<template>
  <div id="app">
    <router-view></router-view>
  </div>
</template>

<script>
export default {
  name: "App",
  components: {},
  methods: {
    bodyScale() {
      var devicewidth = document.documentElement.clientWidth; //获取当前分辨率下的可是区域宽度
      var scale = devicewidth / 1920; // 分母——设计稿的尺寸
      document.body.style.zoom = scale; //放大缩小相应倍数
      let charts = document.getElementsByClassName("chart-container");
      for (let i = 0; i < charts.length; i++) {
        charts[i].style.zoom = 1;
      }
    },
  },
  mounted() {
    this.$nextTick(() => {
      this.bodyScale();
    });
  },
};
</script>

<style>
* {
  margin: 0;
  padding: 0;
}
#app {
  margin: 0px;
  background: url(assets/background.png) no-repeat;
  background-size: 100% 100%;
  background-attachment: fixed;
  min-height: 100vh;
}
</style>
