<template>
  <router-view :class="[mode]" />
</template>

<script>
import Vue from 'vue';
import config from '@/config/style';
import Layout from '@/layouts/index.vue';
import {UsergroupIcon} from "tdesign-icons-vue";
export default Vue.extend({
  computed: {
    mode() {
      return this.$store.getters['setting/mode'];
    },
  },
  mounted() {
    const newRouteConfig = {
      path: '/user',
      name: 'user',
      component: Layout,
      redirect: '/user/user_index',
      meta: {title: '会员管理123', icon: UsergroupIcon},
    };
    console.log(newRouteConfig);
    this.$router.addRoute(newRouteConfig);
    this.$store.dispatch('setting/changeTheme', { ...config });
  },
});
</script>
<style lang="less">
.t-default-menu .t-menu__item{
  height: 50px;
  font-size: 16px;
}
</style>
