Skip to content

Copy batch action: show only locales available in current project - #4435

Merged
mathjazz merged 8 commits into
mozilla:mainfrom
MundiaNderi:bug-4424-project-only-locales
Sep 3, 2026
Merged

Copy batch action: show only locales available in current project#4435
mathjazz merged 8 commits into
mozilla:mainfrom
MundiaNderi:bug-4424-project-only-locales

Conversation

@MundiaNderi

Copy link
Copy Markdown
Collaborator

Fixes #4424

Fall back to the global locale list when in the All Projects view.

@codecov-commenter

codecov-commenter commented Aug 21, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 33.33333% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.92%. Comparing base (5eab94c) to head (c6ca5c0).
⚠️ Report is 15 commits behind head on main.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@MundiaNderi MundiaNderi self-assigned this Aug 21, 2026
@MundiaNderi

Copy link
Copy Markdown
Collaborator Author

Adding tests in a few :)

@MundiaNderi
MundiaNderi requested a review from flodolo August 21, 2026 09:36
@flodolo
flodolo requested review from mathjazz and removed request for flodolo August 21, 2026 09:41
@flodolo

flodolo commented Aug 21, 2026

Copy link
Copy Markdown
Collaborator

Redirecting to @mathjazz since he's back, and much better with JS

@flodolo flodolo changed the title Scope locales to current project Copy batch action: show only locales available in current project Aug 21, 2026

@mathjazz mathjazz left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Nice work, please see the comment inline for a slightly different approach.

Comment thread translate/src/api/other-locales.ts Outdated
Comment thread translate/src/api/other-locales.ts Outdated
Scope locales to current project

Fall back to the global locale list when in the All Projects view
@MundiaNderi
MundiaNderi force-pushed the bug-4424-project-only-locales branch from 03d3f50 to 0af3563 Compare August 31, 2026 09:51
@MundiaNderi
MundiaNderi requested a review from mathjazz September 1, 2026 04:48

@mathjazz mathjazz left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for the update!

The dropdown is dead in the All Projects view (unless you previously open a per-project view - then it remains populated with the locales of that project):
http://localhost:8000/sl/all-projects/all-resources/?string=66617

Comment thread translate/src/api/other-locales.ts
Comment thread translate/src/modules/batchactions/components/BatchActions.test.jsx
Comment thread translate/src/modules/batchactions/components/BatchActions.tsx Outdated
@MundiaNderi
MundiaNderi requested a review from mathjazz September 2, 2026 04:48

@mathjazz mathjazz left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Almost there!

Comment thread translate/src/modules/batchactions/components/BatchActions.tsx
Comment thread translate/src/modules/project/reducer.ts
@MundiaNderi
MundiaNderi requested a review from mathjazz September 3, 2026 11:42

@mathjazz mathjazz left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Great work! 👏

@mathjazz
mathjazz merged commit 53ce415 into mozilla:main Sep 3, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Copy from another locales: display only locales available in the project where possible

4 participants