W3C home > Mailing lists > Public > public-css-archive@w3.org > October 2019

Re: [csswg-drafts] [css-shadow-parts] What's the purpose of multiple idents in ::part()? (#4412)

From: Peter Linss via GitHub <sysbot+gh@w3.org>
Date: Fri, 11 Oct 2019 22:27:38 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-541244536-1570832857-sysbot+gh@w3.org>
Ok, valid point about :state() and internal vs external. But to me that just means that in your calendar widget example, the weekend/holiday status should be a class, rather than a pseudo class (or a part). 

I get your argument about it just being over here rather than there, but there's a distinction between classnames and tagnames, just like there's a distinction between pseudo elements and pseudo classes. And I think we're doing authors a disservice by conflating them.

The `:not()` point wasn't meant as a 'gotcha', classes and pseudo classes have a different specificity and different behaviors than tagnames and pseudo elements. You didn't address the differences in specificity between the examples.

At the end of the day, yes, we *can* mix in the notions of class into parts, but the question here is: *should* we? I really want `::part` to just be a custom pseudo element, that acts like a built in pseudo element, and explains the built in pseudo elements, not something new with its own magic and its own rules. Especially when the 'new magic' is something authors already have via other existing mechanisms.

-- 
GitHub Notification of comment by plinss
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4412#issuecomment-541244536 using your GitHub account
Received on Friday, 11 October 2019 22:27:39 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:54 UTC