From 999ea3a44339c0dc86400075570ffbbd7c6ed720 Mon Sep 17 00:00:00 2001 From: Pan Date: Tue, 4 Dec 2018 18:15:52 +0800 Subject: [PATCH] fix[Tinymce]: fixed fullScreen bug #1400 --- src/components/Tinymce/index.vue | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/components/Tinymce/index.vue b/src/components/Tinymce/index.vue index 7f4a0ae0ea1..9032a6a8ab2 100644 --- a/src/components/Tinymce/index.vue +++ b/src/components/Tinymce/index.vue @@ -157,8 +157,13 @@ export default { }) }, destroyTinymce() { - if (window.tinymce.get(this.tinymceId)) { - window.tinymce.get(this.tinymceId).destroy() + const tinymce = window.tinymce.get(this.tinymceId) + if (this.fullscreen) { + tinymce.execCommand('mceFullScreen') + } + + if (tinymce) { + tinymce.destroy() } }, setContent(value) {