You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
willaengine/resources/js/Global/components/Modals/BasicModal.vue

39 lines
1004 B

<template>
<v-dialog v-model="modal" :width="width" :transition="transition">
<component v-if="modal" :is="name" />
</v-dialog>
</template>
<script>
import {mapGetters} from "vuex";
export default {
props: {
width:{default: '60%'},
name:{default: ''},
transition:{default: 'slide-x-transition'},
},
data:() => ({
}),
components:{
'modal_task_list': () => '@Common/components/Task/Timeline/Modal-Layout.vue',
'modal_task_add': () => '@Common/components/Task/AddEdit/Modal-Add.vue'
},
computed: {
...mapGetters("modal", ["isModalStack"]),
modal: {
get() {
return this.isModalStack(this.name);
},
set(value) {
if (!value) {
this.$_closeModal();
}
}
},
},
}
</script>