cssinjs/jss

Nested selectors are loosing dollar sign

Open

#1.116 aberto em 9 de jun. de 2019

Ver no GitHub
 (4 comments) (1 reaction) (0 assignees)JavaScript (434 forks)batch import
bughelp wanted

Métricas do repositório

Stars
 (7.000 stars)
Métricas de merge de PR
 (Nenhuma PRs mesclada em 30d)

Description

Expected behavior: Normal selector nesting

Describe the bug: When nesting a selector with a dollar sign, it disappears

Codesandbox link: https://codesandbox.io/s/react-jss-playground-j9toj

There I've just added:

    "& h1": {
      color: "red"
    }

And changed Comp to Comp$1

And look at the <style>:

.Comp\$1-wrapper-0-1-13 {
  padding: 40px;
  background: #f7df1e;
  text-align: left;
}
.Comp\1-wrapper-0-1-13 h1 {
  color: red;
}

Versions:

  • react-jss: 8.6.1
  • Browser: Safari 12.1.2
  • OS: macOS 10.14.6

Guia do colaborador