File tree Expand file tree Collapse file tree 1 file changed +41
-0
lines changed
2025/src/components/Schedule Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ import Card from " ../Card.astro" ;
3+ import { Clock , User } from " @lucide/astro" ;
4+ import { getScheduleCardStyle , formatTime } from " ./logic.ts" ;
5+
6+ type Props = {
7+ class? : string ;
8+ start_at: Date ;
9+ end_at: Date ;
10+ title: string ;
11+ session_id? : string | undefined ;
12+ speaker_name? : string | undefined ;
13+ };
14+
15+ const { title, start_at, end_at, speaker_name } = Astro .props ;
16+ const [cardClass, Icon] = getScheduleCardStyle (title );
17+ ---
18+
19+ <Card class =`p-2 mb-5 ${cardClass }` >
20+ <div class =" p-4" >
21+ <div class =" space-y-2" >
22+ <div class =" flex text-sm items-center" >
23+ <Clock class =" mr-2 h-4 w-4 flex-shrink-0 text-green-900" />
24+ <span class =" font-bold text-gray-800"
25+ >{ formatTime (start_at )} - { formatTime (end_at )} </span
26+ >
27+ { speaker_name && (
28+ <div class = " flex items-center ml-5" >
29+ <User class = " h-4 w-4 mr-2 text-gray-600" />
30+ <span class = " text-gray-600" >{ speaker_name } </span >
31+ </div >
32+ )}
33+ </div ><div class =" flex items-center" >
34+ <Icon class =" mr-3 flex-shrink-0 text-gray-900 h-4 w-4" />
35+ <h3 class =" min-w-0 flex-1 text-base leading-tight font-semibold" >
36+ { title }
37+ </h3 >
38+ </div >
39+ </div >
40+ </div >
41+ </Card >
You can’t perform that action at this time.
0 commit comments