Skip to content

Commit 759d4bf

Browse files
committed
bring it closer to the design
1 parent 84217bf commit 759d4bf

File tree

5 files changed

+65
-54
lines changed

5 files changed

+65
-54
lines changed

src/app/conf/2025/components/speaker-card.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ export function SpeakerCard({
4545
/>
4646
)}
4747

48-
<div className="relative aspect-square shrink-0 overflow-hidden @[420px]:size-[176px]">
48+
<div className="relative h-full shrink-0 overflow-hidden @[420px]:w-[176px]">
4949
<div className="absolute inset-0 z-[1] bg-sec-light mix-blend-multiply" />
5050
{speaker.avatar ? (
5151
<Image

src/app/conf/2025/components/speaker-tags.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,14 @@ import { eventsColors } from "../utils"
1111
export function SpeakerTags({
1212
speaker,
1313
className,
14+
showEventType = true,
1415
}: {
1516
speaker: SchedSpeaker
1617
className?: string
18+
showEventType?: boolean
1719
}) {
18-
const eventType = speakerSessions.get(speaker.username)?.[0]?.event_type
20+
const eventType =
21+
showEventType && speakerSessions.get(speaker.username)?.[0]?.event_type
1922

2023
return (
2124
<div className={clsx("flex basis-0 flex-wrap gap-2", className)}>

src/app/conf/2025/schedule/_components/back-link.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@ export function BackLink({
66
year,
77
kind,
88
}: {
9-
year: "2025"
9+
year: `20${number}`
1010
kind: "speakers" | "sessions" | "schedule"
1111
}) {
1212
return (
1313
<NextLink
1414
href={`/conf/${year}/${kind}`}
15-
className="group -m-2 inline-flex cursor-pointer items-center gap-2 p-2 text-sec-darker transition-all typography-menu [text-box:trim-both_cap_alphabetic] hover:underline hover:underline-offset-4 dark:text-neu-700"
15+
className="group typography-menu -m-2 inline-flex cursor-pointer items-center gap-2 p-2 text-sec-darker transition-all [text-box:trim-both_cap_alphabetic] hover:underline hover:underline-offset-4 dark:text-neu-700"
1616
>
17-
<div className="group-hover:animate-arrow-left group-focus:animate-arrow-left [--arrow-left-x:-1px]">
17+
<div className="[--arrow-left-x:-1px] group-hover:animate-arrow-left group-focus:animate-arrow-left">
1818
<ArrowDownIcon className="inline-block size-4 translate-y-[-.5px] rotate-90" />
1919
</div>
2020
Back to {capitalize(kind)}

src/app/conf/2025/speakers/[id]/long-session-card.tsx

Lines changed: 33 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import { clsx } from "clsx"
22
import { ScheduleSession } from "@/app/conf/2023/types"
3-
import { Tag } from "@/app/conf/_design-system/tag"
43
import { Button } from "@/app/conf/_design-system/button"
54
import { Anchor } from "@/app/conf/_design-system/anchor"
65
import { CalendarIcon } from "@/app/conf/_design-system/pixelarticons/calendar-icon"
@@ -9,7 +8,7 @@ import ClockIcon from "@/app/conf/_design-system/pixelarticons/clock.svg?svgr"
98
import PlusIcon from "@/app/conf/_design-system/pixelarticons/plus.svg?svgr"
109
import PlayIcon from "@/app/conf/_design-system/pixelarticons/play.svg?svgr"
1110
import { findVideo } from "../../schedule/[id]/session-video"
12-
import { eventsColors, getEventTitle } from "../../utils"
11+
import { getEventTitle } from "../../utils"
1312
import React from "react"
1413
import { SessionTags } from "../../components/session-tags"
1514

@@ -57,15 +56,14 @@ export function LongSessionCard({
5756
return (
5857
<div
5958
className={clsx(
60-
"group relative border border-neu-200 bg-neu-0",
61-
!!video && "flex flex-col gap-6 backdrop-blur-md",
59+
"group relative border border-neu-200 bg-neu-0 dark:border-neu-100",
6260
className,
6361
)}
6462
{...props}
6563
>
6664
<Anchor
6765
href={`/conf/${year}/schedule/${session.id}?name=${session.name}`}
68-
className="absolute inset-0 z-[1] ring-inset ring-neu-400 hover:ring-1 dark:ring-neu-100"
66+
className="absolute inset-0 z-[1] ring-inset ring-neu-400 hover:bg-sec-base/[.035] hover:ring-1 dark:ring-neu-100"
6967
aria-label={`Read more about "${eventTitle}" by ${session.speakers?.[0]?.name || "Speaker"}`}
7068
/>
7169

@@ -83,12 +81,9 @@ export function LongSessionCard({
8381
</div>
8482

8583
<div className="flex flex-col gap-4">
86-
<div className="min-h-[120px]">
87-
<h3 className="typography-body-lg text-neu-900">
88-
{getEventTitle(
89-
session,
90-
speakers.map(s => s.name),
91-
)}
84+
<div className="min-h-[60px]">
85+
<h3 className="typography-body-lg text-neu-900 2xl:text-2xl">
86+
{eventTitle}
9287
</h3>
9388
</div>
9489
<div className="flex items-center justify-between gap-2">
@@ -126,36 +121,39 @@ export function LongSessionCard({
126121
{/* todo: past session no recording variant */}
127122

128123
{video ? (
129-
<Button
130-
href={`https://youtube.com/embed/${video.id}`}
131-
variant="primary"
132-
className="relative z-[2] w-full"
133-
>
134-
Watch
135-
<PlayIcon className="size-6" />
136-
</Button>
124+
<footer className="px-6 pb-6 pt-0">
125+
<Button
126+
href={`https://youtube.com/embed/${video.id}`}
127+
variant="primary"
128+
className="relative z-[2] w-full"
129+
>
130+
Watch
131+
<PlayIcon className="size-6" />
132+
</Button>
133+
</footer>
137134
) : (
138-
<footer className="flex items-center border-t border-neu-200 text-neu-800">
139-
<div className="flex flex-1 items-center gap-6 border-r border-neu-200 px-6 py-4">
140-
<div className="flex items-center gap-0.5">
141-
<CalendarIcon className="size-4 text-sec-dark" />
142-
<span className="typography-body-xs">{formattedDate}</span>
143-
</div>
144-
<div className="flex items-center gap-0.5">
145-
<ClockIcon className="size-4 text-sec-dark" />
146-
<span className="typography-body-xs">{formattedTime}</span>
135+
<footer className="flex items-center border-t border-neu-200 text-neu-800 dark:border-neu-100">
136+
<div className="flex flex-1 items-center gap-6 border-r border-neu-200 p-6">
137+
<div className="contents flex-col md:max-xl:flex">
138+
<div className="flex items-center gap-0.5 whitespace-pre">
139+
<CalendarIcon className="size-4 shrink-0 -translate-y-px text-sec-dark" />
140+
<span className="typography-body-xs">{formattedDate}</span>
141+
</div>
142+
<div className="flex items-center gap-0.5">
143+
<ClockIcon className="size-4 shrink-0 text-sec-dark" />
144+
<span className="typography-body-xs">{formattedTime}</span>
145+
</div>
147146
</div>
148147
<div className="flex items-center gap-0.5">
149-
<PinIcon className="size-4 text-sec-dark" />
148+
<PinIcon className="size-4 shrink-0 text-sec-dark" />
150149
<span className="typography-body-xs">{session.venue}</span>
151150
</div>
152151
</div>
153-
<div className="flex flex-col items-center justify-center gap-6 px-6 py-4">
154-
<button className="relative z-[2] flex items-center gap-0.5 text-neu-800">
155-
<PlusIcon className="size-4 text-sec-dark" />
156-
<span className="typography-body-xs">Add to calendar</span>
157-
</button>
158-
</div>
152+
{/* TODO: Actually add to calendar. Ensure we show this only on this year's events. */}
153+
<button className="relative z-[2] flex h-full flex-row items-center justify-center gap-0.5 px-6 py-4 text-neu-800 ring-inset ring-neu-400 hover:bg-sec-base/[.035] hover:ring-1 dark:ring-neu-100">
154+
<PlusIcon className="size-4 shrink-0 text-sec-dark" />
155+
<span className="typography-body-xs">Add to calendar</span>
156+
</button>
159157
</footer>
160158
)}
161159
</div>

src/app/conf/2025/speakers/[id]/page.tsx

Lines changed: 24 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import { SpeakerTags } from "../../components/speaker-tags"
1818
import { SpeakerLinks } from "../../components/speaker-links"
1919
import { LongSessionCard } from "./long-session-card"
2020
import Image from "next-image-export-optimizer"
21+
import { formatDescription } from "../../schedule/[id]/format-description"
2122

2223
type SpeakerProps = { params: { id: string } }
2324

@@ -51,37 +52,40 @@ export default function SpeakerPage({ params }: SpeakerProps) {
5152

5253
return (
5354
<>
54-
{/* gql-conf-navbar-strip border-t border-neu-200 bg-neu-0 py-8 text-neu-900 before:bg-white/40 dark:border-neu-100 before:dark:bg-blk/30 xl:py-16 */}
5555
<NavbarPlaceholder className="top-0 bg-neu-50 before:bg-neu-50/40 dark:bg-neu-0 dark:before:bg-blk/30" />
5656
<main className="gql-all-anchors-focusable gql-conf-navbar-strip text-neu-900 before:bg-neu-50/40 before:dark:bg-blk/30">
5757
<div className="bg-neu-50 dark:bg-neu-0">
5858
<div className="gql-conf-container">
5959
<div className="gql-conf-section !py-0">
60-
<div className="border-x border-neu-200 pt-8 dark:border-neu-100 2xl:pt-16">
61-
<SpeakerHeader speaker={speaker} year="2025" />
60+
<div className="border-x border-neu-200 dark:border-neu-100">
61+
<SpeakerHeader
62+
speaker={speaker}
63+
year="2025"
64+
className="border-b border-neu-200 dark:border-neu-100"
65+
/>
6266

6367
<div className="flex justify-end">
6468
<SpeakerLinks
6569
size="lg"
6670
speaker={speaker}
67-
className="!border-r-0"
71+
className="!border-r-0 !border-t-0"
6872
/>
6973
</div>
7074

71-
<p className="typography-body-lg px-4 py-8 lg:p-8 xl:px-24 xl:pb-24 xl:pt-16 xl:text-[32px]">
72-
{speaker.about}
75+
<p className="typography-body-lg mx-auto box-content max-w-[800px] px-4 py-8 lg:px-8 lg:py-16 xl:px-24 xl:pb-24 xl:text-[32px]">
76+
{formatDescription(speaker.about)}
7377
</p>
7478

7579
<Hr />
7680

77-
<h3 className="typography-h2 my-8 max-w-[408px] px-2 sm:px-3 lg:my-16">
81+
<h3 className="typography-h2 my-8 px-2 sm:px-3 lg:my-16">
7882
2025 Sessions
7983
</h3>
8084
<SpeakerSessions speaker={speaker} className="-mx-px -mb-px" />
8185

8286
<Hr />
8387

84-
<h3 className="typography-h2 my-8 max-w-[408px] px-2 sm:px-3 lg:my-16">
88+
<h3 className="typography-h2 my-8 px-2 sm:px-3 lg:my-16">
8589
Sessions from previous editions
8690
</h3>
8791
<SpeakerSessions speaker={speaker} className="-mx-px -mb-px" />
@@ -120,22 +124,28 @@ function SpeakerHeader({
120124
className?: string
121125
}) {
122126
return (
123-
<header className={clsx("flex max-md:flex-col", className)}>
124-
<div className="pl-2 sm:pl-3">
125-
<BackLink year="2025" kind="schedule" />
127+
<header
128+
className={clsx("flex justify-between gap-4 max-md:flex-col", className)}
129+
>
130+
<div className="pl-2 pt-8 sm:pl-3 2xl:pl-24 2xl:pr-16 2xl:pt-16">
131+
<BackLink year={year} kind="schedule" />
126132
<p className="typography-body-lg mt-4 text-sec-darker lg:typography-h3 lg:mt-20">
127133
Meet the speaker
128134
</p>
129135
<h1 className="typography-h1 lg:mt-2">{speaker.name}</h1>
130-
<div className="flex flex-wrap items-center justify-between gap-2 lg:gap-x-4 xl:gap-x-8">
136+
<div className="typography-body-lg mt-8 flex flex-wrap items-center gap-x-8 gap-y-2 lg:mt-12 xl:mt-16 2xl:mt-20">
131137
{[speaker.position, speaker.company === "-" ? "" : speaker.company]
132138
.filter(Boolean)
133139
.join(", ")}
134-
<SpeakerTags speaker={speaker} className="max-lg:flex-nowrap" />
140+
<SpeakerTags
141+
speaker={speaker}
142+
className="flex-nowrap"
143+
showEventType={false}
144+
/>
135145
</div>
136146
</div>
137147
{speaker.avatar && (
138-
<div className="relative overflow-hidden max-lg:mt-6">
148+
<div className="relative overflow-hidden">
139149
<div className="absolute inset-0 z-[1] bg-[hsl(79_81%_83.5%)] opacity-90 mix-blend-multiply" />
140150
<Image
141151
src={speaker.avatar}

0 commit comments

Comments
 (0)