Focus trap focuses the wrong radio button if native radio button group is the first element in modal
- Lingua principale
- TypeScript
- Stelle
- 25k
- Fork
- 6.8k
- Merge medio
- 1g 8h
- PR unite (30g)
- 91
Descrizione
If the first focus-able element in a modal is a group of (native element, **not** Material) radio buttons, and one tabs off the end of the modal (triggering the focus trap and returning the focus to the top of the modal), the first radio button is always focused, even if the selected radio button is one of the later ones.
The expected behavior—found when tabbing to a group of radio buttons in other cases—is for focus to go to the selected radio button.
For now, our workaround is just to ensure there is always some other focus-able element at the top of the modal. A close button works well for this.
I could not find any issues relating to this.
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Riproduci il problema con un modal il cui primo contenuto focalizzabile è un gruppo nativo di pulsanti radio, quindi esci dal modal con Tab per attivare il focus trap. Traccia il comportamento del focus trap del modal e la gestione del focus del gruppo radio; il lavoro è completato quando il focus torna al pulsante radio selezionato invece che al primo pulsante.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- angular, typescript
- Ambito
- accessibility, frontend
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 38/100