mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-05-25 08:09:59 +08:00
Continued implementation of attachment drag+drop
Cannot get working in chrome reliably due to conflicting handling of events and drag+drop API. Getting attachment drop working breaks other parts of TinyMCE. Implementing current work as should still work for MD editor and within FireFox. Related to #1460
This commit is contained in:
@ -256,7 +256,7 @@ class MarkdownEditor {
|
||||
}
|
||||
|
||||
const clipboard = new Clipboard(event.dataTransfer);
|
||||
if (clipboard.hasItems()) {
|
||||
if (clipboard.hasItems() && clipboard.getImages().length > 0) {
|
||||
const cursorPos = cm.coordsChar({left: event.pageX, top: event.pageY});
|
||||
cm.setCursor(cursorPos);
|
||||
event.stopPropagation();
|
||||
|
Reference in New Issue
Block a user