feat: init
This commit is contained in:
32
src/components/Card.astro
Normal file
32
src/components/Card.astro
Normal file
@@ -0,0 +1,32 @@
|
||||
---
|
||||
interface Props {
|
||||
url: string;
|
||||
image: string;
|
||||
title: string;
|
||||
body: string;
|
||||
}
|
||||
|
||||
const { url, image, title, body } = Astro.props;
|
||||
---
|
||||
|
||||
<li class="card">
|
||||
<a class="card__link" href={url}>
|
||||
<div class="center">
|
||||
<img
|
||||
class="card__img"
|
||||
src={image}
|
||||
role="presentation"
|
||||
width="226"
|
||||
height="127"
|
||||
loading="lazy"
|
||||
decoding="async"
|
||||
/>
|
||||
</div>
|
||||
<h3 class="card__title">
|
||||
{title}
|
||||
</h3>
|
||||
<p class="card__txt">
|
||||
{body}
|
||||
</p>
|
||||
</a>
|
||||
</li>
|
||||
Reference in New Issue
Block a user