mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-01-19 14:01:03 +08:00
Properly unload scroll listener when unloading a select [SCI-8802]
This commit is contained in:
parent
c8c0a147b5
commit
ed4af7ae26
1 changed files with 4 additions and 1 deletions
|
@ -62,7 +62,10 @@
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.focusElement.onblur = this.blur;
|
this.focusElement.onblur = this.blur;
|
||||||
document.addEventListener("scroll", this.updateOptionPosition);
|
document.addEventListener('scroll', this.updateOptionPosition);
|
||||||
|
},
|
||||||
|
beforeDestroy() {
|
||||||
|
document.removeEventListener('scroll', this.updateOptionPosition);
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
preventBlur() {
|
preventBlur() {
|
||||||
|
|
Loading…
Reference in a new issue