Open keithamus opened 12 months ago
I vote "don't implement". ToggleOpen isn't a perfect representation of what it does (given focusing) so I would vote against that.
The Open UI Community Group just discussed [invokers] Dialog's `toggle` needs a better name
, and agreed to the following:
RESOLVED: Defer `toggle` and `show`, remove the explicit `toggleModal` string, and keep `auto` behaviours as is.
The separation of concerns IMO needs separate attributes:
It is important as provide each functionality separately and do not mix those. As the imperative as declarative syntax for all. In this case declarative can be limited by allocation of DIALOG attributes.
open
as name for visibility to match the other HTML elements like in details element
triggering the next UI on the toggle
as pointer to the what should happen to element refered say by for
attribute. Scenario:
open=true
attributefor
attributetoggle
attributethe modal
vs popover
vs inline
is rather the subject for mode
attribute of Dialog.
There hasn't been any discussion on this issue for a while, so we're marking it as stale. If you choose to kick off the discussion again, we'll remove the 'stale' label.
Invokers targeting a
<dialog>
can haveinvokeaction=toggle
, which will open and close the dialog as non-modal.toggle
is a little ambiguous, especially as all other names are very clear in their action,togglePopover
,playpause
, etc.Given https://github.com/whatwg/html/issues/9376 (Should we deprecate Dialog
show()
?) perhaps we can simply not implement this?If we are to implement this, it needs a clearer name. Some bad ideas to start the bidding:
toggleNonModal
toggleOpen
toggleShow