summaryrefslogtreecommitdiff
path: root/src/components/Card.astro
diff options
context:
space:
mode:
authorTomasBankauskas <tbdizainas@gmail.com>2024-04-09 13:44:24 +0300
committerTomasBankauskas <tbdizainas@gmail.com>2024-04-09 13:44:24 +0300
commitbe4de751ad432f8230d83e1d6cbb3e56d608cd58 (patch)
tree7922668f00823e21ab7ab799fa4cf5c811bf0613 /src/components/Card.astro
parent3bebbf00e6f4d33bfacbf38eef73a9ad7f0d9d58 (diff)
updates
Diffstat (limited to 'src/components/Card.astro')
-rw-r--r--src/components/Card.astro37
1 files changed, 17 insertions, 20 deletions
diff --git a/src/components/Card.astro b/src/components/Card.astro
index cbe0b0a..da68297 100644
--- a/src/components/Card.astro
+++ b/src/components/Card.astro
@@ -1,29 +1,26 @@
---
interface Props {
- title?: string;
- text?: string;
- linkText?: string;
- href?: string;
+ title?: string;
+ text?: string;
+ linkText?: string;
+ href?: string;
}
const { title, text, linkText, href } = Astro.props;
---
<div class="bg-white text-neutral-600 card">
- <div class="card-body">
- {title && <h3 class="text-neutral-900 card-title">{title}</h3>}
- {text && <p>{text}</p>}
- {
- linkText && href && (
- <div class="card-actions">
- <a
- href={href}
- class="transition link text-neutral-900 hover:opacity-80"
- >
- {linkText}
- </a>
- </div>
- )
- }
- </div>
+ <div class="card-body">
+ {title && <h3 class="text-neutral-900 card-title">{title}</h3>}
+ {text && <p>{text}</p>}
+ {
+ linkText && href && (
+ <div class="card-actions">
+ <a href={href} class="link text-neutral-900">
+ {linkText}
+ </a>
+ </div>
+ )
+ }
+ </div>
</div>