Update Rust crate dark-light to v3 - #382
Open
renovate[bot] wants to merge 1 commit into
Open
Conversation
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.
This PR contains the following updates:
2.0.0→3.0.0Release Notes
rust-dark-light/rust-dark-light (dark-light)
v3.0.0Compare Source
We're thrilled to announce the release of version 3.0.0! 🚀
After listening to your feedback, this update brings exciting changes to the API.
Consumers can now react to system theme changes instead of only polling
detect(). Two new entry points are available:dark_light::subscribe() -> Result<Watcher, Error>— a blocking watcher for any thread or event-loop poll, no async runtime required.dark_light::stream() -> Result<impl Stream<Item = Mode>, Error>— an async adapter over the same watcher. Enabled by default via theasync-iofeature, ortokio.This works across all supported platforms: the XDG portal's
SettingChangedD-Bus signal on Linux/BSD,RegNotifyChangeKeyValueon Windows, and the nativeMediaQueryListchangeevent on WASM.On macOS, changes are currently detected via a 1-second polling thread rather than a native notification. Observing
NSDistributedNotificationCenterrequires a hand-rolled Objective-C delegate that isn't yet safely exposed by theobjc2bindings we use, so we're shipping this version now and may revisit it later.We had originally removed this feature entirely over the macOS limitation, but Linux, Windows, and WASM all had working implementations, and macOS was the only blocker. Dropping the feature for everyone over one platform's rough edges didn't sit right, so we're reintroducing it here.
What's Changed
objc2-foundationv0.3 by @madsmtm in rust-dark-light/dark-light#64New Contributors
Full Changelog: rust-dark-light/dark-light@2.0.0...3.0.0
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.