Skip to content

Commit 49f1e5e

Browse files
committed
fix[Tinymce]: fixed fullScreen bug #1400
1 parent b8b7877 commit 49f1e5e

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/components/Tinymce/index.vue

+7-2
Original file line numberDiff line numberDiff line change
@@ -157,8 +157,13 @@ export default {
157157
})
158158
},
159159
destroyTinymce() {
160-
if (window.tinymce.get(this.tinymceId)) {
161-
window.tinymce.get(this.tinymceId).destroy()
160+
const tinymce = window.tinymce.get(this.tinymceId)
161+
if (this.fullscreen) {
162+
tinymce.execCommand('mceFullScreen')
163+
}
164+
165+
if (tinymce) {
166+
tinymce.destroy()
162167
}
163168
},
164169
setContent(value) {

0 commit comments

Comments
 (0)