feat(i18n): Implement multi-language support (en, zh-CN, zh-TW, ja) with auto-detection#66
Open
yozurukt wants to merge 12 commits into
Open
feat(i18n): Implement multi-language support (en, zh-CN, zh-TW, ja) with auto-detection#66yozurukt wants to merge 12 commits into
yozurukt wants to merge 12 commits into
Conversation
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.
Close #49
This PR adds internationalization (i18n) support to Moodist using
i18nextandreact-i18next, with the UI now available in English, Simplified Chinese, Traditional Chinese, and Japanese.Key Changes:
en,zh-CN,zh-TW,ja) for easy translation and maintenance./that detects the user's preferred language vianavigator.languages, and routes them to the appropriate localized version (usessessionStorageto prevent redirect loops).zh-CN,zh-TW, andjalocales using@font-faceand:lang()selectors to enhance readability for CJK characters.aria-label,alt, etc.) have been internationalized and moved into locale files for consistency.:global()pseudo-class, resolving an issue when stylingset:htmlcontent in the footer.Note: I'm still new to front-end development, so I’d really appreciate any feedback on the implementation, especially on best practices or things I might have overlooked!