Skip to content

Commit

Permalink
Correct lookupPrefix() after fourteen years
Browse files Browse the repository at this point in the history
Since it was introduced in 43213ed we never invoked locating a namespace prefix correctly.

Fixes #1302.
  • Loading branch information
annevk committed Aug 14, 2024
1 parent 6db6c7d commit ad422be
Showing 1 changed file with 26 additions and 9 deletions.
35 changes: 26 additions & 9 deletions dom.bs
Original file line number Diff line number Diff line change
Expand Up @@ -4902,23 +4902,39 @@ the interface <var>node</var> <a>implements</a>:

<dl class=switch>
<dt>{{Element}}
<dd><p>Return the result of <a>locating a namespace prefix</a> for it using <var>namespace</var>.
<dd><p>Return the result of <a>locating a namespace prefix</a> for <a>this</a> using
<var>namespace</var>.

<dt>{{Document}}
<dd><p>Return the result of <a>locating a namespace prefix</a> for its <a>document element</a>,
if its <a>document element</a> is non-null; otherwise null.
<dd>
<ol>
<li><p>If <a>this</a>'s <a>document element</a> is null, then return null.

<li><p>Return the result of <a>locating a namespace prefix</a> for <a>this</a>'s
<a>document element</a> using <var>namespace</var>.
</ol>

<dt>{{DocumentType}}
<dt>{{DocumentFragment}}
<dd><p>Return null.

<dt>{{Attr}}
<dd><p>Return the result of <a>locating a namespace prefix</a> for its <a for=Attr>element</a>,
if its <a for=Attr>element</a> is non-null; otherwise null.
<dd>
<ol>
<li><p>If <a>this</a>'s <a for=Attr>element</a> is null, then return null.

<li><p>Return the result of <a>locating a namespace prefix</a> for <a>this</a>'s
<a for=Attr>element</a> using <var>namespace</var>.
</ol>

<dt>Otherwise
<dd><p>Return the result of <a>locating a namespace prefix</a> for its <a>parent element</a>, if
its <a>parent element</a> is non-null; otherwise null.
<dd>
<ol>
<li><p>If <a>this</a>'s <a>parent element</a> is null, then return null.

<li><p>Return the result of <a>locating a namespace prefix</a> for <a>this</a>'s
<a>parent element</a> using <var>namespace</var>.
</ol>
</dl>
</ol>

Expand Down Expand Up @@ -10358,6 +10374,7 @@ Cyrille Tuzi,
Dan Burzo,
Daniel Clark,
Daniel Glazman,
Darien Maillet Valentine<!-- bhathos; GitHub -->,
Darin Fisher,
David Bruant,
David Flanagan,
Expand Down Expand Up @@ -10436,7 +10453,7 @@ Manish Tripathi,
Marcos Caceres,
Mark Miller,
Martijn van der Ven,
Mason Freed,<!-- mfreed7; GitHub -->
Mason Freed<!-- mfreed7; GitHub -->,
Mats Palmgren,
Mounir Lamouri,
Michael Stramel,
Expand Down Expand Up @@ -10493,7 +10510,7 @@ Tobie Langel,
Tom Pixley,
Travis Leithead,
Trevor Rowbotham,
<i>triple-underscore</i><!--GitHub-->,
<i>triple-underscore</i><!-- GitHub -->,
Tristan Fraipont,
Veli Şenol,
Vidur Apparao,
Expand Down

0 comments on commit ad422be

Please sign in to comment.