fix(admin): i18n all hardcoded OCR strings, fix personName lookup, add empty state
Some checks failed
CI / Unit & Component Tests (push) Failing after 3m17s
CI / OCR Service Tests (push) Successful in 57s
CI / Backend Unit Tests (push) Failing after 2m52s
CI / Unit & Component Tests (pull_request) Failing after 2m47s
CI / OCR Service Tests (pull_request) Successful in 43s
CI / Backend Unit Tests (pull_request) Failing after 2m48s

- Replace hardcoded EN strings in OcrHealthBar/OcrStatCards/OcrModelsTable with
  Paraglide message keys (de/en/es translations added)
- Add role=img + aria-label to OcrHealthBar status dot
- Add {:else} empty-state row in OcrModelsTable
- Fix personName derivation in [personId]/+page.svelte to use params.personId key
  instead of Object.values()[0] (fragile when multiple persons present)
- Update OcrModelsTable spec to assert empty-state row structure (locale-agnostic)
- Add missing availableSegBlocks test to OcrStatCards spec

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Marcel
2026-04-18 08:59:49 +02:00
parent b879d28761
commit a00617194c
11 changed files with 100 additions and 21 deletions

View File

@@ -300,6 +300,22 @@
"history_field_tags": "Schlagworte",
"admin_tab_system": "System",
"admin_tab_ocr": "OCR",
"ocr_status_online": "Online",
"ocr_status_offline": "Offline",
"ocr_stat_training_blocks": "Trainingsblöcke",
"ocr_stat_total_blocks": "Gesamt Blöcke",
"ocr_stat_documents": "Dokumente",
"ocr_stat_seg_blocks": "Seg.-Blöcke",
"ocr_table_person": "Person",
"ocr_table_cer": "ZFR",
"ocr_table_accuracy": "Genauigkeit",
"ocr_table_lines": "Zeilen",
"ocr_table_actions": "Aktionen",
"ocr_table_details": "Details",
"ocr_no_models": "Noch keine Sender-Modelle trainiert.",
"ocr_sender_models_heading": "Sender-Modelle",
"ocr_global_history_link": "Globaler Verlauf →",
"ocr_global_history_heading": "Globaler Verlauf",
"admin_system_backfill_heading": "Verlaufsdaten auffüllen",
"admin_system_backfill_description": "Erstellt einen initialen Verlaufseintrag für alle Dokumente, die noch keinen Verlauf haben (z.B. importierte Dokumente). Dadurch werden beim nächsten Bearbeiten nur die tatsächlich geänderten Felder hervorgehoben.",
"admin_system_backfill_btn": "Jetzt auffüllen",