@@ -5,11 +5,11 @@ import {ReactNativeWrapper, isAndroid} from './../wrapper/wrapper';
55import { HighLevelComponent , GENERIC_INPUTS , GENERIC_BINDINGS } from "./component" ;
66
77var ANDROID_INPUTS : Array < string > = [ 'numberOfLines' , 'underlineColorAndroid' ] ;
8- var IOS_INPUTS : Array < string > = [ 'blurOnSubmit' , ' clearButtonMode', 'clearTextOnFocus' , 'enablesReturnKeyAutomatically' ,
8+ var IOS_INPUTS : Array < string > = [ 'clearButtonMode' , 'clearTextOnFocus' , 'enablesReturnKeyAutomatically' ,
99 'keyboardAppearance' , 'returnKeyType' , 'selectTextOnFocus' ] ;
1010
1111var ANDROID_BINDINGS : string = `[numberOfLines]="_numberOfLines" [underlineColorAndroid]="_underlineColorAndroid" (topTextInput)="_handleKeyPress($event)"` ;
12- var IOS_BINDINGS : string = `[blurOnSubmit]="_blurOnSubmit" [ clearButtonMode]="_clearButtonMode" [clearTextOnFocus]="_clearTextOnFocus"
12+ var IOS_BINDINGS : string = `[clearButtonMode]="_clearButtonMode" [clearTextOnFocus]="_clearTextOnFocus"
1313 [enablesReturnKeyAutomatically]="_enablesReturnKeyAutomatically" [keyboardAppearance]="_keyboardAppearance"
1414 [returnKeyType]="_returnKeyType" [selectTextOnFocus]="_selectTextOnFocus" (topKeyPress)="_handleKeyPress($event)"` ;
1515
@@ -33,10 +33,10 @@ export class Sample {
3333 //Non-native
3434 'autoFocus' ,
3535 //Native
36- 'autoCapitalize' , 'autoCorrect' , 'editable' , 'keyboardType' , 'maxLength' , 'multiline' ,
36+ 'autoCapitalize' , 'autoCorrect' , 'blurOnSubmit' , ' editable', 'keyboardType' , 'maxLength' , 'multiline' ,
3737 'password' , 'placeholder' , 'placeholderTextColor' , 'selectionColor'
3838 ] . concat ( GENERIC_INPUTS ) . concat ( isAndroid ( ) ? ANDROID_INPUTS : IOS_INPUTS ) ,
39- template : `<native-textinput [text]="_getText()" [autoCapitalize]="_autoCapitalize" [autoCorrect]="_autoCorrect" [editable]="_editable" [keyboardType]="_keyboardType"
39+ template : `<native-textinput [text]="_getText()" [autoCapitalize]="_autoCapitalize" [autoCorrect]="_autoCorrect" [blurOnSubmit]="_blurOnSubmit" [ editable]="_editable" [keyboardType]="_keyboardType"
4040 [maxLength]="_maxLength" [multiline]="_multiline" [password]="_password" [placeholder]="_placeholder" [placeholderTextColor]="_placeholderTextColor" [selectionColor]="_selectionColor"
4141 (tap)="focusTextInput()" (topFocus)="_handleFocus()" (topChange)="_handleChange($event)" (topSubmitEditing)="_handleSubmitEditing($event)"
4242 (topBlur)="_handleBlur()" (topEndEditing)="_handleEndEditing($event)" ${ GENERIC_BINDINGS } ${ isAndroid ( ) ? ANDROID_BINDINGS : IOS_BINDINGS } ></native-textinput>`
@@ -89,6 +89,7 @@ export class TextInput extends HighLevelComponent implements OnInit {
8989
9090 private _autoCapitalize : string ;
9191 private _autoCorrect : boolean ;
92+ private _blurOnSubmit : boolean ;
9293 private _editable : boolean ;
9394 private _keyboardType : string ;
9495 private _maxLength : number ;
@@ -105,6 +106,10 @@ export class TextInput extends HighLevelComponent implements OnInit {
105106 * To be documented
106107 */
107108 set autoCorrect ( value : any ) { this . _autoCorrect = this . processBoolean ( value ) ; }
109+ /**
110+ * To be documented
111+ */
112+ set blurOnSubmit ( value : any ) { this . _blurOnSubmit = this . processBoolean ( value ) ; }
108113 /**
109114 * To be documented
110115 */
@@ -151,18 +156,12 @@ export class TextInput extends HighLevelComponent implements OnInit {
151156 */
152157 set underlineColorAndroid ( value : string ) { this . _underlineColorAndroid = this . processColor ( value ) ; }
153158
154- private _blurOnSubmit : boolean ;
155159 private _clearButtonMode : boolean ;
156160 private _clearTextOnFocus : boolean ;
157161 private _enablesReturnKeyAutomatically : boolean ;
158162 private _keyboardAppearance : string ;
159163 private _returnKeyType : string ;
160164 private _selectTextOnFocus : boolean ;
161- /**
162- * To be documented
163- * @platform ios
164- */
165- set blurOnSubmit ( value : any ) { this . _blurOnSubmit = this . processBoolean ( value ) ; }
166165 /**
167166 * To be documented
168167 * @platform ios
0 commit comments