- From: Daniil Sakhapov via GitHub <sysbot+gh@w3.org>
- Date: Thu, 24 Apr 2025 11:08:34 +0000
- To: public-css-archive@w3.org
danielsakhapov has just created a new issue for https://github.com/w3c/csswg-drafts: == [css-pseudo-4] Should parent and element attributes of CSSPseudoElement interface be nullable? == https://drafts.csswg.org/css-pseudo-4/#CSSPseudoElement-interface has ``` readonly attribute Element element; readonly attribute (Element or CSSPseudoElement) parent; ``` but, given the outcome of https://github.com/w3c/csswg-drafts/issues/3607, and e.g. ``` fc = div.firstChild; div.removeChild(fc); fc.parentElement; <-- is null. ``` I would expect the following to return null: ``` .beforePseudo::before { content: "before"; } before = target.pseudo("::before"); div.classList.remove("beforePseudo"); before.parent; <-- should be null, since the pseudo is now ~"detached from DOM"? ``` So, I guess that `parent` and `element` attributes of CSSPseudoElement interface should be nullable? @emilio @fantasai ? Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12115 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 24 April 2025 11:08:34 UTC