-
Notifications
You must be signed in to change notification settings - Fork 266
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do we still need Technique SCR21 ("Using functions of the Document Object Model (DOM) to add content to a page")? #3652
Comments
i'd say kill it with fire. this has nothing to do with accessibility and seems purely a code preference thing (and i'd say that "some of my best friends are innerHTML") |
Works for me. I'll take off and nuke the entire page from orbit. It's the only way to be sure. |
fstrr
added a commit
that referenced
this issue
Jan 23, 2024
mbgower
pushed a commit
that referenced
this issue
Feb 27, 2024
iadawn
pushed a commit
that referenced
this issue
Aug 7, 2024
This PR supersedes #3961; it accomplishes the same output, plus resolves a leftover empty section remaining in that PR. Related issues: #3651, #3758 ## Note to WG I would appreciate eyes on `obsoleteMessage` wording, seen at the end of each technique's About box (or at the top of HTML files in this PR) for restored obsolete techniques: - Parsing techniques (obsolete in 2.2): [F70](https://deploy-preview-3975--wcag2.netlify.app/techniques/failures/f70), [F77](https://deploy-preview-3975--wcag2.netlify.app/techniques/failures/f77), [G134](https://deploy-preview-3975--wcag2.netlify.app/techniques/general/g134), [G192](https://deploy-preview-3975--wcag2.netlify.app/techniques/general/g192), [H74](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h74), [H75](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h75), [H93](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h93), [H94](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h94) (all should have the same message) - Other previously-removed techniques: [H4](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h4), [H35](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h35), [H46](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h46), [H60](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h60), [H73](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h73), [H45](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h45), [H59](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h59), [H70](https://deploy-preview-3975--wcag2.netlify.app/techniques/html/h70), [SCR37](https://deploy-preview-3975--wcag2.netlify.app/techniques/client-side-script/scr37), [G187](https://deploy-preview-3975--wcag2.netlify.app/techniques/general/g187), [F87](https://deploy-preview-3975--wcag2.netlify.app/techniques/failures/f87) - [Flash](https://deploy-preview-3975--wcag2.netlify.app/techniques/flash/flash1) and [Silverlight](https://deploy-preview-3975--wcag2.netlify.app/techniques/silverlight/sl1) (Message is implemented centrally for each of these types, inherited from the XSLT build system) You don't need to worry about the implementation parts of the PR (unless you want to); I expect to ask @iadawn to review that part. ## Background Historically, techniques have been removed from this repository when they become obsolete. However, they are not removed from the WAI site in order to avoid link rot. This is not ideal, as it leaves those pages in isolation with no indication of being obsolete (with the exception of Flash and Silverlight pages, which had a message added by the build process). ## Summary This PR adds support for marking techniques as obsolete via front-matter. When a technique is marked as obsolete, it has the following effects: - Obsolete techniques contain an extra message at the bottom of their "About this technique" paragraph (roughly following the existing example from Flash and Silverlight techniques) - Links to the technique are omitted (e.g. from the [techniques index](https://deploy-preview-3975--wcag2.netlify.app/techniques/) and related techniques sections) - The one exception to this is links from one obsolete technique to another, in which case the links remain intact, to preserve the current WAI site behavior of obsolete technique pages remaining effectively untouched This PR also adds considerations for WCAG 2.2's obsolete SC, 4.1.1 Parsing: - Obsolete SC will no longer be referenced within the About this Technique box regarding applicable SC - The Related Techniques section in Understanding pages for obsolete SC is excluded, since those techniques will also no longer reference the SC - As with the exception to links above, these considerations only apply to pages that are not also obsolete themselves ## Changes - Implements 2 data fields for techniques pages: - `obsoleteSince` - indicates version upon which the technique became obsolete (in XY notation e.g. `22`) - `obsoleteMessage` - Message to display in About this Technique box - These can be set in front-matter or in directory-level Eleventy data files (e.g. for Flash and Silverlight) - Updates some transformation logic to account for new cases where list items or sections may become empty due to removed links to obsolete techniques - Adds back almost all obsolete techniques I could find in git history, with `obsoleteSince` and `obsoleteMessage` set - To avoid cruft and confusion, I have intentionally _not_ added back cross-links between previously-removed techniques, with the exception of H75 (which will still be relevant in WCAG 2.1, which I am also working on supporting in the new build system) ## Exclusions There are 2 techniques I have not restored; if folks have suggestions on wording for `obsoleteMessage` for them, I can add them: - [SCR21](https://www.w3.org/WAI/WCAG22/Techniques/client-side-script/SCR21): this was [removed](#3652) for seemingly having more to do with subjective coding preference than accessibility - [G222](https://www.w3.org/WAI/WCAG21/Techniques/general/G222): this only exists in 2.1 docs and probably shouldn't have ever been backported there, as it pertains to a SC that was initially added in 2.2 (not 2.1!) then removed before 2.2 was published ## Note: XSLT build system deprecation This PR introduces front-matter in some HTML files, which the previous XSLT build system won't know how to handle. Now that we have the Eleventy build system in use for WAI site updates as well as [gh-pages deploys](#3955), there should be no further dependencies on it, and I plan to remove it and think about updating the main README (update: in #3985).
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
SCR21 Using functions of the Document Object Model (DOM) to add content to a page seems to be less about the title of the document and more about certain scripting functionality that the author thinks should be avoided. For example:
and the Procedure, which consists of one item:
As such:
The text was updated successfully, but these errors were encountered: