@builder.io/sdk-vue 0.1.13 → 0.1.14
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/package.json +1 -1
- package/packages/_vue2/dist/{block-styles.f55da466.cjs → block-styles.a33b589b.cjs} +1 -1
- package/packages/_vue2/dist/{block-styles.03915da1.js → block-styles.e4fa133a.js} +3 -3
- package/packages/_vue2/dist/{css.05bd82ed.js → css.9a515005.js} +1 -1
- package/packages/_vue2/dist/css.a4a781f2.cjs +6 -0
- package/packages/_vue2/dist/{index.3bd1f67e.js → index.3826ad2c.js} +6 -6
- package/packages/_vue2/dist/{index.cbc06228.cjs → index.9e0fbaa1.cjs} +3 -3
- package/packages/_vue2/dist/{render-block.5334a9b5.cjs → render-block.65396344.cjs} +2 -2
- package/packages/_vue2/dist/{render-block.58a5d354.js → render-block.8857ae34.js} +5 -5
- package/packages/_vue2/dist/{render-component.88a8e955.cjs → render-component.b187cca7.cjs} +1 -1
- package/packages/_vue2/dist/{render-component.934cdac4.js → render-component.d54274f2.js} +3 -3
- package/packages/_vue2/dist/{render-inlined-styles.e576c02d.cjs → render-inlined-styles.aaa60ee3.cjs} +1 -1
- package/packages/_vue2/dist/{render-inlined-styles.067d5d11.js → render-inlined-styles.f560a740.js} +1 -1
- package/packages/_vue2/dist/{render-repeated-block.84bf8874.js → render-repeated-block.43d7ad78.js} +2 -2
- package/packages/_vue2/dist/{render-repeated-block.47f15cef.cjs → render-repeated-block.a24ffa4d.cjs} +1 -1
- package/packages/_vue2/dist/{render-styles.4764220d.js → render-styles.06311886.js} +2 -2
- package/packages/_vue2/dist/{render-styles.677a15af.cjs → render-styles.3df98784.cjs} +3 -3
- package/packages/_vue2/dist/sdk.cjs +1 -1
- package/packages/_vue2/dist/sdk.js +1 -1
- package/packages/_vue2/dist/style.css +1 -1
- package/packages/_vue3/dist/{block-styles.bab3c28f.js → block-styles.6bad6a44.js} +3 -3
- package/packages/_vue3/dist/{block-styles.58529395.cjs → block-styles.c334abc4.cjs} +1 -1
- package/packages/_vue3/dist/{css.8ed20b10.js → css.162effaf.js} +1 -1
- package/packages/_vue3/dist/{css.63d69670.cjs → css.9c26446d.cjs} +1 -1
- package/packages/_vue3/dist/{index.395b8a3c.cjs → index.51c251ae.cjs} +3 -3
- package/packages/_vue3/dist/{index.2ad3b0cb.js → index.77da28db.js} +6 -6
- package/packages/_vue3/dist/{render-block.5350aee7.js → render-block.55844e87.js} +5 -5
- package/packages/_vue3/dist/{render-block.8923e93f.cjs → render-block.75044288.cjs} +2 -2
- package/packages/_vue3/dist/{render-component.ed1c21ce.js → render-component.445bfcc5.js} +3 -3
- package/packages/_vue3/dist/{render-component.02d9c77a.cjs → render-component.a3596f45.cjs} +1 -1
- package/packages/_vue3/dist/{render-inlined-styles.9f82189a.js → render-inlined-styles.799a72a2.js} +1 -1
- package/packages/_vue3/dist/{render-inlined-styles.7f9d50aa.cjs → render-inlined-styles.a41845aa.cjs} +1 -1
- package/packages/_vue3/dist/{render-repeated-block.86e8e344.js → render-repeated-block.3650cb4b.js} +2 -2
- package/packages/_vue3/dist/{render-repeated-block.9e462881.cjs → render-repeated-block.9f7871c0.cjs} +1 -1
- package/packages/_vue3/dist/{render-styles.cb23fa6b.js → render-styles.6ed62c76.js} +2 -2
- package/packages/_vue3/dist/{render-styles.33387f8f.cjs → render-styles.c70124f9.cjs} +2 -2
- package/packages/_vue3/dist/sdk.cjs +1 -1
- package/packages/_vue3/dist/sdk.js +1 -1
- package/packages/_vue3/dist/style.css +1 -1
- package/packages/_vue2/dist/css.13f6a54e.cjs +0 -6
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index.9e0fbaa1.cjs"),o=require("./css.a4a781f2.cjs"),h=()=>Promise.resolve().then(()=>require("./render-inlined-styles.aaa60ee3.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderInlinedStyles at ../render-inlined-styles.vue",e),e}),y={name:"block-styles",components:{RenderInlinedStyles:h},props:["block","context"],data(){return{TARGET:t.TARGET}},computed:{useBlock(){return o.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!0})},canShowBlock(){return t.checkIsDefined(this.useBlock.hide)?!this.useBlock.hide:t.checkIsDefined(this.useBlock.show)?this.useBlock.show:!0},css(){var a;const e=this.useBlock.responsiveStyles,s=this.context.content,n=t.getSizesForBreakpoints(((a=s==null?void 0:s.meta)==null?void 0:a.breakpoints)||{}),r=e==null?void 0:e.large,c=e==null?void 0:e.medium,i=e==null?void 0:e.small,l=this.useBlock.id,u=r?o.createCssClass({className:l,styles:r}):"",d=c?o.createCssClass({className:l,styles:c,mediaQuery:t.getMaxWidthQueryForSize("medium",n)}):"",m=i?o.createCssClass({className:l,styles:i,mediaQuery:t.getMaxWidthQueryForSize("small",n)}):"";return[u,d,m].join(" ")}}};var k=function(){var s=this,n=s._self._c;return s.TARGET!=="reactNative"&&s.css&&s.canShowBlock?n("render-inlined-styles",{attrs:{styles:s.css}}):s._e()},S=[],p=t.normalizeComponent(y,k,S,!1,null,null,null,null);const f=p.exports;exports.default=f;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { T as k, c as i, g as p, a as u, n as y } from "./index.
|
|
2
|
-
import { g as _, c as o } from "./css.
|
|
3
|
-
const S = () => import("./render-inlined-styles.
|
|
1
|
+
import { T as k, c as i, g as p, a as u, n as y } from "./index.3826ad2c.js";
|
|
2
|
+
import { g as _, c as o } from "./css.9a515005.js";
|
|
3
|
+
const S = () => import("./render-inlined-styles.f560a740.js").then((e) => e.default).catch((e) => {
|
|
4
4
|
throw console.error(
|
|
5
5
|
"Error while attempting to dynamically import component RenderInlinedStyles at ../render-inlined-styles.vue",
|
|
6
6
|
e
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";const i=require("./index.9e0fbaa1.cjs"),l=(e,t,r)=>{if(Object(e)!==e)return e;const s=Array.isArray(t)?t:t.toString().match(/[^.[\]]+/g);return s.slice(0,-1).reduce((n,o,c)=>Object(n[o])===n[o]?n[o]:n[o]=Math.abs(Number(s[c+1]))>>0===+s[c+1]?[]:{},e)[s[s.length-1]]=r,e};const f=({block:e,context:t,state:r})=>{if(!e.bindings)return e;const s=i.fastClone(e),n={...s,properties:{...s.properties},actions:{...s.actions}};for(const o in e.bindings){const c=e.bindings[o],u=i.evaluate({code:c,state:r,context:t});l(n,o,u)}return n};function d({block:e,context:t,shouldEvaluateBindings:r,state:s}){const n=e;return r?f({block:n,state:s,context:t}):n}const p=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),a=e=>Object.entries(e).map(([r,s])=>{if(typeof s=="string")return`${p(r)}: ${s};`}).filter(i.checkIsDefined),g=e=>a(e).join(`
|
|
2
|
+
`),C=({mediaQuery:e,className:t,styles:r})=>{const s=`.${t} {
|
|
3
|
+
${g(r)}
|
|
4
|
+
}`;return e?`${e} {
|
|
5
|
+
${s}
|
|
6
|
+
}`:s};exports.convertStyleMapToCSSArray=a;exports.createCssClass=C;exports.getProcessedBlock=d;
|
|
@@ -113,7 +113,7 @@ const Q = Y.exports, w = (t) => JSON.parse(JSON.stringify(t)), P = {
|
|
|
113
113
|
"Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",
|
|
114
114
|
t
|
|
115
115
|
), t;
|
|
116
|
-
}), ne = () => import("./render-inlined-styles.
|
|
116
|
+
}), ne = () => import("./render-inlined-styles.f560a740.js").then((t) => t.default).catch((t) => {
|
|
117
117
|
throw console.error(
|
|
118
118
|
"Error while attempting to dynamically import component RenderInlinedStyles at ../../components/render-inlined-styles.vue",
|
|
119
119
|
t
|
|
@@ -197,7 +197,7 @@ const Q = Y.exports, w = (t) => JSON.parse(JSON.stringify(t)), P = {
|
|
|
197
197
|
return this.stackAt === "never" ? e : t;
|
|
198
198
|
},
|
|
199
199
|
columnCssVars(t) {
|
|
200
|
-
const e = this.getColumnCssWidth(t), n = `${t === 0 ? 0 : this.gutterSize}px`, o = "100%", s =
|
|
200
|
+
const e = this.getColumnCssWidth(t), n = `${t === 0 ? 0 : this.gutterSize}px`, o = "100%", s = 0;
|
|
201
201
|
return {
|
|
202
202
|
width: e,
|
|
203
203
|
"margin-left": n,
|
|
@@ -255,7 +255,7 @@ var se = function() {
|
|
|
255
255
|
re,
|
|
256
256
|
!1,
|
|
257
257
|
null,
|
|
258
|
-
"
|
|
258
|
+
"bcf8543c",
|
|
259
259
|
null,
|
|
260
260
|
null
|
|
261
261
|
);
|
|
@@ -397,12 +397,12 @@ function _e() {
|
|
|
397
397
|
function g() {
|
|
398
398
|
return _e() && window.location.search.indexOf("builder.frameEditing=") !== -1;
|
|
399
399
|
}
|
|
400
|
-
const xe = () => import("./block-styles.
|
|
400
|
+
const xe = () => import("./block-styles.e4fa133a.js").then((t) => t.default).catch((t) => {
|
|
401
401
|
throw console.error(
|
|
402
402
|
"Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",
|
|
403
403
|
t
|
|
404
404
|
), t;
|
|
405
|
-
}), ke = () => import("./render-block.
|
|
405
|
+
}), ke = () => import("./render-block.8857ae34.js").then((t) => t.default).catch((t) => {
|
|
406
406
|
throw console.error(
|
|
407
407
|
"Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",
|
|
408
408
|
t
|
|
@@ -2147,7 +2147,7 @@ const un = (t, e, n = !0) => {
|
|
|
2147
2147
|
"Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",
|
|
2148
2148
|
t
|
|
2149
2149
|
), t;
|
|
2150
|
-
}), bn = () => import("./render-styles.
|
|
2150
|
+
}), bn = () => import("./render-styles.06311886.js").then((t) => t.default).catch((t) => {
|
|
2151
2151
|
throw console.error(
|
|
2152
2152
|
"Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",
|
|
2153
2153
|
t
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const pe={name:"builder-button",props:["attributes","text","link","openLinkInNewTab"],methods:{filterAttrs:function(e={},n){const o="v-on:";return Object.keys(e).filter(r=>{const s=r.startsWith(o);return n?s:!s}).reduce((r,s)=>({...r,[s.replace(o,"")]:e[s]}),{})}}};function m(t,e,n,o,r,s,i,l){var a=typeof t=="function"?t.options:t;e&&(a.render=e,a.staticRenderFns=n,a._compiled=!0),o&&(a.functional=!0),s&&(a._scopeId="data-v-"+s);var c;if(i?(c=function(u){u=u||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,!u&&typeof __VUE_SSR_CONTEXT__<"u"&&(u=__VUE_SSR_CONTEXT__),r&&r.call(this,u),u&&u._registeredComponents&&u._registeredComponents.add(i)},a._ssrRegister=c):r&&(c=l?function(){r.call(this,(a.functional?this.parent:this).$root.$options.shadowRoot)}:r),c)if(a.functional){a._injectStyles=c;var d=a.render;a.render=function(f,v){return c.call(v),d(f,v)}}else{var h=a.beforeCreate;a.beforeCreate=h?[].concat(h,c):[c]}return{exports:t,options:a}}var me=function(){var e=this,n=e._self._c;return e.link?n("a",e._g(e._b({attrs:{role:"button",href:e.link,target:e.openLinkInNewTab?"_blank":void 0}},"a",e.filterAttrs(e.attributes,!1),!1),e.filterAttrs(e.attributes,!0)),[e._v(" "+e._s(e.text)+" ")]):n("button",e._g(e._b({staticClass:"button-2fnk003dqad"},"button",e.filterAttrs(e.attributes,!1),!1),e.filterAttrs(e.attributes,!0)),[e._v(" "+e._s(e.text)+" ")])},he=[],fe=m(pe,me,he,!1,null,"3e6fa42c",null,null);const U=fe.exports,x=t=>JSON.parse(JSON.stringify(t)),W={small:{min:320,default:321,max:640},medium:{min:641,default:642,max:991},large:{min:990,default:991,max:1200}},ge=(t,e=W)=>`@media (max-width: ${e[t].max}px)`,M=({small:t,medium:e})=>{const n=x(W);if(!t||!e)return n;const o=Math.floor(t/2);n.small={max:t,min:o,default:o+1};const r=n.small.max+1;n.medium={max:e,min:r,default:r+1};const s=n.medium.max+1;return n.large={max:2e3,min:s,default:s+1},n},y="vue2",be=Symbol(),_={Builder:{content:null,context:{},state:{},setState(){},apiKey:null,apiVersion:void 0,registeredComponents:{},inheritedStyles:{}},key:be},ye=()=>Promise.resolve().then(()=>H).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",t),t}),ve=()=>Promise.resolve().then(()=>require("./render-inlined-styles.
|
|
1
|
+
"use strict";const pe={name:"builder-button",props:["attributes","text","link","openLinkInNewTab"],methods:{filterAttrs:function(e={},n){const o="v-on:";return Object.keys(e).filter(r=>{const s=r.startsWith(o);return n?s:!s}).reduce((r,s)=>({...r,[s.replace(o,"")]:e[s]}),{})}}};function m(t,e,n,o,r,s,i,l){var a=typeof t=="function"?t.options:t;e&&(a.render=e,a.staticRenderFns=n,a._compiled=!0),o&&(a.functional=!0),s&&(a._scopeId="data-v-"+s);var c;if(i?(c=function(u){u=u||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,!u&&typeof __VUE_SSR_CONTEXT__<"u"&&(u=__VUE_SSR_CONTEXT__),r&&r.call(this,u),u&&u._registeredComponents&&u._registeredComponents.add(i)},a._ssrRegister=c):r&&(c=l?function(){r.call(this,(a.functional?this.parent:this).$root.$options.shadowRoot)}:r),c)if(a.functional){a._injectStyles=c;var d=a.render;a.render=function(f,v){return c.call(v),d(f,v)}}else{var h=a.beforeCreate;a.beforeCreate=h?[].concat(h,c):[c]}return{exports:t,options:a}}var me=function(){var e=this,n=e._self._c;return e.link?n("a",e._g(e._b({attrs:{role:"button",href:e.link,target:e.openLinkInNewTab?"_blank":void 0}},"a",e.filterAttrs(e.attributes,!1),!1),e.filterAttrs(e.attributes,!0)),[e._v(" "+e._s(e.text)+" ")]):n("button",e._g(e._b({staticClass:"button-2fnk003dqad"},"button",e.filterAttrs(e.attributes,!1),!1),e.filterAttrs(e.attributes,!0)),[e._v(" "+e._s(e.text)+" ")])},he=[],fe=m(pe,me,he,!1,null,"3e6fa42c",null,null);const U=fe.exports,x=t=>JSON.parse(JSON.stringify(t)),W={small:{min:320,default:321,max:640},medium:{min:641,default:642,max:991},large:{min:990,default:991,max:1200}},ge=(t,e=W)=>`@media (max-width: ${e[t].max}px)`,M=({small:t,medium:e})=>{const n=x(W);if(!t||!e)return n;const o=Math.floor(t/2);n.small={max:t,min:o,default:o+1};const r=n.small.max+1;n.medium={max:e,min:r,default:r+1};const s=n.medium.max+1;return n.large={max:2e3,min:s,default:s+1},n},y="vue2",be=Symbol(),_={Builder:{content:null,context:{},state:{},setState(){},apiKey:null,apiVersion:void 0,registeredComponents:{},inheritedStyles:{}},key:be},ye=()=>Promise.resolve().then(()=>H).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",t),t}),ve=()=>Promise.resolve().then(()=>require("./render-inlined-styles.aaa60ee3.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderInlinedStyles at ../../components/render-inlined-styles.vue",t),t}),_e={name:"builder-columns",components:{RenderInlinedStyles:ve,RenderBlocks:ye},props:["space","columns","stackColumnsAt","reverseColumnsWhenStacked","builderBlock"],data(){return{gutterSize:typeof this.space=="number"?this.space||0:20,cols:this.columns||[],stackAt:this.stackColumnsAt||"tablet",flexDir:this.stackColumnsAt==="never"?"row":this.reverseColumnsWhenStacked?"column-reverse":"column",TARGET:y}},inject:{builderContext:_.key},computed:{columnsCssVars(){return{"--flex-dir":this.flexDir,"--flex-dir-tablet":this.getTabletStyle({stackedStyle:this.flexDir,desktopStyle:"row"})}},columnsStyles(){return`
|
|
2
2
|
@media (max-width: ${this.getWidthForBreakpointSize("medium")}px) {
|
|
3
3
|
.${this.builderBlock.id}-breakpoints {
|
|
4
4
|
flex-direction: var(--flex-dir-tablet);
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
margin-left: var(--column-margin-left-mobile) !important;
|
|
23
23
|
}
|
|
24
24
|
},
|
|
25
|
-
`}},methods:{getWidth(t){var e;return((e=this.cols[t])==null?void 0:e.width)||100/this.cols.length},getColumnCssWidth(t){const e=this.gutterSize*(this.cols.length-1)/this.cols.length;return`calc(${this.getWidth(t)}% - ${e}px)`},getTabletStyle({stackedStyle:t,desktopStyle:e}){return this.stackAt==="tablet"?t:e},getMobileStyle({stackedStyle:t,desktopStyle:e}){return this.stackAt==="never"?e:t},columnCssVars(t){const e=this.getColumnCssWidth(t),n=`${t===0?0:this.gutterSize}px`,o="100%",r="0";return{width:e,"margin-left":n,"--column-width-mobile":this.getMobileStyle({stackedStyle:o,desktopStyle:e}),"--column-margin-left-mobile":this.getMobileStyle({stackedStyle:r,desktopStyle:n}),"--column-width-tablet":this.getTabletStyle({stackedStyle:o,desktopStyle:e}),"--column-margin-left-tablet":this.getTabletStyle({stackedStyle:r,desktopStyle:n})}},getWidthForBreakpointSize(t){var n,o;return M(((o=(n=this.builderContext.content)==null?void 0:n.meta)==null?void 0:o.breakpoints)||{})[t].max},_classStringToObject(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\s+/);for(const o of n)e[o]=!0;return e}}};var xe=function(){var e=this,n=e._self._c;return n("div",{class:e._classStringToObject(`builder-columns ${e.builderBlock.id}-breakpoints div-t9spj7joih`),style:e.columnsCssVars,attrs:{dataSet:{"builder-block-name":"builder-columns"}}},[e.TARGET!=="reactNative"?[n("render-inlined-styles",{attrs:{styles:e.columnsStyles}})]:e._e(),e._l(e.columns,function(o,r){return n("div",{key:r,staticClass:"builder-column div-t9spj7joih-2",style:e.columnCssVars(r),attrs:{dataSet:{"builder-block-name":"builder-column"}}},[n("render-blocks",{attrs:{blocks:o.blocks,path:`component.options.columns.${r}.blocks`,parent:e.builderBlock.id,styleProp:{flexGrow:"1"}}})],1)})],2)},ke=[],Se=m(_e,xe,ke,!1,null,"e352abf5",null,null);const L=Se.exports,Ce={name:"builder-fragment-component",props:[]};var we=function(){var e=this,n=e._self._c;return n("span",[e._t("default")],2)},Re=[],Te=m(Ce,we,Re,!1,null,null,null,null);const N=Te.exports;function E(t){return t.replace(/http(s)?:/,"")}function Ie(t="",e,n){const o=new RegExp("([?&])"+e+"=.*?(&|$)","i"),r=t.indexOf("?")!==-1?"&":"?";return t.match(o)?t.replace(o,"$1"+e+"="+encodeURIComponent(n)+"$2"):t+r+e+"="+encodeURIComponent(n)}function $e(t,e){if(!t||!(t!=null&&t.match(/cdn\.shopify\.com/))||!e)return t;if(e==="master")return E(t);const n=t.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);if(n){const o=t.split(n[0]),r=n[3],s=e.match("x")?e:`${e}x`;return E(`${o[0]}_${s}${r}`)}return null}function S(t){if(!t)return t;const e=[100,200,400,800,1200,1600,2e3];if(t.match(/builder\.io/)){let n=t;const o=Number(t.split("?width=")[1]);return isNaN(o)||(n=`${n} ${o}w`),e.filter(r=>r!==o).map(r=>`${Ie(t,"width",r)} ${r}w`).concat([n]).join(", ")}return t.match(/cdn\.shopify\.com/)?e.map(n=>[$e(t,`${n}x${n}`),n]).filter(([n])=>!!n).map(([n,o])=>`${n} ${o}w`).concat([t]).join(", "):t}const Ee={name:"builder-image",props:["image","src","srcset","noWebp","aspectRatio","altText","backgroundPosition","backgroundSize","className","sizes","builderBlock","fitContent"],computed:{srcSetToUse(){var n;const e=this.image||this.src;if(!e||!(e.match(/builder\.io/)||e.match(/cdn\.shopify\.com/)))return this.srcset;if(this.srcset&&((n=this.image)==null?void 0:n.includes("builder.io/api/v1/image"))){if(!this.srcset.includes(this.image.split("?")[0]))return console.debug("Removed given srcset"),S(e)}else if(this.image&&!this.srcset)return S(e);return S(e)},webpSrcSet(){var t;return((t=this.srcSetToUse)==null?void 0:t.match(/builder\.io/))&&!this.noWebp?this.srcSetToUse.replace(/\?/g,"?format=webp&"):""},aspectRatioCss(){const t={position:"absolute",height:"100%",width:"100%",left:"0px",top:"0px"};return this.aspectRatio?t:void 0}},methods:{_classStringToObject(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\s+/);for(const o of n)e[o]=!0;return e}}};var Fe=function(){var o,r,s,i;var e=this,n=e._self._c;return n("div",[n("picture",[e.webpSrcSet?[n("source",{attrs:{type:"image/webp",srcset:e.webpSrcSet}})]:e._e(),n("img",{class:e._classStringToObject("builder-image"+(e.className?" "+e.className:"")+" img-1pl23ac79ld"),style:{objectPosition:e.backgroundPosition||"center",objectFit:e.backgroundSize||"cover",...e.aspectRatioCss},attrs:{loading:"lazy",alt:e.altText,role:e.altText?"presentation":void 0,src:e.image,srcset:e.srcSetToUse,sizes:e.sizes}})],2),e.aspectRatio&&!(((r=(o=e.builderBlock)==null?void 0:o.children)==null?void 0:r.length)&&e.fitContent)?[n("div",{staticClass:"builder-image-sizer div-1pl23ac79ld",style:{paddingTop:e.aspectRatio*100+"%"}})]:e._e(),((i=(s=e.builderBlock)==null?void 0:s.children)==null?void 0:i.length)&&e.fitContent?[e._t("default")]:e._e(),!e.fitContent&&e.children?[n("div",{staticClass:"div-1pl23ac79ld-2"},[e._t("default")],2)]:e._e()],2)},Ae=[],Pe=m(Ee,Fe,Ae,!1,null,"d14c6f82",null,null);const z=Pe.exports;function p(){return typeof window<"u"&&typeof document<"u"}function je(){return p()&&window.self!==window.top}function g(){return je()&&window.location.search.indexOf("builder.frameEditing=")!==-1}const Ve=()=>Promise.resolve().then(()=>require("./block-styles.f55da466.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",t),t}),Be=()=>Promise.resolve().then(()=>require("./render-block.5334a9b5.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",t),t}),Oe={name:"render-blocks",components:{RenderBlock:Be,BlockStyles:Ve},props:["blocks","parent","path","styleProp"],inject:{builderContext:_.key},computed:{className(){var t;return"builder-blocks"+((t=this.blocks)!=null&&t.length?"":" no-blocks")}},methods:{onClick(){var t,e;g()&&!((t=this.blocks)!=null&&t.length)&&((e=window.parent)==null||e.postMessage({type:"builder.clickEmptyBlocks",data:{parentElementId:this.parent,dataPath:this.path}},"*"))},onMouseEnter(){var t,e;g()&&!((t=this.blocks)!=null&&t.length)&&((e=window.parent)==null||e.postMessage({type:"builder.hoverEmptyBlocks",data:{parentElementId:this.parent,dataPath:this.path}},"*"))},_classStringToObject(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\s+/);for(const o of n)e[o]=!0;return e}}};var Ue=function(){var e=this,n=e._self._c;return n("div",{class:e._classStringToObject(e.className+" div-21azgz5avex"),style:e.styleProp,attrs:{"builder-path":e.path,"builder-parent-id":e.parent,dataSet:{class:e.className}},on:{click:function(o){return e.onClick()},mouseenter:function(o){return e.onMouseEnter()}}},[e.blocks?e._l(e.blocks,function(o,r){return n("render-block",{key:"render-block-"+o.id,attrs:{block:o,context:e.builderContext}})}):e._e(),e.blocks?e._l(e.blocks,function(o,r){return n("block-styles",{key:"block-style-"+o.id,attrs:{block:o,context:e.builderContext}})}):e._e()],2)},We=[],Me=m(Oe,Ue,We,!1,null,"7d4553c5",null,null);const K=Me.exports,H=Object.freeze(Object.defineProperty({__proto__:null,default:K},Symbol.toStringTag,{value:"Module"})),Le={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},k=t=>{const e=t.toString().trim();return`return (${!e.startsWith("function")&&!e.startsWith("(")?"function ":""}${e}).apply(this, arguments)`},Ne={name:"Columns",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:k(t=>{function e(){n.forEach(o=>{o.delete("width")})}const n=t.get("columns");Array.isArray(n)&&!!n.find(r=>r.get("width"))&&(!!n.find(s=>!s.get("width"))||n.reduce((l,a)=>l+a.get("width"),0)!==100)&&e()})},{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}]},ze={name:"Fragment",static:!0,hidden:!0,canHaveChildren:!0,noWrap:!0},Ke={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:["jpeg","jpg","png","svg"],required:!0,defaultValue:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",onChange:k(t=>{t.delete("srcset"),t.delete("noWebp");function n(i,l=6e4){return new Promise((a,c)=>{const d=document.createElement("img");let h=!1;d.onload=()=>{h=!0,a(d)},d.addEventListener("error",u=>{console.warn("Image load failed",u.error),c(u.error)}),d.src=i,setTimeout(()=>{h||c(new Error("Image load timed out"))},l)})}function o(i){return Math.round(i*1e3)/1e3}const r=t.get("image"),s=t.get("aspectRatio");if(fetch(r).then(i=>i.blob()).then(i=>{i.type.includes("svg")&&t.set("noWebp",!0)}),r&&(!s||s===.7041))return n(r).then(i=>{const l=t.get("aspectRatio");t.get("image")===r&&(!l||l===.7041)&&i.width&&i.height&&(t.set("aspectRatio",o(i.height/i.width)),t.set("height",i.height),t.set("width",i.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:"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}]},He={name:"Core:Section",static:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",inputs:[{name:"maxWidth",type:"number",defaultValue:1200},{name:"lazyLoad",type:"boolean",defaultValue:!1,advanced:!0,description:"Only render this section when in view"}],defaultStyles:{paddingLeft:"20px",paddingRight:"20px",paddingTop:"50px",paddingBottom:"50px",marginTop:"0px",width:"100vw",marginLeft:"calc(50% - 50vw)"},canHaveChildren:!0,defaultChildren:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"center"}},component:{name:"Text",options:{text:"<p><b>I am a section! My content keeps from getting too wide, so that it's easy to read even on big screens.</b></p><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur</p>"}}}]},De={name:"builder-section-component",props:["maxWidth","attributes"],methods:{filterAttrs:function(e={},n){const o="v-on:";return Object.keys(e).filter(r=>{const s=r.startsWith(o);return n?s:!s}).reduce((r,s)=>({...r,[s.replace(o,"")]:e[s]}),{})}}};var qe=function(){var e=this,n=e._self._c;return n("section",e._g(e._b({style:{width:"100%",alignSelf:"stretch",flexGrow:1,boxSizing:"border-box",maxWidth:e.maxWidth||1200,display:"flex",flexDirection:"column",alignItems:"stretch",marginLeft:"auto",marginRight:"auto"}},"section",e.filterAttrs(e.attributes,!1),!1),e.filterAttrs(e.attributes,!0)),[e._t("default")],2)},Ge=[],Je=m(De,qe,Ge,!1,null,null,null,null);const D=Je.exports,Xe={name:"Symbol",noWrap:!0,static:!0,inputs:[{name:"symbol",type:"uiSymbol"},{name:"dataOnly",helperText:"Make this a data symbol that doesn't display any UI",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"inheritState",helperText:"Inherit the parent component state and data",type:"boolean",defaultValue:!1,advanced:!0},{name:"renderToLiquid",helperText:"Render this symbols contents to liquid. Turn off to fetch with javascript and use custom targeting",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"useChildren",hideFromUI:!0,type:"boolean"}]};function Ye(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:globalThis}function Qe(){const t=Ye().fetch;if(typeof t>"u")throw console.warn(`Builder SDK could not find a global fetch function. Make sure you have a polyfill for fetch in your project.
|
|
25
|
+
`}},methods:{getWidth(t){var e;return((e=this.cols[t])==null?void 0:e.width)||100/this.cols.length},getColumnCssWidth(t){const e=this.gutterSize*(this.cols.length-1)/this.cols.length;return`calc(${this.getWidth(t)}% - ${e}px)`},getTabletStyle({stackedStyle:t,desktopStyle:e}){return this.stackAt==="tablet"?t:e},getMobileStyle({stackedStyle:t,desktopStyle:e}){return this.stackAt==="never"?e:t},columnCssVars(t){const e=this.getColumnCssWidth(t),n=`${t===0?0:this.gutterSize}px`,o="100%",r=0;return{width:e,"margin-left":n,"--column-width-mobile":this.getMobileStyle({stackedStyle:o,desktopStyle:e}),"--column-margin-left-mobile":this.getMobileStyle({stackedStyle:r,desktopStyle:n}),"--column-width-tablet":this.getTabletStyle({stackedStyle:o,desktopStyle:e}),"--column-margin-left-tablet":this.getTabletStyle({stackedStyle:r,desktopStyle:n})}},getWidthForBreakpointSize(t){var n,o;return M(((o=(n=this.builderContext.content)==null?void 0:n.meta)==null?void 0:o.breakpoints)||{})[t].max},_classStringToObject(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\s+/);for(const o of n)e[o]=!0;return e}}};var xe=function(){var e=this,n=e._self._c;return n("div",{class:e._classStringToObject(`builder-columns ${e.builderBlock.id}-breakpoints div-t9spj7joih`),style:e.columnsCssVars,attrs:{dataSet:{"builder-block-name":"builder-columns"}}},[e.TARGET!=="reactNative"?[n("render-inlined-styles",{attrs:{styles:e.columnsStyles}})]:e._e(),e._l(e.columns,function(o,r){return n("div",{key:r,staticClass:"builder-column div-t9spj7joih-2",style:e.columnCssVars(r),attrs:{dataSet:{"builder-block-name":"builder-column"}}},[n("render-blocks",{attrs:{blocks:o.blocks,path:`component.options.columns.${r}.blocks`,parent:e.builderBlock.id,styleProp:{flexGrow:"1"}}})],1)})],2)},ke=[],Se=m(_e,xe,ke,!1,null,"bcf8543c",null,null);const L=Se.exports,Ce={name:"builder-fragment-component",props:[]};var we=function(){var e=this,n=e._self._c;return n("span",[e._t("default")],2)},Re=[],Te=m(Ce,we,Re,!1,null,null,null,null);const N=Te.exports;function E(t){return t.replace(/http(s)?:/,"")}function Ie(t="",e,n){const o=new RegExp("([?&])"+e+"=.*?(&|$)","i"),r=t.indexOf("?")!==-1?"&":"?";return t.match(o)?t.replace(o,"$1"+e+"="+encodeURIComponent(n)+"$2"):t+r+e+"="+encodeURIComponent(n)}function $e(t,e){if(!t||!(t!=null&&t.match(/cdn\.shopify\.com/))||!e)return t;if(e==="master")return E(t);const n=t.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);if(n){const o=t.split(n[0]),r=n[3],s=e.match("x")?e:`${e}x`;return E(`${o[0]}_${s}${r}`)}return null}function S(t){if(!t)return t;const e=[100,200,400,800,1200,1600,2e3];if(t.match(/builder\.io/)){let n=t;const o=Number(t.split("?width=")[1]);return isNaN(o)||(n=`${n} ${o}w`),e.filter(r=>r!==o).map(r=>`${Ie(t,"width",r)} ${r}w`).concat([n]).join(", ")}return t.match(/cdn\.shopify\.com/)?e.map(n=>[$e(t,`${n}x${n}`),n]).filter(([n])=>!!n).map(([n,o])=>`${n} ${o}w`).concat([t]).join(", "):t}const Ee={name:"builder-image",props:["image","src","srcset","noWebp","aspectRatio","altText","backgroundPosition","backgroundSize","className","sizes","builderBlock","fitContent"],computed:{srcSetToUse(){var n;const e=this.image||this.src;if(!e||!(e.match(/builder\.io/)||e.match(/cdn\.shopify\.com/)))return this.srcset;if(this.srcset&&((n=this.image)==null?void 0:n.includes("builder.io/api/v1/image"))){if(!this.srcset.includes(this.image.split("?")[0]))return console.debug("Removed given srcset"),S(e)}else if(this.image&&!this.srcset)return S(e);return S(e)},webpSrcSet(){var t;return((t=this.srcSetToUse)==null?void 0:t.match(/builder\.io/))&&!this.noWebp?this.srcSetToUse.replace(/\?/g,"?format=webp&"):""},aspectRatioCss(){const t={position:"absolute",height:"100%",width:"100%",left:"0px",top:"0px"};return this.aspectRatio?t:void 0}},methods:{_classStringToObject(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\s+/);for(const o of n)e[o]=!0;return e}}};var Fe=function(){var o,r,s,i;var e=this,n=e._self._c;return n("div",[n("picture",[e.webpSrcSet?[n("source",{attrs:{type:"image/webp",srcset:e.webpSrcSet}})]:e._e(),n("img",{class:e._classStringToObject("builder-image"+(e.className?" "+e.className:"")+" img-1pl23ac79ld"),style:{objectPosition:e.backgroundPosition||"center",objectFit:e.backgroundSize||"cover",...e.aspectRatioCss},attrs:{loading:"lazy",alt:e.altText,role:e.altText?"presentation":void 0,src:e.image,srcset:e.srcSetToUse,sizes:e.sizes}})],2),e.aspectRatio&&!(((r=(o=e.builderBlock)==null?void 0:o.children)==null?void 0:r.length)&&e.fitContent)?[n("div",{staticClass:"builder-image-sizer div-1pl23ac79ld",style:{paddingTop:e.aspectRatio*100+"%"}})]:e._e(),((i=(s=e.builderBlock)==null?void 0:s.children)==null?void 0:i.length)&&e.fitContent?[e._t("default")]:e._e(),!e.fitContent&&e.children?[n("div",{staticClass:"div-1pl23ac79ld-2"},[e._t("default")],2)]:e._e()],2)},Ae=[],Pe=m(Ee,Fe,Ae,!1,null,"d14c6f82",null,null);const z=Pe.exports;function p(){return typeof window<"u"&&typeof document<"u"}function je(){return p()&&window.self!==window.top}function g(){return je()&&window.location.search.indexOf("builder.frameEditing=")!==-1}const Ve=()=>Promise.resolve().then(()=>require("./block-styles.a33b589b.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",t),t}),Be=()=>Promise.resolve().then(()=>require("./render-block.65396344.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",t),t}),Oe={name:"render-blocks",components:{RenderBlock:Be,BlockStyles:Ve},props:["blocks","parent","path","styleProp"],inject:{builderContext:_.key},computed:{className(){var t;return"builder-blocks"+((t=this.blocks)!=null&&t.length?"":" no-blocks")}},methods:{onClick(){var t,e;g()&&!((t=this.blocks)!=null&&t.length)&&((e=window.parent)==null||e.postMessage({type:"builder.clickEmptyBlocks",data:{parentElementId:this.parent,dataPath:this.path}},"*"))},onMouseEnter(){var t,e;g()&&!((t=this.blocks)!=null&&t.length)&&((e=window.parent)==null||e.postMessage({type:"builder.hoverEmptyBlocks",data:{parentElementId:this.parent,dataPath:this.path}},"*"))},_classStringToObject(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\s+/);for(const o of n)e[o]=!0;return e}}};var Ue=function(){var e=this,n=e._self._c;return n("div",{class:e._classStringToObject(e.className+" div-21azgz5avex"),style:e.styleProp,attrs:{"builder-path":e.path,"builder-parent-id":e.parent,dataSet:{class:e.className}},on:{click:function(o){return e.onClick()},mouseenter:function(o){return e.onMouseEnter()}}},[e.blocks?e._l(e.blocks,function(o,r){return n("render-block",{key:"render-block-"+o.id,attrs:{block:o,context:e.builderContext}})}):e._e(),e.blocks?e._l(e.blocks,function(o,r){return n("block-styles",{key:"block-style-"+o.id,attrs:{block:o,context:e.builderContext}})}):e._e()],2)},We=[],Me=m(Oe,Ue,We,!1,null,"7d4553c5",null,null);const K=Me.exports,H=Object.freeze(Object.defineProperty({__proto__:null,default:K},Symbol.toStringTag,{value:"Module"})),Le={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},k=t=>{const e=t.toString().trim();return`return (${!e.startsWith("function")&&!e.startsWith("(")?"function ":""}${e}).apply(this, arguments)`},Ne={name:"Columns",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:k(t=>{function e(){n.forEach(o=>{o.delete("width")})}const n=t.get("columns");Array.isArray(n)&&!!n.find(r=>r.get("width"))&&(!!n.find(s=>!s.get("width"))||n.reduce((l,a)=>l+a.get("width"),0)!==100)&&e()})},{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}]},ze={name:"Fragment",static:!0,hidden:!0,canHaveChildren:!0,noWrap:!0},Ke={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:["jpeg","jpg","png","svg"],required:!0,defaultValue:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",onChange:k(t=>{t.delete("srcset"),t.delete("noWebp");function n(i,l=6e4){return new Promise((a,c)=>{const d=document.createElement("img");let h=!1;d.onload=()=>{h=!0,a(d)},d.addEventListener("error",u=>{console.warn("Image load failed",u.error),c(u.error)}),d.src=i,setTimeout(()=>{h||c(new Error("Image load timed out"))},l)})}function o(i){return Math.round(i*1e3)/1e3}const r=t.get("image"),s=t.get("aspectRatio");if(fetch(r).then(i=>i.blob()).then(i=>{i.type.includes("svg")&&t.set("noWebp",!0)}),r&&(!s||s===.7041))return n(r).then(i=>{const l=t.get("aspectRatio");t.get("image")===r&&(!l||l===.7041)&&i.width&&i.height&&(t.set("aspectRatio",o(i.height/i.width)),t.set("height",i.height),t.set("width",i.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:"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}]},He={name:"Core:Section",static:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",inputs:[{name:"maxWidth",type:"number",defaultValue:1200},{name:"lazyLoad",type:"boolean",defaultValue:!1,advanced:!0,description:"Only render this section when in view"}],defaultStyles:{paddingLeft:"20px",paddingRight:"20px",paddingTop:"50px",paddingBottom:"50px",marginTop:"0px",width:"100vw",marginLeft:"calc(50% - 50vw)"},canHaveChildren:!0,defaultChildren:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"center"}},component:{name:"Text",options:{text:"<p><b>I am a section! My content keeps from getting too wide, so that it's easy to read even on big screens.</b></p><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur</p>"}}}]},De={name:"builder-section-component",props:["maxWidth","attributes"],methods:{filterAttrs:function(e={},n){const o="v-on:";return Object.keys(e).filter(r=>{const s=r.startsWith(o);return n?s:!s}).reduce((r,s)=>({...r,[s.replace(o,"")]:e[s]}),{})}}};var qe=function(){var e=this,n=e._self._c;return n("section",e._g(e._b({style:{width:"100%",alignSelf:"stretch",flexGrow:1,boxSizing:"border-box",maxWidth:e.maxWidth||1200,display:"flex",flexDirection:"column",alignItems:"stretch",marginLeft:"auto",marginRight:"auto"}},"section",e.filterAttrs(e.attributes,!1),!1),e.filterAttrs(e.attributes,!0)),[e._t("default")],2)},Ge=[],Je=m(De,qe,Ge,!1,null,null,null,null);const D=Je.exports,Xe={name:"Symbol",noWrap:!0,static:!0,inputs:[{name:"symbol",type:"uiSymbol"},{name:"dataOnly",helperText:"Make this a data symbol that doesn't display any UI",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"inheritState",helperText:"Inherit the parent component state and data",type:"boolean",defaultValue:!1,advanced:!0},{name:"renderToLiquid",helperText:"Render this symbols contents to liquid. Turn off to fetch with javascript and use custom targeting",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"useChildren",hideFromUI:!0,type:"boolean"}]};function Ye(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:globalThis}function Qe(){const t=Ye().fetch;if(typeof t>"u")throw console.warn(`Builder SDK could not find a global fetch function. Make sure you have a polyfill for fetch in your project.
|
|
26
26
|
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 q=Qe(),b=t=>t!=null,Ze=t=>{if(t==="localhost"||t==="127.0.0.1")return t;const e=t.split(".");return e.length>2?e.slice(1).join("."):t},G=async({name:t,canTrack:e})=>{var n;try{return e?(n=document.cookie.split("; ").find(o=>o.startsWith(`${t}=`)))==null?void 0:n.split("=")[1]:void 0}catch(o){console.debug("[COOKIE] GET error: ",o);return}},et=t=>t.map(([e,n])=>n?`${e}=${n}`:e).filter(b).join("; "),tt=[["secure",""],["SameSite","None"]],nt=({name:t,value:e,expires:n})=>{const r=(p()?location.protocol==="https:":!0)?tt:[[]],s=n?[["expires",n.toUTCString()]]:[[]],i=[[t,e],...s,["path","/"],["domain",Ze(window.location.hostname)],...r];return et(i)},J=async({name:t,value:e,expires:n,canTrack:o})=>{try{if(!o)return;const r=nt({name:t,value:e,expires:n});document.cookie=r}catch(r){console.warn("[COOKIE] SET error: ",r)}},ot="builderio.variations",X=t=>`${ot}.${t}`,rt=({contentId:t,canTrack:e})=>G({name:X(t),canTrack:e}),st=({contentId:t,canTrack:e,value:n})=>J({name:X(t),value:n,canTrack:e}),it=t=>b(t.id)&&b(t.variations)&&Object.keys(t.variations).length>0,at=({id:t,variations:e})=>{var r;let n=0;const o=Math.random();for(const s in e){const i=(r=e[s])==null?void 0:r.testRatio;if(n+=i,o<n)return s}return t},F=({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":"")}},lt=async({item:t,canTrack:e})=>{const n=await rt({canTrack:e,contentId:t.id}),o=n?F({item:t,testGroupId:n}):void 0;if(o)return o;{const r=at({variations:t.variations,id:t.id});return st({contentId:t.id,value:r,canTrack:e}).catch(s=>{console.error("could not store A/B test variation: ",s)}),F({item:t,testGroupId:r})}},ct=async({item:t,canTrack:e})=>{if(!it(t))return;const n=await lt({item:t,canTrack:e});Object.assign(t,n)};function C(t,e=null,n="."){return Object.keys(t).reduce((o,r)=>{const s=t[r],i=[e,r].filter(Boolean).join(n);return[typeof s=="object",s!==null,!(Array.isArray(s)&&s.length===0)].every(Boolean)?{...o,...C(s,i,n)}:{...o,[i]:s}},{})}const A="builder.",dt="options.",Y=t=>{const e={};return t.forEach((n,o)=>{e[o]=n}),e},Q=t=>{if(!t)return{};const e=T(t),n={};return Object.keys(e).forEach(o=>{if(o.startsWith(A)){const r=o.replace(A,"").replace(dt,"");n[r]=e[o]}}),n},Z=()=>{if(!p())return{};const t=new URLSearchParams(window.location.search);return Q(t)},T=t=>t instanceof URLSearchParams?Y(t):t,ut=t=>{const{limit:e=30,userAttributes:n,query:o,noTraverse:r=!1,model:s,apiKey:i,includeRefs:l=!0,locale:a,apiVersion:c="v2"}=t;if(!i)throw new Error("Missing API key");if(!["v2","v3"].includes(c))throw new Error(`Invalid apiVersion: expected 'v2' or 'v3', received '${c}'`);const d=new URL(`https://cdn.builder.io/api/${c}/content/${s}?apiKey=${i}&limit=${e}&noTraverse=${r}&includeRefs=${l}${a?`&locale=${a}`:""}`),h={...Z(),...T(t.options||{})},u=C(h);for(const f in u)d.searchParams.set(f,String(u[f]));if(n&&d.searchParams.set("userAttributes",JSON.stringify(n)),o){const f=C({query:o});for(const v in f)d.searchParams.set(v,JSON.stringify(f[v]))}return d};async function I(t){return(await ee({...t,limit:1})).results[0]||null}async function ee(t){const e=ut(t),o=await(await q(e.href)).json(),r=t.canTrack!==!1;if(r&&Array.isArray(o.results))for(const s of o.results)await ct({item:s,canTrack:r});return o}const pt=()=>Promise.resolve().then(()=>Rn).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderContent at ../../components/render-content/render-content.vue",t),t}),mt={name:"builder-symbol",components:{RenderContent:pt},props:["attributes","symbol","dynamic"],data(){var t,e,n;return{className:[...Object.keys(this.attributes.class),"builder-symbol",(t=this.symbol)!=null&&t.inline?"builder-inline-symbol":void 0,((e=this.symbol)==null?void 0:e.dynamic)||this.dynamic?"builder-dynamic-symbol":void 0].filter(Boolean).join(" "),contentToUse:(n=this.symbol)==null?void 0:n.content}},inject:{builderContext:_.key},mounted(){this.fetchContent()},watch:{onUpdateHook0:{handler(){this.fetchContent()},immediate:!0}},computed:{onUpdateHook0(){return{0:this.symbol}}},methods:{fetchContent(){var t,e;!this.contentToUse&&((t=this.symbol)==null?void 0:t.model)&&((e=this.builderContext)==null?void 0:e.apiKey)&&I({model:this.symbol.model,apiKey:this.builderContext.apiKey,apiVersion:this.builderContext.apiVersion,query:{id:this.symbol.entry}}).then(n=>{n&&(this.contentToUse=n)}).catch(n=>{console.error("[Builder.io]: Could not fetch symbol content: ",n)})},filterAttrs:function(e={},n){const o="v-on:";return Object.keys(e).filter(r=>{const s=r.startsWith(o);return n?s:!s}).reduce((r,s)=>({...r,[s.replace(o,"")]:e[s]}),{})},_classStringToObject(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\s+/);for(const o of n)e[o]=!0;return e}}};var ht=function(){var o,r,s,i;var e=this,n=e._self._c;return n("div",e._g(e._b({class:e._classStringToObject(e.className),attrs:{dataSet:{class:e.className}}},"div",e.filterAttrs(e.attributes,!1),!1),e.filterAttrs(e.attributes,!0)),[n("render-content",{attrs:{apiVersion:e.builderContext.apiVersion,apiKey:e.builderContext.apiKey,context:e.builderContext.context,customComponents:Object.values(e.builderContext.registeredComponents),data:{...(o=e.symbol)==null?void 0:o.data,...e.builderContext.state,...(s=(r=e.contentToUse)==null?void 0:r.data)==null?void 0:s.state},model:(i=e.symbol)==null?void 0:i.model,content:e.contentToUse}})],1)},ft=[],gt=m(mt,ht,ft,!1,null,null,null,null);const te=gt.exports,bt={name:"Text",static:!0,image:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-text_fields-24px%20(1).svg?alt=media&token=12177b73-0ee3-42ca-98c6-0dd003de1929",inputs:[{name:"text",type:"html",required:!0,autoFocus:!0,bubble:!0,defaultValue:"Enter some text..."}],defaultStyles:{lineHeight:"normal",height:"auto",textAlign:"center"}},yt={name:"builder-text",props:["text"]};var vt=function(){var e=this,n=e._self._c;return n("span",{staticClass:"builder-text",style:{outline:"none"},domProps:{innerHTML:e._s(e.text)}})},_t=[],xt=m(yt,vt,_t,!1,null,null,null,null);const ne=xt.exports,kt={name:"Video",canHaveChildren:!0,defaultStyles:{minHeight:"20px",minWidth:"20px"},image:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-videocam-24px%20(1).svg?alt=media&token=49a84e4a-b20e-4977-a650-047f986874bb",inputs:[{name:"video",type:"file",allowedFileTypes:["mp4"],bubble:!0,defaultValue:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/assets%2FKQlEmWDxA0coC3PK6UvkrjwkIGI2%2F28cb070609f546cdbe5efa20e931aa4b?alt=media&token=912e9551-7a7c-4dfb-86b6-3da1537d1a7f",required:!0},{name:"posterImage",type:"file",allowedFileTypes:["jpeg","png"],helperText:"Image to show before the video plays"},{name:"autoPlay",type:"boolean",defaultValue:!0},{name:"controls",type:"boolean",defaultValue:!1},{name:"muted",type:"boolean",defaultValue:!0},{name:"loop",type:"boolean",defaultValue:!0},{name:"playsInline",type:"boolean",defaultValue:!0},{name:"fit",type:"text",defaultValue:"cover",enum:["contain","cover","fill","auto"]},{name:"fitContent",type:"boolean",helperText:"When child blocks are provided, fit to them instead of using the aspect ratio",defaultValue:!0,advanced:!0},{name:"position",type:"text",defaultValue:"center",enum:["center","top","left","right","bottom","top left","top right","bottom left","bottom right"]},{name:"height",type:"number",advanced:!0},{name:"width",type:"number",advanced:!0},{name:"aspectRatio",type:"number",advanced:!0,defaultValue:.7004048582995948},{name:"lazyLoad",type:"boolean",helperText:'Load this video "lazily" - as in only when a user scrolls near the video. Recommended for optmized performance and bandwidth consumption',defaultValue:!0,advanced:!0}]},St={name:"builder-video",props:["autoPlay","muted","controls","loop","playsInline","attributes","fit","position","video","posterImage"],computed:{videoProps(){return{...this.autoPlay===!0?{autoPlay:!0}:{},...this.muted===!0?{muted:!0}:{},...this.controls===!0?{controls:!0}:{},...this.loop===!0?{loop:!0}:{},...this.playsInline===!0?{playsInline:!0}:{}}},spreadProps(){return{...this.attributes,...this.videoProps}}}};var Ct=function(){var o;var e=this,n=e._self._c;return n("video",e._b({style:{width:"100%",height:"100%",...(o=e.attributes)==null?void 0:o.style,objectFit:e.fit,objectPosition:e.position,borderRadius:1},attrs:{src:e.video||"no-src",poster:e.posterImage}},"video",e.spreadProps,!1))},wt=[],Rt=m(St,Ct,wt,!1,null,null,null,null);const oe=Rt.exports,Tt={name:"Embed",static:!0,inputs:[{name:"url",type:"url",required:!0,defaultValue:"",helperText:"e.g. enter a youtube url, google map, etc",onChange:k(t=>{const e=t.get("url");if(e)return t.set("content","Loading..."),fetch(`https://iframe.ly/api/iframely?url=${e}&api_key=ae0e60e78201a3f2b0de4b`).then(o=>o.json()).then(o=>{t.get("url")===e&&(o.html?t.set("content",o.html):t.set("content","Invalid url, please try another"))}).catch(o=>{t.set("content","There was an error embedding this URL, please try again or another URL")});t.delete("content")})},{name:"content",type:"html",defaultValue:'<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',hideFromUI:!0}]},It=["text/javascript","application/javascript","application/ecmascript"],$t=t=>It.includes(t.type),Et={name:"builder-embed",props:["content"],data(){return{scriptsInserted:[],scriptsRun:[],ranInitFn:!1}},watch:{onUpdateHook0:{handler(){this.$refs.elem&&!this.ranInitFn&&(this.ranInitFn=!0,this.findAndRunScripts())},immediate:!0}},computed:{onUpdateHook0(){return{0:this.$refs.elem,1:this.ranInitFn}}},methods:{findAndRunScripts(){if(!this.$refs.elem||!this.$refs.elem.getElementsByTagName)return;const t=this.$refs.elem.getElementsByTagName("script");for(let e=0;e<t.length;e++){const n=t[e];if(n.src&&!this.scriptsInserted.includes(n.src)){this.scriptsInserted.push(n.src);const o=document.createElement("script");o.async=!0,o.src=n.src,document.head.appendChild(o)}else if($t(n)&&!this.scriptsRun.includes(n.innerText))try{this.scriptsRun.push(n.innerText),new Function(n.innerText)()}catch(o){console.warn("`Embed`: Error running script:",o)}}}}};var Ft=function(){var e=this,n=e._self._c;return n("div",{ref:"elem",staticClass:"builder-embed",domProps:{innerHTML:e._s(e.content)}})},At=[],Pt=m(Et,Ft,At,!1,null,null,null,null);const jt=Pt.exports,Vt={name:"builder-img-component",props:["backgroundSize","backgroundPosition","imgSrc","altText","image","attributes"],data(){return{isEditing:g}},methods:{filterAttrs:function(e={},n){const o="v-on:";return Object.keys(e).filter(r=>{const s=r.startsWith(o);return n?s:!s}).reduce((r,s)=>({...r,[s.replace(o,"")]:e[s]}),{})}}};var Bt=function(){var e=this,n=e._self._c;return n("img",e._g(e._b({key:e.isEditing()&&e.imgSrc||"default-key",style:{objectFit:e.backgroundSize||"cover",objectPosition:e.backgroundPosition||"center"},attrs:{alt:e.altText,src:e.imgSrc||e.image}},"img",e.filterAttrs(e.attributes,!1),!1),e.filterAttrs(e.attributes,!0)))},Ot=[],Ut=m(Vt,Bt,Ot,!1,null,null,null,null);const Wt=Ut.exports,Mt={name:"Raw:Img",hideFromInsertMenu:!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",inputs:[{name:"image",bubble:!0,type:"file",allowedFileTypes:["jpeg","jpg","png","svg"],required:!0}],noWrap:!0,static:!0},Lt={name:"builder-custom-code",props:["replaceNodes","code"],data(){return{scriptsInserted:[],scriptsRun:[]}},mounted(){this.findAndRunScripts()},methods:{findAndRunScripts(){if(this.$refs.elem&&this.$refs.elem.getElementsByTagName&&typeof window<"u"){const t=this.$refs.elem.getElementsByTagName("script");for(let e=0;e<t.length;e++){const n=t[e];if(n.src){if(this.scriptsInserted.includes(n.src))continue;this.scriptsInserted.push(n.src);const o=document.createElement("script");o.async=!0,o.src=n.src,document.head.appendChild(o)}else if(!n.type||["text/javascript","application/javascript","application/ecmascript"].includes(n.type)){if(this.scriptsRun.includes(n.innerText))continue;try{this.scriptsRun.push(n.innerText),new Function(n.innerText)()}catch(o){console.warn("`CustomCode`: Error running script:",o)}}}}},_classStringToObject(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\s+/);for(const o of n)e[o]=!0;return e}}};var Nt=function(){var e=this,n=e._self._c;return n("div",{ref:"elem",class:e._classStringToObject("builder-custom-code"+(e.replaceNodes?" replace-nodes":"")),domProps:{innerHTML:e._s(e.code)}})},zt=[],Kt=m(Lt,Nt,zt,!1,null,null,null,null);const Ht=Kt.exports,Dt={name:"Custom Code",static:!0,requiredPermissions:["editCode"],inputs:[{name:"code",type:"html",required:!0,defaultValue:"<p>Hello there, I am custom HTML code!</p>",code:!0},{name:"replaceNodes",type:"boolean",helperText:"Preserve server rendered dom nodes",advanced:!0},{name:"scriptsClientOnly",type:"boolean",defaultValue:!1,helperText:"Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",advanced:!0}]},qt=()=>[{component:U,...Le},{component:L,...Ne},{component:Ht,...Dt},{component:jt,...Tt},{component:N,...ze},{component:z,...Ke},{component:Wt,...Mt},{component:D,...He},{component:te,...Xe},{component:ne,...bt},{component:oe,...kt}];function w({code:t,context:e,state:n,event:o,isExpression:r=!0}){if(t===""){console.warn("Skipping evaluation of empty code block.");return}const s={isEditing:g(),isBrowser:p(),isServer:!p()},l=r&&!(t.includes(";")||t.includes(" return ")||t.trim().startsWith("return "))?`return (${t});`:t;try{return new Function("builder","Builder","state","context","event",l)(s,s,n,e,o)}catch(a){console.warn(`Builder custom code error:
|
|
27
27
|
While Evaluating:
|
|
28
28
|
`,l,`
|
|
29
|
-
`,a)}}function re(){return!p()||g()?!1:Boolean(location.search.indexOf("builder.preview=")!==-1)}const $=[];function Gt(t,e){return $.push({component:t,...e}),console.warn("registerComponent is deprecated. Use the `customComponents` prop in RenderContent instead to provide your custom components to the builder SDK."),t}const se=({component:t,...e})=>({type:"builder.registerComponent",data:Xt(e)}),Jt=t=>typeof t=="function"?k(t):x(t),Xt=({inputs:t,...e})=>({...x(e),inputs:t==null?void 0:t.map(n=>Object.entries(n).reduce((o,[r,s])=>({...o,[r]:Jt(s)}),{}))});function Yt(){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 ie(){return Yt().replace(/-/g,"")}const ae="builderSessionId",Qt=async({canTrack:t})=>{if(!t)return;const e=await G({name:ae,canTrack:t});if(b(e))return e;{const n=Zt();return en({id:n,canTrack:t}),n}},Zt=()=>ie(),en=({id:t,canTrack:e})=>J({name:ae,value:t,canTrack:e}),le=()=>p()&&typeof localStorage<"u"?localStorage:void 0,tn=({key:t,canTrack:e})=>{var n;try{return e?(n=le())==null?void 0:n.getItem(t):void 0}catch(o){console.debug("[LocalStorage] GET error: ",o);return}},nn=({key:t,canTrack:e,value:n})=>{var o;try{e&&((o=le())==null||o.setItem(t,n))}catch(r){console.debug("[LocalStorage] SET error: ",r)}},ce="builderVisitorId",on=({canTrack:t})=>{if(!t)return;const e=tn({key:ce,canTrack:t});if(b(e))return e;{const n=rn();return sn({id:n,canTrack:t}),n}},rn=()=>ie(),sn=({id:t,canTrack:e})=>nn({key:ce,value:t,canTrack:e}),an=()=>{if(p()){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},ln=()=>typeof navigator=="object"&&navigator.userAgent||"",cn=()=>{const t=ln(),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),o=an();return{urlPath:o==null?void 0:o.pathname,host:(o==null?void 0:o.host)||(o==null?void 0:o.hostname),device:n?"tablet":e.any()?"mobile":"desktop"}},dn=async({canTrack:t})=>{if(!t)return{visitorId:void 0,sessionId:void 0};const e=await Qt({canTrack:t}),n=on({canTrack:t});return{sessionId:e,visitorId:n}},un=async({type:t,canTrack:e,apiKey:n,metadata:o,...r})=>({type:t,data:{...r,metadata:{url:location.href,...o},...await dn({canTrack:e}),userAttributes:cn(),ownerId:n}});async function R(t){if(!t.apiKey){console.error("[Builder.io]: Missing API key for track call. Please provide your API key.");return}if(!!t.canTrack&&!g()&&!!(p()||y==="reactNative"))return fetch("https://builder.io/api/v1/track",{method:"POST",body:JSON.stringify({events:[await un(t)]}),headers:{"content-type":"application/json"},mode:"cors"}).catch(e=>{console.error("Failed to track: ",e)})}const pn=t=>R({...t,canTrack:!0}),P={};function de(t,e){let n=P[t];if(n||(n=P[t]=[]),n.push(e),p()){const o={type:"builder.register",data:{type:t,info:e}};try{parent.postMessage(o,"*"),parent!==window&&window.postMessage(o,"*")}catch(r){console.debug("Could not postmessage",r)}}}const mn=()=>{de("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 j=!1;const hn=(t={})=>{var e,n;j||(j=!0,p()&&((e=window.parent)==null||e.postMessage({type:"builder.sdkInfo",data:{target:y,supportsPatchUpdates:!1,supportsAddBlockScoping:!0,supportsCustomBreakpoints:!0}},"*"),(n=window.parent)==null||n.postMessage({type:"builder.updateContent",data:{options:t}},"*"),window.addEventListener("message",({data:o})=>{var r,s;if(!!(o!=null&&o.type))switch(o.type){case"builder.evaluate":{const i=o.data.text,l=o.data.arguments||[],a=o.data.id,c=new Function(i);let d,h=null;try{d=c.apply(null,l)}catch(u){h=u}h?(r=window.parent)==null||r.postMessage({type:"builder.evaluateError",data:{id:a,error:h.message}},"*"):d&&typeof d.then=="function"?d.then(u=>{var f;(f=window.parent)==null||f.postMessage({type:"builder.evaluateResult",data:{id:a,result:u}},"*")}).catch(console.error):(s=window.parent)==null||s.postMessage({type:"builder.evaluateResult",data:{result:d,id:a}},"*");break}}})))};function V(t){return Math.round(t*1e3)/1e3}const fn=(t,e,n=!0)=>{if(!(t instanceof HTMLElement))return null;let o=n?t:t.parentElement;do{if(!o)return null;if(e(o))return o}while(o=o.parentElement);return null},gn=t=>fn(t,e=>{const n=e.getAttribute("builder-id")||e.id;return Boolean((n==null?void 0:n.indexOf("builder-"))===0)}),B=({event:t,target:e})=>{const n=e.getBoundingClientRect(),o=t.clientX-n.left,r=t.clientY-n.top,s=V(o/n.width),i=V(r/n.height);return{x:s,y:i}},bn=t=>{const e=t.target,n=e&&gn(e),o=(n==null?void 0:n.getAttribute("builder-id"))||(n==null?void 0:n.id);return{targetBuilderElement:o||void 0,metadata:{targetOffset:e?B({event:t,target:e}):void 0,builderTargetOffset:n?B({event:t,target:n}):void 0,builderElementIndex:n&&o?[].slice.call(document.getElementsByClassName(o)).indexOf(n):void 0}}},yn=({content:t,data:e,locale:n})=>{var s,i,l;const o={};(i=(s=t==null?void 0:t.data)==null?void 0:s.inputs)==null||i.forEach(a=>{var c;a.name&&a.defaultValue!==void 0&&((c=t==null?void 0:t.data)==null?void 0:c.state)&&t.data.state[a.name]===void 0&&(o[a.name]=a.defaultValue)});const r={...(l=t==null?void 0:t.data)==null?void 0:l.state,...e,...n?{locale:n}:{}};return{...o,...r}},vn=({content:t,data:e})=>t?{...t,data:{...t==null?void 0:t.data,...e},meta:t==null?void 0:t.meta}:void 0,_n=()=>Promise.resolve().then(()=>H).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",t),t}),xn=()=>Promise.resolve().then(()=>require("./render-styles.677a15af.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",t),t}),kn={name:"render-content",components:{RenderContentStyles:xn,RenderBlocks:_n},props:["content","data","canTrack","locale","customComponents","model","context","apiKey","includeRefs","apiVersion"],data(){return{forceReRenderCount:0,overrideContent:null,useContent:vn({content:this.content,data:this.data}),update:0,canTrackToUse:b(this.canTrack)?this.canTrack:!0,contentState:yn({content:this.content,data:this.data,locale:this.locale}),allRegisteredComponents:[...qt(),...$,...this.customComponents||[]].reduce((t,e)=>({...t,[e.name]:e}),{}),httpReqsData:{},clicked:!1,TARGET:y}},provide(){const t=this;return{[_.key]:{content:t.useContent,state:t.contentState,setState:t.setContextState,context:t.context||{},apiKey:t.apiKey,apiVersion:t.apiVersion,registeredComponents:t.allRegisteredComponents}}},mounted(){var t,e;if(this.apiKey||console.error("[Builder.io]: No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."),p()){if(g()&&(this.forceReRenderCount=this.forceReRenderCount+1,mn(),hn({...this.locale?{locale:this.locale}:{},...this.includeRefs?{includeRefs:this.includeRefs}:{}}),Object.values(this.allRegisteredComponents).forEach(n=>{var r;const o=se(n);(r=window.parent)==null||r.postMessage(o,"*")}),window.addEventListener("message",this.processMessage),window.addEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate)),this.useContent){const n=(t=this.useContent)==null?void 0:t.testVariationId,o=(e=this.useContent)==null?void 0:e.id;R({type:"impression",canTrack:this.canTrackToUse,contentId:o,apiKey:this.apiKey,variationId:n!==o?n:void 0})}if(re()){const n=new URL(location.href).searchParams,o=n.get("builder.preview"),r=n.get("apiKey")||n.get("builder.space");o===this.model&&r===this.apiKey&&I({model:this.model,apiKey:this.apiKey,apiVersion:this.apiVersion}).then(s=>{s&&this.mergeNewContent(s)})}this.evaluateJsCode(),this.runHttpRequests(),this.emitStateUpdate()}},watch:{onUpdateHook0:{handler(){this.content&&this.mergeNewContent(this.content)},immediate:!0},onUpdateHook1:{handler(){this.evaluateJsCode()},immediate:!0},onUpdateHook2:{handler(){this.runHttpRequests()},immediate:!0},onUpdateHook3:{handler(){this.emitStateUpdate()},immediate:!0}},unmounted(){p()&&(window.removeEventListener("message",this.processMessage),window.removeEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate))},computed:{onUpdateHook0(){return{0:this.content}},onUpdateHook1(){var t,e;return{0:(e=(t=this.useContent)==null?void 0:t.data)==null?void 0:e.jsCode,1:this.contentState}},onUpdateHook2(){var t,e;return{0:(e=(t=this.useContent)==null?void 0:t.data)==null?void 0:e.httpRequests}},onUpdateHook3(){return{0:this.contentState}}},methods:{mergeNewContent(t){var e,n,o,r,s;this.useContent={...this.useContent,...t,data:{...(e=this.useContent)==null?void 0:e.data,...t==null?void 0:t.data},meta:{...(n=this.useContent)==null?void 0:n.meta,...t==null?void 0:t.meta,breakpoints:((o=t==null?void 0:t.meta)==null?void 0:o.breakpoints)||((s=(r=this.useContent)==null?void 0:r.meta)==null?void 0:s.breakpoints)}}},setBreakpoints(t){var e;this.useContent={...this.useContent,meta:{...(e=this.useContent)==null?void 0:e.meta,breakpoints:t}}},setContextState(t){this.contentState=t},processMessage(t){var n;const{data:e}=t;if(e)switch(e.type){case"builder.configureSdk":{const o=e.data,{breakpoints:r,contentId:s}=o;if(!s||s!==((n=this.useContent)==null?void 0:n.id))return;r&&this.setBreakpoints(r),this.forceReRenderCount=this.forceReRenderCount+1;break}case"builder.contentUpdate":{const o=e.data,r=o.key||o.alias||o.entry||o.modelName,s=o.data;r===this.model&&(this.mergeNewContent(s),this.forceReRenderCount=this.forceReRenderCount+1);break}}},evaluateJsCode(){var e,n;const t=(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.jsCode;t&&w({code:t,context:this.context||{},state:this.contentState})},onClick(t){var e,n;if(this.useContent){const o=(e=this.useContent)==null?void 0:e.testVariationId,r=(n=this.useContent)==null?void 0:n.id;R({type:"click",canTrack:this.canTrackToUse,contentId:r,apiKey:this.apiKey,variationId:o!==r?o:void 0,...bn(t),unique:!this.clicked})}this.clicked||(this.clicked=!0)},evalExpression(t){return t.replace(/{{([^}]+)}}/g,(e,n)=>w({code:n,context:this.context||{},state:this.contentState}))},handleRequest({url:t,key:e}){q(t).then(n=>n.json()).then(n=>{const o={...this.contentState,[e]:n};this.setContextState(o)}).catch(n=>{console.log("error fetching dynamic data",t,n)})},runHttpRequests(){var e,n,o;const t=(o=(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.httpRequests)!=null?o:{};Object.entries(t).forEach(([r,s])=>{if(s&&(!this.httpReqsData[r]||g())){const i=this.evalExpression(s);this.handleRequest({url:i,key:r})}})},emitStateUpdate(){g()&&window.dispatchEvent(new CustomEvent("builder:component:stateChange",{detail:{state:this.contentState,ref:{name:this.model}}}))}}};var Sn=function(){var o,r,s,i,l,a,c,d;var e=this,n=e._self._c;return e.useContent?n("div",{ref:"elementRef",attrs:{"builder-content-id":(o=e.useContent)==null?void 0:o.id,"builder-model":e.model},on:{click:function(h){return e.onClick(h)}}},[e.TARGET!=="reactNative"?[n("render-content-styles",{attrs:{contentId:(r=e.useContent)==null?void 0:r.id,cssCode:(i=(s=e.useContent)==null?void 0:s.data)==null?void 0:i.cssCode,customFonts:(a=(l=e.useContent)==null?void 0:l.data)==null?void 0:a.customFonts}})]:e._e(),n("render-blocks",{key:e.forceReRenderCount,attrs:{blocks:(d=(c=e.useContent)==null?void 0:c.data)==null?void 0:d.blocks}})],2):e._e()},Cn=[],wn=m(kn,Sn,Cn,!1,null,null,null,null);const ue=wn.exports,Rn=Object.freeze(Object.defineProperty({__proto__:null,default:ue},Symbol.toStringTag,{value:"Module"})),O={};function Tn(t){if(p()){Object.assign(O,t);const e={type:"builder.settingsChange",data:O};parent.postMessage(e,"*")}}exports.BuilderContext=_;exports.Button=U;exports.Columns=L;exports.Fragment=N;exports.Image=z;exports.Section=D;exports.Symbol=te;exports.TARGET=y;exports.Text=ne;exports.Video=oe;exports.checkIsDefined=b;exports.components=$;exports.convertSearchParamsToQueryObject=Y;exports.createRegisterComponentMessage=se;exports.evaluate=w;exports.fastClone=x;exports.getAllContent=ee;exports.getBuilderSearchParams=Q;exports.getBuilderSearchParamsFromWindow=Z;exports.getContent=I;exports.getMaxWidthQueryForSize=ge;exports.getSizesForBreakpoints=M;exports.isEditing=g;exports.isPreviewing=re;exports.normalizeComponent=m;exports.normalizeSearchParams=T;exports.register=de;exports.registerComponent=Gt;exports.renderBlocks=K;exports.renderContent=ue;exports.setEditorSettings=Tn;exports.track=pn;
|
|
29
|
+
`,a)}}function re(){return!p()||g()?!1:Boolean(location.search.indexOf("builder.preview=")!==-1)}const $=[];function Gt(t,e){return $.push({component:t,...e}),console.warn("registerComponent is deprecated. Use the `customComponents` prop in RenderContent instead to provide your custom components to the builder SDK."),t}const se=({component:t,...e})=>({type:"builder.registerComponent",data:Xt(e)}),Jt=t=>typeof t=="function"?k(t):x(t),Xt=({inputs:t,...e})=>({...x(e),inputs:t==null?void 0:t.map(n=>Object.entries(n).reduce((o,[r,s])=>({...o,[r]:Jt(s)}),{}))});function Yt(){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 ie(){return Yt().replace(/-/g,"")}const ae="builderSessionId",Qt=async({canTrack:t})=>{if(!t)return;const e=await G({name:ae,canTrack:t});if(b(e))return e;{const n=Zt();return en({id:n,canTrack:t}),n}},Zt=()=>ie(),en=({id:t,canTrack:e})=>J({name:ae,value:t,canTrack:e}),le=()=>p()&&typeof localStorage<"u"?localStorage:void 0,tn=({key:t,canTrack:e})=>{var n;try{return e?(n=le())==null?void 0:n.getItem(t):void 0}catch(o){console.debug("[LocalStorage] GET error: ",o);return}},nn=({key:t,canTrack:e,value:n})=>{var o;try{e&&((o=le())==null||o.setItem(t,n))}catch(r){console.debug("[LocalStorage] SET error: ",r)}},ce="builderVisitorId",on=({canTrack:t})=>{if(!t)return;const e=tn({key:ce,canTrack:t});if(b(e))return e;{const n=rn();return sn({id:n,canTrack:t}),n}},rn=()=>ie(),sn=({id:t,canTrack:e})=>nn({key:ce,value:t,canTrack:e}),an=()=>{if(p()){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},ln=()=>typeof navigator=="object"&&navigator.userAgent||"",cn=()=>{const t=ln(),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),o=an();return{urlPath:o==null?void 0:o.pathname,host:(o==null?void 0:o.host)||(o==null?void 0:o.hostname),device:n?"tablet":e.any()?"mobile":"desktop"}},dn=async({canTrack:t})=>{if(!t)return{visitorId:void 0,sessionId:void 0};const e=await Qt({canTrack:t}),n=on({canTrack:t});return{sessionId:e,visitorId:n}},un=async({type:t,canTrack:e,apiKey:n,metadata:o,...r})=>({type:t,data:{...r,metadata:{url:location.href,...o},...await dn({canTrack:e}),userAttributes:cn(),ownerId:n}});async function R(t){if(!t.apiKey){console.error("[Builder.io]: Missing API key for track call. Please provide your API key.");return}if(!!t.canTrack&&!g()&&!!(p()||y==="reactNative"))return fetch("https://builder.io/api/v1/track",{method:"POST",body:JSON.stringify({events:[await un(t)]}),headers:{"content-type":"application/json"},mode:"cors"}).catch(e=>{console.error("Failed to track: ",e)})}const pn=t=>R({...t,canTrack:!0}),P={};function de(t,e){let n=P[t];if(n||(n=P[t]=[]),n.push(e),p()){const o={type:"builder.register",data:{type:t,info:e}};try{parent.postMessage(o,"*"),parent!==window&&window.postMessage(o,"*")}catch(r){console.debug("Could not postmessage",r)}}}const mn=()=>{de("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 j=!1;const hn=(t={})=>{var e,n;j||(j=!0,p()&&((e=window.parent)==null||e.postMessage({type:"builder.sdkInfo",data:{target:y,supportsPatchUpdates:!1,supportsAddBlockScoping:!0,supportsCustomBreakpoints:!0}},"*"),(n=window.parent)==null||n.postMessage({type:"builder.updateContent",data:{options:t}},"*"),window.addEventListener("message",({data:o})=>{var r,s;if(!!(o!=null&&o.type))switch(o.type){case"builder.evaluate":{const i=o.data.text,l=o.data.arguments||[],a=o.data.id,c=new Function(i);let d,h=null;try{d=c.apply(null,l)}catch(u){h=u}h?(r=window.parent)==null||r.postMessage({type:"builder.evaluateError",data:{id:a,error:h.message}},"*"):d&&typeof d.then=="function"?d.then(u=>{var f;(f=window.parent)==null||f.postMessage({type:"builder.evaluateResult",data:{id:a,result:u}},"*")}).catch(console.error):(s=window.parent)==null||s.postMessage({type:"builder.evaluateResult",data:{result:d,id:a}},"*");break}}})))};function V(t){return Math.round(t*1e3)/1e3}const fn=(t,e,n=!0)=>{if(!(t instanceof HTMLElement))return null;let o=n?t:t.parentElement;do{if(!o)return null;if(e(o))return o}while(o=o.parentElement);return null},gn=t=>fn(t,e=>{const n=e.getAttribute("builder-id")||e.id;return Boolean((n==null?void 0:n.indexOf("builder-"))===0)}),B=({event:t,target:e})=>{const n=e.getBoundingClientRect(),o=t.clientX-n.left,r=t.clientY-n.top,s=V(o/n.width),i=V(r/n.height);return{x:s,y:i}},bn=t=>{const e=t.target,n=e&&gn(e),o=(n==null?void 0:n.getAttribute("builder-id"))||(n==null?void 0:n.id);return{targetBuilderElement:o||void 0,metadata:{targetOffset:e?B({event:t,target:e}):void 0,builderTargetOffset:n?B({event:t,target:n}):void 0,builderElementIndex:n&&o?[].slice.call(document.getElementsByClassName(o)).indexOf(n):void 0}}},yn=({content:t,data:e,locale:n})=>{var s,i,l;const o={};(i=(s=t==null?void 0:t.data)==null?void 0:s.inputs)==null||i.forEach(a=>{var c;a.name&&a.defaultValue!==void 0&&((c=t==null?void 0:t.data)==null?void 0:c.state)&&t.data.state[a.name]===void 0&&(o[a.name]=a.defaultValue)});const r={...(l=t==null?void 0:t.data)==null?void 0:l.state,...e,...n?{locale:n}:{}};return{...o,...r}},vn=({content:t,data:e})=>t?{...t,data:{...t==null?void 0:t.data,...e},meta:t==null?void 0:t.meta}:void 0,_n=()=>Promise.resolve().then(()=>H).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",t),t}),xn=()=>Promise.resolve().then(()=>require("./render-styles.3df98784.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",t),t}),kn={name:"render-content",components:{RenderContentStyles:xn,RenderBlocks:_n},props:["content","data","canTrack","locale","customComponents","model","context","apiKey","includeRefs","apiVersion"],data(){return{forceReRenderCount:0,overrideContent:null,useContent:vn({content:this.content,data:this.data}),update:0,canTrackToUse:b(this.canTrack)?this.canTrack:!0,contentState:yn({content:this.content,data:this.data,locale:this.locale}),allRegisteredComponents:[...qt(),...$,...this.customComponents||[]].reduce((t,e)=>({...t,[e.name]:e}),{}),httpReqsData:{},clicked:!1,TARGET:y}},provide(){const t=this;return{[_.key]:{content:t.useContent,state:t.contentState,setState:t.setContextState,context:t.context||{},apiKey:t.apiKey,apiVersion:t.apiVersion,registeredComponents:t.allRegisteredComponents}}},mounted(){var t,e;if(this.apiKey||console.error("[Builder.io]: No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."),p()){if(g()&&(this.forceReRenderCount=this.forceReRenderCount+1,mn(),hn({...this.locale?{locale:this.locale}:{},...this.includeRefs?{includeRefs:this.includeRefs}:{}}),Object.values(this.allRegisteredComponents).forEach(n=>{var r;const o=se(n);(r=window.parent)==null||r.postMessage(o,"*")}),window.addEventListener("message",this.processMessage),window.addEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate)),this.useContent){const n=(t=this.useContent)==null?void 0:t.testVariationId,o=(e=this.useContent)==null?void 0:e.id;R({type:"impression",canTrack:this.canTrackToUse,contentId:o,apiKey:this.apiKey,variationId:n!==o?n:void 0})}if(re()){const n=new URL(location.href).searchParams,o=n.get("builder.preview"),r=n.get("apiKey")||n.get("builder.space");o===this.model&&r===this.apiKey&&I({model:this.model,apiKey:this.apiKey,apiVersion:this.apiVersion}).then(s=>{s&&this.mergeNewContent(s)})}this.evaluateJsCode(),this.runHttpRequests(),this.emitStateUpdate()}},watch:{onUpdateHook0:{handler(){this.content&&this.mergeNewContent(this.content)},immediate:!0},onUpdateHook1:{handler(){this.evaluateJsCode()},immediate:!0},onUpdateHook2:{handler(){this.runHttpRequests()},immediate:!0},onUpdateHook3:{handler(){this.emitStateUpdate()},immediate:!0}},unmounted(){p()&&(window.removeEventListener("message",this.processMessage),window.removeEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate))},computed:{onUpdateHook0(){return{0:this.content}},onUpdateHook1(){var t,e;return{0:(e=(t=this.useContent)==null?void 0:t.data)==null?void 0:e.jsCode,1:this.contentState}},onUpdateHook2(){var t,e;return{0:(e=(t=this.useContent)==null?void 0:t.data)==null?void 0:e.httpRequests}},onUpdateHook3(){return{0:this.contentState}}},methods:{mergeNewContent(t){var e,n,o,r,s;this.useContent={...this.useContent,...t,data:{...(e=this.useContent)==null?void 0:e.data,...t==null?void 0:t.data},meta:{...(n=this.useContent)==null?void 0:n.meta,...t==null?void 0:t.meta,breakpoints:((o=t==null?void 0:t.meta)==null?void 0:o.breakpoints)||((s=(r=this.useContent)==null?void 0:r.meta)==null?void 0:s.breakpoints)}}},setBreakpoints(t){var e;this.useContent={...this.useContent,meta:{...(e=this.useContent)==null?void 0:e.meta,breakpoints:t}}},setContextState(t){this.contentState=t},processMessage(t){var n;const{data:e}=t;if(e)switch(e.type){case"builder.configureSdk":{const o=e.data,{breakpoints:r,contentId:s}=o;if(!s||s!==((n=this.useContent)==null?void 0:n.id))return;r&&this.setBreakpoints(r),this.forceReRenderCount=this.forceReRenderCount+1;break}case"builder.contentUpdate":{const o=e.data,r=o.key||o.alias||o.entry||o.modelName,s=o.data;r===this.model&&(this.mergeNewContent(s),this.forceReRenderCount=this.forceReRenderCount+1);break}}},evaluateJsCode(){var e,n;const t=(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.jsCode;t&&w({code:t,context:this.context||{},state:this.contentState})},onClick(t){var e,n;if(this.useContent){const o=(e=this.useContent)==null?void 0:e.testVariationId,r=(n=this.useContent)==null?void 0:n.id;R({type:"click",canTrack:this.canTrackToUse,contentId:r,apiKey:this.apiKey,variationId:o!==r?o:void 0,...bn(t),unique:!this.clicked})}this.clicked||(this.clicked=!0)},evalExpression(t){return t.replace(/{{([^}]+)}}/g,(e,n)=>w({code:n,context:this.context||{},state:this.contentState}))},handleRequest({url:t,key:e}){q(t).then(n=>n.json()).then(n=>{const o={...this.contentState,[e]:n};this.setContextState(o)}).catch(n=>{console.log("error fetching dynamic data",t,n)})},runHttpRequests(){var e,n,o;const t=(o=(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.httpRequests)!=null?o:{};Object.entries(t).forEach(([r,s])=>{if(s&&(!this.httpReqsData[r]||g())){const i=this.evalExpression(s);this.handleRequest({url:i,key:r})}})},emitStateUpdate(){g()&&window.dispatchEvent(new CustomEvent("builder:component:stateChange",{detail:{state:this.contentState,ref:{name:this.model}}}))}}};var Sn=function(){var o,r,s,i,l,a,c,d;var e=this,n=e._self._c;return e.useContent?n("div",{ref:"elementRef",attrs:{"builder-content-id":(o=e.useContent)==null?void 0:o.id,"builder-model":e.model},on:{click:function(h){return e.onClick(h)}}},[e.TARGET!=="reactNative"?[n("render-content-styles",{attrs:{contentId:(r=e.useContent)==null?void 0:r.id,cssCode:(i=(s=e.useContent)==null?void 0:s.data)==null?void 0:i.cssCode,customFonts:(a=(l=e.useContent)==null?void 0:l.data)==null?void 0:a.customFonts}})]:e._e(),n("render-blocks",{key:e.forceReRenderCount,attrs:{blocks:(d=(c=e.useContent)==null?void 0:c.data)==null?void 0:d.blocks}})],2):e._e()},Cn=[],wn=m(kn,Sn,Cn,!1,null,null,null,null);const ue=wn.exports,Rn=Object.freeze(Object.defineProperty({__proto__:null,default:ue},Symbol.toStringTag,{value:"Module"})),O={};function Tn(t){if(p()){Object.assign(O,t);const e={type:"builder.settingsChange",data:O};parent.postMessage(e,"*")}}exports.BuilderContext=_;exports.Button=U;exports.Columns=L;exports.Fragment=N;exports.Image=z;exports.Section=D;exports.Symbol=te;exports.TARGET=y;exports.Text=ne;exports.Video=oe;exports.checkIsDefined=b;exports.components=$;exports.convertSearchParamsToQueryObject=Y;exports.createRegisterComponentMessage=se;exports.evaluate=w;exports.fastClone=x;exports.getAllContent=ee;exports.getBuilderSearchParams=Q;exports.getBuilderSearchParamsFromWindow=Z;exports.getContent=I;exports.getMaxWidthQueryForSize=ge;exports.getSizesForBreakpoints=M;exports.isEditing=g;exports.isPreviewing=re;exports.normalizeComponent=m;exports.normalizeSearchParams=T;exports.register=de;exports.registerComponent=Gt;exports.renderBlocks=K;exports.renderContent=ue;exports.setEditorSettings=Tn;exports.track=pn;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.9e0fbaa1.cjs"),i=require("./css.a4a781f2.cjs"),d=t=>`v-on:${t.toLowerCase()}`,p=(t,e)=>n=>c.evaluate({code:t,context:e.context,state:e.state,event:n,isExpression:!1});function m(t){var r;const e={},n=(r=t.block.actions)!=null?r:{};for(const o in n){if(!n.hasOwnProperty(o))continue;const s=n[o];e[d(o)]=p(s,t)}return e}function h(t){var e;return{...(e=t.component)==null?void 0:e.options,...t.options,builderBlock:t}}function k(t){const e={};if(typeof t!="string")return e;const n=t.trim().split(/\\s+/);for(const r of n)e[r]=!0;return e}function f(t){return t.class=k(t.class),t}function b(t){var n;const e={...t.properties,"builder-id":t.id,style:x(t.style),class:[t.id,"builder-block",t.class,(n=t.properties)==null?void 0:n.class].filter(Boolean).join(" ")};return f(e)}function x(t){if(!!t)switch(c.TARGET){case"svelte":case"vue2":case"vue3":case"solid":return i.convertStyleMapToCSSArray(t).join(" ");case"qwik":case"reactNative":case"react":return t}}function y(t){return t.tagName||"div"}const g=["area","base","br","col","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],v=t=>typeof t=="string"&&g.includes(t.toLowerCase()),B=({block:t,context:e})=>{var o;const n=(o=i.getProcessedBlock({block:t,state:e.state,context:e.context,shouldEvaluateBindings:!1}).component)==null?void 0:o.name;if(!n)return null;const r=e.registeredComponents[n];if(r)return r;console.warn(`
|
|
2
2
|
Could not find a registered component named "${n}".
|
|
3
|
-
If you registered it, is the file that registered it imported by the file that needs to render it?`)},C=({block:t,context:e})=>{const{repeat:n,...r}=t;if(!(n!=null&&n.collection))return;const o=c.evaluate({code:n.collection,state:e.state,context:e.context});if(!Array.isArray(o))return;const s=n.collection.split(".").pop(),a=n.itemName||(s?s+"Item":"item");return o.map((l,u)=>({context:{...e,state:{...e.state,$index:u,$item:l,[a]:l,[`$${a}Index`]:u}},block:r}))},_=()=>Promise.resolve().then(()=>require("./block-styles.
|
|
3
|
+
If you registered it, is the file that registered it imported by the file that needs to render it?`)},C=({block:t,context:e})=>{const{repeat:n,...r}=t;if(!(n!=null&&n.collection))return;const o=c.evaluate({code:n.collection,state:e.state,context:e.context});if(!Array.isArray(o))return;const s=n.collection.split(".").pop(),a=n.itemName||(s?s+"Item":"item");return o.map((l,u)=>({context:{...e,state:{...e.state,$index:u,$item:l,[a]:l,[`$${a}Index`]:u}},block:r}))},_=()=>Promise.resolve().then(()=>require("./block-styles.a33b589b.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",t),t}),S=()=>Promise.resolve().then(()=>require("./render-repeated-block.a24ffa4d.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderRepeatedBlock at ./render-repeated-block.vue",t),t}),w=()=>Promise.resolve().then(()=>require("./render-component.b187cca7.cjs")).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderComponent at ./render-component.vue",t),t}),P={name:"render-block",components:{RenderComponent:w,RenderRepeatedBlock:S,BlockStyles:_},props:["block","context"],data(){return{component:B({block:this.block,context:this.context}),repeatItemData:C({block:this.block,context:this.context}),isEmptyHtmlElement:v}},computed:{tag(){return y(this.useBlock)},useBlock(){return this.repeatItemData?this.block:i.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!0})},canShowBlock(){return c.checkIsDefined(this.useBlock.hide)?!this.useBlock.hide:c.checkIsDefined(this.useBlock.show)?this.useBlock.show:!0},proxyState(){return typeof Proxy>"u"?(console.error("no Proxy available in this environment, cannot proxy state."),this.context.state):new Proxy(this.context.state,{set:(e,n,r)=>{var o,s;return e[n]=r,(s=(o=this.context).setState)==null||s.call(o,e),!0}})},actions(){return m({block:this.useBlock,state:this.proxyState,context:this.context.context})},attributes(){return{...b(this.useBlock)}},renderComponentProps(){var t,e,n;return{blockChildren:(t=this.useBlock.children)!=null?t:[],componentRef:(e=this.component)==null?void 0:e.component,componentOptions:{...h(this.useBlock),...(n=this.component)!=null&&n.noWrap?{attributes:{...this.attributes,...this.actions}}:{}},context:this.childrenContext}},childrenWithoutParentComponent(){var e,n;return!((e=this.component)!=null&&e.component)&&!this.repeatItemData?(n=this.useBlock.children)!=null?n:[]:[]},childrenContext(){const t=()=>({});return{apiKey:this.context.apiKey,state:this.context.state,content:this.context.content,context:this.context.context,setState:this.context.setState,registeredComponents:this.context.registeredComponents,inheritedStyles:t()}}},methods:{stripVOn:function(e={}){return Object.keys(e).reduce((n,r)=>({...n,[r.replace("v-on:","")]:e[r]}),{})}}};var E=function(){var r;var e=this,n=e._self._c;return!Boolean(!((r=e.component)!=null&&r.noWrap))&&e.canShowBlock?n("render-component",e._b({},"render-component",e.renderComponentProps,!1)):e.isEmptyHtmlElement(e.tag)&&e.canShowBlock?n(e.tag,e._g(e._b({tag:"component"},"component",e.attributes,!1),e.stripVOn(e.actions))):!e.isEmptyHtmlElement(e.tag)&&e.repeatItemData&&e.canShowBlock?n("div",{staticClass:"vue2-root-element-workaround"},e._l(e.repeatItemData,function(o,s){return n("render-repeated-block",{key:s,attrs:{repeatContext:o.context,block:o.block}})}),1):e.canShowBlock?n(e.tag,e._g(e._b({tag:"component"},"component",e.attributes,!1),e.stripVOn(e.actions)),[n("render-component",e._b({},"render-component",e.renderComponentProps,!1)),e._l(e.childrenWithoutParentComponent,function(o,s){return n("render-block",{key:"render-block-"+o.id,attrs:{block:o,context:e.childrenContext}})}),e._l(e.childrenWithoutParentComponent,function(o,s){return n("block-styles",{key:"block-style-"+o.id,attrs:{block:o,context:e.childrenContext}})})],2):e._e()},R=[],I=c.normalizeComponent(P,E,R,!1,null,null,null,null);const O=I.exports;exports.default=O;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { e as u, T as m, c as l, n as d } from "./index.
|
|
2
|
-
import { a as h, g as p } from "./css.
|
|
1
|
+
import { e as u, T as m, c as l, n as d } from "./index.3826ad2c.js";
|
|
2
|
+
import { a as h, g as p } from "./css.9a515005.js";
|
|
3
3
|
const k = (e) => `v-on:${e.toLowerCase()}`, f = (e, t) => (n) => u({
|
|
4
4
|
code: e,
|
|
5
5
|
context: t.context,
|
|
@@ -128,17 +128,17 @@ const _ = [
|
|
|
128
128
|
},
|
|
129
129
|
block: r
|
|
130
130
|
}));
|
|
131
|
-
}, P = () => import("./block-styles.
|
|
131
|
+
}, P = () => import("./block-styles.e4fa133a.js").then((e) => e.default).catch((e) => {
|
|
132
132
|
throw console.error(
|
|
133
133
|
"Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",
|
|
134
134
|
e
|
|
135
135
|
), e;
|
|
136
|
-
}), R = () => import("./render-repeated-block.
|
|
136
|
+
}), R = () => import("./render-repeated-block.43d7ad78.js").then((e) => e.default).catch((e) => {
|
|
137
137
|
throw console.error(
|
|
138
138
|
"Error while attempting to dynamically import component RenderRepeatedBlock at ./render-repeated-block.vue",
|
|
139
139
|
e
|
|
140
140
|
), e;
|
|
141
|
-
}), I = () => import("./render-component.
|
|
141
|
+
}), I = () => import("./render-component.d54274f2.js").then((e) => e.default).catch((e) => {
|
|
142
142
|
throw console.error(
|
|
143
143
|
"Error while attempting to dynamically import component RenderComponent at ./render-component.vue",
|
|
144
144
|
e
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.9e0fbaa1.cjs"),l=()=>Promise.resolve().then(()=>require("./block-styles.a33b589b.cjs")).then(n=>n.default).catch(n=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",n),n}),s=()=>Promise.resolve().then(()=>require("./render-block.65396344.cjs")).then(n=>n.default).catch(n=>{throw console.error("Error while attempting to dynamically import component RenderBlock at ./render-block.vue",n),n}),i={name:"render-component",components:{RenderBlock:s,BlockStyles:l},props:["componentRef","componentOptions","blockChildren","context"]};var a=function(){var e=this,t=e._self._c;return e.componentRef?t(e.componentRef,e._b({tag:"component"},"component",e.componentOptions,!1),[e._l(e.blockChildren,function(o,r){return t("render-block",{key:"render-block-"+o.id,attrs:{block:o,context:e.context}})}),e._l(e.blockChildren,function(o,r){return t("block-styles",{key:"block-style-"+o.id,attrs:{block:o,context:e.context}})})],2):e._e()},m=[],d=c.normalizeComponent(i,a,m,!1,null,null,null,null);const p=d.exports;exports.default=p;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { n as c } from "./index.
|
|
2
|
-
const l = () => import("./block-styles.
|
|
1
|
+
import { n as c } from "./index.3826ad2c.js";
|
|
2
|
+
const l = () => import("./block-styles.e4fa133a.js").then((o) => o.default).catch((o) => {
|
|
3
3
|
throw console.error(
|
|
4
4
|
"Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",
|
|
5
5
|
o
|
|
6
6
|
), o;
|
|
7
|
-
}), s = () => import("./render-block.
|
|
7
|
+
}), s = () => import("./render-block.8857ae34.js").then((o) => o.default).catch((o) => {
|
|
8
8
|
throw console.error(
|
|
9
9
|
"Error while attempting to dynamically import component RenderBlock at ./render-block.vue",
|
|
10
10
|
o
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.9e0fbaa1.cjs"),s={name:"render-inlined-styles",props:["styles"],data(){return{TARGET:n.TARGET}},computed:{injectedStyleScript(){return`<${this.tag}>${this.styles}</${this.tag}>`},tag(){return"style"}}};var r=function(){var e=this,t=e._self._c;return e.TARGET==="svelte"||e.TARGET==="qwik"?t(e.tag,{tag:"component",domProps:{innerHTML:e._s(e.styles)}}):t(e.tag,{tag:"component"},[e._v(e._s(e.styles))])},l=[],a=n.normalizeComponent(s,r,l,!1,null,null,null,null);const o=a.exports;exports.default=o;
|
package/packages/_vue2/dist/{render-repeated-block.84bf8874.js → render-repeated-block.43d7ad78.js}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { B as o, n as r } from "./index.
|
|
2
|
-
const a = () => import("./render-block.
|
|
1
|
+
import { B as o, n as r } from "./index.3826ad2c.js";
|
|
2
|
+
const a = () => import("./render-block.8857ae34.js").then((e) => e.default).catch((e) => {
|
|
3
3
|
throw console.error(
|
|
4
4
|
"Error while attempting to dynamically import component RenderBlock at ./render-block.vue",
|
|
5
5
|
e
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index.9e0fbaa1.cjs"),o=()=>Promise.resolve().then(()=>require("./render-block.65396344.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlock at ./render-block.vue",e),e}),a={name:"render-repeated-block",components:{RenderBlock:o},props:["block","repeatContext"],provide(){const e=this;return{[n.BuilderContext.key]:{content:e.repeatContext.content,state:e.repeatContext.state,setState:e.repeatContext.setState,context:e.repeatContext.context,apiKey:e.repeatContext.apiKey,registeredComponents:e.repeatContext.registeredComponents,inheritedStyles:e.repeatContext.inheritedStyles}}}};var c=function(){var t=this,r=t._self._c;return r("render-block",{attrs:{block:t.block,context:t.repeatContext}})},s=[],l=n.normalizeComponent(a,c,s,!1,null,null,null,null);const i=l.exports;exports.default=i;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as c } from "./index.
|
|
1
|
+
import { n as c } from "./index.3826ad2c.js";
|
|
2
2
|
const f = (e) => {
|
|
3
3
|
var a, o;
|
|
4
4
|
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), r = t.split(",")[0], i = (o = e.fileUrl) != null ? o : (a = e == null ? void 0 : e.files) == null ? void 0 : a.regular;
|
|
@@ -31,7 +31,7 @@ font-weight: ${n};
|
|
|
31
31
|
}, u = ({
|
|
32
32
|
cssCode: e,
|
|
33
33
|
contentId: t
|
|
34
|
-
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", m = () => import("./render-inlined-styles.
|
|
34
|
+
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", m = () => import("./render-inlined-styles.f560a740.js").then((e) => e.default).catch((e) => {
|
|
35
35
|
throw console.error(
|
|
36
36
|
"Error while attempting to dynamically import component RenderInlinedStyles at ../../render-inlined-styles.vue",
|
|
37
37
|
e
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.9e0fbaa1.cjs"),f=e=>{var a,o;const t=e.family+(e.kind&&!e.kind.includes("#")?", "+e.kind:""),r=t.split(",")[0],i=(o=e.fileUrl)!=null?o:(a=e==null?void 0:e.files)==null?void 0:a.regular;let l="";if(i&&t&&r&&(l+=`
|
|
2
2
|
@font-face {
|
|
3
3
|
font-family: "${t}";
|
|
4
4
|
src: local("${r}"), url('${i}') format('woff2');
|
|
@@ -12,9 +12,9 @@ src: url('${s}') format('woff2');
|
|
|
12
12
|
font-display: fallback;
|
|
13
13
|
font-weight: ${n};
|
|
14
14
|
}
|
|
15
|
-
`.trim())}return l},
|
|
15
|
+
`.trim())}return l},d=({customFonts:e})=>{var t;return((t=e==null?void 0:e.map(r=>f(r)))==null?void 0:t.join(" "))||""},u=({cssCode:e,contentId:t})=>e?t?(e==null?void 0:e.replace(/&/g,`div[builder-content-id="${t}"]`))||"":e:"",m=()=>Promise.resolve().then(()=>require("./render-inlined-styles.aaa60ee3.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderInlinedStyles at ../../render-inlined-styles.vue",e),e}),h={name:"render-content-styles",components:{RenderInlinedStyles:m},props:["cssCode","contentId","customFonts"],data(){return{injectedStyles:`
|
|
16
16
|
${u({cssCode:this.cssCode,contentId:this.contentId})}
|
|
17
|
-
${
|
|
17
|
+
${d({customFonts:this.customFonts})}
|
|
18
18
|
|
|
19
19
|
.builder-text > p:first-of-type, .builder-text > .builder-paragraph:first-of-type {
|
|
20
20
|
margin: 0;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./index.
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./index.9e0fbaa1.cjs");exports.Button=e.Button;exports.Columns=e.Columns;exports.Fragment=e.Fragment;exports.Image=e.Image;exports.RenderBlocks=e.renderBlocks;exports.RenderContent=e.renderContent;exports.Section=e.Section;exports.Symbol=e.Symbol;exports.Text=e.Text;exports.Video=e.Video;exports.components=e.components;exports.convertSearchParamsToQueryObject=e.convertSearchParamsToQueryObject;exports.createRegisterComponentMessage=e.createRegisterComponentMessage;exports.getAllContent=e.getAllContent;exports.getBuilderSearchParams=e.getBuilderSearchParams;exports.getBuilderSearchParamsFromWindow=e.getBuilderSearchParamsFromWindow;exports.getContent=e.getContent;exports.isEditing=e.isEditing;exports.isPreviewing=e.isPreviewing;exports.normalizeSearchParams=e.normalizeSearchParams;exports.register=e.register;exports.registerComponent=e.registerComponent;exports.setEditorSettings=e.setEditorSettings;exports.track=e.track;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { b as s, C as t, F as r, I as n, r as o, d as i, S as m, h as g, i as c, V as d, l, v as S, o as C, u, w as h, x as p, q as P, j as B, k as b, y as k, p as v, m as w, s as x, t as y } from "./index.
|
|
1
|
+
import { b as s, C as t, F as r, I as n, r as o, d as i, S as m, h as g, i as c, V as d, l, v as S, o as C, u, w as h, x as p, q as P, j as B, k as b, y as k, p as v, m as w, s as x, t as y } from "./index.3826ad2c.js";
|
|
2
2
|
export {
|
|
3
3
|
s as Button,
|
|
4
4
|
t as Columns,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.button-2fnk003dqad[data-v-3e6fa42c]{all:unset}.div-t9spj7joih[data-v-
|
|
1
|
+
.button-2fnk003dqad[data-v-3e6fa42c]{all:unset}.div-t9spj7joih[data-v-bcf8543c]{display:flex;line-height:normal}.div-t9spj7joih-2[data-v-bcf8543c]{display:flex;flex-direction:column;align-items:stretch}.img-1pl23ac79ld[data-v-d14c6f82]{opacity:1;transition:opacity .2s ease-in-out}.div-1pl23ac79ld[data-v-d14c6f82]{width:100%;pointer-events:none;font-size:0}.div-1pl23ac79ld-2[data-v-d14c6f82]{display:flex;flex-direction:column;align-items:stretch;position:absolute;top:0;left:0;width:100%;height:100%}.div-21azgz5avex[data-v-7d4553c5]{display:flex;flex-direction:column;align-items:stretch}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineAsyncComponent as p, resolveComponent as k, openBlock as y, createBlock as B, createCommentVNode as S } from "vue";
|
|
2
|
-
import { T as f, c as i, g as _, a as d, _ as g } from "./index.
|
|
3
|
-
import { g as x, c as r } from "./css.
|
|
4
|
-
const C = () => import("./render-inlined-styles.
|
|
2
|
+
import { T as f, c as i, g as _, a as d, _ as g } from "./index.77da28db.js";
|
|
3
|
+
import { g as x, c as r } from "./css.162effaf.js";
|
|
4
|
+
const C = () => import("./render-inlined-styles.799a72a2.js").then((e) => e.default).catch((e) => {
|
|
5
5
|
throw console.error(
|
|
6
6
|
"Error while attempting to dynamically import component RenderInlinedStyles at ../render-inlined-styles.vue",
|
|
7
7
|
e
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("vue"),s=require("./index.51c251ae.cjs"),l=require("./css.9c26446d.cjs"),y=()=>Promise.resolve().then(()=>require("./render-inlined-styles.a41845aa.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderInlinedStyles at ../render-inlined-styles.vue",e),e}),k={name:"block-styles",components:{RenderInlinedStyles:c.defineAsyncComponent(y)},props:["block","context"],data(){return{TARGET:s.TARGET}},computed:{useBlock(){return l.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!0})},canShowBlock(){return s.checkIsDefined(this.useBlock.hide)?!this.useBlock.hide:s.checkIsDefined(this.useBlock.show)?this.useBlock.show:!0},css(){var d;const e=this.useBlock.responsiveStyles,o=this.context.content,i=s.getSizesForBreakpoints(((d=o==null?void 0:o.meta)==null?void 0:d.breakpoints)||{}),a=e==null?void 0:e.large,r=e==null?void 0:e.medium,t=e==null?void 0:e.small,n=this.useBlock.id,u=a?l.createCssClass({className:n,styles:a}):"",m=r?l.createCssClass({className:n,styles:r,mediaQuery:s.getMaxWidthQueryForSize("medium",i)}):"",h=t?l.createCssClass({className:n,styles:t,mediaQuery:s.getMaxWidthQueryForSize("small",i)}):"";return[u,m,h].join(" ")}}};function p(e,o,i,a,r,t){const n=c.resolveComponent("render-inlined-styles");return r.TARGET!=="reactNative"&&t.css&&t.canShowBlock?(c.openBlock(),c.createBlock(n,{key:0,styles:t.css},null,8,["styles"])):c.createCommentVNode("",!0)}const S=s._export_sfc(k,[["render",p]]);exports.default=S;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const i=require("./index.
|
|
1
|
+
"use strict";const i=require("./index.51c251ae.cjs"),l=(e,t,r)=>{if(Object(e)!==e)return e;const s=Array.isArray(t)?t:t.toString().match(/[^.[\]]+/g);return s.slice(0,-1).reduce((n,c,o)=>Object(n[c])===n[c]?n[c]:n[c]=Math.abs(Number(s[o+1]))>>0===+s[o+1]?[]:{},e)[s[s.length-1]]=r,e};const d=({block:e,context:t,state:r})=>{if(!e.bindings)return e;const s=i.fastClone(e),n={...s,properties:{...s.properties},actions:{...s.actions}};for(const c in e.bindings){const o=e.bindings[c],u=i.evaluate({code:o,state:r,context:t});l(n,c,u)}return n};function f({block:e,context:t,shouldEvaluateBindings:r,state:s}){const n=e;return r?d({block:n,state:s,context:t}):n}const p=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),a=e=>Object.entries(e).map(([r,s])=>{if(typeof s=="string")return`${p(r)}: ${s};`}).filter(i.checkIsDefined),g=e=>a(e).join(`
|
|
2
2
|
`),C=({mediaQuery:e,className:t,styles:r})=>{const s=`.${t} {
|
|
3
3
|
${g(r)}
|
|
4
4
|
}`;return e?`${e} {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const s=require("vue"),fe={name:"builder-button",props:["attributes","text","link","openLinkInNewTab"],methods:{filterAttrs:function(n={},t){const o="v-on:";return Object.keys(n).filter(i=>{const r=i.startsWith(o);return t?r:!r}).reduce((i,r)=>({...i,[r.replace(o,"")]:n[r]}),{})}}};const p=(e,n)=>{const t=e.__vccOpts||e;for(const[o,i]of n)t[o]=i;return t},ge=["href","target"];function be(e,n,t,o,i,r){return t.link?(s.openBlock(),s.createElementBlock("a",s.mergeProps({key:0,role:"button",href:t.link,target:t.openLinkInNewTab?"_blank":void 0},r.filterAttrs(t.attributes,!1),s.toHandlers(r.filterAttrs(t.attributes,!0),!0)),s.toDisplayString(t.text),17,ge)):(s.openBlock(),s.createElementBlock("button",s.mergeProps({key:1,class:"button-1yj9n7yt24z"},r.filterAttrs(t.attributes,!1),s.toHandlers(r.filterAttrs(t.attributes,!0),!0)),s.toDisplayString(t.text),17))}const M=p(fe,[["render",be],["__scopeId","data-v-28c9cee7"]]),S=e=>JSON.parse(JSON.stringify(e)),L={small:{min:320,default:321,max:640},medium:{min:641,default:642,max:991},large:{min:990,default:991,max:1200}},ye=(e,n=L)=>`@media (max-width: ${n[e].max}px)`,$=({small:e,medium:n})=>{const t=S(L);if(!e||!n)return t;const o=Math.floor(e/2);t.small={max:e,min:o,default:o+1};const i=t.small.max+1;t.medium={max:n,min:i,default:i+1};const r=t.medium.max+1;return t.large={max:2e3,min:r,default:r+1},t},k="vue3",ke=Symbol(),x={Builder:{content:null,context:{},state:{},setState(){},apiKey:null,apiVersion:void 0,registeredComponents:{},inheritedStyles:{}},key:ke},ve=()=>Promise.resolve().then(()=>q).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",e),e}),xe=()=>Promise.resolve().then(()=>require("./render-inlined-styles.
|
|
1
|
+
"use strict";const s=require("vue"),fe={name:"builder-button",props:["attributes","text","link","openLinkInNewTab"],methods:{filterAttrs:function(n={},t){const o="v-on:";return Object.keys(n).filter(i=>{const r=i.startsWith(o);return t?r:!r}).reduce((i,r)=>({...i,[r.replace(o,"")]:n[r]}),{})}}};const p=(e,n)=>{const t=e.__vccOpts||e;for(const[o,i]of n)t[o]=i;return t},ge=["href","target"];function be(e,n,t,o,i,r){return t.link?(s.openBlock(),s.createElementBlock("a",s.mergeProps({key:0,role:"button",href:t.link,target:t.openLinkInNewTab?"_blank":void 0},r.filterAttrs(t.attributes,!1),s.toHandlers(r.filterAttrs(t.attributes,!0),!0)),s.toDisplayString(t.text),17,ge)):(s.openBlock(),s.createElementBlock("button",s.mergeProps({key:1,class:"button-1yj9n7yt24z"},r.filterAttrs(t.attributes,!1),s.toHandlers(r.filterAttrs(t.attributes,!0),!0)),s.toDisplayString(t.text),17))}const M=p(fe,[["render",be],["__scopeId","data-v-28c9cee7"]]),S=e=>JSON.parse(JSON.stringify(e)),L={small:{min:320,default:321,max:640},medium:{min:641,default:642,max:991},large:{min:990,default:991,max:1200}},ye=(e,n=L)=>`@media (max-width: ${n[e].max}px)`,$=({small:e,medium:n})=>{const t=S(L);if(!e||!n)return t;const o=Math.floor(e/2);t.small={max:e,min:o,default:o+1};const i=t.small.max+1;t.medium={max:n,min:i,default:i+1};const r=t.medium.max+1;return t.large={max:2e3,min:r,default:r+1},t},k="vue3",ke=Symbol(),x={Builder:{content:null,context:{},state:{},setState(){},apiKey:null,apiVersion:void 0,registeredComponents:{},inheritedStyles:{}},key:ke},ve=()=>Promise.resolve().then(()=>q).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",e),e}),xe=()=>Promise.resolve().then(()=>require("./render-inlined-styles.a41845aa.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderInlinedStyles at ../../components/render-inlined-styles.vue",e),e}),Se={name:"builder-columns",components:{RenderInlinedStyles:s.defineAsyncComponent(xe),RenderBlocks:s.defineAsyncComponent(ve)},props:["space","columns","stackColumnsAt","reverseColumnsWhenStacked","builderBlock"],data(){return{gutterSize:typeof this.space=="number"?this.space||0:20,cols:this.columns||[],stackAt:this.stackColumnsAt||"tablet",flexDir:this.stackColumnsAt==="never"?"row":this.reverseColumnsWhenStacked?"column-reverse":"column",TARGET:k}},inject:{builderContext:x.key},computed:{columnsCssVars(){return{"--flex-dir":this.flexDir,"--flex-dir-tablet":this.getTabletStyle({stackedStyle:this.flexDir,desktopStyle:"row"})}},columnsStyles(){return`
|
|
2
2
|
@media (max-width: ${this.getWidthForBreakpointSize("medium")}px) {
|
|
3
3
|
.${this.builderBlock.id}-breakpoints {
|
|
4
4
|
flex-direction: var(--flex-dir-tablet);
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
margin-left: var(--column-margin-left-mobile) !important;
|
|
23
23
|
}
|
|
24
24
|
},
|
|
25
|
-
`}},methods:{getWidth(e){var n;return((n=this.cols[e])==null?void 0:n.width)||100/this.cols.length},getColumnCssWidth(e){const n=this.gutterSize*(this.cols.length-1)/this.cols.length;return`calc(${this.getWidth(e)}% - ${n}px)`},getTabletStyle({stackedStyle:e,desktopStyle:n}){return this.stackAt==="tablet"?e:n},getMobileStyle({stackedStyle:e,desktopStyle:n}){return this.stackAt==="never"?n:e},columnCssVars(e){const n=this.getColumnCssWidth(e),t=`${e===0?0:this.gutterSize}px`,o="100%",i="0";return{width:n,"margin-left":t,"--column-width-mobile":this.getMobileStyle({stackedStyle:o,desktopStyle:n}),"--column-margin-left-mobile":this.getMobileStyle({stackedStyle:i,desktopStyle:t}),"--column-width-tablet":this.getTabletStyle({stackedStyle:o,desktopStyle:n}),"--column-margin-left-tablet":this.getTabletStyle({stackedStyle:i,desktopStyle:t})}},getWidthForBreakpointSize(e){var t,o;return $(((o=(t=this.builderContext.content)==null?void 0:t.meta)==null?void 0:o.breakpoints)||{})[e].max},_classStringToObject(e){const n={};if(typeof e!="string")return n;const t=e.trim().split(/\s+/);for(const o of t)n[o]=!0;return n}}};function Ce(e,n,t,o,i,r){const a=s.resolveComponent("render-inlined-styles"),l=s.resolveComponent("render-blocks");return s.openBlock(),s.createElementBlock("div",{class:s.normalizeClass(r._classStringToObject(`builder-columns ${t.builderBlock.id}-breakpoints div-361b1o6wv2k`)),style:s.normalizeStyle(r.columnsCssVars),dataSet:{"builder-block-name":"builder-columns"}},[i.TARGET!=="reactNative"?(s.openBlock(),s.createBlock(a,{key:0,styles:r.columnsStyles},null,8,["styles"])):s.createCommentVNode("",!0),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(t.columns,(c,d)=>(s.openBlock(),s.createElementBlock("div",{key:d,class:"builder-column div-361b1o6wv2k-2",style:s.normalizeStyle(r.columnCssVars(d)),dataSet:{"builder-block-name":"builder-column"}},[s.createVNode(l,{blocks:c.blocks,path:`component.options.columns.${d}.blocks`,parent:t.builderBlock.id,styleProp:{flexGrow:"1"}},null,8,["blocks","path","parent"])],4))),128))],6)}const z=p(Se,[["render",Ce],["__scopeId","data-v-d8ae54cc"]]),_e={name:"builder-fragment-component",props:[]};function we(e,n,t,o,i,r){return s.openBlock(),s.createElementBlock("span",null,[s.renderSlot(e.$slots,"default")])}const H=p(_e,[["render",we]]);function V(e){return e.replace(/http(s)?:/,"")}function Ie(e="",n,t){const o=new RegExp("([?&])"+n+"=.*?(&|$)","i"),i=e.indexOf("?")!==-1?"&":"?";return e.match(o)?e.replace(o,"$1"+n+"="+encodeURIComponent(t)+"$2"):e+i+n+"="+encodeURIComponent(t)}function Te(e,n){if(!e||!(e!=null&&e.match(/cdn\.shopify\.com/))||!n)return e;if(n==="master")return V(e);const t=e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);if(t){const o=e.split(t[0]),i=t[3],r=n.match("x")?n:`${n}x`;return V(`${o[0]}_${r}${i}`)}return null}function _(e){if(!e)return e;const n=[100,200,400,800,1200,1600,2e3];if(e.match(/builder\.io/)){let t=e;const o=Number(e.split("?width=")[1]);return isNaN(o)||(t=`${t} ${o}w`),n.filter(i=>i!==o).map(i=>`${Ie(e,"width",i)} ${i}w`).concat([t]).join(", ")}return e.match(/cdn\.shopify\.com/)?n.map(t=>[Te(e,`${t}x${t}`),t]).filter(([t])=>!!t).map(([t,o])=>`${t} ${o}w`).concat([e]).join(", "):e}const Re={name:"builder-image",props:["image","src","srcset","noWebp","aspectRatio","altText","backgroundPosition","backgroundSize","className","sizes","builderBlock","fitContent"],computed:{srcSetToUse(){var t;const n=this.image||this.src;if(!n||!(n.match(/builder\.io/)||n.match(/cdn\.shopify\.com/)))return this.srcset;if(this.srcset&&((t=this.image)==null?void 0:t.includes("builder.io/api/v1/image"))){if(!this.srcset.includes(this.image.split("?")[0]))return console.debug("Removed given srcset"),_(n)}else if(this.image&&!this.srcset)return _(n);return _(n)},webpSrcSet(){var e;return((e=this.srcSetToUse)==null?void 0:e.match(/builder\.io/))&&!this.noWebp?this.srcSetToUse.replace(/\?/g,"?format=webp&"):""},aspectRatioCss(){const e={position:"absolute",height:"100%",width:"100%",left:"0px",top:"0px"};return this.aspectRatio?e:void 0}},methods:{_classStringToObject(e){const n={};if(typeof e!="string")return n;const t=e.trim().split(/\s+/);for(const o of t)n[o]=!0;return n}}};const Be=["srcset"],Ee=["alt","role","src","srcset","sizes"],Ae={key:2,class:"div-7jvpanrlkn-2"};function Ve(e,n,t,o,i,r){var a,l,c,d;return s.openBlock(),s.createElementBlock(s.Fragment,null,[s.createElementVNode("picture",null,[r.webpSrcSet?(s.openBlock(),s.createElementBlock("source",{key:0,type:"image/webp",srcset:r.webpSrcSet},null,8,Be)):s.createCommentVNode("",!0),s.createElementVNode("img",{loading:"lazy",alt:t.altText,role:t.altText?"presentation":void 0,style:s.normalizeStyle({objectPosition:t.backgroundPosition||"center",objectFit:t.backgroundSize||"cover",...r.aspectRatioCss}),class:s.normalizeClass(r._classStringToObject("builder-image"+(t.className?" "+t.className:"")+" img-7jvpanrlkn")),src:t.image,srcset:r.srcSetToUse,sizes:t.sizes},null,14,Ee)]),t.aspectRatio&&!(((l=(a=t.builderBlock)==null?void 0:a.children)==null?void 0:l.length)&&t.fitContent)?(s.openBlock(),s.createElementBlock("div",{key:0,class:"builder-image-sizer div-7jvpanrlkn",style:s.normalizeStyle({paddingTop:t.aspectRatio*100+"%"})},null,4)):s.createCommentVNode("",!0),((d=(c=t.builderBlock)==null?void 0:c.children)==null?void 0:d.length)&&t.fitContent?s.renderSlot(e.$slots,"default",{key:1},void 0,!0):s.createCommentVNode("",!0),!t.fitContent&&e.children?(s.openBlock(),s.createElementBlock("div",Ae,[s.renderSlot(e.$slots,"default",{},void 0,!0)])):s.createCommentVNode("",!0)],64)}const K=p(Re,[["render",Ve],["__scopeId","data-v-22833d9f"]]);function m(){return typeof window<"u"&&typeof document<"u"}function Pe(){return m()&&window.self!==window.top}function b(){return Pe()&&window.location.search.indexOf("builder.frameEditing=")!==-1}const je=()=>Promise.resolve().then(()=>require("./block-styles.58529395.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",e),e}),Fe=()=>Promise.resolve().then(()=>require("./render-block.8923e93f.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",e),e}),Oe={name:"render-blocks",components:{RenderBlock:s.defineAsyncComponent(Fe),BlockStyles:s.defineAsyncComponent(je)},props:["blocks","parent","path","styleProp"],inject:{builderContext:x.key},computed:{className(){var e;return"builder-blocks"+((e=this.blocks)!=null&&e.length?"":" no-blocks")}},methods:{onClick(){var e,n;b()&&!((e=this.blocks)!=null&&e.length)&&((n=window.parent)==null||n.postMessage({type:"builder.clickEmptyBlocks",data:{parentElementId:this.parent,dataPath:this.path}},"*"))},onMouseEnter(){var e,n;b()&&!((e=this.blocks)!=null&&e.length)&&((n=window.parent)==null||n.postMessage({type:"builder.hoverEmptyBlocks",data:{parentElementId:this.parent,dataPath:this.path}},"*"))},_classStringToObject(e){const n={};if(typeof e!="string")return n;const t=e.trim().split(/\s+/);for(const o of t)n[o]=!0;return n}}};const Ue=["builder-path","builder-parent-id","dataSet"];function Ne(e,n,t,o,i,r){const a=s.resolveComponent("render-block"),l=s.resolveComponent("block-styles");return s.openBlock(),s.createElementBlock("div",{class:s.normalizeClass(r._classStringToObject(r.className+" div-7fq9d0i380")),"builder-path":t.path,"builder-parent-id":t.parent,dataSet:{class:r.className},style:s.normalizeStyle(t.styleProp),onClick:n[0]||(n[0]=c=>r.onClick()),onMouseenter:n[1]||(n[1]=c=>r.onMouseEnter())},[t.blocks?(s.openBlock(!0),s.createElementBlock(s.Fragment,{key:0},s.renderList(t.blocks,(c,d)=>(s.openBlock(),s.createBlock(a,{key:"render-block-"+c.id,block:c,context:r.builderContext},null,8,["block","context"]))),128)):s.createCommentVNode("",!0),t.blocks?(s.openBlock(!0),s.createElementBlock(s.Fragment,{key:1},s.renderList(t.blocks,(c,d)=>(s.openBlock(),s.createBlock(l,{key:"block-style-"+c.id,block:c,context:r.builderContext},null,8,["block","context"]))),128)):s.createCommentVNode("",!0)],46,Ue)}const D=p(Oe,[["render",Ne],["__scopeId","data-v-1112d180"]]),q=Object.freeze(Object.defineProperty({__proto__:null,default:D},Symbol.toStringTag,{value:"Module"})),We={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},C=e=>{const n=e.toString().trim();return`return (${!n.startsWith("function")&&!n.startsWith("(")?"function ":""}${n}).apply(this, arguments)`},Me={name:"Columns",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:C(e=>{function n(){t.forEach(o=>{o.delete("width")})}const t=e.get("columns");Array.isArray(t)&&!!t.find(i=>i.get("width"))&&(!!t.find(r=>!r.get("width"))||t.reduce((l,c)=>l+c.get("width"),0)!==100)&&n()})},{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}]},Le={name:"Fragment",static:!0,hidden:!0,canHaveChildren:!0,noWrap:!0},$e={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:["jpeg","jpg","png","svg"],required:!0,defaultValue:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",onChange:C(e=>{e.delete("srcset"),e.delete("noWebp");function t(a,l=6e4){return new Promise((c,d)=>{const u=document.createElement("img");let f=!1;u.onload=()=>{f=!0,c(u)},u.addEventListener("error",h=>{console.warn("Image load failed",h.error),d(h.error)}),u.src=a,setTimeout(()=>{f||d(new Error("Image load timed out"))},l)})}function o(a){return Math.round(a*1e3)/1e3}const i=e.get("image"),r=e.get("aspectRatio");if(fetch(i).then(a=>a.blob()).then(a=>{a.type.includes("svg")&&e.set("noWebp",!0)}),i&&(!r||r===.7041))return t(i).then(a=>{const l=e.get("aspectRatio");e.get("image")===i&&(!l||l===.7041)&&a.width&&a.height&&(e.set("aspectRatio",o(a.height/a.width)),e.set("height",a.height),e.set("width",a.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:"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}]},ze={name:"Core:Section",static:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",inputs:[{name:"maxWidth",type:"number",defaultValue:1200},{name:"lazyLoad",type:"boolean",defaultValue:!1,advanced:!0,description:"Only render this section when in view"}],defaultStyles:{paddingLeft:"20px",paddingRight:"20px",paddingTop:"50px",paddingBottom:"50px",marginTop:"0px",width:"100vw",marginLeft:"calc(50% - 50vw)"},canHaveChildren:!0,defaultChildren:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"center"}},component:{name:"Text",options:{text:"<p><b>I am a section! My content keeps from getting too wide, so that it's easy to read even on big screens.</b></p><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur</p>"}}}]},He={name:"builder-section-component",props:["maxWidth","attributes"],methods:{filterAttrs:function(n={},t){const o="v-on:";return Object.keys(n).filter(i=>{const r=i.startsWith(o);return t?r:!r}).reduce((i,r)=>({...i,[r.replace(o,"")]:n[r]}),{})}}};function Ke(e,n,t,o,i,r){return s.openBlock(),s.createElementBlock("section",s.mergeProps({style:{width:"100%",alignSelf:"stretch",flexGrow:1,boxSizing:"border-box",maxWidth:t.maxWidth||1200,display:"flex",flexDirection:"column",alignItems:"stretch",marginLeft:"auto",marginRight:"auto"}},r.filterAttrs(t.attributes,!1),s.toHandlers(r.filterAttrs(t.attributes,!0),!0)),[s.renderSlot(e.$slots,"default")],16)}const G=p(He,[["render",Ke]]),De={name:"Symbol",noWrap:!0,static:!0,inputs:[{name:"symbol",type:"uiSymbol"},{name:"dataOnly",helperText:"Make this a data symbol that doesn't display any UI",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"inheritState",helperText:"Inherit the parent component state and data",type:"boolean",defaultValue:!1,advanced:!0},{name:"renderToLiquid",helperText:"Render this symbols contents to liquid. Turn off to fetch with javascript and use custom targeting",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"useChildren",hideFromUI:!0,type:"boolean"}]};function qe(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:globalThis}function Ge(){const e=qe().fetch;if(typeof e>"u")throw console.warn(`Builder SDK could not find a global fetch function. Make sure you have a polyfill for fetch in your project.
|
|
25
|
+
`}},methods:{getWidth(e){var n;return((n=this.cols[e])==null?void 0:n.width)||100/this.cols.length},getColumnCssWidth(e){const n=this.gutterSize*(this.cols.length-1)/this.cols.length;return`calc(${this.getWidth(e)}% - ${n}px)`},getTabletStyle({stackedStyle:e,desktopStyle:n}){return this.stackAt==="tablet"?e:n},getMobileStyle({stackedStyle:e,desktopStyle:n}){return this.stackAt==="never"?n:e},columnCssVars(e){const n=this.getColumnCssWidth(e),t=`${e===0?0:this.gutterSize}px`,o="100%",i=0;return{width:n,"margin-left":t,"--column-width-mobile":this.getMobileStyle({stackedStyle:o,desktopStyle:n}),"--column-margin-left-mobile":this.getMobileStyle({stackedStyle:i,desktopStyle:t}),"--column-width-tablet":this.getTabletStyle({stackedStyle:o,desktopStyle:n}),"--column-margin-left-tablet":this.getTabletStyle({stackedStyle:i,desktopStyle:t})}},getWidthForBreakpointSize(e){var t,o;return $(((o=(t=this.builderContext.content)==null?void 0:t.meta)==null?void 0:o.breakpoints)||{})[e].max},_classStringToObject(e){const n={};if(typeof e!="string")return n;const t=e.trim().split(/\s+/);for(const o of t)n[o]=!0;return n}}};function Ce(e,n,t,o,i,r){const a=s.resolveComponent("render-inlined-styles"),l=s.resolveComponent("render-blocks");return s.openBlock(),s.createElementBlock("div",{class:s.normalizeClass(r._classStringToObject(`builder-columns ${t.builderBlock.id}-breakpoints div-361b1o6wv2k`)),style:s.normalizeStyle(r.columnsCssVars),dataSet:{"builder-block-name":"builder-columns"}},[i.TARGET!=="reactNative"?(s.openBlock(),s.createBlock(a,{key:0,styles:r.columnsStyles},null,8,["styles"])):s.createCommentVNode("",!0),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(t.columns,(c,d)=>(s.openBlock(),s.createElementBlock("div",{key:d,class:"builder-column div-361b1o6wv2k-2",style:s.normalizeStyle(r.columnCssVars(d)),dataSet:{"builder-block-name":"builder-column"}},[s.createVNode(l,{blocks:c.blocks,path:`component.options.columns.${d}.blocks`,parent:t.builderBlock.id,styleProp:{flexGrow:"1"}},null,8,["blocks","path","parent"])],4))),128))],6)}const z=p(Se,[["render",Ce],["__scopeId","data-v-ea0f5889"]]),_e={name:"builder-fragment-component",props:[]};function we(e,n,t,o,i,r){return s.openBlock(),s.createElementBlock("span",null,[s.renderSlot(e.$slots,"default")])}const H=p(_e,[["render",we]]);function V(e){return e.replace(/http(s)?:/,"")}function Ie(e="",n,t){const o=new RegExp("([?&])"+n+"=.*?(&|$)","i"),i=e.indexOf("?")!==-1?"&":"?";return e.match(o)?e.replace(o,"$1"+n+"="+encodeURIComponent(t)+"$2"):e+i+n+"="+encodeURIComponent(t)}function Te(e,n){if(!e||!(e!=null&&e.match(/cdn\.shopify\.com/))||!n)return e;if(n==="master")return V(e);const t=e.match(/(_\d+x(\d+)?)?(\.(jpg|jpeg|gif|png|bmp|bitmap|tiff|tif)(\?v=\d+)?)/i);if(t){const o=e.split(t[0]),i=t[3],r=n.match("x")?n:`${n}x`;return V(`${o[0]}_${r}${i}`)}return null}function _(e){if(!e)return e;const n=[100,200,400,800,1200,1600,2e3];if(e.match(/builder\.io/)){let t=e;const o=Number(e.split("?width=")[1]);return isNaN(o)||(t=`${t} ${o}w`),n.filter(i=>i!==o).map(i=>`${Ie(e,"width",i)} ${i}w`).concat([t]).join(", ")}return e.match(/cdn\.shopify\.com/)?n.map(t=>[Te(e,`${t}x${t}`),t]).filter(([t])=>!!t).map(([t,o])=>`${t} ${o}w`).concat([e]).join(", "):e}const Re={name:"builder-image",props:["image","src","srcset","noWebp","aspectRatio","altText","backgroundPosition","backgroundSize","className","sizes","builderBlock","fitContent"],computed:{srcSetToUse(){var t;const n=this.image||this.src;if(!n||!(n.match(/builder\.io/)||n.match(/cdn\.shopify\.com/)))return this.srcset;if(this.srcset&&((t=this.image)==null?void 0:t.includes("builder.io/api/v1/image"))){if(!this.srcset.includes(this.image.split("?")[0]))return console.debug("Removed given srcset"),_(n)}else if(this.image&&!this.srcset)return _(n);return _(n)},webpSrcSet(){var e;return((e=this.srcSetToUse)==null?void 0:e.match(/builder\.io/))&&!this.noWebp?this.srcSetToUse.replace(/\?/g,"?format=webp&"):""},aspectRatioCss(){const e={position:"absolute",height:"100%",width:"100%",left:"0px",top:"0px"};return this.aspectRatio?e:void 0}},methods:{_classStringToObject(e){const n={};if(typeof e!="string")return n;const t=e.trim().split(/\s+/);for(const o of t)n[o]=!0;return n}}};const Be=["srcset"],Ee=["alt","role","src","srcset","sizes"],Ae={key:2,class:"div-7jvpanrlkn-2"};function Ve(e,n,t,o,i,r){var a,l,c,d;return s.openBlock(),s.createElementBlock(s.Fragment,null,[s.createElementVNode("picture",null,[r.webpSrcSet?(s.openBlock(),s.createElementBlock("source",{key:0,type:"image/webp",srcset:r.webpSrcSet},null,8,Be)):s.createCommentVNode("",!0),s.createElementVNode("img",{loading:"lazy",alt:t.altText,role:t.altText?"presentation":void 0,style:s.normalizeStyle({objectPosition:t.backgroundPosition||"center",objectFit:t.backgroundSize||"cover",...r.aspectRatioCss}),class:s.normalizeClass(r._classStringToObject("builder-image"+(t.className?" "+t.className:"")+" img-7jvpanrlkn")),src:t.image,srcset:r.srcSetToUse,sizes:t.sizes},null,14,Ee)]),t.aspectRatio&&!(((l=(a=t.builderBlock)==null?void 0:a.children)==null?void 0:l.length)&&t.fitContent)?(s.openBlock(),s.createElementBlock("div",{key:0,class:"builder-image-sizer div-7jvpanrlkn",style:s.normalizeStyle({paddingTop:t.aspectRatio*100+"%"})},null,4)):s.createCommentVNode("",!0),((d=(c=t.builderBlock)==null?void 0:c.children)==null?void 0:d.length)&&t.fitContent?s.renderSlot(e.$slots,"default",{key:1},void 0,!0):s.createCommentVNode("",!0),!t.fitContent&&e.children?(s.openBlock(),s.createElementBlock("div",Ae,[s.renderSlot(e.$slots,"default",{},void 0,!0)])):s.createCommentVNode("",!0)],64)}const K=p(Re,[["render",Ve],["__scopeId","data-v-22833d9f"]]);function m(){return typeof window<"u"&&typeof document<"u"}function Pe(){return m()&&window.self!==window.top}function b(){return Pe()&&window.location.search.indexOf("builder.frameEditing=")!==-1}const je=()=>Promise.resolve().then(()=>require("./block-styles.c334abc4.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",e),e}),Fe=()=>Promise.resolve().then(()=>require("./render-block.75044288.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",e),e}),Oe={name:"render-blocks",components:{RenderBlock:s.defineAsyncComponent(Fe),BlockStyles:s.defineAsyncComponent(je)},props:["blocks","parent","path","styleProp"],inject:{builderContext:x.key},computed:{className(){var e;return"builder-blocks"+((e=this.blocks)!=null&&e.length?"":" no-blocks")}},methods:{onClick(){var e,n;b()&&!((e=this.blocks)!=null&&e.length)&&((n=window.parent)==null||n.postMessage({type:"builder.clickEmptyBlocks",data:{parentElementId:this.parent,dataPath:this.path}},"*"))},onMouseEnter(){var e,n;b()&&!((e=this.blocks)!=null&&e.length)&&((n=window.parent)==null||n.postMessage({type:"builder.hoverEmptyBlocks",data:{parentElementId:this.parent,dataPath:this.path}},"*"))},_classStringToObject(e){const n={};if(typeof e!="string")return n;const t=e.trim().split(/\s+/);for(const o of t)n[o]=!0;return n}}};const Ue=["builder-path","builder-parent-id","dataSet"];function Ne(e,n,t,o,i,r){const a=s.resolveComponent("render-block"),l=s.resolveComponent("block-styles");return s.openBlock(),s.createElementBlock("div",{class:s.normalizeClass(r._classStringToObject(r.className+" div-7fq9d0i380")),"builder-path":t.path,"builder-parent-id":t.parent,dataSet:{class:r.className},style:s.normalizeStyle(t.styleProp),onClick:n[0]||(n[0]=c=>r.onClick()),onMouseenter:n[1]||(n[1]=c=>r.onMouseEnter())},[t.blocks?(s.openBlock(!0),s.createElementBlock(s.Fragment,{key:0},s.renderList(t.blocks,(c,d)=>(s.openBlock(),s.createBlock(a,{key:"render-block-"+c.id,block:c,context:r.builderContext},null,8,["block","context"]))),128)):s.createCommentVNode("",!0),t.blocks?(s.openBlock(!0),s.createElementBlock(s.Fragment,{key:1},s.renderList(t.blocks,(c,d)=>(s.openBlock(),s.createBlock(l,{key:"block-style-"+c.id,block:c,context:r.builderContext},null,8,["block","context"]))),128)):s.createCommentVNode("",!0)],46,Ue)}const D=p(Oe,[["render",Ne],["__scopeId","data-v-1112d180"]]),q=Object.freeze(Object.defineProperty({__proto__:null,default:D},Symbol.toStringTag,{value:"Module"})),We={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},C=e=>{const n=e.toString().trim();return`return (${!n.startsWith("function")&&!n.startsWith("(")?"function ":""}${n}).apply(this, arguments)`},Me={name:"Columns",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:C(e=>{function n(){t.forEach(o=>{o.delete("width")})}const t=e.get("columns");Array.isArray(t)&&!!t.find(i=>i.get("width"))&&(!!t.find(r=>!r.get("width"))||t.reduce((l,c)=>l+c.get("width"),0)!==100)&&n()})},{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}]},Le={name:"Fragment",static:!0,hidden:!0,canHaveChildren:!0,noWrap:!0},$e={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:["jpeg","jpg","png","svg"],required:!0,defaultValue:"https://cdn.builder.io/api/v1/image/assets%2FYJIGb4i01jvw0SRdL5Bt%2F72c80f114dc149019051b6852a9e3b7a",onChange:C(e=>{e.delete("srcset"),e.delete("noWebp");function t(a,l=6e4){return new Promise((c,d)=>{const u=document.createElement("img");let f=!1;u.onload=()=>{f=!0,c(u)},u.addEventListener("error",h=>{console.warn("Image load failed",h.error),d(h.error)}),u.src=a,setTimeout(()=>{f||d(new Error("Image load timed out"))},l)})}function o(a){return Math.round(a*1e3)/1e3}const i=e.get("image"),r=e.get("aspectRatio");if(fetch(i).then(a=>a.blob()).then(a=>{a.type.includes("svg")&&e.set("noWebp",!0)}),i&&(!r||r===.7041))return t(i).then(a=>{const l=e.get("aspectRatio");e.get("image")===i&&(!l||l===.7041)&&a.width&&a.height&&(e.set("aspectRatio",o(a.height/a.width)),e.set("height",a.height),e.set("width",a.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:"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}]},ze={name:"Core:Section",static:!0,image:"https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",inputs:[{name:"maxWidth",type:"number",defaultValue:1200},{name:"lazyLoad",type:"boolean",defaultValue:!1,advanced:!0,description:"Only render this section when in view"}],defaultStyles:{paddingLeft:"20px",paddingRight:"20px",paddingTop:"50px",paddingBottom:"50px",marginTop:"0px",width:"100vw",marginLeft:"calc(50% - 50vw)"},canHaveChildren:!0,defaultChildren:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{textAlign:"center"}},component:{name:"Text",options:{text:"<p><b>I am a section! My content keeps from getting too wide, so that it's easy to read even on big screens.</b></p><p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur</p>"}}}]},He={name:"builder-section-component",props:["maxWidth","attributes"],methods:{filterAttrs:function(n={},t){const o="v-on:";return Object.keys(n).filter(i=>{const r=i.startsWith(o);return t?r:!r}).reduce((i,r)=>({...i,[r.replace(o,"")]:n[r]}),{})}}};function Ke(e,n,t,o,i,r){return s.openBlock(),s.createElementBlock("section",s.mergeProps({style:{width:"100%",alignSelf:"stretch",flexGrow:1,boxSizing:"border-box",maxWidth:t.maxWidth||1200,display:"flex",flexDirection:"column",alignItems:"stretch",marginLeft:"auto",marginRight:"auto"}},r.filterAttrs(t.attributes,!1),s.toHandlers(r.filterAttrs(t.attributes,!0),!0)),[s.renderSlot(e.$slots,"default")],16)}const G=p(He,[["render",Ke]]),De={name:"Symbol",noWrap:!0,static:!0,inputs:[{name:"symbol",type:"uiSymbol"},{name:"dataOnly",helperText:"Make this a data symbol that doesn't display any UI",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"inheritState",helperText:"Inherit the parent component state and data",type:"boolean",defaultValue:!1,advanced:!0},{name:"renderToLiquid",helperText:"Render this symbols contents to liquid. Turn off to fetch with javascript and use custom targeting",type:"boolean",defaultValue:!1,advanced:!0,hideFromUI:!0},{name:"useChildren",hideFromUI:!0,type:"boolean"}]};function qe(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:globalThis}function Ge(){const e=qe().fetch;if(typeof e>"u")throw console.warn(`Builder SDK could not find a global fetch function. Make sure you have a polyfill for fetch in your project.
|
|
26
26
|
For more information, read https://github.com/BuilderIO/this-package-uses-fetch`),new Error("Builder SDK could not find a global `fetch` function");return e}const J=Ge(),y=e=>e!=null,Je=e=>{if(e==="localhost"||e==="127.0.0.1")return e;const n=e.split(".");return n.length>2?n.slice(1).join("."):e},Y=async({name:e,canTrack:n})=>{var t;try{return n?(t=document.cookie.split("; ").find(o=>o.startsWith(`${e}=`)))==null?void 0:t.split("=")[1]:void 0}catch(o){console.debug("[COOKIE] GET error: ",o);return}},Ye=e=>e.map(([n,t])=>t?`${n}=${t}`:n).filter(y).join("; "),Xe=[["secure",""],["SameSite","None"]],Qe=({name:e,value:n,expires:t})=>{const i=(m()?location.protocol==="https:":!0)?Xe:[[]],r=t?[["expires",t.toUTCString()]]:[[]],a=[[e,n],...r,["path","/"],["domain",Je(window.location.hostname)],...i];return Ye(a)},X=async({name:e,value:n,expires:t,canTrack:o})=>{try{if(!o)return;const i=Qe({name:e,value:n,expires:t});document.cookie=i}catch(i){console.warn("[COOKIE] SET error: ",i)}},Ze="builderio.variations",Q=e=>`${Ze}.${e}`,et=({contentId:e,canTrack:n})=>Y({name:Q(e),canTrack:n}),tt=({contentId:e,canTrack:n,value:t})=>X({name:Q(e),value:t,canTrack:n}),nt=e=>y(e.id)&&y(e.variations)&&Object.keys(e.variations).length>0,ot=({id:e,variations:n})=>{var i;let t=0;const o=Math.random();for(const r in n){const a=(i=n[r])==null?void 0:i.testRatio;if(t+=a,o<t)return r}return e},P=({item:e,testGroupId:n})=>{const t=e.variations[n];return n===e.id||!t?{testVariationId:e.id,testVariationName:"Default"}:{data:t.data,testVariationId:t.id,testVariationName:t.name||(t.id===e.id?"Default":"")}},rt=async({item:e,canTrack:n})=>{const t=await et({canTrack:n,contentId:e.id}),o=t?P({item:e,testGroupId:t}):void 0;if(o)return o;{const i=ot({variations:e.variations,id:e.id});return tt({contentId:e.id,value:i,canTrack:n}).catch(r=>{console.error("could not store A/B test variation: ",r)}),P({item:e,testGroupId:i})}},it=async({item:e,canTrack:n})=>{if(!nt(e))return;const t=await rt({item:e,canTrack:n});Object.assign(e,t)};function w(e,n=null,t="."){return Object.keys(e).reduce((o,i)=>{const r=e[i],a=[n,i].filter(Boolean).join(t);return[typeof r=="object",r!==null,!(Array.isArray(r)&&r.length===0)].every(Boolean)?{...o,...w(r,a,t)}:{...o,[a]:r}},{})}const j="builder.",st="options.",Z=e=>{const n={};return e.forEach((t,o)=>{n[o]=t}),n},ee=e=>{if(!e)return{};const n=R(e),t={};return Object.keys(n).forEach(o=>{if(o.startsWith(j)){const i=o.replace(j,"").replace(st,"");t[i]=n[o]}}),t},te=()=>{if(!m())return{};const e=new URLSearchParams(window.location.search);return ee(e)},R=e=>e instanceof URLSearchParams?Z(e):e,at=e=>{const{limit:n=30,userAttributes:t,query:o,noTraverse:i=!1,model:r,apiKey:a,includeRefs:l=!0,locale:c,apiVersion:d="v2"}=e;if(!a)throw new Error("Missing API key");if(!["v2","v3"].includes(d))throw new Error(`Invalid apiVersion: expected 'v2' or 'v3', received '${d}'`);const u=new URL(`https://cdn.builder.io/api/${d}/content/${r}?apiKey=${a}&limit=${n}&noTraverse=${i}&includeRefs=${l}${c?`&locale=${c}`:""}`),f={...te(),...R(e.options||{})},h=w(f);for(const g in h)u.searchParams.set(g,String(h[g]));if(t&&u.searchParams.set("userAttributes",JSON.stringify(t)),o){const g=w({query:o});for(const v in g)u.searchParams.set(v,JSON.stringify(g[v]))}return u};async function B(e){return(await ne({...e,limit:1})).results[0]||null}async function ne(e){const n=at(e),o=await(await J(n.href)).json(),i=e.canTrack!==!1;if(i&&Array.isArray(o.results))for(const r of o.results)await it({item:r,canTrack:i});return o}const ct=()=>Promise.resolve().then(()=>fn).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderContent at ../../components/render-content/render-content.vue",e),e}),lt={name:"builder-symbol",components:{RenderContent:s.defineAsyncComponent(ct)},props:["attributes","symbol","dynamic"],data(){var e,n,t;return{className:[...Object.keys(this.attributes.class),"builder-symbol",(e=this.symbol)!=null&&e.inline?"builder-inline-symbol":void 0,((n=this.symbol)==null?void 0:n.dynamic)||this.dynamic?"builder-dynamic-symbol":void 0].filter(Boolean).join(" "),contentToUse:(t=this.symbol)==null?void 0:t.content}},inject:{builderContext:x.key},mounted(){this.fetchContent()},watch:{onUpdateHook0:{handler(){this.fetchContent()},immediate:!0}},computed:{onUpdateHook0(){return{0:this.symbol}}},methods:{fetchContent(){var e,n;!this.contentToUse&&((e=this.symbol)==null?void 0:e.model)&&((n=this.builderContext)==null?void 0:n.apiKey)&&B({model:this.symbol.model,apiKey:this.builderContext.apiKey,apiVersion:this.builderContext.apiVersion,query:{id:this.symbol.entry}}).then(t=>{t&&(this.contentToUse=t)}).catch(t=>{console.error("[Builder.io]: Could not fetch symbol content: ",t)})},filterAttrs:function(n={},t){const o="v-on:";return Object.keys(n).filter(i=>{const r=i.startsWith(o);return t?r:!r}).reduce((i,r)=>({...i,[r.replace(o,"")]:n[r]}),{})},_classStringToObject(e){const n={};if(typeof e!="string")return n;const t=e.trim().split(/\s+/);for(const o of t)n[o]=!0;return n}}},dt=["dataSet"];function ut(e,n,t,o,i,r){var l,c,d,u;const a=s.resolveComponent("render-content");return s.openBlock(),s.createElementBlock("div",s.mergeProps({dataSet:{class:i.className},class:r._classStringToObject(i.className)},r.filterAttrs(t.attributes,!1),s.toHandlers(r.filterAttrs(t.attributes,!0),!0)),[s.createVNode(a,{apiVersion:r.builderContext.apiVersion,apiKey:r.builderContext.apiKey,context:r.builderContext.context,customComponents:Object.values(r.builderContext.registeredComponents),data:{...(l=t.symbol)==null?void 0:l.data,...r.builderContext.state,...(d=(c=i.contentToUse)==null?void 0:c.data)==null?void 0:d.state},model:(u=t.symbol)==null?void 0:u.model,content:i.contentToUse},null,8,["apiVersion","apiKey","context","customComponents","data","model","content"])],16,dt)}const oe=p(lt,[["render",ut]]),mt={name:"Text",static:!0,image:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-text_fields-24px%20(1).svg?alt=media&token=12177b73-0ee3-42ca-98c6-0dd003de1929",inputs:[{name:"text",type:"html",required:!0,autoFocus:!0,bubble:!0,defaultValue:"Enter some text..."}],defaultStyles:{lineHeight:"normal",height:"auto",textAlign:"center"}},pt={name:"builder-text",props:["text"]},ht=["innerHTML"];function ft(e,n,t,o,i,r){return s.openBlock(),s.createElementBlock("span",{class:"builder-text",innerHTML:t.text,style:{outline:"none"}},null,8,ht)}const re=p(pt,[["render",ft]]),gt={name:"Video",canHaveChildren:!0,defaultStyles:{minHeight:"20px",minWidth:"20px"},image:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/images%2Fbaseline-videocam-24px%20(1).svg?alt=media&token=49a84e4a-b20e-4977-a650-047f986874bb",inputs:[{name:"video",type:"file",allowedFileTypes:["mp4"],bubble:!0,defaultValue:"https://firebasestorage.googleapis.com/v0/b/builder-3b0a2.appspot.com/o/assets%2FKQlEmWDxA0coC3PK6UvkrjwkIGI2%2F28cb070609f546cdbe5efa20e931aa4b?alt=media&token=912e9551-7a7c-4dfb-86b6-3da1537d1a7f",required:!0},{name:"posterImage",type:"file",allowedFileTypes:["jpeg","png"],helperText:"Image to show before the video plays"},{name:"autoPlay",type:"boolean",defaultValue:!0},{name:"controls",type:"boolean",defaultValue:!1},{name:"muted",type:"boolean",defaultValue:!0},{name:"loop",type:"boolean",defaultValue:!0},{name:"playsInline",type:"boolean",defaultValue:!0},{name:"fit",type:"text",defaultValue:"cover",enum:["contain","cover","fill","auto"]},{name:"fitContent",type:"boolean",helperText:"When child blocks are provided, fit to them instead of using the aspect ratio",defaultValue:!0,advanced:!0},{name:"position",type:"text",defaultValue:"center",enum:["center","top","left","right","bottom","top left","top right","bottom left","bottom right"]},{name:"height",type:"number",advanced:!0},{name:"width",type:"number",advanced:!0},{name:"aspectRatio",type:"number",advanced:!0,defaultValue:.7004048582995948},{name:"lazyLoad",type:"boolean",helperText:'Load this video "lazily" - as in only when a user scrolls near the video. Recommended for optmized performance and bandwidth consumption',defaultValue:!0,advanced:!0}]},bt={name:"builder-video",props:["autoPlay","muted","controls","loop","playsInline","attributes","fit","position","video","posterImage"],computed:{videoProps(){return{...this.autoPlay===!0?{autoPlay:!0}:{},...this.muted===!0?{muted:!0}:{},...this.controls===!0?{controls:!0}:{},...this.loop===!0?{loop:!0}:{},...this.playsInline===!0?{playsInline:!0}:{}}},spreadProps(){return{...this.attributes,...this.videoProps}}}},yt=["src","poster"];function kt(e,n,t,o,i,r){var a;return s.openBlock(),s.createElementBlock("video",s.mergeProps({style:{width:"100%",height:"100%",...(a=t.attributes)==null?void 0:a.style,objectFit:t.fit,objectPosition:t.position,borderRadius:1},src:t.video||"no-src",poster:t.posterImage},r.spreadProps),null,16,yt)}const ie=p(bt,[["render",kt]]),vt={name:"Embed",static:!0,inputs:[{name:"url",type:"url",required:!0,defaultValue:"",helperText:"e.g. enter a youtube url, google map, etc",onChange:C(e=>{const n=e.get("url");if(n)return e.set("content","Loading..."),fetch(`https://iframe.ly/api/iframely?url=${n}&api_key=ae0e60e78201a3f2b0de4b`).then(o=>o.json()).then(o=>{e.get("url")===n&&(o.html?e.set("content",o.html):e.set("content","Invalid url, please try another"))}).catch(o=>{e.set("content","There was an error embedding this URL, please try again or another URL")});e.delete("content")})},{name:"content",type:"html",defaultValue:'<div style="padding: 20px; text-align: center">(Choose an embed URL)<div>',hideFromUI:!0}]},xt=["text/javascript","application/javascript","application/ecmascript"],St=e=>xt.includes(e.type),Ct={name:"builder-embed",props:["content"],data(){return{scriptsInserted:[],scriptsRun:[],ranInitFn:!1}},watch:{onUpdateHook0:{handler(){this.$refs.elem&&!this.ranInitFn&&(this.ranInitFn=!0,this.findAndRunScripts())},immediate:!0}},computed:{onUpdateHook0(){return{0:this.$refs.elem,1:this.ranInitFn}}},methods:{findAndRunScripts(){if(!this.$refs.elem||!this.$refs.elem.getElementsByTagName)return;const e=this.$refs.elem.getElementsByTagName("script");for(let n=0;n<e.length;n++){const t=e[n];if(t.src&&!this.scriptsInserted.includes(t.src)){this.scriptsInserted.push(t.src);const o=document.createElement("script");o.async=!0,o.src=t.src,document.head.appendChild(o)}else if(St(t)&&!this.scriptsRun.includes(t.innerText))try{this.scriptsRun.push(t.innerText),new Function(t.innerText)()}catch(o){console.warn("`Embed`: Error running script:",o)}}}}},_t=["innerHTML"];function wt(e,n,t,o,i,r){return s.openBlock(),s.createElementBlock("div",{class:"builder-embed",ref:"elem",innerHTML:t.content},null,8,_t)}const It=p(Ct,[["render",wt]]),Tt={name:"builder-img-component",props:["backgroundSize","backgroundPosition","imgSrc","altText","image","attributes"],data(){return{isEditing:b}},methods:{filterAttrs:function(n={},t){const o="v-on:";return Object.keys(n).filter(i=>{const r=i.startsWith(o);return t?r:!r}).reduce((i,r)=>({...i,[r.replace(o,"")]:n[r]}),{})}}},Rt=["alt","src"];function Bt(e,n,t,o,i,r){return s.openBlock(),s.createElementBlock("img",s.mergeProps({style:{objectFit:t.backgroundSize||"cover",objectPosition:t.backgroundPosition||"center"},key:i.isEditing()&&t.imgSrc||"default-key",alt:t.altText,src:t.imgSrc||t.image},r.filterAttrs(t.attributes,!1),s.toHandlers(r.filterAttrs(t.attributes,!0),!0)),null,16,Rt)}const Et=p(Tt,[["render",Bt]]),At={name:"Raw:Img",hideFromInsertMenu:!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",inputs:[{name:"image",bubble:!0,type:"file",allowedFileTypes:["jpeg","jpg","png","svg"],required:!0}],noWrap:!0,static:!0},Vt={name:"builder-custom-code",props:["replaceNodes","code"],data(){return{scriptsInserted:[],scriptsRun:[]}},mounted(){this.findAndRunScripts()},methods:{findAndRunScripts(){if(this.$refs.elem&&this.$refs.elem.getElementsByTagName&&typeof window<"u"){const e=this.$refs.elem.getElementsByTagName("script");for(let n=0;n<e.length;n++){const t=e[n];if(t.src){if(this.scriptsInserted.includes(t.src))continue;this.scriptsInserted.push(t.src);const o=document.createElement("script");o.async=!0,o.src=t.src,document.head.appendChild(o)}else if(!t.type||["text/javascript","application/javascript","application/ecmascript"].includes(t.type)){if(this.scriptsRun.includes(t.innerText))continue;try{this.scriptsRun.push(t.innerText),new Function(t.innerText)()}catch(o){console.warn("`CustomCode`: Error running script:",o)}}}}},_classStringToObject(e){const n={};if(typeof e!="string")return n;const t=e.trim().split(/\s+/);for(const o of t)n[o]=!0;return n}}},Pt=["innerHTML"];function jt(e,n,t,o,i,r){return s.openBlock(),s.createElementBlock("div",{ref:"elem",class:s.normalizeClass(r._classStringToObject("builder-custom-code"+(t.replaceNodes?" replace-nodes":""))),innerHTML:t.code},null,10,Pt)}const Ft=p(Vt,[["render",jt]]),Ot={name:"Custom Code",static:!0,requiredPermissions:["editCode"],inputs:[{name:"code",type:"html",required:!0,defaultValue:"<p>Hello there, I am custom HTML code!</p>",code:!0},{name:"replaceNodes",type:"boolean",helperText:"Preserve server rendered dom nodes",advanced:!0},{name:"scriptsClientOnly",type:"boolean",defaultValue:!1,helperText:"Only print and run scripts on the client. Important when scripts influence DOM that could be replaced when client loads",advanced:!0}]},Ut=()=>[{component:M,...We},{component:z,...Me},{component:Ft,...Ot},{component:It,...vt},{component:H,...Le},{component:K,...$e},{component:Et,...At},{component:G,...ze},{component:oe,...De},{component:re,...mt},{component:ie,...gt}];function I({code:e,context:n,state:t,event:o,isExpression:i=!0}){if(e===""){console.warn("Skipping evaluation of empty code block.");return}const r={isEditing:b(),isBrowser:m(),isServer:!m()},l=i&&!(e.includes(";")||e.includes(" return ")||e.trim().startsWith("return "))?`return (${e});`:e;try{return new Function("builder","Builder","state","context","event",l)(r,r,t,n,o)}catch(c){console.warn(`Builder custom code error:
|
|
27
27
|
While Evaluating:
|
|
28
28
|
`,l,`
|
|
29
|
-
`,c)}}function se(){return!m()||b()?!1:Boolean(location.search.indexOf("builder.preview=")!==-1)}const E=[];function Nt(e,n){return E.push({component:e,...n}),console.warn("registerComponent is deprecated. Use the `customComponents` prop in RenderContent instead to provide your custom components to the builder SDK."),e}const ae=({component:e,...n})=>({type:"builder.registerComponent",data:Mt(n)}),Wt=e=>typeof e=="function"?C(e):S(e),Mt=({inputs:e,...n})=>({...S(n),inputs:e==null?void 0:e.map(t=>Object.entries(t).reduce((o,[i,r])=>({...o,[i]:Wt(r)}),{}))});function Lt(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const n=Math.random()*16|0;return(e=="x"?n:n&3|8).toString(16)})}function ce(){return Lt().replace(/-/g,"")}const le="builderSessionId",$t=async({canTrack:e})=>{if(!e)return;const n=await Y({name:le,canTrack:e});if(y(n))return n;{const t=zt();return Ht({id:t,canTrack:e}),t}},zt=()=>ce(),Ht=({id:e,canTrack:n})=>X({name:le,value:e,canTrack:n}),de=()=>m()&&typeof localStorage<"u"?localStorage:void 0,Kt=({key:e,canTrack:n})=>{var t;try{return n?(t=de())==null?void 0:t.getItem(e):void 0}catch(o){console.debug("[LocalStorage] GET error: ",o);return}},Dt=({key:e,canTrack:n,value:t})=>{var o;try{n&&((o=de())==null||o.setItem(e,t))}catch(i){console.debug("[LocalStorage] SET error: ",i)}},ue="builderVisitorId",qt=({canTrack:e})=>{if(!e)return;const n=Kt({key:ue,canTrack:e});if(y(n))return n;{const t=Gt();return Jt({id:t,canTrack:e}),t}},Gt=()=>ce(),Jt=({id:e,canTrack:n})=>Dt({key:ue,value:e,canTrack:n}),Yt=()=>{if(m()){const e=new URL(location.href);return e.pathname===""&&(e.pathname="/"),e}else return console.warn("Cannot get location for tracking in non-browser environment"),null},Xt=()=>typeof navigator=="object"&&navigator.userAgent||"",Qt=()=>{const e=Xt(),n={Android(){return e.match(/Android/i)},BlackBerry(){return e.match(/BlackBerry/i)},iOS(){return e.match(/iPhone|iPod/i)},Opera(){return e.match(/Opera Mini/i)},Windows(){return e.match(/IEMobile/i)||e.match(/WPDesktop/i)},any(){return n.Android()||n.BlackBerry()||n.iOS()||n.Opera()||n.Windows()||k==="reactNative"}},t=e.match(/Tablet|iPad/i),o=Yt();return{urlPath:o==null?void 0:o.pathname,host:(o==null?void 0:o.host)||(o==null?void 0:o.hostname),device:t?"tablet":n.any()?"mobile":"desktop"}},Zt=async({canTrack:e})=>{if(!e)return{visitorId:void 0,sessionId:void 0};const n=await $t({canTrack:e}),t=qt({canTrack:e});return{sessionId:n,visitorId:t}},en=async({type:e,canTrack:n,apiKey:t,metadata:o,...i})=>({type:e,data:{...i,metadata:{url:location.href,...o},...await Zt({canTrack:n}),userAttributes:Qt(),ownerId:t}});async function T(e){if(!e.apiKey){console.error("[Builder.io]: Missing API key for track call. Please provide your API key.");return}if(!!e.canTrack&&!b()&&!!(m()||k==="reactNative"))return fetch("https://builder.io/api/v1/track",{method:"POST",body:JSON.stringify({events:[await en(e)]}),headers:{"content-type":"application/json"},mode:"cors"}).catch(n=>{console.error("Failed to track: ",n)})}const tn=e=>T({...e,canTrack:!0}),F={};function me(e,n){let t=F[e];if(t||(t=F[e]=[]),t.push(n),m()){const o={type:"builder.register",data:{type:e,info:n}};try{parent.postMessage(o,"*"),parent!==window&&window.postMessage(o,"*")}catch(i){console.debug("Could not postmessage",i)}}}const nn=()=>{me("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 O=!1;const on=(e={})=>{var n,t;O||(O=!0,m()&&((n=window.parent)==null||n.postMessage({type:"builder.sdkInfo",data:{target:k,supportsPatchUpdates:!1,supportsAddBlockScoping:!0,supportsCustomBreakpoints:!0}},"*"),(t=window.parent)==null||t.postMessage({type:"builder.updateContent",data:{options:e}},"*"),window.addEventListener("message",({data:o})=>{var i,r;if(!!(o!=null&&o.type))switch(o.type){case"builder.evaluate":{const a=o.data.text,l=o.data.arguments||[],c=o.data.id,d=new Function(a);let u,f=null;try{u=d.apply(null,l)}catch(h){f=h}f?(i=window.parent)==null||i.postMessage({type:"builder.evaluateError",data:{id:c,error:f.message}},"*"):u&&typeof u.then=="function"?u.then(h=>{var g;(g=window.parent)==null||g.postMessage({type:"builder.evaluateResult",data:{id:c,result:h}},"*")}).catch(console.error):(r=window.parent)==null||r.postMessage({type:"builder.evaluateResult",data:{result:u,id:c}},"*");break}}})))};function U(e){return Math.round(e*1e3)/1e3}const rn=(e,n,t=!0)=>{if(!(e instanceof HTMLElement))return null;let o=t?e:e.parentElement;do{if(!o)return null;if(n(o))return o}while(o=o.parentElement);return null},sn=e=>rn(e,n=>{const t=n.getAttribute("builder-id")||n.id;return Boolean((t==null?void 0:t.indexOf("builder-"))===0)}),N=({event:e,target:n})=>{const t=n.getBoundingClientRect(),o=e.clientX-t.left,i=e.clientY-t.top,r=U(o/t.width),a=U(i/t.height);return{x:r,y:a}},an=e=>{const n=e.target,t=n&&sn(n),o=(t==null?void 0:t.getAttribute("builder-id"))||(t==null?void 0:t.id);return{targetBuilderElement:o||void 0,metadata:{targetOffset:n?N({event:e,target:n}):void 0,builderTargetOffset:t?N({event:e,target:t}):void 0,builderElementIndex:t&&o?[].slice.call(document.getElementsByClassName(o)).indexOf(t):void 0}}},cn=({content:e,data:n,locale:t})=>{var r,a,l;const o={};(a=(r=e==null?void 0:e.data)==null?void 0:r.inputs)==null||a.forEach(c=>{var d;c.name&&c.defaultValue!==void 0&&((d=e==null?void 0:e.data)==null?void 0:d.state)&&e.data.state[c.name]===void 0&&(o[c.name]=c.defaultValue)});const i={...(l=e==null?void 0:e.data)==null?void 0:l.state,...n,...t?{locale:t}:{}};return{...o,...i}},ln=({content:e,data:n})=>e?{...e,data:{...e==null?void 0:e.data,...n},meta:e==null?void 0:e.meta}:void 0,dn=()=>Promise.resolve().then(()=>q).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",e),e}),un=()=>Promise.resolve().then(()=>require("./render-styles.33387f8f.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",e),e}),mn={name:"render-content",components:{RenderContentStyles:s.defineAsyncComponent(un),RenderBlocks:s.defineAsyncComponent(dn)},props:["content","data","canTrack","locale","customComponents","model","context","apiKey","includeRefs","apiVersion"],data(){return{forceReRenderCount:0,overrideContent:null,useContent:ln({content:this.content,data:this.data}),update:0,canTrackToUse:y(this.canTrack)?this.canTrack:!0,contentState:cn({content:this.content,data:this.data,locale:this.locale}),allRegisteredComponents:[...Ut(),...E,...this.customComponents||[]].reduce((e,n)=>({...e,[n.name]:n}),{}),httpReqsData:{},clicked:!1,TARGET:k}},provide(){const e=this;return{[x.key]:{content:e.useContent,state:e.contentState,setState:e.setContextState,context:e.context||{},apiKey:e.apiKey,apiVersion:e.apiVersion,registeredComponents:e.allRegisteredComponents}}},mounted(){var e,n;if(this.apiKey||console.error("[Builder.io]: No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."),m()){if(b()&&(this.forceReRenderCount=this.forceReRenderCount+1,nn(),on({...this.locale?{locale:this.locale}:{},...this.includeRefs?{includeRefs:this.includeRefs}:{}}),Object.values(this.allRegisteredComponents).forEach(t=>{var i;const o=ae(t);(i=window.parent)==null||i.postMessage(o,"*")}),window.addEventListener("message",this.processMessage),window.addEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate)),this.useContent){const t=(e=this.useContent)==null?void 0:e.testVariationId,o=(n=this.useContent)==null?void 0:n.id;T({type:"impression",canTrack:this.canTrackToUse,contentId:o,apiKey:this.apiKey,variationId:t!==o?t:void 0})}if(se()){const t=new URL(location.href).searchParams,o=t.get("builder.preview"),i=t.get("apiKey")||t.get("builder.space");o===this.model&&i===this.apiKey&&B({model:this.model,apiKey:this.apiKey,apiVersion:this.apiVersion}).then(r=>{r&&this.mergeNewContent(r)})}this.evaluateJsCode(),this.runHttpRequests(),this.emitStateUpdate()}},watch:{onUpdateHook0:{handler(){this.content&&this.mergeNewContent(this.content)},immediate:!0},onUpdateHook1:{handler(){this.evaluateJsCode()},immediate:!0},onUpdateHook2:{handler(){this.runHttpRequests()},immediate:!0},onUpdateHook3:{handler(){this.emitStateUpdate()},immediate:!0}},unmounted(){m()&&(window.removeEventListener("message",this.processMessage),window.removeEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate))},computed:{onUpdateHook0(){return{0:this.content}},onUpdateHook1(){var e,n;return{0:(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.jsCode,1:this.contentState}},onUpdateHook2(){var e,n;return{0:(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.httpRequests}},onUpdateHook3(){return{0:this.contentState}}},methods:{mergeNewContent(e){var n,t,o,i,r;this.useContent={...this.useContent,...e,data:{...(n=this.useContent)==null?void 0:n.data,...e==null?void 0:e.data},meta:{...(t=this.useContent)==null?void 0:t.meta,...e==null?void 0:e.meta,breakpoints:((o=e==null?void 0:e.meta)==null?void 0:o.breakpoints)||((r=(i=this.useContent)==null?void 0:i.meta)==null?void 0:r.breakpoints)}}},setBreakpoints(e){var n;this.useContent={...this.useContent,meta:{...(n=this.useContent)==null?void 0:n.meta,breakpoints:e}}},setContextState(e){this.contentState=e},processMessage(e){var t;const{data:n}=e;if(n)switch(n.type){case"builder.configureSdk":{const o=n.data,{breakpoints:i,contentId:r}=o;if(!r||r!==((t=this.useContent)==null?void 0:t.id))return;i&&this.setBreakpoints(i),this.forceReRenderCount=this.forceReRenderCount+1;break}case"builder.contentUpdate":{const o=n.data,i=o.key||o.alias||o.entry||o.modelName,r=o.data;i===this.model&&(this.mergeNewContent(r),this.forceReRenderCount=this.forceReRenderCount+1);break}}},evaluateJsCode(){var n,t;const e=(t=(n=this.useContent)==null?void 0:n.data)==null?void 0:t.jsCode;e&&I({code:e,context:this.context||{},state:this.contentState})},onClick(e){var n,t;if(this.useContent){const o=(n=this.useContent)==null?void 0:n.testVariationId,i=(t=this.useContent)==null?void 0:t.id;T({type:"click",canTrack:this.canTrackToUse,contentId:i,apiKey:this.apiKey,variationId:o!==i?o:void 0,...an(e),unique:!this.clicked})}this.clicked||(this.clicked=!0)},evalExpression(e){return e.replace(/{{([^}]+)}}/g,(n,t)=>I({code:t,context:this.context||{},state:this.contentState}))},handleRequest({url:e,key:n}){J(e).then(t=>t.json()).then(t=>{const o={...this.contentState,[n]:t};this.setContextState(o)}).catch(t=>{console.log("error fetching dynamic data",e,t)})},runHttpRequests(){var n,t,o;const e=(o=(t=(n=this.useContent)==null?void 0:n.data)==null?void 0:t.httpRequests)!=null?o:{};Object.entries(e).forEach(([i,r])=>{if(r&&(!this.httpReqsData[i]||b())){const a=this.evalExpression(r);this.handleRequest({url:a,key:i})}})},emitStateUpdate(){b()&&window.dispatchEvent(new CustomEvent("builder:component:stateChange",{detail:{state:this.contentState,ref:{name:this.model}}}))}}},pn=["builder-content-id","builder-model"];function hn(e,n,t,o,i,r){var c,d,u,f,h,g,v,A;const a=s.resolveComponent("render-content-styles"),l=s.resolveComponent("render-blocks");return i.useContent?(s.openBlock(),s.createElementBlock("div",{key:0,ref:"elementRef",onClick:n[0]||(n[0]=he=>r.onClick(he)),"builder-content-id":(c=i.useContent)==null?void 0:c.id,"builder-model":t.model},[i.TARGET!=="reactNative"?(s.openBlock(),s.createBlock(a,{key:0,contentId:(d=i.useContent)==null?void 0:d.id,cssCode:(f=(u=i.useContent)==null?void 0:u.data)==null?void 0:f.cssCode,customFonts:(g=(h=i.useContent)==null?void 0:h.data)==null?void 0:g.customFonts},null,8,["contentId","cssCode","customFonts"])):s.createCommentVNode("",!0),(s.openBlock(),s.createBlock(l,{blocks:(A=(v=i.useContent)==null?void 0:v.data)==null?void 0:A.blocks,key:i.forceReRenderCount},null,8,["blocks"]))],8,pn)):s.createCommentVNode("",!0)}const pe=p(mn,[["render",hn]]),fn=Object.freeze(Object.defineProperty({__proto__:null,default:pe},Symbol.toStringTag,{value:"Module"})),W={};function gn(e){if(m()){Object.assign(W,e);const n={type:"builder.settingsChange",data:W};parent.postMessage(n,"*")}}exports.BuilderContext=x;exports.Button=M;exports.Columns=z;exports.Fragment=H;exports.Image=K;exports.Section=G;exports.Symbol=oe;exports.TARGET=k;exports.Text=re;exports.Video=ie;exports._export_sfc=p;exports.checkIsDefined=y;exports.components=E;exports.convertSearchParamsToQueryObject=Z;exports.createRegisterComponentMessage=ae;exports.evaluate=I;exports.fastClone=S;exports.getAllContent=ne;exports.getBuilderSearchParams=ee;exports.getBuilderSearchParamsFromWindow=te;exports.getContent=B;exports.getMaxWidthQueryForSize=ye;exports.getSizesForBreakpoints=$;exports.isEditing=b;exports.isPreviewing=se;exports.normalizeSearchParams=R;exports.register=me;exports.registerComponent=Nt;exports.renderBlocks=D;exports.renderContent=pe;exports.setEditorSettings=gn;exports.track=tn;
|
|
29
|
+
`,c)}}function se(){return!m()||b()?!1:Boolean(location.search.indexOf("builder.preview=")!==-1)}const E=[];function Nt(e,n){return E.push({component:e,...n}),console.warn("registerComponent is deprecated. Use the `customComponents` prop in RenderContent instead to provide your custom components to the builder SDK."),e}const ae=({component:e,...n})=>({type:"builder.registerComponent",data:Mt(n)}),Wt=e=>typeof e=="function"?C(e):S(e),Mt=({inputs:e,...n})=>({...S(n),inputs:e==null?void 0:e.map(t=>Object.entries(t).reduce((o,[i,r])=>({...o,[i]:Wt(r)}),{}))});function Lt(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const n=Math.random()*16|0;return(e=="x"?n:n&3|8).toString(16)})}function ce(){return Lt().replace(/-/g,"")}const le="builderSessionId",$t=async({canTrack:e})=>{if(!e)return;const n=await Y({name:le,canTrack:e});if(y(n))return n;{const t=zt();return Ht({id:t,canTrack:e}),t}},zt=()=>ce(),Ht=({id:e,canTrack:n})=>X({name:le,value:e,canTrack:n}),de=()=>m()&&typeof localStorage<"u"?localStorage:void 0,Kt=({key:e,canTrack:n})=>{var t;try{return n?(t=de())==null?void 0:t.getItem(e):void 0}catch(o){console.debug("[LocalStorage] GET error: ",o);return}},Dt=({key:e,canTrack:n,value:t})=>{var o;try{n&&((o=de())==null||o.setItem(e,t))}catch(i){console.debug("[LocalStorage] SET error: ",i)}},ue="builderVisitorId",qt=({canTrack:e})=>{if(!e)return;const n=Kt({key:ue,canTrack:e});if(y(n))return n;{const t=Gt();return Jt({id:t,canTrack:e}),t}},Gt=()=>ce(),Jt=({id:e,canTrack:n})=>Dt({key:ue,value:e,canTrack:n}),Yt=()=>{if(m()){const e=new URL(location.href);return e.pathname===""&&(e.pathname="/"),e}else return console.warn("Cannot get location for tracking in non-browser environment"),null},Xt=()=>typeof navigator=="object"&&navigator.userAgent||"",Qt=()=>{const e=Xt(),n={Android(){return e.match(/Android/i)},BlackBerry(){return e.match(/BlackBerry/i)},iOS(){return e.match(/iPhone|iPod/i)},Opera(){return e.match(/Opera Mini/i)},Windows(){return e.match(/IEMobile/i)||e.match(/WPDesktop/i)},any(){return n.Android()||n.BlackBerry()||n.iOS()||n.Opera()||n.Windows()||k==="reactNative"}},t=e.match(/Tablet|iPad/i),o=Yt();return{urlPath:o==null?void 0:o.pathname,host:(o==null?void 0:o.host)||(o==null?void 0:o.hostname),device:t?"tablet":n.any()?"mobile":"desktop"}},Zt=async({canTrack:e})=>{if(!e)return{visitorId:void 0,sessionId:void 0};const n=await $t({canTrack:e}),t=qt({canTrack:e});return{sessionId:n,visitorId:t}},en=async({type:e,canTrack:n,apiKey:t,metadata:o,...i})=>({type:e,data:{...i,metadata:{url:location.href,...o},...await Zt({canTrack:n}),userAttributes:Qt(),ownerId:t}});async function T(e){if(!e.apiKey){console.error("[Builder.io]: Missing API key for track call. Please provide your API key.");return}if(!!e.canTrack&&!b()&&!!(m()||k==="reactNative"))return fetch("https://builder.io/api/v1/track",{method:"POST",body:JSON.stringify({events:[await en(e)]}),headers:{"content-type":"application/json"},mode:"cors"}).catch(n=>{console.error("Failed to track: ",n)})}const tn=e=>T({...e,canTrack:!0}),F={};function me(e,n){let t=F[e];if(t||(t=F[e]=[]),t.push(n),m()){const o={type:"builder.register",data:{type:e,info:n}};try{parent.postMessage(o,"*"),parent!==window&&window.postMessage(o,"*")}catch(i){console.debug("Could not postmessage",i)}}}const nn=()=>{me("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 O=!1;const on=(e={})=>{var n,t;O||(O=!0,m()&&((n=window.parent)==null||n.postMessage({type:"builder.sdkInfo",data:{target:k,supportsPatchUpdates:!1,supportsAddBlockScoping:!0,supportsCustomBreakpoints:!0}},"*"),(t=window.parent)==null||t.postMessage({type:"builder.updateContent",data:{options:e}},"*"),window.addEventListener("message",({data:o})=>{var i,r;if(!!(o!=null&&o.type))switch(o.type){case"builder.evaluate":{const a=o.data.text,l=o.data.arguments||[],c=o.data.id,d=new Function(a);let u,f=null;try{u=d.apply(null,l)}catch(h){f=h}f?(i=window.parent)==null||i.postMessage({type:"builder.evaluateError",data:{id:c,error:f.message}},"*"):u&&typeof u.then=="function"?u.then(h=>{var g;(g=window.parent)==null||g.postMessage({type:"builder.evaluateResult",data:{id:c,result:h}},"*")}).catch(console.error):(r=window.parent)==null||r.postMessage({type:"builder.evaluateResult",data:{result:u,id:c}},"*");break}}})))};function U(e){return Math.round(e*1e3)/1e3}const rn=(e,n,t=!0)=>{if(!(e instanceof HTMLElement))return null;let o=t?e:e.parentElement;do{if(!o)return null;if(n(o))return o}while(o=o.parentElement);return null},sn=e=>rn(e,n=>{const t=n.getAttribute("builder-id")||n.id;return Boolean((t==null?void 0:t.indexOf("builder-"))===0)}),N=({event:e,target:n})=>{const t=n.getBoundingClientRect(),o=e.clientX-t.left,i=e.clientY-t.top,r=U(o/t.width),a=U(i/t.height);return{x:r,y:a}},an=e=>{const n=e.target,t=n&&sn(n),o=(t==null?void 0:t.getAttribute("builder-id"))||(t==null?void 0:t.id);return{targetBuilderElement:o||void 0,metadata:{targetOffset:n?N({event:e,target:n}):void 0,builderTargetOffset:t?N({event:e,target:t}):void 0,builderElementIndex:t&&o?[].slice.call(document.getElementsByClassName(o)).indexOf(t):void 0}}},cn=({content:e,data:n,locale:t})=>{var r,a,l;const o={};(a=(r=e==null?void 0:e.data)==null?void 0:r.inputs)==null||a.forEach(c=>{var d;c.name&&c.defaultValue!==void 0&&((d=e==null?void 0:e.data)==null?void 0:d.state)&&e.data.state[c.name]===void 0&&(o[c.name]=c.defaultValue)});const i={...(l=e==null?void 0:e.data)==null?void 0:l.state,...n,...t?{locale:t}:{}};return{...o,...i}},ln=({content:e,data:n})=>e?{...e,data:{...e==null?void 0:e.data,...n},meta:e==null?void 0:e.meta}:void 0,dn=()=>Promise.resolve().then(()=>q).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",e),e}),un=()=>Promise.resolve().then(()=>require("./render-styles.c70124f9.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",e),e}),mn={name:"render-content",components:{RenderContentStyles:s.defineAsyncComponent(un),RenderBlocks:s.defineAsyncComponent(dn)},props:["content","data","canTrack","locale","customComponents","model","context","apiKey","includeRefs","apiVersion"],data(){return{forceReRenderCount:0,overrideContent:null,useContent:ln({content:this.content,data:this.data}),update:0,canTrackToUse:y(this.canTrack)?this.canTrack:!0,contentState:cn({content:this.content,data:this.data,locale:this.locale}),allRegisteredComponents:[...Ut(),...E,...this.customComponents||[]].reduce((e,n)=>({...e,[n.name]:n}),{}),httpReqsData:{},clicked:!1,TARGET:k}},provide(){const e=this;return{[x.key]:{content:e.useContent,state:e.contentState,setState:e.setContextState,context:e.context||{},apiKey:e.apiKey,apiVersion:e.apiVersion,registeredComponents:e.allRegisteredComponents}}},mounted(){var e,n;if(this.apiKey||console.error("[Builder.io]: No API key provided to `RenderContent` component. This can cause issues. Please provide an API key using the `apiKey` prop."),m()){if(b()&&(this.forceReRenderCount=this.forceReRenderCount+1,nn(),on({...this.locale?{locale:this.locale}:{},...this.includeRefs?{includeRefs:this.includeRefs}:{}}),Object.values(this.allRegisteredComponents).forEach(t=>{var i;const o=ae(t);(i=window.parent)==null||i.postMessage(o,"*")}),window.addEventListener("message",this.processMessage),window.addEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate)),this.useContent){const t=(e=this.useContent)==null?void 0:e.testVariationId,o=(n=this.useContent)==null?void 0:n.id;T({type:"impression",canTrack:this.canTrackToUse,contentId:o,apiKey:this.apiKey,variationId:t!==o?t:void 0})}if(se()){const t=new URL(location.href).searchParams,o=t.get("builder.preview"),i=t.get("apiKey")||t.get("builder.space");o===this.model&&i===this.apiKey&&B({model:this.model,apiKey:this.apiKey,apiVersion:this.apiVersion}).then(r=>{r&&this.mergeNewContent(r)})}this.evaluateJsCode(),this.runHttpRequests(),this.emitStateUpdate()}},watch:{onUpdateHook0:{handler(){this.content&&this.mergeNewContent(this.content)},immediate:!0},onUpdateHook1:{handler(){this.evaluateJsCode()},immediate:!0},onUpdateHook2:{handler(){this.runHttpRequests()},immediate:!0},onUpdateHook3:{handler(){this.emitStateUpdate()},immediate:!0}},unmounted(){m()&&(window.removeEventListener("message",this.processMessage),window.removeEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate))},computed:{onUpdateHook0(){return{0:this.content}},onUpdateHook1(){var e,n;return{0:(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.jsCode,1:this.contentState}},onUpdateHook2(){var e,n;return{0:(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.httpRequests}},onUpdateHook3(){return{0:this.contentState}}},methods:{mergeNewContent(e){var n,t,o,i,r;this.useContent={...this.useContent,...e,data:{...(n=this.useContent)==null?void 0:n.data,...e==null?void 0:e.data},meta:{...(t=this.useContent)==null?void 0:t.meta,...e==null?void 0:e.meta,breakpoints:((o=e==null?void 0:e.meta)==null?void 0:o.breakpoints)||((r=(i=this.useContent)==null?void 0:i.meta)==null?void 0:r.breakpoints)}}},setBreakpoints(e){var n;this.useContent={...this.useContent,meta:{...(n=this.useContent)==null?void 0:n.meta,breakpoints:e}}},setContextState(e){this.contentState=e},processMessage(e){var t;const{data:n}=e;if(n)switch(n.type){case"builder.configureSdk":{const o=n.data,{breakpoints:i,contentId:r}=o;if(!r||r!==((t=this.useContent)==null?void 0:t.id))return;i&&this.setBreakpoints(i),this.forceReRenderCount=this.forceReRenderCount+1;break}case"builder.contentUpdate":{const o=n.data,i=o.key||o.alias||o.entry||o.modelName,r=o.data;i===this.model&&(this.mergeNewContent(r),this.forceReRenderCount=this.forceReRenderCount+1);break}}},evaluateJsCode(){var n,t;const e=(t=(n=this.useContent)==null?void 0:n.data)==null?void 0:t.jsCode;e&&I({code:e,context:this.context||{},state:this.contentState})},onClick(e){var n,t;if(this.useContent){const o=(n=this.useContent)==null?void 0:n.testVariationId,i=(t=this.useContent)==null?void 0:t.id;T({type:"click",canTrack:this.canTrackToUse,contentId:i,apiKey:this.apiKey,variationId:o!==i?o:void 0,...an(e),unique:!this.clicked})}this.clicked||(this.clicked=!0)},evalExpression(e){return e.replace(/{{([^}]+)}}/g,(n,t)=>I({code:t,context:this.context||{},state:this.contentState}))},handleRequest({url:e,key:n}){J(e).then(t=>t.json()).then(t=>{const o={...this.contentState,[n]:t};this.setContextState(o)}).catch(t=>{console.log("error fetching dynamic data",e,t)})},runHttpRequests(){var n,t,o;const e=(o=(t=(n=this.useContent)==null?void 0:n.data)==null?void 0:t.httpRequests)!=null?o:{};Object.entries(e).forEach(([i,r])=>{if(r&&(!this.httpReqsData[i]||b())){const a=this.evalExpression(r);this.handleRequest({url:a,key:i})}})},emitStateUpdate(){b()&&window.dispatchEvent(new CustomEvent("builder:component:stateChange",{detail:{state:this.contentState,ref:{name:this.model}}}))}}},pn=["builder-content-id","builder-model"];function hn(e,n,t,o,i,r){var c,d,u,f,h,g,v,A;const a=s.resolveComponent("render-content-styles"),l=s.resolveComponent("render-blocks");return i.useContent?(s.openBlock(),s.createElementBlock("div",{key:0,ref:"elementRef",onClick:n[0]||(n[0]=he=>r.onClick(he)),"builder-content-id":(c=i.useContent)==null?void 0:c.id,"builder-model":t.model},[i.TARGET!=="reactNative"?(s.openBlock(),s.createBlock(a,{key:0,contentId:(d=i.useContent)==null?void 0:d.id,cssCode:(f=(u=i.useContent)==null?void 0:u.data)==null?void 0:f.cssCode,customFonts:(g=(h=i.useContent)==null?void 0:h.data)==null?void 0:g.customFonts},null,8,["contentId","cssCode","customFonts"])):s.createCommentVNode("",!0),(s.openBlock(),s.createBlock(l,{blocks:(A=(v=i.useContent)==null?void 0:v.data)==null?void 0:A.blocks,key:i.forceReRenderCount},null,8,["blocks"]))],8,pn)):s.createCommentVNode("",!0)}const pe=p(mn,[["render",hn]]),fn=Object.freeze(Object.defineProperty({__proto__:null,default:pe},Symbol.toStringTag,{value:"Module"})),W={};function gn(e){if(m()){Object.assign(W,e);const n={type:"builder.settingsChange",data:W};parent.postMessage(n,"*")}}exports.BuilderContext=x;exports.Button=M;exports.Columns=z;exports.Fragment=H;exports.Image=K;exports.Section=G;exports.Symbol=oe;exports.TARGET=k;exports.Text=re;exports.Video=ie;exports._export_sfc=p;exports.checkIsDefined=y;exports.components=E;exports.convertSearchParamsToQueryObject=Z;exports.createRegisterComponentMessage=ae;exports.evaluate=I;exports.fastClone=S;exports.getAllContent=ne;exports.getBuilderSearchParams=ee;exports.getBuilderSearchParamsFromWindow=te;exports.getContent=B;exports.getMaxWidthQueryForSize=ye;exports.getSizesForBreakpoints=$;exports.isEditing=b;exports.isPreviewing=se;exports.normalizeSearchParams=R;exports.register=me;exports.registerComponent=Nt;exports.renderBlocks=D;exports.renderContent=pe;exports.setEditorSettings=gn;exports.track=tn;
|
|
@@ -91,7 +91,7 @@ const fe = /* @__PURE__ */ h(me, [["render", he], ["__scopeId", "data-v-28c9cee7
|
|
|
91
91
|
"Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",
|
|
92
92
|
e
|
|
93
93
|
), e;
|
|
94
|
-
}), ve = () => import("./render-inlined-styles.
|
|
94
|
+
}), ve = () => import("./render-inlined-styles.799a72a2.js").then((e) => e.default).catch((e) => {
|
|
95
95
|
throw console.error(
|
|
96
96
|
"Error while attempting to dynamically import component RenderInlinedStyles at ../../components/render-inlined-styles.vue",
|
|
97
97
|
e
|
|
@@ -175,7 +175,7 @@ const fe = /* @__PURE__ */ h(me, [["render", he], ["__scopeId", "data-v-28c9cee7
|
|
|
175
175
|
return this.stackAt === "never" ? n : e;
|
|
176
176
|
},
|
|
177
177
|
columnCssVars(e) {
|
|
178
|
-
const n = this.getColumnCssWidth(e), t = `${e === 0 ? 0 : this.gutterSize}px`, o = "100%", s =
|
|
178
|
+
const n = this.getColumnCssWidth(e), t = `${e === 0 ? 0 : this.gutterSize}px`, o = "100%", s = 0;
|
|
179
179
|
return {
|
|
180
180
|
width: n,
|
|
181
181
|
"margin-left": t,
|
|
@@ -250,7 +250,7 @@ function ke(e, n, t, o, s, i) {
|
|
|
250
250
|
], 4))), 128))
|
|
251
251
|
], 6);
|
|
252
252
|
}
|
|
253
|
-
const Se = /* @__PURE__ */ h(xe, [["render", ke], ["__scopeId", "data-v-
|
|
253
|
+
const Se = /* @__PURE__ */ h(xe, [["render", ke], ["__scopeId", "data-v-ea0f5889"]]), _e = {
|
|
254
254
|
name: "builder-fragment-component",
|
|
255
255
|
props: []
|
|
256
256
|
};
|
|
@@ -403,12 +403,12 @@ function Fe() {
|
|
|
403
403
|
function v() {
|
|
404
404
|
return Fe() && window.location.search.indexOf("builder.frameEditing=") !== -1;
|
|
405
405
|
}
|
|
406
|
-
const Pe = () => import("./block-styles.
|
|
406
|
+
const Pe = () => import("./block-styles.6bad6a44.js").then((e) => e.default).catch((e) => {
|
|
407
407
|
throw console.error(
|
|
408
408
|
"Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",
|
|
409
409
|
e
|
|
410
410
|
), e;
|
|
411
|
-
}), Oe = () => import("./render-block.
|
|
411
|
+
}), Oe = () => import("./render-block.55844e87.js").then((e) => e.default).catch((e) => {
|
|
412
412
|
throw console.error(
|
|
413
413
|
"Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",
|
|
414
414
|
e
|
|
@@ -2130,7 +2130,7 @@ const gn = (e, n, t = !0) => {
|
|
|
2130
2130
|
"Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",
|
|
2131
2131
|
e
|
|
2132
2132
|
), e;
|
|
2133
|
-
}), Sn = () => import("./render-styles.
|
|
2133
|
+
}), Sn = () => import("./render-styles.6ed62c76.js").then((e) => e.default).catch((e) => {
|
|
2134
2134
|
throw console.error(
|
|
2135
2135
|
"Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",
|
|
2136
2136
|
e
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineAsyncComponent as f, resolveComponent as h, openBlock as s, createElementBlock as l, Fragment as u, createBlock as a, resolveDynamicComponent as C, mergeProps as b, toHandlers as v, createCommentVNode as k, renderList as g, withCtx as P, createVNode as R, normalizeProps as _, guardReactiveProps as I } from "vue";
|
|
2
|
-
import { e as S, T as A, c as E, _ as O } from "./index.
|
|
3
|
-
import { a as T, g as w } from "./css.
|
|
2
|
+
import { e as S, T as A, c as E, _ as O } from "./index.77da28db.js";
|
|
3
|
+
import { a as T, g as w } from "./css.162effaf.js";
|
|
4
4
|
const N = (e) => `v-on:${e.toLowerCase()}`, D = (e, t) => (n) => S({
|
|
5
5
|
code: e,
|
|
6
6
|
context: t.context,
|
|
@@ -129,17 +129,17 @@ const q = [
|
|
|
129
129
|
},
|
|
130
130
|
block: c
|
|
131
131
|
}));
|
|
132
|
-
}, U = () => import("./block-styles.
|
|
132
|
+
}, U = () => import("./block-styles.6bad6a44.js").then((e) => e.default).catch((e) => {
|
|
133
133
|
throw console.error(
|
|
134
134
|
"Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",
|
|
135
135
|
e
|
|
136
136
|
), e;
|
|
137
|
-
}), Y = () => import("./render-repeated-block.
|
|
137
|
+
}), Y = () => import("./render-repeated-block.3650cb4b.js").then((e) => e.default).catch((e) => {
|
|
138
138
|
throw console.error(
|
|
139
139
|
"Error while attempting to dynamically import component RenderRepeatedBlock at ./render-repeated-block.vue",
|
|
140
140
|
e
|
|
141
141
|
), e;
|
|
142
|
-
}), J = () => import("./render-component.
|
|
142
|
+
}), J = () => import("./render-component.445bfcc5.js").then((e) => e.default).catch((e) => {
|
|
143
143
|
throw console.error(
|
|
144
144
|
"Error while attempting to dynamically import component RenderComponent at ./render-component.vue",
|
|
145
145
|
e
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),i=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),i=require("./index.51c251ae.cjs"),k=require("./css.9c26446d.cjs"),y=e=>`v-on:${e.toLowerCase()}`,f=(e,n)=>o=>i.evaluate({code:e,context:n.context,state:n.state,event:o,isExpression:!1});function x(e){var s;const n={},o=(s=e.block.actions)!=null?s:{};for(const c in o){if(!o.hasOwnProperty(c))continue;const r=o[c];n[y(c)]=f(r,e)}return n}function B(e){var n;return{...(n=e.component)==null?void 0:n.options,...e.options,builderBlock:e}}function b(e){const n={};if(typeof e!="string")return n;const o=e.trim().split(/\\s+/);for(const s of o)n[s]=!0;return n}function g(e){return e.class=b(e.class),e}function C(e){var o;const n={...e.properties,"builder-id":e.id,style:v(e.style),class:[e.id,"builder-block",e.class,(o=e.properties)==null?void 0:o.class].filter(Boolean).join(" ")};return g(n)}function v(e){if(!!e)switch(i.TARGET){case"svelte":case"vue2":case"vue3":case"solid":return k.convertStyleMapToCSSArray(e).join(" ");case"qwik":case"reactNative":case"react":return e}}function P(e){return e.tagName||"div"}const E=["area","base","br","col","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],_=e=>typeof e=="string"&&E.includes(e.toLowerCase()),S=({block:e,context:n})=>{var c;const o=(c=k.getProcessedBlock({block:e,state:n.state,context:n.context,shouldEvaluateBindings:!1}).component)==null?void 0:c.name;if(!o)return null;const s=n.registeredComponents[o];if(s)return s;console.warn(`
|
|
2
2
|
Could not find a registered component named "${o}".
|
|
3
|
-
If you registered it, is the file that registered it imported by the file that needs to render it?`)},w=({block:e,context:n})=>{const{repeat:o,...s}=e;if(!(o!=null&&o.collection))return;const c=i.evaluate({code:o.collection,state:n.state,context:n.context});if(!Array.isArray(c))return;const r=o.collection.split(".").pop(),a=o.itemName||(r?r+"Item":"item");return c.map((u,m)=>({context:{...n,state:{...n.state,$index:m,$item:u,[a]:u,[`$${a}Index`]:m}},block:s}))},R=()=>Promise.resolve().then(()=>require("./block-styles.
|
|
3
|
+
If you registered it, is the file that registered it imported by the file that needs to render it?`)},w=({block:e,context:n})=>{const{repeat:o,...s}=e;if(!(o!=null&&o.collection))return;const c=i.evaluate({code:o.collection,state:n.state,context:n.context});if(!Array.isArray(c))return;const r=o.collection.split(".").pop(),a=o.itemName||(r?r+"Item":"item");return c.map((u,m)=>({context:{...n,state:{...n.state,$index:m,$item:u,[a]:u,[`$${a}Index`]:m}},block:s}))},R=()=>Promise.resolve().then(()=>require("./block-styles.c334abc4.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",e),e}),A=()=>Promise.resolve().then(()=>require("./render-repeated-block.9f7871c0.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderRepeatedBlock at ./render-repeated-block.vue",e),e}),I=()=>Promise.resolve().then(()=>require("./render-component.a3596f45.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderComponent at ./render-component.vue",e),e}),N={name:"render-block",components:{RenderComponent:t.defineAsyncComponent(I),RenderRepeatedBlock:t.defineAsyncComponent(A),BlockStyles:t.defineAsyncComponent(R)},props:["block","context"],data(){return{component:S({block:this.block,context:this.context}),repeatItemData:w({block:this.block,context:this.context}),isEmptyHtmlElement:_}},computed:{tag(){return P(this.useBlock)},useBlock(){return this.repeatItemData?this.block:k.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!0})},canShowBlock(){return i.checkIsDefined(this.useBlock.hide)?!this.useBlock.hide:i.checkIsDefined(this.useBlock.show)?this.useBlock.show:!0},proxyState(){return typeof Proxy>"u"?(console.error("no Proxy available in this environment, cannot proxy state."),this.context.state):new Proxy(this.context.state,{set:(n,o,s)=>{var c,r;return n[o]=s,(r=(c=this.context).setState)==null||r.call(c,n),!0}})},actions(){return x({block:this.useBlock,state:this.proxyState,context:this.context.context})},attributes(){return{...C(this.useBlock)}},renderComponentProps(){var e,n,o;return{blockChildren:(e=this.useBlock.children)!=null?e:[],componentRef:(n=this.component)==null?void 0:n.component,componentOptions:{...B(this.useBlock),...(o=this.component)!=null&&o.noWrap?{attributes:{...this.attributes,...this.actions}}:{}},context:this.childrenContext}},childrenWithoutParentComponent(){var n,o;return!((n=this.component)!=null&&n.component)&&!this.repeatItemData?(o=this.useBlock.children)!=null?o:[]:[]},childrenContext(){const e=()=>({});return{apiKey:this.context.apiKey,state:this.context.state,content:this.context.content,context:this.context.context,setState:this.context.setState,registeredComponents:this.context.registeredComponents,inheritedStyles:e()}}},methods:{stripVOn:function(n={}){return Object.keys(n).reduce((o,s)=>({...o,[s.replace("v-on:","")]:n[s]}),{})}}};function O(e,n,o,s,c,r){var h;const a=t.resolveComponent("render-repeated-block"),p=t.resolveComponent("render-component"),u=t.resolveComponent("render-block",!0),m=t.resolveComponent("block-styles");return r.canShowBlock?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[(h=c.component)!=null&&h.noWrap?(t.openBlock(),t.createBlock(p,t.normalizeProps(t.mergeProps({key:1},r.renderComponentProps)),null,16)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[c.isEmptyHtmlElement(r.tag)?(t.openBlock(),t.createBlock(t.resolveDynamicComponent(r.tag),t.mergeProps({key:0},r.attributes,t.toHandlers(r.stripVOn(r.actions))),null,16)):t.createCommentVNode("",!0),!c.isEmptyHtmlElement(r.tag)&&c.repeatItemData?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(c.repeatItemData,(l,d)=>(t.openBlock(),t.createBlock(a,{key:d,repeatContext:l.context,block:l.block},null,8,["repeatContext","block"]))),128)):t.createCommentVNode("",!0),!c.isEmptyHtmlElement(r.tag)&&!c.repeatItemData?(t.openBlock(),t.createBlock(t.resolveDynamicComponent(r.tag),t.mergeProps({key:2},r.attributes,t.toHandlers(r.stripVOn(r.actions))),{default:t.withCtx(()=>[t.createVNode(p,t.normalizeProps(t.guardReactiveProps(r.renderComponentProps)),null,16),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.childrenWithoutParentComponent,(l,d)=>(t.openBlock(),t.createBlock(u,{key:"render-block-"+l.id,block:l,context:r.childrenContext},null,8,["block","context"]))),128)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.childrenWithoutParentComponent,(l,d)=>(t.openBlock(),t.createBlock(m,{key:"block-style-"+l.id,block:l,context:r.childrenContext},null,8,["block","context"]))),128))]),_:1},16)):t.createCommentVNode("",!0)],64))],64)):t.createCommentVNode("",!0)}const j=i._export_sfc(N,[["render",O]]);exports.default=j;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { defineAsyncComponent as r, resolveComponent as l, openBlock as n, createBlock as c, resolveDynamicComponent as p, normalizeProps as u, mergeProps as y, withCtx as _, createElementBlock as m, Fragment as s, renderList as a, createCommentVNode as b } from "vue";
|
|
2
|
-
import { _ as f } from "./index.
|
|
3
|
-
const x = () => import("./block-styles.
|
|
2
|
+
import { _ as f } from "./index.77da28db.js";
|
|
3
|
+
const x = () => import("./block-styles.6bad6a44.js").then((e) => e.default).catch((e) => {
|
|
4
4
|
throw console.error(
|
|
5
5
|
"Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",
|
|
6
6
|
e
|
|
7
7
|
), e;
|
|
8
|
-
}), h = () => import("./render-block.
|
|
8
|
+
}), h = () => import("./render-block.55844e87.js").then((e) => e.default).catch((e) => {
|
|
9
9
|
throw console.error(
|
|
10
10
|
"Error while attempting to dynamically import component RenderBlock at ./render-block.vue",
|
|
11
11
|
e
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),s=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),s=require("./index.51c251ae.cjs"),m=()=>Promise.resolve().then(()=>require("./block-styles.c334abc4.cjs")).then(o=>o.default).catch(o=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",o),o}),i=()=>Promise.resolve().then(()=>require("./render-block.75044288.cjs")).then(o=>o.default).catch(o=>{throw console.error("Error while attempting to dynamically import component RenderBlock at ./render-block.vue",o),o}),k={name:"render-component",components:{RenderBlock:e.defineAsyncComponent(i),BlockStyles:e.defineAsyncComponent(m)},props:["componentRef","componentOptions","blockChildren","context"]};function a(o,u,n,p,b,y){const c=e.resolveComponent("render-block"),r=e.resolveComponent("block-styles");return n.componentRef?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.componentRef),e.normalizeProps(e.mergeProps({key:0},n.componentOptions)),{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.blockChildren,(t,l)=>(e.openBlock(),e.createBlock(c,{key:"render-block-"+t.id,block:t,context:n.context},null,8,["block","context"]))),128)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.blockChildren,(t,l)=>(e.openBlock(),e.createBlock(r,{key:"block-style-"+t.id,block:t,context:n.context},null,8,["block","context"]))),128))]),_:1},16)):e.createCommentVNode("",!0)}const d=s._export_sfc(k,[["render",a]]);exports.default=d;
|
package/packages/_vue3/dist/{render-inlined-styles.9f82189a.js → render-inlined-styles.799a72a2.js}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { openBlock as n, createBlock as s, resolveDynamicComponent as l, withCtx as i, createTextVNode as a, toDisplayString as c } from "vue";
|
|
2
|
-
import { T as o, _ as y } from "./index.
|
|
2
|
+
import { T as o, _ as y } from "./index.77da28db.js";
|
|
3
3
|
const d = {
|
|
4
4
|
name: "render-inlined-styles",
|
|
5
5
|
props: ["styles"],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),s=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),s=require("./index.51c251ae.cjs"),c={name:"render-inlined-styles",props:["styles"],data(){return{TARGET:s.TARGET}},computed:{injectedStyleScript(){return`<${this.tag}>${this.styles}</${this.tag}>`},tag(){return"style"}}};function l(o,a,t,u,n,r){return n.TARGET==="svelte"||n.TARGET==="qwik"?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.tag),{key:0,innerHTML:t.styles},null,8,["innerHTML"])):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.tag),{key:1},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.styles),1)]),_:1}))}const i=s._export_sfc(c,[["render",l]]);exports.default=i;
|
package/packages/_vue3/dist/{render-repeated-block.86e8e344.js → render-repeated-block.3650cb4b.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineAsyncComponent as n, resolveComponent as r, openBlock as c, createBlock as a } from "vue";
|
|
2
|
-
import { B as p, _ as s } from "./index.
|
|
3
|
-
const l = () => import("./render-block.
|
|
2
|
+
import { B as p, _ as s } from "./index.77da28db.js";
|
|
3
|
+
const l = () => import("./render-block.55844e87.js").then((e) => e.default).catch((e) => {
|
|
4
4
|
throw console.error(
|
|
5
5
|
"Error while attempting to dynamically import component RenderBlock at ./render-block.vue",
|
|
6
6
|
e
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),o=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),o=require("./index.51c251ae.cjs"),c=()=>Promise.resolve().then(()=>require("./render-block.75044288.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlock at ./render-block.vue",e),e}),s={name:"render-repeated-block",components:{RenderBlock:t.defineAsyncComponent(c)},props:["block","repeatContext"],provide(){const e=this;return{[o.BuilderContext.key]:{content:e.repeatContext.content,state:e.repeatContext.state,setState:e.repeatContext.setState,context:e.repeatContext.context,apiKey:e.repeatContext.apiKey,registeredComponents:e.repeatContext.registeredComponents,inheritedStyles:e.repeatContext.inheritedStyles}}}};function a(e,i,n,d,p,x){const r=t.resolveComponent("render-block");return t.openBlock(),t.createBlock(r,{block:n.block,context:n.repeatContext},null,8,["block","context"])}const l=o._export_sfc(s,[["render",a]]);exports.default=l;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineAsyncComponent as a, resolveComponent as f, openBlock as d, createBlock as p } from "vue";
|
|
2
|
-
import { _ as m } from "./index.
|
|
2
|
+
import { _ as m } from "./index.77da28db.js";
|
|
3
3
|
const u = (e) => {
|
|
4
4
|
var o, l;
|
|
5
5
|
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], r = (l = e.fileUrl) != null ? l : (o = e == null ? void 0 : e.files) == null ? void 0 : o.regular;
|
|
@@ -32,7 +32,7 @@ font-weight: ${s};
|
|
|
32
32
|
}, y = ({
|
|
33
33
|
cssCode: e,
|
|
34
34
|
contentId: t
|
|
35
|
-
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", g = () => import("./render-inlined-styles.
|
|
35
|
+
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", g = () => import("./render-inlined-styles.799a72a2.js").then((e) => e.default).catch((e) => {
|
|
36
36
|
throw console.error(
|
|
37
37
|
"Error while attempting to dynamically import component RenderInlinedStyles at ../../render-inlined-styles.vue",
|
|
38
38
|
e
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),d=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),d=require("./index.51c251ae.cjs"),f=e=>{var c,l;const t=e.family+(e.kind&&!e.kind.includes("#")?", "+e.kind:""),n=t.split(",")[0],r=(l=e.fileUrl)!=null?l:(c=e==null?void 0:e.files)==null?void 0:c.regular;let i="";if(r&&t&&n&&(i+=`
|
|
2
2
|
@font-face {
|
|
3
3
|
font-family: "${t}";
|
|
4
4
|
src: local("${n}"), url('${r}') format('woff2');
|
|
@@ -12,7 +12,7 @@ src: url('${a}') format('woff2');
|
|
|
12
12
|
font-display: fallback;
|
|
13
13
|
font-weight: ${s};
|
|
14
14
|
}
|
|
15
|
-
`.trim())}return i},u=({customFonts:e})=>{var t;return((t=e==null?void 0:e.map(n=>f(n)))==null?void 0:t.join(" "))||""},p=({cssCode:e,contentId:t})=>e?t?(e==null?void 0:e.replace(/&/g,`div[builder-content-id="${t}"]`))||"":e:"",m=()=>Promise.resolve().then(()=>require("./render-inlined-styles.
|
|
15
|
+
`.trim())}return i},u=({customFonts:e})=>{var t;return((t=e==null?void 0:e.map(n=>f(n)))==null?void 0:t.join(" "))||""},p=({cssCode:e,contentId:t})=>e?t?(e==null?void 0:e.replace(/&/g,`div[builder-content-id="${t}"]`))||"":e:"",m=()=>Promise.resolve().then(()=>require("./render-inlined-styles.a41845aa.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderInlinedStyles at ../../render-inlined-styles.vue",e),e}),y={name:"render-content-styles",components:{RenderInlinedStyles:o.defineAsyncComponent(m)},props:["cssCode","contentId","customFonts"],data(){return{injectedStyles:`
|
|
16
16
|
${p({cssCode:this.cssCode,contentId:this.contentId})}
|
|
17
17
|
${u({customFonts:this.customFonts})}
|
|
18
18
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./index.
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./index.51c251ae.cjs");require("vue");exports.Button=e.Button;exports.Columns=e.Columns;exports.Fragment=e.Fragment;exports.Image=e.Image;exports.RenderBlocks=e.renderBlocks;exports.RenderContent=e.renderContent;exports.Section=e.Section;exports.Symbol=e.Symbol;exports.Text=e.Text;exports.Video=e.Video;exports.components=e.components;exports.convertSearchParamsToQueryObject=e.convertSearchParamsToQueryObject;exports.createRegisterComponentMessage=e.createRegisterComponentMessage;exports.getAllContent=e.getAllContent;exports.getBuilderSearchParams=e.getBuilderSearchParams;exports.getBuilderSearchParamsFromWindow=e.getBuilderSearchParamsFromWindow;exports.getContent=e.getContent;exports.isEditing=e.isEditing;exports.isPreviewing=e.isPreviewing;exports.normalizeSearchParams=e.normalizeSearchParams;exports.register=e.register;exports.registerComponent=e.registerComponent;exports.setEditorSettings=e.setEditorSettings;exports.track=e.track;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { b as t, C as r, F as n, I as o, r as i, d as m, S as g, h as c, i as d, V as l, l as S, u as C, n as p, q as u, v as h, w as P, p as B, j as b, k, x as v, o as w, m as x, s as F, t as R } from "./index.
|
|
1
|
+
import { b as t, C as r, F as n, I as o, r as i, d as m, S as g, h as c, i as d, V as l, l as S, u as C, n as p, q as u, v as h, w as P, p as B, j as b, k, x as v, o as w, m as x, s as F, t as R } from "./index.77da28db.js";
|
|
2
2
|
import "vue";
|
|
3
3
|
export {
|
|
4
4
|
t as Button,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.button-1yj9n7yt24z[data-v-28c9cee7]{all:unset}.div-361b1o6wv2k[data-v-
|
|
1
|
+
.button-1yj9n7yt24z[data-v-28c9cee7]{all:unset}.div-361b1o6wv2k[data-v-ea0f5889]{display:flex;line-height:normal}.div-361b1o6wv2k-2[data-v-ea0f5889]{display:flex;flex-direction:column;align-items:stretch}.img-7jvpanrlkn[data-v-22833d9f]{opacity:1;transition:opacity .2s ease-in-out}.div-7jvpanrlkn[data-v-22833d9f]{width:100%;pointer-events:none;font-size:0}.div-7jvpanrlkn-2[data-v-22833d9f]{display:flex;flex-direction:column;align-items:stretch;position:absolute;top:0;left:0;width:100%;height:100%}.div-7fq9d0i380[data-v-1112d180]{display:flex;flex-direction:column;align-items:stretch}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
"use strict";const i=require("./index.cbc06228.cjs"),l=(e,t,r)=>{if(Object(e)!==e)return e;const s=Array.isArray(t)?t:t.toString().match(/[^.[\]]+/g);return s.slice(0,-1).reduce((n,c,o)=>Object(n[c])===n[c]?n[c]:n[c]=Math.abs(Number(s[o+1]))>>0===+s[o+1]?[]:{},e)[s[s.length-1]]=r,e};const d=({block:e,context:t,state:r})=>{if(!e.bindings)return e;const s=i.fastClone(e),n={...s,properties:{...s.properties},actions:{...s.actions}};for(const c in e.bindings){const o=e.bindings[c],u=i.evaluate({code:o,state:r,context:t});l(n,c,u)}return n};function f({block:e,context:t,shouldEvaluateBindings:r,state:s}){const n=e;return r?d({block:n,state:s,context:t}):n}const p=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),a=e=>Object.entries(e).map(([r,s])=>{if(typeof s=="string")return`${p(r)}: ${s};`}).filter(i.checkIsDefined),g=e=>a(e).join(`
|
|
2
|
-
`),C=({mediaQuery:e,className:t,styles:r})=>{const s=`.${t} {
|
|
3
|
-
${g(r)}
|
|
4
|
-
}`;return e?`${e} {
|
|
5
|
-
${s}
|
|
6
|
-
}`:s};exports.convertStyleMapToCSSArray=a;exports.createCssClass=C;exports.getProcessedBlock=f;
|