import { useState } from 'react' import { useLocation } from 'react-router' import { Box, Tab, Tabs, Typography } from '@mui/material' import { ActiveInquiriesTab, LatentInquiriesTab, OfferWizard } from '../../components/anfragencenter' import { useSessionStore } from '../../stores/sessionStore' export default function Anfragencenter() { const location = useLocation() const initialTab = (location.state as { tab?: number } | null)?.tab ?? 0 const [tab, setTab] = useState(initialTab) const orgId = useSessionStore(s => s.currentUser?.organizationId) return ( Anfragencenter setTab(v)} sx={{ '& .MuiTab-root': { textTransform: 'none', fontWeight: 600, fontSize: '0.95rem' }, }} > {tab === 0 && } {tab === 1 && ( )} {tab === 2 && } ) }