1010
1111import type { PartialViewConfig } from '../../Renderer/shims/ReactNativeTypes' ;
1212
13+ type PartialViewConfigWithoutName = $Rest <
14+ PartialViewConfig ,
15+ { uiViewClassName : string } ,
16+ > ;
17+
1318const RCTTextInputViewConfig = {
14- uiViewClassName : 'RCTSinglelineTextInputView' ,
1519 bubblingEventTypes : {
1620 topBlur : {
1721 phasedRegistrationNames : {
@@ -25,6 +29,12 @@ const RCTTextInputViewConfig = {
2529 captured : 'onChangeCapture' ,
2630 } ,
2731 } ,
32+ topContentSizeChange : {
33+ phasedRegistrationNames : {
34+ captured : 'onContentSizeChangeCapture' ,
35+ bubbled : 'onContentSizeChange' ,
36+ } ,
37+ } ,
2838 topEndEditing : {
2939 phasedRegistrationNames : {
3040 bubbled : 'onEndEditing' ,
@@ -69,7 +79,23 @@ const RCTTextInputViewConfig = {
6979 } ,
7080 } ,
7181 } ,
72- directEventTypes : { } ,
82+ directEventTypes : {
83+ topTextInput : {
84+ registrationName : 'onTextInput' ,
85+ } ,
86+ topKeyPressSync : {
87+ registrationName : 'onKeyPressSync' ,
88+ } ,
89+ topScroll : {
90+ registrationName : 'onScroll' ,
91+ } ,
92+ topSelectionChange : {
93+ registrationName : 'onSelectionChange' ,
94+ } ,
95+ topChangeSync : {
96+ registrationName : 'onChangeSync' ,
97+ } ,
98+ } ,
7399 validAttributes : {
74100 fontSize : true ,
75101 fontWeight : true ,
@@ -97,23 +123,18 @@ const RCTTextInputViewConfig = {
97123 caretHidden : true ,
98124 enablesReturnKeyAutomatically : true ,
99125 placeholderTextColor : { process : require ( '../../StyleSheet/processColor' ) } ,
100- onSelectionChange : true ,
101126 clearButtonMode : true ,
102- onContentSizeChange : true ,
103127 keyboardType : true ,
104128 selection : true ,
105129 returnKeyType : true ,
106130 blurOnSubmit : true ,
107131 mostRecentEventCount : true ,
108- onChange : true ,
109132 scrollEnabled : true ,
110133 selectionColor : { process : require ( '../../StyleSheet/processColor' ) } ,
111134 contextMenuHidden : true ,
112135 secureTextEntry : true ,
113- onTextInput : true ,
114136 placeholder : true ,
115137 autoCorrect : true ,
116- onScroll : true ,
117138 multiline : true ,
118139 textContentType : true ,
119140 maxLength : true ,
@@ -124,7 +145,9 @@ const RCTTextInputViewConfig = {
124145 selectTextOnFocus : true ,
125146 text : true ,
126147 clearTextOnFocus : true ,
148+ showSoftInputOnFocus : true ,
149+ autoFocus : true ,
127150 } ,
128151} ;
129152
130- module . exports = ( RCTTextInputViewConfig : PartialViewConfig ) ;
153+ module . exports = ( RCTTextInputViewConfig : PartialViewConfigWithoutName ) ;
0 commit comments