@builder.io/sdk-react 1.0.27 → 1.0.29
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 +29 -29
- package/lib/browser/blocks-exports.mjs +1031 -788
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/init.cjs +1 -1
- package/lib/browser/init.mjs +1 -1
- package/lib/browser/{server-entry-60c3f2b2.cjs → server-entry-29038134.cjs} +1 -1
- package/lib/browser/{server-entry-805a2c2a.js → server-entry-99f6be25.js} +1 -1
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/accordion-a922b6f1.js +131 -0
- package/lib/edge/accordion-cf80a119.cjs +1 -0
- package/lib/edge/{blocks-af5c8ecf.cjs → blocks-0b5854b9.cjs} +10 -10
- package/lib/edge/{blocks-a1399a78.js → blocks-2cd920f9.js} +198 -198
- package/lib/edge/blocks-exports.cjs +1 -1
- package/lib/edge/blocks-exports.mjs +2 -2
- package/lib/edge/{button-16076ac7.cjs → button-2e6cc4b7.cjs} +1 -1
- package/lib/edge/{button-0820a5bc.js → button-e343aea4.js} +2 -2
- package/lib/edge/{columns-688cc205.js → columns-5db55b04.js} +5 -5
- package/lib/edge/{columns-6b8c03be.cjs → columns-cf320d97.cjs} +2 -2
- package/lib/edge/content-variants-d7612a4d.cjs +134 -0
- package/lib/edge/{content-variants-efa4f81b.js → content-variants-dd520b38.js} +313 -192
- package/lib/edge/form-7248b44c.cjs +1 -0
- package/lib/edge/{form-cbe7d822.js → form-a0093dd2.js} +17 -19
- package/lib/edge/{get-class-prop-name-47012c9c.cjs → get-class-prop-name-890dc6a6.cjs} +1 -1
- package/lib/edge/{get-class-prop-name-4a1bad2b.js → get-class-prop-name-f14607dc.js} +1 -1
- package/lib/edge/{img-d3420f5d.cjs → img-960eef70.cjs} +1 -1
- package/lib/edge/{img-14849a5b.js → img-ff2f388e.js} +1 -1
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/init.cjs +1 -1
- package/lib/edge/init.mjs +1 -1
- package/lib/edge/{input-534b9f95.js → input-5934355a.js} +1 -1
- package/lib/edge/{input-07becc4d.cjs → input-e91374cc.cjs} +1 -1
- package/lib/edge/{select-b05ef24f.js → select-298649a8.js} +1 -1
- package/lib/edge/{select-e576d7d0.cjs → select-6e9fb36f.cjs} +1 -1
- package/lib/edge/{server-entry-ee324b22.cjs → server-entry-7feea5b4.cjs} +1 -1
- package/lib/edge/{server-entry-6aaf6054.js → server-entry-d8f1ea14.js} +1 -1
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/edge/{slot-e139f9b4.cjs → slot-3a6d243c.cjs} +1 -1
- package/lib/edge/{slot-944437dd.js → slot-5676b4f4.js} +3 -3
- package/lib/edge/{symbol-75d1c60d.js → symbol-2df385d5.js} +2 -2
- package/lib/edge/{symbol-f7f42446.cjs → symbol-b5a02759.cjs} +1 -1
- package/lib/edge/tabs-036057d6.cjs +1 -0
- package/lib/edge/{tabs-62e415e1.js → tabs-c2055821.js} +20 -20
- package/lib/node/blocks-exports.cjs +29 -29
- package/lib/node/blocks-exports.mjs +1034 -791
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +2 -2
- package/lib/node/init.cjs +1 -1
- package/lib/node/init.mjs +2 -2
- package/lib/node/{node-runtime-1bee7133.cjs → node-runtime-4dbd8a34.cjs} +1 -1
- package/lib/node/{node-runtime-e167306c.js → node-runtime-502f7164.js} +1 -1
- package/lib/node/{server-entry-db936548.cjs → server-entry-4c4c63b3.cjs} +1 -1
- package/lib/node/{server-entry-38fb2258.js → server-entry-95efff43.js} +1 -1
- package/lib/node/server-entry.cjs +1 -1
- package/lib/node/server-entry.mjs +1 -1
- package/package.json +3 -3
- package/types/blocks/accordion/accordion.d.ts +4 -0
- package/types/blocks/accordion/accordion.types.d.ts +12 -0
- package/types/blocks/accordion/component-info.d.ts +2 -0
- package/types/blocks/accordion/helpers.d.ts +1 -0
- package/types/blocks/accordion/index.d.ts +1 -0
- package/types/components/block/animator.d.ts +0 -1
- package/types/components/content-variants/content-variants.types.d.ts +1 -1
- package/types/constants/sdk-version.d.ts +1 -1
- package/types/functions/camel-to-kebab-case.d.ts +1 -1
- package/lib/edge/content-variants-4679172a.cjs +0 -134
- package/lib/edge/form-91166ed6.cjs +0 -1
- package/lib/edge/tabs-4860ef6d.cjs +0 -1
|
@@ -1,11 +1,129 @@
|
|
|
1
|
-
import { jsx as f, jsxs as
|
|
2
|
-
import { lazy as
|
|
3
|
-
import { isBrowser as
|
|
4
|
-
import { Video as
|
|
5
|
-
import { triggerAnimation as
|
|
6
|
-
import "./get-class-prop-name-
|
|
1
|
+
import { jsx as f, jsxs as $, Fragment as z } from "react/jsx-runtime";
|
|
2
|
+
import { lazy as T, useRef as le, useState as k, useEffect as S } from "react";
|
|
3
|
+
import { isBrowser as H, TARGET as te, isEditing as F, registerInsertMenu as se, setupBrowserForEditing as de, createRegisterComponentMessage as ce, getDefaultCanTrack as A, _track as J, isPreviewing as ue, fetchOneEntry as me, logger as pe, createEditorListener as ge, fetch as fe, fastClone as he, serializeComponentInfo as Y, handleABTestingSync as be } from "./server-entry-d8f1ea14.js";
|
|
4
|
+
import { Video as ye, Button as xe, Columns as ve, Fragment as Se, Image as Te, Section as Ie, Symbol as ke, Text as Ce, BuilderContext as we } from "./blocks-exports.mjs";
|
|
5
|
+
import { triggerAnimation as Ve, evaluate as Q, InlinedStyles as ne, ComponentsContext as Re, Blocks as Ee } from "./blocks-2cd920f9.js";
|
|
6
|
+
import "./get-class-prop-name-f14607dc.js";
|
|
7
7
|
import "./dynamic-renderer-8b343325.js";
|
|
8
|
-
const
|
|
8
|
+
const P = {
|
|
9
|
+
"@type": "@builder.io/sdk:Element",
|
|
10
|
+
layerName: "Accordion item title",
|
|
11
|
+
responsiveStyles: {
|
|
12
|
+
large: {
|
|
13
|
+
marginTop: "10px",
|
|
14
|
+
position: "relative",
|
|
15
|
+
display: "flex",
|
|
16
|
+
alignItems: "stretch",
|
|
17
|
+
flexDirection: "column",
|
|
18
|
+
paddingBottom: "10px"
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
children: [{
|
|
22
|
+
"@type": "@builder.io/sdk:Element",
|
|
23
|
+
responsiveStyles: {
|
|
24
|
+
large: {
|
|
25
|
+
textAlign: "left",
|
|
26
|
+
display: "flex",
|
|
27
|
+
flexDirection: "column"
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
component: {
|
|
31
|
+
name: "Text",
|
|
32
|
+
options: {
|
|
33
|
+
text: "I am an accordion title. Click me!"
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}]
|
|
37
|
+
}, D = {
|
|
38
|
+
"@type": "@builder.io/sdk:Element",
|
|
39
|
+
layerName: "Accordion item detail",
|
|
40
|
+
responsiveStyles: {
|
|
41
|
+
large: {
|
|
42
|
+
position: "relative",
|
|
43
|
+
display: "flex",
|
|
44
|
+
alignItems: "stretch",
|
|
45
|
+
flexDirection: "column",
|
|
46
|
+
marginTop: "10px",
|
|
47
|
+
paddingBottom: "10px"
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
children: [{
|
|
51
|
+
"@type": "@builder.io/sdk:Element",
|
|
52
|
+
responsiveStyles: {
|
|
53
|
+
large: {
|
|
54
|
+
paddingTop: "50px",
|
|
55
|
+
textAlign: "left",
|
|
56
|
+
display: "flex",
|
|
57
|
+
flexDirection: "column",
|
|
58
|
+
paddingBottom: "50px"
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
component: {
|
|
62
|
+
name: "Text",
|
|
63
|
+
options: {
|
|
64
|
+
text: "I am an accordion detail, hello!"
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}]
|
|
68
|
+
}, Fe = {
|
|
69
|
+
name: "Builder:Accordion",
|
|
70
|
+
canHaveChildren: !0,
|
|
71
|
+
image: "https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",
|
|
72
|
+
defaultStyles: {
|
|
73
|
+
display: "flex",
|
|
74
|
+
flexDirection: "column",
|
|
75
|
+
alignItems: "stretch"
|
|
76
|
+
},
|
|
77
|
+
inputs: [{
|
|
78
|
+
name: "items",
|
|
79
|
+
type: "list",
|
|
80
|
+
broadcast: !0,
|
|
81
|
+
subFields: [{
|
|
82
|
+
name: "title",
|
|
83
|
+
type: "uiBlocks",
|
|
84
|
+
hideFromUI: !0,
|
|
85
|
+
defaultValue: [P]
|
|
86
|
+
}, {
|
|
87
|
+
name: "detail",
|
|
88
|
+
type: "uiBlocks",
|
|
89
|
+
hideFromUI: !0,
|
|
90
|
+
defaultValue: [D]
|
|
91
|
+
}],
|
|
92
|
+
defaultValue: [{
|
|
93
|
+
title: [P],
|
|
94
|
+
detail: [D]
|
|
95
|
+
}, {
|
|
96
|
+
title: [P],
|
|
97
|
+
detail: [D]
|
|
98
|
+
}],
|
|
99
|
+
showIf: (e) => !e.get("useChildrenForItems")
|
|
100
|
+
}, {
|
|
101
|
+
name: "oneAtATime",
|
|
102
|
+
helperText: "Only allow opening one at a time (collapse all others when new item openned)",
|
|
103
|
+
type: "boolean",
|
|
104
|
+
defaultValue: !1
|
|
105
|
+
}, {
|
|
106
|
+
name: "grid",
|
|
107
|
+
helperText: "Display as a grid",
|
|
108
|
+
type: "boolean",
|
|
109
|
+
defaultValue: !1
|
|
110
|
+
}, {
|
|
111
|
+
name: "gridRowWidth",
|
|
112
|
+
helperText: "Display as a grid",
|
|
113
|
+
type: "string",
|
|
114
|
+
showIf: (e) => e.get("grid"),
|
|
115
|
+
defaultValue: "25%"
|
|
116
|
+
}, {
|
|
117
|
+
name: "useChildrenForItems",
|
|
118
|
+
type: "boolean",
|
|
119
|
+
helperText: "Use child elements for each slide, instead of the array. Useful for dynamically repeating items",
|
|
120
|
+
advanced: !0,
|
|
121
|
+
defaultValue: !1,
|
|
122
|
+
onChange: (e) => {
|
|
123
|
+
e.get("useChildrenForItems") === !0 && e.set("items", []);
|
|
124
|
+
}
|
|
125
|
+
}]
|
|
126
|
+
}, We = T(() => import("./accordion-a922b6f1.js")), Ae = {
|
|
9
127
|
name: "Core:Button",
|
|
10
128
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
11
129
|
defaultStyles: {
|
|
@@ -38,7 +156,7 @@ const Re = {
|
|
|
38
156
|
}],
|
|
39
157
|
static: !0,
|
|
40
158
|
noWrap: !0
|
|
41
|
-
},
|
|
159
|
+
}, Pe = {
|
|
42
160
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
43
161
|
name: "Columns",
|
|
44
162
|
isRSC: !0,
|
|
@@ -239,13 +357,13 @@ const Re = {
|
|
|
239
357
|
helperText: "When stacking columns for mobile devices, reverse the ordering",
|
|
240
358
|
advanced: !0
|
|
241
359
|
}]
|
|
242
|
-
},
|
|
360
|
+
}, De = {
|
|
243
361
|
name: "Fragment",
|
|
244
362
|
static: !0,
|
|
245
363
|
hidden: !0,
|
|
246
364
|
canHaveChildren: !0,
|
|
247
365
|
noWrap: !0
|
|
248
|
-
},
|
|
366
|
+
}, Ue = {
|
|
249
367
|
name: "Image",
|
|
250
368
|
static: !0,
|
|
251
369
|
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",
|
|
@@ -268,13 +386,13 @@ const Re = {
|
|
|
268
386
|
function n(i, o = 6e4) {
|
|
269
387
|
return new Promise((m, h) => {
|
|
270
388
|
const C = document.createElement("img");
|
|
271
|
-
let
|
|
389
|
+
let I = !1;
|
|
272
390
|
C.onload = () => {
|
|
273
|
-
|
|
391
|
+
I = !0, m(C);
|
|
274
392
|
}, C.addEventListener("error", (w) => {
|
|
275
393
|
console.warn("Image load failed", w.error), h(w.error);
|
|
276
394
|
}), C.src = i, setTimeout(() => {
|
|
277
|
-
|
|
395
|
+
I || h(new Error("Image load timed out"));
|
|
278
396
|
}, o);
|
|
279
397
|
});
|
|
280
398
|
}
|
|
@@ -345,7 +463,7 @@ const Re = {
|
|
|
345
463
|
advanced: !0,
|
|
346
464
|
defaultValue: 0.7041
|
|
347
465
|
}]
|
|
348
|
-
},
|
|
466
|
+
}, Le = {
|
|
349
467
|
name: "Core:Section",
|
|
350
468
|
static: !0,
|
|
351
469
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -384,7 +502,7 @@ const Re = {
|
|
|
384
502
|
}
|
|
385
503
|
}
|
|
386
504
|
}]
|
|
387
|
-
},
|
|
505
|
+
}, $e = {
|
|
388
506
|
name: "Slot",
|
|
389
507
|
isRSC: !0,
|
|
390
508
|
description: "Allow child blocks to be inserted into this content when used as a Symbol",
|
|
@@ -397,7 +515,7 @@ const Re = {
|
|
|
397
515
|
required: !0,
|
|
398
516
|
defaultValue: "children"
|
|
399
517
|
}]
|
|
400
|
-
},
|
|
518
|
+
}, He = T(() => import("./slot-5676b4f4.js")), Ne = {
|
|
401
519
|
name: "Symbol",
|
|
402
520
|
noWrap: !0,
|
|
403
521
|
static: !0,
|
|
@@ -430,7 +548,7 @@ const Re = {
|
|
|
430
548
|
hideFromUI: !0,
|
|
431
549
|
type: "boolean"
|
|
432
550
|
}]
|
|
433
|
-
},
|
|
551
|
+
}, U = {
|
|
434
552
|
"@type": "@builder.io/sdk:Element",
|
|
435
553
|
responsiveStyles: {
|
|
436
554
|
large: {
|
|
@@ -452,7 +570,7 @@ const Re = {
|
|
|
452
570
|
text: "New tab"
|
|
453
571
|
}
|
|
454
572
|
}
|
|
455
|
-
},
|
|
573
|
+
}, L = {
|
|
456
574
|
"@type": "@builder.io/sdk:Element",
|
|
457
575
|
responsiveStyles: {
|
|
458
576
|
large: {
|
|
@@ -468,7 +586,7 @@ const Re = {
|
|
|
468
586
|
text: "New tab content "
|
|
469
587
|
}
|
|
470
588
|
}
|
|
471
|
-
},
|
|
589
|
+
}, Be = {
|
|
472
590
|
name: "Builder: Tabs",
|
|
473
591
|
inputs: [{
|
|
474
592
|
name: "tabs",
|
|
@@ -478,16 +596,16 @@ const Re = {
|
|
|
478
596
|
name: "label",
|
|
479
597
|
type: "uiBlocks",
|
|
480
598
|
hideFromUI: !0,
|
|
481
|
-
defaultValue: [
|
|
599
|
+
defaultValue: [U]
|
|
482
600
|
}, {
|
|
483
601
|
name: "content",
|
|
484
602
|
type: "uiBlocks",
|
|
485
603
|
hideFromUI: !0,
|
|
486
|
-
defaultValue: [
|
|
604
|
+
defaultValue: [L]
|
|
487
605
|
}],
|
|
488
606
|
defaultValue: [{
|
|
489
607
|
label: [{
|
|
490
|
-
...
|
|
608
|
+
...U,
|
|
491
609
|
component: {
|
|
492
610
|
name: "Text",
|
|
493
611
|
options: {
|
|
@@ -496,7 +614,7 @@ const Re = {
|
|
|
496
614
|
}
|
|
497
615
|
}],
|
|
498
616
|
content: [{
|
|
499
|
-
...
|
|
617
|
+
...L,
|
|
500
618
|
component: {
|
|
501
619
|
name: "Text",
|
|
502
620
|
options: {
|
|
@@ -506,7 +624,7 @@ const Re = {
|
|
|
506
624
|
}]
|
|
507
625
|
}, {
|
|
508
626
|
label: [{
|
|
509
|
-
...
|
|
627
|
+
...U,
|
|
510
628
|
component: {
|
|
511
629
|
name: "Text",
|
|
512
630
|
options: {
|
|
@@ -515,7 +633,7 @@ const Re = {
|
|
|
515
633
|
}
|
|
516
634
|
}],
|
|
517
635
|
content: [{
|
|
518
|
-
...
|
|
636
|
+
...L,
|
|
519
637
|
component: {
|
|
520
638
|
name: "Text",
|
|
521
639
|
options: {
|
|
@@ -565,7 +683,7 @@ const Re = {
|
|
|
565
683
|
value: "flex-end"
|
|
566
684
|
}]
|
|
567
685
|
}]
|
|
568
|
-
},
|
|
686
|
+
}, je = T(() => import("./tabs-c2055821.js")), qe = {
|
|
569
687
|
name: "Text",
|
|
570
688
|
static: !0,
|
|
571
689
|
isRSC: !0,
|
|
@@ -583,7 +701,7 @@ const Re = {
|
|
|
583
701
|
height: "auto",
|
|
584
702
|
textAlign: "center"
|
|
585
703
|
}
|
|
586
|
-
},
|
|
704
|
+
}, Ke = {
|
|
587
705
|
name: "Custom Code",
|
|
588
706
|
static: !0,
|
|
589
707
|
requiredPermissions: ["editCode"],
|
|
@@ -605,7 +723,7 @@ const Re = {
|
|
|
605
723
|
helperText: "Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",
|
|
606
724
|
advanced: !0
|
|
607
725
|
}]
|
|
608
|
-
},
|
|
726
|
+
}, Oe = T(() => import("./custom-code-7786788e.js")), _e = {
|
|
609
727
|
name: "Embed",
|
|
610
728
|
static: !0,
|
|
611
729
|
inputs: [{
|
|
@@ -630,7 +748,7 @@ const Re = {
|
|
|
630
748
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
631
749
|
hideFromUI: !0
|
|
632
750
|
}]
|
|
633
|
-
},
|
|
751
|
+
}, Me = T(() => import("./embed-5c1bbe12.js")), ze = {
|
|
634
752
|
name: "Form:Form",
|
|
635
753
|
// editableTags: ['builder-form-error']
|
|
636
754
|
defaults: {
|
|
@@ -861,7 +979,7 @@ const Re = {
|
|
|
861
979
|
}
|
|
862
980
|
}
|
|
863
981
|
}]
|
|
864
|
-
},
|
|
982
|
+
}, Je = T(() => import("./form-a0093dd2.js")), Ye = {
|
|
865
983
|
name: "Form:Input",
|
|
866
984
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fad6f37889d9e40bbbbc72cdb5875d6ca",
|
|
867
985
|
inputs: [
|
|
@@ -912,7 +1030,7 @@ const Re = {
|
|
|
912
1030
|
borderStyle: "solid",
|
|
913
1031
|
borderColor: "#ccc"
|
|
914
1032
|
}
|
|
915
|
-
},
|
|
1033
|
+
}, Qe = T(() => import("./input-5934355a.js")), Ge = {
|
|
916
1034
|
name: "Form:Select",
|
|
917
1035
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F83acca093fb24aaf94dee136e9a4b045",
|
|
918
1036
|
defaultStyles: {
|
|
@@ -954,7 +1072,7 @@ const Re = {
|
|
|
954
1072
|
}],
|
|
955
1073
|
static: !0,
|
|
956
1074
|
noWrap: !0
|
|
957
|
-
},
|
|
1075
|
+
}, Xe = T(() => import("./select-298649a8.js")), Ze = {
|
|
958
1076
|
name: "Form:SubmitButton",
|
|
959
1077
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fdf2820ffed1f4349a94c40b3221f5b98",
|
|
960
1078
|
defaultStyles: {
|
|
@@ -979,7 +1097,7 @@ const Re = {
|
|
|
979
1097
|
// that only shows if advanced setting is flipped
|
|
980
1098
|
// TODO: defaultChildren
|
|
981
1099
|
// canHaveChildren: true,
|
|
982
|
-
},
|
|
1100
|
+
}, et = T(() => import("./submit-button-b48361a7.js")), tt = {
|
|
983
1101
|
// friendlyName?
|
|
984
1102
|
name: "Raw:Img",
|
|
985
1103
|
hideFromInsertMenu: !0,
|
|
@@ -993,7 +1111,7 @@ const Re = {
|
|
|
993
1111
|
}],
|
|
994
1112
|
noWrap: !0,
|
|
995
1113
|
static: !0
|
|
996
|
-
},
|
|
1114
|
+
}, nt = T(() => import("./img-ff2f388e.js")), at = {
|
|
997
1115
|
name: "Video",
|
|
998
1116
|
canHaveChildren: !0,
|
|
999
1117
|
defaultStyles: {
|
|
@@ -1074,58 +1192,61 @@ const Re = {
|
|
|
1074
1192
|
defaultValue: !0,
|
|
1075
1193
|
advanced: !0
|
|
1076
1194
|
}]
|
|
1077
|
-
},
|
|
1078
|
-
component:
|
|
1079
|
-
...Ne
|
|
1080
|
-
}, {
|
|
1081
|
-
component: Be,
|
|
1082
|
-
...qe
|
|
1083
|
-
}, {
|
|
1084
|
-
component: _e,
|
|
1195
|
+
}, it = () => [{
|
|
1196
|
+
component: Oe,
|
|
1085
1197
|
...Ke
|
|
1086
1198
|
}, {
|
|
1087
|
-
component:
|
|
1088
|
-
...
|
|
1199
|
+
component: Me,
|
|
1200
|
+
..._e
|
|
1201
|
+
}, {
|
|
1202
|
+
component: Je,
|
|
1203
|
+
...ze
|
|
1089
1204
|
}, {
|
|
1090
1205
|
component: Qe,
|
|
1091
1206
|
...Ye
|
|
1092
1207
|
}, {
|
|
1093
|
-
component:
|
|
1094
|
-
...
|
|
1208
|
+
component: et,
|
|
1209
|
+
...Ze
|
|
1095
1210
|
}, {
|
|
1096
1211
|
component: Xe,
|
|
1097
1212
|
...Ge
|
|
1098
1213
|
}, {
|
|
1099
|
-
component:
|
|
1100
|
-
...
|
|
1101
|
-
}], Y = () => [{
|
|
1102
|
-
component: be,
|
|
1103
|
-
...Re
|
|
1214
|
+
component: nt,
|
|
1215
|
+
...tt
|
|
1104
1216
|
}, {
|
|
1105
1217
|
component: ye,
|
|
1106
|
-
...
|
|
1107
|
-
}, {
|
|
1218
|
+
...at
|
|
1219
|
+
}], G = () => [{
|
|
1108
1220
|
component: xe,
|
|
1109
|
-
...
|
|
1221
|
+
...Ae
|
|
1110
1222
|
}, {
|
|
1111
1223
|
component: ve,
|
|
1112
|
-
...
|
|
1224
|
+
...Pe
|
|
1113
1225
|
}, {
|
|
1114
1226
|
component: Se,
|
|
1115
|
-
...
|
|
1116
|
-
}, {
|
|
1117
|
-
component: Ue,
|
|
1118
|
-
...Pe
|
|
1227
|
+
...De
|
|
1119
1228
|
}, {
|
|
1120
1229
|
component: Te,
|
|
1121
|
-
...
|
|
1230
|
+
...Ue
|
|
1122
1231
|
}, {
|
|
1123
1232
|
component: Ie,
|
|
1124
|
-
...He
|
|
1125
|
-
}, {
|
|
1126
|
-
component: $e,
|
|
1127
1233
|
...Le
|
|
1128
|
-
},
|
|
1234
|
+
}, {
|
|
1235
|
+
component: He,
|
|
1236
|
+
...$e
|
|
1237
|
+
}, {
|
|
1238
|
+
component: ke,
|
|
1239
|
+
...Ne
|
|
1240
|
+
}, {
|
|
1241
|
+
component: Ce,
|
|
1242
|
+
...qe
|
|
1243
|
+
}, {
|
|
1244
|
+
component: je,
|
|
1245
|
+
...Be
|
|
1246
|
+
}, {
|
|
1247
|
+
component: We,
|
|
1248
|
+
...Fe
|
|
1249
|
+
}, ...it()], ot = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
|
|
1129
1250
|
function getAndSetVariantId() {
|
|
1130
1251
|
function setCookie(name, value, days) {
|
|
1131
1252
|
let expires = '';
|
|
@@ -1181,7 +1302,7 @@ const Re = {
|
|
|
1181
1302
|
}).join('');
|
|
1182
1303
|
styleEl.innerHTML = newStyleStr;
|
|
1183
1304
|
}
|
|
1184
|
-
}`,
|
|
1305
|
+
}`, rt = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
|
|
1185
1306
|
if (!navigator.cookieEnabled) {
|
|
1186
1307
|
return;
|
|
1187
1308
|
}
|
|
@@ -1215,26 +1336,26 @@ const Re = {
|
|
|
1215
1336
|
thisScriptEl?.remove();
|
|
1216
1337
|
}
|
|
1217
1338
|
return;
|
|
1218
|
-
}`,
|
|
1339
|
+
}`, ae = "builderIoAbTest", ie = "builderIoRenderContent", W = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
|
|
1219
1340
|
...t,
|
|
1220
1341
|
testVariationId: t.id,
|
|
1221
1342
|
id: e == null ? void 0 : e.id
|
|
1222
|
-
})),
|
|
1343
|
+
})), lt = ({
|
|
1223
1344
|
canTrack: e,
|
|
1224
1345
|
content: t
|
|
1225
|
-
}) => !(!(W(t).length > 0) || !e ||
|
|
1226
|
-
window.${
|
|
1227
|
-
window.${
|
|
1228
|
-
`,
|
|
1229
|
-
window.${
|
|
1230
|
-
"${t}",${JSON.stringify(e)}, ${
|
|
1231
|
-
)`,
|
|
1346
|
+
}) => !(!(W(t).length > 0) || !e || H()), st = (e) => e === "react" || e === "reactNative", oe = st(te), dt = () => `
|
|
1347
|
+
window.${ae} = ${ot}
|
|
1348
|
+
window.${ie} = ${rt}
|
|
1349
|
+
`, ct = (e, t) => `
|
|
1350
|
+
window.${ae}(
|
|
1351
|
+
"${t}",${JSON.stringify(e)}, ${oe}
|
|
1352
|
+
)`, ut = ({
|
|
1232
1353
|
contentId: e,
|
|
1233
1354
|
variationId: t
|
|
1234
|
-
}) => `window.${
|
|
1235
|
-
"${t}", "${e}", ${
|
|
1355
|
+
}) => `window.${ie}(
|
|
1356
|
+
"${t}", "${e}", ${oe}
|
|
1236
1357
|
)`;
|
|
1237
|
-
function
|
|
1358
|
+
function N(e) {
|
|
1238
1359
|
return /* @__PURE__ */ f(
|
|
1239
1360
|
"script",
|
|
1240
1361
|
{
|
|
@@ -1243,10 +1364,10 @@ function $(e) {
|
|
|
1243
1364
|
}
|
|
1244
1365
|
);
|
|
1245
1366
|
}
|
|
1246
|
-
function
|
|
1367
|
+
function X(e) {
|
|
1247
1368
|
return Math.round(e * 1e3) / 1e3;
|
|
1248
1369
|
}
|
|
1249
|
-
const
|
|
1370
|
+
const mt = (e, t, n = !0) => {
|
|
1250
1371
|
if (!(e instanceof HTMLElement))
|
|
1251
1372
|
return null;
|
|
1252
1373
|
let a = n ? e : e.parentElement;
|
|
@@ -1257,35 +1378,35 @@ const lt = (e, t, n = !0) => {
|
|
|
1257
1378
|
return a;
|
|
1258
1379
|
} while (a = a.parentElement);
|
|
1259
1380
|
return null;
|
|
1260
|
-
},
|
|
1381
|
+
}, pt = (e) => mt(e, (t) => {
|
|
1261
1382
|
const n = t.getAttribute("builder-id") || t.id;
|
|
1262
1383
|
return (n == null ? void 0 : n.indexOf("builder-")) === 0;
|
|
1263
|
-
}),
|
|
1384
|
+
}), Z = ({
|
|
1264
1385
|
event: e,
|
|
1265
1386
|
target: t
|
|
1266
1387
|
}) => {
|
|
1267
|
-
const n = t.getBoundingClientRect(), a = e.clientX - n.left, d = e.clientY - n.top, u =
|
|
1388
|
+
const n = t.getBoundingClientRect(), a = e.clientX - n.left, d = e.clientY - n.top, u = X(a / n.width), i = X(d / n.height);
|
|
1268
1389
|
return {
|
|
1269
1390
|
x: u,
|
|
1270
1391
|
y: i
|
|
1271
1392
|
};
|
|
1272
|
-
},
|
|
1273
|
-
const t = e.target, n = t &&
|
|
1393
|
+
}, gt = (e) => {
|
|
1394
|
+
const t = e.target, n = t && pt(t), a = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
|
|
1274
1395
|
return {
|
|
1275
1396
|
targetBuilderElement: a || void 0,
|
|
1276
1397
|
metadata: {
|
|
1277
|
-
targetOffset: t ?
|
|
1398
|
+
targetOffset: t ? Z({
|
|
1278
1399
|
event: e,
|
|
1279
1400
|
target: t
|
|
1280
1401
|
}) : void 0,
|
|
1281
|
-
builderTargetOffset: n ?
|
|
1402
|
+
builderTargetOffset: n ? Z({
|
|
1282
1403
|
event: e,
|
|
1283
1404
|
target: n
|
|
1284
1405
|
}) : void 0,
|
|
1285
1406
|
builderElementIndex: n && a ? [].slice.call(document.getElementsByClassName(a)).indexOf(n) : void 0
|
|
1286
1407
|
}
|
|
1287
1408
|
};
|
|
1288
|
-
},
|
|
1409
|
+
}, ft = (e) => {
|
|
1289
1410
|
var u, i;
|
|
1290
1411
|
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], a = (i = e.fileUrl) != null ? i : (u = e == null ? void 0 : e.files) == null ? void 0 : u.regular;
|
|
1291
1412
|
let d = "";
|
|
@@ -1311,15 +1432,15 @@ font-weight: ${o};
|
|
|
1311
1432
|
`.trim());
|
|
1312
1433
|
}
|
|
1313
1434
|
return d;
|
|
1314
|
-
},
|
|
1435
|
+
}, ht = ({
|
|
1315
1436
|
customFonts: e
|
|
1316
1437
|
}) => {
|
|
1317
1438
|
var t;
|
|
1318
|
-
return ((t = e == null ? void 0 : e.map((n) =>
|
|
1319
|
-
},
|
|
1439
|
+
return ((t = e == null ? void 0 : e.map((n) => ft(n))) == null ? void 0 : t.join(" ")) || "";
|
|
1440
|
+
}, bt = ({
|
|
1320
1441
|
cssCode: e,
|
|
1321
1442
|
contentId: t
|
|
1322
|
-
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "",
|
|
1443
|
+
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", yt = `
|
|
1323
1444
|
.builder-button {
|
|
1324
1445
|
all: unset;
|
|
1325
1446
|
}
|
|
@@ -1336,23 +1457,23 @@ font-weight: ${o};
|
|
|
1336
1457
|
text-align: inherit;
|
|
1337
1458
|
font-family: inherit;
|
|
1338
1459
|
}
|
|
1339
|
-
`,
|
|
1340
|
-
function
|
|
1341
|
-
var
|
|
1342
|
-
const t =
|
|
1460
|
+
`, xt = (e) => e ? "" : yt, vt = (e) => `variant-${e}`;
|
|
1461
|
+
function St(e) {
|
|
1462
|
+
var B, j, q, K, O, _, M;
|
|
1463
|
+
const t = le(null);
|
|
1343
1464
|
function n(r) {
|
|
1344
|
-
var p,
|
|
1465
|
+
var p, s;
|
|
1345
1466
|
const c = {
|
|
1346
1467
|
...e.builderContextSignal.rootState,
|
|
1347
1468
|
...r
|
|
1348
1469
|
};
|
|
1349
|
-
e.builderContextSignal.rootSetState ? (
|
|
1350
|
-
...
|
|
1470
|
+
e.builderContextSignal.rootSetState ? (s = (p = e.builderContextSignal).rootSetState) == null || s.call(p, c) : e.setBuilderContextSignal((l) => ({
|
|
1471
|
+
...l,
|
|
1351
1472
|
rootState: c
|
|
1352
1473
|
}));
|
|
1353
1474
|
}
|
|
1354
1475
|
function a(r) {
|
|
1355
|
-
var p,
|
|
1476
|
+
var p, s, l, g, V;
|
|
1356
1477
|
const c = {
|
|
1357
1478
|
...e.builderContextSignal.content,
|
|
1358
1479
|
...r,
|
|
@@ -1361,9 +1482,9 @@ function bt(e) {
|
|
|
1361
1482
|
...r == null ? void 0 : r.data
|
|
1362
1483
|
},
|
|
1363
1484
|
meta: {
|
|
1364
|
-
...(
|
|
1485
|
+
...(s = e.builderContextSignal.content) == null ? void 0 : s.meta,
|
|
1365
1486
|
...r == null ? void 0 : r.meta,
|
|
1366
|
-
breakpoints: ((
|
|
1487
|
+
breakpoints: ((l = r == null ? void 0 : r.meta) == null ? void 0 : l.breakpoints) || ((V = (g = e.builderContextSignal.content) == null ? void 0 : g.meta) == null ? void 0 : V.breakpoints)
|
|
1367
1488
|
}
|
|
1368
1489
|
};
|
|
1369
1490
|
e.setBuilderContextSignal((b) => ({
|
|
@@ -1377,25 +1498,25 @@ function bt(e) {
|
|
|
1377
1498
|
"aria-hidden": !0
|
|
1378
1499
|
};
|
|
1379
1500
|
}
|
|
1380
|
-
const [u, i] =
|
|
1501
|
+
const [u, i] = k(
|
|
1381
1502
|
() => e.contentWrapper || "div"
|
|
1382
1503
|
);
|
|
1383
1504
|
function o(r) {
|
|
1384
|
-
return
|
|
1505
|
+
return ge({
|
|
1385
1506
|
model: e.model,
|
|
1386
1507
|
trustedHosts: e.trustedHosts,
|
|
1387
1508
|
callbacks: {
|
|
1388
1509
|
configureSdk: (c) => {
|
|
1389
|
-
var
|
|
1390
|
-
const { breakpoints: p, contentId:
|
|
1391
|
-
!
|
|
1510
|
+
var l;
|
|
1511
|
+
const { breakpoints: p, contentId: s } = c;
|
|
1512
|
+
!s || s !== ((l = e.builderContextSignal.content) == null ? void 0 : l.id) || p && a({
|
|
1392
1513
|
meta: {
|
|
1393
1514
|
breakpoints: p
|
|
1394
1515
|
}
|
|
1395
1516
|
});
|
|
1396
1517
|
},
|
|
1397
1518
|
animation: (c) => {
|
|
1398
|
-
|
|
1519
|
+
Ve(c);
|
|
1399
1520
|
},
|
|
1400
1521
|
contentUpdate: (c) => {
|
|
1401
1522
|
a(c);
|
|
@@ -1406,7 +1527,7 @@ function bt(e) {
|
|
|
1406
1527
|
function m() {
|
|
1407
1528
|
var c, p;
|
|
1408
1529
|
const r = (p = (c = e.builderContextSignal.content) == null ? void 0 : c.data) == null ? void 0 : p.jsCode;
|
|
1409
|
-
r &&
|
|
1530
|
+
r && Q({
|
|
1410
1531
|
code: r,
|
|
1411
1532
|
context: e.context || {},
|
|
1412
1533
|
localState: void 0,
|
|
@@ -1418,35 +1539,35 @@ function bt(e) {
|
|
|
1418
1539
|
enableCache: !1
|
|
1419
1540
|
});
|
|
1420
1541
|
}
|
|
1421
|
-
const [h, C] =
|
|
1542
|
+
const [h, C] = k(() => ({})), [I, w] = k(() => ({})), [R, E] = k(() => !1);
|
|
1422
1543
|
function y(r) {
|
|
1423
1544
|
var c, p;
|
|
1424
1545
|
if (e.builderContextSignal.content) {
|
|
1425
|
-
const
|
|
1426
|
-
|
|
1546
|
+
const s = (c = e.builderContextSignal.content) == null ? void 0 : c.testVariationId, l = (p = e.builderContextSignal.content) == null ? void 0 : p.id;
|
|
1547
|
+
J({
|
|
1427
1548
|
type: "click",
|
|
1428
1549
|
canTrack: A(e.canTrack),
|
|
1429
|
-
contentId:
|
|
1550
|
+
contentId: l,
|
|
1430
1551
|
apiKey: e.apiKey,
|
|
1431
|
-
variationId:
|
|
1432
|
-
...
|
|
1552
|
+
variationId: s !== l ? s : void 0,
|
|
1553
|
+
...gt(r),
|
|
1433
1554
|
unique: !R
|
|
1434
1555
|
});
|
|
1435
1556
|
}
|
|
1436
1557
|
R || E(!0);
|
|
1437
1558
|
}
|
|
1438
1559
|
function x() {
|
|
1439
|
-
var c, p,
|
|
1440
|
-
const r = (
|
|
1441
|
-
Object.entries(r).forEach(([
|
|
1442
|
-
if (!g ||
|
|
1560
|
+
var c, p, s;
|
|
1561
|
+
const r = (s = (p = (c = e.builderContextSignal.content) == null ? void 0 : c.data) == null ? void 0 : p.httpRequests) != null ? s : {};
|
|
1562
|
+
Object.entries(r).forEach(([l, g]) => {
|
|
1563
|
+
if (!g || I[l] || h[l] && !F())
|
|
1443
1564
|
return;
|
|
1444
|
-
|
|
1565
|
+
I[l] = !0;
|
|
1445
1566
|
const V = g.replace(
|
|
1446
1567
|
/{{([^}]+)}}/g,
|
|
1447
|
-
(b,
|
|
1448
|
-
|
|
1449
|
-
code:
|
|
1568
|
+
(b, re) => String(
|
|
1569
|
+
Q({
|
|
1570
|
+
code: re,
|
|
1450
1571
|
context: e.context || {},
|
|
1451
1572
|
localState: void 0,
|
|
1452
1573
|
rootState: e.builderContextSignal.rootState,
|
|
@@ -1455,14 +1576,14 @@ function bt(e) {
|
|
|
1455
1576
|
})
|
|
1456
1577
|
)
|
|
1457
1578
|
);
|
|
1458
|
-
|
|
1579
|
+
fe(V).then((b) => b.json()).then((b) => {
|
|
1459
1580
|
n({
|
|
1460
|
-
[
|
|
1461
|
-
}), h[
|
|
1581
|
+
[l]: b
|
|
1582
|
+
}), h[l] = !0;
|
|
1462
1583
|
}).catch((b) => {
|
|
1463
1584
|
console.error("error fetching dynamic data", g, b);
|
|
1464
1585
|
}).finally(() => {
|
|
1465
|
-
|
|
1586
|
+
I[l] = !1;
|
|
1466
1587
|
});
|
|
1467
1588
|
});
|
|
1468
1589
|
}
|
|
@@ -1472,7 +1593,7 @@ function bt(e) {
|
|
|
1472
1593
|
"builder:component:stateChange",
|
|
1473
1594
|
{
|
|
1474
1595
|
detail: {
|
|
1475
|
-
state:
|
|
1596
|
+
state: he(e.builderContextSignal.rootState),
|
|
1476
1597
|
ref: {
|
|
1477
1598
|
name: e.model
|
|
1478
1599
|
}
|
|
@@ -1483,8 +1604,8 @@ function bt(e) {
|
|
|
1483
1604
|
}
|
|
1484
1605
|
return S(() => {
|
|
1485
1606
|
var r, c;
|
|
1486
|
-
if (
|
|
1487
|
-
if (F() && (window.addEventListener("message", o),
|
|
1607
|
+
if (H()) {
|
|
1608
|
+
if (F() && (window.addEventListener("message", o), se(), de({
|
|
1488
1609
|
...e.locale ? {
|
|
1489
1610
|
locale: e.locale
|
|
1490
1611
|
} : {},
|
|
@@ -1496,28 +1617,28 @@ function bt(e) {
|
|
|
1496
1617
|
} : {}
|
|
1497
1618
|
}), Object.values(
|
|
1498
1619
|
e.builderContextSignal.componentInfos
|
|
1499
|
-
).forEach((
|
|
1620
|
+
).forEach((s) => {
|
|
1500
1621
|
var g;
|
|
1501
|
-
const
|
|
1502
|
-
(g = window.parent) == null || g.postMessage(
|
|
1622
|
+
const l = ce(s);
|
|
1623
|
+
(g = window.parent) == null || g.postMessage(l, "*");
|
|
1503
1624
|
}), window.addEventListener(
|
|
1504
1625
|
"builder:component:stateChangeListenerActivated",
|
|
1505
1626
|
v
|
|
1506
1627
|
)), e.builderContextSignal.content && A(e.canTrack)) {
|
|
1507
|
-
const
|
|
1508
|
-
|
|
1628
|
+
const s = (r = e.builderContextSignal.content) == null ? void 0 : r.testVariationId, l = (c = e.builderContextSignal.content) == null ? void 0 : c.id, g = e.apiKey;
|
|
1629
|
+
J({
|
|
1509
1630
|
type: "impression",
|
|
1510
1631
|
canTrack: !0,
|
|
1511
|
-
contentId:
|
|
1632
|
+
contentId: l,
|
|
1512
1633
|
apiKey: g,
|
|
1513
|
-
variationId:
|
|
1634
|
+
variationId: s !== l ? s : void 0
|
|
1514
1635
|
});
|
|
1515
1636
|
}
|
|
1516
|
-
if (
|
|
1517
|
-
const
|
|
1518
|
-
`builder.
|
|
1519
|
-
), V =
|
|
1520
|
-
|
|
1637
|
+
if (ue() && !F()) {
|
|
1638
|
+
const s = new URL(location.href).searchParams, l = s.get("builder.preview"), g = s.get(
|
|
1639
|
+
`builder.overrides.${l}`
|
|
1640
|
+
), V = s.get("apiKey") || s.get("builder.space");
|
|
1641
|
+
l === e.model && V === e.apiKey && (!e.content || g === e.content.id) && me({
|
|
1521
1642
|
model: e.model,
|
|
1522
1643
|
apiKey: e.apiKey,
|
|
1523
1644
|
apiVersion: e.builderContextSignal.apiVersion
|
|
@@ -1527,16 +1648,16 @@ function bt(e) {
|
|
|
1527
1648
|
}
|
|
1528
1649
|
}
|
|
1529
1650
|
}, []), S(() => {
|
|
1530
|
-
e.apiKey ||
|
|
1531
|
-
"No API key provided to `
|
|
1651
|
+
e.apiKey || pe.error(
|
|
1652
|
+
"No API key provided to `Content` component. This can cause issues. Please provide an API key using the `apiKey` prop."
|
|
1532
1653
|
), m(), x(), v();
|
|
1533
1654
|
}, []), S(() => {
|
|
1534
1655
|
e.content && a(e.content);
|
|
1535
1656
|
}, [e.content]), S(() => {
|
|
1536
1657
|
m();
|
|
1537
|
-
}, [(
|
|
1658
|
+
}, [(j = (B = e.builderContextSignal.content) == null ? void 0 : B.data) == null ? void 0 : j.jsCode]), S(() => {
|
|
1538
1659
|
x();
|
|
1539
|
-
}, [(
|
|
1660
|
+
}, [(K = (q = e.builderContextSignal.content) == null ? void 0 : q.data) == null ? void 0 : K.httpRequests]), S(() => {
|
|
1540
1661
|
v();
|
|
1541
1662
|
}, [e.builderContextSignal.rootState]), S(() => {
|
|
1542
1663
|
e.data && n(e.data);
|
|
@@ -1545,42 +1666,42 @@ function bt(e) {
|
|
|
1545
1666
|
locale: e.locale
|
|
1546
1667
|
});
|
|
1547
1668
|
}, [e.locale]), S(() => () => {
|
|
1548
|
-
|
|
1669
|
+
H() && (window.removeEventListener("message", o), window.removeEventListener(
|
|
1549
1670
|
"builder:component:stateChangeListenerActivated",
|
|
1550
1671
|
v
|
|
1551
1672
|
));
|
|
1552
|
-
}, []), /* @__PURE__ */ f(
|
|
1673
|
+
}, []), /* @__PURE__ */ f(we.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content ? /* @__PURE__ */ f(
|
|
1553
1674
|
u,
|
|
1554
1675
|
{
|
|
1555
1676
|
ref: t,
|
|
1556
1677
|
onClick: (r) => y(r),
|
|
1557
|
-
"builder-content-id": (
|
|
1678
|
+
"builder-content-id": (O = e.builderContextSignal.content) == null ? void 0 : O.id,
|
|
1558
1679
|
"builder-model": e.model,
|
|
1559
1680
|
...d(),
|
|
1560
1681
|
...e.contentWrapperProps,
|
|
1561
|
-
className:
|
|
1562
|
-
((
|
|
1682
|
+
className: vt(
|
|
1683
|
+
((_ = e.content) == null ? void 0 : _.testVariationId) || ((M = e.content) == null ? void 0 : M.id)
|
|
1563
1684
|
),
|
|
1564
1685
|
children: e.children
|
|
1565
1686
|
}
|
|
1566
1687
|
) : null });
|
|
1567
1688
|
}
|
|
1568
|
-
function
|
|
1569
|
-
const [t, n] =
|
|
1689
|
+
function Tt(e) {
|
|
1690
|
+
const [t, n] = k(
|
|
1570
1691
|
() => `
|
|
1571
|
-
${
|
|
1692
|
+
${bt({
|
|
1572
1693
|
cssCode: e.cssCode,
|
|
1573
1694
|
contentId: e.contentId
|
|
1574
1695
|
})}
|
|
1575
|
-
${
|
|
1696
|
+
${ht({
|
|
1576
1697
|
customFonts: e.customFonts
|
|
1577
1698
|
})}
|
|
1578
|
-
${
|
|
1699
|
+
${xt(e.isNestedRender)}
|
|
1579
1700
|
`.trim()
|
|
1580
1701
|
);
|
|
1581
|
-
return /* @__PURE__ */ f(
|
|
1702
|
+
return /* @__PURE__ */ f(ne, { id: "builderio-content", styles: t });
|
|
1582
1703
|
}
|
|
1583
|
-
const
|
|
1704
|
+
const It = ({
|
|
1584
1705
|
content: e,
|
|
1585
1706
|
data: t,
|
|
1586
1707
|
locale: n
|
|
@@ -1597,7 +1718,7 @@ const xt = ({
|
|
|
1597
1718
|
locale: n
|
|
1598
1719
|
} : {}
|
|
1599
1720
|
};
|
|
1600
|
-
},
|
|
1721
|
+
}, kt = ({
|
|
1601
1722
|
content: e,
|
|
1602
1723
|
data: t
|
|
1603
1724
|
}) => e ? {
|
|
@@ -1608,12 +1729,12 @@ const xt = ({
|
|
|
1608
1729
|
},
|
|
1609
1730
|
meta: e == null ? void 0 : e.meta
|
|
1610
1731
|
} : void 0;
|
|
1611
|
-
function
|
|
1612
|
-
var m, h, C,
|
|
1613
|
-
const [t, n] =
|
|
1732
|
+
function ee(e) {
|
|
1733
|
+
var m, h, C, I, w, R, E;
|
|
1734
|
+
const [t, n] = k(
|
|
1614
1735
|
() => {
|
|
1615
1736
|
var y, x;
|
|
1616
|
-
return
|
|
1737
|
+
return ut({
|
|
1617
1738
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
1618
1739
|
variationId: (y = e.content) == null ? void 0 : y.testVariationId,
|
|
1619
1740
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
@@ -1627,27 +1748,27 @@ function X(e) {
|
|
|
1627
1748
|
rootState: y
|
|
1628
1749
|
}));
|
|
1629
1750
|
}
|
|
1630
|
-
const [d, u] =
|
|
1751
|
+
const [d, u] = k(
|
|
1631
1752
|
() => [
|
|
1632
|
-
...
|
|
1753
|
+
...G(),
|
|
1633
1754
|
...e.customComponents || []
|
|
1634
1755
|
].reduce(
|
|
1635
1756
|
(y, { component: x, ...v }) => ({
|
|
1636
1757
|
...y,
|
|
1637
1758
|
[v.name]: {
|
|
1638
1759
|
component: x,
|
|
1639
|
-
...
|
|
1760
|
+
...Y(v)
|
|
1640
1761
|
}
|
|
1641
1762
|
}),
|
|
1642
1763
|
{}
|
|
1643
1764
|
)
|
|
1644
|
-
), [i, o] =
|
|
1645
|
-
content:
|
|
1765
|
+
), [i, o] = k(() => ({
|
|
1766
|
+
content: kt({
|
|
1646
1767
|
content: e.content,
|
|
1647
1768
|
data: e.data
|
|
1648
1769
|
}),
|
|
1649
1770
|
localState: void 0,
|
|
1650
|
-
rootState:
|
|
1771
|
+
rootState: It({
|
|
1651
1772
|
content: e.content,
|
|
1652
1773
|
data: e.data,
|
|
1653
1774
|
locale: e.locale
|
|
@@ -1657,12 +1778,12 @@ function X(e) {
|
|
|
1657
1778
|
apiKey: e.apiKey,
|
|
1658
1779
|
apiVersion: e.apiVersion,
|
|
1659
1780
|
componentInfos: [
|
|
1660
|
-
...
|
|
1781
|
+
...G(),
|
|
1661
1782
|
...e.customComponents || []
|
|
1662
1783
|
].reduce(
|
|
1663
1784
|
(y, { component: x, ...v }) => ({
|
|
1664
1785
|
...y,
|
|
1665
|
-
[v.name]:
|
|
1786
|
+
[v.name]: Y(v)
|
|
1666
1787
|
}),
|
|
1667
1788
|
{}
|
|
1668
1789
|
),
|
|
@@ -1671,13 +1792,13 @@ function X(e) {
|
|
|
1671
1792
|
BlocksWrapperProps: e.blocksWrapperProps || {}
|
|
1672
1793
|
}));
|
|
1673
1794
|
return /* @__PURE__ */ f(
|
|
1674
|
-
|
|
1795
|
+
Re.Provider,
|
|
1675
1796
|
{
|
|
1676
1797
|
value: {
|
|
1677
1798
|
registeredComponents: d
|
|
1678
1799
|
},
|
|
1679
|
-
children: /* @__PURE__ */
|
|
1680
|
-
|
|
1800
|
+
children: /* @__PURE__ */ $(
|
|
1801
|
+
St,
|
|
1681
1802
|
{
|
|
1682
1803
|
content: e.content,
|
|
1683
1804
|
data: e.data,
|
|
@@ -1696,23 +1817,23 @@ function X(e) {
|
|
|
1696
1817
|
setBuilderContextSignal: o,
|
|
1697
1818
|
children: [
|
|
1698
1819
|
e.isSsrAbTest ? /* @__PURE__ */ f(
|
|
1699
|
-
|
|
1820
|
+
N,
|
|
1700
1821
|
{
|
|
1701
1822
|
id: "builderio-variant-visibility",
|
|
1702
1823
|
scriptStr: t
|
|
1703
1824
|
}
|
|
1704
1825
|
) : null,
|
|
1705
1826
|
/* @__PURE__ */ f(
|
|
1706
|
-
|
|
1827
|
+
Tt,
|
|
1707
1828
|
{
|
|
1708
1829
|
isNestedRender: e.isNestedRender,
|
|
1709
1830
|
contentId: (m = i.content) == null ? void 0 : m.id,
|
|
1710
1831
|
cssCode: (C = (h = i.content) == null ? void 0 : h.data) == null ? void 0 : C.cssCode,
|
|
1711
|
-
customFonts: (w = (
|
|
1832
|
+
customFonts: (w = (I = i.content) == null ? void 0 : I.data) == null ? void 0 : w.customFonts
|
|
1712
1833
|
}
|
|
1713
1834
|
),
|
|
1714
1835
|
/* @__PURE__ */ f(
|
|
1715
|
-
|
|
1836
|
+
Ee,
|
|
1716
1837
|
{
|
|
1717
1838
|
blocks: (E = (R = i.content) == null ? void 0 : R.data) == null ? void 0 : E.blocks,
|
|
1718
1839
|
context: i,
|
|
@@ -1726,17 +1847,17 @@ function X(e) {
|
|
|
1726
1847
|
}
|
|
1727
1848
|
);
|
|
1728
1849
|
}
|
|
1729
|
-
function
|
|
1850
|
+
function At(e) {
|
|
1730
1851
|
var i;
|
|
1731
|
-
const [t, n] =
|
|
1732
|
-
() =>
|
|
1852
|
+
const [t, n] = k(
|
|
1853
|
+
() => lt({
|
|
1733
1854
|
canTrack: A(e.canTrack),
|
|
1734
1855
|
content: e.content
|
|
1735
1856
|
})
|
|
1736
1857
|
);
|
|
1737
1858
|
function a() {
|
|
1738
1859
|
var o;
|
|
1739
|
-
return
|
|
1860
|
+
return ct(
|
|
1740
1861
|
W(e.content).map((m) => ({
|
|
1741
1862
|
id: m.testVariationId,
|
|
1742
1863
|
testRatio: m.testRatio
|
|
@@ -1752,37 +1873,37 @@ function Rt(e) {
|
|
|
1752
1873
|
return t ? {
|
|
1753
1874
|
...e.content,
|
|
1754
1875
|
testVariationId: (o = e.content) == null ? void 0 : o.id
|
|
1755
|
-
} :
|
|
1876
|
+
} : be({
|
|
1756
1877
|
item: e.content,
|
|
1757
1878
|
canTrack: A(e.canTrack)
|
|
1758
1879
|
});
|
|
1759
1880
|
}
|
|
1760
1881
|
return S(() => {
|
|
1761
|
-
}, []), /* @__PURE__ */
|
|
1762
|
-
!e.isNestedRender &&
|
|
1763
|
-
|
|
1882
|
+
}, []), /* @__PURE__ */ $(z, { children: [
|
|
1883
|
+
!e.isNestedRender && te !== "reactNative" ? /* @__PURE__ */ f(
|
|
1884
|
+
N,
|
|
1764
1885
|
{
|
|
1765
1886
|
id: "builderio-init-variants-fns",
|
|
1766
|
-
scriptStr:
|
|
1887
|
+
scriptStr: dt()
|
|
1767
1888
|
}
|
|
1768
1889
|
) : null,
|
|
1769
|
-
t ? /* @__PURE__ */
|
|
1890
|
+
t ? /* @__PURE__ */ $(z, { children: [
|
|
1770
1891
|
/* @__PURE__ */ f(
|
|
1771
|
-
|
|
1892
|
+
ne,
|
|
1772
1893
|
{
|
|
1773
1894
|
id: "builderio-variants",
|
|
1774
1895
|
styles: d()
|
|
1775
1896
|
}
|
|
1776
1897
|
),
|
|
1777
1898
|
/* @__PURE__ */ f(
|
|
1778
|
-
|
|
1899
|
+
N,
|
|
1779
1900
|
{
|
|
1780
1901
|
id: "builderio-variants-visibility",
|
|
1781
1902
|
scriptStr: a()
|
|
1782
1903
|
}
|
|
1783
1904
|
),
|
|
1784
1905
|
(i = W(e.content)) == null ? void 0 : i.map((o) => /* @__PURE__ */ f(
|
|
1785
|
-
|
|
1906
|
+
ee,
|
|
1786
1907
|
{
|
|
1787
1908
|
isNestedRender: e.isNestedRender,
|
|
1788
1909
|
content: o,
|
|
@@ -1808,7 +1929,7 @@ function Rt(e) {
|
|
|
1808
1929
|
))
|
|
1809
1930
|
] }) : null,
|
|
1810
1931
|
/* @__PURE__ */ f(
|
|
1811
|
-
|
|
1932
|
+
ee,
|
|
1812
1933
|
{
|
|
1813
1934
|
isNestedRender: e.isNestedRender,
|
|
1814
1935
|
content: u(),
|
|
@@ -1834,5 +1955,5 @@ function Rt(e) {
|
|
|
1834
1955
|
] });
|
|
1835
1956
|
}
|
|
1836
1957
|
export {
|
|
1837
|
-
|
|
1958
|
+
At as default
|
|
1838
1959
|
};
|