mirror of
https://github.com/tenrok/vue-context.git
synced 2026-06-23 09:10:32 +03:00
Formatting
This commit is contained in:
+10
-10
@@ -77,21 +77,21 @@
|
|||||||
window.addEventListener('scroll', this.close);
|
window.addEventListener('scroll', this.close);
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Close the context menu.
|
* Close the context menu.
|
||||||
*
|
*
|
||||||
* @param {boolean|Event} emit Used to prevent event being emitted twice from when menu is clicked and closed
|
* @param {boolean|Event} emit Used to prevent event being emitted twice from when menu is clicked and closed
|
||||||
*/
|
*/
|
||||||
close (emit = true) {
|
close (emit = true) {
|
||||||
this.top = null;
|
this.top = null;
|
||||||
this.left = null;
|
this.left = null;
|
||||||
this.data = null;
|
this.data = null;
|
||||||
this.show = false;
|
this.show = false;
|
||||||
|
|
||||||
if (emit) {
|
if (emit) {
|
||||||
this.$emit('close');
|
this.$emit('close');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Close the menu if `closeOnClick` is set to true.
|
* Close the menu if `closeOnClick` is set to true.
|
||||||
|
|||||||
Reference in New Issue
Block a user