summaryrefslogtreecommitdiffhomepage
path: root/src/lib/components/ImageList.svelte
diff options
context:
space:
mode:
authorAdam Malczewski <[email protected]>2026-04-09 19:28:44 +0900
committerAdam Malczewski <[email protected]>2026-04-09 19:28:44 +0900
commit1bfd3e50842fdd511fc89d2b5892f8d440914cca (patch)
treee8fec173a185b91ef28681e8e7030cae46bd37ee /src/lib/components/ImageList.svelte
parent2a8ecc585f6dc5c3c5f98ba3821d899807d813f8 (diff)
downloadflashair-speedsync-1bfd3e50842fdd511fc89d2b5892f8d440914cca.tar.gz
flashair-speedsync-1bfd3e50842fdd511fc89d2b5892f8d440914cca.zip
caching of images
Diffstat (limited to 'src/lib/components/ImageList.svelte')
-rw-r--r--src/lib/components/ImageList.svelte8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/lib/components/ImageList.svelte b/src/lib/components/ImageList.svelte
index f338670..532cd3b 100644
--- a/src/lib/components/ImageList.svelte
+++ b/src/lib/components/ImageList.svelte
@@ -1,6 +1,7 @@
<script lang="ts">
import { flashair } from '../flashair';
import type { FlashAirFileEntry } from '../flashair';
+ import CachedThumbnail from './CachedThumbnail.svelte';
interface Props {
images: FlashAirFileEntry[];
@@ -29,12 +30,7 @@
onclick={() => onSelect(file)}
>
{#if thumbUrl}
- <img
- src={thumbUrl}
- alt={file.filename}
- class="w-full aspect-square rounded object-cover"
- loading="lazy"
- />
+ <CachedThumbnail path={file.path} alt={file.filename} />
{:else}
<div class="w-full aspect-square rounded bg-base-300 flex items-center justify-center">
<span class="text-lg">🖼️</span>