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

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

const routes: RouteRecordRaw[] = [
  {
    name: 'JumpToEnterprise',
    path: '/jumpToEnterprise',
    component: () => import('#/views/external/jump-to-enterprise.vue'),
    meta: {
      hideInMenu: true,
      hideInTab: true,
      title: $t('dashboard.jumpToEnterprise'),
    },
  },
  {
    component: LayoutA,
    meta: {
      icon: 'lucide:layout-dashboard',
      order: -1,
      title: $t('dashboard.title'),
    },
    name: 'Dashboard',
    path: '/',
    children: [
      {
        name: 'Home',
        path: '/home',
        component: () => import('#/views/dashboard/home/index.vue'),
        meta: {
          icon: 'carbon:workspace',
          title: $t('dashboard.home'),
        },
      },
      {
        name: 'ApplicationManagement',
        path: '/application-management',
        component: () =>
          import('#/views/dashboard/application-management/index.vue'),
        meta: {
          icon: 'carbon:application',
          title: $t('homeModule.applicationManagement'),
        },
      },
      {
        name: 'SalesPartners',
        path: '/sales-partners',
        component: () => import('#/views/dashboard/sales-partners/index.vue'),
        meta: {
          icon: 'carbon:user-multiple',
          title: $t('homeModule.salesPartners'),
        },
      },
      {
        name: 'DeliveryPartners',
        path: '/delivery-partners',
        component: () =>
          import('#/views/dashboard/delivery-partners/index.vue'),
        meta: {
          icon: 'carbon:truck',
          title: $t('homeModule.deliveryPartners'),
        },
      },
      {
        name: 'EnterpriseCustomers',
        path: '/enterprise-customers',
        component: () =>
          import('#/views/dashboard/enterprise-customers/index.vue'),
        meta: {
          icon: 'carbon:building',
          title: $t('homeModule.enterpriseCustomers'),
        },
      },
    ],
  },
];

export default routes;
