diff --git a/src/components/codeMirror/header.vue b/src/components/codeMirror/header.vue index df83af9..4143738 100644 --- a/src/components/codeMirror/header.vue +++ b/src/components/codeMirror/header.vue @@ -15,7 +15,7 @@ - + @@ -216,9 +216,6 @@ export default { } }, // 重置页面 - reset() { - this.showResetConfirm = true; - }, confirmReset() { localStorage.clear() this.clearEditorToDefault(); @@ -229,6 +226,9 @@ export default { this.colorChanged(this.config.colorOption[1].value) this.sizeChanged(this.config.sizeOption[2].value) this.$emit('cssChanged') + this.selectFont = this.currentFont; + this.selectSize = this.currentSize; + this.selectColor = this.currentColor; this.showResetConfirm = false; }, cancelReset() { @@ -250,9 +250,9 @@ export default { 'setHtml', 'setCurrentFont', 'setCurrentSize', 'setCssEditorValue', 'setWxRendererOptions']) }, mounted() { - this.selectFont = this.currentFont - this.selectSize = this.currentSize - this.selectColor = this.currentColor + this.selectFont = this.currentFont; + this.selectSize = this.currentSize; + this.selectColor = this.currentColor; } }