mirror of
https://github.com/wanglin2/mind-map.git
synced 2026-02-17 22:08:25 +08:00
Fix:修复创建多个思维导图实例时公式插件会多次扩展Quill的问题
This commit is contained in:
@@ -3,6 +3,8 @@ import Quill from 'quill'
|
||||
import { getChromeVersion, htmlEscape } from '../utils/index'
|
||||
import { getBaseStyleText, getFontStyleText } from './FormulaStyle'
|
||||
|
||||
let extended = false
|
||||
|
||||
// 数学公式支持插件
|
||||
// 该插件在富文本模式下可用
|
||||
class Formula {
|
||||
@@ -50,6 +52,9 @@ class Formula {
|
||||
|
||||
// 修改formula格式工具
|
||||
extendQuill() {
|
||||
if (extended) return
|
||||
extended = true
|
||||
|
||||
const QuillFormula = Quill.import('formats/formula')
|
||||
const self = this
|
||||
|
||||
|
||||
Reference in New Issue
Block a user