Page MenuHomePhabricator

TOC toctogglecheckbox breaks form label rule by not being labelled
Open, Needs TriagePublic

Description

Every MediaWiki TOC generates the input#toctogglecheckbox to collapse and expand the table of contents. Google Pagespeed / Lighthouse suggests that there may not be form elements without some kind of labeling. This input probably cannot be replaced by another element for maintaining no-js comparability.

But to comply it would be easy to add the aria-label attribute, like so: aria-label="Table of contents is hidden" to make it very accessible.

Please consider adding an aria-label attribute to the input#toctogglecheckbox to comply with Pagespeed / Lighthouse.