@builder.io/sdk-react 2.0.25 → 2.0.26
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 +5 -5
- package/lib/browser/blocks-exports.mjs +47 -41
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/{server-entry-350f7ecc.js → server-entry-720336f2.js} +138 -135
- package/lib/browser/server-entry-f2c8ba91.cjs +2 -0
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/{accordion-e2aeca0a.js → accordion-0a97d42c.js} +1 -1
- package/lib/edge/{accordion-d14d05aa.cjs → accordion-e8975004.cjs} +1 -1
- package/lib/edge/{blocks-5a60a8fa.cjs → blocks-13ac260d.cjs} +1 -1
- package/lib/edge/{blocks-9a763eda.js → blocks-79d4ca8d.js} +3 -3
- package/lib/edge/blocks-exports.cjs +1 -1
- package/lib/edge/blocks-exports.mjs +2 -2
- package/lib/edge/{button-265653d5.js → button-17d873fa.js} +2 -2
- package/lib/edge/{button-6ab0c490.cjs → button-a01a8a04.cjs} +1 -1
- package/lib/edge/{columns-346d4ab7.js → columns-b8bb106c.js} +4 -4
- package/lib/edge/{columns-449335a4.cjs → columns-c4c26bf0.cjs} +1 -1
- package/lib/edge/{content-variants-71459280.cjs → content-variants-32296e48.cjs} +8 -8
- package/lib/edge/{content-variants-bdb3d738.js → content-variants-6560c3c8.js} +51 -45
- package/lib/edge/{evaluate-be86a5d8.js → evaluate-1c58cb0f.js} +1 -1
- package/lib/edge/{evaluate-db1f9237.cjs → evaluate-92fb6615.cjs} +1 -1
- package/lib/edge/{form-90310cab.cjs → form-11832191.cjs} +1 -1
- package/lib/edge/{form-41305e00.js → form-d8609725.js} +4 -4
- package/lib/edge/{get-class-prop-name-b49b7684.js → get-class-prop-name-1dd91564.js} +1 -1
- package/lib/edge/{get-class-prop-name-711d58eb.cjs → get-class-prop-name-e5b5610b.cjs} +1 -1
- package/lib/edge/{img-a75bf17b.js → img-bf66df07.js} +1 -1
- package/lib/edge/{img-1ab7ba48.cjs → img-d044ae25.cjs} +1 -1
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/{input-137d07aa.cjs → input-9340f0ba.cjs} +1 -1
- package/lib/edge/{input-6c50146c.js → input-ab613ef1.js} +1 -1
- package/lib/edge/{select-b6c2fdd5.js → select-c9f8f72d.js} +1 -1
- package/lib/edge/{select-55d2c8fa.cjs → select-cda5352c.cjs} +1 -1
- package/lib/edge/server-entry-4d4f2c4b.cjs +2 -0
- package/lib/edge/{server-entry-e914f16e.js → server-entry-c809a8ff.js} +138 -135
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/edge/{slot-84e40920.js → slot-69765c02.js} +4 -4
- package/lib/edge/{slot-8d3b7707.cjs → slot-b66c52dc.cjs} +1 -1
- package/lib/edge/{symbol-468348d8.cjs → symbol-1b3f8d1f.cjs} +1 -1
- package/lib/edge/{symbol-7436ff06.js → symbol-335cfb65.js} +2 -2
- package/lib/edge/{tabs-65d455da.js → tabs-629e6a1f.js} +4 -4
- package/lib/edge/{tabs-802a32f0.cjs → tabs-bf6cc6f2.cjs} +1 -1
- package/lib/edge/{text-423e3303.js → text-2d218073.js} +2 -2
- package/lib/edge/{text-450bf7e4.cjs → text-ff5a8f9b.cjs} +1 -1
- package/lib/node/blocks-exports.cjs +7 -7
- package/lib/node/blocks-exports.mjs +49 -43
- 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/{server-entry-569f32b2.js → server-entry-12c82a21.js} +138 -135
- package/lib/node/server-entry-ac34c1ae.cjs +2 -0
- package/lib/node/server-entry.cjs +1 -1
- package/lib/node/server-entry.mjs +1 -1
- package/lib/node/{should-force-browser-runtime-in-node-13070d3a.cjs → should-force-browser-runtime-in-node-1e38f5d9.cjs} +1 -1
- package/lib/node/{should-force-browser-runtime-in-node-3f610831.js → should-force-browser-runtime-in-node-94a10439.js} +1 -1
- package/package.json +1 -1
- package/types/components/content/components/enable-editor.d.ts +1 -1
- package/types/components/content-variants/content-variants.types.d.ts +4 -0
- package/types/constants/sdk-version.d.ts +1 -1
- package/types/functions/get-content/types.d.ts +4 -0
- package/types/functions/track/index.d.ts +3 -1
- package/lib/browser/server-entry-f8b08c1e.cjs +0 -2
- package/lib/edge/server-entry-ae44ef40.cjs +0 -2
- package/lib/node/server-entry-781dde88.cjs +0 -2
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx as l, Fragment as w, jsxs as V } from "react/jsx-runtime";
|
|
3
|
-
import { TARGET as D, isBrowser as
|
|
3
|
+
import { TARGET as D, isBrowser as _, logger as ne, checkIsDefined as Z, isPreviewing as xe, isEditing as N, registerInsertMenu as Le, setupBrowserForEditing as Oe, createRegisterComponentMessage as Ue, getDefaultCanTrack as q, _track as le, fetchOneEntry as ve, createEditorListener as He, serializeIncludingFunctions as se, handleABTestingSync as je } from "./server-entry-12c82a21.js";
|
|
4
4
|
import { createContext as Se, useEffect as B, useState as T, useRef as $, useContext as ce, createElement as ke } from "react";
|
|
5
|
-
import { getFunctionArguments as
|
|
5
|
+
import { getFunctionArguments as Me, flattenState as _e, shouldForceBrowserRuntimeInNode as qe, runInNode as Ke, parseCode as ze, getBuilderGlobals as Je, set as Ce, fastClone as ie } from "./should-force-browser-runtime-in-node-94a10439.js";
|
|
6
6
|
const Ge = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), Ye = (e) => typeof e == "string" && Ge.has(e.toLowerCase());
|
|
7
7
|
function oe(e) {
|
|
8
8
|
return /* @__PURE__ */ l(w, { children: Ye(e.TagName) ? /* @__PURE__ */ l(w, { children: /* @__PURE__ */ l(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ l(w, { 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 }) }) });
|
|
@@ -85,18 +85,18 @@ const Ie = (e, t, n) => {
|
|
|
85
85
|
rootSetState: a,
|
|
86
86
|
rootState: r
|
|
87
87
|
}) => {
|
|
88
|
-
const s =
|
|
88
|
+
const s = Me({
|
|
89
89
|
builder: t,
|
|
90
90
|
context: n,
|
|
91
91
|
event: i,
|
|
92
|
-
state:
|
|
92
|
+
state: _e({
|
|
93
93
|
rootState: r,
|
|
94
94
|
localState: o,
|
|
95
95
|
rootSetState: a
|
|
96
96
|
})
|
|
97
97
|
});
|
|
98
98
|
return new Function(...s.map(([d]) => d), e)(...s.map(([, d]) => d));
|
|
99
|
-
}, tt = (e) =>
|
|
99
|
+
}, tt = (e) => _() || qe({
|
|
100
100
|
shouldLogWarning: !0
|
|
101
101
|
}) ? et(e) : Ke(e), nt = /^(return )?(\s*)?state(?<getPath>(\.\w+)+)(\s*);?$/, it = /(\s)*var(\s)+_virtual_index(\s)*=(\s)*state(?<getPath>(\.\w+)+)(\s*);?(\s)*return(\s)*_virtual_index(\s)*/, ot = (e) => {
|
|
102
102
|
var t, n, i, o, a, r;
|
|
@@ -319,7 +319,7 @@ const Pe = (e) => Object.entries(e).map(([n, i]) => {
|
|
|
319
319
|
if (typeof i == "string")
|
|
320
320
|
return `${K(n)}: ${i};`;
|
|
321
321
|
}).filter(Z), ft = (e) => Pe(e).join(`
|
|
322
|
-
`),
|
|
322
|
+
`), j = ({
|
|
323
323
|
mediaQuery: e,
|
|
324
324
|
className: t,
|
|
325
325
|
styles: n
|
|
@@ -490,17 +490,17 @@ function kt(e) {
|
|
|
490
490
|
), s = o == null ? void 0 : o.large, d = o == null ? void 0 : o.medium, c = o == null ? void 0 : o.small, h = i.id;
|
|
491
491
|
if (!h)
|
|
492
492
|
return "";
|
|
493
|
-
const b = s ?
|
|
493
|
+
const b = s ? j({
|
|
494
494
|
className: h,
|
|
495
495
|
styles: s
|
|
496
|
-
}) : "", f = d ?
|
|
496
|
+
}) : "", f = d ? j({
|
|
497
497
|
className: h,
|
|
498
498
|
styles: d,
|
|
499
499
|
mediaQuery: de(
|
|
500
500
|
"medium",
|
|
501
501
|
r
|
|
502
502
|
)
|
|
503
|
-
}) : "", v = c ?
|
|
503
|
+
}) : "", v = c ? j({
|
|
504
504
|
className: h,
|
|
505
505
|
styles: c,
|
|
506
506
|
mediaQuery: de(
|
|
@@ -511,7 +511,7 @@ function kt(e) {
|
|
|
511
511
|
let S = "";
|
|
512
512
|
if (g) {
|
|
513
513
|
const k = ((C = (R = g.steps) == null ? void 0 : R[1]) == null ? void 0 : C.styles) || {};
|
|
514
|
-
S =
|
|
514
|
+
S = j({
|
|
515
515
|
className: `${h}:hover`,
|
|
516
516
|
styles: {
|
|
517
517
|
...k,
|
|
@@ -701,7 +701,7 @@ function ue(e) {
|
|
|
701
701
|
contextValue: e.context
|
|
702
702
|
}),
|
|
703
703
|
children: (i = e.blockChildren) == null ? void 0 : i.map((o) => /* @__PURE__ */ l(
|
|
704
|
-
|
|
704
|
+
H,
|
|
705
705
|
{
|
|
706
706
|
block: o,
|
|
707
707
|
context: e.context,
|
|
@@ -716,7 +716,7 @@ function ue(e) {
|
|
|
716
716
|
function me(e) {
|
|
717
717
|
const [t, n] = T(() => e.repeatContext);
|
|
718
718
|
return /* @__PURE__ */ l(ae.Provider, { value: t, children: /* @__PURE__ */ l(
|
|
719
|
-
|
|
719
|
+
H,
|
|
720
720
|
{
|
|
721
721
|
block: e.block,
|
|
722
722
|
context: t,
|
|
@@ -725,7 +725,7 @@ function me(e) {
|
|
|
725
725
|
}
|
|
726
726
|
) });
|
|
727
727
|
}
|
|
728
|
-
function
|
|
728
|
+
function H(e) {
|
|
729
729
|
var h, b, f, v;
|
|
730
730
|
function t() {
|
|
731
731
|
return pt({
|
|
@@ -860,7 +860,7 @@ function j(e) {
|
|
|
860
860
|
}
|
|
861
861
|
),
|
|
862
862
|
(b = d()) == null ? void 0 : b.map((g) => /* @__PURE__ */ l(
|
|
863
|
-
|
|
863
|
+
H,
|
|
864
864
|
{
|
|
865
865
|
block: g,
|
|
866
866
|
registeredComponents: e.registeredComponents,
|
|
@@ -948,7 +948,7 @@ function F(e) {
|
|
|
948
948
|
BlocksWrapper: ((i = e.context) == null ? void 0 : i.BlocksWrapper) || (t == null ? void 0 : t.BlocksWrapper),
|
|
949
949
|
BlocksWrapperProps: ((o = e.context) == null ? void 0 : o.BlocksWrapperProps) || (t == null ? void 0 : t.BlocksWrapperProps),
|
|
950
950
|
children: e.blocks ? /* @__PURE__ */ l(w, { children: (a = e.blocks) == null ? void 0 : a.map((r) => /* @__PURE__ */ l(
|
|
951
|
-
|
|
951
|
+
H,
|
|
952
952
|
{
|
|
953
953
|
block: r,
|
|
954
954
|
linkComponent: e.linkComponent,
|
|
@@ -1387,7 +1387,7 @@ const G = {
|
|
|
1387
1387
|
builderLinkComponent: !0
|
|
1388
1388
|
}
|
|
1389
1389
|
}, he = (e) => e.toString();
|
|
1390
|
-
function
|
|
1390
|
+
function Ht(e) {
|
|
1391
1391
|
var b;
|
|
1392
1392
|
const [t, n] = T(() => []);
|
|
1393
1393
|
function i() {
|
|
@@ -1510,7 +1510,7 @@ function jt(e) {
|
|
|
1510
1510
|
) : null
|
|
1511
1511
|
] })) });
|
|
1512
1512
|
}
|
|
1513
|
-
const
|
|
1513
|
+
const jt = {
|
|
1514
1514
|
name: "Core:Button",
|
|
1515
1515
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
1516
1516
|
defaultStyles: {
|
|
@@ -1546,7 +1546,7 @@ const Mt = {
|
|
|
1546
1546
|
shouldReceiveBuilderProps: {
|
|
1547
1547
|
builderLinkComponent: !0
|
|
1548
1548
|
}
|
|
1549
|
-
},
|
|
1549
|
+
}, Mt = {
|
|
1550
1550
|
// TODO: ways to statically preprocess JSON for references, functions, etc
|
|
1551
1551
|
name: "Columns",
|
|
1552
1552
|
isRSC: !0,
|
|
@@ -1753,7 +1753,7 @@ const Mt = {
|
|
|
1753
1753
|
builderComponents: !0,
|
|
1754
1754
|
builderLinkComponent: !0
|
|
1755
1755
|
}
|
|
1756
|
-
},
|
|
1756
|
+
}, _t = {
|
|
1757
1757
|
name: "Fragment",
|
|
1758
1758
|
static: !0,
|
|
1759
1759
|
hidden: !0,
|
|
@@ -2714,7 +2714,7 @@ function dn(e) {
|
|
|
2714
2714
|
...e.attributes,
|
|
2715
2715
|
children: [
|
|
2716
2716
|
e.builderBlock && e.builderBlock.children ? /* @__PURE__ */ l(w, { children: (f = (b = e.builderBlock) == null ? void 0 : b.children) == null ? void 0 : f.map((v, g) => /* @__PURE__ */ l(
|
|
2717
|
-
|
|
2717
|
+
H,
|
|
2718
2718
|
{
|
|
2719
2719
|
block: v,
|
|
2720
2720
|
context: e.builderContext,
|
|
@@ -3205,13 +3205,13 @@ const Cn = () => [{
|
|
|
3205
3205
|
...Sn
|
|
3206
3206
|
}], ge = () => [{
|
|
3207
3207
|
component: Qe,
|
|
3208
|
-
...
|
|
3208
|
+
...jt
|
|
3209
3209
|
}, {
|
|
3210
3210
|
component: Nt,
|
|
3211
|
-
...
|
|
3211
|
+
...Mt
|
|
3212
3212
|
}, {
|
|
3213
3213
|
component: Ft,
|
|
3214
|
-
...
|
|
3214
|
+
..._t
|
|
3215
3215
|
}, {
|
|
3216
3216
|
component: Lt,
|
|
3217
3217
|
...qt
|
|
@@ -3231,7 +3231,7 @@ const Cn = () => [{
|
|
|
3231
3231
|
component: Qt,
|
|
3232
3232
|
...Yt
|
|
3233
3233
|
}, {
|
|
3234
|
-
component:
|
|
3234
|
+
component: Ht,
|
|
3235
3235
|
...Ut
|
|
3236
3236
|
}, ...Cn()], Tn = `function updateCookiesAndStyles(contentId, variants, isHydrationTarget) {
|
|
3237
3237
|
function getAndSetVariantId() {
|
|
@@ -3323,14 +3323,14 @@ const Cn = () => [{
|
|
|
3323
3323
|
thisScriptEl?.remove();
|
|
3324
3324
|
}
|
|
3325
3325
|
return;
|
|
3326
|
-
}`, Ne = "builderIoAbTest", Fe = "builderIoRenderContent",
|
|
3326
|
+
}`, Ne = "builderIoAbTest", Fe = "builderIoRenderContent", M = (e) => Object.values((e == null ? void 0 : e.variations) || {}).map((t) => ({
|
|
3327
3327
|
...t,
|
|
3328
3328
|
testVariationId: t.id,
|
|
3329
3329
|
id: e == null ? void 0 : e.id
|
|
3330
3330
|
})), wn = ({
|
|
3331
3331
|
canTrack: e,
|
|
3332
3332
|
content: t
|
|
3333
|
-
}) => !(!(
|
|
3333
|
+
}) => !(!(M(t).length > 0) || !e || _()), En = (e) => e === "react" || e === "reactNative", $e = En(D), Rn = () => `
|
|
3334
3334
|
window.${Ne} = ${Tn}
|
|
3335
3335
|
window.${Fe} = ${In}
|
|
3336
3336
|
`, Pn = (e, t) => `
|
|
@@ -3490,7 +3490,7 @@ function Un(e) {
|
|
|
3490
3490
|
() => e.contentWrapper || "div"
|
|
3491
3491
|
);
|
|
3492
3492
|
function s(m) {
|
|
3493
|
-
return
|
|
3493
|
+
return He({
|
|
3494
3494
|
model: e.model,
|
|
3495
3495
|
trustedHosts: e.trustedHosts,
|
|
3496
3496
|
callbacks: {
|
|
@@ -3518,6 +3518,7 @@ function Un(e) {
|
|
|
3518
3518
|
if (e.builderContextSignal.content) {
|
|
3519
3519
|
const u = (y = e.builderContextSignal.content) == null ? void 0 : y.testVariationId, p = (I = e.builderContextSignal.content) == null ? void 0 : I.id;
|
|
3520
3520
|
le({
|
|
3521
|
+
apiHost: e.apiHost,
|
|
3521
3522
|
type: "click",
|
|
3522
3523
|
canTrack: q(e.canTrack),
|
|
3523
3524
|
contentId: p,
|
|
@@ -3577,8 +3578,8 @@ function Un(e) {
|
|
|
3577
3578
|
const R = $(!1);
|
|
3578
3579
|
return R.current || (S(), x(), R.current = !0), B(() => {
|
|
3579
3580
|
var m, y;
|
|
3580
|
-
if (
|
|
3581
|
-
if (N() && (window.addEventListener("message", s), Le(), Oe({
|
|
3581
|
+
if (_()) {
|
|
3582
|
+
if (N() && !e.isNestedRender && (window.addEventListener("message", s), Le(), Oe({
|
|
3582
3583
|
...e.locale ? {
|
|
3583
3584
|
locale: e.locale
|
|
3584
3585
|
} : {},
|
|
@@ -3600,6 +3601,7 @@ function Un(e) {
|
|
|
3600
3601
|
)), e.builderContextSignal.content && q(e.canTrack)) {
|
|
3601
3602
|
const u = (m = e.builderContextSignal.content) == null ? void 0 : m.testVariationId, p = (y = e.builderContextSignal.content) == null ? void 0 : y.id, E = e.apiKey;
|
|
3602
3603
|
le({
|
|
3604
|
+
apiHost: e.apiHost,
|
|
3603
3605
|
type: "impression",
|
|
3604
3606
|
canTrack: !0,
|
|
3605
3607
|
contentId: p,
|
|
@@ -3631,7 +3633,7 @@ function Un(e) {
|
|
|
3631
3633
|
locale: e.locale
|
|
3632
3634
|
});
|
|
3633
3635
|
}, [e.locale]), B(() => () => {
|
|
3634
|
-
|
|
3636
|
+
_() && (window.removeEventListener("message", s), window.removeEventListener(
|
|
3635
3637
|
"builder:component:stateChangeListenerActivated",
|
|
3636
3638
|
x
|
|
3637
3639
|
));
|
|
@@ -3651,7 +3653,7 @@ function Un(e) {
|
|
|
3651
3653
|
}
|
|
3652
3654
|
) : null });
|
|
3653
3655
|
}
|
|
3654
|
-
function
|
|
3656
|
+
function Hn(e) {
|
|
3655
3657
|
const [t, n] = T(
|
|
3656
3658
|
() => `
|
|
3657
3659
|
${$n({
|
|
@@ -3673,7 +3675,7 @@ ${Ln(e.isNestedRender)}
|
|
|
3673
3675
|
}
|
|
3674
3676
|
);
|
|
3675
3677
|
}
|
|
3676
|
-
const
|
|
3678
|
+
const jn = ({
|
|
3677
3679
|
content: e,
|
|
3678
3680
|
data: t,
|
|
3679
3681
|
locale: n
|
|
@@ -3690,7 +3692,7 @@ const Mn = ({
|
|
|
3690
3692
|
locale: n
|
|
3691
3693
|
} : {}
|
|
3692
3694
|
};
|
|
3693
|
-
},
|
|
3695
|
+
}, Mn = ({
|
|
3694
3696
|
content: e,
|
|
3695
3697
|
data: t
|
|
3696
3698
|
}) => e ? {
|
|
@@ -3740,12 +3742,12 @@ function ye(e) {
|
|
|
3740
3742
|
), [r, s] = T(() => {
|
|
3741
3743
|
var C;
|
|
3742
3744
|
return {
|
|
3743
|
-
content:
|
|
3745
|
+
content: Mn({
|
|
3744
3746
|
content: e.content,
|
|
3745
3747
|
data: e.data
|
|
3746
3748
|
}),
|
|
3747
3749
|
localState: void 0,
|
|
3748
|
-
rootState:
|
|
3750
|
+
rootState: jn({
|
|
3749
3751
|
content: e.content,
|
|
3750
3752
|
data: e.data,
|
|
3751
3753
|
locale: e.locale
|
|
@@ -3796,6 +3798,7 @@ function ye(e) {
|
|
|
3796
3798
|
children: /* @__PURE__ */ V(
|
|
3797
3799
|
Un,
|
|
3798
3800
|
{
|
|
3801
|
+
apiHost: e.apiHost,
|
|
3799
3802
|
nonce: e.nonce,
|
|
3800
3803
|
content: e.content,
|
|
3801
3804
|
data: e.data,
|
|
@@ -3810,6 +3813,7 @@ function ye(e) {
|
|
|
3810
3813
|
contentWrapper: e.contentWrapper,
|
|
3811
3814
|
contentWrapperProps: e.contentWrapperProps,
|
|
3812
3815
|
trustedHosts: e.trustedHosts,
|
|
3816
|
+
isNestedRender: e.isNestedRender,
|
|
3813
3817
|
setBuilderContextSignal: s,
|
|
3814
3818
|
children: [
|
|
3815
3819
|
e.isSsrAbTest ? /* @__PURE__ */ l(
|
|
@@ -3821,7 +3825,7 @@ function ye(e) {
|
|
|
3821
3825
|
}
|
|
3822
3826
|
) : null,
|
|
3823
3827
|
/* @__PURE__ */ l(
|
|
3824
|
-
|
|
3828
|
+
Hn,
|
|
3825
3829
|
{
|
|
3826
3830
|
nonce: e.nonce || "",
|
|
3827
3831
|
isNestedRender: e.isNestedRender,
|
|
@@ -3845,7 +3849,7 @@ function ye(e) {
|
|
|
3845
3849
|
}
|
|
3846
3850
|
);
|
|
3847
3851
|
}
|
|
3848
|
-
function
|
|
3852
|
+
function _n(e) {
|
|
3849
3853
|
var r;
|
|
3850
3854
|
const [t, n] = T(
|
|
3851
3855
|
() => wn({
|
|
@@ -3856,7 +3860,7 @@ function Hn(e) {
|
|
|
3856
3860
|
function i() {
|
|
3857
3861
|
var s;
|
|
3858
3862
|
return Pn(
|
|
3859
|
-
|
|
3863
|
+
M(e.content).map((d) => ({
|
|
3860
3864
|
id: d.testVariationId,
|
|
3861
3865
|
testRatio: d.testRatio
|
|
3862
3866
|
})),
|
|
@@ -3864,14 +3868,14 @@ function Hn(e) {
|
|
|
3864
3868
|
);
|
|
3865
3869
|
}
|
|
3866
3870
|
function o() {
|
|
3867
|
-
return
|
|
3871
|
+
return M(e.content).map((s) => `.variant-${s.testVariationId} { display: none; } `).join("");
|
|
3868
3872
|
}
|
|
3869
3873
|
function a() {
|
|
3870
3874
|
var s;
|
|
3871
3875
|
return t ? {
|
|
3872
3876
|
...e.content,
|
|
3873
3877
|
testVariationId: (s = e.content) == null ? void 0 : s.id
|
|
3874
|
-
} :
|
|
3878
|
+
} : je({
|
|
3875
3879
|
item: e.content,
|
|
3876
3880
|
canTrack: q(e.canTrack)
|
|
3877
3881
|
});
|
|
@@ -3903,9 +3907,10 @@ function Hn(e) {
|
|
|
3903
3907
|
nonce: e.nonce || ""
|
|
3904
3908
|
}
|
|
3905
3909
|
),
|
|
3906
|
-
(r =
|
|
3910
|
+
(r = M(e.content)) == null ? void 0 : r.map((s) => /* @__PURE__ */ l(
|
|
3907
3911
|
ye,
|
|
3908
3912
|
{
|
|
3913
|
+
apiHost: e.apiHost,
|
|
3909
3914
|
isNestedRender: e.isNestedRender,
|
|
3910
3915
|
nonce: e.nonce,
|
|
3911
3916
|
content: s,
|
|
@@ -3933,6 +3938,7 @@ function Hn(e) {
|
|
|
3933
3938
|
/* @__PURE__ */ l(
|
|
3934
3939
|
ye,
|
|
3935
3940
|
{
|
|
3941
|
+
apiHost: e.apiHost,
|
|
3936
3942
|
nonce: e.nonce,
|
|
3937
3943
|
isNestedRender: e.isNestedRender,
|
|
3938
3944
|
content: a(),
|
|
@@ -4009,7 +4015,7 @@ function Kn(e) {
|
|
|
4009
4015
|
}, []), B(() => {
|
|
4010
4016
|
r();
|
|
4011
4017
|
}, [e.symbol]), /* @__PURE__ */ l("div", { ...e.attributes, className: i(), children: /* @__PURE__ */ l(
|
|
4012
|
-
|
|
4018
|
+
_n,
|
|
4013
4019
|
{
|
|
4014
4020
|
nonce: e.builderContext.nonce,
|
|
4015
4021
|
isNestedRender: !0,
|
|
@@ -4039,7 +4045,7 @@ export {
|
|
|
4039
4045
|
ae as BuilderContext,
|
|
4040
4046
|
Qe as Button,
|
|
4041
4047
|
Nt as Columns,
|
|
4042
|
-
|
|
4048
|
+
_n as Content,
|
|
4043
4049
|
Ft as Fragment,
|
|
4044
4050
|
Lt as Image,
|
|
4045
4051
|
Ot as Section,
|
package/lib/node/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./blocks-exports.cjs"),e=require("./server-entry-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./blocks-exports.cjs"),e=require("./server-entry-ac34c1ae.cjs");require("react/jsx-runtime");require("react");require("./should-force-browser-runtime-in-node-1e38f5d9.cjs");exports.Blocks=t.Blocks;exports.BuilderContext=t.BuilderContext;exports.Button=t.Button;exports.Columns=t.Columns;exports.Content=t.Content;exports.Fragment=t.Fragment;exports.Image=t.Image;exports.Section=t.Section;exports.Symbol=t.Symbol;exports.Text=t.Text;exports.Video=t.Video;exports._processContentResult=e._processContentResult;exports.createRegisterComponentMessage=e.createRegisterComponentMessage;exports.fetchBuilderProps=e.fetchBuilderProps;exports.fetchEntries=e.fetchEntries;exports.fetchOneEntry=e.fetchOneEntry;exports.getBuilderSearchParams=e.getBuilderSearchParams;exports.isEditing=e.isEditing;exports.isPreviewing=e.isPreviewing;exports.register=e.register;exports.setEditorSettings=e.setEditorSettings;exports.subscribeToEditor=e.subscribeToEditor;exports.track=e.track;
|
package/lib/node/index.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Blocks as s, BuilderContext as n, Button as m, Columns as c, Content as g, Fragment as a, Image as p, Section as d, Symbol as l, Text as u, Video as f } from "./blocks-exports.mjs";
|
|
2
|
-
import { _processContentResult as C, createRegisterComponentMessage as E, fetchBuilderProps as h, fetchEntries as x, fetchOneEntry as S, getBuilderSearchParams as b, isEditing as P, isPreviewing as k, register as y, setEditorSettings as R, subscribeToEditor as T, track as v } from "./server-entry-
|
|
2
|
+
import { _processContentResult as C, createRegisterComponentMessage as E, fetchBuilderProps as h, fetchEntries as x, fetchOneEntry as S, getBuilderSearchParams as b, isEditing as P, isPreviewing as k, register as y, setEditorSettings as R, subscribeToEditor as T, track as v } from "./server-entry-12c82a21.js";
|
|
3
3
|
import "react/jsx-runtime";
|
|
4
4
|
import "react";
|
|
5
|
-
import "./should-force-browser-runtime-in-node-
|
|
5
|
+
import "./should-force-browser-runtime-in-node-94a10439.js";
|
|
6
6
|
export {
|
|
7
7
|
s as Blocks,
|
|
8
8
|
n as BuilderContext,
|
package/lib/node/init.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./should-force-browser-runtime-in-node-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./should-force-browser-runtime-in-node-1e38f5d9.cjs"),t=require("isolated-vm");require("./server-entry-ac34c1ae.cjs");const r=i=>{if(e.shouldForceBrowserRuntimeInNode({shouldLogWarning:!0}))return;const{ivmIsolateOptions:o}=i||{};e.setIvm(t,o)};exports.initializeNodeRuntime=r;
|
package/lib/node/init.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { shouldForceBrowserRuntimeInNode as t, setIvm as r } from "./should-force-browser-runtime-in-node-
|
|
1
|
+
import { shouldForceBrowserRuntimeInNode as t, setIvm as r } from "./should-force-browser-runtime-in-node-94a10439.js";
|
|
2
2
|
import e from "isolated-vm";
|
|
3
|
-
import "./server-entry-
|
|
3
|
+
import "./server-entry-12c82a21.js";
|
|
4
4
|
const u = (o) => {
|
|
5
5
|
if (t({
|
|
6
6
|
shouldLogWarning: !0
|