feat: add internationalization support and shell configuration UI#300
Open
anime-shed wants to merge 2 commits intostd-microblock:masterfrom
Open
feat: add internationalization support and shell configuration UI#300anime-shed wants to merge 2 commits intostd-microblock:masterfrom
anime-shed wants to merge 2 commits intostd-microblock:masterfrom
Conversation
Author
- Introduce internationalization (i18n) infrastructure: - Add i18n scaffolding and translation resource loading utilities. - Provide runtime locale detection and a language switcher component. - Wire common UI strings through translation keys to enable multi-language support. - Add configuration UI for the shell: - New settings panel to configure shell preferences (appearance, behavior, and locale). - Persist user preferences and apply them at runtime. - Accessible, responsive controls integrated into the shell UI. - Implementation details: - Register i18n provider at the app root and update components to use localized strings. - Add helper functions for retrieving and updating locale and other settings. - Include basic tests and example translation resources to validate integration. - Notes: - No breaking changes to existing public APIs. - Future work: expand translation coverage, add additional locales, and refine UX for preference syncing.
Owner
|
Thanks! I'm busy working on another project so it might take a few days for me to review this PR. |
Owner
|
Is the work done by LLMs, btw? |
Author
|
Yes, you can go through the process I did on my repo. Since C and C++ side is way out of my league. |
Owner
Can you fix the three points I mentioned? |
Author
|
@std-microblock I am not able to find your comments? Can you guide me where to find it? |
Owner
Author
std-microblock
requested changes
Jan 4, 2026
Owner
|
what about now |
Author
Replace the JSON parsing backend from yyjson to reflect-cpp (rfl) for locale file handling, simplifying the codebase with better type safety and more ergonomic API. Changes: - Introduce LocaleFile and LocaleMetadata structures with rfl annotations for declarative JSON parsing in i18n_manager.cc - Migrate load_locale() and load_plugin_locales() to use rfl::json::read with improved error messages and validation - Add js_traits specializations for std::map and std::unordered_map in quickjspp.hpp to support generic map conversions - Remove custom map<string, Value> traits from binding_qjs.h (now handled by generic quickjspp.hpp traits) - Remove yyjson dependency from xmake.lua - Clean up config_page exports by removing unused languages identifier The new reflect-cpp approach provides compile-time type checking and reduces boilerplate while maintaining all existing security checks (path validation, canonicalization) and plugin key override protection.
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.






Introduce internationalization (i18n) infrastructure:
Add configuration UI for the shell:
Implementation details:
Notes:
Allow english translation #299