Skip to content

fix(l10n): Use a plural form for the connections tooltip - #1284

Merged
kesselb merged 2 commits into
masterfrom
fix/l10n-plural-connections
Nov 19, 2026
Merged

kesselb merged 2 commits into
masterfrom
fix/l10n-plural-connections

Conversation

@rakekniven

Copy link
Copy Markdown
Member

A translator asked at Transifex how the string "connections" is used.

It is the unit in the tooltip of the "Current connections" live chart: the code joins the value and the translated word (${value} ${unit}). That shows "1 connections", and languages cannot adapt the word to the number or change the order.

This PR lets optionsFor() take a formatter instead of a unit string, and the connections chart now uses n('serverinfo', '%n connection', '%n connections', value) with a TRANSLATORS comment. The queries (/s) and latency (ms) charts show the same text as before. An empty sample still shows "—".

I could not run the build or the tests locally.

🤖 Generated with Claude Code

The tooltip of the live chart joined the number and the translated word
"connections", so it showed "1 connections" and languages could not adapt
the word to the number. Use n() instead. Reported at Transifex.

Signed-off-by: rakekniven <2069590+rakekniven@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@nextcloud-command nextcloud-command added the AI assisted This PR contains AI-assisted commits label Nov 19, 2026
@kesselb

kesselb commented Nov 19, 2026

Copy link
Copy Markdown
Collaborator

/compile /

@kesselb

kesselb commented Nov 19, 2026

Copy link
Copy Markdown
Collaborator

Thanks a lot

Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
@kesselb
kesselb enabled auto-merge November 19, 2026 10:49
@kesselb

kesselb commented Nov 19, 2026

Copy link
Copy Markdown
Collaborator

/backport to stable35 please

@kesselb
kesselb merged commit 1cd99ee into master Nov 19, 2026
36 checks passed
@kesselb
kesselb deleted the fix/l10n-plural-connections branch November 19, 2026 10:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AI assisted This PR contains AI-assisted commits

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants