-
Notifications
You must be signed in to change notification settings - Fork 244
Closed
Description
Hey!
We are using the nesting feature, and if you nest an @media inside of a rule, it properly gets hoisted to the top and the rule with the selector is put inside the @media AtRule. However, if you try to do this with let's say @container then the selector is gone.
This also happens with any other AtRule it doesn't recognize.
Input:
/* Normal syntax, works */
@container (min-width: 200px) {
.bar {
text-decoration-line: underline
}
}
/* Nested syntax with @container, selector is gone */
.foo {
@container (min-width: 200px) {
text-decoration-line: underline
}
@any-at-rule {
color: red;
}
}
/* Nested syntax with @media, selector is still there */
.baz {
@media (min-width: 200px) {
text-decoration-line: underline
}
}Current behaviour:
@container (min-width: 200px) {
.bar {
text-decoration-line: underline;
}
}
@container (min-width: 200px) {
text-decoration-line: underline
}
@any-at-rule {
color: red;
}
@media (min-width: 200px) {
.baz {
text-decoration-line: underline;
}
}Expected behavour:
@container (min-width: 200px) {
.bar {
text-decoration-line: underline;
}
}
@container (min-width: 200px) {
.foo {
text-decoration-line: underline
}
}
@any-at-rule {
.foo {
color: red;
}
}
@media (min-width: 200px) {
.baz {
text-decoration-line: underline;
}
}Is this a bug, or is this the expected behaviour?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels