@cntrl-site/components 1.0.116-alpha.0 → 1.0.117
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/{Burger-DyORh_vF.mjs → Burger-BkVgNMGU.mjs} +1 -1
- package/dist/{Burger-B4kXX9aY.js → Burger-C3yVbQcq.js} +1 -1
- package/dist/Chronicles-BNvvaFYY.mjs +744 -0
- package/dist/Chronicles-Dj1gvNjE.js +196 -0
- package/dist/ChroniclesComponent-CoOgQZx2.js +1 -0
- package/dist/{ChroniclesComponent-jh4v7wp6.mjs → ChroniclesComponent-Szt0H-op.mjs} +542 -491
- 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/Components/helpers/SvgImage/loadSvgMaskUrl.d.ts +0 -7
- package/dist/{ControlSlider-DB4nbVLT.js → ControlSlider-C8ckUIDm.js} +1 -1
- package/dist/{ControlSlider-3w-bHQEg.mjs → ControlSlider-DqKfaKMG.mjs} +1 -1
- package/dist/{FAQ-GmiwRdFq.mjs → FAQ-CJHCMSBa.mjs} +1 -1
- package/dist/{FAQ-7HEkaoU6.js → FAQ-DLh63Utr.js} +1 -1
- package/dist/{Grid-BzarI5Mc.js → Grid-C4hO8KCr.js} +14 -9
- package/dist/{Grid-Z2JZyUdC.mjs → Grid-Dud7PLS9.mjs} +201 -196
- package/dist/{Hive-34KvKNsa.js → Hive-CzabuuCc.js} +1 -1
- package/dist/{Hive-7xHXyMM1.mjs → Hive-DyxYd5eg.mjs} +1 -1
- package/dist/{HiveLightboxTitles-BCoL46-V.mjs → HiveLightboxTitles-DhEeFKWs.mjs} +1 -1
- package/dist/{HiveLightboxTitles-DEeyQGcf.js → HiveLightboxTitles-DlyptAaK.js} +1 -1
- package/dist/{Lightbox-DzPqgKP4.mjs → Lightbox-BY99NS14.mjs} +1 -1
- package/dist/{Lightbox-Cb7lyaNt.js → Lightbox-DZckgBzK.js} +1 -1
- package/dist/{LightboxJournal-C_q7_s-B.mjs → LightboxJournal-BDUs6T0B.mjs} +466 -434
- package/dist/LightboxJournal-Bf_rZzmz.js +555 -0
- package/dist/{LightboxStrip-BrNj7ipX.mjs → LightboxStrip-Cuhb2fIR.mjs} +459 -427
- package/dist/LightboxStrip-RA4ABUC-.js +418 -0
- package/dist/{Mercury-BmhtFYOw.js → Mercury-B-s2Kvuq.js} +1 -1
- package/dist/{Mercury-Q788wrYQ.mjs → Mercury-CCW0Es-s.mjs} +1 -1
- package/dist/{OnelinerForm-D8WIB9Qy.mjs → OnelinerForm-BEu7_sho.mjs} +1 -1
- package/dist/{OnelinerForm-CUmY-bXL.js → OnelinerForm-C2Y_XMCY.js} +1 -1
- package/dist/{SimpleButton-DTpzfmb6.mjs → SimpleButton-C-o2W9bS.mjs} +1 -1
- package/dist/{SimpleButton-DtaCYa3y.js → SimpleButton-nGEcO2gB.js} +1 -1
- package/dist/{Slider20-q0iGgnE3.js → Slider20-BOmjDRf2.js} +1 -1
- package/dist/{Slider20-CKngROrc.mjs → Slider20-DUi6qwnd.mjs} +1 -1
- package/dist/SvgImage-B5mR9y6q.mjs +51 -0
- package/dist/SvgImage-DFlmxAoL.js +1 -0
- package/dist/{TestimonialSingle-CpEUendN.js → TestimonialSingle-BORQom3u.js} +1 -1
- package/dist/{TestimonialSingle-Bax71Hyo.mjs → TestimonialSingle-DrnyReim.mjs} +1 -1
- package/dist/{Waterfall-znaoynn5.mjs → Waterfall-3kKioKh2.mjs} +1 -1
- package/dist/{Waterfall-B9YWMhrg.js → Waterfall-DII4-WV5.js} +1 -1
- package/dist/{components-C9Fu28pp.mjs → components-DSHc15vW.mjs} +29 -653
- package/dist/components-iORMB3kt.js +1 -0
- package/dist/elements.js +1 -1
- package/dist/elements.mjs +23 -24
- package/dist/elements.node.js +1 -1
- package/dist/elements.node.mjs +1 -1
- package/dist/index.d.ts +2 -4
- package/dist/index.js +1 -1
- package/dist/index.mjs +38 -61
- package/dist/loadSvgMaskUrl-DfF7ay6h.js +1 -0
- package/dist/loadSvgMaskUrl-xHgGYgPe.mjs +20 -0
- package/dist/sources.js +143 -30
- package/dist/sources.mjs +150 -37
- package/dist/types/Component.d.ts +0 -7
- package/dist/types/SchemaV1.d.ts +3 -3
- package/package.json +1 -1
- package/dist/Chronicles-Cy2h3jlZ.mjs +0 -724
- package/dist/Chronicles-D0ojQzOP.js +0 -196
- package/dist/ChroniclesComponent-DYPJBI3d.js +0 -1
- package/dist/Components/PopupMenu/PopupMenu.d.ts +0 -73
- package/dist/Components/PopupMenu/PopupMenuComponent.d.ts +0 -594
- package/dist/Components/PopupMenu/popupMenuLayout.d.ts +0 -203
- package/dist/Components/PopupMenu/popupMenuSnap.d.ts +0 -61
- package/dist/LightboxJournal-BFF5aKRz.js +0 -523
- package/dist/LightboxStrip-CC2e0_9A.js +0 -386
- package/dist/PopupMenu-CYdDyzEt.mjs +0 -1372
- package/dist/PopupMenu-Di1fHgho.js +0 -409
- package/dist/SvgImage-CwRq9-ec.mjs +0 -56
- package/dist/SvgImage-_QN8ngad.js +0 -1
- package/dist/components-6QFLq5OI.js +0 -1
- package/dist/loadSvgMaskUrl-B6kHUyof.js +0 -1
- package/dist/loadSvgMaskUrl-DUhCVvpl.mjs +0 -39
|
@@ -0,0 +1,418 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("react/jsx-runtime"),a=require("react"),kn=require("react-dom"),_n=require("./useScopedStyles-Bf6yohVQ.js"),Z=require("./useLightboxSwipeDismiss-Br9uE5G0.js"),At=require("./scalingValue-CSHYgTZl.js"),En=require("./SvgImage-DFlmxAoL.js"),Nn=require("./useLightboxScrollLock-Hf16Eq4g.js"),On=require("./textStylesToCss-CNN3zZTV.js"),zn=(e,o,u,f)=>{const l=Math.min(Math.abs(e)/Math.max(f,1),1);return o+(u-o)*l},Fn=e=>{e.style.transition="",e.style.transform="",e.style.willChange=""},Kn=e=>{const o=getComputedStyle(e).transform;return o==="none"?0:new DOMMatrixReadOnly(o).m41},Bn=(e,o,u,{duration:f,easing:l,onComplete:m})=>{const p=e.scrollLeft,w=u-p,R=p-u,N=(A,Q)=>{Fn(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-Kn(o),!1))}},xt=300,Dn=900,Hn=1500,Xn="cubic-bezier(0.16, 1, 0.3, 1)",Gn=3e3,Vn=2,Yn=16,qn=.05,Un=1,Wt=.3,Zn=50,Jn=20,at=.004,Fe=["title1","title2","title3"],Ke={title1:"1",title2:"2",title3:"3"},Qn={title1:"title1Color",title2:"title2Color",title3:"title3Color"},Pn={title1:.02,title2:.02,title3:.02},Ct=e=>`max(${e}, ${Jn}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")],tr=()=>({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)}},er=(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},te=(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[Qn[o]]}},nr=(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),ee=(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??Pn[e],lineHeight:o.lineHeight,letterSpacing:o.letterSpacing,wordSpacing:o.wordSpacing,textAlign:o.textAlign,textAppearance:o.textAppearance,color:o.color??"#ffffff"};return On.textStylesToCss(f,u)},rr=({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:Ge,thumbnailActiveColor:Ve,title1Width:Mt,title2Width:ie,title3Width:se,title1MarginLeft:W=0,title2MarginLeft:le=0,title3MarginLeft:ae=0,titleRowMarginBottom:ce=0,titleHeaderLayout:ue="desktop",contentMarginTop:Ye,iconMarginLeft:qe}=u,P=t=>At.scalingValue(t,f??!1),Ue=R??u.thumnailSize??.03,fe=P(Ue),kt=P(N),_t=P(M??.02),ut=P(J??0),he=P(Ye??0),Ze=Ct(he),de=P(qe??0),[tt,Et]=a.useState(0),C=a.useRef(tt);C.current=tt;const Je=o[tt],{title1:Nt,title2:Ot,title3:zt}=De(Je),me=ee("title1",te(u,"title1"),f),pe=ee("title2",te(u,"title2"),f),ge=ee("title3",te(u,"title3"),f),j=ue==="mobile",G=!l&&(!f||m),ft=G,ht=G,Qe=G,xe=Z.isImageRatioCover(bt),Pe=xe?{"--image-aspect-ratio":Z.getAspectRatio(bt)}:void 0,ve=!!(Nt||Ot||zt),x=a.useMemo(()=>er(e,Nt,Ot,zt,me,pe,ge),[e,tt,Nt,Ot,zt,me,pe,ge]),et=a.useMemo(()=>({title1Width:Mt,title2Width:ie,title3Width:se}),[Mt,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]),k=a.useMemo(()=>x.filter(t=>t.prefix==="title2"||t.prefix==="title3"),[x]),St=a.useMemo(()=>ze(wt,et),[wt,et]),B=a.useMemo(()=>ze(k,et),[k,et]),Ft=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=k.indexOf(t);return{effectiveWidth:B.effective[i]??0,resolvedWidth:B.resolved[i]??0,maxWidth:jt(i,B.resolved)}},[k,B,be,z,x,wt,St,j]),y=a.useCallback(t=>At.scalingValue(t,f??!1),[f]),tn=y(ce??0),_=a.useMemo(()=>({title1MarginLeft:W,title2MarginLeft:le,title3MarginLeft:ae}),[W,le,ae]),en=a.useCallback(t=>x.slice(0,t+1).reduce((n,r,i)=>n+(r!=null&&r.marginLeftKey?_[r.marginLeftKey]??0:0)+(z[i]??0),0)+(j?0:W??0),[x,_,z,j,W]),nn=a.useCallback(()=>j?0:W??0,[j,W]),Kt=a.useCallback(t=>k.slice(0,t).reduce((n,r,i)=>n+(r.marginLeftKey?_[r.marginLeftKey]??0:0)+(B.resolved[i]??0),0),[k,B.resolved,_]),rn=a.useCallback(t=>{const n=k[t];return Kt(t)+(n.marginLeftKey?_[n.marginLeftKey]??0:0)+(B.resolved[t]??0)},[k,B.resolved,Kt,_]),Bt=(t,n)=>{const r=t.marginLeftKey?_[t.marginLeftKey]??0:0,{effectiveWidth:i,resolvedWidth:s,maxWidth:h}=Ft(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)},on=()=>{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]:Mt??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=_[i.marginLeftKey]??0,d=nr(x,z,_,s)+nn();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},sn=()=>x.map((t,n)=>{const r=jt(n,z),s=en(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`)}),ln=()=>k.flatMap((t,n)=>{if(!t.marginLeftKey)return[];const r=_[t.marginLeftKey]??0,i=Kt(n),{resolvedWidth:s}=Ft(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)}),an=()=>k.map((t,n)=>{const{maxWidth:r}=Ft(t,"two-row-bottom"),s=rn(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`)}),cn=a.useRef(null),v=a.useRef(null),Dt=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),Ht=a.useRef(0),Xt=a.useRef("forward"),D=a.useRef(0),H=a.useRef(null),V=a.useRef(!1),$=o.length>1&&(!l||!!m),Gt=$?3:1,un=a.useMemo(()=>Array.from({length:Gt},()=>o).flat(),[o,Gt]),[fn,we]=a.useState(!1),[Se,$e]=a.useState(!1),[hn,Vt]=a.useState(!0),Y=a.useRef(null),ot=a.useRef(null),Yt=a.useRef(!1),Le=a.useRef(!1),qt=a.useRef(null),q=a.useRef(null),Te=ft&&!hn,F=a.useCallback(()=>{ft&&(Vt(!0),q.current&&clearTimeout(q.current),q.current=setTimeout(()=>{b.current.isActive||Vt(!1)},Gn))},[ft]),mt=a.useCallback(()=>{l||Le.current||(Le.current=!0,$e(!1),qt.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(En.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"}:{}}}),dn=()=>{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&&Bt(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=>Bt(i,"two-row-bottom")),l&&c.jsxs(c.Fragment,{children:[ln(),an()]})]}):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:tn,width:"100%",flexShrink:0,pointerEvents:l?"auto":"none"}})]}):null]})},mn=()=>c.jsxs(c.Fragment,{children:[(W??0)>0||l?Ie("single-row"):null,x.map(t=>Bt(t,"single-row")),l?c.jsxs(c.Fragment,{children:[on(),sn()]}):null,I?Re():null]}),Ut=a.useCallback(t=>!!(t.closest("[data-controls]")||t.closest(`.${e}-thumbnails`)||t.closest(`.${e}-close-icon`)),[e]),{isSwipeDragging:pn,backdropStyle:gn,mediaAreaStyle:xn,overlayContentStyle:vn,swipeHandlers:bn,dismissAreaStyle:yn}=Z.useLightboxSwipeDismiss({enabled:G??!1,onClose:mt,animMs:xt,isBlockedTarget:Ut}),Zt=()=>{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=Zt();!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<Gt;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},Jt=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&&Jt(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")})},wn=(t,n,r)=>{const i=t-n,s=it(n),h=S.current[s];if(Jt(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]),Qt=a.useCallback((t=!1)=>{t&&(Yt.current=!0),ot.current===null&&(ot.current=requestAnimationFrame(()=>{ot.current=null;const n=Yt.current;Yt.current=!1,je(n)}))},[je]),Sn=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);Et(t),Qt(r||i)},[o.length,$,Qt]),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&&Sn(n)},$n=()=>{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*qn,U(),K(),F(),H.current=requestAnimationFrame(Me)},ke=()=>{const t=Dt.current;t&&(t.style.transition="",t.style.transform="",t.style.willChange="")},_e=(t,n,r,i)=>{ke(),t.scrollLeft=n,Ht.current=t.scrollLeft,U(),r!==void 0?(C.current=r,Et(r)):K(),X(!0),i==null||i()},Ee=(t,{behavior:n="smooth",activeIndex:r,onComplete:i}={})=>{const s=v.current,h=Dt.current;if(!s||!h)return;if(Tt(),pt(),X(!1),n==="auto"){_e(s,t,r,i);return}const d=Math.abs(t-s.scrollLeft),g=zn(d,Dn,Hn,s.clientWidth*.55);rt.current=Bn(s,h,t,{duration:g,easing:Xn,onComplete:()=>{rt.current=null,_e(s,t,r,i)}})},Ln=(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})},Tn=(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(Jt(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 jn=r??d%o.length,Mn=wn(i??s.scrollLeft,t,jn);st(Mn,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}Ln("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,Et(t),Qt(!0),Ee(s.offsetLeft,{behavior:n,activeIndex:t,onComplete:n==="smooth"?$n:void 0}))},Pt=()=>{dt.current&&(window.removeEventListener("pointerup",dt.current),window.removeEventListener("pointercancel",dt.current),dt.current=null)},Rn=(t,n,r,i,s)=>{const h=r-t,d=i-n,g=Math.abs(h),L=Math.abs(d);if(g<Zn||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;Pt();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?Tn(r,"smooth",i,h):(X(!0),K()),F()},In=(t,n)=>{const r=Lt.current;Lt.current=null,r&&(Rn(r.startX,r.startY,t,n,r.startActiveIndex),F())},An=t=>{if(!ht)return;if(t.pointerType==="touch"){if(Tt(),X(!0),Ut(t.target))return;Lt.current={startX:t.clientX,startY:t.clientY,startActiveIndex:C.current};return}if(t.pointerType!=="mouse"||t.button!==0||Ut(t.target))return;const n=v.current;if(!n)return;Tt(),pt(),ke(),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),Pt();const r=i=>{i.pointerType==="mouse"&&Rt(i.pointerId)};dt.current=r,window.addEventListener("pointerup",r),window.addEventListener("pointercancel",r)},Wn=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)>Un&&(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"?In(t.clientX,t.clientY):Lt.current=null;return}t.pointerType==="mouse"&&Rt(t.pointerId)}},Cn=t=>{!ht||t.pointerType!=="mouse"||Rt(t.pointerId)};return Nn.useLightboxScrollLock(),a.useEffect(()=>{const t=requestAnimationFrame(()=>$e(!0));return()=>{cancelAnimationFrame(t),pt(),Pt(),ot.current!==null&&(cancelAnimationFrame(ot.current),ot.current=null),qt.current&&clearTimeout(qt.current),q.current&&clearTimeout(q.current)}},[]),a.useEffect(()=>{if(!ft){Vt(!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(()=>{Zt()},[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?Yn:r.deltaMode===2?t.clientHeight:1,s=r.deltaY*i*Vn;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-Ht.current;Ht.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!==Xt.current&&(Xt.current=d,Ce(d))}b.current.isActive&&b.current.hasMoved||K()};t.addEventListener("scroll",n,{passive:!0});const r=new ResizeObserver(()=>{Zt(),U(b.current.isActive),Ce(Xt.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:()=>{pn||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,...gn}}),c.jsxs("div",{ref:cn,className:`${e}-lightbox-dismiss-area`,style:yn,...bn,children:[c.jsx("div",{className:`${e}-lightbox-content`,style:xn,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":fn?"true":"false",onPointerDown:An,onPointerMove:Wn,onPointerUp:Ne,onPointerCancel:Ne,onLostPointerCapture:Cn,children:c.jsx("div",{ref:Dt,className:`${e}-lightbox-strip-track`,style:{gap:ut},children:un.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:vn,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:Ze,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?dn():ve||I?mn():null})})})]}),o.length>1&&ct==="on"&&(()=>{const t=Ct(_t),n=`calc(-0.5 * (${_t} + ${t}))`;return c.jsx("div",{className:`${e}-thumbnails-wrap`,style:{bottom:_t},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":Ge,style:{gap:kt,"--thumbnail-active-color":Ve},children:[o.map((r,i)=>{const s=Ct(kt),h=`calc(-0.5 * (${s} + ${kt}))`;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:()=>Qe&&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:{...Pe,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}})]})})})})()]})]})},ne=400,re="cubic-bezier(0.25, 0.1, 0.25, 1)",or=1.1;function ir(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
|
+
@property --${e}-hover-zoom {
|
|
47
|
+
syntax: '<number>';
|
|
48
|
+
inherits: false;
|
|
49
|
+
initial-value: 1;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.${e}-hover-zoom-in .${e}-cover-image {
|
|
53
|
+
transform: scale(var(--${e}-hover-zoom));
|
|
54
|
+
clip-path: inset(calc(50% - 50% / var(--${e}-hover-zoom)));
|
|
55
|
+
transition: --${e}-hover-zoom ${ne}ms ${re};
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.${e}-hover-scale-down .${e}-cover-image {
|
|
59
|
+
transition: transform ${ne}ms ${re};
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.${e}-hover-greyscale .${e}-cover-image {
|
|
63
|
+
transition: filter ${ne}ms ${re};
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
@media (hover: hover) {
|
|
67
|
+
.${e}-hover-zoom-in .${e}-cover:hover .${e}-cover-image {
|
|
68
|
+
--${e}-hover-zoom: ${or};
|
|
69
|
+
}
|
|
70
|
+
.${e}-hover-scale-down .${e}-cover:hover .${e}-cover-image {
|
|
71
|
+
transform: scale(0.9);
|
|
72
|
+
}
|
|
73
|
+
.${e}-hover-greyscale .${e}-cover:hover .${e}-cover-image {
|
|
74
|
+
filter: grayscale(1);
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.${e}-lightbox {
|
|
79
|
+
position: fixed;
|
|
80
|
+
inset: 0;
|
|
81
|
+
z-index: 9997;
|
|
82
|
+
display: flex;
|
|
83
|
+
flex-direction: column;
|
|
84
|
+
align-items: center;
|
|
85
|
+
justify-content: center;
|
|
86
|
+
overscroll-behavior: none;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.${e}-lightbox-editor {
|
|
90
|
+
inset: auto;
|
|
91
|
+
top: var(--cntrl-article-top, 0);
|
|
92
|
+
left: var(--cntrl-article-left, 0);
|
|
93
|
+
width: var(--cntrl-article-width, 100vw) !important;
|
|
94
|
+
height: var(--cntrl-viewport-height, 100vh) !important;
|
|
95
|
+
overflow: hidden;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.${e}-lightbox-edit-mode {
|
|
99
|
+
z-index: 1;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.${e}-lightbox-edit-mode .${e}-lightbox-strip {
|
|
103
|
+
overflow-x: hidden;
|
|
104
|
+
touch-action: none;
|
|
105
|
+
scroll-snap-type: none;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.${e}-lightbox-content {
|
|
109
|
+
position: relative;
|
|
110
|
+
z-index: 1;
|
|
111
|
+
display: flex;
|
|
112
|
+
flex-direction: column;
|
|
113
|
+
align-items: center;
|
|
114
|
+
justify-content: center;
|
|
115
|
+
width: 100%;
|
|
116
|
+
height: 100%;
|
|
117
|
+
box-sizing: border-box;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.${e}-lightbox-backdrop {
|
|
121
|
+
position: absolute;
|
|
122
|
+
inset: 0;
|
|
123
|
+
pointer-events: none;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.${e}-lightbox-dismiss-area {
|
|
127
|
+
position: relative;
|
|
128
|
+
width: 100%;
|
|
129
|
+
height: 100%;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.${e}-lightbox-strip {
|
|
133
|
+
position: relative;
|
|
134
|
+
flex: 1;
|
|
135
|
+
width: 100%;
|
|
136
|
+
min-height: 0;
|
|
137
|
+
max-width: 100%;
|
|
138
|
+
overflow-x: auto;
|
|
139
|
+
scroll-snap-type: x mandatory;
|
|
140
|
+
box-sizing: border-box;
|
|
141
|
+
touch-action: pan-x;
|
|
142
|
+
scrollbar-width: none;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.${e}-lightbox-strip-track {
|
|
146
|
+
display: flex;
|
|
147
|
+
flex-direction: row;
|
|
148
|
+
flex-wrap: nowrap;
|
|
149
|
+
align-items: center;
|
|
150
|
+
height: 100%;
|
|
151
|
+
min-width: min-content;
|
|
152
|
+
backface-visibility: hidden;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.${e}-lightbox-strip[data-mouse-dragging="true"] {
|
|
156
|
+
scroll-snap-type: none;
|
|
157
|
+
cursor: grabbing;
|
|
158
|
+
user-select: none;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.${e}-lightbox-strip[data-mouse-draggable="true"] {
|
|
162
|
+
cursor: grab;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.${e}-lightbox-strip::-webkit-scrollbar {
|
|
166
|
+
display: none;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.${e}-strip-item {
|
|
170
|
+
position: relative;
|
|
171
|
+
flex: 0 0 auto;
|
|
172
|
+
height: 100%;
|
|
173
|
+
scroll-snap-align: start;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.${e}-strip-item img {
|
|
177
|
+
user-select: none;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.${e}-thumbnails-wrap {
|
|
181
|
+
position: absolute;
|
|
182
|
+
left: 16px;
|
|
183
|
+
right: 16px;
|
|
184
|
+
z-index: 2;
|
|
185
|
+
pointer-events: auto;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.${e}-thumbnails {
|
|
189
|
+
width: 100%;
|
|
190
|
+
overflow-x: auto;
|
|
191
|
+
scrollbar-width: none;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
.${e}-thumbnails-track {
|
|
195
|
+
display: flex;
|
|
196
|
+
flex-direction: row;
|
|
197
|
+
flex-wrap: nowrap;
|
|
198
|
+
align-items: flex-end;
|
|
199
|
+
justify-content: center;
|
|
200
|
+
width: max-content;
|
|
201
|
+
min-width: 100%;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
.${e}-lightbox-editor.${e}-lightbox-edit-mode .${e}-thumbnails {
|
|
205
|
+
overflow: visible;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
.${e}-thumbnails::-webkit-scrollbar {
|
|
209
|
+
display: none;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
.${e}-thumb {
|
|
213
|
+
flex: 0 0 auto;
|
|
214
|
+
display: flex;
|
|
215
|
+
align-items: center;
|
|
216
|
+
justify-content: center;
|
|
217
|
+
padding: 0;
|
|
218
|
+
border: none;
|
|
219
|
+
background: transparent;
|
|
220
|
+
cursor: pointer;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
.${e}-thumbnails-track[data-thumbnail-active="outline"] .${e}-thumb .${e}-thumb-image {
|
|
224
|
+
box-sizing: border-box;
|
|
225
|
+
border: 2px solid transparent;
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
.${e}-thumbnails-track[data-thumbnail-active="outline"] .${e}-thumb[data-active="true"] .${e}-thumb-image {
|
|
229
|
+
border-color: var(--thumbnail-active-color, #ffffff);
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
.${e}-thumbnails-track[data-thumbnail-active="color"] .${e}-thumb:not([data-active="true"]) .${e}-thumb-image {
|
|
233
|
+
filter: grayscale(1);
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
.${e}-thumbnails-track[data-thumbnail-active="scale-up"] .${e}-thumb[data-active="true"] {
|
|
237
|
+
transform: scale(1.15);
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
.${e}-thumb-image {
|
|
241
|
+
display: block;
|
|
242
|
+
object-fit: contain;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
.${e}-thumb-image-cover {
|
|
246
|
+
aspect-ratio: var(--image-aspect-ratio);
|
|
247
|
+
width: auto;
|
|
248
|
+
height: auto;
|
|
249
|
+
object-fit: cover;
|
|
250
|
+
}
|
|
251
|
+
.${e}-close-icon {
|
|
252
|
+
position: relative;
|
|
253
|
+
flex-shrink: 0;
|
|
254
|
+
grid-area: close;
|
|
255
|
+
pointer-events: auto;
|
|
256
|
+
z-index: 2;
|
|
257
|
+
display: flex;
|
|
258
|
+
align-items: center;
|
|
259
|
+
justify-content: center;
|
|
260
|
+
border: none;
|
|
261
|
+
background-color: transparent;
|
|
262
|
+
padding: 0;
|
|
263
|
+
opacity: 1;
|
|
264
|
+
transition: opacity ${xt}ms ease;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
.${e}-close-icon[data-overlay-content-hidden="true"] {
|
|
268
|
+
opacity: 0;
|
|
269
|
+
pointer-events: none;
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
.${e}-close-icon-inner {
|
|
273
|
+
all: unset;
|
|
274
|
+
position: relative;
|
|
275
|
+
cursor: pointer;
|
|
276
|
+
width: 100%;
|
|
277
|
+
height: 100%;
|
|
278
|
+
pointer-events: auto;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
.${e}-close-icon-img {
|
|
282
|
+
position: absolute;
|
|
283
|
+
top: 50%;
|
|
284
|
+
left: 50%;
|
|
285
|
+
transform: translate(-50%, -50%);
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
.${e}-header {
|
|
289
|
+
position: relative;
|
|
290
|
+
display: grid;
|
|
291
|
+
flex: 1;
|
|
292
|
+
width: 100%;
|
|
293
|
+
min-width: 0;
|
|
294
|
+
z-index: 2;
|
|
295
|
+
box-sizing: border-box;
|
|
296
|
+
pointer-events: none;
|
|
297
|
+
word-break: break-word;
|
|
298
|
+
align-items: center;
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
.${e}-header-single-row {
|
|
302
|
+
grid-template-columns: auto auto auto auto 1fr auto;
|
|
303
|
+
grid-template-areas: "margin title1 title2 title3 . close";
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
.${e}-header-two-row {
|
|
307
|
+
height: 100%;
|
|
308
|
+
align-self: stretch;
|
|
309
|
+
display: flex;
|
|
310
|
+
flex-direction: column;
|
|
311
|
+
width: 100%;
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
.${e}-header-row-top {
|
|
315
|
+
display: flex;
|
|
316
|
+
flex-direction: row;
|
|
317
|
+
align-items: center;
|
|
318
|
+
width: 100%;
|
|
319
|
+
flex-shrink: 0;
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
.${e}-header-row-top .${e}-title-cell[data-title="title1"] {
|
|
323
|
+
flex: 0 0 auto;
|
|
324
|
+
min-width: 0;
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
.${e}-header-row-top .${e}-close-icon {
|
|
328
|
+
flex-shrink: 0;
|
|
329
|
+
margin-left: auto;
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
.${e}-header-row-bottom-wrap {
|
|
333
|
+
display: flex;
|
|
334
|
+
flex-direction: column;
|
|
335
|
+
width: 100%;
|
|
336
|
+
margin-top: auto;
|
|
337
|
+
flex-shrink: 0;
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
.${e}-header-row-bottom {
|
|
341
|
+
position: relative;
|
|
342
|
+
display: flex;
|
|
343
|
+
flex-direction: row;
|
|
344
|
+
align-items: flex-end;
|
|
345
|
+
width: 100%;
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
.${e}-header-row-bottom .${e}-title-cell {
|
|
349
|
+
flex: 0 0 auto;
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
.${e}-title-cell {
|
|
353
|
+
position: relative;
|
|
354
|
+
flex: 0 0 auto;
|
|
355
|
+
min-width: 0;
|
|
356
|
+
box-sizing: border-box;
|
|
357
|
+
}
|
|
358
|
+
.${e}-title1,
|
|
359
|
+
.${e}-title2,
|
|
360
|
+
.${e}-title3 {
|
|
361
|
+
margin: 0;
|
|
362
|
+
min-width: 0;
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
.${e}-title-resize-handle {
|
|
366
|
+
background: transparent;
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
.${e}-lightbox-content-inner {
|
|
370
|
+
position: absolute;
|
|
371
|
+
inset: 0;
|
|
372
|
+
z-index: 2;
|
|
373
|
+
pointer-events: none;
|
|
374
|
+
display: flex;
|
|
375
|
+
flex-direction: column;
|
|
376
|
+
opacity: 1;
|
|
377
|
+
transition: opacity ${xt}ms ease;
|
|
378
|
+
}
|
|
379
|
+
|
|
380
|
+
.${e}-lightbox-content-inner[data-overlay-content-hidden="true"] {
|
|
381
|
+
opacity: 0;
|
|
382
|
+
pointer-events: none;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
.${e}-lightbox-content-area {
|
|
386
|
+
position: relative;
|
|
387
|
+
display: flex;
|
|
388
|
+
flex-direction: row;
|
|
389
|
+
flex: 1;
|
|
390
|
+
min-width: 0;
|
|
391
|
+
min-height: 0;
|
|
392
|
+
align-items: flex-start;
|
|
393
|
+
}
|
|
394
|
+
|
|
395
|
+
.${e}-lightbox-content-area-stacked {
|
|
396
|
+
align-items: stretch;
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
.${e}-control {
|
|
400
|
+
position: relative;
|
|
401
|
+
z-index: 2;
|
|
402
|
+
pointer-events: auto;
|
|
403
|
+
flex-shrink: 0;
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
.${e}-control::before {
|
|
407
|
+
content: "";
|
|
408
|
+
position: absolute;
|
|
409
|
+
top: 0;
|
|
410
|
+
left: 0;
|
|
411
|
+
width: 100%;
|
|
412
|
+
height: 100%;
|
|
413
|
+
min-width: 20px;
|
|
414
|
+
min-height: 20px;
|
|
415
|
+
pointer-events: auto;
|
|
416
|
+
z-index: 10;
|
|
417
|
+
}
|
|
418
|
+
`}const sr=({settings:e,content:o,isEditor:u,isEditMode:f,isPreviewMode:l,portalId:m})=>{const{prefix:p}=_n.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:ir(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(rr,{prefix:p,images:A,settings:e,isEditor:u,isEditMode:f,isPreviewMode:l,onClose:()=>O(!1)}),ct)})()]})};exports.LightboxStrip=sr;exports.STRIP_TEXT_STYLE_PREFIXES=Fe;exports.STRIP_TEXT_STYLE_TAB_LABELS=Ke;exports.createStripTextStylePanelTab=tr;exports.createStripTextStyleTabContentItems=He;exports.extractTitlesFromLegacyText=Be;exports.getStripTextStyleSettingKey=E;exports.resolveStripItemTitles=De;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),a=require("react"),_e=require("react-dom"),lt=require("./scalingValue-CSHYgTZl.js"),Be=require("./buildColorVars-CE2D5cQV.js"),Ge=require("./useScopedStyles-Bf6yohVQ.js"),gt=require("./EmbedMediaFrame-DsOTKE4i.js"),bt=require("./textStylesToCss-CNN3zZTV.js"),qe=require("./SvgImage-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),a=require("react"),_e=require("react-dom"),lt=require("./scalingValue-CSHYgTZl.js"),Be=require("./buildColorVars-CE2D5cQV.js"),Ge=require("./useScopedStyles-Bf6yohVQ.js"),gt=require("./EmbedMediaFrame-DsOTKE4i.js"),bt=require("./textStylesToCss-CNN3zZTV.js"),qe=require("./SvgImage-DFlmxAoL.js"),Ke=require("./LazyVideo-imbU18js.js"),wt=300/1440,Ue=8/1440,rt=.004;function Xe(t){return`calc(var(--cntrl-article-width, 100vw) * ${t/1440})`}function Pt(t,e,o,r){return e!==void 0&&e<(t??.01)?`${o} ${r}`:o}function te(t,e,o,r,l="title-leading-gap"){const c=t??.01;return e===void 0||e>=c?{}:{[`--${o}-${l}`]:lt.scalingValue((c-e)/2,r)}}function Ye(t){return`
|
|
2
2
|
.${t}-wrapper {
|
|
3
3
|
box-sizing: border-box;
|
|
4
4
|
display: flex;
|
|
@@ -6,7 +6,7 @@ import { b as Qe } from "./buildColorVars-CLyWQm5K.mjs";
|
|
|
6
6
|
import { u as Pe } from "./useScopedStyles-DhBG3557.mjs";
|
|
7
7
|
import { i as ae, E as Ae, g as tn, a as en } from "./EmbedMediaFrame-DwHeOAy5.mjs";
|
|
8
8
|
import { o as ne, t as oe } from "./textStylesToCss-05Mn6I_2.mjs";
|
|
9
|
-
import { S as nn } from "./SvgImage-
|
|
9
|
+
import { S as nn } from "./SvgImage-B5mR9y6q.mjs";
|
|
10
10
|
import { L as on } from "./LazyVideo-CdAWymKO.mjs";
|
|
11
11
|
const Tt = 300 / 1440, rn = 8 / 1440, ct = 4e-3;
|
|
12
12
|
function ln(t) {
|
|
@@ -5,7 +5,7 @@ import { b as Lo } from "./buildColorVars-CLyWQm5K.mjs";
|
|
|
5
5
|
import { g as D } from "./formFieldValidation-DvihFrq5.mjs";
|
|
6
6
|
import { u as Mo } from "./useScopedStyles-DhBG3557.mjs";
|
|
7
7
|
import { o as A, t as L } from "./textStylesToCss-05Mn6I_2.mjs";
|
|
8
|
-
import { S as No } from "./SvgImage-
|
|
8
|
+
import { S as No } from "./SvgImage-B5mR9y6q.mjs";
|
|
9
9
|
function k(o) {
|
|
10
10
|
return `calc(var(--cntrl-article-width, 100vw) * ${o / 1440})`;
|
|
11
11
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),C=require("react"),l=require("./scalingValue-CSHYgTZl.js"),Vo=require("./buildColorVars-CE2D5cQV.js"),U=require("./formFieldValidation-DZl2KVaF.js"),Wo=require("./useScopedStyles-Bf6yohVQ.js"),m=require("./textStylesToCss-CNN3zZTV.js"),jo=require("./SvgImage-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),C=require("react"),l=require("./scalingValue-CSHYgTZl.js"),Vo=require("./buildColorVars-CE2D5cQV.js"),U=require("./formFieldValidation-DZl2KVaF.js"),Wo=require("./useScopedStyles-Bf6yohVQ.js"),m=require("./textStylesToCss-CNN3zZTV.js"),jo=require("./SvgImage-DFlmxAoL.js");function k(o){return`calc(var(--cntrl-article-width, 100vw) * ${o/1440})`}function zo(o){return`
|
|
2
2
|
.${o}-wrapper {
|
|
3
3
|
display: flex;
|
|
4
4
|
flex-direction: column;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as c, jsxs as x, Fragment as R } from "react/jsx-runtime";
|
|
2
2
|
import { useMemo as po } from "react";
|
|
3
|
-
import { S as uo } from "./SvgImage-
|
|
3
|
+
import { S as uo } from "./SvgImage-B5mR9y6q.mjs";
|
|
4
4
|
import { s as t } from "./scalingValue-C9JH5L6O.mjs";
|
|
5
5
|
import { b as mo } from "./buildColorVars-CLyWQm5K.mjs";
|
|
6
6
|
import { u as xo } from "./useScopedStyles-DhBG3557.mjs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),bo=require("react"),uo=require("./SvgImage-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),bo=require("react"),uo=require("./SvgImage-DFlmxAoL.js"),t=require("./scalingValue-CSHYgTZl.js"),po=require("./buildColorVars-CE2D5cQV.js"),xo=require("./useScopedStyles-Bf6yohVQ.js"),Y=require("./textStylesToCss-CNN3zZTV.js"),go={backgroundColor:"background-color",textColor:"text-color",borderColor:"border-color",iconColor:"icon-color",boxShadowColor:"box-shadow-color",innerBoxShadowColor:"inner-box-shadow-color"},mo=["hover","active"],N={left:"flex-start",center:"center",right:"flex-end"};function wo(o,e){const a=o.currentTarget,l=a.getBoundingClientRect(),c=o.clientY-l.top>l.height/2;a.classList.toggle(`${e}-reveal-from-bottom`,c)}function yo(o,e){const a=o.currentTarget,l=a.getBoundingClientRect(),c=o.clientY<l.top+l.height/2;a.classList.toggle(`${e}-reveal-from-bottom`,c)}function ko(o){const e=`var(--${o}-box-shadow-x, 0) var(--${o}-box-shadow-y, 0) var(--${o}-box-shadow-blur, 0) var(--${o}-box-shadow-spread, 0) var(--${o}-box-shadow-color, transparent)`,a=`inset var(--${o}-inner-box-shadow-x, 0) var(--${o}-inner-box-shadow-y, 0) var(--${o}-inner-box-shadow-blur, 0) var(--${o}-inner-box-shadow-spread, 0) var(--${o}-inner-box-shadow-color, transparent)`,l=`${e}, ${a}`,c=`var(--${o}-box-shadow-x, 0) var(--${o}-box-shadow-y, 0) var(--${o}-box-shadow-blur, 0) var(--${o}-box-shadow-spread, 0) var(--${o}-hover-box-shadow-color, var(--${o}-box-shadow-color, transparent))`,r=`inset var(--${o}-inner-box-shadow-x, 0) var(--${o}-inner-box-shadow-y, 0) var(--${o}-inner-box-shadow-blur, 0) var(--${o}-inner-box-shadow-spread, 0) var(--${o}-hover-inner-box-shadow-color, var(--${o}-inner-box-shadow-color, transparent))`,$=`${c}, ${r}`,s=`var(--${o}-box-shadow-x, 0) var(--${o}-box-shadow-y, 0) var(--${o}-box-shadow-blur, 0) var(--${o}-box-shadow-spread, 0) var(--${o}-active-box-shadow-color, var(--${o}-box-shadow-color, transparent))`,h=`inset var(--${o}-inner-box-shadow-x, 0) var(--${o}-inner-box-shadow-y, 0) var(--${o}-inner-box-shadow-blur, 0) var(--${o}-inner-box-shadow-spread, 0) var(--${o}-active-inner-box-shadow-color, var(--${o}-inner-box-shadow-color, transparent))`,p=`${s}, ${h}`,g=`0 4px 12px rgba(0, 0, 0, 0.15), ${a}`,C=`.${o}-button:focus-visible, a:focus-visible .${o}-button`,V=`.${o}-button:hover, ${C}`,v=f=>`.${o}-hover-effect-${f}:hover, .${o}-hover-effect-${f}:focus-visible, a:focus-visible .${o}-hover-effect-${f}`;return`
|
|
2
2
|
.${o}-root {
|
|
3
3
|
line-height: 0;
|
|
4
4
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),l=require("react"),g=require("classnames"),Ze=require("./RichTextRenderer-DEFXh5o6.js"),S=require("./scalingValue-CSHYgTZl.js"),Re=require("./SvgImage-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),l=require("react"),g=require("classnames"),Ze=require("./RichTextRenderer-DEFXh5o6.js"),S=require("./scalingValue-CSHYgTZl.js"),Re=require("./SvgImage-DFlmxAoL.js"),Je=require("./textStylesToCss-CNN3zZTV.js"),Qe=require("./useScopedStyles-Bf6yohVQ.js"),H=500,De="cubic-bezier(0.25, 1, 0.5, 1)",Pe=300,et=5,tt=.15,ot=.4,rt=100,Y=100,Ne={color:"#000000",hover:"#cccccc"},U={offset:{x:0,y:0},colors:{pagination:"#cccccc",inactive:"#cccccc",background:"#000000"}},nt={s:{paddingY:5,paddingActive:5,borderRadius:9,dot:4,activeDot:8,gapInactive:9,inset:5},m:{paddingY:7,paddingActive:7,borderRadius:17,dot:8,activeDot:20,gapInactive:22,inset:7},l:{paddingY:10,paddingActive:10,borderRadius:29,dot:20,activeDot:38,gapInactive:26,inset:10}},pe={offset:{x:0,y:0},linkColor:"#cccccc"},je={sizeType:"drag",value:3},at="left";function it(e,i){var b,f;const n={fontSettings:{fontFamily:(e==null?void 0:e.titleFontFamily)??"Arial",fontWeight:((b=e==null?void 0:e.titleFontSettings)==null?void 0:b.fontWeight)??400,fontStyle:((f=e==null?void 0:e.titleFontSettings)==null?void 0:f.fontStyle)??"normal"},fontSize:(e==null?void 0:e.titleFontSize)??.02,lineHeight:(e==null?void 0:e.titleLineHeight)??.02,letterSpacing:(e==null?void 0:e.titleLetterSpacing)??0,wordSpacing:(e==null?void 0:e.titleWordSpacing)??0,textAppearance:e==null?void 0:e.titleTextAppearance,textAlign:at,color:(e==null?void 0:e.titleColor)??"#000000"};return Je.textStylesToCss(n,i)}function V(e,i,n){return`${e}: ${S.scalingValue(i/1440,n)};`}function E(e,i){return i<=0?0:(e%i+i)%i}function ct(e,i,n,b){if(!b)return{position:E(e+i,n),hitBoundary:!1};const f=e+i;return f>=0&&f<=n+1?{position:f,hitBoundary:!1}:{position:i>0?n+1:0,hitBoundary:!0}}function lt(e,i){const n=new DOMMatrixReadOnly(window.getComputedStyle(e).transform);return i?n.m41:n.m42}function st(e,i){const n=document.createElement("div");n.className=i,n.setAttribute("aria-hidden","true"),e.appendChild(n);const b=(X,J)=>{n.style.transform=`translate(${X}px, ${J}px)`;const B=n.getBoundingClientRect();return{x:B.left,y:B.top}},f=b(0,0),r=b(Y,0),K=b(0,Y);e.removeChild(n);const C={x:(r.x-f.x)/Y,y:(r.y-f.y)/Y},s={x:(K.x-f.x)/Y,y:(K.y-f.y)/Y},Z=C.x*s.y-s.x*C.y;return{ex:C,ey:s,det:Z}}function dt(e,i,n){const{ex:b,ey:f,det:r}=e;return{x:(i*f.y-n*f.x)/r,y:(b.x*n-b.y*i)/r}}function ut(e,i){return`
|
|
2
2
|
.${e}-wrapper {
|
|
3
3
|
position: relative;
|
|
4
4
|
width: 100%;
|
|
@@ -3,7 +3,7 @@ import { useState as D, useRef as k, useCallback as E, useEffect as B } from "re
|
|
|
3
3
|
import x from "classnames";
|
|
4
4
|
import { R as te } from "./RichTextRenderer-D52Xto59.mjs";
|
|
5
5
|
import { s as C } from "./scalingValue-C9JH5L6O.mjs";
|
|
6
|
-
import { S as Oo } from "./SvgImage-
|
|
6
|
+
import { S as Oo } from "./SvgImage-B5mR9y6q.mjs";
|
|
7
7
|
import { t as re } from "./textStylesToCss-05Mn6I_2.mjs";
|
|
8
8
|
import { u as ne } from "./useScopedStyles-DhBG3557.mjs";
|
|
9
9
|
const j = 500, Ho = "cubic-bezier(0.25, 1, 0.5, 1)", ae = 300, ie = 5, ce = 0.15, le = 0.4, se = 100, W = 100, _o = {
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import { useState as l, useEffect as u } from "react";
|
|
3
|
+
import g from "classnames";
|
|
4
|
+
import { i as p, l as k } from "./loadSvgMaskUrl-xHgGYgPe.mjs";
|
|
5
|
+
const v = "SvgImage-module__svg___q3xE-", C = "SvgImage-module__img___VsTm-", c = {
|
|
6
|
+
svg: v,
|
|
7
|
+
img: C
|
|
8
|
+
}, w = (s) => {
|
|
9
|
+
const e = s.trim().toLowerCase();
|
|
10
|
+
return !!(e.startsWith("data:image/svg+xml") || e.includes("image/svg+xml") || e.includes(".svg") || e.startsWith("blob:"));
|
|
11
|
+
}, _ = (s) => `url("${s.replace(/\\/g, "\\\\").replace(/"/g, '\\"')}")`, x = ({ url: s, fill: e = "#000000", hoverFill: f = "#CCCCCC", className: a = "", style: i }) => {
|
|
12
|
+
const [n, d] = l(() => typeof window > "u" ? !0 : CSS.supports("mask-image", 'url("")') || CSS.supports("-webkit-mask-image", 'url("")')), [o, r] = l(() => p(s) ? s : null);
|
|
13
|
+
return u(() => {
|
|
14
|
+
if (typeof window < "u" && window.CSS) {
|
|
15
|
+
const t = CSS.supports("mask-image", 'url("")') || CSS.supports("-webkit-mask-image", 'url("")');
|
|
16
|
+
d(t);
|
|
17
|
+
}
|
|
18
|
+
}, []), u(() => {
|
|
19
|
+
if (!w(s)) {
|
|
20
|
+
r(null);
|
|
21
|
+
return;
|
|
22
|
+
}
|
|
23
|
+
if (p(s)) {
|
|
24
|
+
r(s);
|
|
25
|
+
return;
|
|
26
|
+
}
|
|
27
|
+
let t = !1;
|
|
28
|
+
return k(s).then((S) => {
|
|
29
|
+
t || r(S);
|
|
30
|
+
}).catch(() => {
|
|
31
|
+
t || r(null);
|
|
32
|
+
}), () => {
|
|
33
|
+
t = !0;
|
|
34
|
+
};
|
|
35
|
+
}, [s]), !o || !n ? /* @__PURE__ */ m("img", { src: s, alt: "", className: g(c.img, a), style: i }) : /* @__PURE__ */ m(
|
|
36
|
+
"span",
|
|
37
|
+
{
|
|
38
|
+
"data-supports-mask": n,
|
|
39
|
+
className: g(c.svg, a),
|
|
40
|
+
style: {
|
|
41
|
+
"--svg": _(o),
|
|
42
|
+
"--fill": e,
|
|
43
|
+
"--hover-fill": f,
|
|
44
|
+
...i ?? {}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
);
|
|
48
|
+
};
|
|
49
|
+
export {
|
|
50
|
+
x as S
|
|
51
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const g=require("react/jsx-runtime"),a=require("react"),c=require("classnames"),n=require("./loadSvgMaskUrl-DfF7ay6h.js"),d="SvgImage-module__svg___q3xE-",k="SvgImage-module__img___VsTm-",m={svg:d,img:k},v=e=>{const s=e.trim().toLowerCase();return!!(s.startsWith("data:image/svg+xml")||s.includes("image/svg+xml")||s.includes(".svg")||s.startsWith("blob:"))},C=e=>`url("${e.replace(/\\/g,"\\\\").replace(/"/g,'\\"')}")`,w=({url:e,fill:s="#000000",hoverFill:f="#CCCCCC",className:i="",style:u})=>{const[l,p]=a.useState(()=>typeof window>"u"?!0:CSS.supports("mask-image",'url("")')||CSS.supports("-webkit-mask-image",'url("")')),[o,r]=a.useState(()=>n.isInlineMaskUrl(e)?e:null);return a.useEffect(()=>{if(typeof window<"u"&&window.CSS){const t=CSS.supports("mask-image",'url("")')||CSS.supports("-webkit-mask-image",'url("")');p(t)}},[]),a.useEffect(()=>{if(!v(e)){r(null);return}if(n.isInlineMaskUrl(e)){r(e);return}let t=!1;return n.loadSvgMaskUrl(e).then(S=>{t||r(S)}).catch(()=>{t||r(null)}),()=>{t=!0}},[e]),!o||!l?g.jsx("img",{src:e,alt:"",className:c(m.img,i),style:u}):g.jsx("span",{"data-supports-mask":l,className:c(m.svg,i),style:{"--svg":C(o),"--fill":s,"--hover-fill":f,...u??{}}})};exports.SvgImage=w;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),j=require("classnames"),o=require("react"),E=require("./RichTextRenderer-DEFXh5o6.js"),u=require("./scalingValue-CSHYgTZl.js"),X=require("./SvgImage-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),j=require("classnames"),o=require("react"),E=require("./RichTextRenderer-DEFXh5o6.js"),u=require("./scalingValue-CSHYgTZl.js"),X=require("./SvgImage-DFlmxAoL.js"),ue=require("./useScopedStyles-Bf6yohVQ.js"),de=require("./readTestimonialTextMeasure-CEPaB4Sy.js"),G=require("./textStylesToCss-CNN3zZTV.js");function he(e){return`
|
|
2
2
|
.${e}-container {
|
|
3
3
|
position: relative;
|
|
4
4
|
overflow-x: clip;
|
|
@@ -3,7 +3,7 @@ import b from "classnames";
|
|
|
3
3
|
import { useState as w, useRef as U, useMemo as Y, useEffect as R, useCallback as N, useLayoutEffect as pe } from "react";
|
|
4
4
|
import { R as Z } from "./RichTextRenderer-D52Xto59.mjs";
|
|
5
5
|
import { s } from "./scalingValue-C9JH5L6O.mjs";
|
|
6
|
-
import { S as E } from "./SvgImage-
|
|
6
|
+
import { S as E } from "./SvgImage-B5mR9y6q.mjs";
|
|
7
7
|
import { u as ve } from "./useScopedStyles-DhBG3557.mjs";
|
|
8
8
|
import { r as we } from "./readTestimonialTextMeasure-BIXpGFEt.mjs";
|
|
9
9
|
import { t as P } from "./textStylesToCss-05Mn6I_2.mjs";
|
|
@@ -8,7 +8,7 @@ import { g as dn, a as hn } from "./getImageRect-CBMhFNHM.mjs";
|
|
|
8
8
|
import { L as pn } from "./LazyVideo-CdAWymKO.mjs";
|
|
9
9
|
import { t as gn } from "./textStylesToCss-05Mn6I_2.mjs";
|
|
10
10
|
import { u as mn } from "./useLazyVideos-CxXyEjRQ.mjs";
|
|
11
|
-
import { H as wn } from "./HiveLightboxTitles-
|
|
11
|
+
import { H as wn } from "./HiveLightboxTitles-DhEeFKWs.mjs";
|
|
12
12
|
function vn(t) {
|
|
13
13
|
return `
|
|
14
14
|
.${t}-titles-row {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),o=require("react"),tn=require("react-dom"),Qe=require("./scalingValue-CSHYgTZl.js"),nn=require("./useScopedStyles-Bf6yohVQ.js"),_=require("./EmbedMediaFrame-DsOTKE4i.js"),zt=require("./getImageRect-BQhQXvT8.js"),rn=require("./LazyVideo-imbU18js.js"),on=require("./textStylesToCss-CNN3zZTV.js"),an=require("./useLazyVideos-CdCbc2j0.js"),ln=require("./HiveLightboxTitles-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),o=require("react"),tn=require("react-dom"),Qe=require("./scalingValue-CSHYgTZl.js"),nn=require("./useScopedStyles-Bf6yohVQ.js"),_=require("./EmbedMediaFrame-DsOTKE4i.js"),zt=require("./getImageRect-BQhQXvT8.js"),rn=require("./LazyVideo-imbU18js.js"),on=require("./textStylesToCss-CNN3zZTV.js"),an=require("./useLazyVideos-CdCbc2j0.js"),ln=require("./HiveLightboxTitles-DlyptAaK.js");function sn(e){return`
|
|
2
2
|
.${e}-titles-row {
|
|
3
3
|
position: relative;
|
|
4
4
|
flex: 0 1 auto;
|