Commit c53b5595 authored by Devin B's avatar Devin B

add_info

parent f7fabe12
......@@ -35,5 +35,10 @@ export default {
SKIN_VIDEO3: 'Skin_Video3',
SKIN_VIDEO4: 'Skin_Video4',
SKIN_VIDEO5: 'Skin_Video5',
SKIN_INFO:'skin_info'
SKIN_INFO:'skin_info',
SKIN_INFO2:'skin_info2',
SKIN_INFO3:'skin_info3',
SKIN_INFO4:'skin_info4',
SKIN_INFO5:'skin_info5',
SKIN_INFO6:'skin_info6'
};
......@@ -10,6 +10,11 @@ import AdditionalSymptoms3 from '../screens/home/skin/AdditionalSymptoms3';
import AdditionalSymptoms4 from '../screens/home/skin/AdditionalSymptoms4';
import AdditionalSymptoms5 from '../screens/home/skin/AdditionalSymptoms5';
import Additionalinformation from '../screens/home/skin/information1';
import Additionalinformation2 from '../screens/home/skin/skininformation2';
import Additionalinformation3 from '../screens/home/skin/skininfromation3';
import Additionalinformation4 from '../screens/home/skin/skininfromation4';
import Additionalinformation5 from '../screens/home/skin/skininformation5';
import Additionalinformation6 from '../screens/home/skin/skininformation6';
import {COLORS, ROUTES} from "../constants"
const Stack = createStackNavigator();
......@@ -30,6 +35,11 @@ function SkinNavigator() {
<Stack.Screen name={ROUTES.SKIN_VIDEO4} component={AdditionalSymptoms4} />
<Stack.Screen name={ROUTES.SKIN_VIDEO5} component={AdditionalSymptoms5} />
<Stack.Screen name={ROUTES.SKIN_INFO} component={Additionalinformation} />
<Stack.Screen name={ROUTES.SKIN_INFO2} component={Additionalinformation2} />
<Stack.Screen name={ROUTES.SKIN_INFO3} component={Additionalinformation3} />
<Stack.Screen name={ROUTES.SKIN_INFO4} component={Additionalinformation4} />
<Stack.Screen name={ROUTES.SKIN_INFO5} component={Additionalinformation5} />
<Stack.Screen name={ROUTES.SKIN_INFO6} component={Additionalinformation6} />
......
......@@ -9,7 +9,7 @@ import { Dimensions } from 'react-native';
import { Linking } from 'react-native';
const AdditionalSymptomsScreen = ({ navigation }) => {
const AdditionalSymptomsScreen2 = ({ navigation }) => {
const [selectedSymptoms, setSelectedSymptoms] = useState({
symptom1: false, symptom2: false, symptom3: false, symptom4: false,
symptom5: false, symptom6: false, symptom7: false, symptom8: false,
......@@ -77,7 +77,7 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
// Navigate based on condition
if (toSkinRisk) {
navigation.navigate(ROUTES.SKIN_RISK);
navigation.navigate(ROUTES.SKIN_RISK, {origin: 'AdditionalSymptomsScreen2' });
} else {
navigation.navigate(ROUTES.SKIN_INFO);
}
......@@ -460,4 +460,4 @@ const styles = StyleSheet.create({
// ... possibly other styles
});
export default AdditionalSymptomsScreen;
export default AdditionalSymptomsScreen2;
......@@ -9,7 +9,7 @@ import { Dimensions } from 'react-native';
import { Linking } from 'react-native';
const AdditionalSymptomsScreen = ({ navigation }) => {
const AdditionalSymptomsScreen1 = ({ navigation }) => {
const [selectedSymptoms, setSelectedSymptoms] = useState({
symptom1: false, symptom2: false, symptom3: false, symptom4: false,
symptom5: false, symptom6: false, symptom7: false, symptom8: false,
......@@ -71,9 +71,9 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
// Navigate based on condition
if (toSkinRisk) {
navigation.navigate(ROUTES.SKIN_RISK);
navigation.navigate(ROUTES.SKIN_RISK, {origin: 'AdditionalSymptomsScreen1' });
} else {
navigation.navigate(ROUTES.SKIN_INFO);
navigation.navigate(ROUTES.SKIN_INFO2);
}
};
......@@ -455,4 +455,4 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
});
export default AdditionalSymptomsScreen;
export default AdditionalSymptomsScreen1;
......@@ -9,7 +9,7 @@ import { Dimensions } from 'react-native';
import { Linking } from 'react-native';
const AdditionalSymptomsScreen = ({ navigation }) => {
const AdditionalSymptomsScreen3 = ({ navigation }) => {
const [selectedSymptoms, setSelectedSymptoms] = useState({
symptom1: false, symptom2: false, symptom3: false, symptom4: false,
symptom5: false, symptom6: false, symptom7: false, symptom8: false,
......@@ -67,7 +67,7 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
// Navigate based on condition
if (toSkinRisk) {
navigation.navigate(ROUTES.SKIN_RISK);
navigation.navigate(ROUTES.SKIN_RISK, {origin: 'AdditionalSymptomsScreen3' });
} else {
navigation.navigate(ROUTES.SKIN_INFO);
}
......@@ -451,4 +451,4 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
});
export default AdditionalSymptomsScreen;
export default AdditionalSymptomsScreen3;
......@@ -9,7 +9,7 @@ import { Dimensions } from 'react-native';
import { Linking } from 'react-native';
const AdditionalSymptomsScreen = ({ navigation }) => {
const AdditionalSymptomsScreen4 = ({ navigation }) => {
const [selectedSymptoms, setSelectedSymptoms] = useState({
symptom1: false, symptom2: false, symptom3: false, symptom4: false,
symptom5: false, symptom6: false, symptom7: false, symptom8: false,
......@@ -62,7 +62,7 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
// Navigate based on condition
if (toSkinRisk) {
navigation.navigate(ROUTES.SKIN_RISK);
navigation.navigate(ROUTES.SKIN_RISK, {origin: 'AdditionalSymptomsScreen4' });
} else {
navigation.navigate(ROUTES.SKIN_INFO);
}
......@@ -445,4 +445,4 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
// ... possibly other styles
});
export default AdditionalSymptomsScreen;
export default AdditionalSymptomsScreen4;
......@@ -9,7 +9,7 @@ import { Dimensions } from 'react-native';
import { Linking } from 'react-native';
const AdditionalSymptomsScreen = ({ navigation }) => {
const AdditionalSymptomsScreen5 = ({ navigation }) => {
const [selectedSymptoms, setSelectedSymptoms] = useState({
symptom1: false, symptom2: false, symptom3: false, symptom4: false,
symptom5: false, symptom6: false, symptom7: false, symptom8: false,
......@@ -155,7 +155,7 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
<Button
title="Continue for more information"
style={styles.nextButton}
onPress={() => navigation.navigate(ROUTES.SKIN_INFO)}
onPress={() => navigation.navigate(ROUTES.SKIN_INFO6)}
/>
</ScrollView>
</SafeAreaView>
......@@ -381,4 +381,4 @@ const styles = StyleSheet.create({
// ... possibly other styles
});
export default AdditionalSymptomsScreen;
export default AdditionalSymptomsScreen5;
......@@ -9,7 +9,7 @@ import { Dimensions } from 'react-native';
import { Linking } from 'react-native';
const AdditionalSymptomsScreen = ({ navigation }) => {
const AdditionalSymptomsScreen6 = ({ navigation }) => {
const [selectedSymptoms, setSelectedSymptoms] = useState({
symptom1: false, symptom2: false, symptom3: false, symptom4: false,
symptom5: false, symptom6: false, symptom7: false, symptom8: false,
......@@ -60,7 +60,7 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
// Navigate based on condition
if (toSkinRisk) {
navigation.navigate(ROUTES.SKIN_RISK);
navigation.navigate(ROUTES.SKIN_RISK, {origin: 'AdditionalSymptomsScreen6' });
} else {
navigation.navigate(ROUTES.SKIN_INFO);
}
......@@ -443,4 +443,4 @@ const AdditionalSymptomsScreen = ({ navigation }) => {
// ... possibly other styles
});
export default AdditionalSymptomsScreen;
export default AdditionalSymptomsScreen6;
......@@ -7,18 +7,14 @@ import Button from '../../../components/Button';
import Video from 'react-native-video';
import { SafeAreaView } from 'react-native-safe-area-context';
const RiskEvaluationScreen = ({ navigation }) => {
const RiskEvaluationScreen = ({ navigation,route }) => {
const { origin } = route.params || {};
const [audioPaused, setAudioPaused] = useState(true);
const [progress, setProgress] = useState(0);
const audioRef = useRef(null);
const progressAnim = useRef(new Animated.Value(0)).current;
// Function to handle the continuation to the next screen
const handleContinue = () => {
// navigation.navigate('NextScreenRoute');
};
useEffect(() => {
if (audioPaused) {
progressAnim.stopAnimation();
......@@ -40,13 +36,33 @@ const RiskEvaluationScreen = ({ navigation }) => {
}
};
const handleContinue = () => {
if (origin === 'AdditionalSymptomsScreen2') {
navigation.navigate(ROUTES.SKIN_INFO);
} else if (origin === 'AdditionalSymptomsScreen1') {
navigation.navigate(ROUTES.SKIN_INFO2);
}
else if (origin === 'AdditionalSymptomsScreen3') {
navigation.navigate(ROUTES.SKIN_INFO3);
}
else if (origin === 'AdditionalSymptomsScreen4') {
navigation.navigate(ROUTES.SKIN_INFO4);
}
else if (origin === 'AdditionalSymptomsScreen6') {
navigation.navigate(ROUTES.SKIN_INFO5);
}
// else {
// navigation.navigate(ROUTES.SKIN_INFO); // Default or fallback screen
// }
};
const URL_link = "https://res.cloudinary.com/dl207ux6g/video/upload/v1716112518/audio/fzkd6v8lnmnsa4onm8sx.mp3";
return (
<SafeAreaView style={styles.container}>
<View style={styles.topContainer}>
<Text style={styles.topicText}>Risk evaluation</Text>
<Text style={styles.topicText}> Evaluated risk</Text>
<Text style={styles.descriptionText}>
Your Condition Risk Level: High,Low will be displayed below
</Text>
......@@ -90,7 +106,7 @@ const RiskEvaluationScreen = ({ navigation }) => {
<Button
title="What should I do next"
style={styles.nextButton}
onPress={() => navigation.navigate(ROUTES.SKIN_INFO)}
onPress={handleContinue}
/>
</View>
</SafeAreaView>
......
......@@ -145,16 +145,7 @@ const Camera = ({ navigation }) => {
style={styles.nextButton}
onPress={handleContinue}
/>
{/* <Button
title="Take your next step"
style={{
marginTop: 12,
width: "90%",
marginTop:43,
marginBottom:83
}}
onPress={() => navigation.navigate(ROUTES.SKIN_RISK)}
/> */}
</View>
</View>
);
......
......@@ -183,7 +183,7 @@ const Additionalinformation = ({ navigation }) => {
</View>
<Button
title="Continue for more information"
title="Not sure ? Diagnose again"
style={styles.nextButton}
onPress={() => navigation.navigate(ROUTES.SKIN_WELCOME)}
/>
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment