summaryrefslogtreecommitdiff
path: root/Userland/Libraries
diff options
context:
space:
mode:
authorTobias Christiansen <tobyase@serenityos.org>2021-09-15 19:00:15 +0200
committerAndreas Kling <kling@serenityos.org>2021-09-15 22:28:28 +0200
commit67bf553fadacaf612ff94c65e240cef2cfd9c386 (patch)
tree9a765d3438594602ae138b82114e58e332e8f893 /Userland/Libraries
parent307f90b675379870af6ca51b1afcce747237e46c (diff)
downloadserenity-67bf553fadacaf612ff94c65e240cef2cfd9c386.zip
LibWeb: Flexbox: Make step 11 of the layout algorithm more align aware
Diffstat (limited to 'Userland/Libraries')
-rw-r--r--Userland/Libraries/LibWeb/Layout/FlexFormattingContext.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Libraries/LibWeb/Layout/FlexFormattingContext.cpp b/Userland/Libraries/LibWeb/Layout/FlexFormattingContext.cpp
index dd4dee20ba..4a6d605a8b 100644
--- a/Userland/Libraries/LibWeb/Layout/FlexFormattingContext.cpp
+++ b/Userland/Libraries/LibWeb/Layout/FlexFormattingContext.cpp
@@ -610,10 +610,10 @@ void FlexFormattingContext::run(Box& box, LayoutMode)
// FIXME: This
// 11. Determine the used cross size of each flex item.
- // FIXME: align-stretch
+ // FIXME: Get the alignment via "align-self" of the item (which accesses "align-items" of the parent if unset)
for (auto& flex_line : flex_lines) {
for (auto& flex_item : flex_line.items) {
- if (is_cross_auto(flex_item->box)) {
+ if (is_cross_auto(flex_item->box) && box.computed_values().align_items() == CSS::AlignItems::Stretch) {
// FIXME: Take margins into account
flex_item->cross_size = flex_line.cross_size;
} else {