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
{{ message }}
Repository navigation
What should happen if you open an auto popover 'within' a hint popover? #12346
Option 2: Show it, but immediately hide it without events
This sounds weird, but it's what happens if you show a popover in the beforetoggle-hide of another popover.
However, I'm not sure this is a good idea, as you'd still get the side-effects of showing the auto popover, and it being a no-op feels better. In fact, I kinda wish this is what happened in the beforetoggle case.
Option 3: Downgrade to hint
Allow the popover to be shown, but show it as a hint. This allows the popover to show, but it would interact with other popovers as a hint, which may be confusing.
One use-case worth considering is custom-select, which uses an auto popover for its picker. Do we want a <select> to work in a hint popover?
An example could be a hover menu which contains options like a currency/language picker. Although I think you could argue that this shouldn't be a hint popover, even if it activates on hover.
A popover=auto can never be nested inside a popover=hint.
I can’t seem to find an explanation in the explainer to why that restriction is there. Are there situations where this would make things very complicated? If not, perhaps a 4th option is “remove the restriction”?
Well opening an auto inside a hint just doesn't really make any sense. What would lifting the restriction actually look like? What would be the use case?
I was thinking of the use-case Jake mentioned at the end of the OP: a customizable select (which uses a popover=auto for the picker) inside a popover=hint.
But like Jake said, one could argue that one shouldn’t be building it that way.
Given <select> now has a popover in appearance base, for which it is not possible to turn into a hint, I think we should allow nested autos to be demoted to hints. Therefore option 3 is my vote.
I think demoting to hint somewhat makes sense, I think the behaviour naturally flows out (in that there's a reasonable default answer for a lot of the questions that come out of that decision). I also think option 3 aligns with priority of constituencies, in that the browser is doing its best to recover from a developer error, meaning that the user actually gets something, rather than nothing.
I think throwing is problematic as the best we can do on declarative instantiation is console.error. Some developers don't really check the console (or the console is now so noisy that signal/noise ratio is past the precipice), so those messages don't necessarily have quite the impact I think we might believe they do. I've paired with developers who've missed console messages because the staging/development environment is too noisy, or they don't have it open, or they simply filter the console window to try and get the noise down.
There are many instances of "developers shouldn't be building it that way" - my worry is that can be conflated with "developers won't be building it that way" or even that "developers" is a singular person or team. In some orgs the person who manages the button might be a different person (or in a different team) to the person who manages the popover, which is different to the team managing the parent popover, and so these things may break in ways which are unexpected - shifting like tectonic plates.
@keithamus so are you saying the downgrade to hint would happen without any kind of console warning? I guess it would be weird to warn about <select> when there isn't much the developer can do about it.
Given <select> now has a popover in appearance base, for which it is not possible to turn into a hint
Does it make sense turn a select popover into a popover=hint, does that break anything? I guess we could define it as a manual and then define extra behaviour but that's probably not worth it.
I can’t seem to find an explanation in the explainer to why that restriction is there. Are there situations where this would make things very complicated?
Yes but maybe that shouldn't stop us. Right now, the model is like this:
There are two lists, where the hint list may be anchored to one of the items in the auto list. The model you're talking about would be a tree I guess. So yeah, a jump in complexity, but not impossible.
If our guiding rules are:
Showing a hint popover hides all other non-ancestor hint popovers.
Showing an auto popover hides all non-ancestor hint and auto popovers.
Hiding a hint or auto popover also hides child hint and auto popovers.
Clicking somewhere hides all hint and auto popovers aside from the closest clicked hint and auto popovers and its ancestors.
…we could make that work with a tree structure. It's just quite a change.
Does it make sense turn a select popover into a popover=hint, does that break anything? I guess we could define it as a manual and then define extra behaviour but that's probably not worth it.
One of the weirdness I encountered with popover=hint is that its interaction with popopver=auto would change in the nested situation, because to some degree the spec/implementation was 'upgrading' the nested hint to an auto. So I expect to some degree, the downgrade would seem weird if developers encountered it.
For example, it would mean that opening a sibling hint would close the select picker, which generally wouldn't happen, because hints don't close autos. But if they're both hints, then one would close the other.
@keithamus so are you saying the downgrade to hint would happen without any kind of console warning? I guess it would be weird to warn about <select> when there isn't much the developer can do about it.
I think we can still console.warn.
@mfreed7 is there any benefit to taking this to Open UI?
I think we can likely resolve this here. Not averse to raising it in OpenUI though.
Sorry for the delay. So I was in the option-1 camp until I read @keithamus 's comment above, which kind of convinced me that perhaps option-3 is the right answer here. I'm still a bit concerned that it will increase the complexity of the algorithms a bit, since we can no longer "trust" the attribute value to tell us what kind of popover it is. But I'm convinced by the real-sounding use case of a customizable-<select> inside a popover=hint. I don't think we should disallow that, since the fix for developers there is fairly harsh - convert the hint to an auto, etc.
I think it might be going too far to just remove the restriction entirely, since that really complicates the algorithms, and I'm not sure it's a net benefit to developers. I'm certainly not in favor of switching customizable-<select> to popover=manual because I do think the picker should play very nicely with other popover=auto's.
How about we just store a bit on each popover that keeps track of whether it's an "auto demoted to hint", and work that into the existing algorithms that look for hint popovers? That would seem to fix the known use case of <select> inside hint, and shouldn't involve too much collateral damage, I think.
Activity
jakearchibald commentedon Apr 8, 2026
@mfreed7 @keithamus @lukewarlow any thoughts?
lukewarlow commentedon Apr 8, 2026
I vote for option 1. It's easily detectable so might aswell make it throw.
bramus commentedon Apr 8, 2026
I can’t seem to find an explanation in the explainer to why that restriction is there. Are there situations where this would make things very complicated? If not, perhaps a 4th option is “remove the restriction”?
lukewarlow commentedon Apr 8, 2026
Well opening an auto inside a hint just doesn't really make any sense. What would lifting the restriction actually look like? What would be the use case?
bramus commentedon Apr 9, 2026
I was thinking of the use-case Jake mentioned at the end of the OP: a customizable select (which uses a
popover=autofor the picker) inside apopover=hint.But like Jake said, one could argue that one shouldn’t be building it that way.
keithamus commentedon Apr 9, 2026
Given
<select>now has a popover in appearance base, for which it is not possible to turn into a hint, I think we should allow nested autos to be demoted to hints. Therefore option 3 is my vote.I think demoting to hint somewhat makes sense, I think the behaviour naturally flows out (in that there's a reasonable default answer for a lot of the questions that come out of that decision). I also think option 3 aligns with priority of constituencies, in that the browser is doing its best to recover from a developer error, meaning that the user actually gets something, rather than nothing.
I think throwing is problematic as the best we can do on declarative instantiation is
console.error. Some developers don't really check the console (or the console is now so noisy that signal/noise ratio is past the precipice), so those messages don't necessarily have quite the impact I think we might believe they do. I've paired with developers who've missed console messages because the staging/development environment is too noisy, or they don't have it open, or they simply filter the console window to try and get the noise down.There are many instances of "developers shouldn't be building it that way" - my worry is that can be conflated with "developers won't be building it that way" or even that "developers" is a singular person or team. In some orgs the person who manages the button might be a different person (or in a different team) to the person who manages the popover, which is different to the team managing the parent popover, and so these things may break in ways which are unexpected - shifting like tectonic plates.
jakearchibald commentedon Apr 9, 2026
@keithamus so are you saying the downgrade to hint would happen without any kind of console warning? I guess it would be weird to warn about
<select>when there isn't much the developer can do about it.We could solve this problem?
lukewarlow commentedon Apr 9, 2026
Does it make sense turn a select popover into a popover=hint, does that break anything? I guess we could define it as a manual and then define extra behaviour but that's probably not worth it.
jakearchibald commentedon Apr 9, 2026
@bramus
Yes but maybe that shouldn't stop us. Right now, the model is like this:
There are two lists, where the hint list may be anchored to one of the items in the auto list. The model you're talking about would be a tree I guess. So yeah, a jump in complexity, but not impossible.
If our guiding rules are:
hintpopover hides all other non-ancestorhintpopovers.autopopover hides all non-ancestorhintandautopopovers.hintorautopopover also hides childhintandautopopovers.hintandautopopovers aside from the closest clickedhintandautopopovers and its ancestors.…we could make that work with a tree structure. It's just quite a change.
jakearchibald commentedon Apr 9, 2026
I know this is kicking the can down the road, but it'd be easier to go from throwing/failure to something else later, than any of the other options.
jakearchibald commentedon Apr 9, 2026
@lukewarlow
One of the weirdness I encountered with
popover=hintis that its interaction withpopopver=autowould change in the nested situation, because to some degree the spec/implementation was 'upgrading' the nested hint to an auto. So I expect to some degree, the downgrade would seem weird if developers encountered it.For example, it would mean that opening a sibling hint would close the select picker, which generally wouldn't happen, because hints don't close autos. But if they're both hints, then one would close the other.
jakearchibald commentedon Apr 9, 2026
@mfreed7 is there any benefit to taking this to Open UI?
bramus commentedon Apr 9, 2026
Which seems reasonable.
keithamus commentedon Apr 9, 2026
I think we can still
console.warn.I think we can likely resolve this here. Not averse to raising it in OpenUI though.
mfreed7 commentedon Apr 15, 2026
Sorry for the delay. So I was in the option-1 camp until I read @keithamus 's comment above, which kind of convinced me that perhaps option-3 is the right answer here. I'm still a bit concerned that it will increase the complexity of the algorithms a bit, since we can no longer "trust" the attribute value to tell us what kind of popover it is. But I'm convinced by the real-sounding use case of a customizable-
<select>inside apopover=hint. I don't think we should disallow that, since the fix for developers there is fairly harsh - convert thehintto anauto, etc.I think it might be going too far to just remove the restriction entirely, since that really complicates the algorithms, and I'm not sure it's a net benefit to developers. I'm certainly not in favor of switching customizable-
<select>topopover=manualbecause I do think the picker should play very nicely with otherpopover=auto's.How about we just store a bit on each popover that keeps track of whether it's an "auto demoted to hint", and work that into the existing algorithms that look for hint popovers? That would seem to fix the known use case of
<select>insidehint, and shouldn't involve too much collateral damage, I think.mfreed7 commentedon Apr 15, 2026
For this reason, I've made Chromium throw for this case right now. I'm hoping to get the overall behavior change out the door this month if I can.
jakearchibald commentedon Apr 16, 2026
Ok, I can spec option 3.
jakearchibald commentedon Apr 17, 2026
#12345 now specs option 3.