Enhancement Request for Select Component - Adding cause Attribute to onHighlightChange Event #1092
AndrejNemec
started this conversation in
Ideas
Replies: 1 comment 3 replies
-
|
Hi, thank you for the proposition. It's a subject to the Zag. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'd like to propose an enhancement to the Select component, specifically related to the
onHighlightChangeevent. It would be highly beneficial to include an additional attribute:cause, in the event details. This attribute would store information about the event that triggeredonHighlightChange.The main reason for this enhancement is to aid in the development of virtual selectors. Currently, when creating a virtual selector, invoking
scrollToIndexfrom a virtualizer within theonHighlightChangeevent is also executed during hover actions. This can cause undesirable shaking if the element is outside of the viewport.The proposed
causeattribute would have values like 'hover', 'keyboard', 'typeahead', 'open', etc.This addition would provide more control and precision in handling different scenarios, improving the usability and functionality of virtual selectors.Beta Was this translation helpful? Give feedback.
All reactions