From 3821c8a7e22690933c99488e5c31177638269000 Mon Sep 17 00:00:00 2001
From: Joey Arhar Otherwise, if submitter has a value,
then set result to that value. Close the dialog subject with result. Close the dialog subject with result and
+ null. Return. The showModal()
method steps are to show a modal
- dialog given this.
The close(returnValue)
method steps are:
@@ -62302,7 +62303,8 @@ interface HTMLDialogElement : HTMLElement {
If returnValue is not given, then set it to null.
Close the dialog this with returnValue.
Close the dialog this with returnValue and + null.
The HTMLDialogElement
: HTMLElement {
removedNode's node document's open dialogs list.
To show a modal dialog given a dialog
element subject:
To show a modal dialog given a dialog
element subject and an
+ Element
or null invoker:
If subject has an open
attribute and
@@ -62465,9 +62468,10 @@ interface HTMLDialogElement : HTMLElement {
data-x="event-beforetoggle">beforetoggle, using ToggleEvent
, with the cancelable
attribute initialized to true, the oldState
attribute initialized to "closed
", and the newState
- attribute initialized to "open
" at subject is false, then
- return.
newState
+ attribute initialized to "open
", and the invoker
attribute set to invoker at
+ subject is false, then return.
If subject has an open
attribute,
then return.
Queue a dialog toggle event task given subject, "closed
", and "open
".
open
", and invoker.
Add an open
attribute to subject, whose
value is the empty string.
Let value be invoker's value.
Close the dialog element with value.
Close the dialog element with value and + invoker.
If command is the Show Modal state and element does
not have an open
attribute, then
- show a modal dialog given element.
When a dialog
element subject is to be closed, with null or a string result, run these steps:
Element
or null
+ invoker, run these steps:
If subject does not have an open
@@ -62633,14 +62639,16 @@ interface HTMLDialogElement : HTMLElement {
Fire an event named beforetoggle
, using ToggleEvent
, with the oldState
attribute initialized to "open
" and the newState
attribute
- initialized to "closed
" at subject.
newState
attribute
+ initialized to "closed
", and the invoker
attribute set to invoker at
+ subject.
If subject does not have an open
attribute, then return.
Queue a dialog toggle event task given subject, "open
", and "closed
".
closed
", and invoker.
Remove subject's open
attribute.
To queue a dialog toggle event task given a dialog
element
- element, a string oldState, and a string newState:
+ element, a string oldState, a string newState, and an
+ Element
or null invoker:
Fire an event named toggle
at element, using ToggleEvent
, with
the oldState
attribute initialized to
- oldState and the newState
attribute
- initialized to newState.
newState
attribute
+ initialized to newState, and the invoker
attribute initialized to
+ invoker.
Set element's dialog toggle task tracker to null.
Set to "open
" when transitioning from closed to open, or set to "closed
" when transitioning from open to closed.
event.invoker
Set to the element which initiated the toggle, which can be set up with the popovertarget
and commandfor
attributes. If there is no invoker element,
+ then it is set to null.
The ToggleEventInit
: EventInit {
data-x="dom-ToggleEvent-newState">newState attributes must return the values they are
initialized to.
The invoker
getter steps are to return the result of
+ retargeting invoker
against this's currentTarget
.
DOM standard issue #1328 + tracks how to better standardize associated event data in a way which makes sense on Events. + Currently an event attribute initialized to a value cannot also have a getter, and so an internal + slot (or map of additional fields) is required to properly specify this.
+A toggle task tracker is a struct which has:
ToggleEvent
, with the cancelable
attribute initialized to true, the oldState
attribute initialized to "closed
", and the newState
- attribute initialized to "open
" at element is false, then
- run cleanupShowingFlag and return.
+ data-x="">closed", the newState
attribute
+ initialized to "open
" at element, and the invoker
attribute initialized to invoker is
+ false, then run cleanupShowingFlag and return.
If the result of running check popover validity given element, false, @@ -86949,13 +86983,14 @@ dictionary DragEventInit : MouseEventInit { previously focused element to originallyFocusedElement.
Queue a popover toggle event task given element, "closed
", and "open
".
open
", and invoker.
Run cleanupShowingFlag.
To queue a popover toggle event task given an element element, a string
- oldState, and a string newState:
+ oldState, a string newState, and an Element
or null
+ invoker:
Fire an event named toggle
at element, using ToggleEvent
, with
the oldState
attribute initialized to
- oldState and the newState
attribute
- initialized to newState.
newState
attribute
+ initialized to newState, and the invoker
attribute initialized to
+ invoker.
Set element's popover toggle task tracker to null.
Let invoker be element's popover invoker.
Set element's popover invoker to null.
Fire an event named beforetoggle
, using ToggleEvent
, with the oldState
attribute initialized to "open
" and the newState
- attribute initialized to "closed
" at element.
newState
+ attribute initialized to "closed
", and the invoker
attribute set to invoker at
+ element.
If autoPopoverListContainsElement is true and document's showing auto popover list's last item is not element, then run DragEventInit : MouseEventInit { data-x="popover-hidden-state">hidden.
If fireEvents is true, then queue a popover toggle event task
- given element, "open
", and "closed
".
open
", "closed
", and
+ invoker.
Let previouslyFocusedElement be element's previously focused element.
closed
", the newState
attribute initialized to "open
", and the invoker
attribute set to invoker at
+ data-x="dom-ToggleEvent-source">source attribute set to invoker at
subject is false, then return.
If subject has an open
attribute,
@@ -62641,7 +62641,7 @@ interface HTMLDialogElement : HTMLElement {
data-x="dom-ToggleEvent-oldState">oldState attribute initialized to "open
", the newState
attribute
initialized to "closed
", and the invoker
attribute set to invoker at
+ data-x="dom-ToggleEvent-source">source attribute set to invoker at
subject.
If subject does not have an open
@@ -62735,7 +62735,7 @@ interface HTMLDialogElement : HTMLElement {
the oldState
attribute initialized to
oldState, the newState
attribute
initialized to newState, and the invoker
attribute initialized to
+ data-x="dom-ToggleEvent-source">source attribute initialized to
invoker.
Set element's dialog toggle task tracker to null.
event.invoker
Set to the element which initiated the toggle, which can be set up with the popovertarget
and commandfor
attributes. If there is no invoker element,
+ data-x="attr-button-commandfor">commandfor attributes. If there is no source element,
then it is set to null.
The invoker
getter steps are to return the result of
+ data-x="dom-ToggleEvent-source">source getter steps are to return the result of
retargeting invoker
against this's source
against this's currentTarget
.
DOM standard issue #1328
@@ -86785,7 +86785,7 @@ dictionary DragEventInit : MouseEventInit {
data-x="dom-ToggleEvent-oldState">oldState attribute initialized to "closed
", the newState
attribute
initialized to "open
" at element, and the invoker
attribute initialized to invoker is
+ data-x="dom-ToggleEvent-source">source attribute initialized to invoker is
false, then run cleanupShowingFlag and return.
oldState
attribute initialized to
oldState, the newState
attribute
initialized to newState, and the invoker
attribute initialized to
+ data-x="dom-ToggleEvent-source">source attribute initialized to
invoker.Set element's popover toggle task tracker to null.
open
", the newState
attribute initialized to "closed
", and the invoker
attribute set to invoker at
+ data-x="dom-ToggleEvent-source">source attribute set to invoker at
element.
If autoPopoverListContainsElement is true and document's
From b3331a6cd1f1714e05c7366f7a8835bc1b923e29 Mon Sep 17 00:00:00 2001
From: Joey Arhar If removedNode's popover
attribute is not in
the no popover state, then run the hide
- popover algorithm given removedNode, false, false, and false.
The moving steps for the HTML Standard, given @@ -53745,7 +53745,8 @@ interface HTMLButtonElement : HTMLElement {
If the result of running check popover validity given target, true, false, and null is true, then run the - hide popover algorithm given target, true, true, and false.
Otheriwse, if the result of running check popover validity given target, true, false, and null is true, then run the hide popover algorithm given target, true, - true, and false.
If element's popover visibility state is in the showing state and oldValue and value are in different states, then run the hide popover - algorithm given element, true, true, and false.
closeAction being to hide a popover given element, true, true, - and false.
getEnabledState being to return true.
Run the hide popover algorithm given this, true, true, and - true.
Run the hide popover algorithm given this, true, true, true, and + null.
To hide a popover given an HTML element element, a boolean focusPreviousElement, a - boolean fireEvents, and a boolean throwExceptions:
+ boolean fireEvents, a boolean throwExceptions, and an HTML element or null invoker:If the result of running check popover validity given element, @@ -87169,8 +87171,6 @@ dictionary DragEventInit : MouseEventInit { showing auto popover list's last item is element, otherwise false.
Let invoker be element's popover invoker.
Set element's popover invoker to null.
If this's popover visibility state is showing, and force is null or false, then run - the hide popover algorithm given this, true, true, and true.
Otherwise, if force is null or true, then run show popover given this, true, and invoker.
Assert: popoverList is not empty.
Run the hide popover algorithm given the last item in - popoverList, focusPreviousElement, fireEvents, and - false.
Run the hide popover algorithm given popoverList's last item, - focusPreviousElement, fireEvents, and false.
If popover's popover visibility state is showing, then run the hide popover algorithm - given popover, true, true, and false.
Otherwise, if popover's popover visibility state is hidden and the result of running check popover
From f88886b4eeb05943117bffc9220bd9f14f40935b Mon Sep 17 00:00:00 2001
From: Joey Arhar
If removedNode's popover
attribute is not in
- the No popover state, then run the hide
+ the No Popover State, then run the hide
popover algorithm given removedNode, false, false, false, and null.
closed
", the newState
attribute initialized to "open
", and the source
attribute set to invoker at
+ data-x="dom-ToggleEvent-source">source attribute initialized to invoker at
subject is false, then return.
If subject has an open
attribute,
@@ -62672,7 +62672,7 @@ interface HTMLDialogElement : HTMLElement {
data-x="dom-ToggleEvent-oldState">oldState attribute initialized to "open
", the newState
attribute
initialized to "closed
", and the source
attribute set to invoker at
+ data-x="dom-ToggleEvent-source">source attribute initialized to invoker at
subject.
If subject does not have an open
@@ -62768,7 +62768,7 @@ interface HTMLDialogElement : HTMLElement {
To queue a dialog toggle event task given a dialog
element
element, a string oldState, a string newState, and an
- Element
or null invoker:
+ Element
or null source:
newState
attribute
initialized to newState, and the source
attribute initialized to
- invoker.Set element's dialog toggle task tracker to null.
To queue a popover toggle event task given an element element, a string
oldState, a string newState, and an Element
or null
- invoker:
+ source:
newState
attribute
initialized to newState, and the source
attribute initialized to
- invoker.Set element's popover toggle task tracker to null.
Queue a dialog toggle event task given this, "closed
", and "open
".
open
", and null.
Add an open
attribute to this, whose
value is the empty string.
If returnValue is not given, then set it to null.
Request to close the dialog this - with returnValue.
To show a modal dialog given a dialog
element subject and an
- Element
or null invoker:
Element
or null source:
If subject has an open
attribute and
@@ -62502,7 +62502,7 @@ interface HTMLDialogElement : HTMLElement {
data-x="dom-ToggleEvent-oldState">oldState attribute initialized to "closed
", the newState
attribute initialized to "open
", and the source
attribute initialized to invoker at
+ data-x="dom-ToggleEvent-source">source attribute initialized to source at
subject is false, then return.
If subject has an open
attribute,
@@ -62514,7 +62514,7 @@ interface HTMLDialogElement : HTMLElement {
state, then return.
Queue a dialog toggle event task given subject, "closed
", "open
", and invoker.
open
", and source.
Add an open
attribute to subject, whose
value is the empty string.
When a dialog
element subject is to be closed, with null or a string result and an Element
or null
- invoker, run these steps:
If subject does not have an open
@@ -62672,14 +62672,14 @@ interface HTMLDialogElement : HTMLElement {
data-x="dom-ToggleEvent-oldState">oldState attribute initialized to "open
", the newState
attribute
initialized to "closed
", and the source
attribute initialized to invoker at
+ data-x="dom-ToggleEvent-source">source attribute initialized to source at
subject.
If subject does not have an open
attribute, then return.
Queue a dialog toggle event task given subject, "open
", "closed
", and invoker.
closed
", and source.
Remove subject's open
attribute.
Remove subject from subject's node document's open dialogs list.
If result is not null, then set the If result is not null, then set subject's returnValue
attribute to result.
Set the request close return value to null.
Set subject's request close return value to null.
Set the request close source element to null.
Set subject's request close source element to null.
If subject's previously focused element is not null, then:
@@ -62739,7 +62739,7 @@ interface HTMLDialogElement : HTMLElement {To request to close dialog
element
subject, given null or a string returnValue and null or an
- Element
invoker:
Element
source:
If subject does not have an open
@@ -62755,7 +62755,7 @@ interface HTMLDialogElement : HTMLElement {
returnValue.
Set subject's request close source element to - invoker.
Request to close subject's close watcher with false.
To hide a popover given an HTML element element, a boolean focusPreviousElement, a boolean fireEvents, a boolean throwExceptions, and an HTML element or null invoker:
+ elements">HTML element or null source:If the result of running check popover validity given element,
@@ -87090,7 +87090,7 @@ dictionary DragEventInit : MouseEventInit {
data-x="dom-ToggleEvent-oldState">oldState attribute initialized to "open
", the newState
attribute initialized to "closed
", and the source
attribute set to invoker at
+ data-x="dom-ToggleEvent-source">source attribute set to source at
element.
If autoPopoverListContainsElement is true and document's @@ -87127,7 +87127,7 @@ dictionary DragEventInit : MouseEventInit {
If fireEvents is true, then queue a popover toggle event task
given element, "open
", "closed
", and
- invoker.
Let previouslyFocusedElement be element's previously focused element.
Each dialog
element has a request close return value, which is a
- string, initially null.
Each dialog
element has a request close source element, which is an
- Element
, initially null.
Element
or null, initially null.
Each dialog
element has an enable close watcher for request close boolean,