feat: add Russian localization and independent STT languages
CI / Typecheck, tests, lint (push) Canceled after 0s
CI / Standalone (mac-arm64) (push) Canceled after 0s
CI / Standalone (linux-x64) (push) Canceled after 0s
CI / Standalone (windows-x64) (push) Canceled after 0s

This commit is contained in:
2026-10-25 17:18:44 +03:00
parent b277ee3e0f
commit a50ca4b867
93 changed files with 3261 additions and 904 deletions
+9
View File
@@ -0,0 +1,9 @@
import { resolveLanguage, type Language } from "../core/i18n.ts";
import { stores } from "./stores.ts";
/** Explicit app preference wins; automatic follow-ups retain the foreground browser's language. */
export function applicationLanguage(system?: string | null): Language {
return resolveLanguage(stores.settingsStore.readSettings()?.general?.language, system ?? process.env.LH_SYSTEM_LANGUAGE ?? Intl.DateTimeFormat().resolvedOptions().locale);
}
export function chatLanguage(chatId: string): Language {
return applicationLanguage(stores.chatStore.getChat(chatId)?.language);
}