Skip to content

Instantly share code, notes, and snippets.

@kfix
Last active August 29, 2015 14:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kfix/229726792f212e259a57 to your computer and use it in GitHub Desktop.
Save kfix/229726792f212e259a57 to your computer and use it in GitHub Desktop.
Fix to minified Trello app.js to allow dragging and dropping links and images from Safari into Trello cards
--- sites/Trello/app.js 2015-05-29 20:20:05.000000000 -0700
+++ sites/Trello/app.js.feex 2015-05-29 20:21:30.000000000 -0700
@@ -31948,13 +31948,13 @@
})
}, function(e, r) {
return t(r)
- })) : t((null != (a = d.call(null != r ? r.types : void 0, "text/x-moz-url") >= 0) ? a : []) ? [r.getData("text/plain")] : [])
+ })) : t((null != (a = d.call(null != r ? r.types : void 0, "text/plain") >= 0) ? a : []) ? [r.getData("text/plain")] : [])
}, e.prototype._isDraggingFiles = function(e) {
var t, r, n, o;
return t = null != (r = e.originalEvent) ? r.dataTransfer : void 0, null != t && (null != t.items && u.any(t.items, function(e) {
return "file" === e.kind || "text/uri-list" === e.type
}) || null != t.types && u.any(t.types, function(e) {
- return "application/x-moz-file" === e || "text/x-moz-url" === e
+ return "application/x-moz-file" === e || "text/x-moz-url" === e || "text/uri-list" === e
}) || (null != (n = t.files) ? n.length : void 0) > 0 && ("copy" === (o = t.effectAllowed) || "all" === o) || /mac/i.test(navigator.platform) && /safari/i.test(navigator.userAgent))
}, e.prototype.dragenter = function(e) {
return this._isDraggingFiles(e) ? (a.hide(), s.stop(e), this.didEnter = !0, u.defer(function(e) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment