Skip to content

[css-color-adjust-1] Root viewport non-overlay scrollbars should follow the user's preferred color scheme by default #8603

@yshalivskyy

Description

@yshalivskyy

Root viewport non-overlay scrollbars don't follow the user's preferred color scheme set using OS or browser appearance setting when the CSS color-scheme property for a given container or color-scheme meta tag is unspecified or set to normal (default). Many web pages don't specify the support for light/dark color schemes using CSS color-scheme property or color-scheme meta tag. In such a case, the used color scheme is light for scrollbars and other interactive UI elements despite the user preference set on the browser/OS level. The behavior creates a confusing experience for users who have selected dark mode as a preferred color scheme and expect interactive UI elements like scrollbars to follow their choice.

The experience is particularly drastic for root non-overlay scrollbars, which always stay on the side of the page and are treated by users as a part of the browser UI. Example user feedback for Edge and Chrome.

I propose adjusting the calculation of the used color scheme for the root non-overlay scrollbar to follow the user's preferred color scheme by default if a page author doesn't override user's preference by root CSS color-scheme property or meta tag. Effectively, nothing will change if the user's preferred color scheme is light. However, if the user's preferred color scheme is dark, the root scrollbar will follow the user's preference. Other scrollbars and elements will follow the existing logic for used color scheme calculation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Agenda+ LaterLower-priority items that are flagged for CSSWG discussioncss-color-adjust-1Current Work

    Type

    No type

    Projects

    Status

    Unslotted

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions