@builder.io/sdk-vue 0.0.2-0 → 0.0.2-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.
Files changed (39) hide show
  1. package/package.json +4 -4
  2. package/packages/_vue2/dist/block-styles.4b780e2e.js +56 -0
  3. package/packages/_vue2/dist/block-styles.d7caff48.cjs +10 -0
  4. package/packages/_vue2/dist/get-processed-block.1b0392ce.js +57 -0
  5. package/packages/_vue2/dist/get-processed-block.a69f90d1.cjs +1 -0
  6. package/packages/_vue2/dist/index.35b10c2f.js +2081 -0
  7. package/packages/_vue2/dist/index.e881a81c.cjs +4 -0
  8. package/packages/_vue2/dist/render-block.3112f40b.js +237 -0
  9. package/packages/_vue2/dist/render-block.37a4bbe9.cjs +3 -0
  10. package/packages/_vue2/dist/render-component.3c148966.cjs +1 -0
  11. package/packages/_vue2/dist/render-component.7c5a2af0.js +38 -0
  12. package/packages/_vue2/dist/render-inlined-styles.c3478295.cjs +1 -0
  13. package/packages/_vue2/dist/render-inlined-styles.f67a4c7d.js +31 -0
  14. package/packages/_vue2/dist/render-repeated-block.006af118.js +50 -0
  15. package/packages/_vue2/dist/render-repeated-block.ea4adce6.cjs +1 -0
  16. package/packages/_vue2/dist/render-styles.90704267.js +70 -0
  17. package/packages/_vue2/dist/render-styles.e6d20f13.cjs +17 -0
  18. package/packages/_vue2/dist/sdk.cjs +1 -0
  19. package/packages/_vue2/dist/sdk.js +27 -0
  20. package/packages/_vue2/dist/style.css +1 -0
  21. package/packages/_vue3/dist/block-styles.13caf8d7.js +53 -0
  22. package/packages/_vue3/dist/block-styles.8cb7f734.cjs +10 -0
  23. package/packages/_vue3/dist/get-processed-block.15d39b53.cjs +1 -0
  24. package/packages/_vue3/dist/get-processed-block.bebdc794.js +57 -0
  25. package/packages/_vue3/dist/index.f58628dd.cjs +4 -0
  26. package/packages/_vue3/dist/index.fa54ce28.js +2054 -0
  27. package/packages/_vue3/dist/render-block.23c16bfb.cjs +3 -0
  28. package/packages/_vue3/dist/render-block.9c550b26.js +253 -0
  29. package/packages/_vue3/dist/render-component.9668419b.js +43 -0
  30. package/packages/_vue3/dist/render-component.c2e224cc.cjs +1 -0
  31. package/packages/_vue3/dist/render-inlined-styles.08569ffb.js +30 -0
  32. package/packages/_vue3/dist/render-inlined-styles.32f5f3bc.cjs +1 -0
  33. package/packages/_vue3/dist/render-repeated-block.73309b84.js +45 -0
  34. package/packages/_vue3/dist/render-repeated-block.8c10514d.cjs +1 -0
  35. package/packages/_vue3/dist/render-styles.22ddc0bf.cjs +17 -0
  36. package/packages/_vue3/dist/render-styles.63eb2def.js +64 -0
  37. package/packages/_vue3/dist/sdk.cjs +1 -0
  38. package/packages/_vue3/dist/sdk.js +28 -0
  39. package/packages/_vue3/dist/style.css +1 -0
@@ -0,0 +1,2081 @@
1
+ const _ = "reactNative";
2
+ function u() {
3
+ return typeof window < "u" && typeof document < "u";
4
+ }
5
+ const k = {};
6
+ function H(t, e) {
7
+ let n = k[t];
8
+ if (n || (n = k[t] = []), n.push(e), u()) {
9
+ const o = {
10
+ type: "builder.register",
11
+ data: {
12
+ type: t,
13
+ info: e
14
+ }
15
+ };
16
+ try {
17
+ parent.postMessage(o, "*"), parent !== window && window.postMessage(o, "*");
18
+ } catch (s) {
19
+ console.debug("Could not postmessage", s);
20
+ }
21
+ }
22
+ }
23
+ const q = () => {
24
+ H("insertMenu", {
25
+ name: "_default",
26
+ default: !0,
27
+ items: [
28
+ { name: "Box" },
29
+ { name: "Text" },
30
+ { name: "Image" },
31
+ { name: "Columns" }
32
+ ]
33
+ });
34
+ }, D = () => {
35
+ var t;
36
+ u() && ((t = window.parent) == null || t.postMessage(
37
+ {
38
+ type: "builder.sdkInfo",
39
+ data: {
40
+ target: _,
41
+ supportsPatchUpdates: !1
42
+ }
43
+ },
44
+ "*"
45
+ ), window.addEventListener("message", ({ data: e }) => {
46
+ var n, o;
47
+ if (e)
48
+ switch (e.type) {
49
+ case "builder.evaluate": {
50
+ const s = e.data.text, r = e.data.arguments || [], a = e.data.id, c = new Function(s);
51
+ let i, l = null;
52
+ try {
53
+ i = c.apply(null, r);
54
+ } catch (d) {
55
+ l = d;
56
+ }
57
+ l ? (n = window.parent) == null || n.postMessage(
58
+ {
59
+ type: "builder.evaluateError",
60
+ data: { id: a, error: l.message }
61
+ },
62
+ "*"
63
+ ) : i && typeof i.then == "function" ? i.then((d) => {
64
+ var h;
65
+ (h = window.parent) == null || h.postMessage(
66
+ {
67
+ type: "builder.evaluateResult",
68
+ data: { id: a, result: d }
69
+ },
70
+ "*"
71
+ );
72
+ }).catch(console.error) : (o = window.parent) == null || o.postMessage(
73
+ {
74
+ type: "builder.evaluateResult",
75
+ data: { result: i, id: a }
76
+ },
77
+ "*"
78
+ );
79
+ break;
80
+ }
81
+ }
82
+ }));
83
+ };
84
+ function y(t) {
85
+ return t;
86
+ }
87
+ function cn(t) {
88
+ return t;
89
+ }
90
+ const K = () => Promise.resolve().then(() => N).then((t) => t.default).catch((t) => {
91
+ throw console.error(
92
+ "Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",
93
+ t
94
+ ), t;
95
+ }), J = {
96
+ name: "builder-columns",
97
+ components: { "render-blocks": K },
98
+ props: [
99
+ "space",
100
+ "columns",
101
+ "stackColumnsAt",
102
+ "reverseColumnsWhenStacked",
103
+ "builderBlock"
104
+ ],
105
+ data: () => ({ markMutable: y }),
106
+ computed: {
107
+ columnsCssVars() {
108
+ const t = this.stackColumnsAt === "never" ? "inherit" : this.reverseColumnsWhenStacked ? "column-reverse" : "column";
109
+ return {
110
+ "--flex-dir": t,
111
+ "--flex-dir-tablet": this.maybeApplyForTablet(t)
112
+ };
113
+ },
114
+ columnCssVars() {
115
+ const t = "100%", e = "0";
116
+ return {
117
+ "--column-width": t,
118
+ "--column-margin-left": e,
119
+ "--column-width-tablet": this.maybeApplyForTablet(t),
120
+ "--column-margin-left-tablet": this.maybeApplyForTablet(e)
121
+ };
122
+ }
123
+ },
124
+ methods: {
125
+ getGutterSize() {
126
+ return typeof this.space == "number" ? this.space || 0 : 20;
127
+ },
128
+ getColumns() {
129
+ return this.columns || [];
130
+ },
131
+ getWidth(t) {
132
+ var n;
133
+ const e = this.getColumns();
134
+ return ((n = e[t]) == null ? void 0 : n.width) || 100 / e.length;
135
+ },
136
+ getColumnCssWidth(t) {
137
+ const e = this.getColumns(), o = this.getGutterSize() * (e.length - 1) / e.length;
138
+ return `calc(${this.getWidth(t)}% - ${o}px)`;
139
+ },
140
+ maybeApplyForTablet(t) {
141
+ return (this.stackColumnsAt || "tablet") === "tablet" ? t : "inherit";
142
+ }
143
+ }
144
+ };
145
+ function p(t, e, n, o, s, r, a, c) {
146
+ var i = typeof t == "function" ? t.options : t;
147
+ e && (i.render = e, i.staticRenderFns = n, i._compiled = !0), o && (i.functional = !0), r && (i._scopeId = "data-v-" + r);
148
+ var l;
149
+ if (a ? (l = function(m) {
150
+ m = m || this.$vnode && this.$vnode.ssrContext || this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext, !m && typeof __VUE_SSR_CONTEXT__ < "u" && (m = __VUE_SSR_CONTEXT__), s && s.call(this, m), m && m._registeredComponents && m._registeredComponents.add(a);
151
+ }, i._ssrRegister = l) : s && (l = c ? function() {
152
+ s.call(
153
+ this,
154
+ (i.functional ? this.parent : this).$root.$options.shadowRoot
155
+ );
156
+ } : s), l)
157
+ if (i.functional) {
158
+ i._injectStyles = l;
159
+ var d = i.render;
160
+ i.render = function(z, C) {
161
+ return l.call(C), d(z, C);
162
+ };
163
+ } else {
164
+ var h = i.beforeCreate;
165
+ i.beforeCreate = h ? [].concat(h, l) : [l];
166
+ }
167
+ return {
168
+ exports: t,
169
+ options: i
170
+ };
171
+ }
172
+ var G = function() {
173
+ var e = this, n = e._self._c;
174
+ return n("div", { staticClass: "builder-columns div-2fnk003dqad", style: e.columnsCssVars }, e._l(e.columns, function(o, s) {
175
+ return n("div", { key: s, staticClass: "builder-column div-2fnk003dqad-2", style: {
176
+ width: e.getColumnCssWidth(s),
177
+ marginLeft: `${s === 0 ? 0 : e.getGutterSize()}px`,
178
+ ...e.columnCssVars
179
+ } }, [n("render-blocks", { attrs: { blocks: e.markMutable(o.blocks), path: `component.options.columns.${s}.blocks`, parent: e.builderBlock.id } })], 1);
180
+ }), 0);
181
+ }, X = [], Y = /* @__PURE__ */ p(
182
+ J,
183
+ G,
184
+ X,
185
+ !1,
186
+ null,
187
+ "d3bc5674",
188
+ null,
189
+ null
190
+ );
191
+ const Q = Y.exports;
192
+ function w(t) {
193
+ return t.replace(/http(s)?:/, "");
194
+ }
195
+ function Z(t = "", e, n) {
196
+ const o = new RegExp("([?&])" + e + "=.*?(&|$)", "i"), s = t.indexOf("?") !== -1 ? "&" : "?";
197
+ return t.match(o) ? t.replace(o, "$1" + e + "=" + encodeURIComponent(n) + "$2") : t + s + e + "=" + encodeURIComponent(n);
198
+ }
199
+ function ee(t, e) {
200
+ if (!t || !(t != null && t.match(/cdn\.shopify\.com/)) || !e)
201
+ return t;
202
+ if (e === "master")
203
+ return w(t);
204
+ const n = t.match(
205
+ /(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i
206
+ );
207
+ if (n) {
208
+ const o = t.split(n[0]), s = n[3], r = e.match("x") ? e : `${e}x`;
209
+ return w(`${o[0]}_${r}${s}`);
210
+ }
211
+ return null;
212
+ }
213
+ function b(t) {
214
+ if (!t)
215
+ return t;
216
+ const e = [100, 200, 400, 800, 1200, 1600, 2e3];
217
+ if (t.match(/builder\.io/)) {
218
+ let n = t;
219
+ const o = Number(t.split("?width=")[1]);
220
+ return isNaN(o) || (n = `${n} ${o}w`), e.filter((s) => s !== o).map((s) => `${Z(t, "width", s)} ${s}w`).concat([n]).join(", ");
221
+ }
222
+ return t.match(/cdn\.shopify\.com/) ? e.map((n) => [ee(t, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, o]) => `${n} ${o}w`).concat([t]).join(", ") : t;
223
+ }
224
+ const te = {
225
+ name: "builder-image",
226
+ props: [
227
+ "image",
228
+ "src",
229
+ "srcset",
230
+ "noWebp",
231
+ "altText",
232
+ "backgroundSize",
233
+ "className",
234
+ "sizes",
235
+ "aspectRatio",
236
+ "fitContent",
237
+ "builderBlock"
238
+ ],
239
+ computed: {
240
+ srcSetToUse() {
241
+ var n;
242
+ const e = this.image || this.src;
243
+ if (!e || !(e.match(/builder\.io/) || e.match(/cdn\.shopify\.com/)))
244
+ return this.srcset;
245
+ if (this.srcset && ((n = this.image) == null ? void 0 : n.includes("builder.io/api/v1/image"))) {
246
+ if (!this.srcset.includes(this.image.split("?")[0]))
247
+ return console.debug("Removed given srcset"), b(e);
248
+ } else if (this.image && !this.srcset)
249
+ return b(e);
250
+ return b(e);
251
+ },
252
+ webpSrcSet() {
253
+ var t;
254
+ return ((t = this.srcSetToUse) == null ? void 0 : t.match(/builder\.io/)) && !this.noWebp ? this.srcSetToUse.replace(/\?/g, "?format=webp&") : "";
255
+ }
256
+ },
257
+ methods: {
258
+ _classStringToObject(t) {
259
+ const e = {};
260
+ if (typeof t != "string")
261
+ return e;
262
+ const n = t.trim().split(/\s+/);
263
+ for (const o of n)
264
+ e[o] = !0;
265
+ return e;
266
+ }
267
+ }
268
+ };
269
+ var ne = function() {
270
+ var o, s, r, a;
271
+ var e = this, n = e._self._c;
272
+ return n("div", { staticClass: "div-1pl23ac79ld" }, [n("picture", [e.webpSrcSet ? [n("source", { attrs: { type: "image/webp", srcset: e.webpSrcSet } })] : e._e(), n("img", { class: e._classStringToObject(
273
+ "builder-image" + (e.className ? " " + e.className : "") + " img-1pl23ac79ld"
274
+ ), style: {
275
+ objectPosition: e.backgroundSize || "center",
276
+ objectFit: e.backgroundSize || "cover"
277
+ }, attrs: { loading: "lazy", alt: e.altText, role: e.altText ? "presentation" : void 0, src: e.image, srcset: e.srcSetToUse, sizes: e.sizes } }), n("source", { attrs: { srcset: e.srcSetToUse } })], 2), e.aspectRatio && !(e.fitContent && ((s = (o = e.builderBlock) == null ? void 0 : o.children) == null ? void 0 : s.length)) ? [n("div", { staticClass: "builder-image-sizer div-1pl23ac79ld-2", style: {
278
+ paddingTop: e.aspectRatio * 100 + "%"
279
+ } })] : e._e(), ((a = (r = e.builderBlock) == null ? void 0 : r.children) == null ? void 0 : a.length) && e.fitContent ? [e._t("default")] : e._e(), e.fitContent ? e._e() : [n("div", { staticClass: "div-1pl23ac79ld-3" }, [e._t("default")], 2)]], 2);
280
+ }, oe = [], se = /* @__PURE__ */ p(
281
+ te,
282
+ ne,
283
+ oe,
284
+ !1,
285
+ null,
286
+ "6a74cb4f",
287
+ null,
288
+ null
289
+ );
290
+ const re = se.exports, ae = {
291
+ name: "builder-text",
292
+ props: ["text"]
293
+ };
294
+ var ie = function() {
295
+ var e = this, n = e._self._c;
296
+ return n("span", { staticClass: "builder-text", domProps: { innerHTML: e._s(e.text) } });
297
+ }, ce = [], le = /* @__PURE__ */ p(
298
+ ae,
299
+ ie,
300
+ ce,
301
+ !1,
302
+ null,
303
+ null,
304
+ null,
305
+ null
306
+ );
307
+ const de = le.exports, ue = {
308
+ name: "builder-video",
309
+ props: [
310
+ "autoPlay",
311
+ "muted",
312
+ "controls",
313
+ "loop",
314
+ "playsInline",
315
+ "attributes",
316
+ "fit",
317
+ "position",
318
+ "video",
319
+ "posterImage"
320
+ ],
321
+ computed: {
322
+ videoProps() {
323
+ return {
324
+ ...this.autoPlay === !0 ? {
325
+ autoPlay: !0
326
+ } : {},
327
+ ...this.muted === !0 ? {
328
+ muted: !0
329
+ } : {},
330
+ ...this.controls === !0 ? {
331
+ controls: !0
332
+ } : {},
333
+ ...this.loop === !0 ? {
334
+ loop: !0
335
+ } : {},
336
+ ...this.playsInline === !0 ? {
337
+ playsInline: !0
338
+ } : {}
339
+ };
340
+ }
341
+ }
342
+ };
343
+ var pe = function() {
344
+ var o;
345
+ var e = this, n = e._self._c;
346
+ return n("video", e._b({ style: {
347
+ width: "100%",
348
+ height: "100%",
349
+ ...(o = e.attributes) == null ? void 0 : o.style,
350
+ objectFit: e.fit,
351
+ objectPosition: e.position,
352
+ borderRadius: 1
353
+ }, attrs: { src: e.video || "no-src", poster: e.posterImage } }, "video", e.videoProps, !1));
354
+ }, me = [], he = /* @__PURE__ */ p(
355
+ ue,
356
+ pe,
357
+ me,
358
+ !1,
359
+ null,
360
+ null,
361
+ null,
362
+ null
363
+ );
364
+ const fe = he.exports;
365
+ function v(t, e = null, n = ".") {
366
+ return Object.keys(t).reduce((o, s) => {
367
+ const r = t[s], a = [e, s].filter(Boolean).join(n);
368
+ return [
369
+ typeof r == "object",
370
+ r !== null,
371
+ !(Array.isArray(r) && r.length === 0)
372
+ ].every(Boolean) ? { ...o, ...v(r, a, n) } : { ...o, [a]: r };
373
+ }, {});
374
+ }
375
+ const S = "builder.", ge = (t) => {
376
+ const e = {};
377
+ return t.forEach((n, o) => {
378
+ e[o] = n;
379
+ }), e;
380
+ }, be = (t) => {
381
+ if (!t)
382
+ return {};
383
+ const e = F(t), n = {};
384
+ return Object.keys(e).forEach((o) => {
385
+ if (o.startsWith(S)) {
386
+ const s = o.replace(S, "");
387
+ n[s] = e[o];
388
+ }
389
+ }), n;
390
+ }, ve = () => {
391
+ if (!u())
392
+ return {};
393
+ const t = new URLSearchParams(window.location.search);
394
+ return be(t);
395
+ }, F = (t) => t instanceof URLSearchParams ? ge(t) : t;
396
+ function _e() {
397
+ return typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : null;
398
+ }
399
+ async function E() {
400
+ const t = _e().fetch;
401
+ if (typeof t > "u" && typeof global < "u") {
402
+ const e = import("node-fetch").then((n) => n.default);
403
+ return e.default || e;
404
+ }
405
+ return t.default || t;
406
+ }
407
+ const ye = (t) => {
408
+ const e = t.split(".");
409
+ return e.length > 2 ? e.slice(1).join(".") : t;
410
+ }, j = async ({
411
+ name: t,
412
+ canTrack: e
413
+ }) => {
414
+ var n;
415
+ try {
416
+ return e ? (n = document.cookie.split("; ").find((o) => o.startsWith(`${t}=`))) == null ? void 0 : n.split("=")[1] : void 0;
417
+ } catch (o) {
418
+ console.debug("[COOKIE] GET error: ", o);
419
+ }
420
+ }, xe = (t) => t.map(([e, n]) => n ? `${e}=${n}` : e).join("; "), Ce = [
421
+ ["secure", ""],
422
+ ["SameSite", "None"]
423
+ ], ke = ({
424
+ name: t,
425
+ value: e,
426
+ expires: n
427
+ }) => {
428
+ const s = (u() ? location.protocol === "https:" : !0) ? Ce : [[]], r = n ? [["expires", n.toUTCString()]] : [[]], a = [
429
+ [t, e],
430
+ ...r,
431
+ ["path", "/"],
432
+ ["domain", ye(window.location.hostname)],
433
+ ...s
434
+ ];
435
+ return xe(a);
436
+ }, U = async ({
437
+ name: t,
438
+ value: e,
439
+ expires: n,
440
+ canTrack: o
441
+ }) => {
442
+ try {
443
+ if (!o)
444
+ return;
445
+ const s = ke({ name: t, value: e, expires: n });
446
+ document.cookie = s;
447
+ } catch (s) {
448
+ console.warn("[COOKIE] SET error: ", s);
449
+ }
450
+ }, we = "builderio.variations", V = (t) => `${we}.${t}`, Se = ({
451
+ contentId: t,
452
+ canTrack: e
453
+ }) => j({ name: V(t), canTrack: e }), Ie = ({
454
+ contentId: t,
455
+ canTrack: e,
456
+ value: n
457
+ }) => U({ name: V(t), value: n, canTrack: e }), g = (t) => t != null, Te = (t) => g(t.id) && g(t.variations) && Object.keys(t.variations).length > 0, Re = ({
458
+ id: t,
459
+ variations: e
460
+ }) => {
461
+ var s;
462
+ let n = 0;
463
+ const o = Math.random();
464
+ for (const r in e)
465
+ if (n += (s = e[r]) == null ? void 0 : s.testRatio, o < n)
466
+ return r;
467
+ return t;
468
+ }, I = ({
469
+ item: t,
470
+ testGroupId: e
471
+ }) => {
472
+ const n = t.variations[e];
473
+ return e === t.id || !n ? {
474
+ testVariationId: t.id,
475
+ testVariationName: "Default"
476
+ } : {
477
+ data: n.data,
478
+ testVariationId: n.id,
479
+ testVariationName: n.name || (n.id === t.id ? "Default" : "")
480
+ };
481
+ }, $e = async ({
482
+ item: t,
483
+ canTrack: e
484
+ }) => {
485
+ const n = await Se({
486
+ canTrack: e,
487
+ contentId: t.id
488
+ }), o = n ? I({ item: t, testGroupId: n }) : void 0;
489
+ if (o)
490
+ return o;
491
+ {
492
+ const s = Re({
493
+ variations: t.variations,
494
+ id: t.id
495
+ });
496
+ return Ie({
497
+ contentId: t.id,
498
+ value: s,
499
+ canTrack: e
500
+ }).catch((r) => {
501
+ console.error("could not store A/B test variation: ", r);
502
+ }), I({ item: t, testGroupId: s });
503
+ }
504
+ }, Fe = async ({
505
+ item: t,
506
+ canTrack: e
507
+ }) => {
508
+ if (!Te(t))
509
+ return;
510
+ const n = await $e({ item: t, canTrack: e });
511
+ Object.assign(t, n);
512
+ };
513
+ async function A(t) {
514
+ return (await je({ ...t, limit: 1 })).results[0] || null;
515
+ }
516
+ const Ee = (t) => {
517
+ const {
518
+ limit: e = 30,
519
+ userAttributes: n,
520
+ query: o,
521
+ noTraverse: s = !1,
522
+ model: r,
523
+ apiKey: a
524
+ } = t, c = new URL(
525
+ `https://cdn.builder.io/api/v2/content/${r}?apiKey=${a}&limit=${e}&noTraverse=${s}`
526
+ ), i = {
527
+ ...ve(),
528
+ ...F(t.options || {})
529
+ }, l = v(i);
530
+ for (const d in l)
531
+ c.searchParams.set(d, String(l[d]));
532
+ if (n && c.searchParams.set("userAttributes", JSON.stringify(n)), o) {
533
+ const d = v({ query: o });
534
+ for (const h in d)
535
+ c.searchParams.set(h, JSON.stringify(d[h]));
536
+ }
537
+ return c;
538
+ };
539
+ async function je(t) {
540
+ const e = Ee(t), o = await (await E())(e.href).then(
541
+ (r) => r.json()
542
+ ), s = t.canTrack !== !1;
543
+ if (s)
544
+ for (const r of o.results)
545
+ await Fe({ item: r, canTrack: s });
546
+ return o;
547
+ }
548
+ const Ue = () => Promise.resolve().then(() => Zt).then((t) => t.default).catch((t) => {
549
+ throw console.error(
550
+ "Error while attempting to dynamically import component RenderContent at ../../components/render-content/render-content.vue",
551
+ t
552
+ ), t;
553
+ }), Ve = {
554
+ name: "builder-symbol",
555
+ components: { "render-content": Ue },
556
+ props: ["symbol", "attributes"],
557
+ data: () => ({ className: "builder-symbol", content: null, markMutable: y }),
558
+ inject: {
559
+ builderContext: "BuilderContext"
560
+ },
561
+ mounted() {
562
+ var t;
563
+ this.content = (t = this.symbol) == null ? void 0 : t.content;
564
+ },
565
+ watch: {
566
+ onUpdateHook0() {
567
+ const t = this.symbol;
568
+ t && !t.content && !this.content && t.model && A({
569
+ model: t.model,
570
+ apiKey: this.builderContext.apiKey,
571
+ query: {
572
+ id: t.entry
573
+ }
574
+ }).then((e) => {
575
+ this.content = e;
576
+ });
577
+ }
578
+ },
579
+ computed: {
580
+ onUpdateHook0() {
581
+ return {
582
+ 0: this.symbol,
583
+ 1: this.content
584
+ };
585
+ }
586
+ },
587
+ methods: {
588
+ _classStringToObject(t) {
589
+ const e = {};
590
+ if (typeof t != "string")
591
+ return e;
592
+ const n = t.trim().split(/\s+/);
593
+ for (const o of n)
594
+ e[o] = !0;
595
+ return e;
596
+ }
597
+ }
598
+ };
599
+ var Ae = function() {
600
+ var o, s, r, a, c;
601
+ var e = this, n = e._self._c;
602
+ return n("div", e._b({ class: e._classStringToObject(e.className), attrs: { dataSet: {
603
+ class: e.className
604
+ } } }, "div", e.attributes, !1), [n("render-content", { attrs: { apiKey: e.builderContext.apiKey, context: e.builderContext.context, customComponents: e.markMutable(Object.values(e.builderContext.registeredComponents)), data: e.markMutable({
605
+ ...(o = e.symbol) == null ? void 0 : o.data,
606
+ ...e.builderContext.state,
607
+ ...(a = (r = (s = e.symbol) == null ? void 0 : s.content) == null ? void 0 : r.data) == null ? void 0 : a.state
608
+ }), model: (c = e.symbol) == null ? void 0 : c.model, content: e.markMutable(e.content) } })], 1);
609
+ }, Oe = [], Pe = /* @__PURE__ */ p(
610
+ Ve,
611
+ Ae,
612
+ Oe,
613
+ !1,
614
+ null,
615
+ null,
616
+ null,
617
+ null
618
+ );
619
+ const We = Pe.exports, Be = {
620
+ name: "builder-button",
621
+ props: ["attributes", "text", "link", "openLinkInNewTab"]
622
+ };
623
+ var Le = function() {
624
+ var e = this, n = e._self._c;
625
+ return e.link ? n("a", e._b({ attrs: { role: "button", href: e.link, target: e.openLinkInNewTab ? "_blank" : void 0 } }, "a", e.attributes, !1), [e._v(" " + e._s(e.text) + " ")]) : n("button", e._b({ staticClass: "button-16nol0lwi20" }, "button", e.attributes, !1), [e._v(" " + e._s(e.text) + " ")]);
626
+ }, Me = [], Ne = /* @__PURE__ */ p(
627
+ Be,
628
+ Le,
629
+ Me,
630
+ !1,
631
+ null,
632
+ "844ae72b",
633
+ null,
634
+ null
635
+ );
636
+ const ze = Ne.exports, He = {
637
+ name: "builder-section-component",
638
+ props: ["attributes", "maxWidth"]
639
+ };
640
+ var qe = function() {
641
+ var e = this, n = e._self._c;
642
+ return n("section", e._b({ style: e.maxWidth && typeof e.maxWidth == "number" ? {
643
+ maxWidth: e.maxWidth
644
+ } : void 0 }, "section", e.attributes, !1), [e._t("default")], 2);
645
+ }, De = [], Ke = /* @__PURE__ */ p(
646
+ He,
647
+ qe,
648
+ De,
649
+ !1,
650
+ null,
651
+ null,
652
+ null,
653
+ null
654
+ );
655
+ const Je = Ke.exports, Ge = {
656
+ name: "builder-fragment-component",
657
+ props: []
658
+ };
659
+ var Xe = function() {
660
+ var e = this, n = e._self._c;
661
+ return n("span", [e._t("default")], 2);
662
+ }, Ye = [], Qe = /* @__PURE__ */ p(
663
+ Ge,
664
+ Xe,
665
+ Ye,
666
+ !1,
667
+ null,
668
+ null,
669
+ null,
670
+ null
671
+ );
672
+ const Ze = Qe.exports, et = {
673
+ name: "Core:Button",
674
+ builtIn: !0,
675
+ image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
676
+ defaultStyles: {
677
+ appearance: "none",
678
+ paddingTop: "15px",
679
+ paddingBottom: "15px",
680
+ paddingLeft: "25px",
681
+ paddingRight: "25px",
682
+ backgroundColor: "#000000",
683
+ color: "white",
684
+ borderRadius: "4px",
685
+ textAlign: "center",
686
+ cursor: "pointer"
687
+ },
688
+ inputs: [
689
+ {
690
+ name: "text",
691
+ type: "text",
692
+ defaultValue: "Click me!",
693
+ bubble: !0
694
+ },
695
+ {
696
+ name: "link",
697
+ type: "url",
698
+ bubble: !0
699
+ },
700
+ {
701
+ name: "openLinkInNewTab",
702
+ type: "boolean",
703
+ defaultValue: !1,
704
+ friendlyName: "Open link in new tab"
705
+ }
706
+ ],
707
+ static: !0,
708
+ noWrap: !0
709
+ };
710
+ function x(t) {
711
+ return t.__qwik_serializable__ = !0, t;
712
+ }
713
+ const tt = {
714
+ name: "Columns",
715
+ builtIn: !0,
716
+ inputs: [
717
+ {
718
+ name: "columns",
719
+ type: "array",
720
+ broadcast: !0,
721
+ subFields: [
722
+ {
723
+ name: "blocks",
724
+ type: "array",
725
+ hideFromUI: !0,
726
+ defaultValue: [
727
+ {
728
+ "@type": "@builder.io/sdk:Element",
729
+ responsiveStyles: {
730
+ large: {
731
+ display: "flex",
732
+ flexDirection: "column",
733
+ alignItems: "stretch",
734
+ flexShrink: "0",
735
+ position: "relative",
736
+ marginTop: "30px",
737
+ textAlign: "center",
738
+ lineHeight: "normal",
739
+ height: "auto",
740
+ minHeight: "20px",
741
+ minWidth: "20px",
742
+ overflow: "hidden"
743
+ }
744
+ },
745
+ component: {
746
+ name: "Image",
747
+ options: {
748
+ image: "https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",
749
+ backgroundPosition: "center",
750
+ backgroundSize: "cover",
751
+ aspectRatio: 0.7004048582995948
752
+ }
753
+ }
754
+ },
755
+ {
756
+ "@type": "@builder.io/sdk:Element",
757
+ responsiveStyles: {
758
+ large: {
759
+ display: "flex",
760
+ flexDirection: "column",
761
+ alignItems: "stretch",
762
+ flexShrink: "0",
763
+ position: "relative",
764
+ marginTop: "30px",
765
+ textAlign: "center",
766
+ lineHeight: "normal",
767
+ height: "auto"
768
+ }
769
+ },
770
+ component: {
771
+ name: "Text",
772
+ options: {
773
+ text: "<p>Enter some text...</p>"
774
+ }
775
+ }
776
+ }
777
+ ]
778
+ },
779
+ {
780
+ name: "width",
781
+ type: "number",
782
+ hideFromUI: !0,
783
+ helperText: "Width %, e.g. set to 50 to fill half of the space"
784
+ },
785
+ {
786
+ name: "link",
787
+ type: "url",
788
+ helperText: "Optionally set a url that clicking this column will link to"
789
+ }
790
+ ],
791
+ defaultValue: [
792
+ {
793
+ blocks: [
794
+ {
795
+ "@type": "@builder.io/sdk:Element",
796
+ responsiveStyles: {
797
+ large: {
798
+ display: "flex",
799
+ flexDirection: "column",
800
+ alignItems: "stretch",
801
+ flexShrink: "0",
802
+ position: "relative",
803
+ marginTop: "30px",
804
+ textAlign: "center",
805
+ lineHeight: "normal",
806
+ height: "auto",
807
+ minHeight: "20px",
808
+ minWidth: "20px",
809
+ overflow: "hidden"
810
+ }
811
+ },
812
+ component: {
813
+ name: "Image",
814
+ options: {
815
+ image: "https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",
816
+ backgroundPosition: "center",
817
+ backgroundSize: "cover",
818
+ aspectRatio: 0.7004048582995948
819
+ }
820
+ }
821
+ },
822
+ {
823
+ "@type": "@builder.io/sdk:Element",
824
+ responsiveStyles: {
825
+ large: {
826
+ display: "flex",
827
+ flexDirection: "column",
828
+ alignItems: "stretch",
829
+ flexShrink: "0",
830
+ position: "relative",
831
+ marginTop: "30px",
832
+ textAlign: "center",
833
+ lineHeight: "normal",
834
+ height: "auto"
835
+ }
836
+ },
837
+ component: {
838
+ name: "Text",
839
+ options: {
840
+ text: "<p>Enter some text...</p>"
841
+ }
842
+ }
843
+ }
844
+ ]
845
+ },
846
+ {
847
+ blocks: [
848
+ {
849
+ "@type": "@builder.io/sdk:Element",
850
+ responsiveStyles: {
851
+ large: {
852
+ display: "flex",
853
+ flexDirection: "column",
854
+ alignItems: "stretch",
855
+ flexShrink: "0",
856
+ position: "relative",
857
+ marginTop: "30px",
858
+ textAlign: "center",
859
+ lineHeight: "normal",
860
+ height: "auto",
861
+ minHeight: "20px",
862
+ minWidth: "20px",
863
+ overflow: "hidden"
864
+ }
865
+ },
866
+ component: {
867
+ name: "Image",
868
+ options: {
869
+ image: "https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",
870
+ backgroundPosition: "center",
871
+ backgroundSize: "cover",
872
+ aspectRatio: 0.7004048582995948
873
+ }
874
+ }
875
+ },
876
+ {
877
+ "@type": "@builder.io/sdk:Element",
878
+ responsiveStyles: {
879
+ large: {
880
+ display: "flex",
881
+ flexDirection: "column",
882
+ alignItems: "stretch",
883
+ flexShrink: "0",
884
+ position: "relative",
885
+ marginTop: "30px",
886
+ textAlign: "center",
887
+ lineHeight: "normal",
888
+ height: "auto"
889
+ }
890
+ },
891
+ component: {
892
+ name: "Text",
893
+ options: {
894
+ text: "<p>Enter some text...</p>"
895
+ }
896
+ }
897
+ }
898
+ ]
899
+ }
900
+ ],
901
+ onChange: x((t) => {
902
+ function e() {
903
+ n.forEach((o) => {
904
+ o.delete("width");
905
+ });
906
+ }
907
+ const n = t.get("columns");
908
+ Array.isArray(n) && !!n.find(
909
+ (s) => s.get("width")
910
+ ) && (!!n.find(
911
+ (r) => !r.get("width")
912
+ ) || n.reduce((c, i) => c + i.get("width"), 0) !== 100) && e();
913
+ })
914
+ },
915
+ {
916
+ name: "space",
917
+ type: "number",
918
+ defaultValue: 20,
919
+ helperText: "Size of gap between columns",
920
+ advanced: !0
921
+ },
922
+ {
923
+ name: "stackColumnsAt",
924
+ type: "string",
925
+ defaultValue: "tablet",
926
+ helperText: "Convert horizontal columns to vertical at what device size",
927
+ enum: ["tablet", "mobile", "never"],
928
+ advanced: !0
929
+ },
930
+ {
931
+ name: "reverseColumnsWhenStacked",
932
+ type: "boolean",
933
+ defaultValue: !1,
934
+ helperText: "When stacking columns for mobile devices, reverse the ordering",
935
+ advanced: !0
936
+ }
937
+ ]
938
+ }, nt = {
939
+ name: "Fragment",
940
+ static: !0,
941
+ hidden: !0,
942
+ builtIn: !0,
943
+ canHaveChildren: !0,
944
+ noWrap: !0
945
+ }, ot = {
946
+ name: "Image",
947
+ static: !0,
948
+ builtIn: !0,
949
+ 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",
950
+ defaultStyles: {
951
+ position: "relative",
952
+ minHeight: "20px",
953
+ minWidth: "20px",
954
+ overflow: "hidden"
955
+ },
956
+ canHaveChildren: !0,
957
+ inputs: [
958
+ {
959
+ name: "image",
960
+ type: "file",
961
+ bubble: !0,
962
+ allowedFileTypes: ["jpeg", "jpg", "png", "svg"],
963
+ required: !0,
964
+ defaultValue: "https://cdn.builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",
965
+ onChange: x((t) => {
966
+ t.delete("srcset"), t.delete("noWebp");
967
+ function n(a, c = 6e4) {
968
+ return new Promise((i, l) => {
969
+ const d = document.createElement("img");
970
+ let h = !1;
971
+ d.onload = () => {
972
+ h = !0, i(d);
973
+ }, d.addEventListener("error", (m) => {
974
+ console.warn("Image load failed", m.error), l(m.error);
975
+ }), d.src = a, setTimeout(() => {
976
+ h || l(new Error("Image load timed out"));
977
+ }, c);
978
+ });
979
+ }
980
+ function o(a) {
981
+ return Math.round(a * 1e3) / 1e3;
982
+ }
983
+ const s = t.get("image"), r = t.get("aspectRatio");
984
+ if (fetch(s).then((a) => a.blob()).then((a) => {
985
+ a.type.includes("svg") && t.set("noWebp", !0);
986
+ }), s && (!r || r === 0.7041))
987
+ return n(s).then((a) => {
988
+ const c = t.get("aspectRatio");
989
+ t.get("image") === s && (!c || c === 0.7041) && a.width && a.height && (t.set("aspectRatio", o(a.height / a.width)), t.set("height", a.height), t.set("width", a.width));
990
+ });
991
+ })
992
+ },
993
+ {
994
+ name: "backgroundSize",
995
+ type: "text",
996
+ defaultValue: "cover",
997
+ enum: [
998
+ {
999
+ label: "contain",
1000
+ value: "contain",
1001
+ helperText: "The image should never get cropped"
1002
+ },
1003
+ {
1004
+ label: "cover",
1005
+ value: "cover",
1006
+ helperText: "The image should fill it's box, cropping when needed"
1007
+ }
1008
+ ]
1009
+ },
1010
+ {
1011
+ name: "backgroundPosition",
1012
+ type: "text",
1013
+ defaultValue: "center",
1014
+ enum: [
1015
+ "center",
1016
+ "top",
1017
+ "left",
1018
+ "right",
1019
+ "bottom",
1020
+ "top left",
1021
+ "top right",
1022
+ "bottom left",
1023
+ "bottom right"
1024
+ ]
1025
+ },
1026
+ {
1027
+ name: "altText",
1028
+ type: "string",
1029
+ helperText: "Text to display when the user has images off"
1030
+ },
1031
+ {
1032
+ name: "height",
1033
+ type: "number",
1034
+ hideFromUI: !0
1035
+ },
1036
+ {
1037
+ name: "width",
1038
+ type: "number",
1039
+ hideFromUI: !0
1040
+ },
1041
+ {
1042
+ name: "sizes",
1043
+ type: "string",
1044
+ hideFromUI: !0
1045
+ },
1046
+ {
1047
+ name: "srcset",
1048
+ type: "string",
1049
+ hideFromUI: !0
1050
+ },
1051
+ {
1052
+ name: "lazy",
1053
+ type: "boolean",
1054
+ defaultValue: !0,
1055
+ hideFromUI: !0
1056
+ },
1057
+ {
1058
+ name: "fitContent",
1059
+ type: "boolean",
1060
+ helperText: "When child blocks are provided, fit to them instead of using the image's aspect ratio",
1061
+ defaultValue: !0
1062
+ },
1063
+ {
1064
+ name: "aspectRatio",
1065
+ type: "number",
1066
+ helperText: "This is the ratio of height/width, e.g. set to 1.5 for a 300px wide and 200px tall photo. Set to 0 to not force the image to maintain it's aspect ratio",
1067
+ advanced: !0,
1068
+ defaultValue: 0.7041
1069
+ }
1070
+ ]
1071
+ }, st = {
1072
+ name: "Core:Section",
1073
+ static: !0,
1074
+ builtIn: !0,
1075
+ image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
1076
+ inputs: [
1077
+ {
1078
+ name: "maxWidth",
1079
+ type: "number",
1080
+ defaultValue: 1200
1081
+ },
1082
+ {
1083
+ name: "lazyLoad",
1084
+ type: "boolean",
1085
+ defaultValue: !1,
1086
+ advanced: !0,
1087
+ description: "Only render this section when in view"
1088
+ }
1089
+ ],
1090
+ defaultStyles: {
1091
+ paddingLeft: "20px",
1092
+ paddingRight: "20px",
1093
+ paddingTop: "50px",
1094
+ paddingBottom: "50px",
1095
+ marginTop: "0px",
1096
+ width: "100vw",
1097
+ marginLeft: "calc(50% - 50vw)"
1098
+ },
1099
+ canHaveChildren: !0,
1100
+ defaultChildren: [
1101
+ {
1102
+ "@type": "@builder.io/sdk:Element",
1103
+ responsiveStyles: {
1104
+ large: {
1105
+ textAlign: "center"
1106
+ }
1107
+ },
1108
+ component: {
1109
+ name: "Text",
1110
+ options: {
1111
+ text: "<p><b>I am a section! My content keeps from getting too wide, so that it's easy to read even on big screens.</b></p><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur</p>"
1112
+ }
1113
+ }
1114
+ }
1115
+ ]
1116
+ }, rt = {
1117
+ name: "Symbol",
1118
+ noWrap: !0,
1119
+ static: !0,
1120
+ builtIn: !0,
1121
+ inputs: [
1122
+ {
1123
+ name: "symbol",
1124
+ type: "uiSymbol"
1125
+ },
1126
+ {
1127
+ name: "dataOnly",
1128
+ helperText: "Make this a data symbol that doesn't display any UI",
1129
+ type: "boolean",
1130
+ defaultValue: !1,
1131
+ advanced: !0,
1132
+ hideFromUI: !0
1133
+ },
1134
+ {
1135
+ name: "inheritState",
1136
+ helperText: "Inherit the parent component state and data",
1137
+ type: "boolean",
1138
+ defaultValue: !1,
1139
+ advanced: !0
1140
+ },
1141
+ {
1142
+ name: "renderToLiquid",
1143
+ helperText: "Render this symbols contents to liquid. Turn off to fetch with javascript and use custom targeting",
1144
+ type: "boolean",
1145
+ defaultValue: !1,
1146
+ advanced: !0,
1147
+ hideFromUI: !0
1148
+ },
1149
+ {
1150
+ name: "useChildren",
1151
+ hideFromUI: !0,
1152
+ type: "boolean"
1153
+ }
1154
+ ]
1155
+ }, at = {
1156
+ name: "Text",
1157
+ static: !0,
1158
+ builtIn: !0,
1159
+ image: "https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-text_fields-24px%20(1).svg?alt=media&token=12177b73-0ee3-42ca-98c6-0dd003de1929",
1160
+ inputs: [
1161
+ {
1162
+ name: "text",
1163
+ type: "html",
1164
+ required: !0,
1165
+ autoFocus: !0,
1166
+ bubble: !0,
1167
+ defaultValue: "Enter some text..."
1168
+ }
1169
+ ],
1170
+ defaultStyles: {
1171
+ lineHeight: "normal",
1172
+ height: "auto",
1173
+ textAlign: "center"
1174
+ }
1175
+ }, it = {
1176
+ name: "Video",
1177
+ canHaveChildren: !0,
1178
+ builtIn: !0,
1179
+ defaultStyles: {
1180
+ minHeight: "20px",
1181
+ minWidth: "20px"
1182
+ },
1183
+ image: "https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-videocam-24px%20(1).svg?alt=media&token=49a84e4a-b20e-4977-a650-047f986874bb",
1184
+ inputs: [
1185
+ {
1186
+ name: "video",
1187
+ type: "file",
1188
+ allowedFileTypes: ["mp4"],
1189
+ bubble: !0,
1190
+ defaultValue: "https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/assets%2FKQlEmWDxA0coC3PK6UvkrjwkIGI2%2F28cb070609f546cdbe5efa20e931aa4b?alt=media&token=912e9551-7a7c-4dfb-86b6-3da1537d1a7f",
1191
+ required: !0
1192
+ },
1193
+ {
1194
+ name: "posterImage",
1195
+ type: "file",
1196
+ allowedFileTypes: ["jpeg", "png"],
1197
+ helperText: "Image to show before the video plays"
1198
+ },
1199
+ {
1200
+ name: "autoPlay",
1201
+ type: "boolean",
1202
+ defaultValue: !0
1203
+ },
1204
+ {
1205
+ name: "controls",
1206
+ type: "boolean",
1207
+ defaultValue: !1
1208
+ },
1209
+ {
1210
+ name: "muted",
1211
+ type: "boolean",
1212
+ defaultValue: !0
1213
+ },
1214
+ {
1215
+ name: "loop",
1216
+ type: "boolean",
1217
+ defaultValue: !0
1218
+ },
1219
+ {
1220
+ name: "playsInline",
1221
+ type: "boolean",
1222
+ defaultValue: !0
1223
+ },
1224
+ {
1225
+ name: "fit",
1226
+ type: "text",
1227
+ defaultValue: "cover",
1228
+ enum: ["contain", "cover", "fill", "auto"]
1229
+ },
1230
+ {
1231
+ name: "fitContent",
1232
+ type: "boolean",
1233
+ helperText: "When child blocks are provided, fit to them instead of using the aspect ratio",
1234
+ defaultValue: !0,
1235
+ advanced: !0
1236
+ },
1237
+ {
1238
+ name: "position",
1239
+ type: "text",
1240
+ defaultValue: "center",
1241
+ enum: [
1242
+ "center",
1243
+ "top",
1244
+ "left",
1245
+ "right",
1246
+ "bottom",
1247
+ "top left",
1248
+ "top right",
1249
+ "bottom left",
1250
+ "bottom right"
1251
+ ]
1252
+ },
1253
+ {
1254
+ name: "height",
1255
+ type: "number",
1256
+ advanced: !0
1257
+ },
1258
+ {
1259
+ name: "width",
1260
+ type: "number",
1261
+ advanced: !0
1262
+ },
1263
+ {
1264
+ name: "aspectRatio",
1265
+ type: "number",
1266
+ advanced: !0,
1267
+ defaultValue: 0.7004048582995948
1268
+ },
1269
+ {
1270
+ name: "lazyLoad",
1271
+ type: "boolean",
1272
+ helperText: 'Load this video "lazily" - as in only when a user scrolls near the video. Recommended for optmized performance and bandwidth consumption',
1273
+ defaultValue: !0,
1274
+ advanced: !0
1275
+ }
1276
+ ]
1277
+ }, ct = {
1278
+ name: "Embed",
1279
+ static: !0,
1280
+ builtIn: !0,
1281
+ inputs: [
1282
+ {
1283
+ name: "url",
1284
+ type: "url",
1285
+ required: !0,
1286
+ defaultValue: "",
1287
+ helperText: "e.g. enter a youtube url, google map, etc",
1288
+ onChange: x((t) => {
1289
+ const e = t.get("url");
1290
+ if (e)
1291
+ return t.set("content", "Loading..."), fetch(
1292
+ `https://iframe.ly/api/iframely?url=${e}&api_key=ae0e60e78201a3f2b0de4b`
1293
+ ).then((o) => o.json()).then((o) => {
1294
+ t.get("url") === e && (o.html ? t.set("content", o.html) : t.set("content", "Invalid url, please try another"));
1295
+ }).catch((o) => {
1296
+ t.set(
1297
+ "content",
1298
+ "There was an error embedding this URL, please try again or another URL"
1299
+ );
1300
+ });
1301
+ t.delete("content");
1302
+ })
1303
+ },
1304
+ {
1305
+ name: "content",
1306
+ type: "html",
1307
+ defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
1308
+ hideFromUI: !0
1309
+ }
1310
+ ]
1311
+ }, lt = [
1312
+ "text/javascript",
1313
+ "application/javascript",
1314
+ "application/ecmascript"
1315
+ ], dt = (t) => lt.includes(t.type), ut = {
1316
+ name: "builder-embed",
1317
+ props: ["content"],
1318
+ data: () => ({ scriptsInserted: [], scriptsRun: [], ranInitFn: !1 }),
1319
+ watch: {
1320
+ onUpdateHook0() {
1321
+ this.$refs.elem && !this.ranInitFn && (this.ranInitFn = !0, this.findAndRunScripts());
1322
+ }
1323
+ },
1324
+ computed: {
1325
+ onUpdateHook0() {
1326
+ return {
1327
+ 0: this.$refs.elem,
1328
+ 1: this.ranInitFn
1329
+ };
1330
+ }
1331
+ },
1332
+ methods: {
1333
+ findAndRunScripts() {
1334
+ if (!this.$refs.elem || !this.$refs.elem.getElementsByTagName)
1335
+ return;
1336
+ const t = this.$refs.elem.getElementsByTagName("script");
1337
+ for (let e = 0; e < t.length; e++) {
1338
+ const n = t[e];
1339
+ if (n.src && !this.scriptsInserted.includes(n.src)) {
1340
+ this.scriptsInserted.push(n.src);
1341
+ const o = document.createElement("script");
1342
+ o.async = !0, o.src = n.src, document.head.appendChild(o);
1343
+ } else if (dt(n) && !this.scriptsRun.includes(n.innerText))
1344
+ try {
1345
+ this.scriptsRun.push(n.innerText), new Function(n.innerText)();
1346
+ } catch (o) {
1347
+ console.warn("`Embed`: Error running script:", o);
1348
+ }
1349
+ }
1350
+ }
1351
+ }
1352
+ };
1353
+ var pt = function() {
1354
+ var e = this, n = e._self._c;
1355
+ return n("div", { ref: "elem", staticClass: "builder-embed", domProps: { innerHTML: e._s(e.content) } });
1356
+ }, mt = [], ht = /* @__PURE__ */ p(
1357
+ ut,
1358
+ pt,
1359
+ mt,
1360
+ !1,
1361
+ null,
1362
+ null,
1363
+ null,
1364
+ null
1365
+ );
1366
+ const ft = ht.exports;
1367
+ function gt() {
1368
+ return u() && window.self !== window.top;
1369
+ }
1370
+ function f() {
1371
+ return gt() && window.location.search.indexOf("builder.frameEditing=") !== -1;
1372
+ }
1373
+ const bt = {
1374
+ name: "builder-img-component",
1375
+ props: [
1376
+ "backgroundSize",
1377
+ "backgroundPosition",
1378
+ "imgSrc",
1379
+ "altText",
1380
+ "image",
1381
+ "attributes"
1382
+ ],
1383
+ data: () => ({ isEditing: f })
1384
+ };
1385
+ var vt = function() {
1386
+ var e = this, n = e._self._c;
1387
+ return n("img", e._b({ key: e.isEditing() && e.imgSrc || "default-key", style: {
1388
+ objectFit: e.backgroundSize || "cover",
1389
+ objectPosition: e.backgroundPosition || "center"
1390
+ }, attrs: { alt: e.altText, src: e.imgSrc || e.image } }, "img", e.attributes, !1));
1391
+ }, _t = [], yt = /* @__PURE__ */ p(
1392
+ bt,
1393
+ vt,
1394
+ _t,
1395
+ !1,
1396
+ null,
1397
+ null,
1398
+ null,
1399
+ null
1400
+ );
1401
+ const xt = yt.exports, Ct = {
1402
+ name: "Raw:Img",
1403
+ hideFromInsertMenu: !0,
1404
+ builtIn: !0,
1405
+ 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",
1406
+ inputs: [
1407
+ {
1408
+ name: "image",
1409
+ bubble: !0,
1410
+ type: "file",
1411
+ allowedFileTypes: ["jpeg", "jpg", "png", "svg"],
1412
+ required: !0
1413
+ }
1414
+ ],
1415
+ noWrap: !0,
1416
+ static: !0
1417
+ }, kt = {
1418
+ name: "builder-custom-code",
1419
+ props: ["replaceNodes", "code"],
1420
+ data: () => ({ scriptsInserted: [], scriptsRun: [] }),
1421
+ mounted() {
1422
+ this.findAndRunScripts();
1423
+ },
1424
+ methods: {
1425
+ findAndRunScripts() {
1426
+ if (this.$refs.elem && this.$refs.elem.getElementsByTagName && typeof window < "u") {
1427
+ const t = this.$refs.elem.getElementsByTagName("script");
1428
+ for (let e = 0; e < t.length; e++) {
1429
+ const n = t[e];
1430
+ if (n.src) {
1431
+ if (this.scriptsInserted.includes(n.src))
1432
+ continue;
1433
+ this.scriptsInserted.push(n.src);
1434
+ const o = document.createElement("script");
1435
+ o.async = !0, o.src = n.src, document.head.appendChild(o);
1436
+ } else if (!n.type || [
1437
+ "text/javascript",
1438
+ "application/javascript",
1439
+ "application/ecmascript"
1440
+ ].includes(n.type)) {
1441
+ if (this.scriptsRun.includes(n.innerText))
1442
+ continue;
1443
+ try {
1444
+ this.scriptsRun.push(n.innerText), new Function(n.innerText)();
1445
+ } catch (o) {
1446
+ console.warn("`CustomCode`: Error running script:", o);
1447
+ }
1448
+ }
1449
+ }
1450
+ }
1451
+ },
1452
+ _classStringToObject(t) {
1453
+ const e = {};
1454
+ if (typeof t != "string")
1455
+ return e;
1456
+ const n = t.trim().split(/\s+/);
1457
+ for (const o of n)
1458
+ e[o] = !0;
1459
+ return e;
1460
+ }
1461
+ }
1462
+ };
1463
+ var wt = function() {
1464
+ var e = this, n = e._self._c;
1465
+ return n("div", { ref: "elem", class: e._classStringToObject(
1466
+ "builder-custom-code" + (e.replaceNodes ? " replace-nodes" : "")
1467
+ ), domProps: { innerHTML: e._s(e.code) } });
1468
+ }, St = [], It = /* @__PURE__ */ p(
1469
+ kt,
1470
+ wt,
1471
+ St,
1472
+ !1,
1473
+ null,
1474
+ null,
1475
+ null,
1476
+ null
1477
+ );
1478
+ const Tt = It.exports, Rt = {
1479
+ name: "Custom Code",
1480
+ static: !0,
1481
+ builtIn: !0,
1482
+ requiredPermissions: ["editCode"],
1483
+ inputs: [
1484
+ {
1485
+ name: "code",
1486
+ type: "html",
1487
+ required: !0,
1488
+ defaultValue: "<p>Hello there, I am custom HTML code!</p>",
1489
+ code: !0
1490
+ },
1491
+ {
1492
+ name: "replaceNodes",
1493
+ type: "boolean",
1494
+ helperText: "Preserve server rendered dom nodes",
1495
+ advanced: !0
1496
+ },
1497
+ {
1498
+ name: "scriptsClientOnly",
1499
+ type: "boolean",
1500
+ defaultValue: !1,
1501
+ helperText: "Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",
1502
+ advanced: !0
1503
+ }
1504
+ ]
1505
+ }, $t = () => [
1506
+ { component: Q, ...tt },
1507
+ { component: re, ...ot },
1508
+ { component: xt, ...Ct },
1509
+ { component: de, ...at },
1510
+ { component: fe, ...it },
1511
+ { component: We, ...rt },
1512
+ { component: ze, ...et },
1513
+ { component: Je, ...st },
1514
+ { component: Ze, ...nt },
1515
+ { component: ft, ...ct },
1516
+ { component: Tt, ...Rt }
1517
+ ];
1518
+ function T({
1519
+ code: t,
1520
+ context: e,
1521
+ state: n,
1522
+ event: o
1523
+ }) {
1524
+ if (t === "") {
1525
+ console.warn("Skipping evaluation of empty code block.");
1526
+ return;
1527
+ }
1528
+ const s = {
1529
+ isEditing: f(),
1530
+ isBrowser: u(),
1531
+ isServer: !u()
1532
+ }, a = !(t.includes(";") || t.includes(" return ") || t.trim().startsWith("return ")) ? `return (${t});` : t;
1533
+ try {
1534
+ return new Function(
1535
+ "builder",
1536
+ "Builder",
1537
+ "state",
1538
+ "context",
1539
+ "event",
1540
+ a
1541
+ )(s, s, n, e, o);
1542
+ } catch (c) {
1543
+ console.warn(
1544
+ `Builder custom code error:
1545
+ While Evaluating:
1546
+ `,
1547
+ a,
1548
+ `
1549
+ `,
1550
+ c.message || c
1551
+ );
1552
+ }
1553
+ }
1554
+ function Ft() {
1555
+ return !u() || f() ? !1 : Boolean(location.search.indexOf("builder.preview=") !== -1);
1556
+ }
1557
+ const O = [];
1558
+ function ln(t, e) {
1559
+ return O.push({ component: t, ...e }), console.warn(
1560
+ "registerComponent is deprecated. Use the `customComponents` prop in RenderContent instead to provide your custom components to the builder SDK."
1561
+ ), t;
1562
+ }
1563
+ const Et = ({
1564
+ component: t,
1565
+ ...e
1566
+ }) => ({
1567
+ type: "builder.registerComponent",
1568
+ data: Vt(e)
1569
+ }), P = (t) => JSON.parse(JSON.stringify(t)), jt = (t) => typeof t == "function" ? Ut(t) : P(t), Ut = (t) => {
1570
+ const e = t.toString().trim();
1571
+ return `return (${!e.startsWith("function") && !e.startsWith("(") ? "function " : ""}${e}).apply(this, arguments)`;
1572
+ }, Vt = ({
1573
+ inputs: t,
1574
+ ...e
1575
+ }) => ({
1576
+ ...P(e),
1577
+ inputs: t == null ? void 0 : t.map(
1578
+ (n) => Object.entries(n).reduce(
1579
+ (o, [s, r]) => ({
1580
+ ...o,
1581
+ [s]: jt(r)
1582
+ }),
1583
+ {}
1584
+ )
1585
+ )
1586
+ });
1587
+ function At() {
1588
+ return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(t) {
1589
+ const e = Math.random() * 16 | 0;
1590
+ return (t == "x" ? e : e & 3 | 8).toString(16);
1591
+ });
1592
+ }
1593
+ function W() {
1594
+ return At().replace(/-/g, "");
1595
+ }
1596
+ const B = "builderSessionId", Ot = async ({ canTrack: t }) => {
1597
+ if (!t)
1598
+ return;
1599
+ const e = await j({
1600
+ name: B,
1601
+ canTrack: t
1602
+ });
1603
+ if (g(e))
1604
+ return e;
1605
+ {
1606
+ const n = Pt();
1607
+ Wt({ id: n, canTrack: t });
1608
+ }
1609
+ }, Pt = () => W(), Wt = ({
1610
+ id: t,
1611
+ canTrack: e
1612
+ }) => U({ name: B, value: t, canTrack: e }), L = () => u() && typeof localStorage < "u" ? localStorage : void 0, Bt = ({
1613
+ key: t,
1614
+ canTrack: e
1615
+ }) => {
1616
+ var n;
1617
+ try {
1618
+ return e ? (n = L()) == null ? void 0 : n.getItem(t) : void 0;
1619
+ } catch (o) {
1620
+ console.debug("[LocalStorage] GET error: ", o);
1621
+ }
1622
+ }, Lt = ({
1623
+ key: t,
1624
+ canTrack: e,
1625
+ value: n
1626
+ }) => {
1627
+ var o;
1628
+ try {
1629
+ e && ((o = L()) == null || o.setItem(t, n));
1630
+ } catch (s) {
1631
+ console.debug("[LocalStorage] SET error: ", s);
1632
+ }
1633
+ }, M = "builderVisitorId", Mt = ({ canTrack: t }) => {
1634
+ if (!t)
1635
+ return;
1636
+ const e = Bt({
1637
+ key: M,
1638
+ canTrack: t
1639
+ });
1640
+ if (g(e))
1641
+ return e;
1642
+ {
1643
+ const n = Nt();
1644
+ zt({ id: n, canTrack: t });
1645
+ }
1646
+ }, Nt = () => W(), zt = ({
1647
+ id: t,
1648
+ canTrack: e
1649
+ }) => Lt({
1650
+ key: M,
1651
+ value: t,
1652
+ canTrack: e
1653
+ }), Ht = async ({
1654
+ canTrack: t
1655
+ }) => {
1656
+ if (!t)
1657
+ return { visitorId: void 0, sessionId: void 0 };
1658
+ const e = await Ot({ canTrack: t }), n = Mt({ canTrack: t });
1659
+ return {
1660
+ sessionId: e,
1661
+ visitorId: n
1662
+ };
1663
+ }, qt = async ({
1664
+ type: t,
1665
+ canTrack: e,
1666
+ orgId: n,
1667
+ contentId: o,
1668
+ ...s
1669
+ }) => ({
1670
+ type: t,
1671
+ data: {
1672
+ ...s,
1673
+ ...await Ht({ canTrack: e }),
1674
+ ownerId: n,
1675
+ contentId: o
1676
+ }
1677
+ });
1678
+ async function R(t) {
1679
+ if (!!t.canTrack && !f() && !!(u() || _ === "reactNative"))
1680
+ return fetch("https://builder.io/api/v1/track", {
1681
+ method: "POST",
1682
+ body: JSON.stringify({
1683
+ events: [await qt(t)]
1684
+ }),
1685
+ headers: {
1686
+ "content-type": "application/json"
1687
+ },
1688
+ mode: "cors"
1689
+ }).catch((e) => {
1690
+ console.error("Failed to track: ", e);
1691
+ });
1692
+ }
1693
+ const Dt = () => Promise.resolve().then(() => N).then((t) => t.default).catch((t) => {
1694
+ throw console.error(
1695
+ "Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",
1696
+ t
1697
+ ), t;
1698
+ }), Kt = () => import("./render-styles.90704267.js").then((t) => t.default).catch((t) => {
1699
+ throw console.error(
1700
+ "Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",
1701
+ t
1702
+ ), t;
1703
+ }), Jt = {
1704
+ name: "render-content",
1705
+ components: {
1706
+ "render-content-styles": Kt,
1707
+ "render-blocks": Dt
1708
+ },
1709
+ props: [
1710
+ "content",
1711
+ "data",
1712
+ "canTrack",
1713
+ "context",
1714
+ "customComponents",
1715
+ "model",
1716
+ "apiKey"
1717
+ ],
1718
+ data: () => ({
1719
+ forceReRenderCount: 0,
1720
+ overrideContent: null,
1721
+ update: 0,
1722
+ overrideState: {},
1723
+ markMutable: y
1724
+ }),
1725
+ provide() {
1726
+ const t = this;
1727
+ return {
1728
+ BuilderContext: {
1729
+ get content() {
1730
+ return t.useContent;
1731
+ },
1732
+ get state() {
1733
+ return t.contentState;
1734
+ },
1735
+ get context() {
1736
+ return t.contextContext;
1737
+ },
1738
+ get apiKey() {
1739
+ return t.apiKey;
1740
+ },
1741
+ get registeredComponents() {
1742
+ return t.allRegisteredComponents;
1743
+ }
1744
+ }
1745
+ };
1746
+ },
1747
+ mounted() {
1748
+ var t;
1749
+ if (u()) {
1750
+ if (f() && (this.forceReRenderCount = this.forceReRenderCount + 1, q(), D(), Object.values(this.allRegisteredComponents).forEach(
1751
+ (e) => {
1752
+ var o;
1753
+ const n = Et(e);
1754
+ (o = window.parent) == null || o.postMessage(n, "*");
1755
+ }
1756
+ ), window.addEventListener("message", this.processMessage), window.addEventListener(
1757
+ "builder:component:stateChangeListenerActivated",
1758
+ this.emitStateUpdate
1759
+ )), this.useContent && R({
1760
+ type: "impression",
1761
+ canTrack: this.canTrackToUse,
1762
+ contentId: (t = this.useContent) == null ? void 0 : t.id,
1763
+ orgId: this.apiKey
1764
+ }), Ft()) {
1765
+ const e = new URL(location.href).searchParams;
1766
+ if (this.model && e.get("builder.preview") === this.model) {
1767
+ const n = e.get("apiKey") || e.get("builder.space");
1768
+ n && A({
1769
+ model: this.model,
1770
+ apiKey: n
1771
+ }).then((o) => {
1772
+ o && (this.overrideContent = o);
1773
+ });
1774
+ }
1775
+ }
1776
+ this.evaluateJsCode(), this.runHttpRequests(), this.emitStateUpdate();
1777
+ }
1778
+ },
1779
+ watch: {
1780
+ onUpdateHook0() {
1781
+ this.evaluateJsCode();
1782
+ },
1783
+ onUpdateHook1() {
1784
+ this.runHttpRequests();
1785
+ },
1786
+ onUpdateHook2() {
1787
+ this.emitStateUpdate();
1788
+ }
1789
+ },
1790
+ unmounted() {
1791
+ u() && (window.removeEventListener("message", this.processMessage), window.removeEventListener(
1792
+ "builder:component:stateChangeListenerActivated",
1793
+ this.emitStateUpdate
1794
+ ));
1795
+ },
1796
+ computed: {
1797
+ useContent() {
1798
+ var e, n;
1799
+ return !this.content && !this.overrideContent ? void 0 : {
1800
+ ...this.content,
1801
+ ...this.overrideContent,
1802
+ data: {
1803
+ ...(e = this.content) == null ? void 0 : e.data,
1804
+ ...this.data,
1805
+ ...(n = this.overrideContent) == null ? void 0 : n.data
1806
+ }
1807
+ };
1808
+ },
1809
+ canTrackToUse() {
1810
+ return this.canTrack || !0;
1811
+ },
1812
+ contentState() {
1813
+ var t, e;
1814
+ return {
1815
+ ...(e = (t = this.content) == null ? void 0 : t.data) == null ? void 0 : e.state,
1816
+ ...this.data,
1817
+ ...this.overrideState
1818
+ };
1819
+ },
1820
+ contextContext() {
1821
+ return this.context || {};
1822
+ },
1823
+ allRegisteredComponents() {
1824
+ return [
1825
+ ...$t(),
1826
+ ...O,
1827
+ ...this.customComponents || []
1828
+ ].reduce(
1829
+ (n, o) => ({ ...n, [o.name]: o }),
1830
+ {}
1831
+ );
1832
+ },
1833
+ httpReqsData() {
1834
+ return {};
1835
+ },
1836
+ shouldRenderContentStyles() {
1837
+ var t, e, n, o, s;
1838
+ return Boolean(
1839
+ (((e = (t = this.useContent) == null ? void 0 : t.data) == null ? void 0 : e.cssCode) || ((s = (o = (n = this.useContent) == null ? void 0 : n.data) == null ? void 0 : o.customFonts) == null ? void 0 : s.length)) && _ !== "reactNative"
1840
+ );
1841
+ },
1842
+ onUpdateHook0() {
1843
+ var t, e;
1844
+ return {
1845
+ 0: (e = (t = this.useContent) == null ? void 0 : t.data) == null ? void 0 : e.jsCode
1846
+ };
1847
+ },
1848
+ onUpdateHook1() {
1849
+ var t, e;
1850
+ return {
1851
+ 0: (e = (t = this.useContent) == null ? void 0 : t.data) == null ? void 0 : e.httpRequests
1852
+ };
1853
+ },
1854
+ onUpdateHook2() {
1855
+ return {
1856
+ 0: this.contentState
1857
+ };
1858
+ }
1859
+ },
1860
+ methods: {
1861
+ processMessage(t) {
1862
+ const { data: e } = t;
1863
+ if (e)
1864
+ switch (e.type) {
1865
+ case "builder.contentUpdate": {
1866
+ const n = e.data, o = n.key || n.alias || n.entry || n.modelName, s = n.data;
1867
+ o === this.model && (this.overrideContent = s, this.forceReRenderCount = this.forceReRenderCount + 1);
1868
+ break;
1869
+ }
1870
+ }
1871
+ },
1872
+ evaluateJsCode() {
1873
+ var e, n;
1874
+ const t = (n = (e = this.useContent) == null ? void 0 : e.data) == null ? void 0 : n.jsCode;
1875
+ t && T({
1876
+ code: t,
1877
+ context: this.contextContext,
1878
+ state: this.contentState
1879
+ });
1880
+ },
1881
+ onClick(t) {
1882
+ var e;
1883
+ this.useContent && R({
1884
+ type: "click",
1885
+ canTrack: this.canTrackToUse,
1886
+ contentId: (e = this.useContent) == null ? void 0 : e.id,
1887
+ orgId: this.apiKey
1888
+ });
1889
+ },
1890
+ evalExpression(t) {
1891
+ return t.replace(
1892
+ /{{([^}]+)}}/g,
1893
+ (e, n) => T({
1894
+ code: n,
1895
+ context: this.contextContext,
1896
+ state: this.contentState
1897
+ })
1898
+ );
1899
+ },
1900
+ handleRequest({ url: t, key: e }) {
1901
+ E().then((n) => n(t)).then((n) => n.json()).then((n) => {
1902
+ const o = { ...this.overrideState, [e]: n };
1903
+ this.overrideState = o;
1904
+ }).catch((n) => {
1905
+ console.log("error fetching dynamic data", t, n);
1906
+ });
1907
+ },
1908
+ runHttpRequests() {
1909
+ var e, n, o;
1910
+ const t = (o = (n = (e = this.useContent) == null ? void 0 : e.data) == null ? void 0 : n.httpRequests) != null ? o : {};
1911
+ Object.entries(t).forEach(([s, r]) => {
1912
+ if (r && (!this.httpReqsData[s] || f())) {
1913
+ const a = this.evalExpression(r);
1914
+ this.handleRequest({
1915
+ url: a,
1916
+ key: s
1917
+ });
1918
+ }
1919
+ });
1920
+ },
1921
+ emitStateUpdate() {
1922
+ f() && window.dispatchEvent(
1923
+ new CustomEvent("builder:component:stateChange", {
1924
+ detail: {
1925
+ state: this.contentState,
1926
+ ref: {
1927
+ name: this.model
1928
+ }
1929
+ }
1930
+ })
1931
+ );
1932
+ }
1933
+ }
1934
+ };
1935
+ var Gt = function() {
1936
+ var o, s, r, a, c, i, l;
1937
+ var e = this, n = e._self._c;
1938
+ return e.useContent ? n("div", { ref: "elementRef", attrs: { "builder-content-id": (o = e.useContent) == null ? void 0 : o.id }, on: { click: function(d) {
1939
+ return e.onClick(d);
1940
+ } } }, [e.shouldRenderContentStyles ? [n("render-content-styles", { attrs: { cssCode: (r = (s = e.useContent) == null ? void 0 : s.data) == null ? void 0 : r.cssCode, customFonts: (c = (a = e.useContent) == null ? void 0 : a.data) == null ? void 0 : c.customFonts } })] : e._e(), n("render-blocks", { key: e.forceReRenderCount, attrs: { blocks: e.markMutable((l = (i = e.useContent) == null ? void 0 : i.data) == null ? void 0 : l.blocks) } })], 2) : e._e();
1941
+ }, Xt = [], Yt = /* @__PURE__ */ p(
1942
+ Jt,
1943
+ Gt,
1944
+ Xt,
1945
+ !1,
1946
+ null,
1947
+ null,
1948
+ null,
1949
+ null
1950
+ );
1951
+ const Qt = Yt.exports, Zt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1952
+ __proto__: null,
1953
+ default: Qt
1954
+ }, Symbol.toStringTag, { value: "Module" })), en = () => import("./block-styles.4b780e2e.js").then((t) => t.default).catch((t) => {
1955
+ throw console.error(
1956
+ "Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",
1957
+ t
1958
+ ), t;
1959
+ }), tn = () => import("./render-block.3112f40b.js").then((t) => t.default).catch((t) => {
1960
+ throw console.error(
1961
+ "Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",
1962
+ t
1963
+ ), t;
1964
+ }), nn = {
1965
+ name: "render-blocks",
1966
+ components: { "render-block": tn, "block-styles": en },
1967
+ props: ["blocks", "parent", "path"],
1968
+ inject: {
1969
+ builderContext: "BuilderContext"
1970
+ },
1971
+ computed: {
1972
+ className() {
1973
+ var t;
1974
+ return "builder-blocks" + ((t = this.blocks) != null && t.length ? "" : " no-blocks");
1975
+ }
1976
+ },
1977
+ methods: {
1978
+ onClick() {
1979
+ var t, e;
1980
+ f() && !((t = this.blocks) != null && t.length) && ((e = window.parent) == null || e.postMessage(
1981
+ {
1982
+ type: "builder.clickEmptyBlocks",
1983
+ data: {
1984
+ parentElementId: this.parent,
1985
+ dataPath: this.path
1986
+ }
1987
+ },
1988
+ "*"
1989
+ ));
1990
+ },
1991
+ onMouseEnter() {
1992
+ var t, e;
1993
+ f() && !((t = this.blocks) != null && t.length) && ((e = window.parent) == null || e.postMessage(
1994
+ {
1995
+ type: "builder.hoverEmptyBlocks",
1996
+ data: {
1997
+ parentElementId: this.parent,
1998
+ dataPath: this.path
1999
+ }
2000
+ },
2001
+ "*"
2002
+ ));
2003
+ },
2004
+ _classStringToObject(t) {
2005
+ const e = {};
2006
+ if (typeof t != "string")
2007
+ return e;
2008
+ const n = t.trim().split(/\s+/);
2009
+ for (const o of n)
2010
+ e[o] = !0;
2011
+ return e;
2012
+ }
2013
+ }
2014
+ };
2015
+ var on = function() {
2016
+ var e = this, n = e._self._c;
2017
+ return n("div", { class: e._classStringToObject(e.className + " div-21azgz5avex"), attrs: { "builder-path": e.path, "builder-parent-id": e.parent, dataSet: {
2018
+ class: e.className
2019
+ } }, on: { click: function(o) {
2020
+ return e.onClick();
2021
+ }, mouseenter: function(o) {
2022
+ return e.onMouseEnter();
2023
+ } } }, [e.blocks ? e._l(e.blocks, function(o, s) {
2024
+ return n("render-block", { key: "render-block-" + o.id, attrs: { block: o, context: e.builderContext } });
2025
+ }) : e._e(), e.blocks ? e._l(e.blocks, function(o, s) {
2026
+ return n("block-styles", { key: "block-style-" + o.id, attrs: { block: o, context: e.builderContext } });
2027
+ }) : e._e()], 2);
2028
+ }, sn = [], rn = /* @__PURE__ */ p(
2029
+ nn,
2030
+ on,
2031
+ sn,
2032
+ !1,
2033
+ null,
2034
+ "3c408a8a",
2035
+ null,
2036
+ null
2037
+ );
2038
+ const an = rn.exports, N = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2039
+ __proto__: null,
2040
+ default: an
2041
+ }, Symbol.toStringTag, { value: "Module" })), $ = {};
2042
+ function dn(t) {
2043
+ if (u()) {
2044
+ Object.assign($, t);
2045
+ const e = {
2046
+ type: "builder.settingsChange",
2047
+ data: $
2048
+ };
2049
+ parent.postMessage(e, "*");
2050
+ }
2051
+ }
2052
+ export {
2053
+ ze as B,
2054
+ Q as C,
2055
+ Ze as F,
2056
+ re as I,
2057
+ We as S,
2058
+ _ as T,
2059
+ fe as V,
2060
+ de as a,
2061
+ Je as b,
2062
+ an as c,
2063
+ Ft as d,
2064
+ T as e,
2065
+ O as f,
2066
+ ln as g,
2067
+ Et as h,
2068
+ f as i,
2069
+ H as j,
2070
+ A as k,
2071
+ Ee as l,
2072
+ cn as m,
2073
+ p as n,
2074
+ je as o,
2075
+ ge as p,
2076
+ be as q,
2077
+ Qt as r,
2078
+ dn as s,
2079
+ ve as t,
2080
+ F as u
2081
+ };