index.vue 685 B

1234567891011121314151617181920212223242526
  1. <template>
  2. <div v-loading="loading" :style="'height:'+ height">
  3. <iframe :src="src" frameborder="no" style="width: 100%;height: 100%" scrolling="auto" />
  4. </div>
  5. </template>
  6. <script>
  7. export default {
  8. name: "Druid",
  9. data() {
  10. return {
  11. src: process.env.VUE_APP_BASE_API + "/druid/index.html",
  12. height: document.documentElement.clientHeight - 94.5 + "px;",
  13. loading: true
  14. };
  15. },
  16. mounted: function() {
  17. setTimeout(() => {
  18. this.loading = false;
  19. }, 230);
  20. const that = this;
  21. window.onresize = function temp() {
  22. that.height = document.documentElement.clientHeight - 94.5 + "px;";
  23. };
  24. }
  25. };
  26. </script>