You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The RadioGroup component applies focus on both keyboard interaction and mouse clicks. While this behavior is standard and beneficial for accessibility, it might limit flexibility for certain use cases.`
In some scenarios, developers may want to differentiate between focus applied via keyboard and focus applied via mouse click. For example, preventing the focus ring from appearing when a radio button is selected with a mouse click while maintaining focus visibility for keyboard navigation. This differentiation is important for creating a more customized user experience and adhering to specific design requirements.
Suggestion:
It would be beneficial to provide a way to disable focus on mouse clicks while preserving keyboard accessibility. This could be achieved through an additional prop or configuration option that allows developers to customize focus behavior based on their needs.
Implement focus styling, with for example a recipe with PandaCSS and add a _focus on itemControl.
Observe the focus being apply on both click and keyboard.
This discussion was converted from issue #2718 on August 02, 2024 10:00.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Description
The RadioGroup component applies focus on both keyboard interaction and mouse clicks. While this behavior is standard and beneficial for accessibility, it might limit flexibility for certain use cases.`
In some scenarios, developers may want to differentiate between focus applied via keyboard and focus applied via mouse click. For example, preventing the focus ring from appearing when a radio button is selected with a mouse click while maintaining focus visibility for keyboard navigation. This differentiation is important for creating a more customized user experience and adhering to specific design requirements.
Suggestion:
It would be beneficial to provide a way to disable focus on mouse clicks while preserving keyboard accessibility. This could be achieved through an additional prop or configuration option that allows developers to customize focus behavior based on their needs.
Link to Reproduction (or Detailed Explanation)
https://ark-ui.com/react/docs/components/radio-group
Steps to Reproduce
_focus
onitemControl
.Observe the focus being apply on both click and keyboard.
Ark UI Version
3.6.2
Framework
Browser
Google Chrome
Thanks for your help 😃
Beta Was this translation helpful? Give feedback.
All reactions