From 31a4a4ef719a09f35ea83949e069322bfee92372 Mon Sep 17 00:00:00 2001 From: Liangyu Date: Sun, 17 Dec 2017 15:36:37 +0800 Subject: [PATCH] iPhoneX fit --- components/NavigationBar/NavigationBar.js | 5 +++-- components/PullPicker/PullPickerView.js | 3 ++- package.json | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/components/NavigationBar/NavigationBar.js b/components/NavigationBar/NavigationBar.js index c3d5687..3137894 100644 --- a/components/NavigationBar/NavigationBar.js +++ b/components/NavigationBar/NavigationBar.js @@ -85,6 +85,7 @@ export default class NavigationBar extends Component { titleTextAlign = 'left'; break; } + let {left: leftInset, right: rightInset} = Theme.screenInset; style = [{ backgroundColor: Theme.navColor, position: 'absolute', @@ -92,8 +93,8 @@ export default class NavigationBar extends Component { right: 0, height: Theme.navBarContentHeight + (statusBarInsets ? Theme.statusBarHeight : 0), paddingTop: statusBarInsets ? Theme.statusBarHeight : 0, - paddingLeft: 4, - paddingRight: 4, + paddingLeft: 4 + leftInset, + paddingRight: 4 + rightInset, borderBottomWidth: Theme.navSeparatorLineWidth, borderBottomColor: Theme.navSeparatorColor, flexDirection: 'row', diff --git a/components/PullPicker/PullPickerView.js b/components/PullPicker/PullPickerView.js index 18a794a..b3a491e 100644 --- a/components/PullPicker/PullPickerView.js +++ b/components/PullPicker/PullPickerView.js @@ -51,8 +51,9 @@ export default class PullPickerView extends Overlay.PullView { backgroundColor: Theme.pupHeaderSeparatorColor, height: Theme.pupHeaderSeparatorHeight, } + let {left: leftInset, right: rightInset} = Theme.screenInset; children = ( - + {!title ? null :