Replace providesDefault in Navigator with provides and an if check#500
Open
hristogochev wants to merge 1 commit into
Conversation
Collaborator
|
It seems it was fixed and published at Google Jetpack compose |
Author
|
Sure, we can wait for the fix to reach Compose Multiplatform instead! Given that Compose Multiplatform was only released 2 days ago and the usual release cycle for a new major release is around 3-4 months, I think it will take at least 3 months until a release with these fixes is published. |
blackbbc
added a commit
to blackbbc/voyager
that referenced
this pull request
Apr 21, 2026
Workaround for CMP-6891: using `providesDefault` for LocalNavigatorStateHolder blocks inherited outer CompositionLocal updates from reaching the Navigator subtree. Symptoms seen on ovCompose / Compose Multiplatform pre-1.8.0-alpha06: theme changes do not propagate below Navigator, causing stale colors in all screens until the app is restarted. Backport of adrielcafe#500 — change LocalNavigatorStateHolder to a nullable static local and only provide it when absent, instead of using providesDefault. Refs: - https://youtrack.jetbrains.com/issue/CMP-6891 - adrielcafe#500
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 is a workaround for an issue with Compose Multiplatform which prevents theme and system padding updates from happening inside nested navigators.
Fixes #484, #486 and #489.