-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prevent
not-*
from being used with variants with multiple sibling r…
…ules (#15689) Variants like this can't be easily negated by our current system: ```css @custom-variant dark { &.is-dark { @slot; } @media (prefers-color-scheme: dark) { @slot; } } ``` Right now it produces the following CSS which is logically incorrect: ```css .utility-name { &:not(.is-dark) { /* ... */ } @media not (prefers-color-scheme: dark) { /* ... */ } } ``` The correct CSS is this which requires moving things around: ```css .utility-name { @media not (prefers-color-scheme: dark) { &:not(.is-dark) { /* ... */ } } } ``` We're opting to disable this instead of generating incorrect CSS for now. I'd like to bring this back in the future for simpler cases in the future.
- Loading branch information
1 parent
4035ab0
commit 79f21a8
Showing
3 changed files
with
49 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters