v1.2.2: never let Night Shift toggles flip the Light/Dark theme - #14
Merged
Conversation
On some macOS versions (confirmed on Sonoma 14.5), the "Auto" appearance setting is coupled to the Night Shift engine: toggling Night Shift also flips the system Light/Dark theme. Users treat Night Shift tinting and the theme as independent settings, so no ShiftChange action should ever change the theme — this affected both the new menu bar toggle and the per-app override. The bridge now snapshots the theme (SkyLight SLSGetAppearanceThemeLegacy) around every setNightShiftEnabled: call and restores it if it changes within ~3s (checks at 0.3/1.2/3.0s; a generation counter lets rapid toggles supersede older guards). Behavior-neutral on macOS versions without the coupling — the guard only acts when a flip actually happens — and theme changes made outside our own calls are never touched. Verified live on Sonoma 14.5: toggling Night Shift off flipped the theme (guard log confirms) and it was restored within 300ms; theme identical before/after a full off/on cycle. Bump version to 1.2.2. Co-Authored-By: Claude Fable 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.
On some macOS versions (confirmed on Sonoma 14.5; apparently decoupled on newer releases), the "Auto" appearance setting is tied to the Night Shift engine — toggling Night Shift also flips the system Light/Dark theme. This affected both the menu bar toggle and the per-app override.
The bridge now snapshots the theme around every
setNightShiftEnabled:call (SkyLightSLSGet/SetAppearanceThemeLegacy) and restores it if it flips within ~3s. Behavior-neutral on OS versions without the coupling; theme changes made outside our own calls are never touched.Verified live on Sonoma 14.5: the guard's log confirms macOS flipped the theme on toggle-off and the guard restored it within 300ms — theme identical through a full off/on cycle.
This release is also the first to exercise the
TAP_PUSH_TOKENtap auto-update.🤖 Generated with Claude Code