Let the hero surface and the reader backdrop follow the theme on iOS - #299
Merged
Conversation
The iOS-only variant of both (no blur, denser tint, #281) wrote the light colours into its rules, and as the last block in the file it beat the dark theme's own rules: on an iPhone in dark mode the search bar sat on a pale strip and the reader's backdrop tinted the wrong way (#293). Both colours are tokens now, defined for light and dark next to the other theme tokens, with a -solid pair the iOS variant uses.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #293.
The iOS-only variant of the hero surface and the reader backdrop (no blur, denser tint, from #282) wrote the light colours into its rules. As the last block in the stylesheet it beat the dark theme's own
.hero::afterrule at equal specificity, so on an iPhone in dark mode the search bar sat on a pale strip, exactly the reporter's screenshot. Regression from my own change.Both colours are tokens now (
--hero-surface-bg,--overlay-backdrop-bg, each with a-solidtwin), defined in the light:rootand redefined in the dark block next to the other theme tokens; the base rules and the iOS variant read the tokens. Behaviour on light themes and on non-iOS browsers is unchanged (same values).