mirror of
https://github.com/KevinMidboe/immich.git
synced 2025-10-29 17:40:28 +00:00
refactor(web): use ImmichApi to create urls (#2435)
This commit is contained in:
@@ -1,5 +1,11 @@
|
||||
<script lang="ts">
|
||||
import { api, AssetResponseDto, SharedLinkResponseDto, SharedLinkType } from '@api';
|
||||
import {
|
||||
api,
|
||||
AssetResponseDto,
|
||||
SharedLinkResponseDto,
|
||||
SharedLinkType,
|
||||
ThumbnailFormat
|
||||
} from '@api';
|
||||
import LoadingSpinner from '../shared-components/loading-spinner.svelte';
|
||||
import OpenInNew from 'svelte-material-icons/OpenInNew.svelte';
|
||||
import Delete from 'svelte-material-icons/TrashCanOutline.svelte';
|
||||
@@ -69,7 +75,7 @@
|
||||
{:then asset}
|
||||
<img
|
||||
id={asset.id}
|
||||
src={`/api/asset/thumbnail/${asset.id}?format=WEBP`}
|
||||
src={api.getAssetThumbnailUrl(asset.id, ThumbnailFormat.Webp)}
|
||||
alt={asset.id}
|
||||
class="object-cover w-[100px] h-[100px] rounded-lg"
|
||||
loading="lazy"
|
||||
|
||||
Reference in New Issue
Block a user