diff options
| author | ivarlovlie <git@ivarlovlie.no> | 2023-02-19 14:08:33 +0100 |
|---|---|---|
| committer | ivarlovlie <git@ivarlovlie.no> | 2023-02-19 14:08:33 +0100 |
| commit | 54bbc06bd84437c6b38e2f6c57060f21a8318720 (patch) | |
| tree | a0f9beb425829e304cdf239709e7d23a13b0fcc8 /src/components/card-v4.svelte | |
| parent | 06ce8fbab52c5c25a67a1518f1888b083b5edde3 (diff) | |
| download | auroraklinikken.no-54bbc06bd84437c6b38e2f6c57060f21a8318720.tar.xz auroraklinikken.no-54bbc06bd84437c6b38e2f6c57060f21a8318720.zip | |
.
Diffstat (limited to 'src/components/card-v4.svelte')
| -rw-r--r-- | src/components/card-v4.svelte | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/components/card-v4.svelte b/src/components/card-v4.svelte index d067357..ff35492 100644 --- a/src/components/card-v4.svelte +++ b/src/components/card-v4.svelte @@ -1,13 +1,20 @@ <script lang="ts"> - export let title; - export let description; + import { PortableText } from "@portabletext/svelte"; + import type { InputValue } from "@portabletext/svelte/ptTypes"; + + export let title: string | undefined; + export let description: string | undefined | InputValue; </script> <div class="card"> <div class="p-6"> - <h3 class="mt-0">I have a dream</h3> + <h3 class="mt-0">{title}</h3> <p class="text-contrast-medium mt-3 mx-0 mb-4"> - Lorem ipsum dolor, sit amet consectetur adipisicing elit. Quia minus culpa commodi. + {#if typeof description === "string"} + {description} + {:else} + <PortableText value={description} /> + {/if} </p> <div class="flex flex-wrap gap-3"> <a href="#0" class="btn btn--subtle">Learn more</a> |
