import { type RouteRecordRaw } from 'vue-router'

export default [
  {
    path: '/personal-space',
    name: 'PersonalSpace',
    meta: {
      rank: 1001,
      title: '个人空间',
      icon: 'mingcute:user-2-line',
      belong: 'personal-space',
    },
    component: () => import('@/layout/index.vue'),
    redirect: '/personalSpaceLayout',
    children: [
      {
        path: '/personalSpaceLayout',
        name: 'PersonalSpaceLayout',
        meta: {
          rank: 1001,
          title: '个人空间',
          belong: 'PersonalSpace',
        },
        component: () => import('@/views/personal-space/personal-space.vue'),
        redirect: '/personalSpace/app',
        children: [
          {
            path: '/personalSpace/app',
            name: 'PersonalSpaceApp',
            meta: {
              rank: 1001,
              title: 'Agent应用',
              belong: 'PersonalSpace',
            },
            component: () => import('@/views/personal-space/personal-app/personal-app.vue'),
          },
        ],
      },
    ],
  },
  {
    path: '/personal-app-setting/:agentId?/:tabKey?',
    name: 'PersonalAppSetting',
    meta: {
      rank: 1001,
      title: '应用设置',
      icon: 'mingcute:user-2-line',
      belong: 'PersonalAppSetting',
      hideSideMenItem: true,
    },
    component: () => import('@/views/personal-space/personal-app-setting/personal-app-setting.vue'),
  },
] as RouteRecordRaw[]
