import '@/core/http';
import JSONbig from 'json-bigint';
import '@/components/Dialog';
import Vue from 'vue';
import ElementUI from 'element-ui';
// import 'element-ui/lib/theme-chalk/index.css'
import '@/assets/style/index.scss';
import '@/core/mixins/global.js';
import App from './App';
import router from './router';
import store from './store';
import '@/staticDict/gptStaticDict.js';
import {SocketService} from '@/utils/websocket.js';
import TreeSelect from '@/components/TreeSelect';
import RichEditor from '@/components/RichEditor';
import InputNumberRange from '@/components/InputNumberRange';
import DateRange from '@/components/DateRange';
import FilterBox from '@/components/FilterBox';
import TableProgressColumn from '@/components/TableProgressColumn';
import UserSelect from '@/components/UserSelect';
import DeptSelect from '@/components/DeptSelect';
import TableBox from '@/components/TableBox';
import RightAddBtn from '@/components/Btns/RightAddBtn';
import VCharts from 'v-charts';
import VXETable from 'vxe-table';
import resize from '@/core/directive/resize.js';
import 'vxe-table/lib/style.css';
import '@/assets/online-icon/iconfont.css';
import VueClipboard from 'vue-clipboard2'

Vue.prototype.$SocketService = SocketService
Vue.use(VueClipboard)

Vue.directive('resize', resize)
Vue.use(VXETable);
window.JSON = new JSONbig({storeAsString: true});
Vue.component('tree-select', TreeSelect);
Vue.component('rich-editor', RichEditor);
Vue.component('input-number-range', InputNumberRange);
Vue.component('date-range', DateRange);
Vue.component('filter-box', FilterBox);
Vue.component('table-progress-column', TableProgressColumn);
Vue.component('user-select', UserSelect);
Vue.component('dept-select', DeptSelect);
Vue.component('table-box', TableBox);
Vue.component('right-add-btn', RightAddBtn);
var EventBus = new Vue();
Object.defineProperties(Vue.prototype, {
  $bus: {
    get: function () {
      return EventBus
    }
  }
})
Vue.use(ElementUI);
Vue.use(VCharts);

Vue.config.productionTip = false;
/* eslint-disable no-new */
const vm = new Vue({
  router,
  store,
  render: h => h(App)
});
vm.$mount('#app');
Vue.prototype.$vm = vm;
