|
@ -37,6 +37,8 @@ function RainSharingDataScreen(props) { |
|
|
const [date, setDate] = useState(moment()); |
|
|
const [date, setDate] = useState(moment()); |
|
|
const [time, setTime] = useState(moment()); |
|
|
const [time, setTime] = useState(moment()); |
|
|
|
|
|
|
|
|
|
|
|
const dims = scaleDimsFromWidth(85, 85, 27); |
|
|
|
|
|
|
|
|
return ( |
|
|
return ( |
|
|
<Screen style={styles.container}> |
|
|
<Screen style={styles.container}> |
|
|
<Text |
|
|
<Text |
|
@ -66,7 +68,7 @@ function RainSharingDataScreen(props) { |
|
|
duration: 1950, |
|
|
duration: 1950, |
|
|
icon: "success", |
|
|
icon: "success", |
|
|
type: "success", |
|
|
type: "success", |
|
|
onPress: () => { }, |
|
|
|
|
|
|
|
|
onPress: () => {}, |
|
|
}); |
|
|
}); |
|
|
props.navigation.navigate("Home"); |
|
|
props.navigation.navigate("Home"); |
|
|
}} |
|
|
}} |
|
@ -79,11 +81,7 @@ function RainSharingDataScreen(props) { |
|
|
borderColor={rain == 0 ? colors.primary : colors.white} |
|
|
borderColor={rain == 0 ? colors.primary : colors.white} |
|
|
style={styles.img_block} |
|
|
style={styles.img_block} |
|
|
> |
|
|
> |
|
|
<Image |
|
|
|
|
|
style={styles.floodingLogo} |
|
|
|
|
|
source={assets.rainLevel.rain_0_5} |
|
|
|
|
|
/> |
|
|
|
|
|
<Text style={styles.text}>Sem chuva</Text> |
|
|
|
|
|
|
|
|
<assets.rainLevel.Rain_0_5 {...dims} /> |
|
|
</View> |
|
|
</View> |
|
|
</TouchableNativeFeedback> |
|
|
</TouchableNativeFeedback> |
|
|
|
|
|
|
|
@ -92,11 +90,7 @@ function RainSharingDataScreen(props) { |
|
|
borderColor={rain == 1 ? colors.primary : colors.white} |
|
|
borderColor={rain == 1 ? colors.primary : colors.white} |
|
|
style={styles.img_block} |
|
|
style={styles.img_block} |
|
|
> |
|
|
> |
|
|
<Image |
|
|
|
|
|
style={styles.floodingLogo} |
|
|
|
|
|
source={assets.rainLevel.rain_1_5} |
|
|
|
|
|
/> |
|
|
|
|
|
<Text style={styles.text}>Chuva fraca</Text> |
|
|
|
|
|
|
|
|
<assets.rainLevel.Rain_1_5 {...dims} /> |
|
|
</View> |
|
|
</View> |
|
|
</TouchableNativeFeedback> |
|
|
</TouchableNativeFeedback> |
|
|
|
|
|
|
|
@ -105,26 +99,18 @@ function RainSharingDataScreen(props) { |
|
|
borderColor={rain == 2 ? colors.primary : colors.white} |
|
|
borderColor={rain == 2 ? colors.primary : colors.white} |
|
|
style={styles.img_block} |
|
|
style={styles.img_block} |
|
|
> |
|
|
> |
|
|
<Image |
|
|
|
|
|
style={styles.floodingLogo} |
|
|
|
|
|
source={assets.rainLevel.rain_2_5} |
|
|
|
|
|
/> |
|
|
|
|
|
<Text style={styles.text}>Chuva moderada</Text> |
|
|
|
|
|
|
|
|
<assets.rainLevel.Rain_2_5 {...dims} /> |
|
|
</View> |
|
|
</View> |
|
|
</TouchableNativeFeedback> |
|
|
</TouchableNativeFeedback> |
|
|
</View> |
|
|
</View> |
|
|
|
|
|
|
|
|
<View style={styles.imgs_row}> |
|
|
|
|
|
|
|
|
<View flexDirection="row" justifyContent="center"> |
|
|
<TouchableNativeFeedback onPress={() => setRain(3)}> |
|
|
<TouchableNativeFeedback onPress={() => setRain(3)}> |
|
|
<View |
|
|
<View |
|
|
borderColor={rain == 3 ? colors.primary : colors.white} |
|
|
borderColor={rain == 3 ? colors.primary : colors.white} |
|
|
style={styles.img_block} |
|
|
style={styles.img_block} |
|
|
> |
|
|
> |
|
|
<Image |
|
|
|
|
|
style={styles.floodingLogo} |
|
|
|
|
|
source={assets.rainLevel.rain_3_5} |
|
|
|
|
|
/> |
|
|
|
|
|
<Text style={styles.text}>Chuva forte</Text> |
|
|
|
|
|
|
|
|
<assets.rainLevel.Rain_3_5 {...dims} /> |
|
|
</View> |
|
|
</View> |
|
|
</TouchableNativeFeedback> |
|
|
</TouchableNativeFeedback> |
|
|
|
|
|
|
|
@ -133,15 +119,11 @@ function RainSharingDataScreen(props) { |
|
|
borderColor={rain == 4 ? colors.primary : colors.white} |
|
|
borderColor={rain == 4 ? colors.primary : colors.white} |
|
|
style={styles.img_block} |
|
|
style={styles.img_block} |
|
|
> |
|
|
> |
|
|
<Image |
|
|
|
|
|
style={styles.floodingLogo} |
|
|
|
|
|
source={assets.rainLevel.rain_4_5} |
|
|
|
|
|
/> |
|
|
|
|
|
<Text style={styles.text}>Chuva muito forte</Text> |
|
|
|
|
|
|
|
|
<assets.rainLevel.Rain_4_5 {...dims} /> |
|
|
</View> |
|
|
</View> |
|
|
</TouchableNativeFeedback> |
|
|
</TouchableNativeFeedback> |
|
|
|
|
|
|
|
|
<TouchableNativeFeedback onPress={() => setRain(5)}> |
|
|
|
|
|
|
|
|
{/*<TouchableNativeFeedback onPress={() => setRain(5)}> |
|
|
<View |
|
|
<View |
|
|
borderColor={rain == 5 ? colors.primary : colors.white} |
|
|
borderColor={rain == 5 ? colors.primary : colors.white} |
|
|
style={styles.img_block} |
|
|
style={styles.img_block} |
|
@ -152,7 +134,7 @@ function RainSharingDataScreen(props) { |
|
|
/> |
|
|
/> |
|
|
<Text style={styles.text}>Pancada de chuva</Text> |
|
|
<Text style={styles.text}>Pancada de chuva</Text> |
|
|
</View> |
|
|
</View> |
|
|
</TouchableNativeFeedback> |
|
|
|
|
|
|
|
|
</TouchableNativeFeedback>*/} |
|
|
</View> |
|
|
</View> |
|
|
</View> |
|
|
</View> |
|
|
|
|
|
|
|
@ -162,9 +144,21 @@ function RainSharingDataScreen(props) { |
|
|
|
|
|
|
|
|
<FormImagePicker backgroundColor={colors.primary} name="images" /> |
|
|
<FormImagePicker backgroundColor={colors.primary} name="images" /> |
|
|
|
|
|
|
|
|
<View style={{ flex: 1, flexDirection: "row", justifyContent: "space-between" }}> |
|
|
|
|
|
|
|
|
<View |
|
|
|
|
|
style={{ |
|
|
|
|
|
flex: 1, |
|
|
|
|
|
flexDirection: "row", |
|
|
|
|
|
justifyContent: "space-between", |
|
|
|
|
|
}} |
|
|
|
|
|
> |
|
|
{/*Data da coleta:*/} |
|
|
{/*Data da coleta:*/} |
|
|
<View style={{ flex: 0.48, borderRightColor: colors.cerulean, borderRightWidth: 1 }}> |
|
|
|
|
|
|
|
|
<View |
|
|
|
|
|
style={{ |
|
|
|
|
|
flex: 0.48, |
|
|
|
|
|
borderRightColor: colors.primary, |
|
|
|
|
|
borderRightWidth: 1, |
|
|
|
|
|
}} |
|
|
|
|
|
> |
|
|
<FormDatePicker |
|
|
<FormDatePicker |
|
|
textStyle={{ |
|
|
textStyle={{ |
|
|
borderColor: colors.gray, |
|
|
borderColor: colors.gray, |
|
@ -177,7 +171,9 @@ function RainSharingDataScreen(props) { |
|
|
</View> |
|
|
</View> |
|
|
{/*Local do evento:*/} |
|
|
{/*Local do evento:*/} |
|
|
<View style={{ flex: 0.48 }}> |
|
|
<View style={{ flex: 0.48 }}> |
|
|
<TouchableOpacity onPress={() => props.navigation.navigate("FormMap")}> |
|
|
|
|
|
|
|
|
<TouchableOpacity |
|
|
|
|
|
onPress={() => props.navigation.navigate("FormMap")} |
|
|
|
|
|
> |
|
|
<FormLocationPicker /> |
|
|
<FormLocationPicker /> |
|
|
</TouchableOpacity> |
|
|
</TouchableOpacity> |
|
|
</View> |
|
|
</View> |
|
@ -197,8 +193,6 @@ function RainSharingDataScreen(props) { |
|
|
); |
|
|
); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
const dims = scaleDimsFromWidth(85, 85, 27); |
|
|
|
|
|
|
|
|
|
|
|
const styles = StyleSheet.create({ |
|
|
const styles = StyleSheet.create({ |
|
|
container: { |
|
|
container: { |
|
|
padding: 10, |
|
|
padding: 10, |
|
@ -207,26 +201,16 @@ const styles = StyleSheet.create({ |
|
|
img_block: { |
|
|
img_block: { |
|
|
flex: 1, |
|
|
flex: 1, |
|
|
borderRadius: 5, |
|
|
borderRadius: 5, |
|
|
padding: 10, |
|
|
|
|
|
borderStyle: "dotted", |
|
|
borderStyle: "dotted", |
|
|
borderColor: colors.white, |
|
|
borderColor: colors.white, |
|
|
borderWidth: borderWidth, |
|
|
borderWidth: borderWidth, |
|
|
alignItems: "center", |
|
|
alignItems: "center", |
|
|
width: dims.width, |
|
|
|
|
|
}, |
|
|
|
|
|
floodingLogo: { |
|
|
|
|
|
width: dims.width * 0.8, |
|
|
|
|
|
height: dims.height * 0.8, |
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
imgs_row: { |
|
|
imgs_row: { |
|
|
flexDirection: "row", |
|
|
flexDirection: "row", |
|
|
justifyContent: "space-between", |
|
|
justifyContent: "space-between", |
|
|
}, |
|
|
}, |
|
|
text: { |
|
|
|
|
|
fontSize: dimensions.text.default, |
|
|
|
|
|
textAlign: "center", |
|
|
|
|
|
marginTop: 10, |
|
|
|
|
|
}, |
|
|
|
|
|
error_txt: { |
|
|
error_txt: { |
|
|
fontSize: dimensions.text.default, |
|
|
fontSize: dimensions.text.default, |
|
|
color: colors.danger, |
|
|
color: colors.danger, |
|
|