This commit is contained in:
Vanessa 2022-08-26 23:49:07 +08:00
parent 2289b44f0c
commit ce31cca404

View file

@ -94,10 +94,12 @@ export const paste = async (protyle: IProtyle, event: (ClipboardEvent | DragEven
Array.from(xmlDom.getElementsByTagName("string")).forEach(item => {
localFiles.push(item.childNodes[0].nodeValue);
});
uploadLocalFiles(localFiles, protyle);
writeText("");
if (localFiles.length > 0) {
uploadLocalFiles(localFiles, protyle);
writeText("");
return;
}
/// #endif
return;
} else {
const xmlString = await fetchSyncPost("/api/clipboard/readFilePaths", {});
if (xmlString.data.length > 0) {