When utilizing the dragenter event to display a dropzone for quickly uploading dropped files on the website, everything functions correctly. However, the dropzone also appears when dragging selected text. How can I differentiate between the two situations early on?
I am aware that the drop event provides access to all file contents through dataTransfer.files for iteration, but this is too late. I need this information at dragenter, yet I always find the files array to be empty.
I require complete control over the appearance and functionality and do not want to rely on an existing library.
I have noticed varying values for event.dataTransfer.Clipboard.effectAllowed when dragging text as opposed to files, with these values also differing between browsers (Chrome vs Firefox).
MooTools is being used, in case that information is helpful.