diff --git a/apps/www/components/LaunchWeek/Ticket/TicketContainer.tsx b/apps/www/components/LaunchWeek/Ticket/TicketContainer.tsx index 632c731bfc4..4ca2852200e 100644 --- a/apps/www/components/LaunchWeek/Ticket/TicketContainer.tsx +++ b/apps/www/components/LaunchWeek/Ticket/TicketContainer.tsx @@ -35,11 +35,7 @@ export default function Conf({ > {pageState === 'registration' && !sharePage ? ( - <> - {/* */} -
- {/* */} - + ) : ( {children} + return
{children}
} diff --git a/apps/www/components/LaunchWeek/Ticket/form.tsx b/apps/www/components/LaunchWeek/Ticket/form.tsx index 04579414957..6cf11867909 100644 --- a/apps/www/components/LaunchWeek/Ticket/form.tsx +++ b/apps/www/components/LaunchWeek/Ticket/form.tsx @@ -155,12 +155,12 @@ export default function Form({ sharePage, align = 'Center' }: Props) { useEmailQueryParam('email', setEmail) return ( -
+

Coming soon

@@ -188,15 +188,14 @@ export default function Form({ sharePage, align = 'Center' }: Props) {
) : ( - + { - // if (formRef && formRef.current && isMobileOrTablet()) { - // scrollTo(formRef.current, formRef.current.offsetHeight); - // } - }} > {username ? 'Done!' : 'Connect with GitHub'} - {username ? ( - - {/* */} - - ) : null} + {username ? : null} {!username && (

diff --git a/apps/www/components/LaunchWeek/Ticket/ticket.module.css b/apps/www/components/LaunchWeek/Ticket/ticket.module.css index aebe6c9c713..63304f59c72 100644 --- a/apps/www/components/LaunchWeek/Ticket/ticket.module.css +++ b/apps/www/components/LaunchWeek/Ticket/ticket.module.css @@ -53,10 +53,10 @@ } } -.ticket-share-layout { +/* .ticket-share-layout { align-items: center; margin-bottom: auto; -} +} */ .ticket-visual { position: relative; diff --git a/apps/www/components/LaunchWeek/Ticket/ticket.tsx b/apps/www/components/LaunchWeek/Ticket/ticket.tsx index 065ecf22412..cb0cf46b487 100644 --- a/apps/www/components/LaunchWeek/Ticket/ticket.tsx +++ b/apps/www/components/LaunchWeek/Ticket/ticket.tsx @@ -46,6 +46,7 @@ export default function Ticket({ username, name, ticketNumber, sharePage, golden // } // }, [divRef, sharePage]) // golden = true + return (

{sharePage ? ( name ? ( -

{name}’s Ticket

+

{name}’s Ticket

) : ( -

{SITE_NAME}

+

{SITE_NAME}

) ) : golden ? ( -

+

You won a golden ticket!
Claim it now!

) : ( -

+

Congratulations, you have a ticket!

)}

-

+

{sharePage ? ( -

+

Join {name ?? 'us'} on {DATE}.

) : golden ? ( diff --git a/apps/www/pages/launch-week/index.tsx b/apps/www/pages/launch-week/index.tsx index 7fc9153231f..facce5b182b 100644 --- a/apps/www/pages/launch-week/index.tsx +++ b/apps/www/pages/launch-week/index.tsx @@ -1,19 +1,12 @@ import { NextSeo } from 'next-seo' +import _days from '~/components/LaunchWeek/days.json' +import { WeekDayProps } from '~/components/LaunchWeek/types' import DefaultLayout from '~/components/Layouts/Default' import SectionContainer from '~/components/Layouts/SectionContainer' -import _days from '~/components/LaunchWeek/days.json' -import HackathonSection from '~/components/LaunchWeek/HackathonSection' -import LaunchHero from '~/components/LaunchWeek/LaunchHero' -import { LaunchSection } from '~/components/LaunchWeek/LaunchSection' -import PreLaunchTeaser from '~/components/LaunchWeek/PreLaunchTeaser' -import ScheduleInfo from '~/components/LaunchWeek/ScheduleInfo' -import { WeekDayProps } from '~/components/LaunchWeek/types' -import { ArrowRightIcon } from '@heroicons/react/outline' -import { Badge, Modal } from 'ui' -import { useEffect, useState } from 'react' import { createClient, Session } from '@supabase/supabase-js' import { useRouter } from 'next/router' +import { useEffect, useState } from 'react' import TicketContainer from '~/components/LaunchWeek/Ticket/TicketContainer' import { useTheme } from '~/components/Providers' @@ -77,26 +70,8 @@ export default function launchweek() { className="md:40 hidden w-40 dark:block lg:w-80" />

Dec 12 – 16 at 8 AM PT | 11 AM ET

- {/* */} - {/* {!shippingHasStarted && } */} - {/* */} - {/* Coming soon -

- Register to get your ticket and stay tuned all week for daily announcements -

*/} - {/*
*/} - {/* TODO: FIX CRESCENT TO NOT BREAK MOBILE VIEWS... */} - {/* - - - */} - {/*
+
-
*/} +
{/*
*/} {/*
diff --git a/apps/www/pages/launch-week/tickets/[username].tsx b/apps/www/pages/launch-week/tickets/[username].tsx index e8bbbd4c501..d873753b74d 100644 --- a/apps/www/pages/launch-week/tickets/[username].tsx +++ b/apps/www/pages/launch-week/tickets/[username].tsx @@ -6,8 +6,9 @@ import SectionContainer from '~/components/Layouts/SectionContainer' import TicketContainer from '~/components/LaunchWeek/Ticket/TicketContainer' import { SITE_URL, SAMPLE_TICKET_NUMBER } from '~/lib/constants' import { createClient } from '@supabase/supabase-js' -import { useState } from 'react' +import { useEffect, useState } from 'react' import { FastGlobOptionsWithoutCwd } from 'globby' +import { useTheme } from '~/components/Providers' type Props = { username: string | null @@ -22,6 +23,8 @@ const supabaseAdmin = createClient( ) export default function TicketShare({ username, ticketNumber, name, golden }: Props) { + const { isDarkMode } = useTheme() + const [supabase] = useState(() => createClient(process.env.NEXT_PUBLIC_SUPABASE_URL!, process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!) ) @@ -35,6 +38,10 @@ export default function TicketShare({ username, ticketNumber, name, golden }: Pr username ?? '' )}` + useEffect(() => { + document.body.className = isDarkMode ? 'dark bg-[#121212]' : 'light bg-[#fff]' + }, [isDarkMode]) + return ( <> -
- + createClient(process.env.NEXT_PUBLIC_SUPABASE_URL!, process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!) ) @@ -28,6 +31,10 @@ export default function TicketHome() { }) }, []) + useEffect(() => { + document.body.className = isDarkMode ? 'dark bg-[#121212]' : 'light bg-[#fff]' + }, [isDarkMode]) + return ( <> -
- +
@media (min-width: 640px) { ... }