From fc47ae81b5983c8f8555f8070a84be2172a0afbd Mon Sep 17 00:00:00 2001 From: ghostubborn Date: Wed, 1 Apr 2026 15:43:11 +0800 Subject: [PATCH] feat(i18n): replace hardcoded Chinese in frontend components with i18n calls Replace all user-visible hardcoded Chinese strings in 7 component files with $t() / t() calls using vue-i18n: - Step1GraphBuild: ontology generation, graph build, status badges - Step2EnvSetup: simulation setup, agent personas, platform config, time config, initial activation, modal profile details - Step3Simulation: report generation button - Step4Report: section loading text, interaction button - Step5Interaction: chat interface, survey UI, tool descriptions, error messages, agent selection - GraphPanel: graph status hints, loading states, tooltips - HistoryDatabase: history cards, modal, replay buttons Added missing translation keys to both zh.json and en.json locale files. Added useI18n imports to components that need script-level translations. --- frontend/src/components/GraphPanel.vue | 18 +- frontend/src/components/HistoryDatabase.vue | 42 ++-- frontend/src/components/Step1GraphBuild.vue | 40 ++-- frontend/src/components/Step2EnvSetup.vue | 201 ++++++++++--------- frontend/src/components/Step3Simulation.vue | 11 +- frontend/src/components/Step4Report.vue | 4 +- frontend/src/components/Step5Interaction.vue | 93 ++++----- locales/en.json | 26 ++- locales/zh.json | 26 ++- 9 files changed, 253 insertions(+), 208 deletions(-) diff --git a/frontend/src/components/GraphPanel.vue b/frontend/src/components/GraphPanel.vue index 314c966e..db188298 100644 --- a/frontend/src/components/GraphPanel.vue +++ b/frontend/src/components/GraphPanel.vue @@ -1,14 +1,14 @@