diff --git a/AppImage/messages/en/common.json b/AppImage/messages/en/common.json index 51ca198d..0853f5d7 100644 --- a/AppImage/messages/en/common.json +++ b/AppImage/messages/en/common.json @@ -1981,7 +1981,10 @@ "systemHostname": "System hostname", "displayNameHint": "Name shown in notifications. Edit it or leave it empty to use the system hostname.", "activeFooter": "Notifications are active. Each channel follows its own category and event selection.", - "inactiveFooter": "Enable notifications to receive system, health and security alerts through the configured channels." + "inactiveFooter": "Enable notifications to receive system, health and security alerts through the configured channels.", + "notificationLanguage": "Notification language", + "selectNotificationLanguage": "Select notification language", + "notificationLanguageHint": "Used for deterministic runtime notifications even when AI is disabled." }, "ai": { "title": "AI enhancement", diff --git a/AppImage/messages/sk/common.json b/AppImage/messages/sk/common.json index 99c0c97f..177e87fc 100644 --- a/AppImage/messages/sk/common.json +++ b/AppImage/messages/sk/common.json @@ -1981,7 +1981,10 @@ "systemHostname": "Názov systému", "displayNameHint": "Meno zobrazené v notifikáciách. Upravte ho alebo nechajte prázdne a použije sa názov systému.", "activeFooter": "Notifikácie sú aktívne. Každý kanál posiela udalosti podľa vlastného výberu kategórií.", - "inactiveFooter": "Zapnite notifikácie a dostávajte upozornenia o systéme, stave a bezpečnosti cez nastavené kanály." + "inactiveFooter": "Zapnite notifikácie a dostávajte upozornenia o systéme, stave a bezpečnosti cez nastavené kanály.", + "notificationLanguage": "Jazyk notifikácií", + "selectNotificationLanguage": "Vyberte jazyk notifikácií", + "notificationLanguageHint": "Používa sa pre spoľahlivé runtime notifikácie aj vtedy, keď je AI vypnutá." }, "ai": { "title": "AI vylepšenie", diff --git a/AppImage/scripts/tests/test_notification_runtime_i18n.py b/AppImage/scripts/tests/test_notification_runtime_i18n.py index db3e4d5a..b7dd1922 100644 --- a/AppImage/scripts/tests/test_notification_runtime_i18n.py +++ b/AppImage/scripts/tests/test_notification_runtime_i18n.py @@ -70,6 +70,21 @@ class RuntimeCatalogTests(unittest.TestCase): for key in en: self.assertEqual(_placeholders(sk[key]), _placeholders(en[key]), key) + def test_notification_language_ui_keys_exist_in_both_catalogs(self): + required = { + "notificationLanguage", + "selectNotificationLanguage", + "notificationLanguageHint", + } + for language in ("en", "sk"): + path = APPIMAGE_DIR / "messages" / language / "common.json" + common = json.loads(path.read_text(encoding="utf-8")) + ui = common["settings"]["notifications"]["ui"] + self.assertTrue(required.issubset(ui), language) + for key in required: + self.assertIsInstance(ui[key], str) + self.assertTrue(ui[key].strip(), f"{language}:{key}") + def test_slovak_catalog_preserves_placeholders_and_translates_static_text(self): en = self.catalogs["en"]["templates"] sk = self.catalogs["sk"]["templates"]