'use client'; import { Game, GameGroup } from "@/types/stellaris"; import { Dropdown } from "@nextui-org/react"; import { Dispatch, Key, SetStateAction, Suspense, useState } from 'react'; import { fetchGameGroups } from "@/components/server/fetchers"; import { GameInfoHandler } from "./data-handlers/game-info-handler"; type SelectionType = "all" | Set; export const GameInfoTabs = ( props: { game: Game, groups: GameGroup[] }) => { const [currentTab, setCurrentTab] = useState(1); let currentTabView; switch(currentTab) { case(1): case(2): { currentTabView =

{currentTab}

break; } case(3): { currentTabView = break; } default: currentTabView =

Oops, something went wrong

} return ( <>
{currentTabView} ) } const GameInfoLegacyView = ( props: { game: Game, groups: GameGroup[] } ) => { return (

Legacy View for {props.groups.length > 1 ? "Groups" : "Group"} {props.groups.map(elem => elem.name).join(", ")}

) }