fix(i18n): localize application workflows
Use stable checklist and interview keys for system copy while preserving user-authored content. Localize creation-tab errors, language selectors, match bands, dates, and selected-CV context.
This commit is contained in:
@@ -11,7 +11,7 @@ import ArrowDownwardIcon from "@mui/icons-material/ArrowDownward";
|
||||
import { getApiErrorMessage } from "../api";
|
||||
import { useI18n } from "../i18n/I18nProvider";
|
||||
import {
|
||||
CHECKLIST_CATEGORIES, Checklist, ChecklistItem, applicationChecklistApi,
|
||||
CHECKLIST_CATEGORIES, Checklist, ChecklistItem, applicationChecklistApi, checklistSystemTranslationToken,
|
||||
} from "../applicationWorkspace";
|
||||
|
||||
// Phase 5 Milestone 2 — the application checklist.
|
||||
@@ -214,8 +214,8 @@ function checklistCategoryLabel(t: (key: any, vars?: Record<string, string | num
|
||||
}
|
||||
|
||||
function checklistItemDisplay(t: (key: any, vars?: Record<string, string | number>) => string, item: ChecklistItem) {
|
||||
if (!item.systemKey || item.systemKey.startsWith("learning:")) return { title: item.title, description: item.description };
|
||||
const token = item.systemKey.replace(/-([a-z])/g, (_, letter: string) => letter.toUpperCase());
|
||||
const token = checklistSystemTranslationToken(item.systemKey);
|
||||
if (!token) return { title: item.title, description: item.description };
|
||||
return {
|
||||
title: t(`checklistItem_${token}`),
|
||||
description: t(`checklistItem_${token}Description`),
|
||||
|
||||
Reference in New Issue
Block a user