2018-12-17 05:51:52 +00:00
|
|
|
<template lang='pug'>
|
|
|
|
v-dialog(v-model='value', persistent, max-width='350')
|
|
|
|
v-card.loader-dialog.radius-7(:color='color', dark)
|
|
|
|
v-card-text.text-xs-center.py-4
|
|
|
|
atom-spinner.is-inline(
|
2018-12-24 06:03:10 +00:00
|
|
|
v-if='mode === `loading`'
|
2018-12-17 05:51:52 +00:00
|
|
|
:animation-duration='1000'
|
|
|
|
:size='60'
|
|
|
|
color='#FFF'
|
|
|
|
)
|
2018-12-24 06:03:10 +00:00
|
|
|
img(v-else-if='mode === `icon`', :src='`/svg/icon-` + icon + `.svg`', :alt='icon')
|
2018-12-17 05:51:52 +00:00
|
|
|
.subheading {{ title }}
|
|
|
|
.caption {{ subtitle }}
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
import { AtomSpinner } from 'epic-spinners'
|
|
|
|
|
|
|
|
export default {
|
|
|
|
components: {
|
|
|
|
AtomSpinner
|
|
|
|
},
|
|
|
|
props: {
|
|
|
|
value: {
|
|
|
|
type: Boolean,
|
|
|
|
default: false
|
|
|
|
},
|
|
|
|
color: {
|
|
|
|
type: String,
|
|
|
|
default: 'blue darken-3'
|
|
|
|
},
|
|
|
|
title: {
|
|
|
|
type: String,
|
|
|
|
default: 'Working...'
|
|
|
|
},
|
|
|
|
subtitle: {
|
|
|
|
type: String,
|
|
|
|
default: 'Please wait'
|
2018-12-24 06:03:10 +00:00
|
|
|
},
|
|
|
|
mode: {
|
|
|
|
type: String,
|
|
|
|
default: 'loading'
|
|
|
|
},
|
|
|
|
icon: {
|
|
|
|
type: String,
|
|
|
|
default: 'checkmark'
|
2018-12-17 05:51:52 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style lang='scss'>
|
|
|
|
.loader-dialog {
|
2018-12-24 22:38:34 +00:00
|
|
|
transition: all .4s ease;
|
|
|
|
|
2018-12-17 05:51:52 +00:00
|
|
|
.atom-spinner.is-inline {
|
|
|
|
display: inline-block;
|
|
|
|
}
|
|
|
|
.caption {
|
|
|
|
color: rgba(255,255,255,.7);
|
|
|
|
}
|
2018-12-24 06:03:10 +00:00
|
|
|
|
|
|
|
img {
|
|
|
|
width: 80px;
|
|
|
|
}
|
2018-12-17 05:51:52 +00:00
|
|
|
}
|
|
|
|
</style>
|