@grapesjs/studio-sdk-plugins 1.0.23 → 1.0.24

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.
@@ -103,16 +103,12 @@ const y = "animation", v = "animation-group", E = "animation:update", k = "anima
103
103
  category: { id: "animations", label: "Animations" },
104
104
  select: !0
105
105
  }, w = (t) => (t == null ? void 0 : t.type) === y, x = (t) => (t == null ? void 0 : t.type) === v, N = (t) => w(t) || x(t), _ = {
106
- // @ts-expect-error available from the next release
107
106
  isVisible: ({ component: t }) => N(t)
108
107
  }, S = {
109
- // @ts-expect-error available from the next release
110
108
  isVisible: ({ component: t }) => w(t)
111
109
  }, K = {
112
- // @ts-expect-error available from the next release
113
110
  isVisible: ({ component: t }) => x(t)
114
111
  }, D = {
115
- // @ts-expect-error available from the next release
116
112
  isVisible: ({ component: t, sector: n }) => {
117
113
  var e;
118
114
  return w(t) && x(t == null ? void 0 : t.parent()) ? !1 : N(t) && ((e = n.getProperty(d.onScroll)) == null ? void 0 : e.getValue()) === "true";
@@ -1,9 +1,9 @@
1
- "use strict";function F(e,a,n){let t,o,c,p,m;const r=a;function u(){const l=Date.now()-p;l<r&&l>=0?t=setTimeout(u,r-l):(t=null,m=e.apply(c,o),c=o=null)}const s=function(){return c=this,o=arguments,p=Date.now(),t||(t=setTimeout(u,r)),m};return s.clear=function(){t&&(clearTimeout(t),t=null)},s.flush=function(){t&&(m=e.apply(c,o),c=o=null,clearTimeout(t),t=null)},s}const z="app.grapesjs.com",R="app-stage.grapesjs.com",U=[z,R,"localhost","127.0.0.1",".local-credentialless.webcontainer.io",".local.webcontainer.io","-sandpack.codesandbox.io"],q="license:check:start",G="license:check:end",V=()=>typeof window<"u",X=({isDev:e,isStage:a})=>`${e?"":`https://${a?R:z}`}/api`,Y=()=>{const e=V()&&window.location.hostname;return!!e&&(U.includes(e)||U.some(a=>e.endsWith(a)))};async function B({path:e,baseApiUrl:a,method:n="GET",headers:t={},params:o,body:c}){const m=`${a||X({isDev:!1,isStage:!1})}${e}`,r={method:n,headers:{"Content-Type":"application/json",...t}};c&&(r.body=JSON.stringify(c));const u=o?new URLSearchParams(o).toString():"",s=u?`?${u}`:"",l=await fetch(`${m}${s}`,r);if(!l.ok)throw new Error(`HTTP error! status: ${l.status}`);return l.json()}var b=(e=>(e.free="free",e.startup="startup",e.business="business",e.enterprise="enterprise",e))(b||{});const W={[b.free]:0,[b.startup]:10,[b.business]:20,[b.enterprise]:30};function Z(e){const a=e;return a.init=n=>t=>e(t,n),a}const J=e=>Z(e);async function Q({editor:e,plan:a,pluginName:n,licenseKey:t,cleanup:o}){let c="",p=!1;const m=Y(),r=s=>{console.warn("Cleanup plugin:",n,"Reason:",s),o()},u=(s={})=>{var C;const{error:l,sdkLicense:D}=s,v=(C=s.plan)==null?void 0:C.category;if(!(D||s.license)||l)r(l||"Invalid license");else if(v){const E=W[a],S=W[v];E>S&&r({pluginRequiredPlan:a,licensePlan:v})}};e.on(q,s=>{c=s==null?void 0:s.baseApiUrl,p=!0}),e.on(G,s=>{u(s)}),setTimeout(async()=>{if(!p){if(m)return;if(t){const s=await ee({licenseKey:t,pluginName:n,baseApiUrl:c});s&&u(s)}else r("The `licenseKey` option not provided")}},2e3)}async function ee(e){const{licenseKey:a,pluginName:n,baseApiUrl:t}=e;try{return(await B({baseApiUrl:t,path:`/sdk/${a||"na"}`,method:"POST",params:{d:window.location.hostname,pn:n}})).result||{}}catch(o){return console.error("Error during SDK license check:",o),!1}}const k="canvasFullSize",te=b.startup,ne=function(e,a={}){const{Canvas:n,Commands:t,Devices:o}=e,c={deviceMaxWidth:1200,deviceMinHeigth:500,canvasOffsetY:30,canvasOffsetX:50,canvasTransition:.3,frameBorderRadius:5,frameTransition:.3,...a},{canvasOffsetY:p,canvasOffsetX:m,canvasTransition:r,deviceMaxWidth:u,deviceMinHeigth:s,frameBorderRadius:l,frameTransition:D}=c,v=`${s}px`,$=n.events,C="core:preview",E=`${t.events.stopCommand}${C}`,S=n.getConfig(),A=`${k}:disable`,_=o.getAll().map(i=>({...i.attributes}));S.scrollableCanvas=!0,o.getAll().map(i=>{!i.get("width")&&i.set("width",`${u}px`),!i.get("height")&&i.set("height","auto"),!i.get("minHeight")&&i.set("minHeight",v)});const L=i=>{const w="data-gs-plg-full-size",d=document.querySelector(`style[${w}]`);if(i&&d)return d.remove();const f=d||document.createElement("style"),h=n.getZoomMultiplier();f.setAttribute(w,"true"),f.innerHTML=`
2
- .gjs-frame-wrapper { transition: width ${D}s !important; }
3
- .gjs-frame-wrapper__bottom { height: ${p*h}px }
4
- .gjs-frame { border-radius: ${l}px }
5
- `,!d&&document.body.appendChild(f)};e.on($.frameLoadHead,i=>{if(!S.scrollableCanvas)return;const{window:w}=i,d=w.document,f=d.head,h="data-gs-plg-wrapper-style",y=f.querySelector(`style[${h}]`)||d.createElement("style");y.setAttribute(h,"true"),y.innerHTML=`
6
- [data-gjs-type="wrapper"] { min-height: ${v}; }
7
- [data-gjs-type="mjml"] { min-height: ${v} !important; }
8
- [data-gjs-type="mj-body"] { min-height: ${v} !important; }
9
- `,!f.contains(y)&&f.appendChild(y)}),e.onReady(()=>{const i=n.getSpotsEl(),w=n.getElement(),d=n.getFramesEl(),f=r*1e3,h=w.style;h.overflowX="hidden",d.style.transition=`transform ${r}s`;const y={x:m,y:p};L();const H=()=>i.style.display="none",K=()=>i.style.display="",T=F(()=>{n.fitViewport({zoom:g=>g>100?100:g,ignoreHeight:!0,gap:y}),L(),setTimeout(()=>{var P,x;const{em:g}=e;g.destroyed||((x=(P=e.getSelected())==null?void 0:P.getEl())==null||x.scrollIntoView({block:"nearest"}),e.refresh({tools:!0}),K(),t.isActive(C)?g.stopDefault():g.runDefault())},f)},100),j=new ResizeObserver(()=>{H(),T()});j.observe(w.parentElement);const I=()=>{H(),T()},M=(g={})=>{g.options&&g.options.from!=="fitViewport"&&n.fitViewport({zoom:n.getZoom(),ignoreHeight:!0,gap:y})},N=()=>{h.overflowX="hidden",h.overflowY="auto"},O=()=>{j.disconnect(),T.clear()};e.on(o.events.select,I),e.on($.zoom,M),e.on(E,N),e.on(e.events.destroy,O),T(),t.add(A,()=>{o.devices.reset(_),S.scrollableCanvas=!1,n.getModel().updateDevice(),n.setZoom(100),n.setCoords(0,0),h.overflowY="hidden",L(!0),e.off(o.events.select,I),e.off($.zoom,M),e.off(E,N),O(),t.run("studio:canvasReload")})}),Q({editor:e,licenseKey:c.licenseKey,plan:te,pluginName:k,cleanup:()=>{e.runCommand(A)}})},se=J(ne);module.exports=se;
1
+ "use strict";function B(e,a,s){let n,i,c,r,m;const l=a;function u(){const p=Date.now()-r;p<l&&p>=0?n=setTimeout(u,l-p):(n=null,m=e.apply(c,i),c=i=null)}const o=function(){return c=this,i=arguments,r=Date.now(),n||(n=setTimeout(u,l)),m};return o.clear=function(){n&&(clearTimeout(n),n=null)},o.flush=function(){n&&(m=e.apply(c,i),c=i=null,clearTimeout(n),n=null)},o}const O="app.grapesjs.com",R="app-stage.grapesjs.com",U=[O,R,"localhost","127.0.0.1",".local-credentialless.webcontainer.io",".local.webcontainer.io","-sandpack.codesandbox.io"],G="license:check:start",X="license:check:end",Y=()=>typeof window<"u",Z=({isDev:e,isStage:a})=>`${e?"":`https://${a?R:O}`}/api`,J=()=>{const e=Y()&&window.location.hostname;return!!e&&(U.includes(e)||U.some(a=>e.endsWith(a)))};async function Q({path:e,baseApiUrl:a,method:s="GET",headers:n={},params:i,body:c}){const m=`${a||Z({isDev:!1,isStage:!1})}${e}`,l={method:s,headers:{"Content-Type":"application/json",...n}};c&&(l.body=JSON.stringify(c));const u=i?new URLSearchParams(i).toString():"",o=u?`?${u}`:"",p=await fetch(`${m}${o}`,l);if(!p.ok)throw new Error(`HTTP error! status: ${p.status}`);return p.json()}var g=(e=>(e.free="free",e.startup="startup",e.business="business",e.enterprise="enterprise",e))(g||{});const W={[g.free]:0,[g.startup]:10,[g.business]:20,[g.enterprise]:30};function ee(e){const a=e;return a.init=s=>n=>e(n,s),a}const te=e=>ee(e);async function ne({editor:e,plan:a,pluginName:s,licenseKey:n,cleanup:i}){let c="",r=!1;const m=J(),l=o=>{console.warn("Cleanup plugin:",s,"Reason:",o),i()},u=(o={})=>{var y;const{error:p,sdkLicense:D}=o,v=(y=o.plan)==null?void 0:y.category;if(!(D||o.license)||p)l(p||"Invalid license");else if(v){const S=W[a],L=W[v];S>L&&l({pluginRequiredPlan:a,licensePlan:v})}};e.on(G,o=>{c=o==null?void 0:o.baseApiUrl,r=!0}),e.on(X,o=>{u(o)}),setTimeout(async()=>{if(!r){if(m)return;if(n){const o=await se({licenseKey:n,pluginName:s,baseApiUrl:c});o&&u(o)}else l("The `licenseKey` option not provided")}},2e3)}async function se(e){const{licenseKey:a,pluginName:s,baseApiUrl:n}=e;try{return(await Q({baseApiUrl:n,path:`/sdk/${a||"na"}`,method:"POST",params:{d:window.location.hostname,pn:s}})).result||{}}catch(i){return console.error("Error during SDK license check:",i),!1}}const k="canvasFullSize",oe=g.startup,ie=(e,a)=>{var c;const{rule:s,ruleView:n}=a,{style:i}=s.attributes;if(i&&i[e]){const r=i[e],m=(c=r==null?void 0:r.endsWith)==null?void 0:c.call(r,"vh"),l=n.frameView.model;if(m&&l.hasAutoHeight()){const u=parseFloat(r),o=s.toCSS({style:{...i,[e]:`${window.outerHeight*(u/100)}px`}});a.css=o}}},ae=e=>{["height","min-height","max-height"].forEach(a=>ie(a,e))},ce=function(e,a={}){const{Canvas:s,Commands:n,Devices:i,Css:c}=e,r={deviceMaxWidth:1200,deviceMinHeigth:500,canvasOffsetY:30,canvasOffsetX:50,canvasTransition:.3,frameBorderRadius:5,frameTransition:.3,...a},{canvasOffsetY:m,canvasOffsetX:l,canvasTransition:u,deviceMaxWidth:o,deviceMinHeigth:p,frameBorderRadius:D,frameTransition:v}=r,w=`${p}px`,y=s.events,S="core:preview",L=`${n.events.stopCommand}${S}`,A=s.getConfig(),M=`${k}:disable`,_=i.getAll().map(t=>({...t.attributes})),z=u*1e3,N={x:l,y:m};let b={},H,C;A.scrollableCanvas=!0,i.getAll().map(t=>{!t.get("width")&&t.set("width",`${o}px`),!t.get("height")&&t.set("height","auto"),!t.get("minHeight")&&t.set("minHeight",w)});const x=t=>{const d="data-gs-plg-full-size",f=document.querySelector(`style[${d}]`);if(t&&f)return f.remove();const h=f||document.createElement("style"),$=s.getZoomMultiplier();h.setAttribute(d,"true"),h.innerHTML=`
2
+ .gjs-frame-wrapper { transition: width ${v}s !important; }
3
+ .gjs-frame-wrapper__bottom { height: ${m*$}px }
4
+ .gjs-frame { border-radius: ${D}px }
5
+ `,!f&&document.body.appendChild(h)};e.on(y.frameLoadHead,t=>{if(!A.scrollableCanvas)return;const{window:d}=t,f=d.document,h=f.head,$="data-gs-plg-wrapper-style",T=h.querySelector(`style[${$}]`)||f.createElement("style");T.setAttribute($,"true"),T.innerHTML=`
6
+ [data-gjs-type="wrapper"] { min-height: ${w}; }
7
+ [data-gjs-type="mjml"] { min-height: ${w} !important; }
8
+ [data-gjs-type="mj-body"] { min-height: ${w} !important; }
9
+ `,!h.contains(T)&&h.appendChild(T)});const j=()=>H.style.display="none",F=()=>H.style.display="",E=B(()=>{s.fitViewport({zoom:t=>t>100?100:t,ignoreHeight:!0,gap:N}),x(),setTimeout(()=>{var d,f;const{em:t}=e;t.destroyed||((f=(d=e.getSelected())==null?void 0:d.getEl())==null||f.scrollIntoView({block:"nearest"}),e.refresh({tools:!0}),F(),n.isActive(S)?t.stopDefault():t.runDefault())},z)},100),K=(t={})=>{t.options&&t.options.from!=="fitViewport"&&s.fitViewport({zoom:s.getZoom(),ignoreHeight:!0,gap:N})},V=()=>{j(),E()},q=()=>{b.overflowX="hidden",b.overflowY="auto"},I=()=>{C==null||C.disconnect(),E.clear()},P=[[i.events.select,V],[y.zoom,K],[L,q],[e.events.destroy,I],[c.events.mountBefore,ae]];n.add(M,()=>{i.devices.reset(_),A.scrollableCanvas=!1,s.getModel().updateDevice(),s.setZoom(100),s.setCoords(0,0),b.overflowY="hidden",x(!0),P.forEach(([t,d])=>e.off(t,d)),I(),n.run("studio:canvasReload")}),P.forEach(([t,d])=>e.on(t,d)),e.onReady(()=>{const t=s.getElement(),d=s.getFramesEl();H=s.getSpotsEl(),b=t.style,b.overflowX="hidden",d.style.transition=`transform ${u}s`,x(),C=new ResizeObserver(()=>{j(),E()}),C.observe(t.parentElement),E()}),ne({editor:e,licenseKey:r.licenseKey,plan:oe,pluginName:k,cleanup:()=>{e.runCommand(M)}})},re=te(ce);module.exports=re;
@@ -1,21 +1,21 @@
1
- function F(e, a, n) {
2
- let t, o, c, p, m;
3
- const r = a;
1
+ function B(e, a, s) {
2
+ let n, i, c, r, m;
3
+ const l = a;
4
4
  function u() {
5
- const l = Date.now() - p;
6
- l < r && l >= 0 ? t = setTimeout(u, r - l) : (t = null, m = e.apply(c, o), c = o = null);
5
+ const p = Date.now() - r;
6
+ p < l && p >= 0 ? n = setTimeout(u, l - p) : (n = null, m = e.apply(c, i), c = i = null);
7
7
  }
8
- const s = function() {
9
- return c = this, o = arguments, p = Date.now(), t || (t = setTimeout(u, r)), m;
8
+ const o = function() {
9
+ return c = this, i = arguments, r = Date.now(), n || (n = setTimeout(u, l)), m;
10
10
  };
11
- return s.clear = function() {
12
- t && (clearTimeout(t), t = null);
13
- }, s.flush = function() {
14
- t && (m = e.apply(c, o), c = o = null, clearTimeout(t), t = null);
15
- }, s;
11
+ return o.clear = function() {
12
+ n && (clearTimeout(n), n = null);
13
+ }, o.flush = function() {
14
+ n && (m = e.apply(c, i), c = i = null, clearTimeout(n), n = null);
15
+ }, o;
16
16
  }
17
- const z = "app.grapesjs.com", R = "app-stage.grapesjs.com", U = [
18
- z,
17
+ const O = "app.grapesjs.com", R = "app-stage.grapesjs.com", U = [
18
+ O,
19
19
  R,
20
20
  "localhost",
21
21
  "127.0.0.1",
@@ -25,96 +25,113 @@ const z = "app.grapesjs.com", R = "app-stage.grapesjs.com", U = [
25
25
  // For stackblitz.com demos
26
26
  "-sandpack.codesandbox.io"
27
27
  // For Sandpack demos
28
- ], q = "license:check:start", G = "license:check:end", V = () => typeof window < "u", X = ({ isDev: e, isStage: a }) => `${e ? "" : `https://${a ? R : z}`}/api`, Y = () => {
29
- const e = V() && window.location.hostname;
28
+ ], G = "license:check:start", X = "license:check:end", Y = () => typeof window < "u", Z = ({ isDev: e, isStage: a }) => `${e ? "" : `https://${a ? R : O}`}/api`, J = () => {
29
+ const e = Y() && window.location.hostname;
30
30
  return !!e && (U.includes(e) || U.some((a) => e.endsWith(a)));
31
31
  };
32
- async function B({
32
+ async function Q({
33
33
  path: e,
34
34
  baseApiUrl: a,
35
- method: n = "GET",
36
- headers: t = {},
37
- params: o,
35
+ method: s = "GET",
36
+ headers: n = {},
37
+ params: i,
38
38
  body: c
39
39
  }) {
40
- const m = `${a || X({ isDev: !1, isStage: !1 })}${e}`, r = {
41
- method: n,
40
+ const m = `${a || Z({ isDev: !1, isStage: !1 })}${e}`, l = {
41
+ method: s,
42
42
  headers: {
43
43
  "Content-Type": "application/json",
44
- ...t
44
+ ...n
45
45
  }
46
46
  };
47
- c && (r.body = JSON.stringify(c));
48
- const u = o ? new URLSearchParams(o).toString() : "", s = u ? `?${u}` : "", l = await fetch(`${m}${s}`, r);
49
- if (!l.ok)
50
- throw new Error(`HTTP error! status: ${l.status}`);
51
- return l.json();
47
+ c && (l.body = JSON.stringify(c));
48
+ const u = i ? new URLSearchParams(i).toString() : "", o = u ? `?${u}` : "", p = await fetch(`${m}${o}`, l);
49
+ if (!p.ok)
50
+ throw new Error(`HTTP error! status: ${p.status}`);
51
+ return p.json();
52
52
  }
53
- var b = /* @__PURE__ */ ((e) => (e.free = "free", e.startup = "startup", e.business = "business", e.enterprise = "enterprise", e))(b || {});
53
+ var g = /* @__PURE__ */ ((e) => (e.free = "free", e.startup = "startup", e.business = "business", e.enterprise = "enterprise", e))(g || {});
54
54
  const W = {
55
- [b.free]: 0,
56
- [b.startup]: 10,
57
- [b.business]: 20,
58
- [b.enterprise]: 30
55
+ [g.free]: 0,
56
+ [g.startup]: 10,
57
+ [g.business]: 20,
58
+ [g.enterprise]: 30
59
59
  };
60
- function Z(e) {
60
+ function ee(e) {
61
61
  const a = e;
62
- return a.init = (n) => (t) => e(t, n), a;
62
+ return a.init = (s) => (n) => e(n, s), a;
63
63
  }
64
- const J = (e) => /* @__PURE__ */ Z(e);
65
- async function Q({
64
+ const te = (e) => /* @__PURE__ */ ee(e);
65
+ async function ne({
66
66
  editor: e,
67
67
  plan: a,
68
- pluginName: n,
69
- licenseKey: t,
70
- cleanup: o
68
+ pluginName: s,
69
+ licenseKey: n,
70
+ cleanup: i
71
71
  }) {
72
- let c = "", p = !1;
73
- const m = Y(), r = (s) => {
74
- console.warn("Cleanup plugin:", n, "Reason:", s), o();
75
- }, u = (s = {}) => {
76
- var C;
77
- const { error: l, sdkLicense: D } = s, v = (C = s.plan) == null ? void 0 : C.category;
78
- if (!(D || s.license) || l)
79
- r(l || "Invalid license");
72
+ let c = "", r = !1;
73
+ const m = J(), l = (o) => {
74
+ console.warn("Cleanup plugin:", s, "Reason:", o), i();
75
+ }, u = (o = {}) => {
76
+ var y;
77
+ const { error: p, sdkLicense: D } = o, v = (y = o.plan) == null ? void 0 : y.category;
78
+ if (!(D || o.license) || p)
79
+ l(p || "Invalid license");
80
80
  else if (v) {
81
- const E = W[a], S = W[v];
82
- E > S && r({ pluginRequiredPlan: a, licensePlan: v });
81
+ const S = W[a], L = W[v];
82
+ S > L && l({ pluginRequiredPlan: a, licensePlan: v });
83
83
  }
84
84
  };
85
- e.on(q, (s) => {
86
- c = s == null ? void 0 : s.baseApiUrl, p = !0;
87
- }), e.on(G, (s) => {
88
- u(s);
85
+ e.on(G, (o) => {
86
+ c = o == null ? void 0 : o.baseApiUrl, r = !0;
87
+ }), e.on(X, (o) => {
88
+ u(o);
89
89
  }), setTimeout(async () => {
90
- if (!p) {
90
+ if (!r) {
91
91
  if (m) return;
92
- if (t) {
93
- const s = await ee({ licenseKey: t, pluginName: n, baseApiUrl: c });
94
- s && u(s);
92
+ if (n) {
93
+ const o = await se({ licenseKey: n, pluginName: s, baseApiUrl: c });
94
+ o && u(o);
95
95
  } else
96
- r("The `licenseKey` option not provided");
96
+ l("The `licenseKey` option not provided");
97
97
  }
98
98
  }, 2e3);
99
99
  }
100
- async function ee(e) {
101
- const { licenseKey: a, pluginName: n, baseApiUrl: t } = e;
100
+ async function se(e) {
101
+ const { licenseKey: a, pluginName: s, baseApiUrl: n } = e;
102
102
  try {
103
- return (await B({
104
- baseApiUrl: t,
103
+ return (await Q({
104
+ baseApiUrl: n,
105
105
  path: `/sdk/${a || "na"}`,
106
106
  method: "POST",
107
107
  params: {
108
108
  d: window.location.hostname,
109
- pn: n
109
+ pn: s
110
110
  }
111
111
  })).result || {};
112
- } catch (o) {
113
- return console.error("Error during SDK license check:", o), !1;
112
+ } catch (i) {
113
+ return console.error("Error during SDK license check:", i), !1;
114
114
  }
115
115
  }
116
- const k = "canvasFullSize", te = b.startup, ne = function(e, a = {}) {
117
- const { Canvas: n, Commands: t, Devices: o } = e, c = {
116
+ const k = "canvasFullSize", oe = g.startup, ie = (e, a) => {
117
+ var c;
118
+ const { rule: s, ruleView: n } = a, { style: i } = s.attributes;
119
+ if (i && i[e]) {
120
+ const r = i[e], m = (c = r == null ? void 0 : r.endsWith) == null ? void 0 : c.call(r, "vh"), l = n.frameView.model;
121
+ if (m && l.hasAutoHeight()) {
122
+ const u = parseFloat(r), o = s.toCSS({
123
+ style: {
124
+ ...i,
125
+ [e]: `${window.outerHeight * (u / 100)}px`
126
+ }
127
+ });
128
+ a.css = o;
129
+ }
130
+ }
131
+ }, ae = (e) => {
132
+ ["height", "min-height", "max-height"].forEach((a) => ie(a, e));
133
+ }, ce = function(e, a = {}) {
134
+ const { Canvas: s, Commands: n, Devices: i, Css: c } = e, r = {
118
135
  deviceMaxWidth: 1200,
119
136
  deviceMinHeigth: 500,
120
137
  canvasOffsetY: 30,
@@ -124,81 +141,84 @@ const k = "canvasFullSize", te = b.startup, ne = function(e, a = {}) {
124
141
  frameTransition: 0.3,
125
142
  ...a
126
143
  }, {
127
- canvasOffsetY: p,
128
- canvasOffsetX: m,
129
- canvasTransition: r,
130
- deviceMaxWidth: u,
131
- deviceMinHeigth: s,
132
- frameBorderRadius: l,
133
- frameTransition: D
134
- } = c, v = `${s}px`, $ = n.events, C = "core:preview", E = `${t.events.stopCommand}${C}`, S = n.getConfig(), A = `${k}:disable`, _ = o.getAll().map((i) => ({ ...i.attributes }));
135
- S.scrollableCanvas = !0, o.getAll().map((i) => {
136
- !i.get("width") && i.set("width", `${u}px`), !i.get("height") && i.set("height", "auto"), !i.get("minHeight") && i.set("minHeight", v);
144
+ canvasOffsetY: m,
145
+ canvasOffsetX: l,
146
+ canvasTransition: u,
147
+ deviceMaxWidth: o,
148
+ deviceMinHeigth: p,
149
+ frameBorderRadius: D,
150
+ frameTransition: v
151
+ } = r, w = `${p}px`, y = s.events, S = "core:preview", L = `${n.events.stopCommand}${S}`, A = s.getConfig(), M = `${k}:disable`, _ = i.getAll().map((t) => ({ ...t.attributes })), z = u * 1e3, N = { x: l, y: m };
152
+ let b = {}, H, C;
153
+ A.scrollableCanvas = !0, i.getAll().map((t) => {
154
+ !t.get("width") && t.set("width", `${o}px`), !t.get("height") && t.set("height", "auto"), !t.get("minHeight") && t.set("minHeight", w);
137
155
  });
138
- const L = (i) => {
139
- const w = "data-gs-plg-full-size", d = document.querySelector(`style[${w}]`);
140
- if (i && d)
141
- return d.remove();
142
- const f = d || document.createElement("style"), h = n.getZoomMultiplier();
143
- f.setAttribute(w, "true"), f.innerHTML = `
144
- .gjs-frame-wrapper { transition: width ${D}s !important; }
145
- .gjs-frame-wrapper__bottom { height: ${p * h}px }
146
- .gjs-frame { border-radius: ${l}px }
147
- `, !d && document.body.appendChild(f);
156
+ const x = (t) => {
157
+ const d = "data-gs-plg-full-size", f = document.querySelector(`style[${d}]`);
158
+ if (t && f)
159
+ return f.remove();
160
+ const h = f || document.createElement("style"), $ = s.getZoomMultiplier();
161
+ h.setAttribute(d, "true"), h.innerHTML = `
162
+ .gjs-frame-wrapper { transition: width ${v}s !important; }
163
+ .gjs-frame-wrapper__bottom { height: ${m * $}px }
164
+ .gjs-frame { border-radius: ${D}px }
165
+ `, !f && document.body.appendChild(h);
148
166
  };
149
- e.on($.frameLoadHead, (i) => {
150
- if (!S.scrollableCanvas) return;
151
- const { window: w } = i, d = w.document, f = d.head, h = "data-gs-plg-wrapper-style", y = f.querySelector(`style[${h}]`) || d.createElement("style");
152
- y.setAttribute(h, "true"), y.innerHTML = `
153
- [data-gjs-type="wrapper"] { min-height: ${v}; }
154
- [data-gjs-type="mjml"] { min-height: ${v} !important; }
155
- [data-gjs-type="mj-body"] { min-height: ${v} !important; }
156
- `, !f.contains(y) && f.appendChild(y);
157
- }), e.onReady(() => {
158
- const i = n.getSpotsEl(), w = n.getElement(), d = n.getFramesEl(), f = r * 1e3, h = w.style;
159
- h.overflowX = "hidden", d.style.transition = `transform ${r}s`;
160
- const y = { x: m, y: p };
161
- L();
162
- const H = () => i.style.display = "none", K = () => i.style.display = "", T = F(() => {
163
- n.fitViewport({
164
- zoom: (g) => g > 100 ? 100 : g,
165
- ignoreHeight: !0,
166
- gap: y
167
- }), L(), setTimeout(() => {
168
- var P, x;
169
- const { em: g } = e;
170
- g.destroyed || ((x = (P = e.getSelected()) == null ? void 0 : P.getEl()) == null || x.scrollIntoView({ block: "nearest" }), e.refresh({ tools: !0 }), K(), t.isActive(C) ? g.stopDefault() : g.runDefault());
171
- }, f);
172
- }, 100), j = new ResizeObserver(() => {
173
- H(), T();
174
- });
175
- j.observe(w.parentElement);
176
- const I = () => {
177
- H(), T();
178
- }, M = (g = {}) => {
179
- g.options && g.options.from !== "fitViewport" && n.fitViewport({
180
- zoom: n.getZoom(),
181
- ignoreHeight: !0,
182
- gap: y
183
- });
184
- }, N = () => {
185
- h.overflowX = "hidden", h.overflowY = "auto";
186
- }, O = () => {
187
- j.disconnect(), T.clear();
188
- };
189
- e.on(o.events.select, I), e.on($.zoom, M), e.on(E, N), e.on(e.events.destroy, O), T(), t.add(A, () => {
190
- o.devices.reset(_), S.scrollableCanvas = !1, n.getModel().updateDevice(), n.setZoom(100), n.setCoords(0, 0), h.overflowY = "hidden", L(!0), e.off(o.events.select, I), e.off($.zoom, M), e.off(E, N), O(), t.run("studio:canvasReload");
167
+ e.on(y.frameLoadHead, (t) => {
168
+ if (!A.scrollableCanvas) return;
169
+ const { window: d } = t, f = d.document, h = f.head, $ = "data-gs-plg-wrapper-style", T = h.querySelector(`style[${$}]`) || f.createElement("style");
170
+ T.setAttribute($, "true"), T.innerHTML = `
171
+ [data-gjs-type="wrapper"] { min-height: ${w}; }
172
+ [data-gjs-type="mjml"] { min-height: ${w} !important; }
173
+ [data-gjs-type="mj-body"] { min-height: ${w} !important; }
174
+ `, !h.contains(T) && h.appendChild(T);
175
+ });
176
+ const j = () => H.style.display = "none", F = () => H.style.display = "", E = B(() => {
177
+ s.fitViewport({
178
+ zoom: (t) => t > 100 ? 100 : t,
179
+ ignoreHeight: !0,
180
+ gap: N
181
+ }), x(), setTimeout(() => {
182
+ var d, f;
183
+ const { em: t } = e;
184
+ t.destroyed || ((f = (d = e.getSelected()) == null ? void 0 : d.getEl()) == null || f.scrollIntoView({ block: "nearest" }), e.refresh({ tools: !0 }), F(), n.isActive(S) ? t.stopDefault() : t.runDefault());
185
+ }, z);
186
+ }, 100), K = (t = {}) => {
187
+ t.options && t.options.from !== "fitViewport" && s.fitViewport({
188
+ zoom: s.getZoom(),
189
+ ignoreHeight: !0,
190
+ gap: N
191
191
  });
192
- }), Q({
192
+ }, V = () => {
193
+ j(), E();
194
+ }, q = () => {
195
+ b.overflowX = "hidden", b.overflowY = "auto";
196
+ }, I = () => {
197
+ C == null || C.disconnect(), E.clear();
198
+ }, P = [
199
+ [i.events.select, V],
200
+ [y.zoom, K],
201
+ [L, q],
202
+ [e.events.destroy, I],
203
+ [c.events.mountBefore, ae]
204
+ ];
205
+ n.add(M, () => {
206
+ i.devices.reset(_), A.scrollableCanvas = !1, s.getModel().updateDevice(), s.setZoom(100), s.setCoords(0, 0), b.overflowY = "hidden", x(!0), P.forEach(([t, d]) => e.off(t, d)), I(), n.run("studio:canvasReload");
207
+ }), P.forEach(([t, d]) => e.on(t, d)), e.onReady(() => {
208
+ const t = s.getElement(), d = s.getFramesEl();
209
+ H = s.getSpotsEl(), b = t.style, b.overflowX = "hidden", d.style.transition = `transform ${u}s`, x(), C = new ResizeObserver(() => {
210
+ j(), E();
211
+ }), C.observe(t.parentElement), E();
212
+ }), ne({
193
213
  editor: e,
194
- licenseKey: c.licenseKey,
195
- plan: te,
214
+ licenseKey: r.licenseKey,
215
+ plan: oe,
196
216
  pluginName: k,
197
217
  cleanup: () => {
198
- e.runCommand(A);
218
+ e.runCommand(M);
199
219
  }
200
220
  });
201
- }, se = J(ne);
221
+ }, re = te(ce);
202
222
  export {
203
- se as default
223
+ re as default
204
224
  };
@@ -1,9 +1,9 @@
1
- (function(C,b){typeof exports=="object"&&typeof module<"u"?module.exports=b():typeof define=="function"&&define.amd?define(b):(C=typeof globalThis<"u"?globalThis:C||self,C.StudioSdkPlugins_canvasFullSize=b())})(this,function(){"use strict";function C(e,i,n){let t,o,c,p,d;const r=i;function u(){const l=Date.now()-p;l<r&&l>=0?t=setTimeout(u,r-l):(t=null,d=e.apply(c,o),c=o=null)}const s=function(){return c=this,o=arguments,p=Date.now(),t||(t=setTimeout(u,r)),d};return s.clear=function(){t&&(clearTimeout(t),t=null)},s.flush=function(){t&&(d=e.apply(c,o),c=o=null,clearTimeout(t),t=null)},s}const b="app.grapesjs.com",x="app-stage.grapesjs.com",H=[b,x,"localhost","127.0.0.1",".local-credentialless.webcontainer.io",".local.webcontainer.io","-sandpack.codesandbox.io"],F="license:check:start",K="license:check:end",q=()=>typeof window<"u",G=({isDev:e,isStage:i})=>`${e?"":`https://${i?x:b}`}/api`,V=()=>{const e=q()&&window.location.hostname;return!!e&&(H.includes(e)||H.some(i=>e.endsWith(i)))};async function X({path:e,baseApiUrl:i,method:n="GET",headers:t={},params:o,body:c}){const d=`${i||G({isDev:!1,isStage:!1})}${e}`,r={method:n,headers:{"Content-Type":"application/json",...t}};c&&(r.body=JSON.stringify(c));const u=o?new URLSearchParams(o).toString():"",s=u?`?${u}`:"",l=await fetch(`${d}${s}`,r);if(!l.ok)throw new Error(`HTTP error! status: ${l.status}`);return l.json()}var S=(e=>(e.free="free",e.startup="startup",e.business="business",e.enterprise="enterprise",e))(S||{});const P={[S.free]:0,[S.startup]:10,[S.business]:20,[S.enterprise]:30};function Y(e){const i=e;return i.init=n=>t=>e(t,n),i}const B=e=>Y(e);async function Z({editor:e,plan:i,pluginName:n,licenseKey:t,cleanup:o}){let c="",p=!1;const d=V(),r=s=>{console.warn("Cleanup plugin:",n,"Reason:",s),o()},u=(s={})=>{var T;const{error:l,sdkLicense:A}=s,v=(T=s.plan)==null?void 0:T.category;if(!(A||s.license)||l)r(l||"Invalid license");else if(v){const D=P[i],$=P[v];D>$&&r({pluginRequiredPlan:i,licensePlan:v})}};e.on(F,s=>{c=s==null?void 0:s.baseApiUrl,p=!0}),e.on(K,s=>{u(s)}),setTimeout(async()=>{if(!p){if(d)return;if(t){const s=await J({licenseKey:t,pluginName:n,baseApiUrl:c});s&&u(s)}else r("The `licenseKey` option not provided")}},2e3)}async function J(e){const{licenseKey:i,pluginName:n,baseApiUrl:t}=e;try{return(await X({baseApiUrl:t,path:`/sdk/${i||"na"}`,method:"POST",params:{d:window.location.hostname,pn:n}})).result||{}}catch(o){return console.error("Error during SDK license check:",o),!1}}const I="canvasFullSize",Q=S.startup;return B(function(e,i={}){const{Canvas:n,Commands:t,Devices:o}=e,c={deviceMaxWidth:1200,deviceMinHeigth:500,canvasOffsetY:30,canvasOffsetX:50,canvasTransition:.3,frameBorderRadius:5,frameTransition:.3,...i},{canvasOffsetY:p,canvasOffsetX:d,canvasTransition:r,deviceMaxWidth:u,deviceMinHeigth:s,frameBorderRadius:l,frameTransition:A}=c,v=`${s}px`,E=n.events,T="core:preview",D=`${t.events.stopCommand}${T}`,$=n.getConfig(),M=`${I}:disable`,ee=o.getAll().map(a=>({...a.attributes}));$.scrollableCanvas=!0,o.getAll().map(a=>{!a.get("width")&&a.set("width",`${u}px`),!a.get("height")&&a.set("height","auto"),!a.get("minHeight")&&a.set("minHeight",v)});const j=a=>{const y="data-gs-plg-full-size",f=document.querySelector(`style[${y}]`);if(a&&f)return f.remove();const m=f||document.createElement("style"),h=n.getZoomMultiplier();m.setAttribute(y,"true"),m.innerHTML=`
2
- .gjs-frame-wrapper { transition: width ${A}s !important; }
3
- .gjs-frame-wrapper__bottom { height: ${p*h}px }
4
- .gjs-frame { border-radius: ${l}px }
5
- `,!f&&document.body.appendChild(m)};e.on(E.frameLoadHead,a=>{if(!$.scrollableCanvas)return;const{window:y}=a,f=y.document,m=f.head,h="data-gs-plg-wrapper-style",w=m.querySelector(`style[${h}]`)||f.createElement("style");w.setAttribute(h,"true"),w.innerHTML=`
6
- [data-gjs-type="wrapper"] { min-height: ${v}; }
7
- [data-gjs-type="mjml"] { min-height: ${v} !important; }
8
- [data-gjs-type="mj-body"] { min-height: ${v} !important; }
9
- `,!m.contains(w)&&m.appendChild(w)}),e.onReady(()=>{const a=n.getSpotsEl(),y=n.getElement(),f=n.getFramesEl(),m=r*1e3,h=y.style;h.overflowX="hidden",f.style.transition=`transform ${r}s`;const w={x:d,y:p};j();const N=()=>a.style.display="none",te=()=>a.style.display="",L=C(()=>{n.fitViewport({zoom:g=>g>100?100:g,ignoreHeight:!0,gap:w}),j(),setTimeout(()=>{var _,R;const{em:g}=e;g.destroyed||((R=(_=e.getSelected())==null?void 0:_.getEl())==null||R.scrollIntoView({block:"nearest"}),e.refresh({tools:!0}),te(),t.isActive(T)?g.stopDefault():g.runDefault())},m)},100),O=new ResizeObserver(()=>{N(),L()});O.observe(y.parentElement);const k=()=>{N(),L()},z=(g={})=>{g.options&&g.options.from!=="fitViewport"&&n.fitViewport({zoom:n.getZoom(),ignoreHeight:!0,gap:w})},U=()=>{h.overflowX="hidden",h.overflowY="auto"},W=()=>{O.disconnect(),L.clear()};e.on(o.events.select,k),e.on(E.zoom,z),e.on(D,U),e.on(e.events.destroy,W),L(),t.add(M,()=>{o.devices.reset(ee),$.scrollableCanvas=!1,n.getModel().updateDevice(),n.setZoom(100),n.setCoords(0,0),h.overflowY="hidden",j(!0),e.off(o.events.select,k),e.off(E.zoom,z),e.off(D,U),W(),t.run("studio:canvasReload")})}),Z({editor:e,licenseKey:c.licenseKey,plan:Q,pluginName:I,cleanup:()=>{e.runCommand(M)}})})});
1
+ (function(w,g){typeof exports=="object"&&typeof module<"u"?module.exports=g():typeof define=="function"&&define.amd?define(g):(w=typeof globalThis<"u"?globalThis:w||self,w.StudioSdkPlugins_canvasFullSize=g())})(this,function(){"use strict";function w(e,a,s){let n,i,c,r,f;const l=a;function u(){const m=Date.now()-r;m<l&&m>=0?n=setTimeout(u,l-m):(n=null,f=e.apply(c,i),c=i=null)}const o=function(){return c=this,i=arguments,r=Date.now(),n||(n=setTimeout(u,l)),f};return o.clear=function(){n&&(clearTimeout(n),n=null)},o.flush=function(){n&&(f=e.apply(c,i),c=i=null,clearTimeout(n),n=null)},o}const g="app.grapesjs.com",N="app-stage.grapesjs.com",P=[g,N,"localhost","127.0.0.1",".local-credentialless.webcontainer.io",".local.webcontainer.io","-sandpack.codesandbox.io"],z="license:check:start",F="license:check:end",K=()=>typeof window<"u",V=({isDev:e,isStage:a})=>`${e?"":`https://${a?N:g}`}/api`,q=()=>{const e=K()&&window.location.hostname;return!!e&&(P.includes(e)||P.some(a=>e.endsWith(a)))};async function B({path:e,baseApiUrl:a,method:s="GET",headers:n={},params:i,body:c}){const f=`${a||V({isDev:!1,isStage:!1})}${e}`,l={method:s,headers:{"Content-Type":"application/json",...n}};c&&(l.body=JSON.stringify(c));const u=i?new URLSearchParams(i).toString():"",o=u?`?${u}`:"",m=await fetch(`${f}${o}`,l);if(!m.ok)throw new Error(`HTTP error! status: ${m.status}`);return m.json()}var v=(e=>(e.free="free",e.startup="startup",e.business="business",e.enterprise="enterprise",e))(v||{});const I={[v.free]:0,[v.startup]:10,[v.business]:20,[v.enterprise]:30};function G(e){const a=e;return a.init=s=>n=>e(n,s),a}const X=e=>G(e);async function Y({editor:e,plan:a,pluginName:s,licenseKey:n,cleanup:i}){let c="",r=!1;const f=q(),l=o=>{console.warn("Cleanup plugin:",s,"Reason:",o),i()},u=(o={})=>{var S;const{error:m,sdkLicense:A}=o,y=(S=o.plan)==null?void 0:S.category;if(!(A||o.license)||m)l(m||"Invalid license");else if(y){const T=I[a],H=I[y];T>H&&l({pluginRequiredPlan:a,licensePlan:y})}};e.on(z,o=>{c=o==null?void 0:o.baseApiUrl,r=!0}),e.on(F,o=>{u(o)}),setTimeout(async()=>{if(!r){if(f)return;if(n){const o=await Z({licenseKey:n,pluginName:s,baseApiUrl:c});o&&u(o)}else l("The `licenseKey` option not provided")}},2e3)}async function Z(e){const{licenseKey:a,pluginName:s,baseApiUrl:n}=e;try{return(await B({baseApiUrl:n,path:`/sdk/${a||"na"}`,method:"POST",params:{d:window.location.hostname,pn:s}})).result||{}}catch(i){return console.error("Error during SDK license check:",i),!1}}const U="canvasFullSize",J=v.startup,Q=(e,a)=>{var c;const{rule:s,ruleView:n}=a,{style:i}=s.attributes;if(i&&i[e]){const r=i[e],f=(c=r==null?void 0:r.endsWith)==null?void 0:c.call(r,"vh"),l=n.frameView.model;if(f&&l.hasAutoHeight()){const u=parseFloat(r),o=s.toCSS({style:{...i,[e]:`${window.outerHeight*(u/100)}px`}});a.css=o}}},ee=e=>{["height","min-height","max-height"].forEach(a=>Q(a,e))};return X(function(e,a={}){const{Canvas:s,Commands:n,Devices:i,Css:c}=e,r={deviceMaxWidth:1200,deviceMinHeigth:500,canvasOffsetY:30,canvasOffsetX:50,canvasTransition:.3,frameBorderRadius:5,frameTransition:.3,...a},{canvasOffsetY:f,canvasOffsetX:l,canvasTransition:u,deviceMaxWidth:o,deviceMinHeigth:m,frameBorderRadius:A,frameTransition:y}=r,b=`${m}px`,S=s.events,T="core:preview",H=`${n.events.stopCommand}${T}`,x=s.getConfig(),W=`${U}:disable`,te=i.getAll().map(t=>({...t.attributes})),ne=u*1e3,k={x:l,y:f};let C={},j,E;x.scrollableCanvas=!0,i.getAll().map(t=>{!t.get("width")&&t.set("width",`${o}px`),!t.get("height")&&t.set("height","auto"),!t.get("minHeight")&&t.set("minHeight",b)});const M=t=>{const d="data-gs-plg-full-size",p=document.querySelector(`style[${d}]`);if(t&&p)return p.remove();const h=p||document.createElement("style"),D=s.getZoomMultiplier();h.setAttribute(d,"true"),h.innerHTML=`
2
+ .gjs-frame-wrapper { transition: width ${y}s !important; }
3
+ .gjs-frame-wrapper__bottom { height: ${f*D}px }
4
+ .gjs-frame { border-radius: ${A}px }
5
+ `,!p&&document.body.appendChild(h)};e.on(S.frameLoadHead,t=>{if(!x.scrollableCanvas)return;const{window:d}=t,p=d.document,h=p.head,D="data-gs-plg-wrapper-style",L=h.querySelector(`style[${D}]`)||p.createElement("style");L.setAttribute(D,"true"),L.innerHTML=`
6
+ [data-gjs-type="wrapper"] { min-height: ${b}; }
7
+ [data-gjs-type="mjml"] { min-height: ${b} !important; }
8
+ [data-gjs-type="mj-body"] { min-height: ${b} !important; }
9
+ `,!h.contains(L)&&h.appendChild(L)});const _=()=>j.style.display="none",se=()=>j.style.display="",$=w(()=>{s.fitViewport({zoom:t=>t>100?100:t,ignoreHeight:!0,gap:k}),M(),setTimeout(()=>{var d,p;const{em:t}=e;t.destroyed||((p=(d=e.getSelected())==null?void 0:d.getEl())==null||p.scrollIntoView({block:"nearest"}),e.refresh({tools:!0}),se(),n.isActive(T)?t.stopDefault():t.runDefault())},ne)},100),oe=(t={})=>{t.options&&t.options.from!=="fitViewport"&&s.fitViewport({zoom:s.getZoom(),ignoreHeight:!0,gap:k})},ie=()=>{_(),$()},ae=()=>{C.overflowX="hidden",C.overflowY="auto"},O=()=>{E==null||E.disconnect(),$.clear()},R=[[i.events.select,ie],[S.zoom,oe],[H,ae],[e.events.destroy,O],[c.events.mountBefore,ee]];n.add(W,()=>{i.devices.reset(te),x.scrollableCanvas=!1,s.getModel().updateDevice(),s.setZoom(100),s.setCoords(0,0),C.overflowY="hidden",M(!0),R.forEach(([t,d])=>e.off(t,d)),O(),n.run("studio:canvasReload")}),R.forEach(([t,d])=>e.on(t,d)),e.onReady(()=>{const t=s.getElement(),d=s.getFramesEl();j=s.getSpotsEl(),C=t.style,C.overflowX="hidden",d.style.transition=`transform ${u}s`,M(),E=new ResizeObserver(()=>{_(),$()}),E.observe(t.parentElement),$()}),Y({editor:e,licenseKey:r.licenseKey,plan:J,pluginName:U,cleanup:()=>{e.runCommand(W)}})})});
@@ -0,0 +1,8 @@
1
+ import { CssRule } from 'grapesjs';
2
+ export interface OnCssMountProps {
3
+ rule: CssRule;
4
+ ruleView: CssRule['views'][0];
5
+ css: string;
6
+ }
7
+ export declare const updateVhHeight: (prop: string, props: OnCssMountProps) => void;
8
+ export declare const onCssMount: (props: OnCssMountProps) => void;
@@ -1,10 +1,17 @@
1
- import { ConditionType, DataCollectionResolverProps, DataVariableResolverProps, IDataSourceExporter } from '@studio/editor/src/typeConfigs/dataSources';
1
+ import { DataCollectionResolverProps, DataVariableResolverProps, IDataSourceExporter } from '@studio/editor/src/typeConfigs/dataSources';
2
+ import { DataConditionResolverProps } from '@studio/editor/src/components/public/StudioDataConditionPicker';
2
3
  export declare class EjsExporter implements IDataSourceExporter {
3
- getVariableSyntax(props: DataVariableResolverProps): string;
4
- getCollectionStartSyntax(options: DataCollectionResolverProps): string;
4
+ getVariableSyntax({ dataResolver }: {
5
+ dataResolver: DataVariableResolverProps;
6
+ }): string;
7
+ getCollectionStartSyntax({ dataResolver }: {
8
+ dataResolver: DataCollectionResolverProps;
9
+ }): string;
5
10
  private _sanitizeVariableName;
6
11
  getCollectionEndSyntax(): string;
7
- getConditionalStartSyntax(condition: ConditionType): string;
12
+ getConditionalStartSyntax({ dataResolver }: {
13
+ dataResolver: DataConditionResolverProps;
14
+ }): string;
8
15
  getConditionElseSyntax(): string;
9
16
  getConditionalEndSyntax(): string;
10
17
  private getFullPath;