fix: envinput crash on debounce handle editor undefined
This commit is contained in:
@@ -120,9 +120,11 @@ export default defineComponent({
|
|||||||
},
|
},
|
||||||
handleChange() {
|
handleChange() {
|
||||||
this.debouncedHandler = debounce(function () {
|
this.debouncedHandler = debounce(function () {
|
||||||
if (this.internalValue !== this.$refs.editor.textContent) {
|
if (this.$refs.editor) {
|
||||||
this.internalValue = this.$refs.editor.textContent
|
if (this.internalValue !== this.$refs.editor.textContent) {
|
||||||
this.processHighlights()
|
this.internalValue = this.$refs.editor.textContent
|
||||||
|
this.processHighlights()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}, 5)
|
}, 5)
|
||||||
this.debouncedHandler()
|
this.debouncedHandler()
|
||||||
|
|||||||
Reference in New Issue
Block a user