From 54bbc06bd84437c6b38e2f6c57060f21a8318720 Mon Sep 17 00:00:00 2001
From: ivarlovlie <git@ivarlovlie.no>
Date: Sun, 19 Feb 2023 14:08:33 +0100
Subject: .

---
 src/components/card-v4.svelte | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

(limited to 'src/components/card-v4.svelte')

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>
-- 
cgit v1.3

