Commit dfddcc9
Respect theme
Summary:
This PR adds respect of the theme's `enforceNavigationBarContrast` attribute in `WindowUtil` `enableEdgeToEdge` (this will allow us to delete our [EdgeToEdgePackage.kt](https://github.com/expo/expo/blob/main/packages/expo-modules-core/android/src/main/java/expo/modules/kotlin/edgeToEdge/EdgeToEdgePackage.kt) file, and prevent a glitch where the navigation bar is semi-opaque for a short instant when user explicitly set `android:enforceNavigationBarContrast` to `false`).
## Changelog:
[ANDROID] [CHANGED] - Respect theme `enforceNavigationBarContrast` attribute
Pull Request resolved: #56413
Test Plan:
- Verified edge-to-edge rendering on API 30+ (transparent status/navigation bars, correct display cutout behavior).
- Verified navigation bar contrast enforcement respects the theme attribute on API 29+ (with `android:enforceNavigationBarContrast` to `true` (default) and `false`).
- Verified fallback navigation bar colors on API 26-28 (light/dark scrim) and API < 26 (dark scrim).
Additional screenshots are found here: #56413 (comment)
Reviewed By: cipolleschi
Differential Revision: D100384656
Pulled By: alanleedev
fbshipit-source-id: 570323408c788d58d1249671a2b19c8539815d00enforceNavigationBarContrast attribute (#56413)1 parent 40c7d8f commit dfddcc9
File tree
1 file changed
+26
-12
lines changed- packages/react-native/ReactAndroid/src/main/java/com/facebook/react/views/view
1 file changed
+26
-12
lines changedLines changed: 26 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
106 | 106 | | |
107 | 107 | | |
108 | 108 | | |
| 109 | + | |
109 | 110 | | |
110 | 111 | | |
| 112 | + | |
| 113 | + | |
111 | 114 | | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
112 | 127 | | |
113 | | - | |
114 | | - | |
| 128 | + | |
115 | 129 | | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
126 | 140 | | |
127 | 141 | | |
128 | 142 | | |
| |||
0 commit comments