[webkit-changes] [WebKit/WebKit] 7b711f: Hovering on CBC homepage causes weird scaling to h...

Alan Baradlay noreply at github.com
Fri Aug 30 13:11:39 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 7b711fb51888e9785b998dd368d394b7180a41d0
      https://github.com/WebKit/WebKit/commit/7b711fb51888e9785b998dd368d394b7180a41d0
  Author: Alan Baradlay <zalan at apple.com>
  Date:   2024-08-30 (Fri, 30 Aug 2024)

  Changed paths:
    A LayoutTests/fast/table/expanding-table-with-grid-cell-expected.html
    A LayoutTests/fast/table/expanding-table-with-grid-cell.html
    M Source/WebCore/rendering/RenderTable.cpp

  Log Message:
  -----------
  Hovering on CBC homepage causes weird scaling to happen as you move
https://bugs.webkit.org/show_bug.cgi?id=278894
<rdar://problem/134986382>

Reviewed by Antti Koivisto.

Preferred width size should never be affected by override size (set by containing boxes e.g. flex, grid).

Override size (as its name implies) is meant to force child boxes use pre-computed widths in flexing context (again e.g. flex, grid)
However this override size, in many cases is result of a previously computed intrinsic sizes coming from child content.

Here the first set of preferred width computation finishes with the correct geometry as there's no override size yet (nothing to set), while
any subsequent layout would force this previously computed override size on preferred with computation (hence the growing content).

This change was introduced as part of r276572 with no explanation of why it was required ("Take the overriding width into account when computing the preferred min/max values for the element" <- not helpful).
r276572 fixed a few WPTS and those still pass after undoing the preferred with size override.

* LayoutTests/fast/table/expanding-table-with-grid-cell-expected.html: Added.
* LayoutTests/fast/table/expanding-table-with-grid-cell.html: Added.
* Source/WebCore/rendering/RenderTable.cpp:
(WebCore::RenderTable::computePreferredLogicalWidths):

Canonical link: https://commits.webkit.org/282988@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list