a11y: drop redundant hardcoded aria-label#112
Merged
JohnMcLear merged 1 commit intomasterfrom May 9, 2026
Merged
Conversation
Etherpad's html10n auto-populates `aria-label` from the localized string when an element has `data-l10n-id` and no author-supplied `aria-label`. Hardcoded English values block that and leave screen readers with the English label regardless of language. Removes redundant `aria-label="…"` (and the no-op `data-l10n-attr="aria-label"` convention which etherpad's html10n does not support) from elements that already have `data-l10n-id`. See etherpad-lite/src/static/js/vendors/html10n.ts:665-678.
ⓘ You've reached your Qodo monthly free-tier limit. Reviews pause until next month — upgrade your plan to continue now, or link your paid account if you already have one. |
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.
Summary
Removes hardcoded
aria-label="…"attributes from elements that already declaredata-l10n-id. Witharia-labelset in the template, etherpad's html10n skips the auto-population path (html10n.ts:665-678) and leaves screen readers with the English label even when the user's UI language is something else.After this PR, html10n populates
aria-labelfrom the localized translation on everypad.applyLanguage()call, marked withdata-l10n-aria-label="true"so subsequent passes refresh it.Also drops the
data-l10n-attr="aria-label"attribute where present — that's a convention from a different localization library (e.g. fluent-dom), and etherpad's html10n does not read it. The auto-population in lines 665-678 is the etherpad mechanism.Part of the fleet-wide plugin a11y/i18n sweep (Phase 3 of the modernization campaign; pilot: ether/ep_align#182).