Location: 06 Discussion - Add Post
Severity: 10
Description: The textarea to add a post has a hidden label for screen reader users purposes. However the off-screen label does not correspond to the on-screen label, which means the required text that's on-screen is not rendered. In addition, voice recognition software users who will use the on-screen label to directly access the textarea will not be able to do so because the accessible name of the field is "Post Body" instead of the on-screen label.
Pattern: None
Auditor Note: Developers must ensure that the accessible name is the same or similar to the on-screen label. In this case, the hidden label is unnecessary and the on-screen label can be implemented as the label for the textarea.
Compliant example:
Internal Note: Agree
Presumably, this is the right place to address this: https://github.com/edx/edx-platform/blob/master/common/static/common/templates/discussion/new-post.underscore#L47
(Caveat: not that familiar with frontend code at edX, don't know how these .underscore files get wired in)
the label for this textarea is being defined here:
https://github.com/edx/edx-platform/blob/6d2468d0dcf782a7561ecc61946146d6fae2762f/lms/static/coffee/src/customwmd.coffee#L136
I'm not sure if it was originally set to something generic ("Post body") on purpose because this file is being used elsewhere as well, so you will want to doublecheck that. If not, then I think updating it here will do the trick. If it is being used elsewhere you will need to make this over-ridable.
So, the "Post body" label has to match what everyone actually sees in the new post editor, which is: "Your question or idea (required)".
Doing a search on platform, it doesn't appear to me that the coffeescript is being used outside of discussions.
PR: https://github.com/edx/edx-platform/pull/16628
Local update DOM image:
This was rolled to Prod on 11/22