Support » Plugin: Ninja Forms Contact Form - The Drag and Drop Form Builder for WordPress » Ninja Forms W3C Error and Possible Solution

  • Resolved vbak

    (@vbak)


    Critical: The aria-describedby attribute must point to IDs of elements in the same document.
    Critical: The aria-labelledby attribute must point to IDs of elements in the same document.

    I’m getting these back from my accessibility scan, in reference to ID: nf-form-errors-1 and ID: nf-form-title-1.

    I know this was brought up in a previous post, and was ruled out as a ‘false positive’, however, I believe there’s a solution for this issue:

    Add aria-busy=true while the content is loading, and aria-busy=false once loading completes.

    aria-busy waits for the wrapped content to complete being “busy”, and only after it is done, will it go through the child elements to look for required relationships.

    aria-busy works with the aria-live attribute. It is explained more in this article:
    https://accessibilityresources.org/aria-busy

    Could this fix be implemented? Thank you!

    • This topic was modified 2 months, 3 weeks ago by vbak.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter vbak

    (@vbak)

    Bump

    Plugin Contributor Justin McElhaney

    (@jmcelhaney)

    The errors about the aria-describedby and aria-labelledby attributes are false positives. The error is happening due to the form being built dynamically on the page and the validation checker not seeing all of the form requirements due to this. When the form is loaded and you inspect the form on a page, the aria attributes are present.

    Thread Starter vbak

    (@vbak)

    @jmcelhaney Yes, I understand they are false positives and that the proper labels appear after the forms are dynamically generated. I mentioned that in the original post.

    I’m suggesting a possible solution to get around that however. Using the aria-busy attribute should help alleviate this false positive, by not checking for those attributes until aria-busy is false (When the forms finish dynamically loading)

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.