Files
ladybird/Tests/LibWeb/Ref/input/table-margin-auto-inside-flex-item.html
Tim Ledbetter 8240fa0dc8 LibWeb: Resolve percentage table widths in wrapper width computation
Previously, a table with `width: 100%` and `margin: auto` whose content
was narrower than the viewport would be centered based on content
width rather than filling the containing block. Resizing the viewport
wider than the content would shift the table progressively further to
the right.

Co-authored-by: Aliaksandr Kalenik <kalenik.aliaksandr@gmail.com>
2026-02-21 05:16:56 +01:00

14 lines
441 B
HTML

<!DOCTYPE html>
<link rel="match" href="../expected/table-margin-auto-inside-flex-item-ref.html" />
<style>
* { margin: 0; padding: 0; }
.flex { display: flex; flex-direction: column; }
.centering { min-width: 400px; margin: 0 auto; }
.table { display: table; width: 100%; margin: 0 auto; background: green; }
</style>
<div class="flex">
<div class="centering">
<div class="table">content</div>
</div>
</div>