86 lines
2.0 KiB
TypeScript
86 lines
2.0 KiB
TypeScript
import { createApp } from 'vue';
|
|
// global css
|
|
import 'virtual:uno.css';
|
|
import '@/assets/styles/index.scss';
|
|
import '@/assets/iconfont/iconfont.css';
|
|
import 'element-plus/theme-chalk/dark/css-vars.css';
|
|
|
|
// App、router、store
|
|
import App from './App.vue';
|
|
import store from './store';
|
|
import router from './router';
|
|
|
|
// 自定义指令
|
|
import directive from './directive';
|
|
|
|
// 注册插件
|
|
import plugins from './plugins/index'; // plugins
|
|
|
|
// 高亮组件
|
|
// import 'highlight.js/styles/a11y-light.css';
|
|
import 'highlight.js/styles/atom-one-dark.css';
|
|
import 'highlight.js/lib/common';
|
|
import HighLight from '@highlightjs/vue-plugin';
|
|
|
|
// svg图标
|
|
import 'virtual:svg-icons-register';
|
|
import ElementIcons from '@/plugins/svgicon';
|
|
|
|
//通信
|
|
import mitt from 'mitt';
|
|
|
|
import '@/assets/fonts/fonts.scss';
|
|
|
|
//打印
|
|
import print from 'vue3-print-nb';
|
|
|
|
// permission control
|
|
import './permission';
|
|
|
|
// 国际化
|
|
import i18n from '@/lang/index';
|
|
|
|
// vxeTable
|
|
import VXETable from 'vxe-table';
|
|
import 'vxe-table/lib/style.css';
|
|
VXETable.config({
|
|
zIndex: 999999
|
|
});
|
|
|
|
//本地保存飞机配置
|
|
import { setLocal } from './utils';
|
|
setLocal('dockAir', 'http://58.17.134.85:9512');
|
|
setLocal('aiUrl', 'http://58.17.134.85:9512');
|
|
setLocal('host', '121.37.237.116');
|
|
setLocal('rtmpPort', '28451');
|
|
setLocal('rtcPort', '28453');
|
|
setLocal('dockSocketUrl', 'ws://58.17.134.85:9512/websocket');
|
|
|
|
// 修改 el-dialog 默认点击遮照为不关闭
|
|
/*import { ElDialog } from 'element-plus';
|
|
ElDialog.props.closeOnClickModal.default = false;*/
|
|
// **main.js**
|
|
import { vue3ScrollSeamless } from 'vue3-scroll-seamless';
|
|
import bus from './utils/bus';
|
|
import $message from '@/plugins/modal';
|
|
|
|
const app = createApp(App);
|
|
|
|
app.use(HighLight);
|
|
app.use(ElementIcons);
|
|
app.use(router);
|
|
app.use(store);
|
|
app.use(print);
|
|
app.use(i18n);
|
|
app.use(VXETable);
|
|
app.use(plugins);
|
|
app.use(bus);
|
|
app.component('vue3ScrollSeamless', vue3ScrollSeamless);
|
|
// 自定义指令
|
|
directive(app);
|
|
|
|
app.mount('#app');
|
|
|
|
app.config.globalProperties.mittBus = mitt();
|
|
app.config.globalProperties.$message = $message;
|