Skip to content

Commit 16d7600

Browse files
committed
Update card component style.
1 parent 4e2e8a6 commit 16d7600

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

src/components/card/card.astro

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export interface Props {
1313
const { title, subtitle, url, image } = Astro.props;
1414
---
1515

16-
<div class="block min-w-[250px] w-full md:w-[40%] lg:w-[30%] p-4 bg-[#D5D6E6] rounded-2xl">
16+
<div class="block min-w-[250px] w-full md:w-[40%] lg:w-[30%] p-4 bg-[#D5D6E6] rounded-2xl text-center flex flex-col h-full">
1717
<a href={url} class="block">
1818
<div class="relative w-full mb-4">
1919
<Image
@@ -26,15 +26,16 @@ const { title, subtitle, url, image } = Astro.props;
2626
/>
2727
</div>
2828
</a>
29-
<div class="flex flex-col items-start">
29+
<div class="flex flex-col items-center flex-grow mb-2">
3030
<a href={url} class="block hover:underline">
3131
<h3 class="text-2xl text-primary">{title}</h3>
3232
</a>
33-
<slot />
33+
<slot />
3434
</div>
35-
<a class="mt-2 text-xs px-2 py-1 bg-[#141F36] text-white rounded-[10px] inline-block leading-4 hover:bg-button-hover not-prose rounded-[5px]" href="{url}">
35+
<a class="text-xs px-2 py-1 mt-4 bg-[#141F36] text-white rounded-[10px] inline-block w-fit mx-auto leading-4 hover:bg-button-hover not-prose mt-auto" href="{url}">
3636
{subtitle}
37-
<span class="inline-block ml-1 font-system text-lg leading-4" >
38-
39-
</span></a>
37+
<span class="inline-block ml-1 font-system text-lg leading-4">
38+
39+
</span>
40+
</a>
4041
</div>

0 commit comments

Comments
 (0)