chore: modernize docs, a11y, and adopt template helper#182
Merged
JohnMcLear merged 5 commits intomainfrom May 8, 2026
Merged
Conversation
Replaces the etherpad-lite-era boilerplate with a plugin-specific guide: target branch is main (not develop), local install via pnpm run plugins i --path, tests run via the etherpad harness, and i18n/a11y are now standing requirements. Cross-links to ether/etherpad's CONTRIBUTING.md for shared rules.
Mirrors etherpad-lite/AGENTS.MD's shape but scoped to ep_align: project structure, helpers used and skipped (with reasons), test commands, and standing rules for agent edits (i18n, a11y, export-shape stability).
Removes the <button> nested inside <a> (invalid HTML, screen-reader confusion) by promoting the <a> to the click target with role=button and tabindex=0, and moves the buttonicon classes onto it. Removes the hardcoded aria-label="Align Left/..." which was blocking html10n from populating aria-label from the localized string. With no author-supplied aria-label, html10n now sets it from the translation and tags the element with data-l10n-aria-label="true" so language changes refresh the accessible name (see etherpad-lite/src/static/js/vendors/html10n.ts:665-678). The English title="..." stays as the pre-html10n fallback; html10n overwrites it via the .title suffix in the data-l10n-id, unchanged from the previous behavior. Adds a Playwright assertion that locks in the structural fix (no <button> children of .ep_align, every button exposes role and an html10n-populated aria-label).
Prepares for adopting the template helper in the next commit.
Replaces the hand-rolled eejsBlock_editbarMenuLeft with the template() helper from ep_plugin_helpers, with both the read-only check and the toolbar-conflict check encoded in the skip callback. The helper wraps skip() in a try/catch so a transient settings.toolbar=undefined no longer risks crashing pad render.
ⓘ 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 was referenced May 9, 2026
This was referenced May 9, 2026
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
Pilot for a fleet-wide plugin modernization sweep. Lands five focused commits in
ep_align:CONTRIBUTING.mdfor plugin scope (target branchmain, plugin install viapnpm run plugins i --path, i18n + a11y are now standing requirements).AGENTS.mdmodeled onetherpad-lite/AGENTS.MD— project structure, helpers used vs skipped (with reasons), test commands, standing rules.templates/editbarButtons.ejs: remove the<button>nested inside<a>(invalid HTML, screen-reader confusion), promote the<a>to the click target withrole="button"andtabindex="0". Remove the hardcodedaria-label="Align Left/..."so etherpad's html10n auto-populatesaria-labelfrom the localized string and tags it withdata-l10n-aria-label="true"(seeetherpad-lite/src/static/js/vendors/html10n.ts:665-678). Adds a Playwright assertion that locks in the structural fix.ep_plugin_helpers ^0.5.0todependencies.templatehelper fromep_plugin_helpersforeejsBlock_editbarMenuLeft. The helper wrapsskip()in a try/catch so a transientsettings.toolbar=undefinedno longer risks crashing pad render.Out of scope (documented gaps in
AGENTS.md)lineAttributehelper adoption — would require migrating from inlinestyle="text-align:..."rendering to a CSS file injected viaaceEditorCSS, plus updating the Playwright assertion. Tracked as a follow-up.lineAttributeExporthelper — backend export shape (<p style='text-align:X'>...</p>) is enforced bystatic/tests/backend/specs/exportHTML.tsfor back-compat; helper produces a different shape.Test plan
static/tests/backend/specs/exportHTML.ts(4 alignment cases + heading interaction)static/tests/frontend-new/specs/align.spec.ts(4 alignment cases via toolbar click + new structural assertion)Local verification was hampered by my etherpad-lite checkout being on a feature branch with degraded test state — CI is the gate.