mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 19:18:12 +00:00
LibWeb: Implement SVG fill-rule
attribute
Previously, we did an evenodd fill for everything which while for most SVGs works, it is not correct default (it should be nonzero), and broke some SVGs. This fixes a few of the icons on https://shopify.com/.
This commit is contained in:
parent
ead56e88db
commit
377ff0ac26
13 changed files with 74 additions and 3 deletions
|
@ -309,6 +309,12 @@ float StyleProperties::stop_opacity() const
|
|||
return resolve_opacity_value(*value);
|
||||
}
|
||||
|
||||
Optional<CSS::FillRule> StyleProperties::fill_rule() const
|
||||
{
|
||||
auto value = property(CSS::PropertyID::FillRule);
|
||||
return value_id_to_fill_rule(value->to_identifier());
|
||||
}
|
||||
|
||||
Optional<CSS::FlexDirection> StyleProperties::flex_direction() const
|
||||
{
|
||||
auto value = property(CSS::PropertyID::FlexDirection);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue