@cntrl-site/components 1.0.115 → 1.0.116
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/dist/Chronicles-BNvvaFYY.mjs +744 -0
- package/dist/Chronicles-Dj1gvNjE.js +196 -0
- package/dist/{ChroniclesComponent-D-yEbs9w.mjs → ChroniclesComponent-0ZWBPdbh.mjs} +542 -491
- package/dist/ChroniclesComponent-D4_6w8f7.js +1 -0
- package/dist/Components/Chronicles/Chronicles.d.ts +7 -1
- package/dist/Components/Chronicles/ChroniclesComponent.d.ts +26 -2
- package/dist/Components/LightboxJournal/LightboxJournal.d.ts +1 -0
- package/dist/Components/LightboxStrip/LightboxStrip.d.ts +1 -0
- package/dist/LightboxJournal-Bmw2zm4t.js +549 -0
- package/dist/{LightboxJournal-D59ex6wH.mjs → LightboxJournal-gePVKQJ4.mjs} +429 -403
- package/dist/{LightboxStrip-YspzBP8N.mjs → LightboxStrip-BPQiQhd3.mjs} +461 -435
- package/dist/LightboxStrip-CTxRwLYk.js +412 -0
- package/dist/{components-D4ZrIo2M.js → components-B8MjlzLL.js} +1 -1
- package/dist/{components-Ds6rhj3U.mjs → components-BQjon_-7.mjs} +1 -1
- package/dist/elements.js +1 -1
- package/dist/elements.mjs +3 -3
- package/dist/elements.node.js +1 -1
- package/dist/elements.node.mjs +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +36 -32
- package/dist/sources.js +124 -25
- package/dist/sources.mjs +131 -32
- package/dist/types/SchemaV1.d.ts +3 -0
- package/package.json +1 -1
- package/dist/Chronicles-Cy2h3jlZ.mjs +0 -724
- package/dist/Chronicles-D0ojQzOP.js +0 -196
- package/dist/ChroniclesComponent-Os_r2IYg.js +0 -1
- package/dist/LightboxJournal-DAEZOPDi.js +0 -523
- package/dist/LightboxStrip-BDjI1jyH.js +0 -386
|
@@ -0,0 +1,412 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("react/jsx-runtime"),a=require("react"),kn=require("react-dom"),En=require("./useScopedStyles-Bf6yohVQ.js"),Z=require("./useLightboxSwipeDismiss-Br9uE5G0.js"),At=require("./scalingValue-CSHYgTZl.js"),Nn=require("./SvgImage-DFlmxAoL.js"),On=require("./useLightboxScrollLock-Hf16Eq4g.js"),zn=require("./textStylesToCss-CNN3zZTV.js"),Fn=(e,o,u,f)=>{const l=Math.min(Math.abs(e)/Math.max(f,1),1);return o+(u-o)*l},Kn=e=>{e.style.transition="",e.style.transform="",e.style.willChange=""},Bn=e=>{const o=getComputedStyle(e).transform;return o==="none"?0:new DOMMatrixReadOnly(o).m41},Dn=(e,o,u,{duration:f,easing:l,onComplete:m})=>{const p=e.scrollLeft,w=u-p,R=p-u,N=(A,Q)=>{Kn(o),e.scrollLeft=A,Q&&(m==null||m())};if(Math.abs(w)<.5)return N(u,!0),()=>{};let M=!1,J=0;const I=()=>{o.removeEventListener("transitionend",O),clearTimeout(J)},O=A=>{A.target!==o||A.propertyName!=="transform"||M||(M=!0,I(),N(u,!0))};return o.addEventListener("transitionend",O),o.style.willChange="transform",o.style.transition="none",o.style.transform="translate3d(0, 0, 0)",o.offsetHeight,o.style.transition=`transform ${f}ms ${l}`,o.style.transform=`translate3d(${R}px, 0, 0)`,J=window.setTimeout(()=>{M||(M=!0,I(),N(u,!0))},f+64),()=>{M||(M=!0,I(),N(p-Bn(o),!1))}},xt=300,Hn=900,Xn=1500,Gn="cubic-bezier(0.16, 1, 0.3, 1)",Vn=3e3,Yn=2,qn=16,Un=.05,Zn=1,Wt=.3,Jn=50,Qn=20,at=.004,Fe=["title1","title2","title3"],Ke={title1:"1",title2:"2",title3:"3"},Pn={title1:"title1Color",title2:"title2Color",title3:"title3Color"},tr={title1:.02,title2:.02,title3:.02},Ct=e=>`max(${e}, ${Qn}px)`,Be=e=>{if(!Array.isArray(e)||e.length===0)return{};const o=e.find(l=>(l==null?void 0:l.type)==="paragraph")??e[0],u=o==null?void 0:o.children;if(!Array.isArray(u))return{};const f=u.map(l=>typeof(l==null?void 0:l.text)=="string"?l.text.trim():"").filter(Boolean);return{title1:f[0],title2:f[1],title3:f[2]}},De=e=>{if(!e)return{title1:"",title2:"",title3:""};if(e.title1||e.title2||e.title3)return{title1:e.title1??"",title2:e.title2??"",title3:e.title3??""};const o=Be(e.text);return{title1:o.title1??"",title2:o.title2??"",title3:o.title3??""}},E=(e,o)=>`${e}${o.charAt(0).toUpperCase()}${o.slice(1)}`,He=e=>[E(e,"fontFamily"),E(e,"fontSettings"),{type:"row",items:[E(e,"fontSize"),E(e,"lineHeight"),E(e,"letterSpacing"),E(e,"wordSpacing")]},E(e,"textAlign"),E(e,"textAppearance")],er=()=>({type:"tab",id:"stripTextStyle",tabs:Object.fromEntries(Fe.map(e=>[Ke[e],He(e)]))}),oe=(e,o)=>{if(e<=0)return[];const u=o.slice(0,e),f=u.reduce((m,p)=>m+p,0);if(f<=1)return u;const{widths:l}=[...u].reverse().reduce(({overflow:m,widths:p},w)=>{if(m<=0||w<=0)return{overflow:m,widths:[w,...p]};const R=Math.min(m,w);return{overflow:m-R,widths:[w-R,...p]}},{overflow:f-1,widths:[]});return l},Xe=(e,o)=>oe(e,o),jt=(e,o)=>{const u=o.filter((f,l)=>l!==e).reduce((f,l)=>f+l,0);return Math.max(1-u,0)},ze=(e,o)=>{const u=e.map(f=>o[f.widthKey]??0);return{resolved:oe(e.length,u),effective:Xe(e.length,u)}},nr=(e,o,u,f,l,m,p)=>{const w=[];return o&&w.push({prefix:"title1",widthKey:"title1Width",className:`${e}-title1`,style:l,text:o}),u&&w.push({prefix:"title2",widthKey:"title2Width",marginLeftKey:"title2MarginLeft",className:`${e}-title2`,style:m,text:u}),f&&w.push({prefix:"title3",widthKey:"title3Width",marginLeftKey:"title3MarginLeft",className:`${e}-title3`,style:p,text:f}),w},ne=(e,o)=>{const u=f=>{const l=E(o,f);return e[l]};return{fontFamily:u("fontFamily")??"Arial",fontSettings:u("fontSettings")??{fontWeight:400,fontStyle:"normal"},fontSize:u("fontSize"),lineHeight:u("lineHeight"),letterSpacing:u("letterSpacing")??0,wordSpacing:u("wordSpacing")??0,textAlign:u("textAlign")??"left",textAppearance:u("textAppearance"),color:e[Pn[o]]}},rr=(e,o,u,f)=>e.slice(0,f).reduce((l,m,p)=>l+(m!=null&&m.marginLeftKey?u[m.marginLeftKey]??0:0)+(o[p]??0),0),re=(e,o,u)=>{var l,m;const f={fontSettings:{fontFamily:o.fontFamily,fontWeight:((l=o.fontSettings)==null?void 0:l.fontWeight)??400,fontStyle:((m=o.fontSettings)==null?void 0:m.fontStyle)??"normal"},fontSize:o.fontSize??tr[e],lineHeight:o.lineHeight,letterSpacing:o.letterSpacing,wordSpacing:o.wordSpacing,textAlign:o.textAlign,textAppearance:o.textAppearance,color:o.color??"#ffffff"};return zn.textStylesToCss(f,u)},or=({prefix:e,images:o,settings:u,isEditor:f,isEditMode:l,isPreviewMode:m,onClose:p})=>{const{backgroundColor:w,thumbnailSize:R,thumbnailGap:N,thumbnailMarginBottom:M,imageGap:J,closeIcon:I,closeIconMaxWidth:O,closeIconColor:A,closeIconHoverColor:Q,thumbnailTrigger:vt,thumbnailVisibility:ct,thumbnailObjectFit:bt,thumbnailActive:Ve,thumbnailActiveColor:Ye,title1Width:kt,title2Width:ie,title3Width:se,title1MarginLeft:W=0,title2MarginLeft:le=0,title3MarginLeft:ae=0,titleRowMarginBottom:ce=0,titleHeaderLayout:ue="desktop",contentMarginTop:qe,iconMarginLeft:Ue}=u,P=t=>At.scalingValue(t,f??!1),Ze=R??u.thumnailSize??.03,fe=P(Ze),Et=P(N),Nt=P(M??.02),ut=P(J??0),he=P(qe??0),Je=Ct(he),de=P(Ue??0),[tt,Ot]=a.useState(0),C=a.useRef(tt);C.current=tt;const Qe=o[tt],{title1:zt,title2:Ft,title3:Kt}=De(Qe),me=re("title1",ne(u,"title1"),f),pe=re("title2",ne(u,"title2"),f),ge=re("title3",ne(u,"title3"),f),j=ue==="mobile",G=!l&&(!f||m),ft=G,ht=G,Pe=G,xe=Z.isImageRatioCover(bt),tn=xe?{"--image-aspect-ratio":Z.getAspectRatio(bt)}:void 0,ve=!!(zt||Ft||Kt),x=a.useMemo(()=>nr(e,zt,Ft,Kt,me,pe,ge),[e,tt,zt,Ft,Kt,me,pe,ge]),et=a.useMemo(()=>({title1Width:kt,title2Width:ie,title3Width:se}),[kt,ie,se]),yt=a.useMemo(()=>x.map(t=>et[t.widthKey]),[x,et]),z=a.useMemo(()=>oe(x.length,yt),[x.length,yt]),be=a.useMemo(()=>Xe(x.length,yt),[x.length,yt]),wt=a.useMemo(()=>x.filter(t=>t.prefix==="title1"),[x]),_=a.useMemo(()=>x.filter(t=>t.prefix==="title2"||t.prefix==="title3"),[x]),St=a.useMemo(()=>ze(wt,et),[wt,et]),B=a.useMemo(()=>ze(_,et),[_,et]),Bt=a.useCallback((t,n)=>{const r=x.indexOf(t);if(!j||n==="single-row")return{effectiveWidth:be[r]??0,resolvedWidth:z[r]??0,maxWidth:jt(r,z)};if(n==="two-row-top"){const s=wt.indexOf(t);return{effectiveWidth:St.effective[s]??0,resolvedWidth:St.resolved[s]??0,maxWidth:jt(s,St.resolved)}}const i=_.indexOf(t);return{effectiveWidth:B.effective[i]??0,resolvedWidth:B.resolved[i]??0,maxWidth:jt(i,B.resolved)}},[_,B,be,z,x,wt,St,j]),y=a.useCallback(t=>At.scalingValue(t,f??!1),[f]),en=y(ce??0),k=a.useMemo(()=>({title1MarginLeft:W,title2MarginLeft:le,title3MarginLeft:ae}),[W,le,ae]),nn=a.useCallback(t=>x.slice(0,t+1).reduce((n,r,i)=>n+(r!=null&&r.marginLeftKey?k[r.marginLeftKey]??0:0)+(z[i]??0),0)+(j?0:W??0),[x,k,z,j,W]),rn=a.useCallback(()=>j?0:W??0,[j,W]),Dt=a.useCallback(t=>_.slice(0,t).reduce((n,r,i)=>n+(r.marginLeftKey?k[r.marginLeftKey]??0:0)+(B.resolved[i]??0),0),[_,B.resolved,k]),on=a.useCallback(t=>{const n=_[t];return Dt(t)+(n.marginLeftKey?k[n.marginLeftKey]??0:0)+(B.resolved[t]??0)},[_,B.resolved,Dt,k]),Ht=(t,n)=>{const r=t.marginLeftKey?k[t.marginLeftKey]??0:0,{effectiveWidth:i,resolvedWidth:s,maxWidth:h}=Bt(t,n),d=l&&n==="two-row-top";return c.jsxs("div",{className:`${e}-title-cell`,"data-title":t.prefix,style:{...n==="single-row"?{gridArea:t.prefix}:{},width:y(i),...r>0?{marginLeft:y(r)}:{}},children:[c.jsx("p",{className:t.className,style:t.style,children:t.text}),d&&t.marginLeftKey&&c.jsx("div",{"data-controls":t.marginLeftKey,"data-controls-axis":"x","data-controls-min":"0","data-controls-max-fraction":String(s),style:{position:"absolute",top:0,left:y(-r),width:`max(${y(r)}, 10px)`,height:"100%",pointerEvents:"auto"}}),d&&c.jsx("div",{"data-controls":t.widthKey,"data-controls-axis":"x","data-controls-max-fraction":String(h),"data-controls-variant":"column-width",className:`${e}-title-resize-handle`,style:{position:"absolute",top:0,right:y(-at/2),width:y(at),height:"100%",pointerEvents:"auto"}})]},t.className)},sn=()=>{const t=j?-1:x.findIndex(i=>i.prefix==="title1"),n=!j&&(l||(W??0)>0)?(()=>{const i=W??0,s=t>=0?z[t]:kt??0;return c.jsx("div",{"data-controls":"title1MarginLeft","data-controls-axis":"x","data-controls-min":"0","data-controls-max-fraction":String(s),style:{position:"absolute",top:0,left:0,width:`max(${y(i)}, 10px)`,height:"100%",pointerEvents:"auto"}},"title1MarginLeft")})():null,r=x.flatMap((i,s)=>{if(!i.marginLeftKey)return[];const h=k[i.marginLeftKey]??0,d=rr(x,z,k,s)+rn();return c.jsx("div",{"data-controls":i.marginLeftKey,"data-controls-axis":"x","data-controls-min":"0","data-controls-max-fraction":String(z[s]),style:{position:"absolute",top:0,left:y(d),width:`max(${y(h)}, 10px)`,height:"100%",pointerEvents:"auto"}},i.marginLeftKey)});return n?[n,...r]:r},ln=()=>x.map((t,n)=>{const r=jt(n,z),s=nn(n)-at/2;return c.jsx("div",{style:{position:"absolute",inset:0,pointerEvents:"none"},children:c.jsx("div",{"data-controls":t.widthKey,"data-controls-axis":"x","data-controls-max-fraction":String(r),"data-controls-variant":"column-width",className:`${e}-title-resize-handle`,style:{position:"absolute",top:0,left:y(s),width:y(at),height:"100%",pointerEvents:"auto"}})},`${t.widthKey}-junction`)}),an=()=>_.flatMap((t,n)=>{if(!t.marginLeftKey)return[];const r=k[t.marginLeftKey]??0,i=Dt(n),{resolvedWidth:s}=Bt(t,"two-row-bottom");return c.jsx("div",{"data-controls":t.marginLeftKey,"data-controls-axis":"x","data-controls-min":"0","data-controls-max-fraction":String(s),style:{position:"absolute",top:0,left:y(i),width:`max(${y(r)}, 10px)`,height:"100%",pointerEvents:"auto"}},t.marginLeftKey)}),cn=()=>_.map((t,n)=>{const{maxWidth:r}=Bt(t,"two-row-bottom"),s=on(n)-at/2;return c.jsx("div",{style:{position:"absolute",inset:0,pointerEvents:"none"},children:c.jsx("div",{"data-controls":t.widthKey,"data-controls-axis":"x","data-controls-max-fraction":String(r),"data-controls-variant":"column-width",className:`${e}-title-resize-handle`,style:{position:"absolute",top:0,left:y(s),width:y(at),height:"100%",pointerEvents:"auto"}})},`${t.widthKey}-junction`)}),un=a.useRef(null),v=a.useRef(null),Xt=a.useRef(null),ye=a.useRef(null),$t=a.useRef([]),S=a.useRef([]),nt=a.useRef(0),Lt=a.useRef(null),b=a.useRef({isActive:!1,startX:0,scrollLeft:0,startActiveIndex:0,hasMoved:!1}),dt=a.useRef(null),rt=a.useRef(null),Gt=a.useRef(0),Vt=a.useRef("forward"),D=a.useRef(0),H=a.useRef(null),V=a.useRef(!1),$=o.length>1&&(!l||!!m),Yt=$?3:1,fn=a.useMemo(()=>Array.from({length:Yt},()=>o).flat(),[o,Yt]),[hn,we]=a.useState(!1),[Se,$e]=a.useState(!1),[dn,qt]=a.useState(!0),Y=a.useRef(null),ot=a.useRef(null),Ut=a.useRef(!1),Le=a.useRef(!1),Zt=a.useRef(null),q=a.useRef(null),Te=ft&&!dn,F=a.useCallback(()=>{ft&&(qt(!0),q.current&&clearTimeout(q.current),q.current=setTimeout(()=>{b.current.isActive||qt(!1)},Vn))},[ft]),mt=a.useCallback(()=>{l||Le.current||(Le.current=!0,$e(!1),Zt.current=setTimeout(()=>{p()},xt))},[l,p]),Re=()=>c.jsxs("div",{className:`${e}-close-icon`,"data-overlay-content-hidden":Te?"true":"false",style:{width:At.scalingValue(O??0,f),height:At.scalingValue(O??0,f),marginRight:de,"--close-icon-hover-color":Q},children:[c.jsx("button",{type:"button",className:`${e}-close-icon-inner`,onClick:mt,"aria-label":"Close",children:c.jsx(Nn.SvgImage,{url:I,fill:A,hoverFill:f&&!m?A:Q,className:`${e}-close-icon-img`})}),l&&c.jsx("div",{"data-controls":"iconMarginLeft","data-controls-axis":"x","data-controls-reverse":"",className:`${e}-control`,style:{position:"absolute",top:0,left:"100%",width:de,height:"100%",pointerEvents:"auto"}})]}),Ie=(t="two-row")=>c.jsx("div",{...t==="two-row"&&l?{"data-controls":"title1MarginLeft","data-controls-axis":"x"}:{},style:{width:y(W??0),flexShrink:0,...t==="single-row"?{gridArea:"margin"}:{alignSelf:"stretch"},...t==="two-row"&&l?{pointerEvents:"auto"}:{}}}),mn=()=>{const t=x.find(i=>i.prefix==="title1"),n=x.filter(i=>i.prefix==="title2"||i.prefix==="title3"),r=n.length>0||l||(ce??0)>0;return c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:`${e}-header-row-top`,children:[(W??0)>0||l?Ie():null,t&&Ht(t,"two-row-top"),I&&Re()]}),r?c.jsxs("div",{className:`${e}-header-row-bottom-wrap`,children:[n.length>0?c.jsxs("div",{className:`${e}-header-row-bottom`,children:[n.map(i=>Ht(i,"two-row-bottom")),l&&c.jsxs(c.Fragment,{children:[an(),cn()]})]}):null,c.jsx("div",{"data-controls":l?"titleRowMarginBottom":void 0,"data-controls-axis":l?"y":void 0,"data-controls-reverse":l?"":void 0,className:l?`${e}-control`:void 0,style:{height:en,width:"100%",flexShrink:0,pointerEvents:l?"auto":"none"}})]}):null]})},pn=()=>c.jsxs(c.Fragment,{children:[(W??0)>0||l?Ie("single-row"):null,x.map(t=>Ht(t,"single-row")),l?c.jsxs(c.Fragment,{children:[sn(),ln()]}):null,I?Re():null]}),Jt=a.useCallback(t=>!!(t.closest("[data-controls]")||t.closest(`.${e}-thumbnails`)||t.closest(`.${e}-close-icon`)),[e]),{isSwipeDragging:gn,backdropStyle:xn,mediaAreaStyle:vn,overlayContentStyle:bn,swipeHandlers:yn,dismissAreaStyle:wn}=Z.useLightboxSwipeDismiss({enabled:G??!1,onClose:mt,animMs:xt,isBlockedTarget:Jt}),Qt=()=>{if(!$||o.length===0)return nt.current=0,0;const t=S.current[0],n=S.current[o.length];if(!t||!n)return nt.current;const r=n.offsetLeft-t.offsetLeft;return r>0&&(nt.current=r),nt.current},U=(t=!1)=>{if(!$)return;const n=v.current,r=Qt();!n||r<=0||r<n.clientWidth*.25||(n.scrollLeft<=0?(n.scrollLeft+=r,t&&(b.current.scrollLeft+=r),V.current&&(D.current+=r)):n.scrollLeft>=r*2&&(n.scrollLeft-=r,t&&(b.current.scrollLeft-=r),V.current&&(D.current-=r)))},Ae=(t,n=(r=>(r=v.current)==null?void 0:r.scrollLeft)()??0)=>{if(!$)return t;let i=o.length+t,s=1/0;for(let h=0;h<Yt;h++){const d=h*o.length+t,g=S.current[d];if(!g)continue;const L=Math.abs(g.offsetLeft-n);L<s&&(s=L,i=d)}return i},We=t=>{const n=v.current;return!t||!n?!1:t.offsetWidth>n.clientWidth+1},Pt=t=>{const n=v.current;if(!t||!n||!We(t))return!1;const r=t.offsetLeft,i=r+t.offsetWidth;return n.scrollLeft>=r-1&&n.scrollLeft+n.clientWidth<=i+1},it=(t=(n=>(n=v.current)==null?void 0:n.scrollLeft)()??0)=>{for(let i=0;i<S.current.length;i+=1){const s=S.current[i];if(s&&Pt(s))return i}let r={flatIndex:0,distance:1/0};return S.current.forEach((i,s)=>{if(!i)return;const h=Math.abs(i.offsetLeft-t);h<r.distance&&(r={flatIndex:s,distance:h})}),r.flatIndex},Ce=t=>{v.current&&S.current.forEach(n=>{n&&(n.style.scrollSnapAlign=We(n)&&t==="backward"?"end":"start")})},Sn=(t,n,r)=>{const i=t-n,s=it(n),h=S.current[s];if(Pt(h))return it(t)%o.length;const d=S.current[s+1],g=h?d?d.offsetLeft-h.offsetLeft:h.offsetWidth:0,L=g>0?i>g*Wt?1:i<-g*Wt?-1:0:0;return L===0?r:$?(r+L+o.length)%o.length:Math.max(0,Math.min(o.length-1,r+L))},je=a.useCallback((t=!1)=>{if(ct!=="on"||l)return;const n=ye.current,r=C.current,i=$t.current[r];if(!n||!i||n.scrollWidth<=n.clientWidth)return;const s=n.scrollLeft,h=s+n.clientWidth,d=i.offsetLeft,g=d+i.offsetWidth;if(d>=s&&g<=h)return;const L=n.scrollWidth-n.clientWidth;let T=s;if(!t&&Y.current===null){const lt=$t.current[r-1],gt=$t.current[r+1],It=lt?i.offsetLeft-lt.offsetLeft:gt?gt.offsetLeft-i.offsetLeft:i.offsetWidth;g>h?T+=It:d<s&&(T-=It)}else g>h?T=g-n.clientWidth:T=d;n.scrollLeft=Math.max(0,Math.min(L,T))},[l,ct]),te=a.useCallback((t=!1)=>{t&&(Ut.current=!0),ot.current===null&&(ot.current=requestAnimationFrame(()=>{ot.current=null;const n=Ut.current;Ut.current=!1,je(n)}))},[je]),$n=a.useCallback(t=>{if(t===C.current)return;const n=C.current;C.current=t;const r=Math.abs(t-n)>1,i=$&&o.length>1&&(n===o.length-1&&t===0||n===0&&t===o.length-1);Ot(t),te(r||i)},[o.length,$,te]),K=()=>{if(!v.current||o.length===0||Y.current!==null||b.current.isActive&&b.current.hasMoved)return;const t=v.current.scrollLeft,n=it(t)%o.length;n!==C.current&&$n(n)},Ln=()=>{Y.current=null},X=t=>{const n=v.current;n&&(n.style.scrollSnapType=t?"":"none")},pt=()=>{var t;(t=rt.current)==null||t.call(rt),rt.current=null},Tt=()=>{H.current!==null&&(cancelAnimationFrame(H.current),H.current=null),V.current=!1},Me=()=>{const t=v.current;if(!t){H.current=null,V.current=!1;return}const n=D.current-t.scrollLeft;if(Math.abs(n)<.5){t.scrollLeft=D.current,U(),K(),H.current=null,V.current=!1;return}t.scrollLeft+=n*Un,U(),K(),F(),H.current=requestAnimationFrame(Me)},_e=()=>{const t=Xt.current;t&&(t.style.transition="",t.style.transform="",t.style.willChange="")},ke=(t,n,r,i)=>{_e(),t.scrollLeft=n,Gt.current=t.scrollLeft,U(),r!==void 0?(C.current=r,Ot(r)):K(),X(!0),i==null||i()},Ee=(t,{behavior:n="smooth",activeIndex:r,onComplete:i}={})=>{const s=v.current,h=Xt.current;if(!s||!h)return;if(Tt(),pt(),X(!1),n==="auto"){ke(s,t,r,i);return}const d=Math.abs(t-s.scrollLeft),g=Fn(d,Hn,Xn,s.clientWidth*.55);rt.current=Dn(s,h,t,{duration:g,easing:Gn,onComplete:()=>{rt.current=null,ke(s,t,r,i)}})},Tn=(t="smooth")=>{const n=v.current;if(!n||o.length===0)return;const r=it()%o.length,i=Ae(r,n.scrollLeft),s=S.current[i];s&&Ee(s.offsetLeft,{behavior:t,activeIndex:r})},Rn=(t,n="smooth",r,i)=>{const s=v.current;if(!s||o.length===0)return;const h=(i??s.scrollLeft)-t,d=it(t),g=S.current[d];if(Pt(g)){X(!0),K();return}const L=S.current[d+1],T=g?L?L.offsetLeft-g.offsetLeft:g.offsetWidth:0;if((T>0?h>T*Wt?1:h<-T*Wt?-1:0:0)!==0){const Mn=r??d%o.length,_n=Sn(i??s.scrollLeft,t,Mn);st(_n,n);return}const gt=i??s.scrollLeft,It=it(gt),Oe=S.current[It];if(Oe&&Math.abs(Oe.offsetLeft-gt)<1){X(!0),K();return}Tn("auto")},st=(t,n="smooth")=>{const r=v.current;if(!r||o.length===0)return;const i=Ae(t,r.scrollLeft),s=S.current[i];s&&(n==="smooth"?Y.current=t:Y.current=null,C.current=t,Ot(t),te(!0),Ee(s.offsetLeft,{behavior:n,activeIndex:t,onComplete:n==="smooth"?Ln:void 0}))},ee=()=>{dt.current&&(window.removeEventListener("pointerup",dt.current),window.removeEventListener("pointercancel",dt.current),dt.current=null)},In=(t,n,r,i,s)=>{const h=r-t,d=i-n,g=Math.abs(h),L=Math.abs(d);if(g<Jn||g<=L)return!1;const T=h<0?1:-1,lt=$?(s+T+o.length)%o.length:Math.max(0,Math.min(o.length-1,s+T));return lt===s?!1:(st(lt),!0)},Rt=t=>{if(!b.current.isActive)return;ee();const n=v.current;if(!n)return;const{scrollLeft:r,startActiveIndex:i,hasMoved:s}=b.current,h=n.scrollLeft;U(!0),b.current={isActive:!1,startX:0,scrollLeft:0,startActiveIndex:0,hasMoved:!1},we(!1),t!==void 0&&n.hasPointerCapture(t)&&n.releasePointerCapture(t),s?Rn(r,"smooth",i,h):(X(!0),K()),F()},An=(t,n)=>{const r=Lt.current;Lt.current=null,r&&(In(r.startX,r.startY,t,n,r.startActiveIndex),F())},Wn=t=>{if(!ht)return;if(t.pointerType==="touch"){if(Tt(),X(!0),Jt(t.target))return;Lt.current={startX:t.clientX,startY:t.clientY,startActiveIndex:C.current};return}if(t.pointerType!=="mouse"||t.button!==0||Jt(t.target))return;const n=v.current;if(!n)return;Tt(),pt(),_e(),Y.current=null,b.current={isActive:!0,startX:t.clientX,scrollLeft:n.scrollLeft,startActiveIndex:C.current,hasMoved:!1},X(!1),F(),n.setPointerCapture(t.pointerId),ee();const r=i=>{i.pointerType==="mouse"&&Rt(i.pointerId)};dt.current=r,window.addEventListener("pointerup",r),window.addEventListener("pointercancel",r)},Cn=t=>{if(!ht||t.pointerType!=="mouse")return;const n=v.current;if(!n||!b.current.isActive)return;if(t.buttons===0){Rt(t.pointerId);return}const r=t.clientX-b.current.startX;Math.abs(r)>Zn&&(b.current.hasMoved=!0,we(!0)),b.current.hasMoved&&(t.preventDefault(),n.scrollLeft=b.current.scrollLeft-r,U(!0),K(),F())},Ne=t=>{if(ht){if(t.pointerType==="touch"){t.type==="pointerup"?An(t.clientX,t.clientY):Lt.current=null;return}t.pointerType==="mouse"&&Rt(t.pointerId)}},jn=t=>{!ht||t.pointerType!=="mouse"||Rt(t.pointerId)};return On.useLightboxScrollLock(),a.useEffect(()=>{const t=requestAnimationFrame(()=>$e(!0));return()=>{cancelAnimationFrame(t),pt(),ee(),ot.current!==null&&(cancelAnimationFrame(ot.current),ot.current=null),Zt.current&&clearTimeout(Zt.current),q.current&&clearTimeout(q.current)}},[]),a.useEffect(()=>{if(!ft){qt(!0);return}F();const t=()=>F();return document.addEventListener("pointermove",t,{passive:!0}),document.addEventListener("pointerdown",t,{passive:!0}),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerdown",t),q.current&&clearTimeout(q.current)}},[ft,F]),a.useEffect(()=>{const t=n=>{n.key==="Escape"&&mt()};return window.addEventListener("keydown",t),()=>window.removeEventListener("keydown",t)},[mt]),a.useLayoutEffect(()=>{Qt()},[ut,o.length,$]),a.useLayoutEffect(()=>{l||st(C.current,"auto")},[ut,l]),a.useLayoutEffect(()=>{st(0,"auto")},[o.length,$]),a.useEffect(()=>{const t=v.current;if(!t||l||!G)return;const n=r=>{if(r.preventDefault(),Math.abs(r.deltaY)<=Math.abs(r.deltaX))return;const i=r.deltaMode===1?qn:r.deltaMode===2?t.clientHeight:1,s=r.deltaY*i*Yn;if(s!==0){if(pt(),V.current||(V.current=!0,D.current=t.scrollLeft,Y.current=null,X(!1)),D.current+=s,!$){const h=t.scrollWidth-t.clientWidth;D.current=Math.max(0,Math.min(h,D.current))}F(),H.current===null&&(H.current=requestAnimationFrame(Me))}};return t.addEventListener("wheel",n,{passive:!1}),()=>{t.removeEventListener("wheel",n),Tt()}},[l,G,$]),a.useEffect(()=>{const t=v.current;if(!t)return;const n=()=>{U(b.current.isActive);const i=t.scrollLeft,s=i-Gt.current;Gt.current=i;const h=nt.current>0?nt.current*.5:1/0;if(s!==0&&Math.abs(s)<h){const d=s>0?"forward":"backward";d!==Vt.current&&(Vt.current=d,Ce(d))}b.current.isActive&&b.current.hasMoved||K()};t.addEventListener("scroll",n,{passive:!0});const r=new ResizeObserver(()=>{Qt(),U(b.current.isActive),Ce(Vt.current),K()});return r.observe(t),()=>{pt(),t.removeEventListener("scroll",n),r.disconnect()}},[o.length,$]),c.jsxs("div",{"data-selection":"none",className:`${e}-lightbox${f?` ${e}-lightbox-editor`:""}${l?` ${e}-lightbox-edit-mode`:""}`,onClick:()=>{gn||mt()},role:"dialog","aria-modal":"true","aria-label":"Image gallery",style:{opacity:Se?1:0,transition:`opacity ${xt}ms ease`,pointerEvents:Se?"auto":"none"},children:[c.jsx("div",{className:`${e}-lightbox-backdrop`,style:{backgroundColor:w,...xn}}),c.jsxs("div",{ref:un,className:`${e}-lightbox-dismiss-area`,style:wn,...yn,children:[c.jsx("div",{className:`${e}-lightbox-content`,style:vn,onClick:t=>t.stopPropagation(),children:c.jsx("div",{ref:v,className:`${e}-lightbox-strip`,"data-lightbox-scrollable":"","data-mouse-draggable":ht&&o.length>0?"true":"false","data-mouse-dragging":hn?"true":"false",onPointerDown:Wn,onPointerMove:Cn,onPointerUp:Ne,onPointerCancel:Ne,onLostPointerCapture:jn,children:c.jsx("div",{ref:Xt,className:`${e}-lightbox-strip-track`,style:{gap:ut},children:fn.map((t,n)=>{const r=t.image.objectFit??"contain",i=n%o.length,s=Math.floor(n/o.length),h=Ct(ut),d=`calc(-0.5 * (${h} + ${ut}))`;return c.jsxs("div",{ref:g=>S.current[n]=g,className:`${e}-strip-item`,style:{height:ue==="mobile"?"calc(0.75 * var(--cntrl-viewport-height, 100vh))":"100%"},children:[c.jsx("img",{src:t.image.assetId,draggable:!1,style:{display:"block",maxWidth:"100%",height:"100%",objectFit:r}}),l&&i<o.length-1&&s===0&&c.jsx("div",{"data-controls":"imageGap","data-controls-axis":"x",style:{position:"absolute",top:0,right:d,width:h,height:"100%",pointerEvents:"auto",zIndex:3}})]},`${s}-${t.image.assetId}-${i}`)})})})}),c.jsxs("div",{className:`${e}-lightbox-content-inner`,"data-overlay-content-hidden":Te?"true":"false",style:bn,children:[c.jsx("div",{style:{position:"relative",width:"100%",height:he,flexShrink:0,pointerEvents:"none"},children:l&&c.jsx("div",{"data-controls":"contentMarginTop","data-controls-axis":"y","data-controls-handle-left-fraction":"0.05",style:{position:"absolute",left:0,right:0,top:0,height:Je,pointerEvents:"auto",zIndex:3}})}),c.jsx("div",{style:{display:"flex",flexDirection:"row",width:"100%",flex:1,minHeight:0,pointerEvents:"none"},children:c.jsx("div",{className:`${e}-lightbox-content-area${j?` ${e}-lightbox-content-area-stacked`:""}`,children:(ve||I)&&c.jsx("div",{className:`${e}-header ${j?`${e}-header-two-row`:`${e}-header-single-row`}`,children:j?mn():ve||I?pn():null})})})]}),o.length>1&&ct==="on"&&(()=>{const t=Ct(Nt),n=`calc(-0.5 * (${Nt} + ${t}))`;return c.jsx("div",{className:`${e}-thumbnails-wrap`,style:{bottom:Nt},children:c.jsx("div",{ref:ye,className:`${e}-thumbnails`,"data-lightbox-scrollable":"",onClick:r=>r.stopPropagation(),children:c.jsxs("div",{className:`${e}-thumbnails-track`,"data-thumbnail-active":Ve,style:{gap:Et,"--thumbnail-active-color":Ye},children:[o.map((r,i)=>{const s=Ct(Et),h=`calc(-0.5 * (${s} + ${Et}))`;return c.jsxs("div",{ref:d=>{$t.current[i]=d},style:{position:"relative",flex:"0 0 auto"},children:[c.jsx("button",{type:"button",className:`${e}-thumb`,"data-active":tt===i?"true":"false",onClick:()=>G&&vt==="click"&&st(i),onMouseEnter:()=>Pe&&vt==="hover"&&st(i),"aria-label":r.image.name?`View ${r.image.name}`:`View image ${i+1}`,"aria-current":tt===i?"true":void 0,children:c.jsx("img",{className:`${e}-thumb-image${xe?` ${e}-thumb-image-cover`:""}`,src:r.image.assetId,alt:"",draggable:!1,style:{...tn,maxWidth:fe,maxHeight:fe,width:bt.display==="cover"?"auto":"100%",height:"auto",objectFit:bt.display==="cover"?"cover":"contain"}})}),l&&i<o.length-1&&c.jsx("div",{"data-controls":"thumbnailGap","data-controls-axis":"x",style:{position:"absolute",top:0,right:h,width:s,height:"100%",pointerEvents:"auto",zIndex:3}})]},`thumb-${r.image.assetId}-${i}`)}),l&&c.jsx("div",{"data-controls":"thumbnailMarginBottom","data-controls-axis":"y","data-controls-reverse":l?"":void 0,style:{position:"absolute",left:0,right:0,bottom:n,height:t,pointerEvents:"auto",zIndex:3}})]})})})})()]})]})},Mt=400,_t="cubic-bezier(0.25, 0.1, 0.25, 1)",Ge=1.1,ir=`${((1-1/Ge)/2*100).toFixed(4)}%`;function sr(e){return`
|
|
2
|
+
.${e}-wrapper {
|
|
3
|
+
position: relative;
|
|
4
|
+
width: 100%;
|
|
5
|
+
height: 100%;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.${e}-cover {
|
|
9
|
+
position: relative;
|
|
10
|
+
width: 100%;
|
|
11
|
+
height: 100%;
|
|
12
|
+
cursor: pointer;
|
|
13
|
+
pointer-events: auto;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.${e}-ratio-wrapper-cover {
|
|
17
|
+
aspect-ratio: var(--image-aspect-ratio);
|
|
18
|
+
height: auto;
|
|
19
|
+
overflow: hidden;
|
|
20
|
+
width: 100%;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.${e}-ratio-wrapper-fit {
|
|
24
|
+
height: 100%;
|
|
25
|
+
width: 100%;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.${e}-cover-image {
|
|
29
|
+
display: block;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.${e}-cover-image-cover {
|
|
33
|
+
object-fit: cover;
|
|
34
|
+
width: 100%;
|
|
35
|
+
height: 100%;
|
|
36
|
+
max-width: 100%;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.${e}-cover-image-fit {
|
|
40
|
+
object-fit: contain;
|
|
41
|
+
width: auto;
|
|
42
|
+
height: auto;
|
|
43
|
+
max-width: 100%;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.${e}-hover-zoom-in .${e}-cover-image {
|
|
47
|
+
clip-path: inset(0);
|
|
48
|
+
transition: transform ${Mt}ms ${_t}, clip-path ${Mt}ms ${_t};
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.${e}-hover-scale-down .${e}-cover-image {
|
|
52
|
+
transition: transform ${Mt}ms ${_t};
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.${e}-hover-greyscale .${e}-cover-image {
|
|
56
|
+
transition: filter ${Mt}ms ${_t};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
@media (hover: hover) {
|
|
60
|
+
.${e}-hover-zoom-in .${e}-cover:hover .${e}-cover-image {
|
|
61
|
+
transform: scale(${Ge});
|
|
62
|
+
clip-path: inset(${ir});
|
|
63
|
+
}
|
|
64
|
+
.${e}-hover-scale-down .${e}-cover:hover .${e}-cover-image {
|
|
65
|
+
transform: scale(0.9);
|
|
66
|
+
}
|
|
67
|
+
.${e}-hover-greyscale .${e}-cover:hover .${e}-cover-image {
|
|
68
|
+
filter: grayscale(1);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.${e}-lightbox {
|
|
73
|
+
position: fixed;
|
|
74
|
+
inset: 0;
|
|
75
|
+
z-index: 9997;
|
|
76
|
+
display: flex;
|
|
77
|
+
flex-direction: column;
|
|
78
|
+
align-items: center;
|
|
79
|
+
justify-content: center;
|
|
80
|
+
overscroll-behavior: none;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.${e}-lightbox-editor {
|
|
84
|
+
inset: auto;
|
|
85
|
+
top: var(--cntrl-article-top, 0);
|
|
86
|
+
left: var(--cntrl-article-left, 0);
|
|
87
|
+
width: var(--cntrl-article-width, 100vw) !important;
|
|
88
|
+
height: var(--cntrl-viewport-height, 100vh) !important;
|
|
89
|
+
overflow: hidden;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.${e}-lightbox-edit-mode {
|
|
93
|
+
z-index: 1;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.${e}-lightbox-edit-mode .${e}-lightbox-strip {
|
|
97
|
+
overflow-x: hidden;
|
|
98
|
+
touch-action: none;
|
|
99
|
+
scroll-snap-type: none;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.${e}-lightbox-content {
|
|
103
|
+
position: relative;
|
|
104
|
+
z-index: 1;
|
|
105
|
+
display: flex;
|
|
106
|
+
flex-direction: column;
|
|
107
|
+
align-items: center;
|
|
108
|
+
justify-content: center;
|
|
109
|
+
width: 100%;
|
|
110
|
+
height: 100%;
|
|
111
|
+
box-sizing: border-box;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.${e}-lightbox-backdrop {
|
|
115
|
+
position: absolute;
|
|
116
|
+
inset: 0;
|
|
117
|
+
pointer-events: none;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.${e}-lightbox-dismiss-area {
|
|
121
|
+
position: relative;
|
|
122
|
+
width: 100%;
|
|
123
|
+
height: 100%;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.${e}-lightbox-strip {
|
|
127
|
+
position: relative;
|
|
128
|
+
flex: 1;
|
|
129
|
+
width: 100%;
|
|
130
|
+
min-height: 0;
|
|
131
|
+
max-width: 100%;
|
|
132
|
+
overflow-x: auto;
|
|
133
|
+
scroll-snap-type: x mandatory;
|
|
134
|
+
box-sizing: border-box;
|
|
135
|
+
touch-action: pan-x;
|
|
136
|
+
scrollbar-width: none;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.${e}-lightbox-strip-track {
|
|
140
|
+
display: flex;
|
|
141
|
+
flex-direction: row;
|
|
142
|
+
flex-wrap: nowrap;
|
|
143
|
+
align-items: center;
|
|
144
|
+
height: 100%;
|
|
145
|
+
min-width: min-content;
|
|
146
|
+
backface-visibility: hidden;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.${e}-lightbox-strip[data-mouse-dragging="true"] {
|
|
150
|
+
scroll-snap-type: none;
|
|
151
|
+
cursor: grabbing;
|
|
152
|
+
user-select: none;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.${e}-lightbox-strip[data-mouse-draggable="true"] {
|
|
156
|
+
cursor: grab;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
.${e}-lightbox-strip::-webkit-scrollbar {
|
|
160
|
+
display: none;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
.${e}-strip-item {
|
|
164
|
+
position: relative;
|
|
165
|
+
flex: 0 0 auto;
|
|
166
|
+
height: 100%;
|
|
167
|
+
scroll-snap-align: start;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.${e}-strip-item img {
|
|
171
|
+
user-select: none;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.${e}-thumbnails-wrap {
|
|
175
|
+
position: absolute;
|
|
176
|
+
left: 16px;
|
|
177
|
+
right: 16px;
|
|
178
|
+
z-index: 2;
|
|
179
|
+
pointer-events: auto;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
.${e}-thumbnails {
|
|
183
|
+
width: 100%;
|
|
184
|
+
overflow-x: auto;
|
|
185
|
+
scrollbar-width: none;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.${e}-thumbnails-track {
|
|
189
|
+
display: flex;
|
|
190
|
+
flex-direction: row;
|
|
191
|
+
flex-wrap: nowrap;
|
|
192
|
+
align-items: flex-end;
|
|
193
|
+
justify-content: center;
|
|
194
|
+
width: max-content;
|
|
195
|
+
min-width: 100%;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
.${e}-lightbox-editor.${e}-lightbox-edit-mode .${e}-thumbnails {
|
|
199
|
+
overflow: visible;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
.${e}-thumbnails::-webkit-scrollbar {
|
|
203
|
+
display: none;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
.${e}-thumb {
|
|
207
|
+
flex: 0 0 auto;
|
|
208
|
+
display: flex;
|
|
209
|
+
align-items: center;
|
|
210
|
+
justify-content: center;
|
|
211
|
+
padding: 0;
|
|
212
|
+
border: none;
|
|
213
|
+
background: transparent;
|
|
214
|
+
cursor: pointer;
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
.${e}-thumbnails-track[data-thumbnail-active="outline"] .${e}-thumb .${e}-thumb-image {
|
|
218
|
+
box-sizing: border-box;
|
|
219
|
+
border: 2px solid transparent;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
.${e}-thumbnails-track[data-thumbnail-active="outline"] .${e}-thumb[data-active="true"] .${e}-thumb-image {
|
|
223
|
+
border-color: var(--thumbnail-active-color, #ffffff);
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
.${e}-thumbnails-track[data-thumbnail-active="color"] .${e}-thumb:not([data-active="true"]) .${e}-thumb-image {
|
|
227
|
+
filter: grayscale(1);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.${e}-thumbnails-track[data-thumbnail-active="scale-up"] .${e}-thumb[data-active="true"] {
|
|
231
|
+
transform: scale(1.15);
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
.${e}-thumb-image {
|
|
235
|
+
display: block;
|
|
236
|
+
object-fit: contain;
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
.${e}-thumb-image-cover {
|
|
240
|
+
aspect-ratio: var(--image-aspect-ratio);
|
|
241
|
+
width: auto;
|
|
242
|
+
height: auto;
|
|
243
|
+
object-fit: cover;
|
|
244
|
+
}
|
|
245
|
+
.${e}-close-icon {
|
|
246
|
+
position: relative;
|
|
247
|
+
flex-shrink: 0;
|
|
248
|
+
grid-area: close;
|
|
249
|
+
pointer-events: auto;
|
|
250
|
+
z-index: 2;
|
|
251
|
+
display: flex;
|
|
252
|
+
align-items: center;
|
|
253
|
+
justify-content: center;
|
|
254
|
+
border: none;
|
|
255
|
+
background-color: transparent;
|
|
256
|
+
padding: 0;
|
|
257
|
+
opacity: 1;
|
|
258
|
+
transition: opacity ${xt}ms ease;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
.${e}-close-icon[data-overlay-content-hidden="true"] {
|
|
262
|
+
opacity: 0;
|
|
263
|
+
pointer-events: none;
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
.${e}-close-icon-inner {
|
|
267
|
+
all: unset;
|
|
268
|
+
position: relative;
|
|
269
|
+
cursor: pointer;
|
|
270
|
+
width: 100%;
|
|
271
|
+
height: 100%;
|
|
272
|
+
pointer-events: auto;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
.${e}-close-icon-img {
|
|
276
|
+
position: absolute;
|
|
277
|
+
top: 50%;
|
|
278
|
+
left: 50%;
|
|
279
|
+
transform: translate(-50%, -50%);
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
.${e}-header {
|
|
283
|
+
position: relative;
|
|
284
|
+
display: grid;
|
|
285
|
+
flex: 1;
|
|
286
|
+
width: 100%;
|
|
287
|
+
min-width: 0;
|
|
288
|
+
z-index: 2;
|
|
289
|
+
box-sizing: border-box;
|
|
290
|
+
pointer-events: none;
|
|
291
|
+
word-break: break-word;
|
|
292
|
+
align-items: center;
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
.${e}-header-single-row {
|
|
296
|
+
grid-template-columns: auto auto auto auto 1fr auto;
|
|
297
|
+
grid-template-areas: "margin title1 title2 title3 . close";
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
.${e}-header-two-row {
|
|
301
|
+
height: 100%;
|
|
302
|
+
align-self: stretch;
|
|
303
|
+
display: flex;
|
|
304
|
+
flex-direction: column;
|
|
305
|
+
width: 100%;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
.${e}-header-row-top {
|
|
309
|
+
display: flex;
|
|
310
|
+
flex-direction: row;
|
|
311
|
+
align-items: center;
|
|
312
|
+
width: 100%;
|
|
313
|
+
flex-shrink: 0;
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
.${e}-header-row-top .${e}-title-cell[data-title="title1"] {
|
|
317
|
+
flex: 0 0 auto;
|
|
318
|
+
min-width: 0;
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
.${e}-header-row-top .${e}-close-icon {
|
|
322
|
+
flex-shrink: 0;
|
|
323
|
+
margin-left: auto;
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
.${e}-header-row-bottom-wrap {
|
|
327
|
+
display: flex;
|
|
328
|
+
flex-direction: column;
|
|
329
|
+
width: 100%;
|
|
330
|
+
margin-top: auto;
|
|
331
|
+
flex-shrink: 0;
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
.${e}-header-row-bottom {
|
|
335
|
+
position: relative;
|
|
336
|
+
display: flex;
|
|
337
|
+
flex-direction: row;
|
|
338
|
+
align-items: flex-end;
|
|
339
|
+
width: 100%;
|
|
340
|
+
}
|
|
341
|
+
|
|
342
|
+
.${e}-header-row-bottom .${e}-title-cell {
|
|
343
|
+
flex: 0 0 auto;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
.${e}-title-cell {
|
|
347
|
+
position: relative;
|
|
348
|
+
flex: 0 0 auto;
|
|
349
|
+
min-width: 0;
|
|
350
|
+
box-sizing: border-box;
|
|
351
|
+
}
|
|
352
|
+
.${e}-title1,
|
|
353
|
+
.${e}-title2,
|
|
354
|
+
.${e}-title3 {
|
|
355
|
+
margin: 0;
|
|
356
|
+
min-width: 0;
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
.${e}-title-resize-handle {
|
|
360
|
+
background: transparent;
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
.${e}-lightbox-content-inner {
|
|
364
|
+
position: absolute;
|
|
365
|
+
inset: 0;
|
|
366
|
+
z-index: 2;
|
|
367
|
+
pointer-events: none;
|
|
368
|
+
display: flex;
|
|
369
|
+
flex-direction: column;
|
|
370
|
+
opacity: 1;
|
|
371
|
+
transition: opacity ${xt}ms ease;
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
.${e}-lightbox-content-inner[data-overlay-content-hidden="true"] {
|
|
375
|
+
opacity: 0;
|
|
376
|
+
pointer-events: none;
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
.${e}-lightbox-content-area {
|
|
380
|
+
position: relative;
|
|
381
|
+
display: flex;
|
|
382
|
+
flex-direction: row;
|
|
383
|
+
flex: 1;
|
|
384
|
+
min-width: 0;
|
|
385
|
+
min-height: 0;
|
|
386
|
+
align-items: flex-start;
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
.${e}-lightbox-content-area-stacked {
|
|
390
|
+
align-items: stretch;
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
.${e}-control {
|
|
394
|
+
position: relative;
|
|
395
|
+
z-index: 2;
|
|
396
|
+
pointer-events: auto;
|
|
397
|
+
flex-shrink: 0;
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
.${e}-control::before {
|
|
401
|
+
content: "";
|
|
402
|
+
position: absolute;
|
|
403
|
+
top: 0;
|
|
404
|
+
left: 0;
|
|
405
|
+
width: 100%;
|
|
406
|
+
height: 100%;
|
|
407
|
+
min-width: 20px;
|
|
408
|
+
min-height: 20px;
|
|
409
|
+
pointer-events: auto;
|
|
410
|
+
z-index: 10;
|
|
411
|
+
}
|
|
412
|
+
`}const lr=({settings:e,content:o,isEditor:u,isEditMode:f,isPreviewMode:l,portalId:m})=>{const{prefix:p}=En.useScopedStyles(),{cover:w,coverFit:R,hover:N="none"}=e,M=N!=="none"&&(!u||l)?` ${p}-hover-${N}`:"",J=a.useRef(null),[I,O]=a.useState(!1),A=o??[],Q=I&&A.length>0,vt=()=>{A.length!==0&&O(!0)};return a.useEffect(()=>{!u||f||l||O(!1)},[u,f,l]),c.jsxs(c.Fragment,{children:[c.jsxs("div",{ref:J,className:`${p}-wrapper${M}`,children:[c.jsx("style",{dangerouslySetInnerHTML:{__html:sr(p)}}),w&&c.jsx("div",{className:`${p}-cover ${Z.isImageRatioCover(R)?`${p}-ratio-wrapper-cover`:`${p}-ratio-wrapper-fit`}`,onClick:()=>vt(),style:{...Z.isImageRatioCover(R)?{"--image-aspect-ratio":Z.getAspectRatio(R)}:{}},"aria-label":"Open image gallery",children:c.jsx("img",{className:`${p}-cover-image ${Z.isImageRatioCover(R)?`${p}-cover-image-cover`:`${p}-cover-image-fit`}`,src:w,alt:"cover"})})]}),Q&&typeof document<"u"&&(()=>{const ct=(m?document.getElementById(m):null)??document.body;return kn.createPortal(c.jsx(or,{prefix:p,images:A,settings:e,isEditor:u,isEditMode:f,isPreviewMode:l,onClose:()=>O(!1)}),ct)})()]})};exports.LightboxStrip=lr;exports.STRIP_TEXT_STYLE_PREFIXES=Fe;exports.STRIP_TEXT_STYLE_TAB_LABELS=Ke;exports.createStripTextStylePanelTab=er;exports.createStripTextStyleTabContentItems=He;exports.extractTitlesFromLegacyText=Be;exports.getStripTextStyleSettingKey=E;exports.resolveStripItemTitles=De;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const r=require("./ControlSlider-C8ckUIDm.js"),n=require("./ImageRevealSlider-DlxudBUy.js"),p=require("./Lightbox-DZckgBzK.js"),e=require("./ChroniclesComponent-Os_r2IYg.js"),t={element:r.ControlSlider,id:"control-slider",name:"Slider",preview:{type:"image",url:"https://cdn.cntrl.site/component-assets/Slider.mp4"},defaultSize:{d:{width:400,height:400},t:{width:400,height:400},m:{width:300,height:300}},assetsPaths:{content:[{path:"image.assetId",placeholderEnabled:!0}],parameters:[{path:"settings.controls.arrowsImgUrl"}]},fontSettingsPaths:{content:[],parameters:[{path:"styles.imageCaption.fontSettings"}]},schema:{type:"object",properties:{settings:{type:"object",display:{type:"settings-block"},properties:{triggers:{title:"triggers",icon:"target",tooltip:"Triggers",type:"object",properties:{triggersList:{type:"object",display:{type:"toggle-ratio-group"},properties:{click:{type:"boolean"},drag:{type:"boolean"}}},autoPlay:{type:["string","null"],label:"Auto",display:{type:"step-selector"},enum:[null,"1s","2s","3s","4s","5s"]}}},direction:{icon:"horizontal-resize",tooltip:"Direction",type:"string",display:{type:"ratio-group"},enum:["horiz","vert"]},transition:{title:"transit",icon:"transition",tooltip:"Transition",type:"object",properties:{type:{type:"string",display:{type:"ratio-group"},enum:["slide","fade in"]},backgroundColor:{type:["string","null"],title:"BG Color",display:{visible:!1,type:"settings-color-picker",format:"single"}},duration:{type:"string",label:"icon:hourglass",display:{type:"step-selector"},enum:["100ms","250ms","500ms","1000ms","1500ms","2000ms"]}}},controls:{title:"controls",icon:"controls",tooltip:"Controls",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},arrowsImgUrl:{type:["string","null"],display:{type:"settings-image-input"}},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},scale:{type:"number",title:"scale",min:50,max:600,display:{type:"range-control"}},color:{title:"color",type:"string",display:{type:"settings-color-picker",format:"single"}},hover:{title:"hover",type:"string",display:{type:"settings-color-picker",format:"single"}},show:{title:"Show",type:"string",display:{type:"ratio-group"},enum:["always","on hover"]}}},pagination:{title:"nav",icon:"pagination",tooltip:"Navigation",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},position:{display:{type:"socket",direction:"horizontal"},type:"string",enum:["outside-1","outside-2","inside-1","inside-2"]},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},scale:{type:"number",title:"scale",min:10,max:400,display:{type:"range-control"}},colors:{display:{type:"settings-color-picker",format:"multiple"},title:"color",type:"array",items:{type:"string"}},hover:{title:"hover",type:"string",display:{type:"settings-color-picker",format:"single"}}}},imageCaption:{title:"Caption",icon:"text-icon",tooltip:"Caption",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},alignment:{type:"string",display:{type:"align-grid"},enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},linkColor:{title:"Link",type:"string",display:{type:"settings-color-picker",format:"single"}},linkHoverColor:{title:"Link Hov",type:"string",display:{type:"settings-color-picker",format:"single"}}}}},default:{triggers:{triggersList:{click:!1,drag:!0},autoPlay:null},controls:{isActive:!0,arrowsImgUrl:null,offset:{x:0,y:0},scale:100,color:"#000000",hover:"#cccccc",show:"always"},transition:{type:"slide",duration:"500ms",backgroundColor:null},pagination:{isActive:!0,scale:50,position:"inside-1",offset:{x:0,y:0},colors:["#cccccc","#cccccc","#000000"],hover:"#cccccc"},direction:"horiz",imageCaption:{offset:{x:0,y:0},isActive:!0,alignment:"middle-center",linkColor:"#cccccc",linkHoverColor:"#cccccc"}},displayRules:[{if:{name:"direction",value:"vert"},then:{name:"properties.pagination.properties.position.display.direction",value:"vertical"}},{if:{name:"transition.type",value:"fade in"},then:{name:"properties.transition.properties.backgroundColor.display.visible",value:!0}}]},content:{type:"array",settings:{addItemFromFileExplorer:!0},items:{type:"object",properties:{image:{type:"object",label:"Image",display:{type:"media-input"},properties:{assetId:{type:"string"},name:{type:"string"},objectFit:{type:"string",enum:["cover","contain"]}},required:["assetId","name"]},imageCaption:{placeholder:"Add Caption...",label:"Description",display:{type:"rich-text"}}},required:["image"]},default:[{image:{objectFit:"cover",assetId:"01M3QM74XES6E7GVC0H3KJ2RH6",name:"Slider-1.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]},{image:{objectFit:"cover",assetId:"01M3QM74XEAZ8H1DTC5V1S554K",name:"Slider-2.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]},{image:{objectFit:"cover",assetId:"01M3QM74XEDRP49HNTEPNZYQTP",name:"Slider-3.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]}]},styles:{type:"object",properties:{imageCaption:{dataName:"caption",type:"object",properties:{fontSettings:{type:"object",display:{type:"font-settings"},properties:{fontFamily:{type:"string"},fontWeight:{type:"number"},fontStyle:{type:"string"}}},widthSettings:{display:{type:"text-width-control"},type:"object",properties:{width:{type:"number"},sizing:{type:"string",enum:["auto","manual"]}}},fontSizeLineHeight:{type:"object",display:{type:"font-size-line-height"},properties:{fontSize:{type:"number"},lineHeight:{type:"number"}}},letterSpacing:{display:{type:"letter-spacing-input"},type:"number"},wordSpacing:{display:{type:"word-spacing-input"},type:"number"},textAlign:{display:{type:"text-align-control"},type:"string",enum:["left","center","right","justify"]},textAppearance:{display:{type:"text-appearance"},properties:{textTransform:{type:"string",enum:["none","uppercase","lowercase","capitalize"]},textDecoration:{type:"string",enum:["none","underline"]},fontVariant:{type:"string",enum:["normal","small-caps"]}}},color:{display:{type:"style-panel-color-picker"},type:"string"}}}},default:{imageCaption:{widthSettings:{width:.13,sizing:"auto"},fontSettings:{fontFamily:"Arial",fontWeight:400,fontStyle:"normal"},fontSizeLineHeight:{fontSize:.02,lineHeight:.02},letterSpacing:0,wordSpacing:0,textAlign:"left",textAppearance:{textTransform:"none",textDecoration:"none",fontVariant:"normal"},color:"#000000"}}}},required:["settings","content","styles"]}},i={element:n.ImageRevealSlider,id:"control-image-reveal",name:"Click Gallery",preview:{type:"image",url:"https://cdn.cntrl.site/component-assets/Click_Gallery.mp4"},defaultSize:{d:{width:"100%",height:"100%"},t:{width:"100%",height:"100%"},m:{width:"100%",height:"100%"}},assetsPaths:{content:[{path:"image.assetId",placeholderEnabled:!0}],parameters:[{path:"settings.cursor.defaultCursor"},{path:"settings.cursor.hoverCursor"}]},fontSettingsPaths:{content:[],parameters:[]},schema:{type:"object",properties:{settings:{type:"object",display:{type:"settings-block"},properties:{imageSize:{title:"IMG SIZE",icon:"size",tooltip:"IMG SIZE",type:"object",properties:{sizeType:{type:"string",display:{type:"ratio-group"},enum:["as Is","custom","random"]},imageWidth:{type:"number",label:"W",display:{type:"numeric-input",visible:!1}},randomRangeImageWidth:{type:"object",display:{type:"random-range-controls",visible:!1},properties:{min:{type:"number"},max:{type:"number"}}}}},cursor:{title:"cursor",icon:"cursor",tooltip:"cursor",type:"object",properties:{cursorType:{type:"string",display:{type:"ratio-group"},enum:["system","custom"]},target:{type:"string",title:"Target",display:{type:"ratio-group"},enum:["area","image"]},defaultCursor:{type:["string","null"],title:"Default",display:{type:"settings-image-input",visible:!1}},defaultCursorScale:{type:"number",title:"Scale",min:1,max:5,step:.1,display:{type:"range-control",visible:!1}},hoverCursor:{type:["string","null"],title:"Hover",display:{type:"settings-image-input",visible:!1}},hoverCursorScale:{type:"number",title:"Scale",min:1,max:5,step:.1,display:{type:"range-control",visible:!1}}}},position:{title:"position",icon:"transition",tooltip:"Position",type:"object",properties:{revealPosition:{type:"string",display:{type:"ratio-group"},enum:["random","same","on Click"]},visible:{type:"string",title:"Visible",display:{type:"ratio-group"},enum:["all","last One"]}}}},default:{imageSize:{sizeType:"custom",imageWidth:500,randomRangeImageWidth:{min:100,max:1e3}},cursor:{cursorType:"system",target:"area",defaultCursor:null,defaultCursorScale:2,hoverCursor:null,hoverCursorScale:2},position:{revealPosition:"random",visible:"all"}},displayRules:[{if:{name:"imageSize.sizeType",value:"custom"},then:{name:"properties.imageSize.properties.imageWidth.display.visible",value:!0}},{if:{name:"imageSize.sizeType",value:"random"},then:{name:"properties.imageSize.properties.randomRangeImageWidth.display.visible",value:!0}},{if:[{name:"cursor.target",value:"image"},{name:"cursor.cursorType",value:"custom"}],then:{name:"properties.cursor.properties.defaultCursor.display.visible",value:!0}},{if:[{name:"cursor.target",value:"image"},{name:"cursor.cursorType",value:"custom"},{name:"cursor.defaultCursor",value:null,isNotEqual:!0}],then:{name:"properties.cursor.properties.defaultCursorScale.display.visible",value:!0}},{if:{name:"cursor.cursorType",value:"custom"},then:{name:"properties.cursor.properties.hoverCursor.display.visible",value:!0}},{if:[{name:"cursor.cursorType",value:"custom"},{name:"cursor.hoverCursor",value:null,isNotEqual:!0}],then:{name:"properties.cursor.properties.hoverCursorScale.display.visible",value:!0}}]},content:{type:"array",settings:{addItemFromFileExplorer:!0},items:{type:"object",properties:{image:{type:"object",label:"Image",display:{isObjectFitEditable:!1,type:"media-input"},properties:{assetId:{type:"string"},name:{type:"string"},objectFit:{type:"string",enum:["cover","contain"]}},required:["assetId","name"]},link:{type:"object",label:"URL",display:{type:"link-input"}}},required:["image"]},default:[{image:{objectFit:"cover",assetId:"01M3QM74XGWBJY3AQQ71GC2Z6Q",name:"Slider-1.png"},link:{type:"url",value:"",target:"blank"}},{image:{objectFit:"cover",assetId:"01M3QM74XGMXS1Z5ZY2RFGS3T4",name:"Slider-2.png"},link:{type:"url",value:"",target:"blank"}},{image:{objectFit:"cover",assetId:"01M3QM74XGWG6VCHNEXKVKAJGT",name:"Slider-3.png"},link:{type:"url",value:"",target:"blank"}},{image:{objectFit:"cover",assetId:"01M3QM74XGCVMTPNHFHMR98RPZ",name:"Slider-4.png"},link:{type:"url",value:"",target:"blank"}}]}}}},o={element:p.LightboxGallery,id:"lightbox",name:"Lightbox",preview:{type:"image",url:"https://cdn.cntrl.site/component-assets/Lightbox.png"},defaultSize:{d:{width:440,height:550},t:{width:235,height:293},m:{width:265,height:331}},fontSettingsPaths:{content:[],parameters:[{path:"styles.imageCaption.fontSettings"}]},assetsPaths:{content:[{path:"image.assetId",placeholderEnabled:!0}],parameters:[{path:"settings.thumbnailBlock.cover.assetId",placeholderEnabled:!0},{path:"settings.controls.arrowsImgUrl"},{path:"settings.area.closeIconUrl"}]},schema:{type:"object",properties:{settings:{type:"object",properties:{thumbnailBlock:{display:{type:"settings-block",triggerEvent:"close"},type:"object",properties:{cover:{title:"COVER",icon:"cover",tooltip:"Cover Image",type:"object",properties:{assetId:{type:"string",display:{type:"cover-image-input"}}}}}},lightboxBlock:{display:{type:"settings-block",triggerEvent:"open"},type:"object",properties:{appear:{title:"APPEAR",icon:"transition",tooltip:"Appearance",type:"object",properties:{type:{type:"string",display:{type:"ratio-group"},enum:["slide in","fade in","mix"]},duration:{type:"string",label:"T",display:{type:"step-selector"},enum:["100ms","250ms","500ms","1000ms","1500ms","2000ms"]},direction:{type:"string",title:"From",display:{type:"direction-control"},enum:["top","left","right","bottom"]}}},triggers:{title:"TRIGGERS",icon:"target",tooltip:"Triggers",type:"object",properties:{type:{type:"string",display:{type:"ratio-group"},enum:["click","drag"]},switch:{type:"string",display:{type:"ratio-group"},enum:["image","50/50"]},repeat:{type:"string",title:"Repeat",display:{visible:!1,type:"ratio-group"},enum:["close","loop"]}}},slider:{title:"SLIDER",icon:"horizontal-resize",tooltip:"Slider",type:"object",properties:{type:{type:"string",display:{type:"ratio-group"},enum:["slide","fade","scale"]},direction:{type:"string",display:{type:"ratio-group"},enum:["horiz","vert"]},duration:{type:"string",label:"T",display:{type:"step-selector"},enum:["100ms","250ms","500ms","1000ms","1500ms","2000ms"]}}},thumbnail:{title:"THUMB",icon:"thumbnail",tooltip:"Thumbnail",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},position:{display:{type:"align-grid"},type:"string",enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},fit:{type:"string",display:{type:"ratio-group"},enum:["cover","fit"]},align:{type:"string",title:"Align",display:{type:"align-group",direction:"horizontal"},enum:["start","center","end"]},triggers:{type:"string",title:"Triggers",display:{type:"ratio-group",direction:"horizontal"},enum:["clk","hov"]},grid:{type:"object",title:"Grid",display:{type:"group"},properties:{size:{type:"number",label:"Box",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},gap:{type:"number",label:"Gap",scalingEnabled:!0,min:0,display:{type:"numeric-input"}}}},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},opacity:{type:"number",title:"Opacity",label:"icon:opacity",min:0,max:100,step:1,display:{type:"numeric-input"}},activeState:{type:"object",title:"ACTIVE",display:{type:"group"},properties:{scale:{type:"number",title:"Scale",min:1,max:5,step:.1,display:{type:"range-control"}},opacity:{type:"number",title:"Opacity",label:"icon:opacity",min:0,max:100,step:1,display:{type:"numeric-input"}}}}}},layout:{title:"LAYOUT",icon:"layout",tooltip:"Layout",type:"object",properties:{position:{display:{type:"align-grid"},type:"string",enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},padding:{type:"object",title:"Padding",display:{type:"padding-controls"},properties:{top:{min:0,step:1,type:"number"},left:{min:0,step:1,type:"number"},right:{min:0,step:1,type:"number"},bottom:{min:0,step:1,type:"number"}}}}},controls:{title:"CONTROLS",icon:"controls",tooltip:"Controls",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},arrowsImgUrl:{type:["string","null"],display:{type:"settings-image-input"}},offset:{title:"Offset",type:"object",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},scale:{type:"number",title:"Scale",min:.5,max:5,step:.1,display:{type:"range-control"}},color:{title:"Color",type:"string",display:{type:"settings-color-picker",format:"single"}},hover:{title:"Hover",type:"string",display:{type:"settings-color-picker",format:"single"}}}},area:{title:"AREA",icon:"area",tooltip:"Area",type:"object",properties:{color:{type:"string",display:{type:"settings-color-picker",format:"single"}},blur:{type:"number",label:"icon:blur",display:{type:"numeric-input"}},closeIconUrl:{type:["string","null"],title:"Close Icon",display:{type:"settings-image-input"}},closeIconAlign:{display:{type:"align-grid",direction:"horizontal"},type:"string",enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},closeIconScale:{type:"number",title:"Scale",min:.5,max:5,step:.1,display:{type:"range-control"}},closeIconOffset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},closeIconColor:{title:"Color",type:"string",display:{type:"settings-color-picker",format:"single"}},closeIconHover:{title:"Hover",type:"string",display:{type:"settings-color-picker",format:"single"}}}},caption:{title:"DESC",icon:"text-icon",tooltip:"Description",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},alignment:{type:"string",display:{type:"align-grid"},enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},offset:{title:"Offset",type:"object",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},linkColor:{title:"Link",type:"string",display:{type:"settings-color-picker",format:"single"}},linkHoverColor:{title:"Link Hov",type:"string",display:{type:"settings-color-picker",format:"single"}}}}}}},default:{d:{thumbnailBlock:{cover:{assetId:"01M3QM74XEQ5ZGJ9WAMKV0EY1V"}},lightboxBlock:{appear:{type:"slide in",duration:"1000ms",direction:"bottom"},triggers:{type:"click",switch:"image",repeat:"loop"},slider:{type:"slide",direction:"vert",duration:"1000ms"},thumbnail:{isActive:!0,position:"middle-left",fit:"fit",align:"start",triggers:"hov",grid:{size:.05,gap:.01},offset:{x:.01,y:0},opacity:50,activeState:{scale:1,opacity:100}},layout:{position:"middle-center",offset:{x:0,y:0},padding:{top:.06,right:0,bottom:.06,left:0}},controls:{isActive:!1,arrowsImgUrl:null,offset:{x:0,y:0},scale:1,color:"#000000",hover:"#cccccc"},area:{color:"rgba(28,31,34,0.9)",blur:0,closeIconUrl:null,closeIconColor:"#000000",closeIconHover:"#cccccc",closeIconAlign:"top-right",closeIconOffset:{x:0,y:0},closeIconScale:1},caption:{isActive:!0,alignment:"middle-center",offset:{x:0,y:0},linkColor:"#cccccc",linkHoverColor:"#cccccc"}}},m:{thumbnailBlock:{cover:{assetId:"01M3QM74XEQ5ZGJ9WAMKV0EY1V"}},lightboxBlock:{appear:{type:"fade in",duration:"500ms",direction:"bottom"},triggers:{type:"click",switch:"image",repeat:"loop"},slider:{type:"slide",direction:"horiz",duration:"1000ms"},thumbnail:{isActive:!0,position:"bottom-center",fit:"fit",align:"start",triggers:"hov",grid:{size:.1,gap:.05},offset:{x:.01,y:-.05},opacity:50,activeState:{scale:1,opacity:100}},layout:{position:"middle-center",offset:{x:0,y:0},padding:{top:.06,right:.05,bottom:.06,left:.05}},controls:{isActive:!1,arrowsImgUrl:null,offset:{x:0,y:0},scale:1,color:"#000000",hover:"#cccccc"},area:{color:"rgba(28,31,34,0.9)",blur:0,closeIconUrl:null,closeIconColor:"#000000",closeIconHover:"#cccccc",closeIconAlign:"top-right",closeIconOffset:{x:0,y:0},closeIconScale:1},caption:{isActive:!0,alignment:"middle-center",offset:{x:0,y:0},hover:"#cccccc"}}},t:{thumbnailBlock:{cover:{assetId:"01M3QM74XEQ5ZGJ9WAMKV0EY1V"}},lightboxBlock:{appear:{type:"fade in",duration:"500ms",direction:"bottom"},triggers:{type:"click",switch:"image",repeat:"loop"},slider:{type:"slide",direction:"vert",duration:"1000ms"},thumbnail:{isActive:!0,position:"middle-left",fit:"fit",align:"start",triggers:"hov",grid:{size:.05,gap:.01},offset:{x:.03,y:0},opacity:50,activeState:{scale:1,opacity:100}},layout:{position:"middle-center",offset:{x:0,y:0},padding:{top:.06,right:.1,bottom:.06,left:.1}},controls:{isActive:!1,arrowsImgUrl:null,offset:{x:0,y:0},scale:1,color:"#000000",hover:"#cccccc"},area:{color:"rgba(28,31,34,0.9)",blur:0,closeIconUrl:null,closeIconColor:"#000000",closeIconHover:"#cccccc",closeIconAlign:"top-right",closeIconOffset:{x:0,y:0},closeIconScale:1},caption:{isActive:!0,alignment:"middle-center",offset:{x:0,y:0},hover:"#cccccc"}}}},displayRules:[{if:{name:"lightboxBlock.appear.type",value:"slide in"},then:{name:"properties.lightboxBlock.properties.appear.properties.direction.display.visible",value:!0}},{if:{name:"lightboxBlock.slider.direction",value:"vert"},then:{name:"properties.lightboxBlock.properties.thumbnail.properties.align.display.direction",value:"vertical"}},{if:{name:"lightboxBlock.appear.type",value:"mix"},then:{name:"properties.lightboxBlock.properties.appear.properties.direction.display.visible",value:!0}},{if:{name:"lightboxBlock.appear.type",value:"fade in"},then:{name:"properties.lightboxBlock.properties.appear.properties.direction.display.visible",value:!1}},{if:[{name:"lightboxBlock.triggers.type",value:"click"},{name:"lightboxBlock.triggers.switch",value:"image"}],then:{name:"properties.lightboxBlock.properties.triggers.properties.repeat.display.visible",value:!0}}]},content:{type:"array",settings:{addItemFromFileExplorer:!0},items:{type:"object",properties:{image:{type:"object",label:"Image",display:{type:"media-input"},properties:{assetId:{type:"string"},name:{type:"string"},objectFit:{type:"string",enum:["cover","contain"]}},required:["assetId","name"]},imageCaption:{label:"Description",placeholder:"Add Caption...",display:{type:"rich-text"}}},required:["image"]},default:[{image:{objectFit:"contain",assetId:"01M3QM74XD4J8X0B8TTSQ8CV3P",name:"Slider-1.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]},{image:{objectFit:"contain",assetId:"01M3QM74XD0N6VQJ5J8J9YB32N",name:"Slider-2.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]},{image:{objectFit:"contain",assetId:"01M3QM74XE4WSEPVF1QQSKMD76",name:"Slider-3.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]}]},styles:{type:"object",properties:{imageCaption:{dataName:"caption",type:"object",properties:{fontSettings:{type:"object",display:{type:"font-settings"},properties:{fontFamily:{type:"string"},fontWeight:{type:"number"},fontStyle:{type:"string"}}},widthSettings:{display:{type:"text-width-control"},type:"object",properties:{width:{type:"number"},sizing:{type:"string",enum:["auto","manual"]}}},fontSizeLineHeight:{type:"object",display:{type:"font-size-line-height"},properties:{fontSize:{type:"number"},lineHeight:{type:"number"}}},letterSpacing:{display:{type:"letter-spacing-input"},type:"number"},wordSpacing:{display:{type:"word-spacing-input"},type:"number"},textAlign:{display:{type:"text-align-control"},type:"string",enum:["left","center","right","justify"]},textAppearance:{display:{type:"text-appearance"},properties:{textTransform:{type:"string",enum:["none","uppercase","lowercase","capitalize"]},textDecoration:{type:"string",enum:["none","underline"]},fontVariant:{type:"string",enum:["normal","small-caps"]}}},color:{display:{type:"style-panel-color-picker"},type:"string"}}}},default:{imageCaption:{widthSettings:{width:.13,sizing:"auto"},fontSettings:{fontFamily:"Arial",fontWeight:400,fontStyle:"normal"},fontSizeLineHeight:{fontSize:.02,lineHeight:.02},letterSpacing:0,wordSpacing:0,textAlign:"left",textAppearance:{textTransform:"none",textDecoration:"none",fontVariant:"normal"},color:"#000000"}}}},required:["settings","content","styles"]}},l=[t,i,e.ClickGallerieComponent,o,e.FormComponent,e.OnelinerFormComponent,e.MarqueeComponent,e.MarqueeTextComponent,e.TestimonialGridComponent,e.TestimonialSingleComponent,e.GridComponent,e.HiveComponent,e.ListComponent,e.FAQComponent,e.LightboxStripComponent,e.LightboxJournalComponent,e.ScaleComponent,e.WaterfallComponent,e.SimpleButtonComponent,e.Slider20Component,e.MercuryComponent,e.HelixComponent,e.BurgerComponent,e.PretextComponent,e.ChroniclesComponent];exports.ControlImageRevealSliderComponent=i;exports.ControlSliderComponent=t;exports.LightboxComponent=o;exports.components=l;
|
|
1
|
+
"use strict";const r=require("./ControlSlider-C8ckUIDm.js"),n=require("./ImageRevealSlider-DlxudBUy.js"),p=require("./Lightbox-DZckgBzK.js"),e=require("./ChroniclesComponent-D4_6w8f7.js"),t={element:r.ControlSlider,id:"control-slider",name:"Slider",preview:{type:"image",url:"https://cdn.cntrl.site/component-assets/Slider.mp4"},defaultSize:{d:{width:400,height:400},t:{width:400,height:400},m:{width:300,height:300}},assetsPaths:{content:[{path:"image.assetId",placeholderEnabled:!0}],parameters:[{path:"settings.controls.arrowsImgUrl"}]},fontSettingsPaths:{content:[],parameters:[{path:"styles.imageCaption.fontSettings"}]},schema:{type:"object",properties:{settings:{type:"object",display:{type:"settings-block"},properties:{triggers:{title:"triggers",icon:"target",tooltip:"Triggers",type:"object",properties:{triggersList:{type:"object",display:{type:"toggle-ratio-group"},properties:{click:{type:"boolean"},drag:{type:"boolean"}}},autoPlay:{type:["string","null"],label:"Auto",display:{type:"step-selector"},enum:[null,"1s","2s","3s","4s","5s"]}}},direction:{icon:"horizontal-resize",tooltip:"Direction",type:"string",display:{type:"ratio-group"},enum:["horiz","vert"]},transition:{title:"transit",icon:"transition",tooltip:"Transition",type:"object",properties:{type:{type:"string",display:{type:"ratio-group"},enum:["slide","fade in"]},backgroundColor:{type:["string","null"],title:"BG Color",display:{visible:!1,type:"settings-color-picker",format:"single"}},duration:{type:"string",label:"icon:hourglass",display:{type:"step-selector"},enum:["100ms","250ms","500ms","1000ms","1500ms","2000ms"]}}},controls:{title:"controls",icon:"controls",tooltip:"Controls",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},arrowsImgUrl:{type:["string","null"],display:{type:"settings-image-input"}},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},scale:{type:"number",title:"scale",min:50,max:600,display:{type:"range-control"}},color:{title:"color",type:"string",display:{type:"settings-color-picker",format:"single"}},hover:{title:"hover",type:"string",display:{type:"settings-color-picker",format:"single"}},show:{title:"Show",type:"string",display:{type:"ratio-group"},enum:["always","on hover"]}}},pagination:{title:"nav",icon:"pagination",tooltip:"Navigation",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},position:{display:{type:"socket",direction:"horizontal"},type:"string",enum:["outside-1","outside-2","inside-1","inside-2"]},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},scale:{type:"number",title:"scale",min:10,max:400,display:{type:"range-control"}},colors:{display:{type:"settings-color-picker",format:"multiple"},title:"color",type:"array",items:{type:"string"}},hover:{title:"hover",type:"string",display:{type:"settings-color-picker",format:"single"}}}},imageCaption:{title:"Caption",icon:"text-icon",tooltip:"Caption",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},alignment:{type:"string",display:{type:"align-grid"},enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},linkColor:{title:"Link",type:"string",display:{type:"settings-color-picker",format:"single"}},linkHoverColor:{title:"Link Hov",type:"string",display:{type:"settings-color-picker",format:"single"}}}}},default:{triggers:{triggersList:{click:!1,drag:!0},autoPlay:null},controls:{isActive:!0,arrowsImgUrl:null,offset:{x:0,y:0},scale:100,color:"#000000",hover:"#cccccc",show:"always"},transition:{type:"slide",duration:"500ms",backgroundColor:null},pagination:{isActive:!0,scale:50,position:"inside-1",offset:{x:0,y:0},colors:["#cccccc","#cccccc","#000000"],hover:"#cccccc"},direction:"horiz",imageCaption:{offset:{x:0,y:0},isActive:!0,alignment:"middle-center",linkColor:"#cccccc",linkHoverColor:"#cccccc"}},displayRules:[{if:{name:"direction",value:"vert"},then:{name:"properties.pagination.properties.position.display.direction",value:"vertical"}},{if:{name:"transition.type",value:"fade in"},then:{name:"properties.transition.properties.backgroundColor.display.visible",value:!0}}]},content:{type:"array",settings:{addItemFromFileExplorer:!0},items:{type:"object",properties:{image:{type:"object",label:"Image",display:{type:"media-input"},properties:{assetId:{type:"string"},name:{type:"string"},objectFit:{type:"string",enum:["cover","contain"]}},required:["assetId","name"]},imageCaption:{placeholder:"Add Caption...",label:"Description",display:{type:"rich-text"}}},required:["image"]},default:[{image:{objectFit:"cover",assetId:"01M3QM74XES6E7GVC0H3KJ2RH6",name:"Slider-1.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]},{image:{objectFit:"cover",assetId:"01M3QM74XEAZ8H1DTC5V1S554K",name:"Slider-2.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]},{image:{objectFit:"cover",assetId:"01M3QM74XEDRP49HNTEPNZYQTP",name:"Slider-3.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]}]},styles:{type:"object",properties:{imageCaption:{dataName:"caption",type:"object",properties:{fontSettings:{type:"object",display:{type:"font-settings"},properties:{fontFamily:{type:"string"},fontWeight:{type:"number"},fontStyle:{type:"string"}}},widthSettings:{display:{type:"text-width-control"},type:"object",properties:{width:{type:"number"},sizing:{type:"string",enum:["auto","manual"]}}},fontSizeLineHeight:{type:"object",display:{type:"font-size-line-height"},properties:{fontSize:{type:"number"},lineHeight:{type:"number"}}},letterSpacing:{display:{type:"letter-spacing-input"},type:"number"},wordSpacing:{display:{type:"word-spacing-input"},type:"number"},textAlign:{display:{type:"text-align-control"},type:"string",enum:["left","center","right","justify"]},textAppearance:{display:{type:"text-appearance"},properties:{textTransform:{type:"string",enum:["none","uppercase","lowercase","capitalize"]},textDecoration:{type:"string",enum:["none","underline"]},fontVariant:{type:"string",enum:["normal","small-caps"]}}},color:{display:{type:"style-panel-color-picker"},type:"string"}}}},default:{imageCaption:{widthSettings:{width:.13,sizing:"auto"},fontSettings:{fontFamily:"Arial",fontWeight:400,fontStyle:"normal"},fontSizeLineHeight:{fontSize:.02,lineHeight:.02},letterSpacing:0,wordSpacing:0,textAlign:"left",textAppearance:{textTransform:"none",textDecoration:"none",fontVariant:"normal"},color:"#000000"}}}},required:["settings","content","styles"]}},i={element:n.ImageRevealSlider,id:"control-image-reveal",name:"Click Gallery",preview:{type:"image",url:"https://cdn.cntrl.site/component-assets/Click_Gallery.mp4"},defaultSize:{d:{width:"100%",height:"100%"},t:{width:"100%",height:"100%"},m:{width:"100%",height:"100%"}},assetsPaths:{content:[{path:"image.assetId",placeholderEnabled:!0}],parameters:[{path:"settings.cursor.defaultCursor"},{path:"settings.cursor.hoverCursor"}]},fontSettingsPaths:{content:[],parameters:[]},schema:{type:"object",properties:{settings:{type:"object",display:{type:"settings-block"},properties:{imageSize:{title:"IMG SIZE",icon:"size",tooltip:"IMG SIZE",type:"object",properties:{sizeType:{type:"string",display:{type:"ratio-group"},enum:["as Is","custom","random"]},imageWidth:{type:"number",label:"W",display:{type:"numeric-input",visible:!1}},randomRangeImageWidth:{type:"object",display:{type:"random-range-controls",visible:!1},properties:{min:{type:"number"},max:{type:"number"}}}}},cursor:{title:"cursor",icon:"cursor",tooltip:"cursor",type:"object",properties:{cursorType:{type:"string",display:{type:"ratio-group"},enum:["system","custom"]},target:{type:"string",title:"Target",display:{type:"ratio-group"},enum:["area","image"]},defaultCursor:{type:["string","null"],title:"Default",display:{type:"settings-image-input",visible:!1}},defaultCursorScale:{type:"number",title:"Scale",min:1,max:5,step:.1,display:{type:"range-control",visible:!1}},hoverCursor:{type:["string","null"],title:"Hover",display:{type:"settings-image-input",visible:!1}},hoverCursorScale:{type:"number",title:"Scale",min:1,max:5,step:.1,display:{type:"range-control",visible:!1}}}},position:{title:"position",icon:"transition",tooltip:"Position",type:"object",properties:{revealPosition:{type:"string",display:{type:"ratio-group"},enum:["random","same","on Click"]},visible:{type:"string",title:"Visible",display:{type:"ratio-group"},enum:["all","last One"]}}}},default:{imageSize:{sizeType:"custom",imageWidth:500,randomRangeImageWidth:{min:100,max:1e3}},cursor:{cursorType:"system",target:"area",defaultCursor:null,defaultCursorScale:2,hoverCursor:null,hoverCursorScale:2},position:{revealPosition:"random",visible:"all"}},displayRules:[{if:{name:"imageSize.sizeType",value:"custom"},then:{name:"properties.imageSize.properties.imageWidth.display.visible",value:!0}},{if:{name:"imageSize.sizeType",value:"random"},then:{name:"properties.imageSize.properties.randomRangeImageWidth.display.visible",value:!0}},{if:[{name:"cursor.target",value:"image"},{name:"cursor.cursorType",value:"custom"}],then:{name:"properties.cursor.properties.defaultCursor.display.visible",value:!0}},{if:[{name:"cursor.target",value:"image"},{name:"cursor.cursorType",value:"custom"},{name:"cursor.defaultCursor",value:null,isNotEqual:!0}],then:{name:"properties.cursor.properties.defaultCursorScale.display.visible",value:!0}},{if:{name:"cursor.cursorType",value:"custom"},then:{name:"properties.cursor.properties.hoverCursor.display.visible",value:!0}},{if:[{name:"cursor.cursorType",value:"custom"},{name:"cursor.hoverCursor",value:null,isNotEqual:!0}],then:{name:"properties.cursor.properties.hoverCursorScale.display.visible",value:!0}}]},content:{type:"array",settings:{addItemFromFileExplorer:!0},items:{type:"object",properties:{image:{type:"object",label:"Image",display:{isObjectFitEditable:!1,type:"media-input"},properties:{assetId:{type:"string"},name:{type:"string"},objectFit:{type:"string",enum:["cover","contain"]}},required:["assetId","name"]},link:{type:"object",label:"URL",display:{type:"link-input"}}},required:["image"]},default:[{image:{objectFit:"cover",assetId:"01M3QM74XGWBJY3AQQ71GC2Z6Q",name:"Slider-1.png"},link:{type:"url",value:"",target:"blank"}},{image:{objectFit:"cover",assetId:"01M3QM74XGMXS1Z5ZY2RFGS3T4",name:"Slider-2.png"},link:{type:"url",value:"",target:"blank"}},{image:{objectFit:"cover",assetId:"01M3QM74XGWG6VCHNEXKVKAJGT",name:"Slider-3.png"},link:{type:"url",value:"",target:"blank"}},{image:{objectFit:"cover",assetId:"01M3QM74XGCVMTPNHFHMR98RPZ",name:"Slider-4.png"},link:{type:"url",value:"",target:"blank"}}]}}}},o={element:p.LightboxGallery,id:"lightbox",name:"Lightbox",preview:{type:"image",url:"https://cdn.cntrl.site/component-assets/Lightbox.png"},defaultSize:{d:{width:440,height:550},t:{width:235,height:293},m:{width:265,height:331}},fontSettingsPaths:{content:[],parameters:[{path:"styles.imageCaption.fontSettings"}]},assetsPaths:{content:[{path:"image.assetId",placeholderEnabled:!0}],parameters:[{path:"settings.thumbnailBlock.cover.assetId",placeholderEnabled:!0},{path:"settings.controls.arrowsImgUrl"},{path:"settings.area.closeIconUrl"}]},schema:{type:"object",properties:{settings:{type:"object",properties:{thumbnailBlock:{display:{type:"settings-block",triggerEvent:"close"},type:"object",properties:{cover:{title:"COVER",icon:"cover",tooltip:"Cover Image",type:"object",properties:{assetId:{type:"string",display:{type:"cover-image-input"}}}}}},lightboxBlock:{display:{type:"settings-block",triggerEvent:"open"},type:"object",properties:{appear:{title:"APPEAR",icon:"transition",tooltip:"Appearance",type:"object",properties:{type:{type:"string",display:{type:"ratio-group"},enum:["slide in","fade in","mix"]},duration:{type:"string",label:"T",display:{type:"step-selector"},enum:["100ms","250ms","500ms","1000ms","1500ms","2000ms"]},direction:{type:"string",title:"From",display:{type:"direction-control"},enum:["top","left","right","bottom"]}}},triggers:{title:"TRIGGERS",icon:"target",tooltip:"Triggers",type:"object",properties:{type:{type:"string",display:{type:"ratio-group"},enum:["click","drag"]},switch:{type:"string",display:{type:"ratio-group"},enum:["image","50/50"]},repeat:{type:"string",title:"Repeat",display:{visible:!1,type:"ratio-group"},enum:["close","loop"]}}},slider:{title:"SLIDER",icon:"horizontal-resize",tooltip:"Slider",type:"object",properties:{type:{type:"string",display:{type:"ratio-group"},enum:["slide","fade","scale"]},direction:{type:"string",display:{type:"ratio-group"},enum:["horiz","vert"]},duration:{type:"string",label:"T",display:{type:"step-selector"},enum:["100ms","250ms","500ms","1000ms","1500ms","2000ms"]}}},thumbnail:{title:"THUMB",icon:"thumbnail",tooltip:"Thumbnail",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},position:{display:{type:"align-grid"},type:"string",enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},fit:{type:"string",display:{type:"ratio-group"},enum:["cover","fit"]},align:{type:"string",title:"Align",display:{type:"align-group",direction:"horizontal"},enum:["start","center","end"]},triggers:{type:"string",title:"Triggers",display:{type:"ratio-group",direction:"horizontal"},enum:["clk","hov"]},grid:{type:"object",title:"Grid",display:{type:"group"},properties:{size:{type:"number",label:"Box",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},gap:{type:"number",label:"Gap",scalingEnabled:!0,min:0,display:{type:"numeric-input"}}}},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},opacity:{type:"number",title:"Opacity",label:"icon:opacity",min:0,max:100,step:1,display:{type:"numeric-input"}},activeState:{type:"object",title:"ACTIVE",display:{type:"group"},properties:{scale:{type:"number",title:"Scale",min:1,max:5,step:.1,display:{type:"range-control"}},opacity:{type:"number",title:"Opacity",label:"icon:opacity",min:0,max:100,step:1,display:{type:"numeric-input"}}}}}},layout:{title:"LAYOUT",icon:"layout",tooltip:"Layout",type:"object",properties:{position:{display:{type:"align-grid"},type:"string",enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},offset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},padding:{type:"object",title:"Padding",display:{type:"padding-controls"},properties:{top:{min:0,step:1,type:"number"},left:{min:0,step:1,type:"number"},right:{min:0,step:1,type:"number"},bottom:{min:0,step:1,type:"number"}}}}},controls:{title:"CONTROLS",icon:"controls",tooltip:"Controls",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},arrowsImgUrl:{type:["string","null"],display:{type:"settings-image-input"}},offset:{title:"Offset",type:"object",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},scale:{type:"number",title:"Scale",min:.5,max:5,step:.1,display:{type:"range-control"}},color:{title:"Color",type:"string",display:{type:"settings-color-picker",format:"single"}},hover:{title:"Hover",type:"string",display:{type:"settings-color-picker",format:"single"}}}},area:{title:"AREA",icon:"area",tooltip:"Area",type:"object",properties:{color:{type:"string",display:{type:"settings-color-picker",format:"single"}},blur:{type:"number",label:"icon:blur",display:{type:"numeric-input"}},closeIconUrl:{type:["string","null"],title:"Close Icon",display:{type:"settings-image-input"}},closeIconAlign:{display:{type:"align-grid",direction:"horizontal"},type:"string",enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},closeIconScale:{type:"number",title:"Scale",min:.5,max:5,step:.1,display:{type:"range-control"}},closeIconOffset:{type:"object",title:"Offset",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},closeIconColor:{title:"Color",type:"string",display:{type:"settings-color-picker",format:"single"}},closeIconHover:{title:"Hover",type:"string",display:{type:"settings-color-picker",format:"single"}}}},caption:{title:"DESC",icon:"text-icon",tooltip:"Description",type:"object",properties:{isActive:{type:"boolean",display:{type:"setting-toggle"}},alignment:{type:"string",display:{type:"align-grid"},enum:["top-left","top-center","top-right","middle-left","middle-center","middle-right","bottom-left","bottom-center","bottom-right"]},offset:{title:"Offset",type:"object",display:{type:"group"},properties:{x:{type:"number",label:"X",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}},y:{type:"number",label:"Y",scalingEnabled:!0,display:{type:"numeric-input",visible:!0}}}},linkColor:{title:"Link",type:"string",display:{type:"settings-color-picker",format:"single"}},linkHoverColor:{title:"Link Hov",type:"string",display:{type:"settings-color-picker",format:"single"}}}}}}},default:{d:{thumbnailBlock:{cover:{assetId:"01M3QM74XEQ5ZGJ9WAMKV0EY1V"}},lightboxBlock:{appear:{type:"slide in",duration:"1000ms",direction:"bottom"},triggers:{type:"click",switch:"image",repeat:"loop"},slider:{type:"slide",direction:"vert",duration:"1000ms"},thumbnail:{isActive:!0,position:"middle-left",fit:"fit",align:"start",triggers:"hov",grid:{size:.05,gap:.01},offset:{x:.01,y:0},opacity:50,activeState:{scale:1,opacity:100}},layout:{position:"middle-center",offset:{x:0,y:0},padding:{top:.06,right:0,bottom:.06,left:0}},controls:{isActive:!1,arrowsImgUrl:null,offset:{x:0,y:0},scale:1,color:"#000000",hover:"#cccccc"},area:{color:"rgba(28,31,34,0.9)",blur:0,closeIconUrl:null,closeIconColor:"#000000",closeIconHover:"#cccccc",closeIconAlign:"top-right",closeIconOffset:{x:0,y:0},closeIconScale:1},caption:{isActive:!0,alignment:"middle-center",offset:{x:0,y:0},linkColor:"#cccccc",linkHoverColor:"#cccccc"}}},m:{thumbnailBlock:{cover:{assetId:"01M3QM74XEQ5ZGJ9WAMKV0EY1V"}},lightboxBlock:{appear:{type:"fade in",duration:"500ms",direction:"bottom"},triggers:{type:"click",switch:"image",repeat:"loop"},slider:{type:"slide",direction:"horiz",duration:"1000ms"},thumbnail:{isActive:!0,position:"bottom-center",fit:"fit",align:"start",triggers:"hov",grid:{size:.1,gap:.05},offset:{x:.01,y:-.05},opacity:50,activeState:{scale:1,opacity:100}},layout:{position:"middle-center",offset:{x:0,y:0},padding:{top:.06,right:.05,bottom:.06,left:.05}},controls:{isActive:!1,arrowsImgUrl:null,offset:{x:0,y:0},scale:1,color:"#000000",hover:"#cccccc"},area:{color:"rgba(28,31,34,0.9)",blur:0,closeIconUrl:null,closeIconColor:"#000000",closeIconHover:"#cccccc",closeIconAlign:"top-right",closeIconOffset:{x:0,y:0},closeIconScale:1},caption:{isActive:!0,alignment:"middle-center",offset:{x:0,y:0},hover:"#cccccc"}}},t:{thumbnailBlock:{cover:{assetId:"01M3QM74XEQ5ZGJ9WAMKV0EY1V"}},lightboxBlock:{appear:{type:"fade in",duration:"500ms",direction:"bottom"},triggers:{type:"click",switch:"image",repeat:"loop"},slider:{type:"slide",direction:"vert",duration:"1000ms"},thumbnail:{isActive:!0,position:"middle-left",fit:"fit",align:"start",triggers:"hov",grid:{size:.05,gap:.01},offset:{x:.03,y:0},opacity:50,activeState:{scale:1,opacity:100}},layout:{position:"middle-center",offset:{x:0,y:0},padding:{top:.06,right:.1,bottom:.06,left:.1}},controls:{isActive:!1,arrowsImgUrl:null,offset:{x:0,y:0},scale:1,color:"#000000",hover:"#cccccc"},area:{color:"rgba(28,31,34,0.9)",blur:0,closeIconUrl:null,closeIconColor:"#000000",closeIconHover:"#cccccc",closeIconAlign:"top-right",closeIconOffset:{x:0,y:0},closeIconScale:1},caption:{isActive:!0,alignment:"middle-center",offset:{x:0,y:0},hover:"#cccccc"}}}},displayRules:[{if:{name:"lightboxBlock.appear.type",value:"slide in"},then:{name:"properties.lightboxBlock.properties.appear.properties.direction.display.visible",value:!0}},{if:{name:"lightboxBlock.slider.direction",value:"vert"},then:{name:"properties.lightboxBlock.properties.thumbnail.properties.align.display.direction",value:"vertical"}},{if:{name:"lightboxBlock.appear.type",value:"mix"},then:{name:"properties.lightboxBlock.properties.appear.properties.direction.display.visible",value:!0}},{if:{name:"lightboxBlock.appear.type",value:"fade in"},then:{name:"properties.lightboxBlock.properties.appear.properties.direction.display.visible",value:!1}},{if:[{name:"lightboxBlock.triggers.type",value:"click"},{name:"lightboxBlock.triggers.switch",value:"image"}],then:{name:"properties.lightboxBlock.properties.triggers.properties.repeat.display.visible",value:!0}}]},content:{type:"array",settings:{addItemFromFileExplorer:!0},items:{type:"object",properties:{image:{type:"object",label:"Image",display:{type:"media-input"},properties:{assetId:{type:"string"},name:{type:"string"},objectFit:{type:"string",enum:["cover","contain"]}},required:["assetId","name"]},imageCaption:{label:"Description",placeholder:"Add Caption...",display:{type:"rich-text"}}},required:["image"]},default:[{image:{objectFit:"contain",assetId:"01M3QM74XD4J8X0B8TTSQ8CV3P",name:"Slider-1.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]},{image:{objectFit:"contain",assetId:"01M3QM74XD0N6VQJ5J8J9YB32N",name:"Slider-2.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]},{image:{objectFit:"contain",assetId:"01M3QM74XE4WSEPVF1QQSKMD76",name:"Slider-3.png"},imageCaption:[{type:"paragraph",children:[{text:""}]}]}]},styles:{type:"object",properties:{imageCaption:{dataName:"caption",type:"object",properties:{fontSettings:{type:"object",display:{type:"font-settings"},properties:{fontFamily:{type:"string"},fontWeight:{type:"number"},fontStyle:{type:"string"}}},widthSettings:{display:{type:"text-width-control"},type:"object",properties:{width:{type:"number"},sizing:{type:"string",enum:["auto","manual"]}}},fontSizeLineHeight:{type:"object",display:{type:"font-size-line-height"},properties:{fontSize:{type:"number"},lineHeight:{type:"number"}}},letterSpacing:{display:{type:"letter-spacing-input"},type:"number"},wordSpacing:{display:{type:"word-spacing-input"},type:"number"},textAlign:{display:{type:"text-align-control"},type:"string",enum:["left","center","right","justify"]},textAppearance:{display:{type:"text-appearance"},properties:{textTransform:{type:"string",enum:["none","uppercase","lowercase","capitalize"]},textDecoration:{type:"string",enum:["none","underline"]},fontVariant:{type:"string",enum:["normal","small-caps"]}}},color:{display:{type:"style-panel-color-picker"},type:"string"}}}},default:{imageCaption:{widthSettings:{width:.13,sizing:"auto"},fontSettings:{fontFamily:"Arial",fontWeight:400,fontStyle:"normal"},fontSizeLineHeight:{fontSize:.02,lineHeight:.02},letterSpacing:0,wordSpacing:0,textAlign:"left",textAppearance:{textTransform:"none",textDecoration:"none",fontVariant:"normal"},color:"#000000"}}}},required:["settings","content","styles"]}},l=[t,i,e.ClickGallerieComponent,o,e.FormComponent,e.OnelinerFormComponent,e.MarqueeComponent,e.MarqueeTextComponent,e.TestimonialGridComponent,e.TestimonialSingleComponent,e.GridComponent,e.HiveComponent,e.ListComponent,e.FAQComponent,e.LightboxStripComponent,e.LightboxJournalComponent,e.ScaleComponent,e.WaterfallComponent,e.SimpleButtonComponent,e.Slider20Component,e.MercuryComponent,e.HelixComponent,e.BurgerComponent,e.PretextComponent,e.ChroniclesComponent];exports.ControlImageRevealSliderComponent=i;exports.ControlSliderComponent=t;exports.LightboxComponent=o;exports.components=l;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ControlSlider as e } from "./ControlSlider-DqKfaKMG.mjs";
|
|
2
2
|
import { ImageRevealSlider as t } from "./ImageRevealSlider-DifEXySR.mjs";
|
|
3
3
|
import { LightboxGallery as i } from "./Lightbox-BY99NS14.mjs";
|
|
4
|
-
import { C as o, F as r, O as p, M as n, a as l, T as s, b as a, G as c, H as y, L as g, c as m, d, e as u, S as b, W as h, f, g as v, h as C, i as x, B as S, P as k, j as I } from "./ChroniclesComponent-
|
|
4
|
+
import { C as o, F as r, O as p, M as n, a as l, T as s, b as a, G as c, H as y, L as g, c as m, d, e as u, S as b, W as h, f, g as v, h as C, i as x, B as S, P as k, j as I } from "./ChroniclesComponent-0ZWBPdbh.mjs";
|
|
5
5
|
const j = {
|
|
6
6
|
element: e,
|
|
7
7
|
id: "control-slider",
|
package/dist/elements.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var h=Object.create;var a=Object.defineProperty;var u=Object.getOwnPropertyDescriptor;var c=Object.getOwnPropertyNames;var g=Object.getPrototypeOf,f=Object.prototype.hasOwnProperty;var d=(e,r,n,o)=>{if(r&&typeof r=="object"||typeof r=="function")for(let i of c(r))!f.call(e,i)&&i!==n&&a(e,i,{get:()=>r[i],enumerable:!(o=u(r,i))||o.enumerable});return e};var t=(e,r,n)=>(n=e!=null?h(g(e)):{},d(r||!e||!e.__esModule?a(n,"default",{value:e,enumerable:!0}):n,e));Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m={"basic-burger":()=>import(/* webpackFetchPriority: "high" */ "./Burger-C3yVbQcq.js").then(e=>e.Burger),chronicles:()=>import(/* webpackFetchPriority: "high" */ "./Chronicles-
|
|
1
|
+
"use strict";var h=Object.create;var a=Object.defineProperty;var u=Object.getOwnPropertyDescriptor;var c=Object.getOwnPropertyNames;var g=Object.getPrototypeOf,f=Object.prototype.hasOwnProperty;var d=(e,r,n,o)=>{if(r&&typeof r=="object"||typeof r=="function")for(let i of c(r))!f.call(e,i)&&i!==n&&a(e,i,{get:()=>r[i],enumerable:!(o=u(r,i))||o.enumerable});return e};var t=(e,r,n)=>(n=e!=null?h(g(e)):{},d(r||!e||!e.__esModule?a(n,"default",{value:e,enumerable:!0}):n,e));Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m={"basic-burger":()=>import(/* webpackFetchPriority: "high" */ "./Burger-C3yVbQcq.js").then(e=>e.Burger),chronicles:()=>import(/* webpackFetchPriority: "high" */ "./Chronicles-Dj1gvNjE.js").then(e=>e.Chronicles),"click-gallerie":()=>import(/* webpackFetchPriority: "high" */ "./ClickGallerie-DYbc-rDp.js").then(e=>e.ClickGallerie),"control-slider":()=>import(/* webpackFetchPriority: "high" */ "./ControlSlider-C8ckUIDm.js").then(e=>e.ControlSlider),faq:()=>import(/* webpackFetchPriority: "high" */ "./FAQ-DLh63Utr.js").then(e=>e.FAQ),form:()=>import(/* webpackFetchPriority: "high" */ "./Form-Dn-6A1He.js").then(e=>e.Form),grid:()=>import(/* webpackFetchPriority: "high" */ "./Grid-OvzWvUW9.js").then(e=>e.Grid),helix:()=>import(/* webpackFetchPriority: "high" */ "./Helix-BpLo9FD3.js").then(e=>e.Helix),hive:()=>import(/* webpackFetchPriority: "high" */ "./Hive-CzabuuCc.js").then(e=>e.Hive),"control-image-reveal":()=>import(/* webpackFetchPriority: "high" */ "./ImageRevealSlider-DlxudBUy.js").then(e=>e.ImageRevealSlider),lightbox:()=>import(/* webpackFetchPriority: "high" */ "./Lightbox-DZckgBzK.js").then(e=>e.LightboxGallery),"lightbox-journal":()=>import(/* webpackFetchPriority: "high" */ "./LightboxJournal-Bmw2zm4t.js").then(e=>e.LightboxJournal),"lightbox-strip":()=>import(/* webpackFetchPriority: "high" */ "./LightboxStrip-CTxRwLYk.js").then(e=>e.LightboxStrip),list:()=>import(/* webpackFetchPriority: "high" */ "./List-DVvpQ24J.js").then(e=>e.List),marquee:()=>import(/* webpackFetchPriority: "high" */ "./Marquee-DDKigLBo.js").then(e=>e.Marquee),"marquee-text":()=>import(/* webpackFetchPriority: "high" */ "./MarqueeText-B5hqB0HA.js").then(e=>e.MarqueeText),mercury:()=>import(/* webpackFetchPriority: "high" */ "./Mercury-B-s2Kvuq.js").then(e=>e.Mercury),"oneliner-form":()=>import(/* webpackFetchPriority: "high" */ "./OnelinerForm-C2Y_XMCY.js").then(e=>e.OnelinerForm),pretext:()=>import(/* webpackFetchPriority: "high" */ "./Pretext-DvQ3xsni.js").then(e=>e.Pretext),scale:()=>import(/* webpackFetchPriority: "high" */ "./Scale-Bg3bGICG.js").then(e=>e.Scale),"simple-button":()=>import(/* webpackFetchPriority: "high" */ "./SimpleButton-nGEcO2gB.js").then(e=>e.SimpleButton),"slider-2-0":()=>import(/* webpackFetchPriority: "high" */ "./Slider20-BOmjDRf2.js").then(e=>e.Slider20),testimonials:()=>import(/* webpackFetchPriority: "high" */ "./TestimonialGrid-BHZazEVX.js").then(e=>e.TestimonialGrid),"testimonial-single":()=>import(/* webpackFetchPriority: "high" */ "./TestimonialSingle-BORQom3u.js").then(e=>e.TestimonialSingle),waterfall:()=>import(/* webpackFetchPriority: "high" */ "./Waterfall-DII4-WV5.js").then(e=>e.Waterfall)},b=Object.keys(m),y=3,E=2e3,s=new Map,l=new Map;function p(e){return Object.prototype.hasOwnProperty.call(m,e)}function x(e){return s.get(e)}function C(e){var r;return(((r=l.get(e))==null?void 0:r.failures)??0)>0}const S=e=>!e.loading&&e.failures>0&&e.failures<y&&Date.now()>=e.retryAt;function M(e){if(!p(e))return Promise.resolve(void 0);const r=l.get(e);if(r&&!S(r))return r.request;const n={loading:!0,failures:(r==null?void 0:r.failures)??0,retryAt:0,request:m[e]().then(o=>(s.set(e,o),n.failures=0,o),o=>{throw n.failures+=1,n.retryAt=Date.now()+E*2**(n.failures-1),o}).finally(()=>{n.loading=!1})};return l.set(e,n),n.request}exports.componentElementIds=b;exports.getComponentElement=x;exports.hasComponentElement=p;exports.hasComponentElementFailed=C;exports.loadComponentElement=M;
|