feat(tabs): respect iosOverflowSafeArea value

This commit is contained in:
Igor Randjelovic
2020-12-05 21:38:35 +01:00
parent 1dd6cf19c3
commit 1ba4230dbe
4 changed files with 40 additions and 5 deletions

View File

@@ -174,15 +174,16 @@ class UIPageViewControllerImpl extends UIPageViewController {
safeAreaInsetsTop = this.topLayoutGuide.length;
}
let conditionalSafeAreaBottom = owner.iosOverflowSafeArea ? safeAreaInsetsBottom : 0;
let scrollViewTop = 0;
let scrollViewHeight = this.view.bounds.size.height;
let scrollViewHeight = this.view.bounds.size.height + conditionalSafeAreaBottom;
if (owner.tabStrip) {
const tabBarHeight = this.tabBar.frame.size.height;
let tabBarTop = safeAreaInsetsTop;
scrollViewTop = tabBarHeight;
scrollViewHeight = this.view.bounds.size.height - tabBarHeight;
scrollViewHeight = this.view.bounds.size.height - tabBarHeight + conditionalSafeAreaBottom;
const tabsPosition = owner.tabsPosition;
if (tabsPosition === "bottom") {