Skip to content

Commit

Permalink
Upstream IDL changes from Trusted Types
Browse files Browse the repository at this point in the history
innerHTML, outerHTML, insertAdjacentHTML, and createContextualFragment all now take HTMLString values
  • Loading branch information
lukewarlow committed Mar 14, 2024
1 parent 18eec2d commit 988ac08
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ <h2>Extensibility</h2>

<pre class="idl">
interface mixin InnerHTML {
[CEReactions] attribute [LegacyNullToEmptyString] DOMString innerHTML;
[CEReactions] attribute [LegacyNullToEmptyString] HTMLString innerHTML;
};

Element includes InnerHTML;
Expand Down Expand Up @@ -305,8 +305,8 @@ <h2>Extensibility</h2>

<pre class="idl">
partial interface Element {
[CEReactions] attribute [LegacyNullToEmptyString] DOMString outerHTML;
[CEReactions] undefined insertAdjacentHTML(DOMString position, DOMString text);
[CEReactions] attribute [LegacyNullToEmptyString] HTMLString outerHTML;
[CEReactions] undefined insertAdjacentHTML(DOMString position, HTMLString text);
};
</pre>

Expand Down Expand Up @@ -482,7 +482,7 @@ <h2>Extensibility</h2>

<pre class="idl">
partial interface Range {
[CEReactions, NewObject] DocumentFragment createContextualFragment(DOMString fragment);
[CEReactions, NewObject] DocumentFragment createContextualFragment(HTMLString fragment);
};
</pre>

Expand Down Expand Up @@ -1765,6 +1765,12 @@ <h2>Dependencies</h2>
<ul>
<li>The <dfn data-lt="LegacyNullToEmptyString"><a href="https://heycam.github.io/webidl/#LegacyNullToEmptyString">[LegacyNullToEmptyString]</a></dfn> IDL <a>extended attribute</a>
</ul>

The Trusted Types [[TRUSTED-TYPES]] specification defines:

<ul>
<li>The <dfn data-lt="HTMLString"><a href="https://w3c.github.io/trusted-types/dist/spec/#typedefdef-htmlstring">HTMLString</a></dfn> IDL <a>typedef</a>
</ul>
</section>

<section class=appendix>
Expand Down

0 comments on commit 988ac08

Please sign in to comment.