quirk-ui 0.0.510 → 0.0.513

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.
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../../assets/index23.css');const r=require("react/jsx-runtime"),n=require("react"),bt=require("../../../arrow-left-4E3t8axP.cjs"),Ct=require("../../../arrow-right-DO6S4vfx.cjs"),$t="_carousel_pig9v_1",St="_noPointerEvents_pig9v_10",Et="_trackContainer_pig9v_14",yt="_track_pig9v_14",Xt="_isMounted_pig9v_28",It="_page_pig9v_33",jt="_controls_pig9v_43",kt="_indicators_pig9v_54",Nt="_indicator_pig9v_54",Rt="_active_pig9v_71",Tt="_buttons_pig9v_75",Wt="_prev_pig9v_80",Lt="_disabled_pig9v_80",At="_next_pig9v_81",c={carousel:$t,noPointerEvents:St,trackContainer:Et,track:yt,isMounted:Xt,page:It,controls:jt,indicators:kt,indicator:Nt,active:Rt,buttons:Tt,prev:Wt,disabled:Lt,next:At};function Dt({items:M,itemsPerPage:d=9,itemsPerRow:F=3,autoplay:J=!1,autoplayInterval:W=3,className:K,externalRef:Q,siblingRef:h,isSplit:L=!1}){const[f,v]=n.useState(0),[a,C]=n.useState(0),[p,y]=n.useState(0),[i,Z]=n.useState(d),[g,tt]=n.useState(!1),[A,et]=n.useState(J),[$,nt]=n.useState(!1),[st,ot]=n.useState(!1),ct=n.useRef(null),u=n.useRef(null),w=n.useRef(null),S=Q,[m,X]=n.useState(!1),[D,P]=n.useState(null),[E,q]=n.useState(null),[z,Y]=n.useState(null),[rt,B]=n.useState(!1),[x,O]=n.useState(null),[I,U]=n.useState(null),at=t=>{Math.abs((I??0)-(x??0))>25&&(t.stopPropagation(),t.preventDefault())},it=t=>{O(t.clientX)},lt=t=>{x!==null&&Math.abs(t.clientX-x)>5&&(B(!0),U(t.clientX))},ut=()=>{if(!x||!I){j();return}const t=x-I;Math.abs(t)>50&&(t>0?R():T()),j()},dt=()=>{j()},j=()=>{B(!1),O(null),U(null)},ht=t=>{q(t.touches[0].clientX),P(t.touches[0].clientY),X(!1)},G=n.useRef(null);n.useEffect(()=>{ot(!0)},[]),n.useEffect(()=>{const t=G.current;if(!t)return;const e=s=>{const o=s.touches[0].clientX-(E??0),l=s.touches[0].clientY-(D??0);!m&&Math.abs(o)>Math.abs(l)&&X(!0),m&&(s.preventDefault(),Y(s.touches[0].clientX))};return t.addEventListener("touchmove",e),()=>{t.removeEventListener("touchmove",e)}},[m,E,D]);const ft=()=>{if(E===null||z===null)return;const t=E-z;Math.abs(t)>50&&(t>0?R():T()),q(null),Y(null),P(null),X(!1)},vt=(t,e)=>{const s=[];for(let o=0;o<t.length;o+=e)s.push(t.slice(o,o+e));return s};n.useLayoutEffect(()=>{if(typeof window<"u"){const t=()=>{const e=window.innerWidth<768,s=e?1:d;tt(e),Z(e?1:d),v(o=>Math.min(o,Math.ceil(M.length/s)-1))};return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)}},[d]);const k=Math.ceil(i/F),H=vt(M,i),_=H.length,pt=3*16,gt=3*16,_t=n.useCallback(t=>{if(t&&!$){const e=t.getBoundingClientRect().width;e>0&&e!==p&&(y(e),nt(!0))}},[p,$]);n.useEffect(()=>{var t,e,s,o;if($&&a>0&&u.current&&((e=(t=u.current.children[0])==null?void 0:t.children[0])!=null&&e.children[0])){const b=((o=(s=u.current.children[0])==null?void 0:s.children[0])==null?void 0:o.children[0]).getBoundingClientRect().width;b>0&&b!==p&&y(b)}},[a,$,p]),n.useEffect(()=>{const t=new ResizeObserver(e=>{var s,o;for(let l of e)if(l.contentRect){g?C(l.contentRect.width-gt):L?h!=null&&h.current?C(l.contentRect.width-((s=h==null?void 0:h.current)==null?void 0:s.offsetWidth)-pt):C(l.contentRect.width):(C(l.contentRect.width),y(((o=u==null?void 0:u.current)==null?void 0:o.children[0].children[0].children[0].getBoundingClientRect().width)??0));const b=g?1:d;v(xt=>Math.min(xt,Math.ceil(M.length/b)-1))}});return S!=null&&S.current&&t.observe(S.current),()=>t.disconnect()},[g,L,M]);const N=()=>{w.current&&clearInterval(w.current),et(!1)},R=()=>{N(),v(t=>Math.min(t+1,_-1))},T=()=>{N(),v(t=>Math.max(t-1,0))},Mt=t=>{N(),v(t)},wt=()=>a?`translateX(-${f*a}px)`:"translateX(0px)",V=()=>{v(t=>t>=_-1?0:t+1)};n.useEffect(()=>(A&&(w.current=setInterval(V,W*1e3)),()=>{w.current&&clearInterval(w.current)}),[A,W,V]);const mt={"--max-item-width":`${(a-(i-1)*16)/i}px`};return r.jsxs("div",{className:`${K??""} ${c.carousel} `,ref:ct,children:[r.jsx("div",{ref:G,className:`${c.trackContainer} ${rt||m?c.noPointerEvents:""}
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../../assets/index23.css');const r=require("react/jsx-runtime"),n=require("react"),bt=require("../../../arrow-left-4E3t8axP.cjs"),Ct=require("../../../arrow-right-DO6S4vfx.cjs"),$t="_carousel_pig9v_1",St="_noPointerEvents_pig9v_10",Et="_trackContainer_pig9v_14",yt="_track_pig9v_14",Xt="_isMounted_pig9v_28",It="_page_pig9v_33",jt="_controls_pig9v_43",kt="_indicators_pig9v_54",Nt="_indicator_pig9v_54",Rt="_active_pig9v_71",Tt="_buttons_pig9v_75",Wt="_prev_pig9v_80",Lt="_disabled_pig9v_80",At="_next_pig9v_81",c={carousel:$t,noPointerEvents:St,trackContainer:Et,track:yt,isMounted:Xt,page:It,controls:jt,indicators:kt,indicator:Nt,active:Rt,buttons:Tt,prev:Wt,disabled:Lt,next:At};function Dt({items:M,itemsPerPage:d=9,itemsPerRow:F=3,autoplay:J=!1,autoplayInterval:W=3,className:K,externalRef:Q,siblingRef:h,isSplit:L=!1}){const[f,v]=n.useState(0),[a,C]=n.useState(0),[p,y]=n.useState(0),[i,Z]=n.useState(d),[g,tt]=n.useState(!1),[A,et]=n.useState(J),[$,nt]=n.useState(!1),[st,ot]=n.useState(!1),ct=n.useRef(null),u=n.useRef(null),w=n.useRef(null),S=Q,[m,X]=n.useState(!1),[D,P]=n.useState(null),[E,q]=n.useState(null),[z,Y]=n.useState(null),[rt,B]=n.useState(!1),[x,O]=n.useState(null),[I,U]=n.useState(null),at=t=>{Math.abs((I??0)-(x??0))>25&&(t.stopPropagation(),t.preventDefault())},it=t=>{O(t.clientX)},lt=t=>{x!==null&&Math.abs(t.clientX-x)>5&&(B(!0),U(t.clientX))},ut=()=>{if(!x||!I){j();return}const t=x-I;Math.abs(t)>50&&(t>0?R():T()),j()},dt=()=>{j()},j=()=>{B(!1),O(null),U(null)},ht=t=>{q(t.touches[0].clientX),P(t.touches[0].clientY),X(!1)},G=n.useRef(null);n.useEffect(()=>{ot(!0)},[]),n.useEffect(()=>{const t=G.current;if(!t)return;const e=s=>{const o=s.touches[0].clientX-(E??0),l=s.touches[0].clientY-(D??0);!m&&Math.abs(o)>Math.abs(l)&&X(!0),m&&(s.preventDefault(),Y(s.touches[0].clientX))};return t.addEventListener("touchmove",e,{passive:!0}),()=>{t.removeEventListener("touchmove",e)}},[m,E,D]);const ft=()=>{if(E===null||z===null)return;const t=E-z;Math.abs(t)>50&&(t>0?R():T()),q(null),Y(null),P(null),X(!1)},vt=(t,e)=>{const s=[];for(let o=0;o<t.length;o+=e)s.push(t.slice(o,o+e));return s};n.useLayoutEffect(()=>{if(typeof window<"u"){const t=()=>{const e=window.innerWidth<768,s=e?1:d;tt(e),Z(e?1:d),v(o=>Math.min(o,Math.ceil(M.length/s)-1))};return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)}},[d]);const k=Math.ceil(i/F),H=vt(M,i),_=H.length,pt=3*16,gt=3*16,_t=n.useCallback(t=>{if(t&&!$){const e=t.getBoundingClientRect().width;e>0&&e!==p&&(y(e),nt(!0))}},[p,$]);n.useEffect(()=>{var t,e,s,o;if($&&a>0&&u.current&&((e=(t=u.current.children[0])==null?void 0:t.children[0])!=null&&e.children[0])){const b=((o=(s=u.current.children[0])==null?void 0:s.children[0])==null?void 0:o.children[0]).getBoundingClientRect().width;b>0&&b!==p&&y(b)}},[a,$,p]),n.useEffect(()=>{const t=new ResizeObserver(e=>{var s,o;for(let l of e)if(l.contentRect){g?C(l.contentRect.width-gt):L?h!=null&&h.current?C(l.contentRect.width-((s=h==null?void 0:h.current)==null?void 0:s.offsetWidth)-pt):C(l.contentRect.width):(C(l.contentRect.width),y(((o=u==null?void 0:u.current)==null?void 0:o.children[0].children[0].children[0].getBoundingClientRect().width)??0));const b=g?1:d;v(xt=>Math.min(xt,Math.ceil(M.length/b)-1))}});return S!=null&&S.current&&t.observe(S.current),()=>t.disconnect()},[g,L,M]);const N=()=>{w.current&&clearInterval(w.current),et(!1)},R=()=>{N(),v(t=>Math.min(t+1,_-1))},T=()=>{N(),v(t=>Math.max(t-1,0))},Mt=t=>{N(),v(t)},wt=()=>a?`translateX(-${f*a}px)`:"translateX(0px)",V=()=>{v(t=>t>=_-1?0:t+1)};n.useEffect(()=>(A&&(w.current=setInterval(V,W*1e3)),()=>{w.current&&clearInterval(w.current)}),[A,W,V]);const mt={"--max-item-width":`${(a-(i-1)*16)/i}px`};return r.jsxs("div",{className:`${K??""} ${c.carousel} `,ref:ct,children:[r.jsx("div",{ref:G,className:`${c.trackContainer} ${rt||m?c.noPointerEvents:""}
2
2
  `,style:{maxWidth:`${a}px`,touchAction:m?"none":"pan-y"},onTouchStart:ht,onTouchEnd:ft,onMouseDown:it,onMouseMove:lt,onMouseUp:ut,onMouseLeave:dt,children:r.jsx("div",{ref:u,className:`${c.track} ${st?c.isMounted:""}`,style:{width:`${_*100}%`,transform:wt()},children:H.map((t,e)=>r.jsx("div",{className:c.page,style:{display:k>1?"grid":"flex",gridTemplateColumns:`repeat(${Math.ceil(i/k)}, 1fr)`,gridTemplateRows:`repeat(${k}, 1fr)`,width:`${a}px`},children:t.map((s,o)=>r.jsx("div",{ref:e===0&&o===0?_t:null,onClickCapture:at,style:{...mt,flexBasis:g?"100%":`${(a-(i-1)*16)/i}px`,width:g?`${a/i-16}px`:"unset"},children:s},o))},e))})}),_>1&&r.jsxs("div",{className:c.controls,style:{maxWidth:p>0&&d===1&&!g?`${p}px`:"unset"},children:[r.jsx("div",{className:c.indicators,children:Array.from({length:_}).map((t,e)=>r.jsx("button",{className:`${c.indicator} ${e===f?c.active:""}`,onClick:()=>Mt(e),"aria-label":`Go to group ${e+1}`},e))}),r.jsxs("div",{className:c.buttons,children:[r.jsx("button",{"aria-label":"Previous slide",className:`${c.prev} ${f===0?c.disabled:""}`,onClick:T,disabled:f===0,children:r.jsx(bt.ArrowLeft,{size:36})}),r.jsx("button",{"aria-label":"Next slide",className:`${c.next} ${f>=_-1?c.disabled:""}`,onClick:R,disabled:f>=M.length-i,children:r.jsx(Ct.ArrowRight,{size:36})})]})]})]})}exports.Carousel=Dt;
@@ -58,7 +58,7 @@ function Vt({
58
58
  const s = n.touches[0].clientX - (y ?? 0), l = n.touches[0].clientY - (B ?? 0);
59
59
  !w && Math.abs(s) > Math.abs(l) && N(!0), w && (n.preventDefault(), H(n.touches[0].clientX));
60
60
  };
61
- return t.addEventListener("touchmove", e), () => {
61
+ return t.addEventListener("touchmove", e, { passive: !0 }), () => {
62
62
  t.removeEventListener("touchmove", e);
63
63
  };
64
64
  }, [w, y, B]);
@@ -13,4 +13,4 @@
13
13
  *
14
14
  * This source code is licensed under the ISC license.
15
15
  * See the LICENSE file in the root directory of this source tree.
16
- */const Se=[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]],_e=G.createLucideIcon("search",Se),Le={standard:e.styles.standard,transparent:e.styles.transparent},Me={left:e.styles.left,center:e.styles.center,right:e.styles.right},Ee=({spotlight:a,renderText:m})=>{var t,C,k,p,j,S,x,_,L,M,u;const w=(t=a.image)==null?void 0:t.asset.altText,f=((C=a.callToAction.linkOptions)==null?void 0:C.linkType)==="external";let y="#";return((k=a.callToAction.linkOptions)==null?void 0:k.linkType)==="external"&&((p=a.callToAction.linkOptions)!=null&&p.externalUrl)?y=(j=a.callToAction.linkOptions)==null?void 0:j.externalUrl:((S=a.callToAction.linkOptions)==null?void 0:S.linkType)==="internal"&&((_=(x=a.callToAction.linkOptions)==null?void 0:x.internalUrl)!=null&&_.slug.current)&&(y=`/${(M=(L=a.callToAction.linkOptions)==null?void 0:L.internalUrl)==null?void 0:M.slug.current}`),s.jsxs("div",{className:e.styles.spotlight,children:[a.image&&s.jsx("div",{className:e.styles.imageWrapper,children:s.jsx("img",{src:(a==null?void 0:a.image.imageUrl)??"",alt:w||a.image.asset.description||"Content image",width:600,height:400})}),s.jsxs("div",{className:e.styles.content,children:[a.title&&s.jsx("div",{className:e.styles.title,children:m==null?void 0:m(a.title,e.styles.title)}),a.description&&s.jsx("div",{className:e.styles.description,children:m==null?void 0:m(a.description,e.styles.description)})]}),((u=a.callToAction)==null?void 0:u.linkOptions)&&s.jsx("div",{className:e.styles.actions,children:s.jsx(O.CallToAction,{as:"a",variant:a.callToAction.variant??"primary",href:y,target:f?"_blank":"_self",rel:f?"noopener noreferrer":"","aria-label":a.callToAction.ariaLabel||a.callToAction.label,children:a.callToAction.label})})]})};function Ae({renderText:a,title:m,logo:w,items:f,groups:y,utilityItems:t,isSticky:C=!1,showSearch:k=!0,showLocaleSelect:p=!0,alignment:j="right",variant:S="standard",navigationType:x="default",searchComponent:_,localeSelectComponent:L,className:M}){const[u,U]=r.useState(!1),[X,b]=r.useState(null),[ce,re]=r.useState(0),[oe,de]=r.useState(!1),[ue,ye]=r.useState(null),[o,N]=r.useState([]),[E,q]=r.useState(0),[he,H]=r.useState(null),[$,me]=r.useState(!1),[A,T]=r.useState("forward"),B=()=>s.jsx("div",{className:`${e.styles.linkWrapper} ${e.styles.parent} ${e.styles.searchWrapper}`,children:s.jsx("div",{className:e.styles.linkItem,children:s.jsx(te.Modal,{className:e.styles.searchModal,trigger:s.jsx("button",{role:"menuitem",title:"Search","aria-label":"Search",className:e.styles.search,children:s.jsx(_e,{size:16})}),content:_})})}),V=()=>s.jsx("div",{className:`${e.styles.linkWrapper} ${e.styles.parent} `,children:s.jsx("div",{className:e.styles.linkItem,children:s.jsx(te.Modal,{className:e.styles.localeModal,trigger:s.jsx("button",{title:"Locale Select","aria-label":"Locale Select",role:"menuitem",className:e.styles.locale,children:s.jsx(ge,{size:16})}),content:L})})});r.useEffect(()=>{if(typeof window<"u"){const l=()=>{const n=window.innerWidth<768;me(n)};return l(),window.addEventListener("resize",l),()=>window.removeEventListener("resize",l)}},[]);const be=()=>{N([])},fe=l=>{T("forward"),N([{title:l.title,primary:l.primaryItems??[],secondary:l.secondaryItems??[],description:""}])},J=l=>{T("forward"),N(n=>[...n,{title:l.label,primary:l.sublinks??[],secondary:[],description:l.description}])},xe=()=>{T("backward"),N(l=>l.slice(0,-1))},F=r.useRef(null),g=r.useRef(null),W=r.useRef(new Map),ke=()=>{U(l=>{const n=!l;return n||(N([]),T("forward"),b(null)),n})},K=l=>{const n=W.current.get(l);if(n&&g.current){const d=n.getBoundingClientRect(),h=g.current.getBoundingClientRect(),c=d.left-h.left+d.width/2;ye(c)}},je=l=>{b(n=>n===l?null:l)},Q=r.useCallback(l=>{F.current&&!F.current.contains(l.target)&&b(null)},[]),Y=r.useCallback(()=>{Z(),typeof window<"u"&&window.innerWidth>768&&(U(!1),b(null),typeof document<"u"&&(document.body.style.overflow=""))},[]),Z=r.useCallback(()=>{if(g.current){const l=g.current.getBoundingClientRect().width;re(l),de(!0)}},[]);r.useEffect(()=>{const l=typeof window<"u",n=typeof document<"u";return l&&window.addEventListener("resize",Y),n&&document.addEventListener("click",Q),Z(),()=>{l&&window.removeEventListener("resize",Y),n&&document.removeEventListener("click",Q)}},[]),r.useEffect(()=>{if(typeof document<"u")return u?setTimeout(()=>{I.lockScroll()},0):I.unlockScroll(),()=>I.unlockScroll()},[u]);const ve=l=>l.map((n,d)=>{var P,ee,se,le,ne;const h=`group-${d}`,z=he===d,c=(P=n.primaryItems)==null?void 0:P[E??0];return s.jsxs("div",{className:`${e.styles.linkWrapper} ${e.styles.parent}`,onMouseEnter:()=>{H(d),b(h),K(h)},onMouseLeave:()=>{H(null),q(0),b(null)},children:[s.jsx("div",{className:e.styles.linkItem,children:s.jsxs("button",{ref:i=>{W.current.set(h,i)},role:"menuitem","aria-haspopup":"true","aria-expanded":z,"aria-controls":`submenu-${d}`,className:`${e.styles.sublinkToggle} ${z?e.styles.open:""} `,children:[n.title,s.jsx(Ne.ChevronDown,{size:18,className:e.styles.chevron})]})}),s.jsx("div",{id:`submenu-${d}`,className:`${e.styles.sublinks} ${z?e.styles.show:""}`,role:"menu","aria-label":`${n.title} submenu`,children:s.jsx("div",{children:s.jsxs("div",{className:`${e.styles.sublinksInner} ${n.spotlight?e.styles.withSpotlight:e.styles.withoutSpotlight}`,children:[s.jsxs("div",{className:`${e.styles.sublinksColumn} ${e.styles.primaryColumn}`,children:[s.jsx("div",{className:e.styles.linkItem}),(ee=n.primaryItems)==null?void 0:ee.map((i,v)=>i.href?s.jsxs("a",{href:i.href,className:`${e.styles.link} ${E===v?e.styles.open:""}`,target:i.isExternal?"_blank":"_self",rel:i.isExternal?"noopener noreferrer":void 0,onClick:()=>{var ae;b(null),(ae=i.onClick)==null||ae.call(i)},onMouseEnter:()=>i.sublinks?q(v):null,role:"menuitem",children:[s.jsxs("span",{className:e.styles.linkContent,children:[i.label,i.subtitle&&s.jsx("span",{className:e.styles.subtitle,children:i.subtitle})]}),i.isExternal&&s.jsx(D.ExternalLink,{className:e.styles.newTabIcon,size:16})]},i._key??v):s.jsx("button",{role:"menuitem",className:`${e.styles.sublinkToggle} ${E===v?e.styles.open:""}`,onMouseEnter:()=>q(v),children:s.jsxs("span",{className:e.styles.linkContent,children:[i.label,i.subtitle&&s.jsx("span",{className:e.styles.subtitle,children:i.subtitle})]})},i._key??v))]}),(c==null?void 0:c.sublinks)&&((se=c==null?void 0:c.sublinks)==null?void 0:se.length)>0&&s.jsxs("div",{className:`${e.styles.sublinksColumn} ${e.styles.fadeInFromLeft}`,children:[(c==null?void 0:c.description)&&s.jsxs("div",{className:e.styles.sublinksDescription,children:[s.jsx("p",{children:"TEXT HERE"}),a==null?void 0:a(c.description)]}),(c==null?void 0:c.sublinks)&&R(c.sublinks,`${h}-${E}`)]},`${c.label}-${(le=c==null?void 0:c.sublinks)==null?void 0:le.length}`),(n==null?void 0:n.secondaryItems)&&((ne=n==null?void 0:n.secondaryItems)==null?void 0:ne.length)>0&&s.jsx("div",{className:`${e.styles.sublinksColumn} ${e.styles.secondaryColumn}`,children:n.secondaryItems&&n.secondaryItems.length>0&&R(n.secondaryItems,`${h}-secondary`)}),n.spotlight&&s.jsx("div",{className:`${e.styles.sublinksColumn} ${e.styles.spotlightColumn}`,children:s.jsx(Ee,{spotlight:n.spotlight,renderText:a??(i=>String(i))})})]})})})]},n._key??`group-${d}`)}),R=(l,n="")=>l.map(d=>{const h=`${n}/${d.label}`;return s.jsx(e.NavLink,{link:d,path:h,parentPath:n,openPath:X,togglePath:je,updateTriangleIndicator:K,setOpenPath:b,renderLinks:R,buttonRefs:W},d._key??h)});return s.jsx("header",{ref:F,className:`${M??""} ${Me[j]} ${Le[S]} ${e.styles.navbar} ${C?e.styles.sticky:""} ${y&&y.length?e.styles.advanced:e.styles.default}`,"aria-label":"Main navigation",children:s.jsxs("div",{className:`${e.styles.container} ${(!t||t.length===0)&&j!=="center"?e.styles.twoColumn:""}`,children:[w?s.jsx("div",{className:e.styles.logo,children:w}):s.jsx("div",{className:e.styles.title,children:m}),s.jsx("nav",{ref:g,style:{left:j==="center"?`calc(50% - ${ce/2}px)`:"0"},className:`${e.styles.nav} ${u?e.styles.open:""} ${oe?e.styles.visible:e.styles.hidden}`,id:"main-menu",role:"menubar","aria-label":"Main navigation",children:s.jsxs("div",{className:e.styles.navInner,children:[s.jsx("svg",{style:{left:`${ue}px`},className:`${e.styles.triangle} ${X?e.styles.show:""}`,width:16,height:12,viewBox:"0 0 100 75",xmlns:"http://www.w3.org/2000/svg",children:s.jsx("polygon",{points:"50,5 95,70 5,70",strokeLinejoin:"round",fill:"white",stroke:"white"})}),x==="default"&&f&&s.jsxs("div",{className:e.styles.grid,children:[f&&f.length>0&&R(f),k&&!$&&s.jsxs(s.Fragment,{children:[s.jsx("span",{className:e.styles.separator}),s.jsx(B,{})]}),p&&s.jsx(V,{})]}),!$&&x==="advanced"&&y&&s.jsxs("div",{className:e.styles.grid,children:[y.length>0&&ve(y),k&&s.jsxs(s.Fragment,{children:[s.jsx("span",{className:e.styles.separator}),s.jsx(B,{})]}),p&&s.jsx(V,{})]}),$&&x==="advanced"&&u&&o.length===0&&y&&s.jsx("div",{className:`${e.styles.mobileMenu}`,children:y.map((l,n)=>s.jsx("div",{className:`${e.styles.mobileMenuItem} ${A==="forward"?e.styles.fadeInFromLeft:e.styles.fadeInFromRight}`,children:s.jsx("button",{role:"menuitem",className:e.styles.sublinkToggle,onClick:()=>fe(l),children:l.title})},l._key??n))}),$&&x==="advanced"&&u&&o.length>0&&s.jsxs("div",{className:`${e.styles.mobileMenuSlide} `,children:[s.jsx("button",{role:"menuitem",className:e.styles.back,onClick:o.length===1?be:xe,children:s.jsx(O.ChevronLeft,{size:18,"aria-hidden":"true",focusable:"false"})}),o[o.length-1].description&&s.jsx("div",{className:`${e.styles.sublinksDescription} ${A==="forward"?e.styles.fadeInFromLeft:e.styles.fadeInFromRight}`,children:a==null?void 0:a(o[o.length-1].description)}),o[o.length-1].primary.map((l,n)=>s.jsx("div",{className:`${e.styles.mobileMenuItem} ${A==="forward"?e.styles.fadeInFromLeft:e.styles.fadeInFromRight}`,children:l.sublinks?s.jsx("button",{role:"menuitem",className:e.styles.sublinkToggle,onClick:()=>J(l),children:s.jsxs("span",{className:e.styles.linkContent,children:[l.label,l.subtitle&&s.jsx("span",{className:e.styles.subtitle,children:l.subtitle})]})}):s.jsxs("a",{href:l.href,className:e.styles.link,target:l.isExternal?"_blank":"_self",rel:l.isExternal?"noopener noreferrer":void 0,role:"menuitem",children:[s.jsxs("span",{className:e.styles.linkContent,children:[l.label,l.subtitle&&s.jsx("span",{className:e.styles.subtitle,children:l.subtitle})]}),l.isExternal&&s.jsx(D.ExternalLink,{className:e.styles.newTabIcon,size:16})]})},l._key??`primary-${n}`)),o[o.length-1].secondary.length>0&&s.jsx("hr",{className:e.styles.groupDivider}),o[o.length-1].secondary.map((l,n)=>s.jsx("div",{className:`${e.styles.mobileMenuItem} ${A==="forward"?e.styles.fadeInFromLeft:e.styles.fadeInFromRight}`,children:l.sublinks?s.jsx("button",{role:"menuitem",className:e.styles.sublinkToggle,onClick:()=>J(l),children:l.label}):s.jsxs("a",{href:l.href,className:e.styles.link,target:l.isExternal?"_blank":"_self",rel:l.isExternal?"noopener noreferrer":void 0,role:"menuitem",children:[l.label,l.isExternal&&s.jsx(D.ExternalLink,{className:e.styles.newTabIcon,size:16})]})},l._key??`secondary-${n}`))]},`stack-${o.length}`)]})}),t&&t.length>0&&s.jsx("nav",{className:e.styles.utility,role:"menu","aria-label":"Utility navigation",children:s.jsx(ie.ButtonGroup,{children:t.map((l,n)=>s.jsx(O.CallToAction,{as:"a",href:l.href??"/",variant:l.variant??"primary",displayType:l.displayType??"text",imageSrc:l.imageSrc,imageAlt:l.imageAlt,"aria-label":l.ariaLabel??l.label,icon:l.icon,iconAlignment:l.iconAlignment,role:"menuitem",children:l.imageSrc?s.jsx("img",{src:l.imageSrc,alt:l.imageAlt??l.ariaLabel??l.label}):l.label},l._key||n))})}),t&&t.length>0&&s.jsx("nav",{role:"menu","aria-label":"Utility navigation",className:`${e.styles.utilityMobile} ${u?e.styles.open:""}`,children:s.jsx(ie.ButtonGroup,{alignment:"center",children:s.jsx(O.CallToAction,{as:"a",href:t[1].href??"/",variant:t[1].variant??"primary",displayType:t[1].displayType??"text",imageSrc:t[1].imageSrc,imageAlt:t[1].imageAlt,"aria-label":t[1].ariaLabel??t[1].label,icon:t[1].icon,iconAlignment:t[1].iconAlignment,role:"menuitem",children:t[1].imageSrc?s.jsx("img",{src:t[1].imageSrc,"aria-label":t[1].imageAlt??t[1].ariaLabel??t[1].label}):t[1].label})})}),s.jsxs("div",{className:e.styles.mobileButtons,children:[$&&k&&s.jsx(B,{}),s.jsx("button",{className:e.styles.menuToggle,onClick:ke,"aria-label":u?"Close menu":"Open menu","aria-expanded":u,"aria-controls":"main-menu",children:u?s.jsx(pe.X,{size:24}):s.jsx(Ce,{size:24})})]})]})})}exports.Navbar=Ae;
16
+ */const Se=[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]],_e=G.createLucideIcon("search",Se),Le={standard:e.styles.standard,transparent:e.styles.transparent},Me={left:e.styles.left,center:e.styles.center,right:e.styles.right},Ee=({spotlight:a,renderText:m})=>{var t,C,k,p,j,S,x,_,L,M,u;const w=(t=a.image)==null?void 0:t.asset.altText,f=((C=a.callToAction.linkOptions)==null?void 0:C.linkType)==="external";let y="#";return((k=a.callToAction.linkOptions)==null?void 0:k.linkType)==="external"&&((p=a.callToAction.linkOptions)!=null&&p.externalUrl)?y=(j=a.callToAction.linkOptions)==null?void 0:j.externalUrl:((S=a.callToAction.linkOptions)==null?void 0:S.linkType)==="internal"&&((_=(x=a.callToAction.linkOptions)==null?void 0:x.internalUrl)!=null&&_.slug.current)&&(y=`/${(M=(L=a.callToAction.linkOptions)==null?void 0:L.internalUrl)==null?void 0:M.slug.current}`),s.jsxs("div",{className:e.styles.spotlight,children:[a.image&&s.jsx("div",{className:e.styles.imageWrapper,children:s.jsx("img",{src:(a==null?void 0:a.image.imageUrl)??"",alt:w||a.image.asset.description||"Content image",width:600,height:400})}),s.jsxs("div",{className:e.styles.content,children:[a.title&&s.jsx("div",{className:e.styles.title,children:m==null?void 0:m(a.title,e.styles.title)}),a.description&&s.jsx("div",{className:e.styles.description,children:m==null?void 0:m(a.description,e.styles.description)})]}),((u=a.callToAction)==null?void 0:u.linkOptions)&&s.jsx("div",{className:e.styles.actions,children:s.jsx(O.CallToAction,{as:"a",variant:a.callToAction.variant??"primary",href:y,target:f?"_blank":"_self",rel:f?"noopener noreferrer":"","aria-label":a.callToAction.ariaLabel||a.callToAction.label,children:a.callToAction.label})})]})};function Ae({renderText:a,title:m,logo:w,items:f,groups:y,utilityItems:t,isSticky:C=!1,showSearch:k=!0,showLocaleSelect:p=!0,alignment:j="right",variant:S="standard",navigationType:x="default",searchComponent:_,localeSelectComponent:L,className:M}){const[u,U]=r.useState(!1),[X,b]=r.useState(null),[ce,re]=r.useState(0),[oe,de]=r.useState(!1),[ue,ye]=r.useState(null),[o,N]=r.useState([]),[E,q]=r.useState(0),[he,H]=r.useState(null),[$,me]=r.useState(!1),[A,T]=r.useState("forward"),B=()=>s.jsx("div",{className:`${e.styles.linkWrapper} ${e.styles.parent} ${e.styles.searchWrapper}`,children:s.jsx("div",{className:e.styles.linkItem,children:s.jsx(te.Modal,{className:e.styles.searchModal,trigger:s.jsx("button",{role:"button",title:"Search","aria-label":"Search",className:e.styles.search,children:s.jsx(_e,{size:16})}),content:_})})}),V=()=>s.jsx("div",{className:`${e.styles.linkWrapper} ${e.styles.parent} `,children:s.jsx("div",{className:e.styles.linkItem,children:s.jsx(te.Modal,{className:e.styles.localeModal,trigger:s.jsx("button",{title:"Locale Select","aria-label":"Locale Select",role:"button",className:e.styles.locale,children:s.jsx(ge,{size:16})}),content:L})})});r.useEffect(()=>{if(typeof window<"u"){const l=()=>{const n=window.innerWidth<768;me(n)};return l(),window.addEventListener("resize",l),()=>window.removeEventListener("resize",l)}},[]);const be=()=>{N([])},fe=l=>{T("forward"),N([{title:l.title,primary:l.primaryItems??[],secondary:l.secondaryItems??[],description:""}])},J=l=>{T("forward"),N(n=>[...n,{title:l.label,primary:l.sublinks??[],secondary:[],description:l.description}])},xe=()=>{T("backward"),N(l=>l.slice(0,-1))},F=r.useRef(null),g=r.useRef(null),W=r.useRef(new Map),ke=()=>{U(l=>{const n=!l;return n||(N([]),T("forward"),b(null)),n})},K=l=>{const n=W.current.get(l);if(n&&g.current){const d=n.getBoundingClientRect(),h=g.current.getBoundingClientRect(),c=d.left-h.left+d.width/2;ye(c)}},je=l=>{b(n=>n===l?null:l)},Q=r.useCallback(l=>{F.current&&!F.current.contains(l.target)&&b(null)},[]),Y=r.useCallback(()=>{Z(),typeof window<"u"&&window.innerWidth>768&&(U(!1),b(null),typeof document<"u"&&(document.body.style.overflow=""))},[]),Z=r.useCallback(()=>{if(g.current){const l=g.current.getBoundingClientRect().width;re(l),de(!0)}},[]);r.useEffect(()=>{const l=typeof window<"u",n=typeof document<"u";return l&&window.addEventListener("resize",Y),n&&document.addEventListener("click",Q),Z(),()=>{l&&window.removeEventListener("resize",Y),n&&document.removeEventListener("click",Q)}},[]),r.useEffect(()=>{if(typeof document<"u")return u?setTimeout(()=>{I.lockScroll()},0):I.unlockScroll(),()=>I.unlockScroll()},[u]);const ve=l=>l.map((n,d)=>{var P,ee,se,le,ne;const h=`group-${d}`,z=he===d,c=(P=n.primaryItems)==null?void 0:P[E??0];return s.jsxs("div",{className:`${e.styles.linkWrapper} ${e.styles.parent}`,onMouseEnter:()=>{H(d),b(h),K(h)},onMouseLeave:()=>{H(null),q(0),b(null)},children:[s.jsx("div",{className:e.styles.linkItem,children:s.jsxs("button",{ref:i=>{W.current.set(h,i)},role:"menuitem","aria-haspopup":"true","aria-expanded":z,"aria-controls":`submenu-${d}`,className:`${e.styles.sublinkToggle} ${z?e.styles.open:""} `,children:[n.title,s.jsx(Ne.ChevronDown,{size:18,className:e.styles.chevron})]})}),s.jsx("div",{id:`submenu-${d}`,className:`${e.styles.sublinks} ${z?e.styles.show:""}`,role:"menu","aria-label":`${n.title} submenu`,children:s.jsx("div",{children:s.jsxs("div",{className:`${e.styles.sublinksInner} ${n.spotlight?e.styles.withSpotlight:e.styles.withoutSpotlight}`,children:[s.jsxs("div",{className:`${e.styles.sublinksColumn} ${e.styles.primaryColumn}`,children:[s.jsx("div",{className:e.styles.linkItem}),(ee=n.primaryItems)==null?void 0:ee.map((i,v)=>i.href?s.jsxs("a",{href:i.href,className:`${e.styles.link} ${E===v?e.styles.open:""}`,target:i.isExternal?"_blank":"_self",rel:i.isExternal?"noopener noreferrer":void 0,onClick:()=>{var ae;b(null),(ae=i.onClick)==null||ae.call(i)},onMouseEnter:()=>i.sublinks?q(v):null,role:"menuitem",children:[s.jsxs("span",{className:e.styles.linkContent,children:[i.label,i.subtitle&&s.jsx("span",{className:e.styles.subtitle,children:i.subtitle})]}),i.isExternal&&s.jsx(D.ExternalLink,{className:e.styles.newTabIcon,size:16})]},i._key??v):s.jsx("button",{role:"menuitem",className:`${e.styles.sublinkToggle} ${E===v?e.styles.open:""}`,onMouseEnter:()=>q(v),children:s.jsxs("span",{className:e.styles.linkContent,children:[i.label,i.subtitle&&s.jsx("span",{className:e.styles.subtitle,children:i.subtitle})]})},i._key??v))]}),(c==null?void 0:c.sublinks)&&((se=c==null?void 0:c.sublinks)==null?void 0:se.length)>0&&s.jsxs("div",{className:`${e.styles.sublinksColumn} ${e.styles.fadeInFromLeft}`,children:[(c==null?void 0:c.description)&&s.jsxs("div",{className:e.styles.sublinksDescription,children:[s.jsx("p",{children:"TEXT HERE"}),a==null?void 0:a(c.description)]}),(c==null?void 0:c.sublinks)&&R(c.sublinks,`${h}-${E}`)]},`${c.label}-${(le=c==null?void 0:c.sublinks)==null?void 0:le.length}`),(n==null?void 0:n.secondaryItems)&&((ne=n==null?void 0:n.secondaryItems)==null?void 0:ne.length)>0&&s.jsx("div",{className:`${e.styles.sublinksColumn} ${e.styles.secondaryColumn}`,children:n.secondaryItems&&n.secondaryItems.length>0&&R(n.secondaryItems,`${h}-secondary`)}),n.spotlight&&s.jsx("div",{className:`${e.styles.sublinksColumn} ${e.styles.spotlightColumn}`,children:s.jsx(Ee,{spotlight:n.spotlight,renderText:a??(i=>String(i))})})]})})})]},n._key??`group-${d}`)}),R=(l,n="")=>l.map(d=>{const h=`${n}/${d.label}`;return s.jsx(e.NavLink,{link:d,path:h,parentPath:n,openPath:X,togglePath:je,updateTriangleIndicator:K,setOpenPath:b,renderLinks:R,buttonRefs:W},d._key??h)});return s.jsx("header",{ref:F,className:`${M??""} ${Me[j]} ${Le[S]} ${e.styles.navbar} ${C?e.styles.sticky:""} ${y&&y.length?e.styles.advanced:e.styles.default}`,"aria-label":"Main navigation",children:s.jsxs("div",{className:`${e.styles.container} ${(!t||t.length===0)&&j!=="center"?e.styles.twoColumn:""}`,children:[w?s.jsx("div",{className:e.styles.logo,children:w}):s.jsx("div",{className:e.styles.title,children:m}),s.jsx("nav",{ref:g,style:{left:j==="center"?`calc(50% - ${ce/2}px)`:"0"},className:`${e.styles.nav} ${u?e.styles.open:""} ${oe?e.styles.visible:e.styles.hidden}`,id:"main-menu",role:"menubar","aria-label":"Main navigation",children:s.jsxs("div",{className:e.styles.navInner,children:[s.jsx("svg",{style:{left:`${ue}px`},className:`${e.styles.triangle} ${X?e.styles.show:""}`,width:16,height:12,viewBox:"0 0 100 75",xmlns:"http://www.w3.org/2000/svg",children:s.jsx("polygon",{points:"50,5 95,70 5,70",strokeLinejoin:"round",fill:"white",stroke:"white"})}),x==="default"&&f&&s.jsxs("div",{className:e.styles.grid,children:[f&&f.length>0&&R(f),k&&!$&&s.jsxs(s.Fragment,{children:[s.jsx("span",{className:e.styles.separator}),s.jsx(B,{})]}),p&&s.jsx(V,{})]}),!$&&x==="advanced"&&y&&s.jsxs("div",{className:e.styles.grid,children:[y.length>0&&ve(y),k&&s.jsxs(s.Fragment,{children:[s.jsx("span",{className:e.styles.separator}),s.jsx(B,{})]}),p&&s.jsx(V,{})]}),$&&x==="advanced"&&u&&o.length===0&&y&&s.jsx("div",{className:`${e.styles.mobileMenu}`,children:y.map((l,n)=>s.jsx("div",{className:`${e.styles.mobileMenuItem} ${A==="forward"?e.styles.fadeInFromLeft:e.styles.fadeInFromRight}`,children:s.jsx("button",{role:"menuitem",className:e.styles.sublinkToggle,onClick:()=>fe(l),children:l.title})},l._key??n))}),$&&x==="advanced"&&u&&o.length>0&&s.jsxs("div",{className:`${e.styles.mobileMenuSlide} `,children:[s.jsx("button",{role:"menuitem",className:e.styles.back,onClick:o.length===1?be:xe,children:s.jsx(O.ChevronLeft,{size:18,"aria-hidden":"true",focusable:"false"})}),o[o.length-1].description&&s.jsx("div",{className:`${e.styles.sublinksDescription} ${A==="forward"?e.styles.fadeInFromLeft:e.styles.fadeInFromRight}`,children:a==null?void 0:a(o[o.length-1].description)}),o[o.length-1].primary.map((l,n)=>s.jsx("div",{className:`${e.styles.mobileMenuItem} ${A==="forward"?e.styles.fadeInFromLeft:e.styles.fadeInFromRight}`,children:l.sublinks?s.jsx("button",{role:"menuitem",className:e.styles.sublinkToggle,onClick:()=>J(l),children:s.jsxs("span",{className:e.styles.linkContent,children:[l.label,l.subtitle&&s.jsx("span",{className:e.styles.subtitle,children:l.subtitle})]})}):s.jsxs("a",{href:l.href,className:e.styles.link,target:l.isExternal?"_blank":"_self",rel:l.isExternal?"noopener noreferrer":void 0,role:"menuitem",children:[s.jsxs("span",{className:e.styles.linkContent,children:[l.label,l.subtitle&&s.jsx("span",{className:e.styles.subtitle,children:l.subtitle})]}),l.isExternal&&s.jsx(D.ExternalLink,{className:e.styles.newTabIcon,size:16})]})},l._key??`primary-${n}`)),o[o.length-1].secondary.length>0&&s.jsx("hr",{className:e.styles.groupDivider}),o[o.length-1].secondary.map((l,n)=>s.jsx("div",{className:`${e.styles.mobileMenuItem} ${A==="forward"?e.styles.fadeInFromLeft:e.styles.fadeInFromRight}`,children:l.sublinks?s.jsx("button",{role:"menuitem",className:e.styles.sublinkToggle,onClick:()=>J(l),children:l.label}):s.jsxs("a",{href:l.href,className:e.styles.link,target:l.isExternal?"_blank":"_self",rel:l.isExternal?"noopener noreferrer":void 0,role:"menuitem",children:[l.label,l.isExternal&&s.jsx(D.ExternalLink,{className:e.styles.newTabIcon,size:16})]})},l._key??`secondary-${n}`))]},`stack-${o.length}`)]})}),t&&t.length>0&&s.jsx("nav",{className:e.styles.utility,role:"menu","aria-label":"Utility navigation",children:s.jsx(ie.ButtonGroup,{children:t.map((l,n)=>s.jsx(O.CallToAction,{as:"a",href:l.href??"/",variant:l.variant??"primary",displayType:l.displayType??"text",imageSrc:l.imageSrc,imageAlt:l.imageAlt,"aria-label":l.ariaLabel??l.label,icon:l.icon,iconAlignment:l.iconAlignment,role:"menuitem",children:l.imageSrc?s.jsx("img",{src:l.imageSrc,alt:l.imageAlt??l.ariaLabel??l.label}):l.label},l._key||n))})}),t&&t.length>0&&s.jsx("nav",{role:"menu","aria-label":"Utility navigation",className:`${e.styles.utilityMobile} ${u?e.styles.open:""}`,children:s.jsx(ie.ButtonGroup,{alignment:"center",children:s.jsx(O.CallToAction,{as:"a",href:t[1].href??"/",variant:t[1].variant??"primary",displayType:t[1].displayType??"text",imageSrc:t[1].imageSrc,imageAlt:t[1].imageAlt,"aria-label":t[1].ariaLabel??t[1].label,icon:t[1].icon,iconAlignment:t[1].iconAlignment,role:"menuitem",children:t[1].imageSrc?s.jsx("img",{src:t[1].imageSrc,"aria-label":t[1].imageAlt??t[1].ariaLabel??t[1].label}):t[1].label})})}),s.jsxs("div",{className:e.styles.mobileButtons,children:[$&&k&&s.jsx(B,{}),s.jsx("button",{className:e.styles.menuToggle,onClick:ke,"aria-label":u?"Close menu":"Open menu","aria-expanded":u,"aria-controls":"main-menu",children:u?s.jsx(pe.X,{size:24}):s.jsx(Ce,{size:24})})]})]})})}exports.Navbar=Ae;
@@ -1,10 +1,10 @@
1
1
  import { jsx as a, jsxs as c, Fragment as oe } from "react/jsx-runtime";
2
- import { useState as f, useEffect as U, useRef as I, useCallback as G } from "react";
2
+ import { useState as b, useEffect as U, useRef as I, useCallback as G } from "react";
3
3
  import { Modal as te } from "../Modal/index.mjs";
4
4
  import { a as Me, C as H } from "../../../index-C-E0ib2G.js";
5
5
  import { ButtonGroup as de } from "../ButtonGroup/index.mjs";
6
6
  import { s as e, N as Ee } from "../../../NavLink-CsNKwUSm.js";
7
- import { lockScroll as Ae, unlockScroll as me } from "../../utils/NoScroll/noScroll.mjs";
7
+ import { lockScroll as Ae, unlockScroll as he } from "../../utils/NoScroll/noScroll.mjs";
8
8
  import { E as X } from "../../../external-link-BOPobeQJ.js";
9
9
  import { X as Se } from "../../../x-CnsEH4Ox.js";
10
10
  import { c as V } from "../../../createLucideIcon-C8GTh_Qx.js";
@@ -56,12 +56,12 @@ const Oe = [
56
56
  right: e.right
57
57
  }, je = ({
58
58
  spotlight: i,
59
- renderText: b
59
+ renderText: f
60
60
  }) => {
61
- var s, E, N, w, $, A, p, S, _, z, m;
61
+ var s, E, N, w, $, A, p, S, _, z, h;
62
62
  const M = (s = i.image) == null ? void 0 : s.asset.altText, v = ((E = i.callToAction.linkOptions) == null ? void 0 : E.linkType) === "external";
63
- let h = "#";
64
- return ((N = i.callToAction.linkOptions) == null ? void 0 : N.linkType) === "external" && ((w = i.callToAction.linkOptions) != null && w.externalUrl) ? h = ($ = i.callToAction.linkOptions) == null ? void 0 : $.externalUrl : ((A = i.callToAction.linkOptions) == null ? void 0 : A.linkType) === "internal" && ((S = (p = i.callToAction.linkOptions) == null ? void 0 : p.internalUrl) != null && S.slug.current) && (h = `/${(z = (_ = i.callToAction.linkOptions) == null ? void 0 : _.internalUrl) == null ? void 0 : z.slug.current}`), /* @__PURE__ */ c("div", { className: e.spotlight, children: [
63
+ let m = "#";
64
+ return ((N = i.callToAction.linkOptions) == null ? void 0 : N.linkType) === "external" && ((w = i.callToAction.linkOptions) != null && w.externalUrl) ? m = ($ = i.callToAction.linkOptions) == null ? void 0 : $.externalUrl : ((A = i.callToAction.linkOptions) == null ? void 0 : A.linkType) === "internal" && ((S = (p = i.callToAction.linkOptions) == null ? void 0 : p.internalUrl) != null && S.slug.current) && (m = `/${(z = (_ = i.callToAction.linkOptions) == null ? void 0 : _.internalUrl) == null ? void 0 : z.slug.current}`), /* @__PURE__ */ c("div", { className: e.spotlight, children: [
65
65
  i.image && /* @__PURE__ */ a("div", { className: e.imageWrapper, children: /* @__PURE__ */ a(
66
66
  "img",
67
67
  {
@@ -72,15 +72,15 @@ const Oe = [
72
72
  }
73
73
  ) }),
74
74
  /* @__PURE__ */ c("div", { className: e.content, children: [
75
- i.title && /* @__PURE__ */ a("div", { className: e.title, children: b == null ? void 0 : b(i.title, e.title) }),
76
- i.description && /* @__PURE__ */ a("div", { className: e.description, children: b == null ? void 0 : b(i.description, e.description) })
75
+ i.title && /* @__PURE__ */ a("div", { className: e.title, children: f == null ? void 0 : f(i.title, e.title) }),
76
+ i.description && /* @__PURE__ */ a("div", { className: e.description, children: f == null ? void 0 : f(i.description, e.description) })
77
77
  ] }),
78
- ((m = i.callToAction) == null ? void 0 : m.linkOptions) && /* @__PURE__ */ a("div", { className: e.actions, children: /* @__PURE__ */ a(
78
+ ((h = i.callToAction) == null ? void 0 : h.linkOptions) && /* @__PURE__ */ a("div", { className: e.actions, children: /* @__PURE__ */ a(
79
79
  H,
80
80
  {
81
81
  as: "a",
82
82
  variant: i.callToAction.variant ?? "primary",
83
- href: h,
83
+ href: m,
84
84
  target: v ? "_blank" : "_self",
85
85
  rel: v ? "noopener noreferrer" : "",
86
86
  "aria-label": i.callToAction.ariaLabel || i.callToAction.label,
@@ -91,10 +91,10 @@ const Oe = [
91
91
  };
92
92
  function Ye({
93
93
  renderText: i,
94
- title: b,
94
+ title: f,
95
95
  logo: M,
96
96
  items: v,
97
- groups: h,
97
+ groups: m,
98
98
  utilityItems: s,
99
99
  isSticky: E = !1,
100
100
  showSearch: N = !0,
@@ -106,9 +106,9 @@ function Ye({
106
106
  localeSelectComponent: _,
107
107
  className: z
108
108
  }) {
109
- const [m, q] = f(!1), [J, k] = f(null), [he, ue] = f(0), [fe, be] = f(!1), [ke, ve] = f(null), [t, y] = f([]), [T, F] = f(
109
+ const [h, q] = b(!1), [J, k] = b(null), [me, ue] = b(0), [be, fe] = b(!1), [ke, ve] = b(null), [t, y] = b([]), [T, F] = b(
110
110
  0
111
- ), [pe, K] = f(null), [C, Ne] = f(!1), [x, R] = f("forward"), B = () => /* @__PURE__ */ a(
111
+ ), [pe, K] = b(null), [C, Ne] = b(!1), [x, R] = b("forward"), B = () => /* @__PURE__ */ a(
112
112
  "div",
113
113
  {
114
114
  className: `${e.linkWrapper} ${e.parent} ${e.searchWrapper}`,
@@ -119,7 +119,7 @@ function Ye({
119
119
  trigger: /* @__PURE__ */ a(
120
120
  "button",
121
121
  {
122
- role: "menuitem",
122
+ role: "button",
123
123
  title: "Search",
124
124
  "aria-label": "Search",
125
125
  className: e.search,
@@ -139,7 +139,7 @@ function Ye({
139
139
  {
140
140
  title: "Locale Select",
141
141
  "aria-label": "Locale Select",
142
- role: "menuitem",
142
+ role: "button",
143
143
  className: e.locale,
144
144
  children: /* @__PURE__ */ a(Te, { size: 16 })
145
145
  }
@@ -199,7 +199,7 @@ function Ye({
199
199
  }, []), ne = G(() => {
200
200
  if (L.current) {
201
201
  const n = L.current.getBoundingClientRect().width;
202
- ue(n), be(!0);
202
+ ue(n), fe(!0);
203
203
  }
204
204
  }, []);
205
205
  U(() => {
@@ -209,10 +209,10 @@ function Ye({
209
209
  };
210
210
  }, []), U(() => {
211
211
  if (typeof document < "u")
212
- return m ? setTimeout(() => {
212
+ return h ? setTimeout(() => {
213
213
  Ae();
214
- }, 0) : me(), () => me();
215
- }, [m]);
214
+ }, 0) : he(), () => he();
215
+ }, [h]);
216
216
  const Le = (n) => n.map((l, d) => {
217
217
  var ae, le, ie, se, ce;
218
218
  const u = `group-${d}`, W = pe === d, o = (ae = l.primaryItems) == null ? void 0 : ae[T ?? 0];
@@ -376,22 +376,22 @@ function Ye({
376
376
  "header",
377
377
  {
378
378
  ref: j,
379
- className: `${z ?? ""} ${Be[$]} ${Fe[A]} ${e.navbar} ${E ? e.sticky : ""} ${h && h.length ? e.advanced : e.default}`,
379
+ className: `${z ?? ""} ${Be[$]} ${Fe[A]} ${e.navbar} ${E ? e.sticky : ""} ${m && m.length ? e.advanced : e.default}`,
380
380
  "aria-label": "Main navigation",
381
381
  children: /* @__PURE__ */ c(
382
382
  "div",
383
383
  {
384
384
  className: `${e.container} ${(!s || s.length === 0) && $ !== "center" ? e.twoColumn : ""}`,
385
385
  children: [
386
- M ? /* @__PURE__ */ a("div", { className: e.logo, children: M }) : /* @__PURE__ */ a("div", { className: e.title, children: b }),
386
+ M ? /* @__PURE__ */ a("div", { className: e.logo, children: M }) : /* @__PURE__ */ a("div", { className: e.title, children: f }),
387
387
  /* @__PURE__ */ a(
388
388
  "nav",
389
389
  {
390
390
  ref: L,
391
391
  style: {
392
- left: $ === "center" ? `calc(50% - ${he / 2}px)` : "0"
392
+ left: $ === "center" ? `calc(50% - ${me / 2}px)` : "0"
393
393
  },
394
- className: `${e.nav} ${m ? e.open : ""} ${fe ? e.visible : e.hidden}`,
394
+ className: `${e.nav} ${h ? e.open : ""} ${be ? e.visible : e.hidden}`,
395
395
  id: "main-menu",
396
396
  role: "menubar",
397
397
  "aria-label": "Main navigation",
@@ -424,15 +424,15 @@ function Ye({
424
424
  ] }),
425
425
  w && /* @__PURE__ */ a(Q, {})
426
426
  ] }),
427
- !C && p === "advanced" && h && /* @__PURE__ */ c("div", { className: e.grid, children: [
428
- h.length > 0 && Le(h),
427
+ !C && p === "advanced" && m && /* @__PURE__ */ c("div", { className: e.grid, children: [
428
+ m.length > 0 && Le(m),
429
429
  N && /* @__PURE__ */ c(oe, { children: [
430
430
  /* @__PURE__ */ a("span", { className: e.separator }),
431
431
  /* @__PURE__ */ a(B, {})
432
432
  ] }),
433
433
  w && /* @__PURE__ */ a(Q, {})
434
434
  ] }),
435
- C && p === "advanced" && m && t.length === 0 && h && /* @__PURE__ */ a("div", { className: `${e.mobileMenu}`, children: h.map((n, l) => /* @__PURE__ */ a(
435
+ C && p === "advanced" && h && t.length === 0 && m && /* @__PURE__ */ a("div", { className: `${e.mobileMenu}`, children: m.map((n, l) => /* @__PURE__ */ a(
436
436
  "div",
437
437
  {
438
438
  className: `${e.mobileMenuItem} ${x === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
@@ -448,7 +448,7 @@ function Ye({
448
448
  },
449
449
  n._key ?? l
450
450
  )) }),
451
- C && p === "advanced" && m && t.length > 0 && /* @__PURE__ */ c(
451
+ C && p === "advanced" && h && t.length > 0 && /* @__PURE__ */ c(
452
452
  "div",
453
453
  {
454
454
  className: `${e.mobileMenuSlide} `,
@@ -600,7 +600,7 @@ function Ye({
600
600
  {
601
601
  role: "menu",
602
602
  "aria-label": "Utility navigation",
603
- className: `${e.utilityMobile} ${m ? e.open : ""}`,
603
+ className: `${e.utilityMobile} ${h ? e.open : ""}`,
604
604
  children: /* @__PURE__ */ a(de, { alignment: "center", children: /* @__PURE__ */ a(
605
605
  H,
606
606
  {
@@ -632,10 +632,10 @@ function Ye({
632
632
  {
633
633
  className: e.menuToggle,
634
634
  onClick: ye,
635
- "aria-label": m ? "Close menu" : "Open menu",
636
- "aria-expanded": m,
635
+ "aria-label": h ? "Close menu" : "Open menu",
636
+ "aria-expanded": h,
637
637
  "aria-controls": "main-menu",
638
- children: m ? /* @__PURE__ */ a(Se, { size: 24 }) : /* @__PURE__ */ a(Re, { size: 24 })
638
+ children: h ? /* @__PURE__ */ a(Se, { size: 24 }) : /* @__PURE__ */ a(Re, { size: 24 })
639
639
  }
640
640
  )
641
641
  ] })
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("react"),P=require("../../ui/PortableTextRenderer/index.cjs"),Q=require("../../hooks/useStyleClasses.cjs"),V=require("../../contexts/LocaleBridge.cjs"),N=require("../../../index-BN6814Bi.cjs"),Y=require("../../../core/components/Input/index.cjs"),F=require("../../../core/components/Select/index.cjs"),ee=require("../../cards/BlogArticleCard/index.cjs"),s=require("../../../CategoryFilters-tDVNMlQO.cjs"),se=require("../../../x-Dft9NVe_.cjs"),te=[{label:"Newest",value:"date-desc"},{label:"Oldest",value:"date-asc"},{label:"Title A-Z",value:"title-asc"},{label:"Title Z-A",value:"title-desc"},{label:"Most Popular",value:"popular-desc"}];function le({heading:o,layout:z="grid",includeFilters:S,excludeFilters:v,limit:j=3,categoryFilters:d,documentType:g,styleOptions:D,initialArticles:b=[],initialTotalCount:L=0,initialIncludeCategories:I=[]}){const[k,c]=t.useState(b),[H,O]=t.useState(L),[C,W]=t.useState("date-desc"),[u,q]=t.useState(I),[T,i]=t.useState(b.length),[a,A]=t.useState(!1),[x,y]=t.useState(!1),[E,r]=t.useState(b.length<L),[f,_]=t.useState(""),[p,Z]=t.useState(""),{locale:G}=V.useLocaleBridge(),U=Q.useStyleClasses(D),R=t.useRef(!1),X={list:s.styles.list}[z??"grid"],J=l=>{W(l.target.value),c([]),i(0),r(!0)},B=()=>{y(!x)},K=()=>{c([]),i(0),r(!0),q([]),_(""),y(!1)},$=async(l=!1)=>{if(a||!E)return;A(!0);const h=new URLSearchParams({start:l?"0":String(T),limit:String(j),sort:C,documentType:g,locale:G});p&&h.append("search",p),u.forEach(n=>h.append("categories",n)),S==null||S.forEach(n=>h.append("include",n._id)),v==null||v.forEach(n=>h.append("exclude",n._id));try{const m=await(await fetch(`/api/articles?${h.toString()}`,{method:"GET"})).json();c(w=>l?m.articles:[...w,...m.articles]),i(w=>l?j:w+j),O(m.totalCount),r(T+m.articles.length<m.totalCount)}catch(n){console.error("Failed to load articles:",n),r(!1)}finally{A(!1)}},M=t.useCallback(()=>{typeof window<"u"&&window.innerWidth>768&&(y(!1),typeof document<"u"&&(document.body.style.overflow=""))},[]);return t.useEffect(()=>{const l=typeof window<"u";return l&&window.addEventListener("resize",M),()=>{l&&window.removeEventListener("resize",M)}},[]),t.useEffect(()=>{if(typeof document<"u")return document.body.style.overflow=x?"hidden":"",()=>{document.body.style.overflow=""}},[x]),t.useEffect(()=>{const l=setTimeout(()=>{Z(f)},500);return()=>clearTimeout(l)},[f]),t.useEffect(()=>{if(!R.current){R.current=!0;return}(p||C!=="date-desc"||u.length>0)&&$(!0)},[p,C,u.join(",")]),e.jsx("section",{className:`${s.styles.documentList} ${U}`,children:e.jsxs("article",{className:s.styles.container,children:[e.jsxs("div",{className:s.styles.heading,children:[(o==null?void 0:o.title)&&e.jsx(P.RichText,{blocks:o==null?void 0:o.title}),(o==null?void 0:o.description)&&e.jsx(P.RichText,{blocks:o==null?void 0:o.description})]}),e.jsxs("div",{className:s.styles.listContainer,children:[(d==null?void 0:d.length)&&e.jsxs("div",{className:s.styles.filterToggle,children:[e.jsx(N.CallToAction,{as:"button",variant:"secondary",onClick:B,disabled:a,icon:"settings",iconAlignment:"left",children:"Filters"}),e.jsx(N.CallToAction,{as:"button",variant:"link",onClick:K,disabled:a||u.length===0&&f.length===0,children:"Reset"})]}),d&&e.jsx(s.CategoryFilters,{categoryFilters:d,selectedCategories:u,setSelectedCategories:q,setArticles:c,setStart:i,setHasMore:r,showFilters:x,toggleFilters:B,isLoading:a}),e.jsxs("div",{className:s.styles.listWrapper,children:[e.jsxs("div",{className:s.styles.listHeader,children:[e.jsxs("div",{className:s.styles.listResults,children:["Results: ",e.jsx("span",{children:H})]}),e.jsxs("div",{className:s.styles.listHeaderFilters,children:[e.jsxs("div",{className:s.styles.listSearch,children:[e.jsx(Y.Input,{type:"text",name:"list-search",placeholder:"Search articles",value:f,onChange:l=>{_(l.target.value),c([]),i(0),r(!0)}}),f&&e.jsx("button",{className:s.styles.clearSearch,onClick:()=>{_(""),c([]),i(0),r(!0)},children:e.jsx(se.X,{size:21})})]}),e.jsx("div",{className:s.styles.listSort,children:e.jsx(F.Select,{id:"list-sort",name:"list-sort",options:te,onChange:J})})]})]}),e.jsx("div",{className:`${s.styles.list} ${X}`,children:k&&k.map(l=>g=="blog"&&e.jsx(ee.BlogArticleCard,{article:l},l._id))}),E&&e.jsx("div",{className:s.styles.loadMore,children:e.jsx(N.CallToAction,{as:"button",variant:"primary",onClick:()=>$(!1),disabled:a,icon:"refresh",iconAlignment:"left",className:a?s.styles.buttonIsLoading:"",children:a?"Loading...":"Load more"})})]})]})]})})}exports.DocumentListBlock=le;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("react"),P=require("../../ui/PortableTextRenderer/index.cjs"),Q=require("../../hooks/useStyleClasses.cjs"),V=require("../../contexts/LocaleBridge.cjs"),N=require("../../../index-BN6814Bi.cjs"),Y=require("../../../core/components/Input/index.cjs"),F=require("../../../core/components/Select/index.cjs"),ee=require("../../cards/BlogArticleCard/index.cjs"),s=require("../../../CategoryFilters-tDVNMlQO.cjs"),se=require("../../../x-Dft9NVe_.cjs"),te=[{label:"Newest",value:"date-desc"},{label:"Oldest",value:"date-asc"},{label:"Title A-Z",value:"title-asc"},{label:"Title Z-A",value:"title-desc"},{label:"Most Popular",value:"popular-desc"}];function le({heading:o,layout:z="grid",includeFilters:p,excludeFilters:v,limit:b=3,categoryFilters:d,documentType:g,styleOptions:D,initialArticles:j=[],initialTotalCount:L=0,initialIncludeCategories:I=[]}){const[k,c]=t.useState(j),[H,O]=t.useState(L),[C,W]=t.useState("date-desc"),[u,q]=t.useState(I),[T,i]=t.useState(j.length),[a,A]=t.useState(!1),[x,y]=t.useState(!1),[E,r]=t.useState(j.length<L),[f,_]=t.useState(""),[S,Z]=t.useState(""),{locale:G}=V.useLocaleBridge(),U=Q.useStyleClasses(D),R=t.useRef(!1),X={list:s.styles.list}[z??"grid"],J=l=>{W(l.target.value),c([]),i(0),r(!0)},B=()=>{y(!x)},K=()=>{c([]),i(0),r(!0),q([]),_(""),y(!1)},$=async(l=!1)=>{if(a||!E)return;A(!0);const h=new URLSearchParams({start:l?"0":String(T),limit:String(b),sort:C,documentType:g,locale:G});S&&h.append("search",S),u.forEach(n=>h.append("categories",n)),p==null||p.forEach(n=>h.append("include",n._id)),v==null||v.forEach(n=>h.append("exclude",n._id));try{const m=await(await fetch(`/api/articles?${h.toString()}`,{method:"GET"})).json();c(w=>l?m.articles:[...w,...m.articles]),i(w=>l?b:w+b),O(m.totalCount),r(T+m.articles.length<m.totalCount)}catch(n){console.error("Failed to load articles:",n),r(!1)}finally{A(!1)}},M=t.useCallback(()=>{typeof window<"u"&&window.innerWidth>768&&(y(!1),typeof document<"u"&&(document.body.style.overflow=""))},[]);return t.useEffect(()=>{const l=typeof window<"u";return l&&window.addEventListener("resize",M),()=>{l&&window.removeEventListener("resize",M)}},[]),t.useEffect(()=>{if(typeof document<"u")return document.body.style.overflow=x?"hidden":"",()=>{document.body.style.overflow=""}},[x]),t.useEffect(()=>{const l=setTimeout(()=>{Z(f)},500);return()=>clearTimeout(l)},[f]),t.useEffect(()=>{if(!R.current){R.current=!0;return}(S||C!=="date-desc"||u.length>0)&&$(!0)},[S,C,u.join(",")]),e.jsx("section",{className:`${s.styles.documentList} ${U}`,children:e.jsxs("article",{className:s.styles.container,children:[e.jsxs("div",{className:s.styles.heading,children:[(o==null?void 0:o.title)&&e.jsx(P.RichText,{blocks:o==null?void 0:o.title}),(o==null?void 0:o.description)&&e.jsx(P.RichText,{blocks:o==null?void 0:o.description})]}),e.jsxs("div",{className:s.styles.listContainer,children:[(d==null?void 0:d.length)&&e.jsxs("div",{className:s.styles.filterToggle,children:[e.jsx(N.CallToAction,{as:"button",variant:"secondary",onClick:B,disabled:a,icon:"settings",iconAlignment:"left",children:"Filters"}),e.jsx(N.CallToAction,{as:"button",variant:"link",onClick:K,disabled:a||u.length===0&&f.length===0,children:"Reset"})]}),d&&e.jsx(s.CategoryFilters,{categoryFilters:d,selectedCategories:u,setSelectedCategories:q,setArticles:c,setStart:i,setHasMore:r,showFilters:x,toggleFilters:B,isLoading:a}),e.jsxs("div",{className:s.styles.listWrapper,children:[e.jsxs("div",{className:s.styles.listHeader,children:[e.jsxs("div",{className:s.styles.listResults,children:["Results: ",e.jsx("span",{children:H})]}),e.jsxs("div",{className:s.styles.listHeaderFilters,children:[e.jsxs("div",{className:s.styles.listSearch,children:[e.jsx(Y.Input,{type:"text",name:"list-search",placeholder:"Search articles",value:f,onChange:l=>{_(l.target.value),c([]),i(0),r(!0)}}),f&&e.jsx("button",{className:s.styles.clearSearch,onClick:()=>{_(""),c([]),i(0),r(!0)},children:e.jsx(se.X,{size:21})})]}),e.jsx("div",{className:s.styles.listSort,children:e.jsx(F.Select,{id:"list-sort",name:"list-sort",label:"Sort by",options:te,onChange:J})})]})]}),e.jsx("div",{className:`${s.styles.list} ${X}`,children:k&&k.map(l=>g=="blog"&&e.jsx(ee.BlogArticleCard,{article:l},l._id))}),E&&e.jsx("div",{className:s.styles.loadMore,children:e.jsx(N.CallToAction,{as:"button",variant:"primary",onClick:()=>$(!1),disabled:a,icon:"refresh",iconAlignment:"left",className:a?s.styles.buttonIsLoading:"",children:a?"Loading...":"Load more"})})]})]})]})})}exports.DocumentListBlock=le;
@@ -1,4 +1,4 @@
1
- import { jsx as e, jsxs as r } from "react/jsx-runtime";
1
+ import { jsx as e, jsxs as l } from "react/jsx-runtime";
2
2
  import { useState as a, useRef as Y, useCallback as F, useEffect as w } from "react";
3
3
  import { RichText as _ } from "../../ui/PortableTextRenderer/index.mjs";
4
4
  import { useStyleClasses as ee } from "../../hooks/useStyleClasses.mjs";
@@ -7,8 +7,8 @@ import { C as R } from "../../../index-C-E0ib2G.js";
7
7
  import { Input as se } from "../../../core/components/Input/index.mjs";
8
8
  import { Select as oe } from "../../../core/components/Select/index.mjs";
9
9
  import { BlogArticleCard as ae } from "../../cards/BlogArticleCard/index.mjs";
10
- import { s as t, C as re } from "../../../CategoryFilters-DJyQJ-ww.js";
11
- import { X as le } from "../../../x-CnsEH4Ox.js";
10
+ import { s as t, C as le } from "../../../CategoryFilters-DJyQJ-ww.js";
11
+ import { X as re } from "../../../x-CnsEH4Ox.js";
12
12
  const ne = [
13
13
  { label: "Newest", value: "date-desc" },
14
14
  { label: "Oldest", value: "date-asc" },
@@ -56,11 +56,11 @@ function we({
56
56
  locale: X
57
57
  });
58
58
  C && h.append("search", C), m.forEach(
59
- (l) => h.append("categories", l)
59
+ (r) => h.append("categories", r)
60
60
  ), S == null || S.forEach(
61
- (l) => h.append("include", l._id)
61
+ (r) => h.append("include", r._id)
62
62
  ), N == null || N.forEach(
63
- (l) => h.append("exclude", l._id)
63
+ (r) => h.append("exclude", r._id)
64
64
  );
65
65
  try {
66
66
  const p = await (await fetch(`/api/articles?${h.toString()}`, {
@@ -69,8 +69,8 @@ function we({
69
69
  i(
70
70
  (E) => s ? p.articles : [...E, ...p.articles]
71
71
  ), d((E) => s ? y : E + y), q(p.totalCount), c(j + p.articles.length < p.totalCount);
72
- } catch (l) {
73
- console.error("Failed to load articles:", l), c(!1);
72
+ } catch (r) {
73
+ console.error("Failed to load articles:", r), c(!1);
74
74
  } finally {
75
75
  z(!1);
76
76
  }
@@ -98,13 +98,13 @@ function we({
98
98
  return;
99
99
  }
100
100
  (C || L !== "date-desc" || m.length > 0) && P(!0);
101
- }, [C, L, m.join(",")]), /* @__PURE__ */ e("section", { className: `${t.documentList} ${J}`, children: /* @__PURE__ */ r("article", { className: t.container, children: [
102
- /* @__PURE__ */ r("div", { className: t.heading, children: [
101
+ }, [C, L, m.join(",")]), /* @__PURE__ */ e("section", { className: `${t.documentList} ${J}`, children: /* @__PURE__ */ l("article", { className: t.container, children: [
102
+ /* @__PURE__ */ l("div", { className: t.heading, children: [
103
103
  (o == null ? void 0 : o.title) && /* @__PURE__ */ e(_, { blocks: o == null ? void 0 : o.title }),
104
104
  (o == null ? void 0 : o.description) && /* @__PURE__ */ e(_, { blocks: o == null ? void 0 : o.description })
105
105
  ] }),
106
- /* @__PURE__ */ r("div", { className: t.listContainer, children: [
107
- (f == null ? void 0 : f.length) && /* @__PURE__ */ r("div", { className: t.filterToggle, children: [
106
+ /* @__PURE__ */ l("div", { className: t.listContainer, children: [
107
+ (f == null ? void 0 : f.length) && /* @__PURE__ */ l("div", { className: t.filterToggle, children: [
108
108
  /* @__PURE__ */ e(
109
109
  R,
110
110
  {
@@ -129,7 +129,7 @@ function we({
129
129
  )
130
130
  ] }),
131
131
  f && /* @__PURE__ */ e(
132
- re,
132
+ le,
133
133
  {
134
134
  categoryFilters: f,
135
135
  selectedCategories: m,
@@ -142,14 +142,14 @@ function we({
142
142
  isLoading: n
143
143
  }
144
144
  ),
145
- /* @__PURE__ */ r("div", { className: t.listWrapper, children: [
146
- /* @__PURE__ */ r("div", { className: t.listHeader, children: [
147
- /* @__PURE__ */ r("div", { className: t.listResults, children: [
145
+ /* @__PURE__ */ l("div", { className: t.listWrapper, children: [
146
+ /* @__PURE__ */ l("div", { className: t.listHeader, children: [
147
+ /* @__PURE__ */ l("div", { className: t.listResults, children: [
148
148
  "Results: ",
149
149
  /* @__PURE__ */ e("span", { children: Z })
150
150
  ] }),
151
- /* @__PURE__ */ r("div", { className: t.listHeaderFilters, children: [
152
- /* @__PURE__ */ r("div", { className: t.listSearch, children: [
151
+ /* @__PURE__ */ l("div", { className: t.listHeaderFilters, children: [
152
+ /* @__PURE__ */ l("div", { className: t.listSearch, children: [
153
153
  /* @__PURE__ */ e(
154
154
  se,
155
155
  {
@@ -169,7 +169,7 @@ function we({
169
169
  onClick: () => {
170
170
  k(""), i([]), d(0), c(!0);
171
171
  },
172
- children: /* @__PURE__ */ e(le, { size: 21 })
172
+ children: /* @__PURE__ */ e(re, { size: 21 })
173
173
  }
174
174
  )
175
175
  ] }),
@@ -178,6 +178,7 @@ function we({
178
178
  {
179
179
  id: "list-sort",
180
180
  name: "list-sort",
181
+ label: "Sort by",
181
182
  options: ne,
182
183
  onChange: Q
183
184
  }
@@ -3,4 +3,4 @@
3
3
  *
4
4
  * This source code is licensed under the ISC license.
5
5
  * See the LICENSE file in the root directory of this source tree.
6
- */const p=[["path",{d:"M7 7h10v10",key:"1tivn9"}],["path",{d:"M7 17 17 7",key:"1vkiza"}]],f=y.createLucideIcon("arrow-up-right",p),v="_item_1d7j0_1",I="_itemImage_1d7j0_14",N="_itemTitle_1d7j0_20",T="_callToAction_1d7j0_26",b="_icon_1d7j0_33",C="_single_1d7j0_39",w="_first_1d7j0_40",E="_itemContent_1d7j0_41",A="_itemExcerpt_1d7j0_113",$="_imagePlaceholder_1d7j0_179",L="_category_1d7j0_223",k="_itemEyebrow_1d7j0_242",i={item:v,itemImage:I,itemTitle:N,callToAction:T,icon:b,single:C,first:w,itemContent:E,itemExcerpt:A,imagePlaceholder:$,category:L,itemEyebrow:k};function q({article:e,className:_="",index:g,limit:u}){var a,l,m,d;const j=`/blog/articles/${e.slug.current}`,r=((a=e.categories)==null?void 0:a.find(n=>{var s,c;return!((c=(s=n.slug)==null?void 0:s.current)!=null&&c.startsWith("library/type"))}))??null,o=((l=e.categories)==null?void 0:l.find(n=>{var s,c;return(c=(s=n.slug)==null?void 0:s.current)==null?void 0:c.startsWith("library/type")}))??null;return t.jsxs(h.LocaleLink,{href:j,className:`${i.item} ${_??""} ${g===0?i.first:""} ${u===1?i.single:""}`,children:[t.jsxs("div",{className:i.itemImage,children:[o&&t.jsx("div",{className:i.category,children:o.title}),e.featuredImage&&e.featuredImage.imageUrl?t.jsx(x,{src:e.featuredImage.imageUrl??"",alt:((m=e.featuredImage)==null?void 0:m.asset.altText)||((d=e==null?void 0:e.featuredImage)==null?void 0:d.asset.description)||"Content image",fill:!0,sizes:"(max-width: 767px) 100vw, 300px",priority:!0}):t.jsx("div",{className:i.imagePlaceholder})]}),t.jsxs("div",{className:i.itemContent,children:[r&&t.jsx("div",{className:i.itemEyebrow,children:r.title}),t.jsxs("div",{className:i.itemTitle,children:[t.jsx("h3",{children:e.title}),t.jsx("div",{className:i.callToAction,children:t.jsx("div",{className:i.icon,children:t.jsx(f,{size:45})})})]}),e.excerpt&&t.jsx("p",{className:i.itemExcerpt,children:e.excerpt})]})]})}exports.BlogArticleCard=q;
6
+ */const p=[["path",{d:"M7 7h10v10",key:"1tivn9"}],["path",{d:"M7 17 17 7",key:"1vkiza"}]],f=y.createLucideIcon("arrow-up-right",p),v="_item_1d7j0_1",I="_itemImage_1d7j0_14",N="_itemTitle_1d7j0_20",T="_callToAction_1d7j0_26",b="_icon_1d7j0_33",C="_single_1d7j0_39",E="_first_1d7j0_40",w="_itemContent_1d7j0_41",A="_itemExcerpt_1d7j0_113",$="_imagePlaceholder_1d7j0_179",L="_category_1d7j0_223",k="_itemEyebrow_1d7j0_242",i={item:v,itemImage:I,itemTitle:N,callToAction:T,icon:b,single:C,first:E,itemContent:w,itemExcerpt:A,imagePlaceholder:$,category:L,itemEyebrow:k};function q({article:e,className:_="",index:g,limit:u}){var a,l,m,d;const j=`/blog/articles/${e.slug.current}`,r=((a=e.categories)==null?void 0:a.find(n=>{var s,c;return!((c=(s=n.slug)==null?void 0:s.current)!=null&&c.startsWith("library/type"))}))??null,o=((l=e.categories)==null?void 0:l.find(n=>{var s,c;return(c=(s=n.slug)==null?void 0:s.current)==null?void 0:c.startsWith("library/type")}))??null;return t.jsxs(h.LocaleLink,{href:j,className:`${i.item} ${_??""} ${g===0?i.first:""} ${u===1?i.single:""}`,children:[t.jsxs("div",{className:i.itemImage,children:[o&&t.jsx("div",{className:i.category,children:o.title}),e.featuredImage&&e.featuredImage.imageUrl?t.jsx(x,{src:e.featuredImage.imageUrl??"",alt:((m=e.featuredImage)==null?void 0:m.asset.altText)||((d=e==null?void 0:e.featuredImage)==null?void 0:d.asset.description)||"Content image",fill:!0,sizes:"(max-width: 767px) 800px, 300px",priority:!0}):t.jsx("div",{className:i.imagePlaceholder})]}),t.jsxs("div",{className:i.itemContent,children:[r&&t.jsx("div",{className:i.itemEyebrow,children:r.title}),t.jsxs("div",{className:i.itemTitle,children:[t.jsx("h3",{children:e.title}),t.jsx("div",{className:i.callToAction,children:t.jsx("div",{className:i.icon,children:t.jsx(f,{size:45})})})]}),e.excerpt&&t.jsx("p",{className:i.itemExcerpt,children:e.excerpt})]})]})}exports.BlogArticleCard=q;
@@ -11,14 +11,14 @@ import '../../../assets/index68.css';/**
11
11
  const x = [
12
12
  ["path", { d: "M7 7h10v10", key: "1tivn9" }],
13
13
  ["path", { d: "M7 17 17 7", key: "1vkiza" }]
14
- ], v = j("arrow-up-right", x), I = "_item_1d7j0_1", N = "_itemImage_1d7j0_14", T = "_itemTitle_1d7j0_20", w = "_callToAction_1d7j0_26", C = "_icon_1d7j0_33", E = "_single_1d7j0_39", b = "_first_1d7j0_40", A = "_itemContent_1d7j0_41", $ = "_itemExcerpt_1d7j0_113", k = "_imagePlaceholder_1d7j0_179", P = "_category_1d7j0_223", z = "_itemEyebrow_1d7j0_242", t = {
14
+ ], v = j("arrow-up-right", x), I = "_item_1d7j0_1", N = "_itemImage_1d7j0_14", T = "_itemTitle_1d7j0_20", C = "_callToAction_1d7j0_26", E = "_icon_1d7j0_33", b = "_single_1d7j0_39", w = "_first_1d7j0_40", A = "_itemContent_1d7j0_41", $ = "_itemExcerpt_1d7j0_113", k = "_imagePlaceholder_1d7j0_179", P = "_category_1d7j0_223", z = "_itemEyebrow_1d7j0_242", t = {
15
15
  item: I,
16
16
  itemImage: N,
17
17
  itemTitle: T,
18
- callToAction: w,
19
- icon: C,
20
- single: E,
21
- first: b,
18
+ callToAction: C,
19
+ icon: E,
20
+ single: b,
21
+ first: w,
22
22
  itemContent: A,
23
23
  itemExcerpt: $,
24
24
  imagePlaceholder: k,
@@ -58,7 +58,7 @@ function B({
58
58
  src: e.featuredImage.imageUrl ?? "",
59
59
  alt: ((d = e.featuredImage) == null ? void 0 : d.asset.altText) || ((_ = e == null ? void 0 : e.featuredImage) == null ? void 0 : _.asset.description) || "Content image",
60
60
  fill: !0,
61
- sizes: "(max-width: 767px) 100vw, 300px",
61
+ sizes: "(max-width: 767px) 800px, 300px",
62
62
  priority: !0
63
63
  }
64
64
  ) : /* @__PURE__ */ i("div", { className: t.imagePlaceholder })
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "quirk-ui",
3
3
  "private": false,
4
- "version": "0.0.510",
4
+ "version": "0.0.513",
5
5
  "type": "module",
6
6
  "exports": {
7
7
  ".": {