feat(i18n): implement internationalization framework and spanish tran…#85
feat(i18n): implement internationalization framework and spanish tran…#85Luchi5544 wants to merge 5 commits into
Conversation
|
@Luchi5544 is attempting to deploy a commit to the truthixify's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
@Luchi5544 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
|
i18n scaffolding + Spanish locale + LocaleSwitcher + instrumenting all chain components looks right. 5 conflicts to resolve: git fetch origin
git rebase origin/develop
git push --force-with-leaseFor each conflicted file, keep develop's structure (it has more recent work) and re-apply your |
|
The i18n work itself is good, but now after #87 just landed (push notifications, modified StellarReceive.tsx), this PR conflicts in git fetch origin
git rebase origin/develop
git push --force-with-leaseWhen resolving, keep develop's StellarReceive structure and re-apply your |
|
#92 just landed (WalletConnect v2) which added deps to git fetch origin
git rebase origin/develop
# pnpm-lock.yaml: easiest is to take develop's version then re-run `pnpm install` to add your own deps back
pnpm install
git add pnpm-lock.yaml
# also resolve any src/components/WalletConnect.tsx conflict — keep develop's WalletConnect integration
git rebase --continue
git push --force-with-lease |
|
Conflicts in git fetch origin
git rebase origin/develop
# package.json: keep both sets of deps
pnpm install # regenerates lockfile
# StellarReceive.tsx: keep develop's QR integration, then re-apply your t() call wrappings
git add -u
git rebase --continue
git push --force-with-lease |
closes #70
Description
This PR integrates a robust internationalization framework into the Wraith Protocol Demo app using
react-i18nextandi18next-browser-languagedetector. It extracts all hardcoded user-visible text into translation dictionaries, introduces a locale switcher in the header, and implements persistent preferences.Key Changes
react-i18nextwith browser language detection (src/i18n/index.ts).LocaleSwitcher(src/components/LocaleSwitcher.tsx) that changes languages viareact-i18nextand persists the selection inlocalStorageunder the keywraith-locale.LocaleSwitcherdropdown to the header right next to the chain switcher.CkbReceive,CkbSend,SolanaReceive,SolanaSend,StellarReceive,StellarSend,HorizenReceive,HorizenSend,WalletConnect, etc.) witht()function hooks.src/i18n/en.json: All original English strings.src/i18n/es.json: Full Spanish translations matching all keys.pnpm-workspace.yamland.npmrcto ensure node-gyp packages (likekeccak,secp256k1,esbuild) can build non-interactively in standard CI/CD and developer environments.Verification Results
npx pnpm formatto format code style constraints.npx pnpm run buildwhich successfully ran type checkingtsc --noEmitand Vite production bundling with 0 warnings or errors.