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've been facing this weird issue where the togglePopover doesn't work when it is for closing the popover on a element (I don't know if it's the only element that has this issue though).
My popover is set to auto (by default) and I toggle it with that method (which always wroked well until then, but I may be missing something) (never faced any issue with popovertarget, that's what I mean).
After doing my best to debug it, I've found that the beforetoggle event is triggered twice (close then open) (but not the toggle one, strangely). => if I prevent the opening one (when concurrent with the closing one), then everything works find (this is my only workaround for now).
i looked at your codepen and noticed you commented out the workaround. did you end up resolving your issue? i'm not having issues opening or closing the popovers in your test using mouse or keyboard? maybe i'm missing something.
but with that said - i'm not sure i really understand the use case here. why you wouldn't put a button within those TDs to mitigate the issue you're potentially facing / make this accessible for people using screen readers. TD elements (role=cell) don't support the expanded state in the a11y tree, so there'd be a lot of extra work needed to ensure this behavior would be properly conveyed to people using screen readers. That is, unless you nested button elements inside the TDs and used those to toggle the popovers - then no JS or extra ARIA for your buttons would be necessary.
What is the issue with the HTML Standard?
I've been facing this weird issue where the
togglePopover
doesn't work when it is for closing the popover on a element (I don't know if it's the only element that has this issue though).My popover is set to
auto
(by default) and I toggle it with that method (which always wroked well until then, but I may be missing something) (never faced any issue with popovertarget, that's what I mean).After doing my best to debug it, I've found that the
beforetoggle
event is triggered twice (close then open) (but not thetoggle
one, strangely). => if I prevent the opening one (when concurrent with the closing one), then everything works find (this is my only workaround for now).Here is a reproduction of the issue (and warkaround) https://codepen.io/lcsga/pen/wBwPeMY
If I forget to provide some other needed informations, let me know, I'd do my best to complete it asap!
The text was updated successfully, but these errors were encountered: