Skip to content

Commit

Permalink
Fixes #1242 - add support for the "@layer" keyword (#1243)
Browse files Browse the repository at this point in the history
  • Loading branch information
earlAchromatic authored and jakubpawlowicz committed Jan 19, 2023
1 parent 690fd43 commit 576a0f0
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/tokenizer/tokenize.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ var BLOCK_RULES = [
'@keyframes',
'@media',
'@supports',
'@container'
'@container',
'@layer'
];

var IGNORE_END_COMMENT_PATTERN = /\/\* clean-css ignore:end \*\/$/;
Expand Down
3 changes: 3 additions & 0 deletions test/fixtures/issue-1242-min.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@layer custom{
.test{font-size:15px;font-weight:700;line-height:10px}
}
7 changes: 7 additions & 0 deletions test/fixtures/issue-1242.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
@layer custom {
.test {
font-size: 15px;
font-weight: bold;
line-height: 10px;
}
}

0 comments on commit 576a0f0

Please sign in to comment.