electron menu translation WIP

This commit is contained in:
SPRINX0\prochazka
2025-11-18 09:20:56 +01:00
parent 6e439adb51
commit 7bb9414be8
4 changed files with 35 additions and 7 deletions

View File

@@ -58,6 +58,11 @@ function getTranslation(key: string, defaultMessage: string, language: string) {
return translation;
}
export function getCurrentTranslations(): Record<string, string> {
const selectedLanguage = getSelectedLanguage();
return translations[selectedLanguage] || {};
}
export function _t(key: string, options: TranslateOptions): string {
const { defaultMessage, values } = options;