1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 11:38:11 +00:00

LibWeb: Replace PlaceSelfStyleValue with ShorthandStyleValue

Turns out we were parsing `place-self` as a PlaceItemsStyleValue
sometimes, whoops.
This commit is contained in:
Sam Atkins 2023-09-20 15:20:05 +01:00 committed by Sam Atkins
parent 1b0939b418
commit 8143d48161
10 changed files with 13 additions and 78 deletions

View file

@ -47,7 +47,6 @@
#include <LibWeb/CSS/StyleValues/OverflowStyleValue.h>
#include <LibWeb/CSS/StyleValues/PercentageStyleValue.h>
#include <LibWeb/CSS/StyleValues/PlaceItemsStyleValue.h>
#include <LibWeb/CSS/StyleValues/PlaceSelfStyleValue.h>
#include <LibWeb/CSS/StyleValues/PositionStyleValue.h>
#include <LibWeb/CSS/StyleValues/RectStyleValue.h>
#include <LibWeb/CSS/StyleValues/ShorthandStyleValue.h>
@ -513,13 +512,6 @@ static void set_property_expanding_shorthands(StyleProperties& style, CSS::Prope
}
if (property_id == CSS::PropertyID::PlaceSelf) {
if (value.is_place_self()) {
auto const& place_self = value.as_place_self();
set_longhand_property(CSS::PropertyID::AlignSelf, place_self.align_self());
set_longhand_property(CSS::PropertyID::JustifySelf, place_self.justify_self());
return;
}
set_longhand_property(CSS::PropertyID::AlignSelf, value);
set_longhand_property(CSS::PropertyID::JustifySelf, value);
return;