Simplify chat drag logic

This commit is contained in:
2026-04-17 13:04:19 +02:00
parent aac254ec23
commit b11953ef1e

View File

@@ -2350,9 +2350,7 @@ async function regenerateFromIndex(index, overrideUserText = null) {
if (activeSidebarMode !== 'chats' || !hasFilePayload(event)) return if (activeSidebarMode !== 'chats' || !hasFilePayload(event)) return
event.preventDefault() event.preventDefault()
imageDragDepthRef.current += 1 imageDragDepthRef.current += 1
if (eventHasImageFiles(event) || Array.from(event?.dataTransfer?.files || []).some(isSupportedChatFile)) { setIsChatDragActive(true)
setIsChatDragActive(true)
}
} }
const handleChatDragOver = (event) => { const handleChatDragOver = (event) => {