selector can start with >
This commit is contained in:
parent
d48560781c
commit
b71b11dccb
@ -283,7 +283,7 @@ impl<'a> StyleSheetParser<'a> {
|
|||||||
while let Some(Token { kind, .. }) = self.lexer.peek() {
|
while let Some(Token { kind, .. }) = self.lexer.peek() {
|
||||||
match kind {
|
match kind {
|
||||||
'a'..='z' | 'A'..='Z' | '_' | '-'
|
'a'..='z' | 'A'..='Z' | '_' | '-'
|
||||||
| '[' | '#' | ':' | '*' | '%' | '.' => rules
|
| '[' | '#' | ':' | '*' | '%' | '.' | '>' => rules
|
||||||
.extend(self.eat_rules(&Selector::new(), &mut GLOBAL_SCOPE.with(|s| s.borrow().clone()))?),
|
.extend(self.eat_rules(&Selector::new(), &mut GLOBAL_SCOPE.with(|s| s.borrow().clone()))?),
|
||||||
&'\t' | &'\n' | ' ' => {
|
&'\t' | &'\n' | ' ' => {
|
||||||
self.lexer.next();
|
self.lexer.next();
|
||||||
|
@ -316,3 +316,5 @@ test!(
|
|||||||
"ul li#foo {\n foo: bar;\n}\n"
|
"ul li#foo {\n foo: bar;\n}\n"
|
||||||
);
|
);
|
||||||
test!(escaped_space, "a\\ b {\n color: foo;\n}\n");
|
test!(escaped_space, "a\\ b {\n color: foo;\n}\n");
|
||||||
|
// blocked on whitespace
|
||||||
|
// test!(multiple_consecutive_immediate_child,"> > foo {\n color: foo;\n}\n",);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user