feat(menu-bar): add monochrome icon mode with template rendering#16
Open
jeanfw wants to merge 1 commit into
Open
feat(menu-bar): add monochrome icon mode with template rendering#16jeanfw wants to merge 1 commit into
jeanfw wants to merge 1 commit into
Conversation
Adds a "Use Colored Status Icon" toggle in Settings (default off). When off, the menu bar icon is rendered as a black-on-clear template image so macOS tints it to match the system menu bar (white in dark mode, black in light mode), aligning with the system tray's monochrome aesthetic. When on, the original green/orange/red status colours are preserved. Colour resolution is centralised in a new MenuBarIconColors helper and threaded through every IconStyle plus the renderer and the icon cache key. AppSettings stays backwards compatible: an existing serialised settings blob without "use_colored_icon" decodes with the new field defaulted to off.
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.
Summary
Adds an opt-in monochrome mode for the menu bar icon so it matches the system tray's white-on-dark / black-on-light aesthetic instead of standing out with green/orange/red status colours.
Use Colored Status Icontoggle in Settings → General (default off, monochrome).NSImage.isTemplate = true) so macOS tints it to match the menu bar.MenuBarIconColorshelper and threaded through every IconStyle plus the renderer and the cache key.AppSettingsstays backwards compatible: a saved settings blob withoutuse_colored_icondecodes with the new field defaulted to off (custominit(from:)falling back to.default).Why monochrome by default
Most macOS menu bar apps (system, third-party, Apple's own) render their tray icon as a template image so it inherits the menu bar tint. ClaudeMeter's coloured icon sticks out visually next to them. Making monochrome the default brings it in line with the system aesthetic; users who liked the at-a-glance colour-coded status can flip the toggle back on.
Preview
The existing
#Preview(\"All Styles\")block still shows the coloured layout. A new#Preview(\"Monochrome\")block renders all six styles in the new mode.Test plan
MenuBarIconRendererTestsandMenuBarIconSnapshotTestsstill pass (colour mode is the default, matches old behaviour).useColoredIconinitialises to off.🤖 Generated with Claude Code