Files
supabase/apps/www/components/LaunchWeek/12/LaunchWeekPrizeSection.tsx
Jonathan Summers-MuirandFrancesco Sansalvadore 1f1f8a5fa4 Feat/whale init (#28243)
* duplicate page

* whale init

* table background

* prepare

* sync undocumented remote schema from master

* revert remote schema sync

* add lw12 tickets migration file

* ticket init

* set up lw12 ticket layout

* finish ticket layout and customization form

* lw12 ticket og

* ticket styling

* code highlight border

* launch week migrations

* local dev progress

* keep local gh config

* comment section

* comment section

* comment out username.tsx

* remove lw/ticekts temp

* update copy

* fix migration view

* redirect to try

* use misc

* lw12 og

* share

* share correct

* env var

* username page

* update example env

* push new db schema

* trigger deploy

* update ticket og

* ticket themes

* bypass browser

* change env var name

* fix

* fix

* process env

* create client server side

* lw announcements

* promoToast

* animated bg

* update ticket og bg

* minor details

* secret ticket

* social share text

* social share textgst

* flow text

* update og

* update og handler

* Update index.ts

* use functions.invoke and use generic supabase URL

* Update index.ts

* Update handler.tsx

* Update package-lock.json

* Update handler.tsx

* add next api route

* moved to vercel edge function

* set revalidate

* Update route.tsx

* Delete lw-ticket-og.tsx

* Update route.tsx

* Update [username].tsx

* Update [username].tsx

* add more fetches

* Update turbo.json

* ticket themes updated

* copy and layout updated

* Update index.tsx

* Update Ticket.tsx

* Update TicketingFlow.tsx

* update countdown

* updated bg

* small updates

* moat

* Update [username].tsx

* Update 20240723155310_add_lw12_ticketing_schema.sql

* optimistic ticket stuff og generation

* Update index.tsx

* updated layout

* update themes in og

* Update constants.ts

* attr renamed

* Update TicketingFlow.tsx

* Update TicketActions.tsx

* grammar

* moar updates

* Update TicketActions.tsx

* Update TicketActions2.tsx

* Update TicketActions.tsx

* Update Hero.tsx

* Update TicketingFlow.tsx

* remove console logs

---------

Co-authored-by: Francesco Sansalvadore <f.sansalvadore@gmail.com>
2024-08-01 01:59:01 +08:00

83 lines
3.6 KiB
TypeScript

import React from 'react'
import { cn } from 'ui'
import LabelBadge from './LabelBadge'
import LaunchWeekPrizeCard from './LaunchWeekPrizeCard'
import Image from 'next/image'
import PrizeActions from './Releases/PrizeActions'
export default function LaunchWeekPrizeSection({ className }: { className?: string }) {
return (
<div
id="prizes"
className={cn(
'relative text-left flex flex-col max-w-7xl mx-auto gap-2 scroll-mt-[66px] text-foreground-lighter',
className
)}
>
<h2 className="w-full text-sm font-mono uppercase tracking-[1px]">Awards</h2>
<div className="w-full pt-4">
<div className="grid grid-cols-1 md:grid-cols-3 gap-4 mx-auto h-auto text-foreground">
<LaunchWeekPrizeCard
className="col-span-full md:col-span-2"
contentClassName="flex flex-col justify-between"
content={
<div className="w-full h-auto lg:min-h-[400px] flex flex-col lg:flex-row items-stretch rounded-lg overflow-hidden">
<div className="relative w-full pl-4 xl:px-4 lg:w-2/3 border-b lg:border-none border-muted aspect-[3/1] top-0 md:-bottom-8 overflow-hidden">
<Image
src="/images/launchweek/11/airpods-max-alpha.png"
alt="Supabase AirPod Max prize"
draggable={false}
width={300}
height={300}
className="hidden md:block absolute object-cover scale-50 lg:scale-100 lg:object-top w-[90%] h-full opacity-90 dark:opacity-50 pointer-events-none"
/>
<Image
src="/images/launchweek/11/airpods-max-alpha-crop.png"
alt="Supabase AirPod Max prize"
draggable={false}
width={300}
height={300}
className="md:hidden absolute mx-auto object-cover inset-x-0 lg:object-top w-auto h-full opacity-90 dark:opacity-50 pointer-events-none"
/>
</div>
<div className="flex flex-col lg:w-1/2 gap-1 p-4 md:p-8 lg:pl-0 lg:h-full">
<div className="flex flex-col gap-2 flex-grow">
<LabelBadge text="5 sets" />
<p className="xl:mt-4 text-foreground">Win AirPods Max</p>
<p className="text-foreground-lighter text-sm">
Secure your ticket to enter our random prize pool, and amplify your odds by
sharing. Or if you don't leave anything up for chance - join our Hackathon and
showcase your creations. With luck or skill, you could snag these top-tier
headphones!
</p>
</div>
</div>
</div>
}
/>
<div className="w-full flex flex-col gap-4 items-stretch">
<LaunchWeekPrizeCard
className="flex-grow"
content={
<div className="p-4 md:p-6 flex flex-col gap-2 text-sm items-start justify-between h-full">
<LabelBadge text="30 t-shirts" />
<p>Supabase T-shirts</p>
</div>
}
/>
<LaunchWeekPrizeCard
className="flex-grow"
content={
<div className="p-4 md:p-6 flex flex-col gap-2 text-sm items-start justify-between h-full">
<LabelBadge text="25 pins" />
<p>Supabase Pins</p>
</div>
}
/>
</div>
</div>
</div>
</div>
)
}