feat(localizations): Add zh-TW translations#7937
Conversation
🦋 Changeset detectedLatest commit: 8ec0c42 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
@ridemountainpig is attempting to deploy a commit to the Clerk Production Team on Vercel. A member of the Team first needs to authorize it. |
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Organization UI (inherited) Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
I'm also a developer from Taiwan |
Ephem
left a comment
There was a problem hiding this comment.
Thank you for the contribution, this is a great addition!
I let an agent do a review pass and a few suggestions came up that I've commented on. Since I do not speak the language I rely on your judgement here however, so feel free to resolve these comments however you see fit.
Send a comment when it's all resolved and we'll take another look and likely approve and get this in. The PR will also need a changeset, you can generate one by running pnpm changeset and following the guide, it should be a patch version for the localizations package.
Co-authored-by: Fredrik Höglund <fredrik.hoglund@gmail.com>
There was a problem hiding this comment.
♻️ Duplicate comments (1)
packages/localizations/src/zh-TW.ts (1)
77-183:⚠️ Potential issue | 🟠 MajorBackfill the current base-locale keys that are still missing here.
en-US.tsnow defines keys that still do not exist in thiszh-TWresource, includingformFieldInputPlaceholder__signUpPassword,billing.billedAnnuallyOnly,billing.prorationCredit,billing.accountCredit,billing.payerCreditRemainder, the seat-pricing subtree underbilling.pricingTable.seatCost,organizationProfile.start.membershipSeatUsageLabel,organizationProfile.plansPage.alerts.planMembershipLimitExceeded, anditemCaption__payerCreditin both org/user billing statements. BecauseLocalizationResourceis aDeepPartial, these omissions will not be caught by type-checking, so the locale can silently drift out of sync with the current base file. Please add translations or explicitundefinedplaceholders for the missing keys before merge. (raw.githubusercontent.com)
Based on learnings: inpackages/localizations/src/*.ts, undefined values for newly added localization keys are intentional placeholders for future translations.Also applies to: 213-230, 317-327, 413-416, 453-460, 1118-1128
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/localizations/src/zh-TW.ts` around lines 77 - 183, The zh-TW locale is missing several keys introduced in en-US; add translations or explicit undefined placeholders for the following keys (matching the en-US structure) into packages/localizations/src/zh-TW.ts: formFieldInputPlaceholder__signUpPassword, billing.billedAnnuallyOnly, billing.prorationCredit, billing.accountCredit, billing.payerCreditRemainder, the billing.pricingTable.seatCost subtree (seatCost and its children), organizationProfile.start.membershipSeatUsageLabel, organizationProfile.plansPage.alerts.planMembershipLimitExceeded, and itemCaption__payerCredit for both org and user billing statements; ensure you place each key under the exact parent object (e.g., billing.*, billing.pricingTable.seatCost.*, organizationProfile.start.*, organizationProfile.plansPage.alerts.*, statement itemCaption__payerCredit) following the existing zh-TW file structure and use either translated strings or explicit undefined values as placeholders.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Duplicate comments:
In `@packages/localizations/src/zh-TW.ts`:
- Around line 77-183: The zh-TW locale is missing several keys introduced in
en-US; add translations or explicit undefined placeholders for the following
keys (matching the en-US structure) into packages/localizations/src/zh-TW.ts:
formFieldInputPlaceholder__signUpPassword, billing.billedAnnuallyOnly,
billing.prorationCredit, billing.accountCredit, billing.payerCreditRemainder,
the billing.pricingTable.seatCost subtree (seatCost and its children),
organizationProfile.start.membershipSeatUsageLabel,
organizationProfile.plansPage.alerts.planMembershipLimitExceeded, and
itemCaption__payerCredit for both org and user billing statements; ensure you
place each key under the exact parent object (e.g., billing.*,
billing.pricingTable.seatCost.*, organizationProfile.start.*,
organizationProfile.plansPage.alerts.*, statement itemCaption__payerCredit)
following the existing zh-TW file structure and use either translated strings or
explicit undefined values as placeholders.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 1fdffddf-25b9-4382-b057-8f71b128d184
📒 Files selected for processing (1)
packages/localizations/src/zh-TW.ts
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@packages/localizations/src/zh-TW.ts`:
- Around line 25-27: The translation uses {{ createdDate }} / {{ expiresDate }}
but the UI supplies positional params (n-based), so update the placeholders in
the keys createdAndExpirationStatus__expiresOn and
createdAndExpirationStatus__never to use the n-param names passed at runtime
(e.g., replace createdDate with n0 and expiresDate with n1) while preserving the
date filters (shortDate/longDate) so the interpolation matches the call site.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 1b147b8d-7c33-494f-bb28-771cecffbb7c
📒 Files selected for processing (1)
packages/localizations/src/zh-TW.ts
|
Hello @Ephem, thanks for your review. I updated the comment and generated the changeset, could you please check it again? Thank you. |
Ephem
left a comment
There was a problem hiding this comment.
Thank you for the updates, this is looking great!
This is a great contribution, we are very grateful and will get this merged soon.
|
@lynda0214 Thank you for proofreading the comments, much appreciated! |
@clerk/agent-toolkit
@clerk/astro
@clerk/backend
@clerk/chrome-extension
@clerk/clerk-js
@clerk/dev-cli
@clerk/expo
@clerk/expo-passkeys
@clerk/express
@clerk/fastify
@clerk/hono
@clerk/localizations
@clerk/nextjs
@clerk/nuxt
@clerk/react
@clerk/react-router
@clerk/shared
@clerk/tanstack-react-start
@clerk/testing
@clerk/ui
@clerk/upgrade
@clerk/vue
commit: |
Description
Checklist
pnpm testruns as expected.pnpm buildruns as expected.Type of change
Summary by CodeRabbit
Localization
Chores