feat(android): add StatusBarBackgroundColor preference to config.xml, update BackgroundColor regarding Android#1502
Open
GitToTheHub wants to merge 6 commits into
Conversation
…ml`, update `BackgroundColor` regarding Android - `StatusBarBackgroundColor` is handled since cordova-android 15, which is reused from cordova-plugin-statusbar. When`AndroidEdgeToEdge` is `true`, this preference may not produce a visible status bar background fill, but it can still influence status bar icon/text light-versus-dark appearance. - Add prefernce example of`StatusBarBackgroundColor` - Update documentation of `BackgroundColor` that on Android if `StatusBarBackgroundColor` is not set, this value is also used for the status bar. Depending on the Android OS version, this preference may also change the navigation/gesture bar. Edge case: if the value is invalid, Cordova ignores it and falls back to platform defaults/fallback colors. - Add note to AndroidEdgeToEdge, that when it set the built-in StatusBar JavaScript API methods (such as `window.statusbar.setBackgroundColor`) are not applied. - Generated-By: GPT-5.3-Codex
- Edge case: when `AndroidEdgeToEdge` is `true`, this preference may not produce a visible status bar background fill, but it can still influence status bar icon/text light-versus-dark appearance. - Generated-By: GPT-5.3-Codex
dpogue
reviewed
May 21, 2026
Member
dpogue
left a comment
There was a problem hiding this comment.
A bunch of what you've written for Android also applies in cordova-ios 8.x
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.
Platforms affected
Motivation and Context
StatusBarBackgroundColoris handled since cordova-android 15, which is reused from cordova-plugin-statusbar. WhenAndroidEdgeToEdgeistrue, this preference may not produce a visible status bar background fill, but it can still influence status bar icon/text light-versus-dark appearance.StatusBarBackgroundColorBackgroundColorthat on Android ifStatusBarBackgroundColoris not set, this value is also used for the status bar. Depending on the Android OS version, this preference may also change the navigation/gesture bar. WhenAndroidEdgeToEdgeistrue, this preference may not produce a visible status bar background fill, but it can still influence status bar icon/text light-versus-dark appearance. If the value is invalid, Cordova ignores it and falls back to platform defaults/fallback colors.AndroidEdgeToEdge, that when using cordova-android 15 and the preference is set, the built-in StatusBar JavaScript API methods (such aswindow.statusbar.setBackgroundColor) are not applied.Description
Testing
Checklist
(platform)if this change only applies to one platform (e.g.(android))