import { styled } from '@mui/material'
import { Outlet } from 'react-router-dom'
import type { Theme } from '@mui/material'

const MainContainer = styled('main')(({ theme }) => {
  const t = theme as Theme
  return {
    flex: '1 0 auto',
    backgroundColor: t.palette.yacolor.bg[t.palette.mode],
  }
})

const YaMain: React.FC = () => {
  return (
    <MainContainer>
      <Outlet />
    </MainContainer>
  )
}

export default YaMain
