@uppy/thumbnail-generator
Advanced tools
Comparing version 1.6.5 to 1.6.6
@@ -163,2 +163,4 @@ var _class, _temp; | ||
// bug in the compatibility data | ||
// eslint-disable-next-line compat/compat | ||
var originalUrl = URL.createObjectURL(file.data); | ||
@@ -169,2 +171,4 @@ var onload = new Promise(function (resolve, reject) { | ||
image.addEventListener('load', function () { | ||
// bug in the compatibility data | ||
// eslint-disable-next-line compat/compat | ||
URL.revokeObjectURL(originalUrl); | ||
@@ -174,2 +178,4 @@ resolve(image); | ||
image.addEventListener('error', function (event) { | ||
// bug in the compatibility data | ||
// eslint-disable-next-line compat/compat | ||
URL.revokeObjectURL(originalUrl); | ||
@@ -194,2 +200,4 @@ reject(event.error || new Error('Could not create thumbnail')); | ||
}).then(function (blob) { | ||
// bug in the compatibility data | ||
// eslint-disable-next-line compat/compat | ||
return URL.createObjectURL(blob); | ||
@@ -462,2 +470,2 @@ }); | ||
return ThumbnailGenerator; | ||
}(Plugin), _class.VERSION = "1.6.5", _temp); | ||
}(Plugin), _class.VERSION = "1.6.6", _temp); |
{ | ||
"name": "@uppy/thumbnail-generator", | ||
"description": "Uppy plugin that generates small previews of images to show on your upload UI.", | ||
"version": "1.6.5", | ||
"version": "1.6.6", | ||
"license": "MIT", | ||
@@ -32,3 +32,3 @@ "main": "lib/index.js", | ||
}, | ||
"gitHead": "36ab6f1d492edca678327a98629a0a53ba37604e" | ||
"gitHead": "32e5445facad7257d32d83b7c915a80bf2c7b65a" | ||
} |
@@ -67,2 +67,4 @@ const { Plugin } = require('@uppy/core') | ||
createThumbnail (file, targetWidth, targetHeight) { | ||
// bug in the compatibility data | ||
// eslint-disable-next-line compat/compat | ||
const originalUrl = URL.createObjectURL(file.data) | ||
@@ -74,2 +76,4 @@ | ||
image.addEventListener('load', () => { | ||
// bug in the compatibility data | ||
// eslint-disable-next-line compat/compat | ||
URL.revokeObjectURL(originalUrl) | ||
@@ -79,2 +83,4 @@ resolve(image) | ||
image.addEventListener('error', (event) => { | ||
// bug in the compatibility data | ||
// eslint-disable-next-line compat/compat | ||
URL.revokeObjectURL(originalUrl) | ||
@@ -95,2 +101,4 @@ reject(event.error || new Error('Could not create thumbnail')) | ||
.then(blob => { | ||
// bug in the compatibility data | ||
// eslint-disable-next-line compat/compat | ||
return URL.createObjectURL(blob) | ||
@@ -97,0 +105,0 @@ }) |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
74252
1217