Blame view

ceres-uniapp-master/components/GlobalLoading/index.vue 1.7 KB
3f535f30   杨鑫   '初始'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
  <template>
    <view class="loading-content" v-if="loadingFlag"  @touchmove.stop.prevent="moveHandle"
                @click.stop.prevent="moveHandle">
      <!-- 遮罩 -->
      <view catchtouchmove="true" class="full-mask" v-if="false"/>
      <!-- loading -->
      <view class="loading-gif">
        <view class="flex mask">
          <image src="@/static/images/loading/loading.gif"></image>
  <!--        <p> {{ loadingInfo }} </p>-->
        </view>
      </view>
    </view>
  </template>
  
  <script>
  import {mapGetters} from 'vuex'
  
  export default {
    name: "GlobalLoading",
    methods: {
      moveHandle() {
        return;
      }
    },
    mounted() {
      console.log("+++++++++++++++++++__++++++++++++++++++++")
      console.log(this.loadingFlag, this.loadingInfo)
    },
    computed: {
      ...mapGetters(["loadingFlag", "loadingInfo"])
    }
  }
  </script>
  
  <style lang="scss" scoped>
  .loading-content {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    //pointer-events: none;
  
    .mask {
      //background-color: rgba(75, 53, 53, 0.52);
    }
  
    .full-mask {
      position: absolute;
      width: 100vw;
      height: 100vh;
      background-color: rgba(0, 0, 0, 0.52);
      z-index: 9998;
      pointer-events: none;
    }
  
    .loading-gif {
      z-index: 9999;
      position: relative;
      width: 100%;
      height: 100%;
  
      .flex {
        width: 200rpx;
        height: 200rpx;
        position: absolute;
        border-radius: 15rpx;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        display: flex;
        align-items: center;
        justify-content: center;
        flex-direction: column;
  
        image {
          width: 150rpx;
          height: 150rpx;
        }
  
        p {
          color: #fff;
        }
      }
    }
  }
  </style>