Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 84fc0edf9e8649a56cca35cc48c73f211e310d14
      
https://github.com/WebKit/WebKit/commit/84fc0edf9e8649a56cca35cc48c73f211e310d14
  Author: Wenson Hsieh <[email protected]>
  Date:   2025-09-05 (Fri, 05 Sep 2025)

  Changed paths:
    A 
LayoutTests/fast/page-color-sampling/color-sampling-horizontal-overflow-with-viewport-meta-expected.txt
    A 
LayoutTests/fast/page-color-sampling/color-sampling-horizontal-overflow-with-viewport-meta.html
    M Source/WebCore/page/LocalFrameView.cpp

  Log Message:
  -----------
  [Liquid Glass] [iOS] github.com: visible gap above sticky top header while 
scrolling on PRs with long branch names
https://bugs.webkit.org/show_bug.cgi?id=298485
rdar://159857229

Reviewed by Abrar Rahman Protyasha.

On iPhone, when rendering pages where:

1. The viewport meta width is set to `device-width`
2. The viewport meta initial scale is unset (auto)
3. The contents of the page lay out wider than the viewport width

...we sometimes end up failing to extend the colors of top fixed/sticky headers 
that are intended to
span the entire viewport width (e.g. `width: 100vw;`) but end up falling short 
due to the fact that
we needed to shrink to fit content (initial scale < 1). This is because the 
heuristic to figure out
whether a viewport-constrained element spans the length of the viewport checks 
the dimensions of the
element against the fixed-position layout rect, which may be larger than the 
viewport rect for CSS
units (`vw`, `vh`) in the scenario described above.

To fix this, we use the smaller of the viewport width for CSS units and the 
actual viewport width
(layout rect for fixed elements) when determining whether a candidate element 
is meant to span the
entire viewport.

* 
LayoutTests/fast/page-color-sampling/color-sampling-horizontal-overflow-with-viewport-meta-expected.txt:
 Added.
* 
LayoutTests/fast/page-color-sampling/color-sampling-horizontal-overflow-with-viewport-meta.html:
 Added.
* Source/WebCore/page/LocalFrameView.cpp:
(WebCore::LocalFrameView::fixedContainerEdges const):

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to