summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/Layout/TreeBuilder.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Userland/Libraries/LibWeb/Layout/TreeBuilder.cpp')
-rw-r--r--Userland/Libraries/LibWeb/Layout/TreeBuilder.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/Userland/Libraries/LibWeb/Layout/TreeBuilder.cpp b/Userland/Libraries/LibWeb/Layout/TreeBuilder.cpp
index a6b0ef59f2..9dbf3bd2ac 100644
--- a/Userland/Libraries/LibWeb/Layout/TreeBuilder.cpp
+++ b/Userland/Libraries/LibWeb/Layout/TreeBuilder.cpp
@@ -33,6 +33,10 @@ static Layout::Node& insertion_parent_for_inline_node(Layout::NodeWithStyle& lay
if (layout_parent.is_inline() && !layout_parent.is_inline_block())
return layout_parent;
+ if (layout_parent.computed_values().display() == CSS::Display::Flex) {
+ layout_parent.append_child(layout_parent.create_anonymous_wrapper());
+ }
+
if (!layout_parent.has_children() || layout_parent.children_are_inline())
return layout_parent;