feat(i18n): localize Heuristic Manager page and fix runtime errors in… #1458
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.



FIXES #1294
🧾 Summary
This PR completes full internationalization (i18n) of the Heuristic Manager page and all its sub-components. In addition to replacing hardcoded strings with translation keys, it resolves multiple runtime and linting issues uncovered during the localization process.
✨ Key Changes
🧩 Heuristic Manager Localization
• Replaced all hardcoded UI strings with i18n keys in:
• ManagerView.vue
• StudyOverview
• RecentActivity
• CooperatorsInfo
• HeuristicsInfo
• StorageInfo
• UsabilityResults
• FinalReportStatus
🌐 Locale File Enhancements
• Added missing Dashboard-related keys (cards, managerView, stats) to all 10 supported locale files.
• Introduced a new common.units namespace to localize storage units (MB / GB).
• Resolved duplicate pages.sessions keys across multiple locale files to fix ESLint warnings and ensure structural consistency.
🔁 Dynamic Localization Logic
• RecentActivity.vue
• Implemented dynamic date-fns locale mapping so relative time strings (e.g. “2 days ago”) match the active language.
• FinalReportStatus.vue
• Updated date formatting to follow locale-specific user conventions.
• StorageInfo.vue
• Localized storage capacity units using shared i18n keys.
🐛 Bug Fixes
• Fixed runtime errors:
• ReferenceError: useRouter is not defined
• ReferenceError: useI18n is not defined
• Added missing imports to affected localized components.
🗂 Files Touched
• ManagerView.vue
• Heuristic Manager sub-components
• src/app/plugins/locales/*.json
✅ Verification
• Language Coverage: Verified correct translations across all 10 supported languages.
• Runtime Stability: Application builds and runs without runtime errors.
• Linting: Fixed JSON structure issues and removed duplicate-key warnings.
• UX Validation: Dates, time-ago labels, and storage units correctly adapt to active locale.
🎯 Result
The Heuristic Manager dashboard is now fully internationalized, locale-aware, and runtime-stable—bringing it in line with the rest of the application’s multilingual experience.
SCREENSHOTS


BEFORE
AFTER