diff --git a/client/src/i18n.tsx b/client/src/i18n.tsx index 6ab704e..230cff1 100644 --- a/client/src/i18n.tsx +++ b/client/src/i18n.tsx @@ -3,16 +3,16 @@ import { negotiateLanguages } from "@fluent/langneg"; import { createContext, createMemo, createSignal, useContext, type ParentProps } from "solid-js"; // Included in bundle even if translation is not not used. This is fine for now but needs to be changed in the future. -import deFtl from "./locales/de.ftl?raw"; -import enFtl from "./locales/en.ftl?raw"; +import deFtl from "./locales/de-DE.ftl?raw"; +import enFtl from "./locales/en-US.ftl?raw"; const MESSAGES: Record = { - en: enFtl, - de: deFtl, + "en-US": enFtl, + "de-DE": deFtl, }; -const SUPPORTED_LOCALES = ["en", "de"] as const; -const DEFAULT_LOCALE = "en"; +const SUPPORTED_LOCALES = ["en-US", "de-DE"] as const; +const DEFAULT_LOCALE = "en-US"; function createBundle(locale: string): FluentBundle { const bundle = new FluentBundle(locale); diff --git a/client/src/locales/de.ftl b/client/src/locales/de-DE.ftl similarity index 100% rename from client/src/locales/de.ftl rename to client/src/locales/de-DE.ftl diff --git a/client/src/locales/en.ftl b/client/src/locales/en-US.ftl similarity index 100% rename from client/src/locales/en.ftl rename to client/src/locales/en-US.ftl