From bce557cc2dc767628bed6aac87301a1be7c5431b Mon Sep 17 00:00:00 2001
From: rxliuli <rxliuli@gmail.com>
Date: Tue, 4 Nov 2025 05:03:50 +0800
Subject: init commit

---
 .../jet/today-card/TodayCardMedia.svelte           | 49 ++++++++++++++++++++++
 1 file changed, 49 insertions(+)
 create mode 100644 src/components/jet/today-card/TodayCardMedia.svelte

(limited to 'src/components/jet/today-card/TodayCardMedia.svelte')

diff --git a/src/components/jet/today-card/TodayCardMedia.svelte b/src/components/jet/today-card/TodayCardMedia.svelte
new file mode 100644
index 0000000..99f444f
--- /dev/null
+++ b/src/components/jet/today-card/TodayCardMedia.svelte
@@ -0,0 +1,49 @@
+<script lang="ts">
+    import type { TodayCardMedia } from '@jet-app/app-store/api/models';
+
+    import type { Profile } from '~/components/Artwork.svelte';
+    import TodayCardMediaAppEvent, {
+        isTodayCardMediaAppEvent,
+    } from '~/components/jet/today-card/media/TodayCardMediaAppEvent.svelte';
+    import TodayCardMediaAppIcon, {
+        isTodayCardMediAppIcon,
+    } from '~/components/jet/today-card/media/TodayCardMediaAppIcon.svelte';
+    import TodayCardMediaBrandedSingleApp, {
+        isTodayCardMediaBrandedSingleApp,
+    } from '~/components/jet/today-card/media/TodayCardMediaBrandedSingleApp.svelte';
+    import TodayCardMediaList, {
+        isTodayCardMediaList,
+    } from '~/components/jet/today-card/media/TodayCardMediaList.svelte';
+    import TodayCardMediaRiver, {
+        isTodayCardMediaRiver,
+    } from '~/components/jet/today-card/media/TodayCardMediaRiver.svelte';
+    import TodayCardMediaWithArtwork, {
+        isTodayCardMediaWithArtwork,
+    } from '~/components/jet/today-card/media/TodayCardMediaWithArtwork.svelte';
+    import TodayCardMediaVideo, {
+        isTodayCardMediaVideo,
+    } from '~/components/jet/today-card/media/TodayCardMediaVideo.svelte';
+
+    export let media: TodayCardMedia;
+
+    /**
+     * A `Profile` to override the default for the card's media
+     */
+    export let artworkProfile: Profile | undefined = undefined;
+</script>
+
+{#if isTodayCardMediaAppEvent(media)}
+    <TodayCardMediaAppEvent {media} {artworkProfile} />
+{:else if isTodayCardMediAppIcon(media)}
+    <TodayCardMediaAppIcon {media} />
+{:else if isTodayCardMediaBrandedSingleApp(media)}
+    <TodayCardMediaBrandedSingleApp {media} {artworkProfile} />
+{:else if isTodayCardMediaList(media)}
+    <TodayCardMediaList {media} />
+{:else if isTodayCardMediaWithArtwork(media)}
+    <TodayCardMediaWithArtwork {media} {artworkProfile} />
+{:else if isTodayCardMediaRiver(media)}
+    <TodayCardMediaRiver {media} />
+{:else if isTodayCardMediaVideo(media)}
+    <TodayCardMediaVideo {media} {artworkProfile} />
+{/if}
-- 
cgit v1.2.3

