feat(i18n): internationalize hardcoded strings in NewCauseClient - #1019
Open
abimbolaalabi wants to merge 7 commits into
Open
feat(i18n): internationalize hardcoded strings in NewCauseClient#1019abimbolaalabi wants to merge 7 commits into
abimbolaalabi wants to merge 7 commits into
Conversation
Add translation keys to messages/en.json and messages/es.json for the Write/Preview tabs, empty-preview state, exact bps label and denominator, and the Cover Image URL (optional) label, replacing hardcoded English strings with t() calls so /es users see localized text. Closes Iris-IV#586
|
@abimbolaalabi 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! 🚀 |
Contributor
|
Auto-review failed (API error). Leaving PR for human review. |
Contributor
|
Auto-review failed (API error). Leaving PR for human review. |
1 similar comment
Contributor
|
Auto-review failed (API error). Leaving PR for human review. |
| const parts = fullKey.split("."); | ||
| const key = parts[parts.length - 1]; | ||
| const namespace = parts.length > 1 ? parts[0] : ''; | ||
| const namespace = parts.length > 1 ? parts[0] : ""; |
…etailClient Jest cannot transform react-markdown because next/jest's default transformIgnorePatterns match node_modules before the ESM whitelist, which made AppPageComponents fail to run. Render the description via SafeMarkdown (mocked in tests) instead, and remove the duplicated h1/CampaignDescription block left by the botched merge of PR 771.
…Client Applies prettier (--write) to files left unformatted by the botched PR 771 merge, plus the t() spans added by this PR's i18n work, so the CI Prettier format check passes.
abimbolaalabi
force-pushed
the
fix/issue-586-i18n-new-cause-client
branch
from
August 1, 2026 10:43
4ec2cc0 to
4ce4a01
Compare
Contributor
|
Auto-review failed (API error). Leaving PR for human review. |
NotificationBell and NotificationSettings render on every page and call the Notifications namespace, which was lost in the 771 merge. Without it, next-intl throws MISSING_MESSAGE on page load and breaks the Playwright E2E connect-wallet journey. Restore the namespace for en and es using the key shapes the current components rely on.
Contributor
|
Auto-review failed (API error). Leaving PR for human review. |
The dashboard renders an h1 alongside body, so the .or() locator resolves to two elements and strict mode rejects it. Use .first() to take the first match, matching the maintainer fix in PR 1020.
Contributor
|
Auto-review failed (API error). Leaving PR for human review. |
The CI test set was at 49.22% branch coverage, just under the 50% threshold in jest.config.ts. Add tests for the cover image and category icon fallback, the save button wallet guard, and async action error paths, mirroring the maintainer coverage in PR 1020. Raises the CI set to 50.6% branches.
Contributor
|
Auto-review failed (API error). Leaving PR for human review. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
This PR internationalizes the remaining hardcoded English strings in the Create Campaign form (
NewCauseClient.tsx): the description editor Write / Preview tabs, the empty-preview state, the revenue-share Exact bps input and its/ 10 000denominator, and the Cover Image URL (optional) label. These previously rendered in English even for/esusers.Related Issue
Closes #586
Changes
🏷️ Internationalization (i18n)
src/app/[locale]/causes/new/NewCauseClient.tsxWrite,Preview,Nothing to preview,Exact bps:,/ 10 000,Cover Image URL, and(optional)witht('key')calls.messages/en.jsontabWrite,tabPreview,nothingToPreview,labelExactBps,revenueShareBpsDenominator,labelCoverImageUrl, andoptionalkeys under theCreateCampaignnamespace.messages/es.jsonVerification Results
t("tabWrite")/t("tabPreview")t("nothingToPreview")t("labelExactBps")/t("revenueShareBpsDenominator")t("labelCoverImageUrl")+t("optional")