@builder.io/sdk-react 4.2.1 → 4.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/browser/blocks-exports.cjs +37 -37
- package/lib/browser/blocks-exports.mjs +1238 -1168
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/server-entry-0817de95.cjs +2 -0
- package/lib/browser/{server-entry-5e98a993.js → server-entry-331e2fd4.js} +248 -246
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/{accordion-4bab42b1.cjs → accordion-1559ca68.cjs} +1 -1
- package/lib/edge/{accordion-a8a363e4.js → accordion-3e9ee224.js} +1 -1
- package/lib/edge/{blocks-d07d0261.cjs → blocks-4f20c19a.cjs} +14 -14
- package/lib/edge/{blocks-e1f5b0d0.js → blocks-b9be7dc1.js} +749 -736
- package/lib/edge/blocks-exports.cjs +1 -1
- package/lib/edge/blocks-exports.mjs +2 -2
- package/lib/edge/{button-6734c0bb.cjs → button-0a632d4f.cjs} +1 -1
- package/lib/edge/{button-bbcadacf.js → button-ba852235.js} +2 -2
- package/lib/edge/{columns-821cba14.cjs → columns-66170ac9.cjs} +1 -1
- package/lib/edge/{columns-cf3081c6.js → columns-ee2fba7b.js} +3 -3
- package/lib/edge/content-variants-4f54d98a.cjs +302 -0
- package/lib/edge/{content-variants-a704e35c.js → content-variants-c013569a.js} +489 -444
- package/lib/edge/{custom-code-f6c30129.js → custom-code-38e2c9d5.js} +1 -1
- package/lib/edge/{custom-code-8fcaa31e.cjs → custom-code-48579935.cjs} +1 -1
- package/lib/edge/{embed-3c0b5564.js → embed-1ce0435c.js} +1 -1
- package/lib/edge/{embed-666d3cc4.cjs → embed-9a7f29ff.cjs} +1 -1
- package/lib/edge/form-d9b6dea6.cjs +1 -0
- package/lib/edge/{form-8b068721.js → form-f558f5d4.js} +24 -21
- package/lib/edge/{get-class-prop-name-d6d821d6.js → get-class-prop-name-35ccd32a.js} +1 -1
- package/lib/edge/{get-class-prop-name-2869a960.cjs → get-class-prop-name-d2be9a48.cjs} +1 -1
- package/lib/edge/image-cce92f6c.cjs +17 -0
- package/lib/edge/image-d87761af.js +123 -0
- package/lib/edge/img-a1e0f10e.js +33 -0
- package/lib/edge/img-b21eb075.cjs +1 -0
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/{input-665ef328.js → input-5c0d3350.js} +1 -1
- package/lib/edge/{input-d31d6451.cjs → input-6854bc85.cjs} +1 -1
- package/lib/edge/{personalization-container-e784836e.js → personalization-container-adf9e0bd.js} +4 -4
- package/lib/edge/{personalization-container-d12566e8.cjs → personalization-container-f7fdc090.cjs} +1 -1
- package/lib/edge/{select-c3085265.cjs → select-6c4637ae.cjs} +1 -1
- package/lib/edge/{select-5fe49bd4.js → select-713e73f6.js} +1 -1
- package/lib/edge/server-entry-0bef3cb1.cjs +2 -0
- package/lib/{node/server-entry-48724189.js → edge/server-entry-71badd34.js} +307 -307
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/edge/{slot-cbbbb02e.cjs → slot-59a86f46.cjs} +1 -1
- package/lib/edge/{slot-a17ee2d7.js → slot-a3c27352.js} +3 -3
- package/lib/edge/symbol-3d81a9de.cjs +1 -0
- package/lib/edge/{symbol-9f960685.js → symbol-86e5a3f0.js} +26 -23
- package/lib/edge/tabs-0d914e5c.cjs +1 -0
- package/lib/edge/{tabs-26ac5b2f.js → tabs-60f8bb61.js} +24 -23
- package/lib/node/blocks-exports.cjs +38 -38
- package/lib/node/blocks-exports.mjs +1375 -1305
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +3 -3
- package/lib/node/init.cjs +1 -1
- package/lib/node/init.mjs +3 -3
- package/lib/node/server-entry-05b0f263.cjs +2 -0
- package/lib/{edge/server-entry-c9d5300f.js → node/server-entry-68823bb0.js} +346 -342
- package/lib/node/server-entry.cjs +1 -1
- package/lib/node/server-entry.mjs +1 -1
- package/lib/node/{setIvm-a7aba6d2.js → setIvm-bb3d0e32.js} +1 -1
- package/lib/node/{setIvm-3b6199a0.cjs → setIvm-bec8f1ed.cjs} +1 -1
- package/lib/node/setIvm.cjs +1 -1
- package/lib/node/setIvm.mjs +2 -2
- package/lib/node/{should-force-browser-runtime-in-node-fdc70f22.js → should-force-browser-runtime-in-node-a4c71d14.js} +1 -1
- package/lib/node/{should-force-browser-runtime-in-node-cbe0ef14.cjs → should-force-browser-runtime-in-node-bbbdf124.cjs} +1 -1
- package/package.json +1 -1
- package/types/blocks/img/img.d.ts +2 -0
- package/types/blocks/symbol/symbol.types.d.ts +1 -2
- package/types/components/awaiter.d.ts +1 -11
- package/types/components/awaiter.types.d.ts +7 -0
- package/types/components/block/components/live-edit-block-styles.d.ts +8 -0
- package/types/components/block/components/style-wrapper.d.ts +9 -0
- package/types/components/live-edit.d.ts +9 -0
- package/types/constants/sdk-version.d.ts +1 -1
- package/types/helpers/find-block.d.ts +18 -0
- package/types/helpers/subscribe-to-editor.d.ts +3 -2
- package/lib/browser/server-entry-4cf669a1.cjs +0 -2
- package/lib/edge/content-variants-ec180883.cjs +0 -302
- package/lib/edge/form-51f639ab.cjs +0 -1
- package/lib/edge/image-209835f4.js +0 -94
- package/lib/edge/image-87a4e006.cjs +0 -17
- package/lib/edge/image.helpers-3e926d47.js +0 -33
- package/lib/edge/image.helpers-dba8a869.cjs +0 -1
- package/lib/edge/img-b04b9b6d.cjs +0 -1
- package/lib/edge/img-dfbd4080.js +0 -28
- package/lib/edge/server-entry-acf5ce7d.cjs +0 -2
- package/lib/edge/symbol-b56b5675.cjs +0 -1
- package/lib/edge/tabs-bf6643d7.cjs +0 -1
- package/lib/node/server-entry-562c0663.cjs +0 -2
|
@@ -1,66 +1,66 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { lazy as C, useRef as
|
|
3
|
-
import { TARGET as F, isBrowser as
|
|
4
|
-
import { Video as
|
|
5
|
-
import { triggerAnimation as
|
|
6
|
-
function
|
|
7
|
-
function r(
|
|
8
|
-
return typeof
|
|
1
|
+
import { jsx as S, jsxs as H, Fragment as M } from "react/jsx-runtime";
|
|
2
|
+
import { lazy as C, useRef as Y, useState as k, useEffect as N } from "react";
|
|
3
|
+
import { TARGET as F, isBrowser as L, isEditing as _, isPreviewing as ue, setupBrowserForEditing as ve, createRegisterComponentMessage as xe, getDefaultCanTrack as j, getCookieSync as Se, _track as ne, fetchOneEntry as Te, createEditorListener as Ie, logFetch as ke, serializeIncludingFunctions as ae, logger as Ce, handleABTestingSync as we } from "./server-entry-71badd34.js";
|
|
4
|
+
import { Video as Ve, Button as Ee, Columns as Re, Fragment as Ae, Image as De, Section as Pe, Symbol as Fe, Text as We, BuilderContext as Ne } from "./blocks-exports.mjs";
|
|
5
|
+
import { triggerAnimation as $e, evaluate as de, fastClone as _e, InlinedStyles as ce, ComponentsContext as Le, Blocks as Be } from "./blocks-b9be7dc1.js";
|
|
6
|
+
function tn(e, t, n, o) {
|
|
7
|
+
function r(m) {
|
|
8
|
+
return typeof m == "string";
|
|
9
9
|
}
|
|
10
|
-
function
|
|
11
|
-
return typeof
|
|
10
|
+
function l(m) {
|
|
11
|
+
return typeof m == "number";
|
|
12
12
|
}
|
|
13
|
-
function
|
|
13
|
+
function a(m, g) {
|
|
14
14
|
return (() => {
|
|
15
|
-
const
|
|
16
|
-
let
|
|
17
|
-
if (
|
|
15
|
+
const T = g.property, A = g.operator;
|
|
16
|
+
let s = g.value;
|
|
17
|
+
if (g && g.property === "urlPath" && g.value && typeof g.value == "string" && g.value !== "/" && g.value.endsWith("/") && (s = g.value.slice(0, -1)), !(T && A))
|
|
18
18
|
return !0;
|
|
19
|
-
if (Array.isArray(
|
|
20
|
-
return
|
|
21
|
-
property:
|
|
22
|
-
operator:
|
|
23
|
-
value:
|
|
24
|
-
})) : !!
|
|
25
|
-
property:
|
|
26
|
-
operator:
|
|
27
|
-
value:
|
|
19
|
+
if (Array.isArray(s))
|
|
20
|
+
return A === "isNot" ? s.every((D) => a(m, {
|
|
21
|
+
property: T,
|
|
22
|
+
operator: A,
|
|
23
|
+
value: D
|
|
24
|
+
})) : !!s.find((D) => a(m, {
|
|
25
|
+
property: T,
|
|
26
|
+
operator: A,
|
|
27
|
+
value: D
|
|
28
28
|
}));
|
|
29
|
-
const
|
|
30
|
-
if (Array.isArray(
|
|
31
|
-
return
|
|
32
|
-
switch (
|
|
29
|
+
const d = m[T];
|
|
30
|
+
if (Array.isArray(d))
|
|
31
|
+
return d.includes(s);
|
|
32
|
+
switch (A) {
|
|
33
33
|
case "is":
|
|
34
|
-
return
|
|
34
|
+
return d === s;
|
|
35
35
|
case "isNot":
|
|
36
|
-
return
|
|
36
|
+
return d !== s;
|
|
37
37
|
case "contains":
|
|
38
|
-
return (r(
|
|
38
|
+
return (r(d) || Array.isArray(d)) && d.includes(String(s));
|
|
39
39
|
case "startsWith":
|
|
40
|
-
return r(
|
|
40
|
+
return r(d) && d.startsWith(String(s));
|
|
41
41
|
case "endsWith":
|
|
42
|
-
return r(
|
|
42
|
+
return r(d) && d.endsWith(String(s));
|
|
43
43
|
case "greaterThan":
|
|
44
|
-
return
|
|
44
|
+
return l(d) && l(s) && d > s;
|
|
45
45
|
case "lessThan":
|
|
46
|
-
return
|
|
46
|
+
return l(d) && l(s) && d < s;
|
|
47
47
|
case "greaterThanOrEqualTo":
|
|
48
|
-
return
|
|
48
|
+
return l(d) && l(s) && d >= s;
|
|
49
49
|
case "lessThanOrEqualTo":
|
|
50
|
-
return
|
|
50
|
+
return l(d) && l(s) && d <= s;
|
|
51
51
|
default:
|
|
52
52
|
return !1;
|
|
53
53
|
}
|
|
54
54
|
})();
|
|
55
55
|
}
|
|
56
|
-
const
|
|
56
|
+
const i = {
|
|
57
57
|
query: t,
|
|
58
58
|
startDate: n,
|
|
59
59
|
endDate: o
|
|
60
|
-
},
|
|
61
|
-
return
|
|
60
|
+
}, u = e.date && new Date(e.date) || /* @__PURE__ */ new Date();
|
|
61
|
+
return i.startDate && new Date(i.startDate) > u || i.endDate && new Date(i.endDate) < u ? !1 : !i.query || !i.query.length ? !0 : i.query.every((m) => a(e, m));
|
|
62
62
|
}
|
|
63
|
-
const
|
|
63
|
+
const Ue = `function getPersonalizedVariant(variants, blockId, isHydrationTarget, locale) {
|
|
64
64
|
if (!navigator.cookieEnabled) {
|
|
65
65
|
return;
|
|
66
66
|
}
|
|
@@ -105,7 +105,7 @@ const $e = `function getPersonalizedVariant(variants, blockId, isHydrationTarget
|
|
|
105
105
|
thisScript.remove();
|
|
106
106
|
}
|
|
107
107
|
}
|
|
108
|
-
}`,
|
|
108
|
+
}`, He = `function filterWithCustomTargeting(userAttributes, query, startDate, endDate) {
|
|
109
109
|
function isString(val) {
|
|
110
110
|
return typeof val === 'string';
|
|
111
111
|
}
|
|
@@ -183,7 +183,7 @@ const $e = `function getPersonalizedVariant(variants, blockId, isHydrationTarget
|
|
|
183
183
|
return item.query.every(filter => {
|
|
184
184
|
return objectMatchesQuery(userAttributes, filter);
|
|
185
185
|
});
|
|
186
|
-
}`,
|
|
186
|
+
}`, Oe = `function updateVisibilityStylesScript(variants, blockId, isHydrationTarget, locale) {
|
|
187
187
|
function getCookie(name) {
|
|
188
188
|
const nameEQ = name + '=';
|
|
189
189
|
const ca = document.cookie.split(';');
|
|
@@ -221,54 +221,54 @@ const $e = `function getPersonalizedVariant(variants, blockId, isHydrationTarget
|
|
|
221
221
|
visibilityStylesEl.innerHTML = newStyleStr;
|
|
222
222
|
}
|
|
223
223
|
}
|
|
224
|
-
}`,
|
|
225
|
-
function
|
|
226
|
-
return !(e && e.length > 0) || !t ? !1 :
|
|
224
|
+
}`, qe = "default", je = "filterWithCustomTargeting", me = "builderIoPersonalization", pe = "updateVisibilityStylesScript", fe = ["react", "vue", "svelte", "qwik"], Me = ["vue", "svelte", "qwik"];
|
|
225
|
+
function nn(e, t) {
|
|
226
|
+
return !(e && e.length > 0) || !t ? !1 : Me.includes(F) ? !0 : !L();
|
|
227
227
|
}
|
|
228
|
-
function
|
|
228
|
+
function an({
|
|
229
229
|
variants: e,
|
|
230
230
|
previewingIndex: t,
|
|
231
231
|
isHydrated: n,
|
|
232
232
|
filteredVariants: o,
|
|
233
233
|
fallbackBlocks: r
|
|
234
234
|
}) {
|
|
235
|
-
var
|
|
236
|
-
const
|
|
235
|
+
var a;
|
|
236
|
+
const l = {
|
|
237
237
|
blocks: r != null ? r : [],
|
|
238
238
|
path: "this.children",
|
|
239
|
-
index:
|
|
239
|
+
index: qe
|
|
240
240
|
};
|
|
241
|
-
if (n &&
|
|
242
|
-
if (typeof t == "number" && t < ((
|
|
243
|
-
const
|
|
244
|
-
if (
|
|
241
|
+
if (n && _()) {
|
|
242
|
+
if (typeof t == "number" && t < ((a = e == null ? void 0 : e.length) != null ? a : 0)) {
|
|
243
|
+
const i = e == null ? void 0 : e[t];
|
|
244
|
+
if (i)
|
|
245
245
|
return {
|
|
246
|
-
blocks:
|
|
246
|
+
blocks: i.blocks,
|
|
247
247
|
path: `variants.${t}.blocks`,
|
|
248
248
|
index: t
|
|
249
249
|
};
|
|
250
250
|
}
|
|
251
|
-
return
|
|
251
|
+
return l;
|
|
252
252
|
}
|
|
253
|
-
if (
|
|
254
|
-
const
|
|
255
|
-
if (
|
|
256
|
-
const
|
|
257
|
-
if (
|
|
253
|
+
if (L()) {
|
|
254
|
+
const i = o == null ? void 0 : o[0];
|
|
255
|
+
if (i && e) {
|
|
256
|
+
const u = e.indexOf(i);
|
|
257
|
+
if (u !== -1)
|
|
258
258
|
return {
|
|
259
|
-
blocks:
|
|
260
|
-
path: `variants.${
|
|
261
|
-
index:
|
|
259
|
+
blocks: i.blocks,
|
|
260
|
+
path: `variants.${u}.blocks`,
|
|
261
|
+
index: u
|
|
262
262
|
};
|
|
263
263
|
}
|
|
264
264
|
}
|
|
265
|
-
return
|
|
265
|
+
return l;
|
|
266
266
|
}
|
|
267
|
-
const
|
|
268
|
-
window.${
|
|
269
|
-
window.${
|
|
270
|
-
window.${
|
|
271
|
-
`,
|
|
267
|
+
const Ke = () => `
|
|
268
|
+
window.${je} = ${He}
|
|
269
|
+
window.${me} = ${Ue}
|
|
270
|
+
window.${pe} = ${Oe}
|
|
271
|
+
`, ge = F === "react", on = (e, t, n) => `window.${me}(${JSON.stringify(e)}, "${t}", ${ge}${n ? `, "${n}"` : ""})`, rn = (e, t, n) => `window.${pe}(${JSON.stringify(e)}, "${t}", ${ge}${n ? `, "${n}"` : ""})`, K = {
|
|
272
272
|
"@type": "@builder.io/sdk:Element",
|
|
273
273
|
layerName: "Accordion item title",
|
|
274
274
|
responsiveStyles: {
|
|
@@ -297,7 +297,7 @@ const qe = () => `
|
|
|
297
297
|
}
|
|
298
298
|
}
|
|
299
299
|
}]
|
|
300
|
-
},
|
|
300
|
+
}, z = {
|
|
301
301
|
"@type": "@builder.io/sdk:Element",
|
|
302
302
|
layerName: "Accordion item detail",
|
|
303
303
|
responsiveStyles: {
|
|
@@ -328,7 +328,7 @@ const qe = () => `
|
|
|
328
328
|
}
|
|
329
329
|
}
|
|
330
330
|
}]
|
|
331
|
-
},
|
|
331
|
+
}, ze = {
|
|
332
332
|
name: "Builder:Accordion",
|
|
333
333
|
canHaveChildren: !0,
|
|
334
334
|
image: "https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",
|
|
@@ -345,19 +345,19 @@ const qe = () => `
|
|
|
345
345
|
name: "title",
|
|
346
346
|
type: "uiBlocks",
|
|
347
347
|
hideFromUI: !0,
|
|
348
|
-
defaultValue: [
|
|
348
|
+
defaultValue: [K]
|
|
349
349
|
}, {
|
|
350
350
|
name: "detail",
|
|
351
351
|
type: "uiBlocks",
|
|
352
352
|
hideFromUI: !0,
|
|
353
|
-
defaultValue: [
|
|
353
|
+
defaultValue: [z]
|
|
354
354
|
}],
|
|
355
355
|
defaultValue: [{
|
|
356
|
-
title: [
|
|
357
|
-
detail: [
|
|
356
|
+
title: [K],
|
|
357
|
+
detail: [z]
|
|
358
358
|
}, {
|
|
359
|
-
title: [
|
|
360
|
-
detail: [
|
|
359
|
+
title: [K],
|
|
360
|
+
detail: [z]
|
|
361
361
|
}],
|
|
362
362
|
showIf: (e) => !e.get("useChildrenForItems")
|
|
363
363
|
}, {
|
|
@@ -392,7 +392,7 @@ const qe = () => `
|
|
|
392
392
|
builderComponents: !0,
|
|
393
393
|
builderLinkComponent: !0
|
|
394
394
|
}
|
|
395
|
-
},
|
|
395
|
+
}, Je = C(() => import("./accordion-3e9ee224.js")), Qe = {
|
|
396
396
|
name: "Core:Button",
|
|
397
397
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
398
398
|
defaultStyles: {
|
|
@@ -428,7 +428,7 @@ const qe = () => `
|
|
|
428
428
|
shouldReceiveBuilderProps: {
|
|
429
429
|
builderLinkComponent: !0
|
|
430
430
|
}
|
|
431
|
-
},
|
|
431
|
+
}, Ye = {
|
|
432
432
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
433
433
|
name: "Columns",
|
|
434
434
|
isRSC: !0,
|
|
@@ -607,7 +607,7 @@ const qe = () => `
|
|
|
607
607
|
});
|
|
608
608
|
}
|
|
609
609
|
const n = e.get("columns");
|
|
610
|
-
Array.isArray(n) && n.find((r) => r.get("width")) && (n.find((
|
|
610
|
+
Array.isArray(n) && n.find((r) => r.get("width")) && (n.find((l) => !l.get("width")) || n.reduce((i, u) => i + u.get("width"), 0) !== 100) && t();
|
|
611
611
|
}
|
|
612
612
|
}, {
|
|
613
613
|
name: "space",
|
|
@@ -635,13 +635,13 @@ const qe = () => `
|
|
|
635
635
|
builderComponents: !0,
|
|
636
636
|
builderLinkComponent: !0
|
|
637
637
|
}
|
|
638
|
-
},
|
|
638
|
+
}, Ge = {
|
|
639
639
|
name: "Fragment",
|
|
640
640
|
static: !0,
|
|
641
641
|
hidden: !0,
|
|
642
642
|
canHaveChildren: !0,
|
|
643
643
|
noWrap: !0
|
|
644
|
-
},
|
|
644
|
+
}, G = ["jpeg", "jpg", "png", "svg", "webp", "gif", "jfif", "pjpeg", "pjp", "apng", "avif", "tif", "tiff", "heif", "bmp", "eps", "raw", "cr2", "nef", "orf", "sr2", "psd", "heic", "dib", "ai"], Xe = ["mp4", "webm", "mkv", "flv", "vob", "ogv", "ogg", "drc", "gif", "gifv", "mng", "avi", "mov", "qt", "mts", "m2ts", "ts", "wmv", "yuv", "rm", "rmvb", "viv", "asf", "amv", "m4p", "mpeg", "mpe", "m2v", "m4v", "svi", "3gp", "3g2", "mxf", "roq", "nsv", "f4v", "f4p", "f4a", "f4b"], Ze = {
|
|
645
645
|
name: "Image",
|
|
646
646
|
static: !0,
|
|
647
647
|
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",
|
|
@@ -656,34 +656,34 @@ const qe = () => `
|
|
|
656
656
|
name: "image",
|
|
657
657
|
type: "file",
|
|
658
658
|
bubble: !0,
|
|
659
|
-
allowedFileTypes:
|
|
659
|
+
allowedFileTypes: G,
|
|
660
660
|
required: !0,
|
|
661
661
|
defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
|
|
662
662
|
onChange: (e) => {
|
|
663
663
|
e.delete("srcset"), e.delete("noWebp");
|
|
664
|
-
function n(
|
|
665
|
-
return new Promise((
|
|
666
|
-
const
|
|
667
|
-
let
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
},
|
|
671
|
-
console.warn("Image load failed",
|
|
672
|
-
}),
|
|
673
|
-
|
|
674
|
-
},
|
|
664
|
+
function n(a, i = 6e4) {
|
|
665
|
+
return new Promise((u, m) => {
|
|
666
|
+
const g = document.createElement("img");
|
|
667
|
+
let R = !1;
|
|
668
|
+
g.onload = () => {
|
|
669
|
+
R = !0, u(g);
|
|
670
|
+
}, g.addEventListener("error", (T) => {
|
|
671
|
+
console.warn("Image load failed", T.error), m(T.error);
|
|
672
|
+
}), g.src = a, setTimeout(() => {
|
|
673
|
+
R || m(new Error("Image load timed out"));
|
|
674
|
+
}, i);
|
|
675
675
|
});
|
|
676
676
|
}
|
|
677
|
-
function o(
|
|
678
|
-
return Math.round(
|
|
677
|
+
function o(a) {
|
|
678
|
+
return Math.round(a * 1e3) / 1e3;
|
|
679
679
|
}
|
|
680
|
-
const r = e.get("image"),
|
|
681
|
-
if (fetch(r).then((
|
|
682
|
-
|
|
683
|
-
}), r && (!
|
|
684
|
-
return n(r).then((
|
|
685
|
-
const
|
|
686
|
-
e.get("image") === r && (!
|
|
680
|
+
const r = e.get("image"), l = e.get("aspectRatio");
|
|
681
|
+
if (fetch(r).then((a) => a.blob()).then((a) => {
|
|
682
|
+
a.type.includes("svg") && e.set("noWebp", !0);
|
|
683
|
+
}), r && (!l || l === 0.7041))
|
|
684
|
+
return n(r).then((a) => {
|
|
685
|
+
const i = e.get("aspectRatio");
|
|
686
|
+
e.get("image") === r && (!i || i === 0.7041) && a.width && a.height && (e.set("aspectRatio", o(a.height / a.width)), e.set("height", a.height), e.set("width", a.width));
|
|
687
687
|
});
|
|
688
688
|
}
|
|
689
689
|
}, {
|
|
@@ -753,7 +753,7 @@ const qe = () => `
|
|
|
753
753
|
shouldReceiveBuilderProps: {
|
|
754
754
|
builderBlock: !0
|
|
755
755
|
}
|
|
756
|
-
},
|
|
756
|
+
}, et = {
|
|
757
757
|
name: "PersonalizationContainer",
|
|
758
758
|
shouldReceiveBuilderProps: {
|
|
759
759
|
builderBlock: !0,
|
|
@@ -789,7 +789,7 @@ const qe = () => `
|
|
|
789
789
|
defaultValue: []
|
|
790
790
|
}]
|
|
791
791
|
}]
|
|
792
|
-
},
|
|
792
|
+
}, tt = C(() => import("./personalization-container-adf9e0bd.js")), nt = {
|
|
793
793
|
name: "Core:Section",
|
|
794
794
|
static: !0,
|
|
795
795
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -828,7 +828,7 @@ const qe = () => `
|
|
|
828
828
|
}
|
|
829
829
|
}
|
|
830
830
|
}]
|
|
831
|
-
},
|
|
831
|
+
}, at = {
|
|
832
832
|
name: "Slot",
|
|
833
833
|
isRSC: !0,
|
|
834
834
|
description: "Allow child blocks to be inserted into this content when used as a Symbol",
|
|
@@ -845,7 +845,7 @@ const qe = () => `
|
|
|
845
845
|
builderContext: !0,
|
|
846
846
|
builderComponents: !0
|
|
847
847
|
}
|
|
848
|
-
},
|
|
848
|
+
}, it = C(() => import("./slot-a3c27352.js")), ot = {
|
|
849
849
|
name: "Symbol",
|
|
850
850
|
noWrap: !0,
|
|
851
851
|
static: !0,
|
|
@@ -884,7 +884,7 @@ const qe = () => `
|
|
|
884
884
|
builderComponents: !0,
|
|
885
885
|
builderLinkComponent: !0
|
|
886
886
|
}
|
|
887
|
-
},
|
|
887
|
+
}, J = {
|
|
888
888
|
"@type": "@builder.io/sdk:Element",
|
|
889
889
|
responsiveStyles: {
|
|
890
890
|
large: {
|
|
@@ -906,7 +906,7 @@ const qe = () => `
|
|
|
906
906
|
text: "New tab"
|
|
907
907
|
}
|
|
908
908
|
}
|
|
909
|
-
},
|
|
909
|
+
}, Q = {
|
|
910
910
|
"@type": "@builder.io/sdk:Element",
|
|
911
911
|
responsiveStyles: {
|
|
912
912
|
large: {
|
|
@@ -922,7 +922,7 @@ const qe = () => `
|
|
|
922
922
|
text: "New tab content "
|
|
923
923
|
}
|
|
924
924
|
}
|
|
925
|
-
},
|
|
925
|
+
}, rt = {
|
|
926
926
|
name: "Builder: Tabs",
|
|
927
927
|
inputs: [{
|
|
928
928
|
name: "tabs",
|
|
@@ -932,16 +932,16 @@ const qe = () => `
|
|
|
932
932
|
name: "label",
|
|
933
933
|
type: "uiBlocks",
|
|
934
934
|
hideFromUI: !0,
|
|
935
|
-
defaultValue: [
|
|
935
|
+
defaultValue: [J]
|
|
936
936
|
}, {
|
|
937
937
|
name: "content",
|
|
938
938
|
type: "uiBlocks",
|
|
939
939
|
hideFromUI: !0,
|
|
940
|
-
defaultValue: [
|
|
940
|
+
defaultValue: [Q]
|
|
941
941
|
}],
|
|
942
942
|
defaultValue: [{
|
|
943
943
|
label: [{
|
|
944
|
-
...
|
|
944
|
+
...J,
|
|
945
945
|
component: {
|
|
946
946
|
name: "Text",
|
|
947
947
|
options: {
|
|
@@ -950,7 +950,7 @@ const qe = () => `
|
|
|
950
950
|
}
|
|
951
951
|
}],
|
|
952
952
|
content: [{
|
|
953
|
-
...
|
|
953
|
+
...Q,
|
|
954
954
|
component: {
|
|
955
955
|
name: "Text",
|
|
956
956
|
options: {
|
|
@@ -960,7 +960,7 @@ const qe = () => `
|
|
|
960
960
|
}]
|
|
961
961
|
}, {
|
|
962
962
|
label: [{
|
|
963
|
-
...
|
|
963
|
+
...J,
|
|
964
964
|
component: {
|
|
965
965
|
name: "Text",
|
|
966
966
|
options: {
|
|
@@ -969,7 +969,7 @@ const qe = () => `
|
|
|
969
969
|
}
|
|
970
970
|
}],
|
|
971
971
|
content: [{
|
|
972
|
-
...
|
|
972
|
+
...Q,
|
|
973
973
|
component: {
|
|
974
974
|
name: "Text",
|
|
975
975
|
options: {
|
|
@@ -1025,11 +1025,10 @@ const qe = () => `
|
|
|
1025
1025
|
builderComponents: !0,
|
|
1026
1026
|
builderLinkComponent: !0
|
|
1027
1027
|
}
|
|
1028
|
-
},
|
|
1028
|
+
}, lt = C(() => import("./tabs-60f8bb61.js")), st = {
|
|
1029
1029
|
shouldReceiveBuilderProps: {},
|
|
1030
1030
|
name: "Text",
|
|
1031
1031
|
static: !0,
|
|
1032
|
-
isRSC: !0,
|
|
1033
1032
|
image: "https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-text_fields-24px%20(1).svg?alt=media&token=12177b73-0ee3-42ca-98c6-0dd003de1929",
|
|
1034
1033
|
inputs: [{
|
|
1035
1034
|
name: "text",
|
|
@@ -1044,7 +1043,7 @@ const qe = () => `
|
|
|
1044
1043
|
height: "auto",
|
|
1045
1044
|
textAlign: "center"
|
|
1046
1045
|
}
|
|
1047
|
-
},
|
|
1046
|
+
}, ut = {
|
|
1048
1047
|
name: "Custom Code",
|
|
1049
1048
|
static: !0,
|
|
1050
1049
|
requiredPermissions: ["editCode"],
|
|
@@ -1066,7 +1065,7 @@ const qe = () => `
|
|
|
1066
1065
|
helperText: "Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",
|
|
1067
1066
|
advanced: !0
|
|
1068
1067
|
}]
|
|
1069
|
-
},
|
|
1068
|
+
}, dt = C(() => import("./custom-code-38e2c9d5.js")), ct = {
|
|
1070
1069
|
name: "Embed",
|
|
1071
1070
|
static: !0,
|
|
1072
1071
|
inputs: [{
|
|
@@ -1081,7 +1080,7 @@ const qe = () => `
|
|
|
1081
1080
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
1082
1081
|
hideFromUI: !0
|
|
1083
1082
|
}]
|
|
1084
|
-
},
|
|
1083
|
+
}, mt = C(() => import("./embed-1ce0435c.js")), pt = {
|
|
1085
1084
|
name: "Form:Form",
|
|
1086
1085
|
// editableTags: ['builder-form-error']
|
|
1087
1086
|
defaults: {
|
|
@@ -1318,7 +1317,7 @@ const qe = () => `
|
|
|
1318
1317
|
builderComponents: !0,
|
|
1319
1318
|
builderLinkComponent: !0
|
|
1320
1319
|
}
|
|
1321
|
-
},
|
|
1320
|
+
}, ft = C(() => import("./form-f558f5d4.js")), gt = {
|
|
1322
1321
|
name: "Form:Input",
|
|
1323
1322
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fad6f37889d9e40bbbbc72cdb5875d6ca",
|
|
1324
1323
|
inputs: [
|
|
@@ -1369,7 +1368,7 @@ const qe = () => `
|
|
|
1369
1368
|
borderStyle: "solid",
|
|
1370
1369
|
borderColor: "#ccc"
|
|
1371
1370
|
}
|
|
1372
|
-
},
|
|
1371
|
+
}, ht = C(() => import("./input-5c0d3350.js")), bt = {
|
|
1373
1372
|
name: "Form:Select",
|
|
1374
1373
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F83acca093fb24aaf94dee136e9a4b045",
|
|
1375
1374
|
defaultStyles: {
|
|
@@ -1411,7 +1410,7 @@ const qe = () => `
|
|
|
1411
1410
|
}],
|
|
1412
1411
|
static: !0,
|
|
1413
1412
|
noWrap: !0
|
|
1414
|
-
},
|
|
1413
|
+
}, yt = C(() => import("./select-713e73f6.js")), vt = {
|
|
1415
1414
|
name: "Form:SubmitButton",
|
|
1416
1415
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fdf2820ffed1f4349a94c40b3221f5b98",
|
|
1417
1416
|
defaultStyles: {
|
|
@@ -1436,7 +1435,7 @@ const qe = () => `
|
|
|
1436
1435
|
// that only shows if advanced setting is flipped
|
|
1437
1436
|
// TODO: defaultChildren
|
|
1438
1437
|
// canHaveChildren: true,
|
|
1439
|
-
},
|
|
1438
|
+
}, xt = C(() => import("./submit-button-b48361a7.js")), St = {
|
|
1440
1439
|
name: "Form:TextArea",
|
|
1441
1440
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Ff74a2f3de58c4c3e939204e5b6b8f6c3",
|
|
1442
1441
|
inputs: [{
|
|
@@ -1472,8 +1471,7 @@ const qe = () => `
|
|
|
1472
1471
|
},
|
|
1473
1472
|
static: !0,
|
|
1474
1473
|
noWrap: !0
|
|
1475
|
-
},
|
|
1476
|
-
// friendlyName?
|
|
1474
|
+
}, Tt = C(() => import("./textarea-d29025e9.js")), It = {
|
|
1477
1475
|
name: "Raw:Img",
|
|
1478
1476
|
hideFromInsertMenu: !0,
|
|
1479
1477
|
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",
|
|
@@ -1481,12 +1479,43 @@ const qe = () => `
|
|
|
1481
1479
|
name: "image",
|
|
1482
1480
|
bubble: !0,
|
|
1483
1481
|
type: "file",
|
|
1484
|
-
allowedFileTypes:
|
|
1482
|
+
allowedFileTypes: G,
|
|
1485
1483
|
required: !0
|
|
1484
|
+
}, {
|
|
1485
|
+
name: "backgroundSize",
|
|
1486
|
+
type: "text",
|
|
1487
|
+
defaultValue: "cover",
|
|
1488
|
+
enum: [{
|
|
1489
|
+
label: "contain",
|
|
1490
|
+
value: "contain",
|
|
1491
|
+
helperText: "The image should never get cropped"
|
|
1492
|
+
}, {
|
|
1493
|
+
label: "cover",
|
|
1494
|
+
value: "cover",
|
|
1495
|
+
helperText: "The image should fill it's box, cropping when needed"
|
|
1496
|
+
}]
|
|
1497
|
+
}, {
|
|
1498
|
+
name: "backgroundPosition",
|
|
1499
|
+
type: "text",
|
|
1500
|
+
defaultValue: "center",
|
|
1501
|
+
enum: ["center", "top", "left", "right", "bottom", "top left", "top right", "bottom left", "bottom right"]
|
|
1502
|
+
}, {
|
|
1503
|
+
name: "altText",
|
|
1504
|
+
type: "string",
|
|
1505
|
+
helperText: "Text to display when the user has images off"
|
|
1506
|
+
}, {
|
|
1507
|
+
name: "title",
|
|
1508
|
+
type: "string",
|
|
1509
|
+
helperText: "Text to display when hovering over the asset"
|
|
1510
|
+
}, {
|
|
1511
|
+
name: "aspectRatio",
|
|
1512
|
+
type: "number",
|
|
1513
|
+
helperText: "This is the ratio of height/width, e.g. set to 1.5 for a 300px wide and 200px tall photo. Set to 0 to not force the image to maintain it's aspect ratio",
|
|
1514
|
+
advanced: !0,
|
|
1515
|
+
defaultValue: 0.7041
|
|
1486
1516
|
}],
|
|
1487
|
-
noWrap: !0
|
|
1488
|
-
|
|
1489
|
-
}, xt = C(() => import("./img-dfbd4080.js")), St = {
|
|
1517
|
+
noWrap: !0
|
|
1518
|
+
}, kt = C(() => import("./img-a1e0f10e.js")), Ct = {
|
|
1490
1519
|
name: "Video",
|
|
1491
1520
|
canHaveChildren: !0,
|
|
1492
1521
|
defaultStyles: {
|
|
@@ -1497,14 +1526,14 @@ const qe = () => `
|
|
|
1497
1526
|
inputs: [{
|
|
1498
1527
|
name: "video",
|
|
1499
1528
|
type: "file",
|
|
1500
|
-
allowedFileTypes:
|
|
1529
|
+
allowedFileTypes: Xe,
|
|
1501
1530
|
bubble: !0,
|
|
1502
1531
|
defaultValue: "https://cdn.builder.io/o/assets%2FYJIGb4i01jvw0SRdL5Bt%2Fd27731a526464deba0016216f5f9e570%2Fcompressed?apiKey=YJIGb4i01jvw0SRdL5Bt&token=d27731a526464deba0016216f5f9e570&alt=media&optimized=true",
|
|
1503
1532
|
required: !0
|
|
1504
1533
|
}, {
|
|
1505
1534
|
name: "posterImage",
|
|
1506
1535
|
type: "file",
|
|
1507
|
-
allowedFileTypes:
|
|
1536
|
+
allowedFileTypes: G,
|
|
1508
1537
|
helperText: "Image to show before the video plays"
|
|
1509
1538
|
}, {
|
|
1510
1539
|
name: "autoPlay",
|
|
@@ -1570,67 +1599,67 @@ const qe = () => `
|
|
|
1570
1599
|
shouldReceiveBuilderProps: {
|
|
1571
1600
|
builderBlock: !0
|
|
1572
1601
|
}
|
|
1573
|
-
},
|
|
1574
|
-
component: rt,
|
|
1575
|
-
...ot
|
|
1576
|
-
}, {
|
|
1577
|
-
component: lt,
|
|
1578
|
-
...st
|
|
1579
|
-
}, {
|
|
1602
|
+
}, wt = () => [{
|
|
1580
1603
|
component: dt,
|
|
1581
1604
|
...ut
|
|
1582
1605
|
}, {
|
|
1583
1606
|
component: mt,
|
|
1584
1607
|
...ct
|
|
1585
|
-
}, {
|
|
1586
|
-
component: ht,
|
|
1587
|
-
...gt
|
|
1588
1608
|
}, {
|
|
1589
1609
|
component: ft,
|
|
1590
1610
|
...pt
|
|
1591
1611
|
}, {
|
|
1592
|
-
component:
|
|
1593
|
-
...
|
|
1612
|
+
component: ht,
|
|
1613
|
+
...gt
|
|
1594
1614
|
}, {
|
|
1595
1615
|
component: xt,
|
|
1596
1616
|
...vt
|
|
1597
1617
|
}, {
|
|
1598
|
-
component:
|
|
1599
|
-
...
|
|
1600
|
-
}], ee = () => [{
|
|
1601
|
-
component: ke,
|
|
1602
|
-
...Me
|
|
1618
|
+
component: yt,
|
|
1619
|
+
...bt
|
|
1603
1620
|
}, {
|
|
1604
|
-
component:
|
|
1605
|
-
...
|
|
1621
|
+
component: Tt,
|
|
1622
|
+
...St
|
|
1606
1623
|
}, {
|
|
1607
|
-
component:
|
|
1608
|
-
...
|
|
1624
|
+
component: kt,
|
|
1625
|
+
...It
|
|
1609
1626
|
}, {
|
|
1610
1627
|
component: Ve,
|
|
1628
|
+
...Ct
|
|
1629
|
+
}], ie = () => [{
|
|
1630
|
+
component: Ee,
|
|
1611
1631
|
...Qe
|
|
1612
1632
|
}, {
|
|
1613
|
-
component:
|
|
1614
|
-
...
|
|
1633
|
+
component: Re,
|
|
1634
|
+
...Ye
|
|
1635
|
+
}, {
|
|
1636
|
+
component: Ae,
|
|
1637
|
+
...Ge
|
|
1615
1638
|
}, {
|
|
1616
|
-
component:
|
|
1639
|
+
component: De,
|
|
1617
1640
|
...Ze
|
|
1618
1641
|
}, {
|
|
1619
|
-
component:
|
|
1620
|
-
...
|
|
1642
|
+
component: Pe,
|
|
1643
|
+
...nt
|
|
1621
1644
|
}, {
|
|
1622
|
-
component:
|
|
1623
|
-
...
|
|
1624
|
-
},
|
|
1625
|
-
component:
|
|
1626
|
-
...
|
|
1645
|
+
component: it,
|
|
1646
|
+
...at
|
|
1647
|
+
}, {
|
|
1648
|
+
component: Fe,
|
|
1649
|
+
...ot
|
|
1650
|
+
}, {
|
|
1651
|
+
component: We,
|
|
1652
|
+
...st
|
|
1653
|
+
}, ...fe.includes(F) ? [{
|
|
1654
|
+
component: tt,
|
|
1655
|
+
...et
|
|
1627
1656
|
}] : [], {
|
|
1628
|
-
component:
|
|
1629
|
-
...
|
|
1657
|
+
component: lt,
|
|
1658
|
+
...rt
|
|
1630
1659
|
}, {
|
|
1631
|
-
component:
|
|
1632
|
-
...
|
|
1633
|
-
}, ...
|
|
1660
|
+
component: Je,
|
|
1661
|
+
...ze
|
|
1662
|
+
}, ...wt()], Vt = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget, isAngularSDK) {
|
|
1634
1663
|
function getAndSetVariantId() {
|
|
1635
1664
|
function setCookie(name, value, days) {
|
|
1636
1665
|
let expires = '';
|
|
@@ -1689,7 +1718,7 @@ const qe = () => `
|
|
|
1689
1718
|
}).join('');
|
|
1690
1719
|
styleEl.innerHTML = newStyleStr;
|
|
1691
1720
|
}
|
|
1692
|
-
}`,
|
|
1721
|
+
}`, Et = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
|
|
1693
1722
|
if (!navigator.cookieEnabled) {
|
|
1694
1723
|
return;
|
|
1695
1724
|
}
|
|
@@ -1723,27 +1752,27 @@ const qe = () => `
|
|
|
1723
1752
|
thisScriptEl?.remove();
|
|
1724
1753
|
}
|
|
1725
1754
|
return;
|
|
1726
|
-
}`,
|
|
1755
|
+
}`, he = "builderIoAbTest", be = "builderIoRenderContent", O = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
|
|
1727
1756
|
...t,
|
|
1728
1757
|
testVariationId: t.id,
|
|
1729
1758
|
id: e == null ? void 0 : e.id
|
|
1730
|
-
})),
|
|
1759
|
+
})), Rt = ({
|
|
1731
1760
|
canTrack: e,
|
|
1732
1761
|
content: t
|
|
1733
|
-
}) => !(!(
|
|
1734
|
-
window.${
|
|
1735
|
-
window.${
|
|
1736
|
-
`,
|
|
1737
|
-
window.${
|
|
1738
|
-
"${t}",${JSON.stringify(e)}, ${
|
|
1739
|
-
)`,
|
|
1762
|
+
}) => !(!(O(t).length > 0) || !e || L()), At = (e) => e === "react" || e === "reactNative", Dt = F === "angular", ye = At(F), Pt = () => `
|
|
1763
|
+
window.${he} = ${Vt}
|
|
1764
|
+
window.${be} = ${Et}
|
|
1765
|
+
`, Ft = (e, t) => `
|
|
1766
|
+
window.${he}(
|
|
1767
|
+
"${t}",${JSON.stringify(e)}, ${ye}, ${Dt}
|
|
1768
|
+
)`, Wt = ({
|
|
1740
1769
|
contentId: e,
|
|
1741
1770
|
variationId: t
|
|
1742
|
-
}) => `window.${
|
|
1743
|
-
"${t}", "${e}", ${
|
|
1771
|
+
}) => `window.${be}(
|
|
1772
|
+
"${t}", "${e}", ${ye}
|
|
1744
1773
|
)`;
|
|
1745
1774
|
function q(e) {
|
|
1746
|
-
return /* @__PURE__ */
|
|
1775
|
+
return /* @__PURE__ */ S(
|
|
1747
1776
|
"script",
|
|
1748
1777
|
{
|
|
1749
1778
|
dangerouslySetInnerHTML: { __html: e.scriptStr },
|
|
@@ -1752,10 +1781,10 @@ function q(e) {
|
|
|
1752
1781
|
}
|
|
1753
1782
|
);
|
|
1754
1783
|
}
|
|
1755
|
-
function
|
|
1784
|
+
function oe(e) {
|
|
1756
1785
|
return Math.round(e * 1e3) / 1e3;
|
|
1757
1786
|
}
|
|
1758
|
-
const
|
|
1787
|
+
const Nt = (e, t, n = !0) => {
|
|
1759
1788
|
if (!(e instanceof HTMLElement))
|
|
1760
1789
|
return null;
|
|
1761
1790
|
let o = n ? e : e.parentElement;
|
|
@@ -1766,37 +1795,37 @@ const Dt = (e, t, n = !0) => {
|
|
|
1766
1795
|
return o;
|
|
1767
1796
|
} while (o = o.parentElement);
|
|
1768
1797
|
return null;
|
|
1769
|
-
},
|
|
1798
|
+
}, $t = (e) => Nt(e, (t) => {
|
|
1770
1799
|
const n = t.getAttribute("builder-id") || t.id;
|
|
1771
1800
|
return (n == null ? void 0 : n.indexOf("builder-")) === 0;
|
|
1772
|
-
}),
|
|
1801
|
+
}), re = ({
|
|
1773
1802
|
event: e,
|
|
1774
1803
|
target: t
|
|
1775
1804
|
}) => {
|
|
1776
|
-
const n = t.getBoundingClientRect(), o = e.clientX - n.left, r = e.clientY - n.top,
|
|
1805
|
+
const n = t.getBoundingClientRect(), o = e.clientX - n.left, r = e.clientY - n.top, l = oe(o / n.width), a = oe(r / n.height);
|
|
1777
1806
|
return {
|
|
1778
|
-
x:
|
|
1779
|
-
y:
|
|
1807
|
+
x: l,
|
|
1808
|
+
y: a
|
|
1780
1809
|
};
|
|
1781
|
-
},
|
|
1782
|
-
const t = e.target, n = t &&
|
|
1810
|
+
}, _t = (e) => {
|
|
1811
|
+
const t = e.target, n = t && $t(t), o = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
|
|
1783
1812
|
return {
|
|
1784
1813
|
targetBuilderElement: o || void 0,
|
|
1785
1814
|
metadata: {
|
|
1786
|
-
targetOffset: t ?
|
|
1815
|
+
targetOffset: t ? re({
|
|
1787
1816
|
event: e,
|
|
1788
1817
|
target: t
|
|
1789
1818
|
}) : void 0,
|
|
1790
|
-
builderTargetOffset: n ?
|
|
1819
|
+
builderTargetOffset: n ? re({
|
|
1791
1820
|
event: e,
|
|
1792
1821
|
target: n
|
|
1793
1822
|
}) : void 0,
|
|
1794
1823
|
builderElementIndex: n && o ? [].slice.call(document.getElementsByClassName(o)).indexOf(n) : void 0
|
|
1795
1824
|
}
|
|
1796
1825
|
};
|
|
1797
|
-
},
|
|
1798
|
-
var
|
|
1799
|
-
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], o = (
|
|
1826
|
+
}, Lt = ["svelte", "qwik", "vue"], le = () => Lt.includes(F) && (_() || ue()), Bt = (e) => {
|
|
1827
|
+
var l, a;
|
|
1828
|
+
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], o = (a = e.fileUrl) != null ? a : (l = e == null ? void 0 : e.files) == null ? void 0 : l.regular;
|
|
1800
1829
|
let r = "";
|
|
1801
1830
|
if (o && t && n && (r += `
|
|
1802
1831
|
@font-face {
|
|
@@ -1806,29 +1835,29 @@ font-display: fallback;
|
|
|
1806
1835
|
font-weight: 400;
|
|
1807
1836
|
}
|
|
1808
1837
|
`.trim()), e.files)
|
|
1809
|
-
for (const
|
|
1810
|
-
if (!(String(Number(
|
|
1838
|
+
for (const i in e.files) {
|
|
1839
|
+
if (!(String(Number(i)) === i))
|
|
1811
1840
|
continue;
|
|
1812
|
-
const
|
|
1813
|
-
|
|
1841
|
+
const m = e.files[i];
|
|
1842
|
+
m && m !== o && (r += `
|
|
1814
1843
|
@font-face {
|
|
1815
1844
|
font-family: "${t}";
|
|
1816
|
-
src: url('${
|
|
1845
|
+
src: url('${m}') format('woff2');
|
|
1817
1846
|
font-display: fallback;
|
|
1818
|
-
font-weight: ${
|
|
1847
|
+
font-weight: ${i};
|
|
1819
1848
|
}
|
|
1820
1849
|
`.trim());
|
|
1821
1850
|
}
|
|
1822
1851
|
return r;
|
|
1823
|
-
},
|
|
1852
|
+
}, Ut = ({
|
|
1824
1853
|
customFonts: e
|
|
1825
1854
|
}) => {
|
|
1826
1855
|
var t;
|
|
1827
|
-
return ((t = e == null ? void 0 : e.map((n) =>
|
|
1828
|
-
},
|
|
1856
|
+
return ((t = e == null ? void 0 : e.map((n) => Bt(n))) == null ? void 0 : t.join(" ")) || "";
|
|
1857
|
+
}, Ht = ({
|
|
1829
1858
|
cssCode: e,
|
|
1830
1859
|
contentId: t
|
|
1831
|
-
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "",
|
|
1860
|
+
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", Ot = `
|
|
1832
1861
|
.builder-button {
|
|
1833
1862
|
all: unset;
|
|
1834
1863
|
}
|
|
@@ -1845,154 +1874,162 @@ font-weight: ${a};
|
|
|
1845
1874
|
text-align: inherit;
|
|
1846
1875
|
font-family: inherit;
|
|
1847
1876
|
}
|
|
1848
|
-
`,
|
|
1849
|
-
function
|
|
1850
|
-
var
|
|
1851
|
-
const t =
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1877
|
+
`, qt = (e) => e ? "" : Ot, jt = (e) => `variant-${e}`;
|
|
1878
|
+
function Mt(e) {
|
|
1879
|
+
var Z, ee, te;
|
|
1880
|
+
const t = Y(null);
|
|
1881
|
+
k(() => !1), k(
|
|
1882
|
+
() => e.builderContextSignal
|
|
1883
|
+
);
|
|
1884
|
+
const [n, o] = k(() => null), [r, l] = k(() => "");
|
|
1885
|
+
function a(c, h) {
|
|
1886
|
+
var y, p;
|
|
1887
|
+
const f = {
|
|
1856
1888
|
...e.builderContextSignal.rootState,
|
|
1857
1889
|
...c
|
|
1858
1890
|
};
|
|
1859
|
-
e.builderContextSignal.rootSetState ? (
|
|
1860
|
-
...
|
|
1861
|
-
rootState:
|
|
1891
|
+
e.builderContextSignal.rootSetState ? (p = (y = e.builderContextSignal).rootSetState) == null || p.call(y, f) : e.setBuilderContextSignal((b) => ({
|
|
1892
|
+
...b,
|
|
1893
|
+
rootState: f
|
|
1894
|
+
})), e.builderContextSignal.rootSetState ? e.builderContextSignal.rootSetState(f) : e.setBuilderContextSignal((b) => ({
|
|
1895
|
+
...b,
|
|
1896
|
+
rootState: f
|
|
1862
1897
|
}));
|
|
1863
1898
|
}
|
|
1864
|
-
function
|
|
1865
|
-
var
|
|
1866
|
-
const
|
|
1899
|
+
function i(c, h) {
|
|
1900
|
+
var y, p, b, P, $;
|
|
1901
|
+
const f = {
|
|
1867
1902
|
...e.builderContextSignal.content,
|
|
1868
1903
|
...c,
|
|
1869
1904
|
data: {
|
|
1870
|
-
...(
|
|
1905
|
+
...(y = e.builderContextSignal.content) == null ? void 0 : y.data,
|
|
1871
1906
|
...c == null ? void 0 : c.data
|
|
1872
1907
|
},
|
|
1873
1908
|
meta: {
|
|
1874
|
-
...(
|
|
1909
|
+
...(p = e.builderContextSignal.content) == null ? void 0 : p.meta,
|
|
1875
1910
|
...c == null ? void 0 : c.meta,
|
|
1876
|
-
breakpoints: ((
|
|
1911
|
+
breakpoints: ((b = c == null ? void 0 : c.meta) == null ? void 0 : b.breakpoints) || (($ = (P = e.builderContextSignal.content) == null ? void 0 : P.meta) == null ? void 0 : $.breakpoints)
|
|
1877
1912
|
}
|
|
1878
1913
|
};
|
|
1879
|
-
e.setBuilderContextSignal((
|
|
1880
|
-
...
|
|
1881
|
-
content:
|
|
1914
|
+
e.setBuilderContextSignal((v) => ({
|
|
1915
|
+
...v,
|
|
1916
|
+
content: f
|
|
1882
1917
|
}));
|
|
1883
1918
|
}
|
|
1884
|
-
function
|
|
1919
|
+
function u() {
|
|
1885
1920
|
return e.showContent ? {} : {
|
|
1886
1921
|
hidden: !0,
|
|
1887
1922
|
"aria-hidden": !0
|
|
1888
1923
|
};
|
|
1889
1924
|
}
|
|
1890
|
-
const [
|
|
1925
|
+
const [m, g] = k(
|
|
1891
1926
|
() => e.contentWrapper || "div"
|
|
1892
1927
|
);
|
|
1893
|
-
function
|
|
1894
|
-
return
|
|
1928
|
+
function R(c) {
|
|
1929
|
+
return Ie({
|
|
1895
1930
|
model: e.model,
|
|
1896
1931
|
trustedHosts: e.trustedHosts,
|
|
1897
1932
|
callbacks: {
|
|
1898
|
-
configureSdk: (
|
|
1899
|
-
var
|
|
1900
|
-
const { breakpoints:
|
|
1901
|
-
!
|
|
1933
|
+
configureSdk: (h) => {
|
|
1934
|
+
var p;
|
|
1935
|
+
const { breakpoints: f, contentId: y } = h;
|
|
1936
|
+
!y || y !== ((p = e.builderContextSignal.content) == null ? void 0 : p.id) || f && i({
|
|
1902
1937
|
meta: {
|
|
1903
|
-
breakpoints:
|
|
1938
|
+
breakpoints: f
|
|
1904
1939
|
}
|
|
1905
1940
|
});
|
|
1906
1941
|
},
|
|
1907
|
-
animation: (
|
|
1908
|
-
|
|
1942
|
+
animation: (h) => {
|
|
1943
|
+
$e(h);
|
|
1909
1944
|
},
|
|
1910
|
-
contentUpdate: (
|
|
1911
|
-
|
|
1945
|
+
contentUpdate: (h, f) => {
|
|
1946
|
+
i(h);
|
|
1912
1947
|
},
|
|
1913
|
-
stateUpdate: (
|
|
1914
|
-
|
|
1948
|
+
stateUpdate: (h, f) => {
|
|
1949
|
+
a(h);
|
|
1915
1950
|
}
|
|
1916
1951
|
}
|
|
1917
1952
|
})(c);
|
|
1918
1953
|
}
|
|
1919
|
-
const [
|
|
1920
|
-
function
|
|
1921
|
-
var
|
|
1954
|
+
const [T, A] = k(() => ({})), [s, d] = k(() => ({})), [D, B] = k(() => !1);
|
|
1955
|
+
function I(c) {
|
|
1956
|
+
var h, f;
|
|
1922
1957
|
if (e.builderContextSignal.content) {
|
|
1923
|
-
const
|
|
1924
|
-
|
|
1958
|
+
const y = (h = e.builderContextSignal.content) == null ? void 0 : h.testVariationId, p = (f = e.builderContextSignal.content) == null ? void 0 : f.id;
|
|
1959
|
+
ne({
|
|
1925
1960
|
apiHost: e.apiHost,
|
|
1926
1961
|
type: "click",
|
|
1927
|
-
canTrack:
|
|
1928
|
-
contentId:
|
|
1962
|
+
canTrack: j(e.canTrack),
|
|
1963
|
+
contentId: p,
|
|
1929
1964
|
apiKey: e.apiKey,
|
|
1930
|
-
variationId:
|
|
1931
|
-
...
|
|
1932
|
-
unique: !
|
|
1965
|
+
variationId: y !== p ? y : void 0,
|
|
1966
|
+
..._t(c),
|
|
1967
|
+
unique: !D
|
|
1933
1968
|
});
|
|
1934
1969
|
}
|
|
1935
|
-
|
|
1970
|
+
D || B(!0);
|
|
1936
1971
|
}
|
|
1937
|
-
function
|
|
1938
|
-
var
|
|
1939
|
-
const c = (
|
|
1972
|
+
function w() {
|
|
1973
|
+
var h, f, y;
|
|
1974
|
+
const c = (y = (f = (h = e.builderContextSignal.content) == null ? void 0 : h.data) == null ? void 0 : f.httpRequests) != null ? y : {};
|
|
1940
1975
|
Object.entries(c).forEach(
|
|
1941
|
-
([
|
|
1942
|
-
if (!
|
|
1976
|
+
([p, b]) => {
|
|
1977
|
+
if (!b)
|
|
1943
1978
|
return;
|
|
1944
|
-
const
|
|
1945
|
-
if (
|
|
1979
|
+
const P = typeof b == "object" && b["@type"] === "@builder.io/core:Request";
|
|
1980
|
+
if (s[p] || T[p] && !_())
|
|
1946
1981
|
return;
|
|
1947
|
-
const
|
|
1948
|
-
|
|
1949
|
-
const
|
|
1982
|
+
const $ = P ? b.request.url : b;
|
|
1983
|
+
s[p] = !0;
|
|
1984
|
+
const v = $.replace(
|
|
1950
1985
|
/{{([^}]+)}}/g,
|
|
1951
|
-
(
|
|
1952
|
-
|
|
1953
|
-
code:
|
|
1986
|
+
(E, U) => String(
|
|
1987
|
+
de({
|
|
1988
|
+
code: U,
|
|
1954
1989
|
context: e.context || {},
|
|
1955
1990
|
localState: void 0,
|
|
1956
1991
|
rootState: e.builderContextSignal.rootState,
|
|
1957
1992
|
rootSetState: e.builderContextSignal.rootSetState
|
|
1958
1993
|
})
|
|
1959
1994
|
)
|
|
1960
|
-
),
|
|
1961
|
-
url:
|
|
1962
|
-
method:
|
|
1963
|
-
headers:
|
|
1964
|
-
body:
|
|
1995
|
+
), x = P ? {
|
|
1996
|
+
url: v,
|
|
1997
|
+
method: b.request.method,
|
|
1998
|
+
headers: b.request.headers,
|
|
1999
|
+
body: b.request.body
|
|
1965
2000
|
} : {
|
|
1966
|
-
url:
|
|
2001
|
+
url: v,
|
|
1967
2002
|
method: "GET"
|
|
1968
2003
|
};
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
2004
|
+
ke(JSON.stringify(x));
|
|
2005
|
+
const W = {
|
|
2006
|
+
method: x.method,
|
|
2007
|
+
headers: x.headers,
|
|
2008
|
+
body: x.body
|
|
2009
|
+
};
|
|
2010
|
+
x.method === "GET" && delete W.body, fetch(x.url, W).then((E) => E.json()).then((E) => {
|
|
2011
|
+
a({
|
|
2012
|
+
[p]: E
|
|
2013
|
+
}), T[p] = !0;
|
|
2014
|
+
}).catch((E) => {
|
|
1978
2015
|
console.error(
|
|
1979
2016
|
"error fetching dynamic data",
|
|
1980
|
-
JSON.stringify(
|
|
1981
|
-
|
|
2017
|
+
JSON.stringify(b),
|
|
2018
|
+
E
|
|
1982
2019
|
);
|
|
1983
2020
|
}).finally(() => {
|
|
1984
|
-
|
|
2021
|
+
s[p] = !1;
|
|
1985
2022
|
});
|
|
1986
2023
|
}
|
|
1987
2024
|
);
|
|
1988
2025
|
}
|
|
1989
|
-
function
|
|
1990
|
-
|
|
2026
|
+
function V() {
|
|
2027
|
+
_() && window.dispatchEvent(
|
|
1991
2028
|
new CustomEvent(
|
|
1992
2029
|
"builder:component:stateChange",
|
|
1993
2030
|
{
|
|
1994
2031
|
detail: {
|
|
1995
|
-
state:
|
|
2032
|
+
state: _e(e.builderContextSignal.rootState),
|
|
1996
2033
|
ref: {
|
|
1997
2034
|
name: e.model
|
|
1998
2035
|
}
|
|
@@ -2001,11 +2038,11 @@ function Ht(e) {
|
|
|
2001
2038
|
)
|
|
2002
2039
|
);
|
|
2003
2040
|
}
|
|
2004
|
-
const
|
|
2005
|
-
return
|
|
2006
|
-
var c,
|
|
2007
|
-
if (
|
|
2008
|
-
|
|
2041
|
+
const X = Y(!1);
|
|
2042
|
+
return X.current || (w(), V(), X.current = !0), N(() => {
|
|
2043
|
+
var c, h, f, y, p;
|
|
2044
|
+
if (L()) {
|
|
2045
|
+
_() && !e.isNestedRender && (window.addEventListener("message", R), ve({
|
|
2009
2046
|
...e.locale ? {
|
|
2010
2047
|
locale: e.locale
|
|
2011
2048
|
} : {},
|
|
@@ -2019,98 +2056,106 @@ function Ht(e) {
|
|
|
2019
2056
|
apiKey: e.apiKey
|
|
2020
2057
|
}), Object.values(
|
|
2021
2058
|
e.builderContextSignal.componentInfos
|
|
2022
|
-
).forEach((
|
|
2023
|
-
var
|
|
2024
|
-
if (!((
|
|
2025
|
-
const
|
|
2026
|
-
(
|
|
2059
|
+
).forEach((v) => {
|
|
2060
|
+
var x, W;
|
|
2061
|
+
if (!((x = v.models) != null && x.length) || v.models.includes(e.model)) {
|
|
2062
|
+
const E = xe(v);
|
|
2063
|
+
(W = window.parent) == null || W.postMessage(E, "*");
|
|
2027
2064
|
}
|
|
2028
2065
|
}), window.addEventListener(
|
|
2029
2066
|
"builder:component:stateChangeListenerActivated",
|
|
2030
|
-
|
|
2067
|
+
V
|
|
2031
2068
|
));
|
|
2032
|
-
const
|
|
2033
|
-
name: `builder.tests.${(
|
|
2069
|
+
const b = e.builderContextSignal.content && j(e.canTrack), P = Se({
|
|
2070
|
+
name: `builder.tests.${(h = e.builderContextSignal.content) == null ? void 0 : h.id}`,
|
|
2034
2071
|
canTrack: !0
|
|
2035
|
-
}),
|
|
2036
|
-
if (
|
|
2037
|
-
const
|
|
2038
|
-
|
|
2072
|
+
}), $ = (f = e.builderContextSignal.content) == null ? void 0 : f.testVariationId;
|
|
2073
|
+
if (b && $ === P) {
|
|
2074
|
+
const v = (y = e.builderContextSignal.content) == null ? void 0 : y.id, x = e.apiKey;
|
|
2075
|
+
ne({
|
|
2039
2076
|
apiHost: e.apiHost,
|
|
2040
2077
|
type: "impression",
|
|
2041
2078
|
canTrack: !0,
|
|
2042
|
-
contentId:
|
|
2043
|
-
apiKey:
|
|
2044
|
-
variationId:
|
|
2079
|
+
contentId: v,
|
|
2080
|
+
apiKey: x,
|
|
2081
|
+
variationId: P !== v ? P : void 0
|
|
2045
2082
|
});
|
|
2046
2083
|
}
|
|
2047
|
-
if (
|
|
2048
|
-
const
|
|
2049
|
-
`builder.overrides.${
|
|
2050
|
-
),
|
|
2051
|
-
(
|
|
2084
|
+
if (ue() && !_()) {
|
|
2085
|
+
const v = new URL(location.href).searchParams, x = v.get("builder.preview"), W = v.get(
|
|
2086
|
+
`builder.overrides.${x}`
|
|
2087
|
+
), E = v.get("apiKey") || v.get("builder.space");
|
|
2088
|
+
(x === "BUILDER_STUDIO" || x === e.model && E === e.apiKey && (!e.content || W === e.content.id)) && Te({
|
|
2052
2089
|
model: e.model,
|
|
2053
2090
|
apiKey: e.apiKey,
|
|
2054
2091
|
apiVersion: e.builderContextSignal.apiVersion,
|
|
2055
|
-
...
|
|
2092
|
+
...x === "BUILDER_STUDIO" && ((p = e.context) != null && p.symbolId) ? {
|
|
2056
2093
|
query: {
|
|
2057
2094
|
id: e.context.symbolId
|
|
2058
2095
|
}
|
|
2059
2096
|
} : {}
|
|
2060
|
-
}).then((
|
|
2061
|
-
|
|
2097
|
+
}).then((U) => {
|
|
2098
|
+
U && i(U);
|
|
2062
2099
|
});
|
|
2063
2100
|
}
|
|
2064
2101
|
}
|
|
2065
|
-
}, []),
|
|
2066
|
-
e.content &&
|
|
2067
|
-
}, [e.content]),
|
|
2068
|
-
|
|
2069
|
-
}, [e.builderContextSignal.rootState]),
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
}
|
|
2075
|
-
}, [e.
|
|
2076
|
-
|
|
2102
|
+
}, []), N(() => {
|
|
2103
|
+
e.content && i(e.content);
|
|
2104
|
+
}, [e.content]), N(() => {
|
|
2105
|
+
V();
|
|
2106
|
+
}, [e.builderContextSignal.rootState]), N(() => {
|
|
2107
|
+
if (e.data) {
|
|
2108
|
+
if (n === e.data)
|
|
2109
|
+
return;
|
|
2110
|
+
a(e.data), o(e.data);
|
|
2111
|
+
}
|
|
2112
|
+
}, [e.data]), N(() => {
|
|
2113
|
+
if (e.locale) {
|
|
2114
|
+
if (r === e.locale)
|
|
2115
|
+
return;
|
|
2116
|
+
a({
|
|
2117
|
+
locale: e.locale
|
|
2118
|
+
}), l(e.locale);
|
|
2119
|
+
}
|
|
2120
|
+
}, [e.locale]), N(() => () => {
|
|
2121
|
+
L() && (window.removeEventListener("message", R), window.removeEventListener(
|
|
2077
2122
|
"builder:component:stateChangeListenerActivated",
|
|
2078
|
-
|
|
2123
|
+
V
|
|
2079
2124
|
));
|
|
2080
|
-
}, []), /* @__PURE__ */
|
|
2081
|
-
|
|
2125
|
+
}, []), /* @__PURE__ */ S(Ne.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content || le() ? /* @__PURE__ */ S(
|
|
2126
|
+
m,
|
|
2082
2127
|
{
|
|
2083
2128
|
ref: t,
|
|
2084
|
-
onClick: (c) =>
|
|
2085
|
-
"builder-content-id": (
|
|
2129
|
+
onClick: (c) => I(c),
|
|
2130
|
+
"builder-content-id": (Z = e.builderContextSignal.content) == null ? void 0 : Z.id,
|
|
2086
2131
|
"builder-model": e.model,
|
|
2087
|
-
className:
|
|
2088
|
-
((
|
|
2132
|
+
className: jt(
|
|
2133
|
+
((ee = e.content) == null ? void 0 : ee.testVariationId) || ((te = e.content) == null ? void 0 : te.id)
|
|
2089
2134
|
),
|
|
2090
2135
|
style: {
|
|
2091
|
-
display: !e.builderContextSignal.content &&
|
|
2136
|
+
display: !e.builderContextSignal.content && le() ? "none" : void 0
|
|
2092
2137
|
},
|
|
2093
|
-
...
|
|
2138
|
+
...u(),
|
|
2094
2139
|
...e.contentWrapperProps,
|
|
2095
2140
|
children: e.children
|
|
2096
2141
|
}
|
|
2097
2142
|
) : null });
|
|
2098
2143
|
}
|
|
2099
|
-
function
|
|
2100
|
-
const [t, n] =
|
|
2144
|
+
function Kt(e) {
|
|
2145
|
+
const [t, n] = k(
|
|
2101
2146
|
() => `
|
|
2102
|
-
${
|
|
2147
|
+
${Ht({
|
|
2103
2148
|
cssCode: e.cssCode,
|
|
2104
2149
|
contentId: e.contentId
|
|
2105
2150
|
})}
|
|
2106
|
-
${
|
|
2151
|
+
${Ut({
|
|
2107
2152
|
customFonts: e.customFonts
|
|
2108
2153
|
})}
|
|
2109
|
-
${
|
|
2154
|
+
${qt(e.isNestedRender)}
|
|
2110
2155
|
`.trim()
|
|
2111
2156
|
);
|
|
2112
|
-
return /* @__PURE__ */
|
|
2113
|
-
|
|
2157
|
+
return /* @__PURE__ */ S(
|
|
2158
|
+
ce,
|
|
2114
2159
|
{
|
|
2115
2160
|
id: "builderio-content",
|
|
2116
2161
|
styles: t,
|
|
@@ -2118,15 +2163,15 @@ ${Ut(e.isNestedRender)}
|
|
|
2118
2163
|
}
|
|
2119
2164
|
);
|
|
2120
2165
|
}
|
|
2121
|
-
const
|
|
2166
|
+
const zt = ({
|
|
2122
2167
|
content: e,
|
|
2123
2168
|
data: t,
|
|
2124
2169
|
locale: n
|
|
2125
2170
|
}) => {
|
|
2126
|
-
var
|
|
2127
|
-
const o = {}, r = ((
|
|
2128
|
-
return (
|
|
2129
|
-
|
|
2171
|
+
var l, a, i;
|
|
2172
|
+
const o = {}, r = ((l = e == null ? void 0 : e.data) == null ? void 0 : l.state) || {};
|
|
2173
|
+
return (i = (a = e == null ? void 0 : e.data) == null ? void 0 : a.inputs) == null || i.forEach((u) => {
|
|
2174
|
+
u.name && u.defaultValue !== void 0 && (o[u.name] = u.defaultValue);
|
|
2130
2175
|
}), {
|
|
2131
2176
|
...o,
|
|
2132
2177
|
...r,
|
|
@@ -2135,7 +2180,7 @@ const Ot = ({
|
|
|
2135
2180
|
locale: n
|
|
2136
2181
|
} : {}
|
|
2137
2182
|
};
|
|
2138
|
-
},
|
|
2183
|
+
}, Jt = ({
|
|
2139
2184
|
content: e,
|
|
2140
2185
|
data: t
|
|
2141
2186
|
}) => e ? {
|
|
@@ -2146,46 +2191,46 @@ const Ot = ({
|
|
|
2146
2191
|
},
|
|
2147
2192
|
meta: e == null ? void 0 : e.meta
|
|
2148
2193
|
} : void 0;
|
|
2149
|
-
function
|
|
2150
|
-
var
|
|
2151
|
-
const [t, n] =
|
|
2194
|
+
function se(e) {
|
|
2195
|
+
var m, g, R, T, A, s, d, D, B;
|
|
2196
|
+
const [t, n] = k(
|
|
2152
2197
|
() => {
|
|
2153
|
-
var
|
|
2154
|
-
return
|
|
2198
|
+
var I, w;
|
|
2199
|
+
return Wt({
|
|
2155
2200
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2156
|
-
variationId: (
|
|
2201
|
+
variationId: (I = e.content) == null ? void 0 : I.testVariationId,
|
|
2157
2202
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2158
|
-
contentId: (
|
|
2203
|
+
contentId: (w = e.content) == null ? void 0 : w.id
|
|
2159
2204
|
});
|
|
2160
2205
|
}
|
|
2161
2206
|
);
|
|
2162
|
-
function o(
|
|
2163
|
-
|
|
2164
|
-
...
|
|
2165
|
-
rootState:
|
|
2207
|
+
function o(I) {
|
|
2208
|
+
i((w) => ({
|
|
2209
|
+
...w,
|
|
2210
|
+
rootState: I
|
|
2166
2211
|
}));
|
|
2167
2212
|
}
|
|
2168
|
-
const [r,
|
|
2213
|
+
const [r, l] = k(
|
|
2169
2214
|
() => [
|
|
2170
|
-
...
|
|
2215
|
+
...ie(),
|
|
2171
2216
|
...e.customComponents || []
|
|
2172
2217
|
].reduce(
|
|
2173
|
-
(
|
|
2174
|
-
...
|
|
2175
|
-
[
|
|
2176
|
-
component:
|
|
2177
|
-
...
|
|
2218
|
+
(I, { component: w, ...V }) => ({
|
|
2219
|
+
...I,
|
|
2220
|
+
[V.name]: {
|
|
2221
|
+
component: w,
|
|
2222
|
+
...ae(V)
|
|
2178
2223
|
}
|
|
2179
2224
|
}),
|
|
2180
2225
|
{}
|
|
2181
2226
|
)
|
|
2182
|
-
), [
|
|
2183
|
-
content:
|
|
2227
|
+
), [a, i] = k(() => ({
|
|
2228
|
+
content: Jt({
|
|
2184
2229
|
content: e.content,
|
|
2185
2230
|
data: e.data
|
|
2186
2231
|
}),
|
|
2187
2232
|
localState: void 0,
|
|
2188
|
-
rootState:
|
|
2233
|
+
rootState: zt({
|
|
2189
2234
|
content: e.content,
|
|
2190
2235
|
data: e.data,
|
|
2191
2236
|
locale: e.locale
|
|
@@ -2196,12 +2241,12 @@ function ie(e) {
|
|
|
2196
2241
|
apiKey: e.apiKey,
|
|
2197
2242
|
apiVersion: e.apiVersion,
|
|
2198
2243
|
componentInfos: [
|
|
2199
|
-
...
|
|
2244
|
+
...ie(),
|
|
2200
2245
|
...e.customComponents || []
|
|
2201
2246
|
].reduce(
|
|
2202
|
-
(
|
|
2203
|
-
...
|
|
2204
|
-
[
|
|
2247
|
+
(I, { component: w, ...V }) => ({
|
|
2248
|
+
...I,
|
|
2249
|
+
[V.name]: ae(V)
|
|
2205
2250
|
}),
|
|
2206
2251
|
{}
|
|
2207
2252
|
),
|
|
@@ -2210,31 +2255,31 @@ function ie(e) {
|
|
|
2210
2255
|
BlocksWrapperProps: e.blocksWrapperProps || {},
|
|
2211
2256
|
nonce: e.nonce || "",
|
|
2212
2257
|
model: e.model
|
|
2213
|
-
})),
|
|
2214
|
-
if (!
|
|
2215
|
-
e.apiKey ||
|
|
2258
|
+
})), u = Y(!1);
|
|
2259
|
+
if (!u.current) {
|
|
2260
|
+
e.apiKey || Ce.error(
|
|
2216
2261
|
"No API key provided to `Content` component. This can cause issues. Please provide an API key using the `apiKey` prop."
|
|
2217
2262
|
);
|
|
2218
|
-
const
|
|
2219
|
-
|
|
2220
|
-
code:
|
|
2263
|
+
const I = (g = (m = a.content) == null ? void 0 : m.data) == null ? void 0 : g.jsCode;
|
|
2264
|
+
I && de({
|
|
2265
|
+
code: I,
|
|
2221
2266
|
context: e.context || {},
|
|
2222
2267
|
localState: void 0,
|
|
2223
|
-
rootState:
|
|
2224
|
-
rootSetState: (
|
|
2225
|
-
Object.assign(
|
|
2268
|
+
rootState: a.rootState,
|
|
2269
|
+
rootSetState: (w) => {
|
|
2270
|
+
Object.assign(a.rootState, w);
|
|
2226
2271
|
},
|
|
2227
2272
|
isExpression: !1
|
|
2228
|
-
}),
|
|
2273
|
+
}), u.current = !0;
|
|
2229
2274
|
}
|
|
2230
|
-
return /* @__PURE__ */
|
|
2231
|
-
|
|
2275
|
+
return /* @__PURE__ */ S(
|
|
2276
|
+
Le.Provider,
|
|
2232
2277
|
{
|
|
2233
2278
|
value: {
|
|
2234
2279
|
registeredComponents: r
|
|
2235
2280
|
},
|
|
2236
|
-
children: /* @__PURE__ */
|
|
2237
|
-
|
|
2281
|
+
children: /* @__PURE__ */ H(
|
|
2282
|
+
Mt,
|
|
2238
2283
|
{
|
|
2239
2284
|
apiHost: e.apiHost,
|
|
2240
2285
|
nonce: e.nonce,
|
|
@@ -2247,14 +2292,14 @@ function ie(e) {
|
|
|
2247
2292
|
locale: e.locale,
|
|
2248
2293
|
enrich: e.enrich,
|
|
2249
2294
|
showContent: e.showContent,
|
|
2250
|
-
builderContextSignal:
|
|
2295
|
+
builderContextSignal: a,
|
|
2251
2296
|
contentWrapper: e.contentWrapper,
|
|
2252
2297
|
contentWrapperProps: e.contentWrapperProps,
|
|
2253
2298
|
trustedHosts: e.trustedHosts,
|
|
2254
2299
|
isNestedRender: e.isNestedRender,
|
|
2255
|
-
setBuilderContextSignal:
|
|
2300
|
+
setBuilderContextSignal: i,
|
|
2256
2301
|
children: [
|
|
2257
|
-
e.isSsrAbTest ? /* @__PURE__ */
|
|
2302
|
+
e.isSsrAbTest ? /* @__PURE__ */ S(
|
|
2258
2303
|
q,
|
|
2259
2304
|
{
|
|
2260
2305
|
id: "builderio-variant-visibility",
|
|
@@ -2262,21 +2307,21 @@ function ie(e) {
|
|
|
2262
2307
|
nonce: e.nonce || ""
|
|
2263
2308
|
}
|
|
2264
2309
|
) : null,
|
|
2265
|
-
/* @__PURE__ */
|
|
2266
|
-
|
|
2310
|
+
/* @__PURE__ */ S(
|
|
2311
|
+
Kt,
|
|
2267
2312
|
{
|
|
2268
2313
|
nonce: e.nonce || "",
|
|
2269
2314
|
isNestedRender: e.isNestedRender,
|
|
2270
|
-
contentId: (
|
|
2271
|
-
cssCode: (
|
|
2272
|
-
customFonts: (
|
|
2315
|
+
contentId: (R = a.content) == null ? void 0 : R.id,
|
|
2316
|
+
cssCode: (A = (T = a.content) == null ? void 0 : T.data) == null ? void 0 : A.cssCode,
|
|
2317
|
+
customFonts: (d = (s = a.content) == null ? void 0 : s.data) == null ? void 0 : d.customFonts
|
|
2273
2318
|
}
|
|
2274
2319
|
),
|
|
2275
|
-
/* @__PURE__ */
|
|
2276
|
-
|
|
2320
|
+
/* @__PURE__ */ S(
|
|
2321
|
+
Be,
|
|
2277
2322
|
{
|
|
2278
|
-
blocks: (
|
|
2279
|
-
context:
|
|
2323
|
+
blocks: (B = (D = a.content) == null ? void 0 : D.data) == null ? void 0 : B.blocks,
|
|
2324
|
+
context: a,
|
|
2280
2325
|
registeredComponents: r,
|
|
2281
2326
|
linkComponent: e.linkComponent
|
|
2282
2327
|
}
|
|
@@ -2287,67 +2332,67 @@ function ie(e) {
|
|
|
2287
2332
|
}
|
|
2288
2333
|
);
|
|
2289
2334
|
}
|
|
2290
|
-
function
|
|
2291
|
-
var
|
|
2292
|
-
const [t, n] =
|
|
2293
|
-
() =>
|
|
2294
|
-
canTrack:
|
|
2335
|
+
function Qt(e) {
|
|
2336
|
+
var a;
|
|
2337
|
+
const [t, n] = k(
|
|
2338
|
+
() => Rt({
|
|
2339
|
+
canTrack: j(e.canTrack),
|
|
2295
2340
|
content: e.content
|
|
2296
2341
|
})
|
|
2297
2342
|
);
|
|
2298
2343
|
function o() {
|
|
2299
|
-
var
|
|
2300
|
-
return
|
|
2301
|
-
|
|
2302
|
-
id:
|
|
2303
|
-
testRatio:
|
|
2344
|
+
var i;
|
|
2345
|
+
return Ft(
|
|
2346
|
+
O(e.content).map((u) => ({
|
|
2347
|
+
id: u.testVariationId,
|
|
2348
|
+
testRatio: u.testRatio
|
|
2304
2349
|
})),
|
|
2305
|
-
((
|
|
2350
|
+
((i = e.content) == null ? void 0 : i.id) || ""
|
|
2306
2351
|
);
|
|
2307
2352
|
}
|
|
2308
2353
|
function r() {
|
|
2309
|
-
return
|
|
2354
|
+
return O(e.content).map((i) => `.variant-${i.testVariationId} { display: none; } `).join("");
|
|
2310
2355
|
}
|
|
2311
|
-
function
|
|
2312
|
-
var
|
|
2356
|
+
function l() {
|
|
2357
|
+
var i;
|
|
2313
2358
|
return t ? {
|
|
2314
2359
|
...e.content,
|
|
2315
|
-
testVariationId: (
|
|
2316
|
-
} :
|
|
2360
|
+
testVariationId: (i = e.content) == null ? void 0 : i.id
|
|
2361
|
+
} : we({
|
|
2317
2362
|
item: e.content,
|
|
2318
|
-
canTrack:
|
|
2363
|
+
canTrack: j(e.canTrack)
|
|
2319
2364
|
});
|
|
2320
2365
|
}
|
|
2321
|
-
return
|
|
2322
|
-
}, []), /* @__PURE__ */
|
|
2323
|
-
!e.isNestedRender && F !== "reactNative" ? /* @__PURE__ */
|
|
2324
|
-
/* @__PURE__ */
|
|
2366
|
+
return N(() => {
|
|
2367
|
+
}, []), /* @__PURE__ */ H(M, { children: [
|
|
2368
|
+
!e.isNestedRender && F !== "reactNative" ? /* @__PURE__ */ H(M, { children: [
|
|
2369
|
+
/* @__PURE__ */ S(
|
|
2325
2370
|
q,
|
|
2326
2371
|
{
|
|
2327
2372
|
id: "builderio-init-variants-fns",
|
|
2328
|
-
scriptStr:
|
|
2373
|
+
scriptStr: Pt(),
|
|
2329
2374
|
nonce: e.nonce || ""
|
|
2330
2375
|
}
|
|
2331
2376
|
),
|
|
2332
|
-
|
|
2377
|
+
fe.includes(F) ? /* @__PURE__ */ S(
|
|
2333
2378
|
q,
|
|
2334
2379
|
{
|
|
2335
2380
|
id: "builderio-init-personalization-variants-fns",
|
|
2336
2381
|
nonce: e.nonce || "",
|
|
2337
|
-
scriptStr:
|
|
2382
|
+
scriptStr: Ke()
|
|
2338
2383
|
}
|
|
2339
2384
|
) : null
|
|
2340
2385
|
] }) : null,
|
|
2341
|
-
t ? /* @__PURE__ */
|
|
2342
|
-
/* @__PURE__ */
|
|
2343
|
-
|
|
2386
|
+
t ? /* @__PURE__ */ H(M, { children: [
|
|
2387
|
+
/* @__PURE__ */ S(
|
|
2388
|
+
ce,
|
|
2344
2389
|
{
|
|
2345
2390
|
id: "builderio-variants",
|
|
2346
2391
|
styles: r(),
|
|
2347
2392
|
nonce: e.nonce || ""
|
|
2348
2393
|
}
|
|
2349
2394
|
),
|
|
2350
|
-
/* @__PURE__ */
|
|
2395
|
+
/* @__PURE__ */ S(
|
|
2351
2396
|
q,
|
|
2352
2397
|
{
|
|
2353
2398
|
id: "builderio-variants-visibility",
|
|
@@ -2355,13 +2400,13 @@ function Mt(e) {
|
|
|
2355
2400
|
nonce: e.nonce || ""
|
|
2356
2401
|
}
|
|
2357
2402
|
),
|
|
2358
|
-
(
|
|
2359
|
-
|
|
2403
|
+
(a = O(e.content)) == null ? void 0 : a.map((i) => /* @__PURE__ */ S(
|
|
2404
|
+
se,
|
|
2360
2405
|
{
|
|
2361
2406
|
apiHost: e.apiHost,
|
|
2362
2407
|
isNestedRender: e.isNestedRender,
|
|
2363
2408
|
nonce: e.nonce,
|
|
2364
|
-
content:
|
|
2409
|
+
content: i,
|
|
2365
2410
|
showContent: !1,
|
|
2366
2411
|
model: e.model,
|
|
2367
2412
|
data: e.data,
|
|
@@ -2380,16 +2425,16 @@ function Mt(e) {
|
|
|
2380
2425
|
contentWrapperProps: e.contentWrapperProps,
|
|
2381
2426
|
trustedHosts: e.trustedHosts
|
|
2382
2427
|
},
|
|
2383
|
-
|
|
2428
|
+
i.testVariationId
|
|
2384
2429
|
))
|
|
2385
2430
|
] }) : null,
|
|
2386
|
-
/* @__PURE__ */
|
|
2387
|
-
|
|
2431
|
+
/* @__PURE__ */ S(
|
|
2432
|
+
se,
|
|
2388
2433
|
{
|
|
2389
2434
|
apiHost: e.apiHost,
|
|
2390
2435
|
nonce: e.nonce,
|
|
2391
2436
|
isNestedRender: e.isNestedRender,
|
|
2392
|
-
content:
|
|
2437
|
+
content: l(),
|
|
2393
2438
|
showContent: !0,
|
|
2394
2439
|
model: e.model,
|
|
2395
2440
|
data: e.data,
|
|
@@ -2411,18 +2456,18 @@ function Mt(e) {
|
|
|
2411
2456
|
)
|
|
2412
2457
|
] });
|
|
2413
2458
|
}
|
|
2414
|
-
const
|
|
2459
|
+
const ln = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2415
2460
|
__proto__: null,
|
|
2416
|
-
default:
|
|
2461
|
+
default: Qt
|
|
2417
2462
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
2418
2463
|
export {
|
|
2419
|
-
|
|
2464
|
+
qe as DEFAULT_INDEX,
|
|
2420
2465
|
q as InlinedScript,
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2426
|
-
|
|
2427
|
-
|
|
2466
|
+
Me as SDKS_REQUIRING_RESET_APPROACH,
|
|
2467
|
+
nn as checkShouldRenderVariants,
|
|
2468
|
+
ln as contentVariants,
|
|
2469
|
+
tn as filterWithCustomTargeting,
|
|
2470
|
+
an as getBlocksToRender,
|
|
2471
|
+
on as getPersonalizationScript,
|
|
2472
|
+
rn as getUpdateVisibilityStylesScript
|
|
2428
2473
|
};
|