This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
nezha-nezha-fronted/nezha-fronted/src/components/common/loading.vue

39 lines
613 B
Vue
Raw Normal View History

<template>
<div v-show="showLoading" style="text-align: center" class="my-loading-box">
<div class="bars1 my-loading">
<span></span>
<span></span>
<span></span>
<span></span>
<span></span>
</div>
</div>
</template>
<script>
export default {
2021-03-19 18:52:19 +08:00
name: 'loading',
props: {
2021-12-02 21:46:07 +08:00
loading: Boolean
},
2021-03-19 18:52:19 +08:00
data () {
return {
2021-03-19 18:52:19 +08:00
showLoading: false
}
},
methods: {
2021-03-19 18:52:19 +08:00
startLoading () {
this.showLoading = true
},
2021-03-19 18:52:19 +08:00
endLoading () {
this.showLoading = false
}
2021-12-02 21:46:07 +08:00
},
watch: {
loading (n) {
this.showLoading = n
}
}
2021-03-19 18:52:19 +08:00
}
</script>