mirror of
https://github.com/wanglin2/mind-map.git
synced 2026-02-21 10:27:44 +08:00
Fix:修复非富文本模式下文本编辑时不能粘贴<a格式的文本的问题
This commit is contained in:
parent
f8f126e8de
commit
dde085b54e
@ -1208,6 +1208,8 @@ export const handleInputPasteText = (e, text) => {
|
||||
if (!selection.rangeCount) return
|
||||
selection.deleteFromDocument()
|
||||
text = text || e.clipboardData.getData('text')
|
||||
// 转义特殊字符
|
||||
text = htmlEscape(text)
|
||||
// 去除格式
|
||||
text = getTextFromHtml(text)
|
||||
// 去除换行
|
||||
|
||||
Loading…
Reference in New Issue
Block a user