123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- import React from 'react';
- import {View , Text, TextInput,StyleSheet , Button} from 'react-native';
- //Inputs Structure For Library
- /*
- const Inp = [
- {
- textContentType :"username",
- placeholder:"username"
- },
- {
- textContentType :"password",
- placeholder:"password"
- }]
- */
- export default class FormEditor extends React.Component {
- constructor(props){
- super(props)
- }
- addInput(e){
- console.log("Will add Input")
- }
- render(){
- let inputs = this.props.value.map((item) => {
- return (
- <View key= {Math.random()}>
-
- <TextInput
- style={styles.defaultInput}
- onChangeText={(text) => {
- props.onChange && props.onChange(text);
- }}
- placeholder={item.placeholder}
- />
- </View>
- )
- })
- return(
- <View styles={{height:100,width:100}}>
- <Text>Missing Functionality on Form </Text>
-
- {/*<Button
- onPress = {(e) => this.addInput(e)}
- title={"Add"}
- />*/}
- </View>
- )
- }
-
- }
- const styles = StyleSheet.create({
- container:{
- padding:10
- },
- defaultInput: {
- marginTop:6,
- borderWidth:1,
- width:200
- }
- })
|