Skip to content

Added missing ptBR translations #6503

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

fell-lucas
Copy link

@fell-lucas fell-lucas commented Aug 10, 2025

Description

Adds missing ptBR translations that are available in the enUS translation file.

Checklist

  • pnpm test runs as expected.
  • pnpm build runs as expected.
  • (If applicable) JSDoc comments have been added or updated for any package exports
  • (If applicable) Documentation has been updated

Type of change

  • 🐛 Bug fix
  • 🌟 New feature
  • 🔨 Breaking change
  • 📖 Refactoring / dependency upgrade / documentation
  • other: Translation files

Summary by CodeRabbit

  • New Features
    • Added and completed missing Brazilian Portuguese (pt-BR) translations for various sections, including API keys, organization and user profile pages, commerce, error messages, and UI elements.
    • Enhanced sign-in and sign-up flows with localized subtitles and button texts.
    • Improved consistency and coverage of Portuguese translations across the application.

Copy link

changeset-bot bot commented Aug 10, 2025

🦋 Changeset detected

Latest commit: 416efa8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 4 packages
Name Type
@clerk/localizations Patch
@clerk/clerk-js Patch
@clerk/chrome-extension Patch
@clerk/clerk-expo Patch

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

Copy link

vercel bot commented Aug 10, 2025

@fell-lucas is attempting to deploy a commit to the Clerk Production Team on Vercel.

A member of the Team first needs to authorize it.

Copy link
Contributor

coderabbitai bot commented Aug 10, 2025

📝 Walkthrough

Walkthrough

This update introduces a new changeset file documenting a patch release for the @clerk/localizations package. The main change is a significant expansion and completion of the Brazilian Portuguese (pt-BR) localization resource. Numerous translation keys were added or completed across various sections, including API keys, badges, commerce, organization and user profile navigation, sign-in and sign-up flows, error messages, and UI button labels. The update ensures more comprehensive and consistent coverage of the pt-BR localization, addressing previously missing or undefined translations.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Note

🔌 MCP (Model Context Protocol) integration is now available in Early Access!

Pro users can now connect to remote MCP servers under the Integrations page to get reviews and chat conversations that understand additional development context.


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.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

🔭 Outside diff range comments (1)
packages/localizations/src/pt-BR.ts (1)

1058-1058: Untranslated string: “Add” should be localized

This is visible UI text; translate to pt-BR.

-    formButtonPrimary__add: 'Add',
+    formButtonPrimary__add: 'Adicionar',
🧹 Nitpick comments (2)
packages/localizations/src/pt-BR.ts (1)

1-1286: Tests and linting

No tests were added. Consider adding a key-coverage and placeholder-parity test (like the script above) to prevent regressions. Also ensure Prettier/ESLint pass for this file.

You can adapt the script above into a unit test to enforce parity with en-US.

.changeset/forty-bottles-accept.md (1)

1-6: Changeset looks correct; minor copy nit

Consider using hyphenated locale and imperative mood.

-added missing ptBR translations
+add missing pt-BR translations
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between cf284ee and 416efa8.

📒 Files selected for processing (2)
  • .changeset/forty-bottles-accept.md (1 hunks)
  • packages/localizations/src/pt-BR.ts (17 hunks)
🧰 Additional context used
📓 Path-based instructions (10)
.changeset/**

📄 CodeRabbit Inference Engine (.cursor/rules/monorepo.mdc)

Automated releases must use Changesets.

Files:

  • .changeset/forty-bottles-accept.md
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit Inference Engine (.cursor/rules/development.mdc)

**/*.{js,jsx,ts,tsx}: All code must pass ESLint checks with the project's configuration
Follow established naming conventions (PascalCase for components, camelCase for variables)
Maintain comprehensive JSDoc comments for public APIs
Use dynamic imports for optional features
All public APIs must be documented with JSDoc
Provide meaningful error messages to developers
Include error recovery suggestions where applicable
Log errors appropriately for debugging
Lazy load components and features when possible
Implement proper caching strategies
Use efficient data structures and algorithms
Profile and optimize critical paths
Validate all inputs and sanitize outputs
Implement proper logging with different levels

Files:

  • packages/localizations/src/pt-BR.ts
**/*.{js,jsx,ts,tsx,json,css,scss,md,yaml,yml}

📄 CodeRabbit Inference Engine (.cursor/rules/development.mdc)

Use Prettier for consistent code formatting

Files:

  • packages/localizations/src/pt-BR.ts
packages/**/*.{ts,tsx}

📄 CodeRabbit Inference Engine (.cursor/rules/development.mdc)

TypeScript is required for all packages

Files:

  • packages/localizations/src/pt-BR.ts
packages/**/*.{ts,tsx,d.ts}

📄 CodeRabbit Inference Engine (.cursor/rules/development.mdc)

Packages should export TypeScript types alongside runtime code

Files:

  • packages/localizations/src/pt-BR.ts
**/*.{ts,tsx}

📄 CodeRabbit Inference Engine (.cursor/rules/development.mdc)

Use proper TypeScript error types

**/*.{ts,tsx}: Always define explicit return types for functions, especially public APIs
Use proper type annotations for variables and parameters where inference isn't clear
Avoid any type - prefer unknown when type is uncertain, then narrow with type guards
Use interface for object shapes that might be extended
Use type for unions, primitives, and computed types
Prefer readonly properties for immutable data structures
Use private for internal implementation details
Use protected for inheritance hierarchies
Use public explicitly for clarity in public APIs
Prefer readonly for properties that shouldn't change after construction
Prefer composition and interfaces over deep inheritance chains
Use mixins for shared behavior across unrelated classes
Implement dependency injection for loose coupling
Let TypeScript infer when types are obvious
Use const assertions for literal types: as const
Use satisfies operator for type checking without widening
Use mapped types for transforming object types
Use conditional types for type-level logic
Leverage template literal types for string manipulation
Use ES6 imports/exports consistently
Use default exports sparingly, prefer named exports
Use type-only imports: import type { ... } from ...
No any types without justification
Proper error handling with typed errors
Consistent use of readonly for immutable data
Proper generic constraints
No unused type parameters
Proper use of utility types instead of manual type construction
Type-only imports where possible
Proper tree-shaking friendly exports
No circular dependencies
Efficient type computations (avoid deep recursion)

Files:

  • packages/localizations/src/pt-BR.ts
packages/localizations/**/*

📄 CodeRabbit Inference Engine (.cursor/rules/monorepo.mdc)

Localization files must be placed in 'packages/localizations/'.

Files:

  • packages/localizations/src/pt-BR.ts
**/*.{js,ts,tsx,jsx}

📄 CodeRabbit Inference Engine (.cursor/rules/monorepo.mdc)

Support multiple Clerk environment variables (CLERK_, NEXT_PUBLIC_CLERK_, etc.) for configuration.

Files:

  • packages/localizations/src/pt-BR.ts
**/*

⚙️ CodeRabbit Configuration File

If there are no tests added or modified as part of the PR, please suggest that tests be added to cover the changes.

Files:

  • packages/localizations/src/pt-BR.ts
**/localizations/**/*.ts

⚙️ CodeRabbit Configuration File

**/localizations/**/*.ts: Review the changes to localization files with the following guidelines:

  • Ensure that no existing translations are accidentally removed unless they are being replaced or fixed. If a string is removed, verify that it is intentional and justified.
  • Check that all translations are friendly, formal, or semi-formal. Explicit, offensive, or inappropriate language is not allowed. If you find any potentially offensive language or are unsure, tag the @clerk/sdk-infra team in a separate comment. If you do not intend to tag the team, refer to it as "Clerk SDK Infra team" instead.
  • Use the most up-to-date base localization file (https://github.com/clerk/javascript/blob/main/packages/localizations/src/en-US.ts) to validate changes, ensuring consistency and completeness.
  • Confirm that new translations are accurate, contextually appropriate, and match the intent of the original English strings.
  • Check for formatting issues, such as missing placeholders, incorrect variable usage, or syntax errors.
  • Ensure that all keys are unique and that there are no duplicate or conflicting entries.
  • If you notice missing translations for new keys, flag them for completion.

Files:

  • packages/localizations/src/pt-BR.ts
🔇 Additional comments (6)
packages/localizations/src/pt-BR.ts (6)

17-36: New organization chooser translations read well

Wording is clear and semi-formal; placeholders look correct. No issues found.


281-283: API Keys titles/nav look consistent

The additions for API Keys in org and user sections are consistent and clear. No issues found.

Also applies to: 403-409, 931-933, 1116-1122


721-723: Sign-in combined subtitle is friendly and appropriate

Tone and phrasing look good for pt-BR. No issues found.


822-823: Social provider label (many-in-view) looks correct

Showing only the provider name matches expected pattern. No issues found.


829-845: Error messages look accurate and safe

Wording is clear, formal, and non-offensive. Placeholders appear correct.

Also applies to: 861-862, 882-883


1-1286: Confirm translation key and placeholder parity
I attempted to run the comparison script, but it didn’t emit any results. Please manually verify that:

  • pt-BR covers every key defined in en-US (no missing or extra entries)
  • Each {{…}} placeholder in pt-BR exactly matches its counterpart in en-US (no missing or stray variables)

Comment on lines +57 to +62
lastUsed__days: '{{days}}d atrás',
lastUsed__hours: '{{hours}}h atrás',
lastUsed__minutes: '{{minutes}}m atrás',
lastUsed__months: '{{months}}m atrás',
lastUsed__seconds: '{{seconds}}s atrás',
lastUsed__years: '{{years}}a atrás',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Disambiguate time abbreviations for minutes vs. months

Both minutes and months use “m”, which is ambiguous. Suggest:

  • minutes → “min”
  • months → “mês(es)”

This matches common pt-BR conventions and avoids confusion.

-    lastUsed__minutes: '{{minutes}}m atrás',
-    lastUsed__months: '{{months}}m atrás',
+    lastUsed__minutes: '{{minutes}}min atrás',
+    lastUsed__months: '{{months}}mês(es) atrás',
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
lastUsed__days: '{{days}}d atrás',
lastUsed__hours: '{{hours}}h atrás',
lastUsed__minutes: '{{minutes}}m atrás',
lastUsed__months: '{{months}}m atrás',
lastUsed__seconds: '{{seconds}}s atrás',
lastUsed__years: '{{years}}a atrás',
lastUsed__days: '{{days}}d atrás',
lastUsed__hours: '{{hours}}h atrás',
- lastUsed__minutes: '{{minutes}}m atrás',
- lastUsed__months: '{{months}}m atrás',
+ lastUsed__minutes: '{{minutes}}min atrás',
+ lastUsed__months: '{{months}}mês(es) atrás',
lastUsed__seconds: '{{seconds}}s atrás',
lastUsed__years: '{{years}}a atrás',
🤖 Prompt for AI Agents
In packages/localizations/src/pt-BR.ts between lines 57 and 62, the time
abbreviations for minutes and months both use "m", causing ambiguity. Change the
abbreviation for minutes from "m" to "min" and for months from "m" to "mês" or
"meses" to clearly distinguish them according to pt-BR conventions.

Comment on lines +65 to 69
confirmationText: 'Revogar',
formButtonPrimary__revoke: 'Revogar chave',
formHint: 'Tem certeza de que deseja excluir esta chave secreta?',
formTitle: 'Revogar chave secreta "{{apiKeyName}}"?',
},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Consistent terminology: use “chave de API” (not “chave secreta”)

Elsewhere you use “Chaves de API”. For consistency and clarity, prefer “chave de API” in revoke copy and title.

-      formHint: 'Tem certeza de que deseja excluir esta chave secreta?',
-      formTitle: 'Revogar chave secreta "{{apiKeyName}}"?',
+      formHint: 'Tem certeza de que deseja excluir esta chave de API?',
+      formTitle: 'Revogar chave de API "{{apiKeyName}}"?',
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
confirmationText: 'Revogar',
formButtonPrimary__revoke: 'Revogar chave',
formHint: 'Tem certeza de que deseja excluir esta chave secreta?',
formTitle: 'Revogar chave secreta "{{apiKeyName}}"?',
},
confirmationText: 'Revogar',
formButtonPrimary__revoke: 'Revogar chave',
formHint: 'Tem certeza de que deseja excluir esta chave de API?',
formTitle: 'Revogar chave de API "{{apiKeyName}}"?',
},
🤖 Prompt for AI Agents
In packages/localizations/src/pt-BR.ts around lines 65 to 69, replace all
instances of "chave secreta" with "chave de API" in the revoke confirmation text
and title to maintain consistent terminology across the application. Update the
formHint and formTitle strings accordingly to use "chave de API" instead of
"chave secreta".

formFieldInputPlaceholder__apiKeyName: undefined,
formFieldInputPlaceholder__apiKeyDescription: 'Explique por que você está gerando esta chave',
formFieldInputPlaceholder__apiKeyExpirationDate: 'Selecionar data',
formFieldInputPlaceholder__apiKeyName: 'Digite o nome da sua chave secreta',
formFieldInputPlaceholder__backupCode: 'Insira o código de backup',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Placeholder: prefer “chave de API” over “chave secreta”

Align with the rest of the file (e.g., page titles) and common wording.

-  formFieldInputPlaceholder__apiKeyName: 'Digite o nome da sua chave secreta',
+  formFieldInputPlaceholder__apiKeyName: 'Digite o nome da sua chave de API',

Committable suggestion skipped: line range outside the PR's diff.

🤖 Prompt for AI Agents
In packages/localizations/src/pt-BR.ts at line 219, the placeholder text uses
"código de backup" which should be updated to use "chave de API" to align with
the rest of the file and common terminology. Replace the string value with
"Insira a chave de API" to maintain consistency in wording.

Comment on lines +233 to 236
formFieldLabel__apiKeyDescription: 'Descrição',
formFieldLabel__apiKeyExpiration: 'Expiração',
formFieldLabel__apiKeyName: 'Nome da chave secreta',
formFieldLabel__automaticInvitations: 'Ativar convites automáticos para este domínio',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Label: prefer “chave de API” over “chave secreta”

Keep terminology consistent with titles/navigation.

-  formFieldLabel__apiKeyName: 'Nome da chave secreta',
+  formFieldLabel__apiKeyName: 'Nome da chave de API',
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
formFieldLabel__apiKeyDescription: 'Descrição',
formFieldLabel__apiKeyExpiration: 'Expiração',
formFieldLabel__apiKeyName: 'Nome da chave secreta',
formFieldLabel__automaticInvitations: 'Ativar convites automáticos para este domínio',
formFieldLabel__apiKeyDescription: 'Descrição',
formFieldLabel__apiKeyExpiration: 'Expiração',
formFieldLabel__apiKeyName: 'Nome da chave de API',
formFieldLabel__automaticInvitations: 'Ativar convites automáticos para este domínio',
🤖 Prompt for AI Agents
In packages/localizations/src/pt-BR.ts around lines 233 to 236, the label "Nome
da chave secreta" should be changed to "Nome da chave de API" to maintain
consistent terminology with titles and navigation. Update the string value
accordingly to reflect this preferred phrasing.

Comment on lines 1247 to 1251
destructiveAction: 'Remover carteira',
detailsAction__nonPrimary: undefined,
detailsAction__nonPrimary: 'Conectar carteira',
primaryButton: 'Carteiras Web3',
title: 'Carteiras Web3',
},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Likely wrong action label: should be “Definir como principal”

For consistency with similar actions (e.g., phoneCode.detailsAction__nonPrimary), this should set the wallet as primary, not “connect wallet”.

-        detailsAction__nonPrimary: 'Conectar carteira',
+        detailsAction__nonPrimary: 'Definir como principal',
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
destructiveAction: 'Remover carteira',
detailsAction__nonPrimary: undefined,
detailsAction__nonPrimary: 'Conectar carteira',
primaryButton: 'Carteiras Web3',
title: 'Carteiras Web3',
},
destructiveAction: 'Remover carteira',
- detailsAction__nonPrimary: 'Conectar carteira',
+ detailsAction__nonPrimary: 'Definir como principal',
primaryButton: 'Carteiras Web3',
title: 'Carteiras Web3',
🤖 Prompt for AI Agents
In packages/localizations/src/pt-BR.ts around lines 1247 to 1251, the label for
detailsAction__nonPrimary is incorrectly set to "Conectar carteira" but should
be "Definir como principal" to match the intended action of setting the wallet
as primary. Update the string value of detailsAction__nonPrimary to "Definir
como principal" for consistency with similar action labels.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants