mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 17:37:37 +00:00
LibHTML: Unbreak parsing of standalone declarations
Oops, I forgot to update CSSParser::parse_standalone_declaration() after making parse_property() return a property (or {} for failure.)
This commit is contained in:
parent
b9557bf876
commit
ef0613ea4c
1 changed files with 6 additions and 2 deletions
|
@ -215,7 +215,9 @@ public:
|
||||||
consume_whitespace();
|
consume_whitespace();
|
||||||
is_important = true;
|
is_important = true;
|
||||||
}
|
}
|
||||||
consume_specific(';');
|
if (peek() != '}')
|
||||||
|
consume_specific(';');
|
||||||
|
|
||||||
return StyleProperty { property_name, parse_css_value(property_value), is_important };
|
return StyleProperty { property_name, parse_css_value(property_value), is_important };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -254,7 +256,9 @@ public:
|
||||||
{
|
{
|
||||||
consume_whitespace();
|
consume_whitespace();
|
||||||
for (;;) {
|
for (;;) {
|
||||||
parse_property();
|
auto property = parse_property();
|
||||||
|
if (property.has_value())
|
||||||
|
current_rule.properties.append(property.value());
|
||||||
consume_whitespace();
|
consume_whitespace();
|
||||||
if (!peek())
|
if (!peek())
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue