Modern Docker Management, Designed for Everyone
Go composecontainer-managementcontainersdockerdocker-composedocker-managementgoself-hostedsveltekittypescriptweb-ui
fix: date locale cant be loaded from date-fns if locale is en
Kyle Mendell947655c30dd9
diff --git a/frontend/src/lib/utils/locale.util.ts b/frontend/src/lib/utils/locale.util.tsindex efa1ddffe..bc3eb1326 100644--- a/frontend/src/lib/utils/locale.util.ts+++ b/frontend/src/lib/utils/locale.util.ts@@ -3,9 +3,14 @@ import { setDefaultOptions } from 'date-fns';import { z } from 'zod/v4';export async function setLocale(locale: Locale, reload = true) {+ let dateFnsLocale: string = locale;+ if (dateFnsLocale === 'en') {+ dateFnsLocale = 'en-US';+ }+const [zodResult, dateFnsResult] = await Promise.allSettled([import(`../../../node_modules/zod/v4/locales/${locale}.js`),- import(`../../../node_modules/date-fns/locale/${locale}.js`)+ import(`../../../node_modules/date-fns/locale/${dateFnsLocale}.js`)]);if (zodResult.status === 'fulfilled') {