diff --git a/messages/de.json b/messages/de.json index e3af310dc..04ac97c51 100644 --- a/messages/de.json +++ b/messages/de.json @@ -250,6 +250,16 @@ "vo2Max": "VO₂ max", "vo2MaxUnit": "mL/(kg·min)", "bpInTarget": "BD im Zielbereich", + "weightShort": "Gewicht", + "bloodPressureSysShort": "BD (Sys)", + "bloodPressureDiaShort": "BD (Dia)", + "pulseShort": "Puls", + "bodyFatShort": "KF", + "moodShort": "Stimmung", + "sleepShort": "Schlaf", + "stepsShort": "Schritte", + "vo2MaxShort": "VO₂ max", + "bpInTargetShort": "BD-Ziel", "days30Short": "30T", "medications": "Medikamente", "insightsPreview": "KI-Insights-Vorschau", @@ -2791,8 +2801,8 @@ }, "i18n": { "maintainershipBanner": { - "notice": "Diese Übersetzung wird per KI gepflegt und kann ungenau sein.", - "cta": "Hilf mit auf GitHub", + "notice": "Diese Sprachversion ist KI-entworfen, inklusive der sicherheitskritischen Coach-Anweisungen. Automatisierte Validierung läuft in CI; KI-Coach-Regressionen bitte auf GitHub melden.", + "cta": "Auf GitHub melden", "dismiss": "Schließen" } }, diff --git a/messages/en.json b/messages/en.json index ddebf6fc4..ccac34260 100644 --- a/messages/en.json +++ b/messages/en.json @@ -250,6 +250,16 @@ "vo2Max": "VO₂ max", "vo2MaxUnit": "mL/(kg·min)", "bpInTarget": "BP in Target", + "weightShort": "Weight", + "bloodPressureSysShort": "BP (Sys)", + "bloodPressureDiaShort": "BP (Dia)", + "pulseShort": "Pulse", + "bodyFatShort": "Body Fat", + "moodShort": "Mood", + "sleepShort": "Sleep", + "stepsShort": "Steps", + "vo2MaxShort": "VO₂ max", + "bpInTargetShort": "BP in Target", "days30Short": "30d", "medications": "Medications", "insightsPreview": "AI Insights preview", @@ -2791,8 +2801,8 @@ }, "i18n": { "maintainershipBanner": { - "notice": "This translation is AI-maintained and may contain inaccuracies.", - "cta": "Help out on GitHub", + "notice": "This locale is AI-drafted including the Coach's safety-critical instructions. Automated validation runs in CI; please report any AI Coach regressions on GitHub.", + "cta": "Report on GitHub", "dismiss": "Dismiss" } }, diff --git a/messages/es.json b/messages/es.json index 994717b7e..e78a4972e 100644 --- a/messages/es.json +++ b/messages/es.json @@ -250,6 +250,16 @@ "vo2Max": "VO₂ max", "vo2MaxUnit": "mL/(kg·min)", "bpInTarget": "BP in Target", + "weightShort": "Peso", + "bloodPressureSysShort": "PA (Sys)", + "bloodPressureDiaShort": "PA (Dia)", + "pulseShort": "Pulso", + "bodyFatShort": "GC", + "moodShort": "Humor", + "sleepShort": "Sueño", + "stepsShort": "Pasos", + "vo2MaxShort": "VO₂ max", + "bpInTargetShort": "PA-objetivo", "days30Short": "30d", "medications": "Medicamentos", "insightsPreview": "AI Insights preview", @@ -2791,8 +2801,8 @@ }, "i18n": { "maintainershipBanner": { - "notice": "Esta traducción está mantenida por IA y puede contener imprecisiones.", - "cta": "Ayúdanos en GitHub", + "notice": "Este idioma está redactado por IA, incluidas las instrucciones críticas para la seguridad del Coach. La validación automática se ejecuta en CI; informe de cualquier regresión del Coach IA en GitHub.", + "cta": "Informar en GitHub", "dismiss": "Cerrar" } }, diff --git a/messages/fr.json b/messages/fr.json index 5e46e71f3..46b7cde40 100644 --- a/messages/fr.json +++ b/messages/fr.json @@ -250,6 +250,16 @@ "vo2Max": "VO₂ max", "vo2MaxUnit": "mL/(kg·min)", "bpInTarget": "BP in Target", + "weightShort": "Poids", + "bloodPressureSysShort": "TA (Sys)", + "bloodPressureDiaShort": "TA (Dia)", + "pulseShort": "Pouls", + "bodyFatShort": "TG", + "moodShort": "Humeur", + "sleepShort": "Sommeil", + "stepsShort": "Pas", + "vo2MaxShort": "VO₂ max", + "bpInTargetShort": "TA-cible", "days30Short": "30d", "medications": "Médicaments", "insightsPreview": "AI Insights preview", @@ -2791,8 +2801,8 @@ }, "i18n": { "maintainershipBanner": { - "notice": "Cette traduction est maintenue par IA et peut contenir des imprécisions.", - "cta": "Aidez-nous sur GitHub", + "notice": "Cette langue est rédigée par IA, y compris les instructions critiques pour la sécurité du Coach. Une validation automatique tourne en CI ; signalez toute régression du Coach IA sur GitHub.", + "cta": "Signaler sur GitHub", "dismiss": "Ignorer" } }, diff --git a/messages/it.json b/messages/it.json index bd2b2d185..2c0310cd3 100644 --- a/messages/it.json +++ b/messages/it.json @@ -250,6 +250,16 @@ "vo2Max": "VO₂ max", "vo2MaxUnit": "mL/(kg·min)", "bpInTarget": "BP in Target", + "weightShort": "Peso", + "bloodPressureSysShort": "PA (Sys)", + "bloodPressureDiaShort": "PA (Dia)", + "pulseShort": "Polso", + "bodyFatShort": "GC", + "moodShort": "Umore", + "sleepShort": "Sonno", + "stepsShort": "Passi", + "vo2MaxShort": "VO₂ max", + "bpInTargetShort": "PA-target", "days30Short": "30d", "medications": "Farmaci", "insightsPreview": "AI Insights preview", @@ -2791,8 +2801,8 @@ }, "i18n": { "maintainershipBanner": { - "notice": "Questa traduzione è gestita tramite IA e potrebbe contenere imprecisioni.", - "cta": "Aiutaci su GitHub", + "notice": "Questa lingua è redatta tramite IA, incluse le istruzioni critiche per la sicurezza del Coach. La validazione automatica gira in CI; segnali qualsiasi regressione del Coach IA su GitHub.", + "cta": "Segnala su GitHub", "dismiss": "Chiudi" } }, diff --git a/messages/pl.json b/messages/pl.json index 8f9b1cd26..a5fa4f664 100644 --- a/messages/pl.json +++ b/messages/pl.json @@ -250,6 +250,16 @@ "vo2Max": "VO₂ max", "vo2MaxUnit": "mL/(kg·min)", "bpInTarget": "BP in Target", + "weightShort": "Waga", + "bloodPressureSysShort": "RR (Sk)", + "bloodPressureDiaShort": "RR (Rk)", + "pulseShort": "Tętno", + "bodyFatShort": "TT", + "moodShort": "Nastrój", + "sleepShort": "Sen", + "stepsShort": "Kroki", + "vo2MaxShort": "VO₂ max", + "bpInTargetShort": "RR-cel", "days30Short": "30d", "medications": "Leki", "insightsPreview": "AI Insights preview", @@ -2791,8 +2801,8 @@ }, "i18n": { "maintainershipBanner": { - "notice": "To tłumaczenie jest utrzymywane przez AI i może zawierać nieścisłości.", - "cta": "Pomóż na GitHubie", + "notice": "Ta wersja językowa jest opracowana przez AI, w tym instrukcje krytyczne dla bezpieczeństwa Coacha. Walidacja automatyczna działa w CI; proszę zgłaszać wszelkie regresje Coacha AI na GitHubie.", + "cta": "Zgłoś na GitHubie", "dismiss": "Zamknij" } }, diff --git a/src/components/i18n/__tests__/maintainership-banner.test.tsx b/src/components/i18n/__tests__/maintainership-banner.test.tsx index 016c4ff47..ad6f63f4b 100644 --- a/src/components/i18n/__tests__/maintainership-banner.test.tsx +++ b/src/components/i18n/__tests__/maintainership-banner.test.tsx @@ -82,4 +82,45 @@ describe("", () => { expect(cfg.isMaintainedLocale("it")).toBe(false); expect(cfg.isMaintainedLocale("pl")).toBe(false); }); + + // v1.4.25 W14c — banner copy upgraded to acknowledge that the + // FR/ES/IT/PL Coach prompts are AI-drafted including safety-critical + // instructions. Pin the new wording so a copy regression cannot + // quietly soften the disclosure. + it("EN banner copy names safety-critical AI-drafted Coach content", async () => { + const { readFileSync } = await import("node:fs"); + const { join } = await import("node:path"); + const en = JSON.parse( + readFileSync(join(process.cwd(), "messages", "en.json"), "utf8"), + ) as { i18n: { maintainershipBanner: { notice: string } } }; + const notice = en.i18n.maintainershipBanner.notice; + expect(notice).toMatch(/AI-drafted/); + expect(notice).toMatch(/safety-critical/); + expect(notice).toMatch(/GitHub/); + expect(notice).toMatch(/Coach/); + }); + + it("every AI-initial locale's banner notice acknowledges the AI-drafted Coach content", async () => { + const { readFileSync } = await import("node:fs"); + const { join } = await import("node:path"); + const aiDraftPatterns: Record = { + fr: /rédigée par IA/, + es: /redactado por IA/, + it: /redatta tramite IA/, + pl: /opracowana przez AI/, + }; + for (const [locale, pattern] of Object.entries(aiDraftPatterns)) { + const data = JSON.parse( + readFileSync( + join(process.cwd(), "messages", `${locale}.json`), + "utf8", + ), + ) as { i18n: { maintainershipBanner: { notice: string } } }; + const notice = data.i18n.maintainershipBanner.notice; + expect(notice, `${locale} banner notice`).toMatch(pattern); + expect(notice, `${locale} banner notice mentions Coach`).toMatch( + /Coach/, + ); + } + }); });