0.0.1 • Published 4 years ago
lidemo2 v0.0.1
This Component is from Lisec Mobile team for Demo purpose
lipicker is a simple digital signature component with basic properties. (Props and it's Usage will soon be updated).
Installation
npm install --save lipicker
Usage
import LiPicker from 'lipciker';
class LiPickerDemo extends Component {
constructor(props) {
super(props);
this.state = {
pickerVal: '',
pickervalArr: ['one', 'two', 'three', 'four', 'five', 'six']
}
}
liPickerChange(val,id) {
console.log(val,id, 'CHANGED VALUE and ID');
this.setstate({pickerVal:val});
}
render() {
return (
<View style={flex: 1, alignItems: 'center',}>
<Text>LiPickerDemo</Text>
<LiPicker
pickerId='P1'
liPickerChange={(val, id) => this.liPickerChange(val,id)} // callback for onChange
mode='dropdown' // optional
selectedValue={this.state.pickerval} // Currently selected item
liPickerItem={this.state.pickervalArr} // Your array list
title='Picker-title' // Your label for the Picker/combo-box
disabled = {false} // false by default
size={'small'} /> // optional
</View>
);
}
}
0.0.1
4 years ago