diff --git a/crates/hdx_ast/src/css/stylerule.rs b/crates/hdx_ast/src/css/stylerule.rs index c0880e9..4ad2aea 100644 --- a/crates/hdx_ast/src/css/stylerule.rs +++ b/crates/hdx_ast/src/css/stylerule.rs @@ -112,6 +112,7 @@ mod tests { assert_parse!(StyleRule, "body {\n\topacity: 0;\n}"); assert_parse!(StyleRule, ".foo *{}", ".foo * {\n}"); assert_parse!(StyleRule, ":nth-child(1) {\n\topacity: 0;\n}"); + assert_parse!(StyleRule, ".foo {\n\t--bar: (baz);\n}"); } #[test] diff --git a/crates/hdx_ast/src/syntax.rs b/crates/hdx_ast/src/syntax.rs index 8ebe574..7e0259d 100644 --- a/crates/hdx_ast/src/syntax.rs +++ b/crates/hdx_ast/src/syntax.rs @@ -193,6 +193,7 @@ impl<'a> Parse<'a> for SimpleBlock<'a> { } if let Some(token) = parser.peek::() { if token.to_pairwise() == pair.to_pairwise() { + parser.hop(token); break; } }