1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-11 10:18:15 +09:00

LibWeb: Generate a BlockContainer box for display:inline-flex

We were previously generating an InlineNode, which is not a Box. We need
some type of Box to do flex layout, so let's just make a BlockContainer.
This commit is contained in:
Andreas Kling 2022-10-06 20:34:55 +02:00
parent 97bbb630c8
commit c7d592dd01
Notes: sideshowbarker 2024-07-17 09:47:09 +09:00

View file

@ -308,7 +308,8 @@ RefPtr<Layout::Node> Element::create_layout_node_for_display_type(DOM::Document&
return adopt_ref(*new Layout::BlockContainer(document, element, move(style)));
if (display.is_flow_inside())
return adopt_ref(*new Layout::InlineNode(document, element, move(style)));
if (display.is_flex_inside())
return adopt_ref(*new Layout::BlockContainer(document, element, move(style)));
dbgln_if(LIBWEB_CSS_DEBUG, "FIXME: Support display: {}", display.to_string());
return adopt_ref(*new Layout::InlineNode(document, element, move(style)));
}