mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 06:07:44 +00:00
LibWeb: Support more kinds of indefinite widths on flex column items
This stuff is pretty hairy since the specifications don't give any guidance on which widths to use when calculating the intrinsic height of flex items in a column layout. However, our old behavior of "treat anything indefinite as fit-content" was definitely not good enough, so this patch improves the situation by considering values like `min-content`, `max-content` and `fit-content` separately from `auto`, and making the whole flex layout pipeline aware of them (in the cross axis context).
This commit is contained in:
parent
17b363b596
commit
41e7c5766e
4 changed files with 144 additions and 24 deletions
|
@ -211,7 +211,7 @@ private:
|
|||
[[nodiscard]] CSSPixels calculate_fit_content_main_size(FlexItem const&) const;
|
||||
[[nodiscard]] CSSPixels calculate_fit_content_cross_size(FlexItem const&) const;
|
||||
|
||||
CSSPixels calculate_clamped_fit_content_width(Box const&, AvailableSpace const&) const;
|
||||
[[nodiscard]] CSSPixels calculate_width_to_use_when_determining_intrinsic_height_of_item(FlexItem const&) const;
|
||||
|
||||
virtual void parent_context_did_dimension_child_root_box() override;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue