From 4e4052162042fc26fe17cc4eb2e2deb28a5344fa Mon Sep 17 00:00:00 2001 From: Valentin Shergin Date: Mon, 29 May 2017 15:56:44 -0700 Subject: [PATCH] Forcing to `alignSelf: stretch` was removed from Summary: Because it introduces inconsistency in RN layout model, confuses people and hurts dev experience. The original problem was introduced in D1611014 as an attempt to address the intrinsic size issue. So, now has intrinsic size (D5069971) and we don't need this hack anymore. GH issues: https://github.com/facebook/react-native/issues/11892 https://github.com/facebook/react-native/issues/9646 Reviewed By: javache Differential Revision: D5072833 fbshipit-source-id: d9a60ab09b728e6de89bfa53eda07069377f1369 --- Libraries/Components/TextInput/TextInput.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/Libraries/Components/TextInput/TextInput.js b/Libraries/Components/TextInput/TextInput.js index b47b785b0..f18f6c648 100644 --- a/Libraries/Components/TextInput/TextInput.js +++ b/Libraries/Components/TextInput/TextInput.js @@ -628,7 +628,7 @@ const TextInput = React.createClass({ var textContainer; var props = Object.assign({}, this.props); - props.style = [styles.input, this.props.style]; + props.style = [this.props.style]; if (props.selection && props.selection.end == null) { props.selection = {start: props.selection.start, end: props.selection.start}; @@ -859,9 +859,6 @@ const TextInput = React.createClass({ }); var styles = StyleSheet.create({ - input: { - alignSelf: 'stretch', - }, multilineInput: { // This default top inset makes RCTTextView seem as close as possible // to single-line RCTTextField defaults, using the system defaults