package com.example.mystictale.navigation

import android.os.Build
import androidx.annotation.RequiresApi
import androidx.compose.runtime.Composable
import androidx.navigation.compose.NavHost
import androidx.navigation.compose.composable
import androidx.navigation.compose.rememberNavController
import com.example.mystictale.Screen.registration.RegistrationDateOfBirth
import com.example.mystictale.Screen.registration.RegistrationEmail
import com.example.mystictale.Screen.registration.RegistrationGender
import com.example.mystictale.Screen.registration.RegistrationName
import com.example.mystictale.Screen.registration.RegistrationPassword
import com.example.mystictale.Screen.Start
import com.example.mystictale.Screen.passwordRecovery.PasswordRecovery
import com.example.mystictale.Screen.signIn.SignIn

@RequiresApi(Build.VERSION_CODES.O)
@Composable
fun Navigation() {
    val navController = rememberNavController()
    NavHost(navController = navController, startDestination = Screens.Start.route)
    {
        composable(Screens.Start.route)
        {
            Start(navController)
        }
        composable(Screens.RegistrationEmail.route)
        {
            RegistrationEmail(navController)
        }
        composable(Screens.RegistrationName.route)
        {
            RegistrationName(navController)
        }
        composable(Screens.RegistrationPassword.route)
        {
            RegistrationPassword(navController)
        }
        composable(Screens.RegistrationDateOfBirth.route)
        {
            RegistrationDateOfBirth(navController)
        }
        composable(Screens.RegistrationGender.route)
        {
            RegistrationGender(navController)
        }
        composable(Screens.SingIn.route)
        {
            SignIn(navController)
        }
        composable(Screens.PasswordRecovery.route)
        {
            PasswordRecovery(navController)
        }

    }
}