import type { RouteRecordRaw } from 'vue-router';

import { $t } from '#/locales';

const routes: RouteRecordRaw[] = [
  {
    meta: {
      icon: 'lucide:users',
      order: 3,
      title: $t('page.student.title'),
    },
    name: 'Student',
    path: '/student',
    redirect: '/student/list',
    children: [
      {
        name: 'StudentList',
        path: 'list',
        component: () => import('#/views/student/list.vue'),
        meta: {
          icon: 'lucide:list',
          title: $t('page.student.list'),
        },
      },
      {
        name: 'StudentDetail',
        path: 'detail/:id?',
        component: () => import('#/views/student/detail.vue'),
        meta: {
          hideInMenu: true,
          title: $t('page.student.detail'),
        },
      },
    ],
  },
];

export default routes;

