(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4574],{258:e=>{e.exports={style:{fontFamily:"'Roboto', 'Roboto Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_9b9904",variable:"__variable_9b9904"}},4441:e=>{e.exports={style:{fontFamily:"'Space Mono', monospace",fontStyle:"normal"},className:"__className_43ec4f",variable:"__variable_43ec4f"}},5989:e=>{e.exports={style:{fontFamily:"'Inconsolata', monospace",fontStyle:"normal"},className:"__className_74de3c",variable:"__variable_74de3c"}},7361:e=>{e.exports={style:{fontFamily:"'DM Mono', monospace",fontStyle:"normal"},className:"__className_d62096",variable:"__variable_d62096"}},10206:e=>{e.exports={style:{fontFamily:"'Fira Sans Extra Condensed', 'Fira Sans Extra Condensed Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_3b7d83",variable:"__variable_3b7d83"}},15253:e=>{e.exports={style:{fontFamily:"'Noto Sans', 'Noto Sans Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_d3752e",variable:"__variable_d3752e"}},16821:(e,t,n)=>{"use strict";n.d(t,{cr:()=>v,tU:()=>m,ab:()=>b});var r=n(34743),l=n(18080);function a(e,t,n){try{return e(t)}catch(e){return(0,r.R)("[nuqs] Error while parsing value `%s`: %O"+(n?" (for key `%s`)":""),t,e,n),null}}var o=function(){if("undefined"==typeof window||!window.GestureEvent)return 50;try{let e=navigator.userAgent?.match(/version\/([\d\.]+) safari/i);return parseFloat(e[1])>=17?120:320}catch{return 320}}(),i=new Map,s={history:"replace",scroll:!1,shallow:!0,throttleMs:o},u=new Set,c=0,f=null,d=n(7620);function p(e){function t(t){if(void 0===t)return null;let n="";if(Array.isArray(t)){if(void 0===t[0])return null;n=t[0]}return"string"==typeof t&&(n=t),a(e.parse,n)}return{eq:(e,t)=>e===t,...e,parseServerSide:t,withDefault(e){return{...this,defaultValue:e,parseServerSide(n){var r;return null!=(r=t(n))?r:e}}},withOptions(e){return{...this,...e}}}}var m=p({parse:e=>e,serialize:e=>"".concat(e)});p({parse:e=>{let t=parseInt(e);return Number.isNaN(t)?null:t},serialize:e=>Math.round(e).toFixed()}),p({parse:e=>{let t=parseInt(e,16);return Number.isNaN(t)?null:t},serialize:e=>{let t=Math.round(e).toString(16);return t.padStart(t.length+t.length%2,"0")}}),p({parse:e=>{let t=parseFloat(e);return Number.isNaN(t)?null:t},serialize:e=>e.toString()});var v=p({parse:e=>"true"===e,serialize:e=>e?"true":"false"});p({parse:e=>{let t=parseInt(e);return Number.isNaN(t)?null:new Date(t)},serialize:e=>e.valueOf().toString()}),p({parse:e=>{let t=new Date(e);return Number.isNaN(t.valueOf())?null:t},serialize:e=>e.toISOString()}),p({parse:e=>{let t=new Date(e.slice(0,10));return Number.isNaN(t.valueOf())?null:t},serialize:e=>e.toISOString().slice(0,10)});var y=function(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r?r.push(n):e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&(n?r.splice(r.indexOf(n)>>>0,1):e.set(t,[]))},emit:function(t,n){var r=e.get(t);r&&r.slice().map(function(e){e(n)}),(r=e.get("*"))&&r.slice().map(function(e){e(t,n)})}}}(),h={};function b(e){let{history:t="replace",scroll:n=!1,shallow:a=!0,throttleMs:p=o,clearOnDefault:m=!0,startTransition:v,urlKeys:b=h}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},_=Object.keys(e).join(","),N=(0,d.useMemo)(()=>Object.fromEntries(Object.keys(e).map(e=>{var t;return[e,null!=(t=b[e])?t:e]})),[_,b]),{searchParams:E,updateUrl:x,rateLimitFactor:S=1}=(0,l.V7)(),R=(0,d.useRef)({});if(Object.keys(R.current).length!==Object.keys(e).length){var C;R.current=Object.fromEntries(null!=(C=null==E?void 0:E.entries())?C:[])}let O=(0,d.useMemo)(()=>Object.fromEntries(Object.keys(e).map(t=>{var n;return[t,null!=(n=e[t].defaultValue)?n:null]})),[Object.values(e).map(e=>{let{defaultValue:t}=e;return t}).join(",")]),[j,M]=(0,d.useState)(()=>g(e,b,null!=E?E:new URLSearchParams)),F=(0,d.useRef)(j);(0,r.Y)("[nuq+ `%s`] render - state: %O, iSP: %s",_,j,E),(0,d.useEffect)(()=>{let t=g(e,b,E,R.current,F.current);F.current=t,M(t)},[Object.values(N).map(e=>null==E?void 0:E.get(e)).join("&")]),(0,d.useInsertionEffect)(()=>{let t=Object.keys(e).reduce((t,n)=>(t[n]=t=>{var l,a;let{state:o,query:i}=t,{defaultValue:s}=e[n],u=N[n];F.current={...F.current,[n]:null!=(l=null!=o?o:s)?l:null},R.current[u]=i,(0,r.Y)("[nuq+ `%s`] Cross-hook key sync %s: %O (default: %O). Resolved: %O",_,u,o,s,F.current),a=F.current,(0,r.Y)("[nuq+ `%s`] updateInternalState %O",_,a),F.current=a,M(a)},t),{});for(let n of Object.keys(e)){let e=N[n];(0,r.Y)("[nuq+ `%s`] Subscribing to sync for `%s`",_,e),y.on(e,t[n])}return()=>{for(let n of Object.keys(e)){let e=N[n];(0,r.Y)("[nuq+ `%s`] Unsubscribing to sync for `%s`",_,e),y.off(e,t[n])}}},[e,N]);let P=(0,d.useCallback)(function(d){var h,b,g,E,C,j,M,P,T,k,I,D,L,A,V;let q=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},U="function"==typeof d?d(w(F.current,O)):null===d?Object.fromEntries(Object.keys(e).map(e=>[e,null])):d;for(let[l,c]of((0,r.Y)("[nuq+ `%s`] setState: %O",_,U),Object.entries(U))){let f=e[l],d=N[l];f&&((null!=(b=null!=(h=q.clearOnDefault)?h:f.clearOnDefault)?b:m)&&null!==c&&void 0!==f.defaultValue&&(null!=(g=f.eq)?g:(e,t)=>e===t)(c,f.defaultValue)&&(c=null),R.current[d]=function(e,t,n,l){let a=null===t?null:n(t);return(0,r.Y)("[nuqs queue] Enqueueing %s=%s %O",e,a,l),i.set(e,a),"push"===l.history&&(s.history="push"),l.scroll&&(s.scroll=!0),!1===l.shallow&&(s.shallow=!1),l.startTransition&&u.add(l.startTransition),s.throttleMs=Math.max(l.throttleMs??o,Number.isFinite(s.throttleMs)?s.throttleMs:0),a}(d,c,null!=(E=f.serialize)?E:String,{history:null!=(j=null!=(C=q.history)?C:f.history)?j:t,shallow:null!=(P=null!=(M=q.shallow)?M:f.shallow)?P:a,scroll:null!=(k=null!=(T=q.scroll)?T:f.scroll)?k:n,throttleMs:null!=(D=null!=(I=q.throttleMs)?I:f.throttleMs)?D:p,startTransition:null!=(A=null!=(L=q.startTransition)?L:f.startTransition)?A:v}),y.emit(d,{state:c,query:null!=(V=R.current[d])?V:null}))}return null===f&&(f=new Promise((e,t)=>{if(!Number.isFinite(s.throttleMs)){(0,r.Y)("[nuqs queue] Skipping flush due to throttleMs=Infinity"),e(new URLSearchParams(location.search)),setTimeout(()=>{f=null},0);return}function n(){c=performance.now();let[n,a]=function(e){let t=new URLSearchParams(location.search);if(0===i.size)return[t,null];let n=Array.from(i.entries()),a={...s},c=Array.from(u);for(let[e,l]of(i.clear(),u.clear(),s.history="replace",s.scroll=!1,s.shallow=!0,s.throttleMs=o,(0,r.Y)("[nuqs queue] Flushing queue %O with options %O",n,a),n))null===l?t.delete(e):t.set(e,l);try{return function(e,t){let n=r=>{if(r===e.length)return t();let l=e[r];if(!l)throw Error("Invalid transition function");l(()=>n(r+1))};n(0)}(c,()=>{e(t,{history:a.history,scroll:a.scroll,shallow:a.shallow})}),[t,null]}catch(e){return console.error((0,l.z3)(429),n.map(([e])=>e).join(),e),[t,e]}}(x);null===a?e(n):t(n),f=null}setTimeout(function(){let e=performance.now()-c,t=s.throttleMs,l=S*Math.max(0,Math.min(t,t-e));(0,r.Y)("[nuqs queue] Scheduling flush in %f ms. Throttled at %f ms",l,t),0===l?n():setTimeout(n,l)},0)})),f},[e,t,a,n,p,v,N,x,S,O]);return[(0,d.useMemo)(()=>w(j,O),[j,O]),P]}function g(e,t,n,r,l){return Object.keys(e).reduce((o,s)=>{var u,c,f;let d=null!=(u=null==t?void 0:t[s])?u:s,{parse:p}=e[s],m=i.get(d),v=void 0===m?null!=(c=null==n?void 0:n.get(d))?c:null:m;if(r&&l&&r[d]===v)return o[s]=null!=(f=l[s])?f:null,o;let y=null===v?null:a(p,v,s);return o[s]=null!=y?y:null,r&&(r[d]=v),o},{})}function w(e,t){return Object.fromEntries(Object.keys(e).map(n=>{var r,l;return[n,null!=(l=null!=(r=e[n])?r:t[n])?l:null]}))}},18080:(e,t,n)=>{"use strict";n.d(t,{Hx:()=>s,OB:()=>o,V7:()=>u,z3:()=>a});var r=n(7620),l={404:"nuqs requires an adapter to work with your framework.",409:"Multiple versions of the library are loaded. This may lead to unexpected behavior. Currently using `%s`, but `%s` was about to load on top.",414:"Max safe URL length exceeded. Some browsers may not be able to accept this URL. Consider limiting the amount of state stored in the URL.",429:"URL update rate-limited by the browser. Consider increasing `throttleMs` for key(s) `%s`. %O",500:"Empty search params cache. Search params can't be accessed in Layouts.",501:"Search params cache already populated. Have you called `parse` twice?"};function a(e){return`[nuqs] ${l[e]} See https://err.47ng.com/NUQS-${e}`}function o(e){if(0===e.size)return"";let t=[];for(let[n,r]of e.entries()){let e=n.replace(/#/g,"%23").replace(/&/g,"%26").replace(/\+/g,"%2B").replace(/=/g,"%3D").replace(/\?/g,"%3F");t.push(`${e}=${r.replace(/%/g,"%25").replace(/\+/g,"%2B").replace(/ /g,"+").replace(/#/g,"%23").replace(/&/g,"%26").replace(/"/g,"%22").replace(/'/g,"%27").replace(/`/g,"%60").replace(//g,"%3E").replace(/[\x00-\x1F]/g,e=>encodeURIComponent(e))}`)}return"?"+t.join("&")}var i=(0,r.createContext)({useAdapter(){throw Error(a(404))}});function s(e){return({children:t,...n})=>(0,r.createElement)(i.Provider,{...n,value:{useAdapter:e}},t)}function u(){let e=(0,r.useContext)(i);if(!("useAdapter"in e))throw Error(a(404));return e.useAdapter()}i.displayName="NuqsAdapterContext"},19408:e=>{e.exports={style:{fontFamily:"'Lato', 'Lato Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_d62555",variable:"__variable_d62555"}},20758:e=>{e.exports={style:{fontFamily:"'Fira Code', monospace",fontStyle:"normal"},className:"__className_a9d83c",variable:"__variable_a9d83c"}},34086:e=>{e.exports={style:{fontFamily:"'Raleway', 'Raleway Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_45d4e2",variable:"__variable_45d4e2"}},34743:(e,t,n)=>{"use strict";n.d(t,{R:()=>a,Y:()=>l});var r=function(){try{if("undefined"==typeof localStorage)return!1;let e="nuqs-localStorage-test";localStorage.setItem(e,e);let t=localStorage.getItem(e)===e;if(localStorage.removeItem(e),!t)return!1}catch(e){return console.error("[nuqs]: debug mode is disabled (localStorage unavailable).",e),!1}return(localStorage.getItem("debug")??"").includes("nuqs")}();function l(e,...t){if(!r)return;let n=function(e,...t){return e.replace(/%[sfdO]/g,e=>{let n=t.shift();return"%O"===e&&n?JSON.stringify(n).replace(/"([^"]+)":/g,"$1:"):String(n)})}(e,...t);performance.mark(n),console.log(e,...t)}function a(e,...t){r&&console.warn(e,...t)}},38098:(e,t,n)=>{"use strict";n.d(t,{NuqsAdapter:()=>i});var r=n(18080),l=n(34743),a=n(62942),o=n(7620),i=(0,r.Hx)(function(){let e=(0,a.useRouter)(),t=(0,a.useSearchParams)(),[n,i]=(0,o.useOptimistic)(t);return{searchParams:n,updateUrl:(0,o.useCallback)((t,n)=>{(0,o.startTransition)(()=>{i(t)});let a=function(e,t){let n=e.split("#")[0]??"";return n+(0,r.OB)(t)+location.hash}(location.origin+location.pathname,t);(0,l.Y)("[nuqs queue (app)] Updating url: %s",a),("push"===n.history?history.pushState:history.replaceState).call(history,null,"",a),n.scroll&&window.scrollTo(0,0),n.shallow||e.replace(a,{scroll:!1})},[]),rateLimitFactor:2}})},39538:e=>{e.exports={style:{fontFamily:"'Ubuntu', 'Ubuntu Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_8eda71",variable:"__variable_8eda71"}},51212:e=>{e.exports={style:{fontFamily:"'Roboto Mono', monospace",fontStyle:"normal"},className:"__className_3fa647",variable:"__variable_3fa647"}},55739:e=>{e.exports={style:{fontFamily:"'Roboto Slab', 'Roboto Slab Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_dc9162",variable:"__variable_dc9162"}},57968:e=>{e.exports={style:{fontFamily:"'Overpass', 'Overpass Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_f5cad2",variable:"__variable_f5cad2"}},63034:(e,t,n)=>{"use strict";n.d(t,{UC:()=>e5,C1:()=>e3,q7:()=>e0,N_:()=>e2,B8:()=>eX,bL:()=>eQ,l9:()=>e1,LM:()=>e4});var r,l=n(7620),a=n.t(l,2),o=n(97509),i=n(80482);function s(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r.defaultPrevented)return t?.(r)}}function u(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function c(...e){return t=>{let n=!1,r=e.map(e=>{let r=u(e,t);return n||"function"!=typeof r||(n=!0),r});if(n)return()=>{for(let t=0;t{let{children:n,...r}=e,a=l.Children.toArray(n),o=a.find(y);if(o){let e=o.props.children,n=a.map(t=>t!==o?t:l.Children.count(e)>1?l.Children.only(null):l.isValidElement(e)?e.props.children:null);return(0,d.jsx)(m,{...r,ref:t,children:l.isValidElement(e)?l.cloneElement(e,void 0,n):null})}return(0,d.jsx)(m,{...r,ref:t,children:n})});p.displayName="Slot";var m=l.forwardRef((e,t)=>{let{children:n,...r}=e;if(l.isValidElement(n)){let e=function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(n=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}(n);return l.cloneElement(n,{...function(e,t){let n={...t};for(let r in t){let l=e[r],a=t[r];/^on[A-Z]/.test(r)?l&&a?n[r]=(...e)=>{a(...e),l(...e)}:l&&(n[r]=l):"style"===r?n[r]={...l,...a}:"className"===r&&(n[r]=[l,a].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props),ref:t?c(t,e):e})}return l.Children.count(n)>1?l.Children.only(null):null});m.displayName="SlotClone";var v=({children:e})=>(0,d.jsx)(d.Fragment,{children:e});function y(e){return l.isValidElement(e)&&e.type===v}var h=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce((e,t)=>{let n=l.forwardRef((e,n)=>{let{asChild:r,...l}=e,a=r?p:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,d.jsx)(a,{...l,ref:n})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function b(e,t){e&&o.flushSync(()=>e.dispatchEvent(t))}var g=n(87076),w=l.createContext(void 0),_=n(17247),N=e=>{let{present:t,children:n}=e,r=function(e){var t,n;let[r,a]=l.useState(),o=l.useRef({}),i=l.useRef(e),s=l.useRef("none"),[u,c]=(t=e?"mounted":"unmounted",n={mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}},l.useReducer((e,t)=>{let r=n[e][t];return null!=r?r:e},t));return l.useEffect(()=>{let e=E(o.current);s.current="mounted"===u?e:"none"},[u]),(0,_.N)(()=>{let t=o.current,n=i.current;if(n!==e){let r=s.current,l=E(t);e?c("MOUNT"):"none"===l||(null==t?void 0:t.display)==="none"?c("UNMOUNT"):n&&r!==l?c("ANIMATION_OUT"):c("UNMOUNT"),i.current=e}},[e,c]),(0,_.N)(()=>{if(r){var e;let t,n=null!=(e=r.ownerDocument.defaultView)?e:window,l=e=>{let l=E(o.current).includes(e.animationName);if(e.target===r&&l&&(c("ANIMATION_END"),!i.current)){let e=r.style.animationFillMode;r.style.animationFillMode="forwards",t=n.setTimeout(()=>{"forwards"===r.style.animationFillMode&&(r.style.animationFillMode=e)})}},a=e=>{e.target===r&&(s.current=E(o.current))};return r.addEventListener("animationstart",a),r.addEventListener("animationcancel",l),r.addEventListener("animationend",l),()=>{n.clearTimeout(t),r.removeEventListener("animationstart",a),r.removeEventListener("animationcancel",l),r.removeEventListener("animationend",l)}}c("ANIMATION_END")},[r,c]),{isPresent:["mounted","unmountSuspended"].includes(u),ref:l.useCallback(e=>{e&&(o.current=getComputedStyle(e)),a(e)},[])}}(t),a="function"==typeof n?n({present:r.isPresent}):l.Children.only(n),o=f(r.ref,function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,l=r&&"isReactWarning"in r&&r.isReactWarning;return l?e.ref:(l=(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get)&&"isReactWarning"in r&&r.isReactWarning)?e.props.ref:e.props.ref||e.ref}(a));return"function"==typeof n||r.isPresent?l.cloneElement(a,{ref:o}):null};function E(e){return(null==e?void 0:e.animationName)||"none"}N.displayName="Presence";var x=a["useId".toString()]||(()=>void 0),S=0;function R(e){let[t,n]=l.useState(x());return(0,_.N)(()=>{e||n(e=>e??String(S++))},[e]),e||(t?`radix-${t}`:"")}function C(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function O(...e){return t=>{let n=!1,r=e.map(e=>{let r=C(e,t);return n||"function"!=typeof r||(n=!0),r});if(n)return()=>{for(let t=0;t{let{children:n,...r}=e,a=l.Children.toArray(n),o=a.find(T);if(o){let e=o.props.children,n=a.map(t=>t!==o?t:l.Children.count(e)>1?l.Children.only(null):l.isValidElement(e)?e.props.children:null);return(0,d.jsx)(F,{...r,ref:t,children:l.isValidElement(e)?l.cloneElement(e,void 0,n):null})}return(0,d.jsx)(F,{...r,ref:t,children:n})});M.displayName="Slot";var F=l.forwardRef((e,t)=>{let{children:n,...r}=e;if(l.isValidElement(n)){let e=function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(n=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}(n);return l.cloneElement(n,{...function(e,t){let n={...t};for(let r in t){let l=e[r],a=t[r];/^on[A-Z]/.test(r)?l&&a?n[r]=(...e)=>{a(...e),l(...e)}:l&&(n[r]=l):"style"===r?n[r]={...l,...a}:"className"===r&&(n[r]=[l,a].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props),ref:t?O(t,e):e})}return l.Children.count(n)>1?l.Children.only(null):null});F.displayName="SlotClone";var P=({children:e})=>(0,d.jsx)(d.Fragment,{children:e});function T(e){return l.isValidElement(e)&&e.type===P}function k(e){let t=e+"CollectionProvider",[n,r]=(0,i.A)(t),[a,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),s=e=>{let{scope:t,children:n}=e,r=l.useRef(null),o=l.useRef(new Map).current;return(0,d.jsx)(a,{scope:t,itemMap:o,collectionRef:r,children:n})};s.displayName=t;let u=e+"CollectionSlot",c=l.forwardRef((e,t)=>{let{scope:n,children:r}=e,l=j(t,o(u,n).collectionRef);return(0,d.jsx)(M,{ref:l,children:r})});c.displayName=u;let f=e+"CollectionItemSlot",p="data-radix-collection-item",m=l.forwardRef((e,t)=>{let{scope:n,children:r,...a}=e,i=l.useRef(null),s=j(t,i),u=o(f,n);return l.useEffect(()=>(u.itemMap.set(i,{ref:i,...a}),()=>void u.itemMap.delete(i))),(0,d.jsx)(M,{...{[p]:""},ref:s,children:r})});return m.displayName=f,[{Provider:s,Slot:c,ItemSlot:m},function(t){let n=o(e+"CollectionConsumer",t);return l.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll("[".concat(p,"]")));return Array.from(n.itemMap.values()).sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current))},[n.collectionRef,n.itemMap])},r]}function I(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r.defaultPrevented)return t?.(r)}}function D(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function L(...e){return t=>{let n=!1,r=e.map(e=>{let r=D(e,t);return n||"function"!=typeof r||(n=!0),r});if(n)return()=>{for(let t=0;t{let{children:n,...r}=e,a=l.Children.toArray(n),o=a.find(W);if(o){let e=o.props.children,n=a.map(t=>t!==o?t:l.Children.count(e)>1?l.Children.only(null):l.isValidElement(e)?e.props.children:null);return(0,d.jsx)(q,{...r,ref:t,children:l.isValidElement(e)?l.cloneElement(e,void 0,n):null})}return(0,d.jsx)(q,{...r,ref:t,children:n})});V.displayName="Slot";var q=l.forwardRef((e,t)=>{let{children:n,...r}=e;if(l.isValidElement(n)){let e=function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(n=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}(n);return l.cloneElement(n,{...function(e,t){let n={...t};for(let r in t){let l=e[r],a=t[r];/^on[A-Z]/.test(r)?l&&a?n[r]=(...e)=>{a(...e),l(...e)}:l&&(n[r]=l):"style"===r?n[r]={...l,...a}:"className"===r&&(n[r]=[l,a].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props),ref:t?L(t,e):e})}return l.Children.count(n)>1?l.Children.only(null):null});q.displayName="SlotClone";var U=({children:e})=>(0,d.jsx)(d.Fragment,{children:e});function W(e){return l.isValidElement(e)&&e.type===U}var z=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce((e,t)=>{let n=l.forwardRef((e,n)=>{let{asChild:r,...l}=e,a=r?V:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,d.jsx)(a,{...l,ref:n})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{}),B=n(93568),K=n(57314),Y="dismissableLayer.update",$=l.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),H=l.forwardRef((e,t)=>{var n,a;let{disableOutsidePointerEvents:o=!1,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:u,onInteractOutside:c,onDismiss:f,...p}=e,m=l.useContext($),[v,y]=l.useState(null),h=null!=(a=null==v?void 0:v.ownerDocument)?a:null==(n=globalThis)?void 0:n.document,[,b]=l.useState({}),g=A(t,e=>y(e)),w=Array.from(m.layers),[_]=[...m.layersWithOutsidePointerEventsDisabled].slice(-1),N=w.indexOf(_),E=v?w.indexOf(v):-1,x=m.layersWithOutsidePointerEventsDisabled.size>0,S=E>=N,R=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null==(t=globalThis)?void 0:t.document,r=(0,B.c)(e),a=l.useRef(!1),o=l.useRef(()=>{});return l.useEffect(()=>{let e=e=>{if(e.target&&!a.current){let t=function(){G("dismissableLayer.pointerDownOutside",r,l,{discrete:!0})},l={originalEvent:e};"touch"===e.pointerType?(n.removeEventListener("click",o.current),o.current=t,n.addEventListener("click",o.current,{once:!0})):t()}else n.removeEventListener("click",o.current);a.current=!1},t=window.setTimeout(()=>{n.addEventListener("pointerdown",e)},0);return()=>{window.clearTimeout(t),n.removeEventListener("pointerdown",e),n.removeEventListener("click",o.current)}},[n,r]),{onPointerDownCapture:()=>a.current=!0}}(e=>{let t=e.target,n=[...m.branches].some(e=>e.contains(t));S&&!n&&(null==s||s(e),null==c||c(e),e.defaultPrevented||null==f||f())},h),C=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null==(t=globalThis)?void 0:t.document,r=(0,B.c)(e),a=l.useRef(!1);return l.useEffect(()=>{let e=e=>{e.target&&!a.current&&G("dismissableLayer.focusOutside",r,{originalEvent:e},{discrete:!1})};return n.addEventListener("focusin",e),()=>n.removeEventListener("focusin",e)},[n,r]),{onFocusCapture:()=>a.current=!0,onBlurCapture:()=>a.current=!1}}(e=>{let t=e.target;![...m.branches].some(e=>e.contains(t))&&(null==u||u(e),null==c||c(e),e.defaultPrevented||null==f||f())},h);return(0,K.U)(e=>{E===m.layers.size-1&&(null==i||i(e),!e.defaultPrevented&&f&&(e.preventDefault(),f()))},h),l.useEffect(()=>{if(v)return o&&(0===m.layersWithOutsidePointerEventsDisabled.size&&(r=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),m.layersWithOutsidePointerEventsDisabled.add(v)),m.layers.add(v),Z(),()=>{o&&1===m.layersWithOutsidePointerEventsDisabled.size&&(h.body.style.pointerEvents=r)}},[v,h,o,m]),l.useEffect(()=>()=>{v&&(m.layers.delete(v),m.layersWithOutsidePointerEventsDisabled.delete(v),Z())},[v,m]),l.useEffect(()=>{let e=()=>b({});return document.addEventListener(Y,e),()=>document.removeEventListener(Y,e)},[]),(0,d.jsx)(z.div,{...p,ref:g,style:{pointerEvents:x?S?"auto":"none":void 0,...e.style},onFocusCapture:I(e.onFocusCapture,C.onFocusCapture),onBlurCapture:I(e.onBlurCapture,C.onBlurCapture),onPointerDownCapture:I(e.onPointerDownCapture,R.onPointerDownCapture)})});function Z(){let e=new CustomEvent(Y);document.dispatchEvent(e)}function G(e,t,n,r){let{discrete:l}=r,a=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});if(t&&a.addEventListener(e,t,{once:!0}),l)a&&o.flushSync(()=>a.dispatchEvent(i));else a.dispatchEvent(i)}H.displayName="DismissableLayer",l.forwardRef((e,t)=>{let n=l.useContext($),r=l.useRef(null),a=A(t,r);return l.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,d.jsx)(z.div,{...e,ref:a})}).displayName="DismissableLayerBranch";var J=n(22702);function Q(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}var X=l.forwardRef((e,t)=>{let{children:n,...r}=e,a=l.Children.toArray(n),o=a.find(en);if(o){let e=o.props.children,n=a.map(t=>t!==o?t:l.Children.count(e)>1?l.Children.only(null):l.isValidElement(e)?e.props.children:null);return(0,d.jsx)(ee,{...r,ref:t,children:l.isValidElement(e)?l.cloneElement(e,void 0,n):null})}return(0,d.jsx)(ee,{...r,ref:t,children:n})});X.displayName="Slot";var ee=l.forwardRef((e,t)=>{let{children:n,...r}=e;if(l.isValidElement(n)){let e=function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(n=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}(n);return l.cloneElement(n,{...function(e,t){let n={...t};for(let r in t){let l=e[r],a=t[r];/^on[A-Z]/.test(r)?l&&a?n[r]=(...e)=>{a(...e),l(...e)}:l&&(n[r]=l):"style"===r?n[r]={...l,...a}:"className"===r&&(n[r]=[l,a].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props),ref:t?function(...e){return t=>{let n=!1,r=e.map(e=>{let r=Q(e,t);return n||"function"!=typeof r||(n=!0),r});if(n)return()=>{for(let t=0;t1?l.Children.only(null):null});ee.displayName="SlotClone";var et=({children:e})=>(0,d.jsx)(d.Fragment,{children:e});function en(e){return l.isValidElement(e)&&e.type===et}var er=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce((e,t)=>{let n=l.forwardRef((e,n)=>{let{asChild:r,...l}=e,a=r?X:t;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,d.jsx)(a,{...l,ref:n})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{}),el=l.forwardRef((e,t)=>(0,d.jsx)(er.span,{...e,ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}));el.displayName="VisuallyHidden";var ea="NavigationMenu",[eo,ei,es]=k(ea),[eu,ec,ef]=k(ea),[ed,ep]=(0,i.A)(ea,[es,ef]),[em,ev]=ed(ea),[ey,eh]=ed(ea),eb=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,value:r,onValueChange:a,defaultValue:o,delayDuration:i=200,skipDelayDuration:s=300,orientation:u="horizontal",dir:c,...p}=e,[m,v]=l.useState(null),y=f(t,e=>v(e)),b=function(e){let t=l.useContext(w);return e||t||"ltr"}(c),_=l.useRef(0),N=l.useRef(0),E=l.useRef(0),[x,S]=l.useState(!0),[R="",C]=(0,g.i)({prop:r,onChange:e=>{let t=s>0;""!==e?(window.clearTimeout(E.current),t&&S(!1)):(window.clearTimeout(E.current),E.current=window.setTimeout(()=>S(!0),s)),null==a||a(e)},defaultProp:o}),O=l.useCallback(()=>{window.clearTimeout(N.current),N.current=window.setTimeout(()=>C(""),150)},[C]),j=l.useCallback(e=>{window.clearTimeout(N.current),C(e)},[C]),M=l.useCallback(e=>{R===e?window.clearTimeout(N.current):_.current=window.setTimeout(()=>{window.clearTimeout(N.current),C(e)},i)},[R,C,i]);return l.useEffect(()=>()=>{window.clearTimeout(_.current),window.clearTimeout(N.current),window.clearTimeout(E.current)},[]),(0,d.jsx)(ew,{scope:n,isRootMenu:!0,value:R,dir:b,orientation:u,rootNavigationMenu:m,onTriggerEnter:e=>{window.clearTimeout(_.current),x?M(e):j(e)},onTriggerLeave:()=>{window.clearTimeout(_.current),O()},onContentEnter:()=>window.clearTimeout(N.current),onContentLeave:O,onItemSelect:e=>{C(t=>t===e?"":e)},onItemDismiss:()=>C(""),children:(0,d.jsx)(h.nav,{"aria-label":"Main","data-orientation":u,dir:b,...p,ref:y})})});eb.displayName=ea;var eg="NavigationMenuSub";l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,value:r,onValueChange:l,defaultValue:a,orientation:o="horizontal",...i}=e,s=ev(eg,n),[u="",c]=(0,g.i)({prop:r,onChange:l,defaultProp:a});return(0,d.jsx)(ew,{scope:n,isRootMenu:!1,value:u,dir:s.dir,orientation:o,rootNavigationMenu:s.rootNavigationMenu,onTriggerEnter:e=>c(e),onItemSelect:e=>c(e),onItemDismiss:()=>c(""),children:(0,d.jsx)(h.div,{"data-orientation":o,...i,ref:t})})}).displayName=eg;var ew=e=>{let{scope:t,isRootMenu:n,rootNavigationMenu:r,dir:a,orientation:o,children:i,value:s,onItemSelect:u,onItemDismiss:c,onTriggerEnter:f,onTriggerLeave:p,onContentEnter:m,onContentLeave:v}=e,[y,h]=l.useState(null),[b,g]=l.useState(new Map),[w,_]=l.useState(null);return(0,d.jsx)(em,{scope:t,isRootMenu:n,rootNavigationMenu:r,value:s,previousValue:(0,J.Z)(s),baseId:R(),dir:a,orientation:o,viewport:y,onViewportChange:h,indicatorTrack:w,onIndicatorTrackChange:_,onTriggerEnter:(0,B.c)(f),onTriggerLeave:(0,B.c)(p),onContentEnter:(0,B.c)(m),onContentLeave:(0,B.c)(v),onItemSelect:(0,B.c)(u),onItemDismiss:(0,B.c)(c),onViewportContentChange:l.useCallback((e,t)=>{g(n=>(n.set(e,t),new Map(n)))},[]),onViewportContentRemove:l.useCallback(e=>{g(t=>t.has(e)?(t.delete(e),new Map(t)):t)},[]),children:(0,d.jsx)(eo.Provider,{scope:t,children:(0,d.jsx)(ey,{scope:t,items:b,children:i})})})},e_="NavigationMenuList",eN=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,...r}=e,l=ev(e_,n),a=(0,d.jsx)(h.ul,{"data-orientation":l.orientation,...r,ref:t});return(0,d.jsx)(h.div,{style:{position:"relative"},ref:l.onIndicatorTrackChange,children:(0,d.jsx)(eo.Slot,{scope:n,children:l.isRootMenu?(0,d.jsx)(eW,{asChild:!0,children:a}):a})})});eN.displayName=e_;var eE="NavigationMenuItem",[ex,eS]=ed(eE),eR=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,value:r,...a}=e,o=R(),i=l.useRef(null),s=l.useRef(null),u=l.useRef(null),c=l.useRef(()=>{}),f=l.useRef(!1),p=l.useCallback(function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"start";if(i.current){c.current();let t=eK(i.current);t.length&&eY("start"===e?t:t.reverse())}},[]),m=l.useCallback(()=>{if(i.current){let e=eK(i.current);e.length&&(c.current=function(e){return e.forEach(e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")}),()=>{e.forEach(e=>{let t=e.dataset.tabindex;e.setAttribute("tabindex",t)})}}(e))}},[]);return(0,d.jsx)(ex,{scope:n,value:r||o||"LEGACY_REACT_AUTO_VALUE",triggerRef:s,contentRef:i,focusProxyRef:u,wasEscapeCloseRef:f,onEntryKeyDown:p,onFocusProxyEnter:p,onRootContentClose:m,onContentFocusOutside:m,children:(0,d.jsx)(h.li,{...a,ref:t})})});eR.displayName=eE;var eC="NavigationMenuTrigger",eO=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,disabled:r,...a}=e,o=ev(eC,e.__scopeNavigationMenu),i=eS(eC,e.__scopeNavigationMenu),u=l.useRef(null),c=f(u,i.triggerRef,t),p=eZ(o.baseId,i.value),m=eG(o.baseId,i.value),v=l.useRef(!1),y=l.useRef(!1),b=i.value===o.value;return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(eo.ItemSlot,{scope:n,value:i.value,children:(0,d.jsx)(eB,{asChild:!0,children:(0,d.jsx)(h.button,{id:p,disabled:r,"data-disabled":r?"":void 0,"data-state":eH(b),"aria-expanded":b,"aria-controls":m,...a,ref:c,onPointerEnter:s(e.onPointerEnter,()=>{y.current=!1,i.wasEscapeCloseRef.current=!1}),onPointerMove:s(e.onPointerMove,eJ(()=>{r||y.current||i.wasEscapeCloseRef.current||v.current||(o.onTriggerEnter(i.value),v.current=!0)})),onPointerLeave:s(e.onPointerLeave,eJ(()=>{r||(o.onTriggerLeave(),v.current=!1)})),onClick:s(e.onClick,()=>{o.onItemSelect(i.value),y.current=b}),onKeyDown:s(e.onKeyDown,e=>{let t={horizontal:"ArrowDown",vertical:"rtl"===o.dir?"ArrowLeft":"ArrowRight"}[o.orientation];b&&e.key===t&&(i.onEntryKeyDown(),e.preventDefault())})})})}),b&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(el,{"aria-hidden":!0,tabIndex:0,ref:i.focusProxyRef,onFocus:e=>{let t=i.contentRef.current,n=e.relatedTarget,r=n===u.current,l=null==t?void 0:t.contains(n);(r||!l)&&i.onFocusProxyEnter(r?"start":"end")}}),o.viewport&&(0,d.jsx)("span",{"aria-owns":m})]})]})});eO.displayName=eC;var ej="navigationMenu.linkSelect",eM=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,active:r,onSelect:l,...a}=e;return(0,d.jsx)(eB,{asChild:!0,children:(0,d.jsx)(h.a,{"data-active":r?"":void 0,"aria-current":r?"page":void 0,...a,ref:t,onClick:s(e.onClick,e=>{let t=e.target,n=new CustomEvent(ej,{bubbles:!0,cancelable:!0});t.addEventListener(ej,e=>null==l?void 0:l(e),{once:!0}),b(t,n),n.defaultPrevented||e.metaKey||b(t,new CustomEvent(eL,{bubbles:!0,cancelable:!0}))},{checkForDefaultPrevented:!1})})})});eM.displayName="NavigationMenuLink";var eF="NavigationMenuIndicator",eP=l.forwardRef((e,t)=>{let{forceMount:n,...r}=e,l=ev(eF,e.__scopeNavigationMenu),a=!!l.value;return l.indicatorTrack?o.createPortal((0,d.jsx)(N,{present:n||a,children:(0,d.jsx)(eT,{...r,ref:t})}),l.indicatorTrack):null});eP.displayName=eF;var eT=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,...r}=e,a=ev(eF,n),o=ei(n),[i,s]=l.useState(null),[u,c]=l.useState(null),f="horizontal"===a.orientation,p=!!a.value;l.useEffect(()=>{var e;let t=null==(e=o().find(e=>e.value===a.value))?void 0:e.ref.current;t&&s(t)},[o,a.value]);let m=()=>{i&&c({size:f?i.offsetWidth:i.offsetHeight,offset:f?i.offsetLeft:i.offsetTop})};return e$(i,m),e$(a.indicatorTrack,m),u?(0,d.jsx)(h.div,{"aria-hidden":!0,"data-state":p?"visible":"hidden","data-orientation":a.orientation,...r,ref:t,style:{position:"absolute",...f?{left:0,width:u.size+"px",transform:"translateX(".concat(u.offset,"px)")}:{top:0,height:u.size+"px",transform:"translateY(".concat(u.offset,"px)")},...r.style}}):null}),ek="NavigationMenuContent",eI=l.forwardRef((e,t)=>{let{forceMount:n,...r}=e,l=ev(ek,e.__scopeNavigationMenu),a=eS(ek,e.__scopeNavigationMenu),o=f(a.contentRef,t),i=a.value===l.value,u={value:a.value,triggerRef:a.triggerRef,focusProxyRef:a.focusProxyRef,wasEscapeCloseRef:a.wasEscapeCloseRef,onContentFocusOutside:a.onContentFocusOutside,onRootContentClose:a.onRootContentClose,...r};return l.viewport?(0,d.jsx)(eD,{forceMount:n,...u,ref:o}):(0,d.jsx)(N,{present:n||i,children:(0,d.jsx)(eA,{"data-state":eH(i),...u,ref:o,onPointerEnter:s(e.onPointerEnter,l.onContentEnter),onPointerLeave:s(e.onPointerLeave,eJ(l.onContentLeave)),style:{pointerEvents:!i&&l.isRootMenu?"none":void 0,...u.style}})})});eI.displayName=ek;var eD=l.forwardRef((e,t)=>{let{onViewportContentChange:n,onViewportContentRemove:r}=ev(ek,e.__scopeNavigationMenu);return(0,_.N)(()=>{n(e.value,{ref:t,...e})},[e,t,n]),(0,_.N)(()=>()=>r(e.value),[e.value,r]),null}),eL="navigationMenu.rootContentDismiss",eA=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,value:r,triggerRef:a,focusProxyRef:o,wasEscapeCloseRef:i,onRootContentClose:u,onContentFocusOutside:c,...p}=e,m=ev(ek,n),v=l.useRef(null),y=f(v,t),h=eZ(m.baseId,r),b=eG(m.baseId,r),g=ei(n),w=l.useRef(null),{onItemDismiss:_}=m;l.useEffect(()=>{let e=v.current;if(m.isRootMenu&&e){let t=()=>{var t;_(),u(),e.contains(document.activeElement)&&(null==(t=a.current)||t.focus())};return e.addEventListener(eL,t),()=>e.removeEventListener(eL,t)}},[m.isRootMenu,e.value,a,_,u]);let N=l.useMemo(()=>{let e=g().map(e=>e.value);"rtl"===m.dir&&e.reverse();let t=e.indexOf(m.value),n=e.indexOf(m.previousValue),l=r===m.value,a=n===e.indexOf(r);if(!l&&!a)return w.current;let o=(()=>{if(t!==n){if(l&&-1!==n)return t>n?"from-end":"from-start";if(a&&-1!==t)return t>n?"to-start":"to-end"}return null})();return w.current=o,o},[m.previousValue,m.value,m.dir,g,r]);return(0,d.jsx)(eW,{asChild:!0,children:(0,d.jsx)(H,{id:b,"aria-labelledby":h,"data-motion":N,"data-orientation":m.orientation,...p,ref:y,disableOutsidePointerEvents:!1,onDismiss:()=>{var e;let t=new Event(eL,{bubbles:!0,cancelable:!0});null==(e=v.current)||e.dispatchEvent(t)},onFocusOutside:s(e.onFocusOutside,e=>{var t;c();let n=e.target;(null==(t=m.rootNavigationMenu)?void 0:t.contains(n))&&e.preventDefault()}),onPointerDownOutside:s(e.onPointerDownOutside,e=>{var t;let n=e.target,r=g().some(e=>{var t;return null==(t=e.ref.current)?void 0:t.contains(n)}),l=m.isRootMenu&&(null==(t=m.viewport)?void 0:t.contains(n));(r||l||!m.isRootMenu)&&e.preventDefault()}),onKeyDown:s(e.onKeyDown,e=>{let t=e.altKey||e.ctrlKey||e.metaKey;if("Tab"===e.key&&!t){let t=eK(e.currentTarget),r=document.activeElement,l=t.findIndex(e=>e===r);if(eY(e.shiftKey?t.slice(0,l).reverse():t.slice(l+1,t.length)))e.preventDefault();else{var n;null==(n=o.current)||n.focus()}}}),onEscapeKeyDown:s(e.onEscapeKeyDown,e=>{i.current=!0})})})}),eV="NavigationMenuViewport",eq=l.forwardRef((e,t)=>{let{forceMount:n,...r}=e,l=!!ev(eV,e.__scopeNavigationMenu).value;return(0,d.jsx)(N,{present:n||l,children:(0,d.jsx)(eU,{...r,ref:t})})});eq.displayName=eV;var eU=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,children:r,...a}=e,o=ev(eV,n),i=f(t,o.onViewportChange),u=eh(ek,e.__scopeNavigationMenu),[p,m]=l.useState(null),[v,y]=l.useState(null),b=p?(null==p?void 0:p.width)+"px":void 0,g=p?(null==p?void 0:p.height)+"px":void 0,w=!!o.value,_=w?o.value:o.previousValue;return e$(v,()=>{v&&m({width:v.offsetWidth,height:v.offsetHeight})}),(0,d.jsx)(h.div,{"data-state":eH(w),"data-orientation":o.orientation,...a,ref:i,style:{pointerEvents:!w&&o.isRootMenu?"none":void 0,"--radix-navigation-menu-viewport-width":b,"--radix-navigation-menu-viewport-height":g,...a.style},onPointerEnter:s(e.onPointerEnter,o.onContentEnter),onPointerLeave:s(e.onPointerLeave,eJ(o.onContentLeave)),children:Array.from(u.items).map(e=>{let[t,{ref:n,forceMount:r,...l}]=e,a=_===t;return(0,d.jsx)(N,{present:r||a,children:(0,d.jsx)(eA,{...l,ref:c(n,e=>{a&&e&&y(e)})})},t)})})}),eW=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,...r}=e,l=ev("FocusGroup",n);return(0,d.jsx)(eu.Provider,{scope:n,children:(0,d.jsx)(eu.Slot,{scope:n,children:(0,d.jsx)(h.div,{dir:l.dir,...r,ref:t})})})}),ez=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"],eB=l.forwardRef((e,t)=>{let{__scopeNavigationMenu:n,...r}=e,l=ec(n),a=ev("FocusGroupItem",n);return(0,d.jsx)(eu.ItemSlot,{scope:n,children:(0,d.jsx)(h.button,{...r,ref:t,onKeyDown:s(e.onKeyDown,e=>{if(["Home","End",...ez].includes(e.key)){let t=l().map(e=>e.ref.current);if(["rtl"===a.dir?"ArrowRight":"ArrowLeft","ArrowUp","End"].includes(e.key)&&t.reverse(),ez.includes(e.key)){let n=t.indexOf(e.currentTarget);t=t.slice(n+1)}setTimeout(()=>eY(t)),e.preventDefault()}})})})});function eK(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function eY(e){let t=document.activeElement;return e.some(e=>e===t||(e.focus(),document.activeElement!==t))}function e$(e,t){let n=(0,B.c)(t);(0,_.N)(()=>{let t=0;if(e){let r=new ResizeObserver(()=>{cancelAnimationFrame(t),t=window.requestAnimationFrame(n)});return r.observe(e),()=>{window.cancelAnimationFrame(t),r.unobserve(e)}}},[e,n])}function eH(e){return e?"open":"closed"}function eZ(e,t){return"".concat(e,"-trigger-").concat(t)}function eG(e,t){return"".concat(e,"-content-").concat(t)}function eJ(e){return t=>"mouse"===t.pointerType?e(t):void 0}var eQ=eb,eX=eN,e0=eR,e1=eO,e2=eM,e3=eP,e5=eI,e4=eq},65938:(e,t,n)=>{"use strict";n.d(t,{S7:()=>o});var r=n(7620);n(54568);var l=Symbol.for("ui.streamable.value");function a(e){return null!=e&&"object"==typeof e&&"type"in e&&e.type===l}function o(e){if(!a(e))throw Error("Invalid value: this hook only accepts values created via `createStreamableValue`.");return{[Symbol.asyncIterator](){let t=e,n=t.curr,r=!1,l=!0;return{async next(){if(r)return{value:n,done:!0};if(void 0!==(t=await t).error)throw t.error;if("curr"in t||t.diff){if(t.diff){if(0===t.diff[0]){if("string"!=typeof n)throw Error("Invalid patch: can only append to string types. This is a bug in the AI SDK.");n+=t.diff[1]}}else n=t.curr;if(!t.next)return r=!0,{value:n,done:!1}}return void 0===t.next?{value:n,done:!0}:(t=t.next,l&&(l=!1,void 0===n))?this.next():{value:n,done:!1}}}}}}},76059:e=>{e.exports={style:{fontFamily:"'IBM Plex Mono', monospace",fontStyle:"normal"},className:"__className_77429c",variable:"__variable_77429c"}},76954:e=>{e.exports={style:{fontFamily:"'IBM Plex Serif', 'IBM Plex Serif Fallback', serif",fontStyle:"normal"},className:"__className_15084a",variable:"__variable_15084a"}},77117:e=>{e.exports={style:{fontFamily:"'Source Code Pro', monospace",fontStyle:"normal"},className:"__className_80a83f",variable:"__variable_80a83f"}},81582:e=>{e.exports={style:{fontFamily:"'Merriweather', 'Merriweather Fallback', serif",fontStyle:"normal"},className:"__className_c33558",variable:"__variable_c33558"}},82536:e=>{e.exports={style:{fontFamily:"'JetBrains Mono', monospace",fontStyle:"normal"},className:"__className_219587",variable:"__variable_219587"}},83196:e=>{e.exports={style:{fontFamily:"'Source Sans 3', 'Source Sans 3 Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_8ef3f4",variable:"__variable_8ef3f4"}},87298:e=>{e.exports={style:{fontFamily:"'abcFavorit', 'abcFavorit Fallback', system-ui, arial"},className:"__className_115593",variable:"__variable_115593"}},89090:e=>{e.exports={style:{fontFamily:"'Noto Color Emoji', 'Noto Color Emoji Fallback'",fontWeight:400,fontStyle:"normal"},className:"__className_e0c565",variable:"__variable_e0c565"}},91942:e=>{e.exports={style:{fontFamily:"'Inter', 'Inter Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_1365a1",variable:"__variable_1365a1"}},93522:e=>{e.exports={style:{fontFamily:"'Poppins', 'Poppins Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_796067",variable:"__variable_796067"}},94497:e=>{e.exports={style:{fontFamily:"'Open Sans', 'Open Sans Fallback', system-ui, arial",fontStyle:"normal"},className:"__className_7f969e",variable:"__variable_7f969e"}}}]);