react-native-lights
Version:
A modernised light-weight UI kit for mobile apps.
47 lines (44 loc) • 1.25 kB
JavaScript
import React from 'react';
import {View, TextInput} from 'react-native';
function InputText({
TextInputWidth,
maxLengthValue,
keyboardType,
onChangeText,
placeholderText,
placeholderTextColor,
fontSizeValue,
fontWeightValue,
borderColorValue,
borderWidthValue,
borderBottomColorValue,
borderBottomWidthValue,
autoFocusValue,
Value,
extraStyle,
}) {
return (
<View>
<TextInput
placeholder={placeholderText ? placeholderText : '9999999999'}
placeholderTextColor={
placeholderTextColor ? placeholderTextColor : '#7D7D7D'
}
autoFocus={autoFocusValue ? autoFocusValue : true}
maxLength={maxLengthValue ? maxLengthValue : 10}
keyboardType={keyboardType ? keyboardType : 'numeric'}
onChangeText={onChangeText}
value={Value}
borderBottomColor={borderBottomColorValue}
borderBottomWidth={borderBottomWidthValue}
fontSize={fontSizeValue ? fontSizeValue : 30}
fontWeight={fontWeightValue ? fontWeightValue : 'bold'}
borderColor={borderColorValue}
borderWidth={borderWidthValue}
width={TextInputWidth}
style={extraStyle}
/>
</View>
);
}
export default InputText;