import { Dashboard } from 'icons';
import { useRoutes } from 'react-router-dom';
import { ExploreSpaces } from 'screens/dashboard/explore-spaces';
import { MySpaces } from 'screens/dashboard/my-spaces';
import { UpComing } from 'screens/dashboard/up-coming';

export const Router = () => {
  return useRoutes([
    {
      path: 'dashboard',
      element: <Dashboard />,
      children: [
        {
          path: 'upcoming',
          element: <UpComing />,
        },
        {
          path: 'spaces',
          element: <MySpaces />,
        },
        {
          path: 'explore',
          element: <ExploreSpaces />,
        },
      ],
    },
    {
      path: 'dashboard',
      element: <Dashboard />,
      children: [
        {
          path: 'upcoming',
          element: <UpComing />,
        },
        {
          path: 'spaces',
          element: <MySpaces />,
        },
        {
          path: 'explore',
          element: <ExploreSpaces />,
        },
      ],
    },
  ]);
};
