Fix enhancement issues: i18n tabs, misleading AI label, unused deps#5229
Fix enhancement issues: i18n tabs, misleading AI label, unused deps#5229clubanderson merged 3 commits intomainfrom
Conversation
Add useTranslation() and use t() for Install, Uninstall, Update/Upgrade, and Troubleshooting tab labels and empty-state messages. Add corresponding translation keys under missions.detail.tabs in common.json. Signed-off-by: Andrew Anderson <andy@clubanderson.com>
The "AI-Powered Creation" tab in ReplaceCardModal uses keyword matching, not AI. Rename to "Smart Suggestions" with honest description, replace Sparkles icon with Lightbulb to avoid implying AI capabilities. Signed-off-by: Andrew Anderson <andy@clubanderson.com>
…mpiler (#5196) React Compiler was disabled but these dependencies remained. Remove both react-compiler-runtime (dependency) and babel-plugin-react-compiler (devDependency) since they are no longer used. Signed-off-by: Andrew Anderson <andy@clubanderson.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
✅ Deploy Preview for kubestellarconsole ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
👋 Hey @clubanderson — thanks for opening this PR!
This is an automated message. |
|
Thank you for your contribution! Your PR has been merged. Check out what's new:
Stay connected: Slack #kubestellar-dev | Multi-Cluster Survey |
|
Post-merge build verification passed ✅ Both Go and frontend builds compiled successfully against merge commit |
There was a problem hiding this comment.
Pull request overview
This PR addresses a set of UX/maintenance cleanup items in the web console: internationalizing Mission detail tab labels, removing “AI” branding from a keyword-matching suggestion flow, and dropping unused React Compiler dependencies.
Changes:
- Internationalized
MissionDetailViewtab labels/empty states viauseTranslation()and newmissions.detail.tabs.*keys. - Renamed the Replace Card modal “AI-Powered” UI to “Smart Suggestions”, swapped the icon, and updated related copy/labels.
- Removed unused
react-compiler-runtimeandbabel-plugin-react-compilerfromwebdependencies (and updated lockfile).
Reviewed changes
Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| web/src/locales/en/common.json | Adds missions.detail.tabs.* keys and updates Replace Card modal strings to “Smart Suggestions” wording. |
| web/src/components/missions/MissionDetailView.tsx | Replaces hardcoded tab labels/empty messages with i18n t() calls. |
| web/src/components/dashboard/ReplaceCardModal.tsx | Rebrands the “AI” tab UI to “Smart Suggestions” and replaces Sparkles with Lightbulb. |
| web/package.json | Removes unused React Compiler-related dependencies. |
| web/package-lock.json | Removes corresponding lockfile entries for the removed packages. |
Files not reviewed (1)
- web/package-lock.json: Language not supported
| const tabs: TabDef[] = [ | ||
| { | ||
| id: 'install', | ||
| label: 'Install', | ||
| label: t('missions.detail.tabs.install'), | ||
| icon: Download, |
There was a problem hiding this comment.
This PR updates the tab labels to use i18n, but MissionDetailView still contains several other user-facing strings hardcoded in English (e.g., "Back to listing", "Preview"/"View Raw", "Improve", default importLabel="Import", etc.). If the intent is to close #5216 (i18n bypass), those strings should also be routed through t() (and added to common.json), or the issue/PR description should be adjusted so we don’t mark the i18n work as complete prematurely.
| const handleAIGenerate = async () => { | ||
| if (!nlPrompt.trim()) return | ||
| setIsProcessing(true) | ||
| setAiSuggestion(null) | ||
|
|
||
| // Simulate AI processing | ||
| // Simulate processing delay for keyword matching | ||
| await new Promise((resolve) => setTimeout(resolve, NAV_AFTER_ANIMATION_MS)) |
There was a problem hiding this comment.
The UI is now labeled "Smart Suggestions" and the implementation is explicitly keyword matching, but the internal API still uses AI-centric names (handleAIGenerate, aiSuggestion, tab id 'ai', etc.). Renaming these identifiers to reflect the actual behavior would reduce confusion and make future maintenance (e.g., adding a real AI path later) less error-prone.
🔄 Auto-Applying Copilot Code ReviewCopilot code review found 0 code suggestion(s) and 2 general comment(s). Also address these general comments:
Push all fixes in a single commit. Run Auto-generated by copilot-review-apply workflow. |
✅ Post-Merge Verification: passedCommit: |
Summary
useTranslation()toMissionDetailView.tsxand replace hardcoded English tab labels (Install, Uninstall, Update/Upgrade, Troubleshooting) witht()calls. Added translation keys undermissions.detail.tabsincommon.json.ReplaceCardModal.tsx. ReplaceSparklesicon withLightbulbsince the feature uses keyword matching, not AI. Updated translation keys accordingly.react-compiler-runtime(dependency) andbabel-plugin-react-compiler(devDependency) frompackage.jsonsince React Compiler was disabled.Closes #5216
Closes #5200
Closes #5196
Closes #5211
Test plan
npm run buildpasses