{{ message }}
Repository navigation
fix(connect): theme the Android account onboarding navigation bar from the appearance - #2723
Open
asendra-stripe wants to merge 2 commits into
Open
asendra-stripe wants to merge 2 commits into
asendra-stripe wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
Why did we need to add more theming parameters to the dev interface? This can be solved by using existing ones no?
(adding more requires API review as noted by @torrance-stripe )
r? @asendra-stripe
Contributor
Author
There was a problem hiding this comment.
@jorgea-stripe I reply on Slack but forgot to do it here. I have updated the PR to avoid modifying the public API. Let me know if that works for you!
…m the appearance On Android the account onboarding navigation bar was always white with black text, so in dark mode a white bar sat above a dark embedded component. The bar now takes its background from the colorBackground appearance variable and its title and close icon from colorText, and the area behind the status bar uses the background color too. Defaults are unchanged when the variables are not set. Adds toolbarBackgroundColor and toolbarContentColor to the native NavigationBar. NotificationBanner uses the same bar and can adopt the new props. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Committed-By-Agent: claude
…bar color Drops the new toolbarBackgroundColor and toolbarContentColor props, so the public API and its report are unchanged. The bar now takes its background from the backgroundColor of its style, which the native view manager passes on to the toolbar, and picks black or white content for contrast. Committed-By-Agent: claude
asendra-stripe
force-pushed
the
asendra/connect-android-navbar-appearance
branch
from
October 21, 2026 14:17
e228461 to
a7b929b
Compare
This branch has not been deployed
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
On Android, the
ConnectAccountOnboardingnavigation bar is always white with black text, and the area behind the status bar is white too. When the app uses a dark appearance, a white bar sits above a dark embedded component.This change makes the bar follow the appearance, using only existing props:
ConnectAccountOnboardingpasses thecolorBackgroundappearance variable as thebackgroundColorof the bar'sstyle, and as the background of the safe area behind the status bar (the component body already used it).style.backgroundColor. Its toolbar draws its own background, which used to cover the one React Native applies, so the view manager forwards the color to the toolbar.There are no API changes: no new props, and the API report, the native spec and the
NavigationBarwrapper are untouched.This matches iOS, where the native bar's background is also the
colorBackgroundappearance variable and the title and close button are not coloured fromcolorTexteither; they use the system colors, which are black in light mode and white in dark mode. Before this change nothing let an app set the Android title color, so choosing black or white by contrast removes no option.NotificationBannerrenders the same bar and could pass the same style. I did not change it because I could not exercise it.Motivation
In dark mode the Android onboarding screen shows a white header and white status-bar area above a dark component, which looks broken compared with iOS.
NavigationBarView.kthardcodesColor.WHITEfor the toolbar andColor.BLACKfor the title and close icon, so apps cannot fix this through the appearance API.Testing
Manually, on an Android API 37 emulator (Pixel 9a profile), with the change applied to stripe-react-native 0.79.0 in an app that sets the Connect appearance from its own light and dark themes:
Not tested: a real device, other Android versions,
NotificationBanner, a background that is a mid-tone color, and a live theme change while the screen is open (the status-bar icons keep the style they had when the screen opened).Automated: two
Componentstests check that, on Android, the bar's style gets the appearance background and falls back to white when the appearance sets none. Six Robolectric tests cover the black or white content choice. A deliberate break of each is caught.yarn test,yarn lintandtscpass, and so do the Kotlin format and lint hooks. I ran the Robolectric tests through an app's Gradle project, not throughyarn test:unit:android, which needs the example app's dependencies.Documentation
Select one:
Added a CHANGELOG entry.