mirror of
https://github.com/immich-app/immich.git
synced 2025-11-03 11:07:10 -05:00
fix(web): show upload speed (#23138)
* remove unnecessary else * Better fix * fix: update text color * chore: stylings --------- Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
This commit is contained in:
parent
446f738c7d
commit
cd8d66f5dd
@ -40,7 +40,11 @@
|
|||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div in:fade={{ duration: 250 }} out:fade={{ duration: 100 }} class="flex flex-col rounded-lg text-xs p-2 gap-1">
|
<div
|
||||||
|
in:fade={{ duration: 250 }}
|
||||||
|
out:fade={{ duration: 100 }}
|
||||||
|
class="flex flex-col rounded-xl text-xs p-2 gap-1 border border-gray-300 dark:border-subtle bg-primary/10"
|
||||||
|
>
|
||||||
<div class="flex items-center gap-2">
|
<div class="flex items-center gap-2">
|
||||||
<div class="flex items-center justify-center">
|
<div class="flex items-center justify-center">
|
||||||
{#if uploadAsset.state === UploadState.PENDING}
|
{#if uploadAsset.state === UploadState.PENDING}
|
||||||
@ -91,12 +95,13 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{#if uploadAsset.state === UploadState.STARTED}
|
{#if uploadAsset.state === UploadState.STARTED}
|
||||||
<div class="text-black relative mt-[5px] h-[15px] w-full rounded-md bg-gray-300 dark:bg-gray-700">
|
<div class="text-black relative mt-[5px] h-[18px] w-full rounded-md bg-gray-300 dark:bg-gray-700">
|
||||||
<div class="h-[15px] rounded-md bg-immich-primary transition-all" style={`width: ${uploadAsset.progress}%`}></div>
|
<div class="h-[18px] rounded-md bg-immich-primary transition-all" style={`width: ${uploadAsset.progress}%`}></div>
|
||||||
<p class="absolute top-0 h-full w-full text-center text-primary text-[10px]">
|
<p class="absolute top-0.5 h-full w-full text-center text-white text-[10px]">
|
||||||
{#if uploadAsset.message}
|
{#if uploadAsset.message === $t('asset_hashing')}
|
||||||
{uploadAsset.message}
|
{uploadAsset.message}
|
||||||
{:else}
|
{:else}
|
||||||
|
{uploadAsset.message}
|
||||||
{uploadAsset.progress}% - {getByteUnitString(uploadAsset.speed || 0, $locale)}/s - {uploadAsset.eta}s
|
{uploadAsset.progress}% - {getByteUnitString(uploadAsset.speed || 0, $locale)}/s - {uploadAsset.eta}s
|
||||||
{/if}
|
{/if}
|
||||||
</p>
|
</p>
|
||||||
|
|||||||
@ -52,7 +52,7 @@
|
|||||||
{#if showDetail}
|
{#if showDetail}
|
||||||
<div
|
<div
|
||||||
in:scale={{ duration: 250, easing: quartInOut }}
|
in:scale={{ duration: 250, easing: quartInOut }}
|
||||||
class="w-[300px] rounded-lg border bg-gray-100 p-4 text-sm shadow-sm dark:border-immich-dark-gray dark:bg-immich-dark-gray dark:text-white"
|
class="w-[325px] rounded-xl border border-gray-200 dark:border-subtle p-4 text-sm shadow-xs bg-subtle"
|
||||||
>
|
>
|
||||||
<div class="place-item-center mb-4 flex justify-between">
|
<div class="place-item-center mb-4 flex justify-between">
|
||||||
<div class="flex flex-col gap-1">
|
<div class="flex flex-col gap-1">
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user