@builder.io/sdk-react-nextjs 0.19.2 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,282 +1,304 @@
1
1
  "use client";
2
- import { jsx as k } from "react/jsx-runtime";
3
- import { useRef as P, useState as m, useEffect as c } from "react";
4
- import O from "../../../context/builder.context.mjs";
5
- import { evaluate as W } from "../../../functions/evaluate/evaluate.mjs";
6
- import { fastClone as j } from "../../../functions/fast-clone.mjs";
7
- import { fetchOneEntry as A } from "../../../functions/get-content/index.mjs";
8
- import { isBrowser as L } from "../../../functions/is-browser.mjs";
9
- import { isEditing as g } from "../../../functions/is-editing.mjs";
10
- import { isPreviewing as B } from "../../../functions/is-previewing.mjs";
11
- import { logFetch as F } from "../../../functions/log-fetch.mjs";
12
- import { createRegisterComponentMessage as M } from "../../../functions/register-component.mjs";
13
- import { _track as H } from "../../../functions/track/index.mjs";
14
- import { getInteractionPropertiesForEvent as $ } from "../../../functions/track/interaction.mjs";
15
- import { getDefaultCanTrack as K } from "../../../helpers/canTrack.mjs";
16
- import { getCookieSync as z } from "../../../helpers/cookie.mjs";
17
- import { postPreviewContent as G } from "../../../helpers/preview-lru-cache/set.mjs";
18
- import { createEditorListener as J } from "../../../helpers/subscribe-to-editor.mjs";
19
- import { setupBrowserForEditing as Q } from "../../../scripts/init-editing.mjs";
20
- import { triggerAnimation as X } from "../../block/animator.mjs";
21
- import { needsElementRefDivForEditing as q } from "./enable-editor.helpers.mjs";
22
- import { getWrapperClassName as Y } from "./styles.helpers.mjs";
23
- import { useRouter as Z } from "next/navigation";
24
- function yt(t) {
25
- var w, y, R;
26
- const u = P(null);
27
- m(() => !1);
28
- function s(n) {
2
+ import { jsx as H } from "react/jsx-runtime";
3
+ import { useRef as K, useState as s, useEffect as l } from "react";
4
+ import A from "../../../context/builder.context.mjs";
5
+ import { evaluate as B } from "../../../functions/evaluate/evaluate.mjs";
6
+ import { fastClone as F } from "../../../functions/fast-clone.mjs";
7
+ import { fetchOneEntry as M } from "../../../functions/get-content/index.mjs";
8
+ import { isBrowser as T } from "../../../functions/is-browser.mjs";
9
+ import { isEditing as b } from "../../../functions/is-editing.mjs";
10
+ import { isPreviewing as J } from "../../../functions/is-previewing.mjs";
11
+ import { logFetch as $ } from "../../../functions/log-fetch.mjs";
12
+ import { createRegisterComponentMessage as z } from "../../../functions/register-component.mjs";
13
+ import { _track as U } from "../../../functions/track/index.mjs";
14
+ import { getInteractionPropertiesForEvent as G } from "../../../functions/track/interaction.mjs";
15
+ import { getDefaultCanTrack as q } from "../../../helpers/canTrack.mjs";
16
+ import { getCookieSync as Q } from "../../../helpers/cookie.mjs";
17
+ import { postPreviewContent as X } from "../../../helpers/preview-lru-cache/set.mjs";
18
+ import { createEditorListener as Y } from "../../../helpers/subscribe-to-editor.mjs";
19
+ import { setupBrowserForEditing as Z } from "../../../scripts/init-editing.mjs";
20
+ import { triggerAnimation as p } from "../../block/animator.mjs";
21
+ import { needsElementRefDivForEditing as D } from "./enable-editor.helpers.mjs";
22
+ import { getWrapperClassName as ee } from "./styles.helpers.mjs";
23
+ import { useRouter as te } from "next/navigation";
24
+ function Le(e) {
25
+ var k, P, L;
26
+ const c = K(null);
27
+ s(() => !1);
28
+ function f(n) {
29
29
  var i, o;
30
- const e = {
31
- ...t.builderContextSignal.rootState,
30
+ const t = {
31
+ ...e.builderContextSignal.rootState,
32
32
  ...n
33
33
  };
34
- t.builderContextSignal.rootSetState ? (o = (i = t.builderContextSignal).rootSetState) == null || o.call(i, e) : t.builderContextSignal.rootState = e;
34
+ e.builderContextSignal.rootSetState ? (o = (i = e.builderContextSignal).rootSetState) == null || o.call(i, t) : e.builderContextSignal.rootState = t;
35
35
  }
36
- function b(n) {
36
+ function S(n) {
37
37
  var i, o, a, r, d;
38
- const e = {
39
- ...t.builderContextSignal.content,
38
+ const t = {
39
+ ...e.builderContextSignal.content,
40
40
  ...n,
41
41
  data: {
42
- ...(i = t.builderContextSignal.content) == null ? void 0 : i.data,
42
+ ...(i = e.builderContextSignal.content) == null ? void 0 : i.data,
43
43
  ...n == null ? void 0 : n.data
44
44
  },
45
45
  meta: {
46
- ...(o = t.builderContextSignal.content) == null ? void 0 : o.meta,
46
+ ...(o = e.builderContextSignal.content) == null ? void 0 : o.meta,
47
47
  ...n == null ? void 0 : n.meta,
48
- breakpoints: ((a = n == null ? void 0 : n.meta) == null ? void 0 : a.breakpoints) || ((d = (r = t.builderContextSignal.content) == null ? void 0 : r.meta) == null ? void 0 : d.breakpoints)
48
+ breakpoints: ((a = n == null ? void 0 : n.meta) == null ? void 0 : a.breakpoints) || ((d = (r = e.builderContextSignal.content) == null ? void 0 : r.meta) == null ? void 0 : d.breakpoints)
49
49
  }
50
50
  };
51
- G({
52
- value: e,
53
- key: e.id,
51
+ X({
52
+ value: t,
53
+ key: t.id,
54
54
  url: window.location.pathname
55
55
  });
56
56
  }
57
- function T() {
58
- return t.showContent ? {} : {
57
+ function N() {
58
+ return e.showContent ? {} : {
59
59
  hidden: !0,
60
60
  "aria-hidden": !0
61
61
  };
62
62
  }
63
- const [U, p] = m(
64
- () => t.contentWrapper || "div"
63
+ const [O, ne] = s(
64
+ () => e.contentWrapper || "div"
65
65
  );
66
- function v(n) {
67
- return J({
68
- model: t.model,
69
- trustedHosts: t.trustedHosts,
66
+ function x(n) {
67
+ return Y({
68
+ model: e.model,
69
+ trustedHosts: e.trustedHosts,
70
70
  callbacks: {
71
- configureSdk: (e) => {
71
+ configureSdk: (t) => {
72
72
  var a;
73
- const { breakpoints: i, contentId: o } = e;
74
- !o || o !== ((a = t.builderContextSignal.content) == null ? void 0 : a.id) || i && b({
73
+ const { breakpoints: i, contentId: o } = t;
74
+ !o || o !== ((a = e.builderContextSignal.content) == null ? void 0 : a.id) || i && S({
75
75
  meta: {
76
76
  breakpoints: i
77
77
  }
78
78
  });
79
79
  },
80
- animation: (e) => {
81
- X(e);
80
+ animation: (t) => {
81
+ p(t);
82
82
  },
83
- contentUpdate: (e) => {
84
- b(e);
83
+ contentUpdate: (t) => {
84
+ S(t);
85
85
  },
86
- stateUpdate: (e) => {
87
- s(e);
86
+ stateUpdate: (t) => {
87
+ f(t);
88
88
  }
89
89
  }
90
90
  })(n);
91
91
  }
92
- const [h, tt] = m(() => ({})), [S, et] = m(() => ({})), [x, D] = m(() => !1);
93
- function V(n) {
94
- var e, i;
95
- if (t.builderContextSignal.content) {
96
- const o = (e = t.builderContextSignal.content) == null ? void 0 : e.testVariationId, a = (i = t.builderContextSignal.content) == null ? void 0 : i.id;
97
- H({
98
- apiHost: t.apiHost,
92
+ const [C, ie] = s(() => ({})), [v, ae] = s(() => ({})), [y, V] = s(() => !1);
93
+ function j(n) {
94
+ var t, i;
95
+ if (e.builderContextSignal.content) {
96
+ const o = (t = e.builderContextSignal.content) == null ? void 0 : t.testVariationId, a = (i = e.builderContextSignal.content) == null ? void 0 : i.id;
97
+ U({
98
+ apiHost: e.apiHost,
99
99
  type: "click",
100
- canTrack: K(t.canTrack),
100
+ canTrack: q(e.canTrack),
101
101
  contentId: a,
102
- apiKey: t.apiKey,
102
+ apiKey: e.apiKey,
103
103
  variationId: o !== a ? o : void 0,
104
- ...$(n),
105
- unique: !x
104
+ ...G(n),
105
+ unique: !y
106
106
  });
107
107
  }
108
- x || D(!0);
108
+ y || V(!0);
109
109
  }
110
- function N() {
111
- var e, i, o;
112
- const n = (o = (i = (e = t.builderContextSignal.content) == null ? void 0 : e.data) == null ? void 0 : i.httpRequests) != null ? o : {};
113
- Object.entries(n).forEach(([a, r]) => {
114
- if (!r || S[a] || h[a] && !g())
115
- return;
116
- S[a] = !0;
117
- const d = r.replace(
118
- /{{([^}]+)}}/g,
119
- (l, _) => String(
120
- W({
121
- code: _,
122
- context: t.context || {},
123
- localState: void 0,
124
- rootState: t.builderContextSignal.rootState,
125
- rootSetState: t.builderContextSignal.rootSetState
126
- })
127
- )
128
- );
129
- F(d), fetch(d).then((l) => l.json()).then((l) => {
130
- s({
131
- [a]: l
132
- }), h[a] = !0;
133
- }).catch((l) => {
134
- console.error("error fetching dynamic data", r, l);
135
- }).finally(() => {
136
- S[a] = !1;
137
- });
138
- });
110
+ function _() {
111
+ var t, i, o;
112
+ const n = (o = (i = (t = e.builderContextSignal.content) == null ? void 0 : t.data) == null ? void 0 : i.httpRequests) != null ? o : {};
113
+ Object.entries(n).forEach(
114
+ ([a, r]) => {
115
+ if (!r)
116
+ return;
117
+ const d = typeof r == "object" && r["@type"] === "@builder.io/core:Request";
118
+ if (v[a] || C[a] && !b())
119
+ return;
120
+ const h = d ? r.request.url : r;
121
+ v[a] = !0;
122
+ const R = h.replace(
123
+ /{{([^}]+)}}/g,
124
+ (u, W) => String(
125
+ B({
126
+ code: W,
127
+ context: e.context || {},
128
+ localState: void 0,
129
+ rootState: e.builderContextSignal.rootState,
130
+ rootSetState: e.builderContextSignal.rootSetState
131
+ })
132
+ )
133
+ ), m = d ? {
134
+ url: R,
135
+ method: r.request.method,
136
+ headers: r.request.headers,
137
+ body: r.request.body
138
+ } : {
139
+ url: R,
140
+ method: "GET"
141
+ };
142
+ $(JSON.stringify(m)), fetch(m.url, {
143
+ method: m.method,
144
+ headers: m.headers,
145
+ body: m.body
146
+ }).then((u) => u.json()).then((u) => {
147
+ f({
148
+ [a]: u
149
+ }), C[a] = !0;
150
+ }).catch((u) => {
151
+ console.error(
152
+ "error fetching dynamic data",
153
+ JSON.stringify(r),
154
+ u
155
+ );
156
+ }).finally(() => {
157
+ v[a] = !1;
158
+ });
159
+ }
160
+ );
139
161
  }
140
- function f() {
141
- g() && window.dispatchEvent(
162
+ function g() {
163
+ b() && window.dispatchEvent(
142
164
  new CustomEvent(
143
165
  "builder:component:stateChange",
144
166
  {
145
167
  detail: {
146
- state: j(t.builderContextSignal.rootState),
168
+ state: F(e.builderContextSignal.rootState),
147
169
  ref: {
148
- name: t.model
170
+ name: e.model
149
171
  }
150
172
  }
151
173
  }
152
174
  )
153
175
  );
154
176
  }
155
- function C(n) {
156
- var e;
157
- window.addEventListener("message", v), Q({
158
- ...t.locale ? {
159
- locale: t.locale
177
+ function E(n) {
178
+ var t;
179
+ window.addEventListener("message", x), Z({
180
+ ...e.locale ? {
181
+ locale: e.locale
160
182
  } : {},
161
- ...t.enrich ? {
162
- enrich: t.enrich
183
+ ...e.enrich ? {
184
+ enrich: e.enrich
163
185
  } : {},
164
- ...t.trustedHosts ? {
165
- trustedHosts: t.trustedHosts
186
+ ...e.trustedHosts ? {
187
+ trustedHosts: e.trustedHosts
166
188
  } : {},
167
- modelName: (e = t.model) != null ? e : "",
168
- apiKey: t.apiKey
189
+ modelName: (t = e.model) != null ? t : "",
190
+ apiKey: e.apiKey
169
191
  }), Object.values(
170
- t.builderContextSignal.componentInfos
192
+ e.builderContextSignal.componentInfos
171
193
  ).forEach((i) => {
172
194
  var o, a;
173
- if (!((o = i.models) != null && o.length) || i.models.includes(t.model)) {
174
- const r = M(i);
195
+ if (!((o = i.models) != null && o.length) || i.models.includes(e.model)) {
196
+ const r = z(i);
175
197
  (a = window.parent) == null || a.postMessage(r, "*");
176
198
  }
177
199
  }), window.addEventListener(
178
200
  "builder:component:stateChangeListenerActivated",
179
- f
201
+ g
180
202
  );
181
203
  }
182
- function E(n) {
204
+ function I(n) {
183
205
  var r;
184
- const e = new URL(location.href).searchParams, i = e.get("builder.preview"), o = e.get(
206
+ const t = new URL(location.href).searchParams, i = t.get("builder.preview"), o = t.get(
185
207
  `builder.overrides.${i}`
186
- ), a = e.get("apiKey") || e.get("builder.space");
187
- (i === "BUILDER_STUDIO" || i === t.model && a === t.apiKey && (!t.content || o === t.content.id)) && A({
188
- model: t.model,
189
- apiKey: t.apiKey,
190
- apiVersion: t.builderContextSignal.apiVersion,
191
- ...i === "BUILDER_STUDIO" && ((r = t.context) != null && r.symbolId) ? {
208
+ ), a = t.get("apiKey") || t.get("builder.space");
209
+ (i === "BUILDER_STUDIO" || i === e.model && a === e.apiKey && (!e.content || o === e.content.id)) && M({
210
+ model: e.model,
211
+ apiKey: e.apiKey,
212
+ apiVersion: e.builderContextSignal.apiVersion,
213
+ ...i === "BUILDER_STUDIO" && ((r = e.context) != null && r.symbolId) ? {
192
214
  query: {
193
- id: t.context.symbolId
215
+ id: e.context.symbolId
194
216
  }
195
217
  } : {}
196
218
  }).then((d) => {
197
- d && b(d);
219
+ d && S(d);
198
220
  });
199
221
  }
200
- Z();
201
- const I = P(!1);
202
- return I.current || (N(), f(), I.current = !0), c(() => {
222
+ te();
223
+ const w = K(!1);
224
+ return w.current || (_(), g(), w.current = !0), l(() => {
203
225
  var n;
204
- return (n = u.current) == null || n.addEventListener(
226
+ return (n = c.current) == null || n.addEventListener(
205
227
  "initeditingbldr",
206
- C
228
+ E
207
229
  ), () => {
208
- var e;
209
- return (e = u.current) == null ? void 0 : e.removeEventListener(
230
+ var t;
231
+ return (t = c.current) == null ? void 0 : t.removeEventListener(
210
232
  "initeditingbldr",
211
- C
233
+ E
212
234
  );
213
235
  };
214
- }, []), c(() => {
236
+ }, []), l(() => {
215
237
  var n;
216
- return (n = u.current) == null || n.addEventListener(
238
+ return (n = c.current) == null || n.addEventListener(
217
239
  "initpreviewingbldr",
218
- E
240
+ I
219
241
  ), () => {
220
- var e;
221
- return (e = u.current) == null ? void 0 : e.removeEventListener(
242
+ var t;
243
+ return (t = c.current) == null ? void 0 : t.removeEventListener(
222
244
  "initpreviewingbldr",
223
- E
245
+ I
224
246
  );
225
247
  };
226
- }, []), c(() => {
227
- var n, e, i;
228
- if (L()) {
229
- g() && !t.isNestedRender && u.current && u.current.dispatchEvent(new CustomEvent("initeditingbldr"));
230
- const o = t.builderContextSignal.content && K(t.canTrack), a = z({
231
- name: `builder.tests.${(n = t.builderContextSignal.content) == null ? void 0 : n.id}`,
248
+ }, []), l(() => {
249
+ var n, t, i;
250
+ if (T()) {
251
+ b() && !e.isNestedRender && c.current && c.current.dispatchEvent(new CustomEvent("initeditingbldr"));
252
+ const o = e.builderContextSignal.content && q(e.canTrack), a = Q({
253
+ name: `builder.tests.${(n = e.builderContextSignal.content) == null ? void 0 : n.id}`,
232
254
  canTrack: !0
233
- }), r = (e = t.builderContextSignal.content) == null ? void 0 : e.testVariationId;
255
+ }), r = (t = e.builderContextSignal.content) == null ? void 0 : t.testVariationId;
234
256
  if (o && r === a) {
235
- const d = (i = t.builderContextSignal.content) == null ? void 0 : i.id, l = t.apiKey;
236
- H({
237
- apiHost: t.apiHost,
257
+ const d = (i = e.builderContextSignal.content) == null ? void 0 : i.id, h = e.apiKey;
258
+ U({
259
+ apiHost: e.apiHost,
238
260
  type: "impression",
239
261
  canTrack: !0,
240
262
  contentId: d,
241
- apiKey: l,
263
+ apiKey: h,
242
264
  variationId: a !== d ? a : void 0
243
265
  });
244
266
  }
245
- B() && g();
267
+ J() && b();
246
268
  }
247
- }, []), c(() => {
248
- }, [t.content]), c(() => {
249
- f();
250
- }, [t.builderContextSignal.rootState]), c(() => {
251
- t.data && s(t.data);
252
- }, [t.data]), c(() => {
253
- t.locale && s({
254
- locale: t.locale
269
+ }, []), l(() => {
270
+ }, [e.content]), l(() => {
271
+ g();
272
+ }, [e.builderContextSignal.rootState]), l(() => {
273
+ e.data && f(e.data);
274
+ }, [e.data]), l(() => {
275
+ e.locale && f({
276
+ locale: e.locale
255
277
  });
256
- }, [t.locale]), c(() => () => {
257
- L() && (window.removeEventListener("message", v), window.removeEventListener(
278
+ }, [e.locale]), l(() => () => {
279
+ T() && (window.removeEventListener("message", x), window.removeEventListener(
258
280
  "builder:component:stateChangeListenerActivated",
259
- f
281
+ g
260
282
  ));
261
- }, []), /* @__PURE__ */ k(O.Provider, { value: t.builderContextSignal, children: t.builderContextSignal.content || q() ? /* @__PURE__ */ k(
262
- U,
283
+ }, []), /* @__PURE__ */ H(A.Provider, { value: e.builderContextSignal, children: e.builderContextSignal.content || D() ? /* @__PURE__ */ H(
284
+ O,
263
285
  {
264
- ref: u,
265
- onClick: (n) => V(n),
266
- "builder-content-id": (w = t.builderContextSignal.content) == null ? void 0 : w.id,
267
- "builder-model": t.model,
268
- className: Y(
269
- ((y = t.content) == null ? void 0 : y.testVariationId) || ((R = t.content) == null ? void 0 : R.id)
286
+ ref: c,
287
+ onClick: (n) => j(n),
288
+ "builder-content-id": (k = e.builderContextSignal.content) == null ? void 0 : k.id,
289
+ "builder-model": e.model,
290
+ className: ee(
291
+ ((P = e.content) == null ? void 0 : P.testVariationId) || ((L = e.content) == null ? void 0 : L.id)
270
292
  ),
271
293
  style: {
272
- display: !t.builderContextSignal.content && q() ? "none" : void 0
294
+ display: !e.builderContextSignal.content && D() ? "none" : void 0
273
295
  },
274
- ...T(),
275
- ...t.contentWrapperProps,
276
- children: t.children
296
+ ...N(),
297
+ ...e.contentWrapperProps,
298
+ children: e.children
277
299
  }
278
300
  ) : null });
279
301
  }
280
302
  export {
281
- yt as default
303
+ Le as default
282
304
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e="0.19.2";exports.SDK_VERSION=e;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e="0.20.0";exports.SDK_VERSION=e;
@@ -1,4 +1,4 @@
1
- const o = "0.19.2";
1
+ const o = "0.20.0";
2
2
  export {
3
3
  o as SDK_VERSION
4
4
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("../constants/target.cjs"),d=require("../helpers/omit.cjs"),p=require("./evaluate/evaluate.cjs"),f=require("./extract-localized-values.cjs"),g=require("./fast-clone.cjs"),m=require("./set.cjs"),y=require("./transform-block.cjs");function o(e){if(e===null||typeof e!="object")return e;if(Array.isArray(e))return e.map(n=>o(n));if(e["@type"]==="@builder.io/sdk:Element")return e;const t={};for(const n in e)n!=="meta"&&Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=o(e[n]));return t}const C=["svelte","vue","angular","qwik","solid"].includes(u.TARGET),q=e=>{if(C){const t=g.fastClone(e);return{...t,properties:{...t.properties},actions:{...t.actions}}}else{const t=o(d.omit(e,"children","meta"));return{...t,properties:{...t.properties},actions:{...t.actions},children:e.children,meta:e.meta}}},v=({block:e,context:t,localState:n,rootState:i,rootSetState:s})=>{if(!e.bindings)return e;const r=q(e);for(const c in e.bindings){const a=e.bindings[c],l=p.evaluate({code:a,localState:n,rootState:i,rootSetState:s,context:t});m.set(r,c,l)}return r};function B({block:e,context:t,localState:n,rootState:i,rootSetState:s}){let r=f.resolveLocalizedValues(e,i.locale);return r=y.transformBlock(r),v({block:r,localState:n,rootState:i,rootSetState:s,context:t})}exports.deepCloneWithConditions=o;exports.getProcessedBlock=B;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("../constants/target.cjs"),d=require("../helpers/omit.cjs"),p=require("./evaluate/evaluate.cjs"),f=require("./extract-localized-values.cjs"),g=require("./fast-clone.cjs"),m=require("./set.cjs"),y=require("./transform-block.cjs");function o(e){if(e===null||typeof e!="object")return e;if(Array.isArray(e))return e.map(n=>o(n));if(e["@type"]==="@builder.io/sdk:Element")return e;const t={};for(const n in e)n!=="meta"&&Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=o(e[n]));return t}const C=["svelte","vue","angular","qwik","solid"].includes(u.TARGET),q=e=>{if(C){const t=g.fastClone(e);return{...t,properties:{...t.properties},actions:{...t.actions}}}else{const t=o(d.omit(e,"children","meta"));return{...t,properties:{...t.properties},actions:{...t.actions},children:e.children,meta:e.meta}}},v=({block:e,context:t,localState:n,rootState:i,rootSetState:s})=>{if(!e.bindings)return e;const r=q(e);for(const c in e.bindings){const a=e.bindings[c],l=p.evaluate({code:a,localState:n,rootState:i,rootSetState:s,context:t});m.set(r,c,l)}return r};function B({block:e,context:t,localState:n,rootState:i,rootSetState:s}){let r=y.transformBlock(e);return r=v({block:r,localState:n,rootState:i,rootSetState:s,context:t}),r=f.resolveLocalizedValues(r,i.locale),r}exports.deepCloneWithConditions=o;exports.getProcessedBlock=B;
@@ -72,14 +72,14 @@ function P({
72
72
  rootState: i,
73
73
  rootSetState: o
74
74
  }) {
75
- let n = f(e, i.locale);
76
- return n = g(n), O({
75
+ let n = g(e);
76
+ return n = O({
77
77
  block: n,
78
78
  localState: t,
79
79
  rootState: i,
80
80
  rootSetState: o,
81
81
  context: r
82
- });
82
+ }), n = f(n, i.locale), n;
83
83
  }
84
84
  export {
85
85
  s as deepCloneWithConditions,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@builder.io/sdk-react-nextjs",
3
3
  "description": "Builder.io RSC SDK for NextJS App Directory",
4
- "version": "0.19.2",
4
+ "version": "0.20.0",
5
5
  "homepage": "https://github.com/BuilderIO/builder/tree/main/packages/sdks/output/nextjs",
6
6
  "repository": {
7
7
  "type": "git",
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "0.19.2";
1
+ export declare const SDK_VERSION = "0.20.0";
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "0.19.2";
1
+ export declare const SDK_VERSION = "0.20.0";