mirror of
https://github.com/immich-app/immich
synced 2025-10-17 18:19:27 +00:00
feat(web): manual stacking asset (#4650)
Co-authored-by: shalong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
This commit is contained in:
parent
72dcde9e0f
commit
8b5b6d0821
22 changed files with 437 additions and 82 deletions
|
|
@ -10,6 +10,7 @@
|
|||
|
||||
export let asset: AssetResponseDto;
|
||||
export let element: HTMLDivElement | undefined = undefined;
|
||||
export let haveFadeTransition = true;
|
||||
|
||||
let imgElement: HTMLDivElement;
|
||||
let assetData: string;
|
||||
|
|
@ -116,7 +117,7 @@
|
|||
|
||||
<div
|
||||
bind:this={element}
|
||||
transition:fade={{ duration: 150 }}
|
||||
transition:fade={{ duration: haveFadeTransition ? 150 : 0 }}
|
||||
class="flex h-full select-none place-content-center place-items-center"
|
||||
>
|
||||
{#await loadAssetData({ loadOriginal: false })}
|
||||
|
|
@ -124,7 +125,7 @@
|
|||
{:then}
|
||||
<div bind:this={imgElement} class="h-full w-full">
|
||||
<img
|
||||
transition:fade={{ duration: 150 }}
|
||||
transition:fade={{ duration: haveFadeTransition ? 150 : 0 }}
|
||||
src={assetData}
|
||||
alt={asset.id}
|
||||
class="h-full w-full object-contain"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue