Enhance Portuguese translations and restructure i18n schema#14986
Enhance Portuguese translations and restructure i18n schema#14986VicenzoMF wants to merge 8 commits intomedusajs:developfrom
Conversation
Restructure i18n schema and translations: - swap selectAll/unselectAll and adjust required/additionalProperties - add shippingOptionTypes and store defaults in translation files - update order components to use new translation keys - switch payment status to use i18n strings
🦋 Changeset detectedLatest commit: 096ca67 The changes in this PR will be included in the next version bump. This PR includes changesets to release 77 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 |
|
@VicenzoMF is attempting to deploy a commit to the medusajs Team on Vercel. A member of the Team first needs to authorize it. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
...outes/orders/order-detail/components/order-fulfillment-section/order-fulfillment-section.tsx
Outdated
Show resolved
Hide resolved
| "awaitingFulfillmentBadge": "Awaiting fulfillment", | ||
| "awaitingShipping": "Awaiting shipping", | ||
| "awaitingPickup": "Awaiting pickup", | ||
| "awaitingDelivery": "Awaiting Delivery", |
There was a problem hiding this comment.
Inconsistent capitalization in awaitingDelivery translation value
Low Severity
The value "Awaiting Delivery" uses title case for "Delivery", while the adjacent entries "awaitingShipping" and "awaitingPickup" use sentence case ("Awaiting shipping", "Awaiting pickup"). This creates a visible inconsistency in the UI when these strings appear as status badges.
|
You have used all of your free Bugbot PR reviews. To receive reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial. |
|
You have used all of your free Bugbot PR reviews. To receive reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial. |
|
Thank you for your contribution! After reviewing this PR, we need a few things addressed before we can move forward: Required changes:
Notes: This PR goes beyond a translation-only contribution — it adds new source keys to
|
devDependency, created the changeset
|
You have used all of your free Bugbot PR reviews. To receive reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial. |
|
You have used all of your free Bugbot PR reviews. To receive reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial. |


Summary
What — What changes are introduced in this PR?
This PR contains updates related to internationalization (i18n) and minor dependency adjustments for the admin dashboard. The key changes are:
$schema.json) to fix key names, required lists, ordering, and addadditionalProperties: falsewhere appropriate.en.jsonandptBR.json(e.g.,awaitingShipping,awaitingPickup,awaitingDelivery,shippingOptionTypes, severalstorefields, andtranslationsdomain).t(...)) in order-related components.packages/admin/dashboard/package.json(removed directi18nextdependency and addedprettier) and updatedyarn.lockto reflect dependency changes (including updates to@swc/coreand addition ofprettier).Why — Why are these changes relevant or necessary?
prettier) as needed; updates toyarn.lockensure reproducible installs.How — How have these changes been implemented?
packages/admin/dashboard/src/i18n/translations/$schema.json:selectAll/unselectAllkeys where required).requiredarrays.additionalProperties: falseto objects to tighten validation.shippingOptionTypes,translationsdomain entries).packages/admin/dashboard/src/i18n/translations/en.jsonand.../ptBR.jsonwith new keys and localized strings.order-fulfillment-section.tsxnow usest("orders.fulfillment.awaitingPickup"),t("orders.fulfillment.awaitingShipping"), andt("orders.fulfillment.awaitingDelivery").order-payment-section.tsxnow usest("orders.payment.status.canceled"),t("orders.payment.status.captured"), andt("orders.payment.status.awaiting").packages/admin/dashboard/package.json(removed expliciti18nextentry and addedprettier) and committedyarn.lockupdates (addsprettierand updates@swc/coreresolutions).Testing — How have these changes been tested, or how can the reviewer test the feature?
Manual testing steps:
yarn installat the repository root (ensureyarn.lockis used).yarn buildor the project-specific build command).requires_shippingis true and it's a pickup: showsorders.fulfillment.awaitingPickup(PT-BR:Aguardando retirada).requires_shippingis true and not a pickup: showsorders.fulfillment.awaitingShipping(PT-BR:Aguardando envio).requires_shippingis false: showsorders.fulfillment.awaitingDelivery(PT-BR:Aguardando entrega).orders.payment.status.canceledorders.payment.status.capturedorders.payment.status.awaitingshippingOptionTypes,storefields (default sales channel, default location, default locale), and translations domain to ensure labels appear in the chosen locale (en / pt-BR).yarn test(or package-specific test command) to ensure no regressions.$schema.json:en.jsonandptBR.jsonpass the schema.Examples
Provide examples or code snippets that demonstrate how this feature works, or how it can be used in practice.
This helps with documentation and ensures maintainers can quickly understand and verify the change.
Checklist
Please ensure the following before requesting a review:
yarn changesetand follow the promptsAdditional Context
yarn.lockchanges include addition ofprettierfor the$schema.jsoncommand to work. Ensure CI builds on all target platforms succeed after these lockfile changes.$schema.jsonaddsadditionalProperties: falsein multiple places. This strengthens validation but may require future translation files to strictly follow the schema shape.Note
Medium Risk
Medium risk due to schema strictness changes (
additionalProperties: falseand required key reshuffles) that can break translation validation/builds, plus order status label changes that may surface missing/incorrect i18n keys.Overview
Updates the dashboard translation
$schema.jsonto reorder/rename keys, adjustrequiredlists, and add broaderadditionalProperties: falseconstraints (including new/expanded sections liketranslations).Extends
en.jsonand especiallyptBR.jsonwith new UI strings (e.g., fulfillment awaiting states, draft order list empty/filtered messaging, store default fields, shipping option types, promotions templates/status/limits, and new refund-reason copy).Adjusts order detail UI to use i18n keys for fulfillment “awaiting …” statuses and payment status labels; fulfillment “Canceled/Shipped/Delivered” labels are now hard-coded strings. Adds
prettier@^3.8.1to the dashboard devDependencies (with correspondingyarn.lockupdate).Written by Cursor Bugbot for commit d0fed30. This will update automatically on new commits. Configure here.