LibWeb: Distribute colspan cell width equally when baseline is zero

This matches the behavior of other engines.
This commit is contained in:
Tim Ledbetter
2026-02-02 14:18:56 +00:00
committed by Sam Atkins
parent 1e8ae879c5
commit 0b346d1952
Notes: github-actions[bot] 2026-02-06 11:38:16 +00:00
6 changed files with 100 additions and 10 deletions

View File

@@ -0,0 +1,31 @@
<!DOCTYPE html>
<link rel="author" title="Morten Stenshorne" href="mailto:mstensho@chromium.org">
<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=1430449">
<p>There should be five squares.</p>
<table cellspacing="0" cellpadding="0">
<tr>
<td colspan="3" style="background:blue;" data-expected-width="75" data-expected-height="75">
<div style="width:50px; height:75px;"></div>
</td>
<td colspan="3" style="background:green;" data-expected-width="75" data-expected-height="75">
<div style="width:50px; height:75px;"></div>
</td>
</tr>
<tr>
<td style="background:black;" data-expected-width="50" data-expected-height="50">
<div style="width:50px; height:50px;"></div>
</td>
<td colspan="4" style="background:lime;" data-expected-width="50" data-expected-height="50">
<div style="width:50px; height:50px;"></div>
</td>
<td style="background:hotpink;" data-expected-width="50" data-expected-height="50">
<div style="width:50px; height:50px;"></div>
</td>
</tr>
</table>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<script src="../../resources/check-layout-th.js"></script>
<script>
checkLayout('td')
</script>