How to make element not focusable with tab navigation

want to use button element but Its imperative that you cant select it with tab
6 Replies
13eck
13eck2y ago
Why is it imperative that you can't select it via tab? That's super not accessible.
MartynasXS
MartynasXSOP2y ago
its electron window frame
13eck
13eck2y ago
No idea what that is, but you want to set a negative tabindex on the element:
A negative value (the exact negative value doesn't actually matter, usually tabindex="-1") means that the element is not reachable via sequential keyboard navigation.
https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex
MartynasXS
MartynasXSOP2y ago
MartynasXS
MartynasXSOP2y ago
Thanks!
13eck
13eck2y ago
👍
Want results from more Discord servers?
Add your server