mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 22:37:35 +00:00
LibWeb: Proritize FlexFormattingContext when display: flex is specified
An item with display: flex and overflow: hidden would've caused a BlockFormattingContext before.
This commit is contained in:
parent
e0a727bc76
commit
54013ffbe0
1 changed files with 5 additions and 4 deletions
|
@ -75,13 +75,14 @@ void FormattingContext::layout_inside(Box& box, LayoutMode layout_mode)
|
|||
return;
|
||||
}
|
||||
|
||||
if (creates_block_formatting_context(box)) {
|
||||
BlockFormattingContext context(box, this);
|
||||
if (box.computed_values().display() == CSS::Display::Flex) {
|
||||
FlexFormattingContext context(box, this);
|
||||
context.run(box, layout_mode);
|
||||
return;
|
||||
}
|
||||
if (box.computed_values().display() == CSS::Display::Flex) {
|
||||
FlexFormattingContext context(box, this);
|
||||
|
||||
if (creates_block_formatting_context(box)) {
|
||||
BlockFormattingContext context(box, this);
|
||||
context.run(box, layout_mode);
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue