1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:48:11 +00:00

LibWeb: LayoutNodes know whether they are flex-items

This is useful for debugging when dumping the layout tree.
This commit is contained in:
Tobias Christiansen 2021-05-29 22:36:15 +02:00 committed by Ali Mohammad Pur
parent 2205239d9a
commit 7f81c8fba2
3 changed files with 10 additions and 1 deletions

View file

@ -165,7 +165,9 @@ void dump_tree(StringBuilder& builder, const Layout::Node& layout_node, bool sho
if (box.is_inline_block())
builder.appendff(" {}inline-block{}", inline_block_color_on, color_off);
if (box.computed_values().display() == CSS::Display::Flex)
builder.appendff(" {}flex{}", flex_color_on, color_off);
builder.appendff(" {}flex-container{}", flex_color_on, color_off);
if (box.is_flex_item())
builder.appendff(" {}flex-item{}", flex_color_on, color_off);
if (show_box_model) {
// Dump the horizontal box properties