Re: [csswg-drafts] [selectors] Functional pseudo-class like :matches() with 0 specificity

>From what I understand of the current state of css usage, with websites moving towards component-splitting of their files instead of type-splitting for their files, stylesheets files used in development have grown smaller and smaller, and targetted to specific portions of the application; using source order makes more sense than using the specificity cascade at that scale.

You still want specificity rules for more generic theming purposes, and to allow the style of one component to override its sub component' styles if needed, but "local state" of a component is something people don't want to have an impact on specificity, hence this proposal generating zero specificity.

It doesn't require major changes to how browsers do cascade unlike your proposal, and solves the currently most dire issue. I haven't heard anyone desiring your proposed behavior before. I don't want to say it doesn't have value, but it doesn't seem like an appropriate design to solve the most frequently-heard problem.

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

Received on Monday, 2 October 2017 18:53:35 UTC