From 86b2d66ddcc36025feedc6e9e9b038efa4b73414 Mon Sep 17 00:00:00 2001 From: Josh Levine Date: Fri, 3 Apr 2015 13:51:10 -0700 Subject: [PATCH 1/2] Added transitionBackgroundColor property to Navigator for setting the transition background color between scenes --- Libraries/CustomComponents/Navigator/Navigator.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/Libraries/CustomComponents/Navigator/Navigator.js b/Libraries/CustomComponents/Navigator/Navigator.js index acf9b383fe36ab..e25807444545f7 100644 --- a/Libraries/CustomComponents/Navigator/Navigator.js +++ b/Libraries/CustomComponents/Navigator/Navigator.js @@ -245,6 +245,11 @@ var Navigator = React.createClass({ * so the scenes will remain mounted */ shouldJumpOnBackstackPop: PropTypes.bool, + + /** + * The background color when transitioning between scenes + */ + transitionBackgroundColor: View.PropTypes.style.backgroundColor, }, statics: { @@ -972,10 +977,14 @@ var Navigator = React.createClass({ var items = shouldRecurseToNavigator ? this.state.routeStack.map(this._routeToOptimizedStackItem) : null; + var transitionerStyle = this.props.transitionBackgroundColor ? + [styles.transitioner, {backgroundColor: this.props.transitionBackgroundColor}] : + styles.transitioner; + return ( {items} From 544f668510b06d17a789c85be9b1b93dc5ee8f1d Mon Sep 17 00:00:00 2001 From: Josh Levine Date: Fri, 3 Apr 2015 15:08:47 -0700 Subject: [PATCH 2/2] Remove addition of transitionBackgroundColor property on Navigator, Changed navigator transition background color to 'transparent' --- Libraries/CustomComponents/Navigator/Navigator.js | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/Libraries/CustomComponents/Navigator/Navigator.js b/Libraries/CustomComponents/Navigator/Navigator.js index e25807444545f7..89975cdc5bd945 100644 --- a/Libraries/CustomComponents/Navigator/Navigator.js +++ b/Libraries/CustomComponents/Navigator/Navigator.js @@ -89,7 +89,7 @@ var styles = StyleSheet.create({ }, transitioner: { flex: 1, - backgroundColor: '#555555', + backgroundColor: 'transparent', overflow: 'hidden', } }); @@ -245,11 +245,6 @@ var Navigator = React.createClass({ * so the scenes will remain mounted */ shouldJumpOnBackstackPop: PropTypes.bool, - - /** - * The background color when transitioning between scenes - */ - transitionBackgroundColor: View.PropTypes.style.backgroundColor, }, statics: { @@ -977,14 +972,10 @@ var Navigator = React.createClass({ var items = shouldRecurseToNavigator ? this.state.routeStack.map(this._routeToOptimizedStackItem) : null; - var transitionerStyle = this.props.transitionBackgroundColor ? - [styles.transitioner, {backgroundColor: this.props.transitionBackgroundColor}] : - styles.transitioner; - return ( {items}