Skip to content

[css-nesting-1] are declarations allowed in a nested @layer rule #8082

@romainmenke

Description

@romainmenke

@argyleink These examples all follow the same basic pattern:

- style rule
  - at-rule
    - style rule
      - declarations
.foo {
  @layer a-layer {
    .bar {
      color: red;
    }
  }
}

But can we also do this?

- style rule
  - at-rule
    - declarations
.foo {
  @layer a-layer {
    color: red;
  }
}

Also unclear if the wording from section 2.2 is still correct now that @layer and @scope are allowed. Should this be changed to be less specific than conditional rules. (afaik @layer isn't a conditional rule)
Or do need a new section for at-rules that aren't conditional rules?

Originally posted by @romainmenke in #7965 (comment)

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions