@builder.io/sdk-react 0.11.3 → 0.11.4
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 +24 -24
- package/lib/browser/index.mjs +539 -520
- package/lib/edge/index.cjs +20 -20
- package/lib/edge/index.mjs +1036 -1017
- package/lib/node/index.cjs +12 -12
- package/lib/node/index.mjs +265 -246
- package/package.json +1 -1
- package/types/components/content/components/enable-editor.d.ts +1 -1
- package/types/components/content/content.helpers.d.ts +1 -1
- package/types/constants/sdk-version.d.ts +1 -1
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__ */ c(
|
|
2
|
+
import { jsxs as P, Fragment as h, jsx as c } from "react/jsx-runtime";
|
|
3
|
+
import { createContext as Ce, useState as S, useContext as se, createElement as we, useRef as ee, useEffect as E } from "react";
|
|
4
|
+
import { i as V, j as $, k as Ne, l as U, m as te, n as J, T as L, r as Fe, o as D, p as de, a as _e, c as Le, b as Ie, q as je, u as ue, v as me, w as Me } from "./server-entry-f978b3a5.js";
|
|
5
|
+
import { _ as mn, h as fn, f as hn, g as gn, e as bn, d as xn, s as yn, t as Sn } from "./server-entry-f978b3a5.js";
|
|
6
|
+
function Ue(e) {
|
|
7
|
+
return /* @__PURE__ */ P(h, { children: [
|
|
8
|
+
e.link ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
9
9
|
"a",
|
|
10
10
|
{
|
|
11
11
|
...e.attributes,
|
|
@@ -14,7 +14,7 @@ function Me(e) {
|
|
|
14
14
|
role: "button",
|
|
15
15
|
children: e.text
|
|
16
16
|
}
|
|
17
|
-
) }) : /* @__PURE__ */ c(
|
|
17
|
+
) }) : /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
18
18
|
"button",
|
|
19
19
|
{
|
|
20
20
|
...e.attributes,
|
|
@@ -28,7 +28,7 @@ function Me(e) {
|
|
|
28
28
|
}` })
|
|
29
29
|
] });
|
|
30
30
|
}
|
|
31
|
-
const ne =
|
|
31
|
+
const ne = Ce({
|
|
32
32
|
content: null,
|
|
33
33
|
context: {},
|
|
34
34
|
localState: void 0,
|
|
@@ -41,8 +41,8 @@ const ne = ke({
|
|
|
41
41
|
inheritedStyles: {},
|
|
42
42
|
BlocksWrapper: "div",
|
|
43
43
|
BlocksWrapperProps: {}
|
|
44
|
-
}),
|
|
45
|
-
function
|
|
44
|
+
}), Te = Ce({ registeredComponents: {} });
|
|
45
|
+
function De(e) {
|
|
46
46
|
var t;
|
|
47
47
|
return {
|
|
48
48
|
...(t = e.component) == null ? void 0 : t.options,
|
|
@@ -53,7 +53,7 @@ function Ue(e) {
|
|
|
53
53
|
builderBlock: e
|
|
54
54
|
};
|
|
55
55
|
}
|
|
56
|
-
const
|
|
56
|
+
const Oe = ({
|
|
57
57
|
builder: e,
|
|
58
58
|
context: t,
|
|
59
59
|
event: n,
|
|
@@ -65,69 +65,69 @@ const De = ({
|
|
|
65
65
|
builder: e,
|
|
66
66
|
context: t,
|
|
67
67
|
event: n
|
|
68
|
-
}),
|
|
68
|
+
}), Ke = () => ({
|
|
69
69
|
isEditing: V(),
|
|
70
70
|
isBrowser: $(),
|
|
71
71
|
isServer: !$(),
|
|
72
|
-
getUserAttributes: () =>
|
|
73
|
-
}),
|
|
72
|
+
getUserAttributes: () => Ne()
|
|
73
|
+
}), He = (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, fe = ({
|
|
76
76
|
code: e,
|
|
77
77
|
builder: t,
|
|
78
78
|
context: n,
|
|
79
79
|
event: i,
|
|
80
80
|
localState: a,
|
|
81
|
-
rootSetState:
|
|
82
|
-
rootState:
|
|
81
|
+
rootSetState: o,
|
|
82
|
+
rootState: r
|
|
83
83
|
}) => {
|
|
84
|
-
const s =
|
|
84
|
+
const s = Oe({
|
|
85
85
|
builder: t,
|
|
86
86
|
context: n,
|
|
87
87
|
event: i,
|
|
88
|
-
state:
|
|
88
|
+
state: ze(r, a, o)
|
|
89
89
|
});
|
|
90
90
|
return new Function(...s.map(([l]) => l), e)(...s.map(([, l]) => l));
|
|
91
91
|
};
|
|
92
|
-
function
|
|
92
|
+
function ze(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, o) => {
|
|
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] = o, n == null || n(e), !0;
|
|
101
101
|
}
|
|
102
102
|
});
|
|
103
103
|
}
|
|
104
|
-
const
|
|
104
|
+
const qe = (e) => ($(), fe(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:
|
|
112
|
-
isExpression:
|
|
111
|
+
event: o,
|
|
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
118
|
const s = {
|
|
119
|
-
code:
|
|
120
|
-
isExpression:
|
|
119
|
+
code: He(e, {
|
|
120
|
+
isExpression: r
|
|
121
121
|
}),
|
|
122
|
-
builder:
|
|
122
|
+
builder: Ke(),
|
|
123
123
|
context: t,
|
|
124
|
-
event:
|
|
124
|
+
event: o,
|
|
125
125
|
rootSetState: a,
|
|
126
126
|
rootState: i,
|
|
127
127
|
localState: n
|
|
128
128
|
};
|
|
129
129
|
try {
|
|
130
|
-
return
|
|
130
|
+
return qe(s);
|
|
131
131
|
} catch (l) {
|
|
132
132
|
U.error("Failed code evaluation: " + l.message, {
|
|
133
133
|
code: e
|
|
@@ -135,13 +135,13 @@ function _({
|
|
|
135
135
|
return;
|
|
136
136
|
}
|
|
137
137
|
}
|
|
138
|
-
const
|
|
138
|
+
const Ye = (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, 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;
|
|
143
143
|
};
|
|
144
|
-
const
|
|
144
|
+
const Qe = ({
|
|
145
145
|
block: e,
|
|
146
146
|
context: t,
|
|
147
147
|
localState: n,
|
|
@@ -150,13 +150,13 @@ const Ye = ({
|
|
|
150
150
|
}) => {
|
|
151
151
|
if (!e.bindings)
|
|
152
152
|
return e;
|
|
153
|
-
const
|
|
154
|
-
...
|
|
153
|
+
const o = te(e), r = {
|
|
154
|
+
...o,
|
|
155
155
|
properties: {
|
|
156
|
-
...
|
|
156
|
+
...o.properties
|
|
157
157
|
},
|
|
158
158
|
actions: {
|
|
159
|
-
...
|
|
159
|
+
...o.actions
|
|
160
160
|
}
|
|
161
161
|
};
|
|
162
162
|
for (const s in e.bindings) {
|
|
@@ -167,9 +167,9 @@ const Ye = ({
|
|
|
167
167
|
rootSetState: a,
|
|
168
168
|
context: t
|
|
169
169
|
});
|
|
170
|
-
|
|
170
|
+
Ye(r, s, d);
|
|
171
171
|
}
|
|
172
|
-
return
|
|
172
|
+
return r;
|
|
173
173
|
};
|
|
174
174
|
function O({
|
|
175
175
|
block: e,
|
|
@@ -177,31 +177,31 @@ function O({
|
|
|
177
177
|
shouldEvaluateBindings: n,
|
|
178
178
|
localState: i,
|
|
179
179
|
rootState: a,
|
|
180
|
-
rootSetState:
|
|
180
|
+
rootSetState: o
|
|
181
181
|
}) {
|
|
182
|
-
const
|
|
183
|
-
return n ?
|
|
184
|
-
block:
|
|
182
|
+
const r = e;
|
|
183
|
+
return n ? Qe({
|
|
184
|
+
block: r,
|
|
185
185
|
localState: i,
|
|
186
186
|
rootState: a,
|
|
187
|
-
rootSetState:
|
|
187
|
+
rootSetState: o,
|
|
188
188
|
context: t
|
|
189
|
-
}) :
|
|
189
|
+
}) : r;
|
|
190
190
|
}
|
|
191
|
-
const
|
|
191
|
+
const Ge = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"], Y = (e) => typeof e == "string" && Ge.includes(e.toLowerCase()), Je = ({
|
|
192
192
|
block: e,
|
|
193
193
|
context: t,
|
|
194
194
|
registeredComponents: n
|
|
195
195
|
}) => {
|
|
196
|
-
var
|
|
197
|
-
const i = (
|
|
196
|
+
var o;
|
|
197
|
+
const i = (o = O({
|
|
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 : o.name;
|
|
205
205
|
if (!i)
|
|
206
206
|
return null;
|
|
207
207
|
const a = n[i];
|
|
@@ -210,7 +210,7 @@ const Qe = ["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
|
+
}, Xe = ({
|
|
214
214
|
block: e,
|
|
215
215
|
context: t
|
|
216
216
|
}) => {
|
|
@@ -229,7 +229,7 @@ const Qe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
229
229
|
});
|
|
230
230
|
if (!Array.isArray(a))
|
|
231
231
|
return;
|
|
232
|
-
const
|
|
232
|
+
const o = n.collection.split(".").pop(), r = n.itemName || (o ? o + "Item" : "item");
|
|
233
233
|
return a.map((l, d) => ({
|
|
234
234
|
context: {
|
|
235
235
|
...t,
|
|
@@ -237,13 +237,13 @@ const Qe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
237
237
|
...t.localState,
|
|
238
238
|
$index: d,
|
|
239
239
|
$item: l,
|
|
240
|
-
[
|
|
241
|
-
[`$${
|
|
240
|
+
[r]: l,
|
|
241
|
+
[`$${r}Index`]: d
|
|
242
242
|
}
|
|
243
243
|
},
|
|
244
244
|
block: i
|
|
245
245
|
}));
|
|
246
|
-
},
|
|
246
|
+
}, Re = {
|
|
247
247
|
small: {
|
|
248
248
|
min: 320,
|
|
249
249
|
default: 321,
|
|
@@ -259,11 +259,11 @@ const Qe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
259
259
|
default: 991,
|
|
260
260
|
max: 1200
|
|
261
261
|
}
|
|
262
|
-
},
|
|
262
|
+
}, he = (e, t = Re) => `@media (max-width: ${t[e].max}px)`, Ee = ({
|
|
263
263
|
small: e,
|
|
264
264
|
medium: t
|
|
265
265
|
}) => {
|
|
266
|
-
const n = te(
|
|
266
|
+
const n = te(Re);
|
|
267
267
|
if (!e || !t)
|
|
268
268
|
return n;
|
|
269
269
|
const i = Math.floor(e / 2);
|
|
@@ -278,24 +278,24 @@ const Qe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
278
278
|
min: a,
|
|
279
279
|
default: a + 1
|
|
280
280
|
};
|
|
281
|
-
const
|
|
281
|
+
const o = 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: o,
|
|
286
|
+
default: o + 1
|
|
287
287
|
}, n;
|
|
288
|
-
},
|
|
288
|
+
}, Ze = (e) => e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase(), Pe = (e) => Object.entries(e).map(([n, i]) => {
|
|
289
289
|
if (typeof i == "string")
|
|
290
|
-
return `${
|
|
291
|
-
}).filter(J),
|
|
290
|
+
return `${Ze(n)}: ${i};`;
|
|
291
|
+
}).filter(J), et = (e) => Pe(e).join(`
|
|
292
292
|
`), Q = ({
|
|
293
293
|
mediaQuery: e,
|
|
294
294
|
className: t,
|
|
295
295
|
styles: n
|
|
296
296
|
}) => {
|
|
297
297
|
const i = `.${t} {
|
|
298
|
-
${
|
|
298
|
+
${et(n)}
|
|
299
299
|
}`;
|
|
300
300
|
return e ? `${e} {
|
|
301
301
|
${i}
|
|
@@ -304,7 +304,7 @@ const Qe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
304
304
|
function H(e) {
|
|
305
305
|
return /* @__PURE__ */ c("style", { dangerouslySetInnerHTML: { __html: e.styles }, id: e.id });
|
|
306
306
|
}
|
|
307
|
-
function
|
|
307
|
+
function tt(e) {
|
|
308
308
|
function t() {
|
|
309
309
|
const i = O({
|
|
310
310
|
block: e.block,
|
|
@@ -317,7 +317,7 @@ function et(e) {
|
|
|
317
317
|
return J(i.hide) ? !i.hide : J(i.show) ? i.show : !0;
|
|
318
318
|
}
|
|
319
319
|
function n() {
|
|
320
|
-
var
|
|
320
|
+
var C;
|
|
321
321
|
const i = O({
|
|
322
322
|
block: e.block,
|
|
323
323
|
localState: e.context.localState,
|
|
@@ -325,37 +325,37 @@ function et(e) {
|
|
|
325
325
|
rootSetState: e.context.rootSetState,
|
|
326
326
|
context: e.context.context,
|
|
327
327
|
shouldEvaluateBindings: !0
|
|
328
|
-
}), a = i.responsiveStyles,
|
|
329
|
-
((
|
|
328
|
+
}), a = i.responsiveStyles, o = e.context.content, r = Ee(
|
|
329
|
+
((C = o == null ? void 0 : o.meta) == null ? void 0 : C.breakpoints) || {}
|
|
330
330
|
), s = a == null ? void 0 : a.large, l = a == null ? void 0 : a.medium, d = a == null ? void 0 : a.small, u = i.id;
|
|
331
331
|
if (!u)
|
|
332
332
|
return "";
|
|
333
|
-
const
|
|
333
|
+
const b = s ? Q({
|
|
334
334
|
className: u,
|
|
335
335
|
styles: s
|
|
336
|
-
}) : "",
|
|
336
|
+
}) : "", v = l ? Q({
|
|
337
337
|
className: u,
|
|
338
338
|
styles: l,
|
|
339
|
-
mediaQuery:
|
|
339
|
+
mediaQuery: he(
|
|
340
340
|
"medium",
|
|
341
|
-
|
|
341
|
+
r
|
|
342
342
|
)
|
|
343
|
-
}) : "",
|
|
343
|
+
}) : "", y = d ? Q({
|
|
344
344
|
className: u,
|
|
345
345
|
styles: d,
|
|
346
|
-
mediaQuery:
|
|
346
|
+
mediaQuery: he(
|
|
347
347
|
"small",
|
|
348
|
-
|
|
348
|
+
r
|
|
349
349
|
)
|
|
350
350
|
}) : "";
|
|
351
|
-
return [
|
|
351
|
+
return [b, v, y].join(" ");
|
|
352
352
|
}
|
|
353
|
-
return /* @__PURE__ */ c(
|
|
353
|
+
return /* @__PURE__ */ c(h, { children: n() && t() ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(H, { styles: n() }) }) : null });
|
|
354
354
|
}
|
|
355
|
-
function
|
|
355
|
+
function nt(e) {
|
|
356
356
|
return e.charAt(0).toUpperCase() + e.slice(1);
|
|
357
357
|
}
|
|
358
|
-
const
|
|
358
|
+
const it = (e) => `on${nt(e)}`, at = (e, t) => (n) => _({
|
|
359
359
|
code: e,
|
|
360
360
|
context: t.context,
|
|
361
361
|
localState: t.localState,
|
|
@@ -370,27 +370,27 @@ function X(e) {
|
|
|
370
370
|
for (const a in n) {
|
|
371
371
|
if (!n.hasOwnProperty(a))
|
|
372
372
|
continue;
|
|
373
|
-
const
|
|
374
|
-
let
|
|
373
|
+
const o = n[a];
|
|
374
|
+
let r = it(a);
|
|
375
375
|
if (e.stripPrefix)
|
|
376
376
|
switch (L) {
|
|
377
377
|
case "vue":
|
|
378
|
-
|
|
378
|
+
r = r.replace("v-on:", "");
|
|
379
379
|
break;
|
|
380
380
|
case "svelte":
|
|
381
|
-
|
|
381
|
+
r = r.replace("on:", "");
|
|
382
382
|
break;
|
|
383
383
|
}
|
|
384
|
-
t[
|
|
384
|
+
t[r] = at(o, e);
|
|
385
385
|
}
|
|
386
386
|
return t;
|
|
387
387
|
}
|
|
388
|
-
function
|
|
388
|
+
function ot({
|
|
389
389
|
properties: e
|
|
390
390
|
}) {
|
|
391
391
|
return e.className = e.class, delete e.class, e;
|
|
392
392
|
}
|
|
393
|
-
const
|
|
393
|
+
const rt = (e) => ({
|
|
394
394
|
href: e.href
|
|
395
395
|
});
|
|
396
396
|
function K({
|
|
@@ -399,24 +399,24 @@ function K({
|
|
|
399
399
|
}) {
|
|
400
400
|
var i;
|
|
401
401
|
const n = {
|
|
402
|
-
...
|
|
402
|
+
...rt(e),
|
|
403
403
|
...e.properties,
|
|
404
404
|
"builder-id": e.id,
|
|
405
|
-
style: e.style ?
|
|
405
|
+
style: e.style ? ct(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 ot({
|
|
409
409
|
properties: n,
|
|
410
410
|
context: t,
|
|
411
411
|
block: e
|
|
412
412
|
});
|
|
413
413
|
}
|
|
414
|
-
function
|
|
414
|
+
function ct(e) {
|
|
415
415
|
switch (L) {
|
|
416
416
|
case "svelte":
|
|
417
417
|
case "vue":
|
|
418
418
|
case "solid":
|
|
419
|
-
return
|
|
419
|
+
return Pe(e).join(" ");
|
|
420
420
|
case "qwik":
|
|
421
421
|
case "reactNative":
|
|
422
422
|
case "react":
|
|
@@ -424,10 +424,10 @@ function rt(e) {
|
|
|
424
424
|
return e;
|
|
425
425
|
}
|
|
426
426
|
}
|
|
427
|
-
function
|
|
428
|
-
return /* @__PURE__ */
|
|
427
|
+
function ge(e) {
|
|
428
|
+
return /* @__PURE__ */ P(h, { children: [
|
|
429
429
|
" ",
|
|
430
|
-
e.hasChildren ? /* @__PURE__ */ c(
|
|
430
|
+
e.hasChildren ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ P(
|
|
431
431
|
e.Wrapper,
|
|
432
432
|
{
|
|
433
433
|
...K({
|
|
@@ -448,7 +448,7 @@ function he(e) {
|
|
|
448
448
|
" "
|
|
449
449
|
]
|
|
450
450
|
}
|
|
451
|
-
) }) : /* @__PURE__ */ c(
|
|
451
|
+
) }) : /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
452
452
|
e.Wrapper,
|
|
453
453
|
{
|
|
454
454
|
...K({
|
|
@@ -468,7 +468,7 @@ function he(e) {
|
|
|
468
468
|
" "
|
|
469
469
|
] });
|
|
470
470
|
}
|
|
471
|
-
function
|
|
471
|
+
function lt(e) {
|
|
472
472
|
return /* @__PURE__ */ c(
|
|
473
473
|
e.Wrapper,
|
|
474
474
|
{
|
|
@@ -490,14 +490,14 @@ function ct(e) {
|
|
|
490
490
|
}
|
|
491
491
|
);
|
|
492
492
|
}
|
|
493
|
-
const
|
|
493
|
+
const st = ({
|
|
494
494
|
componentOptions: e,
|
|
495
495
|
builderBlock: t,
|
|
496
496
|
context: n,
|
|
497
497
|
componentRef: i,
|
|
498
498
|
includeBlockProps: a,
|
|
499
|
-
isInteractive:
|
|
500
|
-
contextValue:
|
|
499
|
+
isInteractive: o,
|
|
500
|
+
contextValue: r
|
|
501
501
|
}) => {
|
|
502
502
|
const s = {
|
|
503
503
|
...e,
|
|
@@ -508,11 +508,11 @@ const lt = ({
|
|
|
508
508
|
...a ? {
|
|
509
509
|
attributes: K({
|
|
510
510
|
block: t,
|
|
511
|
-
context:
|
|
511
|
+
context: r
|
|
512
512
|
})
|
|
513
513
|
} : {}
|
|
514
514
|
};
|
|
515
|
-
return
|
|
515
|
+
return o ? {
|
|
516
516
|
Wrapper: i,
|
|
517
517
|
block: t,
|
|
518
518
|
context: n,
|
|
@@ -520,15 +520,15 @@ const lt = ({
|
|
|
520
520
|
includeBlockProps: a
|
|
521
521
|
} : s;
|
|
522
522
|
};
|
|
523
|
-
function
|
|
523
|
+
function be(e) {
|
|
524
524
|
var i;
|
|
525
525
|
const [t, n] = S(
|
|
526
|
-
() => e.isInteractive ?
|
|
526
|
+
() => e.isInteractive ? lt : e.componentRef
|
|
527
527
|
);
|
|
528
|
-
return /* @__PURE__ */ c(
|
|
528
|
+
return /* @__PURE__ */ c(h, { children: e.componentRef ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
529
529
|
t,
|
|
530
530
|
{
|
|
531
|
-
...
|
|
531
|
+
...st({
|
|
532
532
|
componentOptions: e.componentOptions,
|
|
533
533
|
builderBlock: e.builderBlock,
|
|
534
534
|
context: e.context,
|
|
@@ -549,7 +549,7 @@ function ge(e) {
|
|
|
549
549
|
}
|
|
550
550
|
) }) : null });
|
|
551
551
|
}
|
|
552
|
-
function
|
|
552
|
+
function dt(e) {
|
|
553
553
|
const [t, n] = S(() => e.repeatContext);
|
|
554
554
|
return /* @__PURE__ */ c(ne.Provider, { value: t, children: /* @__PURE__ */ c(
|
|
555
555
|
z,
|
|
@@ -561,23 +561,23 @@ function st(e) {
|
|
|
561
561
|
) });
|
|
562
562
|
}
|
|
563
563
|
function z(e) {
|
|
564
|
-
var u,
|
|
564
|
+
var u, b, v;
|
|
565
565
|
function t() {
|
|
566
|
-
return
|
|
566
|
+
return Je({
|
|
567
567
|
block: e.block,
|
|
568
568
|
context: e.context,
|
|
569
569
|
registeredComponents: e.registeredComponents
|
|
570
570
|
});
|
|
571
571
|
}
|
|
572
572
|
function n() {
|
|
573
|
-
return
|
|
573
|
+
return Xe({
|
|
574
574
|
block: e.block,
|
|
575
575
|
context: e.context
|
|
576
576
|
});
|
|
577
577
|
}
|
|
578
578
|
function i() {
|
|
579
|
-
var
|
|
580
|
-
return (
|
|
579
|
+
var y;
|
|
580
|
+
return (y = e.block.repeat) != null && y.collection ? e.block : O({
|
|
581
581
|
block: e.block,
|
|
582
582
|
localState: e.context.localState,
|
|
583
583
|
rootState: e.context.rootState,
|
|
@@ -589,26 +589,26 @@ function z(e) {
|
|
|
589
589
|
function a() {
|
|
590
590
|
return e.block.tagName || "div";
|
|
591
591
|
}
|
|
592
|
-
function
|
|
593
|
-
var
|
|
594
|
-
if ((
|
|
592
|
+
function o() {
|
|
593
|
+
var k, R;
|
|
594
|
+
if ((k = e.block.repeat) != null && k.collection)
|
|
595
595
|
return !!((R = n == null ? void 0 : n()) != null && R.length);
|
|
596
|
-
const
|
|
597
|
-
return ("show" in i() ? i().show : !0) && !
|
|
596
|
+
const y = "hide" in i() ? i().hide : !1;
|
|
597
|
+
return ("show" in i() ? i().show : !0) && !y;
|
|
598
598
|
}
|
|
599
|
-
function
|
|
600
|
-
var
|
|
601
|
-
return !((
|
|
599
|
+
function r() {
|
|
600
|
+
var C, k;
|
|
601
|
+
return !((C = t == null ? void 0 : t()) != null && C.component) && !n() ? (k = i().children) != null ? k : [] : [];
|
|
602
602
|
}
|
|
603
603
|
function s() {
|
|
604
|
-
var
|
|
604
|
+
var y, C, k, R, W, w;
|
|
605
605
|
return {
|
|
606
|
-
blockChildren: (
|
|
607
|
-
componentRef: (
|
|
606
|
+
blockChildren: (y = i().children) != null ? y : [],
|
|
607
|
+
componentRef: (C = t == null ? void 0 : t()) == null ? void 0 : C.component,
|
|
608
608
|
componentOptions: {
|
|
609
|
-
...
|
|
609
|
+
...De(i()),
|
|
610
610
|
builderContext: e.context,
|
|
611
|
-
...((
|
|
611
|
+
...((k = t == null ? void 0 : t()) == null ? void 0 : k.name) === "Symbol" || ((R = t == null ? void 0 : t()) == null ? void 0 : R.name) === "Columns" ? {
|
|
612
612
|
builderComponents: e.registeredComponents
|
|
613
613
|
} : {}
|
|
614
614
|
},
|
|
@@ -616,14 +616,14 @@ function z(e) {
|
|
|
616
616
|
registeredComponents: e.registeredComponents,
|
|
617
617
|
builderBlock: i(),
|
|
618
618
|
includeBlockProps: ((W = t == null ? void 0 : t()) == null ? void 0 : W.noWrap) === !0,
|
|
619
|
-
isInteractive: !((
|
|
619
|
+
isInteractive: !((w = t == null ? void 0 : t()) != null && w.isRSC)
|
|
620
620
|
};
|
|
621
621
|
}
|
|
622
622
|
const [l, d] = S(() => e.context);
|
|
623
|
-
return /* @__PURE__ */ c(
|
|
624
|
-
/* @__PURE__ */ c(
|
|
625
|
-
(u = t == null ? void 0 : t()) != null && u.noWrap ? /* @__PURE__ */ c(
|
|
626
|
-
|
|
623
|
+
return /* @__PURE__ */ c(h, { children: o() ? /* @__PURE__ */ P(h, { children: [
|
|
624
|
+
/* @__PURE__ */ c(tt, { block: e.block, context: e.context }),
|
|
625
|
+
(u = t == null ? void 0 : t()) != null && u.noWrap ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
626
|
+
be,
|
|
627
627
|
{
|
|
628
628
|
componentRef: s().componentRef,
|
|
629
629
|
componentOptions: s().componentOptions,
|
|
@@ -634,9 +634,9 @@ function z(e) {
|
|
|
634
634
|
includeBlockProps: s().includeBlockProps,
|
|
635
635
|
isInteractive: s().isInteractive
|
|
636
636
|
}
|
|
637
|
-
) }) : /* @__PURE__ */
|
|
638
|
-
Y(a()) ? /* @__PURE__ */ c(
|
|
639
|
-
|
|
637
|
+
) }) : /* @__PURE__ */ P(h, { children: [
|
|
638
|
+
Y(a()) ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
639
|
+
ge,
|
|
640
640
|
{
|
|
641
641
|
Wrapper: a(),
|
|
642
642
|
block: i(),
|
|
@@ -644,17 +644,17 @@ function z(e) {
|
|
|
644
644
|
hasChildren: !1
|
|
645
645
|
}
|
|
646
646
|
) }) : null,
|
|
647
|
-
!Y(a()) && n() ? /* @__PURE__ */ c(
|
|
648
|
-
|
|
647
|
+
!Y(a()) && n() ? /* @__PURE__ */ c(h, { children: (b = n()) == null ? void 0 : b.map((y, C) => /* @__PURE__ */ c(
|
|
648
|
+
dt,
|
|
649
649
|
{
|
|
650
|
-
repeatContext:
|
|
651
|
-
block:
|
|
650
|
+
repeatContext: y.context,
|
|
651
|
+
block: y.block,
|
|
652
652
|
registeredComponents: e.registeredComponents
|
|
653
653
|
},
|
|
654
|
-
|
|
654
|
+
C
|
|
655
655
|
)) }) : null,
|
|
656
|
-
!Y(a()) && !n() ? /* @__PURE__ */ c(
|
|
657
|
-
|
|
656
|
+
!Y(a()) && !n() ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ P(
|
|
657
|
+
ge,
|
|
658
658
|
{
|
|
659
659
|
Wrapper: a(),
|
|
660
660
|
block: i(),
|
|
@@ -662,7 +662,7 @@ function z(e) {
|
|
|
662
662
|
hasChildren: !0,
|
|
663
663
|
children: [
|
|
664
664
|
/* @__PURE__ */ c(
|
|
665
|
-
|
|
665
|
+
be,
|
|
666
666
|
{
|
|
667
667
|
componentRef: s().componentRef,
|
|
668
668
|
componentOptions: s().componentOptions,
|
|
@@ -674,14 +674,14 @@ function z(e) {
|
|
|
674
674
|
isInteractive: s().isInteractive
|
|
675
675
|
}
|
|
676
676
|
),
|
|
677
|
-
(
|
|
677
|
+
(v = r()) == null ? void 0 : v.map((y) => /* @__PURE__ */ c(
|
|
678
678
|
z,
|
|
679
679
|
{
|
|
680
|
-
block:
|
|
680
|
+
block: y,
|
|
681
681
|
context: l,
|
|
682
682
|
registeredComponents: e.registeredComponents
|
|
683
683
|
},
|
|
684
|
-
|
|
684
|
+
y.id
|
|
685
685
|
))
|
|
686
686
|
]
|
|
687
687
|
}
|
|
@@ -689,14 +689,14 @@ function z(e) {
|
|
|
689
689
|
] })
|
|
690
690
|
] }) : null });
|
|
691
691
|
}
|
|
692
|
-
function
|
|
692
|
+
function ut(e) {
|
|
693
693
|
function t() {
|
|
694
694
|
var a;
|
|
695
695
|
return "builder-blocks" + ((a = e.blocks) != null && a.length ? "" : " no-blocks");
|
|
696
696
|
}
|
|
697
697
|
function n() {
|
|
698
|
-
var a,
|
|
699
|
-
V() && !((a = e.blocks) != null && a.length) && ((
|
|
698
|
+
var a, o;
|
|
699
|
+
V() && !((a = e.blocks) != null && a.length) && ((o = window.parent) == null || o.postMessage(
|
|
700
700
|
{
|
|
701
701
|
type: "builder.clickEmptyBlocks",
|
|
702
702
|
data: {
|
|
@@ -708,8 +708,8 @@ function dt(e) {
|
|
|
708
708
|
));
|
|
709
709
|
}
|
|
710
710
|
function i() {
|
|
711
|
-
var a,
|
|
712
|
-
V() && !((a = e.blocks) != null && a.length) && ((
|
|
711
|
+
var a, o;
|
|
712
|
+
V() && !((a = e.blocks) != null && a.length) && ((o = window.parent) == null || o.postMessage(
|
|
713
713
|
{
|
|
714
714
|
type: "builder.hoverEmptyBlocks",
|
|
715
715
|
data: {
|
|
@@ -720,7 +720,7 @@ function dt(e) {
|
|
|
720
720
|
"*"
|
|
721
721
|
));
|
|
722
722
|
}
|
|
723
|
-
return /* @__PURE__ */
|
|
723
|
+
return /* @__PURE__ */ P(h, { children: [
|
|
724
724
|
/* @__PURE__ */ c(
|
|
725
725
|
e.BlocksWrapper,
|
|
726
726
|
{
|
|
@@ -743,10 +743,10 @@ function dt(e) {
|
|
|
743
743
|
] });
|
|
744
744
|
}
|
|
745
745
|
function ie(e) {
|
|
746
|
-
var i, a,
|
|
747
|
-
const t =
|
|
746
|
+
var i, a, o;
|
|
747
|
+
const t = se(ne), n = se(Te);
|
|
748
748
|
return /* @__PURE__ */ c(
|
|
749
|
-
|
|
749
|
+
ut,
|
|
750
750
|
{
|
|
751
751
|
blocks: e.blocks,
|
|
752
752
|
parent: e.parent,
|
|
@@ -754,59 +754,59 @@ function ie(e) {
|
|
|
754
754
|
styleProp: e.styleProp,
|
|
755
755
|
BlocksWrapper: (i = e.context) == null ? void 0 : i.BlocksWrapper,
|
|
756
756
|
BlocksWrapperProps: (a = e.context) == null ? void 0 : a.BlocksWrapperProps,
|
|
757
|
-
children: e.blocks ? /* @__PURE__ */ c(
|
|
757
|
+
children: e.blocks ? /* @__PURE__ */ c(h, { children: (o = e.blocks) == null ? void 0 : o.map((r) => /* @__PURE__ */ c(
|
|
758
758
|
z,
|
|
759
759
|
{
|
|
760
|
-
block:
|
|
760
|
+
block: r,
|
|
761
761
|
context: e.context || t,
|
|
762
762
|
registeredComponents: e.registeredComponents || n.registeredComponents
|
|
763
763
|
},
|
|
764
|
-
|
|
764
|
+
r.id
|
|
765
765
|
)) }) : null
|
|
766
766
|
}
|
|
767
767
|
);
|
|
768
768
|
}
|
|
769
|
-
function
|
|
769
|
+
function mt(e) {
|
|
770
770
|
var W;
|
|
771
771
|
const [t, n] = S(
|
|
772
772
|
() => typeof e.space == "number" ? e.space || 0 : 20
|
|
773
|
-
), [i, a] = S(() => e.columns || []), [
|
|
773
|
+
), [i, a] = S(() => e.columns || []), [o, r] = S(
|
|
774
774
|
() => e.stackColumnsAt || "tablet"
|
|
775
775
|
);
|
|
776
|
-
function s(
|
|
777
|
-
var
|
|
778
|
-
return ((
|
|
776
|
+
function s(w) {
|
|
777
|
+
var I;
|
|
778
|
+
return ((I = i[w]) == null ? void 0 : I.width) || 100 / i.length;
|
|
779
779
|
}
|
|
780
|
-
function l(
|
|
781
|
-
const
|
|
782
|
-
return `calc(${s(
|
|
780
|
+
function l(w) {
|
|
781
|
+
const I = t * (i.length - 1) / i.length;
|
|
782
|
+
return `calc(${s(w)}% - ${I}px)`;
|
|
783
783
|
}
|
|
784
784
|
function d({
|
|
785
|
-
stackedStyle:
|
|
786
|
-
desktopStyle:
|
|
785
|
+
stackedStyle: w,
|
|
786
|
+
desktopStyle: I
|
|
787
787
|
}) {
|
|
788
|
-
return
|
|
788
|
+
return o === "tablet" ? w : I;
|
|
789
789
|
}
|
|
790
790
|
function u({
|
|
791
|
-
stackedStyle:
|
|
792
|
-
desktopStyle:
|
|
791
|
+
stackedStyle: w,
|
|
792
|
+
desktopStyle: I
|
|
793
793
|
}) {
|
|
794
|
-
return
|
|
794
|
+
return o === "never" ? I : w;
|
|
795
795
|
}
|
|
796
|
-
const [
|
|
796
|
+
const [b, v] = S(
|
|
797
797
|
() => e.stackColumnsAt === "never" ? "row" : e.reverseColumnsWhenStacked ? "column-reverse" : "column"
|
|
798
798
|
);
|
|
799
|
-
function
|
|
799
|
+
function y() {
|
|
800
800
|
return {
|
|
801
|
-
"--flex-dir":
|
|
801
|
+
"--flex-dir": b,
|
|
802
802
|
"--flex-dir-tablet": d({
|
|
803
|
-
stackedStyle:
|
|
803
|
+
stackedStyle: b,
|
|
804
804
|
desktopStyle: "row"
|
|
805
805
|
})
|
|
806
806
|
};
|
|
807
807
|
}
|
|
808
|
-
function
|
|
809
|
-
const
|
|
808
|
+
function C(w) {
|
|
809
|
+
const I = w === 0 ? 0 : t, B = l(w), A = `${I}px`, N = "100%", F = 0;
|
|
810
810
|
return {
|
|
811
811
|
width: B,
|
|
812
812
|
["marginLeft"]: A,
|
|
@@ -828,15 +828,15 @@ function ut(e) {
|
|
|
828
828
|
})
|
|
829
829
|
};
|
|
830
830
|
}
|
|
831
|
-
function
|
|
831
|
+
function k(w) {
|
|
832
832
|
var B, A;
|
|
833
|
-
return
|
|
833
|
+
return Ee(
|
|
834
834
|
((A = (B = e.builderContext.content) == null ? void 0 : B.meta) == null ? void 0 : A.breakpoints) || {}
|
|
835
|
-
)[
|
|
835
|
+
)[w].max;
|
|
836
836
|
}
|
|
837
837
|
function R() {
|
|
838
838
|
return `
|
|
839
|
-
@media (max-width: ${
|
|
839
|
+
@media (max-width: ${k("medium")}px) {
|
|
840
840
|
.${e.builderBlock.id}-breakpoints {
|
|
841
841
|
flex-direction: var(--flex-dir-tablet);
|
|
842
842
|
align-items: stretch;
|
|
@@ -848,7 +848,7 @@ function ut(e) {
|
|
|
848
848
|
}
|
|
849
849
|
}
|
|
850
850
|
|
|
851
|
-
@media (max-width: ${
|
|
851
|
+
@media (max-width: ${k("small")}px) {
|
|
852
852
|
.${e.builderBlock.id}-breakpoints {
|
|
853
853
|
flex-direction: var(--flex-dir);
|
|
854
854
|
align-items: stretch;
|
|
@@ -861,32 +861,32 @@ function ut(e) {
|
|
|
861
861
|
},
|
|
862
862
|
`;
|
|
863
863
|
}
|
|
864
|
-
return /* @__PURE__ */
|
|
865
|
-
/* @__PURE__ */
|
|
864
|
+
return /* @__PURE__ */ P(h, { children: [
|
|
865
|
+
/* @__PURE__ */ P(
|
|
866
866
|
"div",
|
|
867
867
|
{
|
|
868
868
|
className: `builder-columns ${e.builderBlock.id}-breakpoints div-3c01d6ec`,
|
|
869
|
-
style:
|
|
869
|
+
style: y(),
|
|
870
870
|
children: [
|
|
871
|
-
/* @__PURE__ */ c(
|
|
872
|
-
(W = e.columns) == null ? void 0 : W.map((
|
|
871
|
+
/* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(H, { styles: R() }) }),
|
|
872
|
+
(W = e.columns) == null ? void 0 : W.map((w, I) => /* @__PURE__ */ we(
|
|
873
873
|
"div",
|
|
874
874
|
{
|
|
875
875
|
className: "builder-column div-3c01d6ec-2",
|
|
876
|
-
style: I
|
|
877
|
-
key:
|
|
876
|
+
style: C(I),
|
|
877
|
+
key: I
|
|
878
878
|
},
|
|
879
879
|
/* @__PURE__ */ c(
|
|
880
880
|
ie,
|
|
881
881
|
{
|
|
882
|
-
path: `component.options.columns.${
|
|
882
|
+
path: `component.options.columns.${I}.blocks`,
|
|
883
883
|
parent: e.builderBlock.id,
|
|
884
884
|
styleProp: {
|
|
885
885
|
flexGrow: "1"
|
|
886
886
|
},
|
|
887
887
|
context: e.builderContext,
|
|
888
888
|
registeredComponents: e.builderComponents,
|
|
889
|
-
blocks:
|
|
889
|
+
blocks: w.blocks
|
|
890
890
|
}
|
|
891
891
|
)
|
|
892
892
|
))
|
|
@@ -903,25 +903,25 @@ function ut(e) {
|
|
|
903
903
|
}` })
|
|
904
904
|
] });
|
|
905
905
|
}
|
|
906
|
-
function
|
|
906
|
+
function ft(e) {
|
|
907
907
|
return /* @__PURE__ */ c("span", { children: e.children });
|
|
908
908
|
}
|
|
909
|
-
function
|
|
909
|
+
function xe(e) {
|
|
910
910
|
return e.replace(/http(s)?:/, "");
|
|
911
911
|
}
|
|
912
|
-
function
|
|
912
|
+
function ht(e = "", t, n) {
|
|
913
913
|
const i = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), a = e.indexOf("?") !== -1 ? "&" : "?";
|
|
914
914
|
return e.match(i) ? e.replace(i, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + a + t + "=" + encodeURIComponent(n);
|
|
915
915
|
}
|
|
916
|
-
function
|
|
916
|
+
function gt(e, t) {
|
|
917
917
|
if (!e || !(e != null && e.match(/cdn\.shopify\.com/)) || !t)
|
|
918
918
|
return e;
|
|
919
919
|
if (t === "master")
|
|
920
|
-
return
|
|
920
|
+
return xe(e);
|
|
921
921
|
const n = e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);
|
|
922
922
|
if (n) {
|
|
923
|
-
const i = e.split(n[0]), a = n[3],
|
|
924
|
-
return
|
|
923
|
+
const i = e.split(n[0]), a = n[3], o = t.match("x") ? t : `${t}x`;
|
|
924
|
+
return xe(`${i[0]}_${o}${a}`);
|
|
925
925
|
}
|
|
926
926
|
return null;
|
|
927
927
|
}
|
|
@@ -932,12 +932,12 @@ function G(e) {
|
|
|
932
932
|
if (e.match(/builder\.io/)) {
|
|
933
933
|
let n = e;
|
|
934
934
|
const i = Number(e.split("?width=")[1]);
|
|
935
|
-
return isNaN(i) || (n = `${n} ${i}w`), t.filter((a) => a !== i).map((a) => `${
|
|
935
|
+
return isNaN(i) || (n = `${n} ${i}w`), t.filter((a) => a !== i).map((a) => `${ht(e, "width", a)} ${a}w`).concat([n]).join(", ");
|
|
936
936
|
}
|
|
937
|
-
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [
|
|
937
|
+
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [gt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, i]) => `${n} ${i}w`).concat([e]).join(", ") : e;
|
|
938
938
|
}
|
|
939
|
-
function
|
|
940
|
-
var a,
|
|
939
|
+
function bt(e) {
|
|
940
|
+
var a, o, r, s;
|
|
941
941
|
function t() {
|
|
942
942
|
var u;
|
|
943
943
|
const d = e.image || e.src;
|
|
@@ -966,10 +966,10 @@ function gt(e) {
|
|
|
966
966
|
};
|
|
967
967
|
return e.aspectRatio ? l : void 0;
|
|
968
968
|
}
|
|
969
|
-
return /* @__PURE__ */
|
|
970
|
-
/* @__PURE__ */
|
|
971
|
-
/* @__PURE__ */
|
|
972
|
-
n() ? /* @__PURE__ */ c(
|
|
969
|
+
return /* @__PURE__ */ P(h, { children: [
|
|
970
|
+
/* @__PURE__ */ P(h, { children: [
|
|
971
|
+
/* @__PURE__ */ P("picture", { children: [
|
|
972
|
+
n() ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c("source", { type: "image/webp", srcSet: n() }) }) : null,
|
|
973
973
|
/* @__PURE__ */ c(
|
|
974
974
|
"img",
|
|
975
975
|
{
|
|
@@ -988,7 +988,7 @@ function gt(e) {
|
|
|
988
988
|
}
|
|
989
989
|
)
|
|
990
990
|
] }),
|
|
991
|
-
e.aspectRatio && !((
|
|
991
|
+
e.aspectRatio && !((o = (a = e.builderBlock) == null ? void 0 : a.children) != null && o.length && e.fitContent) ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
992
992
|
"div",
|
|
993
993
|
{
|
|
994
994
|
className: "builder-image-sizer div-40c70c9b",
|
|
@@ -997,8 +997,8 @@ function gt(e) {
|
|
|
997
997
|
}
|
|
998
998
|
}
|
|
999
999
|
) }) : null,
|
|
1000
|
-
(s = (
|
|
1001
|
-
!e.fitContent && e.children ? /* @__PURE__ */ c(
|
|
1000
|
+
(s = (r = e.builderBlock) == null ? void 0 : r.children) != null && s.length && e.fitContent ? /* @__PURE__ */ c(h, { children: e.children }) : null,
|
|
1001
|
+
!e.fitContent && e.children ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c("div", { className: "div-40c70c9b-2", children: e.children }) }) : null
|
|
1002
1002
|
] }),
|
|
1003
1003
|
/* @__PURE__ */ c("style", { children: `.img-40c70c9b {
|
|
1004
1004
|
opacity: 1;
|
|
@@ -1019,7 +1019,7 @@ function gt(e) {
|
|
|
1019
1019
|
}` })
|
|
1020
1020
|
] });
|
|
1021
1021
|
}
|
|
1022
|
-
function
|
|
1022
|
+
function xt(e) {
|
|
1023
1023
|
return /* @__PURE__ */ c(
|
|
1024
1024
|
"section",
|
|
1025
1025
|
{
|
|
@@ -1040,7 +1040,7 @@ function bt(e) {
|
|
|
1040
1040
|
}
|
|
1041
1041
|
);
|
|
1042
1042
|
}
|
|
1043
|
-
const
|
|
1043
|
+
const yt = {
|
|
1044
1044
|
name: "Core:Button",
|
|
1045
1045
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
1046
1046
|
defaultStyles: {
|
|
@@ -1073,7 +1073,7 @@ const xt = {
|
|
|
1073
1073
|
}],
|
|
1074
1074
|
static: !0,
|
|
1075
1075
|
noWrap: !0
|
|
1076
|
-
},
|
|
1076
|
+
}, St = {
|
|
1077
1077
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
1078
1078
|
name: "Columns",
|
|
1079
1079
|
isRSC: !0,
|
|
@@ -1252,7 +1252,7 @@ const xt = {
|
|
|
1252
1252
|
});
|
|
1253
1253
|
}
|
|
1254
1254
|
const n = e.get("columns");
|
|
1255
|
-
Array.isArray(n) && n.find((a) => a.get("width")) && (n.find((
|
|
1255
|
+
Array.isArray(n) && n.find((a) => a.get("width")) && (n.find((o) => !o.get("width")) || n.reduce((s, l) => s + l.get("width"), 0) !== 100) && t();
|
|
1256
1256
|
}
|
|
1257
1257
|
}, {
|
|
1258
1258
|
name: "space",
|
|
@@ -1274,7 +1274,7 @@ const xt = {
|
|
|
1274
1274
|
helperText: "When stacking columns for mobile devices, reverse the ordering",
|
|
1275
1275
|
advanced: !0
|
|
1276
1276
|
}]
|
|
1277
|
-
},
|
|
1277
|
+
}, vt = {
|
|
1278
1278
|
name: "Custom Code",
|
|
1279
1279
|
static: !0,
|
|
1280
1280
|
requiredPermissions: ["editCode"],
|
|
@@ -1298,14 +1298,14 @@ const xt = {
|
|
|
1298
1298
|
}]
|
|
1299
1299
|
};
|
|
1300
1300
|
function pt(e) {
|
|
1301
|
-
const t = ee(null), [n, i] = S(() => []), [a,
|
|
1302
|
-
return
|
|
1301
|
+
const t = ee(null), [n, i] = S(() => []), [a, o] = S(() => []);
|
|
1302
|
+
return E(() => {
|
|
1303
1303
|
var s;
|
|
1304
1304
|
if (!((s = t.current) != null && s.getElementsByTagName) || typeof window == "undefined")
|
|
1305
1305
|
return;
|
|
1306
|
-
const
|
|
1307
|
-
for (let l = 0; l <
|
|
1308
|
-
const d =
|
|
1306
|
+
const r = t.current.getElementsByTagName("script");
|
|
1307
|
+
for (let l = 0; l < r.length; l++) {
|
|
1308
|
+
const d = r[l];
|
|
1309
1309
|
if (d.src) {
|
|
1310
1310
|
if (n.includes(d.src))
|
|
1311
1311
|
continue;
|
|
@@ -1335,7 +1335,7 @@ function pt(e) {
|
|
|
1335
1335
|
}
|
|
1336
1336
|
);
|
|
1337
1337
|
}
|
|
1338
|
-
const
|
|
1338
|
+
const kt = {
|
|
1339
1339
|
name: "Embed",
|
|
1340
1340
|
static: !0,
|
|
1341
1341
|
inputs: [{
|
|
@@ -1360,30 +1360,30 @@ const vt = {
|
|
|
1360
1360
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
1361
1361
|
hideFromUI: !0
|
|
1362
1362
|
}]
|
|
1363
|
-
},
|
|
1364
|
-
function
|
|
1365
|
-
const t = ee(null), [n, i] = S(() => []), [a,
|
|
1363
|
+
}, Ct = ["text/javascript", "application/javascript", "application/ecmascript"], wt = (e) => Ct.includes(e.type);
|
|
1364
|
+
function It(e) {
|
|
1365
|
+
const t = ee(null), [n, i] = S(() => []), [a, o] = S(() => []), [r, s] = S(() => !1);
|
|
1366
1366
|
function l() {
|
|
1367
1367
|
if (!t.current || !t.current.getElementsByTagName)
|
|
1368
1368
|
return;
|
|
1369
1369
|
const d = t.current.getElementsByTagName("script");
|
|
1370
1370
|
for (let u = 0; u < d.length; u++) {
|
|
1371
|
-
const
|
|
1372
|
-
if (
|
|
1373
|
-
n.push(
|
|
1374
|
-
const
|
|
1375
|
-
|
|
1376
|
-
} else if (
|
|
1371
|
+
const b = d[u];
|
|
1372
|
+
if (b.src && !n.includes(b.src)) {
|
|
1373
|
+
n.push(b.src);
|
|
1374
|
+
const v = document.createElement("script");
|
|
1375
|
+
v.async = !0, v.src = b.src, document.head.appendChild(v);
|
|
1376
|
+
} else if (wt(b) && !a.includes(b.innerText))
|
|
1377
1377
|
try {
|
|
1378
|
-
a.push(
|
|
1379
|
-
} catch (
|
|
1380
|
-
console.warn("`Embed`: Error running script:",
|
|
1378
|
+
a.push(b.innerText), new Function(b.innerText)();
|
|
1379
|
+
} catch (v) {
|
|
1380
|
+
console.warn("`Embed`: Error running script:", v);
|
|
1381
1381
|
}
|
|
1382
1382
|
}
|
|
1383
1383
|
}
|
|
1384
|
-
return
|
|
1385
|
-
t.current && !
|
|
1386
|
-
}, [t.current,
|
|
1384
|
+
return E(() => {
|
|
1385
|
+
t.current && !r && (s(!0), l());
|
|
1386
|
+
}, [t.current, r]), /* @__PURE__ */ c(
|
|
1387
1387
|
"div",
|
|
1388
1388
|
{
|
|
1389
1389
|
className: "builder-embed",
|
|
@@ -1392,13 +1392,13 @@ function wt(e) {
|
|
|
1392
1392
|
}
|
|
1393
1393
|
);
|
|
1394
1394
|
}
|
|
1395
|
-
const
|
|
1395
|
+
const Tt = {
|
|
1396
1396
|
name: "Fragment",
|
|
1397
1397
|
static: !0,
|
|
1398
1398
|
hidden: !0,
|
|
1399
1399
|
canHaveChildren: !0,
|
|
1400
1400
|
noWrap: !0
|
|
1401
|
-
},
|
|
1401
|
+
}, Rt = {
|
|
1402
1402
|
name: "Image",
|
|
1403
1403
|
static: !0,
|
|
1404
1404
|
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 +1418,29 @@ const It = {
|
|
|
1418
1418
|
defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
|
|
1419
1419
|
onChange: (e) => {
|
|
1420
1420
|
e.delete("srcset"), e.delete("noWebp");
|
|
1421
|
-
function n(
|
|
1421
|
+
function n(r, s = 6e4) {
|
|
1422
1422
|
return new Promise((l, d) => {
|
|
1423
1423
|
const u = document.createElement("img");
|
|
1424
|
-
let
|
|
1424
|
+
let b = !1;
|
|
1425
1425
|
u.onload = () => {
|
|
1426
|
-
|
|
1427
|
-
}, u.addEventListener("error", (
|
|
1428
|
-
console.warn("Image load failed",
|
|
1429
|
-
}), u.src =
|
|
1430
|
-
|
|
1426
|
+
b = !0, l(u);
|
|
1427
|
+
}, u.addEventListener("error", (v) => {
|
|
1428
|
+
console.warn("Image load failed", v.error), d(v.error);
|
|
1429
|
+
}), u.src = r, setTimeout(() => {
|
|
1430
|
+
b || d(new Error("Image load timed out"));
|
|
1431
1431
|
}, s);
|
|
1432
1432
|
});
|
|
1433
1433
|
}
|
|
1434
|
-
function i(
|
|
1435
|
-
return Math.round(
|
|
1434
|
+
function i(r) {
|
|
1435
|
+
return Math.round(r * 1e3) / 1e3;
|
|
1436
1436
|
}
|
|
1437
|
-
const a = e.get("image"),
|
|
1438
|
-
if (fetch(a).then((
|
|
1439
|
-
|
|
1440
|
-
}), a && (!
|
|
1441
|
-
return n(a).then((
|
|
1437
|
+
const a = e.get("image"), o = e.get("aspectRatio");
|
|
1438
|
+
if (fetch(a).then((r) => r.blob()).then((r) => {
|
|
1439
|
+
r.type.includes("svg") && e.set("noWebp", !0);
|
|
1440
|
+
}), a && (!o || o === 0.7041))
|
|
1441
|
+
return n(a).then((r) => {
|
|
1442
1442
|
const s = e.get("aspectRatio");
|
|
1443
|
-
e.get("image") === a && (!s || s === 0.7041) &&
|
|
1443
|
+
e.get("image") === a && (!s || s === 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
1444
|
});
|
|
1445
1445
|
}
|
|
1446
1446
|
}, {
|
|
@@ -1498,7 +1498,7 @@ const It = {
|
|
|
1498
1498
|
advanced: !0,
|
|
1499
1499
|
defaultValue: 0.7041
|
|
1500
1500
|
}]
|
|
1501
|
-
},
|
|
1501
|
+
}, Et = {
|
|
1502
1502
|
// friendlyName?
|
|
1503
1503
|
name: "Raw:Img",
|
|
1504
1504
|
hideFromInsertMenu: !0,
|
|
@@ -1513,7 +1513,7 @@ const It = {
|
|
|
1513
1513
|
noWrap: !0,
|
|
1514
1514
|
static: !0
|
|
1515
1515
|
};
|
|
1516
|
-
function
|
|
1516
|
+
function Pt(e) {
|
|
1517
1517
|
return /* @__PURE__ */ c(
|
|
1518
1518
|
"img",
|
|
1519
1519
|
{
|
|
@@ -1528,7 +1528,7 @@ function Et(e) {
|
|
|
1528
1528
|
V() && e.imgSrc || "default-key"
|
|
1529
1529
|
);
|
|
1530
1530
|
}
|
|
1531
|
-
const
|
|
1531
|
+
const Wt = {
|
|
1532
1532
|
name: "Core:Section",
|
|
1533
1533
|
static: !0,
|
|
1534
1534
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -1567,7 +1567,7 @@ const Pt = {
|
|
|
1567
1567
|
}
|
|
1568
1568
|
}
|
|
1569
1569
|
}]
|
|
1570
|
-
},
|
|
1570
|
+
}, Bt = {
|
|
1571
1571
|
name: "Symbol",
|
|
1572
1572
|
noWrap: !0,
|
|
1573
1573
|
static: !0,
|
|
@@ -1600,7 +1600,7 @@ const Pt = {
|
|
|
1600
1600
|
hideFromUI: !0,
|
|
1601
1601
|
type: "boolean"
|
|
1602
1602
|
}]
|
|
1603
|
-
},
|
|
1603
|
+
}, At = {
|
|
1604
1604
|
name: "Text",
|
|
1605
1605
|
static: !0,
|
|
1606
1606
|
isRSC: !0,
|
|
@@ -1619,7 +1619,7 @@ const Pt = {
|
|
|
1619
1619
|
textAlign: "center"
|
|
1620
1620
|
}
|
|
1621
1621
|
};
|
|
1622
|
-
function
|
|
1622
|
+
function Vt(e) {
|
|
1623
1623
|
var t;
|
|
1624
1624
|
return /* @__PURE__ */ c(
|
|
1625
1625
|
"div",
|
|
@@ -1632,7 +1632,7 @@ function At(e) {
|
|
|
1632
1632
|
}
|
|
1633
1633
|
);
|
|
1634
1634
|
}
|
|
1635
|
-
const
|
|
1635
|
+
const $t = {
|
|
1636
1636
|
name: "Video",
|
|
1637
1637
|
canHaveChildren: !0,
|
|
1638
1638
|
defaultStyles: {
|
|
@@ -1714,8 +1714,8 @@ const Vt = {
|
|
|
1714
1714
|
advanced: !0
|
|
1715
1715
|
}]
|
|
1716
1716
|
};
|
|
1717
|
-
function
|
|
1718
|
-
var i, a,
|
|
1717
|
+
function Nt(e) {
|
|
1718
|
+
var i, a, o, r, s, l, d;
|
|
1719
1719
|
function t() {
|
|
1720
1720
|
return {
|
|
1721
1721
|
...e.autoPlay === !0 ? {
|
|
@@ -1740,7 +1740,7 @@ function $t(e) {
|
|
|
1740
1740
|
...t()
|
|
1741
1741
|
};
|
|
1742
1742
|
}
|
|
1743
|
-
return /* @__PURE__ */
|
|
1743
|
+
return /* @__PURE__ */ P(
|
|
1744
1744
|
"div",
|
|
1745
1745
|
{
|
|
1746
1746
|
style: {
|
|
@@ -1772,7 +1772,7 @@ function $t(e) {
|
|
|
1772
1772
|
children: e.lazyLoad ? null : /* @__PURE__ */ c("source", { type: "video/mp4", src: e.video })
|
|
1773
1773
|
}
|
|
1774
1774
|
),
|
|
1775
|
-
e.aspectRatio && !(e.fitContent && ((
|
|
1775
|
+
e.aspectRatio && !(e.fitContent && ((o = (a = e.builderBlock) == null ? void 0 : a.children) != null && o.length)) ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
1776
1776
|
"div",
|
|
1777
1777
|
{
|
|
1778
1778
|
style: {
|
|
@@ -1783,7 +1783,7 @@ function $t(e) {
|
|
|
1783
1783
|
}
|
|
1784
1784
|
}
|
|
1785
1785
|
) }) : null,
|
|
1786
|
-
(s = (
|
|
1786
|
+
(s = (r = e.builderBlock) == null ? void 0 : r.children) != null && s.length && e.fitContent ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
1787
1787
|
"div",
|
|
1788
1788
|
{
|
|
1789
1789
|
style: {
|
|
@@ -1794,7 +1794,7 @@ function $t(e) {
|
|
|
1794
1794
|
children: e.children
|
|
1795
1795
|
}
|
|
1796
1796
|
) }) : null,
|
|
1797
|
-
(d = (l = e.builderBlock) == null ? void 0 : l.children) != null && d.length && !e.fitContent ? /* @__PURE__ */ c(
|
|
1797
|
+
(d = (l = e.builderBlock) == null ? void 0 : l.children) != null && d.length && !e.fitContent ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
1798
1798
|
"div",
|
|
1799
1799
|
{
|
|
1800
1800
|
style: {
|
|
@@ -1815,40 +1815,40 @@ function $t(e) {
|
|
|
1815
1815
|
}
|
|
1816
1816
|
);
|
|
1817
1817
|
}
|
|
1818
|
-
const
|
|
1819
|
-
component:
|
|
1820
|
-
...xt
|
|
1821
|
-
}, {
|
|
1822
|
-
component: ut,
|
|
1818
|
+
const ye = () => [{
|
|
1819
|
+
component: Ue,
|
|
1823
1820
|
...yt
|
|
1824
1821
|
}, {
|
|
1825
|
-
component:
|
|
1822
|
+
component: mt,
|
|
1826
1823
|
...St
|
|
1827
1824
|
}, {
|
|
1828
|
-
component:
|
|
1825
|
+
component: pt,
|
|
1829
1826
|
...vt
|
|
1830
1827
|
}, {
|
|
1831
|
-
component:
|
|
1832
|
-
...
|
|
1828
|
+
component: It,
|
|
1829
|
+
...kt
|
|
1833
1830
|
}, {
|
|
1834
|
-
component:
|
|
1831
|
+
component: ft,
|
|
1835
1832
|
...Tt
|
|
1836
1833
|
}, {
|
|
1837
|
-
component:
|
|
1834
|
+
component: bt,
|
|
1838
1835
|
...Rt
|
|
1839
1836
|
}, {
|
|
1840
|
-
component:
|
|
1841
|
-
...
|
|
1837
|
+
component: Pt,
|
|
1838
|
+
...Et
|
|
1842
1839
|
}, {
|
|
1843
|
-
component:
|
|
1840
|
+
component: xt,
|
|
1844
1841
|
...Wt
|
|
1845
1842
|
}, {
|
|
1846
|
-
component:
|
|
1843
|
+
component: an,
|
|
1847
1844
|
...Bt
|
|
1848
1845
|
}, {
|
|
1849
|
-
component:
|
|
1850
|
-
...
|
|
1851
|
-
}
|
|
1846
|
+
component: Vt,
|
|
1847
|
+
...At
|
|
1848
|
+
}, {
|
|
1849
|
+
component: Nt,
|
|
1850
|
+
...$t
|
|
1851
|
+
}], Ft = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
|
|
1852
1852
|
function getAndSetVariantId() {
|
|
1853
1853
|
function setCookie(name, value, days) {
|
|
1854
1854
|
let expires = '';
|
|
@@ -1904,7 +1904,7 @@ const xe = () => [{
|
|
|
1904
1904
|
}).join('');
|
|
1905
1905
|
styleEl.innerHTML = newStyleStr;
|
|
1906
1906
|
}
|
|
1907
|
-
}`,
|
|
1907
|
+
}`, _t = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
|
|
1908
1908
|
if (!navigator.cookieEnabled) {
|
|
1909
1909
|
return;
|
|
1910
1910
|
}
|
|
@@ -1938,24 +1938,24 @@ const xe = () => [{
|
|
|
1938
1938
|
thisScriptEl?.remove();
|
|
1939
1939
|
}
|
|
1940
1940
|
return;
|
|
1941
|
-
}`,
|
|
1941
|
+
}`, We = "builderIoAbTest", Be = "builderIoRenderContent", M = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
|
|
1942
1942
|
...t,
|
|
1943
1943
|
testVariationId: t.id,
|
|
1944
1944
|
id: e == null ? void 0 : e.id
|
|
1945
|
-
})),
|
|
1945
|
+
})), Lt = ({
|
|
1946
1946
|
canTrack: e,
|
|
1947
1947
|
content: t
|
|
1948
|
-
}) => !(!(M(t).length > 0) || !e || $()),
|
|
1949
|
-
window.${Pe} = ${Nt}
|
|
1948
|
+
}) => !(!(M(t).length > 0) || !e || $()), jt = (e) => e === "react" || e === "reactNative", Ae = jt(L), Mt = () => `
|
|
1950
1949
|
window.${We} = ${Ft}
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1950
|
+
window.${Be} = ${_t}
|
|
1951
|
+
`, Ut = (e, t) => `
|
|
1952
|
+
window.${We}(
|
|
1953
|
+
"${t}",${JSON.stringify(e)}, ${Ae}
|
|
1954
|
+
)`, Dt = ({
|
|
1955
1955
|
contentId: e,
|
|
1956
1956
|
variationId: t
|
|
1957
|
-
}) => `window.${
|
|
1958
|
-
"${t}", "${e}", ${
|
|
1957
|
+
}) => `window.${Be}(
|
|
1958
|
+
"${t}", "${e}", ${Ae}
|
|
1959
1959
|
)`;
|
|
1960
1960
|
function Z(e) {
|
|
1961
1961
|
return /* @__PURE__ */ c(
|
|
@@ -1966,10 +1966,10 @@ function Z(e) {
|
|
|
1966
1966
|
}
|
|
1967
1967
|
);
|
|
1968
1968
|
}
|
|
1969
|
-
function
|
|
1969
|
+
function Se(e) {
|
|
1970
1970
|
return Math.round(e * 1e3) / 1e3;
|
|
1971
1971
|
}
|
|
1972
|
-
const
|
|
1972
|
+
const Ot = (e, t, n = !0) => {
|
|
1973
1973
|
if (!(e instanceof HTMLElement))
|
|
1974
1974
|
return null;
|
|
1975
1975
|
let i = n ? e : e.parentElement;
|
|
@@ -1980,36 +1980,36 @@ const Dt = (e, t, n = !0) => {
|
|
|
1980
1980
|
return i;
|
|
1981
1981
|
} while (i = i.parentElement);
|
|
1982
1982
|
return null;
|
|
1983
|
-
},
|
|
1983
|
+
}, Kt = (e) => Ot(e, (t) => {
|
|
1984
1984
|
const n = t.getAttribute("builder-id") || t.id;
|
|
1985
1985
|
return (n == null ? void 0 : n.indexOf("builder-")) === 0;
|
|
1986
|
-
}),
|
|
1986
|
+
}), ve = ({
|
|
1987
1987
|
event: e,
|
|
1988
1988
|
target: t
|
|
1989
1989
|
}) => {
|
|
1990
|
-
const n = t.getBoundingClientRect(), i = e.clientX - n.left, a = e.clientY - n.top,
|
|
1990
|
+
const n = t.getBoundingClientRect(), i = e.clientX - n.left, a = e.clientY - n.top, o = Se(i / n.width), r = Se(a / n.height);
|
|
1991
1991
|
return {
|
|
1992
|
-
x:
|
|
1993
|
-
y:
|
|
1992
|
+
x: o,
|
|
1993
|
+
y: r
|
|
1994
1994
|
};
|
|
1995
|
-
},
|
|
1996
|
-
const t = e.target, n = t &&
|
|
1995
|
+
}, Ht = (e) => {
|
|
1996
|
+
const t = e.target, n = t && Kt(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
|
|
1997
1997
|
return {
|
|
1998
1998
|
targetBuilderElement: i || void 0,
|
|
1999
1999
|
metadata: {
|
|
2000
|
-
targetOffset: t ?
|
|
2000
|
+
targetOffset: t ? ve({
|
|
2001
2001
|
event: e,
|
|
2002
2002
|
target: t
|
|
2003
2003
|
}) : void 0,
|
|
2004
|
-
builderTargetOffset: n ?
|
|
2004
|
+
builderTargetOffset: n ? ve({
|
|
2005
2005
|
event: e,
|
|
2006
2006
|
target: n
|
|
2007
2007
|
}) : void 0,
|
|
2008
2008
|
builderElementIndex: n && i ? [].slice.call(document.getElementsByClassName(i)).indexOf(n) : void 0
|
|
2009
2009
|
}
|
|
2010
2010
|
};
|
|
2011
|
-
},
|
|
2012
|
-
|
|
2011
|
+
}, zt = "0.11.4", qt = () => {
|
|
2012
|
+
Fe("insertMenu", {
|
|
2013
2013
|
name: "_default",
|
|
2014
2014
|
default: !0,
|
|
2015
2015
|
items: [{
|
|
@@ -2032,13 +2032,13 @@ const Dt = (e, t, n = !0) => {
|
|
|
2032
2032
|
});
|
|
2033
2033
|
};
|
|
2034
2034
|
let pe = !1;
|
|
2035
|
-
const
|
|
2035
|
+
const Yt = (e = {}) => {
|
|
2036
2036
|
var t, n;
|
|
2037
2037
|
pe || (pe = !0, $() && ((t = window.parent) == null || t.postMessage({
|
|
2038
2038
|
type: "builder.sdkInfo",
|
|
2039
2039
|
data: {
|
|
2040
2040
|
target: L,
|
|
2041
|
-
version:
|
|
2041
|
+
version: zt,
|
|
2042
2042
|
supportsPatchUpdates: !1,
|
|
2043
2043
|
// Supports builder-model="..." attribute which is needed to
|
|
2044
2044
|
// scope our '+ add block' button styling
|
|
@@ -2053,33 +2053,33 @@ const qt = (e = {}) => {
|
|
|
2053
2053
|
}, "*"), window.addEventListener("message", ({
|
|
2054
2054
|
data: i
|
|
2055
2055
|
}) => {
|
|
2056
|
-
var a,
|
|
2056
|
+
var a, o;
|
|
2057
2057
|
if (i != null && i.type)
|
|
2058
2058
|
switch (i.type) {
|
|
2059
2059
|
case "builder.evaluate": {
|
|
2060
|
-
const
|
|
2061
|
-
let u,
|
|
2060
|
+
const r = i.data.text, s = i.data.arguments || [], l = i.data.id, d = new Function(r);
|
|
2061
|
+
let u, b = null;
|
|
2062
2062
|
try {
|
|
2063
2063
|
u = d.apply(null, s);
|
|
2064
|
-
} catch (
|
|
2065
|
-
|
|
2064
|
+
} catch (v) {
|
|
2065
|
+
b = v;
|
|
2066
2066
|
}
|
|
2067
|
-
|
|
2067
|
+
b ? (a = window.parent) == null || a.postMessage({
|
|
2068
2068
|
type: "builder.evaluateError",
|
|
2069
2069
|
data: {
|
|
2070
2070
|
id: l,
|
|
2071
|
-
error:
|
|
2071
|
+
error: b.message
|
|
2072
2072
|
}
|
|
2073
|
-
}, "*") : u && typeof u.then == "function" ? u.then((
|
|
2074
|
-
var
|
|
2075
|
-
(
|
|
2073
|
+
}, "*") : u && typeof u.then == "function" ? u.then((v) => {
|
|
2074
|
+
var y;
|
|
2075
|
+
(y = window.parent) == null || y.postMessage({
|
|
2076
2076
|
type: "builder.evaluateResult",
|
|
2077
2077
|
data: {
|
|
2078
2078
|
id: l,
|
|
2079
|
-
result:
|
|
2079
|
+
result: v
|
|
2080
2080
|
}
|
|
2081
2081
|
}, "*");
|
|
2082
|
-
}).catch(console.error) : (
|
|
2082
|
+
}).catch(console.error) : (o = window.parent) == null || o.postMessage({
|
|
2083
2083
|
type: "builder.evaluateResult",
|
|
2084
2084
|
data: {
|
|
2085
2085
|
result: u,
|
|
@@ -2091,61 +2091,73 @@ const qt = (e = {}) => {
|
|
|
2091
2091
|
}
|
|
2092
2092
|
})));
|
|
2093
2093
|
};
|
|
2094
|
-
function
|
|
2095
|
-
var
|
|
2094
|
+
function Qt(e) {
|
|
2095
|
+
var F, q, ae, oe, re, ce, le;
|
|
2096
2096
|
const t = ee(null), [n, i] = S(() => 0);
|
|
2097
|
+
S(() => !0);
|
|
2097
2098
|
function a(m) {
|
|
2098
|
-
var
|
|
2099
|
-
const
|
|
2099
|
+
var g, x;
|
|
2100
|
+
const f = {
|
|
2101
|
+
...e.builderContextSignal.rootState,
|
|
2102
|
+
...m
|
|
2103
|
+
};
|
|
2104
|
+
e.builderContextSignal.rootSetState ? (x = (g = e.builderContextSignal).rootSetState) == null || x.call(g, f) : e.setBuilderContextSignal((p) => ({
|
|
2105
|
+
...p,
|
|
2106
|
+
rootState: f
|
|
2107
|
+
}));
|
|
2108
|
+
}
|
|
2109
|
+
function o(m) {
|
|
2110
|
+
var g, x, p, T, j;
|
|
2111
|
+
const f = {
|
|
2100
2112
|
...e.builderContextSignal.content,
|
|
2101
2113
|
...m,
|
|
2102
2114
|
data: {
|
|
2103
|
-
...(
|
|
2115
|
+
...(g = e.builderContextSignal.content) == null ? void 0 : g.data,
|
|
2104
2116
|
...m == null ? void 0 : m.data
|
|
2105
2117
|
},
|
|
2106
2118
|
meta: {
|
|
2107
|
-
...(
|
|
2119
|
+
...(x = e.builderContextSignal.content) == null ? void 0 : x.meta,
|
|
2108
2120
|
...m == null ? void 0 : m.meta,
|
|
2109
|
-
breakpoints: ((
|
|
2121
|
+
breakpoints: ((p = m == null ? void 0 : m.meta) == null ? void 0 : p.breakpoints) || ((j = (T = e.builderContextSignal.content) == null ? void 0 : T.meta) == null ? void 0 : j.breakpoints)
|
|
2110
2122
|
}
|
|
2111
2123
|
};
|
|
2112
|
-
e.setBuilderContextSignal((
|
|
2113
|
-
|
|
2114
|
-
content:
|
|
2124
|
+
e.setBuilderContextSignal(($e) => ({
|
|
2125
|
+
...$e,
|
|
2126
|
+
content: f
|
|
2115
2127
|
}));
|
|
2116
2128
|
}
|
|
2117
2129
|
S(() => 0);
|
|
2118
|
-
const [r,
|
|
2130
|
+
const [r, s] = S(
|
|
2119
2131
|
() => !1
|
|
2120
|
-
), [
|
|
2132
|
+
), [l, d] = S(
|
|
2121
2133
|
() => e.contentWrapper || "div"
|
|
2122
2134
|
);
|
|
2123
|
-
function
|
|
2124
|
-
var
|
|
2125
|
-
const { data:
|
|
2126
|
-
if (
|
|
2127
|
-
switch (
|
|
2135
|
+
function u(m) {
|
|
2136
|
+
var g;
|
|
2137
|
+
const { data: f } = m;
|
|
2138
|
+
if (f)
|
|
2139
|
+
switch (f.type) {
|
|
2128
2140
|
case "builder.configureSdk": {
|
|
2129
|
-
const
|
|
2130
|
-
if (!T || T !== ((
|
|
2141
|
+
const x = f.data, { breakpoints: p, contentId: T } = x;
|
|
2142
|
+
if (!T || T !== ((g = e.builderContextSignal.content) == null ? void 0 : g.id))
|
|
2131
2143
|
return;
|
|
2132
|
-
|
|
2144
|
+
p && o({
|
|
2133
2145
|
meta: {
|
|
2134
|
-
breakpoints:
|
|
2146
|
+
breakpoints: p
|
|
2135
2147
|
}
|
|
2136
2148
|
}), i(n + 1);
|
|
2137
2149
|
break;
|
|
2138
2150
|
}
|
|
2139
2151
|
case "builder.contentUpdate": {
|
|
2140
|
-
const
|
|
2141
|
-
|
|
2152
|
+
const x = f.data, p = x.key || x.alias || x.entry || x.modelName, T = x.data;
|
|
2153
|
+
p === e.model && (o(T), i(n + 1));
|
|
2142
2154
|
break;
|
|
2143
2155
|
}
|
|
2144
2156
|
}
|
|
2145
2157
|
}
|
|
2146
|
-
function
|
|
2147
|
-
var
|
|
2148
|
-
const m = (
|
|
2158
|
+
function b() {
|
|
2159
|
+
var f, g;
|
|
2160
|
+
const m = (g = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : g.jsCode;
|
|
2149
2161
|
m && _({
|
|
2150
2162
|
code: m,
|
|
2151
2163
|
context: e.context || {},
|
|
@@ -2154,28 +2166,28 @@ function Yt(e) {
|
|
|
2154
2166
|
rootSetState: e.builderContextSignal.rootSetState
|
|
2155
2167
|
});
|
|
2156
2168
|
}
|
|
2157
|
-
const [
|
|
2158
|
-
function
|
|
2159
|
-
var
|
|
2169
|
+
const [v, y] = S(() => ({})), [C, k] = S(() => !1);
|
|
2170
|
+
function R(m) {
|
|
2171
|
+
var f, g;
|
|
2160
2172
|
if (e.builderContextSignal.content) {
|
|
2161
|
-
const
|
|
2162
|
-
|
|
2173
|
+
const x = (f = e.builderContextSignal.content) == null ? void 0 : f.testVariationId, p = (g = e.builderContextSignal.content) == null ? void 0 : g.id;
|
|
2174
|
+
de({
|
|
2163
2175
|
type: "click",
|
|
2164
2176
|
canTrack: D(e.canTrack),
|
|
2165
|
-
contentId:
|
|
2177
|
+
contentId: p,
|
|
2166
2178
|
apiKey: e.apiKey,
|
|
2167
|
-
variationId:
|
|
2168
|
-
...
|
|
2169
|
-
unique: !
|
|
2179
|
+
variationId: x !== p ? x : void 0,
|
|
2180
|
+
...Ht(m),
|
|
2181
|
+
unique: !C
|
|
2170
2182
|
});
|
|
2171
2183
|
}
|
|
2172
|
-
|
|
2184
|
+
C || k(!0);
|
|
2173
2185
|
}
|
|
2174
|
-
function
|
|
2186
|
+
function W(m) {
|
|
2175
2187
|
return m.replace(
|
|
2176
2188
|
/{{([^}]+)}}/g,
|
|
2177
|
-
(
|
|
2178
|
-
code:
|
|
2189
|
+
(f, g) => _({
|
|
2190
|
+
code: g,
|
|
2179
2191
|
context: e.context || {},
|
|
2180
2192
|
localState: void 0,
|
|
2181
2193
|
rootState: e.builderContextSignal.rootState,
|
|
@@ -2183,32 +2195,32 @@ function Yt(e) {
|
|
|
2183
2195
|
})
|
|
2184
2196
|
);
|
|
2185
2197
|
}
|
|
2186
|
-
function
|
|
2187
|
-
|
|
2188
|
-
var
|
|
2189
|
-
const
|
|
2198
|
+
function w({ url: m, key: f }) {
|
|
2199
|
+
je(m).then((g) => g.json()).then((g) => {
|
|
2200
|
+
var p, T;
|
|
2201
|
+
const x = {
|
|
2190
2202
|
...e.builderContextSignal.rootState,
|
|
2191
|
-
[
|
|
2203
|
+
[f]: g
|
|
2192
2204
|
};
|
|
2193
|
-
(T = (
|
|
2194
|
-
}).catch((
|
|
2195
|
-
console.error("error fetching dynamic data", m,
|
|
2205
|
+
(T = (p = e.builderContextSignal).rootSetState) == null || T.call(p, x), v[f] = !0;
|
|
2206
|
+
}).catch((g) => {
|
|
2207
|
+
console.error("error fetching dynamic data", m, g);
|
|
2196
2208
|
});
|
|
2197
2209
|
}
|
|
2198
|
-
function
|
|
2199
|
-
var
|
|
2200
|
-
const m = (
|
|
2201
|
-
Object.entries(m).forEach(([
|
|
2202
|
-
if (T && (!
|
|
2203
|
-
const j =
|
|
2204
|
-
|
|
2210
|
+
function I() {
|
|
2211
|
+
var f, g, x;
|
|
2212
|
+
const m = (x = (g = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : g.httpRequests) != null ? x : {};
|
|
2213
|
+
Object.entries(m).forEach(([p, T]) => {
|
|
2214
|
+
if (T && (!v[p] || V())) {
|
|
2215
|
+
const j = W(T);
|
|
2216
|
+
w({
|
|
2205
2217
|
url: j,
|
|
2206
|
-
key:
|
|
2218
|
+
key: p
|
|
2207
2219
|
});
|
|
2208
2220
|
}
|
|
2209
2221
|
});
|
|
2210
2222
|
}
|
|
2211
|
-
function
|
|
2223
|
+
function B() {
|
|
2212
2224
|
V() && window.dispatchEvent(
|
|
2213
2225
|
new CustomEvent(
|
|
2214
2226
|
"builder:component:stateChange",
|
|
@@ -2223,8 +2235,8 @@ function Yt(e) {
|
|
|
2223
2235
|
)
|
|
2224
2236
|
);
|
|
2225
2237
|
}
|
|
2226
|
-
function
|
|
2227
|
-
i(n + 1), window.addEventListener("message",
|
|
2238
|
+
function A(m) {
|
|
2239
|
+
i(n + 1), window.addEventListener("message", u), qt(), Yt({
|
|
2228
2240
|
...e.locale ? {
|
|
2229
2241
|
locale: e.locale
|
|
2230
2242
|
} : {},
|
|
@@ -2236,108 +2248,114 @@ function Yt(e) {
|
|
|
2236
2248
|
} : {}
|
|
2237
2249
|
}), Object.values(
|
|
2238
2250
|
e.builderContextSignal.componentInfos
|
|
2239
|
-
).forEach((
|
|
2240
|
-
var
|
|
2241
|
-
const
|
|
2242
|
-
(
|
|
2251
|
+
).forEach((f) => {
|
|
2252
|
+
var x;
|
|
2253
|
+
const g = Le(f);
|
|
2254
|
+
(x = window.parent) == null || x.postMessage(g, "*");
|
|
2243
2255
|
}), window.addEventListener(
|
|
2244
2256
|
"builder:component:stateChangeListenerActivated",
|
|
2245
|
-
|
|
2257
|
+
B
|
|
2246
2258
|
);
|
|
2247
2259
|
}
|
|
2248
|
-
function
|
|
2249
|
-
const
|
|
2250
|
-
`builder.preview.${
|
|
2251
|
-
),
|
|
2252
|
-
|
|
2260
|
+
function N(m) {
|
|
2261
|
+
const f = new URL(location.href).searchParams, g = f.get("builder.preview"), x = f.get(
|
|
2262
|
+
`builder.preview.${g}`
|
|
2263
|
+
), p = f.get("apiKey") || f.get("builder.space");
|
|
2264
|
+
g === e.model && p === e.apiKey && (!e.content || x === e.content.id) && Ie({
|
|
2253
2265
|
model: e.model,
|
|
2254
2266
|
apiKey: e.apiKey,
|
|
2255
2267
|
apiVersion: e.builderContextSignal.apiVersion
|
|
2256
2268
|
}).then((T) => {
|
|
2257
|
-
T &&
|
|
2269
|
+
T && o(T);
|
|
2258
2270
|
});
|
|
2259
2271
|
}
|
|
2260
|
-
return
|
|
2272
|
+
return E(() => {
|
|
2261
2273
|
var m;
|
|
2262
2274
|
return (m = t.current) == null || m.addEventListener(
|
|
2263
2275
|
"initeditingbldr",
|
|
2264
|
-
|
|
2276
|
+
A
|
|
2265
2277
|
), () => {
|
|
2266
|
-
var
|
|
2267
|
-
return (
|
|
2278
|
+
var f;
|
|
2279
|
+
return (f = t.current) == null ? void 0 : f.removeEventListener(
|
|
2268
2280
|
"initeditingbldr",
|
|
2269
|
-
|
|
2281
|
+
A
|
|
2270
2282
|
);
|
|
2271
2283
|
};
|
|
2272
|
-
}, []),
|
|
2284
|
+
}, []), E(() => {
|
|
2273
2285
|
var m;
|
|
2274
2286
|
return (m = t.current) == null || m.addEventListener(
|
|
2275
2287
|
"initpreviewingbldr",
|
|
2276
|
-
|
|
2288
|
+
N
|
|
2277
2289
|
), () => {
|
|
2278
|
-
var
|
|
2279
|
-
return (
|
|
2290
|
+
var f;
|
|
2291
|
+
return (f = t.current) == null ? void 0 : f.removeEventListener(
|
|
2280
2292
|
"initpreviewingbldr",
|
|
2281
|
-
|
|
2293
|
+
N
|
|
2282
2294
|
);
|
|
2283
2295
|
};
|
|
2284
|
-
}, []),
|
|
2285
|
-
var m,
|
|
2296
|
+
}, []), E(() => {
|
|
2297
|
+
var m, f;
|
|
2286
2298
|
if ($()) {
|
|
2287
2299
|
if (V() && t.current && t.current.dispatchEvent(new CustomEvent("initeditingbldr")), e.builderContextSignal.content && D(e.canTrack)) {
|
|
2288
|
-
const
|
|
2289
|
-
|
|
2300
|
+
const x = (m = e.builderContextSignal.content) == null ? void 0 : m.testVariationId, p = (f = e.builderContextSignal.content) == null ? void 0 : f.id, T = e.apiKey;
|
|
2301
|
+
de({
|
|
2290
2302
|
type: "impression",
|
|
2291
2303
|
canTrack: !0,
|
|
2292
|
-
contentId:
|
|
2304
|
+
contentId: p,
|
|
2293
2305
|
apiKey: T,
|
|
2294
|
-
variationId:
|
|
2306
|
+
variationId: x !== p ? x : void 0
|
|
2295
2307
|
});
|
|
2296
2308
|
}
|
|
2297
|
-
|
|
2309
|
+
_e() && t.current && t.current.dispatchEvent(new CustomEvent("initpreviewingbldr"));
|
|
2298
2310
|
}
|
|
2299
|
-
}, []),
|
|
2311
|
+
}, []), E(() => {
|
|
2300
2312
|
e.apiKey || U.error(
|
|
2301
2313
|
"No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."
|
|
2302
|
-
),
|
|
2303
|
-
}, []),
|
|
2304
|
-
e.content &&
|
|
2305
|
-
}, [e.content]),
|
|
2306
|
-
}, [r]),
|
|
2307
|
-
|
|
2314
|
+
), b(), I(), B();
|
|
2315
|
+
}, []), E(() => {
|
|
2316
|
+
e.content && o(e.content);
|
|
2317
|
+
}, [e.content]), E(() => {
|
|
2318
|
+
}, [r]), E(() => {
|
|
2319
|
+
b();
|
|
2308
2320
|
}, [
|
|
2309
|
-
(
|
|
2321
|
+
(q = (F = e.builderContextSignal.content) == null ? void 0 : F.data) == null ? void 0 : q.jsCode,
|
|
2310
2322
|
e.builderContextSignal.rootState
|
|
2311
|
-
]),
|
|
2312
|
-
|
|
2313
|
-
}, [(
|
|
2314
|
-
|
|
2315
|
-
}, [e.builderContextSignal.rootState]),
|
|
2316
|
-
|
|
2323
|
+
]), E(() => {
|
|
2324
|
+
I();
|
|
2325
|
+
}, [(oe = (ae = e.builderContextSignal.content) == null ? void 0 : ae.data) == null ? void 0 : oe.httpRequests]), E(() => {
|
|
2326
|
+
B();
|
|
2327
|
+
}, [e.builderContextSignal.rootState]), E(() => {
|
|
2328
|
+
e.data && a(e.data);
|
|
2329
|
+
}, [e.data]), E(() => {
|
|
2330
|
+
e.locale && a({
|
|
2331
|
+
locale: e.locale
|
|
2332
|
+
});
|
|
2333
|
+
}, [e.locale]), E(() => () => {
|
|
2334
|
+
$() && (window.removeEventListener("message", u), window.removeEventListener(
|
|
2317
2335
|
"builder:component:stateChangeListenerActivated",
|
|
2318
|
-
|
|
2336
|
+
B
|
|
2319
2337
|
));
|
|
2320
|
-
}, []), /* @__PURE__ */ c(ne.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content ? /* @__PURE__ */ c(
|
|
2321
|
-
|
|
2338
|
+
}, []), /* @__PURE__ */ c(ne.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ we(
|
|
2339
|
+
l,
|
|
2322
2340
|
{
|
|
2323
2341
|
key: n,
|
|
2324
2342
|
ref: t,
|
|
2325
|
-
onClick: (m) =>
|
|
2326
|
-
"builder-content-id": (
|
|
2343
|
+
onClick: (m) => R(m),
|
|
2344
|
+
"builder-content-id": (re = e.builderContextSignal.content) == null ? void 0 : re.id,
|
|
2327
2345
|
"builder-model": e.model,
|
|
2328
2346
|
...e.showContent ? {} : {
|
|
2329
2347
|
hidden: !0,
|
|
2330
2348
|
"aria-hidden": !0
|
|
2331
2349
|
},
|
|
2332
2350
|
...e.contentWrapperProps,
|
|
2333
|
-
className: `variant-${((
|
|
2351
|
+
className: `variant-${((ce = e.content) == null ? void 0 : ce.testVariationId) || ((le = e.content) == null ? void 0 : le.id)}`
|
|
2334
2352
|
},
|
|
2335
2353
|
e.children
|
|
2336
2354
|
) }) : null });
|
|
2337
2355
|
}
|
|
2338
|
-
const
|
|
2339
|
-
var
|
|
2340
|
-
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (
|
|
2356
|
+
const Gt = (e) => {
|
|
2357
|
+
var o, r;
|
|
2358
|
+
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (r = e.fileUrl) != null ? r : (o = e == null ? void 0 : e.files) == null ? void 0 : o.regular;
|
|
2341
2359
|
let a = "";
|
|
2342
2360
|
if (i && t && n && (a += `
|
|
2343
2361
|
@font-face {
|
|
@@ -2361,23 +2379,23 @@ font-weight: ${s};
|
|
|
2361
2379
|
`.trim());
|
|
2362
2380
|
}
|
|
2363
2381
|
return a;
|
|
2364
|
-
},
|
|
2382
|
+
}, Jt = ({
|
|
2365
2383
|
customFonts: e
|
|
2366
2384
|
}) => {
|
|
2367
2385
|
var t;
|
|
2368
|
-
return ((t = e == null ? void 0 : e.map((n) =>
|
|
2369
|
-
},
|
|
2386
|
+
return ((t = e == null ? void 0 : e.map((n) => Gt(n))) == null ? void 0 : t.join(" ")) || "";
|
|
2387
|
+
}, Xt = ({
|
|
2370
2388
|
cssCode: e,
|
|
2371
2389
|
contentId: t
|
|
2372
2390
|
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "";
|
|
2373
|
-
function
|
|
2391
|
+
function Zt(e) {
|
|
2374
2392
|
const [t, n] = S(
|
|
2375
2393
|
() => `
|
|
2376
|
-
${
|
|
2394
|
+
${Xt({
|
|
2377
2395
|
cssCode: e.cssCode,
|
|
2378
2396
|
contentId: e.contentId
|
|
2379
2397
|
})}
|
|
2380
|
-
${
|
|
2398
|
+
${Jt({
|
|
2381
2399
|
customFonts: e.customFonts
|
|
2382
2400
|
})}
|
|
2383
2401
|
|
|
@@ -2397,14 +2415,14 @@ ${Gt({
|
|
|
2397
2415
|
);
|
|
2398
2416
|
return /* @__PURE__ */ c(H, { styles: t });
|
|
2399
2417
|
}
|
|
2400
|
-
const
|
|
2418
|
+
const en = ({
|
|
2401
2419
|
content: e,
|
|
2402
2420
|
data: t,
|
|
2403
2421
|
locale: n
|
|
2404
2422
|
}) => {
|
|
2405
|
-
var
|
|
2406
|
-
const i = {}, a = ((
|
|
2407
|
-
return (s = (
|
|
2423
|
+
var o, r, s;
|
|
2424
|
+
const i = {}, a = ((o = e == null ? void 0 : e.data) == null ? void 0 : o.state) || {};
|
|
2425
|
+
return (s = (r = e == null ? void 0 : e.data) == null ? void 0 : r.inputs) == null || s.forEach((l) => {
|
|
2408
2426
|
l.name && l.defaultValue !== void 0 && (i[l.name] = l.defaultValue);
|
|
2409
2427
|
}), {
|
|
2410
2428
|
...i,
|
|
@@ -2414,7 +2432,7 @@ const Zt = ({
|
|
|
2414
2432
|
locale: n
|
|
2415
2433
|
} : {}
|
|
2416
2434
|
};
|
|
2417
|
-
},
|
|
2435
|
+
}, tn = ({
|
|
2418
2436
|
content: e,
|
|
2419
2437
|
data: t
|
|
2420
2438
|
}) => e ? {
|
|
@@ -2425,52 +2443,52 @@ const Zt = ({
|
|
|
2425
2443
|
},
|
|
2426
2444
|
meta: e == null ? void 0 : e.meta
|
|
2427
2445
|
} : void 0;
|
|
2428
|
-
function
|
|
2429
|
-
var l, d, u,
|
|
2446
|
+
function ke(e) {
|
|
2447
|
+
var l, d, u, b, v, y, C;
|
|
2430
2448
|
const [t, n] = S(
|
|
2431
2449
|
() => {
|
|
2432
|
-
var
|
|
2433
|
-
return
|
|
2450
|
+
var k, R;
|
|
2451
|
+
return Dt({
|
|
2434
2452
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2435
|
-
variationId: (
|
|
2453
|
+
variationId: (k = e.content) == null ? void 0 : k.testVariationId,
|
|
2436
2454
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2437
2455
|
contentId: (R = e.content) == null ? void 0 : R.id
|
|
2438
2456
|
});
|
|
2439
2457
|
}
|
|
2440
2458
|
);
|
|
2441
|
-
function i(
|
|
2459
|
+
function i(k) {
|
|
2442
2460
|
s((R) => ({
|
|
2443
2461
|
...R,
|
|
2444
|
-
rootState:
|
|
2462
|
+
rootState: k
|
|
2445
2463
|
}));
|
|
2446
2464
|
}
|
|
2447
|
-
const [a,
|
|
2465
|
+
const [a, o] = S(
|
|
2448
2466
|
() => [
|
|
2449
|
-
...
|
|
2467
|
+
...ye(),
|
|
2450
2468
|
// While this `components` object is deprecated, we must maintain support for it.
|
|
2451
2469
|
// Since users are able to override our default components, we need to make sure that we do not break such
|
|
2452
2470
|
// existing usage.
|
|
2453
2471
|
// This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
|
|
2454
2472
|
// which is the new standard way of providing custom components, and must therefore take precedence.
|
|
2455
|
-
...
|
|
2473
|
+
...ue,
|
|
2456
2474
|
...e.customComponents || []
|
|
2457
2475
|
].reduce(
|
|
2458
|
-
(
|
|
2459
|
-
...
|
|
2476
|
+
(k, { component: R, ...W }) => ({
|
|
2477
|
+
...k,
|
|
2460
2478
|
[W.name]: {
|
|
2461
2479
|
component: R,
|
|
2462
|
-
...
|
|
2480
|
+
...me(W)
|
|
2463
2481
|
}
|
|
2464
2482
|
}),
|
|
2465
2483
|
{}
|
|
2466
2484
|
)
|
|
2467
|
-
), [
|
|
2468
|
-
content:
|
|
2485
|
+
), [r, s] = S(() => ({
|
|
2486
|
+
content: tn({
|
|
2469
2487
|
content: e.content,
|
|
2470
2488
|
data: e.data
|
|
2471
2489
|
}),
|
|
2472
2490
|
localState: void 0,
|
|
2473
|
-
rootState:
|
|
2491
|
+
rootState: en({
|
|
2474
2492
|
content: e.content,
|
|
2475
2493
|
data: e.data,
|
|
2476
2494
|
locale: e.locale
|
|
@@ -2480,18 +2498,18 @@ function ve(e) {
|
|
|
2480
2498
|
apiKey: e.apiKey,
|
|
2481
2499
|
apiVersion: e.apiVersion,
|
|
2482
2500
|
componentInfos: [
|
|
2483
|
-
...
|
|
2501
|
+
...ye(),
|
|
2484
2502
|
// While this `components` object is deprecated, we must maintain support for it.
|
|
2485
2503
|
// Since users are able to override our default components, we need to make sure that we do not break such
|
|
2486
2504
|
// existing usage.
|
|
2487
2505
|
// This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
|
|
2488
2506
|
// which is the new standard way of providing custom components, and must therefore take precedence.
|
|
2489
|
-
...
|
|
2507
|
+
...ue,
|
|
2490
2508
|
...e.customComponents || []
|
|
2491
2509
|
].reduce(
|
|
2492
|
-
(
|
|
2493
|
-
...
|
|
2494
|
-
[W.name]:
|
|
2510
|
+
(k, { component: R, ...W }) => ({
|
|
2511
|
+
...k,
|
|
2512
|
+
[W.name]: me(W)
|
|
2495
2513
|
}),
|
|
2496
2514
|
{}
|
|
2497
2515
|
),
|
|
@@ -2500,15 +2518,16 @@ function ve(e) {
|
|
|
2500
2518
|
BlocksWrapperProps: e.blocksWrapperProps || {}
|
|
2501
2519
|
}));
|
|
2502
2520
|
return /* @__PURE__ */ c(
|
|
2503
|
-
|
|
2521
|
+
Te.Provider,
|
|
2504
2522
|
{
|
|
2505
2523
|
value: {
|
|
2506
2524
|
registeredComponents: a
|
|
2507
2525
|
},
|
|
2508
|
-
children: /* @__PURE__ */
|
|
2509
|
-
|
|
2526
|
+
children: /* @__PURE__ */ P(
|
|
2527
|
+
Qt,
|
|
2510
2528
|
{
|
|
2511
2529
|
content: e.content,
|
|
2530
|
+
data: e.data,
|
|
2512
2531
|
model: e.model,
|
|
2513
2532
|
context: e.context,
|
|
2514
2533
|
apiKey: e.apiKey,
|
|
@@ -2517,25 +2536,25 @@ function ve(e) {
|
|
|
2517
2536
|
includeRefs: e.includeRefs,
|
|
2518
2537
|
enrich: e.enrich,
|
|
2519
2538
|
showContent: e.showContent,
|
|
2520
|
-
builderContextSignal:
|
|
2539
|
+
builderContextSignal: r,
|
|
2521
2540
|
contentWrapper: e.contentWrapper,
|
|
2522
2541
|
contentWrapperProps: e.contentWrapperProps,
|
|
2523
2542
|
setBuilderContextSignal: s,
|
|
2524
2543
|
children: [
|
|
2525
|
-
e.isSsrAbTest ? /* @__PURE__ */ c(
|
|
2526
|
-
/* @__PURE__ */ c(
|
|
2527
|
-
|
|
2544
|
+
e.isSsrAbTest ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(Z, { scriptStr: t }) }) : null,
|
|
2545
|
+
/* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(
|
|
2546
|
+
Zt,
|
|
2528
2547
|
{
|
|
2529
|
-
contentId: (l =
|
|
2530
|
-
cssCode: (u = (d =
|
|
2531
|
-
customFonts: (
|
|
2548
|
+
contentId: (l = r.content) == null ? void 0 : l.id,
|
|
2549
|
+
cssCode: (u = (d = r.content) == null ? void 0 : d.data) == null ? void 0 : u.cssCode,
|
|
2550
|
+
customFonts: (v = (b = r.content) == null ? void 0 : b.data) == null ? void 0 : v.customFonts
|
|
2532
2551
|
}
|
|
2533
2552
|
) }),
|
|
2534
2553
|
/* @__PURE__ */ c(
|
|
2535
2554
|
ie,
|
|
2536
2555
|
{
|
|
2537
|
-
blocks: (
|
|
2538
|
-
context:
|
|
2556
|
+
blocks: (C = (y = r.content) == null ? void 0 : y.data) == null ? void 0 : C.blocks,
|
|
2557
|
+
context: r,
|
|
2539
2558
|
registeredComponents: a
|
|
2540
2559
|
}
|
|
2541
2560
|
)
|
|
@@ -2545,17 +2564,17 @@ function ve(e) {
|
|
|
2545
2564
|
}
|
|
2546
2565
|
);
|
|
2547
2566
|
}
|
|
2548
|
-
function
|
|
2549
|
-
var
|
|
2567
|
+
function Ve(e) {
|
|
2568
|
+
var r, s;
|
|
2550
2569
|
const [t, n] = S(
|
|
2551
|
-
() =>
|
|
2570
|
+
() => Lt({
|
|
2552
2571
|
canTrack: D(e.canTrack),
|
|
2553
2572
|
content: e.content
|
|
2554
2573
|
})
|
|
2555
2574
|
);
|
|
2556
2575
|
function i() {
|
|
2557
2576
|
var l;
|
|
2558
|
-
return
|
|
2577
|
+
return Ut(
|
|
2559
2578
|
M(e.content).map((d) => ({
|
|
2560
2579
|
id: d.testVariationId,
|
|
2561
2580
|
testRatio: d.testRatio
|
|
@@ -2566,30 +2585,30 @@ function Ae(e) {
|
|
|
2566
2585
|
function a() {
|
|
2567
2586
|
return M(e.content).map((l) => `.variant-${l.testVariationId} { display: none; } `).join("");
|
|
2568
2587
|
}
|
|
2569
|
-
function
|
|
2588
|
+
function o() {
|
|
2570
2589
|
var l;
|
|
2571
2590
|
return t ? {
|
|
2572
2591
|
...e.content,
|
|
2573
2592
|
testVariationId: (l = e.content) == null ? void 0 : l.id
|
|
2574
|
-
} :
|
|
2593
|
+
} : Me({
|
|
2575
2594
|
item: e.content,
|
|
2576
2595
|
canTrack: D(e.canTrack)
|
|
2577
2596
|
});
|
|
2578
2597
|
}
|
|
2579
|
-
return
|
|
2580
|
-
}, []), /* @__PURE__ */
|
|
2581
|
-
!e.__isNestedRender && L !== "reactNative" ? /* @__PURE__ */ c(
|
|
2582
|
-
t ? /* @__PURE__ */
|
|
2598
|
+
return E(() => {
|
|
2599
|
+
}, []), /* @__PURE__ */ P(h, { children: [
|
|
2600
|
+
!e.__isNestedRender && L !== "reactNative" ? /* @__PURE__ */ c(h, { children: /* @__PURE__ */ c(Z, { scriptStr: Mt() }) }) : null,
|
|
2601
|
+
t ? /* @__PURE__ */ P(h, { children: [
|
|
2583
2602
|
/* @__PURE__ */ c(
|
|
2584
2603
|
H,
|
|
2585
2604
|
{
|
|
2586
|
-
id: `variants-styles-${(
|
|
2605
|
+
id: `variants-styles-${(r = e.content) == null ? void 0 : r.id}`,
|
|
2587
2606
|
styles: a()
|
|
2588
2607
|
}
|
|
2589
2608
|
),
|
|
2590
2609
|
/* @__PURE__ */ c(Z, { scriptStr: i() }),
|
|
2591
2610
|
(s = M(e.content)) == null ? void 0 : s.map((l) => /* @__PURE__ */ c(
|
|
2592
|
-
|
|
2611
|
+
ke,
|
|
2593
2612
|
{
|
|
2594
2613
|
content: l,
|
|
2595
2614
|
showContent: !1,
|
|
@@ -2613,9 +2632,9 @@ function Ae(e) {
|
|
|
2613
2632
|
))
|
|
2614
2633
|
] }) : null,
|
|
2615
2634
|
/* @__PURE__ */ c(
|
|
2616
|
-
|
|
2635
|
+
ke,
|
|
2617
2636
|
{
|
|
2618
|
-
content:
|
|
2637
|
+
content: o(),
|
|
2619
2638
|
showContent: !0,
|
|
2620
2639
|
model: e.model,
|
|
2621
2640
|
data: e.data,
|
|
@@ -2636,13 +2655,13 @@ function Ae(e) {
|
|
|
2636
2655
|
)
|
|
2637
2656
|
] });
|
|
2638
2657
|
}
|
|
2639
|
-
const
|
|
2658
|
+
const nn = async ({
|
|
2640
2659
|
builderContextValue: e,
|
|
2641
2660
|
symbol: t
|
|
2642
2661
|
}) => {
|
|
2643
2662
|
if (t != null && t.model && // This is a hack, we should not need to check for this, but it is needed for Svelte.
|
|
2644
2663
|
(e != null && e.apiKey))
|
|
2645
|
-
return
|
|
2664
|
+
return Ie({
|
|
2646
2665
|
model: t.model,
|
|
2647
2666
|
apiKey: e.apiKey,
|
|
2648
2667
|
apiVersion: e.apiVersion,
|
|
@@ -2655,8 +2674,8 @@ const tn = async ({
|
|
|
2655
2674
|
U.error("Could not fetch symbol content: ", n);
|
|
2656
2675
|
});
|
|
2657
2676
|
};
|
|
2658
|
-
function
|
|
2659
|
-
var
|
|
2677
|
+
function an(e) {
|
|
2678
|
+
var o, r, s;
|
|
2660
2679
|
function t() {
|
|
2661
2680
|
var l, d;
|
|
2662
2681
|
return [
|
|
@@ -2671,18 +2690,18 @@ function nn(e) {
|
|
|
2671
2690
|
return (l = e.symbol) == null ? void 0 : l.content;
|
|
2672
2691
|
});
|
|
2673
2692
|
function a() {
|
|
2674
|
-
n ||
|
|
2693
|
+
n || nn({
|
|
2675
2694
|
symbol: e.symbol,
|
|
2676
2695
|
builderContextValue: e.builderContext
|
|
2677
2696
|
}).then((l) => {
|
|
2678
2697
|
l && i(l);
|
|
2679
2698
|
});
|
|
2680
2699
|
}
|
|
2681
|
-
return
|
|
2682
|
-
}, []),
|
|
2700
|
+
return E(() => {
|
|
2701
|
+
}, []), E(() => {
|
|
2683
2702
|
a();
|
|
2684
2703
|
}, [e.symbol]), /* @__PURE__ */ c("div", { ...e.attributes, className: t(), children: /* @__PURE__ */ c(
|
|
2685
|
-
|
|
2704
|
+
Ve,
|
|
2686
2705
|
{
|
|
2687
2706
|
__isNestedRender: !0,
|
|
2688
2707
|
apiVersion: e.builderContext.apiVersion,
|
|
@@ -2690,40 +2709,40 @@ function nn(e) {
|
|
|
2690
2709
|
context: e.builderContext.context,
|
|
2691
2710
|
customComponents: Object.values(e.builderComponents),
|
|
2692
2711
|
data: {
|
|
2693
|
-
...(
|
|
2712
|
+
...(o = e.symbol) == null ? void 0 : o.data,
|
|
2694
2713
|
...e.builderContext.localState,
|
|
2695
|
-
...(
|
|
2714
|
+
...(r = n == null ? void 0 : n.data) == null ? void 0 : r.state
|
|
2696
2715
|
},
|
|
2697
2716
|
model: (s = e.symbol) == null ? void 0 : s.model,
|
|
2698
2717
|
content: n
|
|
2699
2718
|
}
|
|
2700
2719
|
) });
|
|
2701
2720
|
}
|
|
2702
|
-
const
|
|
2721
|
+
const ln = ie, sn = Ve;
|
|
2703
2722
|
export {
|
|
2704
2723
|
ie as Blocks,
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
|
|
2709
|
-
|
|
2710
|
-
|
|
2711
|
-
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
+
Ue as Button,
|
|
2725
|
+
mt as Columns,
|
|
2726
|
+
Ve as Content,
|
|
2727
|
+
ft as Fragment,
|
|
2728
|
+
bt as Image,
|
|
2729
|
+
ln as RenderBlocks,
|
|
2730
|
+
sn as RenderContent,
|
|
2731
|
+
xt as Section,
|
|
2732
|
+
an as Symbol,
|
|
2733
|
+
Vt as Text,
|
|
2734
|
+
Nt as Video,
|
|
2735
|
+
mn as _processContentResult,
|
|
2736
|
+
Le as createRegisterComponentMessage,
|
|
2737
|
+
fn as fetchBuilderProps,
|
|
2738
|
+
hn as fetchEntries,
|
|
2739
|
+
Ie as fetchOneEntry,
|
|
2740
|
+
gn as getAllContent,
|
|
2741
|
+
bn as getBuilderSearchParams,
|
|
2742
|
+
xn as getContent,
|
|
2724
2743
|
V as isEditing,
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2744
|
+
_e as isPreviewing,
|
|
2745
|
+
Fe as register,
|
|
2746
|
+
yn as setEditorSettings,
|
|
2747
|
+
Sn as track
|
|
2729
2748
|
};
|