@swan-admin/swan-ai-measurements 1.1.2 → 1.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/fileUpload.js +4 -4
- package/dist/fileUpload.js +2 -2
- package/package.json +1 -1
package/dist/esm/fileUpload.js
CHANGED
|
@@ -22,8 +22,8 @@ var _FileUpload_uppyIns, _FileUpload_accessKey, _FileUpload_stagingUrl;
|
|
|
22
22
|
import axios from "axios";
|
|
23
23
|
import { REQUIRED_MESSAGE, REQUIRED_MESSAGE_FOR_META_DATA, FILE_UPLOAD_ENDPOINT, APP_AUTH_BASE_URL } from "./constants.js";
|
|
24
24
|
import { checkMetaDataValue, checkParameters, fetchData, getFileChunks, getUrl } from "./utils.js";
|
|
25
|
-
|
|
26
|
-
|
|
25
|
+
import Uppy from "@uppy/core";
|
|
26
|
+
import AwsS3Multipart from "@uppy/aws-s3-multipart";
|
|
27
27
|
class FileUpload {
|
|
28
28
|
constructor(accessKey, stagingUrl = false) {
|
|
29
29
|
_FileUpload_uppyIns.set(this, void 0);
|
|
@@ -44,8 +44,8 @@ class FileUpload {
|
|
|
44
44
|
if (__classPrivateFieldGet(this, _FileUpload_uppyIns, "f")) {
|
|
45
45
|
__classPrivateFieldGet(this, _FileUpload_uppyIns, "f").close();
|
|
46
46
|
}
|
|
47
|
-
__classPrivateFieldSet(this, _FileUpload_uppyIns, new Uppy
|
|
48
|
-
__classPrivateFieldGet(this, _FileUpload_uppyIns, "f").use(AwsS3Multipart
|
|
47
|
+
__classPrivateFieldSet(this, _FileUpload_uppyIns, new Uppy({ autoProceed: true }), "f");
|
|
48
|
+
__classPrivateFieldGet(this, _FileUpload_uppyIns, "f").use(AwsS3Multipart, {
|
|
49
49
|
limit: 10,
|
|
50
50
|
retryDelays: [0, 1000, 3000, 5000],
|
|
51
51
|
companionUrl: getUrl({ urlName: APP_AUTH_BASE_URL, stagingUrl: __classPrivateFieldGet(this, _FileUpload_stagingUrl, "f") }),
|
package/dist/fileUpload.js
CHANGED
|
@@ -27,8 +27,8 @@ class FileUpload {
|
|
|
27
27
|
if (this.#uppyIns) {
|
|
28
28
|
this.#uppyIns.close();
|
|
29
29
|
}
|
|
30
|
-
this.#uppyIns = new Uppy({ autoProceed: true });
|
|
31
|
-
this.#uppyIns.use(AwsS3Multipart, {
|
|
30
|
+
this.#uppyIns = new Uppy.default({ autoProceed: true });
|
|
31
|
+
this.#uppyIns.use(AwsS3Multipart.default, {
|
|
32
32
|
limit: 10,
|
|
33
33
|
retryDelays: [0, 1000, 3000, 5000],
|
|
34
34
|
companionUrl: (0, utils_js_1.getUrl)({ urlName: constants_js_1.APP_AUTH_BASE_URL, stagingUrl: this.#stagingUrl }),
|