No Description

Drna.js 3.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. import React from "react";
  2. import { View, Text, StyleSheet, TouchableOpacity, TextInput} from "react-native";
  3. import { SelectList } from 'react-native-dropdown-select-list';
  4. const Drna = () => {
  5. const [text, onChangeText] = React.useState(null);
  6. const [number, onChangeNumber] = React.useState(null);
  7. const [selected, setSelected] = React.useState("");
  8. const leyesViolaciones = [
  9. {key:'1', value:'Descarga de águas contaminadas'},
  10. {key:'2', value:'Olores objetables-fuertes'},
  11. {key:'3', value:'Tala y/o poda de árboles'},
  12. {key:'4', value:'Rellenando un bosque'},
  13. {key:'5', value:'Rellenando una quebrada'},
  14. {key:'6', value:'Realizando perforaciones en el suelo'},
  15. {key:'7', value:'Moviendo con maquinaria tierra de un lugar a otro'},
  16. {key:'8', value:'Peces y/o otros organismos muertos'},
  17. {key:'9', value:'Tapando la vegetación'},
  18. {key:'10', value:'Destrucción de humedal'},
  19. {key:'11', value:'Construcción sospechosa'},
  20. {key:'12', value:'Otros (vertederos clandestinos, entre otros)'},
  21. ];
  22. return (
  23. <View>
  24. <Text
  25. style={{
  26. fontSize: 30,
  27. textAlign: "center",
  28. marginTop: "20%"
  29. }}
  30. >Formulario DRNA</Text>
  31. <TextInput
  32. style={styles.input}
  33. value={text}
  34. placeholder="Nombre"
  35. placeholderTextColor={"grey"}
  36. />
  37. <TextInput
  38. style={styles.input}
  39. value={text}
  40. placeholder="Email"
  41. placeholderTextColor={"grey"}
  42. />
  43. <TextInput
  44. style={styles.input}
  45. value={text}
  46. placeholder="Fecha"
  47. placeholderTextColor={"grey"}
  48. />
  49. <SelectList
  50. boxStyles={styles.input}
  51. dropdownStyles={styles.input2}
  52. data={leyesViolaciones}
  53. setSelected={setSelected}
  54. placeholder="Leyes en violacion"
  55. />
  56. <TextInput
  57. style={styles.input}
  58. value={text}
  59. placeholder="Lugar de los hechos"
  60. placeholderTextColor={"grey"}
  61. />
  62. <TextInput
  63. style={styles.input2}
  64. value={text}
  65. placeholder="Descripcion de los hechos"
  66. placeholderTextColor={"grey"}
  67. />
  68. <TouchableOpacity style={styles.button}>
  69. <Text style={styles.text}>Someter</Text>
  70. </TouchableOpacity>
  71. </View>
  72. )
  73. }
  74. export default Drna
  75. const styles = StyleSheet.create({
  76. input: {
  77. height: 40,
  78. margin: 12,
  79. borderWidth: 0.5,
  80. padding: 10,
  81. borderRadius:10
  82. },
  83. input2: {
  84. height: 100,
  85. margin: 12,
  86. borderWidth: 0.5,
  87. padding: 15,
  88. borderRadius:10
  89. },
  90. button: {
  91. width:250,
  92. alignSelf: 'center',
  93. alignItems: 'center',
  94. justifyContent: 'center',
  95. paddingVertical: 12,
  96. paddingHorizontal: 32,
  97. borderRadius: 4,
  98. elevation: 3,
  99. backgroundColor: '#009688',
  100. marginTop: "5%"
  101. },
  102. text: {
  103. fontSize: 16,
  104. lineHeight: 21,
  105. fontWeight: 'bold',
  106. letterSpacing: 0.25,
  107. color: 'white',
  108. }
  109. });