作者 RuoYi

升级quill到最新版本2.0.2

@@ -49,7 +49,7 @@ @@ -49,7 +49,7 @@
49 "js-cookie": "3.0.1", 49 "js-cookie": "3.0.1",
50 "jsencrypt": "3.0.0-rc.1", 50 "jsencrypt": "3.0.0-rc.1",
51 "nprogress": "0.2.0", 51 "nprogress": "0.2.0",
52 - "quill": "1.3.7", 52 + "quill": "2.0.2",
53 "screenfull": "5.0.2", 53 "screenfull": "5.0.2",
54 "sortablejs": "1.10.2", 54 "sortablejs": "1.10.2",
55 "vue": "2.6.12", 55 "vue": "2.6.12",
@@ -108,7 +108,7 @@ export default { @@ -108,7 +108,7 @@ export default {
108 if (val !== this.currentValue) { 108 if (val !== this.currentValue) {
109 this.currentValue = val === null ? "" : val; 109 this.currentValue = val === null ? "" : val;
110 if (this.Quill) { 110 if (this.Quill) {
111 - this.Quill.pasteHTML(this.currentValue); 111 + this.Quill.clipboard.dangerouslyPasteHTML(this.currentValue);
112 } 112 }
113 } 113 }
114 }, 114 },
@@ -136,7 +136,7 @@ export default { @@ -136,7 +136,7 @@ export default {
136 } 136 }
137 }); 137 });
138 } 138 }
139 - this.Quill.pasteHTML(this.currentValue); 139 + this.Quill.clipboard.dangerouslyPasteHTML(this.currentValue);
140 this.Quill.on("text-change", (delta, oldDelta, source) => { 140 this.Quill.on("text-change", (delta, oldDelta, source) => {
141 const html = this.$refs.editor.children[0].innerHTML; 141 const html = this.$refs.editor.children[0].innerHTML;
142 const text = this.Quill.getText(); 142 const text = this.Quill.getText();
@@ -27,6 +27,7 @@ module.exports = { @@ -27,6 +27,7 @@ module.exports = {
27 lintOnSave: process.env.NODE_ENV === 'development', 27 lintOnSave: process.env.NODE_ENV === 'development',
28 // 如果你不需要生产环境的 source map,可以将其设置为 false 以加速生产环境构建。 28 // 如果你不需要生产环境的 source map,可以将其设置为 false 以加速生产环境构建。
29 productionSourceMap: false, 29 productionSourceMap: false,
  30 + transpileDependencies: ['quill'],
30 // webpack-dev-server 相关配置 31 // webpack-dev-server 相关配置
31 devServer: { 32 devServer: {
32 host: '0.0.0.0', 33 host: '0.0.0.0',