feat: walking skeleton - study space uploads
This commit is contained in:
35
src/lib/components/SpaceCard.svelte
Normal file
35
src/lib/components/SpaceCard.svelte
Normal file
@@ -0,0 +1,35 @@
|
||||
<script lang="ts">
|
||||
import type { Snippet } from "svelte";
|
||||
|
||||
interface Props {
|
||||
alt: string;
|
||||
imgSrc: string;
|
||||
description?: Snippet;
|
||||
}
|
||||
|
||||
const { alt, imgSrc, description }: Props = $props();
|
||||
</script>
|
||||
|
||||
<div class="card">
|
||||
<img src={imgSrc} {alt} />
|
||||
<div class="description">
|
||||
{@render description?.()}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<style>
|
||||
.card {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background-color: #38353f;
|
||||
}
|
||||
.description {
|
||||
padding: 0.5rem;
|
||||
color: #edebe9;
|
||||
font-size: 0.875rem;
|
||||
}
|
||||
img {
|
||||
width: 16rem;
|
||||
aspect-ratio: 1 / 1;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user