Bug 213394 - When in dark mode, switching to a light theme on the page results in invisible (light) scrollbars
Summary: When in dark mode, switching to a light theme on the page results in invisibl...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Scrolling (show other bugs)
Version: Safari Technology Preview
Hardware: Mac macOS 10.15
: P2 Major
Assignee: Nobody
URL: https://twitter.com/anthony_ricaud/st...
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-06-19 11:32 PDT by Sean Patterson
Modified: 2021-06-17 05:25 PDT (History)
5 users (show)

See Also:


Attachments
Reduced Testcase (976 bytes, text/html)
2020-06-19 12:59 PDT, Anthony Ricaud
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sean Patterson 2020-06-19 11:32:43 PDT
See  https://twitter.com/anthony_ricaud/status/1273751909573234689?s=20

It was reported on Release 108 (Safari 13.2, WebKit 15610.1.16.3) macOS 10.15.5

It appears the scrollbars aren't updating in while in dark mode. I have yet to confirm.
Comment 1 Radar WebKit Bug Importer 2020-06-19 11:42:22 PDT
<rdar://problem/64538999>
Comment 2 Anthony Ricaud 2020-06-19 12:59:33 PDT
Created attachment 402309 [details]
Reduced Testcase

With this reduced testcase, it seems the scrollbar color does not adapt to the background color in Dark mode with `color-scheme: light dark`.

If you remove `color-scheme: light dark`, the scrollbar always adapts to the background color.
Comment 3 Simon Fraser (smfr) 2020-06-19 13:36:52 PDT
When the page is in light mode, and the OS is dark mode, FrameView::recalculateScrollbarOverlayStyle() computes an overlay scrollbar style of ScrollbarOverlayStyleDefault, which I think means "use the OS default" which gives the wrong color.