You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

103 lines
2.5 KiB

6 years ago
import { createStackNavigator, createAppContainer } from "react-navigation"
import Splash from "./screens/Splash"
import Banner from "./screens/Banner"
6 years ago
import QuizIndex from "./screens/QuizIndex"
import Quiz from "./screens/Quiz"
import Exam from "./screens/Exam"
import Results from "./screens/Results"
6 years ago
import Recap from "./screens/Recap"
6 years ago
import Info from "./screens/Info"
6 years ago
import Dictionary from "./screens/Dictionary"
6 years ago
import { colors, texts} from "./components/Variables"
const MainStack = createStackNavigator({
Splash: {
screen: Splash,
navigationOptions: ({ navigation }) => ({
header: null,
backgroundColor: colors.yellow,
headerStyle: {
backgroundColor: colors.yellow
}
})
},
6 years ago
Recap: {
screen: Recap,
navigationOptions: ({ navigation }) => ({
header: null,
backgroundColor: colors.yellow,
headerStyle: {
backgroundColor: colors.yellow
}
})
},
Results: {
screen: Results,
navigationOptions: ({ navigation }) => ({
header: null,
backgroundColor: colors.yellow,
headerStyle: {
backgroundColor: colors.yellow
}
})
},
6 years ago
Info: {
screen: Info,
navigationOptions: ({ navigation }) => ({
header: null,
6 years ago
})
},
Dictionary: {
screen: Dictionary,
navigationOptions: ({ navigation }) => ({
header: null,
6 years ago
})
},
Banner: {
screen: Banner,
navigationOptions: ({ navigation }) => ({
header: null,
backgroundColor: colors.yellow,
headerStyle: {
backgroundColor: colors.yellow
}
})
},
QuizIndex: {
screen: QuizIndex,
navigationOptions: ({ navigation }) => ({
6 years ago
headerTitle: texts.quizzes,
headerTintColor: colors.white,
backgroundColor: colors.dark_blue,
headerStyle: {
backgroundColor: colors.dark_blue
6 years ago
}
})
},
Quiz: {
screen: Quiz,
navigationOptions: ({ navigation }) => ({
headerTitle: navigation.getParam("title"),
6 years ago
headerTintColor: colors.white,
headerStyle: {
backgroundColor: navigation.getParam("color"),
borderBottomColor: navigation.getParam("color")
}
})
},
Exam: {
screen: Exam,
navigationOptions: ({ navigation }) => ({
headerTitle: navigation.getParam("title"),
headerTintColor: colors.white,
headerStyle: {
backgroundColor: navigation.getParam("color"),
borderBottomColor: navigation.getParam("color")
}
})
}
6 years ago
})
6 years ago
export default createAppContainer(MainStack)