position: fixed root scroller interacts poorly with URL bar |
|||
Issue descriptionChrome Version: 68.0.3439.0 OS: Android Repro: https://jsbin.com/lubesedoyo/1/quiet What steps will reproduce the problem? (1) Scroll down the page to hide the URL bar What is the expected result? The page should stay "stuck" to the URL bar as it hides What happens instead? The URL bar hides without moving the page, breaking the illusion that the URL bar is fixed with respect to the content. See https://github.com/valdrinkoshi/virtual-scroller/issues/82#issuecomment-391658637 for some more details.
,
May 24 2018
,
Sep 19
Usable repro link: https://output.jsbin.com/pecado/1/quiet
,
Sep 19
This isn't so much an issue in rootScroller as it is the interaction between the URL bar and fixed elements that have both top and bottom properties set. In that case we prefer sticking to the bottom but I think it'd be more intuitive for that case to use top.
,
Sep 26
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/77b67445ba6e415e8b41b5b6fd5c016c7195206d commit 77b67445ba6e415e8b41b5b6fd5c016c7195206d Author: David Bokan <bokan@chromium.org> Date: Wed Sep 26 23:14:35 2018 Elements with fixed bottom and top stick to top When an element is position: fixed and specifies a value for bottom, we want it to stick to the bottom of the viewport as the URL bar hides (and the renderer is moved up). However, we missed the special case where both top and bottom are specified. We can't resize the element in real time but it's more intuitive to have the element stick to the screen top. This also exposed an issue in how we raster the area exposed by the URL bar. Since we don't resize the viewport layers until the finger is lifted, the raster code needs to adjust the visible rect by the amount the URL bar is hidden. This was done by always adding the entire top controls height in the pending tree. This was guarded by an ANDROID ifdef which meant the test added here didn't get its benefit and produced unrastered tiles. I removed the ifdef (URL bar hiding is now also available on ChromeOS) and improved the expansion to make it more exactly match the amount of extra visible area. Bug: 846322 Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_layout_tests_slimming_paint_v2;master.tryserver.blink:linux_trusty_blink_rel Change-Id: I02700e08e8254a64405c3adb1a7a123b65468f44 Reviewed-on: https://chromium-review.googlesource.com/1235123 Commit-Queue: David Bokan <bokan@chromium.org> Reviewed-by: Stefan Zager <szager@chromium.org> Reviewed-by: vmpstr <vmpstr@chromium.org> Cr-Commit-Position: refs/heads/master@{#594515} [modify] https://crrev.com/77b67445ba6e415e8b41b5b6fd5c016c7195206d/cc/layers/picture_layer_impl.cc [add] https://crrev.com/77b67445ba6e415e8b41b5b6fd5c016c7195206d/third_party/WebKit/LayoutTests/virtual/android/url-bar/bottom-and-top-fixed-sticks-to-top-expected.html [add] https://crrev.com/77b67445ba6e415e8b41b5b6fd5c016c7195206d/third_party/WebKit/LayoutTests/virtual/android/url-bar/bottom-and-top-fixed-sticks-to-top.html [modify] https://crrev.com/77b67445ba6e415e8b41b5b6fd5c016c7195206d/third_party/blink/renderer/core/page/chrome_client_impl.cc [modify] https://crrev.com/77b67445ba6e415e8b41b5b6fd5c016c7195206d/third_party/blink/renderer/core/page/scrolling/scrolling_coordinator.cc [modify] https://crrev.com/77b67445ba6e415e8b41b5b6fd5c016c7195206d/third_party/blink/renderer/core/paint/paint_property_tree_builder.cc [modify] https://crrev.com/77b67445ba6e415e8b41b5b6fd5c016c7195206d/third_party/blink/renderer/core/style/computed_style.h
,
Oct 17
|
|||
►
Sign in to add a comment |
|||
Comment 1 by bokan@chromium.org
, May 24 2018