@oub/fusion 0.2.105 → 0.2.106
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/fusion.js
CHANGED
|
@@ -1454,7 +1454,7 @@ const Hi = /* @__PURE__ */ he(zu, [["render", Wu], ["__scopeId", "data-v-71c2433
|
|
|
1454
1454
|
}
|
|
1455
1455
|
}
|
|
1456
1456
|
});
|
|
1457
|
-
const zi = (e) => (so("data-v-
|
|
1457
|
+
const zi = (e) => (so("data-v-50ad0004"), e = e(), lo(), e), Yu = ["data-test"], Gu = { class: "fusion-select-panel" }, Zu = { class: "fusion-select-panel-content" }, _u = { class: "list-wrapper" }, $u = {
|
|
1458
1458
|
key: 0,
|
|
1459
1459
|
class: "p-xl",
|
|
1460
1460
|
"data-test": "search-loading-wrapper"
|
|
@@ -1577,7 +1577,7 @@ function fd(e, t, a, r, n, o) {
|
|
|
1577
1577
|
_: 3
|
|
1578
1578
|
}, 8, ["options", "onTrigger"]);
|
|
1579
1579
|
}
|
|
1580
|
-
const bo = /* @__PURE__ */ he(Ku, [["render", fd], ["__scopeId", "data-v-
|
|
1580
|
+
const bo = /* @__PURE__ */ he(Ku, [["render", fd], ["__scopeId", "data-v-50ad0004"]]), hd = {
|
|
1581
1581
|
name: "SVGArrowDown"
|
|
1582
1582
|
}, md = {
|
|
1583
1583
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -2623,7 +2623,7 @@ function Hd(e, t, a, r, n, o) {
|
|
|
2623
2623
|
}, 1032, ["selected", "data-test", "onKeydown", "onClick"]))), 128))
|
|
2624
2624
|
], 8, Rd);
|
|
2625
2625
|
}
|
|
2626
|
-
const zd = /* @__PURE__ */ he(Ed, [["render", Hd], ["__scopeId", "data-v-
|
|
2626
|
+
const zd = /* @__PURE__ */ he(Ed, [["render", Hd], ["__scopeId", "data-v-6e820bf3"]]), jd = {
|
|
2627
2627
|
name: "CountrySelectDropdown",
|
|
2628
2628
|
components: { SVGArrowDown: ji, CountryFlag: Xi },
|
|
2629
2629
|
props: {
|
|
@@ -2682,7 +2682,7 @@ function Kd(e, t, a, r, n, o) {
|
|
|
2682
2682
|
])
|
|
2683
2683
|
], 10, Jd);
|
|
2684
2684
|
}
|
|
2685
|
-
const Yd = /* @__PURE__ */ he(jd, [["render", Kd], ["__scopeId", "data-v-
|
|
2685
|
+
const Yd = /* @__PURE__ */ he(jd, [["render", Kd], ["__scopeId", "data-v-0de9450e"]]), Gd = le({
|
|
2686
2686
|
name: "FusionPhoneInput",
|
|
2687
2687
|
components: { CountrySelectList: zd, FusionPanel: bo, CountrySelectDropdown: Yd, SVGExclamationTriangle: wt },
|
|
2688
2688
|
props: {
|
|
@@ -3416,7 +3416,7 @@ function $c(e, t, a, r, n, o) {
|
|
|
3416
3416
|
_: 3
|
|
3417
3417
|
});
|
|
3418
3418
|
}
|
|
3419
|
-
const G3 = /* @__PURE__ */ he(Xc, [["render", $c], ["__scopeId", "data-v-
|
|
3419
|
+
const G3 = /* @__PURE__ */ he(Xc, [["render", $c], ["__scopeId", "data-v-a6dafb6d"]]);
|
|
3420
3420
|
function Ft(e) {
|
|
3421
3421
|
"@babel/helpers - typeof";
|
|
3422
3422
|
return Ft = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
|
|
@@ -12908,7 +12908,7 @@ function U1(e, t, a, r, n, o) {
|
|
|
12908
12908
|
})) : C("", !0)
|
|
12909
12909
|
], 64);
|
|
12910
12910
|
}
|
|
12911
|
-
const nk = /* @__PURE__ */ he(D1, [["render", U1], ["__scopeId", "data-v-
|
|
12911
|
+
const nk = /* @__PURE__ */ he(D1, [["render", U1], ["__scopeId", "data-v-3bd17874"]]), I1 = le({
|
|
12912
12912
|
name: "FusionSideNavigationItem",
|
|
12913
12913
|
props: {
|
|
12914
12914
|
item: {
|
|
@@ -13897,7 +13897,7 @@ const J0 = /* @__PURE__ */ he(z0, [["render", j0], ["__scopeId", "data-v-a88d594
|
|
|
13897
13897
|
}
|
|
13898
13898
|
}
|
|
13899
13899
|
};
|
|
13900
|
-
const W0 = (e) => (so("data-v-
|
|
13900
|
+
const W0 = (e) => (so("data-v-9397fe0b"), e = e(), lo(), e), K0 = ["aria-labelledby"], Y0 = /* @__PURE__ */ W0(() => /* @__PURE__ */ g("div", {
|
|
13901
13901
|
class: "fusion-modal-background",
|
|
13902
13902
|
"aria-hidden": "true"
|
|
13903
13903
|
}, null, -1));
|
|
@@ -13955,7 +13955,7 @@ function G0(e, t, a, r, n, o) {
|
|
|
13955
13955
|
Y0
|
|
13956
13956
|
], 2);
|
|
13957
13957
|
}
|
|
13958
|
-
const fk = /* @__PURE__ */ he(X0, [["render", G0], ["__scopeId", "data-v-
|
|
13958
|
+
const fk = /* @__PURE__ */ he(X0, [["render", G0], ["__scopeId", "data-v-9397fe0b"]]), Z0 = 12, Ho = le({
|
|
13959
13959
|
name: "FusionCircularProgressIndicator",
|
|
13960
13960
|
props: {
|
|
13961
13961
|
size: {
|
|
@@ -17262,26 +17262,29 @@ const F3 = /* @__PURE__ */ he(C3, [["render", T3]]), D3 = le({
|
|
|
17262
17262
|
},
|
|
17263
17263
|
acceptedFileTypes() {
|
|
17264
17264
|
return this.allowedFileTypes.join(",");
|
|
17265
|
+
},
|
|
17266
|
+
uppyClient() {
|
|
17267
|
+
return new F2({
|
|
17268
|
+
// https://uppy.io/docs/uppy/#options
|
|
17269
|
+
restrictions: {
|
|
17270
|
+
maxNumberOfFiles: this.maxFiles,
|
|
17271
|
+
maxFileSize: this.maxFileSize,
|
|
17272
|
+
allowedFileTypes: this.allowedFileTypes
|
|
17273
|
+
},
|
|
17274
|
+
autoProceed: this.automaticallyUpload
|
|
17275
|
+
});
|
|
17265
17276
|
}
|
|
17266
17277
|
},
|
|
17267
17278
|
mounted() {
|
|
17268
17279
|
this.initUppy();
|
|
17269
17280
|
},
|
|
17270
17281
|
beforeUnmount() {
|
|
17271
|
-
this.
|
|
17282
|
+
this.uppyClient && (this.uppyClient.cancelAll(), this.uppyClient.clear());
|
|
17272
17283
|
},
|
|
17273
17284
|
methods: {
|
|
17274
17285
|
// Initialize Uppy
|
|
17275
17286
|
initUppy() {
|
|
17276
|
-
this.
|
|
17277
|
-
// https://uppy.io/docs/uppy/#options
|
|
17278
|
-
restrictions: {
|
|
17279
|
-
maxNumberOfFiles: this.maxFiles,
|
|
17280
|
-
maxFileSize: this.maxFileSize,
|
|
17281
|
-
allowedFileTypes: this.allowedFileTypes
|
|
17282
|
-
},
|
|
17283
|
-
autoProceed: this.automaticallyUpload
|
|
17284
|
-
}), this.uppy && this.uppy.use(Gs, {
|
|
17287
|
+
this.uppyClient && this.uppyClient.use(Gs, {
|
|
17285
17288
|
// https://uppy.io/docs/xhr-upload/#options
|
|
17286
17289
|
endpoint: this.uploadUrl,
|
|
17287
17290
|
headers: this.headers,
|
|
@@ -17293,18 +17296,18 @@ const F3 = /* @__PURE__ */ he(C3, [["render", T3]]), D3 = le({
|
|
|
17293
17296
|
shouldRetry(e) {
|
|
17294
17297
|
return !1;
|
|
17295
17298
|
}
|
|
17296
|
-
}), this.
|
|
17297
|
-
this.files = this.
|
|
17298
|
-
}), this.
|
|
17299
|
-
this.files = this.
|
|
17300
|
-
}), this.
|
|
17299
|
+
}), this.uppyClient && (this.uppyClient.on("file-added", (e) => {
|
|
17300
|
+
this.files = this.uppyClient.getFiles(), e && (this.uppyClient.setMeta(this.formData), this.$emit("uppy-file-added", e), this.clearInternalError());
|
|
17301
|
+
}), this.uppyClient.on("file-removed", (e) => {
|
|
17302
|
+
this.files = this.uppyClient.getFiles(), e && this.$emit("uppy-file-removed", e);
|
|
17303
|
+
}), this.uppyClient.on("upload", () => {
|
|
17301
17304
|
this.isUploading = !0;
|
|
17302
|
-
}), this.
|
|
17303
|
-
this.files = this.
|
|
17304
|
-
}), this.
|
|
17305
|
-
this.files = this.
|
|
17306
|
-
}), this.
|
|
17307
|
-
this.files = this.
|
|
17305
|
+
}), this.uppyClient.on("upload-progress", () => {
|
|
17306
|
+
this.files = this.uppyClient.getFiles();
|
|
17307
|
+
}), this.uppyClient.on("upload-success", (e, t) => {
|
|
17308
|
+
this.files = this.uppyClient.getFiles(), e && (this.$emit("uppy-upload-success", { file: e, response: t }), this.clearInternalError());
|
|
17309
|
+
}), this.uppyClient.on("upload-error", (e, t) => {
|
|
17310
|
+
this.files = this.uppyClient.getFiles();
|
|
17308
17311
|
const a = `Upload failed: ${t.message}`;
|
|
17309
17312
|
switch (this.$emit("uppy-upload-error", t), t.cause) {
|
|
17310
17313
|
case "Internal Server Error":
|
|
@@ -17319,11 +17322,11 @@ const F3 = /* @__PURE__ */ he(C3, [["render", T3]]), D3 = le({
|
|
|
17319
17322
|
this.setInternalError(a);
|
|
17320
17323
|
}
|
|
17321
17324
|
e && this.removeFile(e);
|
|
17322
|
-
}), this.
|
|
17325
|
+
}), this.uppyClient.on("complete", (e) => {
|
|
17323
17326
|
this.isUploading = !1;
|
|
17324
17327
|
const t = (e == null ? void 0 : e.failed) || [], a = (e == null ? void 0 : e.successful) || [];
|
|
17325
17328
|
t.length === 0 && a.length > 0 && this.clearInternalError(), this.$emit("uppy-upload-complete");
|
|
17326
|
-
}), this.
|
|
17329
|
+
}), this.uppyClient.on("restriction-failed", (e, t) => {
|
|
17327
17330
|
let a = t.message;
|
|
17328
17331
|
a.startsWith("You can only upload:") && (this.allowedFileTypes && this.allowedFileTypes.length > 0 ? a = `The selected files must be ${this.allowedFileTypes.join(", ")}` : a = "File type not allowed. Please check the allowed file types.", this.$emit("uppy-restriction-error", "incorrect-file-type")), a.includes("exceeds maximum allowed size") && (a = `The file size must not exceed ${Zs(this.maxFileSize)}.`, this.$emit("uppy-restriction-error", "incorrect-file-size")), a.includes("You can only upload") && (a = `You can only upload a maximum of ${this.maxFiles} file${this.maxFiles !== 1 ? "s" : ""}.`, this.$emit("uppy-restriction-error", "incorrect-file-amount")), this.setInternalError(a);
|
|
17329
17332
|
}));
|
|
@@ -17340,9 +17343,9 @@ const F3 = /* @__PURE__ */ he(C3, [["render", T3]]), D3 = le({
|
|
|
17340
17343
|
this.addFiles(a), t.value = "";
|
|
17341
17344
|
},
|
|
17342
17345
|
addFiles(e) {
|
|
17343
|
-
this.disabled || !this.
|
|
17346
|
+
this.disabled || !this.uppyClient || e.forEach((t) => {
|
|
17344
17347
|
try {
|
|
17345
|
-
this.
|
|
17348
|
+
this.uppyClient.addFile({
|
|
17346
17349
|
name: t.name,
|
|
17347
17350
|
type: t.type,
|
|
17348
17351
|
data: t,
|
|
@@ -17354,10 +17357,10 @@ const F3 = /* @__PURE__ */ he(C3, [["render", T3]]), D3 = le({
|
|
|
17354
17357
|
});
|
|
17355
17358
|
},
|
|
17356
17359
|
removeFile(e) {
|
|
17357
|
-
this.
|
|
17360
|
+
this.uppyClient && (this.uppyClient.removeFile(e.id), this.$emit("uppy-file-removed", e));
|
|
17358
17361
|
},
|
|
17359
17362
|
clearFiles() {
|
|
17360
|
-
this.
|
|
17363
|
+
this.uppyClient && (this.uppyClient.clear(), this.files = []);
|
|
17361
17364
|
},
|
|
17362
17365
|
setInternalError(e) {
|
|
17363
17366
|
this.internalErrorMessage = e;
|
|
@@ -17428,7 +17431,7 @@ function V3(e, t, a, r, n, o) {
|
|
|
17428
17431
|
], 2)) : C("", !0)
|
|
17429
17432
|
], 10, B3);
|
|
17430
17433
|
}
|
|
17431
|
-
const vk = /* @__PURE__ */ he(D3, [["render", V3], ["__scopeId", "data-v-
|
|
17434
|
+
const vk = /* @__PURE__ */ he(D3, [["render", V3], ["__scopeId", "data-v-7e4f151b"]]), N3 = le({
|
|
17432
17435
|
name: "FusionRangeDatePicker",
|
|
17433
17436
|
components: { SVGCalendar: qo, SVGExclamationTriangle: wt, VueDatePicker: Un },
|
|
17434
17437
|
props: {
|