JS event handlers

Hi all.

 I have a text input with the following JS event handlers: change/input/keydown/keyup

When a screen reader is registering their Email address for example on a form and then press the Esc key to exit that form element, the page closed and redirected the user back to the previous page when using the Esc key.  I have removed both keyup/keydown even and the Esc issue is resolved.

I have found the following failure Pointer Cancellation (A)and wondered if I was heading in the right direction: https://www.w3.org/WAI/WCAG21/Techniques/general/G212 and https://www.w3.org/WAI/WCAG21/Techniques/failures/F101

Thank you.

Tom
G212: Using native controls to ensure functionality is triggered on the up-event. - W3<https://www.w3.org/WAI/WCAG21/Techniques/general/G212>
The <button> element doesn't do anything on its own (unless its part of a <form>, and does NOT have <type="button">, in which case it submits the form).Authors should rely on input-agnostic click handlers.
www.w3.org

Received on Wednesday, 26 October 2022 06:19:35 UTC