react-native-navigation 8.2.2 → 8.3.0-snapshot.1847

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.e2e.js CHANGED
@@ -1,4 +1,3 @@
1
- import "setimmediate";
2
1
  import { LogBox } from 'react-native';
3
2
 
4
3
  LogBox.ignoreAllLogs();
@@ -12,7 +12,6 @@ import androidx.core.view.WindowInsetsControllerCompat
12
12
  import kotlin.math.abs
13
13
  import kotlin.math.ceil
14
14
 
15
-
16
15
  object SystemUiUtils {
17
16
  private const val STATUS_BAR_HEIGHT_M = 24
18
17
  internal const val STATUS_BAR_HEIGHT_TRANSLUCENCY = 0.65f
@@ -20,7 +19,6 @@ object SystemUiUtils {
20
19
  var navigationBarDefaultColor = -1
21
20
  private set
22
21
 
23
-
24
22
  @JvmStatic
25
23
  fun getStatusBarHeight(activity: Activity?): Int {
26
24
  val res = if (statusBarHeight > 0) {
@@ -167,4 +165,4 @@ object SystemUiUtils {
167
165
  }
168
166
  }
169
167
 
170
- }
168
+ }
@@ -316,10 +316,12 @@ public class BottomTabsController extends ParentController<BottomTabsLayout> imp
316
316
  @Override
317
317
  protected WindowInsetsCompat onApplyWindowInsets(View view, WindowInsetsCompat insets) {
318
318
  Insets sysInsets = insets.getInsets(WindowInsetsCompat.Type.systemBars());
319
- view.setPaddingRelative(0, 0, 0, sysInsets.bottom);
320
- return WindowInsetsCompat.CONSUMED;
321
- }
319
+ Insets imeInsets = insets.getInsets(WindowInsetsCompat.Type.ime());
322
320
 
321
+ int bottomInset = (imeInsets.bottom > 0) ? 0 : sysInsets.bottom;
322
+ view.setPaddingRelative(0, 0, 0, bottomInset);
323
+ return insets;
324
+ }
323
325
 
324
326
  @RestrictTo(RestrictTo.Scope.TESTS)
325
327
  public BottomTabs getBottomTabs() {
@@ -120,7 +120,8 @@ class StatusBarPresenter private constructor(
120
120
 
121
121
  private fun setStatusBarVisible(viewController: ViewController<*>, visible: Bool) {
122
122
  val window = window.get() ?: return
123
- val view = if (viewController.view != null) viewController.view else window.decorView
123
+ val view = viewController.peekView() ?: window.decorView
124
+
124
125
  if (visible.isFalse) {
125
126
  hideStatusBar(window, view)
126
127
  } else {
@@ -254,6 +254,11 @@ public abstract class ViewController<T extends ViewGroup> implements ViewTreeObs
254
254
  if (view.getParent() == null) parent.addView(view, index);
255
255
  }
256
256
 
257
+ @Nullable
258
+ public T peekView() {
259
+ return view;
260
+ }
261
+
257
262
  public String getId() {
258
263
  return id;
259
264
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-navigation",
3
- "version": "8.2.2",
3
+ "version": "8.3.0-snapshot.1847",
4
4
  "description": "React Native Navigation - truly native navigation for iOS and Android",
5
5
  "license": "MIT",
6
6
  "nativePackage": true,
@@ -122,7 +122,6 @@
122
122
  "redux": "3.x.x",
123
123
  "remx": "3.x.x",
124
124
  "semver": "5.x.x",
125
- "setimmediate": "^1.0.5",
126
125
  "shell-utils": "1.x.x",
127
126
  "ts-mockito": "^2.3.1",
128
127
  "typedoc": "0.x.x",