Visitar URL original
Take in account selectors support in functional pseudo-classes · Issue #450 · css/csso · GitHub
Skip to content

Take in account selectors support in functional pseudo-classes #450

Open

Description

@lahmatiy

Currently CSSO doesn't traverse selectors in functional pseudo-classes when build pseudoSignature which leads to the incorrect merge of rules, e.g.

.cc-expiry-month:not(:-moz-placeholder-shown) {
      width: 42px;
}

.cc-expiry-month:not(:-ms-input-placeholder) {
      width: 42px;
}

.cc-expiry-month:not(:placeholder-shown) {
      width: 42px;
}

Will produce the incorrect result (pretty printed):

.cc-expiry-month:not(:-moz-placeholder-shown),
.cc-expiry-month:not(:-ms-input-placeholder),
.cc-expiry-month:not(:placeholder-shown){
    width:42px
}

The correct output should not merge rules.

(example taken from the comment in #416)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions