RCTTextField was spliited into two classes

Summary:
Motivation:
 * We maintain two different implementation of <TextInput> (multilined and singlelined), this change makes the implementations much similar which will help us to support and improve both of them in the (near) future;
 * We have to have separated RCTView-based container view for (TextField) to support sofisticated bordering and so on;
 * It opens to us possibility to unify UITextView and UITextField subclasses and remove code duplication across RCTTextView and RCTTextField;
 * Making things decoupled in general will allow us to fix existing bugs with events.

Reviewed By: mmmulani

Differential Revision: D5083010

fbshipit-source-id: 2f2d42c2244d2b39256c51480c1f16f4e3947c01
This commit is contained in:
Valentin Shergin
2017-05-29 15:56:47 -07:00
committed by Facebook Github Bot
parent 48650226e8
commit e13b9c6e49
10 changed files with 372 additions and 192 deletions

View File

@@ -773,6 +773,9 @@ exports.examples = [
backgroundColor: '#eeeeee',
borderColor: '#666666',
borderWidth: 5,
borderTopWidth: 20,
borderRadius: 10,
borderBottomRightRadius: 20,
padding: 10,
paddingTop: 20,
}}
@@ -780,7 +783,7 @@ exports.examples = [
/>
</View>
<Text>Multiline TextInput</Text>
<View style={{height: 80}}>
<View style={{height: 130}}>
<TextInput
style={{
position: 'absolute',
@@ -788,9 +791,12 @@ exports.examples = [
backgroundColor: '#eeeeee',
borderColor: '#666666',
borderWidth: 5,
borderTopWidth: 20,
borderRadius: 10,
borderBottomRightRadius: 20,
padding: 10,
paddingTop: 20,
borderTopWidth: 20,
maxHeight: 100
}}
multiline={true}
placeholder="Placeholder defines intrinsic size"