diff --git a/src/app/components/forms/FormDatePicker.js b/src/app/components/forms/FormDatePicker.js index 95ebf07..a0b0ef4 100644 --- a/src/app/components/forms/FormDatePicker.js +++ b/src/app/components/forms/FormDatePicker.js @@ -94,16 +94,15 @@ const FormDatePicker = (props) => { justifyContent: "space-between", }} > - - - - - - {" "} - {date.format("DD/MM/YYYY")} {"\n"} {time.format("HH:mm")} - - + + + + + {" "} {date.format("DD/MM/YYYY")} {"\n "} {time.format("HH:mm")} + + + {Platform.OS !== "ios" && show && renderDatePicker()} {Platform.OS === "ios" && show && ( @@ -190,19 +189,18 @@ const styles = StyleSheet.create({ justifyContent: "center", }, dateInput: { - flex: 0.91, + flex: 0.80, backgroundColor: colors.white, borderRadius: 25, - padding: 10, marginVertical: 10, }, - dateIcon:{ + dateIcon: { backgroundColor: colors.cerulean, - padding: 10, - width: 20, - alignItems: "center", - borderRadius: 5, - flex: 0.09, + padding: 8, + width: 20, + alignItems: "center", + borderRadius: 5, + flex: 0.20, } }); diff --git a/src/app/components/forms/FormLocationPicker.js b/src/app/components/forms/FormLocationPicker.js new file mode 100644 index 0000000..4345465 --- /dev/null +++ b/src/app/components/forms/FormLocationPicker.js @@ -0,0 +1,56 @@ +import React from "react"; +import { + StyleSheet, + Text, + View, +} from "react-native"; + +import { MaterialIcons } from '@expo/vector-icons'; +import colors from "../../config/colors"; +import { Colors } from "react-native/Libraries/NewAppScreen"; +import { TouchableOpacity } from "react-native-gesture-handler"; + +const FormLocationPicker = (props) => { + return ( + + + + + + + + {""} Endereço {"\n "}... + + + Defina o local no mapa + + + ); + +} + +const styles = StyleSheet.create({ + location: { + flex: 1, + flexDirection: "row", + alignItems: "center", + justifyContent: "space-between", + }, + adressText: { + flex: 0.78, + backgroundColor: colors.white, + borderRadius: 25, + marginVertical: 10, + + }, + mapIcon: { + backgroundColor: colors.cerulean, + padding: 8, + width: 20, + alignItems: "center", + borderRadius: 5, + flex: 0.20, + } +}); + +export default FormLocationPicker; \ No newline at end of file diff --git a/src/app/navigation/SharingDataOptionsNavigator.js b/src/app/navigation/SharingDataOptionsNavigator.js index bce1a67..62de6a3 100644 --- a/src/app/navigation/SharingDataOptionsNavigator.js +++ b/src/app/navigation/SharingDataOptionsNavigator.js @@ -26,7 +26,7 @@ function SharingDataOptionsNavigator() { name="RainSharingData" component={RainSharingDataScreen} options={{ - title: "Enviar uma informação", + title: "Chuva", headerStyle: { backgroundColor: "white", }, @@ -36,7 +36,7 @@ function SharingDataOptionsNavigator() { name="FloodSharingData" component={SharingFloodZonesScreen} options={{ - title: "Enviar uma informação", + title: "Ponto de alagamento", headerStyle: { backgroundColor: "white", }, @@ -46,7 +46,7 @@ function SharingDataOptionsNavigator() { name="PluviometerSharingData" component={PluviometerSharingDataScreen} options={{ - title: "Enviar uma informação", + title: "Pluviômetro", headerStyle: { backgroundColor: "white", }, @@ -56,7 +56,7 @@ function SharingDataOptionsNavigator() { name="RiverFloodData" component={RiverFloodSharingDataScreen} options={{ - title: "Enviar uma informação", + title: "Nível de água no rio", headerStyle: { backgroundColor: "white", }, diff --git a/src/app/screens/PluviometerSharingDataScreen.js b/src/app/screens/PluviometerSharingDataScreen.js index f2e9b28..a7a4903 100644 --- a/src/app/screens/PluviometerSharingDataScreen.js +++ b/src/app/screens/PluviometerSharingDataScreen.js @@ -16,6 +16,7 @@ import { dimensions, scaleDimsFromWidth } from "../config/dimensions"; import FormDatePicker from "../components/forms/FormDatePicker"; import colors from "../config/colors/"; import moment from "moment"; +import FormLocationPicker from "../components/forms/FormLocationPicker"; const dims = scaleDimsFromWidth(85, 85, 25); @@ -72,7 +73,7 @@ function PluviometerSharingDataScreen(props) { }} validationSchema={validationSchema} > - + Quantidade de chuva (mm): - - + + {/*Data da coleta:*/} - setDateTime(value)} - onTimeChange={(value) => setTime(value)} - /> + + setDateTime(value)} + onTimeChange={(value) => setTime(value)} + /> + + {/*Local do evento:*/} + + + + diff --git a/src/app/screens/RainSharingDataScreen.js b/src/app/screens/RainSharingDataScreen.js index 5be50e8..2dc6672 100644 --- a/src/app/screens/RainSharingDataScreen.js +++ b/src/app/screens/RainSharingDataScreen.js @@ -20,6 +20,7 @@ import { scaleDimsFromWidth, dimensions } from "../config/dimensions"; import assets from "../config/assets"; import moment from "moment"; import FormDatePicker from "../components/forms/FormDatePicker"; +import FormLocationPicker from "../components/forms/FormLocationPicker"; const validationSchema = Yup.object().shape({ images: Yup.array(), @@ -161,18 +162,23 @@ function RainSharingDataScreen(props) { - + {/*Data da coleta:*/} - setDateTime(value)} - onTimeChange={(value) => setTime(value)} - /> + + setDateTime(value)} + onTimeChange={(value) => setTime(value)} + /> + + {/*Local do evento:*/} + + + - + {/*Data da coleta:*/} - setDateTime(value)} - onTimeChange={(value) => setTime(value)} - /> + + setDateTime(value)} + onTimeChange={(value) => setTime(value)} + /> + + {/*Local do evento:*/} + + + - - + + {/*Data da coleta:*/} - setDateTime(value)} - onTimeChange={(value) => setTime(value)} - /> + + setDateTime(value)} + onTimeChange={(value) => setTime(value)} + /> + + {/*Local do evento:*/} + + +