diff --git a/web/app/components/base/file-uploader/hooks.ts b/web/app/components/base/file-uploader/hooks.ts index b4c8fe1008..7c82e0a04e 100644 --- a/web/app/components/base/file-uploader/hooks.ts +++ b/web/app/components/base/file-uploader/hooks.ts @@ -310,7 +310,8 @@ export const useFile = (fileConfig: FileUpload) => { const handleClipboardPasteFile = useCallback((e: ClipboardEvent) => { const file = e.clipboardData?.files[0] - if (file) { + const text = e.clipboardData?.getData('text/plain') + if (file && !text) { e.preventDefault() handleLocalFileUpload(file) }