mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-24 09:52:31 +00:00
LibWeb: Don't crash with non-<col> table-column
This commit is contained in:
parent
5b522c096e
commit
863092afdc
Notes:
github-actions[bot]
2025-07-01 09:19:36 +00:00
Author: https://github.com/Gingeh
Commit: 863092afdc
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5262
4 changed files with 50 additions and 6 deletions
|
@ -65,8 +65,9 @@ TableGrid TableGrid::calculate_row_column_grid(Box const& box, Vector<Cell>& cel
|
|||
|
||||
auto process_col_group = [&](auto& col_group) {
|
||||
auto dom_node = col_group.dom_node();
|
||||
dom_node->template for_each_in_subtree_of_type<HTML::HTMLTableColElement>([&](auto&) {
|
||||
x_width += 1;
|
||||
dom_node->for_each_in_subtree([&](auto& descendant) {
|
||||
if (descendant.layout_node() && descendant.layout_node()->display().is_table_column())
|
||||
x_width += 1;
|
||||
return TraversalDecision::Continue;
|
||||
});
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue