@builder.io/sdk-vue 2.0.13 → 2.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/{edge/block-styles-mSowNIFi.js → browser/block-styles-nWGppwAf.js} +14 -12
- package/lib/browser/block-styles-rt4v7rBl.cjs +1 -0
- package/lib/browser/{block-wrapper-7wDwU1ik.js → block-wrapper-hPYvxseU.js} +3 -3
- package/lib/browser/{block-wrapper-ianIz_MG.cjs → block-wrapper-l_mdj42t.cjs} +1 -1
- package/lib/browser/{component-ref-yQ6WDHbR.js → component-ref-JlpkOrad.js} +2 -2
- package/lib/browser/{component-ref-MlfJPaLv.cjs → component-ref-dPnPtrON.cjs} +1 -1
- package/lib/{edge/get-block-properties-Hs6W4UwL.js → browser/get-block-properties-HzVZCpxa.js} +20 -18
- package/lib/browser/get-block-properties-sInACBRh.cjs +1 -0
- package/lib/browser/index-MDNnQzZB.cjs +166 -0
- package/lib/browser/{index-3j8dJ25f.js → index-ZL8QUFiN.js} +546 -552
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/init.cjs +8 -0
- package/lib/browser/init.mjs +65 -0
- package/lib/browser/logger-0-1mARBa.cjs +1 -0
- package/lib/browser/logger-Hm2e1Xk_.js +12 -0
- package/lib/browser/{repeated-block-_EQDFqYb.js → repeated-block-8EN4xN25.js} +2 -2
- package/lib/browser/{repeated-block-BBHHbrlK.cjs → repeated-block-uV-zuqkw.cjs} +1 -1
- package/lib/edge/block-styles-Ta3OQAmE.cjs +1 -0
- package/lib/{browser/block-styles-03Qg_nl9.js → edge/block-styles-zRPUnWLf.js} +6 -6
- package/lib/{node/block-wrapper-8DA9SdPk.cjs → edge/block-wrapper-9IWz2vxg.cjs} +1 -1
- package/lib/{node/block-wrapper-wULOB3JK.js → edge/block-wrapper-x7ERONr-.js} +5 -5
- package/lib/{node/component-ref-Tn-Aa9EG.js → edge/component-ref-JRfa9Vwo.js} +2 -2
- package/lib/{node/component-ref-cw1D-ZyS.cjs → edge/component-ref-eV0RBAzs.cjs} +1 -1
- package/lib/edge/get-block-properties-Dy3XF05J.cjs +1 -0
- package/lib/{browser/get-block-properties-ROTqTJZ3.js → edge/get-block-properties-PLBPSz3W.js} +13 -13
- package/lib/edge/{index-u68L80fc.cjs → index-5-C3UhJz.cjs} +31 -31
- package/lib/edge/{index-C-mI6Ai4.js → index-TGe9_80q.js} +837 -843
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/init.cjs +8 -0
- package/lib/edge/init.mjs +64 -0
- package/lib/edge/logger-I8FmJD_1.js +11 -0
- package/lib/edge/logger-U9-0vDJK.cjs +1 -0
- package/lib/edge/{repeated-block-cXD1rb5T.cjs → repeated-block-FB2jF4o_.cjs} +1 -1
- package/lib/edge/{repeated-block-P7xKkVOb.js → repeated-block-_9Gs2AOY.js} +2 -2
- package/lib/node/{block-styles-TC7FEjXP.js → block-styles-gLB-jSXN.js} +13 -12
- package/lib/node/block-styles-u7KGnyuc.cjs +1 -0
- package/lib/{edge/block-wrapper-BxeE3u_2.cjs → node/block-wrapper-cCYzfiv5.cjs} +1 -1
- package/lib/{edge/block-wrapper-EnFwFXwA.js → node/block-wrapper-frfIIST_.js} +3 -3
- package/lib/{edge/component-ref-t51XeINm.js → node/component-ref-IbarjSnq.js} +2 -2
- package/lib/{edge/component-ref-XzuZ1Hfj.cjs → node/component-ref-ZlBAzimq.cjs} +1 -1
- package/lib/node/get-block-properties-2Q2lr9bu.cjs +1 -0
- package/lib/node/{get-block-properties-lLVZb91I.js → get-block-properties-QIsIgfnu.js} +17 -16
- package/lib/node/{index-eZTeDA6U.js → index-BugETl2c.js} +907 -1123
- package/lib/node/index-s5vEnK-M.cjs +166 -0
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +17 -16
- package/lib/node/init.cjs +1 -0
- package/lib/node/init.mjs +11 -0
- package/lib/node/node-runtime-0rF8vJwU.js +233 -0
- package/lib/node/node-runtime-Bqb5TnyM.cjs +48 -0
- package/lib/node/{repeated-block-_TZDsWlq.js → repeated-block-Z-_chLeZ.js} +2 -2
- package/lib/node/{repeated-block-49B-IJEV.cjs → repeated-block-ZpVu-xdw.cjs} +1 -1
- package/package.json +5 -1
- package/lib/browser/block-styles-NluRxFx2.cjs +0 -1
- package/lib/browser/get-block-properties-Cj0ih41l.cjs +0 -1
- package/lib/browser/index-sPD8fzSJ.cjs +0 -166
- package/lib/edge/block-styles-TkeDyfA0.cjs +0 -1
- package/lib/edge/get-block-properties-MnsKwX8B.cjs +0 -1
- package/lib/node/block-styles-aVTlrIHc.cjs +0 -1
- package/lib/node/get-block-properties-coIi16X2.cjs +0 -1
- package/lib/node/index-ZUbIvJ0s.cjs +0 -213
|
@@ -1,11 +1,13 @@
|
|
|
1
|
+
import "./style.css";
|
|
1
2
|
import { defineComponent as C, resolveComponent as g, openBlock as $, createBlock as v, createCommentVNode as B } from "vue";
|
|
2
|
-
import { _,
|
|
3
|
+
import { _, c as h, g as T, a as l, b as k, d as w, e as I } from "./index-ZL8QUFiN.js";
|
|
4
|
+
import { T as N } from "./logger-Hm2e1Xk_.js";
|
|
3
5
|
const z = C({
|
|
4
6
|
name: "block-styles",
|
|
5
7
|
components: { InlinedStyles: _ },
|
|
6
8
|
props: ["block", "context"],
|
|
7
9
|
data() {
|
|
8
|
-
return { TARGET:
|
|
10
|
+
return { TARGET: N };
|
|
9
11
|
},
|
|
10
12
|
computed: {
|
|
11
13
|
canShowBlock() {
|
|
@@ -14,27 +16,27 @@ const z = C({
|
|
|
14
16
|
},
|
|
15
17
|
css() {
|
|
16
18
|
var p, u, y;
|
|
17
|
-
const e = this.block, s = e.responsiveStyles, n = this.context.content,
|
|
19
|
+
const e = this.block, s = e.responsiveStyles, n = this.context.content, r = T(
|
|
18
20
|
((p = n == null ? void 0 : n.meta) == null ? void 0 : p.breakpoints) || {}
|
|
19
|
-
),
|
|
21
|
+
), c = s == null ? void 0 : s.large, i = s == null ? void 0 : s.medium, a = s == null ? void 0 : s.small, o = e.id;
|
|
20
22
|
if (!o)
|
|
21
23
|
return "";
|
|
22
|
-
const S =
|
|
24
|
+
const S = c ? l({
|
|
23
25
|
className: o,
|
|
24
|
-
styles:
|
|
26
|
+
styles: c
|
|
25
27
|
}) : "", f = i ? l({
|
|
26
28
|
className: o,
|
|
27
29
|
styles: i,
|
|
28
30
|
mediaQuery: k(
|
|
29
31
|
"medium",
|
|
30
|
-
|
|
32
|
+
r
|
|
31
33
|
)
|
|
32
34
|
}) : "", b = a ? l({
|
|
33
35
|
className: o,
|
|
34
36
|
styles: a,
|
|
35
37
|
mediaQuery: k(
|
|
36
38
|
"small",
|
|
37
|
-
|
|
39
|
+
r
|
|
38
40
|
)
|
|
39
41
|
}) : "", t = e.animations && e.animations.find((m) => m.trigger === "hover");
|
|
40
42
|
let d = "";
|
|
@@ -44,7 +46,7 @@ const z = C({
|
|
|
44
46
|
className: `${o}:hover`,
|
|
45
47
|
styles: {
|
|
46
48
|
...m,
|
|
47
|
-
transition: `all ${t.duration}s ${
|
|
49
|
+
transition: `all ${t.duration}s ${w(
|
|
48
50
|
t.easing
|
|
49
51
|
)}`,
|
|
50
52
|
transitionDelay: t.delay ? `${t.delay}s` : "0s"
|
|
@@ -60,7 +62,7 @@ const z = C({
|
|
|
60
62
|
}
|
|
61
63
|
}
|
|
62
64
|
});
|
|
63
|
-
function A(e, s, n,
|
|
65
|
+
function A(e, s, n, r, c, i) {
|
|
64
66
|
const a = g("InlinedStyles");
|
|
65
67
|
return e.TARGET !== "reactNative" && e.css && e.canShowBlock ? ($(), v(a, {
|
|
66
68
|
key: 0,
|
|
@@ -69,7 +71,7 @@ function A(e, s, n, c, r, i) {
|
|
|
69
71
|
nonce: e.context.nonce
|
|
70
72
|
}, null, 8, ["styles", "nonce"])) : B("", !0);
|
|
71
73
|
}
|
|
72
|
-
const
|
|
74
|
+
const F = /* @__PURE__ */ I(z, [["render", A]]);
|
|
73
75
|
export {
|
|
74
|
-
|
|
76
|
+
F as default
|
|
75
77
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var B=require("./style.css");Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("vue"),s=require("./index-MDNnQzZB.cjs"),f=require("./logger-0-1mARBa.cjs"),g=r.defineComponent({name:"block-styles",components:{InlinedStyles:s._sfc_main},props:["block","context"],data(){return{TARGET:f.TARGET}},computed:{canShowBlock(){const e=this.block;return s.checkIsDefined(e.hide)?!e.hide:s.checkIsDefined(e.show)?e.show:!0},css(){var y,p,h;const e=this.block,t=e.responsiveStyles,l=this.context.content,a=s.getSizesForBreakpoints(((y=l==null?void 0:l.meta)==null?void 0:y.breakpoints)||{}),i=t==null?void 0:t.large,d=t==null?void 0:t.medium,c=t==null?void 0:t.small,n=e.id;if(!n)return"";const S=i?s.createCssClass({className:n,styles:i}):"",k=d?s.createCssClass({className:n,styles:d,mediaQuery:s.getMaxWidthQueryForSize("medium",a)}):"",C=c?s.createCssClass({className:n,styles:c,mediaQuery:s.getMaxWidthQueryForSize("small",a)}):"",o=e.animations&&e.animations.find(m=>m.trigger==="hover");let u="";if(o){const m=((h=(p=o.steps)==null?void 0:p[1])==null?void 0:h.styles)||{};u=s.createCssClass({className:`${n}:hover`,styles:{...m,transition:`all ${o.duration}s ${s.camelToKebabCase(o.easing)}`,transitionDelay:o.delay?`${o.delay}s`:"0s"}})||""}return[S,k,C,u].join(" ")}}});function b(e,t,l,a,i,d){const c=r.resolveComponent("InlinedStyles");return e.TARGET!=="reactNative"&&e.css&&e.canShowBlock?(r.openBlock(),r.createBlock(c,{key:0,id:"builderio-block",styles:e.css,nonce:e.context.nonce},null,8,["styles","nonce"])):r.createCommentVNode("",!0)}const v=s._export_sfc(g,[["render",b]]);exports.default=v;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import "./style.css";
|
|
2
2
|
import { defineComponent as o, defineAsyncComponent as r, resolveComponent as n, openBlock as a, createBlock as c, withCtx as i, renderSlot as p } from "vue";
|
|
3
|
-
import { g as s, a as l } from "./get-block-properties-
|
|
4
|
-
import { e as m } from "./index-
|
|
5
|
-
const d = () => import("./index-
|
|
3
|
+
import { g as s, a as l } from "./get-block-properties-HzVZCpxa.js";
|
|
4
|
+
import { e as m } from "./index-ZL8QUFiN.js";
|
|
5
|
+
const d = () => import("./index-ZL8QUFiN.js").then((e) => e.D).then((e) => e.default).catch((e) => {
|
|
6
6
|
throw console.error(
|
|
7
7
|
"Error while attempting to dynamically import component DynamicRenderer at ../../dynamic-renderer/dynamic-renderer.vue",
|
|
8
8
|
e
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var k=require("./style.css");Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),o=require("./get-block-properties-
|
|
1
|
+
var k=require("./style.css");Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),o=require("./get-block-properties-sInACBRh.cjs"),n=require("./index-MDNnQzZB.cjs"),c=()=>Promise.resolve().then(()=>require("./index-MDNnQzZB.cjs")).then(e=>e.dynamicRenderer).then(e=>e.default).catch(e=>{throw console.error("Error while attempting to dynamically import component DynamicRenderer at ../../dynamic-renderer/dynamic-renderer.vue",e),e}),a=t.defineComponent({name:"block-wrapper",components:{DynamicRenderer:t.defineAsyncComponent(c)},props:["Wrapper","block","context"],data(){return{getBlockActions:o.getBlockActions,getBlockProperties:o.getBlockProperties}}});function i(e,l,p,d,m,u){const r=t.resolveComponent("DynamicRenderer");return t.openBlock(),t.createBlock(r,{TagName:e.Wrapper,attributes:e.getBlockProperties({block:e.block,context:e.context}),actionAttributes:e.getBlockActions({block:e.block,rootState:e.context.rootState,rootSetState:e.context.rootSetState,localState:e.context.localState,context:e.context.context,stripPrefix:!0})},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default")]),_:3},8,["TagName","attributes","actionAttributes"])}const s=n._export_sfc(a,[["render",i]]);exports.default=s;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./style.css";
|
|
2
2
|
import { defineComponent as m, openBlock as r, createBlock as a, resolveDynamicComponent as k, mergeProps as u, withCtx as d, renderSlot as h, resolveComponent as B, normalizeProps as P, createElementBlock as g, Fragment as $, renderList as v, createCommentVNode as S } from "vue";
|
|
3
|
-
import { e as f, B as W, w } from "./index-
|
|
4
|
-
import { a as b, g as R } from "./get-block-properties-
|
|
3
|
+
import { e as f, B as W, w } from "./index-ZL8QUFiN.js";
|
|
4
|
+
import { a as b, g as R } from "./get-block-properties-HzVZCpxa.js";
|
|
5
5
|
const x = m({
|
|
6
6
|
name: "interactive-element",
|
|
7
7
|
props: ["includeBlockProps", "block", "context", "wrapperProps", "Wrapper"],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var P=require("./style.css");Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),c=require("./index-
|
|
1
|
+
var P=require("./style.css");Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),c=require("./index-MDNnQzZB.cjs"),a=require("./get-block-properties-sInACBRh.cjs"),u=t.defineComponent({name:"interactive-element",props:["includeBlockProps","block","context","wrapperProps","Wrapper"],computed:{attributes(){return this.includeBlockProps?{...a.getBlockProperties({block:this.block,context:this.context}),...a.getBlockActions({block:this.block,rootState:this.context.rootState,rootSetState:this.context.rootSetState,localState:this.context.localState,context:this.context.context})}:{}}}});function d(e,o,p,s,n,i){return t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.Wrapper),t.mergeProps({attributes:e.attributes},e.wrapperProps),{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default")]),_:3},16,["attributes"])}const m=c._export_sfc(u,[["render",d]]),f=({componentOptions:e,builderBlock:o,context:p,componentRef:s,includeBlockProps:n,isInteractive:i,contextValue:l})=>{const r={...e,...n?{attributes:a.getBlockProperties({block:o,context:l})}:{}};return i?{Wrapper:s,block:o,context:p,wrapperProps:e,includeBlockProps:n}:r},B=t.defineComponent({name:"component-ref",components:{Block:c.Block,InteractiveElement:m},props:["isInteractive","componentRef","componentOptions","builderBlock","context","linkComponent","includeBlockProps","blockChildren","registeredComponents"],data(){return{Wrapper:this.isInteractive?c.wrapComponentRef(m):this.componentRef,getWrapperProps:f}}});function b(e,o,p,s,n,i){const l=t.resolveComponent("Block");return e.componentRef?(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.Wrapper),t.normalizeProps(t.mergeProps({key:0},e.getWrapperProps({componentOptions:e.componentOptions,builderBlock:e.builderBlock,context:e.context,componentRef:e.componentRef,linkComponent:e.linkComponent,includeBlockProps:e.includeBlockProps,isInteractive:e.isInteractive,contextValue:e.context}))),{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.blockChildren,(r,k)=>(t.openBlock(),t.createBlock(l,{key:r.id,block:r,context:e.context,registeredComponents:e.registeredComponents,linkComponent:e.linkComponent},null,8,["block","context","registeredComponents","linkComponent"]))),128))]),_:1},16)):t.createCommentVNode("",!0)}const C=c._export_sfc(B,[["render",b]]);exports.default=C;
|
package/lib/{edge/get-block-properties-Hs6W4UwL.js → browser/get-block-properties-HzVZCpxa.js}
RENAMED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
1
|
+
import "./style.css";
|
|
2
|
+
import { T as s } from "./logger-Hm2e1Xk_.js";
|
|
3
|
+
import { f as c, h as i, i as l } from "./index-ZL8QUFiN.js";
|
|
4
|
+
const f = (e) => `v-on:${e.toLowerCase()}`, p = (e, t) => (r) => c({
|
|
3
5
|
code: e,
|
|
4
6
|
context: t.context,
|
|
5
7
|
localState: t.localState,
|
|
@@ -9,27 +11,27 @@ const f = (e) => `v-on:${e.toLowerCase()}`, u = (e, t) => (r) => s({
|
|
|
9
11
|
isExpression: !1,
|
|
10
12
|
enableCache: !0
|
|
11
13
|
});
|
|
12
|
-
function
|
|
14
|
+
function g(e) {
|
|
13
15
|
const t = {}, r = e.block.actions ?? {};
|
|
14
|
-
for (const
|
|
15
|
-
if (!r.hasOwnProperty(
|
|
16
|
+
for (const o in r) {
|
|
17
|
+
if (!r.hasOwnProperty(o))
|
|
16
18
|
continue;
|
|
17
|
-
const n = r[
|
|
18
|
-
let
|
|
19
|
+
const n = r[o];
|
|
20
|
+
let a = f(o);
|
|
19
21
|
if (e.stripPrefix)
|
|
20
|
-
switch (
|
|
22
|
+
switch (s) {
|
|
21
23
|
case "vue":
|
|
22
|
-
|
|
24
|
+
a = a.replace("v-on:", "");
|
|
23
25
|
break;
|
|
24
26
|
case "svelte":
|
|
25
|
-
|
|
27
|
+
a = a.replace("on:", "");
|
|
26
28
|
break;
|
|
27
29
|
}
|
|
28
|
-
t[
|
|
30
|
+
t[a] = p(n, e);
|
|
29
31
|
}
|
|
30
32
|
return t;
|
|
31
33
|
}
|
|
32
|
-
function
|
|
34
|
+
function u({
|
|
33
35
|
properties: e
|
|
34
36
|
}) {
|
|
35
37
|
return e;
|
|
@@ -37,11 +39,11 @@ function p({
|
|
|
37
39
|
const v = (e) => ({
|
|
38
40
|
href: e.href
|
|
39
41
|
});
|
|
40
|
-
function
|
|
42
|
+
function h({
|
|
41
43
|
block: e,
|
|
42
44
|
context: t
|
|
43
45
|
}) {
|
|
44
|
-
var
|
|
46
|
+
var o;
|
|
45
47
|
const r = {
|
|
46
48
|
...v(e),
|
|
47
49
|
...e.properties,
|
|
@@ -50,15 +52,15 @@ function g({
|
|
|
50
52
|
block: e,
|
|
51
53
|
context: t
|
|
52
54
|
}),
|
|
53
|
-
[l()]: [e.id, "builder-block", e.class, (
|
|
55
|
+
[l()]: [e.id, "builder-block", e.class, (o = e.properties) == null ? void 0 : o.class].filter(Boolean).join(" ")
|
|
54
56
|
};
|
|
55
|
-
return
|
|
57
|
+
return u({
|
|
56
58
|
properties: r,
|
|
57
59
|
context: t,
|
|
58
60
|
block: e
|
|
59
61
|
});
|
|
60
62
|
}
|
|
61
63
|
export {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
+
h as a,
|
|
65
|
+
g
|
|
64
66
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var v=require("./style.css");const c=require("./logger-0-1mARBa.cjs"),a=require("./index-MDNnQzZB.cjs"),i=e=>`v-on:${e.toLowerCase()}`,l=(e,t)=>r=>a.evaluate({code:e,context:t.context,localState:t.localState,rootState:t.rootState,rootSetState:t.rootSetState,event:r,isExpression:!1,enableCache:!0});function u(e){const t={},r=e.block.actions??{};for(const o in r){if(!r.hasOwnProperty(o))continue;const s=r[o];let n=i(o);if(e.stripPrefix)switch(c.TARGET){case"vue":n=n.replace("v-on:","");break;case"svelte":n=n.replace("on:","");break}t[n]=l(s,e)}return t}function p({properties:e}){return e}const f=e=>({href:e.href});function d({block:e,context:t}){var o;const r={...f(e),...e.properties,"builder-id":e.id,style:a.getStyle({block:e,context:t}),[a.getClassPropName()]:[e.id,"builder-block",e.class,(o=e.properties)==null?void 0:o.class].filter(Boolean).join(" ")};return p({properties:r,context:t,block:e})}exports.getBlockActions=u;exports.getBlockProperties=d;
|