修复纯文本不能复制的错误

This commit is contained in:
jacky 2024-05-22 18:04:57 +08:00
parent b983c4d773
commit cc61263c97
1 changed files with 6 additions and 3 deletions

View File

@ -76,12 +76,15 @@ const handleCreated = (editor) => {
}
const customPaste = (editor, event, callback) => {
console.log(event)
// console.log(event)
//
loadingShow.value = true
let htmlData = event.clipboardData.getData('text/html') // html
console.log(htmlData)
// console.log(htmlData)
if (htmlData == "") {
htmlData = event.clipboardData.getData('text/plain') // html
// console.log(htmlData)
}
let rtfData = event.clipboardData.getData('text/rtf') // html
// console.log('-------------- rtfData --------------', rtfData)