feat: Add Prop autoClose
to Modal
This commit is contained in:
parent
473d8975f7
commit
d7987d1e0a
1 changed files with 7 additions and 1 deletions
|
@ -122,6 +122,10 @@
|
||||||
type: Number,
|
type: Number,
|
||||||
default: 1000
|
default: 1000
|
||||||
},
|
},
|
||||||
|
autoClose: {
|
||||||
|
type: Boolean,
|
||||||
|
default: true
|
||||||
|
}
|
||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
|
@ -252,7 +256,9 @@
|
||||||
if (this.loading) {
|
if (this.loading) {
|
||||||
this.buttonLoading = true;
|
this.buttonLoading = true;
|
||||||
} else {
|
} else {
|
||||||
this.visible = false;
|
if (this.autoClose) {
|
||||||
|
this.visible = false;
|
||||||
|
}
|
||||||
this.$emit('input', false);
|
this.$emit('input', false);
|
||||||
}
|
}
|
||||||
this.$emit('on-ok');
|
this.$emit('on-ok');
|
||||||
|
|
Loading…
Add table
Reference in a new issue