import type { RouteConfig } from '@react-router/dev/routes';

import { index, route, layout, prefix } from '@react-router/dev/routes';

export default [
  layout('./routes/login/layout.tsx', [
    route('login', './routes/login/page.tsx'),
  ]),
  layout('./routes/layout.tsx', [
    index('./routes/page.tsx'),
    ...prefix('imagery', [
      ...prefix('aerial', [
        index('./routes/imagery/aerial/page.tsx'),
        route(':aerialId', './routes/imagery/aerial/[id]/page.tsx'),
      ]),
      ...prefix('satellite', [
        index('./routes/imagery/satellite/page.tsx'),
        route(':satelliteId', './routes/imagery/satellite/[id]/page.tsx'),
      ]),
      ...prefix('drone', [
        index('./routes/imagery/drone/page.tsx'),
        route(':droneId', './routes/imagery/drone/[id]/page.tsx'),
      ]),
    ]),
    ...prefix('inference', [
      index('./routes/inference/page.tsx'),
      route(':inferenceId', './routes/inference/[id]/page.tsx'),
    ]),
    ...prefix('model', [
      index('./routes/model/page.tsx'),
      route(':modelId', './routes/model/[id]/page.tsx'),
    ]),
    ...prefix('labeling', [
      route('label', './routes/labeling/label/page.tsx'),
      route('review', './routes/labeling/review/page.tsx'),
    ]),
    ...prefix('log', [
      route('audit', './routes/log/audit/page.tsx'),
      route('system', './routes/log/system/page.tsx'),
    ]),
    ...prefix('schedule', [
      index('./routes/schedule/page.tsx'),
    ]),
    route('code', './routes/code/page.tsx'),
    route('hyper-parameter', './routes/hyper-parameter/page.tsx'),
    route('user', './routes/user/page.tsx'),
  ]),

  route('*', './routes/catch-all.tsx'),
] satisfies RouteConfig;
