import { createApp } from "vue";
import App from "./App.vue";
import router from "./router/index";
import store from "./store/index";
//import dataV from '@jiaminghi/data-view';//引入dataV可能如果启动报错看这个https://blog.csdn.net/qq_54753561/article/details/125583526
import echarts from "./components/echarts"; //echarts 根据官网封装的
import DataVVue3 from "@kjgl77/datav-vue3"; //https://datav-vue3.netlify.app/Guide/index.html#%E4%BD%BF%E7%94%A8%E6%96%B9%E6%B3%95
import * as XEUtils from "xe-utils";
import ElementPlus from "element-plus";
import "element-plus/dist/index.css";
import zhCn from "element-plus/es/locale/lang/zh-cn";
// 引入全局css
import "./assets/scss/style.scss";
// 引入图表（所有图标见 icon 目录下的 demo_index.html）
import "./assets/icon/iconfont.css";
import BaiduMap from "vue-baidu-map-3x";
import BaiduMapOffline from "vue-baidu-map-offline";
(window as any).XEUtils = XEUtils;
const app = createApp(App);
app.use(BaiduMapOffline, {
  offline: true,
  offlineConfig: {
    imgext: ".png",
    customstyle: "",
    tiles_dir: "",
    tiles_hybrid: "",
    tiles_self: "",
    tiles_v_dir: "",
    tiles_satellite_dir: "",
    tiles_road_dir: "",
    tiles_v_road_dir: "",
    home: "./plugin/offline/",
  },
});
app.use(BaiduMap, {
  // ak: 'Yp57V71dkOPiXjiN8VdcFRsVELzlVNKK',
  ak: "RpQi6WNFZ9tseKzhdwOQsXwFsoVntnsN",
  v: "3.0",
});
app.config.globalProperties.$echarts = echarts;
app.use(DataVVue3);
app.use(ElementPlus, {
  locale: zhCn,
});
app.use(store).use(router).mount("#app");
