summaryrefslogtreecommitdiffstats
path: root/webapp/src/components/LoadingBar.vue
diff options
context:
space:
mode:
Diffstat (limited to 'webapp/src/components/LoadingBar.vue')
-rw-r--r--webapp/src/components/LoadingBar.vue21
1 files changed, 12 insertions, 9 deletions
diff --git a/webapp/src/components/LoadingBar.vue b/webapp/src/components/LoadingBar.vue
index 32495ef..342b638 100644
--- a/webapp/src/components/LoadingBar.vue
+++ b/webapp/src/components/LoadingBar.vue
@@ -37,15 +37,18 @@ export default {
}
},
watch: {
- loading (value) {
- clearTimeout(this.loadingTimeout)
- if (value) {
- this.loadingValue = 0
- this.loadingBar = true
- this.loadingTimeout = setTimeout(this.increaseLoadingValue, 10)
- } else {
- this.loadingValue = 100
- this.loadingTimeout = setTimeout(() => { this.loadingBar = false }, 500)
+ loading: {
+ immediate: true,
+ handler (value) {
+ clearTimeout(this.loadingTimeout)
+ if (value) {
+ this.loadingValue = 0
+ this.loadingBar = true
+ this.loadingTimeout = setTimeout(this.increaseLoadingValue, 10)
+ } else {
+ this.loadingValue = 100
+ this.loadingTimeout = setTimeout(() => { this.loadingBar = false }, 500)
+ }
}
}
},