1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-15 04:34:59 +00:00

LibWeb: Propagate errors from parse_css_value and property_initial_value

This commit is contained in:
Sam Atkins 2023-05-02 15:09:46 +01:00 committed by Andreas Kling
parent 294f5b109f
commit f4d8a24fe4
12 changed files with 68 additions and 66 deletions

View file

@ -41,7 +41,7 @@ void HTMLTableCellElement::apply_presentational_hints(CSS::StyleProperties& styl
if (value.equals_ignoring_ascii_case("center"sv) || value.equals_ignoring_ascii_case("middle"sv)) {
style.set_property(CSS::PropertyID::TextAlign, CSS::IdentifierStyleValue::create(CSS::ValueID::LibwebCenter).release_value_but_fixme_should_propagate_errors());
} else {
if (auto parsed_value = parse_css_value(CSS::Parser::ParsingContext { document() }, value.view(), CSS::PropertyID::TextAlign))
if (auto parsed_value = parse_css_value(CSS::Parser::ParsingContext { document() }, value.view(), CSS::PropertyID::TextAlign).release_value_but_fixme_should_propagate_errors())
style.set_property(CSS::PropertyID::TextAlign, parsed_value.release_nonnull());
}
return;