@builder.io/sdk-react 2.0.9 → 2.0.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/browser/blocks-exports.cjs +31 -31
- package/lib/browser/blocks-exports.mjs +1032 -996
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/init.cjs +3 -3
- package/lib/browser/init.mjs +3 -3
- package/lib/{node/server-entry-8bf52a55.js → browser/server-entry-288f3748.js} +333 -330
- package/lib/browser/server-entry-7304506e.cjs +2 -0
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/{accordion-589b3ac8.js → accordion-3cfa3eee.js} +1 -1
- package/lib/edge/{accordion-afed3bd3.cjs → accordion-807094e8.cjs} +1 -1
- package/lib/edge/blocks-54e76c48.js +842 -0
- package/lib/edge/blocks-ec210226.cjs +12 -0
- package/lib/edge/blocks-exports.cjs +1 -1
- package/lib/edge/blocks-exports.mjs +2 -2
- package/lib/edge/{button-08412b69.js → button-0d89818e.js} +2 -2
- package/lib/edge/{button-26b76a4a.cjs → button-e3dbd868.cjs} +1 -1
- package/lib/edge/{columns-ccdafcc7.cjs → columns-f4875265.cjs} +1 -1
- package/lib/edge/{columns-bd2a004b.js → columns-f9a7710d.js} +4 -4
- package/lib/edge/{content-variants-dd7ea0f9.js → content-variants-8ab0c195.js} +13 -12
- package/lib/edge/{content-variants-fc207487.cjs → content-variants-aadc6d6c.cjs} +1 -1
- package/lib/edge/{evaluate-e2f692df.js → evaluate-1ef00edc.js} +87 -87
- package/lib/edge/{evaluate-3991fda5.cjs → evaluate-4d70dcda.cjs} +6 -6
- package/lib/edge/{form-b9148162.js → form-0e3e79d5.js} +4 -4
- package/lib/edge/{form-5eb85abf.cjs → form-8edb1a1e.cjs} +1 -1
- package/lib/edge/{get-class-prop-name-0c783f8c.js → get-class-prop-name-c8375d5b.js} +1 -1
- package/lib/edge/{get-class-prop-name-2fa91d70.cjs → get-class-prop-name-f64b085a.cjs} +1 -1
- package/lib/edge/{img-602f7d3a.js → img-411548cf.js} +1 -1
- package/lib/edge/{img-2f30658b.cjs → img-a63de542.cjs} +1 -1
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/init.cjs +3 -3
- package/lib/edge/init.mjs +3 -3
- package/lib/edge/{input-551362f3.cjs → input-59f88558.cjs} +1 -1
- package/lib/edge/{input-4c791db9.js → input-a31ad183.js} +1 -1
- package/lib/edge/{select-eb26f837.cjs → select-31a4a930.cjs} +1 -1
- package/lib/edge/{select-d1391d12.js → select-bfc6e2dd.js} +1 -1
- package/lib/edge/{server-entry-c537d834.js → server-entry-899f7119.js} +1 -1
- package/lib/edge/{server-entry-7b4fa72f.cjs → server-entry-f0b40e5b.cjs} +1 -1
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/edge/{slot-d375d5eb.js → slot-634372d2.js} +12 -11
- package/lib/edge/slot-c9228b15.cjs +1 -0
- package/lib/edge/{symbol-6c18ca90.cjs → symbol-10d573de.cjs} +1 -1
- package/lib/edge/{symbol-8b3a6b98.js → symbol-32a5d0f7.js} +2 -2
- package/lib/edge/{tabs-1e47cfd4.js → tabs-52ed1067.js} +4 -4
- package/lib/edge/{tabs-8296bce7.cjs → tabs-71e3e002.cjs} +1 -1
- package/lib/edge/{text-9eac9e4d.cjs → text-853d6ef4.cjs} +1 -1
- package/lib/edge/{text-d3c86634.js → text-ea8a6161.js} +2 -2
- package/lib/node/blocks-exports.cjs +32 -32
- package/lib/node/blocks-exports.mjs +1032 -996
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +2 -2
- package/lib/node/init.cjs +1 -1
- package/lib/node/init.mjs +2 -2
- package/lib/node/{node-runtime-e41e9eb6.js → node-runtime-792d0497.js} +3 -3
- package/lib/node/{node-runtime-c7c85f6c.cjs → node-runtime-8348be9f.cjs} +4 -4
- package/lib/{browser/server-entry-8bf52a55.js → node/server-entry-288f3748.js} +333 -330
- package/lib/node/server-entry-7304506e.cjs +2 -0
- package/lib/node/server-entry.cjs +1 -1
- package/lib/node/server-entry.mjs +1 -1
- package/package.json +3 -3
- package/types/blocks/slot/slot.d.ts +2 -2
- package/types/components/block/block.helpers.d.ts +1 -2
- package/types/constants/sdk-version.d.ts +1 -1
- package/types/functions/evaluate/node-runtime/init.d.ts +1 -0
- package/types/functions/get-processed-block.d.ts +1 -0
- package/lib/browser/server-entry-16fc27fe.cjs +0 -2
- package/lib/edge/blocks-854f4022.cjs +0 -12
- package/lib/edge/blocks-fdb24842.js +0 -808
- package/lib/edge/slot-d723d000.cjs +0 -1
- package/lib/node/server-entry-16fc27fe.cjs +0 -2
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
import { jsx as
|
|
6
|
-
import { TARGET as
|
|
7
|
-
import { createContext as
|
|
8
|
-
const
|
|
2
|
+
var _e = Object.defineProperty;
|
|
3
|
+
var ze = (e, t, n) => t in e ? _e(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
4
|
+
var ne = (e, t, n) => (ze(e, typeof t != "symbol" ? t + "" : t, n), n);
|
|
5
|
+
import { jsx as l, Fragment as E, jsxs as V } from "react/jsx-runtime";
|
|
6
|
+
import { TARGET as U, isEditing as $, isBrowser as H, getUserAttributes as Je, checkIsDefined as Q, logger as Z, isPreviewing as Re, registerInsertMenu as Ye, setupBrowserForEditing as Ge, createRegisterComponentMessage as Qe, getDefaultCanTrack as X, _track as he, fetchOneEntry as Ee, createEditorListener as Xe, fetch as Ze, serializeIncludingFunctions as ge, handleABTestingSync as et } from "./server-entry-288f3748.js";
|
|
7
|
+
import { createContext as Be, useState as T, useEffect as P, useRef as z, useContext as be, createElement as Pe } from "react";
|
|
8
|
+
const tt = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), nt = (e) => typeof e == "string" && tt.has(e.toLowerCase());
|
|
9
9
|
function de(e) {
|
|
10
|
-
return /* @__PURE__ */
|
|
10
|
+
return /* @__PURE__ */ l(E, { children: nt(e.TagName) ? /* @__PURE__ */ l(E, { children: /* @__PURE__ */ l(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ l(E, { children: typeof e.TagName == "string" ? /* @__PURE__ */ l(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) : /* @__PURE__ */ l(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) });
|
|
11
11
|
}
|
|
12
|
-
const
|
|
13
|
-
switch (
|
|
12
|
+
const _ = () => {
|
|
13
|
+
switch (U) {
|
|
14
14
|
case "react":
|
|
15
15
|
case "reactNative":
|
|
16
16
|
case "rsc":
|
|
@@ -23,11 +23,11 @@ const z = () => {
|
|
|
23
23
|
return "class";
|
|
24
24
|
}
|
|
25
25
|
};
|
|
26
|
-
function
|
|
26
|
+
function it(e) {
|
|
27
27
|
function t() {
|
|
28
28
|
return {
|
|
29
29
|
...e.attributes,
|
|
30
|
-
[
|
|
30
|
+
[_()]: `${e.link ? "" : "builder-button"} ${e.attributes[_()] || ""}`,
|
|
31
31
|
...e.link ? {
|
|
32
32
|
href: e.link,
|
|
33
33
|
target: e.openLinkInNewTab ? "_blank" : void 0,
|
|
@@ -37,7 +37,7 @@ function nt(e) {
|
|
|
37
37
|
}
|
|
38
38
|
};
|
|
39
39
|
}
|
|
40
|
-
return /* @__PURE__ */
|
|
40
|
+
return /* @__PURE__ */ l(
|
|
41
41
|
de,
|
|
42
42
|
{
|
|
43
43
|
attributes: t(),
|
|
@@ -47,7 +47,7 @@ function nt(e) {
|
|
|
47
47
|
}
|
|
48
48
|
);
|
|
49
49
|
}
|
|
50
|
-
const ue =
|
|
50
|
+
const ue = Be({
|
|
51
51
|
content: null,
|
|
52
52
|
context: {},
|
|
53
53
|
localState: void 0,
|
|
@@ -61,15 +61,21 @@ const ue = Re({
|
|
|
61
61
|
BlocksWrapper: "div",
|
|
62
62
|
BlocksWrapperProps: {},
|
|
63
63
|
nonce: ""
|
|
64
|
-
}),
|
|
65
|
-
function
|
|
64
|
+
}), Ve = Be({ registeredComponents: {} });
|
|
65
|
+
function ot(e) {
|
|
66
66
|
var t;
|
|
67
67
|
return {
|
|
68
68
|
...(t = e.component) == null ? void 0 : t.options,
|
|
69
69
|
...e.options
|
|
70
70
|
};
|
|
71
71
|
}
|
|
72
|
-
|
|
72
|
+
function at(e, ...t) {
|
|
73
|
+
const n = Object.assign({}, e);
|
|
74
|
+
for (const i of t)
|
|
75
|
+
delete n[i];
|
|
76
|
+
return n;
|
|
77
|
+
}
|
|
78
|
+
const rt = ({
|
|
73
79
|
builder: e,
|
|
74
80
|
context: t,
|
|
75
81
|
event: n,
|
|
@@ -81,12 +87,12 @@ const ot = ({
|
|
|
81
87
|
builder: e,
|
|
82
88
|
context: t,
|
|
83
89
|
event: n
|
|
84
|
-
}),
|
|
90
|
+
}), lt = () => ({
|
|
85
91
|
isEditing: $(),
|
|
86
|
-
isBrowser:
|
|
87
|
-
isServer: !
|
|
88
|
-
getUserAttributes: () =>
|
|
89
|
-
}),
|
|
92
|
+
isBrowser: H(),
|
|
93
|
+
isServer: !H(),
|
|
94
|
+
getUserAttributes: () => Je()
|
|
95
|
+
}), st = (e, {
|
|
90
96
|
isExpression: t = !0
|
|
91
97
|
}) => /* we disable this for cases where we definitely don't want a return */ t && !(e.includes(";") || e.includes(" return ") || e.trim().startsWith("return ")) ? `return (${e});` : e, pe = ({
|
|
92
98
|
code: e,
|
|
@@ -94,22 +100,22 @@ const ot = ({
|
|
|
94
100
|
context: n,
|
|
95
101
|
event: i,
|
|
96
102
|
localState: o,
|
|
97
|
-
rootSetState:
|
|
98
|
-
rootState:
|
|
103
|
+
rootSetState: a,
|
|
104
|
+
rootState: r
|
|
99
105
|
}) => {
|
|
100
|
-
const
|
|
106
|
+
const s = rt({
|
|
101
107
|
builder: t,
|
|
102
108
|
context: n,
|
|
103
109
|
event: i,
|
|
104
|
-
state:
|
|
105
|
-
rootState:
|
|
110
|
+
state: Ae({
|
|
111
|
+
rootState: r,
|
|
106
112
|
localState: o,
|
|
107
|
-
rootSetState:
|
|
113
|
+
rootSetState: a
|
|
108
114
|
})
|
|
109
115
|
});
|
|
110
|
-
return new Function(...
|
|
116
|
+
return new Function(...s.map(([d]) => d), e)(...s.map(([, d]) => d));
|
|
111
117
|
};
|
|
112
|
-
function
|
|
118
|
+
function Ae({
|
|
113
119
|
rootState: e,
|
|
114
120
|
localState: t,
|
|
115
121
|
rootSetState: n
|
|
@@ -118,33 +124,33 @@ function Pe({
|
|
|
118
124
|
get: (i, o) => {
|
|
119
125
|
if (t && o in t)
|
|
120
126
|
return t[o];
|
|
121
|
-
const
|
|
122
|
-
return typeof
|
|
123
|
-
rootState:
|
|
127
|
+
const a = i[o];
|
|
128
|
+
return typeof a == "object" && a !== null ? Ae({
|
|
129
|
+
rootState: a,
|
|
124
130
|
localState: void 0,
|
|
125
|
-
rootSetState: n ? (
|
|
126
|
-
i[o] =
|
|
131
|
+
rootSetState: n ? (r) => {
|
|
132
|
+
i[o] = r, n(i);
|
|
127
133
|
} : void 0
|
|
128
|
-
}) :
|
|
134
|
+
}) : a;
|
|
129
135
|
},
|
|
130
|
-
set: (i, o,
|
|
136
|
+
set: (i, o, a) => {
|
|
131
137
|
if (t && o in t)
|
|
132
138
|
throw new Error("Writing to local state is not allowed as it is read-only.");
|
|
133
|
-
return i[o] =
|
|
139
|
+
return i[o] = a, n == null || n(i), !0;
|
|
134
140
|
}
|
|
135
141
|
});
|
|
136
142
|
}
|
|
137
|
-
function
|
|
143
|
+
function ct() {
|
|
138
144
|
var e;
|
|
139
|
-
return typeof process != "undefined" &&
|
|
145
|
+
return typeof process != "undefined" && Q((e = process == null ? void 0 : process.versions) == null ? void 0 : e.node);
|
|
140
146
|
}
|
|
141
|
-
const
|
|
147
|
+
const dt = () => {
|
|
142
148
|
var i;
|
|
143
|
-
if (!
|
|
149
|
+
if (!ct())
|
|
144
150
|
return !1;
|
|
145
151
|
const e = process.arch === "arm64", t = process.version.startsWith("v20"), n = (i = process.env.NODE_OPTIONS) == null ? void 0 : i.includes("--no-node-snapshot");
|
|
146
152
|
return e && t && !n ? (Z.log("Skipping usage of `isolated-vm` to avoid crashes in Node v20 on an arm64 machine.\n If you would like to use the `isolated-vm` package on this machine, please provide the `NODE_OPTIONS=--no-node-snapshot` config to your Node process.\n See https://github.com/BuilderIO/builder/blob/main/packages/sdks/README.md#node-v20--m1-macs-apple-silicon-support for more information.\n "), !0) : !1;
|
|
147
|
-
},
|
|
153
|
+
}, ut = (e) => (H() || dt(), pe(e)), mt = !0, L = class L {
|
|
148
154
|
static getCacheKey(t) {
|
|
149
155
|
return JSON.stringify({
|
|
150
156
|
...t,
|
|
@@ -162,57 +168,95 @@ const st = () => {
|
|
|
162
168
|
});
|
|
163
169
|
}
|
|
164
170
|
};
|
|
165
|
-
|
|
166
|
-
let
|
|
167
|
-
function
|
|
171
|
+
ne(L, "cacheLimit", 20), ne(L, "cache", /* @__PURE__ */ new Map());
|
|
172
|
+
let j = L;
|
|
173
|
+
function K({
|
|
168
174
|
code: e,
|
|
169
175
|
context: t,
|
|
170
176
|
localState: n,
|
|
171
177
|
rootState: i,
|
|
172
178
|
rootSetState: o,
|
|
173
|
-
event:
|
|
174
|
-
isExpression:
|
|
175
|
-
enableCache:
|
|
179
|
+
event: a,
|
|
180
|
+
isExpression: r = !0,
|
|
181
|
+
enableCache: s
|
|
176
182
|
}) {
|
|
177
183
|
if (e === "")
|
|
178
184
|
return;
|
|
179
|
-
const
|
|
180
|
-
code:
|
|
181
|
-
isExpression:
|
|
185
|
+
const d = {
|
|
186
|
+
code: st(e, {
|
|
187
|
+
isExpression: r
|
|
182
188
|
}),
|
|
183
|
-
builder:
|
|
189
|
+
builder: lt(),
|
|
184
190
|
context: t,
|
|
185
|
-
event:
|
|
191
|
+
event: a,
|
|
186
192
|
rootSetState: o,
|
|
187
193
|
rootState: i,
|
|
188
194
|
localState: n
|
|
189
195
|
};
|
|
190
|
-
if (
|
|
191
|
-
const
|
|
192
|
-
if (
|
|
193
|
-
return
|
|
196
|
+
if (s && !mt) {
|
|
197
|
+
const c = j.getCacheKey(d), u = j.getCachedValue(c);
|
|
198
|
+
if (u)
|
|
199
|
+
return u.value;
|
|
194
200
|
}
|
|
195
201
|
try {
|
|
196
|
-
const
|
|
197
|
-
if (
|
|
198
|
-
const
|
|
199
|
-
|
|
200
|
-
}
|
|
201
|
-
return
|
|
202
|
-
} catch (
|
|
203
|
-
Z.error("Failed code evaluation: " +
|
|
202
|
+
const c = ut(d);
|
|
203
|
+
if (s) {
|
|
204
|
+
const u = j.getCacheKey(d);
|
|
205
|
+
j.setCachedValue(u, c);
|
|
206
|
+
}
|
|
207
|
+
return c;
|
|
208
|
+
} catch (c) {
|
|
209
|
+
Z.error("Failed code evaluation: " + c.message, {
|
|
204
210
|
code: e
|
|
205
211
|
});
|
|
206
212
|
return;
|
|
207
213
|
}
|
|
208
214
|
}
|
|
209
|
-
const me = (e) => JSON.parse(JSON.stringify(e)),
|
|
215
|
+
const me = (e) => JSON.parse(JSON.stringify(e)), Ne = (e, t, n) => {
|
|
210
216
|
if (Object(e) !== e)
|
|
211
217
|
return e;
|
|
212
218
|
const i = Array.isArray(t) ? t : t.toString().match(/[^.[\]]+/g);
|
|
213
|
-
return i.slice(0, -1).reduce((o,
|
|
219
|
+
return i.slice(0, -1).reduce((o, a, r) => Object(o[a]) === o[a] ? o[a] : o[a] = Math.abs(Number(i[r + 1])) >> 0 === +i[r + 1] ? [] : {}, e)[i[i.length - 1]] = n, e;
|
|
214
220
|
};
|
|
215
|
-
|
|
221
|
+
function se(e) {
|
|
222
|
+
if (e === null || typeof e != "object")
|
|
223
|
+
return e;
|
|
224
|
+
if (Array.isArray(e))
|
|
225
|
+
return e.map((n) => se(n));
|
|
226
|
+
if (e["@type"] === "@builder.io/sdk:Element")
|
|
227
|
+
return e;
|
|
228
|
+
const t = {};
|
|
229
|
+
for (const n in e)
|
|
230
|
+
n !== "meta" && Object.prototype.hasOwnProperty.call(e, n) && (t[n] = se(e[n]));
|
|
231
|
+
return t;
|
|
232
|
+
}
|
|
233
|
+
const ft = ["svelte", "vue", "angular", "qwik", "solid"].includes(U), ht = (e) => {
|
|
234
|
+
if (ft) {
|
|
235
|
+
const t = me(e);
|
|
236
|
+
return {
|
|
237
|
+
...t,
|
|
238
|
+
properties: {
|
|
239
|
+
...t.properties
|
|
240
|
+
},
|
|
241
|
+
actions: {
|
|
242
|
+
...t.actions
|
|
243
|
+
}
|
|
244
|
+
};
|
|
245
|
+
} else {
|
|
246
|
+
const t = se(at(e, "children", "meta"));
|
|
247
|
+
return {
|
|
248
|
+
...t,
|
|
249
|
+
properties: {
|
|
250
|
+
...t.properties
|
|
251
|
+
},
|
|
252
|
+
actions: {
|
|
253
|
+
...t.actions
|
|
254
|
+
},
|
|
255
|
+
children: e.children,
|
|
256
|
+
meta: e.meta
|
|
257
|
+
};
|
|
258
|
+
}
|
|
259
|
+
}, gt = ({
|
|
216
260
|
block: e,
|
|
217
261
|
context: t,
|
|
218
262
|
localState: n,
|
|
@@ -221,180 +265,172 @@ const dt = ({
|
|
|
221
265
|
}) => {
|
|
222
266
|
if (!e.bindings)
|
|
223
267
|
return e;
|
|
224
|
-
const
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
},
|
|
229
|
-
actions: {
|
|
230
|
-
...r.actions
|
|
231
|
-
}
|
|
232
|
-
};
|
|
233
|
-
for (const l in e.bindings) {
|
|
234
|
-
const c = e.bindings[l], d = H({
|
|
235
|
-
code: c,
|
|
268
|
+
const a = ht(e);
|
|
269
|
+
for (const r in e.bindings) {
|
|
270
|
+
const s = e.bindings[r], d = K({
|
|
271
|
+
code: s,
|
|
236
272
|
localState: n,
|
|
237
273
|
rootState: i,
|
|
238
274
|
rootSetState: o,
|
|
239
275
|
context: t,
|
|
240
276
|
enableCache: !0
|
|
241
277
|
});
|
|
242
|
-
|
|
278
|
+
Ne(a, r, d);
|
|
243
279
|
}
|
|
244
280
|
return a;
|
|
245
281
|
};
|
|
246
|
-
function
|
|
282
|
+
function bt({
|
|
247
283
|
block: e,
|
|
248
284
|
context: t,
|
|
249
285
|
shouldEvaluateBindings: n,
|
|
250
286
|
localState: i,
|
|
251
287
|
rootState: o,
|
|
252
|
-
rootSetState:
|
|
288
|
+
rootSetState: a
|
|
253
289
|
}) {
|
|
254
|
-
const
|
|
255
|
-
return n ?
|
|
256
|
-
block:
|
|
290
|
+
const r = e;
|
|
291
|
+
return n ? gt({
|
|
292
|
+
block: r,
|
|
257
293
|
localState: i,
|
|
258
294
|
rootState: o,
|
|
259
|
-
rootSetState:
|
|
295
|
+
rootSetState: a,
|
|
260
296
|
context: t
|
|
261
|
-
}) :
|
|
297
|
+
}) : r;
|
|
262
298
|
}
|
|
263
|
-
const
|
|
264
|
-
function
|
|
265
|
-
let i, o,
|
|
266
|
-
const
|
|
267
|
-
|
|
299
|
+
const ee = (e) => e ? e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g, "$1-$2").toLowerCase() : "";
|
|
300
|
+
function pt(e, t, n = {}) {
|
|
301
|
+
let i, o, a, r = null, s = 0;
|
|
302
|
+
const d = function() {
|
|
303
|
+
s = n.leading === !1 ? 0 : Date.now(), r = null, a = e.apply(i, o), r || (i = o = null);
|
|
268
304
|
};
|
|
269
305
|
return function() {
|
|
270
|
-
const
|
|
271
|
-
!
|
|
272
|
-
const
|
|
273
|
-
return i = this, o = arguments,
|
|
306
|
+
const c = Date.now();
|
|
307
|
+
!s && n.leading === !1 && (s = c);
|
|
308
|
+
const u = t - (c - s);
|
|
309
|
+
return i = this, o = arguments, u <= 0 || u > t ? (r && (clearTimeout(r), r = null), s = c, a = e.apply(i, o), r || (i = o = null)) : !r && n.trailing !== !1 && (r = setTimeout(d, u)), a;
|
|
274
310
|
};
|
|
275
311
|
}
|
|
276
|
-
function
|
|
312
|
+
function q(e, ...t) {
|
|
277
313
|
const n = Object(e);
|
|
278
314
|
for (let i = 1; i < arguments.length; i++) {
|
|
279
315
|
const o = arguments[i];
|
|
280
316
|
if (o != null)
|
|
281
|
-
for (const
|
|
282
|
-
Object.prototype.hasOwnProperty.call(o,
|
|
317
|
+
for (const a in o)
|
|
318
|
+
Object.prototype.hasOwnProperty.call(o, a) && (n[a] = o[a]);
|
|
283
319
|
}
|
|
284
320
|
return n;
|
|
285
321
|
}
|
|
286
|
-
function
|
|
322
|
+
function yt(e) {
|
|
287
323
|
for (const t of e)
|
|
288
324
|
switch (t.trigger) {
|
|
289
325
|
case "pageLoad":
|
|
290
|
-
|
|
326
|
+
$e(t);
|
|
291
327
|
break;
|
|
292
328
|
case "scrollInView":
|
|
293
|
-
|
|
329
|
+
vt(t);
|
|
294
330
|
break;
|
|
295
331
|
}
|
|
296
332
|
}
|
|
297
|
-
function
|
|
333
|
+
function We(e) {
|
|
298
334
|
console.warn(`Cannot animate element: element with ID ${e} not found!`);
|
|
299
335
|
}
|
|
300
|
-
function
|
|
301
|
-
const n =
|
|
302
|
-
for (const
|
|
303
|
-
for (const
|
|
304
|
-
|
|
336
|
+
function Fe(e, t) {
|
|
337
|
+
const n = xt(e), i = getComputedStyle(t), o = e.steps[0].styles, a = e.steps[e.steps.length - 1].styles, r = [o, a];
|
|
338
|
+
for (const s of r)
|
|
339
|
+
for (const d of n)
|
|
340
|
+
d in s || (s[d] = i[d]);
|
|
305
341
|
}
|
|
306
|
-
function
|
|
342
|
+
function xt(e) {
|
|
307
343
|
const t = [];
|
|
308
344
|
for (const n of e.steps)
|
|
309
345
|
for (const i in n.styles)
|
|
310
346
|
t.indexOf(i) === -1 && t.push(i);
|
|
311
347
|
return t;
|
|
312
348
|
}
|
|
313
|
-
function
|
|
349
|
+
function $e(e) {
|
|
314
350
|
const t = Array.prototype.slice.call(document.getElementsByClassName(e.elementId || e.id || ""));
|
|
315
351
|
if (!t.length) {
|
|
316
|
-
|
|
352
|
+
We(e.elementId || e.id || "");
|
|
317
353
|
return;
|
|
318
354
|
}
|
|
319
355
|
Array.from(t).forEach((n) => {
|
|
320
|
-
|
|
321
|
-
n.style.transition = `all ${e.duration}s ${
|
|
356
|
+
Fe(e, n), n.style.transition = "none", n.style.transitionDelay = "0", q(n.style, e.steps[0].styles), setTimeout(() => {
|
|
357
|
+
n.style.transition = `all ${e.duration}s ${ee(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s"), q(n.style, e.steps[1].styles), setTimeout(() => {
|
|
322
358
|
n.style.transition = "", n.style.transitionDelay = "";
|
|
323
359
|
}, (e.delay || 0) * 1e3 + e.duration * 1e3 + 100);
|
|
324
360
|
});
|
|
325
361
|
});
|
|
326
362
|
}
|
|
327
|
-
function
|
|
363
|
+
function vt(e) {
|
|
328
364
|
const t = Array.prototype.slice.call(document.getElementsByClassName(e.elementId || e.id || ""));
|
|
329
365
|
if (!t.length) {
|
|
330
|
-
|
|
366
|
+
We(e.elementId || e.id || "");
|
|
331
367
|
return;
|
|
332
368
|
}
|
|
333
369
|
Array.from(t).forEach((n) => {
|
|
334
|
-
|
|
370
|
+
Fe(e, n);
|
|
335
371
|
let i = !1, o = !1;
|
|
336
|
-
function
|
|
337
|
-
!i &&
|
|
338
|
-
|
|
372
|
+
function a() {
|
|
373
|
+
!i && s(n) ? (i = !0, o = !0, setTimeout(() => {
|
|
374
|
+
q(n.style, e.steps[1].styles), e.repeat || document.removeEventListener("scroll", r), setTimeout(() => {
|
|
339
375
|
o = !1, e.repeat || (n.style.transition = "", n.style.transitionDelay = "");
|
|
340
376
|
}, (e.duration + (e.delay || 0)) * 1e3 + 100);
|
|
341
|
-
})) : e.repeat && i && !o && !
|
|
377
|
+
})) : e.repeat && i && !o && !s(n) && (i = !1, q(n.style, e.steps[0].styles));
|
|
342
378
|
}
|
|
343
|
-
const
|
|
379
|
+
const r = pt(a, 200, {
|
|
344
380
|
leading: !1
|
|
345
381
|
});
|
|
346
|
-
function
|
|
347
|
-
const
|
|
348
|
-
return
|
|
382
|
+
function s(u) {
|
|
383
|
+
const g = u.getBoundingClientRect(), m = window.innerHeight, h = (e.thresholdPercent || 0) / 100 * m;
|
|
384
|
+
return g.bottom > h && g.top < m - h;
|
|
349
385
|
}
|
|
350
|
-
const
|
|
351
|
-
function
|
|
352
|
-
|
|
386
|
+
const d = e.steps[0].styles;
|
|
387
|
+
function c() {
|
|
388
|
+
q(n.style, d);
|
|
353
389
|
}
|
|
354
|
-
|
|
355
|
-
n.style.transition = `all ${e.duration}s ${
|
|
356
|
-
}), document.addEventListener("scroll",
|
|
390
|
+
c(), setTimeout(() => {
|
|
391
|
+
n.style.transition = `all ${e.duration}s ${ee(e.easing)}`, e.delay && (n.style.transitionDelay = e.delay + "s");
|
|
392
|
+
}), document.addEventListener("scroll", r, {
|
|
357
393
|
capture: !0,
|
|
358
394
|
passive: !0
|
|
359
|
-
}),
|
|
395
|
+
}), a();
|
|
360
396
|
});
|
|
361
397
|
}
|
|
362
|
-
const
|
|
398
|
+
const De = (e) => Object.entries(e).map(([n, i]) => {
|
|
363
399
|
if (typeof i == "string")
|
|
364
|
-
return `${
|
|
365
|
-
}).filter(
|
|
366
|
-
`),
|
|
400
|
+
return `${ee(n)}: ${i};`;
|
|
401
|
+
}).filter(Q), St = (e) => De(e).join(`
|
|
402
|
+
`), Y = ({
|
|
367
403
|
mediaQuery: e,
|
|
368
404
|
className: t,
|
|
369
405
|
styles: n
|
|
370
406
|
}) => {
|
|
371
407
|
const i = `.${t} {
|
|
372
|
-
${
|
|
408
|
+
${St(n)}
|
|
373
409
|
}`;
|
|
374
410
|
return e ? `${e} {
|
|
375
411
|
${i}
|
|
376
412
|
}` : i;
|
|
377
413
|
};
|
|
378
|
-
function
|
|
414
|
+
function kt({
|
|
379
415
|
style: e
|
|
380
416
|
}) {
|
|
381
417
|
return e;
|
|
382
418
|
}
|
|
383
|
-
const
|
|
419
|
+
const Ct = ({
|
|
384
420
|
block: e,
|
|
385
421
|
context: t
|
|
386
|
-
}) =>
|
|
422
|
+
}) => Le(kt({
|
|
387
423
|
style: e.style || {},
|
|
388
424
|
context: t,
|
|
389
425
|
block: e
|
|
390
426
|
}));
|
|
391
|
-
function
|
|
392
|
-
switch (
|
|
427
|
+
function Le(e) {
|
|
428
|
+
switch (U) {
|
|
393
429
|
case "svelte":
|
|
394
430
|
case "vue":
|
|
395
431
|
case "solid":
|
|
396
432
|
case "angular":
|
|
397
|
-
return
|
|
433
|
+
return De(e).join(" ");
|
|
398
434
|
case "qwik":
|
|
399
435
|
case "reactNative":
|
|
400
436
|
case "react":
|
|
@@ -402,29 +438,21 @@ function $e(e) {
|
|
|
402
438
|
return e;
|
|
403
439
|
}
|
|
404
440
|
}
|
|
405
|
-
const
|
|
441
|
+
const Tt = ({
|
|
406
442
|
block: e,
|
|
407
|
-
|
|
408
|
-
registeredComponents: n
|
|
443
|
+
registeredComponents: t
|
|
409
444
|
}) => {
|
|
410
|
-
var
|
|
411
|
-
const
|
|
412
|
-
|
|
413
|
-
localState: t.localState,
|
|
414
|
-
rootState: t.rootState,
|
|
415
|
-
rootSetState: t.rootSetState,
|
|
416
|
-
context: t.context,
|
|
417
|
-
shouldEvaluateBindings: !1
|
|
418
|
-
}).component) == null ? void 0 : r.name;
|
|
419
|
-
if (!i)
|
|
445
|
+
var o;
|
|
446
|
+
const n = (o = e.component) == null ? void 0 : o.name;
|
|
447
|
+
if (!n)
|
|
420
448
|
return null;
|
|
421
|
-
const
|
|
422
|
-
if (
|
|
423
|
-
return
|
|
449
|
+
const i = t[n];
|
|
450
|
+
if (i)
|
|
451
|
+
return i;
|
|
424
452
|
console.warn(`
|
|
425
|
-
Could not find a registered component named "${
|
|
453
|
+
Could not find a registered component named "${n}".
|
|
426
454
|
If you registered it, is the file that registered it imported by the file that needs to render it?`);
|
|
427
|
-
},
|
|
455
|
+
}, It = ({
|
|
428
456
|
block: e,
|
|
429
457
|
context: t
|
|
430
458
|
}) => {
|
|
@@ -434,7 +462,7 @@ const yt = ({
|
|
|
434
462
|
} = e;
|
|
435
463
|
if (!(n != null && n.collection))
|
|
436
464
|
return;
|
|
437
|
-
const o =
|
|
465
|
+
const o = K({
|
|
438
466
|
code: n.collection,
|
|
439
467
|
localState: t.localState,
|
|
440
468
|
rootState: t.rootState,
|
|
@@ -444,41 +472,41 @@ const yt = ({
|
|
|
444
472
|
});
|
|
445
473
|
if (!Array.isArray(o))
|
|
446
474
|
return;
|
|
447
|
-
const
|
|
448
|
-
return o.map((
|
|
475
|
+
const a = n.collection.split(".").pop(), r = n.itemName || (a ? a + "Item" : "item");
|
|
476
|
+
return o.map((d, c) => ({
|
|
449
477
|
context: {
|
|
450
478
|
...t,
|
|
451
479
|
localState: {
|
|
452
480
|
...t.localState,
|
|
453
|
-
$index:
|
|
454
|
-
$item:
|
|
455
|
-
[
|
|
456
|
-
[`$${
|
|
481
|
+
$index: c,
|
|
482
|
+
$item: d,
|
|
483
|
+
[r]: d,
|
|
484
|
+
[`$${r}Index`]: c
|
|
457
485
|
}
|
|
458
486
|
},
|
|
459
487
|
block: i
|
|
460
488
|
}));
|
|
461
|
-
},
|
|
489
|
+
}, wt = (e, t) => {
|
|
462
490
|
var n;
|
|
463
491
|
return (n = e == null ? void 0 : e.shouldReceiveBuilderProps) != null && n.builderLinkComponent ? {
|
|
464
492
|
builderLinkComponent: t
|
|
465
493
|
} : {};
|
|
466
|
-
},
|
|
494
|
+
}, Rt = (e, t) => {
|
|
467
495
|
var n;
|
|
468
496
|
return (n = e == null ? void 0 : e.shouldReceiveBuilderProps) != null && n.builderComponents ? {
|
|
469
497
|
builderComponents: t
|
|
470
498
|
} : {};
|
|
471
|
-
},
|
|
499
|
+
}, Et = (e, t) => {
|
|
472
500
|
var n;
|
|
473
501
|
return (n = e == null ? void 0 : e.shouldReceiveBuilderProps) != null && n.builderBlock ? {
|
|
474
502
|
builderBlock: t
|
|
475
503
|
} : {};
|
|
476
|
-
},
|
|
504
|
+
}, Bt = (e, t) => {
|
|
477
505
|
var n;
|
|
478
506
|
return (n = e == null ? void 0 : e.shouldReceiveBuilderProps) != null && n.builderContext ? {
|
|
479
507
|
builderContext: t
|
|
480
508
|
} : {};
|
|
481
|
-
},
|
|
509
|
+
}, Oe = {
|
|
482
510
|
small: {
|
|
483
511
|
min: 320,
|
|
484
512
|
default: 321,
|
|
@@ -494,11 +522,11 @@ const yt = ({
|
|
|
494
522
|
default: 991,
|
|
495
523
|
max: 1200
|
|
496
524
|
}
|
|
497
|
-
}, ye = (e, t =
|
|
525
|
+
}, ye = (e, t = Oe) => `@media (max-width: ${t[e].max}px)`, Ue = ({
|
|
498
526
|
small: e,
|
|
499
527
|
medium: t
|
|
500
528
|
}) => {
|
|
501
|
-
const n = me(
|
|
529
|
+
const n = me(Oe);
|
|
502
530
|
if (!e || !t)
|
|
503
531
|
return n;
|
|
504
532
|
const i = Math.floor(e / 2);
|
|
@@ -513,16 +541,16 @@ const yt = ({
|
|
|
513
541
|
min: o,
|
|
514
542
|
default: o + 1
|
|
515
543
|
};
|
|
516
|
-
const
|
|
544
|
+
const a = n.medium.max + 1;
|
|
517
545
|
return n.large = {
|
|
518
546
|
max: 2e3,
|
|
519
547
|
// TODO: decide upper limit
|
|
520
|
-
min:
|
|
521
|
-
default:
|
|
548
|
+
min: a,
|
|
549
|
+
default: a + 1
|
|
522
550
|
}, n;
|
|
523
551
|
};
|
|
524
|
-
function
|
|
525
|
-
return /* @__PURE__ */
|
|
552
|
+
function te(e) {
|
|
553
|
+
return /* @__PURE__ */ l(
|
|
526
554
|
"style",
|
|
527
555
|
{
|
|
528
556
|
dangerouslySetInnerHTML: { __html: e.styles },
|
|
@@ -531,73 +559,59 @@ function ne(e) {
|
|
|
531
559
|
}
|
|
532
560
|
);
|
|
533
561
|
}
|
|
534
|
-
function
|
|
562
|
+
function Pt(e) {
|
|
535
563
|
function t() {
|
|
536
|
-
const i =
|
|
537
|
-
|
|
538
|
-
localState: e.context.localState,
|
|
539
|
-
rootState: e.context.rootState,
|
|
540
|
-
rootSetState: e.context.rootSetState,
|
|
541
|
-
context: e.context.context,
|
|
542
|
-
shouldEvaluateBindings: !0
|
|
543
|
-
});
|
|
544
|
-
return G(i.hide) ? !i.hide : G(i.show) ? i.show : !0;
|
|
564
|
+
const i = e.block;
|
|
565
|
+
return Q(i.hide) ? !i.hide : Q(i.show) ? i.show : !0;
|
|
545
566
|
}
|
|
546
567
|
function n() {
|
|
547
|
-
var
|
|
548
|
-
const i =
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
rootSetState: e.context.rootSetState,
|
|
553
|
-
context: e.context.context,
|
|
554
|
-
shouldEvaluateBindings: !0
|
|
555
|
-
}), o = i.responsiveStyles, r = e.context.content, a = Le(
|
|
556
|
-
((p = r == null ? void 0 : r.meta) == null ? void 0 : p.breakpoints) || {}
|
|
557
|
-
), l = o == null ? void 0 : o.large, c = o == null ? void 0 : o.medium, d = o == null ? void 0 : o.small, f = i.id;
|
|
558
|
-
if (!f)
|
|
568
|
+
var f, w, B;
|
|
569
|
+
const i = e.block, o = i.responsiveStyles, a = e.context.content, r = Ue(
|
|
570
|
+
((f = a == null ? void 0 : a.meta) == null ? void 0 : f.breakpoints) || {}
|
|
571
|
+
), s = o == null ? void 0 : o.large, d = o == null ? void 0 : o.medium, c = o == null ? void 0 : o.small, u = i.id;
|
|
572
|
+
if (!u)
|
|
559
573
|
return "";
|
|
560
|
-
const
|
|
561
|
-
className:
|
|
562
|
-
styles:
|
|
563
|
-
}) : "", m =
|
|
564
|
-
className:
|
|
565
|
-
styles:
|
|
574
|
+
const g = s ? Y({
|
|
575
|
+
className: u,
|
|
576
|
+
styles: s
|
|
577
|
+
}) : "", m = d ? Y({
|
|
578
|
+
className: u,
|
|
579
|
+
styles: d,
|
|
566
580
|
mediaQuery: ye(
|
|
567
581
|
"medium",
|
|
568
|
-
|
|
582
|
+
r
|
|
569
583
|
)
|
|
570
|
-
}) : "",
|
|
571
|
-
className:
|
|
572
|
-
styles:
|
|
584
|
+
}) : "", x = c ? Y({
|
|
585
|
+
className: u,
|
|
586
|
+
styles: c,
|
|
573
587
|
mediaQuery: ye(
|
|
574
588
|
"small",
|
|
575
|
-
|
|
589
|
+
r
|
|
576
590
|
)
|
|
577
|
-
}) : "",
|
|
578
|
-
let
|
|
579
|
-
if (
|
|
580
|
-
const A = ((
|
|
581
|
-
|
|
582
|
-
className: `${
|
|
591
|
+
}) : "", h = i.animations && i.animations.find((A) => A.trigger === "hover");
|
|
592
|
+
let p = "";
|
|
593
|
+
if (h) {
|
|
594
|
+
const A = ((B = (w = h.steps) == null ? void 0 : w[1]) == null ? void 0 : B.styles) || {};
|
|
595
|
+
p = Y({
|
|
596
|
+
className: `${u}:hover`,
|
|
583
597
|
styles: {
|
|
584
598
|
...A,
|
|
585
|
-
transition: `all ${
|
|
586
|
-
|
|
599
|
+
transition: `all ${h.duration}s ${ee(
|
|
600
|
+
h.easing
|
|
587
601
|
)}`,
|
|
588
|
-
transitionDelay:
|
|
602
|
+
transitionDelay: h.delay ? `${h.delay}s` : "0s"
|
|
589
603
|
}
|
|
590
604
|
}) || "";
|
|
591
605
|
}
|
|
592
606
|
return [
|
|
593
|
-
u,
|
|
594
|
-
m,
|
|
595
607
|
g,
|
|
596
|
-
|
|
608
|
+
m,
|
|
609
|
+
x,
|
|
610
|
+
p
|
|
597
611
|
].join(" ");
|
|
598
612
|
}
|
|
599
|
-
return /* @__PURE__ */
|
|
600
|
-
|
|
613
|
+
return /* @__PURE__ */ l(E, { children: n() && t() ? /* @__PURE__ */ l(E, { children: /* @__PURE__ */ l(
|
|
614
|
+
te,
|
|
601
615
|
{
|
|
602
616
|
id: "builderio-block",
|
|
603
617
|
styles: n(),
|
|
@@ -605,10 +619,10 @@ function Tt(e) {
|
|
|
605
619
|
}
|
|
606
620
|
) }) : null });
|
|
607
621
|
}
|
|
608
|
-
function
|
|
622
|
+
function Vt(e) {
|
|
609
623
|
return e.charAt(0).toUpperCase() + e.slice(1);
|
|
610
624
|
}
|
|
611
|
-
const
|
|
625
|
+
const At = (e) => `on${Vt(e)}`, Nt = (e, t) => (n) => K({
|
|
612
626
|
code: e,
|
|
613
627
|
context: t.context,
|
|
614
628
|
localState: t.localState,
|
|
@@ -618,33 +632,33 @@ const wt = (e) => `on${It(e)}`, Rt = (e, t) => (n) => H({
|
|
|
618
632
|
isExpression: !1,
|
|
619
633
|
enableCache: !0
|
|
620
634
|
});
|
|
621
|
-
function
|
|
635
|
+
function Me(e) {
|
|
622
636
|
var i;
|
|
623
637
|
const t = {}, n = (i = e.block.actions) != null ? i : {};
|
|
624
638
|
for (const o in n) {
|
|
625
639
|
if (!n.hasOwnProperty(o))
|
|
626
640
|
continue;
|
|
627
|
-
const
|
|
628
|
-
let
|
|
641
|
+
const a = n[o];
|
|
642
|
+
let r = At(o);
|
|
629
643
|
if (e.stripPrefix)
|
|
630
|
-
switch (
|
|
644
|
+
switch (U) {
|
|
631
645
|
case "vue":
|
|
632
|
-
|
|
646
|
+
r = r.replace("v-on:", "");
|
|
633
647
|
break;
|
|
634
648
|
case "svelte":
|
|
635
|
-
|
|
649
|
+
r = r.replace("on:", "");
|
|
636
650
|
break;
|
|
637
651
|
}
|
|
638
|
-
t[
|
|
652
|
+
t[r] = Nt(a, e);
|
|
639
653
|
}
|
|
640
654
|
return t;
|
|
641
655
|
}
|
|
642
|
-
function
|
|
656
|
+
function Wt({
|
|
643
657
|
properties: e
|
|
644
658
|
}) {
|
|
645
659
|
return e;
|
|
646
660
|
}
|
|
647
|
-
const
|
|
661
|
+
const Ft = (e) => ({
|
|
648
662
|
href: e.href
|
|
649
663
|
});
|
|
650
664
|
function fe({
|
|
@@ -653,23 +667,23 @@ function fe({
|
|
|
653
667
|
}) {
|
|
654
668
|
var i;
|
|
655
669
|
const n = {
|
|
656
|
-
...
|
|
670
|
+
...Ft(e),
|
|
657
671
|
...e.properties,
|
|
658
672
|
"builder-id": e.id,
|
|
659
|
-
style:
|
|
673
|
+
style: Ct({
|
|
660
674
|
block: e,
|
|
661
675
|
context: t
|
|
662
676
|
}),
|
|
663
|
-
[
|
|
677
|
+
[_()]: [e.id, "builder-block", e.class, (i = e.properties) == null ? void 0 : i.class].filter(Boolean).join(" ")
|
|
664
678
|
};
|
|
665
|
-
return
|
|
679
|
+
return Wt({
|
|
666
680
|
properties: n,
|
|
667
681
|
context: t,
|
|
668
682
|
block: e
|
|
669
683
|
});
|
|
670
684
|
}
|
|
671
|
-
function
|
|
672
|
-
return /* @__PURE__ */
|
|
685
|
+
function $t(e) {
|
|
686
|
+
return /* @__PURE__ */ l(
|
|
673
687
|
de,
|
|
674
688
|
{
|
|
675
689
|
TagName: e.Wrapper,
|
|
@@ -677,7 +691,7 @@ function Pt(e) {
|
|
|
677
691
|
block: e.block,
|
|
678
692
|
context: e.context
|
|
679
693
|
}),
|
|
680
|
-
actionAttributes:
|
|
694
|
+
actionAttributes: Me({
|
|
681
695
|
block: e.block,
|
|
682
696
|
rootState: e.context.rootState,
|
|
683
697
|
rootSetState: e.context.rootSetState,
|
|
@@ -689,14 +703,14 @@ function Pt(e) {
|
|
|
689
703
|
}
|
|
690
704
|
);
|
|
691
705
|
}
|
|
692
|
-
function
|
|
706
|
+
function Dt(e) {
|
|
693
707
|
function t() {
|
|
694
708
|
return e.includeBlockProps ? {
|
|
695
709
|
...fe({
|
|
696
710
|
block: e.block,
|
|
697
711
|
context: e.context
|
|
698
712
|
}),
|
|
699
|
-
...
|
|
713
|
+
...Me({
|
|
700
714
|
block: e.block,
|
|
701
715
|
rootState: e.context.rootState,
|
|
702
716
|
rootSetState: e.context.rootSetState,
|
|
@@ -705,18 +719,18 @@ function Vt(e) {
|
|
|
705
719
|
})
|
|
706
720
|
} : {};
|
|
707
721
|
}
|
|
708
|
-
return /* @__PURE__ */
|
|
722
|
+
return /* @__PURE__ */ l(e.Wrapper, { ...e.wrapperProps, attributes: t(), children: e.children });
|
|
709
723
|
}
|
|
710
|
-
const
|
|
724
|
+
const Lt = ({
|
|
711
725
|
componentOptions: e,
|
|
712
726
|
builderBlock: t,
|
|
713
727
|
context: n,
|
|
714
728
|
componentRef: i,
|
|
715
729
|
includeBlockProps: o,
|
|
716
|
-
isInteractive:
|
|
717
|
-
contextValue:
|
|
730
|
+
isInteractive: a,
|
|
731
|
+
contextValue: r
|
|
718
732
|
}) => {
|
|
719
|
-
const
|
|
733
|
+
const s = {
|
|
720
734
|
...e,
|
|
721
735
|
/**
|
|
722
736
|
* If `noWrap` is set to `true`, then the block's props/attributes are provided to the
|
|
@@ -725,27 +739,27 @@ const At = ({
|
|
|
725
739
|
...o ? {
|
|
726
740
|
attributes: fe({
|
|
727
741
|
block: t,
|
|
728
|
-
context:
|
|
742
|
+
context: r
|
|
729
743
|
})
|
|
730
744
|
} : {}
|
|
731
745
|
};
|
|
732
|
-
return
|
|
746
|
+
return a ? {
|
|
733
747
|
Wrapper: i,
|
|
734
748
|
block: t,
|
|
735
749
|
context: n,
|
|
736
750
|
wrapperProps: e,
|
|
737
751
|
includeBlockProps: o
|
|
738
|
-
} :
|
|
752
|
+
} : s;
|
|
739
753
|
};
|
|
740
754
|
function xe(e) {
|
|
741
755
|
var i;
|
|
742
756
|
const [t, n] = T(
|
|
743
|
-
() => e.isInteractive ?
|
|
757
|
+
() => e.isInteractive ? Dt : e.componentRef
|
|
744
758
|
);
|
|
745
|
-
return /* @__PURE__ */
|
|
759
|
+
return /* @__PURE__ */ l(E, { children: e.componentRef ? /* @__PURE__ */ l(E, { children: /* @__PURE__ */ l(
|
|
746
760
|
t,
|
|
747
761
|
{
|
|
748
|
-
...
|
|
762
|
+
...Lt({
|
|
749
763
|
componentOptions: e.componentOptions,
|
|
750
764
|
builderBlock: e.builderBlock,
|
|
751
765
|
context: e.context,
|
|
@@ -755,8 +769,8 @@ function xe(e) {
|
|
|
755
769
|
isInteractive: e.isInteractive,
|
|
756
770
|
contextValue: e.context
|
|
757
771
|
}),
|
|
758
|
-
children: (i = e.blockChildren) == null ? void 0 : i.map((o) => /* @__PURE__ */
|
|
759
|
-
|
|
772
|
+
children: (i = e.blockChildren) == null ? void 0 : i.map((o) => /* @__PURE__ */ l(
|
|
773
|
+
J,
|
|
760
774
|
{
|
|
761
775
|
block: o,
|
|
762
776
|
context: e.context,
|
|
@@ -768,10 +782,10 @@ function xe(e) {
|
|
|
768
782
|
}
|
|
769
783
|
) }) : null });
|
|
770
784
|
}
|
|
771
|
-
function
|
|
785
|
+
function ve(e) {
|
|
772
786
|
const [t, n] = T(() => e.repeatContext);
|
|
773
|
-
return /* @__PURE__ */
|
|
774
|
-
|
|
787
|
+
return /* @__PURE__ */ l(ue.Provider, { value: t, children: /* @__PURE__ */ l(
|
|
788
|
+
J,
|
|
775
789
|
{
|
|
776
790
|
block: e.block,
|
|
777
791
|
context: t,
|
|
@@ -780,24 +794,23 @@ function Nt(e) {
|
|
|
780
794
|
}
|
|
781
795
|
) });
|
|
782
796
|
}
|
|
783
|
-
function
|
|
784
|
-
var
|
|
797
|
+
function J(e) {
|
|
798
|
+
var u, g, m, x;
|
|
785
799
|
function t() {
|
|
786
|
-
return
|
|
787
|
-
block: e.block,
|
|
788
|
-
context: e.context,
|
|
789
|
-
registeredComponents: e.registeredComponents
|
|
790
|
-
});
|
|
791
|
-
}
|
|
792
|
-
function n() {
|
|
793
|
-
return xt({
|
|
800
|
+
return It({
|
|
794
801
|
block: e.block,
|
|
795
802
|
context: e.context
|
|
796
803
|
});
|
|
797
804
|
}
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
805
|
+
const [n, i] = T(() => ({
|
|
806
|
+
value: null,
|
|
807
|
+
update: !1
|
|
808
|
+
}));
|
|
809
|
+
function o() {
|
|
810
|
+
var p;
|
|
811
|
+
if (n.value && !n.update && !Re())
|
|
812
|
+
return n.value;
|
|
813
|
+
const h = (p = e.block.repeat) != null && p.collection ? e.block : bt({
|
|
801
814
|
block: e.block,
|
|
802
815
|
localState: e.context.localState,
|
|
803
816
|
rootState: e.context.rootState,
|
|
@@ -805,121 +818,140 @@ function _(e) {
|
|
|
805
818
|
context: e.context.context,
|
|
806
819
|
shouldEvaluateBindings: !0
|
|
807
820
|
});
|
|
821
|
+
return n.value = h, n.update = !1, h;
|
|
808
822
|
}
|
|
809
|
-
function
|
|
810
|
-
|
|
811
|
-
|
|
823
|
+
function a() {
|
|
824
|
+
return Tt({
|
|
825
|
+
block: o(),
|
|
826
|
+
registeredComponents: e.registeredComponents
|
|
827
|
+
});
|
|
812
828
|
}
|
|
813
829
|
function r() {
|
|
814
|
-
var
|
|
815
|
-
|
|
816
|
-
return !!((y = n == null ? void 0 : n()) != null && y.length);
|
|
817
|
-
const u = "hide" in i() ? i().hide : !1;
|
|
818
|
-
return ("show" in i() ? i().show : !0) && !u;
|
|
830
|
+
var p;
|
|
831
|
+
return e.block.tagName === "a" || ((p = o().properties) == null ? void 0 : p.href) || o().href ? e.linkComponent || "a" : e.block.tagName || "div";
|
|
819
832
|
}
|
|
820
|
-
function
|
|
821
|
-
var
|
|
822
|
-
|
|
833
|
+
function s() {
|
|
834
|
+
var f, w;
|
|
835
|
+
if ((f = e.block.repeat) != null && f.collection)
|
|
836
|
+
return !!((w = t == null ? void 0 : t()) != null && w.length);
|
|
837
|
+
const h = "hide" in o() ? o().hide : !1;
|
|
838
|
+
return ("show" in o() ? o().show : !0) && !h;
|
|
823
839
|
}
|
|
824
|
-
function
|
|
825
|
-
var
|
|
840
|
+
function d() {
|
|
841
|
+
var p, f;
|
|
842
|
+
return !((p = a == null ? void 0 : a()) != null && p.component) && !t() ? (f = o().children) != null ? f : [] : [];
|
|
843
|
+
}
|
|
844
|
+
function c() {
|
|
845
|
+
var h, p, f, w;
|
|
826
846
|
return {
|
|
827
|
-
blockChildren: (
|
|
828
|
-
componentRef: (
|
|
847
|
+
blockChildren: (h = o().children) != null ? h : [],
|
|
848
|
+
componentRef: (p = a == null ? void 0 : a()) == null ? void 0 : p.component,
|
|
829
849
|
componentOptions: {
|
|
830
|
-
...
|
|
831
|
-
...
|
|
832
|
-
...
|
|
833
|
-
...
|
|
834
|
-
...
|
|
835
|
-
|
|
850
|
+
...ot(o()),
|
|
851
|
+
...Et(a(), o()),
|
|
852
|
+
...Bt(a(), e.context),
|
|
853
|
+
...wt(a(), e.linkComponent),
|
|
854
|
+
...Rt(
|
|
855
|
+
a(),
|
|
836
856
|
e.registeredComponents
|
|
837
857
|
)
|
|
838
858
|
},
|
|
839
859
|
context: e.context,
|
|
840
860
|
linkComponent: e.linkComponent,
|
|
841
861
|
registeredComponents: e.registeredComponents,
|
|
842
|
-
builderBlock:
|
|
843
|
-
includeBlockProps: ((
|
|
844
|
-
isInteractive: !((
|
|
862
|
+
builderBlock: o(),
|
|
863
|
+
includeBlockProps: ((f = a == null ? void 0 : a()) == null ? void 0 : f.noWrap) === !0,
|
|
864
|
+
isInteractive: !((w = a == null ? void 0 : a()) != null && w.isRSC && U === "rsc")
|
|
845
865
|
};
|
|
846
866
|
}
|
|
847
867
|
return P(() => {
|
|
848
|
-
const
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
...
|
|
852
|
-
elementId:
|
|
868
|
+
const h = o().id, p = o().animations;
|
|
869
|
+
p && h && yt(
|
|
870
|
+
p.map((f) => ({
|
|
871
|
+
...f,
|
|
872
|
+
elementId: h
|
|
853
873
|
}))
|
|
854
874
|
);
|
|
855
|
-
}, []),
|
|
856
|
-
|
|
857
|
-
|
|
875
|
+
}, []), P(() => {
|
|
876
|
+
n.update = !0;
|
|
877
|
+
}), /* @__PURE__ */ l(E, { children: s() ? /* @__PURE__ */ V(E, { children: [
|
|
878
|
+
/* @__PURE__ */ l(Pt, { block: o(), context: e.context }),
|
|
879
|
+
(u = a == null ? void 0 : a()) != null && u.noWrap ? t() ? /* @__PURE__ */ l(E, { children: (x = t()) == null ? void 0 : x.map((h, p) => /* @__PURE__ */ l(
|
|
880
|
+
ve,
|
|
881
|
+
{
|
|
882
|
+
repeatContext: h.context,
|
|
883
|
+
block: h.block,
|
|
884
|
+
registeredComponents: e.registeredComponents,
|
|
885
|
+
linkComponent: e.linkComponent
|
|
886
|
+
},
|
|
887
|
+
p
|
|
888
|
+
)) }) : /* @__PURE__ */ l(
|
|
858
889
|
xe,
|
|
859
890
|
{
|
|
860
|
-
componentRef:
|
|
861
|
-
componentOptions:
|
|
862
|
-
blockChildren:
|
|
863
|
-
context:
|
|
864
|
-
registeredComponents:
|
|
865
|
-
linkComponent:
|
|
866
|
-
builderBlock:
|
|
867
|
-
includeBlockProps:
|
|
868
|
-
isInteractive:
|
|
891
|
+
componentRef: c().componentRef,
|
|
892
|
+
componentOptions: c().componentOptions,
|
|
893
|
+
blockChildren: c().blockChildren,
|
|
894
|
+
context: c().context,
|
|
895
|
+
registeredComponents: c().registeredComponents,
|
|
896
|
+
linkComponent: c().linkComponent,
|
|
897
|
+
builderBlock: c().builderBlock,
|
|
898
|
+
includeBlockProps: c().includeBlockProps,
|
|
899
|
+
isInteractive: c().isInteractive
|
|
869
900
|
}
|
|
870
|
-
)
|
|
871
|
-
|
|
901
|
+
) : /* @__PURE__ */ l(E, { children: t() ? /* @__PURE__ */ l(E, { children: (m = t()) == null ? void 0 : m.map((h, p) => /* @__PURE__ */ l(
|
|
902
|
+
ve,
|
|
872
903
|
{
|
|
873
|
-
repeatContext:
|
|
874
|
-
block:
|
|
904
|
+
repeatContext: h.context,
|
|
905
|
+
block: h.block,
|
|
875
906
|
registeredComponents: e.registeredComponents,
|
|
876
907
|
linkComponent: e.linkComponent
|
|
877
908
|
},
|
|
878
|
-
|
|
909
|
+
p
|
|
879
910
|
)) }) : /* @__PURE__ */ V(
|
|
880
|
-
|
|
911
|
+
$t,
|
|
881
912
|
{
|
|
882
|
-
Wrapper:
|
|
883
|
-
block:
|
|
913
|
+
Wrapper: r(),
|
|
914
|
+
block: o(),
|
|
884
915
|
context: e.context,
|
|
885
916
|
children: [
|
|
886
|
-
/* @__PURE__ */
|
|
917
|
+
/* @__PURE__ */ l(
|
|
887
918
|
xe,
|
|
888
919
|
{
|
|
889
|
-
componentRef:
|
|
890
|
-
componentOptions:
|
|
891
|
-
blockChildren:
|
|
892
|
-
context:
|
|
893
|
-
registeredComponents:
|
|
894
|
-
linkComponent:
|
|
895
|
-
builderBlock:
|
|
896
|
-
includeBlockProps:
|
|
897
|
-
isInteractive:
|
|
920
|
+
componentRef: c().componentRef,
|
|
921
|
+
componentOptions: c().componentOptions,
|
|
922
|
+
blockChildren: c().blockChildren,
|
|
923
|
+
context: c().context,
|
|
924
|
+
registeredComponents: c().registeredComponents,
|
|
925
|
+
linkComponent: c().linkComponent,
|
|
926
|
+
builderBlock: c().builderBlock,
|
|
927
|
+
includeBlockProps: c().includeBlockProps,
|
|
928
|
+
isInteractive: c().isInteractive
|
|
898
929
|
}
|
|
899
930
|
),
|
|
900
|
-
(
|
|
901
|
-
|
|
931
|
+
(g = d()) == null ? void 0 : g.map((h) => /* @__PURE__ */ l(
|
|
932
|
+
J,
|
|
902
933
|
{
|
|
903
|
-
block:
|
|
934
|
+
block: h,
|
|
904
935
|
registeredComponents: e.registeredComponents,
|
|
905
936
|
linkComponent: e.linkComponent,
|
|
906
937
|
context: e.context
|
|
907
938
|
},
|
|
908
|
-
|
|
939
|
+
h.id
|
|
909
940
|
))
|
|
910
941
|
]
|
|
911
942
|
}
|
|
912
943
|
) })
|
|
913
944
|
] }) : null });
|
|
914
945
|
}
|
|
915
|
-
function
|
|
916
|
-
|
|
917
|
-
var o;
|
|
918
|
-
return "builder-blocks" + ((o = e.blocks) != null && o.length ? "" : " no-blocks");
|
|
919
|
-
}
|
|
946
|
+
function Ot(e) {
|
|
947
|
+
const t = z(null);
|
|
920
948
|
function n() {
|
|
921
|
-
var
|
|
922
|
-
|
|
949
|
+
var a;
|
|
950
|
+
return "builder-blocks" + ((a = e.blocks) != null && a.length ? "" : " no-blocks");
|
|
951
|
+
}
|
|
952
|
+
function i() {
|
|
953
|
+
var a, r;
|
|
954
|
+
$() && !((a = e.blocks) != null && a.length) && ((r = window.parent) == null || r.postMessage(
|
|
923
955
|
{
|
|
924
956
|
type: "builder.clickEmptyBlocks",
|
|
925
957
|
data: {
|
|
@@ -930,9 +962,9 @@ function Wt(e) {
|
|
|
930
962
|
"*"
|
|
931
963
|
));
|
|
932
964
|
}
|
|
933
|
-
function
|
|
934
|
-
var
|
|
935
|
-
$() && !((
|
|
965
|
+
function o() {
|
|
966
|
+
var a, r;
|
|
967
|
+
$() && !((a = e.blocks) != null && a.length) && ((r = window.parent) == null || r.postMessage(
|
|
936
968
|
{
|
|
937
969
|
type: "builder.hoverEmptyBlocks",
|
|
938
970
|
data: {
|
|
@@ -943,22 +975,24 @@ function Wt(e) {
|
|
|
943
975
|
"*"
|
|
944
976
|
));
|
|
945
977
|
}
|
|
946
|
-
return
|
|
947
|
-
|
|
978
|
+
return P(() => {
|
|
979
|
+
}, []), /* @__PURE__ */ V(E, { children: [
|
|
980
|
+
/* @__PURE__ */ l(
|
|
948
981
|
e.BlocksWrapper,
|
|
949
982
|
{
|
|
950
|
-
|
|
983
|
+
ref: t,
|
|
984
|
+
className: n() + " props-blocks-wrapper-51ef31b4",
|
|
951
985
|
"builder-path": e.path,
|
|
952
986
|
"builder-parent-id": e.parent,
|
|
953
987
|
style: e.styleProp,
|
|
954
|
-
onClick: (
|
|
955
|
-
onMouseEnter: (
|
|
956
|
-
onKeyPress: (
|
|
988
|
+
onClick: (a) => i(),
|
|
989
|
+
onMouseEnter: (a) => o(),
|
|
990
|
+
onKeyPress: (a) => i(),
|
|
957
991
|
...e.BlocksWrapperProps,
|
|
958
992
|
children: e.children
|
|
959
993
|
}
|
|
960
994
|
),
|
|
961
|
-
/* @__PURE__ */
|
|
995
|
+
/* @__PURE__ */ l("style", { children: `.props-blocks-wrapper-51ef31b4 {
|
|
962
996
|
display: flex;
|
|
963
997
|
flex-direction: column;
|
|
964
998
|
align-items: stretch;
|
|
@@ -966,10 +1000,10 @@ function Wt(e) {
|
|
|
966
1000
|
] });
|
|
967
1001
|
}
|
|
968
1002
|
function D(e) {
|
|
969
|
-
var i, o,
|
|
970
|
-
const t = be(ue), n = be(
|
|
971
|
-
return /* @__PURE__ */
|
|
972
|
-
|
|
1003
|
+
var i, o, a;
|
|
1004
|
+
const t = be(ue), n = be(Ve);
|
|
1005
|
+
return /* @__PURE__ */ l(
|
|
1006
|
+
Ot,
|
|
973
1007
|
{
|
|
974
1008
|
blocks: e.blocks,
|
|
975
1009
|
parent: e.parent,
|
|
@@ -977,64 +1011,64 @@ function D(e) {
|
|
|
977
1011
|
styleProp: e.styleProp,
|
|
978
1012
|
BlocksWrapper: ((i = e.context) == null ? void 0 : i.BlocksWrapper) || t.BlocksWrapper,
|
|
979
1013
|
BlocksWrapperProps: ((o = e.context) == null ? void 0 : o.BlocksWrapperProps) || t.BlocksWrapperProps,
|
|
980
|
-
children: e.blocks ? /* @__PURE__ */
|
|
981
|
-
|
|
1014
|
+
children: e.blocks ? /* @__PURE__ */ l(E, { children: (a = e.blocks) == null ? void 0 : a.map((r) => /* @__PURE__ */ l(
|
|
1015
|
+
J,
|
|
982
1016
|
{
|
|
983
|
-
block:
|
|
1017
|
+
block: r,
|
|
984
1018
|
linkComponent: e.linkComponent,
|
|
985
1019
|
context: e.context || t,
|
|
986
1020
|
registeredComponents: e.registeredComponents || n.registeredComponents
|
|
987
1021
|
},
|
|
988
|
-
|
|
1022
|
+
r.id
|
|
989
1023
|
)) }) : null
|
|
990
1024
|
}
|
|
991
1025
|
);
|
|
992
1026
|
}
|
|
993
|
-
const
|
|
994
|
-
function
|
|
1027
|
+
const Ut = (e) => `builder-columns ${e}-breakpoints`;
|
|
1028
|
+
function Mt(e) {
|
|
995
1029
|
var A, O;
|
|
996
1030
|
const [t, n] = T(
|
|
997
1031
|
() => typeof e.space == "number" ? e.space || 0 : 20
|
|
998
|
-
), [i, o] = T(() => e.columns || []), [
|
|
1032
|
+
), [i, o] = T(() => e.columns || []), [a, r] = T(
|
|
999
1033
|
() => e.stackColumnsAt || "tablet"
|
|
1000
1034
|
);
|
|
1001
|
-
function
|
|
1002
|
-
return
|
|
1035
|
+
function s(v) {
|
|
1036
|
+
return v.link ? e.builderLinkComponent || "a" : "div";
|
|
1003
1037
|
}
|
|
1004
|
-
function
|
|
1005
|
-
var
|
|
1006
|
-
return ((
|
|
1038
|
+
function d(v) {
|
|
1039
|
+
var R;
|
|
1040
|
+
return ((R = i[v]) == null ? void 0 : R.width) || 100 / i.length;
|
|
1007
1041
|
}
|
|
1008
|
-
function
|
|
1009
|
-
const
|
|
1010
|
-
return `calc(${
|
|
1042
|
+
function c(v) {
|
|
1043
|
+
const R = d(v), N = t * (i.length - 1) * (R / 100);
|
|
1044
|
+
return `calc(${R}% - ${N}px)`;
|
|
1011
1045
|
}
|
|
1012
|
-
function
|
|
1013
|
-
stackedStyle:
|
|
1014
|
-
desktopStyle:
|
|
1046
|
+
function u({
|
|
1047
|
+
stackedStyle: v,
|
|
1048
|
+
desktopStyle: R
|
|
1015
1049
|
}) {
|
|
1016
|
-
return
|
|
1050
|
+
return a === "tablet" ? v : R;
|
|
1017
1051
|
}
|
|
1018
|
-
function
|
|
1019
|
-
stackedStyle:
|
|
1020
|
-
desktopStyle:
|
|
1052
|
+
function g({
|
|
1053
|
+
stackedStyle: v,
|
|
1054
|
+
desktopStyle: R
|
|
1021
1055
|
}) {
|
|
1022
|
-
return
|
|
1056
|
+
return a === "never" ? R : v;
|
|
1023
1057
|
}
|
|
1024
|
-
const [m,
|
|
1058
|
+
const [m, x] = T(
|
|
1025
1059
|
() => e.stackColumnsAt === "never" ? "row" : e.reverseColumnsWhenStacked ? "column-reverse" : "column"
|
|
1026
1060
|
);
|
|
1027
|
-
function
|
|
1061
|
+
function h() {
|
|
1028
1062
|
return {
|
|
1029
1063
|
"--flex-dir": m,
|
|
1030
|
-
"--flex-dir-tablet":
|
|
1064
|
+
"--flex-dir-tablet": u({
|
|
1031
1065
|
stackedStyle: m,
|
|
1032
1066
|
desktopStyle: "row"
|
|
1033
1067
|
})
|
|
1034
1068
|
};
|
|
1035
1069
|
}
|
|
1036
|
-
function
|
|
1037
|
-
const
|
|
1070
|
+
function p(v) {
|
|
1071
|
+
const R = v === 0 ? 0 : t, N = c(v), y = `${R}px`, b = "100%", S = 0;
|
|
1038
1072
|
return {
|
|
1039
1073
|
...{
|
|
1040
1074
|
display: "flex",
|
|
@@ -1042,93 +1076,93 @@ function $t(e) {
|
|
|
1042
1076
|
alignItems: "stretch"
|
|
1043
1077
|
},
|
|
1044
1078
|
width: N,
|
|
1045
|
-
["marginLeft"]:
|
|
1046
|
-
"--column-width-mobile":
|
|
1047
|
-
stackedStyle:
|
|
1079
|
+
["marginLeft"]: y,
|
|
1080
|
+
"--column-width-mobile": g({
|
|
1081
|
+
stackedStyle: b,
|
|
1048
1082
|
desktopStyle: N
|
|
1049
1083
|
}),
|
|
1050
|
-
"--column-margin-left-mobile":
|
|
1051
|
-
stackedStyle:
|
|
1052
|
-
desktopStyle:
|
|
1084
|
+
"--column-margin-left-mobile": g({
|
|
1085
|
+
stackedStyle: S,
|
|
1086
|
+
desktopStyle: y
|
|
1053
1087
|
}),
|
|
1054
|
-
"--column-width-tablet":
|
|
1055
|
-
stackedStyle:
|
|
1088
|
+
"--column-width-tablet": u({
|
|
1089
|
+
stackedStyle: b,
|
|
1056
1090
|
desktopStyle: N
|
|
1057
1091
|
}),
|
|
1058
|
-
"--column-margin-left-tablet":
|
|
1059
|
-
stackedStyle:
|
|
1060
|
-
desktopStyle:
|
|
1092
|
+
"--column-margin-left-tablet": u({
|
|
1093
|
+
stackedStyle: S,
|
|
1094
|
+
desktopStyle: y
|
|
1061
1095
|
})
|
|
1062
1096
|
};
|
|
1063
1097
|
}
|
|
1064
|
-
function
|
|
1065
|
-
var N,
|
|
1066
|
-
return
|
|
1067
|
-
((
|
|
1068
|
-
)[
|
|
1098
|
+
function f(v) {
|
|
1099
|
+
var N, y;
|
|
1100
|
+
return Ue(
|
|
1101
|
+
((y = (N = e.builderContext.content) == null ? void 0 : N.meta) == null ? void 0 : y.breakpoints) || {}
|
|
1102
|
+
)[v].max;
|
|
1069
1103
|
}
|
|
1070
|
-
function
|
|
1071
|
-
const
|
|
1104
|
+
function w() {
|
|
1105
|
+
const v = `.${e.builderBlock.id}-breakpoints > .builder-column`;
|
|
1072
1106
|
return `
|
|
1073
|
-
@media (max-width: ${
|
|
1107
|
+
@media (max-width: ${f("medium")}px) {
|
|
1074
1108
|
.${e.builderBlock.id}-breakpoints {
|
|
1075
1109
|
flex-direction: var(--flex-dir-tablet);
|
|
1076
1110
|
align-items: stretch;
|
|
1077
1111
|
}
|
|
1078
1112
|
|
|
1079
|
-
${
|
|
1113
|
+
${v} {
|
|
1080
1114
|
width: var(--column-width-tablet) !important;
|
|
1081
1115
|
margin-left: var(--column-margin-left-tablet) !important;
|
|
1082
1116
|
}
|
|
1083
1117
|
}
|
|
1084
1118
|
|
|
1085
|
-
@media (max-width: ${
|
|
1119
|
+
@media (max-width: ${f("small")}px) {
|
|
1086
1120
|
.${e.builderBlock.id}-breakpoints {
|
|
1087
1121
|
flex-direction: var(--flex-dir);
|
|
1088
1122
|
align-items: stretch;
|
|
1089
1123
|
}
|
|
1090
1124
|
|
|
1091
|
-
${
|
|
1125
|
+
${v} {
|
|
1092
1126
|
width: var(--column-width-mobile) !important;
|
|
1093
1127
|
margin-left: var(--column-margin-left-mobile) !important;
|
|
1094
1128
|
}
|
|
1095
1129
|
},
|
|
1096
1130
|
`;
|
|
1097
1131
|
}
|
|
1098
|
-
function
|
|
1132
|
+
function B(v, R) {
|
|
1099
1133
|
return {
|
|
1100
|
-
...
|
|
1101
|
-
href:
|
|
1134
|
+
...v.link ? {
|
|
1135
|
+
href: v.link
|
|
1102
1136
|
} : {},
|
|
1103
|
-
[
|
|
1104
|
-
style:
|
|
1137
|
+
[_()]: "builder-column",
|
|
1138
|
+
style: Le(p(R))
|
|
1105
1139
|
};
|
|
1106
1140
|
}
|
|
1107
|
-
return /* @__PURE__ */ V(
|
|
1141
|
+
return /* @__PURE__ */ V(E, { children: [
|
|
1108
1142
|
/* @__PURE__ */ V(
|
|
1109
1143
|
"div",
|
|
1110
1144
|
{
|
|
1111
|
-
className:
|
|
1112
|
-
style:
|
|
1145
|
+
className: Ut((A = e.builderBlock) == null ? void 0 : A.id) + " div-34f576bb",
|
|
1146
|
+
style: h(),
|
|
1113
1147
|
children: [
|
|
1114
|
-
/* @__PURE__ */
|
|
1115
|
-
|
|
1148
|
+
/* @__PURE__ */ l(
|
|
1149
|
+
te,
|
|
1116
1150
|
{
|
|
1117
1151
|
id: "builderio-columns",
|
|
1118
|
-
styles:
|
|
1152
|
+
styles: w(),
|
|
1119
1153
|
nonce: e.builderContext.nonce
|
|
1120
1154
|
}
|
|
1121
1155
|
),
|
|
1122
|
-
(O = e.columns) == null ? void 0 : O.map((
|
|
1156
|
+
(O = e.columns) == null ? void 0 : O.map((v, R) => /* @__PURE__ */ l(
|
|
1123
1157
|
de,
|
|
1124
1158
|
{
|
|
1125
|
-
TagName:
|
|
1159
|
+
TagName: s(v),
|
|
1126
1160
|
actionAttributes: {},
|
|
1127
|
-
attributes:
|
|
1128
|
-
children: /* @__PURE__ */
|
|
1161
|
+
attributes: B(v, R),
|
|
1162
|
+
children: /* @__PURE__ */ l(
|
|
1129
1163
|
D,
|
|
1130
1164
|
{
|
|
1131
|
-
path: `component.options.columns.${
|
|
1165
|
+
path: `component.options.columns.${R}.blocks`,
|
|
1132
1166
|
parent: e.builderBlock.id,
|
|
1133
1167
|
styleProp: {
|
|
1134
1168
|
flexGrow: "1"
|
|
@@ -1136,92 +1170,92 @@ function $t(e) {
|
|
|
1136
1170
|
context: e.builderContext,
|
|
1137
1171
|
registeredComponents: e.builderComponents,
|
|
1138
1172
|
linkComponent: e.builderLinkComponent,
|
|
1139
|
-
blocks:
|
|
1173
|
+
blocks: v.blocks
|
|
1140
1174
|
}
|
|
1141
1175
|
)
|
|
1142
1176
|
},
|
|
1143
|
-
|
|
1177
|
+
R
|
|
1144
1178
|
))
|
|
1145
1179
|
]
|
|
1146
1180
|
}
|
|
1147
1181
|
),
|
|
1148
|
-
/* @__PURE__ */
|
|
1182
|
+
/* @__PURE__ */ l("style", { children: `.div-34f576bb {
|
|
1149
1183
|
display: flex;
|
|
1150
1184
|
line-height: normal;
|
|
1151
1185
|
}` })
|
|
1152
1186
|
] });
|
|
1153
1187
|
}
|
|
1154
|
-
function
|
|
1155
|
-
return /* @__PURE__ */
|
|
1188
|
+
function jt(e) {
|
|
1189
|
+
return /* @__PURE__ */ l("span", { children: e.children });
|
|
1156
1190
|
}
|
|
1157
|
-
function
|
|
1191
|
+
function Se(e) {
|
|
1158
1192
|
return e.replace(/http(s)?:/, "");
|
|
1159
1193
|
}
|
|
1160
|
-
function
|
|
1194
|
+
function Ht(e = "", t, n) {
|
|
1161
1195
|
const i = new RegExp("([?&])" + t + "=.*?(&|$)", "i"), o = e.indexOf("?") !== -1 ? "&" : "?";
|
|
1162
1196
|
return e.match(i) ? e.replace(i, "$1" + t + "=" + encodeURIComponent(n) + "$2") : e + o + t + "=" + encodeURIComponent(n);
|
|
1163
1197
|
}
|
|
1164
|
-
function
|
|
1198
|
+
function Kt(e, t) {
|
|
1165
1199
|
if (!e || !(e != null && e.match(/cdn\.shopify\.com/)) || !t)
|
|
1166
1200
|
return e;
|
|
1167
1201
|
if (t === "master")
|
|
1168
|
-
return
|
|
1202
|
+
return Se(e);
|
|
1169
1203
|
const n = e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);
|
|
1170
1204
|
if (n) {
|
|
1171
|
-
const i = e.split(n[0]), o = n[3],
|
|
1172
|
-
return
|
|
1205
|
+
const i = e.split(n[0]), o = n[3], a = t.match("x") ? t : `${t}x`;
|
|
1206
|
+
return Se(`${i[0]}_${a}${o}`);
|
|
1173
1207
|
}
|
|
1174
1208
|
return null;
|
|
1175
1209
|
}
|
|
1176
|
-
function
|
|
1210
|
+
function ie(e) {
|
|
1177
1211
|
if (!e)
|
|
1178
1212
|
return e;
|
|
1179
1213
|
const t = [100, 200, 400, 800, 1200, 1600, 2e3];
|
|
1180
1214
|
if (e.match(/builder\.io/)) {
|
|
1181
1215
|
let n = e;
|
|
1182
1216
|
const i = Number(e.split("?width=")[1]);
|
|
1183
|
-
return isNaN(i) || (n = `${n} ${i}w`), t.filter((o) => o !== i).map((o) => `${
|
|
1217
|
+
return isNaN(i) || (n = `${n} ${i}w`), t.filter((o) => o !== i).map((o) => `${Ht(e, "width", o)} ${o}w`).concat([n]).join(", ");
|
|
1184
1218
|
}
|
|
1185
|
-
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [
|
|
1219
|
+
return e.match(/cdn\.shopify\.com/) ? t.map((n) => [Kt(e, `${n}x${n}`), n]).filter(([n]) => !!n).map(([n, i]) => `${n} ${i}w`).concat([e]).join(", ") : e;
|
|
1186
1220
|
}
|
|
1187
|
-
function
|
|
1188
|
-
var o, r,
|
|
1221
|
+
function qt(e) {
|
|
1222
|
+
var o, a, r, s, d, c;
|
|
1189
1223
|
function t() {
|
|
1190
1224
|
var m;
|
|
1191
|
-
const
|
|
1192
|
-
if (!
|
|
1225
|
+
const g = e.image || e.src;
|
|
1226
|
+
if (!g || // We can auto add srcset for cdn.builder.io and shopify
|
|
1193
1227
|
// images, otherwise you can supply this prop manually
|
|
1194
|
-
!(
|
|
1228
|
+
!(g.match(/builder\.io/) || g.match(/cdn\.shopify\.com/)))
|
|
1195
1229
|
return e.srcset;
|
|
1196
1230
|
if (!e.noWebp) {
|
|
1197
1231
|
if (e.srcset && ((m = e.image) != null && m.includes("builder.io/api/v1/image"))) {
|
|
1198
1232
|
if (!e.srcset.includes(e.image.split("?")[0]))
|
|
1199
|
-
return console.debug("Removed given srcset"),
|
|
1233
|
+
return console.debug("Removed given srcset"), ie(g);
|
|
1200
1234
|
} else if (e.image && !e.srcset)
|
|
1201
|
-
return
|
|
1202
|
-
return
|
|
1235
|
+
return ie(g);
|
|
1236
|
+
return ie(g);
|
|
1203
1237
|
}
|
|
1204
1238
|
}
|
|
1205
1239
|
function n() {
|
|
1206
|
-
var
|
|
1207
|
-
return (
|
|
1240
|
+
var u;
|
|
1241
|
+
return (u = t == null ? void 0 : t()) != null && u.match(/builder\.io/) && !e.noWebp ? t().replace(/\?/g, "?format=webp&") : "";
|
|
1208
1242
|
}
|
|
1209
1243
|
function i() {
|
|
1210
|
-
const
|
|
1244
|
+
const u = {
|
|
1211
1245
|
position: "absolute",
|
|
1212
1246
|
height: "100%",
|
|
1213
1247
|
width: "100%",
|
|
1214
1248
|
left: "0px",
|
|
1215
1249
|
top: "0px"
|
|
1216
1250
|
};
|
|
1217
|
-
return e.aspectRatio ?
|
|
1251
|
+
return e.aspectRatio ? u : void 0;
|
|
1218
1252
|
}
|
|
1219
1253
|
return P(() => {
|
|
1220
|
-
}, []), /* @__PURE__ */ V(
|
|
1221
|
-
/* @__PURE__ */ V(
|
|
1254
|
+
}, []), /* @__PURE__ */ V(E, { children: [
|
|
1255
|
+
/* @__PURE__ */ V(E, { children: [
|
|
1222
1256
|
/* @__PURE__ */ V("picture", { children: [
|
|
1223
|
-
n() ? /* @__PURE__ */
|
|
1224
|
-
/* @__PURE__ */
|
|
1257
|
+
n() ? /* @__PURE__ */ l("source", { type: "image/webp", srcSet: n() }) : null,
|
|
1258
|
+
/* @__PURE__ */ l(
|
|
1225
1259
|
"img",
|
|
1226
1260
|
{
|
|
1227
1261
|
loading: e.highPriority ? "eager" : "lazy",
|
|
@@ -1240,7 +1274,7 @@ function jt(e) {
|
|
|
1240
1274
|
}
|
|
1241
1275
|
)
|
|
1242
1276
|
] }),
|
|
1243
|
-
e.aspectRatio && !((
|
|
1277
|
+
e.aspectRatio && !((a = (o = e.builderBlock) == null ? void 0 : o.children) != null && a.length && e.fitContent) ? /* @__PURE__ */ l(
|
|
1244
1278
|
"div",
|
|
1245
1279
|
{
|
|
1246
1280
|
className: "builder-image-sizer div-2d6925f2",
|
|
@@ -1249,10 +1283,10 @@ function jt(e) {
|
|
|
1249
1283
|
}
|
|
1250
1284
|
}
|
|
1251
1285
|
) : null,
|
|
1252
|
-
(
|
|
1253
|
-
!e.fitContent && ((
|
|
1286
|
+
(s = (r = e.builderBlock) == null ? void 0 : r.children) != null && s.length && e.fitContent ? /* @__PURE__ */ l(E, { children: e.children }) : null,
|
|
1287
|
+
!e.fitContent && ((c = (d = e.builderBlock) == null ? void 0 : d.children) != null && c.length) ? /* @__PURE__ */ l("div", { className: "div-2d6925f2-2", children: e.children }) : null
|
|
1254
1288
|
] }),
|
|
1255
|
-
/* @__PURE__ */
|
|
1289
|
+
/* @__PURE__ */ l("style", { children: `.img-2d6925f2 {
|
|
1256
1290
|
opacity: 1;
|
|
1257
1291
|
transition: opacity 0.2s ease-in-out;
|
|
1258
1292
|
}.div-2d6925f2 {
|
|
@@ -1271,8 +1305,8 @@ function jt(e) {
|
|
|
1271
1305
|
}` })
|
|
1272
1306
|
] });
|
|
1273
1307
|
}
|
|
1274
|
-
function
|
|
1275
|
-
return /* @__PURE__ */
|
|
1308
|
+
function _t(e) {
|
|
1309
|
+
return /* @__PURE__ */ l(
|
|
1276
1310
|
"section",
|
|
1277
1311
|
{
|
|
1278
1312
|
...e.attributes,
|
|
@@ -1292,7 +1326,7 @@ function Ut(e) {
|
|
|
1292
1326
|
}
|
|
1293
1327
|
);
|
|
1294
1328
|
}
|
|
1295
|
-
const
|
|
1329
|
+
const oe = {
|
|
1296
1330
|
"@type": "@builder.io/sdk:Element",
|
|
1297
1331
|
layerName: "Accordion item title",
|
|
1298
1332
|
responsiveStyles: {
|
|
@@ -1321,7 +1355,7 @@ const ae = {
|
|
|
1321
1355
|
}
|
|
1322
1356
|
}
|
|
1323
1357
|
}]
|
|
1324
|
-
},
|
|
1358
|
+
}, ae = {
|
|
1325
1359
|
"@type": "@builder.io/sdk:Element",
|
|
1326
1360
|
layerName: "Accordion item detail",
|
|
1327
1361
|
responsiveStyles: {
|
|
@@ -1352,7 +1386,7 @@ const ae = {
|
|
|
1352
1386
|
}
|
|
1353
1387
|
}
|
|
1354
1388
|
}]
|
|
1355
|
-
},
|
|
1389
|
+
}, zt = {
|
|
1356
1390
|
name: "Builder:Accordion",
|
|
1357
1391
|
canHaveChildren: !0,
|
|
1358
1392
|
image: "https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",
|
|
@@ -1369,19 +1403,19 @@ const ae = {
|
|
|
1369
1403
|
name: "title",
|
|
1370
1404
|
type: "uiBlocks",
|
|
1371
1405
|
hideFromUI: !0,
|
|
1372
|
-
defaultValue: [
|
|
1406
|
+
defaultValue: [oe]
|
|
1373
1407
|
}, {
|
|
1374
1408
|
name: "detail",
|
|
1375
1409
|
type: "uiBlocks",
|
|
1376
1410
|
hideFromUI: !0,
|
|
1377
|
-
defaultValue: [
|
|
1411
|
+
defaultValue: [ae]
|
|
1378
1412
|
}],
|
|
1379
1413
|
defaultValue: [{
|
|
1380
|
-
title: [
|
|
1381
|
-
detail: [
|
|
1414
|
+
title: [oe],
|
|
1415
|
+
detail: [ae]
|
|
1382
1416
|
}, {
|
|
1383
|
-
title: [
|
|
1384
|
-
detail: [
|
|
1417
|
+
title: [oe],
|
|
1418
|
+
detail: [ae]
|
|
1385
1419
|
}],
|
|
1386
1420
|
showIf: (e) => !e.get("useChildrenForItems")
|
|
1387
1421
|
}, {
|
|
@@ -1416,9 +1450,9 @@ const ae = {
|
|
|
1416
1450
|
builderComponents: !0,
|
|
1417
1451
|
builderLinkComponent: !0
|
|
1418
1452
|
}
|
|
1419
|
-
},
|
|
1420
|
-
function
|
|
1421
|
-
var
|
|
1453
|
+
}, ke = (e) => e.toString();
|
|
1454
|
+
function Jt(e) {
|
|
1455
|
+
var g;
|
|
1422
1456
|
const [t, n] = T(() => []);
|
|
1423
1457
|
function i() {
|
|
1424
1458
|
return !!(e.grid || e.oneAtATime);
|
|
@@ -1435,8 +1469,8 @@ function Ht(e) {
|
|
|
1435
1469
|
}
|
|
1436
1470
|
};
|
|
1437
1471
|
}
|
|
1438
|
-
function
|
|
1439
|
-
const
|
|
1472
|
+
function a() {
|
|
1473
|
+
const x = {
|
|
1440
1474
|
...{
|
|
1441
1475
|
display: "flex",
|
|
1442
1476
|
flexDirection: "column"
|
|
@@ -1445,35 +1479,35 @@ function Ht(e) {
|
|
|
1445
1479
|
cursor: "pointer"
|
|
1446
1480
|
};
|
|
1447
1481
|
return Object.fromEntries(
|
|
1448
|
-
Object.entries(
|
|
1482
|
+
Object.entries(x).filter(([h, p]) => p !== void 0)
|
|
1449
1483
|
);
|
|
1450
1484
|
}
|
|
1451
|
-
function
|
|
1485
|
+
function r(m) {
|
|
1452
1486
|
return `builder-accordion-title builder-accordion-title-${t.includes(m) ? "open" : "closed"}`;
|
|
1453
1487
|
}
|
|
1454
|
-
function
|
|
1488
|
+
function s(m) {
|
|
1455
1489
|
return `builder-accordion-detail builder-accordion-detail-${t.includes(m) ? "open" : "closed"}`;
|
|
1456
1490
|
}
|
|
1457
|
-
function
|
|
1491
|
+
function d() {
|
|
1458
1492
|
let m = null;
|
|
1459
1493
|
if (e.grid && t.length && document) {
|
|
1460
|
-
const
|
|
1461
|
-
let
|
|
1462
|
-
`.builder-accordion-title[data-index="${
|
|
1494
|
+
const h = t[0];
|
|
1495
|
+
let f = document.querySelector(
|
|
1496
|
+
`.builder-accordion-title[data-index="${h}"]`
|
|
1463
1497
|
);
|
|
1464
|
-
if (m =
|
|
1465
|
-
let
|
|
1466
|
-
for (;
|
|
1467
|
-
if (
|
|
1468
|
-
if (
|
|
1498
|
+
if (m = h, f) {
|
|
1499
|
+
let w = f.getBoundingClientRect();
|
|
1500
|
+
for (; f = f && f.nextElementSibling; )
|
|
1501
|
+
if (f) {
|
|
1502
|
+
if (f.classList.contains("builder-accordion-detail"))
|
|
1469
1503
|
continue;
|
|
1470
|
-
const
|
|
1471
|
-
if (
|
|
1504
|
+
const B = f.getBoundingClientRect();
|
|
1505
|
+
if (B.left > w.left) {
|
|
1472
1506
|
const A = parseInt(
|
|
1473
|
-
|
|
1507
|
+
f.getAttribute("data-index") || "",
|
|
1474
1508
|
10
|
|
1475
1509
|
);
|
|
1476
|
-
isNaN(A) || (
|
|
1510
|
+
isNaN(A) || (w = B, m = A);
|
|
1477
1511
|
} else
|
|
1478
1512
|
break;
|
|
1479
1513
|
}
|
|
@@ -1481,37 +1515,37 @@ function Ht(e) {
|
|
|
1481
1515
|
}
|
|
1482
1516
|
return typeof m == "number" && (m = m + 1), m;
|
|
1483
1517
|
}
|
|
1484
|
-
function
|
|
1518
|
+
function c() {
|
|
1485
1519
|
const m = {
|
|
1486
|
-
order: typeof
|
|
1520
|
+
order: typeof d() == "number" ? d() : void 0,
|
|
1487
1521
|
...e.grid && {
|
|
1488
1522
|
width: "100%"
|
|
1489
1523
|
}
|
|
1490
1524
|
};
|
|
1491
1525
|
return Object.fromEntries(
|
|
1492
|
-
Object.entries(m).filter(([
|
|
1526
|
+
Object.entries(m).filter(([x, h]) => h !== void 0)
|
|
1493
1527
|
);
|
|
1494
1528
|
}
|
|
1495
|
-
function
|
|
1496
|
-
t.includes(m) ? n(i() ? [] : t.filter((
|
|
1529
|
+
function u(m) {
|
|
1530
|
+
t.includes(m) ? n(i() ? [] : t.filter((x) => x !== m)) : n(i() ? [m] : t.concat(m));
|
|
1497
1531
|
}
|
|
1498
|
-
return /* @__PURE__ */
|
|
1499
|
-
/* @__PURE__ */
|
|
1532
|
+
return /* @__PURE__ */ l("div", { className: "builder-accordion", style: o(), children: (g = e.items) == null ? void 0 : g.map((m, x) => /* @__PURE__ */ V(E, { children: [
|
|
1533
|
+
/* @__PURE__ */ l(
|
|
1500
1534
|
"div",
|
|
1501
1535
|
{
|
|
1502
|
-
className:
|
|
1536
|
+
className: r(x),
|
|
1503
1537
|
style: {
|
|
1504
|
-
...
|
|
1538
|
+
...a(),
|
|
1505
1539
|
width: e.grid ? e.gridRowWidth : void 0,
|
|
1506
|
-
order:
|
|
1540
|
+
order: d() !== null ? ke(x) : ke(x + 1)
|
|
1507
1541
|
},
|
|
1508
|
-
"data-index":
|
|
1509
|
-
onClick: (
|
|
1510
|
-
children: /* @__PURE__ */
|
|
1542
|
+
"data-index": x,
|
|
1543
|
+
onClick: (h) => u(x),
|
|
1544
|
+
children: /* @__PURE__ */ l(
|
|
1511
1545
|
D,
|
|
1512
1546
|
{
|
|
1513
1547
|
blocks: m.title,
|
|
1514
|
-
path: `items.${
|
|
1548
|
+
path: `items.${x}.title`,
|
|
1515
1549
|
parent: e.builderBlock.id,
|
|
1516
1550
|
context: e.builderContext,
|
|
1517
1551
|
registeredComponents: e.builderComponents,
|
|
@@ -1520,16 +1554,16 @@ function Ht(e) {
|
|
|
1520
1554
|
)
|
|
1521
1555
|
}
|
|
1522
1556
|
),
|
|
1523
|
-
t.includes(
|
|
1557
|
+
t.includes(x) ? /* @__PURE__ */ l(
|
|
1524
1558
|
"div",
|
|
1525
1559
|
{
|
|
1526
|
-
className:
|
|
1527
|
-
style:
|
|
1528
|
-
children: /* @__PURE__ */
|
|
1560
|
+
className: s(x),
|
|
1561
|
+
style: c(),
|
|
1562
|
+
children: /* @__PURE__ */ l(
|
|
1529
1563
|
D,
|
|
1530
1564
|
{
|
|
1531
1565
|
blocks: m.detail,
|
|
1532
|
-
path: `items.${
|
|
1566
|
+
path: `items.${x}.detail`,
|
|
1533
1567
|
parent: e.builderBlock.id,
|
|
1534
1568
|
context: e.builderContext,
|
|
1535
1569
|
registeredComponents: e.builderComponents,
|
|
@@ -1540,7 +1574,7 @@ function Ht(e) {
|
|
|
1540
1574
|
) : null
|
|
1541
1575
|
] })) });
|
|
1542
1576
|
}
|
|
1543
|
-
const
|
|
1577
|
+
const Yt = {
|
|
1544
1578
|
name: "Core:Button",
|
|
1545
1579
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
1546
1580
|
defaultStyles: {
|
|
@@ -1576,7 +1610,7 @@ const qt = {
|
|
|
1576
1610
|
shouldReceiveBuilderProps: {
|
|
1577
1611
|
builderLinkComponent: !0
|
|
1578
1612
|
}
|
|
1579
|
-
},
|
|
1613
|
+
}, Gt = {
|
|
1580
1614
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
1581
1615
|
name: "Columns",
|
|
1582
1616
|
isRSC: !0,
|
|
@@ -1755,7 +1789,7 @@ const qt = {
|
|
|
1755
1789
|
});
|
|
1756
1790
|
}
|
|
1757
1791
|
const n = e.get("columns");
|
|
1758
|
-
Array.isArray(n) && n.find((o) => o.get("width")) && (n.find((
|
|
1792
|
+
Array.isArray(n) && n.find((o) => o.get("width")) && (n.find((a) => !a.get("width")) || n.reduce((s, d) => s + d.get("width"), 0) !== 100) && t();
|
|
1759
1793
|
}
|
|
1760
1794
|
}, {
|
|
1761
1795
|
name: "space",
|
|
@@ -1783,13 +1817,13 @@ const qt = {
|
|
|
1783
1817
|
builderComponents: !0,
|
|
1784
1818
|
builderLinkComponent: !0
|
|
1785
1819
|
}
|
|
1786
|
-
},
|
|
1820
|
+
}, Qt = {
|
|
1787
1821
|
name: "Fragment",
|
|
1788
1822
|
static: !0,
|
|
1789
1823
|
hidden: !0,
|
|
1790
1824
|
canHaveChildren: !0,
|
|
1791
1825
|
noWrap: !0
|
|
1792
|
-
},
|
|
1826
|
+
}, Xt = {
|
|
1793
1827
|
name: "Image",
|
|
1794
1828
|
static: !0,
|
|
1795
1829
|
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",
|
|
@@ -1809,29 +1843,29 @@ const qt = {
|
|
|
1809
1843
|
defaultValue: "https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",
|
|
1810
1844
|
onChange: (e) => {
|
|
1811
1845
|
e.delete("srcset"), e.delete("noWebp");
|
|
1812
|
-
function n(
|
|
1813
|
-
return new Promise((
|
|
1814
|
-
const
|
|
1815
|
-
let
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
},
|
|
1819
|
-
console.warn("Image load failed", m.error),
|
|
1820
|
-
}),
|
|
1821
|
-
|
|
1822
|
-
},
|
|
1846
|
+
function n(r, s = 6e4) {
|
|
1847
|
+
return new Promise((d, c) => {
|
|
1848
|
+
const u = document.createElement("img");
|
|
1849
|
+
let g = !1;
|
|
1850
|
+
u.onload = () => {
|
|
1851
|
+
g = !0, d(u);
|
|
1852
|
+
}, u.addEventListener("error", (m) => {
|
|
1853
|
+
console.warn("Image load failed", m.error), c(m.error);
|
|
1854
|
+
}), u.src = r, setTimeout(() => {
|
|
1855
|
+
g || c(new Error("Image load timed out"));
|
|
1856
|
+
}, s);
|
|
1823
1857
|
});
|
|
1824
1858
|
}
|
|
1825
|
-
function i(
|
|
1826
|
-
return Math.round(
|
|
1859
|
+
function i(r) {
|
|
1860
|
+
return Math.round(r * 1e3) / 1e3;
|
|
1827
1861
|
}
|
|
1828
|
-
const o = e.get("image"),
|
|
1829
|
-
if (fetch(o).then((
|
|
1830
|
-
|
|
1831
|
-
}), o && (!
|
|
1832
|
-
return n(o).then((
|
|
1833
|
-
const
|
|
1834
|
-
e.get("image") === o && (!
|
|
1862
|
+
const o = e.get("image"), a = e.get("aspectRatio");
|
|
1863
|
+
if (fetch(o).then((r) => r.blob()).then((r) => {
|
|
1864
|
+
r.type.includes("svg") && e.set("noWebp", !0);
|
|
1865
|
+
}), o && (!a || a === 0.7041))
|
|
1866
|
+
return n(o).then((r) => {
|
|
1867
|
+
const s = e.get("aspectRatio");
|
|
1868
|
+
e.get("image") === o && (!s || s === 0.7041) && r.width && r.height && (e.set("aspectRatio", i(r.height / r.width)), e.set("height", r.height), e.set("width", r.width));
|
|
1835
1869
|
});
|
|
1836
1870
|
}
|
|
1837
1871
|
}, {
|
|
@@ -1897,7 +1931,7 @@ const qt = {
|
|
|
1897
1931
|
shouldReceiveBuilderProps: {
|
|
1898
1932
|
builderBlock: !0
|
|
1899
1933
|
}
|
|
1900
|
-
},
|
|
1934
|
+
}, Zt = {
|
|
1901
1935
|
name: "Core:Section",
|
|
1902
1936
|
static: !0,
|
|
1903
1937
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
@@ -1936,7 +1970,7 @@ const qt = {
|
|
|
1936
1970
|
}
|
|
1937
1971
|
}
|
|
1938
1972
|
}]
|
|
1939
|
-
},
|
|
1973
|
+
}, en = {
|
|
1940
1974
|
name: "Slot",
|
|
1941
1975
|
isRSC: !0,
|
|
1942
1976
|
description: "Allow child blocks to be inserted into this content when used as a Symbol",
|
|
@@ -1950,12 +1984,13 @@ const qt = {
|
|
|
1950
1984
|
defaultValue: "children"
|
|
1951
1985
|
}],
|
|
1952
1986
|
shouldReceiveBuilderProps: {
|
|
1953
|
-
builderContext: !0
|
|
1987
|
+
builderContext: !0,
|
|
1988
|
+
builderComponents: !0
|
|
1954
1989
|
}
|
|
1955
1990
|
};
|
|
1956
|
-
function
|
|
1991
|
+
function tn(e) {
|
|
1957
1992
|
var t, n, i;
|
|
1958
|
-
return /* @__PURE__ */
|
|
1993
|
+
return /* @__PURE__ */ l(
|
|
1959
1994
|
"div",
|
|
1960
1995
|
{
|
|
1961
1996
|
style: {
|
|
@@ -1964,19 +1999,20 @@ function Gt(e) {
|
|
|
1964
1999
|
...!((t = e.builderContext.context) != null && t.symbolId) && {
|
|
1965
2000
|
"builder-slot": e.name
|
|
1966
2001
|
},
|
|
1967
|
-
children: /* @__PURE__ */
|
|
2002
|
+
children: /* @__PURE__ */ l(
|
|
1968
2003
|
D,
|
|
1969
2004
|
{
|
|
1970
2005
|
parent: (n = e.builderContext.context) == null ? void 0 : n.symbolId,
|
|
1971
2006
|
path: `symbol.data.${e.name}`,
|
|
1972
2007
|
context: e.builderContext,
|
|
2008
|
+
registeredComponents: e.builderComponents,
|
|
1973
2009
|
blocks: (i = e.builderContext.rootState) == null ? void 0 : i[e.name]
|
|
1974
2010
|
}
|
|
1975
2011
|
)
|
|
1976
2012
|
}
|
|
1977
2013
|
);
|
|
1978
2014
|
}
|
|
1979
|
-
const
|
|
2015
|
+
const nn = {
|
|
1980
2016
|
name: "Symbol",
|
|
1981
2017
|
noWrap: !0,
|
|
1982
2018
|
static: !0,
|
|
@@ -2015,7 +2051,7 @@ const Qt = {
|
|
|
2015
2051
|
builderComponents: !0,
|
|
2016
2052
|
builderLinkComponent: !0
|
|
2017
2053
|
}
|
|
2018
|
-
},
|
|
2054
|
+
}, re = {
|
|
2019
2055
|
"@type": "@builder.io/sdk:Element",
|
|
2020
2056
|
responsiveStyles: {
|
|
2021
2057
|
large: {
|
|
@@ -2037,7 +2073,7 @@ const Qt = {
|
|
|
2037
2073
|
text: "New tab"
|
|
2038
2074
|
}
|
|
2039
2075
|
}
|
|
2040
|
-
},
|
|
2076
|
+
}, le = {
|
|
2041
2077
|
"@type": "@builder.io/sdk:Element",
|
|
2042
2078
|
responsiveStyles: {
|
|
2043
2079
|
large: {
|
|
@@ -2053,7 +2089,7 @@ const Qt = {
|
|
|
2053
2089
|
text: "New tab content "
|
|
2054
2090
|
}
|
|
2055
2091
|
}
|
|
2056
|
-
},
|
|
2092
|
+
}, on = {
|
|
2057
2093
|
name: "Builder: Tabs",
|
|
2058
2094
|
inputs: [{
|
|
2059
2095
|
name: "tabs",
|
|
@@ -2063,16 +2099,16 @@ const Qt = {
|
|
|
2063
2099
|
name: "label",
|
|
2064
2100
|
type: "uiBlocks",
|
|
2065
2101
|
hideFromUI: !0,
|
|
2066
|
-
defaultValue: [
|
|
2102
|
+
defaultValue: [re]
|
|
2067
2103
|
}, {
|
|
2068
2104
|
name: "content",
|
|
2069
2105
|
type: "uiBlocks",
|
|
2070
2106
|
hideFromUI: !0,
|
|
2071
|
-
defaultValue: [
|
|
2107
|
+
defaultValue: [le]
|
|
2072
2108
|
}],
|
|
2073
2109
|
defaultValue: [{
|
|
2074
2110
|
label: [{
|
|
2075
|
-
...
|
|
2111
|
+
...re,
|
|
2076
2112
|
component: {
|
|
2077
2113
|
name: "Text",
|
|
2078
2114
|
options: {
|
|
@@ -2081,7 +2117,7 @@ const Qt = {
|
|
|
2081
2117
|
}
|
|
2082
2118
|
}],
|
|
2083
2119
|
content: [{
|
|
2084
|
-
...
|
|
2120
|
+
...le,
|
|
2085
2121
|
component: {
|
|
2086
2122
|
name: "Text",
|
|
2087
2123
|
options: {
|
|
@@ -2091,7 +2127,7 @@ const Qt = {
|
|
|
2091
2127
|
}]
|
|
2092
2128
|
}, {
|
|
2093
2129
|
label: [{
|
|
2094
|
-
...
|
|
2130
|
+
...re,
|
|
2095
2131
|
component: {
|
|
2096
2132
|
name: "Text",
|
|
2097
2133
|
options: {
|
|
@@ -2100,7 +2136,7 @@ const Qt = {
|
|
|
2100
2136
|
}
|
|
2101
2137
|
}],
|
|
2102
2138
|
content: [{
|
|
2103
|
-
...
|
|
2139
|
+
...le,
|
|
2104
2140
|
component: {
|
|
2105
2141
|
name: "Text",
|
|
2106
2142
|
options: {
|
|
@@ -2157,19 +2193,19 @@ const Qt = {
|
|
|
2157
2193
|
builderLinkComponent: !0
|
|
2158
2194
|
}
|
|
2159
2195
|
};
|
|
2160
|
-
function
|
|
2161
|
-
var
|
|
2196
|
+
function an(e) {
|
|
2197
|
+
var a;
|
|
2162
2198
|
const [t, n] = T(
|
|
2163
2199
|
() => e.defaultActiveTab ? e.defaultActiveTab - 1 : 0
|
|
2164
2200
|
);
|
|
2165
|
-
function i(
|
|
2166
|
-
return e.tabs && e.tabs[
|
|
2201
|
+
function i(r) {
|
|
2202
|
+
return e.tabs && e.tabs[r].content;
|
|
2167
2203
|
}
|
|
2168
|
-
function o(
|
|
2169
|
-
|
|
2204
|
+
function o(r) {
|
|
2205
|
+
r === t && e.collapsible ? n(-1) : n(r);
|
|
2170
2206
|
}
|
|
2171
2207
|
return /* @__PURE__ */ V("div", { children: [
|
|
2172
|
-
/* @__PURE__ */
|
|
2208
|
+
/* @__PURE__ */ l(
|
|
2173
2209
|
"div",
|
|
2174
2210
|
{
|
|
2175
2211
|
className: "builder-tabs-wrap",
|
|
@@ -2179,31 +2215,31 @@ function Zt(e) {
|
|
|
2179
2215
|
justifyContent: e.tabHeaderLayout || "flex-start",
|
|
2180
2216
|
overflow: "auto"
|
|
2181
2217
|
},
|
|
2182
|
-
children: (
|
|
2218
|
+
children: (a = e.tabs) == null ? void 0 : a.map((r, s) => /* @__PURE__ */ l(
|
|
2183
2219
|
"span",
|
|
2184
2220
|
{
|
|
2185
|
-
className: `builder-tab-wrap ${t ===
|
|
2221
|
+
className: `builder-tab-wrap ${t === s ? "builder-tab-active" : ""}`,
|
|
2186
2222
|
style: {
|
|
2187
|
-
...t ===
|
|
2223
|
+
...t === s ? e.activeTabStyle : {}
|
|
2188
2224
|
},
|
|
2189
|
-
onClick: (
|
|
2190
|
-
children: /* @__PURE__ */
|
|
2225
|
+
onClick: (d) => o(s),
|
|
2226
|
+
children: /* @__PURE__ */ l(
|
|
2191
2227
|
D,
|
|
2192
2228
|
{
|
|
2193
2229
|
parent: e.builderBlock.id,
|
|
2194
|
-
path: `component.options.tabs.${
|
|
2195
|
-
blocks:
|
|
2230
|
+
path: `component.options.tabs.${s}.label`,
|
|
2231
|
+
blocks: r.label,
|
|
2196
2232
|
context: e.builderContext,
|
|
2197
2233
|
registeredComponents: e.builderComponents,
|
|
2198
2234
|
linkComponent: e.builderLinkComponent
|
|
2199
2235
|
}
|
|
2200
2236
|
)
|
|
2201
2237
|
},
|
|
2202
|
-
|
|
2238
|
+
s
|
|
2203
2239
|
))
|
|
2204
2240
|
}
|
|
2205
2241
|
),
|
|
2206
|
-
i(t) ? /* @__PURE__ */
|
|
2242
|
+
i(t) ? /* @__PURE__ */ l("div", { children: /* @__PURE__ */ l(
|
|
2207
2243
|
D,
|
|
2208
2244
|
{
|
|
2209
2245
|
parent: e.builderBlock.id,
|
|
@@ -2216,7 +2252,7 @@ function Zt(e) {
|
|
|
2216
2252
|
) }) : null
|
|
2217
2253
|
] });
|
|
2218
2254
|
}
|
|
2219
|
-
const
|
|
2255
|
+
const rn = {
|
|
2220
2256
|
shouldReceiveBuilderProps: {
|
|
2221
2257
|
builderBlock: !1,
|
|
2222
2258
|
builderContext: !0
|
|
@@ -2239,28 +2275,28 @@ const en = {
|
|
|
2239
2275
|
textAlign: "center"
|
|
2240
2276
|
}
|
|
2241
2277
|
};
|
|
2242
|
-
function
|
|
2278
|
+
function ln(e) {
|
|
2243
2279
|
function t() {
|
|
2244
|
-
var
|
|
2280
|
+
var s;
|
|
2245
2281
|
const n = e.builderContext, {
|
|
2246
2282
|
context: i,
|
|
2247
2283
|
localState: o,
|
|
2248
|
-
rootState:
|
|
2249
|
-
rootSetState:
|
|
2284
|
+
rootState: a,
|
|
2285
|
+
rootSetState: r
|
|
2250
2286
|
} = n;
|
|
2251
|
-
return String(((
|
|
2287
|
+
return String(((s = e.text) == null ? void 0 : s.toString()) || "").replace(
|
|
2252
2288
|
/{{([^}]+)}}/g,
|
|
2253
|
-
(
|
|
2254
|
-
code:
|
|
2289
|
+
(d, c) => K({
|
|
2290
|
+
code: c,
|
|
2255
2291
|
context: i,
|
|
2256
2292
|
localState: o,
|
|
2257
|
-
rootState:
|
|
2258
|
-
rootSetState:
|
|
2293
|
+
rootState: a,
|
|
2294
|
+
rootSetState: r,
|
|
2259
2295
|
enableCache: !1
|
|
2260
2296
|
})
|
|
2261
2297
|
);
|
|
2262
2298
|
}
|
|
2263
|
-
return /* @__PURE__ */
|
|
2299
|
+
return /* @__PURE__ */ l(
|
|
2264
2300
|
"div",
|
|
2265
2301
|
{
|
|
2266
2302
|
className: "builder-text",
|
|
@@ -2271,7 +2307,7 @@ function tn(e) {
|
|
|
2271
2307
|
}
|
|
2272
2308
|
);
|
|
2273
2309
|
}
|
|
2274
|
-
const
|
|
2310
|
+
const sn = {
|
|
2275
2311
|
name: "Custom Code",
|
|
2276
2312
|
static: !0,
|
|
2277
2313
|
requiredPermissions: ["editCode"],
|
|
@@ -2294,36 +2330,36 @@ const nn = {
|
|
|
2294
2330
|
advanced: !0
|
|
2295
2331
|
}]
|
|
2296
2332
|
};
|
|
2297
|
-
function
|
|
2298
|
-
const t =
|
|
2333
|
+
function cn(e) {
|
|
2334
|
+
const t = z(null), [n, i] = T(() => []), [o, a] = T(() => []);
|
|
2299
2335
|
return P(() => {
|
|
2300
|
-
var
|
|
2301
|
-
if (!((
|
|
2336
|
+
var s;
|
|
2337
|
+
if (!((s = t.current) != null && s.getElementsByTagName) || typeof window == "undefined")
|
|
2302
2338
|
return;
|
|
2303
|
-
const
|
|
2304
|
-
for (let
|
|
2305
|
-
const
|
|
2306
|
-
if (
|
|
2307
|
-
if (n.includes(
|
|
2339
|
+
const r = t.current.getElementsByTagName("script");
|
|
2340
|
+
for (let d = 0; d < r.length; d++) {
|
|
2341
|
+
const c = r[d];
|
|
2342
|
+
if (c.src) {
|
|
2343
|
+
if (n.includes(c.src))
|
|
2308
2344
|
continue;
|
|
2309
|
-
n.push(
|
|
2310
|
-
const
|
|
2311
|
-
|
|
2312
|
-
} else if (!
|
|
2345
|
+
n.push(c.src);
|
|
2346
|
+
const u = document.createElement("script");
|
|
2347
|
+
u.async = !0, u.src = c.src, document.head.appendChild(u);
|
|
2348
|
+
} else if (!c.type || [
|
|
2313
2349
|
"text/javascript",
|
|
2314
2350
|
"application/javascript",
|
|
2315
2351
|
"application/ecmascript"
|
|
2316
|
-
].includes(
|
|
2317
|
-
if (o.includes(
|
|
2352
|
+
].includes(c.type)) {
|
|
2353
|
+
if (o.includes(c.innerText))
|
|
2318
2354
|
continue;
|
|
2319
2355
|
try {
|
|
2320
|
-
o.push(
|
|
2321
|
-
} catch (
|
|
2322
|
-
console.warn("`CustomCode`: Error running script:",
|
|
2356
|
+
o.push(c.innerText), new Function(c.innerText)();
|
|
2357
|
+
} catch (u) {
|
|
2358
|
+
console.warn("`CustomCode`: Error running script:", u);
|
|
2323
2359
|
}
|
|
2324
2360
|
}
|
|
2325
2361
|
}
|
|
2326
|
-
}, []), /* @__PURE__ */
|
|
2362
|
+
}, []), /* @__PURE__ */ l(
|
|
2327
2363
|
"div",
|
|
2328
2364
|
{
|
|
2329
2365
|
ref: t,
|
|
@@ -2332,7 +2368,7 @@ function on(e) {
|
|
|
2332
2368
|
}
|
|
2333
2369
|
);
|
|
2334
2370
|
}
|
|
2335
|
-
const
|
|
2371
|
+
const dn = {
|
|
2336
2372
|
name: "Embed",
|
|
2337
2373
|
static: !0,
|
|
2338
2374
|
inputs: [{
|
|
@@ -2347,30 +2383,30 @@ const an = {
|
|
|
2347
2383
|
defaultValue: '<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',
|
|
2348
2384
|
hideFromUI: !0
|
|
2349
2385
|
}]
|
|
2350
|
-
},
|
|
2351
|
-
function
|
|
2352
|
-
const t =
|
|
2353
|
-
function
|
|
2386
|
+
}, un = ["text/javascript", "application/javascript", "application/ecmascript"], mn = (e) => un.includes(e.type);
|
|
2387
|
+
function fn(e) {
|
|
2388
|
+
const t = z(null), [n, i] = T(() => []), [o, a] = T(() => []), [r, s] = T(() => !1);
|
|
2389
|
+
function d() {
|
|
2354
2390
|
if (!t.current || !t.current.getElementsByTagName)
|
|
2355
2391
|
return;
|
|
2356
|
-
const
|
|
2357
|
-
for (let
|
|
2358
|
-
const
|
|
2359
|
-
if (
|
|
2360
|
-
n.push(
|
|
2392
|
+
const c = t.current.getElementsByTagName("script");
|
|
2393
|
+
for (let u = 0; u < c.length; u++) {
|
|
2394
|
+
const g = c[u];
|
|
2395
|
+
if (g.src && !n.includes(g.src)) {
|
|
2396
|
+
n.push(g.src);
|
|
2361
2397
|
const m = document.createElement("script");
|
|
2362
|
-
m.async = !0, m.src =
|
|
2363
|
-
} else if (
|
|
2398
|
+
m.async = !0, m.src = g.src, document.head.appendChild(m);
|
|
2399
|
+
} else if (mn(g) && !o.includes(g.innerText))
|
|
2364
2400
|
try {
|
|
2365
|
-
o.push(
|
|
2401
|
+
o.push(g.innerText), new Function(g.innerText)();
|
|
2366
2402
|
} catch (m) {
|
|
2367
2403
|
console.warn("`Embed`: Error running script:", m);
|
|
2368
2404
|
}
|
|
2369
2405
|
}
|
|
2370
2406
|
}
|
|
2371
2407
|
return P(() => {
|
|
2372
|
-
t.current && !
|
|
2373
|
-
}, [t.current,
|
|
2408
|
+
t.current && !r && (s(!0), d());
|
|
2409
|
+
}, [t.current, r]), /* @__PURE__ */ l(
|
|
2374
2410
|
"div",
|
|
2375
2411
|
{
|
|
2376
2412
|
className: "builder-embed",
|
|
@@ -2379,7 +2415,7 @@ function sn(e) {
|
|
|
2379
2415
|
}
|
|
2380
2416
|
);
|
|
2381
2417
|
}
|
|
2382
|
-
const
|
|
2418
|
+
const hn = {
|
|
2383
2419
|
name: "Form:Form",
|
|
2384
2420
|
// editableTags: ['builder-form-error']
|
|
2385
2421
|
defaults: {
|
|
@@ -2616,123 +2652,123 @@ const cn = {
|
|
|
2616
2652
|
builderComponents: !0,
|
|
2617
2653
|
builderLinkComponent: !0
|
|
2618
2654
|
}
|
|
2619
|
-
},
|
|
2655
|
+
}, gn = ["production", "qa", "test", "development", "dev", "cdn-qa", "cloud", "fast", "cdn2", "cdn-prod"], bn = () => {
|
|
2620
2656
|
const e = process.env.NODE_ENV || "production";
|
|
2621
|
-
return
|
|
2622
|
-
},
|
|
2623
|
-
const i = String.prototype.split.call(t, /[,[\].]+?/).filter(Boolean).reduce((o,
|
|
2657
|
+
return gn.includes(e) ? e : "production";
|
|
2658
|
+
}, pn = (e, t, n) => {
|
|
2659
|
+
const i = String.prototype.split.call(t, /[,[\].]+?/).filter(Boolean).reduce((o, a) => o != null ? o[a] : o, e);
|
|
2624
2660
|
return i === void 0 || i === e ? n : i;
|
|
2625
2661
|
};
|
|
2626
|
-
function
|
|
2627
|
-
var
|
|
2628
|
-
const t =
|
|
2629
|
-
function
|
|
2630
|
-
var
|
|
2631
|
-
const
|
|
2662
|
+
function yn(e) {
|
|
2663
|
+
var g, m;
|
|
2664
|
+
const t = z(null), [n, i] = T(() => "unsubmitted"), [o, a] = T(() => null), [r, s] = T(() => "");
|
|
2665
|
+
function d(x) {
|
|
2666
|
+
var p, f;
|
|
2667
|
+
const h = {
|
|
2632
2668
|
...e.builderContext.rootState,
|
|
2633
|
-
...
|
|
2669
|
+
...x
|
|
2634
2670
|
};
|
|
2635
|
-
e.builderContext.rootSetState ? (
|
|
2671
|
+
e.builderContext.rootSetState ? (f = (p = e.builderContext).rootSetState) == null || f.call(p, h) : e.builderContext.rootState = h;
|
|
2636
2672
|
}
|
|
2637
|
-
function
|
|
2673
|
+
function c() {
|
|
2638
2674
|
return $() && e.previewState || n;
|
|
2639
2675
|
}
|
|
2640
|
-
function
|
|
2641
|
-
var
|
|
2642
|
-
const
|
|
2676
|
+
function u(x) {
|
|
2677
|
+
var p;
|
|
2678
|
+
const h = e.sendWithJs || e.sendSubmissionsTo === "email";
|
|
2643
2679
|
if (e.sendSubmissionsTo === "zapier")
|
|
2644
|
-
|
|
2645
|
-
else if (
|
|
2680
|
+
x.preventDefault();
|
|
2681
|
+
else if (h) {
|
|
2646
2682
|
if (!(e.action || e.sendSubmissionsTo === "email")) {
|
|
2647
|
-
|
|
2683
|
+
x.preventDefault();
|
|
2648
2684
|
return;
|
|
2649
2685
|
}
|
|
2650
|
-
|
|
2651
|
-
const
|
|
2652
|
-
let
|
|
2653
|
-
const A = new FormData(
|
|
2654
|
-
let
|
|
2655
|
-
const
|
|
2656
|
-
if (
|
|
2657
|
-
if (
|
|
2658
|
-
if (
|
|
2659
|
-
return
|
|
2660
|
-
key:
|
|
2661
|
-
value:
|
|
2686
|
+
x.preventDefault();
|
|
2687
|
+
const f = x.currentTarget || x.target, w = e.customHeaders || {};
|
|
2688
|
+
let B;
|
|
2689
|
+
const A = new FormData(f), O = Array.from(f.querySelectorAll("input,select,textarea")).filter((y) => !!y.name).map((y) => {
|
|
2690
|
+
let b;
|
|
2691
|
+
const S = y.name;
|
|
2692
|
+
if (y instanceof HTMLInputElement)
|
|
2693
|
+
if (y.type === "radio") {
|
|
2694
|
+
if (y.checked)
|
|
2695
|
+
return b = y.name, {
|
|
2696
|
+
key: S,
|
|
2697
|
+
value: b
|
|
2662
2698
|
};
|
|
2663
|
-
} else if (
|
|
2664
|
-
|
|
2665
|
-
else if (
|
|
2666
|
-
const
|
|
2667
|
-
isNaN(
|
|
2699
|
+
} else if (y.type === "checkbox")
|
|
2700
|
+
b = y.checked;
|
|
2701
|
+
else if (y.type === "number" || y.type === "range") {
|
|
2702
|
+
const k = y.valueAsNumber;
|
|
2703
|
+
isNaN(k) || (b = k);
|
|
2668
2704
|
} else
|
|
2669
|
-
|
|
2705
|
+
y.type === "file" ? b = y.files : b = y.value;
|
|
2670
2706
|
else
|
|
2671
|
-
|
|
2707
|
+
b = y.value;
|
|
2672
2708
|
return {
|
|
2673
|
-
key:
|
|
2674
|
-
value:
|
|
2709
|
+
key: S,
|
|
2710
|
+
value: b
|
|
2675
2711
|
};
|
|
2676
2712
|
});
|
|
2677
|
-
let
|
|
2678
|
-
if (e.sendSubmissionsTo === "email" && (
|
|
2679
|
-
(
|
|
2680
|
-
}),
|
|
2681
|
-
|
|
2713
|
+
let v = e.contentType;
|
|
2714
|
+
if (e.sendSubmissionsTo === "email" && (v = "multipart/form-data"), Array.from(O).forEach(({ value: y }) => {
|
|
2715
|
+
(y instanceof File || Array.isArray(y) && y[0] instanceof File || y instanceof FileList) && (v = "multipart/form-data");
|
|
2716
|
+
}), v !== "application/json")
|
|
2717
|
+
B = A;
|
|
2682
2718
|
else {
|
|
2683
|
-
const
|
|
2684
|
-
Array.from(O).forEach(({ value:
|
|
2685
|
-
|
|
2686
|
-
}),
|
|
2719
|
+
const y = {};
|
|
2720
|
+
Array.from(O).forEach(({ value: b, key: S }) => {
|
|
2721
|
+
Ne(y, S, b);
|
|
2722
|
+
}), B = JSON.stringify(y);
|
|
2687
2723
|
}
|
|
2688
|
-
|
|
2689
|
-
const
|
|
2690
|
-
if (t.current && (t.current.dispatchEvent(
|
|
2724
|
+
v && v !== "multipart/form-data" && (h && ((p = e.action) != null && p.includes("zapier.com")) || (w["content-type"] = v));
|
|
2725
|
+
const R = new CustomEvent("presubmit", { detail: { body: B } });
|
|
2726
|
+
if (t.current && (t.current.dispatchEvent(R), R.defaultPrevented))
|
|
2691
2727
|
return;
|
|
2692
2728
|
i("sending");
|
|
2693
|
-
const N = `${
|
|
2729
|
+
const N = `${bn() === "dev" ? "http://localhost:5000" : "https://builder.io"}/api/v1/form-submit?apiKey=${e.builderContext.apiKey}&to=${btoa(
|
|
2694
2730
|
e.sendSubmissionsToEmail || ""
|
|
2695
2731
|
)}&name=${encodeURIComponent(e.name || "")}`;
|
|
2696
2732
|
fetch(
|
|
2697
2733
|
e.sendSubmissionsTo === "email" ? N : e.action,
|
|
2698
|
-
{ body:
|
|
2734
|
+
{ body: B, headers: w, method: e.method || "post" }
|
|
2699
2735
|
).then(
|
|
2700
|
-
async (
|
|
2701
|
-
let
|
|
2702
|
-
const
|
|
2703
|
-
if (
|
|
2704
|
-
let
|
|
2705
|
-
|
|
2736
|
+
async (y) => {
|
|
2737
|
+
let b;
|
|
2738
|
+
const S = y.headers.get("content-type");
|
|
2739
|
+
if (S && S.indexOf("application/json") !== -1 ? b = await y.json() : b = await y.text(), !y.ok && e.errorMessagePath) {
|
|
2740
|
+
let k = pn(b, e.errorMessagePath);
|
|
2741
|
+
k && (typeof k != "string" && (k = JSON.stringify(k)), s(k), d({ formErrorMessage: k }));
|
|
2706
2742
|
}
|
|
2707
|
-
if (
|
|
2708
|
-
const
|
|
2709
|
-
detail: { res:
|
|
2743
|
+
if (a(b), i(y.ok ? "success" : "error"), y.ok) {
|
|
2744
|
+
const k = new CustomEvent("submit:success", {
|
|
2745
|
+
detail: { res: y, body: b }
|
|
2710
2746
|
});
|
|
2711
2747
|
if (t.current) {
|
|
2712
|
-
if (t.current.dispatchEvent(
|
|
2748
|
+
if (t.current.dispatchEvent(k), k.defaultPrevented)
|
|
2713
2749
|
return;
|
|
2714
2750
|
e.resetFormOnSubmit !== !1 && t.current.reset();
|
|
2715
2751
|
}
|
|
2716
2752
|
if (e.successUrl)
|
|
2717
2753
|
if (t.current) {
|
|
2718
|
-
const
|
|
2754
|
+
const C = new CustomEvent("route", {
|
|
2719
2755
|
detail: { url: e.successUrl }
|
|
2720
2756
|
});
|
|
2721
|
-
t.current.dispatchEvent(
|
|
2757
|
+
t.current.dispatchEvent(C), C.defaultPrevented || (location.href = e.successUrl);
|
|
2722
2758
|
} else
|
|
2723
2759
|
location.href = e.successUrl;
|
|
2724
2760
|
}
|
|
2725
2761
|
},
|
|
2726
|
-
(
|
|
2727
|
-
const
|
|
2728
|
-
detail: { error:
|
|
2762
|
+
(y) => {
|
|
2763
|
+
const b = new CustomEvent("submit:error", {
|
|
2764
|
+
detail: { error: y }
|
|
2729
2765
|
});
|
|
2730
|
-
t.current && (t.current.dispatchEvent(
|
|
2766
|
+
t.current && (t.current.dispatchEvent(b), b.defaultPrevented) || (a(y), i("error"));
|
|
2731
2767
|
}
|
|
2732
2768
|
);
|
|
2733
2769
|
}
|
|
2734
2770
|
}
|
|
2735
|
-
return /* @__PURE__ */ V(
|
|
2771
|
+
return /* @__PURE__ */ V(E, { children: [
|
|
2736
2772
|
" ",
|
|
2737
2773
|
/* @__PURE__ */ V(
|
|
2738
2774
|
"form",
|
|
@@ -2742,20 +2778,20 @@ function fn(e) {
|
|
|
2742
2778
|
action: !e.sendWithJs && e.action,
|
|
2743
2779
|
method: e.method,
|
|
2744
2780
|
name: e.name,
|
|
2745
|
-
onSubmit: (
|
|
2781
|
+
onSubmit: (x) => u(x),
|
|
2746
2782
|
...e.attributes,
|
|
2747
2783
|
children: [
|
|
2748
|
-
e.builderBlock && e.builderBlock.children ? /* @__PURE__ */
|
|
2749
|
-
|
|
2784
|
+
e.builderBlock && e.builderBlock.children ? /* @__PURE__ */ l(E, { children: (m = (g = e.builderBlock) == null ? void 0 : g.children) == null ? void 0 : m.map((x, h) => /* @__PURE__ */ l(
|
|
2785
|
+
J,
|
|
2750
2786
|
{
|
|
2751
|
-
block:
|
|
2787
|
+
block: x,
|
|
2752
2788
|
context: e.builderContext,
|
|
2753
2789
|
registeredComponents: e.builderComponents,
|
|
2754
2790
|
linkComponent: e.builderLinkComponent
|
|
2755
2791
|
},
|
|
2756
|
-
`form-block-${
|
|
2792
|
+
`form-block-${h}`
|
|
2757
2793
|
)) }) : null,
|
|
2758
|
-
|
|
2794
|
+
c() === "error" ? /* @__PURE__ */ l(
|
|
2759
2795
|
D,
|
|
2760
2796
|
{
|
|
2761
2797
|
path: "errorMessage",
|
|
@@ -2763,7 +2799,7 @@ function fn(e) {
|
|
|
2763
2799
|
context: e.builderContext
|
|
2764
2800
|
}
|
|
2765
2801
|
) : null,
|
|
2766
|
-
|
|
2802
|
+
c() === "sending" ? /* @__PURE__ */ l(
|
|
2767
2803
|
D,
|
|
2768
2804
|
{
|
|
2769
2805
|
path: "sendingMessage",
|
|
@@ -2771,8 +2807,8 @@ function fn(e) {
|
|
|
2771
2807
|
context: e.builderContext
|
|
2772
2808
|
}
|
|
2773
2809
|
) : null,
|
|
2774
|
-
|
|
2775
|
-
|
|
2810
|
+
c() === "error" && o ? /* @__PURE__ */ l("pre", { className: "builder-form-error-text pre-3a20f614", children: JSON.stringify(o, null, 2) }) : null,
|
|
2811
|
+
c() === "success" ? /* @__PURE__ */ l(
|
|
2776
2812
|
D,
|
|
2777
2813
|
{
|
|
2778
2814
|
path: "successMessage",
|
|
@@ -2784,11 +2820,11 @@ function fn(e) {
|
|
|
2784
2820
|
}
|
|
2785
2821
|
),
|
|
2786
2822
|
" ",
|
|
2787
|
-
/* @__PURE__ */
|
|
2823
|
+
/* @__PURE__ */ l("style", { children: ".pre-3a20f614 { padding: 10px; color: red; text-align: center; }" }),
|
|
2788
2824
|
" "
|
|
2789
2825
|
] });
|
|
2790
2826
|
}
|
|
2791
|
-
const
|
|
2827
|
+
const xn = {
|
|
2792
2828
|
name: "Form:Input",
|
|
2793
2829
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fad6f37889d9e40bbbbc72cdb5875d6ca",
|
|
2794
2830
|
inputs: [
|
|
@@ -2840,8 +2876,8 @@ const hn = {
|
|
|
2840
2876
|
borderColor: "#ccc"
|
|
2841
2877
|
}
|
|
2842
2878
|
};
|
|
2843
|
-
function
|
|
2844
|
-
return /* @__PURE__ */
|
|
2879
|
+
function vn(e) {
|
|
2880
|
+
return /* @__PURE__ */ Pe(
|
|
2845
2881
|
"input",
|
|
2846
2882
|
{
|
|
2847
2883
|
...e.attributes,
|
|
@@ -2855,7 +2891,7 @@ function gn(e) {
|
|
|
2855
2891
|
}
|
|
2856
2892
|
);
|
|
2857
2893
|
}
|
|
2858
|
-
const
|
|
2894
|
+
const Sn = {
|
|
2859
2895
|
name: "Form:Select",
|
|
2860
2896
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F83acca093fb24aaf94dee136e9a4b045",
|
|
2861
2897
|
defaultStyles: {
|
|
@@ -2898,9 +2934,9 @@ const bn = {
|
|
|
2898
2934
|
static: !0,
|
|
2899
2935
|
noWrap: !0
|
|
2900
2936
|
};
|
|
2901
|
-
function
|
|
2937
|
+
function kn(e) {
|
|
2902
2938
|
var t;
|
|
2903
|
-
return /* @__PURE__ */
|
|
2939
|
+
return /* @__PURE__ */ Pe(
|
|
2904
2940
|
"select",
|
|
2905
2941
|
{
|
|
2906
2942
|
...e.attributes,
|
|
@@ -2910,10 +2946,10 @@ function pn(e) {
|
|
|
2910
2946
|
name: e.name,
|
|
2911
2947
|
required: e.required
|
|
2912
2948
|
},
|
|
2913
|
-
(t = e.options) == null ? void 0 : t.map((n, i) => /* @__PURE__ */
|
|
2949
|
+
(t = e.options) == null ? void 0 : t.map((n, i) => /* @__PURE__ */ l("option", { value: n.value, children: n.name || n.value }, `${n.name}-${i}`))
|
|
2914
2950
|
);
|
|
2915
2951
|
}
|
|
2916
|
-
const
|
|
2952
|
+
const Cn = {
|
|
2917
2953
|
name: "Form:SubmitButton",
|
|
2918
2954
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Fdf2820ffed1f4349a94c40b3221f5b98",
|
|
2919
2955
|
defaultStyles: {
|
|
@@ -2939,10 +2975,10 @@ const yn = {
|
|
|
2939
2975
|
// TODO: defaultChildren
|
|
2940
2976
|
// canHaveChildren: true,
|
|
2941
2977
|
};
|
|
2942
|
-
function
|
|
2943
|
-
return /* @__PURE__ */
|
|
2978
|
+
function Tn(e) {
|
|
2979
|
+
return /* @__PURE__ */ l("button", { type: "submit", ...e.attributes, children: e.text });
|
|
2944
2980
|
}
|
|
2945
|
-
const
|
|
2981
|
+
const In = {
|
|
2946
2982
|
name: "Form:TextArea",
|
|
2947
2983
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2Ff74a2f3de58c4c3e939204e5b6b8f6c3",
|
|
2948
2984
|
inputs: [{
|
|
@@ -2979,8 +3015,8 @@ const vn = {
|
|
|
2979
3015
|
static: !0,
|
|
2980
3016
|
noWrap: !0
|
|
2981
3017
|
};
|
|
2982
|
-
function
|
|
2983
|
-
return /* @__PURE__ */
|
|
3018
|
+
function wn(e) {
|
|
3019
|
+
return /* @__PURE__ */ l(
|
|
2984
3020
|
"textarea",
|
|
2985
3021
|
{
|
|
2986
3022
|
...e.attributes,
|
|
@@ -2992,7 +3028,7 @@ function Sn(e) {
|
|
|
2992
3028
|
}
|
|
2993
3029
|
);
|
|
2994
3030
|
}
|
|
2995
|
-
const
|
|
3031
|
+
const Rn = {
|
|
2996
3032
|
// friendlyName?
|
|
2997
3033
|
name: "Raw:Img",
|
|
2998
3034
|
hideFromInsertMenu: !0,
|
|
@@ -3007,8 +3043,8 @@ const kn = {
|
|
|
3007
3043
|
noWrap: !0,
|
|
3008
3044
|
static: !0
|
|
3009
3045
|
};
|
|
3010
|
-
function
|
|
3011
|
-
return /* @__PURE__ */
|
|
3046
|
+
function En(e) {
|
|
3047
|
+
return /* @__PURE__ */ l(
|
|
3012
3048
|
"img",
|
|
3013
3049
|
{
|
|
3014
3050
|
style: {
|
|
@@ -3022,7 +3058,7 @@ function Cn(e) {
|
|
|
3022
3058
|
$() && e.imgSrc || "default-key"
|
|
3023
3059
|
);
|
|
3024
3060
|
}
|
|
3025
|
-
const
|
|
3061
|
+
const Bn = {
|
|
3026
3062
|
name: "Video",
|
|
3027
3063
|
canHaveChildren: !0,
|
|
3028
3064
|
defaultStyles: {
|
|
@@ -3107,8 +3143,8 @@ const Tn = {
|
|
|
3107
3143
|
builderBlock: !0
|
|
3108
3144
|
}
|
|
3109
3145
|
};
|
|
3110
|
-
function
|
|
3111
|
-
var i, o, r,
|
|
3146
|
+
function Pn(e) {
|
|
3147
|
+
var i, o, a, r, s, d, c;
|
|
3112
3148
|
function t() {
|
|
3113
3149
|
return {
|
|
3114
3150
|
...e.autoPlay === !0 ? {
|
|
@@ -3140,7 +3176,7 @@ function In(e) {
|
|
|
3140
3176
|
position: "relative"
|
|
3141
3177
|
},
|
|
3142
3178
|
children: [
|
|
3143
|
-
/* @__PURE__ */
|
|
3179
|
+
/* @__PURE__ */ l(
|
|
3144
3180
|
"video",
|
|
3145
3181
|
{
|
|
3146
3182
|
className: "builder-video",
|
|
@@ -3162,10 +3198,10 @@ function In(e) {
|
|
|
3162
3198
|
},
|
|
3163
3199
|
src: e.video || "no-src",
|
|
3164
3200
|
poster: e.posterImage,
|
|
3165
|
-
children: e.lazyLoad ? null : /* @__PURE__ */
|
|
3201
|
+
children: e.lazyLoad ? null : /* @__PURE__ */ l("source", { type: "video/mp4", src: e.video })
|
|
3166
3202
|
}
|
|
3167
3203
|
),
|
|
3168
|
-
e.aspectRatio && !(e.fitContent && ((
|
|
3204
|
+
e.aspectRatio && !(e.fitContent && ((a = (o = e.builderBlock) == null ? void 0 : o.children) != null && a.length)) ? /* @__PURE__ */ l(
|
|
3169
3205
|
"div",
|
|
3170
3206
|
{
|
|
3171
3207
|
style: {
|
|
@@ -3176,7 +3212,7 @@ function In(e) {
|
|
|
3176
3212
|
}
|
|
3177
3213
|
}
|
|
3178
3214
|
) : null,
|
|
3179
|
-
(
|
|
3215
|
+
(s = (r = e.builderBlock) == null ? void 0 : r.children) != null && s.length && e.fitContent ? /* @__PURE__ */ l(
|
|
3180
3216
|
"div",
|
|
3181
3217
|
{
|
|
3182
3218
|
style: {
|
|
@@ -3187,7 +3223,7 @@ function In(e) {
|
|
|
3187
3223
|
children: e.children
|
|
3188
3224
|
}
|
|
3189
3225
|
) : null,
|
|
3190
|
-
(
|
|
3226
|
+
(c = (d = e.builderBlock) == null ? void 0 : d.children) != null && c.length && !e.fitContent ? /* @__PURE__ */ l(
|
|
3191
3227
|
"div",
|
|
3192
3228
|
{
|
|
3193
3229
|
style: {
|
|
@@ -3208,64 +3244,64 @@ function In(e) {
|
|
|
3208
3244
|
}
|
|
3209
3245
|
);
|
|
3210
3246
|
}
|
|
3211
|
-
const
|
|
3212
|
-
component:
|
|
3213
|
-
...
|
|
3214
|
-
}, {
|
|
3215
|
-
component: sn,
|
|
3216
|
-
...an
|
|
3247
|
+
const Vn = () => [{
|
|
3248
|
+
component: cn,
|
|
3249
|
+
...sn
|
|
3217
3250
|
}, {
|
|
3218
3251
|
component: fn,
|
|
3219
|
-
...
|
|
3252
|
+
...dn
|
|
3220
3253
|
}, {
|
|
3221
|
-
component:
|
|
3254
|
+
component: yn,
|
|
3222
3255
|
...hn
|
|
3223
3256
|
}, {
|
|
3224
|
-
component:
|
|
3225
|
-
...
|
|
3257
|
+
component: vn,
|
|
3258
|
+
...xn
|
|
3226
3259
|
}, {
|
|
3227
|
-
component:
|
|
3228
|
-
...
|
|
3260
|
+
component: Tn,
|
|
3261
|
+
...Cn
|
|
3229
3262
|
}, {
|
|
3230
|
-
component:
|
|
3231
|
-
...
|
|
3263
|
+
component: kn,
|
|
3264
|
+
...Sn
|
|
3232
3265
|
}, {
|
|
3233
|
-
component:
|
|
3234
|
-
...
|
|
3266
|
+
component: wn,
|
|
3267
|
+
...In
|
|
3235
3268
|
}, {
|
|
3236
|
-
component:
|
|
3237
|
-
...
|
|
3238
|
-
}], ke = () => [{
|
|
3239
|
-
component: nt,
|
|
3240
|
-
...qt
|
|
3269
|
+
component: En,
|
|
3270
|
+
...Rn
|
|
3241
3271
|
}, {
|
|
3242
|
-
component:
|
|
3243
|
-
...
|
|
3272
|
+
component: Pn,
|
|
3273
|
+
...Bn
|
|
3274
|
+
}], Ce = () => [{
|
|
3275
|
+
component: it,
|
|
3276
|
+
...Yt
|
|
3244
3277
|
}, {
|
|
3245
|
-
component:
|
|
3246
|
-
...
|
|
3278
|
+
component: Mt,
|
|
3279
|
+
...Gt
|
|
3247
3280
|
}, {
|
|
3248
3281
|
component: jt,
|
|
3249
|
-
...
|
|
3250
|
-
}, {
|
|
3251
|
-
component: Ut,
|
|
3252
|
-
...Jt
|
|
3282
|
+
...Qt
|
|
3253
3283
|
}, {
|
|
3254
|
-
component:
|
|
3255
|
-
...
|
|
3284
|
+
component: qt,
|
|
3285
|
+
...Xt
|
|
3256
3286
|
}, {
|
|
3257
|
-
component:
|
|
3258
|
-
...
|
|
3287
|
+
component: _t,
|
|
3288
|
+
...Zt
|
|
3259
3289
|
}, {
|
|
3260
3290
|
component: tn,
|
|
3261
3291
|
...en
|
|
3262
3292
|
}, {
|
|
3263
|
-
component:
|
|
3264
|
-
...
|
|
3293
|
+
component: ei,
|
|
3294
|
+
...nn
|
|
3295
|
+
}, {
|
|
3296
|
+
component: ln,
|
|
3297
|
+
...rn
|
|
3265
3298
|
}, {
|
|
3266
|
-
component:
|
|
3267
|
-
...
|
|
3268
|
-
},
|
|
3299
|
+
component: an,
|
|
3300
|
+
...on
|
|
3301
|
+
}, {
|
|
3302
|
+
component: Jt,
|
|
3303
|
+
...zt
|
|
3304
|
+
}, ...Vn()], An = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
|
|
3269
3305
|
function getAndSetVariantId() {
|
|
3270
3306
|
function setCookie(name, value, days) {
|
|
3271
3307
|
let expires = '';
|
|
@@ -3321,7 +3357,7 @@ const wn = () => [{
|
|
|
3321
3357
|
}).join('');
|
|
3322
3358
|
styleEl.innerHTML = newStyleStr;
|
|
3323
3359
|
}
|
|
3324
|
-
}`,
|
|
3360
|
+
}`, Nn = `function updateVariantVisibility(variantContentId, defaultContentId, isHydrationTarget) {
|
|
3325
3361
|
if (!navigator.cookieEnabled) {
|
|
3326
3362
|
return;
|
|
3327
3363
|
}
|
|
@@ -3355,27 +3391,27 @@ const wn = () => [{
|
|
|
3355
3391
|
thisScriptEl?.remove();
|
|
3356
3392
|
}
|
|
3357
3393
|
return;
|
|
3358
|
-
}`, je = "builderIoAbTest",
|
|
3394
|
+
}`, je = "builderIoAbTest", He = "builderIoRenderContent", G = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
|
|
3359
3395
|
...t,
|
|
3360
3396
|
testVariationId: t.id,
|
|
3361
3397
|
id: e == null ? void 0 : e.id
|
|
3362
|
-
})),
|
|
3398
|
+
})), Wn = ({
|
|
3363
3399
|
canTrack: e,
|
|
3364
3400
|
content: t
|
|
3365
|
-
}) => !(!(
|
|
3366
|
-
window.${je} = ${
|
|
3367
|
-
window.${
|
|
3368
|
-
`,
|
|
3401
|
+
}) => !(!(G(t).length > 0) || !e || H()), Fn = (e) => e === "react" || e === "reactNative", Ke = Fn(U), $n = () => `
|
|
3402
|
+
window.${je} = ${An}
|
|
3403
|
+
window.${He} = ${Nn}
|
|
3404
|
+
`, Dn = (e, t) => `
|
|
3369
3405
|
window.${je}(
|
|
3370
|
-
"${t}",${JSON.stringify(e)}, ${
|
|
3371
|
-
)`,
|
|
3406
|
+
"${t}",${JSON.stringify(e)}, ${Ke}
|
|
3407
|
+
)`, Ln = ({
|
|
3372
3408
|
contentId: e,
|
|
3373
3409
|
variationId: t
|
|
3374
|
-
}) => `window.${
|
|
3375
|
-
"${t}", "${e}", ${
|
|
3410
|
+
}) => `window.${He}(
|
|
3411
|
+
"${t}", "${e}", ${Ke}
|
|
3376
3412
|
)`;
|
|
3377
3413
|
function ce(e) {
|
|
3378
|
-
return /* @__PURE__ */
|
|
3414
|
+
return /* @__PURE__ */ l(
|
|
3379
3415
|
"script",
|
|
3380
3416
|
{
|
|
3381
3417
|
dangerouslySetInnerHTML: { __html: e.scriptStr },
|
|
@@ -3384,10 +3420,10 @@ function ce(e) {
|
|
|
3384
3420
|
}
|
|
3385
3421
|
);
|
|
3386
3422
|
}
|
|
3387
|
-
function
|
|
3423
|
+
function Te(e) {
|
|
3388
3424
|
return Math.round(e * 1e3) / 1e3;
|
|
3389
3425
|
}
|
|
3390
|
-
const
|
|
3426
|
+
const On = (e, t, n = !0) => {
|
|
3391
3427
|
if (!(e instanceof HTMLElement))
|
|
3392
3428
|
return null;
|
|
3393
3429
|
let i = n ? e : e.parentElement;
|
|
@@ -3398,37 +3434,37 @@ const Wn = (e, t, n = !0) => {
|
|
|
3398
3434
|
return i;
|
|
3399
3435
|
} while (i = i.parentElement);
|
|
3400
3436
|
return null;
|
|
3401
|
-
},
|
|
3437
|
+
}, Un = (e) => On(e, (t) => {
|
|
3402
3438
|
const n = t.getAttribute("builder-id") || t.id;
|
|
3403
3439
|
return (n == null ? void 0 : n.indexOf("builder-")) === 0;
|
|
3404
|
-
}),
|
|
3440
|
+
}), Ie = ({
|
|
3405
3441
|
event: e,
|
|
3406
3442
|
target: t
|
|
3407
3443
|
}) => {
|
|
3408
|
-
const n = t.getBoundingClientRect(), i = e.clientX - n.left, o = e.clientY - n.top,
|
|
3444
|
+
const n = t.getBoundingClientRect(), i = e.clientX - n.left, o = e.clientY - n.top, a = Te(i / n.width), r = Te(o / n.height);
|
|
3409
3445
|
return {
|
|
3410
|
-
x:
|
|
3411
|
-
y:
|
|
3446
|
+
x: a,
|
|
3447
|
+
y: r
|
|
3412
3448
|
};
|
|
3413
|
-
},
|
|
3414
|
-
const t = e.target, n = t &&
|
|
3449
|
+
}, Mn = (e) => {
|
|
3450
|
+
const t = e.target, n = t && Un(t), i = (n == null ? void 0 : n.getAttribute("builder-id")) || (n == null ? void 0 : n.id);
|
|
3415
3451
|
return {
|
|
3416
3452
|
targetBuilderElement: i || void 0,
|
|
3417
3453
|
metadata: {
|
|
3418
|
-
targetOffset: t ?
|
|
3454
|
+
targetOffset: t ? Ie({
|
|
3419
3455
|
event: e,
|
|
3420
3456
|
target: t
|
|
3421
3457
|
}) : void 0,
|
|
3422
|
-
builderTargetOffset: n ?
|
|
3458
|
+
builderTargetOffset: n ? Ie({
|
|
3423
3459
|
event: e,
|
|
3424
3460
|
target: n
|
|
3425
3461
|
}) : void 0,
|
|
3426
3462
|
builderElementIndex: n && i ? [].slice.call(document.getElementsByClassName(i)).indexOf(n) : void 0
|
|
3427
3463
|
}
|
|
3428
3464
|
};
|
|
3429
|
-
},
|
|
3430
|
-
var
|
|
3431
|
-
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (
|
|
3465
|
+
}, jn = (e) => {
|
|
3466
|
+
var a, r;
|
|
3467
|
+
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (r = e.fileUrl) != null ? r : (a = e == null ? void 0 : e.files) == null ? void 0 : a.regular;
|
|
3432
3468
|
let o = "";
|
|
3433
3469
|
if (i && t && n && (o += `
|
|
3434
3470
|
@font-face {
|
|
@@ -3438,29 +3474,29 @@ font-display: fallback;
|
|
|
3438
3474
|
font-weight: 400;
|
|
3439
3475
|
}
|
|
3440
3476
|
`.trim()), e.files)
|
|
3441
|
-
for (const
|
|
3442
|
-
if (!(String(Number(
|
|
3477
|
+
for (const s in e.files) {
|
|
3478
|
+
if (!(String(Number(s)) === s))
|
|
3443
3479
|
continue;
|
|
3444
|
-
const
|
|
3445
|
-
|
|
3480
|
+
const c = e.files[s];
|
|
3481
|
+
c && c !== i && (o += `
|
|
3446
3482
|
@font-face {
|
|
3447
3483
|
font-family: "${t}";
|
|
3448
|
-
src: url('${
|
|
3484
|
+
src: url('${c}') format('woff2');
|
|
3449
3485
|
font-display: fallback;
|
|
3450
|
-
font-weight: ${
|
|
3486
|
+
font-weight: ${s};
|
|
3451
3487
|
}
|
|
3452
3488
|
`.trim());
|
|
3453
3489
|
}
|
|
3454
3490
|
return o;
|
|
3455
|
-
},
|
|
3491
|
+
}, Hn = ({
|
|
3456
3492
|
customFonts: e
|
|
3457
3493
|
}) => {
|
|
3458
3494
|
var t;
|
|
3459
|
-
return ((t = e == null ? void 0 : e.map((n) =>
|
|
3460
|
-
},
|
|
3495
|
+
return ((t = e == null ? void 0 : e.map((n) => jn(n))) == null ? void 0 : t.join(" ")) || "";
|
|
3496
|
+
}, Kn = ({
|
|
3461
3497
|
cssCode: e,
|
|
3462
3498
|
contentId: t
|
|
3463
|
-
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "",
|
|
3499
|
+
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", qn = `
|
|
3464
3500
|
.builder-button {
|
|
3465
3501
|
all: unset;
|
|
3466
3502
|
}
|
|
@@ -3477,39 +3513,39 @@ font-weight: ${l};
|
|
|
3477
3513
|
text-align: inherit;
|
|
3478
3514
|
font-family: inherit;
|
|
3479
3515
|
}
|
|
3480
|
-
`,
|
|
3481
|
-
function
|
|
3482
|
-
var
|
|
3483
|
-
const t =
|
|
3484
|
-
function n(
|
|
3485
|
-
var
|
|
3486
|
-
const
|
|
3516
|
+
`, _n = (e) => e ? "" : qn, zn = (e) => `variant-${e}`;
|
|
3517
|
+
function Jn(e) {
|
|
3518
|
+
var B, A, O, v, R, N, y;
|
|
3519
|
+
const t = z(null);
|
|
3520
|
+
function n(b) {
|
|
3521
|
+
var k, C;
|
|
3522
|
+
const S = {
|
|
3487
3523
|
...e.builderContextSignal.rootState,
|
|
3488
|
-
...
|
|
3524
|
+
...b
|
|
3489
3525
|
};
|
|
3490
|
-
e.builderContextSignal.rootSetState ? (
|
|
3526
|
+
e.builderContextSignal.rootSetState ? (C = (k = e.builderContextSignal).rootSetState) == null || C.call(k, S) : e.setBuilderContextSignal((I) => ({
|
|
3491
3527
|
...I,
|
|
3492
|
-
rootState:
|
|
3528
|
+
rootState: S
|
|
3493
3529
|
}));
|
|
3494
3530
|
}
|
|
3495
|
-
function i(
|
|
3496
|
-
var
|
|
3497
|
-
const
|
|
3531
|
+
function i(b) {
|
|
3532
|
+
var k, C, I, W, M;
|
|
3533
|
+
const S = {
|
|
3498
3534
|
...e.builderContextSignal.content,
|
|
3499
|
-
...
|
|
3535
|
+
...b,
|
|
3500
3536
|
data: {
|
|
3501
|
-
...(
|
|
3502
|
-
...
|
|
3537
|
+
...(k = e.builderContextSignal.content) == null ? void 0 : k.data,
|
|
3538
|
+
...b == null ? void 0 : b.data
|
|
3503
3539
|
},
|
|
3504
3540
|
meta: {
|
|
3505
|
-
...(
|
|
3506
|
-
...
|
|
3507
|
-
breakpoints: ((I =
|
|
3541
|
+
...(C = e.builderContextSignal.content) == null ? void 0 : C.meta,
|
|
3542
|
+
...b == null ? void 0 : b.meta,
|
|
3543
|
+
breakpoints: ((I = b == null ? void 0 : b.meta) == null ? void 0 : I.breakpoints) || ((M = (W = e.builderContextSignal.content) == null ? void 0 : W.meta) == null ? void 0 : M.breakpoints)
|
|
3508
3544
|
}
|
|
3509
3545
|
};
|
|
3510
3546
|
e.setBuilderContextSignal((F) => ({
|
|
3511
3547
|
...F,
|
|
3512
|
-
content:
|
|
3548
|
+
content: S
|
|
3513
3549
|
}));
|
|
3514
3550
|
}
|
|
3515
3551
|
function o() {
|
|
@@ -3518,37 +3554,37 @@ function Hn(e) {
|
|
|
3518
3554
|
"aria-hidden": !0
|
|
3519
3555
|
};
|
|
3520
3556
|
}
|
|
3521
|
-
const [
|
|
3557
|
+
const [a, r] = T(
|
|
3522
3558
|
() => e.contentWrapper || "div"
|
|
3523
3559
|
);
|
|
3524
|
-
function
|
|
3525
|
-
return
|
|
3560
|
+
function s(b) {
|
|
3561
|
+
return Xe({
|
|
3526
3562
|
model: e.model,
|
|
3527
3563
|
trustedHosts: e.trustedHosts,
|
|
3528
3564
|
callbacks: {
|
|
3529
|
-
configureSdk: (
|
|
3565
|
+
configureSdk: (S) => {
|
|
3530
3566
|
var I;
|
|
3531
|
-
const { breakpoints:
|
|
3532
|
-
!
|
|
3567
|
+
const { breakpoints: k, contentId: C } = S;
|
|
3568
|
+
!C || C !== ((I = e.builderContextSignal.content) == null ? void 0 : I.id) || k && i({
|
|
3533
3569
|
meta: {
|
|
3534
|
-
breakpoints:
|
|
3570
|
+
breakpoints: k
|
|
3535
3571
|
}
|
|
3536
3572
|
});
|
|
3537
3573
|
},
|
|
3538
|
-
animation: (
|
|
3539
|
-
|
|
3574
|
+
animation: (S) => {
|
|
3575
|
+
$e(S);
|
|
3540
3576
|
},
|
|
3541
|
-
contentUpdate: (
|
|
3542
|
-
i(
|
|
3577
|
+
contentUpdate: (S) => {
|
|
3578
|
+
i(S);
|
|
3543
3579
|
}
|
|
3544
3580
|
}
|
|
3545
|
-
})(
|
|
3581
|
+
})(b);
|
|
3546
3582
|
}
|
|
3547
|
-
function
|
|
3548
|
-
var
|
|
3549
|
-
const
|
|
3550
|
-
|
|
3551
|
-
code:
|
|
3583
|
+
function d() {
|
|
3584
|
+
var S, k;
|
|
3585
|
+
const b = (k = (S = e.builderContextSignal.content) == null ? void 0 : S.data) == null ? void 0 : k.jsCode;
|
|
3586
|
+
b && K({
|
|
3587
|
+
code: b,
|
|
3552
3588
|
context: e.context || {},
|
|
3553
3589
|
localState: void 0,
|
|
3554
3590
|
rootState: e.builderContextSignal.rootState,
|
|
@@ -3559,35 +3595,35 @@ function Hn(e) {
|
|
|
3559
3595
|
enableCache: !1
|
|
3560
3596
|
});
|
|
3561
3597
|
}
|
|
3562
|
-
const [
|
|
3563
|
-
function
|
|
3564
|
-
var
|
|
3598
|
+
const [c, u] = T(() => ({})), [g, m] = T(() => ({})), [x, h] = T(() => !1);
|
|
3599
|
+
function p(b) {
|
|
3600
|
+
var S, k;
|
|
3565
3601
|
if (e.builderContextSignal.content) {
|
|
3566
|
-
const
|
|
3602
|
+
const C = (S = e.builderContextSignal.content) == null ? void 0 : S.testVariationId, I = (k = e.builderContextSignal.content) == null ? void 0 : k.id;
|
|
3567
3603
|
he({
|
|
3568
3604
|
type: "click",
|
|
3569
|
-
canTrack:
|
|
3605
|
+
canTrack: X(e.canTrack),
|
|
3570
3606
|
contentId: I,
|
|
3571
3607
|
apiKey: e.apiKey,
|
|
3572
|
-
variationId:
|
|
3573
|
-
|
|
3574
|
-
unique: !
|
|
3608
|
+
variationId: C !== I ? C : void 0,
|
|
3609
|
+
...Mn(b),
|
|
3610
|
+
unique: !x
|
|
3575
3611
|
});
|
|
3576
3612
|
}
|
|
3577
|
-
|
|
3613
|
+
x || h(!0);
|
|
3578
3614
|
}
|
|
3579
|
-
function
|
|
3580
|
-
var
|
|
3581
|
-
const
|
|
3582
|
-
Object.entries(
|
|
3583
|
-
if (!W ||
|
|
3615
|
+
function f() {
|
|
3616
|
+
var S, k, C;
|
|
3617
|
+
const b = (C = (k = (S = e.builderContextSignal.content) == null ? void 0 : S.data) == null ? void 0 : k.httpRequests) != null ? C : {};
|
|
3618
|
+
Object.entries(b).forEach(([I, W]) => {
|
|
3619
|
+
if (!W || g[I] || c[I] && !$())
|
|
3584
3620
|
return;
|
|
3585
|
-
|
|
3586
|
-
const
|
|
3621
|
+
g[I] = !0;
|
|
3622
|
+
const M = W.replace(
|
|
3587
3623
|
/{{([^}]+)}}/g,
|
|
3588
|
-
(F,
|
|
3589
|
-
|
|
3590
|
-
code:
|
|
3624
|
+
(F, qe) => String(
|
|
3625
|
+
K({
|
|
3626
|
+
code: qe,
|
|
3591
3627
|
context: e.context || {},
|
|
3592
3628
|
localState: void 0,
|
|
3593
3629
|
rootState: e.builderContextSignal.rootState,
|
|
@@ -3596,18 +3632,18 @@ function Hn(e) {
|
|
|
3596
3632
|
})
|
|
3597
3633
|
)
|
|
3598
3634
|
);
|
|
3599
|
-
|
|
3635
|
+
Ze(M).then((F) => F.json()).then((F) => {
|
|
3600
3636
|
n({
|
|
3601
3637
|
[I]: F
|
|
3602
|
-
}),
|
|
3638
|
+
}), c[I] = !0;
|
|
3603
3639
|
}).catch((F) => {
|
|
3604
3640
|
console.error("error fetching dynamic data", W, F);
|
|
3605
3641
|
}).finally(() => {
|
|
3606
|
-
|
|
3642
|
+
g[I] = !1;
|
|
3607
3643
|
});
|
|
3608
3644
|
});
|
|
3609
3645
|
}
|
|
3610
|
-
function
|
|
3646
|
+
function w() {
|
|
3611
3647
|
$() && window.dispatchEvent(
|
|
3612
3648
|
new CustomEvent(
|
|
3613
3649
|
"builder:component:stateChange",
|
|
@@ -3623,9 +3659,9 @@ function Hn(e) {
|
|
|
3623
3659
|
);
|
|
3624
3660
|
}
|
|
3625
3661
|
return P(() => {
|
|
3626
|
-
var
|
|
3627
|
-
if (
|
|
3628
|
-
if ($() && (window.addEventListener("message",
|
|
3662
|
+
var b, S;
|
|
3663
|
+
if (H()) {
|
|
3664
|
+
if ($() && (window.addEventListener("message", s), Ye(), Ge({
|
|
3629
3665
|
...e.locale ? {
|
|
3630
3666
|
locale: e.locale
|
|
3631
3667
|
} : {},
|
|
@@ -3637,28 +3673,28 @@ function Hn(e) {
|
|
|
3637
3673
|
} : {}
|
|
3638
3674
|
}), Object.values(
|
|
3639
3675
|
e.builderContextSignal.componentInfos
|
|
3640
|
-
).forEach((
|
|
3676
|
+
).forEach((C) => {
|
|
3641
3677
|
var W;
|
|
3642
|
-
const I =
|
|
3678
|
+
const I = Qe(C);
|
|
3643
3679
|
(W = window.parent) == null || W.postMessage(I, "*");
|
|
3644
3680
|
}), window.addEventListener(
|
|
3645
3681
|
"builder:component:stateChangeListenerActivated",
|
|
3646
|
-
|
|
3647
|
-
)), e.builderContextSignal.content &&
|
|
3648
|
-
const
|
|
3682
|
+
w
|
|
3683
|
+
)), e.builderContextSignal.content && X(e.canTrack)) {
|
|
3684
|
+
const C = (b = e.builderContextSignal.content) == null ? void 0 : b.testVariationId, I = (S = e.builderContextSignal.content) == null ? void 0 : S.id, W = e.apiKey;
|
|
3649
3685
|
he({
|
|
3650
3686
|
type: "impression",
|
|
3651
3687
|
canTrack: !0,
|
|
3652
3688
|
contentId: I,
|
|
3653
3689
|
apiKey: W,
|
|
3654
|
-
variationId:
|
|
3690
|
+
variationId: C !== I ? C : void 0
|
|
3655
3691
|
});
|
|
3656
3692
|
}
|
|
3657
|
-
if (
|
|
3658
|
-
const
|
|
3693
|
+
if (Re() && !$()) {
|
|
3694
|
+
const C = new URL(location.href).searchParams, I = C.get("builder.preview"), W = C.get(
|
|
3659
3695
|
`builder.overrides.${I}`
|
|
3660
|
-
),
|
|
3661
|
-
I === e.model &&
|
|
3696
|
+
), M = C.get("apiKey") || C.get("builder.space");
|
|
3697
|
+
I === e.model && M === e.apiKey && (!e.content || W === e.content.id) && Ee({
|
|
3662
3698
|
model: e.model,
|
|
3663
3699
|
apiKey: e.apiKey,
|
|
3664
3700
|
apiVersion: e.builderContextSignal.apiVersion
|
|
@@ -3670,15 +3706,15 @@ function Hn(e) {
|
|
|
3670
3706
|
}, []), P(() => {
|
|
3671
3707
|
e.apiKey || Z.error(
|
|
3672
3708
|
"No API key provided to `Content` component. This can cause issues. Please provide an API key using the `apiKey` prop."
|
|
3673
|
-
),
|
|
3709
|
+
), d(), f(), w();
|
|
3674
3710
|
}, []), P(() => {
|
|
3675
3711
|
e.content && i(e.content);
|
|
3676
3712
|
}, [e.content]), P(() => {
|
|
3677
|
-
|
|
3678
|
-
}, [(A = (
|
|
3679
|
-
|
|
3680
|
-
}, [(
|
|
3681
|
-
|
|
3713
|
+
d();
|
|
3714
|
+
}, [(A = (B = e.builderContextSignal.content) == null ? void 0 : B.data) == null ? void 0 : A.jsCode]), P(() => {
|
|
3715
|
+
f();
|
|
3716
|
+
}, [(v = (O = e.builderContextSignal.content) == null ? void 0 : O.data) == null ? void 0 : v.httpRequests]), P(() => {
|
|
3717
|
+
w();
|
|
3682
3718
|
}, [e.builderContextSignal.rootState]), P(() => {
|
|
3683
3719
|
e.data && n(e.data);
|
|
3684
3720
|
}, [e.data]), P(() => {
|
|
@@ -3686,41 +3722,41 @@ function Hn(e) {
|
|
|
3686
3722
|
locale: e.locale
|
|
3687
3723
|
});
|
|
3688
3724
|
}, [e.locale]), P(() => () => {
|
|
3689
|
-
|
|
3725
|
+
H() && (window.removeEventListener("message", s), window.removeEventListener(
|
|
3690
3726
|
"builder:component:stateChangeListenerActivated",
|
|
3691
|
-
|
|
3727
|
+
w
|
|
3692
3728
|
));
|
|
3693
|
-
}, []), /* @__PURE__ */
|
|
3694
|
-
|
|
3729
|
+
}, []), /* @__PURE__ */ l(ue.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content ? /* @__PURE__ */ l(
|
|
3730
|
+
a,
|
|
3695
3731
|
{
|
|
3696
3732
|
ref: t,
|
|
3697
|
-
onClick: (
|
|
3698
|
-
"builder-content-id": (
|
|
3733
|
+
onClick: (b) => p(b),
|
|
3734
|
+
"builder-content-id": (R = e.builderContextSignal.content) == null ? void 0 : R.id,
|
|
3699
3735
|
"builder-model": e.model,
|
|
3700
3736
|
...o(),
|
|
3701
3737
|
...e.contentWrapperProps,
|
|
3702
|
-
className:
|
|
3703
|
-
((N = e.content) == null ? void 0 : N.testVariationId) || ((
|
|
3738
|
+
className: zn(
|
|
3739
|
+
((N = e.content) == null ? void 0 : N.testVariationId) || ((y = e.content) == null ? void 0 : y.id)
|
|
3704
3740
|
),
|
|
3705
3741
|
children: e.children
|
|
3706
3742
|
}
|
|
3707
3743
|
) : null });
|
|
3708
3744
|
}
|
|
3709
|
-
function
|
|
3745
|
+
function Yn(e) {
|
|
3710
3746
|
const [t, n] = T(
|
|
3711
3747
|
() => `
|
|
3712
|
-
${
|
|
3748
|
+
${Kn({
|
|
3713
3749
|
cssCode: e.cssCode,
|
|
3714
3750
|
contentId: e.contentId
|
|
3715
3751
|
})}
|
|
3716
|
-
${
|
|
3752
|
+
${Hn({
|
|
3717
3753
|
customFonts: e.customFonts
|
|
3718
3754
|
})}
|
|
3719
|
-
${
|
|
3755
|
+
${_n(e.isNestedRender)}
|
|
3720
3756
|
`.trim()
|
|
3721
3757
|
);
|
|
3722
|
-
return /* @__PURE__ */
|
|
3723
|
-
|
|
3758
|
+
return /* @__PURE__ */ l(
|
|
3759
|
+
te,
|
|
3724
3760
|
{
|
|
3725
3761
|
id: "builderio-content",
|
|
3726
3762
|
styles: t,
|
|
@@ -3728,15 +3764,15 @@ ${Un(e.isNestedRender)}
|
|
|
3728
3764
|
}
|
|
3729
3765
|
);
|
|
3730
3766
|
}
|
|
3731
|
-
const
|
|
3767
|
+
const Gn = ({
|
|
3732
3768
|
content: e,
|
|
3733
3769
|
data: t,
|
|
3734
3770
|
locale: n
|
|
3735
3771
|
}) => {
|
|
3736
|
-
var
|
|
3737
|
-
const i = {}, o = ((
|
|
3738
|
-
return (
|
|
3739
|
-
|
|
3772
|
+
var a, r, s;
|
|
3773
|
+
const i = {}, o = ((a = e == null ? void 0 : e.data) == null ? void 0 : a.state) || {};
|
|
3774
|
+
return (s = (r = e == null ? void 0 : e.data) == null ? void 0 : r.inputs) == null || s.forEach((d) => {
|
|
3775
|
+
d.name && d.defaultValue !== void 0 && (i[d.name] = d.defaultValue);
|
|
3740
3776
|
}), {
|
|
3741
3777
|
...i,
|
|
3742
3778
|
...o,
|
|
@@ -3745,7 +3781,7 @@ const Kn = ({
|
|
|
3745
3781
|
locale: n
|
|
3746
3782
|
} : {}
|
|
3747
3783
|
};
|
|
3748
|
-
},
|
|
3784
|
+
}, Qn = ({
|
|
3749
3785
|
content: e,
|
|
3750
3786
|
data: t
|
|
3751
3787
|
}) => e ? {
|
|
@@ -3756,51 +3792,51 @@ const Kn = ({
|
|
|
3756
3792
|
},
|
|
3757
3793
|
meta: e == null ? void 0 : e.meta
|
|
3758
3794
|
} : void 0;
|
|
3759
|
-
function
|
|
3760
|
-
var
|
|
3795
|
+
function we(e) {
|
|
3796
|
+
var d, c, u, g, m, x, h;
|
|
3761
3797
|
const [t, n] = T(
|
|
3762
3798
|
() => {
|
|
3763
|
-
var
|
|
3764
|
-
return
|
|
3799
|
+
var p, f;
|
|
3800
|
+
return Ln({
|
|
3765
3801
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
3766
|
-
variationId: (
|
|
3802
|
+
variationId: (p = e.content) == null ? void 0 : p.testVariationId,
|
|
3767
3803
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-non-null-asserted-optional-chain
|
|
3768
|
-
contentId: (
|
|
3804
|
+
contentId: (f = e.content) == null ? void 0 : f.id
|
|
3769
3805
|
});
|
|
3770
3806
|
}
|
|
3771
3807
|
);
|
|
3772
|
-
function i(
|
|
3773
|
-
|
|
3774
|
-
...
|
|
3775
|
-
rootState:
|
|
3808
|
+
function i(p) {
|
|
3809
|
+
s((f) => ({
|
|
3810
|
+
...f,
|
|
3811
|
+
rootState: p
|
|
3776
3812
|
}));
|
|
3777
3813
|
}
|
|
3778
|
-
const [o,
|
|
3814
|
+
const [o, a] = T(
|
|
3779
3815
|
() => {
|
|
3780
|
-
var
|
|
3816
|
+
var p;
|
|
3781
3817
|
return [
|
|
3782
|
-
...
|
|
3783
|
-
...((
|
|
3818
|
+
...Ce(),
|
|
3819
|
+
...((p = e.customComponents) == null ? void 0 : p.filter(({ models: f }) => !(f != null && f.length) || !e.model ? !0 : f.includes(e.model))) || []
|
|
3784
3820
|
].reduce(
|
|
3785
|
-
(
|
|
3786
|
-
...
|
|
3787
|
-
[
|
|
3788
|
-
component:
|
|
3789
|
-
...ge(
|
|
3821
|
+
(f, { component: w, ...B }) => ({
|
|
3822
|
+
...f,
|
|
3823
|
+
[B.name]: {
|
|
3824
|
+
component: w,
|
|
3825
|
+
...ge(B)
|
|
3790
3826
|
}
|
|
3791
3827
|
}),
|
|
3792
3828
|
{}
|
|
3793
3829
|
);
|
|
3794
3830
|
}
|
|
3795
|
-
), [
|
|
3796
|
-
var
|
|
3831
|
+
), [r, s] = T(() => {
|
|
3832
|
+
var p;
|
|
3797
3833
|
return {
|
|
3798
|
-
content:
|
|
3834
|
+
content: Qn({
|
|
3799
3835
|
content: e.content,
|
|
3800
3836
|
data: e.data
|
|
3801
3837
|
}),
|
|
3802
3838
|
localState: void 0,
|
|
3803
|
-
rootState:
|
|
3839
|
+
rootState: Gn({
|
|
3804
3840
|
content: e.content,
|
|
3805
3841
|
data: e.data,
|
|
3806
3842
|
locale: e.locale
|
|
@@ -3811,12 +3847,12 @@ function Ie(e) {
|
|
|
3811
3847
|
apiKey: e.apiKey,
|
|
3812
3848
|
apiVersion: e.apiVersion,
|
|
3813
3849
|
componentInfos: [
|
|
3814
|
-
...
|
|
3815
|
-
...((
|
|
3850
|
+
...Ce(),
|
|
3851
|
+
...((p = e.customComponents) == null ? void 0 : p.filter(({ models: f }) => !(f != null && f.length) || !e.model ? !0 : f.includes(e.model))) || []
|
|
3816
3852
|
].reduce(
|
|
3817
|
-
(
|
|
3818
|
-
...
|
|
3819
|
-
[
|
|
3853
|
+
(f, { component: w, ...B }) => ({
|
|
3854
|
+
...f,
|
|
3855
|
+
[B.name]: ge(B)
|
|
3820
3856
|
}),
|
|
3821
3857
|
{}
|
|
3822
3858
|
),
|
|
@@ -3826,14 +3862,14 @@ function Ie(e) {
|
|
|
3826
3862
|
nonce: e.nonce || ""
|
|
3827
3863
|
};
|
|
3828
3864
|
});
|
|
3829
|
-
return /* @__PURE__ */
|
|
3830
|
-
|
|
3865
|
+
return /* @__PURE__ */ l(
|
|
3866
|
+
Ve.Provider,
|
|
3831
3867
|
{
|
|
3832
3868
|
value: {
|
|
3833
3869
|
registeredComponents: o
|
|
3834
3870
|
},
|
|
3835
3871
|
children: /* @__PURE__ */ V(
|
|
3836
|
-
|
|
3872
|
+
Jn,
|
|
3837
3873
|
{
|
|
3838
3874
|
nonce: e.nonce,
|
|
3839
3875
|
content: e.content,
|
|
@@ -3845,13 +3881,13 @@ function Ie(e) {
|
|
|
3845
3881
|
locale: e.locale,
|
|
3846
3882
|
enrich: e.enrich,
|
|
3847
3883
|
showContent: e.showContent,
|
|
3848
|
-
builderContextSignal:
|
|
3884
|
+
builderContextSignal: r,
|
|
3849
3885
|
contentWrapper: e.contentWrapper,
|
|
3850
3886
|
contentWrapperProps: e.contentWrapperProps,
|
|
3851
3887
|
trustedHosts: e.trustedHosts,
|
|
3852
|
-
setBuilderContextSignal:
|
|
3888
|
+
setBuilderContextSignal: s,
|
|
3853
3889
|
children: [
|
|
3854
|
-
e.isSsrAbTest ? /* @__PURE__ */
|
|
3890
|
+
e.isSsrAbTest ? /* @__PURE__ */ l(
|
|
3855
3891
|
ce,
|
|
3856
3892
|
{
|
|
3857
3893
|
id: "builderio-variant-visibility",
|
|
@@ -3859,21 +3895,21 @@ function Ie(e) {
|
|
|
3859
3895
|
nonce: e.nonce || ""
|
|
3860
3896
|
}
|
|
3861
3897
|
) : null,
|
|
3862
|
-
/* @__PURE__ */
|
|
3863
|
-
|
|
3898
|
+
/* @__PURE__ */ l(
|
|
3899
|
+
Yn,
|
|
3864
3900
|
{
|
|
3865
3901
|
nonce: e.nonce || "",
|
|
3866
3902
|
isNestedRender: e.isNestedRender,
|
|
3867
|
-
contentId: (
|
|
3868
|
-
cssCode: (
|
|
3869
|
-
customFonts: (m = (
|
|
3903
|
+
contentId: (d = r.content) == null ? void 0 : d.id,
|
|
3904
|
+
cssCode: (u = (c = r.content) == null ? void 0 : c.data) == null ? void 0 : u.cssCode,
|
|
3905
|
+
customFonts: (m = (g = r.content) == null ? void 0 : g.data) == null ? void 0 : m.customFonts
|
|
3870
3906
|
}
|
|
3871
3907
|
),
|
|
3872
|
-
/* @__PURE__ */
|
|
3908
|
+
/* @__PURE__ */ l(
|
|
3873
3909
|
D,
|
|
3874
3910
|
{
|
|
3875
|
-
blocks: (
|
|
3876
|
-
context:
|
|
3911
|
+
blocks: (h = (x = r.content) == null ? void 0 : x.data) == null ? void 0 : h.blocks,
|
|
3912
|
+
context: r,
|
|
3877
3913
|
registeredComponents: o,
|
|
3878
3914
|
linkComponent: e.linkComponent
|
|
3879
3915
|
}
|
|
@@ -3884,57 +3920,57 @@ function Ie(e) {
|
|
|
3884
3920
|
}
|
|
3885
3921
|
);
|
|
3886
3922
|
}
|
|
3887
|
-
function
|
|
3888
|
-
var
|
|
3923
|
+
function Xn(e) {
|
|
3924
|
+
var r;
|
|
3889
3925
|
const [t, n] = T(
|
|
3890
|
-
() =>
|
|
3891
|
-
canTrack:
|
|
3926
|
+
() => Wn({
|
|
3927
|
+
canTrack: X(e.canTrack),
|
|
3892
3928
|
content: e.content
|
|
3893
3929
|
})
|
|
3894
3930
|
);
|
|
3895
3931
|
function i() {
|
|
3896
|
-
var
|
|
3897
|
-
return
|
|
3898
|
-
|
|
3899
|
-
id:
|
|
3900
|
-
testRatio:
|
|
3932
|
+
var s;
|
|
3933
|
+
return Dn(
|
|
3934
|
+
G(e.content).map((d) => ({
|
|
3935
|
+
id: d.testVariationId,
|
|
3936
|
+
testRatio: d.testRatio
|
|
3901
3937
|
})),
|
|
3902
|
-
((
|
|
3938
|
+
((s = e.content) == null ? void 0 : s.id) || ""
|
|
3903
3939
|
);
|
|
3904
3940
|
}
|
|
3905
3941
|
function o() {
|
|
3906
|
-
return
|
|
3942
|
+
return G(e.content).map((s) => `.variant-${s.testVariationId} { display: none; } `).join("");
|
|
3907
3943
|
}
|
|
3908
|
-
function
|
|
3909
|
-
var
|
|
3944
|
+
function a() {
|
|
3945
|
+
var s;
|
|
3910
3946
|
return t ? {
|
|
3911
3947
|
...e.content,
|
|
3912
|
-
testVariationId: (
|
|
3913
|
-
} :
|
|
3948
|
+
testVariationId: (s = e.content) == null ? void 0 : s.id
|
|
3949
|
+
} : et({
|
|
3914
3950
|
item: e.content,
|
|
3915
|
-
canTrack:
|
|
3951
|
+
canTrack: X(e.canTrack)
|
|
3916
3952
|
});
|
|
3917
3953
|
}
|
|
3918
3954
|
return P(() => {
|
|
3919
|
-
}, []), /* @__PURE__ */ V(
|
|
3920
|
-
!e.isNestedRender &&
|
|
3955
|
+
}, []), /* @__PURE__ */ V(E, { children: [
|
|
3956
|
+
!e.isNestedRender && U !== "reactNative" ? /* @__PURE__ */ l(
|
|
3921
3957
|
ce,
|
|
3922
3958
|
{
|
|
3923
3959
|
id: "builderio-init-variants-fns",
|
|
3924
|
-
scriptStr:
|
|
3960
|
+
scriptStr: $n(),
|
|
3925
3961
|
nonce: e.nonce || ""
|
|
3926
3962
|
}
|
|
3927
3963
|
) : null,
|
|
3928
|
-
t ? /* @__PURE__ */ V(
|
|
3929
|
-
/* @__PURE__ */
|
|
3930
|
-
|
|
3964
|
+
t ? /* @__PURE__ */ V(E, { children: [
|
|
3965
|
+
/* @__PURE__ */ l(
|
|
3966
|
+
te,
|
|
3931
3967
|
{
|
|
3932
3968
|
id: "builderio-variants",
|
|
3933
3969
|
styles: o(),
|
|
3934
3970
|
nonce: e.nonce || ""
|
|
3935
3971
|
}
|
|
3936
3972
|
),
|
|
3937
|
-
/* @__PURE__ */
|
|
3973
|
+
/* @__PURE__ */ l(
|
|
3938
3974
|
ce,
|
|
3939
3975
|
{
|
|
3940
3976
|
id: "builderio-variants-visibility",
|
|
@@ -3942,12 +3978,12 @@ function _n(e) {
|
|
|
3942
3978
|
nonce: e.nonce || ""
|
|
3943
3979
|
}
|
|
3944
3980
|
),
|
|
3945
|
-
(
|
|
3946
|
-
|
|
3981
|
+
(r = G(e.content)) == null ? void 0 : r.map((s) => /* @__PURE__ */ l(
|
|
3982
|
+
we,
|
|
3947
3983
|
{
|
|
3948
3984
|
isNestedRender: e.isNestedRender,
|
|
3949
3985
|
nonce: e.nonce,
|
|
3950
|
-
content:
|
|
3986
|
+
content: s,
|
|
3951
3987
|
showContent: !1,
|
|
3952
3988
|
model: e.model,
|
|
3953
3989
|
data: e.data,
|
|
@@ -3966,15 +4002,15 @@ function _n(e) {
|
|
|
3966
4002
|
contentWrapperProps: e.contentWrapperProps,
|
|
3967
4003
|
trustedHosts: e.trustedHosts
|
|
3968
4004
|
},
|
|
3969
|
-
|
|
4005
|
+
s.testVariationId
|
|
3970
4006
|
))
|
|
3971
4007
|
] }) : null,
|
|
3972
|
-
/* @__PURE__ */
|
|
3973
|
-
|
|
4008
|
+
/* @__PURE__ */ l(
|
|
4009
|
+
we,
|
|
3974
4010
|
{
|
|
3975
4011
|
nonce: e.nonce,
|
|
3976
4012
|
isNestedRender: e.isNestedRender,
|
|
3977
|
-
content:
|
|
4013
|
+
content: a(),
|
|
3978
4014
|
showContent: !0,
|
|
3979
4015
|
model: e.model,
|
|
3980
4016
|
data: e.data,
|
|
@@ -3996,13 +4032,13 @@ function _n(e) {
|
|
|
3996
4032
|
)
|
|
3997
4033
|
] });
|
|
3998
4034
|
}
|
|
3999
|
-
const
|
|
4035
|
+
const Zn = async ({
|
|
4000
4036
|
builderContextValue: e,
|
|
4001
4037
|
symbol: t
|
|
4002
4038
|
}) => {
|
|
4003
4039
|
if (t != null && t.model && // This is a hack, we should not need to check for this, but it is needed for Svelte.
|
|
4004
4040
|
(e != null && e.apiKey))
|
|
4005
|
-
return
|
|
4041
|
+
return Ee({
|
|
4006
4042
|
model: t.model,
|
|
4007
4043
|
apiKey: e.apiKey,
|
|
4008
4044
|
apiVersion: e.apiVersion,
|
|
@@ -4015,8 +4051,8 @@ const Jn = async ({
|
|
|
4015
4051
|
Z.error("Could not fetch symbol content: ", n);
|
|
4016
4052
|
});
|
|
4017
4053
|
};
|
|
4018
|
-
function
|
|
4019
|
-
var
|
|
4054
|
+
function ei(e) {
|
|
4055
|
+
var s, d, c, u;
|
|
4020
4056
|
function t() {
|
|
4021
4057
|
return "div";
|
|
4022
4058
|
}
|
|
@@ -4024,31 +4060,31 @@ function Yn(e) {
|
|
|
4024
4060
|
return "div";
|
|
4025
4061
|
}
|
|
4026
4062
|
function i() {
|
|
4027
|
-
var
|
|
4063
|
+
var g, m;
|
|
4028
4064
|
return [
|
|
4029
|
-
e.attributes[
|
|
4065
|
+
e.attributes[_()],
|
|
4030
4066
|
"builder-symbol",
|
|
4031
|
-
(
|
|
4067
|
+
(g = e.symbol) != null && g.inline ? "builder-inline-symbol" : void 0,
|
|
4032
4068
|
(m = e.symbol) != null && m.dynamic || e.dynamic ? "builder-dynamic-symbol" : void 0
|
|
4033
4069
|
].filter(Boolean).join(" ");
|
|
4034
4070
|
}
|
|
4035
|
-
const [o,
|
|
4036
|
-
var
|
|
4037
|
-
return (
|
|
4071
|
+
const [o, a] = T(() => {
|
|
4072
|
+
var g;
|
|
4073
|
+
return (g = e.symbol) == null ? void 0 : g.content;
|
|
4038
4074
|
});
|
|
4039
|
-
function
|
|
4040
|
-
o ||
|
|
4075
|
+
function r() {
|
|
4076
|
+
o || Zn({
|
|
4041
4077
|
symbol: e.symbol,
|
|
4042
4078
|
builderContextValue: e.builderContext
|
|
4043
|
-
}).then((
|
|
4044
|
-
|
|
4079
|
+
}).then((g) => {
|
|
4080
|
+
g && a(g);
|
|
4045
4081
|
});
|
|
4046
4082
|
}
|
|
4047
4083
|
return P(() => {
|
|
4048
4084
|
}, []), P(() => {
|
|
4049
|
-
|
|
4050
|
-
}, [e.symbol]), /* @__PURE__ */
|
|
4051
|
-
|
|
4085
|
+
r();
|
|
4086
|
+
}, [e.symbol]), /* @__PURE__ */ l("div", { ...e.attributes, className: i(), children: /* @__PURE__ */ l(
|
|
4087
|
+
Xn,
|
|
4052
4088
|
{
|
|
4053
4089
|
nonce: e.builderContext.nonce,
|
|
4054
4090
|
isNestedRender: !0,
|
|
@@ -4056,16 +4092,16 @@ function Yn(e) {
|
|
|
4056
4092
|
apiKey: e.builderContext.apiKey,
|
|
4057
4093
|
context: {
|
|
4058
4094
|
...e.builderContext.context,
|
|
4059
|
-
symbolId: (
|
|
4095
|
+
symbolId: (s = e.builderBlock) == null ? void 0 : s.id
|
|
4060
4096
|
},
|
|
4061
4097
|
customComponents: Object.values(e.builderComponents),
|
|
4062
4098
|
data: {
|
|
4063
|
-
...(
|
|
4099
|
+
...(d = e.symbol) == null ? void 0 : d.data,
|
|
4064
4100
|
...e.builderContext.localState,
|
|
4065
|
-
...(
|
|
4101
|
+
...(c = o == null ? void 0 : o.data) == null ? void 0 : c.state
|
|
4066
4102
|
},
|
|
4067
4103
|
canTrack: e.builderContext.canTrack,
|
|
4068
|
-
model: (
|
|
4104
|
+
model: (u = e.symbol) == null ? void 0 : u.model,
|
|
4069
4105
|
content: o,
|
|
4070
4106
|
linkComponent: e.builderLinkComponent,
|
|
4071
4107
|
blocksWrapper: t(),
|
|
@@ -4076,13 +4112,13 @@ function Yn(e) {
|
|
|
4076
4112
|
export {
|
|
4077
4113
|
D as Blocks,
|
|
4078
4114
|
ue as BuilderContext,
|
|
4079
|
-
|
|
4080
|
-
|
|
4081
|
-
|
|
4082
|
-
|
|
4083
|
-
|
|
4084
|
-
|
|
4085
|
-
|
|
4086
|
-
|
|
4087
|
-
|
|
4115
|
+
it as Button,
|
|
4116
|
+
Mt as Columns,
|
|
4117
|
+
Xn as Content,
|
|
4118
|
+
jt as Fragment,
|
|
4119
|
+
qt as Image,
|
|
4120
|
+
_t as Section,
|
|
4121
|
+
ei as Symbol,
|
|
4122
|
+
ln as Text,
|
|
4123
|
+
Pn as Video
|
|
4088
4124
|
};
|