Blame view

src/router/routes/modules/demo/charts.ts 1.46 KB
1
2
import type { AppRouteModule } from '/@/router/types';
vben authored
3
import { getParentLayout, LAYOUT } from '/@/router/constant';
4
import { t } from '/@/hooks/web/useI18n';
5
6
const charts: AppRouteModule = {
vben authored
7
8
9
10
11
  path: '/charts',
  name: 'Charts',
  component: LAYOUT,
  redirect: '/charts/apexChart',
  meta: {
陈小婷 authored
12
    icon: 'vaadin:spline-area-chart',
13
    title: t('routes.demo.charts.charts'),
14
  },
vben authored
15
  children: [
16
    {
17
18
19
20
21
22
23
24
      path: 'apexChart',
      name: 'ApexChart',
      meta: {
        title: t('routes.demo.charts.apexChart'),
      },
      component: () => import('/@/views/demo/echarts/apex/index.vue'),
    },
    {
vben authored
25
      path: 'echarts',
26
      name: 'Echarts',
vben authored
27
      component: getParentLayout('Echarts'),
28
29
30
      meta: {
        title: 'Echarts',
      },
31
      redirect: '/charts/echarts/map',
32
33
34
35
36
37
      children: [
        {
          path: 'map',
          name: 'Map',
          component: () => import('/@/views/demo/echarts/Map.vue'),
          meta: {
38
            title: t('routes.demo.charts.map'),
39
40
41
42
43
44
45
          },
        },
        {
          path: 'line',
          name: 'Line',
          component: () => import('/@/views/demo/echarts/Line.vue'),
          meta: {
46
            title: t('routes.demo.charts.line'),
47
48
49
50
51
52
53
          },
        },
        {
          path: 'pie',
          name: 'Pie',
          component: () => import('/@/views/demo/echarts/Pie.vue'),
          meta: {
54
            title: t('routes.demo.charts.pie'),
55
56
57
58
59
          },
        },
      ],
    },
  ],
60
61
62
};

export default charts;