@builder.io/sdk-react 0.12.0 → 0.12.2
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/index.cjs +29 -29
- package/lib/browser/index.mjs +701 -674
- package/lib/edge/index.cjs +39 -39
- package/lib/edge/index.mjs +1127 -1100
- package/lib/node/index.cjs +12 -12
- package/lib/node/index.mjs +436 -409
- package/package.json +1 -1
- package/types/blocks/slot/component-info.d.ts +2 -0
- package/types/blocks/slot/slot.d.ts +11 -0
- package/types/components/block/block.helpers.d.ts +0 -1
- package/types/components/block/components/block-wrapper.d.ts +2 -6
- package/types/components/content-variants/content-variants.types.d.ts +4 -0
- package/types/components/dynamic-renderer/dynamic-renderer.d.ts +8 -0
- package/types/components/dynamic-renderer/dynamic-renderer.helpers.d.ts +1 -0
- package/types/constants/sdk-version.d.ts +1 -1
- package/types/functions/is-from-trusted-host.d.ts +3 -0
- package/types/scripts/init-editing.d.ts +1 -0
package/lib/browser/index.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
3
|
-
import { createContext as
|
|
4
|
-
import { i as V, j as $, k as
|
|
5
|
-
import { _ as
|
|
6
|
-
function
|
|
7
|
-
return /* @__PURE__ */
|
|
8
|
-
e.link ? /* @__PURE__ */
|
|
2
|
+
import { jsxs as B, Fragment as h, jsx as o } from "react/jsx-runtime";
|
|
3
|
+
import { createContext as ve, useState as S, useContext as ce, createElement as pe, useRef as X, useEffect as E } from "react";
|
|
4
|
+
import { i as V, j as $, k as $e, l as U, m as Z, n as G, T as L, r as Ne, o as D, p as le, a as Fe, c as _e, b as ke, q as Le, u as se, v as de, w as je } from "./server-entry-f978b3a5.js";
|
|
5
|
+
import { _ as xn, h as yn, f as Sn, g as vn, e as pn, d as kn, s as Cn, t as wn } from "./server-entry-f978b3a5.js";
|
|
6
|
+
function Me(e) {
|
|
7
|
+
return /* @__PURE__ */ B(h, { children: [
|
|
8
|
+
e.link ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
9
9
|
"a",
|
|
10
10
|
{
|
|
11
11
|
...e.attributes,
|
|
@@ -14,7 +14,7 @@ function Ue(e) {
|
|
|
14
14
|
role: "button",
|
|
15
15
|
children: e.text
|
|
16
16
|
}
|
|
17
|
-
) }) : /* @__PURE__ */
|
|
17
|
+
) }) : /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
18
18
|
"button",
|
|
19
19
|
{
|
|
20
20
|
...e.attributes,
|
|
@@ -23,12 +23,12 @@ function Ue(e) {
|
|
|
23
23
|
children: e.text
|
|
24
24
|
}
|
|
25
25
|
) }),
|
|
26
|
-
/* @__PURE__ */
|
|
26
|
+
/* @__PURE__ */ o("style", { children: `.button-fdf49de0 {
|
|
27
27
|
all: unset;
|
|
28
28
|
}` })
|
|
29
29
|
] });
|
|
30
30
|
}
|
|
31
|
-
const
|
|
31
|
+
const ee = ve({
|
|
32
32
|
content: null,
|
|
33
33
|
context: {},
|
|
34
34
|
localState: void 0,
|
|
@@ -41,8 +41,8 @@ const ne = Ce({
|
|
|
41
41
|
inheritedStyles: {},
|
|
42
42
|
BlocksWrapper: "div",
|
|
43
43
|
BlocksWrapperProps: {}
|
|
44
|
-
}),
|
|
45
|
-
function
|
|
44
|
+
}), Ce = ve({ registeredComponents: {} });
|
|
45
|
+
function Ue(e) {
|
|
46
46
|
var t;
|
|
47
47
|
return {
|
|
48
48
|
...(t = e.component) == null ? void 0 : t.options,
|
|
@@ -53,7 +53,7 @@ function De(e) {
|
|
|
53
53
|
builderBlock: e
|
|
54
54
|
};
|
|
55
55
|
}
|
|
56
|
-
const
|
|
56
|
+
const De = ({
|
|
57
57
|
builder: e,
|
|
58
58
|
context: t,
|
|
59
59
|
event: n,
|
|
@@ -65,83 +65,83 @@ const Oe = ({
|
|
|
65
65
|
builder: e,
|
|
66
66
|
context: t,
|
|
67
67
|
event: n
|
|
68
|
-
}),
|
|
68
|
+
}), He = () => ({
|
|
69
69
|
isEditing: V(),
|
|
70
70
|
isBrowser: $(),
|
|
71
71
|
isServer: !$(),
|
|
72
|
-
getUserAttributes: () =>
|
|
73
|
-
}),
|
|
72
|
+
getUserAttributes: () => $e()
|
|
73
|
+
}), Oe = (e, {
|
|
74
74
|
isExpression: t = !0
|
|
75
|
-
}) => /* we disable this for cases where we definitely don't want a return */ t && !(e.includes(";") || e.includes(" return ") || e.trim().startsWith("return ")) ? `return (${e});` : e,
|
|
75
|
+
}) => /* we disable this for cases where we definitely don't want a return */ t && !(e.includes(";") || e.includes(" return ") || e.trim().startsWith("return ")) ? `return (${e});` : e, ue = ({
|
|
76
76
|
code: e,
|
|
77
77
|
builder: t,
|
|
78
78
|
context: n,
|
|
79
79
|
event: i,
|
|
80
80
|
localState: a,
|
|
81
|
-
rootSetState:
|
|
81
|
+
rootSetState: c,
|
|
82
82
|
rootState: r
|
|
83
83
|
}) => {
|
|
84
|
-
const
|
|
84
|
+
const l = De({
|
|
85
85
|
builder: t,
|
|
86
86
|
context: n,
|
|
87
87
|
event: i,
|
|
88
|
-
state:
|
|
88
|
+
state: Ke(r, a, c)
|
|
89
89
|
});
|
|
90
|
-
return new Function(...
|
|
90
|
+
return new Function(...l.map(([s]) => s), e)(...l.map(([, s]) => s));
|
|
91
91
|
};
|
|
92
|
-
function
|
|
92
|
+
function Ke(e, t, n) {
|
|
93
93
|
if (e === t)
|
|
94
94
|
throw new Error("rootState === localState");
|
|
95
95
|
return new Proxy(e, {
|
|
96
96
|
get: (i, a) => t && a in t ? t[a] : e[a],
|
|
97
|
-
set: (i, a,
|
|
97
|
+
set: (i, a, c) => {
|
|
98
98
|
if (t && a in t)
|
|
99
99
|
throw new Error("Writing to local state is not allowed as it is read-only.");
|
|
100
|
-
return e[a] =
|
|
100
|
+
return e[a] = c, n == null || n(e), !0;
|
|
101
101
|
}
|
|
102
102
|
});
|
|
103
103
|
}
|
|
104
|
-
const
|
|
104
|
+
const ze = (e) => ($(), ue(e));
|
|
105
105
|
function _({
|
|
106
106
|
code: e,
|
|
107
107
|
context: t,
|
|
108
108
|
localState: n,
|
|
109
109
|
rootState: i,
|
|
110
110
|
rootSetState: a,
|
|
111
|
-
event:
|
|
111
|
+
event: c,
|
|
112
112
|
isExpression: r = !0
|
|
113
113
|
}) {
|
|
114
114
|
if (e === "") {
|
|
115
115
|
U.warn("Skipping evaluation of empty code block.");
|
|
116
116
|
return;
|
|
117
117
|
}
|
|
118
|
-
const
|
|
119
|
-
code:
|
|
118
|
+
const l = {
|
|
119
|
+
code: Oe(e, {
|
|
120
120
|
isExpression: r
|
|
121
121
|
}),
|
|
122
|
-
builder:
|
|
122
|
+
builder: He(),
|
|
123
123
|
context: t,
|
|
124
|
-
event:
|
|
124
|
+
event: c,
|
|
125
125
|
rootSetState: a,
|
|
126
126
|
rootState: i,
|
|
127
127
|
localState: n
|
|
128
128
|
};
|
|
129
129
|
try {
|
|
130
|
-
return
|
|
131
|
-
} catch (
|
|
132
|
-
U.error("Failed code evaluation: " +
|
|
130
|
+
return ze(l);
|
|
131
|
+
} catch (s) {
|
|
132
|
+
U.error("Failed code evaluation: " + s.message, {
|
|
133
133
|
code: e
|
|
134
134
|
});
|
|
135
135
|
return;
|
|
136
136
|
}
|
|
137
137
|
}
|
|
138
|
-
const
|
|
138
|
+
const qe = (e, t, n) => {
|
|
139
139
|
if (Object(e) !== e)
|
|
140
140
|
return e;
|
|
141
141
|
const i = Array.isArray(t) ? t : t.toString().match(/[^.[\]]+/g);
|
|
142
|
-
return i.slice(0, -1).reduce((a,
|
|
142
|
+
return i.slice(0, -1).reduce((a, c, r) => Object(a[c]) === a[c] ? a[c] : a[c] = Math.abs(Number(i[r + 1])) >> 0 === +i[r + 1] ? [] : {}, e)[i[i.length - 1]] = n, e;
|
|
143
143
|
};
|
|
144
|
-
const
|
|
144
|
+
const Ye = ({
|
|
145
145
|
block: e,
|
|
146
146
|
context: t,
|
|
147
147
|
localState: n,
|
|
@@ -150,58 +150,58 @@ const Qe = ({
|
|
|
150
150
|
}) => {
|
|
151
151
|
if (!e.bindings)
|
|
152
152
|
return e;
|
|
153
|
-
const
|
|
154
|
-
...
|
|
153
|
+
const c = Z(e), r = {
|
|
154
|
+
...c,
|
|
155
155
|
properties: {
|
|
156
|
-
...
|
|
156
|
+
...c.properties
|
|
157
157
|
},
|
|
158
158
|
actions: {
|
|
159
|
-
...
|
|
159
|
+
...c.actions
|
|
160
160
|
}
|
|
161
161
|
};
|
|
162
|
-
for (const
|
|
163
|
-
const
|
|
164
|
-
code:
|
|
162
|
+
for (const l in e.bindings) {
|
|
163
|
+
const s = e.bindings[l], d = _({
|
|
164
|
+
code: s,
|
|
165
165
|
localState: n,
|
|
166
166
|
rootState: i,
|
|
167
167
|
rootSetState: a,
|
|
168
168
|
context: t
|
|
169
169
|
});
|
|
170
|
-
|
|
170
|
+
qe(r, l, d);
|
|
171
171
|
}
|
|
172
172
|
return r;
|
|
173
173
|
};
|
|
174
|
-
function
|
|
174
|
+
function H({
|
|
175
175
|
block: e,
|
|
176
176
|
context: t,
|
|
177
177
|
shouldEvaluateBindings: n,
|
|
178
178
|
localState: i,
|
|
179
179
|
rootState: a,
|
|
180
|
-
rootSetState:
|
|
180
|
+
rootSetState: c
|
|
181
181
|
}) {
|
|
182
182
|
const r = e;
|
|
183
|
-
return n ?
|
|
183
|
+
return n ? Ye({
|
|
184
184
|
block: r,
|
|
185
185
|
localState: i,
|
|
186
186
|
rootState: a,
|
|
187
|
-
rootSetState:
|
|
187
|
+
rootSetState: c,
|
|
188
188
|
context: t
|
|
189
189
|
}) : r;
|
|
190
190
|
}
|
|
191
|
-
const
|
|
191
|
+
const Qe = ({
|
|
192
192
|
block: e,
|
|
193
193
|
context: t,
|
|
194
194
|
registeredComponents: n
|
|
195
195
|
}) => {
|
|
196
|
-
var
|
|
197
|
-
const i = (
|
|
196
|
+
var c;
|
|
197
|
+
const i = (c = H({
|
|
198
198
|
block: e,
|
|
199
199
|
localState: t.localState,
|
|
200
200
|
rootState: t.rootState,
|
|
201
201
|
rootSetState: t.rootSetState,
|
|
202
202
|
context: t.context,
|
|
203
203
|
shouldEvaluateBindings: !1
|
|
204
|
-
}).component) == null ? void 0 :
|
|
204
|
+
}).component) == null ? void 0 : c.name;
|
|
205
205
|
if (!i)
|
|
206
206
|
return null;
|
|
207
207
|
const a = n[i];
|
|
@@ -210,7 +210,7 @@ const Ge = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
210
210
|
console.warn(`
|
|
211
211
|
Could not find a registered component named "${i}".
|
|
212
212
|
If you registered it, is the file that registered it imported by the file that needs to render it?`);
|
|
213
|
-
},
|
|
213
|
+
}, Ge = ({
|
|
214
214
|
block: e,
|
|
215
215
|
context: t
|
|
216
216
|
}) => {
|
|
@@ -229,21 +229,21 @@ const Ge = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
229
229
|
});
|
|
230
230
|
if (!Array.isArray(a))
|
|
231
231
|
return;
|
|
232
|
-
const
|
|
233
|
-
return a.map((
|
|
232
|
+
const c = n.collection.split(".").pop(), r = n.itemName || (c ? c + "Item" : "item");
|
|
233
|
+
return a.map((s, d) => ({
|
|
234
234
|
context: {
|
|
235
235
|
...t,
|
|
236
236
|
localState: {
|
|
237
237
|
...t.localState,
|
|
238
238
|
$index: d,
|
|
239
|
-
$item:
|
|
240
|
-
[r]:
|
|
239
|
+
$item: s,
|
|
240
|
+
[r]: s,
|
|
241
241
|
[`$${r}Index`]: d
|
|
242
242
|
}
|
|
243
243
|
},
|
|
244
244
|
block: i
|
|
245
245
|
}));
|
|
246
|
-
},
|
|
246
|
+
}, we = {
|
|
247
247
|
small: {
|
|
248
248
|
min: 320,
|
|
249
249
|
default: 321,
|
|
@@ -259,11 +259,11 @@ const Ge = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
259
259
|
default: 991,
|
|
260
260
|
max: 1200
|
|
261
261
|
}
|
|
262
|
-
},
|
|
262
|
+
}, me = (e, t = we) => `@media (max-width: ${t[e].max}px)`, Ie = ({
|
|
263
263
|
small: e,
|
|
264
264
|
medium: t
|
|
265
265
|
}) => {
|
|
266
|
-
const n =
|
|
266
|
+
const n = Z(we);
|
|
267
267
|
if (!e || !t)
|
|
268
268
|
return n;
|
|
269
269
|
const i = Math.floor(e / 2);
|
|
@@ -278,35 +278,35 @@ const Ge = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
278
278
|
min: a,
|
|
279
279
|
default: a + 1
|
|
280
280
|
};
|
|
281
|
-
const
|
|
281
|
+
const c = n.medium.max + 1;
|
|
282
282
|
return n.large = {
|
|
283
283
|
max: 2e3,
|
|
284
284
|
// TODO: decide upper limit
|
|
285
|
-
min:
|
|
286
|
-
default:
|
|
285
|
+
min: c,
|
|
286
|
+
default: c + 1
|
|
287
287
|
}, n;
|
|
288
|
-
},
|
|
288
|
+
}, Je = (e) => e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase(), Te = (e) => Object.entries(e).map(([n, i]) => {
|
|
289
289
|
if (typeof i == "string")
|
|
290
|
-
return `${
|
|
291
|
-
}).filter(
|
|
292
|
-
`),
|
|
290
|
+
return `${Je(n)}: ${i};`;
|
|
291
|
+
}).filter(G), Xe = (e) => Te(e).join(`
|
|
292
|
+
`), Y = ({
|
|
293
293
|
mediaQuery: e,
|
|
294
294
|
className: t,
|
|
295
295
|
styles: n
|
|
296
296
|
}) => {
|
|
297
297
|
const i = `.${t} {
|
|
298
|
-
${
|
|
298
|
+
${Xe(n)}
|
|
299
299
|
}`;
|
|
300
300
|
return e ? `${e} {
|
|
301
301
|
${i}
|
|
302
302
|
}` : i;
|
|
303
303
|
};
|
|
304
|
-
function
|
|
305
|
-
return /* @__PURE__ */
|
|
304
|
+
function O(e) {
|
|
305
|
+
return /* @__PURE__ */ o("style", { dangerouslySetInnerHTML: { __html: e.styles }, id: e.id });
|
|
306
306
|
}
|
|
307
|
-
function
|
|
307
|
+
function Ze(e) {
|
|
308
308
|
function t() {
|
|
309
|
-
const i =
|
|
309
|
+
const i = H({
|
|
310
310
|
block: e.block,
|
|
311
311
|
localState: e.context.localState,
|
|
312
312
|
rootState: e.context.rootState,
|
|
@@ -314,48 +314,48 @@ function tt(e) {
|
|
|
314
314
|
context: e.context.context,
|
|
315
315
|
shouldEvaluateBindings: !0
|
|
316
316
|
});
|
|
317
|
-
return
|
|
317
|
+
return G(i.hide) ? !i.hide : G(i.show) ? i.show : !0;
|
|
318
318
|
}
|
|
319
319
|
function n() {
|
|
320
|
-
var
|
|
321
|
-
const i =
|
|
320
|
+
var k;
|
|
321
|
+
const i = H({
|
|
322
322
|
block: e.block,
|
|
323
323
|
localState: e.context.localState,
|
|
324
324
|
rootState: e.context.rootState,
|
|
325
325
|
rootSetState: e.context.rootSetState,
|
|
326
326
|
context: e.context.context,
|
|
327
327
|
shouldEvaluateBindings: !0
|
|
328
|
-
}), a = i.responsiveStyles,
|
|
329
|
-
((
|
|
330
|
-
),
|
|
331
|
-
if (!
|
|
328
|
+
}), a = i.responsiveStyles, c = e.context.content, r = Ie(
|
|
329
|
+
((k = c == null ? void 0 : c.meta) == null ? void 0 : k.breakpoints) || {}
|
|
330
|
+
), l = a == null ? void 0 : a.large, s = a == null ? void 0 : a.medium, d = a == null ? void 0 : a.small, m = i.id;
|
|
331
|
+
if (!m)
|
|
332
332
|
return "";
|
|
333
|
-
const
|
|
334
|
-
className:
|
|
335
|
-
styles:
|
|
336
|
-
}) : "", v =
|
|
337
|
-
className:
|
|
338
|
-
styles:
|
|
339
|
-
mediaQuery:
|
|
333
|
+
const g = l ? Y({
|
|
334
|
+
className: m,
|
|
335
|
+
styles: l
|
|
336
|
+
}) : "", v = s ? Y({
|
|
337
|
+
className: m,
|
|
338
|
+
styles: s,
|
|
339
|
+
mediaQuery: me(
|
|
340
340
|
"medium",
|
|
341
341
|
r
|
|
342
342
|
)
|
|
343
|
-
}) : "", y = d ?
|
|
344
|
-
className:
|
|
343
|
+
}) : "", y = d ? Y({
|
|
344
|
+
className: m,
|
|
345
345
|
styles: d,
|
|
346
|
-
mediaQuery:
|
|
346
|
+
mediaQuery: me(
|
|
347
347
|
"small",
|
|
348
348
|
r
|
|
349
349
|
)
|
|
350
350
|
}) : "";
|
|
351
|
-
return [
|
|
351
|
+
return [g, v, y].join(" ");
|
|
352
352
|
}
|
|
353
|
-
return /* @__PURE__ */
|
|
353
|
+
return /* @__PURE__ */ o(h, { children: n() && t() ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(O, { styles: n() }) }) : null });
|
|
354
354
|
}
|
|
355
|
-
function
|
|
355
|
+
function et(e) {
|
|
356
356
|
return e.charAt(0).toUpperCase() + e.slice(1);
|
|
357
357
|
}
|
|
358
|
-
const
|
|
358
|
+
const tt = (e) => `on${et(e)}`, nt = (e, t) => (n) => _({
|
|
359
359
|
code: e,
|
|
360
360
|
context: t.context,
|
|
361
361
|
localState: t.localState,
|
|
@@ -364,14 +364,14 @@ const it = (e) => `on${nt(e)}`, at = (e, t) => (n) => _({
|
|
|
364
364
|
event: n,
|
|
365
365
|
isExpression: !1
|
|
366
366
|
});
|
|
367
|
-
function
|
|
367
|
+
function Re(e) {
|
|
368
368
|
var i;
|
|
369
369
|
const t = {}, n = (i = e.block.actions) != null ? i : {};
|
|
370
370
|
for (const a in n) {
|
|
371
371
|
if (!n.hasOwnProperty(a))
|
|
372
372
|
continue;
|
|
373
|
-
const
|
|
374
|
-
let r =
|
|
373
|
+
const c = n[a];
|
|
374
|
+
let r = tt(a);
|
|
375
375
|
if (e.stripPrefix)
|
|
376
376
|
switch (L) {
|
|
377
377
|
case "vue":
|
|
@@ -381,42 +381,42 @@ function X(e) {
|
|
|
381
381
|
r = r.replace("on:", "");
|
|
382
382
|
break;
|
|
383
383
|
}
|
|
384
|
-
t[r] =
|
|
384
|
+
t[r] = nt(c, e);
|
|
385
385
|
}
|
|
386
386
|
return t;
|
|
387
387
|
}
|
|
388
|
-
function
|
|
388
|
+
function it({
|
|
389
389
|
properties: e
|
|
390
390
|
}) {
|
|
391
391
|
return e.className = e.class, delete e.class, e;
|
|
392
392
|
}
|
|
393
|
-
const
|
|
393
|
+
const at = (e) => ({
|
|
394
394
|
href: e.href
|
|
395
395
|
});
|
|
396
|
-
function
|
|
396
|
+
function te({
|
|
397
397
|
block: e,
|
|
398
398
|
context: t
|
|
399
399
|
}) {
|
|
400
400
|
var i;
|
|
401
401
|
const n = {
|
|
402
|
-
...
|
|
402
|
+
...at(e),
|
|
403
403
|
...e.properties,
|
|
404
404
|
"builder-id": e.id,
|
|
405
|
-
style: e.style ?
|
|
405
|
+
style: e.style ? ot(e.style) : void 0,
|
|
406
406
|
class: [e.id, "builder-block", e.class, (i = e.properties) == null ? void 0 : i.class].filter(Boolean).join(" ")
|
|
407
407
|
};
|
|
408
|
-
return
|
|
408
|
+
return it({
|
|
409
409
|
properties: n,
|
|
410
410
|
context: t,
|
|
411
411
|
block: e
|
|
412
412
|
});
|
|
413
413
|
}
|
|
414
|
-
function
|
|
414
|
+
function ot(e) {
|
|
415
415
|
switch (L) {
|
|
416
416
|
case "svelte":
|
|
417
417
|
case "vue":
|
|
418
418
|
case "solid":
|
|
419
|
-
return
|
|
419
|
+
return Te(e).join(" ");
|
|
420
420
|
case "qwik":
|
|
421
421
|
case "reactNative":
|
|
422
422
|
case "react":
|
|
@@ -424,61 +424,42 @@ function ct(e) {
|
|
|
424
424
|
return e;
|
|
425
425
|
}
|
|
426
426
|
}
|
|
427
|
-
|
|
428
|
-
return /* @__PURE__ */ P(h, { children: [
|
|
429
|
-
" ",
|
|
430
|
-
e.hasChildren ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ P(
|
|
431
|
-
e.Wrapper,
|
|
432
|
-
{
|
|
433
|
-
...K({
|
|
434
|
-
block: e.block,
|
|
435
|
-
context: e.context
|
|
436
|
-
}),
|
|
437
|
-
...X({
|
|
438
|
-
block: e.block,
|
|
439
|
-
rootState: e.context.rootState,
|
|
440
|
-
rootSetState: e.context.rootSetState,
|
|
441
|
-
localState: e.context.localState,
|
|
442
|
-
context: e.context.context,
|
|
443
|
-
stripPrefix: !0
|
|
444
|
-
}),
|
|
445
|
-
children: [
|
|
446
|
-
" ",
|
|
447
|
-
e.children,
|
|
448
|
-
" "
|
|
449
|
-
]
|
|
450
|
-
}
|
|
451
|
-
) }) : /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
452
|
-
e.Wrapper,
|
|
453
|
-
{
|
|
454
|
-
...K({
|
|
455
|
-
block: e.block,
|
|
456
|
-
context: e.context
|
|
457
|
-
}),
|
|
458
|
-
...X({
|
|
459
|
-
block: e.block,
|
|
460
|
-
rootState: e.context.rootState,
|
|
461
|
-
rootSetState: e.context.rootSetState,
|
|
462
|
-
localState: e.context.localState,
|
|
463
|
-
context: e.context.context,
|
|
464
|
-
stripPrefix: !0
|
|
465
|
-
})
|
|
466
|
-
}
|
|
467
|
-
) }),
|
|
468
|
-
" "
|
|
469
|
-
] });
|
|
470
|
-
}
|
|
427
|
+
const rt = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), ct = (e) => typeof e == "string" && rt.has(e.toLowerCase());
|
|
471
428
|
function lt(e) {
|
|
472
|
-
return /* @__PURE__ */
|
|
429
|
+
return /* @__PURE__ */ o(h, { children: ct(e.TagName) ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ o(h, { children: typeof e.TagName == "string" ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) : /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) }) });
|
|
430
|
+
}
|
|
431
|
+
function st(e) {
|
|
432
|
+
return /* @__PURE__ */ o(
|
|
433
|
+
lt,
|
|
434
|
+
{
|
|
435
|
+
TagName: e.Wrapper,
|
|
436
|
+
attributes: te({
|
|
437
|
+
block: e.block,
|
|
438
|
+
context: e.context
|
|
439
|
+
}),
|
|
440
|
+
actionAttributes: Re({
|
|
441
|
+
block: e.block,
|
|
442
|
+
rootState: e.context.rootState,
|
|
443
|
+
rootSetState: e.context.rootSetState,
|
|
444
|
+
localState: e.context.localState,
|
|
445
|
+
context: e.context.context,
|
|
446
|
+
stripPrefix: !0
|
|
447
|
+
}),
|
|
448
|
+
children: e.children
|
|
449
|
+
}
|
|
450
|
+
);
|
|
451
|
+
}
|
|
452
|
+
function dt(e) {
|
|
453
|
+
return /* @__PURE__ */ o(
|
|
473
454
|
e.Wrapper,
|
|
474
455
|
{
|
|
475
456
|
...e.wrapperProps,
|
|
476
457
|
attributes: e.includeBlockProps ? {
|
|
477
|
-
...
|
|
458
|
+
...te({
|
|
478
459
|
block: e.block,
|
|
479
460
|
context: e.context
|
|
480
461
|
}),
|
|
481
|
-
...
|
|
462
|
+
...Re({
|
|
482
463
|
block: e.block,
|
|
483
464
|
rootState: e.context.rootState,
|
|
484
465
|
rootSetState: e.context.rootSetState,
|
|
@@ -490,45 +471,45 @@ function lt(e) {
|
|
|
490
471
|
}
|
|
491
472
|
);
|
|
492
473
|
}
|
|
493
|
-
const
|
|
474
|
+
const ut = ({
|
|
494
475
|
componentOptions: e,
|
|
495
476
|
builderBlock: t,
|
|
496
477
|
context: n,
|
|
497
478
|
componentRef: i,
|
|
498
479
|
includeBlockProps: a,
|
|
499
|
-
isInteractive:
|
|
480
|
+
isInteractive: c,
|
|
500
481
|
contextValue: r
|
|
501
482
|
}) => {
|
|
502
|
-
const
|
|
483
|
+
const l = {
|
|
503
484
|
...e,
|
|
504
485
|
/**
|
|
505
486
|
* If `noWrap` is set to `true`, then the block's props/attributes are provided to the
|
|
506
487
|
* component itself directly. Otherwise, they are provided to the wrapper element.
|
|
507
488
|
*/
|
|
508
489
|
...a ? {
|
|
509
|
-
attributes:
|
|
490
|
+
attributes: te({
|
|
510
491
|
block: t,
|
|
511
492
|
context: r
|
|
512
493
|
})
|
|
513
494
|
} : {}
|
|
514
495
|
};
|
|
515
|
-
return
|
|
496
|
+
return c ? {
|
|
516
497
|
Wrapper: i,
|
|
517
498
|
block: t,
|
|
518
499
|
context: n,
|
|
519
500
|
wrapperProps: e,
|
|
520
501
|
includeBlockProps: a
|
|
521
|
-
} :
|
|
502
|
+
} : l;
|
|
522
503
|
};
|
|
523
|
-
function
|
|
504
|
+
function fe(e) {
|
|
524
505
|
var i;
|
|
525
506
|
const [t, n] = S(
|
|
526
|
-
() => e.isInteractive ?
|
|
507
|
+
() => e.isInteractive ? dt : e.componentRef
|
|
527
508
|
);
|
|
528
|
-
return /* @__PURE__ */
|
|
509
|
+
return /* @__PURE__ */ o(h, { children: e.componentRef ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
529
510
|
t,
|
|
530
511
|
{
|
|
531
|
-
...
|
|
512
|
+
...ut({
|
|
532
513
|
componentOptions: e.componentOptions,
|
|
533
514
|
builderBlock: e.builderBlock,
|
|
534
515
|
context: e.context,
|
|
@@ -537,8 +518,8 @@ function be(e) {
|
|
|
537
518
|
isInteractive: e.isInteractive,
|
|
538
519
|
contextValue: e.context
|
|
539
520
|
}),
|
|
540
|
-
children: (i = e.blockChildren) == null ? void 0 : i.map((a) => /* @__PURE__ */
|
|
541
|
-
|
|
521
|
+
children: (i = e.blockChildren) == null ? void 0 : i.map((a) => /* @__PURE__ */ o(
|
|
522
|
+
K,
|
|
542
523
|
{
|
|
543
524
|
block: a,
|
|
544
525
|
context: e.context,
|
|
@@ -549,10 +530,10 @@ function be(e) {
|
|
|
549
530
|
}
|
|
550
531
|
) }) : null });
|
|
551
532
|
}
|
|
552
|
-
function
|
|
533
|
+
function mt(e) {
|
|
553
534
|
const [t, n] = S(() => e.repeatContext);
|
|
554
|
-
return /* @__PURE__ */
|
|
555
|
-
|
|
535
|
+
return /* @__PURE__ */ o(ee.Provider, { value: t, children: /* @__PURE__ */ o(
|
|
536
|
+
K,
|
|
556
537
|
{
|
|
557
538
|
block: e.block,
|
|
558
539
|
context: t,
|
|
@@ -560,24 +541,24 @@ function dt(e) {
|
|
|
560
541
|
}
|
|
561
542
|
) });
|
|
562
543
|
}
|
|
563
|
-
function
|
|
564
|
-
var
|
|
544
|
+
function K(e) {
|
|
545
|
+
var m, g, v;
|
|
565
546
|
function t() {
|
|
566
|
-
return
|
|
547
|
+
return Qe({
|
|
567
548
|
block: e.block,
|
|
568
549
|
context: e.context,
|
|
569
550
|
registeredComponents: e.registeredComponents
|
|
570
551
|
});
|
|
571
552
|
}
|
|
572
553
|
function n() {
|
|
573
|
-
return
|
|
554
|
+
return Ge({
|
|
574
555
|
block: e.block,
|
|
575
556
|
context: e.context
|
|
576
557
|
});
|
|
577
558
|
}
|
|
578
559
|
function i() {
|
|
579
560
|
var y;
|
|
580
|
-
return (y = e.block.repeat) != null && y.collection ? e.block :
|
|
561
|
+
return (y = e.block.repeat) != null && y.collection ? e.block : H({
|
|
581
562
|
block: e.block,
|
|
582
563
|
localState: e.context.localState,
|
|
583
564
|
rootState: e.context.rootState,
|
|
@@ -589,114 +570,101 @@ function z(e) {
|
|
|
589
570
|
function a() {
|
|
590
571
|
return e.block.tagName || "div";
|
|
591
572
|
}
|
|
592
|
-
function
|
|
593
|
-
var
|
|
594
|
-
if ((
|
|
573
|
+
function c() {
|
|
574
|
+
var C, R;
|
|
575
|
+
if ((C = e.block.repeat) != null && C.collection)
|
|
595
576
|
return !!((R = n == null ? void 0 : n()) != null && R.length);
|
|
596
577
|
const y = "hide" in i() ? i().hide : !1;
|
|
597
578
|
return ("show" in i() ? i().show : !0) && !y;
|
|
598
579
|
}
|
|
599
580
|
function r() {
|
|
600
|
-
var
|
|
601
|
-
return !((
|
|
581
|
+
var k, C;
|
|
582
|
+
return !((k = t == null ? void 0 : t()) != null && k.component) && !n() ? (C = i().children) != null ? C : [] : [];
|
|
602
583
|
}
|
|
603
|
-
function
|
|
604
|
-
var y,
|
|
584
|
+
function l() {
|
|
585
|
+
var y, k, C, R, P, w;
|
|
605
586
|
return {
|
|
606
587
|
blockChildren: (y = i().children) != null ? y : [],
|
|
607
|
-
componentRef: (
|
|
588
|
+
componentRef: (k = t == null ? void 0 : t()) == null ? void 0 : k.component,
|
|
608
589
|
componentOptions: {
|
|
609
|
-
...
|
|
590
|
+
...Ue(i()),
|
|
610
591
|
builderContext: e.context,
|
|
611
|
-
...((
|
|
592
|
+
...((C = t == null ? void 0 : t()) == null ? void 0 : C.name) === "Symbol" || ((R = t == null ? void 0 : t()) == null ? void 0 : R.name) === "Columns" ? {
|
|
612
593
|
builderComponents: e.registeredComponents
|
|
613
594
|
} : {}
|
|
614
595
|
},
|
|
615
|
-
context:
|
|
596
|
+
context: s,
|
|
616
597
|
registeredComponents: e.registeredComponents,
|
|
617
598
|
builderBlock: i(),
|
|
618
|
-
includeBlockProps: ((
|
|
599
|
+
includeBlockProps: ((P = t == null ? void 0 : t()) == null ? void 0 : P.noWrap) === !0,
|
|
619
600
|
isInteractive: !((w = t == null ? void 0 : t()) != null && w.isRSC)
|
|
620
601
|
};
|
|
621
602
|
}
|
|
622
|
-
const [
|
|
623
|
-
return /* @__PURE__ */
|
|
624
|
-
/* @__PURE__ */
|
|
625
|
-
(
|
|
626
|
-
|
|
603
|
+
const [s, d] = S(() => e.context);
|
|
604
|
+
return /* @__PURE__ */ o(h, { children: c() ? /* @__PURE__ */ B(h, { children: [
|
|
605
|
+
/* @__PURE__ */ o(Ze, { block: e.block, context: e.context }),
|
|
606
|
+
(m = t == null ? void 0 : t()) != null && m.noWrap ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
607
|
+
fe,
|
|
627
608
|
{
|
|
628
|
-
componentRef:
|
|
629
|
-
componentOptions:
|
|
630
|
-
blockChildren:
|
|
631
|
-
context:
|
|
632
|
-
registeredComponents:
|
|
633
|
-
builderBlock:
|
|
634
|
-
includeBlockProps:
|
|
635
|
-
isInteractive:
|
|
609
|
+
componentRef: l().componentRef,
|
|
610
|
+
componentOptions: l().componentOptions,
|
|
611
|
+
blockChildren: l().blockChildren,
|
|
612
|
+
context: l().context,
|
|
613
|
+
registeredComponents: l().registeredComponents,
|
|
614
|
+
builderBlock: l().builderBlock,
|
|
615
|
+
includeBlockProps: l().includeBlockProps,
|
|
616
|
+
isInteractive: l().isInteractive
|
|
636
617
|
}
|
|
637
|
-
) }) : /* @__PURE__ */
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
(v = r()) == null ? void 0 : v.map((y) => /* @__PURE__ */ c(
|
|
678
|
-
z,
|
|
679
|
-
{
|
|
680
|
-
block: y,
|
|
681
|
-
context: l,
|
|
682
|
-
registeredComponents: e.registeredComponents
|
|
683
|
-
},
|
|
684
|
-
y.id
|
|
685
|
-
))
|
|
686
|
-
]
|
|
687
|
-
}
|
|
688
|
-
) }) : null
|
|
689
|
-
] })
|
|
618
|
+
) }) : /* @__PURE__ */ o(h, { children: n() ? /* @__PURE__ */ o(h, { children: (v = n()) == null ? void 0 : v.map((y, k) => /* @__PURE__ */ o(
|
|
619
|
+
mt,
|
|
620
|
+
{
|
|
621
|
+
repeatContext: y.context,
|
|
622
|
+
block: y.block,
|
|
623
|
+
registeredComponents: e.registeredComponents
|
|
624
|
+
},
|
|
625
|
+
k
|
|
626
|
+
)) }) : /* @__PURE__ */ o(h, { children: /* @__PURE__ */ B(
|
|
627
|
+
st,
|
|
628
|
+
{
|
|
629
|
+
Wrapper: a(),
|
|
630
|
+
block: i(),
|
|
631
|
+
context: e.context,
|
|
632
|
+
children: [
|
|
633
|
+
/* @__PURE__ */ o(
|
|
634
|
+
fe,
|
|
635
|
+
{
|
|
636
|
+
componentRef: l().componentRef,
|
|
637
|
+
componentOptions: l().componentOptions,
|
|
638
|
+
blockChildren: l().blockChildren,
|
|
639
|
+
context: l().context,
|
|
640
|
+
registeredComponents: l().registeredComponents,
|
|
641
|
+
builderBlock: l().builderBlock,
|
|
642
|
+
includeBlockProps: l().includeBlockProps,
|
|
643
|
+
isInteractive: l().isInteractive
|
|
644
|
+
}
|
|
645
|
+
),
|
|
646
|
+
(g = r()) == null ? void 0 : g.map((y) => /* @__PURE__ */ o(
|
|
647
|
+
K,
|
|
648
|
+
{
|
|
649
|
+
block: y,
|
|
650
|
+
context: s,
|
|
651
|
+
registeredComponents: e.registeredComponents
|
|
652
|
+
},
|
|
653
|
+
y.id
|
|
654
|
+
))
|
|
655
|
+
]
|
|
656
|
+
}
|
|
657
|
+
) }) })
|
|
690
658
|
] }) : null });
|
|
691
659
|
}
|
|
692
|
-
function
|
|
660
|
+
function ft(e) {
|
|
693
661
|
function t() {
|
|
694
662
|
var a;
|
|
695
663
|
return "builder-blocks" + ((a = e.blocks) != null && a.length ? "" : " no-blocks");
|
|
696
664
|
}
|
|
697
665
|
function n() {
|
|
698
|
-
var a,
|
|
699
|
-
V() && !((a = e.blocks) != null && a.length) && ((
|
|
666
|
+
var a, c;
|
|
667
|
+
V() && !((a = e.blocks) != null && a.length) && ((c = window.parent) == null || c.postMessage(
|
|
700
668
|
{
|
|
701
669
|
type: "builder.clickEmptyBlocks",
|
|
702
670
|
data: {
|
|
@@ -708,8 +676,8 @@ function ut(e) {
|
|
|
708
676
|
));
|
|
709
677
|
}
|
|
710
678
|
function i() {
|
|
711
|
-
var a,
|
|
712
|
-
V() && !((a = e.blocks) != null && a.length) && ((
|
|
679
|
+
var a, c;
|
|
680
|
+
V() && !((a = e.blocks) != null && a.length) && ((c = window.parent) == null || c.postMessage(
|
|
713
681
|
{
|
|
714
682
|
type: "builder.hoverEmptyBlocks",
|
|
715
683
|
data: {
|
|
@@ -720,8 +688,8 @@ function ut(e) {
|
|
|
720
688
|
"*"
|
|
721
689
|
));
|
|
722
690
|
}
|
|
723
|
-
return /* @__PURE__ */
|
|
724
|
-
/* @__PURE__ */
|
|
691
|
+
return /* @__PURE__ */ B(h, { children: [
|
|
692
|
+
/* @__PURE__ */ o(
|
|
725
693
|
e.BlocksWrapper,
|
|
726
694
|
{
|
|
727
695
|
className: t() + " props-blocks-wrapper-4f2c12d8",
|
|
@@ -735,18 +703,18 @@ function ut(e) {
|
|
|
735
703
|
children: e.children
|
|
736
704
|
}
|
|
737
705
|
),
|
|
738
|
-
/* @__PURE__ */
|
|
706
|
+
/* @__PURE__ */ o("style", { children: `.props-blocks-wrapper-4f2c12d8 {
|
|
739
707
|
display: flex;
|
|
740
708
|
flex-direction: column;
|
|
741
709
|
align-items: stretch;
|
|
742
710
|
}` })
|
|
743
711
|
] });
|
|
744
712
|
}
|
|
745
|
-
function
|
|
746
|
-
var i, a,
|
|
747
|
-
const t =
|
|
748
|
-
return /* @__PURE__ */
|
|
749
|
-
|
|
713
|
+
function z(e) {
|
|
714
|
+
var i, a, c;
|
|
715
|
+
const t = ce(ee), n = ce(Ce);
|
|
716
|
+
return /* @__PURE__ */ o(
|
|
717
|
+
ft,
|
|
750
718
|
{
|
|
751
719
|
blocks: e.blocks,
|
|
752
720
|
parent: e.parent,
|
|
@@ -754,8 +722,8 @@ function ie(e) {
|
|
|
754
722
|
styleProp: e.styleProp,
|
|
755
723
|
BlocksWrapper: (i = e.context) == null ? void 0 : i.BlocksWrapper,
|
|
756
724
|
BlocksWrapperProps: (a = e.context) == null ? void 0 : a.BlocksWrapperProps,
|
|
757
|
-
children: e.blocks ? /* @__PURE__ */
|
|
758
|
-
|
|
725
|
+
children: e.blocks ? /* @__PURE__ */ o(h, { children: (c = e.blocks) == null ? void 0 : c.map((r) => /* @__PURE__ */ o(
|
|
726
|
+
K,
|
|
759
727
|
{
|
|
760
728
|
block: r,
|
|
761
729
|
context: e.context || t,
|
|
@@ -766,61 +734,61 @@ function ie(e) {
|
|
|
766
734
|
}
|
|
767
735
|
);
|
|
768
736
|
}
|
|
769
|
-
function
|
|
770
|
-
var
|
|
737
|
+
function ht(e) {
|
|
738
|
+
var P;
|
|
771
739
|
const [t, n] = S(
|
|
772
740
|
() => typeof e.space == "number" ? e.space || 0 : 20
|
|
773
|
-
), [i, a] = S(() => e.columns || []), [
|
|
741
|
+
), [i, a] = S(() => e.columns || []), [c, r] = S(
|
|
774
742
|
() => e.stackColumnsAt || "tablet"
|
|
775
743
|
);
|
|
776
|
-
function
|
|
744
|
+
function l(w) {
|
|
777
745
|
var I;
|
|
778
746
|
return ((I = i[w]) == null ? void 0 : I.width) || 100 / i.length;
|
|
779
747
|
}
|
|
780
|
-
function
|
|
748
|
+
function s(w) {
|
|
781
749
|
const I = t * (i.length - 1) / i.length;
|
|
782
|
-
return `calc(${
|
|
750
|
+
return `calc(${l(w)}% - ${I}px)`;
|
|
783
751
|
}
|
|
784
752
|
function d({
|
|
785
753
|
stackedStyle: w,
|
|
786
754
|
desktopStyle: I
|
|
787
755
|
}) {
|
|
788
|
-
return
|
|
756
|
+
return c === "tablet" ? w : I;
|
|
789
757
|
}
|
|
790
|
-
function
|
|
758
|
+
function m({
|
|
791
759
|
stackedStyle: w,
|
|
792
760
|
desktopStyle: I
|
|
793
761
|
}) {
|
|
794
|
-
return
|
|
762
|
+
return c === "never" ? I : w;
|
|
795
763
|
}
|
|
796
|
-
const [
|
|
764
|
+
const [g, v] = S(
|
|
797
765
|
() => e.stackColumnsAt === "never" ? "row" : e.reverseColumnsWhenStacked ? "column-reverse" : "column"
|
|
798
766
|
);
|
|
799
767
|
function y() {
|
|
800
768
|
return {
|
|
801
|
-
"--flex-dir":
|
|
769
|
+
"--flex-dir": g,
|
|
802
770
|
"--flex-dir-tablet": d({
|
|
803
|
-
stackedStyle:
|
|
771
|
+
stackedStyle: g,
|
|
804
772
|
desktopStyle: "row"
|
|
805
773
|
})
|
|
806
774
|
};
|
|
807
775
|
}
|
|
808
|
-
function
|
|
809
|
-
const I = w === 0 ? 0 : t,
|
|
776
|
+
function k(w) {
|
|
777
|
+
const I = w === 0 ? 0 : t, W = s(w), A = `${I}px`, N = "100%", F = 0;
|
|
810
778
|
return {
|
|
811
|
-
width:
|
|
779
|
+
width: W,
|
|
812
780
|
["marginLeft"]: A,
|
|
813
|
-
"--column-width-mobile":
|
|
781
|
+
"--column-width-mobile": m({
|
|
814
782
|
stackedStyle: N,
|
|
815
|
-
desktopStyle:
|
|
783
|
+
desktopStyle: W
|
|
816
784
|
}),
|
|
817
|
-
"--column-margin-left-mobile":
|
|
785
|
+
"--column-margin-left-mobile": m({
|
|
818
786
|
stackedStyle: F,
|
|
819
787
|
desktopStyle: A
|
|
820
788
|
}),
|
|
821
789
|
"--column-width-tablet": d({
|
|
822
790
|
stackedStyle: N,
|
|
823
|
-
desktopStyle:
|
|
791
|
+
desktopStyle: W
|
|
824
792
|
}),
|
|
825
793
|
"--column-margin-left-tablet": d({
|
|
826
794
|
stackedStyle: F,
|
|
@@ -828,15 +796,15 @@ function mt(e) {
|
|
|
828
796
|
})
|
|
829
797
|
};
|
|
830
798
|
}
|
|
831
|
-
function
|
|
832
|
-
var
|
|
833
|
-
return
|
|
834
|
-
((A = (
|
|
799
|
+
function C(w) {
|
|
800
|
+
var W, A;
|
|
801
|
+
return Ie(
|
|
802
|
+
((A = (W = e.builderContext.content) == null ? void 0 : W.meta) == null ? void 0 : A.breakpoints) || {}
|
|
835
803
|
)[w].max;
|
|
836
804
|
}
|
|
837
805
|
function R() {
|
|
838
806
|
return `
|
|
839
|
-
@media (max-width: ${
|
|
807
|
+
@media (max-width: ${C("medium")}px) {
|
|
840
808
|
.${e.builderBlock.id}-breakpoints {
|
|
841
809
|
flex-direction: var(--flex-dir-tablet);
|
|
842
810
|
align-items: stretch;
|
|
@@ -848,7 +816,7 @@ function mt(e) {
|
|
|
848
816
|
}
|
|
849
817
|
}
|
|
850
818
|
|
|
851
|
-
@media (max-width: ${
|
|
819
|
+
@media (max-width: ${C("small")}px) {
|
|
852
820
|
.${e.builderBlock.id}-breakpoints {
|
|
853
821
|
flex-direction: var(--flex-dir);
|
|
854
822
|
align-items: stretch;
|
|
@@ -861,23 +829,23 @@ function mt(e) {
|
|
|
861
829
|
},
|
|
862
830
|
`;
|
|
863
831
|
}
|
|
864
|
-
return /* @__PURE__ */
|
|
865
|
-
/* @__PURE__ */
|
|
832
|
+
return /* @__PURE__ */ B(h, { children: [
|
|
833
|
+
/* @__PURE__ */ B(
|
|
866
834
|
"div",
|
|
867
835
|
{
|
|
868
836
|
className: `builder-columns ${e.builderBlock.id}-breakpoints div-3c01d6ec`,
|
|
869
837
|
style: y(),
|
|
870
838
|
children: [
|
|
871
|
-
/* @__PURE__ */
|
|
872
|
-
(
|
|
839
|
+
/* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(O, { styles: R() }) }),
|
|
840
|
+
(P = e.columns) == null ? void 0 : P.map((w, I) => /* @__PURE__ */ pe(
|
|
873
841
|
"div",
|
|
874
842
|
{
|
|
875
843
|
className: "builder-column div-3c01d6ec-2",
|
|
876
|
-
style:
|
|
844
|
+
style: k(I),
|
|
877
845
|
key: I
|
|
878
846
|
},
|
|
879
|
-
/* @__PURE__ */
|
|
880
|
-
|
|
847
|
+
/* @__PURE__ */ o(
|
|
848
|
+
z,
|
|
881
849
|
{
|
|
882
850
|
path: `component.options.columns.${I}.blocks`,
|
|
883
851
|
parent: e.builderBlock.id,
|
|
@@ -893,7 +861,7 @@ function mt(e) {
|
|
|
893
861
|
]
|
|
894
862
|
}
|
|
895
863
|
),
|
|
896
|
-
/* @__PURE__ */
|
|
864
|
+
/* @__PURE__ */ o("style", { children: `.div-3c01d6ec {
|
|
897
865
|
display: flex;
|
|
898
866
|
line-height: normal;
|
|
899
867
|
}.div-3c01d6ec-2 {
|
|
@@ -903,74 +871,74 @@ function mt(e) {
|
|
|
903
871
|
}` })
|
|
904
872
|
] });
|
|
905
873
|
}
|
|
906
|
-
function
|
|
907
|
-
return /* @__PURE__ */
|
|
874
|
+
function gt(e) {
|
|
875
|
+
return /* @__PURE__ */ o("span", { children: e.children });
|
|
908
876
|
}
|
|
909
|
-
function
|
|
877
|
+
function he(e) {
|
|
910
878
|
return e.replace(/http(s)?:/, "");
|
|
911
879
|
}
|
|
912
|
-
function
|
|
880
|
+
function bt(e = "", t, n) {
|
|
913
881
|
const i = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), a = e.indexOf("?") !== -1 ? "&" : "?";
|
|
914
882
|
return e.match(i) ? e.replace(i, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + a + t + "=" + encodeURIComponent(n);
|
|
915
883
|
}
|
|
916
|
-
function
|
|
884
|
+
function xt(e, t) {
|
|
917
885
|
if (!e || !(e != null && e.match(/cdn\.shopify\.com/)) || !t)
|
|
918
886
|
return e;
|
|
919
887
|
if (t === "master")
|
|
920
|
-
return
|
|
888
|
+
return he(e);
|
|
921
889
|
const n = e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);
|
|
922
890
|
if (n) {
|
|
923
|
-
const i = e.split(n[0]), a = n[3],
|
|
924
|
-
return
|
|
891
|
+
const i = e.split(n[0]), a = n[3], c = t.match("x") ? t : `${t}x`;
|
|
892
|
+
return he(`${i[0]}_${c}${a}`);
|
|
925
893
|
}
|
|
926
894
|
return null;
|
|
927
895
|
}
|
|
928
|
-
function
|
|
896
|
+
function Q(e) {
|
|
929
897
|
if (!e)
|
|
930
898
|
return e;
|
|
931
899
|
const t = [100, 200, 400, 800, 1200, 1600, 2e3];
|
|
932
900
|
if (e.match(/builder\.io/)) {
|
|
933
901
|
let n = e;
|
|
934
902
|
const i = Number(e.split("?width=")[1]);
|
|
935
|
-
return isNaN(i) || (n = `${n} ${i}w`), t.filter((a) => a !== i).map((a) => `${
|
|
903
|
+
return isNaN(i) || (n = `${n} ${i}w`), t.filter((a) => a !== i).map((a) => `${bt(e, "width", a)} ${a}w`).concat([n]).join(", ");
|
|
936
904
|
}
|
|
937
|
-
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [
|
|
905
|
+
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [xt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, i]) => `${n} ${i}w`).concat([e]).join(", ") : e;
|
|
938
906
|
}
|
|
939
|
-
function
|
|
940
|
-
var a,
|
|
907
|
+
function yt(e) {
|
|
908
|
+
var a, c, r, l;
|
|
941
909
|
function t() {
|
|
942
|
-
var
|
|
910
|
+
var m;
|
|
943
911
|
const d = e.image || e.src;
|
|
944
912
|
if (!d || // We can auto add srcset for cdn.builder.io and shopify
|
|
945
913
|
// images, otherwise you can supply this prop manually
|
|
946
914
|
!(d.match(/builder\.io/) || d.match(/cdn\.shopify\.com/)))
|
|
947
915
|
return e.srcset;
|
|
948
|
-
if (e.srcset && ((
|
|
916
|
+
if (e.srcset && ((m = e.image) != null && m.includes("builder.io/api/v1/image"))) {
|
|
949
917
|
if (!e.srcset.includes(e.image.split("?")[0]))
|
|
950
|
-
return console.debug("Removed given srcset"),
|
|
918
|
+
return console.debug("Removed given srcset"), Q(d);
|
|
951
919
|
} else if (e.image && !e.srcset)
|
|
952
|
-
return
|
|
953
|
-
return
|
|
920
|
+
return Q(d);
|
|
921
|
+
return Q(d);
|
|
954
922
|
}
|
|
955
923
|
function n() {
|
|
956
|
-
var
|
|
957
|
-
return (
|
|
924
|
+
var s;
|
|
925
|
+
return (s = t == null ? void 0 : t()) != null && s.match(/builder\.io/) && !e.noWebp ? t().replace(/\?/g, "?format=webp&") : "";
|
|
958
926
|
}
|
|
959
927
|
function i() {
|
|
960
|
-
const
|
|
928
|
+
const s = {
|
|
961
929
|
position: "absolute",
|
|
962
930
|
height: "100%",
|
|
963
931
|
width: "100%",
|
|
964
932
|
left: "0px",
|
|
965
933
|
top: "0px"
|
|
966
934
|
};
|
|
967
|
-
return e.aspectRatio ?
|
|
935
|
+
return e.aspectRatio ? s : void 0;
|
|
968
936
|
}
|
|
969
|
-
return /* @__PURE__ */
|
|
970
|
-
/* @__PURE__ */
|
|
971
|
-
/* @__PURE__ */
|
|
972
|
-
n() ? /* @__PURE__ */
|
|
973
|
-
/* @__PURE__ */
|
|
937
|
+
return /* @__PURE__ */ B(h, { children: [
|
|
938
|
+
/* @__PURE__ */ B(h, { children: [
|
|
939
|
+
/* @__PURE__ */ B("picture", { children: [
|
|
940
|
+
n() ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o("source", { type: "image/webp", srcSet: n() }) }) : null,
|
|
941
|
+
/* @__PURE__ */ o(
|
|
974
942
|
"img",
|
|
975
943
|
{
|
|
976
944
|
loading: "lazy",
|
|
@@ -988,7 +956,7 @@ function bt(e) {
|
|
|
988
956
|
}
|
|
989
957
|
)
|
|
990
958
|
] }),
|
|
991
|
-
e.aspectRatio && !((
|
|
959
|
+
e.aspectRatio && !((c = (a = e.builderBlock) == null ? void 0 : a.children) != null && c.length && e.fitContent) ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
992
960
|
"div",
|
|
993
961
|
{
|
|
994
962
|
className: "builder-image-sizer div-40c70c9b",
|
|
@@ -997,10 +965,10 @@ function bt(e) {
|
|
|
997
965
|
}
|
|
998
966
|
}
|
|
999
967
|
) }) : null,
|
|
1000
|
-
(
|
|
1001
|
-
!e.fitContent && e.children ? /* @__PURE__ */
|
|
968
|
+
(l = (r = e.builderBlock) == null ? void 0 : r.children) != null && l.length && e.fitContent ? /* @__PURE__ */ o(h, { children: e.children }) : null,
|
|
969
|
+
!e.fitContent && e.children ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o("div", { className: "div-40c70c9b-2", children: e.children }) }) : null
|
|
1002
970
|
] }),
|
|
1003
|
-
/* @__PURE__ */
|
|
971
|
+
/* @__PURE__ */ o("style", { children: `.img-40c70c9b {
|
|
1004
972
|
opacity: 1;
|
|
1005
973
|
transition: opacity 0.2s ease-in-out;
|
|
1006
974
|
}.div-40c70c9b {
|
|
@@ -1019,8 +987,8 @@ function bt(e) {
|
|
|
1019
987
|
}` })
|
|
1020
988
|
] });
|
|
1021
989
|
}
|
|
1022
|
-
function
|
|
1023
|
-
return /* @__PURE__ */
|
|
990
|
+
function St(e) {
|
|
991
|
+
return /* @__PURE__ */ o(
|
|
1024
992
|
"section",
|
|
1025
993
|
{
|
|
1026
994
|
...e.attributes,
|
|
@@ -1040,7 +1008,7 @@ function xt(e) {
|
|
|
1040
1008
|
}
|
|
1041
1009
|
);
|
|
1042
1010
|
}
|
|
1043
|
-
const
|
|
1011
|
+
const vt = {
|
|
1044
1012
|
name: "Core:Button",
|
|
1045
1013
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
1046
1014
|
defaultStyles: {
|
|
@@ -1073,7 +1041,7 @@ const yt = {
|
|
|
1073
1041
|
}],
|
|
1074
1042
|
static: !0,
|
|
1075
1043
|
noWrap: !0
|
|
1076
|
-
},
|
|
1044
|
+
}, pt = {
|
|
1077
1045
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
1078
1046
|
name: "Columns",
|
|
1079
1047
|
isRSC: !0,
|
|
@@ -1252,7 +1220,7 @@ const yt = {
|
|
|
1252
1220
|
});
|
|
1253
1221
|
}
|
|
1254
1222
|
const n = e.get("columns");
|
|
1255
|
-
Array.isArray(n) && n.find((a) => a.get("width")) && (n.find((
|
|
1223
|
+
Array.isArray(n) && n.find((a) => a.get("width")) && (n.find((c) => !c.get("width")) || n.reduce((l, s) => l + s.get("width"), 0) !== 100) && t();
|
|
1256
1224
|
}
|
|
1257
1225
|
}, {
|
|
1258
1226
|
name: "space",
|
|
@@ -1274,7 +1242,7 @@ const yt = {
|
|
|
1274
1242
|
helperText: "When stacking columns for mobile devices, reverse the ordering",
|
|
1275
1243
|
advanced: !0
|
|
1276
1244
|
}]
|
|
1277
|
-
},
|
|
1245
|
+
}, kt = {
|
|
1278
1246
|
name: "Custom Code",
|
|
1279
1247
|
static: !0,
|
|
1280
1248
|
requiredPermissions: ["editCode"],
|
|
@@ -1297,21 +1265,21 @@ const yt = {
|
|
|
1297
1265
|
advanced: !0
|
|
1298
1266
|
}]
|
|
1299
1267
|
};
|
|
1300
|
-
function
|
|
1301
|
-
const t =
|
|
1268
|
+
function Ct(e) {
|
|
1269
|
+
const t = X(null), [n, i] = S(() => []), [a, c] = S(() => []);
|
|
1302
1270
|
return E(() => {
|
|
1303
|
-
var
|
|
1304
|
-
if (!((
|
|
1271
|
+
var l;
|
|
1272
|
+
if (!((l = t.current) != null && l.getElementsByTagName) || typeof window == "undefined")
|
|
1305
1273
|
return;
|
|
1306
1274
|
const r = t.current.getElementsByTagName("script");
|
|
1307
|
-
for (let
|
|
1308
|
-
const d = r[
|
|
1275
|
+
for (let s = 0; s < r.length; s++) {
|
|
1276
|
+
const d = r[s];
|
|
1309
1277
|
if (d.src) {
|
|
1310
1278
|
if (n.includes(d.src))
|
|
1311
1279
|
continue;
|
|
1312
1280
|
n.push(d.src);
|
|
1313
|
-
const
|
|
1314
|
-
|
|
1281
|
+
const m = document.createElement("script");
|
|
1282
|
+
m.async = !0, m.src = d.src, document.head.appendChild(m);
|
|
1315
1283
|
} else if (!d.type || [
|
|
1316
1284
|
"text/javascript",
|
|
1317
1285
|
"application/javascript",
|
|
@@ -1321,12 +1289,12 @@ function pt(e) {
|
|
|
1321
1289
|
continue;
|
|
1322
1290
|
try {
|
|
1323
1291
|
a.push(d.innerText), new Function(d.innerText)();
|
|
1324
|
-
} catch (
|
|
1325
|
-
console.warn("`CustomCode`: Error running script:",
|
|
1292
|
+
} catch (m) {
|
|
1293
|
+
console.warn("`CustomCode`: Error running script:", m);
|
|
1326
1294
|
}
|
|
1327
1295
|
}
|
|
1328
1296
|
}
|
|
1329
|
-
}, []), /* @__PURE__ */
|
|
1297
|
+
}, []), /* @__PURE__ */ o(
|
|
1330
1298
|
"div",
|
|
1331
1299
|
{
|
|
1332
1300
|
ref: t,
|
|
@@ -1335,7 +1303,7 @@ function pt(e) {
|
|
|
1335
1303
|
}
|
|
1336
1304
|
);
|
|
1337
1305
|
}
|
|
1338
|
-
const
|
|
1306
|
+
const wt = {
|
|
1339
1307
|
name: "Embed",
|
|
1340
1308
|
static: !0,
|
|
1341
1309
|
inputs: [{
|
|
@@ -1360,30 +1328,30 @@ const kt = {
|
|
|
1360
1328
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
1361
1329
|
hideFromUI: !0
|
|
1362
1330
|
}]
|
|
1363
|
-
},
|
|
1364
|
-
function
|
|
1365
|
-
const t =
|
|
1366
|
-
function
|
|
1331
|
+
}, It = ["text/javascript", "application/javascript", "application/ecmascript"], Tt = (e) => It.includes(e.type);
|
|
1332
|
+
function Rt(e) {
|
|
1333
|
+
const t = X(null), [n, i] = S(() => []), [a, c] = S(() => []), [r, l] = S(() => !1);
|
|
1334
|
+
function s() {
|
|
1367
1335
|
if (!t.current || !t.current.getElementsByTagName)
|
|
1368
1336
|
return;
|
|
1369
1337
|
const d = t.current.getElementsByTagName("script");
|
|
1370
|
-
for (let
|
|
1371
|
-
const
|
|
1372
|
-
if (
|
|
1373
|
-
n.push(
|
|
1338
|
+
for (let m = 0; m < d.length; m++) {
|
|
1339
|
+
const g = d[m];
|
|
1340
|
+
if (g.src && !n.includes(g.src)) {
|
|
1341
|
+
n.push(g.src);
|
|
1374
1342
|
const v = document.createElement("script");
|
|
1375
|
-
v.async = !0, v.src =
|
|
1376
|
-
} else if (
|
|
1343
|
+
v.async = !0, v.src = g.src, document.head.appendChild(v);
|
|
1344
|
+
} else if (Tt(g) && !a.includes(g.innerText))
|
|
1377
1345
|
try {
|
|
1378
|
-
a.push(
|
|
1346
|
+
a.push(g.innerText), new Function(g.innerText)();
|
|
1379
1347
|
} catch (v) {
|
|
1380
1348
|
console.warn("`Embed`: Error running script:", v);
|
|
1381
1349
|
}
|
|
1382
1350
|
}
|
|
1383
1351
|
}
|
|
1384
1352
|
return E(() => {
|
|
1385
|
-
t.current && !r && (
|
|
1386
|
-
}, [t.current, r]), /* @__PURE__ */
|
|
1353
|
+
t.current && !r && (l(!0), s());
|
|
1354
|
+
}, [t.current, r]), /* @__PURE__ */ o(
|
|
1387
1355
|
"div",
|
|
1388
1356
|
{
|
|
1389
1357
|
className: "builder-embed",
|
|
@@ -1392,13 +1360,13 @@ function It(e) {
|
|
|
1392
1360
|
}
|
|
1393
1361
|
);
|
|
1394
1362
|
}
|
|
1395
|
-
const
|
|
1363
|
+
const Et = {
|
|
1396
1364
|
name: "Fragment",
|
|
1397
1365
|
static: !0,
|
|
1398
1366
|
hidden: !0,
|
|
1399
1367
|
canHaveChildren: !0,
|
|
1400
1368
|
noWrap: !0
|
|
1401
|
-
},
|
|
1369
|
+
}, Pt = {
|
|
1402
1370
|
name: "Image",
|
|
1403
1371
|
static: !0,
|
|
1404
1372
|
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",
|
|
@@ -1418,29 +1386,29 @@ const Tt = {
|
|
|
1418
1386
|
defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
|
|
1419
1387
|
onChange: (e) => {
|
|
1420
1388
|
e.delete("srcset"), e.delete("noWebp");
|
|
1421
|
-
function n(r,
|
|
1422
|
-
return new Promise((
|
|
1423
|
-
const
|
|
1424
|
-
let
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
},
|
|
1389
|
+
function n(r, l = 6e4) {
|
|
1390
|
+
return new Promise((s, d) => {
|
|
1391
|
+
const m = document.createElement("img");
|
|
1392
|
+
let g = !1;
|
|
1393
|
+
m.onload = () => {
|
|
1394
|
+
g = !0, s(m);
|
|
1395
|
+
}, m.addEventListener("error", (v) => {
|
|
1428
1396
|
console.warn("Image load failed", v.error), d(v.error);
|
|
1429
|
-
}),
|
|
1430
|
-
|
|
1431
|
-
},
|
|
1397
|
+
}), m.src = r, setTimeout(() => {
|
|
1398
|
+
g || d(new Error("Image load timed out"));
|
|
1399
|
+
}, l);
|
|
1432
1400
|
});
|
|
1433
1401
|
}
|
|
1434
1402
|
function i(r) {
|
|
1435
1403
|
return Math.round(r * 1e3) / 1e3;
|
|
1436
1404
|
}
|
|
1437
|
-
const a = e.get("image"),
|
|
1405
|
+
const a = e.get("image"), c = e.get("aspectRatio");
|
|
1438
1406
|
if (fetch(a).then((r) => r.blob()).then((r) => {
|
|
1439
1407
|
r.type.includes("svg") && e.set("noWebp", !0);
|
|
1440
|
-
}), a && (!
|
|
1408
|
+
}), a && (!c || c === 0.7041))
|
|
1441
1409
|
return n(a).then((r) => {
|
|
1442
|
-
const
|
|
1443
|
-
e.get("image") === a && (!
|
|
1410
|
+
const l = e.get("aspectRatio");
|
|
1411
|
+
e.get("image") === a && (!l || l === 0.7041) && r.width && r.height && (e.set("aspectRatio", i(r.height / r.width)), e.set("height", r.height), e.set("width", r.width));
|
|
1444
1412
|
});
|
|
1445
1413
|
}
|
|
1446
1414
|
}, {
|
|
@@ -1498,7 +1466,7 @@ const Tt = {
|
|
|
1498
1466
|
advanced: !0,
|
|
1499
1467
|
defaultValue: 0.7041
|
|
1500
1468
|
}]
|
|
1501
|
-
},
|
|
1469
|
+
}, Bt = {
|
|
1502
1470
|
// friendlyName?
|
|
1503
1471
|
name: "Raw:Img",
|
|
1504
1472
|
hideFromInsertMenu: !0,
|
|
@@ -1513,8 +1481,8 @@ const Tt = {
|
|
|
1513
1481
|
noWrap: !0,
|
|
1514
1482
|
static: !0
|
|
1515
1483
|
};
|
|
1516
|
-
function
|
|
1517
|
-
return /* @__PURE__ */
|
|
1484
|
+
function Wt(e) {
|
|
1485
|
+
return /* @__PURE__ */ o(
|
|
1518
1486
|
"img",
|
|
1519
1487
|
{
|
|
1520
1488
|
style: {
|
|
@@ -1528,7 +1496,7 @@ function Pt(e) {
|
|
|
1528
1496
|
V() && e.imgSrc || "default-key"
|
|
1529
1497
|
);
|
|
1530
1498
|
}
|
|
1531
|
-
const
|
|
1499
|
+
const At = {
|
|
1532
1500
|
name: "Core:Section",
|
|
1533
1501
|
static: !0,
|
|
1534
1502
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -1567,7 +1535,44 @@ const Wt = {
|
|
|
1567
1535
|
}
|
|
1568
1536
|
}
|
|
1569
1537
|
}]
|
|
1570
|
-
},
|
|
1538
|
+
}, Vt = {
|
|
1539
|
+
name: "Slot",
|
|
1540
|
+
isRSC: !0,
|
|
1541
|
+
description: "Allow child blocks to be inserted into this content when used as a Symbol",
|
|
1542
|
+
docsLink: "https://www.builder.io/c/docs/symbols-with-blocks",
|
|
1543
|
+
image: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F3aad6de36eae43b59b52c85190fdef56",
|
|
1544
|
+
// Maybe wrap this for canHaveChildren so bind children to this hm
|
|
1545
|
+
inputs: [{
|
|
1546
|
+
name: "name",
|
|
1547
|
+
type: "string",
|
|
1548
|
+
required: !0,
|
|
1549
|
+
defaultValue: "children"
|
|
1550
|
+
}]
|
|
1551
|
+
};
|
|
1552
|
+
function $t(e) {
|
|
1553
|
+
var t, n, i;
|
|
1554
|
+
return /* @__PURE__ */ o(
|
|
1555
|
+
"div",
|
|
1556
|
+
{
|
|
1557
|
+
style: {
|
|
1558
|
+
pointerEvents: "auto"
|
|
1559
|
+
},
|
|
1560
|
+
...!((t = e.builderContext.context) != null && t.symbolId) && {
|
|
1561
|
+
"builder-slot": e.name
|
|
1562
|
+
},
|
|
1563
|
+
children: /* @__PURE__ */ o(
|
|
1564
|
+
z,
|
|
1565
|
+
{
|
|
1566
|
+
parent: (n = e.builderContext.context) == null ? void 0 : n.symbolId,
|
|
1567
|
+
path: `symbol.data.${e.name}`,
|
|
1568
|
+
context: e.builderContext,
|
|
1569
|
+
blocks: (i = e.builderContext.rootState) == null ? void 0 : i[e.name]
|
|
1570
|
+
}
|
|
1571
|
+
)
|
|
1572
|
+
}
|
|
1573
|
+
);
|
|
1574
|
+
}
|
|
1575
|
+
const Nt = {
|
|
1571
1576
|
name: "Symbol",
|
|
1572
1577
|
noWrap: !0,
|
|
1573
1578
|
static: !0,
|
|
@@ -1600,7 +1605,7 @@ const Wt = {
|
|
|
1600
1605
|
hideFromUI: !0,
|
|
1601
1606
|
type: "boolean"
|
|
1602
1607
|
}]
|
|
1603
|
-
},
|
|
1608
|
+
}, Ft = {
|
|
1604
1609
|
name: "Text",
|
|
1605
1610
|
static: !0,
|
|
1606
1611
|
isRSC: !0,
|
|
@@ -1619,9 +1624,9 @@ const Wt = {
|
|
|
1619
1624
|
textAlign: "center"
|
|
1620
1625
|
}
|
|
1621
1626
|
};
|
|
1622
|
-
function
|
|
1627
|
+
function _t(e) {
|
|
1623
1628
|
var t;
|
|
1624
|
-
return /* @__PURE__ */
|
|
1629
|
+
return /* @__PURE__ */ o(
|
|
1625
1630
|
"div",
|
|
1626
1631
|
{
|
|
1627
1632
|
className: "builder-text",
|
|
@@ -1632,7 +1637,7 @@ function Vt(e) {
|
|
|
1632
1637
|
}
|
|
1633
1638
|
);
|
|
1634
1639
|
}
|
|
1635
|
-
const
|
|
1640
|
+
const Lt = {
|
|
1636
1641
|
name: "Video",
|
|
1637
1642
|
canHaveChildren: !0,
|
|
1638
1643
|
defaultStyles: {
|
|
@@ -1714,8 +1719,8 @@ const $t = {
|
|
|
1714
1719
|
advanced: !0
|
|
1715
1720
|
}]
|
|
1716
1721
|
};
|
|
1717
|
-
function
|
|
1718
|
-
var i, a,
|
|
1722
|
+
function jt(e) {
|
|
1723
|
+
var i, a, c, r, l, s, d;
|
|
1719
1724
|
function t() {
|
|
1720
1725
|
return {
|
|
1721
1726
|
...e.autoPlay === !0 ? {
|
|
@@ -1740,14 +1745,14 @@ function Nt(e) {
|
|
|
1740
1745
|
...t()
|
|
1741
1746
|
};
|
|
1742
1747
|
}
|
|
1743
|
-
return /* @__PURE__ */
|
|
1748
|
+
return /* @__PURE__ */ B(
|
|
1744
1749
|
"div",
|
|
1745
1750
|
{
|
|
1746
1751
|
style: {
|
|
1747
1752
|
position: "relative"
|
|
1748
1753
|
},
|
|
1749
1754
|
children: [
|
|
1750
|
-
/* @__PURE__ */
|
|
1755
|
+
/* @__PURE__ */ o(
|
|
1751
1756
|
"video",
|
|
1752
1757
|
{
|
|
1753
1758
|
className: "builder-video",
|
|
@@ -1769,10 +1774,10 @@ function Nt(e) {
|
|
|
1769
1774
|
},
|
|
1770
1775
|
src: e.video || "no-src",
|
|
1771
1776
|
poster: e.posterImage,
|
|
1772
|
-
children: e.lazyLoad ? null : /* @__PURE__ */
|
|
1777
|
+
children: e.lazyLoad ? null : /* @__PURE__ */ o("source", { type: "video/mp4", src: e.video })
|
|
1773
1778
|
}
|
|
1774
1779
|
),
|
|
1775
|
-
e.aspectRatio && !(e.fitContent && ((
|
|
1780
|
+
e.aspectRatio && !(e.fitContent && ((c = (a = e.builderBlock) == null ? void 0 : a.children) != null && c.length)) ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
1776
1781
|
"div",
|
|
1777
1782
|
{
|
|
1778
1783
|
style: {
|
|
@@ -1783,7 +1788,7 @@ function Nt(e) {
|
|
|
1783
1788
|
}
|
|
1784
1789
|
}
|
|
1785
1790
|
) }) : null,
|
|
1786
|
-
(
|
|
1791
|
+
(l = (r = e.builderBlock) == null ? void 0 : r.children) != null && l.length && e.fitContent ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
1787
1792
|
"div",
|
|
1788
1793
|
{
|
|
1789
1794
|
style: {
|
|
@@ -1794,7 +1799,7 @@ function Nt(e) {
|
|
|
1794
1799
|
children: e.children
|
|
1795
1800
|
}
|
|
1796
1801
|
) }) : null,
|
|
1797
|
-
(d = (
|
|
1802
|
+
(d = (s = e.builderBlock) == null ? void 0 : s.children) != null && d.length && !e.fitContent ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
1798
1803
|
"div",
|
|
1799
1804
|
{
|
|
1800
1805
|
style: {
|
|
@@ -1815,40 +1820,43 @@ function Nt(e) {
|
|
|
1815
1820
|
}
|
|
1816
1821
|
);
|
|
1817
1822
|
}
|
|
1818
|
-
const
|
|
1819
|
-
component:
|
|
1820
|
-
...yt
|
|
1821
|
-
}, {
|
|
1822
|
-
component: mt,
|
|
1823
|
-
...St
|
|
1824
|
-
}, {
|
|
1825
|
-
component: pt,
|
|
1823
|
+
const ge = () => [{
|
|
1824
|
+
component: Me,
|
|
1826
1825
|
...vt
|
|
1827
1826
|
}, {
|
|
1828
|
-
component:
|
|
1829
|
-
...
|
|
1827
|
+
component: ht,
|
|
1828
|
+
...pt
|
|
1830
1829
|
}, {
|
|
1831
|
-
component:
|
|
1832
|
-
...
|
|
1830
|
+
component: Ct,
|
|
1831
|
+
...kt
|
|
1833
1832
|
}, {
|
|
1834
|
-
component:
|
|
1835
|
-
...
|
|
1833
|
+
component: Rt,
|
|
1834
|
+
...wt
|
|
1836
1835
|
}, {
|
|
1837
|
-
component:
|
|
1836
|
+
component: gt,
|
|
1838
1837
|
...Et
|
|
1839
1838
|
}, {
|
|
1840
|
-
component:
|
|
1841
|
-
...
|
|
1839
|
+
component: yt,
|
|
1840
|
+
...Pt
|
|
1842
1841
|
}, {
|
|
1843
|
-
component:
|
|
1842
|
+
component: Wt,
|
|
1844
1843
|
...Bt
|
|
1845
1844
|
}, {
|
|
1846
|
-
component:
|
|
1845
|
+
component: St,
|
|
1847
1846
|
...At
|
|
1848
1847
|
}, {
|
|
1849
|
-
component:
|
|
1850
|
-
|
|
1851
|
-
}
|
|
1848
|
+
component: sn,
|
|
1849
|
+
...Nt
|
|
1850
|
+
}, {
|
|
1851
|
+
component: _t,
|
|
1852
|
+
...Ft
|
|
1853
|
+
}, {
|
|
1854
|
+
component: jt,
|
|
1855
|
+
...Lt
|
|
1856
|
+
}, {
|
|
1857
|
+
component: $t,
|
|
1858
|
+
...Vt
|
|
1859
|
+
}], Mt = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
|
|
1852
1860
|
function getAndSetVariantId() {
|
|
1853
1861
|
function setCookie(name, value, days) {
|
|
1854
1862
|
let expires = '';
|
|
@@ -1904,7 +1912,7 @@ const ye = () => [{
|
|
|
1904
1912
|
}).join('');
|
|
1905
1913
|
styleEl.innerHTML = newStyleStr;
|
|
1906
1914
|
}
|
|
1907
|
-
}`,
|
|
1915
|
+
}`, Ut = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
|
|
1908
1916
|
if (!navigator.cookieEnabled) {
|
|
1909
1917
|
return;
|
|
1910
1918
|
}
|
|
@@ -1938,27 +1946,27 @@ const ye = () => [{
|
|
|
1938
1946
|
thisScriptEl?.remove();
|
|
1939
1947
|
}
|
|
1940
1948
|
return;
|
|
1941
|
-
}`,
|
|
1949
|
+
}`, Ee = "builderIoAbTest", Pe = "builderIoRenderContent", M = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
|
|
1942
1950
|
...t,
|
|
1943
1951
|
testVariationId: t.id,
|
|
1944
1952
|
id: e == null ? void 0 : e.id
|
|
1945
|
-
})),
|
|
1953
|
+
})), Dt = ({
|
|
1946
1954
|
canTrack: e,
|
|
1947
1955
|
content: t
|
|
1948
|
-
}) => !(!(M(t).length > 0) || !e || $()),
|
|
1949
|
-
window.${
|
|
1950
|
-
window.${
|
|
1951
|
-
`,
|
|
1952
|
-
window.${
|
|
1953
|
-
"${t}",${JSON.stringify(e)}, ${
|
|
1954
|
-
)`,
|
|
1956
|
+
}) => !(!(M(t).length > 0) || !e || $()), Ht = (e) => e === "react" || e === "reactNative", Be = Ht(L), Ot = () => `
|
|
1957
|
+
window.${Ee} = ${Mt}
|
|
1958
|
+
window.${Pe} = ${Ut}
|
|
1959
|
+
`, Kt = (e, t) => `
|
|
1960
|
+
window.${Ee}(
|
|
1961
|
+
"${t}",${JSON.stringify(e)}, ${Be}
|
|
1962
|
+
)`, zt = ({
|
|
1955
1963
|
contentId: e,
|
|
1956
1964
|
variationId: t
|
|
1957
|
-
}) => `window.${
|
|
1958
|
-
"${t}", "${e}", ${
|
|
1965
|
+
}) => `window.${Pe}(
|
|
1966
|
+
"${t}", "${e}", ${Be}
|
|
1959
1967
|
)`;
|
|
1960
|
-
function
|
|
1961
|
-
return /* @__PURE__ */
|
|
1968
|
+
function J(e) {
|
|
1969
|
+
return /* @__PURE__ */ o(
|
|
1962
1970
|
"script",
|
|
1963
1971
|
{
|
|
1964
1972
|
dangerouslySetInnerHTML: { __html: e.scriptStr },
|
|
@@ -1966,10 +1974,15 @@ function Z(e) {
|
|
|
1966
1974
|
}
|
|
1967
1975
|
);
|
|
1968
1976
|
}
|
|
1969
|
-
|
|
1977
|
+
const qt = ["*.beta.builder.io", "beta.builder.io", "builder.io", "localhost", "qa.builder.io"];
|
|
1978
|
+
function We(e, t) {
|
|
1979
|
+
const n = new URL(t.origin), i = n.hostname;
|
|
1980
|
+
return (e || qt).findIndex((a) => a.startsWith("*.") ? i.endsWith(a.slice(1)) : a === i) > -1;
|
|
1981
|
+
}
|
|
1982
|
+
function be(e) {
|
|
1970
1983
|
return Math.round(e * 1e3) / 1e3;
|
|
1971
1984
|
}
|
|
1972
|
-
const
|
|
1985
|
+
const Yt = (e, t, n = !0) => {
|
|
1973
1986
|
if (!(e instanceof HTMLElement))
|
|
1974
1987
|
return null;
|
|
1975
1988
|
let i = n ? e : e.parentElement;
|
|
@@ -1980,36 +1993,36 @@ const Ot = (e, t, n = !0) => {
|
|
|
1980
1993
|
return i;
|
|
1981
1994
|
} while (i = i.parentElement);
|
|
1982
1995
|
return null;
|
|
1983
|
-
},
|
|
1996
|
+
}, Qt = (e) => Yt(e, (t) => {
|
|
1984
1997
|
const n = t.getAttribute("builder-id") || t.id;
|
|
1985
1998
|
return (n == null ? void 0 : n.indexOf("builder-")) === 0;
|
|
1986
|
-
}),
|
|
1999
|
+
}), xe = ({
|
|
1987
2000
|
event: e,
|
|
1988
2001
|
target: t
|
|
1989
2002
|
}) => {
|
|
1990
|
-
const n = t.getBoundingClientRect(), i = e.clientX - n.left, a = e.clientY - n.top,
|
|
2003
|
+
const n = t.getBoundingClientRect(), i = e.clientX - n.left, a = e.clientY - n.top, c = be(i / n.width), r = be(a / n.height);
|
|
1991
2004
|
return {
|
|
1992
|
-
x:
|
|
2005
|
+
x: c,
|
|
1993
2006
|
y: r
|
|
1994
2007
|
};
|
|
1995
|
-
},
|
|
1996
|
-
const t = e.target, n = t &&
|
|
2008
|
+
}, Gt = (e) => {
|
|
2009
|
+
const t = e.target, n = t && Qt(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
|
|
1997
2010
|
return {
|
|
1998
2011
|
targetBuilderElement: i || void 0,
|
|
1999
2012
|
metadata: {
|
|
2000
|
-
targetOffset: t ?
|
|
2013
|
+
targetOffset: t ? xe({
|
|
2001
2014
|
event: e,
|
|
2002
2015
|
target: t
|
|
2003
2016
|
}) : void 0,
|
|
2004
|
-
builderTargetOffset: n ?
|
|
2017
|
+
builderTargetOffset: n ? xe({
|
|
2005
2018
|
event: e,
|
|
2006
2019
|
target: n
|
|
2007
2020
|
}) : void 0,
|
|
2008
2021
|
builderElementIndex: n && i ? [].slice.call(document.getElementsByClassName(i)).indexOf(n) : void 0
|
|
2009
2022
|
}
|
|
2010
2023
|
};
|
|
2011
|
-
},
|
|
2012
|
-
|
|
2024
|
+
}, Jt = "0.12.2", Xt = () => {
|
|
2025
|
+
Ne("insertMenu", {
|
|
2013
2026
|
name: "_default",
|
|
2014
2027
|
default: !0,
|
|
2015
2028
|
items: [{
|
|
@@ -2031,14 +2044,14 @@ const Ot = (e, t, n = !0) => {
|
|
|
2031
2044
|
}]
|
|
2032
2045
|
});
|
|
2033
2046
|
};
|
|
2034
|
-
let
|
|
2035
|
-
const
|
|
2047
|
+
let ye = !1;
|
|
2048
|
+
const Zt = (e = {}) => {
|
|
2036
2049
|
var t, n;
|
|
2037
|
-
|
|
2050
|
+
ye || (ye = !0, $() && ((t = window.parent) == null || t.postMessage({
|
|
2038
2051
|
type: "builder.sdkInfo",
|
|
2039
2052
|
data: {
|
|
2040
2053
|
target: L,
|
|
2041
|
-
version:
|
|
2054
|
+
version: Jt,
|
|
2042
2055
|
supportsPatchUpdates: !1,
|
|
2043
2056
|
// Supports builder-model="..." attribute which is needed to
|
|
2044
2057
|
// scope our '+ add block' button styling
|
|
@@ -2050,40 +2063,43 @@ const Yt = (e = {}) => {
|
|
|
2050
2063
|
data: {
|
|
2051
2064
|
options: e
|
|
2052
2065
|
}
|
|
2053
|
-
}, "*"), window.addEventListener("message", ({
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
|
|
2066
|
+
}, "*"), window.addEventListener("message", (i) => {
|
|
2067
|
+
var c, r;
|
|
2068
|
+
if (!We(e.trustedHosts, i))
|
|
2069
|
+
return;
|
|
2070
|
+
const {
|
|
2071
|
+
data: a
|
|
2072
|
+
} = i;
|
|
2073
|
+
if (a != null && a.type)
|
|
2074
|
+
switch (a.type) {
|
|
2059
2075
|
case "builder.evaluate": {
|
|
2060
|
-
const
|
|
2061
|
-
let
|
|
2076
|
+
const l = a.data.text, s = a.data.arguments || [], d = a.data.id, m = new Function(l);
|
|
2077
|
+
let g, v = null;
|
|
2062
2078
|
try {
|
|
2063
|
-
|
|
2064
|
-
} catch (
|
|
2065
|
-
|
|
2079
|
+
g = m.apply(null, s);
|
|
2080
|
+
} catch (y) {
|
|
2081
|
+
v = y;
|
|
2066
2082
|
}
|
|
2067
|
-
|
|
2083
|
+
v ? (c = window.parent) == null || c.postMessage({
|
|
2068
2084
|
type: "builder.evaluateError",
|
|
2069
2085
|
data: {
|
|
2070
|
-
id:
|
|
2071
|
-
error:
|
|
2086
|
+
id: d,
|
|
2087
|
+
error: v.message
|
|
2072
2088
|
}
|
|
2073
|
-
}, "*") :
|
|
2074
|
-
var
|
|
2075
|
-
(
|
|
2089
|
+
}, "*") : g && typeof g.then == "function" ? g.then((y) => {
|
|
2090
|
+
var k;
|
|
2091
|
+
(k = window.parent) == null || k.postMessage({
|
|
2076
2092
|
type: "builder.evaluateResult",
|
|
2077
2093
|
data: {
|
|
2078
|
-
id:
|
|
2079
|
-
result:
|
|
2094
|
+
id: d,
|
|
2095
|
+
result: y
|
|
2080
2096
|
}
|
|
2081
2097
|
}, "*");
|
|
2082
|
-
}).catch(console.error) : (
|
|
2098
|
+
}).catch(console.error) : (r = window.parent) == null || r.postMessage({
|
|
2083
2099
|
type: "builder.evaluateResult",
|
|
2084
2100
|
data: {
|
|
2085
|
-
result:
|
|
2086
|
-
id:
|
|
2101
|
+
result: g,
|
|
2102
|
+
id: d
|
|
2087
2103
|
}
|
|
2088
2104
|
}, "*");
|
|
2089
2105
|
break;
|
|
@@ -2091,57 +2107,59 @@ const Yt = (e = {}) => {
|
|
|
2091
2107
|
}
|
|
2092
2108
|
})));
|
|
2093
2109
|
};
|
|
2094
|
-
function
|
|
2095
|
-
var F, q,
|
|
2096
|
-
const t =
|
|
2110
|
+
function en(e) {
|
|
2111
|
+
var F, q, ne, ie, ae, oe, re;
|
|
2112
|
+
const t = X(null), [n, i] = S(() => 0);
|
|
2097
2113
|
S(() => !0);
|
|
2098
|
-
function a(
|
|
2099
|
-
var
|
|
2114
|
+
function a(u) {
|
|
2115
|
+
var b, x;
|
|
2100
2116
|
const f = {
|
|
2101
2117
|
...e.builderContextSignal.rootState,
|
|
2102
|
-
...
|
|
2118
|
+
...u
|
|
2103
2119
|
};
|
|
2104
|
-
e.builderContextSignal.rootSetState ? (x = (
|
|
2120
|
+
e.builderContextSignal.rootSetState ? (x = (b = e.builderContextSignal).rootSetState) == null || x.call(b, f) : e.setBuilderContextSignal((p) => ({
|
|
2105
2121
|
...p,
|
|
2106
2122
|
rootState: f
|
|
2107
2123
|
}));
|
|
2108
2124
|
}
|
|
2109
|
-
function
|
|
2110
|
-
var
|
|
2125
|
+
function c(u) {
|
|
2126
|
+
var b, x, p, T, j;
|
|
2111
2127
|
const f = {
|
|
2112
2128
|
...e.builderContextSignal.content,
|
|
2113
|
-
...
|
|
2129
|
+
...u,
|
|
2114
2130
|
data: {
|
|
2115
|
-
...(
|
|
2116
|
-
...
|
|
2131
|
+
...(b = e.builderContextSignal.content) == null ? void 0 : b.data,
|
|
2132
|
+
...u == null ? void 0 : u.data
|
|
2117
2133
|
},
|
|
2118
2134
|
meta: {
|
|
2119
2135
|
...(x = e.builderContextSignal.content) == null ? void 0 : x.meta,
|
|
2120
|
-
...
|
|
2121
|
-
breakpoints: ((p =
|
|
2136
|
+
...u == null ? void 0 : u.meta,
|
|
2137
|
+
breakpoints: ((p = u == null ? void 0 : u.meta) == null ? void 0 : p.breakpoints) || ((j = (T = e.builderContextSignal.content) == null ? void 0 : T.meta) == null ? void 0 : j.breakpoints)
|
|
2122
2138
|
}
|
|
2123
2139
|
};
|
|
2124
|
-
e.setBuilderContextSignal((
|
|
2125
|
-
|
|
2140
|
+
e.setBuilderContextSignal((Ve) => ({
|
|
2141
|
+
...Ve,
|
|
2126
2142
|
content: f
|
|
2127
2143
|
}));
|
|
2128
2144
|
}
|
|
2129
2145
|
S(() => 0);
|
|
2130
|
-
const [r,
|
|
2146
|
+
const [r, l] = S(
|
|
2131
2147
|
() => !1
|
|
2132
|
-
), [
|
|
2148
|
+
), [s, d] = S(
|
|
2133
2149
|
() => e.contentWrapper || "div"
|
|
2134
2150
|
);
|
|
2135
|
-
function u
|
|
2136
|
-
var
|
|
2137
|
-
|
|
2151
|
+
function m(u) {
|
|
2152
|
+
var b;
|
|
2153
|
+
if (!We(e.trustedHosts, u))
|
|
2154
|
+
return;
|
|
2155
|
+
const { data: f } = u;
|
|
2138
2156
|
if (f)
|
|
2139
2157
|
switch (f.type) {
|
|
2140
2158
|
case "builder.configureSdk": {
|
|
2141
2159
|
const x = f.data, { breakpoints: p, contentId: T } = x;
|
|
2142
|
-
if (!T || T !== ((
|
|
2160
|
+
if (!T || T !== ((b = e.builderContextSignal.content) == null ? void 0 : b.id))
|
|
2143
2161
|
return;
|
|
2144
|
-
p &&
|
|
2162
|
+
p && c({
|
|
2145
2163
|
meta: {
|
|
2146
2164
|
breakpoints: p
|
|
2147
2165
|
}
|
|
@@ -2150,44 +2168,44 @@ function Qt(e) {
|
|
|
2150
2168
|
}
|
|
2151
2169
|
case "builder.contentUpdate": {
|
|
2152
2170
|
const x = f.data, p = x.key || x.alias || x.entry || x.modelName, T = x.data;
|
|
2153
|
-
p === e.model && (
|
|
2171
|
+
p === e.model && (c(T), i(n + 1));
|
|
2154
2172
|
break;
|
|
2155
2173
|
}
|
|
2156
2174
|
}
|
|
2157
2175
|
}
|
|
2158
|
-
function
|
|
2159
|
-
var f,
|
|
2160
|
-
const
|
|
2161
|
-
|
|
2162
|
-
code:
|
|
2176
|
+
function g() {
|
|
2177
|
+
var f, b;
|
|
2178
|
+
const u = (b = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : b.jsCode;
|
|
2179
|
+
u && _({
|
|
2180
|
+
code: u,
|
|
2163
2181
|
context: e.context || {},
|
|
2164
2182
|
localState: void 0,
|
|
2165
2183
|
rootState: e.builderContextSignal.rootState,
|
|
2166
2184
|
rootSetState: e.builderContextSignal.rootSetState
|
|
2167
2185
|
});
|
|
2168
2186
|
}
|
|
2169
|
-
const [v, y] = S(() => ({})), [
|
|
2170
|
-
function R(
|
|
2171
|
-
var f,
|
|
2187
|
+
const [v, y] = S(() => ({})), [k, C] = S(() => !1);
|
|
2188
|
+
function R(u) {
|
|
2189
|
+
var f, b;
|
|
2172
2190
|
if (e.builderContextSignal.content) {
|
|
2173
|
-
const x = (f = e.builderContextSignal.content) == null ? void 0 : f.testVariationId, p = (
|
|
2174
|
-
|
|
2191
|
+
const x = (f = e.builderContextSignal.content) == null ? void 0 : f.testVariationId, p = (b = e.builderContextSignal.content) == null ? void 0 : b.id;
|
|
2192
|
+
le({
|
|
2175
2193
|
type: "click",
|
|
2176
2194
|
canTrack: D(e.canTrack),
|
|
2177
2195
|
contentId: p,
|
|
2178
2196
|
apiKey: e.apiKey,
|
|
2179
2197
|
variationId: x !== p ? x : void 0,
|
|
2180
|
-
...
|
|
2181
|
-
unique: !
|
|
2198
|
+
...Gt(u),
|
|
2199
|
+
unique: !k
|
|
2182
2200
|
});
|
|
2183
2201
|
}
|
|
2184
|
-
|
|
2202
|
+
k || C(!0);
|
|
2185
2203
|
}
|
|
2186
|
-
function
|
|
2187
|
-
return
|
|
2204
|
+
function P(u) {
|
|
2205
|
+
return u.replace(
|
|
2188
2206
|
/{{([^}]+)}}/g,
|
|
2189
|
-
(f,
|
|
2190
|
-
code:
|
|
2207
|
+
(f, b) => _({
|
|
2208
|
+
code: b,
|
|
2191
2209
|
context: e.context || {},
|
|
2192
2210
|
localState: void 0,
|
|
2193
2211
|
rootState: e.builderContextSignal.rootState,
|
|
@@ -2195,24 +2213,24 @@ function Qt(e) {
|
|
|
2195
2213
|
})
|
|
2196
2214
|
);
|
|
2197
2215
|
}
|
|
2198
|
-
function w({ url:
|
|
2199
|
-
|
|
2216
|
+
function w({ url: u, key: f }) {
|
|
2217
|
+
Le(u).then((b) => b.json()).then((b) => {
|
|
2200
2218
|
var p, T;
|
|
2201
2219
|
const x = {
|
|
2202
2220
|
...e.builderContextSignal.rootState,
|
|
2203
|
-
[f]:
|
|
2221
|
+
[f]: b
|
|
2204
2222
|
};
|
|
2205
2223
|
(T = (p = e.builderContextSignal).rootSetState) == null || T.call(p, x), v[f] = !0;
|
|
2206
|
-
}).catch((
|
|
2207
|
-
console.error("error fetching dynamic data",
|
|
2224
|
+
}).catch((b) => {
|
|
2225
|
+
console.error("error fetching dynamic data", u, b);
|
|
2208
2226
|
});
|
|
2209
2227
|
}
|
|
2210
2228
|
function I() {
|
|
2211
|
-
var f,
|
|
2212
|
-
const
|
|
2213
|
-
Object.entries(
|
|
2229
|
+
var f, b, x;
|
|
2230
|
+
const u = (x = (b = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : b.httpRequests) != null ? x : {};
|
|
2231
|
+
Object.entries(u).forEach(([p, T]) => {
|
|
2214
2232
|
if (T && (!v[p] || V())) {
|
|
2215
|
-
const j =
|
|
2233
|
+
const j = P(T);
|
|
2216
2234
|
w({
|
|
2217
2235
|
url: j,
|
|
2218
2236
|
key: p
|
|
@@ -2220,13 +2238,13 @@ function Qt(e) {
|
|
|
2220
2238
|
}
|
|
2221
2239
|
});
|
|
2222
2240
|
}
|
|
2223
|
-
function
|
|
2241
|
+
function W() {
|
|
2224
2242
|
V() && window.dispatchEvent(
|
|
2225
2243
|
new CustomEvent(
|
|
2226
2244
|
"builder:component:stateChange",
|
|
2227
2245
|
{
|
|
2228
2246
|
detail: {
|
|
2229
|
-
state:
|
|
2247
|
+
state: Z(e.builderContextSignal.rootState),
|
|
2230
2248
|
ref: {
|
|
2231
2249
|
name: e.model
|
|
2232
2250
|
}
|
|
@@ -2235,8 +2253,8 @@ function Qt(e) {
|
|
|
2235
2253
|
)
|
|
2236
2254
|
);
|
|
2237
2255
|
}
|
|
2238
|
-
function A(
|
|
2239
|
-
i(n + 1), window.addEventListener("message",
|
|
2256
|
+
function A(u) {
|
|
2257
|
+
i(n + 1), window.addEventListener("message", m), Xt(), Zt({
|
|
2240
2258
|
...e.locale ? {
|
|
2241
2259
|
locale: e.locale
|
|
2242
2260
|
} : {},
|
|
@@ -2245,33 +2263,36 @@ function Qt(e) {
|
|
|
2245
2263
|
} : {},
|
|
2246
2264
|
...e.enrich ? {
|
|
2247
2265
|
enrich: e.enrich
|
|
2266
|
+
} : {},
|
|
2267
|
+
...e.trustedHosts ? {
|
|
2268
|
+
trustedHosts: e.trustedHosts
|
|
2248
2269
|
} : {}
|
|
2249
2270
|
}), Object.values(
|
|
2250
2271
|
e.builderContextSignal.componentInfos
|
|
2251
2272
|
).forEach((f) => {
|
|
2252
2273
|
var x;
|
|
2253
|
-
const
|
|
2254
|
-
(x = window.parent) == null || x.postMessage(
|
|
2274
|
+
const b = _e(f);
|
|
2275
|
+
(x = window.parent) == null || x.postMessage(b, "*");
|
|
2255
2276
|
}), window.addEventListener(
|
|
2256
2277
|
"builder:component:stateChangeListenerActivated",
|
|
2257
|
-
|
|
2278
|
+
W
|
|
2258
2279
|
);
|
|
2259
2280
|
}
|
|
2260
|
-
function N(
|
|
2261
|
-
const f = new URL(location.href).searchParams,
|
|
2262
|
-
`builder.preview.${
|
|
2281
|
+
function N(u) {
|
|
2282
|
+
const f = new URL(location.href).searchParams, b = f.get("builder.preview"), x = f.get(
|
|
2283
|
+
`builder.preview.${b}`
|
|
2263
2284
|
), p = f.get("apiKey") || f.get("builder.space");
|
|
2264
|
-
|
|
2285
|
+
b === e.model && p === e.apiKey && (!e.content || x === e.content.id) && ke({
|
|
2265
2286
|
model: e.model,
|
|
2266
2287
|
apiKey: e.apiKey,
|
|
2267
2288
|
apiVersion: e.builderContextSignal.apiVersion
|
|
2268
2289
|
}).then((T) => {
|
|
2269
|
-
T &&
|
|
2290
|
+
T && c(T);
|
|
2270
2291
|
});
|
|
2271
2292
|
}
|
|
2272
2293
|
return E(() => {
|
|
2273
|
-
var
|
|
2274
|
-
return (
|
|
2294
|
+
var u;
|
|
2295
|
+
return (u = t.current) == null || u.addEventListener(
|
|
2275
2296
|
"initeditingbldr",
|
|
2276
2297
|
A
|
|
2277
2298
|
), () => {
|
|
@@ -2282,8 +2303,8 @@ function Qt(e) {
|
|
|
2282
2303
|
);
|
|
2283
2304
|
};
|
|
2284
2305
|
}, []), E(() => {
|
|
2285
|
-
var
|
|
2286
|
-
return (
|
|
2306
|
+
var u;
|
|
2307
|
+
return (u = t.current) == null || u.addEventListener(
|
|
2287
2308
|
"initpreviewingbldr",
|
|
2288
2309
|
N
|
|
2289
2310
|
), () => {
|
|
@@ -2294,11 +2315,11 @@ function Qt(e) {
|
|
|
2294
2315
|
);
|
|
2295
2316
|
};
|
|
2296
2317
|
}, []), E(() => {
|
|
2297
|
-
var
|
|
2318
|
+
var u, f;
|
|
2298
2319
|
if ($()) {
|
|
2299
2320
|
if (V() && t.current && t.current.dispatchEvent(new CustomEvent("initeditingbldr")), e.builderContextSignal.content && D(e.canTrack)) {
|
|
2300
|
-
const x = (
|
|
2301
|
-
|
|
2321
|
+
const x = (u = e.builderContextSignal.content) == null ? void 0 : u.testVariationId, p = (f = e.builderContextSignal.content) == null ? void 0 : f.id, T = e.apiKey;
|
|
2322
|
+
le({
|
|
2302
2323
|
type: "impression",
|
|
2303
2324
|
canTrack: !0,
|
|
2304
2325
|
contentId: p,
|
|
@@ -2306,24 +2327,24 @@ function Qt(e) {
|
|
|
2306
2327
|
variationId: x !== p ? x : void 0
|
|
2307
2328
|
});
|
|
2308
2329
|
}
|
|
2309
|
-
|
|
2330
|
+
Fe() && t.current && t.current.dispatchEvent(new CustomEvent("initpreviewingbldr"));
|
|
2310
2331
|
}
|
|
2311
2332
|
}, []), E(() => {
|
|
2312
2333
|
e.apiKey || U.error(
|
|
2313
2334
|
"No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."
|
|
2314
|
-
),
|
|
2335
|
+
), g(), I(), W();
|
|
2315
2336
|
}, []), E(() => {
|
|
2316
|
-
e.content &&
|
|
2337
|
+
e.content && c(e.content);
|
|
2317
2338
|
}, [e.content]), E(() => {
|
|
2318
2339
|
}, [r]), E(() => {
|
|
2319
|
-
|
|
2340
|
+
g();
|
|
2320
2341
|
}, [
|
|
2321
2342
|
(q = (F = e.builderContextSignal.content) == null ? void 0 : F.data) == null ? void 0 : q.jsCode,
|
|
2322
2343
|
e.builderContextSignal.rootState
|
|
2323
2344
|
]), E(() => {
|
|
2324
2345
|
I();
|
|
2325
|
-
}, [(
|
|
2326
|
-
|
|
2346
|
+
}, [(ie = (ne = e.builderContextSignal.content) == null ? void 0 : ne.data) == null ? void 0 : ie.httpRequests]), E(() => {
|
|
2347
|
+
W();
|
|
2327
2348
|
}, [e.builderContextSignal.rootState]), E(() => {
|
|
2328
2349
|
e.data && a(e.data);
|
|
2329
2350
|
}, [e.data]), E(() => {
|
|
@@ -2331,31 +2352,31 @@ function Qt(e) {
|
|
|
2331
2352
|
locale: e.locale
|
|
2332
2353
|
});
|
|
2333
2354
|
}, [e.locale]), E(() => () => {
|
|
2334
|
-
$() && (window.removeEventListener("message",
|
|
2355
|
+
$() && (window.removeEventListener("message", m), window.removeEventListener(
|
|
2335
2356
|
"builder:component:stateChangeListenerActivated",
|
|
2336
|
-
|
|
2357
|
+
W
|
|
2337
2358
|
));
|
|
2338
|
-
}, []), /* @__PURE__ */
|
|
2339
|
-
|
|
2359
|
+
}, []), /* @__PURE__ */ o(ee.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ pe(
|
|
2360
|
+
s,
|
|
2340
2361
|
{
|
|
2341
2362
|
key: n,
|
|
2342
2363
|
ref: t,
|
|
2343
|
-
onClick: (
|
|
2344
|
-
"builder-content-id": (
|
|
2364
|
+
onClick: (u) => R(u),
|
|
2365
|
+
"builder-content-id": (ae = e.builderContextSignal.content) == null ? void 0 : ae.id,
|
|
2345
2366
|
"builder-model": e.model,
|
|
2346
2367
|
...e.showContent ? {} : {
|
|
2347
2368
|
hidden: !0,
|
|
2348
2369
|
"aria-hidden": !0
|
|
2349
2370
|
},
|
|
2350
2371
|
...e.contentWrapperProps,
|
|
2351
|
-
className: `variant-${((
|
|
2372
|
+
className: `variant-${((oe = e.content) == null ? void 0 : oe.testVariationId) || ((re = e.content) == null ? void 0 : re.id)}`
|
|
2352
2373
|
},
|
|
2353
2374
|
e.children
|
|
2354
2375
|
) }) : null });
|
|
2355
2376
|
}
|
|
2356
|
-
const
|
|
2357
|
-
var
|
|
2358
|
-
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (r = e.fileUrl) != null ? r : (
|
|
2377
|
+
const tn = (e) => {
|
|
2378
|
+
var c, r;
|
|
2379
|
+
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (r = e.fileUrl) != null ? r : (c = e == null ? void 0 : e.files) == null ? void 0 : c.regular;
|
|
2359
2380
|
let a = "";
|
|
2360
2381
|
if (i && t && n && (a += `
|
|
2361
2382
|
@font-face {
|
|
@@ -2365,37 +2386,37 @@ font-display: fallback;
|
|
|
2365
2386
|
font-weight: 400;
|
|
2366
2387
|
}
|
|
2367
2388
|
`.trim()), e.files)
|
|
2368
|
-
for (const
|
|
2369
|
-
if (!(String(Number(
|
|
2389
|
+
for (const l in e.files) {
|
|
2390
|
+
if (!(String(Number(l)) === l))
|
|
2370
2391
|
continue;
|
|
2371
|
-
const d = e.files[
|
|
2392
|
+
const d = e.files[l];
|
|
2372
2393
|
d && d !== i && (a += `
|
|
2373
2394
|
@font-face {
|
|
2374
2395
|
font-family: "${t}";
|
|
2375
2396
|
src: url('${d}') format('woff2');
|
|
2376
2397
|
font-display: fallback;
|
|
2377
|
-
font-weight: ${
|
|
2398
|
+
font-weight: ${l};
|
|
2378
2399
|
}
|
|
2379
2400
|
`.trim());
|
|
2380
2401
|
}
|
|
2381
2402
|
return a;
|
|
2382
|
-
},
|
|
2403
|
+
}, nn = ({
|
|
2383
2404
|
customFonts: e
|
|
2384
2405
|
}) => {
|
|
2385
2406
|
var t;
|
|
2386
|
-
return ((t = e == null ? void 0 : e.map((n) =>
|
|
2387
|
-
},
|
|
2407
|
+
return ((t = e == null ? void 0 : e.map((n) => tn(n))) == null ? void 0 : t.join(" ")) || "";
|
|
2408
|
+
}, an = ({
|
|
2388
2409
|
cssCode: e,
|
|
2389
2410
|
contentId: t
|
|
2390
2411
|
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "";
|
|
2391
|
-
function
|
|
2412
|
+
function on(e) {
|
|
2392
2413
|
const [t, n] = S(
|
|
2393
2414
|
() => `
|
|
2394
|
-
${
|
|
2415
|
+
${an({
|
|
2395
2416
|
cssCode: e.cssCode,
|
|
2396
2417
|
contentId: e.contentId
|
|
2397
2418
|
})}
|
|
2398
|
-
${
|
|
2419
|
+
${nn({
|
|
2399
2420
|
customFonts: e.customFonts
|
|
2400
2421
|
})}
|
|
2401
2422
|
|
|
@@ -2413,17 +2434,17 @@ ${Jt({
|
|
|
2413
2434
|
}
|
|
2414
2435
|
`.trim()
|
|
2415
2436
|
);
|
|
2416
|
-
return /* @__PURE__ */
|
|
2437
|
+
return /* @__PURE__ */ o(O, { styles: t });
|
|
2417
2438
|
}
|
|
2418
|
-
const
|
|
2439
|
+
const rn = ({
|
|
2419
2440
|
content: e,
|
|
2420
2441
|
data: t,
|
|
2421
2442
|
locale: n
|
|
2422
2443
|
}) => {
|
|
2423
|
-
var
|
|
2424
|
-
const i = {}, a = ((
|
|
2425
|
-
return (
|
|
2426
|
-
|
|
2444
|
+
var c, r, l;
|
|
2445
|
+
const i = {}, a = ((c = e == null ? void 0 : e.data) == null ? void 0 : c.state) || {};
|
|
2446
|
+
return (l = (r = e == null ? void 0 : e.data) == null ? void 0 : r.inputs) == null || l.forEach((s) => {
|
|
2447
|
+
s.name && s.defaultValue !== void 0 && (i[s.name] = s.defaultValue);
|
|
2427
2448
|
}), {
|
|
2428
2449
|
...i,
|
|
2429
2450
|
...a,
|
|
@@ -2432,7 +2453,7 @@ const en = ({
|
|
|
2432
2453
|
locale: n
|
|
2433
2454
|
} : {}
|
|
2434
2455
|
};
|
|
2435
|
-
},
|
|
2456
|
+
}, cn = ({
|
|
2436
2457
|
content: e,
|
|
2437
2458
|
data: t
|
|
2438
2459
|
}) => e ? {
|
|
@@ -2443,52 +2464,52 @@ const en = ({
|
|
|
2443
2464
|
},
|
|
2444
2465
|
meta: e == null ? void 0 : e.meta
|
|
2445
2466
|
} : void 0;
|
|
2446
|
-
function
|
|
2447
|
-
var
|
|
2467
|
+
function Se(e) {
|
|
2468
|
+
var s, d, m, g, v, y, k;
|
|
2448
2469
|
const [t, n] = S(
|
|
2449
2470
|
() => {
|
|
2450
|
-
var
|
|
2451
|
-
return
|
|
2471
|
+
var C, R;
|
|
2472
|
+
return zt({
|
|
2452
2473
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2453
|
-
variationId: (
|
|
2474
|
+
variationId: (C = e.content) == null ? void 0 : C.testVariationId,
|
|
2454
2475
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2455
2476
|
contentId: (R = e.content) == null ? void 0 : R.id
|
|
2456
2477
|
});
|
|
2457
2478
|
}
|
|
2458
2479
|
);
|
|
2459
|
-
function i(
|
|
2460
|
-
|
|
2480
|
+
function i(C) {
|
|
2481
|
+
l((R) => ({
|
|
2461
2482
|
...R,
|
|
2462
|
-
rootState:
|
|
2483
|
+
rootState: C
|
|
2463
2484
|
}));
|
|
2464
2485
|
}
|
|
2465
|
-
const [a,
|
|
2486
|
+
const [a, c] = S(
|
|
2466
2487
|
() => [
|
|
2467
|
-
...
|
|
2488
|
+
...ge(),
|
|
2468
2489
|
// While this `components` object is deprecated, we must maintain support for it.
|
|
2469
2490
|
// Since users are able to override our default components, we need to make sure that we do not break such
|
|
2470
2491
|
// existing usage.
|
|
2471
2492
|
// This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
|
|
2472
2493
|
// which is the new standard way of providing custom components, and must therefore take precedence.
|
|
2473
|
-
...
|
|
2494
|
+
...se,
|
|
2474
2495
|
...e.customComponents || []
|
|
2475
2496
|
].reduce(
|
|
2476
|
-
(
|
|
2477
|
-
...
|
|
2478
|
-
[
|
|
2497
|
+
(C, { component: R, ...P }) => ({
|
|
2498
|
+
...C,
|
|
2499
|
+
[P.name]: {
|
|
2479
2500
|
component: R,
|
|
2480
|
-
...
|
|
2501
|
+
...de(P)
|
|
2481
2502
|
}
|
|
2482
2503
|
}),
|
|
2483
2504
|
{}
|
|
2484
2505
|
)
|
|
2485
|
-
), [r,
|
|
2486
|
-
content:
|
|
2506
|
+
), [r, l] = S(() => ({
|
|
2507
|
+
content: cn({
|
|
2487
2508
|
content: e.content,
|
|
2488
2509
|
data: e.data
|
|
2489
2510
|
}),
|
|
2490
2511
|
localState: void 0,
|
|
2491
|
-
rootState:
|
|
2512
|
+
rootState: rn({
|
|
2492
2513
|
content: e.content,
|
|
2493
2514
|
data: e.data,
|
|
2494
2515
|
locale: e.locale
|
|
@@ -2498,18 +2519,18 @@ function ke(e) {
|
|
|
2498
2519
|
apiKey: e.apiKey,
|
|
2499
2520
|
apiVersion: e.apiVersion,
|
|
2500
2521
|
componentInfos: [
|
|
2501
|
-
...
|
|
2522
|
+
...ge(),
|
|
2502
2523
|
// While this `components` object is deprecated, we must maintain support for it.
|
|
2503
2524
|
// Since users are able to override our default components, we need to make sure that we do not break such
|
|
2504
2525
|
// existing usage.
|
|
2505
2526
|
// This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
|
|
2506
2527
|
// which is the new standard way of providing custom components, and must therefore take precedence.
|
|
2507
|
-
...
|
|
2528
|
+
...se,
|
|
2508
2529
|
...e.customComponents || []
|
|
2509
2530
|
].reduce(
|
|
2510
|
-
(
|
|
2511
|
-
...
|
|
2512
|
-
[
|
|
2531
|
+
(C, { component: R, ...P }) => ({
|
|
2532
|
+
...C,
|
|
2533
|
+
[P.name]: de(P)
|
|
2513
2534
|
}),
|
|
2514
2535
|
{}
|
|
2515
2536
|
),
|
|
@@ -2517,14 +2538,14 @@ function ke(e) {
|
|
|
2517
2538
|
BlocksWrapper: e.blocksWrapper || "div",
|
|
2518
2539
|
BlocksWrapperProps: e.blocksWrapperProps || {}
|
|
2519
2540
|
}));
|
|
2520
|
-
return /* @__PURE__ */
|
|
2521
|
-
|
|
2541
|
+
return /* @__PURE__ */ o(
|
|
2542
|
+
Ce.Provider,
|
|
2522
2543
|
{
|
|
2523
2544
|
value: {
|
|
2524
2545
|
registeredComponents: a
|
|
2525
2546
|
},
|
|
2526
|
-
children: /* @__PURE__ */
|
|
2527
|
-
|
|
2547
|
+
children: /* @__PURE__ */ B(
|
|
2548
|
+
en,
|
|
2528
2549
|
{
|
|
2529
2550
|
content: e.content,
|
|
2530
2551
|
data: e.data,
|
|
@@ -2539,21 +2560,22 @@ function ke(e) {
|
|
|
2539
2560
|
builderContextSignal: r,
|
|
2540
2561
|
contentWrapper: e.contentWrapper,
|
|
2541
2562
|
contentWrapperProps: e.contentWrapperProps,
|
|
2542
|
-
|
|
2563
|
+
trustedHosts: e.trustedHosts,
|
|
2564
|
+
setBuilderContextSignal: l,
|
|
2543
2565
|
children: [
|
|
2544
|
-
e.isSsrAbTest ? /* @__PURE__ */
|
|
2545
|
-
/* @__PURE__ */
|
|
2546
|
-
|
|
2566
|
+
e.isSsrAbTest ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(J, { scriptStr: t }) }) : null,
|
|
2567
|
+
/* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(
|
|
2568
|
+
on,
|
|
2547
2569
|
{
|
|
2548
|
-
contentId: (
|
|
2549
|
-
cssCode: (
|
|
2550
|
-
customFonts: (v = (
|
|
2570
|
+
contentId: (s = r.content) == null ? void 0 : s.id,
|
|
2571
|
+
cssCode: (m = (d = r.content) == null ? void 0 : d.data) == null ? void 0 : m.cssCode,
|
|
2572
|
+
customFonts: (v = (g = r.content) == null ? void 0 : g.data) == null ? void 0 : v.customFonts
|
|
2551
2573
|
}
|
|
2552
2574
|
) }),
|
|
2553
|
-
/* @__PURE__ */
|
|
2554
|
-
|
|
2575
|
+
/* @__PURE__ */ o(
|
|
2576
|
+
z,
|
|
2555
2577
|
{
|
|
2556
|
-
blocks: (
|
|
2578
|
+
blocks: (k = (y = r.content) == null ? void 0 : y.data) == null ? void 0 : k.blocks,
|
|
2557
2579
|
context: r,
|
|
2558
2580
|
registeredComponents: a
|
|
2559
2581
|
}
|
|
@@ -2564,53 +2586,53 @@ function ke(e) {
|
|
|
2564
2586
|
}
|
|
2565
2587
|
);
|
|
2566
2588
|
}
|
|
2567
|
-
function
|
|
2568
|
-
var r,
|
|
2589
|
+
function Ae(e) {
|
|
2590
|
+
var r, l;
|
|
2569
2591
|
const [t, n] = S(
|
|
2570
|
-
() =>
|
|
2592
|
+
() => Dt({
|
|
2571
2593
|
canTrack: D(e.canTrack),
|
|
2572
2594
|
content: e.content
|
|
2573
2595
|
})
|
|
2574
2596
|
);
|
|
2575
2597
|
function i() {
|
|
2576
|
-
var
|
|
2577
|
-
return
|
|
2598
|
+
var s;
|
|
2599
|
+
return Kt(
|
|
2578
2600
|
M(e.content).map((d) => ({
|
|
2579
2601
|
id: d.testVariationId,
|
|
2580
2602
|
testRatio: d.testRatio
|
|
2581
2603
|
})),
|
|
2582
|
-
((
|
|
2604
|
+
((s = e.content) == null ? void 0 : s.id) || ""
|
|
2583
2605
|
);
|
|
2584
2606
|
}
|
|
2585
2607
|
function a() {
|
|
2586
|
-
return M(e.content).map((
|
|
2608
|
+
return M(e.content).map((s) => `.variant-${s.testVariationId} { display: none; } `).join("");
|
|
2587
2609
|
}
|
|
2588
|
-
function
|
|
2589
|
-
var
|
|
2610
|
+
function c() {
|
|
2611
|
+
var s;
|
|
2590
2612
|
return t ? {
|
|
2591
2613
|
...e.content,
|
|
2592
|
-
testVariationId: (
|
|
2593
|
-
} :
|
|
2614
|
+
testVariationId: (s = e.content) == null ? void 0 : s.id
|
|
2615
|
+
} : je({
|
|
2594
2616
|
item: e.content,
|
|
2595
2617
|
canTrack: D(e.canTrack)
|
|
2596
2618
|
});
|
|
2597
2619
|
}
|
|
2598
2620
|
return E(() => {
|
|
2599
|
-
}, []), /* @__PURE__ */
|
|
2600
|
-
!e.__isNestedRender && L !== "reactNative" ? /* @__PURE__ */
|
|
2601
|
-
t ? /* @__PURE__ */
|
|
2602
|
-
/* @__PURE__ */
|
|
2603
|
-
|
|
2621
|
+
}, []), /* @__PURE__ */ B(h, { children: [
|
|
2622
|
+
!e.__isNestedRender && L !== "reactNative" ? /* @__PURE__ */ o(h, { children: /* @__PURE__ */ o(J, { scriptStr: Ot() }) }) : null,
|
|
2623
|
+
t ? /* @__PURE__ */ B(h, { children: [
|
|
2624
|
+
/* @__PURE__ */ o(
|
|
2625
|
+
O,
|
|
2604
2626
|
{
|
|
2605
2627
|
id: `variants-styles-${(r = e.content) == null ? void 0 : r.id}`,
|
|
2606
2628
|
styles: a()
|
|
2607
2629
|
}
|
|
2608
2630
|
),
|
|
2609
|
-
/* @__PURE__ */
|
|
2610
|
-
(
|
|
2611
|
-
|
|
2631
|
+
/* @__PURE__ */ o(J, { scriptStr: i() }),
|
|
2632
|
+
(l = M(e.content)) == null ? void 0 : l.map((s) => /* @__PURE__ */ o(
|
|
2633
|
+
Se,
|
|
2612
2634
|
{
|
|
2613
|
-
content:
|
|
2635
|
+
content: s,
|
|
2614
2636
|
showContent: !1,
|
|
2615
2637
|
model: e.model,
|
|
2616
2638
|
data: e.data,
|
|
@@ -2626,15 +2648,16 @@ function Ve(e) {
|
|
|
2626
2648
|
blocksWrapper: e.blocksWrapper,
|
|
2627
2649
|
blocksWrapperProps: e.blocksWrapperProps,
|
|
2628
2650
|
contentWrapper: e.contentWrapper,
|
|
2629
|
-
contentWrapperProps: e.contentWrapperProps
|
|
2651
|
+
contentWrapperProps: e.contentWrapperProps,
|
|
2652
|
+
trustedHosts: e.trustedHosts
|
|
2630
2653
|
},
|
|
2631
|
-
|
|
2654
|
+
s.testVariationId
|
|
2632
2655
|
))
|
|
2633
2656
|
] }) : null,
|
|
2634
|
-
/* @__PURE__ */
|
|
2635
|
-
|
|
2657
|
+
/* @__PURE__ */ o(
|
|
2658
|
+
Se,
|
|
2636
2659
|
{
|
|
2637
|
-
content:
|
|
2660
|
+
content: c(),
|
|
2638
2661
|
showContent: !0,
|
|
2639
2662
|
model: e.model,
|
|
2640
2663
|
data: e.data,
|
|
@@ -2650,18 +2673,19 @@ function Ve(e) {
|
|
|
2650
2673
|
blocksWrapper: e.blocksWrapper,
|
|
2651
2674
|
blocksWrapperProps: e.blocksWrapperProps,
|
|
2652
2675
|
contentWrapper: e.contentWrapper,
|
|
2653
|
-
contentWrapperProps: e.contentWrapperProps
|
|
2676
|
+
contentWrapperProps: e.contentWrapperProps,
|
|
2677
|
+
trustedHosts: e.trustedHosts
|
|
2654
2678
|
}
|
|
2655
2679
|
)
|
|
2656
2680
|
] });
|
|
2657
2681
|
}
|
|
2658
|
-
const
|
|
2682
|
+
const ln = async ({
|
|
2659
2683
|
builderContextValue: e,
|
|
2660
2684
|
symbol: t
|
|
2661
2685
|
}) => {
|
|
2662
2686
|
if (t != null && t.model && // This is a hack, we should not need to check for this, but it is needed for Svelte.
|
|
2663
2687
|
(e != null && e.apiKey))
|
|
2664
|
-
return
|
|
2688
|
+
return ke({
|
|
2665
2689
|
model: t.model,
|
|
2666
2690
|
apiKey: e.apiKey,
|
|
2667
2691
|
apiVersion: e.apiVersion,
|
|
@@ -2674,75 +2698,78 @@ const nn = async ({
|
|
|
2674
2698
|
U.error("Could not fetch symbol content: ", n);
|
|
2675
2699
|
});
|
|
2676
2700
|
};
|
|
2677
|
-
function
|
|
2678
|
-
var
|
|
2701
|
+
function sn(e) {
|
|
2702
|
+
var c, r, l, s;
|
|
2679
2703
|
function t() {
|
|
2680
|
-
var
|
|
2704
|
+
var d, m;
|
|
2681
2705
|
return [
|
|
2682
2706
|
e.attributes.className,
|
|
2683
2707
|
"builder-symbol",
|
|
2684
|
-
(
|
|
2685
|
-
(
|
|
2708
|
+
(d = e.symbol) != null && d.inline ? "builder-inline-symbol" : void 0,
|
|
2709
|
+
(m = e.symbol) != null && m.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
|
|
2686
2710
|
].filter(Boolean).join(" ");
|
|
2687
2711
|
}
|
|
2688
2712
|
const [n, i] = S(() => {
|
|
2689
|
-
var
|
|
2690
|
-
return (
|
|
2713
|
+
var d;
|
|
2714
|
+
return (d = e.symbol) == null ? void 0 : d.content;
|
|
2691
2715
|
});
|
|
2692
2716
|
function a() {
|
|
2693
|
-
n ||
|
|
2717
|
+
n || ln({
|
|
2694
2718
|
symbol: e.symbol,
|
|
2695
2719
|
builderContextValue: e.builderContext
|
|
2696
|
-
}).then((
|
|
2697
|
-
|
|
2720
|
+
}).then((d) => {
|
|
2721
|
+
d && i(d);
|
|
2698
2722
|
});
|
|
2699
2723
|
}
|
|
2700
2724
|
return E(() => {
|
|
2701
2725
|
}, []), E(() => {
|
|
2702
2726
|
a();
|
|
2703
|
-
}, [e.symbol]), /* @__PURE__ */
|
|
2704
|
-
|
|
2727
|
+
}, [e.symbol]), /* @__PURE__ */ o("div", { ...e.attributes, className: t(), children: /* @__PURE__ */ o(
|
|
2728
|
+
Ae,
|
|
2705
2729
|
{
|
|
2706
2730
|
__isNestedRender: !0,
|
|
2707
2731
|
apiVersion: e.builderContext.apiVersion,
|
|
2708
2732
|
apiKey: e.builderContext.apiKey,
|
|
2709
|
-
context:
|
|
2733
|
+
context: {
|
|
2734
|
+
...e.builderContext.context,
|
|
2735
|
+
symbolId: (c = e.builderBlock) == null ? void 0 : c.id
|
|
2736
|
+
},
|
|
2710
2737
|
customComponents: Object.values(e.builderComponents),
|
|
2711
2738
|
data: {
|
|
2712
|
-
...(
|
|
2739
|
+
...(r = e.symbol) == null ? void 0 : r.data,
|
|
2713
2740
|
...e.builderContext.localState,
|
|
2714
|
-
...(
|
|
2741
|
+
...(l = n == null ? void 0 : n.data) == null ? void 0 : l.state
|
|
2715
2742
|
},
|
|
2716
2743
|
model: (s = e.symbol) == null ? void 0 : s.model,
|
|
2717
2744
|
content: n
|
|
2718
2745
|
}
|
|
2719
2746
|
) });
|
|
2720
2747
|
}
|
|
2721
|
-
const
|
|
2748
|
+
const fn = z, hn = Ae;
|
|
2722
2749
|
export {
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2750
|
+
z as Blocks,
|
|
2751
|
+
Me as Button,
|
|
2752
|
+
ht as Columns,
|
|
2753
|
+
Ae as Content,
|
|
2754
|
+
gt as Fragment,
|
|
2755
|
+
yt as Image,
|
|
2756
|
+
fn as RenderBlocks,
|
|
2757
|
+
hn as RenderContent,
|
|
2758
|
+
St as Section,
|
|
2759
|
+
sn as Symbol,
|
|
2760
|
+
_t as Text,
|
|
2761
|
+
jt as Video,
|
|
2762
|
+
xn as _processContentResult,
|
|
2763
|
+
_e as createRegisterComponentMessage,
|
|
2764
|
+
yn as fetchBuilderProps,
|
|
2765
|
+
Sn as fetchEntries,
|
|
2766
|
+
ke as fetchOneEntry,
|
|
2767
|
+
vn as getAllContent,
|
|
2768
|
+
pn as getBuilderSearchParams,
|
|
2769
|
+
kn as getContent,
|
|
2743
2770
|
V as isEditing,
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2771
|
+
Fe as isPreviewing,
|
|
2772
|
+
Ne as register,
|
|
2773
|
+
Cn as setEditorSettings,
|
|
2774
|
+
wn as track
|
|
2748
2775
|
};
|