@@ -4,6 +4,7 @@ import { type CollectionEntry } from "astro:content";
4
4
import Logo from " ../logo.svg" ;
5
5
import { ButtonWithMovingBorderEffect } from " ./ButtonWithMovingBorderEffect" ;
6
6
import { formatISO } from " date-fns" ;
7
+ import { Icon } from " astro-icon/components" ;
7
8
8
9
type Props = CollectionEntry <" mktds" >;
9
10
@@ -33,26 +34,30 @@ const mktdIsUpcoming = mktd.data.date > new Date();
33
34
/></a
34
35
>
35
36
</div >
36
- <div
37
- class =" container m-auto flex flex-wrap items-center justify-around gap-4 px-4 pb-8"
38
- >
39
- <div class =" grid grid-rows-[1fr_auto_1fr]" >
40
- <div class =" row-start-2" >
37
+ <div class =" container m-auto flex flex-wrap justify-around gap-4 px-4 pb-8" >
38
+ <div
39
+ class =" flex flex-col items-center gap-4"
40
+ class:list ={ mktdIsUpcoming ? " justify-end" : " justify-center" }
41
+ >
42
+ <div class =" " >
41
43
<time datetime ={ date } >{ formattedDate } </time >
42
44
<h1 class =" text-4xl font-bold" >{ mktd .data .name } </h1 >
43
45
<p class =" text-xl first-letter:uppercase" >{ mktd .data .subtitle } </p >
44
46
</div >
45
47
{
46
48
mktdIsUpcoming && (
47
- <div class = " row-start-3 mt-6 justify-self-start" >
48
- <ButtonWithMovingBorderEffect
49
- client :idle
50
- rel = " noopener"
51
- href = { mktd .data .inscriptionLink }
52
- >
53
- S'inscrire
54
- </ButtonWithMovingBorderEffect >
55
- </div >
49
+ <ButtonWithMovingBorderEffect client :idle className = " gap-2" >
50
+ S'inscrire
51
+ { mktd .data .inscriptionLinks .map ((inscriptionLink ) => (
52
+ <a
53
+ rel = " noopener"
54
+ href = { inscriptionLink .url }
55
+ aria-label = { inscriptionLink .type }
56
+ >
57
+ <Icon name = { inscriptionLink .type } />
58
+ </a >
59
+ ))}
60
+ </ButtonWithMovingBorderEffect >
56
61
)
57
62
}
58
63
</div >
0 commit comments