@builder.io/sdk-vue 0.1.14 → 0.1.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/package.json +1 -1
  2. package/packages/_vue2/dist/{block-styles.a33b589b.cjs → block-styles.083832a5.cjs} +1 -1
  3. package/packages/_vue2/dist/{block-styles.e4fa133a.js → block-styles.c935448f.js} +3 -3
  4. package/packages/_vue2/dist/{css.a4a781f2.cjs → css.125be5c3.cjs} +2 -2
  5. package/packages/_vue2/dist/{css.9a515005.js → css.67faf460.js} +1 -1
  6. package/packages/_vue2/dist/{index.3826ad2c.js → index.15db69ec.js} +118 -89
  7. package/packages/_vue2/dist/index.5d490ae1.cjs +29 -0
  8. package/packages/_vue2/dist/{render-block.8857ae34.js → render-block.68937b99.js} +8 -7
  9. package/packages/_vue2/dist/{render-block.65396344.cjs → render-block.ff5b481d.cjs} +2 -2
  10. package/packages/_vue2/dist/{render-component.d54274f2.js → render-component.4c69d70d.js} +3 -3
  11. package/packages/_vue2/dist/{render-component.b187cca7.cjs → render-component.dfd75a2e.cjs} +1 -1
  12. package/packages/_vue2/dist/{render-inlined-styles.aaa60ee3.cjs → render-inlined-styles.0013a71a.cjs} +1 -1
  13. package/packages/_vue2/dist/{render-inlined-styles.f560a740.js → render-inlined-styles.d5d4ae0d.js} +1 -1
  14. package/packages/_vue2/dist/{render-repeated-block.a24ffa4d.cjs → render-repeated-block.bf521eab.cjs} +1 -1
  15. package/packages/_vue2/dist/{render-repeated-block.43d7ad78.js → render-repeated-block.e5408f18.js} +2 -2
  16. package/packages/_vue2/dist/{render-styles.06311886.js → render-styles.107ba326.js} +2 -2
  17. package/packages/_vue2/dist/{render-styles.3df98784.cjs → render-styles.1fad2590.cjs} +3 -3
  18. package/packages/_vue2/dist/sdk.cjs +1 -1
  19. package/packages/_vue2/dist/sdk.js +1 -1
  20. package/packages/_vue2/dist/src/blocks/button/button.vue.d.ts +1 -0
  21. package/packages/_vue2/dist/src/blocks/columns/columns.vue.d.ts +13 -11
  22. package/packages/_vue2/dist/src/blocks/symbol/symbol.vue.d.ts +9 -9
  23. package/packages/_vue2/dist/src/components/render-block/block-styles.vue.d.ts +2 -2
  24. package/packages/_vue2/dist/src/components/render-block/render-block.vue.d.ts +2 -2
  25. package/packages/_vue2/dist/src/components/render-block/render-component.vue.d.ts +2 -2
  26. package/packages/_vue2/dist/src/components/render-blocks.vue.d.ts +1 -1
  27. package/packages/_vue2/dist/src/components/render-content/render-content.vue.d.ts +10 -9
  28. package/packages/_vue2/dist/src/context/types.d.ts +1 -1
  29. package/packages/_vue2/dist/src/functions/get-content/index.d.ts +5 -5
  30. package/packages/_vue2/dist/style.css +1 -1
  31. package/packages/_vue3/dist/{block-styles.c334abc4.cjs → block-styles.2a45708e.cjs} +1 -1
  32. package/packages/_vue3/dist/{block-styles.6bad6a44.js → block-styles.a6b0fdfd.js} +3 -3
  33. package/packages/_vue3/dist/{css.9c26446d.cjs → css.23dfb27d.cjs} +1 -1
  34. package/packages/_vue3/dist/{css.162effaf.js → css.d614b61b.js} +1 -1
  35. package/packages/_vue3/dist/index.60a69463.cjs +29 -0
  36. package/packages/_vue3/dist/{index.77da28db.js → index.8e00fba7.js} +106 -77
  37. package/packages/_vue3/dist/render-block.5d56e77f.cjs +3 -0
  38. package/packages/_vue3/dist/{render-block.55844e87.js → render-block.96a49d1c.js} +68 -46
  39. package/packages/_vue3/dist/render-component.17648f34.cjs +1 -0
  40. package/packages/_vue3/dist/render-component.b2532a6b.js +26 -0
  41. package/packages/_vue3/dist/{render-inlined-styles.799a72a2.js → render-inlined-styles.4cf0869f.js} +1 -1
  42. package/packages/_vue3/dist/{render-inlined-styles.a41845aa.cjs → render-inlined-styles.553ae14b.cjs} +1 -1
  43. package/packages/_vue3/dist/{render-repeated-block.3650cb4b.js → render-repeated-block.37707927.js} +4 -4
  44. package/packages/_vue3/dist/render-repeated-block.57e71440.cjs +1 -0
  45. package/packages/_vue3/dist/{render-styles.6ed62c76.js → render-styles.17630af3.js} +2 -2
  46. package/packages/_vue3/dist/{render-styles.c70124f9.cjs → render-styles.ecbf096b.cjs} +2 -2
  47. package/packages/_vue3/dist/sdk.cjs +1 -1
  48. package/packages/_vue3/dist/sdk.js +1 -1
  49. package/packages/_vue3/dist/src/blocks/button/button.vue.d.ts +1 -0
  50. package/packages/_vue3/dist/src/blocks/columns/columns.vue.d.ts +13 -11
  51. package/packages/_vue3/dist/src/blocks/image/image.vue.d.ts +1 -1
  52. package/packages/_vue3/dist/src/blocks/symbol/symbol.vue.d.ts +18 -9
  53. package/packages/_vue3/dist/src/components/render-block/block-styles.vue.d.ts +2 -2
  54. package/packages/_vue3/dist/src/components/render-block/render-block.vue.d.ts +2 -2
  55. package/packages/_vue3/dist/src/components/render-block/render-component.vue.d.ts +2 -2
  56. package/packages/_vue3/dist/src/components/render-blocks.vue.d.ts +1 -1
  57. package/packages/_vue3/dist/src/components/render-content/render-content.vue.d.ts +10 -9
  58. package/packages/_vue3/dist/src/context/types.d.ts +1 -1
  59. package/packages/_vue3/dist/src/functions/get-content/index.d.ts +5 -5
  60. package/packages/_vue3/dist/style.css +1 -1
  61. package/packages/_vue2/dist/index.9e0fbaa1.cjs +0 -29
  62. package/packages/_vue3/dist/index.51c251ae.cjs +0 -29
  63. package/packages/_vue3/dist/render-block.75044288.cjs +0 -3
  64. package/packages/_vue3/dist/render-component.445bfcc5.js +0 -42
  65. package/packages/_vue3/dist/render-component.a3596f45.cjs +0 -1
  66. package/packages/_vue3/dist/render-repeated-block.9f7871c0.cjs +0 -1
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "workspaces": [
5
5
  "packages/*"
6
6
  ],
7
- "version": "0.1.14",
7
+ "version": "0.1.16",
8
8
  "main": "./packages/_vue2/dist/sdk.js",
9
9
  "module": "./packages/_vue2/dist/sdk.js",
10
10
  "type": "module",
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index.9e0fbaa1.cjs"),o=require("./css.a4a781f2.cjs"),h=()=>Promise.resolve().then(()=>require("./render-inlined-styles.aaa60ee3.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderInlinedStyles at ../render-inlined-styles.vue",e),e}),y={name:"block-styles",components:{RenderInlinedStyles:h},props:["block","context"],data(){return{TARGET:t.TARGET}},computed:{useBlock(){return o.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!0})},canShowBlock(){return t.checkIsDefined(this.useBlock.hide)?!this.useBlock.hide:t.checkIsDefined(this.useBlock.show)?this.useBlock.show:!0},css(){var a;const e=this.useBlock.responsiveStyles,s=this.context.content,n=t.getSizesForBreakpoints(((a=s==null?void 0:s.meta)==null?void 0:a.breakpoints)||{}),r=e==null?void 0:e.large,c=e==null?void 0:e.medium,i=e==null?void 0:e.small,l=this.useBlock.id,u=r?o.createCssClass({className:l,styles:r}):"",d=c?o.createCssClass({className:l,styles:c,mediaQuery:t.getMaxWidthQueryForSize("medium",n)}):"",m=i?o.createCssClass({className:l,styles:i,mediaQuery:t.getMaxWidthQueryForSize("small",n)}):"";return[u,d,m].join(" ")}}};var k=function(){var s=this,n=s._self._c;return s.TARGET!=="reactNative"&&s.css&&s.canShowBlock?n("render-inlined-styles",{attrs:{styles:s.css}}):s._e()},S=[],p=t.normalizeComponent(y,k,S,!1,null,null,null,null);const f=p.exports;exports.default=f;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index.5d490ae1.cjs"),o=require("./css.125be5c3.cjs"),h=()=>Promise.resolve().then(()=>require("./render-inlined-styles.0013a71a.cjs")).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component RenderInlinedStyles at ../render-inlined-styles.vue",e),e}),y={name:"block-styles",components:{RenderInlinedStyles:h},props:["block","context"],data(){return{TARGET:t.TARGET}},computed:{useBlock(){return o.getProcessedBlock({block:this.block,state:this.context.state,context:this.context.context,shouldEvaluateBindings:!0})},canShowBlock(){return t.checkIsDefined(this.useBlock.hide)?!this.useBlock.hide:t.checkIsDefined(this.useBlock.show)?this.useBlock.show:!0},css(){var a;const e=this.useBlock.responsiveStyles,s=this.context.content,n=t.getSizesForBreakpoints(((a=s==null?void 0:s.meta)==null?void 0:a.breakpoints)||{}),l=e==null?void 0:e.large,r=e==null?void 0:e.medium,i=e==null?void 0:e.small,c=this.useBlock.id,d=l?o.createCssClass({className:c,styles:l}):"",u=r?o.createCssClass({className:c,styles:r,mediaQuery:t.getMaxWidthQueryForSize("medium",n)}):"",m=i?o.createCssClass({className:c,styles:i,mediaQuery:t.getMaxWidthQueryForSize("small",n)}):"";return[d,u,m].join(" ")}}};var k=function(){var s=this,n=s._self._c;return s.TARGET!=="reactNative"&&s.css&&s.canShowBlock?n("render-inlined-styles",{attrs:{styles:s.css}}):s._e()},S=[],p=t.normalizeComponent(y,k,S,!1,null,null,null,null);const _=p.exports;exports.default=_;
@@ -1,6 +1,6 @@
1
- import { T as k, c as i, g as p, a as u, n as y } from "./index.3826ad2c.js";
2
- import { g as _, c as o } from "./css.9a515005.js";
3
- const S = () => import("./render-inlined-styles.f560a740.js").then((e) => e.default).catch((e) => {
1
+ import { T as k, c as i, g as p, a as u, n as y } from "./index.15db69ec.js";
2
+ import { g as _, c as o } from "./css.67faf460.js";
3
+ const S = () => import("./render-inlined-styles.d5d4ae0d.js").then((e) => e.default).catch((e) => {
4
4
  throw console.error(
5
5
  "Error while attempting to dynamically import component RenderInlinedStyles at ../render-inlined-styles.vue",
6
6
  e
@@ -1,6 +1,6 @@
1
- "use strict";const i=require("./index.9e0fbaa1.cjs"),l=(e,t,r)=>{if(Object(e)!==e)return e;const s=Array.isArray(t)?t:t.toString().match(/[^.[\]]+/g);return s.slice(0,-1).reduce((n,o,c)=>Object(n[o])===n[o]?n[o]:n[o]=Math.abs(Number(s[c+1]))>>0===+s[c+1]?[]:{},e)[s[s.length-1]]=r,e};const f=({block:e,context:t,state:r})=>{if(!e.bindings)return e;const s=i.fastClone(e),n={...s,properties:{...s.properties},actions:{...s.actions}};for(const o in e.bindings){const c=e.bindings[o],u=i.evaluate({code:c,state:r,context:t});l(n,o,u)}return n};function d({block:e,context:t,shouldEvaluateBindings:r,state:s}){const n=e;return r?f({block:n,state:s,context:t}):n}const p=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),a=e=>Object.entries(e).map(([r,s])=>{if(typeof s=="string")return`${p(r)}: ${s};`}).filter(i.checkIsDefined),g=e=>a(e).join(`
1
+ "use strict";const i=require("./index.5d490ae1.cjs"),l=(e,t,r)=>{if(Object(e)!==e)return e;const s=Array.isArray(t)?t:t.toString().match(/[^.[\]]+/g);return s.slice(0,-1).reduce((n,o,c)=>Object(n[o])===n[o]?n[o]:n[o]=Math.abs(Number(s[c+1]))>>0===+s[c+1]?[]:{},e)[s[s.length-1]]=r,e};const d=({block:e,context:t,state:r})=>{if(!e.bindings)return e;const s=i.fastClone(e),n={...s,properties:{...s.properties},actions:{...s.actions}};for(const o in e.bindings){const c=e.bindings[o],u=i.evaluate({code:c,state:r,context:t});l(n,o,u)}return n};function f({block:e,context:t,shouldEvaluateBindings:r,state:s}){const n=e;return r?d({block:n,state:s,context:t}):n}const p=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),a=e=>Object.entries(e).map(([r,s])=>{if(typeof s=="string")return`${p(r)}: ${s};`}).filter(i.checkIsDefined),g=e=>a(e).join(`
2
2
  `),C=({mediaQuery:e,className:t,styles:r})=>{const s=`.${t} {
3
3
  ${g(r)}
4
4
  }`;return e?`${e} {
5
5
  ${s}
6
- }`:s};exports.convertStyleMapToCSSArray=a;exports.createCssClass=C;exports.getProcessedBlock=d;
6
+ }`:s};exports.convertStyleMapToCSSArray=a;exports.createCssClass=C;exports.getProcessedBlock=f;
@@ -1,4 +1,4 @@
1
- import { f as a, e as u, c as f } from "./index.3826ad2c.js";
1
+ import { f as a, e as u, c as f } from "./index.15db69ec.js";
2
2
  const l = (e, t, r) => {
3
3
  if (Object(e) !== e)
4
4
  return e;
@@ -14,6 +14,15 @@ const G = {
14
14
  }),
15
15
  {}
16
16
  );
17
+ },
18
+ _classStringToObject(t) {
19
+ const e = {};
20
+ if (typeof t != "string")
21
+ return e;
22
+ const n = t.trim().split(/\s+/);
23
+ for (const o of n)
24
+ e[o] = !0;
25
+ return e;
17
26
  }
18
27
  }
19
28
  };
@@ -46,18 +55,20 @@ function h(t, e, n, o, s, r, i, l) {
46
55
  }
47
56
  var J = function() {
48
57
  var e = this, n = e._self._c;
49
- 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) + " ")]);
58
+ 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({ class: e._classStringToObject(
59
+ e.attributes.class + " button-2fnk003dqad"
60
+ ) }, "button", e.filterAttrs(e.attributes, !1), !1), e.filterAttrs(e.attributes, !0)), [e._v(" " + e._s(e.text) + " ")]);
50
61
  }, X = [], Y = /* @__PURE__ */ h(
51
62
  G,
52
63
  J,
53
64
  X,
54
65
  !1,
55
66
  null,
56
- "3e6fa42c",
67
+ "65a02987",
57
68
  null,
58
69
  null
59
70
  );
60
- const Q = Y.exports, w = (t) => JSON.parse(JSON.stringify(t)), P = {
71
+ const Q = Y.exports, w = (t) => JSON.parse(JSON.stringify(t)), V = {
61
72
  small: {
62
73
  min: 320,
63
74
  default: 321,
@@ -73,8 +84,8 @@ const Q = Y.exports, w = (t) => JSON.parse(JSON.stringify(t)), P = {
73
84
  default: 991,
74
85
  max: 1200
75
86
  }
76
- }, Cn = (t, e = P) => `@media (max-width: ${e[t].max}px)`, Z = ({ small: t, medium: e }) => {
77
- const n = w(P);
87
+ }, Cn = (t, e = V) => `@media (max-width: ${e[t].max}px)`, Z = ({ small: t, medium: e }) => {
88
+ const n = w(V);
78
89
  if (!t || !e)
79
90
  return n;
80
91
  const o = Math.floor(t / 2);
@@ -113,7 +124,7 @@ const Q = Y.exports, w = (t) => JSON.parse(JSON.stringify(t)), P = {
113
124
  "Error while attempting to dynamically import component RenderBlocks at ../../components/render-blocks.vue",
114
125
  t
115
126
  ), t;
116
- }), ne = () => import("./render-inlined-styles.f560a740.js").then((t) => t.default).catch((t) => {
127
+ }), ne = () => import("./render-inlined-styles.d5d4ae0d.js").then((t) => t.default).catch((t) => {
117
128
  throw console.error(
118
129
  "Error while attempting to dynamically import component RenderInlinedStyles at ../../components/render-inlined-styles.vue",
119
130
  t
@@ -190,14 +201,21 @@ const Q = Y.exports, w = (t) => JSON.parse(JSON.stringify(t)), P = {
190
201
  const e = this.gutterSize * (this.cols.length - 1) / this.cols.length;
191
202
  return `calc(${this.getWidth(t)}% - ${e}px)`;
192
203
  },
193
- getTabletStyle({ stackedStyle: t, desktopStyle: e }) {
204
+ getTabletStyle({
205
+ stackedStyle: t,
206
+ desktopStyle: e
207
+ }) {
194
208
  return this.stackAt === "tablet" ? t : e;
195
209
  },
196
- getMobileStyle({ stackedStyle: t, desktopStyle: e }) {
210
+ getMobileStyle({
211
+ stackedStyle: t,
212
+ desktopStyle: e
213
+ }) {
197
214
  return this.stackAt === "never" ? e : t;
198
215
  },
199
216
  columnCssVars(t) {
200
- const e = this.getColumnCssWidth(t), n = `${t === 0 ? 0 : this.gutterSize}px`, o = "100%", s = 0;
217
+ t === 0 || this.gutterSize;
218
+ const e = this.getColumnCssWidth(t), n = `${this.gutterSize}px`, o = "100%", s = 0;
201
219
  return {
202
220
  width: e,
203
221
  "margin-left": n,
@@ -255,7 +273,7 @@ var se = function() {
255
273
  re,
256
274
  !1,
257
275
  null,
258
- "bcf8543c",
276
+ "2bb878ea",
259
277
  null,
260
278
  null
261
279
  );
@@ -383,7 +401,7 @@ var ge = function() {
383
401
  be,
384
402
  !1,
385
403
  null,
386
- "d14c6f82",
404
+ "b5206874",
387
405
  null,
388
406
  null
389
407
  );
@@ -397,12 +415,12 @@ function _e() {
397
415
  function g() {
398
416
  return _e() && window.location.search.indexOf("builder.frameEditing=") !== -1;
399
417
  }
400
- const xe = () => import("./block-styles.e4fa133a.js").then((t) => t.default).catch((t) => {
418
+ const xe = () => import("./block-styles.c935448f.js").then((t) => t.default).catch((t) => {
401
419
  throw console.error(
402
420
  "Error while attempting to dynamically import component BlockStyles at ./render-block/block-styles.vue",
403
421
  t
404
422
  ), t;
405
- }), ke = () => import("./render-block.8857ae34.js").then((t) => t.default).catch((t) => {
423
+ }), ke = () => import("./render-block.68937b99.js").then((t) => t.default).catch((t) => {
406
424
  throw console.error(
407
425
  "Error while attempting to dynamically import component RenderBlock at ./render-block/render-block.vue",
408
426
  t
@@ -477,14 +495,14 @@ var Ce = function() {
477
495
  we,
478
496
  !1,
479
497
  null,
480
- "7d4553c5",
498
+ "57df98d3",
481
499
  null,
482
500
  null
483
501
  );
484
- const Ie = Re.exports, O = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
502
+ const Te = Re.exports, O = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
485
503
  __proto__: null,
486
- default: Ie
487
- }, Symbol.toStringTag, { value: "Module" })), Te = {
504
+ default: Te
505
+ }, Symbol.toStringTag, { value: "Module" })), Ie = {
488
506
  name: "Core:Button",
489
507
  image: "https://cdn.builder.io/api/v1/image/assets%2FIsxPKMo2gPRRKeakUztj1D6uqed2%2F81a15681c3e74df09677dfc57a615b13",
490
508
  defaultStyles: {
@@ -943,7 +961,7 @@ const Ie = Re.exports, O = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.
943
961
  }
944
962
  }
945
963
  };
946
- var Ve = function() {
964
+ var Pe = function() {
947
965
  var e = this, n = e._self._c;
948
966
  return n("section", e._g(e._b({ style: {
949
967
  width: "100%",
@@ -957,10 +975,10 @@ var Ve = function() {
957
975
  marginLeft: "auto",
958
976
  marginRight: "auto"
959
977
  } }, "section", e.filterAttrs(e.attributes, !1), !1), e.filterAttrs(e.attributes, !0)), [e._t("default")], 2);
960
- }, Pe = [], Oe = /* @__PURE__ */ h(
978
+ }, Ve = [], Oe = /* @__PURE__ */ h(
961
979
  je,
962
- Ve,
963
980
  Pe,
981
+ Ve,
964
982
  !1,
965
983
  null,
966
984
  null,
@@ -1018,7 +1036,7 @@ function Me() {
1018
1036
  ), new Error("Builder SDK could not find a global `fetch` function");
1019
1037
  return t;
1020
1038
  }
1021
- const B = Me(), b = (t) => t != null, Le = (t) => {
1039
+ const B = Me(), b = (t) => t != null, Ne = (t) => {
1022
1040
  if (t === "localhost" || t === "127.0.0.1")
1023
1041
  return t;
1024
1042
  const e = t.split(".");
@@ -1034,22 +1052,22 @@ const B = Me(), b = (t) => t != null, Le = (t) => {
1034
1052
  console.debug("[COOKIE] GET error: ", o);
1035
1053
  return;
1036
1054
  }
1037
- }, Ne = (t) => t.map(([e, n]) => n ? `${e}=${n}` : e).filter(b).join("; "), Ke = [
1055
+ }, Le = (t) => t.map(([e, n]) => n ? `${e}=${n}` : e).filter(b).join("; "), ze = [
1038
1056
  ["secure", ""],
1039
1057
  ["SameSite", "None"]
1040
- ], ze = ({
1058
+ ], Ke = ({
1041
1059
  name: t,
1042
1060
  value: e,
1043
1061
  expires: n
1044
1062
  }) => {
1045
- const s = (p() ? location.protocol === "https:" : !0) ? Ke : [[]], r = n ? [["expires", n.toUTCString()]] : [[]], i = [
1063
+ const s = (p() ? location.protocol === "https:" : !0) ? ze : [[]], r = n ? [["expires", n.toUTCString()]] : [[]], i = [
1046
1064
  [t, e],
1047
1065
  ...r,
1048
1066
  ["path", "/"],
1049
- ["domain", Le(window.location.hostname)],
1067
+ ["domain", Ne(window.location.hostname)],
1050
1068
  ...s
1051
1069
  ];
1052
- return Ne(i);
1070
+ return Le(i);
1053
1071
  }, W = async ({
1054
1072
  name: t,
1055
1073
  value: e,
@@ -1059,7 +1077,7 @@ const B = Me(), b = (t) => t != null, Le = (t) => {
1059
1077
  try {
1060
1078
  if (!o)
1061
1079
  return;
1062
- const s = ze({ name: t, value: e, expires: n });
1080
+ const s = Ke({ name: t, value: e, expires: n });
1063
1081
  document.cookie = s;
1064
1082
  } catch (s) {
1065
1083
  console.warn("[COOKIE] SET error: ", s);
@@ -1084,7 +1102,7 @@ const B = Me(), b = (t) => t != null, Le = (t) => {
1084
1102
  return r;
1085
1103
  }
1086
1104
  return t;
1087
- }, I = ({
1105
+ }, T = ({
1088
1106
  item: t,
1089
1107
  testGroupId: e
1090
1108
  }) => {
@@ -1104,7 +1122,7 @@ const B = Me(), b = (t) => t != null, Le = (t) => {
1104
1122
  const n = await De({
1105
1123
  canTrack: e,
1106
1124
  contentId: t.id
1107
- }), o = n ? I({ item: t, testGroupId: n }) : void 0;
1125
+ }), o = n ? T({ item: t, testGroupId: n }) : void 0;
1108
1126
  if (o)
1109
1127
  return o;
1110
1128
  {
@@ -1118,7 +1136,7 @@ const B = Me(), b = (t) => t != null, Le = (t) => {
1118
1136
  canTrack: e
1119
1137
  }).catch((r) => {
1120
1138
  console.error("could not store A/B test variation: ", r);
1121
- }), I({ item: t, testGroupId: s });
1139
+ }), T({ item: t, testGroupId: s });
1122
1140
  }
1123
1141
  }, Ye = async ({
1124
1142
  item: t,
@@ -1139,7 +1157,7 @@ function S(t, e = null, n = ".") {
1139
1157
  ].every(Boolean) ? { ...o, ...S(r, i, n) } : { ...o, [i]: r };
1140
1158
  }, {});
1141
1159
  }
1142
- const T = "builder.", Qe = "options.", Ze = (t) => {
1160
+ const I = "builder.", Qe = "options.", Ze = (t) => {
1143
1161
  const e = {};
1144
1162
  return t.forEach((n, o) => {
1145
1163
  e[o] = n;
@@ -1147,10 +1165,10 @@ const T = "builder.", Qe = "options.", Ze = (t) => {
1147
1165
  }, et = (t) => {
1148
1166
  if (!t)
1149
1167
  return {};
1150
- const e = L(t), n = {};
1168
+ const e = N(t), n = {};
1151
1169
  return Object.keys(e).forEach((o) => {
1152
- if (o.startsWith(T)) {
1153
- const s = o.replace(T, "").replace(Qe, "");
1170
+ if (o.startsWith(I)) {
1171
+ const s = o.replace(I, "").replace(Qe, "");
1154
1172
  n[s] = e[o];
1155
1173
  }
1156
1174
  }), n;
@@ -1159,7 +1177,7 @@ const T = "builder.", Qe = "options.", Ze = (t) => {
1159
1177
  return {};
1160
1178
  const t = new URLSearchParams(window.location.search);
1161
1179
  return et(t);
1162
- }, L = (t) => t instanceof URLSearchParams ? Ze(t) : t, nt = (t) => {
1180
+ }, N = (t) => t instanceof URLSearchParams ? Ze(t) : t, nt = (t) => {
1163
1181
  const {
1164
1182
  limit: e = 30,
1165
1183
  userAttributes: n,
@@ -1181,7 +1199,7 @@ const T = "builder.", Qe = "options.", Ze = (t) => {
1181
1199
  `https://cdn.builder.io/api/${c}/content/${r}?apiKey=${i}&limit=${e}&noTraverse=${s}&includeRefs=${l}${a ? `&locale=${a}` : ""}`
1182
1200
  ), m = {
1183
1201
  ...tt(),
1184
- ...L(t.options || {})
1202
+ ...N(t.options || {})
1185
1203
  }, u = S(m);
1186
1204
  for (const f in u)
1187
1205
  d.searchParams.set(f, String(u[f]));
@@ -1192,14 +1210,22 @@ const T = "builder.", Qe = "options.", Ze = (t) => {
1192
1210
  }
1193
1211
  return d;
1194
1212
  };
1195
- async function N(t) {
1196
- return (await ot({ ...t, limit: 1 })).results[0] || null;
1213
+ async function L(t) {
1214
+ const e = await ot({ ...t, limit: 1 });
1215
+ return "results" in e && (e == null ? void 0 : e.results[0]) || null;
1197
1216
  }
1198
1217
  async function ot(t) {
1199
- const e = nt(t), o = await (await B(e.href)).json(), s = t.canTrack !== !1;
1200
- if (s && Array.isArray(o.results))
1201
- for (const r of o.results)
1202
- await Ye({ item: r, canTrack: s });
1218
+ const e = nt(t), o = await (await B(e.href)).json();
1219
+ if ("status" in o && !("results" in o))
1220
+ return console.error("[Builder.io]: Error fetching data. ", o, t), o;
1221
+ const s = t.canTrack !== !1;
1222
+ try {
1223
+ if (s && Array.isArray(o.results))
1224
+ for (const r of o.results)
1225
+ await Ye({ item: r, canTrack: s });
1226
+ } catch (r) {
1227
+ console.error("[Builder.io]: Could not setup A/B testing. ", r);
1228
+ }
1203
1229
  return o;
1204
1230
  }
1205
1231
  const st = () => Promise.resolve().then(() => Sn).then((t) => t.default).catch((t) => {
@@ -1247,7 +1273,7 @@ const st = () => Promise.resolve().then(() => Sn).then((t) => t.default).catch((
1247
1273
  methods: {
1248
1274
  fetchContent() {
1249
1275
  var t, e;
1250
- !this.contentToUse && ((t = this.symbol) == null ? void 0 : t.model) && ((e = this.builderContext) == null ? void 0 : e.apiKey) && N({
1276
+ !this.contentToUse && ((t = this.symbol) == null ? void 0 : t.model) && ((e = this.builderContext) == null ? void 0 : e.apiKey) && L({
1251
1277
  model: this.symbol.model,
1252
1278
  apiKey: this.builderContext.apiKey,
1253
1279
  apiVersion: this.builderContext.apiVersion,
@@ -1594,17 +1620,17 @@ const xt = _t.exports, kt = {
1594
1620
  var Rt = function() {
1595
1621
  var e = this, n = e._self._c;
1596
1622
  return n("div", { ref: "elem", staticClass: "builder-embed", domProps: { innerHTML: e._s(e.content) } });
1597
- }, It = [], Tt = /* @__PURE__ */ h(
1623
+ }, Tt = [], It = /* @__PURE__ */ h(
1598
1624
  wt,
1599
1625
  Rt,
1600
- It,
1626
+ Tt,
1601
1627
  !1,
1602
1628
  null,
1603
1629
  null,
1604
1630
  null,
1605
1631
  null
1606
1632
  );
1607
- const $t = Tt.exports, Et = {
1633
+ const $t = It.exports, Et = {
1608
1634
  name: "builder-img-component",
1609
1635
  props: [
1610
1636
  "backgroundSize",
@@ -1649,7 +1675,7 @@ var At = function() {
1649
1675
  null,
1650
1676
  null
1651
1677
  );
1652
- const Vt = jt.exports, Pt = {
1678
+ const Pt = jt.exports, Vt = {
1653
1679
  name: "Raw:Img",
1654
1680
  hideFromInsertMenu: !0,
1655
1681
  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",
@@ -1727,7 +1753,7 @@ var Bt = function() {
1727
1753
  null,
1728
1754
  null
1729
1755
  );
1730
- const Mt = Wt.exports, Lt = {
1756
+ const Mt = Wt.exports, Nt = {
1731
1757
  name: "Custom Code",
1732
1758
  static: !0,
1733
1759
  requiredPermissions: ["editCode"],
@@ -1753,14 +1779,14 @@ const Mt = Wt.exports, Lt = {
1753
1779
  advanced: !0
1754
1780
  }
1755
1781
  ]
1756
- }, Nt = () => [
1757
- { component: Q, ...Te },
1782
+ }, Lt = () => [
1783
+ { component: Q, ...Ie },
1758
1784
  { component: ae, ...$e },
1759
- { component: Mt, ...Lt },
1785
+ { component: Mt, ...Nt },
1760
1786
  { component: $t, ...kt },
1761
1787
  { component: pe, ...Ee },
1762
1788
  { component: ve, ...Ae },
1763
- { component: Vt, ...Pt },
1789
+ { component: Pt, ...Vt },
1764
1790
  { component: Be, ...Fe },
1765
1791
  { component: ct, ...Ue },
1766
1792
  { component: ft, ...dt },
@@ -1803,16 +1829,16 @@ function $({
1803
1829
  );
1804
1830
  }
1805
1831
  }
1806
- function Kt() {
1832
+ function zt() {
1807
1833
  return !p() || g() ? !1 : Boolean(location.search.indexOf("builder.preview=") !== -1);
1808
1834
  }
1809
- const K = [];
1835
+ const z = [];
1810
1836
  function wn(t, e) {
1811
- return K.push({ component: t, ...e }), console.warn(
1837
+ return z.push({ component: t, ...e }), console.warn(
1812
1838
  "registerComponent is deprecated. Use the `customComponents` prop in RenderContent instead to provide your custom components to the builder SDK."
1813
1839
  ), t;
1814
1840
  }
1815
- const zt = ({
1841
+ const Kt = ({
1816
1842
  component: t,
1817
1843
  ...e
1818
1844
  }) => ({
@@ -1839,7 +1865,7 @@ function qt() {
1839
1865
  return (t == "x" ? e : e & 3 | 8).toString(16);
1840
1866
  });
1841
1867
  }
1842
- function z() {
1868
+ function K() {
1843
1869
  return qt().replace(/-/g, "");
1844
1870
  }
1845
1871
  const H = "builderSessionId", Gt = async ({
@@ -1857,7 +1883,7 @@ const H = "builderSessionId", Gt = async ({
1857
1883
  const n = Jt();
1858
1884
  return Xt({ id: n, canTrack: t }), n;
1859
1885
  }
1860
- }, Jt = () => z(), Xt = ({
1886
+ }, Jt = () => K(), Xt = ({
1861
1887
  id: t,
1862
1888
  canTrack: e
1863
1889
  }) => W({ name: H, value: t, canTrack: e }), D = () => p() && typeof localStorage < "u" ? localStorage : void 0, Yt = ({
@@ -1895,7 +1921,7 @@ const H = "builderSessionId", Gt = async ({
1895
1921
  const n = en();
1896
1922
  return tn({ id: n, canTrack: t }), n;
1897
1923
  }
1898
- }, en = () => z(), tn = ({
1924
+ }, en = () => K(), tn = ({
1899
1925
  id: t,
1900
1926
  canTrack: e
1901
1927
  }) => Qt({
@@ -2147,7 +2173,7 @@ const un = (t, e, n = !0) => {
2147
2173
  "Error while attempting to dynamically import component RenderBlocks at ../render-blocks.vue",
2148
2174
  t
2149
2175
  ), t;
2150
- }), bn = () => import("./render-styles.06311886.js").then((t) => t.default).catch((t) => {
2176
+ }), bn = () => import("./render-styles.107ba326.js").then((t) => t.default).catch((t) => {
2151
2177
  throw console.error(
2152
2178
  "Error while attempting to dynamically import component RenderContentStyles at ./components/render-styles.vue",
2153
2179
  t
@@ -2186,8 +2212,8 @@ const un = (t, e, n = !0) => {
2186
2212
  locale: this.locale
2187
2213
  }),
2188
2214
  allRegisteredComponents: [
2189
- ...Nt(),
2190
- ...K,
2215
+ ...Lt(),
2216
+ ...z,
2191
2217
  ...this.customComponents || []
2192
2218
  ].reduce(
2193
2219
  (t, e) => ({
@@ -2227,13 +2253,13 @@ const un = (t, e, n = !0) => {
2227
2253
  ...this.includeRefs ? {
2228
2254
  includeRefs: this.includeRefs
2229
2255
  } : {}
2230
- }), Object.values(this.allRegisteredComponents).forEach(
2231
- (n) => {
2232
- var s;
2233
- const o = zt(n);
2234
- (s = window.parent) == null || s.postMessage(o, "*");
2235
- }
2236
- ), window.addEventListener("message", this.processMessage), window.addEventListener(
2256
+ }), Object.values(
2257
+ this.allRegisteredComponents
2258
+ ).forEach((n) => {
2259
+ var s;
2260
+ const o = Kt(n);
2261
+ (s = window.parent) == null || s.postMessage(o, "*");
2262
+ }), window.addEventListener("message", this.processMessage), window.addEventListener(
2237
2263
  "builder:component:stateChangeListenerActivated",
2238
2264
  this.emitStateUpdate
2239
2265
  )), this.useContent) {
@@ -2246,9 +2272,9 @@ const un = (t, e, n = !0) => {
2246
2272
  variationId: n !== o ? n : void 0
2247
2273
  });
2248
2274
  }
2249
- if (Kt()) {
2275
+ if (zt()) {
2250
2276
  const n = new URL(location.href).searchParams, o = n.get("builder.preview"), s = n.get("apiKey") || n.get("builder.space");
2251
- o === this.model && s === this.apiKey && N({
2277
+ o === this.model && s === this.apiKey && L({
2252
2278
  model: this.model,
2253
2279
  apiKey: this.apiKey,
2254
2280
  apiVersion: this.apiVersion
@@ -2408,7 +2434,7 @@ const un = (t, e, n = !0) => {
2408
2434
  };
2409
2435
  this.setContextState(o);
2410
2436
  }).catch((n) => {
2411
- console.log("error fetching dynamic data", t, n);
2437
+ console.error("error fetching dynamic data", t, n);
2412
2438
  });
2413
2439
  },
2414
2440
  runHttpRequests() {
@@ -2426,14 +2452,17 @@ const un = (t, e, n = !0) => {
2426
2452
  },
2427
2453
  emitStateUpdate() {
2428
2454
  g() && window.dispatchEvent(
2429
- new CustomEvent("builder:component:stateChange", {
2430
- detail: {
2431
- state: this.contentState,
2432
- ref: {
2433
- name: this.model
2455
+ new CustomEvent(
2456
+ "builder:component:stateChange",
2457
+ {
2458
+ detail: {
2459
+ state: this.contentState,
2460
+ ref: {
2461
+ name: this.model
2462
+ }
2434
2463
  }
2435
2464
  }
2436
- })
2465
+ )
2437
2466
  );
2438
2467
  }
2439
2468
  }
@@ -2457,13 +2486,13 @@ var vn = function() {
2457
2486
  const kn = xn.exports, Sn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2458
2487
  __proto__: null,
2459
2488
  default: kn
2460
- }, Symbol.toStringTag, { value: "Module" })), V = {};
2461
- function In(t) {
2489
+ }, Symbol.toStringTag, { value: "Module" })), P = {};
2490
+ function Tn(t) {
2462
2491
  if (p()) {
2463
- Object.assign(V, t);
2492
+ Object.assign(P, t);
2464
2493
  const e = {
2465
2494
  type: "builder.settingsChange",
2466
- data: V
2495
+ data: P
2467
2496
  };
2468
2497
  parent.postMessage(e, "*");
2469
2498
  }
@@ -2486,19 +2515,19 @@ export {
2486
2515
  ct as h,
2487
2516
  ft as i,
2488
2517
  g as j,
2489
- Kt as k,
2490
- K as l,
2518
+ zt as k,
2519
+ z as l,
2491
2520
  wn as m,
2492
2521
  h as n,
2493
- zt as o,
2522
+ Kt as o,
2494
2523
  ln as p,
2495
- N as q,
2496
- Ie as r,
2497
- In as s,
2524
+ L as q,
2525
+ Te as r,
2526
+ Tn as s,
2498
2527
  Rn as t,
2499
2528
  ot as u,
2500
2529
  Ze as v,
2501
2530
  et as w,
2502
2531
  tt as x,
2503
- L as y
2532
+ N as y
2504
2533
  };