diff --git a/source b/source index 295577fcfa1..f2c738a13f5 100644 --- a/source +++ b/source @@ -45686,7 +45686,8 @@ interface HTMLInputElement : HTMLElement { // also has obsolete members }; -HTMLInputElement includes PopoverInvokerElement; +HTMLInputElement includes PopoverInvokerElement; +HTMLInputElement includes DialogInvokerElement;
HTMLInputElement
.HTMLButtonElement
.Buttons may have the following content attributes:
+ +dialogmoddaltarget
If specified, the dialogmodaltarget
attribute value must
+ be the ID of a dialog element
+ in the same tree as the button with the
+ dialogmodaltarget
attribute.
The following shows how the dialogmodaltarget
attribute
+ can be used to show and close a dialog:
<button dialogmodaltarget="foo">
+ Show a dialog (modal)
+</button>
+
+<dialog id="foo">
+ This is a dialog!
+ <button dialogmodaltarget="foo">Close</button>
+</article>
+ interface mixin DialogInvokerElement {
+ [CEReactions] attribute Element? dialogModalTargetElement;
+};
+
+ The dialogModalTargetElement
IDL attribute must
+ reflect the dialogmodaltarget
attribute.
To run the dialog modal target attribute activation behavior given a Node
+ node:
Let dialog be node's dialog modal target element.
If dialog is null, then return.
If the open
attribute is set on node
+ then:
+
+
Run close()
Otherwise, run showModal()
on node
To get the dialog modal target element given a Node
node, perform
+ the following steps. They return an HTML element or null.
If node is not a button, then return + null.
If node is disabled, then return + null.
If node has a form owner and node is a submit button, then return null.
Let dialogElement be node's dialogmodaltarget
-associated element.
If dialogElement is null, then return null.
If dialogElement is not a dialog
element, then return null.
Return dialogElement.
script
element