You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
62 lines
1.3 KiB
62 lines
1.3 KiB
<!--
|
|
* @Author: your name
|
|
* @Date: 2021-10-08 08:41:57
|
|
* @LastEditTime: 2021-10-26 13:03:31
|
|
* @LastEditors: Please set LastEditors
|
|
* @Description: In User Settings Edit
|
|
* @FilePath: /data-show/src/App.vue
|
|
-->
|
|
<template>
|
|
<a-config-provider :locale="locale">
|
|
<div id="app">
|
|
<router-view></router-view>
|
|
</div>
|
|
</a-config-provider>
|
|
</template>
|
|
|
|
<script>
|
|
import zhCN from "ant-design-vue/lib/locale-provider/zh_CN";
|
|
export default {
|
|
name: "App",
|
|
data() {
|
|
return {
|
|
locale: zhCN,
|
|
};
|
|
},
|
|
created() {
|
|
// this.changeZoom()
|
|
},
|
|
methods: {
|
|
changeZoom() {
|
|
let w = window.screen.width;
|
|
let zoom = 1;
|
|
if (1300 < w && w <= 1920) {
|
|
zoom = w / 1928;
|
|
} else if (w < 1300) {
|
|
zoom = 1300 / 1928;
|
|
} else {
|
|
zoom = 1;
|
|
}
|
|
document.body.style.zoom = zoom;
|
|
this.setZoom(zoom);
|
|
},
|
|
},
|
|
};
|
|
</script>
|
|
|
|
<style>
|
|
html,
|
|
body {
|
|
width: 100%;
|
|
height: 100%;
|
|
font-family: "Arial", "Microsoft YaHei", "黑体", "宋体", sans-serif;
|
|
font-size: 62.5%;
|
|
background: #010b19;
|
|
}
|
|
#app {
|
|
width: 100%;
|
|
height: 100%;
|
|
background: #010b19;
|
|
}
|
|
</style>
|