import React from "react";
import { createRoot } from "react-dom/client";
import {
    BrowserRouter,
    Routes,
    Route,
  } from "react-router-dom";

import App from "./App";
import Home from "./Home";
import Registrations from "./Registrations";
import Connections from "./Connections";
import Connection from "./Connection";
import Patient from "./Patient";

const container = document.getElementById("root");
const root = createRoot(container);

root.render(<BrowserRouter basename="/ui">
    <Routes>
      <Route path="/" element={<App />}>
        <Route index element={<Home />} />
        <Route path="/registraties" element={<Registrations />}/>
        <Route path="/connecties" element={<Connections />}/>
        <Route path="/connecties/:connId/:serviceId" element={<Connection />}/>
        <Route path="/connecties/:connId/:serviceId/:patientId" element={<Patient />}/>
        {/* <Route path="teams" element={<Teams />}>
          <Route path=":teamId" element={<Team />} />
          <Route path="new" element={<NewTeamForm />} />
          <Route index element={<LeagueStandings />} />
        </Route> */}
      </Route>
    </Routes>
  </BrowserRouter>);