import { Navigate, Route, Routes } from 'react-router-dom';
import { List } from './edit/List';
import { Main } from './layouts';
import { App as FlowApp } from './flow';
import { Deck } from './deck';
import { App as PanelApp } from './app';

export const App = () => {
  return (
    <Routes>
      <Route element={<Main />}>
        <Route path='/' element={<Navigate to='/panel/edit/list' />}></Route>
        <Route path='edit/list' element={<List />} />
        <Route path='flow/:id' element={<FlowApp />} />
        <Route path='deck/:id' element={<Deck />} />
        <Route path='app/:id' element={<PanelApp />} />
        <Route path='*' element={'Not Found'}></Route>
      </Route>
    </Routes>
  );
};
