Skip to content

Commit

Permalink
modal: change event order (#454)
Browse files Browse the repository at this point in the history
* modal: change event order

* modal: change to BS4 events
  • Loading branch information
youaresofunny authored and pi0 committed May 26, 2017
1 parent 8090c4c commit e5f4253
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/components/modal.vue
Expand Up @@ -188,6 +188,7 @@
if (this.is_visible) {
return;
}
this.$emit('show');
this.is_visible = true;
this.$root.$emit('shown::modal', this.id);
this.body.classList.add('modal-open');
Expand Down Expand Up @@ -216,7 +217,7 @@
// Emit events
this.$emit('change', false);
this.$emit('hidden', e);
this.$emit('hide',e);
if (isOK === true) {
this.$emit('ok', e);
Expand All @@ -234,6 +235,7 @@
}
this.is_visible = false;
this.$root.$emit('hidden::modal', this.id);
this.$emit('hidden', e);
this.body.classList.remove('modal-open');
}
},
Expand Down

0 comments on commit e5f4253

Please sign in to comment.