1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 23:17:45 +00:00

LibWeb: Convert flex-basis to LengthPercentage

The flexbox logic confuses me so regressions are possible, though our
test page looks the same as before so it should be fine.

Renamed FlexBasis::Length -> LengthPercentage too, for clarity.
This commit is contained in:
Sam Atkins 2022-01-19 11:52:01 +00:00 committed by Andreas Kling
parent 784ba2ec42
commit cb0cce5cdc
5 changed files with 29 additions and 15 deletions

View file

@ -69,9 +69,9 @@ struct Transformation {
struct FlexBasisData {
CSS::FlexBasis type { CSS::FlexBasis::Auto };
CSS::Length length {};
Optional<CSS::LengthPercentage> length_percentage;
bool is_definite() const { return type == CSS::FlexBasis::Length; }
bool is_definite() const { return type == CSS::FlexBasis::LengthPercentage; }
};
struct BoxShadowData {