@builder.io/sdk-react-nextjs 0.14.15 → 0.14.16
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/{node/USE_CLIENT_BUNDLE-85565442.cjs → browser/USE_CLIENT_BUNDLE-026b8026.cjs} +3 -3
- package/lib/browser/{USE_CLIENT_BUNDLE-619fca6f.js → USE_CLIENT_BUNDLE-30c6c6c1.js} +15 -15
- package/lib/{edge/USE_SERVER_BUNDLE-54c1fcea.js → browser/USE_SERVER_BUNDLE-685e6983.js} +1 -1
- package/lib/{edge/USE_SERVER_BUNDLE-b436e323.cjs → browser/USE_SERVER_BUNDLE-ce31724e.cjs} +1 -1
- package/lib/browser/{bundle-62dcf48b.js → bundle-5c0a9d7a.js} +555 -538
- package/lib/browser/bundle-9744b895.cjs +169 -0
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +3 -3
- package/lib/{node/USE_CLIENT_BUNDLE-c0730eab.js → edge/USE_CLIENT_BUNDLE-5b0b3e9b.js} +15 -15
- package/lib/{browser/USE_CLIENT_BUNDLE-d44f1d9a.cjs → edge/USE_CLIENT_BUNDLE-9b110136.cjs} +3 -3
- package/lib/{node/USE_SERVER_BUNDLE-558179bb.js → edge/USE_SERVER_BUNDLE-0f9fd6f2.js} +1 -1
- package/lib/{node/USE_SERVER_BUNDLE-81427dab.cjs → edge/USE_SERVER_BUNDLE-b3d619da.cjs} +1 -1
- package/lib/edge/{bundle-67ad9183.js → bundle-b24e7c9b.js} +1049 -1032
- package/lib/edge/{bundle-fbc6c22e.cjs → bundle-f1760904.cjs} +29 -29
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +3 -3
- package/lib/{edge/USE_CLIENT_BUNDLE-84dff6eb.js → node/USE_CLIENT_BUNDLE-f8067984.js} +15 -15
- package/lib/{edge/USE_CLIENT_BUNDLE-97b90370.cjs → node/USE_CLIENT_BUNDLE-f9ebade4.cjs} +3 -3
- package/lib/{browser/USE_SERVER_BUNDLE-b4db53a9.js → node/USE_SERVER_BUNDLE-4b52a0c0.js} +1 -1
- package/lib/{browser/USE_SERVER_BUNDLE-72579b21.cjs → node/USE_SERVER_BUNDLE-e1e73ba6.cjs} +1 -1
- package/lib/node/{bundle-3fe2b5da.cjs → bundle-0fc157c8.cjs} +9 -9
- package/lib/node/{bundle-5f638f04.js → bundle-8d3cab60.js} +169 -152
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +3 -3
- package/package.json +1 -1
- package/types/cjs/components/block/animator.d.ts +1 -1
- package/types/cjs/constants/sdk-version.d.ts +1 -1
- package/types/cjs/functions/is-previewing.d.ts +1 -1
- package/types/esm/components/block/animator.d.ts +1 -1
- package/types/esm/constants/sdk-version.d.ts +1 -1
- package/types/esm/functions/is-previewing.d.ts +1 -1
- package/lib/browser/bundle-df3df109.cjs +0 -169
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
"use client";"use strict";const t=require("react/jsx-runtime"),
|
|
1
|
+
"use client";"use strict";const t=require("react/jsx-runtime"),n=require("./bundle-9744b895.cjs"),l=require("react"),M=require("./USE_SERVER_BUNDLE-ce31724e.cjs"),D=require("next/navigation");function j(e){return t.jsx(t.Fragment,{children:n.isEmptyElement(e.TagName)?t.jsx(t.Fragment,{children:t.jsx(e.TagName,{...e.attributes,...e.actionAttributes})}):t.jsx(t.Fragment,{children:typeof e.TagName=="string"?t.jsx(e.TagName,{...e.attributes,...e.actionAttributes,children:e.children}):t.jsx(e.TagName,{...e.attributes,...e.actionAttributes,children:e.children})})})}function H(e){return t.jsx(j,{attributes:{...e.attributes,[n.getClassPropName()]:`${e.link?"":"builder-button"} ${e.attributes[n.getClassPropName()]||""}`,...e.link?{href:e.link,target:e.openLinkInNewTab?"_blank":void 0,role:"link"}:{role:"button"}},TagName:e.link?e.builderLinkComponent||"a":"button",actionAttributes:{},children:e.text})}function V(e){return t.jsx(j,{TagName:e.Wrapper,attributes:n.getBlockProperties({block:e.block,context:e.context}),actionAttributes:n.getBlockActions({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 U(e){return t.jsx(e.Wrapper,{...e.wrapperProps,attributes:e.includeBlockProps?{...n.getBlockProperties({block:e.block,context:e.context}),...n.getBlockActions({block:e.block,rootState:e.context.rootState,rootSetState:e.context.rootSetState,localState:e.context.localState,context:e.context.context})}:{},children:e.children})}function $(e){function c(){var o;return"builder-blocks"+((o=e.blocks)!=null&&o.length?"":" no-blocks")}function u(){var o,b;n.isEditing()&&!((o=e.blocks)!=null&&o.length)&&((b=window.parent)==null||b.postMessage({type:"builder.clickEmptyBlocks",data:{parentElementId:e.parent,dataPath:e.path}},"*"))}function S(){var o,b;n.isEditing()&&!((o=e.blocks)!=null&&o.length)&&((b=window.parent)==null||b.postMessage({type:"builder.hoverEmptyBlocks",data:{parentElementId:e.parent,dataPath:e.path}},"*"))}return t.jsxs(t.Fragment,{children:[t.jsx(e.BlocksWrapper,{className:c()+" props-blocks-wrapper-7cd1560e","builder-path":e.path,"builder-parent-id":e.parent,style:e.styleProp,onClick:o=>u(),onMouseEnter:o=>S(),onKeyPress:o=>u(),...e.BlocksWrapperProps,children:e.children}),t.jsx("style",{children:`.props-blocks-wrapper-7cd1560e {
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
align-items: stretch;
|
|
5
|
-
}`})]})}function O(e){return t.jsx("span",{children:e.children})}function J(e){var o,b,h,x;function c(){var f;const d=e.image||e.src;if(!d||!(d.match(/builder\.io/)||d.match(/cdn\.shopify\.com/)))return e.srcset;if(e.srcset&&((f=e.image)!=null&&f.includes("builder.io/api/v1/image"))){if(!e.srcset.includes(e.image.split("?")[0]))return console.debug("Removed given srcset"),
|
|
5
|
+
}`})]})}function O(e){return t.jsx("span",{children:e.children})}function J(e){var o,b,h,x;function c(){var f;const d=e.image||e.src;if(!d||!(d.match(/builder\.io/)||d.match(/cdn\.shopify\.com/)))return e.srcset;if(e.srcset&&((f=e.image)!=null&&f.includes("builder.io/api/v1/image"))){if(!e.srcset.includes(e.image.split("?")[0]))return console.debug("Removed given srcset"),n.getSrcSet(d)}else if(e.image&&!e.srcset)return n.getSrcSet(d);return n.getSrcSet(d)}function u(){var g;return(g=c==null?void 0:c())!=null&&g.match(/builder\.io/)&&!e.noWebp?c().replace(/\?/g,"?format=webp&"):""}function S(){const g={position:"absolute",height:"100%",width:"100%",left:"0px",top:"0px"};return e.aspectRatio?g:void 0}return t.jsxs(t.Fragment,{children:[t.jsxs(t.Fragment,{children:[t.jsxs("picture",{children:[u()?t.jsx("source",{type:"image/webp",srcSet:u()}):null,t.jsx("img",{loading:"lazy",alt:e.altText,role:e.altText?void 0:"presentation",style:{objectPosition:e.backgroundPosition||"center",objectFit:e.backgroundSize||"cover",...S()},className:"builder-image"+(e.className?" "+e.className:"")+" img-a0c95e8c",src:e.image,srcSet:c(),sizes:e.sizes})]}),e.aspectRatio&&!((b=(o=e.builderBlock)==null?void 0:o.children)!=null&&b.length&&e.fitContent)?t.jsx("div",{className:"builder-image-sizer div-a0c95e8c",style:{paddingTop:e.aspectRatio*100+"%"}}):null,(x=(h=e.builderBlock)==null?void 0:h.children)!=null&&x.length&&e.fitContent?t.jsx(t.Fragment,{children:e.children}):null,!e.fitContent&&e.children?t.jsx("div",{className:"div-a0c95e8c-2",children:e.children}):null]}),t.jsx("style",{children:`.img-a0c95e8c {
|
|
6
6
|
opacity: 1;
|
|
7
7
|
transition: opacity 0.2s ease-in-out;
|
|
8
8
|
}.div-a0c95e8c {
|
|
@@ -18,4 +18,4 @@
|
|
|
18
18
|
left: 0;
|
|
19
19
|
width: 100%;
|
|
20
20
|
height: 100%;
|
|
21
|
-
}`})]})}function G(e){return t.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})}function Q(e){const c=l.useRef(null),[u,S]=l.useState(()=>[]),[o,b]=l.useState(()=>[]);return l.useEffect(()=>{var x;if(!((x=c.current)!=null&&x.getElementsByTagName)||typeof window>"u")return;const h=c.current.getElementsByTagName("script");for(let g=0;g<h.length;g++){const d=h[g];if(d.src){if(u.includes(d.src))continue;u.push(d.src);const f=document.createElement("script");f.async=!0,f.src=d.src,document.head.appendChild(f)}else if(!d.type||["text/javascript","application/javascript","application/ecmascript"].includes(d.type)){if(o.includes(d.innerText))continue;try{o.push(d.innerText),new Function(d.innerText)()}catch(f){console.warn("`CustomCode`: Error running script:",f)}}}},[]),t.jsx("div",{ref:c,className:"builder-custom-code"+(e.replaceNodes?" replace-nodes":""),dangerouslySetInnerHTML:{__html:e.code}})}function X(e){const c=l.useRef(null),[u,S]=l.useState(()=>[]),[o,b]=l.useState(()=>[]),[h,x]=l.useState(()=>!1);function g(){if(!c.current||!c.current.getElementsByTagName)return;const d=c.current.getElementsByTagName("script");for(let f=0;f<d.length;f++){const v=d[f];if(v.src&&!u.includes(v.src)){u.push(v.src);const C=document.createElement("script");C.async=!0,C.src=v.src,document.head.appendChild(C)}else if(
|
|
21
|
+
}`})]})}function G(e){return t.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})}function Q(e){const c=l.useRef(null),[u,S]=l.useState(()=>[]),[o,b]=l.useState(()=>[]);return l.useEffect(()=>{var x;if(!((x=c.current)!=null&&x.getElementsByTagName)||typeof window>"u")return;const h=c.current.getElementsByTagName("script");for(let g=0;g<h.length;g++){const d=h[g];if(d.src){if(u.includes(d.src))continue;u.push(d.src);const f=document.createElement("script");f.async=!0,f.src=d.src,document.head.appendChild(f)}else if(!d.type||["text/javascript","application/javascript","application/ecmascript"].includes(d.type)){if(o.includes(d.innerText))continue;try{o.push(d.innerText),new Function(d.innerText)()}catch(f){console.warn("`CustomCode`: Error running script:",f)}}}},[]),t.jsx("div",{ref:c,className:"builder-custom-code"+(e.replaceNodes?" replace-nodes":""),dangerouslySetInnerHTML:{__html:e.code}})}function X(e){const c=l.useRef(null),[u,S]=l.useState(()=>[]),[o,b]=l.useState(()=>[]),[h,x]=l.useState(()=>!1);function g(){if(!c.current||!c.current.getElementsByTagName)return;const d=c.current.getElementsByTagName("script");for(let f=0;f<d.length;f++){const v=d[f];if(v.src&&!u.includes(v.src)){u.push(v.src);const C=document.createElement("script");C.async=!0,C.src=v.src,document.head.appendChild(C)}else if(n.isJsScript(v)&&!o.includes(v.innerText))try{o.push(v.innerText),new Function(v.innerText)()}catch(C){console.warn("`Embed`: Error running script:",C)}}}return l.useEffect(()=>{c.current&&!h&&(x(!0),g())},[c.current,h]),t.jsx("div",{className:"builder-embed",ref:c,dangerouslySetInnerHTML:{__html:e.content}})}function Y(e){return t.jsx("img",{style:{objectFit:e.backgroundSize||"cover",objectPosition:e.backgroundPosition||"center"},alt:e.altText,src:e.imgSrc||e.image,...e.attributes},n.isEditing()&&e.imgSrc||"default-key")}function Z(e){var S,o,b,h,x,g,d;function c(){return{...e.autoPlay===!0?{autoPlay:!0}:{},...e.muted===!0?{muted:!0}:{},...e.controls===!0?{controls:!0}:{},...e.loop===!0?{loop:!0}:{},...e.playsInline===!0?{playsInline:!0}:{}}}function u(){return{...c()}}return t.jsxs("div",{style:{position:"relative"},children:[t.jsx("video",{className:"builder-video",...u(),preload:e.preload||"metadata",style:{width:"100%",height:"100%",...(S=e.attributes)==null?void 0:S.style,objectFit:e.fit,objectPosition:e.position,zIndex:2,borderRadius:"1px",...e.aspectRatio?{position:"absolute"}:null},src:e.video||"no-src",poster:e.posterImage,children:e.lazyLoad?null:t.jsx("source",{type:"video/mp4",src:e.video})}),e.aspectRatio&&!(e.fitContent&&((b=(o=e.builderBlock)==null?void 0:o.children)!=null&&b.length))?t.jsx("div",{style:{width:"100%",paddingTop:e.aspectRatio*100+"%",pointerEvents:"none",fontSize:"0px"}}):null,(x=(h=e.builderBlock)==null?void 0:h.children)!=null&&x.length&&e.fitContent?t.jsx("div",{style:{display:"flex",flexDirection:"column",alignItems:"stretch"},children:e.children}):null,(d=(g=e.builderBlock)==null?void 0:g.children)!=null&&d.length&&!e.fitContent?t.jsx("div",{style:{pointerEvents:"none",display:"flex",flexDirection:"column",alignItems:"stretch",position:"absolute",top:"0",left:"0",width:"100%",height:"100%"},children:e.children}):null]})}const q=l.createContext({content:null,context:{},localState:void 0,rootSetState(){},rootState:{},apiKey:null,apiVersion:void 0,componentInfos:{},inheritedStyles:{},BlocksWrapper:"div",BlocksWrapperProps:{}});function p(e){var P,T,B,N,L,F,W;const c=l.useRef(null);function u(a){var s,r;const i={...e.builderContextSignal.rootState,...a};e.builderContextSignal.rootSetState?(r=(s=e.builderContextSignal).rootSetState)==null||r.call(s,i):e.builderContextSignal.rootState=i}function S(a){var s,r,m,y,k;const i={...e.builderContextSignal.content,...a,data:{...(s=e.builderContextSignal.content)==null?void 0:s.data,...a==null?void 0:a.data},meta:{...(r=e.builderContextSignal.content)==null?void 0:r.meta,...a==null?void 0:a.meta,breakpoints:((m=a==null?void 0:a.meta)==null?void 0:m.breakpoints)||((k=(y=e.builderContextSignal.content)==null?void 0:y.meta)==null?void 0:k.breakpoints)}};M.postPreviewContent({value:i,key:i.id}).then(()=>{_.refresh()})}const[o,b]=l.useState(()=>e.contentWrapper||"div");function h(a){return n.createEditorListener({model:e.model,trustedHosts:e.trustedHosts,callbacks:{configureSdk:i=>{var m;const{breakpoints:s,contentId:r}=i;!r||r!==((m=e.builderContextSignal.content)==null?void 0:m.id)||s&&S({meta:{breakpoints:s}})},animation:i=>{n.triggerAnimation(i)},contentUpdate:i=>{S(i)}}})(a)}function x(){var i,s;const a=(s=(i=e.builderContextSignal.content)==null?void 0:i.data)==null?void 0:s.jsCode;a&&n.evaluate({code:a,context:e.context||{},localState:void 0,rootState:e.builderContextSignal.rootState,rootSetState:e.builderContextSignal.rootSetState,enableCache:!1})}const[g,d]=l.useState(()=>({})),[f,v]=l.useState(()=>({})),[C,A]=l.useState(()=>!1);function K(a){var i,s;if(e.builderContextSignal.content){const r=(i=e.builderContextSignal.content)==null?void 0:i.testVariationId,m=(s=e.builderContextSignal.content)==null?void 0:s.id;n._track({type:"click",canTrack:n.getDefaultCanTrack(e.canTrack),contentId:m,apiKey:e.apiKey,variationId:r!==m?r:void 0,...n.getInteractionPropertiesForEvent(a),unique:!C})}C||A(!0)}function I(){var i,s;const a=((s=(i=e.builderContextSignal.content)==null?void 0:i.data)==null?void 0:s.httpRequests)??{};Object.entries(a).forEach(([r,m])=>{if(!m||f[r]||g[r]&&!n.isEditing())return;f[r]=!0;const y=m.replace(/{{([^}]+)}}/g,(k,z)=>String(n.evaluate({code:z,context:e.context||{},localState:void 0,rootState:e.builderContextSignal.rootState,rootSetState:e.builderContextSignal.rootSetState,enableCache:!0})));n.fetch(y).then(k=>k.json()).then(k=>{u({[r]:k}),g[r]=!0}).catch(k=>{console.error("error fetching dynamic data",m,k)}).finally(()=>{f[r]=!1})})}function E(){n.isEditing()&&window.dispatchEvent(new CustomEvent("builder:component:stateChange",{detail:{state:n.fastClone(e.builderContextSignal.rootState),ref:{name:e.model}}}))}function w(a){window.addEventListener("message",h),n.registerInsertMenu(),n.setupBrowserForEditing({...e.locale?{locale:e.locale}:{},...e.enrich?{enrich:e.enrich}:{},...e.trustedHosts?{trustedHosts:e.trustedHosts}:{}}),Object.values(e.builderContextSignal.componentInfos).forEach(i=>{var r;const s=n.createRegisterComponentMessage(i);(r=window.parent)==null||r.postMessage(s,"*")}),window.addEventListener("builder:component:stateChangeListenerActivated",E)}function R(a){const i=new URL(location.href).searchParams,s=i.get("builder.preview"),r=i.get(`builder.preview.${s}`),m=i.get("apiKey")||i.get("builder.space");s===e.model&&m===e.apiKey&&(!e.content||r===e.content.id)&&n.fetchOneEntry({model:e.model,apiKey:e.apiKey,apiVersion:e.builderContextSignal.apiVersion}).then(y=>{y&&S(y)})}const _=D.useRouter();return l.useEffect(()=>{var a;return(a=c.current)==null||a.addEventListener("initeditingbldr",w),()=>{var i;return(i=c.current)==null?void 0:i.removeEventListener("initeditingbldr",w)}},[]),l.useEffect(()=>{var a;return(a=c.current)==null||a.addEventListener("initpreviewingbldr",R),()=>{var i;return(i=c.current)==null?void 0:i.removeEventListener("initpreviewingbldr",R)}},[]),l.useEffect(()=>{var a,i;if(n.isBrowser()){if(n.isEditing()&&c.current&&c.current.dispatchEvent(new CustomEvent("initeditingbldr")),e.builderContextSignal.content&&n.getDefaultCanTrack(e.canTrack)){const r=(a=e.builderContextSignal.content)==null?void 0:a.testVariationId,m=(i=e.builderContextSignal.content)==null?void 0:i.id,y=e.apiKey;n._track({type:"impression",canTrack:!0,contentId:m,apiKey:y,variationId:r!==m?r:void 0})}n.isPreviewing()&&n.isEditing()}},[]),l.useEffect(()=>{e.apiKey||n.logger.error("No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."),x(),I(),E()},[]),l.useEffect(()=>{},[e.content]),l.useEffect(()=>{x()},[(T=(P=e.builderContextSignal.content)==null?void 0:P.data)==null?void 0:T.jsCode]),l.useEffect(()=>{I()},[(N=(B=e.builderContextSignal.content)==null?void 0:B.data)==null?void 0:N.httpRequests]),l.useEffect(()=>{E()},[e.builderContextSignal.rootState]),l.useEffect(()=>{e.data&&u(e.data)},[e.data]),l.useEffect(()=>{e.locale&&u({locale:e.locale})},[e.locale]),l.useEffect(()=>()=>{n.isBrowser()&&(window.removeEventListener("message",h),window.removeEventListener("builder:component:stateChangeListenerActivated",E))},[]),t.jsx(q.Provider,{value:e.builderContextSignal,children:e.builderContextSignal.content?t.jsx(o,{ref:c,onClick:a=>K(a),"builder-content-id":(L=e.builderContextSignal.content)==null?void 0:L.id,"builder-model":e.model,...e.showContent?{}:{hidden:!0,"aria-hidden":!0},...e.contentWrapperProps,className:`variant-${((F=e.content)==null?void 0:F.testVariationId)||((W=e.content)==null?void 0:W.id)}`,children:e.children}):null})}exports.BlockWrapper=V;exports.BlocksWrapper=$;exports.Button=H;exports.CustomCode=Q;exports.DynamicRenderer=j;exports.Embed=X;exports.EnableEditor=p;exports.FragmentComponent=O;exports.Image=J;exports.ImgComponent=Y;exports.InteractiveElement=U;exports.SectionComponent=G;exports.Video=Z;exports.builderContext=q;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx as i, Fragment as
|
|
3
|
-
import { i as Y, g as q, a as U, b as $, c as
|
|
2
|
+
import { jsx as i, Fragment as w, jsxs as I } from "react/jsx-runtime";
|
|
3
|
+
import { i as Y, g as q, a as U, b as $, c as E, d as R, e as Z, f as H, h as _, _ as V, j as p, l as ee, k as te, t as ne, m as D, n as ie, o as ae, p as ce, r as re, s as le, q as oe, u as de } from "./bundle-5c0a9d7a.js";
|
|
4
4
|
import { useRef as T, useState as k, useEffect as f, createContext as se } from "react";
|
|
5
|
-
import { p as ue } from "./USE_SERVER_BUNDLE-
|
|
5
|
+
import { p as ue } from "./USE_SERVER_BUNDLE-685e6983.js";
|
|
6
6
|
import { useRouter as me } from "next/navigation";
|
|
7
7
|
function O(e) {
|
|
8
|
-
return /* @__PURE__ */ i(
|
|
8
|
+
return /* @__PURE__ */ i(w, { children: Y(e.TagName) ? /* @__PURE__ */ i(w, { children: /* @__PURE__ */ i(e.TagName, { ...e.attributes, ...e.actionAttributes }) }) : /* @__PURE__ */ i(w, { children: typeof e.TagName == "string" ? /* @__PURE__ */ i(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) : /* @__PURE__ */ i(e.TagName, { ...e.attributes, ...e.actionAttributes, children: e.children }) }) });
|
|
9
9
|
}
|
|
10
10
|
function xe(e) {
|
|
11
11
|
return /* @__PURE__ */ i(
|
|
@@ -78,7 +78,7 @@ function Ce(e) {
|
|
|
78
78
|
}
|
|
79
79
|
function d() {
|
|
80
80
|
var r, g;
|
|
81
|
-
|
|
81
|
+
E() && !((r = e.blocks) != null && r.length) && ((g = window.parent) == null || g.postMessage(
|
|
82
82
|
{
|
|
83
83
|
type: "builder.clickEmptyBlocks",
|
|
84
84
|
data: {
|
|
@@ -91,7 +91,7 @@ function Ce(e) {
|
|
|
91
91
|
}
|
|
92
92
|
function S() {
|
|
93
93
|
var r, g;
|
|
94
|
-
|
|
94
|
+
E() && !((r = e.blocks) != null && r.length) && ((g = window.parent) == null || g.postMessage(
|
|
95
95
|
{
|
|
96
96
|
type: "builder.hoverEmptyBlocks",
|
|
97
97
|
data: {
|
|
@@ -102,7 +102,7 @@ function Ce(e) {
|
|
|
102
102
|
"*"
|
|
103
103
|
));
|
|
104
104
|
}
|
|
105
|
-
return /* @__PURE__ */ I(
|
|
105
|
+
return /* @__PURE__ */ I(w, { children: [
|
|
106
106
|
/* @__PURE__ */ i(
|
|
107
107
|
e.BlocksWrapper,
|
|
108
108
|
{
|
|
@@ -157,8 +157,8 @@ function we(e) {
|
|
|
157
157
|
};
|
|
158
158
|
return e.aspectRatio ? s : void 0;
|
|
159
159
|
}
|
|
160
|
-
return /* @__PURE__ */ I(
|
|
161
|
-
/* @__PURE__ */ I(
|
|
160
|
+
return /* @__PURE__ */ I(w, { children: [
|
|
161
|
+
/* @__PURE__ */ I(w, { children: [
|
|
162
162
|
/* @__PURE__ */ I("picture", { children: [
|
|
163
163
|
d() ? /* @__PURE__ */ i("source", { type: "image/webp", srcSet: d() }) : null,
|
|
164
164
|
/* @__PURE__ */ i(
|
|
@@ -188,7 +188,7 @@ function we(e) {
|
|
|
188
188
|
}
|
|
189
189
|
}
|
|
190
190
|
) : null,
|
|
191
|
-
(h = (b = e.builderBlock) == null ? void 0 : b.children) != null && h.length && e.fitContent ? /* @__PURE__ */ i(
|
|
191
|
+
(h = (b = e.builderBlock) == null ? void 0 : b.children) != null && h.length && e.fitContent ? /* @__PURE__ */ i(w, { children: e.children }) : null,
|
|
192
192
|
!e.fitContent && e.children ? /* @__PURE__ */ i("div", { className: "div-a0c95e8c-2", children: e.children }) : null
|
|
193
193
|
] }),
|
|
194
194
|
/* @__PURE__ */ i("style", { children: `.img-a0c95e8c {
|
|
@@ -312,7 +312,7 @@ function Te(e) {
|
|
|
312
312
|
src: e.imgSrc || e.image,
|
|
313
313
|
...e.attributes
|
|
314
314
|
},
|
|
315
|
-
|
|
315
|
+
E() && e.imgSrc || "default-key"
|
|
316
316
|
);
|
|
317
317
|
}
|
|
318
318
|
function Ne(e) {
|
|
@@ -525,7 +525,7 @@ function Be(e) {
|
|
|
525
525
|
var t, o;
|
|
526
526
|
const n = ((o = (t = e.builderContextSignal.content) == null ? void 0 : t.data) == null ? void 0 : o.httpRequests) ?? {};
|
|
527
527
|
Object.entries(n).forEach(([c, u]) => {
|
|
528
|
-
if (!u || m[c] || s[c] && !
|
|
528
|
+
if (!u || m[c] || s[c] && !E())
|
|
529
529
|
return;
|
|
530
530
|
m[c] = !0;
|
|
531
531
|
const x = u.replace(
|
|
@@ -553,7 +553,7 @@ function Be(e) {
|
|
|
553
553
|
});
|
|
554
554
|
}
|
|
555
555
|
function P() {
|
|
556
|
-
|
|
556
|
+
E() && window.dispatchEvent(
|
|
557
557
|
new CustomEvent(
|
|
558
558
|
"builder:component:stateChange",
|
|
559
559
|
{
|
|
@@ -629,7 +629,7 @@ function Be(e) {
|
|
|
629
629
|
}, []), f(() => {
|
|
630
630
|
var n, t;
|
|
631
631
|
if (H()) {
|
|
632
|
-
if (
|
|
632
|
+
if (E() && a.current && a.current.dispatchEvent(new CustomEvent("initeditingbldr")), e.builderContextSignal.content && _(e.canTrack)) {
|
|
633
633
|
const c = (n = e.builderContextSignal.content) == null ? void 0 : n.testVariationId, u = (t = e.builderContextSignal.content) == null ? void 0 : t.id, x = e.apiKey;
|
|
634
634
|
V({
|
|
635
635
|
type: "impression",
|
|
@@ -639,7 +639,7 @@ function Be(e) {
|
|
|
639
639
|
variationId: c !== u ? c : void 0
|
|
640
640
|
});
|
|
641
641
|
}
|
|
642
|
-
p();
|
|
642
|
+
p() && E();
|
|
643
643
|
}
|
|
644
644
|
}, []), f(() => {
|
|
645
645
|
e.apiKey || ee.error(
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use server";"use strict";const n=require("./bundle-
|
|
1
|
+
"use server";"use strict";const n=require("./bundle-9744b895.cjs");async function s({key:e,value:t}){return n.init(),globalThis._BUILDER_PREVIEW_LRU_CACHE.set(e,t),{[e]:t}}exports.postPreviewContent=s;
|