@builder.io/sdk-react 0.12.6 → 0.12.7

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.
@@ -1,14 +1,14 @@
1
1
  "use client";
2
- import { jsx as l, Fragment as h, jsxs as A } from "react/jsx-runtime";
3
- import { createContext as pe, useState as v, useContext as se, useRef as ee, useEffect as E, createElement as Le } from "react";
4
- import { T as $, i as N, j as V, k as _e, l as M, m as _, n as te, r as Oe, o as H, p as de, a as je, c as De, b as Ce, q as Ue, u as ue, v as me, w as Me } from "./server-entry-b9bdd327.js";
5
- import { _ as pn, h as Cn, f as wn, g as In, e as Tn, d as Rn, s as En, t as Pn } from "./server-entry-b9bdd327.js";
6
- const He = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), Ke = (e) => typeof e == "string" && He.has(e.toLowerCase());
7
- function ne(e) {
8
- return /* @__PURE__ */ l(h, { children: Ke(e.TagName) ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ l(h, { children: typeof e.TagName == "string" ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) : /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) }) });
2
+ import { jsx as c, Fragment as g, jsxs as W } from "react/jsx-runtime";
3
+ import { createContext as Te, useState as k, useEffect as R, useContext as fe, useRef as te, createElement as Ue } from "react";
4
+ import { T as F, i as N, j as V, k as He, l as M, m as O, n as ne, r as Me, o as K, p as he, a as Ke, c as ze, b as Re, q as qe, u as ge, v as be, w as Ye } from "./server-entry-b9bdd327.js";
5
+ import { _ as Wn, h as Nn, f as $n, g as Vn, e as Fn, d as Ln, s as Dn, t as On } from "./server-entry-b9bdd327.js";
6
+ const Qe = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), Ge = (e) => typeof e == "string" && Qe.has(e.toLowerCase());
7
+ function ie(e) {
8
+ return /* @__PURE__ */ c(g, { children: Ge(e.TagName) ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ c(g, { children: typeof e.TagName == "string" ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) : /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) }) });
9
9
  }
10
- const O = () => {
11
- switch ($) {
10
+ const _ = () => {
11
+ switch (F) {
12
12
  case "react":
13
13
  case "reactNative":
14
14
  case "rsc":
@@ -20,14 +20,14 @@ const O = () => {
20
20
  return "class";
21
21
  }
22
22
  };
23
- function ze(e) {
24
- return /* @__PURE__ */ l(
25
- ne,
23
+ function Je(e) {
24
+ return /* @__PURE__ */ c(
25
+ ie,
26
26
  {
27
27
  TagName: e.link ? e.builderLinkComponent || "a" : "button",
28
28
  attributes: {
29
29
  ...e.attributes,
30
- [O()]: `${e.link ? "" : "builder-button"} ${e.attributes[O()] || ""}`,
30
+ [_()]: `${e.link ? "" : "builder-button"} ${e.attributes[_()] || ""}`,
31
31
  ...e.link ? {
32
32
  href: e.link,
33
33
  target: e.openLinkInNewTab ? "_blank" : void 0,
@@ -41,7 +41,7 @@ function ze(e) {
41
41
  }
42
42
  );
43
43
  }
44
- const ie = pe({
44
+ const oe = Te({
45
45
  content: null,
46
46
  context: {},
47
47
  localState: void 0,
@@ -54,8 +54,8 @@ const ie = pe({
54
54
  inheritedStyles: {},
55
55
  BlocksWrapper: "div",
56
56
  BlocksWrapperProps: {}
57
- }), we = pe({ registeredComponents: {} });
58
- function qe(e) {
57
+ }), Ee = Te({ registeredComponents: {} });
58
+ function Xe(e) {
59
59
  var t;
60
60
  return {
61
61
  ...(t = e.component) == null ? void 0 : t.options,
@@ -66,7 +66,7 @@ function qe(e) {
66
66
  builderBlock: e
67
67
  };
68
68
  }
69
- const Ye = ({
69
+ const Ze = ({
70
70
  builder: e,
71
71
  context: t,
72
72
  event: n,
@@ -78,14 +78,14 @@ const Ye = ({
78
78
  builder: e,
79
79
  context: t,
80
80
  event: n
81
- }), Qe = () => ({
81
+ }), et = () => ({
82
82
  isEditing: N(),
83
83
  isBrowser: V(),
84
84
  isServer: !V(),
85
- getUserAttributes: () => _e()
86
- }), Ge = (e, {
85
+ getUserAttributes: () => He()
86
+ }), tt = (e, {
87
87
  isExpression: t = !0
88
- }) => /* we disable this for cases where we definitely don't want a return */ t && !(e.includes(";") || e.includes(" return ") || e.trim().startsWith("return ")) ? `return (${e});` : e, fe = ({
88
+ }) => /* 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, ye = ({
89
89
  code: e,
90
90
  builder: t,
91
91
  context: n,
@@ -94,19 +94,19 @@ const Ye = ({
94
94
  rootSetState: a,
95
95
  rootState: r
96
96
  }) => {
97
- const c = Ye({
97
+ const l = Ze({
98
98
  builder: t,
99
99
  context: n,
100
100
  event: i,
101
- state: Ie({
101
+ state: Pe({
102
102
  rootState: r,
103
103
  localState: o,
104
104
  rootSetState: a
105
105
  })
106
106
  });
107
- return new Function(...c.map(([s]) => s), e)(...c.map(([, s]) => s));
107
+ return new Function(...l.map(([s]) => s), e)(...l.map(([, s]) => s));
108
108
  };
109
- function Ie({
109
+ function Pe({
110
110
  rootState: e,
111
111
  localState: t,
112
112
  rootSetState: n
@@ -116,7 +116,7 @@ function Ie({
116
116
  if (t && o in t)
117
117
  return t[o];
118
118
  const a = i[o];
119
- return typeof a == "object" ? Ie({
119
+ return typeof a == "object" ? Pe({
120
120
  rootState: a,
121
121
  localState: void 0,
122
122
  rootSetState: n ? (r) => {
@@ -131,17 +131,17 @@ function Ie({
131
131
  }
132
132
  });
133
133
  }
134
- function Je() {
134
+ function nt() {
135
135
  var e;
136
136
  return typeof process != "undefined" && M((e = process == null ? void 0 : process.versions) == null ? void 0 : e.node);
137
137
  }
138
- const Xe = () => {
138
+ const it = () => {
139
139
  var i;
140
- if (!Je())
140
+ if (!nt())
141
141
  return !1;
142
142
  const e = process.arch === "arm64", t = process.version.startsWith("v20"), n = (i = process.env.NODE_OPTIONS) == null ? void 0 : i.includes("--no-node-snapshot");
143
- return e && t && !n ? (_.log("Skipping usage of `isolated-vm` to avoid crashes in Node v20 on an arm64 machine.\n If you would like to use the `isolated-vm` package on this machine, please provide the `NODE_OPTIONS=--no-node-snapshot` config to your Node process.\n See https://github.com/BuilderIO/builder/blob/main/packages/sdks/README.md#node-v20--m1-macs-apple-silicon-support for more information.\n "), !0) : !1;
144
- }, Ze = (e) => (V() || Xe(), fe(e));
143
+ return e && t && !n ? (O.log("Skipping usage of `isolated-vm` to avoid crashes in Node v20 on an arm64 machine.\n If you would like to use the `isolated-vm` package on this machine, please provide the `NODE_OPTIONS=--no-node-snapshot` config to your Node process.\n See https://github.com/BuilderIO/builder/blob/main/packages/sdks/README.md#node-v20--m1-macs-apple-silicon-support for more information.\n "), !0) : !1;
144
+ }, ot = (e) => (V() || it(), ye(e));
145
145
  function j({
146
146
  code: e,
147
147
  context: t,
@@ -152,14 +152,14 @@ function j({
152
152
  isExpression: r = !0
153
153
  }) {
154
154
  if (e === "") {
155
- _.warn("Skipping evaluation of empty code block.");
155
+ O.warn("Skipping evaluation of empty code block.");
156
156
  return;
157
157
  }
158
- const c = {
159
- code: Ge(e, {
158
+ const l = {
159
+ code: tt(e, {
160
160
  isExpression: r
161
161
  }),
162
- builder: Qe(),
162
+ builder: et(),
163
163
  context: t,
164
164
  event: a,
165
165
  rootSetState: o,
@@ -167,21 +167,21 @@ function j({
167
167
  localState: n
168
168
  };
169
169
  try {
170
- return Ze(c);
170
+ return ot(l);
171
171
  } catch (s) {
172
- _.error("Failed code evaluation: " + s.message, {
172
+ O.error("Failed code evaluation: " + s.message, {
173
173
  code: e
174
174
  });
175
175
  return;
176
176
  }
177
177
  }
178
- const et = (e, t, n) => {
178
+ const at = (e, t, n) => {
179
179
  if (Object(e) !== e)
180
180
  return e;
181
181
  const i = Array.isArray(t) ? t : t.toString().match(/[^.[\]]+/g);
182
182
  return i.slice(0, -1).reduce((o, a, r) => Object(o[a]) === o[a] ? o[a] : o[a] = Math.abs(Number(i[r + 1])) >> 0 === +i[r + 1] ? [] : {}, e)[i[i.length - 1]] = n, e;
183
183
  };
184
- const tt = ({
184
+ const rt = ({
185
185
  block: e,
186
186
  context: t,
187
187
  localState: n,
@@ -190,7 +190,7 @@ const tt = ({
190
190
  }) => {
191
191
  if (!e.bindings)
192
192
  return e;
193
- const a = te(e), r = {
193
+ const a = ne(e), r = {
194
194
  ...a,
195
195
  properties: {
196
196
  ...a.properties
@@ -199,19 +199,19 @@ const tt = ({
199
199
  ...a.actions
200
200
  }
201
201
  };
202
- for (const c in e.bindings) {
203
- const s = e.bindings[c], d = j({
202
+ for (const l in e.bindings) {
203
+ const s = e.bindings[l], d = j({
204
204
  code: s,
205
205
  localState: n,
206
206
  rootState: i,
207
207
  rootSetState: o,
208
208
  context: t
209
209
  });
210
- et(r, c, d);
210
+ at(r, l, d);
211
211
  }
212
212
  return r;
213
213
  };
214
- function K({
214
+ function z({
215
215
  block: e,
216
216
  context: t,
217
217
  shouldEvaluateBindings: n,
@@ -220,7 +220,7 @@ function K({
220
220
  rootSetState: a
221
221
  }) {
222
222
  const r = e;
223
- return n ? tt({
223
+ return n ? rt({
224
224
  block: r,
225
225
  localState: i,
226
226
  rootState: o,
@@ -228,13 +228,135 @@ function K({
228
228
  context: t
229
229
  }) : r;
230
230
  }
231
- const nt = ({
231
+ function lt(e, t, n = {}) {
232
+ let i, o, a, r = null, l = 0;
233
+ const s = function() {
234
+ l = n.leading === !1 ? 0 : Date.now(), r = null, a = e.apply(i, o), r || (i = o = null);
235
+ };
236
+ return function() {
237
+ const d = Date.now();
238
+ !l && n.leading === !1 && (l = d);
239
+ const u = t - (d - l);
240
+ return i = this, o = arguments, u <= 0 || u > t ? (r && (clearTimeout(r), r = null), l = d, a = e.apply(i, o), r || (i = o = null)) : !r && n.trailing !== !1 && (r = setTimeout(s, u)), a;
241
+ };
242
+ }
243
+ function $(e, ...t) {
244
+ const n = Object(e);
245
+ for (let i = 1; i < arguments.length; i++) {
246
+ const o = arguments[i];
247
+ if (o != null)
248
+ for (const a in o)
249
+ Object.prototype.hasOwnProperty.call(o, a) && (n[a] = o[a]);
250
+ }
251
+ return n;
252
+ }
253
+ const ae = (e) => e ? e.replace(/([A-Z])/g, (t) => `-${t[0].toLowerCase()}`) : "";
254
+ function ct(e) {
255
+ for (const t of e)
256
+ switch (t.trigger) {
257
+ case "pageLoad":
258
+ Ae(t);
259
+ break;
260
+ case "hover":
261
+ dt(t);
262
+ break;
263
+ case "scrollInView":
264
+ ut(t);
265
+ break;
266
+ }
267
+ }
268
+ function re(e) {
269
+ console.warn(`Cannot animate element: element with ID ${e} not found!`);
270
+ }
271
+ function le(e, t) {
272
+ const n = st(e), i = getComputedStyle(t), o = e.steps[0].styles, a = e.steps[e.steps.length - 1].styles, r = [o, a];
273
+ for (const l of r)
274
+ for (const s of n)
275
+ s in l || (l[s] = i[s]);
276
+ }
277
+ function st(e) {
278
+ const t = [];
279
+ for (const n of e.steps)
280
+ for (const i in n.styles)
281
+ t.indexOf(i) === -1 && t.push(i);
282
+ return t;
283
+ }
284
+ function Ae(e) {
285
+ const t = Array.prototype.slice.call(document.getElementsByClassName(e.elementId || e.id || ""));
286
+ if (!t.length) {
287
+ re(e.elementId || e.id || "");
288
+ return;
289
+ }
290
+ Array.from(t).forEach((n) => {
291
+ le(e, n), n.style.transition = "none", n.style.transitionDelay = "0", $(n.style, e.steps[0].styles), setTimeout(() => {
292
+ n.style.transition = `all ${e.duration}s ${ae(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s"), $(n.style, e.steps[1].styles), setTimeout(() => {
293
+ n.style.transition = "", n.style.transitionDelay = "";
294
+ }, (e.delay || 0) * 1e3 + e.duration * 1e3 + 100);
295
+ });
296
+ });
297
+ }
298
+ function dt(e) {
299
+ const t = Array.prototype.slice.call(document.getElementsByClassName(e.elementId || e.id || ""));
300
+ if (!t.length) {
301
+ re(e.elementId || e.id || "");
302
+ return;
303
+ }
304
+ Array.from(t).forEach((n) => {
305
+ le(e, n);
306
+ const i = e.steps[0].styles, o = e.steps[1].styles;
307
+ function a() {
308
+ $(n.style, i);
309
+ }
310
+ function r() {
311
+ $(n.style, o);
312
+ }
313
+ a(), n.addEventListener("mouseenter", r), n.addEventListener("mouseleave", a), setTimeout(() => {
314
+ n.style.transition = `all ${e.duration}s ${ae(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s");
315
+ });
316
+ });
317
+ }
318
+ function ut(e) {
319
+ const t = Array.prototype.slice.call(document.getElementsByClassName(e.elementId || e.id || ""));
320
+ if (!t.length) {
321
+ re(e.elementId || e.id || "");
322
+ return;
323
+ }
324
+ Array.from(t).forEach((n) => {
325
+ le(e, n);
326
+ let i = !1, o = !1;
327
+ function a() {
328
+ !i && l(n) ? (i = !0, o = !0, setTimeout(() => {
329
+ $(n.style, e.steps[1].styles), e.repeat || document.removeEventListener("scroll", r), setTimeout(() => {
330
+ o = !1, e.repeat || (n.style.transition = "", n.style.transitionDelay = "");
331
+ }, (e.duration + (e.delay || 0)) * 1e3 + 100);
332
+ })) : e.repeat && i && !o && !l(n) && (i = !1, $(n.style, e.steps[0].styles));
333
+ }
334
+ const r = lt(a, 200, {
335
+ leading: !1
336
+ });
337
+ function l(u) {
338
+ const h = u.getBoundingClientRect(), p = window.innerHeight, y = (e.thresholdPercent || 0) / 100 * p;
339
+ return h.bottom > y && h.top < p - y;
340
+ }
341
+ const s = e.steps[0].styles;
342
+ function d() {
343
+ $(n.style, s);
344
+ }
345
+ d(), setTimeout(() => {
346
+ n.style.transition = `all ${e.duration}s ${ae(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s");
347
+ }), document.addEventListener("scroll", r, {
348
+ capture: !0,
349
+ passive: !0
350
+ }), a();
351
+ });
352
+ }
353
+ const mt = ({
232
354
  block: e,
233
355
  context: t,
234
356
  registeredComponents: n
235
357
  }) => {
236
358
  var a;
237
- const i = (a = K({
359
+ const i = (a = z({
238
360
  block: e,
239
361
  localState: t.localState,
240
362
  rootState: t.rootState,
@@ -250,7 +372,7 @@ const nt = ({
250
372
  console.warn(`
251
373
  Could not find a registered component named "${i}".
252
374
  If you registered it, is the file that registered it imported by the file that needs to render it?`);
253
- }, it = ({
375
+ }, ft = ({
254
376
  block: e,
255
377
  context: t
256
378
  }) => {
@@ -283,7 +405,7 @@ const nt = ({
283
405
  },
284
406
  block: i
285
407
  }));
286
- }, Te = {
408
+ }, Be = {
287
409
  small: {
288
410
  min: 320,
289
411
  default: 321,
@@ -299,11 +421,11 @@ const nt = ({
299
421
  default: 991,
300
422
  max: 1200
301
423
  }
302
- }, he = (e, t = Te) => `@media (max-width: ${t[e].max}px)`, Re = ({
424
+ }, Se = (e, t = Be) => `@media (max-width: ${t[e].max}px)`, We = ({
303
425
  small: e,
304
426
  medium: t
305
427
  }) => {
306
- const n = te(Te);
428
+ const n = ne(Be);
307
429
  if (!e || !t)
308
430
  return n;
309
431
  const i = Math.floor(e / 2);
@@ -325,28 +447,28 @@ const nt = ({
325
447
  min: a,
326
448
  default: a + 1
327
449
  }, n;
328
- }, ot = (e) => e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase(), Ee = (e) => Object.entries(e).map(([n, i]) => {
450
+ }, ht = (e) => e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase(), Ne = (e) => Object.entries(e).map(([n, i]) => {
329
451
  if (typeof i == "string")
330
- return `${ot(n)}: ${i};`;
331
- }).filter(M), at = (e) => Ee(e).join(`
332
- `), J = ({
452
+ return `${ht(n)}: ${i};`;
453
+ }).filter(M), gt = (e) => Ne(e).join(`
454
+ `), X = ({
333
455
  mediaQuery: e,
334
456
  className: t,
335
457
  styles: n
336
458
  }) => {
337
459
  const i = `.${t} {
338
- ${at(n)}
460
+ ${gt(n)}
339
461
  }`;
340
462
  return e ? `${e} {
341
463
  ${i}
342
464
  }` : i;
343
465
  };
344
- function z(e) {
345
- return /* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: e.styles }, id: e.id });
466
+ function q(e) {
467
+ return /* @__PURE__ */ c("style", { dangerouslySetInnerHTML: { __html: e.styles }, id: e.id });
346
468
  }
347
- function rt(e) {
469
+ function bt(e) {
348
470
  function t() {
349
- const i = K({
471
+ const i = z({
350
472
  block: e.block,
351
473
  localState: e.context.localState,
352
474
  rootState: e.context.rootState,
@@ -357,45 +479,45 @@ function rt(e) {
357
479
  return M(i.hide) ? !i.hide : M(i.show) ? i.show : !0;
358
480
  }
359
481
  function n() {
360
- var x;
361
- const i = K({
482
+ var y;
483
+ const i = z({
362
484
  block: e.block,
363
485
  localState: e.context.localState,
364
486
  rootState: e.context.rootState,
365
487
  rootSetState: e.context.rootSetState,
366
488
  context: e.context.context,
367
489
  shouldEvaluateBindings: !0
368
- }), o = i.responsiveStyles, a = e.context.content, r = Re(
369
- ((x = a == null ? void 0 : a.meta) == null ? void 0 : x.breakpoints) || {}
370
- ), c = o == null ? void 0 : o.large, s = o == null ? void 0 : o.medium, d = o == null ? void 0 : o.small, m = i.id;
371
- if (!m)
490
+ }), o = i.responsiveStyles, a = e.context.content, r = We(
491
+ ((y = a == null ? void 0 : a.meta) == null ? void 0 : y.breakpoints) || {}
492
+ ), l = o == null ? void 0 : o.large, s = o == null ? void 0 : o.medium, d = o == null ? void 0 : o.small, u = i.id;
493
+ if (!u)
372
494
  return "";
373
- const g = c ? J({
374
- className: m,
375
- styles: c
376
- }) : "", k = s ? J({
377
- className: m,
495
+ const h = l ? X({
496
+ className: u,
497
+ styles: l
498
+ }) : "", p = s ? X({
499
+ className: u,
378
500
  styles: s,
379
- mediaQuery: he(
501
+ mediaQuery: Se(
380
502
  "medium",
381
503
  r
382
504
  )
383
- }) : "", S = d ? J({
384
- className: m,
505
+ }) : "", b = d ? X({
506
+ className: u,
385
507
  styles: d,
386
- mediaQuery: he(
508
+ mediaQuery: Se(
387
509
  "small",
388
510
  r
389
511
  )
390
512
  }) : "";
391
- return [g, k, S].join(" ");
513
+ return [h, p, b].join(" ");
392
514
  }
393
- return /* @__PURE__ */ l(h, { children: n() && t() ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(z, { styles: n() }) }) : null });
515
+ return /* @__PURE__ */ c(g, { children: n() && t() ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(q, { styles: n() }) }) : null });
394
516
  }
395
- function lt(e) {
517
+ function yt(e) {
396
518
  return e.charAt(0).toUpperCase() + e.slice(1);
397
519
  }
398
- const ct = (e) => `on${lt(e)}`, st = (e, t) => (n) => j({
520
+ const St = (e) => `on${yt(e)}`, xt = (e, t) => (n) => j({
399
521
  code: e,
400
522
  context: t.context,
401
523
  localState: t.localState,
@@ -404,16 +526,16 @@ const ct = (e) => `on${lt(e)}`, st = (e, t) => (n) => j({
404
526
  event: n,
405
527
  isExpression: !1
406
528
  });
407
- function Pe(e) {
529
+ function $e(e) {
408
530
  var i;
409
531
  const t = {}, n = (i = e.block.actions) != null ? i : {};
410
532
  for (const o in n) {
411
533
  if (!n.hasOwnProperty(o))
412
534
  continue;
413
535
  const a = n[o];
414
- let r = ct(o);
536
+ let r = St(o);
415
537
  if (e.stripPrefix)
416
- switch ($) {
538
+ switch (F) {
417
539
  case "vue":
418
540
  r = r.replace("v-on:", "");
419
541
  break;
@@ -421,29 +543,29 @@ function Pe(e) {
421
543
  r = r.replace("on:", "");
422
544
  break;
423
545
  }
424
- t[r] = st(a, e);
546
+ t[r] = xt(a, e);
425
547
  }
426
548
  return t;
427
549
  }
428
- function dt({
550
+ function pt({
429
551
  style: e
430
552
  }) {
431
553
  return e;
432
554
  }
433
- const ut = ({
555
+ const vt = ({
434
556
  block: e,
435
557
  context: t
436
- }) => Be(dt({
558
+ }) => Ve(pt({
437
559
  style: e.style || {},
438
560
  context: t,
439
561
  block: e
440
562
  }));
441
- function Be(e) {
442
- switch ($) {
563
+ function Ve(e) {
564
+ switch (F) {
443
565
  case "svelte":
444
566
  case "vue":
445
567
  case "solid":
446
- return Ee(e).join(" ");
568
+ return Ne(e).join(" ");
447
569
  case "qwik":
448
570
  case "reactNative":
449
571
  case "react":
@@ -451,45 +573,45 @@ function Be(e) {
451
573
  return e;
452
574
  }
453
575
  }
454
- function mt({
576
+ function kt({
455
577
  properties: e
456
578
  }) {
457
579
  return e;
458
580
  }
459
- const ft = (e) => ({
581
+ const Ct = (e) => ({
460
582
  href: e.href
461
583
  });
462
- function oe({
584
+ function ce({
463
585
  block: e,
464
586
  context: t
465
587
  }) {
466
588
  var i;
467
589
  const n = {
468
- ...ft(e),
590
+ ...Ct(e),
469
591
  ...e.properties,
470
592
  "builder-id": e.id,
471
- style: ut({
593
+ style: vt({
472
594
  block: e,
473
595
  context: t
474
596
  }),
475
- [O()]: [e.id, "builder-block", e.class, (i = e.properties) == null ? void 0 : i.class].filter(Boolean).join(" ")
597
+ [_()]: [e.id, "builder-block", e.class, (i = e.properties) == null ? void 0 : i.class].filter(Boolean).join(" ")
476
598
  };
477
- return mt({
599
+ return kt({
478
600
  properties: n,
479
601
  context: t,
480
602
  block: e
481
603
  });
482
604
  }
483
- function ht(e) {
484
- return /* @__PURE__ */ l(
485
- ne,
605
+ function wt(e) {
606
+ return /* @__PURE__ */ c(
607
+ ie,
486
608
  {
487
609
  TagName: e.Wrapper,
488
- attributes: oe({
610
+ attributes: ce({
489
611
  block: e.block,
490
612
  context: e.context
491
613
  }),
492
- actionAttributes: Pe({
614
+ actionAttributes: $e({
493
615
  block: e.block,
494
616
  rootState: e.context.rootState,
495
617
  rootSetState: e.context.rootSetState,
@@ -501,17 +623,17 @@ function ht(e) {
501
623
  }
502
624
  );
503
625
  }
504
- function gt(e) {
505
- return /* @__PURE__ */ l(
626
+ function It(e) {
627
+ return /* @__PURE__ */ c(
506
628
  e.Wrapper,
507
629
  {
508
630
  ...e.wrapperProps,
509
631
  attributes: e.includeBlockProps ? {
510
- ...oe({
632
+ ...ce({
511
633
  block: e.block,
512
634
  context: e.context
513
635
  }),
514
- ...Pe({
636
+ ...$e({
515
637
  block: e.block,
516
638
  rootState: e.context.rootState,
517
639
  rootSetState: e.context.rootSetState,
@@ -523,7 +645,7 @@ function gt(e) {
523
645
  }
524
646
  );
525
647
  }
526
- const bt = ({
648
+ const Tt = ({
527
649
  componentOptions: e,
528
650
  builderBlock: t,
529
651
  context: n,
@@ -532,14 +654,14 @@ const bt = ({
532
654
  isInteractive: a,
533
655
  contextValue: r
534
656
  }) => {
535
- const c = {
657
+ const l = {
536
658
  ...e,
537
659
  /**
538
660
  * If `noWrap` is set to `true`, then the block's props/attributes are provided to the
539
661
  * component itself directly. Otherwise, they are provided to the wrapper element.
540
662
  */
541
663
  ...o ? {
542
- attributes: oe({
664
+ attributes: ce({
543
665
  block: t,
544
666
  context: r
545
667
  })
@@ -551,17 +673,17 @@ const bt = ({
551
673
  context: n,
552
674
  wrapperProps: e,
553
675
  includeBlockProps: o
554
- } : c;
676
+ } : l;
555
677
  };
556
- function ge(e) {
678
+ function xe(e) {
557
679
  var i;
558
- const [t, n] = v(
559
- () => e.isInteractive ? gt : e.componentRef
680
+ const [t, n] = k(
681
+ () => e.isInteractive ? It : e.componentRef
560
682
  );
561
- return /* @__PURE__ */ l(h, { children: e.componentRef ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(
683
+ return /* @__PURE__ */ c(g, { children: e.componentRef ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
562
684
  t,
563
685
  {
564
- ...bt({
686
+ ...Tt({
565
687
  componentOptions: e.componentOptions,
566
688
  builderBlock: e.builderBlock,
567
689
  context: e.context,
@@ -571,8 +693,8 @@ function ge(e) {
571
693
  isInteractive: e.isInteractive,
572
694
  contextValue: e.context
573
695
  }),
574
- children: (i = e.blockChildren) == null ? void 0 : i.map((o) => /* @__PURE__ */ l(
575
- q,
696
+ children: (i = e.blockChildren) == null ? void 0 : i.map((o) => /* @__PURE__ */ c(
697
+ Y,
576
698
  {
577
699
  block: o,
578
700
  context: e.context,
@@ -584,10 +706,10 @@ function ge(e) {
584
706
  }
585
707
  ) }) : null });
586
708
  }
587
- function yt(e) {
588
- const [t, n] = v(() => e.repeatContext);
589
- return /* @__PURE__ */ l(ie.Provider, { value: t, children: /* @__PURE__ */ l(
590
- q,
709
+ function Rt(e) {
710
+ const [t, n] = k(() => e.repeatContext);
711
+ return /* @__PURE__ */ c(oe.Provider, { value: t, children: /* @__PURE__ */ c(
712
+ Y,
591
713
  {
592
714
  block: e.block,
593
715
  context: t,
@@ -596,24 +718,24 @@ function yt(e) {
596
718
  }
597
719
  ) });
598
720
  }
599
- function q(e) {
600
- var m, g, k;
721
+ function Y(e) {
722
+ var u, h, p;
601
723
  function t() {
602
- return nt({
724
+ return mt({
603
725
  block: e.block,
604
726
  context: e.context,
605
727
  registeredComponents: e.registeredComponents
606
728
  });
607
729
  }
608
730
  function n() {
609
- return it({
731
+ return ft({
610
732
  block: e.block,
611
733
  context: e.context
612
734
  });
613
735
  }
614
736
  function i() {
615
- var S;
616
- return (S = e.block.repeat) != null && S.collection ? e.block : K({
737
+ var b;
738
+ return (b = e.block.repeat) != null && b.collection ? e.block : z({
617
739
  block: e.block,
618
740
  localState: e.context.localState,
619
741
  rootState: e.context.rootState,
@@ -623,29 +745,29 @@ function q(e) {
623
745
  });
624
746
  }
625
747
  function o() {
626
- var x;
627
- return e.block.tagName === "a" || ((x = i().properties) == null ? void 0 : x.href) || i().href ? e.linkComponent || "a" : e.block.tagName || "div";
748
+ var y;
749
+ return e.block.tagName === "a" || ((y = i().properties) == null ? void 0 : y.href) || i().href ? e.linkComponent || "a" : e.block.tagName || "div";
628
750
  }
629
751
  function a() {
630
- var C, R;
631
- if ((C = e.block.repeat) != null && C.collection)
632
- return !!((R = n == null ? void 0 : n()) != null && R.length);
633
- const S = "hide" in i() ? i().hide : !1;
634
- return ("show" in i() ? i().show : !0) && !S;
752
+ var v, E;
753
+ if ((v = e.block.repeat) != null && v.collection)
754
+ return !!((E = n == null ? void 0 : n()) != null && E.length);
755
+ const b = "hide" in i() ? i().hide : !1;
756
+ return ("show" in i() ? i().show : !0) && !b;
635
757
  }
636
758
  function r() {
637
- var x, C;
638
- return !((x = t == null ? void 0 : t()) != null && x.component) && !n() ? (C = i().children) != null ? C : [] : [];
759
+ var y, v;
760
+ return !((y = t == null ? void 0 : t()) != null && y.component) && !n() ? (v = i().children) != null ? v : [] : [];
639
761
  }
640
- function c() {
641
- var S, x, C, R, B, w, I, P, W;
762
+ function l() {
763
+ var b, y, v, E, A, w, I, P, B;
642
764
  return {
643
- blockChildren: (S = i().children) != null ? S : [],
644
- componentRef: (x = t == null ? void 0 : t()) == null ? void 0 : x.component,
765
+ blockChildren: (b = i().children) != null ? b : [],
766
+ componentRef: (y = t == null ? void 0 : t()) == null ? void 0 : y.component,
645
767
  componentOptions: {
646
- ...qe(i()),
768
+ ...Xe(i()),
647
769
  builderContext: e.context,
648
- ...((C = t == null ? void 0 : t()) == null ? void 0 : C.name) === "Core:Button" || ((R = t == null ? void 0 : t()) == null ? void 0 : R.name) === "Symbol" || ((B = t == null ? void 0 : t()) == null ? void 0 : B.name) === "Columns" ? {
770
+ ...((v = t == null ? void 0 : t()) == null ? void 0 : v.name) === "Core:Button" || ((E = t == null ? void 0 : t()) == null ? void 0 : E.name) === "Symbol" || ((A = t == null ? void 0 : t()) == null ? void 0 : A.name) === "Columns" ? {
649
771
  builderLinkComponent: e.linkComponent
650
772
  } : {},
651
773
  ...((w = t == null ? void 0 : t()) == null ? void 0 : w.name) === "Symbol" || ((I = t == null ? void 0 : t()) == null ? void 0 : I.name) === "Columns" ? {
@@ -657,72 +779,80 @@ function q(e) {
657
779
  registeredComponents: e.registeredComponents,
658
780
  builderBlock: i(),
659
781
  includeBlockProps: ((P = t == null ? void 0 : t()) == null ? void 0 : P.noWrap) === !0,
660
- isInteractive: !((W = t == null ? void 0 : t()) != null && W.isRSC)
782
+ isInteractive: !((B = t == null ? void 0 : t()) != null && B.isRSC)
661
783
  };
662
784
  }
663
- const [s, d] = v(() => e.context);
664
- return /* @__PURE__ */ l(h, { children: a() ? /* @__PURE__ */ A(h, { children: [
665
- /* @__PURE__ */ l(rt, { block: e.block, context: e.context }),
666
- (m = t == null ? void 0 : t()) != null && m.noWrap ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(
667
- ge,
785
+ const [s, d] = k(() => e.context);
786
+ return R(() => {
787
+ const b = i().id, y = i().animations;
788
+ y && b && ct(
789
+ y.filter((v) => v.trigger !== "hover").map((v) => ({
790
+ ...v,
791
+ elementId: b
792
+ }))
793
+ );
794
+ }, []), /* @__PURE__ */ c(g, { children: a() ? /* @__PURE__ */ W(g, { children: [
795
+ /* @__PURE__ */ c(bt, { block: e.block, context: e.context }),
796
+ (u = t == null ? void 0 : t()) != null && u.noWrap ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
797
+ xe,
668
798
  {
669
- componentRef: c().componentRef,
670
- componentOptions: c().componentOptions,
671
- blockChildren: c().blockChildren,
672
- context: c().context,
673
- registeredComponents: c().registeredComponents,
674
- linkComponent: c().linkComponent,
675
- builderBlock: c().builderBlock,
676
- includeBlockProps: c().includeBlockProps,
677
- isInteractive: c().isInteractive
799
+ componentRef: l().componentRef,
800
+ componentOptions: l().componentOptions,
801
+ blockChildren: l().blockChildren,
802
+ context: l().context,
803
+ registeredComponents: l().registeredComponents,
804
+ linkComponent: l().linkComponent,
805
+ builderBlock: l().builderBlock,
806
+ includeBlockProps: l().includeBlockProps,
807
+ isInteractive: l().isInteractive
678
808
  }
679
- ) }) : /* @__PURE__ */ l(h, { children: n() ? /* @__PURE__ */ l(h, { children: (k = n()) == null ? void 0 : k.map((S, x) => /* @__PURE__ */ l(
680
- yt,
809
+ ) }) : /* @__PURE__ */ c(g, { children: n() ? /* @__PURE__ */ c(g, { children: (p = n()) == null ? void 0 : p.map((b, y) => /* @__PURE__ */ c(
810
+ Rt,
681
811
  {
682
- repeatContext: S.context,
683
- block: S.block,
812
+ repeatContext: b.context,
813
+ block: b.block,
684
814
  registeredComponents: e.registeredComponents,
685
815
  linkComponent: e.linkComponent
686
816
  },
687
- x
688
- )) }) : /* @__PURE__ */ l(h, { children: /* @__PURE__ */ A(
689
- ht,
817
+ y
818
+ )) }) : /* @__PURE__ */ c(g, { children: /* @__PURE__ */ W(
819
+ wt,
690
820
  {
691
821
  Wrapper: o(),
692
822
  block: i(),
693
823
  context: e.context,
694
824
  linkComponent: e.linkComponent,
695
825
  children: [
696
- /* @__PURE__ */ l(
697
- ge,
826
+ /* @__PURE__ */ c(
827
+ xe,
698
828
  {
699
- componentRef: c().componentRef,
700
- componentOptions: c().componentOptions,
701
- blockChildren: c().blockChildren,
702
- context: c().context,
703
- registeredComponents: c().registeredComponents,
704
- linkComponent: c().linkComponent,
705
- builderBlock: c().builderBlock,
706
- includeBlockProps: c().includeBlockProps,
707
- isInteractive: c().isInteractive
829
+ componentRef: l().componentRef,
830
+ componentOptions: l().componentOptions,
831
+ blockChildren: l().blockChildren,
832
+ context: l().context,
833
+ registeredComponents: l().registeredComponents,
834
+ linkComponent: l().linkComponent,
835
+ builderBlock: l().builderBlock,
836
+ includeBlockProps: l().includeBlockProps,
837
+ isInteractive: l().isInteractive
708
838
  }
709
839
  ),
710
- (g = r()) == null ? void 0 : g.map((S) => /* @__PURE__ */ l(
711
- q,
840
+ (h = r()) == null ? void 0 : h.map((b) => /* @__PURE__ */ c(
841
+ Y,
712
842
  {
713
- block: S,
843
+ block: b,
714
844
  context: s,
715
845
  registeredComponents: e.registeredComponents,
716
846
  linkComponent: e.linkComponent
717
847
  },
718
- S.id
848
+ b.id
719
849
  ))
720
850
  ]
721
851
  }
722
852
  ) }) })
723
853
  ] }) : null });
724
854
  }
725
- function St(e) {
855
+ function Et(e) {
726
856
  function t() {
727
857
  var o;
728
858
  return "builder-blocks" + ((o = e.blocks) != null && o.length ? "" : " no-blocks");
@@ -753,8 +883,8 @@ function St(e) {
753
883
  "*"
754
884
  ));
755
885
  }
756
- return /* @__PURE__ */ A(h, { children: [
757
- /* @__PURE__ */ l(
886
+ return /* @__PURE__ */ W(g, { children: [
887
+ /* @__PURE__ */ c(
758
888
  e.BlocksWrapper,
759
889
  {
760
890
  className: t() + " props-blocks-wrapper-4f2c12d8",
@@ -768,18 +898,18 @@ function St(e) {
768
898
  children: e.children
769
899
  }
770
900
  ),
771
- /* @__PURE__ */ l("style", { children: `.props-blocks-wrapper-4f2c12d8 {
901
+ /* @__PURE__ */ c("style", { children: `.props-blocks-wrapper-4f2c12d8 {
772
902
  display: flex;
773
903
  flex-direction: column;
774
904
  align-items: stretch;
775
905
  }` })
776
906
  ] });
777
907
  }
778
- function Y(e) {
908
+ function Q(e) {
779
909
  var i, o, a;
780
- const t = se(ie), n = se(we);
781
- return /* @__PURE__ */ l(
782
- St,
910
+ const t = fe(oe), n = fe(Ee);
911
+ return /* @__PURE__ */ c(
912
+ Et,
783
913
  {
784
914
  blocks: e.blocks,
785
915
  parent: e.parent,
@@ -787,8 +917,8 @@ function Y(e) {
787
917
  styleProp: e.styleProp,
788
918
  BlocksWrapper: (i = e.context) == null ? void 0 : i.BlocksWrapper,
789
919
  BlocksWrapperProps: (o = e.context) == null ? void 0 : o.BlocksWrapperProps,
790
- children: e.blocks ? /* @__PURE__ */ l(h, { children: (a = e.blocks) == null ? void 0 : a.map((r) => /* @__PURE__ */ l(
791
- q,
920
+ children: e.blocks ? /* @__PURE__ */ c(g, { children: (a = e.blocks) == null ? void 0 : a.map((r) => /* @__PURE__ */ c(
921
+ Y,
792
922
  {
793
923
  block: r,
794
924
  linkComponent: e.linkComponent,
@@ -800,20 +930,20 @@ function Y(e) {
800
930
  }
801
931
  );
802
932
  }
803
- function xt(e) {
804
- var B;
805
- const [t, n] = v(
933
+ function Pt(e) {
934
+ var A;
935
+ const [t, n] = k(
806
936
  () => typeof e.space == "number" ? e.space || 0 : 20
807
- ), [i, o] = v(() => e.columns || []), [a, r] = v(
937
+ ), [i, o] = k(() => e.columns || []), [a, r] = k(
808
938
  () => e.stackColumnsAt || "tablet"
809
939
  );
810
- function c(w) {
940
+ function l(w) {
811
941
  var I;
812
942
  return ((I = i[w]) == null ? void 0 : I.width) || 100 / i.length;
813
943
  }
814
944
  function s(w) {
815
945
  const I = t * (i.length - 1) / i.length;
816
- return `calc(${c(w)}% - ${I}px)`;
946
+ return `calc(${l(w)}% - ${I}px)`;
817
947
  }
818
948
  function d({
819
949
  stackedStyle: w,
@@ -821,26 +951,26 @@ function xt(e) {
821
951
  }) {
822
952
  return a === "tablet" ? w : I;
823
953
  }
824
- function m({
954
+ function u({
825
955
  stackedStyle: w,
826
956
  desktopStyle: I
827
957
  }) {
828
958
  return a === "never" ? I : w;
829
959
  }
830
- const [g, k] = v(
960
+ const [h, p] = k(
831
961
  () => e.stackColumnsAt === "never" ? "row" : e.reverseColumnsWhenStacked ? "column-reverse" : "column"
832
962
  );
833
- function S() {
963
+ function b() {
834
964
  return {
835
- "--flex-dir": g,
965
+ "--flex-dir": h,
836
966
  "--flex-dir-tablet": d({
837
- stackedStyle: g,
967
+ stackedStyle: h,
838
968
  desktopStyle: "row"
839
969
  })
840
970
  };
841
971
  }
842
- function x(w) {
843
- const I = w === 0 ? 0 : t, P = s(w), W = `${I}px`, F = "100%", L = 0;
972
+ function y(w) {
973
+ const I = w === 0 ? 0 : t, P = s(w), B = `${I}px`, L = "100%", D = 0;
844
974
  return {
845
975
  ...{
846
976
  display: "flex",
@@ -848,34 +978,34 @@ function xt(e) {
848
978
  alignItems: "stretch"
849
979
  },
850
980
  width: P,
851
- ["marginLeft"]: W,
852
- "--column-width-mobile": m({
853
- stackedStyle: F,
981
+ ["marginLeft"]: B,
982
+ "--column-width-mobile": u({
983
+ stackedStyle: L,
854
984
  desktopStyle: P
855
985
  }),
856
- "--column-margin-left-mobile": m({
857
- stackedStyle: L,
858
- desktopStyle: W
986
+ "--column-margin-left-mobile": u({
987
+ stackedStyle: D,
988
+ desktopStyle: B
859
989
  }),
860
990
  "--column-width-tablet": d({
861
- stackedStyle: F,
991
+ stackedStyle: L,
862
992
  desktopStyle: P
863
993
  }),
864
994
  "--column-margin-left-tablet": d({
865
- stackedStyle: L,
866
- desktopStyle: W
995
+ stackedStyle: D,
996
+ desktopStyle: B
867
997
  })
868
998
  };
869
999
  }
870
- function C(w) {
871
- var P, W;
872
- return Re(
873
- ((W = (P = e.builderContext.content) == null ? void 0 : P.meta) == null ? void 0 : W.breakpoints) || {}
1000
+ function v(w) {
1001
+ var P, B;
1002
+ return We(
1003
+ ((B = (P = e.builderContext.content) == null ? void 0 : P.meta) == null ? void 0 : B.breakpoints) || {}
874
1004
  )[w].max;
875
1005
  }
876
- function R() {
1006
+ function E() {
877
1007
  return `
878
- @media (max-width: ${C("medium")}px) {
1008
+ @media (max-width: ${v("medium")}px) {
879
1009
  .${e.builderBlock.id}-breakpoints {
880
1010
  flex-direction: var(--flex-dir-tablet);
881
1011
  align-items: stretch;
@@ -887,7 +1017,7 @@ function xt(e) {
887
1017
  }
888
1018
  }
889
1019
 
890
- @media (max-width: ${C("small")}px) {
1020
+ @media (max-width: ${v("small")}px) {
891
1021
  .${e.builderBlock.id}-breakpoints {
892
1022
  flex-direction: var(--flex-dir);
893
1023
  align-items: stretch;
@@ -900,16 +1030,16 @@ function xt(e) {
900
1030
  },
901
1031
  `;
902
1032
  }
903
- return /* @__PURE__ */ A(h, { children: [
904
- /* @__PURE__ */ A(
1033
+ return /* @__PURE__ */ W(g, { children: [
1034
+ /* @__PURE__ */ W(
905
1035
  "div",
906
1036
  {
907
1037
  className: `builder-columns ${e.builderBlock.id}-breakpoints div-6f826264`,
908
- style: S(),
1038
+ style: b(),
909
1039
  children: [
910
- /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(z, { styles: R() }) }),
911
- (B = e.columns) == null ? void 0 : B.map((w, I) => /* @__PURE__ */ l(
912
- ne,
1040
+ /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(q, { styles: E() }) }),
1041
+ (A = e.columns) == null ? void 0 : A.map((w, I) => /* @__PURE__ */ c(
1042
+ ie,
913
1043
  {
914
1044
  TagName: w.link ? e.builderLinkComponent || "a" : "div",
915
1045
  actionAttributes: {},
@@ -917,11 +1047,11 @@ function xt(e) {
917
1047
  ...w.link ? {
918
1048
  href: w.link
919
1049
  } : {},
920
- [O()]: "builder-column",
921
- style: Be(x(I))
1050
+ [_()]: "builder-column",
1051
+ style: Ve(y(I))
922
1052
  },
923
- children: /* @__PURE__ */ l(
924
- Y,
1053
+ children: /* @__PURE__ */ c(
1054
+ Q,
925
1055
  {
926
1056
  path: `component.options.columns.${I}.blocks`,
927
1057
  parent: e.builderBlock.id,
@@ -940,60 +1070,60 @@ function xt(e) {
940
1070
  ]
941
1071
  }
942
1072
  ),
943
- /* @__PURE__ */ l("style", { children: `.div-6f826264 {
1073
+ /* @__PURE__ */ c("style", { children: `.div-6f826264 {
944
1074
  display: flex;
945
1075
  line-height: normal;
946
1076
  }` })
947
1077
  ] });
948
1078
  }
949
- function vt(e) {
950
- return /* @__PURE__ */ l("span", { children: e.children });
1079
+ function At(e) {
1080
+ return /* @__PURE__ */ c("span", { children: e.children });
951
1081
  }
952
- function be(e) {
1082
+ function pe(e) {
953
1083
  return e.replace(/http(s)?:/, "");
954
1084
  }
955
- function kt(e = "", t, n) {
1085
+ function Bt(e = "", t, n) {
956
1086
  const i = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), o = e.indexOf("?") !== -1 ? "&" : "?";
957
1087
  return e.match(i) ? e.replace(i, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + o + t + "=" + encodeURIComponent(n);
958
1088
  }
959
- function pt(e, t) {
1089
+ function Wt(e, t) {
960
1090
  if (!e || !(e != null && e.match(/cdn\.shopify\.com/)) || !t)
961
1091
  return e;
962
1092
  if (t === "master")
963
- return be(e);
1093
+ return pe(e);
964
1094
  const n = e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);
965
1095
  if (n) {
966
1096
  const i = e.split(n[0]), o = n[3], a = t.match("x") ? t : `${t}x`;
967
- return be(`${i[0]}_${a}${o}`);
1097
+ return pe(`${i[0]}_${a}${o}`);
968
1098
  }
969
1099
  return null;
970
1100
  }
971
- function X(e) {
1101
+ function Z(e) {
972
1102
  if (!e)
973
1103
  return e;
974
1104
  const t = [100, 200, 400, 800, 1200, 1600, 2e3];
975
1105
  if (e.match(/builder\.io/)) {
976
1106
  let n = e;
977
1107
  const i = Number(e.split("?width=")[1]);
978
- return isNaN(i) || (n = `${n} ${i}w`), t.filter((o) => o !== i).map((o) => `${kt(e, "width", o)} ${o}w`).concat([n]).join(", ");
1108
+ return isNaN(i) || (n = `${n} ${i}w`), t.filter((o) => o !== i).map((o) => `${Bt(e, "width", o)} ${o}w`).concat([n]).join(", ");
979
1109
  }
980
- return e.match(/cdn\.shopify\.com/) ? t.map((n) => [pt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, i]) => `${n} ${i}w`).concat([e]).join(", ") : e;
1110
+ return e.match(/cdn\.shopify\.com/) ? t.map((n) => [Wt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, i]) => `${n} ${i}w`).concat([e]).join(", ") : e;
981
1111
  }
982
- function Ct(e) {
983
- var o, a, r, c;
1112
+ function Nt(e) {
1113
+ var o, a, r, l;
984
1114
  function t() {
985
- var m;
1115
+ var u;
986
1116
  const d = e.image || e.src;
987
1117
  if (!d || // We can auto add srcset for cdn.builder.io and shopify
988
1118
  // images, otherwise you can supply this prop manually
989
1119
  !(d.match(/builder\.io/) || d.match(/cdn\.shopify\.com/)))
990
1120
  return e.srcset;
991
- if (e.srcset && ((m = e.image) != null && m.includes("builder.io/api/v1/image"))) {
1121
+ if (e.srcset && ((u = e.image) != null && u.includes("builder.io/api/v1/image"))) {
992
1122
  if (!e.srcset.includes(e.image.split("?")[0]))
993
- return console.debug("Removed given srcset"), X(d);
1123
+ return console.debug("Removed given srcset"), Z(d);
994
1124
  } else if (e.image && !e.srcset)
995
- return X(d);
996
- return X(d);
1125
+ return Z(d);
1126
+ return Z(d);
997
1127
  }
998
1128
  function n() {
999
1129
  var s;
@@ -1009,11 +1139,11 @@ function Ct(e) {
1009
1139
  };
1010
1140
  return e.aspectRatio ? s : void 0;
1011
1141
  }
1012
- return /* @__PURE__ */ A(h, { children: [
1013
- /* @__PURE__ */ A(h, { children: [
1014
- /* @__PURE__ */ A("picture", { children: [
1015
- n() ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l("source", { type: "image/webp", srcSet: n() }) }) : null,
1016
- /* @__PURE__ */ l(
1142
+ return /* @__PURE__ */ W(g, { children: [
1143
+ /* @__PURE__ */ W(g, { children: [
1144
+ /* @__PURE__ */ W("picture", { children: [
1145
+ n() ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c("source", { type: "image/webp", srcSet: n() }) }) : null,
1146
+ /* @__PURE__ */ c(
1017
1147
  "img",
1018
1148
  {
1019
1149
  loading: "lazy",
@@ -1031,7 +1161,7 @@ function Ct(e) {
1031
1161
  }
1032
1162
  )
1033
1163
  ] }),
1034
- e.aspectRatio && !((a = (o = e.builderBlock) == null ? void 0 : o.children) != null && a.length && e.fitContent) ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(
1164
+ e.aspectRatio && !((a = (o = e.builderBlock) == null ? void 0 : o.children) != null && a.length && e.fitContent) ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
1035
1165
  "div",
1036
1166
  {
1037
1167
  className: "builder-image-sizer div-40c70c9b",
@@ -1040,10 +1170,10 @@ function Ct(e) {
1040
1170
  }
1041
1171
  }
1042
1172
  ) }) : null,
1043
- (c = (r = e.builderBlock) == null ? void 0 : r.children) != null && c.length && e.fitContent ? /* @__PURE__ */ l(h, { children: e.children }) : null,
1044
- !e.fitContent && e.children ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l("div", { className: "div-40c70c9b-2", children: e.children }) }) : null
1173
+ (l = (r = e.builderBlock) == null ? void 0 : r.children) != null && l.length && e.fitContent ? /* @__PURE__ */ c(g, { children: e.children }) : null,
1174
+ !e.fitContent && e.children ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c("div", { className: "div-40c70c9b-2", children: e.children }) }) : null
1045
1175
  ] }),
1046
- /* @__PURE__ */ l("style", { children: `.img-40c70c9b {
1176
+ /* @__PURE__ */ c("style", { children: `.img-40c70c9b {
1047
1177
  opacity: 1;
1048
1178
  transition: opacity 0.2s ease-in-out;
1049
1179
  }.div-40c70c9b {
@@ -1062,8 +1192,8 @@ function Ct(e) {
1062
1192
  }` })
1063
1193
  ] });
1064
1194
  }
1065
- function wt(e) {
1066
- return /* @__PURE__ */ l(
1195
+ function $t(e) {
1196
+ return /* @__PURE__ */ c(
1067
1197
  "section",
1068
1198
  {
1069
1199
  ...e.attributes,
@@ -1083,7 +1213,7 @@ function wt(e) {
1083
1213
  }
1084
1214
  );
1085
1215
  }
1086
- const It = {
1216
+ const Vt = {
1087
1217
  name: "Core:Button",
1088
1218
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
1089
1219
  defaultStyles: {
@@ -1116,7 +1246,7 @@ const It = {
1116
1246
  }],
1117
1247
  static: !0,
1118
1248
  noWrap: !0
1119
- }, Tt = {
1249
+ }, Ft = {
1120
1250
  // TODO: ways to statically preprocess JSON for references, functions, etc
1121
1251
  name: "Columns",
1122
1252
  isRSC: !0,
@@ -1295,7 +1425,7 @@ const It = {
1295
1425
  });
1296
1426
  }
1297
1427
  const n = e.get("columns");
1298
- Array.isArray(n) && n.find((o) => o.get("width")) && (n.find((a) => !a.get("width")) || n.reduce((c, s) => c + s.get("width"), 0) !== 100) && t();
1428
+ Array.isArray(n) && n.find((o) => o.get("width")) && (n.find((a) => !a.get("width")) || n.reduce((l, s) => l + s.get("width"), 0) !== 100) && t();
1299
1429
  }
1300
1430
  }, {
1301
1431
  name: "space",
@@ -1317,7 +1447,7 @@ const It = {
1317
1447
  helperText: "When stacking columns for mobile devices, reverse the ordering",
1318
1448
  advanced: !0
1319
1449
  }]
1320
- }, Rt = {
1450
+ }, Lt = {
1321
1451
  name: "Custom Code",
1322
1452
  static: !0,
1323
1453
  requiredPermissions: ["editCode"],
@@ -1340,11 +1470,11 @@ const It = {
1340
1470
  advanced: !0
1341
1471
  }]
1342
1472
  };
1343
- function Et(e) {
1344
- const t = ee(null), [n, i] = v(() => []), [o, a] = v(() => []);
1345
- return E(() => {
1346
- var c;
1347
- if (!((c = t.current) != null && c.getElementsByTagName) || typeof window == "undefined")
1473
+ function Dt(e) {
1474
+ const t = te(null), [n, i] = k(() => []), [o, a] = k(() => []);
1475
+ return R(() => {
1476
+ var l;
1477
+ if (!((l = t.current) != null && l.getElementsByTagName) || typeof window == "undefined")
1348
1478
  return;
1349
1479
  const r = t.current.getElementsByTagName("script");
1350
1480
  for (let s = 0; s < r.length; s++) {
@@ -1353,8 +1483,8 @@ function Et(e) {
1353
1483
  if (n.includes(d.src))
1354
1484
  continue;
1355
1485
  n.push(d.src);
1356
- const m = document.createElement("script");
1357
- m.async = !0, m.src = d.src, document.head.appendChild(m);
1486
+ const u = document.createElement("script");
1487
+ u.async = !0, u.src = d.src, document.head.appendChild(u);
1358
1488
  } else if (!d.type || [
1359
1489
  "text/javascript",
1360
1490
  "application/javascript",
@@ -1364,12 +1494,12 @@ function Et(e) {
1364
1494
  continue;
1365
1495
  try {
1366
1496
  o.push(d.innerText), new Function(d.innerText)();
1367
- } catch (m) {
1368
- console.warn("`CustomCode`: Error running script:", m);
1497
+ } catch (u) {
1498
+ console.warn("`CustomCode`: Error running script:", u);
1369
1499
  }
1370
1500
  }
1371
1501
  }
1372
- }, []), /* @__PURE__ */ l(
1502
+ }, []), /* @__PURE__ */ c(
1373
1503
  "div",
1374
1504
  {
1375
1505
  ref: t,
@@ -1378,7 +1508,7 @@ function Et(e) {
1378
1508
  }
1379
1509
  );
1380
1510
  }
1381
- const Pt = {
1511
+ const Ot = {
1382
1512
  name: "Embed",
1383
1513
  static: !0,
1384
1514
  inputs: [{
@@ -1403,30 +1533,30 @@ const Pt = {
1403
1533
  defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
1404
1534
  hideFromUI: !0
1405
1535
  }]
1406
- }, Bt = ["text/javascript", "application/javascript", "application/ecmascript"], Wt = (e) => Bt.includes(e.type);
1407
- function At(e) {
1408
- const t = ee(null), [n, i] = v(() => []), [o, a] = v(() => []), [r, c] = v(() => !1);
1536
+ }, _t = ["text/javascript", "application/javascript", "application/ecmascript"], jt = (e) => _t.includes(e.type);
1537
+ function Ut(e) {
1538
+ const t = te(null), [n, i] = k(() => []), [o, a] = k(() => []), [r, l] = k(() => !1);
1409
1539
  function s() {
1410
1540
  if (!t.current || !t.current.getElementsByTagName)
1411
1541
  return;
1412
1542
  const d = t.current.getElementsByTagName("script");
1413
- for (let m = 0; m < d.length; m++) {
1414
- const g = d[m];
1415
- if (g.src && !n.includes(g.src)) {
1416
- n.push(g.src);
1417
- const k = document.createElement("script");
1418
- k.async = !0, k.src = g.src, document.head.appendChild(k);
1419
- } else if (Wt(g) && !o.includes(g.innerText))
1543
+ for (let u = 0; u < d.length; u++) {
1544
+ const h = d[u];
1545
+ if (h.src && !n.includes(h.src)) {
1546
+ n.push(h.src);
1547
+ const p = document.createElement("script");
1548
+ p.async = !0, p.src = h.src, document.head.appendChild(p);
1549
+ } else if (jt(h) && !o.includes(h.innerText))
1420
1550
  try {
1421
- o.push(g.innerText), new Function(g.innerText)();
1422
- } catch (k) {
1423
- console.warn("`Embed`: Error running script:", k);
1551
+ o.push(h.innerText), new Function(h.innerText)();
1552
+ } catch (p) {
1553
+ console.warn("`Embed`: Error running script:", p);
1424
1554
  }
1425
1555
  }
1426
1556
  }
1427
- return E(() => {
1428
- t.current && !r && (c(!0), s());
1429
- }, [t.current, r]), /* @__PURE__ */ l(
1557
+ return R(() => {
1558
+ t.current && !r && (l(!0), s());
1559
+ }, [t.current, r]), /* @__PURE__ */ c(
1430
1560
  "div",
1431
1561
  {
1432
1562
  className: "builder-embed",
@@ -1435,13 +1565,13 @@ function At(e) {
1435
1565
  }
1436
1566
  );
1437
1567
  }
1438
- const Nt = {
1568
+ const Ht = {
1439
1569
  name: "Fragment",
1440
1570
  static: !0,
1441
1571
  hidden: !0,
1442
1572
  canHaveChildren: !0,
1443
1573
  noWrap: !0
1444
- }, Vt = {
1574
+ }, Mt = {
1445
1575
  name: "Image",
1446
1576
  static: !0,
1447
1577
  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",
@@ -1461,17 +1591,17 @@ const Nt = {
1461
1591
  defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
1462
1592
  onChange: (e) => {
1463
1593
  e.delete("srcset"), e.delete("noWebp");
1464
- function n(r, c = 6e4) {
1594
+ function n(r, l = 6e4) {
1465
1595
  return new Promise((s, d) => {
1466
- const m = document.createElement("img");
1467
- let g = !1;
1468
- m.onload = () => {
1469
- g = !0, s(m);
1470
- }, m.addEventListener("error", (k) => {
1471
- console.warn("Image load failed", k.error), d(k.error);
1472
- }), m.src = r, setTimeout(() => {
1473
- g || d(new Error("Image load timed out"));
1474
- }, c);
1596
+ const u = document.createElement("img");
1597
+ let h = !1;
1598
+ u.onload = () => {
1599
+ h = !0, s(u);
1600
+ }, u.addEventListener("error", (p) => {
1601
+ console.warn("Image load failed", p.error), d(p.error);
1602
+ }), u.src = r, setTimeout(() => {
1603
+ h || d(new Error("Image load timed out"));
1604
+ }, l);
1475
1605
  });
1476
1606
  }
1477
1607
  function i(r) {
@@ -1482,8 +1612,8 @@ const Nt = {
1482
1612
  r.type.includes("svg") && e.set("noWebp", !0);
1483
1613
  }), o && (!a || a === 0.7041))
1484
1614
  return n(o).then((r) => {
1485
- const c = e.get("aspectRatio");
1486
- e.get("image") === o && (!c || c === 0.7041) && r.width && r.height && (e.set("aspectRatio", i(r.height / r.width)), e.set("height", r.height), e.set("width", r.width));
1615
+ const l = e.get("aspectRatio");
1616
+ e.get("image") === o && (!l || l === 0.7041) && r.width && r.height && (e.set("aspectRatio", i(r.height / r.width)), e.set("height", r.height), e.set("width", r.width));
1487
1617
  });
1488
1618
  }
1489
1619
  }, {
@@ -1541,7 +1671,7 @@ const Nt = {
1541
1671
  advanced: !0,
1542
1672
  defaultValue: 0.7041
1543
1673
  }]
1544
- }, $t = {
1674
+ }, Kt = {
1545
1675
  // friendlyName?
1546
1676
  name: "Raw:Img",
1547
1677
  hideFromInsertMenu: !0,
@@ -1556,8 +1686,8 @@ const Nt = {
1556
1686
  noWrap: !0,
1557
1687
  static: !0
1558
1688
  };
1559
- function Ft(e) {
1560
- return /* @__PURE__ */ l(
1689
+ function zt(e) {
1690
+ return /* @__PURE__ */ c(
1561
1691
  "img",
1562
1692
  {
1563
1693
  style: {
@@ -1571,7 +1701,7 @@ function Ft(e) {
1571
1701
  N() && e.imgSrc || "default-key"
1572
1702
  );
1573
1703
  }
1574
- const Lt = {
1704
+ const qt = {
1575
1705
  name: "Core:Section",
1576
1706
  static: !0,
1577
1707
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
@@ -1610,7 +1740,7 @@ const Lt = {
1610
1740
  }
1611
1741
  }
1612
1742
  }]
1613
- }, _t = {
1743
+ }, Yt = {
1614
1744
  name: "Slot",
1615
1745
  isRSC: !0,
1616
1746
  description: "Allow child blocks to be inserted into this content when used as a Symbol",
@@ -1624,9 +1754,9 @@ const Lt = {
1624
1754
  defaultValue: "children"
1625
1755
  }]
1626
1756
  };
1627
- function Ot(e) {
1757
+ function Qt(e) {
1628
1758
  var t, n, i;
1629
- return /* @__PURE__ */ l(
1759
+ return /* @__PURE__ */ c(
1630
1760
  "div",
1631
1761
  {
1632
1762
  style: {
@@ -1635,8 +1765,8 @@ function Ot(e) {
1635
1765
  ...!((t = e.builderContext.context) != null && t.symbolId) && {
1636
1766
  "builder-slot": e.name
1637
1767
  },
1638
- children: /* @__PURE__ */ l(
1639
- Y,
1768
+ children: /* @__PURE__ */ c(
1769
+ Q,
1640
1770
  {
1641
1771
  parent: (n = e.builderContext.context) == null ? void 0 : n.symbolId,
1642
1772
  path: `symbol.data.${e.name}`,
@@ -1647,7 +1777,7 @@ function Ot(e) {
1647
1777
  }
1648
1778
  );
1649
1779
  }
1650
- const jt = {
1780
+ const Gt = {
1651
1781
  name: "Symbol",
1652
1782
  noWrap: !0,
1653
1783
  static: !0,
@@ -1680,7 +1810,7 @@ const jt = {
1680
1810
  hideFromUI: !0,
1681
1811
  type: "boolean"
1682
1812
  }]
1683
- }, Dt = {
1813
+ }, Jt = {
1684
1814
  name: "Text",
1685
1815
  static: !0,
1686
1816
  isRSC: !0,
@@ -1699,9 +1829,9 @@ const jt = {
1699
1829
  textAlign: "center"
1700
1830
  }
1701
1831
  };
1702
- function Ut(e) {
1832
+ function Xt(e) {
1703
1833
  var t;
1704
- return /* @__PURE__ */ l(
1834
+ return /* @__PURE__ */ c(
1705
1835
  "div",
1706
1836
  {
1707
1837
  className: "builder-text",
@@ -1712,7 +1842,7 @@ function Ut(e) {
1712
1842
  }
1713
1843
  );
1714
1844
  }
1715
- const Mt = {
1845
+ const Zt = {
1716
1846
  name: "Video",
1717
1847
  canHaveChildren: !0,
1718
1848
  defaultStyles: {
@@ -1794,8 +1924,8 @@ const Mt = {
1794
1924
  advanced: !0
1795
1925
  }]
1796
1926
  };
1797
- function Ht(e) {
1798
- var i, o, a, r, c, s, d;
1927
+ function en(e) {
1928
+ var i, o, a, r, l, s, d;
1799
1929
  function t() {
1800
1930
  return {
1801
1931
  ...e.autoPlay === !0 ? {
@@ -1820,14 +1950,14 @@ function Ht(e) {
1820
1950
  ...t()
1821
1951
  };
1822
1952
  }
1823
- return /* @__PURE__ */ A(
1953
+ return /* @__PURE__ */ W(
1824
1954
  "div",
1825
1955
  {
1826
1956
  style: {
1827
1957
  position: "relative"
1828
1958
  },
1829
1959
  children: [
1830
- /* @__PURE__ */ l(
1960
+ /* @__PURE__ */ c(
1831
1961
  "video",
1832
1962
  {
1833
1963
  className: "builder-video",
@@ -1849,10 +1979,10 @@ function Ht(e) {
1849
1979
  },
1850
1980
  src: e.video || "no-src",
1851
1981
  poster: e.posterImage,
1852
- children: e.lazyLoad ? null : /* @__PURE__ */ l("source", { type: "video/mp4", src: e.video })
1982
+ children: e.lazyLoad ? null : /* @__PURE__ */ c("source", { type: "video/mp4", src: e.video })
1853
1983
  }
1854
1984
  ),
1855
- e.aspectRatio && !(e.fitContent && ((a = (o = e.builderBlock) == null ? void 0 : o.children) != null && a.length)) ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(
1985
+ e.aspectRatio && !(e.fitContent && ((a = (o = e.builderBlock) == null ? void 0 : o.children) != null && a.length)) ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
1856
1986
  "div",
1857
1987
  {
1858
1988
  style: {
@@ -1863,7 +1993,7 @@ function Ht(e) {
1863
1993
  }
1864
1994
  }
1865
1995
  ) }) : null,
1866
- (c = (r = e.builderBlock) == null ? void 0 : r.children) != null && c.length && e.fitContent ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(
1996
+ (l = (r = e.builderBlock) == null ? void 0 : r.children) != null && l.length && e.fitContent ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
1867
1997
  "div",
1868
1998
  {
1869
1999
  style: {
@@ -1874,7 +2004,7 @@ function Ht(e) {
1874
2004
  children: e.children
1875
2005
  }
1876
2006
  ) }) : null,
1877
- (d = (s = e.builderBlock) == null ? void 0 : s.children) != null && d.length && !e.fitContent ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(
2007
+ (d = (s = e.builderBlock) == null ? void 0 : s.children) != null && d.length && !e.fitContent ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
1878
2008
  "div",
1879
2009
  {
1880
2010
  style: {
@@ -1895,43 +2025,43 @@ function Ht(e) {
1895
2025
  }
1896
2026
  );
1897
2027
  }
1898
- const ye = () => [{
1899
- component: ze,
1900
- ...It
2028
+ const ve = () => [{
2029
+ component: Je,
2030
+ ...Vt
2031
+ }, {
2032
+ component: Pt,
2033
+ ...Ft
1901
2034
  }, {
1902
- component: xt,
1903
- ...Tt
2035
+ component: Dt,
2036
+ ...Lt
1904
2037
  }, {
1905
- component: Et,
1906
- ...Rt
2038
+ component: Ut,
2039
+ ...Ot
1907
2040
  }, {
1908
2041
  component: At,
1909
- ...Pt
2042
+ ...Ht
1910
2043
  }, {
1911
- component: vt,
1912
- ...Nt
2044
+ component: Nt,
2045
+ ...Mt
1913
2046
  }, {
1914
- component: Ct,
1915
- ...Vt
2047
+ component: zt,
2048
+ ...Kt
1916
2049
  }, {
1917
- component: Ft,
1918
- ...$t
2050
+ component: $t,
2051
+ ...qt
1919
2052
  }, {
1920
- component: wt,
1921
- ...Lt
2053
+ component: wn,
2054
+ ...Gt
1922
2055
  }, {
1923
- component: hn,
1924
- ...jt
2056
+ component: Xt,
2057
+ ...Jt
1925
2058
  }, {
1926
- component: Ut,
1927
- ...Dt
2059
+ component: en,
2060
+ ...Zt
1928
2061
  }, {
1929
- component: Ht,
1930
- ...Mt
1931
- }, {
1932
- component: Ot,
1933
- ..._t
1934
- }], Kt = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
2062
+ component: Qt,
2063
+ ...Yt
2064
+ }], tn = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
1935
2065
  function getAndSetVariantId() {
1936
2066
  function setCookie(name, value, days) {
1937
2067
  let expires = '';
@@ -1987,7 +2117,7 @@ const ye = () => [{
1987
2117
  }).join('');
1988
2118
  styleEl.innerHTML = newStyleStr;
1989
2119
  }
1990
- }`, zt = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
2120
+ }`, nn = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
1991
2121
  if (!navigator.cookieEnabled) {
1992
2122
  return;
1993
2123
  }
@@ -2021,27 +2151,27 @@ const ye = () => [{
2021
2151
  thisScriptEl?.remove();
2022
2152
  }
2023
2153
  return;
2024
- }`, We = "builderIoAbTest", Ae = "builderIoRenderContent", U = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
2154
+ }`, Fe = "builderIoAbTest", Le = "builderIoRenderContent", H = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
2025
2155
  ...t,
2026
2156
  testVariationId: t.id,
2027
2157
  id: e == null ? void 0 : e.id
2028
- })), qt = ({
2158
+ })), on = ({
2029
2159
  canTrack: e,
2030
2160
  content: t
2031
- }) => !(!(U(t).length > 0) || !e || V()), Yt = (e) => e === "react" || e === "reactNative", Ne = Yt($), Qt = () => `
2032
- window.${We} = ${Kt}
2033
- window.${Ae} = ${zt}
2034
- `, Gt = (e, t) => `
2035
- window.${We}(
2036
- "${t}",${JSON.stringify(e)}, ${Ne}
2037
- )`, Jt = ({
2161
+ }) => !(!(H(t).length > 0) || !e || V()), an = (e) => e === "react" || e === "reactNative", De = an(F), rn = () => `
2162
+ window.${Fe} = ${tn}
2163
+ window.${Le} = ${nn}
2164
+ `, ln = (e, t) => `
2165
+ window.${Fe}(
2166
+ "${t}",${JSON.stringify(e)}, ${De}
2167
+ )`, cn = ({
2038
2168
  contentId: e,
2039
2169
  variationId: t
2040
- }) => `window.${Ae}(
2041
- "${t}", "${e}", ${Ne}
2170
+ }) => `window.${Le}(
2171
+ "${t}", "${e}", ${De}
2042
2172
  )`;
2043
- function Z(e) {
2044
- return /* @__PURE__ */ l(
2173
+ function ee(e) {
2174
+ return /* @__PURE__ */ c(
2045
2175
  "script",
2046
2176
  {
2047
2177
  dangerouslySetInnerHTML: { __html: e.scriptStr },
@@ -2049,15 +2179,15 @@ function Z(e) {
2049
2179
  }
2050
2180
  );
2051
2181
  }
2052
- const Xt = ["*.beta.builder.io", "beta.builder.io", "builder.io", "localhost", "qa.builder.io"];
2053
- function Ve(e, t) {
2182
+ const sn = ["*.beta.builder.io", "beta.builder.io", "builder.io", "localhost", "qa.builder.io"];
2183
+ function Oe(e, t) {
2054
2184
  const n = new URL(t.origin), i = n.hostname;
2055
- return (e || Xt).findIndex((o) => o.startsWith("*.") ? i.endsWith(o.slice(1)) : o === i) > -1;
2185
+ return (e || sn).findIndex((o) => o.startsWith("*.") ? i.endsWith(o.slice(1)) : o === i) > -1;
2056
2186
  }
2057
- function Se(e) {
2187
+ function ke(e) {
2058
2188
  return Math.round(e * 1e3) / 1e3;
2059
2189
  }
2060
- const Zt = (e, t, n = !0) => {
2190
+ const dn = (e, t, n = !0) => {
2061
2191
  if (!(e instanceof HTMLElement))
2062
2192
  return null;
2063
2193
  let i = n ? e : e.parentElement;
@@ -2068,36 +2198,36 @@ const Zt = (e, t, n = !0) => {
2068
2198
  return i;
2069
2199
  } while (i = i.parentElement);
2070
2200
  return null;
2071
- }, en = (e) => Zt(e, (t) => {
2201
+ }, un = (e) => dn(e, (t) => {
2072
2202
  const n = t.getAttribute("builder-id") || t.id;
2073
2203
  return (n == null ? void 0 : n.indexOf("builder-")) === 0;
2074
- }), xe = ({
2204
+ }), Ce = ({
2075
2205
  event: e,
2076
2206
  target: t
2077
2207
  }) => {
2078
- const n = t.getBoundingClientRect(), i = e.clientX - n.left, o = e.clientY - n.top, a = Se(i / n.width), r = Se(o / n.height);
2208
+ const n = t.getBoundingClientRect(), i = e.clientX - n.left, o = e.clientY - n.top, a = ke(i / n.width), r = ke(o / n.height);
2079
2209
  return {
2080
2210
  x: a,
2081
2211
  y: r
2082
2212
  };
2083
- }, tn = (e) => {
2084
- const t = e.target, n = t && en(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
2213
+ }, mn = (e) => {
2214
+ const t = e.target, n = t && un(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
2085
2215
  return {
2086
2216
  targetBuilderElement: i || void 0,
2087
2217
  metadata: {
2088
- targetOffset: t ? xe({
2218
+ targetOffset: t ? Ce({
2089
2219
  event: e,
2090
2220
  target: t
2091
2221
  }) : void 0,
2092
- builderTargetOffset: n ? xe({
2222
+ builderTargetOffset: n ? Ce({
2093
2223
  event: e,
2094
2224
  target: n
2095
2225
  }) : void 0,
2096
2226
  builderElementIndex: n && i ? [].slice.call(document.getElementsByClassName(i)).indexOf(n) : void 0
2097
2227
  }
2098
2228
  };
2099
- }, nn = "0.12.6", on = () => {
2100
- Oe("insertMenu", {
2229
+ }, fn = "0.12.7", hn = () => {
2230
+ Me("insertMenu", {
2101
2231
  name: "_default",
2102
2232
  default: !0,
2103
2233
  items: [{
@@ -2119,14 +2249,14 @@ const Zt = (e, t, n = !0) => {
2119
2249
  }]
2120
2250
  });
2121
2251
  };
2122
- let ve = !1;
2123
- const an = (e = {}) => {
2252
+ let we = !1;
2253
+ const gn = (e = {}) => {
2124
2254
  var t, n;
2125
- ve || (ve = !0, V() && ((t = window.parent) == null || t.postMessage({
2255
+ we || (we = !0, V() && ((t = window.parent) == null || t.postMessage({
2126
2256
  type: "builder.sdkInfo",
2127
2257
  data: {
2128
- target: $,
2129
- version: nn,
2258
+ target: F,
2259
+ version: fn,
2130
2260
  supportsPatchUpdates: !1,
2131
2261
  // Supports builder-model="..." attribute which is needed to
2132
2262
  // scope our '+ add block' button styling
@@ -2140,7 +2270,7 @@ const an = (e = {}) => {
2140
2270
  }
2141
2271
  }, "*"), window.addEventListener("message", (i) => {
2142
2272
  var a, r;
2143
- if (!Ve(e.trustedHosts, i))
2273
+ if (!Oe(e.trustedHosts, i))
2144
2274
  return;
2145
2275
  const {
2146
2276
  data: o
@@ -2148,32 +2278,32 @@ const an = (e = {}) => {
2148
2278
  if (o != null && o.type)
2149
2279
  switch (o.type) {
2150
2280
  case "builder.evaluate": {
2151
- const c = o.data.text, s = o.data.arguments || [], d = o.data.id, m = new Function(c);
2152
- let g, k = null;
2281
+ const l = o.data.text, s = o.data.arguments || [], d = o.data.id, u = new Function(l);
2282
+ let h, p = null;
2153
2283
  try {
2154
- g = m.apply(null, s);
2155
- } catch (S) {
2156
- k = S;
2284
+ h = u.apply(null, s);
2285
+ } catch (b) {
2286
+ p = b;
2157
2287
  }
2158
- k ? (a = window.parent) == null || a.postMessage({
2288
+ p ? (a = window.parent) == null || a.postMessage({
2159
2289
  type: "builder.evaluateError",
2160
2290
  data: {
2161
2291
  id: d,
2162
- error: k.message
2292
+ error: p.message
2163
2293
  }
2164
- }, "*") : g && typeof g.then == "function" ? g.then((S) => {
2165
- var x;
2166
- (x = window.parent) == null || x.postMessage({
2294
+ }, "*") : h && typeof h.then == "function" ? h.then((b) => {
2295
+ var y;
2296
+ (y = window.parent) == null || y.postMessage({
2167
2297
  type: "builder.evaluateResult",
2168
2298
  data: {
2169
2299
  id: d,
2170
- result: S
2300
+ result: b
2171
2301
  }
2172
2302
  }, "*");
2173
2303
  }).catch(console.error) : (r = window.parent) == null || r.postMessage({
2174
2304
  type: "builder.evaluateResult",
2175
2305
  data: {
2176
- result: g,
2306
+ result: h,
2177
2307
  id: d
2178
2308
  }
2179
2309
  }, "*");
@@ -2182,105 +2312,109 @@ const an = (e = {}) => {
2182
2312
  }
2183
2313
  })));
2184
2314
  };
2185
- function rn(e) {
2186
- var L, Q, G, ae, re, le, ce;
2187
- const t = ee(null), [n, i] = v(() => 0);
2188
- v(() => !0);
2189
- function o(u) {
2190
- var b, y;
2315
+ function bn(e) {
2316
+ var D, G, J, se, de, ue, me;
2317
+ const t = te(null), [n, i] = k(() => 0);
2318
+ k(() => !0);
2319
+ function o(m) {
2320
+ var S, x;
2191
2321
  const f = {
2192
2322
  ...e.builderContextSignal.rootState,
2193
- ...u
2323
+ ...m
2194
2324
  };
2195
- e.builderContextSignal.rootSetState ? (y = (b = e.builderContextSignal).rootSetState) == null || y.call(b, f) : e.setBuilderContextSignal((p) => ({
2196
- ...p,
2325
+ e.builderContextSignal.rootSetState ? (x = (S = e.builderContextSignal).rootSetState) == null || x.call(S, f) : e.setBuilderContextSignal((C) => ({
2326
+ ...C,
2197
2327
  rootState: f
2198
2328
  }));
2199
2329
  }
2200
- function a(u) {
2201
- var b, y, p, T, D;
2330
+ function a(m) {
2331
+ var S, x, C, T, U;
2202
2332
  const f = {
2203
2333
  ...e.builderContextSignal.content,
2204
- ...u,
2334
+ ...m,
2205
2335
  data: {
2206
- ...(b = e.builderContextSignal.content) == null ? void 0 : b.data,
2207
- ...u == null ? void 0 : u.data
2336
+ ...(S = e.builderContextSignal.content) == null ? void 0 : S.data,
2337
+ ...m == null ? void 0 : m.data
2208
2338
  },
2209
2339
  meta: {
2210
- ...(y = e.builderContextSignal.content) == null ? void 0 : y.meta,
2211
- ...u == null ? void 0 : u.meta,
2212
- breakpoints: ((p = u == null ? void 0 : u.meta) == null ? void 0 : p.breakpoints) || ((D = (T = e.builderContextSignal.content) == null ? void 0 : T.meta) == null ? void 0 : D.breakpoints)
2340
+ ...(x = e.builderContextSignal.content) == null ? void 0 : x.meta,
2341
+ ...m == null ? void 0 : m.meta,
2342
+ breakpoints: ((C = m == null ? void 0 : m.meta) == null ? void 0 : C.breakpoints) || ((U = (T = e.builderContextSignal.content) == null ? void 0 : T.meta) == null ? void 0 : U.breakpoints)
2213
2343
  }
2214
2344
  };
2215
- e.setBuilderContextSignal((Fe) => ({
2216
- ...Fe,
2345
+ e.setBuilderContextSignal((je) => ({
2346
+ ...je,
2217
2347
  content: f
2218
2348
  }));
2219
2349
  }
2220
- v(() => 0);
2221
- const [r, c] = v(
2350
+ k(() => 0);
2351
+ const [r, l] = k(
2222
2352
  () => !1
2223
- ), [s, d] = v(
2353
+ ), [s, d] = k(
2224
2354
  () => e.contentWrapper || "div"
2225
2355
  );
2226
- function m(u) {
2227
- var b;
2228
- if (!Ve(e.trustedHosts, u))
2356
+ function u(m) {
2357
+ var S;
2358
+ if (!Oe(e.trustedHosts, m))
2229
2359
  return;
2230
- const { data: f } = u;
2360
+ const { data: f } = m;
2231
2361
  if (f)
2232
2362
  switch (f.type) {
2233
2363
  case "builder.configureSdk": {
2234
- const y = f.data, { breakpoints: p, contentId: T } = y;
2235
- if (!T || T !== ((b = e.builderContextSignal.content) == null ? void 0 : b.id))
2364
+ const x = f.data, { breakpoints: C, contentId: T } = x;
2365
+ if (!T || T !== ((S = e.builderContextSignal.content) == null ? void 0 : S.id))
2236
2366
  return;
2237
- p && a({
2367
+ C && a({
2238
2368
  meta: {
2239
- breakpoints: p
2369
+ breakpoints: C
2240
2370
  }
2241
2371
  }), i(n + 1);
2242
2372
  break;
2243
2373
  }
2374
+ case "builder.triggerAnimation": {
2375
+ Ae(f.data);
2376
+ break;
2377
+ }
2244
2378
  case "builder.contentUpdate": {
2245
- const y = f.data, p = y.key || y.alias || y.entry || y.modelName, T = y.data;
2246
- p === e.model && (a(T), i(n + 1));
2379
+ const x = f.data, C = x.key || x.alias || x.entry || x.modelName, T = x.data;
2380
+ C === e.model && (a(T), i(n + 1));
2247
2381
  break;
2248
2382
  }
2249
2383
  }
2250
2384
  }
2251
- function g() {
2252
- var f, b;
2253
- const u = (b = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : b.jsCode;
2254
- u && j({
2255
- code: u,
2385
+ function h() {
2386
+ var f, S;
2387
+ const m = (S = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : S.jsCode;
2388
+ m && j({
2389
+ code: m,
2256
2390
  context: e.context || {},
2257
2391
  localState: void 0,
2258
2392
  rootState: e.builderContextSignal.rootState,
2259
2393
  rootSetState: e.builderContextSignal.rootSetState
2260
2394
  });
2261
2395
  }
2262
- const [k, S] = v(() => ({})), [x, C] = v(() => !1);
2263
- function R(u) {
2264
- var f, b;
2396
+ const [p, b] = k(() => ({})), [y, v] = k(() => !1);
2397
+ function E(m) {
2398
+ var f, S;
2265
2399
  if (e.builderContextSignal.content) {
2266
- const y = (f = e.builderContextSignal.content) == null ? void 0 : f.testVariationId, p = (b = e.builderContextSignal.content) == null ? void 0 : b.id;
2267
- de({
2400
+ const x = (f = e.builderContextSignal.content) == null ? void 0 : f.testVariationId, C = (S = e.builderContextSignal.content) == null ? void 0 : S.id;
2401
+ he({
2268
2402
  type: "click",
2269
- canTrack: H(e.canTrack),
2270
- contentId: p,
2403
+ canTrack: K(e.canTrack),
2404
+ contentId: C,
2271
2405
  apiKey: e.apiKey,
2272
- variationId: y !== p ? y : void 0,
2273
- ...tn(u),
2274
- unique: !x
2406
+ variationId: x !== C ? x : void 0,
2407
+ ...mn(m),
2408
+ unique: !y
2275
2409
  });
2276
2410
  }
2277
- x || C(!0);
2411
+ y || v(!0);
2278
2412
  }
2279
- function B(u) {
2280
- return u.replace(
2413
+ function A(m) {
2414
+ return m.replace(
2281
2415
  /{{([^}]+)}}/g,
2282
- (f, b) => j({
2283
- code: b,
2416
+ (f, S) => j({
2417
+ code: S,
2284
2418
  context: e.context || {},
2285
2419
  localState: void 0,
2286
2420
  rootState: e.builderContextSignal.rootState,
@@ -2288,27 +2422,27 @@ function rn(e) {
2288
2422
  })
2289
2423
  );
2290
2424
  }
2291
- function w({ url: u, key: f }) {
2292
- Ue(u).then((b) => b.json()).then((b) => {
2293
- var p, T;
2294
- const y = {
2425
+ function w({ url: m, key: f }) {
2426
+ qe(m).then((S) => S.json()).then((S) => {
2427
+ var C, T;
2428
+ const x = {
2295
2429
  ...e.builderContextSignal.rootState,
2296
- [f]: b
2430
+ [f]: S
2297
2431
  };
2298
- (T = (p = e.builderContextSignal).rootSetState) == null || T.call(p, y), k[f] = !0;
2299
- }).catch((b) => {
2300
- console.error("error fetching dynamic data", u, b);
2432
+ (T = (C = e.builderContextSignal).rootSetState) == null || T.call(C, x), p[f] = !0;
2433
+ }).catch((S) => {
2434
+ console.error("error fetching dynamic data", m, S);
2301
2435
  });
2302
2436
  }
2303
2437
  function I() {
2304
- var f, b, y;
2305
- const u = (y = (b = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : b.httpRequests) != null ? y : {};
2306
- Object.entries(u).forEach(([p, T]) => {
2307
- if (T && (!k[p] || N())) {
2308
- const D = B(T);
2438
+ var f, S, x;
2439
+ const m = (x = (S = (f = e.builderContextSignal.content) == null ? void 0 : f.data) == null ? void 0 : S.httpRequests) != null ? x : {};
2440
+ Object.entries(m).forEach(([C, T]) => {
2441
+ if (T && (!p[C] || N())) {
2442
+ const U = A(T);
2309
2443
  w({
2310
- url: D,
2311
- key: p
2444
+ url: U,
2445
+ key: C
2312
2446
  });
2313
2447
  }
2314
2448
  });
@@ -2319,7 +2453,7 @@ function rn(e) {
2319
2453
  "builder:component:stateChange",
2320
2454
  {
2321
2455
  detail: {
2322
- state: te(e.builderContextSignal.rootState),
2456
+ state: ne(e.builderContextSignal.rootState),
2323
2457
  ref: {
2324
2458
  name: e.model
2325
2459
  }
@@ -2328,8 +2462,8 @@ function rn(e) {
2328
2462
  )
2329
2463
  );
2330
2464
  }
2331
- function W(u) {
2332
- i(n + 1), window.addEventListener("message", m), on(), an({
2465
+ function B(m) {
2466
+ i(n + 1), window.addEventListener("message", u), hn(), gn({
2333
2467
  ...e.locale ? {
2334
2468
  locale: e.locale
2335
2469
  } : {},
@@ -2345,19 +2479,19 @@ function rn(e) {
2345
2479
  }), Object.values(
2346
2480
  e.builderContextSignal.componentInfos
2347
2481
  ).forEach((f) => {
2348
- var y;
2349
- const b = De(f);
2350
- (y = window.parent) == null || y.postMessage(b, "*");
2482
+ var x;
2483
+ const S = ze(f);
2484
+ (x = window.parent) == null || x.postMessage(S, "*");
2351
2485
  }), window.addEventListener(
2352
2486
  "builder:component:stateChangeListenerActivated",
2353
2487
  P
2354
2488
  );
2355
2489
  }
2356
- function F(u) {
2357
- const f = new URL(location.href).searchParams, b = f.get("builder.preview"), y = f.get(
2358
- `builder.preview.${b}`
2359
- ), p = f.get("apiKey") || f.get("builder.space");
2360
- b === e.model && p === e.apiKey && (!e.content || y === e.content.id) && Ce({
2490
+ function L(m) {
2491
+ const f = new URL(location.href).searchParams, S = f.get("builder.preview"), x = f.get(
2492
+ `builder.preview.${S}`
2493
+ ), C = f.get("apiKey") || f.get("builder.space");
2494
+ S === e.model && C === e.apiKey && (!e.content || x === e.content.id) && Re({
2361
2495
  model: e.model,
2362
2496
  apiKey: e.apiKey,
2363
2497
  apiVersion: e.builderContextSignal.apiVersion
@@ -2365,88 +2499,88 @@ function rn(e) {
2365
2499
  T && a(T);
2366
2500
  });
2367
2501
  }
2368
- return E(() => {
2369
- var u;
2370
- return (u = t.current) == null || u.addEventListener(
2502
+ return R(() => {
2503
+ var m;
2504
+ return (m = t.current) == null || m.addEventListener(
2371
2505
  "initeditingbldr",
2372
- W
2506
+ B
2373
2507
  ), () => {
2374
2508
  var f;
2375
2509
  return (f = t.current) == null ? void 0 : f.removeEventListener(
2376
2510
  "initeditingbldr",
2377
- W
2511
+ B
2378
2512
  );
2379
2513
  };
2380
- }, []), E(() => {
2381
- var u;
2382
- return (u = t.current) == null || u.addEventListener(
2514
+ }, []), R(() => {
2515
+ var m;
2516
+ return (m = t.current) == null || m.addEventListener(
2383
2517
  "initpreviewingbldr",
2384
- F
2518
+ L
2385
2519
  ), () => {
2386
2520
  var f;
2387
2521
  return (f = t.current) == null ? void 0 : f.removeEventListener(
2388
2522
  "initpreviewingbldr",
2389
- F
2523
+ L
2390
2524
  );
2391
2525
  };
2392
- }, []), E(() => {
2393
- var u, f;
2526
+ }, []), R(() => {
2527
+ var m, f;
2394
2528
  if (V()) {
2395
- if (N() && t.current && t.current.dispatchEvent(new CustomEvent("initeditingbldr")), e.builderContextSignal.content && H(e.canTrack)) {
2396
- const y = (u = e.builderContextSignal.content) == null ? void 0 : u.testVariationId, p = (f = e.builderContextSignal.content) == null ? void 0 : f.id, T = e.apiKey;
2397
- de({
2529
+ if (N() && t.current && t.current.dispatchEvent(new CustomEvent("initeditingbldr")), e.builderContextSignal.content && K(e.canTrack)) {
2530
+ const x = (m = e.builderContextSignal.content) == null ? void 0 : m.testVariationId, C = (f = e.builderContextSignal.content) == null ? void 0 : f.id, T = e.apiKey;
2531
+ he({
2398
2532
  type: "impression",
2399
2533
  canTrack: !0,
2400
- contentId: p,
2534
+ contentId: C,
2401
2535
  apiKey: T,
2402
- variationId: y !== p ? y : void 0
2536
+ variationId: x !== C ? x : void 0
2403
2537
  });
2404
2538
  }
2405
- je() && t.current && t.current.dispatchEvent(new CustomEvent("initpreviewingbldr"));
2539
+ Ke() && t.current && t.current.dispatchEvent(new CustomEvent("initpreviewingbldr"));
2406
2540
  }
2407
- }, []), E(() => {
2408
- e.apiKey || _.error(
2541
+ }, []), R(() => {
2542
+ e.apiKey || O.error(
2409
2543
  "No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."
2410
- ), g(), I(), P();
2411
- }, []), E(() => {
2544
+ ), h(), I(), P();
2545
+ }, []), R(() => {
2412
2546
  e.content && a(e.content);
2413
- }, [e.content]), E(() => {
2414
- }, [r]), E(() => {
2415
- g();
2416
- }, [(Q = (L = e.builderContextSignal.content) == null ? void 0 : L.data) == null ? void 0 : Q.jsCode]), E(() => {
2547
+ }, [e.content]), R(() => {
2548
+ }, [r]), R(() => {
2549
+ h();
2550
+ }, [(G = (D = e.builderContextSignal.content) == null ? void 0 : D.data) == null ? void 0 : G.jsCode]), R(() => {
2417
2551
  I();
2418
- }, [(ae = (G = e.builderContextSignal.content) == null ? void 0 : G.data) == null ? void 0 : ae.httpRequests]), E(() => {
2552
+ }, [(se = (J = e.builderContextSignal.content) == null ? void 0 : J.data) == null ? void 0 : se.httpRequests]), R(() => {
2419
2553
  P();
2420
- }, [e.builderContextSignal.rootState]), E(() => {
2554
+ }, [e.builderContextSignal.rootState]), R(() => {
2421
2555
  e.data && o(e.data);
2422
- }, [e.data]), E(() => {
2556
+ }, [e.data]), R(() => {
2423
2557
  e.locale && o({
2424
2558
  locale: e.locale
2425
2559
  });
2426
- }, [e.locale]), E(() => () => {
2427
- V() && (window.removeEventListener("message", m), window.removeEventListener(
2560
+ }, [e.locale]), R(() => () => {
2561
+ V() && (window.removeEventListener("message", u), window.removeEventListener(
2428
2562
  "builder:component:stateChangeListenerActivated",
2429
2563
  P
2430
2564
  ));
2431
- }, []), /* @__PURE__ */ l(ie.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ Le(
2565
+ }, []), /* @__PURE__ */ c(oe.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ Ue(
2432
2566
  s,
2433
2567
  {
2434
2568
  key: n,
2435
2569
  ref: t,
2436
- onClick: (u) => R(u),
2437
- "builder-content-id": (re = e.builderContextSignal.content) == null ? void 0 : re.id,
2570
+ onClick: (m) => E(m),
2571
+ "builder-content-id": (de = e.builderContextSignal.content) == null ? void 0 : de.id,
2438
2572
  "builder-model": e.model,
2439
2573
  ...e.showContent ? {} : {
2440
2574
  hidden: !0,
2441
2575
  "aria-hidden": !0
2442
2576
  },
2443
2577
  ...e.contentWrapperProps,
2444
- className: `variant-${((le = e.content) == null ? void 0 : le.testVariationId) || ((ce = e.content) == null ? void 0 : ce.id)}`
2578
+ className: `variant-${((ue = e.content) == null ? void 0 : ue.testVariationId) || ((me = e.content) == null ? void 0 : me.id)}`
2445
2579
  },
2446
2580
  e.children
2447
2581
  ) }) : null });
2448
2582
  }
2449
- const ln = (e) => {
2583
+ const yn = (e) => {
2450
2584
  var a, r;
2451
2585
  const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (r = e.fileUrl) != null ? r : (a = e == null ? void 0 : e.files) == null ? void 0 : a.regular;
2452
2586
  let o = "";
@@ -2458,37 +2592,37 @@ font-display: fallback;
2458
2592
  font-weight: 400;
2459
2593
  }
2460
2594
  `.trim()), e.files)
2461
- for (const c in e.files) {
2462
- if (!(String(Number(c)) === c))
2595
+ for (const l in e.files) {
2596
+ if (!(String(Number(l)) === l))
2463
2597
  continue;
2464
- const d = e.files[c];
2598
+ const d = e.files[l];
2465
2599
  d && d !== i && (o += `
2466
2600
  @font-face {
2467
2601
  font-family: "${t}";
2468
2602
  src: url('${d}') format('woff2');
2469
2603
  font-display: fallback;
2470
- font-weight: ${c};
2604
+ font-weight: ${l};
2471
2605
  }
2472
2606
  `.trim());
2473
2607
  }
2474
2608
  return o;
2475
- }, cn = ({
2609
+ }, Sn = ({
2476
2610
  customFonts: e
2477
2611
  }) => {
2478
2612
  var t;
2479
- return ((t = e == null ? void 0 : e.map((n) => ln(n))) == null ? void 0 : t.join(" ")) || "";
2480
- }, sn = ({
2613
+ return ((t = e == null ? void 0 : e.map((n) => yn(n))) == null ? void 0 : t.join(" ")) || "";
2614
+ }, xn = ({
2481
2615
  cssCode: e,
2482
2616
  contentId: t
2483
2617
  }) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "";
2484
- function dn(e) {
2485
- const [t, n] = v(
2618
+ function pn(e) {
2619
+ const [t, n] = k(
2486
2620
  () => `
2487
- ${sn({
2621
+ ${xn({
2488
2622
  cssCode: e.cssCode,
2489
2623
  contentId: e.contentId
2490
2624
  })}
2491
- ${cn({
2625
+ ${Sn({
2492
2626
  customFonts: e.customFonts
2493
2627
  })}
2494
2628
 
@@ -2510,16 +2644,16 @@ ${cn({
2510
2644
  }
2511
2645
  `.trim()
2512
2646
  );
2513
- return /* @__PURE__ */ l(z, { styles: t });
2647
+ return /* @__PURE__ */ c(q, { styles: t });
2514
2648
  }
2515
- const un = ({
2649
+ const vn = ({
2516
2650
  content: e,
2517
2651
  data: t,
2518
2652
  locale: n
2519
2653
  }) => {
2520
- var a, r, c;
2654
+ var a, r, l;
2521
2655
  const i = {}, o = ((a = e == null ? void 0 : e.data) == null ? void 0 : a.state) || {};
2522
- return (c = (r = e == null ? void 0 : e.data) == null ? void 0 : r.inputs) == null || c.forEach((s) => {
2656
+ return (l = (r = e == null ? void 0 : e.data) == null ? void 0 : r.inputs) == null || l.forEach((s) => {
2523
2657
  s.name && s.defaultValue !== void 0 && (i[s.name] = s.defaultValue);
2524
2658
  }), {
2525
2659
  ...i,
@@ -2529,7 +2663,7 @@ const un = ({
2529
2663
  locale: n
2530
2664
  } : {}
2531
2665
  };
2532
- }, mn = ({
2666
+ }, kn = ({
2533
2667
  content: e,
2534
2668
  data: t
2535
2669
  }) => e ? {
@@ -2540,52 +2674,52 @@ const un = ({
2540
2674
  },
2541
2675
  meta: e == null ? void 0 : e.meta
2542
2676
  } : void 0;
2543
- function ke(e) {
2544
- var s, d, m, g, k, S, x;
2545
- const [t, n] = v(
2677
+ function Ie(e) {
2678
+ var s, d, u, h, p, b, y;
2679
+ const [t, n] = k(
2546
2680
  () => {
2547
- var C, R;
2548
- return Jt({
2681
+ var v, E;
2682
+ return cn({
2549
2683
  // eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
2550
- variationId: (C = e.content) == null ? void 0 : C.testVariationId,
2684
+ variationId: (v = e.content) == null ? void 0 : v.testVariationId,
2551
2685
  // eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
2552
- contentId: (R = e.content) == null ? void 0 : R.id
2686
+ contentId: (E = e.content) == null ? void 0 : E.id
2553
2687
  });
2554
2688
  }
2555
2689
  );
2556
- function i(C) {
2557
- c((R) => ({
2558
- ...R,
2559
- rootState: C
2690
+ function i(v) {
2691
+ l((E) => ({
2692
+ ...E,
2693
+ rootState: v
2560
2694
  }));
2561
2695
  }
2562
- const [o, a] = v(
2696
+ const [o, a] = k(
2563
2697
  () => [
2564
- ...ye(),
2698
+ ...ve(),
2565
2699
  // While this `components` object is deprecated, we must maintain support for it.
2566
2700
  // Since users are able to override our default components, we need to make sure that we do not break such
2567
2701
  // existing usage.
2568
2702
  // This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
2569
2703
  // which is the new standard way of providing custom components, and must therefore take precedence.
2570
- ...ue,
2704
+ ...ge,
2571
2705
  ...e.customComponents || []
2572
2706
  ].reduce(
2573
- (C, { component: R, ...B }) => ({
2574
- ...C,
2575
- [B.name]: {
2576
- component: R,
2577
- ...me(B)
2707
+ (v, { component: E, ...A }) => ({
2708
+ ...v,
2709
+ [A.name]: {
2710
+ component: E,
2711
+ ...be(A)
2578
2712
  }
2579
2713
  }),
2580
2714
  {}
2581
2715
  )
2582
- ), [r, c] = v(() => ({
2583
- content: mn({
2716
+ ), [r, l] = k(() => ({
2717
+ content: kn({
2584
2718
  content: e.content,
2585
2719
  data: e.data
2586
2720
  }),
2587
2721
  localState: void 0,
2588
- rootState: un({
2722
+ rootState: vn({
2589
2723
  content: e.content,
2590
2724
  data: e.data,
2591
2725
  locale: e.locale
@@ -2595,18 +2729,18 @@ function ke(e) {
2595
2729
  apiKey: e.apiKey,
2596
2730
  apiVersion: e.apiVersion,
2597
2731
  componentInfos: [
2598
- ...ye(),
2732
+ ...ve(),
2599
2733
  // While this `components` object is deprecated, we must maintain support for it.
2600
2734
  // Since users are able to override our default components, we need to make sure that we do not break such
2601
2735
  // existing usage.
2602
2736
  // This is why we spread `components` after the default Builder.io components, but before the `props.customComponents`,
2603
2737
  // which is the new standard way of providing custom components, and must therefore take precedence.
2604
- ...ue,
2738
+ ...ge,
2605
2739
  ...e.customComponents || []
2606
2740
  ].reduce(
2607
- (C, { component: R, ...B }) => ({
2608
- ...C,
2609
- [B.name]: me(B)
2741
+ (v, { component: E, ...A }) => ({
2742
+ ...v,
2743
+ [A.name]: be(A)
2610
2744
  }),
2611
2745
  {}
2612
2746
  ),
@@ -2614,14 +2748,14 @@ function ke(e) {
2614
2748
  BlocksWrapper: e.blocksWrapper || "div",
2615
2749
  BlocksWrapperProps: e.blocksWrapperProps || {}
2616
2750
  }));
2617
- return /* @__PURE__ */ l(
2618
- we.Provider,
2751
+ return /* @__PURE__ */ c(
2752
+ Ee.Provider,
2619
2753
  {
2620
2754
  value: {
2621
2755
  registeredComponents: o
2622
2756
  },
2623
- children: /* @__PURE__ */ A(
2624
- rn,
2757
+ children: /* @__PURE__ */ W(
2758
+ bn,
2625
2759
  {
2626
2760
  content: e.content,
2627
2761
  data: e.data,
@@ -2638,21 +2772,21 @@ function ke(e) {
2638
2772
  contentWrapperProps: e.contentWrapperProps,
2639
2773
  linkComponent: e.linkComponent,
2640
2774
  trustedHosts: e.trustedHosts,
2641
- setBuilderContextSignal: c,
2775
+ setBuilderContextSignal: l,
2642
2776
  children: [
2643
- e.isSsrAbTest ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(Z, { scriptStr: t }) }) : null,
2644
- /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(
2645
- dn,
2777
+ e.isSsrAbTest ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(ee, { scriptStr: t }) }) : null,
2778
+ /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(
2779
+ pn,
2646
2780
  {
2647
2781
  contentId: (s = r.content) == null ? void 0 : s.id,
2648
- cssCode: (m = (d = r.content) == null ? void 0 : d.data) == null ? void 0 : m.cssCode,
2649
- customFonts: (k = (g = r.content) == null ? void 0 : g.data) == null ? void 0 : k.customFonts
2782
+ cssCode: (u = (d = r.content) == null ? void 0 : d.data) == null ? void 0 : u.cssCode,
2783
+ customFonts: (p = (h = r.content) == null ? void 0 : h.data) == null ? void 0 : p.customFonts
2650
2784
  }
2651
2785
  ) }),
2652
- /* @__PURE__ */ l(
2653
- Y,
2786
+ /* @__PURE__ */ c(
2787
+ Q,
2654
2788
  {
2655
- blocks: (x = (S = r.content) == null ? void 0 : S.data) == null ? void 0 : x.blocks,
2789
+ blocks: (y = (b = r.content) == null ? void 0 : b.data) == null ? void 0 : y.blocks,
2656
2790
  context: r,
2657
2791
  registeredComponents: o,
2658
2792
  linkComponent: e.linkComponent
@@ -2664,18 +2798,18 @@ function ke(e) {
2664
2798
  }
2665
2799
  );
2666
2800
  }
2667
- function $e(e) {
2668
- var r, c;
2669
- const [t, n] = v(
2670
- () => qt({
2671
- canTrack: H(e.canTrack),
2801
+ function _e(e) {
2802
+ var r, l;
2803
+ const [t, n] = k(
2804
+ () => on({
2805
+ canTrack: K(e.canTrack),
2672
2806
  content: e.content
2673
2807
  })
2674
2808
  );
2675
2809
  function i() {
2676
2810
  var s;
2677
- return Gt(
2678
- U(e.content).map((d) => ({
2811
+ return ln(
2812
+ H(e.content).map((d) => ({
2679
2813
  id: d.testVariationId,
2680
2814
  testRatio: d.testRatio
2681
2815
  })),
@@ -2683,32 +2817,32 @@ function $e(e) {
2683
2817
  );
2684
2818
  }
2685
2819
  function o() {
2686
- return U(e.content).map((s) => `.variant-${s.testVariationId} { display: none; } `).join("");
2820
+ return H(e.content).map((s) => `.variant-${s.testVariationId} { display: none; } `).join("");
2687
2821
  }
2688
2822
  function a() {
2689
2823
  var s;
2690
2824
  return t ? {
2691
2825
  ...e.content,
2692
2826
  testVariationId: (s = e.content) == null ? void 0 : s.id
2693
- } : Me({
2827
+ } : Ye({
2694
2828
  item: e.content,
2695
- canTrack: H(e.canTrack)
2829
+ canTrack: K(e.canTrack)
2696
2830
  });
2697
2831
  }
2698
- return E(() => {
2699
- }, []), /* @__PURE__ */ A(h, { children: [
2700
- !e.__isNestedRender && $ !== "reactNative" ? /* @__PURE__ */ l(h, { children: /* @__PURE__ */ l(Z, { scriptStr: Qt() }) }) : null,
2701
- t ? /* @__PURE__ */ A(h, { children: [
2702
- /* @__PURE__ */ l(
2703
- z,
2832
+ return R(() => {
2833
+ }, []), /* @__PURE__ */ W(g, { children: [
2834
+ !e.__isNestedRender && F !== "reactNative" ? /* @__PURE__ */ c(g, { children: /* @__PURE__ */ c(ee, { scriptStr: rn() }) }) : null,
2835
+ t ? /* @__PURE__ */ W(g, { children: [
2836
+ /* @__PURE__ */ c(
2837
+ q,
2704
2838
  {
2705
2839
  id: `variants-styles-${(r = e.content) == null ? void 0 : r.id}`,
2706
2840
  styles: o()
2707
2841
  }
2708
2842
  ),
2709
- /* @__PURE__ */ l(Z, { scriptStr: i() }),
2710
- (c = U(e.content)) == null ? void 0 : c.map((s) => /* @__PURE__ */ l(
2711
- ke,
2843
+ /* @__PURE__ */ c(ee, { scriptStr: i() }),
2844
+ (l = H(e.content)) == null ? void 0 : l.map((s) => /* @__PURE__ */ c(
2845
+ Ie,
2712
2846
  {
2713
2847
  content: s,
2714
2848
  showContent: !1,
@@ -2733,8 +2867,8 @@ function $e(e) {
2733
2867
  s.testVariationId
2734
2868
  ))
2735
2869
  ] }) : null,
2736
- /* @__PURE__ */ l(
2737
- ke,
2870
+ /* @__PURE__ */ c(
2871
+ Ie,
2738
2872
  {
2739
2873
  content: a(),
2740
2874
  showContent: !0,
@@ -2759,13 +2893,13 @@ function $e(e) {
2759
2893
  )
2760
2894
  ] });
2761
2895
  }
2762
- const fn = async ({
2896
+ const Cn = async ({
2763
2897
  builderContextValue: e,
2764
2898
  symbol: t
2765
2899
  }) => {
2766
2900
  if (t != null && t.model && // This is a hack, we should not need to check for this, but it is needed for Svelte.
2767
2901
  (e != null && e.apiKey))
2768
- return Ce({
2902
+ return Re({
2769
2903
  model: t.model,
2770
2904
  apiKey: e.apiKey,
2771
2905
  apiVersion: e.apiVersion,
@@ -2775,37 +2909,37 @@ const fn = async ({
2775
2909
  }
2776
2910
  }
2777
2911
  }).catch((n) => {
2778
- _.error("Could not fetch symbol content: ", n);
2912
+ O.error("Could not fetch symbol content: ", n);
2779
2913
  });
2780
2914
  };
2781
- function hn(e) {
2782
- var a, r, c, s;
2915
+ function wn(e) {
2916
+ var a, r, l, s;
2783
2917
  function t() {
2784
- var d, m;
2918
+ var d, u;
2785
2919
  return [
2786
- e.attributes[O()],
2920
+ e.attributes[_()],
2787
2921
  "builder-symbol",
2788
2922
  (d = e.symbol) != null && d.inline ? "builder-inline-symbol" : void 0,
2789
- (m = e.symbol) != null && m.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
2923
+ (u = e.symbol) != null && u.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
2790
2924
  ].filter(Boolean).join(" ");
2791
2925
  }
2792
- const [n, i] = v(() => {
2926
+ const [n, i] = k(() => {
2793
2927
  var d;
2794
2928
  return (d = e.symbol) == null ? void 0 : d.content;
2795
2929
  });
2796
2930
  function o() {
2797
- n || fn({
2931
+ n || Cn({
2798
2932
  symbol: e.symbol,
2799
2933
  builderContextValue: e.builderContext
2800
2934
  }).then((d) => {
2801
2935
  d && i(d);
2802
2936
  });
2803
2937
  }
2804
- return E(() => {
2805
- }, []), E(() => {
2938
+ return R(() => {
2939
+ }, []), R(() => {
2806
2940
  o();
2807
- }, [e.symbol]), /* @__PURE__ */ l("div", { ...e.attributes, className: t(), children: /* @__PURE__ */ l(
2808
- $e,
2941
+ }, [e.symbol]), /* @__PURE__ */ c("div", { ...e.attributes, className: t(), children: /* @__PURE__ */ c(
2942
+ _e,
2809
2943
  {
2810
2944
  __isNestedRender: !0,
2811
2945
  apiVersion: e.builderContext.apiVersion,
@@ -2818,7 +2952,7 @@ function hn(e) {
2818
2952
  data: {
2819
2953
  ...(r = e.symbol) == null ? void 0 : r.data,
2820
2954
  ...e.builderContext.localState,
2821
- ...(c = n == null ? void 0 : n.data) == null ? void 0 : c.state
2955
+ ...(l = n == null ? void 0 : n.data) == null ? void 0 : l.state
2822
2956
  },
2823
2957
  model: (s = e.symbol) == null ? void 0 : s.model,
2824
2958
  content: n,
@@ -2826,31 +2960,31 @@ function hn(e) {
2826
2960
  }
2827
2961
  ) });
2828
2962
  }
2829
- const Sn = Y, xn = $e;
2963
+ const En = Q, Pn = _e;
2830
2964
  export {
2831
- Y as Blocks,
2832
- ze as Button,
2833
- xt as Columns,
2834
- $e as Content,
2835
- vt as Fragment,
2836
- Ct as Image,
2837
- Sn as RenderBlocks,
2838
- xn as RenderContent,
2839
- wt as Section,
2840
- hn as Symbol,
2841
- Ut as Text,
2842
- Ht as Video,
2843
- pn as _processContentResult,
2844
- De as createRegisterComponentMessage,
2845
- Cn as fetchBuilderProps,
2846
- wn as fetchEntries,
2847
- Ce as fetchOneEntry,
2848
- In as getAllContent,
2849
- Tn as getBuilderSearchParams,
2850
- Rn as getContent,
2965
+ Q as Blocks,
2966
+ Je as Button,
2967
+ Pt as Columns,
2968
+ _e as Content,
2969
+ At as Fragment,
2970
+ Nt as Image,
2971
+ En as RenderBlocks,
2972
+ Pn as RenderContent,
2973
+ $t as Section,
2974
+ wn as Symbol,
2975
+ Xt as Text,
2976
+ en as Video,
2977
+ Wn as _processContentResult,
2978
+ ze as createRegisterComponentMessage,
2979
+ Nn as fetchBuilderProps,
2980
+ $n as fetchEntries,
2981
+ Re as fetchOneEntry,
2982
+ Vn as getAllContent,
2983
+ Fn as getBuilderSearchParams,
2984
+ Ln as getContent,
2851
2985
  N as isEditing,
2852
- je as isPreviewing,
2853
- Oe as register,
2854
- En as setEditorSettings,
2855
- Pn as track
2986
+ Ke as isPreviewing,
2987
+ Me as register,
2988
+ Dn as setEditorSettings,
2989
+ On as track
2856
2990
  };