@builder.io/sdk-react 4.0.3 → 4.0.4
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 +6 -6
- package/lib/browser/blocks-exports.mjs +18 -11
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/{server-entry-e6ae7704.js → server-entry-66a925df.js} +1 -1
- package/lib/browser/{server-entry-c40e781d.cjs → server-entry-e6bf2d7b.cjs} +1 -1
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/{accordion-8934ef4b.cjs → accordion-7464a303.cjs} +1 -1
- package/lib/edge/{accordion-e657c96d.js → accordion-b4b4d9f1.js} +1 -1
- package/lib/edge/{blocks-a6ffbf92.cjs → blocks-e91ba3d4.cjs} +10 -10
- package/lib/edge/{blocks-513223a7.js → blocks-e93076da.js} +243 -241
- package/lib/edge/blocks-exports.cjs +1 -1
- package/lib/edge/blocks-exports.mjs +2 -2
- package/lib/edge/{button-3522aac2.js → button-33f21c52.js} +2 -2
- package/lib/edge/{button-49563e3b.cjs → button-fda4fec5.cjs} +1 -1
- package/lib/edge/{columns-ea0b3b30.js → columns-55e99fb4.js} +3 -3
- package/lib/edge/{columns-092b6fac.cjs → columns-f7fd551f.cjs} +1 -1
- package/lib/edge/{content-variants-6c1e3b13.js → content-variants-2ebd741d.js} +45 -41
- package/lib/edge/{content-variants-75ff40ca.cjs → content-variants-e6b3bd34.cjs} +1 -1
- package/lib/edge/{custom-code-ae3262be.cjs → custom-code-c66cd781.cjs} +1 -1
- package/lib/edge/{custom-code-1a43bbd7.js → custom-code-d7aa74ff.js} +1 -1
- package/lib/edge/{embed-8d302933.cjs → embed-2c418cac.cjs} +1 -1
- package/lib/edge/{embed-106f0066.js → embed-7384956f.js} +1 -1
- package/lib/edge/{form-0c0d5bf5.js → form-5148ead0.js} +3 -3
- package/lib/edge/{form-46e4d997.cjs → form-61cd3cc1.cjs} +1 -1
- package/lib/edge/{get-class-prop-name-dad1ee7e.cjs → get-class-prop-name-5ff8e9ef.cjs} +1 -1
- package/lib/edge/{get-class-prop-name-e44df0c8.js → get-class-prop-name-f91e4605.js} +1 -1
- package/lib/edge/{image-38917f45.js → image-1729f079.js} +20 -19
- package/lib/edge/{image-590e36ae.cjs → image-a6fbd15b.cjs} +3 -3
- package/lib/edge/{img-8bdeb666.js → img-595b9ae3.js} +1 -1
- package/lib/edge/{img-e49acb58.cjs → img-8770a93f.cjs} +1 -1
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/{input-92aaa4f2.cjs → input-10b2e145.cjs} +1 -1
- package/lib/edge/{input-d6338de6.js → input-cab27192.js} +1 -1
- package/lib/edge/{personalization-container-965bec51.cjs → personalization-container-1ba57b3b.cjs} +1 -1
- package/lib/edge/{personalization-container-1307218b.js → personalization-container-9984806a.js} +4 -4
- package/lib/edge/{select-5ce728b4.cjs → select-36b1bb81.cjs} +1 -1
- package/lib/edge/{select-1538b41a.js → select-e1dc1504.js} +1 -1
- package/lib/edge/{server-entry-2e94ad2c.js → server-entry-74debd65.js} +1 -1
- package/lib/edge/{server-entry-46e686b9.cjs → server-entry-f10ae31d.cjs} +1 -1
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/edge/{slot-516f176d.js → slot-c6535e6d.js} +3 -3
- package/lib/edge/{slot-3b6aa7ec.cjs → slot-e8473a94.cjs} +1 -1
- package/lib/edge/{symbol-cd10b6f0.cjs → symbol-9177d14c.cjs} +1 -1
- package/lib/edge/{symbol-3b2e7ebf.js → symbol-fc7d42ee.js} +2 -2
- package/lib/edge/{tabs-f0945019.js → tabs-955ab7dd.js} +3 -3
- package/lib/edge/{tabs-cec51291.cjs → tabs-980a2753.cjs} +1 -1
- package/lib/node/blocks-exports.cjs +6 -6
- package/lib/node/blocks-exports.mjs +20 -13
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +3 -3
- package/lib/node/init.cjs +1 -1
- package/lib/node/init.mjs +3 -3
- package/lib/node/{server-entry-6b05381c.cjs → server-entry-a7413c09.cjs} +1 -1
- package/lib/node/{server-entry-c1000f54.js → server-entry-d38415f3.js} +1 -1
- package/lib/node/server-entry.cjs +1 -1
- package/lib/node/server-entry.mjs +1 -1
- package/lib/node/{setIvm-4ae0308c.cjs → setIvm-0a044ac8.cjs} +1 -1
- package/lib/node/{setIvm-011d6eb2.js → setIvm-9fe8e65a.js} +1 -1
- package/lib/node/setIvm.cjs +1 -1
- package/lib/node/setIvm.mjs +2 -2
- package/lib/node/{should-force-browser-runtime-in-node-5d513614.cjs → should-force-browser-runtime-in-node-e4a9bd6b.cjs} +1 -1
- package/lib/node/{should-force-browser-runtime-in-node-abf8d0a7.js → should-force-browser-runtime-in-node-eb6e6ea4.js} +1 -1
- package/package.json +1 -1
- package/types/blocks/image/image.types.d.ts +1 -0
- package/types/constants/sdk-version.d.ts +1 -1
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("./server-entry-
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("./server-entry-a7413c09.cjs"),r=require("react/jsx-runtime"),h=require("react"),N=require("./setIvm-0a044ac8.cjs"),Oe=require("./should-force-browser-runtime-in-node-e4a9bd6b.cjs");function Le(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,i.get?i:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Ue=Le(h),_e=new Set(["area","base","br","col","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"]),qe=e=>typeof e=="string"&&_e.has(e.toLowerCase());function ne(e){return r.jsx(r.Fragment,{children:qe(e.TagName)?r.jsx(r.Fragment,{children:r.jsx(e.TagName,{...e.attributes,...e.actionAttributes})}):r.jsx(r.Fragment,{children:typeof e.TagName=="string"?r.jsx(e.TagName,{...e.attributes,...e.actionAttributes,children:e.children}):r.jsx(e.TagName,{...e.attributes,...e.actionAttributes,children:e.children})})})}const O=()=>{switch(p.TARGET){case"react":case"reactNative":case"rsc":return"className";case"svelte":case"vue":case"solid":case"qwik":case"angular":return"class"}};function he(e){function t(){return{...e.attributes,[O()]:`${e.link?"":"builder-button"} ${e.attributes[O()]||""}`,...e.link?{href:e.link,target:e.openLinkInNewTab?"_blank":void 0,role:"link"}:{role:"button"}}}return r.jsx(ne,{attributes:t(),TagName:e.link?e.builderLinkComponent||"a":"button",actionAttributes:{},children:e.text})}const H=h.createContext({content:null,context:{},localState:void 0,rootSetState(){},rootState:{},apiKey:null,apiVersion:void 0,componentInfos:{},inheritedStyles:{},BlocksWrapper:"div",BlocksWrapperProps:{},nonce:"",model:""}),be=h.createContext({registeredComponents:{}}),pe=(e,t,n)=>{const i=String.prototype.split.call(t,/[,[\].]+?/).filter(Boolean).reduce((a,s)=>a!=null?a[s]:a,e);return i===void 0||i===e?n:i},Me=({code:e,builder:t,context:n,event:i,localState:a,rootSetState:s,rootState:o})=>{const l=N.getFunctionArguments({builder:t,context:n,event:i,state:N.flattenState({rootState:o,localState:a,rootSetState:s})});return new Function(...l.map(([d])=>d),e)(...l.map(([,d])=>d))},He=e=>p.isBrowser()||Oe.shouldForceBrowserRuntimeInNode({shouldLogWarning:!0})?Me(e):N.runInNode(e),ze=/^(return )?(\s*)?state(?<getPath>(\.\w+)+)(\s*);?$/,Ke=/(\s)*var(\s)+_virtual_index(\s)*=(\s)*state(?<getPath>(\.\w+)+)(\s*);?(\s)*return(\s)*_virtual_index(\s)*/,Ge=e=>{var t,n,i,a,s,o;return((i=(n=(t=ze.exec(e.trim()))==null?void 0:t.groups)==null?void 0:n.getPath)==null?void 0:i.slice(1))||((o=(s=(a=Ke.exec(e.trim()))==null?void 0:a.groups)==null?void 0:s.getPath)==null?void 0:o.slice(1))};function W({code:e,context:t,localState:n,rootState:i,rootSetState:a,event:s,isExpression:o=!0}){if(e.trim()==="")return;const l=Ge(e.trim());if(l)return pe({...i,...n},l);const d={code:N.parseCode(e,{isExpression:o}),builder:N.getBuilderGlobals(),context:t,event:s,rootSetState:a,rootState:i,localState:n};try{return He(d)}catch(u){p.logger.error("Failed code evaluation: "+u.message,{code:e});return}}function Je(e,t){var n;return{...(n=e.component)==null?void 0:n.options,...e.options,...Qe(e,t)}}const Qe=(e,t)=>{var n,i;if(((n=e.component)==null?void 0:n.name)==="Text"&&((i=e.component.options)!=null&&i.text)&&typeof e.component.options.text=="string")return{...e.component.options,text:e.component.options.text.replace(/{{([^}]+)}}/g,(a,s)=>W({code:s,context:t,localState:t.localState,rootState:t.rootState,rootSetState:t.rootSetState}))}};function Ye(e,...t){const n=Object.assign({},e);for(const i of t)delete n[i];return n}function q(e,t,n=null,i=null,a=new WeakSet){if(e==null||typeof e!="object"){t(e,s=>{n!==null&&i!==null&&(n[i]=s)});return}a.has(e)||(a.add(e),Array.isArray(e)?e.forEach((s,o)=>{t(s,d=>{e[o]=d}),q(s,t,e,o,a)}):Object.entries(e).forEach(([s,o])=>{t(o,d=>{e[s]=d}),q(o,t,e,s,a)}))}function ye(e){return e&&typeof e=="object"&&e["@type"]==="@builder.io/core:LocalizedValue"}function Xe(e){if(!e||!Object.getOwnPropertyNames(e).length)return!1;let t=!1;return q(e,n=>{if(ye(n)){t=!0;return}}),t}function Ze(e,t){return!e||!Object.getOwnPropertyNames(e).length?{}:(q(e,(n,i)=>{var a;ye(n)&&i((a=n[t])!=null?a:void 0)}),e)}function et(e,t){var n,i;return(n=e.component)!=null&&n.options&&Xe((i=e.component)==null?void 0:i.options)&&(t||console.warn("[Builder.io] In order to use localized fields in Builder, you must pass a locale prop to the BuilderComponent or to options object while fetching the content to resolve localized fields. Learn more: https://www.builder.io/c/docs/localization-inline#targeting-and-inline-localization"),e.component.options=Ze(e.component.options,t!=null?t:"Default")),e}function te(e){if(e===null||typeof e!="object")return e;if(Array.isArray(e))return e.map(n=>te(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]=te(e[n]));return t}const tt=["svelte","vue","angular","qwik","solid"].includes(p.TARGET),nt=e=>{if(tt){const t=N.fastClone(e);return{...t,properties:{...t.properties},actions:{...t.actions}}}else{const t=te(Ye(e,"children","meta"));return{...t,properties:{...t.properties},actions:{...t.actions},children:e.children,meta:e.meta}}},it=({block:e,context:t,localState:n,rootState:i,rootSetState:a})=>{if(!e.bindings)return e;const s=nt(e);for(const o in e.bindings){const l=e.bindings[o],d=W({code:l,localState:n,rootState:i,rootSetState:a,context:t});N.set(s,o,d)}return s};function at({block:e,context:t,localState:n,rootState:i,rootSetState:a}){let s=et(e,i.locale);return s=s,it({block:s,localState:n,rootState:i,rootSetState:a,context:t})}const z=e=>e?e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase():"";function ot(e,t,n={}){let i,a,s,o=null,l=0;const d=function(){l=n.leading===!1?0:Date.now(),o=null,s=e.apply(i,a),o||(i=a=null)};return function(){const u=Date.now();!l&&n.leading===!1&&(l=u);const g=t-(u-l);return i=this,a=arguments,g<=0||g>t?(o&&(clearTimeout(o),o=null),l=u,s=e.apply(i,a),o||(i=a=null)):!o&&n.trailing!==!1&&(o=setTimeout(d,g)),s}}function $(e,...t){const n=Object(e);for(let i=1;i<arguments.length;i++){const a=arguments[i];if(a!=null)for(const s in a)Object.prototype.hasOwnProperty.call(a,s)&&(n[s]=a[s])}return n}function rt(e){for(const t of e)switch(t.trigger){case"pageLoad":Se(t);break;case"scrollInView":lt(t);break}}function xe(e){console.warn(`Cannot animate element: element with ID ${e} not found!`)}function ve(e,t){const n=st(e),i=getComputedStyle(t),a=e.steps[0].styles,s=e.steps[e.steps.length-1].styles,o=[a,s];for(const l of o)for(const d of n)d in l||(l[d]=i[d])}function st(e){const t=[];for(const n of e.steps)for(const i in n.styles)t.indexOf(i)===-1&&t.push(i);return t}function Se(e){const t=Array.prototype.slice.call(document.getElementsByClassName(e.elementId||e.id||""));if(!t.length){xe(e.elementId||e.id||"");return}Array.from(t).forEach(n=>{ve(e,n),n.style.transition="none",n.style.transitionDelay="0",$(n.style,e.steps[0].styles),setTimeout(()=>{n.style.transition=`all ${e.duration}s ${z(e.easing)}`,e.delay&&(n.style.transitionDelay=e.delay+"s"),$(n.style,e.steps[1].styles),setTimeout(()=>{n.style.transition="",n.style.transitionDelay=""},(e.delay||0)*1e3+e.duration*1e3+100)})})}function lt(e){const t=Array.prototype.slice.call(document.getElementsByClassName(e.elementId||e.id||""));if(!t.length){xe(e.elementId||e.id||"");return}Array.from(t).forEach(n=>{ve(e,n);let i=!1,a=!1;function s(){!i&&l(n)?(i=!0,a=!0,setTimeout(()=>{$(n.style,e.steps[1].styles),e.repeat||document.removeEventListener("scroll",o),setTimeout(()=>{a=!1,e.repeat||(n.style.transition="",n.style.transitionDelay="")},(e.duration+(e.delay||0))*1e3+100)})):e.repeat&&i&&!a&&!l(n)&&(i=!1,$(n.style,e.steps[0].styles))}const o=ot(s,200,{leading:!1});function l(g){const b=g.getBoundingClientRect(),c=window.innerHeight,f=(e.thresholdPercent||0)/100*c;return b.bottom>f&&b.top<c-f}const d=e.steps[0].styles;function u(){$(n.style,d)}u(),setTimeout(()=>{n.style.transition=`all ${e.duration}s ${z(e.easing)}`,e.delay&&(n.style.transitionDelay=e.delay+"s")}),document.addEventListener("scroll",o,{capture:!0,passive:!0}),s()})}const ke=e=>Object.entries(e).map(([n,i])=>{if(typeof i=="string")return`${z(n)}: ${i};`}).filter(p.checkIsDefined),ct=e=>ke(e).join(`
|
|
2
2
|
`),D=({mediaQuery:e,className:t,styles:n})=>{const i=`.${t} {
|
|
3
3
|
${ct(n)}
|
|
4
4
|
}`;return e?`${e} {
|
|
5
5
|
${i}
|
|
6
6
|
}`:i};function ut({style:e}){return e}const dt=({block:e,context:t})=>Ce(ut({style:e.style||{},context:t,block:e}));function Ce(e){switch(p.TARGET){case"svelte":case"vue":case"solid":case"angular":return ke(e).join(" ");case"qwik":case"reactNative":case"react":case"rsc":return e}}const Te=(e,t)=>e?t?e.models&&e.models.length>0&&!e.models.includes(t):!1:!0,mt=({block:e,registeredComponents:t,model:n})=>{var s;const i=(s=e.component)==null?void 0:s.name;if(!i)return null;const a=t[i];if(!a||Te(a,n)){console.warn(`
|
|
7
7
|
Could not find a registered component named "${i}".
|
|
8
|
-
If you registered it, is the file that registered it imported by the file that needs to render it?`);return}else return a},ft=({block:e,context:t})=>{const{repeat:n,...i}=e;if(!(n!=null&&n.collection))return;const a=W({code:n.collection,localState:t.localState,rootState:t.rootState,rootSetState:t.rootSetState,context:t.context});if(!Array.isArray(a))return;const s=n.collection.split(".").pop(),o=n.itemName||(s?s+"Item":"item");return a.map((d,u)=>({context:{...t,localState:{...t.localState,$index:u,$item:d,[o]:d,[`$${o}Index`]:u}},block:i}))},gt=(e,t)=>{var n;return(n=e==null?void 0:e.shouldReceiveBuilderProps)!=null&&n.builderLinkComponent?{builderLinkComponent:t}:{}},ht=(e,t,n)=>{var i;return(i=e==null?void 0:e.shouldReceiveBuilderProps)!=null&&i.builderComponents?{builderComponents:Object.fromEntries(Object.entries(t).filter(([s,o])=>!Te(o,n)))}:{}},bt=(e,t)=>{var n;return(n=e==null?void 0:e.shouldReceiveBuilderProps)!=null&&n.builderBlock?{builderBlock:t}:{}},pt=(e,t)=>{var n;return(n=e==null?void 0:e.shouldReceiveBuilderProps)!=null&&n.builderContext?{builderContext:t}:{}},we={xsmall:{min:0,default:160,max:320},small:{min:321,default:321,max:640},medium:{min:641,default:642,max:991},large:{min:990,default:991,max:1200}},J=(e,t=we)=>`@media (max-width: ${t[e].max}px)`,Ie=e=>{const t=N.fastClone(we);if(!e)return t;const{xsmall:n,small:i,medium:a}=e;if(n){const d=Math.floor(n/2);t.xsmall={max:n,min:d,default:d+1}}if(!i||!a)return t;const s=n?t.xsmall.max+1:Math.floor(i/2);t.small={max:i,min:s,default:s+1};const o=t.small.max+1;t.medium={max:a,min:o,default:o+1};const l=t.medium.max+1;return t.large={max:2e3,min:l,default:l+1},t};function L(e){return r.jsx("style",{dangerouslySetInnerHTML:{__html:e.styles},"data-id":e.id,nonce:e.nonce})}function yt(e){function t(){const i=e.block;return p.checkIsDefined(i.hide)?!i.hide:p.checkIsDefined(i.show)?i.show:!0}function n(){var w,P,E,k,m;const i=e.block,a=i.responsiveStyles,s=e.context.content,o=Ie(((w=s==null?void 0:s.meta)==null?void 0:w.breakpoints)||{}),l=!!((E=(P=s==null?void 0:s.meta)==null?void 0:P.breakpoints)!=null&&E.xsmall),d=a==null?void 0:a.large,u=a==null?void 0:a.medium,g=a==null?void 0:a.small,b=a==null?void 0:a.xsmall,c=i.id;if(!c)return"";const S=d?D({className:c,styles:d}):"",f=u?D({className:c,styles:u,mediaQuery:J("medium",o)}):"",y=g?D({className:c,styles:g,mediaQuery:J("small",o)}):"",C=b&&l?D({className:c,styles:b,mediaQuery:J("xsmall",o)}):"",x=i.animations&&i.animations.find(v=>v.trigger==="hover");let T="";if(x){const v=((m=(k=x.steps)==null?void 0:k[1])==null?void 0:m.styles)||{};T=D({className:`${c}:hover`,styles:{...v,transition:`all ${x.duration}s ${z(x.easing)}`,transitionDelay:x.delay?`${x.delay}s`:"0s"}})||""}return[S,f,y,C,T].join(" ")}return r.jsx(r.Fragment,{children:n()&&t()?r.jsx(r.Fragment,{children:r.jsx(L,{id:"builderio-block",styles:n(),nonce:e.context.nonce})}):null})}function xt(e){return e.charAt(0).toUpperCase()+e.slice(1)}const vt=e=>`on${xt(e)}`,St=(e,t)=>n=>W({code:e,context:t.context,localState:t.localState,rootState:t.rootState,rootSetState:t.rootSetState,event:n,isExpression:!1});function Ee(e){var i;const t={},n=(i=e.block.actions)!=null?i:{};for(const a in n){if(!n.hasOwnProperty(a))continue;const s=n[a];let o=vt(a);if(e.stripPrefix)switch(p.TARGET){case"vue":o=o.replace("v-on:","");break;case"svelte":o=o.replace("on:","");break}t[o]=St(s,e)}return t}function kt({properties:e}){return e}const Ct=e=>({href:e.href});function ie({block:e,context:t}){var i;const n={...Ct(e),...e.properties,"builder-id":e.id,style:dt({block:e,context:t}),[O()]:[e.id,"builder-block",e.class,(i=e.properties)==null?void 0:i.class].filter(Boolean).join(" ")};return kt({properties:n,context:t,block:e})}function Tt(e){return r.jsx(ne,{TagName:e.Wrapper,attributes:ie({block:e.block,context:e.context}),actionAttributes:Ee({block:e.block,rootState:e.context.rootState,rootSetState:e.context.rootSetState,localState:e.context.localState,context:e.context.context,stripPrefix:!0}),children:e.children})}function wt(e){return h.useEffect(()=>{},[]),r.jsx(r.Fragment,{children:e.children})}function It(e){function t(){return e.includeBlockProps?{...ie({block:e.block,context:e.context}),...Ee({block:e.block,rootState:e.context.rootState,rootSetState:e.context.rootSetState,localState:e.context.localState,context:e.context.context})}:{}}return r.jsx(r.Fragment,{children:e.Wrapper.load?r.jsx(r.Fragment,{children:r.jsx(wt,{load:e.Wrapper.load,fallback:e.Wrapper.fallback,props:e.wrapperProps,attributes:t(),children:e.children})}):r.jsx(e.Wrapper,{...e.wrapperProps,attributes:t(),children:e.children})})}const Et=({componentOptions:e,builderBlock:t,context:n,componentRef:i,includeBlockProps:a,isInteractive:s,contextValue:o})=>{const l={...e,...a?{attributes:ie({block:t,context:o})}:{}};return s?{Wrapper:i,block:t,context:n,wrapperProps:e,includeBlockProps:a}:l};function re(e){var i;const[t,n]=h.useState(()=>e.isInteractive?It:e.componentRef);return r.jsx(r.Fragment,{children:e.componentRef?r.jsx(r.Fragment,{children:r.jsx(t,{...Et({componentOptions:e.componentOptions,builderBlock:e.builderBlock,context:e.context,componentRef:e.componentRef,linkComponent:e.linkComponent,includeBlockProps:e.includeBlockProps,isInteractive:e.isInteractive,contextValue:e.context}),children:(i=e.blockChildren)==null?void 0:i.map(a=>r.jsx(K,{block:a,context:e.context,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent},a.id))})}):null})}function se(e){const[t,n]=h.useState(()=>e.repeatContext);return r.jsx(H.Provider,{value:t,children:r.jsx(K,{block:e.block,context:t,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent})})}function K(e){var g,b,c,S;function t(){return ft({block:e.block,context:e.context})}const[n,i]=h.useState(()=>({value:null,update:!1}));function a(){var y;if(n.value&&!n.update&&!p.isPreviewing())return n.value;const f=(y=e.block.repeat)!=null&&y.collection?e.block:at({block:e.block,localState:e.context.localState,rootState:e.context.rootState,rootSetState:e.context.rootSetState,context:e.context.context});return n.value=f,n.update=!1,f}function s(){return mt({block:a(),registeredComponents:e.registeredComponents,model:e.context.model})}function o(){var y;return e.block.tagName==="a"||((y=a().properties)==null?void 0:y.href)||a().href?e.linkComponent||"a":e.block.tagName||"div"}function l(){var C,x;if((C=e.block.repeat)!=null&&C.collection)return!!((x=t==null?void 0:t())!=null&&x.length);const f="hide"in a()?a().hide:!1;return("show"in a()?a().show:!0)&&!f}function d(){var y,C;return!((y=s==null?void 0:s())!=null&&y.component)&&!t()?(C=a().children)!=null?C:[]:[]}function u(){var f,y,C,x;return{blockChildren:(f=a().children)!=null?f:[],componentRef:(y=s==null?void 0:s())==null?void 0:y.component,componentOptions:{...Je(a(),e.context),...bt(s(),a()),...pt(s(),e.context),...gt(s(),e.linkComponent),...ht(s(),e.registeredComponents,e.context.model)},context:e.context,linkComponent:e.linkComponent,registeredComponents:e.registeredComponents,builderBlock:a(),includeBlockProps:((C=s==null?void 0:s())==null?void 0:C.noWrap)===!0,isInteractive:!((x=s==null?void 0:s())!=null&&x.isRSC&&p.TARGET==="rsc")}}return h.useEffect(()=>{const f=a().id,y=a().animations;y&&f&&rt(y.map(C=>({...C,elementId:f})))},[]),h.useEffect(()=>{n.update=!0}),r.jsx(r.Fragment,{children:l()?r.jsxs(r.Fragment,{children:[r.jsx(yt,{block:a(),context:e.context}),(g=s==null?void 0:s())!=null&&g.noWrap?t()?r.jsx(r.Fragment,{children:(S=t())==null?void 0:S.map((f,y)=>r.jsx(se,{repeatContext:f.context,block:f.block,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent},y))}):r.jsx(re,{componentRef:u().componentRef,componentOptions:u().componentOptions,blockChildren:u().blockChildren,context:u().context,registeredComponents:u().registeredComponents,linkComponent:u().linkComponent,builderBlock:u().builderBlock,includeBlockProps:u().includeBlockProps,isInteractive:u().isInteractive}):r.jsx(r.Fragment,{children:t()?r.jsx(r.Fragment,{children:(c=t())==null?void 0:c.map((f,y)=>r.jsx(se,{repeatContext:f.context,block:f.block,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent},y))}):r.jsxs(Tt,{Wrapper:o(),block:a(),context:e.context,children:[r.jsx(re,{componentRef:u().componentRef,componentOptions:u().componentOptions,blockChildren:u().blockChildren,context:u().context,registeredComponents:u().registeredComponents,linkComponent:u().linkComponent,builderBlock:u().builderBlock,includeBlockProps:u().includeBlockProps,isInteractive:u().isInteractive}),(b=d())==null?void 0:b.map(f=>r.jsx(K,{block:f,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent,context:e.context},f.id))]})})]}):null})}function Rt(e){const t=h.useRef(null);function n(){var o;return["builder-blocks",(o=e.blocks)!=null&&o.length?"":"no-blocks",e.classNameProp].filter(Boolean).join(" ")}function i(){if(!e.path)return;const o="this.",l="component.options.";return e.path.startsWith(o)?e.path.replace(o,""):e.path.startsWith(l)?e.path:`${l}${e.path||""}`}function a(){var o,l;p.isEditing()&&!((o=e.blocks)!=null&&o.length)&&((l=window.parent)==null||l.postMessage({type:"builder.clickEmptyBlocks",data:{parentElementId:e.parent,dataPath:i()}},"*"))}function s(){var o,l;p.isEditing()&&!((o=e.blocks)!=null&&o.length)&&((l=window.parent)==null||l.postMessage({type:"builder.hoverEmptyBlocks",data:{parentElementId:e.parent,dataPath:i()}},"*"))}return h.useEffect(()=>{},[]),r.jsxs(r.Fragment,{children:[r.jsx(e.BlocksWrapper,{ref:t,className:n()+" props-blocks-wrapper-
|
|
8
|
+
If you registered it, is the file that registered it imported by the file that needs to render it?`);return}else return a},ft=({block:e,context:t})=>{const{repeat:n,...i}=e;if(!(n!=null&&n.collection))return;const a=W({code:n.collection,localState:t.localState,rootState:t.rootState,rootSetState:t.rootSetState,context:t.context});if(!Array.isArray(a))return;const s=n.collection.split(".").pop(),o=n.itemName||(s?s+"Item":"item");return a.map((d,u)=>({context:{...t,localState:{...t.localState,$index:u,$item:d,[o]:d,[`$${o}Index`]:u}},block:i}))},gt=(e,t)=>{var n;return(n=e==null?void 0:e.shouldReceiveBuilderProps)!=null&&n.builderLinkComponent?{builderLinkComponent:t}:{}},ht=(e,t,n)=>{var i;return(i=e==null?void 0:e.shouldReceiveBuilderProps)!=null&&i.builderComponents?{builderComponents:Object.fromEntries(Object.entries(t).filter(([s,o])=>!Te(o,n)))}:{}},bt=(e,t)=>{var n;return(n=e==null?void 0:e.shouldReceiveBuilderProps)!=null&&n.builderBlock?{builderBlock:t}:{}},pt=(e,t)=>{var n;return(n=e==null?void 0:e.shouldReceiveBuilderProps)!=null&&n.builderContext?{builderContext:t}:{}},we={xsmall:{min:0,default:160,max:320},small:{min:321,default:321,max:640},medium:{min:641,default:642,max:991},large:{min:990,default:991,max:1200}},J=(e,t=we)=>`@media (max-width: ${t[e].max}px)`,Ie=e=>{const t=N.fastClone(we);if(!e)return t;const{xsmall:n,small:i,medium:a}=e;if(n){const d=Math.floor(n/2);t.xsmall={max:n,min:d,default:d+1}}if(!i||!a)return t;const s=n?t.xsmall.max+1:Math.floor(i/2);t.small={max:i,min:s,default:s+1};const o=t.small.max+1;t.medium={max:a,min:o,default:o+1};const l=t.medium.max+1;return t.large={max:2e3,min:l,default:l+1},t};function L(e){return r.jsx("style",{dangerouslySetInnerHTML:{__html:e.styles},"data-id":e.id,nonce:e.nonce})}function yt(e){function t(){const i=e.block;return p.checkIsDefined(i.hide)?!i.hide:p.checkIsDefined(i.show)?i.show:!0}function n(){var w,P,E,k,m;const i=e.block,a=i.responsiveStyles,s=e.context.content,o=Ie(((w=s==null?void 0:s.meta)==null?void 0:w.breakpoints)||{}),l=!!((E=(P=s==null?void 0:s.meta)==null?void 0:P.breakpoints)!=null&&E.xsmall),d=a==null?void 0:a.large,u=a==null?void 0:a.medium,g=a==null?void 0:a.small,b=a==null?void 0:a.xsmall,c=i.id;if(!c)return"";const S=d?D({className:c,styles:d}):"",f=u?D({className:c,styles:u,mediaQuery:J("medium",o)}):"",y=g?D({className:c,styles:g,mediaQuery:J("small",o)}):"",C=b&&l?D({className:c,styles:b,mediaQuery:J("xsmall",o)}):"",x=i.animations&&i.animations.find(v=>v.trigger==="hover");let T="";if(x){const v=((m=(k=x.steps)==null?void 0:k[1])==null?void 0:m.styles)||{};T=D({className:`${c}:hover`,styles:{...v,transition:`all ${x.duration}s ${z(x.easing)}`,transitionDelay:x.delay?`${x.delay}s`:"0s"}})||""}return[S,f,y,C,T].join(" ")}return r.jsx(r.Fragment,{children:n()&&t()?r.jsx(r.Fragment,{children:r.jsx(L,{id:"builderio-block",styles:n(),nonce:e.context.nonce})}):null})}function xt(e){return e.charAt(0).toUpperCase()+e.slice(1)}const vt=e=>`on${xt(e)}`,St=(e,t)=>n=>W({code:e,context:t.context,localState:t.localState,rootState:t.rootState,rootSetState:t.rootSetState,event:n,isExpression:!1});function Ee(e){var i;const t={},n=(i=e.block.actions)!=null?i:{};for(const a in n){if(!n.hasOwnProperty(a))continue;const s=n[a];let o=vt(a);if(e.stripPrefix)switch(p.TARGET){case"vue":o=o.replace("v-on:","");break;case"svelte":o=o.replace("on:","");break}t[o]=St(s,e)}return t}function kt({properties:e}){return e}const Ct=e=>({href:e.href});function ie({block:e,context:t}){var i;const n={...Ct(e),...e.properties,"builder-id":e.id,style:dt({block:e,context:t}),[O()]:[e.id,"builder-block",e.class,(i=e.properties)==null?void 0:i.class].filter(Boolean).join(" ")};return kt({properties:n,context:t,block:e})}function Tt(e){return r.jsx(ne,{TagName:e.Wrapper,attributes:ie({block:e.block,context:e.context}),actionAttributes:Ee({block:e.block,rootState:e.context.rootState,rootSetState:e.context.rootSetState,localState:e.context.localState,context:e.context.context,stripPrefix:!0}),children:e.children})}function wt(e){return h.useEffect(()=>{},[]),r.jsx(r.Fragment,{children:e.children})}function It(e){function t(){return e.includeBlockProps?{...ie({block:e.block,context:e.context}),...Ee({block:e.block,rootState:e.context.rootState,rootSetState:e.context.rootSetState,localState:e.context.localState,context:e.context.context})}:{}}return r.jsx(r.Fragment,{children:e.Wrapper.load?r.jsx(r.Fragment,{children:r.jsx(wt,{load:e.Wrapper.load,fallback:e.Wrapper.fallback,props:e.wrapperProps,attributes:t(),children:e.children})}):r.jsx(e.Wrapper,{...e.wrapperProps,attributes:t(),children:e.children})})}const Et=({componentOptions:e,builderBlock:t,context:n,componentRef:i,includeBlockProps:a,isInteractive:s,contextValue:o})=>{const l={...e,...a?{attributes:ie({block:t,context:o})}:{}};return s?{Wrapper:i,block:t,context:n,wrapperProps:e,includeBlockProps:a}:l};function re(e){var i;const[t,n]=h.useState(()=>e.isInteractive?It:e.componentRef);return r.jsx(r.Fragment,{children:e.componentRef?r.jsx(r.Fragment,{children:r.jsx(t,{...Et({componentOptions:e.componentOptions,builderBlock:e.builderBlock,context:e.context,componentRef:e.componentRef,linkComponent:e.linkComponent,includeBlockProps:e.includeBlockProps,isInteractive:e.isInteractive,contextValue:e.context}),children:(i=e.blockChildren)==null?void 0:i.map(a=>r.jsx(K,{block:a,context:e.context,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent},a.id))})}):null})}function se(e){const[t,n]=h.useState(()=>e.repeatContext);return r.jsx(H.Provider,{value:t,children:r.jsx(K,{block:e.block,context:t,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent})})}function K(e){var g,b,c,S;function t(){return ft({block:e.block,context:e.context})}const[n,i]=h.useState(()=>({value:null,update:!1}));function a(){var y;if(n.value&&!n.update&&!p.isPreviewing())return n.value;const f=(y=e.block.repeat)!=null&&y.collection?e.block:at({block:e.block,localState:e.context.localState,rootState:e.context.rootState,rootSetState:e.context.rootSetState,context:e.context.context});return n.value=f,n.update=!1,f}function s(){return mt({block:a(),registeredComponents:e.registeredComponents,model:e.context.model})}function o(){var y;return e.block.tagName==="a"||((y=a().properties)==null?void 0:y.href)||a().href?e.linkComponent||"a":e.block.tagName||"div"}function l(){var C,x;if((C=e.block.repeat)!=null&&C.collection)return!!((x=t==null?void 0:t())!=null&&x.length);const f="hide"in a()?a().hide:!1;return("show"in a()?a().show:!0)&&!f}function d(){var y,C;return!((y=s==null?void 0:s())!=null&&y.component)&&!t()?(C=a().children)!=null?C:[]:[]}function u(){var f,y,C,x;return{blockChildren:(f=a().children)!=null?f:[],componentRef:(y=s==null?void 0:s())==null?void 0:y.component,componentOptions:{...Je(a(),e.context),...bt(s(),a()),...pt(s(),e.context),...gt(s(),e.linkComponent),...ht(s(),e.registeredComponents,e.context.model)},context:e.context,linkComponent:e.linkComponent,registeredComponents:e.registeredComponents,builderBlock:a(),includeBlockProps:((C=s==null?void 0:s())==null?void 0:C.noWrap)===!0,isInteractive:!((x=s==null?void 0:s())!=null&&x.isRSC&&p.TARGET==="rsc")}}return h.useEffect(()=>{const f=a().id,y=a().animations;y&&f&&rt(y.map(C=>({...C,elementId:f})))},[]),h.useEffect(()=>{n.update=!0}),r.jsx(r.Fragment,{children:l()?r.jsxs(r.Fragment,{children:[r.jsx(yt,{block:a(),context:e.context}),(g=s==null?void 0:s())!=null&&g.noWrap?t()?r.jsx(r.Fragment,{children:(S=t())==null?void 0:S.map((f,y)=>r.jsx(se,{repeatContext:f.context,block:f.block,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent},y))}):r.jsx(re,{componentRef:u().componentRef,componentOptions:u().componentOptions,blockChildren:u().blockChildren,context:u().context,registeredComponents:u().registeredComponents,linkComponent:u().linkComponent,builderBlock:u().builderBlock,includeBlockProps:u().includeBlockProps,isInteractive:u().isInteractive}):r.jsx(r.Fragment,{children:t()?r.jsx(r.Fragment,{children:(c=t())==null?void 0:c.map((f,y)=>r.jsx(se,{repeatContext:f.context,block:f.block,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent},y))}):r.jsxs(Tt,{Wrapper:o(),block:a(),context:e.context,children:[r.jsx(re,{componentRef:u().componentRef,componentOptions:u().componentOptions,blockChildren:u().blockChildren,context:u().context,registeredComponents:u().registeredComponents,linkComponent:u().linkComponent,builderBlock:u().builderBlock,includeBlockProps:u().includeBlockProps,isInteractive:u().isInteractive}),(b=d())==null?void 0:b.map(f=>r.jsx(K,{block:f,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent,context:e.context},f.id))]})})]}):null})}function Rt(e){const t=h.useRef(null);h.useState(()=>!1);function n(){var o;return["builder-blocks",(o=e.blocks)!=null&&o.length?"":"no-blocks",e.classNameProp].filter(Boolean).join(" ")}function i(){if(!e.path)return;const o="this.",l="component.options.";return e.path.startsWith(o)?e.path.replace(o,""):e.path.startsWith(l)?e.path:`${l}${e.path||""}`}function a(){var o,l;p.isEditing()&&!((o=e.blocks)!=null&&o.length)&&((l=window.parent)==null||l.postMessage({type:"builder.clickEmptyBlocks",data:{parentElementId:e.parent,dataPath:i()}},"*"))}function s(){var o,l;p.isEditing()&&!((o=e.blocks)!=null&&o.length)&&((l=window.parent)==null||l.postMessage({type:"builder.hoverEmptyBlocks",data:{parentElementId:e.parent,dataPath:i()}},"*"))}return h.useEffect(()=>{},[]),h.useEffect(()=>{},[e.blocks]),r.jsxs(r.Fragment,{children:[r.jsx(e.BlocksWrapper,{ref:t,className:n()+" props-blocks-wrapper-14802cff","builder-path":i(),"builder-parent-id":e.parent,style:e.styleProp,onClick:o=>a(),onMouseEnter:o=>s(),onKeyPress:o=>a(),...e.BlocksWrapperProps,children:e.children}),r.jsx("style",{children:`.props-blocks-wrapper-14802cff {
|
|
9
9
|
display: flex;
|
|
10
10
|
flex-direction: column;
|
|
11
11
|
align-items: stretch;
|
|
@@ -36,14 +36,14 @@
|
|
|
36
36
|
`}function f(x,T){return{...x.link?{href:x.link}:{},[O()]:"builder-column",style:Ce(b(T))}}return r.jsxs(r.Fragment,{children:[r.jsxs("div",{className:Pt((y=e.builderBlock)==null?void 0:y.id)+" div-a6f3faac",style:g(),children:[r.jsx(L,{id:"builderio-columns",styles:S(),nonce:e.builderContext.nonce}),(C=e.columns)==null?void 0:C.map((x,T)=>r.jsx(ne,{TagName:a(x),actionAttributes:{},attributes:f(x,T),children:r.jsx(A,{path:`columns.${T}.blocks`,parent:e.builderBlock.id,context:e.builderContext,registeredComponents:e.builderComponents,linkComponent:e.builderLinkComponent,blocks:x.blocks,styleProp:{flexGrow:"1"}})},T))]}),r.jsx("style",{children:`.div-a6f3faac {
|
|
37
37
|
display: flex;
|
|
38
38
|
line-height: normal;
|
|
39
|
-
}`})]})}function Pe(e){return r.jsx("span",{children:e.children})}function le(e){return e.replace(/http(s)?:/,"")}function jt(e="",t,n){const i=new RegExp("([?&])"+t+"=.*?(&|$)","i"),a=e.indexOf("?")!==-1?"&":"?";return e.match(i)?e.replace(i,"$1"+t+"="+encodeURIComponent(n)+"$2"):e+a+t+"="+encodeURIComponent(n)}function Vt(e,t){if(!e||!(e!=null&&e.match(/cdn\.shopify\.com/))||!t)return e;if(t==="master")return le(e);const n=e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);if(n){const i=e.split(n[0]),a=n[3],s=t.match("x")?t:`${t}x`;return le(`${i[0]}_${s}${a}`)}return null}function Q(e){if(!e)return e;const t=[100,200,400,800,1200,1600,2e3];if(e.match(/builder\.io/)){let n=e;const i=Number(e.split("?width=")[1]);return isNaN(i)||(n=`${n} ${i}w`),t.filter(a=>a!==i).map(a=>`${jt(e,"width",a)} ${a}w`).concat([n]).join(", ")}return e.match(/cdn\.shopify\.com/)?t.map(n=>[Vt(e,`${n}x${n}`),n]).filter(([n])=>!!n).map(([n,i])=>`${n} ${i}w`).concat([e]).join(", "):e}function je(e){var a,s,o,l,d,u;function t(){var c;const b=e.image||e.src;if(!b||!(typeof b=="string"&&(b.match(/builder\.io/)||b.match(/cdn\.shopify\.com/))))return e.srcset;if(!e.noWebp){if(e.srcset&&((c=e.image)!=null&&c.includes("builder.io/api/v1/image"))){if(!e.srcset.includes(e.image.split("?")[0]))return console.debug("Removed given srcset"),Q(b)}else if(e.image&&!e.srcset)return Q(b);return Q(b)}}function n(){var g;return(g=t==null?void 0:t())!=null&&g.match(/builder\.io/)&&!e.noWebp?t().replace(/\?/g,"?format=webp&"):""}function i(){const g={position:"absolute",height:"100%",width:"100%",left:"0px",top:"0px"};return e.aspectRatio?g:void 0}return r.jsxs(r.Fragment,{children:[r.jsxs(r.Fragment,{children:[r.jsxs("picture",{children:[n()?r.jsx("source",{type:"image/webp",srcSet:n()}):null,r.jsx("img",{loading:e.highPriority?"eager":"lazy",fetchPriority:e.highPriority?"high":"auto",alt:e.altText,role:e.altText?void 0:"presentation",style:{objectPosition:e.backgroundPosition||"center",objectFit:e.backgroundSize||"cover",...i()},className:"builder-image"+(e.className?" "+e.className:"")+" img-
|
|
39
|
+
}`})]})}function Pe(e){return r.jsx("span",{children:e.children})}function le(e){return e.replace(/http(s)?:/,"")}function jt(e="",t,n){const i=new RegExp("([?&])"+t+"=.*?(&|$)","i"),a=e.indexOf("?")!==-1?"&":"?";return e.match(i)?e.replace(i,"$1"+t+"="+encodeURIComponent(n)+"$2"):e+a+t+"="+encodeURIComponent(n)}function Vt(e,t){if(!e||!(e!=null&&e.match(/cdn\.shopify\.com/))||!t)return e;if(t==="master")return le(e);const n=e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);if(n){const i=e.split(n[0]),a=n[3],s=t.match("x")?t:`${t}x`;return le(`${i[0]}_${s}${a}`)}return null}function Q(e){if(!e)return e;const t=[100,200,400,800,1200,1600,2e3];if(e.match(/builder\.io/)){let n=e;const i=Number(e.split("?width=")[1]);return isNaN(i)||(n=`${n} ${i}w`),t.filter(a=>a!==i).map(a=>`${jt(e,"width",a)} ${a}w`).concat([n]).join(", ")}return e.match(/cdn\.shopify\.com/)?t.map(n=>[Vt(e,`${n}x${n}`),n]).filter(([n])=>!!n).map(([n,i])=>`${n} ${i}w`).concat([e]).join(", "):e}function je(e){var a,s,o,l,d,u;function t(){var c;const b=e.image||e.src;if(!b||!(typeof b=="string"&&(b.match(/builder\.io/)||b.match(/cdn\.shopify\.com/))))return e.srcset;if(!e.noWebp){if(e.srcset&&((c=e.image)!=null&&c.includes("builder.io/api/v1/image"))){if(!e.srcset.includes(e.image.split("?")[0]))return console.debug("Removed given srcset"),Q(b)}else if(e.image&&!e.srcset)return Q(b);return Q(b)}}function n(){var g;return(g=t==null?void 0:t())!=null&&g.match(/builder\.io/)&&!e.noWebp?t().replace(/\?/g,"?format=webp&"):""}function i(){const g={position:"absolute",height:"100%",width:"100%",left:"0px",top:"0px"};return e.aspectRatio?g:void 0}return r.jsxs(r.Fragment,{children:[r.jsxs(r.Fragment,{children:[r.jsxs("picture",{children:[n()?r.jsx("source",{type:"image/webp",srcSet:n()}):null,r.jsx("img",{loading:e.highPriority?"eager":"lazy",fetchPriority:e.highPriority?"high":"auto",alt:e.altText,title:e.title,role:e.altText?void 0:"presentation",style:{objectPosition:e.backgroundPosition||"center",objectFit:e.backgroundSize||"cover",...i()},className:"builder-image"+(e.className?" "+e.className:"")+" img-1aa8aba3",src:e.image,srcSet:t(),sizes:e.sizes})]}),e.aspectRatio&&!((s=(a=e.builderBlock)==null?void 0:a.children)!=null&&s.length&&e.fitContent)?r.jsx("div",{className:"builder-image-sizer div-1aa8aba3",style:{paddingTop:e.aspectRatio*100+"%"}}):null,(l=(o=e.builderBlock)==null?void 0:o.children)!=null&&l.length&&e.fitContent?r.jsx(r.Fragment,{children:e.children}):null,!e.fitContent&&((u=(d=e.builderBlock)==null?void 0:d.children)!=null&&u.length)?r.jsx("div",{className:"div-1aa8aba3-2",children:e.children}):null]}),r.jsx("style",{children:`.img-1aa8aba3 {
|
|
40
40
|
opacity: 1;
|
|
41
41
|
transition: opacity 0.2s ease-in-out;
|
|
42
|
-
}.div-
|
|
42
|
+
}.div-1aa8aba3 {
|
|
43
43
|
width: 100%;
|
|
44
44
|
pointer-events: none;
|
|
45
45
|
font-size: 0;
|
|
46
|
-
}.div-
|
|
46
|
+
}.div-1aa8aba3-2 {
|
|
47
47
|
display: flex;
|
|
48
48
|
flex-direction: column;
|
|
49
49
|
align-items: stretch;
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
left: 0;
|
|
53
53
|
width: 100%;
|
|
54
54
|
height: 100%;
|
|
55
|
-
}`})]})}function Ve(e){return r.jsx("section",{...e.attributes,style:{width:"100%",alignSelf:"stretch",flexGrow:1,boxSizing:"border-box",maxWidth:e.maxWidth||1200,display:"flex",flexDirection:"column",alignItems:"stretch",marginLeft:"auto",marginRight:"auto"},children:e.children})}const Y={"@type":"@builder.io/sdk:Element",layerName:"Accordion item title",responsiveStyles:{large:{marginTop:"10px",position:"relative",display:"flex",alignItems:"stretch",flexDirection:"column",paddingBottom:"10px"}},children:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"left",display:"flex",flexDirection:"column"}},component:{name:"Text",options:{text:"I am an accordion title. Click me!"}}}]},X={"@type":"@builder.io/sdk:Element",layerName:"Accordion item detail",responsiveStyles:{large:{position:"relative",display:"flex",alignItems:"stretch",flexDirection:"column",marginTop:"10px",paddingBottom:"10px"}},children:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{paddingTop:"50px",textAlign:"left",display:"flex",flexDirection:"column",paddingBottom:"50px"}},component:{name:"Text",options:{text:"I am an accordion detail, hello!"}}}]},Bt={name:"Builder:Accordion",canHaveChildren:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",defaultStyles:{display:"flex",flexDirection:"column",alignItems:"stretch"},inputs:[{name:"items",type:"list",broadcast:!0,subFields:[{name:"title",type:"uiBlocks",hideFromUI:!0,defaultValue:[Y]},{name:"detail",type:"uiBlocks",hideFromUI:!0,defaultValue:[X]}],defaultValue:[{title:[Y],detail:[X]},{title:[Y],detail:[X]}],showIf:e=>!e.get("useChildrenForItems")},{name:"oneAtATime",helperText:"Only allow opening one at a time (collapse all others when new item openned)",type:"boolean",defaultValue:!1},{name:"grid",helperText:"Display as a grid",type:"boolean",defaultValue:!1},{name:"gridRowWidth",helperText:"Display as a grid",type:"string",showIf:e=>e.get("grid"),defaultValue:"25%"},{name:"useChildrenForItems",type:"boolean",helperText:"Use child elements for each slide, instead of the array. Useful for dynamically repeating items",advanced:!0,defaultValue:!1,onChange:e=>{e.get("useChildrenForItems")===!0&&e.set("items",[])}}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},ce=e=>e.toString();function At(e){var b;const[t,n]=h.useState(()=>[]);function i(){return!!(e.grid||e.oneAtATime)}function a(){return{display:"flex",alignItems:"stretch",flexDirection:"column",...e.grid&&{flexDirection:"row",alignItems:"flex-start",flexWrap:"wrap"}}}function s(){const S={...{display:"flex",flexDirection:"column"},alignItems:"stretch",cursor:"pointer"};return Object.fromEntries(Object.entries(S).filter(([f,y])=>y!==void 0))}function o(c){return`builder-accordion-title builder-accordion-title-${t.includes(c)?"open":"closed"}`}function l(c){return`builder-accordion-detail builder-accordion-detail-${t.includes(c)?"open":"closed"}`}function d(){let c=null;if(e.grid&&t.length&&document){const f=t[0];let C=document.querySelector(`.builder-accordion-title[data-index="${f}"]`);if(c=f,C){let x=C.getBoundingClientRect();for(;C=C&&C.nextElementSibling;)if(C){if(C.classList.contains("builder-accordion-detail"))continue;const T=C.getBoundingClientRect();if(T.left>x.left){const w=parseInt(C.getAttribute("data-index")||"",10);isNaN(w)||(x=T,c=w)}else break}}}return typeof c=="number"&&(c=c+1),c}function u(){const c={order:typeof d()=="number"?d():void 0,...e.grid&&{width:"100%"}};return Object.fromEntries(Object.entries(c).filter(([S,f])=>f!==void 0))}function g(c){t.includes(c)?n(i()?[]:t.filter(S=>S!==c)):n(i()?[c]:t.concat(c))}return r.jsx("div",{className:"builder-accordion",style:a(),children:(b=e.items)==null?void 0:b.map((c,S)=>r.jsxs(Ue.Fragment,{children:[r.jsx("div",{className:o(S),style:{...s(),...e.grid&&{width:e.gridRowWidth,order:d()!==null?ce(S):ce(S+1)}},"data-index":S,onClick:f=>g(S),children:r.jsx(A,{blocks:c.title,path:`items.${S}.title`,parent:e.builderBlock.id,context:e.builderContext,registeredComponents:e.builderComponents,linkComponent:e.builderLinkComponent})}),t.includes(S)?r.jsx("div",{className:l(S),style:u(),children:r.jsx(A,{blocks:c.detail,path:`items.${S}.detail`,parent:e.builderBlock.id,context:e.builderContext,registeredComponents:e.builderComponents,linkComponent:e.builderLinkComponent})}):null]},S))})}const Nt={name:"Core:Button",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",defaultStyles:{appearance:"none",paddingTop:"15px",paddingBottom:"15px",paddingLeft:"25px",paddingRight:"25px",backgroundColor:"#000000",color:"white",borderRadius:"4px",textAlign:"center",cursor:"pointer"},inputs:[{name:"text",type:"text",defaultValue:"Click me!",bubble:!0},{name:"link",type:"url",bubble:!0},{name:"openLinkInNewTab",type:"boolean",defaultValue:!1,friendlyName:"Open link in new tab"}],static:!0,noWrap:!0,shouldReceiveBuilderProps:{builderLinkComponent:!0}},Ft={name:"Columns",isRSC:!0,inputs:[{name:"columns",type:"array",broadcast:!0,subFields:[{name:"blocks",type:"array",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{name:"width",type:"number",hideFromUI:!0,helperText:"Width %, e.g. set to 50 to fill half of the space"},{name:"link",type:"url",helperText:"Optionally set a url that clicking this column will link to"}],defaultValue:[{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]}],onChange:e=>{function t(){n.forEach(i=>{i.delete("width")})}const n=e.get("columns");Array.isArray(n)&&n.find(a=>a.get("width"))&&(n.find(s=>!s.get("width"))||n.reduce((l,d)=>l+d.get("width"),0)!==100)&&t()}},{name:"space",type:"number",defaultValue:20,helperText:"Size of gap between columns",advanced:!0},{name:"stackColumnsAt",type:"string",defaultValue:"tablet",helperText:"Convert horizontal columns to vertical at what device size",enum:["tablet","mobile","never"],advanced:!0},{name:"reverseColumnsWhenStacked",type:"boolean",defaultValue:!1,helperText:"When stacking columns for mobile devices, reverse the ordering",advanced:!0}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},Wt={name:"Fragment",static:!0,hidden:!0,canHaveChildren:!0,noWrap:!0},ae=["jpeg","jpg","png","svg","webp","gif","jfif","pjpeg","pjp","apng","avif","tif","tiff","heif","bmp","eps","raw","cr2","nef","orf","sr2","psd","heic","dib","ai"],Dt=["mp4","webm","mkv","flv","vob","ogv","ogg","drc","gif","gifv","mng","avi","mov","qt","mts","m2ts","ts","wmv","yuv","rm","rmvb","viv","asf","amv","m4p","mpeg","mpe","m2v","m4v","svi","3gp","3g2","mxf","roq","nsv","f4v","f4p","f4a","f4b"],$t={name:"Image",static:!0,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",defaultStyles:{position:"relative",minHeight:"20px",minWidth:"20px",overflow:"hidden"},canHaveChildren:!0,inputs:[{name:"image",type:"file",bubble:!0,allowedFileTypes:ae,required:!0,defaultValue:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",onChange:e=>{e.delete("srcset"),e.delete("noWebp");function n(o,l=6e4){return new Promise((d,u)=>{const g=document.createElement("img");let b=!1;g.onload=()=>{b=!0,d(g)},g.addEventListener("error",c=>{console.warn("Image load failed",c.error),u(c.error)}),g.src=o,setTimeout(()=>{b||u(new Error("Image load timed out"))},l)})}function i(o){return Math.round(o*1e3)/1e3}const a=e.get("image"),s=e.get("aspectRatio");if(fetch(a).then(o=>o.blob()).then(o=>{o.type.includes("svg")&&e.set("noWebp",!0)}),a&&(!s||s===.7041))return n(a).then(o=>{const l=e.get("aspectRatio");e.get("image")===a&&(!l||l===.7041)&&o.width&&o.height&&(e.set("aspectRatio",i(o.height/o.width)),e.set("height",o.height),e.set("width",o.width))})}},{name:"backgroundSize",type:"text",defaultValue:"cover",enum:[{label:"contain",value:"contain",helperText:"The image should never get cropped"},{label:"cover",value:"cover",helperText:"The image should fill it's box, cropping when needed"}]},{name:"backgroundPosition",type:"text",defaultValue:"center",enum:["center","top","left","right","bottom","top left","top right","bottom left","bottom right"]},{name:"altText",type:"string",helperText:"Text to display when the user has images off"},{name:"height",type:"number",hideFromUI:!0},{name:"width",type:"number",hideFromUI:!0},{name:"sizes",type:"string",hideFromUI:!0},{name:"srcset",type:"string",hideFromUI:!0},{name:"lazy",type:"boolean",defaultValue:!0,hideFromUI:!0},{name:"fitContent",type:"boolean",helperText:"When child blocks are provided, fit to them instead of using the image's aspect ratio",defaultValue:!0},{name:"highPriority",type:"boolean",advanced:!0,helperText:"Mark this image as high priority compared to other images on the page. This prevents lazy loading of the image and tells the browser to load this image before others on the page."},{name:"aspectRatio",type:"number",helperText:"This is the ratio of height/width, e.g. set to 1.5 for a 300px wide and 200px tall photo. Set to 0 to not force the image to maintain it's aspect ratio",advanced:!0,defaultValue:.7041}],shouldReceiveBuilderProps:{builderBlock:!0}},Ot={name:"PersonalizationContainer",shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0},noWrap:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F37229ed30d8c41dfb10b8cca1992053a",canHaveChildren:!0,inputs:[{name:"variants",defaultValue:[],behavior:"personalizationVariantList",type:"list",subFields:[{name:"name",type:"text"},{name:"query",friendlyName:"Targeting rules",type:"BuilderQuery",defaultValue:[]},{name:"startDate",type:"date"},{name:"endDate",type:"date"},{name:"blocks",type:"uiBlocks",hideFromUI:!0,defaultValue:[]}]}]};function M(e){return r.jsx("script",{dangerouslySetInnerHTML:{__html:e.scriptStr},"data-id":e.id,nonce:e.nonce||""})}function Lt(e,t,n,i){function a(u){return typeof u=="string"}function s(u){return typeof u=="number"}function o(u,g){return(()=>{const c=g.property,S=g.operator;let f=g.value;if(g&&g.property==="urlPath"&&g.value&&typeof g.value=="string"&&g.value!=="/"&&g.value.endsWith("/")&&(f=g.value.slice(0,-1)),!(c&&S))return!0;if(Array.isArray(f))return S==="isNot"?f.every(C=>o(u,{property:c,operator:S,value:C})):!!f.find(C=>o(u,{property:c,operator:S,value:C}));const y=u[c];if(Array.isArray(y))return y.includes(f);switch(S){case"is":return y===f;case"isNot":return y!==f;case"contains":return(a(y)||Array.isArray(y))&&y.includes(String(f));case"startsWith":return a(y)&&y.startsWith(String(f));case"endsWith":return a(y)&&y.endsWith(String(f));case"greaterThan":return s(y)&&s(f)&&y>f;case"lessThan":return s(y)&&s(f)&&y<f;case"greaterThanOrEqualTo":return s(y)&&s(f)&&y>=f;case"lessThanOrEqualTo":return s(y)&&s(f)&&y<=f;default:return!1}})()}const l={query:t,startDate:n,endDate:i},d=e.date&&new Date(e.date)||new Date;return l.startDate&&new Date(l.startDate)>d||l.endDate&&new Date(l.endDate)<d?!1:!l.query||!l.query.length?!0:l.query.every(u=>o(e,u))}const Ut=`function getPersonalizedVariant(variants, blockId, locale) {
|
|
55
|
+
}`})]})}function Ve(e){return r.jsx("section",{...e.attributes,style:{width:"100%",alignSelf:"stretch",flexGrow:1,boxSizing:"border-box",maxWidth:e.maxWidth||1200,display:"flex",flexDirection:"column",alignItems:"stretch",marginLeft:"auto",marginRight:"auto"},children:e.children})}const Y={"@type":"@builder.io/sdk:Element",layerName:"Accordion item title",responsiveStyles:{large:{marginTop:"10px",position:"relative",display:"flex",alignItems:"stretch",flexDirection:"column",paddingBottom:"10px"}},children:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"left",display:"flex",flexDirection:"column"}},component:{name:"Text",options:{text:"I am an accordion title. Click me!"}}}]},X={"@type":"@builder.io/sdk:Element",layerName:"Accordion item detail",responsiveStyles:{large:{position:"relative",display:"flex",alignItems:"stretch",flexDirection:"column",marginTop:"10px",paddingBottom:"10px"}},children:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{paddingTop:"50px",textAlign:"left",display:"flex",flexDirection:"column",paddingBottom:"50px"}},component:{name:"Text",options:{text:"I am an accordion detail, hello!"}}}]},Bt={name:"Builder:Accordion",canHaveChildren:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FagZ9n5CUKRfbL9t6CaJOyVSK4Es2%2Ffab6c1fd3fe542408cbdec078bca7f35",defaultStyles:{display:"flex",flexDirection:"column",alignItems:"stretch"},inputs:[{name:"items",type:"list",broadcast:!0,subFields:[{name:"title",type:"uiBlocks",hideFromUI:!0,defaultValue:[Y]},{name:"detail",type:"uiBlocks",hideFromUI:!0,defaultValue:[X]}],defaultValue:[{title:[Y],detail:[X]},{title:[Y],detail:[X]}],showIf:e=>!e.get("useChildrenForItems")},{name:"oneAtATime",helperText:"Only allow opening one at a time (collapse all others when new item openned)",type:"boolean",defaultValue:!1},{name:"grid",helperText:"Display as a grid",type:"boolean",defaultValue:!1},{name:"gridRowWidth",helperText:"Display as a grid",type:"string",showIf:e=>e.get("grid"),defaultValue:"25%"},{name:"useChildrenForItems",type:"boolean",helperText:"Use child elements for each slide, instead of the array. Useful for dynamically repeating items",advanced:!0,defaultValue:!1,onChange:e=>{e.get("useChildrenForItems")===!0&&e.set("items",[])}}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},ce=e=>e.toString();function At(e){var b;const[t,n]=h.useState(()=>[]);function i(){return!!(e.grid||e.oneAtATime)}function a(){return{display:"flex",alignItems:"stretch",flexDirection:"column",...e.grid&&{flexDirection:"row",alignItems:"flex-start",flexWrap:"wrap"}}}function s(){const S={...{display:"flex",flexDirection:"column"},alignItems:"stretch",cursor:"pointer"};return Object.fromEntries(Object.entries(S).filter(([f,y])=>y!==void 0))}function o(c){return`builder-accordion-title builder-accordion-title-${t.includes(c)?"open":"closed"}`}function l(c){return`builder-accordion-detail builder-accordion-detail-${t.includes(c)?"open":"closed"}`}function d(){let c=null;if(e.grid&&t.length&&document){const f=t[0];let C=document.querySelector(`.builder-accordion-title[data-index="${f}"]`);if(c=f,C){let x=C.getBoundingClientRect();for(;C=C&&C.nextElementSibling;)if(C){if(C.classList.contains("builder-accordion-detail"))continue;const T=C.getBoundingClientRect();if(T.left>x.left){const w=parseInt(C.getAttribute("data-index")||"",10);isNaN(w)||(x=T,c=w)}else break}}}return typeof c=="number"&&(c=c+1),c}function u(){const c={order:typeof d()=="number"?d():void 0,...e.grid&&{width:"100%"}};return Object.fromEntries(Object.entries(c).filter(([S,f])=>f!==void 0))}function g(c){t.includes(c)?n(i()?[]:t.filter(S=>S!==c)):n(i()?[c]:t.concat(c))}return r.jsx("div",{className:"builder-accordion",style:a(),children:(b=e.items)==null?void 0:b.map((c,S)=>r.jsxs(Ue.Fragment,{children:[r.jsx("div",{className:o(S),style:{...s(),...e.grid&&{width:e.gridRowWidth,order:d()!==null?ce(S):ce(S+1)}},"data-index":S,onClick:f=>g(S),children:r.jsx(A,{blocks:c.title,path:`items.${S}.title`,parent:e.builderBlock.id,context:e.builderContext,registeredComponents:e.builderComponents,linkComponent:e.builderLinkComponent})}),t.includes(S)?r.jsx("div",{className:l(S),style:u(),children:r.jsx(A,{blocks:c.detail,path:`items.${S}.detail`,parent:e.builderBlock.id,context:e.builderContext,registeredComponents:e.builderComponents,linkComponent:e.builderLinkComponent})}):null]},S))})}const Nt={name:"Core:Button",image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",defaultStyles:{appearance:"none",paddingTop:"15px",paddingBottom:"15px",paddingLeft:"25px",paddingRight:"25px",backgroundColor:"#000000",color:"white",borderRadius:"4px",textAlign:"center",cursor:"pointer"},inputs:[{name:"text",type:"text",defaultValue:"Click me!",bubble:!0},{name:"link",type:"url",bubble:!0},{name:"openLinkInNewTab",type:"boolean",defaultValue:!1,friendlyName:"Open link in new tab"}],static:!0,noWrap:!0,shouldReceiveBuilderProps:{builderLinkComponent:!0}},Ft={name:"Columns",isRSC:!0,inputs:[{name:"columns",type:"array",broadcast:!0,subFields:[{name:"blocks",type:"array",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{name:"width",type:"number",hideFromUI:!0,helperText:"Width %, e.g. set to 50 to fill half of the space"},{name:"link",type:"url",helperText:"Optionally set a url that clicking this column will link to"}],defaultValue:[{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]}],onChange:e=>{function t(){n.forEach(i=>{i.delete("width")})}const n=e.get("columns");Array.isArray(n)&&n.find(a=>a.get("width"))&&(n.find(s=>!s.get("width"))||n.reduce((l,d)=>l+d.get("width"),0)!==100)&&t()}},{name:"space",type:"number",defaultValue:20,helperText:"Size of gap between columns",advanced:!0},{name:"stackColumnsAt",type:"string",defaultValue:"tablet",helperText:"Convert horizontal columns to vertical at what device size",enum:["tablet","mobile","never"],advanced:!0},{name:"reverseColumnsWhenStacked",type:"boolean",defaultValue:!1,helperText:"When stacking columns for mobile devices, reverse the ordering",advanced:!0}],shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0,builderComponents:!0,builderLinkComponent:!0}},Wt={name:"Fragment",static:!0,hidden:!0,canHaveChildren:!0,noWrap:!0},ae=["jpeg","jpg","png","svg","webp","gif","jfif","pjpeg","pjp","apng","avif","tif","tiff","heif","bmp","eps","raw","cr2","nef","orf","sr2","psd","heic","dib","ai"],Dt=["mp4","webm","mkv","flv","vob","ogv","ogg","drc","gif","gifv","mng","avi","mov","qt","mts","m2ts","ts","wmv","yuv","rm","rmvb","viv","asf","amv","m4p","mpeg","mpe","m2v","m4v","svi","3gp","3g2","mxf","roq","nsv","f4v","f4p","f4a","f4b"],$t={name:"Image",static:!0,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",defaultStyles:{position:"relative",minHeight:"20px",minWidth:"20px",overflow:"hidden"},canHaveChildren:!0,inputs:[{name:"image",type:"file",bubble:!0,allowedFileTypes:ae,required:!0,defaultValue:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",onChange:e=>{e.delete("srcset"),e.delete("noWebp");function n(o,l=6e4){return new Promise((d,u)=>{const g=document.createElement("img");let b=!1;g.onload=()=>{b=!0,d(g)},g.addEventListener("error",c=>{console.warn("Image load failed",c.error),u(c.error)}),g.src=o,setTimeout(()=>{b||u(new Error("Image load timed out"))},l)})}function i(o){return Math.round(o*1e3)/1e3}const a=e.get("image"),s=e.get("aspectRatio");if(fetch(a).then(o=>o.blob()).then(o=>{o.type.includes("svg")&&e.set("noWebp",!0)}),a&&(!s||s===.7041))return n(a).then(o=>{const l=e.get("aspectRatio");e.get("image")===a&&(!l||l===.7041)&&o.width&&o.height&&(e.set("aspectRatio",i(o.height/o.width)),e.set("height",o.height),e.set("width",o.width))})}},{name:"backgroundSize",type:"text",defaultValue:"cover",enum:[{label:"contain",value:"contain",helperText:"The image should never get cropped"},{label:"cover",value:"cover",helperText:"The image should fill it's box, cropping when needed"}]},{name:"backgroundPosition",type:"text",defaultValue:"center",enum:["center","top","left","right","bottom","top left","top right","bottom left","bottom right"]},{name:"altText",type:"string",helperText:"Text to display when the user has images off"},{name:"title",type:"string",helperText:"Text to display when hovering over the asset"},{name:"height",type:"number",hideFromUI:!0},{name:"width",type:"number",hideFromUI:!0},{name:"sizes",type:"string",hideFromUI:!0},{name:"srcset",type:"string",hideFromUI:!0},{name:"lazy",type:"boolean",defaultValue:!0,hideFromUI:!0},{name:"fitContent",type:"boolean",helperText:"When child blocks are provided, fit to them instead of using the image's aspect ratio",defaultValue:!0},{name:"highPriority",type:"boolean",advanced:!0,helperText:"Mark this image as high priority compared to other images on the page. This prevents lazy loading of the image and tells the browser to load this image before others on the page."},{name:"aspectRatio",type:"number",helperText:"This is the ratio of height/width, e.g. set to 1.5 for a 300px wide and 200px tall photo. Set to 0 to not force the image to maintain it's aspect ratio",advanced:!0,defaultValue:.7041}],shouldReceiveBuilderProps:{builderBlock:!0}},Ot={name:"PersonalizationContainer",shouldReceiveBuilderProps:{builderBlock:!0,builderContext:!0},noWrap:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F37229ed30d8c41dfb10b8cca1992053a",canHaveChildren:!0,inputs:[{name:"variants",defaultValue:[],behavior:"personalizationVariantList",type:"list",subFields:[{name:"name",type:"text"},{name:"query",friendlyName:"Targeting rules",type:"BuilderQuery",defaultValue:[]},{name:"startDate",type:"date"},{name:"endDate",type:"date"},{name:"blocks",type:"uiBlocks",hideFromUI:!0,defaultValue:[]}]}]};function M(e){return r.jsx("script",{dangerouslySetInnerHTML:{__html:e.scriptStr},"data-id":e.id,nonce:e.nonce||""})}function Lt(e,t,n,i){function a(u){return typeof u=="string"}function s(u){return typeof u=="number"}function o(u,g){return(()=>{const c=g.property,S=g.operator;let f=g.value;if(g&&g.property==="urlPath"&&g.value&&typeof g.value=="string"&&g.value!=="/"&&g.value.endsWith("/")&&(f=g.value.slice(0,-1)),!(c&&S))return!0;if(Array.isArray(f))return S==="isNot"?f.every(C=>o(u,{property:c,operator:S,value:C})):!!f.find(C=>o(u,{property:c,operator:S,value:C}));const y=u[c];if(Array.isArray(y))return y.includes(f);switch(S){case"is":return y===f;case"isNot":return y!==f;case"contains":return(a(y)||Array.isArray(y))&&y.includes(String(f));case"startsWith":return a(y)&&y.startsWith(String(f));case"endsWith":return a(y)&&y.endsWith(String(f));case"greaterThan":return s(y)&&s(f)&&y>f;case"lessThan":return s(y)&&s(f)&&y<f;case"greaterThanOrEqualTo":return s(y)&&s(f)&&y>=f;case"lessThanOrEqualTo":return s(y)&&s(f)&&y<=f;default:return!1}})()}const l={query:t,startDate:n,endDate:i},d=e.date&&new Date(e.date)||new Date;return l.startDate&&new Date(l.startDate)>d||l.endDate&&new Date(l.endDate)<d?!1:!l.query||!l.query.length?!0:l.query.every(u=>o(e,u))}const Ut=`function getPersonalizedVariant(variants, blockId, locale) {
|
|
56
56
|
if (!navigator.cookieEnabled) {
|
|
57
57
|
return;
|
|
58
58
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { TARGET as O, isBrowser as U, logger as z, checkIsDefined as se, isPreviewing as X, isEditing as N, userAttributesService as be, getDefaultCanTrack as M, logFetch as Ve, registerInsertMenu as Ge, setupBrowserForEditing as Qe, createRegisterComponentMessage as Ye, getCookieSync as Xe, _track as pe, fetchOneEntry as Pe, createEditorListener as Ze, serializeIncludingFunctions as ye, handleABTestingSync as et } from "./server-entry-
|
|
3
|
-
import { setClientUserAttributes as Ri } from "./server-entry-
|
|
2
|
+
import { TARGET as O, isBrowser as U, logger as z, checkIsDefined as se, isPreviewing as X, isEditing as N, userAttributesService as be, getDefaultCanTrack as M, logFetch as Ve, registerInsertMenu as Ge, setupBrowserForEditing as Qe, createRegisterComponentMessage as Ye, getCookieSync as Xe, _track as pe, fetchOneEntry as Pe, createEditorListener as Ze, serializeIncludingFunctions as ye, handleABTestingSync as et } from "./server-entry-d38415f3.js";
|
|
3
|
+
import { setClientUserAttributes as Ri } from "./server-entry-d38415f3.js";
|
|
4
4
|
import { jsx as s, Fragment as R, jsxs as B } from "react/jsx-runtime";
|
|
5
5
|
import * as tt from "react";
|
|
6
6
|
import { createContext as Be, useEffect as P, useState as I, useRef as L, useContext as ve, createElement as Ae } from "react";
|
|
7
|
-
import { getFunctionArguments as nt, flattenState as it, runInNode as at, parseCode as ot, getBuilderGlobals as rt, set as Ne, fastClone as ue } from "./setIvm-
|
|
8
|
-
import { shouldForceBrowserRuntimeInNode as lt } from "./should-force-browser-runtime-in-node-
|
|
7
|
+
import { getFunctionArguments as nt, flattenState as it, runInNode as at, parseCode as ot, getBuilderGlobals as rt, set as Ne, fastClone as ue } from "./setIvm-9fe8e65a.js";
|
|
8
|
+
import { shouldForceBrowserRuntimeInNode as lt } from "./should-force-browser-runtime-in-node-eb6e6ea4.js";
|
|
9
9
|
const st = /* @__PURE__ */ new Set(["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]), ct = (e) => typeof e == "string" && st.has(e.toLowerCase());
|
|
10
10
|
function de(e) {
|
|
11
11
|
return /* @__PURE__ */ s(R, { children: ct(e.TagName) ? /* @__PURE__ */ s(R, { children: /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ s(R, { children: typeof e.TagName == "string" ? /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) : /* @__PURE__ */ s(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) });
|
|
@@ -963,6 +963,7 @@ function ee(e) {
|
|
|
963
963
|
}
|
|
964
964
|
function Gt(e) {
|
|
965
965
|
const t = L(null);
|
|
966
|
+
I(() => !1);
|
|
966
967
|
function n() {
|
|
967
968
|
var o;
|
|
968
969
|
return [
|
|
@@ -1004,12 +1005,13 @@ function Gt(e) {
|
|
|
1004
1005
|
));
|
|
1005
1006
|
}
|
|
1006
1007
|
return P(() => {
|
|
1007
|
-
}, []),
|
|
1008
|
+
}, []), P(() => {
|
|
1009
|
+
}, [e.blocks]), /* @__PURE__ */ B(R, { children: [
|
|
1008
1010
|
/* @__PURE__ */ s(
|
|
1009
1011
|
e.BlocksWrapper,
|
|
1010
1012
|
{
|
|
1011
1013
|
ref: t,
|
|
1012
|
-
className: n() + " props-blocks-wrapper-
|
|
1014
|
+
className: n() + " props-blocks-wrapper-14802cff",
|
|
1013
1015
|
"builder-path": i(),
|
|
1014
1016
|
"builder-parent-id": e.parent,
|
|
1015
1017
|
style: e.styleProp,
|
|
@@ -1020,7 +1022,7 @@ function Gt(e) {
|
|
|
1020
1022
|
children: e.children
|
|
1021
1023
|
}
|
|
1022
1024
|
),
|
|
1023
|
-
/* @__PURE__ */ s("style", { children: `.props-blocks-wrapper-
|
|
1025
|
+
/* @__PURE__ */ s("style", { children: `.props-blocks-wrapper-14802cff {
|
|
1024
1026
|
display: flex;
|
|
1025
1027
|
flex-direction: column;
|
|
1026
1028
|
align-items: stretch;
|
|
@@ -1293,13 +1295,14 @@ function tn(e) {
|
|
|
1293
1295
|
loading: e.highPriority ? "eager" : "lazy",
|
|
1294
1296
|
fetchPriority: e.highPriority ? "high" : "auto",
|
|
1295
1297
|
alt: e.altText,
|
|
1298
|
+
title: e.title,
|
|
1296
1299
|
role: e.altText ? void 0 : "presentation",
|
|
1297
1300
|
style: {
|
|
1298
1301
|
objectPosition: e.backgroundPosition || "center",
|
|
1299
1302
|
objectFit: e.backgroundSize || "cover",
|
|
1300
1303
|
...i()
|
|
1301
1304
|
},
|
|
1302
|
-
className: "builder-image" + (e.className ? " " + e.className : "") + " img-
|
|
1305
|
+
className: "builder-image" + (e.className ? " " + e.className : "") + " img-1aa8aba3",
|
|
1303
1306
|
src: e.image,
|
|
1304
1307
|
srcSet: t(),
|
|
1305
1308
|
sizes: e.sizes
|
|
@@ -1309,23 +1312,23 @@ function tn(e) {
|
|
|
1309
1312
|
e.aspectRatio && !((r = (a = e.builderBlock) == null ? void 0 : a.children) != null && r.length && e.fitContent) ? /* @__PURE__ */ s(
|
|
1310
1313
|
"div",
|
|
1311
1314
|
{
|
|
1312
|
-
className: "builder-image-sizer div-
|
|
1315
|
+
className: "builder-image-sizer div-1aa8aba3",
|
|
1313
1316
|
style: {
|
|
1314
1317
|
paddingTop: e.aspectRatio * 100 + "%"
|
|
1315
1318
|
}
|
|
1316
1319
|
}
|
|
1317
1320
|
) : null,
|
|
1318
1321
|
(l = (o = e.builderBlock) == null ? void 0 : o.children) != null && l.length && e.fitContent ? /* @__PURE__ */ s(R, { children: e.children }) : null,
|
|
1319
|
-
!e.fitContent && ((u = (d = e.builderBlock) == null ? void 0 : d.children) != null && u.length) ? /* @__PURE__ */ s("div", { className: "div-
|
|
1322
|
+
!e.fitContent && ((u = (d = e.builderBlock) == null ? void 0 : d.children) != null && u.length) ? /* @__PURE__ */ s("div", { className: "div-1aa8aba3-2", children: e.children }) : null
|
|
1320
1323
|
] }),
|
|
1321
|
-
/* @__PURE__ */ s("style", { children: `.img-
|
|
1324
|
+
/* @__PURE__ */ s("style", { children: `.img-1aa8aba3 {
|
|
1322
1325
|
opacity: 1;
|
|
1323
1326
|
transition: opacity 0.2s ease-in-out;
|
|
1324
|
-
}.div-
|
|
1327
|
+
}.div-1aa8aba3 {
|
|
1325
1328
|
width: 100%;
|
|
1326
1329
|
pointer-events: none;
|
|
1327
1330
|
font-size: 0;
|
|
1328
|
-
}.div-
|
|
1331
|
+
}.div-1aa8aba3-2 {
|
|
1329
1332
|
display: flex;
|
|
1330
1333
|
flex-direction: column;
|
|
1331
1334
|
align-items: stretch;
|
|
@@ -1924,6 +1927,10 @@ const rn = {
|
|
|
1924
1927
|
name: "altText",
|
|
1925
1928
|
type: "string",
|
|
1926
1929
|
helperText: "Text to display when the user has images off"
|
|
1930
|
+
}, {
|
|
1931
|
+
name: "title",
|
|
1932
|
+
type: "string",
|
|
1933
|
+
helperText: "Text to display when hovering over the asset"
|
|
1927
1934
|
}, {
|
|
1928
1935
|
name: "height",
|
|
1929
1936
|
type: "number",
|
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-a7413c09.cjs");require("react/jsx-runtime");require("react");require("./setIvm-0a044ac8.cjs");require("./should-force-browser-runtime-in-node-e4a9bd6b.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.setClientUserAttributes=e.setClientUserAttributes;exports.setEditorSettings=e.setEditorSettings;exports.subscribeToEditor=e.subscribeToEditor;exports.track=e.track;
|
package/lib/node/index.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Blocks as n, BuilderContext as m, Button as c, Columns as g, Content as p, Fragment as a, Image as l, Section as u, Symbol as d, Text as C, Video as f } from "./blocks-exports.mjs";
|
|
2
|
-
import { _processContentResult as E, createRegisterComponentMessage as b, fetchBuilderProps as h, fetchEntries as x, fetchOneEntry as S, getBuilderSearchParams as P, isEditing as k, isPreviewing as y, register as R, setClientUserAttributes as T, setEditorSettings as v, subscribeToEditor as w, track as A } from "./server-entry-
|
|
2
|
+
import { _processContentResult as E, createRegisterComponentMessage as b, fetchBuilderProps as h, fetchEntries as x, fetchOneEntry as S, getBuilderSearchParams as P, isEditing as k, isPreviewing as y, register as R, setClientUserAttributes as T, setEditorSettings as v, subscribeToEditor as w, track as A } from "./server-entry-d38415f3.js";
|
|
3
3
|
import "react/jsx-runtime";
|
|
4
4
|
import "react";
|
|
5
|
-
import "./setIvm-
|
|
6
|
-
import "./should-force-browser-runtime-in-node-
|
|
5
|
+
import "./setIvm-9fe8e65a.js";
|
|
6
|
+
import "./should-force-browser-runtime-in-node-eb6e6ea4.js";
|
|
7
7
|
export {
|
|
8
8
|
n as Blocks,
|
|
9
9
|
m as BuilderContext,
|
package/lib/node/init.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./should-force-browser-runtime-in-node-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./should-force-browser-runtime-in-node-e4a9bd6b.cjs"),t=require("isolated-vm"),r=require("./setIvm-0a044ac8.cjs");require("./server-entry-a7413c09.cjs");const n=e=>{if(o.shouldForceBrowserRuntimeInNode({shouldLogWarning:!0}))return;const{ivmIsolateOptions:i}=e||{};r.setIvm(t,i)};exports.initializeNodeRuntime=n;
|
package/lib/node/init.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { shouldForceBrowserRuntimeInNode as r } from "./should-force-browser-runtime-in-node-
|
|
1
|
+
import { shouldForceBrowserRuntimeInNode as r } from "./should-force-browser-runtime-in-node-eb6e6ea4.js";
|
|
2
2
|
import t from "isolated-vm";
|
|
3
|
-
import { setIvm as e } from "./setIvm-
|
|
4
|
-
import "./server-entry-
|
|
3
|
+
import { setIvm as e } from "./setIvm-9fe8e65a.js";
|
|
4
|
+
import "./server-entry-d38415f3.js";
|
|
5
5
|
const u = (o) => {
|
|
6
6
|
if (r({
|
|
7
7
|
shouldLogWarning: !0
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const y="react",E="[Builder.io]: ",d={log:(...t)=>console.log(E,...t),error:(...t)=>console.error(E,...t),warn:(...t)=>console.warn(E,...t),debug:(...t)=>console.debug(E,...t)};function c(){return typeof window!="undefined"&&typeof document!="undefined"}const mt=t=>{const e={};return t.forEach((n,r)=>{e[r]=n}),e},j=t=>t instanceof URLSearchParams?mt(t):t,W=t=>typeof t=="string"?t:t instanceof URLSearchParams?t.toString():new URLSearchParams(t).toString();function bt(){return c()&&window.self!==window.top}function G(t){return bt()&&W(t||window.location.search).indexOf("builder.frameEditing=")!==-1}const yt=()=>{if(c()){const t=new URL(location.href);return t.pathname===""&&(t.pathname="/"),t}else return console.warn("Cannot get location for tracking in non-browser environment"),null},St=()=>typeof navigator=="object"&&navigator.userAgent||"",$=()=>{const t=St(),e={Android(){return t.match(/Android/i)},BlackBerry(){return t.match(/BlackBerry/i)},iOS(){return t.match(/iPhone|iPod/i)},Opera(){return t.match(/Opera Mini/i)},Windows(){return t.match(/IEMobile/i)||t.match(/WPDesktop/i)},any(){return e.Android()||e.BlackBerry()||e.iOS()||e.Opera()||e.Windows()||y==="reactNative"}},n=t.match(/Tablet|iPad/i),r=yt();return{urlPath:r==null?void 0:r.pathname,host:(r==null?void 0:r.host)||(r==null?void 0:r.hostname),device:n?"tablet":e.any()?"mobile":"desktop"}},p=t=>t!=null;function wt(t){const e=t||(c()?window.location.search:void 0);return e?W(e).indexOf("builder.preview=")!==-1:!1}const vt=t=>({type:"builder.registerComponent",data:P(t)}),Et=t=>{const e=t.toString().trim(),n=/^[a-zA-Z0-9_]+\s*=>/i.test(e);return`return (${!e.startsWith("function")&&!e.startsWith("async")&&!e.startsWith("(")&&!n?"function ":""}${e}).apply(this, arguments)`};function P(t){return JSON.parse(JSON.stringify(t,(e,n)=>typeof n=="function"?Et(n):n))}const F={};function J(t,e){t==="plugin"&&(e=P(e));let n=F[t];if(n||(n=F[t]=[]),n.push(e),c()){const r={type:"builder.register",data:{type:t,info:e}};try{parent.postMessage(r,"*"),parent!==window&&window.postMessage(r,"*")}catch(s){console.debug("Could not postmessage",s)}}}const V={};function It(t){if(c()){Object.assign(V,t);const e={type:"builder.settingsChange",data:V};parent.postMessage(e,"*")}}const M="builder.",kt="options.",C=t=>{if(!t)return{};const e=j(t),n={};return Object.keys(e).forEach(r=>{if(r.startsWith(M)){const s=r.replace(M,"").replace(kt,"");n[s]=e[r]}}),n},At=()=>{if(!c())return{};const t=new URLSearchParams(window.location.search);return C(t)},X="4.0.
|
|
1
|
+
"use strict";const y="react",E="[Builder.io]: ",d={log:(...t)=>console.log(E,...t),error:(...t)=>console.error(E,...t),warn:(...t)=>console.warn(E,...t),debug:(...t)=>console.debug(E,...t)};function c(){return typeof window!="undefined"&&typeof document!="undefined"}const mt=t=>{const e={};return t.forEach((n,r)=>{e[r]=n}),e},j=t=>t instanceof URLSearchParams?mt(t):t,W=t=>typeof t=="string"?t:t instanceof URLSearchParams?t.toString():new URLSearchParams(t).toString();function bt(){return c()&&window.self!==window.top}function G(t){return bt()&&W(t||window.location.search).indexOf("builder.frameEditing=")!==-1}const yt=()=>{if(c()){const t=new URL(location.href);return t.pathname===""&&(t.pathname="/"),t}else return console.warn("Cannot get location for tracking in non-browser environment"),null},St=()=>typeof navigator=="object"&&navigator.userAgent||"",$=()=>{const t=St(),e={Android(){return t.match(/Android/i)},BlackBerry(){return t.match(/BlackBerry/i)},iOS(){return t.match(/iPhone|iPod/i)},Opera(){return t.match(/Opera Mini/i)},Windows(){return t.match(/IEMobile/i)||t.match(/WPDesktop/i)},any(){return e.Android()||e.BlackBerry()||e.iOS()||e.Opera()||e.Windows()||y==="reactNative"}},n=t.match(/Tablet|iPad/i),r=yt();return{urlPath:r==null?void 0:r.pathname,host:(r==null?void 0:r.host)||(r==null?void 0:r.hostname),device:n?"tablet":e.any()?"mobile":"desktop"}},p=t=>t!=null;function wt(t){const e=t||(c()?window.location.search:void 0);return e?W(e).indexOf("builder.preview=")!==-1:!1}const vt=t=>({type:"builder.registerComponent",data:P(t)}),Et=t=>{const e=t.toString().trim(),n=/^[a-zA-Z0-9_]+\s*=>/i.test(e);return`return (${!e.startsWith("function")&&!e.startsWith("async")&&!e.startsWith("(")&&!n?"function ":""}${e}).apply(this, arguments)`};function P(t){return JSON.parse(JSON.stringify(t,(e,n)=>typeof n=="function"?Et(n):n))}const F={};function J(t,e){t==="plugin"&&(e=P(e));let n=F[t];if(n||(n=F[t]=[]),n.push(e),c()){const r={type:"builder.register",data:{type:t,info:e}};try{parent.postMessage(r,"*"),parent!==window&&window.postMessage(r,"*")}catch(s){console.debug("Could not postmessage",s)}}}const V={};function It(t){if(c()){Object.assign(V,t);const e={type:"builder.settingsChange",data:V};parent.postMessage(e,"*")}}const M="builder.",kt="options.",C=t=>{if(!t)return{};const e=j(t),n={};return Object.keys(e).forEach(r=>{if(r.startsWith(M)){const s=r.replace(M,"").replace(kt,"");n[s]=e[r]}}),n},At=()=>{if(!c())return{};const t=new URLSearchParams(window.location.search);return C(t)},X="4.0.4",z=()=>({"X-Builder-SDK":y,"X-Builder-SDK-GEN":"2","X-Builder-SDK-Version":X}),Ot=t=>{if(t==="localhost"||t==="127.0.0.1")return t;const e=t.split(".");return e.length>2?e.slice(1).join("."):t},I=({name:t,canTrack:e})=>{var n;try{return e?(n=document.cookie.split("; ").find(r=>r.startsWith(`${t}=`)))==null?void 0:n.split("=")[1]:void 0}catch(r){d.warn("[COOKIE] GET error: ",(r==null?void 0:r.message)||r);return}},H=async t=>I(t),Pt=t=>t.map(([e,n])=>n?`${e}=${n}`:e).filter(p).join("; "),Ct=[["secure",""],["SameSite","None"]],Ut=({name:t,value:e,expires:n})=>{const s=(c()?location.protocol==="https:":!0)?Ct:[[]],o=n?[["expires",n.toUTCString()]]:[[]],i=[[t,e],...o,["path","/"],["domain",Ot(window.location.hostname)],...s];return Pt(i)},U=async({name:t,value:e,expires:n,canTrack:r})=>{try{if(!r)return;const s=Ut({name:t,value:e,expires:n});document.cookie=s}catch(s){d.warn("[COOKIE] SET error: ",(s==null?void 0:s.message)||s)}};function Tt(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(t){const e=Math.random()*16|0;return(t=="x"?e:e&3|8).toString(16)})}function Q(){return Tt().replace(/-/g,"")}const Y="builderSessionId",Bt=async({canTrack:t})=>{if(!t)return;const e=await H({name:Y,canTrack:t});if(p(e))return e;{const n=Rt();return xt({id:n,canTrack:t}),n}},Rt=()=>Q(),xt=({id:t,canTrack:e})=>U({name:Y,value:t,canTrack:e}),Z=()=>c()&&typeof localStorage!="undefined"?localStorage:void 0,Lt=({key:t,canTrack:e})=>{var n;try{return e?(n=Z())==null?void 0:n.getItem(t):void 0}catch(r){console.debug("[LocalStorage] GET error: ",r);return}},Nt=({key:t,canTrack:e,value:n})=>{var r;try{e&&((r=Z())==null||r.setItem(t,n))}catch(s){console.debug("[LocalStorage] SET error: ",s)}},q="builderVisitorId",Ft=({canTrack:t})=>{if(!t)return;const e=Lt({key:q,canTrack:t});if(p(e))return e;{const n=Vt();return Mt({id:n,canTrack:t}),n}},Vt=()=>Q(),Mt=({id:t,canTrack:e})=>Nt({key:q,value:t,canTrack:e});function tt(t){var e;typeof process!="undefined"&&((e=process.env)!=null&&e.DEBUG)&&String(process.env.DEBUG)=="true"&&d.log(t)}const Dt=async({canTrack:t})=>{if(!t)return{visitorId:void 0,sessionId:void 0};const e=await Bt({canTrack:t}),n=Ft({canTrack:t});return{sessionId:e,visitorId:n}},Kt=async({type:t,canTrack:e,apiKey:n,metadata:r,...s})=>({type:t,data:{...s,metadata:{url:location.href,...r},...await Dt({canTrack:e}),userAttributes:$(),ownerId:n}});async function et({apiHost:t,...e}){if(!e.apiKey){d.error("Missing API key for track call. Please provide your API key.");return}if(!e.canTrack||G()||!(c()||y==="reactNative"))return;const r=`${t||"https://cdn.builder.io"}/api/v1/track`;return tt(r),fetch(r,{method:"POST",body:JSON.stringify({events:[await Kt(e)]}),headers:{"content-type":"application/json",...z()},mode:"cors"}).catch(s=>{console.error("Failed to track: ",s)})}const _t=t=>et({...t,canTrack:!0}),jt=["*.beta.builder.io","beta.builder.io","builder.io","localhost","qa.builder.io"];function nt(t,e){if(!e.origin.startsWith("http")&&!e.origin.startsWith("https"))return!1;const n=new URL(e.origin),r=n.hostname;return(t||jt).findIndex(s=>s.startsWith("*.")?r.endsWith(s.slice(1)):s===r)>-1}const Wt=()=>{J("insertMenu",{name:"_default",default:!0,items:[{name:"Box"},{name:"Text"},{name:"Image"},{name:"Columns"},{name:"Core:Section"},{name:"Core:Button"},{name:"Embed"},{name:"Custom Code"}]})};let D=!1;const rt=t=>{var e,n;D||(D=!0,c()&&((e=window.parent)==null||e.postMessage({type:"builder.sdkInfo",data:{target:y,version:X,supportsPatchUpdates:!1,supportsAddBlockScoping:!0,supportsCustomBreakpoints:!0,modelName:t.modelName,apiKey:t.apiKey,supportsXSmallBreakpoint:!0,blockLevelPersonalization:!0}},"*"),(n=window.parent)==null||n.postMessage({type:"builder.updateContent",data:{options:t}},"*"),window.addEventListener("message",r=>{var o,i;if(!nt(t.trustedHosts,r))return;const{data:s}=r;if(s!=null&&s.type)switch(s.type){case"builder.evaluate":{const u=s.data.text,S=s.data.arguments||[],m=s.data.id,k=new Function(u);let l,g=null;try{l=k.apply(null,S)}catch(h){g=h}g?(o=window.parent)==null||o.postMessage({type:"builder.evaluateError",data:{id:m,error:g.message}},"*"):l&&typeof l.then=="function"?l.then(h=>{var w;(w=window.parent)==null||w.postMessage({type:"builder.evaluateResult",data:{id:m,result:h}},"*")}).catch(console.error):(i=window.parent)==null||i.postMessage({type:"builder.evaluateResult",data:{result:l,id:m}},"*");break}}})))},st=({model:t,trustedHosts:e,callbacks:n})=>r=>{if(!nt(e,r))return;const{data:s}=r;if(s)switch(s.type){case"builder.configureSdk":{n.configureSdk(s.data);break}case"builder.triggerAnimation":{n.animation(s.data);break}case"builder.resetState":{const o=s.data,i=o.model,u=o==null?void 0:o.state;i===t&&u&&n.stateUpdate(u);break}case"builder.contentUpdate":{const o=s.data,i=o.key||o.alias||o.entry||o.modelName,u=o.data;i===t&&n.contentUpdate(u);break}}},Gt=({model:t,apiKey:e,callback:n,trustedHosts:r})=>{if(!c)return d.warn("`subscribeToEditor` only works in the browser. It currently seems to be running on the server."),()=>{};rt({modelName:t,apiKey:e});const s=st({callbacks:{contentUpdate:n,animation:()=>{},configureSdk:()=>{},stateUpdate:()=>{}},model:t,trustedHosts:r});return window.addEventListener("message",s),()=>{window.removeEventListener("message",s)}},$t="builder.tests",T=t=>`${$t}.${t}`,Jt=({contentId:t})=>H({name:T(t),canTrack:!0}),Xt=({contentId:t})=>I({name:T(t),canTrack:!0}),zt=({contentId:t,value:e})=>U({name:T(t),value:e,canTrack:!0}),ot=t=>p(t.id)&&p(t.variations)&&Object.keys(t.variations).length>0,Ht=({id:t,variations:e})=>{var s;let n=0;const r=Math.random();for(const o in e){const i=(s=e[o])==null?void 0:s.testRatio;if(n+=i,r<n)return o}return t},it=t=>{const e=Ht(t);return zt({contentId:t.id,value:e}).catch(n=>{d.error("could not store A/B test variation: ",n)}),e},at=({item:t,testGroupId:e})=>{const n=t.variations[e];return e===t.id||!n?{testVariationId:t.id,testVariationName:"Default"}:{data:n.data,testVariationId:n.id,testVariationName:n.name||(n.id===t.id?"Default":"")}},Qt=({item:t,canTrack:e})=>{if(!e)return t;if(!t)return;if(!ot(t))return t;const n=Xt({contentId:t.id})||it({variations:t.variations,id:t.id}),r=at({item:t,testGroupId:n});return{...t,...r}},Yt=async({item:t,canTrack:e})=>{if(!e||!ot(t))return t;const r=await Jt({contentId:t.id})||it({variations:t.variations,id:t.id}),s=at({item:t,testGroupId:r});return{...t,...s}},K="builder.userAttributes";function Zt(){let t=!0;const e=new Set;return{setUserAttributes(n){if(!c())return;const r={...this.getUserAttributes(),...n};U({name:K,value:JSON.stringify(r),canTrack:t}),e.forEach(s=>s(r))},getUserAttributes(){return c()?JSON.parse(I({name:K,canTrack:t})||"{}"):{}},subscribeOnUserAttributesChange(n){return e.add(n),()=>{e.delete(n)}},setCanTrack(n){t=n}}}const B=Zt(),qt=t=>{B.setUserAttributes(t)},ct=t=>{const e=p(t)?t:!0;return B.setCanTrack(e),e};function te(){return typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:globalThis}function ee(){const t=te().fetch;if(typeof t=="undefined")throw console.warn(`Builder SDK could not find a global fetch function. Make sure you have a polyfill for fetch in your project.
|
|
2
2
|
For more information, read https://github.com/BuilderIO/this-package-uses-fetch`),new Error("Builder SDK could not find a global `fetch` function");return t}const ne=ee();function O(t,e=null,n="."){return Object.keys(t).reduce((r,s)=>{const o=t[s],i=[e,s].filter(Boolean).join(n);return[typeof o=="object",o!==null,!(Array.isArray(o)&&o.length===0)].every(Boolean)?{...r,...O(o,i,n)}:{...r,[i]:o}},{})}function ut(t,e,n={}){for(const r in t){const s=t[r],o=e?e+"."+r:r;s&&typeof s=="object"&&!Array.isArray(s)&&!Object.keys(s).find(i=>i.startsWith("$"))?ut(s,o,n):n[o]=s}return n}function re(t){const e={};for(const n in t){const r=n.split(".");let s=e;for(let o=0;o<r.length;o++){const i=r[o];o===r.length-1?s[i]=t[n]:(s[i]=s[i]||{},s=s[i])}}return e}const se="v3",_=t=>typeof t=="number"&&!isNaN(t)&&t>=0,R=t=>{const{limit:e=30,userAttributes:n,query:r,model:s,apiKey:o,enrich:i,locale:u,apiVersion:S=se,fields:m,omit:k,offset:l,cacheSeconds:g,staleCacheSeconds:h,sort:w,includeUnpublished:x,apiHost:gt}=t;if(!o)throw new Error("Missing API key");if(!["v3"].includes(S))throw new Error(`Invalid apiVersion: expected 'v3', received '${S}'`);const ht=e!==1,pt=gt||"https://cdn.builder.io",a=new URL(`${pt}/api/${S}/content/${s}`);a.searchParams.set("apiKey",o),a.searchParams.set("limit",String(e)),a.searchParams.set("noTraverse",String(ht)),a.searchParams.set("includeRefs",String(!0));const A=u||(n==null?void 0:n.locale);let b=n||{};if(A&&(a.searchParams.set("locale",A),b={locale:A,...b}),i&&a.searchParams.set("enrich",String(i)),a.searchParams.set("omit",k||"meta.componentsUsed"),m&&a.searchParams.set("fields",m),Number.isFinite(l)&&l>-1&&a.searchParams.set("offset",String(Math.floor(l))),typeof x=="boolean"&&a.searchParams.set("includeUnpublished",String(x)),g&&_(g)&&a.searchParams.set("cacheSeconds",String(g)),h&&_(h)&&a.searchParams.set("staleCacheSeconds",String(h)),w){const f=O({sort:w});for(const v in f)a.searchParams.set(v,JSON.stringify(f[v]))}const L={...At(),...j(t.options||{})};b={...b,...ie(L)};const N=O(L);for(const f in N)a.searchParams.set(f,String(N[f]));if(Object.keys(b).length>0&&a.searchParams.set("userAttributes",JSON.stringify(b)),r){const f=ut({query:r});for(const v in f)a.searchParams.set(v,JSON.stringify(f[v]))}return a},oe=t=>{const e={};for(const n in t)n.startsWith("userAttributes.")&&(e[n]=t[n],delete t[n]);return e},ie=t=>{if(c()&&t.preview==="BUILDER_STUDIO"){t["userAttributes.urlPath"]=window.location.pathname,t["userAttributes.host"]=window.location.host;const e=oe(t),{userAttributes:n}=re(e);return n}return{}},ae=t=>"results"in t;async function lt(t){const e=await ft({...t,limit:1});return e&&e[0]||null}const ce=async t=>{var i,u;const e=R(t),n=(i=t.fetch)!=null?i:ne,r={...t.fetchOptions,headers:{...(u=t.fetchOptions)==null?void 0:u.headers,...z()}};return await(await n(e.href,r)).json()},dt=async(t,e,n=R(t))=>{const r=ct(t.canTrack);if(n.search.includes("preview="),!r||!(c()||y==="reactNative"))return e.results;try{const s=[];for(const o of e.results)s.push(await Yt({item:o,canTrack:r}));e.results=s}catch(s){d.error("Could not process A/B tests. ",s)}return e.results};async function ft(t){const e=R(t),n=await ce(t);if(!ae(n))throw d.error("Error fetching data. ",{url:e,content:n,options:t}),n;return dt(t,n)}const ue=async t=>{var r,s,o;const e=t.path||((r=t.url)==null?void 0:r.pathname)||((s=t.userAttributes)==null?void 0:s.urlPath),n={...t,apiKey:t.apiKey,model:t.model||"page",userAttributes:{...t.userAttributes,...e?{urlPath:e}:{}},options:C(t.searchParams||((o=t.url)==null?void 0:o.searchParams)||t.options)};return{apiKey:n.apiKey,model:n.model,content:await lt(n)}};exports.MSG_PREFIX=E;exports.TARGET=y;exports._processContentResult=dt;exports._track=et;exports.checkIsDefined=p;exports.createEditorListener=st;exports.createRegisterComponentMessage=vt;exports.fetchBuilderProps=ue;exports.fetchEntries=ft;exports.fetchOneEntry=lt;exports.getBuilderSearchParams=C;exports.getCookieSync=I;exports.getDefaultCanTrack=ct;exports.getUserAttributes=$;exports.handleABTestingSync=Qt;exports.isBrowser=c;exports.isEditing=G;exports.isPreviewing=wt;exports.logFetch=tt;exports.logger=d;exports.register=J;exports.registerInsertMenu=Wt;exports.serializeIncludingFunctions=P;exports.setClientUserAttributes=qt;exports.setEditorSettings=It;exports.setupBrowserForEditing=rt;exports.subscribeToEditor=Gt;exports.track=_t;exports.userAttributesService=B;
|
|
@@ -112,7 +112,7 @@ const N = "builder.", ht = "options.", W = (t) => {
|
|
|
112
112
|
return {};
|
|
113
113
|
const t = new URLSearchParams(window.location.search);
|
|
114
114
|
return W(t);
|
|
115
|
-
}, _ = "4.0.
|
|
115
|
+
}, _ = "4.0.4", $ = () => ({
|
|
116
116
|
"X-Builder-SDK": v,
|
|
117
117
|
"X-Builder-SDK-GEN": "2",
|
|
118
118
|
"X-Builder-SDK-Version": _
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./server-entry-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./server-entry-a7413c09.cjs");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;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _processContentResult as r, createRegisterComponentMessage as s, fetchBuilderProps as i, fetchEntries as n, fetchOneEntry as o, getBuilderSearchParams as c, isEditing as g, isPreviewing as a, register as d, setEditorSettings as E, subscribeToEditor as f, track as h } from "./server-entry-
|
|
1
|
+
import { _processContentResult as r, createRegisterComponentMessage as s, fetchBuilderProps as i, fetchEntries as n, fetchOneEntry as o, getBuilderSearchParams as c, isEditing as g, isPreviewing as a, register as d, setEditorSettings as E, subscribeToEditor as f, track as h } from "./server-entry-d38415f3.js";
|
|
2
2
|
export {
|
|
3
3
|
r as _processContentResult,
|
|
4
4
|
s as createRegisterComponentMessage,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const serverEntry=require("./server-entry-
|
|
1
|
+
"use strict";const serverEntry=require("./server-entry-a7413c09.cjs"),getFunctionArguments=({builder:e,context:t,event:s,state:r})=>Object.entries({state:r,Builder:e,builder:e,context:t,event:s}),getBuilderGlobals=()=>({isEditing:serverEntry.isEditing(),isBrowser:serverEntry.isBrowser(),isServer:!serverEntry.isBrowser(),getUserAttributes:()=>serverEntry.getUserAttributes()}),parseCode=(e,{isExpression:t=!0})=>t&&!(e.includes(";")||e.includes(" return ")||e.trim().startsWith("return "))?`return (${e});`:e;function flattenState({rootState:e,localState:t,rootSetState:s}){return new Proxy(e,{get:(r,n)=>{if(t&&n in t)return t[n];const o=r[n];return typeof o=="object"&&o!==null?flattenState({rootState:o,localState:void 0,rootSetState:s?i=>{r[n]=i,s(r)}:void 0}):o},set:(r,n,o)=>{if(t&&n in t)throw new Error("Writing to local state is not allowed as it is read-only.");return r[n]=o,s==null||s(r),!0}})}const SDK_NAME_FOR_TARGET=(()=>{switch(serverEntry.TARGET){case"rsc":return"react-nextjs";case"reactNative":return"react-native";default:return serverEntry.TARGET}})(),SDK_NAME=`@builder.io/sdk-${SDK_NAME_FOR_TARGET}`,fastClone=e=>JSON.parse(JSON.stringify(e)),set=(e,t,s)=>{if(Object(e)!==e)return e;const r=Array.isArray(t)?t:t.toString().match(/[^.[\]]+/g);return r.slice(0,-1).reduce((n,o,i)=>Object(n[o])===n[o]?n[o]:n[o]=Math.abs(Number(r[i+1]))>>0===+r[i+1]?[]:{},e)[r[r.length-1]]=s,e},noop=()=>{};let safeDynamicRequire=noop;try{safeDynamicRequire=eval("require")}catch(e){}const getSyncValName=e=>`bldr_${e}_sync`,BUILDER_SET_STATE_NAME="BUILDER_SET_STATE",INJECTED_IVM_GLOBAL="BUILDER_IVM",REF_TO_PROXY_FN=`
|
|
2
2
|
var refToProxy = (obj) => {
|
|
3
3
|
if (typeof obj !== 'object' || obj === null) {
|
|
4
4
|
return obj;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { isEditing, isBrowser, getUserAttributes, TARGET, logger, MSG_PREFIX } from "./server-entry-
|
|
1
|
+
import { isEditing, isBrowser, getUserAttributes, TARGET, logger, MSG_PREFIX } from "./server-entry-d38415f3.js";
|
|
2
2
|
const getFunctionArguments = ({
|
|
3
3
|
builder: e,
|
|
4
4
|
context: t,
|
package/lib/node/setIvm.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./setIvm-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./setIvm-0a044ac8.cjs");require("./server-entry-a7413c09.cjs");exports.setIvm=e.setIvm;
|
package/lib/node/setIvm.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const s=require("./server-entry-
|
|
1
|
+
"use strict";const s=require("./server-entry-a7413c09.cjs");function t(){var e;return typeof process!="undefined"&&s.checkIsDefined((e=process==null?void 0:process.versions)==null?void 0:e.node)}const c=({shouldLogWarning:e})=>{var o;if(!t())return!1;const n=process.arch==="arm64",r=process.version.startsWith("v20"),i=(o=process.env.NODE_OPTIONS)==null?void 0:o.includes("--no-node-snapshot");return n&&r&&!i?(e&&s.logger.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};exports.shouldForceBrowserRuntimeInNode=c;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { checkIsDefined as i, logger as t } from "./server-entry-
|
|
1
|
+
import { checkIsDefined as i, logger as t } from "./server-entry-d38415f3.js";
|
|
2
2
|
function a() {
|
|
3
3
|
var o;
|
|
4
4
|
return typeof process != "undefined" && i((o = process == null ? void 0 : process.versions) == null ? void 0 : o.node);
|
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "4.0.
|
|
1
|
+
export declare const SDK_VERSION = "4.0.4";
|