<template>
  <div class="loading" :style="styleloading"></div>
</template>

<script>
  export default {
    name: 'Loading', // 定义的组件名称 使用时写法：loading
    props: {
      backurl: String,
    },
    data(){
      return{
        styleloading:''
      }
    },
    watch:{
      'backurl':{
        handler(){
          this.styleloading="background: url("+this.backurl+") center center no-repeat;background-size: 10%;background-color: rgba(0, 0, 0, 0.5);"
          console.log(this.styleloading,'asdasss')
        },
        immediate:true
      }
    }
  }
</script>

<style scoped>
  .loading {
    position: fixed;
    left: 0;
    top: 0;
    /*background: url('../../../static/ManageHomePic/加载数据1.gif') center center no-repeat;*/
    /*background: url('../../../static/NewManageHome/加载.gif') center center no-repeat;*/
    width: 100vw;
    height: 100vh;
    z-index: 1000;
  }
</style>
