@spiffcommerce/core 27.3.0-beta.05f252d3-708a-513e-8231-67285a5cd0d1 → 27.3.0-beta.1585d9b8-15c4-5217-8f48-b75f0565fba9
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/index.js +38 -38
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +593 -596
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -11,10 +11,10 @@ import St from "lodash.clonedeep";
|
|
|
11
11
|
import { toString as ln } from "qrcode";
|
|
12
12
|
import pr from "svg-path-bbox";
|
|
13
13
|
import { parse as Xe } from "opentype.js";
|
|
14
|
-
import { jsx as
|
|
14
|
+
import { jsx as F, jsxs as ct, Fragment as zt } from "preact/jsx-runtime";
|
|
15
15
|
import fr from "handlebars";
|
|
16
16
|
import { dataUriToBuffer as Cr } from "data-uri-to-buffer";
|
|
17
|
-
import
|
|
17
|
+
import Fa from "lodash.chunk";
|
|
18
18
|
import { CognitoIdentityProviderClient as wr, InitiateAuthCommand as ka, RespondToAuthChallengeCommand as yr } from "@aws-sdk/client-cognito-identity-provider";
|
|
19
19
|
import Sr from "dinero.js";
|
|
20
20
|
import * as Ma from "currency-codes";
|
|
@@ -23,7 +23,7 @@ import { split as Ze } from "unicode-default-word-boundary";
|
|
|
23
23
|
import dn from "lodash.debounce";
|
|
24
24
|
import "fs";
|
|
25
25
|
import "path";
|
|
26
|
-
var Ce = /* @__PURE__ */ ((r) => (r.Data = "Data", r.Font = "Font", r.Frame = "Frame", r.Illustration = "Illustration", r.Image = "Image", r.Model = "Model", r.Material = "Material", r.Color = "Color", r.QuestionnaireCollateral = "QuestionnaireCollateral", r.RequestCollateral = "RequestCollateral", r.SignupCollateral = "SignupCollateral", r.Video = "Video", r.ColorProfile = "ColorProfile", r.Environment = "Environment", r))(Ce || {}),
|
|
26
|
+
var Ce = /* @__PURE__ */ ((r) => (r.Data = "Data", r.Font = "Font", r.Frame = "Frame", r.Illustration = "Illustration", r.Image = "Image", r.Model = "Model", r.Material = "Material", r.Color = "Color", r.QuestionnaireCollateral = "QuestionnaireCollateral", r.RequestCollateral = "RequestCollateral", r.SignupCollateral = "SignupCollateral", r.Video = "Video", r.ColorProfile = "ColorProfile", r.Environment = "Environment", r))(Ce || {}), j = /* @__PURE__ */ ((r) => (r.FileUpload = "FileUpload", r.Option = "Option", r.ColorOption = "ColorOption", r.Text = "Text", r))(j || {}), P = /* @__PURE__ */ ((r) => (r.Information = "Information", r.Bulk = "Bulk", r.DigitalContent = "DigitalContent", r.Finish = "Finish", r.Frame = "Frame", r.Illustration = "Illustration", r.Introduction = "Introduction", r.Material = "Material", r.Model = "Model", r.Module = "Module", r.Picture = "Picture", r.Photo = "Photo", r.ProductOverlay = "ProductOverlay", r.Question = "Question", r.Shape = "Shape", r.SilentIllustration = "SilentIllustration", r.Text = "Text", r))(P || {}), vr = /* @__PURE__ */ ((r) => (r.Color = "Color", r.Colors = "Colors", r.Selection = "Selection", r.Selections = "Selections", r.Text = "Text", r.Upload = "Upload", r))(vr || {}), qt = /* @__PURE__ */ ((r) => (r.ThreeD = "ThreeD", r.FreeDesign = "FreeDesign", r.Print = "Print", r))(qt || {}), M = /* @__PURE__ */ ((r) => (r.Frame = "frame", r.Group = "group", r.Image = "image", r.Pattern = "pattern", r.Illustration = "illustration", r.Textbox = "textbox", r))(M || {}), Er = /* @__PURE__ */ ((r) => (r.Default = "Default", r.FirstTransaction = "FirstTransaction", r.OneToOne = "OneToOne", r))(Er || {}), br = /* @__PURE__ */ ((r) => (r.Hyperlink = "Hyperlink", r.Edit = "Edit", r.Approve = "Approve", r))(br || {}), Br = /* @__PURE__ */ ((r) => (r.Hub = "Hub", r.Shopify = "Shopify", r))(Br || {}), ua = /* @__PURE__ */ ((r) => (r.BackgroundRemover = "BackgroundRemover", r.ConversionAccelerator = "Conversion Accelerator", r.ProcessBuilder = "ProcessBuilder", r))(ua || {}), Ir = /* @__PURE__ */ ((r) => (r[r.Orbit = 0] = "Orbit", r[r.Pan = 1] = "Pan", r))(Ir || {}), we = /* @__PURE__ */ ((r) => (r.Owner = "Owner", r.Approver = "Approver", r.Editor = "Editor", r.Viewer = "Viewer", r))(we || {}), Mt = /* @__PURE__ */ ((r) => (r.Autosize = "Autosize", r.Traditional = "Traditional", r))(Mt || {}), H = /* @__PURE__ */ ((r) => (r[r.North = 0] = "North", r[r.Northeast = 1] = "Northeast", r[r.East = 2] = "East", r[r.Southeast = 3] = "Southeast", r[r.South = 4] = "South", r[r.Southwest = 5] = "Southwest", r[r.West = 6] = "West", r[r.Northwest = 7] = "Northwest", r))(H || {}), Pr = /* @__PURE__ */ ((r) => (r.Pixel = "px", r.Millimeter = "mm", r.Centimeter = "cm", r))(Pr || {});
|
|
27
27
|
class An extends Error {
|
|
28
28
|
constructor(t) {
|
|
29
29
|
super(t), this.name = this.constructor.name;
|
|
@@ -69,7 +69,7 @@ class G extends De {
|
|
|
69
69
|
super(`Unhandled Behavior Encountered: ${t}`);
|
|
70
70
|
}
|
|
71
71
|
}
|
|
72
|
-
class
|
|
72
|
+
class xt extends De {
|
|
73
73
|
constructor(t) {
|
|
74
74
|
super(`Parsing Error: ${t}`);
|
|
75
75
|
}
|
|
@@ -79,7 +79,7 @@ class ut extends De {
|
|
|
79
79
|
super(`Client Error: ${t}`);
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
|
-
class
|
|
82
|
+
class xe extends De {
|
|
83
83
|
constructor(t) {
|
|
84
84
|
super(`Resource Generation Failed: ${t}`);
|
|
85
85
|
}
|
|
@@ -127,14 +127,14 @@ class Ta {
|
|
|
127
127
|
this.set(t, a);
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
|
-
const
|
|
130
|
+
const xr = () => {
|
|
131
131
|
try {
|
|
132
132
|
return localStorage ? new Dr() : new Ta();
|
|
133
133
|
} catch {
|
|
134
134
|
return console.warn("Local storage was unavilable due to browser security settings. Using in-memory storage instead."), new Ta();
|
|
135
135
|
}
|
|
136
|
-
}, N =
|
|
137
|
-
class
|
|
136
|
+
}, N = xr();
|
|
137
|
+
class Fr {
|
|
138
138
|
constructor() {
|
|
139
139
|
this.defaultServerUrl = "https://api.au.spiffcommerce.com", this.defaultServicesApiUrl = "https://services.au.spiffcommerce.com", this.defaultHubUrl = "https://hub.au.spiffcommerce.com", this.serverUrl = this.defaultServerUrl, this.servicesApiUrl = this.defaultServicesApiUrl, this.hubUrl = this.defaultHubUrl, this.serverUrlCallbacks = [];
|
|
140
140
|
}
|
|
@@ -160,9 +160,9 @@ class xr {
|
|
|
160
160
|
this.serverUrlCallbacks.push(t);
|
|
161
161
|
}
|
|
162
162
|
}
|
|
163
|
-
const mt = new
|
|
163
|
+
const mt = new Fr();
|
|
164
164
|
let ta, ea;
|
|
165
|
-
function
|
|
165
|
+
function Fc(r) {
|
|
166
166
|
ta = r;
|
|
167
167
|
}
|
|
168
168
|
function kc(r) {
|
|
@@ -209,7 +209,7 @@ const un = /* @__PURE__ */ new Map(), Na = /* @__PURE__ */ new Map(), Qa = /* @_
|
|
|
209
209
|
return new DOMParser();
|
|
210
210
|
const r = Xt();
|
|
211
211
|
return new r.DOMParser();
|
|
212
|
-
}, Tr = () => Tt([typeof DOMParser]) ? DOMParser : Xt().DOMParser,
|
|
212
|
+
}, Tr = () => Tt([typeof DOMParser]) ? DOMParser : Xt().DOMParser, Fe = (r, t) => new Promise((e, a) => {
|
|
213
213
|
t ? hn(r).then(e).catch(a) : rt(r).then((n) => {
|
|
214
214
|
n.arrayBuffer().then(e).catch(a);
|
|
215
215
|
}).catch((n) => {
|
|
@@ -228,7 +228,7 @@ const un = /* @__PURE__ */ new Map(), Na = /* @__PURE__ */ new Map(), Qa = /* @_
|
|
|
228
228
|
const n = a.load();
|
|
229
229
|
return Oe.set(t, n), n;
|
|
230
230
|
}
|
|
231
|
-
},
|
|
231
|
+
}, Bt = () => {
|
|
232
232
|
if (Tt([typeof XMLSerializer]))
|
|
233
233
|
return new XMLSerializer();
|
|
234
234
|
const r = Xt();
|
|
@@ -292,24 +292,24 @@ const un = /* @__PURE__ */ new Map(), Na = /* @__PURE__ */ new Map(), Qa = /* @_
|
|
|
292
292
|
}, a.readAsDataURL(r);
|
|
293
293
|
});
|
|
294
294
|
let $r, ma;
|
|
295
|
-
const
|
|
295
|
+
const Lr = (r) => {
|
|
296
296
|
ma = r;
|
|
297
|
-
},
|
|
297
|
+
}, Ur = () => ma;
|
|
298
298
|
let pn;
|
|
299
299
|
const Vr = (r) => {
|
|
300
300
|
pn = r;
|
|
301
|
-
},
|
|
301
|
+
}, Gr = () => new Promise((r) => {
|
|
302
302
|
const t = mt.getHubUrl(), e = (a) => {
|
|
303
303
|
a.origin === t && (window.removeEventListener("message", e), r(a.data));
|
|
304
304
|
};
|
|
305
305
|
window.parent !== window && (window.addEventListener("message", e, !1), window.parent.postMessage("ready", t));
|
|
306
|
-
}),
|
|
306
|
+
}), zr = async () => {
|
|
307
307
|
const r = {
|
|
308
308
|
applicationKey: ma,
|
|
309
309
|
customerToken: $r,
|
|
310
310
|
bearer: pn
|
|
311
311
|
};
|
|
312
|
-
return typeof window < "u" && (window.location.href.includes("/workflows/product/") || window.location.href.includes("hub=true")) ? { ...await
|
|
312
|
+
return typeof window < "u" && (window.location.href.includes("/workflows/product/") || window.location.href.includes("hub=true")) ? { ...await Gr(), ...r } : r;
|
|
313
313
|
};
|
|
314
314
|
async function Wr(r, t) {
|
|
315
315
|
const e = mt.getServerUrl(), a = e.includes(".aumelbdev.spiffcommerce.com") ? "https://moonlight.aumelbdev.spiffcommerce.com" : e.includes(".us.spiffcommerce.com") ? "https://moonlight.us.spiffcommerce.com" : "https://moonlight.au.spiffcommerce.com";
|
|
@@ -333,7 +333,7 @@ class jr {
|
|
|
333
333
|
uri: `${mt.getServerUrl()}/graphql`,
|
|
334
334
|
fetch: Wr
|
|
335
335
|
}), e = dr(async (i, s) => {
|
|
336
|
-
const { headers: o } = s, l = o || {}, c = await
|
|
336
|
+
const { headers: o } = s, l = o || {}, c = await zr();
|
|
337
337
|
let d = s.bearer ?? c.bearer;
|
|
338
338
|
if (this.spiffClient)
|
|
339
339
|
try {
|
|
@@ -368,7 +368,7 @@ class jr {
|
|
|
368
368
|
});
|
|
369
369
|
}
|
|
370
370
|
}
|
|
371
|
-
const
|
|
371
|
+
const B = new jr();
|
|
372
372
|
let aa, na;
|
|
373
373
|
const gt = (r, t, e) => {
|
|
374
374
|
if (aa !== void 0)
|
|
@@ -1814,7 +1814,7 @@ const qr = (r) => new Promise((t) => {
|
|
|
1814
1814
|
"Black 5 C",
|
|
1815
1815
|
"Black 6 C",
|
|
1816
1816
|
"Black 7 C"
|
|
1817
|
-
],
|
|
1817
|
+
], Ft = [
|
|
1818
1818
|
"FEDD00",
|
|
1819
1819
|
"FFD700",
|
|
1820
1820
|
"FE5000",
|
|
@@ -3156,17 +3156,17 @@ const qr = (r) => new Promise((t) => {
|
|
|
3156
3156
|
"3E2B2E",
|
|
3157
3157
|
"101820",
|
|
3158
3158
|
"3D3935"
|
|
3159
|
-
],
|
|
3159
|
+
], Le = Ft.map((r) => [
|
|
3160
3160
|
parseInt(r.substring(0, 2), 16),
|
|
3161
3161
|
parseInt(r.substring(2, 4), 16),
|
|
3162
3162
|
parseInt(r.substring(4, 6), 16)
|
|
3163
3163
|
]);
|
|
3164
3164
|
function Tc(r) {
|
|
3165
3165
|
const t = Yt.indexOf(r);
|
|
3166
|
-
return t >= 0 ?
|
|
3166
|
+
return t >= 0 ? Ft[t] : "";
|
|
3167
3167
|
}
|
|
3168
3168
|
function Kr(r) {
|
|
3169
|
-
const t =
|
|
3169
|
+
const t = Ft.indexOf(r);
|
|
3170
3170
|
return t >= 0 ? Yt[t] : "";
|
|
3171
3171
|
}
|
|
3172
3172
|
function Nc(r, t = 64) {
|
|
@@ -3178,16 +3178,16 @@ function Nc(r, t = 64) {
|
|
|
3178
3178
|
});
|
|
3179
3179
|
const i = parseInt(r.substring(0, 2), 16), s = parseInt(r.substring(2, 4), 16), o = parseInt(r.substring(4, 6), 16);
|
|
3180
3180
|
let l, c, d;
|
|
3181
|
-
for (let A = 0; A <
|
|
3182
|
-
l =
|
|
3181
|
+
for (let A = 0; A < Ft.length; A++) {
|
|
3182
|
+
l = Le[A][0], c = Le[A][1], d = Le[A][2];
|
|
3183
3183
|
const u = Math.sqrt(Math.pow(i - l, 2) + Math.pow(s - c, 2) + Math.pow(o - d, 2));
|
|
3184
3184
|
a.push(u);
|
|
3185
3185
|
}
|
|
3186
3186
|
for (let A = 0; A < a.length; A++)
|
|
3187
|
-
a[A] <= t && !e.some((u) => u.pms === Yt[A]) && e.push({ pms: Yt[A], hex:
|
|
3187
|
+
a[A] <= t && !e.some((u) => u.pms === Yt[A]) && e.push({ pms: Yt[A], hex: Ft[A], distance: a[A] });
|
|
3188
3188
|
return e.sort((A, u) => A.distance - u.distance);
|
|
3189
3189
|
}
|
|
3190
|
-
const _r = Yt.map((r, t) => ({ pms: r, hex:
|
|
3190
|
+
const _r = Yt.map((r, t) => ({ pms: r, hex: Ft[t] })), Xr = new gr(_r, { keys: ["pms"] });
|
|
3191
3191
|
function Qc(r, t) {
|
|
3192
3192
|
return Xr.search(r, t ? { limit: t } : void 0);
|
|
3193
3193
|
}
|
|
@@ -3339,7 +3339,7 @@ const oe = (r) => {
|
|
|
3339
3339
|
}
|
|
3340
3340
|
});
|
|
3341
3341
|
});
|
|
3342
|
-
}, vn = (r) =>
|
|
3342
|
+
}, vn = (r) => Bt().serializeToString(r), fa = (r, t, e, a, n) => {
|
|
3343
3343
|
const i = yn(r);
|
|
3344
3344
|
if (!i)
|
|
3345
3345
|
throw new Error("Failed to read SVG.");
|
|
@@ -3371,7 +3371,7 @@ const oe = (r) => {
|
|
|
3371
3371
|
s.classList.add(A), s.setAttribute("stroke", c.browserValue), a[d] = c;
|
|
3372
3372
|
}
|
|
3373
3373
|
});
|
|
3374
|
-
const i =
|
|
3374
|
+
const i = Bt().serializeToString(e);
|
|
3375
3375
|
return {
|
|
3376
3376
|
colors: a,
|
|
3377
3377
|
svg: i
|
|
@@ -3508,14 +3508,14 @@ const oe = (r) => {
|
|
|
3508
3508
|
...AssetFields
|
|
3509
3509
|
}
|
|
3510
3510
|
}
|
|
3511
|
-
`, ve = async (r) => (await
|
|
3511
|
+
`, ve = async (r) => (await B.getShadowGraphqlClient().query({
|
|
3512
3512
|
query: oi,
|
|
3513
3513
|
errorPolicy: "all",
|
|
3514
3514
|
fetchPolicy: "no-cache",
|
|
3515
3515
|
variables: {
|
|
3516
3516
|
keys: r
|
|
3517
3517
|
}
|
|
3518
|
-
})).data.assets, Ai = async (r) => (await
|
|
3518
|
+
})).data.assets, Ai = async (r) => (await B.getShadowGraphqlClient().query({
|
|
3519
3519
|
query: li,
|
|
3520
3520
|
errorPolicy: "all",
|
|
3521
3521
|
variables: {
|
|
@@ -3523,7 +3523,7 @@ const oe = (r) => {
|
|
|
3523
3523
|
}
|
|
3524
3524
|
})).data.materials, ui = async (r, t, e, a, n) => {
|
|
3525
3525
|
var s;
|
|
3526
|
-
return (s = (await
|
|
3526
|
+
return (s = (await B.getShadowGraphqlClient().mutate({
|
|
3527
3527
|
mutation: ci,
|
|
3528
3528
|
errorPolicy: "all",
|
|
3529
3529
|
fetchPolicy: "no-cache",
|
|
@@ -3642,7 +3642,7 @@ class hi {
|
|
|
3642
3642
|
}
|
|
3643
3643
|
const n = (async () => {
|
|
3644
3644
|
var s, o;
|
|
3645
|
-
const i = await
|
|
3645
|
+
const i = await B.getShadowGraphqlClient().mutate({
|
|
3646
3646
|
mutation: di,
|
|
3647
3647
|
fetchPolicy: "no-cache",
|
|
3648
3648
|
errorPolicy: "all",
|
|
@@ -3678,9 +3678,9 @@ class hi {
|
|
|
3678
3678
|
if (e === "image/svg+xml") {
|
|
3679
3679
|
const a = await t.blob.text(), s = new window.DOMParser().parseFromString(a, "image/svg+xml").documentElement;
|
|
3680
3680
|
if (!s)
|
|
3681
|
-
throw new
|
|
3681
|
+
throw new xt("Failed to read SVG.");
|
|
3682
3682
|
ni(s);
|
|
3683
|
-
const l =
|
|
3683
|
+
const l = Bt().serializeToString(s);
|
|
3684
3684
|
return {
|
|
3685
3685
|
name: t.name,
|
|
3686
3686
|
blob: new Blob([l], { type: "image/svg+xml" })
|
|
@@ -3768,7 +3768,7 @@ const Rt = "persistentAssets", En = class Ct {
|
|
|
3768
3768
|
};
|
|
3769
3769
|
En.callbacks = [];
|
|
3770
3770
|
let It = En;
|
|
3771
|
-
const
|
|
3771
|
+
const La = "bgrmPersistentAssets";
|
|
3772
3772
|
class K {
|
|
3773
3773
|
static has(t) {
|
|
3774
3774
|
return K.getMap().has(t);
|
|
@@ -3795,13 +3795,13 @@ class K {
|
|
|
3795
3795
|
a && (e.delete(a), K.setMap(e));
|
|
3796
3796
|
}
|
|
3797
3797
|
static getMap() {
|
|
3798
|
-
return N.getMap(
|
|
3798
|
+
return N.getMap(La) || /* @__PURE__ */ new Map();
|
|
3799
3799
|
}
|
|
3800
3800
|
static setMap(t) {
|
|
3801
|
-
N.setMap(
|
|
3801
|
+
N.setMap(La, t);
|
|
3802
3802
|
}
|
|
3803
3803
|
}
|
|
3804
|
-
const
|
|
3804
|
+
const L = new hi();
|
|
3805
3805
|
class mi {
|
|
3806
3806
|
constructor() {
|
|
3807
3807
|
this.cache = {}, this.disabled = !1;
|
|
@@ -3833,7 +3833,7 @@ class mi {
|
|
|
3833
3833
|
this.disabled = t;
|
|
3834
3834
|
}
|
|
3835
3835
|
}
|
|
3836
|
-
const Jt = new mi(),
|
|
3836
|
+
const Jt = new mi(), bn = v`
|
|
3837
3837
|
fragment OptionFields on Option {
|
|
3838
3838
|
id
|
|
3839
3839
|
name
|
|
@@ -3873,14 +3873,14 @@ const Jt = new mi(), Bn = v`
|
|
|
3873
3873
|
`, gi = v`
|
|
3874
3874
|
${te(!1)}
|
|
3875
3875
|
${wa}
|
|
3876
|
-
${
|
|
3876
|
+
${bn}
|
|
3877
3877
|
query GetOptions($ids: [String]!) {
|
|
3878
3878
|
options(ids: $ids) {
|
|
3879
3879
|
...OptionFields
|
|
3880
3880
|
}
|
|
3881
3881
|
}
|
|
3882
3882
|
`, pi = async (r) => {
|
|
3883
|
-
const t = await
|
|
3883
|
+
const t = await B.getShadowGraphqlClient().query({
|
|
3884
3884
|
query: gi,
|
|
3885
3885
|
errorPolicy: "all",
|
|
3886
3886
|
variables: {
|
|
@@ -3889,8 +3889,8 @@ const Jt = new mi(), Bn = v`
|
|
|
3889
3889
|
});
|
|
3890
3890
|
return t.data.options.forEach((e) => {
|
|
3891
3891
|
var a, n;
|
|
3892
|
-
(a = e.defaultVariant) != null && a.asset &&
|
|
3893
|
-
i.asset &&
|
|
3892
|
+
(a = e.defaultVariant) != null && a.asset && L.cacheAsset(e.defaultVariant.asset), e.colorProfile && L.cacheAsset(e.colorProfile), (n = e.variants) == null || n.forEach((i) => {
|
|
3893
|
+
i.asset && L.cacheAsset(i.asset), i.thumbnail && L.cacheAsset(i.thumbnail), i.material && L.cacheMaterial(i.material);
|
|
3894
3894
|
});
|
|
3895
3895
|
}), t.data.options;
|
|
3896
3896
|
}, fi = async (r, t) => (await t).find((a) => a.id === r), Ci = async (r) => {
|
|
@@ -3948,7 +3948,7 @@ class wi {
|
|
|
3948
3948
|
}
|
|
3949
3949
|
}
|
|
3950
3950
|
}
|
|
3951
|
-
const Y = new wi(),
|
|
3951
|
+
const Y = new wi(), Bn = v`
|
|
3952
3952
|
fragment ActiveIntegrationFields on Integration {
|
|
3953
3953
|
id
|
|
3954
3954
|
logo
|
|
@@ -4093,7 +4093,7 @@ const Y = new wi(), bn = v`
|
|
|
4093
4093
|
${Te}
|
|
4094
4094
|
${In}
|
|
4095
4095
|
${Pn}
|
|
4096
|
-
${
|
|
4096
|
+
${Bn}
|
|
4097
4097
|
query ReadTransactions($ids: [String]!) {
|
|
4098
4098
|
transactions(ids: $ids) {
|
|
4099
4099
|
customLogoLink
|
|
@@ -4256,7 +4256,7 @@ const Y = new wi(), bn = v`
|
|
|
4256
4256
|
id
|
|
4257
4257
|
}
|
|
4258
4258
|
}
|
|
4259
|
-
`,
|
|
4259
|
+
`, bi = v`
|
|
4260
4260
|
query ReadTransactionForDesignCreation($id: String!) {
|
|
4261
4261
|
transactions(ids: [$id]) {
|
|
4262
4262
|
id
|
|
@@ -4322,7 +4322,7 @@ const Y = new wi(), bn = v`
|
|
|
4322
4322
|
workflowViewerReadOnlyLink
|
|
4323
4323
|
}
|
|
4324
4324
|
}
|
|
4325
|
-
`,
|
|
4325
|
+
`, Bi = v`
|
|
4326
4326
|
${Pn}
|
|
4327
4327
|
query ReadTransactionForShareActions($id: String!) {
|
|
4328
4328
|
transactions(ids: [$id]) {
|
|
@@ -4340,7 +4340,7 @@ const Y = new wi(), bn = v`
|
|
|
4340
4340
|
workflowState
|
|
4341
4341
|
}
|
|
4342
4342
|
}
|
|
4343
|
-
`,
|
|
4343
|
+
`, xn = (r) => v`
|
|
4344
4344
|
${Te}
|
|
4345
4345
|
fragment IntegrationProductFields on IntegrationProduct {
|
|
4346
4346
|
id
|
|
@@ -4424,14 +4424,14 @@ const Y = new wi(), bn = v`
|
|
|
4424
4424
|
}
|
|
4425
4425
|
}
|
|
4426
4426
|
`, Ii = (r) => v`
|
|
4427
|
-
${
|
|
4427
|
+
${xn(r)}
|
|
4428
4428
|
query GetIntegrationProducts($ids: [String!]!) {
|
|
4429
4429
|
integrationProducts(ids: $ids) {
|
|
4430
4430
|
...IntegrationProductFields
|
|
4431
4431
|
}
|
|
4432
4432
|
}
|
|
4433
4433
|
`, Pi = (r) => v`
|
|
4434
|
-
${
|
|
4434
|
+
${xn(r)}
|
|
4435
4435
|
query GetIntegrationProductFromExternalIds($externalIntegrationId: String!, $externalProductId: String!) {
|
|
4436
4436
|
integrationProductFromExternalIds(
|
|
4437
4437
|
externalIntegrationId: $externalIntegrationId
|
|
@@ -4452,11 +4452,11 @@ const Y = new wi(), bn = v`
|
|
|
4452
4452
|
}
|
|
4453
4453
|
}
|
|
4454
4454
|
}
|
|
4455
|
-
`,
|
|
4455
|
+
`, xi = v`
|
|
4456
4456
|
mutation FinalizeUpdateTransaction($transactionId: String!) {
|
|
4457
4457
|
transactionFinalizeUpdate(transactionId: $transactionId)
|
|
4458
4458
|
}
|
|
4459
|
-
`,
|
|
4459
|
+
`, Fi = v`
|
|
4460
4460
|
fragment RegionFields on Region {
|
|
4461
4461
|
width
|
|
4462
4462
|
top
|
|
@@ -4579,8 +4579,8 @@ const Y = new wi(), bn = v`
|
|
|
4579
4579
|
`, Ni = (r) => v`
|
|
4580
4580
|
${te(r)}
|
|
4581
4581
|
${wa}
|
|
4582
|
-
${
|
|
4583
|
-
${
|
|
4582
|
+
${bn}
|
|
4583
|
+
${Fi}
|
|
4584
4584
|
${ki}
|
|
4585
4585
|
${Mi}
|
|
4586
4586
|
${Ti}
|
|
@@ -5100,7 +5100,7 @@ const Y = new wi(), bn = v`
|
|
|
5100
5100
|
}
|
|
5101
5101
|
}
|
|
5102
5102
|
`, $i = v`
|
|
5103
|
-
${
|
|
5103
|
+
${Bn}
|
|
5104
5104
|
${Ne}
|
|
5105
5105
|
query GetCurrentIntegration($themeConfigurationId: String) {
|
|
5106
5106
|
currentIntegration {
|
|
@@ -5112,7 +5112,7 @@ const Y = new wi(), bn = v`
|
|
|
5112
5112
|
...ActiveIntegrationFields
|
|
5113
5113
|
}
|
|
5114
5114
|
}
|
|
5115
|
-
`,
|
|
5115
|
+
`, Li = v`
|
|
5116
5116
|
${Ne}
|
|
5117
5117
|
query ReadTransactionForMarketplaceTheme($id: String!) {
|
|
5118
5118
|
transactions(ids: [$id]) {
|
|
@@ -5121,7 +5121,7 @@ const Y = new wi(), bn = v`
|
|
|
5121
5121
|
}
|
|
5122
5122
|
}
|
|
5123
5123
|
}
|
|
5124
|
-
`,
|
|
5124
|
+
`, Ui = v`
|
|
5125
5125
|
${Ne}
|
|
5126
5126
|
query ReadBundleForMarketplaceTheme($id: String!) {
|
|
5127
5127
|
bundles(ids: [$id]) {
|
|
@@ -5137,7 +5137,7 @@ const Y = new wi(), bn = v`
|
|
|
5137
5137
|
internalId
|
|
5138
5138
|
}
|
|
5139
5139
|
}
|
|
5140
|
-
`,
|
|
5140
|
+
`, Gi = v`
|
|
5141
5141
|
query CurrencyConversion($from: String!, $to: String!) {
|
|
5142
5142
|
currencyConversion(from: $from, to: $to) {
|
|
5143
5143
|
rateFrom
|
|
@@ -5145,7 +5145,7 @@ const Y = new wi(), bn = v`
|
|
|
5145
5145
|
timestamp
|
|
5146
5146
|
}
|
|
5147
5147
|
}
|
|
5148
|
-
`, Ot = [P.SilentIllustration, P.ProductOverlay],
|
|
5148
|
+
`, Ot = [P.SilentIllustration, P.ProductOverlay], zi = async (r) => {
|
|
5149
5149
|
const t = [];
|
|
5150
5150
|
r.introduction && t.push({
|
|
5151
5151
|
name: "Introduction",
|
|
@@ -5234,7 +5234,7 @@ const Y = new wi(), bn = v`
|
|
|
5234
5234
|
);
|
|
5235
5235
|
return i;
|
|
5236
5236
|
};
|
|
5237
|
-
class
|
|
5237
|
+
class Fn {
|
|
5238
5238
|
constructor() {
|
|
5239
5239
|
this.timestamp = Date.now();
|
|
5240
5240
|
}
|
|
@@ -5328,11 +5328,11 @@ const Q = () => {
|
|
|
5328
5328
|
width: u
|
|
5329
5329
|
}) => {
|
|
5330
5330
|
var E;
|
|
5331
|
-
const h = e || 0, m = 2 * ((l == null ? void 0 : l.scale) || 1), g = A || { x: 0, y: 0, width: u, height: i }, p = `${g.x} ${g.y} ${g.width} ${g.height}`, f = Q(), C = a.purpose === qt.FreeDesign && /* @__PURE__ */
|
|
5331
|
+
const h = e || 0, m = 2 * ((l == null ? void 0 : l.scale) || 1), g = A || { x: 0, y: 0, width: u, height: i }, p = `${g.x} ${g.y} ${g.width} ${g.height}`, f = Q(), C = a.purpose === qt.FreeDesign && /* @__PURE__ */ F("defs", { children: /* @__PURE__ */ F("clipPath", { id: "viewboxClip", children: /* @__PURE__ */ F("rect", { width: g.width, height: g.height, rx: h }) }) }), w = (E = a.colorProfiles) == null ? void 0 : E.map((b, I) => (
|
|
5332
5332
|
/* @ts-ignore */
|
|
5333
|
-
/* @__PURE__ */
|
|
5334
|
-
)), S = n.map((
|
|
5335
|
-
...
|
|
5333
|
+
/* @__PURE__ */ F("color-profile", { name: b.name, xlinkHref: b.key, children: " " }, I)
|
|
5334
|
+
)), S = n.map((b) => ({
|
|
5335
|
+
...b,
|
|
5336
5336
|
_renderingConfiguration: a,
|
|
5337
5337
|
mask: l ? `url(#viewmask-${f})` : void 0
|
|
5338
5338
|
})), y = va(S);
|
|
@@ -5357,7 +5357,7 @@ const Q = () => {
|
|
|
5357
5357
|
children: [
|
|
5358
5358
|
w,
|
|
5359
5359
|
C,
|
|
5360
|
-
!!r && /* @__PURE__ */
|
|
5360
|
+
!!r && /* @__PURE__ */ F(
|
|
5361
5361
|
"rect",
|
|
5362
5362
|
{
|
|
5363
5363
|
id: "layout-background",
|
|
@@ -5367,15 +5367,15 @@ const Q = () => {
|
|
|
5367
5367
|
rx: h
|
|
5368
5368
|
}
|
|
5369
5369
|
),
|
|
5370
|
-
/* @__PURE__ */
|
|
5370
|
+
/* @__PURE__ */ F(
|
|
5371
5371
|
"g",
|
|
5372
5372
|
{
|
|
5373
5373
|
id: "element-group",
|
|
5374
5374
|
clipPath: a.purpose === qt.FreeDesign ? "url(#viewboxClip)" : void 0,
|
|
5375
|
-
children: y.map((
|
|
5375
|
+
children: y.map((b) => On(b)).filter((b) => !!b)
|
|
5376
5376
|
}
|
|
5377
5377
|
),
|
|
5378
|
-
l && /* @__PURE__ */
|
|
5378
|
+
l && /* @__PURE__ */ F(
|
|
5379
5379
|
"rect",
|
|
5380
5380
|
{
|
|
5381
5381
|
x: l.x,
|
|
@@ -5389,7 +5389,7 @@ const Q = () => {
|
|
|
5389
5389
|
}
|
|
5390
5390
|
),
|
|
5391
5391
|
l && /* @__PURE__ */ ct("mask", { id: `viewmask-${f}`, children: [
|
|
5392
|
-
/* @__PURE__ */
|
|
5392
|
+
/* @__PURE__ */ F(
|
|
5393
5393
|
"rect",
|
|
5394
5394
|
{
|
|
5395
5395
|
x: g.x,
|
|
@@ -5399,7 +5399,7 @@ const Q = () => {
|
|
|
5399
5399
|
fill: "black"
|
|
5400
5400
|
}
|
|
5401
5401
|
),
|
|
5402
|
-
/* @__PURE__ */
|
|
5402
|
+
/* @__PURE__ */ F(
|
|
5403
5403
|
"rect",
|
|
5404
5404
|
{
|
|
5405
5405
|
x: l.x,
|
|
@@ -5424,22 +5424,22 @@ const Q = () => {
|
|
|
5424
5424
|
}, Oc = (r, t, e) => {
|
|
5425
5425
|
const a = Math.sqrt(Math.pow(t.x - r.x, 2) + Math.pow(t.y - r.y, 2)), n = Math.sqrt(Math.pow(t.x - e.x, 2) + Math.pow(t.y - e.y, 2)), i = Math.sqrt(Math.pow(e.x - r.x, 2) + Math.pow(e.y - r.y, 2));
|
|
5426
5426
|
return Math.acos((n * n + a * a - i * i) / (2 * n * a)) * (180 / Math.PI);
|
|
5427
|
-
}, pt = (r) => r * (Math.PI / 180), $c = (r, t, e) => Math.abs(r - t) < e,
|
|
5427
|
+
}, pt = (r) => r * (Math.PI / 180), $c = (r, t, e) => Math.abs(r - t) < e, Lc = (r, t, e) => {
|
|
5428
5428
|
const a = Math.sin(pt(e)), n = Math.cos(pt(e));
|
|
5429
5429
|
return {
|
|
5430
5430
|
x: (r.x - t.x) * n - (r.y - t.y) * a + t.x,
|
|
5431
5431
|
y: (r.x - t.x) * a + (r.y - t.y) * n + t.y
|
|
5432
5432
|
};
|
|
5433
|
-
},
|
|
5433
|
+
}, Uc = (r, t) => ({
|
|
5434
5434
|
x: (r.x + t.x) / 2,
|
|
5435
5435
|
y: (r.y + t.y) / 2
|
|
5436
5436
|
}), Vc = (r, t, e, a) => ({
|
|
5437
5437
|
x: r.x + (t == null ? void 0 : t.x) * e,
|
|
5438
5438
|
y: r.y + (t == null ? void 0 : t.y) * a
|
|
5439
|
-
}),
|
|
5439
|
+
}), Gc = (r, t, e, a) => ({
|
|
5440
5440
|
x: r.x + ((t == null ? void 0 : t.x) + (t == null ? void 0 : t.width)) * e,
|
|
5441
5441
|
y: r.y + (t == null ? void 0 : t.y) * a
|
|
5442
|
-
}),
|
|
5442
|
+
}), zc = (r, t, e, a) => ({
|
|
5443
5443
|
x: r.x + ((t == null ? void 0 : t.x) + (t == null ? void 0 : t.width)) * e,
|
|
5444
5444
|
y: r.y + ((t == null ? void 0 : t.y) + (t == null ? void 0 : t.height)) * a
|
|
5445
5445
|
}), Pt = (r) => {
|
|
@@ -5493,7 +5493,7 @@ const Q = () => {
|
|
|
5493
5493
|
};
|
|
5494
5494
|
}, qc = 0.352778, Hc = 0.035277, Mn = (r) => {
|
|
5495
5495
|
const t = r.rotation || 0, e = pt(t), a = Math.cos(e), n = -Math.sin(e);
|
|
5496
|
-
return /* @__PURE__ */
|
|
5496
|
+
return /* @__PURE__ */ F("g", { mask: r.stepName || r.productOverlay ? void 0 : r.mask, children: /* @__PURE__ */ F(
|
|
5497
5497
|
"g",
|
|
5498
5498
|
{
|
|
5499
5499
|
transform: `
|
|
@@ -5502,7 +5502,7 @@ const Q = () => {
|
|
|
5502
5502
|
matrix(${a}, ${-n}, ${n}, ${a}, 0, 0)
|
|
5503
5503
|
matrix(1, 0, 0, 1, ${-r.width / 2}, ${-r.height / 2})
|
|
5504
5504
|
`,
|
|
5505
|
-
children: /* @__PURE__ */
|
|
5505
|
+
children: /* @__PURE__ */ F(
|
|
5506
5506
|
"image",
|
|
5507
5507
|
{
|
|
5508
5508
|
xlinkHref: r.src,
|
|
@@ -5516,8 +5516,8 @@ const Q = () => {
|
|
|
5516
5516
|
}, Tn = (r) => {
|
|
5517
5517
|
var l;
|
|
5518
5518
|
const t = `spiff-group-clip-${r.id}`, e = r.rotation || 0, a = pt(e), n = Math.cos(a), i = -Math.sin(a), s = va(r.children);
|
|
5519
|
-
return /* @__PURE__ */ ct(
|
|
5520
|
-
/* @__PURE__ */
|
|
5519
|
+
return /* @__PURE__ */ ct(zt, { children: [
|
|
5520
|
+
/* @__PURE__ */ F("defs", { children: (() => /* @__PURE__ */ F("clipPath", { id: t, preserveAspectRatio: "none", children: r.clipPath ? /* @__PURE__ */ F("path", { d: r.clipPath }) : /* @__PURE__ */ F("rect", { x: 0, y: 0, width: r.width, height: r.height }) }))() }),
|
|
5521
5521
|
/* @__PURE__ */ ct(
|
|
5522
5522
|
"g",
|
|
5523
5523
|
{
|
|
@@ -5528,7 +5528,7 @@ const Q = () => {
|
|
|
5528
5528
|
matrix(1, 0, 0, 1, ${-r.width / 2}, ${-r.height / 2})
|
|
5529
5529
|
`,
|
|
5530
5530
|
children: [
|
|
5531
|
-
(l = r._renderingConfiguration) != null && l.debug ? /* @__PURE__ */
|
|
5531
|
+
(l = r._renderingConfiguration) != null && l.debug ? /* @__PURE__ */ F(
|
|
5532
5532
|
"rect",
|
|
5533
5533
|
{
|
|
5534
5534
|
stroke: "red",
|
|
@@ -5540,7 +5540,7 @@ const Q = () => {
|
|
|
5540
5540
|
height: r.height
|
|
5541
5541
|
}
|
|
5542
5542
|
) : void 0,
|
|
5543
|
-
s.map((c) => On(c)).filter((c) => !!c).map((c) => /* @__PURE__ */
|
|
5543
|
+
s.map((c) => On(c)).filter((c) => !!c).map((c) => /* @__PURE__ */ F("g", { clipPath: `url(#${t})`, children: c }))
|
|
5544
5544
|
]
|
|
5545
5545
|
}
|
|
5546
5546
|
)
|
|
@@ -5556,9 +5556,9 @@ const Q = () => {
|
|
|
5556
5556
|
return r.pattern.src;
|
|
5557
5557
|
};
|
|
5558
5558
|
if (!a())
|
|
5559
|
-
return /* @__PURE__ */
|
|
5560
|
-
const n = () => r.threshold ? r.invertThreshold ? "1 ".repeat(r.threshold) + "0 ".repeat(256 - r.threshold) : "0 ".repeat(r.threshold) + "1 ".repeat(256 - r.threshold) : "", i = () => /* @__PURE__ */
|
|
5561
|
-
/* @__PURE__ */
|
|
5559
|
+
return /* @__PURE__ */ F(zt, {});
|
|
5560
|
+
const n = () => r.threshold ? r.invertThreshold ? "1 ".repeat(r.threshold) + "0 ".repeat(256 - r.threshold) : "0 ".repeat(r.threshold) + "1 ".repeat(256 - r.threshold) : "", i = () => /* @__PURE__ */ F(zt, { children: r.useThreshold && /* @__PURE__ */ F("defs", { children: /* @__PURE__ */ ct("filter", { id: e, "color-interpolation-filters": "sRGB", children: [
|
|
5561
|
+
/* @__PURE__ */ F(
|
|
5562
5562
|
"feColorMatrix",
|
|
5563
5563
|
{
|
|
5564
5564
|
type: "matrix",
|
|
@@ -5572,14 +5572,14 @@ const Q = () => {
|
|
|
5572
5572
|
}
|
|
5573
5573
|
),
|
|
5574
5574
|
/* @__PURE__ */ ct("feComponentTransfer", { in: "greyscale", children: [
|
|
5575
|
-
/* @__PURE__ */
|
|
5576
|
-
/* @__PURE__ */
|
|
5577
|
-
/* @__PURE__ */
|
|
5575
|
+
/* @__PURE__ */ F("feFuncR", { type: "discrete", tableValues: n() }),
|
|
5576
|
+
/* @__PURE__ */ F("feFuncG", { type: "discrete", tableValues: n() }),
|
|
5577
|
+
/* @__PURE__ */ F("feFuncB", { type: "discrete", tableValues: n() })
|
|
5578
5578
|
] })
|
|
5579
5579
|
] }) }) }), s = r.rotation || 0, o = pt(s), l = Math.cos(o), c = -Math.sin(o), d = () => {
|
|
5580
|
-
var w, S, y, E,
|
|
5581
|
-
const A = ((w = r.pattern) == null ? void 0 : w.x) || 0, u = ((S = r.pattern) == null ? void 0 : S.y) || 0, h = ((y = r.pattern) == null ? void 0 : y.width) || 0, m = ((E = r.pattern) == null ? void 0 : E.height) || 0, g = ((
|
|
5582
|
-
return [(
|
|
5580
|
+
var w, S, y, E, b, I, D, x, k, T;
|
|
5581
|
+
const A = ((w = r.pattern) == null ? void 0 : w.x) || 0, u = ((S = r.pattern) == null ? void 0 : S.y) || 0, h = ((y = r.pattern) == null ? void 0 : y.width) || 0, m = ((E = r.pattern) == null ? void 0 : E.height) || 0, g = ((b = r.pattern) == null ? void 0 : b.scaleX) || 1, p = ((I = r.pattern) == null ? void 0 : I.scaleY) || 1, f = ((D = r.pattern) == null ? void 0 : D.rotation) || 0;
|
|
5582
|
+
return [(x = r.pattern) != null && x.svg ? {
|
|
5583
5583
|
id: `${t}-contents`,
|
|
5584
5584
|
type: M.Illustration,
|
|
5585
5585
|
x: A,
|
|
@@ -5601,15 +5601,15 @@ const Q = () => {
|
|
|
5601
5601
|
src: a()
|
|
5602
5602
|
}];
|
|
5603
5603
|
};
|
|
5604
|
-
return /* @__PURE__ */ ct(
|
|
5604
|
+
return /* @__PURE__ */ ct(zt, { children: [
|
|
5605
5605
|
i(),
|
|
5606
|
-
/* @__PURE__ */
|
|
5606
|
+
/* @__PURE__ */ F(
|
|
5607
5607
|
"g",
|
|
5608
5608
|
{
|
|
5609
5609
|
opacity: r.opacity,
|
|
5610
5610
|
mask: r.stepName ? void 0 : r.mask,
|
|
5611
5611
|
filter: r.useThreshold ? `url(#${e})` : void 0,
|
|
5612
|
-
children: /* @__PURE__ */
|
|
5612
|
+
children: /* @__PURE__ */ F(
|
|
5613
5613
|
"g",
|
|
5614
5614
|
{
|
|
5615
5615
|
transform: `
|
|
@@ -5619,7 +5619,7 @@ const Q = () => {
|
|
|
5619
5619
|
matrix(1, 0, 0, 1, ${-r.width / 2}, ${-r.height / 2})
|
|
5620
5620
|
matrix(${r.scaleX}, 0, 0, ${r.scaleY}, 0, 0)
|
|
5621
5621
|
`,
|
|
5622
|
-
children: /* @__PURE__ */
|
|
5622
|
+
children: /* @__PURE__ */ F(
|
|
5623
5623
|
Tn,
|
|
5624
5624
|
{
|
|
5625
5625
|
id: t,
|
|
@@ -5688,9 +5688,9 @@ class Ji {
|
|
|
5688
5688
|
}), a - n;
|
|
5689
5689
|
}
|
|
5690
5690
|
}
|
|
5691
|
-
const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:",
|
|
5692
|
-
if (
|
|
5693
|
-
return
|
|
5691
|
+
const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Ue = /* @__PURE__ */ new Map(), Nt = async (r) => {
|
|
5692
|
+
if (Ue.has(r))
|
|
5693
|
+
return Ue.get(r);
|
|
5694
5694
|
const e = (async () => {
|
|
5695
5695
|
try {
|
|
5696
5696
|
return Et(r).getFont();
|
|
@@ -5699,12 +5699,12 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5699
5699
|
const a = gn(r), n = Xe(a);
|
|
5700
5700
|
return ra(r, n), n;
|
|
5701
5701
|
} else {
|
|
5702
|
-
const a = await
|
|
5702
|
+
const a = await Fe(r, !0), n = Xe(a);
|
|
5703
5703
|
return ra(r, n), await Nr(n, r), n;
|
|
5704
5704
|
}
|
|
5705
5705
|
}
|
|
5706
5706
|
})();
|
|
5707
|
-
return
|
|
5707
|
+
return Ue.set(r, e), e;
|
|
5708
5708
|
}, _i = (r) => {
|
|
5709
5709
|
const t = gn(r), e = Xe(t);
|
|
5710
5710
|
return ra(r, e), e;
|
|
@@ -5741,19 +5741,19 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5741
5741
|
let y = 0;
|
|
5742
5742
|
const E = A.getAttribute("text-anchor");
|
|
5743
5743
|
E === "middle" ? y = S / 2 : E === "end" && (y = S);
|
|
5744
|
-
const
|
|
5744
|
+
const b = g.getPath(
|
|
5745
5745
|
A.innerHTML,
|
|
5746
5746
|
parseFloat(A.getAttribute("x") ?? "0") - y,
|
|
5747
5747
|
parseFloat(A.getAttribute("y") ?? "0"),
|
|
5748
5748
|
parseInt(u.getAttribute("font-size") ?? "72")
|
|
5749
5749
|
);
|
|
5750
|
-
|
|
5751
|
-
const I =
|
|
5752
|
-
h.appendChild(
|
|
5750
|
+
b.fill = p, b.stroke = f, b.strokeWidth = parseFloat(C ?? "0");
|
|
5751
|
+
const I = b.toSVG(2), x = t.parseFromString(I, "image/svg+xml").firstElementChild;
|
|
5752
|
+
h.appendChild(x);
|
|
5753
5753
|
}
|
|
5754
|
-
return e.querySelectorAll("text").forEach((d) => d.remove()),
|
|
5754
|
+
return e.querySelectorAll("text").forEach((d) => d.remove()), Bt().serializeToString(a);
|
|
5755
5755
|
}, Ee = (r, t, e, a) => Math.max(es(r.join(`
|
|
5756
|
-
`), e, a), t),
|
|
5756
|
+
`), e, a), t), Ua = (r, t, e, a, n, i) => {
|
|
5757
5757
|
const s = (i || ya) * n.getApproximateHeight(), o = t.split(`
|
|
5758
5758
|
`);
|
|
5759
5759
|
try {
|
|
@@ -5811,7 +5811,7 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5811
5811
|
var c;
|
|
5812
5812
|
const n = Et(t.fontData.assetUrl), i = n.getFont(), s = t.fontSize / i.unitsPerEm;
|
|
5813
5813
|
if (!e)
|
|
5814
|
-
return
|
|
5814
|
+
return Ua(t, r, t.fontSize, s, n, a);
|
|
5815
5815
|
let o;
|
|
5816
5816
|
if (t.text ? o = t.text.split(`
|
|
5817
5817
|
`) : o = ((c = t.input) == null ? void 0 : c.split(`
|
|
@@ -5828,7 +5828,7 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5828
5828
|
requiredHeight: t.height,
|
|
5829
5829
|
requiredWidth: Ee(o, t.width, s, n),
|
|
5830
5830
|
fontSize: Xi(o, n, i, t.width, t.height, a)
|
|
5831
|
-
} :
|
|
5831
|
+
} : Ua(t, r, t.fontSize, s, n, a);
|
|
5832
5832
|
}, ts = (r, t, e, a, n) => {
|
|
5833
5833
|
const s = Et(t.assetUrl).getFont();
|
|
5834
5834
|
let o = { ...r };
|
|
@@ -5861,7 +5861,7 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5861
5861
|
stripControlCharacters: !0,
|
|
5862
5862
|
vertical: !1,
|
|
5863
5863
|
uppercase: !1
|
|
5864
|
-
},
|
|
5864
|
+
}, be = (r, t = Va) => {
|
|
5865
5865
|
const e = { ...Va, ...t };
|
|
5866
5866
|
let a = r || "";
|
|
5867
5867
|
return e.stripControlCharacters && (a = a.replace(/^(?![\u000A\u000D])[\u0000-\u001F\u007F-\u009F]/g, "")), e.uppercase && (a = a.toUpperCase()), e.vertical && (a = a.split("").join(`
|
|
@@ -5901,9 +5901,9 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5901
5901
|
var w;
|
|
5902
5902
|
return r.textFillImage ? `url("#${s}")` : (w = r._renderingConfiguration) != null && w.spotColors && r.fillSpotColorDefinition ? `${r.fill} ${wn(r.fillSpotColorDefinition)}` : r.fill;
|
|
5903
5903
|
};
|
|
5904
|
-
return /* @__PURE__ */ ct(
|
|
5904
|
+
return /* @__PURE__ */ ct(zt, { children: [
|
|
5905
5905
|
/* @__PURE__ */ ct("defs", { children: [
|
|
5906
|
-
r.textFillImage && /* @__PURE__ */
|
|
5906
|
+
r.textFillImage && /* @__PURE__ */ F(
|
|
5907
5907
|
"pattern",
|
|
5908
5908
|
{
|
|
5909
5909
|
id: s,
|
|
@@ -5912,7 +5912,7 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5912
5912
|
height: r.textFillImage.scale * r.textFillImage.height,
|
|
5913
5913
|
x: 0,
|
|
5914
5914
|
y: 0,
|
|
5915
|
-
children: /* @__PURE__ */
|
|
5915
|
+
children: /* @__PURE__ */ F(
|
|
5916
5916
|
"image",
|
|
5917
5917
|
{
|
|
5918
5918
|
href: r.textFillImage.src,
|
|
@@ -5923,7 +5923,7 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5923
5923
|
)
|
|
5924
5924
|
}
|
|
5925
5925
|
),
|
|
5926
|
-
/* @__PURE__ */
|
|
5926
|
+
/* @__PURE__ */ F(
|
|
5927
5927
|
"style",
|
|
5928
5928
|
{
|
|
5929
5929
|
type: "text/css",
|
|
@@ -5937,10 +5937,10 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5937
5937
|
}
|
|
5938
5938
|
}
|
|
5939
5939
|
),
|
|
5940
|
-
r.curved && r.paths ? /* @__PURE__ */
|
|
5940
|
+
r.curved && r.paths ? /* @__PURE__ */ F("path", { id: i, d: r.paths[0] }) : void 0
|
|
5941
5941
|
] }),
|
|
5942
|
-
(C = r._renderingConfiguration) != null && C.debug ? /* @__PURE__ */
|
|
5943
|
-
/* @__PURE__ */
|
|
5942
|
+
(C = r._renderingConfiguration) != null && C.debug ? /* @__PURE__ */ F("rect", { stroke: "blue", fill: "none", x: r.x, y: r.y, width: r.width, height: r.height }) : void 0,
|
|
5943
|
+
/* @__PURE__ */ F("g", { mask: r.stepName ? void 0 : r.mask, children: /* @__PURE__ */ F("g", { transform: `matrix(${a}, ${-n}, ${n}, ${a}, ${o}, ${l})`, children: /* @__PURE__ */ F(
|
|
5944
5944
|
"text",
|
|
5945
5945
|
{
|
|
5946
5946
|
xmlSpace: "preserve",
|
|
@@ -5955,7 +5955,7 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5955
5955
|
},
|
|
5956
5956
|
stroke: A,
|
|
5957
5957
|
strokeWidth: u,
|
|
5958
|
-
children: r.curved ? /* @__PURE__ */
|
|
5958
|
+
children: r.curved ? /* @__PURE__ */ F(ss, { text: c, curvedPathId: i, align: r.align }) : d.map((w, S) => /* @__PURE__ */ F(
|
|
5959
5959
|
is,
|
|
5960
5960
|
{
|
|
5961
5961
|
align: r.vertical ? "center" : r.align,
|
|
@@ -5986,10 +5986,10 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
5986
5986
|
const s = (r.amountLines - 1) / 2;
|
|
5987
5987
|
return (r.thisLineIdx - s) * n + r.fontSize / 4;
|
|
5988
5988
|
};
|
|
5989
|
-
return /* @__PURE__ */
|
|
5989
|
+
return /* @__PURE__ */ F("tspan", { textAnchor: Rn(r.align), x: e(), y: `${a()}px`, children: r.text });
|
|
5990
5990
|
}, ss = (r) => {
|
|
5991
5991
|
const t = `#${r.curvedPathId}`;
|
|
5992
|
-
return /* @__PURE__ */
|
|
5992
|
+
return /* @__PURE__ */ F(
|
|
5993
5993
|
"textPath",
|
|
5994
5994
|
{
|
|
5995
5995
|
startOffset: (() => r.align === "left" ? "0%" : r.align === "right" ? "100%" : "50%")(),
|
|
@@ -6002,7 +6002,7 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
6002
6002
|
}, os = (r) => {
|
|
6003
6003
|
var s, o;
|
|
6004
6004
|
if (r.cachedObjectURL && !((s = r._renderingConfiguration) != null && s.omitCachedFields))
|
|
6005
|
-
return /* @__PURE__ */
|
|
6005
|
+
return /* @__PURE__ */ F(
|
|
6006
6006
|
Mn,
|
|
6007
6007
|
{
|
|
6008
6008
|
id: r.id,
|
|
@@ -6027,7 +6027,7 @@ const Ki = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Le = /* @_
|
|
|
6027
6027
|
throw new Error(
|
|
6028
6028
|
`Illustration element ${r.id} (stepName ${r.stepName}) lacked svg from src ${r.src} at render time.`
|
|
6029
6029
|
);
|
|
6030
|
-
return /* @__PURE__ */
|
|
6030
|
+
return /* @__PURE__ */ F("g", { mask: r.stepName ? void 0 : r.mask, children: /* @__PURE__ */ F(
|
|
6031
6031
|
"g",
|
|
6032
6032
|
{
|
|
6033
6033
|
transform: i,
|
|
@@ -6135,9 +6135,9 @@ class ls {
|
|
|
6135
6135
|
return { ...t, transaction: e.apply(a) };
|
|
6136
6136
|
}
|
|
6137
6137
|
}
|
|
6138
|
-
const On = (r) => r.type === M.Image ? /* @__PURE__ */
|
|
6138
|
+
const On = (r) => r.type === M.Image ? /* @__PURE__ */ F(Mn, { ...r }, r.id) : r.type === M.Frame ? /* @__PURE__ */ F(Yi, { ...r }, r.id) : r.type === M.Illustration ? /* @__PURE__ */ F(os, { ...r }, r.id) : r.type === M.Textbox ? /* @__PURE__ */ F(rs, { ...r }, r.id) : r.type === M.Group ? /* @__PURE__ */ F(Tn, { ...r }, r.id) : null, Sa = (r, t, e) => {
|
|
6139
6139
|
const a = e.renderingConfiguration, n = a != null && a.removeExcludedElements ? t.filter((i) => !i.excludeFromExport) : t;
|
|
6140
|
-
return /* @__PURE__ */
|
|
6140
|
+
return /* @__PURE__ */ F(
|
|
6141
6141
|
Hi,
|
|
6142
6142
|
{
|
|
6143
6143
|
preserveAspectRatio: void 0,
|
|
@@ -6185,7 +6185,7 @@ const ae = (r) => {
|
|
|
6185
6185
|
if (r.defaultVariant !== void 0)
|
|
6186
6186
|
return t.find((e) => e.id === r.defaultVariant);
|
|
6187
6187
|
}
|
|
6188
|
-
}, At = /* @__PURE__ */ new Map(), Vt = /* @__PURE__ */ new Map(),
|
|
6188
|
+
}, At = /* @__PURE__ */ new Map(), Vt = /* @__PURE__ */ new Map(), Ge = /* @__PURE__ */ new Map(), $n = async (r, t) => {
|
|
6189
6189
|
if (!t) {
|
|
6190
6190
|
if (!r)
|
|
6191
6191
|
throw new Error("No region or src supplied. Cannot construct frame!");
|
|
@@ -6209,8 +6209,8 @@ const ae = (r) => {
|
|
|
6209
6209
|
throw new Error(`No asset for variant with ID: ${r.frameVariantId}`);
|
|
6210
6210
|
return e;
|
|
6211
6211
|
}, Qe = async (r) => {
|
|
6212
|
-
if (
|
|
6213
|
-
return
|
|
6212
|
+
if (Ge.has(r))
|
|
6213
|
+
return Ge.get(r);
|
|
6214
6214
|
const e = (async () => {
|
|
6215
6215
|
if (Vt.has(r))
|
|
6216
6216
|
return Vt.get(r);
|
|
@@ -6246,7 +6246,7 @@ const ae = (r) => {
|
|
|
6246
6246
|
}
|
|
6247
6247
|
throw new Error("Malformed frame SVG");
|
|
6248
6248
|
})();
|
|
6249
|
-
return
|
|
6249
|
+
return Ge.set(r, e), e;
|
|
6250
6250
|
}, Ea = (r, t, e, a) => {
|
|
6251
6251
|
const n = t.width / t.height, i = r.width / r.height;
|
|
6252
6252
|
let s;
|
|
@@ -6262,7 +6262,7 @@ const ae = (r) => {
|
|
|
6262
6262
|
if (At.has(r))
|
|
6263
6263
|
return At.get(r);
|
|
6264
6264
|
if (r.startsWith("data:image/svg+xml")) {
|
|
6265
|
-
const a = Cr(r), n = new TextDecoder().decode(a.buffer), i =
|
|
6265
|
+
const a = Cr(r), n = new TextDecoder().decode(a.buffer), i = Ln(n), s = {
|
|
6266
6266
|
src: r,
|
|
6267
6267
|
width: i.width,
|
|
6268
6268
|
height: i.height,
|
|
@@ -6271,7 +6271,7 @@ const ae = (r) => {
|
|
|
6271
6271
|
return At.set(r, s), s;
|
|
6272
6272
|
}
|
|
6273
6273
|
if ((((e = r.split(".").pop()) == null ? void 0 : e.toLowerCase()) ?? "") === "svg") {
|
|
6274
|
-
const a = await
|
|
6274
|
+
const a = await ba(r), n = a.width, i = a.height, s = {
|
|
6275
6275
|
src: r,
|
|
6276
6276
|
width: n,
|
|
6277
6277
|
height: i,
|
|
@@ -6279,7 +6279,7 @@ const ae = (r) => {
|
|
|
6279
6279
|
};
|
|
6280
6280
|
return At.set(r, s), s;
|
|
6281
6281
|
} else {
|
|
6282
|
-
const a = await
|
|
6282
|
+
const a = await Fe(r, !0), n = await Me(a), i = {
|
|
6283
6283
|
src: r,
|
|
6284
6284
|
width: n.width,
|
|
6285
6285
|
height: n.height,
|
|
@@ -6287,14 +6287,14 @@ const ae = (r) => {
|
|
|
6287
6287
|
};
|
|
6288
6288
|
return At.set(r, i), i;
|
|
6289
6289
|
}
|
|
6290
|
-
},
|
|
6290
|
+
}, ba = async (r) => {
|
|
6291
6291
|
const t = await at(r);
|
|
6292
|
-
return
|
|
6293
|
-
},
|
|
6292
|
+
return Ln(t);
|
|
6293
|
+
}, Ga = (r) => r.endsWith("mm") ? Number(r.replace("mm", "")) * 3.7795275591 : r.endsWith("px") ? Number(r.replace("px", "")) : Number(r), Ln = (r) => {
|
|
6294
6294
|
const a = dt().parseFromString(r, "image/svg+xml").querySelector("svg");
|
|
6295
6295
|
if (!a)
|
|
6296
6296
|
throw new Error("No svg tag found, this svg must be malformed!");
|
|
6297
|
-
const n = a.getAttribute("viewBox"), i = a.getAttribute("width"), s = a.getAttribute("height"), o = s && i ? [0, 0,
|
|
6297
|
+
const n = a.getAttribute("viewBox"), i = a.getAttribute("width"), s = a.getAttribute("height"), o = s && i ? [0, 0, Ga(i), Ga(s)] : n == null ? void 0 : n.split(" ").map((l) => Number(l));
|
|
6298
6298
|
if (!o)
|
|
6299
6299
|
throw new Error("No viewbox or width/height values detected on SVG file!");
|
|
6300
6300
|
return {
|
|
@@ -6304,13 +6304,13 @@ const ae = (r) => {
|
|
|
6304
6304
|
}, $t = (r, t) => {
|
|
6305
6305
|
const e = r.layoutState.elements.filter((n) => n.layer === t), a = Math.max(...e.map((n) => n.layerIndex).filter((n) => n !== void 0));
|
|
6306
6306
|
return Math.max(a, 0) + 1;
|
|
6307
|
-
},
|
|
6307
|
+
}, Un = async (r) => new Promise((t) => {
|
|
6308
6308
|
at(r).then((e) => {
|
|
6309
6309
|
t(e);
|
|
6310
6310
|
}).catch((e) => console.error(e));
|
|
6311
|
-
}),
|
|
6312
|
-
if (
|
|
6313
|
-
return
|
|
6311
|
+
}), ze = /* @__PURE__ */ new Map(), Kt = async (r) => {
|
|
6312
|
+
if (ze.has(r))
|
|
6313
|
+
return ze.get(r);
|
|
6314
6314
|
const t = async (n) => new Promise((i, s) => {
|
|
6315
6315
|
try {
|
|
6316
6316
|
if (!(!!URL && !!URL.createObjectURL))
|
|
@@ -6327,7 +6327,7 @@ const ae = (r) => {
|
|
|
6327
6327
|
const s = dt().parseFromString(r, "image/svg+xml").firstElementChild;
|
|
6328
6328
|
if (!s)
|
|
6329
6329
|
throw new Error("Failed to read SVG");
|
|
6330
|
-
const l =
|
|
6330
|
+
const l = Bt().serializeToString(s), c = gt(), d = c.getContext("2d"), A = await Aa.from(d, l, {
|
|
6331
6331
|
anonymousCrossOrigin: !0,
|
|
6332
6332
|
ignoreDimensions: !1,
|
|
6333
6333
|
createCanvas: gt,
|
|
@@ -6342,8 +6342,8 @@ const ae = (r) => {
|
|
|
6342
6342
|
A.resize(m, m);
|
|
6343
6343
|
return await A.render(), await t(c);
|
|
6344
6344
|
})();
|
|
6345
|
-
return
|
|
6346
|
-
},
|
|
6345
|
+
return ze.set(r, a), a;
|
|
6346
|
+
}, Lt = async (r, t, e, a) => {
|
|
6347
6347
|
const n = r.layoutState.layout.useEditableArea && r.layoutState.layout.editableArea || {
|
|
6348
6348
|
width: r.layoutState.layout.width,
|
|
6349
6349
|
height: r.layoutState.layout.height,
|
|
@@ -6358,14 +6358,14 @@ const ae = (r) => {
|
|
|
6358
6358
|
panelId: r.layoutState.layout.panelId
|
|
6359
6359
|
};
|
|
6360
6360
|
if (e && t === M.Illustration) {
|
|
6361
|
-
const l = await lt(await
|
|
6361
|
+
const l = await lt(await Un(e)), u = dt().parseFromString(l.svg, "image/svg+xml").firstElementChild.getAttribute("viewBox");
|
|
6362
6362
|
if (!u)
|
|
6363
6363
|
throw new Error("SVG missing viewBox.");
|
|
6364
6364
|
const h = o.height, m = u.split(" "), g = parseFloat(m[2]) || 1, p = parseFloat(m[3]) || 1, f = g / p;
|
|
6365
6365
|
o.height = o.width / f, o.top += (h - o.height) / 2;
|
|
6366
6366
|
}
|
|
6367
6367
|
if (e && t === M.Image) {
|
|
6368
|
-
const l = o.height, c = await
|
|
6368
|
+
const l = o.height, c = await Fe(e), d = await Me(c), A = d.width / d.height;
|
|
6369
6369
|
o.height = o.width / A, o.top += (l - o.height) / 2;
|
|
6370
6370
|
}
|
|
6371
6371
|
if (e && t === M.Textbox && (a != null && a.text) && (a != null && a.fontScale)) {
|
|
@@ -6377,7 +6377,7 @@ const ae = (r) => {
|
|
|
6377
6377
|
};
|
|
6378
6378
|
class Jc {
|
|
6379
6379
|
static async getFrame(t, e) {
|
|
6380
|
-
const a = await $n(e.region, e.src), n = await Qe(a), i = e.region || await
|
|
6380
|
+
const a = await $n(e.region, e.src), n = await Qe(a), i = e.region || await Lt(t, M.Frame);
|
|
6381
6381
|
return {
|
|
6382
6382
|
id: Q(),
|
|
6383
6383
|
x: i.left,
|
|
@@ -6403,7 +6403,7 @@ class Jc {
|
|
|
6403
6403
|
};
|
|
6404
6404
|
}
|
|
6405
6405
|
static async getImage(t, e) {
|
|
6406
|
-
const a = e.region || await
|
|
6406
|
+
const a = e.region || await Lt(t, M.Image, e.src);
|
|
6407
6407
|
return {
|
|
6408
6408
|
id: Q(),
|
|
6409
6409
|
src: e.src,
|
|
@@ -6424,10 +6424,10 @@ class Jc {
|
|
|
6424
6424
|
const { configuration: a, fontSrc: n, designInputStep: i } = e, s = await Nt(n), o = {
|
|
6425
6425
|
assetUrl: n,
|
|
6426
6426
|
name: s.names.fullName.en
|
|
6427
|
-
}, l = (i == null ? void 0 : i.text) || a.defaultText || "", c = a.replaceableText ? a.replaceableText.replace("{{}}", l) : l, d =
|
|
6427
|
+
}, l = (i == null ? void 0 : i.text) || a.defaultText || "", c = a.replaceableText ? a.replaceableText.replace("{{}}", l) : l, d = be(c, {
|
|
6428
6428
|
vertical: a.vertical,
|
|
6429
6429
|
uppercase: a.uppercase
|
|
6430
|
-
}), A = e.region || await
|
|
6430
|
+
}), A = e.region || await Lt(t, M.Textbox, n, {
|
|
6431
6431
|
text: d,
|
|
6432
6432
|
fontScale: a.size ? a.size / s.unitsPerEm : void 0
|
|
6433
6433
|
}), u = ee(
|
|
@@ -6493,7 +6493,7 @@ class Jc {
|
|
|
6493
6493
|
</svg>
|
|
6494
6494
|
`, n = {};
|
|
6495
6495
|
n["spiff-fill-shape"] = { browserValue: e.color };
|
|
6496
|
-
const i = e.region || await
|
|
6496
|
+
const i = e.region || await Lt(t, M.Illustration), s = Q();
|
|
6497
6497
|
return {
|
|
6498
6498
|
stepRegion: e.region,
|
|
6499
6499
|
colors: n,
|
|
@@ -6511,7 +6511,7 @@ class Jc {
|
|
|
6511
6511
|
};
|
|
6512
6512
|
}
|
|
6513
6513
|
static async getIllustration(t, e) {
|
|
6514
|
-
const a = e.region || await
|
|
6514
|
+
const a = e.region || await Lt(t, M.Illustration, e.src), n = await lt(await Un(e.src)), i = await Kt(n.svg), s = Q();
|
|
6515
6515
|
return {
|
|
6516
6516
|
cachedObjectURL: i,
|
|
6517
6517
|
stepRegion: e.region,
|
|
@@ -6536,7 +6536,7 @@ class V extends Error {
|
|
|
6536
6536
|
super("Element not found!"), Object.setPrototypeOf(this, V.prototype);
|
|
6537
6537
|
}
|
|
6538
6538
|
}
|
|
6539
|
-
const
|
|
6539
|
+
const U = (r, t) => X(r, t).elements.find((n) => n.id === r), X = (r, t) => {
|
|
6540
6540
|
const e = Object.values(t).find((a) => a.elements.some((n) => n.id === r));
|
|
6541
6541
|
if (!e)
|
|
6542
6542
|
throw new V();
|
|
@@ -6548,7 +6548,7 @@ const L = (r, t) => X(r, t).elements.find((n) => n.id === r), X = (r, t) => {
|
|
|
6548
6548
|
elements: a,
|
|
6549
6549
|
modificationID: Q()
|
|
6550
6550
|
};
|
|
6551
|
-
},
|
|
6551
|
+
}, za = async (r) => {
|
|
6552
6552
|
var a;
|
|
6553
6553
|
const t = [...Object.keys(r.layouts)], e = [...new Set(t)];
|
|
6554
6554
|
for (let n = 0; n < e.length; n++) {
|
|
@@ -6627,7 +6627,7 @@ class Kc extends O {
|
|
|
6627
6627
|
}
|
|
6628
6628
|
apply(t) {
|
|
6629
6629
|
this.oldState = t;
|
|
6630
|
-
const e =
|
|
6630
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6631
6631
|
if (!e.id)
|
|
6632
6632
|
throw new V();
|
|
6633
6633
|
const a = {
|
|
@@ -6650,7 +6650,7 @@ class _c extends O {
|
|
|
6650
6650
|
}
|
|
6651
6651
|
apply(t) {
|
|
6652
6652
|
this.oldState = t;
|
|
6653
|
-
const e =
|
|
6653
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6654
6654
|
if (!e.id)
|
|
6655
6655
|
throw new V();
|
|
6656
6656
|
const a = {
|
|
@@ -6672,7 +6672,7 @@ class Xc extends O {
|
|
|
6672
6672
|
}
|
|
6673
6673
|
apply(t) {
|
|
6674
6674
|
this.oldState = t;
|
|
6675
|
-
const e =
|
|
6675
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6676
6676
|
if (!e.id)
|
|
6677
6677
|
throw new V();
|
|
6678
6678
|
let a = {
|
|
@@ -6723,7 +6723,7 @@ class Vn extends O {
|
|
|
6723
6723
|
};
|
|
6724
6724
|
}
|
|
6725
6725
|
}
|
|
6726
|
-
class
|
|
6726
|
+
class z extends O {
|
|
6727
6727
|
/**
|
|
6728
6728
|
* @param initialParams The initial parameters to be set on this new object
|
|
6729
6729
|
* @param callback An optional callback function to be notified when the object has been instantiated
|
|
@@ -6783,7 +6783,7 @@ class W extends O {
|
|
|
6783
6783
|
return a !== void 0 ? a + 1 : 0;
|
|
6784
6784
|
}
|
|
6785
6785
|
}
|
|
6786
|
-
class
|
|
6786
|
+
class bt extends O {
|
|
6787
6787
|
constructor(t) {
|
|
6788
6788
|
super(), this.id = t;
|
|
6789
6789
|
}
|
|
@@ -6811,7 +6811,7 @@ class ds extends O {
|
|
|
6811
6811
|
}
|
|
6812
6812
|
apply(t) {
|
|
6813
6813
|
this.oldState = t;
|
|
6814
|
-
const e =
|
|
6814
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6815
6815
|
if (!e.id)
|
|
6816
6816
|
throw new V();
|
|
6817
6817
|
const a = {
|
|
@@ -6835,7 +6835,7 @@ class We extends O {
|
|
|
6835
6835
|
}
|
|
6836
6836
|
apply(t) {
|
|
6837
6837
|
this.oldState = t;
|
|
6838
|
-
const e =
|
|
6838
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6839
6839
|
if (!e.id)
|
|
6840
6840
|
throw new V();
|
|
6841
6841
|
const a = {
|
|
@@ -6857,7 +6857,7 @@ class As extends O {
|
|
|
6857
6857
|
}
|
|
6858
6858
|
apply(t) {
|
|
6859
6859
|
this.oldState = t;
|
|
6860
|
-
const e =
|
|
6860
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6861
6861
|
if (!e.id)
|
|
6862
6862
|
throw new V();
|
|
6863
6863
|
const a = {
|
|
@@ -6879,7 +6879,7 @@ class ja extends O {
|
|
|
6879
6879
|
}
|
|
6880
6880
|
apply(t) {
|
|
6881
6881
|
this.oldState = t;
|
|
6882
|
-
const e =
|
|
6882
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6883
6883
|
if (!e.id)
|
|
6884
6884
|
throw new V();
|
|
6885
6885
|
const a = {
|
|
@@ -6901,7 +6901,7 @@ class us extends O {
|
|
|
6901
6901
|
}
|
|
6902
6902
|
apply(t) {
|
|
6903
6903
|
this.oldState = t;
|
|
6904
|
-
const e =
|
|
6904
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6905
6905
|
if (!e.id)
|
|
6906
6906
|
throw new V();
|
|
6907
6907
|
const a = {
|
|
@@ -6959,7 +6959,7 @@ class ms extends O {
|
|
|
6959
6959
|
}
|
|
6960
6960
|
apply(t) {
|
|
6961
6961
|
this.oldState = t;
|
|
6962
|
-
const e =
|
|
6962
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6963
6963
|
if (!e.id)
|
|
6964
6964
|
throw new V();
|
|
6965
6965
|
const a = {
|
|
@@ -6984,7 +6984,7 @@ class Zc extends O {
|
|
|
6984
6984
|
}
|
|
6985
6985
|
apply(t) {
|
|
6986
6986
|
this.oldState = t;
|
|
6987
|
-
const e =
|
|
6987
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
6988
6988
|
if (!e.id)
|
|
6989
6989
|
throw new V();
|
|
6990
6990
|
const a = {
|
|
@@ -7006,7 +7006,7 @@ class gs extends O {
|
|
|
7006
7006
|
}
|
|
7007
7007
|
apply(t) {
|
|
7008
7008
|
this.oldState = t;
|
|
7009
|
-
const e =
|
|
7009
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
7010
7010
|
if (!e.id)
|
|
7011
7011
|
throw new V();
|
|
7012
7012
|
const a = X(e.id, Object.values(t.layouts)), n = Z(ee(e, this.text, e), a);
|
|
@@ -7025,7 +7025,7 @@ class je extends O {
|
|
|
7025
7025
|
}
|
|
7026
7026
|
apply(t) {
|
|
7027
7027
|
this.oldState = t;
|
|
7028
|
-
const e =
|
|
7028
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
7029
7029
|
if (!e.id)
|
|
7030
7030
|
throw new V();
|
|
7031
7031
|
const a = {
|
|
@@ -7048,7 +7048,7 @@ class oa extends O {
|
|
|
7048
7048
|
}
|
|
7049
7049
|
apply(t) {
|
|
7050
7050
|
this.oldState = t;
|
|
7051
|
-
const e =
|
|
7051
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
7052
7052
|
if (!e.id)
|
|
7053
7053
|
throw new V();
|
|
7054
7054
|
const a = e.colors || {}, n = a[this.className];
|
|
@@ -7080,7 +7080,7 @@ class ps extends O {
|
|
|
7080
7080
|
}
|
|
7081
7081
|
apply(t) {
|
|
7082
7082
|
this.oldState = t;
|
|
7083
|
-
const e =
|
|
7083
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
7084
7084
|
if (!e.id)
|
|
7085
7085
|
throw new V();
|
|
7086
7086
|
const a = {
|
|
@@ -7105,7 +7105,7 @@ class td extends O {
|
|
|
7105
7105
|
super(), this.id = t;
|
|
7106
7106
|
}
|
|
7107
7107
|
apply(t) {
|
|
7108
|
-
if (this.oldState = t, !
|
|
7108
|
+
if (this.oldState = t, !U(this.id, Object.values(t.layouts)).id)
|
|
7109
7109
|
throw new V();
|
|
7110
7110
|
const a = Object.values(t.layouts).find((s) => s.elements.find((o) => o.id === this.id));
|
|
7111
7111
|
if (!a)
|
|
@@ -7135,7 +7135,7 @@ class ed extends O {
|
|
|
7135
7135
|
}
|
|
7136
7136
|
apply(t) {
|
|
7137
7137
|
this.oldState = t;
|
|
7138
|
-
const e =
|
|
7138
|
+
const e = U(this.id, Object.values(t.layouts));
|
|
7139
7139
|
if (!e.id)
|
|
7140
7140
|
throw new V();
|
|
7141
7141
|
const a = Object.values(t.layouts).find((o) => o.elements.find((l) => l.id === this.id));
|
|
@@ -7165,7 +7165,7 @@ class ad extends O {
|
|
|
7165
7165
|
super(), this.id = t;
|
|
7166
7166
|
}
|
|
7167
7167
|
apply(t) {
|
|
7168
|
-
if (this.oldState = t, !
|
|
7168
|
+
if (this.oldState = t, !U(this.id, Object.values(t.layouts)).id)
|
|
7169
7169
|
throw new V();
|
|
7170
7170
|
const a = Object.values(t.layouts).find((l) => l.elements.find((c) => c.id === this.id));
|
|
7171
7171
|
if (!a)
|
|
@@ -7192,7 +7192,7 @@ class nd extends O {
|
|
|
7192
7192
|
super(), this.id = t;
|
|
7193
7193
|
}
|
|
7194
7194
|
apply(t) {
|
|
7195
|
-
if (this.oldState = t, !
|
|
7195
|
+
if (this.oldState = t, !U(this.id, Object.values(t.layouts)).id)
|
|
7196
7196
|
throw new V();
|
|
7197
7197
|
const a = Object.values(t.layouts).find((l) => l.elements.find((c) => c.id === this.id));
|
|
7198
7198
|
if (!a)
|
|
@@ -7251,7 +7251,7 @@ class qa {
|
|
|
7251
7251
|
id: h.id,
|
|
7252
7252
|
region: n
|
|
7253
7253
|
},
|
|
7254
|
-
command: new
|
|
7254
|
+
command: new z(h, i)
|
|
7255
7255
|
};
|
|
7256
7256
|
} else {
|
|
7257
7257
|
const u = this.configuration.type === P.SilentIllustration ? (A = this.configuration.data.asset) == null ? void 0 : A.fileLink : s, m = await lt(await (async () => new Promise((p, f) => {
|
|
@@ -7286,7 +7286,7 @@ class qa {
|
|
|
7286
7286
|
id: g.id,
|
|
7287
7287
|
region: n
|
|
7288
7288
|
},
|
|
7289
|
-
command: new
|
|
7289
|
+
command: new z(g, i)
|
|
7290
7290
|
};
|
|
7291
7291
|
}
|
|
7292
7292
|
}, this.configuration = t, this.layouts = e, this.product = a || void 0;
|
|
@@ -7323,10 +7323,10 @@ const fs = async (r) => {
|
|
|
7323
7323
|
}
|
|
7324
7324
|
})).json()).shortUrl;
|
|
7325
7325
|
} catch (e) {
|
|
7326
|
-
throw console.error(e), new
|
|
7326
|
+
throw console.error(e), new xe("Failed to shorten URL, see console.");
|
|
7327
7327
|
}
|
|
7328
7328
|
};
|
|
7329
|
-
class
|
|
7329
|
+
class Gn {
|
|
7330
7330
|
async poll() {
|
|
7331
7331
|
try {
|
|
7332
7332
|
if (await this.predicate()) {
|
|
@@ -7373,7 +7373,7 @@ class Cs {
|
|
|
7373
7373
|
const h = (await ve([e]))[0], m = (p = (g = h == null ? void 0 : h.versions) == null ? void 0 : g.find((f) => f.name === "mpeg4")) == null ? void 0 : p.link;
|
|
7374
7374
|
return { asset: h, link: m };
|
|
7375
7375
|
}, s = await new Promise((h, m) => {
|
|
7376
|
-
new
|
|
7376
|
+
new Gn(
|
|
7377
7377
|
async () => !!(await i()).link,
|
|
7378
7378
|
async () => {
|
|
7379
7379
|
const g = await i();
|
|
@@ -7391,12 +7391,12 @@ class Cs {
|
|
|
7391
7391
|
40
|
|
7392
7392
|
);
|
|
7393
7393
|
});
|
|
7394
|
-
t.forEach((h) => a.getCommandDispatcher()(new
|
|
7394
|
+
t.forEach((h) => a.getCommandDispatcher()(new bt(h.id)));
|
|
7395
7395
|
const o = n.data.baseUrl.slice(0, 4) === "http" ? "" : "https://", l = new URL(o + n.data.baseUrl);
|
|
7396
7396
|
l.searchParams.append("video", btoa(JSON.stringify([s]))), l.pathname = l.pathname + (l.pathname.slice(-1) === "/" ? "" : "/");
|
|
7397
7397
|
const c = l.toString();
|
|
7398
7398
|
if (c.length >= 2e3)
|
|
7399
|
-
throw new
|
|
7399
|
+
throw new xe("Cannot create QR code, URL too long.");
|
|
7400
7400
|
const d = await fs(c);
|
|
7401
7401
|
if (!n.data || !n.data.regions)
|
|
7402
7402
|
throw new Se(n, "Missing regions.");
|
|
@@ -7421,7 +7421,7 @@ class Cs {
|
|
|
7421
7421
|
throw new Error("Region not found");
|
|
7422
7422
|
if (!A || !d)
|
|
7423
7423
|
throw new Error("Neither a region or layout found!");
|
|
7424
|
-
return new
|
|
7424
|
+
return new z(
|
|
7425
7425
|
{
|
|
7426
7426
|
stepRegion: d,
|
|
7427
7427
|
stepName: n,
|
|
@@ -7441,8 +7441,8 @@ class Cs {
|
|
|
7441
7441
|
} };
|
|
7442
7442
|
}
|
|
7443
7443
|
}
|
|
7444
|
-
const
|
|
7445
|
-
class
|
|
7444
|
+
const zn = new Cs();
|
|
7445
|
+
class Be {
|
|
7446
7446
|
constructor() {
|
|
7447
7447
|
this.frameSourceSvg = async (t, e) => {
|
|
7448
7448
|
if (!t)
|
|
@@ -7467,7 +7467,7 @@ class be {
|
|
|
7467
7467
|
const s = e.getWorkflowExperience().getBundle();
|
|
7468
7468
|
if (s && t.globalPropertyAspectConfigurations) {
|
|
7469
7469
|
const o = s.getGlobalPropertyStateManager(), l = t.globalPropertyAspectConfigurations[0], c = o.getAspectStorage(l.aspectName);
|
|
7470
|
-
c && c.originalAssetKey && (i = (await
|
|
7470
|
+
c && c.originalAssetKey && (i = (await L.getLocalOrFromServer(c.originalAssetKey)).fileLink);
|
|
7471
7471
|
}
|
|
7472
7472
|
if (t.option && t.option.variants && t.option.variants.length > 0) {
|
|
7473
7473
|
const o = t.option, l = Y.getDefaultVariant(o);
|
|
@@ -7556,28 +7556,28 @@ class be {
|
|
|
7556
7556
|
}
|
|
7557
7557
|
selectImage(t, e, a, n = !0) {
|
|
7558
7558
|
var l;
|
|
7559
|
-
const i =
|
|
7559
|
+
const i = Be.patternSource(e), s = (l = a.getStepStorage(t.stepName)) == null ? void 0 : l.framePatternSrc;
|
|
7560
7560
|
if (s && s === i)
|
|
7561
7561
|
return Promise.resolve();
|
|
7562
7562
|
a.setEditedStatus(t.stepName, !0);
|
|
7563
7563
|
const o = e.fileLink || "";
|
|
7564
7564
|
return o.endsWith(".pdf") || o.endsWith(".eps") || o.endsWith(".ai") ? new Promise((c) => {
|
|
7565
7565
|
a.addPoller(
|
|
7566
|
-
new
|
|
7566
|
+
new Gn(
|
|
7567
7567
|
async () => {
|
|
7568
7568
|
var h;
|
|
7569
|
-
const A = (h = (await
|
|
7569
|
+
const A = (h = (await L.getFromServer(e.key || "")).versions) == null ? void 0 : h.find((m) => m.name === "svg");
|
|
7570
7570
|
return A ? (await rt(A.link)).status === 200 : !1;
|
|
7571
7571
|
},
|
|
7572
7572
|
() => {
|
|
7573
|
-
|
|
7573
|
+
L.getLocalOrFromServer(e.key || "").then((d) => {
|
|
7574
7574
|
this.loadPatternFromAsset(d, t, a, n).then(
|
|
7575
7575
|
c
|
|
7576
7576
|
);
|
|
7577
7577
|
});
|
|
7578
7578
|
},
|
|
7579
7579
|
() => {
|
|
7580
|
-
throw new
|
|
7580
|
+
throw new xe("Failed to resolve transcoded PDF");
|
|
7581
7581
|
}
|
|
7582
7582
|
)
|
|
7583
7583
|
);
|
|
@@ -7594,7 +7594,7 @@ class be {
|
|
|
7594
7594
|
s && (s.command && n.getCommandDispatcher()(s.command), s.followup && await s.followup());
|
|
7595
7595
|
}
|
|
7596
7596
|
getCreateElementCommand(t, e, a, n) {
|
|
7597
|
-
return new
|
|
7597
|
+
return new z(
|
|
7598
7598
|
{
|
|
7599
7599
|
id: t,
|
|
7600
7600
|
type: M.Frame,
|
|
@@ -7621,7 +7621,7 @@ class be {
|
|
|
7621
7621
|
}
|
|
7622
7622
|
async loadPatternFromString(t, e, a = !0, n = void 0, i) {
|
|
7623
7623
|
if (t.endsWith("svg")) {
|
|
7624
|
-
const s = await
|
|
7624
|
+
const s = await ba(t), o = s.width, l = s.height, c = await at(t);
|
|
7625
7625
|
if (i) {
|
|
7626
7626
|
const u = c.match(/<(image|linearGradient|radialGradient)(\s|>|\/>)/gim);
|
|
7627
7627
|
if (u && u.length > 0)
|
|
@@ -7639,7 +7639,7 @@ class be {
|
|
|
7639
7639
|
};
|
|
7640
7640
|
At.set(t, A), e.setPatternData(A, a);
|
|
7641
7641
|
} else {
|
|
7642
|
-
const s = await
|
|
7642
|
+
const s = await Fe(t, !0), o = await Me(s), l = {
|
|
7643
7643
|
src: t,
|
|
7644
7644
|
width: o.width,
|
|
7645
7645
|
height: o.height,
|
|
@@ -7733,7 +7733,7 @@ class be {
|
|
|
7733
7733
|
i && i(!0);
|
|
7734
7734
|
const c = t.data.initialZoomLevel, d = await Promise.all(
|
|
7735
7735
|
t.data.regions.map(async (m, g) => {
|
|
7736
|
-
const p = await Qe(l[g]), f = o.getImageData(), C = a.map((I) => new
|
|
7736
|
+
const p = await Qe(l[g]), f = o.getImageData(), C = a.map((I) => new bt(I.id)), w = f ? Ea(
|
|
7737
7737
|
f,
|
|
7738
7738
|
p,
|
|
7739
7739
|
c && !t.data.forceImageCover ? { scale: c } : void 0,
|
|
@@ -7748,11 +7748,11 @@ class be {
|
|
|
7748
7748
|
scaleX: (w == null ? void 0 : w.zoom) || 1,
|
|
7749
7749
|
scaleY: (w == null ? void 0 : w.zoom) || 1,
|
|
7750
7750
|
rotation: 0
|
|
7751
|
-
} : void 0, y = Q(),
|
|
7752
|
-
if (!
|
|
7751
|
+
} : void 0, y = Q(), b = n.getLayouts().find((I) => I.panelId === m.panelId);
|
|
7752
|
+
if (!b)
|
|
7753
7753
|
throw new J(m);
|
|
7754
7754
|
return {
|
|
7755
|
-
command: this.getCreateElementCommand(y, m,
|
|
7755
|
+
command: this.getCreateElementCommand(y, m, b, {
|
|
7756
7756
|
frameData: p,
|
|
7757
7757
|
pattern: S,
|
|
7758
7758
|
disablePlaceholder: t.data.disablePlaceholder,
|
|
@@ -7801,7 +7801,7 @@ class be {
|
|
|
7801
7801
|
}
|
|
7802
7802
|
async loadPatternFromAsset(t, e, a, n) {
|
|
7803
7803
|
var c, d;
|
|
7804
|
-
const i =
|
|
7804
|
+
const i = Be.patternSource(t), s = a.markUpdatePending(), o = (c = a.getWorkflowExperience().getStepById(e.stepName)) == null ? void 0 : c.frameService;
|
|
7805
7805
|
if (!o)
|
|
7806
7806
|
throw a.markUpdateCompleted(s), new Error("Frame service unavailable, cannot load pattern!");
|
|
7807
7807
|
try {
|
|
@@ -7828,7 +7828,7 @@ class be {
|
|
|
7828
7828
|
), this.validateColorCount(e, a);
|
|
7829
7829
|
}
|
|
7830
7830
|
}
|
|
7831
|
-
const wt = new
|
|
7831
|
+
const wt = new Be();
|
|
7832
7832
|
class ws {
|
|
7833
7833
|
async getIllustrationBody(t) {
|
|
7834
7834
|
return new Promise((e) => {
|
|
@@ -7838,7 +7838,7 @@ class ws {
|
|
|
7838
7838
|
});
|
|
7839
7839
|
}
|
|
7840
7840
|
getCreateElementCommand(t, e, a, n) {
|
|
7841
|
-
return new
|
|
7841
|
+
return new z(
|
|
7842
7842
|
{
|
|
7843
7843
|
stepRegion: e,
|
|
7844
7844
|
stepName: n.stepName,
|
|
@@ -7865,7 +7865,7 @@ class ws {
|
|
|
7865
7865
|
if (a.length === 0)
|
|
7866
7866
|
return [];
|
|
7867
7867
|
try {
|
|
7868
|
-
return
|
|
7868
|
+
return U(
|
|
7869
7869
|
a[0].id,
|
|
7870
7870
|
e.getAllLayoutData()
|
|
7871
7871
|
).colors;
|
|
@@ -7950,7 +7950,7 @@ class ws {
|
|
|
7950
7950
|
var h, m;
|
|
7951
7951
|
if (e.length === 0)
|
|
7952
7952
|
return;
|
|
7953
|
-
const s =
|
|
7953
|
+
const s = U(
|
|
7954
7954
|
e[0].id,
|
|
7955
7955
|
n().map((g) => g.layoutState)
|
|
7956
7956
|
), o = { ...s.colors }, l = {};
|
|
@@ -7995,7 +7995,7 @@ class ws {
|
|
|
7995
7995
|
if (!t.data || !t.data.regions)
|
|
7996
7996
|
throw new Se(t, "Missing regions.");
|
|
7997
7997
|
n(!0);
|
|
7998
|
-
const s = a.map((C) => new
|
|
7998
|
+
const s = a.map((C) => new bt(C.id));
|
|
7999
7999
|
t.mandatory && i.setMandatoryFulfilled(t.stepName, !1);
|
|
8000
8000
|
const o = e.asset;
|
|
8001
8001
|
if (!o)
|
|
@@ -8040,31 +8040,31 @@ class ws {
|
|
|
8040
8040
|
const C = ((w = o.assetConfiguration) == null ? void 0 : w.defaultColorVariants) || [];
|
|
8041
8041
|
if (C.length !== 0) {
|
|
8042
8042
|
const y = {};
|
|
8043
|
-
(((S = o.assetConfiguration) == null ? void 0 : S.channelNumbers) || []).forEach((
|
|
8043
|
+
(((S = o.assetConfiguration) == null ? void 0 : S.channelNumbers) || []).forEach((b) => {
|
|
8044
8044
|
var D;
|
|
8045
|
-
const I = C.find((
|
|
8046
|
-
I && (y[`${
|
|
8045
|
+
const I = C.find((x) => x.channelNumber === b.number);
|
|
8046
|
+
I && (y[`${b.id.replace(/\W/g, "")}`] = { browserValue: ((D = I == null ? void 0 : I.variant) == null ? void 0 : D.color) || "" });
|
|
8047
8047
|
}), await this.changeColors(
|
|
8048
8048
|
t,
|
|
8049
|
-
u.map((
|
|
8049
|
+
u.map((b) => b.regionElement),
|
|
8050
8050
|
i,
|
|
8051
8051
|
() => i.getCommandContext().getAllLayouts(),
|
|
8052
8052
|
new Map(Object.entries(y))
|
|
8053
8053
|
);
|
|
8054
8054
|
}
|
|
8055
8055
|
if (t.data.colorPickerEnabled) {
|
|
8056
|
-
const y = await this.availableColors(t, i) || [], E = Object.keys(c.colors),
|
|
8057
|
-
if (
|
|
8056
|
+
const y = await this.availableColors(t, i) || [], E = Object.keys(c.colors), b = y.length === 1 && E.length === 1;
|
|
8057
|
+
if (b) {
|
|
8058
8058
|
const I = y[0], D = E[0];
|
|
8059
8059
|
await this.changeColors(
|
|
8060
8060
|
t,
|
|
8061
|
-
u.map((
|
|
8061
|
+
u.map((x) => x.regionElement),
|
|
8062
8062
|
i,
|
|
8063
8063
|
() => i.getCommandContext().getAllLayouts(),
|
|
8064
8064
|
/* @__PURE__ */ new Map([[D, I.variant.color]])
|
|
8065
8065
|
);
|
|
8066
8066
|
}
|
|
8067
|
-
!
|
|
8067
|
+
!b && C.length === 0 && await this.changeColors(
|
|
8068
8068
|
t,
|
|
8069
8069
|
u.map((I) => I.regionElement),
|
|
8070
8070
|
i,
|
|
@@ -8280,8 +8280,8 @@ class vs {
|
|
|
8280
8280
|
if (!p)
|
|
8281
8281
|
return console.error(`Can not find layout for region: ${u.panelId}`), null;
|
|
8282
8282
|
const f = [];
|
|
8283
|
-
return h && f.push(new
|
|
8284
|
-
new
|
|
8283
|
+
return h && f.push(new bt(m)), f.push(
|
|
8284
|
+
new z(
|
|
8285
8285
|
{
|
|
8286
8286
|
stepRegion: u,
|
|
8287
8287
|
stepName: t.stepName,
|
|
@@ -8402,14 +8402,14 @@ class Es {
|
|
|
8402
8402
|
if (!s)
|
|
8403
8403
|
return console.error("No URL for picture!"), null;
|
|
8404
8404
|
n(!0), t.mandatory && a.setMandatoryFulfilled(t.stepName, !1);
|
|
8405
|
-
const l = a.getRegionElements(t.stepName).map((A) => new
|
|
8405
|
+
const l = a.getRegionElements(t.stepName).map((A) => new bt(A.id)), c = (A) => {
|
|
8406
8406
|
const h = a.getLayouts().find((g) => g.panelId === A.panelId);
|
|
8407
8407
|
if (!h)
|
|
8408
8408
|
throw new J(A);
|
|
8409
8409
|
const m = Q();
|
|
8410
8410
|
return {
|
|
8411
8411
|
regionElement: { id: m, region: A },
|
|
8412
|
-
command: new
|
|
8412
|
+
command: new z(
|
|
8413
8413
|
{
|
|
8414
8414
|
stepName: t.stepName,
|
|
8415
8415
|
stepRegion: A,
|
|
@@ -8446,7 +8446,7 @@ class Es {
|
|
|
8446
8446
|
}
|
|
8447
8447
|
}
|
|
8448
8448
|
const Hn = new Es();
|
|
8449
|
-
class
|
|
8449
|
+
class bs {
|
|
8450
8450
|
async init(t, e, a) {
|
|
8451
8451
|
const n = t.option;
|
|
8452
8452
|
if (!n)
|
|
@@ -8504,8 +8504,8 @@ class Bs {
|
|
|
8504
8504
|
};
|
|
8505
8505
|
}
|
|
8506
8506
|
}
|
|
8507
|
-
const Yn = new
|
|
8508
|
-
class
|
|
8507
|
+
const Yn = new bs();
|
|
8508
|
+
class Bs {
|
|
8509
8509
|
constructor() {
|
|
8510
8510
|
this.shapeFillId = "spiff-fill-shape";
|
|
8511
8511
|
}
|
|
@@ -8639,7 +8639,7 @@ class bs {
|
|
|
8639
8639
|
return {
|
|
8640
8640
|
id: C,
|
|
8641
8641
|
region: h,
|
|
8642
|
-
command: new
|
|
8642
|
+
command: new z(
|
|
8643
8643
|
{
|
|
8644
8644
|
stepRegion: h,
|
|
8645
8645
|
stepName: t.stepName,
|
|
@@ -8677,7 +8677,7 @@ class bs {
|
|
|
8677
8677
|
}
|
|
8678
8678
|
}
|
|
8679
8679
|
}
|
|
8680
|
-
const
|
|
8680
|
+
const Gt = new Bs();
|
|
8681
8681
|
class Is {
|
|
8682
8682
|
constructor() {
|
|
8683
8683
|
this.latestToast = null, this.toastType = null, this.toastCallbacks = [];
|
|
@@ -8760,7 +8760,7 @@ class Pe extends Error {
|
|
|
8760
8760
|
super(t), Object.setPrototypeOf(this, new.target.prototype), this.name = Pe.name;
|
|
8761
8761
|
}
|
|
8762
8762
|
}
|
|
8763
|
-
class
|
|
8763
|
+
class xs {
|
|
8764
8764
|
constructor() {
|
|
8765
8765
|
this.cachedColors = /* @__PURE__ */ new Map(), this.cachedStrokeColors = /* @__PURE__ */ new Map(), this.filterUnsupportedCharacters = (t, e) => {
|
|
8766
8766
|
let a = t.replace(
|
|
@@ -8794,12 +8794,14 @@ class Fs {
|
|
|
8794
8794
|
}
|
|
8795
8795
|
async init(t, e, a) {
|
|
8796
8796
|
var i, s, o, l;
|
|
8797
|
+
console.log(`LOG: text step init for ${t.stepTitle} (${t.stepName})`);
|
|
8797
8798
|
const n = t.option;
|
|
8798
8799
|
if (!n)
|
|
8799
8800
|
return null;
|
|
8800
8801
|
if (a)
|
|
8801
|
-
await this.reload(t, e, a);
|
|
8802
|
+
console.log(`LOG: text step init reload (${t.stepName})`), await this.reload(t, e, a);
|
|
8802
8803
|
else {
|
|
8804
|
+
console.log(`LOG: text step init new (${t.stepName})`);
|
|
8803
8805
|
const c = this.getDefaultImageFillVariant(t.data), d = (i = c == null ? void 0 : c.asset) == null ? void 0 : i.fileLink, A = d ? await sa(d) : void 0, u = A ? {
|
|
8804
8806
|
src: A.src,
|
|
8805
8807
|
height: A.height,
|
|
@@ -8814,7 +8816,7 @@ class Fs {
|
|
|
8814
8816
|
if (p && t.globalPropertyAspectConfigurations) {
|
|
8815
8817
|
const C = (s = p.getGlobalPropertyConfiguration()) == null ? void 0 : s.aspects, w = C == null ? void 0 : C.find((S) => {
|
|
8816
8818
|
var y;
|
|
8817
|
-
return S.type ===
|
|
8819
|
+
return S.type === j.Text && ((y = t.globalPropertyAspectConfigurations) == null ? void 0 : y.map((E) => E.aspectName).includes(S.name));
|
|
8818
8820
|
});
|
|
8819
8821
|
if (w) {
|
|
8820
8822
|
const y = p.getGlobalPropertyStateManager().getAspect(w.name);
|
|
@@ -8835,7 +8837,7 @@ class Fs {
|
|
|
8835
8837
|
});
|
|
8836
8838
|
const f = Y.getDefaultVariant(n);
|
|
8837
8839
|
if (f)
|
|
8838
|
-
return this.selectVariantCommand(
|
|
8840
|
+
return console.log(`LOG: text step init default (${t.stepName})`), this.selectVariantCommand(
|
|
8839
8841
|
t,
|
|
8840
8842
|
f,
|
|
8841
8843
|
{ text: g },
|
|
@@ -8849,10 +8851,10 @@ class Fs {
|
|
|
8849
8851
|
m
|
|
8850
8852
|
);
|
|
8851
8853
|
}
|
|
8852
|
-
return null;
|
|
8854
|
+
return console.log(`LOG: text step init end (${t.stepName})`), null;
|
|
8853
8855
|
}
|
|
8854
8856
|
findLayoutElements(t, e) {
|
|
8855
|
-
return t.getRegionElements(e.stepName).map((i) =>
|
|
8857
|
+
return t.getRegionElements(e.stepName).map((i) => U(i.id, t.getAllLayoutData()));
|
|
8856
8858
|
}
|
|
8857
8859
|
/**
|
|
8858
8860
|
* Get the colors that can be used for a given text step.
|
|
@@ -8983,7 +8985,7 @@ class Fs {
|
|
|
8983
8985
|
}
|
|
8984
8986
|
getProcessedInput(t, e, a) {
|
|
8985
8987
|
const n = a ? t : this.injectReplaceableText(t, e);
|
|
8986
|
-
return
|
|
8988
|
+
return be(n, {
|
|
8987
8989
|
vertical: e.vertical,
|
|
8988
8990
|
uppercase: e.uppercase
|
|
8989
8991
|
});
|
|
@@ -9048,21 +9050,23 @@ class Fs {
|
|
|
9048
9050
|
a.serializableWorkflow.steps
|
|
9049
9051
|
), o = Object.values(a.layouts).map((m) => m.elements).flat().filter((m) => m.stepName === t.stepName), l = t.option;
|
|
9050
9052
|
if (n != null && n.selectedVariants) {
|
|
9053
|
+
console.log("LOG: text reload a");
|
|
9051
9054
|
const m = n.selectedVariants[0].id;
|
|
9052
9055
|
if (l && m) {
|
|
9053
9056
|
const g = (c = l.variants) == null ? void 0 : c.find((p) => p.id === m);
|
|
9054
9057
|
if (g) {
|
|
9058
|
+
console.log("LOG: text reload a variant");
|
|
9055
9059
|
const p = await this.fontDataFromVariant(g), f = o.map((y) => ({ id: y.id, region: y.stepRegion })), C = (d = n.storage) == null ? void 0 : d.color;
|
|
9056
9060
|
let w = (A = n.storage) == null ? void 0 : A.text;
|
|
9057
9061
|
const S = e.getWorkflowExperience().getBundle();
|
|
9058
9062
|
if (S && t.globalPropertyAspectConfigurations) {
|
|
9059
|
-
const y = (u = S.getGlobalPropertyConfiguration()) == null ? void 0 : u.aspects, E = y == null ? void 0 : y.find((
|
|
9063
|
+
const y = (u = S.getGlobalPropertyConfiguration()) == null ? void 0 : u.aspects, E = y == null ? void 0 : y.find((b) => {
|
|
9060
9064
|
var I;
|
|
9061
|
-
return
|
|
9065
|
+
return b.type === j.Text && ((I = t.globalPropertyAspectConfigurations) == null ? void 0 : I.map((D) => D.aspectName).includes(b.name));
|
|
9062
9066
|
});
|
|
9063
9067
|
if (E) {
|
|
9064
9068
|
const I = S.getGlobalPropertyStateManager().getAspect(E.name);
|
|
9065
|
-
I && (w = I);
|
|
9069
|
+
I && (console.log("LOG: text reload a variant found aspect text"), w = I);
|
|
9066
9070
|
}
|
|
9067
9071
|
}
|
|
9068
9072
|
if (await e.setSelectionsAndElements(
|
|
@@ -9071,10 +9075,11 @@ class Fs {
|
|
|
9071
9075
|
f,
|
|
9072
9076
|
async () => {
|
|
9073
9077
|
e.updateMetadata(t.stepName, { color: C, text: w }), e.updateStorage(t.stepName, { text: w, inputText: w });
|
|
9074
|
-
const y = o.map((
|
|
9078
|
+
const y = o.map((b) => new ja(b.id, p)), E = new $(y);
|
|
9075
9079
|
e.getCommandDispatcher()(E);
|
|
9076
9080
|
}
|
|
9077
9081
|
), o.length === 0 && l) {
|
|
9082
|
+
console.log("LOG: text reload a variant no elements");
|
|
9078
9083
|
const y = Y.getDefaultVariant(l);
|
|
9079
9084
|
if (y) {
|
|
9080
9085
|
const E = await this.selectVariantCommand(
|
|
@@ -9091,7 +9096,8 @@ class Fs {
|
|
|
9091
9096
|
e.getCommandDispatcher()(E.command);
|
|
9092
9097
|
}
|
|
9093
9098
|
} else {
|
|
9094
|
-
|
|
9099
|
+
console.log("LOG: text reload a variant yes elements");
|
|
9100
|
+
const { command: y } = W.updateInputText(
|
|
9095
9101
|
w || "",
|
|
9096
9102
|
o,
|
|
9097
9103
|
t,
|
|
@@ -9102,16 +9108,18 @@ class Fs {
|
|
|
9102
9108
|
}
|
|
9103
9109
|
}
|
|
9104
9110
|
} else {
|
|
9111
|
+
console.log("LOG: text reload b");
|
|
9105
9112
|
const m = e.getWorkflowExperience().getBundle();
|
|
9106
9113
|
if (m && t.globalPropertyAspectConfigurations) {
|
|
9107
9114
|
const g = (h = m.getGlobalPropertyConfiguration()) == null ? void 0 : h.aspects, p = g == null ? void 0 : g.find((f) => {
|
|
9108
9115
|
var C;
|
|
9109
|
-
return f.type ===
|
|
9116
|
+
return f.type === j.Text && ((C = t.globalPropertyAspectConfigurations) == null ? void 0 : C.map((w) => w.aspectName).includes(f.name));
|
|
9110
9117
|
});
|
|
9111
9118
|
if (p) {
|
|
9112
9119
|
const C = m.getGlobalPropertyStateManager().getAspect(p.name);
|
|
9113
9120
|
if (C)
|
|
9114
9121
|
if (o.length === 0 && l) {
|
|
9122
|
+
console.log("LOG: text reload a variant no elements");
|
|
9115
9123
|
const w = Y.getDefaultVariant(l);
|
|
9116
9124
|
if (w) {
|
|
9117
9125
|
const S = await this.selectVariantCommand(
|
|
@@ -9128,7 +9136,8 @@ class Fs {
|
|
|
9128
9136
|
e.getCommandDispatcher()(S.command);
|
|
9129
9137
|
}
|
|
9130
9138
|
} else {
|
|
9131
|
-
|
|
9139
|
+
console.log("LOG: text reload a variant yes elements");
|
|
9140
|
+
const { command: w } = W.updateInputText(
|
|
9132
9141
|
C,
|
|
9133
9142
|
o,
|
|
9134
9143
|
t,
|
|
@@ -9298,7 +9307,7 @@ class Fs {
|
|
|
9298
9307
|
curved: a.curved,
|
|
9299
9308
|
paths: a.paths,
|
|
9300
9309
|
fillSpotColorDefinition: f
|
|
9301
|
-
}, y = [], E = /* @__PURE__ */ new Map(),
|
|
9310
|
+
}, y = [], E = /* @__PURE__ */ new Map(), b = /* @__PURE__ */ new Map();
|
|
9302
9311
|
if (!S.fontData)
|
|
9303
9312
|
throw new G("Failed to resolve font data for text.");
|
|
9304
9313
|
const [I, D] = pe(
|
|
@@ -9315,13 +9324,13 @@ class Fs {
|
|
|
9315
9324
|
[l],
|
|
9316
9325
|
{ size: a.size, minSize: a.minSize, maxSize: a.maxSize }
|
|
9317
9326
|
);
|
|
9318
|
-
E.set(S.id, I),
|
|
9319
|
-
const
|
|
9327
|
+
E.set(S.id, I), b.set(S.id, D);
|
|
9328
|
+
const x = a.curved || a.vertical ? l : (D || []).join(`
|
|
9320
9329
|
`);
|
|
9321
9330
|
y.push(
|
|
9322
|
-
this.generateTextChangeCommandsForRegion(I, a, S.id,
|
|
9331
|
+
this.generateTextChangeCommandsForRegion(I, a, S.id, x)
|
|
9323
9332
|
);
|
|
9324
|
-
const k = new
|
|
9333
|
+
const k = new z(S, h);
|
|
9325
9334
|
return {
|
|
9326
9335
|
regionElement: { id: m, region: A },
|
|
9327
9336
|
commands: [k, ...y],
|
|
@@ -9376,13 +9385,13 @@ class Fs {
|
|
|
9376
9385
|
return d && d(!0), { info: "0" };
|
|
9377
9386
|
const S = s.getProfanities(), y = Ze(u.toLowerCase());
|
|
9378
9387
|
for (const E of y)
|
|
9379
|
-
for (const
|
|
9380
|
-
const I = S[
|
|
9388
|
+
for (const b in S) {
|
|
9389
|
+
const I = S[b].toLowerCase().replace(/\s/g, "");
|
|
9381
9390
|
if (E === I)
|
|
9382
9391
|
return l(!0), { error: "Blocked profanity." };
|
|
9383
9392
|
}
|
|
9384
9393
|
return !t.data.vertical && !t.data.allowNewlines && (u.includes(`
|
|
9385
|
-
`) || u.includes("\r")) ? (l(!0), { error: "Cannot span multiple lines." }) : !t.data.curved && !Array.from(g.values()).every((
|
|
9394
|
+
`) || u.includes("\r")) ? (l(!0), { error: "Cannot span multiple lines." }) : !t.data.curved && !Array.from(g.values()).every((b) => b) ? (l(!0), { error: "Does not fit." }) : (l(!1), { info: (t.data.maxLength - u.length).toString() });
|
|
9386
9395
|
})();
|
|
9387
9396
|
if (f.error) {
|
|
9388
9397
|
c(f.error);
|
|
@@ -9409,8 +9418,8 @@ class Fs {
|
|
|
9409
9418
|
return new $(C);
|
|
9410
9419
|
}
|
|
9411
9420
|
}
|
|
9412
|
-
const
|
|
9413
|
-
class
|
|
9421
|
+
const W = new xs();
|
|
9422
|
+
class Fs {
|
|
9414
9423
|
}
|
|
9415
9424
|
const ks = "data:application/octet-stream;base64,AAEAAAAPAIAAAwBwRkZUTYdHeHoAAElcAAAAHEdERUYAJwBUAAAe2AAAAB5HUE9TkNtcVAAAHygAACoyR1NVQrj/uP4AAB74AAAAME9TLzJoWmUcAAABeAAAAGBjbWFwtkIacAAAAxAAAAJWZ2FzcP//AAMAAB7QAAAACGdseWY27KOUAAAGCAAAFcRoZWFkFPal0gAAAPwAAAA2aGhlYQU0Ar0AAAE0AAAAJGhtdHiADw6qAAAB2AAAAThsb2Nh5CzfJAAABWgAAACebWF4cACVAEwAAAFYAAAAIG5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Ax/90AMv/EADP/6wA0/+EANf/wADb/8AA4/9wAOf/dADr/7AA7/9gAPP/sAD3/5wA+/+wAP//iAED/0wBB/+IAQv/YAEP/4gBE/84ARf/JAEb/4gBH/8kASP/OAEn/vwBK/8kAS//TACwABv/7AAf/3wAI/+cACf+wAAr/4wAL/8kADP/dAA3/xwAO/+cAD//dABD/7AAR/+cAEv/iABP/yQAU/9cAFf+/ABb/4gAa/+kAMf/YADL/uwAz/+EANP/dADb/6wA3//MAOP/lADn/8QA6//IAO//eADz/5wA9/+4APv/zAD//8ABA/+IAQf/2AEL/6gBD//YARP/kAEX/zABG/+8AR/+0AEj/uwBJ/64ASv+vAEv/5QAsAAb/+wAH/90ACP/nAAn/4gAK/9MAC//nAAz/3QAN//YADv/eAA//3QAQ/7AAEf/OABL/sAAT//sAFP/dABX/0wAW/9MAMf/iADL/iAAz//YANP/OADX/9gA2//EAN//xADj/0wA5//YAOv/zADv/gAA8//EAPf/7AD7/+wA///YAQP/OAEH/7gBC/84AQ//2AET/2ABF//sARv/2AEf/5wBI/+cASf/TAEr/4gBL/+wALAAG//sAB//2AAj/8QAJ/9gACv/nAAv/3QAM/+IADf/dAA7/4gAP/+IAEP/nABH/5wAS/9gAE//YABT/3QAV/84AFv/sADH/5wAy/78AM//nADT/2AA1/+cANv/nADf/7AA4/90AOf/sADr/7AA7/+cAPP/sAD3/8QA+/+wAP//xAED/4gBB//EAQv/dAEP/5wBE/+IARf/YAEb/5wBH/78ASP/HAEn/sABK/7UAS//dACsABv/xAAf/8QAI/+IACf/dAAr/0wAL/+IADP/iAA3/3QAO/+cAD//dABD/zgAR/9MAEv/EABP/0wAU/84AFv/dADH/4gAy/6EAM//jADT/3QA1/+wANv/sADf/5wA4/90AOf/nADr/8QA7/78APP/xAD3/9gA+/+wAP//nAED/3QBB/+cAQv/nAEP/5wBE/+IARf/OAEb/3QBH/8QASP/JAEn/lwBK/7oAS//YACkABv/sAAf/0wAI/90ACf/OAAr/3QAM/90ADf/EAA7/5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ANP/zADX/+wA2//4AN//+ADj/+QA7/+4APf/+AD7/+wA///4AQP/2AEH/+gBC/+4AQ//7AET/+QBF//sARv/+AEf/8wBI/+8ASf/zAEr/6wBL//4AHQAG//EAJP/3ADH/7AAy/7sAM//sADT/4wA1/+8ANv/vADf/9wA4/+QAOf/qADr/9wA7/98APP/vAD3/9wA+/+sAP//uAED/4wBB/+4AQv/mAEP/7wBE/+IARf/VAEb/7gBH/8MASP/GAEn/uwBK/7oAS//fABwABv/sACT//gAy/54AM//rADT/6gA1//EANv/rADf/9wA4/+MAOf/oADr/9wA7/64APP/sAD3/8QA+/+wAP//sAED/4QBB//MAQv/oAEP/5ABE/9gARf/kAEb/7gBH/9EASP/QAEn/uwBK/8QAS//zADAAF//3ABj//wAZ/+kAGv//ABv//QAc//4AHf/pAB7/+wAf//8AIP/iACH//gAi//8AI//+ACT//wAl/+IAJ//uACj//gAp/+cAKv/hACv/+QAs/8MALf/QAC7/5AAv/8wAMP//ADL/4QAz//4ANP/jADX/9wA3//kAOP/fADn/9wA7/+IAPP/5AD3/+gA+//EAP//6AED/2gBB/+8AQv/aAET/7wBF/9cARv/qAEf/xgBI/7sASf/qAEr/tABL//sAHQAG/+cAF//oACT/+gAy/+IAM//xADT/zAA1/+8ANv/sADf/+gA4/8wAOf/3ADr/8wA7/8kAPP/uAD3/7wA+/+wAP//rAED/yQBB//cAQv/MAEP/+ABE/9QARf/KAEb/2gBH/8EASP/EAEn/4gBK/7cAS//vAB0ABv/xABv/+QAl/+4AMv+8ADP/7wA0/9wANf/zADb/6AA3//cAOP/hADn/5gA6//MAO//aADz/6QA9//MAPv/pAD//6wBA/+MAQf/3AEL/2gBD/+kARP/rAEX/1ABG/+kAR//JAEj/zABJ/7QASv+7AEv/5wAbAAb/9gAy/6YAM//9ADT/0wA1//oANv/+ADf//QA4/9UAOf/3ADr//wA7/7kAPP/6AD3//gA+//sAP//7AED/0ABB//oAQv/XAEP/+QBE/+IARf/zAEb/9wBH/+8ASP/vAEn/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ASv+6AEv/6AAmAAf/9gAI//EACf/sAAr/9gAM/+cADv/6AA//8QAQ//EAEf/vABL/4QAT//EAFP/iABX/5wAy/+kAM//9ADT/5wA1//sANv/9ADf//gA4/+sAOf/+ADoAAQA7/+gAPP/9AD3/9wA+//0AP//9AED/6wBBAAEAQv/pAEP/+QBE/+wARgACAEf/6QBI/+8ASf/nAEr/6wBL//sAKQAH//sACP/xAAn/5wAK/+4AC//2AAz/4gAN//sADv/1AA//8QAQ/90AEf/kABL/4gAT/+wAFP/YABX/3QAx//YAMv+5ADP/+AA0/+MANf/3ADb/+AA3//kAOP/iADn/+gA6//0AO//OADz//QA9//4APv/5AD///ABA/+YAQv/jAEP/9wBE/+YARf/vAEb//gBH/+cASP/vAEn/0QBK/+YAS//9ACgAB//2AAj/4gAJ/90ACv/sAAv/4gAM/+gADf/iAA7/9QAP/+gAEP/dABH/4AAS/+YAE//OABT/4gAV/90AJP/7ADH/9gAy/8EAM//vADT/3wA2//QAN//4ADj/4wA5/+kAOv/6ADv/0QA8/+YAPf/zAD7/6QA///EAQP/qAEL/3ABD/+gARP/fAEb/+ABH/7sASP+7AEn/rwBK/68AS//jACcACP/xAAn/7AAK//gADP/2AA7/9wAP//YAEP/xABH/5wAS/+cAE//xABT/7AAV/+UAMf/2ADL/6AAz//kANP/qADX/+wA2//oAN//7ADj/6wA5//cAOv//ADv/4wA8//sAPf/+AD7/+wA///oAQP/sAEH/+gBC/+MAQ//5AET/7wBF/+oARv/7AEf/4wBI/+wASf/jAEr/6gBL//4AJgAH//sACP/7AAn/5wAK//oADP/2AA7/9gAP//YAEP/xABH/8QAS//IAE//xABT/5wAV//EAMv/nADP/+wA0//EANf/9ADb//gA3//4AOP/uADn/+wA6//4AO//oAD0AAAA+//sAP//+AED/7wBB//4AQv/qAEP//wBE//EARf/3AEb/+wBH/+YASP/3AEn/2gBK/+QAS//7ACkAB//2AAj/9gAJ/90ACv/yAAz/8QAO//EAD//wABD/6gAR/+wAEv/mABP/9AAU/+w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AsAAf/yQAI/84ACf/JAAr/wgAL/8kADP/JAA3//gAO/8kAD/+6ABD/jQAR/7oAEv+gABP/4gAU/7UAFf+6AB7/8QAk//sAMf+1ADL/lwAz/+8ANP+7ADX/5gA2/+4AN//uADj/uQA5/+gAOv/3ADv/hAA8/+8APf/sAD7/7AA//+oAQP+6AEH/7ABC/7kAQ//pAET/ygBF/+8ARv/vAEf/6ABI/+kASf/fAEr/5ABL//EAJgAH//YACf/iAAr/7AAL/+cADP/iAA3//wAO//UAD//nABD/7AAR/+IAEv/gABP/7AAU/90AFf/TADH/4gAy/+sAM//+ADT/6AA1//4ANgAEADf//wA4/9wAOf/6ADv/5gA8//8APf//AD///QBA/+MAQf//AEMAAABE/+8ARf/4AEb/+wBH//cASP/rAEn/6QBK/+kAS//9AAIAAQAGAEsAAAAAAAAAAQAAAADUGBYRAAAAANmXsTQAAAAA2ZexNA==", et = (r) => Mr("http://www.w3.org/2000/svg", r), Ms = (r, t) => {
|
|
9416
9425
|
const e = et("rect");
|
|
@@ -9487,7 +9496,7 @@ class Os {
|
|
|
9487
9496
|
u = (A * 100 | 0) / 100;
|
|
9488
9497
|
break;
|
|
9489
9498
|
default:
|
|
9490
|
-
throw new
|
|
9499
|
+
throw new xt("Failed to encode path.");
|
|
9491
9500
|
}
|
|
9492
9501
|
l || s.push(" "), s.push(u), l = !1;
|
|
9493
9502
|
}
|
|
@@ -9501,12 +9510,12 @@ class Os {
|
|
|
9501
9510
|
for (e.lastIndex = 0; i = e.exec(t); ) {
|
|
9502
9511
|
const s = i[1].toLowerCase(), o = (i[2].match(a) || []).map(parseFloat), l = s === i[1], c = Ha[s];
|
|
9503
9512
|
if (o.length < c.length)
|
|
9504
|
-
throw new
|
|
9513
|
+
throw new xt(
|
|
9505
9514
|
`Path type "${s}" given ${o.length} arguments, expected ${c.length}.`
|
|
9506
9515
|
);
|
|
9507
9516
|
if (c.length > 0) {
|
|
9508
9517
|
if (o.length % c.length !== 0)
|
|
9509
|
-
throw new
|
|
9518
|
+
throw new xt(
|
|
9510
9519
|
`Path type "${s}" given ${o.length} arguments, not divisible by ${c.length}`
|
|
9511
9520
|
);
|
|
9512
9521
|
for (let d = 0; d < o.length / c.length; d++) {
|
|
@@ -9531,7 +9540,7 @@ class Os {
|
|
|
9531
9540
|
if (o in i && l in i) {
|
|
9532
9541
|
const c = [i[o], i[l]], d = e(c);
|
|
9533
9542
|
if (d.length < 2)
|
|
9534
|
-
throw new
|
|
9543
|
+
throw new xt("Transformer must return at least 2 points.");
|
|
9535
9544
|
i[o] = d[0], i[l] = d[1];
|
|
9536
9545
|
}
|
|
9537
9546
|
}
|
|
@@ -9554,7 +9563,7 @@ class Os {
|
|
|
9554
9563
|
}
|
|
9555
9564
|
}
|
|
9556
9565
|
}
|
|
9557
|
-
class $s extends
|
|
9566
|
+
class $s extends Fs {
|
|
9558
9567
|
constructor() {
|
|
9559
9568
|
super(...arguments), this.moduleName = "Vegemite";
|
|
9560
9569
|
}
|
|
@@ -9574,8 +9583,8 @@ class $s extends xs {
|
|
|
9574
9583
|
y.setAttribute("d", d), y.setAttribute("stroke", "black"), y.setAttribute("stroke-width", "3"), S.appendChild(y);
|
|
9575
9584
|
const E = et("g");
|
|
9576
9585
|
E.classList.add("module-layer0"), w.appendChild(E), E.setAttribute("filter", "url(#shadow)"), E.innerHTML = y.outerHTML;
|
|
9577
|
-
const
|
|
9578
|
-
|
|
9586
|
+
const b = et("g");
|
|
9587
|
+
b.classList.add("module-layer1"), w.appendChild(b), b.setAttribute("stroke-width", "3"), b.setAttribute("stroke", "rgb(45,41,38)"), b.setAttribute("fill", "rgb(45,41,38)"), b.setAttribute("transform", "translate(0.5,0)"), b.innerHTML = o;
|
|
9579
9588
|
const I = et("g");
|
|
9580
9589
|
I.classList.add("module-layer2"), w.appendChild(I), I.setAttribute("fill", "rgb(255,209,0)"), I.setAttribute("transform", "translate(1,-0.1)"), I.innerHTML = o;
|
|
9581
9590
|
const D = et("g");
|
|
@@ -9623,7 +9632,7 @@ const ne = v`
|
|
|
9623
9632
|
}
|
|
9624
9633
|
}
|
|
9625
9634
|
}
|
|
9626
|
-
`,
|
|
9635
|
+
`, Ls = v`
|
|
9627
9636
|
${ne}
|
|
9628
9637
|
mutation CreateGlobalPropertyState($bundleId: String!) {
|
|
9629
9638
|
globalPropertyStateCreate(bundleId: $bundleId) {
|
|
@@ -9633,7 +9642,7 @@ const ne = v`
|
|
|
9633
9642
|
}
|
|
9634
9643
|
}
|
|
9635
9644
|
}
|
|
9636
|
-
`,
|
|
9645
|
+
`, Us = v`
|
|
9637
9646
|
${ne}
|
|
9638
9647
|
mutation UpdateGlobalPropertyState($id: String!, $aspects: [GlobalPropertyStateAspectInput]!) {
|
|
9639
9648
|
globalPropertyStateUpdate(id: $id, aspects: $aspects) {
|
|
@@ -9653,14 +9662,14 @@ const ne = v`
|
|
|
9653
9662
|
}
|
|
9654
9663
|
}
|
|
9655
9664
|
}
|
|
9656
|
-
`, rd = async (r) => (await
|
|
9665
|
+
`, rd = async (r) => (await B.getShadowGraphqlClient().query({
|
|
9657
9666
|
query: Vs,
|
|
9658
9667
|
fetchPolicy: "cache-first",
|
|
9659
9668
|
errorPolicy: "all",
|
|
9660
9669
|
variables: {
|
|
9661
9670
|
bundleId: r
|
|
9662
9671
|
}
|
|
9663
|
-
})).data.globalPropertyState,
|
|
9672
|
+
})).data.globalPropertyState, Gs = v`
|
|
9664
9673
|
${Te}
|
|
9665
9674
|
fragment ProductFields on Product {
|
|
9666
9675
|
id
|
|
@@ -9705,8 +9714,8 @@ const ne = v`
|
|
|
9705
9714
|
name
|
|
9706
9715
|
}
|
|
9707
9716
|
}
|
|
9708
|
-
`,
|
|
9709
|
-
${
|
|
9717
|
+
`, Ba = v`
|
|
9718
|
+
${Gs}
|
|
9710
9719
|
fragment ProductCollectionProductFields on ProductCollectionProduct {
|
|
9711
9720
|
id
|
|
9712
9721
|
productId
|
|
@@ -9716,7 +9725,7 @@ const ne = v`
|
|
|
9716
9725
|
}
|
|
9717
9726
|
}
|
|
9718
9727
|
`, re = (r) => v`
|
|
9719
|
-
${r ?
|
|
9728
|
+
${r ? Ba : ""}
|
|
9720
9729
|
fragment ProductCollectionFields on ProductCollection {
|
|
9721
9730
|
id
|
|
9722
9731
|
name
|
|
@@ -9773,7 +9782,7 @@ const ne = v`
|
|
|
9773
9782
|
}
|
|
9774
9783
|
}
|
|
9775
9784
|
}
|
|
9776
|
-
`,
|
|
9785
|
+
`, zs = (r) => v`
|
|
9777
9786
|
${ne}
|
|
9778
9787
|
${re(r)}
|
|
9779
9788
|
query GetBundle($id: String!) {
|
|
@@ -9892,7 +9901,7 @@ const ne = v`
|
|
|
9892
9901
|
}
|
|
9893
9902
|
}
|
|
9894
9903
|
`, js = v`
|
|
9895
|
-
${
|
|
9904
|
+
${Ba}
|
|
9896
9905
|
query GetProductCollectionProducts($id: String!, $productIds: [String!]) {
|
|
9897
9906
|
productCollections(ids: [$id], productIds: $productIds) {
|
|
9898
9907
|
id
|
|
@@ -9925,7 +9934,7 @@ const ne = v`
|
|
|
9925
9934
|
}
|
|
9926
9935
|
}
|
|
9927
9936
|
`, Hs = v`
|
|
9928
|
-
${
|
|
9937
|
+
${Ba}
|
|
9929
9938
|
query GetProductCollectionForProductsFeed(
|
|
9930
9939
|
$id: String!
|
|
9931
9940
|
$limit: Int
|
|
@@ -10274,7 +10283,7 @@ const ne = v`
|
|
|
10274
10283
|
`;
|
|
10275
10284
|
var Re = /* @__PURE__ */ ((r) => (r.Error = "Error", r.Warning = "Warning", r.Info = "Info", r))(Re || {});
|
|
10276
10285
|
const fo = 1e3;
|
|
10277
|
-
class Ja extends
|
|
10286
|
+
class Ja extends Fn {
|
|
10278
10287
|
constructor(t) {
|
|
10279
10288
|
super(), this.createdAt = /* @__PURE__ */ new Date(), this.update = t;
|
|
10280
10289
|
}
|
|
@@ -10291,12 +10300,14 @@ class Co {
|
|
|
10291
10300
|
var w;
|
|
10292
10301
|
this.workflowStatePromiseQueue = new kn(1), this.initialized = !1, this.readOnly = !1, this.isReloadedTransaction = !1, this.singleVariantsRenderable = !1, this.stepTags = {}, this.renderLayouts = () => {
|
|
10293
10302
|
var E;
|
|
10294
|
-
if (!this.previewService)
|
|
10303
|
+
if (console.log("LOG: rendering layouts"), !this.previewService)
|
|
10295
10304
|
return;
|
|
10296
10305
|
const S = this.getCommandContext().getAllLayouts(), y = (E = this.getLayoutPreviewService()) == null ? void 0 : E.getAll();
|
|
10297
|
-
if (y)
|
|
10298
|
-
|
|
10299
|
-
|
|
10306
|
+
if (y) {
|
|
10307
|
+
console.log(`LOG: ${y.size} layouts to render`);
|
|
10308
|
+
for (const [, b] of y)
|
|
10309
|
+
b.render(S);
|
|
10310
|
+
}
|
|
10300
10311
|
}, this.experience = t, this.client = e, this.updateTransaction = o, this.graphQlClient = l, this.commandContext = s, this.reloadedState = h, this.transaction = c, this.readOnly = m, this.singleVariantsRenderable = f, this.confirmedDesign = !1, this.editedSteps = {}, this.informationResults = [], this.mandatorySteps = {}, this.pendingUpdates = [], this.selectionCost = 0, this.workflow = a, this.stepSpecificServices = {}, this.profanityFilter = n, this.pollers = [], this.allScenes = [], this.layouts = i, this.product = d, this.previewService = A, this.modelContainer = g, this.stepElements = {}, this.stepInitialised = {}, this.stepMetadata = {}, this.stepSelections = {}, this.storage = {}, this.validationErrors = { steps: /* @__PURE__ */ new Map() }, this.confirmCallbacks = [], this.editedCallbacks = [], this.elementsCallbacks = [], this.informationResultCallbacks = [], this.initCallbacks = [], this.mandatoryCallbacks = [], this.makingAdjustmentsCallback = [], this.metadataCallbacks = [], this.selectionCallbacks = [], this.stepSpecificStorageCallbacks = {}, this.storageCallbacks = [], this.validationCallbacks = [], this.recipientCallbacks = [], this.currentAdjustingStepId = "", this.renderableContextService = u, (w = this.renderableContextService) == null || w.setWorkflowManager(this), this.isReloadedTransaction = p, this.workflow.steps.forEach((S) => {
|
|
10301
10312
|
this.stepTags[S.stepName] = S.tags ?? [];
|
|
10302
10313
|
}), C && (this.workflowStatePromiseQueue.enabled = !1), this.initializationPromise = this.initializeDefaultWorkflowState(a), this.initializationPromise.then(() => {
|
|
@@ -10401,7 +10412,7 @@ class Co {
|
|
|
10401
10412
|
};
|
|
10402
10413
|
this.reloadedState && this.reloadedState.serializableWorkflow.steps.forEach((o) => {
|
|
10403
10414
|
this.storage[o.stepName] = o.storage || {};
|
|
10404
|
-
}), this.allScenes = await
|
|
10415
|
+
}), this.allScenes = await zi(t);
|
|
10405
10416
|
const n = Dt(this.allScenes, this.stepSelections).map((o) => o.silentSteps).flat(), { stepElements: i, commands: s } = await this.stepElementsForIntroducedSilentSteps(n, !!this.reloadedState);
|
|
10406
10417
|
this.commandContext.apply(new $(s), !0), this.stepElements = { ...this.stepElements, ...i }, await this.ensureStepsAreLoaded(), !this.isReloadedTransaction && this.updateStateWithServer(), this.renderLayouts(), this.reloadedState && e();
|
|
10407
10418
|
}
|
|
@@ -10818,7 +10829,7 @@ class Co {
|
|
|
10818
10829
|
}
|
|
10819
10830
|
async updateTransactionStakeholders() {
|
|
10820
10831
|
var e;
|
|
10821
|
-
const t = await
|
|
10832
|
+
const t = await B.getShadowGraphqlClient().query({
|
|
10822
10833
|
query: Di,
|
|
10823
10834
|
errorPolicy: "all",
|
|
10824
10835
|
fetchPolicy: "no-cache",
|
|
@@ -10829,7 +10840,7 @@ class Co {
|
|
|
10829
10840
|
!((e = t == null ? void 0 : t.data) != null && e.transactions) || t.data.transactions.length !== 1 ? (this.transaction.currentStakeholder = void 0, this.transaction.stakeholders = void 0) : (this.transaction.stakeholders = t.data.transactions[0].stakeholders, this.transaction.currentStakeholder = t.data.transactions[0].currentStakeholder);
|
|
10830
10841
|
}
|
|
10831
10842
|
async approveTransaction(t) {
|
|
10832
|
-
await
|
|
10843
|
+
await B.getShadowGraphqlClient().mutate({
|
|
10833
10844
|
mutation: uo,
|
|
10834
10845
|
errorPolicy: "all",
|
|
10835
10846
|
fetchPolicy: "no-cache",
|
|
@@ -10840,7 +10851,7 @@ class Co {
|
|
|
10840
10851
|
});
|
|
10841
10852
|
}
|
|
10842
10853
|
async rejectTransaction(t) {
|
|
10843
|
-
await
|
|
10854
|
+
await B.getShadowGraphqlClient().mutate({
|
|
10844
10855
|
mutation: ho,
|
|
10845
10856
|
errorPolicy: "all",
|
|
10846
10857
|
fetchPolicy: "no-cache",
|
|
@@ -10853,7 +10864,7 @@ class Co {
|
|
|
10853
10864
|
async reset() {
|
|
10854
10865
|
this.commandContext.getAllLayouts().forEach(
|
|
10855
10866
|
(e) => e.layoutState.elements.forEach((a) => {
|
|
10856
|
-
this.getCommandDispatcher()(new
|
|
10867
|
+
this.getCommandDispatcher()(new bt(a.id));
|
|
10857
10868
|
})
|
|
10858
10869
|
), this.stepElements = {}, this.stepInitialised = {}, this.stepMetadata = {}, this.stepSelections = {}, this.storage = {}, await this.ensureStepsAreLoaded();
|
|
10859
10870
|
}
|
|
@@ -10863,11 +10874,11 @@ class Co {
|
|
|
10863
10874
|
this.stepSelections = {
|
|
10864
10875
|
...this.stepSelections,
|
|
10865
10876
|
[t]: { selectedVariants: e }
|
|
10866
|
-
}, this.selectionCost = Object.values(this.stepSelections).reduce((E,
|
|
10877
|
+
}, this.selectionCost = Object.values(this.stepSelections).reduce((E, b) => E + b.selectedVariants.map((I) => I.priceModifier || 0).reduce((I, D) => I + D, 0), 0), this.workflow.steps.forEach((E) => {
|
|
10867
10878
|
yt(E, this.stepSelections) || (this.stepInitialised[E.stepName] = !1, delete this.stepMetadata[E.stepName], delete this.stepSelections[E.stepName], delete this.storage[E.stepName]);
|
|
10868
10879
|
});
|
|
10869
10880
|
const s = this.allScenes, o = Dt(s, i), l = Dt(s, this.stepSelections), c = o.map((E) => E.silentSteps).flat(), A = l.map((E) => E.silentSteps).flat().filter(
|
|
10870
|
-
(E) => !c.some((
|
|
10881
|
+
(E) => !c.some((b) => b.stepName === E.stepName)
|
|
10871
10882
|
);
|
|
10872
10883
|
c.forEach((E) => {
|
|
10873
10884
|
yt(E, this.stepSelections) || (this.stepInitialised[E.stepName] = !1);
|
|
@@ -10881,15 +10892,15 @@ class Co {
|
|
|
10881
10892
|
const g = this.workflow.steps.find((E) => E.stepName === t);
|
|
10882
10893
|
if ((g == null ? void 0 : g.type) === P.Frame) {
|
|
10883
10894
|
const E = (y = this.getWorkflowExperience().getStepById(g.stepName)) == null ? void 0 : y.frameService;
|
|
10884
|
-
E == null || E.setTargetElements(a.map((
|
|
10895
|
+
E == null || E.setTargetElements(a.map((b) => b.id));
|
|
10885
10896
|
}
|
|
10886
|
-
const p = u.map((E) => new
|
|
10897
|
+
const p = u.map((E) => new bt(E.id)), f = new Wa(this.constructSerializableWorkflow()), C = [...m, ...p, f];
|
|
10887
10898
|
C.length > 0 && this.commandContext.apply(new $(C), !0), await this.ensureStepsAreLoaded(), this.onElementsChange();
|
|
10888
10899
|
const w = this.getInvalidModelVariants(), S = this.modelContainer;
|
|
10889
10900
|
if (S) {
|
|
10890
10901
|
const E = w.map(
|
|
10891
|
-
(
|
|
10892
|
-
|
|
10902
|
+
(b) => S.applyModelVariant(
|
|
10903
|
+
b,
|
|
10893
10904
|
{
|
|
10894
10905
|
contextService: this.getLayoutPreviewService()
|
|
10895
10906
|
},
|
|
@@ -10902,12 +10913,13 @@ class Co {
|
|
|
10902
10913
|
}
|
|
10903
10914
|
async ensureStepsAreLoaded() {
|
|
10904
10915
|
const e = Dt(this.allScenes, this.stepSelections).map((l) => l.renderableSteps), a = [], n = e.flat();
|
|
10916
|
+
console.log("LOG: ensuring steps are loaded");
|
|
10905
10917
|
for (const l of n)
|
|
10906
10918
|
if (!this.stepInitialised[l.stepName])
|
|
10907
10919
|
switch (this.stepInitialised[l.stepName] = !0, l.type) {
|
|
10908
10920
|
case P.DigitalContent:
|
|
10909
10921
|
a.push(
|
|
10910
|
-
|
|
10922
|
+
zn.init(
|
|
10911
10923
|
l,
|
|
10912
10924
|
this,
|
|
10913
10925
|
this.reloadedState
|
|
@@ -10948,10 +10960,10 @@ class Co {
|
|
|
10948
10960
|
);
|
|
10949
10961
|
break;
|
|
10950
10962
|
case P.Shape:
|
|
10951
|
-
a.push(
|
|
10963
|
+
a.push(Gt.init(l, this, this.reloadedState));
|
|
10952
10964
|
break;
|
|
10953
10965
|
case P.Text:
|
|
10954
|
-
a.push(
|
|
10966
|
+
a.push(W.init(l, this, this.reloadedState));
|
|
10955
10967
|
break;
|
|
10956
10968
|
}
|
|
10957
10969
|
const i = (await Promise.allSettled(a)).map((l) => {
|
|
@@ -11258,7 +11270,7 @@ class wo extends it {
|
|
|
11258
11270
|
const t = this.manager.getRegionElements(this.step.stepName) || [];
|
|
11259
11271
|
if (t.length === 0)
|
|
11260
11272
|
return;
|
|
11261
|
-
const a =
|
|
11273
|
+
const a = U(t[0].id, this.manager.getAllLayoutData()).colors, n = (o = this.getCurrentVariant()) == null ? void 0 : o.getAssetResource(), i = n == null ? void 0 : n.assetConfiguration, s = (i == null ? void 0 : i.defaultColorVariants) || [];
|
|
11262
11274
|
if (s.length !== 0) {
|
|
11263
11275
|
const l = {};
|
|
11264
11276
|
return s.forEach((c) => {
|
|
@@ -11369,13 +11381,13 @@ class Eo extends it {
|
|
|
11369
11381
|
return this.step.data.displayType || ((t = this.step.option) == null ? void 0 : t.displayType);
|
|
11370
11382
|
}
|
|
11371
11383
|
}
|
|
11372
|
-
class
|
|
11384
|
+
class bo extends it {
|
|
11373
11385
|
constructor(t, e, a) {
|
|
11374
11386
|
super(t, e, a);
|
|
11375
11387
|
}
|
|
11376
11388
|
selectVariant(t) {
|
|
11377
11389
|
const e = t.getResource();
|
|
11378
|
-
return
|
|
11390
|
+
return Gt.selectVariant(
|
|
11379
11391
|
this.step,
|
|
11380
11392
|
{
|
|
11381
11393
|
fill: e.color,
|
|
@@ -11393,7 +11405,7 @@ class Bo extends it {
|
|
|
11393
11405
|
* @deprecated The shape step can now pass through colors returned by getColors via selectVariant. Please swap setColor for selectVariant.
|
|
11394
11406
|
*/
|
|
11395
11407
|
setColor(t) {
|
|
11396
|
-
return
|
|
11408
|
+
return Gt.selectVariant(
|
|
11397
11409
|
this.step,
|
|
11398
11410
|
t,
|
|
11399
11411
|
this.manager.getRegionElements(this.step.stepName) || [],
|
|
@@ -11405,7 +11417,7 @@ class Bo extends it {
|
|
|
11405
11417
|
* @returns A list of color definitions that are currently applied to the illustration.
|
|
11406
11418
|
*/
|
|
11407
11419
|
getColors() {
|
|
11408
|
-
return
|
|
11420
|
+
return Gt.availableColours(this.step);
|
|
11409
11421
|
}
|
|
11410
11422
|
/**
|
|
11411
11423
|
* Allows for setting a custom color when the custom variant is selected. Will
|
|
@@ -11413,7 +11425,7 @@ class Bo extends it {
|
|
|
11413
11425
|
*/
|
|
11414
11426
|
setCustomColor(t) {
|
|
11415
11427
|
var e, a;
|
|
11416
|
-
return ((e = this.getCurrentVariant()) == null ? void 0 : e.getColor()) !== "#custom" && console.warn(`setting custom color for step ${this.step.stepName} but color is ${(a = this.getCurrentVariant()) == null ? void 0 : a.getColor()}`),
|
|
11428
|
+
return ((e = this.getCurrentVariant()) == null ? void 0 : e.getColor()) !== "#custom" && console.warn(`setting custom color for step ${this.step.stepName} but color is ${(a = this.getCurrentVariant()) == null ? void 0 : a.getColor()}`), Gt.setCustomColor(t, this.step, this.manager);
|
|
11417
11429
|
}
|
|
11418
11430
|
getCustomColor() {
|
|
11419
11431
|
var e, a, n;
|
|
@@ -11424,7 +11436,7 @@ class Bo extends it {
|
|
|
11424
11436
|
return t;
|
|
11425
11437
|
}
|
|
11426
11438
|
}
|
|
11427
|
-
class
|
|
11439
|
+
class Bo extends it {
|
|
11428
11440
|
constructor(t, e, a) {
|
|
11429
11441
|
super(t, e, a);
|
|
11430
11442
|
}
|
|
@@ -11433,7 +11445,7 @@ class bo extends it {
|
|
|
11433
11445
|
* @param variant The font variant to use.
|
|
11434
11446
|
*/
|
|
11435
11447
|
async selectVariant(t) {
|
|
11436
|
-
|
|
11448
|
+
W.selectVariant(
|
|
11437
11449
|
this.step,
|
|
11438
11450
|
t.getResource(),
|
|
11439
11451
|
this.manager,
|
|
@@ -11460,7 +11472,7 @@ class bo extends it {
|
|
|
11460
11472
|
* @returns A list of colors that can be used to fill the text.
|
|
11461
11473
|
*/
|
|
11462
11474
|
getAvailableFillColors() {
|
|
11463
|
-
return this.step.data.colorPickerEnabled ?
|
|
11475
|
+
return this.step.data.colorPickerEnabled ? W.availableFillColors(this.step) : [];
|
|
11464
11476
|
}
|
|
11465
11477
|
/**
|
|
11466
11478
|
* Changes the fill of text related to this step to the new fill value.
|
|
@@ -11468,7 +11480,7 @@ class bo extends it {
|
|
|
11468
11480
|
*/
|
|
11469
11481
|
async setFillColor(t) {
|
|
11470
11482
|
const e = this.manager.getRegionElements(this.step.stepName);
|
|
11471
|
-
await
|
|
11483
|
+
await W.changeFillColor(this.step, t, e, this.manager);
|
|
11472
11484
|
}
|
|
11473
11485
|
/**
|
|
11474
11486
|
* Gets the color currently applied to the element.
|
|
@@ -11478,23 +11490,23 @@ class bo extends it {
|
|
|
11478
11490
|
return ((t = this.manager.getStepStorage(this.step.stepName)) == null ? void 0 : t.color) || "#000000";
|
|
11479
11491
|
}
|
|
11480
11492
|
getAvailableFillImages() {
|
|
11481
|
-
return
|
|
11493
|
+
return W.availableFillImages(this.step);
|
|
11482
11494
|
}
|
|
11483
11495
|
async setFillImage(t) {
|
|
11484
11496
|
const e = this.manager.getRegionElements(this.step.stepName);
|
|
11485
|
-
await
|
|
11497
|
+
await W.changeFillImage(this.step, t, e, this.manager);
|
|
11486
11498
|
}
|
|
11487
11499
|
getFillImage() {
|
|
11488
11500
|
var t;
|
|
11489
11501
|
return (t = this.manager.getStepStorage(this.step.stepName)) == null ? void 0 : t.fillImage;
|
|
11490
11502
|
}
|
|
11491
11503
|
getAlignment() {
|
|
11492
|
-
const t =
|
|
11504
|
+
const t = W.findLayoutElements(this.manager, this.step);
|
|
11493
11505
|
return t == null ? void 0 : t[0].align;
|
|
11494
11506
|
}
|
|
11495
11507
|
setAlignment(t) {
|
|
11496
11508
|
const e = this.manager.getRegionElements(this.step.stepName);
|
|
11497
|
-
|
|
11509
|
+
W.changeAlignment(this.step, t, e, this.manager);
|
|
11498
11510
|
}
|
|
11499
11511
|
/**
|
|
11500
11512
|
* When true & the step has replaceable text configured the user will be
|
|
@@ -11519,21 +11531,21 @@ class bo extends it {
|
|
|
11519
11531
|
const e = {
|
|
11520
11532
|
input: t,
|
|
11521
11533
|
helperData: {}
|
|
11522
|
-
}, a =
|
|
11534
|
+
}, a = W.findLayoutElements(this.manager, this.step), n = W.filterUnsupportedCharacters(t, (d = a[0]) == null ? void 0 : d.fontData), i = !!this.step.data && !!this.step.data.maxLength && n.length > this.step.data.maxLength;
|
|
11523
11535
|
i || (e.input = n);
|
|
11524
11536
|
const s = a.length <= 0, o = s ? { inputText: n, text: n } : { inputText: n };
|
|
11525
11537
|
this.manager.updateStorage(this.step.stepName, o);
|
|
11526
|
-
const l = this.manager.getStepStorage(this.step.stepName), c =
|
|
11538
|
+
const l = this.manager.getStepStorage(this.step.stepName), c = W.getProcessedInput(
|
|
11527
11539
|
n,
|
|
11528
11540
|
this.step.data,
|
|
11529
11541
|
(l == null ? void 0 : l.customiseAllText) ?? !1
|
|
11530
11542
|
);
|
|
11531
|
-
if (s)
|
|
11543
|
+
if (console.log(`LOG: setting text to ${a.length} regions`), s)
|
|
11532
11544
|
i || this.manager.updateMetadata(this.step.stepName, {
|
|
11533
11545
|
text: c
|
|
11534
11546
|
});
|
|
11535
11547
|
else {
|
|
11536
|
-
const { command: A, errorData: u, helperData: h } =
|
|
11548
|
+
const { command: A, errorData: u, helperData: h } = W.updateInputText(
|
|
11537
11549
|
n,
|
|
11538
11550
|
a,
|
|
11539
11551
|
this.step,
|
|
@@ -11572,8 +11584,8 @@ class bo extends it {
|
|
|
11572
11584
|
if (!(t != null && t.defaultCleared) && this.step.data.deleteDefaultOnFocus) {
|
|
11573
11585
|
const e = this.setText("");
|
|
11574
11586
|
this.manager.updateStorage(this.step.stepName, { defaultCleared: !0, inputText: "" });
|
|
11575
|
-
const a =
|
|
11576
|
-
return
|
|
11587
|
+
const a = W.findLayoutElements(this.manager, this.step);
|
|
11588
|
+
return W.updateInputText("", a, this.step, this.manager), e;
|
|
11577
11589
|
}
|
|
11578
11590
|
}
|
|
11579
11591
|
hasColorPicker() {
|
|
@@ -11610,7 +11622,7 @@ class bo extends it {
|
|
|
11610
11622
|
* @returns A list of colors that can be used for the text's outline.
|
|
11611
11623
|
*/
|
|
11612
11624
|
getAvailableStrokeColors() {
|
|
11613
|
-
return this.step.data.strokeEnabled ?
|
|
11625
|
+
return this.step.data.strokeEnabled ? W.availableStrokeColors(this.step) : [];
|
|
11614
11626
|
}
|
|
11615
11627
|
getStrokeColor() {
|
|
11616
11628
|
var t, e;
|
|
@@ -11622,7 +11634,7 @@ class bo extends it {
|
|
|
11622
11634
|
*/
|
|
11623
11635
|
async setStrokeColor(t) {
|
|
11624
11636
|
const e = this.manager.getRegionElements(this.step.stepName);
|
|
11625
|
-
await
|
|
11637
|
+
await W.changeStrokeColor(this.step, t, e, this.manager);
|
|
11626
11638
|
}
|
|
11627
11639
|
}
|
|
11628
11640
|
class Io extends it {
|
|
@@ -11657,7 +11669,7 @@ class Po extends it {
|
|
|
11657
11669
|
* @returns The final URL string for the QR code.
|
|
11658
11670
|
*/
|
|
11659
11671
|
async selectVideo(t) {
|
|
11660
|
-
return
|
|
11672
|
+
return zn.regenerateQRCode(
|
|
11661
11673
|
this.manager.getRegionElements(this.step.stepName),
|
|
11662
11674
|
t.key,
|
|
11663
11675
|
this.manager,
|
|
@@ -11723,13 +11735,13 @@ class ce {
|
|
|
11723
11735
|
case P.Question:
|
|
11724
11736
|
return new Eo(t, e, t.getStepTags(e.stepName));
|
|
11725
11737
|
case P.Text:
|
|
11726
|
-
return new
|
|
11738
|
+
return new Bo(t, e, t.getStepTags(e.stepName));
|
|
11727
11739
|
case P.Illustration:
|
|
11728
11740
|
return new wo(t, e, t.getStepTags(e.stepName));
|
|
11729
11741
|
case P.Picture:
|
|
11730
11742
|
return new vo(t, e, t.getStepTags(e.stepName));
|
|
11731
11743
|
case P.Shape:
|
|
11732
|
-
return new
|
|
11744
|
+
return new bo(t, e, t.getStepTags(e.stepName));
|
|
11733
11745
|
case P.Material:
|
|
11734
11746
|
return new yo(t, e, t.getStepTags(e.stepName));
|
|
11735
11747
|
case P.Model:
|
|
@@ -11768,7 +11780,7 @@ const _n = v`
|
|
|
11768
11780
|
externalProductVariantId
|
|
11769
11781
|
}
|
|
11770
11782
|
}
|
|
11771
|
-
`,
|
|
11783
|
+
`, xo = v`
|
|
11772
11784
|
${_n}
|
|
11773
11785
|
mutation CreateDesign(
|
|
11774
11786
|
$name: String!
|
|
@@ -11800,7 +11812,7 @@ const _n = v`
|
|
|
11800
11812
|
}
|
|
11801
11813
|
}
|
|
11802
11814
|
}
|
|
11803
|
-
`,
|
|
11815
|
+
`, Fo = v`
|
|
11804
11816
|
${_n}
|
|
11805
11817
|
mutation CreateDesigns($inputs: [DesignCreateInput]!) {
|
|
11806
11818
|
designCreateMany(inputs: $inputs) {
|
|
@@ -11832,8 +11844,8 @@ const ko = async (r, t) => {
|
|
|
11832
11844
|
const l = ((n = Object.entries(localStorage).find(([d, A]) => d.startsWith("CognitoIdentityServiceProvider") && d.endsWith("idToken"))) == null ? void 0 : n[0]) || "", c = localStorage.getItem(l);
|
|
11833
11845
|
c && !Wt(c) && (e.Authorization = `Bearer ${c}`);
|
|
11834
11846
|
}
|
|
11835
|
-
return (i = (await
|
|
11836
|
-
mutation:
|
|
11847
|
+
return (i = (await B.getShadowGraphqlClient().mutate({
|
|
11848
|
+
mutation: xo,
|
|
11837
11849
|
errorPolicy: "all",
|
|
11838
11850
|
fetchPolicy: "no-cache",
|
|
11839
11851
|
variables: {
|
|
@@ -11863,8 +11875,8 @@ const ko = async (r, t) => {
|
|
|
11863
11875
|
const l = ((n = Object.entries(localStorage).find(([d, A]) => d.startsWith("CognitoIdentityServiceProvider") && d.endsWith("idToken"))) == null ? void 0 : n[0]) || "", c = localStorage.getItem(l);
|
|
11864
11876
|
c && !Wt(c) && (e.Authorization = `Bearer ${c}`);
|
|
11865
11877
|
}
|
|
11866
|
-
return (i = (await
|
|
11867
|
-
mutation:
|
|
11878
|
+
return (i = (await B.getShadowGraphqlClient().mutate({
|
|
11879
|
+
mutation: Fo,
|
|
11868
11880
|
errorPolicy: "all",
|
|
11869
11881
|
fetchPolicy: "no-cache",
|
|
11870
11882
|
variables: {
|
|
@@ -11970,13 +11982,13 @@ const ko = async (r, t) => {
|
|
|
11970
11982
|
if (c !== void 0)
|
|
11971
11983
|
return c;
|
|
11972
11984
|
await r.outstandingRequestsPromise();
|
|
11973
|
-
const
|
|
11985
|
+
const x = (N.getMap("transactionOwnerIds") || /* @__PURE__ */ new Map()).get(n.id), T = await B.getShadowGraphqlClient().query({
|
|
11974
11986
|
query: Dn,
|
|
11975
11987
|
variables: { ids: [n.id] },
|
|
11976
11988
|
fetchPolicy: "no-cache",
|
|
11977
11989
|
errorPolicy: "all",
|
|
11978
11990
|
context: {
|
|
11979
|
-
transactionOwnerId:
|
|
11991
|
+
transactionOwnerId: x
|
|
11980
11992
|
}
|
|
11981
11993
|
}), nt = (R = T.data) == null ? void 0 : R.transactions[0].workflowState;
|
|
11982
11994
|
return T.errors ? (T.errors.forEach((tt) => {
|
|
@@ -11984,7 +11996,7 @@ const ko = async (r, t) => {
|
|
|
11984
11996
|
}), null) : nt ?? null;
|
|
11985
11997
|
})() || (console.warn("State mismatch detected. Uploading known state explicitly"), console.warn("State Object:", JSON.stringify(a())), await r.updateStateWithServerImmediate(a), console.log("Server state is undefined @ Workflow completion"));
|
|
11986
11998
|
const u = r.getPreviewService(), h = (I = t == null ? void 0 : t.finalizeStepConfig) == null ? void 0 : I.lookAtAnimation, m = u && t.showModelOnFinishStep && !!h, g = l && ca(l, t, !0), p = l && ca(l, t, !1), f = async (D) => {
|
|
11987
|
-
const
|
|
11999
|
+
const x = {};
|
|
11988
12000
|
let k = 0;
|
|
11989
12001
|
if (Object.keys(i).length > 0)
|
|
11990
12002
|
for (const T of Object.keys(i)) {
|
|
@@ -11993,11 +12005,11 @@ const ko = async (r, t) => {
|
|
|
11993
12005
|
const q = nt.selections[tt];
|
|
11994
12006
|
if (R && (!D || R.option && (R.option.variants || []).length > 1 && !R.data.hideSelectionInCart && !R.data.hideSelectionsInCart)) {
|
|
11995
12007
|
const ft = R.stepTitle;
|
|
11996
|
-
|
|
12008
|
+
x[ft] ? x[ft].push({
|
|
11997
12009
|
id: q.id || "",
|
|
11998
12010
|
name: q.name,
|
|
11999
12011
|
priceModifier: q.priceModifier
|
|
12000
|
-
}) :
|
|
12012
|
+
}) : x[ft] = [
|
|
12001
12013
|
{
|
|
12002
12014
|
id: q.id || "",
|
|
12003
12015
|
name: q.name,
|
|
@@ -12008,19 +12020,19 @@ const ko = async (r, t) => {
|
|
|
12008
12020
|
k += q.priceModifier;
|
|
12009
12021
|
}
|
|
12010
12022
|
}
|
|
12011
|
-
return [
|
|
12023
|
+
return [x, k];
|
|
12012
12024
|
}, [C] = await f(!0), w = Object.fromEntries(
|
|
12013
|
-
Object.keys(C).map((D) => [D, C[D].map((
|
|
12025
|
+
Object.keys(C).map((D) => [D, C[D].map((x) => x.id)])
|
|
12014
12026
|
), [S] = await f(!1), y = Object.fromEntries(
|
|
12015
12027
|
Object.keys(S).map((D) => [
|
|
12016
12028
|
D,
|
|
12017
|
-
S[D].map((
|
|
12029
|
+
S[D].map((x) => x.id)
|
|
12018
12030
|
])
|
|
12019
12031
|
);
|
|
12020
12032
|
let E = await o(m, n.id);
|
|
12021
12033
|
if (E) {
|
|
12022
12034
|
const D = await (await rt(E)).blob();
|
|
12023
|
-
E = (await
|
|
12035
|
+
E = (await L.uploadAsset(
|
|
12024
12036
|
{ name: `${n.id}-preview-image.png`, blob: D },
|
|
12025
12037
|
Ce.Image,
|
|
12026
12038
|
!0,
|
|
@@ -12031,9 +12043,9 @@ const ko = async (r, t) => {
|
|
|
12031
12043
|
designDetails: (() => {
|
|
12032
12044
|
const D = {
|
|
12033
12045
|
name: s,
|
|
12034
|
-
layouts: e.map((
|
|
12035
|
-
index:
|
|
12036
|
-
panelId:
|
|
12046
|
+
layouts: e.map((x) => ({
|
|
12047
|
+
index: x.index,
|
|
12048
|
+
panelId: x.panelId
|
|
12037
12049
|
})),
|
|
12038
12050
|
workflowId: t.id,
|
|
12039
12051
|
transactionId: n.id,
|
|
@@ -12041,16 +12053,16 @@ const ko = async (r, t) => {
|
|
|
12041
12053
|
previewImage: E
|
|
12042
12054
|
};
|
|
12043
12055
|
if (p) {
|
|
12044
|
-
const
|
|
12056
|
+
const x = [];
|
|
12045
12057
|
for (const [k, T] of Object.entries(p))
|
|
12046
|
-
|
|
12047
|
-
D.metadata =
|
|
12058
|
+
x.push({ key: k, value: T });
|
|
12059
|
+
D.metadata = x;
|
|
12048
12060
|
}
|
|
12049
12061
|
if (w) {
|
|
12050
|
-
const
|
|
12062
|
+
const x = [];
|
|
12051
12063
|
for (const [k, T] of Object.entries(y))
|
|
12052
|
-
|
|
12053
|
-
D.selectedVariants =
|
|
12064
|
+
x.push({ key: k, ids: T });
|
|
12065
|
+
D.selectedVariants = x;
|
|
12054
12066
|
}
|
|
12055
12067
|
return D;
|
|
12056
12068
|
})(),
|
|
@@ -12095,7 +12107,7 @@ const ko = async (r, t) => {
|
|
|
12095
12107
|
);
|
|
12096
12108
|
const n = await (async () => {
|
|
12097
12109
|
var c;
|
|
12098
|
-
const l = await
|
|
12110
|
+
const l = await B.getShadowGraphqlClient().query({
|
|
12099
12111
|
query: Dn,
|
|
12100
12112
|
variables: { ids: r.map((d) => d.transaction.id) },
|
|
12101
12113
|
fetchPolicy: "no-cache",
|
|
@@ -12240,14 +12252,14 @@ const Ye = new Ro(), Oo = v`
|
|
|
12240
12252
|
id
|
|
12241
12253
|
}
|
|
12242
12254
|
}
|
|
12243
|
-
`,
|
|
12255
|
+
`, Lo = v`
|
|
12244
12256
|
mutation AddOrganizationToTransaction($transactionId: String!, $organizationName: String!) {
|
|
12245
12257
|
organizationAttachToTransaction(transactionId: $transactionId, organizationName: $organizationName) {
|
|
12246
12258
|
id
|
|
12247
12259
|
}
|
|
12248
12260
|
}
|
|
12249
12261
|
`;
|
|
12250
|
-
var
|
|
12262
|
+
var Uo = /* @__PURE__ */ ((r) => (r.QuantityChanged = "QuantityChanged", r.PriceBreakChanged = "PriceBreakChanged", r))(Uo || {});
|
|
12251
12263
|
class Vo {
|
|
12252
12264
|
constructor(t, e) {
|
|
12253
12265
|
var n;
|
|
@@ -12325,7 +12337,7 @@ class Vo {
|
|
|
12325
12337
|
}
|
|
12326
12338
|
async attachOrganization(t) {
|
|
12327
12339
|
await this.graphQlClient().mutate({
|
|
12328
|
-
mutation:
|
|
12340
|
+
mutation: Lo,
|
|
12329
12341
|
variables: {
|
|
12330
12342
|
transactionId: this.getWorkflowManager().getTransaction().id,
|
|
12331
12343
|
organizationName: t
|
|
@@ -12375,7 +12387,7 @@ class Vo {
|
|
|
12375
12387
|
height: d.layoutState.layout.height
|
|
12376
12388
|
}, u = this.commandContext.getLayoutById(d.layoutState.layout.id), h = s.getContext("2d");
|
|
12377
12389
|
if (!h)
|
|
12378
|
-
throw new
|
|
12390
|
+
throw new xe("Failed to obtain 2D context for preview image creation");
|
|
12379
12391
|
const m = Sa(u.layoutState.layout, u.layoutState.elements, {
|
|
12380
12392
|
renderingConfiguration: {
|
|
12381
12393
|
purpose: qt.Print,
|
|
@@ -12588,7 +12600,7 @@ class Vo {
|
|
|
12588
12600
|
async onDesignFinished(t, e = !0) {
|
|
12589
12601
|
const a = this.workflowManager.getTransaction();
|
|
12590
12602
|
return a.completed ? (await this.graphQlClient().mutate({
|
|
12591
|
-
mutation:
|
|
12603
|
+
mutation: xi,
|
|
12592
12604
|
variables: {
|
|
12593
12605
|
transactionId: a.id
|
|
12594
12606
|
}
|
|
@@ -12676,7 +12688,7 @@ class Vo {
|
|
|
12676
12688
|
(this.eventCallbacks.get(t) || []).forEach((e) => e(this));
|
|
12677
12689
|
}
|
|
12678
12690
|
}
|
|
12679
|
-
const
|
|
12691
|
+
const Go = [
|
|
12680
12692
|
"altGlyph",
|
|
12681
12693
|
"circle",
|
|
12682
12694
|
"ellipse",
|
|
@@ -12688,7 +12700,7 @@ const zo = [
|
|
|
12688
12700
|
"textPath",
|
|
12689
12701
|
"tref",
|
|
12690
12702
|
"tspan"
|
|
12691
|
-
],
|
|
12703
|
+
], zo = async (r, t, e) => {
|
|
12692
12704
|
const a = t.data, n = e.data.baseUrl, i = a.assetUrl.replace("localhost", "localstack"), s = n.slice(0, 4) === "http" ? "" : "https://", o = new URL(s + n);
|
|
12693
12705
|
o.searchParams.append("video", Ra(JSON.stringify([{ href: i }]))), o.pathname = o.pathname + (o.pathname.slice(-1) === "/" ? "" : "/");
|
|
12694
12706
|
const l = o.toString(), d = `data:image/svg+xml;base64,${Ra(await ln(l, { type: "svg" }))}`, A = (h) => {
|
|
@@ -12696,7 +12708,7 @@ const zo = [
|
|
|
12696
12708
|
if (!m)
|
|
12697
12709
|
throw new J(h);
|
|
12698
12710
|
const g = Q();
|
|
12699
|
-
return new
|
|
12711
|
+
return new z(
|
|
12700
12712
|
{
|
|
12701
12713
|
id: g,
|
|
12702
12714
|
src: d,
|
|
@@ -12736,7 +12748,7 @@ const zo = [
|
|
|
12736
12748
|
a.data.forceImageCover
|
|
12737
12749
|
);
|
|
12738
12750
|
return [
|
|
12739
|
-
new
|
|
12751
|
+
new z(
|
|
12740
12752
|
{
|
|
12741
12753
|
id: u,
|
|
12742
12754
|
path: A.path,
|
|
@@ -12778,7 +12790,7 @@ const zo = [
|
|
|
12778
12790
|
const n = e.data, i = a.option;
|
|
12779
12791
|
if (!i)
|
|
12780
12792
|
return console.error(`No option for step ${a.stepName}.`), [];
|
|
12781
|
-
const s = ((y = i.variants) == null ? void 0 : y.find((
|
|
12793
|
+
const s = ((y = i.variants) == null ? void 0 : y.find((b) => b.id === n.illustrationVariantId)) || ae(i);
|
|
12782
12794
|
if (!s)
|
|
12783
12795
|
return console.error(`No variant with ID: ${n.illustrationVariantId}`), [];
|
|
12784
12796
|
if (!s.asset)
|
|
@@ -12792,55 +12804,55 @@ const zo = [
|
|
|
12792
12804
|
return console.error("Failed to read SVG."), [];
|
|
12793
12805
|
pa(m);
|
|
12794
12806
|
const g = {};
|
|
12795
|
-
kt(m, (
|
|
12796
|
-
|
|
12797
|
-
const I =
|
|
12807
|
+
kt(m, (b) => {
|
|
12808
|
+
Go.includes(b.tagName) && !b.attributes.getNamedItem("fill") && b.setAttribute("fill", "#000000");
|
|
12809
|
+
const I = b.attributes.getNamedItem("fill");
|
|
12798
12810
|
if (I && I.value !== "none") {
|
|
12799
|
-
const
|
|
12800
|
-
|
|
12811
|
+
const x = I.value, T = `spiff-fill-${x.replace(/\W/g, "")}`;
|
|
12812
|
+
b.classList.add(T), g[T] = { browserValue: x };
|
|
12801
12813
|
}
|
|
12802
|
-
const D =
|
|
12814
|
+
const D = b.attributes.getNamedItem("stroke");
|
|
12803
12815
|
if (D && D.value !== "none") {
|
|
12804
|
-
const
|
|
12805
|
-
|
|
12816
|
+
const x = D.value, T = `spiff-stroke-${x.replace(/\W/g, "")}`;
|
|
12817
|
+
b.classList.add(T), g[T] = { browserValue: x };
|
|
12806
12818
|
}
|
|
12807
12819
|
});
|
|
12808
|
-
const f =
|
|
12820
|
+
const f = Bt().serializeToString(m), C = n.colors;
|
|
12809
12821
|
if (C) {
|
|
12810
|
-
for (const [
|
|
12822
|
+
for (const [b, I] of Object.entries(g))
|
|
12811
12823
|
for (const D of Object.keys(C))
|
|
12812
12824
|
if (I.browserValue === D) {
|
|
12813
|
-
g[
|
|
12825
|
+
g[b] = { browserValue: C[D] };
|
|
12814
12826
|
break;
|
|
12815
12827
|
}
|
|
12816
12828
|
}
|
|
12817
|
-
const w = (
|
|
12818
|
-
const I = r.find((
|
|
12829
|
+
const w = (b) => {
|
|
12830
|
+
const I = r.find((x) => x.panelId === b.panelId);
|
|
12819
12831
|
if (!I)
|
|
12820
|
-
throw new J(
|
|
12832
|
+
throw new J(b);
|
|
12821
12833
|
const D = Q();
|
|
12822
|
-
return new
|
|
12834
|
+
return new z(
|
|
12823
12835
|
{
|
|
12824
12836
|
colors: g,
|
|
12825
12837
|
id: D,
|
|
12826
12838
|
svg: f,
|
|
12827
12839
|
type: M.Illustration,
|
|
12828
|
-
y:
|
|
12829
|
-
x:
|
|
12830
|
-
rotation:
|
|
12831
|
-
width:
|
|
12832
|
-
height:
|
|
12833
|
-
layer:
|
|
12834
|
-
layerIndex:
|
|
12835
|
-
immutable:
|
|
12840
|
+
y: b.top,
|
|
12841
|
+
x: b.left,
|
|
12842
|
+
rotation: b.rotation,
|
|
12843
|
+
width: b.width,
|
|
12844
|
+
height: b.height,
|
|
12845
|
+
layer: b.layer,
|
|
12846
|
+
layerIndex: b.layerIndex,
|
|
12847
|
+
immutable: b.immutable
|
|
12836
12848
|
},
|
|
12837
12849
|
I
|
|
12838
12850
|
);
|
|
12839
12851
|
}, S = a.data.regions;
|
|
12840
12852
|
try {
|
|
12841
12853
|
return S.map(w);
|
|
12842
|
-
} catch (
|
|
12843
|
-
return console.error(
|
|
12854
|
+
} catch (b) {
|
|
12855
|
+
return console.error(b), [];
|
|
12844
12856
|
}
|
|
12845
12857
|
}, qo = async (r, t, e) => {
|
|
12846
12858
|
const a = await Jn(e.data.module), n = t.data, i = (o, l) => {
|
|
@@ -12848,7 +12860,7 @@ const zo = [
|
|
|
12848
12860
|
if (!c)
|
|
12849
12861
|
throw new J(l);
|
|
12850
12862
|
const d = Q();
|
|
12851
|
-
return new
|
|
12863
|
+
return new z(
|
|
12852
12864
|
{
|
|
12853
12865
|
colors: {},
|
|
12854
12866
|
id: d,
|
|
@@ -12891,7 +12903,7 @@ const zo = [
|
|
|
12891
12903
|
if (!h)
|
|
12892
12904
|
throw new J(u);
|
|
12893
12905
|
const m = Q();
|
|
12894
|
-
return new
|
|
12906
|
+
return new z(
|
|
12895
12907
|
{
|
|
12896
12908
|
id: m,
|
|
12897
12909
|
src: o,
|
|
@@ -12948,7 +12960,7 @@ const zo = [
|
|
|
12948
12960
|
/>
|
|
12949
12961
|
</svg>
|
|
12950
12962
|
`, m = { "spiff-fill-shape": { browserValue: s.color || "#000000" } }, g = Q();
|
|
12951
|
-
return new
|
|
12963
|
+
return new z(
|
|
12952
12964
|
{
|
|
12953
12965
|
colors: m,
|
|
12954
12966
|
id: g,
|
|
@@ -12999,7 +13011,7 @@ const zo = [
|
|
|
12999
13011
|
excludeFromExport: t.data.excludeFromPrint,
|
|
13000
13012
|
preserveAspectRatio: "none"
|
|
13001
13013
|
};
|
|
13002
|
-
a.push(new
|
|
13014
|
+
a.push(new z(A, d));
|
|
13003
13015
|
});
|
|
13004
13016
|
} catch (c) {
|
|
13005
13017
|
console.error(c);
|
|
@@ -13008,8 +13020,8 @@ const zo = [
|
|
|
13008
13020
|
const c = await at(i, !0), d = (A) => {
|
|
13009
13021
|
const u = /<svg.*?<\/svg>/s, h = A.match(u) || [], m = (h == null ? void 0 : h.length) > 0 ? h[0] : "", f = dt().parseFromString(m, "image/svg+xml").firstElementChild;
|
|
13010
13022
|
if (!f)
|
|
13011
|
-
throw new
|
|
13012
|
-
return pa(f),
|
|
13023
|
+
throw new xt("Failed to read SVG.");
|
|
13024
|
+
return pa(f), Bt().serializeToString(f);
|
|
13013
13025
|
};
|
|
13014
13026
|
l.forEach((A) => {
|
|
13015
13027
|
const u = r.find((m) => m.panelId === A.panelId);
|
|
@@ -13034,7 +13046,7 @@ const zo = [
|
|
|
13034
13046
|
productOverlay: t.type === P.ProductOverlay ? !0 : void 0,
|
|
13035
13047
|
excludeFromExport: t.data.excludeFromPrint
|
|
13036
13048
|
};
|
|
13037
|
-
a.push(new
|
|
13049
|
+
a.push(new z(h, u));
|
|
13038
13050
|
});
|
|
13039
13051
|
}
|
|
13040
13052
|
return a;
|
|
@@ -13060,7 +13072,7 @@ const zo = [
|
|
|
13060
13072
|
assetUrl: p,
|
|
13061
13073
|
name: f.names.fullName.en
|
|
13062
13074
|
};
|
|
13063
|
-
})(), A = (a.data.replaceableText ? a.data.replaceableText.replace("{{}}", i.text) : i.text) || "", u =
|
|
13075
|
+
})(), A = (a.data.replaceableText ? a.data.replaceableText.replace("{{}}", i.text) : i.text) || "", u = be(A, {
|
|
13064
13076
|
vertical: a.data.vertical,
|
|
13065
13077
|
uppercase: a.data.uppercase
|
|
13066
13078
|
}), h = async (p) => {
|
|
@@ -13101,7 +13113,7 @@ const zo = [
|
|
|
13101
13113
|
d,
|
|
13102
13114
|
p,
|
|
13103
13115
|
[
|
|
13104
|
-
|
|
13116
|
+
be(u, {
|
|
13105
13117
|
vertical: a.data.vertical,
|
|
13106
13118
|
uppercase: a.data.uppercase
|
|
13107
13119
|
})
|
|
@@ -13113,7 +13125,7 @@ const zo = [
|
|
|
13113
13125
|
}
|
|
13114
13126
|
);
|
|
13115
13127
|
n.push(
|
|
13116
|
-
new
|
|
13128
|
+
new z(
|
|
13117
13129
|
{
|
|
13118
13130
|
...C,
|
|
13119
13131
|
fontSize: w,
|
|
@@ -13124,7 +13136,7 @@ const zo = [
|
|
|
13124
13136
|
)
|
|
13125
13137
|
);
|
|
13126
13138
|
} else
|
|
13127
|
-
n.push(new
|
|
13139
|
+
n.push(new z(C, f));
|
|
13128
13140
|
}
|
|
13129
13141
|
return n;
|
|
13130
13142
|
}, _o = (r, t) => r.conditions ? r.conditions.every((e) => {
|
|
@@ -13144,7 +13156,7 @@ const zo = [
|
|
|
13144
13156
|
switch (o.type) {
|
|
13145
13157
|
case P.DigitalContent:
|
|
13146
13158
|
n.push(
|
|
13147
|
-
...await
|
|
13159
|
+
...await zo(e, s, o)
|
|
13148
13160
|
);
|
|
13149
13161
|
break;
|
|
13150
13162
|
case P.Frame:
|
|
@@ -13299,7 +13311,7 @@ class al {
|
|
|
13299
13311
|
);
|
|
13300
13312
|
}
|
|
13301
13313
|
}
|
|
13302
|
-
class nl extends
|
|
13314
|
+
class nl extends Fn {
|
|
13303
13315
|
constructor(t, e, a, n, i, s) {
|
|
13304
13316
|
super(), this.layoutId = t, this.ctx = e, this.nonPOTSupport = a, this.onRender = n, this.layouts = i, this.getWorkflowManager = s;
|
|
13305
13317
|
}
|
|
@@ -13434,19 +13446,19 @@ class rl {
|
|
|
13434
13446
|
}
|
|
13435
13447
|
async createHandle(t) {
|
|
13436
13448
|
switch (t.type) {
|
|
13437
|
-
case
|
|
13449
|
+
case j.FileUpload:
|
|
13438
13450
|
return new il(this.bundle, t).initialize();
|
|
13439
|
-
case
|
|
13451
|
+
case j.ColorOption:
|
|
13440
13452
|
return new Ka(
|
|
13441
13453
|
this.bundle,
|
|
13442
13454
|
t,
|
|
13443
13455
|
t.entityId ? await Y.getOption(t.entityId) : void 0
|
|
13444
13456
|
);
|
|
13445
|
-
case
|
|
13457
|
+
case j.Option: {
|
|
13446
13458
|
const e = t.entityId ? await Y.getOption(t.entityId) : void 0;
|
|
13447
13459
|
return (e == null ? void 0 : e.type) === "Color" ? new Ka(this.bundle, t, e) : new tr(this.bundle, t, e);
|
|
13448
13460
|
}
|
|
13449
|
-
case
|
|
13461
|
+
case j.Text:
|
|
13450
13462
|
return new sl(this.bundle, t);
|
|
13451
13463
|
default:
|
|
13452
13464
|
throw new Error("Unhandled Global Property Aspect Type");
|
|
@@ -13521,7 +13533,7 @@ class il extends Ia {
|
|
|
13521
13533
|
const t = await this.getImage();
|
|
13522
13534
|
if (t != null && t.fileLink)
|
|
13523
13535
|
if (t != null && t.fileLink.endsWith(".svg")) {
|
|
13524
|
-
const a = await at(t == null ? void 0 : t.fileLink), n = await
|
|
13536
|
+
const a = await at(t == null ? void 0 : t.fileLink), n = await ba(t == null ? void 0 : t.fileLink), i = n.width, s = n.height, o = await lt(a), l = this.bundle.getGlobalPropertyStateManager().getAspectStorage(this.property.name);
|
|
13525
13537
|
(e = l == null ? void 0 : l.colors) == null || e.forEach((d) => {
|
|
13526
13538
|
o.colors[d.key] = {
|
|
13527
13539
|
browserValue: d.browserValue,
|
|
@@ -13574,7 +13586,7 @@ class il extends Ia {
|
|
|
13574
13586
|
const e = await this.getOriginalImage();
|
|
13575
13587
|
if (!e)
|
|
13576
13588
|
throw new Error("You must supply an image selection before attempting to remove the background.");
|
|
13577
|
-
const a = this.bundle.getGlobalPropertyStateManager(), n = await
|
|
13589
|
+
const a = this.bundle.getGlobalPropertyStateManager(), n = await L.removeBackgroundFromAsset(e), s = {
|
|
13578
13590
|
...a.getAspectStorage(this.property.name),
|
|
13579
13591
|
backgroundRemovedAssetKey: n.key,
|
|
13580
13592
|
useOriginalAsset: !t
|
|
@@ -13594,7 +13606,7 @@ class il extends Ia {
|
|
|
13594
13606
|
async getImage() {
|
|
13595
13607
|
const t = this.getStateValue();
|
|
13596
13608
|
if (t)
|
|
13597
|
-
return
|
|
13609
|
+
return L.getLocalOrFromServer(t);
|
|
13598
13610
|
}
|
|
13599
13611
|
async getImageWithColors() {
|
|
13600
13612
|
var t, e;
|
|
@@ -13607,7 +13619,7 @@ class il extends Ia {
|
|
|
13607
13619
|
async getOriginalImage() {
|
|
13608
13620
|
const t = this.bundle.getGlobalPropertyStateManager().getAspectStorage(this.property.name);
|
|
13609
13621
|
if (t != null && t.originalAssetKey)
|
|
13610
|
-
return
|
|
13622
|
+
return L.getLocalOrFromServer(t.originalAssetKey);
|
|
13611
13623
|
}
|
|
13612
13624
|
/**
|
|
13613
13625
|
* Retrieves the version of the image selection that has the background removed, if one exists.
|
|
@@ -13616,7 +13628,7 @@ class il extends Ia {
|
|
|
13616
13628
|
async getBackgroundRemovedImage() {
|
|
13617
13629
|
const t = this.bundle.getGlobalPropertyStateManager().getAspectStorage(this.property.name);
|
|
13618
13630
|
if (t != null && t.backgroundRemovedAssetKey)
|
|
13619
|
-
return
|
|
13631
|
+
return L.getLocalOrFromServer(t.backgroundRemovedAssetKey);
|
|
13620
13632
|
}
|
|
13621
13633
|
getUseOriginalImage() {
|
|
13622
13634
|
var t;
|
|
@@ -13652,7 +13664,7 @@ class il extends Ia {
|
|
|
13652
13664
|
const e = this.getStateValue();
|
|
13653
13665
|
if (!e)
|
|
13654
13666
|
return;
|
|
13655
|
-
const a = await
|
|
13667
|
+
const a = await L.getLocalOrFromServer(e);
|
|
13656
13668
|
if (!a)
|
|
13657
13669
|
return;
|
|
13658
13670
|
await this.applyImageSelection(a, t, !1, !0);
|
|
@@ -13760,7 +13772,7 @@ class sl extends Ia {
|
|
|
13760
13772
|
* Set the text.
|
|
13761
13773
|
*/
|
|
13762
13774
|
async setText(t) {
|
|
13763
|
-
await Promise.all([
|
|
13775
|
+
console.log(`LOG: global setting text ${t}`), await Promise.all([
|
|
13764
13776
|
this.bundle.getGlobalPropertyStateManager().setAspect(this.property.name, t),
|
|
13765
13777
|
this.applyTextSelection(t)
|
|
13766
13778
|
]);
|
|
@@ -13772,7 +13784,9 @@ class sl extends Ia {
|
|
|
13772
13784
|
await this.applyTextSelection(e, t);
|
|
13773
13785
|
}
|
|
13774
13786
|
async applyTextSelection(t, e) {
|
|
13775
|
-
const
|
|
13787
|
+
const a = this.getSharedSteps(e);
|
|
13788
|
+
console.log(`LOG: applying text selection to ${a.length} steps`);
|
|
13789
|
+
const n = a.map((i) => {
|
|
13776
13790
|
i.setText(t);
|
|
13777
13791
|
});
|
|
13778
13792
|
await Promise.all(n);
|
|
@@ -14038,23 +14052,24 @@ class cl {
|
|
|
14038
14052
|
var e, a;
|
|
14039
14053
|
if (!this.globalPropertyState)
|
|
14040
14054
|
throw new Error("Global property state not initialized");
|
|
14041
|
-
|
|
14042
|
-
|
|
14055
|
+
console.log(`LOG: setting state ${this.globalPropertyState.id} with ${this.globalPropertyState.aspects.length} aspects`), console.trace();
|
|
14056
|
+
const t = await B.getShadowGraphqlClient().mutate({
|
|
14057
|
+
mutation: Us,
|
|
14043
14058
|
variables: {
|
|
14044
14059
|
id: this.globalPropertyState.id,
|
|
14045
14060
|
aspects: this.globalPropertyState.aspects.map((n) => {
|
|
14046
14061
|
let i = n.type && n.storage ? {} : void 0;
|
|
14047
14062
|
if (i)
|
|
14048
14063
|
switch (n.type) {
|
|
14049
|
-
case
|
|
14064
|
+
case j.FileUpload: {
|
|
14050
14065
|
i.fileUpload = n.storage;
|
|
14051
14066
|
break;
|
|
14052
14067
|
}
|
|
14053
|
-
case
|
|
14068
|
+
case j.Option: {
|
|
14054
14069
|
i.option = n.storage;
|
|
14055
14070
|
break;
|
|
14056
14071
|
}
|
|
14057
|
-
case
|
|
14072
|
+
case j.ColorOption: {
|
|
14058
14073
|
i = n.storage;
|
|
14059
14074
|
break;
|
|
14060
14075
|
}
|
|
@@ -14082,8 +14097,8 @@ class cl {
|
|
|
14082
14097
|
}
|
|
14083
14098
|
async createGlobalPropertyState() {
|
|
14084
14099
|
var e, a;
|
|
14085
|
-
const t = await
|
|
14086
|
-
mutation:
|
|
14100
|
+
const t = await B.getShadowGraphqlClient().mutate({
|
|
14101
|
+
mutation: Ls,
|
|
14087
14102
|
variables: {
|
|
14088
14103
|
bundleId: this.bundleId
|
|
14089
14104
|
},
|
|
@@ -14220,7 +14235,7 @@ class ul {
|
|
|
14220
14235
|
async ensureIdsArePresent(t) {
|
|
14221
14236
|
if (t.every((a) => this.internalMap.has(a)))
|
|
14222
14237
|
return;
|
|
14223
|
-
const e = await
|
|
14238
|
+
const e = await B.getShadowGraphqlClient().query({
|
|
14224
14239
|
query: Al,
|
|
14225
14240
|
errorPolicy: "all",
|
|
14226
14241
|
variables: {
|
|
@@ -14308,7 +14323,7 @@ class er {
|
|
|
14308
14323
|
async fetchProducts(t) {
|
|
14309
14324
|
if (this.fullFetched)
|
|
14310
14325
|
return this.collection.productCollectionProducts.filter((a) => !!a.product).map((a) => new de(a));
|
|
14311
|
-
const e = await
|
|
14326
|
+
const e = await B.getShadowGraphqlClient().query({
|
|
14312
14327
|
query: js,
|
|
14313
14328
|
variables: {
|
|
14314
14329
|
id: this.getId(),
|
|
@@ -14325,7 +14340,7 @@ class er {
|
|
|
14325
14340
|
*/
|
|
14326
14341
|
async filterProducts(t, e, a, n) {
|
|
14327
14342
|
var l, c;
|
|
14328
|
-
const i = await
|
|
14343
|
+
const i = await B.getShadowGraphqlClient().query({
|
|
14329
14344
|
query: qs,
|
|
14330
14345
|
errorPolicy: "all",
|
|
14331
14346
|
variables: {
|
|
@@ -14365,7 +14380,7 @@ class er {
|
|
|
14365
14380
|
items: d.slice(t, t + e)
|
|
14366
14381
|
};
|
|
14367
14382
|
}
|
|
14368
|
-
const o = new AbortController(), { signal: l } = o, c =
|
|
14383
|
+
const o = new AbortController(), { signal: l } = o, c = B.getShadowGraphqlClient().watchQuery({
|
|
14369
14384
|
query: Hs,
|
|
14370
14385
|
variables: {
|
|
14371
14386
|
id: this.getId(),
|
|
@@ -14642,7 +14657,7 @@ const fl = v`
|
|
|
14642
14657
|
}
|
|
14643
14658
|
`, od = async (r) => {
|
|
14644
14659
|
var e, a;
|
|
14645
|
-
return (a = (e = (await
|
|
14660
|
+
return (a = (e = (await B.getShadowGraphqlClient().query({
|
|
14646
14661
|
query: fl,
|
|
14647
14662
|
errorPolicy: "all",
|
|
14648
14663
|
variables: {
|
|
@@ -14715,41 +14730,23 @@ const wl = v`
|
|
|
14715
14730
|
`;
|
|
14716
14731
|
class Je {
|
|
14717
14732
|
constructor(t, e, a, n, i, s) {
|
|
14718
|
-
var c, d
|
|
14719
|
-
this.workflowExperiences = [], this.eventEmitter = new Cl(), this.client = t, this.id = e.id, this.name = e.name || "", this.template = e.template || !1, this.quoteId = e.quoteId, this.shareActions = e.bundleShareActions, this.workflowViewerLink = e.workflowViewerLink, this.workflowViewerAmendLink = e.workflowViewerAmendLink, this.ownerId = i, this.metadata = new Map(((
|
|
14720
|
-
const o = (
|
|
14733
|
+
var l, c, d;
|
|
14734
|
+
this.workflowExperiences = [], this.eventEmitter = new Cl(), this.client = t, this.id = e.id, this.name = e.name || "", this.template = e.template || !1, this.quoteId = e.quoteId, this.shareActions = e.bundleShareActions, this.workflowViewerLink = e.workflowViewerLink, this.workflowViewerAmendLink = e.workflowViewerAmendLink, this.ownerId = i, this.metadata = new Map(((l = e.metadata) == null ? void 0 : l.map((A) => [A.key, A.value])) || []), this.completed = e.completed ?? !1, this.productCollection = e.productCollection, this.bundleStateManager = new dl(e.bundleStateData);
|
|
14735
|
+
const o = (c = this.productCollection) == null ? void 0 : c.globalPropertyConfiguration;
|
|
14721
14736
|
this.globalConfigurationPropertyId = o == null ? void 0 : o.id, this.globalPropertyStateManager = new cl(
|
|
14722
14737
|
this.id,
|
|
14723
14738
|
this.ownerId,
|
|
14724
14739
|
o,
|
|
14725
14740
|
this.checkConditionalHandlesChanged.bind(this),
|
|
14726
14741
|
s
|
|
14727
|
-
), this.globalPropertyHandleService = new rl(this), this.setPreviewService(a)
|
|
14728
|
-
|
|
14729
|
-
if (s != null && s.readonly) {
|
|
14730
|
-
u([]);
|
|
14731
|
-
return;
|
|
14732
|
-
}
|
|
14733
|
-
console.log("Setting default global variants."), this.globalPropertyHandleService.getHandles().then((m) => {
|
|
14734
|
-
const g = m.map((p) => {
|
|
14735
|
-
if (p.getType() === z.ColorOption || p.getType() === z.Option) {
|
|
14736
|
-
const f = p;
|
|
14737
|
-
if (this.globalPropertyStateManager.getGlobalPropertyState())
|
|
14738
|
-
return f.initDefaultVariant();
|
|
14739
|
-
console.log("Attempted to set global default variant before state was initialized.");
|
|
14740
|
-
}
|
|
14741
|
-
});
|
|
14742
|
-
Promise.all(g).then(u).catch(h);
|
|
14743
|
-
});
|
|
14744
|
-
});
|
|
14745
|
-
this.initializationPromise = Promise.all([
|
|
14746
|
-
this.loadExistingWorkflowExperiences(((A = e.transactions) == null ? void 0 : A.map((u) => u.id)) || [], {
|
|
14742
|
+
), this.globalPropertyHandleService = new rl(this), this.setPreviewService(a), this.initializationPromise = Promise.all([
|
|
14743
|
+
this.loadExistingWorkflowExperiences(((d = e.transactions) == null ? void 0 : d.map((A) => A.id)) || [], {
|
|
14747
14744
|
...n,
|
|
14748
14745
|
bundleOwnerId: i
|
|
14749
14746
|
}),
|
|
14750
14747
|
this.globalPropertyStateManager.getInitializationPromise()
|
|
14751
|
-
])
|
|
14752
|
-
console.error(`Bundle initialization failed: ${
|
|
14748
|
+
]), this.initializationPromise.catch((A) => {
|
|
14749
|
+
console.error(`Bundle initialization failed: ${A}`);
|
|
14753
14750
|
});
|
|
14754
14751
|
}
|
|
14755
14752
|
getTemplate() {
|
|
@@ -14757,7 +14754,7 @@ class Je {
|
|
|
14757
14754
|
}
|
|
14758
14755
|
async generateQuoteId() {
|
|
14759
14756
|
var a, n;
|
|
14760
|
-
const e = (n = (a = (await
|
|
14757
|
+
const e = (n = (a = (await B.getShadowGraphqlClient().mutate({
|
|
14761
14758
|
mutation: Sl,
|
|
14762
14759
|
variables: {
|
|
14763
14760
|
id: this.id
|
|
@@ -14769,7 +14766,7 @@ class Je {
|
|
|
14769
14766
|
return this.quoteId = e, e || "";
|
|
14770
14767
|
}
|
|
14771
14768
|
async attachAddress(t, e, a, n, i, s) {
|
|
14772
|
-
await
|
|
14769
|
+
await B.getShadowGraphqlClient().mutate({
|
|
14773
14770
|
mutation: wl,
|
|
14774
14771
|
variables: {
|
|
14775
14772
|
bundleId: this.id,
|
|
@@ -14786,7 +14783,7 @@ class Je {
|
|
|
14786
14783
|
});
|
|
14787
14784
|
}
|
|
14788
14785
|
async attachOrganization(t) {
|
|
14789
|
-
await
|
|
14786
|
+
await B.getShadowGraphqlClient().mutate({
|
|
14790
14787
|
mutation: yl,
|
|
14791
14788
|
variables: {
|
|
14792
14789
|
bundleId: this.id,
|
|
@@ -14861,15 +14858,15 @@ class Je {
|
|
|
14861
14858
|
}
|
|
14862
14859
|
async applyGlobalPropertyState(t) {
|
|
14863
14860
|
var a;
|
|
14864
|
-
const e = await this.
|
|
14865
|
-
for (const n of
|
|
14866
|
-
const i = n.
|
|
14861
|
+
const e = await this.globalPropertyHandleService.getHandles();
|
|
14862
|
+
for (const n of t.aspects) {
|
|
14863
|
+
const i = n == null ? void 0 : n.name, s = e.find((o) => o.getName() === i);
|
|
14867
14864
|
if (s)
|
|
14868
|
-
switch (
|
|
14869
|
-
case
|
|
14870
|
-
const o =
|
|
14865
|
+
switch (n.type) {
|
|
14866
|
+
case j.FileUpload: {
|
|
14867
|
+
const o = s, l = await ve([n.value]);
|
|
14871
14868
|
l.length > 0 && await o.selectImage(l[0]);
|
|
14872
|
-
const c = (a =
|
|
14869
|
+
const c = (a = n.storage) == null ? void 0 : a.colors;
|
|
14873
14870
|
if (c) {
|
|
14874
14871
|
const d = Object.fromEntries(
|
|
14875
14872
|
c.map((A) => [A.key, { browserValue: A.browserValue, pmsValue: A.pmsValue }]) ?? []
|
|
@@ -14878,22 +14875,22 @@ class Je {
|
|
|
14878
14875
|
}
|
|
14879
14876
|
break;
|
|
14880
14877
|
}
|
|
14881
|
-
case
|
|
14882
|
-
const o =
|
|
14883
|
-
if (
|
|
14884
|
-
const c = o.getAllVariants().find((d) => d.getId() ===
|
|
14878
|
+
case j.ColorOption: {
|
|
14879
|
+
const o = s;
|
|
14880
|
+
if (n.type === j.ColorOption) {
|
|
14881
|
+
const c = o.getAllVariants().find((d) => d.getId() === n.value);
|
|
14885
14882
|
c && await o.selectVariant(c);
|
|
14886
14883
|
} else
|
|
14887
|
-
o.setCustomColor(
|
|
14884
|
+
o.setCustomColor(n.value);
|
|
14888
14885
|
break;
|
|
14889
14886
|
}
|
|
14890
|
-
case
|
|
14891
|
-
const o =
|
|
14887
|
+
case j.Option: {
|
|
14888
|
+
const o = s, c = o.getAllVariants().find((d) => d.getId() === n.value);
|
|
14892
14889
|
c && await o.selectVariant(c);
|
|
14893
14890
|
break;
|
|
14894
14891
|
}
|
|
14895
|
-
case
|
|
14896
|
-
await
|
|
14892
|
+
case j.Text: {
|
|
14893
|
+
await s.setText(n.value);
|
|
14897
14894
|
break;
|
|
14898
14895
|
}
|
|
14899
14896
|
}
|
|
@@ -14903,7 +14900,7 @@ class Je {
|
|
|
14903
14900
|
return this.globalPropertyStateManager;
|
|
14904
14901
|
}
|
|
14905
14902
|
async getGlobalPropertyTotalSubunits() {
|
|
14906
|
-
return (await this.globalPropertyHandleService.getHandles()).filter((a) => a.getType() ===
|
|
14903
|
+
return (await this.globalPropertyHandleService.getHandles()).filter((a) => a.getType() === j.Option).map((a) => {
|
|
14907
14904
|
var n;
|
|
14908
14905
|
return ((n = a.getCurrentVariant()) == null ? void 0 : n.getPrice()) || 0;
|
|
14909
14906
|
}).reduce((a, n) => a + n, 0);
|
|
@@ -14922,7 +14919,7 @@ class Je {
|
|
|
14922
14919
|
const c = (e = this.getGlobalPropertyConfiguration()) == null ? void 0 : e.aspects.find(
|
|
14923
14920
|
(d) => d.name === l
|
|
14924
14921
|
);
|
|
14925
|
-
if (c && c.type ===
|
|
14922
|
+
if (c && c.type === j.ColorOption) {
|
|
14926
14923
|
const d = (a = s.getCurrentVariant()) == null ? void 0 : a.getAssetResource(), A = ((n = d == null ? void 0 : d.assetConfiguration) == null ? void 0 : n.channelNumbers) || [], u = ((i = d == null ? void 0 : d.assetConfiguration) == null ? void 0 : i.defaultColorVariants) || [], h = ll(
|
|
14927
14924
|
this.getWorkflowExperiences(),
|
|
14928
14925
|
this.globalConfigurationPropertyId || "",
|
|
@@ -14957,7 +14954,7 @@ class Je {
|
|
|
14957
14954
|
"Unable to add transaction to bundle - Already Exists: " + a.filter((o) => !!o).map((o) => o == null ? void 0 : o.getWorkflowManager().getTransaction().id).join(", ")
|
|
14958
14955
|
);
|
|
14959
14956
|
const n = N.getMap("transactionOwnerIds") || /* @__PURE__ */ new Map(), i = e.map((o) => n.get(o));
|
|
14960
|
-
await
|
|
14957
|
+
await B.getShadowGraphqlClient().mutate({
|
|
14961
14958
|
mutation: Xs,
|
|
14962
14959
|
variables: {
|
|
14963
14960
|
id: this.id,
|
|
@@ -14989,7 +14986,7 @@ class Je {
|
|
|
14989
14986
|
))
|
|
14990
14987
|
throw new Error("Unable to add transaction to bundle - Already Exists!");
|
|
14991
14988
|
const s = (N.getMap("transactionOwnerIds") || /* @__PURE__ */ new Map()).get(a);
|
|
14992
|
-
await
|
|
14989
|
+
await B.getShadowGraphqlClient().mutate({
|
|
14993
14990
|
mutation: _s,
|
|
14994
14991
|
variables: {
|
|
14995
14992
|
id: this.id,
|
|
@@ -15024,7 +15021,7 @@ class Je {
|
|
|
15024
15021
|
const n = this.workflowExperiences.find(
|
|
15025
15022
|
(i) => i.getWorkflowManager().getTransaction().id === e.id
|
|
15026
15023
|
);
|
|
15027
|
-
if (n.setBundle(void 0), this.previewService && n.getWorkflowManager().ejectFromPreviewService(), this.bundleStateManager.removeStateForTransaction(e.id), await
|
|
15024
|
+
if (n.setBundle(void 0), this.previewService && n.getWorkflowManager().ejectFromPreviewService(), this.bundleStateManager.removeStateForTransaction(e.id), await B.getShadowGraphqlClient().mutate({
|
|
15028
15025
|
mutation: Zs,
|
|
15029
15026
|
variables: {
|
|
15030
15027
|
id: this.id,
|
|
@@ -15061,7 +15058,7 @@ class Je {
|
|
|
15061
15058
|
);
|
|
15062
15059
|
a.forEach((n) => n.setBundle(void 0)), [...this.workflowExperiences, ...a].forEach(
|
|
15063
15060
|
(n) => n.checkForPriceBreakChanges()
|
|
15064
|
-
), this.previewService && a.forEach((n) => n.getWorkflowManager().ejectFromPreviewService()), t.forEach((n) => this.bundleStateManager.removeStateForTransaction(n.id)), await
|
|
15061
|
+
), this.previewService && a.forEach((n) => n.getWorkflowManager().ejectFromPreviewService()), t.forEach((n) => this.bundleStateManager.removeStateForTransaction(n.id)), await B.getShadowGraphqlClient().mutate({
|
|
15065
15062
|
mutation: to,
|
|
15066
15063
|
variables: {
|
|
15067
15064
|
id: this.id,
|
|
@@ -15124,7 +15121,7 @@ class Je {
|
|
|
15124
15121
|
}
|
|
15125
15122
|
async addStakeholder(t, e) {
|
|
15126
15123
|
var i;
|
|
15127
|
-
const a = await
|
|
15124
|
+
const a = await B.getShadowGraphqlClient().mutate({
|
|
15128
15125
|
mutation: eo,
|
|
15129
15126
|
variables: {
|
|
15130
15127
|
id: this.id,
|
|
@@ -15142,7 +15139,7 @@ class Je {
|
|
|
15142
15139
|
}
|
|
15143
15140
|
async removeStakeholder(t) {
|
|
15144
15141
|
var a;
|
|
15145
|
-
if (!((a = (await
|
|
15142
|
+
if (!((a = (await B.getShadowGraphqlClient().mutate({
|
|
15146
15143
|
mutation: ao,
|
|
15147
15144
|
variables: {
|
|
15148
15145
|
id: this.id,
|
|
@@ -15156,7 +15153,7 @@ class Je {
|
|
|
15156
15153
|
}
|
|
15157
15154
|
async updateStakeholders(t) {
|
|
15158
15155
|
var n;
|
|
15159
|
-
const e = await
|
|
15156
|
+
const e = await B.getShadowGraphqlClient().mutate({
|
|
15160
15157
|
mutation: no,
|
|
15161
15158
|
variables: {
|
|
15162
15159
|
id: this.id,
|
|
@@ -15172,7 +15169,7 @@ class Je {
|
|
|
15172
15169
|
this.storeStakeholderCustomers(a);
|
|
15173
15170
|
}
|
|
15174
15171
|
async getAllStakeholders() {
|
|
15175
|
-
const t = await
|
|
15172
|
+
const t = await B.getShadowGraphqlClient().query({
|
|
15176
15173
|
query: Ya,
|
|
15177
15174
|
errorPolicy: "all",
|
|
15178
15175
|
fetchPolicy: "no-cache",
|
|
@@ -15189,7 +15186,7 @@ class Je {
|
|
|
15189
15186
|
return this.storeStakeholderCustomers(e), e;
|
|
15190
15187
|
}
|
|
15191
15188
|
async getCurrentStakeholder() {
|
|
15192
|
-
const t = await
|
|
15189
|
+
const t = await B.getShadowGraphqlClient().query({
|
|
15193
15190
|
query: Ya,
|
|
15194
15191
|
errorPolicy: "all",
|
|
15195
15192
|
fetchPolicy: "no-cache",
|
|
@@ -15211,7 +15208,7 @@ class Je {
|
|
|
15211
15208
|
}
|
|
15212
15209
|
async finish(t, e) {
|
|
15213
15210
|
if (this.completed)
|
|
15214
|
-
return await
|
|
15211
|
+
return await B.getShadowGraphqlClient().mutate({
|
|
15215
15212
|
mutation: lo,
|
|
15216
15213
|
variables: {
|
|
15217
15214
|
bundleId: this.id
|
|
@@ -15273,7 +15270,7 @@ class Je {
|
|
|
15273
15270
|
return this.bundleStateManager.activateWorkflowExperienceTransform(t, e), this.updateBundle();
|
|
15274
15271
|
}
|
|
15275
15272
|
async assignGlobalPropertyConfiguration(t) {
|
|
15276
|
-
await
|
|
15273
|
+
await B.getShadowGraphqlClient().mutate({
|
|
15277
15274
|
mutation: so,
|
|
15278
15275
|
variables: {
|
|
15279
15276
|
bundleId: this.id,
|
|
@@ -15286,7 +15283,7 @@ class Je {
|
|
|
15286
15283
|
}
|
|
15287
15284
|
async assignProductCollection(t) {
|
|
15288
15285
|
var a, n;
|
|
15289
|
-
const e = await
|
|
15286
|
+
const e = await B.getShadowGraphqlClient().mutate({
|
|
15290
15287
|
mutation: io(
|
|
15291
15288
|
((a = this.globalPropertyStateManager.getBundleOptions()) == null ? void 0 : a.eagerFetchProducts) ?? !1
|
|
15292
15289
|
),
|
|
@@ -15344,7 +15341,7 @@ class Je {
|
|
|
15344
15341
|
}
|
|
15345
15342
|
async updateBundle() {
|
|
15346
15343
|
var e;
|
|
15347
|
-
if (!((e = (await
|
|
15344
|
+
if (!((e = (await B.getShadowGraphqlClient().mutate({
|
|
15348
15345
|
mutation: Ks,
|
|
15349
15346
|
variables: {
|
|
15350
15347
|
id: this.id,
|
|
@@ -15361,7 +15358,7 @@ class Je {
|
|
|
15361
15358
|
throw new Error("Bundle not found!");
|
|
15362
15359
|
}
|
|
15363
15360
|
async updateTransactionOrder() {
|
|
15364
|
-
await
|
|
15361
|
+
await B.getShadowGraphqlClient().mutate({
|
|
15365
15362
|
mutation: ro,
|
|
15366
15363
|
variables: {
|
|
15367
15364
|
id: this.id,
|
|
@@ -15402,7 +15399,7 @@ class Je {
|
|
|
15402
15399
|
return this.workflowViewerAmendLink;
|
|
15403
15400
|
}
|
|
15404
15401
|
async approve(t, e) {
|
|
15405
|
-
await
|
|
15402
|
+
await B.getShadowGraphqlClient().mutate({
|
|
15406
15403
|
mutation: co,
|
|
15407
15404
|
errorPolicy: "all",
|
|
15408
15405
|
fetchPolicy: "no-cache",
|
|
@@ -15414,7 +15411,7 @@ class Je {
|
|
|
15414
15411
|
});
|
|
15415
15412
|
}
|
|
15416
15413
|
async reject(t, e) {
|
|
15417
|
-
await
|
|
15414
|
+
await B.getShadowGraphqlClient().mutate({
|
|
15418
15415
|
mutation: Ao,
|
|
15419
15416
|
errorPolicy: "all",
|
|
15420
15417
|
fetchPolicy: "no-cache",
|
|
@@ -15450,7 +15447,7 @@ class El {
|
|
|
15450
15447
|
*/
|
|
15451
15448
|
async execute(t, e, a) {
|
|
15452
15449
|
var A, u, h;
|
|
15453
|
-
const i = (u = (A = (await
|
|
15450
|
+
const i = (u = (A = (await B.getShadowGraphqlClient().mutate({
|
|
15454
15451
|
mutation: vl,
|
|
15455
15452
|
variables: {
|
|
15456
15453
|
processFlowId: t,
|
|
@@ -15466,7 +15463,7 @@ class El {
|
|
|
15466
15463
|
}
|
|
15467
15464
|
let o = !1, l = 0, c, d;
|
|
15468
15465
|
for (; !o; ) {
|
|
15469
|
-
c = await
|
|
15466
|
+
c = await B.getShadowGraphqlClient().query({
|
|
15470
15467
|
query: v`
|
|
15471
15468
|
query getProcessFlowExecution($ids: [String]!) {
|
|
15472
15469
|
processExecutions(ids: $ids) {
|
|
@@ -15493,7 +15490,7 @@ class El {
|
|
|
15493
15490
|
"Execution has failed to complete. See Automation > FLows in Flight on partner account on SpiffCommerce Hub."
|
|
15494
15491
|
);
|
|
15495
15492
|
if (m.completedAt) {
|
|
15496
|
-
o = !0, d = new
|
|
15493
|
+
o = !0, d = new bl(m);
|
|
15497
15494
|
break;
|
|
15498
15495
|
}
|
|
15499
15496
|
l += 1;
|
|
@@ -15507,7 +15504,7 @@ class El {
|
|
|
15507
15504
|
return Promise.resolve(d);
|
|
15508
15505
|
}
|
|
15509
15506
|
}
|
|
15510
|
-
class
|
|
15507
|
+
class bl {
|
|
15511
15508
|
constructor(t) {
|
|
15512
15509
|
this.execution = t;
|
|
15513
15510
|
}
|
|
@@ -15592,7 +15589,7 @@ class Pa {
|
|
|
15592
15589
|
return t.startsWith("[") ? JSON.stringify(JSON.parse(t)) : t;
|
|
15593
15590
|
}
|
|
15594
15591
|
}
|
|
15595
|
-
var
|
|
15592
|
+
var Bl = /* @__PURE__ */ ((r) => (r.Transaction = "Transaction", r.Bundle = "Bundle", r.Product = "Product", r.Variant = "Variant", r.Option = "Option", r.LineItem = "LineItem", r.Asset = "Asset", r))(Bl || {});
|
|
15596
15593
|
class ld extends Pa {
|
|
15597
15594
|
constructor(t) {
|
|
15598
15595
|
super(`"${t}"`);
|
|
@@ -15764,8 +15761,8 @@ const Dl = v`
|
|
|
15764
15761
|
}
|
|
15765
15762
|
}
|
|
15766
15763
|
`;
|
|
15767
|
-
class
|
|
15768
|
-
constructor(t, e =
|
|
15764
|
+
class xl {
|
|
15765
|
+
constructor(t, e = B.getShadowGraphqlClient.bind(B)) {
|
|
15769
15766
|
this.options = t, this.client = e;
|
|
15770
15767
|
}
|
|
15771
15768
|
query(t) {
|
|
@@ -15793,7 +15790,7 @@ class Fl {
|
|
|
15793
15790
|
});
|
|
15794
15791
|
}
|
|
15795
15792
|
}
|
|
15796
|
-
class
|
|
15793
|
+
class Fl {
|
|
15797
15794
|
init(t, e, a) {
|
|
15798
15795
|
this.cognitoClient = new wr({ region: e }), this.spiffRegion = t, this.userPoolClientId = a;
|
|
15799
15796
|
}
|
|
@@ -15845,7 +15842,7 @@ class xl {
|
|
|
15845
15842
|
));
|
|
15846
15843
|
}
|
|
15847
15844
|
}
|
|
15848
|
-
const
|
|
15845
|
+
const Ut = new Fl();
|
|
15849
15846
|
class kl {
|
|
15850
15847
|
/**
|
|
15851
15848
|
* Returns a formatted string representing a given amount with desired currency.
|
|
@@ -15923,7 +15920,7 @@ class Ml {
|
|
|
15923
15920
|
}
|
|
15924
15921
|
const Tl = async (r, t) => {
|
|
15925
15922
|
var n;
|
|
15926
|
-
const e = await
|
|
15923
|
+
const e = await B.getShadowGraphqlClient().query({
|
|
15927
15924
|
query: Ni(((n = t == null ? void 0 : t.assets) == null ? void 0 : n.metadata) || !1),
|
|
15928
15925
|
errorPolicy: "all",
|
|
15929
15926
|
variables: {
|
|
@@ -15940,8 +15937,8 @@ const Tl = async (r, t) => {
|
|
|
15940
15937
|
return a.forEach((i) => {
|
|
15941
15938
|
i.steps.forEach((s) => {
|
|
15942
15939
|
var o, l, c;
|
|
15943
|
-
delete s.data.__typename, (o = s.option) != null && o.id && ((l = s.option.defaultVariant) != null && l.asset &&
|
|
15944
|
-
d.asset &&
|
|
15940
|
+
delete s.data.__typename, (o = s.option) != null && o.id && ((l = s.option.defaultVariant) != null && l.asset && L.cacheAsset(s.option.defaultVariant.asset), s.option.colorProfile && L.cacheAsset(s.option.colorProfile), (c = s.option.variants) == null || c.forEach((d) => {
|
|
15941
|
+
d.asset && L.cacheAsset(d.asset), d.thumbnail && L.cacheAsset(d.thumbnail), d.material && L.cacheMaterial(d.material);
|
|
15945
15942
|
}), Jt.set({ id: s.option.id }, Promise.resolve(s.option)));
|
|
15946
15943
|
}), i.finalizeStepConfig || (i.finalizeStepConfig = {}), i.finalizeStepConfig.termsMarkdown = i.finalizeStepConfig.termsMarkdown || i.partner.termsMarkdown;
|
|
15947
15944
|
}), a;
|
|
@@ -15980,33 +15977,33 @@ class Ad {
|
|
|
15980
15977
|
constructor(t) {
|
|
15981
15978
|
this.activeIntegration = void 0, this.updateTransactionState = async (e) => {
|
|
15982
15979
|
try {
|
|
15983
|
-
return
|
|
15980
|
+
return B.getShadowGraphqlClient().mutate({
|
|
15984
15981
|
...e,
|
|
15985
15982
|
mutation: vi
|
|
15986
15983
|
});
|
|
15987
15984
|
} catch (a) {
|
|
15988
15985
|
throw console.error(a), new ut("Critical - Unable to synchronize workflow state with server.");
|
|
15989
15986
|
}
|
|
15990
|
-
}, this.options = t, this.options.applicationKey &&
|
|
15987
|
+
}, this.options = t, this.options.applicationKey && Lr(this.options.applicationKey), console.debug("------------------------"), console.debug("Spiff Commerce Core SDK"), console.debug("Version: 27.3.0-beta.d19ddd38-fcd3-5036-a764-7674af30aff5"), console.debug(`Application Key Provided: ${!!this.options.applicationKey}`), console.debug("------------------------");
|
|
15991
15988
|
}
|
|
15992
15989
|
configure(t) {
|
|
15993
|
-
mt.setHubUrl(t.hubUrl), mt.setServerUrl(t.serverUrl), mt.setServicesApiUrl(t.servicesApiUrl), this.marketplaceThemeInstallId = t.marketplaceThemeInstallId, this.marketplaceThemeInstallConfigurationId = t.marketplaceThemeInstallConfigurationId, this.userPoolClientId = t.userPoolClientId, this.userPoolRegion = t.userPoolRegion, this.spiffRegion = t.spiffRegion, t.bearerAuthenticationToken && Vr(t.bearerAuthenticationToken), this.options.applicationKey && this.getIntegration(), this.spiffRegion && this.userPoolRegion && this.userPoolClientId &&
|
|
15990
|
+
mt.setHubUrl(t.hubUrl), mt.setServerUrl(t.serverUrl), mt.setServicesApiUrl(t.servicesApiUrl), this.marketplaceThemeInstallId = t.marketplaceThemeInstallId, this.marketplaceThemeInstallConfigurationId = t.marketplaceThemeInstallConfigurationId, this.userPoolClientId = t.userPoolClientId, this.userPoolRegion = t.userPoolRegion, this.spiffRegion = t.spiffRegion, t.bearerAuthenticationToken && Vr(t.bearerAuthenticationToken), this.options.applicationKey && this.getIntegration(), this.spiffRegion && this.userPoolRegion && this.userPoolClientId && Ut.init(this.spiffRegion, this.userPoolRegion, this.userPoolClientId);
|
|
15994
15991
|
}
|
|
15995
15992
|
/**
|
|
15996
15993
|
* @returns The asset manager allows for common operations related to assets
|
|
15997
15994
|
* and the Spiff Commerce platform.
|
|
15998
15995
|
*/
|
|
15999
15996
|
getAssetManager() {
|
|
16000
|
-
return
|
|
15997
|
+
return L;
|
|
16001
15998
|
}
|
|
16002
15999
|
getFlowService() {
|
|
16003
|
-
if (!
|
|
16000
|
+
if (!Ur())
|
|
16004
16001
|
throw new Error("Application key required to use Flow Service.");
|
|
16005
16002
|
return new El();
|
|
16006
16003
|
}
|
|
16007
16004
|
async getCurrencyContext(t) {
|
|
16008
|
-
const a = (await this.getIntegration()).partner.currencyCode, i = await
|
|
16009
|
-
query:
|
|
16005
|
+
const a = (await this.getIntegration()).partner.currencyCode, i = await B.getShadowGraphqlClient().query({
|
|
16006
|
+
query: Gi,
|
|
16010
16007
|
errorPolicy: "all",
|
|
16011
16008
|
fetchPolicy: "cache-first",
|
|
16012
16009
|
variables: {
|
|
@@ -16073,7 +16070,7 @@ class Ad {
|
|
|
16073
16070
|
*/
|
|
16074
16071
|
async authenticateTransactionFromLocalStorage(t) {
|
|
16075
16072
|
var d, A, u, h, m, g;
|
|
16076
|
-
const e =
|
|
16073
|
+
const e = B.getShadowGraphqlClient(), a = await e.query({
|
|
16077
16074
|
query: Qi,
|
|
16078
16075
|
errorPolicy: "all",
|
|
16079
16076
|
fetchPolicy: "no-cache",
|
|
@@ -16133,7 +16130,7 @@ class Ad {
|
|
|
16133
16130
|
e != null && e.has(t) && (e.delete(t), N.setMap("transactionCustomerIds", e));
|
|
16134
16131
|
}
|
|
16135
16132
|
async customerHasBundleTemplates(t) {
|
|
16136
|
-
const n = (await
|
|
16133
|
+
const n = (await B.getShadowGraphqlClient().query({
|
|
16137
16134
|
query: ue,
|
|
16138
16135
|
errorPolicy: "all",
|
|
16139
16136
|
fetchPolicy: "no-cache",
|
|
@@ -16157,7 +16154,7 @@ class Ad {
|
|
|
16157
16154
|
async getOrCreateCustomer(t) {
|
|
16158
16155
|
var s;
|
|
16159
16156
|
this.customer = void 0;
|
|
16160
|
-
const e =
|
|
16157
|
+
const e = B.getShadowGraphqlClient(), n = (await e.query({
|
|
16161
16158
|
query: ue,
|
|
16162
16159
|
errorPolicy: "all",
|
|
16163
16160
|
fetchPolicy: "no-cache",
|
|
@@ -16204,13 +16201,13 @@ class Ad {
|
|
|
16204
16201
|
return !1;
|
|
16205
16202
|
const n = JSON.parse(e), i = (/* @__PURE__ */ new Date()).getTime() / 1e3;
|
|
16206
16203
|
if (!n.ExpiresIn || n.ExpiresIn < i - parseInt(t)) {
|
|
16207
|
-
const l = await
|
|
16204
|
+
const l = await Ut.refreshTokens();
|
|
16208
16205
|
if (l != null && l.AuthenticationResult)
|
|
16209
16206
|
localStorage.setItem("last-refreshed-cognito-tokens", `${(/* @__PURE__ */ new Date()).getTime() / 1e3}`), n.AccessToken = l.AuthenticationResult.AccessToken, localStorage.setItem("cognito-tokens", JSON.stringify(n));
|
|
16210
16207
|
else
|
|
16211
16208
|
return this.logOut(), console.error("Failed to refresh tokens."), !1;
|
|
16212
16209
|
}
|
|
16213
|
-
const o = (await
|
|
16210
|
+
const o = (await B.getShadowGraphqlClient().query({
|
|
16214
16211
|
query: ue,
|
|
16215
16212
|
errorPolicy: "all",
|
|
16216
16213
|
fetchPolicy: "no-cache",
|
|
@@ -16224,22 +16221,22 @@ class Ad {
|
|
|
16224
16221
|
* Generate an email code to allow logging in as a Spiff user.
|
|
16225
16222
|
*/
|
|
16226
16223
|
async generateVerificationCode(t) {
|
|
16227
|
-
await
|
|
16224
|
+
await B.getShadowGraphqlClient().mutate({
|
|
16228
16225
|
mutation: Pl,
|
|
16229
16226
|
variables: {
|
|
16230
16227
|
emailAddress: t
|
|
16231
16228
|
}
|
|
16232
|
-
}), await
|
|
16229
|
+
}), await Ut.generateCode(t);
|
|
16233
16230
|
}
|
|
16234
16231
|
/**
|
|
16235
16232
|
* Verify an email code to log in as a Spiff user.
|
|
16236
16233
|
* Always returns true if it doesn't throw.
|
|
16237
16234
|
*/
|
|
16238
16235
|
async verifyCode(t, e) {
|
|
16239
|
-
const a = (await this.getIntegration()).partner.id || "", n = await
|
|
16236
|
+
const a = (await this.getIntegration()).partner.id || "", n = await Ut.verifyCode(t, e, a);
|
|
16240
16237
|
if (n != null && n.AuthenticationResult) {
|
|
16241
16238
|
localStorage.setItem("last-refreshed-cognito-tokens", `${(/* @__PURE__ */ new Date()).getTime() / 1e3}`), localStorage.setItem("cognito-tokens", JSON.stringify(n.AuthenticationResult)), localStorage.setItem("cognito-email", t);
|
|
16242
|
-
const s = (await
|
|
16239
|
+
const s = (await B.getShadowGraphqlClient().query({
|
|
16243
16240
|
query: ue,
|
|
16244
16241
|
errorPolicy: "all",
|
|
16245
16242
|
fetchPolicy: "no-cache",
|
|
@@ -16266,7 +16263,7 @@ class Ad {
|
|
|
16266
16263
|
throw new Error("No token data in storage.");
|
|
16267
16264
|
const a = JSON.parse(e), n = (/* @__PURE__ */ new Date()).getTime() / 1e3, i = !(a != null && a.AccessToken) || Wt(a.AccessToken);
|
|
16268
16265
|
if (!a.ExpiresIn || a.ExpiresIn < n - parseInt(t) || i) {
|
|
16269
|
-
const s = await
|
|
16266
|
+
const s = await Ut.refreshTokens();
|
|
16270
16267
|
if (s != null && s.AuthenticationResult)
|
|
16271
16268
|
localStorage.setItem("last-refreshed-cognito-tokens", `${(/* @__PURE__ */ new Date()).getTime() / 1e3}`), a.AccessToken = s.AuthenticationResult.AccessToken, localStorage.setItem("cognito-tokens", JSON.stringify(a));
|
|
16272
16269
|
else
|
|
@@ -16280,7 +16277,7 @@ class Ad {
|
|
|
16280
16277
|
var e;
|
|
16281
16278
|
if (!((e = this.customer) != null && e.id))
|
|
16282
16279
|
throw new Error("Customer must be logged in before calling this function.");
|
|
16283
|
-
return (await
|
|
16280
|
+
return (await B.getShadowGraphqlClient().query({
|
|
16284
16281
|
query: Dl,
|
|
16285
16282
|
variables: {
|
|
16286
16283
|
id: this.customer.id
|
|
@@ -16293,7 +16290,7 @@ class Ad {
|
|
|
16293
16290
|
*/
|
|
16294
16291
|
async getNewBundle(t, e, a) {
|
|
16295
16292
|
var c, d, A, u, h;
|
|
16296
|
-
const i = (A = (await
|
|
16293
|
+
const i = (A = (await B.getShadowGraphqlClient().mutate({
|
|
16297
16294
|
mutation: Ys(((d = (c = a == null ? void 0 : a.graphql) == null ? void 0 : c.productCollection) == null ? void 0 : d.eagerFetchProducts) || !1),
|
|
16298
16295
|
variables: {
|
|
16299
16296
|
collectionId: t,
|
|
@@ -16323,21 +16320,21 @@ class Ad {
|
|
|
16323
16320
|
* @returns A bundle to be used for grouping and operating on large amounts of workflow experiences.
|
|
16324
16321
|
*/
|
|
16325
16322
|
async getExistingBundle(t, e, a, n) {
|
|
16326
|
-
var h, m, g, p, f, C, w, S, y, E,
|
|
16323
|
+
var h, m, g, p, f, C, w, S, y, E, b;
|
|
16327
16324
|
const i = N.getMap("bundleOwnerIds"), s = i == null ? void 0 : i.get(t), o = {};
|
|
16328
16325
|
try {
|
|
16329
16326
|
const I = await this.loggedInBearerToken();
|
|
16330
16327
|
o.Authorization = `Bearer ${I}`;
|
|
16331
16328
|
} catch {
|
|
16332
|
-
const
|
|
16329
|
+
const x = ((h = Object.entries(localStorage).find(([T, nt]) => T.startsWith("CognitoIdentityServiceProvider") && T.endsWith("idToken"))) == null ? void 0 : h[0]) || "", k = localStorage.getItem(x);
|
|
16333
16330
|
k && !Wt(k) && (o.Authorization = `Bearer ${k}`);
|
|
16334
16331
|
}
|
|
16335
16332
|
const l = {
|
|
16336
16333
|
bundleOwnerId: s,
|
|
16337
16334
|
...o,
|
|
16338
16335
|
...(m = n == null ? void 0 : n.graphql) == null ? void 0 : m.additionalHeaders
|
|
16339
|
-
}, c = await
|
|
16340
|
-
query:
|
|
16336
|
+
}, c = await B.getShadowGraphqlClient().query({
|
|
16337
|
+
query: zs(((p = (g = n == null ? void 0 : n.graphql) == null ? void 0 : g.productCollection) == null ? void 0 : p.eagerFetchProducts) || !1),
|
|
16341
16338
|
variables: {
|
|
16342
16339
|
id: t
|
|
16343
16340
|
},
|
|
@@ -16352,7 +16349,7 @@ class Ad {
|
|
|
16352
16349
|
A.set(d.id, d.partner.id), N.setMap("bundlePartnerIds", A);
|
|
16353
16350
|
const u = new Je(this, d, e, a, s, {
|
|
16354
16351
|
additionalHeaders: (y = n == null ? void 0 : n.graphql) == null ? void 0 : y.additionalHeaders,
|
|
16355
|
-
eagerFetchProducts: (
|
|
16352
|
+
eagerFetchProducts: (b = (E = n == null ? void 0 : n.graphql) == null ? void 0 : E.productCollection) == null ? void 0 : b.eagerFetchProducts,
|
|
16356
16353
|
existingGlobalPropertyState: c.data.globalPropertyState,
|
|
16357
16354
|
readonly: n == null ? void 0 : n.readonly
|
|
16358
16355
|
});
|
|
@@ -16371,14 +16368,14 @@ class Ad {
|
|
|
16371
16368
|
const C = await this.loggedInBearerToken();
|
|
16372
16369
|
s.Authorization = `Bearer ${C}`;
|
|
16373
16370
|
} catch {
|
|
16374
|
-
const S = ((h = Object.entries(localStorage).find(([E,
|
|
16371
|
+
const S = ((h = Object.entries(localStorage).find(([E, b]) => E.startsWith("CognitoIdentityServiceProvider") && E.endsWith("idToken"))) == null ? void 0 : h[0]) || "", y = localStorage.getItem(S);
|
|
16375
16372
|
y && !Wt(y) && (s.Authorization = `Bearer ${y}`);
|
|
16376
16373
|
}
|
|
16377
16374
|
const o = {
|
|
16378
16375
|
bundleOwnerId: i,
|
|
16379
16376
|
...s,
|
|
16380
16377
|
...(m = n == null ? void 0 : n.graphql) == null ? void 0 : m.additionalHeaders
|
|
16381
|
-
}, c = (f = (await
|
|
16378
|
+
}, c = (f = (await B.getShadowGraphqlClient().mutate({
|
|
16382
16379
|
mutation: Js(((p = (g = n == null ? void 0 : n.graphql) == null ? void 0 : g.productCollection) == null ? void 0 : p.eagerFetchProducts) || !1),
|
|
16383
16380
|
variables: {
|
|
16384
16381
|
id: t,
|
|
@@ -16420,7 +16417,7 @@ class Ad {
|
|
|
16420
16417
|
if (!((i = this.customer) != null && i.id))
|
|
16421
16418
|
throw new Error("Customer not authenticated.");
|
|
16422
16419
|
const { includeMetadata: e, ...a } = t;
|
|
16423
|
-
return (await
|
|
16420
|
+
return (await B.getShadowGraphqlClient().query({
|
|
16424
16421
|
query: oo(e ?? !1),
|
|
16425
16422
|
variables: {
|
|
16426
16423
|
...a,
|
|
@@ -16437,7 +16434,7 @@ class Ad {
|
|
|
16437
16434
|
var i;
|
|
16438
16435
|
if (!this.customer)
|
|
16439
16436
|
throw new Error("Customer not authenticated.");
|
|
16440
|
-
const t = await
|
|
16437
|
+
const t = await B.getShadowGraphqlClient().query({
|
|
16441
16438
|
query: Ws,
|
|
16442
16439
|
variables: {
|
|
16443
16440
|
id: this.customer.id
|
|
@@ -16474,20 +16471,20 @@ class Ad {
|
|
|
16474
16471
|
async getWorkflowExperiences(t, e) {
|
|
16475
16472
|
if (t.length === 0)
|
|
16476
16473
|
throw new ut("No options provided!");
|
|
16477
|
-
const a =
|
|
16478
|
-
var D,
|
|
16474
|
+
const a = B.getShadowGraphqlClient(), n = async (y) => {
|
|
16475
|
+
var D, x, k;
|
|
16479
16476
|
if (y.length === 0)
|
|
16480
16477
|
return [];
|
|
16481
|
-
const E = y.map((T) => T.option.transactionId),
|
|
16478
|
+
const E = y.map((T) => T.option.transactionId), b = await a.query({
|
|
16482
16479
|
query: Si,
|
|
16483
16480
|
variables: {
|
|
16484
16481
|
ids: E
|
|
16485
16482
|
},
|
|
16486
16483
|
errorPolicy: "all",
|
|
16487
16484
|
fetchPolicy: "no-cache"
|
|
16488
|
-
}), I =
|
|
16485
|
+
}), I = b.data.transactions;
|
|
16489
16486
|
if (I.length !== y.length) {
|
|
16490
|
-
const T = ((
|
|
16487
|
+
const T = ((x = (D = b.errors) == null ? void 0 : D[0]) == null ? void 0 : x.message) || "Unknown error";
|
|
16491
16488
|
throw new ut(`Not all transactions were found: ${T}`);
|
|
16492
16489
|
}
|
|
16493
16490
|
return !this.activeIntegration && ((k = I[0].integrationProduct) != null && k.integration) && (this.activeIntegration = Promise.resolve(I[0].integrationProduct.integration)), I.map((T, nt) => {
|
|
@@ -16500,7 +16497,7 @@ class Ad {
|
|
|
16500
16497
|
};
|
|
16501
16498
|
});
|
|
16502
16499
|
}, i = async (y) => {
|
|
16503
|
-
var I, D,
|
|
16500
|
+
var I, D, x;
|
|
16504
16501
|
if (y.length === 0)
|
|
16505
16502
|
return [];
|
|
16506
16503
|
const E = await a.mutate({
|
|
@@ -16519,12 +16516,12 @@ class Ad {
|
|
|
16519
16516
|
},
|
|
16520
16517
|
errorPolicy: "all",
|
|
16521
16518
|
fetchPolicy: "no-cache"
|
|
16522
|
-
}),
|
|
16523
|
-
if (!
|
|
16524
|
-
const k = ((
|
|
16519
|
+
}), b = (I = E.data) == null ? void 0 : I.transactionCreateMany;
|
|
16520
|
+
if (!b || b.length === 0) {
|
|
16521
|
+
const k = ((x = (D = E.errors) == null ? void 0 : D[0]) == null ? void 0 : x.message) || "Unknown error";
|
|
16525
16522
|
throw new ut(`Failed to create transactions: ${k}`);
|
|
16526
16523
|
}
|
|
16527
|
-
return
|
|
16524
|
+
return b.map((k, T) => ({
|
|
16528
16525
|
transaction: k,
|
|
16529
16526
|
workflowId: k.workflowId,
|
|
16530
16527
|
readOnly: !1,
|
|
@@ -16532,14 +16529,14 @@ class Ad {
|
|
|
16532
16529
|
}));
|
|
16533
16530
|
}, s = t.map((y, E) => ({ option: y, index: E })), o = s.filter((y) => y.option.type === "transaction"), l = s.filter(
|
|
16534
16531
|
(y) => y.option.type === "integration" || y.option.type === "external"
|
|
16535
|
-
), c =
|
|
16532
|
+
), c = Fa(o, 10), d = Fa(l, 10), A = (await Promise.all([
|
|
16536
16533
|
...c.map(n),
|
|
16537
16534
|
...d.map(i)
|
|
16538
16535
|
])).flat(), u = [...new Set(A.map((y) => y.workflowId))], h = await nr(u, e), m = new Map(h.map((y) => [y.id, y])), g = N.getMap("transactionOwnerIds") || /* @__PURE__ */ new Map(), p = A.map(async (y) => {
|
|
16539
16536
|
var tt;
|
|
16540
|
-
const { transaction: E, workflowId:
|
|
16537
|
+
const { transaction: E, workflowId: b, readOnly: I, index: D } = y, x = m.get(b), k = t[D];
|
|
16541
16538
|
!g.get(E.id) && E.transactionOwnerId && g.set(E.id, E.transactionOwnerId);
|
|
16542
|
-
const T = g.get(E.id) || void 0, nt = new
|
|
16539
|
+
const T = g.get(E.id) || void 0, nt = new xl({
|
|
16543
16540
|
onMutate: () => ({ context: { transactionOwnerId: T, bundleOwnerId: e == null ? void 0 : e.bundleOwnerId } }),
|
|
16544
16541
|
onQuery: () => ({ context: { transactionOwnerId: T, bundleOwnerId: e == null ? void 0 : e.bundleOwnerId } })
|
|
16545
16542
|
}), R = {
|
|
@@ -16555,15 +16552,15 @@ class Ad {
|
|
|
16555
16552
|
}),
|
|
16556
16553
|
graphQlClient: () => nt,
|
|
16557
16554
|
readOnly: I,
|
|
16558
|
-
workflow:
|
|
16555
|
+
workflow: x,
|
|
16559
16556
|
isReloadedTransaction: k.type === "transaction"
|
|
16560
16557
|
};
|
|
16561
16558
|
if (k.type === "transaction" && E.workflowState) {
|
|
16562
16559
|
const q = JSON.parse(E.workflowState);
|
|
16563
|
-
R.layouts = Object.values(q.layouts || {}).map((ft) => ft.layout), await
|
|
16560
|
+
R.layouts = Object.values(q.layouts || {}).map((ft) => ft.layout), await za(q), R.reloadedState = q;
|
|
16564
16561
|
} else if (!I && k.workflowState) {
|
|
16565
16562
|
const q = JSON.parse(k.workflowState);
|
|
16566
|
-
R.layouts = Object.values(q.layouts || {}).map((ft) => ft.layout), await
|
|
16563
|
+
R.layouts = Object.values(q.layouts || {}).map((ft) => ft.layout), await za(q), R.reloadedState = q;
|
|
16567
16564
|
} else
|
|
16568
16565
|
R.layouts = Rl(
|
|
16569
16566
|
R.transaction,
|
|
@@ -16575,8 +16572,8 @@ class Ad {
|
|
|
16575
16572
|
}), f = await Promise.all(p);
|
|
16576
16573
|
N.setMap("transactionOwnerIds", g);
|
|
16577
16574
|
const w = f.sort((y, E) => y.index - E.index).map(async (y) => {
|
|
16578
|
-
const { experienceOptions: E, options:
|
|
16579
|
-
return await I.getWorkflowManager().getInitializationPromise(),
|
|
16575
|
+
const { experienceOptions: E, options: b } = y, I = new Vo(this, E);
|
|
16576
|
+
return await I.getWorkflowManager().getInitializationPromise(), b.type !== "transaction" && this.customer && await I.attachCustomerDetails({ email: this.customer.emailAddress }), I;
|
|
16580
16577
|
}), S = await Promise.all(w);
|
|
16581
16578
|
return S.forEach((y) => y.getWorkflowManager().setWorkflowStateSyncEnabled(!0)), S;
|
|
16582
16579
|
}
|
|
@@ -16586,7 +16583,7 @@ class Ad {
|
|
|
16586
16583
|
}
|
|
16587
16584
|
async getIntegrationProductById(t, e) {
|
|
16588
16585
|
var s, o;
|
|
16589
|
-
const i = (s = (await
|
|
16586
|
+
const i = (s = (await B.getShadowGraphqlClient().query({
|
|
16590
16587
|
query: Ii(e),
|
|
16591
16588
|
variables: {
|
|
16592
16589
|
ids: [t]
|
|
@@ -16600,7 +16597,7 @@ class Ad {
|
|
|
16600
16597
|
}
|
|
16601
16598
|
async getIntegrationProductFromExternalIds(t, e, a) {
|
|
16602
16599
|
var o;
|
|
16603
|
-
const s = (o = (await
|
|
16600
|
+
const s = (o = (await B.getShadowGraphqlClient().query({
|
|
16604
16601
|
query: Pi(a),
|
|
16605
16602
|
variables: {
|
|
16606
16603
|
externalProductId: e,
|
|
@@ -16617,8 +16614,8 @@ class Ad {
|
|
|
16617
16614
|
return t.type === "integration" ? this.getIntegrationProductById(t.integrationProductId) : this.getIntegrationProductFromExternalIds(t.externalIntegrationId, t.externalProductId);
|
|
16618
16615
|
}
|
|
16619
16616
|
async getShareActionsForTransaction(t) {
|
|
16620
|
-
const a = (N.getMap("transactionOwnerIds") || /* @__PURE__ */ new Map()).get(t) || void 0, n = await
|
|
16621
|
-
query:
|
|
16617
|
+
const a = (N.getMap("transactionOwnerIds") || /* @__PURE__ */ new Map()).get(t) || void 0, n = await B.getShadowGraphqlClient().query({
|
|
16618
|
+
query: Bi,
|
|
16622
16619
|
errorPolicy: "all",
|
|
16623
16620
|
fetchPolicy: "no-cache",
|
|
16624
16621
|
variables: {
|
|
@@ -16633,7 +16630,7 @@ class Ad {
|
|
|
16633
16630
|
return n.data.transactions[0].transactionShareActions;
|
|
16634
16631
|
}
|
|
16635
16632
|
async placeOrder(t) {
|
|
16636
|
-
const e = await
|
|
16633
|
+
const e = await B.getShadowGraphqlClient().mutate({
|
|
16637
16634
|
mutation: Vi,
|
|
16638
16635
|
variables: {
|
|
16639
16636
|
orderItems: t
|
|
@@ -16649,7 +16646,7 @@ class Ad {
|
|
|
16649
16646
|
};
|
|
16650
16647
|
}
|
|
16651
16648
|
}
|
|
16652
|
-
const Ol = async (r, t) => (await
|
|
16649
|
+
const Ol = async (r, t) => (await B.getShadowGraphqlClient().query({
|
|
16653
16650
|
query: $i,
|
|
16654
16651
|
errorPolicy: "all",
|
|
16655
16652
|
fetchPolicy: "no-cache",
|
|
@@ -16662,8 +16659,8 @@ const Ol = async (r, t) => (await b.getShadowGraphqlClient().query({
|
|
|
16662
16659
|
themeConfigurationId: t
|
|
16663
16660
|
}
|
|
16664
16661
|
})).data.currentIntegration, ud = async (r) => {
|
|
16665
|
-
const e = await
|
|
16666
|
-
query:
|
|
16662
|
+
const e = await B.getShadowGraphqlClient().query({
|
|
16663
|
+
query: bi,
|
|
16667
16664
|
errorPolicy: "all",
|
|
16668
16665
|
fetchPolicy: "network-only",
|
|
16669
16666
|
variables: {
|
|
@@ -16674,7 +16671,7 @@ const Ol = async (r, t) => (await b.getShadowGraphqlClient().query({
|
|
|
16674
16671
|
return e.data.transactions[0];
|
|
16675
16672
|
}, hd = async (r, t) => {
|
|
16676
16673
|
var a;
|
|
16677
|
-
return (a = (await
|
|
16674
|
+
return (a = (await B.getShadowGraphqlClient().query({
|
|
16678
16675
|
query: Oi,
|
|
16679
16676
|
errorPolicy: "all",
|
|
16680
16677
|
variables: {
|
|
@@ -16684,8 +16681,8 @@ const Ol = async (r, t) => (await b.getShadowGraphqlClient().query({
|
|
|
16684
16681
|
})).data) == null ? void 0 : a.marketplaceThemeInstallConfiguration;
|
|
16685
16682
|
}, md = async (r) => {
|
|
16686
16683
|
var e, a, n;
|
|
16687
|
-
return (n = (a = (e = (await
|
|
16688
|
-
query:
|
|
16684
|
+
return (n = (a = (e = (await B.getShadowGraphqlClient().query({
|
|
16685
|
+
query: Ui,
|
|
16689
16686
|
errorPolicy: "all",
|
|
16690
16687
|
variables: {
|
|
16691
16688
|
id: r
|
|
@@ -16693,8 +16690,8 @@ const Ol = async (r, t) => (await b.getShadowGraphqlClient().query({
|
|
|
16693
16690
|
})).data) == null ? void 0 : e.bundles) == null ? void 0 : a[0]) == null ? void 0 : n.marketplaceThemeInstallConfiguration;
|
|
16694
16691
|
}, gd = async (r) => {
|
|
16695
16692
|
var e, a, n;
|
|
16696
|
-
return (n = (a = (e = (await
|
|
16697
|
-
query:
|
|
16693
|
+
return (n = (a = (e = (await B.getShadowGraphqlClient().query({
|
|
16694
|
+
query: Li,
|
|
16698
16695
|
errorPolicy: "all",
|
|
16699
16696
|
variables: {
|
|
16700
16697
|
id: r
|
|
@@ -16715,7 +16712,7 @@ function $l(r, t, e, a) {
|
|
|
16715
16712
|
function he(r, t, e) {
|
|
16716
16713
|
return Math.min(Math.max(r, t), e);
|
|
16717
16714
|
}
|
|
16718
|
-
class
|
|
16715
|
+
class Ll {
|
|
16719
16716
|
constructor(t, e) {
|
|
16720
16717
|
this.minZoomScale = [0.03], this.maxZoomScale = [20], this._debouncedUpdateFrameOffsets = dn(this.updateFrameOffsets, 200), this.targetElements = [], this.onFrameDataChangeListeners = [], this.onZoomChangeListeners = [], this.forceImageCover = t, this.initialZoom = e, this.thresholdSettings = {
|
|
16721
16718
|
useThreshold: !1,
|
|
@@ -17099,12 +17096,12 @@ class pd {
|
|
|
17099
17096
|
return [];
|
|
17100
17097
|
}
|
|
17101
17098
|
}
|
|
17102
|
-
var
|
|
17099
|
+
var Ul = /* @__PURE__ */ ((r) => (r.SelectFrame = "SelectFrame", r.SelectImage = "SelectImage", r.Position = "Position", r))(Ul || {});
|
|
17103
17100
|
class Vl extends it {
|
|
17104
17101
|
constructor(t, e, a) {
|
|
17105
17102
|
super(t, e, a);
|
|
17106
17103
|
const n = e.data;
|
|
17107
|
-
this.frameService = new
|
|
17104
|
+
this.frameService = new Ll(n.forceImageCover, n.initialZoomLevel), this.frameService.connectWorkflowManager(t, e.stepName);
|
|
17108
17105
|
}
|
|
17109
17106
|
selectVariant(t) {
|
|
17110
17107
|
const e = this.manager.getRegionElements(this.step.stepName);
|
|
@@ -17168,7 +17165,7 @@ class Vl extends it {
|
|
|
17168
17165
|
const e = await this.getOriginalImageSelection();
|
|
17169
17166
|
if (!e)
|
|
17170
17167
|
throw new Error("You must supply an image selection before attempting to remove the background.");
|
|
17171
|
-
const a = await
|
|
17168
|
+
const a = await L.removeBackgroundFromAsset(e);
|
|
17172
17169
|
t && await wt.selectImage(this.step, a, this.manager, !1);
|
|
17173
17170
|
const n = ((i = this.manager.getStepStorage(this.step.stepName)) == null ? void 0 : i.framePatternData) || {};
|
|
17174
17171
|
return this.manager.updateStorage(this.step.stepName, {
|
|
@@ -17227,13 +17224,13 @@ class Vl extends it {
|
|
|
17227
17224
|
var e, a;
|
|
17228
17225
|
const t = (a = (e = this.manager.getStepStorage(this.step.stepName)) == null ? void 0 : e.framePatternData) == null ? void 0 : a.originalAssetKey;
|
|
17229
17226
|
if (t)
|
|
17230
|
-
return
|
|
17227
|
+
return L.getLocalOrFromServer(t);
|
|
17231
17228
|
}
|
|
17232
17229
|
async getBackgroundRemovedImageSelection() {
|
|
17233
17230
|
var e, a;
|
|
17234
17231
|
const t = (a = (e = this.manager.getStepStorage(this.step.stepName)) == null ? void 0 : e.framePatternData) == null ? void 0 : a.backgroundRemovedAssetKey;
|
|
17235
17232
|
if (t)
|
|
17236
|
-
return
|
|
17233
|
+
return L.getLocalOrFromServer(t);
|
|
17237
17234
|
}
|
|
17238
17235
|
hasOriginalImageSelection() {
|
|
17239
17236
|
var t, e;
|
|
@@ -17273,7 +17270,7 @@ class Vl extends it {
|
|
|
17273
17270
|
return this.manager.getStepStorage(this.step.stepName);
|
|
17274
17271
|
}
|
|
17275
17272
|
}
|
|
17276
|
-
const
|
|
17273
|
+
const Gl = v`
|
|
17277
17274
|
query GetLoggedInCustomer($email: String!) {
|
|
17278
17275
|
customer(emailAddress: $email) {
|
|
17279
17276
|
id
|
|
@@ -17316,7 +17313,7 @@ const zl = v`
|
|
|
17316
17313
|
total
|
|
17317
17314
|
}
|
|
17318
17315
|
}
|
|
17319
|
-
`,
|
|
17316
|
+
`, zl = v`
|
|
17320
17317
|
mutation SetTransactionDesignName($id: String!, $name: String!) {
|
|
17321
17318
|
transactionUpdate(id: $id, designName: $name) {
|
|
17322
17319
|
id
|
|
@@ -17393,7 +17390,7 @@ const zl = v`
|
|
|
17393
17390
|
total
|
|
17394
17391
|
}
|
|
17395
17392
|
}
|
|
17396
|
-
`, fd = async (r, t, e) => await
|
|
17393
|
+
`, fd = async (r, t, e) => await B.getShadowGraphqlClient().mutate({
|
|
17397
17394
|
mutation: Hl,
|
|
17398
17395
|
errorPolicy: "all",
|
|
17399
17396
|
variables: {
|
|
@@ -17401,34 +17398,34 @@ const zl = v`
|
|
|
17401
17398
|
name: t
|
|
17402
17399
|
},
|
|
17403
17400
|
context: e
|
|
17404
|
-
}), Cd = async (r, t) => await
|
|
17405
|
-
mutation:
|
|
17401
|
+
}), Cd = async (r, t) => await B.getShadowGraphqlClient().mutate({
|
|
17402
|
+
mutation: zl,
|
|
17406
17403
|
errorPolicy: "all",
|
|
17407
17404
|
variables: {
|
|
17408
17405
|
id: r,
|
|
17409
17406
|
name: t
|
|
17410
17407
|
}
|
|
17411
|
-
}), wd = async (r, t) => await
|
|
17408
|
+
}), wd = async (r, t) => await B.getShadowGraphqlClient().mutate({
|
|
17412
17409
|
mutation: Yl,
|
|
17413
17410
|
errorPolicy: "all",
|
|
17414
17411
|
variables: {
|
|
17415
17412
|
id: r,
|
|
17416
17413
|
template: t
|
|
17417
17414
|
}
|
|
17418
|
-
}), yd = async (r, t) => await
|
|
17415
|
+
}), yd = async (r, t) => await B.getShadowGraphqlClient().mutate({
|
|
17419
17416
|
mutation: Wl,
|
|
17420
17417
|
errorPolicy: "all",
|
|
17421
17418
|
variables: {
|
|
17422
17419
|
id: r,
|
|
17423
17420
|
template: t
|
|
17424
17421
|
}
|
|
17425
|
-
}), Sd = async (r) => (await
|
|
17426
|
-
query:
|
|
17422
|
+
}), Sd = async (r) => (await B.getShadowGraphqlClient().query({
|
|
17423
|
+
query: Gl,
|
|
17427
17424
|
errorPolicy: "all",
|
|
17428
17425
|
variables: {
|
|
17429
17426
|
email: r
|
|
17430
17427
|
}
|
|
17431
|
-
})).data.customer, vd = async (r, t, e) => await
|
|
17428
|
+
})).data.customer, vd = async (r, t, e) => await B.getShadowGraphqlClient().query({
|
|
17432
17429
|
query: jl,
|
|
17433
17430
|
errorPolicy: "all",
|
|
17434
17431
|
fetchPolicy: "no-cache",
|
|
@@ -17437,7 +17434,7 @@ const zl = v`
|
|
|
17437
17434
|
offset: e,
|
|
17438
17435
|
limit: t
|
|
17439
17436
|
}
|
|
17440
|
-
}), Ed = async (r, t) => await
|
|
17437
|
+
}), Ed = async (r, t) => await B.getShadowGraphqlClient().query({
|
|
17441
17438
|
query: ql,
|
|
17442
17439
|
errorPolicy: "all",
|
|
17443
17440
|
fetchPolicy: "no-cache",
|
|
@@ -17445,9 +17442,9 @@ const zl = v`
|
|
|
17445
17442
|
id: r
|
|
17446
17443
|
},
|
|
17447
17444
|
context: t
|
|
17448
|
-
}),
|
|
17445
|
+
}), bd = async (r, t, e) => {
|
|
17449
17446
|
var n;
|
|
17450
|
-
const a = await
|
|
17447
|
+
const a = await B.getShadowGraphqlClient().query({
|
|
17451
17448
|
query: Da,
|
|
17452
17449
|
errorPolicy: "all",
|
|
17453
17450
|
fetchPolicy: "no-cache",
|
|
@@ -17469,9 +17466,9 @@ const zl = v`
|
|
|
17469
17466
|
}
|
|
17470
17467
|
});
|
|
17471
17468
|
return ((n = a == null ? void 0 : a.data.customerTransactionsFeed) == null ? void 0 : n.items) || [];
|
|
17472
|
-
},
|
|
17469
|
+
}, Bd = async (r, t, e) => {
|
|
17473
17470
|
var n;
|
|
17474
|
-
const a = await
|
|
17471
|
+
const a = await B.getShadowGraphqlClient().query({
|
|
17475
17472
|
query: Da,
|
|
17476
17473
|
errorPolicy: "all",
|
|
17477
17474
|
fetchPolicy: "no-cache",
|
|
@@ -17495,7 +17492,7 @@ const zl = v`
|
|
|
17495
17492
|
return ((n = a == null ? void 0 : a.data.customerTransactionsFeed) == null ? void 0 : n.items) || [];
|
|
17496
17493
|
}, Id = async (r, t, e) => {
|
|
17497
17494
|
var n;
|
|
17498
|
-
const a = await
|
|
17495
|
+
const a = await B.getShadowGraphqlClient().query({
|
|
17499
17496
|
query: Da,
|
|
17500
17497
|
errorPolicy: "all",
|
|
17501
17498
|
fetchPolicy: "no-cache",
|
|
@@ -17515,7 +17512,7 @@ const zl = v`
|
|
|
17515
17512
|
return ((n = a == null ? void 0 : a.data.customerTransactionsFeed) == null ? void 0 : n.items) || [];
|
|
17516
17513
|
}, Pd = async (r, t, e) => {
|
|
17517
17514
|
var n;
|
|
17518
|
-
const a = await
|
|
17515
|
+
const a = await B.getShadowGraphqlClient().query({
|
|
17519
17516
|
query: Jl,
|
|
17520
17517
|
errorPolicy: "all",
|
|
17521
17518
|
fetchPolicy: "no-cache",
|
|
@@ -17633,7 +17630,7 @@ const ir = v`
|
|
|
17633
17630
|
}
|
|
17634
17631
|
missingComponentTypes
|
|
17635
17632
|
}
|
|
17636
|
-
`,
|
|
17633
|
+
`, xa = v`
|
|
17637
17634
|
${ir}
|
|
17638
17635
|
fragment AddressValidationJobFields on AddressValidationJob {
|
|
17639
17636
|
id
|
|
@@ -17646,14 +17643,14 @@ const ir = v`
|
|
|
17646
17643
|
}
|
|
17647
17644
|
}
|
|
17648
17645
|
`, tc = v`
|
|
17649
|
-
${
|
|
17646
|
+
${xa}
|
|
17650
17647
|
query GetAddressValidationJobs($ids: [String!]!) {
|
|
17651
17648
|
addressValidationJobs(ids: $ids) {
|
|
17652
17649
|
...AddressValidationJobFields
|
|
17653
17650
|
}
|
|
17654
17651
|
}
|
|
17655
17652
|
`, ec = v`
|
|
17656
|
-
${
|
|
17653
|
+
${xa}
|
|
17657
17654
|
query GetRecipientsWithAddressValidationJobs($ids: [String!]!) {
|
|
17658
17655
|
recipients(ids: $ids) {
|
|
17659
17656
|
id
|
|
@@ -17670,7 +17667,7 @@ const ir = v`
|
|
|
17670
17667
|
}
|
|
17671
17668
|
}
|
|
17672
17669
|
`, nc = v`
|
|
17673
|
-
${
|
|
17670
|
+
${xa}
|
|
17674
17671
|
mutation BatchValidateRecipientAddress($ids: [String!]!) {
|
|
17675
17672
|
recipientValidateBatch(ids: $ids) {
|
|
17676
17673
|
...AddressValidationJobFields
|
|
@@ -17682,7 +17679,7 @@ const Dd = async (r) => {
|
|
|
17682
17679
|
const t = r.map((a) => {
|
|
17683
17680
|
var n;
|
|
17684
17681
|
return (n = a.getWorkflowManager().getTransaction().recipient) == null ? void 0 : n.id;
|
|
17685
|
-
}).filter((a) => !!a), e = await
|
|
17682
|
+
}).filter((a) => !!a), e = await B.getShadowGraphqlClient().query({
|
|
17686
17683
|
query: ec,
|
|
17687
17684
|
errorPolicy: "all",
|
|
17688
17685
|
fetchPolicy: "network-only",
|
|
@@ -17696,9 +17693,9 @@ const Dd = async (r) => {
|
|
|
17696
17693
|
if (n)
|
|
17697
17694
|
return (l = (o = (s = e.data) == null ? void 0 : s.recipients) == null ? void 0 : o.find((c) => c.id === n)) == null ? void 0 : l.addressValidationJob;
|
|
17698
17695
|
});
|
|
17699
|
-
},
|
|
17696
|
+
}, xd = async (r) => {
|
|
17700
17697
|
var e;
|
|
17701
|
-
return (e = (await
|
|
17698
|
+
return (e = (await B.getShadowGraphqlClient().query({
|
|
17702
17699
|
query: tc,
|
|
17703
17700
|
errorPolicy: "all",
|
|
17704
17701
|
fetchPolicy: "network-only",
|
|
@@ -17706,9 +17703,9 @@ const Dd = async (r) => {
|
|
|
17706
17703
|
ids: r
|
|
17707
17704
|
}
|
|
17708
17705
|
})).data) == null ? void 0 : e.addressValidationJobs;
|
|
17709
|
-
},
|
|
17706
|
+
}, Fd = async (r) => {
|
|
17710
17707
|
var e, a;
|
|
17711
|
-
return (e = r.getWorkflowManager().getTransaction().recipient) != null && e.id ? (a = (await
|
|
17708
|
+
return (e = r.getWorkflowManager().getTransaction().recipient) != null && e.id ? (a = (await B.getShadowGraphqlClient().mutate({
|
|
17712
17709
|
mutation: ac,
|
|
17713
17710
|
errorPolicy: "all",
|
|
17714
17711
|
fetchPolicy: "network-only",
|
|
@@ -17720,7 +17717,7 @@ const Dd = async (r) => {
|
|
|
17720
17717
|
const t = r.map((a) => {
|
|
17721
17718
|
var n;
|
|
17722
17719
|
return (n = a.getWorkflowManager().getTransaction().recipient) == null ? void 0 : n.id;
|
|
17723
|
-
}).filter((a) => !!a), e = await
|
|
17720
|
+
}).filter((a) => !!a), e = await B.getShadowGraphqlClient().mutate({
|
|
17724
17721
|
mutation: nc,
|
|
17725
17722
|
errorPolicy: "all",
|
|
17726
17723
|
fetchPolicy: "network-only",
|
|
@@ -17740,7 +17737,7 @@ export {
|
|
|
17740
17737
|
ic as AddressValidationJobStatus,
|
|
17741
17738
|
rc as AddressValidationResultConfirmationLevel,
|
|
17742
17739
|
cd as ArrayInput,
|
|
17743
|
-
|
|
17740
|
+
j as AspectType,
|
|
17744
17741
|
vt as AssetNotFoundError,
|
|
17745
17742
|
Ce as AssetType,
|
|
17746
17743
|
ad as BringForwardCommand,
|
|
@@ -17753,22 +17750,22 @@ export {
|
|
|
17753
17750
|
ls as CommandContext,
|
|
17754
17751
|
_l as ConversionDataType,
|
|
17755
17752
|
Kl as ConversionLocation,
|
|
17756
|
-
|
|
17753
|
+
z as CreateElementCommand,
|
|
17757
17754
|
Vn as CreateLayoutCommand,
|
|
17758
17755
|
Ml as CurrencyContext,
|
|
17759
17756
|
kl as CurrencyService,
|
|
17760
|
-
|
|
17757
|
+
bt as DeleteElementCommand,
|
|
17761
17758
|
Po as DigitalContentStepHandle,
|
|
17762
17759
|
il as FileUploadGlobalPropertyHandle,
|
|
17763
17760
|
Ae as FlowExecutionNodeResult,
|
|
17764
|
-
|
|
17761
|
+
bl as FlowExecutionResult,
|
|
17765
17762
|
El as FlowService,
|
|
17766
17763
|
us as FontAlignmentCommand,
|
|
17767
17764
|
ds as FontColorCommand,
|
|
17768
17765
|
As as FontSizeCommand,
|
|
17769
17766
|
ja as FontSourceCommand,
|
|
17770
|
-
|
|
17771
|
-
|
|
17767
|
+
Ll as FrameService,
|
|
17768
|
+
Ul as FrameStep,
|
|
17772
17769
|
Vl as FrameStepHandle,
|
|
17773
17770
|
Ia as GlobalPropertyHandle,
|
|
17774
17771
|
$ as GroupCommand,
|
|
@@ -17776,7 +17773,7 @@ export {
|
|
|
17776
17773
|
Re as InformationMessageType,
|
|
17777
17774
|
Io as InformationStepHandle,
|
|
17778
17775
|
_a as IntegrationProduct,
|
|
17779
|
-
|
|
17776
|
+
Br as IntegrationType,
|
|
17780
17777
|
Jc as LayoutElementFactory,
|
|
17781
17778
|
M as LayoutElementType,
|
|
17782
17779
|
J as LayoutNotFoundError,
|
|
@@ -17788,10 +17785,10 @@ export {
|
|
|
17788
17785
|
Do as ModuleStepHandle,
|
|
17789
17786
|
Kc as MoveCommand,
|
|
17790
17787
|
ar as ObjectInput,
|
|
17791
|
-
|
|
17788
|
+
Bl as ObjectInputType,
|
|
17792
17789
|
tr as OptionGlobalPropertyHandle,
|
|
17793
17790
|
ye as OptionNotFoundError,
|
|
17794
|
-
|
|
17791
|
+
xt as ParseError,
|
|
17795
17792
|
vo as PictureStepHandle,
|
|
17796
17793
|
Ir as ProductCameraRig,
|
|
17797
17794
|
er as ProductCollection,
|
|
@@ -17800,14 +17797,14 @@ export {
|
|
|
17800
17797
|
Jt as PromiseCache,
|
|
17801
17798
|
kn as PromiseQueue,
|
|
17802
17799
|
Eo as QuestionStepHandle,
|
|
17803
|
-
|
|
17800
|
+
Fn as QueueablePromise,
|
|
17804
17801
|
Xc as ResizeCommand,
|
|
17805
17802
|
Ht as ResourceNotFoundError,
|
|
17806
17803
|
_c as RotateCommand,
|
|
17807
17804
|
H as ScaleAxis,
|
|
17808
17805
|
nd as SendBackwardsCommand,
|
|
17809
|
-
|
|
17810
|
-
|
|
17806
|
+
bo as ShapeStepHandle,
|
|
17807
|
+
br as ShareActionType,
|
|
17811
17808
|
Ad as SpiffCommerceClient,
|
|
17812
17809
|
we as StakeholderType,
|
|
17813
17810
|
vr as StepAspectType,
|
|
@@ -17817,16 +17814,16 @@ export {
|
|
|
17817
17814
|
gs as TextChangeCommand,
|
|
17818
17815
|
sl as TextGlobalPropertyHandle,
|
|
17819
17816
|
ld as TextInput,
|
|
17820
|
-
|
|
17817
|
+
Bo as TextStepHandle,
|
|
17821
17818
|
pl as Transform,
|
|
17822
17819
|
gl as TransformCollection,
|
|
17823
17820
|
G as UnhandledBehaviorError,
|
|
17824
17821
|
Pr as UnitOfMeasurement,
|
|
17825
17822
|
Zc as UpdateImageSourceCommand,
|
|
17826
17823
|
st as Variant,
|
|
17827
|
-
|
|
17824
|
+
Uo as WorkflowExperienceEventType,
|
|
17828
17825
|
Vo as WorkflowExperienceImpl,
|
|
17829
|
-
|
|
17826
|
+
L as assetService,
|
|
17830
17827
|
Zr as browserColorToHex,
|
|
17831
17828
|
Hc as cmPerPixel,
|
|
17832
17829
|
No as createDesign,
|
|
@@ -17834,13 +17831,13 @@ export {
|
|
|
17834
17831
|
Mc as dataUrlFromExternalUrl,
|
|
17835
17832
|
Ye as designService,
|
|
17836
17833
|
pe as determineCorrectFontSizeAndLines,
|
|
17837
|
-
|
|
17834
|
+
zn as digitalContentStepService,
|
|
17838
17835
|
dt as domParser,
|
|
17839
17836
|
wd as duplicateBundle,
|
|
17840
17837
|
yd as duplicateTransaction,
|
|
17841
17838
|
at as fetchAsString,
|
|
17842
17839
|
Oc as findAngle,
|
|
17843
|
-
|
|
17840
|
+
U as findElement,
|
|
17844
17841
|
Qc as findPmsColors,
|
|
17845
17842
|
Vt as frameDataCache,
|
|
17846
17843
|
wt as frameStepService,
|
|
@@ -17848,7 +17845,7 @@ export {
|
|
|
17848
17845
|
Xo as generateCommands,
|
|
17849
17846
|
lt as generateSVGWithUnknownColors,
|
|
17850
17847
|
sd as generateStateFromDesignInputSteps,
|
|
17851
|
-
|
|
17848
|
+
xd as getAddressValidationJobs,
|
|
17852
17849
|
Me as getAttributesFromArrayBuffer,
|
|
17853
17850
|
Rc as getAxisAlignedBoundingBox,
|
|
17854
17851
|
$l as getBoundedOffsets,
|
|
@@ -17859,25 +17856,25 @@ export {
|
|
|
17859
17856
|
Qe as getFrameData,
|
|
17860
17857
|
rd as getGlobalPropertyStateForBundle,
|
|
17861
17858
|
Ol as getIntegration,
|
|
17862
|
-
|
|
17859
|
+
Gc as getNEPoint,
|
|
17863
17860
|
Vc as getNWPoint,
|
|
17864
|
-
|
|
17861
|
+
Bd as getOrderedTransactions,
|
|
17865
17862
|
hd as getOverrideThemeConfiguration,
|
|
17866
|
-
|
|
17863
|
+
Uc as getPointOfRotation,
|
|
17867
17864
|
od as getProductCollections,
|
|
17868
|
-
|
|
17865
|
+
zc as getSEPoint,
|
|
17869
17866
|
Sa as getSvgElement,
|
|
17870
17867
|
Pd as getTemplateBundles,
|
|
17871
17868
|
Id as getTemplateTransactions,
|
|
17872
17869
|
ud as getTransaction,
|
|
17873
17870
|
gd as getTransactionThemeConfiguration,
|
|
17874
17871
|
Ed as getTransactionsForBundle,
|
|
17875
|
-
|
|
17876
|
-
|
|
17872
|
+
Lc as getTrueCoordinates,
|
|
17873
|
+
bd as getUnorderedTransactions,
|
|
17877
17874
|
Dd as getValidationJobsForWorkflowExperiences,
|
|
17878
17875
|
dd as getWorkflow,
|
|
17879
17876
|
nr as getWorkflows,
|
|
17880
|
-
|
|
17877
|
+
B as graphQlManager,
|
|
17881
17878
|
ge as illustrationStepService,
|
|
17882
17879
|
$c as isCloseToValue,
|
|
17883
17880
|
Nt as loadFont,
|
|
@@ -17898,24 +17895,24 @@ export {
|
|
|
17898
17895
|
Tc as pmsToRgb,
|
|
17899
17896
|
Yn as questionStepService,
|
|
17900
17897
|
kc as registerFetchImplementation,
|
|
17901
|
-
|
|
17902
|
-
|
|
17898
|
+
Fc as registerWindowImplementation,
|
|
17899
|
+
za as rehydrateSerializedLayout,
|
|
17903
17900
|
Kr as rgbToPms,
|
|
17904
17901
|
le as rotateAroundPoint,
|
|
17905
17902
|
pa as sanitizeSvgTree,
|
|
17906
17903
|
Vr as setBearerAuthenticationToken,
|
|
17907
17904
|
fn as setCanvasModule,
|
|
17908
|
-
|
|
17905
|
+
Gt as shapeStepService,
|
|
17909
17906
|
fs as shortenUrl,
|
|
17910
17907
|
mt as spiffCoreConfiguration,
|
|
17911
17908
|
id as stepAspectValuesToDesignInputSteps,
|
|
17912
17909
|
$a as svgColorValueToDefinition,
|
|
17913
|
-
|
|
17910
|
+
Ln as svgStringDimensions,
|
|
17914
17911
|
ha as svgToDataUrl,
|
|
17915
|
-
|
|
17912
|
+
W as textStepService,
|
|
17916
17913
|
Ps as toast,
|
|
17917
|
-
|
|
17914
|
+
Fd as validateWorkflowExperienceRecipient,
|
|
17918
17915
|
kd as validateWorkflowExperienceRecipients,
|
|
17919
|
-
|
|
17916
|
+
Bt as xmlSerializer
|
|
17920
17917
|
};
|
|
17921
17918
|
//# sourceMappingURL=index.mjs.map
|