- From: Anne van Kesteren <notifications@github.com>
- Date: Mon, 18 Sep 2023 01:48:17 -0700
- To: whatwg/dom <dom@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/dom/pull/1223/review/1630553363@github.com>
@annevk commented on this pull request. I was hoping this definition could mostly stay in CSS and in DOM we could use the composed tree (which we use for events). Perhaps having both concepts in DOM is useful, but early on we were fairly deliberate on the split and I feel like we lost some of the knowledge as to why we did things that way. cc @rniwa @hayatoito @domenic @smaug---- > @@ -5956,6 +5956,23 @@ is an object or one of its <a>shadow-including ancestors</a>. <p class=note>The <a>retargeting</a> algorithm is used by <a lt=dispatch>event dispatch</a> as well as other specifications, such as <cite>Fullscreen</cite>. [[FULLSCREEN]] +<p>To get the <dfn export>flat tree parent</dfn> of a <var>node</var>:</p> + +<ol> + <li><p>Let <var>parent</var> be <var>node</var>'s <a for=tree>parent</a>.</p></li> + + <li><p>If <var>parent</var> is a <a for=/>shadow root</a>, then return <var>parent</var>'s <a + for=DocumentFragment>host</a>.</p></li> + + <li><p>If <var>parent</var> is not a <a for=Element>shadow host</a>, then return + <var>node</var>.</p></li> You want to return parent here, presumably. > @@ -5956,6 +5956,23 @@ is an object or one of its <a>shadow-including ancestors</a>. <p class=note>The <a>retargeting</a> algorithm is used by <a lt=dispatch>event dispatch</a> as well as other specifications, such as <cite>Fullscreen</cite>. [[FULLSCREEN]] +<p>To get the <dfn export>flat tree parent</dfn> of a <var>node</var>:</p> + +<ol> + <li><p>Let <var>parent</var> be <var>node</var>'s <a for=tree>parent</a>.</p></li> + + <li><p>If <var>parent</var> is a <a for=/>shadow root</a>, then return <var>parent</var>'s <a No wrapping in phrasing elements. > @@ -5956,6 +5956,23 @@ is an object or one of its <a>shadow-including ancestors</a>. <p class=note>The <a>retargeting</a> algorithm is used by <a lt=dispatch>event dispatch</a> as well as other specifications, such as <cite>Fullscreen</cite>. [[FULLSCREEN]] +<p>To get the <dfn export>flat tree parent</dfn> of a <var>node</var>:</p> What about children of a slot element? -- Reply to this email directly or view it on GitHub: https://github.com/whatwg/dom/pull/1223#pullrequestreview-1630553363 You are receiving this because you are subscribed to this thread. Message ID: <whatwg/dom/pull/1223/review/1630553363@github.com>
Received on Monday, 18 September 2023 08:48:23 UTC