@builder.io/sdk-react-nextjs 0.14.16 → 0.14.19
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/lib/browser/USE_CLIENT_BUNDLE-a0af5379.cjs +21 -0
- package/lib/{node/USE_CLIENT_BUNDLE-f8067984.js → browser/USE_CLIENT_BUNDLE-b63f19ab.js} +251 -247
- package/lib/{edge/USE_SERVER_BUNDLE-0f9fd6f2.js → browser/USE_SERVER_BUNDLE-60e66f1c.js} +1 -1
- package/lib/{edge/USE_SERVER_BUNDLE-b3d619da.cjs → browser/USE_SERVER_BUNDLE-c0e4ee23.cjs} +1 -1
- package/lib/browser/bundle-9732e1d3.cjs +169 -0
- package/lib/browser/{bundle-5c0a9d7a.js → bundle-edd2e835.js} +591 -581
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +4 -4
- package/lib/edge/USE_CLIENT_BUNDLE-0a51f6af.cjs +21 -0
- package/lib/{browser/USE_CLIENT_BUNDLE-30c6c6c1.js → edge/USE_CLIENT_BUNDLE-8bf08d5b.js} +251 -247
- package/lib/{node/USE_SERVER_BUNDLE-e1e73ba6.cjs → edge/USE_SERVER_BUNDLE-7acc7eaf.cjs} +1 -1
- package/lib/{node/USE_SERVER_BUNDLE-4b52a0c0.js → edge/USE_SERVER_BUNDLE-90c6ce15.js} +1 -1
- package/lib/edge/bundle-af88805d.cjs +189 -0
- package/lib/edge/{bundle-b24e7c9b.js → bundle-e86f8464.js} +998 -988
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +4 -4
- package/lib/node/USE_CLIENT_BUNDLE-8a32af0d.cjs +21 -0
- package/lib/{edge/USE_CLIENT_BUNDLE-5b0b3e9b.js → node/USE_CLIENT_BUNDLE-e4c15aa7.js} +251 -247
- package/lib/{browser/USE_SERVER_BUNDLE-685e6983.js → node/USE_SERVER_BUNDLE-4fd50e3b.js} +1 -1
- package/lib/{browser/USE_SERVER_BUNDLE-ce31724e.cjs → node/USE_SERVER_BUNDLE-d6552b77.cjs} +1 -1
- package/lib/node/{bundle-8d3cab60.js → bundle-1280dc1a.js} +257 -245
- package/lib/node/{bundle-0fc157c8.cjs → bundle-23855e1a.cjs} +18 -18
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +4 -4
- package/package.json +1 -1
- package/types/cjs/blocks/columns/columns.types.d.ts +1 -1
- package/types/cjs/blocks/columns/helpers.d.ts +1 -0
- package/types/cjs/blocks/tabs/component-info.d.ts +2 -0
- package/types/cjs/blocks/tabs/index.d.ts +1 -0
- package/types/cjs/blocks/tabs/tabs.d.ts +4 -0
- package/types/cjs/blocks/tabs/tabs.types.d.ts +13 -0
- package/types/cjs/blocks/text/text.types.d.ts +2 -1
- package/types/cjs/components/block/block.helpers.d.ts +4 -2
- package/types/cjs/components/content/components/styles.helpers.d.ts +1 -0
- package/types/cjs/components/dynamic-div.d.ts +15 -0
- package/types/cjs/constants/sdk-version.d.ts +1 -1
- package/types/cjs/types/targets.d.ts +1 -1
- package/types/esm/blocks/columns/columns.types.d.ts +1 -1
- package/types/esm/blocks/columns/helpers.d.ts +1 -0
- package/types/esm/blocks/tabs/component-info.d.ts +2 -0
- package/types/esm/blocks/tabs/index.d.ts +1 -0
- package/types/esm/blocks/tabs/tabs.d.ts +4 -0
- package/types/esm/blocks/tabs/tabs.types.d.ts +13 -0
- package/types/esm/blocks/text/text.types.d.ts +2 -1
- package/types/esm/components/block/block.helpers.d.ts +4 -2
- package/types/esm/components/content/components/styles.helpers.d.ts +1 -0
- package/types/esm/components/dynamic-div.d.ts +15 -0
- package/types/esm/constants/sdk-version.d.ts +1 -1
- package/types/esm/types/targets.d.ts +1 -1
- package/lib/browser/USE_CLIENT_BUNDLE-026b8026.cjs +0 -21
- package/lib/browser/bundle-9744b895.cjs +0 -169
- package/lib/edge/USE_CLIENT_BUNDLE-9b110136.cjs +0 -21
- package/lib/edge/bundle-f1760904.cjs +0 -189
- package/lib/node/USE_CLIENT_BUNDLE-f9ebade4.cjs +0 -21
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { jsx as l, Fragment as
|
|
1
|
+
import { jsx as l, Fragment as C, jsxs as R } from "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { LRUCache as Oe } from "lru-cache";
|
|
4
|
+
import { I as Fe, B as Le, a as Ue, D as De, C as _e, E as Me, b as je, V as He, c as Ke, F as ze, d as qe, S as Ye, e as Ge } from "./USE_CLIENT_BUNDLE-b63f19ab.js";
|
|
5
5
|
import "next/navigation";
|
|
6
|
-
const
|
|
7
|
-
switch (
|
|
6
|
+
const Je = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), ho = (e) => typeof e == "string" && Je.has(e.toLowerCase()), T = "rsc", M = () => {
|
|
7
|
+
switch (T) {
|
|
8
8
|
case "react":
|
|
9
9
|
case "reactNative":
|
|
10
10
|
case "rsc":
|
|
@@ -13,10 +13,11 @@ const Ye = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr",
|
|
|
13
13
|
case "vue":
|
|
14
14
|
case "solid":
|
|
15
15
|
case "qwik":
|
|
16
|
+
case "angular":
|
|
16
17
|
return "class";
|
|
17
18
|
}
|
|
18
19
|
};
|
|
19
|
-
function
|
|
20
|
+
function Qe(e) {
|
|
20
21
|
var t;
|
|
21
22
|
return {
|
|
22
23
|
...(t = e.component) == null ? void 0 : t.options,
|
|
@@ -27,36 +28,36 @@ function Ge(e) {
|
|
|
27
28
|
builderBlock: e
|
|
28
29
|
};
|
|
29
30
|
}
|
|
30
|
-
const A = "[Builder.io]: ",
|
|
31
|
+
const A = "[Builder.io]: ", w = {
|
|
31
32
|
log: (...e) => console.log(A, ...e),
|
|
32
33
|
error: (...e) => console.error(A, ...e),
|
|
33
34
|
warn: (...e) => console.warn(A, ...e),
|
|
34
35
|
debug: (...e) => console.debug(A, ...e)
|
|
35
36
|
};
|
|
36
|
-
function
|
|
37
|
+
function k() {
|
|
37
38
|
return typeof window < "u" && typeof document < "u";
|
|
38
39
|
}
|
|
39
|
-
const
|
|
40
|
+
const Xe = (e) => {
|
|
40
41
|
const t = {};
|
|
41
42
|
return e.forEach((n, o) => {
|
|
42
43
|
t[o] = n;
|
|
43
44
|
}), t;
|
|
44
|
-
},
|
|
45
|
-
function
|
|
46
|
-
return
|
|
45
|
+
}, de = (e) => e instanceof URLSearchParams ? Xe(e) : e, ue = (e) => typeof e == "string" ? e : e instanceof URLSearchParams ? e.toString() : new URLSearchParams(e).toString();
|
|
46
|
+
function Ze() {
|
|
47
|
+
return k() && window.self !== window.top;
|
|
47
48
|
}
|
|
48
|
-
function
|
|
49
|
-
return
|
|
50
|
-
|
|
49
|
+
function me(e) {
|
|
50
|
+
return Ze() && // accessing window.location.search is safe here because `isIframe()` is only `true` if we're in a browser.
|
|
51
|
+
ue(e || window.location.search).indexOf("builder.frameEditing=") !== -1;
|
|
51
52
|
}
|
|
52
|
-
const
|
|
53
|
-
if (
|
|
53
|
+
const et = () => {
|
|
54
|
+
if (k()) {
|
|
54
55
|
const e = new URL(location.href);
|
|
55
56
|
return e.pathname === "" && (e.pathname = "/"), e;
|
|
56
57
|
} else
|
|
57
58
|
return console.warn("Cannot get location for tracking in non-browser environment"), null;
|
|
58
|
-
},
|
|
59
|
-
const e =
|
|
59
|
+
}, tt = () => typeof navigator == "object" && navigator.userAgent || "", fe = () => {
|
|
60
|
+
const e = tt(), t = {
|
|
60
61
|
Android() {
|
|
61
62
|
return e.match(/Android/i);
|
|
62
63
|
},
|
|
@@ -73,15 +74,15 @@ const Xe = () => {
|
|
|
73
74
|
return e.match(/IEMobile/i) || e.match(/WPDesktop/i);
|
|
74
75
|
},
|
|
75
76
|
any() {
|
|
76
|
-
return t.Android() || t.BlackBerry() || t.iOS() || t.Opera() || t.Windows() ||
|
|
77
|
+
return t.Android() || t.BlackBerry() || t.iOS() || t.Opera() || t.Windows() || T === "reactNative";
|
|
77
78
|
}
|
|
78
|
-
}, n = e.match(/Tablet|iPad/i), o =
|
|
79
|
+
}, n = e.match(/Tablet|iPad/i), o = et();
|
|
79
80
|
return {
|
|
80
81
|
urlPath: o == null ? void 0 : o.pathname,
|
|
81
82
|
host: (o == null ? void 0 : o.host) || (o == null ? void 0 : o.hostname),
|
|
82
83
|
device: n ? "tablet" : t.any() ? "mobile" : "desktop"
|
|
83
84
|
};
|
|
84
|
-
},
|
|
85
|
+
}, nt = ({
|
|
85
86
|
builder: e,
|
|
86
87
|
context: t,
|
|
87
88
|
event: n,
|
|
@@ -93,14 +94,14 @@ const Xe = () => {
|
|
|
93
94
|
builder: e,
|
|
94
95
|
context: t,
|
|
95
96
|
event: n
|
|
96
|
-
}),
|
|
97
|
-
isEditing:
|
|
98
|
-
isBrowser:
|
|
99
|
-
isServer: !
|
|
100
|
-
getUserAttributes: () =>
|
|
101
|
-
}),
|
|
97
|
+
}), ot = () => ({
|
|
98
|
+
isEditing: me(),
|
|
99
|
+
isBrowser: k(),
|
|
100
|
+
isServer: !k(),
|
|
101
|
+
getUserAttributes: () => fe()
|
|
102
|
+
}), it = (e, {
|
|
102
103
|
isExpression: t = !0
|
|
103
|
-
}) => /* we disable this for cases where we definitely don't want a return */ t && !(e.includes(";") || e.includes(" return ") || e.trim().startsWith("return ")) ? `return (${e});` : e,
|
|
104
|
+
}) => /* we disable this for cases where we definitely don't want a return */ t && !(e.includes(";") || e.includes(" return ") || e.trim().startsWith("return ")) ? `return (${e});` : e, J = ({
|
|
104
105
|
code: e,
|
|
105
106
|
builder: t,
|
|
106
107
|
context: n,
|
|
@@ -109,11 +110,11 @@ const Xe = () => {
|
|
|
109
110
|
rootSetState: r,
|
|
110
111
|
rootState: a
|
|
111
112
|
}) => {
|
|
112
|
-
const s =
|
|
113
|
+
const s = nt({
|
|
113
114
|
builder: t,
|
|
114
115
|
context: n,
|
|
115
116
|
event: o,
|
|
116
|
-
state:
|
|
117
|
+
state: he({
|
|
117
118
|
rootState: a,
|
|
118
119
|
localState: i,
|
|
119
120
|
rootSetState: r
|
|
@@ -121,7 +122,7 @@ const Xe = () => {
|
|
|
121
122
|
});
|
|
122
123
|
return new Function(...s.map(([c]) => c), e)(...s.map(([, c]) => c));
|
|
123
124
|
};
|
|
124
|
-
function
|
|
125
|
+
function he({
|
|
125
126
|
rootState: e,
|
|
126
127
|
localState: t,
|
|
127
128
|
rootSetState: n
|
|
@@ -131,7 +132,7 @@ function me({
|
|
|
131
132
|
if (t && i in t)
|
|
132
133
|
return t[i];
|
|
133
134
|
const r = o[i];
|
|
134
|
-
return typeof r == "object" && r !== null ?
|
|
135
|
+
return typeof r == "object" && r !== null ? he({
|
|
135
136
|
rootState: r,
|
|
136
137
|
localState: void 0,
|
|
137
138
|
rootSetState: n ? (a) => {
|
|
@@ -147,17 +148,17 @@ function me({
|
|
|
147
148
|
});
|
|
148
149
|
}
|
|
149
150
|
const I = (e) => e != null;
|
|
150
|
-
function
|
|
151
|
+
function rt() {
|
|
151
152
|
var e;
|
|
152
153
|
return typeof process < "u" && I((e = process == null ? void 0 : process.versions) == null ? void 0 : e.node);
|
|
153
154
|
}
|
|
154
|
-
const
|
|
155
|
+
const at = () => {
|
|
155
156
|
var o;
|
|
156
|
-
if (!
|
|
157
|
+
if (!rt())
|
|
157
158
|
return !1;
|
|
158
159
|
const e = process.arch === "arm64", t = process.version.startsWith("v20"), n = (o = process.env.NODE_OPTIONS) == null ? void 0 : o.includes("--no-node-snapshot");
|
|
159
|
-
return e && t && !n ? (
|
|
160
|
-
},
|
|
160
|
+
return e && t && !n ? (w.log("Skipping usage of `isolated-vm` to avoid crashes in Node v20 on an arm64 machine.\n If you would like to use the `isolated-vm` package on this machine, please provide the `NODE_OPTIONS=--no-node-snapshot` config to your Node process.\n See https://github.com/BuilderIO/builder/blob/main/packages/sdks/README.md#node-v20--m1-macs-apple-silicon-support for more information.\n "), !0) : !1;
|
|
161
|
+
}, st = (e) => (k() || at(), J(e)), j = class P {
|
|
161
162
|
static getCacheKey(t) {
|
|
162
163
|
return JSON.stringify({
|
|
163
164
|
...t,
|
|
@@ -188,15 +189,13 @@ function H({
|
|
|
188
189
|
isExpression: a = !0,
|
|
189
190
|
enableCache: s
|
|
190
191
|
}) {
|
|
191
|
-
if (e === "")
|
|
192
|
-
C.warn("Skipping evaluation of empty code block.");
|
|
192
|
+
if (e === "")
|
|
193
193
|
return;
|
|
194
|
-
}
|
|
195
194
|
const c = {
|
|
196
|
-
code:
|
|
195
|
+
code: it(e, {
|
|
197
196
|
isExpression: a
|
|
198
197
|
}),
|
|
199
|
-
builder:
|
|
198
|
+
builder: ot(),
|
|
200
199
|
context: t,
|
|
201
200
|
event: r,
|
|
202
201
|
rootSetState: i,
|
|
@@ -204,31 +203,31 @@ function H({
|
|
|
204
203
|
localState: n
|
|
205
204
|
};
|
|
206
205
|
if (s) {
|
|
207
|
-
const
|
|
208
|
-
if (
|
|
209
|
-
return
|
|
206
|
+
const u = V.getCacheKey(c), h = V.getCachedValue(u);
|
|
207
|
+
if (h)
|
|
208
|
+
return h.value;
|
|
210
209
|
}
|
|
211
210
|
try {
|
|
212
|
-
const
|
|
211
|
+
const u = st(c);
|
|
213
212
|
if (s) {
|
|
214
|
-
const
|
|
215
|
-
V.setCachedValue(
|
|
213
|
+
const h = V.getCacheKey(c);
|
|
214
|
+
V.setCachedValue(h, u);
|
|
216
215
|
}
|
|
217
|
-
return
|
|
218
|
-
} catch (
|
|
219
|
-
|
|
216
|
+
return u;
|
|
217
|
+
} catch (u) {
|
|
218
|
+
w.error("Failed code evaluation: " + u.message, {
|
|
220
219
|
code: e
|
|
221
220
|
});
|
|
222
221
|
return;
|
|
223
222
|
}
|
|
224
223
|
}
|
|
225
|
-
const
|
|
224
|
+
const O = (e) => JSON.parse(JSON.stringify(e)), ct = (e, t, n) => {
|
|
226
225
|
if (Object(e) !== e)
|
|
227
226
|
return e;
|
|
228
227
|
const o = Array.isArray(t) ? t : t.toString().match(/[^.[\]]+/g);
|
|
229
228
|
return o.slice(0, -1).reduce((i, r, a) => Object(i[r]) === i[r] ? i[r] : i[r] = Math.abs(Number(o[a + 1])) >> 0 === +o[a + 1] ? [] : {}, e)[o[o.length - 1]] = n, e;
|
|
230
229
|
};
|
|
231
|
-
const
|
|
230
|
+
const lt = ({
|
|
232
231
|
block: e,
|
|
233
232
|
context: t,
|
|
234
233
|
localState: n,
|
|
@@ -237,7 +236,7 @@ const st = ({
|
|
|
237
236
|
}) => {
|
|
238
237
|
if (!e.bindings)
|
|
239
238
|
return e;
|
|
240
|
-
const r =
|
|
239
|
+
const r = O(e), a = {
|
|
241
240
|
...r,
|
|
242
241
|
properties: {
|
|
243
242
|
...r.properties
|
|
@@ -247,7 +246,7 @@ const st = ({
|
|
|
247
246
|
}
|
|
248
247
|
};
|
|
249
248
|
for (const s in e.bindings) {
|
|
250
|
-
const c = e.bindings[s],
|
|
249
|
+
const c = e.bindings[s], u = H({
|
|
251
250
|
code: c,
|
|
252
251
|
localState: n,
|
|
253
252
|
rootState: o,
|
|
@@ -255,11 +254,11 @@ const st = ({
|
|
|
255
254
|
context: t,
|
|
256
255
|
enableCache: !0
|
|
257
256
|
});
|
|
258
|
-
|
|
257
|
+
ct(a, s, u);
|
|
259
258
|
}
|
|
260
259
|
return a;
|
|
261
260
|
};
|
|
262
|
-
function
|
|
261
|
+
function N({
|
|
263
262
|
block: e,
|
|
264
263
|
context: t,
|
|
265
264
|
shouldEvaluateBindings: n,
|
|
@@ -268,7 +267,7 @@ function $({
|
|
|
268
267
|
rootSetState: r
|
|
269
268
|
}) {
|
|
270
269
|
const a = e;
|
|
271
|
-
return n ?
|
|
270
|
+
return n ? lt({
|
|
272
271
|
block: a,
|
|
273
272
|
localState: o,
|
|
274
273
|
rootState: i,
|
|
@@ -276,41 +275,42 @@ function $({
|
|
|
276
275
|
context: t
|
|
277
276
|
}) : a;
|
|
278
277
|
}
|
|
279
|
-
const
|
|
278
|
+
const dt = (e) => e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase(), pe = (e) => Object.entries(e).map(([n, o]) => {
|
|
280
279
|
if (typeof o == "string")
|
|
281
|
-
return `${
|
|
282
|
-
}).filter(I),
|
|
280
|
+
return `${dt(n)}: ${o};`;
|
|
281
|
+
}).filter(I), ut = (e) => pe(e).join(`
|
|
283
282
|
`), B = ({
|
|
284
283
|
mediaQuery: e,
|
|
285
284
|
className: t,
|
|
286
285
|
styles: n
|
|
287
286
|
}) => {
|
|
288
287
|
const o = `.${t} {
|
|
289
|
-
${
|
|
288
|
+
${ut(n)}
|
|
290
289
|
}`;
|
|
291
290
|
return e ? `${e} {
|
|
292
291
|
${o}
|
|
293
292
|
}` : o;
|
|
294
293
|
};
|
|
295
|
-
function
|
|
294
|
+
function mt({
|
|
296
295
|
style: e
|
|
297
296
|
}) {
|
|
298
297
|
return e;
|
|
299
298
|
}
|
|
300
|
-
const
|
|
299
|
+
const ft = ({
|
|
301
300
|
block: e,
|
|
302
301
|
context: t
|
|
303
|
-
}) =>
|
|
302
|
+
}) => ge(mt({
|
|
304
303
|
style: e.style || {},
|
|
305
304
|
context: t,
|
|
306
305
|
block: e
|
|
307
306
|
}));
|
|
308
|
-
function
|
|
309
|
-
switch (
|
|
307
|
+
function ge(e) {
|
|
308
|
+
switch (T) {
|
|
310
309
|
case "svelte":
|
|
311
310
|
case "vue":
|
|
312
311
|
case "solid":
|
|
313
|
-
|
|
312
|
+
case "angular":
|
|
313
|
+
return pe(e).join(" ");
|
|
314
314
|
case "qwik":
|
|
315
315
|
case "reactNative":
|
|
316
316
|
case "react":
|
|
@@ -318,13 +318,13 @@ function he(e) {
|
|
|
318
318
|
return e;
|
|
319
319
|
}
|
|
320
320
|
}
|
|
321
|
-
const
|
|
321
|
+
const ht = ({
|
|
322
322
|
block: e,
|
|
323
323
|
context: t,
|
|
324
324
|
registeredComponents: n
|
|
325
325
|
}) => {
|
|
326
326
|
var r;
|
|
327
|
-
const o = (r =
|
|
327
|
+
const o = (r = N({
|
|
328
328
|
block: e,
|
|
329
329
|
localState: t.localState,
|
|
330
330
|
rootState: t.rootState,
|
|
@@ -340,7 +340,7 @@ const mt = ({
|
|
|
340
340
|
console.warn(`
|
|
341
341
|
Could not find a registered component named "${o}".
|
|
342
342
|
If you registered it, is the file that registered it imported by the file that needs to render it?`);
|
|
343
|
-
},
|
|
343
|
+
}, pt = ({
|
|
344
344
|
block: e,
|
|
345
345
|
context: t
|
|
346
346
|
}) => {
|
|
@@ -361,20 +361,20 @@ const mt = ({
|
|
|
361
361
|
if (!Array.isArray(i))
|
|
362
362
|
return;
|
|
363
363
|
const r = n.collection.split(".").pop(), a = n.itemName || (r ? r + "Item" : "item");
|
|
364
|
-
return i.map((c,
|
|
364
|
+
return i.map((c, u) => ({
|
|
365
365
|
context: {
|
|
366
366
|
...t,
|
|
367
367
|
localState: {
|
|
368
368
|
...t.localState,
|
|
369
|
-
$index:
|
|
369
|
+
$index: u,
|
|
370
370
|
$item: c,
|
|
371
371
|
[a]: c,
|
|
372
|
-
[`$${a}Index`]:
|
|
372
|
+
[`$${a}Index`]: u
|
|
373
373
|
}
|
|
374
374
|
},
|
|
375
375
|
block: o
|
|
376
376
|
}));
|
|
377
|
-
},
|
|
377
|
+
}, gt = (e) => e && (e.isRSC || ["Core:Button", "Symbol", "Columns", "Form:Form", "Builder: Tabs"].includes(e.name)), bt = (e) => e && (e.isRSC || ["Symbol", "Columns", "Form:Form", "Builder: Tabs"].includes(e.name)), be = {
|
|
378
378
|
small: {
|
|
379
379
|
min: 320,
|
|
380
380
|
default: 321,
|
|
@@ -390,11 +390,11 @@ const mt = ({
|
|
|
390
390
|
default: 991,
|
|
391
391
|
max: 1200
|
|
392
392
|
}
|
|
393
|
-
},
|
|
393
|
+
}, Q = (e, t = be) => `@media (max-width: ${t[e].max}px)`, ye = ({
|
|
394
394
|
small: e,
|
|
395
395
|
medium: t
|
|
396
396
|
}) => {
|
|
397
|
-
const n =
|
|
397
|
+
const n = O(be);
|
|
398
398
|
if (!e || !t)
|
|
399
399
|
return n;
|
|
400
400
|
const o = Math.floor(e / 2);
|
|
@@ -426,7 +426,7 @@ function F(e) {
|
|
|
426
426
|
}
|
|
427
427
|
);
|
|
428
428
|
}
|
|
429
|
-
function
|
|
429
|
+
function X(e, ...t) {
|
|
430
430
|
const n = Object(e);
|
|
431
431
|
for (let o = 1; o < arguments.length; o++) {
|
|
432
432
|
const i = arguments[o];
|
|
@@ -436,40 +436,40 @@ function J(e, ...t) {
|
|
|
436
436
|
}
|
|
437
437
|
return n;
|
|
438
438
|
}
|
|
439
|
-
const
|
|
440
|
-
function
|
|
439
|
+
const Se = (e) => e ? e.replace(/([A-Z])/g, (t) => `-${t[0].toLowerCase()}`) : "";
|
|
440
|
+
function yt(e) {
|
|
441
441
|
console.warn(`Cannot animate element: element with ID ${e} not found!`);
|
|
442
442
|
}
|
|
443
|
-
function
|
|
444
|
-
const n =
|
|
443
|
+
function St(e, t) {
|
|
444
|
+
const n = vt(e), o = getComputedStyle(t), i = e.steps[0].styles, r = e.steps[e.steps.length - 1].styles, a = [i, r];
|
|
445
445
|
for (const s of a)
|
|
446
446
|
for (const c of n)
|
|
447
447
|
c in s || (s[c] = o[c]);
|
|
448
448
|
}
|
|
449
|
-
function
|
|
449
|
+
function vt(e) {
|
|
450
450
|
const t = [];
|
|
451
451
|
for (const n of e.steps)
|
|
452
452
|
for (const o in n.styles)
|
|
453
453
|
t.indexOf(o) === -1 && t.push(o);
|
|
454
454
|
return t;
|
|
455
455
|
}
|
|
456
|
-
function
|
|
456
|
+
function po(e) {
|
|
457
457
|
const t = Array.prototype.slice.call(document.getElementsByClassName(e.elementId || e.id || ""));
|
|
458
458
|
if (!t.length) {
|
|
459
|
-
|
|
459
|
+
yt(e.elementId || e.id || "");
|
|
460
460
|
return;
|
|
461
461
|
}
|
|
462
462
|
Array.from(t).forEach((n) => {
|
|
463
|
-
|
|
464
|
-
n.style.transition = `all ${e.duration}s ${
|
|
463
|
+
St(e, n), n.style.transition = "none", n.style.transitionDelay = "0", X(n.style, e.steps[0].styles), setTimeout(() => {
|
|
464
|
+
n.style.transition = `all ${e.duration}s ${Se(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s"), X(n.style, e.steps[1].styles), setTimeout(() => {
|
|
465
465
|
n.style.transition = "", n.style.transitionDelay = "";
|
|
466
466
|
}, (e.delay || 0) * 1e3 + e.duration * 1e3 + 100);
|
|
467
467
|
});
|
|
468
468
|
});
|
|
469
469
|
}
|
|
470
|
-
function
|
|
470
|
+
function kt(e) {
|
|
471
471
|
const t = function() {
|
|
472
|
-
const i =
|
|
472
|
+
const i = N({
|
|
473
473
|
block: e.block,
|
|
474
474
|
localState: e.context.localState,
|
|
475
475
|
rootState: e.context.rootState,
|
|
@@ -479,64 +479,64 @@ function bt(e) {
|
|
|
479
479
|
});
|
|
480
480
|
return I(i.hide) ? !i.hide : I(i.show) ? i.show : !0;
|
|
481
481
|
}, n = function() {
|
|
482
|
-
var
|
|
483
|
-
const i =
|
|
482
|
+
var m, p, y;
|
|
483
|
+
const i = N({
|
|
484
484
|
block: e.block,
|
|
485
485
|
localState: e.context.localState,
|
|
486
486
|
rootState: e.context.rootState,
|
|
487
487
|
rootSetState: e.context.rootSetState,
|
|
488
488
|
context: e.context.context,
|
|
489
489
|
shouldEvaluateBindings: !0
|
|
490
|
-
}), r = i.responsiveStyles, a = e.context.content, s =
|
|
491
|
-
((
|
|
492
|
-
), c = r == null ? void 0 : r.large,
|
|
493
|
-
if (!
|
|
490
|
+
}), r = i.responsiveStyles, a = e.context.content, s = ye(
|
|
491
|
+
((m = a == null ? void 0 : a.meta) == null ? void 0 : m.breakpoints) || {}
|
|
492
|
+
), c = r == null ? void 0 : r.large, u = r == null ? void 0 : r.medium, h = r == null ? void 0 : r.small, d = i.id;
|
|
493
|
+
if (!d)
|
|
494
494
|
return "";
|
|
495
|
-
const
|
|
496
|
-
className:
|
|
495
|
+
const f = c ? B({
|
|
496
|
+
className: d,
|
|
497
497
|
styles: c
|
|
498
|
-
}) : "",
|
|
499
|
-
className:
|
|
500
|
-
styles:
|
|
501
|
-
mediaQuery:
|
|
498
|
+
}) : "", g = u ? B({
|
|
499
|
+
className: d,
|
|
500
|
+
styles: u,
|
|
501
|
+
mediaQuery: Q(
|
|
502
502
|
"medium",
|
|
503
503
|
s
|
|
504
504
|
)
|
|
505
|
-
}) : "",
|
|
506
|
-
className:
|
|
507
|
-
styles:
|
|
508
|
-
mediaQuery:
|
|
505
|
+
}) : "", v = h ? B({
|
|
506
|
+
className: d,
|
|
507
|
+
styles: h,
|
|
508
|
+
mediaQuery: Q(
|
|
509
509
|
"small",
|
|
510
510
|
s
|
|
511
511
|
)
|
|
512
|
-
}) : "",
|
|
513
|
-
let
|
|
514
|
-
if (
|
|
515
|
-
const S = ((
|
|
516
|
-
|
|
517
|
-
className: `${
|
|
512
|
+
}) : "", b = i.animations && i.animations.find((S) => S.trigger === "hover");
|
|
513
|
+
let E = "";
|
|
514
|
+
if (b) {
|
|
515
|
+
const S = ((y = (p = b.steps) == null ? void 0 : p[1]) == null ? void 0 : y.styles) || {};
|
|
516
|
+
E = B({
|
|
517
|
+
className: `${d}:hover`,
|
|
518
518
|
styles: {
|
|
519
519
|
...S,
|
|
520
|
-
transition: `all ${
|
|
521
|
-
|
|
520
|
+
transition: `all ${b.duration}s ${Se(
|
|
521
|
+
b.easing
|
|
522
522
|
)}`,
|
|
523
|
-
transitionDelay:
|
|
523
|
+
transitionDelay: b.delay ? `${b.delay}s` : "0s"
|
|
524
524
|
}
|
|
525
525
|
}) || "";
|
|
526
526
|
}
|
|
527
527
|
return [
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
528
|
+
f,
|
|
529
|
+
g,
|
|
530
|
+
v,
|
|
531
|
+
E
|
|
532
532
|
].join(" ");
|
|
533
533
|
};
|
|
534
|
-
return /* @__PURE__ */ l(
|
|
534
|
+
return /* @__PURE__ */ l(C, { children: n() && t() ? /* @__PURE__ */ l(C, { children: /* @__PURE__ */ l(F, { id: "builderio-block", styles: n() }) }) : null });
|
|
535
535
|
}
|
|
536
|
-
function
|
|
536
|
+
function Ct(e) {
|
|
537
537
|
return e.charAt(0).toUpperCase() + e.slice(1);
|
|
538
538
|
}
|
|
539
|
-
const
|
|
539
|
+
const xt = (e) => `on${Ct(e)}`, wt = (e, t) => (n) => H({
|
|
540
540
|
code: e,
|
|
541
541
|
context: t.context,
|
|
542
542
|
localState: t.localState,
|
|
@@ -546,15 +546,15 @@ const St = (e) => `on${yt(e)}`, vt = (e, t) => (n) => H({
|
|
|
546
546
|
isExpression: !1,
|
|
547
547
|
enableCache: !0
|
|
548
548
|
});
|
|
549
|
-
function
|
|
549
|
+
function go(e) {
|
|
550
550
|
const t = {}, n = e.block.actions ?? {};
|
|
551
551
|
for (const o in n) {
|
|
552
552
|
if (!n.hasOwnProperty(o))
|
|
553
553
|
continue;
|
|
554
554
|
const i = n[o];
|
|
555
|
-
let r =
|
|
555
|
+
let r = xt(o);
|
|
556
556
|
if (e.stripPrefix)
|
|
557
|
-
switch (
|
|
557
|
+
switch (T) {
|
|
558
558
|
case "vue":
|
|
559
559
|
r = r.replace("v-on:", "");
|
|
560
560
|
break;
|
|
@@ -562,40 +562,40 @@ function lo(e) {
|
|
|
562
562
|
r = r.replace("on:", "");
|
|
563
563
|
break;
|
|
564
564
|
}
|
|
565
|
-
t[r] =
|
|
565
|
+
t[r] = wt(i, e);
|
|
566
566
|
}
|
|
567
567
|
return t;
|
|
568
568
|
}
|
|
569
|
-
function
|
|
569
|
+
function It({
|
|
570
570
|
properties: e
|
|
571
571
|
}) {
|
|
572
572
|
return e;
|
|
573
573
|
}
|
|
574
|
-
const
|
|
574
|
+
const Tt = (e) => ({
|
|
575
575
|
href: e.href
|
|
576
576
|
});
|
|
577
|
-
function
|
|
577
|
+
function Et({
|
|
578
578
|
block: e,
|
|
579
579
|
context: t
|
|
580
580
|
}) {
|
|
581
581
|
var o;
|
|
582
582
|
const n = {
|
|
583
|
-
...
|
|
583
|
+
...Tt(e),
|
|
584
584
|
...e.properties,
|
|
585
585
|
"builder-id": e.id,
|
|
586
|
-
style:
|
|
586
|
+
style: ft({
|
|
587
587
|
block: e,
|
|
588
588
|
context: t
|
|
589
589
|
}),
|
|
590
590
|
[M()]: [e.id, "builder-block", e.class, (o = e.properties) == null ? void 0 : o.class].filter(Boolean).join(" ")
|
|
591
591
|
};
|
|
592
|
-
return
|
|
592
|
+
return It({
|
|
593
593
|
properties: n,
|
|
594
594
|
context: t,
|
|
595
595
|
block: e
|
|
596
596
|
});
|
|
597
597
|
}
|
|
598
|
-
const
|
|
598
|
+
const Rt = ({
|
|
599
599
|
componentOptions: e,
|
|
600
600
|
builderBlock: t,
|
|
601
601
|
context: n,
|
|
@@ -611,7 +611,7 @@ const wt = ({
|
|
|
611
611
|
* component itself directly. Otherwise, they are provided to the wrapper element.
|
|
612
612
|
*/
|
|
613
613
|
...i ? {
|
|
614
|
-
attributes:
|
|
614
|
+
attributes: Et({
|
|
615
615
|
block: t,
|
|
616
616
|
context: a
|
|
617
617
|
})
|
|
@@ -625,13 +625,13 @@ const wt = ({
|
|
|
625
625
|
includeBlockProps: i
|
|
626
626
|
} : s;
|
|
627
627
|
};
|
|
628
|
-
function
|
|
628
|
+
function Z(e) {
|
|
629
629
|
var n;
|
|
630
|
-
const t = e.isInteractive ?
|
|
631
|
-
return /* @__PURE__ */ l(
|
|
630
|
+
const t = e.isInteractive ? Fe : e.componentRef;
|
|
631
|
+
return /* @__PURE__ */ l(C, { children: e.componentRef ? /* @__PURE__ */ l(C, { children: /* @__PURE__ */ l(
|
|
632
632
|
t,
|
|
633
633
|
{
|
|
634
|
-
...
|
|
634
|
+
...Rt({
|
|
635
635
|
componentOptions: e.componentOptions,
|
|
636
636
|
builderBlock: e.builderBlock,
|
|
637
637
|
context: e.context,
|
|
@@ -654,7 +654,7 @@ function Q(e) {
|
|
|
654
654
|
}
|
|
655
655
|
) }) : null });
|
|
656
656
|
}
|
|
657
|
-
function
|
|
657
|
+
function Pt(e) {
|
|
658
658
|
const t = e.repeatContext;
|
|
659
659
|
return /* @__PURE__ */ l(
|
|
660
660
|
L,
|
|
@@ -667,21 +667,21 @@ function It(e) {
|
|
|
667
667
|
);
|
|
668
668
|
}
|
|
669
669
|
function L(e) {
|
|
670
|
-
var c,
|
|
670
|
+
var c, u, h;
|
|
671
671
|
const t = function() {
|
|
672
|
-
return
|
|
672
|
+
return ht({
|
|
673
673
|
block: e.block,
|
|
674
674
|
context: e.context,
|
|
675
675
|
registeredComponents: e.registeredComponents
|
|
676
676
|
});
|
|
677
677
|
}, n = function() {
|
|
678
|
-
return
|
|
678
|
+
return pt({
|
|
679
679
|
block: e.block,
|
|
680
680
|
context: e.context
|
|
681
681
|
});
|
|
682
682
|
}, o = function() {
|
|
683
|
-
var
|
|
684
|
-
return (
|
|
683
|
+
var f;
|
|
684
|
+
return (f = e.block.repeat) != null && f.collection ? e.block : N({
|
|
685
685
|
block: e.block,
|
|
686
686
|
localState: e.context.localState,
|
|
687
687
|
rootState: e.context.rootState,
|
|
@@ -690,29 +690,29 @@ function L(e) {
|
|
|
690
690
|
shouldEvaluateBindings: !0
|
|
691
691
|
});
|
|
692
692
|
}, i = function() {
|
|
693
|
-
var
|
|
694
|
-
return e.block.tagName === "a" || ((
|
|
693
|
+
var g;
|
|
694
|
+
return e.block.tagName === "a" || ((g = o().properties) == null ? void 0 : g.href) || o().href ? e.linkComponent || "a" : e.block.tagName || "div";
|
|
695
695
|
}, r = function() {
|
|
696
|
-
var
|
|
697
|
-
if ((
|
|
698
|
-
return !!((
|
|
699
|
-
const
|
|
700
|
-
return ("show" in o() ? o().show : !0) && !
|
|
696
|
+
var v, b;
|
|
697
|
+
if ((v = e.block.repeat) != null && v.collection)
|
|
698
|
+
return !!((b = n()) != null && b.length);
|
|
699
|
+
const f = "hide" in o() ? o().hide : !1;
|
|
700
|
+
return ("show" in o() ? o().show : !0) && !f;
|
|
701
701
|
}, a = function() {
|
|
702
|
-
var
|
|
703
|
-
return !((
|
|
702
|
+
var g;
|
|
703
|
+
return !((g = t()) != null && g.component) && !n() ? o().children ?? [] : [];
|
|
704
704
|
}, s = function() {
|
|
705
|
-
var
|
|
705
|
+
var f, g, v;
|
|
706
706
|
return {
|
|
707
707
|
blockChildren: o().children ?? [],
|
|
708
|
-
componentRef: (
|
|
708
|
+
componentRef: (f = t()) == null ? void 0 : f.component,
|
|
709
709
|
componentOptions: {
|
|
710
|
-
...
|
|
710
|
+
...Qe(o()),
|
|
711
711
|
builderContext: e.context,
|
|
712
|
-
...(
|
|
712
|
+
...gt(t()) ? {
|
|
713
713
|
builderLinkComponent: e.linkComponent
|
|
714
714
|
} : {},
|
|
715
|
-
...(
|
|
715
|
+
...bt(t()) ? {
|
|
716
716
|
builderComponents: e.registeredComponents
|
|
717
717
|
} : {}
|
|
718
718
|
},
|
|
@@ -720,14 +720,14 @@ function L(e) {
|
|
|
720
720
|
linkComponent: e.linkComponent,
|
|
721
721
|
registeredComponents: e.registeredComponents,
|
|
722
722
|
builderBlock: o(),
|
|
723
|
-
includeBlockProps: ((
|
|
724
|
-
isInteractive: !((
|
|
723
|
+
includeBlockProps: ((g = t()) == null ? void 0 : g.noWrap) === !0,
|
|
724
|
+
isInteractive: !((v = t()) != null && v.isRSC)
|
|
725
725
|
};
|
|
726
726
|
};
|
|
727
|
-
return /* @__PURE__ */ l(
|
|
728
|
-
/* @__PURE__ */ l(
|
|
729
|
-
(c = t()) != null && c.noWrap ? /* @__PURE__ */ l(
|
|
730
|
-
|
|
727
|
+
return /* @__PURE__ */ l(C, { children: r() ? /* @__PURE__ */ R(C, { children: [
|
|
728
|
+
/* @__PURE__ */ l(kt, { block: e.block, context: e.context }),
|
|
729
|
+
(c = t()) != null && c.noWrap ? /* @__PURE__ */ l(C, { children: /* @__PURE__ */ l(
|
|
730
|
+
Z,
|
|
731
731
|
{
|
|
732
732
|
componentRef: s().componentRef,
|
|
733
733
|
componentOptions: s().componentOptions,
|
|
@@ -739,17 +739,17 @@ function L(e) {
|
|
|
739
739
|
includeBlockProps: s().includeBlockProps,
|
|
740
740
|
isInteractive: s().isInteractive
|
|
741
741
|
}
|
|
742
|
-
) }) : /* @__PURE__ */ l(
|
|
743
|
-
|
|
742
|
+
) }) : /* @__PURE__ */ l(C, { children: n() ? /* @__PURE__ */ l(C, { children: (h = n()) == null ? void 0 : h.map((d, f) => /* @__PURE__ */ l(
|
|
743
|
+
Pt,
|
|
744
744
|
{
|
|
745
|
-
repeatContext:
|
|
746
|
-
block:
|
|
745
|
+
repeatContext: d.context,
|
|
746
|
+
block: d.block,
|
|
747
747
|
registeredComponents: e.registeredComponents,
|
|
748
748
|
linkComponent: e.linkComponent
|
|
749
749
|
},
|
|
750
|
-
|
|
750
|
+
f
|
|
751
751
|
)) }) : /* @__PURE__ */ R(
|
|
752
|
-
|
|
752
|
+
Le,
|
|
753
753
|
{
|
|
754
754
|
Wrapper: i(),
|
|
755
755
|
block: o(),
|
|
@@ -757,7 +757,7 @@ function L(e) {
|
|
|
757
757
|
linkComponent: e.linkComponent,
|
|
758
758
|
children: [
|
|
759
759
|
/* @__PURE__ */ l(
|
|
760
|
-
|
|
760
|
+
Z,
|
|
761
761
|
{
|
|
762
762
|
componentRef: s().componentRef,
|
|
763
763
|
componentOptions: s().componentOptions,
|
|
@@ -770,15 +770,15 @@ function L(e) {
|
|
|
770
770
|
isInteractive: s().isInteractive
|
|
771
771
|
}
|
|
772
772
|
),
|
|
773
|
-
(
|
|
773
|
+
(u = a()) == null ? void 0 : u.map((d) => /* @__PURE__ */ l(
|
|
774
774
|
L,
|
|
775
775
|
{
|
|
776
|
-
block:
|
|
776
|
+
block: d,
|
|
777
777
|
registeredComponents: e.registeredComponents,
|
|
778
778
|
linkComponent: e.linkComponent,
|
|
779
779
|
context: e.context
|
|
780
780
|
},
|
|
781
|
-
|
|
781
|
+
d.id
|
|
782
782
|
))
|
|
783
783
|
]
|
|
784
784
|
}
|
|
@@ -788,7 +788,7 @@ function L(e) {
|
|
|
788
788
|
function K(e) {
|
|
789
789
|
var t, n, o;
|
|
790
790
|
return /* @__PURE__ */ l(
|
|
791
|
-
|
|
791
|
+
Ue,
|
|
792
792
|
{
|
|
793
793
|
blocks: e.blocks,
|
|
794
794
|
parent: e.parent,
|
|
@@ -796,7 +796,7 @@ function K(e) {
|
|
|
796
796
|
styleProp: e.styleProp,
|
|
797
797
|
BlocksWrapper: (t = e.context) == null ? void 0 : t.BlocksWrapper,
|
|
798
798
|
BlocksWrapperProps: (n = e.context) == null ? void 0 : n.BlocksWrapperProps,
|
|
799
|
-
children: e.blocks ? /* @__PURE__ */ l(
|
|
799
|
+
children: e.blocks ? /* @__PURE__ */ l(C, { children: (o = e.blocks) == null ? void 0 : o.map((i) => /* @__PURE__ */ l(
|
|
800
800
|
L,
|
|
801
801
|
{
|
|
802
802
|
block: i,
|
|
@@ -809,67 +809,70 @@ function K(e) {
|
|
|
809
809
|
}
|
|
810
810
|
);
|
|
811
811
|
}
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
812
|
+
const At = (e) => `builder-columns ${e}-breakpoints`;
|
|
813
|
+
function Vt(e) {
|
|
814
|
+
var b, E;
|
|
815
|
+
const t = typeof e.space == "number" ? e.space || 0 : 20, n = e.columns || [], o = e.stackColumnsAt || "tablet", i = function(p) {
|
|
816
|
+
return p.link ? e.builderLinkComponent || "a" : "div";
|
|
817
|
+
}, r = function(p) {
|
|
815
818
|
var y;
|
|
816
|
-
return ((y = n[
|
|
817
|
-
},
|
|
819
|
+
return ((y = n[p]) == null ? void 0 : y.width) || 100 / n.length;
|
|
820
|
+
}, a = function(p) {
|
|
818
821
|
const y = t * (n.length - 1) / n.length;
|
|
819
|
-
return `calc(${
|
|
820
|
-
},
|
|
821
|
-
stackedStyle:
|
|
822
|
+
return `calc(${r(p)}% - ${y}px)`;
|
|
823
|
+
}, s = function({
|
|
824
|
+
stackedStyle: p,
|
|
822
825
|
desktopStyle: y
|
|
823
826
|
}) {
|
|
824
|
-
return o === "tablet" ?
|
|
825
|
-
},
|
|
826
|
-
stackedStyle:
|
|
827
|
+
return o === "tablet" ? p : y;
|
|
828
|
+
}, c = function({
|
|
829
|
+
stackedStyle: p,
|
|
827
830
|
desktopStyle: y
|
|
828
831
|
}) {
|
|
829
|
-
return o === "never" ? y :
|
|
830
|
-
},
|
|
832
|
+
return o === "never" ? y : p;
|
|
833
|
+
}, u = e.stackColumnsAt === "never" ? "row" : e.reverseColumnsWhenStacked ? "column-reverse" : "column", h = function() {
|
|
831
834
|
return {
|
|
832
|
-
"--flex-dir":
|
|
833
|
-
"--flex-dir-tablet":
|
|
834
|
-
stackedStyle:
|
|
835
|
+
"--flex-dir": u,
|
|
836
|
+
"--flex-dir-tablet": s({
|
|
837
|
+
stackedStyle: u,
|
|
835
838
|
desktopStyle: "row"
|
|
836
839
|
})
|
|
837
840
|
};
|
|
838
|
-
},
|
|
839
|
-
const y =
|
|
841
|
+
}, d = function(p) {
|
|
842
|
+
const y = p === 0 ? 0 : t, S = a(p), x = `${y}px`, Y = "100%", G = 0;
|
|
840
843
|
return {
|
|
841
844
|
...{
|
|
842
845
|
display: "flex",
|
|
843
846
|
flexDirection: "column",
|
|
844
847
|
alignItems: "stretch"
|
|
845
848
|
},
|
|
846
|
-
width:
|
|
847
|
-
["marginLeft"]:
|
|
848
|
-
"--column-width-mobile":
|
|
849
|
-
stackedStyle:
|
|
850
|
-
desktopStyle:
|
|
849
|
+
width: S,
|
|
850
|
+
["marginLeft"]: x,
|
|
851
|
+
"--column-width-mobile": c({
|
|
852
|
+
stackedStyle: Y,
|
|
853
|
+
desktopStyle: S
|
|
851
854
|
}),
|
|
852
|
-
"--column-margin-left-mobile":
|
|
853
|
-
stackedStyle:
|
|
854
|
-
desktopStyle:
|
|
855
|
+
"--column-margin-left-mobile": c({
|
|
856
|
+
stackedStyle: G,
|
|
857
|
+
desktopStyle: x
|
|
855
858
|
}),
|
|
856
|
-
"--column-width-tablet":
|
|
857
|
-
stackedStyle:
|
|
858
|
-
desktopStyle:
|
|
859
|
+
"--column-width-tablet": s({
|
|
860
|
+
stackedStyle: Y,
|
|
861
|
+
desktopStyle: S
|
|
859
862
|
}),
|
|
860
|
-
"--column-margin-left-tablet":
|
|
861
|
-
stackedStyle:
|
|
862
|
-
desktopStyle:
|
|
863
|
+
"--column-margin-left-tablet": s({
|
|
864
|
+
stackedStyle: G,
|
|
865
|
+
desktopStyle: x
|
|
863
866
|
})
|
|
864
867
|
};
|
|
865
|
-
},
|
|
866
|
-
var
|
|
867
|
-
return
|
|
868
|
-
((
|
|
869
|
-
)[
|
|
870
|
-
},
|
|
868
|
+
}, f = function(p) {
|
|
869
|
+
var S, x;
|
|
870
|
+
return ye(
|
|
871
|
+
((x = (S = e.builderContext.content) == null ? void 0 : S.meta) == null ? void 0 : x.breakpoints) || {}
|
|
872
|
+
)[p].max;
|
|
873
|
+
}, g = function() {
|
|
871
874
|
return `
|
|
872
|
-
@media (max-width: ${
|
|
875
|
+
@media (max-width: ${f("medium")}px) {
|
|
873
876
|
.${e.builderBlock.id}-breakpoints {
|
|
874
877
|
flex-direction: var(--flex-dir-tablet);
|
|
875
878
|
align-items: stretch;
|
|
@@ -881,7 +884,7 @@ function Tt(e) {
|
|
|
881
884
|
}
|
|
882
885
|
}
|
|
883
886
|
|
|
884
|
-
@media (max-width: ${
|
|
887
|
+
@media (max-width: ${f("small")}px) {
|
|
885
888
|
.${e.builderBlock.id}-breakpoints {
|
|
886
889
|
flex-direction: var(--flex-dir);
|
|
887
890
|
align-items: stretch;
|
|
@@ -893,31 +896,33 @@ function Tt(e) {
|
|
|
893
896
|
}
|
|
894
897
|
},
|
|
895
898
|
`;
|
|
899
|
+
}, v = function(p, y) {
|
|
900
|
+
return {
|
|
901
|
+
...p.link ? {
|
|
902
|
+
href: p.link
|
|
903
|
+
} : {},
|
|
904
|
+
[M()]: "builder-column",
|
|
905
|
+
style: ge(d(y))
|
|
906
|
+
};
|
|
896
907
|
};
|
|
897
|
-
return /* @__PURE__ */ R(
|
|
908
|
+
return /* @__PURE__ */ R(C, { children: [
|
|
898
909
|
/* @__PURE__ */ R(
|
|
899
910
|
"div",
|
|
900
911
|
{
|
|
901
|
-
className:
|
|
902
|
-
style:
|
|
912
|
+
className: At((b = e.builderBlock) == null ? void 0 : b.id) + " div-2651dce4",
|
|
913
|
+
style: h(),
|
|
903
914
|
children: [
|
|
904
|
-
/* @__PURE__ */ l(F, { id: "builderio-columns", styles:
|
|
905
|
-
(
|
|
906
|
-
|
|
915
|
+
/* @__PURE__ */ l(F, { id: "builderio-columns", styles: g() }),
|
|
916
|
+
(E = e.columns) == null ? void 0 : E.map((m, p) => /* @__PURE__ */ l(
|
|
917
|
+
De,
|
|
907
918
|
{
|
|
908
|
-
TagName:
|
|
919
|
+
TagName: i(m),
|
|
909
920
|
actionAttributes: {},
|
|
910
|
-
attributes:
|
|
911
|
-
...p.link ? {
|
|
912
|
-
href: p.link
|
|
913
|
-
} : {},
|
|
914
|
-
[M()]: "builder-column",
|
|
915
|
-
style: he(g(d))
|
|
916
|
-
},
|
|
921
|
+
attributes: v(m, p),
|
|
917
922
|
children: /* @__PURE__ */ l(
|
|
918
923
|
K,
|
|
919
924
|
{
|
|
920
|
-
path: `component.options.columns.${
|
|
925
|
+
path: `component.options.columns.${p}.blocks`,
|
|
921
926
|
parent: e.builderBlock.id,
|
|
922
927
|
styleProp: {
|
|
923
928
|
flexGrow: "1"
|
|
@@ -925,57 +930,57 @@ function Tt(e) {
|
|
|
925
930
|
context: e.builderContext,
|
|
926
931
|
registeredComponents: e.builderComponents,
|
|
927
932
|
linkComponent: e.builderLinkComponent,
|
|
928
|
-
blocks:
|
|
933
|
+
blocks: m.blocks
|
|
929
934
|
}
|
|
930
935
|
)
|
|
931
936
|
},
|
|
932
|
-
|
|
937
|
+
p
|
|
933
938
|
))
|
|
934
939
|
]
|
|
935
940
|
}
|
|
936
941
|
),
|
|
937
|
-
/* @__PURE__ */ l("style", { children: `.div-
|
|
942
|
+
/* @__PURE__ */ l("style", { children: `.div-2651dce4 {
|
|
938
943
|
display: flex;
|
|
939
944
|
line-height: normal;
|
|
940
945
|
}` })
|
|
941
946
|
] });
|
|
942
947
|
}
|
|
943
|
-
function
|
|
948
|
+
function ee(e) {
|
|
944
949
|
return e.replace(/http(s)?:/, "");
|
|
945
950
|
}
|
|
946
|
-
function
|
|
951
|
+
function Bt(e = "", t, n) {
|
|
947
952
|
const o = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), i = e.indexOf("?") !== -1 ? "&" : "?";
|
|
948
953
|
return e.match(o) ? e.replace(o, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + i + t + "=" + encodeURIComponent(n);
|
|
949
954
|
}
|
|
950
|
-
function
|
|
955
|
+
function Wt(e, t) {
|
|
951
956
|
if (!e || !(e != null && e.match(/cdn\.shopify\.com/)) || !t)
|
|
952
957
|
return e;
|
|
953
958
|
if (t === "master")
|
|
954
|
-
return
|
|
959
|
+
return ee(e);
|
|
955
960
|
const n = e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);
|
|
956
961
|
if (n) {
|
|
957
962
|
const o = e.split(n[0]), i = n[3], r = t.match("x") ? t : `${t}x`;
|
|
958
|
-
return
|
|
963
|
+
return ee(`${o[0]}_${r}${i}`);
|
|
959
964
|
}
|
|
960
965
|
return null;
|
|
961
966
|
}
|
|
962
|
-
function
|
|
967
|
+
function bo(e) {
|
|
963
968
|
if (!e)
|
|
964
969
|
return e;
|
|
965
970
|
const t = [100, 200, 400, 800, 1200, 1600, 2e3];
|
|
966
971
|
if (e.match(/builder\.io/)) {
|
|
967
972
|
let n = e;
|
|
968
973
|
const o = Number(e.split("?width=")[1]);
|
|
969
|
-
return isNaN(o) || (n = `${n} ${o}w`), t.filter((i) => i !== o).map((i) => `${
|
|
974
|
+
return isNaN(o) || (n = `${n} ${o}w`), t.filter((i) => i !== o).map((i) => `${Bt(e, "width", i)} ${i}w`).concat([n]).join(", ");
|
|
970
975
|
}
|
|
971
|
-
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [
|
|
976
|
+
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [Wt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, o]) => `${n} ${o}w`).concat([e]).join(", ") : e;
|
|
972
977
|
}
|
|
973
|
-
const
|
|
978
|
+
const $t = (e) => {
|
|
974
979
|
if (e === "localhost" || e === "127.0.0.1")
|
|
975
980
|
return e;
|
|
976
981
|
const t = e.split(".");
|
|
977
982
|
return t.length > 2 ? t.slice(1).join(".") : e;
|
|
978
|
-
},
|
|
983
|
+
}, ve = ({
|
|
979
984
|
name: e,
|
|
980
985
|
canTrack: t
|
|
981
986
|
}) => {
|
|
@@ -983,17 +988,17 @@ const Pt = (e) => {
|
|
|
983
988
|
try {
|
|
984
989
|
return t ? (n = document.cookie.split("; ").find((o) => o.startsWith(`${e}=`))) == null ? void 0 : n.split("=")[1] : void 0;
|
|
985
990
|
} catch (o) {
|
|
986
|
-
|
|
991
|
+
w.warn("[COOKIE] GET error: ", (o == null ? void 0 : o.message) || o);
|
|
987
992
|
return;
|
|
988
993
|
}
|
|
989
|
-
},
|
|
994
|
+
}, ke = async (e) => ve(e), Nt = (e) => e.map(([t, n]) => n ? `${t}=${n}` : t).filter(I).join("; "), Ot = [["secure", ""], ["SameSite", "None"]], Ft = ({
|
|
990
995
|
name: e,
|
|
991
996
|
value: t,
|
|
992
997
|
expires: n
|
|
993
998
|
}) => {
|
|
994
|
-
const i = (
|
|
995
|
-
return
|
|
996
|
-
},
|
|
999
|
+
const i = (k() ? location.protocol === "https:" : !0) ? Ot : [[]], r = n ? [["expires", n.toUTCString()]] : [[]], a = [[e, t], ...r, ["path", "/"], ["domain", $t(window.location.hostname)], ...i];
|
|
1000
|
+
return Nt(a);
|
|
1001
|
+
}, Ce = async ({
|
|
997
1002
|
name: e,
|
|
998
1003
|
value: t,
|
|
999
1004
|
expires: n,
|
|
@@ -1002,33 +1007,33 @@ const Pt = (e) => {
|
|
|
1002
1007
|
try {
|
|
1003
1008
|
if (!o)
|
|
1004
1009
|
return;
|
|
1005
|
-
const i =
|
|
1010
|
+
const i = Ft({
|
|
1006
1011
|
name: e,
|
|
1007
1012
|
value: t,
|
|
1008
1013
|
expires: n
|
|
1009
1014
|
});
|
|
1010
1015
|
document.cookie = i;
|
|
1011
1016
|
} catch (i) {
|
|
1012
|
-
|
|
1017
|
+
w.warn("[COOKIE] SET error: ", (i == null ? void 0 : i.message) || i);
|
|
1013
1018
|
}
|
|
1014
|
-
},
|
|
1019
|
+
}, Lt = "builder.tests", z = (e) => `${Lt}.${e}`, Ut = ({
|
|
1015
1020
|
contentId: e
|
|
1016
|
-
}) =>
|
|
1021
|
+
}) => ke({
|
|
1017
1022
|
name: z(e),
|
|
1018
1023
|
canTrack: !0
|
|
1019
|
-
}),
|
|
1024
|
+
}), Dt = ({
|
|
1020
1025
|
contentId: e
|
|
1021
|
-
}) =>
|
|
1026
|
+
}) => ve({
|
|
1022
1027
|
name: z(e),
|
|
1023
1028
|
canTrack: !0
|
|
1024
|
-
}),
|
|
1029
|
+
}), _t = ({
|
|
1025
1030
|
contentId: e,
|
|
1026
1031
|
value: t
|
|
1027
|
-
}) =>
|
|
1032
|
+
}) => Ce({
|
|
1028
1033
|
name: z(e),
|
|
1029
1034
|
value: t,
|
|
1030
1035
|
canTrack: !0
|
|
1031
|
-
}),
|
|
1036
|
+
}), xe = (e) => I(e.id) && I(e.variations) && Object.keys(e.variations).length > 0, Mt = ({
|
|
1032
1037
|
id: e,
|
|
1033
1038
|
variations: t
|
|
1034
1039
|
}) => {
|
|
@@ -1041,15 +1046,15 @@ const Pt = (e) => {
|
|
|
1041
1046
|
return r;
|
|
1042
1047
|
}
|
|
1043
1048
|
return e;
|
|
1044
|
-
},
|
|
1045
|
-
const t =
|
|
1046
|
-
return
|
|
1049
|
+
}, we = (e) => {
|
|
1050
|
+
const t = Mt(e);
|
|
1051
|
+
return _t({
|
|
1047
1052
|
contentId: e.id,
|
|
1048
1053
|
value: t
|
|
1049
1054
|
}).catch((n) => {
|
|
1050
|
-
|
|
1055
|
+
w.error("could not store A/B test variation: ", n);
|
|
1051
1056
|
}), t;
|
|
1052
|
-
},
|
|
1057
|
+
}, Ie = ({
|
|
1053
1058
|
item: e,
|
|
1054
1059
|
testGroupId: t
|
|
1055
1060
|
}) => {
|
|
@@ -1063,7 +1068,7 @@ const Pt = (e) => {
|
|
|
1063
1068
|
testVariationId: n.id,
|
|
1064
1069
|
testVariationName: n.name || (n.id === e.id ? "Default" : "")
|
|
1065
1070
|
};
|
|
1066
|
-
},
|
|
1071
|
+
}, jt = ({
|
|
1067
1072
|
item: e,
|
|
1068
1073
|
canTrack: t
|
|
1069
1074
|
}) => {
|
|
@@ -1071,14 +1076,14 @@ const Pt = (e) => {
|
|
|
1071
1076
|
return e;
|
|
1072
1077
|
if (!e)
|
|
1073
1078
|
return;
|
|
1074
|
-
if (!
|
|
1079
|
+
if (!xe(e))
|
|
1075
1080
|
return e;
|
|
1076
|
-
const n =
|
|
1081
|
+
const n = Dt({
|
|
1077
1082
|
contentId: e.id
|
|
1078
|
-
}) ||
|
|
1083
|
+
}) || we({
|
|
1079
1084
|
variations: e.variations,
|
|
1080
1085
|
id: e.id
|
|
1081
|
-
}), o =
|
|
1086
|
+
}), o = Ie({
|
|
1082
1087
|
item: e,
|
|
1083
1088
|
testGroupId: n
|
|
1084
1089
|
});
|
|
@@ -1086,18 +1091,18 @@ const Pt = (e) => {
|
|
|
1086
1091
|
...e,
|
|
1087
1092
|
...o
|
|
1088
1093
|
};
|
|
1089
|
-
},
|
|
1094
|
+
}, Ht = async ({
|
|
1090
1095
|
item: e,
|
|
1091
1096
|
canTrack: t
|
|
1092
1097
|
}) => {
|
|
1093
|
-
if (!t || !
|
|
1098
|
+
if (!t || !xe(e))
|
|
1094
1099
|
return e;
|
|
1095
|
-
const o = await
|
|
1100
|
+
const o = await Ut({
|
|
1096
1101
|
contentId: e.id
|
|
1097
|
-
}) ||
|
|
1102
|
+
}) || we({
|
|
1098
1103
|
variations: e.variations,
|
|
1099
1104
|
id: e.id
|
|
1100
|
-
}), i =
|
|
1105
|
+
}), i = Ie({
|
|
1101
1106
|
item: e,
|
|
1102
1107
|
testGroupId: o
|
|
1103
1108
|
});
|
|
@@ -1105,7 +1110,7 @@ const Pt = (e) => {
|
|
|
1105
1110
|
...e,
|
|
1106
1111
|
...i
|
|
1107
1112
|
};
|
|
1108
|
-
}, U = (e) => I(e) ? e : !0,
|
|
1113
|
+
}, U = (e) => I(e) ? e : !0, Kt = {
|
|
1109
1114
|
name: "Core:Button",
|
|
1110
1115
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
1111
1116
|
defaultStyles: {
|
|
@@ -1138,7 +1143,7 @@ const Pt = (e) => {
|
|
|
1138
1143
|
}],
|
|
1139
1144
|
static: !0,
|
|
1140
1145
|
noWrap: !0
|
|
1141
|
-
},
|
|
1146
|
+
}, zt = {
|
|
1142
1147
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
1143
1148
|
name: "Columns",
|
|
1144
1149
|
isRSC: !0,
|
|
@@ -1339,13 +1344,13 @@ const Pt = (e) => {
|
|
|
1339
1344
|
helperText: "When stacking columns for mobile devices, reverse the ordering",
|
|
1340
1345
|
advanced: !0
|
|
1341
1346
|
}]
|
|
1342
|
-
},
|
|
1347
|
+
}, qt = {
|
|
1343
1348
|
name: "Fragment",
|
|
1344
1349
|
static: !0,
|
|
1345
1350
|
hidden: !0,
|
|
1346
1351
|
canHaveChildren: !0,
|
|
1347
1352
|
noWrap: !0
|
|
1348
|
-
},
|
|
1353
|
+
}, Yt = {
|
|
1349
1354
|
name: "Image",
|
|
1350
1355
|
static: !0,
|
|
1351
1356
|
image: "https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-insert_photo-24px.svg?alt=media&token=4e5d0ef4-f5e8-4e57-b3a9-38d63a9b9dc4",
|
|
@@ -1366,15 +1371,15 @@ const Pt = (e) => {
|
|
|
1366
1371
|
onChange: (e) => {
|
|
1367
1372
|
e.delete("srcset"), e.delete("noWebp");
|
|
1368
1373
|
function n(a, s = 6e4) {
|
|
1369
|
-
return new Promise((c,
|
|
1370
|
-
const
|
|
1371
|
-
let
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
},
|
|
1375
|
-
console.warn("Image load failed",
|
|
1376
|
-
}),
|
|
1377
|
-
|
|
1374
|
+
return new Promise((c, u) => {
|
|
1375
|
+
const h = document.createElement("img");
|
|
1376
|
+
let d = !1;
|
|
1377
|
+
h.onload = () => {
|
|
1378
|
+
d = !0, c(h);
|
|
1379
|
+
}, h.addEventListener("error", (f) => {
|
|
1380
|
+
console.warn("Image load failed", f.error), u(f.error);
|
|
1381
|
+
}), h.src = a, setTimeout(() => {
|
|
1382
|
+
d || u(new Error("Image load timed out"));
|
|
1378
1383
|
}, s);
|
|
1379
1384
|
});
|
|
1380
1385
|
}
|
|
@@ -1445,7 +1450,7 @@ const Pt = (e) => {
|
|
|
1445
1450
|
advanced: !0,
|
|
1446
1451
|
defaultValue: 0.7041
|
|
1447
1452
|
}]
|
|
1448
|
-
},
|
|
1453
|
+
}, Gt = {
|
|
1449
1454
|
name: "Core:Section",
|
|
1450
1455
|
static: !0,
|
|
1451
1456
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -1484,7 +1489,7 @@ const Pt = (e) => {
|
|
|
1484
1489
|
}
|
|
1485
1490
|
}
|
|
1486
1491
|
}]
|
|
1487
|
-
},
|
|
1492
|
+
}, Jt = {
|
|
1488
1493
|
name: "Slot",
|
|
1489
1494
|
isRSC: !0,
|
|
1490
1495
|
description: "Allow child blocks to be inserted into this content when used as a Symbol",
|
|
@@ -1498,7 +1503,7 @@ const Pt = (e) => {
|
|
|
1498
1503
|
defaultValue: "children"
|
|
1499
1504
|
}]
|
|
1500
1505
|
};
|
|
1501
|
-
function
|
|
1506
|
+
function Qt(e) {
|
|
1502
1507
|
var t, n, o;
|
|
1503
1508
|
return /* @__PURE__ */ l(
|
|
1504
1509
|
"div",
|
|
@@ -1521,7 +1526,7 @@ function zt(e) {
|
|
|
1521
1526
|
}
|
|
1522
1527
|
);
|
|
1523
1528
|
}
|
|
1524
|
-
const
|
|
1529
|
+
const Xt = {
|
|
1525
1530
|
name: "Symbol",
|
|
1526
1531
|
noWrap: !0,
|
|
1527
1532
|
static: !0,
|
|
@@ -1554,7 +1559,7 @@ const qt = {
|
|
|
1554
1559
|
hideFromUI: !0,
|
|
1555
1560
|
type: "boolean"
|
|
1556
1561
|
}]
|
|
1557
|
-
},
|
|
1562
|
+
}, Zt = {
|
|
1558
1563
|
name: "Text",
|
|
1559
1564
|
static: !0,
|
|
1560
1565
|
isRSC: !0,
|
|
@@ -1573,7 +1578,7 @@ const qt = {
|
|
|
1573
1578
|
textAlign: "center"
|
|
1574
1579
|
}
|
|
1575
1580
|
};
|
|
1576
|
-
function
|
|
1581
|
+
function en(e) {
|
|
1577
1582
|
var t;
|
|
1578
1583
|
return /* @__PURE__ */ l(
|
|
1579
1584
|
"div",
|
|
@@ -1586,7 +1591,7 @@ function Gt(e) {
|
|
|
1586
1591
|
}
|
|
1587
1592
|
);
|
|
1588
1593
|
}
|
|
1589
|
-
const
|
|
1594
|
+
const tn = {
|
|
1590
1595
|
name: "Custom Code",
|
|
1591
1596
|
static: !0,
|
|
1592
1597
|
requiredPermissions: ["editCode"],
|
|
@@ -1608,7 +1613,7 @@ const Jt = {
|
|
|
1608
1613
|
helperText: "Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",
|
|
1609
1614
|
advanced: !0
|
|
1610
1615
|
}]
|
|
1611
|
-
},
|
|
1616
|
+
}, nn = {
|
|
1612
1617
|
name: "Embed",
|
|
1613
1618
|
static: !0,
|
|
1614
1619
|
inputs: [{
|
|
@@ -1633,7 +1638,7 @@ const Jt = {
|
|
|
1633
1638
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
1634
1639
|
hideFromUI: !0
|
|
1635
1640
|
}]
|
|
1636
|
-
},
|
|
1641
|
+
}, on = ["text/javascript", "application/javascript", "application/ecmascript"], yo = (e) => on.includes(e.type), rn = {
|
|
1637
1642
|
// friendlyName?
|
|
1638
1643
|
name: "Raw:Img",
|
|
1639
1644
|
hideFromInsertMenu: !0,
|
|
@@ -1647,7 +1652,7 @@ const Jt = {
|
|
|
1647
1652
|
}],
|
|
1648
1653
|
noWrap: !0,
|
|
1649
1654
|
static: !0
|
|
1650
|
-
},
|
|
1655
|
+
}, an = {
|
|
1651
1656
|
name: "Video",
|
|
1652
1657
|
canHaveChildren: !0,
|
|
1653
1658
|
defaultStyles: {
|
|
@@ -1728,58 +1733,58 @@ const Jt = {
|
|
|
1728
1733
|
defaultValue: !0,
|
|
1729
1734
|
advanced: !0
|
|
1730
1735
|
}]
|
|
1731
|
-
},
|
|
1732
|
-
component: Le,
|
|
1733
|
-
...Jt
|
|
1734
|
-
}, {
|
|
1735
|
-
component: Ue,
|
|
1736
|
-
...Qt
|
|
1737
|
-
}, {
|
|
1738
|
-
component: De,
|
|
1739
|
-
...Zt
|
|
1740
|
-
}, {
|
|
1736
|
+
}, sn = () => [{
|
|
1741
1737
|
component: _e,
|
|
1742
|
-
...
|
|
1743
|
-
}], Z = () => [{
|
|
1744
|
-
component: Me,
|
|
1745
|
-
...Dt
|
|
1738
|
+
...tn
|
|
1746
1739
|
}, {
|
|
1747
|
-
component:
|
|
1748
|
-
...
|
|
1740
|
+
component: Me,
|
|
1741
|
+
...nn
|
|
1749
1742
|
}, {
|
|
1750
1743
|
component: je,
|
|
1751
|
-
...
|
|
1744
|
+
...rn
|
|
1752
1745
|
}, {
|
|
1753
1746
|
component: He,
|
|
1754
|
-
...
|
|
1755
|
-
}, {
|
|
1747
|
+
...an
|
|
1748
|
+
}], te = () => [{
|
|
1756
1749
|
component: Ke,
|
|
1757
|
-
...Ht
|
|
1758
|
-
}, {
|
|
1759
|
-
component: zt,
|
|
1760
1750
|
...Kt
|
|
1761
1751
|
}, {
|
|
1762
|
-
component:
|
|
1752
|
+
component: Vt,
|
|
1753
|
+
...zt
|
|
1754
|
+
}, {
|
|
1755
|
+
component: ze,
|
|
1763
1756
|
...qt
|
|
1764
1757
|
}, {
|
|
1765
|
-
component:
|
|
1758
|
+
component: qe,
|
|
1766
1759
|
...Yt
|
|
1767
|
-
},
|
|
1760
|
+
}, {
|
|
1761
|
+
component: Ye,
|
|
1762
|
+
...Gt
|
|
1763
|
+
}, {
|
|
1764
|
+
component: Qt,
|
|
1765
|
+
...Jt
|
|
1766
|
+
}, {
|
|
1767
|
+
component: ro,
|
|
1768
|
+
...Xt
|
|
1769
|
+
}, {
|
|
1770
|
+
component: en,
|
|
1771
|
+
...Zt
|
|
1772
|
+
}, ...sn()], So = (e) => ({
|
|
1768
1773
|
type: "builder.registerComponent",
|
|
1769
1774
|
data: D(e)
|
|
1770
|
-
}),
|
|
1775
|
+
}), cn = (e) => {
|
|
1771
1776
|
const t = e.toString().trim();
|
|
1772
1777
|
return `return (${!t.startsWith("function") && !t.startsWith("(") ? "function " : ""}${t}).apply(this, arguments)`;
|
|
1773
|
-
},
|
|
1778
|
+
}, ln = (e) => typeof e == "function" ? cn(e) : O(e), D = ({
|
|
1774
1779
|
inputs: e,
|
|
1775
1780
|
...t
|
|
1776
1781
|
}) => ({
|
|
1777
|
-
...
|
|
1782
|
+
...O(t),
|
|
1778
1783
|
inputs: e == null ? void 0 : e.map((n) => Object.entries(n).reduce((o, [i, r]) => ({
|
|
1779
1784
|
...o,
|
|
1780
|
-
[i]:
|
|
1785
|
+
[i]: ln(r)
|
|
1781
1786
|
}), {}))
|
|
1782
|
-
}),
|
|
1787
|
+
}), dn = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
|
|
1783
1788
|
function getAndSetVariantId() {
|
|
1784
1789
|
function setCookie(name, value, days) {
|
|
1785
1790
|
let expires = '';
|
|
@@ -1835,7 +1840,7 @@ const Jt = {
|
|
|
1835
1840
|
}).join('');
|
|
1836
1841
|
styleEl.innerHTML = newStyleStr;
|
|
1837
1842
|
}
|
|
1838
|
-
}`,
|
|
1843
|
+
}`, un = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
|
|
1839
1844
|
if (!navigator.cookieEnabled) {
|
|
1840
1845
|
return;
|
|
1841
1846
|
}
|
|
@@ -1869,24 +1874,24 @@ const Jt = {
|
|
|
1869
1874
|
thisScriptEl?.remove();
|
|
1870
1875
|
}
|
|
1871
1876
|
return;
|
|
1872
|
-
}`,
|
|
1877
|
+
}`, Te = "builderIoAbTest", Ee = "builderIoRenderContent", W = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
|
|
1873
1878
|
...t,
|
|
1874
1879
|
testVariationId: t.id,
|
|
1875
1880
|
id: e == null ? void 0 : e.id
|
|
1876
|
-
})),
|
|
1881
|
+
})), mn = ({
|
|
1877
1882
|
canTrack: e,
|
|
1878
1883
|
content: t
|
|
1879
|
-
}) => !(!(W(t).length > 0) || !e ||
|
|
1880
|
-
window.${
|
|
1881
|
-
window.${
|
|
1882
|
-
`,
|
|
1883
|
-
window.${
|
|
1884
|
-
"${t}",${JSON.stringify(e)}, ${
|
|
1885
|
-
)`,
|
|
1884
|
+
}) => !(!(W(t).length > 0) || !e || k()), fn = (e) => e === "react" || e === "reactNative", Re = fn(T), hn = () => `
|
|
1885
|
+
window.${Te} = ${dn}
|
|
1886
|
+
window.${Ee} = ${un}
|
|
1887
|
+
`, pn = (e, t) => `
|
|
1888
|
+
window.${Te}(
|
|
1889
|
+
"${t}",${JSON.stringify(e)}, ${Re}
|
|
1890
|
+
)`, gn = ({
|
|
1886
1891
|
contentId: e,
|
|
1887
1892
|
variationId: t
|
|
1888
|
-
}) => `window.${
|
|
1889
|
-
"${t}", "${e}", ${
|
|
1893
|
+
}) => `window.${Ee}(
|
|
1894
|
+
"${t}", "${e}", ${Re}
|
|
1890
1895
|
)`;
|
|
1891
1896
|
function _(e) {
|
|
1892
1897
|
return /* @__PURE__ */ l(
|
|
@@ -1897,61 +1902,61 @@ function _(e) {
|
|
|
1897
1902
|
}
|
|
1898
1903
|
);
|
|
1899
1904
|
}
|
|
1900
|
-
const
|
|
1905
|
+
const bn = (e) => {
|
|
1901
1906
|
const t = e.get("preview"), n = e.get("overrides." + t);
|
|
1902
|
-
return n ||
|
|
1907
|
+
return n || w.warn("No previewed ID found in search params."), n;
|
|
1903
1908
|
};
|
|
1904
|
-
function
|
|
1905
|
-
globalThis._BUILDER_PREVIEW_LRU_CACHE || (globalThis._BUILDER_PREVIEW_LRU_CACHE = new
|
|
1909
|
+
function yn() {
|
|
1910
|
+
globalThis._BUILDER_PREVIEW_LRU_CACHE || (globalThis._BUILDER_PREVIEW_LRU_CACHE = new Oe({
|
|
1906
1911
|
max: 500,
|
|
1907
1912
|
// how long to live in ms
|
|
1908
1913
|
ttl: 1e3 * 60 * 5
|
|
1909
1914
|
}));
|
|
1910
1915
|
}
|
|
1911
|
-
function
|
|
1912
|
-
|
|
1913
|
-
const t =
|
|
1916
|
+
function Sn(e) {
|
|
1917
|
+
yn();
|
|
1918
|
+
const t = bn(e);
|
|
1914
1919
|
return typeof t == "string" ? globalThis._BUILDER_PREVIEW_LRU_CACHE.get(t) : void 0;
|
|
1915
1920
|
}
|
|
1916
|
-
function
|
|
1921
|
+
function vn() {
|
|
1917
1922
|
return typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : globalThis;
|
|
1918
1923
|
}
|
|
1919
|
-
function
|
|
1920
|
-
const e =
|
|
1924
|
+
function kn() {
|
|
1925
|
+
const e = vn().fetch;
|
|
1921
1926
|
if (typeof e > "u")
|
|
1922
1927
|
throw console.warn(`Builder SDK could not find a global fetch function. Make sure you have a polyfill for fetch in your project.
|
|
1923
1928
|
For more information, read https://github.com/BuilderIO/this-package-uses-fetch`), new Error("Builder SDK could not find a global `fetch` function");
|
|
1924
1929
|
return e;
|
|
1925
1930
|
}
|
|
1926
|
-
const
|
|
1927
|
-
function
|
|
1931
|
+
const Cn = kn();
|
|
1932
|
+
function $(e, t = null, n = ".") {
|
|
1928
1933
|
return Object.keys(e).reduce((o, i) => {
|
|
1929
1934
|
const r = e[i], a = [t, i].filter(Boolean).join(n);
|
|
1930
1935
|
return [typeof r == "object", r !== null, !(Array.isArray(r) && r.length === 0)].every(Boolean) ? {
|
|
1931
1936
|
...o,
|
|
1932
|
-
|
|
1937
|
+
...$(r, a, n)
|
|
1933
1938
|
} : {
|
|
1934
1939
|
...o,
|
|
1935
1940
|
[a]: r
|
|
1936
1941
|
};
|
|
1937
1942
|
}, {});
|
|
1938
1943
|
}
|
|
1939
|
-
const
|
|
1944
|
+
const xn = "v3", ne = "builder.", wn = "options.", Pe = (e) => {
|
|
1940
1945
|
if (!e)
|
|
1941
1946
|
return {};
|
|
1942
|
-
const t =
|
|
1947
|
+
const t = de(e), n = {};
|
|
1943
1948
|
return Object.keys(t).forEach((o) => {
|
|
1944
|
-
if (o.startsWith(
|
|
1945
|
-
const i = o.replace(
|
|
1949
|
+
if (o.startsWith(ne)) {
|
|
1950
|
+
const i = o.replace(ne, "").replace(wn, "");
|
|
1946
1951
|
n[i] = t[o];
|
|
1947
1952
|
}
|
|
1948
1953
|
}), n;
|
|
1949
|
-
},
|
|
1950
|
-
if (!
|
|
1954
|
+
}, In = () => {
|
|
1955
|
+
if (!k())
|
|
1951
1956
|
return {};
|
|
1952
1957
|
const e = new URLSearchParams(window.location.search);
|
|
1953
|
-
return
|
|
1954
|
-
},
|
|
1958
|
+
return Pe(e);
|
|
1959
|
+
}, oe = (e) => typeof e == "number" && !isNaN(e) && e >= 0, q = (e) => {
|
|
1955
1960
|
const {
|
|
1956
1961
|
limit: t = 30,
|
|
1957
1962
|
userAttributes: n,
|
|
@@ -1960,175 +1965,175 @@ const yn = "v3", ee = "builder.", Sn = "options.", Ee = (e) => {
|
|
|
1960
1965
|
apiKey: r,
|
|
1961
1966
|
enrich: a,
|
|
1962
1967
|
locale: s,
|
|
1963
|
-
apiVersion: c =
|
|
1964
|
-
fields:
|
|
1965
|
-
omit:
|
|
1966
|
-
offset:
|
|
1967
|
-
cacheSeconds:
|
|
1968
|
-
staleCacheSeconds:
|
|
1969
|
-
sort:
|
|
1970
|
-
includeUnpublished:
|
|
1968
|
+
apiVersion: c = xn,
|
|
1969
|
+
fields: u,
|
|
1970
|
+
omit: h,
|
|
1971
|
+
offset: d,
|
|
1972
|
+
cacheSeconds: f,
|
|
1973
|
+
staleCacheSeconds: g,
|
|
1974
|
+
sort: v,
|
|
1975
|
+
includeUnpublished: b
|
|
1971
1976
|
} = e;
|
|
1972
1977
|
if (!r)
|
|
1973
1978
|
throw new Error("Missing API key");
|
|
1974
1979
|
if (!["v3"].includes(c))
|
|
1975
1980
|
throw new Error(`Invalid apiVersion: expected 'v3', received '${c}'`);
|
|
1976
|
-
const
|
|
1977
|
-
if (
|
|
1978
|
-
const S =
|
|
1979
|
-
sort:
|
|
1981
|
+
const E = t !== 1, m = new URL(`https://cdn.builder.io/api/${c}/content/${i}`);
|
|
1982
|
+
if (m.searchParams.set("apiKey", r), m.searchParams.set("limit", String(t)), m.searchParams.set("noTraverse", String(E)), m.searchParams.set("includeRefs", String(!0)), s && m.searchParams.set("locale", s), a && m.searchParams.set("enrich", String(a)), m.searchParams.set("omit", h || "meta.componentsUsed"), u && m.searchParams.set("fields", u), Number.isFinite(d) && d > -1 && m.searchParams.set("offset", String(Math.floor(d))), typeof b == "boolean" && m.searchParams.set("includeUnpublished", String(b)), f && oe(f) && m.searchParams.set("cacheSeconds", String(f)), g && oe(g) && m.searchParams.set("staleCacheSeconds", String(g)), v) {
|
|
1983
|
+
const S = $({
|
|
1984
|
+
sort: v
|
|
1980
1985
|
});
|
|
1981
|
-
for (const
|
|
1982
|
-
|
|
1986
|
+
for (const x in S)
|
|
1987
|
+
m.searchParams.set(x, JSON.stringify(S[x]));
|
|
1983
1988
|
}
|
|
1984
|
-
const
|
|
1985
|
-
...
|
|
1986
|
-
...
|
|
1987
|
-
},
|
|
1988
|
-
for (const S in
|
|
1989
|
-
|
|
1990
|
-
if (n &&
|
|
1991
|
-
const S =
|
|
1989
|
+
const p = {
|
|
1990
|
+
...In(),
|
|
1991
|
+
...de(e.options || {})
|
|
1992
|
+
}, y = $(p);
|
|
1993
|
+
for (const S in y)
|
|
1994
|
+
m.searchParams.set(S, String(y[S]));
|
|
1995
|
+
if (n && m.searchParams.set("userAttributes", JSON.stringify(n)), o) {
|
|
1996
|
+
const S = $({
|
|
1992
1997
|
query: o
|
|
1993
1998
|
});
|
|
1994
|
-
for (const
|
|
1995
|
-
|
|
1999
|
+
for (const x in S)
|
|
2000
|
+
m.searchParams.set(x, JSON.stringify(S[x]));
|
|
1996
2001
|
}
|
|
1997
|
-
return
|
|
1998
|
-
},
|
|
1999
|
-
async function
|
|
2000
|
-
const t = await
|
|
2002
|
+
return m;
|
|
2003
|
+
}, Tn = (e) => "results" in e;
|
|
2004
|
+
async function Ae(e) {
|
|
2005
|
+
const t = await Pn({
|
|
2001
2006
|
...e,
|
|
2002
2007
|
limit: 1
|
|
2003
2008
|
});
|
|
2004
2009
|
return t && t[0] || null;
|
|
2005
2010
|
}
|
|
2006
|
-
const
|
|
2011
|
+
const En = async (e) => {
|
|
2007
2012
|
const t = q(e);
|
|
2008
|
-
return await (await (e.fetch ??
|
|
2009
|
-
},
|
|
2013
|
+
return await (await (e.fetch ?? Cn)(t.href, e.fetchOptions)).json();
|
|
2014
|
+
}, Rn = async (e, t, n = q(e)) => {
|
|
2010
2015
|
const o = U(e.canTrack);
|
|
2011
2016
|
if (n.search.includes("preview=")) {
|
|
2012
2017
|
const r = [];
|
|
2013
2018
|
for (const a of t.results) {
|
|
2014
|
-
const s =
|
|
2019
|
+
const s = Sn(n.searchParams);
|
|
2015
2020
|
r.push(s || a);
|
|
2016
2021
|
}
|
|
2017
2022
|
t.results = r;
|
|
2018
2023
|
}
|
|
2019
|
-
if (!o || !(
|
|
2024
|
+
if (!o || !(k() || T === "reactNative"))
|
|
2020
2025
|
return t.results;
|
|
2021
2026
|
try {
|
|
2022
2027
|
const r = [];
|
|
2023
2028
|
for (const a of t.results)
|
|
2024
|
-
r.push(await
|
|
2029
|
+
r.push(await Ht({
|
|
2025
2030
|
item: a,
|
|
2026
2031
|
canTrack: o
|
|
2027
2032
|
}));
|
|
2028
2033
|
t.results = r;
|
|
2029
2034
|
} catch (r) {
|
|
2030
|
-
|
|
2035
|
+
w.error("Could not process A/B tests. ", r);
|
|
2031
2036
|
}
|
|
2032
2037
|
return t.results;
|
|
2033
2038
|
};
|
|
2034
|
-
async function
|
|
2039
|
+
async function Pn(e) {
|
|
2035
2040
|
try {
|
|
2036
|
-
const t = q(e), n = await
|
|
2037
|
-
return
|
|
2041
|
+
const t = q(e), n = await En(e);
|
|
2042
|
+
return Tn(n) ? Rn(e, n) : (w.error("Error fetching data. ", {
|
|
2038
2043
|
url: t,
|
|
2039
2044
|
content: n,
|
|
2040
2045
|
options: e
|
|
2041
2046
|
}), null);
|
|
2042
2047
|
} catch (t) {
|
|
2043
|
-
return
|
|
2048
|
+
return w.error("Error fetching data. ", t), null;
|
|
2044
2049
|
}
|
|
2045
2050
|
}
|
|
2046
|
-
function
|
|
2047
|
-
const t = e || (
|
|
2048
|
-
return t ?
|
|
2051
|
+
function vo(e) {
|
|
2052
|
+
const t = e || (k() ? window.location.search : void 0);
|
|
2053
|
+
return t ? ue(t).indexOf("builder.preview=") !== -1 : !1;
|
|
2049
2054
|
}
|
|
2050
|
-
function
|
|
2055
|
+
function An() {
|
|
2051
2056
|
return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(e) {
|
|
2052
2057
|
const t = Math.random() * 16 | 0;
|
|
2053
2058
|
return (e == "x" ? t : t & 3 | 8).toString(16);
|
|
2054
2059
|
});
|
|
2055
2060
|
}
|
|
2056
|
-
function
|
|
2057
|
-
return
|
|
2061
|
+
function Ve() {
|
|
2062
|
+
return An().replace(/-/g, "");
|
|
2058
2063
|
}
|
|
2059
|
-
const
|
|
2064
|
+
const Be = "builderSessionId", Vn = async ({
|
|
2060
2065
|
canTrack: e
|
|
2061
2066
|
}) => {
|
|
2062
2067
|
if (!e)
|
|
2063
2068
|
return;
|
|
2064
|
-
const t = await
|
|
2065
|
-
name:
|
|
2069
|
+
const t = await ke({
|
|
2070
|
+
name: Be,
|
|
2066
2071
|
canTrack: e
|
|
2067
2072
|
});
|
|
2068
2073
|
if (I(t))
|
|
2069
2074
|
return t;
|
|
2070
2075
|
{
|
|
2071
|
-
const n =
|
|
2072
|
-
return
|
|
2076
|
+
const n = Bn();
|
|
2077
|
+
return Wn({
|
|
2073
2078
|
id: n,
|
|
2074
2079
|
canTrack: e
|
|
2075
2080
|
}), n;
|
|
2076
2081
|
}
|
|
2077
|
-
},
|
|
2082
|
+
}, Bn = () => Ve(), Wn = ({
|
|
2078
2083
|
id: e,
|
|
2079
2084
|
canTrack: t
|
|
2080
|
-
}) =>
|
|
2081
|
-
name:
|
|
2085
|
+
}) => Ce({
|
|
2086
|
+
name: Be,
|
|
2082
2087
|
value: e,
|
|
2083
2088
|
canTrack: t
|
|
2084
|
-
}),
|
|
2089
|
+
}), We = () => k() && typeof localStorage < "u" ? localStorage : void 0, $n = ({
|
|
2085
2090
|
key: e,
|
|
2086
2091
|
canTrack: t
|
|
2087
2092
|
}) => {
|
|
2088
2093
|
var n;
|
|
2089
2094
|
try {
|
|
2090
|
-
return t ? (n =
|
|
2095
|
+
return t ? (n = We()) == null ? void 0 : n.getItem(e) : void 0;
|
|
2091
2096
|
} catch (o) {
|
|
2092
2097
|
console.debug("[LocalStorage] GET error: ", o);
|
|
2093
2098
|
return;
|
|
2094
2099
|
}
|
|
2095
|
-
},
|
|
2100
|
+
}, Nn = ({
|
|
2096
2101
|
key: e,
|
|
2097
2102
|
canTrack: t,
|
|
2098
2103
|
value: n
|
|
2099
2104
|
}) => {
|
|
2100
2105
|
var o;
|
|
2101
2106
|
try {
|
|
2102
|
-
t && ((o =
|
|
2107
|
+
t && ((o = We()) == null || o.setItem(e, n));
|
|
2103
2108
|
} catch (i) {
|
|
2104
2109
|
console.debug("[LocalStorage] SET error: ", i);
|
|
2105
2110
|
}
|
|
2106
|
-
},
|
|
2111
|
+
}, $e = "builderVisitorId", On = ({
|
|
2107
2112
|
canTrack: e
|
|
2108
2113
|
}) => {
|
|
2109
2114
|
if (!e)
|
|
2110
2115
|
return;
|
|
2111
|
-
const t =
|
|
2112
|
-
key:
|
|
2116
|
+
const t = $n({
|
|
2117
|
+
key: $e,
|
|
2113
2118
|
canTrack: e
|
|
2114
2119
|
});
|
|
2115
2120
|
if (I(t))
|
|
2116
2121
|
return t;
|
|
2117
2122
|
{
|
|
2118
|
-
const n =
|
|
2119
|
-
return
|
|
2123
|
+
const n = Fn();
|
|
2124
|
+
return Ln({
|
|
2120
2125
|
id: n,
|
|
2121
2126
|
canTrack: e
|
|
2122
2127
|
}), n;
|
|
2123
2128
|
}
|
|
2124
|
-
},
|
|
2129
|
+
}, Fn = () => Ve(), Ln = ({
|
|
2125
2130
|
id: e,
|
|
2126
2131
|
canTrack: t
|
|
2127
|
-
}) =>
|
|
2128
|
-
key:
|
|
2132
|
+
}) => Nn({
|
|
2133
|
+
key: $e,
|
|
2129
2134
|
value: e,
|
|
2130
2135
|
canTrack: t
|
|
2131
|
-
}),
|
|
2136
|
+
}), Un = async ({
|
|
2132
2137
|
canTrack: e
|
|
2133
2138
|
}) => {
|
|
2134
2139
|
if (!e)
|
|
@@ -2136,16 +2141,16 @@ const Ae = "builderSessionId", Tn = async ({
|
|
|
2136
2141
|
visitorId: void 0,
|
|
2137
2142
|
sessionId: void 0
|
|
2138
2143
|
};
|
|
2139
|
-
const t = await
|
|
2144
|
+
const t = await Vn({
|
|
2140
2145
|
canTrack: e
|
|
2141
|
-
}), n =
|
|
2146
|
+
}), n = On({
|
|
2142
2147
|
canTrack: e
|
|
2143
2148
|
});
|
|
2144
2149
|
return {
|
|
2145
2150
|
sessionId: t,
|
|
2146
2151
|
visitorId: n
|
|
2147
2152
|
};
|
|
2148
|
-
},
|
|
2153
|
+
}, Dn = async ({
|
|
2149
2154
|
type: e,
|
|
2150
2155
|
canTrack: t,
|
|
2151
2156
|
apiKey: n,
|
|
@@ -2159,23 +2164,23 @@ const Ae = "builderSessionId", Tn = async ({
|
|
|
2159
2164
|
url: location.href,
|
|
2160
2165
|
...o
|
|
2161
2166
|
},
|
|
2162
|
-
...await
|
|
2167
|
+
...await Un({
|
|
2163
2168
|
canTrack: t
|
|
2164
2169
|
}),
|
|
2165
|
-
userAttributes:
|
|
2170
|
+
userAttributes: fe(),
|
|
2166
2171
|
ownerId: n
|
|
2167
2172
|
}
|
|
2168
2173
|
});
|
|
2169
|
-
async function
|
|
2174
|
+
async function _n(e) {
|
|
2170
2175
|
if (!e.apiKey) {
|
|
2171
|
-
|
|
2176
|
+
w.error("Missing API key for track call. Please provide your API key.");
|
|
2172
2177
|
return;
|
|
2173
2178
|
}
|
|
2174
|
-
if (e.canTrack && !
|
|
2179
|
+
if (e.canTrack && !me() && (k() || T === "reactNative"))
|
|
2175
2180
|
return fetch("https://cdn.builder.io/api/v1/track", {
|
|
2176
2181
|
method: "POST",
|
|
2177
2182
|
body: JSON.stringify({
|
|
2178
|
-
events: [await
|
|
2183
|
+
events: [await Dn(e)]
|
|
2179
2184
|
}),
|
|
2180
2185
|
headers: {
|
|
2181
2186
|
"content-type": "application/json"
|
|
@@ -2185,14 +2190,14 @@ async function Nn(e) {
|
|
|
2185
2190
|
console.error("Failed to track: ", t);
|
|
2186
2191
|
});
|
|
2187
2192
|
}
|
|
2188
|
-
const
|
|
2193
|
+
const ko = (e) => _n({
|
|
2189
2194
|
...e,
|
|
2190
2195
|
canTrack: !0
|
|
2191
2196
|
});
|
|
2192
|
-
function
|
|
2197
|
+
function ie(e) {
|
|
2193
2198
|
return Math.round(e * 1e3) / 1e3;
|
|
2194
2199
|
}
|
|
2195
|
-
const
|
|
2200
|
+
const Mn = (e, t, n = !0) => {
|
|
2196
2201
|
if (!(e instanceof HTMLElement))
|
|
2197
2202
|
return null;
|
|
2198
2203
|
let o = n ? e : e.parentElement;
|
|
@@ -2203,43 +2208,43 @@ const Fn = (e, t, n = !0) => {
|
|
|
2203
2208
|
return o;
|
|
2204
2209
|
} while (o = o.parentElement);
|
|
2205
2210
|
return null;
|
|
2206
|
-
},
|
|
2211
|
+
}, jn = (e) => Mn(e, (t) => {
|
|
2207
2212
|
const n = t.getAttribute("builder-id") || t.id;
|
|
2208
2213
|
return (n == null ? void 0 : n.indexOf("builder-")) === 0;
|
|
2209
|
-
}),
|
|
2214
|
+
}), re = ({
|
|
2210
2215
|
event: e,
|
|
2211
2216
|
target: t
|
|
2212
2217
|
}) => {
|
|
2213
|
-
const n = t.getBoundingClientRect(), o = e.clientX - n.left, i = e.clientY - n.top, r =
|
|
2218
|
+
const n = t.getBoundingClientRect(), o = e.clientX - n.left, i = e.clientY - n.top, r = ie(o / n.width), a = ie(i / n.height);
|
|
2214
2219
|
return {
|
|
2215
2220
|
x: r,
|
|
2216
2221
|
y: a
|
|
2217
2222
|
};
|
|
2218
|
-
},
|
|
2219
|
-
const t = e.target, n = t &&
|
|
2223
|
+
}, Co = (e) => {
|
|
2224
|
+
const t = e.target, n = t && jn(t), o = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
|
|
2220
2225
|
return {
|
|
2221
2226
|
targetBuilderElement: o || void 0,
|
|
2222
2227
|
metadata: {
|
|
2223
|
-
targetOffset: t ?
|
|
2228
|
+
targetOffset: t ? re({
|
|
2224
2229
|
event: e,
|
|
2225
2230
|
target: t
|
|
2226
2231
|
}) : void 0,
|
|
2227
|
-
builderTargetOffset: n ?
|
|
2232
|
+
builderTargetOffset: n ? re({
|
|
2228
2233
|
event: e,
|
|
2229
2234
|
target: n
|
|
2230
2235
|
}) : void 0,
|
|
2231
2236
|
builderElementIndex: n && o ? [].slice.call(document.getElementsByClassName(o)).indexOf(n) : void 0
|
|
2232
2237
|
}
|
|
2233
2238
|
};
|
|
2234
|
-
},
|
|
2235
|
-
function
|
|
2239
|
+
}, Hn = ["*.beta.builder.io", "beta.builder.io", "builder.io", "localhost", "qa.builder.io"];
|
|
2240
|
+
function Ne(e, t) {
|
|
2236
2241
|
const n = new URL(t.origin), o = n.hostname;
|
|
2237
|
-
return (e ||
|
|
2242
|
+
return (e || Hn).findIndex((i) => i.startsWith("*.") ? o.endsWith(i.slice(1)) : i === o) > -1;
|
|
2238
2243
|
}
|
|
2239
|
-
const
|
|
2240
|
-
function
|
|
2241
|
-
let n =
|
|
2242
|
-
if (n || (n =
|
|
2244
|
+
const Kn = "0.14.19", ae = {};
|
|
2245
|
+
function zn(e, t) {
|
|
2246
|
+
let n = ae[e];
|
|
2247
|
+
if (n || (n = ae[e] = []), n.push(t), k()) {
|
|
2243
2248
|
const o = {
|
|
2244
2249
|
type: "builder.register",
|
|
2245
2250
|
data: {
|
|
@@ -2254,8 +2259,8 @@ function _n(e, t) {
|
|
|
2254
2259
|
}
|
|
2255
2260
|
}
|
|
2256
2261
|
}
|
|
2257
|
-
const
|
|
2258
|
-
|
|
2262
|
+
const xo = () => {
|
|
2263
|
+
zn("insertMenu", {
|
|
2259
2264
|
name: "_default",
|
|
2260
2265
|
default: !0,
|
|
2261
2266
|
items: [{
|
|
@@ -2277,14 +2282,14 @@ const bo = () => {
|
|
|
2277
2282
|
}]
|
|
2278
2283
|
});
|
|
2279
2284
|
};
|
|
2280
|
-
let
|
|
2281
|
-
const
|
|
2285
|
+
let se = !1;
|
|
2286
|
+
const qn = (e = {}) => {
|
|
2282
2287
|
var t, n;
|
|
2283
|
-
|
|
2288
|
+
se || (se = !0, k() && ((t = window.parent) == null || t.postMessage({
|
|
2284
2289
|
type: "builder.sdkInfo",
|
|
2285
2290
|
data: {
|
|
2286
|
-
target:
|
|
2287
|
-
version:
|
|
2291
|
+
target: T,
|
|
2292
|
+
version: Kn,
|
|
2288
2293
|
supportsPatchUpdates: !1,
|
|
2289
2294
|
// Supports builder-model="..." attribute which is needed to
|
|
2290
2295
|
// scope our '+ add block' button styling
|
|
@@ -2298,7 +2303,7 @@ const Mn = (e = {}) => {
|
|
|
2298
2303
|
}
|
|
2299
2304
|
}, "*"), window.addEventListener("message", (o) => {
|
|
2300
2305
|
var r, a;
|
|
2301
|
-
if (!
|
|
2306
|
+
if (!Ne(e.trustedHosts, o))
|
|
2302
2307
|
return;
|
|
2303
2308
|
const {
|
|
2304
2309
|
data: i
|
|
@@ -2306,45 +2311,45 @@ const Mn = (e = {}) => {
|
|
|
2306
2311
|
if (i != null && i.type)
|
|
2307
2312
|
switch (i.type) {
|
|
2308
2313
|
case "builder.evaluate": {
|
|
2309
|
-
const s = i.data.text, c = i.data.arguments || [],
|
|
2310
|
-
let
|
|
2314
|
+
const s = i.data.text, c = i.data.arguments || [], u = i.data.id, h = new Function(s);
|
|
2315
|
+
let d, f = null;
|
|
2311
2316
|
try {
|
|
2312
|
-
|
|
2313
|
-
} catch (
|
|
2314
|
-
|
|
2317
|
+
d = h.apply(null, c);
|
|
2318
|
+
} catch (g) {
|
|
2319
|
+
f = g;
|
|
2315
2320
|
}
|
|
2316
|
-
|
|
2321
|
+
f ? (r = window.parent) == null || r.postMessage({
|
|
2317
2322
|
type: "builder.evaluateError",
|
|
2318
2323
|
data: {
|
|
2319
|
-
id:
|
|
2320
|
-
error:
|
|
2324
|
+
id: u,
|
|
2325
|
+
error: f.message
|
|
2321
2326
|
}
|
|
2322
|
-
}, "*") :
|
|
2323
|
-
var
|
|
2324
|
-
(
|
|
2327
|
+
}, "*") : d && typeof d.then == "function" ? d.then((g) => {
|
|
2328
|
+
var v;
|
|
2329
|
+
(v = window.parent) == null || v.postMessage({
|
|
2325
2330
|
type: "builder.evaluateResult",
|
|
2326
2331
|
data: {
|
|
2327
|
-
id:
|
|
2328
|
-
result:
|
|
2332
|
+
id: u,
|
|
2333
|
+
result: g
|
|
2329
2334
|
}
|
|
2330
2335
|
}, "*");
|
|
2331
2336
|
}).catch(console.error) : (a = window.parent) == null || a.postMessage({
|
|
2332
2337
|
type: "builder.evaluateResult",
|
|
2333
2338
|
data: {
|
|
2334
|
-
result:
|
|
2335
|
-
id:
|
|
2339
|
+
result: d,
|
|
2340
|
+
id: u
|
|
2336
2341
|
}
|
|
2337
2342
|
}, "*");
|
|
2338
2343
|
break;
|
|
2339
2344
|
}
|
|
2340
2345
|
}
|
|
2341
2346
|
})));
|
|
2342
|
-
},
|
|
2347
|
+
}, Yn = ({
|
|
2343
2348
|
model: e,
|
|
2344
2349
|
trustedHosts: t,
|
|
2345
2350
|
callbacks: n
|
|
2346
2351
|
}) => (o) => {
|
|
2347
|
-
if (!
|
|
2352
|
+
if (!Ne(t, o))
|
|
2348
2353
|
return;
|
|
2349
2354
|
const {
|
|
2350
2355
|
data: i
|
|
@@ -2365,12 +2370,12 @@ const Mn = (e = {}) => {
|
|
|
2365
2370
|
break;
|
|
2366
2371
|
}
|
|
2367
2372
|
}
|
|
2368
|
-
},
|
|
2369
|
-
if (!
|
|
2370
|
-
return
|
|
2373
|
+
}, wo = (e, t, n) => {
|
|
2374
|
+
if (!k)
|
|
2375
|
+
return w.warn("`subscribeToEditor` only works in the browser. It currently seems to be running on the server."), () => {
|
|
2371
2376
|
};
|
|
2372
|
-
|
|
2373
|
-
const o =
|
|
2377
|
+
qn();
|
|
2378
|
+
const o = Yn({
|
|
2374
2379
|
callbacks: {
|
|
2375
2380
|
contentUpdate: t,
|
|
2376
2381
|
animation: () => {
|
|
@@ -2384,7 +2389,7 @@ const Mn = (e = {}) => {
|
|
|
2384
2389
|
return window.addEventListener("message", o), () => {
|
|
2385
2390
|
window.removeEventListener("message", o);
|
|
2386
2391
|
};
|
|
2387
|
-
},
|
|
2392
|
+
}, Gn = (e) => {
|
|
2388
2393
|
var r;
|
|
2389
2394
|
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], o = e.fileUrl ?? ((r = e == null ? void 0 : e.files) == null ? void 0 : r.regular);
|
|
2390
2395
|
let i = "";
|
|
@@ -2410,15 +2415,15 @@ font-weight: ${a};
|
|
|
2410
2415
|
`.trim());
|
|
2411
2416
|
}
|
|
2412
2417
|
return i;
|
|
2413
|
-
},
|
|
2418
|
+
}, Jn = ({
|
|
2414
2419
|
customFonts: e
|
|
2415
2420
|
}) => {
|
|
2416
2421
|
var t;
|
|
2417
|
-
return ((t = e == null ? void 0 : e.map((n) =>
|
|
2418
|
-
},
|
|
2422
|
+
return ((t = e == null ? void 0 : e.map((n) => Gn(n))) == null ? void 0 : t.join(" ")) || "";
|
|
2423
|
+
}, Qn = ({
|
|
2419
2424
|
cssCode: e,
|
|
2420
2425
|
contentId: t
|
|
2421
|
-
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "",
|
|
2426
|
+
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", Xn = `
|
|
2422
2427
|
.builder-button {
|
|
2423
2428
|
all: unset;
|
|
2424
2429
|
}
|
|
@@ -2435,21 +2440,21 @@ font-weight: ${a};
|
|
|
2435
2440
|
text-align: inherit;
|
|
2436
2441
|
font-family: inherit;
|
|
2437
2442
|
}
|
|
2438
|
-
`,
|
|
2439
|
-
function
|
|
2443
|
+
`, Zn = (e) => e ? "" : Xn, Io = (e) => `variant-${e}`;
|
|
2444
|
+
function eo(e) {
|
|
2440
2445
|
const t = `
|
|
2441
|
-
${
|
|
2446
|
+
${Qn({
|
|
2442
2447
|
cssCode: e.cssCode,
|
|
2443
2448
|
contentId: e.contentId
|
|
2444
2449
|
})}
|
|
2445
|
-
${
|
|
2450
|
+
${Jn({
|
|
2446
2451
|
customFonts: e.customFonts
|
|
2447
2452
|
})}
|
|
2448
|
-
${
|
|
2453
|
+
${Zn(e.isNestedRender)}
|
|
2449
2454
|
`.trim();
|
|
2450
2455
|
return /* @__PURE__ */ l(F, { id: "builderio-content", styles: t });
|
|
2451
2456
|
}
|
|
2452
|
-
const
|
|
2457
|
+
const to = ({
|
|
2453
2458
|
content: e,
|
|
2454
2459
|
data: t,
|
|
2455
2460
|
locale: n
|
|
@@ -2466,7 +2471,7 @@ const Jn = ({
|
|
|
2466
2471
|
locale: n
|
|
2467
2472
|
} : {}
|
|
2468
2473
|
};
|
|
2469
|
-
},
|
|
2474
|
+
}, no = ({
|
|
2470
2475
|
content: e,
|
|
2471
2476
|
data: t
|
|
2472
2477
|
}) => e ? {
|
|
@@ -2477,32 +2482,32 @@ const Jn = ({
|
|
|
2477
2482
|
},
|
|
2478
2483
|
meta: e == null ? void 0 : e.meta
|
|
2479
2484
|
} : void 0;
|
|
2480
|
-
function
|
|
2481
|
-
var i, r, a, s, c,
|
|
2482
|
-
const t =
|
|
2485
|
+
function ce(e) {
|
|
2486
|
+
var i, r, a, s, c, u, h, d, f;
|
|
2487
|
+
const t = gn({
|
|
2483
2488
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2484
2489
|
variationId: (i = e.content) == null ? void 0 : i.testVariationId,
|
|
2485
2490
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2486
2491
|
contentId: (r = e.content) == null ? void 0 : r.id
|
|
2487
2492
|
}), n = [
|
|
2488
|
-
...
|
|
2493
|
+
...te(),
|
|
2489
2494
|
...e.customComponents || []
|
|
2490
2495
|
].reduce(
|
|
2491
|
-
(
|
|
2492
|
-
...
|
|
2493
|
-
[
|
|
2494
|
-
component:
|
|
2495
|
-
...D(
|
|
2496
|
+
(g, { component: v, ...b }) => ({
|
|
2497
|
+
...g,
|
|
2498
|
+
[b.name]: {
|
|
2499
|
+
component: v,
|
|
2500
|
+
...D(b)
|
|
2496
2501
|
}
|
|
2497
2502
|
}),
|
|
2498
2503
|
{}
|
|
2499
2504
|
), o = {
|
|
2500
|
-
content:
|
|
2505
|
+
content: no({
|
|
2501
2506
|
content: e.content,
|
|
2502
2507
|
data: e.data
|
|
2503
2508
|
}),
|
|
2504
2509
|
localState: void 0,
|
|
2505
|
-
rootState:
|
|
2510
|
+
rootState: to({
|
|
2506
2511
|
content: e.content,
|
|
2507
2512
|
data: e.data,
|
|
2508
2513
|
locale: e.locale
|
|
@@ -2512,12 +2517,12 @@ function ae(e) {
|
|
|
2512
2517
|
apiKey: e.apiKey,
|
|
2513
2518
|
apiVersion: e.apiVersion,
|
|
2514
2519
|
componentInfos: [
|
|
2515
|
-
...
|
|
2520
|
+
...te(),
|
|
2516
2521
|
...e.customComponents || []
|
|
2517
2522
|
].reduce(
|
|
2518
|
-
(
|
|
2519
|
-
...
|
|
2520
|
-
[
|
|
2523
|
+
(g, { component: v, ...b }) => ({
|
|
2524
|
+
...g,
|
|
2525
|
+
[b.name]: D(b)
|
|
2521
2526
|
}),
|
|
2522
2527
|
{}
|
|
2523
2528
|
),
|
|
@@ -2526,7 +2531,7 @@ function ae(e) {
|
|
|
2526
2531
|
BlocksWrapperProps: e.blocksWrapperProps || {}
|
|
2527
2532
|
};
|
|
2528
2533
|
return /* @__PURE__ */ R(
|
|
2529
|
-
|
|
2534
|
+
Ge,
|
|
2530
2535
|
{
|
|
2531
2536
|
content: e.content,
|
|
2532
2537
|
data: e.data,
|
|
@@ -2551,18 +2556,18 @@ function ae(e) {
|
|
|
2551
2556
|
}
|
|
2552
2557
|
) : null,
|
|
2553
2558
|
/* @__PURE__ */ l(
|
|
2554
|
-
|
|
2559
|
+
eo,
|
|
2555
2560
|
{
|
|
2556
2561
|
isNestedRender: e.isNestedRender,
|
|
2557
2562
|
contentId: (a = o.content) == null ? void 0 : a.id,
|
|
2558
2563
|
cssCode: (c = (s = o.content) == null ? void 0 : s.data) == null ? void 0 : c.cssCode,
|
|
2559
|
-
customFonts: (
|
|
2564
|
+
customFonts: (h = (u = o.content) == null ? void 0 : u.data) == null ? void 0 : h.customFonts
|
|
2560
2565
|
}
|
|
2561
2566
|
),
|
|
2562
2567
|
/* @__PURE__ */ l(
|
|
2563
2568
|
K,
|
|
2564
2569
|
{
|
|
2565
|
-
blocks: (
|
|
2570
|
+
blocks: (f = (d = o.content) == null ? void 0 : d.data) == null ? void 0 : f.blocks,
|
|
2566
2571
|
context: o,
|
|
2567
2572
|
registeredComponents: n,
|
|
2568
2573
|
linkComponent: e.linkComponent
|
|
@@ -2572,14 +2577,14 @@ function ae(e) {
|
|
|
2572
2577
|
}
|
|
2573
2578
|
);
|
|
2574
2579
|
}
|
|
2575
|
-
function
|
|
2580
|
+
function oo(e) {
|
|
2576
2581
|
var r;
|
|
2577
|
-
const t =
|
|
2582
|
+
const t = mn({
|
|
2578
2583
|
canTrack: U(e.canTrack),
|
|
2579
2584
|
content: e.content
|
|
2580
2585
|
}), n = function() {
|
|
2581
2586
|
var s;
|
|
2582
|
-
return
|
|
2587
|
+
return pn(
|
|
2583
2588
|
W(e.content).map((c) => ({
|
|
2584
2589
|
id: c.testVariationId,
|
|
2585
2590
|
testRatio: c.testRatio
|
|
@@ -2593,20 +2598,20 @@ function Xn(e) {
|
|
|
2593
2598
|
return t ? {
|
|
2594
2599
|
...e.content,
|
|
2595
2600
|
testVariationId: (s = e.content) == null ? void 0 : s.id
|
|
2596
|
-
} :
|
|
2601
|
+
} : jt({
|
|
2597
2602
|
item: e.content,
|
|
2598
2603
|
canTrack: U(e.canTrack)
|
|
2599
2604
|
});
|
|
2600
2605
|
};
|
|
2601
|
-
return /* @__PURE__ */ R(
|
|
2602
|
-
!e.isNestedRender &&
|
|
2606
|
+
return /* @__PURE__ */ R(C, { children: [
|
|
2607
|
+
!e.isNestedRender && T !== "reactNative" ? /* @__PURE__ */ l(
|
|
2603
2608
|
_,
|
|
2604
2609
|
{
|
|
2605
2610
|
id: "builderio-init-variants-fns",
|
|
2606
|
-
scriptStr:
|
|
2611
|
+
scriptStr: hn()
|
|
2607
2612
|
}
|
|
2608
2613
|
) : null,
|
|
2609
|
-
t ? /* @__PURE__ */ R(
|
|
2614
|
+
t ? /* @__PURE__ */ R(C, { children: [
|
|
2610
2615
|
/* @__PURE__ */ l(
|
|
2611
2616
|
F,
|
|
2612
2617
|
{
|
|
@@ -2622,7 +2627,7 @@ function Xn(e) {
|
|
|
2622
2627
|
}
|
|
2623
2628
|
),
|
|
2624
2629
|
(r = W(e.content)) == null ? void 0 : r.map((a) => /* @__PURE__ */ l(
|
|
2625
|
-
|
|
2630
|
+
ce,
|
|
2626
2631
|
{
|
|
2627
2632
|
isNestedRender: e.isNestedRender,
|
|
2628
2633
|
content: a,
|
|
@@ -2648,7 +2653,7 @@ function Xn(e) {
|
|
|
2648
2653
|
))
|
|
2649
2654
|
] }) : null,
|
|
2650
2655
|
/* @__PURE__ */ l(
|
|
2651
|
-
|
|
2656
|
+
ce,
|
|
2652
2657
|
{
|
|
2653
2658
|
isNestedRender: e.isNestedRender,
|
|
2654
2659
|
content: i(),
|
|
@@ -2673,13 +2678,13 @@ function Xn(e) {
|
|
|
2673
2678
|
)
|
|
2674
2679
|
] });
|
|
2675
2680
|
}
|
|
2676
|
-
const
|
|
2681
|
+
const io = async ({
|
|
2677
2682
|
builderContextValue: e,
|
|
2678
2683
|
symbol: t
|
|
2679
2684
|
}) => {
|
|
2680
2685
|
if (t != null && t.model && // This is a hack, we should not need to check for this, but it is needed for Svelte.
|
|
2681
2686
|
(e != null && e.apiKey))
|
|
2682
|
-
return
|
|
2687
|
+
return Ae({
|
|
2683
2688
|
model: t.model,
|
|
2684
2689
|
apiKey: e.apiKey,
|
|
2685
2690
|
apiVersion: e.apiVersion,
|
|
@@ -2689,59 +2694,63 @@ const Zn = async ({
|
|
|
2689
2694
|
}
|
|
2690
2695
|
}
|
|
2691
2696
|
}).catch((n) => {
|
|
2692
|
-
|
|
2697
|
+
w.error("Could not fetch symbol content: ", n);
|
|
2693
2698
|
});
|
|
2694
2699
|
};
|
|
2695
|
-
async function
|
|
2696
|
-
var
|
|
2700
|
+
async function ro(e) {
|
|
2701
|
+
var r, a, s, c, u;
|
|
2697
2702
|
const t = function() {
|
|
2698
|
-
|
|
2703
|
+
return "div";
|
|
2704
|
+
}, n = function() {
|
|
2705
|
+
return "div";
|
|
2706
|
+
}, o = function() {
|
|
2707
|
+
var d, f;
|
|
2699
2708
|
return [
|
|
2700
2709
|
e.attributes[M()],
|
|
2701
2710
|
"builder-symbol",
|
|
2702
|
-
(
|
|
2703
|
-
(
|
|
2711
|
+
(d = e.symbol) != null && d.inline ? "builder-inline-symbol" : void 0,
|
|
2712
|
+
(f = e.symbol) != null && f.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
|
|
2704
2713
|
].filter(Boolean).join(" ");
|
|
2705
|
-
},
|
|
2714
|
+
}, i = ((r = e.symbol) == null ? void 0 : r.content) || await io({
|
|
2706
2715
|
symbol: e.symbol,
|
|
2707
2716
|
builderContextValue: e.builderContext
|
|
2708
2717
|
});
|
|
2709
|
-
return /* @__PURE__ */ l("div", { ...e.attributes, className:
|
|
2710
|
-
|
|
2718
|
+
return /* @__PURE__ */ l("div", { ...e.attributes, className: o(), children: /* @__PURE__ */ l(
|
|
2719
|
+
oo,
|
|
2711
2720
|
{
|
|
2712
2721
|
isNestedRender: !0,
|
|
2713
2722
|
apiVersion: e.builderContext.apiVersion,
|
|
2714
2723
|
apiKey: e.builderContext.apiKey,
|
|
2715
2724
|
context: {
|
|
2716
2725
|
...e.builderContext.context,
|
|
2717
|
-
symbolId: (
|
|
2726
|
+
symbolId: (a = e.builderBlock) == null ? void 0 : a.id
|
|
2718
2727
|
},
|
|
2719
2728
|
customComponents: Object.values(e.builderComponents),
|
|
2720
2729
|
data: {
|
|
2721
|
-
...(
|
|
2730
|
+
...(s = e.symbol) == null ? void 0 : s.data,
|
|
2722
2731
|
...e.builderContext.localState,
|
|
2723
|
-
...(
|
|
2732
|
+
...(c = i == null ? void 0 : i.data) == null ? void 0 : c.state
|
|
2724
2733
|
},
|
|
2725
|
-
model: (
|
|
2726
|
-
content:
|
|
2734
|
+
model: (u = e.symbol) == null ? void 0 : u.model,
|
|
2735
|
+
content: i,
|
|
2727
2736
|
linkComponent: e.builderLinkComponent,
|
|
2728
|
-
blocksWrapper:
|
|
2729
|
-
contentWrapper:
|
|
2737
|
+
blocksWrapper: t(),
|
|
2738
|
+
contentWrapper: n()
|
|
2730
2739
|
}
|
|
2731
2740
|
) });
|
|
2732
2741
|
}
|
|
2733
|
-
const
|
|
2734
|
-
function
|
|
2735
|
-
if (
|
|
2736
|
-
Object.assign(
|
|
2742
|
+
const le = {};
|
|
2743
|
+
function To(e) {
|
|
2744
|
+
if (k()) {
|
|
2745
|
+
Object.assign(le, e);
|
|
2737
2746
|
const t = {
|
|
2738
2747
|
type: "builder.settingsChange",
|
|
2739
|
-
data:
|
|
2748
|
+
data: le
|
|
2740
2749
|
};
|
|
2741
2750
|
parent.postMessage(t, "*");
|
|
2742
2751
|
}
|
|
2743
2752
|
}
|
|
2744
|
-
const
|
|
2753
|
+
const Eo = async (e) => {
|
|
2745
2754
|
var o, i, r;
|
|
2746
2755
|
const t = e.path || ((o = e.url) == null ? void 0 : o.pathname) || ((i = e.userAttributes) == null ? void 0 : i.urlPath), n = {
|
|
2747
2756
|
...e,
|
|
@@ -2753,49 +2762,50 @@ const vo = async (e) => {
|
|
|
2753
2762
|
urlPath: t
|
|
2754
2763
|
} : {}
|
|
2755
2764
|
},
|
|
2756
|
-
options:
|
|
2765
|
+
options: Pe(e.searchParams || ((r = e.url) == null ? void 0 : r.searchParams) || e.options)
|
|
2757
2766
|
};
|
|
2758
2767
|
return {
|
|
2759
2768
|
apiKey: n.apiKey,
|
|
2760
2769
|
model: n.model,
|
|
2761
|
-
content: await
|
|
2770
|
+
content: await Ae(n)
|
|
2762
2771
|
};
|
|
2763
2772
|
};
|
|
2764
2773
|
export {
|
|
2765
|
-
|
|
2774
|
+
Pe as A,
|
|
2766
2775
|
K as B,
|
|
2767
|
-
|
|
2768
|
-
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2776
|
+
Vt as C,
|
|
2777
|
+
ko as D,
|
|
2778
|
+
wo as E,
|
|
2779
|
+
Eo as F,
|
|
2780
|
+
Rn as G,
|
|
2781
|
+
Pn as H,
|
|
2782
|
+
ro as S,
|
|
2783
|
+
en as T,
|
|
2784
|
+
_n as _,
|
|
2785
|
+
Et as a,
|
|
2786
|
+
go as b,
|
|
2787
|
+
me as c,
|
|
2788
|
+
bo as d,
|
|
2789
|
+
yo as e,
|
|
2790
|
+
k as f,
|
|
2781
2791
|
M as g,
|
|
2782
2792
|
U as h,
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2799
|
-
|
|
2800
|
-
|
|
2793
|
+
ho as i,
|
|
2794
|
+
vo as j,
|
|
2795
|
+
Io as k,
|
|
2796
|
+
w as l,
|
|
2797
|
+
Yn as m,
|
|
2798
|
+
H as n,
|
|
2799
|
+
Co as o,
|
|
2800
|
+
Cn as p,
|
|
2801
|
+
O as q,
|
|
2802
|
+
xo as r,
|
|
2803
|
+
qn as s,
|
|
2804
|
+
po as t,
|
|
2805
|
+
So as u,
|
|
2806
|
+
Ae as v,
|
|
2807
|
+
yn as w,
|
|
2808
|
+
oo as x,
|
|
2809
|
+
zn as y,
|
|
2810
|
+
To as z
|
|
2801
2811
|
};
|