import { ShowProvider } from "@/contexts/ShowContext";
import { SeasonProvider } from "@/contexts/SeasonContext";
import { StreamingServiceProvider } from "@/contexts/StreamingServiceContext";
import { PersonProvider } from "@/contexts/PersonContext";
import { DiscoveryProvider } from "@/contexts/DiscoveryContext";
import { Stack } from "expo-router";
import "react-native-reanimated";

export default function RootLayout() {
  return (
    <ShowProvider>
      <SeasonProvider>
        <StreamingServiceProvider>
          <PersonProvider>
            <DiscoveryProvider>
              <Stack>
                <Stack.Screen name="(tabs)" options={{ headerShown: false }} />
                <Stack.Screen
                  name="showDetails"
                  options={{
                    headerShown: false,
                  }}
                />
                <Stack.Screen
                  name="participant"
                  options={{
                    presentation: "fullScreenModal",
                    headerShown: false,
                  }}
                />
              </Stack>
            </DiscoveryProvider>
          </PersonProvider>
        </StreamingServiceProvider>
      </SeasonProvider>
    </ShowProvider>
  );
}
