diff --git a/app/activeEvents/[event_id]/page.tsx b/app/discover/[event_id]/page.tsx similarity index 82% rename from app/activeEvents/[event_id]/page.tsx rename to app/discover/[event_id]/page.tsx index 1144489..2aee252 100644 --- a/app/activeEvents/[event_id]/page.tsx +++ b/app/discover/[event_id]/page.tsx @@ -5,9 +5,7 @@ import { useRouter } from 'next/navigation'; import { fetchEventById } from '@/api/supabase/queries/events'; import { fetchFacilityById } from '@/api/supabase/queries/facilities'; import Back from '@/public/images/back.svg'; -import Help from '@/public/images/help.svg'; import LocationPin from '@/public/images/location_pin.svg'; -import Star from '@/public/images/star.svg'; import { SMALL } from '@/styles/text'; import { Event, Facilities } from '@/types/schema'; import { @@ -33,17 +31,17 @@ import { Title, } from './styles'; -function Tags(tags: string[]) { +function Tags(tags: (string | undefined)[]) { return ( {tags.map((tag, index) => { - return {tag}; + return tag && {tag}; })} ); } -function InterestBlockGen(title: string, about: string) { +function InterestBlockGen(title: string, about: string, icon: string) { return ( {' '} @@ -53,7 +51,7 @@ function InterestBlockGen(title: string, about: string) { {title} {about} - Test + Icon ); @@ -95,8 +93,8 @@ export default function EventPage({ {event ? event.needs_host - ? Tags(['Host Needed', event.type_of_act, event.genre]) - : Tags([event.type_of_act, event.genre]) + ? Tags(['Host Needed', event.performance_type, event.genre]) + : Tags([event.performance_type, event.genre]) : ''} About @@ -117,8 +115,16 @@ export default function EventPage({ '' )} Show Interest - {InterestBlockGen('To Perform', 'Be the star of the show!')} - {InterestBlockGen('To Host', 'Help setup the show!')} + {InterestBlockGen( + 'To Perform', + 'Be the star of the show!', + '/images/help.svg', + )} + {InterestBlockGen( + 'To Host', + 'Help setup the show!', + '/images/star.svg', + )} Sign up diff --git a/app/activeEvents/[event_id]/styles.ts b/app/discover/[event_id]/styles.ts similarity index 100% rename from app/activeEvents/[event_id]/styles.ts rename to app/discover/[event_id]/styles.ts diff --git a/app/activeEvents/page.tsx b/app/discover/page.tsx similarity index 97% rename from app/activeEvents/page.tsx rename to app/discover/page.tsx index a4a456b..e8db2a8 100644 --- a/app/activeEvents/page.tsx +++ b/app/discover/page.tsx @@ -55,6 +55,7 @@ export default function ActiveEventsPage() { {events.map(event => ( ))} diff --git a/app/activeEvents/styles.ts b/app/discover/styles.ts similarity index 100% rename from app/activeEvents/styles.ts rename to app/discover/styles.ts diff --git a/components/EventListingCard/EventListingCard.tsx b/components/EventListingCard/EventListingCard.tsx index 7a6445d..e00349e 100644 --- a/components/EventListingCard/EventListingCard.tsx +++ b/components/EventListingCard/EventListingCard.tsx @@ -1,11 +1,18 @@ import React from 'react'; +import Link from 'next/link'; import { PerformanceType } from '@/types/schema'; import { EventListing } from './styles'; export default function EventListingCard({ performance_type, + id, }: { performance_type: PerformanceType; + id: string; }) { - return {performance_type} ; + return ( + + {performance_type} + + ); }