Comments (4)
@josepharhar will be able to answer this succinctly.
from html.
I think it would introduce complexity and unexpected states to allow switching between popover types without closing the popover. For example, we currently only allow multiple popover=auto popovers to be open if they are associated via a relationship, such as if one is a dom ancestor of another. If we allowed an unrelated popover to switch from popover=manual to popover=auto, should we close all other popover=auto popovers? If we don't then other algorithms would encounter an invalid state, and if we do then we have to add a bunch of partially duplicated code from the hide popover algorithm.
I have a case: there's a global tooltip (implements with popover also) in popover (call it "X" alias).
When the X popover shown, then shows the global tooltip, the X popover auto closed.
Why does your popover need to change states after opening? Why can't it just have popover=manual before it opens?
from html.
@josepharhar Thanks for your reply.
In my case, the popover and tooltip both needs light dismiss, so it setted as auto.
But when the tooltip shows, don't want to hide it.
So changed it's attribute from auto to manual when tooltip shows, and change back after closed.
Maybe the only case is tooltip, a global one without ancestor relationship to other elements.
from html.
Ah I see your use case, it would be perfectly handled by the proposed popover=hint value:
#9776
#9778
I'm going to close this issue in favor of #9776
Please comment there if that proposal doesn't fit your use case in any way, but I believe it will.
from html.
Related Issues (20)
- Should dir=auto with no strong characters inherit directionality from parent or be ltr? HOT 10
- Navigation: DocumentState request referrer is not set for about:srcdoc
- `<callout>` element for callouts/alerts/admonitions HOT 35
- Proposal: HTML Attribute to state non-consent when scraping for training datasets HOT 1
- Can a task throw exceptions? HOT 2
- "run a classic script" returns completion records and throws HOT 1
- Session history step of top level navigable when child navigables traverse history HOT 1
- Should there be an opt-out for declarative shadow roots having `clonable=true`? HOT 27
- Should `<a target="_blank">` and `window.open` consume the transient activation? HOT 2
- `<img sizes="auto, 100px" loading="eager">`: `auto` equates to `100wv` but should ideally be ignored
- Constrain OffscreenCanvas with a placeholder canvas element HOT 8
- A way to run code before the next frame HOT 8
- New attribute for avoiding to autocapitalize text input fields HOT 1
- Autocomplete attribute value to indicate form input is third-party data
- Improve API of `insertAdjacent*()` methods HOT 2
- Read-only state for buttons? HOT 9
- Upcoming WHATNOT meeting on 2/22/2024 HOT 5
- attribute change steps for popover may fire events synchronously HOT 6
- Update UA stylesheet rules to use `:any-link` instead of `:visited` or `:link` HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from html.