Color the browser title bar to match the theme - #276
Merged
Merged
Conversation
Safari (and Chrome on Android) tint the title/tool bar from <meta name="theme-color">. theme.js now creates that tag and sets it to the navbar background of the effective theme (white for light, #1e293b for dark), so the bar no longer stays bright in dark mode. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Safari only updates its title bar on load, not when the theme is switched on an open page. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
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.
What
Safari (and Chrome on Android) tint their title/tool bar from
<meta name="theme-color">. The page had none, so the bar stayed bright in dark mode.theme.jsnow creates the tag and sets it to the navbar background of the effective theme:#fffffffor light,#1e293bfor dark. It is set on every page load, including System following the OS setting.Known limitation
In Safari the bar only changes when a page loads. Switching the theme from the popover on an already open page leaves the bar in the old color until the next reload. I tried replacing the tag on each change and setting it again after the reveal transition finished; neither made Safari update, so both were dropped.
Testing
🤖 Generated with Claude Code