Skip to content

fix(i18n): say "1 product" and "1 prompt/location", not the plural - #1741

Merged
gkhngyk merged 2 commits into
ansvisor:mainfrom
cihan-gyk:fix/singular-copy
Oct 29, 2026
Merged

gkhngyk merged 2 commits into
ansvisor:mainfrom
cihan-gyk:fix/singular-copy

Conversation

@cihan-gyk

Copy link
Copy Markdown
Collaborator

Summary

Four counts had no singular form, so a count of one read as a plural:

  • Product Visibility › Readiness: the "first 40 words", "wrong price" and "reseller cheaper than you" titles read "· 1 products";
  • Insights › Tracked prompts card: "1 prompts/locations left to add".

Each now has a one case in web/messages/en.json. The rest of en.json was checked for the same pattern; unnamed forms like "+# more" or "# left" read correctly in the singular and are left as they are.

Related issue

None.

Type of change

  • fix — Bug fix

How to test

  1. Product Visibility › Readiness with one product affected by a check: "· 1 product".
  2. Insights with one prompt or location left on the plan: "1 prompt left to add" / "1 location left to add".

Checklist

  • Branch follows the naming convention
  • Commits follow Conventional Commits
  • Web: yarn lint (0 errors), yarn typecheck, yarn build pass; yarn test 554/555 files, _before-publish timed out under load (known; passes alone)
  • Tests added (_readiness.test.tsx and _kpi-cards.test.tsx cover the count of one)
  • Browser check: the demo data has no count of one; the tests cover it

🤖 Generated with Claude Code

Four counts had no singular form: Product Visibility Readiness's first
40 words, wrong price and cheaper reseller titles read "· 1 products",
and the Tracked prompts card "1 prompts/locations left to add". Each
gets a `one` case; tests cover the count of one.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

@gkhngyk gkhngyk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good

Reviewed f0bb582, branched from ce9a3dc. Copy and tests only, no migration.

What I checked

  • The four messages now have a one case:
    • Readiness: firstWords, wrongPrice and resellerCheaper. Their =0 cases are unchanged.
    • Insights: slotsLeft.
  • The new tests catch it. I put main's en.json back under the PR's tests: both new cases fail ("1 products", "1 prompts/locations"). With the PR's en.json, all 16 tests in _kpi-cards.test.tsx and _readiness.test.tsx pass.
  • Other counts. I scanned en.json for plural messages with no one/=1 case whose other reads # <noun>s. None are left. The rest, such as "+# more", "# still open" and "# over your plan limit", read correctly at 1.
  • en.json is the only locale file, so no other language needs the same change.
  • It merges cleanly on ce9a3dc and alongside #1717 and #1719. All three touch en.json, in different places.

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.

2 participants