@@ -45686,7 +45686,8 @@ interface <dfn interface>HTMLInputElement</dfn> : <span>HTMLElement</span> {
45686
45686
45687
45687
// <a href="#HTMLInputElement-partial">also has obsolete members</a>
45688
45688
};
45689
- <span>HTMLInputElement</span> includes <span>PopoverInvokerElement</span>;</code></pre>
45689
+ <span>HTMLInputElement</span> includes <span>PopoverInvokerElement</span>;
45690
+ <span>HTMLInputElement</span> includes <span>DialogInvokerElement</span>;</code></pre>
45690
45691
</dd>
45691
45692
<dd w-dev>Uses <code>HTMLInputElement</code>.</dd>
45692
45693
</dl>
@@ -52101,7 +52102,8 @@ interface <dfn interface>HTMLButtonElement</dfn> : <span>HTMLElement</span> {
52101
52102
52102
52103
readonly attribute <span>NodeList</span> <span data-x="dom-lfe-labels">labels</span>;
52103
52104
};
52104
- <span>HTMLButtonElement</span> includes <span>PopoverInvokerElement</span>;</code></pre>
52105
+ <span>HTMLButtonElement</span> includes <span>PopoverInvokerElement</span>;
52106
+ <span>HTMLButtonElement</span> includes <span>DialogInvokerElement</span>;</code></pre>
52105
52107
</dd>
52106
52108
<dd w-dev>Uses <code>HTMLButtonElement</code>.</dd>
52107
52109
</dl>
@@ -60365,6 +60367,85 @@ interface <dfn interface>HTMLDialogElement</dfn> : <span>HTMLElement</span> {
60365
60367
60366
60368
</div>
60367
60369
60370
+ <h4 id="the-dialogmodal-target-attributes">The dialogmodal target attributes</h4>
60371
+
60372
+ <p><span data-x="concept-button">Buttons</span> may have the following content attributes:</p>
60373
+
60374
+ <ul>
60375
+ <li><p><dfn element-attr for="html-global"><code
60376
+ data-x="attr-dialogmodaltarget">dialogmoddaltarget</code></dfn></p></li>
60377
+ </ul>
60378
+
60379
+ <p>If specified, the <code data-x="attr-dialogmodaltarget">dialogmodaltarget</code> attribute value must
60380
+ be the <span data-x="concept-ID">ID</span> of a <span data-x="dialog">dialog</span> element
60381
+ in the same <span>tree</span> as the <span data-x="concept-button">button</span> with the
60382
+ <code data-x="attr-dialogmodaltarget">dialogmodaltarget</code> attribute.</p>
60383
+
60384
+ <div class="example">
60385
+ <p>The following shows how the <code data-x="attr-dialogmodaltarget">dialogmodaltarget</code> attribute
60386
+ can be used to show and close a dialog:</p>
60387
+
60388
+ <pre><code class="html"><button dialogmodaltarget="foo">
60389
+ Show a dialog (modal)
60390
+ </button>
60391
+
60392
+ <dialog id="foo">
60393
+ This is a dialog!
60394
+ <button dialogmodaltarget="foo">Close</button>
60395
+ </article></code></pre>
60396
+ </div>
60397
+
60398
+ <span data-x="concept-element-dom">DOM interface</span>:
60399
+ <pre><code class="idl">interface mixin <dfn interface>DialogInvokerElement</dfn> {
60400
+ [<span>CEReactions</span>] attribute Element? <span data-x="dom-dialogModalTargetElement">dialogModalTargetElement</span>;
60401
+ };</code></pre>
60402
+
60403
+ <p>The <dfn attribute for="HTMLElement"><code
60404
+ data-x="dom-dialogModalTargetElement">dialogModalTargetElement</code></dfn> IDL attribute must
60405
+ <span>reflect</span> the <code data-x="attr-dialogmodaltarget">dialogmodaltarget</code> attribute.</p>
60406
+
60407
+ <p>To run the <dfn>dialog modal target attribute activation behavior</dfn> given a <code>Node</code>
60408
+ <var>node</var>:</p>
60409
+
60410
+ <ol>
60411
+ <li><p>Let <var>dialog</var> be <var>node</var>'s <span>dialog modal target element</span>.</p></li>
60412
+
60413
+ <li><p>If <var>dialog</var> is null, then return.</p></li>
60414
+
60415
+ <li><p>If the <code data-x="attr-dialog-open">open</code> attribute is set on <var>node</var>
60416
+ then:
60417
+
60418
+ <ol>
60419
+ <li><p>Run <code data-x="dom-dialog-close">close()</code></p> on <var>node</var></li>
60420
+ <li><p>Otherwise, run <code data-x="dom-dialog-showmodal">showModal()</code> on <var>node</var></li>
60421
+ </ol>
60422
+
60423
+ </li>
60424
+ </ol>
60425
+
60426
+ <p>To get the <dfn>dialog modal target element</dfn> given a <code>Node</code> <var>node</var>, perform
60427
+ the following steps. They return an <span data-x="HTML elements">HTML element</span> or null.</p>
60428
+
60429
+ <ol>
60430
+ <li><p>If <var>node</var> is not a <span data-x="concept-button">button</span>, then return
60431
+ null.</p></li>
60432
+
60433
+ <li><p>If <var>node</var> is <span data-x="concept-fe-disabled">disabled</span>, then return
60434
+ null.</p></li>
60435
+
60436
+ <li><p>If <var>node</var> has a <span>form owner</span> and <var>node</var> is a <span
60437
+ data-x="concept-submit-button">submit button</span>, then return null.</p></li>
60438
+
60439
+ <li><p>Let <var>dialogElement</var> be <var>node</var>'s <span data-x="attr-associated
60440
+ element"><code data-x="">dialogmodaltarget</code>-associated element</span>.</p></li>
60441
+
60442
+ <li><p>If <var>dialogElement</var> is null, then return null.</p></li>
60443
+
60444
+ <li><p>If <var>dialogElement</var> is not a <code data-x="dialog">dialog</code> element, then return null.</p></li>
60445
+
60446
+ <li><p>Return <var>dialogElement</var>.</p></li>
60447
+ </ol>
60448
+
60368
60449
60369
60450
<h4 id="the-script-element">The <dfn
60370
60451
id="script" element><code>script</code></dfn> element</h4>
0 commit comments