@builder.io/sdk-react 0.7.0 → 0.7.1-1
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 +23 -23
- package/lib/browser/index.mjs +592 -560
- package/lib/browser/{server-entry-f341a184.mjs → server-entry-13b7e1e6.mjs} +200 -185
- package/lib/browser/server-entry-c98db16c.js +2 -0
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/index.cjs +32 -32
- package/lib/edge/index.mjs +1122 -1062
- package/lib/{node/server-entry-f341a184.mjs → edge/server-entry-13b7e1e6.mjs} +200 -185
- package/lib/edge/server-entry-c98db16c.js +2 -0
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/index.cjs +14 -0
- package/lib/index.mjs +10 -0
- package/lib/node/index.cjs +68 -28
- package/lib/node/index.mjs +931 -802
- package/lib/{edge/server-entry-f341a184.mjs → node/server-entry-13b7e1e6.mjs} +200 -185
- package/lib/node/server-entry-c98db16c.js +2 -0
- package/lib/node/server-entry.cjs +1 -1
- package/lib/node/server-entry.mjs +1 -1
- package/package.json +4 -1
- package/types/blocks/image/image.d.ts +1 -1
- package/types/constants/sdk-version.d.ts +1 -1
- package/types/functions/evaluate/choose-eval.d.ts +6 -0
- package/types/functions/evaluate/evaluate.d.ts +1 -5
- package/types/functions/evaluate/helpers.d.ts +7 -1
- package/types/functions/evaluate/node-runtime/index.d.ts +1 -1
- package/types/functions/evaluate/node-runtime/node-runtime.d.ts +2 -0
- package/types/functions/evaluate/node-runtime/safeDynamicRequire.d.ts +13 -0
- package/types/functions/get-content/types.d.ts +94 -3
- package/types/functions/is-node-runtime.d.ts +4 -0
- package/types/node-runtime/index.d.ts +1 -0
- package/types/node-runtime/node-runtime.d.ts +1 -0
- package/types/node-runtime.d.ts +1 -0
- package/lib/browser/server-entry-f668f903.js +0 -2
- package/lib/edge/server-entry-f668f903.js +0 -2
- package/lib/node/server-entry-f668f903.js +0 -2
package/lib/browser/index.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
3
|
-
import { createContext as
|
|
4
|
-
import { j as
|
|
5
|
-
import { _ as
|
|
6
|
-
function
|
|
7
|
-
return /* @__PURE__ */
|
|
8
|
-
e.link ? /* @__PURE__ */
|
|
2
|
+
import { jsxs as $, Fragment as g, jsx as c } from "react/jsx-runtime";
|
|
3
|
+
import { createContext as Se, useState as I, useContext as oe, createElement as ve, useRef as Z, useEffect as P } from "react";
|
|
4
|
+
import { j as ee, i as V, k as F, l as Ae, m as _, n as Y, T as M, r as Be, o as U, p as re, a as Ve, c as Fe, b as pe, q as Ne, u as le, v as ce, w as We } from "./server-entry-13b7e1e6.mjs";
|
|
5
|
+
import { _ as ln, h as cn, f as sn, g as dn, e as un, d as mn, s as fn, t as hn } from "./server-entry-13b7e1e6.mjs";
|
|
6
|
+
function je(e) {
|
|
7
|
+
return /* @__PURE__ */ $(g, { children: [
|
|
8
|
+
e.link ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
|
|
9
9
|
"a",
|
|
10
10
|
{
|
|
11
11
|
role: "button",
|
|
@@ -14,21 +14,21 @@ function Fe(e) {
|
|
|
14
14
|
target: e.openLinkInNewTab ? "_blank" : void 0,
|
|
15
15
|
children: e.text
|
|
16
16
|
}
|
|
17
|
-
) }) : /* @__PURE__ */
|
|
17
|
+
) }) : /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
|
|
18
18
|
"button",
|
|
19
19
|
{
|
|
20
20
|
...e.attributes,
|
|
21
21
|
style: e.attributes.style,
|
|
22
|
-
className: e.attributes.className + " button-
|
|
22
|
+
className: e.attributes.className + " button-35669e6c",
|
|
23
23
|
children: e.text
|
|
24
24
|
}
|
|
25
25
|
) }),
|
|
26
|
-
/* @__PURE__ */
|
|
26
|
+
/* @__PURE__ */ c("style", { children: `.button-35669e6c {
|
|
27
27
|
all: unset;
|
|
28
28
|
}` })
|
|
29
29
|
] });
|
|
30
30
|
}
|
|
31
|
-
const
|
|
31
|
+
const ke = {
|
|
32
32
|
small: {
|
|
33
33
|
min: 320,
|
|
34
34
|
default: 321,
|
|
@@ -44,11 +44,11 @@ const ye = {
|
|
|
44
44
|
default: 991,
|
|
45
45
|
max: 1200
|
|
46
46
|
}
|
|
47
|
-
},
|
|
47
|
+
}, se = (e, t = ke) => `@media (max-width: ${t[e].max}px)`, Ce = ({
|
|
48
48
|
small: e,
|
|
49
49
|
medium: t
|
|
50
50
|
}) => {
|
|
51
|
-
const n =
|
|
51
|
+
const n = ee(ke);
|
|
52
52
|
if (!e || !t)
|
|
53
53
|
return n;
|
|
54
54
|
const i = Math.floor(e / 2);
|
|
@@ -70,7 +70,7 @@ const ye = {
|
|
|
70
70
|
min: o,
|
|
71
71
|
default: o + 1
|
|
72
72
|
}, n;
|
|
73
|
-
},
|
|
73
|
+
}, Me = ({
|
|
74
74
|
builder: e,
|
|
75
75
|
context: t,
|
|
76
76
|
event: n,
|
|
@@ -82,7 +82,14 @@ const ye = {
|
|
|
82
82
|
builder: e,
|
|
83
83
|
context: t,
|
|
84
84
|
event: n
|
|
85
|
-
}),
|
|
85
|
+
}), Le = () => ({
|
|
86
|
+
isEditing: V(),
|
|
87
|
+
isBrowser: F(),
|
|
88
|
+
isServer: !F(),
|
|
89
|
+
getUserAttributes: () => Ae()
|
|
90
|
+
}), _e = (e, {
|
|
91
|
+
isExpression: t = !0
|
|
92
|
+
}) => /* 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, de = ({
|
|
86
93
|
code: e,
|
|
87
94
|
builder: t,
|
|
88
95
|
context: n,
|
|
@@ -91,15 +98,15 @@ const ye = {
|
|
|
91
98
|
rootSetState: o,
|
|
92
99
|
rootState: r
|
|
93
100
|
}) => {
|
|
94
|
-
const d =
|
|
101
|
+
const d = Me({
|
|
95
102
|
builder: t,
|
|
96
103
|
context: n,
|
|
97
104
|
event: i,
|
|
98
|
-
state:
|
|
105
|
+
state: Ue(r, a, o)
|
|
99
106
|
});
|
|
100
|
-
return new Function(...d.map(([
|
|
107
|
+
return new Function(...d.map(([l]) => l), e)(...d.map(([, l]) => l));
|
|
101
108
|
};
|
|
102
|
-
function
|
|
109
|
+
function Ue(e, t, n) {
|
|
103
110
|
if (e === t)
|
|
104
111
|
throw new Error("rootState === localState");
|
|
105
112
|
return new Proxy(e, {
|
|
@@ -111,6 +118,7 @@ function je(e, t, n) {
|
|
|
111
118
|
}
|
|
112
119
|
});
|
|
113
120
|
}
|
|
121
|
+
const Ke = (e) => (F(), de(e));
|
|
114
122
|
function j({
|
|
115
123
|
code: e,
|
|
116
124
|
context: t,
|
|
@@ -121,17 +129,14 @@ function j({
|
|
|
121
129
|
isExpression: r = !0
|
|
122
130
|
}) {
|
|
123
131
|
if (e === "") {
|
|
124
|
-
|
|
132
|
+
_.warn("Skipping evaluation of empty code block.");
|
|
125
133
|
return;
|
|
126
134
|
}
|
|
127
135
|
const d = {
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
}, u = {
|
|
133
|
-
code: /* we disable this for cases where we definitely don't want a return */ r && !(e.includes(";") || e.includes(" return ") || e.trim().startsWith("return ")) ? `return (${e});` : e,
|
|
134
|
-
builder: d,
|
|
136
|
+
code: _e(e, {
|
|
137
|
+
isExpression: r
|
|
138
|
+
}),
|
|
139
|
+
builder: Le(),
|
|
135
140
|
context: t,
|
|
136
141
|
event: o,
|
|
137
142
|
rootSetState: a,
|
|
@@ -139,21 +144,21 @@ function j({
|
|
|
139
144
|
localState: n
|
|
140
145
|
};
|
|
141
146
|
try {
|
|
142
|
-
return
|
|
143
|
-
} catch (
|
|
144
|
-
|
|
147
|
+
return Ke(d);
|
|
148
|
+
} catch (l) {
|
|
149
|
+
_.error("Failed code evaluation: " + l.message, {
|
|
145
150
|
code: e
|
|
146
151
|
});
|
|
147
152
|
return;
|
|
148
153
|
}
|
|
149
154
|
}
|
|
150
|
-
const
|
|
155
|
+
const Oe = (e, t, n) => {
|
|
151
156
|
if (Object(e) !== e)
|
|
152
157
|
return e;
|
|
153
158
|
const i = Array.isArray(t) ? t : t.toString().match(/[^.[\]]+/g);
|
|
154
159
|
return i.slice(0, -1).reduce((a, o, r) => Object(a[o]) === a[o] ? a[o] : a[o] = Math.abs(Number(i[r + 1])) >> 0 === +i[r + 1] ? [] : {}, e)[i[i.length - 1]] = n, e;
|
|
155
160
|
};
|
|
156
|
-
const
|
|
161
|
+
const He = ({
|
|
157
162
|
block: e,
|
|
158
163
|
context: t,
|
|
159
164
|
localState: n,
|
|
@@ -162,7 +167,7 @@ const Le = ({
|
|
|
162
167
|
}) => {
|
|
163
168
|
if (!e.bindings)
|
|
164
169
|
return e;
|
|
165
|
-
const o =
|
|
170
|
+
const o = ee(e), r = {
|
|
166
171
|
...o,
|
|
167
172
|
properties: {
|
|
168
173
|
...o.properties
|
|
@@ -172,14 +177,14 @@ const Le = ({
|
|
|
172
177
|
}
|
|
173
178
|
};
|
|
174
179
|
for (const d in e.bindings) {
|
|
175
|
-
const
|
|
176
|
-
code:
|
|
180
|
+
const l = e.bindings[d], s = j({
|
|
181
|
+
code: l,
|
|
177
182
|
localState: n,
|
|
178
183
|
rootState: i,
|
|
179
184
|
rootSetState: a,
|
|
180
185
|
context: t
|
|
181
186
|
});
|
|
182
|
-
|
|
187
|
+
Oe(r, d, s);
|
|
183
188
|
}
|
|
184
189
|
return r;
|
|
185
190
|
};
|
|
@@ -192,7 +197,7 @@ function K({
|
|
|
192
197
|
rootSetState: o
|
|
193
198
|
}) {
|
|
194
199
|
const r = e;
|
|
195
|
-
return n ?
|
|
200
|
+
return n ? He({
|
|
196
201
|
block: r,
|
|
197
202
|
localState: i,
|
|
198
203
|
rootState: a,
|
|
@@ -200,26 +205,26 @@ function K({
|
|
|
200
205
|
context: t
|
|
201
206
|
}) : r;
|
|
202
207
|
}
|
|
203
|
-
const
|
|
208
|
+
const ze = (e) => e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase(), we = (e) => Object.entries(e).map(([n, i]) => {
|
|
204
209
|
if (typeof i == "string")
|
|
205
|
-
return `${
|
|
206
|
-
}).filter(Y),
|
|
207
|
-
`),
|
|
210
|
+
return `${ze(n)}: ${i};`;
|
|
211
|
+
}).filter(Y), qe = (e) => we(e).join(`
|
|
212
|
+
`), D = ({
|
|
208
213
|
mediaQuery: e,
|
|
209
214
|
className: t,
|
|
210
215
|
styles: n
|
|
211
216
|
}) => {
|
|
212
217
|
const i = `.${t} {
|
|
213
|
-
${
|
|
218
|
+
${qe(n)}
|
|
214
219
|
}`;
|
|
215
220
|
return e ? `${e} {
|
|
216
221
|
${i}
|
|
217
222
|
}` : i;
|
|
218
223
|
};
|
|
219
224
|
function H(e) {
|
|
220
|
-
return /* @__PURE__ */
|
|
225
|
+
return /* @__PURE__ */ c("style", { dangerouslySetInnerHTML: { __html: e.styles }, id: e.id });
|
|
221
226
|
}
|
|
222
|
-
function
|
|
227
|
+
function te(e) {
|
|
223
228
|
function t() {
|
|
224
229
|
const i = K({
|
|
225
230
|
block: e.block,
|
|
@@ -232,7 +237,7 @@ function ee(e) {
|
|
|
232
237
|
return Y(i.hide) ? !i.hide : Y(i.show) ? i.show : !0;
|
|
233
238
|
}
|
|
234
239
|
function n() {
|
|
235
|
-
var
|
|
240
|
+
var b;
|
|
236
241
|
const i = K({
|
|
237
242
|
block: e.block,
|
|
238
243
|
localState: e.context.localState,
|
|
@@ -240,34 +245,34 @@ function ee(e) {
|
|
|
240
245
|
rootSetState: e.context.rootSetState,
|
|
241
246
|
context: e.context.context,
|
|
242
247
|
shouldEvaluateBindings: !0
|
|
243
|
-
}), a = i.responsiveStyles, o = e.context.content, r =
|
|
244
|
-
((
|
|
245
|
-
), d = a == null ? void 0 : a.large,
|
|
248
|
+
}), a = i.responsiveStyles, o = e.context.content, r = Ce(
|
|
249
|
+
((b = o == null ? void 0 : o.meta) == null ? void 0 : b.breakpoints) || {}
|
|
250
|
+
), d = a == null ? void 0 : a.large, l = a == null ? void 0 : a.medium, s = a == null ? void 0 : a.small, u = i.id;
|
|
246
251
|
if (!u)
|
|
247
252
|
return "";
|
|
248
|
-
const
|
|
253
|
+
const h = d ? D({
|
|
249
254
|
className: u,
|
|
250
255
|
styles: d
|
|
251
|
-
}) : "", y =
|
|
256
|
+
}) : "", y = l ? D({
|
|
252
257
|
className: u,
|
|
253
|
-
styles:
|
|
254
|
-
mediaQuery:
|
|
258
|
+
styles: l,
|
|
259
|
+
mediaQuery: se(
|
|
255
260
|
"medium",
|
|
256
261
|
r
|
|
257
262
|
)
|
|
258
|
-
}) : "", k = s ?
|
|
263
|
+
}) : "", k = s ? D({
|
|
259
264
|
className: u,
|
|
260
265
|
styles: s,
|
|
261
|
-
mediaQuery:
|
|
266
|
+
mediaQuery: se(
|
|
262
267
|
"small",
|
|
263
268
|
r
|
|
264
269
|
)
|
|
265
270
|
}) : "";
|
|
266
|
-
return [
|
|
271
|
+
return [h, y, k].join(" ");
|
|
267
272
|
}
|
|
268
|
-
return /* @__PURE__ */
|
|
273
|
+
return /* @__PURE__ */ c(g, { children: n() && t() ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(H, { styles: n() }) }) : null });
|
|
269
274
|
}
|
|
270
|
-
function
|
|
275
|
+
function De(e) {
|
|
271
276
|
var t;
|
|
272
277
|
return {
|
|
273
278
|
...(t = e.component) == null ? void 0 : t.options,
|
|
@@ -278,7 +283,7 @@ function Ke(e) {
|
|
|
278
283
|
builderBlock: e
|
|
279
284
|
};
|
|
280
285
|
}
|
|
281
|
-
const
|
|
286
|
+
const Ge = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"], G = (e) => typeof e == "string" && Ge.includes(e.toLowerCase()), Je = ({
|
|
282
287
|
block: e,
|
|
283
288
|
context: t,
|
|
284
289
|
registeredComponents: n
|
|
@@ -300,7 +305,7 @@ const Oe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
300
305
|
console.warn(`
|
|
301
306
|
Could not find a registered component named "${i}".
|
|
302
307
|
If you registered it, is the file that registered it imported by the file that needs to render it?`);
|
|
303
|
-
},
|
|
308
|
+
}, Ye = ({
|
|
304
309
|
block: e,
|
|
305
310
|
context: t
|
|
306
311
|
}) => {
|
|
@@ -320,20 +325,20 @@ const Oe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
320
325
|
if (!Array.isArray(a))
|
|
321
326
|
return;
|
|
322
327
|
const o = n.collection.split(".").pop(), r = n.itemName || (o ? o + "Item" : "item");
|
|
323
|
-
return a.map((
|
|
328
|
+
return a.map((l, s) => ({
|
|
324
329
|
context: {
|
|
325
330
|
...t,
|
|
326
331
|
localState: {
|
|
327
332
|
...t.localState,
|
|
328
333
|
$index: s,
|
|
329
|
-
$item:
|
|
330
|
-
[r]:
|
|
334
|
+
$item: l,
|
|
335
|
+
[r]: l,
|
|
331
336
|
[`$${r}Index`]: s
|
|
332
337
|
}
|
|
333
338
|
},
|
|
334
339
|
block: i
|
|
335
340
|
}));
|
|
336
|
-
},
|
|
341
|
+
}, ne = Se({
|
|
337
342
|
content: null,
|
|
338
343
|
context: {},
|
|
339
344
|
localState: void 0,
|
|
@@ -345,9 +350,9 @@ const Oe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
345
350
|
componentInfos: {},
|
|
346
351
|
inheritedStyles: {}
|
|
347
352
|
});
|
|
348
|
-
function
|
|
353
|
+
function Qe(e) {
|
|
349
354
|
const [t, n] = I(() => e.repeatContext);
|
|
350
|
-
return /* @__PURE__ */
|
|
355
|
+
return /* @__PURE__ */ c(ne.Provider, { value: t, children: /* @__PURE__ */ c(
|
|
351
356
|
z,
|
|
352
357
|
{
|
|
353
358
|
block: e.block,
|
|
@@ -356,10 +361,10 @@ function qe(e) {
|
|
|
356
361
|
}
|
|
357
362
|
) });
|
|
358
363
|
}
|
|
359
|
-
function
|
|
364
|
+
function Xe(e) {
|
|
360
365
|
return e.charAt(0).toUpperCase() + e.slice(1);
|
|
361
366
|
}
|
|
362
|
-
const
|
|
367
|
+
const Ze = (e) => `on${Xe(e)}`, et = (e, t) => (n) => j({
|
|
363
368
|
code: e,
|
|
364
369
|
context: t.context,
|
|
365
370
|
localState: t.localState,
|
|
@@ -368,13 +373,13 @@ const Je = (e) => `on${De(e)}`, Ye = (e, t) => (n) => j({
|
|
|
368
373
|
event: n,
|
|
369
374
|
isExpression: !1
|
|
370
375
|
});
|
|
371
|
-
function
|
|
376
|
+
function Q(e) {
|
|
372
377
|
const t = {}, n = e.block.actions ?? {};
|
|
373
378
|
for (const i in n) {
|
|
374
379
|
if (!n.hasOwnProperty(i))
|
|
375
380
|
continue;
|
|
376
381
|
const a = n[i];
|
|
377
|
-
let o =
|
|
382
|
+
let o = Ze(i);
|
|
378
383
|
if (e.stripPrefix)
|
|
379
384
|
switch (M) {
|
|
380
385
|
case "vue2":
|
|
@@ -385,14 +390,14 @@ function G(e) {
|
|
|
385
390
|
o = o.replace("on:", "");
|
|
386
391
|
break;
|
|
387
392
|
}
|
|
388
|
-
t[o] =
|
|
393
|
+
t[o] = et(a, e);
|
|
389
394
|
}
|
|
390
395
|
return t;
|
|
391
396
|
}
|
|
392
|
-
function
|
|
397
|
+
function tt(e) {
|
|
393
398
|
return e.className = e.class, delete e.class, e;
|
|
394
399
|
}
|
|
395
|
-
const
|
|
400
|
+
const nt = (e) => ({
|
|
396
401
|
href: e.href
|
|
397
402
|
});
|
|
398
403
|
function O({
|
|
@@ -401,21 +406,21 @@ function O({
|
|
|
401
406
|
}) {
|
|
402
407
|
var i;
|
|
403
408
|
const n = {
|
|
404
|
-
...
|
|
409
|
+
...nt(e),
|
|
405
410
|
...e.properties,
|
|
406
411
|
"builder-id": e.id,
|
|
407
|
-
style: e.style ?
|
|
412
|
+
style: e.style ? it(e.style) : void 0,
|
|
408
413
|
class: [e.id, "builder-block", e.class, (i = e.properties) == null ? void 0 : i.class].filter(Boolean).join(" ")
|
|
409
414
|
};
|
|
410
|
-
return
|
|
415
|
+
return tt(n);
|
|
411
416
|
}
|
|
412
|
-
function
|
|
417
|
+
function it(e) {
|
|
413
418
|
switch (M) {
|
|
414
419
|
case "svelte":
|
|
415
420
|
case "vue2":
|
|
416
421
|
case "vue3":
|
|
417
422
|
case "solid":
|
|
418
|
-
return
|
|
423
|
+
return we(e).join(" ");
|
|
419
424
|
case "qwik":
|
|
420
425
|
case "reactNative":
|
|
421
426
|
case "react":
|
|
@@ -423,8 +428,8 @@ function Xe(e) {
|
|
|
423
428
|
return e;
|
|
424
429
|
}
|
|
425
430
|
}
|
|
426
|
-
function
|
|
427
|
-
return /* @__PURE__ */
|
|
431
|
+
function at(e) {
|
|
432
|
+
return /* @__PURE__ */ c(
|
|
428
433
|
e.Wrapper,
|
|
429
434
|
{
|
|
430
435
|
...e.wrapperProps,
|
|
@@ -433,7 +438,7 @@ function Ze(e) {
|
|
|
433
438
|
block: e.block,
|
|
434
439
|
context: e.context
|
|
435
440
|
}),
|
|
436
|
-
...
|
|
441
|
+
...Q({
|
|
437
442
|
block: e.block,
|
|
438
443
|
rootState: e.context.rootState,
|
|
439
444
|
rootSetState: e.context.rootSetState,
|
|
@@ -445,7 +450,7 @@ function Ze(e) {
|
|
|
445
450
|
}
|
|
446
451
|
);
|
|
447
452
|
}
|
|
448
|
-
const
|
|
453
|
+
const ot = ({
|
|
449
454
|
componentOptions: e,
|
|
450
455
|
builderBlock: t,
|
|
451
456
|
context: n,
|
|
@@ -471,15 +476,15 @@ const et = ({
|
|
|
471
476
|
})
|
|
472
477
|
} : {}
|
|
473
478
|
};
|
|
474
|
-
function
|
|
479
|
+
function ue(e) {
|
|
475
480
|
var i, a;
|
|
476
481
|
const [t, n] = I(
|
|
477
|
-
() => e.isInteractive ?
|
|
482
|
+
() => e.isInteractive ? at : e.componentRef
|
|
478
483
|
);
|
|
479
|
-
return /* @__PURE__ */
|
|
484
|
+
return /* @__PURE__ */ c(g, { children: e.componentRef ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ $(
|
|
480
485
|
t,
|
|
481
486
|
{
|
|
482
|
-
...
|
|
487
|
+
...ot({
|
|
483
488
|
componentOptions: e.componentOptions,
|
|
484
489
|
builderBlock: e.builderBlock,
|
|
485
490
|
context: e.context,
|
|
@@ -489,7 +494,7 @@ function ce(e) {
|
|
|
489
494
|
contextValue: e.context
|
|
490
495
|
}),
|
|
491
496
|
children: [
|
|
492
|
-
(i = e.blockChildren) == null ? void 0 : i.map((o) => /* @__PURE__ */
|
|
497
|
+
(i = e.blockChildren) == null ? void 0 : i.map((o) => /* @__PURE__ */ c(
|
|
493
498
|
z,
|
|
494
499
|
{
|
|
495
500
|
block: o,
|
|
@@ -498,8 +503,8 @@ function ce(e) {
|
|
|
498
503
|
},
|
|
499
504
|
"block-" + o.id
|
|
500
505
|
)),
|
|
501
|
-
(a = e.blockChildren) == null ? void 0 : a.map((o) => /* @__PURE__ */
|
|
502
|
-
|
|
506
|
+
(a = e.blockChildren) == null ? void 0 : a.map((o) => /* @__PURE__ */ c(
|
|
507
|
+
te,
|
|
503
508
|
{
|
|
504
509
|
block: o,
|
|
505
510
|
context: e.context
|
|
@@ -510,17 +515,17 @@ function ce(e) {
|
|
|
510
515
|
}
|
|
511
516
|
) }) : null });
|
|
512
517
|
}
|
|
513
|
-
function
|
|
514
|
-
return /* @__PURE__ */
|
|
518
|
+
function me(e) {
|
|
519
|
+
return /* @__PURE__ */ $(g, { children: [
|
|
515
520
|
" ",
|
|
516
|
-
e.hasChildren ? /* @__PURE__ */
|
|
521
|
+
e.hasChildren ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ $(
|
|
517
522
|
e.Wrapper,
|
|
518
523
|
{
|
|
519
524
|
...O({
|
|
520
525
|
block: e.block,
|
|
521
526
|
context: e.context
|
|
522
527
|
}),
|
|
523
|
-
...
|
|
528
|
+
...Q({
|
|
524
529
|
block: e.block,
|
|
525
530
|
rootState: e.context.rootState,
|
|
526
531
|
rootSetState: e.context.rootSetState,
|
|
@@ -534,14 +539,14 @@ function se(e) {
|
|
|
534
539
|
" "
|
|
535
540
|
]
|
|
536
541
|
}
|
|
537
|
-
) }) : /* @__PURE__ */
|
|
542
|
+
) }) : /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
|
|
538
543
|
e.Wrapper,
|
|
539
544
|
{
|
|
540
545
|
...O({
|
|
541
546
|
block: e.block,
|
|
542
547
|
context: e.context
|
|
543
548
|
}),
|
|
544
|
-
...
|
|
549
|
+
...Q({
|
|
545
550
|
block: e.block,
|
|
546
551
|
rootState: e.context.rootState,
|
|
547
552
|
rootSetState: e.context.rootSetState,
|
|
@@ -555,16 +560,16 @@ function se(e) {
|
|
|
555
560
|
] });
|
|
556
561
|
}
|
|
557
562
|
function z(e) {
|
|
558
|
-
var u,
|
|
563
|
+
var u, h, y, k;
|
|
559
564
|
function t() {
|
|
560
|
-
return
|
|
565
|
+
return Je({
|
|
561
566
|
block: e.block,
|
|
562
567
|
context: e.context,
|
|
563
568
|
registeredComponents: e.registeredComponents
|
|
564
569
|
});
|
|
565
570
|
}
|
|
566
571
|
function n() {
|
|
567
|
-
return
|
|
572
|
+
return Ye({
|
|
568
573
|
block: e.block,
|
|
569
574
|
context: e.context
|
|
570
575
|
});
|
|
@@ -590,28 +595,28 @@ function z(e) {
|
|
|
590
595
|
return !((S = t == null ? void 0 : t()) != null && S.component) && !n() ? i().children ?? [] : [];
|
|
591
596
|
}
|
|
592
597
|
function d() {
|
|
593
|
-
var
|
|
598
|
+
var b, S, C, w, x;
|
|
594
599
|
return {
|
|
595
600
|
blockChildren: i().children ?? [],
|
|
596
|
-
componentRef: (
|
|
601
|
+
componentRef: (b = t == null ? void 0 : t()) == null ? void 0 : b.component,
|
|
597
602
|
componentOptions: {
|
|
598
|
-
...
|
|
603
|
+
...De(i()),
|
|
599
604
|
builderContext: e.context,
|
|
600
|
-
...((S = t == null ? void 0 : t()) == null ? void 0 : S.name) === "Symbol" || ((
|
|
605
|
+
...((S = t == null ? void 0 : t()) == null ? void 0 : S.name) === "Symbol" || ((C = t == null ? void 0 : t()) == null ? void 0 : C.name) === "Columns" ? {
|
|
601
606
|
builderComponents: e.registeredComponents
|
|
602
607
|
} : {}
|
|
603
608
|
},
|
|
604
|
-
context:
|
|
609
|
+
context: l,
|
|
605
610
|
registeredComponents: e.registeredComponents,
|
|
606
611
|
builderBlock: i(),
|
|
607
|
-
includeBlockProps: ((
|
|
608
|
-
isInteractive: !((
|
|
612
|
+
includeBlockProps: ((w = t == null ? void 0 : t()) == null ? void 0 : w.noWrap) === !0,
|
|
613
|
+
isInteractive: !((x = t == null ? void 0 : t()) != null && x.isRSC)
|
|
609
614
|
};
|
|
610
615
|
}
|
|
611
|
-
const [
|
|
612
|
-
return /* @__PURE__ */
|
|
613
|
-
|
|
614
|
-
|
|
616
|
+
const [l, s] = I(() => e.context);
|
|
617
|
+
return /* @__PURE__ */ c(g, { children: o() ? /* @__PURE__ */ c(g, { children: (u = t == null ? void 0 : t()) != null && u.noWrap ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(ue, { ...d() }) }) : /* @__PURE__ */ $(g, { children: [
|
|
618
|
+
G(a()) ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
|
|
619
|
+
me,
|
|
615
620
|
{
|
|
616
621
|
Wrapper: a(),
|
|
617
622
|
block: i(),
|
|
@@ -619,47 +624,47 @@ function z(e) {
|
|
|
619
624
|
hasChildren: !1
|
|
620
625
|
}
|
|
621
626
|
) }) : null,
|
|
622
|
-
!
|
|
623
|
-
|
|
627
|
+
!G(a()) && n() ? /* @__PURE__ */ c(g, { children: (h = n()) == null ? void 0 : h.map((b, S) => /* @__PURE__ */ c(
|
|
628
|
+
Qe,
|
|
624
629
|
{
|
|
625
|
-
repeatContext:
|
|
626
|
-
block:
|
|
630
|
+
repeatContext: b.context,
|
|
631
|
+
block: b.block,
|
|
627
632
|
registeredComponents: e.registeredComponents
|
|
628
633
|
},
|
|
629
634
|
S
|
|
630
635
|
)) }) : null,
|
|
631
|
-
!
|
|
632
|
-
|
|
636
|
+
!G(a()) && !n() ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ $(
|
|
637
|
+
me,
|
|
633
638
|
{
|
|
634
639
|
Wrapper: a(),
|
|
635
640
|
block: i(),
|
|
636
641
|
context: e.context,
|
|
637
642
|
hasChildren: !0,
|
|
638
643
|
children: [
|
|
639
|
-
/* @__PURE__ */
|
|
640
|
-
(y = r()) == null ? void 0 : y.map((
|
|
644
|
+
/* @__PURE__ */ c(ue, { ...d() }),
|
|
645
|
+
(y = r()) == null ? void 0 : y.map((b) => /* @__PURE__ */ c(
|
|
641
646
|
z,
|
|
642
647
|
{
|
|
643
|
-
block:
|
|
644
|
-
context:
|
|
648
|
+
block: b,
|
|
649
|
+
context: l,
|
|
645
650
|
registeredComponents: e.registeredComponents
|
|
646
651
|
},
|
|
647
|
-
"block-" +
|
|
652
|
+
"block-" + b.id
|
|
648
653
|
)),
|
|
649
|
-
(k = r()) == null ? void 0 : k.map((
|
|
650
|
-
|
|
654
|
+
(k = r()) == null ? void 0 : k.map((b) => /* @__PURE__ */ c(
|
|
655
|
+
te,
|
|
651
656
|
{
|
|
652
|
-
block:
|
|
653
|
-
context:
|
|
657
|
+
block: b,
|
|
658
|
+
context: l
|
|
654
659
|
},
|
|
655
|
-
"block-style-" +
|
|
660
|
+
"block-style-" + b.id
|
|
656
661
|
))
|
|
657
662
|
]
|
|
658
663
|
}
|
|
659
664
|
) }) : null
|
|
660
665
|
] }) }) : null });
|
|
661
666
|
}
|
|
662
|
-
function
|
|
667
|
+
function rt(e) {
|
|
663
668
|
function t() {
|
|
664
669
|
var a;
|
|
665
670
|
return "builder-blocks" + ((a = e.blocks) != null && a.length ? "" : " no-blocks");
|
|
@@ -690,11 +695,11 @@ function tt(e) {
|
|
|
690
695
|
"*"
|
|
691
696
|
));
|
|
692
697
|
}
|
|
693
|
-
return /* @__PURE__ */
|
|
694
|
-
/* @__PURE__ */
|
|
698
|
+
return /* @__PURE__ */ $(g, { children: [
|
|
699
|
+
/* @__PURE__ */ c(
|
|
695
700
|
"div",
|
|
696
701
|
{
|
|
697
|
-
className: t() + " div-
|
|
702
|
+
className: t() + " div-02c7a115",
|
|
698
703
|
"builder-path": e.path,
|
|
699
704
|
"builder-parent-id": e.parent,
|
|
700
705
|
style: e.styleProp,
|
|
@@ -704,26 +709,26 @@ function tt(e) {
|
|
|
704
709
|
children: e.children
|
|
705
710
|
}
|
|
706
711
|
),
|
|
707
|
-
/* @__PURE__ */
|
|
712
|
+
/* @__PURE__ */ c("style", { children: `.div-02c7a115 {
|
|
708
713
|
display: flex;
|
|
709
714
|
flex-direction: column;
|
|
710
715
|
align-items: stretch;
|
|
711
716
|
}` })
|
|
712
717
|
] });
|
|
713
718
|
}
|
|
714
|
-
const
|
|
715
|
-
function
|
|
719
|
+
const Ie = Se({ registeredComponents: {} });
|
|
720
|
+
function ie(e) {
|
|
716
721
|
var i, a;
|
|
717
|
-
const t =
|
|
718
|
-
return /* @__PURE__ */
|
|
719
|
-
|
|
722
|
+
const t = oe(ne), n = oe(Ie);
|
|
723
|
+
return /* @__PURE__ */ $(
|
|
724
|
+
rt,
|
|
720
725
|
{
|
|
721
726
|
blocks: e.blocks,
|
|
722
727
|
parent: e.parent,
|
|
723
728
|
path: e.path,
|
|
724
729
|
styleProp: e.styleProp,
|
|
725
730
|
children: [
|
|
726
|
-
e.blocks ? /* @__PURE__ */
|
|
731
|
+
e.blocks ? /* @__PURE__ */ c(g, { children: (i = e.blocks) == null ? void 0 : i.map((o) => /* @__PURE__ */ c(
|
|
727
732
|
z,
|
|
728
733
|
{
|
|
729
734
|
block: o,
|
|
@@ -732,8 +737,8 @@ function ne(e) {
|
|
|
732
737
|
},
|
|
733
738
|
"render-block-" + o.id
|
|
734
739
|
)) }) : null,
|
|
735
|
-
e.blocks ? /* @__PURE__ */
|
|
736
|
-
|
|
740
|
+
e.blocks ? /* @__PURE__ */ c(g, { children: (a = e.blocks) == null ? void 0 : a.map((o) => /* @__PURE__ */ c(
|
|
741
|
+
te,
|
|
737
742
|
{
|
|
738
743
|
block: o,
|
|
739
744
|
context: e.context || t
|
|
@@ -744,47 +749,47 @@ function ne(e) {
|
|
|
744
749
|
}
|
|
745
750
|
);
|
|
746
751
|
}
|
|
747
|
-
function
|
|
748
|
-
var
|
|
752
|
+
function lt(e) {
|
|
753
|
+
var w;
|
|
749
754
|
const [t, n] = I(
|
|
750
755
|
() => typeof e.space == "number" ? e.space || 0 : 20
|
|
751
756
|
), [i, a] = I(() => e.columns || []), [o, r] = I(
|
|
752
757
|
() => e.stackColumnsAt || "tablet"
|
|
753
758
|
);
|
|
754
|
-
function d(
|
|
759
|
+
function d(x) {
|
|
755
760
|
var R;
|
|
756
|
-
return ((R = i[
|
|
761
|
+
return ((R = i[x]) == null ? void 0 : R.width) || 100 / i.length;
|
|
757
762
|
}
|
|
758
|
-
function
|
|
763
|
+
function l(x) {
|
|
759
764
|
const R = t * (i.length - 1) / i.length;
|
|
760
|
-
return `calc(${d(
|
|
765
|
+
return `calc(${d(x)}% - ${R}px)`;
|
|
761
766
|
}
|
|
762
767
|
function s({
|
|
763
|
-
stackedStyle:
|
|
768
|
+
stackedStyle: x,
|
|
764
769
|
desktopStyle: R
|
|
765
770
|
}) {
|
|
766
|
-
return o === "tablet" ?
|
|
771
|
+
return o === "tablet" ? x : R;
|
|
767
772
|
}
|
|
768
773
|
function u({
|
|
769
|
-
stackedStyle:
|
|
774
|
+
stackedStyle: x,
|
|
770
775
|
desktopStyle: R
|
|
771
776
|
}) {
|
|
772
|
-
return o === "never" ? R :
|
|
777
|
+
return o === "never" ? R : x;
|
|
773
778
|
}
|
|
774
|
-
const [
|
|
779
|
+
const [h, y] = I(
|
|
775
780
|
() => e.stackColumnsAt === "never" ? "row" : e.reverseColumnsWhenStacked ? "column-reverse" : "column"
|
|
776
781
|
);
|
|
777
782
|
function k() {
|
|
778
783
|
return {
|
|
779
|
-
"--flex-dir":
|
|
784
|
+
"--flex-dir": h,
|
|
780
785
|
"--flex-dir-tablet": s({
|
|
781
|
-
stackedStyle:
|
|
786
|
+
stackedStyle: h,
|
|
782
787
|
desktopStyle: "row"
|
|
783
788
|
})
|
|
784
789
|
};
|
|
785
790
|
}
|
|
786
|
-
function
|
|
787
|
-
const R =
|
|
791
|
+
function b(x) {
|
|
792
|
+
const R = x === 0 ? 0 : t, A = l(x), B = `${R}px`, N = "100%", W = 0;
|
|
788
793
|
return {
|
|
789
794
|
width: A,
|
|
790
795
|
["marginLeft"]: B,
|
|
@@ -793,7 +798,7 @@ function nt(e) {
|
|
|
793
798
|
desktopStyle: A
|
|
794
799
|
}),
|
|
795
800
|
"--column-margin-left-mobile": u({
|
|
796
|
-
stackedStyle:
|
|
801
|
+
stackedStyle: W,
|
|
797
802
|
desktopStyle: B
|
|
798
803
|
}),
|
|
799
804
|
"--column-width-tablet": s({
|
|
@@ -801,18 +806,18 @@ function nt(e) {
|
|
|
801
806
|
desktopStyle: A
|
|
802
807
|
}),
|
|
803
808
|
"--column-margin-left-tablet": s({
|
|
804
|
-
stackedStyle:
|
|
809
|
+
stackedStyle: W,
|
|
805
810
|
desktopStyle: B
|
|
806
811
|
})
|
|
807
812
|
};
|
|
808
813
|
}
|
|
809
|
-
function S(
|
|
814
|
+
function S(x) {
|
|
810
815
|
var A, B;
|
|
811
|
-
return
|
|
816
|
+
return Ce(
|
|
812
817
|
((B = (A = e.builderContext.content) == null ? void 0 : A.meta) == null ? void 0 : B.breakpoints) || {}
|
|
813
|
-
)[
|
|
818
|
+
)[x].max;
|
|
814
819
|
}
|
|
815
|
-
function
|
|
820
|
+
function C() {
|
|
816
821
|
return `
|
|
817
822
|
@media (max-width: ${S("medium")}px) {
|
|
818
823
|
.${e.builderBlock.id}-breakpoints {
|
|
@@ -839,23 +844,23 @@ function nt(e) {
|
|
|
839
844
|
},
|
|
840
845
|
`;
|
|
841
846
|
}
|
|
842
|
-
return /* @__PURE__ */
|
|
843
|
-
/* @__PURE__ */
|
|
847
|
+
return /* @__PURE__ */ $(g, { children: [
|
|
848
|
+
/* @__PURE__ */ $(
|
|
844
849
|
"div",
|
|
845
850
|
{
|
|
846
|
-
className: `builder-columns ${e.builderBlock.id}-breakpoints div-
|
|
851
|
+
className: `builder-columns ${e.builderBlock.id}-breakpoints div-ac8f4142`,
|
|
847
852
|
style: k(),
|
|
848
853
|
children: [
|
|
849
|
-
/* @__PURE__ */
|
|
850
|
-
(
|
|
854
|
+
/* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(H, { styles: C() }) }),
|
|
855
|
+
(w = e.columns) == null ? void 0 : w.map((x, R) => /* @__PURE__ */ ve(
|
|
851
856
|
"div",
|
|
852
857
|
{
|
|
853
|
-
className: "builder-column div-
|
|
854
|
-
style:
|
|
858
|
+
className: "builder-column div-ac8f4142-2",
|
|
859
|
+
style: b(R),
|
|
855
860
|
key: R
|
|
856
861
|
},
|
|
857
|
-
/* @__PURE__ */
|
|
858
|
-
|
|
862
|
+
/* @__PURE__ */ c(
|
|
863
|
+
ie,
|
|
859
864
|
{
|
|
860
865
|
path: `component.options.columns.${R}.blocks`,
|
|
861
866
|
parent: e.builderBlock.id,
|
|
@@ -864,42 +869,42 @@ function nt(e) {
|
|
|
864
869
|
},
|
|
865
870
|
context: e.builderContext,
|
|
866
871
|
registeredComponents: e.builderComponents,
|
|
867
|
-
blocks:
|
|
872
|
+
blocks: x.blocks
|
|
868
873
|
}
|
|
869
874
|
)
|
|
870
875
|
))
|
|
871
876
|
]
|
|
872
877
|
}
|
|
873
878
|
),
|
|
874
|
-
/* @__PURE__ */
|
|
879
|
+
/* @__PURE__ */ c("style", { children: `.div-ac8f4142 {
|
|
875
880
|
display: flex;
|
|
876
881
|
line-height: normal;
|
|
877
|
-
}.div-
|
|
882
|
+
}.div-ac8f4142-2 {
|
|
878
883
|
display: flex;
|
|
879
884
|
flex-direction: column;
|
|
880
885
|
align-items: stretch;
|
|
881
886
|
}` })
|
|
882
887
|
] });
|
|
883
888
|
}
|
|
884
|
-
function
|
|
885
|
-
return /* @__PURE__ */
|
|
889
|
+
function ct(e) {
|
|
890
|
+
return /* @__PURE__ */ c("span", { children: e.children });
|
|
886
891
|
}
|
|
887
|
-
function
|
|
892
|
+
function fe(e) {
|
|
888
893
|
return e.replace(/http(s)?:/, "");
|
|
889
894
|
}
|
|
890
|
-
function
|
|
895
|
+
function st(e = "", t, n) {
|
|
891
896
|
const i = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), a = e.indexOf("?") !== -1 ? "&" : "?";
|
|
892
897
|
return e.match(i) ? e.replace(i, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + a + t + "=" + encodeURIComponent(n);
|
|
893
898
|
}
|
|
894
|
-
function
|
|
899
|
+
function dt(e, t) {
|
|
895
900
|
if (!e || !(e != null && e.match(/cdn\.shopify\.com/)) || !t)
|
|
896
901
|
return e;
|
|
897
902
|
if (t === "master")
|
|
898
|
-
return
|
|
903
|
+
return fe(e);
|
|
899
904
|
const n = e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);
|
|
900
905
|
if (n) {
|
|
901
906
|
const i = e.split(n[0]), a = n[3], o = t.match("x") ? t : `${t}x`;
|
|
902
|
-
return
|
|
907
|
+
return fe(`${i[0]}_${o}${a}`);
|
|
903
908
|
}
|
|
904
909
|
return null;
|
|
905
910
|
}
|
|
@@ -910,11 +915,11 @@ function J(e) {
|
|
|
910
915
|
if (e.match(/builder\.io/)) {
|
|
911
916
|
let n = e;
|
|
912
917
|
const i = Number(e.split("?width=")[1]);
|
|
913
|
-
return isNaN(i) || (n = `${n} ${i}w`), t.filter((a) => a !== i).map((a) => `${
|
|
918
|
+
return isNaN(i) || (n = `${n} ${i}w`), t.filter((a) => a !== i).map((a) => `${st(e, "width", a)} ${a}w`).concat([n]).join(", ");
|
|
914
919
|
}
|
|
915
|
-
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [
|
|
920
|
+
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [dt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, i]) => `${n} ${i}w`).concat([e]).join(", ") : e;
|
|
916
921
|
}
|
|
917
|
-
function
|
|
922
|
+
function ut(e) {
|
|
918
923
|
var a, o, r, d;
|
|
919
924
|
function t() {
|
|
920
925
|
var u;
|
|
@@ -931,24 +936,24 @@ function rt(e) {
|
|
|
931
936
|
return J(s);
|
|
932
937
|
}
|
|
933
938
|
function n() {
|
|
934
|
-
var
|
|
935
|
-
return (
|
|
939
|
+
var l;
|
|
940
|
+
return (l = t == null ? void 0 : t()) != null && l.match(/builder\.io/) && !e.noWebp ? t().replace(/\?/g, "?format=webp&") : "";
|
|
936
941
|
}
|
|
937
942
|
function i() {
|
|
938
|
-
const
|
|
943
|
+
const l = {
|
|
939
944
|
position: "absolute",
|
|
940
945
|
height: "100%",
|
|
941
946
|
width: "100%",
|
|
942
947
|
left: "0px",
|
|
943
948
|
top: "0px"
|
|
944
949
|
};
|
|
945
|
-
return e.aspectRatio ?
|
|
950
|
+
return e.aspectRatio ? l : void 0;
|
|
946
951
|
}
|
|
947
|
-
return /* @__PURE__ */
|
|
948
|
-
/* @__PURE__ */
|
|
949
|
-
/* @__PURE__ */
|
|
950
|
-
n() ? /* @__PURE__ */
|
|
951
|
-
/* @__PURE__ */
|
|
952
|
+
return /* @__PURE__ */ $(g, { children: [
|
|
953
|
+
/* @__PURE__ */ $(g, { children: [
|
|
954
|
+
/* @__PURE__ */ $("picture", { children: [
|
|
955
|
+
n() ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c("source", { type: "image/webp", srcSet: n() }) }) : null,
|
|
956
|
+
/* @__PURE__ */ c(
|
|
952
957
|
"img",
|
|
953
958
|
{
|
|
954
959
|
loading: "lazy",
|
|
@@ -959,33 +964,33 @@ function rt(e) {
|
|
|
959
964
|
objectFit: e.backgroundSize || "cover",
|
|
960
965
|
...i()
|
|
961
966
|
},
|
|
962
|
-
className: "builder-image" + (e.className ? " " + e.className : "") + " img-
|
|
967
|
+
className: "builder-image" + (e.className ? " " + e.className : "") + " img-497e0136",
|
|
963
968
|
src: e.image,
|
|
964
969
|
srcSet: t(),
|
|
965
970
|
sizes: e.sizes
|
|
966
971
|
}
|
|
967
972
|
)
|
|
968
973
|
] }),
|
|
969
|
-
e.aspectRatio && !((o = (a = e.builderBlock) == null ? void 0 : a.children) != null && o.length && e.fitContent) ? /* @__PURE__ */
|
|
974
|
+
e.aspectRatio && !((o = (a = e.builderBlock) == null ? void 0 : a.children) != null && o.length && e.fitContent) ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
|
|
970
975
|
"div",
|
|
971
976
|
{
|
|
972
|
-
className: "builder-image-sizer div-
|
|
977
|
+
className: "builder-image-sizer div-497e0136",
|
|
973
978
|
style: {
|
|
974
979
|
paddingTop: e.aspectRatio * 100 + "%"
|
|
975
980
|
}
|
|
976
981
|
}
|
|
977
982
|
) }) : null,
|
|
978
|
-
(d = (r = e.builderBlock) == null ? void 0 : r.children) != null && d.length && e.fitContent ? /* @__PURE__ */
|
|
979
|
-
!e.fitContent && e.children ? /* @__PURE__ */
|
|
983
|
+
(d = (r = e.builderBlock) == null ? void 0 : r.children) != null && d.length && e.fitContent ? /* @__PURE__ */ c(g, { children: e.children }) : null,
|
|
984
|
+
!e.fitContent && e.children ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c("div", { className: "div-497e0136-2", children: e.children }) }) : null
|
|
980
985
|
] }),
|
|
981
|
-
/* @__PURE__ */
|
|
986
|
+
/* @__PURE__ */ c("style", { children: `.img-497e0136 {
|
|
982
987
|
opacity: 1;
|
|
983
988
|
transition: opacity 0.2s ease-in-out;
|
|
984
|
-
}.div-
|
|
989
|
+
}.div-497e0136 {
|
|
985
990
|
width: 100%;
|
|
986
991
|
pointer-events: none;
|
|
987
992
|
font-size: 0;
|
|
988
|
-
}.div-
|
|
993
|
+
}.div-497e0136-2 {
|
|
989
994
|
display: flex;
|
|
990
995
|
flex-direction: column;
|
|
991
996
|
align-items: stretch;
|
|
@@ -997,8 +1002,8 @@ function rt(e) {
|
|
|
997
1002
|
}` })
|
|
998
1003
|
] });
|
|
999
1004
|
}
|
|
1000
|
-
function
|
|
1001
|
-
return /* @__PURE__ */
|
|
1005
|
+
function mt(e) {
|
|
1006
|
+
return /* @__PURE__ */ c(
|
|
1002
1007
|
"section",
|
|
1003
1008
|
{
|
|
1004
1009
|
...e.attributes,
|
|
@@ -1022,40 +1027,40 @@ const L = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t
|
|
|
1022
1027
|
...t,
|
|
1023
1028
|
testVariationId: t.id,
|
|
1024
1029
|
id: e == null ? void 0 : e.id
|
|
1025
|
-
})),
|
|
1030
|
+
})), ft = ({
|
|
1026
1031
|
canTrack: e,
|
|
1027
1032
|
content: t
|
|
1028
1033
|
}) => !(!(L(t).length > 0) || !e || F());
|
|
1029
|
-
function
|
|
1034
|
+
function ht(e, t, n) {
|
|
1030
1035
|
var r;
|
|
1031
1036
|
function i() {
|
|
1032
|
-
function d(
|
|
1033
|
-
let
|
|
1034
|
-
if (
|
|
1035
|
-
const
|
|
1036
|
-
|
|
1037
|
+
function d(b, S, C) {
|
|
1038
|
+
let w = "";
|
|
1039
|
+
if (C) {
|
|
1040
|
+
const x = /* @__PURE__ */ new Date();
|
|
1041
|
+
x.setTime(x.getTime() + C * 24 * 60 * 60 * 1e3), w = "; expires=" + x.toUTCString();
|
|
1037
1042
|
}
|
|
1038
|
-
document.cookie =
|
|
1043
|
+
document.cookie = b + "=" + (S || "") + w + "; path=/; Secure; SameSite=None";
|
|
1039
1044
|
}
|
|
1040
|
-
function
|
|
1041
|
-
const S =
|
|
1042
|
-
for (let
|
|
1043
|
-
let
|
|
1044
|
-
for (;
|
|
1045
|
-
|
|
1046
|
-
if (
|
|
1047
|
-
return
|
|
1045
|
+
function l(b) {
|
|
1046
|
+
const S = b + "=", C = document.cookie.split(";");
|
|
1047
|
+
for (let w = 0; w < C.length; w++) {
|
|
1048
|
+
let x = C[w];
|
|
1049
|
+
for (; x.charAt(0) === " "; )
|
|
1050
|
+
x = x.substring(1, x.length);
|
|
1051
|
+
if (x.indexOf(S) === 0)
|
|
1052
|
+
return x.substring(S.length, x.length);
|
|
1048
1053
|
}
|
|
1049
1054
|
return null;
|
|
1050
1055
|
}
|
|
1051
|
-
const s = `builder.tests.${e}`, u =
|
|
1052
|
-
if (u &&
|
|
1056
|
+
const s = `builder.tests.${e}`, u = l(s), h = t.map((b) => b.id).concat(e);
|
|
1057
|
+
if (u && h.includes(u))
|
|
1053
1058
|
return u;
|
|
1054
1059
|
let y = 0;
|
|
1055
1060
|
const k = Math.random();
|
|
1056
|
-
for (let
|
|
1057
|
-
const S = t[
|
|
1058
|
-
if (y +=
|
|
1061
|
+
for (let b = 0; b < t.length; b++) {
|
|
1062
|
+
const S = t[b], C = S.testRatio;
|
|
1063
|
+
if (y += C, k < y)
|
|
1059
1064
|
return d(s, S.id), S.id;
|
|
1060
1065
|
}
|
|
1061
1066
|
return d(s, e), e;
|
|
@@ -1068,19 +1073,19 @@ function st(e, t, n) {
|
|
|
1068
1073
|
} else {
|
|
1069
1074
|
const d = t.concat({
|
|
1070
1075
|
id: e
|
|
1071
|
-
}).filter((
|
|
1076
|
+
}).filter((l) => l.id !== a).map((l) => `.variant-${l.id} { display: none; }
|
|
1072
1077
|
`).join("");
|
|
1073
1078
|
o.innerHTML = d;
|
|
1074
1079
|
}
|
|
1075
1080
|
}
|
|
1076
|
-
function
|
|
1077
|
-
var
|
|
1081
|
+
function gt(e, t, n) {
|
|
1082
|
+
var l;
|
|
1078
1083
|
if (!navigator.cookieEnabled)
|
|
1079
1084
|
return;
|
|
1080
1085
|
function i(s) {
|
|
1081
|
-
const u = s + "=",
|
|
1082
|
-
for (let y = 0; y <
|
|
1083
|
-
let k =
|
|
1086
|
+
const u = s + "=", h = document.cookie.split(";");
|
|
1087
|
+
for (let y = 0; y < h.length; y++) {
|
|
1088
|
+
let k = h[y];
|
|
1084
1089
|
for (; k.charAt(0) === " "; )
|
|
1085
1090
|
k = k.substring(1, k.length);
|
|
1086
1091
|
if (k.indexOf(u) === 0)
|
|
@@ -1088,7 +1093,7 @@ function dt(e, t, n) {
|
|
|
1088
1093
|
}
|
|
1089
1094
|
return null;
|
|
1090
1095
|
}
|
|
1091
|
-
const a = `builder.tests.${t}`, o = i(a), r = (
|
|
1096
|
+
const a = `builder.tests.${t}`, o = i(a), r = (l = document.currentScript) == null ? void 0 : l.parentElement, d = e === t;
|
|
1092
1097
|
if (o === e) {
|
|
1093
1098
|
if (d)
|
|
1094
1099
|
return;
|
|
@@ -1098,18 +1103,18 @@ function dt(e, t, n) {
|
|
|
1098
1103
|
return;
|
|
1099
1104
|
}
|
|
1100
1105
|
}
|
|
1101
|
-
const
|
|
1102
|
-
const e =
|
|
1106
|
+
const bt = (e) => e === "react" || e === "reactNative", Te = bt(M), Re = "builderIoAbTest", Ee = "builderIoRenderContent", xt = () => {
|
|
1107
|
+
const e = ht.toString().replace(/\s+/g, " "), t = gt.toString().replace(/\s+/g, " ");
|
|
1103
1108
|
return `
|
|
1104
|
-
window.${
|
|
1105
|
-
window.${
|
|
1109
|
+
window.${Re} = ${e}
|
|
1110
|
+
window.${Ee} = ${t}
|
|
1106
1111
|
`;
|
|
1107
|
-
},
|
|
1108
|
-
window.${
|
|
1112
|
+
}, yt = (e, t) => `
|
|
1113
|
+
window.${Re}("${t}",${JSON.stringify(e)}, ${Te})`, St = ({
|
|
1109
1114
|
contentId: e,
|
|
1110
1115
|
variationId: t
|
|
1111
1116
|
}) => `
|
|
1112
|
-
window.${
|
|
1117
|
+
window.${Ee}("${t}", "${e}", ${Te})`, vt = {
|
|
1113
1118
|
name: "Core:Button",
|
|
1114
1119
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
1115
1120
|
defaultStyles: {
|
|
@@ -1142,7 +1147,7 @@ const ut = (e) => e === "react" || e === "reactNative", pe = ut(M), Ce = "builde
|
|
|
1142
1147
|
}],
|
|
1143
1148
|
static: !0,
|
|
1144
1149
|
noWrap: !0
|
|
1145
|
-
},
|
|
1150
|
+
}, pt = {
|
|
1146
1151
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
1147
1152
|
name: "Columns",
|
|
1148
1153
|
isRSC: !0,
|
|
@@ -1321,7 +1326,7 @@ const ut = (e) => e === "react" || e === "reactNative", pe = ut(M), Ce = "builde
|
|
|
1321
1326
|
});
|
|
1322
1327
|
}
|
|
1323
1328
|
const n = e.get("columns");
|
|
1324
|
-
Array.isArray(n) && n.find((a) => a.get("width")) && (n.find((o) => !o.get("width")) || n.reduce((d,
|
|
1329
|
+
Array.isArray(n) && n.find((a) => a.get("width")) && (n.find((o) => !o.get("width")) || n.reduce((d, l) => d + l.get("width"), 0) !== 100) && t();
|
|
1325
1330
|
}
|
|
1326
1331
|
}, {
|
|
1327
1332
|
name: "space",
|
|
@@ -1343,13 +1348,13 @@ const ut = (e) => e === "react" || e === "reactNative", pe = ut(M), Ce = "builde
|
|
|
1343
1348
|
helperText: "When stacking columns for mobile devices, reverse the ordering",
|
|
1344
1349
|
advanced: !0
|
|
1345
1350
|
}]
|
|
1346
|
-
},
|
|
1351
|
+
}, kt = {
|
|
1347
1352
|
name: "Fragment",
|
|
1348
1353
|
static: !0,
|
|
1349
1354
|
hidden: !0,
|
|
1350
1355
|
canHaveChildren: !0,
|
|
1351
1356
|
noWrap: !0
|
|
1352
|
-
},
|
|
1357
|
+
}, Ct = {
|
|
1353
1358
|
name: "Image",
|
|
1354
1359
|
static: !0,
|
|
1355
1360
|
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",
|
|
@@ -1370,15 +1375,15 @@ const ut = (e) => e === "react" || e === "reactNative", pe = ut(M), Ce = "builde
|
|
|
1370
1375
|
onChange: (e) => {
|
|
1371
1376
|
e.delete("srcset"), e.delete("noWebp");
|
|
1372
1377
|
function n(r, d = 6e4) {
|
|
1373
|
-
return new Promise((
|
|
1378
|
+
return new Promise((l, s) => {
|
|
1374
1379
|
const u = document.createElement("img");
|
|
1375
|
-
let
|
|
1380
|
+
let h = !1;
|
|
1376
1381
|
u.onload = () => {
|
|
1377
|
-
|
|
1382
|
+
h = !0, l(u);
|
|
1378
1383
|
}, u.addEventListener("error", (y) => {
|
|
1379
1384
|
console.warn("Image load failed", y.error), s(y.error);
|
|
1380
1385
|
}), u.src = r, setTimeout(() => {
|
|
1381
|
-
|
|
1386
|
+
h || s(new Error("Image load timed out"));
|
|
1382
1387
|
}, d);
|
|
1383
1388
|
});
|
|
1384
1389
|
}
|
|
@@ -1449,7 +1454,7 @@ const ut = (e) => e === "react" || e === "reactNative", pe = ut(M), Ce = "builde
|
|
|
1449
1454
|
advanced: !0,
|
|
1450
1455
|
defaultValue: 0.7041
|
|
1451
1456
|
}]
|
|
1452
|
-
},
|
|
1457
|
+
}, wt = {
|
|
1453
1458
|
name: "Core:Section",
|
|
1454
1459
|
static: !0,
|
|
1455
1460
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -1488,7 +1493,7 @@ const ut = (e) => e === "react" || e === "reactNative", pe = ut(M), Ce = "builde
|
|
|
1488
1493
|
}
|
|
1489
1494
|
}
|
|
1490
1495
|
}]
|
|
1491
|
-
},
|
|
1496
|
+
}, It = {
|
|
1492
1497
|
name: "Symbol",
|
|
1493
1498
|
noWrap: !0,
|
|
1494
1499
|
static: !0,
|
|
@@ -1521,7 +1526,7 @@ const ut = (e) => e === "react" || e === "reactNative", pe = ut(M), Ce = "builde
|
|
|
1521
1526
|
hideFromUI: !0,
|
|
1522
1527
|
type: "boolean"
|
|
1523
1528
|
}]
|
|
1524
|
-
},
|
|
1529
|
+
}, Tt = {
|
|
1525
1530
|
name: "Text",
|
|
1526
1531
|
static: !0,
|
|
1527
1532
|
isRSC: !0,
|
|
@@ -1540,9 +1545,9 @@ const ut = (e) => e === "react" || e === "reactNative", pe = ut(M), Ce = "builde
|
|
|
1540
1545
|
textAlign: "center"
|
|
1541
1546
|
}
|
|
1542
1547
|
};
|
|
1543
|
-
function
|
|
1548
|
+
function Rt(e) {
|
|
1544
1549
|
var t;
|
|
1545
|
-
return /* @__PURE__ */
|
|
1550
|
+
return /* @__PURE__ */ c(
|
|
1546
1551
|
"div",
|
|
1547
1552
|
{
|
|
1548
1553
|
className: "builder-text",
|
|
@@ -1553,7 +1558,7 @@ function pt(e) {
|
|
|
1553
1558
|
}
|
|
1554
1559
|
);
|
|
1555
1560
|
}
|
|
1556
|
-
const
|
|
1561
|
+
const Et = {
|
|
1557
1562
|
name: "Video",
|
|
1558
1563
|
canHaveChildren: !0,
|
|
1559
1564
|
defaultStyles: {
|
|
@@ -1635,7 +1640,7 @@ const Ct = {
|
|
|
1635
1640
|
advanced: !0
|
|
1636
1641
|
}]
|
|
1637
1642
|
};
|
|
1638
|
-
function
|
|
1643
|
+
function $t(e) {
|
|
1639
1644
|
var i;
|
|
1640
1645
|
function t() {
|
|
1641
1646
|
return {
|
|
@@ -1662,7 +1667,7 @@ function wt(e) {
|
|
|
1662
1667
|
...t()
|
|
1663
1668
|
};
|
|
1664
1669
|
}
|
|
1665
|
-
return /* @__PURE__ */
|
|
1670
|
+
return /* @__PURE__ */ c(
|
|
1666
1671
|
"video",
|
|
1667
1672
|
{
|
|
1668
1673
|
...n(),
|
|
@@ -1682,7 +1687,7 @@ function wt(e) {
|
|
|
1682
1687
|
}
|
|
1683
1688
|
);
|
|
1684
1689
|
}
|
|
1685
|
-
const
|
|
1690
|
+
const Pt = {
|
|
1686
1691
|
name: "Embed",
|
|
1687
1692
|
static: !0,
|
|
1688
1693
|
inputs: [{
|
|
@@ -1707,30 +1712,30 @@ const It = {
|
|
|
1707
1712
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
1708
1713
|
hideFromUI: !0
|
|
1709
1714
|
}]
|
|
1710
|
-
},
|
|
1711
|
-
function
|
|
1712
|
-
const t =
|
|
1713
|
-
function
|
|
1715
|
+
}, At = ["text/javascript", "application/javascript", "application/ecmascript"], Bt = (e) => At.includes(e.type);
|
|
1716
|
+
function Vt(e) {
|
|
1717
|
+
const t = Z(null), [n, i] = I(() => []), [a, o] = I(() => []), [r, d] = I(() => !1);
|
|
1718
|
+
function l() {
|
|
1714
1719
|
if (!t.current || !t.current.getElementsByTagName)
|
|
1715
1720
|
return;
|
|
1716
1721
|
const s = t.current.getElementsByTagName("script");
|
|
1717
1722
|
for (let u = 0; u < s.length; u++) {
|
|
1718
|
-
const
|
|
1719
|
-
if (
|
|
1720
|
-
n.push(
|
|
1723
|
+
const h = s[u];
|
|
1724
|
+
if (h.src && !n.includes(h.src)) {
|
|
1725
|
+
n.push(h.src);
|
|
1721
1726
|
const y = document.createElement("script");
|
|
1722
|
-
y.async = !0, y.src =
|
|
1723
|
-
} else if (
|
|
1727
|
+
y.async = !0, y.src = h.src, document.head.appendChild(y);
|
|
1728
|
+
} else if (Bt(h) && !a.includes(h.innerText))
|
|
1724
1729
|
try {
|
|
1725
|
-
a.push(
|
|
1730
|
+
a.push(h.innerText), new Function(h.innerText)();
|
|
1726
1731
|
} catch (y) {
|
|
1727
1732
|
console.warn("`Embed`: Error running script:", y);
|
|
1728
1733
|
}
|
|
1729
1734
|
}
|
|
1730
1735
|
}
|
|
1731
1736
|
return P(() => {
|
|
1732
|
-
t.current && !r && (d(!0),
|
|
1733
|
-
}, [t.current, r]), /* @__PURE__ */
|
|
1737
|
+
t.current && !r && (d(!0), l());
|
|
1738
|
+
}, [t.current, r]), /* @__PURE__ */ c(
|
|
1734
1739
|
"div",
|
|
1735
1740
|
{
|
|
1736
1741
|
className: "builder-embed",
|
|
@@ -1739,8 +1744,8 @@ function Et(e) {
|
|
|
1739
1744
|
}
|
|
1740
1745
|
);
|
|
1741
1746
|
}
|
|
1742
|
-
function
|
|
1743
|
-
return /* @__PURE__ */
|
|
1747
|
+
function Ft(e) {
|
|
1748
|
+
return /* @__PURE__ */ c(
|
|
1744
1749
|
"img",
|
|
1745
1750
|
{
|
|
1746
1751
|
style: {
|
|
@@ -1754,7 +1759,7 @@ function $t(e) {
|
|
|
1754
1759
|
V() && e.imgSrc || "default-key"
|
|
1755
1760
|
);
|
|
1756
1761
|
}
|
|
1757
|
-
const
|
|
1762
|
+
const Nt = {
|
|
1758
1763
|
// friendlyName?
|
|
1759
1764
|
name: "Raw:Img",
|
|
1760
1765
|
hideFromInsertMenu: !0,
|
|
@@ -1769,38 +1774,36 @@ const Pt = {
|
|
|
1769
1774
|
noWrap: !0,
|
|
1770
1775
|
static: !0
|
|
1771
1776
|
};
|
|
1772
|
-
function
|
|
1773
|
-
const t =
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1777
|
+
function Wt(e) {
|
|
1778
|
+
const t = Z(null), [n, i] = I(() => []), [a, o] = I(() => []);
|
|
1779
|
+
return P(() => {
|
|
1780
|
+
var d;
|
|
1781
|
+
if (!((d = t.current) != null && d.getElementsByTagName) || typeof window > "u")
|
|
1782
|
+
return;
|
|
1783
|
+
const r = t.current.getElementsByTagName("script");
|
|
1784
|
+
for (let l = 0; l < r.length; l++) {
|
|
1785
|
+
const s = r[l];
|
|
1786
|
+
if (s.src) {
|
|
1787
|
+
if (n.includes(s.src))
|
|
1788
|
+
continue;
|
|
1789
|
+
n.push(s.src);
|
|
1790
|
+
const u = document.createElement("script");
|
|
1791
|
+
u.async = !0, u.src = s.src, document.head.appendChild(u);
|
|
1792
|
+
} else if (!s.type || [
|
|
1793
|
+
"text/javascript",
|
|
1794
|
+
"application/javascript",
|
|
1795
|
+
"application/ecmascript"
|
|
1796
|
+
].includes(s.type)) {
|
|
1797
|
+
if (a.includes(s.innerText))
|
|
1798
|
+
continue;
|
|
1799
|
+
try {
|
|
1800
|
+
a.push(s.innerText), new Function(s.innerText)();
|
|
1801
|
+
} catch (u) {
|
|
1802
|
+
console.warn("`CustomCode`: Error running script:", u);
|
|
1797
1803
|
}
|
|
1798
1804
|
}
|
|
1799
1805
|
}
|
|
1800
|
-
}
|
|
1801
|
-
return P(() => {
|
|
1802
|
-
r();
|
|
1803
|
-
}, []), /* @__PURE__ */ l(
|
|
1806
|
+
}, []), /* @__PURE__ */ c(
|
|
1804
1807
|
"div",
|
|
1805
1808
|
{
|
|
1806
1809
|
ref: t,
|
|
@@ -1809,7 +1812,7 @@ function At(e) {
|
|
|
1809
1812
|
}
|
|
1810
1813
|
);
|
|
1811
1814
|
}
|
|
1812
|
-
const
|
|
1815
|
+
const jt = {
|
|
1813
1816
|
name: "Custom Code",
|
|
1814
1817
|
static: !0,
|
|
1815
1818
|
requiredPermissions: ["editCode"],
|
|
@@ -1831,40 +1834,40 @@ const Bt = {
|
|
|
1831
1834
|
helperText: "Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",
|
|
1832
1835
|
advanced: !0
|
|
1833
1836
|
}]
|
|
1834
|
-
},
|
|
1835
|
-
component:
|
|
1836
|
-
...
|
|
1837
|
+
}, he = () => [{
|
|
1838
|
+
component: je,
|
|
1839
|
+
...vt
|
|
1837
1840
|
}, {
|
|
1838
|
-
component:
|
|
1839
|
-
...
|
|
1841
|
+
component: lt,
|
|
1842
|
+
...pt
|
|
1840
1843
|
}, {
|
|
1841
|
-
component:
|
|
1842
|
-
...
|
|
1844
|
+
component: Wt,
|
|
1845
|
+
...jt
|
|
1843
1846
|
}, {
|
|
1844
|
-
component:
|
|
1845
|
-
...
|
|
1847
|
+
component: Vt,
|
|
1848
|
+
...Pt
|
|
1846
1849
|
}, {
|
|
1847
|
-
component:
|
|
1848
|
-
...
|
|
1850
|
+
component: ct,
|
|
1851
|
+
...kt
|
|
1849
1852
|
}, {
|
|
1850
|
-
component:
|
|
1851
|
-
...
|
|
1853
|
+
component: ut,
|
|
1854
|
+
...Ct
|
|
1852
1855
|
}, {
|
|
1853
|
-
component:
|
|
1854
|
-
...
|
|
1856
|
+
component: Ft,
|
|
1857
|
+
...Nt
|
|
1855
1858
|
}, {
|
|
1856
|
-
component:
|
|
1857
|
-
...
|
|
1859
|
+
component: mt,
|
|
1860
|
+
...wt
|
|
1858
1861
|
}, {
|
|
1859
|
-
component:
|
|
1860
|
-
...
|
|
1862
|
+
component: Xt,
|
|
1863
|
+
...It
|
|
1861
1864
|
}, {
|
|
1862
|
-
component:
|
|
1863
|
-
...
|
|
1865
|
+
component: Rt,
|
|
1866
|
+
...Tt
|
|
1864
1867
|
}, {
|
|
1865
|
-
component:
|
|
1866
|
-
...
|
|
1867
|
-
}],
|
|
1868
|
+
component: $t,
|
|
1869
|
+
...Et
|
|
1870
|
+
}], Mt = (e) => {
|
|
1868
1871
|
var o;
|
|
1869
1872
|
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = e.fileUrl ?? ((o = e == null ? void 0 : e.files) == null ? void 0 : o.regular);
|
|
1870
1873
|
let a = "";
|
|
@@ -1879,34 +1882,34 @@ font-weight: 400;
|
|
|
1879
1882
|
for (const r in e.files) {
|
|
1880
1883
|
if (!(String(Number(r)) === r))
|
|
1881
1884
|
continue;
|
|
1882
|
-
const
|
|
1883
|
-
|
|
1885
|
+
const l = e.files[r];
|
|
1886
|
+
l && l !== i && (a += `
|
|
1884
1887
|
@font-face {
|
|
1885
1888
|
font-family: "${t}";
|
|
1886
|
-
src: url('${
|
|
1889
|
+
src: url('${l}') format('woff2');
|
|
1887
1890
|
font-display: fallback;
|
|
1888
1891
|
font-weight: ${r};
|
|
1889
1892
|
}
|
|
1890
1893
|
`.trim());
|
|
1891
1894
|
}
|
|
1892
1895
|
return a;
|
|
1893
|
-
},
|
|
1896
|
+
}, Lt = ({
|
|
1894
1897
|
customFonts: e
|
|
1895
1898
|
}) => {
|
|
1896
1899
|
var t;
|
|
1897
|
-
return ((t = e == null ? void 0 : e.map((n) =>
|
|
1898
|
-
},
|
|
1900
|
+
return ((t = e == null ? void 0 : e.map((n) => Mt(n))) == null ? void 0 : t.join(" ")) || "";
|
|
1901
|
+
}, _t = ({
|
|
1899
1902
|
cssCode: e,
|
|
1900
1903
|
contentId: t
|
|
1901
1904
|
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "";
|
|
1902
|
-
function
|
|
1905
|
+
function Ut(e) {
|
|
1903
1906
|
const [t, n] = I(
|
|
1904
1907
|
() => `
|
|
1905
|
-
${
|
|
1908
|
+
${_t({
|
|
1906
1909
|
cssCode: e.cssCode,
|
|
1907
1910
|
contentId: e.contentId
|
|
1908
1911
|
})}
|
|
1909
|
-
${
|
|
1912
|
+
${Lt({
|
|
1910
1913
|
customFonts: e.customFonts
|
|
1911
1914
|
})}
|
|
1912
1915
|
|
|
@@ -1924,18 +1927,18 @@ ${Ft({
|
|
|
1924
1927
|
}
|
|
1925
1928
|
`.trim()
|
|
1926
1929
|
);
|
|
1927
|
-
return /* @__PURE__ */
|
|
1930
|
+
return /* @__PURE__ */ c(H, { styles: t });
|
|
1928
1931
|
}
|
|
1929
|
-
const
|
|
1932
|
+
const Kt = ({
|
|
1930
1933
|
content: e,
|
|
1931
1934
|
data: t,
|
|
1932
1935
|
locale: n
|
|
1933
1936
|
}) => {
|
|
1934
1937
|
var o, r, d;
|
|
1935
1938
|
const i = {};
|
|
1936
|
-
(r = (o = e == null ? void 0 : e.data) == null ? void 0 : o.inputs) == null || r.forEach((
|
|
1939
|
+
(r = (o = e == null ? void 0 : e.data) == null ? void 0 : o.inputs) == null || r.forEach((l) => {
|
|
1937
1940
|
var s;
|
|
1938
|
-
|
|
1941
|
+
l.name && l.defaultValue !== void 0 && ((s = e == null ? void 0 : e.data) != null && s.state) && e.data.state[l.name] === void 0 && (i[l.name] = l.defaultValue);
|
|
1939
1942
|
});
|
|
1940
1943
|
const a = {
|
|
1941
1944
|
...(d = e == null ? void 0 : e.data) == null ? void 0 : d.state,
|
|
@@ -1948,7 +1951,7 @@ const jt = ({
|
|
|
1948
1951
|
...i,
|
|
1949
1952
|
...a
|
|
1950
1953
|
};
|
|
1951
|
-
},
|
|
1954
|
+
}, Ot = ({
|
|
1952
1955
|
content: e,
|
|
1953
1956
|
data: t
|
|
1954
1957
|
}) => e ? {
|
|
@@ -1958,8 +1961,8 @@ const jt = ({
|
|
|
1958
1961
|
...t
|
|
1959
1962
|
},
|
|
1960
1963
|
meta: e == null ? void 0 : e.meta
|
|
1961
|
-
} : void 0,
|
|
1962
|
-
|
|
1964
|
+
} : void 0, Ht = "0.7.1-1", zt = () => {
|
|
1965
|
+
Be("insertMenu", {
|
|
1963
1966
|
name: "_default",
|
|
1964
1967
|
default: !0,
|
|
1965
1968
|
items: [{
|
|
@@ -1981,14 +1984,14 @@ const jt = ({
|
|
|
1981
1984
|
}]
|
|
1982
1985
|
});
|
|
1983
1986
|
};
|
|
1984
|
-
let
|
|
1985
|
-
const
|
|
1987
|
+
let ge = !1;
|
|
1988
|
+
const qt = (e = {}) => {
|
|
1986
1989
|
var t, n;
|
|
1987
|
-
|
|
1990
|
+
ge || (ge = !0, F() && ((t = window.parent) == null || t.postMessage({
|
|
1988
1991
|
type: "builder.sdkInfo",
|
|
1989
1992
|
data: {
|
|
1990
1993
|
target: M,
|
|
1991
|
-
version:
|
|
1994
|
+
version: Ht,
|
|
1992
1995
|
supportsPatchUpdates: !1,
|
|
1993
1996
|
// Supports builder-model="..." attribute which is needed to
|
|
1994
1997
|
// scope our '+ add block' button styling
|
|
@@ -2007,25 +2010,25 @@ const _t = (e = {}) => {
|
|
|
2007
2010
|
if (i != null && i.type)
|
|
2008
2011
|
switch (i.type) {
|
|
2009
2012
|
case "builder.evaluate": {
|
|
2010
|
-
const r = i.data.text, d = i.data.arguments || [],
|
|
2011
|
-
let u,
|
|
2013
|
+
const r = i.data.text, d = i.data.arguments || [], l = i.data.id, s = new Function(r);
|
|
2014
|
+
let u, h = null;
|
|
2012
2015
|
try {
|
|
2013
2016
|
u = s.apply(null, d);
|
|
2014
2017
|
} catch (y) {
|
|
2015
|
-
|
|
2018
|
+
h = y;
|
|
2016
2019
|
}
|
|
2017
|
-
|
|
2020
|
+
h ? (a = window.parent) == null || a.postMessage({
|
|
2018
2021
|
type: "builder.evaluateError",
|
|
2019
2022
|
data: {
|
|
2020
|
-
id:
|
|
2021
|
-
error:
|
|
2023
|
+
id: l,
|
|
2024
|
+
error: h.message
|
|
2022
2025
|
}
|
|
2023
2026
|
}, "*") : u && typeof u.then == "function" ? u.then((y) => {
|
|
2024
2027
|
var k;
|
|
2025
2028
|
(k = window.parent) == null || k.postMessage({
|
|
2026
2029
|
type: "builder.evaluateResult",
|
|
2027
2030
|
data: {
|
|
2028
|
-
id:
|
|
2031
|
+
id: l,
|
|
2029
2032
|
result: y
|
|
2030
2033
|
}
|
|
2031
2034
|
}, "*");
|
|
@@ -2033,7 +2036,7 @@ const _t = (e = {}) => {
|
|
|
2033
2036
|
type: "builder.evaluateResult",
|
|
2034
2037
|
data: {
|
|
2035
2038
|
result: u,
|
|
2036
|
-
id:
|
|
2039
|
+
id: l
|
|
2037
2040
|
}
|
|
2038
2041
|
}, "*");
|
|
2039
2042
|
break;
|
|
@@ -2041,10 +2044,10 @@ const _t = (e = {}) => {
|
|
|
2041
2044
|
}
|
|
2042
2045
|
})));
|
|
2043
2046
|
};
|
|
2044
|
-
function
|
|
2047
|
+
function be(e) {
|
|
2045
2048
|
return Math.round(e * 1e3) / 1e3;
|
|
2046
2049
|
}
|
|
2047
|
-
const
|
|
2050
|
+
const Dt = (e, t, n = !0) => {
|
|
2048
2051
|
if (!(e instanceof HTMLElement))
|
|
2049
2052
|
return null;
|
|
2050
2053
|
let i = n ? e : e.parentElement;
|
|
@@ -2055,28 +2058,28 @@ const Kt = (e, t, n = !0) => {
|
|
|
2055
2058
|
return i;
|
|
2056
2059
|
} while (i = i.parentElement);
|
|
2057
2060
|
return null;
|
|
2058
|
-
},
|
|
2061
|
+
}, Gt = (e) => Dt(e, (t) => {
|
|
2059
2062
|
const n = t.getAttribute("builder-id") || t.id;
|
|
2060
2063
|
return (n == null ? void 0 : n.indexOf("builder-")) === 0;
|
|
2061
|
-
}),
|
|
2064
|
+
}), xe = ({
|
|
2062
2065
|
event: e,
|
|
2063
2066
|
target: t
|
|
2064
2067
|
}) => {
|
|
2065
|
-
const n = t.getBoundingClientRect(), i = e.clientX - n.left, a = e.clientY - n.top, o =
|
|
2068
|
+
const n = t.getBoundingClientRect(), i = e.clientX - n.left, a = e.clientY - n.top, o = be(i / n.width), r = be(a / n.height);
|
|
2066
2069
|
return {
|
|
2067
2070
|
x: o,
|
|
2068
2071
|
y: r
|
|
2069
2072
|
};
|
|
2070
|
-
},
|
|
2071
|
-
const t = e.target, n = t &&
|
|
2073
|
+
}, Jt = (e) => {
|
|
2074
|
+
const t = e.target, n = t && Gt(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
|
|
2072
2075
|
return {
|
|
2073
2076
|
targetBuilderElement: i || void 0,
|
|
2074
2077
|
metadata: {
|
|
2075
|
-
targetOffset: t ?
|
|
2078
|
+
targetOffset: t ? xe({
|
|
2076
2079
|
event: e,
|
|
2077
2080
|
target: t
|
|
2078
2081
|
}) : void 0,
|
|
2079
|
-
builderTargetOffset: n ?
|
|
2082
|
+
builderTargetOffset: n ? xe({
|
|
2080
2083
|
event: e,
|
|
2081
2084
|
target: n
|
|
2082
2085
|
}) : void 0,
|
|
@@ -2084,41 +2087,41 @@ const Kt = (e, t, n = !0) => {
|
|
|
2084
2087
|
}
|
|
2085
2088
|
};
|
|
2086
2089
|
};
|
|
2087
|
-
function
|
|
2088
|
-
var
|
|
2089
|
-
const t =
|
|
2090
|
-
function a(
|
|
2091
|
-
var
|
|
2092
|
-
const
|
|
2090
|
+
function Yt(e) {
|
|
2091
|
+
var A, B, N, W, q;
|
|
2092
|
+
const t = Z(null), [n, i] = I(() => 0);
|
|
2093
|
+
function a(m) {
|
|
2094
|
+
var v, p, T, E, ae;
|
|
2095
|
+
const f = {
|
|
2093
2096
|
...e.builderContextSignal.content,
|
|
2094
|
-
...
|
|
2097
|
+
...m,
|
|
2095
2098
|
data: {
|
|
2096
|
-
...(
|
|
2097
|
-
...
|
|
2099
|
+
...(v = e.builderContextSignal.content) == null ? void 0 : v.data,
|
|
2100
|
+
...m == null ? void 0 : m.data
|
|
2098
2101
|
},
|
|
2099
2102
|
meta: {
|
|
2100
|
-
...(
|
|
2101
|
-
...
|
|
2102
|
-
breakpoints: ((T =
|
|
2103
|
+
...(p = e.builderContextSignal.content) == null ? void 0 : p.meta,
|
|
2104
|
+
...m == null ? void 0 : m.meta,
|
|
2105
|
+
breakpoints: ((T = m == null ? void 0 : m.meta) == null ? void 0 : T.breakpoints) || ((ae = (E = e.builderContextSignal.content) == null ? void 0 : E.meta) == null ? void 0 : ae.breakpoints)
|
|
2103
2106
|
}
|
|
2104
2107
|
};
|
|
2105
|
-
e.setBuilderContextSignal((
|
|
2106
|
-
...
|
|
2107
|
-
content:
|
|
2108
|
+
e.setBuilderContextSignal((Pe) => ({
|
|
2109
|
+
...Pe,
|
|
2110
|
+
content: f
|
|
2108
2111
|
}));
|
|
2109
2112
|
}
|
|
2110
2113
|
I(() => 0);
|
|
2111
2114
|
const [o, r] = I(
|
|
2112
2115
|
() => !1
|
|
2113
2116
|
);
|
|
2114
|
-
function d(
|
|
2115
|
-
var
|
|
2116
|
-
const { data:
|
|
2117
|
-
if (
|
|
2118
|
-
switch (
|
|
2117
|
+
function d(m) {
|
|
2118
|
+
var v;
|
|
2119
|
+
const { data: f } = m;
|
|
2120
|
+
if (f)
|
|
2121
|
+
switch (f.type) {
|
|
2119
2122
|
case "builder.configureSdk": {
|
|
2120
|
-
const
|
|
2121
|
-
if (
|
|
2123
|
+
const p = f.data, { breakpoints: T, contentId: E } = p;
|
|
2124
|
+
if (!E || E !== ((v = e.builderContextSignal.content) == null ? void 0 : v.id))
|
|
2122
2125
|
return;
|
|
2123
2126
|
T && a({
|
|
2124
2127
|
meta: {
|
|
@@ -2128,45 +2131,45 @@ function zt(e) {
|
|
|
2128
2131
|
break;
|
|
2129
2132
|
}
|
|
2130
2133
|
case "builder.contentUpdate": {
|
|
2131
|
-
const
|
|
2132
|
-
T === e.model && (a(
|
|
2134
|
+
const p = f.data, T = p.key || p.alias || p.entry || p.modelName, E = p.data;
|
|
2135
|
+
T === e.model && (a(E), i(n + 1));
|
|
2133
2136
|
break;
|
|
2134
2137
|
}
|
|
2135
2138
|
}
|
|
2136
2139
|
}
|
|
2137
|
-
function
|
|
2138
|
-
var
|
|
2139
|
-
const
|
|
2140
|
-
|
|
2141
|
-
code:
|
|
2140
|
+
function l() {
|
|
2141
|
+
var f, v;
|
|
2142
|
+
const m = (v = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : v.jsCode;
|
|
2143
|
+
m && j({
|
|
2144
|
+
code: m,
|
|
2142
2145
|
context: e.context || {},
|
|
2143
2146
|
localState: void 0,
|
|
2144
2147
|
rootState: e.builderContextSignal.rootState,
|
|
2145
2148
|
rootSetState: e.builderContextSignal.rootSetState
|
|
2146
2149
|
});
|
|
2147
2150
|
}
|
|
2148
|
-
const [s, u] = I(() => ({})), [
|
|
2149
|
-
function k(
|
|
2150
|
-
var
|
|
2151
|
+
const [s, u] = I(() => ({})), [h, y] = I(() => !1);
|
|
2152
|
+
function k(m) {
|
|
2153
|
+
var f, v;
|
|
2151
2154
|
if (e.builderContextSignal.content) {
|
|
2152
|
-
const
|
|
2153
|
-
|
|
2155
|
+
const p = (f = e.builderContextSignal.content) == null ? void 0 : f.testVariationId, T = (v = e.builderContextSignal.content) == null ? void 0 : v.id;
|
|
2156
|
+
re({
|
|
2154
2157
|
type: "click",
|
|
2155
|
-
canTrack:
|
|
2158
|
+
canTrack: U(e.canTrack),
|
|
2156
2159
|
contentId: T,
|
|
2157
2160
|
apiKey: e.apiKey,
|
|
2158
|
-
variationId:
|
|
2159
|
-
...
|
|
2160
|
-
unique: !
|
|
2161
|
+
variationId: p !== T ? p : void 0,
|
|
2162
|
+
...Jt(m),
|
|
2163
|
+
unique: !h
|
|
2161
2164
|
});
|
|
2162
2165
|
}
|
|
2163
|
-
|
|
2166
|
+
h || y(!0);
|
|
2164
2167
|
}
|
|
2165
|
-
function
|
|
2166
|
-
return
|
|
2168
|
+
function b(m) {
|
|
2169
|
+
return m.replace(
|
|
2167
2170
|
/{{([^}]+)}}/g,
|
|
2168
|
-
(
|
|
2169
|
-
code:
|
|
2171
|
+
(f, v) => j({
|
|
2172
|
+
code: v,
|
|
2170
2173
|
context: e.context || {},
|
|
2171
2174
|
localState: void 0,
|
|
2172
2175
|
rootState: e.builderContextSignal.rootState,
|
|
@@ -2174,38 +2177,38 @@ function zt(e) {
|
|
|
2174
2177
|
})
|
|
2175
2178
|
);
|
|
2176
2179
|
}
|
|
2177
|
-
function S({ url:
|
|
2178
|
-
|
|
2179
|
-
var T,
|
|
2180
|
-
const
|
|
2180
|
+
function S({ url: m, key: f }) {
|
|
2181
|
+
Ne(m).then((v) => v.json()).then((v) => {
|
|
2182
|
+
var T, E;
|
|
2183
|
+
const p = {
|
|
2181
2184
|
...e.builderContextSignal.rootState,
|
|
2182
|
-
[
|
|
2185
|
+
[f]: v
|
|
2183
2186
|
};
|
|
2184
|
-
(
|
|
2185
|
-
}).catch((
|
|
2186
|
-
console.error("error fetching dynamic data",
|
|
2187
|
+
(E = (T = e.builderContextSignal).rootSetState) == null || E.call(T, p), s[f] = !0;
|
|
2188
|
+
}).catch((v) => {
|
|
2189
|
+
console.error("error fetching dynamic data", m, v);
|
|
2187
2190
|
});
|
|
2188
2191
|
}
|
|
2189
|
-
function
|
|
2190
|
-
var
|
|
2191
|
-
const
|
|
2192
|
-
Object.entries(
|
|
2193
|
-
if (T && (!s[
|
|
2194
|
-
const
|
|
2192
|
+
function C() {
|
|
2193
|
+
var f, v;
|
|
2194
|
+
const m = ((v = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : v.httpRequests) ?? {};
|
|
2195
|
+
Object.entries(m).forEach(([p, T]) => {
|
|
2196
|
+
if (T && (!s[p] || V())) {
|
|
2197
|
+
const E = b(T);
|
|
2195
2198
|
S({
|
|
2196
|
-
url:
|
|
2197
|
-
key:
|
|
2199
|
+
url: E,
|
|
2200
|
+
key: p
|
|
2198
2201
|
});
|
|
2199
2202
|
}
|
|
2200
2203
|
});
|
|
2201
2204
|
}
|
|
2202
|
-
function
|
|
2205
|
+
function w() {
|
|
2203
2206
|
V() && window.dispatchEvent(
|
|
2204
2207
|
new CustomEvent(
|
|
2205
2208
|
"builder:component:stateChange",
|
|
2206
2209
|
{
|
|
2207
2210
|
detail: {
|
|
2208
|
-
state:
|
|
2211
|
+
state: ee(e.builderContextSignal.rootState),
|
|
2209
2212
|
ref: {
|
|
2210
2213
|
name: e.model
|
|
2211
2214
|
}
|
|
@@ -2214,90 +2217,119 @@ function zt(e) {
|
|
|
2214
2217
|
)
|
|
2215
2218
|
);
|
|
2216
2219
|
}
|
|
2220
|
+
function x(m) {
|
|
2221
|
+
i(n + 1), window.addEventListener("message", d), zt(), qt({
|
|
2222
|
+
...e.locale ? {
|
|
2223
|
+
locale: e.locale
|
|
2224
|
+
} : {},
|
|
2225
|
+
...e.includeRefs ? {
|
|
2226
|
+
includeRefs: e.includeRefs
|
|
2227
|
+
} : {},
|
|
2228
|
+
...e.enrich ? {
|
|
2229
|
+
enrich: e.enrich
|
|
2230
|
+
} : {}
|
|
2231
|
+
}), Object.values(
|
|
2232
|
+
e.builderContextSignal.componentInfos
|
|
2233
|
+
).forEach((f) => {
|
|
2234
|
+
var p;
|
|
2235
|
+
const v = Fe(f);
|
|
2236
|
+
(p = window.parent) == null || p.postMessage(v, "*");
|
|
2237
|
+
}), window.addEventListener(
|
|
2238
|
+
"builder:component:stateChangeListenerActivated",
|
|
2239
|
+
w
|
|
2240
|
+
);
|
|
2241
|
+
}
|
|
2242
|
+
function R(m) {
|
|
2243
|
+
const f = new URL(location.href).searchParams, v = f.get("builder.preview"), p = f.get(
|
|
2244
|
+
`builder.preview.${v}`
|
|
2245
|
+
), T = f.get("apiKey") || f.get("builder.space");
|
|
2246
|
+
v === e.model && T === e.apiKey && (!e.content || p === e.content.id) && pe({
|
|
2247
|
+
model: e.model,
|
|
2248
|
+
apiKey: e.apiKey,
|
|
2249
|
+
apiVersion: e.builderContextSignal.apiVersion
|
|
2250
|
+
}).then((E) => {
|
|
2251
|
+
E && a(E);
|
|
2252
|
+
});
|
|
2253
|
+
}
|
|
2217
2254
|
return P(() => {
|
|
2218
|
-
var
|
|
2219
|
-
|
|
2220
|
-
"
|
|
2221
|
-
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2255
|
+
var m;
|
|
2256
|
+
return (m = t.current) == null || m.addEventListener(
|
|
2257
|
+
"initeditingbldr",
|
|
2258
|
+
x
|
|
2259
|
+
), () => {
|
|
2260
|
+
var f;
|
|
2261
|
+
return (f = t.current) == null ? void 0 : f.removeEventListener(
|
|
2262
|
+
"initeditingbldr",
|
|
2263
|
+
x
|
|
2264
|
+
);
|
|
2265
|
+
};
|
|
2266
|
+
}, []), P(() => {
|
|
2267
|
+
var m;
|
|
2268
|
+
return (m = t.current) == null || m.addEventListener(
|
|
2269
|
+
"initpreviewingbldr",
|
|
2270
|
+
R
|
|
2271
|
+
), () => {
|
|
2272
|
+
var f;
|
|
2273
|
+
return (f = t.current) == null ? void 0 : f.removeEventListener(
|
|
2274
|
+
"initpreviewingbldr",
|
|
2275
|
+
R
|
|
2276
|
+
);
|
|
2277
|
+
};
|
|
2278
|
+
}, []), P(() => {
|
|
2279
|
+
var m, f;
|
|
2280
|
+
if (F()) {
|
|
2281
|
+
if (V() && t.current && t.current.dispatchEvent(new CustomEvent("initeditingbldr")), e.builderContextSignal.content && U(e.canTrack)) {
|
|
2282
|
+
const p = (m = e.builderContextSignal.content) == null ? void 0 : m.testVariationId, T = (f = e.builderContextSignal.content) == null ? void 0 : f.id, E = e.apiKey;
|
|
2283
|
+
re({
|
|
2244
2284
|
type: "impression",
|
|
2245
|
-
canTrack:
|
|
2246
|
-
contentId:
|
|
2247
|
-
apiKey:
|
|
2248
|
-
variationId:
|
|
2249
|
-
});
|
|
2250
|
-
}
|
|
2251
|
-
if (Ae()) {
|
|
2252
|
-
const x = new URL(location.href).searchParams, v = x.get("builder.preview"), T = x.get(
|
|
2253
|
-
`builder.preview.${v}`
|
|
2254
|
-
), $ = x.get("apiKey") || x.get("builder.space");
|
|
2255
|
-
v === e.model && $ === e.apiKey && (!e.content || T === e.content.id) && xe({
|
|
2256
|
-
model: e.model,
|
|
2257
|
-
apiKey: e.apiKey,
|
|
2258
|
-
apiVersion: e.builderContextSignal.apiVersion
|
|
2259
|
-
}).then((W) => {
|
|
2260
|
-
W && a(W);
|
|
2285
|
+
canTrack: !0,
|
|
2286
|
+
contentId: T,
|
|
2287
|
+
apiKey: E,
|
|
2288
|
+
variationId: p !== T ? p : void 0
|
|
2261
2289
|
});
|
|
2262
2290
|
}
|
|
2263
|
-
|
|
2291
|
+
Ve() && t.current && t.current.dispatchEvent(new CustomEvent("initpreviewingbldr"));
|
|
2264
2292
|
}
|
|
2293
|
+
}, []), P(() => {
|
|
2294
|
+
e.apiKey || _.error(
|
|
2295
|
+
"No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."
|
|
2296
|
+
), l(), C(), w();
|
|
2265
2297
|
}, []), P(() => {
|
|
2266
2298
|
e.content && a(e.content);
|
|
2267
2299
|
}, [e.content]), P(() => {
|
|
2268
2300
|
}, [o]), P(() => {
|
|
2269
|
-
|
|
2301
|
+
l();
|
|
2270
2302
|
}, [
|
|
2271
|
-
(
|
|
2303
|
+
(B = (A = e.builderContextSignal.content) == null ? void 0 : A.data) == null ? void 0 : B.jsCode,
|
|
2272
2304
|
e.builderContextSignal.rootState
|
|
2273
2305
|
]), P(() => {
|
|
2274
|
-
p();
|
|
2275
|
-
}, [(B = (A = e.builderContextSignal.content) == null ? void 0 : A.data) == null ? void 0 : B.httpRequests]), P(() => {
|
|
2276
2306
|
C();
|
|
2307
|
+
}, [(W = (N = e.builderContextSignal.content) == null ? void 0 : N.data) == null ? void 0 : W.httpRequests]), P(() => {
|
|
2308
|
+
w();
|
|
2277
2309
|
}, [e.builderContextSignal.rootState]), P(() => () => {
|
|
2278
2310
|
F() && (window.removeEventListener("message", d), window.removeEventListener(
|
|
2279
2311
|
"builder:component:stateChangeListenerActivated",
|
|
2280
|
-
|
|
2312
|
+
w
|
|
2281
2313
|
));
|
|
2282
|
-
}, []), /* @__PURE__ */
|
|
2314
|
+
}, []), /* @__PURE__ */ c(ne.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ ve(
|
|
2283
2315
|
"div",
|
|
2284
2316
|
{
|
|
2317
|
+
key: n,
|
|
2285
2318
|
ref: t,
|
|
2286
|
-
onClick: (
|
|
2287
|
-
"builder-content-id": (
|
|
2319
|
+
onClick: (m) => k(m),
|
|
2320
|
+
"builder-content-id": (q = e.builderContextSignal.content) == null ? void 0 : q.id,
|
|
2288
2321
|
"builder-model": e.model,
|
|
2289
2322
|
...e.showContent ? {} : {
|
|
2290
2323
|
hidden: !0,
|
|
2291
2324
|
"aria-hidden": !0
|
|
2292
2325
|
},
|
|
2293
|
-
className: e.classNameProp
|
|
2294
|
-
children: e.children
|
|
2326
|
+
className: e.classNameProp
|
|
2295
2327
|
},
|
|
2296
|
-
|
|
2328
|
+
e.children
|
|
2297
2329
|
) }) : null });
|
|
2298
2330
|
}
|
|
2299
|
-
function
|
|
2300
|
-
return /* @__PURE__ */
|
|
2331
|
+
function X(e) {
|
|
2332
|
+
return /* @__PURE__ */ c(
|
|
2301
2333
|
"script",
|
|
2302
2334
|
{
|
|
2303
2335
|
dangerouslySetInnerHTML: { __html: e.scriptStr },
|
|
@@ -2305,52 +2337,52 @@ function Q(e) {
|
|
|
2305
2337
|
}
|
|
2306
2338
|
);
|
|
2307
2339
|
}
|
|
2308
|
-
function
|
|
2309
|
-
var
|
|
2340
|
+
function ye(e) {
|
|
2341
|
+
var l, s, u, h, y, k, b;
|
|
2310
2342
|
const [t, n] = I(
|
|
2311
2343
|
() => {
|
|
2312
|
-
var S,
|
|
2313
|
-
return
|
|
2344
|
+
var S, C;
|
|
2345
|
+
return St({
|
|
2314
2346
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2315
2347
|
variationId: (S = e.content) == null ? void 0 : S.testVariationId,
|
|
2316
2348
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2317
|
-
contentId: (
|
|
2349
|
+
contentId: (C = e.content) == null ? void 0 : C.id
|
|
2318
2350
|
});
|
|
2319
2351
|
}
|
|
2320
2352
|
);
|
|
2321
2353
|
function i(S) {
|
|
2322
|
-
d((
|
|
2323
|
-
...
|
|
2354
|
+
d((C) => ({
|
|
2355
|
+
...C,
|
|
2324
2356
|
rootState: S
|
|
2325
2357
|
}));
|
|
2326
2358
|
}
|
|
2327
2359
|
const [a, o] = I(
|
|
2328
2360
|
() => [
|
|
2329
|
-
...
|
|
2361
|
+
...he(),
|
|
2330
2362
|
// While this `components` object is deprecated, we must maintain support for it.
|
|
2331
2363
|
// Since users are able to override our default components, we need to make sure that we do not break such
|
|
2332
2364
|
// existing usage.
|
|
2333
2365
|
// This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
|
|
2334
2366
|
// which is the new standard way of providing custom components, and must therefore take precedence.
|
|
2335
|
-
...
|
|
2367
|
+
...le,
|
|
2336
2368
|
...e.customComponents || []
|
|
2337
2369
|
].reduce(
|
|
2338
|
-
(S, { component:
|
|
2370
|
+
(S, { component: C, ...w }) => ({
|
|
2339
2371
|
...S,
|
|
2340
|
-
[
|
|
2341
|
-
component:
|
|
2342
|
-
...
|
|
2372
|
+
[w.name]: {
|
|
2373
|
+
component: C,
|
|
2374
|
+
...ce(w)
|
|
2343
2375
|
}
|
|
2344
2376
|
}),
|
|
2345
2377
|
{}
|
|
2346
2378
|
)
|
|
2347
2379
|
), [r, d] = I(() => ({
|
|
2348
|
-
content:
|
|
2380
|
+
content: Ot({
|
|
2349
2381
|
content: e.content,
|
|
2350
2382
|
data: e.data
|
|
2351
2383
|
}),
|
|
2352
2384
|
localState: void 0,
|
|
2353
|
-
rootState:
|
|
2385
|
+
rootState: Kt({
|
|
2354
2386
|
content: e.content,
|
|
2355
2387
|
data: e.data,
|
|
2356
2388
|
locale: e.locale
|
|
@@ -2360,31 +2392,31 @@ function ge(e) {
|
|
|
2360
2392
|
apiKey: e.apiKey,
|
|
2361
2393
|
apiVersion: e.apiVersion,
|
|
2362
2394
|
componentInfos: [
|
|
2363
|
-
...
|
|
2395
|
+
...he(),
|
|
2364
2396
|
// While this `components` object is deprecated, we must maintain support for it.
|
|
2365
2397
|
// Since users are able to override our default components, we need to make sure that we do not break such
|
|
2366
2398
|
// existing usage.
|
|
2367
2399
|
// This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
|
|
2368
2400
|
// which is the new standard way of providing custom components, and must therefore take precedence.
|
|
2369
|
-
...
|
|
2401
|
+
...le,
|
|
2370
2402
|
...e.customComponents || []
|
|
2371
2403
|
].reduce(
|
|
2372
|
-
(S, { component:
|
|
2404
|
+
(S, { component: C, ...w }) => ({
|
|
2373
2405
|
...S,
|
|
2374
|
-
[
|
|
2406
|
+
[w.name]: ce(w)
|
|
2375
2407
|
}),
|
|
2376
2408
|
{}
|
|
2377
2409
|
),
|
|
2378
2410
|
inheritedStyles: {}
|
|
2379
2411
|
}));
|
|
2380
|
-
return /* @__PURE__ */
|
|
2381
|
-
|
|
2412
|
+
return /* @__PURE__ */ c(
|
|
2413
|
+
Ie.Provider,
|
|
2382
2414
|
{
|
|
2383
2415
|
value: {
|
|
2384
2416
|
registeredComponents: a
|
|
2385
2417
|
},
|
|
2386
|
-
children: /* @__PURE__ */
|
|
2387
|
-
|
|
2418
|
+
children: /* @__PURE__ */ $(
|
|
2419
|
+
Yt,
|
|
2388
2420
|
{
|
|
2389
2421
|
content: e.content,
|
|
2390
2422
|
model: e.model,
|
|
@@ -2399,19 +2431,19 @@ function ge(e) {
|
|
|
2399
2431
|
builderContextSignal: r,
|
|
2400
2432
|
setBuilderContextSignal: d,
|
|
2401
2433
|
children: [
|
|
2402
|
-
e.isSsrAbTest ? /* @__PURE__ */
|
|
2403
|
-
/* @__PURE__ */
|
|
2404
|
-
|
|
2434
|
+
e.isSsrAbTest ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(X, { scriptStr: t }) }) : null,
|
|
2435
|
+
/* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
|
|
2436
|
+
Ut,
|
|
2405
2437
|
{
|
|
2406
|
-
contentId: (
|
|
2438
|
+
contentId: (l = r.content) == null ? void 0 : l.id,
|
|
2407
2439
|
cssCode: (u = (s = r.content) == null ? void 0 : s.data) == null ? void 0 : u.cssCode,
|
|
2408
|
-
customFonts: (y = (
|
|
2440
|
+
customFonts: (y = (h = r.content) == null ? void 0 : h.data) == null ? void 0 : y.customFonts
|
|
2409
2441
|
}
|
|
2410
2442
|
) }),
|
|
2411
|
-
/* @__PURE__ */
|
|
2412
|
-
|
|
2443
|
+
/* @__PURE__ */ c(
|
|
2444
|
+
ie,
|
|
2413
2445
|
{
|
|
2414
|
-
blocks: (
|
|
2446
|
+
blocks: (b = (k = r.content) == null ? void 0 : k.data) == null ? void 0 : b.blocks,
|
|
2415
2447
|
context: r,
|
|
2416
2448
|
registeredComponents: a
|
|
2417
2449
|
}
|
|
@@ -2422,17 +2454,17 @@ function ge(e) {
|
|
|
2422
2454
|
}
|
|
2423
2455
|
);
|
|
2424
2456
|
}
|
|
2425
|
-
function
|
|
2426
|
-
var r, d,
|
|
2457
|
+
function $e(e) {
|
|
2458
|
+
var r, d, l;
|
|
2427
2459
|
const [t, n] = I(
|
|
2428
|
-
() =>
|
|
2429
|
-
canTrack:
|
|
2460
|
+
() => ft({
|
|
2461
|
+
canTrack: U(e.canTrack),
|
|
2430
2462
|
content: e.content
|
|
2431
2463
|
})
|
|
2432
2464
|
);
|
|
2433
2465
|
function i() {
|
|
2434
2466
|
var s;
|
|
2435
|
-
return
|
|
2467
|
+
return yt(
|
|
2436
2468
|
L(e.content).map((u) => ({
|
|
2437
2469
|
id: u.testVariationId,
|
|
2438
2470
|
testRatio: u.testRatio
|
|
@@ -2448,25 +2480,25 @@ function Ie(e) {
|
|
|
2448
2480
|
return t ? {
|
|
2449
2481
|
...e.content,
|
|
2450
2482
|
testVariationId: (s = e.content) == null ? void 0 : s.id
|
|
2451
|
-
} :
|
|
2483
|
+
} : We({
|
|
2452
2484
|
item: e.content,
|
|
2453
|
-
canTrack:
|
|
2485
|
+
canTrack: U(e.canTrack)
|
|
2454
2486
|
});
|
|
2455
2487
|
}
|
|
2456
2488
|
return P(() => {
|
|
2457
|
-
}, []), /* @__PURE__ */
|
|
2458
|
-
!e.__isNestedRender && M !== "reactNative" ? /* @__PURE__ */
|
|
2459
|
-
t ? /* @__PURE__ */
|
|
2460
|
-
/* @__PURE__ */
|
|
2489
|
+
}, []), /* @__PURE__ */ $(g, { children: [
|
|
2490
|
+
!e.__isNestedRender && M !== "reactNative" ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(X, { scriptStr: xt() }) }) : null,
|
|
2491
|
+
t ? /* @__PURE__ */ $(g, { children: [
|
|
2492
|
+
/* @__PURE__ */ c(
|
|
2461
2493
|
H,
|
|
2462
2494
|
{
|
|
2463
2495
|
id: `variants-styles-${(r = e.content) == null ? void 0 : r.id}`,
|
|
2464
2496
|
styles: a()
|
|
2465
2497
|
}
|
|
2466
2498
|
),
|
|
2467
|
-
/* @__PURE__ */
|
|
2468
|
-
(d = L(e.content)) == null ? void 0 : d.map((s) => /* @__PURE__ */
|
|
2469
|
-
|
|
2499
|
+
/* @__PURE__ */ c(X, { scriptStr: i() }),
|
|
2500
|
+
(d = L(e.content)) == null ? void 0 : d.map((s) => /* @__PURE__ */ c(
|
|
2501
|
+
ye,
|
|
2470
2502
|
{
|
|
2471
2503
|
content: s,
|
|
2472
2504
|
showContent: !1,
|
|
@@ -2486,11 +2518,11 @@ function Ie(e) {
|
|
|
2486
2518
|
s.testVariationId
|
|
2487
2519
|
))
|
|
2488
2520
|
] }) : null,
|
|
2489
|
-
/* @__PURE__ */
|
|
2490
|
-
|
|
2521
|
+
/* @__PURE__ */ c(
|
|
2522
|
+
ye,
|
|
2491
2523
|
{
|
|
2492
2524
|
content: o(),
|
|
2493
|
-
classNameProp: `variant-${(
|
|
2525
|
+
classNameProp: `variant-${(l = e.content) == null ? void 0 : l.id}`,
|
|
2494
2526
|
showContent: !0,
|
|
2495
2527
|
model: e.model,
|
|
2496
2528
|
data: e.data,
|
|
@@ -2507,13 +2539,13 @@ function Ie(e) {
|
|
|
2507
2539
|
)
|
|
2508
2540
|
] });
|
|
2509
2541
|
}
|
|
2510
|
-
const
|
|
2542
|
+
const Qt = async ({
|
|
2511
2543
|
builderContextValue: e,
|
|
2512
2544
|
symbol: t
|
|
2513
2545
|
}) => {
|
|
2514
2546
|
if (t != null && t.model && // This is a hack, we should not need to check for this, but it is needed for Svelte.
|
|
2515
2547
|
(e != null && e.apiKey))
|
|
2516
|
-
return
|
|
2548
|
+
return pe({
|
|
2517
2549
|
model: t.model,
|
|
2518
2550
|
apiKey: e.apiKey,
|
|
2519
2551
|
apiVersion: e.apiVersion,
|
|
@@ -2523,38 +2555,38 @@ const qt = async ({
|
|
|
2523
2555
|
}
|
|
2524
2556
|
}
|
|
2525
2557
|
}).catch((n) => {
|
|
2526
|
-
|
|
2558
|
+
_.error("Could not fetch symbol content: ", n);
|
|
2527
2559
|
});
|
|
2528
2560
|
};
|
|
2529
|
-
function
|
|
2561
|
+
function Xt(e) {
|
|
2530
2562
|
var o, r, d;
|
|
2531
2563
|
function t() {
|
|
2532
|
-
var
|
|
2564
|
+
var l, s;
|
|
2533
2565
|
return [
|
|
2534
2566
|
e.attributes.className,
|
|
2535
2567
|
"builder-symbol",
|
|
2536
|
-
(
|
|
2568
|
+
(l = e.symbol) != null && l.inline ? "builder-inline-symbol" : void 0,
|
|
2537
2569
|
(s = e.symbol) != null && s.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
|
|
2538
2570
|
].filter(Boolean).join(" ");
|
|
2539
2571
|
}
|
|
2540
2572
|
const [n, i] = I(() => {
|
|
2541
|
-
var
|
|
2542
|
-
return (
|
|
2573
|
+
var l;
|
|
2574
|
+
return (l = e.symbol) == null ? void 0 : l.content;
|
|
2543
2575
|
});
|
|
2544
2576
|
function a() {
|
|
2545
|
-
n ||
|
|
2577
|
+
n || Qt({
|
|
2546
2578
|
symbol: e.symbol,
|
|
2547
2579
|
builderContextValue: e.builderContext
|
|
2548
|
-
}).then((
|
|
2549
|
-
|
|
2580
|
+
}).then((l) => {
|
|
2581
|
+
l && i(l);
|
|
2550
2582
|
});
|
|
2551
2583
|
}
|
|
2552
2584
|
return P(() => {
|
|
2553
2585
|
a();
|
|
2554
2586
|
}, []), P(() => {
|
|
2555
2587
|
a();
|
|
2556
|
-
}, [e.symbol]), /* @__PURE__ */
|
|
2557
|
-
|
|
2588
|
+
}, [e.symbol]), /* @__PURE__ */ c("div", { ...e.attributes, className: t(), children: /* @__PURE__ */ c(
|
|
2589
|
+
$e,
|
|
2558
2590
|
{
|
|
2559
2591
|
__isNestedRender: !0,
|
|
2560
2592
|
apiVersion: e.builderContext.apiVersion,
|
|
@@ -2571,31 +2603,31 @@ function Dt(e) {
|
|
|
2571
2603
|
}
|
|
2572
2604
|
) });
|
|
2573
2605
|
}
|
|
2574
|
-
const
|
|
2606
|
+
const nn = ie, an = $e;
|
|
2575
2607
|
export {
|
|
2576
|
-
|
|
2577
|
-
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
|
|
2581
|
-
|
|
2582
|
-
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2587
|
-
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
|
|
2592
|
-
|
|
2593
|
-
|
|
2594
|
-
|
|
2595
|
-
|
|
2608
|
+
ie as Blocks,
|
|
2609
|
+
je as Button,
|
|
2610
|
+
lt as Columns,
|
|
2611
|
+
$e as Content,
|
|
2612
|
+
ct as Fragment,
|
|
2613
|
+
ut as Image,
|
|
2614
|
+
nn as RenderBlocks,
|
|
2615
|
+
an as RenderContent,
|
|
2616
|
+
mt as Section,
|
|
2617
|
+
Xt as Symbol,
|
|
2618
|
+
Rt as Text,
|
|
2619
|
+
$t as Video,
|
|
2620
|
+
ln as _processContentResult,
|
|
2621
|
+
Fe as createRegisterComponentMessage,
|
|
2622
|
+
cn as fetchBuilderProps,
|
|
2623
|
+
sn as fetchEntries,
|
|
2624
|
+
pe as fetchOneEntry,
|
|
2625
|
+
dn as getAllContent,
|
|
2626
|
+
un as getBuilderSearchParams,
|
|
2627
|
+
mn as getContent,
|
|
2596
2628
|
V as isEditing,
|
|
2597
|
-
|
|
2598
|
-
|
|
2599
|
-
|
|
2600
|
-
|
|
2629
|
+
Ve as isPreviewing,
|
|
2630
|
+
Be as register,
|
|
2631
|
+
fn as setEditorSettings,
|
|
2632
|
+
hn as track
|
|
2601
2633
|
};
|