-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(ecau): drop images without jQuery #472
Conversation
Codecov Report
@@ Coverage Diff @@
## main #472 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 46 46
Lines 1008 1009 +1
Branches 168 168
=========================================
+ Hits 1008 1009 +1
Continue to review full report at Codecov.
|
/deploy-preview please. |
This PR changes 1 built userscript(s):
|
fix(ecau): drop images without jQuery (#472)
45085f1
to
41e6e35
Compare
/deploy-preview with Greasemonkey fixes Tested successfully with all major browser/userscript engine combinations 🎉 Greasemonkey was being naughty again though, but that's also been fixed. |
/deploy-preview because the bot doesn't listen to edited comments 🙄 |
fix(ecau): drop images without jQuery (#472)
41e6e35
to
792e4b9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
P.S. When you say that you've tested with VM, that includes VM Beta, right?
Good point, I actually only tested with VM Beta on Firefox (Chrome was the non-beta version). I have no reason to believe it won't work on VM stable in FF or VM Beta in Chrome, but I'll double-check before merging. |
Well, you already did more tests than I would have done, so I definitely won't complain 😂 |
I really needed to downgrade VM to the stable version anyway to verify whether #465 was because of VM beta. Can confirm this fix works on Chrome/VM beta and FF/VM stable too. |
fix(ecau): drop images without jQuery (#472)
🚀 Released 1 new userscript version(s):
|
So apparently my previous experimentation didn't go far enough and it turns out we don't actually need jQuery to get MB to handle the drop event. The reason we were using jQuery was that we can't "officially" instantiate our own
DropEvent
s with aFileList
with our own files in thedataTransfer
property (either because of read-only properties, private constructors, or some other security precaution). However, I never tried just defining the necessary properties usingObject.defineProperty
, which can circumvent the readonly status. Turns out, that just works. 🎉Fixes #440.
Tested successfully on: