Re: [csswg-drafts] [selectors-4] `:is()` and `:where()` not allowed inside `:not()`? (#9038)

It seems to be a known pitfall of `:is()`/`:where()`. Their argument has global scope rather than is scoped to the selector before it. I.e., `.a *:is(.b .c)` actually searches for the `.c` elements that have both `.a` and `.b` elements in their ancestors chain in any order, so not only .a > .b > .c, but also .b > .a > .c and .a.b > .c would match it. There is a scoped styles proposal in [css-cascade-6] to work around this problem.

-- 
GitHub Notification of comment by SelenIT
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/9038#issuecomment-1623735741 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Thursday, 6 July 2023 14:01:42 UTC