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
I am building a UI that requires the ability to open/close the ListBox programmatically from a different component. The documentation for ListBox has a section on controlling open/close states, but the solution it provides involves passing an open boolean argument to the ListBox child, which allows determining the open status, but not for changing it, as far as I can tell.
I tried to work around this by introducing my own open state variable, and using it to set the visibility CSS property of Listbox.Options, but this introduces a strange issue where the ListBox is sometimes not in focus when it is opened, and so the hover styling effects don't work. Is there any other way around this problem?
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
Uh oh!
There was an error while loading. Please reload this page.
-
I am building a UI that requires the ability to open/close the
ListBox
programmatically from a different component. The documentation forListBox
has a section on controlling open/close states, but the solution it provides involves passing anopen
boolean argument to theListBox
child, which allows determining the open status, but not for changing it, as far as I can tell.I tried to work around this by introducing my own
open
state variable, and using it to set thevisibility
CSS property ofListbox.Options
, but this introduces a strange issue where theListBox
is sometimes not in focus when it is opened, and so the hover styling effects don't work. Is there any other way around this problem?Beta Was this translation helpful? Give feedback.
All reactions