Re: [csswg-drafts] [selectors-4] reconsider specificity rule for :matches()

@Loirooriol, I don’t see this ambiguity in the spec. Since the spec for `:matches()` specificity says

> The full selector’s specificity is equivalent to expanding out all the combinations in full

this example will be expanded as

`#a + .foo span, #a + * span, * + .foo span, * + * span { ... }`

and by the [rules](https://drafts.csswg.org/selectors-4/#specificity-rules) of the selectors list specificity, its specificity will be the largest one of the individual selectors in the list that match the element, in this example it would be (1, 0, 1) of `#a + * span`. There is only one way to expand `:matches()` into a selector list, and any selector list has only one maximum specificity value of its parts (even if several parts have the same specificity), so there is no place for the ambiguity to occur.

Do I miss something?

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

Received on Sunday, 31 December 2017 16:46:10 UTC