@builder.io/sdk-react-nextjs 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/USE_CLIENT_BUNDLE-34ca6573.js +23 -0
- package/lib/browser/USE_CLIENT_BUNDLE-35cf57f2.mjs +657 -0
- package/lib/browser/USE_SERVER_BUNDLE-5f0752b4.mjs +11 -0
- package/lib/{edge/USE_SERVER_BUNDLE-105e9ef3.js → browser/USE_SERVER_BUNDLE-da1cf240.js} +1 -1
- package/lib/browser/{bundle-3b073b16.mjs → bundle-f0e86750.mjs} +680 -663
- package/lib/browser/bundle-fa4c07cb.js +76 -0
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +7 -7
- package/lib/edge/USE_CLIENT_BUNDLE-2841cf29.js +23 -0
- package/lib/edge/USE_CLIENT_BUNDLE-aeac6d00.mjs +657 -0
- package/lib/edge/USE_SERVER_BUNDLE-015ab545.mjs +11 -0
- package/lib/{node/USE_SERVER_BUNDLE-d8c698c8.js → edge/USE_SERVER_BUNDLE-ef1618a6.js} +1 -1
- package/lib/edge/{bundle-ed178c62.mjs → bundle-3c711a0f.mjs} +2053 -2008
- package/lib/edge/bundle-bfbd5fa6.js +96 -0
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +7 -7
- package/lib/node/USE_CLIENT_BUNDLE-a30d8b97.js +23 -0
- package/lib/node/USE_CLIENT_BUNDLE-fc82531c.mjs +657 -0
- package/lib/node/USE_SERVER_BUNDLE-25e36fa7.mjs +11 -0
- package/lib/{browser/USE_SERVER_BUNDLE-d8c698c8.js → node/USE_SERVER_BUNDLE-b26e79d4.js} +1 -1
- package/lib/node/bundle-23b73f20.js +116 -0
- package/lib/node/{bundle-3b073b16.mjs → bundle-4a8d8d92.mjs} +895 -781
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +7 -7
- package/package.json +4 -3
- 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/get-content/types.d.ts +94 -3
- package/lib/browser/USE_CLIENT_BUNDLE-3a41b1ba.js +0 -23
- package/lib/browser/USE_CLIENT_BUNDLE-fc8c1bc0.mjs +0 -618
- package/lib/browser/USE_SERVER_BUNDLE-226a15ac.mjs +0 -11
- package/lib/browser/bundle-0fae602b.js +0 -76
- package/lib/edge/USE_CLIENT_BUNDLE-0e9f8e67.mjs +0 -618
- package/lib/edge/USE_CLIENT_BUNDLE-d48583e8.js +0 -23
- package/lib/edge/USE_SERVER_BUNDLE-f6a1e321.mjs +0 -11
- package/lib/edge/bundle-0c1d9099.js +0 -96
- package/lib/node/USE_CLIENT_BUNDLE-3a41b1ba.js +0 -23
- package/lib/node/USE_CLIENT_BUNDLE-fc8c1bc0.mjs +0 -618
- package/lib/node/USE_SERVER_BUNDLE-226a15ac.mjs +0 -11
- package/lib/node/bundle-0fae602b.js +0 -76
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { LRUCache
|
|
2
|
-
import { jsx
|
|
3
|
-
import { createElement
|
|
4
|
-
import { I as
|
|
1
|
+
import { LRUCache } from "lru-cache";
|
|
2
|
+
import { jsx, Fragment, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { createElement } from "react";
|
|
4
|
+
import { I as InteractiveElement, B as BlockWrapper, a as BlocksWrapper, b as Button, C as CustomCode, E as Embed, F as FragmentComponent, c as Image, d as ImgComponent, S as SectionComponent, V as Video, e as EnableEditor } from "./USE_CLIENT_BUNDLE-fc82531c.mjs";
|
|
5
5
|
import "next/navigation";
|
|
6
|
-
const
|
|
6
|
+
const fastClone = (e) => JSON.parse(JSON.stringify(e)), SIZES = {
|
|
7
7
|
small: {
|
|
8
8
|
min: 320,
|
|
9
9
|
default: 321,
|
|
@@ -19,11 +19,11 @@ const A = (e) => JSON.parse(JSON.stringify(e)), ae = {
|
|
|
19
19
|
default: 991,
|
|
20
20
|
max: 1200
|
|
21
21
|
}
|
|
22
|
-
},
|
|
22
|
+
}, getMaxWidthQueryForSize = (e, t = SIZES) => `@media (max-width: ${t[e].max}px)`, getSizesForBreakpoints = ({
|
|
23
23
|
small: e,
|
|
24
24
|
medium: t
|
|
25
25
|
}) => {
|
|
26
|
-
const n =
|
|
26
|
+
const n = fastClone(SIZES);
|
|
27
27
|
if (!e || !t)
|
|
28
28
|
return n;
|
|
29
29
|
const o = Math.floor(e / 2);
|
|
@@ -32,42 +32,42 @@ const A = (e) => JSON.parse(JSON.stringify(e)), ae = {
|
|
|
32
32
|
min: o,
|
|
33
33
|
default: o + 1
|
|
34
34
|
};
|
|
35
|
-
const
|
|
35
|
+
const r = n.small.max + 1;
|
|
36
36
|
n.medium = {
|
|
37
37
|
max: t,
|
|
38
|
-
min:
|
|
39
|
-
default:
|
|
38
|
+
min: r,
|
|
39
|
+
default: r + 1
|
|
40
40
|
};
|
|
41
|
-
const
|
|
41
|
+
const i = n.medium.max + 1;
|
|
42
42
|
return n.large = {
|
|
43
43
|
max: 2e3,
|
|
44
44
|
// TODO: decide upper limit
|
|
45
|
-
min:
|
|
46
|
-
default:
|
|
45
|
+
min: i,
|
|
46
|
+
default: i + 1
|
|
47
47
|
}, n;
|
|
48
|
-
},
|
|
49
|
-
log: (...e) => console.log(
|
|
50
|
-
error: (...e) => console.error(
|
|
51
|
-
warn: (...e) => console.warn(
|
|
52
|
-
debug: (...e) => console.debug(
|
|
48
|
+
}, TARGET = "rsc", MSG_PREFIX = "[Builder.io]: ", logger = {
|
|
49
|
+
log: (...e) => console.log(MSG_PREFIX, ...e),
|
|
50
|
+
error: (...e) => console.error(MSG_PREFIX, ...e),
|
|
51
|
+
warn: (...e) => console.warn(MSG_PREFIX, ...e),
|
|
52
|
+
debug: (...e) => console.debug(MSG_PREFIX, ...e)
|
|
53
53
|
};
|
|
54
|
-
function
|
|
54
|
+
function isBrowser() {
|
|
55
55
|
return typeof window < "u" && typeof document < "u";
|
|
56
56
|
}
|
|
57
|
-
function
|
|
58
|
-
return
|
|
57
|
+
function isIframe() {
|
|
58
|
+
return isBrowser() && window.self !== window.top;
|
|
59
59
|
}
|
|
60
|
-
function
|
|
61
|
-
return
|
|
60
|
+
function isEditing() {
|
|
61
|
+
return isIframe() && window.location.search.indexOf("builder.frameEditing=") !== -1;
|
|
62
62
|
}
|
|
63
|
-
const
|
|
64
|
-
if (
|
|
63
|
+
const getLocation = () => {
|
|
64
|
+
if (isBrowser()) {
|
|
65
65
|
const e = new URL(location.href);
|
|
66
66
|
return e.pathname === "" && (e.pathname = "/"), e;
|
|
67
67
|
} else
|
|
68
68
|
return console.warn("Cannot get location for tracking in non-browser environment"), null;
|
|
69
|
-
},
|
|
70
|
-
const e =
|
|
69
|
+
}, getUserAgent = () => typeof navigator == "object" && navigator.userAgent || "", getUserAttributes = () => {
|
|
70
|
+
const e = getUserAgent(), t = {
|
|
71
71
|
Android() {
|
|
72
72
|
return e.match(/Android/i);
|
|
73
73
|
},
|
|
@@ -84,15 +84,15 @@ const _e = () => {
|
|
|
84
84
|
return e.match(/IEMobile/i) || e.match(/WPDesktop/i);
|
|
85
85
|
},
|
|
86
86
|
any() {
|
|
87
|
-
return t.Android() || t.BlackBerry() || t.iOS() || t.Opera() || t.Windows() ||
|
|
87
|
+
return t.Android() || t.BlackBerry() || t.iOS() || t.Opera() || t.Windows() || TARGET === "reactNative";
|
|
88
88
|
}
|
|
89
|
-
}, n = e.match(/Tablet|iPad/i), o =
|
|
89
|
+
}, n = e.match(/Tablet|iPad/i), o = getLocation();
|
|
90
90
|
return {
|
|
91
91
|
urlPath: o == null ? void 0 : o.pathname,
|
|
92
92
|
host: (o == null ? void 0 : o.host) || (o == null ? void 0 : o.hostname),
|
|
93
93
|
device: n ? "tablet" : t.any() ? "mobile" : "desktop"
|
|
94
94
|
};
|
|
95
|
-
},
|
|
95
|
+
}, getFunctionArguments = ({
|
|
96
96
|
builder: e,
|
|
97
97
|
context: t,
|
|
98
98
|
event: n,
|
|
@@ -104,146 +104,248 @@ const _e = () => {
|
|
|
104
104
|
builder: e,
|
|
105
105
|
context: t,
|
|
106
106
|
event: n
|
|
107
|
-
}),
|
|
107
|
+
}), getBuilderGlobals = () => ({
|
|
108
|
+
isEditing: isEditing(),
|
|
109
|
+
isBrowser: isBrowser(),
|
|
110
|
+
isServer: !isBrowser(),
|
|
111
|
+
getUserAttributes: () => getUserAttributes()
|
|
112
|
+
}), parseCode = (e, {
|
|
113
|
+
isExpression: t = !0
|
|
114
|
+
}) => /* 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, runInBrowser = ({
|
|
108
115
|
code: e,
|
|
109
116
|
builder: t,
|
|
110
117
|
context: n,
|
|
111
118
|
event: o,
|
|
112
|
-
localState:
|
|
113
|
-
rootSetState:
|
|
119
|
+
localState: r,
|
|
120
|
+
rootSetState: i,
|
|
114
121
|
rootState: a
|
|
115
122
|
}) => {
|
|
116
|
-
const c =
|
|
123
|
+
const c = getFunctionArguments({
|
|
117
124
|
builder: t,
|
|
118
125
|
context: n,
|
|
119
126
|
event: o,
|
|
120
|
-
state:
|
|
127
|
+
state: flattenState(a, r, i)
|
|
121
128
|
});
|
|
122
129
|
return new Function(...c.map(([s]) => s), e)(...c.map(([, s]) => s));
|
|
123
130
|
};
|
|
124
|
-
function
|
|
131
|
+
function flattenState(e, t, n) {
|
|
125
132
|
if (e === t)
|
|
126
133
|
throw new Error("rootState === localState");
|
|
127
134
|
return new Proxy(e, {
|
|
128
|
-
get: (o,
|
|
129
|
-
set: (o,
|
|
130
|
-
if (t &&
|
|
135
|
+
get: (o, r) => t && r in t ? t[r] : e[r],
|
|
136
|
+
set: (o, r, i) => {
|
|
137
|
+
if (t && r in t)
|
|
131
138
|
throw new Error("Writing to local state is not allowed as it is read-only.");
|
|
132
|
-
return e[
|
|
139
|
+
return e[r] = i, n == null || n(e), !0;
|
|
133
140
|
}
|
|
134
141
|
});
|
|
135
142
|
}
|
|
136
|
-
|
|
143
|
+
const noop = () => null;
|
|
144
|
+
let safeDynamicRequire = noop;
|
|
145
|
+
try {
|
|
146
|
+
safeDynamicRequire = eval("require");
|
|
147
|
+
} catch (e) {
|
|
148
|
+
}
|
|
149
|
+
const set = (e, t, n) => {
|
|
150
|
+
if (Object(e) !== e)
|
|
151
|
+
return e;
|
|
152
|
+
const o = Array.isArray(t) ? t : t.toString().match(/[^.[\]]+/g);
|
|
153
|
+
return o.slice(0, -1).reduce((r, i, a) => Object(r[i]) === r[i] ? r[i] : r[i] = Math.abs(Number(o[a + 1])) >> 0 === +o[a + 1] ? [] : {}, e)[o[o.length - 1]] = n, e;
|
|
154
|
+
}, ivm = safeDynamicRequire("isolated-vm"), getSyncValName = (e) => `bldr_${e}_sync`, BUILDER_SET_STATE_NAME = "BUILDER_SET_STATE", INJECTED_IVM_GLOBAL = "BUILDER_IVM", REF_TO_PROXY_FN = `
|
|
155
|
+
var refToProxy = (obj) => {
|
|
156
|
+
if (typeof obj !== 'object' || obj === null) {
|
|
157
|
+
return obj;
|
|
158
|
+
}
|
|
159
|
+
return new Proxy({}, {
|
|
160
|
+
get(target, key) {
|
|
161
|
+
if (key === 'copySync') {
|
|
162
|
+
return () => obj.copySync();
|
|
163
|
+
}
|
|
164
|
+
const val = obj.getSync(key);
|
|
165
|
+
if (typeof val?.getSync === 'function') {
|
|
166
|
+
return refToProxy(val);
|
|
167
|
+
}
|
|
168
|
+
return val;
|
|
169
|
+
},
|
|
170
|
+
set(target, key, value) {
|
|
171
|
+
const v = typeof value === 'object' ? new ${INJECTED_IVM_GLOBAL}.Reference(value) : value;
|
|
172
|
+
obj.setSync(key, v);
|
|
173
|
+
${BUILDER_SET_STATE_NAME}(key, value)
|
|
174
|
+
},
|
|
175
|
+
deleteProperty(target, key) {
|
|
176
|
+
obj.deleteSync(key);
|
|
177
|
+
}
|
|
178
|
+
})
|
|
179
|
+
}
|
|
180
|
+
`, processCode = ({
|
|
181
|
+
code: e,
|
|
182
|
+
args: t
|
|
183
|
+
}) => {
|
|
184
|
+
const n = t.map(([o]) => `var ${o} = refToProxy(${getSyncValName(o)}); `).join("");
|
|
185
|
+
return `
|
|
186
|
+
${REF_TO_PROXY_FN}
|
|
187
|
+
${n}
|
|
188
|
+
function theFunction() {
|
|
189
|
+
${e}
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
let output = theFunction()
|
|
193
|
+
|
|
194
|
+
if (typeof output === 'object' && output !== null) {
|
|
195
|
+
output = JSON.stringify(output.copySync ? output.copySync() : output);
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
output;
|
|
199
|
+
`;
|
|
200
|
+
}, getIsolateContext = () => new ivm.Isolate({
|
|
201
|
+
memoryLimit: 128
|
|
202
|
+
}).createContextSync(), runInNode = ({
|
|
203
|
+
code: e,
|
|
204
|
+
builder: t,
|
|
205
|
+
context: n,
|
|
206
|
+
event: o,
|
|
207
|
+
localState: r,
|
|
208
|
+
rootSetState: i,
|
|
209
|
+
rootState: a
|
|
210
|
+
}) => {
|
|
211
|
+
const c = fastClone({
|
|
212
|
+
...a,
|
|
213
|
+
...r
|
|
214
|
+
}), s = getFunctionArguments({
|
|
215
|
+
builder: t,
|
|
216
|
+
context: n,
|
|
217
|
+
event: o,
|
|
218
|
+
state: c
|
|
219
|
+
}), u = getIsolateContext(), m = u.global;
|
|
220
|
+
m.setSync("global", m.derefInto()), m.setSync("log", function(...l) {
|
|
221
|
+
console.log(...l);
|
|
222
|
+
}), m.setSync(BUILDER_SET_STATE_NAME, function(l, f) {
|
|
223
|
+
set(a, l, f), i == null || i(a);
|
|
224
|
+
}), s.forEach(([l, f]) => {
|
|
225
|
+
const d = typeof f == "object" ? new ivm.Reference(
|
|
226
|
+
// workaround: methods with default values for arguments is not being cloned over
|
|
227
|
+
l === "builder" ? {
|
|
228
|
+
...f,
|
|
229
|
+
getUserAttributes: () => f.getUserAttributes()
|
|
230
|
+
} : f
|
|
231
|
+
) : null;
|
|
232
|
+
m.setSync(getSyncValName(l), d);
|
|
233
|
+
}), m.setSync(INJECTED_IVM_GLOBAL, ivm);
|
|
234
|
+
const h = processCode({
|
|
235
|
+
code: e,
|
|
236
|
+
args: s
|
|
237
|
+
}), p = u.evalSync(h);
|
|
238
|
+
try {
|
|
239
|
+
return JSON.parse(p);
|
|
240
|
+
} catch {
|
|
241
|
+
return p;
|
|
242
|
+
}
|
|
243
|
+
}, chooseBrowserOrServerEval = (e) => isBrowser() ? runInBrowser(e) : runInNode(e);
|
|
244
|
+
function evaluate({
|
|
137
245
|
code: e,
|
|
138
246
|
context: t,
|
|
139
247
|
localState: n,
|
|
140
248
|
rootState: o,
|
|
141
|
-
rootSetState:
|
|
142
|
-
event:
|
|
249
|
+
rootSetState: r,
|
|
250
|
+
event: i,
|
|
143
251
|
isExpression: a = !0
|
|
144
252
|
}) {
|
|
145
253
|
if (e === "") {
|
|
146
|
-
|
|
254
|
+
logger.warn("Skipping evaluation of empty code block.");
|
|
147
255
|
return;
|
|
148
256
|
}
|
|
149
257
|
const c = {
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
}, f = {
|
|
155
|
-
code: /* we disable this for cases where we definitely don't want a return */ a && !(e.includes(";") || e.includes(" return ") || e.trim().startsWith("return ")) ? `return (${e});` : e,
|
|
156
|
-
builder: c,
|
|
258
|
+
code: parseCode(e, {
|
|
259
|
+
isExpression: a
|
|
260
|
+
}),
|
|
261
|
+
builder: getBuilderGlobals(),
|
|
157
262
|
context: t,
|
|
158
|
-
event:
|
|
159
|
-
rootSetState:
|
|
263
|
+
event: i,
|
|
264
|
+
rootSetState: r,
|
|
160
265
|
rootState: o,
|
|
161
266
|
localState: n
|
|
162
267
|
};
|
|
163
268
|
try {
|
|
164
|
-
return
|
|
165
|
-
} catch (
|
|
166
|
-
|
|
269
|
+
return chooseBrowserOrServerEval(c);
|
|
270
|
+
} catch (s) {
|
|
271
|
+
logger.error("Failed code evaluation: " + s.message, {
|
|
167
272
|
code: e
|
|
168
273
|
});
|
|
169
274
|
return;
|
|
170
275
|
}
|
|
171
276
|
}
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
return o.slice(0, -1).reduce((i, r, a) => Object(i[r]) === i[r] ? i[r] : i[r] = Math.abs(Number(o[a + 1])) >> 0 === +o[a + 1] ? [] : {}, e)[o[o.length - 1]] = n, e;
|
|
177
|
-
};
|
|
178
|
-
const qe = ({
|
|
277
|
+
function transformBlock(e) {
|
|
278
|
+
return e;
|
|
279
|
+
}
|
|
280
|
+
const evaluateBindings = ({
|
|
179
281
|
block: e,
|
|
180
282
|
context: t,
|
|
181
283
|
localState: n,
|
|
182
284
|
rootState: o,
|
|
183
|
-
rootSetState:
|
|
285
|
+
rootSetState: r
|
|
184
286
|
}) => {
|
|
185
287
|
if (!e.bindings)
|
|
186
288
|
return e;
|
|
187
|
-
const
|
|
188
|
-
...
|
|
289
|
+
const i = fastClone(e), a = {
|
|
290
|
+
...i,
|
|
189
291
|
properties: {
|
|
190
|
-
...
|
|
292
|
+
...i.properties
|
|
191
293
|
},
|
|
192
294
|
actions: {
|
|
193
|
-
...
|
|
295
|
+
...i.actions
|
|
194
296
|
}
|
|
195
297
|
};
|
|
196
298
|
for (const c in e.bindings) {
|
|
197
|
-
const s = e.bindings[c], u =
|
|
299
|
+
const s = e.bindings[c], u = evaluate({
|
|
198
300
|
code: s,
|
|
199
301
|
localState: n,
|
|
200
302
|
rootState: o,
|
|
201
|
-
rootSetState:
|
|
303
|
+
rootSetState: r,
|
|
202
304
|
context: t
|
|
203
305
|
});
|
|
204
|
-
|
|
306
|
+
set(a, c, u);
|
|
205
307
|
}
|
|
206
308
|
return a;
|
|
207
309
|
};
|
|
208
|
-
function
|
|
310
|
+
function getProcessedBlock({
|
|
209
311
|
block: e,
|
|
210
312
|
context: t,
|
|
211
313
|
shouldEvaluateBindings: n,
|
|
212
314
|
localState: o,
|
|
213
|
-
rootState:
|
|
214
|
-
rootSetState:
|
|
315
|
+
rootState: r,
|
|
316
|
+
rootSetState: i
|
|
215
317
|
}) {
|
|
216
318
|
const a = e;
|
|
217
|
-
return n ?
|
|
319
|
+
return n ? evaluateBindings({
|
|
218
320
|
block: a,
|
|
219
321
|
localState: o,
|
|
220
|
-
rootState:
|
|
221
|
-
rootSetState:
|
|
322
|
+
rootState: r,
|
|
323
|
+
rootSetState: i,
|
|
222
324
|
context: t
|
|
223
325
|
}) : a;
|
|
224
326
|
}
|
|
225
|
-
const
|
|
327
|
+
const camelToKebabCase = (e) => e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase(), checkIsDefined = (e) => e != null, convertStyleMapToCSSArray = (e) => Object.entries(e).map(([n, o]) => {
|
|
226
328
|
if (typeof o == "string")
|
|
227
|
-
return `${
|
|
228
|
-
}).filter(
|
|
229
|
-
`),
|
|
329
|
+
return `${camelToKebabCase(n)}: ${o};`;
|
|
330
|
+
}).filter(checkIsDefined), convertStyleMapToCSS = (e) => convertStyleMapToCSSArray(e).join(`
|
|
331
|
+
`), createCssClass = ({
|
|
230
332
|
mediaQuery: e,
|
|
231
333
|
className: t,
|
|
232
334
|
styles: n
|
|
233
335
|
}) => {
|
|
234
336
|
const o = `.${t} {
|
|
235
|
-
${
|
|
337
|
+
${convertStyleMapToCSS(n)}
|
|
236
338
|
}`;
|
|
237
339
|
return e ? `${e} {
|
|
238
340
|
${o}
|
|
239
341
|
}` : o;
|
|
240
342
|
};
|
|
241
|
-
function
|
|
242
|
-
return /* @__PURE__ */
|
|
343
|
+
function InlinedStyles(e) {
|
|
344
|
+
return /* @__PURE__ */ jsx("style", { dangerouslySetInnerHTML: { __html: e.styles }, id: e.id });
|
|
243
345
|
}
|
|
244
|
-
function
|
|
346
|
+
function BlockStyles(e) {
|
|
245
347
|
const t = function() {
|
|
246
|
-
const
|
|
348
|
+
const r = getProcessedBlock({
|
|
247
349
|
block: e.block,
|
|
248
350
|
localState: e.context.localState,
|
|
249
351
|
rootState: e.context.rootState,
|
|
@@ -251,44 +353,44 @@ function U(e) {
|
|
|
251
353
|
context: e.context.context,
|
|
252
354
|
shouldEvaluateBindings: !0
|
|
253
355
|
});
|
|
254
|
-
return
|
|
356
|
+
return checkIsDefined(r.hide) ? !r.hide : checkIsDefined(r.show) ? r.show : !0;
|
|
255
357
|
}, n = function() {
|
|
256
358
|
var d;
|
|
257
|
-
const
|
|
359
|
+
const r = getProcessedBlock({
|
|
258
360
|
block: e.block,
|
|
259
361
|
localState: e.context.localState,
|
|
260
362
|
rootState: e.context.rootState,
|
|
261
363
|
rootSetState: e.context.rootSetState,
|
|
262
364
|
context: e.context.context,
|
|
263
365
|
shouldEvaluateBindings: !0
|
|
264
|
-
}),
|
|
366
|
+
}), i = r.responsiveStyles, a = e.context.content, c = getSizesForBreakpoints(
|
|
265
367
|
((d = a == null ? void 0 : a.meta) == null ? void 0 : d.breakpoints) || {}
|
|
266
|
-
), s =
|
|
267
|
-
if (!
|
|
368
|
+
), s = i == null ? void 0 : i.large, u = i == null ? void 0 : i.medium, m = i == null ? void 0 : i.small, h = r.id;
|
|
369
|
+
if (!h)
|
|
268
370
|
return "";
|
|
269
|
-
const p = s ?
|
|
270
|
-
className:
|
|
371
|
+
const p = s ? createCssClass({
|
|
372
|
+
className: h,
|
|
271
373
|
styles: s
|
|
272
|
-
}) : "",
|
|
273
|
-
className:
|
|
374
|
+
}) : "", l = u ? createCssClass({
|
|
375
|
+
className: h,
|
|
274
376
|
styles: u,
|
|
275
|
-
mediaQuery:
|
|
377
|
+
mediaQuery: getMaxWidthQueryForSize(
|
|
276
378
|
"medium",
|
|
277
379
|
c
|
|
278
380
|
)
|
|
279
|
-
}) : "",
|
|
280
|
-
className:
|
|
281
|
-
styles:
|
|
282
|
-
mediaQuery:
|
|
381
|
+
}) : "", f = m ? createCssClass({
|
|
382
|
+
className: h,
|
|
383
|
+
styles: m,
|
|
384
|
+
mediaQuery: getMaxWidthQueryForSize(
|
|
283
385
|
"small",
|
|
284
386
|
c
|
|
285
387
|
)
|
|
286
388
|
}) : "";
|
|
287
|
-
return [p,
|
|
389
|
+
return [p, l, f].join(" ");
|
|
288
390
|
};
|
|
289
|
-
return /* @__PURE__ */
|
|
391
|
+
return /* @__PURE__ */ jsx(Fragment, { children: n() && t() ? /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(InlinedStyles, { styles: n() }) }) : null });
|
|
290
392
|
}
|
|
291
|
-
function
|
|
393
|
+
function getBlockComponentOptions(e) {
|
|
292
394
|
var t;
|
|
293
395
|
return {
|
|
294
396
|
...(t = e.component) == null ? void 0 : t.options,
|
|
@@ -299,29 +401,29 @@ function Ye(e) {
|
|
|
299
401
|
builderBlock: e
|
|
300
402
|
};
|
|
301
403
|
}
|
|
302
|
-
const
|
|
404
|
+
const EMPTY_HTML_ELEMENTS = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"], isEmptyHtmlElement = (e) => typeof e == "string" && EMPTY_HTML_ELEMENTS.includes(e.toLowerCase()), getComponent = ({
|
|
303
405
|
block: e,
|
|
304
406
|
context: t,
|
|
305
407
|
registeredComponents: n
|
|
306
408
|
}) => {
|
|
307
|
-
var
|
|
308
|
-
const o = (
|
|
409
|
+
var i;
|
|
410
|
+
const o = (i = getProcessedBlock({
|
|
309
411
|
block: e,
|
|
310
412
|
localState: t.localState,
|
|
311
413
|
rootState: t.rootState,
|
|
312
414
|
rootSetState: t.rootSetState,
|
|
313
415
|
context: t.context,
|
|
314
416
|
shouldEvaluateBindings: !1
|
|
315
|
-
}).component) == null ? void 0 :
|
|
417
|
+
}).component) == null ? void 0 : i.name;
|
|
316
418
|
if (!o)
|
|
317
419
|
return null;
|
|
318
|
-
const
|
|
319
|
-
if (
|
|
320
|
-
return
|
|
420
|
+
const r = n[o];
|
|
421
|
+
if (r)
|
|
422
|
+
return r;
|
|
321
423
|
console.warn(`
|
|
322
424
|
Could not find a registered component named "${o}".
|
|
323
425
|
If you registered it, is the file that registered it imported by the file that needs to render it?`);
|
|
324
|
-
},
|
|
426
|
+
}, getRepeatItemData = ({
|
|
325
427
|
block: e,
|
|
326
428
|
context: t
|
|
327
429
|
}) => {
|
|
@@ -331,17 +433,17 @@ const Xe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
331
433
|
} = e;
|
|
332
434
|
if (!(n != null && n.collection))
|
|
333
435
|
return;
|
|
334
|
-
const
|
|
436
|
+
const r = evaluate({
|
|
335
437
|
code: n.collection,
|
|
336
438
|
localState: t.localState,
|
|
337
439
|
rootState: t.rootState,
|
|
338
440
|
rootSetState: t.rootSetState,
|
|
339
441
|
context: t.context
|
|
340
442
|
});
|
|
341
|
-
if (!Array.isArray(
|
|
443
|
+
if (!Array.isArray(r))
|
|
342
444
|
return;
|
|
343
|
-
const
|
|
344
|
-
return
|
|
445
|
+
const i = n.collection.split(".").pop(), a = n.itemName || (i ? i + "Item" : "item");
|
|
446
|
+
return r.map((s, u) => ({
|
|
345
447
|
context: {
|
|
346
448
|
...t,
|
|
347
449
|
localState: {
|
|
@@ -355,10 +457,10 @@ const Xe = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen"
|
|
|
355
457
|
block: o
|
|
356
458
|
}));
|
|
357
459
|
};
|
|
358
|
-
function
|
|
460
|
+
function RepeatedBlock(e) {
|
|
359
461
|
const t = e.repeatContext;
|
|
360
|
-
return /* @__PURE__ */
|
|
361
|
-
|
|
462
|
+
return /* @__PURE__ */ jsx(
|
|
463
|
+
Block,
|
|
362
464
|
{
|
|
363
465
|
block: e.block,
|
|
364
466
|
context: t,
|
|
@@ -366,10 +468,10 @@ function et(e) {
|
|
|
366
468
|
}
|
|
367
469
|
);
|
|
368
470
|
}
|
|
369
|
-
function
|
|
471
|
+
function capitalizeFirstLetter(e) {
|
|
370
472
|
return e.charAt(0).toUpperCase() + e.slice(1);
|
|
371
473
|
}
|
|
372
|
-
const
|
|
474
|
+
const getEventHandlerName = (e) => `on${capitalizeFirstLetter(e)}`, createEventHandler = (e, t) => (n) => evaluate({
|
|
373
475
|
code: e,
|
|
374
476
|
context: t.context,
|
|
375
477
|
localState: t.localState,
|
|
@@ -378,54 +480,54 @@ const nt = (e) => `on${tt(e)}`, ot = (e, t) => (n) => M({
|
|
|
378
480
|
event: n,
|
|
379
481
|
isExpression: !1
|
|
380
482
|
});
|
|
381
|
-
function
|
|
483
|
+
function getBlockActions(e) {
|
|
382
484
|
const t = {}, n = e.block.actions ?? {};
|
|
383
485
|
for (const o in n) {
|
|
384
486
|
if (!n.hasOwnProperty(o))
|
|
385
487
|
continue;
|
|
386
|
-
const
|
|
387
|
-
let
|
|
488
|
+
const r = n[o];
|
|
489
|
+
let i = getEventHandlerName(o);
|
|
388
490
|
if (e.stripPrefix)
|
|
389
|
-
switch (
|
|
491
|
+
switch (TARGET) {
|
|
390
492
|
case "vue2":
|
|
391
493
|
case "vue3":
|
|
392
|
-
|
|
494
|
+
i = i.replace("v-on:", "");
|
|
393
495
|
break;
|
|
394
496
|
case "svelte":
|
|
395
|
-
|
|
497
|
+
i = i.replace("on:", "");
|
|
396
498
|
break;
|
|
397
499
|
}
|
|
398
|
-
t[
|
|
500
|
+
t[i] = createEventHandler(r, e);
|
|
399
501
|
}
|
|
400
502
|
return t;
|
|
401
503
|
}
|
|
402
|
-
function
|
|
504
|
+
function transformBlockProperties(e) {
|
|
403
505
|
return e.className = e.class, delete e.class, e;
|
|
404
506
|
}
|
|
405
|
-
const
|
|
507
|
+
const extractRelevantRootBlockProperties = (e) => ({
|
|
406
508
|
href: e.href
|
|
407
509
|
});
|
|
408
|
-
function
|
|
510
|
+
function getBlockProperties({
|
|
409
511
|
block: e,
|
|
410
512
|
context: t
|
|
411
513
|
}) {
|
|
412
514
|
var o;
|
|
413
515
|
const n = {
|
|
414
|
-
...
|
|
516
|
+
...extractRelevantRootBlockProperties(e),
|
|
415
517
|
...e.properties,
|
|
416
518
|
"builder-id": e.id,
|
|
417
|
-
style: e.style ?
|
|
519
|
+
style: e.style ? getStyleAttribute(e.style) : void 0,
|
|
418
520
|
class: [e.id, "builder-block", e.class, (o = e.properties) == null ? void 0 : o.class].filter(Boolean).join(" ")
|
|
419
521
|
};
|
|
420
|
-
return
|
|
522
|
+
return transformBlockProperties(n);
|
|
421
523
|
}
|
|
422
|
-
function
|
|
423
|
-
switch (
|
|
524
|
+
function getStyleAttribute(e) {
|
|
525
|
+
switch (TARGET) {
|
|
424
526
|
case "svelte":
|
|
425
527
|
case "vue2":
|
|
426
528
|
case "vue3":
|
|
427
529
|
case "solid":
|
|
428
|
-
return
|
|
530
|
+
return convertStyleMapToCSSArray(e).join(" ");
|
|
429
531
|
case "qwik":
|
|
430
532
|
case "reactNative":
|
|
431
533
|
case "react":
|
|
@@ -433,15 +535,15 @@ function st(e) {
|
|
|
433
535
|
return e;
|
|
434
536
|
}
|
|
435
537
|
}
|
|
436
|
-
const
|
|
538
|
+
const getWrapperProps = ({
|
|
437
539
|
componentOptions: e,
|
|
438
540
|
builderBlock: t,
|
|
439
541
|
context: n,
|
|
440
542
|
componentRef: o,
|
|
441
|
-
includeBlockProps:
|
|
442
|
-
isInteractive:
|
|
543
|
+
includeBlockProps: r,
|
|
544
|
+
isInteractive: i,
|
|
443
545
|
contextValue: a
|
|
444
|
-
}) =>
|
|
546
|
+
}) => i ? {
|
|
445
547
|
Wrapper: o,
|
|
446
548
|
block: t,
|
|
447
549
|
context: n,
|
|
@@ -452,20 +554,20 @@ const ct = ({
|
|
|
452
554
|
* If `noWrap` is set to `true`, then the block's props/attributes are provided to the
|
|
453
555
|
* component itself directly. Otherwise, they are provided to the wrapper element.
|
|
454
556
|
*/
|
|
455
|
-
...
|
|
456
|
-
attributes:
|
|
557
|
+
...r ? {
|
|
558
|
+
attributes: getBlockProperties({
|
|
457
559
|
block: t,
|
|
458
560
|
context: a
|
|
459
561
|
})
|
|
460
562
|
} : {}
|
|
461
563
|
};
|
|
462
|
-
function
|
|
564
|
+
function ComponentRef(e) {
|
|
463
565
|
var n, o;
|
|
464
|
-
const t = e.isInteractive ?
|
|
465
|
-
return /* @__PURE__ */
|
|
566
|
+
const t = e.isInteractive ? InteractiveElement : e.componentRef;
|
|
567
|
+
return /* @__PURE__ */ jsx(Fragment, { children: e.componentRef ? /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsxs(
|
|
466
568
|
t,
|
|
467
569
|
{
|
|
468
|
-
...
|
|
570
|
+
...getWrapperProps({
|
|
469
571
|
componentOptions: e.componentOptions,
|
|
470
572
|
builderBlock: e.builderBlock,
|
|
471
573
|
context: e.context,
|
|
@@ -475,42 +577,42 @@ function J(e) {
|
|
|
475
577
|
contextValue: e.context
|
|
476
578
|
}),
|
|
477
579
|
children: [
|
|
478
|
-
(n = e.blockChildren) == null ? void 0 : n.map((
|
|
479
|
-
|
|
580
|
+
(n = e.blockChildren) == null ? void 0 : n.map((r) => /* @__PURE__ */ jsx(
|
|
581
|
+
Block,
|
|
480
582
|
{
|
|
481
|
-
block:
|
|
583
|
+
block: r,
|
|
482
584
|
context: e.context,
|
|
483
585
|
registeredComponents: e.registeredComponents
|
|
484
586
|
},
|
|
485
|
-
"block-" +
|
|
587
|
+
"block-" + r.id
|
|
486
588
|
)),
|
|
487
|
-
(o = e.blockChildren) == null ? void 0 : o.map((
|
|
488
|
-
|
|
589
|
+
(o = e.blockChildren) == null ? void 0 : o.map((r) => /* @__PURE__ */ jsx(
|
|
590
|
+
BlockStyles,
|
|
489
591
|
{
|
|
490
|
-
block:
|
|
592
|
+
block: r,
|
|
491
593
|
context: e.context
|
|
492
594
|
},
|
|
493
|
-
"block-style-" +
|
|
595
|
+
"block-style-" + r.id
|
|
494
596
|
))
|
|
495
597
|
]
|
|
496
598
|
}
|
|
497
599
|
) }) : null });
|
|
498
600
|
}
|
|
499
|
-
function
|
|
500
|
-
var u,
|
|
601
|
+
function Block(e) {
|
|
602
|
+
var u, m, h, p;
|
|
501
603
|
const t = function() {
|
|
502
|
-
return
|
|
604
|
+
return getComponent({
|
|
503
605
|
block: e.block,
|
|
504
606
|
context: e.context,
|
|
505
607
|
registeredComponents: e.registeredComponents
|
|
506
608
|
});
|
|
507
609
|
}, n = function() {
|
|
508
|
-
return
|
|
610
|
+
return getRepeatItemData({
|
|
509
611
|
block: e.block,
|
|
510
612
|
context: e.context
|
|
511
613
|
});
|
|
512
614
|
}, o = function() {
|
|
513
|
-
return n() ? e.block :
|
|
615
|
+
return n() ? e.block : getProcessedBlock({
|
|
514
616
|
block: e.block,
|
|
515
617
|
localState: e.context.localState,
|
|
516
618
|
rootState: e.context.rootState,
|
|
@@ -518,20 +620,20 @@ function $(e) {
|
|
|
518
620
|
context: e.context.context,
|
|
519
621
|
shouldEvaluateBindings: !0
|
|
520
622
|
});
|
|
521
|
-
}, i = function() {
|
|
522
|
-
return e.block.tagName || "div";
|
|
523
623
|
}, r = function() {
|
|
624
|
+
return e.block.tagName || "div";
|
|
625
|
+
}, i = function() {
|
|
524
626
|
return "hide" in o() ? !o().hide : "show" in o() ? o().show : !0;
|
|
525
627
|
}, a = function() {
|
|
526
628
|
var d;
|
|
527
629
|
return !((d = t()) != null && d.component) && !n() ? o().children ?? [] : [];
|
|
528
630
|
}, c = function() {
|
|
529
|
-
var
|
|
631
|
+
var f, d, b, y, g;
|
|
530
632
|
return {
|
|
531
633
|
blockChildren: o().children ?? [],
|
|
532
|
-
componentRef: (
|
|
634
|
+
componentRef: (f = t()) == null ? void 0 : f.component,
|
|
533
635
|
componentOptions: {
|
|
534
|
-
...
|
|
636
|
+
...getBlockComponentOptions(o()),
|
|
535
637
|
builderContext: e.context,
|
|
536
638
|
...((d = t()) == null ? void 0 : d.name) === "Symbol" || ((b = t()) == null ? void 0 : b.name) === "Columns" ? {
|
|
537
639
|
builderComponents: e.registeredComponents
|
|
@@ -540,72 +642,72 @@ function $(e) {
|
|
|
540
642
|
context: s,
|
|
541
643
|
registeredComponents: e.registeredComponents,
|
|
542
644
|
builderBlock: o(),
|
|
543
|
-
includeBlockProps: ((
|
|
544
|
-
isInteractive: !((
|
|
645
|
+
includeBlockProps: ((y = t()) == null ? void 0 : y.noWrap) === !0,
|
|
646
|
+
isInteractive: !((g = t()) != null && g.isRSC)
|
|
545
647
|
};
|
|
546
648
|
}, s = e.context;
|
|
547
|
-
return /* @__PURE__ */
|
|
548
|
-
|
|
549
|
-
|
|
649
|
+
return /* @__PURE__ */ jsx(Fragment, { children: i() ? /* @__PURE__ */ jsx(Fragment, { children: (u = t()) != null && u.noWrap ? /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(ComponentRef, { ...c() }) }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
650
|
+
isEmptyHtmlElement(r()) ? /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(
|
|
651
|
+
BlockWrapper,
|
|
550
652
|
{
|
|
551
|
-
Wrapper:
|
|
653
|
+
Wrapper: r(),
|
|
552
654
|
block: o(),
|
|
553
655
|
context: e.context,
|
|
554
656
|
hasChildren: !1
|
|
555
657
|
}
|
|
556
658
|
) }) : null,
|
|
557
|
-
!
|
|
558
|
-
|
|
659
|
+
!isEmptyHtmlElement(r()) && n() ? /* @__PURE__ */ jsx(Fragment, { children: (m = n()) == null ? void 0 : m.map((l, f) => /* @__PURE__ */ jsx(
|
|
660
|
+
RepeatedBlock,
|
|
559
661
|
{
|
|
560
|
-
repeatContext:
|
|
561
|
-
block:
|
|
662
|
+
repeatContext: l.context,
|
|
663
|
+
block: l.block,
|
|
562
664
|
registeredComponents: e.registeredComponents
|
|
563
665
|
},
|
|
564
|
-
|
|
666
|
+
f
|
|
565
667
|
)) }) : null,
|
|
566
|
-
!
|
|
567
|
-
|
|
668
|
+
!isEmptyHtmlElement(r()) && !n() ? /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsxs(
|
|
669
|
+
BlockWrapper,
|
|
568
670
|
{
|
|
569
|
-
Wrapper:
|
|
671
|
+
Wrapper: r(),
|
|
570
672
|
block: o(),
|
|
571
673
|
context: e.context,
|
|
572
674
|
hasChildren: !0,
|
|
573
675
|
children: [
|
|
574
|
-
/* @__PURE__ */
|
|
575
|
-
(
|
|
576
|
-
|
|
676
|
+
/* @__PURE__ */ jsx(ComponentRef, { ...c() }),
|
|
677
|
+
(h = a()) == null ? void 0 : h.map((l) => /* @__PURE__ */ jsx(
|
|
678
|
+
Block,
|
|
577
679
|
{
|
|
578
|
-
block:
|
|
680
|
+
block: l,
|
|
579
681
|
context: s,
|
|
580
682
|
registeredComponents: e.registeredComponents
|
|
581
683
|
},
|
|
582
|
-
"block-" +
|
|
684
|
+
"block-" + l.id
|
|
583
685
|
)),
|
|
584
|
-
(p = a()) == null ? void 0 : p.map((
|
|
585
|
-
|
|
686
|
+
(p = a()) == null ? void 0 : p.map((l) => /* @__PURE__ */ jsx(
|
|
687
|
+
BlockStyles,
|
|
586
688
|
{
|
|
587
|
-
block:
|
|
689
|
+
block: l,
|
|
588
690
|
context: s
|
|
589
691
|
},
|
|
590
|
-
"block-style-" +
|
|
692
|
+
"block-style-" + l.id
|
|
591
693
|
))
|
|
592
694
|
]
|
|
593
695
|
}
|
|
594
696
|
) }) : null
|
|
595
697
|
] }) }) : null });
|
|
596
698
|
}
|
|
597
|
-
function
|
|
699
|
+
function Blocks(e) {
|
|
598
700
|
var t, n;
|
|
599
|
-
return /* @__PURE__ */
|
|
600
|
-
|
|
701
|
+
return /* @__PURE__ */ jsxs(
|
|
702
|
+
BlocksWrapper,
|
|
601
703
|
{
|
|
602
704
|
blocks: e.blocks,
|
|
603
705
|
parent: e.parent,
|
|
604
706
|
path: e.path,
|
|
605
707
|
styleProp: e.styleProp,
|
|
606
708
|
children: [
|
|
607
|
-
e.blocks ? /* @__PURE__ */
|
|
608
|
-
|
|
709
|
+
e.blocks ? /* @__PURE__ */ jsx(Fragment, { children: (t = e.blocks) == null ? void 0 : t.map((o) => /* @__PURE__ */ jsx(
|
|
710
|
+
Block,
|
|
609
711
|
{
|
|
610
712
|
block: o,
|
|
611
713
|
context: e.context,
|
|
@@ -613,8 +715,8 @@ function _(e) {
|
|
|
613
715
|
},
|
|
614
716
|
"render-block-" + o.id
|
|
615
717
|
)) }) : null,
|
|
616
|
-
e.blocks ? /* @__PURE__ */
|
|
617
|
-
|
|
718
|
+
e.blocks ? /* @__PURE__ */ jsx(Fragment, { children: (n = e.blocks) == null ? void 0 : n.map((o) => /* @__PURE__ */ jsx(
|
|
719
|
+
BlockStyles,
|
|
618
720
|
{
|
|
619
721
|
block: o,
|
|
620
722
|
context: e.context
|
|
@@ -625,14 +727,14 @@ function _(e) {
|
|
|
625
727
|
}
|
|
626
728
|
);
|
|
627
729
|
}
|
|
628
|
-
function
|
|
629
|
-
var
|
|
630
|
-
const t = typeof e.space == "number" ? e.space || 0 : 20, n = e.columns || [], o = e.stackColumnsAt || "tablet",
|
|
730
|
+
function Columns(e) {
|
|
731
|
+
var l;
|
|
732
|
+
const t = typeof e.space == "number" ? e.space || 0 : 20, n = e.columns || [], o = e.stackColumnsAt || "tablet", r = function(d) {
|
|
631
733
|
var b;
|
|
632
734
|
return ((b = n[d]) == null ? void 0 : b.width) || 100 / n.length;
|
|
633
|
-
},
|
|
735
|
+
}, i = function(d) {
|
|
634
736
|
const b = t * (n.length - 1) / n.length;
|
|
635
|
-
return `calc(${
|
|
737
|
+
return `calc(${r(d)}% - ${b}px)`;
|
|
636
738
|
}, a = function({
|
|
637
739
|
stackedStyle: d,
|
|
638
740
|
desktopStyle: b
|
|
@@ -651,36 +753,36 @@ function lt(e) {
|
|
|
651
753
|
desktopStyle: "row"
|
|
652
754
|
})
|
|
653
755
|
};
|
|
654
|
-
},
|
|
655
|
-
const b = d === 0 ? 0 : t,
|
|
756
|
+
}, m = function(d) {
|
|
757
|
+
const b = d === 0 ? 0 : t, y = i(d), g = `${b}px`, v = "100%", x = 0;
|
|
656
758
|
return {
|
|
657
|
-
width:
|
|
658
|
-
["marginLeft"]:
|
|
759
|
+
width: y,
|
|
760
|
+
["marginLeft"]: g,
|
|
659
761
|
"--column-width-mobile": c({
|
|
660
|
-
stackedStyle:
|
|
661
|
-
desktopStyle:
|
|
762
|
+
stackedStyle: v,
|
|
763
|
+
desktopStyle: y
|
|
662
764
|
}),
|
|
663
765
|
"--column-margin-left-mobile": c({
|
|
664
|
-
stackedStyle:
|
|
665
|
-
desktopStyle:
|
|
766
|
+
stackedStyle: x,
|
|
767
|
+
desktopStyle: g
|
|
666
768
|
}),
|
|
667
769
|
"--column-width-tablet": a({
|
|
668
|
-
stackedStyle:
|
|
669
|
-
desktopStyle:
|
|
770
|
+
stackedStyle: v,
|
|
771
|
+
desktopStyle: y
|
|
670
772
|
}),
|
|
671
773
|
"--column-margin-left-tablet": a({
|
|
672
|
-
stackedStyle:
|
|
673
|
-
desktopStyle:
|
|
774
|
+
stackedStyle: x,
|
|
775
|
+
desktopStyle: g
|
|
674
776
|
})
|
|
675
777
|
};
|
|
676
|
-
},
|
|
677
|
-
var
|
|
678
|
-
return
|
|
679
|
-
((
|
|
778
|
+
}, h = function(d) {
|
|
779
|
+
var y, g;
|
|
780
|
+
return getSizesForBreakpoints(
|
|
781
|
+
((g = (y = e.builderContext.content) == null ? void 0 : y.meta) == null ? void 0 : g.breakpoints) || {}
|
|
680
782
|
)[d].max;
|
|
681
783
|
}, p = function() {
|
|
682
784
|
return `
|
|
683
|
-
@media (max-width: ${
|
|
785
|
+
@media (max-width: ${h("medium")}px) {
|
|
684
786
|
.${e.builderBlock.id}-breakpoints {
|
|
685
787
|
flex-direction: var(--flex-dir-tablet);
|
|
686
788
|
align-items: stretch;
|
|
@@ -692,7 +794,7 @@ function lt(e) {
|
|
|
692
794
|
}
|
|
693
795
|
}
|
|
694
796
|
|
|
695
|
-
@media (max-width: ${
|
|
797
|
+
@media (max-width: ${h("small")}px) {
|
|
696
798
|
.${e.builderBlock.id}-breakpoints {
|
|
697
799
|
flex-direction: var(--flex-dir);
|
|
698
800
|
align-items: stretch;
|
|
@@ -705,23 +807,23 @@ function lt(e) {
|
|
|
705
807
|
},
|
|
706
808
|
`;
|
|
707
809
|
};
|
|
708
|
-
return /* @__PURE__ */
|
|
709
|
-
/* @__PURE__ */
|
|
810
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
811
|
+
/* @__PURE__ */ jsxs(
|
|
710
812
|
"div",
|
|
711
813
|
{
|
|
712
|
-
className: `builder-columns ${e.builderBlock.id}-breakpoints div-
|
|
814
|
+
className: `builder-columns ${e.builderBlock.id}-breakpoints div-666689ca`,
|
|
713
815
|
style: u(),
|
|
714
816
|
children: [
|
|
715
|
-
/* @__PURE__ */
|
|
716
|
-
(
|
|
817
|
+
/* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(InlinedStyles, { styles: p() }) }),
|
|
818
|
+
(l = e.columns) == null ? void 0 : l.map((f, d) => /* @__PURE__ */ createElement(
|
|
717
819
|
"div",
|
|
718
820
|
{
|
|
719
|
-
className: "builder-column div-
|
|
720
|
-
style:
|
|
821
|
+
className: "builder-column div-666689ca-2",
|
|
822
|
+
style: m(d),
|
|
721
823
|
key: d
|
|
722
824
|
},
|
|
723
|
-
/* @__PURE__ */
|
|
724
|
-
|
|
825
|
+
/* @__PURE__ */ jsx(
|
|
826
|
+
Blocks,
|
|
725
827
|
{
|
|
726
828
|
path: `component.options.columns.${d}.blocks`,
|
|
727
829
|
parent: e.builderBlock.id,
|
|
@@ -730,125 +832,125 @@ function lt(e) {
|
|
|
730
832
|
},
|
|
731
833
|
context: e.builderContext,
|
|
732
834
|
registeredComponents: e.builderComponents,
|
|
733
|
-
blocks:
|
|
835
|
+
blocks: f.blocks
|
|
734
836
|
}
|
|
735
837
|
)
|
|
736
838
|
))
|
|
737
839
|
]
|
|
738
840
|
}
|
|
739
841
|
),
|
|
740
|
-
/* @__PURE__ */
|
|
842
|
+
/* @__PURE__ */ jsx("style", { children: `.div-666689ca {
|
|
741
843
|
display: flex;
|
|
742
844
|
line-height: normal;
|
|
743
|
-
}.div-
|
|
845
|
+
}.div-666689ca-2 {
|
|
744
846
|
display: flex;
|
|
745
847
|
flex-direction: column;
|
|
746
848
|
align-items: stretch;
|
|
747
849
|
}` })
|
|
748
850
|
] });
|
|
749
851
|
}
|
|
750
|
-
function
|
|
852
|
+
function removeProtocol(e) {
|
|
751
853
|
return e.replace(/http(s)?:/, "");
|
|
752
854
|
}
|
|
753
|
-
function
|
|
754
|
-
const o = new RegExp("([?&])" + t + "=.*?(&|$)", "i"),
|
|
755
|
-
return e.match(o) ? e.replace(o, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e +
|
|
855
|
+
function updateQueryParam(e = "", t, n) {
|
|
856
|
+
const o = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), r = e.indexOf("?") !== -1 ? "&" : "?";
|
|
857
|
+
return e.match(o) ? e.replace(o, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + r + t + "=" + encodeURIComponent(n);
|
|
756
858
|
}
|
|
757
|
-
function
|
|
859
|
+
function getShopifyImageUrl(e, t) {
|
|
758
860
|
if (!e || !(e != null && e.match(/cdn\.shopify\.com/)) || !t)
|
|
759
861
|
return e;
|
|
760
862
|
if (t === "master")
|
|
761
|
-
return
|
|
863
|
+
return removeProtocol(e);
|
|
762
864
|
const n = e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);
|
|
763
865
|
if (n) {
|
|
764
|
-
const o = e.split(n[0]),
|
|
765
|
-
return
|
|
866
|
+
const o = e.split(n[0]), r = n[3], i = t.match("x") ? t : `${t}x`;
|
|
867
|
+
return removeProtocol(`${o[0]}_${i}${r}`);
|
|
766
868
|
}
|
|
767
869
|
return null;
|
|
768
870
|
}
|
|
769
|
-
function
|
|
871
|
+
function getSrcSet(e) {
|
|
770
872
|
if (!e)
|
|
771
873
|
return e;
|
|
772
874
|
const t = [100, 200, 400, 800, 1200, 1600, 2e3];
|
|
773
875
|
if (e.match(/builder\.io/)) {
|
|
774
876
|
let n = e;
|
|
775
877
|
const o = Number(e.split("?width=")[1]);
|
|
776
|
-
return isNaN(o) || (n = `${n} ${o}w`), t.filter((
|
|
878
|
+
return isNaN(o) || (n = `${n} ${o}w`), t.filter((r) => r !== o).map((r) => `${updateQueryParam(e, "width", r)} ${r}w`).concat([n]).join(", ");
|
|
777
879
|
}
|
|
778
|
-
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [
|
|
880
|
+
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [getShopifyImageUrl(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, o]) => `${n} ${o}w`).concat([e]).join(", ") : e;
|
|
779
881
|
}
|
|
780
|
-
const
|
|
882
|
+
const getVariants = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
|
|
781
883
|
...t,
|
|
782
884
|
testVariationId: t.id,
|
|
783
885
|
id: e == null ? void 0 : e.id
|
|
784
|
-
})),
|
|
886
|
+
})), checkShouldRunVariants = ({
|
|
785
887
|
canTrack: e,
|
|
786
888
|
content: t
|
|
787
|
-
}) => !(!(
|
|
788
|
-
function
|
|
889
|
+
}) => !(!(getVariants(t).length > 0) || !e || isBrowser());
|
|
890
|
+
function bldrAbTest(e, t, n) {
|
|
789
891
|
var a;
|
|
790
892
|
function o() {
|
|
791
|
-
function c(
|
|
792
|
-
let
|
|
893
|
+
function c(f, d, b) {
|
|
894
|
+
let y = "";
|
|
793
895
|
if (b) {
|
|
794
|
-
const
|
|
795
|
-
|
|
896
|
+
const g = /* @__PURE__ */ new Date();
|
|
897
|
+
g.setTime(g.getTime() + b * 24 * 60 * 60 * 1e3), y = "; expires=" + g.toUTCString();
|
|
796
898
|
}
|
|
797
|
-
document.cookie =
|
|
899
|
+
document.cookie = f + "=" + (d || "") + y + "; path=/; Secure; SameSite=None";
|
|
798
900
|
}
|
|
799
|
-
function s(
|
|
800
|
-
const d =
|
|
801
|
-
for (let
|
|
802
|
-
let
|
|
803
|
-
for (;
|
|
804
|
-
|
|
805
|
-
if (
|
|
806
|
-
return
|
|
901
|
+
function s(f) {
|
|
902
|
+
const d = f + "=", b = document.cookie.split(";");
|
|
903
|
+
for (let y = 0; y < b.length; y++) {
|
|
904
|
+
let g = b[y];
|
|
905
|
+
for (; g.charAt(0) === " "; )
|
|
906
|
+
g = g.substring(1, g.length);
|
|
907
|
+
if (g.indexOf(d) === 0)
|
|
908
|
+
return g.substring(d.length, g.length);
|
|
807
909
|
}
|
|
808
910
|
return null;
|
|
809
911
|
}
|
|
810
|
-
const u = `builder.tests.${e}`,
|
|
811
|
-
if (
|
|
812
|
-
return
|
|
912
|
+
const u = `builder.tests.${e}`, m = s(u), h = t.map((f) => f.id).concat(e);
|
|
913
|
+
if (m && h.includes(m))
|
|
914
|
+
return m;
|
|
813
915
|
let p = 0;
|
|
814
|
-
const
|
|
815
|
-
for (let
|
|
816
|
-
const d = t[
|
|
817
|
-
if (p += b,
|
|
916
|
+
const l = Math.random();
|
|
917
|
+
for (let f = 0; f < t.length; f++) {
|
|
918
|
+
const d = t[f], b = d.testRatio;
|
|
919
|
+
if (p += b, l < p)
|
|
818
920
|
return c(u, d.id), d.id;
|
|
819
921
|
}
|
|
820
922
|
return c(u, e), e;
|
|
821
923
|
}
|
|
822
|
-
const
|
|
924
|
+
const r = o(), i = (a = document.currentScript) == null ? void 0 : a.previousElementSibling;
|
|
823
925
|
if (n) {
|
|
824
|
-
|
|
926
|
+
i.remove();
|
|
825
927
|
const c = document.currentScript;
|
|
826
928
|
c == null || c.remove();
|
|
827
929
|
} else {
|
|
828
930
|
const c = t.concat({
|
|
829
931
|
id: e
|
|
830
|
-
}).filter((s) => s.id !==
|
|
932
|
+
}).filter((s) => s.id !== r).map((s) => `.variant-${s.id} { display: none; }
|
|
831
933
|
`).join("");
|
|
832
|
-
|
|
934
|
+
i.innerHTML = c;
|
|
833
935
|
}
|
|
834
936
|
}
|
|
835
|
-
function
|
|
937
|
+
function bldrCntntScrpt(e, t, n) {
|
|
836
938
|
var s;
|
|
837
939
|
if (!navigator.cookieEnabled)
|
|
838
940
|
return;
|
|
839
941
|
function o(u) {
|
|
840
|
-
const
|
|
841
|
-
for (let p = 0; p <
|
|
842
|
-
let
|
|
843
|
-
for (;
|
|
844
|
-
|
|
845
|
-
if (
|
|
846
|
-
return
|
|
942
|
+
const m = u + "=", h = document.cookie.split(";");
|
|
943
|
+
for (let p = 0; p < h.length; p++) {
|
|
944
|
+
let l = h[p];
|
|
945
|
+
for (; l.charAt(0) === " "; )
|
|
946
|
+
l = l.substring(1, l.length);
|
|
947
|
+
if (l.indexOf(m) === 0)
|
|
948
|
+
return l.substring(m.length, l.length);
|
|
847
949
|
}
|
|
848
950
|
return null;
|
|
849
951
|
}
|
|
850
|
-
const
|
|
851
|
-
if (
|
|
952
|
+
const r = `builder.tests.${t}`, i = o(r), a = (s = document.currentScript) == null ? void 0 : s.parentElement, c = e === t;
|
|
953
|
+
if (i === e) {
|
|
852
954
|
if (c)
|
|
853
955
|
return;
|
|
854
956
|
a == null || a.removeAttribute("hidden"), a == null || a.removeAttribute("aria-hidden");
|
|
@@ -857,18 +959,18 @@ function ht(e, t, n) {
|
|
|
857
959
|
return;
|
|
858
960
|
}
|
|
859
961
|
}
|
|
860
|
-
const
|
|
861
|
-
const e =
|
|
962
|
+
const getIsHydrationTarget = (e) => e === "react" || e === "reactNative", isHydrationTarget = getIsHydrationTarget(TARGET), AB_TEST_FN_NAME = "builderIoAbTest", CONTENT_FN_NAME = "builderIoRenderContent", getScriptString = () => {
|
|
963
|
+
const e = bldrAbTest.toString().replace(/\s+/g, " "), t = bldrCntntScrpt.toString().replace(/\s+/g, " ");
|
|
862
964
|
return `
|
|
863
|
-
window.${
|
|
864
|
-
window.${
|
|
965
|
+
window.${AB_TEST_FN_NAME} = ${e}
|
|
966
|
+
window.${CONTENT_FN_NAME} = ${t}
|
|
865
967
|
`;
|
|
866
|
-
},
|
|
867
|
-
window.${
|
|
968
|
+
}, getVariantsScriptString = (e, t) => `
|
|
969
|
+
window.${AB_TEST_FN_NAME}("${t}",${JSON.stringify(e)}, ${isHydrationTarget})`, getRenderContentScriptString = ({
|
|
868
970
|
contentId: e,
|
|
869
971
|
variationId: t
|
|
870
972
|
}) => `
|
|
871
|
-
window.${
|
|
973
|
+
window.${CONTENT_FN_NAME}("${t}", "${e}", ${isHydrationTarget})`, componentInfo$a = {
|
|
872
974
|
name: "Core:Button",
|
|
873
975
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
874
976
|
defaultStyles: {
|
|
@@ -901,7 +1003,7 @@ const gt = (e) => e === "react" || e === "reactNative", ue = gt(I), de = "builde
|
|
|
901
1003
|
}],
|
|
902
1004
|
static: !0,
|
|
903
1005
|
noWrap: !0
|
|
904
|
-
},
|
|
1006
|
+
}, componentInfo$9 = {
|
|
905
1007
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
906
1008
|
name: "Columns",
|
|
907
1009
|
isRSC: !0,
|
|
@@ -1080,7 +1182,7 @@ const gt = (e) => e === "react" || e === "reactNative", ue = gt(I), de = "builde
|
|
|
1080
1182
|
});
|
|
1081
1183
|
}
|
|
1082
1184
|
const n = e.get("columns");
|
|
1083
|
-
Array.isArray(n) && n.find((
|
|
1185
|
+
Array.isArray(n) && n.find((r) => r.get("width")) && (n.find((i) => !i.get("width")) || n.reduce((c, s) => c + s.get("width"), 0) !== 100) && t();
|
|
1084
1186
|
}
|
|
1085
1187
|
}, {
|
|
1086
1188
|
name: "space",
|
|
@@ -1102,13 +1204,13 @@ const gt = (e) => e === "react" || e === "reactNative", ue = gt(I), de = "builde
|
|
|
1102
1204
|
helperText: "When stacking columns for mobile devices, reverse the ordering",
|
|
1103
1205
|
advanced: !0
|
|
1104
1206
|
}]
|
|
1105
|
-
},
|
|
1207
|
+
}, componentInfo$8 = {
|
|
1106
1208
|
name: "Fragment",
|
|
1107
1209
|
static: !0,
|
|
1108
1210
|
hidden: !0,
|
|
1109
1211
|
canHaveChildren: !0,
|
|
1110
1212
|
noWrap: !0
|
|
1111
|
-
},
|
|
1213
|
+
}, componentInfo$7 = {
|
|
1112
1214
|
name: "Image",
|
|
1113
1215
|
static: !0,
|
|
1114
1216
|
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",
|
|
@@ -1130,27 +1232,27 @@ const gt = (e) => e === "react" || e === "reactNative", ue = gt(I), de = "builde
|
|
|
1130
1232
|
e.delete("srcset"), e.delete("noWebp");
|
|
1131
1233
|
function n(a, c = 6e4) {
|
|
1132
1234
|
return new Promise((s, u) => {
|
|
1133
|
-
const
|
|
1134
|
-
let
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
},
|
|
1235
|
+
const m = document.createElement("img");
|
|
1236
|
+
let h = !1;
|
|
1237
|
+
m.onload = () => {
|
|
1238
|
+
h = !0, s(m);
|
|
1239
|
+
}, m.addEventListener("error", (p) => {
|
|
1138
1240
|
console.warn("Image load failed", p.error), u(p.error);
|
|
1139
|
-
}),
|
|
1140
|
-
|
|
1241
|
+
}), m.src = a, setTimeout(() => {
|
|
1242
|
+
h || u(new Error("Image load timed out"));
|
|
1141
1243
|
}, c);
|
|
1142
1244
|
});
|
|
1143
1245
|
}
|
|
1144
1246
|
function o(a) {
|
|
1145
1247
|
return Math.round(a * 1e3) / 1e3;
|
|
1146
1248
|
}
|
|
1147
|
-
const
|
|
1148
|
-
if (fetch(
|
|
1249
|
+
const r = e.get("image"), i = e.get("aspectRatio");
|
|
1250
|
+
if (fetch(r).then((a) => a.blob()).then((a) => {
|
|
1149
1251
|
a.type.includes("svg") && e.set("noWebp", !0);
|
|
1150
|
-
}),
|
|
1151
|
-
return n(
|
|
1252
|
+
}), r && (!i || i === 0.7041))
|
|
1253
|
+
return n(r).then((a) => {
|
|
1152
1254
|
const c = e.get("aspectRatio");
|
|
1153
|
-
e.get("image") ===
|
|
1255
|
+
e.get("image") === r && (!c || c === 0.7041) && a.width && a.height && (e.set("aspectRatio", o(a.height / a.width)), e.set("height", a.height), e.set("width", a.width));
|
|
1154
1256
|
});
|
|
1155
1257
|
}
|
|
1156
1258
|
}, {
|
|
@@ -1208,7 +1310,7 @@ const gt = (e) => e === "react" || e === "reactNative", ue = gt(I), de = "builde
|
|
|
1208
1310
|
advanced: !0,
|
|
1209
1311
|
defaultValue: 0.7041
|
|
1210
1312
|
}]
|
|
1211
|
-
},
|
|
1313
|
+
}, componentInfo$6 = {
|
|
1212
1314
|
name: "Core:Section",
|
|
1213
1315
|
static: !0,
|
|
1214
1316
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -1247,7 +1349,7 @@ const gt = (e) => e === "react" || e === "reactNative", ue = gt(I), de = "builde
|
|
|
1247
1349
|
}
|
|
1248
1350
|
}
|
|
1249
1351
|
}]
|
|
1250
|
-
},
|
|
1352
|
+
}, componentInfo$5 = {
|
|
1251
1353
|
name: "Symbol",
|
|
1252
1354
|
noWrap: !0,
|
|
1253
1355
|
static: !0,
|
|
@@ -1280,7 +1382,7 @@ const gt = (e) => e === "react" || e === "reactNative", ue = gt(I), de = "builde
|
|
|
1280
1382
|
hideFromUI: !0,
|
|
1281
1383
|
type: "boolean"
|
|
1282
1384
|
}]
|
|
1283
|
-
},
|
|
1385
|
+
}, componentInfo$4 = {
|
|
1284
1386
|
name: "Text",
|
|
1285
1387
|
static: !0,
|
|
1286
1388
|
isRSC: !0,
|
|
@@ -1299,9 +1401,9 @@ const gt = (e) => e === "react" || e === "reactNative", ue = gt(I), de = "builde
|
|
|
1299
1401
|
textAlign: "center"
|
|
1300
1402
|
}
|
|
1301
1403
|
};
|
|
1302
|
-
function
|
|
1404
|
+
function Text(e) {
|
|
1303
1405
|
var t;
|
|
1304
|
-
return /* @__PURE__ */
|
|
1406
|
+
return /* @__PURE__ */ jsx(
|
|
1305
1407
|
"div",
|
|
1306
1408
|
{
|
|
1307
1409
|
className: "builder-text",
|
|
@@ -1312,7 +1414,7 @@ function Tt(e) {
|
|
|
1312
1414
|
}
|
|
1313
1415
|
);
|
|
1314
1416
|
}
|
|
1315
|
-
const
|
|
1417
|
+
const componentInfo$3 = {
|
|
1316
1418
|
name: "Video",
|
|
1317
1419
|
canHaveChildren: !0,
|
|
1318
1420
|
defaultStyles: {
|
|
@@ -1393,7 +1495,7 @@ const Rt = {
|
|
|
1393
1495
|
defaultValue: !0,
|
|
1394
1496
|
advanced: !0
|
|
1395
1497
|
}]
|
|
1396
|
-
},
|
|
1498
|
+
}, componentInfo$2 = {
|
|
1397
1499
|
name: "Embed",
|
|
1398
1500
|
static: !0,
|
|
1399
1501
|
inputs: [{
|
|
@@ -1418,7 +1520,7 @@ const Rt = {
|
|
|
1418
1520
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
1419
1521
|
hideFromUI: !0
|
|
1420
1522
|
}]
|
|
1421
|
-
},
|
|
1523
|
+
}, SCRIPT_MIME_TYPES = ["text/javascript", "application/javascript", "application/ecmascript"], isJsScript = (e) => SCRIPT_MIME_TYPES.includes(e.type), componentInfo$1 = {
|
|
1422
1524
|
// friendlyName?
|
|
1423
1525
|
name: "Raw:Img",
|
|
1424
1526
|
hideFromInsertMenu: !0,
|
|
@@ -1432,7 +1534,7 @@ const Rt = {
|
|
|
1432
1534
|
}],
|
|
1433
1535
|
noWrap: !0,
|
|
1434
1536
|
static: !0
|
|
1435
|
-
},
|
|
1537
|
+
}, componentInfo = {
|
|
1436
1538
|
name: "Custom Code",
|
|
1437
1539
|
static: !0,
|
|
1438
1540
|
requiredPermissions: ["editCode"],
|
|
@@ -1454,59 +1556,59 @@ const Rt = {
|
|
|
1454
1556
|
helperText: "Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",
|
|
1455
1557
|
advanced: !0
|
|
1456
1558
|
}]
|
|
1457
|
-
},
|
|
1458
|
-
component:
|
|
1459
|
-
...
|
|
1559
|
+
}, getDefaultRegisteredComponents = () => [{
|
|
1560
|
+
component: Button,
|
|
1561
|
+
...componentInfo$a
|
|
1460
1562
|
}, {
|
|
1461
|
-
component:
|
|
1462
|
-
...
|
|
1563
|
+
component: Columns,
|
|
1564
|
+
...componentInfo$9
|
|
1463
1565
|
}, {
|
|
1464
|
-
component:
|
|
1465
|
-
|
|
1566
|
+
component: CustomCode,
|
|
1567
|
+
...componentInfo
|
|
1466
1568
|
}, {
|
|
1467
|
-
component:
|
|
1468
|
-
...
|
|
1569
|
+
component: Embed,
|
|
1570
|
+
...componentInfo$2
|
|
1469
1571
|
}, {
|
|
1470
|
-
component:
|
|
1471
|
-
...
|
|
1572
|
+
component: FragmentComponent,
|
|
1573
|
+
...componentInfo$8
|
|
1472
1574
|
}, {
|
|
1473
|
-
component:
|
|
1474
|
-
...
|
|
1575
|
+
component: Image,
|
|
1576
|
+
...componentInfo$7
|
|
1475
1577
|
}, {
|
|
1476
|
-
component:
|
|
1477
|
-
...
|
|
1578
|
+
component: ImgComponent,
|
|
1579
|
+
...componentInfo$1
|
|
1478
1580
|
}, {
|
|
1479
|
-
component:
|
|
1480
|
-
...
|
|
1581
|
+
component: SectionComponent,
|
|
1582
|
+
...componentInfo$6
|
|
1481
1583
|
}, {
|
|
1482
|
-
component:
|
|
1483
|
-
...
|
|
1584
|
+
component: Symbol$1,
|
|
1585
|
+
...componentInfo$5
|
|
1484
1586
|
}, {
|
|
1485
|
-
component:
|
|
1486
|
-
...
|
|
1587
|
+
component: Text,
|
|
1588
|
+
...componentInfo$4
|
|
1487
1589
|
}, {
|
|
1488
|
-
component:
|
|
1489
|
-
...
|
|
1490
|
-
}],
|
|
1590
|
+
component: Video,
|
|
1591
|
+
...componentInfo$3
|
|
1592
|
+
}], components = [], createRegisterComponentMessage = (e) => ({
|
|
1491
1593
|
type: "builder.registerComponent",
|
|
1492
|
-
data:
|
|
1493
|
-
}),
|
|
1594
|
+
data: serializeComponentInfo(e)
|
|
1595
|
+
}), serializeFn = (e) => {
|
|
1494
1596
|
const t = e.toString().trim();
|
|
1495
1597
|
return `return (${!t.startsWith("function") && !t.startsWith("(") ? "function " : ""}${t}).apply(this, arguments)`;
|
|
1496
|
-
},
|
|
1598
|
+
}, serializeValue = (e) => typeof e == "function" ? serializeFn(e) : fastClone(e), serializeComponentInfo = ({
|
|
1497
1599
|
inputs: e,
|
|
1498
1600
|
...t
|
|
1499
1601
|
}) => ({
|
|
1500
|
-
...
|
|
1501
|
-
inputs: e == null ? void 0 : e.map((n) => Object.entries(n).reduce((o, [
|
|
1602
|
+
...fastClone(t),
|
|
1603
|
+
inputs: e == null ? void 0 : e.map((n) => Object.entries(n).reduce((o, [r, i]) => ({
|
|
1502
1604
|
...o,
|
|
1503
|
-
[
|
|
1605
|
+
[r]: serializeValue(i)
|
|
1504
1606
|
}), {}))
|
|
1505
|
-
}),
|
|
1506
|
-
var
|
|
1507
|
-
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], o = e.fileUrl ?? ((
|
|
1508
|
-
let
|
|
1509
|
-
if (o && t && n && (
|
|
1607
|
+
}), getCssFromFont = (e) => {
|
|
1608
|
+
var i;
|
|
1609
|
+
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], o = e.fileUrl ?? ((i = e == null ? void 0 : e.files) == null ? void 0 : i.regular);
|
|
1610
|
+
let r = "";
|
|
1611
|
+
if (o && t && n && (r += `
|
|
1510
1612
|
@font-face {
|
|
1511
1613
|
font-family: "${t}";
|
|
1512
1614
|
src: local("${n}"), url('${o}') format('woff2');
|
|
@@ -1518,7 +1620,7 @@ font-weight: 400;
|
|
|
1518
1620
|
if (!(String(Number(a)) === a))
|
|
1519
1621
|
continue;
|
|
1520
1622
|
const s = e.files[a];
|
|
1521
|
-
s && s !== o && (
|
|
1623
|
+
s && s !== o && (r += `
|
|
1522
1624
|
@font-face {
|
|
1523
1625
|
font-family: "${t}";
|
|
1524
1626
|
src: url('${s}') format('woff2');
|
|
@@ -1527,23 +1629,23 @@ font-weight: ${a};
|
|
|
1527
1629
|
}
|
|
1528
1630
|
`.trim());
|
|
1529
1631
|
}
|
|
1530
|
-
return
|
|
1531
|
-
},
|
|
1632
|
+
return r;
|
|
1633
|
+
}, getFontCss = ({
|
|
1532
1634
|
customFonts: e
|
|
1533
1635
|
}) => {
|
|
1534
1636
|
var t;
|
|
1535
|
-
return ((t = e == null ? void 0 : e.map((n) =>
|
|
1536
|
-
},
|
|
1637
|
+
return ((t = e == null ? void 0 : e.map((n) => getCssFromFont(n))) == null ? void 0 : t.join(" ")) || "";
|
|
1638
|
+
}, getCss = ({
|
|
1537
1639
|
cssCode: e,
|
|
1538
1640
|
contentId: t
|
|
1539
1641
|
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "";
|
|
1540
|
-
function
|
|
1642
|
+
function ContentStyles(e) {
|
|
1541
1643
|
const t = `
|
|
1542
|
-
${
|
|
1644
|
+
${getCss({
|
|
1543
1645
|
cssCode: e.cssCode,
|
|
1544
1646
|
contentId: e.contentId
|
|
1545
1647
|
})}
|
|
1546
|
-
${
|
|
1648
|
+
${getFontCss({
|
|
1547
1649
|
customFonts: e.customFonts
|
|
1548
1650
|
})}
|
|
1549
1651
|
|
|
@@ -1560,20 +1662,20 @@ ${Ot({
|
|
|
1560
1662
|
font-family: inherit;
|
|
1561
1663
|
}
|
|
1562
1664
|
`.trim();
|
|
1563
|
-
return /* @__PURE__ */
|
|
1665
|
+
return /* @__PURE__ */ jsx(InlinedStyles, { styles: t });
|
|
1564
1666
|
}
|
|
1565
|
-
const
|
|
1667
|
+
const getContextStateInitialValue = ({
|
|
1566
1668
|
content: e,
|
|
1567
1669
|
data: t,
|
|
1568
1670
|
locale: n
|
|
1569
1671
|
}) => {
|
|
1570
|
-
var
|
|
1672
|
+
var i, a, c;
|
|
1571
1673
|
const o = {};
|
|
1572
|
-
(a = (
|
|
1674
|
+
(a = (i = e == null ? void 0 : e.data) == null ? void 0 : i.inputs) == null || a.forEach((s) => {
|
|
1573
1675
|
var u;
|
|
1574
1676
|
s.name && s.defaultValue !== void 0 && ((u = e == null ? void 0 : e.data) != null && u.state) && e.data.state[s.name] === void 0 && (o[s.name] = s.defaultValue);
|
|
1575
1677
|
});
|
|
1576
|
-
const
|
|
1678
|
+
const r = {
|
|
1577
1679
|
...(c = e == null ? void 0 : e.data) == null ? void 0 : c.state,
|
|
1578
1680
|
...t,
|
|
1579
1681
|
...n ? {
|
|
@@ -1582,9 +1684,9 @@ const Lt = ({
|
|
|
1582
1684
|
};
|
|
1583
1685
|
return {
|
|
1584
1686
|
...o,
|
|
1585
|
-
...
|
|
1687
|
+
...r
|
|
1586
1688
|
};
|
|
1587
|
-
},
|
|
1689
|
+
}, getContentInitialValue = ({
|
|
1588
1690
|
content: e,
|
|
1589
1691
|
data: t
|
|
1590
1692
|
}) => e ? {
|
|
@@ -1595,22 +1697,22 @@ const Lt = ({
|
|
|
1595
1697
|
},
|
|
1596
1698
|
meta: e == null ? void 0 : e.meta
|
|
1597
1699
|
} : void 0;
|
|
1598
|
-
function
|
|
1700
|
+
function getGlobalThis() {
|
|
1599
1701
|
return typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : globalThis;
|
|
1600
1702
|
}
|
|
1601
|
-
function
|
|
1602
|
-
const e =
|
|
1703
|
+
function getFetch() {
|
|
1704
|
+
const e = getGlobalThis().fetch;
|
|
1603
1705
|
if (typeof e > "u")
|
|
1604
1706
|
throw console.warn(`Builder SDK could not find a global fetch function. Make sure you have a polyfill for fetch in your project.
|
|
1605
1707
|
For more information, read https://github.com/BuilderIO/this-package-uses-fetch`), new Error("Builder SDK could not find a global `fetch` function");
|
|
1606
1708
|
return e;
|
|
1607
1709
|
}
|
|
1608
|
-
const
|
|
1710
|
+
const fetch$1 = getFetch(), getTopLevelDomain = (e) => {
|
|
1609
1711
|
if (e === "localhost" || e === "127.0.0.1")
|
|
1610
1712
|
return e;
|
|
1611
1713
|
const t = e.split(".");
|
|
1612
1714
|
return t.length > 2 ? t.slice(1).join(".") : e;
|
|
1613
|
-
},
|
|
1715
|
+
}, getCookieSync = ({
|
|
1614
1716
|
name: e,
|
|
1615
1717
|
canTrack: t
|
|
1616
1718
|
}) => {
|
|
@@ -1618,17 +1720,17 @@ const jt = _t(), Kt = (e) => {
|
|
|
1618
1720
|
try {
|
|
1619
1721
|
return t ? (n = document.cookie.split("; ").find((o) => o.startsWith(`${e}=`))) == null ? void 0 : n.split("=")[1] : void 0;
|
|
1620
1722
|
} catch (o) {
|
|
1621
|
-
|
|
1723
|
+
logger.warn("[COOKIE] GET error: ", (o == null ? void 0 : o.message) || o);
|
|
1622
1724
|
return;
|
|
1623
1725
|
}
|
|
1624
|
-
},
|
|
1726
|
+
}, getCookie = async (e) => getCookieSync(e), stringifyCookie = (e) => e.map(([t, n]) => n ? `${t}=${n}` : t).filter(checkIsDefined).join("; "), SECURE_CONFIG = [["secure", ""], ["SameSite", "None"]], createCookieString = ({
|
|
1625
1727
|
name: e,
|
|
1626
1728
|
value: t,
|
|
1627
1729
|
expires: n
|
|
1628
1730
|
}) => {
|
|
1629
|
-
const
|
|
1630
|
-
return
|
|
1631
|
-
},
|
|
1731
|
+
const r = (isBrowser() ? location.protocol === "https:" : !0) ? SECURE_CONFIG : [[]], i = n ? [["expires", n.toUTCString()]] : [[]], a = [[e, t], ...i, ["path", "/"], ["domain", getTopLevelDomain(window.location.hostname)], ...r];
|
|
1732
|
+
return stringifyCookie(a);
|
|
1733
|
+
}, setCookie = async ({
|
|
1632
1734
|
name: e,
|
|
1633
1735
|
value: t,
|
|
1634
1736
|
expires: n,
|
|
@@ -1637,98 +1739,98 @@ const jt = _t(), Kt = (e) => {
|
|
|
1637
1739
|
try {
|
|
1638
1740
|
if (!o)
|
|
1639
1741
|
return;
|
|
1640
|
-
const
|
|
1742
|
+
const r = createCookieString({
|
|
1641
1743
|
name: e,
|
|
1642
1744
|
value: t,
|
|
1643
1745
|
expires: n
|
|
1644
1746
|
});
|
|
1645
|
-
document.cookie =
|
|
1646
|
-
} catch (
|
|
1647
|
-
|
|
1747
|
+
document.cookie = r;
|
|
1748
|
+
} catch (r) {
|
|
1749
|
+
logger.warn("[COOKIE] SET error: ", (r == null ? void 0 : r.message) || r);
|
|
1648
1750
|
}
|
|
1649
1751
|
};
|
|
1650
|
-
function
|
|
1752
|
+
function uuidv4() {
|
|
1651
1753
|
return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(e) {
|
|
1652
1754
|
const t = Math.random() * 16 | 0;
|
|
1653
1755
|
return (e == "x" ? t : t & 3 | 8).toString(16);
|
|
1654
1756
|
});
|
|
1655
1757
|
}
|
|
1656
|
-
function
|
|
1657
|
-
return
|
|
1758
|
+
function uuid() {
|
|
1759
|
+
return uuidv4().replace(/-/g, "");
|
|
1658
1760
|
}
|
|
1659
|
-
const
|
|
1761
|
+
const SESSION_LOCAL_STORAGE_KEY = "builderSessionId", getSessionId = async ({
|
|
1660
1762
|
canTrack: e
|
|
1661
1763
|
}) => {
|
|
1662
1764
|
if (!e)
|
|
1663
1765
|
return;
|
|
1664
|
-
const t = await
|
|
1665
|
-
name:
|
|
1766
|
+
const t = await getCookie({
|
|
1767
|
+
name: SESSION_LOCAL_STORAGE_KEY,
|
|
1666
1768
|
canTrack: e
|
|
1667
1769
|
});
|
|
1668
|
-
if (
|
|
1770
|
+
if (checkIsDefined(t))
|
|
1669
1771
|
return t;
|
|
1670
1772
|
{
|
|
1671
|
-
const n =
|
|
1672
|
-
return
|
|
1773
|
+
const n = createSessionId();
|
|
1774
|
+
return setSessionId({
|
|
1673
1775
|
id: n,
|
|
1674
1776
|
canTrack: e
|
|
1675
1777
|
}), n;
|
|
1676
1778
|
}
|
|
1677
|
-
},
|
|
1779
|
+
}, createSessionId = () => uuid(), setSessionId = ({
|
|
1678
1780
|
id: e,
|
|
1679
1781
|
canTrack: t
|
|
1680
|
-
}) =>
|
|
1681
|
-
name:
|
|
1782
|
+
}) => setCookie({
|
|
1783
|
+
name: SESSION_LOCAL_STORAGE_KEY,
|
|
1682
1784
|
value: e,
|
|
1683
1785
|
canTrack: t
|
|
1684
|
-
}),
|
|
1786
|
+
}), getLocalStorage = () => isBrowser() && typeof localStorage < "u" ? localStorage : void 0, getLocalStorageItem = ({
|
|
1685
1787
|
key: e,
|
|
1686
1788
|
canTrack: t
|
|
1687
1789
|
}) => {
|
|
1688
1790
|
var n;
|
|
1689
1791
|
try {
|
|
1690
|
-
return t ? (n =
|
|
1792
|
+
return t ? (n = getLocalStorage()) == null ? void 0 : n.getItem(e) : void 0;
|
|
1691
1793
|
} catch (o) {
|
|
1692
1794
|
console.debug("[LocalStorage] GET error: ", o);
|
|
1693
1795
|
return;
|
|
1694
1796
|
}
|
|
1695
|
-
},
|
|
1797
|
+
}, setLocalStorageItem = ({
|
|
1696
1798
|
key: e,
|
|
1697
1799
|
canTrack: t,
|
|
1698
1800
|
value: n
|
|
1699
1801
|
}) => {
|
|
1700
1802
|
var o;
|
|
1701
1803
|
try {
|
|
1702
|
-
t && ((o =
|
|
1703
|
-
} catch (
|
|
1704
|
-
console.debug("[LocalStorage] SET error: ",
|
|
1804
|
+
t && ((o = getLocalStorage()) == null || o.setItem(e, n));
|
|
1805
|
+
} catch (r) {
|
|
1806
|
+
console.debug("[LocalStorage] SET error: ", r);
|
|
1705
1807
|
}
|
|
1706
|
-
},
|
|
1808
|
+
}, VISITOR_LOCAL_STORAGE_KEY = "builderVisitorId", getVisitorId = ({
|
|
1707
1809
|
canTrack: e
|
|
1708
1810
|
}) => {
|
|
1709
1811
|
if (!e)
|
|
1710
1812
|
return;
|
|
1711
|
-
const t =
|
|
1712
|
-
key:
|
|
1813
|
+
const t = getLocalStorageItem({
|
|
1814
|
+
key: VISITOR_LOCAL_STORAGE_KEY,
|
|
1713
1815
|
canTrack: e
|
|
1714
1816
|
});
|
|
1715
|
-
if (
|
|
1817
|
+
if (checkIsDefined(t))
|
|
1716
1818
|
return t;
|
|
1717
1819
|
{
|
|
1718
|
-
const n =
|
|
1719
|
-
return
|
|
1820
|
+
const n = createVisitorId();
|
|
1821
|
+
return setVisitorId({
|
|
1720
1822
|
id: n,
|
|
1721
1823
|
canTrack: e
|
|
1722
1824
|
}), n;
|
|
1723
1825
|
}
|
|
1724
|
-
},
|
|
1826
|
+
}, createVisitorId = () => uuid(), setVisitorId = ({
|
|
1725
1827
|
id: e,
|
|
1726
1828
|
canTrack: t
|
|
1727
|
-
}) =>
|
|
1728
|
-
key:
|
|
1829
|
+
}) => setLocalStorageItem({
|
|
1830
|
+
key: VISITOR_LOCAL_STORAGE_KEY,
|
|
1729
1831
|
value: e,
|
|
1730
1832
|
canTrack: t
|
|
1731
|
-
}),
|
|
1833
|
+
}), getTrackingEventData = async ({
|
|
1732
1834
|
canTrack: e
|
|
1733
1835
|
}) => {
|
|
1734
1836
|
if (!e)
|
|
@@ -1736,46 +1838,46 @@ const be = "builderSessionId", Gt = async ({
|
|
|
1736
1838
|
visitorId: void 0,
|
|
1737
1839
|
sessionId: void 0
|
|
1738
1840
|
};
|
|
1739
|
-
const t = await
|
|
1841
|
+
const t = await getSessionId({
|
|
1740
1842
|
canTrack: e
|
|
1741
|
-
}), n =
|
|
1843
|
+
}), n = getVisitorId({
|
|
1742
1844
|
canTrack: e
|
|
1743
1845
|
});
|
|
1744
1846
|
return {
|
|
1745
1847
|
sessionId: t,
|
|
1746
1848
|
visitorId: n
|
|
1747
1849
|
};
|
|
1748
|
-
},
|
|
1850
|
+
}, createEvent = async ({
|
|
1749
1851
|
type: e,
|
|
1750
1852
|
canTrack: t,
|
|
1751
1853
|
apiKey: n,
|
|
1752
1854
|
metadata: o,
|
|
1753
|
-
...
|
|
1855
|
+
...r
|
|
1754
1856
|
}) => ({
|
|
1755
1857
|
type: e,
|
|
1756
1858
|
data: {
|
|
1757
|
-
...
|
|
1859
|
+
...r,
|
|
1758
1860
|
metadata: {
|
|
1759
1861
|
url: location.href,
|
|
1760
1862
|
...o
|
|
1761
1863
|
},
|
|
1762
|
-
...await
|
|
1864
|
+
...await getTrackingEventData({
|
|
1763
1865
|
canTrack: t
|
|
1764
1866
|
}),
|
|
1765
|
-
userAttributes:
|
|
1867
|
+
userAttributes: getUserAttributes(),
|
|
1766
1868
|
ownerId: n
|
|
1767
1869
|
}
|
|
1768
1870
|
});
|
|
1769
|
-
async function
|
|
1871
|
+
async function _track(e) {
|
|
1770
1872
|
if (!e.apiKey) {
|
|
1771
|
-
|
|
1873
|
+
logger.error("Missing API key for track call. Please provide your API key.");
|
|
1772
1874
|
return;
|
|
1773
1875
|
}
|
|
1774
|
-
if (e.canTrack && !
|
|
1876
|
+
if (e.canTrack && !isEditing() && (isBrowser() || TARGET === "reactNative"))
|
|
1775
1877
|
return fetch("https://cdn.builder.io/api/v1/track", {
|
|
1776
1878
|
method: "POST",
|
|
1777
1879
|
body: JSON.stringify({
|
|
1778
|
-
events: [await
|
|
1880
|
+
events: [await createEvent(e)]
|
|
1779
1881
|
}),
|
|
1780
1882
|
headers: {
|
|
1781
1883
|
"content-type": "application/json"
|
|
@@ -1785,13 +1887,13 @@ async function rn(e) {
|
|
|
1785
1887
|
console.error("Failed to track: ", t);
|
|
1786
1888
|
});
|
|
1787
1889
|
}
|
|
1788
|
-
const
|
|
1890
|
+
const track = (e) => _track({
|
|
1789
1891
|
...e,
|
|
1790
1892
|
canTrack: !0
|
|
1791
|
-
}),
|
|
1792
|
-
function
|
|
1793
|
-
let n =
|
|
1794
|
-
if (n || (n =
|
|
1893
|
+
}), SDK_VERSION = "0.7.1-0", registry = {};
|
|
1894
|
+
function register(e, t) {
|
|
1895
|
+
let n = registry[e];
|
|
1896
|
+
if (n || (n = registry[e] = []), n.push(t), isBrowser()) {
|
|
1795
1897
|
const o = {
|
|
1796
1898
|
type: "builder.register",
|
|
1797
1899
|
data: {
|
|
@@ -1801,13 +1903,13 @@ function sn(e, t) {
|
|
|
1801
1903
|
};
|
|
1802
1904
|
try {
|
|
1803
1905
|
parent.postMessage(o, "*"), parent !== window && window.postMessage(o, "*");
|
|
1804
|
-
} catch (
|
|
1805
|
-
console.debug("Could not postmessage",
|
|
1906
|
+
} catch (r) {
|
|
1907
|
+
console.debug("Could not postmessage", r);
|
|
1806
1908
|
}
|
|
1807
1909
|
}
|
|
1808
1910
|
}
|
|
1809
|
-
const
|
|
1810
|
-
|
|
1911
|
+
const registerInsertMenu = () => {
|
|
1912
|
+
register("insertMenu", {
|
|
1811
1913
|
name: "_default",
|
|
1812
1914
|
default: !0,
|
|
1813
1915
|
items: [{
|
|
@@ -1829,14 +1931,14 @@ const Un = () => {
|
|
|
1829
1931
|
}]
|
|
1830
1932
|
});
|
|
1831
1933
|
};
|
|
1832
|
-
let
|
|
1833
|
-
const
|
|
1934
|
+
let isSetupForEditing = !1;
|
|
1935
|
+
const setupBrowserForEditing = (e = {}) => {
|
|
1834
1936
|
var t, n;
|
|
1835
|
-
|
|
1937
|
+
isSetupForEditing || (isSetupForEditing = !0, isBrowser() && ((t = window.parent) == null || t.postMessage({
|
|
1836
1938
|
type: "builder.sdkInfo",
|
|
1837
1939
|
data: {
|
|
1838
|
-
target:
|
|
1839
|
-
version:
|
|
1940
|
+
target: TARGET,
|
|
1941
|
+
version: SDK_VERSION,
|
|
1840
1942
|
supportsPatchUpdates: !1,
|
|
1841
1943
|
// Supports builder-model="..." attribute which is needed to
|
|
1842
1944
|
// scope our '+ add block' button styling
|
|
@@ -1851,36 +1953,36 @@ const _n = (e = {}) => {
|
|
|
1851
1953
|
}, "*"), window.addEventListener("message", ({
|
|
1852
1954
|
data: o
|
|
1853
1955
|
}) => {
|
|
1854
|
-
var
|
|
1956
|
+
var r, i;
|
|
1855
1957
|
if (o != null && o.type)
|
|
1856
1958
|
switch (o.type) {
|
|
1857
1959
|
case "builder.evaluate": {
|
|
1858
1960
|
const a = o.data.text, c = o.data.arguments || [], s = o.data.id, u = new Function(a);
|
|
1859
|
-
let
|
|
1961
|
+
let m, h = null;
|
|
1860
1962
|
try {
|
|
1861
|
-
|
|
1963
|
+
m = u.apply(null, c);
|
|
1862
1964
|
} catch (p) {
|
|
1863
|
-
|
|
1965
|
+
h = p;
|
|
1864
1966
|
}
|
|
1865
|
-
|
|
1967
|
+
h ? (r = window.parent) == null || r.postMessage({
|
|
1866
1968
|
type: "builder.evaluateError",
|
|
1867
1969
|
data: {
|
|
1868
1970
|
id: s,
|
|
1869
|
-
error:
|
|
1971
|
+
error: h.message
|
|
1870
1972
|
}
|
|
1871
|
-
}, "*") :
|
|
1872
|
-
var
|
|
1873
|
-
(
|
|
1973
|
+
}, "*") : m && typeof m.then == "function" ? m.then((p) => {
|
|
1974
|
+
var l;
|
|
1975
|
+
(l = window.parent) == null || l.postMessage({
|
|
1874
1976
|
type: "builder.evaluateResult",
|
|
1875
1977
|
data: {
|
|
1876
1978
|
id: s,
|
|
1877
1979
|
result: p
|
|
1878
1980
|
}
|
|
1879
1981
|
}, "*");
|
|
1880
|
-
}).catch(console.error) : (
|
|
1982
|
+
}).catch(console.error) : (i = window.parent) == null || i.postMessage({
|
|
1881
1983
|
type: "builder.evaluateResult",
|
|
1882
1984
|
data: {
|
|
1883
|
-
result:
|
|
1985
|
+
result: m,
|
|
1884
1986
|
id: s
|
|
1885
1987
|
}
|
|
1886
1988
|
}, "*");
|
|
@@ -1889,10 +1991,10 @@ const _n = (e = {}) => {
|
|
|
1889
1991
|
}
|
|
1890
1992
|
})));
|
|
1891
1993
|
};
|
|
1892
|
-
function
|
|
1994
|
+
function round(e) {
|
|
1893
1995
|
return Math.round(e * 1e3) / 1e3;
|
|
1894
1996
|
}
|
|
1895
|
-
const
|
|
1997
|
+
const findParentElement = (e, t, n = !0) => {
|
|
1896
1998
|
if (!(e instanceof HTMLElement))
|
|
1897
1999
|
return null;
|
|
1898
2000
|
let o = n ? e : e.parentElement;
|
|
@@ -1903,45 +2005,279 @@ const cn = (e, t, n = !0) => {
|
|
|
1903
2005
|
return o;
|
|
1904
2006
|
} while (o = o.parentElement);
|
|
1905
2007
|
return null;
|
|
1906
|
-
},
|
|
2008
|
+
}, findBuilderParent = (e) => findParentElement(e, (t) => {
|
|
1907
2009
|
const n = t.getAttribute("builder-id") || t.id;
|
|
1908
2010
|
return (n == null ? void 0 : n.indexOf("builder-")) === 0;
|
|
1909
|
-
}),
|
|
2011
|
+
}), computeOffset = ({
|
|
1910
2012
|
event: e,
|
|
1911
2013
|
target: t
|
|
1912
2014
|
}) => {
|
|
1913
|
-
const n = t.getBoundingClientRect(), o = e.clientX - n.left,
|
|
2015
|
+
const n = t.getBoundingClientRect(), o = e.clientX - n.left, r = e.clientY - n.top, i = round(o / n.width), a = round(r / n.height);
|
|
1914
2016
|
return {
|
|
1915
|
-
x:
|
|
2017
|
+
x: i,
|
|
1916
2018
|
y: a
|
|
1917
2019
|
};
|
|
1918
|
-
},
|
|
1919
|
-
const t = e.target, n = t &&
|
|
2020
|
+
}, getInteractionPropertiesForEvent = (e) => {
|
|
2021
|
+
const t = e.target, n = t && findBuilderParent(t), o = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
|
|
1920
2022
|
return {
|
|
1921
2023
|
targetBuilderElement: o || void 0,
|
|
1922
2024
|
metadata: {
|
|
1923
|
-
targetOffset: t ?
|
|
2025
|
+
targetOffset: t ? computeOffset({
|
|
1924
2026
|
event: e,
|
|
1925
2027
|
target: t
|
|
1926
2028
|
}) : void 0,
|
|
1927
|
-
builderTargetOffset: n ?
|
|
2029
|
+
builderTargetOffset: n ? computeOffset({
|
|
1928
2030
|
event: e,
|
|
1929
2031
|
target: n
|
|
1930
2032
|
}) : void 0,
|
|
1931
2033
|
builderElementIndex: n && o ? [].slice.call(document.getElementsByClassName(o)).indexOf(n) : void 0
|
|
1932
2034
|
}
|
|
1933
2035
|
};
|
|
2036
|
+
}, BUILDER_STORE_PREFIX = "builder.tests", getContentTestKey = (e) => `${BUILDER_STORE_PREFIX}.${e}`, getContentVariationCookie = ({
|
|
2037
|
+
contentId: e
|
|
2038
|
+
}) => getCookie({
|
|
2039
|
+
name: getContentTestKey(e),
|
|
2040
|
+
canTrack: !0
|
|
2041
|
+
}), getContentVariationCookieSync = ({
|
|
2042
|
+
contentId: e
|
|
2043
|
+
}) => getCookieSync({
|
|
2044
|
+
name: getContentTestKey(e),
|
|
2045
|
+
canTrack: !0
|
|
2046
|
+
}), setContentVariationCookie = ({
|
|
2047
|
+
contentId: e,
|
|
2048
|
+
value: t
|
|
2049
|
+
}) => setCookie({
|
|
2050
|
+
name: getContentTestKey(e),
|
|
2051
|
+
value: t,
|
|
2052
|
+
canTrack: !0
|
|
2053
|
+
}), checkIsBuilderContentWithVariations = (e) => checkIsDefined(e.id) && checkIsDefined(e.variations) && Object.keys(e.variations).length > 0, getRandomVariationId = ({
|
|
2054
|
+
id: e,
|
|
2055
|
+
variations: t
|
|
2056
|
+
}) => {
|
|
2057
|
+
var r;
|
|
2058
|
+
let n = 0;
|
|
2059
|
+
const o = Math.random();
|
|
2060
|
+
for (const i in t) {
|
|
2061
|
+
const a = (r = t[i]) == null ? void 0 : r.testRatio;
|
|
2062
|
+
if (n += a, o < n)
|
|
2063
|
+
return i;
|
|
2064
|
+
}
|
|
2065
|
+
return e;
|
|
2066
|
+
}, getAndSetVariantId = (e) => {
|
|
2067
|
+
const t = getRandomVariationId(e);
|
|
2068
|
+
return setContentVariationCookie({
|
|
2069
|
+
contentId: e.id,
|
|
2070
|
+
value: t
|
|
2071
|
+
}).catch((n) => {
|
|
2072
|
+
logger.error("could not store A/B test variation: ", n);
|
|
2073
|
+
}), t;
|
|
2074
|
+
}, getTestFields = ({
|
|
2075
|
+
item: e,
|
|
2076
|
+
testGroupId: t
|
|
2077
|
+
}) => {
|
|
2078
|
+
const n = e.variations[t];
|
|
2079
|
+
return t === e.id || // handle edge-case where `testGroupId` points to non-existing variation
|
|
2080
|
+
!n ? {
|
|
2081
|
+
testVariationId: e.id,
|
|
2082
|
+
testVariationName: "Default"
|
|
2083
|
+
} : {
|
|
2084
|
+
data: n.data,
|
|
2085
|
+
testVariationId: n.id,
|
|
2086
|
+
testVariationName: n.name || (n.id === e.id ? "Default" : "")
|
|
2087
|
+
};
|
|
2088
|
+
}, handleABTestingSync = ({
|
|
2089
|
+
item: e,
|
|
2090
|
+
canTrack: t
|
|
2091
|
+
}) => {
|
|
2092
|
+
if (!t)
|
|
2093
|
+
return e;
|
|
2094
|
+
if (!e)
|
|
2095
|
+
return;
|
|
2096
|
+
if (!checkIsBuilderContentWithVariations(e))
|
|
2097
|
+
return e;
|
|
2098
|
+
const n = getContentVariationCookieSync({
|
|
2099
|
+
contentId: e.id
|
|
2100
|
+
}) || getAndSetVariantId({
|
|
2101
|
+
variations: e.variations,
|
|
2102
|
+
id: e.id
|
|
2103
|
+
}), o = getTestFields({
|
|
2104
|
+
item: e,
|
|
2105
|
+
testGroupId: n
|
|
2106
|
+
});
|
|
2107
|
+
return {
|
|
2108
|
+
...e,
|
|
2109
|
+
...o
|
|
2110
|
+
};
|
|
2111
|
+
}, handleABTesting = async ({
|
|
2112
|
+
item: e,
|
|
2113
|
+
canTrack: t
|
|
2114
|
+
}) => {
|
|
2115
|
+
if (!t || !checkIsBuilderContentWithVariations(e))
|
|
2116
|
+
return e;
|
|
2117
|
+
const o = await getContentVariationCookie({
|
|
2118
|
+
contentId: e.id
|
|
2119
|
+
}) || getAndSetVariantId({
|
|
2120
|
+
variations: e.variations,
|
|
2121
|
+
id: e.id
|
|
2122
|
+
}), r = getTestFields({
|
|
2123
|
+
item: e,
|
|
2124
|
+
testGroupId: o
|
|
2125
|
+
});
|
|
2126
|
+
return {
|
|
2127
|
+
...e,
|
|
2128
|
+
...r
|
|
2129
|
+
};
|
|
2130
|
+
}, getDefaultCanTrack = (e) => checkIsDefined(e) ? e : !0, getIdFromSearchParams = (e) => {
|
|
2131
|
+
const t = e.get("preview"), n = e.get("overrides." + t);
|
|
2132
|
+
return n || logger.warn("No previewed ID found in search params."), n;
|
|
1934
2133
|
};
|
|
1935
|
-
function
|
|
1936
|
-
globalThis._BUILDER_PREVIEW_LRU_CACHE || (globalThis._BUILDER_PREVIEW_LRU_CACHE = new
|
|
2134
|
+
function init() {
|
|
2135
|
+
globalThis._BUILDER_PREVIEW_LRU_CACHE || (globalThis._BUILDER_PREVIEW_LRU_CACHE = new LRUCache({
|
|
1937
2136
|
max: 500,
|
|
1938
2137
|
// how long to live in ms
|
|
1939
2138
|
ttl: 1e3 * 60 * 5
|
|
1940
2139
|
}));
|
|
1941
2140
|
}
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
2141
|
+
function getPreviewContent(e) {
|
|
2142
|
+
init();
|
|
2143
|
+
const t = getIdFromSearchParams(e);
|
|
2144
|
+
return typeof t == "string" ? globalThis._BUILDER_PREVIEW_LRU_CACHE.get(t) : void 0;
|
|
2145
|
+
}
|
|
2146
|
+
function flatten(e, t = null, n = ".") {
|
|
2147
|
+
return Object.keys(e).reduce((o, r) => {
|
|
2148
|
+
const i = e[r], a = [t, r].filter(Boolean).join(n);
|
|
2149
|
+
return [typeof i == "object", i !== null, !(Array.isArray(i) && i.length === 0)].every(Boolean) ? {
|
|
2150
|
+
...o,
|
|
2151
|
+
...flatten(i, a, n)
|
|
2152
|
+
} : {
|
|
2153
|
+
...o,
|
|
2154
|
+
[a]: i
|
|
2155
|
+
};
|
|
2156
|
+
}, {});
|
|
2157
|
+
}
|
|
2158
|
+
const BUILDER_SEARCHPARAMS_PREFIX = "builder.", BUILDER_OPTIONS_PREFIX = "options.", convertSearchParamsToQueryObject = (e) => {
|
|
2159
|
+
const t = {};
|
|
2160
|
+
return e.forEach((n, o) => {
|
|
2161
|
+
t[o] = n;
|
|
2162
|
+
}), t;
|
|
2163
|
+
}, getBuilderSearchParams = (e) => {
|
|
2164
|
+
if (!e)
|
|
2165
|
+
return {};
|
|
2166
|
+
const t = normalizeSearchParams(e), n = {};
|
|
2167
|
+
return Object.keys(t).forEach((o) => {
|
|
2168
|
+
if (o.startsWith(BUILDER_SEARCHPARAMS_PREFIX)) {
|
|
2169
|
+
const r = o.replace(BUILDER_SEARCHPARAMS_PREFIX, "").replace(BUILDER_OPTIONS_PREFIX, "");
|
|
2170
|
+
n[r] = t[o];
|
|
2171
|
+
}
|
|
2172
|
+
}), n;
|
|
2173
|
+
}, getBuilderSearchParamsFromWindow = () => {
|
|
2174
|
+
if (!isBrowser())
|
|
2175
|
+
return {};
|
|
2176
|
+
const e = new URLSearchParams(window.location.search);
|
|
2177
|
+
return getBuilderSearchParams(e);
|
|
2178
|
+
}, normalizeSearchParams = (e) => e instanceof URLSearchParams ? convertSearchParamsToQueryObject(e) : e, DEFAULT_API_VERSION = "v3", isPositiveNumber = (e) => typeof e == "number" && !isNaN(e) && e >= 0, generateContentUrl = (e) => {
|
|
2179
|
+
let {
|
|
2180
|
+
noTraverse: t = !1
|
|
2181
|
+
} = e;
|
|
2182
|
+
const {
|
|
2183
|
+
limit: n = 30,
|
|
2184
|
+
userAttributes: o,
|
|
2185
|
+
query: r,
|
|
2186
|
+
model: i,
|
|
2187
|
+
apiKey: a,
|
|
2188
|
+
includeRefs: c = !0,
|
|
2189
|
+
enrich: s,
|
|
2190
|
+
locale: u,
|
|
2191
|
+
apiVersion: m = DEFAULT_API_VERSION,
|
|
2192
|
+
fields: h,
|
|
2193
|
+
omit: p,
|
|
2194
|
+
offset: l,
|
|
2195
|
+
cacheSeconds: f,
|
|
2196
|
+
staleCacheSeconds: d,
|
|
2197
|
+
sort: b,
|
|
2198
|
+
includeUnpublished: y
|
|
2199
|
+
} = e;
|
|
2200
|
+
if (!a)
|
|
2201
|
+
throw new Error("Missing API key");
|
|
2202
|
+
if (!["v2", "v3"].includes(m))
|
|
2203
|
+
throw new Error(`Invalid apiVersion: expected 'v2' or 'v3', received '${m}'`);
|
|
2204
|
+
(e.limit === void 0 || e.limit > 1) && !("noTraverse" in e) && (t = !0);
|
|
2205
|
+
const g = new URL(`https://cdn.builder.io/api/${m}/content/${i}?apiKey=${a}&limit=${n}&noTraverse=${t}&includeRefs=${c}${u ? `&locale=${u}` : ""}${s ? `&enrich=${s}` : ""}`);
|
|
2206
|
+
if (g.searchParams.set("omit", p || "meta.componentsUsed"), h && g.searchParams.set("fields", h), Number.isFinite(l) && l > -1 && g.searchParams.set("offset", String(Math.floor(l))), typeof y == "boolean" && g.searchParams.set("includeUnpublished", String(y)), f && isPositiveNumber(f) && g.searchParams.set("cacheSeconds", String(f)), d && isPositiveNumber(d) && g.searchParams.set("staleCacheSeconds", String(d)), b) {
|
|
2207
|
+
const S = flatten({
|
|
2208
|
+
sort: b
|
|
2209
|
+
});
|
|
2210
|
+
for (const C in S)
|
|
2211
|
+
g.searchParams.set(C, JSON.stringify(S[C]));
|
|
2212
|
+
}
|
|
2213
|
+
const v = {
|
|
2214
|
+
...getBuilderSearchParamsFromWindow(),
|
|
2215
|
+
...normalizeSearchParams(e.options || {})
|
|
2216
|
+
}, x = flatten(v);
|
|
2217
|
+
for (const S in x)
|
|
2218
|
+
g.searchParams.set(S, String(x[S]));
|
|
2219
|
+
if (o && g.searchParams.set("userAttributes", JSON.stringify(o)), r) {
|
|
2220
|
+
const S = flatten({
|
|
2221
|
+
query: r
|
|
2222
|
+
});
|
|
2223
|
+
for (const C in S)
|
|
2224
|
+
g.searchParams.set(C, JSON.stringify(S[C]));
|
|
2225
|
+
}
|
|
2226
|
+
return g;
|
|
2227
|
+
}, checkContentHasResults = (e) => "results" in e;
|
|
2228
|
+
async function fetchOneEntry(e) {
|
|
2229
|
+
const t = await fetchEntries({
|
|
2230
|
+
...e,
|
|
2231
|
+
limit: 1
|
|
2232
|
+
});
|
|
2233
|
+
return t && t.results[0] || null;
|
|
2234
|
+
}
|
|
2235
|
+
const getContent = fetchOneEntry, _fetchContent = async (e) => {
|
|
2236
|
+
const t = generateContentUrl(e);
|
|
2237
|
+
return await (await fetch$1(t.href)).json();
|
|
2238
|
+
}, _processContentResult = async (e, t, n = generateContentUrl(e)) => {
|
|
2239
|
+
const o = getDefaultCanTrack(e.canTrack);
|
|
2240
|
+
if (n.search.includes("preview=")) {
|
|
2241
|
+
const i = [];
|
|
2242
|
+
for (const a of t.results) {
|
|
2243
|
+
const c = getPreviewContent(n.searchParams);
|
|
2244
|
+
i.push(c || a);
|
|
2245
|
+
}
|
|
2246
|
+
t.results = i;
|
|
2247
|
+
}
|
|
2248
|
+
if (!o || !(isBrowser() || TARGET === "reactNative"))
|
|
2249
|
+
return t;
|
|
2250
|
+
try {
|
|
2251
|
+
const i = [];
|
|
2252
|
+
for (const a of t.results)
|
|
2253
|
+
i.push(await handleABTesting({
|
|
2254
|
+
item: a,
|
|
2255
|
+
canTrack: o
|
|
2256
|
+
}));
|
|
2257
|
+
t.results = i;
|
|
2258
|
+
} catch (i) {
|
|
2259
|
+
logger.error("Could not process A/B tests. ", i);
|
|
2260
|
+
}
|
|
2261
|
+
return t;
|
|
2262
|
+
};
|
|
2263
|
+
async function fetchEntries(e) {
|
|
2264
|
+
try {
|
|
2265
|
+
const t = generateContentUrl(e), n = await _fetchContent(e);
|
|
2266
|
+
return checkContentHasResults(n) ? _processContentResult(e, n) : (logger.error("Error fetching data. ", {
|
|
2267
|
+
url: t,
|
|
2268
|
+
content: n,
|
|
2269
|
+
options: e
|
|
2270
|
+
}), null);
|
|
2271
|
+
} catch (t) {
|
|
2272
|
+
return logger.error("Error fetching data. ", t), null;
|
|
2273
|
+
}
|
|
2274
|
+
}
|
|
2275
|
+
const getAllContent = fetchEntries;
|
|
2276
|
+
function isPreviewing() {
|
|
2277
|
+
return !isBrowser() || isEditing() ? !1 : location.search.indexOf("builder.preview=") !== -1;
|
|
2278
|
+
}
|
|
2279
|
+
function InlinedScript(e) {
|
|
2280
|
+
return /* @__PURE__ */ jsx(
|
|
1945
2281
|
"script",
|
|
1946
2282
|
{
|
|
1947
2283
|
dangerouslySetInnerHTML: { __html: e.scriptStr },
|
|
@@ -1949,38 +2285,38 @@ function W(e) {
|
|
|
1949
2285
|
}
|
|
1950
2286
|
);
|
|
1951
2287
|
}
|
|
1952
|
-
function
|
|
1953
|
-
var
|
|
1954
|
-
const t =
|
|
2288
|
+
function ContentComponent(e) {
|
|
2289
|
+
var r, i, a, c, s, u, m, h, p;
|
|
2290
|
+
const t = getRenderContentScriptString({
|
|
1955
2291
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
1956
|
-
variationId: (
|
|
2292
|
+
variationId: (r = e.content) == null ? void 0 : r.testVariationId,
|
|
1957
2293
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
1958
|
-
contentId: (
|
|
2294
|
+
contentId: (i = e.content) == null ? void 0 : i.id
|
|
1959
2295
|
}), n = [
|
|
1960
|
-
...
|
|
2296
|
+
...getDefaultRegisteredComponents(),
|
|
1961
2297
|
// While this `components` object is deprecated, we must maintain support for it.
|
|
1962
2298
|
// Since users are able to override our default components, we need to make sure that we do not break such
|
|
1963
2299
|
// existing usage.
|
|
1964
2300
|
// This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
|
|
1965
2301
|
// which is the new standard way of providing custom components, and must therefore take precedence.
|
|
1966
|
-
...
|
|
2302
|
+
...components,
|
|
1967
2303
|
...e.customComponents || []
|
|
1968
2304
|
].reduce(
|
|
1969
|
-
(
|
|
1970
|
-
...
|
|
2305
|
+
(l, { component: f, ...d }) => ({
|
|
2306
|
+
...l,
|
|
1971
2307
|
[d.name]: {
|
|
1972
|
-
component:
|
|
1973
|
-
...
|
|
2308
|
+
component: f,
|
|
2309
|
+
...serializeComponentInfo(d)
|
|
1974
2310
|
}
|
|
1975
2311
|
}),
|
|
1976
2312
|
{}
|
|
1977
2313
|
), o = {
|
|
1978
|
-
content:
|
|
2314
|
+
content: getContentInitialValue({
|
|
1979
2315
|
content: e.content,
|
|
1980
2316
|
data: e.data
|
|
1981
2317
|
}),
|
|
1982
2318
|
localState: void 0,
|
|
1983
|
-
rootState:
|
|
2319
|
+
rootState: getContextStateInitialValue({
|
|
1984
2320
|
content: e.content,
|
|
1985
2321
|
data: e.data,
|
|
1986
2322
|
locale: e.locale
|
|
@@ -1990,25 +2326,25 @@ function oe(e) {
|
|
|
1990
2326
|
apiKey: e.apiKey,
|
|
1991
2327
|
apiVersion: e.apiVersion,
|
|
1992
2328
|
componentInfos: [
|
|
1993
|
-
...
|
|
2329
|
+
...getDefaultRegisteredComponents(),
|
|
1994
2330
|
// While this `components` object is deprecated, we must maintain support for it.
|
|
1995
2331
|
// Since users are able to override our default components, we need to make sure that we do not break such
|
|
1996
2332
|
// existing usage.
|
|
1997
2333
|
// This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
|
|
1998
2334
|
// which is the new standard way of providing custom components, and must therefore take precedence.
|
|
1999
|
-
...
|
|
2335
|
+
...components,
|
|
2000
2336
|
...e.customComponents || []
|
|
2001
2337
|
].reduce(
|
|
2002
|
-
(
|
|
2003
|
-
...
|
|
2004
|
-
[d.name]:
|
|
2338
|
+
(l, { component: f, ...d }) => ({
|
|
2339
|
+
...l,
|
|
2340
|
+
[d.name]: serializeComponentInfo(d)
|
|
2005
2341
|
}),
|
|
2006
2342
|
{}
|
|
2007
2343
|
),
|
|
2008
2344
|
inheritedStyles: {}
|
|
2009
2345
|
};
|
|
2010
|
-
return /* @__PURE__ */
|
|
2011
|
-
|
|
2346
|
+
return /* @__PURE__ */ jsxs(
|
|
2347
|
+
EnableEditor,
|
|
2012
2348
|
{
|
|
2013
2349
|
content: e.content,
|
|
2014
2350
|
model: e.model,
|
|
@@ -2022,19 +2358,19 @@ function oe(e) {
|
|
|
2022
2358
|
showContent: e.showContent,
|
|
2023
2359
|
builderContextSignal: o,
|
|
2024
2360
|
children: [
|
|
2025
|
-
e.isSsrAbTest ? /* @__PURE__ */
|
|
2026
|
-
/* @__PURE__ */
|
|
2027
|
-
|
|
2361
|
+
e.isSsrAbTest ? /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(InlinedScript, { scriptStr: t }) }) : null,
|
|
2362
|
+
/* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(
|
|
2363
|
+
ContentStyles,
|
|
2028
2364
|
{
|
|
2029
2365
|
contentId: (a = o.content) == null ? void 0 : a.id,
|
|
2030
2366
|
cssCode: (s = (c = o.content) == null ? void 0 : c.data) == null ? void 0 : s.cssCode,
|
|
2031
|
-
customFonts: (
|
|
2367
|
+
customFonts: (m = (u = o.content) == null ? void 0 : u.data) == null ? void 0 : m.customFonts
|
|
2032
2368
|
}
|
|
2033
2369
|
) }),
|
|
2034
|
-
/* @__PURE__ */
|
|
2035
|
-
|
|
2370
|
+
/* @__PURE__ */ jsx(
|
|
2371
|
+
Blocks,
|
|
2036
2372
|
{
|
|
2037
|
-
blocks: (p = (
|
|
2373
|
+
blocks: (p = (h = o.content) == null ? void 0 : h.data) == null ? void 0 : p.blocks,
|
|
2038
2374
|
context: o,
|
|
2039
2375
|
registeredComponents: n
|
|
2040
2376
|
}
|
|
@@ -2043,140 +2379,45 @@ function oe(e) {
|
|
|
2043
2379
|
}
|
|
2044
2380
|
);
|
|
2045
2381
|
}
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
canTrack: !0
|
|
2051
|
-
}), fn = ({
|
|
2052
|
-
contentId: e
|
|
2053
|
-
}) => fe({
|
|
2054
|
-
name: j(e),
|
|
2055
|
-
canTrack: !0
|
|
2056
|
-
}), hn = ({
|
|
2057
|
-
contentId: e,
|
|
2058
|
-
value: t
|
|
2059
|
-
}) => ge({
|
|
2060
|
-
name: j(e),
|
|
2061
|
-
value: t,
|
|
2062
|
-
canTrack: !0
|
|
2063
|
-
}), Se = (e) => C(e.id) && C(e.variations) && Object.keys(e.variations).length > 0, gn = ({
|
|
2064
|
-
id: e,
|
|
2065
|
-
variations: t
|
|
2066
|
-
}) => {
|
|
2067
|
-
var i;
|
|
2068
|
-
let n = 0;
|
|
2069
|
-
const o = Math.random();
|
|
2070
|
-
for (const r in t) {
|
|
2071
|
-
const a = (i = t[r]) == null ? void 0 : i.testRatio;
|
|
2072
|
-
if (n += a, o < n)
|
|
2073
|
-
return r;
|
|
2074
|
-
}
|
|
2075
|
-
return e;
|
|
2076
|
-
}, ve = (e) => {
|
|
2077
|
-
const t = gn(e);
|
|
2078
|
-
return hn({
|
|
2079
|
-
contentId: e.id,
|
|
2080
|
-
value: t
|
|
2081
|
-
}).catch((n) => {
|
|
2082
|
-
k.error("could not store A/B test variation: ", n);
|
|
2083
|
-
}), t;
|
|
2084
|
-
}, ke = ({
|
|
2085
|
-
item: e,
|
|
2086
|
-
testGroupId: t
|
|
2087
|
-
}) => {
|
|
2088
|
-
const n = e.variations[t];
|
|
2089
|
-
return t === e.id || // handle edge-case where `testGroupId` points to non-existing variation
|
|
2090
|
-
!n ? {
|
|
2091
|
-
testVariationId: e.id,
|
|
2092
|
-
testVariationName: "Default"
|
|
2093
|
-
} : {
|
|
2094
|
-
data: n.data,
|
|
2095
|
-
testVariationId: n.id,
|
|
2096
|
-
testVariationName: n.name || (n.id === e.id ? "Default" : "")
|
|
2097
|
-
};
|
|
2098
|
-
}, pn = ({
|
|
2099
|
-
item: e,
|
|
2100
|
-
canTrack: t
|
|
2101
|
-
}) => {
|
|
2102
|
-
if (!t)
|
|
2103
|
-
return e;
|
|
2104
|
-
if (!e)
|
|
2105
|
-
return;
|
|
2106
|
-
if (!Se(e))
|
|
2107
|
-
return e;
|
|
2108
|
-
const n = fn({
|
|
2109
|
-
contentId: e.id
|
|
2110
|
-
}) || ve({
|
|
2111
|
-
variations: e.variations,
|
|
2112
|
-
id: e.id
|
|
2113
|
-
}), o = ke({
|
|
2114
|
-
item: e,
|
|
2115
|
-
testGroupId: n
|
|
2116
|
-
});
|
|
2117
|
-
return {
|
|
2118
|
-
...e,
|
|
2119
|
-
...o
|
|
2120
|
-
};
|
|
2121
|
-
}, bn = async ({
|
|
2122
|
-
item: e,
|
|
2123
|
-
canTrack: t
|
|
2124
|
-
}) => {
|
|
2125
|
-
if (!t || !Se(e))
|
|
2126
|
-
return e;
|
|
2127
|
-
const o = await mn({
|
|
2128
|
-
contentId: e.id
|
|
2129
|
-
}) || ve({
|
|
2130
|
-
variations: e.variations,
|
|
2131
|
-
id: e.id
|
|
2132
|
-
}), i = ke({
|
|
2133
|
-
item: e,
|
|
2134
|
-
testGroupId: o
|
|
2135
|
-
});
|
|
2136
|
-
return {
|
|
2137
|
-
...e,
|
|
2138
|
-
...i
|
|
2139
|
-
};
|
|
2140
|
-
};
|
|
2141
|
-
function we(e) {
|
|
2142
|
-
var r, a, c;
|
|
2143
|
-
const t = mt({
|
|
2144
|
-
canTrack: O(e.canTrack),
|
|
2382
|
+
function ContentVariants(e) {
|
|
2383
|
+
var i, a, c;
|
|
2384
|
+
const t = checkShouldRunVariants({
|
|
2385
|
+
canTrack: getDefaultCanTrack(e.canTrack),
|
|
2145
2386
|
content: e.content
|
|
2146
2387
|
}), n = function() {
|
|
2147
2388
|
var u;
|
|
2148
|
-
return
|
|
2149
|
-
|
|
2150
|
-
id:
|
|
2151
|
-
testRatio:
|
|
2389
|
+
return getVariantsScriptString(
|
|
2390
|
+
getVariants(e.content).map((m) => ({
|
|
2391
|
+
id: m.testVariationId,
|
|
2392
|
+
testRatio: m.testRatio
|
|
2152
2393
|
})),
|
|
2153
2394
|
((u = e.content) == null ? void 0 : u.id) || ""
|
|
2154
2395
|
);
|
|
2155
2396
|
}, o = function() {
|
|
2156
|
-
return
|
|
2157
|
-
},
|
|
2397
|
+
return getVariants(e.content).map((u) => `.variant-${u.testVariationId} { display: none; } `).join("");
|
|
2398
|
+
}, r = function() {
|
|
2158
2399
|
var u;
|
|
2159
2400
|
return t ? {
|
|
2160
2401
|
...e.content,
|
|
2161
2402
|
testVariationId: (u = e.content) == null ? void 0 : u.id
|
|
2162
|
-
} :
|
|
2403
|
+
} : handleABTestingSync({
|
|
2163
2404
|
item: e.content,
|
|
2164
|
-
canTrack:
|
|
2405
|
+
canTrack: getDefaultCanTrack(e.canTrack)
|
|
2165
2406
|
});
|
|
2166
2407
|
};
|
|
2167
|
-
return /* @__PURE__ */
|
|
2168
|
-
!e.__isNestedRender &&
|
|
2169
|
-
t ? /* @__PURE__ */
|
|
2170
|
-
/* @__PURE__ */
|
|
2171
|
-
|
|
2408
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
2409
|
+
!e.__isNestedRender && TARGET !== "reactNative" ? /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(InlinedScript, { scriptStr: getScriptString() }) }) : null,
|
|
2410
|
+
t ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
2411
|
+
/* @__PURE__ */ jsx(
|
|
2412
|
+
InlinedStyles,
|
|
2172
2413
|
{
|
|
2173
|
-
id: `variants-styles-${(
|
|
2414
|
+
id: `variants-styles-${(i = e.content) == null ? void 0 : i.id}`,
|
|
2174
2415
|
styles: o()
|
|
2175
2416
|
}
|
|
2176
2417
|
),
|
|
2177
|
-
/* @__PURE__ */
|
|
2178
|
-
(a =
|
|
2179
|
-
|
|
2418
|
+
/* @__PURE__ */ jsx(InlinedScript, { scriptStr: n() }),
|
|
2419
|
+
(a = getVariants(e.content)) == null ? void 0 : a.map((s) => /* @__PURE__ */ jsx(
|
|
2420
|
+
ContentComponent,
|
|
2180
2421
|
{
|
|
2181
2422
|
content: s,
|
|
2182
2423
|
showContent: !1,
|
|
@@ -2196,10 +2437,10 @@ function we(e) {
|
|
|
2196
2437
|
s.testVariationId
|
|
2197
2438
|
))
|
|
2198
2439
|
] }) : null,
|
|
2199
|
-
/* @__PURE__ */
|
|
2200
|
-
|
|
2440
|
+
/* @__PURE__ */ jsx(
|
|
2441
|
+
ContentComponent,
|
|
2201
2442
|
{
|
|
2202
|
-
content:
|
|
2443
|
+
content: r(),
|
|
2203
2444
|
classNameProp: `variant-${(c = e.content) == null ? void 0 : c.id}`,
|
|
2204
2445
|
showContent: !0,
|
|
2205
2446
|
model: e.model,
|
|
@@ -2217,13 +2458,13 @@ function we(e) {
|
|
|
2217
2458
|
)
|
|
2218
2459
|
] });
|
|
2219
2460
|
}
|
|
2220
|
-
const
|
|
2461
|
+
const fetchSymbolContent = async ({
|
|
2221
2462
|
builderContextValue: e,
|
|
2222
2463
|
symbol: t
|
|
2223
2464
|
}) => {
|
|
2224
2465
|
if (t != null && t.model && // This is a hack, we should not need to check for this, but it is needed for Svelte.
|
|
2225
2466
|
(e != null && e.apiKey))
|
|
2226
|
-
return
|
|
2467
|
+
return fetchOneEntry({
|
|
2227
2468
|
model: t.model,
|
|
2228
2469
|
apiKey: e.apiKey,
|
|
2229
2470
|
apiVersion: e.apiVersion,
|
|
@@ -2233,11 +2474,11 @@ const yn = async ({
|
|
|
2233
2474
|
}
|
|
2234
2475
|
}
|
|
2235
2476
|
}).catch((n) => {
|
|
2236
|
-
|
|
2477
|
+
logger.error("Could not fetch symbol content: ", n);
|
|
2237
2478
|
});
|
|
2238
2479
|
};
|
|
2239
|
-
async function
|
|
2240
|
-
var o,
|
|
2480
|
+
async function Symbol$1(e) {
|
|
2481
|
+
var o, r, i, a;
|
|
2241
2482
|
const t = function() {
|
|
2242
2483
|
var s, u;
|
|
2243
2484
|
return [
|
|
@@ -2246,12 +2487,12 @@ async function xn(e) {
|
|
|
2246
2487
|
(s = e.symbol) != null && s.inline ? "builder-inline-symbol" : void 0,
|
|
2247
2488
|
(u = e.symbol) != null && u.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
|
|
2248
2489
|
].filter(Boolean).join(" ");
|
|
2249
|
-
}, n = ((o = e.symbol) == null ? void 0 : o.content) || await
|
|
2490
|
+
}, n = ((o = e.symbol) == null ? void 0 : o.content) || await fetchSymbolContent({
|
|
2250
2491
|
symbol: e.symbol,
|
|
2251
2492
|
builderContextValue: e.builderContext
|
|
2252
2493
|
});
|
|
2253
|
-
return /* @__PURE__ */
|
|
2254
|
-
|
|
2494
|
+
return /* @__PURE__ */ jsx("div", { ...e.attributes, className: t(), children: /* @__PURE__ */ jsx(
|
|
2495
|
+
ContentVariants,
|
|
2255
2496
|
{
|
|
2256
2497
|
__isNestedRender: !0,
|
|
2257
2498
|
apiVersion: e.builderContext.apiVersion,
|
|
@@ -2259,156 +2500,29 @@ async function xn(e) {
|
|
|
2259
2500
|
context: e.builderContext.context,
|
|
2260
2501
|
customComponents: Object.values(e.builderComponents),
|
|
2261
2502
|
data: {
|
|
2262
|
-
...(
|
|
2503
|
+
...(r = e.symbol) == null ? void 0 : r.data,
|
|
2263
2504
|
...e.builderContext.localState,
|
|
2264
|
-
...(
|
|
2505
|
+
...(i = n == null ? void 0 : n.data) == null ? void 0 : i.state
|
|
2265
2506
|
},
|
|
2266
2507
|
model: (a = e.symbol) == null ? void 0 : a.model,
|
|
2267
2508
|
content: n
|
|
2268
2509
|
}
|
|
2269
2510
|
) });
|
|
2270
2511
|
}
|
|
2271
|
-
const
|
|
2272
|
-
function
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
const ie = {};
|
|
2276
|
-
function zn(e) {
|
|
2277
|
-
if (v()) {
|
|
2278
|
-
Object.assign(ie, e);
|
|
2512
|
+
const RenderBlocks = Blocks, RenderContent = ContentVariants, settings = {};
|
|
2513
|
+
function setEditorSettings(e) {
|
|
2514
|
+
if (isBrowser()) {
|
|
2515
|
+
Object.assign(settings, e);
|
|
2279
2516
|
const t = {
|
|
2280
2517
|
type: "builder.settingsChange",
|
|
2281
|
-
data:
|
|
2518
|
+
data: settings
|
|
2282
2519
|
};
|
|
2283
2520
|
parent.postMessage(t, "*");
|
|
2284
2521
|
}
|
|
2285
2522
|
}
|
|
2286
|
-
const
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
};
|
|
2290
|
-
function vn(e) {
|
|
2291
|
-
un();
|
|
2292
|
-
const t = Sn(e);
|
|
2293
|
-
return typeof t == "string" ? globalThis._BUILDER_PREVIEW_LRU_CACHE.get(t) : void 0;
|
|
2294
|
-
}
|
|
2295
|
-
function N(e, t = null, n = ".") {
|
|
2296
|
-
return Object.keys(e).reduce((o, i) => {
|
|
2297
|
-
const r = e[i], a = [t, i].filter(Boolean).join(n);
|
|
2298
|
-
return [typeof r == "object", r !== null, !(Array.isArray(r) && r.length === 0)].every(Boolean) ? {
|
|
2299
|
-
...o,
|
|
2300
|
-
...N(r, a, n)
|
|
2301
|
-
} : {
|
|
2302
|
-
...o,
|
|
2303
|
-
[a]: r
|
|
2304
|
-
};
|
|
2305
|
-
}, {});
|
|
2306
|
-
}
|
|
2307
|
-
const re = "builder.", kn = "options.", wn = (e) => {
|
|
2308
|
-
const t = {};
|
|
2309
|
-
return e.forEach((n, o) => {
|
|
2310
|
-
t[o] = n;
|
|
2311
|
-
}), t;
|
|
2312
|
-
}, Ce = (e) => {
|
|
2313
|
-
if (!e)
|
|
2314
|
-
return {};
|
|
2315
|
-
const t = Ie(e), n = {};
|
|
2316
|
-
return Object.keys(t).forEach((o) => {
|
|
2317
|
-
if (o.startsWith(re)) {
|
|
2318
|
-
const i = o.replace(re, "").replace(kn, "");
|
|
2319
|
-
n[i] = t[o];
|
|
2320
|
-
}
|
|
2321
|
-
}), n;
|
|
2322
|
-
}, Cn = () => {
|
|
2323
|
-
if (!v())
|
|
2324
|
-
return {};
|
|
2325
|
-
const e = new URLSearchParams(window.location.search);
|
|
2326
|
-
return Ce(e);
|
|
2327
|
-
}, Ie = (e) => e instanceof URLSearchParams ? wn(e) : e, In = "v3", K = (e) => {
|
|
2328
|
-
let {
|
|
2329
|
-
noTraverse: t = !1
|
|
2330
|
-
} = e;
|
|
2331
|
-
const {
|
|
2332
|
-
limit: n = 30,
|
|
2333
|
-
userAttributes: o,
|
|
2334
|
-
query: i,
|
|
2335
|
-
model: r,
|
|
2336
|
-
apiKey: a,
|
|
2337
|
-
includeRefs: c = !0,
|
|
2338
|
-
enrich: s,
|
|
2339
|
-
locale: u,
|
|
2340
|
-
apiVersion: f = In
|
|
2341
|
-
} = e;
|
|
2342
|
-
if (!a)
|
|
2343
|
-
throw new Error("Missing API key");
|
|
2344
|
-
if (!["v2", "v3"].includes(f))
|
|
2345
|
-
throw new Error(`Invalid apiVersion: expected 'v2' or 'v3', received '${f}'`);
|
|
2346
|
-
(e.limit === void 0 || e.limit > 1) && !("noTraverse" in e) && (t = !0);
|
|
2347
|
-
const g = new URL(`https://cdn.builder.io/api/${f}/content/${r}?apiKey=${a}&limit=${n}&noTraverse=${t}&includeRefs=${c}${u ? `&locale=${u}` : ""}${s ? `&enrich=${s}` : ""}`), p = {
|
|
2348
|
-
...Cn(),
|
|
2349
|
-
...Ie(e.options || {})
|
|
2350
|
-
}, m = N(p);
|
|
2351
|
-
for (const h in m)
|
|
2352
|
-
g.searchParams.set(h, String(m[h]));
|
|
2353
|
-
if (o && g.searchParams.set("userAttributes", JSON.stringify(o)), i) {
|
|
2354
|
-
const h = N({
|
|
2355
|
-
query: i
|
|
2356
|
-
});
|
|
2357
|
-
for (const d in h)
|
|
2358
|
-
g.searchParams.set(d, JSON.stringify(h[d]));
|
|
2359
|
-
}
|
|
2360
|
-
return g;
|
|
2361
|
-
}, Tn = (e) => "results" in e;
|
|
2362
|
-
async function H(e) {
|
|
2363
|
-
const t = await Te({
|
|
2364
|
-
...e,
|
|
2365
|
-
limit: 1
|
|
2366
|
-
});
|
|
2367
|
-
return t && t.results[0] || null;
|
|
2368
|
-
}
|
|
2369
|
-
const qn = H, Rn = async (e) => {
|
|
2370
|
-
const t = K(e);
|
|
2371
|
-
return await (await jt(t.href)).json();
|
|
2372
|
-
}, En = async (e, t, n = K(e)) => {
|
|
2373
|
-
const o = O(e.canTrack);
|
|
2374
|
-
if (n.search.includes("preview=")) {
|
|
2375
|
-
const r = [];
|
|
2376
|
-
for (const a of t.results) {
|
|
2377
|
-
const c = vn(n.searchParams);
|
|
2378
|
-
r.push(c || a);
|
|
2379
|
-
}
|
|
2380
|
-
t.results = r;
|
|
2381
|
-
}
|
|
2382
|
-
if (!o || !(v() || I === "reactNative"))
|
|
2383
|
-
return t;
|
|
2384
|
-
try {
|
|
2385
|
-
const r = [];
|
|
2386
|
-
for (const a of t.results)
|
|
2387
|
-
r.push(await bn({
|
|
2388
|
-
item: a,
|
|
2389
|
-
canTrack: o
|
|
2390
|
-
}));
|
|
2391
|
-
t.results = r;
|
|
2392
|
-
} catch (r) {
|
|
2393
|
-
k.error("Could not process A/B tests. ", r);
|
|
2394
|
-
}
|
|
2395
|
-
return t;
|
|
2396
|
-
};
|
|
2397
|
-
async function Te(e) {
|
|
2398
|
-
try {
|
|
2399
|
-
const t = K(e), n = await Rn(e);
|
|
2400
|
-
return Tn(n) ? En(e, n) : (k.error("Error fetching data. ", {
|
|
2401
|
-
url: t,
|
|
2402
|
-
content: n,
|
|
2403
|
-
options: e
|
|
2404
|
-
}), null);
|
|
2405
|
-
} catch (t) {
|
|
2406
|
-
return k.error("Error fetching data. ", t), null;
|
|
2407
|
-
}
|
|
2408
|
-
}
|
|
2409
|
-
const Gn = Te, Jn = async (e) => {
|
|
2410
|
-
var o, i, r;
|
|
2411
|
-
const t = e.path || ((o = e.url) == null ? void 0 : o.pathname) || ((i = e.userAttributes) == null ? void 0 : i.urlPath), n = {
|
|
2523
|
+
const fetchBuilderProps = async (e) => {
|
|
2524
|
+
var o, r, i;
|
|
2525
|
+
const t = e.path || ((o = e.url) == null ? void 0 : o.pathname) || ((r = e.userAttributes) == null ? void 0 : r.urlPath), n = {
|
|
2412
2526
|
...e,
|
|
2413
2527
|
apiKey: e.apiKey,
|
|
2414
2528
|
model: e.model || "page",
|
|
@@ -2418,48 +2532,48 @@ const Gn = Te, Jn = async (e) => {
|
|
|
2418
2532
|
urlPath: t
|
|
2419
2533
|
} : {}
|
|
2420
2534
|
},
|
|
2421
|
-
options:
|
|
2535
|
+
options: getBuilderSearchParams(e.searchParams || ((i = e.url) == null ? void 0 : i.searchParams) || e.options)
|
|
2422
2536
|
};
|
|
2423
2537
|
return {
|
|
2424
2538
|
apiKey: n.apiKey,
|
|
2425
2539
|
model: n.model,
|
|
2426
|
-
content: await
|
|
2540
|
+
content: await fetchOneEntry(n)
|
|
2427
2541
|
};
|
|
2428
2542
|
};
|
|
2429
2543
|
export {
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2460
|
-
|
|
2461
|
-
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2544
|
+
getBuilderSearchParams as A,
|
|
2545
|
+
Blocks as B,
|
|
2546
|
+
ContentVariants as C,
|
|
2547
|
+
track as D,
|
|
2548
|
+
fetchBuilderProps as E,
|
|
2549
|
+
RenderBlocks as R,
|
|
2550
|
+
Symbol$1 as S,
|
|
2551
|
+
Text as T,
|
|
2552
|
+
_track as _,
|
|
2553
|
+
getBlockActions as a,
|
|
2554
|
+
getSrcSet as b,
|
|
2555
|
+
isJsScript as c,
|
|
2556
|
+
isBrowser as d,
|
|
2557
|
+
getDefaultCanTrack as e,
|
|
2558
|
+
isPreviewing as f,
|
|
2559
|
+
getBlockProperties as g,
|
|
2560
|
+
evaluate as h,
|
|
2561
|
+
isEditing as i,
|
|
2562
|
+
getInteractionPropertiesForEvent as j,
|
|
2563
|
+
fastClone as k,
|
|
2564
|
+
logger as l,
|
|
2565
|
+
createRegisterComponentMessage as m,
|
|
2566
|
+
fetchOneEntry as n,
|
|
2567
|
+
fetch$1 as o,
|
|
2568
|
+
init as p,
|
|
2569
|
+
RenderContent as q,
|
|
2570
|
+
registerInsertMenu as r,
|
|
2571
|
+
setupBrowserForEditing as s,
|
|
2572
|
+
Columns as t,
|
|
2573
|
+
register as u,
|
|
2574
|
+
setEditorSettings as v,
|
|
2575
|
+
fetchEntries as w,
|
|
2576
|
+
getAllContent as x,
|
|
2577
|
+
getContent as y,
|
|
2578
|
+
_processContentResult as z
|
|
2465
2579
|
};
|