1
0
mirror of https://github.com/immich-app/immich.git synced 2025-06-24 04:46:50 +02:00

feat(web): more localized number formatting (#11401)

This commit is contained in:
Michel Heusschen
2024-07-29 16:38:27 +02:00
committed by GitHub
parent 2e059bfbfd
commit 0237f9baa3
10 changed files with 44 additions and 19 deletions

View File

@ -38,6 +38,7 @@
import { tweened } from 'svelte/motion';
import { fade } from 'svelte/transition';
import { t } from 'svelte-i18n';
import { locale } from '$lib/stores/preferences.store';
const parseIndex = (s: string | null, max: number | null) =>
Math.max(Math.min(Number.parseInt(s ?? '') || 0, max ?? 0), 0);
@ -201,7 +202,7 @@
<div>
<p class="text-small">
{assetIndex + 1}/{currentMemory.assets.length}
{(assetIndex + 1).toLocaleString($locale)}/{currentMemory.assets.length.toLocaleString($locale)}
</p>
</div>
</div>