@builder.io/sdk-react 2.0.19 → 2.0.22
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 +833 -833
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/{server-entry-c8020f19.cjs → server-entry-5770bca9.cjs} +2 -2
- package/lib/browser/{server-entry-12189812.js → server-entry-b83ba684.js} +1 -2
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/{accordion-634b0466.js → accordion-78c3d81b.js} +1 -1
- package/lib/edge/{accordion-eaf2e50a.cjs → accordion-80133dd8.cjs} +1 -1
- package/lib/edge/blocks-5084bbec.cjs +12 -0
- package/lib/edge/{blocks-51761337.js → blocks-852d317b.js} +240 -233
- package/lib/edge/blocks-exports.cjs +1 -1
- package/lib/edge/blocks-exports.mjs +2 -2
- package/lib/edge/{button-6d2144c3.js → button-0a729557.js} +2 -2
- package/lib/edge/{button-a0aad19e.cjs → button-a97c0d05.cjs} +1 -1
- package/lib/edge/{columns-030a6892.js → columns-1149d23a.js} +6 -6
- package/lib/edge/{columns-44d76a14.cjs → columns-2bd50130.cjs} +4 -4
- package/lib/edge/{content-variants-46a433c2.js → content-variants-86962b96.js} +306 -308
- package/lib/edge/content-variants-cbd84920.cjs +134 -0
- package/lib/edge/{evaluate-6febb3ef.js → evaluate-46f56681.js} +671 -659
- package/lib/edge/{evaluate-29260bf8.cjs → evaluate-617e3bee.cjs} +11 -13
- package/lib/edge/{form-855a28fc.js → form-1811c08f.js} +6 -6
- package/lib/edge/form-c42561fb.cjs +1 -0
- package/lib/edge/{get-class-prop-name-a6353748.js → get-class-prop-name-6e4205e7.js} +1 -1
- package/lib/edge/{get-class-prop-name-6320e936.cjs → get-class-prop-name-dc89023a.cjs} +1 -1
- package/lib/edge/{image-eebfcbac.cjs → image-54d2f755.cjs} +3 -3
- package/lib/edge/{image-6a074aab.js → image-6970c193.js} +24 -24
- package/lib/edge/{img-56b4a196.js → img-0bc990ef.js} +1 -1
- package/lib/edge/{img-1f88586f.cjs → img-70b9d719.cjs} +1 -1
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/{input-35f6fbdd.cjs → input-21071030.cjs} +1 -1
- package/lib/edge/{input-7873f170.js → input-3689c63d.js} +1 -1
- package/lib/edge/{select-eb16d7cc.js → select-65ebd3fd.js} +1 -1
- package/lib/edge/{select-f03c5ba6.cjs → select-cb7c2f44.cjs} +1 -1
- package/lib/edge/{server-entry-dbe27fb2.cjs → server-entry-8ce6f347.cjs} +2 -2
- package/lib/edge/{server-entry-77a5a1a0.js → server-entry-9d83b8e5.js} +1 -2
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/edge/{slot-93865012.cjs → slot-21cc91d8.cjs} +1 -1
- package/lib/edge/{slot-c9a7a451.js → slot-e5f3b92d.js} +4 -4
- package/lib/edge/{symbol-b6b36212.cjs → symbol-0cc07e41.cjs} +1 -1
- package/lib/edge/{symbol-6657c638.js → symbol-56e5b927.js} +2 -2
- package/lib/edge/{tabs-44484f49.js → tabs-0e6f6b5b.js} +4 -4
- package/lib/edge/{tabs-020fedaa.cjs → tabs-9390d611.cjs} +1 -1
- package/lib/edge/{text-e00e3cdc.js → text-b68c0d5a.js} +2 -2
- package/lib/edge/{text-562c8568.cjs → text-baaedac7.cjs} +1 -1
- package/lib/node/blocks-exports.cjs +31 -31
- package/lib/node/blocks-exports.mjs +817 -844
- 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-82ab17f2.cjs → server-entry-52b8f10a.cjs} +2 -2
- package/lib/node/{server-entry-902ea0c4.js → server-entry-5b32494d.js} +1 -2
- 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-f20178fa.cjs → should-force-browser-runtime-in-node-253f1726.cjs} +4 -4
- package/lib/node/{should-force-browser-runtime-in-node-0b0cefdf.js → should-force-browser-runtime-in-node-68bc74aa.js} +56 -29
- package/package.json +1 -1
- package/types/constants/sdk-version.d.ts +1 -1
- package/types/functions/evaluate/browser-runtime/browser.d.ts +0 -6
- package/types/functions/evaluate/helpers.d.ts +5 -0
- package/types/types/input.d.ts +1 -1
- package/lib/edge/blocks-b8c9a72a.cjs +0 -12
- package/lib/edge/content-variants-3eef022e.cjs +0 -134
- package/lib/edge/form-59059e97.cjs +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react");require("./server-entry-
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react");require("./server-entry-8ce6f347.cjs");const t=e.lazy(()=>Promise.resolve().then(()=>require("./button-a97c0d05.cjs"))),r=e.lazy(()=>Promise.resolve().then(()=>require("./columns-2bd50130.cjs"))),n=e.lazy(()=>Promise.resolve().then(()=>require("./fragment-b6e3a326.cjs"))),s=e.lazy(()=>Promise.resolve().then(()=>require("./image-54d2f755.cjs"))),i=e.lazy(()=>Promise.resolve().then(()=>require("./section-d655ea14.cjs"))),l=e.lazy(()=>Promise.resolve().then(()=>require("./symbol-0cc07e41.cjs"))),c=e.lazy(()=>Promise.resolve().then(()=>require("./text-baaedac7.cjs"))),a=e.lazy(()=>Promise.resolve().then(()=>require("./video-e20dcbbc.cjs"))),u=e.lazy(()=>Promise.resolve().then(()=>require("./blocks-5084bbec.cjs")).then(o=>o.blocks)),m=e.lazy(()=>Promise.resolve().then(()=>require("./content-variants-cbd84920.cjs"))),y=e.createContext({content:null,context:{},localState:void 0,rootSetState(){},rootState:{},apiKey:null,apiVersion:void 0,componentInfos:{},inheritedStyles:{},BlocksWrapper:"div",BlocksWrapperProps:{},nonce:""});exports.Blocks=u;exports.BuilderContext=y;exports.Button=t;exports.Columns=r;exports.Content=m;exports.Fragment=n;exports.Image=s;exports.Section=i;exports.Symbol=l;exports.Text=c;exports.Video=a;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { lazy as t, createContext as n } from "react";
|
|
3
|
-
import "./server-entry-
|
|
4
|
-
const i = t(() => import("./button-
|
|
3
|
+
import "./server-entry-9d83b8e5.js";
|
|
4
|
+
const i = t(() => import("./button-0a729557.js")), r = t(() => import("./columns-1149d23a.js")), a = t(() => import("./fragment-1492bc7f.js")), c = t(() => import("./image-6970c193.js")), m = t(() => import("./section-d83e2dd3.js")), p = t(() => import("./symbol-56e5b927.js")), l = t(() => import("./text-b68c0d5a.js")), u = t(() => import("./video-58c2cc8d.js")), d = t(() => import("./blocks-852d317b.js").then((o) => o.blocks)), x = t(() => import("./content-variants-86962b96.js")), S = n({
|
|
5
5
|
content: null,
|
|
6
6
|
context: {},
|
|
7
7
|
localState: void 0,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import { DynamicRenderer as r } from "./dynamic-renderer-8b343325.js";
|
|
3
|
-
import { getClassPropName as n } from "./get-class-prop-name-
|
|
4
|
-
import "./server-entry-
|
|
3
|
+
import { getClassPropName as n } from "./get-class-prop-name-6e4205e7.js";
|
|
4
|
+
import "./server-entry-9d83b8e5.js";
|
|
5
5
|
function b(t) {
|
|
6
6
|
function e() {
|
|
7
7
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),r=require("./dynamic-renderer-b29b45ca.cjs"),t=require("./get-class-prop-name-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),r=require("./dynamic-renderer-b29b45ca.cjs"),t=require("./get-class-prop-name-dc89023a.cjs");require("./server-entry-8ce6f347.cjs");function u(e){function n(){return{...e.attributes,[t.getClassPropName()]:`${e.link?"":"builder-button"} ${e.attributes[t.getClassPropName()]||""}`,...e.link?{href:e.link,target:e.openLinkInNewTab?"_blank":void 0,role:"link"}:{role:"button"}}}return i.jsx(r.DynamicRenderer,{attributes:n(),TagName:e.link?e.builderLinkComponent||"a":"button",actionAttributes:{},children:e.text})}exports.default=u;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsxs as y, Fragment as B, jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { useState as r } from "react";
|
|
3
|
-
import { InlinedStyles as z, Blocks as A, mapStyleObjToStrIfNeeded as L, getSizesForBreakpoints as W } from "./blocks-
|
|
3
|
+
import { InlinedStyles as z, Blocks as A, mapStyleObjToStrIfNeeded as L, getSizesForBreakpoints as W } from "./blocks-852d317b.js";
|
|
4
4
|
import { DynamicRenderer as D } from "./dynamic-renderer-8b343325.js";
|
|
5
|
-
import { getClassPropName as N } from "./get-class-prop-name-
|
|
5
|
+
import { getClassPropName as N } from "./get-class-prop-name-6e4205e7.js";
|
|
6
6
|
import "./blocks-exports.mjs";
|
|
7
|
-
import "./server-entry-
|
|
8
|
-
import "./evaluate-
|
|
7
|
+
import "./server-entry-9d83b8e5.js";
|
|
8
|
+
import "./evaluate-46f56681.js";
|
|
9
9
|
const F = (e) => `builder-columns ${e}-breakpoints`;
|
|
10
10
|
function Q(e) {
|
|
11
11
|
var f, k;
|
|
@@ -124,7 +124,7 @@ function Q(e) {
|
|
|
124
124
|
/* @__PURE__ */ y(
|
|
125
125
|
"div",
|
|
126
126
|
{
|
|
127
|
-
className: F((f = e.builderBlock) == null ? void 0 : f.id) + " div-
|
|
127
|
+
className: F((f = e.builderBlock) == null ? void 0 : f.id) + " div-3b0f6fe2",
|
|
128
128
|
style: p(),
|
|
129
129
|
children: [
|
|
130
130
|
/* @__PURE__ */ o(
|
|
@@ -161,7 +161,7 @@ function Q(e) {
|
|
|
161
161
|
]
|
|
162
162
|
}
|
|
163
163
|
),
|
|
164
|
-
/* @__PURE__ */ o("style", { children: `.div-
|
|
164
|
+
/* @__PURE__ */ o("style", { children: `.div-3b0f6fe2 {
|
|
165
165
|
display: flex;
|
|
166
166
|
line-height: normal;
|
|
167
167
|
}` })
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),o=require("react"),s=require("./blocks-
|
|
2
|
-
@media (max-width: ${
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),o=require("react"),s=require("./blocks-5084bbec.cjs"),p=require("./dynamic-renderer-b29b45ca.cjs"),q=require("./get-class-prop-name-dc89023a.cjs");require("./blocks-exports.cjs");require("./server-entry-8ce6f347.cjs");require("./evaluate-617e3bee.cjs");const B=t=>`builder-columns ${t}-breakpoints`;function z(t){var k,g;const[u,A]=o.useState(()=>typeof t.space=="number"?t.space||0:20),[c,L]=o.useState(()=>t.columns||[]),[d,N]=o.useState(()=>t.stackColumnsAt||"tablet");function y(e){return e.link?t.builderLinkComponent||"a":"div"}function x(e){var n;return((n=c[e])==null?void 0:n.width)||100/c.length}function C(e){const n=x(e),i=u*(c.length-1)*(n/100);return`calc(${n}% - ${i}px)`}function a({stackedStyle:e,desktopStyle:n}){return d==="tablet"?e:n}function m({stackedStyle:e,desktopStyle:n}){return d==="never"?n:e}const[b,W]=o.useState(()=>t.stackColumnsAt==="never"?"row":t.reverseColumnsWhenStacked?"column-reverse":"column");function v(){return{"--flex-dir":b,"--flex-dir-tablet":a({stackedStyle:b,desktopStyle:"row"})}}function w(e){const n=e===0?0:u,i=C(e),r=`${n}px`,h="100%",S=0;return{...{display:"flex",flexDirection:"column",alignItems:"stretch"},width:i,["marginLeft"]:r,"--column-width-mobile":m({stackedStyle:h,desktopStyle:i}),"--column-margin-left-mobile":m({stackedStyle:S,desktopStyle:r}),"--column-width-tablet":a({stackedStyle:h,desktopStyle:i}),"--column-margin-left-tablet":a({stackedStyle:S,desktopStyle:r})}}function f(e){var i,r;return s.getSizesForBreakpoints(((r=(i=t.builderContext.content)==null?void 0:i.meta)==null?void 0:r.breakpoints)||{})[e].max}function $(){const e=`.${t.builderBlock.id}-breakpoints > .builder-column`;return`
|
|
2
|
+
@media (max-width: ${f("medium")}px) {
|
|
3
3
|
.${t.builderBlock.id}-breakpoints {
|
|
4
4
|
flex-direction: var(--flex-dir-tablet);
|
|
5
5
|
align-items: stretch;
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
@media (max-width: ${
|
|
14
|
+
@media (max-width: ${f("small")}px) {
|
|
15
15
|
.${t.builderBlock.id}-breakpoints {
|
|
16
16
|
flex-direction: var(--flex-dir);
|
|
17
17
|
align-items: stretch;
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
margin-left: var(--column-margin-left-mobile) !important;
|
|
23
23
|
}
|
|
24
24
|
},
|
|
25
|
-
`}function j(e,n){return{...e.link?{href:e.link}:{},[q.getClassPropName()]:"builder-column",style:s.mapStyleObjToStrIfNeeded(w(n))}}return l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:B((
|
|
25
|
+
`}function j(e,n){return{...e.link?{href:e.link}:{},[q.getClassPropName()]:"builder-column",style:s.mapStyleObjToStrIfNeeded(w(n))}}return l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:B((k=t.builderBlock)==null?void 0:k.id)+" div-3b0f6fe2",style:v(),children:[l.jsx(s.InlinedStyles,{id:"builderio-columns",styles:$(),nonce:t.builderContext.nonce}),(g=t.columns)==null?void 0:g.map((e,n)=>l.jsx(p.DynamicRenderer,{TagName:y(e),actionAttributes:{},attributes:j(e,n),children:l.jsx(s.Blocks,{path:`component.options.columns.${n}.blocks`,parent:t.builderBlock.id,styleProp:{flexGrow:"1"},context:t.builderContext,registeredComponents:t.builderComponents,linkComponent:t.builderLinkComponent,blocks:e.blocks})},n))]}),l.jsx("style",{children:`.div-3b0f6fe2 {
|
|
26
26
|
display: flex;
|
|
27
27
|
line-height: normal;
|
|
28
28
|
}`})]})}exports.default=z;
|