-
Notifications
You must be signed in to change notification settings - Fork 757
Open
Labels
Description
I was reading this article and I reached this gem:
const FOCUSABLE_SELECTORS = [
'[contenteditable]',
'[tabindex="0"]:not([disabled])',
'a[href]',
'audio[controls]',
'button:not([disabled])',
'iframe',
"input:not([disabled]):not([type='hidden'])",
'select:not([disabled])',
'summary',
'textarea:not([disabled])',
'video[controls]',
].join(',');Authors should not have to do all this just to target focusable elements (not to mention even this won't catch some…). Adding a pseudo-class for focusability seems like pretty low-hanging fruit (so low-hanging that I'd swear I've seen it discussed before, but I couldn't find anything so…)
jimmyfrasche, muratcorlu, Schweinepriester, Malvoz, kizu and 8 morejimmyfrasche and Malvozjimmyfrasche and Malvozjimmyfrasche and Malvozjimmyfrasche and Schweinepriester