@spiffcommerce/core 26.37.0-beta.3291c9ea-5d65-502b-bbaa-23048d45de85 → 26.37.0
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/CHANGELOG.md +2 -8
- package/dist/index.d.ts +0 -5
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +255 -262
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -19,7 +19,7 @@ import { split as Ke } from "unicode-default-word-boundary";
|
|
|
19
19
|
import on from "lodash.debounce";
|
|
20
20
|
import "fs";
|
|
21
21
|
import "path";
|
|
22
|
-
var ge = /* @__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))(ge || {}), et = /* @__PURE__ */ ((r) => (r.FileUpload = "FileUpload", r.Option = "Option", r.ColorOption = "ColorOption", r.Text = "Text", r))(et || {}), D = /* @__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))(D || {}),
|
|
22
|
+
var ge = /* @__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))(ge || {}), et = /* @__PURE__ */ ((r) => (r.FileUpload = "FileUpload", r.Option = "Option", r.ColorOption = "ColorOption", r.Text = "Text", r))(et || {}), D = /* @__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))(D || {}), fr = /* @__PURE__ */ ((r) => (r.Color = "Color", r.Colors = "Colors", r.Selection = "Selection", r.Selections = "Selections", r.Text = "Text", r.Upload = "Upload", r))(fr || {}), Wt = /* @__PURE__ */ ((r) => (r.ThreeD = "ThreeD", r.FreeDesign = "FreeDesign", r.Print = "Print", r))(Wt || {}), T = /* @__PURE__ */ ((r) => (r.Frame = "frame", r.Group = "group", r.Image = "image", r.Pattern = "pattern", r.Illustration = "illustration", r.Textbox = "textbox", r))(T || {}), pr = /* @__PURE__ */ ((r) => (r.Default = "Default", r.FirstTransaction = "FirstTransaction", r.OneToOne = "OneToOne", r))(pr || {}), Cr = /* @__PURE__ */ ((r) => (r.Hyperlink = "Hyperlink", r.Edit = "Edit", r.Approve = "Approve", r))(Cr || {}), wr = /* @__PURE__ */ ((r) => (r.Hub = "Hub", r.Shopify = "Shopify", r))(wr || {}), da = /* @__PURE__ */ ((r) => (r.BackgroundRemover = "BackgroundRemover", r.ConversionAccelerator = "Conversion Accelerator", r.ProcessBuilder = "ProcessBuilder", r))(da || {}), yr = /* @__PURE__ */ ((r) => (r[r.Orbit = 0] = "Orbit", r[r.Pan = 1] = "Pan", r))(yr || {}), fe = /* @__PURE__ */ ((r) => (r.Owner = "Owner", r.Approver = "Approver", r.Editor = "Editor", r.Viewer = "Viewer", r))(fe || {}), Mt = /* @__PURE__ */ ((r) => (r.Autosize = "Autosize", r.Traditional = "Traditional", r))(Mt || {}), j = /* @__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))(j || {}), Sr = /* @__PURE__ */ ((r) => (r.Pixel = "px", r.Millimeter = "mm", r.Centimeter = "cm", r))(Sr || {});
|
|
23
23
|
class ln extends Error {
|
|
24
24
|
constructor(t) {
|
|
25
25
|
super(t), this.name = this.constructor.name;
|
|
@@ -30,7 +30,7 @@ class Jt extends ln {
|
|
|
30
30
|
super(`ConfigurationError - ${t}`);
|
|
31
31
|
}
|
|
32
32
|
}
|
|
33
|
-
class
|
|
33
|
+
class pe extends Jt {
|
|
34
34
|
constructor(t) {
|
|
35
35
|
super(`Option not Configured: ${t.stepTitle}`), this.optionId = (t == null ? void 0 : t.optionId) || "N/A";
|
|
36
36
|
}
|
|
@@ -158,7 +158,7 @@ class Br {
|
|
|
158
158
|
}
|
|
159
159
|
const mt = new Br();
|
|
160
160
|
let _e, Xe;
|
|
161
|
-
function
|
|
161
|
+
function pc(r) {
|
|
162
162
|
_e = r;
|
|
163
163
|
}
|
|
164
164
|
function Cc(r) {
|
|
@@ -330,12 +330,12 @@ class $r {
|
|
|
330
330
|
uri: `${mt.getServerUrl()}/graphql`,
|
|
331
331
|
fetch: Or
|
|
332
332
|
}), e = lr(async (i, s) => {
|
|
333
|
-
const { headers: o } = s, l = o || {}, c = await Rr(), d = s.bearer ?? c.bearer, A = s.partnerId ?? c.partnerId, u = s.activeIntegration ?? c.activeIntegration, h = s.transactionOwnerId, m = s.customerToken ?? c.customerToken, g = s.applicationKey ?? c.applicationKey,
|
|
333
|
+
const { headers: o } = s, l = o || {}, c = await Rr(), d = s.bearer ?? c.bearer, A = s.partnerId ?? c.partnerId, u = s.activeIntegration ?? c.activeIntegration, h = s.transactionOwnerId, m = s.customerToken ?? c.customerToken, g = s.applicationKey ?? c.applicationKey, f = s.bundleOwnerId;
|
|
334
334
|
try {
|
|
335
335
|
if (window && window.__SENTRY__) {
|
|
336
|
-
const
|
|
337
|
-
if (
|
|
338
|
-
const C =
|
|
336
|
+
const p = window.__SENTRY__.hub;
|
|
337
|
+
if (p) {
|
|
338
|
+
const C = p.traceHeaders();
|
|
339
339
|
Object.entries(C).forEach(([w, v]) => {
|
|
340
340
|
l[w] = v;
|
|
341
341
|
});
|
|
@@ -343,7 +343,7 @@ class $r {
|
|
|
343
343
|
}
|
|
344
344
|
} catch {
|
|
345
345
|
}
|
|
346
|
-
return d && (l.Authorization = `Bearer ${d}`), A && (l.partnerId = A), u && (l.activeIntegration = u), h && (l.transactionOwnerId = h), m && (l.customerToken = m), g && (l["X-Application-Key"] = g),
|
|
346
|
+
return d && (l.Authorization = `Bearer ${d}`), A && (l.partnerId = A), u && (l.activeIntegration = u), h && (l.transactionOwnerId = h), m && (l.customerToken = m), g && (l["X-Application-Key"] = g), f && (l.bundleOwnerId = f), l["Allow-Moonlight-Redirect"] = "true", {
|
|
347
347
|
headers: l
|
|
348
348
|
};
|
|
349
349
|
}), a = cr(({ operation: i, graphQLErrors: s, networkError: o }) => {
|
|
@@ -363,7 +363,7 @@ const gt = (r, t, e) => {
|
|
|
363
363
|
if (Ze !== void 0)
|
|
364
364
|
return Ze(r, t, e);
|
|
365
365
|
try {
|
|
366
|
-
const a =
|
|
366
|
+
const a = fn(!0);
|
|
367
367
|
return gn(a), a.createCanvas(r, t, e);
|
|
368
368
|
} catch {
|
|
369
369
|
throw new Error("Canvas module not set");
|
|
@@ -372,7 +372,7 @@ const gt = (r, t, e) => {
|
|
|
372
372
|
if (ta !== void 0)
|
|
373
373
|
return ta(r, t);
|
|
374
374
|
try {
|
|
375
|
-
const e =
|
|
375
|
+
const e = fn(!0);
|
|
376
376
|
return gn(e), e.loadImage(r, t);
|
|
377
377
|
} catch {
|
|
378
378
|
throw new Error("Canvas module not set");
|
|
@@ -381,7 +381,7 @@ const gt = (r, t, e) => {
|
|
|
381
381
|
function gn(r) {
|
|
382
382
|
Ze = r == null ? void 0 : r.createCanvas, ta = r == null ? void 0 : r.loadImage;
|
|
383
383
|
}
|
|
384
|
-
function
|
|
384
|
+
function fn(r) {
|
|
385
385
|
try {
|
|
386
386
|
if (document.createElement("canvas").getContext("2d"))
|
|
387
387
|
return {
|
|
@@ -3197,9 +3197,9 @@ function Qa(r) {
|
|
|
3197
3197
|
return t.length === 6 ? t : t.length === 3 ? `${t[0]}${t[0]}${t[1]}${t[1]}${t[2]}${t[2]}` : "";
|
|
3198
3198
|
}
|
|
3199
3199
|
const ie = (r) => {
|
|
3200
|
-
const t =
|
|
3200
|
+
const t = pn(r.spotColor);
|
|
3201
3201
|
return t ? `${r.browserValue} ${t}` : r.browserValue;
|
|
3202
|
-
},
|
|
3202
|
+
}, pn = (r) => {
|
|
3203
3203
|
if (!r)
|
|
3204
3204
|
return "";
|
|
3205
3205
|
if (r.profileName.includes("/") && r.profileName.includes(".icc")) {
|
|
@@ -3333,7 +3333,7 @@ const ie = (r) => {
|
|
|
3333
3333
|
if (!i)
|
|
3334
3334
|
throw new Error("Failed to read SVG.");
|
|
3335
3335
|
return _r(i, t, e), wn(i, a, n), yn(i);
|
|
3336
|
-
},
|
|
3336
|
+
}, fa = (r, t, e) => {
|
|
3337
3337
|
const a = Cn(r);
|
|
3338
3338
|
if (!a)
|
|
3339
3339
|
throw new Error("Failed to read SVG.");
|
|
@@ -3422,7 +3422,7 @@ const ie = (r) => {
|
|
|
3422
3422
|
...AssetFields
|
|
3423
3423
|
}
|
|
3424
3424
|
}
|
|
3425
|
-
`,
|
|
3425
|
+
`, pa = y`
|
|
3426
3426
|
fragment MaterialFields on Material {
|
|
3427
3427
|
id
|
|
3428
3428
|
name
|
|
@@ -3470,7 +3470,7 @@ const ie = (r) => {
|
|
|
3470
3470
|
}
|
|
3471
3471
|
}
|
|
3472
3472
|
`, ei = y`
|
|
3473
|
-
${
|
|
3473
|
+
${pa}
|
|
3474
3474
|
query GetMaterials($ids: [String]) {
|
|
3475
3475
|
materials(id: $ids) {
|
|
3476
3476
|
...MaterialFields
|
|
@@ -3861,7 +3861,7 @@ const qt = new oi(), vn = y`
|
|
|
3861
3861
|
}
|
|
3862
3862
|
`, li = y`
|
|
3863
3863
|
${Xt(!1)}
|
|
3864
|
-
${
|
|
3864
|
+
${pa}
|
|
3865
3865
|
${vn}
|
|
3866
3866
|
query GetOptions($ids: [String]!) {
|
|
3867
3867
|
options(ids: $ids) {
|
|
@@ -4238,13 +4238,13 @@ const _ = new ui(), En = y`
|
|
|
4238
4238
|
id
|
|
4239
4239
|
}
|
|
4240
4240
|
}
|
|
4241
|
-
`,
|
|
4241
|
+
`, fi = y`
|
|
4242
4242
|
mutation UpdateTransactionQuantity($id: String!, $quantity: Int) {
|
|
4243
4243
|
transactionUpdate(id: $id, quantity: $quantity) {
|
|
4244
4244
|
id
|
|
4245
4245
|
}
|
|
4246
4246
|
}
|
|
4247
|
-
`,
|
|
4247
|
+
`, pi = y`
|
|
4248
4248
|
query ReadTransactionForDesignCreation($id: String!) {
|
|
4249
4249
|
transactions(ids: [$id]) {
|
|
4250
4250
|
id
|
|
@@ -4566,7 +4566,7 @@ const _ = new ui(), En = y`
|
|
|
4566
4566
|
}
|
|
4567
4567
|
`, Di = (r) => y`
|
|
4568
4568
|
${Xt(r)}
|
|
4569
|
-
${
|
|
4569
|
+
${pa}
|
|
4570
4570
|
${vn}
|
|
4571
4571
|
${Ei}
|
|
4572
4572
|
${Bi}
|
|
@@ -5308,13 +5308,13 @@ const N = () => {
|
|
|
5308
5308
|
width: u
|
|
5309
5309
|
}) => {
|
|
5310
5310
|
var E;
|
|
5311
|
-
const h = e || 0, m = 2 * ((l == null ? void 0 : l.scale) || 1), g = A || { x: 0, y: 0, width: u, height: i },
|
|
5311
|
+
const h = e || 0, m = 2 * ((l == null ? void 0 : l.scale) || 1), g = A || { x: 0, y: 0, width: u, height: i }, f = `${g.x} ${g.y} ${g.width} ${g.height}`, p = N(), C = a.purpose === Wt.FreeDesign && /* @__PURE__ */ x("defs", { children: /* @__PURE__ */ x("clipPath", { id: "viewboxClip", children: /* @__PURE__ */ x("rect", { width: g.width, height: g.height, rx: h }) }) }), w = (E = a.colorProfiles) == null ? void 0 : E.map((B, I) => (
|
|
5312
5312
|
/* @ts-ignore */
|
|
5313
5313
|
/* @__PURE__ */ x("color-profile", { name: B.name, xlinkHref: B.key, children: " " }, I)
|
|
5314
5314
|
)), v = n.map((B) => ({
|
|
5315
5315
|
...B,
|
|
5316
5316
|
_renderingConfiguration: a,
|
|
5317
|
-
mask: l ? `url(#viewmask-${
|
|
5317
|
+
mask: l ? `url(#viewmask-${p})` : void 0
|
|
5318
5318
|
})), S = ya(v);
|
|
5319
5319
|
return /* @__PURE__ */ ct(
|
|
5320
5320
|
"svg",
|
|
@@ -5333,7 +5333,7 @@ const N = () => {
|
|
|
5333
5333
|
maxHeight: s,
|
|
5334
5334
|
position: c
|
|
5335
5335
|
},
|
|
5336
|
-
viewBox:
|
|
5336
|
+
viewBox: f,
|
|
5337
5337
|
children: [
|
|
5338
5338
|
w,
|
|
5339
5339
|
C,
|
|
@@ -5368,7 +5368,7 @@ const N = () => {
|
|
|
5368
5368
|
strokeDasharray: `${m * 2} ${m}`
|
|
5369
5369
|
}
|
|
5370
5370
|
),
|
|
5371
|
-
l && /* @__PURE__ */ ct("mask", { id: `viewmask-${
|
|
5371
|
+
l && /* @__PURE__ */ ct("mask", { id: `viewmask-${p}`, children: [
|
|
5372
5372
|
/* @__PURE__ */ x(
|
|
5373
5373
|
"rect",
|
|
5374
5374
|
{
|
|
@@ -5394,7 +5394,7 @@ const N = () => {
|
|
|
5394
5394
|
}
|
|
5395
5395
|
);
|
|
5396
5396
|
}, Ec = (r, t, e, a, n) => {
|
|
5397
|
-
const i =
|
|
5397
|
+
const i = ft(n), s = e / 2, o = a / 2, l = r + s, c = t + o, d = Math.sin(i), A = Math.cos(i), u = s, h = s, m = -o, g = o, f = u * A - m * d, p = h * A - g * d, C = u * d + m * A, w = h * d + g * A, v = Math.max(Math.abs(f), Math.abs(p)), S = Math.max(Math.abs(C), Math.abs(w));
|
|
5398
5398
|
return {
|
|
5399
5399
|
minX: l - v,
|
|
5400
5400
|
maxX: l + v,
|
|
@@ -5404,8 +5404,8 @@ const N = () => {
|
|
|
5404
5404
|
}, Bc = (r, t, e) => {
|
|
5405
5405
|
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));
|
|
5406
5406
|
return Math.acos((n * n + a * a - i * i) / (2 * n * a)) * (180 / Math.PI);
|
|
5407
|
-
},
|
|
5408
|
-
const a = Math.sin(
|
|
5407
|
+
}, ft = (r) => r * (Math.PI / 180), bc = (r, t, e) => Math.abs(r - t) < e, Ic = (r, t, e) => {
|
|
5408
|
+
const a = Math.sin(ft(e)), n = Math.cos(ft(e));
|
|
5409
5409
|
return {
|
|
5410
5410
|
x: (r.x - t.x) * n - (r.y - t.y) * a + t.x,
|
|
5411
5411
|
y: (r.x - t.x) * a + (r.y - t.y) * n + t.y
|
|
@@ -5442,7 +5442,7 @@ const N = () => {
|
|
|
5442
5442
|
return j.Northwest;
|
|
5443
5443
|
}
|
|
5444
5444
|
}, kc = (r, t) => t > 45 && t <= 135 ? It(r) : t > 135 && t <= 225 ? It(It(r)) : t > 225 && t <= 315 ? It(It(It(r))) : r, Mc = (r, t = { x: 0, y: 0 }, e = { x: 1, y: 1 }) => {
|
|
5445
|
-
const a =
|
|
5445
|
+
const a = ft(r.rotation), n = {
|
|
5446
5446
|
x: t.x + r.x * e.x,
|
|
5447
5447
|
y: t.x + r.y * e.y
|
|
5448
5448
|
}, i = {
|
|
@@ -5472,7 +5472,7 @@ const N = () => {
|
|
|
5472
5472
|
y: (r.x - t.x) * a + (r.y - t.y) * n + t.y
|
|
5473
5473
|
};
|
|
5474
5474
|
}, Tc = 0.352778, Qc = 0.035277, xn = (r) => {
|
|
5475
|
-
const t = r.rotation || 0, e =
|
|
5475
|
+
const t = r.rotation || 0, e = ft(t), a = Math.cos(e), n = -Math.sin(e);
|
|
5476
5476
|
return /* @__PURE__ */ x("g", { mask: r.stepName || r.productOverlay ? void 0 : r.mask, children: /* @__PURE__ */ x(
|
|
5477
5477
|
"g",
|
|
5478
5478
|
{
|
|
@@ -5495,7 +5495,7 @@ const N = () => {
|
|
|
5495
5495
|
) });
|
|
5496
5496
|
}, kn = (r) => {
|
|
5497
5497
|
var l;
|
|
5498
|
-
const t = `spiff-group-clip-${r.id}`, e = r.rotation || 0, a =
|
|
5498
|
+
const t = `spiff-group-clip-${r.id}`, e = r.rotation || 0, a = ft(e), n = Math.cos(a), i = -Math.sin(a), s = ya(r.children);
|
|
5499
5499
|
return /* @__PURE__ */ ct(zt, { children: [
|
|
5500
5500
|
/* @__PURE__ */ x("defs", { children: (() => /* @__PURE__ */ x("clipPath", { id: t, preserveAspectRatio: "none", children: r.clipPath ? /* @__PURE__ */ x("path", { d: r.clipPath }) : /* @__PURE__ */ x("rect", { x: 0, y: 0, width: r.width, height: r.height }) }))() }),
|
|
5501
5501
|
/* @__PURE__ */ ct(
|
|
@@ -5530,7 +5530,7 @@ const N = () => {
|
|
|
5530
5530
|
if (!r.pattern)
|
|
5531
5531
|
return "";
|
|
5532
5532
|
if (r.pattern.svg) {
|
|
5533
|
-
const A =
|
|
5533
|
+
const A = fa(r.pattern.svg, r.pattern.colors || {}, !1);
|
|
5534
5534
|
return Aa(A);
|
|
5535
5535
|
}
|
|
5536
5536
|
return r.pattern.src;
|
|
@@ -5556,17 +5556,17 @@ const N = () => {
|
|
|
5556
5556
|
/* @__PURE__ */ x("feFuncG", { type: "discrete", tableValues: n() }),
|
|
5557
5557
|
/* @__PURE__ */ x("feFuncB", { type: "discrete", tableValues: n() })
|
|
5558
5558
|
] })
|
|
5559
|
-
] }) }) }), s = r.rotation || 0, o =
|
|
5559
|
+
] }) }) }), s = r.rotation || 0, o = ft(s), l = Math.cos(o), c = -Math.sin(o), d = () => {
|
|
5560
5560
|
var w, v, S, E, B, I, P, F, k, Q;
|
|
5561
|
-
const A = ((w = r.pattern) == null ? void 0 : w.x) || 0, u = ((v = r.pattern) == null ? void 0 : v.y) || 0, h = ((S = r.pattern) == null ? void 0 : S.width) || 0, m = ((E = r.pattern) == null ? void 0 : E.height) || 0, g = ((B = r.pattern) == null ? void 0 : B.scaleX) || 1,
|
|
5561
|
+
const A = ((w = r.pattern) == null ? void 0 : w.x) || 0, u = ((v = r.pattern) == null ? void 0 : v.y) || 0, h = ((S = r.pattern) == null ? void 0 : S.width) || 0, m = ((E = r.pattern) == null ? void 0 : E.height) || 0, g = ((B = r.pattern) == null ? void 0 : B.scaleX) || 1, f = ((I = r.pattern) == null ? void 0 : I.scaleY) || 1, p = ((P = r.pattern) == null ? void 0 : P.rotation) || 0;
|
|
5562
5562
|
return [(F = r.pattern) != null && F.svg ? {
|
|
5563
5563
|
id: `${t}-contents`,
|
|
5564
5564
|
type: T.Illustration,
|
|
5565
5565
|
x: A,
|
|
5566
5566
|
y: u,
|
|
5567
|
-
rotation:
|
|
5567
|
+
rotation: p,
|
|
5568
5568
|
width: h * g,
|
|
5569
|
-
height: m *
|
|
5569
|
+
height: m * f,
|
|
5570
5570
|
src: a(),
|
|
5571
5571
|
svg: (k = r.pattern) == null ? void 0 : k.svg,
|
|
5572
5572
|
colors: (Q = r.pattern) == null ? void 0 : Q.colors
|
|
@@ -5575,9 +5575,9 @@ const N = () => {
|
|
|
5575
5575
|
type: T.Image,
|
|
5576
5576
|
x: A,
|
|
5577
5577
|
y: u,
|
|
5578
|
-
rotation:
|
|
5578
|
+
rotation: p,
|
|
5579
5579
|
width: h * g,
|
|
5580
|
-
height: m *
|
|
5580
|
+
height: m * f,
|
|
5581
5581
|
src: a()
|
|
5582
5582
|
}];
|
|
5583
5583
|
};
|
|
@@ -5701,18 +5701,18 @@ const zi = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Oe = /* @_
|
|
|
5701
5701
|
a.querySelectorAll("style").forEach((d) => {
|
|
5702
5702
|
var u;
|
|
5703
5703
|
(u = nn(d.innerHTML).stylesheet) == null || u.rules.forEach((h) => {
|
|
5704
|
-
var m, g,
|
|
5704
|
+
var m, g, f;
|
|
5705
5705
|
if (h.type === "font-face" && h.declarations) {
|
|
5706
|
-
const
|
|
5706
|
+
const p = (m = h.declarations.find(
|
|
5707
5707
|
(v) => v.property === "font-family"
|
|
5708
|
-
)) == null ? void 0 : m.value, C = (g = h.declarations.find((v) => v.property === "src")) == null ? void 0 : g.value, w = (
|
|
5709
|
-
|
|
5708
|
+
)) == null ? void 0 : m.value, C = (g = h.declarations.find((v) => v.property === "src")) == null ? void 0 : g.value, w = (f = C == null ? void 0 : C.match(/'(https.*?)'/)) == null ? void 0 : f[1];
|
|
5709
|
+
p && w && n.set(p, w);
|
|
5710
5710
|
}
|
|
5711
5711
|
});
|
|
5712
5712
|
});
|
|
5713
5713
|
const s = e.querySelectorAll("tspan");
|
|
5714
5714
|
for (let d = 0; d < s.length; d++) {
|
|
5715
|
-
const A = s.item(d), u = A.closest("text"), h = A.closest("g"), m = u.getAttribute("font-family"), g = await Qt(n.get(m)),
|
|
5715
|
+
const A = s.item(d), u = A.closest("text"), h = A.closest("g"), m = u.getAttribute("font-family"), g = await Qt(n.get(m)), f = u.getAttribute("fill"), p = u.getAttribute("stroke"), C = u.getAttribute("stroke-width"), w = g.getPath(
|
|
5716
5716
|
A.innerHTML,
|
|
5717
5717
|
0,
|
|
5718
5718
|
0,
|
|
@@ -5727,7 +5727,7 @@ const zi = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Oe = /* @_
|
|
|
5727
5727
|
parseFloat(A.getAttribute("y") ?? "0"),
|
|
5728
5728
|
parseInt(u.getAttribute("font-size") ?? "72")
|
|
5729
5729
|
);
|
|
5730
|
-
B.fill =
|
|
5730
|
+
B.fill = f, B.stroke = p, B.strokeWidth = parseFloat(C ?? "0");
|
|
5731
5731
|
const I = B.toSVG(2), F = t.parseFromString(I, "image/svg+xml").firstElementChild;
|
|
5732
5732
|
h.appendChild(F);
|
|
5733
5733
|
}
|
|
@@ -5865,14 +5865,14 @@ const zi = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Oe = /* @_
|
|
|
5865
5865
|
};
|
|
5866
5866
|
})()
|
|
5867
5867
|
} : r, Ca = 1.1, Ki = (r) => {
|
|
5868
|
-
var h, m, g,
|
|
5868
|
+
var h, m, g, f;
|
|
5869
5869
|
const e = (r.rotation || 0) * Math.PI / 180, a = Math.cos(e), n = -Math.sin(e), i = `text-path-${r.id}`, s = `text-fill-${r.id}`, o = r.x + (r.curved ? 0 : r.width / 2), l = r.y + (r.curved ? 0 : r.height / 2), c = (r.text || "").split(`
|
|
5870
5870
|
`), d = (h = r.strokeColor) != null && h.browserValue && r.strokeThickness ? (m = r.strokeColor) == null ? void 0 : m.browserValue : void 0, A = (g = r.strokeColor) != null && g.browserValue && r.strokeThickness ? r.strokeThickness : void 0;
|
|
5871
5871
|
if (r.curved && !r.paths || !r.fontData)
|
|
5872
5872
|
return null;
|
|
5873
5873
|
const u = () => {
|
|
5874
|
-
var
|
|
5875
|
-
return r.textFillImage ? `url("#${s}")` : (
|
|
5874
|
+
var p;
|
|
5875
|
+
return r.textFillImage ? `url("#${s}")` : (p = r._renderingConfiguration) != null && p.spotColors && r.fillSpotColorDefinition ? `${r.fill} ${pn(r.fillSpotColorDefinition)}` : r.fill;
|
|
5876
5876
|
};
|
|
5877
5877
|
return /* @__PURE__ */ ct(zt, { children: [
|
|
5878
5878
|
/* @__PURE__ */ ct("defs", { children: [
|
|
@@ -5912,7 +5912,7 @@ const zi = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Oe = /* @_
|
|
|
5912
5912
|
),
|
|
5913
5913
|
r.curved && r.paths ? /* @__PURE__ */ x("path", { id: i, d: r.paths[0] }) : void 0
|
|
5914
5914
|
] }),
|
|
5915
|
-
(
|
|
5915
|
+
(f = r._renderingConfiguration) != null && f.debug ? /* @__PURE__ */ x("rect", { stroke: "blue", fill: "none", x: r.x, y: r.y, width: r.width, height: r.height }) : void 0,
|
|
5916
5916
|
/* @__PURE__ */ x("g", { mask: r.stepName ? void 0 : r.mask, children: /* @__PURE__ */ x("g", { transform: `matrix(${a}, ${-n}, ${n}, ${a}, ${o}, ${l})`, children: /* @__PURE__ */ x(
|
|
5917
5917
|
"text",
|
|
5918
5918
|
{
|
|
@@ -5928,14 +5928,14 @@ const zi = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Oe = /* @_
|
|
|
5928
5928
|
},
|
|
5929
5929
|
stroke: d,
|
|
5930
5930
|
strokeWidth: A,
|
|
5931
|
-
children: r.curved ? /* @__PURE__ */ x(Xi, { text: r.text || "", curvedPathId: i, align: r.align }) : c.map((
|
|
5931
|
+
children: r.curved ? /* @__PURE__ */ x(Xi, { text: r.text || "", curvedPathId: i, align: r.align }) : c.map((p, C) => /* @__PURE__ */ x(
|
|
5932
5932
|
_i,
|
|
5933
5933
|
{
|
|
5934
5934
|
align: r.vertical ? "center" : r.align,
|
|
5935
5935
|
fontSize: r.fontSize,
|
|
5936
5936
|
thisLineIdx: C,
|
|
5937
5937
|
amountLines: c.length,
|
|
5938
|
-
text:
|
|
5938
|
+
text: p,
|
|
5939
5939
|
textboxHeight: r.height,
|
|
5940
5940
|
textboxWidth: r.width,
|
|
5941
5941
|
lineHeight: r.lineHeight,
|
|
@@ -5990,7 +5990,7 @@ const zi = (r) => r.substring(0, 5).toLowerCase().trim() === "data:", Oe = /* @_
|
|
|
5990
5990
|
mask: r.stepName ? void 0 : r.mask
|
|
5991
5991
|
}
|
|
5992
5992
|
);
|
|
5993
|
-
const t = r.rotation || 0, e =
|
|
5993
|
+
const t = r.rotation || 0, e = ft(t), a = Math.cos(e), n = -Math.sin(e), i = `
|
|
5994
5994
|
matrix(1, 0, 0, 1, ${r.x}, ${r.y})
|
|
5995
5995
|
matrix(1, 0, 0, 1, ${r.width / 2}, ${r.height / 2})
|
|
5996
5996
|
matrix(${a}, ${-n}, ${n}, ${a}, 0, 0)
|
|
@@ -6309,8 +6309,8 @@ const te = (r) => {
|
|
|
6309
6309
|
fetch: nt
|
|
6310
6310
|
}), u = s.getAttribute("width"), h = s.getAttribute("height"), m = 2048;
|
|
6311
6311
|
if (h && u) {
|
|
6312
|
-
const g = parseFloat(h),
|
|
6313
|
-
|
|
6312
|
+
const g = parseFloat(h), p = parseFloat(u) / g;
|
|
6313
|
+
p > 1 ? A.resize(m, m / p) : A.resize(m * p, m);
|
|
6314
6314
|
} else
|
|
6315
6315
|
A.resize(m, m);
|
|
6316
6316
|
return await A.render(), await t(c);
|
|
@@ -6334,8 +6334,8 @@ const te = (r) => {
|
|
|
6334
6334
|
const l = await lt(await $n(e)), u = dt().parseFromString(l.svg, "image/svg+xml").firstElementChild.getAttribute("viewBox");
|
|
6335
6335
|
if (!u)
|
|
6336
6336
|
throw new Error("SVG missing viewBox.");
|
|
6337
|
-
const h = o.height, m = u.split(" "), g = parseFloat(m[2]) || 1,
|
|
6338
|
-
o.height = o.width /
|
|
6337
|
+
const h = o.height, m = u.split(" "), g = parseFloat(m[2]) || 1, f = parseFloat(m[3]) || 1, p = g / f;
|
|
6338
|
+
o.height = o.width / p, o.top += (h - o.height) / 2;
|
|
6339
6339
|
}
|
|
6340
6340
|
if (e && t === T.Image) {
|
|
6341
6341
|
const l = o.height, c = await De(e), d = await Fe(c), A = d.width / d.height;
|
|
@@ -7227,13 +7227,13 @@ class Ga {
|
|
|
7227
7227
|
command: new G(h, i)
|
|
7228
7228
|
};
|
|
7229
7229
|
} else {
|
|
7230
|
-
const u = this.configuration.type === D.SilentIllustration ? (A = this.configuration.data.asset) == null ? void 0 : A.fileLink : s, m = await lt(await (async () => new Promise((
|
|
7230
|
+
const u = this.configuration.type === D.SilentIllustration ? (A = this.configuration.data.asset) == null ? void 0 : A.fileLink : s, m = await lt(await (async () => new Promise((f, p) => {
|
|
7231
7231
|
if (!u) {
|
|
7232
|
-
|
|
7232
|
+
p("Undefined vector silent step source");
|
|
7233
7233
|
return;
|
|
7234
7234
|
}
|
|
7235
7235
|
at(u, !0).then((C) => {
|
|
7236
|
-
|
|
7236
|
+
f(C);
|
|
7237
7237
|
}).catch((C) => console.error(C));
|
|
7238
7238
|
}))()), g = {
|
|
7239
7239
|
stepName: this.configuration.stepName,
|
|
@@ -7342,8 +7342,8 @@ class ds {
|
|
|
7342
7342
|
}
|
|
7343
7343
|
async regenerateQRCode(t, e, a, n) {
|
|
7344
7344
|
const i = async () => {
|
|
7345
|
-
var g,
|
|
7346
|
-
const h = (await ea([e]))[0], m = (
|
|
7345
|
+
var g, f;
|
|
7346
|
+
const h = (await ea([e]))[0], m = (f = (g = h == null ? void 0 : h.versions) == null ? void 0 : g.find((p) => p.name === "mpeg4")) == null ? void 0 : f.link;
|
|
7347
7347
|
return { asset: h, link: m };
|
|
7348
7348
|
}, s = await new Promise((h, m) => {
|
|
7349
7349
|
new Ln(
|
|
@@ -7476,13 +7476,13 @@ class Se {
|
|
|
7476
7476
|
}
|
|
7477
7477
|
if (n) {
|
|
7478
7478
|
const d = async () => {
|
|
7479
|
-
var m, g,
|
|
7480
|
-
const A = (m = n.storage) == null ? void 0 : m.colors, u = (g = n.storage) == null ? void 0 : g.framePatternSrc, h = (
|
|
7479
|
+
var m, g, f, p, C;
|
|
7480
|
+
const A = (m = n.storage) == null ? void 0 : m.colors, u = (g = n.storage) == null ? void 0 : g.framePatternSrc, h = (f = n.storage) == null ? void 0 : f.frameOffsetsList;
|
|
7481
7481
|
if (e.updateMetadata(t.stepName, {
|
|
7482
7482
|
frameOffsetsList: h,
|
|
7483
7483
|
framePatternSrc: u
|
|
7484
7484
|
}), u) {
|
|
7485
|
-
const w = (
|
|
7485
|
+
const w = (p = e.getWorkflowExperience().getStepById(t.stepName)) == null ? void 0 : p.frameService;
|
|
7486
7486
|
if (!w)
|
|
7487
7487
|
throw new Error("Frame service unavailable, cannot load pattern!");
|
|
7488
7488
|
await this.loadPatternFromString(u, w, !0, A), e.updateMetadata(t.stepName, { image: u }), e.updateStorage(t.stepName, {
|
|
@@ -7706,18 +7706,18 @@ class Se {
|
|
|
7706
7706
|
i && i(!0);
|
|
7707
7707
|
const c = t.data.initialZoomLevel, d = await Promise.all(
|
|
7708
7708
|
t.data.regions.map(async (m, g) => {
|
|
7709
|
-
const
|
|
7710
|
-
f,
|
|
7709
|
+
const f = await Me(l[g]), p = o.getImageData(), C = a.map((I) => new Et(I.id)), w = p ? Sa(
|
|
7711
7710
|
p,
|
|
7711
|
+
f,
|
|
7712
7712
|
c && !t.data.forceImageCover ? { scale: c } : void 0,
|
|
7713
7713
|
t.data.forceImageCover
|
|
7714
|
-
) : void 0, v =
|
|
7714
|
+
) : void 0, v = p ? {
|
|
7715
7715
|
id: N(),
|
|
7716
|
-
src:
|
|
7716
|
+
src: p.src,
|
|
7717
7717
|
x: (w == null ? void 0 : w.x) || 0,
|
|
7718
7718
|
y: (w == null ? void 0 : w.y) || 0,
|
|
7719
|
-
width:
|
|
7720
|
-
height:
|
|
7719
|
+
width: p.width,
|
|
7720
|
+
height: p.height,
|
|
7721
7721
|
scaleX: (w == null ? void 0 : w.zoom) || 1,
|
|
7722
7722
|
scaleY: (w == null ? void 0 : w.zoom) || 1,
|
|
7723
7723
|
rotation: 0
|
|
@@ -7726,7 +7726,7 @@ class Se {
|
|
|
7726
7726
|
throw new q(m);
|
|
7727
7727
|
return {
|
|
7728
7728
|
command: this.getCreateElementCommand(S, m, B, {
|
|
7729
|
-
frameData:
|
|
7729
|
+
frameData: f,
|
|
7730
7730
|
pattern: v,
|
|
7731
7731
|
disablePlaceholder: t.data.disablePlaceholder,
|
|
7732
7732
|
stepName: t.stepName
|
|
@@ -7927,25 +7927,25 @@ class As {
|
|
|
7927
7927
|
e[0].id,
|
|
7928
7928
|
n().map((g) => g.layoutState)
|
|
7929
7929
|
), o = { ...s.colors }, l = {};
|
|
7930
|
-
Object.entries(o).forEach(([g,
|
|
7931
|
-
const
|
|
7932
|
-
C && (
|
|
7930
|
+
Object.entries(o).forEach(([g, f]) => {
|
|
7931
|
+
const p = { browserValue: f.browserValue, pmsValue: f.pmsValue }, C = f.spotColor;
|
|
7932
|
+
C && (p.spotColor = { profileName: C.profileName, namedColor: C.namedColor }), l[g] = p;
|
|
7933
7933
|
});
|
|
7934
|
-
for (const [g,
|
|
7935
|
-
const
|
|
7936
|
-
o[g] = { browserValue:
|
|
7934
|
+
for (const [g, f] of i.entries()) {
|
|
7935
|
+
const p = typeof f == "string" ? f : f.browserValue, C = typeof f == "string" ? void 0 : f.pmsValue;
|
|
7936
|
+
o[g] = { browserValue: p, spotColor: (h = o[g]) == null ? void 0 : h.spotColor, pmsValue: C }, l[g] = { browserValue: p };
|
|
7937
7937
|
}
|
|
7938
7938
|
let c = Array.from(Object.values(o)).map((g) => g.browserValue);
|
|
7939
7939
|
const d = t.data.colorOption;
|
|
7940
7940
|
d && ((m = d.variants) == null || m.forEach((g) => {
|
|
7941
|
-
c = c.map((
|
|
7942
|
-
var
|
|
7943
|
-
return
|
|
7941
|
+
c = c.map((f) => {
|
|
7942
|
+
var p;
|
|
7943
|
+
return f.toLowerCase() === ((p = g.color) == null ? void 0 : p.toLowerCase()) ? g.name : f;
|
|
7944
7944
|
});
|
|
7945
7945
|
})), a.updateMetadata(t.stepName, { colors: c });
|
|
7946
7946
|
const A = /* @__PURE__ */ new Map();
|
|
7947
|
-
if (Object.entries(o).forEach(([g,
|
|
7948
|
-
A.set(g,
|
|
7947
|
+
if (Object.entries(o).forEach(([g, f]) => {
|
|
7948
|
+
A.set(g, f);
|
|
7949
7949
|
}), !s.svg)
|
|
7950
7950
|
throw new Error("Colors changed before SVG loaded. This should never happen!");
|
|
7951
7951
|
const u = await this.changeColorsCommand(
|
|
@@ -7964,7 +7964,7 @@ class As {
|
|
|
7964
7964
|
s && (s.command && i.getCommandDispatcher()(s.command), s.followup && await s.followup());
|
|
7965
7965
|
}
|
|
7966
7966
|
async selectVariantCommand(t, e, a, n, i) {
|
|
7967
|
-
var
|
|
7967
|
+
var p;
|
|
7968
7968
|
if (!t.data || !t.data.regions)
|
|
7969
7969
|
throw new Ce(t, "Missing regions.");
|
|
7970
7970
|
n(!0);
|
|
@@ -7992,8 +7992,8 @@ class As {
|
|
|
7992
7992
|
};
|
|
7993
7993
|
}, u = t.data.regions.map(A), m = [...u.map((C) => C.command), ...s];
|
|
7994
7994
|
let g = Array.from(Object.values(c.colors)).map((C) => C.browserValue);
|
|
7995
|
-
const
|
|
7996
|
-
return
|
|
7995
|
+
const f = t.data.colorOption;
|
|
7996
|
+
return f && ((p = f.variants) == null || p.forEach((C) => {
|
|
7997
7997
|
g = g.map((w) => {
|
|
7998
7998
|
var v;
|
|
7999
7999
|
return w.toLowerCase() === ((v = C.color) == null ? void 0 : v.toLowerCase()) ? C.name : w;
|
|
@@ -8054,7 +8054,7 @@ class us {
|
|
|
8054
8054
|
async init(t, e, a) {
|
|
8055
8055
|
const n = t.option;
|
|
8056
8056
|
if (!n)
|
|
8057
|
-
throw new
|
|
8057
|
+
throw new pe(t);
|
|
8058
8058
|
if (a)
|
|
8059
8059
|
await this.reload(t, e, a);
|
|
8060
8060
|
else {
|
|
@@ -8072,7 +8072,7 @@ class us {
|
|
|
8072
8072
|
a.serializableWorkflow.steps
|
|
8073
8073
|
), o = Object.values(a.layouts).map((d) => d.elements).flat().filter((d) => d.stepName === t.stepName), l = t.option;
|
|
8074
8074
|
if (!l)
|
|
8075
|
-
throw new
|
|
8075
|
+
throw new pe(t);
|
|
8076
8076
|
if (n != null && n.selectedVariants) {
|
|
8077
8077
|
const d = n.selectedVariants[0].id;
|
|
8078
8078
|
if (d) {
|
|
@@ -8086,8 +8086,8 @@ class us {
|
|
|
8086
8086
|
async () => {
|
|
8087
8087
|
const m = e.getModelContainer();
|
|
8088
8088
|
if (m) {
|
|
8089
|
-
const g = t.data.targetMaterials.map((
|
|
8090
|
-
|
|
8089
|
+
const g = t.data.targetMaterials.map((f) => m.applyMaterialVariant(
|
|
8090
|
+
f,
|
|
8091
8091
|
l.id || "",
|
|
8092
8092
|
u || {}
|
|
8093
8093
|
));
|
|
@@ -8132,7 +8132,7 @@ class hs {
|
|
|
8132
8132
|
async init(t, e, a) {
|
|
8133
8133
|
const n = t.option;
|
|
8134
8134
|
if (!n)
|
|
8135
|
-
throw new
|
|
8135
|
+
throw new pe(t);
|
|
8136
8136
|
if (a)
|
|
8137
8137
|
await this.reload(t, e, a);
|
|
8138
8138
|
else {
|
|
@@ -8249,11 +8249,11 @@ class ms {
|
|
|
8249
8249
|
return console.error("Missing configuration."), null;
|
|
8250
8250
|
a.updateStorage(t.stepName, { text: e }), a.updateMetadata(t.stepName, { text: e });
|
|
8251
8251
|
const c = (A, u, h) => {
|
|
8252
|
-
const m = h || N(),
|
|
8253
|
-
if (!
|
|
8252
|
+
const m = h || N(), f = a.getLayouts().find((C) => C.panelId === u.panelId);
|
|
8253
|
+
if (!f)
|
|
8254
8254
|
return console.error(`Can not find layout for region: ${u.panelId}`), null;
|
|
8255
|
-
const
|
|
8256
|
-
return h &&
|
|
8255
|
+
const p = [];
|
|
8256
|
+
return h && p.push(new Et(m)), p.push(
|
|
8257
8257
|
new G(
|
|
8258
8258
|
{
|
|
8259
8259
|
stepRegion: u,
|
|
@@ -8271,12 +8271,12 @@ class ms {
|
|
|
8271
8271
|
layerIndex: u.layerIndex,
|
|
8272
8272
|
immutable: u.immutable
|
|
8273
8273
|
},
|
|
8274
|
-
|
|
8274
|
+
f
|
|
8275
8275
|
)
|
|
8276
8276
|
), {
|
|
8277
8277
|
id: m,
|
|
8278
8278
|
region: u,
|
|
8279
|
-
command: new $(
|
|
8279
|
+
command: new $(p)
|
|
8280
8280
|
};
|
|
8281
8281
|
};
|
|
8282
8282
|
if (i.length > 0) {
|
|
@@ -8419,7 +8419,7 @@ class gs {
|
|
|
8419
8419
|
}
|
|
8420
8420
|
}
|
|
8421
8421
|
const jn = new gs();
|
|
8422
|
-
class
|
|
8422
|
+
class fs {
|
|
8423
8423
|
async init(t, e, a) {
|
|
8424
8424
|
const n = t.option;
|
|
8425
8425
|
if (!n)
|
|
@@ -8477,8 +8477,8 @@ class ps {
|
|
|
8477
8477
|
};
|
|
8478
8478
|
}
|
|
8479
8479
|
}
|
|
8480
|
-
const Hn = new
|
|
8481
|
-
class
|
|
8480
|
+
const Hn = new fs();
|
|
8481
|
+
class ps {
|
|
8482
8482
|
constructor() {
|
|
8483
8483
|
this.shapeFillId = "spiff-fill-shape";
|
|
8484
8484
|
}
|
|
@@ -8504,7 +8504,7 @@ class fs {
|
|
|
8504
8504
|
async init(t, e, a) {
|
|
8505
8505
|
const n = t.option;
|
|
8506
8506
|
if (!n)
|
|
8507
|
-
throw new
|
|
8507
|
+
throw new pe(t);
|
|
8508
8508
|
if (a)
|
|
8509
8509
|
await this.reload(t, e, a);
|
|
8510
8510
|
else {
|
|
@@ -8586,7 +8586,7 @@ class fs {
|
|
|
8586
8586
|
const m = i.find((w) => w.panelId === h.panelId);
|
|
8587
8587
|
if (!m)
|
|
8588
8588
|
throw new q(h);
|
|
8589
|
-
const g = o(),
|
|
8589
|
+
const g = o(), f = `
|
|
8590
8590
|
<svg
|
|
8591
8591
|
xmlns="http://www.w3.org/2000/svg"
|
|
8592
8592
|
xmlnsXlink="http://www.w3.org/1999/xlink"
|
|
@@ -8606,8 +8606,8 @@ class fs {
|
|
|
8606
8606
|
fill="${g}"
|
|
8607
8607
|
/>
|
|
8608
8608
|
</svg>
|
|
8609
|
-
`,
|
|
8610
|
-
|
|
8609
|
+
`, p = {};
|
|
8610
|
+
p[this.shapeFillId] = { browserValue: g };
|
|
8611
8611
|
const C = N();
|
|
8612
8612
|
return {
|
|
8613
8613
|
id: C,
|
|
@@ -8616,9 +8616,9 @@ class fs {
|
|
|
8616
8616
|
{
|
|
8617
8617
|
stepRegion: h,
|
|
8618
8618
|
stepName: t.stepName,
|
|
8619
|
-
colors:
|
|
8619
|
+
colors: p,
|
|
8620
8620
|
id: C,
|
|
8621
|
-
svg:
|
|
8621
|
+
svg: f,
|
|
8622
8622
|
type: T.Illustration,
|
|
8623
8623
|
y: h.top,
|
|
8624
8624
|
x: h.left,
|
|
@@ -8650,7 +8650,7 @@ class fs {
|
|
|
8650
8650
|
}
|
|
8651
8651
|
}
|
|
8652
8652
|
}
|
|
8653
|
-
const Vt = new
|
|
8653
|
+
const Vt = new ps();
|
|
8654
8654
|
class Cs {
|
|
8655
8655
|
constructor() {
|
|
8656
8656
|
this.latestToast = null, this.toastType = null, this.toastCallbacks = [];
|
|
@@ -8689,14 +8689,14 @@ const ws = new Cs(), Ge = (r, t, e, a, n) => {
|
|
|
8689
8689
|
const A = Math.max(...o);
|
|
8690
8690
|
if (A <= r.width)
|
|
8691
8691
|
return [i, A];
|
|
8692
|
-
const u = o.reduce((
|
|
8692
|
+
const u = o.reduce((f, p, C, w) => p > w[f] ? C : f, 0), h = i[u];
|
|
8693
8693
|
let m = !1, g = h.length;
|
|
8694
8694
|
for (; !m && g > -1; ) {
|
|
8695
8695
|
g = h.lastIndexOf(" ", g - 1);
|
|
8696
|
-
const
|
|
8697
|
-
|
|
8696
|
+
const f = [h.slice(0, g), h.slice(g + 1)], p = f.map((w) => ht(w, a, n));
|
|
8697
|
+
p[0] <= r.width && (i = [...i.slice(0, u), ...f, ...i.slice(u + 1)], o = [
|
|
8698
8698
|
...o.slice(0, u),
|
|
8699
|
-
...
|
|
8699
|
+
...p,
|
|
8700
8700
|
...o.slice(u + 1)
|
|
8701
8701
|
], s += 1, m = !0);
|
|
8702
8702
|
}
|
|
@@ -9013,19 +9013,19 @@ class Ss {
|
|
|
9013
9013
|
if (l && u) {
|
|
9014
9014
|
const h = (c = l.variants) == null ? void 0 : c.find((m) => m.id === u);
|
|
9015
9015
|
if (h) {
|
|
9016
|
-
const m = await this.fontDataFromVariant(h), g = o.map((w) => ({ id: w.id, region: w.stepRegion })),
|
|
9016
|
+
const m = await this.fontDataFromVariant(h), g = o.map((w) => ({ id: w.id, region: w.stepRegion })), f = (d = n.storage) == null ? void 0 : d.color, p = (A = n.storage) == null ? void 0 : A.text;
|
|
9017
9017
|
await e.setSelectionsAndElements(
|
|
9018
9018
|
t.stepName,
|
|
9019
9019
|
[h],
|
|
9020
9020
|
g,
|
|
9021
9021
|
async () => {
|
|
9022
|
-
e.updateMetadata(t.stepName, { color:
|
|
9022
|
+
e.updateMetadata(t.stepName, { color: f, text: p }), e.updateStorage(t.stepName, { text: p, inputText: p });
|
|
9023
9023
|
const w = o.map((S) => new za(S.id, m)), v = new $(w);
|
|
9024
9024
|
e.getCommandDispatcher()(v);
|
|
9025
9025
|
}
|
|
9026
9026
|
);
|
|
9027
9027
|
const { command: C } = H.updateInputText(
|
|
9028
|
-
|
|
9028
|
+
p || "",
|
|
9029
9029
|
o,
|
|
9030
9030
|
t,
|
|
9031
9031
|
e
|
|
@@ -9074,16 +9074,16 @@ class Ss {
|
|
|
9074
9074
|
var u;
|
|
9075
9075
|
const d = i.markUpdatePending(), A = await this.fontDataFromVariant(e);
|
|
9076
9076
|
if (n.length > 0) {
|
|
9077
|
-
const h = n.map((
|
|
9077
|
+
const h = n.map((f) => new za(f.id, A));
|
|
9078
9078
|
if (l) {
|
|
9079
|
-
const
|
|
9080
|
-
h.push(...
|
|
9079
|
+
const f = n.map((p) => new Ve(p.id, l));
|
|
9080
|
+
h.push(...f);
|
|
9081
9081
|
}
|
|
9082
9082
|
if (c) {
|
|
9083
|
-
const
|
|
9084
|
-
(
|
|
9083
|
+
const f = n.map(
|
|
9084
|
+
(p) => new ze(p.id, c, t.data.strokeThickness)
|
|
9085
9085
|
);
|
|
9086
|
-
h.push(...
|
|
9086
|
+
h.push(...f);
|
|
9087
9087
|
}
|
|
9088
9088
|
const m = await this.changeInputTextWithRegion(
|
|
9089
9089
|
t,
|
|
@@ -9120,18 +9120,18 @@ class Ss {
|
|
|
9120
9120
|
!!a.customiseAllText,
|
|
9121
9121
|
s,
|
|
9122
9122
|
o
|
|
9123
|
-
), g = h.flatMap((
|
|
9123
|
+
), g = h.flatMap((p) => p.commands);
|
|
9124
9124
|
if (l) {
|
|
9125
|
-
const
|
|
9125
|
+
const p = h.map(
|
|
9126
9126
|
(C) => new Ve(C.regionElement.id, l)
|
|
9127
9127
|
);
|
|
9128
|
-
g.push(...
|
|
9128
|
+
g.push(...p);
|
|
9129
9129
|
}
|
|
9130
9130
|
if (c) {
|
|
9131
|
-
const
|
|
9131
|
+
const p = n.map(
|
|
9132
9132
|
(C) => new ze(C.id, c, t.data.strokeThickness)
|
|
9133
9133
|
);
|
|
9134
|
-
g.push(...
|
|
9134
|
+
g.push(...p);
|
|
9135
9135
|
}
|
|
9136
9136
|
return m && g.push(m), {
|
|
9137
9137
|
command: new $(g),
|
|
@@ -9154,19 +9154,19 @@ class Ss {
|
|
|
9154
9154
|
throw new Error("Step data not supplied");
|
|
9155
9155
|
const o = i.text || a.defaultText || "", l = this.getProcessedInput(o, a, !1), c = async (A) => {
|
|
9156
9156
|
var g;
|
|
9157
|
-
const h = s.getLayouts().find((
|
|
9157
|
+
const h = s.getLayouts().find((f) => f.panelId === A.panelId), m = N();
|
|
9158
9158
|
try {
|
|
9159
9159
|
if (!h)
|
|
9160
9160
|
throw new Ee("Failed to find layout for region: " + A.panelId);
|
|
9161
|
-
const
|
|
9162
|
-
let
|
|
9163
|
-
if (
|
|
9164
|
-
const Q =
|
|
9161
|
+
const f = a.colorOption;
|
|
9162
|
+
let p;
|
|
9163
|
+
if (f && f.variants) {
|
|
9164
|
+
const Q = f.variants.find((it) => {
|
|
9165
9165
|
var R;
|
|
9166
|
-
return it.id === ((R =
|
|
9167
|
-
}) ||
|
|
9168
|
-
|
|
9169
|
-
colorProfileAssetKey: (g =
|
|
9166
|
+
return it.id === ((R = f.defaultVariant) == null ? void 0 : R.id);
|
|
9167
|
+
}) || f.variants[0];
|
|
9168
|
+
p = this.createTextFillSpotColor(f, Q), s.updateStorage(t, {
|
|
9169
|
+
colorProfileAssetKey: (g = f.colorProfile) == null ? void 0 : g.key
|
|
9170
9170
|
});
|
|
9171
9171
|
}
|
|
9172
9172
|
const C = await this.getDefaultColor(a), w = C || "#000000", v = {
|
|
@@ -9192,7 +9192,7 @@ class Ss {
|
|
|
9192
9192
|
verticalAlign: a.verticalAlign || "middle",
|
|
9193
9193
|
curved: a.curved,
|
|
9194
9194
|
paths: a.paths,
|
|
9195
|
-
fillSpotColorDefinition:
|
|
9195
|
+
fillSpotColorDefinition: p
|
|
9196
9196
|
}, S = [], E = /* @__PURE__ */ new Map(), B = /* @__PURE__ */ new Map();
|
|
9197
9197
|
if (!v.fontData)
|
|
9198
9198
|
throw new z("Failed to resolve font data for text.");
|
|
@@ -9223,8 +9223,8 @@ class Ss {
|
|
|
9223
9223
|
newElement: v,
|
|
9224
9224
|
fontData: n
|
|
9225
9225
|
};
|
|
9226
|
-
} catch (
|
|
9227
|
-
throw console.log(
|
|
9226
|
+
} catch (f) {
|
|
9227
|
+
throw console.log(f), new ve("Error adding font to region");
|
|
9228
9228
|
}
|
|
9229
9229
|
}, d = await Promise.all(a.regions.map(c)).catch((A) => {
|
|
9230
9230
|
throw A instanceof ve ? (ws.setLatestToast("Failed to load font.", Te.Error), A) : A instanceof Ee ? A : new Error(A);
|
|
@@ -9266,7 +9266,7 @@ class Ss {
|
|
|
9266
9266
|
);
|
|
9267
9267
|
m.set(v.id, S), g.set(v.id, E);
|
|
9268
9268
|
}
|
|
9269
|
-
const
|
|
9269
|
+
const p = (() => {
|
|
9270
9270
|
if (t.data && t.data.maxLength && u.length > t.data.maxLength)
|
|
9271
9271
|
return d && d(!0), { info: "0" };
|
|
9272
9272
|
const v = s.getProfanities(), S = Ke(u.toLowerCase());
|
|
@@ -9279,11 +9279,11 @@ class Ss {
|
|
|
9279
9279
|
return !t.data.vertical && !t.data.allowNewlines && (u.includes(`
|
|
9280
9280
|
`) || 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() });
|
|
9281
9281
|
})();
|
|
9282
|
-
if (
|
|
9283
|
-
c(
|
|
9282
|
+
if (p.error) {
|
|
9283
|
+
c(p.error);
|
|
9284
9284
|
return;
|
|
9285
9285
|
}
|
|
9286
|
-
if (c(`${
|
|
9286
|
+
if (c(`${p.info} characters remaining` || ""), d)
|
|
9287
9287
|
return;
|
|
9288
9288
|
s.updateStorage(t.stepName, { text: A }), s.updateMetadata(t.stepName, {
|
|
9289
9289
|
text: this.injectReplaceableText(A, t.data)
|
|
@@ -9483,12 +9483,12 @@ class xs extends vs {
|
|
|
9483
9483
|
m.classList.add("module-bounds"), u.appendChild(m);
|
|
9484
9484
|
const g = Bs(e.height, e.width);
|
|
9485
9485
|
g.setAttribute("opacity", "0"), m.appendChild(g);
|
|
9486
|
-
const
|
|
9487
|
-
|
|
9488
|
-
const
|
|
9489
|
-
|
|
9486
|
+
const f = tt("g");
|
|
9487
|
+
f.classList.add("module-text-enclosure"), u.appendChild(f);
|
|
9488
|
+
const p = A();
|
|
9489
|
+
f.appendChild(p);
|
|
9490
9490
|
const C = mr(d);
|
|
9491
|
-
return Ds(
|
|
9491
|
+
return Ds(f, C, e.height, e.width, 0.35, 0.65), Is(u.outerHTML);
|
|
9492
9492
|
}
|
|
9493
9493
|
}
|
|
9494
9494
|
async function qn(r) {
|
|
@@ -10150,7 +10150,7 @@ class Ha extends Pn {
|
|
|
10150
10150
|
}
|
|
10151
10151
|
}
|
|
10152
10152
|
class lo {
|
|
10153
|
-
constructor(t, e, a, n, i, s, o, l, c, d, A, u, h, m = !1, g,
|
|
10153
|
+
constructor(t, e, a, n, i, s, o, l, c, d, A, u, h, m = !1, g, f = !1, p = !1, C = !1) {
|
|
10154
10154
|
this.workflowStatePromiseQueue = new Fn(1), this.initialized = !1, this.readOnly = !1, this.isReloadedTransaction = !1, this.singleVariantsRenderable = !1, this.stepTags = {}, this.renderLayouts = () => {
|
|
10155
10155
|
var S;
|
|
10156
10156
|
if (!this.previewService)
|
|
@@ -10159,7 +10159,7 @@ class lo {
|
|
|
10159
10159
|
if (v)
|
|
10160
10160
|
for (const [, E] of v)
|
|
10161
10161
|
E.render(w);
|
|
10162
|
-
}, 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 =
|
|
10162
|
+
}, 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 = p, 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.currentAdjustingStepId = "", this.renderableContextService = u, this.isReloadedTransaction = f, this.workflow.steps.forEach((w) => {
|
|
10163
10163
|
this.stepTags[w.stepName] = w.tags ?? [];
|
|
10164
10164
|
}), C && (this.workflowStatePromiseQueue.enabled = !1), this.initializationPromise = this.initializeDefaultWorkflowState(a), this.initializationPromise.then(() => {
|
|
10165
10165
|
this.initialized = !0;
|
|
@@ -10205,7 +10205,7 @@ class lo {
|
|
|
10205
10205
|
}
|
|
10206
10206
|
});
|
|
10207
10207
|
else {
|
|
10208
|
-
const
|
|
10208
|
+
const f = await this.graphQlClient().mutate({
|
|
10209
10209
|
mutation: ro,
|
|
10210
10210
|
errorPolicy: "all",
|
|
10211
10211
|
fetchPolicy: "no-cache",
|
|
@@ -10223,7 +10223,7 @@ class lo {
|
|
|
10223
10223
|
}
|
|
10224
10224
|
});
|
|
10225
10225
|
this.transaction.recipient = {
|
|
10226
|
-
id: (h = (u =
|
|
10226
|
+
id: (h = (u = f == null ? void 0 : f.data) == null ? void 0 : u.recipientCreate) == null ? void 0 : h.id,
|
|
10227
10227
|
firstName: t,
|
|
10228
10228
|
lastName: e,
|
|
10229
10229
|
address: a,
|
|
@@ -10240,14 +10240,13 @@ class lo {
|
|
|
10240
10240
|
fetchPolicy: "no-cache",
|
|
10241
10241
|
variables: {
|
|
10242
10242
|
id: this.transaction.id,
|
|
10243
|
-
recipientId: (g = (m =
|
|
10243
|
+
recipientId: (g = (m = f.data) == null ? void 0 : m.recipientCreate) == null ? void 0 : g.id
|
|
10244
10244
|
},
|
|
10245
10245
|
context: {
|
|
10246
10246
|
transactionOwnerId: this.transaction.transactionOwnerId
|
|
10247
10247
|
}
|
|
10248
10248
|
});
|
|
10249
10249
|
}
|
|
10250
|
-
this.recipientCallbacks.forEach((p) => p(this.transaction.recipient));
|
|
10251
10250
|
}
|
|
10252
10251
|
async initializeDefaultWorkflowState(t) {
|
|
10253
10252
|
const e = () => {
|
|
@@ -10328,12 +10327,6 @@ class lo {
|
|
|
10328
10327
|
addValidationCallback(t) {
|
|
10329
10328
|
this.validationCallbacks.push(t), t(this.validationErrors);
|
|
10330
10329
|
}
|
|
10331
|
-
addRecipientCallback(t) {
|
|
10332
|
-
this.recipientCallbacks.push(t), t(this.transaction.recipient);
|
|
10333
|
-
}
|
|
10334
|
-
removeRecipientCallback(t) {
|
|
10335
|
-
this.recipientCallbacks = this.recipientCallbacks.filter((e) => e !== t);
|
|
10336
|
-
}
|
|
10337
10330
|
getLayouts() {
|
|
10338
10331
|
return this.layouts;
|
|
10339
10332
|
}
|
|
@@ -10742,7 +10735,7 @@ class lo {
|
|
|
10742
10735
|
const E = (S = this.getWorkflowExperience().getStepById(g.stepName)) == null ? void 0 : S.frameService;
|
|
10743
10736
|
E == null || E.setTargetElements(a.map((B) => B.id));
|
|
10744
10737
|
}
|
|
10745
|
-
const
|
|
10738
|
+
const f = u.map((E) => new Et(E.id)), p = new Va(this.constructSerializableWorkflow()), C = [...m, ...f, p];
|
|
10746
10739
|
C.length > 0 && this.commandContext.apply(new $(C), !0), await this.ensureStepsAreLoaded(), this.onElementsChange();
|
|
10747
10740
|
const w = this.getInvalidModelVariants(), v = this.modelContainer;
|
|
10748
10741
|
if (v) {
|
|
@@ -11283,7 +11276,7 @@ class go extends rt {
|
|
|
11283
11276
|
return t;
|
|
11284
11277
|
}
|
|
11285
11278
|
}
|
|
11286
|
-
class
|
|
11279
|
+
class fo extends rt {
|
|
11287
11280
|
constructor(t, e, a) {
|
|
11288
11281
|
super(t, e, a);
|
|
11289
11282
|
}
|
|
@@ -11484,7 +11477,7 @@ class po extends rt {
|
|
|
11484
11477
|
await H.changeStrokeColor(this.step, t, e, this.manager);
|
|
11485
11478
|
}
|
|
11486
11479
|
}
|
|
11487
|
-
class
|
|
11480
|
+
class po extends rt {
|
|
11488
11481
|
constructor(t, e, a) {
|
|
11489
11482
|
super(t, e, a);
|
|
11490
11483
|
}
|
|
@@ -11578,11 +11571,11 @@ class oe {
|
|
|
11578
11571
|
case D.DigitalContent:
|
|
11579
11572
|
return new Co(t, e, t.getStepTags(e.stepName));
|
|
11580
11573
|
case D.Information:
|
|
11581
|
-
return new
|
|
11574
|
+
return new po(t, e, t.getStepTags(e.stepName));
|
|
11582
11575
|
case D.Question:
|
|
11583
11576
|
return new mo(t, e, t.getStepTags(e.stepName));
|
|
11584
11577
|
case D.Text:
|
|
11585
|
-
return new
|
|
11578
|
+
return new fo(t, e, t.getStepTags(e.stepName));
|
|
11586
11579
|
case D.Illustration:
|
|
11587
11580
|
return new co(t, e, t.getStepTags(e.stepName));
|
|
11588
11581
|
case D.Picture:
|
|
@@ -11822,7 +11815,7 @@ const vo = async (r) => {
|
|
|
11822
11815
|
Q.errors && console.log("Server Error:", Z.message);
|
|
11823
11816
|
}), null) : it ?? null;
|
|
11824
11817
|
})() || (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"));
|
|
11825
|
-
const u = r.getPreviewService(), h = (I = t == null ? void 0 : t.finalizeStepConfig) == null ? void 0 : I.lookAtAnimation, m = u && t.showModelOnFinishStep && !!h, g = l && oa(l, t, !0),
|
|
11818
|
+
const u = r.getPreviewService(), h = (I = t == null ? void 0 : t.finalizeStepConfig) == null ? void 0 : I.lookAtAnimation, m = u && t.showModelOnFinishStep && !!h, g = l && oa(l, t, !0), f = l && oa(l, t, !1), p = async (P) => {
|
|
11826
11819
|
const F = {};
|
|
11827
11820
|
let k = 0;
|
|
11828
11821
|
if (Object.keys(i).length > 0)
|
|
@@ -11831,12 +11824,12 @@ const vo = async (r) => {
|
|
|
11831
11824
|
for (let Z = 0; Z < it.selections.length; ++Z) {
|
|
11832
11825
|
const W = it.selections[Z];
|
|
11833
11826
|
if (R && (!P || R.option && (R.option.variants || []).length > 1 && !R.data.hideSelectionInCart && !R.data.hideSelectionsInCart)) {
|
|
11834
|
-
const
|
|
11835
|
-
F[
|
|
11827
|
+
const pt = R.stepTitle;
|
|
11828
|
+
F[pt] ? F[pt].push({
|
|
11836
11829
|
id: W.id || "",
|
|
11837
11830
|
name: W.name,
|
|
11838
11831
|
priceModifier: W.priceModifier
|
|
11839
|
-
}) : F[
|
|
11832
|
+
}) : F[pt] = [
|
|
11840
11833
|
{
|
|
11841
11834
|
id: W.id || "",
|
|
11842
11835
|
name: W.name,
|
|
@@ -11848,9 +11841,9 @@ const vo = async (r) => {
|
|
|
11848
11841
|
}
|
|
11849
11842
|
}
|
|
11850
11843
|
return [F, k];
|
|
11851
|
-
}, [C] = await
|
|
11844
|
+
}, [C] = await p(!0), w = Object.fromEntries(
|
|
11852
11845
|
Object.keys(C).map((P) => [P, C[P].map((F) => F.id)])
|
|
11853
|
-
), [v] = await
|
|
11846
|
+
), [v] = await p(!1), S = Object.fromEntries(
|
|
11854
11847
|
Object.keys(v).map((P) => [
|
|
11855
11848
|
P,
|
|
11856
11849
|
v[P].map((F) => F.id)
|
|
@@ -11879,9 +11872,9 @@ const vo = async (r) => {
|
|
|
11879
11872
|
useThreeDimPreview: !!m,
|
|
11880
11873
|
previewImage: E
|
|
11881
11874
|
};
|
|
11882
|
-
if (
|
|
11875
|
+
if (f) {
|
|
11883
11876
|
const F = [];
|
|
11884
|
-
for (const [k, Q] of Object.entries(
|
|
11877
|
+
for (const [k, Q] of Object.entries(f))
|
|
11885
11878
|
F.push({ key: k, value: Q });
|
|
11886
11879
|
P.metadata = F;
|
|
11887
11880
|
}
|
|
@@ -11897,7 +11890,7 @@ const vo = async (r) => {
|
|
|
11897
11890
|
cartMetadata: g
|
|
11898
11891
|
};
|
|
11899
11892
|
}, bo = async (r, t, e, a, n, i, s, o, l, c, d) => {
|
|
11900
|
-
var
|
|
11893
|
+
var p, C;
|
|
11901
11894
|
l("workflow.steps.finish.finalize.buildingLayouts");
|
|
11902
11895
|
const { designDetails: A, cartSelectionsWithPrices: u, cartMetadata: h } = await _n(
|
|
11903
11896
|
r,
|
|
@@ -11911,13 +11904,13 @@ const vo = async (r) => {
|
|
|
11911
11904
|
d
|
|
11912
11905
|
);
|
|
11913
11906
|
l("workflow.steps.finish.finalize.creatingDesign");
|
|
11914
|
-
const m = await vo(A), g = (
|
|
11907
|
+
const m = await vo(A), g = (p = m == null ? void 0 : m.transaction) == null ? void 0 : p.previewImageLink;
|
|
11915
11908
|
if (!(m != null && m.transaction))
|
|
11916
11909
|
throw new Error("Failed to create design");
|
|
11917
11910
|
l("workflow.steps.finish.finalize.updatingTransaction");
|
|
11918
|
-
const
|
|
11911
|
+
const f = m.transaction;
|
|
11919
11912
|
return Kn(
|
|
11920
|
-
|
|
11913
|
+
f,
|
|
11921
11914
|
n,
|
|
11922
11915
|
t,
|
|
11923
11916
|
u,
|
|
@@ -12229,8 +12222,8 @@ class Mo {
|
|
|
12229
12222
|
DOMParser: ha(),
|
|
12230
12223
|
fetch
|
|
12231
12224
|
})).render();
|
|
12232
|
-
const
|
|
12233
|
-
return s.toDataURL(
|
|
12225
|
+
const p = await this.getCanvasObjectURLAsync(s);
|
|
12226
|
+
return s.toDataURL(p);
|
|
12234
12227
|
}
|
|
12235
12228
|
getStepById(t) {
|
|
12236
12229
|
const e = this.getWorkflowManager().getWorkflow().steps.find((i) => i.stepName === t);
|
|
@@ -12326,15 +12319,15 @@ class Mo {
|
|
|
12326
12319
|
A !== void 0 && (A.forEach((u) => d.add(JSON.stringify(u))), o.forEach((u) => {
|
|
12327
12320
|
const h = u.getRaw().globalPropertyAspectConfigurations;
|
|
12328
12321
|
h !== void 0 && h.forEach((m) => {
|
|
12329
|
-
const g = l(m),
|
|
12330
|
-
if (
|
|
12331
|
-
const
|
|
12332
|
-
if (!
|
|
12322
|
+
const g = l(m), f = d.has(JSON.stringify(m));
|
|
12323
|
+
if (f && (g == null ? void 0 : g.getType()) === "Option") {
|
|
12324
|
+
const p = u.getCurrentVariant();
|
|
12325
|
+
if (!p)
|
|
12333
12326
|
return;
|
|
12334
|
-
c.selectVariant(
|
|
12335
|
-
} else if (
|
|
12336
|
-
const
|
|
12337
|
-
c.setText(
|
|
12327
|
+
c.selectVariant(p), d.delete(JSON.stringify(m));
|
|
12328
|
+
} else if (f && (g == null ? void 0 : g.getType()) === "Text") {
|
|
12329
|
+
const p = u.getText();
|
|
12330
|
+
c.setText(p), d.delete(JSON.stringify(m));
|
|
12338
12331
|
}
|
|
12339
12332
|
});
|
|
12340
12333
|
}));
|
|
@@ -12492,7 +12485,7 @@ class Mo {
|
|
|
12492
12485
|
), this.checkForPriceBreakChanges();
|
|
12493
12486
|
const e = this.getWorkflowManager().getTransaction();
|
|
12494
12487
|
await this.graphQlClient().mutate({
|
|
12495
|
-
mutation:
|
|
12488
|
+
mutation: fi,
|
|
12496
12489
|
variables: {
|
|
12497
12490
|
id: e.id,
|
|
12498
12491
|
quantity: t
|
|
@@ -12530,7 +12523,7 @@ const To = [
|
|
|
12530
12523
|
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);
|
|
12531
12524
|
o.searchParams.append("video", Ma(JSON.stringify([{ href: i }]))), o.pathname = o.pathname + (o.pathname.slice(-1) === "/" ? "" : "/");
|
|
12532
12525
|
const l = o.toString(), d = `data:image/svg+xml;base64,${Ma(await rn(l, { type: "svg" }))}`, A = (h) => {
|
|
12533
|
-
const m = r.find((
|
|
12526
|
+
const m = r.find((f) => f.panelId === h.panelId);
|
|
12534
12527
|
if (!m)
|
|
12535
12528
|
throw new q(h);
|
|
12536
12529
|
const g = N();
|
|
@@ -12560,7 +12553,7 @@ const To = [
|
|
|
12560
12553
|
o && (t[a.stepName] = { selectedVariants: [o] });
|
|
12561
12554
|
const l = async (c) => {
|
|
12562
12555
|
var g;
|
|
12563
|
-
const d = await Rn(c, (g = o == null ? void 0 : o.asset) == null ? void 0 : g.fileLink), A = await Me(d), u = N(), h = r.find((
|
|
12556
|
+
const d = await Rn(c, (g = o == null ? void 0 : o.asset) == null ? void 0 : g.fileLink), A = await Me(d), u = N(), h = r.find((f) => f.panelId === c.panelId);
|
|
12564
12557
|
if (!h)
|
|
12565
12558
|
throw new q(c);
|
|
12566
12559
|
const m = Sa(
|
|
@@ -12643,7 +12636,7 @@ const To = [
|
|
|
12643
12636
|
B.classList.add(Q), g[Q] = { browserValue: F };
|
|
12644
12637
|
}
|
|
12645
12638
|
});
|
|
12646
|
-
const
|
|
12639
|
+
const p = Bt().serializeToString(m), C = n.colors;
|
|
12647
12640
|
if (C) {
|
|
12648
12641
|
for (const [B, I] of Object.entries(g))
|
|
12649
12642
|
for (const P of Object.keys(C))
|
|
@@ -12661,7 +12654,7 @@ const To = [
|
|
|
12661
12654
|
{
|
|
12662
12655
|
colors: g,
|
|
12663
12656
|
id: P,
|
|
12664
|
-
svg:
|
|
12657
|
+
svg: p,
|
|
12665
12658
|
type: T.Illustration,
|
|
12666
12659
|
y: B.top,
|
|
12667
12660
|
x: B.left,
|
|
@@ -12762,7 +12755,7 @@ const To = [
|
|
|
12762
12755
|
return console.error(`No variant with ID: ${n.colorVariantId}`), [];
|
|
12763
12756
|
t[a.stepName] = { selectedVariants: [s] };
|
|
12764
12757
|
const o = (d) => {
|
|
12765
|
-
const A = r.find((
|
|
12758
|
+
const A = r.find((f) => f.panelId === d.panelId);
|
|
12766
12759
|
if (!A)
|
|
12767
12760
|
throw new q(d);
|
|
12768
12761
|
const u = `
|
|
@@ -12844,10 +12837,10 @@ const To = [
|
|
|
12844
12837
|
}
|
|
12845
12838
|
else {
|
|
12846
12839
|
const c = await at(i, !0), d = (A) => {
|
|
12847
|
-
const u = /<svg.*?<\/svg>/s, h = A.match(u) || [], m = (h == null ? void 0 : h.length) > 0 ? h[0] : "",
|
|
12848
|
-
if (!
|
|
12840
|
+
const u = /<svg.*?<\/svg>/s, h = A.match(u) || [], m = (h == null ? void 0 : h.length) > 0 ? h[0] : "", p = dt().parseFromString(m, "image/svg+xml").firstElementChild;
|
|
12841
|
+
if (!p)
|
|
12849
12842
|
throw new Pt("Failed to read SVG.");
|
|
12850
|
-
return ma(
|
|
12843
|
+
return ma(p), Bt().serializeToString(p);
|
|
12851
12844
|
};
|
|
12852
12845
|
l.forEach((A) => {
|
|
12853
12846
|
const u = r.find((m) => m.panelId === A.panelId);
|
|
@@ -12877,40 +12870,40 @@ const To = [
|
|
|
12877
12870
|
}
|
|
12878
12871
|
return a;
|
|
12879
12872
|
}, Vo = async (r, t, e, a) => {
|
|
12880
|
-
const n = [], i = e.data, s = 30, o = (
|
|
12873
|
+
const n = [], i = e.data, s = 30, o = (f) => f.vertical ? "center" : f.textAlign || "center", l = () => {
|
|
12881
12874
|
var w;
|
|
12882
|
-
const
|
|
12883
|
-
if (!
|
|
12875
|
+
const f = a.option;
|
|
12876
|
+
if (!f)
|
|
12884
12877
|
return;
|
|
12885
|
-
const
|
|
12886
|
-
if (!
|
|
12878
|
+
const p = ((w = f.variants) == null ? void 0 : w.find((v) => v.id === i.fontVariantId)) || te(f);
|
|
12879
|
+
if (!p || !p.asset)
|
|
12887
12880
|
return;
|
|
12888
|
-
t[a.stepName] = { selectedVariants: [
|
|
12889
|
-
const C =
|
|
12881
|
+
t[a.stepName] = { selectedVariants: [p] };
|
|
12882
|
+
const C = p.asset.fileLink;
|
|
12890
12883
|
if (C)
|
|
12891
12884
|
return C;
|
|
12892
12885
|
}, d = await (async () => {
|
|
12893
|
-
const
|
|
12894
|
-
if (!
|
|
12886
|
+
const f = l();
|
|
12887
|
+
if (!f)
|
|
12895
12888
|
return;
|
|
12896
|
-
const
|
|
12889
|
+
const p = await Qt(f);
|
|
12897
12890
|
return {
|
|
12898
|
-
assetUrl:
|
|
12899
|
-
name:
|
|
12891
|
+
assetUrl: f,
|
|
12892
|
+
name: p.names.fullName.en
|
|
12900
12893
|
};
|
|
12901
12894
|
})(), A = (a.data.replaceableText ? a.data.replaceableText.replace("{{}}", i.text) : i.text) || "", u = ye(A, {
|
|
12902
12895
|
vertical: a.data.vertical,
|
|
12903
12896
|
uppercase: a.data.uppercase
|
|
12904
|
-
}), h = async (
|
|
12905
|
-
const
|
|
12906
|
-
if (!
|
|
12897
|
+
}), h = async (f) => {
|
|
12898
|
+
const p = f.colorOption;
|
|
12899
|
+
if (!p)
|
|
12907
12900
|
return;
|
|
12908
|
-
const C = _.getDefaultVariant(
|
|
12901
|
+
const C = _.getDefaultVariant(p);
|
|
12909
12902
|
return C == null ? void 0 : C.color;
|
|
12910
12903
|
}, m = i.color || await h(a.data), g = a.data.regions;
|
|
12911
|
-
for (const
|
|
12912
|
-
const
|
|
12913
|
-
if (!
|
|
12904
|
+
for (const f of g) {
|
|
12905
|
+
const p = r.find((w) => w.panelId === f.panelId);
|
|
12906
|
+
if (!p)
|
|
12914
12907
|
continue;
|
|
12915
12908
|
const C = {
|
|
12916
12909
|
stepName: e.name,
|
|
@@ -12920,24 +12913,24 @@ const To = [
|
|
|
12920
12913
|
fill: i.color || m || "#000000",
|
|
12921
12914
|
fontData: d,
|
|
12922
12915
|
fontSize: a.data.size || s,
|
|
12923
|
-
height:
|
|
12924
|
-
layer:
|
|
12925
|
-
layerIndex:
|
|
12916
|
+
height: f.height,
|
|
12917
|
+
layer: f.layer,
|
|
12918
|
+
layerIndex: f.layerIndex,
|
|
12926
12919
|
paths: a.data.paths,
|
|
12927
|
-
rotation:
|
|
12920
|
+
rotation: f.rotation,
|
|
12928
12921
|
text: u,
|
|
12929
12922
|
type: T.Textbox,
|
|
12930
12923
|
vertical: a.data.vertical,
|
|
12931
12924
|
verticalAlign: a.data.verticalAlign || "middle",
|
|
12932
|
-
width:
|
|
12933
|
-
x:
|
|
12934
|
-
y:
|
|
12925
|
+
width: f.width,
|
|
12926
|
+
x: f.left,
|
|
12927
|
+
y: f.top
|
|
12935
12928
|
};
|
|
12936
12929
|
if (d) {
|
|
12937
12930
|
const [w, v] = he(
|
|
12938
12931
|
a.data.size || s,
|
|
12939
12932
|
d,
|
|
12940
|
-
|
|
12933
|
+
f,
|
|
12941
12934
|
[
|
|
12942
12935
|
ye(u, {
|
|
12943
12936
|
vertical: a.data.vertical,
|
|
@@ -12958,11 +12951,11 @@ const To = [
|
|
|
12958
12951
|
text: C.curved ? C.text : (v || []).join(`
|
|
12959
12952
|
`)
|
|
12960
12953
|
},
|
|
12961
|
-
|
|
12954
|
+
p
|
|
12962
12955
|
)
|
|
12963
12956
|
);
|
|
12964
12957
|
} else
|
|
12965
|
-
n.push(new G(C,
|
|
12958
|
+
n.push(new G(C, p));
|
|
12966
12959
|
}
|
|
12967
12960
|
return n;
|
|
12968
12961
|
}, zo = (r, t) => r.conditions ? r.conditions.every((e) => {
|
|
@@ -13420,7 +13413,7 @@ class Ko extends Ba {
|
|
|
13420
13413
|
}
|
|
13421
13414
|
async getImageWithColors() {
|
|
13422
13415
|
var t, e;
|
|
13423
|
-
return await this.loadImageData(), (t = this.imageData) != null && t.svg ? Aa(
|
|
13416
|
+
return await this.loadImageData(), (t = this.imageData) != null && t.svg ? Aa(fa(this.imageData.svg, this.imageData.colors ?? {}, !1)) : (e = this.imageData) == null ? void 0 : e.src;
|
|
13424
13417
|
}
|
|
13425
13418
|
/**
|
|
13426
13419
|
* Retrieves the original, unmodified image selection, if one exists.
|
|
@@ -14531,11 +14524,11 @@ class He {
|
|
|
14531
14524
|
return;
|
|
14532
14525
|
}
|
|
14533
14526
|
console.log("Setting default global variants."), this.globalPropertyHandleService.getHandles().then((m) => {
|
|
14534
|
-
const g = m.map((
|
|
14535
|
-
if (
|
|
14536
|
-
const
|
|
14527
|
+
const g = m.map((f) => {
|
|
14528
|
+
if (f.getType() === et.ColorOption || f.getType() === et.Option) {
|
|
14529
|
+
const p = f;
|
|
14537
14530
|
if (this.globalPropertyStateManager.getGlobalPropertyState())
|
|
14538
|
-
return
|
|
14531
|
+
return p.initDefaultVariant();
|
|
14539
14532
|
console.log("Attempted to set global default variant before state was initialized.");
|
|
14540
14533
|
}
|
|
14541
14534
|
});
|
|
@@ -14672,11 +14665,11 @@ class He {
|
|
|
14672
14665
|
this.getWorkflowExperiences(),
|
|
14673
14666
|
this.globalConfigurationPropertyId || "",
|
|
14674
14667
|
l
|
|
14675
|
-
), m = [...new Set(A.map((
|
|
14668
|
+
), m = [...new Set(A.map((f) => f.number))];
|
|
14676
14669
|
if (m.length > h)
|
|
14677
|
-
for (const
|
|
14678
|
-
const
|
|
14679
|
-
C && await
|
|
14670
|
+
for (const f of m) {
|
|
14671
|
+
const p = this.getGlobalPropertyStateManager(), C = u.find((w) => w.channelNumber === f);
|
|
14672
|
+
C && await p.setAspect(l, C.variant.id || "", void 0, C.channelNumber);
|
|
14680
14673
|
}
|
|
14681
14674
|
}
|
|
14682
14675
|
}
|
|
@@ -14874,7 +14867,7 @@ class He {
|
|
|
14874
14867
|
variables: {
|
|
14875
14868
|
id: this.id,
|
|
14876
14869
|
details: t,
|
|
14877
|
-
type: e ||
|
|
14870
|
+
type: e || fe.Owner
|
|
14878
14871
|
},
|
|
14879
14872
|
context: {
|
|
14880
14873
|
bundleOwnerId: this.ownerId
|
|
@@ -15335,7 +15328,7 @@ class ba {
|
|
|
15335
15328
|
return t.startsWith("[") ? JSON.stringify(JSON.parse(t)) : t;
|
|
15336
15329
|
}
|
|
15337
15330
|
}
|
|
15338
|
-
var
|
|
15331
|
+
var fl = /* @__PURE__ */ ((r) => (r.Transaction = "Transaction", r.Bundle = "Bundle", r.Product = "Product", r.Variant = "Variant", r.Option = "Option", r.LineItem = "LineItem", r.Asset = "Asset", r))(fl || {});
|
|
15339
15332
|
class Yc extends ba {
|
|
15340
15333
|
constructor(t) {
|
|
15341
15334
|
super(`"${t}"`);
|
|
@@ -15409,7 +15402,7 @@ const Ja = y`
|
|
|
15409
15402
|
}
|
|
15410
15403
|
}
|
|
15411
15404
|
}
|
|
15412
|
-
`,
|
|
15405
|
+
`, pl = y`
|
|
15413
15406
|
mutation CustomerCreate($details: CustomerDetailsInput!) {
|
|
15414
15407
|
customerCreate(details: $details) {
|
|
15415
15408
|
id
|
|
@@ -15645,7 +15638,7 @@ class _c {
|
|
|
15645
15638
|
var n, i;
|
|
15646
15639
|
const e = M.getMap("bundleOwnerIds");
|
|
15647
15640
|
if (e != null && e.has(t))
|
|
15648
|
-
return Promise.resolve({ success: !0, stakeholderType:
|
|
15641
|
+
return Promise.resolve({ success: !0, stakeholderType: fe.Owner });
|
|
15649
15642
|
const a = M.getMap("bundlePartnerIds") || /* @__PURE__ */ new Map();
|
|
15650
15643
|
if (a.has(t)) {
|
|
15651
15644
|
const s = a.get(t), l = (M.getMap("partnerCustomerIds") || /* @__PURE__ */ new Map()).get(s);
|
|
@@ -15694,11 +15687,11 @@ class _c {
|
|
|
15694
15687
|
return Promise.resolve({ success: !1, transactionReadOnly: !0 });
|
|
15695
15688
|
const s = M.getMap("transactionOwnerIds");
|
|
15696
15689
|
if (s != null && s.has(t))
|
|
15697
|
-
return Promise.resolve({ success: !0, stakeholderType:
|
|
15690
|
+
return Promise.resolve({ success: !0, stakeholderType: fe.Owner });
|
|
15698
15691
|
const o = M.getMap("transactionCustomerIds");
|
|
15699
15692
|
if (o != null && o.has(t)) {
|
|
15700
|
-
const
|
|
15701
|
-
if (
|
|
15693
|
+
const f = o.get(t);
|
|
15694
|
+
if (f && await this.authenticateCustomerId(f)) {
|
|
15702
15695
|
const C = ((h = (u = this.customer) == null ? void 0 : u.bundleStakeholders) == null ? void 0 : h.find(
|
|
15703
15696
|
(w) => {
|
|
15704
15697
|
var v, S;
|
|
@@ -15774,7 +15767,7 @@ class _c {
|
|
|
15774
15767
|
})).data.customer;
|
|
15775
15768
|
if (!n.id) {
|
|
15776
15769
|
const l = (s = (await e.mutate({
|
|
15777
|
-
mutation:
|
|
15770
|
+
mutation: pl,
|
|
15778
15771
|
errorPolicy: "all",
|
|
15779
15772
|
fetchPolicy: "no-cache",
|
|
15780
15773
|
variables: {
|
|
@@ -15905,13 +15898,13 @@ class _c {
|
|
|
15905
15898
|
* @returns A bundle to be used for grouping and operating on large amounts of workflow experiences.
|
|
15906
15899
|
*/
|
|
15907
15900
|
async getExistingBundle(t, e, a, n) {
|
|
15908
|
-
var
|
|
15909
|
-
const i = M.getMap("bundleOwnerIds"), s = i == null ? void 0 : i.get(t), l = ((
|
|
15901
|
+
var f, p, C, w, v, S, E, B, I, P, F;
|
|
15902
|
+
const i = M.getMap("bundleOwnerIds"), s = i == null ? void 0 : i.get(t), l = ((f = Object.entries(localStorage).find(([k, Q]) => k.startsWith("CognitoIdentityServiceProvider") && k.endsWith("idToken"))) == null ? void 0 : f[0]) || "", c = localStorage.getItem(l), d = {};
|
|
15910
15903
|
c && !Be(c) && (d.Authorization = `Bearer ${c}`);
|
|
15911
15904
|
const A = {
|
|
15912
15905
|
bundleOwnerId: s,
|
|
15913
15906
|
...d,
|
|
15914
|
-
...(
|
|
15907
|
+
...(p = n == null ? void 0 : n.graphql) == null ? void 0 : p.additionalHeaders
|
|
15915
15908
|
}, u = await b.getShadowGraphqlClient().query({
|
|
15916
15909
|
query: Qs(((w = (C = n == null ? void 0 : n.graphql) == null ? void 0 : C.productCollection) == null ? void 0 : w.eagerFetchProducts) || !1),
|
|
15917
15910
|
variables: {
|
|
@@ -15941,8 +15934,8 @@ class _c {
|
|
|
15941
15934
|
* @returns A bundle to be used for grouping and operating on large amounts of workflow experiences.
|
|
15942
15935
|
*/
|
|
15943
15936
|
async duplicateBundle(t, e, a, n) {
|
|
15944
|
-
var
|
|
15945
|
-
const i = (
|
|
15937
|
+
var f, p, C, w, v, S, E, B;
|
|
15938
|
+
const i = (f = M.getMap("bundleOwnerIds")) == null ? void 0 : f.get(t), o = ((p = Object.entries(localStorage).find(([I, P]) => I.startsWith("CognitoIdentityServiceProvider") && I.endsWith("idToken"))) == null ? void 0 : p[0]) || "", l = localStorage.getItem(o), c = {};
|
|
15946
15939
|
l && !Be(l) && (c.Authorization = `Bearer ${l}`);
|
|
15947
15940
|
const d = {
|
|
15948
15941
|
bundleOwnerId: i,
|
|
@@ -16103,7 +16096,7 @@ class _c {
|
|
|
16103
16096
|
), c = Pa(o, 10), d = Pa(l, 10), A = (await Promise.all([
|
|
16104
16097
|
...c.map(n),
|
|
16105
16098
|
...d.map(i)
|
|
16106
|
-
])).flat(), u = [...new Set(A.map((S) => S.workflowId))], h = await er(u, e), m = new Map(h.map((S) => [S.id, S])), g = M.getMap("transactionOwnerIds") || /* @__PURE__ */ new Map(),
|
|
16099
|
+
])).flat(), u = [...new Set(A.map((S) => S.workflowId))], h = await er(u, e), m = new Map(h.map((S) => [S.id, S])), g = M.getMap("transactionOwnerIds") || /* @__PURE__ */ new Map(), f = A.map(async (S) => {
|
|
16107
16100
|
var Z;
|
|
16108
16101
|
const { transaction: E, workflowId: B, readOnly: I, index: P } = S, F = m.get(B), k = t[P];
|
|
16109
16102
|
!g.get(E.id) && E.transactionOwnerId && g.set(E.id, E.transactionOwnerId);
|
|
@@ -16128,10 +16121,10 @@ class _c {
|
|
|
16128
16121
|
};
|
|
16129
16122
|
if (k.type === "transaction" && E.workflowState) {
|
|
16130
16123
|
const W = JSON.parse(E.workflowState);
|
|
16131
|
-
R.layouts = Object.values(W.layouts || {}).map((
|
|
16124
|
+
R.layouts = Object.values(W.layouts || {}).map((pt) => pt.layout), await La(W), R.reloadedState = W;
|
|
16132
16125
|
} else if (!I && k.workflowState) {
|
|
16133
16126
|
const W = JSON.parse(k.workflowState);
|
|
16134
|
-
R.layouts = Object.values(W.layouts || {}).map((
|
|
16127
|
+
R.layouts = Object.values(W.layouts || {}).map((pt) => pt.layout), await La(W), R.reloadedState = W;
|
|
16135
16128
|
} else
|
|
16136
16129
|
R.layouts = Il(
|
|
16137
16130
|
R.transaction,
|
|
@@ -16140,9 +16133,9 @@ class _c {
|
|
|
16140
16133
|
return R.renderableContextService = new Wo(
|
|
16141
16134
|
R.layouts
|
|
16142
16135
|
), R.delayWorkflowStateSync = !0, { experienceOptions: R, index: P, options: k };
|
|
16143
|
-
}),
|
|
16136
|
+
}), p = await Promise.all(f);
|
|
16144
16137
|
M.setMap("transactionOwnerIds", g);
|
|
16145
|
-
const w =
|
|
16138
|
+
const w = p.sort((S, E) => S.index - E.index).map(async (S) => {
|
|
16146
16139
|
const { experienceOptions: E, options: B } = S, I = new Mo(this, E);
|
|
16147
16140
|
return await I.getWorkflowManager().getInitializationPromise(), B.type !== "transaction" && this.customer && await I.attachCustomerDetails({ email: this.customer.emailAddress }), I;
|
|
16148
16141
|
}), v = await Promise.all(w);
|
|
@@ -16231,7 +16224,7 @@ const Dl = async (r, t) => (await b.getShadowGraphqlClient().query({
|
|
|
16231
16224
|
}
|
|
16232
16225
|
})).data.currentIntegration, Xc = async (r) => {
|
|
16233
16226
|
const e = await b.getShadowGraphqlClient().query({
|
|
16234
|
-
query:
|
|
16227
|
+
query: pi,
|
|
16235
16228
|
errorPolicy: "all",
|
|
16236
16229
|
fetchPolicy: "network-only",
|
|
16237
16230
|
variables: {
|
|
@@ -16358,7 +16351,7 @@ class Fl {
|
|
|
16358
16351
|
getImageSrc() {
|
|
16359
16352
|
if (this.imageData) {
|
|
16360
16353
|
if (this.imageData.svg) {
|
|
16361
|
-
const t =
|
|
16354
|
+
const t = fa(this.imageData.svg, this.imageData.colors || {}, !1);
|
|
16362
16355
|
return Aa(t);
|
|
16363
16356
|
}
|
|
16364
16357
|
return this.imageData.src;
|
|
@@ -17272,7 +17265,7 @@ const md = async (r) => {
|
|
|
17272
17265
|
ids: r
|
|
17273
17266
|
}
|
|
17274
17267
|
})).data) == null ? void 0 : e.addressValidationJobs;
|
|
17275
|
-
},
|
|
17268
|
+
}, fd = async (r) => {
|
|
17276
17269
|
var e, a;
|
|
17277
17270
|
return (e = r.getWorkflowManager().getTransaction().recipient) != null && e.id ? (a = (await b.getShadowGraphqlClient().mutate({
|
|
17278
17271
|
mutation: Hl,
|
|
@@ -17282,7 +17275,7 @@ const md = async (r) => {
|
|
|
17282
17275
|
id: r.getWorkflowManager().getTransaction().recipient.id
|
|
17283
17276
|
}
|
|
17284
17277
|
})).data) == null ? void 0 : a.recipientValidate : void 0;
|
|
17285
|
-
},
|
|
17278
|
+
}, pd = async (r) => {
|
|
17286
17279
|
const t = r.map((a) => {
|
|
17287
17280
|
var n;
|
|
17288
17281
|
return (n = a.getWorkflowManager().getTransaction().recipient) == null ? void 0 : n.id;
|
|
@@ -17312,7 +17305,7 @@ export {
|
|
|
17312
17305
|
Gc as BringForwardCommand,
|
|
17313
17306
|
zc as BringToBackCommand,
|
|
17314
17307
|
Vc as BringToFrontCommand,
|
|
17315
|
-
|
|
17308
|
+
pr as BundleDesignCreationCartAddMode,
|
|
17316
17309
|
O as CanvasCommand,
|
|
17317
17310
|
le as CollectionProduct,
|
|
17318
17311
|
qa as ColorOptionGlobalPropertyHandle,
|
|
@@ -17338,7 +17331,7 @@ export {
|
|
|
17338
17331
|
$ as GroupCommand,
|
|
17339
17332
|
co as IllustrationStepHandle,
|
|
17340
17333
|
Te as InformationMessageType,
|
|
17341
|
-
|
|
17334
|
+
po as InformationStepHandle,
|
|
17342
17335
|
Ya as IntegrationProduct,
|
|
17343
17336
|
wr as IntegrationType,
|
|
17344
17337
|
Rc as LayoutElementFactory,
|
|
@@ -17352,9 +17345,9 @@ export {
|
|
|
17352
17345
|
wo as ModuleStepHandle,
|
|
17353
17346
|
Oc as MoveCommand,
|
|
17354
17347
|
tr as ObjectInput,
|
|
17355
|
-
|
|
17348
|
+
fl as ObjectInputType,
|
|
17356
17349
|
Xn as OptionGlobalPropertyHandle,
|
|
17357
|
-
|
|
17350
|
+
pe as OptionNotFoundError,
|
|
17358
17351
|
Pt as ParseError,
|
|
17359
17352
|
ho as PictureStepHandle,
|
|
17360
17353
|
yr as ProductCameraRig,
|
|
@@ -17373,15 +17366,15 @@ export {
|
|
|
17373
17366
|
go as ShapeStepHandle,
|
|
17374
17367
|
Cr as ShareActionType,
|
|
17375
17368
|
_c as SpiffCommerceClient,
|
|
17376
|
-
|
|
17377
|
-
|
|
17369
|
+
fe as StakeholderType,
|
|
17370
|
+
fr as StepAspectType,
|
|
17378
17371
|
rt as StepHandle,
|
|
17379
17372
|
D as StepType,
|
|
17380
17373
|
Mt as TextAlgorithm,
|
|
17381
17374
|
os as TextChangeCommand,
|
|
17382
17375
|
_o as TextGlobalPropertyHandle,
|
|
17383
17376
|
Yc as TextInput,
|
|
17384
|
-
|
|
17377
|
+
fo as TextStepHandle,
|
|
17385
17378
|
ol as Transform,
|
|
17386
17379
|
sl as TransformCollection,
|
|
17387
17380
|
z as UnhandledBehaviorError,
|
|
@@ -17449,7 +17442,7 @@ export {
|
|
|
17449
17442
|
rl as metafieldManager,
|
|
17450
17443
|
Tc as mmPerPixel,
|
|
17451
17444
|
Gn as modelStepService,
|
|
17452
|
-
|
|
17445
|
+
fa as modifySVGColors,
|
|
17453
17446
|
Wn as moduleStepService,
|
|
17454
17447
|
nd as nameBundle,
|
|
17455
17448
|
rd as nameTransaction,
|
|
@@ -17461,7 +17454,7 @@ export {
|
|
|
17461
17454
|
yc as pmsToRgb,
|
|
17462
17455
|
Hn as questionStepService,
|
|
17463
17456
|
Cc as registerFetchImplementation,
|
|
17464
|
-
|
|
17457
|
+
pc as registerWindowImplementation,
|
|
17465
17458
|
La as rehydrateSerializedLayout,
|
|
17466
17459
|
Gr as rgbToPms,
|
|
17467
17460
|
se as rotateAroundPoint,
|
|
@@ -17477,8 +17470,8 @@ export {
|
|
|
17477
17470
|
Aa as svgToDataUrl,
|
|
17478
17471
|
H as textStepService,
|
|
17479
17472
|
ws as toast,
|
|
17480
|
-
|
|
17481
|
-
|
|
17473
|
+
fd as validateWorkflowExperienceRecipient,
|
|
17474
|
+
pd as validateWorkflowExperienceRecipients,
|
|
17482
17475
|
Bt as xmlSerializer
|
|
17483
17476
|
};
|
|
17484
17477
|
//# sourceMappingURL=index.mjs.map
|