@builder.io/sdk-vue 0.1.5 → 0.1.6
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.0c522549.cjs → block-styles.9b0be456.cjs} +1 -1
- package/packages/_vue2/dist/{block-styles.cf0de18b.js → block-styles.d0435c8f.js} +3 -3
- package/packages/{_vue3/dist/get-processed-block.77446c19.cjs → _vue2/dist/get-processed-block.531fd2fb.cjs} +1 -1
- package/packages/{_vue3/dist/get-processed-block.37c65d27.js → _vue2/dist/get-processed-block.aa4c9919.js} +1 -1
- package/packages/_vue2/dist/index.b431861b.cjs +30 -0
- package/packages/_vue2/dist/{index.24f01638.js → index.da42f753.js} +112 -123
- package/packages/_vue2/dist/{render-block.a8683c91.js → render-block.49244064.js} +5 -5
- package/packages/_vue2/dist/render-block.5d240071.cjs +3 -0
- package/packages/_vue2/dist/{render-component.1220773f.cjs → render-component.3117c1fd.cjs} +1 -1
- package/packages/_vue2/dist/{render-component.aafdd999.js → render-component.42e82bc4.js} +3 -3
- package/packages/_vue2/dist/{render-inlined-styles.e770caf6.js → render-inlined-styles.5d055b0c.js} +1 -1
- package/packages/_vue2/dist/{render-inlined-styles.362de669.cjs → render-inlined-styles.d7530652.cjs} +1 -1
- package/packages/_vue2/dist/{render-repeated-block.8881a0f1.cjs → render-repeated-block.b4a9163a.cjs} +1 -1
- package/packages/_vue2/dist/{render-repeated-block.3fa28a72.js → render-repeated-block.bceba726.js} +2 -2
- package/packages/_vue2/dist/{render-styles.239d91cf.js → render-styles.0451ee0a.js} +2 -2
- package/packages/_vue2/dist/{render-styles.956991f6.cjs → render-styles.144e8a3e.cjs} +2 -2
- package/packages/_vue2/dist/sdk.cjs +1 -1
- package/packages/_vue2/dist/sdk.js +1 -1
- package/packages/_vue2/dist/src/types/components.d.ts +0 -1
- package/packages/_vue2/dist/style.css +1 -1
- package/packages/_vue3/dist/{block-styles.666ee81f.cjs → block-styles.05a01a8e.cjs} +1 -1
- package/packages/_vue3/dist/{block-styles.d05bbb48.js → block-styles.5fb6e927.js} +3 -3
- package/packages/{_vue2/dist/get-processed-block.2cf53db5.js → _vue3/dist/get-processed-block.48c68f6b.js} +1 -1
- package/packages/{_vue2/dist/get-processed-block.100e890c.cjs → _vue3/dist/get-processed-block.e6e75aca.cjs} +1 -1
- package/packages/_vue3/dist/{index.6b1bc5ee.cjs → index.6275edf0.cjs} +10 -10
- package/packages/_vue3/dist/{index.b1080e36.js → index.8392057e.js} +15 -26
- package/packages/_vue3/dist/{render-block.11e5a0d0.js → render-block.017ccb02.js} +5 -5
- package/packages/_vue3/dist/{render-block.c674f764.cjs → render-block.f6f263a8.cjs} +2 -2
- package/packages/_vue3/dist/{render-component.3397c957.js → render-component.5b79b1a2.js} +3 -3
- package/packages/_vue3/dist/{render-component.2455895f.cjs → render-component.626cb9a2.cjs} +1 -1
- package/packages/_vue3/dist/{render-inlined-styles.ca824cfb.js → render-inlined-styles.0773feb1.js} +1 -1
- package/packages/_vue3/dist/{render-inlined-styles.17e85155.cjs → render-inlined-styles.ab30b262.cjs} +1 -1
- package/packages/_vue3/dist/{render-repeated-block.645dd73e.js → render-repeated-block.09b2f47e.js} +2 -2
- package/packages/_vue3/dist/{render-repeated-block.1b978fce.cjs → render-repeated-block.802c4a21.cjs} +1 -1
- package/packages/_vue3/dist/{render-styles.4d7ca33e.cjs → render-styles.7e2d3639.cjs} +2 -2
- package/packages/_vue3/dist/{render-styles.f59a1cf7.js → render-styles.c79197c2.js} +2 -2
- package/packages/_vue3/dist/sdk.cjs +1 -1
- package/packages/_vue3/dist/sdk.js +1 -1
- package/packages/_vue3/dist/src/types/components.d.ts +0 -1
- package/packages/_vue3/dist/style.css +1 -1
- package/packages/_vue2/dist/index.e93e18ce.cjs +0 -30
- package/packages/_vue2/dist/render-block.d4d3c07e.cjs +0 -3
|
@@ -127,10 +127,10 @@ function ye(e, n, t, o, r, s) {
|
|
|
127
127
|
target: t.openLinkInNewTab ? "_blank" : void 0
|
|
128
128
|
}, s.filterAttrs(t.attributes, !1), w(s.filterAttrs(t.attributes, !0), !0)), M(t.text), 17, be)) : (d(), u("button", _({
|
|
129
129
|
key: 1,
|
|
130
|
-
class: "button-
|
|
130
|
+
class: "button-7fq9d0i380"
|
|
131
131
|
}, s.filterAttrs(t.attributes, !1), w(s.filterAttrs(t.attributes, !0), !0)), M(t.text), 17));
|
|
132
132
|
}
|
|
133
|
-
const ve = /* @__PURE__ */ g(ge, [["render", ye], ["__scopeId", "data-v-
|
|
133
|
+
const ve = /* @__PURE__ */ g(ge, [["render", ye], ["__scopeId", "data-v-465ad941"]]), V = (e) => JSON.parse(JSON.stringify(e)), Z = {
|
|
134
134
|
small: {
|
|
135
135
|
min: 320,
|
|
136
136
|
default: 321,
|
|
@@ -188,7 +188,7 @@ const ve = /* @__PURE__ */ g(ge, [["render", ye], ["__scopeId", "data-v-44d936dc
|
|
|
188
188
|
"Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",
|
|
189
189
|
e
|
|
190
190
|
), e;
|
|
191
|
-
}), Ce = () => import("./render-inlined-styles.
|
|
191
|
+
}), Ce = () => import("./render-inlined-styles.0773feb1.js").then((e) => e.default).catch((e) => {
|
|
192
192
|
throw console.error(
|
|
193
193
|
"Error while attempting to dynamically import component RenderInlinedStyles at ../../components/render-inlined-styles.vue",
|
|
194
194
|
e
|
|
@@ -321,7 +321,7 @@ function Ie(e, n, t, o, r, s) {
|
|
|
321
321
|
return d(), u("div", {
|
|
322
322
|
class: j(
|
|
323
323
|
s._classStringToObject(
|
|
324
|
-
`builder-columns ${t.builderBlock.id}-breakpoints div-
|
|
324
|
+
`builder-columns ${t.builderBlock.id}-breakpoints div-1eih9th5ow6`
|
|
325
325
|
)
|
|
326
326
|
),
|
|
327
327
|
style: I({
|
|
@@ -335,7 +335,7 @@ function Ie(e, n, t, o, r, s) {
|
|
|
335
335
|
}, null, 8, ["styles"])) : b("", !0),
|
|
336
336
|
(d(!0), u(E, null, F(t.columns, (c, l) => (d(), u("div", {
|
|
337
337
|
key: l,
|
|
338
|
-
class: "builder-column div-
|
|
338
|
+
class: "builder-column div-1eih9th5ow6-2",
|
|
339
339
|
style: I({
|
|
340
340
|
width: s.getColumnCssWidth(l),
|
|
341
341
|
marginLeft: `${l === 0 ? 0 : s.getGutterSize()}px`,
|
|
@@ -354,7 +354,7 @@ function Ie(e, n, t, o, r, s) {
|
|
|
354
354
|
], 4))), 128))
|
|
355
355
|
], 6);
|
|
356
356
|
}
|
|
357
|
-
const Te = /* @__PURE__ */ g(we, [["render", Ie], ["__scopeId", "data-v-
|
|
357
|
+
const Te = /* @__PURE__ */ g(we, [["render", Ie], ["__scopeId", "data-v-8bc87868"]]), Re = {
|
|
358
358
|
name: "builder-fragment-component",
|
|
359
359
|
props: []
|
|
360
360
|
};
|
|
@@ -454,7 +454,7 @@ const Oe = {
|
|
|
454
454
|
};
|
|
455
455
|
const Fe = ["srcset"], Be = ["alt", "role", "src", "srcset", "sizes"], Ue = {
|
|
456
456
|
key: 2,
|
|
457
|
-
class: "div-
|
|
457
|
+
class: "div-2btisl9m7v3-2"
|
|
458
458
|
};
|
|
459
459
|
function Ve(e, n, t, o, r, s) {
|
|
460
460
|
var a, i, c, l;
|
|
@@ -476,7 +476,7 @@ function Ve(e, n, t, o, r, s) {
|
|
|
476
476
|
}),
|
|
477
477
|
class: j(
|
|
478
478
|
s._classStringToObject(
|
|
479
|
-
"builder-image" + (t.className ? " " + t.className : "") + " img-
|
|
479
|
+
"builder-image" + (t.className ? " " + t.className : "") + " img-2btisl9m7v3"
|
|
480
480
|
)
|
|
481
481
|
),
|
|
482
482
|
src: t.image,
|
|
@@ -486,7 +486,7 @@ function Ve(e, n, t, o, r, s) {
|
|
|
486
486
|
]),
|
|
487
487
|
t.aspectRatio && !(((i = (a = t.builderBlock) == null ? void 0 : a.children) == null ? void 0 : i.length) && t.fitContent) ? (d(), u("div", {
|
|
488
488
|
key: 0,
|
|
489
|
-
class: "builder-image-sizer div-
|
|
489
|
+
class: "builder-image-sizer div-2btisl9m7v3",
|
|
490
490
|
style: I({
|
|
491
491
|
paddingTop: t.aspectRatio * 100 + "%"
|
|
492
492
|
})
|
|
@@ -497,7 +497,7 @@ function Ve(e, n, t, o, r, s) {
|
|
|
497
497
|
])) : b("", !0)
|
|
498
498
|
], 64);
|
|
499
499
|
}
|
|
500
|
-
const We = /* @__PURE__ */ g(Oe, [["render", Ve], ["__scopeId", "data-v-
|
|
500
|
+
const We = /* @__PURE__ */ g(Oe, [["render", Ve], ["__scopeId", "data-v-44c710e2"]]), Ne = Symbol(), W = {
|
|
501
501
|
Builder: {
|
|
502
502
|
content: null,
|
|
503
503
|
context: {},
|
|
@@ -516,12 +516,12 @@ function Le() {
|
|
|
516
516
|
function y() {
|
|
517
517
|
return Le() && window.location.search.indexOf("builder.frameEditing=") !== -1;
|
|
518
518
|
}
|
|
519
|
-
const Me = () => import("./block-styles.
|
|
519
|
+
const Me = () => import("./block-styles.5fb6e927.js").then((e) => e.default).catch((e) => {
|
|
520
520
|
throw console.error(
|
|
521
521
|
"Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",
|
|
522
522
|
e
|
|
523
523
|
), e;
|
|
524
|
-
}), $e = () => import("./render-block.
|
|
524
|
+
}), $e = () => import("./render-block.017ccb02.js").then((e) => e.default).catch((e) => {
|
|
525
525
|
throw console.error(
|
|
526
526
|
"Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",
|
|
527
527
|
e
|
|
@@ -584,7 +584,7 @@ const Ke = ["builder-path", "builder-parent-id", "dataSet"];
|
|
|
584
584
|
function He(e, n, t, o, r, s) {
|
|
585
585
|
const a = k("render-block"), i = k("block-styles");
|
|
586
586
|
return d(), u("div", {
|
|
587
|
-
class: j(s._classStringToObject(s.className + " div-
|
|
587
|
+
class: j(s._classStringToObject(s.className + " div-20vehov4ay6")),
|
|
588
588
|
"builder-path": t.path,
|
|
589
589
|
"builder-parent-id": t.parent,
|
|
590
590
|
dataSet: {
|
|
@@ -606,12 +606,11 @@ function He(e, n, t, o, r, s) {
|
|
|
606
606
|
}, null, 8, ["block", "context"]))), 128)) : b("", !0)
|
|
607
607
|
], 46, Ke);
|
|
608
608
|
}
|
|
609
|
-
const De = /* @__PURE__ */ g(ze, [["render", He], ["__scopeId", "data-v-
|
|
609
|
+
const De = /* @__PURE__ */ g(ze, [["render", He], ["__scopeId", "data-v-b5395d79"]]), ee = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
610
610
|
__proto__: null,
|
|
611
611
|
default: De
|
|
612
612
|
}, Symbol.toStringTag, { value: "Module" })), qe = {
|
|
613
613
|
name: "Core:Button",
|
|
614
|
-
builtIn: !0,
|
|
615
614
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
|
|
616
615
|
defaultStyles: {
|
|
617
616
|
appearance: "none",
|
|
@@ -651,7 +650,6 @@ const De = /* @__PURE__ */ g(ze, [["render", He], ["__scopeId", "data-v-1112d180
|
|
|
651
650
|
return `return (${!n.startsWith("function") && !n.startsWith("(") ? "function " : ""}${n}).apply(this, arguments)`;
|
|
652
651
|
}, Ge = {
|
|
653
652
|
name: "Columns",
|
|
654
|
-
builtIn: !0,
|
|
655
653
|
inputs: [
|
|
656
654
|
{
|
|
657
655
|
name: "columns",
|
|
@@ -878,13 +876,11 @@ const De = /* @__PURE__ */ g(ze, [["render", He], ["__scopeId", "data-v-1112d180
|
|
|
878
876
|
name: "Fragment",
|
|
879
877
|
static: !0,
|
|
880
878
|
hidden: !0,
|
|
881
|
-
builtIn: !0,
|
|
882
879
|
canHaveChildren: !0,
|
|
883
880
|
noWrap: !0
|
|
884
881
|
}, Xe = {
|
|
885
882
|
name: "Image",
|
|
886
883
|
static: !0,
|
|
887
|
-
builtIn: !0,
|
|
888
884
|
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",
|
|
889
885
|
defaultStyles: {
|
|
890
886
|
position: "relative",
|
|
@@ -1012,7 +1008,6 @@ const De = /* @__PURE__ */ g(ze, [["render", He], ["__scopeId", "data-v-1112d180
|
|
|
1012
1008
|
}, Ye = {
|
|
1013
1009
|
name: "Core:Section",
|
|
1014
1010
|
static: !0,
|
|
1015
|
-
builtIn: !0,
|
|
1016
1011
|
image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F682efef23ace49afac61748dd305c70a",
|
|
1017
1012
|
inputs: [
|
|
1018
1013
|
{
|
|
@@ -1092,7 +1087,6 @@ const et = /* @__PURE__ */ g(Qe, [["render", Ze]]), tt = {
|
|
|
1092
1087
|
name: "Symbol",
|
|
1093
1088
|
noWrap: !0,
|
|
1094
1089
|
static: !0,
|
|
1095
|
-
builtIn: !0,
|
|
1096
1090
|
inputs: [
|
|
1097
1091
|
{
|
|
1098
1092
|
name: "symbol",
|
|
@@ -1419,7 +1413,6 @@ function Ct(e, n, t, o, r, s) {
|
|
|
1419
1413
|
const wt = /* @__PURE__ */ g(St, [["render", Ct]]), It = {
|
|
1420
1414
|
name: "Text",
|
|
1421
1415
|
static: !0,
|
|
1422
|
-
builtIn: !0,
|
|
1423
1416
|
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",
|
|
1424
1417
|
inputs: [
|
|
1425
1418
|
{
|
|
@@ -1449,7 +1442,6 @@ function Et(e, n, t, o, r, s) {
|
|
|
1449
1442
|
const At = /* @__PURE__ */ g(Tt, [["render", Et]]), jt = {
|
|
1450
1443
|
name: "Video",
|
|
1451
1444
|
canHaveChildren: !0,
|
|
1452
|
-
builtIn: !0,
|
|
1453
1445
|
defaultStyles: {
|
|
1454
1446
|
minHeight: "20px",
|
|
1455
1447
|
minWidth: "20px"
|
|
@@ -1608,7 +1600,6 @@ function Ft(e, n, t, o, r, s) {
|
|
|
1608
1600
|
const Bt = /* @__PURE__ */ g(Pt, [["render", Ft]]), Ut = {
|
|
1609
1601
|
name: "Embed",
|
|
1610
1602
|
static: !0,
|
|
1611
|
-
builtIn: !0,
|
|
1612
1603
|
inputs: [
|
|
1613
1604
|
{
|
|
1614
1605
|
name: "url",
|
|
@@ -1735,7 +1726,6 @@ function Ht(e, n, t, o, r, s) {
|
|
|
1735
1726
|
const Dt = /* @__PURE__ */ g(zt, [["render", Ht]]), qt = {
|
|
1736
1727
|
name: "Raw:Img",
|
|
1737
1728
|
hideFromInsertMenu: !0,
|
|
1738
|
-
builtIn: !0,
|
|
1739
1729
|
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",
|
|
1740
1730
|
inputs: [
|
|
1741
1731
|
{
|
|
@@ -1810,7 +1800,6 @@ function Xt(e, n, t, o, r, s) {
|
|
|
1810
1800
|
const Yt = /* @__PURE__ */ g(Gt, [["render", Xt]]), Qt = {
|
|
1811
1801
|
name: "Custom Code",
|
|
1812
1802
|
static: !0,
|
|
1813
|
-
builtIn: !0,
|
|
1814
1803
|
requiredPermissions: ["editCode"],
|
|
1815
1804
|
inputs: [
|
|
1816
1805
|
{
|
|
@@ -2134,7 +2123,7 @@ const vn = (e, n, t = !0) => {
|
|
|
2134
2123
|
"Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",
|
|
2135
2124
|
e
|
|
2136
2125
|
), e;
|
|
2137
|
-
}), wn = () => import("./render-styles.
|
|
2126
|
+
}), wn = () => import("./render-styles.c79197c2.js").then((e) => e.default).catch((e) => {
|
|
2138
2127
|
throw console.error(
|
|
2139
2128
|
"Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",
|
|
2140
2129
|
e
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineAsyncComponent as f, resolveComponent as p, openBlock as s, createElementBlock as d, Fragment as h, createBlock as a, resolveDynamicComponent as v, normalizeProps as k, mergeProps as b, createCommentVNode as g, renderList as C, withCtx as P, createVNode as R, guardReactiveProps as S } from "vue";
|
|
2
|
-
import { e as _, T as w, b as A, _ as I } from "./index.
|
|
3
|
-
import { g as E } from "./get-processed-block.
|
|
2
|
+
import { e as _, T as w, b as A, _ as I } from "./index.8392057e.js";
|
|
3
|
+
import { g as E } from "./get-processed-block.48c68f6b.js";
|
|
4
4
|
const T = (e) => `v-on:${e.toLowerCase()}`, N = (e, t) => (n) => _({
|
|
5
5
|
code: e,
|
|
6
6
|
context: t.context,
|
|
@@ -129,17 +129,17 @@ const K = [
|
|
|
129
129
|
},
|
|
130
130
|
block: c
|
|
131
131
|
}));
|
|
132
|
-
}, F = () => import("./block-styles.
|
|
132
|
+
}, F = () => import("./block-styles.5fb6e927.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
|
-
}), G = () => import("./render-repeated-block.
|
|
137
|
+
}), G = () => import("./render-repeated-block.09b2f47e.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
|
-
}), U = () => import("./render-component.
|
|
142
|
+
}), U = () => import("./render-component.5b79b1a2.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.6275edf0.cjs"),h=require("./get-processed-block.e6e75aca.cjs"),y=e=>`v-on:${e.toLowerCase()}`,x=(e,o)=>n=>i.evaluate({code:e,context:o.context,state:o.state,event:n,isExpression:!1});function b(e){var s;const o={},n=(s=e.block.actions)!=null?s:{};for(const c in n){if(!n.hasOwnProperty(c))continue;const r=n[c];o[y(c)]=x(r,e)}return o}function f(e){var o;return{...(o=e.component)==null?void 0:o.options,...e.options,builderBlock:e}}function B(e){const o={};if(typeof e!="string")return o;const n=e.trim().split(/\\s+/);for(const s of n)o[s]=!0;return o}function g(e){return e.class=B(e.class),e}function C(e){var n;const o={...e.properties,"builder-id":e.id,style:v(e.style),class:[e.id,"builder-block",e.class,(n=e.properties)==null?void 0:n.class].filter(Boolean).join(" ")};return g(o)}function v(e){if(!!e)switch(i.TARGET){case"svelte":case"vue2":case"vue3":case"solid":return i.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:o})=>{var c;const n=(c=h.getProcessedBlock({block:e,state:o.state,context:o.context,shouldEvaluateBindings:!1}).component)==null?void 0:c.name;if(!n)return null;const s=o.registeredComponents[n];if(s)return s;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?`)},R=({block:e,context:o})=>{const{repeat:n,...s}=e;if(!(n!=null&&n.collection))return;const c=i.evaluate({code:n.collection,state:o.state,context:o.context});if(!Array.isArray(c))return;const r=n.collection.split(".").pop(),a=n.itemName||(r?r+"Item":"item");return c.map((m,p)=>({context:{...o,state:{...o.state,$index:p,$item:m,[a]:m,[`$${a}Index`]:p}},block:s}))},w=()=>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?`)},R=({block:e,context:o})=>{const{repeat:n,...s}=e;if(!(n!=null&&n.collection))return;const c=i.evaluate({code:n.collection,state:o.state,context:o.context});if(!Array.isArray(c))return;const r=n.collection.split(".").pop(),a=n.itemName||(r?r+"Item":"item");return c.map((m,p)=>({context:{...o,state:{...o.state,$index:p,$item:m,[a]:m,[`$${a}Index`]:p}},block:s}))},w=()=>Promise.resolve().then(()=>require("./block-styles.05a01a8e.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.802c4a21.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}),N=()=>Promise.resolve().then(()=>require("./render-component.626cb9a2.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderComponent at ./render-component.vue",e),e}),I={name:"render-block",components:{RenderComponent:t.defineAsyncComponent(N),RenderRepeatedBlock:t.defineAsyncComponent(A),BlockStyles:t.defineAsyncComponent(w)},props:["block","context"],data(){return{component:S({block:this.block,context:this.context}),repeatItemData:R({block:this.block,context:this.context}),isEmptyHtmlElement:_}},computed:{tag(){return P(this.useBlock)},useBlock(){return this.repeatItemData?this.block:h.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!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:(o,n,s)=>{var c,r;return o[n]=s,(r=(c=this.context).setState)==null||r.call(c,o),!0}})},actions(){return b({block:this.useBlock,state:this.proxyState,context:this.context.context})},attributes(){return{...C(this.useBlock)}},renderComponentProps(){var e,o,n,s,c,r;return{blockChildren:(e=this.useBlock.children)!=null?e:[],componentRef:(o=this.component)==null?void 0:o.component,componentOptions:{...f(this.useBlock),...(n=this.component)!=null&&n.noWrap?{attributes:{...this.attributes,...this.actions}}:{},customBreakpoints:(r=(c=(s=this.childrenContext)==null?void 0:s.content)==null?void 0:c.meta)==null?void 0:r.breakpoints},context:this.childrenContext}},childrenWithoutParentComponent(){var o,n;return!((o=this.component)!=null&&o.component)&&!this.repeatItemData?(n=this.useBlock.children)!=null?n:[]:[]},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()}}}};function T(e,o,n,s,c,r){var k;const a=t.resolveComponent("render-repeated-block"),u=t.resolveComponent("render-component"),m=t.resolveComponent("render-block",!0),p=t.resolveComponent("block-styles");return(k=c.component)!=null&&k.noWrap?(t.openBlock(),t.createBlock(u,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.normalizeProps(t.mergeProps({key:0},{...r.attributes,...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.normalizeProps(t.mergeProps({key:2},{...r.attributes,...r.actions})),{default:t.withCtx(()=>[t.createVNode(u,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(m,{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(p,{key:"block-style-"+l.id,block:l,context:r.childrenContext},null,8,["block","context"]))),128))]),_:1},16)):t.createCommentVNode("",!0)],64))}const j=i._export_sfc(I,[["render",T]]);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.8392057e.js";
|
|
3
|
+
const x = () => import("./block-styles.5fb6e927.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.017ccb02.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.6275edf0.cjs"),m=()=>Promise.resolve().then(()=>require("./block-styles.05a01a8e.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.f6f263a8.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,y,b){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.ca824cfb.js → render-inlined-styles.0773feb1.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.8392057e.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.6275edf0.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.645dd73e.js → render-repeated-block.09b2f47e.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.8392057e.js";
|
|
3
|
+
const l = () => import("./render-block.017ccb02.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.6275edf0.cjs"),c=()=>Promise.resolve().then(()=>require("./render-block.f6f263a8.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,d,n,i,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,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),a=require("./index.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),a=require("./index.6275edf0.cjs"),f=e=>{var c,s;const n=e.family+(e.kind&&!e.kind.includes("#")?", "+e.kind:""),t=n.split(",")[0],i=(s=e.fileUrl)!=null?s:(c=e==null?void 0:e.files)==null?void 0:c.regular;let r="";if(i&&n&&t&&(r+=`
|
|
2
2
|
@font-face {
|
|
3
3
|
font-family: "${n}";
|
|
4
4
|
src: local("${t}"), url('${i}') format('woff2');
|
|
@@ -12,7 +12,7 @@ src: url('${d}') format('woff2');
|
|
|
12
12
|
font-display: fallback;
|
|
13
13
|
font-weight: ${l};
|
|
14
14
|
}
|
|
15
|
-
`.trim())}return r},u=({customFonts:e})=>{var n;return((n=e==null?void 0:e.map(t=>f(t)))==null?void 0:n.join(" "))||""},m=({cssCode:e,contentId:n})=>e?n?(e==null?void 0:e.replace(/&/g,`div[builder-content-id="${n}"]`))||"":e:"",y=()=>Promise.resolve().then(()=>require("./render-inlined-styles.
|
|
15
|
+
`.trim())}return r},u=({customFonts:e})=>{var n;return((n=e==null?void 0:e.map(t=>f(t)))==null?void 0:n.join(" "))||""},m=({cssCode:e,contentId:n})=>e?n?(e==null?void 0:e.replace(/&/g,`div[builder-content-id="${n}"]`))||"":e:"",y=()=>Promise.resolve().then(()=>require("./render-inlined-styles.ab30b262.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}),p={name:"render-content-styles",components:{RenderInlinedStyles:o.defineAsyncComponent(y)},props:["cssCode","contentId","customFonts"],data(){return{injectedStyles:`
|
|
16
16
|
${m({cssCode:this.cssCode,contentId:this.contentId})}
|
|
17
17
|
${u({customFonts:this.customFonts})}
|
|
18
18
|
`}}};function g(e,n,t,i,r,c){const s=o.resolveComponent("render-inlined-styles");return o.openBlock(),o.createBlock(s,{styles:r.injectedStyles},null,8,["styles"])}const h=a._export_sfc(p,[["render",g]]);exports.default=h;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineAsyncComponent as a, resolveComponent as d, openBlock as f, createBlock as m } from "vue";
|
|
2
|
-
import { _ as p } from "./index.
|
|
2
|
+
import { _ as p } from "./index.8392057e.js";
|
|
3
3
|
const u = (e) => {
|
|
4
4
|
var o, s;
|
|
5
5
|
const t = e.family + (e.kind && !e.kind.includes("#") ? ", " + e.kind : ""), n = t.split(",")[0], i = (s = e.fileUrl) != null ? s : (o = e == null ? void 0 : e.files) == null ? void 0 : o.regular;
|
|
@@ -32,7 +32,7 @@ font-weight: ${l};
|
|
|
32
32
|
}, _ = ({
|
|
33
33
|
cssCode: e,
|
|
34
34
|
contentId: t
|
|
35
|
-
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", h = () => import("./render-inlined-styles.
|
|
35
|
+
}) => e ? t ? (e == null ? void 0 : e.replace(/&/g, `div[builder-content-id="${t}"]`)) || "" : e : "", h = () => import("./render-inlined-styles.0773feb1.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 +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.6275edf0.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 { d as t, C as r, F as n, I as o, r as i, h as m, S as g, i as c, j as d, V as l, m as S, v as C, o as p, u, w as h, x as P, q as B, k, l as v, y as w, p as x, n as y, s as F, t as R } from "./index.
|
|
1
|
+
import { d as t, C as r, F as n, I as o, r as i, h as m, S as g, i as c, j as d, V as l, m as S, v as C, o as p, u, w as h, x as P, q as B, k, l as v, y as w, p as x, n as y, s as F, t as R } from "./index.8392057e.js";
|
|
2
2
|
import "vue";
|
|
3
3
|
export {
|
|
4
4
|
t as Button,
|
|
@@ -122,7 +122,6 @@ export interface ComponentInfo {
|
|
|
122
122
|
* Passing a list of model names will restrict using the component to only the models listed here, otherwise it'll be available for all models
|
|
123
123
|
*/
|
|
124
124
|
models?: string[];
|
|
125
|
-
builtIn: true;
|
|
126
125
|
/**
|
|
127
126
|
* Specify restrictions direct children must match
|
|
128
127
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.button-
|
|
1
|
+
.button-7fq9d0i380[data-v-465ad941]{all:unset}.div-1eih9th5ow6[data-v-8bc87868]{display:flex;line-height:normal}.div-1eih9th5ow6-2[data-v-8bc87868]{display:flex;flex-direction:column;align-items:stretch}.img-2btisl9m7v3[data-v-44c710e2]{opacity:1;transition:opacity .2s ease-in-out}.div-2btisl9m7v3[data-v-44c710e2]{width:100%;pointer-events:none;font-size:0}.div-2btisl9m7v3-2[data-v-44c710e2]{display:flex;flex-direction:column;align-items:stretch;position:absolute;top:0;left:0;width:100%;height:100%}.div-20vehov4ay6[data-v-b5395d79]{display:flex;flex-direction:column;align-items:stretch}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
"use strict";const y="vue2";function p(){return typeof window<"u"&&typeof document<"u"}const A={};function V(t,e){let n=A[t];if(n||(n=A[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(s){console.debug("Could not postmessage",s)}}}const he=()=>{V("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 P=!1;const fe=(t={})=>{var e,n;P||(P=!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 s,r;if(!!(o!=null&&o.type))switch(o.type){case"builder.evaluate":{const a=o.data.text,i=o.data.arguments||[],l=o.data.id,c=new Function(a);let d,m=null;try{d=c.apply(null,i)}catch(u){m=u}m?(s=window.parent)==null||s.postMessage({type:"builder.evaluateError",data:{id:l,error:m.message}},"*"):d&&typeof d.then=="function"?d.then(u=>{var g;(g=window.parent)==null||g.postMessage({type:"builder.evaluateResult",data:{id:l,result:u}},"*")}).catch(console.error):(r=window.parent)==null||r.postMessage({type:"builder.evaluateResult",data:{result:d,id:l}},"*");break}}})))},ge={name:"builder-button",props:["attributes","text","link","openLinkInNewTab"],methods:{filterAttrs:function(e={},n){const o="v-on:",s=i=>i.startsWith(o),r=i=>!i.startsWith(o),a=i=>i.replace(o,"");return Object.keys(e).filter(n?s:r).reduce((i,l)=>({...i,[a(l)]:e[l]}),{})}}};function h(t,e,n,o,s,r,a,i){var l=typeof t=="function"?t.options:t;e&&(l.render=e,l.staticRenderFns=n,l._compiled=!0),o&&(l.functional=!0),r&&(l._scopeId="data-v-"+r);var c;if(a?(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__),s&&s.call(this,u),u&&u._registeredComponents&&u._registeredComponents.add(a)},l._ssrRegister=c):s&&(c=i?function(){s.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:s),c)if(l.functional){l._injectStyles=c;var d=l.render;l.render=function(g,E){return c.call(E),d(g,E)}}else{var m=l.beforeCreate;l.beforeCreate=m?[].concat(m,c):[c]}return{exports:t,options:l}}var be=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)+" ")])},ye=[],ve=h(ge,be,ye,!1,null,"37bd4cbd",null,null);const N=ve.exports,_=t=>JSON.parse(JSON.stringify(t)),M={small:{min:320,default:321,max:640},medium:{min:641,default:642,max:991},large:{min:990,default:991,max:1200}},_e=(t,e=M)=>`@media (max-width: ${e[t].max}px)`,L=({small:t,medium:e})=>{const n=_(M);if(!t||!e)return n;const o=Math.floor(t/2);n.small={max:t,min:o,default:o+1};const s=n.small.max+1;n.medium={max:e,min:s,default:s+1};const r=n.medium.max+1;return n.large={max:2e3,min:r,default:r+1},n},xe=t=>t.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),b=t=>t!=null,z=t=>Object.entries(t).map(([n,o])=>{if(typeof o=="string")return`${xe(n)}: ${o};`}).filter(b),v=t=>z(t).join(`
|
|
2
|
-
`),ke=({mediaQuery:t,className:e,styles:n})=>{const o=`.${e} {
|
|
3
|
-
${v(n)}
|
|
4
|
-
}`;return t?`${t} {
|
|
5
|
-
${o}
|
|
6
|
-
}`:o},Ce=()=>Promise.resolve().then(()=>G).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",t),t}),Se=()=>Promise.resolve().then(()=>require("./render-inlined-styles.362de669.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}),we={name:"builder-columns",components:{RenderInlinedStyles:Se,RenderBlocks:Ce},props:["space","columns","stackColumnsAt","reverseColumnsWhenStacked","customBreakpoints","builderBlock"],data(){return{TARGET:y}},computed:{columnsCssVars(){const t=this.stackColumnsAt==="never"?"inherit":this.reverseColumnsWhenStacked?"column-reverse":"column";return{"--flex-dir":t,"--flex-dir-tablet":this.maybeApplyForTablet(t)}},columnCssVars(){const t="100%",e="0";return{"--column-width":t,"--column-margin-left":e,"--column-width-tablet":this.maybeApplyForTablet(t),"--column-margin-left-tablet":this.maybeApplyForTablet(e)}},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
|
-
${v(this.columnStyleObjects.columns.medium)}
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.${this.builderBlock.id}-breakpoints > .builder-column {
|
|
13
|
-
${v(this.columnStyleObjects.column.medium)}
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
@media (max-width: ${this.getWidthForBreakpointSize("small")}px) {
|
|
18
|
-
.${this.builderBlock.id}-breakpoints {
|
|
19
|
-
${v(this.columnStyleObjects.columns.small)}
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
.${this.builderBlock.id}-breakpoints > .builder-column {
|
|
23
|
-
${v(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(t){var n;const e=this.getColumns();return((n=e[t])==null?void 0:n.width)||100/e.length},getColumnCssWidth(t){const e=this.getColumns(),o=this.getGutterSize()*(e.length-1)/e.length;return`calc(${this.getWidth(t)}% - ${o}px)`},maybeApplyForTablet(t){return(this.stackColumnsAt||"tablet")==="tablet"?t:"inherit"},getWidthForBreakpointSize(t){return L(this.customBreakpoints||{})[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 Ie=function(){var e=this,n=e._self._c;return n("div",{class:e._classStringToObject(`builder-columns ${e.builderBlock.id}-breakpoints div-t9spj7joih`),style:{...e.TARGET==="reactNative"?e.reactNativeColumnsStyles:{},...e.columnsCssVars}},[e.TARGET!=="reactNative"?[n("render-inlined-styles",{attrs:{styles:e.columnsStyles}})]:e._e(),e._l(e.columns,function(o,s){return n("div",{key:s,staticClass:"builder-column div-t9spj7joih-2",style:{width:e.getColumnCssWidth(s),marginLeft:`${s===0?0:e.getGutterSize()}px`,...e.TARGET==="reactNative"?e.reactNativeColumnStyles:{},...e.columnCssVars}},[n("render-blocks",{attrs:{blocks:o.blocks,path:`component.options.columns.${s}.blocks`,parent:e.builderBlock.id,styleProp:{flexGrow:"1"}}})],1)})],2)},Re=[],Te=h(we,Ie,Re,!1,null,"72d9045b",null,null);const K=Te.exports,$e={name:"builder-fragment-component",props:[]};var Ee=function(){var e=this,n=e._self._c;return n("span",[e._t("default")],2)},Ae=[],Pe=h($e,Ee,Ae,!1,null,null,null,null);const D=Pe.exports;function F(t){return t.replace(/http(s)?:/,"")}function Fe(t="",e,n){const o=new RegExp("([?&])"+e+"=.*?(&|$)","i"),s=t.indexOf("?")!==-1?"&":"?";return t.match(o)?t.replace(o,"$1"+e+"="+encodeURIComponent(n)+"$2"):t+s+e+"="+encodeURIComponent(n)}function je(t,e){if(!t||!(t!=null&&t.match(/cdn\.shopify\.com/))||!e)return t;if(e==="master")return F(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]),s=n[3],r=e.match("x")?e:`${e}x`;return F(`${o[0]}_${r}${s}`)}return null}function C(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(s=>s!==o).map(s=>`${Fe(t,"width",s)} ${s}w`).concat([n]).join(", ")}return t.match(/cdn\.shopify\.com/)?e.map(n=>[je(t,`${n}x${n}`),n]).filter(([n])=>!!n).map(([n,o])=>`${n} ${o}w`).concat([t]).join(", "):t}const Oe={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"),C(e)}else if(this.image&&!this.srcset)return C(e);return C(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 Be=function(){var o,s,r,a;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&&!(((s=(o=e.builderBlock)==null?void 0:o.children)==null?void 0:s.length)&&e.fitContent)?[n("div",{staticClass:"builder-image-sizer div-1pl23ac79ld",style:{paddingTop:e.aspectRatio*100+"%"}})]:e._e(),((a=(r=e.builderBlock)==null?void 0:r.children)==null?void 0:a.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)},Ue=[],We=h(Oe,Be,Ue,!1,null,"d14c6f82",null,null);const H=We.exports,Ve=Symbol(),x={Builder:{content:null,context:{},state:{},setState(){},apiKey:null,registeredComponents:{},inheritedStyles:{}},key:Ve};function Ne(){return p()&&window.self!==window.top}function f(){return Ne()&&window.location.search.indexOf("builder.frameEditing=")!==-1}const Me=()=>Promise.resolve().then(()=>require("./block-styles.0c522549.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}),Le=()=>Promise.resolve().then(()=>require("./render-block.d4d3c07e.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}),ze={name:"render-blocks",components:{RenderBlock:Le,BlockStyles:Me},props:["blocks","parent","path","styleProp"],inject:{builderContext:x.key},computed:{className(){var t;return"builder-blocks"+((t=this.blocks)!=null&&t.length?"":" no-blocks")}},methods:{onClick(){var t,e;f()&&!((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;f()&&!((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 Ke=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,s){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,s){return n("block-styles",{key:"block-style-"+o.id,attrs:{block:o,context:e.builderContext}})}):e._e()],2)},De=[],He=h(ze,Ke,De,!1,null,"7d4553c5",null,null);const q=He.exports,G=Object.freeze(Object.defineProperty({__proto__:null,default:q},Symbol.toStringTag,{value:"Module"})),qe={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},k=t=>{const e=t.toString().trim();return`return (${!e.startsWith("function")&&!e.startsWith("(")?"function ":""}${e}).apply(this, arguments)`},Ge={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:k(t=>{function e(){n.forEach(o=>{o.delete("width")})}const n=t.get("columns");Array.isArray(n)&&!!n.find(s=>s.get("width"))&&(!!n.find(r=>!r.get("width"))||n.reduce((i,l)=>i+l.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}]},Je={name:"Fragment",static:!0,hidden:!0,builtIn:!0,canHaveChildren:!0,noWrap:!0},Xe={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:k(t=>{t.delete("srcset"),t.delete("noWebp");function n(a,i=6e4){return new Promise((l,c)=>{const d=document.createElement("img");let m=!1;d.onload=()=>{m=!0,l(d)},d.addEventListener("error",u=>{console.warn("Image load failed",u.error),c(u.error)}),d.src=a,setTimeout(()=>{m||c(new Error("Image load timed out"))},i)})}function o(a){return Math.round(a*1e3)/1e3}const s=t.get("image"),r=t.get("aspectRatio");if(fetch(s).then(a=>a.blob()).then(a=>{a.type.includes("svg")&&t.set("noWebp",!0)}),s&&(!r||r===.7041))return n(s).then(a=>{const i=t.get("aspectRatio");t.get("image")===s&&(!i||i===.7041)&&a.width&&a.height&&(t.set("aspectRatio",o(a.height/a.width)),t.set("height",a.height),t.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}]},Ye={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>"}}}]},Qe={name:"builder-section-component",props:["maxWidth","attributes"],methods:{filterAttrs:function(e={},n){const o="v-on:",s=i=>i.startsWith(o),r=i=>!i.startsWith(o),a=i=>i.replace(o,"");return Object.keys(e).filter(n?s:r).reduce((i,l)=>({...i,[a(l)]:e[l]}),{})}}};var Ze=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&&typeof e.maxWidth=="number"?e.maxWidth:1200}px`,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)},et=[],tt=h(Qe,Ze,et,!1,null,null,null,null);const J=tt.exports,nt={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"}]};function ot(){return typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:globalThis}function st(){const t=ot().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.
|
|
27
|
-
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 X=st(),rt=t=>{if(t==="localhost"||t==="127.0.0.1")return t;const e=t.split(".");return e.length>2?e.slice(1).join("."):t},Y=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}},it=t=>t.map(([e,n])=>n?`${e}=${n}`:e).filter(b).join("; "),at=[["secure",""],["SameSite","None"]],lt=({name:t,value:e,expires:n})=>{const s=(p()?location.protocol==="https:":!0)?at:[[]],r=n?[["expires",n.toUTCString()]]:[[]],a=[[t,e],...r,["path","/"],["domain",rt(window.location.hostname)],...s];return it(a)},Q=async({name:t,value:e,expires:n,canTrack:o})=>{try{if(!o)return;const s=lt({name:t,value:e,expires:n});document.cookie=s}catch(s){console.warn("[COOKIE] SET error: ",s)}},ct="builderio.variations",Z=t=>`${ct}.${t}`,ut=({contentId:t,canTrack:e})=>Y({name:Z(t),canTrack:e}),dt=({contentId:t,canTrack:e,value:n})=>Q({name:Z(t),value:n,canTrack:e}),mt=t=>b(t.id)&&b(t.variations)&&Object.keys(t.variations).length>0,pt=({id:t,variations:e})=>{var s;let n=0;const o=Math.random();for(const r in e)if(n+=(s=e[r])==null?void 0:s.testRatio,o<n)return r;return t},j=({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":"")}},ht=async({item:t,canTrack:e})=>{const n=await ut({canTrack:e,contentId:t.id}),o=n?j({item:t,testGroupId:n}):void 0;if(o)return o;{const s=pt({variations:t.variations,id:t.id});return dt({contentId:t.id,value:s,canTrack:e}).catch(r=>{console.error("could not store A/B test variation: ",r)}),j({item:t,testGroupId:s})}},ft=async({item:t,canTrack:e})=>{if(!mt(t))return;const n=await ht({item:t,canTrack:e});Object.assign(t,n)};function S(t,e=null,n="."){return Object.keys(t).reduce((o,s)=>{const r=t[s],a=[e,s].filter(Boolean).join(n);return[typeof r=="object",r!==null,!(Array.isArray(r)&&r.length===0)].every(Boolean)?{...o,...S(r,a,n)}:{...o,[a]:r}},{})}const O="builder.",gt="options.",ee=t=>{const e={};return t.forEach((n,o)=>{e[o]=n}),e},te=t=>{if(!t)return{};const e=R(t),n={};return Object.keys(e).forEach(o=>{if(o.startsWith(O)){const s=o.replace(O,"").replace(gt,"");n[s]=e[o]}}),n},ne=()=>{if(!p())return{};const t=new URLSearchParams(window.location.search);return te(t)},R=t=>t instanceof URLSearchParams?ee(t):t,bt=t=>{const{limit:e=30,userAttributes:n,query:o,noTraverse:s=!1,model:r,apiKey:a,includeRefs:i=!0,locale:l}=t;if(!a)throw new Error("Missing API key");const c=new URL(`https://cdn.builder.io/api/v2/content/${r}?apiKey=${a}&limit=${e}&noTraverse=${s}&includeRefs=${i}${l?`&locale=${l}`:""}`),d={...ne(),...R(t.options||{})},m=S(d);for(const u in m)c.searchParams.set(u,String(m[u]));if(n&&c.searchParams.set("userAttributes",JSON.stringify(n)),o){const u=S({query:o});for(const g in u)c.searchParams.set(g,JSON.stringify(u[g]))}return c};async function T(t){return(await oe({...t,limit:1})).results[0]||null}async function oe(t){const e=bt(t),o=await(await X(e.href)).json(),s=t.canTrack!==!1;if(s&&Array.isArray(o.results))for(const r of o.results)await ft({item:r,canTrack:s});return o}const yt=()=>Promise.resolve().then(()=>En).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}),vt={name:"builder-symbol",components:{RenderContent:yt},props:["attributes","symbol","dynamic"],data(){return{fetchedContent:null}},inject:{builderContext:x.key},watch:{onUpdateHook0:{handler(){var e;const t=this.symbol;t&&!t.content&&!this.fetchedContent&&t.model&&((e=this.builderContext)==null?void 0:e.apiKey)&&T({model:t.model,apiKey:this.builderContext.apiKey,query:{id:t.entry}}).then(n=>{this.fetchedContent=n})},immediate:!0}},computed:{className(){var t,e;return[...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(){var t;return((t=this.symbol)==null?void 0:t.content)||this.fetchedContent},onUpdateHook0(){return{0:this.symbol,1:this.fetchedContent}}},methods:{filterAttrs:function(e={},n){const o="v-on:",s=i=>i.startsWith(o),r=i=>!i.startsWith(o),a=i=>i.replace(o,"");return Object.keys(e).filter(n?s:r).reduce((i,l)=>({...i,[a(l)]:e[l]}),{})},_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 _t=function(){var o,s,r,a,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:{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,...(a=(r=(s=e.symbol)==null?void 0:s.content)==null?void 0:r.data)==null?void 0:a.state},model:(i=e.symbol)==null?void 0:i.model,content:e.contentToUse}})],1)},xt=[],kt=h(vt,_t,xt,!1,null,null,null,null);const se=kt.exports,Ct={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"}},St={name:"builder-text",props:["text"]};var wt=function(){var e=this,n=e._self._c;return n("span",{staticClass:"builder-text",domProps:{innerHTML:e._s(e.text)}})},It=[],Rt=h(St,wt,It,!1,null,null,null,null);const re=Rt.exports,Tt={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}]},$t={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 Et=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))},At=[],Pt=h($t,Et,At,!1,null,null,null,null);const ie=Pt.exports,Ft={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: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}]},jt=["text/javascript","application/javascript","application/ecmascript"],Ot=t=>jt.includes(t.type),Bt={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(Ot(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 Ut=function(){var e=this,n=e._self._c;return n("div",{ref:"elem",staticClass:"builder-embed",domProps:{innerHTML:e._s(e.content)}})},Wt=[],Vt=h(Bt,Ut,Wt,!1,null,null,null,null);const Nt=Vt.exports,Mt={name:"builder-img-component",props:["backgroundSize","backgroundPosition","imgSrc","altText","image","attributes"],data(){return{isEditing:f}},methods:{filterAttrs:function(e={},n){const o="v-on:",s=i=>i.startsWith(o),r=i=>!i.startsWith(o),a=i=>i.replace(o,"");return Object.keys(e).filter(n?s:r).reduce((i,l)=>({...i,[a(l)]:e[l]}),{})}}};var Lt=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)))},zt=[],Kt=h(Mt,Lt,zt,!1,null,null,null,null);const Dt=Kt.exports,Ht={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},qt={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 Gt=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)}})},Jt=[],Xt=h(qt,Gt,Jt,!1,null,null,null,null);const Yt=Xt.exports,Qt={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}]},Zt=()=>[{component:N,...qe},{component:K,...Ge},{component:Yt,...Qt},{component:Nt,...Ft},{component:D,...Je},{component:H,...Xe},{component:Dt,...Ht},{component:J,...Ye},{component:se,...nt},{component:re,...Ct},{component:ie,...Tt}];function w({code:t,context:e,state:n,event:o,isExpression:s=!0}){if(t===""){console.warn("Skipping evaluation of empty code block.");return}const r={isEditing:f(),isBrowser:p(),isServer:!p()},i=s&&!(t.includes(";")||t.includes(" return ")||t.trim().startsWith("return "))?`return (${t});`:t;try{return new Function("builder","Builder","state","context","event",i)(r,r,n,e,o)}catch(l){console.warn(`Builder custom code error:
|
|
28
|
-
While Evaluating:
|
|
29
|
-
`,i,`
|
|
30
|
-
`,l)}}function ae(){return!p()||f()?!1:Boolean(location.search.indexOf("builder.preview=")!==-1)}const $=[];function en(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 le=({component:t,...e})=>({type:"builder.registerComponent",data:nn(e)}),tn=t=>typeof t=="function"?k(t):_(t),nn=({inputs:t,...e})=>({..._(e),inputs:t==null?void 0:t.map(n=>Object.entries(n).reduce((o,[s,r])=>({...o,[s]:tn(r)}),{}))});function on(){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 ce(){return on().replace(/-/g,"")}const ue="builderSessionId",sn=async({canTrack:t})=>{if(!t)return;const e=await Y({name:ue,canTrack:t});if(b(e))return e;{const n=rn();return an({id:n,canTrack:t}),n}},rn=()=>ce(),an=({id:t,canTrack:e})=>Q({name:ue,value:t,canTrack:e}),de=()=>p()&&typeof localStorage<"u"?localStorage:void 0,ln=({key:t,canTrack:e})=>{var n;try{return e?(n=de())==null?void 0:n.getItem(t):void 0}catch(o){console.debug("[LocalStorage] GET error: ",o);return}},cn=({key:t,canTrack:e,value:n})=>{var o;try{e&&((o=de())==null||o.setItem(t,n))}catch(s){console.debug("[LocalStorage] SET error: ",s)}},me="builderVisitorId",un=({canTrack:t})=>{if(!t)return;const e=ln({key:me,canTrack:t});if(b(e))return e;{const n=dn();return mn({id:n,canTrack:t}),n}},dn=()=>ce(),mn=({id:t,canTrack:e})=>cn({key:me,value:t,canTrack:e}),pn=()=>{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},hn=()=>typeof navigator=="object"&&navigator.userAgent||"",fn=()=>{const t=hn(),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=pn();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"}},gn=async({canTrack:t})=>{if(!t)return{visitorId:void 0,sessionId:void 0};const e=await sn({canTrack:t}),n=un({canTrack:t});return{sessionId:e,visitorId:n}},bn=async({type:t,canTrack:e,apiKey:n,metadata:o,...s})=>({type:t,data:{...s,metadata:{url:location.href,...o},...await gn({canTrack:e}),userAttributes:fn(),ownerId:n}});async function I(t){if(!t.apiKey){console.error("[Builder.io]: Missing API key for track call. Please provide your API key.");return}if(!!t.canTrack&&!f()&&!!(p()||y==="reactNative"))return fetch("https://builder.io/api/v1/track",{method:"POST",body:JSON.stringify({events:[await bn(t)]}),headers:{"content-type":"application/json"},mode:"cors"}).catch(e=>{console.error("Failed to track: ",e)})}const yn=t=>I({...t,canTrack:!0});function B(t){return Math.round(t*1e3)/1e3}const vn=(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},_n=t=>vn(t,e=>{const n=e.getAttribute("builder-id")||e.id;return Boolean((n==null?void 0:n.indexOf("builder-"))===0)}),U=({event:t,target:e})=>{const n=e.getBoundingClientRect(),o=t.clientX-n.left,s=t.clientY-n.top,r=B(o/n.width),a=B(s/n.height);return{x:r,y:a}},xn=t=>{const e=t.target,n=e&&_n(e),o=(n==null?void 0:n.getAttribute("builder-id"))||(n==null?void 0:n.id);return{targetBuilderElement:o||void 0,metadata:{targetOffset:e?U({event:t,target:e}):void 0,builderTargetOffset:n?U({event:t,target:n}):void 0,builderElementIndex:n&&o?[].slice.call(document.getElementsByClassName(o)).indexOf(n):void 0}}},kn=({content:t,data:e,locale:n})=>{var r,a,i;const o={};(a=(r=t==null?void 0:t.data)==null?void 0:r.inputs)==null||a.forEach(l=>{var c;l.name&&l.defaultValue!==void 0&&((c=t==null?void 0:t.data)==null?void 0:c.state)&&t.data.state[l.name]===void 0&&(o[l.name]=l.defaultValue)});const s={...(i=t==null?void 0:t.data)==null?void 0:i.state,...e,...n?{locale:n}:{}};return{...o,...s}},Cn=({content:t,data:e})=>t?{...t,data:{...t==null?void 0:t.data,...e},meta:t==null?void 0:t.meta}:void 0,Sn=()=>Promise.resolve().then(()=>G).then(t=>t.default).catch(t=>{throw console.error("Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",t),t}),wn=()=>Promise.resolve().then(()=>require("./render-styles.956991f6.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}),In={name:"render-content",components:{RenderContentStyles:wn,RenderBlocks:Sn},props:["content","data","canTrack","locale","customComponents","model","context","apiKey","includeRefs"],data(){return{forceReRenderCount:0,overrideContent:null,useContent:Cn({content:this.content,data:this.data}),update:0,canTrackToUse:b(this.canTrack)?this.canTrack:!0,contentState:kn({content:this.content,data:this.data,locale:this.locale}),allRegisteredComponents:[...Zt(),...$,...this.customComponents||[]].reduce((t,e)=>({...t,[e.name]:e}),{}),httpReqsData:{},clicked:!1}},provide(){const t=this;return{[x.key]:{content:t.useContent,state:t.contentState,setState:t.setContextState,context:t.context||{},apiKey:t.apiKey,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(f()&&(this.forceReRenderCount=this.forceReRenderCount+1,he(),fe({...this.locale?{locale:this.locale}:{},...this.includeRefs?{includeRefs:this.includeRefs}:{}}),Object.values(this.allRegisteredComponents).forEach(n=>{var s;const o=le(n);(s=window.parent)==null||s.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;I({type:"impression",canTrack:this.canTrackToUse,contentId:o,apiKey:this.apiKey,variationId:n!==o?n:void 0})}if(ae()){const n=new URL(location.href).searchParams,o=n.get("builder.preview"),s=n.get("apiKey")||n.get("builder.space");o===this.model&&s===this.apiKey&&T({model:this.model,apiKey:this.apiKey}).then(r=>{r&&this.mergeNewContent(r)})}this.evaluateJsCode(),this.runHttpRequests(),this.emitStateUpdate()}},watch:{onUpdateHook0:{handler(){this.evaluateJsCode()},immediate:!0},onUpdateHook1:{handler(){this.runHttpRequests()},immediate:!0},onUpdateHook2:{handler(){this.emitStateUpdate()},immediate:!0}},unmounted(){p()&&(window.removeEventListener("message",this.processMessage),window.removeEventListener("builder:component:stateChangeListenerActivated",this.emitStateUpdate))},computed:{shouldRenderContentStyles(){var t,e,n,o,s;return Boolean((((e=(t=this.useContent)==null?void 0:t.data)==null?void 0:e.cssCode)||((s=(o=(n=this.useContent)==null?void 0:n.data)==null?void 0:o.customFonts)==null?void 0:s.length))&&y!=="reactNative")},onUpdateHook0(){var t,e;return{0:(e=(t=this.useContent)==null?void 0:t.data)==null?void 0:e.jsCode,1:this.contentState}},onUpdateHook1(){var t,e;return{0:(e=(t=this.useContent)==null?void 0:t.data)==null?void 0:e.httpRequests}},onUpdateHook2(){return{0:this.contentState}}},methods:{mergeNewContent(t){var e,n,o,s,r;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)||((r=(s=this.useContent)==null?void 0:s.meta)==null?void 0:r.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:s,contentId:r}=o;if(!r||r!==((n=this.useContent)==null?void 0:n.id))return;s&&this.setBreakpoints(s),this.forceReRenderCount=this.forceReRenderCount+1;break}case"builder.contentUpdate":{const o=e.data,s=o.key||o.alias||o.entry||o.modelName,r=o.data;s===this.model&&(this.mergeNewContent(r),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,s=(n=this.useContent)==null?void 0:n.id;I({type:"click",canTrack:this.canTrackToUse,contentId:s,apiKey:this.apiKey,variationId:o!==s?o:void 0,...xn(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}){X(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(([s,r])=>{if(r&&(!this.httpReqsData[s]||f())){const a=this.evalExpression(r);this.handleRequest({url:a,key:s})}})},emitStateUpdate(){f()&&window.dispatchEvent(new CustomEvent("builder:component:stateChange",{detail:{state:this.contentState,ref:{name:this.model}}}))}}};var Rn=function(){var o,s,r,a,i,l,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(m){return e.onClick(m)}}},[e.shouldRenderContentStyles?[n("render-content-styles",{attrs:{contentId:(s=e.useContent)==null?void 0:s.id,cssCode:(a=(r=e.useContent)==null?void 0:r.data)==null?void 0:a.cssCode,customFonts:(l=(i=e.useContent)==null?void 0:i.data)==null?void 0:l.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()},Tn=[],$n=h(In,Rn,Tn,!1,null,null,null,null);const pe=$n.exports,En=Object.freeze(Object.defineProperty({__proto__:null,default:pe},Symbol.toStringTag,{value:"Module"})),W={};function An(t){if(p()){Object.assign(W,t);const e={type:"builder.settingsChange",data:W};parent.postMessage(e,"*")}}exports.BuilderContext=x;exports.Button=N;exports.Columns=K;exports.Fragment=D;exports.Image=H;exports.Section=J;exports.Symbol=se;exports.TARGET=y;exports.Text=re;exports.Video=ie;exports.components=$;exports.convertSearchParamsToQueryObject=ee;exports.convertStyleMapToCSSArray=z;exports.createCssClass=ke;exports.createRegisterComponentMessage=le;exports.evaluate=w;exports.fastClone=_;exports.getAllContent=oe;exports.getBuilderSearchParams=te;exports.getBuilderSearchParamsFromWindow=ne;exports.getContent=T;exports.getMaxWidthQueryForSize=_e;exports.getSizesForBreakpoints=L;exports.isEditing=f;exports.isPreviewing=ae;exports.normalizeComponent=h;exports.normalizeSearchParams=R;exports.register=V;exports.registerComponent=en;exports.renderBlocks=q;exports.renderContent=pe;exports.setEditorSettings=An;exports.track=yn;
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index.e93e18ce.cjs"),u=require("./get-processed-block.100e890c.cjs"),d=e=>`v-on:${e.toLowerCase()}`,p=(e,t)=>n=>c.evaluate({code:e,context:t.context,state:t.state,event:n,isExpression:!1});function m(e){var r;const t={},n=(r=e.block.actions)!=null?r:{};for(const o in n){if(!n.hasOwnProperty(o))continue;const s=n[o];t[d(o)]=p(s,e)}return t}function h(e){var t;return{...(t=e.component)==null?void 0:t.options,...e.options,builderBlock:e}}function k(e){const t={};if(typeof e!="string")return t;const n=e.trim().split(/\\s+/);for(const r of n)t[r]=!0;return t}function f(e){return e.class=k(e.class),e}function x(e){var n;const t={...e.properties,"builder-id":e.id,style:b(e.style),class:[e.id,"builder-block",e.class,(n=e.properties)==null?void 0:n.class].filter(Boolean).join(" ")};return f(t)}function b(e){if(!!e)switch(c.TARGET){case"svelte":case"vue2":case"vue3":case"solid":return c.convertStyleMapToCSSArray(e).join(" ");case"qwik":case"reactNative":case"react":return e}}function y(e){return e.tagName||"div"}const g=["area","base","br","col","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],v=e=>typeof e=="string"&&g.includes(e.toLowerCase()),C=({block:e,context:t})=>{var o;const n=(o=u.getProcessedBlock({block:e,state:t.state,context:t.context,shouldEvaluateBindings:!1}).component)==null?void 0:o.name;if(!n)return null;const r=t.registeredComponents[n];if(r)return r;console.warn(`
|
|
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?`)},B=({block:e,context:t})=>{const{repeat:n,...r}=e;if(!(n!=null&&n.collection))return;const o=c.evaluate({code:n.collection,state:t.state,context:t.context});if(!Array.isArray(o))return;const s=n.collection.split(".").pop(),i=n.itemName||(s?s+"Item":"item");return o.map((a,l)=>({context:{...t,state:{...t.state,$index:l,$item:a,[i]:a,[`$${i}Index`]:l}},block:r}))},_=()=>Promise.resolve().then(()=>require("./block-styles.0c522549.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component BlockStyles at ./block-styles.vue",e),e}),P=()=>Promise.resolve().then(()=>require("./render-repeated-block.8881a0f1.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}),E=()=>Promise.resolve().then(()=>require("./render-component.1220773f.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderComponent at ./render-component.vue",e),e}),S={name:"render-block",components:{RenderComponent:E,RenderRepeatedBlock:P,BlockStyles:_},props:["block","context"],data(){return{component:C({block:this.block,context:this.context}),repeatItemData:B({block:this.block,context:this.context}),isEmptyHtmlElement:v}},computed:{tag(){return y(this.useBlock)},useBlock(){return this.repeatItemData?this.block:u.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!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:(t,n,r)=>{var o,s;return t[n]=r,(s=(o=this.context).setState)==null||s.call(o,t),!0}})},actions(){return m({block:this.useBlock,state:this.proxyState,context:this.context.context})},attributes(){return{...x(this.useBlock)}},renderComponentProps(){var e,t,n,r,o,s;return{blockChildren:(e=this.useBlock.children)!=null?e:[],componentRef:(t=this.component)==null?void 0:t.component,componentOptions:{...h(this.useBlock),...(n=this.component)!=null&&n.noWrap?{attributes:{...this.attributes,...this.actions}}:{},customBreakpoints:(s=(o=(r=this.childrenContext)==null?void 0:r.content)==null?void 0:o.meta)==null?void 0:s.breakpoints},context:this.childrenContext}},childrenWithoutParentComponent(){var t,n;return!((t=this.component)!=null&&t.component)&&!this.repeatItemData?(n=this.useBlock.children)!=null?n:[]:[]},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()}}}};var w=function(){var r;var t=this,n=t._self._c;return Boolean(!((r=t.component)!=null&&r.noWrap))?t.isEmptyHtmlElement(t.tag)?n(t.tag,t._b({tag:"component"},"component",{...t.attributes,...t.actions},!1)):!t.isEmptyHtmlElement(t.tag)&&t.repeatItemData?n("div",{staticClass:"vue2-root-element-workaround"},t._l(t.repeatItemData,function(o,s){return n("render-repeated-block",{key:s,attrs:{repeatContext:o.context,block:o.block}})}),1):n(t.tag,t._b({tag:"component"},"component",{...t.attributes,...t.actions},!1),[n("render-component",t._b({},"render-component",t.renderComponentProps,!1)),t._l(t.childrenWithoutParentComponent,function(o,s){return n("render-block",{key:"render-block-"+o.id,attrs:{block:o,context:t.childrenContext}})}),t._l(t.childrenWithoutParentComponent,function(o,s){return n("block-styles",{key:"block-style-"+o.id,attrs:{block:o,context:t.childrenContext}})})],2):n("render-component",t._b({},"render-component",t.renderComponentProps,!1))},R=[],T=c.normalizeComponent(S,w,R,!1,null,null,null,null);const j=T.exports;exports.default=j;
|