import type { AppRouteModule } from '@/router/types';

import { LAYOUT } from '@/router/constant';
<%_ if (enableTranslation) { _%>
import { t } from '@/hooks/web/useI18n';
<%_ } _%>

const dashboard: AppRouteModule = {
  path: '/dashboard',
  name: 'Dashboard',
  component: LAYOUT,
  redirect: '/dashboard/analysis',
  meta: {
    orderNo: 10,
    icon: 'ion:grid-outline',
    title: <% if (enableTranslation) { %>t('routes.dashboard.dashboard')<% } else { %>'t$t('routes.dashboard.dashboard')$t$'<% } %>,
  },
  children: [
    {
      path: 'analysis',
      name: 'Analysis',
      component: () => import('@/views/dashboard/Analysis/index.vue'),
      meta: {
        // affix: true,
        title: <% if (enableTranslation) { %>t('routes.dashboard.analysis')<% } else { %>'t$t('routes.dashboard.analysis')$t$'<% } %>,
      },
    },
    {
      path: 'workbench',
      name: 'Workbench',
      component: () => import('@/views/dashboard/workbench/index.vue'),
      meta: {
        title: <% if (enableTranslation) { %>t('routes.dashboard.workbench')<% } else { %>'t$t('routes.dashboard.workbench')$t$'<% } %>,
      },
    },
  ],
};

export default dashboard;
