@builder.io/sdk-vue 0.0.5 → 0.0.7
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.14e01ebb.cjs +1 -0
- package/packages/_vue2/dist/block-styles.4a6d4454.js +64 -0
- package/packages/_vue2/dist/{get-processed-block.50c3959c.cjs → get-processed-block.60a0851d.cjs} +1 -1
- package/packages/{_vue3/dist/get-processed-block.9bb2fd8e.js → _vue2/dist/get-processed-block.a1509eaa.js} +1 -1
- package/packages/_vue2/dist/{index.7a7ff238.js → index.12321644.js} +610 -395
- package/packages/_vue2/dist/index.2202f0aa.cjs +29 -0
- package/packages/_vue2/dist/{render-block.7635a885.js → render-block.478d4b37.js} +77 -56
- package/packages/_vue2/dist/render-block.51134fca.cjs +3 -0
- package/packages/_vue2/dist/{render-component-with-context.f56ece1d.js → render-component-with-context.4a307a33.js} +2 -2
- package/packages/_vue2/dist/{render-component-with-context.95834dc3.cjs → render-component-with-context.e823d5d7.cjs} +1 -1
- package/packages/_vue2/dist/{render-component.c352f53d.js → render-component.1c886638.js} +3 -3
- package/packages/_vue2/dist/{render-component.1f139db7.cjs → render-component.fe614b72.cjs} +1 -1
- package/packages/_vue2/dist/{render-inlined-styles.a6d217ba.js → render-inlined-styles.976a3c9e.js} +1 -1
- package/packages/_vue2/dist/{render-inlined-styles.82edc9e3.cjs → render-inlined-styles.e5b335e1.cjs} +1 -1
- package/packages/_vue2/dist/{render-repeated-block.8b8babc7.cjs → render-repeated-block.b11f76de.cjs} +1 -1
- package/packages/_vue2/dist/{render-repeated-block.7e988491.js → render-repeated-block.c2bc657c.js} +2 -2
- package/packages/_vue2/dist/{render-styles.6bcf5051.cjs → render-styles.a0f5973e.cjs} +1 -1
- package/packages/_vue2/dist/{render-styles.0fcd6636.js → render-styles.c1e07776.js} +2 -2
- package/packages/_vue2/dist/sdk.cjs +1 -1
- package/packages/_vue2/dist/sdk.js +10 -10
- package/packages/_vue2/dist/src/blocks/columns/columns.vue.d.ts +44 -0
- package/packages/_vue2/dist/src/blocks/symbol/symbol.vue.d.ts +3 -1
- package/packages/_vue2/dist/src/components/render-block/render-block.vue.d.ts +1 -0
- package/packages/_vue2/dist/src/components/render-block/render-component-with-context.vue.d.ts +1 -0
- package/packages/_vue2/dist/src/components/render-block/render-component.vue.d.ts +3 -0
- package/packages/_vue2/dist/src/components/render-block/render-repeated-block.vue.d.ts +1 -0
- package/packages/_vue2/dist/src/components/render-blocks.vue.d.ts +1 -0
- package/packages/_vue2/dist/src/components/render-content/render-content.vue.d.ts +4 -0
- package/packages/_vue2/dist/src/functions/evaluate.d.ts +2 -1
- package/packages/_vue2/dist/src/functions/get-block-actions-handler.d.ts +5 -2
- package/packages/_vue2/dist/src/functions/get-block-properties.d.ts +1 -4
- package/packages/_vue2/dist/src/functions/get-builder-search-params/index.d.ts +1 -1
- package/packages/_vue2/dist/src/functions/get-content/index.d.ts +3 -0
- package/packages/_vue2/dist/src/functions/get-content/types.d.ts +4 -0
- package/packages/_vue2/dist/src/functions/get-react-native-block-styles.d.ts +2 -1
- package/packages/_vue2/dist/src/functions/track.d.ts +6 -1
- package/packages/_vue2/dist/src/functions/transform-block-properties.d.ts +2 -0
- package/packages/_vue2/dist/src/helpers/css.d.ts +2 -0
- package/packages/_vue2/dist/src/scripts/init-editing.d.ts +4 -1
- package/packages/_vue2/dist/src/types/builder-block.d.ts +1 -0
- package/packages/_vue2/dist/src/types/builder-content.d.ts +6 -4
- package/packages/_vue2/dist/style.css +1 -1
- package/packages/_vue3/dist/block-styles.3f38d23f.cjs +1 -0
- package/packages/_vue3/dist/block-styles.9c18985e.js +61 -0
- package/packages/_vue3/dist/{get-processed-block.9b8059ab.cjs → get-processed-block.00348c25.cjs} +1 -1
- package/packages/{_vue2/dist/get-processed-block.d176d859.js → _vue3/dist/get-processed-block.391579db.js} +1 -1
- package/packages/_vue3/dist/index.4580bfec.cjs +29 -0
- package/packages/_vue3/dist/{index.bdc957bb.js → index.8f01d2e4.js} +678 -457
- package/packages/_vue3/dist/{render-block.97918590.js → render-block.66d690e4.js} +86 -65
- package/packages/_vue3/dist/render-block.f390e85d.cjs +3 -0
- package/packages/_vue3/dist/{render-component-with-context.e10c7475.js → render-component-with-context.3e80acf8.js} +2 -2
- package/packages/_vue3/dist/{render-component-with-context.4968d548.cjs → render-component-with-context.fb32b5d3.cjs} +1 -1
- package/packages/_vue3/dist/{render-component.da37335e.cjs → render-component.1b155226.cjs} +1 -1
- package/packages/_vue3/dist/{render-component.44939843.js → render-component.68197847.js} +3 -3
- package/packages/_vue3/dist/{render-inlined-styles.bcf2d6ec.cjs → render-inlined-styles.74308f98.cjs} +1 -1
- package/packages/_vue3/dist/{render-inlined-styles.5500cf72.js → render-inlined-styles.fdbe3458.js} +1 -1
- package/packages/_vue3/dist/{render-repeated-block.e053daa2.js → render-repeated-block.b17a78c3.js} +2 -2
- package/packages/_vue3/dist/{render-repeated-block.f954b0ce.cjs → render-repeated-block.c53825f5.cjs} +1 -1
- package/packages/_vue3/dist/{render-styles.1af9ac32.js → render-styles.05b9373e.js} +2 -2
- package/packages/_vue3/dist/{render-styles.6f74d8a8.cjs → render-styles.b2290f3c.cjs} +1 -1
- package/packages/_vue3/dist/sdk.cjs +1 -1
- package/packages/_vue3/dist/sdk.js +9 -9
- package/packages/_vue3/dist/src/blocks/columns/columns.vue.d.ts +43 -0
- package/packages/_vue3/dist/src/blocks/image/image.vue.d.ts +1 -0
- package/packages/_vue3/dist/src/blocks/symbol/symbol.vue.d.ts +2 -1
- package/packages/_vue3/dist/src/components/render-block/render-component.vue.d.ts +2 -0
- package/packages/_vue3/dist/src/components/render-content/render-content.vue.d.ts +3 -0
- package/packages/_vue3/dist/src/functions/evaluate.d.ts +2 -1
- package/packages/_vue3/dist/src/functions/get-block-actions-handler.d.ts +5 -2
- package/packages/_vue3/dist/src/functions/get-block-properties.d.ts +1 -4
- package/packages/_vue3/dist/src/functions/get-builder-search-params/index.d.ts +1 -1
- package/packages/_vue3/dist/src/functions/get-content/index.d.ts +3 -0
- package/packages/_vue3/dist/src/functions/get-content/types.d.ts +4 -0
- package/packages/_vue3/dist/src/functions/get-react-native-block-styles.d.ts +2 -1
- package/packages/_vue3/dist/src/functions/track.d.ts +6 -1
- package/packages/_vue3/dist/src/functions/transform-block-properties.d.ts +2 -0
- package/packages/_vue3/dist/src/helpers/css.d.ts +2 -0
- package/packages/_vue3/dist/src/scripts/init-editing.d.ts +4 -1
- package/packages/_vue3/dist/src/types/builder-block.d.ts +1 -0
- package/packages/_vue3/dist/src/types/builder-content.d.ts +6 -4
- package/packages/_vue3/dist/style.css +1 -1
- package/packages/_vue2/dist/block-styles.19a877d5.js +0 -117
- package/packages/_vue2/dist/block-styles.40e83f61.cjs +0 -6
- package/packages/_vue2/dist/index.319178a0.cjs +0 -4
- package/packages/_vue2/dist/render-block.c2a840de.cjs +0 -3
- package/packages/_vue3/dist/block-styles.a9ff2d51.cjs +0 -6
- package/packages/_vue3/dist/block-styles.c98db17a.js +0 -114
- package/packages/_vue3/dist/index.7ebc9925.cjs +0 -4
- package/packages/_vue3/dist/render-block.ea7240a5.cjs +0 -3
|
@@ -182,6 +182,7 @@ declare const _sfc_main: {
|
|
|
182
182
|
component(): any;
|
|
183
183
|
tag(): any;
|
|
184
184
|
useBlock(): any;
|
|
185
|
+
actions(): any;
|
|
185
186
|
attributes(): any;
|
|
186
187
|
shouldWrap(): any;
|
|
187
188
|
renderComponentProps(): any;
|
|
@@ -313,6 +314,7 @@ declare const _sfc_main: {
|
|
|
313
314
|
forceReRenderCount: number;
|
|
314
315
|
overrideContent: null;
|
|
315
316
|
update: number;
|
|
317
|
+
useBreakpoints: null;
|
|
316
318
|
overrideState: {};
|
|
317
319
|
};
|
|
318
320
|
provide(): {
|
|
@@ -361,7 +363,6 @@ declare const _sfc_main: {
|
|
|
361
363
|
};
|
|
362
364
|
props: string[];
|
|
363
365
|
data: () => {
|
|
364
|
-
className: string;
|
|
365
366
|
fetchedContent: null;
|
|
366
367
|
};
|
|
367
368
|
inject: {
|
|
@@ -371,6 +372,7 @@ declare const _sfc_main: {
|
|
|
371
372
|
onUpdateHook0(): void;
|
|
372
373
|
};
|
|
373
374
|
computed: {
|
|
375
|
+
className(): any;
|
|
374
376
|
contentToUse(): any;
|
|
375
377
|
onUpdateHook0(): any;
|
|
376
378
|
};
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import type { BuilderBlock } from "../../types/builder-block.js";
|
|
2
2
|
import type { BuilderContextInterface } from "../../context/types.js";
|
|
3
|
+
import type { Breakpoints } from "../../types/builder-content.js";
|
|
3
4
|
export interface RenderComponentProps {
|
|
4
5
|
componentRef: any;
|
|
5
6
|
componentOptions: any;
|
|
6
7
|
blockChildren: BuilderBlock[];
|
|
7
8
|
context: BuilderContextInterface;
|
|
9
|
+
customBreakpoints?: Breakpoints;
|
|
8
10
|
}
|
|
9
11
|
declare const _sfc_main: {
|
|
10
12
|
name: string;
|
|
@@ -80,6 +82,7 @@ declare const _sfc_main: {
|
|
|
80
82
|
component(): any;
|
|
81
83
|
tag(): any;
|
|
82
84
|
useBlock(): any;
|
|
85
|
+
actions(): any;
|
|
83
86
|
attributes(): any;
|
|
84
87
|
shouldWrap(): any;
|
|
85
88
|
renderComponentProps(): any;
|
|
@@ -11,6 +11,8 @@ export declare type RenderContentProps = {
|
|
|
11
11
|
apiKey: string;
|
|
12
12
|
customComponents?: RegisteredComponent[];
|
|
13
13
|
canTrack?: boolean;
|
|
14
|
+
locale?: string;
|
|
15
|
+
includeRefs?: boolean;
|
|
14
16
|
};
|
|
15
17
|
declare const _sfc_main: {
|
|
16
18
|
name: string;
|
|
@@ -175,6 +177,7 @@ declare const _sfc_main: {
|
|
|
175
177
|
component(): any;
|
|
176
178
|
tag(): any;
|
|
177
179
|
useBlock(): any;
|
|
180
|
+
actions(): any;
|
|
178
181
|
attributes(): any;
|
|
179
182
|
shouldWrap(): any;
|
|
180
183
|
renderComponentProps(): any;
|
|
@@ -306,6 +309,7 @@ declare const _sfc_main: {
|
|
|
306
309
|
forceReRenderCount: number;
|
|
307
310
|
overrideContent: null;
|
|
308
311
|
update: number;
|
|
312
|
+
useBreakpoints: null;
|
|
309
313
|
overrideState: {};
|
|
310
314
|
};
|
|
311
315
|
provide(): {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { BuilderContextInterface } from '../context/types.js';
|
|
2
|
-
export declare function evaluate({ code, context, state, event, }: {
|
|
2
|
+
export declare function evaluate({ code, context, state, event, isExpression, }: {
|
|
3
3
|
code: string;
|
|
4
4
|
event?: Event;
|
|
5
|
+
isExpression?: boolean;
|
|
5
6
|
} & Pick<BuilderContextInterface, 'state' | 'context'>): any;
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import type { BuilderContextInterface } from '../context/types.js';
|
|
2
2
|
import type { BuilderBlock } from '../types/builder-block.js';
|
|
3
|
-
|
|
3
|
+
declare type Options = {
|
|
4
4
|
block: BuilderBlock;
|
|
5
|
-
} & Pick<BuilderContextInterface, 'state' | 'context'
|
|
5
|
+
} & Pick<BuilderContextInterface, 'state' | 'context'>;
|
|
6
|
+
declare type EventHandler = (event: Event) => any;
|
|
7
|
+
export declare const createEventHandler: (value: string, options: Options) => EventHandler;
|
|
8
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare type QueryObject = Record<string, string>;
|
|
1
|
+
declare type QueryObject = Record<string, string | string[]>;
|
|
2
2
|
export declare const convertSearchParamsToQueryObject: (searchParams: URLSearchParams) => QueryObject;
|
|
3
3
|
export declare const getBuilderSearchParams: (_options: QueryObject | URLSearchParams | undefined) => QueryObject;
|
|
4
4
|
export declare const getBuilderSearchParamsFromWindow: () => QueryObject;
|
|
@@ -2,6 +2,9 @@ import type { BuilderContent } from '../../types/builder-content.js';
|
|
|
2
2
|
export declare type GetContentOptions = import('./types.js').GetContentOptions;
|
|
3
3
|
export declare function getContent(options: GetContentOptions): Promise<BuilderContent | null>;
|
|
4
4
|
export declare const generateContentUrl: (options: GetContentOptions) => URL;
|
|
5
|
+
/**
|
|
6
|
+
* TO-DO: Handle error responses.
|
|
7
|
+
*/
|
|
5
8
|
interface ContentResponse {
|
|
6
9
|
results: BuilderContent[];
|
|
7
10
|
}
|
|
@@ -32,4 +32,8 @@ export interface GetContentOptions {
|
|
|
32
32
|
* Include references in the response. Defaults to `true`.
|
|
33
33
|
*/
|
|
34
34
|
includeRefs?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* If provided, the API will auto-resolve localized objects to the value of this `locale` key.
|
|
37
|
+
*/
|
|
38
|
+
locale?: string;
|
|
35
39
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { BuilderContextInterface } from '../context/types.js';
|
|
2
2
|
import type { BuilderBlock } from '../types/builder-block.js';
|
|
3
|
-
export declare function getReactNativeBlockStyles({ block, context, }: {
|
|
3
|
+
export declare function getReactNativeBlockStyles({ block, context, blockStyles, }: {
|
|
4
4
|
block: BuilderBlock;
|
|
5
5
|
context: BuilderContextInterface;
|
|
6
|
+
blockStyles: any;
|
|
6
7
|
}): CSSStyleDeclaration | Record<string, string | undefined>;
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import type { CanTrack } from '../types/can-track.js';
|
|
2
2
|
interface Event {
|
|
3
|
-
|
|
3
|
+
/**
|
|
4
|
+
* The type of your event.
|
|
5
|
+
*
|
|
6
|
+
* Examples: `click`, `conversion`, `pageview`, `impression`
|
|
7
|
+
*/
|
|
8
|
+
type: string;
|
|
4
9
|
data: {
|
|
5
10
|
/**
|
|
6
11
|
* (Optional) The content's ID. Useful if this event pertains to a specific piece of content.
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
export declare const convertStyleMapToCSSArray: (style: Partial<CSSStyleDeclaration>) => string[];
|
|
2
|
+
export declare const convertStyleMapToCSS: (style: Partial<CSSStyleDeclaration>) => string;
|
|
1
3
|
export declare const createCssClass: ({ mediaQuery, className, styles, }: {
|
|
2
4
|
mediaQuery?: string | undefined;
|
|
3
5
|
className: string;
|
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import type { BuilderBlock } from './builder-block.js';
|
|
2
|
+
import type { Nullable } from './typescript.js';
|
|
2
3
|
declare type Input = any;
|
|
4
|
+
export interface Breakpoints {
|
|
5
|
+
small: number;
|
|
6
|
+
medium: number;
|
|
7
|
+
}
|
|
3
8
|
export interface BuilderContentVariation {
|
|
4
9
|
data?: {
|
|
5
10
|
title?: string;
|
|
@@ -19,10 +24,7 @@ export interface BuilderContentVariation {
|
|
|
19
24
|
testRatio?: number;
|
|
20
25
|
id?: string;
|
|
21
26
|
meta?: {
|
|
22
|
-
breakpoints?:
|
|
23
|
-
small: number;
|
|
24
|
-
medium: number;
|
|
25
|
-
};
|
|
27
|
+
breakpoints?: Nullable<Breakpoints>;
|
|
26
28
|
[key: string]: any;
|
|
27
29
|
};
|
|
28
30
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.div-
|
|
1
|
+
.div-t43jfuqn6g[data-v-a99b6f14]{display:flex;line-height:normal}.div-t43jfuqn6g-2[data-v-a99b6f14]{display:flex;flex-direction:column;align-items:stretch}.img-1o2kztlxdt6[data-v-deaf6cf6]{opacity:1;transition:opacity .2s ease-in-out}.div-1o2kztlxdt6[data-v-deaf6cf6]{width:100%;pointer-events:none;font-size:0}.div-1o2kztlxdt6-2[data-v-deaf6cf6]{display:flex;flex-direction:column;align-items:stretch;position:absolute;top:0;left:0;width:100%;height:100%}.button-29wpyomtntv[data-v-7061ea07]{all:unset}.div-23e8fqt91nf[data-v-713efc9e]{display:flex;flex-direction:column;align-items:stretch}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),s=require("./index.4580bfec.cjs"),y=require("./get-processed-block.00348c25.cjs"),p=()=>Promise.resolve().then(()=>require("./render-inlined-styles.74308f98.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:o.defineAsyncComponent(p)},props:["block","context"],data:()=>({TARGET:s.TARGET}),computed:{useBlock(){return y.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!0})},css(){var a;const e=this.useBlock.responsiveStyles,c=this.context.content,r=s.getSizesForBreakpoints(((a=c==null?void 0:c.meta)==null?void 0:a.breakpoints)||{}),l=e==null?void 0:e.large,i=e==null?void 0:e.medium,t=e==null?void 0:e.small,n=this.useBlock.id,d=l?s.createCssClass({className:n,styles:l}):"",u=i?s.createCssClass({className:n,styles:i,mediaQuery:s.getMaxWidthQueryForSize("medium",r)}):"",m=t?s.createCssClass({className:n,styles:t,mediaQuery:s.getMaxWidthQueryForSize("small",r)}):"";return[d,u,m].join(" ")}}};function h(e,c,r,l,i,t){const n=o.resolveComponent("render-inlined-styles");return e.TARGET!=="reactNative"&&t.css?(o.openBlock(),o.createBlock(n,{key:0,styles:t.css},null,8,["styles"])):o.createCommentVNode("",!0)}const S=s._export_sfc(k,[["render",h]]);exports.default=S;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { defineAsyncComponent as u, resolveComponent as y, openBlock as k, createBlock as h, createCommentVNode as S } from "vue";
|
|
2
|
+
import { T as _, g as f, c as r, a as i, _ as g } from "./index.8f01d2e4.js";
|
|
3
|
+
import { g as x } from "./get-processed-block.391579db.js";
|
|
4
|
+
const B = () => import("./render-inlined-styles.fdbe3458.js").then((e) => e.default).catch((e) => {
|
|
5
|
+
throw console.error(
|
|
6
|
+
"Error while attempting to dynamically import component RenderInlinedStyles at ../render-inlined-styles.vue",
|
|
7
|
+
e
|
|
8
|
+
), e;
|
|
9
|
+
}), C = {
|
|
10
|
+
name: "block-styles",
|
|
11
|
+
components: {
|
|
12
|
+
RenderInlinedStyles: u(B)
|
|
13
|
+
},
|
|
14
|
+
props: ["block", "context"],
|
|
15
|
+
data: () => ({ TARGET: _ }),
|
|
16
|
+
computed: {
|
|
17
|
+
useBlock() {
|
|
18
|
+
return x({
|
|
19
|
+
block: this.block,
|
|
20
|
+
state: this.context.state,
|
|
21
|
+
context: this.context.context,
|
|
22
|
+
shouldEvaluateBindings: !0
|
|
23
|
+
});
|
|
24
|
+
},
|
|
25
|
+
css() {
|
|
26
|
+
var a;
|
|
27
|
+
const e = this.useBlock.responsiveStyles, n = this.context.content, o = f(
|
|
28
|
+
((a = n == null ? void 0 : n.meta) == null ? void 0 : a.breakpoints) || {}
|
|
29
|
+
), l = e == null ? void 0 : e.large, c = e == null ? void 0 : e.medium, t = e == null ? void 0 : e.small, s = this.useBlock.id, m = l ? r({
|
|
30
|
+
className: s,
|
|
31
|
+
styles: l
|
|
32
|
+
}) : "", d = c ? r({
|
|
33
|
+
className: s,
|
|
34
|
+
styles: c,
|
|
35
|
+
mediaQuery: i(
|
|
36
|
+
"medium",
|
|
37
|
+
o
|
|
38
|
+
)
|
|
39
|
+
}) : "", p = t ? r({
|
|
40
|
+
className: s,
|
|
41
|
+
styles: t,
|
|
42
|
+
mediaQuery: i(
|
|
43
|
+
"small",
|
|
44
|
+
o
|
|
45
|
+
)
|
|
46
|
+
}) : "";
|
|
47
|
+
return [m, d, p].join(" ");
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
function b(e, n, o, l, c, t) {
|
|
52
|
+
const s = y("render-inlined-styles");
|
|
53
|
+
return e.TARGET !== "reactNative" && t.css ? (k(), h(s, {
|
|
54
|
+
key: 0,
|
|
55
|
+
styles: t.css
|
|
56
|
+
}, null, 8, ["styles"])) : S("", !0);
|
|
57
|
+
}
|
|
58
|
+
const E = /* @__PURE__ */ g(C, [["render", b]]);
|
|
59
|
+
export {
|
|
60
|
+
E as default
|
|
61
|
+
};
|
package/packages/_vue3/dist/{get-processed-block.9b8059ab.cjs → get-processed-block.00348c25.cjs}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const o=require("./index.
|
|
1
|
+
"use strict";const o=require("./index.4580bfec.cjs"),d=(e,r,i)=>{if(Object(e)!==e)return e;const n=Array.isArray(r)?r:r.toString().match(/[^.[\]]+/g);return n.slice(0,-1).reduce((t,s,c)=>Object(t[s])===t[s]?t[s]:t[s]=Math.abs(Number(n[c+1]))>>0===+n[c+1]?[]:{},e)[n[n.length-1]]=i,e};const a=({block:e,context:r,state:i})=>{if(!e.bindings)return e;const n=o.fastClone(e),t={...n,properties:{...n.properties},actions:{...n.actions}};for(const s in e.bindings){const c=e.bindings[s],u=o.evaluate({code:c,state:i,context:r});d(t,s,u)}return t};function f({block:e,context:r,shouldEvaluateBindings:i,state:n}){const t=e;return i?a({block:t,state:n,context:r}):t}exports.getProcessedBlock=f;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";const r=require("vue");function he(e){if(e&&e.__esModule)return e;const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,o.get?o:{enumerable:!0,get:()=>e[t]})}}return n.default=e,Object.freeze(n)}const k="vue3";function f(){return typeof window<"u"&&typeof document<"u"}const j={};function $(e,n){let t=j[e];if(t||(t=j[e]=[]),t.push(n),f()){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 fe=()=>{$("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 F=!1;const ge=(e={})=>{var n,t;F||(F=!0,f()&&((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,s;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,m=null;try{u=d.apply(null,l)}catch(p){m=p}m?(i=window.parent)==null||i.postMessage({type:"builder.evaluateError",data:{id:c,error:m.message}},"*"):u&&typeof u.then=="function"?u.then(p=>{var b;(b=window.parent)==null||b.postMessage({type:"builder.evaluateResult",data:{id:c,result:p}},"*")}).catch(console.error):(s=window.parent)==null||s.postMessage({type:"builder.evaluateResult",data:{result:u,id:c}},"*");break}}})))},x=e=>JSON.parse(JSON.stringify(e)),U={small:{min:320,default:321,max:640},medium:{min:641,default:642,max:991},large:{min:990,default:991,max:1200}},be=(e,n=U)=>`@media (max-width: ${n[e].max}px)`,N=({small:e,medium:n})=>{const t=x(U);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 s=t.medium.max+1;return t.large={max:2e3,min:s,default:s+1},t},ye=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),v=e=>e!=null,W=e=>Object.entries(e).map(([t,o])=>{if(typeof o=="string")return`${ye(t)}: ${o};`}).filter(v),y=e=>W(e).join(`
|
|
2
|
+
`),ve=({mediaQuery:e,className:n,styles:t})=>{const o=`.${n} {
|
|
3
|
+
${y(t)}
|
|
4
|
+
}`;return e?`${e} {
|
|
5
|
+
${o}
|
|
6
|
+
}`:o},ke=()=>Promise.resolve().then(()=>me).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.74308f98.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}),Ce={name:"builder-columns",components:{RenderInlinedStyles:r.defineAsyncComponent(xe),RenderBlocks:r.defineAsyncComponent(ke)},props:["space","columns","stackColumnsAt","reverseColumnsWhenStacked","customBreakpoints","builderBlock"],data:()=>({TARGET:k}),computed:{columnsCssVars(){const e=this.stackColumnsAt==="never"?"inherit":this.reverseColumnsWhenStacked?"column-reverse":"column";return{"--flex-dir":e,"--flex-dir-tablet":this.maybeApplyForTablet(e)}},columnCssVars(){const e="100%",n="0";return{"--column-width":e,"--column-margin-left":n,"--column-width-tablet":this.maybeApplyForTablet(e),"--column-margin-left-tablet":this.maybeApplyForTablet(n)}},columnStyleObjects(){return{columns:{small:{flexDirection:"var(--flex-dir)",alignItems:"stretch"},medium:{flexDirection:"var(--flex-dir-tablet)",alignItems:"stretch"}},column:{small:{width:"var(--column-width) !important",marginLeft:"var(--column-margin-left) !important"},medium:{width:"var(--column-width-tablet) !important",marginLeft:"var(--column-margin-left-tablet) !important"}}}},columnsStyles(){return`
|
|
7
|
+
@media (max-width: ${this.getWidthForBreakpointSize("medium")}px) {
|
|
8
|
+
.${this.builderBlock.id}-breakpoints {
|
|
9
|
+
${y(this.columnStyleObjects.columns.medium)}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.${this.builderBlock.id}-breakpoints > .builder-column {
|
|
13
|
+
${y(this.columnStyleObjects.column.medium)}
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
@media (max-width: ${this.getWidthForBreakpointSize("small")}px) {
|
|
18
|
+
.${this.builderBlock.id}-breakpoints {
|
|
19
|
+
${y(this.columnStyleObjects.columns.small)}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.${this.builderBlock.id}-breakpoints > .builder-column {
|
|
23
|
+
${y(this.columnStyleObjects.column.small)}
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
`},reactNativeColumnsStyles(){return this.columnStyleObjects.columns.small},reactNativeColumnStyles(){return this.columnStyleObjects.column.small}},methods:{getGutterSize(){return typeof this.space=="number"?this.space||0:20},getColumns(){return this.columns||[]},getWidth(e){var t;const n=this.getColumns();return((t=n[e])==null?void 0:t.width)||100/n.length},getColumnCssWidth(e){const n=this.getColumns(),o=this.getGutterSize()*(n.length-1)/n.length;return`calc(${this.getWidth(e)}% - ${o}px)`},maybeApplyForTablet(e){return(this.stackColumnsAt||"tablet")==="tablet"?e:"inherit"},getWidthForBreakpointSize(e){return N(this.customBreakpoints||{})[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}}};const h=(e,n)=>{const t=e.__vccOpts||e;for(const[o,i]of n)t[o]=i;return t};function Se(e,n,t,o,i,s){const a=r.resolveComponent("render-inlined-styles"),l=r.resolveComponent("render-blocks");return r.openBlock(),r.createElementBlock("div",{class:r.normalizeClass(s._classStringToObject(`builder-columns ${t.builderBlock.id}-breakpoints div-1fogms4bee0`)),style:r.normalizeStyle({...e.TARGET==="reactNative"?s.reactNativeColumnsStyles:{},...s.columnsCssVars})},[e.TARGET!=="reactNative"?(r.openBlock(),r.createBlock(a,{key:0,styles:s.columnsStyles},null,8,["styles"])):r.createCommentVNode("",!0),(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(t.columns,(c,d)=>(r.openBlock(),r.createElementBlock("div",{key:d,class:"builder-column div-1fogms4bee0-2",style:r.normalizeStyle({width:s.getColumnCssWidth(d),marginLeft:`${d===0?0:s.getGutterSize()}px`,...e.TARGET==="reactNative"?s.reactNativeColumnStyles:{},...s.columnCssVars})},[r.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 L=h(Ce,[["render",Se],["__scopeId","data-v-523c4250"]]);function P(e){return e.replace(/http(s)?:/,"")}function _e(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 we(e,n){if(!e||!(e!=null&&e.match(/cdn\.shopify\.com/))||!n)return e;if(n==="master")return P(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],s=n.match("x")?n:`${n}x`;return P(`${o[0]}_${s}${i}`)}return null}function S(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=>`${_e(e,"width",i)} ${i}w`).concat([t]).join(", ")}return e.match(/cdn\.shopify\.com/)?n.map(t=>[we(e,`${t}x${t}`),t]).filter(([t])=>!!t).map(([t,o])=>`${t} ${o}w`).concat([e]).join(", "):e}const Ie={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"),S(n)}else if(this.image&&!this.srcset)return S(n);return S(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 Te=["srcset"],Re=["alt","role","src","srcset","sizes"],Be=["srcset"],Ee={key:2,class:"div-263j453upso-2"};function je(e,n,t,o,i,s){var a,l,c,d;return r.openBlock(),r.createElementBlock(r.Fragment,null,[r.createElementVNode("picture",null,[s.webpSrcSet?(r.openBlock(),r.createElementBlock("source",{key:0,type:"image/webp",srcset:s.webpSrcSet},null,8,Te)):r.createCommentVNode("",!0),r.createElementVNode("img",{loading:"lazy",alt:t.altText,role:t.altText?"presentation":void 0,style:r.normalizeStyle({objectPosition:t.backgroundPosition||"center",objectFit:t.backgroundSize||"cover",...s.aspectRatioCss}),class:r.normalizeClass(s._classStringToObject("builder-image"+(t.className?" "+t.className:"")+" img-263j453upso")),src:t.image,srcset:s.srcSetToUse,sizes:t.sizes},null,14,Re),r.createElementVNode("source",{srcset:s.srcSetToUse},null,8,Be)]),t.aspectRatio&&!(((l=(a=t.builderBlock)==null?void 0:a.children)==null?void 0:l.length)&&t.fitContent)?(r.openBlock(),r.createElementBlock("div",{key:0,class:"builder-image-sizer div-263j453upso",style:r.normalizeStyle({paddingTop:t.aspectRatio*100+"%"})},null,4)):r.createCommentVNode("",!0),((d=(c=t.builderBlock)==null?void 0:c.children)==null?void 0:d.length)&&t.fitContent?r.renderSlot(e.$slots,"default",{key:1},void 0,!0):r.createCommentVNode("",!0),!t.fitContent&&e.children?(r.openBlock(),r.createElementBlock("div",Ee,[r.renderSlot(e.$slots,"default",{},void 0,!0)])):r.createCommentVNode("",!0)],64)}const M=h(Ie,[["render",je],["__scopeId","data-v-110feda1"]]),Fe={name:"builder-text",props:["text"]},Pe=["innerHTML"];function Ae(e,n,t,o,i,s){return r.openBlock(),r.createElementBlock("span",{class:"builder-text",innerHTML:t.text},null,8,Pe)}const z=h(Fe,[["render",Ae]]),Oe={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}}}},Ve=["src","poster"];function $e(e,n,t,o,i,s){var a;return r.openBlock(),r.createElementBlock("video",r.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},s.spreadProps),null,16,Ve)}const H=h(Oe,[["render",$e]]);function _(e,n=null,t="."){return Object.keys(e).reduce((o,i)=>{const s=e[i],a=[n,i].filter(Boolean).join(t);return[typeof s=="object",s!==null,!(Array.isArray(s)&&s.length===0)].every(Boolean)?{...o,..._(s,a,t)}:{...o,[a]:s}},{})}const A="builder.",Ue="options.",D=e=>{const n={};return e.forEach((t,o)=>{n[o]=t}),n},K=e=>{if(!e)return{};const n=T(e),t={};return Object.keys(n).forEach(o=>{if(o.startsWith(A)){const i=o.replace(A,"").replace(Ue,"");t[i]=n[o]}}),t},q=()=>{if(!f())return{};const e=new URLSearchParams(window.location.search);return K(e)},T=e=>e instanceof URLSearchParams?D(e):e;function Ne(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:null}async function G(){const e=Ne().fetch;if(typeof e>"u"&&typeof global<"u"){const n=Promise.resolve().then(()=>he(require("node-fetch"))).then(t=>t.default);return n.default||n}return e.default||e}const We=e=>{const n=e.split(".");return n.length>2?n.slice(1).join("."):e},J=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)}},Le=e=>e.map(([n,t])=>t?`${n}=${t}`:n).join("; "),Me=[["secure",""],["SameSite","None"]],ze=({name:e,value:n,expires:t})=>{const i=(f()?location.protocol==="https:":!0)?Me:[[]],s=t?[["expires",t.toUTCString()]]:[[]],a=[[e,n],...s,["path","/"],["domain",We(window.location.hostname)],...i];return Le(a)},X=async({name:e,value:n,expires:t,canTrack:o})=>{try{if(!o)return;const i=ze({name:e,value:n,expires:t});document.cookie=i}catch(i){console.warn("[COOKIE] SET error: ",i)}},He="builderio.variations",Y=e=>`${He}.${e}`,De=({contentId:e,canTrack:n})=>J({name:Y(e),canTrack:n}),Ke=({contentId:e,canTrack:n,value:t})=>X({name:Y(e),value:t,canTrack:n}),qe=e=>v(e.id)&&v(e.variations)&&Object.keys(e.variations).length>0,Ge=({id:e,variations:n})=>{var i;let t=0;const o=Math.random();for(const s in n)if(t+=(i=n[s])==null?void 0:i.testRatio,o<t)return s;return e},O=({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":"")}},Je=async({item:e,canTrack:n})=>{const t=await De({canTrack:n,contentId:e.id}),o=t?O({item:e,testGroupId:t}):void 0;if(o)return o;{const i=Ge({variations:e.variations,id:e.id});return Ke({contentId:e.id,value:i,canTrack:n}).catch(s=>{console.error("could not store A/B test variation: ",s)}),O({item:e,testGroupId:i})}},Xe=async({item:e,canTrack:n})=>{if(!qe(e))return;const t=await Je({item:e,canTrack:n});Object.assign(e,t)};async function R(e){return(await Z({...e,limit:1})).results[0]||null}const Q=e=>{const{limit:n=30,userAttributes:t,query:o,noTraverse:i=!1,model:s,apiKey:a,includeRefs:l=!0,locale:c}=e;if(!a)throw new Error("Missing API key");const d=new URL(`https://cdn.builder.io/api/v2/content/${s}?apiKey=${a}&limit=${n}&noTraverse=${i}&includeRefs=${l}${c?`&locale=${c}`:""}`),u={...q(),...T(e.options||{})},m=_(u);for(const p in m)d.searchParams.set(p,String(m[p]));if(t&&d.searchParams.set("userAttributes",JSON.stringify(t)),o){const p=_({query:o});for(const b in p)d.searchParams.set(b,JSON.stringify(p[b]))}return d};async function Z(e){const n=Q(e),o=await(await G())(n.href).then(s=>s.json()),i=e.canTrack!==!1;if(i&&Array.isArray(o.results))for(const s of o.results)await Xe({item:s,canTrack:i});return o}const Ye=()=>Promise.resolve().then(()=>tn).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}),Qe={name:"builder-symbol",components:{RenderContent:r.defineAsyncComponent(Ye)},props:["attributes","symbol","dynamic"],data:()=>({fetchedContent:null}),inject:{builderContext:"BuilderContext"},watch:{onUpdateHook0(){const e=this.symbol;e&&!e.content&&!this.fetchedContent&&e.model&&R({model:e.model,apiKey:this.builderContext.apiKey,query:{id:e.entry}}).then(n=>{this.fetchedContent=n})}},computed:{className(){var e,n;return[...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(){var e;return((e=this.symbol)==null?void 0:e.content)||this.fetchedContent},onUpdateHook0(){return{0:this.symbol,1:this.fetchedContent}}},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}}},Ze=["dataSet"];function et(e,n,t,o,i,s){var l,c,d,u,m;const a=r.resolveComponent("render-content");return r.openBlock(),r.createElementBlock("div",r.mergeProps({dataSet:{class:s.className},class:s._classStringToObject(s.className)},t.attributes),[r.createVNode(a,{apiKey:s.builderContext.apiKey,context:s.builderContext.context,customComponents:Object.values(s.builderContext.registeredComponents),data:{...(l=t.symbol)==null?void 0:l.data,...s.builderContext.state,...(u=(d=(c=t.symbol)==null?void 0:c.content)==null?void 0:d.data)==null?void 0:u.state},model:(m=t.symbol)==null?void 0:m.model,content:s.contentToUse},null,8,["apiKey","context","customComponents","data","model","content"])],16,Ze)}const ee=h(Qe,[["render",et]]),tt={name:"builder-button",props:["attributes","text","link","openLinkInNewTab"]};const nt=["href","target"];function ot(e,n,t,o,i,s){return t.link?(r.openBlock(),r.createElementBlock("a",r.mergeProps({key:0,role:"button",href:t.link,target:t.openLinkInNewTab?"_blank":void 0},t.attributes),r.toDisplayString(t.text),17,nt)):(r.openBlock(),r.createElementBlock("button",r.mergeProps({key:1,class:"button-7jvpanrlkn"},t.attributes),r.toDisplayString(t.text),17))}const te=h(tt,[["render",ot],["__scopeId","data-v-9cf2830c"]]),rt={name:"builder-section-component",props:["attributes","maxWidth"]};function st(e,n,t,o,i,s){return r.openBlock(),r.createElementBlock("section",r.mergeProps({style:{width:"100%",alignSelf:"stretch",flexGrow:"1",boxSizing:"border-box",maxWidth:`${t.maxWidth&&typeof t.maxWidth=="number"?t.maxWidth:1200}px`,display:"flex",flexDirection:"column",alignItems:"stretch",marginLeft:"auto",marginRight:"auto"}},t.attributes),[r.renderSlot(e.$slots,"default")],16)}const ne=h(rt,[["render",st]]),it={name:"builder-fragment-component",props:[]};function at(e,n,t,o,i,s){return r.openBlock(),r.createElementBlock("span",null,[r.renderSlot(e.$slots,"default")])}const oe=h(it,[["render",at]]),ct={name:"Core:Button",builtIn:!0,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)`},lt={name:"Columns",builtIn:!0,inputs:[{name:"columns",type:"array",broadcast:!0,subFields:[{name:"blocks",type:"array",hideFromUI:!0,defaultValue:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{name:"width",type:"number",hideFromUI:!0,helperText:"Width %, e.g. set to 50 to fill half of the space"},{name:"link",type:"url",helperText:"Optionally set a url that clicking this column will link to"}],defaultValue:[{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]},{blocks:[{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto",minHeight:"20px",minWidth:"20px",overflow:"hidden"}},component:{name:"Image",options:{image:"https://builder.io/api/v1/image/assets%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",backgroundPosition:"center",backgroundSize:"cover",aspectRatio:.7004048582995948}}},{"@type":"@builder.io/sdk:Element",responsiveStyles:{large:{display:"flex",flexDirection:"column",alignItems:"stretch",flexShrink:"0",position:"relative",marginTop:"30px",textAlign:"center",lineHeight:"normal",height:"auto"}},component:{name:"Text",options:{text:"<p>Enter some text...</p>"}}}]}],onChange: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(s=>!s.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}]},dt={name:"Fragment",static:!0,hidden:!0,builtIn:!0,canHaveChildren:!0,noWrap:!0},ut={name:"Image",static:!0,builtIn:!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%2Fpwgjf0RoYWbdnJSbpBAjXNRMe9F2%2Ffb27a7c790324294af8be1c35fe30f4d",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 m=!1;u.onload=()=>{m=!0,c(u)},u.addEventListener("error",p=>{console.warn("Image load failed",p.error),d(p.error)}),u.src=a,setTimeout(()=>{m||d(new Error("Image load timed out"))},l)})}function o(a){return Math.round(a*1e3)/1e3}const i=e.get("image"),s=e.get("aspectRatio");if(fetch(i).then(a=>a.blob()).then(a=>{a.type.includes("svg")&&e.set("noWebp",!0)}),i&&(!s||s===.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}]},mt={name:"Core:Section",static:!0,builtIn:!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>"}}}]},pt={name:"Symbol",noWrap:!0,static:!0,builtIn:!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"}]},ht={name:"Text",static:!0,builtIn:!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"}},ft={name:"Video",canHaveChildren:!0,builtIn:!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}]},gt={name:"Embed",static:!0,builtIn:!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}]},bt=["text/javascript","application/javascript","application/ecmascript"],yt=e=>bt.includes(e.type),vt={name:"builder-embed",props:["content"],data:()=>({scriptsInserted:[],scriptsRun:[],ranInitFn:!1}),watch:{onUpdateHook0(){this.$refs.elem&&!this.ranInitFn&&(this.ranInitFn=!0,this.findAndRunScripts())}},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(yt(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)}}}}},kt=["innerHTML"];function xt(e,n,t,o,i,s){return r.openBlock(),r.createElementBlock("div",{class:"builder-embed",ref:"elem",innerHTML:t.content},null,8,kt)}const Ct=h(vt,[["render",xt]]);function St(){return f()&&window.self!==window.top}function g(){return St()&&window.location.search.indexOf("builder.frameEditing=")!==-1}const _t={name:"builder-img-component",props:["backgroundSize","backgroundPosition","imgSrc","altText","image","attributes"],data:()=>({isEditing:g})},wt=["alt","src"];function It(e,n,t,o,i,s){return r.openBlock(),r.createElementBlock("img",r.mergeProps({style:{objectFit:t.backgroundSize||"cover",objectPosition:t.backgroundPosition||"center"},key:e.isEditing()&&t.imgSrc||"default-key",alt:t.altText,src:t.imgSrc||t.image},t.attributes),null,16,wt)}const Tt=h(_t,[["render",It]]),Rt={name:"Raw:Img",hideFromInsertMenu:!0,builtIn:!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},Bt={name:"builder-custom-code",props:["replaceNodes","code"],data:()=>({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}}},Et=["innerHTML"];function jt(e,n,t,o,i,s){return r.openBlock(),r.createElementBlock("div",{ref:"elem",class:r.normalizeClass(s._classStringToObject("builder-custom-code"+(t.replaceNodes?" replace-nodes":""))),innerHTML:t.code},null,10,Et)}const Ft=h(Bt,[["render",jt]]),Pt={name:"Custom Code",static:!0,builtIn:!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}]},At=()=>[{component:L,...lt},{component:M,...ut},{component:Tt,...Rt},{component:z,...ht},{component:H,...ft},{component:ee,...pt},{component:te,...ct},{component:ne,...mt},{component:oe,...dt},{component:Ct,...gt},{component:Ft,...Pt}];function w({code:e,context:n,state:t,event:o,isExpression:i=!0}){if(e===""){console.warn("Skipping evaluation of empty code block.");return}const s={isEditing:g(),isBrowser:f(),isServer:!f()},l=i&&!(e.includes(";")||e.includes(" return ")||e.trim().startsWith("return "))?`return (${e});`:e;try{return new Function("builder","Builder","state","context","event",l)(s,s,t,n,o)}catch(c){console.warn(`Builder custom code error:
|
|
27
|
+
While Evaluating:
|
|
28
|
+
`,l,`
|
|
29
|
+
`,c)}}function re(){return!f()||g()?!1:Boolean(location.search.indexOf("builder.preview=")!==-1)}const B=[];function Ot(e,n){return B.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 se=({component:e,...n})=>({type:"builder.registerComponent",data:$t(n)}),Vt=e=>typeof e=="function"?C(e):x(e),$t=({inputs:e,...n})=>({...x(n),inputs:e==null?void 0:e.map(t=>Object.entries(t).reduce((o,[i,s])=>({...o,[i]:Vt(s)}),{}))});function Ut(){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 ie(){return Ut().replace(/-/g,"")}const ae="builderSessionId",Nt=async({canTrack:e})=>{if(!e)return;const n=await J({name:ae,canTrack:e});if(v(n))return n;{const t=Wt();Lt({id:t,canTrack:e})}},Wt=()=>ie(),Lt=({id:e,canTrack:n})=>X({name:ae,value:e,canTrack:n}),ce=()=>f()&&typeof localStorage<"u"?localStorage:void 0,Mt=({key:e,canTrack:n})=>{var t;try{return n?(t=ce())==null?void 0:t.getItem(e):void 0}catch(o){console.debug("[LocalStorage] GET error: ",o)}},zt=({key:e,canTrack:n,value:t})=>{var o;try{n&&((o=ce())==null||o.setItem(e,t))}catch(i){console.debug("[LocalStorage] SET error: ",i)}},le="builderVisitorId",Ht=({canTrack:e})=>{if(!e)return;const n=Mt({key:le,canTrack:e});if(v(n))return n;{const t=Dt();Kt({id:t,canTrack:e})}},Dt=()=>ie(),Kt=({id:e,canTrack:n})=>zt({key:le,value:e,canTrack:n}),qt=async({canTrack:e})=>{if(!e)return{visitorId:void 0,sessionId:void 0};const n=await Nt({canTrack:e}),t=Ht({canTrack:e});return{sessionId:n,visitorId:t}},Gt=async({type:e,canTrack:n,apiKey:t,metadata:o,...i})=>({type:e,data:{...i,metadata:JSON.stringify(o),...await qt({canTrack:n}),ownerId:t}});async function I(e){if(!e.apiKey){console.error("[Builder.io]: Missing API key for track call. Please provide your API key.");return}if(!!e.canTrack&&!g()&&!!(f()||k==="reactNative"))return fetch("https://builder.io/api/v1/track",{method:"POST",body:JSON.stringify({events:[await Gt(e)]}),headers:{"content-type":"application/json"},mode:"cors"}).catch(n=>{console.error("Failed to track: ",n)})}const Jt=e=>I({...e,canTrack:!0}),Xt=()=>Promise.resolve().then(()=>me).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",e),e}),Yt=()=>Promise.resolve().then(()=>require("./render-styles.b2290f3c.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}),Qt={name:"render-content",components:{RenderContentStyles:r.defineAsyncComponent(Yt),RenderBlocks:r.defineAsyncComponent(Xt)},props:["content","data","canTrack","locale","context","customComponents","model","apiKey","includeRefs"],data:()=>({forceReRenderCount:0,overrideContent:null,update:0,useBreakpoints:null,overrideState:{}}),provide(){const e=this;return{BuilderContext:{get content(){return e.useContent},get state(){return e.contentState},get context(){return e.contextContext},get apiKey(){return e.apiKey},get registeredComponents(){return 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."),f()){if(g()&&(this.forceReRenderCount=this.forceReRenderCount+1,fe(),ge({...this.locale?{locale:this.locale}:{},...this.includeRefs?{includeRefs:this.includeRefs}:{}}),Object.values(this.allRegisteredComponents).forEach(t=>{var i;const o=se(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;I({type:"impression",canTrack:this.canTrackToUse,contentId:o,apiKey:this.apiKey,variationId:t!==o?t:void 0})}if(re()){const t=new URL(location.href).searchParams;if(this.model&&t.get("builder.preview")===this.model){const o=t.get("apiKey")||t.get("builder.space");o&&R({model:this.model,apiKey:o}).then(i=>{i&&(this.overrideContent=i)})}}this.evaluateJsCode(),this.runHttpRequests(),this.emitStateUpdate()}},watch:{onUpdateHook0(){this.evaluateJsCode()},onUpdateHook1(){this.runHttpRequests()},onUpdateHook2(){this.emitStateUpdate()}},unmounted(){f()&&(window.removeEventListener("message",this.processMessage),window.removeEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate))},computed:{useContent(){var n,t,o,i,s,a,l,c;return!this.content&&!this.overrideContent?void 0:{...this.content,...this.overrideContent,data:{...(n=this.content)==null?void 0:n.data,...this.data,...(t=this.overrideContent)==null?void 0:t.data},meta:{...(o=this.content)==null?void 0:o.meta,...(i=this.overrideContent)==null?void 0:i.meta,breakpoints:this.useBreakpoints||((a=(s=this.overrideContent)==null?void 0:s.meta)==null?void 0:a.breakpoints)||((c=(l=this.content)==null?void 0:l.meta)==null?void 0:c.breakpoints)}}},canTrackToUse(){return this.canTrack||!0},contentState(){var e,n;return{...(n=(e=this.content)==null?void 0:e.data)==null?void 0:n.state,...this.data,...this.locale?{locale:this.locale}:{},...this.overrideState}},contextContext(){return this.context||{}},allRegisteredComponents(){return[...At(),...B,...this.customComponents||[]].reduce((t,o)=>({...t,[o.name]:o}),{})},httpReqsData(){return{}},shouldRenderContentStyles(){var e,n,t,o,i;return Boolean((((n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.cssCode)||((i=(o=(t=this.useContent)==null?void 0:t.data)==null?void 0:o.customFonts)==null?void 0:i.length))&&k!=="reactNative")},onUpdateHook0(){var e,n;return{0:(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.jsCode,1:this.contentState}},onUpdateHook1(){var e,n;return{0:(n=(e=this.useContent)==null?void 0:e.data)==null?void 0:n.httpRequests}},onUpdateHook2(){return{0:this.contentState}}},methods:{processMessage(e){var t;const{data:n}=e;if(n)switch(n.type){case"builder.configureSdk":{const o=n.data,{breakpoints:i,contentId:s}=o;if(!s||s!==((t=this.useContent)==null?void 0:t.id))return;this.useBreakpoints=i,this.forceReRenderCount=this.forceReRenderCount+1;break}case"builder.contentUpdate":{const o=n.data,i=o.key||o.alias||o.entry||o.modelName,s=o.data;i===this.model&&(this.overrideContent=s,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&&w({code:e,context:this.contextContext,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;I({type:"click",canTrack:this.canTrackToUse,contentId:i,apiKey:this.apiKey,variationId:o!==i?o:void 0})}},evalExpression(e){return e.replace(/{{([^}]+)}}/g,(n,t)=>w({code:t,context:this.contextContext,state:this.contentState}))},handleRequest({url:e,key:n}){G().then(t=>t(e)).then(t=>t.json()).then(t=>{const o={...this.overrideState,[n]:t};this.overrideState=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,s])=>{if(s&&(!this.httpReqsData[i]||g())){const a=this.evalExpression(s);this.handleRequest({url:a,key:i})}})},emitStateUpdate(){g()&&window.dispatchEvent(new CustomEvent("builder:component:stateChange",{detail:{state:this.contentState,ref:{name:this.model}}}))}}},Zt=["builder-content-id","builder-model"];function en(e,n,t,o,i,s){var c,d,u,m,p,b,E;const a=r.resolveComponent("render-content-styles"),l=r.resolveComponent("render-blocks");return s.useContent?(r.openBlock(),r.createElementBlock("div",{key:0,ref:"elementRef",onClick:n[0]||(n[0]=pe=>s.onClick(pe)),"builder-content-id":(c=s.useContent)==null?void 0:c.id,"builder-model":t.model},[s.shouldRenderContentStyles?(r.openBlock(),r.createBlock(a,{key:0,cssCode:(u=(d=s.useContent)==null?void 0:d.data)==null?void 0:u.cssCode,customFonts:(p=(m=s.useContent)==null?void 0:m.data)==null?void 0:p.customFonts},null,8,["cssCode","customFonts"])):r.createCommentVNode("",!0),(r.openBlock(),r.createBlock(l,{blocks:(E=(b=s.useContent)==null?void 0:b.data)==null?void 0:E.blocks,key:e.forceReRenderCount},null,8,["blocks"]))],8,Zt)):r.createCommentVNode("",!0)}const de=h(Qt,[["render",en]]),tn=Object.freeze(Object.defineProperty({__proto__:null,default:de},Symbol.toStringTag,{value:"Module"})),nn=()=>Promise.resolve().then(()=>require("./block-styles.3f38d23f.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}),on=()=>Promise.resolve().then(()=>require("./render-block.f390e85d.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}),rn={name:"render-blocks",components:{RenderBlock:r.defineAsyncComponent(on),BlockStyles:r.defineAsyncComponent(nn)},props:["blocks","parent","path","styleProp"],inject:{builderContext:"BuilderContext"},computed:{className(){var e;return"builder-blocks"+((e=this.blocks)!=null&&e.length?"":" no-blocks")}},methods:{onClick(){var e,n;g()&&!((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;g()&&!((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 sn=["builder-path","builder-parent-id","dataSet"];function an(e,n,t,o,i,s){const a=r.resolveComponent("render-block"),l=r.resolveComponent("block-styles");return r.openBlock(),r.createElementBlock("div",{class:r.normalizeClass(s._classStringToObject(s.className+" div-1yj9n7yt24z")),"builder-path":t.path,"builder-parent-id":t.parent,dataSet:{class:s.className},style:r.normalizeStyle(t.styleProp),onClick:n[0]||(n[0]=c=>s.onClick()),onMouseenter:n[1]||(n[1]=c=>s.onMouseEnter())},[t.blocks?(r.openBlock(!0),r.createElementBlock(r.Fragment,{key:0},r.renderList(t.blocks,(c,d)=>(r.openBlock(),r.createBlock(a,{key:"render-block-"+c.id,block:c,context:s.builderContext},null,8,["block","context"]))),128)):r.createCommentVNode("",!0),t.blocks?(r.openBlock(!0),r.createElementBlock(r.Fragment,{key:1},r.renderList(t.blocks,(c,d)=>(r.openBlock(),r.createBlock(l,{key:"block-style-"+c.id,block:c,context:s.builderContext},null,8,["block","context"]))),128)):r.createCommentVNode("",!0)],46,sn)}const ue=h(rn,[["render",an],["__scopeId","data-v-35167bc1"]]),me=Object.freeze(Object.defineProperty({__proto__:null,default:ue},Symbol.toStringTag,{value:"Module"})),V={};function cn(e){if(f()){Object.assign(V,e);const n={type:"builder.settingsChange",data:V};parent.postMessage(n,"*")}}exports.Button=te;exports.Columns=L;exports.Fragment=oe;exports.Image=M;exports.Section=ne;exports.Symbol=ee;exports.TARGET=k;exports.Text=z;exports.Video=H;exports._export_sfc=h;exports.components=B;exports.convertSearchParamsToQueryObject=D;exports.convertStyleMapToCSSArray=W;exports.createCssClass=ve;exports.createRegisterComponentMessage=se;exports.evaluate=w;exports.fastClone=x;exports.generateContentUrl=Q;exports.getAllContent=Z;exports.getBuilderSearchParams=K;exports.getBuilderSearchParamsFromWindow=q;exports.getContent=R;exports.getMaxWidthQueryForSize=be;exports.getSizesForBreakpoints=N;exports.isEditing=g;exports.isPreviewing=re;exports.normalizeSearchParams=T;exports.register=$;exports.registerComponent=Ot;exports.renderBlocks=ue;exports.renderContent=de;exports.setEditorSettings=cn;exports.track=Jt;
|