mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-06 08:36:15 +00:00
LibWeb: Stop computing content in NodeWithStyle::apply_style()
This seems to have been required when pseudo-elements were first implemented, but has since become unused. It's also awkward because we don't have access to the DOM Element and its CountersSet at this point. So, let's remove it. For reference, Chrome&Firefox both return the computed value for `content: counter(foo)` as `counter(foo)`, not as the computed string. So not computing it here seems like the intended behaviour.
This commit is contained in:
@@ -751,8 +751,6 @@ void NodeWithStyle::apply_style(const CSS::StyleProperties& computed_style)
|
||||
if (auto outline_width = computed_style.property(CSS::PropertyID::OutlineWidth); outline_width->is_length())
|
||||
computed_values.set_outline_width(outline_width->as_length().length());
|
||||
|
||||
// FIXME: Stop generating the content twice. (First time is in TreeBuilder.)
|
||||
computed_values.set_content(computed_style.content(initial_quote_nesting_level()).content_data);
|
||||
computed_values.set_grid_auto_columns(computed_style.grid_auto_columns());
|
||||
computed_values.set_grid_auto_rows(computed_style.grid_auto_rows());
|
||||
computed_values.set_grid_template_columns(computed_style.grid_template_columns());
|
||||
|
||||
Reference in New Issue
Block a user