Skip to content

Commit aa051f8

Browse files
authored
Merge pull request #231 from posadev/communities-agenda
feat: add missing communities and improve agenda
2 parents 26bf525 + d94917a commit aa051f8

File tree

11 files changed

+104
-40
lines changed

11 files changed

+104
-40
lines changed

src/components/Header.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ const Header = () => {
3838
>
3939
<div className="container mx-auto px-4 pt-2">
4040
<div className="flex items-center justify-between h-16">
41-
<a className="flex items-center space-x-2" onClick={() => navigate('/#inicio')}>
41+
<a className="flex items-center space-x-2" onClick={() => navigateMenu('/#inicio')}>
4242
<img
4343
src={posadevLogo}
4444
alt="Posadev Logo"
@@ -105,7 +105,7 @@ const Header = () => {
105105
</a>
106106
<a
107107
onClick={() => navigateMenu('/#patrocinadores')}
108-
className={cn("w-full bg-gradient-to-r from-posadev-darkPink to-posadev-brightPink text-white px-4 py-3 rounded-lg flex items-center space-x-2", isActive('/#patrocinadores') && "underline shadow-posadev-brightPink/25")}
108+
className={cn("w-full bg-gradient-to-r from-posadev-darkPink to-posadev-brightPink text-white px-4 py-3 rounded-lg flex items-center space-x-2 gap-2", isActive('/#patrocinadores') && "underline shadow-posadev-brightPink/25")}
109109
>
110110
<UserStar className="w-4 h-4" aria-hidden="true"/>
111111
Se un patrocinador

src/components/agenda/AgendaContent.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import {useEffect} from "react";
44
import {getAgenda} from "@/https/fetch.ts";
55
import {useAppContext} from "@/context/AppContext.tsx";
66
import AgendaRow from "@/components/agenda/AgendaRow.tsx";
7-
import {ScrollArea} from "@/components/ui/scroll-area.tsx";
87

98
const AgendaContent = () => {
109
const {setAgenda, agenda, savedSessions} = useAppContext()
@@ -19,7 +18,7 @@ const AgendaContent = () => {
1918
if (agenda.length === 0) return (<></>)
2019

2120
if (!displayAll && savedSessions.size === 0) {
22-
return (<Card className="w-full pb-8 md:px-6 relative shadow-gray-500">
21+
return (<Card className="w-full pb-8 md:px-6 relative shadow-gray-500 min-h-60">
2322
<nav className="flex gap-4 pt-8 pb-2 sticky bg-white w-full h-20">
2423
<Badge variant={`${displayAll ? "default" : "ghost"}`} onClick={() => setDisplayAll(true)} role="button">Mostrar todos</Badge>
2524
<Badge variant={`${displayAll ? "ghost" : "default"}`} onClick={() => setDisplayAll(false)} role="button">Mostrar guardados</Badge>
@@ -30,7 +29,7 @@ const AgendaContent = () => {
3029

3130
return (
3231
<Card className="w-full pb-8 md:px-6 relative shadow-gray-500">
33-
<nav className="flex gap-4 pt-8 pb-2 sticky top-[80px] z-10 bg-white w-full h-20">
32+
<nav className="flex gap-4 mt-4 py-2 px-4 sticky top-[80px] z-20 bg-white w-full h-14">
3433
<Badge variant={`${displayAll ? "default" : "ghost"}`} onClick={() => setDisplayAll(true)} role="button">Mostrar todos</Badge>
3534
<Badge variant={`${displayAll ? "ghost" : "default"}`} onClick={() => setDisplayAll(false)} role="button">Mostrar guardados</Badge>
3635
</nav>

src/components/agenda/AgendaRow.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import React, {useEffect, useState} from "react";
2-
import RoomsExpandable from "@/components/agenda/RoomsExpandable.tsx";
32
import Rooms from "@/components/agenda/Rooms.tsx";
43
import {useIsMobile} from "@/hooks/use-mobile.tsx";
54
import {IRoomAgenda} from "@/types/agenda.ts";
65
import {formatTime} from "@/lib/utils.ts";
76
import {useAppContext} from "@/context/AppContext.tsx";
7+
import Adorno from "@/components/icons/Adorno.tsx";
8+
import {Card} from "@/components/ui/card.tsx";
89

910
interface AgendaRowProps {
1011
slotStart: string;
@@ -49,8 +50,14 @@ const AgendaRow: React.FC<AgendaRowProps> = ({slotStart, rooms}) => {
4950
hasPassed ? "opacity-0 pointer-events-none" : "opacity-100"
5051
}`}
5152
>
53+
<Card className="flex items-center gap-4 p-2 bg-alternative-700 border-alternative-700 sticky top-[136px] z-10">
54+
<Adorno className="h-8 w-8" />
55+
<time className="font-bold text-2xl text-white">{formatTime(slotStart)}</time>
56+
<span aria-label="a" className="font-bold text-2xl text-gray-500">-</span>
57+
<time className="font-bold text-2xl text-white">{endTime}</time>
58+
<h2 className="font-bold text-2xl text-gray-700"></h2>
59+
</Card>
5260
<Rooms rooms={rooms} slotStart={slotStart} endsAt={endTime} hide={false} />
53-
<RoomsExpandable rooms={rooms} slotStart={slotStart} endsAt={endTime} hide={true} />
5461
</section>
5562
)
5663
}

src/components/agenda/Rooms.tsx

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,10 @@
11
import React from "react";
2-
import Adorno from "@/components/icons/Adorno.tsx";
32
import CardCharla from "@/components/agenda/CardCharla.tsx";
4-
import {Card} from "@/components/ui/card.tsx";
5-
import {formatTime} from "@/lib/utils.ts";
63

74
const Rooms = ({rooms, slotStart, hide, endsAt}) => {
85
if (hide) return null;
96
return (
107
<>
11-
<Card className="flex items-center gap-4 p-2 bg-alternative-700 border-alternative-700">
12-
<Adorno className="h-8 w-8" />
13-
<time className="font-bold text-2xl text-white">{formatTime(slotStart)}</time>
14-
<span aria-label="a" className="font-bold text-2xl text-gray-500">-</span>
15-
<time className="font-bold text-2xl text-white">{endsAt}</time>
16-
<h2 className="font-bold text-2xl text-gray-700"></h2>
17-
</Card>
188
<div className="flex flex-col flex-wrap flex-grow md:flex-row gap-6 px-10 w-full">
199
{rooms.map((room) => {
2010
return <CardCharla key={room.id} room={room} />

src/components/agenda/RoomsExpandable.tsx

Lines changed: 13 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -3,31 +3,23 @@ import CardCharla from "@/components/agenda/CardCharla.tsx";
33
import Adorno from "@/components/icons/Adorno.tsx";
44
import React from "react";
55
import {formatTime} from "@/lib/utils.ts";
6+
import Carousel from "@/components/Carousel.tsx";
7+
import {IRoomAgenda} from "@/types/agenda.ts";
8+
import {Card} from "@/components/ui/card.tsx";
69

710
const RoomsExpandable = ({rooms, slotStart, endsAt, hide}) => {
811
if (hide) return null;
912
return (
10-
<Accordion type="single" collapsible className="">
11-
<AccordionItem value={slotStart}>
12-
<div className="flex items-center gap-4">
13-
<AccordionTrigger className="flex gap-6 px-2">
14-
<Adorno/>
15-
<time className="font-bold text-2xl">{formatTime(slotStart)}</time>
16-
<span aria-label="a" className="font-bold text-2xl text-gray-500">-</span>
17-
<time className="font-bold text-2xl text-white">{endsAt}</time>
18-
<h2 className="font-bold text-2xl text-gray-700"></h2>
19-
Ver mas
20-
</AccordionTrigger>
21-
</div>
22-
<AccordionContent>
23-
{rooms.map((room) => (
24-
<div className="flex flex-col md:flex-row gap-6" key={room.id}>
25-
<CardCharla room={room}/>
26-
</div>
27-
))}
28-
</AccordionContent>
29-
</AccordionItem>
30-
</Accordion>
13+
<section>
14+
<Card className="flex items-center gap-4 p-2 bg-alternative-700 border-alternative-700">
15+
<Adorno className="h-8 w-8" />
16+
<time className="font-bold text-2xl text-white">{formatTime(slotStart)}</time>
17+
<span aria-label="a" className="font-bold text-2xl text-gray-500">-</span>
18+
<time className="font-bold text-2xl text-white">{endsAt}</time>
19+
<h2 className="font-bold text-2xl text-gray-700"></h2>
20+
</Card>
21+
<Carousel items={rooms} renderItem={(room: IRoomAgenda) => <CardCharla room={room} key={room.id}/>} />
22+
</section>
3123
)
3224
}
3325

src/context/AppContext.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ export const AppProvider = ({ children }) => {
3939

4040

4141
useEffect(() => {
42-
console.log(savedSessions);
4342
localStorage.setItem("savedSessions", JSON.stringify([...savedSessions]));
4443
}, [savedSessions]);
4544

src/data/communites.ts

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ import GDGLogo from "@/img/communities/2025/GDG-Guadalajara.png";
88
import ajolotesAWSLogo from "@/img/communities/2025/ajolotes-aws.png";
99
import calzadacode from "@/img/communities/2025/calzadacode.png";
1010
import linuxeroszapopan from "@/img/communities/2025/linuxeroszapopan.png";
11+
import techQuiero from "@/img/communities/2025/techquiero.png";
12+
import rubymx from "@/img/communities/2025/rubymx.png";
13+
import webdevtalksLogo from "@/img/communities/2025/webdevtalks.png";
1114

1215
export const communitiesAllies: Array<ICommunity> = [
1316
{
@@ -180,5 +183,79 @@ export const communitiesAllies: Array<ICommunity> = [
180183
linkType: LinkType.Twitter
181184
}
182185
]
186+
},
187+
{
188+
name: "TechQuiero",
189+
description: "",
190+
link: "https://techquiero.com/es",
191+
image: techQuiero,
192+
socials: [
193+
{
194+
title: "Instagram",
195+
url: "https://www.instagram.com/techquieromx/",
196+
linkType: LinkType.Instagram
197+
},
198+
{
199+
title: "Facebook",
200+
url: "https://www.facebook.com/TechQuiero",
201+
linkType: LinkType.Facebook
202+
},
203+
{
204+
title: "LinkedIn",
205+
url: "https://www.linkedin.com/company/tech-quiero/posts/?feedView=all",
206+
linkType: LinkType.LinkedIn
207+
}
208+
]
209+
},
210+
{
211+
name: "Comunidad RubyMX",
212+
description: "",
213+
link: "https://comunidadruby.mx/",
214+
image: rubymx,
215+
socials: [
216+
{
217+
title: "Facebook",
218+
url: "https://www.facebook.com/comunidadrubymx",
219+
linkType: LinkType.Facebook
220+
},
221+
{
222+
title: "LinkedIn",
223+
url: "https://mx.linkedin.com/company/comunidadrubymx",
224+
linkType: LinkType.LinkedIn
225+
},
226+
{
227+
title: "Twitter",
228+
url: "https://x.com/comunidadrubymx",
229+
linkType: LinkType.Twitter
230+
},
231+
{
232+
title: "Instagram",
233+
url: "https://www.instagram.com/comunidadrubymx",
234+
linkType: LinkType.Instagram
235+
}
236+
]
237+
},
238+
{
239+
name: "WebDevTalks",
240+
description: "",
241+
link: "https://webdevtalks.mx",
242+
image: webdevtalksLogo,
243+
socials: [
244+
{
245+
title: "Instagram",
246+
url: "https://www.instagram.com/webdevtalksmx",
247+
linkType: LinkType.Instagram
248+
},
249+
{
250+
title: "Facebook",
251+
url: "https://www.facebook.com/ColimaWebDevTalks",
252+
linkType: LinkType.Facebook
253+
},
254+
{
255+
title: "LinkedIn",
256+
url: "https://www.linkedin.com/company/web-dev-talks",
257+
linkType: LinkType.LinkedIn
258+
}
259+
]
183260
}
184261
];
11 KB
Loading
28.7 KB
Loading
1.11 MB
Loading

0 commit comments

Comments
 (0)