@@ -9,6 +9,8 @@ import { SchedSpeaker } from "../../2023/types"
99import { StripesDecoration } from "../../_design-system/stripes-decoration"
1010import { SocialIcon , SocialIconType } from "../../_design-system/social-icon"
1111
12+ import styles from "./speaker-card.module.css"
13+
1214export interface SpeakerCardProps extends React . HTMLAttributes < HTMLDivElement > {
1315 tags ?: string [ ]
1416 isReturning ?: boolean
@@ -30,6 +32,7 @@ export function SpeakerCard({
3032 < article
3133 className = { clsx (
3234 "group relative overflow-hidden border border-neu-200 bg-neu-0 @container dark:border-neu-100" ,
35+ styles . speakerCard ,
3336 className ,
3437 ) }
3538 { ...props }
@@ -38,23 +41,33 @@ export function SpeakerCard({
3841 { showSocials && (
3942 < SpeakerLinks speaker = { speaker } className = "absolute right-6 top-6" />
4043 ) }
41- { speaker . avatar && (
42- < div className = "relative aspect-square shrink-0 overflow-hidden" >
43- < div className = "absolute inset-0 z-[1] bg-sec-light mix-blend-multiply" />
44+
45+ < div className = "relative aspect-square shrink-0 overflow-hidden @[420px]:basis-[176px]" >
46+ < div className = "absolute inset-0 z-[1] bg-sec-light mix-blend-multiply" />
47+ { speaker . avatar ? (
4448 < Image
4549 src = { speaker . avatar }
4650 alt = ""
4751 width = { 176 }
4852 height = { 176 }
4953 className = "size-full object-cover saturate-[.1] transition-transform"
5054 />
51- < Stripes mask = "radial-gradient(ellipse at top left, hsl(var(--color-pri-base)) 0%, hsl(var(--color-pri-base)) 5%, transparent 40%, transparent, transparent 85%, black 100%)" />
52- </ div >
53- ) }
55+ ) : (
56+ < div
57+ className = "size-full"
58+ style = { {
59+ backgroundImage :
60+ "linear-gradient(163deg, #759236 0%, hsl(var(--color-sec-lighter)) 100%)" ,
61+ } }
62+ />
63+ ) }
64+ < Stripes />
65+ </ div >
66+
5467 < div className = "flex flex-1 flex-col gap-2" >
5568 < div className = "flex flex-col gap-1" >
5669 < h3 className = "typography-body-lg" > { speaker . name } </ h3 >
57- < p className = "typography-body-sm text-neu-800" >
70+ < p className = "text-neu-800 typography-body-sm " >
5871 { [
5972 speaker . position ,
6073 speaker . company === "-" ? "" : speaker . company ,
@@ -64,7 +77,7 @@ export function SpeakerCard({
6477 </ p >
6578 </ div >
6679 { speaker . about && (
67- < p className = "typography-body-sm line-clamp-3 text-neu-800" >
80+ < p className = "line-clamp-3 text-neu-800 typography-body-sm " >
6881 { speaker . about }
6982 </ p >
7083 ) }
@@ -124,17 +137,16 @@ function SpeakerLinks({
124137 )
125138}
126139
127- function Stripes ( { mask } : { mask ?: string } ) {
140+ function Stripes ( ) {
128141 return (
129142 < div
130143 role = "presentation"
131- className = "pointer-events-none absolute inset-0 inset-y-[-20px]"
132- style = { {
133- maskImage : mask ,
134- WebkitMaskImage : mask ,
135- } }
144+ className = { clsx (
145+ "pointer-events-none absolute inset-0 inset-y-[-20px]" ,
146+ styles . stripes ,
147+ ) }
136148 >
137- < StripesDecoration oddClassName = "absolute inset-0 bg-gradient-to-b from-sec-dark to-sec-light " />
149+ < StripesDecoration oddClassName = "absolute inset-0 bg-gradient-to-b from-sec-dark to-[var(--end-color)] " />
138150 </ div >
139151 )
140152}
0 commit comments