@builder.io/sdk-react 3.0.5 → 3.0.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.
Files changed (81) hide show
  1. package/lib/browser/blocks-exports.cjs +167 -30
  2. package/lib/browser/blocks-exports.mjs +1370 -931
  3. package/lib/browser/index.cjs +1 -1
  4. package/lib/browser/index.mjs +17 -16
  5. package/lib/{edge/server-entry-67bfc740.js → browser/server-entry-20c79b90.js} +319 -274
  6. package/lib/browser/server-entry-762e29e0.cjs +2 -0
  7. package/lib/browser/server-entry.cjs +1 -1
  8. package/lib/browser/server-entry.mjs +1 -1
  9. package/lib/edge/{accordion-190c4426.cjs → accordion-071aa4f9.cjs} +1 -1
  10. package/lib/edge/{accordion-cd6e0363.js → accordion-22c2c037.js} +1 -1
  11. package/lib/edge/{blocks-fe2d7c1a.js → blocks-2989e629.js} +1343 -1318
  12. package/lib/edge/blocks-d3f37507.cjs +30 -0
  13. package/lib/edge/blocks-exports.cjs +1 -1
  14. package/lib/edge/blocks-exports.mjs +13 -12
  15. package/lib/edge/{button-6a27481c.js → button-2b5270c4.js} +2 -2
  16. package/lib/edge/{button-694fcd4f.cjs → button-a2cc6565.cjs} +1 -1
  17. package/lib/edge/{columns-90e6407e.js → columns-21b9be25.js} +3 -3
  18. package/lib/edge/{columns-b38bf0f7.cjs → columns-b7240242.cjs} +1 -1
  19. package/lib/edge/{content-variants-cbb89349.js → content-variants-88f4dc64.js} +165 -124
  20. package/lib/edge/content-variants-fdd5ee50.cjs +134 -0
  21. package/lib/edge/dynamic-blocks-exports.cjs +3 -1
  22. package/lib/edge/dynamic-blocks-exports.mjs +5 -2
  23. package/lib/edge/{form-547645eb.cjs → form-77687883.cjs} +1 -1
  24. package/lib/edge/{form-16bbf874.js → form-d29f3cc0.js} +3 -3
  25. package/lib/edge/{get-class-prop-name-8b719c6b.js → get-class-prop-name-dbc5d99c.js} +1 -1
  26. package/lib/edge/{get-class-prop-name-58770197.cjs → get-class-prop-name-f597545d.cjs} +1 -1
  27. package/lib/edge/{img-8859c851.cjs → img-03f9002b.cjs} +1 -1
  28. package/lib/edge/{img-d3351743.js → img-fed70928.js} +1 -1
  29. package/lib/edge/index.cjs +1 -1
  30. package/lib/edge/index.mjs +18 -17
  31. package/lib/edge/{input-24c601b4.js → input-083c3c35.js} +1 -1
  32. package/lib/edge/{input-4fe0fc6d.cjs → input-1e548fd0.cjs} +1 -1
  33. package/lib/edge/personalization-container-bcff3433.js +384 -0
  34. package/lib/edge/personalization-container-dde10a09.cjs +138 -0
  35. package/lib/edge/{select-c73bd418.cjs → select-21e33225.cjs} +1 -1
  36. package/lib/edge/{select-af05377b.js → select-9f22c2ba.js} +1 -1
  37. package/lib/{browser/server-entry-785c0408.js → edge/server-entry-43a6f5be.js} +339 -298
  38. package/lib/edge/server-entry-ac35a5c8.cjs +2 -0
  39. package/lib/edge/server-entry.cjs +1 -1
  40. package/lib/edge/server-entry.mjs +1 -1
  41. package/lib/edge/{slot-759c8dd9.cjs → slot-a9f5d6c0.cjs} +1 -1
  42. package/lib/edge/{slot-32a4df0c.js → slot-ca171e8c.js} +3 -3
  43. package/lib/edge/{symbol-50360a37.js → symbol-8f6ff028.js} +2 -2
  44. package/lib/edge/{symbol-8d63aa7d.cjs → symbol-a2015c7e.cjs} +1 -1
  45. package/lib/edge/{tabs-6535c934.js → tabs-6b67fca2.js} +3 -3
  46. package/lib/edge/{tabs-fc6c1700.cjs → tabs-880c9088.cjs} +1 -1
  47. package/lib/node/blocks-exports.cjs +168 -31
  48. package/lib/node/blocks-exports.mjs +1343 -904
  49. package/lib/node/index.cjs +1 -1
  50. package/lib/node/index.mjs +17 -16
  51. package/lib/node/init.cjs +1 -1
  52. package/lib/node/init.mjs +3 -3
  53. package/lib/node/server-entry-0b433783.cjs +2 -0
  54. package/lib/node/{server-entry-ffc70868.js → server-entry-6626257d.js} +280 -237
  55. package/lib/node/server-entry.cjs +1 -1
  56. package/lib/node/server-entry.mjs +1 -1
  57. package/lib/node/{setIvm-4ce0db03.cjs → setIvm-49abbae6.cjs} +1 -1
  58. package/lib/node/{setIvm-2cea7252.js → setIvm-5cb298bf.js} +1 -1
  59. package/lib/node/setIvm.cjs +1 -1
  60. package/lib/node/setIvm.mjs +2 -2
  61. package/lib/node/{should-force-browser-runtime-in-node-d3e6df07.cjs → should-force-browser-runtime-in-node-11e8399e.cjs} +1 -1
  62. package/lib/node/{should-force-browser-runtime-in-node-c0d50009.js → should-force-browser-runtime-in-node-94f1a5b3.js} +1 -1
  63. package/package.json +1 -1
  64. package/types/blocks/personalization-container/component-info.d.ts +2 -0
  65. package/types/blocks/personalization-container/helpers/inlined-fns.d.ts +8 -0
  66. package/types/blocks/personalization-container/helpers.d.ts +27 -0
  67. package/types/blocks/personalization-container/index.d.ts +1 -0
  68. package/types/blocks/personalization-container/personalization-container.d.ts +4 -0
  69. package/types/blocks/personalization-container/personalization-container.types.d.ts +14 -0
  70. package/types/constants/device-sizes.d.ts +3 -2
  71. package/types/constants/sdk-version.d.ts +1 -1
  72. package/types/helpers/user-attributes.d.ts +17 -0
  73. package/types/index-helpers/blocks-exports.d.ts +1 -0
  74. package/types/types/builder-block.d.ts +0 -1
  75. package/types/types/builder-content.d.ts +1 -0
  76. package/types/types/input.d.ts +1 -0
  77. package/lib/browser/server-entry-101d66b8.cjs +0 -2
  78. package/lib/edge/blocks-766e8d45.cjs +0 -30
  79. package/lib/edge/content-variants-4e385c19.cjs +0 -134
  80. package/lib/edge/server-entry-3c7fa63a.cjs +0 -2
  81. package/lib/node/server-entry-95273908.cjs +0 -2
@@ -1,16 +1,17 @@
1
1
  "use client";
2
- import { jsx as s, Fragment as E, jsxs as B } from "react/jsx-runtime";
3
- import { TARGET as $, isBrowser as j, logger as oe, checkIsDefined as te, isPreviewing as ae, isEditing as N, logFetch as Te, registerInsertMenu as je, setupBrowserForEditing as qe, createRegisterComponentMessage as ze, getDefaultCanTrack as q, _track as ue, fetchOneEntry as Ie, createEditorListener as Ke, serializeIncludingFunctions as me, handleABTestingSync as Je } from "./server-entry-ffc70868.js";
4
- import * as Ge from "react";
5
- import { createContext as we, useEffect as A, useState as R, useRef as L, useContext as fe, createElement as Ee } from "react";
6
- import { getFunctionArguments as Ye, flattenState as Qe, runInNode as Xe, parseCode as Ze, getBuilderGlobals as et, set as Re, fastClone as re } from "./setIvm-2cea7252.js";
7
- import { shouldForceBrowserRuntimeInNode as tt } from "./should-force-browser-runtime-in-node-c0d50009.js";
8
- const nt = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), it = (e) => typeof e == "string" && nt.has(e.toLowerCase());
9
- function le(e) {
10
- return /* @__PURE__ */ s(E, { children: it(e.TagName) ? /* @__PURE__ */ s(E, { children: /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ s(E, { children: typeof e.TagName == "string" ? /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) : /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) });
2
+ import { TARGET as F, isBrowser as L, logger as re, checkIsDefined as ae, isPreviewing as G, isEditing as W, userAttributesService as me, getDefaultCanTrack as q, logFetch as we, registerInsertMenu as je, setupBrowserForEditing as ze, createRegisterComponentMessage as Ke, _track as fe, fetchOneEntry as Ie, createEditorListener as Je, serializeIncludingFunctions as he, handleABTestingSync as Ge } from "./server-entry-6626257d.js";
3
+ import { setClientUserAttributes as ki } from "./server-entry-6626257d.js";
4
+ import { jsx as s, Fragment as R, jsxs as V } from "react/jsx-runtime";
5
+ import * as Qe from "react";
6
+ import { createContext as Ee, useEffect as A, useState as E, useRef as D, useContext as ge, createElement as Re } from "react";
7
+ import { getFunctionArguments as Ye, flattenState as Xe, runInNode as Ze, parseCode as et, getBuilderGlobals as tt, set as Pe, fastClone as le } from "./setIvm-5cb298bf.js";
8
+ import { shouldForceBrowserRuntimeInNode as nt } from "./should-force-browser-runtime-in-node-94f1a5b3.js";
9
+ const it = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), at = (e) => typeof e == "string" && it.has(e.toLowerCase());
10
+ function se(e) {
11
+ return /* @__PURE__ */ s(R, { children: at(e.TagName) ? /* @__PURE__ */ s(R, { children: /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ s(R, { children: typeof e.TagName == "string" ? /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) : /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) });
11
12
  }
12
- const U = () => {
13
- switch ($) {
13
+ const H = () => {
14
+ switch (F) {
14
15
  case "react":
15
16
  case "reactNative":
16
17
  case "rsc":
@@ -27,7 +28,7 @@ function ot(e) {
27
28
  function t() {
28
29
  return {
29
30
  ...e.attributes,
30
- [U()]: `${e.link ? "" : "builder-button"} ${e.attributes[U()] || ""}`,
31
+ [H()]: `${e.link ? "" : "builder-button"} ${e.attributes[H()] || ""}`,
31
32
  ...e.link ? {
32
33
  href: e.link,
33
34
  target: e.openLinkInNewTab ? "_blank" : void 0,
@@ -38,7 +39,7 @@ function ot(e) {
38
39
  };
39
40
  }
40
41
  return /* @__PURE__ */ s(
41
- le,
42
+ se,
42
43
  {
43
44
  attributes: t(),
44
45
  TagName: e.link ? e.builderLinkComponent || "a" : "button",
@@ -47,7 +48,7 @@ function ot(e) {
47
48
  }
48
49
  );
49
50
  }
50
- const se = we({
51
+ const ce = Ee({
51
52
  content: null,
52
53
  context: {},
53
54
  localState: void 0,
@@ -62,67 +63,67 @@ const se = we({
62
63
  BlocksWrapperProps: {},
63
64
  nonce: "",
64
65
  model: ""
65
- }), Pe = we({ registeredComponents: {} }), Be = (e, t, n) => {
66
- const i = String.prototype.split.call(t, /[,[\].]+?/).filter(Boolean).reduce((o, r) => o != null ? o[r] : o, e);
66
+ }), Ve = Ee({ registeredComponents: {} }), Be = (e, t, n) => {
67
+ const i = String.prototype.split.call(t, /[,[\].]+?/).filter(Boolean).reduce((a, r) => a != null ? a[r] : a, e);
67
68
  return i === void 0 || i === e ? n : i;
68
- }, at = ({
69
+ }, rt = ({
69
70
  code: e,
70
71
  builder: t,
71
72
  context: n,
72
73
  event: i,
73
- localState: o,
74
+ localState: a,
74
75
  rootSetState: r,
75
- rootState: a
76
+ rootState: o
76
77
  }) => {
77
78
  const l = Ye({
78
79
  builder: t,
79
80
  context: n,
80
81
  event: i,
81
- state: Qe({
82
- rootState: a,
83
- localState: o,
82
+ state: Xe({
83
+ rootState: o,
84
+ localState: a,
84
85
  rootSetState: r
85
86
  })
86
87
  });
87
- return new Function(...l.map(([d]) => d), e)(...l.map(([, d]) => d));
88
- }, rt = (e) => j() || tt({
88
+ return new Function(...l.map(([u]) => u), e)(...l.map(([, u]) => u));
89
+ }, lt = (e) => L() || nt({
89
90
  shouldLogWarning: !0
90
- }) ? at(e) : Xe(e), lt = /^(return )?(\s*)?state(?<getPath>(\.\w+)+)(\s*);?$/, st = /(\s)*var(\s)+_virtual_index(\s)*=(\s)*state(?<getPath>(\.\w+)+)(\s*);?(\s)*return(\s)*_virtual_index(\s)*/, ct = (e) => {
91
- var t, n, i, o, r, a;
92
- return ((i = (n = (t = lt.exec(e.trim())) == null ? void 0 : t.groups) == null ? void 0 : n.getPath) == null ? void 0 : i.slice(1)) || ((a = (r = (o = st.exec(e.trim())) == null ? void 0 : o.groups) == null ? void 0 : r.getPath) == null ? void 0 : a.slice(1));
91
+ }) ? rt(e) : Ze(e), st = /^(return )?(\s*)?state(?<getPath>(\.\w+)+)(\s*);?$/, ct = /(\s)*var(\s)+_virtual_index(\s)*=(\s)*state(?<getPath>(\.\w+)+)(\s*);?(\s)*return(\s)*_virtual_index(\s)*/, ut = (e) => {
92
+ var t, n, i, a, r, o;
93
+ return ((i = (n = (t = st.exec(e.trim())) == null ? void 0 : t.groups) == null ? void 0 : n.getPath) == null ? void 0 : i.slice(1)) || ((o = (r = (a = ct.exec(e.trim())) == null ? void 0 : a.groups) == null ? void 0 : r.getPath) == null ? void 0 : o.slice(1));
93
94
  };
94
- function D({
95
+ function O({
95
96
  code: e,
96
97
  context: t,
97
98
  localState: n,
98
99
  rootState: i,
99
- rootSetState: o,
100
+ rootSetState: a,
100
101
  event: r,
101
- isExpression: a = !0
102
+ isExpression: o = !0
102
103
  }) {
103
104
  if (e.trim() === "")
104
105
  return;
105
- const l = ct(e.trim());
106
+ const l = ut(e.trim());
106
107
  if (l)
107
108
  return Be({
108
109
  ...i,
109
110
  ...n
110
111
  }, l);
111
- const d = {
112
- code: Ze(e, {
113
- isExpression: a
112
+ const u = {
113
+ code: et(e, {
114
+ isExpression: o
114
115
  }),
115
- builder: et(),
116
+ builder: tt(),
116
117
  context: t,
117
118
  event: r,
118
- rootSetState: o,
119
+ rootSetState: a,
119
120
  rootState: i,
120
121
  localState: n
121
122
  };
122
123
  try {
123
- return rt(d);
124
+ return lt(u);
124
125
  } catch (c) {
125
- oe.error("Failed code evaluation: " + c.message, {
126
+ re.error("Failed code evaluation: " + c.message, {
126
127
  code: e
127
128
  });
128
129
  return;
@@ -133,15 +134,15 @@ function dt(e, t) {
133
134
  return {
134
135
  ...(n = e.component) == null ? void 0 : n.options,
135
136
  ...e.options,
136
- ...ut(e, t)
137
+ ...mt(e, t)
137
138
  };
138
139
  }
139
- const ut = (e, t) => {
140
+ const mt = (e, t) => {
140
141
  var n, i;
141
142
  if (((n = e.component) == null ? void 0 : n.name) === "Text" && ((i = e.component.options) != null && i.text) && typeof e.component.options.text == "string")
142
143
  return {
143
144
  ...e.component.options,
144
- text: e.component.options.text.replace(/{{([^}]+)}}/g, (o, r) => D({
145
+ text: e.component.options.text.replace(/{{([^}]+)}}/g, (a, r) => O({
145
146
  code: r,
146
147
  context: t,
147
148
  localState: t.localState,
@@ -150,68 +151,68 @@ const ut = (e, t) => {
150
151
  }))
151
152
  };
152
153
  };
153
- function mt(e, ...t) {
154
+ function ft(e, ...t) {
154
155
  const n = Object.assign({}, e);
155
156
  for (const i of t)
156
157
  delete n[i];
157
158
  return n;
158
159
  }
159
- function z(e, t, n = null, i = null, o = /* @__PURE__ */ new WeakSet()) {
160
+ function K(e, t, n = null, i = null, a = /* @__PURE__ */ new WeakSet()) {
160
161
  if (e == null || typeof e != "object") {
161
162
  t(e, (r) => {
162
163
  n !== null && i !== null && (n[i] = r);
163
164
  });
164
165
  return;
165
166
  }
166
- o.has(e) || (o.add(e), Array.isArray(e) ? e.forEach((r, a) => {
167
- t(r, (d) => {
168
- e[a] = d;
169
- }), z(r, t, e, a, o);
170
- }) : Object.entries(e).forEach(([r, a]) => {
171
- t(a, (d) => {
172
- e[r] = d;
173
- }), z(a, t, e, r, o);
167
+ a.has(e) || (a.add(e), Array.isArray(e) ? e.forEach((r, o) => {
168
+ t(r, (u) => {
169
+ e[o] = u;
170
+ }), K(r, t, e, o, a);
171
+ }) : Object.entries(e).forEach(([r, o]) => {
172
+ t(o, (u) => {
173
+ e[r] = u;
174
+ }), K(o, t, e, r, a);
174
175
  }));
175
176
  }
176
- function Ve(e) {
177
+ function Ae(e) {
177
178
  return e && typeof e == "object" && e["@type"] === "@builder.io/core:LocalizedValue";
178
179
  }
179
- function ft(e) {
180
+ function ht(e) {
180
181
  if (!e || !Object.getOwnPropertyNames(e).length)
181
182
  return !1;
182
183
  let t = !1;
183
- return z(e, (n) => {
184
- if (Ve(n)) {
184
+ return K(e, (n) => {
185
+ if (Ae(n)) {
185
186
  t = !0;
186
187
  return;
187
188
  }
188
189
  }), t;
189
190
  }
190
- function ht(e, t) {
191
- return !e || !Object.getOwnPropertyNames(e).length ? {} : (z(e, (n, i) => {
192
- var o;
193
- Ve(n) && i((o = n[t]) != null ? o : void 0);
191
+ function gt(e, t) {
192
+ return !e || !Object.getOwnPropertyNames(e).length ? {} : (K(e, (n, i) => {
193
+ var a;
194
+ Ae(n) && i((a = n[t]) != null ? a : void 0);
194
195
  }), e);
195
196
  }
196
- function gt(e, t) {
197
+ function bt(e, t) {
197
198
  var n, i;
198
- return (n = e.component) != null && n.options && ft((i = e.component) == null ? void 0 : i.options) && (t || console.warn("[Builder.io] In order to use localized fields in Builder, you must pass a locale prop to the BuilderComponent or to options object while fetching the content to resolve localized fields. Learn more: https://www.builder.io/c/docs/localization-inline#targeting-and-inline-localization"), e.component.options = ht(e.component.options, t != null ? t : "Default")), e;
199
+ return (n = e.component) != null && n.options && ht((i = e.component) == null ? void 0 : i.options) && (t || console.warn("[Builder.io] In order to use localized fields in Builder, you must pass a locale prop to the BuilderComponent or to options object while fetching the content to resolve localized fields. Learn more: https://www.builder.io/c/docs/localization-inline#targeting-and-inline-localization"), e.component.options = gt(e.component.options, t != null ? t : "Default")), e;
199
200
  }
200
- function ne(e) {
201
+ function oe(e) {
201
202
  if (e === null || typeof e != "object")
202
203
  return e;
203
204
  if (Array.isArray(e))
204
- return e.map((n) => ne(n));
205
+ return e.map((n) => oe(n));
205
206
  if (e["@type"] === "@builder.io/sdk:Element")
206
207
  return e;
207
208
  const t = {};
208
209
  for (const n in e)
209
- n !== "meta" && Object.prototype.hasOwnProperty.call(e, n) && (t[n] = ne(e[n]));
210
+ n !== "meta" && Object.prototype.hasOwnProperty.call(e, n) && (t[n] = oe(e[n]));
210
211
  return t;
211
212
  }
212
- const bt = ["svelte", "vue", "angular", "qwik", "solid"].includes($), pt = (e) => {
213
- if (bt) {
214
- const t = re(e);
213
+ const pt = ["svelte", "vue", "angular", "qwik", "solid"].includes(F), yt = (e) => {
214
+ if (pt) {
215
+ const t = le(e);
215
216
  return {
216
217
  ...t,
217
218
  properties: {
@@ -222,7 +223,7 @@ const bt = ["svelte", "vue", "angular", "qwik", "solid"].includes($), pt = (e) =
222
223
  }
223
224
  };
224
225
  } else {
225
- const t = ne(mt(e, "children", "meta"));
226
+ const t = oe(ft(e, "children", "meta"));
226
227
  return {
227
228
  ...t,
228
229
  properties: {
@@ -235,25 +236,25 @@ const bt = ["svelte", "vue", "angular", "qwik", "solid"].includes($), pt = (e) =
235
236
  meta: e.meta
236
237
  };
237
238
  }
238
- }, yt = ({
239
+ }, vt = ({
239
240
  block: e,
240
241
  context: t,
241
242
  localState: n,
242
243
  rootState: i,
243
- rootSetState: o
244
+ rootSetState: a
244
245
  }) => {
245
246
  if (!e.bindings)
246
247
  return e;
247
- const r = pt(e);
248
- for (const a in e.bindings) {
249
- const l = e.bindings[a], d = D({
248
+ const r = yt(e);
249
+ for (const o in e.bindings) {
250
+ const l = e.bindings[o], u = O({
250
251
  code: l,
251
252
  localState: n,
252
253
  rootState: i,
253
- rootSetState: o,
254
+ rootSetState: a,
254
255
  context: t
255
256
  });
256
- Re(r, a, d);
257
+ Pe(r, o, u);
257
258
  }
258
259
  return r;
259
260
  };
@@ -262,127 +263,127 @@ function xt({
262
263
  context: t,
263
264
  localState: n,
264
265
  rootState: i,
265
- rootSetState: o
266
+ rootSetState: a
266
267
  }) {
267
- let r = gt(e, i.locale);
268
- return r = r, yt({
268
+ let r = bt(e, i.locale);
269
+ return r = r, vt({
269
270
  block: r,
270
271
  localState: n,
271
272
  rootState: i,
272
- rootSetState: o,
273
+ rootSetState: a,
273
274
  context: t
274
275
  });
275
276
  }
276
- const K = (e) => e ? e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase() : "";
277
- function vt(e, t, n = {}) {
278
- let i, o, r, a = null, l = 0;
279
- const d = function() {
280
- l = n.leading === !1 ? 0 : Date.now(), a = null, r = e.apply(i, o), a || (i = o = null);
277
+ const Q = (e) => e ? e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase() : "";
278
+ function St(e, t, n = {}) {
279
+ let i, a, r, o = null, l = 0;
280
+ const u = function() {
281
+ l = n.leading === !1 ? 0 : Date.now(), o = null, r = e.apply(i, a), o || (i = a = null);
281
282
  };
282
283
  return function() {
283
284
  const c = Date.now();
284
285
  !l && n.leading === !1 && (l = c);
285
286
  const h = t - (c - l);
286
- return i = this, o = arguments, h <= 0 || h > t ? (a && (clearTimeout(a), a = null), l = c, r = e.apply(i, o), a || (i = o = null)) : !a && n.trailing !== !1 && (a = setTimeout(d, h)), r;
287
+ return i = this, a = arguments, h <= 0 || h > t ? (o && (clearTimeout(o), o = null), l = c, r = e.apply(i, a), o || (i = a = null)) : !o && n.trailing !== !1 && (o = setTimeout(u, h)), r;
287
288
  };
288
289
  }
289
- function O(e, ...t) {
290
+ function _(e, ...t) {
290
291
  const n = Object(e);
291
292
  for (let i = 1; i < arguments.length; i++) {
292
- const o = arguments[i];
293
- if (o != null)
294
- for (const r in o)
295
- Object.prototype.hasOwnProperty.call(o, r) && (n[r] = o[r]);
293
+ const a = arguments[i];
294
+ if (a != null)
295
+ for (const r in a)
296
+ Object.prototype.hasOwnProperty.call(a, r) && (n[r] = a[r]);
296
297
  }
297
298
  return n;
298
299
  }
299
- function St(e) {
300
+ function kt(e) {
300
301
  for (const t of e)
301
302
  switch (t.trigger) {
302
303
  case "pageLoad":
303
- Ne(t);
304
+ $e(t);
304
305
  break;
305
306
  case "scrollInView":
306
- Ct(t);
307
+ Tt(t);
307
308
  break;
308
309
  }
309
310
  }
310
- function Ae(e) {
311
+ function Ne(e) {
311
312
  console.warn(`Cannot animate element: element with ID ${e} not found!`);
312
313
  }
313
314
  function We(e, t) {
314
- const n = kt(e), i = getComputedStyle(t), o = e.steps[0].styles, r = e.steps[e.steps.length - 1].styles, a = [o, r];
315
- for (const l of a)
316
- for (const d of n)
317
- d in l || (l[d] = i[d]);
315
+ const n = Ct(e), i = getComputedStyle(t), a = e.steps[0].styles, r = e.steps[e.steps.length - 1].styles, o = [a, r];
316
+ for (const l of o)
317
+ for (const u of n)
318
+ u in l || (l[u] = i[u]);
318
319
  }
319
- function kt(e) {
320
+ function Ct(e) {
320
321
  const t = [];
321
322
  for (const n of e.steps)
322
323
  for (const i in n.styles)
323
324
  t.indexOf(i) === -1 && t.push(i);
324
325
  return t;
325
326
  }
326
- function Ne(e) {
327
+ function $e(e) {
327
328
  const t = Array.prototype.slice.call(document.getElementsByClassName(e.elementId || e.id || ""));
328
329
  if (!t.length) {
329
- Ae(e.elementId || e.id || "");
330
+ Ne(e.elementId || e.id || "");
330
331
  return;
331
332
  }
332
333
  Array.from(t).forEach((n) => {
333
- We(e, n), n.style.transition = "none", n.style.transitionDelay = "0", O(n.style, e.steps[0].styles), setTimeout(() => {
334
- n.style.transition = `all ${e.duration}s ${K(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s"), O(n.style, e.steps[1].styles), setTimeout(() => {
334
+ We(e, n), n.style.transition = "none", n.style.transitionDelay = "0", _(n.style, e.steps[0].styles), setTimeout(() => {
335
+ n.style.transition = `all ${e.duration}s ${Q(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s"), _(n.style, e.steps[1].styles), setTimeout(() => {
335
336
  n.style.transition = "", n.style.transitionDelay = "";
336
337
  }, (e.delay || 0) * 1e3 + e.duration * 1e3 + 100);
337
338
  });
338
339
  });
339
340
  }
340
- function Ct(e) {
341
+ function Tt(e) {
341
342
  const t = Array.prototype.slice.call(document.getElementsByClassName(e.elementId || e.id || ""));
342
343
  if (!t.length) {
343
- Ae(e.elementId || e.id || "");
344
+ Ne(e.elementId || e.id || "");
344
345
  return;
345
346
  }
346
347
  Array.from(t).forEach((n) => {
347
348
  We(e, n);
348
- let i = !1, o = !1;
349
+ let i = !1, a = !1;
349
350
  function r() {
350
- !i && l(n) ? (i = !0, o = !0, setTimeout(() => {
351
- O(n.style, e.steps[1].styles), e.repeat || document.removeEventListener("scroll", a), setTimeout(() => {
352
- o = !1, e.repeat || (n.style.transition = "", n.style.transitionDelay = "");
351
+ !i && l(n) ? (i = !0, a = !0, setTimeout(() => {
352
+ _(n.style, e.steps[1].styles), e.repeat || document.removeEventListener("scroll", o), setTimeout(() => {
353
+ a = !1, e.repeat || (n.style.transition = "", n.style.transitionDelay = "");
353
354
  }, (e.duration + (e.delay || 0)) * 1e3 + 100);
354
- })) : e.repeat && i && !o && !l(n) && (i = !1, O(n.style, e.steps[0].styles));
355
+ })) : e.repeat && i && !a && !l(n) && (i = !1, _(n.style, e.steps[0].styles));
355
356
  }
356
- const a = vt(r, 200, {
357
+ const o = St(r, 200, {
357
358
  leading: !1
358
359
  });
359
360
  function l(h) {
360
- const m = h.getBoundingClientRect(), u = window.innerHeight, g = (e.thresholdPercent || 0) / 100 * u;
361
- return m.bottom > g && m.top < u - g;
361
+ const g = h.getBoundingClientRect(), d = window.innerHeight, f = (e.thresholdPercent || 0) / 100 * d;
362
+ return g.bottom > f && g.top < d - f;
362
363
  }
363
- const d = e.steps[0].styles;
364
+ const u = e.steps[0].styles;
364
365
  function c() {
365
- O(n.style, d);
366
+ _(n.style, u);
366
367
  }
367
368
  c(), setTimeout(() => {
368
- n.style.transition = `all ${e.duration}s ${K(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s");
369
- }), document.addEventListener("scroll", a, {
369
+ n.style.transition = `all ${e.duration}s ${Q(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s");
370
+ }), document.addEventListener("scroll", o, {
370
371
  capture: !0,
371
372
  passive: !0
372
373
  }), r();
373
374
  });
374
375
  }
375
- const Fe = (e) => Object.entries(e).map(([n, i]) => {
376
+ const De = (e) => Object.entries(e).map(([n, i]) => {
376
377
  if (typeof i == "string")
377
- return `${K(n)}: ${i};`;
378
- }).filter(te), Tt = (e) => Fe(e).join(`
379
- `), H = ({
378
+ return `${Q(n)}: ${i};`;
379
+ }).filter(ae), wt = (e) => De(e).join(`
380
+ `), U = ({
380
381
  mediaQuery: e,
381
382
  className: t,
382
383
  styles: n
383
384
  }) => {
384
385
  const i = `.${t} {
385
- ${Tt(n)}
386
+ ${wt(n)}
386
387
  }`;
387
388
  return e ? `${e} {
388
389
  ${i}
@@ -393,21 +394,21 @@ function It({
393
394
  }) {
394
395
  return e;
395
396
  }
396
- const wt = ({
397
+ const Et = ({
397
398
  block: e,
398
399
  context: t
399
- }) => $e(It({
400
+ }) => Fe(It({
400
401
  style: e.style || {},
401
402
  context: t,
402
403
  block: e
403
404
  }));
404
- function $e(e) {
405
- switch ($) {
405
+ function Fe(e) {
406
+ switch (F) {
406
407
  case "svelte":
407
408
  case "vue":
408
409
  case "solid":
409
410
  case "angular":
410
- return Fe(e).join(" ");
411
+ return De(e).join(" ");
411
412
  case "qwik":
412
413
  case "reactNative":
413
414
  case "react":
@@ -415,7 +416,7 @@ function $e(e) {
415
416
  return e;
416
417
  }
417
418
  }
418
- const Le = (e, t) => e ? t ? e.models && e.models.length > 0 && !e.models.includes(t) : !1 : !0, Et = ({
419
+ const Le = (e, t) => e ? t ? e.models && e.models.length > 0 && !e.models.includes(t) : !1 : !0, Rt = ({
419
420
  block: e,
420
421
  registeredComponents: t,
421
422
  model: n
@@ -424,15 +425,15 @@ const Le = (e, t) => e ? t ? e.models && e.models.length > 0 && !e.models.includ
424
425
  const i = (r = e.component) == null ? void 0 : r.name;
425
426
  if (!i)
426
427
  return null;
427
- const o = t[i];
428
- if (!o || Le(o, n)) {
428
+ const a = t[i];
429
+ if (!a || Le(a, n)) {
429
430
  console.warn(`
430
431
  Could not find a registered component named "${i}".
431
432
  If you registered it, is the file that registered it imported by the file that needs to render it?`);
432
433
  return;
433
434
  } else
434
- return o;
435
- }, Rt = ({
435
+ return a;
436
+ }, Pt = ({
436
437
  block: e,
437
438
  context: t
438
439
  }) => {
@@ -442,30 +443,30 @@ const Le = (e, t) => e ? t ? e.models && e.models.length > 0 && !e.models.includ
442
443
  } = e;
443
444
  if (!(n != null && n.collection))
444
445
  return;
445
- const o = D({
446
+ const a = O({
446
447
  code: n.collection,
447
448
  localState: t.localState,
448
449
  rootState: t.rootState,
449
450
  rootSetState: t.rootSetState,
450
451
  context: t.context
451
452
  });
452
- if (!Array.isArray(o))
453
+ if (!Array.isArray(a))
453
454
  return;
454
- const r = n.collection.split(".").pop(), a = n.itemName || (r ? r + "Item" : "item");
455
- return o.map((d, c) => ({
455
+ const r = n.collection.split(".").pop(), o = n.itemName || (r ? r + "Item" : "item");
456
+ return a.map((u, c) => ({
456
457
  context: {
457
458
  ...t,
458
459
  localState: {
459
460
  ...t.localState,
460
461
  $index: c,
461
- $item: d,
462
- [a]: d,
463
- [`$${a}Index`]: c
462
+ $item: u,
463
+ [o]: u,
464
+ [`$${o}Index`]: c
464
465
  }
465
466
  },
466
467
  block: i
467
468
  }));
468
- }, Pt = (e, t) => {
469
+ }, Vt = (e, t) => {
469
470
  var n;
470
471
  return (n = e == null ? void 0 : e.shouldReceiveBuilderProps) != null && n.builderLinkComponent ? {
471
472
  builderLinkComponent: t
@@ -473,21 +474,26 @@ const Le = (e, t) => e ? t ? e.models && e.models.length > 0 && !e.models.includ
473
474
  }, Bt = (e, t, n) => {
474
475
  var i;
475
476
  return (i = e == null ? void 0 : e.shouldReceiveBuilderProps) != null && i.builderComponents ? {
476
- builderComponents: Object.fromEntries(Object.entries(t).filter(([r, a]) => !Le(a, n)))
477
+ builderComponents: Object.fromEntries(Object.entries(t).filter(([r, o]) => !Le(o, n)))
477
478
  } : {};
478
- }, Vt = (e, t) => {
479
+ }, At = (e, t) => {
479
480
  var n;
480
481
  return (n = e == null ? void 0 : e.shouldReceiveBuilderProps) != null && n.builderBlock ? {
481
482
  builderBlock: t
482
483
  } : {};
483
- }, At = (e, t) => {
484
+ }, Nt = (e, t) => {
484
485
  var n;
485
486
  return (n = e == null ? void 0 : e.shouldReceiveBuilderProps) != null && n.builderContext ? {
486
487
  builderContext: t
487
488
  } : {};
488
- }, De = {
489
+ }, Oe = {
490
+ xsmall: {
491
+ min: 0,
492
+ default: 160,
493
+ max: 320
494
+ },
489
495
  small: {
490
- min: 320,
496
+ min: 321,
491
497
  default: 321,
492
498
  max: 640
493
499
  },
@@ -501,34 +507,46 @@ const Le = (e, t) => e ? t ? e.models && e.models.length > 0 && !e.models.includ
501
507
  default: 991,
502
508
  max: 1200
503
509
  }
504
- }, he = (e, t = De) => `@media (max-width: ${t[e].max}px)`, Oe = ({
505
- small: e,
506
- medium: t
507
- }) => {
508
- const n = re(De);
509
- if (!e || !t)
510
- return n;
511
- const i = Math.floor(e / 2);
512
- n.small = {
513
- max: e,
514
- min: i,
515
- default: i + 1
510
+ }, X = (e, t = Oe) => `@media (max-width: ${t[e].max}px)`, Ue = (e) => {
511
+ const t = le(Oe);
512
+ if (!e)
513
+ return t;
514
+ const {
515
+ xsmall: n,
516
+ small: i,
517
+ medium: a
518
+ } = e;
519
+ if (n) {
520
+ const u = Math.floor(n / 2);
521
+ t.xsmall = {
522
+ max: n,
523
+ min: u,
524
+ default: u + 1
525
+ };
526
+ }
527
+ if (!i || !a)
528
+ return t;
529
+ const r = n ? t.xsmall.max + 1 : Math.floor(i / 2);
530
+ t.small = {
531
+ max: i,
532
+ min: r,
533
+ default: r + 1
516
534
  };
517
- const o = n.small.max + 1;
518
- n.medium = {
519
- max: t,
535
+ const o = t.small.max + 1;
536
+ t.medium = {
537
+ max: a,
520
538
  min: o,
521
539
  default: o + 1
522
540
  };
523
- const r = n.medium.max + 1;
524
- return n.large = {
541
+ const l = t.medium.max + 1;
542
+ return t.large = {
525
543
  max: 2e3,
526
544
  // TODO: decide upper limit
527
- min: r,
528
- default: r + 1
529
- }, n;
545
+ min: l,
546
+ default: l + 1
547
+ }, t;
530
548
  };
531
- function J(e) {
549
+ function M(e) {
532
550
  return /* @__PURE__ */ s(
533
551
  "style",
534
552
  {
@@ -541,56 +559,64 @@ function J(e) {
541
559
  function Wt(e) {
542
560
  function t() {
543
561
  const i = e.block;
544
- return te(i.hide) ? !i.hide : te(i.show) ? i.show : !0;
562
+ return ae(i.hide) ? !i.hide : ae(i.show) ? i.show : !0;
545
563
  }
546
564
  function n() {
547
- var y, b, p;
548
- const i = e.block, o = i.responsiveStyles, r = e.context.content, a = Oe(
549
- ((y = r == null ? void 0 : r.meta) == null ? void 0 : y.breakpoints) || {}
550
- ), l = o == null ? void 0 : o.large, d = o == null ? void 0 : o.medium, c = o == null ? void 0 : o.small, h = i.id;
551
- if (!h)
565
+ var T, P, I, v, m;
566
+ const i = e.block, a = i.responsiveStyles, r = e.context.content, o = Ue(
567
+ ((T = r == null ? void 0 : r.meta) == null ? void 0 : T.breakpoints) || {}
568
+ ), l = !!((I = (P = r == null ? void 0 : r.meta) == null ? void 0 : P.breakpoints) != null && I.xsmall), u = a == null ? void 0 : a.large, c = a == null ? void 0 : a.medium, h = a == null ? void 0 : a.small, g = a == null ? void 0 : a.xsmall, d = i.id;
569
+ if (!d)
552
570
  return "";
553
- const m = l ? H({
554
- className: h,
555
- styles: l
556
- }) : "", u = d ? H({
557
- className: h,
558
- styles: d,
559
- mediaQuery: he(
571
+ const k = u ? U({
572
+ className: d,
573
+ styles: u
574
+ }) : "", f = c ? U({
575
+ className: d,
576
+ styles: c,
577
+ mediaQuery: X(
560
578
  "medium",
561
- a
579
+ o
562
580
  )
563
- }) : "", k = c ? H({
564
- className: h,
565
- styles: c,
566
- mediaQuery: he(
581
+ }) : "", b = h ? U({
582
+ className: d,
583
+ styles: h,
584
+ mediaQuery: X(
567
585
  "small",
568
- a
586
+ o
587
+ )
588
+ }) : "", x = g && l ? U({
589
+ className: d,
590
+ styles: g,
591
+ mediaQuery: X(
592
+ "xsmall",
593
+ o
569
594
  )
570
- }) : "", g = i.animations && i.animations.find((C) => C.trigger === "hover");
571
- let v = "";
572
- if (g) {
573
- const C = ((p = (b = g.steps) == null ? void 0 : b[1]) == null ? void 0 : p.styles) || {};
574
- v = H({
575
- className: `${h}:hover`,
595
+ }) : "", y = i.animations && i.animations.find((p) => p.trigger === "hover");
596
+ let S = "";
597
+ if (y) {
598
+ const p = ((m = (v = y.steps) == null ? void 0 : v[1]) == null ? void 0 : m.styles) || {};
599
+ S = U({
600
+ className: `${d}:hover`,
576
601
  styles: {
577
- ...C,
578
- transition: `all ${g.duration}s ${K(
579
- g.easing
602
+ ...p,
603
+ transition: `all ${y.duration}s ${Q(
604
+ y.easing
580
605
  )}`,
581
- transitionDelay: g.delay ? `${g.delay}s` : "0s"
606
+ transitionDelay: y.delay ? `${y.delay}s` : "0s"
582
607
  }
583
608
  }) || "";
584
609
  }
585
610
  return [
586
- m,
587
- u,
588
611
  k,
589
- v
612
+ f,
613
+ b,
614
+ x,
615
+ S
590
616
  ].join(" ");
591
617
  }
592
- return /* @__PURE__ */ s(E, { children: n() && t() ? /* @__PURE__ */ s(E, { children: /* @__PURE__ */ s(
593
- J,
618
+ return /* @__PURE__ */ s(R, { children: n() && t() ? /* @__PURE__ */ s(R, { children: /* @__PURE__ */ s(
619
+ M,
594
620
  {
595
621
  id: "builderio-block",
596
622
  styles: n(),
@@ -598,10 +624,10 @@ function Wt(e) {
598
624
  }
599
625
  ) }) : null });
600
626
  }
601
- function Nt(e) {
627
+ function $t(e) {
602
628
  return e.charAt(0).toUpperCase() + e.slice(1);
603
629
  }
604
- const Ft = (e) => `on${Nt(e)}`, $t = (e, t) => (n) => D({
630
+ const Dt = (e) => `on${$t(e)}`, Ft = (e, t) => (n) => O({
605
631
  code: e,
606
632
  context: t.context,
607
633
  localState: t.localState,
@@ -610,24 +636,24 @@ const Ft = (e) => `on${Nt(e)}`, $t = (e, t) => (n) => D({
610
636
  event: n,
611
637
  isExpression: !1
612
638
  });
613
- function Ue(e) {
639
+ function _e(e) {
614
640
  var i;
615
641
  const t = {}, n = (i = e.block.actions) != null ? i : {};
616
- for (const o in n) {
617
- if (!n.hasOwnProperty(o))
642
+ for (const a in n) {
643
+ if (!n.hasOwnProperty(a))
618
644
  continue;
619
- const r = n[o];
620
- let a = Ft(o);
645
+ const r = n[a];
646
+ let o = Dt(a);
621
647
  if (e.stripPrefix)
622
- switch ($) {
648
+ switch (F) {
623
649
  case "vue":
624
- a = a.replace("v-on:", "");
650
+ o = o.replace("v-on:", "");
625
651
  break;
626
652
  case "svelte":
627
- a = a.replace("on:", "");
653
+ o = o.replace("on:", "");
628
654
  break;
629
655
  }
630
- t[a] = $t(r, e);
656
+ t[o] = Ft(r, e);
631
657
  }
632
658
  return t;
633
659
  }
@@ -636,23 +662,23 @@ function Lt({
636
662
  }) {
637
663
  return e;
638
664
  }
639
- const Dt = (e) => ({
665
+ const Ot = (e) => ({
640
666
  href: e.href
641
667
  });
642
- function ce({
668
+ function ue({
643
669
  block: e,
644
670
  context: t
645
671
  }) {
646
672
  var i;
647
673
  const n = {
648
- ...Dt(e),
674
+ ...Ot(e),
649
675
  ...e.properties,
650
676
  "builder-id": e.id,
651
- style: wt({
677
+ style: Et({
652
678
  block: e,
653
679
  context: t
654
680
  }),
655
- [U()]: [e.id, "builder-block", e.class, (i = e.properties) == null ? void 0 : i.class].filter(Boolean).join(" ")
681
+ [H()]: [e.id, "builder-block", e.class, (i = e.properties) == null ? void 0 : i.class].filter(Boolean).join(" ")
656
682
  };
657
683
  return Lt({
658
684
  properties: n,
@@ -660,16 +686,16 @@ function ce({
660
686
  block: e
661
687
  });
662
688
  }
663
- function Ot(e) {
689
+ function Ut(e) {
664
690
  return /* @__PURE__ */ s(
665
- le,
691
+ se,
666
692
  {
667
693
  TagName: e.Wrapper,
668
- attributes: ce({
694
+ attributes: ue({
669
695
  block: e.block,
670
696
  context: e.context
671
697
  }),
672
- actionAttributes: Ue({
698
+ actionAttributes: _e({
673
699
  block: e.block,
674
700
  rootState: e.context.rootState,
675
701
  rootSetState: e.context.rootSetState,
@@ -681,18 +707,18 @@ function Ot(e) {
681
707
  }
682
708
  );
683
709
  }
684
- function Ut(e) {
710
+ function _t(e) {
685
711
  return A(() => {
686
- }, []), /* @__PURE__ */ s(E, { children: e.children });
712
+ }, []), /* @__PURE__ */ s(R, { children: e.children });
687
713
  }
688
- function _t(e) {
714
+ function qt(e) {
689
715
  function t() {
690
716
  return e.includeBlockProps ? {
691
- ...ce({
717
+ ...ue({
692
718
  block: e.block,
693
719
  context: e.context
694
720
  }),
695
- ...Ue({
721
+ ..._e({
696
722
  block: e.block,
697
723
  rootState: e.context.rootState,
698
724
  rootSetState: e.context.rootSetState,
@@ -701,8 +727,8 @@ function _t(e) {
701
727
  })
702
728
  } : {};
703
729
  }
704
- return /* @__PURE__ */ s(E, { children: e.Wrapper.load ? /* @__PURE__ */ s(E, { children: /* @__PURE__ */ s(
705
- Ut,
730
+ return /* @__PURE__ */ s(R, { children: e.Wrapper.load ? /* @__PURE__ */ s(R, { children: /* @__PURE__ */ s(
731
+ _t,
706
732
  {
707
733
  load: e.Wrapper.load,
708
734
  fallback: e.Wrapper.fallback,
@@ -717,9 +743,9 @@ const Ht = ({
717
743
  builderBlock: t,
718
744
  context: n,
719
745
  componentRef: i,
720
- includeBlockProps: o,
746
+ includeBlockProps: a,
721
747
  isInteractive: r,
722
- contextValue: a
748
+ contextValue: o
723
749
  }) => {
724
750
  const l = {
725
751
  ...e,
@@ -727,10 +753,10 @@ const Ht = ({
727
753
  * If `noWrap` is set to `true`, then the block's props/attributes are provided to the
728
754
  * component itself directly. Otherwise, they are provided to the wrapper element.
729
755
  */
730
- ...o ? {
731
- attributes: ce({
756
+ ...a ? {
757
+ attributes: ue({
732
758
  block: t,
733
- context: a
759
+ context: o
734
760
  })
735
761
  } : {}
736
762
  };
@@ -739,15 +765,15 @@ const Ht = ({
739
765
  block: t,
740
766
  context: n,
741
767
  wrapperProps: e,
742
- includeBlockProps: o
768
+ includeBlockProps: a
743
769
  } : l;
744
770
  };
745
- function ge(e) {
771
+ function be(e) {
746
772
  var i;
747
- const [t, n] = R(
748
- () => e.isInteractive ? _t : e.componentRef
773
+ const [t, n] = E(
774
+ () => e.isInteractive ? qt : e.componentRef
749
775
  );
750
- return /* @__PURE__ */ s(E, { children: e.componentRef ? /* @__PURE__ */ s(E, { children: /* @__PURE__ */ s(
776
+ return /* @__PURE__ */ s(R, { children: e.componentRef ? /* @__PURE__ */ s(R, { children: /* @__PURE__ */ s(
751
777
  t,
752
778
  {
753
779
  ...Ht({
@@ -760,23 +786,23 @@ function ge(e) {
760
786
  isInteractive: e.isInteractive,
761
787
  contextValue: e.context
762
788
  }),
763
- children: (i = e.blockChildren) == null ? void 0 : i.map((o) => /* @__PURE__ */ s(
764
- G,
789
+ children: (i = e.blockChildren) == null ? void 0 : i.map((a) => /* @__PURE__ */ s(
790
+ Y,
765
791
  {
766
- block: o,
792
+ block: a,
767
793
  context: e.context,
768
794
  registeredComponents: e.registeredComponents,
769
795
  linkComponent: e.linkComponent
770
796
  },
771
- o.id
797
+ a.id
772
798
  ))
773
799
  }
774
800
  ) }) : null });
775
801
  }
776
- function be(e) {
777
- const [t, n] = R(() => e.repeatContext);
778
- return /* @__PURE__ */ s(se.Provider, { value: t, children: /* @__PURE__ */ s(
779
- G,
802
+ function pe(e) {
803
+ const [t, n] = E(() => e.repeatContext);
804
+ return /* @__PURE__ */ s(ce.Provider, { value: t, children: /* @__PURE__ */ s(
805
+ Y,
780
806
  {
781
807
  block: e.block,
782
808
  context: t,
@@ -785,63 +811,63 @@ function be(e) {
785
811
  }
786
812
  ) });
787
813
  }
788
- function G(e) {
789
- var h, m, u, k;
814
+ function Y(e) {
815
+ var h, g, d, k;
790
816
  function t() {
791
- return Rt({
817
+ return Pt({
792
818
  block: e.block,
793
819
  context: e.context
794
820
  });
795
821
  }
796
- const [n, i] = R(() => ({
822
+ const [n, i] = E(() => ({
797
823
  value: null,
798
824
  update: !1
799
825
  }));
800
- function o() {
801
- var v;
802
- if (n.value && !n.update && !ae())
826
+ function a() {
827
+ var b;
828
+ if (n.value && !n.update && !G())
803
829
  return n.value;
804
- const g = (v = e.block.repeat) != null && v.collection ? e.block : xt({
830
+ const f = (b = e.block.repeat) != null && b.collection ? e.block : xt({
805
831
  block: e.block,
806
832
  localState: e.context.localState,
807
833
  rootState: e.context.rootState,
808
834
  rootSetState: e.context.rootSetState,
809
835
  context: e.context.context
810
836
  });
811
- return n.value = g, n.update = !1, g;
837
+ return n.value = f, n.update = !1, f;
812
838
  }
813
839
  function r() {
814
- return Et({
815
- block: o(),
840
+ return Rt({
841
+ block: a(),
816
842
  registeredComponents: e.registeredComponents,
817
843
  model: e.context.model
818
844
  });
819
845
  }
820
- function a() {
821
- var v;
822
- return e.block.tagName === "a" || ((v = o().properties) == null ? void 0 : v.href) || o().href ? e.linkComponent || "a" : e.block.tagName || "div";
846
+ function o() {
847
+ var b;
848
+ return e.block.tagName === "a" || ((b = a().properties) == null ? void 0 : b.href) || a().href ? e.linkComponent || "a" : e.block.tagName || "div";
823
849
  }
824
850
  function l() {
825
- var y, b;
826
- if ((y = e.block.repeat) != null && y.collection)
827
- return !!((b = t == null ? void 0 : t()) != null && b.length);
828
- const g = "hide" in o() ? o().hide : !1;
829
- return ("show" in o() ? o().show : !0) && !g;
851
+ var x, y;
852
+ if ((x = e.block.repeat) != null && x.collection)
853
+ return !!((y = t == null ? void 0 : t()) != null && y.length);
854
+ const f = "hide" in a() ? a().hide : !1;
855
+ return ("show" in a() ? a().show : !0) && !f;
830
856
  }
831
- function d() {
832
- var v, y;
833
- return !((v = r == null ? void 0 : r()) != null && v.component) && !t() ? (y = o().children) != null ? y : [] : [];
857
+ function u() {
858
+ var b, x;
859
+ return !((b = r == null ? void 0 : r()) != null && b.component) && !t() ? (x = a().children) != null ? x : [] : [];
834
860
  }
835
861
  function c() {
836
- var g, v, y, b;
862
+ var f, b, x, y;
837
863
  return {
838
- blockChildren: (g = o().children) != null ? g : [],
839
- componentRef: (v = r == null ? void 0 : r()) == null ? void 0 : v.component,
864
+ blockChildren: (f = a().children) != null ? f : [],
865
+ componentRef: (b = r == null ? void 0 : r()) == null ? void 0 : b.component,
840
866
  componentOptions: {
841
- ...dt(o(), e.context),
842
- ...Vt(r(), o()),
843
- ...At(r(), e.context),
844
- ...Pt(r(), e.linkComponent),
867
+ ...dt(a(), e.context),
868
+ ...At(r(), a()),
869
+ ...Nt(r(), e.context),
870
+ ...Vt(r(), e.linkComponent),
845
871
  ...Bt(
846
872
  r(),
847
873
  e.registeredComponents,
@@ -851,34 +877,34 @@ function G(e) {
851
877
  context: e.context,
852
878
  linkComponent: e.linkComponent,
853
879
  registeredComponents: e.registeredComponents,
854
- builderBlock: o(),
855
- includeBlockProps: ((y = r == null ? void 0 : r()) == null ? void 0 : y.noWrap) === !0,
856
- isInteractive: !((b = r == null ? void 0 : r()) != null && b.isRSC && $ === "rsc")
880
+ builderBlock: a(),
881
+ includeBlockProps: ((x = r == null ? void 0 : r()) == null ? void 0 : x.noWrap) === !0,
882
+ isInteractive: !((y = r == null ? void 0 : r()) != null && y.isRSC && F === "rsc")
857
883
  };
858
884
  }
859
885
  return A(() => {
860
- const g = o().id, v = o().animations;
861
- v && g && St(
862
- v.map((y) => ({
863
- ...y,
864
- elementId: g
886
+ const f = a().id, b = a().animations;
887
+ b && f && kt(
888
+ b.map((x) => ({
889
+ ...x,
890
+ elementId: f
865
891
  }))
866
892
  );
867
893
  }, []), A(() => {
868
894
  n.update = !0;
869
- }), /* @__PURE__ */ s(E, { children: l() ? /* @__PURE__ */ B(E, { children: [
870
- /* @__PURE__ */ s(Wt, { block: o(), context: e.context }),
871
- (h = r == null ? void 0 : r()) != null && h.noWrap ? t() ? /* @__PURE__ */ s(E, { children: (k = t()) == null ? void 0 : k.map((g, v) => /* @__PURE__ */ s(
872
- be,
895
+ }), /* @__PURE__ */ s(R, { children: l() ? /* @__PURE__ */ V(R, { children: [
896
+ /* @__PURE__ */ s(Wt, { block: a(), context: e.context }),
897
+ (h = r == null ? void 0 : r()) != null && h.noWrap ? t() ? /* @__PURE__ */ s(R, { children: (k = t()) == null ? void 0 : k.map((f, b) => /* @__PURE__ */ s(
898
+ pe,
873
899
  {
874
- repeatContext: g.context,
875
- block: g.block,
900
+ repeatContext: f.context,
901
+ block: f.block,
876
902
  registeredComponents: e.registeredComponents,
877
903
  linkComponent: e.linkComponent
878
904
  },
879
- v
905
+ b
880
906
  )) }) : /* @__PURE__ */ s(
881
- ge,
907
+ be,
882
908
  {
883
909
  componentRef: c().componentRef,
884
910
  componentOptions: c().componentOptions,
@@ -890,24 +916,24 @@ function G(e) {
890
916
  includeBlockProps: c().includeBlockProps,
891
917
  isInteractive: c().isInteractive
892
918
  }
893
- ) : /* @__PURE__ */ s(E, { children: t() ? /* @__PURE__ */ s(E, { children: (u = t()) == null ? void 0 : u.map((g, v) => /* @__PURE__ */ s(
894
- be,
919
+ ) : /* @__PURE__ */ s(R, { children: t() ? /* @__PURE__ */ s(R, { children: (d = t()) == null ? void 0 : d.map((f, b) => /* @__PURE__ */ s(
920
+ pe,
895
921
  {
896
- repeatContext: g.context,
897
- block: g.block,
922
+ repeatContext: f.context,
923
+ block: f.block,
898
924
  registeredComponents: e.registeredComponents,
899
925
  linkComponent: e.linkComponent
900
926
  },
901
- v
902
- )) }) : /* @__PURE__ */ B(
903
- Ot,
927
+ b
928
+ )) }) : /* @__PURE__ */ V(
929
+ Ut,
904
930
  {
905
- Wrapper: a(),
906
- block: o(),
931
+ Wrapper: o(),
932
+ block: a(),
907
933
  context: e.context,
908
934
  children: [
909
935
  /* @__PURE__ */ s(
910
- ge,
936
+ be,
911
937
  {
912
938
  componentRef: c().componentRef,
913
939
  componentOptions: c().componentOptions,
@@ -920,15 +946,15 @@ function G(e) {
920
946
  isInteractive: c().isInteractive
921
947
  }
922
948
  ),
923
- (m = d()) == null ? void 0 : m.map((g) => /* @__PURE__ */ s(
924
- G,
949
+ (g = u()) == null ? void 0 : g.map((f) => /* @__PURE__ */ s(
950
+ Y,
925
951
  {
926
- block: g,
952
+ block: f,
927
953
  registeredComponents: e.registeredComponents,
928
954
  linkComponent: e.linkComponent,
929
955
  context: e.context
930
956
  },
931
- g.id
957
+ f.id
932
958
  ))
933
959
  ]
934
960
  }
@@ -936,24 +962,24 @@ function G(e) {
936
962
  ] }) : null });
937
963
  }
938
964
  function Mt(e) {
939
- const t = L(null);
965
+ const t = D(null);
940
966
  function n() {
941
- var a;
967
+ var o;
942
968
  return [
943
969
  "builder-blocks",
944
- (a = e.blocks) != null && a.length ? "" : "no-blocks",
970
+ (o = e.blocks) != null && o.length ? "" : "no-blocks",
945
971
  e.classNameProp
946
972
  ].filter(Boolean).join(" ");
947
973
  }
948
974
  function i() {
949
975
  if (!e.path)
950
976
  return;
951
- const a = "component.options.";
952
- return e.path.startsWith(a) ? e.path : `${a}${e.path || ""}`;
977
+ const o = "this.", l = "component.options.";
978
+ return e.path.startsWith(o) ? e.path.replace(o, "") : e.path.startsWith(l) ? e.path : `${l}${e.path || ""}`;
953
979
  }
954
- function o() {
955
- var a, l;
956
- N() && !((a = e.blocks) != null && a.length) && ((l = window.parent) == null || l.postMessage(
980
+ function a() {
981
+ var o, l;
982
+ W() && !((o = e.blocks) != null && o.length) && ((l = window.parent) == null || l.postMessage(
957
983
  {
958
984
  type: "builder.clickEmptyBlocks",
959
985
  data: {
@@ -965,8 +991,8 @@ function Mt(e) {
965
991
  ));
966
992
  }
967
993
  function r() {
968
- var a, l;
969
- N() && !((a = e.blocks) != null && a.length) && ((l = window.parent) == null || l.postMessage(
994
+ var o, l;
995
+ W() && !((o = e.blocks) != null && o.length) && ((l = window.parent) == null || l.postMessage(
970
996
  {
971
997
  type: "builder.hoverEmptyBlocks",
972
998
  data: {
@@ -978,32 +1004,32 @@ function Mt(e) {
978
1004
  ));
979
1005
  }
980
1006
  return A(() => {
981
- }, []), /* @__PURE__ */ B(E, { children: [
1007
+ }, []), /* @__PURE__ */ V(R, { children: [
982
1008
  /* @__PURE__ */ s(
983
1009
  e.BlocksWrapper,
984
1010
  {
985
1011
  ref: t,
986
- className: n() + " props-blocks-wrapper-2c6a6d88",
1012
+ className: n() + " props-blocks-wrapper-2936bbfc",
987
1013
  "builder-path": i(),
988
1014
  "builder-parent-id": e.parent,
989
1015
  style: e.styleProp,
990
- onClick: (a) => o(),
991
- onMouseEnter: (a) => r(),
992
- onKeyPress: (a) => o(),
1016
+ onClick: (o) => a(),
1017
+ onMouseEnter: (o) => r(),
1018
+ onKeyPress: (o) => a(),
993
1019
  ...e.BlocksWrapperProps,
994
1020
  children: e.children
995
1021
  }
996
1022
  ),
997
- /* @__PURE__ */ s("style", { children: `.props-blocks-wrapper-2c6a6d88 {
1023
+ /* @__PURE__ */ s("style", { children: `.props-blocks-wrapper-2936bbfc {
998
1024
  display: flex;
999
1025
  flex-direction: column;
1000
1026
  align-items: stretch;
1001
1027
  }` })
1002
1028
  ] });
1003
1029
  }
1004
- function F(e) {
1005
- var i, o, r;
1006
- const t = fe(se), n = fe(Pe);
1030
+ function $(e) {
1031
+ var i, a, r;
1032
+ const t = ge(ce), n = ge(Ve);
1007
1033
  return /* @__PURE__ */ s(
1008
1034
  Mt,
1009
1035
  {
@@ -1013,23 +1039,23 @@ function F(e) {
1013
1039
  styleProp: e.styleProp,
1014
1040
  classNameProp: e.className,
1015
1041
  BlocksWrapper: ((i = e.context) == null ? void 0 : i.BlocksWrapper) || (t == null ? void 0 : t.BlocksWrapper),
1016
- BlocksWrapperProps: ((o = e.context) == null ? void 0 : o.BlocksWrapperProps) || (t == null ? void 0 : t.BlocksWrapperProps),
1017
- children: e.blocks ? /* @__PURE__ */ s(E, { children: (r = e.blocks) == null ? void 0 : r.map((a) => /* @__PURE__ */ s(
1018
- G,
1042
+ BlocksWrapperProps: ((a = e.context) == null ? void 0 : a.BlocksWrapperProps) || (t == null ? void 0 : t.BlocksWrapperProps),
1043
+ children: e.blocks ? /* @__PURE__ */ s(R, { children: (r = e.blocks) == null ? void 0 : r.map((o) => /* @__PURE__ */ s(
1044
+ Y,
1019
1045
  {
1020
- block: a,
1046
+ block: o,
1021
1047
  linkComponent: e.linkComponent,
1022
1048
  context: e.context || t,
1023
1049
  registeredComponents: e.registeredComponents || (n == null ? void 0 : n.registeredComponents)
1024
1050
  },
1025
- a.id
1051
+ o.id
1026
1052
  )) }) : null
1027
1053
  }
1028
1054
  );
1029
1055
  }
1030
1056
  const jt = (e) => `builder-columns ${e}-breakpoints`;
1031
- function qt(e) {
1032
- var v, y;
1057
+ function zt(e) {
1058
+ var b, x;
1033
1059
  function t() {
1034
1060
  return typeof e.space == "number" ? e.space || 0 : 20;
1035
1061
  }
@@ -1039,28 +1065,28 @@ function qt(e) {
1039
1065
  function i() {
1040
1066
  return e.stackColumnsAt || "tablet";
1041
1067
  }
1042
- function o(b) {
1043
- return b.link ? e.builderLinkComponent || "a" : "div";
1068
+ function a(y) {
1069
+ return y.link ? e.builderLinkComponent || "a" : "div";
1044
1070
  }
1045
- function r(b) {
1046
- var p;
1047
- return ((p = n()[b]) == null ? void 0 : p.width) || 100 / n().length;
1071
+ function r(y) {
1072
+ var S;
1073
+ return ((S = n()[y]) == null ? void 0 : S.width) || 100 / n().length;
1048
1074
  }
1049
- function a(b) {
1050
- const p = r(b), C = t() * (n().length - 1) * (p / 100);
1051
- return `calc(${p}% - ${C}px)`;
1075
+ function o(y) {
1076
+ const S = r(y), T = t() * (n().length - 1) * (S / 100);
1077
+ return `calc(${S}% - ${T}px)`;
1052
1078
  }
1053
1079
  function l({
1054
- stackedStyle: b,
1055
- desktopStyle: p
1080
+ stackedStyle: y,
1081
+ desktopStyle: S
1056
1082
  }) {
1057
- return i() === "tablet" ? b : p;
1083
+ return i() === "tablet" ? y : S;
1058
1084
  }
1059
- function d({
1060
- stackedStyle: b,
1061
- desktopStyle: p
1085
+ function u({
1086
+ stackedStyle: y,
1087
+ desktopStyle: S
1062
1088
  }) {
1063
- return i() === "never" ? p : b;
1089
+ return i() === "never" ? S : y;
1064
1090
  }
1065
1091
  function c() {
1066
1092
  return e.stackColumnsAt === "never" ? "row" : e.reverseColumnsWhenStacked ? "column-reverse" : "column";
@@ -1074,114 +1100,114 @@ function qt(e) {
1074
1100
  })
1075
1101
  };
1076
1102
  }
1077
- function m(b) {
1078
- const p = b === 0 ? 0 : t(), C = a(b), P = `${p}px`, I = "100%", w = 0;
1103
+ function g(y) {
1104
+ const S = y === 0 ? 0 : t(), T = o(y), P = `${S}px`, I = "100%", v = 0;
1079
1105
  return {
1080
1106
  ...{
1081
1107
  display: "flex",
1082
1108
  flexDirection: "column",
1083
1109
  alignItems: "stretch"
1084
1110
  },
1085
- width: C,
1111
+ width: T,
1086
1112
  ["marginLeft"]: P,
1087
- "--column-width-mobile": d({
1113
+ "--column-width-mobile": u({
1088
1114
  stackedStyle: I,
1089
- desktopStyle: C
1115
+ desktopStyle: T
1090
1116
  }),
1091
- "--column-margin-left-mobile": d({
1092
- stackedStyle: w,
1117
+ "--column-margin-left-mobile": u({
1118
+ stackedStyle: v,
1093
1119
  desktopStyle: P
1094
1120
  }),
1095
1121
  "--column-width-tablet": l({
1096
1122
  stackedStyle: I,
1097
- desktopStyle: C
1123
+ desktopStyle: T
1098
1124
  }),
1099
1125
  "--column-margin-left-tablet": l({
1100
- stackedStyle: w,
1126
+ stackedStyle: v,
1101
1127
  desktopStyle: P
1102
1128
  })
1103
1129
  };
1104
1130
  }
1105
- function u(b) {
1106
- var C, P;
1107
- return Oe(
1108
- ((P = (C = e.builderContext.content) == null ? void 0 : C.meta) == null ? void 0 : P.breakpoints) || {}
1109
- )[b].max;
1131
+ function d(y) {
1132
+ var T, P;
1133
+ return Ue(
1134
+ ((P = (T = e.builderContext.content) == null ? void 0 : T.meta) == null ? void 0 : P.breakpoints) || {}
1135
+ )[y].max;
1110
1136
  }
1111
1137
  function k() {
1112
- const b = `.${e.builderBlock.id}-breakpoints > .builder-column`;
1138
+ const y = `.${e.builderBlock.id}-breakpoints > .builder-column`;
1113
1139
  return `
1114
- @media (max-width: ${u("medium")}px) {
1140
+ @media (max-width: ${d("medium")}px) {
1115
1141
  .${e.builderBlock.id}-breakpoints {
1116
1142
  flex-direction: var(--flex-dir-tablet);
1117
1143
  align-items: stretch;
1118
1144
  }
1119
1145
 
1120
- ${b} {
1146
+ ${y} {
1121
1147
  width: var(--column-width-tablet) !important;
1122
1148
  margin-left: var(--column-margin-left-tablet) !important;
1123
1149
  }
1124
1150
  }
1125
1151
 
1126
- @media (max-width: ${u("small")}px) {
1152
+ @media (max-width: ${d("small")}px) {
1127
1153
  .${e.builderBlock.id}-breakpoints {
1128
1154
  flex-direction: var(--flex-dir);
1129
1155
  align-items: stretch;
1130
1156
  }
1131
1157
 
1132
- ${b} {
1158
+ ${y} {
1133
1159
  width: var(--column-width-mobile) !important;
1134
1160
  margin-left: var(--column-margin-left-mobile) !important;
1135
1161
  }
1136
1162
  },
1137
1163
  `;
1138
1164
  }
1139
- function g(b, p) {
1165
+ function f(y, S) {
1140
1166
  return {
1141
- ...b.link ? {
1142
- href: b.link
1167
+ ...y.link ? {
1168
+ href: y.link
1143
1169
  } : {},
1144
- [U()]: "builder-column",
1145
- style: $e(m(p))
1170
+ [H()]: "builder-column",
1171
+ style: Fe(g(S))
1146
1172
  };
1147
1173
  }
1148
- return /* @__PURE__ */ B(E, { children: [
1149
- /* @__PURE__ */ B(
1174
+ return /* @__PURE__ */ V(R, { children: [
1175
+ /* @__PURE__ */ V(
1150
1176
  "div",
1151
1177
  {
1152
- className: jt((v = e.builderBlock) == null ? void 0 : v.id) + " div-a6f3faac",
1178
+ className: jt((b = e.builderBlock) == null ? void 0 : b.id) + " div-a6f3faac",
1153
1179
  style: h(),
1154
1180
  children: [
1155
1181
  /* @__PURE__ */ s(
1156
- J,
1182
+ M,
1157
1183
  {
1158
1184
  id: "builderio-columns",
1159
1185
  styles: k(),
1160
1186
  nonce: e.builderContext.nonce
1161
1187
  }
1162
1188
  ),
1163
- (y = e.columns) == null ? void 0 : y.map((b, p) => /* @__PURE__ */ s(
1164
- le,
1189
+ (x = e.columns) == null ? void 0 : x.map((y, S) => /* @__PURE__ */ s(
1190
+ se,
1165
1191
  {
1166
- TagName: o(b),
1192
+ TagName: a(y),
1167
1193
  actionAttributes: {},
1168
- attributes: g(b, p),
1194
+ attributes: f(y, S),
1169
1195
  children: /* @__PURE__ */ s(
1170
- F,
1196
+ $,
1171
1197
  {
1172
- path: `columns.${p}.blocks`,
1198
+ path: `columns.${S}.blocks`,
1173
1199
  parent: e.builderBlock.id,
1174
1200
  context: e.builderContext,
1175
1201
  registeredComponents: e.builderComponents,
1176
1202
  linkComponent: e.builderLinkComponent,
1177
- blocks: b.blocks,
1203
+ blocks: y.blocks,
1178
1204
  styleProp: {
1179
1205
  flexGrow: "1"
1180
1206
  }
1181
1207
  }
1182
1208
  )
1183
1209
  },
1184
- p
1210
+ S
1185
1211
  ))
1186
1212
  ]
1187
1213
  }
@@ -1192,55 +1218,55 @@ function qt(e) {
1192
1218
  }` })
1193
1219
  ] });
1194
1220
  }
1195
- function zt(e) {
1221
+ function Kt(e) {
1196
1222
  return /* @__PURE__ */ s("span", { children: e.children });
1197
1223
  }
1198
- function pe(e) {
1224
+ function ye(e) {
1199
1225
  return e.replace(/http(s)?:/, "");
1200
1226
  }
1201
- function Kt(e = "", t, n) {
1202
- const i = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), o = e.indexOf("?") !== -1 ? "&" : "?";
1203
- return e.match(i) ? e.replace(i, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + o + t + "=" + encodeURIComponent(n);
1227
+ function Jt(e = "", t, n) {
1228
+ const i = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), a = e.indexOf("?") !== -1 ? "&" : "?";
1229
+ return e.match(i) ? e.replace(i, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + a + t + "=" + encodeURIComponent(n);
1204
1230
  }
1205
- function Jt(e, t) {
1231
+ function Gt(e, t) {
1206
1232
  if (!e || !(e != null && e.match(/cdn\.shopify\.com/)) || !t)
1207
1233
  return e;
1208
1234
  if (t === "master")
1209
- return pe(e);
1235
+ return ye(e);
1210
1236
  const n = e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);
1211
1237
  if (n) {
1212
- const i = e.split(n[0]), o = n[3], r = t.match("x") ? t : `${t}x`;
1213
- return pe(`${i[0]}_${r}${o}`);
1238
+ const i = e.split(n[0]), a = n[3], r = t.match("x") ? t : `${t}x`;
1239
+ return ye(`${i[0]}_${r}${a}`);
1214
1240
  }
1215
1241
  return null;
1216
1242
  }
1217
- function Y(e) {
1243
+ function Z(e) {
1218
1244
  if (!e)
1219
1245
  return e;
1220
1246
  const t = [100, 200, 400, 800, 1200, 1600, 2e3];
1221
1247
  if (e.match(/builder\.io/)) {
1222
1248
  let n = e;
1223
1249
  const i = Number(e.split("?width=")[1]);
1224
- return isNaN(i) || (n = `${n} ${i}w`), t.filter((o) => o !== i).map((o) => `${Kt(e, "width", o)} ${o}w`).concat([n]).join(", ");
1250
+ return isNaN(i) || (n = `${n} ${i}w`), t.filter((a) => a !== i).map((a) => `${Jt(e, "width", a)} ${a}w`).concat([n]).join(", ");
1225
1251
  }
1226
- return e.match(/cdn\.shopify\.com/) ? t.map((n) => [Jt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, i]) => `${n} ${i}w`).concat([e]).join(", ") : e;
1252
+ return e.match(/cdn\.shopify\.com/) ? t.map((n) => [Gt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, i]) => `${n} ${i}w`).concat([e]).join(", ") : e;
1227
1253
  }
1228
- function Gt(e) {
1229
- var o, r, a, l, d, c;
1254
+ function Qt(e) {
1255
+ var a, r, o, l, u, c;
1230
1256
  function t() {
1231
- var u;
1232
- const m = e.image || e.src;
1233
- if (!m || // We can auto add srcset for cdn.builder.io and shopify
1257
+ var d;
1258
+ const g = e.image || e.src;
1259
+ if (!g || // We can auto add srcset for cdn.builder.io and shopify
1234
1260
  // images, otherwise you can supply this prop manually
1235
- !(typeof m == "string" && (m.match(/builder\.io/) || m.match(/cdn\.shopify\.com/))))
1261
+ !(typeof g == "string" && (g.match(/builder\.io/) || g.match(/cdn\.shopify\.com/))))
1236
1262
  return e.srcset;
1237
1263
  if (!e.noWebp) {
1238
- if (e.srcset && ((u = e.image) != null && u.includes("builder.io/api/v1/image"))) {
1264
+ if (e.srcset && ((d = e.image) != null && d.includes("builder.io/api/v1/image"))) {
1239
1265
  if (!e.srcset.includes(e.image.split("?")[0]))
1240
- return console.debug("Removed given srcset"), Y(m);
1266
+ return console.debug("Removed given srcset"), Z(g);
1241
1267
  } else if (e.image && !e.srcset)
1242
- return Y(m);
1243
- return Y(m);
1268
+ return Z(g);
1269
+ return Z(g);
1244
1270
  }
1245
1271
  }
1246
1272
  function n() {
@@ -1257,9 +1283,9 @@ function Gt(e) {
1257
1283
  };
1258
1284
  return e.aspectRatio ? h : void 0;
1259
1285
  }
1260
- return /* @__PURE__ */ B(E, { children: [
1261
- /* @__PURE__ */ B(E, { children: [
1262
- /* @__PURE__ */ B("picture", { children: [
1286
+ return /* @__PURE__ */ V(R, { children: [
1287
+ /* @__PURE__ */ V(R, { children: [
1288
+ /* @__PURE__ */ V("picture", { children: [
1263
1289
  n() ? /* @__PURE__ */ s("source", { type: "image/webp", srcSet: n() }) : null,
1264
1290
  /* @__PURE__ */ s(
1265
1291
  "img",
@@ -1280,7 +1306,7 @@ function Gt(e) {
1280
1306
  }
1281
1307
  )
1282
1308
  ] }),
1283
- e.aspectRatio && !((r = (o = e.builderBlock) == null ? void 0 : o.children) != null && r.length && e.fitContent) ? /* @__PURE__ */ s(
1309
+ e.aspectRatio && !((r = (a = e.builderBlock) == null ? void 0 : a.children) != null && r.length && e.fitContent) ? /* @__PURE__ */ s(
1284
1310
  "div",
1285
1311
  {
1286
1312
  className: "builder-image-sizer div-9dac2184",
@@ -1289,8 +1315,8 @@ function Gt(e) {
1289
1315
  }
1290
1316
  }
1291
1317
  ) : null,
1292
- (l = (a = e.builderBlock) == null ? void 0 : a.children) != null && l.length && e.fitContent ? /* @__PURE__ */ s(E, { children: e.children }) : null,
1293
- !e.fitContent && ((c = (d = e.builderBlock) == null ? void 0 : d.children) != null && c.length) ? /* @__PURE__ */ s("div", { className: "div-9dac2184-2", children: e.children }) : null
1318
+ (l = (o = e.builderBlock) == null ? void 0 : o.children) != null && l.length && e.fitContent ? /* @__PURE__ */ s(R, { children: e.children }) : null,
1319
+ !e.fitContent && ((c = (u = e.builderBlock) == null ? void 0 : u.children) != null && c.length) ? /* @__PURE__ */ s("div", { className: "div-9dac2184-2", children: e.children }) : null
1294
1320
  ] }),
1295
1321
  /* @__PURE__ */ s("style", { children: `.img-9dac2184 {
1296
1322
  opacity: 1;
@@ -1332,7 +1358,7 @@ function Yt(e) {
1332
1358
  }
1333
1359
  );
1334
1360
  }
1335
- const Q = {
1361
+ const ee = {
1336
1362
  "@type": "@builder.io/sdk:Element",
1337
1363
  layerName: "Accordion item title",
1338
1364
  responsiveStyles: {
@@ -1361,7 +1387,7 @@ const Q = {
1361
1387
  }
1362
1388
  }
1363
1389
  }]
1364
- }, X = {
1390
+ }, te = {
1365
1391
  "@type": "@builder.io/sdk:Element",
1366
1392
  layerName: "Accordion item detail",
1367
1393
  responsiveStyles: {
@@ -1392,7 +1418,7 @@ const Q = {
1392
1418
  }
1393
1419
  }
1394
1420
  }]
1395
- }, Qt = {
1421
+ }, Xt = {
1396
1422
  name: "Builder:Accordion",
1397
1423
  canHaveChildren: !0,
1398
1424
  image: "https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",
@@ -1409,19 +1435,19 @@ const Q = {
1409
1435
  name: "title",
1410
1436
  type: "uiBlocks",
1411
1437
  hideFromUI: !0,
1412
- defaultValue: [Q]
1438
+ defaultValue: [ee]
1413
1439
  }, {
1414
1440
  name: "detail",
1415
1441
  type: "uiBlocks",
1416
1442
  hideFromUI: !0,
1417
- defaultValue: [X]
1443
+ defaultValue: [te]
1418
1444
  }],
1419
1445
  defaultValue: [{
1420
- title: [Q],
1421
- detail: [X]
1446
+ title: [ee],
1447
+ detail: [te]
1422
1448
  }, {
1423
- title: [Q],
1424
- detail: [X]
1449
+ title: [ee],
1450
+ detail: [te]
1425
1451
  }],
1426
1452
  showIf: (e) => !e.get("useChildrenForItems")
1427
1453
  }, {
@@ -1456,14 +1482,14 @@ const Q = {
1456
1482
  builderComponents: !0,
1457
1483
  builderLinkComponent: !0
1458
1484
  }
1459
- }, ye = (e) => e.toString();
1460
- function Xt(e) {
1461
- var m;
1462
- const [t, n] = R(() => []);
1485
+ }, ve = (e) => e.toString();
1486
+ function Zt(e) {
1487
+ var g;
1488
+ const [t, n] = E(() => []);
1463
1489
  function i() {
1464
1490
  return !!(e.grid || e.oneAtATime);
1465
1491
  }
1466
- function o() {
1492
+ function a() {
1467
1493
  return {
1468
1494
  display: "flex",
1469
1495
  alignItems: "stretch",
@@ -1485,74 +1511,74 @@ function Xt(e) {
1485
1511
  cursor: "pointer"
1486
1512
  };
1487
1513
  return Object.fromEntries(
1488
- Object.entries(k).filter(([g, v]) => v !== void 0)
1514
+ Object.entries(k).filter(([f, b]) => b !== void 0)
1489
1515
  );
1490
1516
  }
1491
- function a(u) {
1492
- return `builder-accordion-title builder-accordion-title-${t.includes(u) ? "open" : "closed"}`;
1517
+ function o(d) {
1518
+ return `builder-accordion-title builder-accordion-title-${t.includes(d) ? "open" : "closed"}`;
1493
1519
  }
1494
- function l(u) {
1495
- return `builder-accordion-detail builder-accordion-detail-${t.includes(u) ? "open" : "closed"}`;
1520
+ function l(d) {
1521
+ return `builder-accordion-detail builder-accordion-detail-${t.includes(d) ? "open" : "closed"}`;
1496
1522
  }
1497
- function d() {
1498
- let u = null;
1523
+ function u() {
1524
+ let d = null;
1499
1525
  if (e.grid && t.length && document) {
1500
- const g = t[0];
1501
- let y = document.querySelector(
1502
- `.builder-accordion-title[data-index="${g}"]`
1526
+ const f = t[0];
1527
+ let x = document.querySelector(
1528
+ `.builder-accordion-title[data-index="${f}"]`
1503
1529
  );
1504
- if (u = g, y) {
1505
- let b = y.getBoundingClientRect();
1506
- for (; y = y && y.nextElementSibling; )
1507
- if (y) {
1508
- if (y.classList.contains("builder-accordion-detail"))
1530
+ if (d = f, x) {
1531
+ let y = x.getBoundingClientRect();
1532
+ for (; x = x && x.nextElementSibling; )
1533
+ if (x) {
1534
+ if (x.classList.contains("builder-accordion-detail"))
1509
1535
  continue;
1510
- const p = y.getBoundingClientRect();
1511
- if (p.left > b.left) {
1512
- const C = parseInt(
1513
- y.getAttribute("data-index") || "",
1536
+ const S = x.getBoundingClientRect();
1537
+ if (S.left > y.left) {
1538
+ const T = parseInt(
1539
+ x.getAttribute("data-index") || "",
1514
1540
  10
1515
1541
  );
1516
- isNaN(C) || (b = p, u = C);
1542
+ isNaN(T) || (y = S, d = T);
1517
1543
  } else
1518
1544
  break;
1519
1545
  }
1520
1546
  }
1521
1547
  }
1522
- return typeof u == "number" && (u = u + 1), u;
1548
+ return typeof d == "number" && (d = d + 1), d;
1523
1549
  }
1524
1550
  function c() {
1525
- const u = {
1526
- order: typeof d() == "number" ? d() : void 0,
1551
+ const d = {
1552
+ order: typeof u() == "number" ? u() : void 0,
1527
1553
  ...e.grid && {
1528
1554
  width: "100%"
1529
1555
  }
1530
1556
  };
1531
1557
  return Object.fromEntries(
1532
- Object.entries(u).filter(([k, g]) => g !== void 0)
1558
+ Object.entries(d).filter(([k, f]) => f !== void 0)
1533
1559
  );
1534
1560
  }
1535
- function h(u) {
1536
- t.includes(u) ? n(i() ? [] : t.filter((k) => k !== u)) : n(i() ? [u] : t.concat(u));
1561
+ function h(d) {
1562
+ t.includes(d) ? n(i() ? [] : t.filter((k) => k !== d)) : n(i() ? [d] : t.concat(d));
1537
1563
  }
1538
- return /* @__PURE__ */ s("div", { className: "builder-accordion", style: o(), children: (m = e.items) == null ? void 0 : m.map((u, k) => /* @__PURE__ */ B(Ge.Fragment, { children: [
1564
+ return /* @__PURE__ */ s("div", { className: "builder-accordion", style: a(), children: (g = e.items) == null ? void 0 : g.map((d, k) => /* @__PURE__ */ V(Qe.Fragment, { children: [
1539
1565
  /* @__PURE__ */ s(
1540
1566
  "div",
1541
1567
  {
1542
- className: a(k),
1568
+ className: o(k),
1543
1569
  style: {
1544
1570
  ...r(),
1545
1571
  ...e.grid && {
1546
1572
  width: e.gridRowWidth,
1547
- order: d() !== null ? ye(k) : ye(k + 1)
1573
+ order: u() !== null ? ve(k) : ve(k + 1)
1548
1574
  }
1549
1575
  },
1550
1576
  "data-index": k,
1551
- onClick: (g) => h(k),
1577
+ onClick: (f) => h(k),
1552
1578
  children: /* @__PURE__ */ s(
1553
- F,
1579
+ $,
1554
1580
  {
1555
- blocks: u.title,
1581
+ blocks: d.title,
1556
1582
  path: `items.${k}.title`,
1557
1583
  parent: e.builderBlock.id,
1558
1584
  context: e.builderContext,
@@ -1568,9 +1594,9 @@ function Xt(e) {
1568
1594
  className: l(k),
1569
1595
  style: c(),
1570
1596
  children: /* @__PURE__ */ s(
1571
- F,
1597
+ $,
1572
1598
  {
1573
- blocks: u.detail,
1599
+ blocks: d.detail,
1574
1600
  path: `items.${k}.detail`,
1575
1601
  parent: e.builderBlock.id,
1576
1602
  context: e.builderContext,
@@ -1582,7 +1608,7 @@ function Xt(e) {
1582
1608
  ) : null
1583
1609
  ] }, k)) });
1584
1610
  }
1585
- const Zt = {
1611
+ const en = {
1586
1612
  name: "Core:Button",
1587
1613
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
1588
1614
  defaultStyles: {
@@ -1618,7 +1644,7 @@ const Zt = {
1618
1644
  shouldReceiveBuilderProps: {
1619
1645
  builderLinkComponent: !0
1620
1646
  }
1621
- }, en = {
1647
+ }, tn = {
1622
1648
  // TODO: ways to statically preprocess JSON for references, functions, etc
1623
1649
  name: "Columns",
1624
1650
  isRSC: !0,
@@ -1797,7 +1823,7 @@ const Zt = {
1797
1823
  });
1798
1824
  }
1799
1825
  const n = e.get("columns");
1800
- Array.isArray(n) && n.find((o) => o.get("width")) && (n.find((r) => !r.get("width")) || n.reduce((l, d) => l + d.get("width"), 0) !== 100) && t();
1826
+ Array.isArray(n) && n.find((a) => a.get("width")) && (n.find((r) => !r.get("width")) || n.reduce((l, u) => l + u.get("width"), 0) !== 100) && t();
1801
1827
  }
1802
1828
  }, {
1803
1829
  name: "space",
@@ -1825,13 +1851,13 @@ const Zt = {
1825
1851
  builderComponents: !0,
1826
1852
  builderLinkComponent: !0
1827
1853
  }
1828
- }, tn = {
1854
+ }, nn = {
1829
1855
  name: "Fragment",
1830
1856
  static: !0,
1831
1857
  hidden: !0,
1832
1858
  canHaveChildren: !0,
1833
1859
  noWrap: !0
1834
- }, de = ["jpeg", "jpg", "png", "svg", "webp", "gif", "jfif", "pjpeg", "pjp", "apng", "avif", "tif", "tiff", "heif", "bmp", "eps", "raw", "cr2", "nef", "orf", "sr2", "psd", "heic", "dib", "ai"], nn = ["mp4", "webm", "mkv", "flv", "vob", "ogv", "ogg", "drc", "gif", "gifv", "mng", "avi", "mov", "qt", "mts", "m2ts", "ts", "wmv", "yuv", "rm", "rmvb", "viv", "asf", "amv", "m4p", "mpeg", "mpe", "m2v", "m4v", "svi", "3gp", "3g2", "mxf", "roq", "nsv", "f4v", "f4p", "f4a", "f4b"], on = {
1860
+ }, de = ["jpeg", "jpg", "png", "svg", "webp", "gif", "jfif", "pjpeg", "pjp", "apng", "avif", "tif", "tiff", "heif", "bmp", "eps", "raw", "cr2", "nef", "orf", "sr2", "psd", "heic", "dib", "ai"], an = ["mp4", "webm", "mkv", "flv", "vob", "ogv", "ogg", "drc", "gif", "gifv", "mng", "avi", "mov", "qt", "mts", "m2ts", "ts", "wmv", "yuv", "rm", "rmvb", "viv", "asf", "amv", "m4p", "mpeg", "mpe", "m2v", "m4v", "svi", "3gp", "3g2", "mxf", "roq", "nsv", "f4v", "f4p", "f4a", "f4b"], on = {
1835
1861
  name: "Image",
1836
1862
  static: !0,
1837
1863
  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",
@@ -1851,29 +1877,29 @@ const Zt = {
1851
1877
  defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
1852
1878
  onChange: (e) => {
1853
1879
  e.delete("srcset"), e.delete("noWebp");
1854
- function n(a, l = 6e4) {
1855
- return new Promise((d, c) => {
1880
+ function n(o, l = 6e4) {
1881
+ return new Promise((u, c) => {
1856
1882
  const h = document.createElement("img");
1857
- let m = !1;
1883
+ let g = !1;
1858
1884
  h.onload = () => {
1859
- m = !0, d(h);
1860
- }, h.addEventListener("error", (u) => {
1861
- console.warn("Image load failed", u.error), c(u.error);
1862
- }), h.src = a, setTimeout(() => {
1863
- m || c(new Error("Image load timed out"));
1885
+ g = !0, u(h);
1886
+ }, h.addEventListener("error", (d) => {
1887
+ console.warn("Image load failed", d.error), c(d.error);
1888
+ }), h.src = o, setTimeout(() => {
1889
+ g || c(new Error("Image load timed out"));
1864
1890
  }, l);
1865
1891
  });
1866
1892
  }
1867
- function i(a) {
1868
- return Math.round(a * 1e3) / 1e3;
1893
+ function i(o) {
1894
+ return Math.round(o * 1e3) / 1e3;
1869
1895
  }
1870
- const o = e.get("image"), r = e.get("aspectRatio");
1871
- if (fetch(o).then((a) => a.blob()).then((a) => {
1872
- a.type.includes("svg") && e.set("noWebp", !0);
1873
- }), o && (!r || r === 0.7041))
1874
- return n(o).then((a) => {
1896
+ const a = e.get("image"), r = e.get("aspectRatio");
1897
+ if (fetch(a).then((o) => o.blob()).then((o) => {
1898
+ o.type.includes("svg") && e.set("noWebp", !0);
1899
+ }), a && (!r || r === 0.7041))
1900
+ return n(a).then((o) => {
1875
1901
  const l = e.get("aspectRatio");
1876
- e.get("image") === o && (!l || l === 0.7041) && a.width && a.height && (e.set("aspectRatio", i(a.height / a.width)), e.set("height", a.height), e.set("width", a.width));
1902
+ e.get("image") === a && (!l || l === 0.7041) && o.width && o.height && (e.set("aspectRatio", i(o.height / o.width)), e.set("height", o.height), e.set("width", o.width));
1877
1903
  });
1878
1904
  }
1879
1905
  }, {
@@ -1939,7 +1965,426 @@ const Zt = {
1939
1965
  shouldReceiveBuilderProps: {
1940
1966
  builderBlock: !0
1941
1967
  }
1942
- }, an = {
1968
+ }, rn = {
1969
+ name: "PersonalizationContainer",
1970
+ shouldReceiveBuilderProps: {
1971
+ builderBlock: !0,
1972
+ builderContext: !0
1973
+ },
1974
+ noWrap: !0,
1975
+ image: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F37229ed30d8c41dfb10b8cca1992053a",
1976
+ canHaveChildren: !0,
1977
+ inputs: [{
1978
+ name: "variants",
1979
+ defaultValue: [],
1980
+ behavior: "personalizationVariantList",
1981
+ type: "list",
1982
+ subFields: [{
1983
+ name: "name",
1984
+ type: "text"
1985
+ }, {
1986
+ name: "query",
1987
+ friendlyName: "Targeting rules",
1988
+ type: "BuilderQuery",
1989
+ defaultValue: []
1990
+ }, {
1991
+ name: "startDate",
1992
+ type: "date"
1993
+ }, {
1994
+ name: "endDate",
1995
+ type: "date"
1996
+ }, {
1997
+ name: "blocks",
1998
+ type: "uiBlocks",
1999
+ hideFromUI: !0,
2000
+ defaultValue: []
2001
+ }]
2002
+ }]
2003
+ };
2004
+ function J(e) {
2005
+ return /* @__PURE__ */ s(
2006
+ "script",
2007
+ {
2008
+ dangerouslySetInnerHTML: { __html: e.scriptStr },
2009
+ "data-id": e.id,
2010
+ nonce: e.nonce || ""
2011
+ }
2012
+ );
2013
+ }
2014
+ function ln(e, t, n, i) {
2015
+ function a(c) {
2016
+ return typeof c == "string";
2017
+ }
2018
+ function r(c) {
2019
+ return typeof c == "number";
2020
+ }
2021
+ function o(c, h) {
2022
+ return (() => {
2023
+ const d = h.property, k = h.operator;
2024
+ let f = h.value;
2025
+ if (h && h.property === "urlPath" && h.value && typeof h.value == "string" && h.value !== "/" && h.value.endsWith("/") && (f = h.value.slice(0, -1)), !(d && k))
2026
+ return !0;
2027
+ if (Array.isArray(f))
2028
+ return k === "isNot" ? f.every((x) => o(c, {
2029
+ property: d,
2030
+ operator: k,
2031
+ value: x
2032
+ })) : !!f.find((x) => o(c, {
2033
+ property: d,
2034
+ operator: k,
2035
+ value: x
2036
+ }));
2037
+ const b = c[d];
2038
+ if (Array.isArray(b))
2039
+ return b.includes(f);
2040
+ switch (k) {
2041
+ case "is":
2042
+ return b === f;
2043
+ case "isNot":
2044
+ return b !== f;
2045
+ case "contains":
2046
+ return (a(b) || Array.isArray(b)) && b.includes(String(f));
2047
+ case "startsWith":
2048
+ return a(b) && b.startsWith(String(f));
2049
+ case "endsWith":
2050
+ return a(b) && b.endsWith(String(f));
2051
+ case "greaterThan":
2052
+ return r(b) && r(f) && b > f;
2053
+ case "lessThan":
2054
+ return r(b) && r(f) && b < f;
2055
+ case "greaterThanOrEqualTo":
2056
+ return r(b) && r(f) && b >= f;
2057
+ case "lessThanOrEqualTo":
2058
+ return r(b) && r(f) && b <= f;
2059
+ default:
2060
+ return !1;
2061
+ }
2062
+ })();
2063
+ }
2064
+ const l = {
2065
+ query: t,
2066
+ startDate: n,
2067
+ endDate: i
2068
+ }, u = e.date && new Date(e.date) || /* @__PURE__ */ new Date();
2069
+ return l.startDate && new Date(l.startDate) > u || l.endDate && new Date(l.endDate) < u ? !1 : !l.query || !l.query.length ? !0 : l.query.every((c) => o(e, c));
2070
+ }
2071
+ const sn = `function getPersonalizedVariant(variants, blockId, locale) {
2072
+ if (!navigator.cookieEnabled) {
2073
+ return;
2074
+ }
2075
+ function getCookie(name) {
2076
+ const nameEQ = name + '=';
2077
+ const ca = document.cookie.split(';');
2078
+ for (let i = 0; i < ca.length; i++) {
2079
+ let c = ca[i];
2080
+ while (c.charAt(0) == ' ') c = c.substring(1, c.length);
2081
+ if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length, c.length);
2082
+ }
2083
+ return null;
2084
+ }
2085
+ function removeVariants() {
2086
+ variants?.forEach(function (_, index) {
2087
+ document.querySelector('template[data-variant-id="' + blockId + '-' + index + '"]')?.remove();
2088
+ });
2089
+ document.querySelector('script[data-id="variants-script-' + blockId + '"]')?.remove();
2090
+ document.querySelector('style[data-id="variants-styles-' + blockId + '"]')?.remove();
2091
+ }
2092
+ const attributes = JSON.parse(getCookie('builder.userAttributes') || '{}');
2093
+ if (locale) {
2094
+ attributes.locale = locale;
2095
+ }
2096
+ const winningVariantIndex = variants?.findIndex(function (variant) {
2097
+ return filterWithCustomTargeting(attributes, variant.query, variant.startDate, variant.endDate);
2098
+ });
2099
+ const isDebug = location.href.includes('builder.debug=true');
2100
+ if (isDebug) {
2101
+ console.debug('PersonalizationContainer', {
2102
+ attributes,
2103
+ variants,
2104
+ winningVariantIndex
2105
+ });
2106
+ }
2107
+ if (winningVariantIndex !== -1) {
2108
+ const winningVariant = document.querySelector('template[data-variant-id="' + blockId + '-' + winningVariantIndex + '"]');
2109
+ if (winningVariant) {
2110
+ const parentNode = winningVariant.parentNode;
2111
+ if (parentNode) {
2112
+ const newParent = parentNode.cloneNode(false);
2113
+ newParent.appendChild(winningVariant.content.firstChild);
2114
+ newParent.appendChild(winningVariant.content.lastChild);
2115
+ parentNode.parentNode?.replaceChild(newParent, parentNode);
2116
+ }
2117
+ if (isDebug) {
2118
+ console.debug('PersonalizationContainer', 'Winning variant Replaced:', winningVariant);
2119
+ }
2120
+ }
2121
+ } else if (variants && variants.length > 0) {
2122
+ removeVariants();
2123
+ }
2124
+ }`, cn = `function filterWithCustomTargeting(userAttributes, query, startDate, endDate) {
2125
+ function isString(val) {
2126
+ return typeof val === 'string';
2127
+ }
2128
+ function isNumber(val) {
2129
+ return typeof val === 'number';
2130
+ }
2131
+ function objectMatchesQuery(userattr, query) {
2132
+ const result = (() => {
2133
+ const property = query.property;
2134
+ const operator = query.operator;
2135
+ let testValue = query.value;
2136
+ if (query && query.property === 'urlPath' && query.value && typeof query.value === 'string' && query.value !== '/' && query.value.endsWith('/')) {
2137
+ testValue = query.value.slice(0, -1);
2138
+ }
2139
+ if (!(property && operator)) {
2140
+ return true;
2141
+ }
2142
+ if (Array.isArray(testValue)) {
2143
+ if (operator === 'isNot') {
2144
+ return testValue.every(val => objectMatchesQuery(userattr, {
2145
+ property,
2146
+ operator,
2147
+ value: val
2148
+ }));
2149
+ }
2150
+ return !!testValue.find(val => objectMatchesQuery(userattr, {
2151
+ property,
2152
+ operator,
2153
+ value: val
2154
+ }));
2155
+ }
2156
+ const value = userattr[property];
2157
+ if (Array.isArray(value)) {
2158
+ return value.includes(testValue);
2159
+ }
2160
+ switch (operator) {
2161
+ case 'is':
2162
+ return value === testValue;
2163
+ case 'isNot':
2164
+ return value !== testValue;
2165
+ case 'contains':
2166
+ return (isString(value) || Array.isArray(value)) && value.includes(String(testValue));
2167
+ case 'startsWith':
2168
+ return isString(value) && value.startsWith(String(testValue));
2169
+ case 'endsWith':
2170
+ return isString(value) && value.endsWith(String(testValue));
2171
+ case 'greaterThan':
2172
+ return isNumber(value) && isNumber(testValue) && value > testValue;
2173
+ case 'lessThan':
2174
+ return isNumber(value) && isNumber(testValue) && value < testValue;
2175
+ case 'greaterThanOrEqualTo':
2176
+ return isNumber(value) && isNumber(testValue) && value >= testValue;
2177
+ case 'lessThanOrEqualTo':
2178
+ return isNumber(value) && isNumber(testValue) && value <= testValue;
2179
+ default:
2180
+ return false;
2181
+ }
2182
+ })();
2183
+ return result;
2184
+ }
2185
+ const item = {
2186
+ query,
2187
+ startDate,
2188
+ endDate
2189
+ };
2190
+ const now = userAttributes.date && new Date(userAttributes.date) || new Date();
2191
+ if (item.startDate && new Date(item.startDate) > now) {
2192
+ return false;
2193
+ } else if (item.endDate && new Date(item.endDate) < now) {
2194
+ return false;
2195
+ }
2196
+ if (!item.query || !item.query.length) {
2197
+ return true;
2198
+ }
2199
+ return item.query.every(filter => {
2200
+ return objectMatchesQuery(userAttributes, filter);
2201
+ });
2202
+ }`;
2203
+ function un(e, t) {
2204
+ return !(!(e && e.length > 0) || !t || L());
2205
+ }
2206
+ function dn({
2207
+ variants: e,
2208
+ previewingIndex: t,
2209
+ isHydrated: n,
2210
+ filteredVariants: i,
2211
+ fallbackBlocks: a
2212
+ }) {
2213
+ var o;
2214
+ const r = {
2215
+ blocks: a != null ? a : [],
2216
+ path: "this.children"
2217
+ };
2218
+ if (n && W())
2219
+ return typeof t == "number" && t < ((o = e == null ? void 0 : e.length) != null ? o : 0) ? {
2220
+ blocks: e[t].blocks,
2221
+ path: `component.options.variants.${t}.blocks`
2222
+ } : r;
2223
+ if (L()) {
2224
+ const l = i == null ? void 0 : i[0];
2225
+ if (l)
2226
+ return {
2227
+ blocks: l.blocks,
2228
+ path: `component.options.variants.${e == null ? void 0 : e.indexOf(l)}.blocks`
2229
+ };
2230
+ }
2231
+ return r;
2232
+ }
2233
+ const mn = (e, t, n) => `
2234
+ (function() {
2235
+ ${cn}
2236
+ ${sn}
2237
+ getPersonalizedVariant(${JSON.stringify(e)}, "${t}"${n ? `, "${n}"` : ""})
2238
+ })();
2239
+ `;
2240
+ function fn(e) {
2241
+ var b, x, y, S, T, P, I;
2242
+ const t = D(null), [n, i] = E(
2243
+ () => me.getUserAttributes()
2244
+ ), [a, r] = E(
2245
+ () => {
2246
+ var v, m, p;
2247
+ return mn(
2248
+ e.variants,
2249
+ ((v = e.builderBlock) == null ? void 0 : v.id) || "none",
2250
+ (p = (m = e.builderContext) == null ? void 0 : m.rootState) == null ? void 0 : p.locale
2251
+ );
2252
+ }
2253
+ ), [o, l] = E(() => []), [u, c] = E(
2254
+ () => {
2255
+ var v;
2256
+ return un(
2257
+ e.variants,
2258
+ q((v = e.builderContext) == null ? void 0 : v.canTrack)
2259
+ );
2260
+ }
2261
+ ), [h, g] = E(() => !1);
2262
+ function d() {
2263
+ return (e.variants || []).filter((v) => {
2264
+ var m, p, C, w;
2265
+ return ln(
2266
+ {
2267
+ ...(p = (m = e.builderContext) == null ? void 0 : m.rootState) != null && p.locale ? {
2268
+ locale: (w = (C = e.builderContext) == null ? void 0 : C.rootState) == null ? void 0 : w.locale
2269
+ } : {},
2270
+ ...n
2271
+ },
2272
+ v.query,
2273
+ v.startDate,
2274
+ v.endDate
2275
+ );
2276
+ });
2277
+ }
2278
+ function k() {
2279
+ var v;
2280
+ return dn({
2281
+ variants: e.variants,
2282
+ fallbackBlocks: (v = e.builderBlock) == null ? void 0 : v.children,
2283
+ isHydrated: h,
2284
+ filteredVariants: d(),
2285
+ previewingIndex: e.previewingIndex
2286
+ });
2287
+ }
2288
+ function f() {
2289
+ return (e.variants || []).map(
2290
+ (v, m) => {
2291
+ var p;
2292
+ return `[data-variant-id="${(p = e.builderBlock) == null ? void 0 : p.id}-${m}"] { display: none; } `;
2293
+ }
2294
+ ).join("");
2295
+ }
2296
+ return A(() => {
2297
+ var m;
2298
+ g(!0);
2299
+ const v = me.subscribeOnUserAttributesChange(
2300
+ (p) => {
2301
+ i(p);
2302
+ }
2303
+ );
2304
+ if (!(W() || G())) {
2305
+ const p = d()[0];
2306
+ t.current && (t.current.dispatchEvent(
2307
+ new CustomEvent("builder.variantLoaded", {
2308
+ detail: {
2309
+ variant: p || "default",
2310
+ content: (m = e.builderContext) == null ? void 0 : m.content
2311
+ },
2312
+ bubbles: !0
2313
+ })
2314
+ ), new IntersectionObserver((w) => {
2315
+ w.forEach((B) => {
2316
+ var N;
2317
+ B.isIntersecting && t.current && t.current.dispatchEvent(
2318
+ new CustomEvent("builder.variantDisplayed", {
2319
+ detail: {
2320
+ variant: p || "default",
2321
+ content: (N = e.builderContext) == null ? void 0 : N.content
2322
+ },
2323
+ bubbles: !0
2324
+ })
2325
+ );
2326
+ });
2327
+ }).observe(t.current));
2328
+ }
2329
+ o.push(v);
2330
+ }, []), A(() => () => {
2331
+ o.forEach((v) => v());
2332
+ }, []), /* @__PURE__ */ V(
2333
+ "div",
2334
+ {
2335
+ ref: t,
2336
+ ...e.attributes,
2337
+ className: `builder-personalization-container ${((b = e.attributes) == null ? void 0 : b.className) || ""}`,
2338
+ children: [
2339
+ u ? /* @__PURE__ */ V(R, { children: [
2340
+ (x = e.variants) == null ? void 0 : x.map((v, m) => {
2341
+ var p, C;
2342
+ return /* @__PURE__ */ s(
2343
+ "template",
2344
+ {
2345
+ "data-variant-id": `${(p = e.builderBlock) == null ? void 0 : p.id}-${m}`,
2346
+ children: /* @__PURE__ */ s(
2347
+ $,
2348
+ {
2349
+ blocks: v.blocks,
2350
+ parent: (C = e.builderBlock) == null ? void 0 : C.id,
2351
+ path: `component.options.variants.${m}.blocks`
2352
+ }
2353
+ )
2354
+ },
2355
+ m
2356
+ );
2357
+ }),
2358
+ /* @__PURE__ */ s(
2359
+ M,
2360
+ {
2361
+ nonce: ((y = e.builderContext) == null ? void 0 : y.nonce) || "",
2362
+ styles: f(),
2363
+ id: `variants-styles-${(S = e.builderBlock) == null ? void 0 : S.id}`
2364
+ }
2365
+ ),
2366
+ /* @__PURE__ */ s(
2367
+ J,
2368
+ {
2369
+ nonce: ((T = e.builderContext) == null ? void 0 : T.nonce) || "",
2370
+ scriptStr: a,
2371
+ id: `variants-script-${(P = e.builderBlock) == null ? void 0 : P.id}`
2372
+ }
2373
+ )
2374
+ ] }) : null,
2375
+ /* @__PURE__ */ s(
2376
+ $,
2377
+ {
2378
+ blocks: k().blocks,
2379
+ parent: (I = e.builderBlock) == null ? void 0 : I.id,
2380
+ path: k().path
2381
+ }
2382
+ )
2383
+ ]
2384
+ }
2385
+ );
2386
+ }
2387
+ const hn = {
1943
2388
  name: "Core:Section",
1944
2389
  static: !0,
1945
2390
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
@@ -1978,7 +2423,7 @@ const Zt = {
1978
2423
  }
1979
2424
  }
1980
2425
  }]
1981
- }, rn = {
2426
+ }, gn = {
1982
2427
  name: "Slot",
1983
2428
  isRSC: !0,
1984
2429
  description: "Allow child blocks to be inserted into this content when used as a Symbol",
@@ -1996,7 +2441,7 @@ const Zt = {
1996
2441
  builderComponents: !0
1997
2442
  }
1998
2443
  };
1999
- function ln(e) {
2444
+ function bn(e) {
2000
2445
  var t, n, i;
2001
2446
  return /* @__PURE__ */ s(
2002
2447
  "div",
@@ -2008,7 +2453,7 @@ function ln(e) {
2008
2453
  "builder-slot": e.name
2009
2454
  },
2010
2455
  children: /* @__PURE__ */ s(
2011
- F,
2456
+ $,
2012
2457
  {
2013
2458
  parent: (n = e.builderContext.context) == null ? void 0 : n.symbolId,
2014
2459
  path: `symbol.data.${e.name}`,
@@ -2020,7 +2465,7 @@ function ln(e) {
2020
2465
  }
2021
2466
  );
2022
2467
  }
2023
- const sn = {
2468
+ const pn = {
2024
2469
  name: "Symbol",
2025
2470
  noWrap: !0,
2026
2471
  static: !0,
@@ -2059,7 +2504,7 @@ const sn = {
2059
2504
  builderComponents: !0,
2060
2505
  builderLinkComponent: !0
2061
2506
  }
2062
- }, Z = {
2507
+ }, ne = {
2063
2508
  "@type": "@builder.io/sdk:Element",
2064
2509
  responsiveStyles: {
2065
2510
  large: {
@@ -2081,7 +2526,7 @@ const sn = {
2081
2526
  text: "New tab"
2082
2527
  }
2083
2528
  }
2084
- }, ee = {
2529
+ }, ie = {
2085
2530
  "@type": "@builder.io/sdk:Element",
2086
2531
  responsiveStyles: {
2087
2532
  large: {
@@ -2097,7 +2542,7 @@ const sn = {
2097
2542
  text: "New tab content "
2098
2543
  }
2099
2544
  }
2100
- }, cn = {
2545
+ }, yn = {
2101
2546
  name: "Builder: Tabs",
2102
2547
  inputs: [{
2103
2548
  name: "tabs",
@@ -2107,16 +2552,16 @@ const sn = {
2107
2552
  name: "label",
2108
2553
  type: "uiBlocks",
2109
2554
  hideFromUI: !0,
2110
- defaultValue: [Z]
2555
+ defaultValue: [ne]
2111
2556
  }, {
2112
2557
  name: "content",
2113
2558
  type: "uiBlocks",
2114
2559
  hideFromUI: !0,
2115
- defaultValue: [ee]
2560
+ defaultValue: [ie]
2116
2561
  }],
2117
2562
  defaultValue: [{
2118
2563
  label: [{
2119
- ...Z,
2564
+ ...ne,
2120
2565
  component: {
2121
2566
  name: "Text",
2122
2567
  options: {
@@ -2125,7 +2570,7 @@ const sn = {
2125
2570
  }
2126
2571
  }],
2127
2572
  content: [{
2128
- ...ee,
2573
+ ...ie,
2129
2574
  component: {
2130
2575
  name: "Text",
2131
2576
  options: {
@@ -2135,7 +2580,7 @@ const sn = {
2135
2580
  }]
2136
2581
  }, {
2137
2582
  label: [{
2138
- ...Z,
2583
+ ...ne,
2139
2584
  component: {
2140
2585
  name: "Text",
2141
2586
  options: {
@@ -2144,7 +2589,7 @@ const sn = {
2144
2589
  }
2145
2590
  }],
2146
2591
  content: [{
2147
- ...ee,
2592
+ ...ie,
2148
2593
  component: {
2149
2594
  name: "Text",
2150
2595
  options: {
@@ -2201,18 +2646,18 @@ const sn = {
2201
2646
  builderLinkComponent: !0
2202
2647
  }
2203
2648
  };
2204
- function dn(e) {
2649
+ function vn(e) {
2205
2650
  var r;
2206
- const [t, n] = R(
2651
+ const [t, n] = E(
2207
2652
  () => e.defaultActiveTab ? e.defaultActiveTab - 1 : 0
2208
2653
  );
2209
- function i(a) {
2210
- return e.tabs && e.tabs[a].content;
2654
+ function i(o) {
2655
+ return e.tabs && e.tabs[o].content;
2211
2656
  }
2212
- function o(a) {
2213
- a === t && e.collapsible ? n(-1) : n(a);
2657
+ function a(o) {
2658
+ o === t && e.collapsible ? n(-1) : n(o);
2214
2659
  }
2215
- return /* @__PURE__ */ B("div", { children: [
2660
+ return /* @__PURE__ */ V("div", { children: [
2216
2661
  /* @__PURE__ */ s(
2217
2662
  "div",
2218
2663
  {
@@ -2223,20 +2668,20 @@ function dn(e) {
2223
2668
  justifyContent: e.tabHeaderLayout || "flex-start",
2224
2669
  overflow: "auto"
2225
2670
  },
2226
- children: (r = e.tabs) == null ? void 0 : r.map((a, l) => /* @__PURE__ */ s(
2671
+ children: (r = e.tabs) == null ? void 0 : r.map((o, l) => /* @__PURE__ */ s(
2227
2672
  "span",
2228
2673
  {
2229
2674
  className: `builder-tab-wrap ${t === l ? "builder-tab-active" : ""}`,
2230
2675
  style: {
2231
2676
  ...t === l ? e.activeTabStyle : {}
2232
2677
  },
2233
- onClick: (d) => o(l),
2678
+ onClick: (u) => a(l),
2234
2679
  children: /* @__PURE__ */ s(
2235
- F,
2680
+ $,
2236
2681
  {
2237
2682
  parent: e.builderBlock.id,
2238
2683
  path: `tabs.${l}.label`,
2239
- blocks: a.label,
2684
+ blocks: o.label,
2240
2685
  context: e.builderContext,
2241
2686
  registeredComponents: e.builderComponents,
2242
2687
  linkComponent: e.builderLinkComponent
@@ -2248,7 +2693,7 @@ function dn(e) {
2248
2693
  }
2249
2694
  ),
2250
2695
  i(t) ? /* @__PURE__ */ s("div", { children: /* @__PURE__ */ s(
2251
- F,
2696
+ $,
2252
2697
  {
2253
2698
  parent: e.builderBlock.id,
2254
2699
  path: `tabs.${t}.content`,
@@ -2260,7 +2705,7 @@ function dn(e) {
2260
2705
  ) }) : null
2261
2706
  ] });
2262
2707
  }
2263
- const un = {
2708
+ const xn = {
2264
2709
  shouldReceiveBuilderProps: {
2265
2710
  builderBlock: !1,
2266
2711
  builderContext: !0
@@ -2283,7 +2728,7 @@ const un = {
2283
2728
  textAlign: "center"
2284
2729
  }
2285
2730
  };
2286
- function mn(e) {
2731
+ function Sn(e) {
2287
2732
  var t;
2288
2733
  return /* @__PURE__ */ s(
2289
2734
  "div",
@@ -2296,7 +2741,7 @@ function mn(e) {
2296
2741
  }
2297
2742
  );
2298
2743
  }
2299
- const fn = {
2744
+ const kn = {
2300
2745
  name: "Custom Code",
2301
2746
  static: !0,
2302
2747
  requiredPermissions: ["editCode"],
@@ -2319,15 +2764,15 @@ const fn = {
2319
2764
  advanced: !0
2320
2765
  }]
2321
2766
  };
2322
- function hn(e) {
2323
- const t = L(null), [n, i] = R(() => []), [o, r] = R(() => []);
2767
+ function Cn(e) {
2768
+ const t = D(null), [n, i] = E(() => []), [a, r] = E(() => []);
2324
2769
  return A(() => {
2325
2770
  var l;
2326
2771
  if (!((l = t.current) != null && l.getElementsByTagName) || typeof window == "undefined")
2327
2772
  return;
2328
- const a = t.current.getElementsByTagName("script");
2329
- for (let d = 0; d < a.length; d++) {
2330
- const c = a[d];
2773
+ const o = t.current.getElementsByTagName("script");
2774
+ for (let u = 0; u < o.length; u++) {
2775
+ const c = o[u];
2331
2776
  if (c.src) {
2332
2777
  if (n.includes(c.src))
2333
2778
  continue;
@@ -2339,10 +2784,10 @@ function hn(e) {
2339
2784
  "application/javascript",
2340
2785
  "application/ecmascript"
2341
2786
  ].includes(c.type)) {
2342
- if (o.includes(c.innerText))
2787
+ if (a.includes(c.innerText))
2343
2788
  continue;
2344
2789
  try {
2345
- o.push(c.innerText), new Function(c.innerText)();
2790
+ a.push(c.innerText), new Function(c.innerText)();
2346
2791
  } catch (h) {
2347
2792
  console.warn("`CustomCode`: Error running script:", h);
2348
2793
  }
@@ -2357,7 +2802,7 @@ function hn(e) {
2357
2802
  }
2358
2803
  );
2359
2804
  }
2360
- const gn = {
2805
+ const Tn = {
2361
2806
  name: "Embed",
2362
2807
  static: !0,
2363
2808
  inputs: [{
@@ -2372,30 +2817,30 @@ const gn = {
2372
2817
  defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
2373
2818
  hideFromUI: !0
2374
2819
  }]
2375
- }, bn = ["text/javascript", "application/javascript", "application/ecmascript"], pn = (e) => bn.includes(e.type);
2376
- function yn(e) {
2377
- const t = L(null), [n, i] = R(() => []), [o, r] = R(() => []), [a, l] = R(() => !1);
2378
- function d() {
2820
+ }, wn = ["text/javascript", "application/javascript", "application/ecmascript"], In = (e) => wn.includes(e.type);
2821
+ function En(e) {
2822
+ const t = D(null), [n, i] = E(() => []), [a, r] = E(() => []), [o, l] = E(() => !1);
2823
+ function u() {
2379
2824
  if (!t.current || !t.current.getElementsByTagName)
2380
2825
  return;
2381
2826
  const c = t.current.getElementsByTagName("script");
2382
2827
  for (let h = 0; h < c.length; h++) {
2383
- const m = c[h];
2384
- if (m.src && !n.includes(m.src)) {
2385
- n.push(m.src);
2386
- const u = document.createElement("script");
2387
- u.async = !0, u.src = m.src, document.head.appendChild(u);
2388
- } else if (pn(m) && !o.includes(m.innerText))
2828
+ const g = c[h];
2829
+ if (g.src && !n.includes(g.src)) {
2830
+ n.push(g.src);
2831
+ const d = document.createElement("script");
2832
+ d.async = !0, d.src = g.src, document.head.appendChild(d);
2833
+ } else if (In(g) && !a.includes(g.innerText))
2389
2834
  try {
2390
- o.push(m.innerText), new Function(m.innerText)();
2391
- } catch (u) {
2392
- console.warn("`Embed`: Error running script:", u);
2835
+ a.push(g.innerText), new Function(g.innerText)();
2836
+ } catch (d) {
2837
+ console.warn("`Embed`: Error running script:", d);
2393
2838
  }
2394
2839
  }
2395
2840
  }
2396
2841
  return A(() => {
2397
- t.current && !a && (l(!0), d());
2398
- }, [t.current, a]), /* @__PURE__ */ s(
2842
+ t.current && !o && (l(!0), u());
2843
+ }, [t.current, o]), /* @__PURE__ */ s(
2399
2844
  "div",
2400
2845
  {
2401
2846
  className: "builder-embed",
@@ -2404,7 +2849,7 @@ function yn(e) {
2404
2849
  }
2405
2850
  );
2406
2851
  }
2407
- const xn = {
2852
+ const Rn = {
2408
2853
  name: "Form:Form",
2409
2854
  // editableTags: ['builder-form-error']
2410
2855
  defaults: {
@@ -2641,118 +3086,118 @@ const xn = {
2641
3086
  builderComponents: !0,
2642
3087
  builderLinkComponent: !0
2643
3088
  }
2644
- }, vn = ["production", "qa", "test", "development", "dev", "cdn-qa", "cloud", "fast", "cdn2", "cdn-prod"], Sn = () => {
3089
+ }, Pn = ["production", "qa", "test", "development", "dev", "cdn-qa", "cloud", "fast", "cdn2", "cdn-prod"], Vn = () => {
2645
3090
  const e = process.env.NODE_ENV || "production";
2646
- return vn.includes(e) ? e : "production";
3091
+ return Pn.includes(e) ? e : "production";
2647
3092
  };
2648
- function kn(e) {
2649
- const t = L(null), [n, i] = R(() => "unsubmitted"), [o, r] = R(() => null), [a, l] = R(() => "");
2650
- function d(m) {
2651
- var k, g;
2652
- const u = {
3093
+ function Bn(e) {
3094
+ const t = D(null), [n, i] = E(() => "unsubmitted"), [a, r] = E(() => null), [o, l] = E(() => "");
3095
+ function u(g) {
3096
+ var k, f;
3097
+ const d = {
2653
3098
  ...e.builderContext.rootState,
2654
- ...m
3099
+ ...g
2655
3100
  };
2656
- e.builderContext.rootSetState ? (g = (k = e.builderContext).rootSetState) == null || g.call(k, u) : e.builderContext.rootState = u;
3101
+ e.builderContext.rootSetState ? (f = (k = e.builderContext).rootSetState) == null || f.call(k, d) : e.builderContext.rootState = d;
2657
3102
  }
2658
3103
  function c() {
2659
- return N() && e.previewState || n;
3104
+ return W() && e.previewState || n;
2660
3105
  }
2661
- function h(m) {
3106
+ function h(g) {
2662
3107
  var k;
2663
- const u = e.sendWithJs || e.sendSubmissionsTo === "email";
3108
+ const d = e.sendWithJs || e.sendSubmissionsTo === "email";
2664
3109
  if (e.sendSubmissionsTo === "zapier")
2665
- m.preventDefault();
2666
- else if (u) {
3110
+ g.preventDefault();
3111
+ else if (d) {
2667
3112
  if (!(e.action || e.sendSubmissionsTo === "email")) {
2668
- m.preventDefault();
3113
+ g.preventDefault();
2669
3114
  return;
2670
3115
  }
2671
- m.preventDefault();
2672
- const g = m.currentTarget || m.target, v = e.customHeaders || {};
2673
- let y;
2674
- const b = new FormData(g), p = Array.from(g.querySelectorAll("input,select,textarea")).filter((f) => !!f.name).map((f) => {
2675
- let S;
2676
- const x = f.name;
2677
- if (f instanceof HTMLInputElement)
2678
- if (f.type === "radio") {
2679
- if (f.checked)
2680
- return S = f.name, {
2681
- key: x,
2682
- value: S
3116
+ g.preventDefault();
3117
+ const f = g.currentTarget || g.target, b = e.customHeaders || {};
3118
+ let x;
3119
+ const y = new FormData(f), S = Array.from(f.querySelectorAll("input,select,textarea")).filter((m) => !!m.name).map((m) => {
3120
+ let p;
3121
+ const C = m.name;
3122
+ if (m instanceof HTMLInputElement)
3123
+ if (m.type === "radio") {
3124
+ if (m.checked)
3125
+ return p = m.name, {
3126
+ key: C,
3127
+ value: p
2683
3128
  };
2684
- } else if (f.type === "checkbox")
2685
- S = f.checked;
2686
- else if (f.type === "number" || f.type === "range") {
2687
- const T = f.valueAsNumber;
2688
- isNaN(T) || (S = T);
3129
+ } else if (m.type === "checkbox")
3130
+ p = m.checked;
3131
+ else if (m.type === "number" || m.type === "range") {
3132
+ const w = m.valueAsNumber;
3133
+ isNaN(w) || (p = w);
2689
3134
  } else
2690
- f.type === "file" ? S = f.files : S = f.value;
3135
+ m.type === "file" ? p = m.files : p = m.value;
2691
3136
  else
2692
- S = f.value;
3137
+ p = m.value;
2693
3138
  return {
2694
- key: x,
2695
- value: S
3139
+ key: C,
3140
+ value: p
2696
3141
  };
2697
3142
  });
2698
- let C = e.contentType;
2699
- if (e.sendSubmissionsTo === "email" && (C = "multipart/form-data"), Array.from(p).forEach(({ value: f }) => {
2700
- (f instanceof File || Array.isArray(f) && f[0] instanceof File || f instanceof FileList) && (C = "multipart/form-data");
2701
- }), C !== "application/json")
2702
- y = b;
3143
+ let T = e.contentType;
3144
+ if (e.sendSubmissionsTo === "email" && (T = "multipart/form-data"), Array.from(S).forEach(({ value: m }) => {
3145
+ (m instanceof File || Array.isArray(m) && m[0] instanceof File || m instanceof FileList) && (T = "multipart/form-data");
3146
+ }), T !== "application/json")
3147
+ x = y;
2703
3148
  else {
2704
- const f = {};
2705
- Array.from(p).forEach(({ value: S, key: x }) => {
2706
- Re(f, x, S);
2707
- }), y = JSON.stringify(f);
3149
+ const m = {};
3150
+ Array.from(S).forEach(({ value: p, key: C }) => {
3151
+ Pe(m, C, p);
3152
+ }), x = JSON.stringify(m);
2708
3153
  }
2709
- C && C !== "multipart/form-data" && (u && ((k = e.action) != null && k.includes("zapier.com")) || (v["content-type"] = C));
2710
- const P = new CustomEvent("presubmit", { detail: { body: y } });
3154
+ T && T !== "multipart/form-data" && (d && ((k = e.action) != null && k.includes("zapier.com")) || (b["content-type"] = T));
3155
+ const P = new CustomEvent("presubmit", { detail: { body: x } });
2711
3156
  if (t.current && (t.current.dispatchEvent(P), P.defaultPrevented))
2712
3157
  return;
2713
3158
  i("sending");
2714
- const I = `${Sn() === "dev" ? "http://localhost:5000" : "https://builder.io"}/api/v1/form-submit?apiKey=${e.builderContext.apiKey}&to=${btoa(
3159
+ const I = `${Vn() === "dev" ? "http://localhost:5000" : "https://builder.io"}/api/v1/form-submit?apiKey=${e.builderContext.apiKey}&to=${btoa(
2715
3160
  e.sendSubmissionsToEmail || ""
2716
- )}&name=${encodeURIComponent(e.name || "")}`, w = e.sendSubmissionsTo === "email" ? I : e.action;
2717
- Te(w), fetch(w, { body: y, headers: v, method: e.method || "post" }).then(
2718
- async (f) => {
2719
- let S;
2720
- const x = f.headers.get("content-type");
2721
- if (x && x.indexOf("application/json") !== -1 ? S = await f.json() : S = await f.text(), !f.ok && e.errorMessagePath) {
2722
- let T = Be(S, e.errorMessagePath);
2723
- T && (typeof T != "string" && (T = JSON.stringify(T)), l(T), d({ formErrorMessage: T }));
3161
+ )}&name=${encodeURIComponent(e.name || "")}`, v = e.sendSubmissionsTo === "email" ? I : e.action;
3162
+ we(v), fetch(v, { body: x, headers: b, method: e.method || "post" }).then(
3163
+ async (m) => {
3164
+ let p;
3165
+ const C = m.headers.get("content-type");
3166
+ if (C && C.indexOf("application/json") !== -1 ? p = await m.json() : p = await m.text(), !m.ok && e.errorMessagePath) {
3167
+ let w = Be(p, e.errorMessagePath);
3168
+ w && (typeof w != "string" && (w = JSON.stringify(w)), l(w), u({ formErrorMessage: w }));
2724
3169
  }
2725
- if (r(S), i(f.ok ? "success" : "error"), f.ok) {
2726
- const T = new CustomEvent("submit:success", {
2727
- detail: { res: f, body: S }
3170
+ if (r(p), i(m.ok ? "success" : "error"), m.ok) {
3171
+ const w = new CustomEvent("submit:success", {
3172
+ detail: { res: m, body: p }
2728
3173
  });
2729
3174
  if (t.current) {
2730
- if (t.current.dispatchEvent(T), T.defaultPrevented)
3175
+ if (t.current.dispatchEvent(w), w.defaultPrevented)
2731
3176
  return;
2732
3177
  e.resetFormOnSubmit !== !1 && t.current.reset();
2733
3178
  }
2734
3179
  if (e.successUrl)
2735
3180
  if (t.current) {
2736
- const V = new CustomEvent("route", {
3181
+ const B = new CustomEvent("route", {
2737
3182
  detail: { url: e.successUrl }
2738
3183
  });
2739
- t.current.dispatchEvent(V), V.defaultPrevented || (location.href = e.successUrl);
3184
+ t.current.dispatchEvent(B), B.defaultPrevented || (location.href = e.successUrl);
2740
3185
  } else
2741
3186
  location.href = e.successUrl;
2742
3187
  }
2743
3188
  },
2744
- (f) => {
2745
- const S = new CustomEvent("submit:error", {
2746
- detail: { error: f }
3189
+ (m) => {
3190
+ const p = new CustomEvent("submit:error", {
3191
+ detail: { error: m }
2747
3192
  });
2748
- t.current && (t.current.dispatchEvent(S), S.defaultPrevented) || (r(f), i("error"));
3193
+ t.current && (t.current.dispatchEvent(p), p.defaultPrevented) || (r(m), i("error"));
2749
3194
  }
2750
3195
  );
2751
3196
  }
2752
3197
  }
2753
- return /* @__PURE__ */ B(E, { children: [
3198
+ return /* @__PURE__ */ V(R, { children: [
2754
3199
  " ",
2755
- /* @__PURE__ */ B(
3200
+ /* @__PURE__ */ V(
2756
3201
  "form",
2757
3202
  {
2758
3203
  validate: e.validate,
@@ -2760,12 +3205,12 @@ function kn(e) {
2760
3205
  action: !e.sendWithJs && e.action,
2761
3206
  method: e.method,
2762
3207
  name: e.name,
2763
- onSubmit: (m) => h(m),
3208
+ onSubmit: (g) => h(g),
2764
3209
  ...e.attributes,
2765
3210
  children: [
2766
3211
  e.children,
2767
3212
  c() === "error" ? /* @__PURE__ */ s(
2768
- F,
3213
+ $,
2769
3214
  {
2770
3215
  path: "errorMessage",
2771
3216
  blocks: e.errorMessage,
@@ -2773,16 +3218,16 @@ function kn(e) {
2773
3218
  }
2774
3219
  ) : null,
2775
3220
  c() === "sending" ? /* @__PURE__ */ s(
2776
- F,
3221
+ $,
2777
3222
  {
2778
3223
  path: "sendingMessage",
2779
3224
  blocks: e.sendingMessage,
2780
3225
  context: e.builderContext
2781
3226
  }
2782
3227
  ) : null,
2783
- c() === "error" && o ? /* @__PURE__ */ s("pre", { className: "builder-form-error-text pre-7acc3b46", children: JSON.stringify(o, null, 2) }) : null,
3228
+ c() === "error" && a ? /* @__PURE__ */ s("pre", { className: "builder-form-error-text pre-7acc3b46", children: JSON.stringify(a, null, 2) }) : null,
2784
3229
  c() === "success" ? /* @__PURE__ */ s(
2785
- F,
3230
+ $,
2786
3231
  {
2787
3232
  path: "successMessage",
2788
3233
  blocks: e.successMessage,
@@ -2797,7 +3242,7 @@ function kn(e) {
2797
3242
  " "
2798
3243
  ] });
2799
3244
  }
2800
- const Cn = {
3245
+ const An = {
2801
3246
  name: "Form:Input",
2802
3247
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fad6f37889d9e40bbbbc72cdb5875d6ca",
2803
3248
  inputs: [
@@ -2849,12 +3294,12 @@ const Cn = {
2849
3294
  borderColor: "#ccc"
2850
3295
  }
2851
3296
  };
2852
- function Tn(e) {
2853
- return /* @__PURE__ */ Ee(
3297
+ function Nn(e) {
3298
+ return /* @__PURE__ */ Re(
2854
3299
  "input",
2855
3300
  {
2856
3301
  ...e.attributes,
2857
- key: N() && e.defaultValue ? e.defaultValue : "default-key",
3302
+ key: W() && e.defaultValue ? e.defaultValue : "default-key",
2858
3303
  placeholder: e.placeholder,
2859
3304
  type: e.type,
2860
3305
  name: e.name,
@@ -2864,7 +3309,7 @@ function Tn(e) {
2864
3309
  }
2865
3310
  );
2866
3311
  }
2867
- const In = {
3312
+ const Wn = {
2868
3313
  name: "Form:Select",
2869
3314
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F83acca093fb24aaf94dee136e9a4b045",
2870
3315
  defaultStyles: {
@@ -2907,14 +3352,14 @@ const In = {
2907
3352
  static: !0,
2908
3353
  noWrap: !0
2909
3354
  };
2910
- function wn(e) {
3355
+ function $n(e) {
2911
3356
  var t;
2912
- return /* @__PURE__ */ Ee(
3357
+ return /* @__PURE__ */ Re(
2913
3358
  "select",
2914
3359
  {
2915
3360
  ...e.attributes,
2916
3361
  value: e.value,
2917
- key: N() && e.defaultValue ? e.defaultValue : "default-key",
3362
+ key: W() && e.defaultValue ? e.defaultValue : "default-key",
2918
3363
  defaultValue: e.defaultValue,
2919
3364
  name: e.name,
2920
3365
  required: e.required
@@ -2922,7 +3367,7 @@ function wn(e) {
2922
3367
  (t = e.options) == null ? void 0 : t.map((n, i) => /* @__PURE__ */ s("option", { value: n.value, children: n.name || n.value }, `${n.name}-${i}`))
2923
3368
  );
2924
3369
  }
2925
- const En = {
3370
+ const Dn = {
2926
3371
  name: "Form:SubmitButton",
2927
3372
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fdf2820ffed1f4349a94c40b3221f5b98",
2928
3373
  defaultStyles: {
@@ -2948,10 +3393,10 @@ const En = {
2948
3393
  // TODO: defaultChildren
2949
3394
  // canHaveChildren: true,
2950
3395
  };
2951
- function Rn(e) {
3396
+ function Fn(e) {
2952
3397
  return /* @__PURE__ */ s("button", { type: "submit", ...e.attributes, children: e.text });
2953
3398
  }
2954
- const Pn = {
3399
+ const Ln = {
2955
3400
  name: "Form:TextArea",
2956
3401
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Ff74a2f3de58c4c3e939204e5b6b8f6c3",
2957
3402
  inputs: [{
@@ -2988,7 +3433,7 @@ const Pn = {
2988
3433
  static: !0,
2989
3434
  noWrap: !0
2990
3435
  };
2991
- function Bn(e) {
3436
+ function On(e) {
2992
3437
  return /* @__PURE__ */ s(
2993
3438
  "textarea",
2994
3439
  {
@@ -3001,7 +3446,7 @@ function Bn(e) {
3001
3446
  }
3002
3447
  );
3003
3448
  }
3004
- const Vn = {
3449
+ const Un = {
3005
3450
  // friendlyName?
3006
3451
  name: "Raw:Img",
3007
3452
  hideFromInsertMenu: !0,
@@ -3016,7 +3461,7 @@ const Vn = {
3016
3461
  noWrap: !0,
3017
3462
  static: !0
3018
3463
  };
3019
- function An(e) {
3464
+ function _n(e) {
3020
3465
  return /* @__PURE__ */ s(
3021
3466
  "img",
3022
3467
  {
@@ -3028,10 +3473,10 @@ function An(e) {
3028
3473
  src: e.imgSrc || e.image,
3029
3474
  ...e.attributes
3030
3475
  },
3031
- N() && e.imgSrc || "default-key"
3476
+ W() && e.imgSrc || "default-key"
3032
3477
  );
3033
3478
  }
3034
- const Wn = {
3479
+ const qn = {
3035
3480
  name: "Video",
3036
3481
  canHaveChildren: !0,
3037
3482
  defaultStyles: {
@@ -3042,7 +3487,7 @@ const Wn = {
3042
3487
  inputs: [{
3043
3488
  name: "video",
3044
3489
  type: "file",
3045
- allowedFileTypes: nn,
3490
+ allowedFileTypes: an,
3046
3491
  bubble: !0,
3047
3492
  defaultValue: "https://cdn.builder.io/o/assets%2FYJIGb4i01jvw0SRdL5Bt%2Fd27731a526464deba0016216f5f9e570%2Fcompressed?apiKey=YJIGb4i01jvw0SRdL5Bt&token=d27731a526464deba0016216f5f9e570&alt=media&optimized=true",
3048
3493
  required: !0
@@ -3116,8 +3561,8 @@ const Wn = {
3116
3561
  builderBlock: !0
3117
3562
  }
3118
3563
  };
3119
- function Nn(e) {
3120
- var i, o, r, a, l, d, c;
3564
+ function Hn(e) {
3565
+ var i, a, r, o, l, u, c;
3121
3566
  function t() {
3122
3567
  return {
3123
3568
  ...e.autoPlay === !0 ? {
@@ -3142,7 +3587,7 @@ function Nn(e) {
3142
3587
  ...t()
3143
3588
  };
3144
3589
  }
3145
- return /* @__PURE__ */ B(
3590
+ return /* @__PURE__ */ V(
3146
3591
  "div",
3147
3592
  {
3148
3593
  style: {
@@ -3173,7 +3618,7 @@ function Nn(e) {
3173
3618
  children: e.lazyLoad ? null : /* @__PURE__ */ s("source", { type: "video/mp4", src: e.video })
3174
3619
  }
3175
3620
  ),
3176
- e.aspectRatio && !(e.fitContent && ((r = (o = e.builderBlock) == null ? void 0 : o.children) != null && r.length)) ? /* @__PURE__ */ s(
3621
+ e.aspectRatio && !(e.fitContent && ((r = (a = e.builderBlock) == null ? void 0 : a.children) != null && r.length)) ? /* @__PURE__ */ s(
3177
3622
  "div",
3178
3623
  {
3179
3624
  style: {
@@ -3184,7 +3629,7 @@ function Nn(e) {
3184
3629
  }
3185
3630
  }
3186
3631
  ) : null,
3187
- (l = (a = e.builderBlock) == null ? void 0 : a.children) != null && l.length && e.fitContent ? /* @__PURE__ */ s(
3632
+ (l = (o = e.builderBlock) == null ? void 0 : o.children) != null && l.length && e.fitContent ? /* @__PURE__ */ s(
3188
3633
  "div",
3189
3634
  {
3190
3635
  style: {
@@ -3195,7 +3640,7 @@ function Nn(e) {
3195
3640
  children: e.children
3196
3641
  }
3197
3642
  ) : null,
3198
- (c = (d = e.builderBlock) == null ? void 0 : d.children) != null && c.length && !e.fitContent ? /* @__PURE__ */ s(
3643
+ (c = (u = e.builderBlock) == null ? void 0 : u.children) != null && c.length && !e.fitContent ? /* @__PURE__ */ s(
3199
3644
  "div",
3200
3645
  {
3201
3646
  style: {
@@ -3216,64 +3661,67 @@ function Nn(e) {
3216
3661
  }
3217
3662
  );
3218
3663
  }
3219
- const Fn = () => [{
3220
- component: hn,
3221
- ...fn
3664
+ const Mn = () => [{
3665
+ component: Cn,
3666
+ ...kn
3222
3667
  }, {
3223
- component: yn,
3224
- ...gn
3668
+ component: En,
3669
+ ...Tn
3225
3670
  }, {
3226
- component: kn,
3227
- ...xn
3671
+ component: Bn,
3672
+ ...Rn
3228
3673
  }, {
3229
- component: Tn,
3230
- ...Cn
3674
+ component: Nn,
3675
+ ...An
3231
3676
  }, {
3232
- component: Rn,
3233
- ...En
3677
+ component: Fn,
3678
+ ...Dn
3234
3679
  }, {
3235
- component: wn,
3236
- ...In
3680
+ component: $n,
3681
+ ...Wn
3237
3682
  }, {
3238
- component: Bn,
3239
- ...Pn
3683
+ component: On,
3684
+ ...Ln
3240
3685
  }, {
3241
- component: An,
3242
- ...Vn
3686
+ component: _n,
3687
+ ...Un
3243
3688
  }, {
3244
- component: Nn,
3245
- ...Wn
3689
+ component: Hn,
3690
+ ...qn
3246
3691
  }], xe = () => [{
3247
3692
  component: ot,
3248
- ...Zt
3249
- }, {
3250
- component: qt,
3251
3693
  ...en
3252
3694
  }, {
3253
3695
  component: zt,
3254
3696
  ...tn
3255
3697
  }, {
3256
- component: Gt,
3698
+ component: Kt,
3699
+ ...nn
3700
+ }, {
3701
+ component: Qt,
3257
3702
  ...on
3258
3703
  }, {
3259
3704
  component: Yt,
3260
- ...an
3705
+ ...hn
3261
3706
  }, {
3262
- component: ln,
3263
- ...rn
3707
+ component: bn,
3708
+ ...gn
3264
3709
  }, {
3265
- component: ai,
3266
- ...sn
3710
+ component: hi,
3711
+ ...pn
3267
3712
  }, {
3268
- component: mn,
3269
- ...un
3713
+ component: Sn,
3714
+ ...xn
3715
+ }, {
3716
+ component: fn,
3717
+ ...rn
3270
3718
  }, {
3271
- component: dn,
3272
- ...cn
3719
+ component: vn,
3720
+ ...yn
3273
3721
  }, {
3274
- component: Xt,
3275
- ...Qt
3276
- }, ...Fn()], $n = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
3722
+ component: Zt,
3723
+ ...Xt
3724
+ }, ...Mn()], jn = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
3277
3725
  function getAndSetVariantId() {
3278
3726
  function setCookie(name, value, days) {
3279
3727
  let expires = '';
@@ -3329,7 +3777,7 @@ const Fn = () => [{
3329
3777
  }).join('');
3330
3778
  styleEl.innerHTML = newStyleStr;
3331
3779
  }
3332
- }`, Ln = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
3780
+ }`, zn = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
3333
3781
  if (!navigator.cookieEnabled) {
3334
3782
  return;
3335
3783
  }
@@ -3363,39 +3811,29 @@ const Fn = () => [{
3363
3811
  thisScriptEl?.remove();
3364
3812
  }
3365
3813
  return;
3366
- }`, _e = "builderIoAbTest", He = "builderIoRenderContent", M = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
3814
+ }`, qe = "builderIoAbTest", He = "builderIoRenderContent", z = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
3367
3815
  ...t,
3368
3816
  testVariationId: t.id,
3369
3817
  id: e == null ? void 0 : e.id
3370
- })), Dn = ({
3818
+ })), Kn = ({
3371
3819
  canTrack: e,
3372
3820
  content: t
3373
- }) => !(!(M(t).length > 0) || !e || j()), On = (e) => e === "react" || e === "reactNative", Me = On($), Un = () => `
3374
- window.${_e} = ${$n}
3375
- window.${He} = ${Ln}
3376
- `, _n = (e, t) => `
3377
- window.${_e}(
3821
+ }) => !(!(z(t).length > 0) || !e || L()), Jn = (e) => e === "react" || e === "reactNative", Me = Jn(F), Gn = () => `
3822
+ window.${qe} = ${jn}
3823
+ window.${He} = ${zn}
3824
+ `, Qn = (e, t) => `
3825
+ window.${qe}(
3378
3826
  "${t}",${JSON.stringify(e)}, ${Me}
3379
- )`, Hn = ({
3827
+ )`, Yn = ({
3380
3828
  contentId: e,
3381
3829
  variationId: t
3382
3830
  }) => `window.${He}(
3383
3831
  "${t}", "${e}", ${Me}
3384
3832
  )`;
3385
- function ie(e) {
3386
- return /* @__PURE__ */ s(
3387
- "script",
3388
- {
3389
- dangerouslySetInnerHTML: { __html: e.scriptStr },
3390
- "data-id": e.id,
3391
- nonce: e.nonce || ""
3392
- }
3393
- );
3394
- }
3395
- function ve(e) {
3833
+ function Se(e) {
3396
3834
  return Math.round(e * 1e3) / 1e3;
3397
3835
  }
3398
- const Mn = (e, t, n = !0) => {
3836
+ const Xn = (e, t, n = !0) => {
3399
3837
  if (!(e instanceof HTMLElement))
3400
3838
  return null;
3401
3839
  let i = n ? e : e.parentElement;
@@ -3406,39 +3844,39 @@ const Mn = (e, t, n = !0) => {
3406
3844
  return i;
3407
3845
  } while (i = i.parentElement);
3408
3846
  return null;
3409
- }, jn = (e) => Mn(e, (t) => {
3847
+ }, Zn = (e) => Xn(e, (t) => {
3410
3848
  const n = t.getAttribute("builder-id") || t.id;
3411
3849
  return (n == null ? void 0 : n.indexOf("builder-")) === 0;
3412
- }), Se = ({
3850
+ }), ke = ({
3413
3851
  event: e,
3414
3852
  target: t
3415
3853
  }) => {
3416
- const n = t.getBoundingClientRect(), i = e.clientX - n.left, o = e.clientY - n.top, r = ve(i / n.width), a = ve(o / n.height);
3854
+ const n = t.getBoundingClientRect(), i = e.clientX - n.left, a = e.clientY - n.top, r = Se(i / n.width), o = Se(a / n.height);
3417
3855
  return {
3418
3856
  x: r,
3419
- y: a
3857
+ y: o
3420
3858
  };
3421
- }, qn = (e) => {
3422
- const t = e.target, n = t && jn(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
3859
+ }, ei = (e) => {
3860
+ const t = e.target, n = t && Zn(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
3423
3861
  return {
3424
3862
  targetBuilderElement: i || void 0,
3425
3863
  metadata: {
3426
- targetOffset: t ? Se({
3864
+ targetOffset: t ? ke({
3427
3865
  event: e,
3428
3866
  target: t
3429
3867
  }) : void 0,
3430
- builderTargetOffset: n ? Se({
3868
+ builderTargetOffset: n ? ke({
3431
3869
  event: e,
3432
3870
  target: n
3433
3871
  }) : void 0,
3434
3872
  builderElementIndex: n && i ? [].slice.call(document.getElementsByClassName(i)).indexOf(n) : void 0
3435
3873
  }
3436
3874
  };
3437
- }, zn = ["svelte", "qwik", "vue"], ke = () => zn.includes($) && (N() || ae()), Kn = (e) => {
3438
- var r, a;
3439
- const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (a = e.fileUrl) != null ? a : (r = e == null ? void 0 : e.files) == null ? void 0 : r.regular;
3440
- let o = "";
3441
- if (i && t && n && (o += `
3875
+ }, ti = ["svelte", "qwik", "vue"], Ce = () => ti.includes(F) && (W() || G()), ni = (e) => {
3876
+ var r, o;
3877
+ const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (o = e.fileUrl) != null ? o : (r = e == null ? void 0 : e.files) == null ? void 0 : r.regular;
3878
+ let a = "";
3879
+ if (i && t && n && (a += `
3442
3880
  @font-face {
3443
3881
  font-family: "${t}";
3444
3882
  src: local("${n}"), url('${i}') format('woff2');
@@ -3450,7 +3888,7 @@ font-weight: 400;
3450
3888
  if (!(String(Number(l)) === l))
3451
3889
  continue;
3452
3890
  const c = e.files[l];
3453
- c && c !== i && (o += `
3891
+ c && c !== i && (a += `
3454
3892
  @font-face {
3455
3893
  font-family: "${t}";
3456
3894
  src: url('${c}') format('woff2');
@@ -3459,16 +3897,16 @@ font-weight: ${l};
3459
3897
  }
3460
3898
  `.trim());
3461
3899
  }
3462
- return o;
3463
- }, Jn = ({
3900
+ return a;
3901
+ }, ii = ({
3464
3902
  customFonts: e
3465
3903
  }) => {
3466
3904
  var t;
3467
- return ((t = e == null ? void 0 : e.map((n) => Kn(n))) == null ? void 0 : t.join(" ")) || "";
3468
- }, Gn = ({
3905
+ return ((t = e == null ? void 0 : e.map((n) => ni(n))) == null ? void 0 : t.join(" ")) || "";
3906
+ }, ai = ({
3469
3907
  cssCode: e,
3470
3908
  contentId: t
3471
- }) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", Yn = `
3909
+ }) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", oi = `
3472
3910
  .builder-button {
3473
3911
  all: unset;
3474
3912
  }
@@ -3485,103 +3923,103 @@ font-weight: ${l};
3485
3923
  text-align: inherit;
3486
3924
  font-family: inherit;
3487
3925
  }
3488
- `, Qn = (e) => e ? "" : Yn, Xn = (e) => `variant-${e}`;
3489
- function Zn(e) {
3490
- var p, C, P;
3491
- const t = L(null);
3926
+ `, ri = (e) => e ? "" : oi, li = (e) => `variant-${e}`;
3927
+ function si(e) {
3928
+ var S, T, P;
3929
+ const t = D(null);
3492
3930
  function n(I) {
3493
- var f, S;
3494
- const w = {
3931
+ var m, p;
3932
+ const v = {
3495
3933
  ...e.builderContextSignal.rootState,
3496
3934
  ...I
3497
3935
  };
3498
- e.builderContextSignal.rootSetState ? (S = (f = e.builderContextSignal).rootSetState) == null || S.call(f, w) : e.setBuilderContextSignal((x) => ({
3499
- ...x,
3500
- rootState: w
3936
+ e.builderContextSignal.rootSetState ? (p = (m = e.builderContextSignal).rootSetState) == null || p.call(m, v) : e.setBuilderContextSignal((C) => ({
3937
+ ...C,
3938
+ rootState: v
3501
3939
  }));
3502
3940
  }
3503
3941
  function i(I) {
3504
- var f, S, x, T, V;
3505
- const w = {
3942
+ var m, p, C, w, B;
3943
+ const v = {
3506
3944
  ...e.builderContextSignal.content,
3507
3945
  ...I,
3508
3946
  data: {
3509
- ...(f = e.builderContextSignal.content) == null ? void 0 : f.data,
3947
+ ...(m = e.builderContextSignal.content) == null ? void 0 : m.data,
3510
3948
  ...I == null ? void 0 : I.data
3511
3949
  },
3512
3950
  meta: {
3513
- ...(S = e.builderContextSignal.content) == null ? void 0 : S.meta,
3951
+ ...(p = e.builderContextSignal.content) == null ? void 0 : p.meta,
3514
3952
  ...I == null ? void 0 : I.meta,
3515
- breakpoints: ((x = I == null ? void 0 : I.meta) == null ? void 0 : x.breakpoints) || ((V = (T = e.builderContextSignal.content) == null ? void 0 : T.meta) == null ? void 0 : V.breakpoints)
3953
+ breakpoints: ((C = I == null ? void 0 : I.meta) == null ? void 0 : C.breakpoints) || ((B = (w = e.builderContextSignal.content) == null ? void 0 : w.meta) == null ? void 0 : B.breakpoints)
3516
3954
  }
3517
3955
  };
3518
- e.setBuilderContextSignal((W) => ({
3519
- ...W,
3520
- content: w
3956
+ e.setBuilderContextSignal((N) => ({
3957
+ ...N,
3958
+ content: v
3521
3959
  }));
3522
3960
  }
3523
- function o() {
3961
+ function a() {
3524
3962
  return e.showContent ? {} : {
3525
3963
  hidden: !0,
3526
3964
  "aria-hidden": !0
3527
3965
  };
3528
3966
  }
3529
- const [r, a] = R(
3967
+ const [r, o] = E(
3530
3968
  () => e.contentWrapper || "div"
3531
3969
  );
3532
3970
  function l(I) {
3533
- return Ke({
3971
+ return Je({
3534
3972
  model: e.model,
3535
3973
  trustedHosts: e.trustedHosts,
3536
3974
  callbacks: {
3537
- configureSdk: (w) => {
3538
- var x;
3539
- const { breakpoints: f, contentId: S } = w;
3540
- !S || S !== ((x = e.builderContextSignal.content) == null ? void 0 : x.id) || f && i({
3975
+ configureSdk: (v) => {
3976
+ var C;
3977
+ const { breakpoints: m, contentId: p } = v;
3978
+ !p || p !== ((C = e.builderContextSignal.content) == null ? void 0 : C.id) || m && i({
3541
3979
  meta: {
3542
- breakpoints: f
3980
+ breakpoints: m
3543
3981
  }
3544
3982
  });
3545
3983
  },
3546
- animation: (w) => {
3547
- Ne(w);
3984
+ animation: (v) => {
3985
+ $e(v);
3548
3986
  },
3549
- contentUpdate: (w) => {
3550
- i(w);
3987
+ contentUpdate: (v) => {
3988
+ i(v);
3551
3989
  }
3552
3990
  }
3553
3991
  })(I);
3554
3992
  }
3555
- const [d, c] = R(() => ({})), [h, m] = R(() => ({})), [u, k] = R(() => !1);
3556
- function g(I) {
3557
- var w, f;
3993
+ const [u, c] = E(() => ({})), [h, g] = E(() => ({})), [d, k] = E(() => !1);
3994
+ function f(I) {
3995
+ var v, m;
3558
3996
  if (e.builderContextSignal.content) {
3559
- const S = (w = e.builderContextSignal.content) == null ? void 0 : w.testVariationId, x = (f = e.builderContextSignal.content) == null ? void 0 : f.id;
3560
- ue({
3997
+ const p = (v = e.builderContextSignal.content) == null ? void 0 : v.testVariationId, C = (m = e.builderContextSignal.content) == null ? void 0 : m.id;
3998
+ fe({
3561
3999
  apiHost: e.apiHost,
3562
4000
  type: "click",
3563
4001
  canTrack: q(e.canTrack),
3564
- contentId: x,
4002
+ contentId: C,
3565
4003
  apiKey: e.apiKey,
3566
- variationId: S !== x ? S : void 0,
3567
- ...qn(I),
3568
- unique: !u
4004
+ variationId: p !== C ? p : void 0,
4005
+ ...ei(I),
4006
+ unique: !d
3569
4007
  });
3570
4008
  }
3571
- u || k(!0);
4009
+ d || k(!0);
3572
4010
  }
3573
- function v() {
3574
- var w, f, S;
3575
- const I = (S = (f = (w = e.builderContextSignal.content) == null ? void 0 : w.data) == null ? void 0 : f.httpRequests) != null ? S : {};
3576
- Object.entries(I).forEach(([x, T]) => {
3577
- if (!T || h[x] || d[x] && !N())
4011
+ function b() {
4012
+ var v, m, p;
4013
+ const I = (p = (m = (v = e.builderContextSignal.content) == null ? void 0 : v.data) == null ? void 0 : m.httpRequests) != null ? p : {};
4014
+ Object.entries(I).forEach(([C, w]) => {
4015
+ if (!w || h[C] || u[C] && !W())
3578
4016
  return;
3579
- h[x] = !0;
3580
- const V = T.replace(
4017
+ h[C] = !0;
4018
+ const B = w.replace(
3581
4019
  /{{([^}]+)}}/g,
3582
- (W, _) => String(
3583
- D({
3584
- code: _,
4020
+ (N, j) => String(
4021
+ O({
4022
+ code: j,
3585
4023
  context: e.context || {},
3586
4024
  localState: void 0,
3587
4025
  rootState: e.builderContextSignal.rootState,
@@ -3589,24 +4027,24 @@ function Zn(e) {
3589
4027
  })
3590
4028
  )
3591
4029
  );
3592
- Te(V), fetch(V).then((W) => W.json()).then((W) => {
4030
+ we(B), fetch(B).then((N) => N.json()).then((N) => {
3593
4031
  n({
3594
- [x]: W
3595
- }), d[x] = !0;
3596
- }).catch((W) => {
3597
- console.error("error fetching dynamic data", T, W);
4032
+ [C]: N
4033
+ }), u[C] = !0;
4034
+ }).catch((N) => {
4035
+ console.error("error fetching dynamic data", w, N);
3598
4036
  }).finally(() => {
3599
- h[x] = !1;
4037
+ h[C] = !1;
3600
4038
  });
3601
4039
  });
3602
4040
  }
3603
- function y() {
3604
- N() && window.dispatchEvent(
4041
+ function x() {
4042
+ W() && window.dispatchEvent(
3605
4043
  new CustomEvent(
3606
4044
  "builder:component:stateChange",
3607
4045
  {
3608
4046
  detail: {
3609
- state: re(e.builderContextSignal.rootState),
4047
+ state: le(e.builderContextSignal.rootState),
3610
4048
  ref: {
3611
4049
  name: e.model
3612
4050
  }
@@ -3615,11 +4053,11 @@ function Zn(e) {
3615
4053
  )
3616
4054
  );
3617
4055
  }
3618
- const b = L(!1);
3619
- return b.current || (v(), y(), b.current = !0), A(() => {
3620
- var I, w, f;
3621
- if (j()) {
3622
- if (N() && !e.isNestedRender && (window.addEventListener("message", l), je(), qe({
4056
+ const y = D(!1);
4057
+ return y.current || (b(), x(), y.current = !0), A(() => {
4058
+ var I, v, m;
4059
+ if (L()) {
4060
+ if (W() && !e.isNestedRender && (window.addEventListener("message", l), je(), ze({
3623
4061
  ...e.locale ? {
3624
4062
  locale: e.locale
3625
4063
  } : {},
@@ -3631,48 +4069,48 @@ function Zn(e) {
3631
4069
  } : {}
3632
4070
  }), Object.values(
3633
4071
  e.builderContextSignal.componentInfos
3634
- ).forEach((x) => {
3635
- var T, V;
3636
- if (!e.model || !((T = x.models) != null && T.length) || x.models.includes(e.model)) {
3637
- const W = ze(x);
3638
- (V = window.parent) == null || V.postMessage(W, "*");
4072
+ ).forEach((C) => {
4073
+ var w, B;
4074
+ if (!e.model || !((w = C.models) != null && w.length) || C.models.includes(e.model)) {
4075
+ const N = Ke(C);
4076
+ (B = window.parent) == null || B.postMessage(N, "*");
3639
4077
  }
3640
4078
  }), window.addEventListener(
3641
4079
  "builder:component:stateChangeListenerActivated",
3642
- y
4080
+ x
3643
4081
  )), e.builderContextSignal.content && q(e.canTrack)) {
3644
- const x = (I = e.builderContextSignal.content) == null ? void 0 : I.testVariationId, T = (w = e.builderContextSignal.content) == null ? void 0 : w.id, V = e.apiKey;
3645
- ue({
4082
+ const C = (I = e.builderContextSignal.content) == null ? void 0 : I.testVariationId, w = (v = e.builderContextSignal.content) == null ? void 0 : v.id, B = e.apiKey;
4083
+ fe({
3646
4084
  apiHost: e.apiHost,
3647
4085
  type: "impression",
3648
4086
  canTrack: !0,
3649
- contentId: T,
3650
- apiKey: V,
3651
- variationId: x !== T ? x : void 0
4087
+ contentId: w,
4088
+ apiKey: B,
4089
+ variationId: C !== w ? C : void 0
3652
4090
  });
3653
4091
  }
3654
- if (ae() && !N()) {
3655
- const x = new URL(location.href).searchParams, T = x.get("builder.preview"), V = x.get(
3656
- `builder.overrides.${T}`
3657
- ), W = x.get("apiKey") || x.get("builder.space");
3658
- (T === "BUILDER_STUDIO" || T === e.model && W === e.apiKey && (!e.content || V === e.content.id)) && Ie({
4092
+ if (G() && !W()) {
4093
+ const C = new URL(location.href).searchParams, w = C.get("builder.preview"), B = C.get(
4094
+ `builder.overrides.${w}`
4095
+ ), N = C.get("apiKey") || C.get("builder.space");
4096
+ (w === "BUILDER_STUDIO" || w === e.model && N === e.apiKey && (!e.content || B === e.content.id)) && Ie({
3659
4097
  model: e.model || "",
3660
4098
  apiKey: e.apiKey,
3661
4099
  apiVersion: e.builderContextSignal.apiVersion,
3662
- ...T === "BUILDER_STUDIO" && ((f = e.context) != null && f.symbolId) ? {
4100
+ ...w === "BUILDER_STUDIO" && ((m = e.context) != null && m.symbolId) ? {
3663
4101
  query: {
3664
4102
  id: e.context.symbolId
3665
4103
  }
3666
4104
  } : {}
3667
- }).then((_) => {
3668
- _ && i(_);
4105
+ }).then((j) => {
4106
+ j && i(j);
3669
4107
  });
3670
4108
  }
3671
4109
  }
3672
4110
  }, []), A(() => {
3673
4111
  e.content && i(e.content);
3674
4112
  }, [e.content]), A(() => {
3675
- y();
4113
+ x();
3676
4114
  }, [e.builderContextSignal.rootState]), A(() => {
3677
4115
  e.data && n(e.data);
3678
4116
  }, [e.data]), A(() => {
@@ -3680,44 +4118,44 @@ function Zn(e) {
3680
4118
  locale: e.locale
3681
4119
  });
3682
4120
  }, [e.locale]), A(() => () => {
3683
- j() && (window.removeEventListener("message", l), window.removeEventListener(
4121
+ L() && (window.removeEventListener("message", l), window.removeEventListener(
3684
4122
  "builder:component:stateChangeListenerActivated",
3685
- y
4123
+ x
3686
4124
  ));
3687
- }, []), /* @__PURE__ */ s(se.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content || ke() ? /* @__PURE__ */ s(
4125
+ }, []), /* @__PURE__ */ s(ce.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content || Ce() ? /* @__PURE__ */ s(
3688
4126
  r,
3689
4127
  {
3690
4128
  ref: t,
3691
- onClick: (I) => g(I),
3692
- "builder-content-id": (p = e.builderContextSignal.content) == null ? void 0 : p.id,
4129
+ onClick: (I) => f(I),
4130
+ "builder-content-id": (S = e.builderContextSignal.content) == null ? void 0 : S.id,
3693
4131
  "builder-model": e.model,
3694
- className: Xn(
3695
- ((C = e.content) == null ? void 0 : C.testVariationId) || ((P = e.content) == null ? void 0 : P.id)
4132
+ className: li(
4133
+ ((T = e.content) == null ? void 0 : T.testVariationId) || ((P = e.content) == null ? void 0 : P.id)
3696
4134
  ),
3697
4135
  style: {
3698
- display: !e.builderContextSignal.content && ke() ? "none" : void 0
4136
+ display: !e.builderContextSignal.content && Ce() ? "none" : void 0
3699
4137
  },
3700
- ...o(),
4138
+ ...a(),
3701
4139
  ...e.contentWrapperProps,
3702
4140
  children: e.children
3703
4141
  }
3704
4142
  ) : null });
3705
4143
  }
3706
- function ei(e) {
3707
- const [t, n] = R(
4144
+ function ci(e) {
4145
+ const [t, n] = E(
3708
4146
  () => `
3709
- ${Gn({
4147
+ ${ai({
3710
4148
  cssCode: e.cssCode,
3711
4149
  contentId: e.contentId
3712
4150
  })}
3713
- ${Jn({
4151
+ ${ii({
3714
4152
  customFonts: e.customFonts
3715
4153
  })}
3716
- ${Qn(e.isNestedRender)}
4154
+ ${ri(e.isNestedRender)}
3717
4155
  `.trim()
3718
4156
  );
3719
4157
  return /* @__PURE__ */ s(
3720
- J,
4158
+ M,
3721
4159
  {
3722
4160
  id: "builderio-content",
3723
4161
  styles: t,
@@ -3725,24 +4163,24 @@ ${Qn(e.isNestedRender)}
3725
4163
  }
3726
4164
  );
3727
4165
  }
3728
- const ti = ({
4166
+ const ui = ({
3729
4167
  content: e,
3730
4168
  data: t,
3731
4169
  locale: n
3732
4170
  }) => {
3733
- var r, a, l;
3734
- const i = {}, o = ((r = e == null ? void 0 : e.data) == null ? void 0 : r.state) || {};
3735
- return (l = (a = e == null ? void 0 : e.data) == null ? void 0 : a.inputs) == null || l.forEach((d) => {
3736
- d.name && d.defaultValue !== void 0 && (i[d.name] = d.defaultValue);
4171
+ var r, o, l;
4172
+ const i = {}, a = ((r = e == null ? void 0 : e.data) == null ? void 0 : r.state) || {};
4173
+ return (l = (o = e == null ? void 0 : e.data) == null ? void 0 : o.inputs) == null || l.forEach((u) => {
4174
+ u.name && u.defaultValue !== void 0 && (i[u.name] = u.defaultValue);
3737
4175
  }), {
3738
4176
  ...i,
3739
- ...o,
4177
+ ...a,
3740
4178
  ...t,
3741
4179
  ...n ? {
3742
4180
  locale: n
3743
4181
  } : {}
3744
4182
  };
3745
- }, ni = ({
4183
+ }, di = ({
3746
4184
  content: e,
3747
4185
  data: t
3748
4186
  }) => e ? {
@@ -3753,46 +4191,46 @@ const ti = ({
3753
4191
  },
3754
4192
  meta: e == null ? void 0 : e.meta
3755
4193
  } : void 0;
3756
- function Ce(e) {
3757
- var c, h, m, u, k, g, v, y, b;
3758
- const [t, n] = R(
4194
+ function Te(e) {
4195
+ var c, h, g, d, k, f, b, x, y;
4196
+ const [t, n] = E(
3759
4197
  () => {
3760
- var p, C;
3761
- return Hn({
4198
+ var S, T;
4199
+ return Yn({
3762
4200
  // eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
3763
- variationId: (p = e.content) == null ? void 0 : p.testVariationId,
4201
+ variationId: (S = e.content) == null ? void 0 : S.testVariationId,
3764
4202
  // eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
3765
- contentId: (C = e.content) == null ? void 0 : C.id
4203
+ contentId: (T = e.content) == null ? void 0 : T.id
3766
4204
  });
3767
4205
  }
3768
4206
  );
3769
- function i(p) {
3770
- l((C) => ({
3771
- ...C,
3772
- rootState: p
4207
+ function i(S) {
4208
+ l((T) => ({
4209
+ ...T,
4210
+ rootState: S
3773
4211
  }));
3774
4212
  }
3775
- const [o, r] = R(
4213
+ const [a, r] = E(
3776
4214
  () => [
3777
4215
  ...xe(),
3778
4216
  ...e.customComponents || []
3779
4217
  ].reduce(
3780
- (p, { component: C, ...P }) => ({
3781
- ...p,
4218
+ (S, { component: T, ...P }) => ({
4219
+ ...S,
3782
4220
  [P.name]: {
3783
- component: C,
3784
- ...me(P)
4221
+ component: T,
4222
+ ...he(P)
3785
4223
  }
3786
4224
  }),
3787
4225
  {}
3788
4226
  )
3789
- ), [a, l] = R(() => ({
3790
- content: ni({
4227
+ ), [o, l] = E(() => ({
4228
+ content: di({
3791
4229
  content: e.content,
3792
4230
  data: e.data
3793
4231
  }),
3794
4232
  localState: void 0,
3795
- rootState: ti({
4233
+ rootState: ui({
3796
4234
  content: e.content,
3797
4235
  data: e.data,
3798
4236
  locale: e.locale
@@ -3806,9 +4244,9 @@ function Ce(e) {
3806
4244
  ...xe(),
3807
4245
  ...e.customComponents || []
3808
4246
  ].reduce(
3809
- (p, { component: C, ...P }) => ({
3810
- ...p,
3811
- [P.name]: me(P)
4247
+ (S, { component: T, ...P }) => ({
4248
+ ...S,
4249
+ [P.name]: he(P)
3812
4250
  }),
3813
4251
  {}
3814
4252
  ),
@@ -3817,31 +4255,31 @@ function Ce(e) {
3817
4255
  BlocksWrapperProps: e.blocksWrapperProps || {},
3818
4256
  nonce: e.nonce || "",
3819
4257
  model: e.model || ""
3820
- })), d = L(!1);
3821
- if (!d.current) {
3822
- e.apiKey || oe.error(
4258
+ })), u = D(!1);
4259
+ if (!u.current) {
4260
+ e.apiKey || re.error(
3823
4261
  "No API key provided to `Content` component. This can cause issues. Please provide an API key using the `apiKey` prop."
3824
4262
  );
3825
- const p = (h = (c = a.content) == null ? void 0 : c.data) == null ? void 0 : h.jsCode;
3826
- p && D({
3827
- code: p,
4263
+ const S = (h = (c = o.content) == null ? void 0 : c.data) == null ? void 0 : h.jsCode;
4264
+ S && O({
4265
+ code: S,
3828
4266
  context: e.context || {},
3829
4267
  localState: void 0,
3830
- rootState: a.rootState,
3831
- rootSetState: (C) => {
3832
- Object.assign(a.rootState, C);
4268
+ rootState: o.rootState,
4269
+ rootSetState: (T) => {
4270
+ Object.assign(o.rootState, T);
3833
4271
  },
3834
4272
  isExpression: !1
3835
- }), d.current = !0;
4273
+ }), u.current = !0;
3836
4274
  }
3837
4275
  return /* @__PURE__ */ s(
3838
- Pe.Provider,
4276
+ Ve.Provider,
3839
4277
  {
3840
4278
  value: {
3841
- registeredComponents: o
4279
+ registeredComponents: a
3842
4280
  },
3843
- children: /* @__PURE__ */ B(
3844
- Zn,
4281
+ children: /* @__PURE__ */ V(
4282
+ si,
3845
4283
  {
3846
4284
  apiHost: e.apiHost,
3847
4285
  nonce: e.nonce,
@@ -3854,7 +4292,7 @@ function Ce(e) {
3854
4292
  locale: e.locale,
3855
4293
  enrich: e.enrich,
3856
4294
  showContent: e.showContent,
3857
- builderContextSignal: a,
4295
+ builderContextSignal: o,
3858
4296
  contentWrapper: e.contentWrapper,
3859
4297
  contentWrapperProps: e.contentWrapperProps,
3860
4298
  trustedHosts: e.trustedHosts,
@@ -3862,7 +4300,7 @@ function Ce(e) {
3862
4300
  setBuilderContextSignal: l,
3863
4301
  children: [
3864
4302
  e.isSsrAbTest ? /* @__PURE__ */ s(
3865
- ie,
4303
+ J,
3866
4304
  {
3867
4305
  id: "builderio-variant-visibility",
3868
4306
  scriptStr: t,
@@ -3870,21 +4308,21 @@ function Ce(e) {
3870
4308
  }
3871
4309
  ) : null,
3872
4310
  /* @__PURE__ */ s(
3873
- ei,
4311
+ ci,
3874
4312
  {
3875
4313
  nonce: e.nonce || "",
3876
4314
  isNestedRender: e.isNestedRender,
3877
- contentId: (m = a.content) == null ? void 0 : m.id,
3878
- cssCode: (k = (u = a.content) == null ? void 0 : u.data) == null ? void 0 : k.cssCode,
3879
- customFonts: (v = (g = a.content) == null ? void 0 : g.data) == null ? void 0 : v.customFonts
4315
+ contentId: (g = o.content) == null ? void 0 : g.id,
4316
+ cssCode: (k = (d = o.content) == null ? void 0 : d.data) == null ? void 0 : k.cssCode,
4317
+ customFonts: (b = (f = o.content) == null ? void 0 : f.data) == null ? void 0 : b.customFonts
3880
4318
  }
3881
4319
  ),
3882
4320
  /* @__PURE__ */ s(
3883
- F,
4321
+ $,
3884
4322
  {
3885
- blocks: (b = (y = a.content) == null ? void 0 : y.data) == null ? void 0 : b.blocks,
3886
- context: a,
3887
- registeredComponents: o,
4323
+ blocks: (y = (x = o.content) == null ? void 0 : x.data) == null ? void 0 : y.blocks,
4324
+ context: o,
4325
+ registeredComponents: a,
3888
4326
  linkComponent: e.linkComponent
3889
4327
  }
3890
4328
  )
@@ -3894,66 +4332,66 @@ function Ce(e) {
3894
4332
  }
3895
4333
  );
3896
4334
  }
3897
- function ii(e) {
3898
- var a;
3899
- const [t, n] = R(
3900
- () => Dn({
4335
+ function mi(e) {
4336
+ var o;
4337
+ const [t, n] = E(
4338
+ () => Kn({
3901
4339
  canTrack: q(e.canTrack),
3902
4340
  content: e.content
3903
4341
  })
3904
4342
  );
3905
4343
  function i() {
3906
4344
  var l;
3907
- return _n(
3908
- M(e.content).map((d) => ({
3909
- id: d.testVariationId,
3910
- testRatio: d.testRatio
4345
+ return Qn(
4346
+ z(e.content).map((u) => ({
4347
+ id: u.testVariationId,
4348
+ testRatio: u.testRatio
3911
4349
  })),
3912
4350
  ((l = e.content) == null ? void 0 : l.id) || ""
3913
4351
  );
3914
4352
  }
3915
- function o() {
3916
- return M(e.content).map((l) => `.variant-${l.testVariationId} { display: none; } `).join("");
4353
+ function a() {
4354
+ return z(e.content).map((l) => `.variant-${l.testVariationId} { display: none; } `).join("");
3917
4355
  }
3918
4356
  function r() {
3919
4357
  var l;
3920
4358
  return t ? {
3921
4359
  ...e.content,
3922
4360
  testVariationId: (l = e.content) == null ? void 0 : l.id
3923
- } : Je({
4361
+ } : Ge({
3924
4362
  item: e.content,
3925
4363
  canTrack: q(e.canTrack)
3926
4364
  });
3927
4365
  }
3928
4366
  return A(() => {
3929
- }, []), /* @__PURE__ */ B(E, { children: [
3930
- !e.isNestedRender && $ !== "reactNative" ? /* @__PURE__ */ s(
3931
- ie,
4367
+ }, []), /* @__PURE__ */ V(R, { children: [
4368
+ !e.isNestedRender && F !== "reactNative" ? /* @__PURE__ */ s(
4369
+ J,
3932
4370
  {
3933
4371
  id: "builderio-init-variants-fns",
3934
- scriptStr: Un(),
4372
+ scriptStr: Gn(),
3935
4373
  nonce: e.nonce || ""
3936
4374
  }
3937
4375
  ) : null,
3938
- t ? /* @__PURE__ */ B(E, { children: [
4376
+ t ? /* @__PURE__ */ V(R, { children: [
3939
4377
  /* @__PURE__ */ s(
3940
- J,
4378
+ M,
3941
4379
  {
3942
4380
  id: "builderio-variants",
3943
- styles: o(),
4381
+ styles: a(),
3944
4382
  nonce: e.nonce || ""
3945
4383
  }
3946
4384
  ),
3947
4385
  /* @__PURE__ */ s(
3948
- ie,
4386
+ J,
3949
4387
  {
3950
4388
  id: "builderio-variants-visibility",
3951
4389
  scriptStr: i(),
3952
4390
  nonce: e.nonce || ""
3953
4391
  }
3954
4392
  ),
3955
- (a = M(e.content)) == null ? void 0 : a.map((l) => /* @__PURE__ */ s(
3956
- Ce,
4393
+ (o = z(e.content)) == null ? void 0 : o.map((l) => /* @__PURE__ */ s(
4394
+ Te,
3957
4395
  {
3958
4396
  apiHost: e.apiHost,
3959
4397
  isNestedRender: e.isNestedRender,
@@ -3981,7 +4419,7 @@ function ii(e) {
3981
4419
  ))
3982
4420
  ] }) : null,
3983
4421
  /* @__PURE__ */ s(
3984
- Ce,
4422
+ Te,
3985
4423
  {
3986
4424
  apiHost: e.apiHost,
3987
4425
  nonce: e.nonce,
@@ -4008,7 +4446,7 @@ function ii(e) {
4008
4446
  )
4009
4447
  ] });
4010
4448
  }
4011
- const oi = async ({
4449
+ const fi = async ({
4012
4450
  builderContextValue: e,
4013
4451
  symbol: t
4014
4452
  }) => {
@@ -4024,11 +4462,11 @@ const oi = async ({
4024
4462
  }
4025
4463
  }
4026
4464
  }).catch((n) => {
4027
- oe.error("Could not fetch symbol content: ", n);
4465
+ re.error("Could not fetch symbol content: ", n);
4028
4466
  });
4029
4467
  };
4030
- function ai(e) {
4031
- var l, d, c, h;
4468
+ function hi(e) {
4469
+ var l, u, c, h;
4032
4470
  function t() {
4033
4471
  return "div";
4034
4472
  }
@@ -4036,31 +4474,31 @@ function ai(e) {
4036
4474
  return "div";
4037
4475
  }
4038
4476
  function i() {
4039
- var m, u;
4477
+ var g, d;
4040
4478
  return [
4041
- e.attributes[U()],
4479
+ e.attributes[H()],
4042
4480
  "builder-symbol",
4043
- (m = e.symbol) != null && m.inline ? "builder-inline-symbol" : void 0,
4044
- (u = e.symbol) != null && u.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
4481
+ (g = e.symbol) != null && g.inline ? "builder-inline-symbol" : void 0,
4482
+ (d = e.symbol) != null && d.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
4045
4483
  ].filter(Boolean).join(" ");
4046
4484
  }
4047
- const [o, r] = R(() => {
4048
- var m;
4049
- return (m = e.symbol) == null ? void 0 : m.content;
4485
+ const [a, r] = E(() => {
4486
+ var g;
4487
+ return (g = e.symbol) == null ? void 0 : g.content;
4050
4488
  });
4051
- function a() {
4052
- o || oi({
4489
+ function o() {
4490
+ a || fi({
4053
4491
  symbol: e.symbol,
4054
4492
  builderContextValue: e.builderContext
4055
- }).then((m) => {
4056
- m && r(m);
4493
+ }).then((g) => {
4494
+ g && r(g);
4057
4495
  });
4058
4496
  }
4059
4497
  return A(() => {
4060
4498
  }, []), A(() => {
4061
- a();
4499
+ o();
4062
4500
  }, [e.symbol]), /* @__PURE__ */ s("div", { ...e.attributes, className: i(), children: /* @__PURE__ */ s(
4063
- ii,
4501
+ mi,
4064
4502
  {
4065
4503
  nonce: e.builderContext.nonce,
4066
4504
  isNestedRender: !0,
@@ -4072,13 +4510,13 @@ function ai(e) {
4072
4510
  },
4073
4511
  customComponents: Object.values(e.builderComponents),
4074
4512
  data: {
4075
- ...(d = e.symbol) == null ? void 0 : d.data,
4513
+ ...(u = e.symbol) == null ? void 0 : u.data,
4076
4514
  ...e.builderContext.localState,
4077
- ...(c = o == null ? void 0 : o.data) == null ? void 0 : c.state
4515
+ ...(c = a == null ? void 0 : a.data) == null ? void 0 : c.state
4078
4516
  },
4079
4517
  canTrack: e.builderContext.canTrack,
4080
4518
  model: (h = e.symbol) == null ? void 0 : h.model,
4081
- content: o,
4519
+ content: a,
4082
4520
  linkComponent: e.builderLinkComponent,
4083
4521
  blocksWrapper: t(),
4084
4522
  contentWrapper: n()
@@ -4086,15 +4524,16 @@ function ai(e) {
4086
4524
  ) });
4087
4525
  }
4088
4526
  export {
4089
- F as Blocks,
4090
- se as BuilderContext,
4527
+ $ as Blocks,
4528
+ ce as BuilderContext,
4091
4529
  ot as Button,
4092
- qt as Columns,
4093
- ii as Content,
4094
- zt as Fragment,
4095
- Gt as Image,
4530
+ zt as Columns,
4531
+ mi as Content,
4532
+ Kt as Fragment,
4533
+ Qt as Image,
4096
4534
  Yt as Section,
4097
- ai as Symbol,
4098
- mn as Text,
4099
- Nn as Video
4535
+ hi as Symbol,
4536
+ Sn as Text,
4537
+ Hn as Video,
4538
+ ki as setClientUserAttributes
4100
4539
  };