i18n: translate popup home view strings#336
Open
pooyak wants to merge 1 commit into
Open
Conversation
The popup home view had inline Chinese strings in the Vue template and a few script callsites, so the popup rendered in Chinese for users whose browser locale resolved to en (or anything other than zh_CN) even though _locales/en already existed and the rest of the home view was already wired through getMessage(). Replace the hardcoded text with getMessage() calls and add the matching keys to _locales/en, _locales/zh_CN, and the fallback map in utils/i18n.ts. Touched strings: - Section titles: Quick Tools, Management - Quick-tools tooltips: recording-coming-soon, page-edit, element-marker - Management entries: AI Assistant, Workflow Management, Element Marker Management, Local Model (titles + descriptions) - Coming-soon toast template (now placeholder-substituted with the feature name) and the two recording-flow callers + workflow caller that previously passed Chinese feature names directly. Scope is limited to entrypoints/popup/App.vue. Sibling components (LocalModelPage, ScheduleDialog, sidepanel, builder, web-editor) still contain inline Chinese; those are left for follow-up PRs to keep this diff reviewable.
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
The popup home view had inline Chinese strings in
entrypoints/popup/App.vue(template + a few script callsites), so the popup rendered in Chinese for users whose browser UI locale resolves to anything other thanzh_CN, even though_locales/en/messages.jsonalready exists and most of the same view is already wired throughgetMessage().This PR threads the remaining popup strings through the existing i18n pipeline. No new infrastructure — just replaces hardcoded text with
getMessage()calls and registers the keys.Changes
entrypoints/popup/App.vueQuick Tools,ManagementcomingSoonMessagewith$FEATURE$placeholder; the three callers (startRecording,stopRecording,openWorkflowSidepanel) pass localized feature names instead of literal Chinese strings_locales/en/messages.json,_locales/zh_CN/messages.json— 15 new keys (descriptions included)utils/i18n.ts— corresponding English entries in thefallbackMessagesmapScope
Intentionally limited to
entrypoints/popup/App.vue. Sibling components (LocalModelPage.vue,ScheduleDialog.vue, sidepanel, builder, web-editor-v2) still have inline Chinese and can follow in separate PRs to keep this diff reviewable.Test plan
prettier --check— cleaneslint— cleanvue-tsc --noEmit— no new errors introduced (one pre-existingTS2322on L287@switch-modelexists onmasterand is unrelated)🤖 Generated with Claude Code