mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 03:27:44 +00:00
LibWeb: Use available space to resolve table container width
Using avilable space directly while resolving table container width allows to avoid assigning it to table wrapper box content width which sometimes involves infinite (saturated) values. Also this allows to get rid of set_max_content_width() which is a hack that allows to bypass set_content_width() to assign infinite (saturated) width to a box. Closes https://github.com/SerenityOS/serenity/issues/19521
This commit is contained in:
parent
fb60db7b00
commit
9101c8d079
7 changed files with 42 additions and 35 deletions
|
@ -567,7 +567,7 @@ void TableFormattingContext::compute_table_width()
|
|||
|
||||
auto& computed_values = table_box().computed_values();
|
||||
|
||||
CSSPixels width_of_table_containing_block = m_state.get(*table_box().containing_block()).content_width();
|
||||
CSSPixels width_of_table_containing_block = m_available_space->width.to_px();
|
||||
|
||||
// Percentages on 'width' and 'height' on the table are relative to the table wrapper box's containing block,
|
||||
// not the table wrapper box itself.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue