claude-alfred 0.3.21 → 0.3.22

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.
Files changed (58) hide show
  1. package/README.ja.md +5 -6
  2. package/README.md +5 -6
  3. package/dist/{audit-e13xK9Fr.mjs → audit-DmNpxVt4.mjs} +1 -1
  4. package/dist/cli.mjs +3 -3
  5. package/dist/{directives-DfzKzUAL.mjs → directives-Drv78LF2.mjs} +1 -1
  6. package/dist/{dispatcher-BDl_Flyx.mjs → dispatcher-Bm43S1GQ.mjs} +6 -6
  7. package/dist/{drift-CKOseTmh.mjs → drift-PySAVqkr.mjs} +3 -3
  8. package/dist/{epic-CfxJ13zy.mjs → epic-DJZgRHFr.mjs} +1 -1
  9. package/dist/{living-spec-BfQnawom.mjs → living-spec-C5kafrYy.mjs} +2 -2
  10. package/dist/{post-tool-DpBkq5ik.mjs → post-tool-CXbKGLOa.mjs} +7 -7
  11. package/dist/post-tool-CiV4IiYH.mjs +11 -0
  12. package/dist/{pre-compact-Cncx9q7L.mjs → pre-compact-p_eqH4vL.mjs} +5 -9
  13. package/dist/{pre-tool-Dyp4S8cV.mjs → pre-tool-CnoF_sta.mjs} +8 -8
  14. package/dist/{review-gate-7Pfe_A-8.mjs → review-gate-P_eycqEX.mjs} +1 -3
  15. package/dist/{server-CYUJFZhW.mjs → server-AL3qcEqy.mjs} +5 -10
  16. package/dist/{server-D3b54XYU.mjs → server-BJ1jUEm2.mjs} +18 -123
  17. package/dist/{session-start-CU4-KivX.mjs → session-start-CS4gyHMH.mjs} +8 -5
  18. package/dist/{stop-CGv96IQd.mjs → stop-DJgb2wrf.mjs} +2 -2
  19. package/dist/{types-K2jxpWyU.mjs → types-DyBixMZ0.mjs} +13 -17
  20. package/dist/{user-prompt-BPAOU8f-.mjs → user-prompt-vSVUeux8.mjs} +13 -15
  21. package/package.json +1 -1
  22. package/web/dist/assets/activity-CXCppRFo.js +1 -0
  23. package/web/dist/assets/alert-dialog-EwyZzvus.js +20 -0
  24. package/web/dist/assets/{badge-C_nJR3_P.js → badge-LeU66vxM.js} +1936 -1934
  25. package/web/dist/assets/butler-empty-DDWZ5SlJ.js +1 -0
  26. package/web/dist/assets/button-9A03BFB6.js +1 -0
  27. package/web/dist/assets/{card-D-KKTUrZ.js → card-C6aK9m3p.js} +1 -1
  28. package/web/dist/assets/{es2015-C0wv2Iox.js → es2015-DCAVxrl_.js} +1 -1
  29. package/web/dist/assets/index-BWInN_tm.css +1 -0
  30. package/web/dist/assets/index-uOCUo7Eo.js +10 -0
  31. package/web/dist/assets/{knowledge-Cf76s4T9.js → knowledge-CB_kjUsk.js} +15 -15
  32. package/web/dist/assets/{link-CfxeT0ji.js → link-DBmH_08w.js} +1 -1
  33. package/web/dist/assets/motion-BYjuf98F.js +1 -0
  34. package/web/dist/assets/preload-helper-BmUhu0Y-.js +1 -0
  35. package/web/dist/assets/progress-qFNeU9jW.js +6 -0
  36. package/web/dist/assets/routes-Dgq6wgCk.js +1 -0
  37. package/web/dist/assets/separator-mtcJeU26.js +5 -0
  38. package/web/dist/assets/{skeleton-ByYY54GV.js → skeleton-Cwiwlof_.js} +1 -1
  39. package/web/dist/assets/stagger-container-GyT5nb39.js +9 -0
  40. package/web/dist/assets/tasks-CVVDa650.js +1 -0
  41. package/web/dist/assets/tasks._slug-BccdO-CH.js +44 -0
  42. package/web/dist/assets/tooltip-CAuNczLe.js +1 -0
  43. package/web/dist/index.html +9 -7
  44. package/dist/post-tool-BawR4gHR.mjs +0 -11
  45. package/web/dist/assets/activity-BMH0Gseq.js +0 -3
  46. package/web/dist/assets/alert-dialog-Df-NKKik.js +0 -20
  47. package/web/dist/assets/button-BC81_2hy.js +0 -1
  48. package/web/dist/assets/dist-CCslGrjS.js +0 -1
  49. package/web/dist/assets/dist-CbLvV7YE.js +0 -1
  50. package/web/dist/assets/index-BedjjxO2.css +0 -1
  51. package/web/dist/assets/index-ClD5S_3_.js +0 -138
  52. package/web/dist/assets/progress-3fcfVnZl.js +0 -6
  53. package/web/dist/assets/routes-DZR7VbL6.js +0 -1
  54. package/web/dist/assets/stagger-container-ClpnejW9.js +0 -9
  55. package/web/dist/assets/tasks-Byg4aFbV.js +0 -1
  56. package/web/dist/assets/tasks._slug-jxqMGzVd.js +0 -44
  57. package/web/dist/assets/useParams-BHiGLTRd.js +0 -1
  58. /package/web/dist/assets/{types-CkMKNgId.js → types-Gr5neTyu.js} +0 -0
@@ -1 +1 @@
1
- import{$t as e,Bt as t,Cn as n,Tn as r,en as i}from"./badge-C_nJR3_P.js";var a=r(i(),1),o=a.use,s=typeof window<`u`?a.useLayoutEffect:a.useEffect;function c(e){let t=a.useRef({value:e,prev:null}),n=t.current.value;return e!==n&&(t.current={value:e,prev:n}),t.current.prev}function l(e,t,n={},r={}){a.useEffect(()=>{if(!e.current||r.disabled||typeof IntersectionObserver!=`function`)return;let i=new IntersectionObserver(([e])=>{t(e)},n);return i.observe(e.current),()=>{i.disconnect()}},[t,n,r.disabled,e])}function u(e){let t=a.useRef(null);return a.useImperativeHandle(e,()=>t.current,[]),t}function d(e){return e[e.length-1]}function f(e){return typeof e==`function`}function p(e,t){return f(e)?e(t):e}var m=Object.prototype.hasOwnProperty,h=Object.prototype.propertyIsEnumerable,g=()=>Object.create(null),_=(e,t)=>v(e,t,g);function v(e,t,n=()=>({}),r=0){if(e===t)return e;if(r>500)return t;let i=t,a=S(e)&&S(i);if(!a&&!(b(e)&&b(i)))return i;let o=a?e:y(e);if(!o)return i;let s=a?i:y(i);if(!s)return i;let c=o.length,l=s.length,u=a?Array(l):n(),d=0;for(let t=0;t<l;t++){let o=a?t:s[t],l=e[o],f=i[o];if(l===f){u[o]=l,(a?t<c:m.call(e,o))&&d++;continue}if(l===null||f===null||typeof l!=`object`||typeof f!=`object`){u[o]=f;continue}let p=v(l,f,n,r+1);u[o]=p,p===l&&d++}return c===l&&d===c?e:u}function y(e){let t=Object.getOwnPropertyNames(e);for(let n of t)if(!h.call(e,n))return!1;let n=Object.getOwnPropertySymbols(e);if(n.length===0)return t;let r=t;for(let t of n){if(!h.call(e,t))return!1;r.push(t)}return r}function b(e){if(!x(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!x(n)||!n.hasOwnProperty(`isPrototypeOf`))}function x(e){return Object.prototype.toString.call(e)===`[object Object]`}function S(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function C(e,t,n){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return!1;for(let r=0,i=e.length;r<i;r++)if(!C(e[r],t[r],n))return!1;return!0}if(b(e)&&b(t)){let r=n?.ignoreUndefined??!0;if(n?.partial){for(let i in t)if((!r||t[i]!==void 0)&&!C(e[i],t[i],n))return!1;return!0}let i=0;if(!r)i=Object.keys(e).length;else for(let t in e)e[t]!==void 0&&i++;let a=0;for(let o in t)if((!r||t[o]!==void 0)&&(a++,a>i||!C(e[o],t[o],n)))return!1;return i===a}return!1}function w(e){let t,n,r=new Promise((e,r)=>{t=e,n=r});return r.status=`pending`,r.resolve=n=>{r.status=`resolved`,r.value=n,t(n),e?.(n)},r.reject=e=>{r.status=`rejected`,n(e)},r}function T(e){return typeof e?.message==`string`?e.message.startsWith(`Failed to fetch dynamically imported module`)||e.message.startsWith(`error loading dynamically imported module`)||e.message.startsWith(`Importing a module script failed`):!1}function E(e){return!!(e&&typeof e==`object`&&typeof e.then==`function`)}function D(e){return e.replace(/[\x00-\x1f\x7f]/g,``)}function O(e){let t;try{t=decodeURI(e)}catch{t=e.replaceAll(/%[0-9A-F]{2}/gi,e=>{try{return decodeURI(e)}catch{return e}})}return D(t)}var k=[`http:`,`https:`,`mailto:`,`tel:`];function ee(e,t){if(!e)return!1;try{let n=new URL(e);return!t.has(n.protocol)}catch{return!1}}var A={"&":`\\u0026`,">":`\\u003e`,"<":`\\u003c`,"\u2028":`\\u2028`,"\u2029":`\\u2029`},te=/[&><\u2028\u2029]/g;function ne(e){return e.replace(te,e=>A[e])}function re(e){if(!e||!/[%\\\x00-\x1f\x7f]/.test(e)&&!e.startsWith(`//`))return{path:e,handledProtocolRelativeURL:!1};let t=/%25|%5C/gi,n=0,r=``,i;for(;(i=t.exec(e))!==null;)r+=O(e.slice(n,i.index))+i[0],n=t.lastIndex;r+=O(n?e.slice(n):e);let a=!1;return r.startsWith(`//`)&&(a=!0,r=`/`+r.replace(/^\/+/,``)),{path:r,handledProtocolRelativeURL:a}}function ie(e){return/\s|[^\u0000-\u007F]/.test(e)?e.replace(/\s|[^\u0000-\u007F]/gu,encodeURIComponent):e}function j(e){let t=new Map,n,r,i=e=>{e.next&&(e.prev?(e.prev.next=e.next,e.next.prev=e.prev,e.next=void 0,r&&(r.next=e,e.prev=r)):(e.next.prev=void 0,n=e.next,e.next=void 0,r&&(e.prev=r,r.next=e)),r=e)};return{get(e){let n=t.get(e);if(n)return i(n),n.value},set(a,o){if(t.size>=e&&n){let e=n;t.delete(e.key),e.next&&(n=e.next,e.next.prev=void 0),e===r&&(r=void 0)}let s=t.get(a);if(s)s.value=o,i(s);else{let e={key:a,value:o,prev:r};r&&(r.next=e),r=e,n||=e,t.set(a,e)}},clear(){t.clear(),n=void 0,r=void 0}}}var ae=!0,oe=`Invariant failed`;function se(e,t){if(!e){if(ae)throw Error(oe);var n=typeof t==`function`?t():t,r=n?`${oe}: ${n}`:oe;throw Error(r)}}var M=4,ce=5;function le(e){let t=e.indexOf(`{`);if(t===-1)return null;let n=e.indexOf(`}`,t);return n===-1||t+1>=e.length?null:[t,n]}function N(e,t,n=new Uint16Array(6)){let r=e.indexOf(`/`,t),i=r===-1?e.length:r,a=e.substring(t,i);if(!a||!a.includes(`$`))return n[0]=0,n[1]=t,n[2]=t,n[3]=i,n[4]=i,n[5]=i,n;if(a===`$`){let r=e.length;return n[0]=2,n[1]=t,n[2]=t,n[3]=r,n[4]=r,n[5]=r,n}if(a.charCodeAt(0)===36)return n[0]=1,n[1]=t,n[2]=t+1,n[3]=i,n[4]=i,n[5]=i,n;let o=le(a);if(o){let[r,s]=o,c=a.charCodeAt(r+1);if(c===45){if(r+2<a.length&&a.charCodeAt(r+2)===36){let e=r+3,a=s;if(e<a)return n[0]=3,n[1]=t+r,n[2]=t+e,n[3]=t+a,n[4]=t+s+1,n[5]=i,n}}else if(c===36){let a=r+1,o=r+2;return o===s?(n[0]=2,n[1]=t+r,n[2]=t+a,n[3]=t+o,n[4]=t+s+1,n[5]=e.length,n):(n[0]=1,n[1]=t+r,n[2]=t+o,n[3]=t+s,n[4]=t+s+1,n[5]=i,n)}}return n[0]=0,n[1]=t,n[2]=t,n[3]=i,n[4]=i,n[5]=i,n}function P(e,t,n,r,i,a,o){o?.(n);let s=r;{let r=n.fullPath??n.from,o=r.length,c=n.options?.caseSensitive??e,l=!!(n.options?.params?.parse&&n.options?.skipRouteOnParseError?.params);for(;s<o;){let e=N(r,s,t),o,u=s,d=e[5];switch(s=d+1,a++,e[0]){case 0:{let t=r.substring(e[2],e[3]);if(c){let e=i.static?.get(t);if(e)o=e;else{i.static??=new Map;let e=L(n.fullPath??n.from);e.parent=i,e.depth=a,o=e,i.static.set(t,e)}}else{let e=t.toLowerCase(),r=i.staticInsensitive?.get(e);if(r)o=r;else{i.staticInsensitive??=new Map;let t=L(n.fullPath??n.from);t.parent=i,t.depth=a,o=t,i.staticInsensitive.set(e,t)}}break}case 1:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),f=c&&!!(t||s),p=t?f?t:t.toLowerCase():void 0,m=s?f?s:s.toLowerCase():void 0,h=!l&&i.dynamic?.find(e=>!e.skipOnParamError&&e.caseSensitive===f&&e.prefix===p&&e.suffix===m);if(h)o=h;else{let e=R(1,n.fullPath??n.from,f,p,m);o=e,e.depth=a,e.parent=i,i.dynamic??=[],i.dynamic.push(e)}break}case 3:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),f=c&&!!(t||s),p=t?f?t:t.toLowerCase():void 0,m=s?f?s:s.toLowerCase():void 0,h=!l&&i.optional?.find(e=>!e.skipOnParamError&&e.caseSensitive===f&&e.prefix===p&&e.suffix===m);if(h)o=h;else{let e=R(3,n.fullPath??n.from,f,p,m);o=e,e.parent=i,e.depth=a,i.optional??=[],i.optional.push(e)}break}case 2:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),l=c&&!!(t||s),f=t?l?t:t.toLowerCase():void 0,p=s?l?s:s.toLowerCase():void 0,m=R(2,n.fullPath??n.from,l,f,p);o=m,m.parent=i,m.depth=a,i.wildcard??=[],i.wildcard.push(m)}}i=o}if(l&&n.children&&!n.isRoot&&n.id&&n.id.charCodeAt(n.id.lastIndexOf(`/`)+1)===95){let e=L(n.fullPath??n.from);e.kind=ce,e.parent=i,a++,e.depth=a,i.pathless??=[],i.pathless.push(e),i=e}let u=(n.path||!n.children)&&!n.isRoot;if(u&&r.endsWith(`/`)){let e=L(n.fullPath??n.from);e.kind=M,e.parent=i,a++,e.depth=a,i.index=e,i=e}i.parse=n.options?.params?.parse??null,i.skipOnParamError=l,i.parsingPriority=n.options?.skipRouteOnParseError?.priority??0,u&&!i.route&&(i.route=n,i.fullPath=n.fullPath??n.from)}if(n.children)for(let r of n.children)P(e,t,r,s,i,a,o)}function F(e,t){if(e.skipOnParamError&&!t.skipOnParamError)return-1;if(!e.skipOnParamError&&t.skipOnParamError)return 1;if(e.skipOnParamError&&t.skipOnParamError&&(e.parsingPriority||t.parsingPriority))return t.parsingPriority-e.parsingPriority;if(e.prefix&&t.prefix&&e.prefix!==t.prefix){if(e.prefix.startsWith(t.prefix))return-1;if(t.prefix.startsWith(e.prefix))return 1}if(e.suffix&&t.suffix&&e.suffix!==t.suffix){if(e.suffix.endsWith(t.suffix))return-1;if(t.suffix.endsWith(e.suffix))return 1}return e.prefix&&!t.prefix?-1:!e.prefix&&t.prefix?1:e.suffix&&!t.suffix?-1:!e.suffix&&t.suffix?1:e.caseSensitive&&!t.caseSensitive?-1:!e.caseSensitive&&t.caseSensitive?1:0}function I(e){if(e.pathless)for(let t of e.pathless)I(t);if(e.static)for(let t of e.static.values())I(t);if(e.staticInsensitive)for(let t of e.staticInsensitive.values())I(t);if(e.dynamic?.length){e.dynamic.sort(F);for(let t of e.dynamic)I(t)}if(e.optional?.length){e.optional.sort(F);for(let t of e.optional)I(t)}if(e.wildcard?.length){e.wildcard.sort(F);for(let t of e.wildcard)I(t)}}function L(e){return{kind:0,depth:0,pathless:null,index:null,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:e,parent:null,parse:null,skipOnParamError:!1,parsingPriority:0}}function R(e,t,n,r,i){return{kind:e,depth:0,pathless:null,index:null,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:t,parent:null,parse:null,skipOnParamError:!1,parsingPriority:0,caseSensitive:n,prefix:r,suffix:i}}function ue(e,t){let n=L(`/`),r=new Uint16Array(6);for(let t of e)P(!1,r,t,1,n,0);I(n),t.masksTree=n,t.flatCache=j(1e3)}function z(e,t){e||=`/`;let n=t.flatCache.get(e);if(n)return n;let r=W(e,t.masksTree);return t.flatCache.set(e,r),r}function B(e,t,n,r,i){e||=`/`,r||=`/`;let a=t?`case\0${e}`:e,o=i.singleCache.get(a);return o||(o=L(`/`),P(t,new Uint16Array(6),{from:e},1,o,0),i.singleCache.set(a,o)),W(r,o,n)}function V(e,t,n=!1){let r=n?e:`nofuzz\0${e}`,i=t.matchCache.get(r);if(i!==void 0)return i;e||=`/`;let a;try{a=W(e,t.segmentTree,n)}catch(e){if(e instanceof URIError)a=null;else throw e}return a&&(a.branch=de(a.route)),t.matchCache.set(r,a),a}function H(e){return e===`/`?e:e.replace(/\/{1,}$/,``)}function U(e,t=!1,n){let r=L(e.fullPath),i=new Uint16Array(6),a={},o={},s=0;return P(t,i,e,1,r,0,e=>{if(n?.(e,s),se(!(e.id in a),`Duplicate routes found with id: ${String(e.id)}`),a[e.id]=e,s!==0&&e.path){let t=H(e.fullPath);(!o[t]||e.fullPath.endsWith(`/`))&&(o[t]=e)}s++}),I(r),{processedTree:{segmentTree:r,singleCache:j(1e3),matchCache:j(1e3),flatCache:null,masksTree:null},routesById:a,routesByPath:o}}function W(e,t,n=!1){let r=e.split(`/`),i=pe(e,r,t,n);if(!i)return null;let[a]=G(e,r,i);return{route:i.node.route,rawParams:a,parsedParams:i.parsedParams}}function G(e,t,n){let r=fe(n.node),i=null,a=Object.create(null),o=n.extract?.part??0,s=n.extract?.node??0,c=n.extract?.path??0,l=n.extract?.segment??0;for(;s<r.length;o++,s++,c++,l++){let u=r[s];if(u.kind===M)break;if(u.kind===ce){l--,o--,c--;continue}let d=t[o],f=c;if(d&&(c+=d.length),u.kind===1){i??=n.node.fullPath.split(`/`);let e=i[l],t=u.prefix?.length??0;if(e.charCodeAt(t)===123){let n=u.suffix?.length??0,r=e.substring(t+2,e.length-n-1),i=d.substring(t,d.length-n);a[r]=decodeURIComponent(i)}else{let t=e.substring(1);a[t]=decodeURIComponent(d)}}else if(u.kind===3){if(n.skipped&1<<s){o--,c=f-1;continue}i??=n.node.fullPath.split(`/`);let e=i[l],t=u.prefix?.length??0,r=u.suffix?.length??0,p=e.substring(t+3,e.length-r-1),m=u.suffix||u.prefix?d.substring(t,d.length-r):d;m&&(a[p]=decodeURIComponent(m))}else if(u.kind===2){let t=u,n=e.substring(f+(t.prefix?.length??0),e.length-(t.suffix?.length??0)),r=decodeURIComponent(n);a[`*`]=r,a._splat=r;break}}return n.rawParams&&Object.assign(a,n.rawParams),[a,{part:o,node:s,path:c,segment:l}]}function de(e){let t=[e];for(;e.parentRoute;)e=e.parentRoute,t.push(e);return t.reverse(),t}function fe(e){let t=Array(e.depth+1);do t[e.depth]=e,e=e.parent;while(e);return t}function pe(e,t,n,r){if(e===`/`&&n.index)return{node:n.index,skipped:0};let i=!d(t),a=i&&e!==`/`,o=t.length-(i?1:0),s=[{node:n,index:1,skipped:0,depth:1,statics:1,dynamics:0,optionals:0}],c=null,l=null,u=null;for(;s.length;){let n=s.pop(),{node:i,index:d,skipped:f,depth:p,statics:m,dynamics:h,optionals:g}=n,{extract:_,rawParams:v,parsedParams:y}=n;if(i.skipOnParamError){if(!K(e,t,n))continue;v=n.rawParams,_=n.extract,y=n.parsedParams}r&&i.route&&i.kind!==M&&q(l,n)&&(l=n);let b=d===o;if(b&&(i.route&&!a&&q(u,n)&&(u=n),!i.optional&&!i.wildcard&&!i.index&&!i.pathless))continue;let x=b?void 0:t[d],S;if(b&&i.index){let n={node:i.index,index:d,skipped:f,depth:p+1,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y},r=!0;if(i.index.skipOnParamError&&(K(e,t,n)||(r=!1)),r){if(m===o&&!h&&!g&&!f)return n;q(u,n)&&(u=n)}}if(i.wildcard&&q(c,n))for(let n of i.wildcard){let{prefix:r,suffix:i}=n;if(r&&(b||!(n.caseSensitive?x:S??=x.toLowerCase()).startsWith(r)))continue;if(i){if(b)continue;let e=t.slice(d).join(`/`).slice(-i.length);if((n.caseSensitive?e:e.toLowerCase())!==i)continue}let a={node:n,index:o,skipped:f,depth:p,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y};if(!(n.skipOnParamError&&!K(e,t,a))){c=a;break}}if(i.optional){let e=f|1<<p,t=p+1;for(let n=i.optional.length-1;n>=0;n--){let r=i.optional[n];s.push({node:r,index:d,skipped:e,depth:t,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b)for(let e=i.optional.length-1;e>=0;e--){let n=i.optional[e],{prefix:r,suffix:a}=n;if(r||a){let e=n.caseSensitive?x:S??=x.toLowerCase();if(r&&!e.startsWith(r)||a&&!e.endsWith(a))continue}s.push({node:n,index:d+1,skipped:f,depth:t,statics:m,dynamics:h,optionals:g+1,extract:_,rawParams:v,parsedParams:y})}}if(!b&&i.dynamic&&x)for(let e=i.dynamic.length-1;e>=0;e--){let t=i.dynamic[e],{prefix:n,suffix:r}=t;if(n||r){let e=t.caseSensitive?x:S??=x.toLowerCase();if(n&&!e.startsWith(n)||r&&!e.endsWith(r))continue}s.push({node:t,index:d+1,skipped:f,depth:p+1,statics:m,dynamics:h+1,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b&&i.staticInsensitive){let e=i.staticInsensitive.get(S??=x.toLowerCase());e&&s.push({node:e,index:d+1,skipped:f,depth:p+1,statics:m+1,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b&&i.static){let e=i.static.get(x);e&&s.push({node:e,index:d+1,skipped:f,depth:p+1,statics:m+1,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(i.pathless){let e=p+1;for(let t=i.pathless.length-1;t>=0;t--){let n=i.pathless[t];s.push({node:n,index:d,skipped:f,depth:e,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}}}if(u&&c)return q(c,u)?u:c;if(u)return u;if(c)return c;if(r&&l){let n=l.index;for(let e=0;e<l.index;e++)n+=t[e].length;let r=n===e.length?`/`:e.slice(n);return l.rawParams??=Object.create(null),l.rawParams[`**`]=decodeURIComponent(r),l}return null}function K(e,t,n){try{let[r,i]=G(e,t,n);n.rawParams=r,n.extract=i;let a=n.node.parse(r);return n.parsedParams=Object.assign(Object.create(null),n.parsedParams,a),!0}catch{return null}}function q(e,t){return e?t.statics>e.statics||t.statics===e.statics&&(t.dynamics>e.dynamics||t.dynamics===e.dynamics&&(t.optionals>e.optionals||t.optionals===e.optionals&&((t.node.kind===M)>(e.node.kind===M)||t.node.kind===M==(e.node.kind===M)&&t.depth>e.depth))):!0}function J(e){return Y(e.filter(e=>e!==void 0).join(`/`))}function Y(e){return e.replace(/\/{2,}/g,`/`)}function X(e){return e===`/`?e:e.replace(/^\/{1,}/,``)}function me(e){let t=e.length;return t>1&&e[t-1]===`/`?e.replace(/\/{1,}$/,``):e}function he(e){return me(X(e))}function Z(e,t){return e?.endsWith(`/`)&&e!==`/`&&e!==`${t}/`?e.slice(0,-1):e}function ge(e,t,n){return Z(e,n)===Z(t,n)}function _e({base:e,to:t,trailingSlash:n=`never`,cache:r}){let i=t.startsWith(`/`),a=!i&&t===`.`,o;if(r){o=i?t:a?e:e+`\0`+t;let n=r.get(o);if(n)return n}let s;if(a)s=e.split(`/`);else if(i)s=t.split(`/`);else{for(s=e.split(`/`);s.length>1&&d(s)===``;)s.pop();let n=t.split(`/`);for(let e=0,t=n.length;e<t;e++){let r=n[e];r===``?e?e===t-1&&s.push(r):s=[r]:r===`..`?s.pop():r===`.`||s.push(r)}}s.length>1&&(d(s)===``?n===`never`&&s.pop():n===`always`&&s.push(``));let c,l=``;for(let e=0;e<s.length;e++){e>0&&(l+=`/`);let t=s[e];if(!t)continue;c=N(t,0,c);let n=c[0];if(n===0){l+=t;continue}let r=c[5],i=t.substring(0,c[1]),a=t.substring(c[4],r),o=t.substring(c[2],c[3]);n===1?l+=i||a?`${i}{$${o}}${a}`:`$${o}`:n===2?l+=i||a?`${i}{$}${a}`:`$`:l+=`${i}{-$${o}}${a}`}l=Y(l);let u=l||`/`;return o&&r&&r.set(o,u),u}function ve(e){let t=new Map(e.map(e=>[encodeURIComponent(e),e])),n=Array.from(t.keys()).map(e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)).join(`|`),r=new RegExp(n,`g`);return e=>e.replace(r,e=>t.get(e)??e)}function ye(e,t,n){let r=t[e];return typeof r==`string`?e===`_splat`?/^[a-zA-Z0-9\-._~!/]*$/.test(r)?r:r.split(`/`).map(e=>xe(e,n)).join(`/`):xe(r,n):r}function be({path:e,params:t,decoder:n,...r}){let i=!1,a=Object.create(null);if(!e||e===`/`)return{interpolatedPath:`/`,usedParams:a,isMissingParams:i};if(!e.includes(`$`))return{interpolatedPath:e,usedParams:a,isMissingParams:i};let o=e.length,s=0,c,l=``;for(;s<o;){let r=s;c=N(e,r,c);let o=c[5];if(s=o+1,r===o)continue;let u=c[0];if(u===0){l+=`/`+e.substring(r,o);continue}if(u===2){let s=t._splat;a._splat=s,a[`*`]=s;let u=e.substring(r,c[1]),d=e.substring(c[4],o);if(!s){i=!0,(u||d)&&(l+=`/`+u+d);continue}let f=ye(`_splat`,t,n);l+=`/`+u+f+d;continue}if(u===1){let s=e.substring(c[2],c[3]);!i&&!(s in t)&&(i=!0),a[s]=t[s];let u=e.substring(r,c[1]),d=e.substring(c[4],o),f=ye(s,t,n)??`undefined`;l+=`/`+u+f+d;continue}if(u===3){let i=e.substring(c[2],c[3]),s=t[i];if(s==null)continue;a[i]=s;let u=e.substring(r,c[1]),d=e.substring(c[4],o),f=ye(i,t,n)??``;l+=`/`+u+f+d;continue}}return e.endsWith(`/`)&&(l+=`/`),{usedParams:a,interpolatedPath:l||`/`,isMissingParams:i}}function xe(e,t){let n=encodeURIComponent(e);return t?.(n)??n}var Se=`Error preloading route! ☝️`,Ce=e();function we({children:e,fallback:t=null}){return Te()?(0,Ce.jsx)(a.Fragment,{children:e}):(0,Ce.jsx)(a.Fragment,{children:t})}function Te(){return a.useSyncExternalStore(Ee,()=>!0,()=>!1)}function Ee(){return()=>{}}var De=a.createContext(null),Oe=!0;function ke(e,t){if(!Oe){if(e)return;var n=`Warning: `+t;typeof console<`u`&&console.warn(n);try{throw Error(n)}catch{}}}function Ae(e){let t=a.useContext(De);return ke(!((e?.warn??!0)&&!t),`useRouter must be used inside a <RouterProvider> component!`),t}var je=n((e=>{var t=i();function n(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var r=typeof Object.is==`function`?Object.is:n,a=t.useState,o=t.useEffect,s=t.useLayoutEffect,c=t.useDebugValue;function l(e,t){var n=t(),r=a({inst:{value:n,getSnapshot:t}}),i=r[0].inst,l=r[1];return s(function(){i.value=n,i.getSnapshot=t,u(i)&&l({inst:i})},[e,n,t]),o(function(){return u(i)&&l({inst:i}),e(function(){u(i)&&l({inst:i})})},[e]),c(n),n}function u(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!r(e,n)}catch{return!0}}function d(e,t){return t()}var f=typeof window>`u`||window.document===void 0||window.document.createElement===void 0?d:l;e.useSyncExternalStore=t.useSyncExternalStore===void 0?f:t.useSyncExternalStore})),Me=n(((e,t)=>{t.exports=je()})),Ne=n((e=>{var t=i(),n=Me();function r(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var a=typeof Object.is==`function`?Object.is:r,o=n.useSyncExternalStore,s=t.useRef,c=t.useEffect,l=t.useMemo,u=t.useDebugValue;e.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var d=s(null);if(d.current===null){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=l(function(){function e(e){if(!o){if(o=!0,s=e,e=r(e),i!==void 0&&f.hasValue){var t=f.value;if(i(t,e))return c=t}return c=e}if(t=c,a(s,e))return t;var n=r(e);return i!==void 0&&i(t,n)?(s=e,t):(s=e,c=n)}var o=!1,s,c,l=n===void 0?null:n;return[function(){return e(t())},l===null?void 0:function(){return e(l())}]},[t,n,r,i]);var p=o(e,d[0],d[1]);return c(function(){f.hasValue=!0,f.value=p},[p]),u(p),p}})),Pe=n(((e,t)=>{t.exports=Ne()}))();function Fe(e,t){return e===t}function Ie(e,t,n=Fe){let r=(0,a.useCallback)(t=>{if(!e)return()=>{};let{unsubscribe:n}=e.subscribe(t);return n},[e]),i=(0,a.useCallback)(()=>e?.get(),[e]);return(0,Pe.useSyncExternalStoreWithSelector)(r,i,i,t,n)}function Le(e){let t=Ae({warn:e?.router===void 0}),n=e?.router||t,r=(0,a.useRef)(void 0);return Ie(n.__store,t=>{if(e?.select){if(e.structuralSharing??n.options.defaultStructuralSharing){let n=v(r.current,e.select(t));return r.current=n,n}return e.select(t)}return t})}var Re=r(t(),1);function ze(e,t){let n=Ae(),r=u(t),{activeProps:i,inactiveProps:o,activeOptions:s,to:c,preload:d,preloadDelay:f,hashScrollIntoView:m,replace:h,startTransition:g,resetScroll:_,viewTransition:v,children:y,target:b,disabled:x,style:S,className:w,onClick:T,onBlur:E,onFocus:D,onMouseEnter:O,onMouseLeave:k,onTouchStart:A,ignoreBlocker:te,params:ne,search:re,hash:ie,state:j,mask:ae,reloadDocument:oe,unsafeRelative:se,from:M,_fromLocation:ce,...le}=e,N=Te(),P=Le({select:e=>{let t=e.matches[e.matches.length-1];return{search:t?.search,hash:e.location.hash,path:t?.pathname}},structuralSharing:!0}),F=e.from,I=a.useMemo(()=>({...e,from:F}),[n,P,F,e._fromLocation,e.hash,e.to,e.search,e.params,e.state,e.mask,e.unsafeRelative]),L=a.useMemo(()=>n.buildLocation({...I}),[n,I]),R=L.maskedLocation?L.maskedLocation.publicHref:L.publicHref,ue=L.maskedLocation?L.maskedLocation.external:L.external,z=a.useMemo(()=>Ke(R,ue,n.history,x),[x,ue,R,n.history]),B=a.useMemo(()=>{if(z?.external)return ee(z.href,n.protocolAllowlist)?void 0:z.href;if(!qe(c)&&!(typeof c!=`string`||c.indexOf(`:`)===-1))try{return new URL(c),ee(c,n.protocolAllowlist)?void 0:c}catch{}},[c,z,n.protocolAllowlist]),V=Le({select:e=>{if(B)return!1;if(s?.exact){if(!ge(e.location.pathname,L.pathname,n.basepath))return!1}else{let t=Z(e.location.pathname,n.basepath),r=Z(L.pathname,n.basepath);if(!(t.startsWith(r)&&(t.length===r.length||t[r.length]===`/`)))return!1}return(s?.includeSearch??!0)&&!C(e.location.search,L.search,{partial:!s?.exact,ignoreUndefined:!s?.explicitUndefined})?!1:s?.includeHash?N&&e.location.hash===L.hash:!0}}),H=V?p(i,{})??Ve:Be,U=V?Be:p(o,{})??Be,W=[w,H.className,U.className].filter(Boolean).join(` `),G=(S||H.style||U.style)&&{...S,...H.style,...U.style},[de,fe]=a.useState(!1),pe=a.useRef(!1),K=e.reloadDocument||B?!1:d??n.options.defaultPreload,q=f??n.options.defaultPreloadDelay??0,J=a.useCallback(()=>{n.preloadRoute({...I,_builtLocation:L}).catch(e=>{console.warn(e),console.warn(Se)})},[n,I,L]);l(r,a.useCallback(e=>{e?.isIntersecting&&J()},[J]),Ge,{disabled:!!x||K!==`viewport`}),a.useEffect(()=>{pe.current||!x&&K===`render`&&(J(),pe.current=!0)},[x,J,K]);let Y=e=>{let t=e.currentTarget.getAttribute(`target`),r=b===void 0?t:b;if(!x&&!Ye(e)&&!e.defaultPrevented&&(!r||r===`_self`)&&e.button===0){e.preventDefault(),(0,Re.flushSync)(()=>{fe(!0)});let t=n.subscribe(`onResolved`,()=>{t(),fe(!1)});n.navigate({...I,replace:h,resetScroll:_,hashScrollIntoView:m,startTransition:g,viewTransition:v,ignoreBlocker:te})}};if(B)return{...le,ref:r,href:B,...y&&{children:y},...b&&{target:b},...x&&{disabled:x},...S&&{style:S},...w&&{className:w},...T&&{onClick:T},...E&&{onBlur:E},...D&&{onFocus:D},...O&&{onMouseEnter:O},...k&&{onMouseLeave:k},...A&&{onTouchStart:A}};let X=e=>{if(x||K!==`intent`)return;if(!q){J();return}let t=e.currentTarget;if(Q.has(t))return;let n=setTimeout(()=>{Q.delete(t),J()},q);Q.set(t,n)},me=e=>{x||K!==`intent`||J()},he=e=>{if(x||!K||!q)return;let t=e.currentTarget,n=Q.get(t);n&&(clearTimeout(n),Q.delete(t))};return{...le,...H,...U,href:z?.href,ref:r,onClick:$([T,Y]),onBlur:$([E,he]),onFocus:$([D,X]),onMouseEnter:$([O,X]),onMouseLeave:$([k,he]),onTouchStart:$([A,me]),disabled:!!x,target:b,...G&&{style:G},...W&&{className:W},...x&&He,...V&&Ue,...N&&de&&We}}var Be={},Ve={className:`active`},He={role:`link`,"aria-disabled":!0},Ue={"data-status":`active`,"aria-current":`page`},We={"data-transitioning":`transitioning`},Q=new WeakMap,Ge={rootMargin:`100px`},$=e=>t=>{for(let n of e)if(n){if(t.defaultPrevented)return;n(t)}};function Ke(e,t,n,r){if(!r)return t?{href:e,external:!0}:{href:n.createHref(e)||`/`,external:!1}}function qe(e){if(typeof e!=`string`)return!1;let t=e.charCodeAt(0);return t===47?e.charCodeAt(1)!==47:t===46}var Je=a.forwardRef((e,t)=>{let{_asChild:n,...r}=e,{type:i,...o}=ze(r,t),s=typeof r.children==`function`?r.children({isActive:o[`data-status`]===`active`}):r.children;if(!n){let{disabled:e,...t}=o;return a.createElement(`a`,t,s)}return a.createElement(n,o,s)});function Ye(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}export{T as A,w as C,ne as D,ie as E,o as F,s as I,c as L,d as M,_ as N,p as O,v as P,k as S,C as T,B as _,De as a,se as b,ve as c,_e as d,he as f,V as g,z as h,ke as i,E as j,ee as k,be as l,me as m,Le as n,we as o,X as p,Ae as r,Y as s,Je as t,J as u,ue as v,re as w,j as x,U as y};
1
+ import{Ct as e,It as t,Lt as n,on as r,un as i}from"./badge-LeU66vxM.js";var a=i(n(),1),o=a.use,s=typeof window<`u`?a.useLayoutEffect:a.useEffect;function c(e){let t=a.useRef({value:e,prev:null}),n=t.current.value;return e!==n&&(t.current={value:e,prev:n}),t.current.prev}function l(e,t,n={},r={}){a.useEffect(()=>{if(!e.current||r.disabled||typeof IntersectionObserver!=`function`)return;let i=new IntersectionObserver(([e])=>{t(e)},n);return i.observe(e.current),()=>{i.disconnect()}},[t,n,r.disabled,e])}function u(e){let t=a.useRef(null);return a.useImperativeHandle(e,()=>t.current,[]),t}function d(e){return e[e.length-1]}function f(e){return typeof e==`function`}function p(e,t){return f(e)?e(t):e}var m=Object.prototype.hasOwnProperty,h=Object.prototype.propertyIsEnumerable,g=()=>Object.create(null),_=(e,t)=>v(e,t,g);function v(e,t,n=()=>({}),r=0){if(e===t)return e;if(r>500)return t;let i=t,a=S(e)&&S(i);if(!a&&!(b(e)&&b(i)))return i;let o=a?e:y(e);if(!o)return i;let s=a?i:y(i);if(!s)return i;let c=o.length,l=s.length,u=a?Array(l):n(),d=0;for(let t=0;t<l;t++){let o=a?t:s[t],l=e[o],f=i[o];if(l===f){u[o]=l,(a?t<c:m.call(e,o))&&d++;continue}if(l===null||f===null||typeof l!=`object`||typeof f!=`object`){u[o]=f;continue}let p=v(l,f,n,r+1);u[o]=p,p===l&&d++}return c===l&&d===c?e:u}function y(e){let t=Object.getOwnPropertyNames(e);for(let n of t)if(!h.call(e,n))return!1;let n=Object.getOwnPropertySymbols(e);if(n.length===0)return t;let r=t;for(let t of n){if(!h.call(e,t))return!1;r.push(t)}return r}function b(e){if(!x(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!x(n)||!n.hasOwnProperty(`isPrototypeOf`))}function x(e){return Object.prototype.toString.call(e)===`[object Object]`}function S(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function C(e,t,n){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return!1;for(let r=0,i=e.length;r<i;r++)if(!C(e[r],t[r],n))return!1;return!0}if(b(e)&&b(t)){let r=n?.ignoreUndefined??!0;if(n?.partial){for(let i in t)if((!r||t[i]!==void 0)&&!C(e[i],t[i],n))return!1;return!0}let i=0;if(!r)i=Object.keys(e).length;else for(let t in e)e[t]!==void 0&&i++;let a=0;for(let o in t)if((!r||t[o]!==void 0)&&(a++,a>i||!C(e[o],t[o],n)))return!1;return i===a}return!1}function w(e){let t,n,r=new Promise((e,r)=>{t=e,n=r});return r.status=`pending`,r.resolve=n=>{r.status=`resolved`,r.value=n,t(n),e?.(n)},r.reject=e=>{r.status=`rejected`,n(e)},r}function T(e){return typeof e?.message==`string`?e.message.startsWith(`Failed to fetch dynamically imported module`)||e.message.startsWith(`error loading dynamically imported module`)||e.message.startsWith(`Importing a module script failed`):!1}function E(e){return!!(e&&typeof e==`object`&&typeof e.then==`function`)}function D(e){return e.replace(/[\x00-\x1f\x7f]/g,``)}function O(e){let t;try{t=decodeURI(e)}catch{t=e.replaceAll(/%[0-9A-F]{2}/gi,e=>{try{return decodeURI(e)}catch{return e}})}return D(t)}var k=[`http:`,`https:`,`mailto:`,`tel:`];function ee(e,t){if(!e)return!1;try{let n=new URL(e);return!t.has(n.protocol)}catch{return!1}}var A={"&":`\\u0026`,">":`\\u003e`,"<":`\\u003c`,"\u2028":`\\u2028`,"\u2029":`\\u2029`},te=/[&><\u2028\u2029]/g;function ne(e){return e.replace(te,e=>A[e])}function re(e){if(!e||!/[%\\\x00-\x1f\x7f]/.test(e)&&!e.startsWith(`//`))return{path:e,handledProtocolRelativeURL:!1};let t=/%25|%5C/gi,n=0,r=``,i;for(;(i=t.exec(e))!==null;)r+=O(e.slice(n,i.index))+i[0],n=t.lastIndex;r+=O(n?e.slice(n):e);let a=!1;return r.startsWith(`//`)&&(a=!0,r=`/`+r.replace(/^\/+/,``)),{path:r,handledProtocolRelativeURL:a}}function ie(e){return/\s|[^\u0000-\u007F]/.test(e)?e.replace(/\s|[^\u0000-\u007F]/gu,encodeURIComponent):e}function j(e){let t=new Map,n,r,i=e=>{e.next&&(e.prev?(e.prev.next=e.next,e.next.prev=e.prev,e.next=void 0,r&&(r.next=e,e.prev=r)):(e.next.prev=void 0,n=e.next,e.next=void 0,r&&(e.prev=r,r.next=e)),r=e)};return{get(e){let n=t.get(e);if(n)return i(n),n.value},set(a,o){if(t.size>=e&&n){let e=n;t.delete(e.key),e.next&&(n=e.next,e.next.prev=void 0),e===r&&(r=void 0)}let s=t.get(a);if(s)s.value=o,i(s);else{let e={key:a,value:o,prev:r};r&&(r.next=e),r=e,n||=e,t.set(a,e)}},clear(){t.clear(),n=void 0,r=void 0}}}var ae=!0,oe=`Invariant failed`;function se(e,t){if(!e){if(ae)throw Error(oe);var n=typeof t==`function`?t():t,r=n?`${oe}: ${n}`:oe;throw Error(r)}}var M=4,ce=5;function le(e){let t=e.indexOf(`{`);if(t===-1)return null;let n=e.indexOf(`}`,t);return n===-1||t+1>=e.length?null:[t,n]}function N(e,t,n=new Uint16Array(6)){let r=e.indexOf(`/`,t),i=r===-1?e.length:r,a=e.substring(t,i);if(!a||!a.includes(`$`))return n[0]=0,n[1]=t,n[2]=t,n[3]=i,n[4]=i,n[5]=i,n;if(a===`$`){let r=e.length;return n[0]=2,n[1]=t,n[2]=t,n[3]=r,n[4]=r,n[5]=r,n}if(a.charCodeAt(0)===36)return n[0]=1,n[1]=t,n[2]=t+1,n[3]=i,n[4]=i,n[5]=i,n;let o=le(a);if(o){let[r,s]=o,c=a.charCodeAt(r+1);if(c===45){if(r+2<a.length&&a.charCodeAt(r+2)===36){let e=r+3,a=s;if(e<a)return n[0]=3,n[1]=t+r,n[2]=t+e,n[3]=t+a,n[4]=t+s+1,n[5]=i,n}}else if(c===36){let a=r+1,o=r+2;return o===s?(n[0]=2,n[1]=t+r,n[2]=t+a,n[3]=t+o,n[4]=t+s+1,n[5]=e.length,n):(n[0]=1,n[1]=t+r,n[2]=t+o,n[3]=t+s,n[4]=t+s+1,n[5]=i,n)}}return n[0]=0,n[1]=t,n[2]=t,n[3]=i,n[4]=i,n[5]=i,n}function P(e,t,n,r,i,a,o){o?.(n);let s=r;{let r=n.fullPath??n.from,o=r.length,c=n.options?.caseSensitive??e,l=!!(n.options?.params?.parse&&n.options?.skipRouteOnParseError?.params);for(;s<o;){let e=N(r,s,t),o,u=s,d=e[5];switch(s=d+1,a++,e[0]){case 0:{let t=r.substring(e[2],e[3]);if(c){let e=i.static?.get(t);if(e)o=e;else{i.static??=new Map;let e=L(n.fullPath??n.from);e.parent=i,e.depth=a,o=e,i.static.set(t,e)}}else{let e=t.toLowerCase(),r=i.staticInsensitive?.get(e);if(r)o=r;else{i.staticInsensitive??=new Map;let t=L(n.fullPath??n.from);t.parent=i,t.depth=a,o=t,i.staticInsensitive.set(e,t)}}break}case 1:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),f=c&&!!(t||s),p=t?f?t:t.toLowerCase():void 0,m=s?f?s:s.toLowerCase():void 0,h=!l&&i.dynamic?.find(e=>!e.skipOnParamError&&e.caseSensitive===f&&e.prefix===p&&e.suffix===m);if(h)o=h;else{let e=R(1,n.fullPath??n.from,f,p,m);o=e,e.depth=a,e.parent=i,i.dynamic??=[],i.dynamic.push(e)}break}case 3:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),f=c&&!!(t||s),p=t?f?t:t.toLowerCase():void 0,m=s?f?s:s.toLowerCase():void 0,h=!l&&i.optional?.find(e=>!e.skipOnParamError&&e.caseSensitive===f&&e.prefix===p&&e.suffix===m);if(h)o=h;else{let e=R(3,n.fullPath??n.from,f,p,m);o=e,e.parent=i,e.depth=a,i.optional??=[],i.optional.push(e)}break}case 2:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),l=c&&!!(t||s),f=t?l?t:t.toLowerCase():void 0,p=s?l?s:s.toLowerCase():void 0,m=R(2,n.fullPath??n.from,l,f,p);o=m,m.parent=i,m.depth=a,i.wildcard??=[],i.wildcard.push(m)}}i=o}if(l&&n.children&&!n.isRoot&&n.id&&n.id.charCodeAt(n.id.lastIndexOf(`/`)+1)===95){let e=L(n.fullPath??n.from);e.kind=ce,e.parent=i,a++,e.depth=a,i.pathless??=[],i.pathless.push(e),i=e}let u=(n.path||!n.children)&&!n.isRoot;if(u&&r.endsWith(`/`)){let e=L(n.fullPath??n.from);e.kind=M,e.parent=i,a++,e.depth=a,i.index=e,i=e}i.parse=n.options?.params?.parse??null,i.skipOnParamError=l,i.parsingPriority=n.options?.skipRouteOnParseError?.priority??0,u&&!i.route&&(i.route=n,i.fullPath=n.fullPath??n.from)}if(n.children)for(let r of n.children)P(e,t,r,s,i,a,o)}function F(e,t){if(e.skipOnParamError&&!t.skipOnParamError)return-1;if(!e.skipOnParamError&&t.skipOnParamError)return 1;if(e.skipOnParamError&&t.skipOnParamError&&(e.parsingPriority||t.parsingPriority))return t.parsingPriority-e.parsingPriority;if(e.prefix&&t.prefix&&e.prefix!==t.prefix){if(e.prefix.startsWith(t.prefix))return-1;if(t.prefix.startsWith(e.prefix))return 1}if(e.suffix&&t.suffix&&e.suffix!==t.suffix){if(e.suffix.endsWith(t.suffix))return-1;if(t.suffix.endsWith(e.suffix))return 1}return e.prefix&&!t.prefix?-1:!e.prefix&&t.prefix?1:e.suffix&&!t.suffix?-1:!e.suffix&&t.suffix?1:e.caseSensitive&&!t.caseSensitive?-1:!e.caseSensitive&&t.caseSensitive?1:0}function I(e){if(e.pathless)for(let t of e.pathless)I(t);if(e.static)for(let t of e.static.values())I(t);if(e.staticInsensitive)for(let t of e.staticInsensitive.values())I(t);if(e.dynamic?.length){e.dynamic.sort(F);for(let t of e.dynamic)I(t)}if(e.optional?.length){e.optional.sort(F);for(let t of e.optional)I(t)}if(e.wildcard?.length){e.wildcard.sort(F);for(let t of e.wildcard)I(t)}}function L(e){return{kind:0,depth:0,pathless:null,index:null,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:e,parent:null,parse:null,skipOnParamError:!1,parsingPriority:0}}function R(e,t,n,r,i){return{kind:e,depth:0,pathless:null,index:null,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:t,parent:null,parse:null,skipOnParamError:!1,parsingPriority:0,caseSensitive:n,prefix:r,suffix:i}}function ue(e,t){let n=L(`/`),r=new Uint16Array(6);for(let t of e)P(!1,r,t,1,n,0);I(n),t.masksTree=n,t.flatCache=j(1e3)}function z(e,t){e||=`/`;let n=t.flatCache.get(e);if(n)return n;let r=W(e,t.masksTree);return t.flatCache.set(e,r),r}function B(e,t,n,r,i){e||=`/`,r||=`/`;let a=t?`case\0${e}`:e,o=i.singleCache.get(a);return o||(o=L(`/`),P(t,new Uint16Array(6),{from:e},1,o,0),i.singleCache.set(a,o)),W(r,o,n)}function V(e,t,n=!1){let r=n?e:`nofuzz\0${e}`,i=t.matchCache.get(r);if(i!==void 0)return i;e||=`/`;let a;try{a=W(e,t.segmentTree,n)}catch(e){if(e instanceof URIError)a=null;else throw e}return a&&(a.branch=de(a.route)),t.matchCache.set(r,a),a}function H(e){return e===`/`?e:e.replace(/\/{1,}$/,``)}function U(e,t=!1,n){let r=L(e.fullPath),i=new Uint16Array(6),a={},o={},s=0;return P(t,i,e,1,r,0,e=>{if(n?.(e,s),se(!(e.id in a),`Duplicate routes found with id: ${String(e.id)}`),a[e.id]=e,s!==0&&e.path){let t=H(e.fullPath);(!o[t]||e.fullPath.endsWith(`/`))&&(o[t]=e)}s++}),I(r),{processedTree:{segmentTree:r,singleCache:j(1e3),matchCache:j(1e3),flatCache:null,masksTree:null},routesById:a,routesByPath:o}}function W(e,t,n=!1){let r=e.split(`/`),i=pe(e,r,t,n);if(!i)return null;let[a]=G(e,r,i);return{route:i.node.route,rawParams:a,parsedParams:i.parsedParams}}function G(e,t,n){let r=fe(n.node),i=null,a=Object.create(null),o=n.extract?.part??0,s=n.extract?.node??0,c=n.extract?.path??0,l=n.extract?.segment??0;for(;s<r.length;o++,s++,c++,l++){let u=r[s];if(u.kind===M)break;if(u.kind===ce){l--,o--,c--;continue}let d=t[o],f=c;if(d&&(c+=d.length),u.kind===1){i??=n.node.fullPath.split(`/`);let e=i[l],t=u.prefix?.length??0;if(e.charCodeAt(t)===123){let n=u.suffix?.length??0,r=e.substring(t+2,e.length-n-1),i=d.substring(t,d.length-n);a[r]=decodeURIComponent(i)}else{let t=e.substring(1);a[t]=decodeURIComponent(d)}}else if(u.kind===3){if(n.skipped&1<<s){o--,c=f-1;continue}i??=n.node.fullPath.split(`/`);let e=i[l],t=u.prefix?.length??0,r=u.suffix?.length??0,p=e.substring(t+3,e.length-r-1),m=u.suffix||u.prefix?d.substring(t,d.length-r):d;m&&(a[p]=decodeURIComponent(m))}else if(u.kind===2){let t=u,n=e.substring(f+(t.prefix?.length??0),e.length-(t.suffix?.length??0)),r=decodeURIComponent(n);a[`*`]=r,a._splat=r;break}}return n.rawParams&&Object.assign(a,n.rawParams),[a,{part:o,node:s,path:c,segment:l}]}function de(e){let t=[e];for(;e.parentRoute;)e=e.parentRoute,t.push(e);return t.reverse(),t}function fe(e){let t=Array(e.depth+1);do t[e.depth]=e,e=e.parent;while(e);return t}function pe(e,t,n,r){if(e===`/`&&n.index)return{node:n.index,skipped:0};let i=!d(t),a=i&&e!==`/`,o=t.length-(i?1:0),s=[{node:n,index:1,skipped:0,depth:1,statics:1,dynamics:0,optionals:0}],c=null,l=null,u=null;for(;s.length;){let n=s.pop(),{node:i,index:d,skipped:f,depth:p,statics:m,dynamics:h,optionals:g}=n,{extract:_,rawParams:v,parsedParams:y}=n;if(i.skipOnParamError){if(!K(e,t,n))continue;v=n.rawParams,_=n.extract,y=n.parsedParams}r&&i.route&&i.kind!==M&&q(l,n)&&(l=n);let b=d===o;if(b&&(i.route&&!a&&q(u,n)&&(u=n),!i.optional&&!i.wildcard&&!i.index&&!i.pathless))continue;let x=b?void 0:t[d],S;if(b&&i.index){let n={node:i.index,index:d,skipped:f,depth:p+1,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y},r=!0;if(i.index.skipOnParamError&&(K(e,t,n)||(r=!1)),r){if(m===o&&!h&&!g&&!f)return n;q(u,n)&&(u=n)}}if(i.wildcard&&q(c,n))for(let n of i.wildcard){let{prefix:r,suffix:i}=n;if(r&&(b||!(n.caseSensitive?x:S??=x.toLowerCase()).startsWith(r)))continue;if(i){if(b)continue;let e=t.slice(d).join(`/`).slice(-i.length);if((n.caseSensitive?e:e.toLowerCase())!==i)continue}let a={node:n,index:o,skipped:f,depth:p,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y};if(!(n.skipOnParamError&&!K(e,t,a))){c=a;break}}if(i.optional){let e=f|1<<p,t=p+1;for(let n=i.optional.length-1;n>=0;n--){let r=i.optional[n];s.push({node:r,index:d,skipped:e,depth:t,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b)for(let e=i.optional.length-1;e>=0;e--){let n=i.optional[e],{prefix:r,suffix:a}=n;if(r||a){let e=n.caseSensitive?x:S??=x.toLowerCase();if(r&&!e.startsWith(r)||a&&!e.endsWith(a))continue}s.push({node:n,index:d+1,skipped:f,depth:t,statics:m,dynamics:h,optionals:g+1,extract:_,rawParams:v,parsedParams:y})}}if(!b&&i.dynamic&&x)for(let e=i.dynamic.length-1;e>=0;e--){let t=i.dynamic[e],{prefix:n,suffix:r}=t;if(n||r){let e=t.caseSensitive?x:S??=x.toLowerCase();if(n&&!e.startsWith(n)||r&&!e.endsWith(r))continue}s.push({node:t,index:d+1,skipped:f,depth:p+1,statics:m,dynamics:h+1,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b&&i.staticInsensitive){let e=i.staticInsensitive.get(S??=x.toLowerCase());e&&s.push({node:e,index:d+1,skipped:f,depth:p+1,statics:m+1,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b&&i.static){let e=i.static.get(x);e&&s.push({node:e,index:d+1,skipped:f,depth:p+1,statics:m+1,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(i.pathless){let e=p+1;for(let t=i.pathless.length-1;t>=0;t--){let n=i.pathless[t];s.push({node:n,index:d,skipped:f,depth:e,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}}}if(u&&c)return q(c,u)?u:c;if(u)return u;if(c)return c;if(r&&l){let n=l.index;for(let e=0;e<l.index;e++)n+=t[e].length;let r=n===e.length?`/`:e.slice(n);return l.rawParams??=Object.create(null),l.rawParams[`**`]=decodeURIComponent(r),l}return null}function K(e,t,n){try{let[r,i]=G(e,t,n);n.rawParams=r,n.extract=i;let a=n.node.parse(r);return n.parsedParams=Object.assign(Object.create(null),n.parsedParams,a),!0}catch{return null}}function q(e,t){return e?t.statics>e.statics||t.statics===e.statics&&(t.dynamics>e.dynamics||t.dynamics===e.dynamics&&(t.optionals>e.optionals||t.optionals===e.optionals&&((t.node.kind===M)>(e.node.kind===M)||t.node.kind===M==(e.node.kind===M)&&t.depth>e.depth))):!0}function J(e){return Y(e.filter(e=>e!==void 0).join(`/`))}function Y(e){return e.replace(/\/{2,}/g,`/`)}function X(e){return e===`/`?e:e.replace(/^\/{1,}/,``)}function me(e){let t=e.length;return t>1&&e[t-1]===`/`?e.replace(/\/{1,}$/,``):e}function he(e){return me(X(e))}function Z(e,t){return e?.endsWith(`/`)&&e!==`/`&&e!==`${t}/`?e.slice(0,-1):e}function ge(e,t,n){return Z(e,n)===Z(t,n)}function _e({base:e,to:t,trailingSlash:n=`never`,cache:r}){let i=t.startsWith(`/`),a=!i&&t===`.`,o;if(r){o=i?t:a?e:e+`\0`+t;let n=r.get(o);if(n)return n}let s;if(a)s=e.split(`/`);else if(i)s=t.split(`/`);else{for(s=e.split(`/`);s.length>1&&d(s)===``;)s.pop();let n=t.split(`/`);for(let e=0,t=n.length;e<t;e++){let r=n[e];r===``?e?e===t-1&&s.push(r):s=[r]:r===`..`?s.pop():r===`.`||s.push(r)}}s.length>1&&(d(s)===``?n===`never`&&s.pop():n===`always`&&s.push(``));let c,l=``;for(let e=0;e<s.length;e++){e>0&&(l+=`/`);let t=s[e];if(!t)continue;c=N(t,0,c);let n=c[0];if(n===0){l+=t;continue}let r=c[5],i=t.substring(0,c[1]),a=t.substring(c[4],r),o=t.substring(c[2],c[3]);n===1?l+=i||a?`${i}{$${o}}${a}`:`$${o}`:n===2?l+=i||a?`${i}{$}${a}`:`$`:l+=`${i}{-$${o}}${a}`}l=Y(l);let u=l||`/`;return o&&r&&r.set(o,u),u}function ve(e){let t=new Map(e.map(e=>[encodeURIComponent(e),e])),n=Array.from(t.keys()).map(e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)).join(`|`),r=new RegExp(n,`g`);return e=>e.replace(r,e=>t.get(e)??e)}function ye(e,t,n){let r=t[e];return typeof r==`string`?e===`_splat`?/^[a-zA-Z0-9\-._~!/]*$/.test(r)?r:r.split(`/`).map(e=>xe(e,n)).join(`/`):xe(r,n):r}function be({path:e,params:t,decoder:n,...r}){let i=!1,a=Object.create(null);if(!e||e===`/`)return{interpolatedPath:`/`,usedParams:a,isMissingParams:i};if(!e.includes(`$`))return{interpolatedPath:e,usedParams:a,isMissingParams:i};let o=e.length,s=0,c,l=``;for(;s<o;){let r=s;c=N(e,r,c);let o=c[5];if(s=o+1,r===o)continue;let u=c[0];if(u===0){l+=`/`+e.substring(r,o);continue}if(u===2){let s=t._splat;a._splat=s,a[`*`]=s;let u=e.substring(r,c[1]),d=e.substring(c[4],o);if(!s){i=!0,(u||d)&&(l+=`/`+u+d);continue}let f=ye(`_splat`,t,n);l+=`/`+u+f+d;continue}if(u===1){let s=e.substring(c[2],c[3]);!i&&!(s in t)&&(i=!0),a[s]=t[s];let u=e.substring(r,c[1]),d=e.substring(c[4],o),f=ye(s,t,n)??`undefined`;l+=`/`+u+f+d;continue}if(u===3){let i=e.substring(c[2],c[3]),s=t[i];if(s==null)continue;a[i]=s;let u=e.substring(r,c[1]),d=e.substring(c[4],o),f=ye(i,t,n)??``;l+=`/`+u+f+d;continue}}return e.endsWith(`/`)&&(l+=`/`),{usedParams:a,interpolatedPath:l||`/`,isMissingParams:i}}function xe(e,t){let n=encodeURIComponent(e);return t?.(n)??n}var Se=`Error preloading route! ☝️`,Ce=t();function we({children:e,fallback:t=null}){return Te()?(0,Ce.jsx)(a.Fragment,{children:e}):(0,Ce.jsx)(a.Fragment,{children:t})}function Te(){return a.useSyncExternalStore(Ee,()=>!0,()=>!1)}function Ee(){return()=>{}}var De=a.createContext(null),Oe=!0;function ke(e,t){if(!Oe){if(e)return;var n=`Warning: `+t;typeof console<`u`&&console.warn(n);try{throw Error(n)}catch{}}}function Ae(e){let t=a.useContext(De);return ke(!((e?.warn??!0)&&!t),`useRouter must be used inside a <RouterProvider> component!`),t}var je=r((e=>{var t=n();function r(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var i=typeof Object.is==`function`?Object.is:r,a=t.useState,o=t.useEffect,s=t.useLayoutEffect,c=t.useDebugValue;function l(e,t){var n=t(),r=a({inst:{value:n,getSnapshot:t}}),i=r[0].inst,l=r[1];return s(function(){i.value=n,i.getSnapshot=t,u(i)&&l({inst:i})},[e,n,t]),o(function(){return u(i)&&l({inst:i}),e(function(){u(i)&&l({inst:i})})},[e]),c(n),n}function u(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!i(e,n)}catch{return!0}}function d(e,t){return t()}var f=typeof window>`u`||window.document===void 0||window.document.createElement===void 0?d:l;e.useSyncExternalStore=t.useSyncExternalStore===void 0?f:t.useSyncExternalStore})),Me=r(((e,t)=>{t.exports=je()})),Ne=r((e=>{var t=n(),r=Me();function i(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var a=typeof Object.is==`function`?Object.is:i,o=r.useSyncExternalStore,s=t.useRef,c=t.useEffect,l=t.useMemo,u=t.useDebugValue;e.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var d=s(null);if(d.current===null){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=l(function(){function e(e){if(!o){if(o=!0,s=e,e=r(e),i!==void 0&&f.hasValue){var t=f.value;if(i(t,e))return c=t}return c=e}if(t=c,a(s,e))return t;var n=r(e);return i!==void 0&&i(t,n)?(s=e,t):(s=e,c=n)}var o=!1,s,c,l=n===void 0?null:n;return[function(){return e(t())},l===null?void 0:function(){return e(l())}]},[t,n,r,i]);var p=o(e,d[0],d[1]);return c(function(){f.hasValue=!0,f.value=p},[p]),u(p),p}})),Pe=r(((e,t)=>{t.exports=Ne()}))();function Fe(e,t){return e===t}function Ie(e,t,n=Fe){let r=(0,a.useCallback)(t=>{if(!e)return()=>{};let{unsubscribe:n}=e.subscribe(t);return n},[e]),i=(0,a.useCallback)(()=>e?.get(),[e]);return(0,Pe.useSyncExternalStoreWithSelector)(r,i,i,t,n)}function Le(e){let t=Ae({warn:e?.router===void 0}),n=e?.router||t,r=(0,a.useRef)(void 0);return Ie(n.__store,t=>{if(e?.select){if(e.structuralSharing??n.options.defaultStructuralSharing){let n=v(r.current,e.select(t));return r.current=n,n}return e.select(t)}return t})}var Re=i(e(),1);function ze(e,t){let n=Ae(),r=u(t),{activeProps:i,inactiveProps:o,activeOptions:s,to:c,preload:d,preloadDelay:f,hashScrollIntoView:m,replace:h,startTransition:g,resetScroll:_,viewTransition:v,children:y,target:b,disabled:x,style:S,className:w,onClick:T,onBlur:E,onFocus:D,onMouseEnter:O,onMouseLeave:k,onTouchStart:A,ignoreBlocker:te,params:ne,search:re,hash:ie,state:j,mask:ae,reloadDocument:oe,unsafeRelative:se,from:M,_fromLocation:ce,...le}=e,N=Te(),P=Le({select:e=>{let t=e.matches[e.matches.length-1];return{search:t?.search,hash:e.location.hash,path:t?.pathname}},structuralSharing:!0}),F=e.from,I=a.useMemo(()=>({...e,from:F}),[n,P,F,e._fromLocation,e.hash,e.to,e.search,e.params,e.state,e.mask,e.unsafeRelative]),L=a.useMemo(()=>n.buildLocation({...I}),[n,I]),R=L.maskedLocation?L.maskedLocation.publicHref:L.publicHref,ue=L.maskedLocation?L.maskedLocation.external:L.external,z=a.useMemo(()=>Ke(R,ue,n.history,x),[x,ue,R,n.history]),B=a.useMemo(()=>{if(z?.external)return ee(z.href,n.protocolAllowlist)?void 0:z.href;if(!qe(c)&&!(typeof c!=`string`||c.indexOf(`:`)===-1))try{return new URL(c),ee(c,n.protocolAllowlist)?void 0:c}catch{}},[c,z,n.protocolAllowlist]),V=Le({select:e=>{if(B)return!1;if(s?.exact){if(!ge(e.location.pathname,L.pathname,n.basepath))return!1}else{let t=Z(e.location.pathname,n.basepath),r=Z(L.pathname,n.basepath);if(!(t.startsWith(r)&&(t.length===r.length||t[r.length]===`/`)))return!1}return(s?.includeSearch??!0)&&!C(e.location.search,L.search,{partial:!s?.exact,ignoreUndefined:!s?.explicitUndefined})?!1:s?.includeHash?N&&e.location.hash===L.hash:!0}}),H=V?p(i,{})??Ve:Be,U=V?Be:p(o,{})??Be,W=[w,H.className,U.className].filter(Boolean).join(` `),G=(S||H.style||U.style)&&{...S,...H.style,...U.style},[de,fe]=a.useState(!1),pe=a.useRef(!1),K=e.reloadDocument||B?!1:d??n.options.defaultPreload,q=f??n.options.defaultPreloadDelay??0,J=a.useCallback(()=>{n.preloadRoute({...I,_builtLocation:L}).catch(e=>{console.warn(e),console.warn(Se)})},[n,I,L]);l(r,a.useCallback(e=>{e?.isIntersecting&&J()},[J]),Ge,{disabled:!!x||K!==`viewport`}),a.useEffect(()=>{pe.current||!x&&K===`render`&&(J(),pe.current=!0)},[x,J,K]);let Y=e=>{let t=e.currentTarget.getAttribute(`target`),r=b===void 0?t:b;if(!x&&!Ye(e)&&!e.defaultPrevented&&(!r||r===`_self`)&&e.button===0){e.preventDefault(),(0,Re.flushSync)(()=>{fe(!0)});let t=n.subscribe(`onResolved`,()=>{t(),fe(!1)});n.navigate({...I,replace:h,resetScroll:_,hashScrollIntoView:m,startTransition:g,viewTransition:v,ignoreBlocker:te})}};if(B)return{...le,ref:r,href:B,...y&&{children:y},...b&&{target:b},...x&&{disabled:x},...S&&{style:S},...w&&{className:w},...T&&{onClick:T},...E&&{onBlur:E},...D&&{onFocus:D},...O&&{onMouseEnter:O},...k&&{onMouseLeave:k},...A&&{onTouchStart:A}};let X=e=>{if(x||K!==`intent`)return;if(!q){J();return}let t=e.currentTarget;if(Q.has(t))return;let n=setTimeout(()=>{Q.delete(t),J()},q);Q.set(t,n)},me=e=>{x||K!==`intent`||J()},he=e=>{if(x||!K||!q)return;let t=e.currentTarget,n=Q.get(t);n&&(clearTimeout(n),Q.delete(t))};return{...le,...H,...U,href:z?.href,ref:r,onClick:$([T,Y]),onBlur:$([E,he]),onFocus:$([D,X]),onMouseEnter:$([O,X]),onMouseLeave:$([k,he]),onTouchStart:$([A,me]),disabled:!!x,target:b,...G&&{style:G},...W&&{className:W},...x&&He,...V&&Ue,...N&&de&&We}}var Be={},Ve={className:`active`},He={role:`link`,"aria-disabled":!0},Ue={"data-status":`active`,"aria-current":`page`},We={"data-transitioning":`transitioning`},Q=new WeakMap,Ge={rootMargin:`100px`},$=e=>t=>{for(let n of e)if(n){if(t.defaultPrevented)return;n(t)}};function Ke(e,t,n,r){if(!r)return t?{href:e,external:!0}:{href:n.createHref(e)||`/`,external:!1}}function qe(e){if(typeof e!=`string`)return!1;let t=e.charCodeAt(0);return t===47?e.charCodeAt(1)!==47:t===46}var Je=a.forwardRef((e,t)=>{let{_asChild:n,...r}=e,{type:i,...o}=ze(r,t),s=typeof r.children==`function`?r.children({isActive:o[`data-status`]===`active`}):r.children;if(!n){let{disabled:e,...t}=o;return a.createElement(`a`,t,s)}return a.createElement(n,o,s)});function Ye(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}export{T as A,w as C,ne as D,ie as E,o as F,s as I,c as L,d as M,_ as N,p as O,v as P,k as S,C as T,B as _,De as a,se as b,ve as c,_e as d,he as f,V as g,z as h,ke as i,E as j,ee as k,be as l,me as m,Le as n,we as o,X as p,Ae as r,Y as s,Je as t,J as u,ue as v,re as w,j as x,U as y};
@@ -0,0 +1 @@
1
+ import{It as e,Lt as t,cn as n,ln as r,sn as i,un as a}from"./badge-LeU66vxM.js";var o=a(t(),1),s=(0,o.createContext)({});function c(e){let t=(0,o.useRef)(null);return t.current===null&&(t.current=e()),t.current}var l=typeof window<`u`?o.useLayoutEffect:o.useEffect,u=(0,o.createContext)(null);function d(e,t){e.indexOf(t)===-1&&e.push(t)}function f(e,t){let n=e.indexOf(t);n>-1&&e.splice(n,1)}var p=(e,t,n)=>n>t?t:n<e?e:n,m={},h=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function g(e){return typeof e==`object`&&!!e}var _=e=>/^0[^.\s]+$/u.test(e);function v(e){let t;return()=>(t===void 0&&(t=e()),t)}var y=e=>e,b=(e,t)=>n=>t(e(n)),x=(...e)=>e.reduce(b),S=(e,t,n)=>{let r=t-e;return r===0?1:(n-e)/r},C=class{constructor(){this.subscriptions=[]}add(e){return d(this.subscriptions,e),()=>f(this.subscriptions,e)}notify(e,t,n){let r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](e,t,n);else for(let i=0;i<r;i++){let r=this.subscriptions[i];r&&r(e,t,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}},w=e=>e*1e3,T=e=>e/1e3;function E(e,t){return t?1e3/t*e:0}var D=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,ee=1e-7,te=12;function ne(e,t,n,r,i){let a,o,s=0;do o=t+(n-t)/2,a=D(o,r,i)-e,a>0?n=o:t=o;while(Math.abs(a)>ee&&++s<te);return o}function re(e,t,n,r){if(e===t&&n===r)return y;let i=t=>ne(t,0,1,e,n);return e=>e===0||e===1?e:D(i(e),t,r)}var ie=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,ae=e=>t=>1-e(1-t),oe=re(.33,1.53,.69,.99),se=ae(oe),ce=ie(se),le=e=>e>=1?1:(e*=2)<1?.5*se(e):.5*(2-2**(-10*(e-1))),ue=e=>1-Math.sin(Math.acos(e)),de=ae(ue),fe=ie(ue),pe=re(.42,0,1,1),me=re(0,0,.58,1),he=re(.42,0,.58,1),ge=e=>Array.isArray(e)&&typeof e[0]!=`number`,_e=e=>Array.isArray(e)&&typeof e[0]==`number`,ve={linear:y,easeIn:pe,easeInOut:he,easeOut:me,circIn:ue,circInOut:fe,circOut:de,backIn:se,backInOut:ce,backOut:oe,anticipate:le},ye=e=>typeof e==`string`,be=e=>{if(_e(e)){e.length;let[t,n,r,i]=e;return re(t,n,r,i)}else if(ye(e))return ve[e],`${e}`,ve[e];return e},xe=[`setup`,`read`,`resolveKeyframes`,`preUpdate`,`update`,`preRender`,`render`,`postRender`],O={value:null,addProjectionMetrics:null};function Se(e,t){let n=new Set,r=new Set,i=!1,a=!1,o=new WeakSet,s={delta:0,timestamp:0,isProcessing:!1},c=0;function l(t){o.has(t)&&(u.schedule(t),e()),c++,t(s)}let u={schedule:(e,t=!1,a=!1)=>{let s=a&&i?n:r;return t&&o.add(e),s.add(e),e},cancel:e=>{r.delete(e),o.delete(e)},process:e=>{if(s=e,i){a=!0;return}i=!0;let o=n;n=r,r=o,n.forEach(l),t&&O.value&&O.value.frameloop[t].push(c),c=0,n.clear(),i=!1,a&&(a=!1,u.process(e))}};return u}var Ce=40;function we(e,t){let n=!1,r=!0,i={delta:0,timestamp:0,isProcessing:!1},a=()=>n=!0,o=xe.reduce((e,n)=>(e[n]=Se(a,t?n:void 0),e),{}),{setup:s,read:c,resolveKeyframes:l,preUpdate:u,update:d,preRender:f,render:p,postRender:h}=o,g=()=>{let a=m.useManualTiming,o=a?i.timestamp:performance.now();n=!1,a||(i.delta=r?1e3/60:Math.max(Math.min(o-i.timestamp,Ce),1)),i.timestamp=o,i.isProcessing=!0,s.process(i),c.process(i),l.process(i),u.process(i),d.process(i),f.process(i),p.process(i),h.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(g))},_=()=>{n=!0,r=!0,i.isProcessing||e(g)};return{schedule:xe.reduce((e,t)=>{let r=o[t];return e[t]=(e,t=!1,i=!1)=>(n||_(),r.schedule(e,t,i)),e},{}),cancel:e=>{for(let t=0;t<xe.length;t++)o[xe[t]].cancel(e)},state:i,steps:o}}var{schedule:k,cancel:A,state:j,steps:Te}=we(typeof requestAnimationFrame<`u`?requestAnimationFrame:y,!0),Ee;function De(){Ee=void 0}var M={now:()=>(Ee===void 0&&M.set(j.isProcessing||m.useManualTiming?j.timestamp:performance.now()),Ee),set:e=>{Ee=e,queueMicrotask(De)}},Oe={layout:0,mainThread:0,waapi:0},ke=e=>t=>typeof t==`string`&&t.startsWith(e),Ae=ke(`--`),je=ke(`var(--`),Me=e=>je(e)?Ne.test(e.split(`/*`)[0].trim()):!1,Ne=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function Pe(e){return typeof e==`string`?e.split(`/*`)[0].includes(`var(--`):!1}var Fe={test:e=>typeof e==`number`,parse:parseFloat,transform:e=>e},Ie={...Fe,transform:e=>p(0,1,e)},Le={...Fe,default:1},Re=e=>Math.round(e*1e5)/1e5,ze=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Be(e){return e==null}var Ve=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,He=(e,t)=>n=>!!(typeof n==`string`&&Ve.test(n)&&n.startsWith(e)||t&&!Be(n)&&Object.prototype.hasOwnProperty.call(n,t)),Ue=(e,t,n)=>r=>{if(typeof r!=`string`)return r;let[i,a,o,s]=r.match(ze);return{[e]:parseFloat(i),[t]:parseFloat(a),[n]:parseFloat(o),alpha:s===void 0?1:parseFloat(s)}},We=e=>p(0,255,e),Ge={...Fe,transform:e=>Math.round(We(e))},Ke={test:He(`rgb`,`red`),parse:Ue(`red`,`green`,`blue`),transform:({red:e,green:t,blue:n,alpha:r=1})=>`rgba(`+Ge.transform(e)+`, `+Ge.transform(t)+`, `+Ge.transform(n)+`, `+Re(Ie.transform(r))+`)`};function qe(e){let t=``,n=``,r=``,i=``;return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}var Je={test:He(`#`),parse:qe,transform:Ke.transform},Ye=e=>({test:t=>typeof t==`string`&&t.endsWith(e)&&t.split(` `).length===1,parse:parseFloat,transform:t=>`${t}${e}`}),N=Ye(`deg`),P=Ye(`%`),F=Ye(`px`),Xe=Ye(`vh`),Ze=Ye(`vw`),Qe={...P,parse:e=>P.parse(e)/100,transform:e=>P.transform(e*100)},$e={test:He(`hsl`,`hue`),parse:Ue(`hue`,`saturation`,`lightness`),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>`hsla(`+Math.round(e)+`, `+P.transform(Re(t))+`, `+P.transform(Re(n))+`, `+Re(Ie.transform(r))+`)`},I={test:e=>Ke.test(e)||Je.test(e)||$e.test(e),parse:e=>Ke.test(e)?Ke.parse(e):$e.test(e)?$e.parse(e):Je.parse(e),transform:e=>typeof e==`string`?e:e.hasOwnProperty(`red`)?Ke.transform(e):$e.transform(e),getAnimatableNone:e=>{let t=I.parse(e);return t.alpha=0,I.transform(t)}},et=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function tt(e){return isNaN(e)&&typeof e==`string`&&(e.match(ze)?.length||0)+(e.match(et)?.length||0)>0}var nt=`number`,rt=`color`,it=`var`,at=`var(`,ot="${}",st=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ct(e){let t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[],a=0;return{values:n,split:t.replace(st,e=>(I.test(e)?(r.color.push(a),i.push(rt),n.push(I.parse(e))):e.startsWith(at)?(r.var.push(a),i.push(it),n.push(e)):(r.number.push(a),i.push(nt),n.push(parseFloat(e))),++a,ot)).split(ot),indexes:r,types:i}}function lt(e){return ct(e).values}function ut({split:e,types:t}){let n=e.length;return r=>{let i=``;for(let a=0;a<n;a++)if(i+=e[a],r[a]!==void 0){let e=t[a];e===nt?i+=Re(r[a]):e===rt?i+=I.transform(r[a]):i+=r[a]}return i}}function dt(e){return ut(ct(e))}var ft=e=>typeof e==`number`?0:I.test(e)?I.getAnimatableNone(e):e,pt=(e,t)=>typeof e==`number`?t?.trim().endsWith(`/`)?e:0:ft(e);function mt(e){let t=ct(e);return ut(t)(t.values.map((e,n)=>pt(e,t.split[n])))}var L={test:tt,parse:lt,createTransformer:dt,getAnimatableNone:mt};function ht(e,t,n){return n<0&&(n+=1),n>1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function gt({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,a=0,o=0;if(!t)i=a=o=n;else{let r=n<.5?n*(1+t):n+t-n*t,s=2*n-r;i=ht(s,r,e+1/3),a=ht(s,r,e),o=ht(s,r,e-1/3)}return{red:Math.round(i*255),green:Math.round(a*255),blue:Math.round(o*255),alpha:r}}function _t(e,t){return n=>n>0?t:e}var R=(e,t,n)=>e+(t-e)*n,vt=(e,t,n)=>{let r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},yt=[Je,Ke,$e],bt=e=>yt.find(t=>t.test(e));function xt(e){let t=bt(e);if(`${e}`,!t)return!1;let n=t.parse(e);return t===$e&&(n=gt(n)),n}var St=(e,t)=>{let n=xt(e),r=xt(t);if(!n||!r)return _t(e,t);let i={...n};return e=>(i.red=vt(n.red,r.red,e),i.green=vt(n.green,r.green,e),i.blue=vt(n.blue,r.blue,e),i.alpha=R(n.alpha,r.alpha,e),Ke.transform(i))},Ct=new Set([`none`,`hidden`]);function wt(e,t){return Ct.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function Tt(e,t){return n=>R(e,t,n)}function Et(e){return typeof e==`number`?Tt:typeof e==`string`?Me(e)?_t:I.test(e)?St:At:Array.isArray(e)?Dt:typeof e==`object`?I.test(e)?St:Ot:_t}function Dt(e,t){let n=[...e],r=n.length,i=e.map((e,n)=>Et(e)(e,t[n]));return e=>{for(let t=0;t<r;t++)n[t]=i[t](e);return n}}function Ot(e,t){let n={...e,...t},r={};for(let i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=Et(e[i])(e[i],t[i]));return e=>{for(let t in r)n[t]=r[t](e);return n}}function kt(e,t){let n=[],r={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){let a=t.types[i],o=e.indexes[a][r[a]];n[i]=e.values[o]??0,r[a]++}return n}var At=(e,t)=>{let n=L.createTransformer(t),r=ct(e),i=ct(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Ct.has(e)&&!i.values.length||Ct.has(t)&&!r.values.length?wt(e,t):x(Dt(kt(r,i),i.values),n):(`${e}${t}`,_t(e,t))};function jt(e,t,n){return typeof e==`number`&&typeof t==`number`&&typeof n==`number`?R(e,t,n):Et(e)(e,t)}var Mt=e=>{let t=({timestamp:t})=>e(t);return{start:(e=!0)=>k.update(t,e),stop:()=>A(t),now:()=>j.isProcessing?j.timestamp:M.now()}},Nt=(e,t,n=10)=>{let r=``,i=Math.max(Math.round(t/n),2);for(let t=0;t<i;t++)r+=Math.round(e(t/(i-1))*1e4)/1e4+`, `;return`linear(${r.substring(0,r.length-2)})`},Pt=2e4;function Ft(e){let t=0,n=e.next(t);for(;!n.done&&t<2e4;)t+=50,n=e.next(t);return t>=2e4?1/0:t}function It(e,t=100,n){let r=n({...e,keyframes:[0,t]}),i=Math.min(Ft(r),Pt);return{type:`keyframes`,ease:e=>r.next(i*e).value/t,duration:T(i)}}var z={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function Lt(e,t){return e*Math.sqrt(1-t*t)}var Rt=12;function zt(e,t,n){let r=n;for(let n=1;n<Rt;n++)r-=e(r)/t(r);return r}var Bt=.001;function Vt({duration:e=z.duration,bounce:t=z.bounce,velocity:n=z.velocity,mass:r=z.mass}){let i,a;w(z.maxDuration);let o=1-t;o=p(z.minDamping,z.maxDamping,o),e=p(z.minDuration,z.maxDuration,T(e)),o<1?(i=t=>{let r=t*o,i=r*e,a=r-n,s=Lt(t,o),c=Math.exp(-i);return Bt-a/s*c},a=t=>{let r=t*o*e,a=r*n+n,s=o**2*t**2*e,c=Math.exp(-r),l=Lt(t**2,o);return(-i(t)+Bt>0?-1:1)*((a-s)*c)/l}):(i=t=>{let r=Math.exp(-t*e),i=(t-n)*e+1;return-Bt+r*i},a=t=>Math.exp(-t*e)*((n-t)*(e*e)));let s=5/e,c=zt(i,a,s);if(e=w(e),isNaN(c))return{stiffness:z.stiffness,damping:z.damping,duration:e};{let t=c**2*r;return{stiffness:t,damping:o*2*Math.sqrt(r*t),duration:e}}}var Ht=[`duration`,`bounce`],Ut=[`stiffness`,`damping`,`mass`];function Wt(e,t){return t.some(t=>e[t]!==void 0)}function Gt(e){let t={velocity:z.velocity,stiffness:z.stiffness,damping:z.damping,mass:z.mass,isResolvedFromDuration:!1,...e};if(!Wt(e,Ut)&&Wt(e,Ht))if(t.velocity=0,e.visualDuration){let n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,a=2*p(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:z.mass,stiffness:i,damping:a}}else{let n=Vt({...e,velocity:0});t={...t,...n,mass:z.mass},t.isResolvedFromDuration=!0}return t}function Kt(e=z.visualDuration,t=z.bounce){let n=typeof e==`object`?e:{visualDuration:e,keyframes:[0,1],bounce:t},{restSpeed:r,restDelta:i}=n,a=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],s={done:!1,value:a},{stiffness:c,damping:l,mass:u,duration:d,velocity:f,isResolvedFromDuration:p}=Gt({...n,velocity:-T(n.velocity||0)}),m=f||0,h=l/(2*Math.sqrt(c*u)),g=o-a,_=T(Math.sqrt(c/u)),v=Math.abs(g)<5;r||=v?z.restSpeed.granular:z.restSpeed.default,i||=v?z.restDelta.granular:z.restDelta.default;let y,b,x,S,C,E;if(h<1)x=Lt(_,h),S=(m+h*_*g)/x,y=e=>o-Math.exp(-h*_*e)*(S*Math.sin(x*e)+g*Math.cos(x*e)),C=h*_*S+g*x,E=h*_*g-S*x,b=e=>Math.exp(-h*_*e)*(C*Math.sin(x*e)+E*Math.cos(x*e));else if(h===1){y=e=>o-Math.exp(-_*e)*(g+(m+_*g)*e);let e=m+_*g;b=t=>Math.exp(-_*t)*(_*e*t-m)}else{let e=_*Math.sqrt(h*h-1);y=t=>{let n=Math.exp(-h*_*t),r=Math.min(e*t,300);return o-n*((m+h*_*g)*Math.sinh(r)+e*g*Math.cosh(r))/e};let t=(m+h*_*g)/e,n=h*_*t-g*e,r=h*_*g-t*e;b=t=>{let i=Math.exp(-h*_*t),a=Math.min(e*t,300);return i*(n*Math.sinh(a)+r*Math.cosh(a))}}let D={calculatedDuration:p&&d||null,velocity:e=>w(b(e)),next:e=>{if(!p&&h<1){let t=Math.exp(-h*_*e),n=Math.sin(x*e),a=Math.cos(x*e),c=o-t*(S*n+g*a),l=w(t*(C*n+E*a));return s.done=Math.abs(l)<=r&&Math.abs(o-c)<=i,s.value=s.done?o:c,s}let t=y(e);if(p)s.done=e>=d;else{let n=w(b(e));s.done=Math.abs(n)<=r&&Math.abs(o-t)<=i}return s.value=s.done?o:t,s},toString:()=>{let e=Math.min(Ft(D),Pt),t=Nt(t=>D.next(e*t).value,e,30);return e+`ms `+t},toTransition:()=>{}};return D}Kt.applyToOptions=e=>{let t=It(e,100,Kt);return e.ease=t.ease,e.duration=w(t.duration),e.type=`keyframes`,e};var qt=5;function Jt(e,t,n){let r=Math.max(t-qt,0);return E(n-e(r),t-r)}function Yt({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:a=500,modifyTarget:o,min:s,max:c,restDelta:l=.5,restSpeed:u}){let d=e[0],f={done:!1,value:d},p=e=>s!==void 0&&e<s||c!==void 0&&e>c,m=e=>s===void 0?c:c===void 0||Math.abs(s-e)<Math.abs(c-e)?s:c,h=n*t,g=d+h,_=o===void 0?g:o(g);_!==g&&(h=_-d);let v=e=>-h*Math.exp(-e/r),y=e=>_+v(e),b=e=>{let t=v(e),n=y(e);f.done=Math.abs(t)<=l,f.value=f.done?_:n},x,S,C=e=>{p(f.value)&&(x=e,S=Kt({keyframes:[f.value,m(f.value)],velocity:Jt(y,e,f.value),damping:i,stiffness:a,restDelta:l,restSpeed:u}))};return C(0),{calculatedDuration:null,next:e=>{let t=!1;return!S&&x===void 0&&(t=!0,b(e),C(e)),x!==void 0&&e>=x?S.next(e-x):(!t&&b(e),f)}}}function Xt(e,t,n){let r=[],i=n||m.mix||jt,a=e.length-1;for(let n=0;n<a;n++){let a=i(e[n],e[n+1]);t&&(a=x(Array.isArray(t)?t[n]||y:t,a)),r.push(a)}return r}function Zt(e,t,{clamp:n=!0,ease:r,mixer:i}={}){let a=e.length;if(t.length,a===1)return()=>t[0];if(a===2&&t[0]===t[1])return()=>t[1];let o=e[0]===e[1];e[0]>e[a-1]&&(e=[...e].reverse(),t=[...t].reverse());let s=Xt(t,r,i),c=s.length,l=n=>{if(o&&n<e[0])return t[0];let r=0;if(c>1)for(;r<e.length-2&&!(n<e[r+1]);r++);let i=S(e[r],e[r+1],n);return s[r](i)};return n?t=>l(p(e[0],e[a-1],t)):l}function Qt(e,t){let n=e[e.length-1];for(let r=1;r<=t;r++){let i=S(0,t,r);e.push(R(n,1,i))}}function $t(e){let t=[0];return Qt(t,e.length-1),t}function en(e,t){return e.map(e=>e*t)}function tn(e,t){return e.map(()=>t||he).splice(0,e.length-1)}function nn({duration:e=300,keyframes:t,times:n,ease:r=`easeInOut`}){let i=ge(r)?r.map(be):be(r),a={done:!1,value:t[0]},o=Zt(en(n&&n.length===t.length?n:$t(t),e),t,{ease:Array.isArray(i)?i:tn(t,i)});return{calculatedDuration:e,next:t=>(a.value=o(t),a.done=t>=e,a)}}var rn=e=>e!==null;function an(e,{repeat:t,repeatType:n=`loop`},r,i=1){let a=e.filter(rn),o=i<0||t&&n!==`loop`&&t%2==1?0:a.length-1;return!o||r===void 0?a[o]:r}var on={decay:Yt,inertia:Yt,tween:nn,keyframes:nn,spring:Kt};function sn(e){typeof e.type==`string`&&(e.type=on[e.type])}var cn=class{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(e=>{this.resolve=e})}notifyFinished(){this.resolve()}then(e,t){return this.finished.then(e,t)}},ln=e=>e/100,un=class extends cn{constructor(e){super(),this.state=`idle`,this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{let{motionValue:e}=this.options;e&&e.updatedAt!==M.now()&&this.tick(M.now()),this.isStopped=!0,this.state!==`idle`&&(this.teardown(),this.options.onStop?.())},Oe.mainThread++,this.options=e,this.initAnimation(),this.play(),e.autoplay===!1&&this.pause()}initAnimation(){let{options:e}=this;sn(e);let{type:t=nn,repeat:n=0,repeatDelay:r=0,repeatType:i,velocity:a=0}=e,{keyframes:o}=e,s=t||nn;s!==nn&&typeof o[0]!=`number`&&(this.mixKeyframes=x(ln,jt(o[0],o[1])),o=[0,100]);let c=s({...e,keyframes:o});i===`mirror`&&(this.mirroredGenerator=s({...e,keyframes:[...o].reverse(),velocity:-a})),c.calculatedDuration===null&&(c.calculatedDuration=Ft(c));let{calculatedDuration:l}=c;this.calculatedDuration=l,this.resolvedDuration=l+r,this.totalDuration=this.resolvedDuration*(n+1)-r,this.generator=c}updateTime(e){let t=Math.round(e-this.startTime)*this.playbackSpeed;this.holdTime===null?this.currentTime=t:this.currentTime=this.holdTime}tick(e,t=!1){let{generator:n,totalDuration:r,mixKeyframes:i,mirroredGenerator:a,resolvedDuration:o,calculatedDuration:s}=this;if(this.startTime===null)return n.next(0);let{delay:c=0,keyframes:l,repeat:u,repeatType:d,repeatDelay:f,type:m,onUpdate:h,finalKeyframe:g}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-r/this.speed,this.startTime)),t?this.currentTime=e:this.updateTime(e);let _=this.currentTime-c*(this.playbackSpeed>=0?1:-1),v=this.playbackSpeed>=0?_<0:_>r;this.currentTime=Math.max(_,0),this.state===`finished`&&this.holdTime===null&&(this.currentTime=r);let y=this.currentTime,b=n;if(u){let e=Math.min(this.currentTime,r)/o,t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),n===1&&t--,t=Math.min(t,u+1),t%2&&(d===`reverse`?(n=1-n,f&&(n-=f/o)):d===`mirror`&&(b=a)),y=p(0,1,n)*o}let x;v?(this.delayState.value=l[0],x=this.delayState):x=b.next(y),i&&!v&&(x.value=i(x.value));let{done:S}=x;!v&&s!==null&&(S=this.playbackSpeed>=0?this.currentTime>=r:this.currentTime<=0);let C=this.holdTime===null&&(this.state===`finished`||this.state===`running`&&S);return C&&m!==Yt&&(x.value=an(l,this.options,g,this.speed)),h&&h(x.value),C&&this.finish(),x}then(e,t){return this.finished.then(e,t)}get duration(){return T(this.calculatedDuration)}get iterationDuration(){let{delay:e=0}=this.options||{};return this.duration+T(e)}get time(){return T(this.currentTime)}set time(e){e=w(e),this.currentTime=e,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state=`paused`,this.holdTime=e,this.tick(e))}getGeneratorVelocity(){let e=this.currentTime;if(e<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(e);let t=this.generator.next(e).value;return Jt(e=>this.generator.next(e).value,e,t)}get speed(){return this.playbackSpeed}set speed(e){let t=this.playbackSpeed!==e;t&&this.driver&&this.updateTime(M.now()),this.playbackSpeed=e,t&&this.driver&&(this.time=T(this.currentTime))}play(){if(this.isStopped)return;let{driver:e=Mt,startTime:t}=this.options;this.driver||=e(e=>this.tick(e)),this.options.onPlay?.();let n=this.driver.now();this.state===`finished`?(this.updateFinished(),this.startTime=n):this.holdTime===null?this.startTime||=t??n:this.startTime=n-this.holdTime,this.state===`finished`&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state=`running`,this.driver.start()}pause(){this.state=`paused`,this.updateTime(M.now()),this.holdTime=this.currentTime}complete(){this.state!==`running`&&this.play(),this.state=`finished`,this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state=`finished`,this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state=`idle`,this.stopDriver(),this.startTime=this.holdTime=null,Oe.mainThread--}stopDriver(){this.driver&&=(this.driver.stop(),void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}attachTimeline(e){return this.options.allowFlatten&&(this.options.type=`keyframes`,this.options.ease=`linear`,this.initAnimation()),this.driver?.stop(),e.observe(this)}};function dn(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}var B=e=>e*180/Math.PI,fn=e=>mn(B(Math.atan2(e[1],e[0]))),pn={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:fn,rotateZ:fn,skewX:e=>B(Math.atan(e[1])),skewY:e=>B(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},mn=e=>(e%=360,e<0&&(e+=360),e),hn=fn,gn=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),_n=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),vn={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:gn,scaleY:_n,scale:e=>(gn(e)+_n(e))/2,rotateX:e=>mn(B(Math.atan2(e[6],e[5]))),rotateY:e=>mn(B(Math.atan2(-e[2],e[0]))),rotateZ:hn,rotate:hn,skewX:e=>B(Math.atan(e[4])),skewY:e=>B(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function yn(e){return e.includes(`scale`)?1:0}function bn(e,t){if(!e||e===`none`)return yn(t);let n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u),r,i;if(n)r=vn,i=n;else{let t=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=pn,i=t}if(!i)return yn(t);let a=r[t],o=i[1].split(`,`).map(Sn);return typeof a==`function`?a(o):o[a]}var xn=(e,t)=>{let{transform:n=`none`}=getComputedStyle(e);return bn(n,t)};function Sn(e){return parseFloat(e.trim())}var Cn=[`transformPerspective`,`x`,`y`,`z`,`translateX`,`translateY`,`translateZ`,`scale`,`scaleX`,`scaleY`,`rotate`,`rotateX`,`rotateY`,`rotateZ`,`skew`,`skewX`,`skewY`],wn=new Set(Cn),Tn=e=>e===Fe||e===F,En=new Set([`x`,`y`,`z`]),Dn=Cn.filter(e=>!En.has(e));function On(e){let t=[];return Dn.forEach(n=>{let r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith(`scale`)?1:0))}),t}var V={width:({x:e},{paddingLeft:t=`0`,paddingRight:n=`0`,boxSizing:r})=>{let i=e.max-e.min;return r===`border-box`?i:i-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t=`0`,paddingBottom:n=`0`,boxSizing:r})=>{let i=e.max-e.min;return r===`border-box`?i:i-parseFloat(t)-parseFloat(n)},top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>bn(t,`x`),y:(e,{transform:t})=>bn(t,`y`)};V.translateX=V.x,V.translateY=V.y;var H=new Set,kn=!1,An=!1,jn=!1;function Mn(){if(An){let e=Array.from(H).filter(e=>e.needsMeasurement),t=new Set(e.map(e=>e.element)),n=new Map;t.forEach(e=>{let t=On(e);t.length&&(n.set(e,t),e.render())}),e.forEach(e=>e.measureInitialState()),t.forEach(e=>{e.render();let t=n.get(e);t&&t.forEach(([t,n])=>{e.getValue(t)?.set(n)})}),e.forEach(e=>e.measureEndState()),e.forEach(e=>{e.suspendedScrollY!==void 0&&window.scrollTo(0,e.suspendedScrollY)})}An=!1,kn=!1,H.forEach(e=>e.complete(jn)),H.clear()}function Nn(){H.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(An=!0)})}function Pn(){jn=!0,Nn(),Mn(),jn=!1}var Fn=class{constructor(e,t,n,r,i,a=!1){this.state=`pending`,this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=r,this.element=i,this.isAsync=a}scheduleResolve(){this.state=`scheduled`,this.isAsync?(H.add(this),kn||(kn=!0,k.read(Nn),k.resolveKeyframes(Mn))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:e,name:t,element:n,motionValue:r}=this;if(e[0]===null){let i=r?.get(),a=e[e.length-1];if(i!==void 0)e[0]=i;else if(n&&t){let r=n.readValue(t,a);r!=null&&(e[0]=r)}e[0]===void 0&&(e[0]=a),r&&i===void 0&&r.set(e[0])}dn(e)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(e=!1){this.state=`complete`,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,e),H.delete(this)}cancel(){this.state===`scheduled`&&(H.delete(this),this.state=`pending`)}resume(){this.state===`pending`&&this.scheduleResolve()}},In=e=>e.startsWith(`--`);function Ln(e,t,n){In(t)?e.style.setProperty(t,n):e.style[t]=n}var Rn={};function zn(e,t){let n=v(e);return()=>Rn[t]??n()}var Bn=zn(()=>window.ScrollTimeline!==void 0,`scrollTimeline`),Vn=zn(()=>{try{document.createElement(`div`).animate({opacity:0},{easing:`linear(0, 1)`})}catch{return!1}return!0},`linearEasing`),Hn=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Un={linear:`linear`,ease:`ease`,easeIn:`ease-in`,easeOut:`ease-out`,easeInOut:`ease-in-out`,circIn:Hn([0,.65,.55,1]),circOut:Hn([.55,0,1,.45]),backIn:Hn([.31,.01,.66,-.59]),backOut:Hn([.33,1.53,.69,.99])};function Wn(e,t){if(e)return typeof e==`function`?Vn()?Nt(e,t):`ease-out`:_e(e)?Hn(e):Array.isArray(e)?e.map(e=>Wn(e,t)||Un.easeOut):Un[e]}function Gn(e,t,n,{delay:r=0,duration:i=300,repeat:a=0,repeatType:o=`loop`,ease:s=`easeOut`,times:c}={},l=void 0){let u={[t]:n};c&&(u.offset=c);let d=Wn(s,i);Array.isArray(d)&&(u.easing=d),O.value&&Oe.waapi++;let f={delay:r,duration:i,easing:Array.isArray(d)?`linear`:d,fill:`both`,iterations:a+1,direction:o===`reverse`?`alternate`:`normal`};l&&(f.pseudoElement=l);let p=e.animate(u,f);return O.value&&p.finished.finally(()=>{Oe.waapi--}),p}function Kn(e){return typeof e==`function`&&`applyToOptions`in e}function qn({type:e,...t}){return Kn(e)&&Vn()?e.applyToOptions(t):(t.duration??=300,t.ease??=`easeOut`,t)}var Jn=class extends cn{constructor(e){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!e)return;let{element:t,name:n,keyframes:r,pseudoElement:i,allowFlatten:a=!1,finalKeyframe:o,onComplete:s}=e;this.isPseudoElement=!!i,this.allowFlatten=a,this.options=e,e.type;let c=qn(e);this.animation=Gn(t,n,r,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){let e=an(r,this.options,o,this.speed);this.updateMotionValue&&this.updateMotionValue(e),Ln(t,n,e),this.animation.cancel()}s?.(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state===`finished`&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;let{state:e}=this;e===`idle`||e===`finished`||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){let e=this.options?.element;!this.isPseudoElement&&e?.isConnected&&this.animation.commitStyles?.()}get duration(){let e=this.animation.effect?.getComputedTiming?.().duration||0;return T(Number(e))}get iterationDuration(){let{delay:e=0}=this.options||{};return this.duration+T(e)}get time(){return T(Number(this.animation.currentTime)||0)}set time(e){let t=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=w(e),t&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(e){e<0&&(this.finishedTime=null),this.animation.playbackRate=e}get state(){return this.finishedTime===null?this.animation.playState:`finished`}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(e){this.manualStartTime=this.animation.startTime=e}attachTimeline({timeline:e,rangeStart:t,rangeEnd:n,observe:r}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:`linear`}),this.animation.onfinish=null,e&&Bn()?(this.animation.timeline=e,t&&(this.animation.rangeStart=t),n&&(this.animation.rangeEnd=n),y):r(this)}},Yn={anticipate:le,backInOut:ce,circInOut:fe};function Xn(e){return e in Yn}function Zn(e){typeof e.ease==`string`&&Xn(e.ease)&&(e.ease=Yn[e.ease])}var Qn=10,$n=class extends Jn{constructor(e){Zn(e),sn(e),super(e),e.startTime!==void 0&&e.autoplay!==!1&&(this.startTime=e.startTime),this.options=e}updateMotionValue(e){let{motionValue:t,onUpdate:n,onComplete:r,element:i,...a}=this.options;if(!t)return;if(e!==void 0){t.set(e);return}let o=new un({...a,autoplay:!1}),s=Math.max(Qn,M.now()-this.startTime),c=p(0,Qn,s-Qn),l=o.sample(s).value,{name:u}=this.options;i&&u&&Ln(i,u,l),t.setWithVelocity(o.sample(Math.max(0,s-c)).value,l,c),o.stop()}},er=(e,t)=>t===`zIndex`?!1:!!(typeof e==`number`||Array.isArray(e)||typeof e==`string`&&(L.test(e)||e===`0`)&&!e.startsWith(`url(`));function tr(e){let t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function nr(e,t,n,r){let i=e[0];if(i===null)return!1;if(t===`display`||t===`visibility`)return!0;let a=e[e.length-1],o=er(i,t),s=er(a,t);return`${t}${i}${a}${o?a:i}`,!o||!s?!1:tr(e)||(n===`spring`||Kn(n))&&r}function rr(e){e.duration=0,e.type=`keyframes`}var ir=new Set([`opacity`,`clipPath`,`filter`,`transform`]),ar=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function or(e){for(let t=0;t<e.length;t++)if(typeof e[t]==`string`&&ar.test(e[t]))return!0;return!1}var sr=new Set([`color`,`backgroundColor`,`outlineColor`,`fill`,`stroke`,`borderColor`,`borderTopColor`,`borderRightColor`,`borderBottomColor`,`borderLeftColor`]),cr=v(()=>Object.hasOwnProperty.call(Element.prototype,`animate`));function lr(e){let{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:a,type:o,keyframes:s}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;let{onUpdate:c,transformTemplate:l}=t.owner.getProps();return cr()&&n&&(ir.has(n)||sr.has(n)&&or(s))&&(n!==`transform`||!l)&&!c&&!r&&i!==`mirror`&&a!==0&&o!==`inertia`}var ur=40,dr=class extends cn{constructor({autoplay:e=!0,delay:t=0,type:n=`keyframes`,repeat:r=0,repeatDelay:i=0,repeatType:a=`loop`,keyframes:o,name:s,motionValue:c,element:l,...u}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=M.now();let d={autoplay:e,delay:t,type:n,repeat:r,repeatDelay:i,repeatType:a,name:s,motionValue:c,element:l,...u};this.keyframeResolver=new(l?.KeyframeResolver||Fn)(o,(e,t,n)=>this.onKeyframesResolved(e,t,d,!n),s,c,l),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(e,t,n,r){this.keyframeResolver=void 0;let{name:i,type:a,velocity:o,delay:s,isHandoff:c,onUpdate:l}=n;this.resolvedAt=M.now();let u=!0;nr(e,i,a,o)||(u=!1,(m.instantAnimations||!s)&&l?.(an(e,n,t)),e[0]=e[e.length-1],rr(n),n.repeat=0);let d={startTime:r?this.resolvedAt&&this.resolvedAt-this.createdAt>ur?this.resolvedAt:this.createdAt:void 0,finalKeyframe:t,...n,keyframes:e},f=u&&!c&&lr(d),p=d.motionValue?.owner?.current,h;if(f)try{h=new $n({...d,element:p})}catch{h=new un(d)}else h=new un(d);h.finished.then(()=>{this.notifyFinished()}).catch(y),this.pendingTimeline&&=(this.stopTimeline=h.attachTimeline(this.pendingTimeline),void 0),this._animation=h}get finished(){return this._animation?this.animation.finished:this._finished}then(e,t){return this.finished.finally(e).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Pn()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(e){this.animation.time=e}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(e){this.animation.speed=e}get startTime(){return this.animation.startTime}attachTimeline(e){return this._animation?this.stopTimeline=this.animation.attachTimeline(e):this.pendingTimeline=e,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}};function fr(e,t,n,r=0,i=1){let a=Array.from(e).sort((e,t)=>e.sortNodePosition(t)).indexOf(t),o=e.size,s=(o-1)*r;return typeof n==`function`?n(a,o):i===1?a*r:s-a*r}var pr=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function mr(e){let t=pr.exec(e);if(!t)return[,];let[,n,r,i]=t;return[`--${n??r}`,i]}function hr(e,t,n=1){`${e}`;let[r,i]=mr(e);if(!r)return;let a=window.getComputedStyle(t).getPropertyValue(r);if(a){let e=a.trim();return h(e)?parseFloat(e):e}return Me(i)?hr(i,t,n+1):i}var gr={type:`spring`,stiffness:500,damping:25,restSpeed:10},_r=e=>({type:`spring`,stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),vr={type:`keyframes`,duration:.8},yr={type:`keyframes`,ease:[.25,.1,.35,1],duration:.3},br=(e,{keyframes:t})=>t.length>2?vr:wn.has(e)?e.startsWith(`scale`)?_r(t[1]):gr:yr;function xr(e,t){if(e?.inherit&&t){let{inherit:n,...r}=e;return{...t,...r}}return e}function Sr(e,t){let n=e?.[t]??e?.default??e;return n===e?n:xr(n,e)}var Cr=new Set([`when`,`delay`,`delayChildren`,`staggerChildren`,`staggerDirection`,`repeat`,`repeatType`,`repeatDelay`,`from`,`elapsed`]);function wr(e){for(let t in e)if(!Cr.has(t))return!0;return!1}var Tr=(e,t,n,r={},i,a)=>o=>{let s=Sr(r,e)||{},c=s.delay||r.delay||0,{elapsed:l=0}=r;l-=w(c);let u={keyframes:Array.isArray(n)?n:[null,n],ease:`easeOut`,velocity:t.getVelocity(),...s,delay:-l,onUpdate:e=>{t.set(e),s.onUpdate&&s.onUpdate(e)},onComplete:()=>{o(),s.onComplete&&s.onComplete()},name:e,motionValue:t,element:a?void 0:i};wr(s)||Object.assign(u,br(e,u)),u.duration&&=w(u.duration),u.repeatDelay&&=w(u.repeatDelay),u.from!==void 0&&(u.keyframes[0]=u.from);let d=!1;if((u.type===!1||u.duration===0&&!u.repeatDelay)&&(rr(u),u.delay===0&&(d=!0)),(m.instantAnimations||m.skipAnimations||i?.shouldSkipAnimations)&&(d=!0,rr(u),u.delay=0),u.allowFlatten=!s.type&&!s.ease,d&&!a&&t.get()!==void 0){let e=an(u.keyframes,s);if(e!==void 0){k.update(()=>{u.onUpdate(e),u.onComplete()});return}}return s.isSync?new un(u):new dr(u)};function Er(e){let t=[{},{}];return e?.values.forEach((e,n)=>{t[0][n]=e.get(),t[1][n]=e.getVelocity()}),t}function Dr(e,t,n,r){if(typeof t==`function`){let[i,a]=Er(r);t=t(n===void 0?e.custom:n,i,a)}if(typeof t==`string`&&(t=e.variants&&e.variants[t]),typeof t==`function`){let[i,a]=Er(r);t=t(n===void 0?e.custom:n,i,a)}return t}function U(e,t,n){let r=e.getProps();return Dr(r,t,n===void 0?r.custom:n,e)}var Or=new Set([`width`,`height`,`top`,`left`,`right`,`bottom`,...Cn]),kr=30,Ar=e=>!isNaN(parseFloat(e)),jr={current:void 0},Mr=class{constructor(e,t={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=e=>{let t=M.now();if(this.updatedAt!==t&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(let e of this.dependents)e.dirty()},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){this.current=e,this.updatedAt=M.now(),this.canTrackVelocity===null&&e!==void 0&&(this.canTrackVelocity=Ar(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on(`change`,e)}on(e,t){this.events[e]||(this.events[e]=new C);let n=this.events[e].add(t);return e===`change`?()=>{n(),k.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e){this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e)}setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(e){this.dependents||=new Set,this.dependents.add(e)}removeDependent(e){this.dependents&&this.dependents.delete(e)}get(){return jr.current&&jr.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let e=M.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||e-this.updatedAt>kr)return 0;let t=Math.min(this.updatedAt-this.prevUpdatedAt,kr);return E(parseFloat(this.current)-parseFloat(this.prevFrameValue),t)}start(e){return this.stop(),new Promise(t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function W(e,t){return new Mr(e,t)}var Nr=e=>Array.isArray(e);function Pr(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,W(n))}function Fr(e){return Nr(e)?e[e.length-1]||0:e}function Ir(e,t){let{transitionEnd:n={},transition:r={},...i}=U(e,t)||{};i={...i,...n};for(let t in i)Pr(e,t,Fr(i[t]))}var G=e=>!!(e&&e.getVelocity);function Lr(e){return!!(G(e)&&e.add)}function Rr(e,t){let n=e.getValue(`willChange`);if(Lr(n))return n.add(t);if(!n&&m.WillChange){let n=new m.WillChange(`auto`);e.addValue(`willChange`,n),n.add(t)}}function zr(e){return e.replace(/([A-Z])/g,e=>`-${e.toLowerCase()}`)}var Br=`data-`+zr(`framerAppearId`);function Vr(e){return e.props[Br]}function Hr({protectedKeys:e,needsAnimating:t},n){let r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function Ur(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:a,transitionEnd:o,...s}=t,c=e.getDefaultTransition();a=a?xr(a,c):c;let l=a?.reduceMotion;r&&(a=r);let u=[],d=i&&e.animationState&&e.animationState.getState()[i];for(let t in s){let r=e.getValue(t,e.latestValues[t]??null),i=s[t];if(i===void 0||d&&Hr(d,t))continue;let o={delay:n,...Sr(a||{},t)},c=r.get();if(c!==void 0&&!r.isAnimating()&&!Array.isArray(i)&&i===c&&!o.velocity){k.update(()=>r.set(i));continue}let f=!1;if(window.MotionHandoffAnimation){let n=Vr(e);if(n){let e=window.MotionHandoffAnimation(n,t,k);e!==null&&(o.startTime=e,f=!0)}}Rr(e,t);let p=l??e.shouldReduceMotion;r.start(Tr(t,r,i,p&&Or.has(t)?{type:!1}:o,e,f));let m=r.animation;m&&u.push(m)}if(o){let t=()=>k.update(()=>{o&&Ir(e,o)});u.length?Promise.all(u).then(t):t()}return u}function Wr(e,t,n={}){let r=U(e,t,n.type===`exit`?e.presenceContext?.custom:void 0),{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);let a=r?()=>Promise.all(Ur(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(r=0)=>{let{delayChildren:a=0,staggerChildren:o,staggerDirection:s}=i;return Gr(e,t,r,a,o,s,n)}:()=>Promise.resolve(),{when:s}=i;if(s){let[e,t]=s===`beforeChildren`?[a,o]:[o,a];return e().then(()=>t())}else return Promise.all([a(),o(n.delay)])}function Gr(e,t,n=0,r=0,i=0,a=1,o){let s=[];for(let c of e.variantChildren)c.notify(`AnimationStart`,t),s.push(Wr(c,t,{...o,delay:n+(typeof r==`function`?0:r)+fr(e.variantChildren,c,r,i,a)}).then(()=>c.notify(`AnimationComplete`,t)));return Promise.all(s)}function Kr(e,t,n={}){e.notify(`AnimationStart`,t);let r;if(Array.isArray(t)){let i=t.map(t=>Wr(e,t,n));r=Promise.all(i)}else if(typeof t==`string`)r=Wr(e,t,n);else{let i=typeof t==`function`?U(e,t,n.custom):t;r=Promise.all(Ur(e,i,n))}return r.then(()=>{e.notify(`AnimationComplete`,t)})}var qr={test:e=>e===`auto`,parse:e=>e},Jr=e=>t=>t.test(e),Yr=[Fe,F,P,N,Ze,Xe,qr],Xr=e=>Yr.find(Jr(e));function Zr(e){return typeof e==`number`?e===0:e===null?!0:e===`none`||e===`0`||_(e)}var Qr=new Set([`brightness`,`contrast`,`saturate`,`opacity`]);function $r(e){let[t,n]=e.slice(0,-1).split(`(`);if(t===`drop-shadow`)return e;let[r]=n.match(ze)||[];if(!r)return e;let i=n.replace(r,``),a=Qr.has(t)?1:0;return r!==n&&(a*=100),t+`(`+a+i+`)`}var ei=/\b([a-z-]*)\(.*?\)/gu,ti={...L,getAnimatableNone:e=>{let t=e.match(ei);return t?t.map($r).join(` `):e}},ni={...L,getAnimatableNone:e=>{let t=L.parse(e);return L.createTransformer(e)(t.map(e=>typeof e==`number`?0:typeof e==`object`?{...e,alpha:1}:e))}},ri={...Fe,transform:Math.round},ii={borderWidth:F,borderTopWidth:F,borderRightWidth:F,borderBottomWidth:F,borderLeftWidth:F,borderRadius:F,borderTopLeftRadius:F,borderTopRightRadius:F,borderBottomRightRadius:F,borderBottomLeftRadius:F,width:F,maxWidth:F,height:F,maxHeight:F,top:F,right:F,bottom:F,left:F,inset:F,insetBlock:F,insetBlockStart:F,insetBlockEnd:F,insetInline:F,insetInlineStart:F,insetInlineEnd:F,padding:F,paddingTop:F,paddingRight:F,paddingBottom:F,paddingLeft:F,paddingBlock:F,paddingBlockStart:F,paddingBlockEnd:F,paddingInline:F,paddingInlineStart:F,paddingInlineEnd:F,margin:F,marginTop:F,marginRight:F,marginBottom:F,marginLeft:F,marginBlock:F,marginBlockStart:F,marginBlockEnd:F,marginInline:F,marginInlineStart:F,marginInlineEnd:F,fontSize:F,backgroundPositionX:F,backgroundPositionY:F,rotate:N,rotateX:N,rotateY:N,rotateZ:N,scale:Le,scaleX:Le,scaleY:Le,scaleZ:Le,skew:N,skewX:N,skewY:N,distance:F,translateX:F,translateY:F,translateZ:F,x:F,y:F,z:F,perspective:F,transformPerspective:F,opacity:Ie,originX:Qe,originY:Qe,originZ:F,zIndex:ri,fillOpacity:Ie,strokeOpacity:Ie,numOctaves:ri},ai={...ii,color:I,backgroundColor:I,outlineColor:I,fill:I,stroke:I,borderColor:I,borderTopColor:I,borderRightColor:I,borderBottomColor:I,borderLeftColor:I,filter:ti,WebkitFilter:ti,mask:ni,WebkitMask:ni},oi=e=>ai[e],si=new Set([ti,ni]);function ci(e,t){let n=oi(e);return si.has(n)||(n=L),n.getAnimatableNone?n.getAnimatableNone(t):void 0}var li=new Set([`auto`,`none`,`0`]);function ui(e,t,n){let r=0,i;for(;r<e.length&&!i;){let t=e[r];typeof t==`string`&&!li.has(t)&&ct(t).values.length&&(i=e[r]),r++}if(i&&n)for(let r of t)e[r]=ci(n,i)}var di=class extends Fn{constructor(e,t,n,r,i){super(e,t,n,r,i,!0)}readKeyframes(){let{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let n=0;n<e.length;n++){let r=e[n];if(typeof r==`string`&&(r=r.trim(),Me(r))){let i=hr(r,t.current);i!==void 0&&(e[n]=i),n===e.length-1&&(this.finalKeyframe=r)}}if(this.resolveNoneKeyframes(),!Or.has(n)||e.length!==2)return;let[r,i]=e,a=Xr(r),o=Xr(i);if(Pe(r)!==Pe(i)&&V[n]){this.needsMeasurement=!0;return}if(a!==o)if(Tn(a)&&Tn(o))for(let t=0;t<e.length;t++){let n=e[t];typeof n==`string`&&(e[t]=parseFloat(n))}else V[n]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){let{unresolvedKeyframes:e,name:t}=this,n=[];for(let t=0;t<e.length;t++)(e[t]===null||Zr(e[t]))&&n.push(t);n.length&&ui(e,n,t)}measureInitialState(){let{element:e,unresolvedKeyframes:t,name:n}=this;if(!e||!e.current)return;n===`height`&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=V[n](e.measureViewportBox(),window.getComputedStyle(e.current)),t[0]=this.measuredOrigin;let r=t[t.length-1];r!==void 0&&e.getValue(n,r).jump(r,!1)}measureEndState(){let{element:e,name:t,unresolvedKeyframes:n}=this;if(!e||!e.current)return;let r=e.getValue(t);r&&r.jump(this.measuredOrigin,!1);let i=n.length-1,a=n[i];n[i]=V[t](e.measureViewportBox(),window.getComputedStyle(e.current)),a!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=a),this.removedTransforms?.length&&this.removedTransforms.forEach(([t,n])=>{e.getValue(t).set(n)}),this.resolveNoneKeyframes()}};function fi(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e==`string`){let r=document;t&&(r=t.current);let i=n?.[e]??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e).filter(e=>e!=null)}var pi=(e,t)=>t&&typeof e==`number`?t.transform(e):e;function mi(e){return g(e)&&`offsetHeight`in e&&!(`ownerSVGElement`in e)}var{schedule:hi,cancel:gi}=we(queueMicrotask,!1),K={x:!1,y:!1};function _i(){return K.x||K.y}function vi(e){return e===`x`||e===`y`?K[e]?null:(K[e]=!0,()=>{K[e]=!1}):K.x||K.y?null:(K.x=K.y=!0,()=>{K.x=K.y=!1})}function yi(e,t){let n=fi(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},()=>r.abort()]}function bi(e){return!(e.pointerType===`touch`||_i())}function xi(e,t,n={}){let[r,i,a]=yi(e,n);return r.forEach(e=>{let n=!1,r=!1,a,o=()=>{e.removeEventListener(`pointerleave`,u)},s=e=>{a&&=(a(e),void 0),o()},c=e=>{n=!1,window.removeEventListener(`pointerup`,c),window.removeEventListener(`pointercancel`,c),r&&(r=!1,s(e))},l=()=>{n=!0,window.addEventListener(`pointerup`,c,i),window.addEventListener(`pointercancel`,c,i)},u=e=>{if(e.pointerType!==`touch`){if(n){r=!0;return}s(e)}};e.addEventListener(`pointerenter`,n=>{if(!bi(n))return;r=!1;let o=t(e,n);typeof o==`function`&&(a=o,e.addEventListener(`pointerleave`,u,i))},i),e.addEventListener(`pointerdown`,l,i)}),a}var Si=(e,t)=>t?e===t?!0:Si(e,t.parentElement):!1,Ci=e=>e.pointerType===`mouse`?typeof e.button!=`number`||e.button<=0:e.isPrimary!==!1,wi=new Set([`BUTTON`,`INPUT`,`SELECT`,`TEXTAREA`,`A`]);function Ti(e){return wi.has(e.tagName)||e.isContentEditable===!0}var Ei=new Set([`INPUT`,`SELECT`,`TEXTAREA`]);function Di(e){return Ei.has(e.tagName)||e.isContentEditable===!0}var Oi=new WeakSet;function ki(e){return t=>{t.key===`Enter`&&e(t)}}function Ai(e,t){e.dispatchEvent(new PointerEvent(`pointer`+t,{isPrimary:!0,bubbles:!0}))}var ji=(e,t)=>{let n=e.currentTarget;if(!n)return;let r=ki(()=>{if(Oi.has(n))return;Ai(n,`down`);let e=ki(()=>{Ai(n,`up`)});n.addEventListener(`keyup`,e,t),n.addEventListener(`blur`,()=>Ai(n,`cancel`),t)});n.addEventListener(`keydown`,r,t),n.addEventListener(`blur`,()=>n.removeEventListener(`keydown`,r),t)};function Mi(e){return Ci(e)&&!_i()}var Ni=new WeakSet;function Pi(e,t,n={}){let[r,i,a]=yi(e,n),o=e=>{let r=e.currentTarget;if(!Mi(e)||Ni.has(e))return;Oi.add(r),n.stopPropagation&&Ni.add(e);let a=t(r,e),o=(e,t)=>{window.removeEventListener(`pointerup`,s),window.removeEventListener(`pointercancel`,c),Oi.has(r)&&Oi.delete(r),Mi(e)&&typeof a==`function`&&a(e,{success:t})},s=e=>{o(e,r===window||r===document||n.useGlobalTarget||Si(r,e.target))},c=e=>{o(e,!1)};window.addEventListener(`pointerup`,s,i),window.addEventListener(`pointercancel`,c,i)};return r.forEach(e=>{(n.useGlobalTarget?window:e).addEventListener(`pointerdown`,o,i),mi(e)&&(e.addEventListener(`focus`,e=>ji(e,i)),!Ti(e)&&!e.hasAttribute(`tabindex`)&&(e.tabIndex=0))}),a}function Fi(e){return g(e)&&`ownerSVGElement`in e}var Ii=new WeakMap,Li,Ri=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+`Size`]:Fi(r)&&`getBBox`in r?r.getBBox()[t]:r[n],zi=Ri(`inline`,`width`,`offsetWidth`),Bi=Ri(`block`,`height`,`offsetHeight`);function Vi({target:e,borderBoxSize:t}){Ii.get(e)?.forEach(n=>{n(e,{get width(){return zi(e,t)},get height(){return Bi(e,t)}})})}function Hi(e){e.forEach(Vi)}function Ui(){typeof ResizeObserver>`u`||(Li=new ResizeObserver(Hi))}function Wi(e,t){Li||Ui();let n=fi(e);return n.forEach(e=>{let n=Ii.get(e);n||(n=new Set,Ii.set(e,n)),n.add(t),Li?.observe(e)}),()=>{n.forEach(e=>{let n=Ii.get(e);n?.delete(t),n?.size||Li?.unobserve(e)})}}var Gi=new Set,Ki;function qi(){Ki=()=>{let e={get width(){return window.innerWidth},get height(){return window.innerHeight}};Gi.forEach(t=>t(e))},window.addEventListener(`resize`,Ki)}function Ji(e){return Gi.add(e),Ki||qi(),()=>{Gi.delete(e),!Gi.size&&typeof Ki==`function`&&(window.removeEventListener(`resize`,Ki),Ki=void 0)}}function Yi(e,t){return typeof e==`function`?Ji(e):Wi(e,t)}function Xi(e){return Fi(e)&&e.tagName===`svg`}var Zi=[...Yr,I,L],Qi=e=>Zi.find(Jr(e)),$i=()=>({translate:0,scale:1,origin:0,originPoint:0}),ea=()=>({x:$i(),y:$i()}),ta=()=>({min:0,max:0}),q=()=>({x:ta(),y:ta()}),na=new WeakMap;function ra(e){return typeof e==`object`&&!!e&&typeof e.start==`function`}function ia(e){return typeof e==`string`||Array.isArray(e)}var aa=[`animate`,`whileInView`,`whileFocus`,`whileHover`,`whileTap`,`whileDrag`,`exit`],oa=[`initial`,...aa];function sa(e){return ra(e.animate)||oa.some(t=>ia(e[t]))}function ca(e){return!!(sa(e)||e.variants)}function la(e,t,n){for(let r in t){let i=t[r],a=n[r];if(G(i))e.addValue(r,i);else if(G(a))e.addValue(r,W(i,{owner:e}));else if(a!==i)if(e.hasValue(r)){let t=e.getValue(r);t.liveStyle===!0?t.jump(i):t.hasAnimated||t.set(i)}else{let t=e.getStaticValue(r);e.addValue(r,W(t===void 0?i:t,{owner:e}))}}for(let r in n)t[r]===void 0&&e.removeValue(r);return t}var ua={current:null},da={current:!1},fa=typeof window<`u`;function pa(){if(da.current=!0,fa)if(window.matchMedia){let e=window.matchMedia(`(prefers-reduced-motion)`),t=()=>ua.current=e.matches;e.addEventListener(`change`,t),t()}else ua.current=!1}var ma=[`AnimationStart`,`AnimationComplete`,`Update`,`BeforeLayoutMeasure`,`LayoutMeasure`,`LayoutAnimationStart`,`LayoutAnimationComplete`],ha={};function ga(e){ha=e}function _a(){return ha}var va=class{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,skipAnimations:i,blockInitialAnimation:a,visualState:o},s={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=Fn,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify(`Update`,this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let e=M.now();this.renderScheduledAt<e&&(this.renderScheduledAt=e,k.render(this.render,!1,!0))};let{latestValues:c,renderState:l}=o;this.latestValues=c,this.baseTarget={...c},this.initialValues=t.initial?{...c}:{},this.renderState=l,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=r,this.skipAnimationsConfig=i,this.options=s,this.blockInitialAnimation=!!a,this.isControllingVariants=sa(t),this.isVariantNode=ca(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);let{willChange:u,...d}=this.scrapeMotionValuesFromProps(t,{},this);for(let e in d){let t=d[e];c[e]!==void 0&&G(t)&&t.set(c[e])}}mount(e){if(this.hasBeenMounted)for(let e in this.initialValues)this.values.get(e)?.jump(this.initialValues[e]),this.latestValues[e]=this.initialValues[e];this.current=e,na.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((e,t)=>this.bindToMotionValue(t,e)),this.reducedMotionConfig===`never`?this.shouldReduceMotion=!1:this.reducedMotionConfig===`always`?this.shouldReduceMotion=!0:(da.current||pa(),this.shouldReduceMotion=ua.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,this.parent?.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){this.projection&&this.projection.unmount(),A(this.notifyUpdate),A(this.render),this.valueSubscriptions.forEach(e=>e()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(let e in this.events)this.events[e].clear();for(let e in this.features){let t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}addChild(e){this.children.add(e),this.enteringChildren??=new Set,this.enteringChildren.add(e)}removeChild(e){this.children.delete(e),this.enteringChildren&&this.enteringChildren.delete(e)}bindToMotionValue(e,t){if(this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)(),t.accelerate&&ir.has(e)&&this.current instanceof HTMLElement){let{factory:n,keyframes:r,times:i,ease:a,duration:o}=t.accelerate,s=new Jn({element:this.current,name:e,keyframes:r,times:i,ease:a,duration:w(o)}),c=n(s);this.valueSubscriptions.set(e,()=>{c(),s.cancel()});return}let n=wn.has(e);n&&this.onBindTransform&&this.onBindTransform();let r=t.on(`change`,t=>{this.latestValues[e]=t,this.props.onUpdate&&k.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()}),i;typeof window<`u`&&window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,()=>{r(),i&&i(),t.owner&&t.stop()})}sortNodePosition(e){return!this.current||!this.sortInstanceNodePosition||this.type!==e.type?0:this.sortInstanceNodePosition(this.current,e.current)}updateFeatures(){let e=`animation`;for(e in ha){let t=ha[e];if(!t)continue;let{isEnabled:n,Feature:r}=t;if(!this.features[e]&&r&&n(this.props)&&(this.features[e]=new r(this)),this.features[e]){let t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):q()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;t<ma.length;t++){let n=ma[t];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);let r=e[`on`+n];r&&(this.propEventSubscriptions[n]=this.on(n,r))}this.prevMotionValues=la(this,this.scrapeMotionValuesFromProps(e,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(e){let t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){let n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);let t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return n===void 0&&t!==void 0&&(n=W(t===null?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){let n=this.latestValues[e]!==void 0||!this.current?this.latestValues[e]:this.getBaseTargetFromProps(this.props,e)??this.readValueFromInstance(this.current,e,this.options);return n!=null&&(typeof n==`string`&&(h(n)||_(n))?n=parseFloat(n):!Qi(n)&&L.test(t)&&(n=ci(e,t)),this.setBaseTarget(e,G(n)?n.get():n)),G(n)?n.get():n}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){let{initial:t}=this.props,n;if(typeof t==`string`||typeof t==`object`){let r=Dr(this.props,t,this.presenceContext?.custom);r&&(n=r[e])}if(t&&n!==void 0)return n;let r=this.getBaseTargetFromProps(this.props,e);return r!==void 0&&!G(r)?r:this.initialValues[e]!==void 0&&n===void 0?void 0:this.baseTarget[e]}on(e,t){return this.events[e]||(this.events[e]=new C),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}scheduleRenderMicrotask(){hi.render(this.render)}},ya=class extends va{constructor(){super(...arguments),this.KeyframeResolver=di}sortInstanceNodePosition(e,t){return e.compareDocumentPosition(t)&2?1:-1}getBaseTargetFromProps(e,t){let n=e.style;return n?n[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;G(e)&&(this.childSubscription=e.on(`change`,e=>{this.current&&(this.current.textContent=`${e}`)}))}},J=class{constructor(e){this.isMounted=!1,this.node=e}update(){}};function ba({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function xa({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function Sa(e,t){if(!t)return e;let n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Ca(e){return e===void 0||e===1}function wa({scale:e,scaleX:t,scaleY:n}){return!Ca(e)||!Ca(t)||!Ca(n)}function Y(e){return wa(e)||Ta(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Ta(e){return Ea(e.x)||Ea(e.y)}function Ea(e){return e&&e!==`0%`}function Da(e,t,n){return n+t*(e-n)}function Oa(e,t,n,r,i){return i!==void 0&&(e=Da(e,i,r)),Da(e,n,r)+t}function ka(e,t=0,n=1,r,i){e.min=Oa(e.min,t,n,r,i),e.max=Oa(e.max,t,n,r,i)}function Aa(e,{x:t,y:n}){ka(e.x,t.translate,t.scale,t.originPoint),ka(e.y,n.translate,n.scale,n.originPoint)}var ja=.999999999999,Ma=1.0000000000001;function Na(e,t,n,r=!1){let i=n.length;if(!i)return;t.x=t.y=1;let a,o;for(let s=0;s<i;s++){a=n[s],o=a.projectionDelta;let{visualElement:i}=a.options;i&&i.props.style&&i.props.style.display===`contents`||(r&&a.options.layoutScroll&&a.scroll&&a!==a.root&&(X(e.x,-a.scroll.offset.x),X(e.y,-a.scroll.offset.y)),o&&(t.x*=o.x.scale,t.y*=o.y.scale,Aa(e,o)),r&&Y(a.latestValues)&&Ia(e,a.latestValues,a.layout?.layoutBox))}t.x<Ma&&t.x>ja&&(t.x=1),t.y<Ma&&t.y>ja&&(t.y=1)}function X(e,t){e.min+=t,e.max+=t}function Pa(e,t,n,r,i=.5){ka(e,t,n,R(e.min,e.max,i),r)}function Fa(e,t){return typeof e==`string`?parseFloat(e)/100*(t.max-t.min):e}function Ia(e,t,n){let r=n??e;Pa(e.x,Fa(t.x,r.x),t.scaleX,t.scale,t.originX),Pa(e.y,Fa(t.y,r.y),t.scaleY,t.scale,t.originY)}function La(e,t){return ba(Sa(e.getBoundingClientRect(),t))}function Ra(e,t,n){let r=La(e,n),{scroll:i}=t;return i&&(X(r.x,i.offset.x),X(r.y,i.offset.y)),r}var za={x:`translateX`,y:`translateY`,z:`translateZ`,transformPerspective:`perspective`},Ba=Cn.length;function Va(e,t,n){let r=``,i=!0;for(let a=0;a<Ba;a++){let o=Cn[a],s=e[o];if(s===void 0)continue;let c=!0;if(typeof s==`number`)c=s===(o.startsWith(`scale`)?1:0);else{let e=parseFloat(s);c=o.startsWith(`scale`)?e===1:e===0}if(!c||n){let e=pi(s,ii[o]);if(!c){i=!1;let t=za[o]||o;r+=`${t}(${e}) `}n&&(t[o]=e)}}return r=r.trim(),n?r=n(t,i?``:r):i&&(r=`none`),r}function Ha(e,t,n){let{style:r,vars:i,transformOrigin:a}=e,o=!1,s=!1;for(let e in t){let n=t[e];if(wn.has(e)){o=!0;continue}else if(Ae(e)){i[e]=n;continue}else{let t=pi(n,ii[e]);e.startsWith(`origin`)?(s=!0,a[e]=t):r[e]=t}}if(t.transform||(o||n?r.transform=Va(t,e.transform,n):r.transform&&=`none`),s){let{originX:e=`50%`,originY:t=`50%`,originZ:n=0}=a;r.transformOrigin=`${e} ${t} ${n}`}}function Ua(e,{style:t,vars:n},r,i){let a=e.style,o;for(o in t)a[o]=t[o];for(o in i?.applyProjectionStyles(a,r),n)a.setProperty(o,n[o])}function Wa(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var Ga={correct:(e,t)=>{if(!t.target)return e;if(typeof e==`string`)if(F.test(e))e=parseFloat(e);else return e;return`${Wa(e,t.target.x)}% ${Wa(e,t.target.y)}%`}},Ka={correct:(e,{treeScale:t,projectionDelta:n})=>{let r=e,i=L.parse(e);if(i.length>5)return r;let a=L.createTransformer(e),o=typeof i[0]==`number`?0:1,s=n.x.scale*t.x,c=n.y.scale*t.y;i[0+o]/=s,i[1+o]/=c;let l=R(s,c,.5);return typeof i[2+o]==`number`&&(i[2+o]/=l),typeof i[3+o]==`number`&&(i[3+o]/=l),a(i)}},qa={borderRadius:{...Ga,applyTo:[`borderTopLeftRadius`,`borderTopRightRadius`,`borderBottomLeftRadius`,`borderBottomRightRadius`]},borderTopLeftRadius:Ga,borderTopRightRadius:Ga,borderBottomLeftRadius:Ga,borderBottomRightRadius:Ga,boxShadow:Ka};function Ja(e,{layout:t,layoutId:n}){return wn.has(e)||e.startsWith(`origin`)||(t||n!==void 0)&&(!!qa[e]||e===`opacity`)}function Ya(e,t,n){let r=e.style,i=t?.style,a={};if(!r)return a;for(let t in r)(G(r[t])||i&&G(i[t])||Ja(t,e)||n?.getValue(t)?.liveStyle!==void 0)&&(a[t]=r[t]);return a}function Xa(e){return window.getComputedStyle(e)}var Za=class extends ya{constructor(){super(...arguments),this.type=`html`,this.renderInstance=Ua}readValueFromInstance(e,t){if(wn.has(t))return this.projection?.isProjecting?yn(t):xn(e,t);{let n=Xa(e),r=(Ae(t)?n.getPropertyValue(t):n[t])||0;return typeof r==`string`?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return La(e,t)}build(e,t,n){Ha(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return Ya(e,t,n)}},Qa={offset:`stroke-dashoffset`,array:`stroke-dasharray`},$a={offset:`strokeDashoffset`,array:`strokeDasharray`};function eo(e,t,n=1,r=0,i=!0){e.pathLength=1;let a=i?Qa:$a;e[a.offset]=`${-r}`,e[a.array]=`${t} ${n}`}var to=[`offsetDistance`,`offsetPath`,`offsetRotate`,`offsetAnchor`];function no(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:a=1,pathOffset:o=0,...s},c,l,u){if(Ha(e,s,l),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:d,style:f}=e;d.transform&&(f.transform=d.transform,delete d.transform),(f.transform||d.transformOrigin)&&(f.transformOrigin=d.transformOrigin??`50% 50%`,delete d.transformOrigin),f.transform&&(f.transformBox=u?.transformBox??`fill-box`,delete d.transformBox);for(let e of to)d[e]!==void 0&&(f[e]=d[e],delete d[e]);t!==void 0&&(d.x=t),n!==void 0&&(d.y=n),r!==void 0&&(d.scale=r),i!==void 0&&eo(d,i,a,o,!1)}var ro=new Set([`baseFrequency`,`diffuseConstant`,`kernelMatrix`,`kernelUnitLength`,`keySplines`,`keyTimes`,`limitingConeAngle`,`markerHeight`,`markerWidth`,`numOctaves`,`targetX`,`targetY`,`surfaceScale`,`specularConstant`,`specularExponent`,`stdDeviation`,`tableValues`,`viewBox`,`gradientTransform`,`pathLength`,`startOffset`,`textLength`,`lengthAdjust`]),io=e=>typeof e==`string`&&e.toLowerCase()===`svg`;function ao(e,t,n,r){Ua(e,t,void 0,r);for(let n in t.attrs)e.setAttribute(ro.has(n)?n:zr(n),t.attrs[n])}function oo(e,t,n){let r=Ya(e,t,n);for(let n in e)if(G(e[n])||G(t[n])){let t=Cn.indexOf(n)===-1?n:`attr`+n.charAt(0).toUpperCase()+n.substring(1);r[t]=e[n]}return r}var so=class extends ya{constructor(){super(...arguments),this.type=`svg`,this.isSVGTag=!1,this.measureInstanceViewportBox=q}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(wn.has(t)){let e=oi(t);return e&&e.default||0}return t=ro.has(t)?t:zr(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return oo(e,t,n)}build(e,t,n){no(e,t,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(e,t,n,r){ao(e,t,n,r)}mount(e){this.isSVGTag=io(e.tagName),super.mount(e)}},co=oa.length;function lo(e){if(!e)return;if(!e.isControllingVariants){let t=e.parent&&lo(e.parent)||{};return e.props.initial!==void 0&&(t.initial=e.props.initial),t}let t={};for(let n=0;n<co;n++){let r=oa[n],i=e.props[r];(ia(i)||i===!1)&&(t[r]=i)}return t}function uo(e,t){if(!Array.isArray(t))return!1;let n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}var fo=[...aa].reverse(),po=aa.length;function mo(e){return t=>Promise.all(t.map(({animation:t,options:n})=>Kr(e,t,n)))}function ho(e){let t=mo(e),n=vo(),r=!0,i=!1,a=t=>(n,r)=>{let i=U(e,r,t===`exit`?e.presenceContext?.custom:void 0);if(i){let{transition:e,transitionEnd:t,...r}=i;n={...n,...r,...t}}return n};function o(n){t=n(e)}function s(o){let{props:s}=e,c=lo(e.parent)||{},l=[],u=new Set,d={},f=1/0;for(let t=0;t<po;t++){let p=fo[t],m=n[p],h=s[p]===void 0?c[p]:s[p],g=ia(h),_=p===o?m.isActive:null;_===!1&&(f=t);let v=h===c[p]&&h!==s[p]&&g;if(v&&(r||i)&&e.manuallyAnimateOnMount&&(v=!1),m.protectedKeys={...d},!m.isActive&&_===null||!h&&!m.prevProp||ra(h)||typeof h==`boolean`)continue;if(p===`exit`&&m.isActive&&_!==!0){m.prevResolvedValues&&(d={...d,...m.prevResolvedValues});continue}let y=go(m.prevProp,h),b=y||p===o&&m.isActive&&!v&&g||t>f&&g,x=!1,S=Array.isArray(h)?h:[h],C=S.reduce(a(p),{});_===!1&&(C={});let{prevResolvedValues:w={}}=m,T={...w,...C},E=t=>{b=!0,u.has(t)&&(x=!0,u.delete(t)),m.needsAnimating[t]=!0;let n=e.getValue(t);n&&(n.liveStyle=!1)};for(let e in T){let t=C[e],n=w[e];if(d.hasOwnProperty(e))continue;let r=!1;r=Nr(t)&&Nr(n)?!uo(t,n):t!==n,r?t==null?u.add(e):E(e):t!==void 0&&u.has(e)?E(e):m.protectedKeys[e]=!0}m.prevProp=h,m.prevResolvedValues=C,m.isActive&&(d={...d,...C}),(r||i)&&e.blockInitialAnimation&&(b=!1);let D=v&&y;b&&(!D||x)&&l.push(...S.map(t=>{let n={type:p};if(typeof t==`string`&&(r||i)&&!D&&e.manuallyAnimateOnMount&&e.parent){let{parent:r}=e,i=U(r,t);if(r.enteringChildren&&i){let{delayChildren:t}=i.transition||{};n.delay=fr(r.enteringChildren,e,t)}}return{animation:t,options:n}}))}if(u.size){let t={};if(typeof s.initial!=`boolean`){let n=U(e,Array.isArray(s.initial)?s.initial[0]:s.initial);n&&n.transition&&(t.transition=n.transition)}u.forEach(n=>{let r=e.getBaseTarget(n),i=e.getValue(n);i&&(i.liveStyle=!0),t[n]=r??null}),l.push({animation:t})}let p=!!l.length;return r&&(s.initial===!1||s.initial===s.animate)&&!e.manuallyAnimateOnMount&&(p=!1),r=!1,i=!1,p?t(l):Promise.resolve()}function c(t,r){if(n[t].isActive===r)return Promise.resolve();e.variantChildren?.forEach(e=>e.animationState?.setActive(t,r)),n[t].isActive=r;let i=s(t);for(let e in n)n[e].protectedKeys={};return i}return{animateChanges:s,setActive:c,setAnimateFunction:o,getState:()=>n,reset:()=>{n=vo(),i=!0}}}function go(e,t){return typeof t==`string`?t!==e:Array.isArray(t)?!uo(t,e):!1}function _o(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function vo(){return{animate:_o(!0),whileInView:_o(),whileHover:_o(),whileTap:_o(),whileDrag:_o(),whileFocus:_o(),exit:_o()}}function yo(e,t){e.min=t.min,e.max=t.max}function Z(e,t){yo(e.x,t.x),yo(e.y,t.y)}function bo(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}var xo=1e-4,So=1-xo,Co=1+xo,wo=.01,To=0-wo,Eo=0+wo;function Q(e){return e.max-e.min}function Do(e,t,n){return Math.abs(e-t)<=n}function Oo(e,t,n,r=.5){e.origin=r,e.originPoint=R(t.min,t.max,e.origin),e.scale=Q(n)/Q(t),e.translate=R(n.min,n.max,e.origin)-e.originPoint,(e.scale>=So&&e.scale<=Co||isNaN(e.scale))&&(e.scale=1),(e.translate>=To&&e.translate<=Eo||isNaN(e.translate))&&(e.translate=0)}function ko(e,t,n,r){Oo(e.x,t.x,n.x,r?r.originX:void 0),Oo(e.y,t.y,n.y,r?r.originY:void 0)}function Ao(e,t,n,r=0){e.min=(r?R(n.min,n.max,r):n.min)+t.min,e.max=e.min+Q(t)}function jo(e,t,n,r){Ao(e.x,t.x,n.x,r?.x),Ao(e.y,t.y,n.y,r?.y)}function Mo(e,t,n,r=0){let i=r?R(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+Q(t)}function No(e,t,n,r){Mo(e.x,t.x,n.x,r?.x),Mo(e.y,t.y,n.y,r?.y)}function Po(e,t,n,r,i){return e-=t,e=Da(e,1/n,r),i!==void 0&&(e=Da(e,1/i,r)),e}function Fo(e,t=0,n=1,r=.5,i,a=e,o=e){if(P.test(t)&&(t=parseFloat(t),t=R(o.min,o.max,t/100)-o.min),typeof t!=`number`)return;let s=R(a.min,a.max,r);e===a&&(s-=t),e.min=Po(e.min,t,n,s,i),e.max=Po(e.max,t,n,s,i)}function Io(e,t,[n,r,i],a,o){Fo(e,t[n],t[r],t[i],t.scale,a,o)}var Lo=[`x`,`scaleX`,`originX`],Ro=[`y`,`scaleY`,`originY`];function zo(e,t,n,r){Io(e.x,t,Lo,n?n.x:void 0,r?r.x:void 0),Io(e.y,t,Ro,n?n.y:void 0,r?r.y:void 0)}function Bo(e){return e.translate===0&&e.scale===1}function Vo(e){return Bo(e.x)&&Bo(e.y)}function Ho(e,t){return e.min===t.min&&e.max===t.max}function Uo(e,t){return Ho(e.x,t.x)&&Ho(e.y,t.y)}function Wo(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Go(e,t){return Wo(e.x,t.x)&&Wo(e.y,t.y)}function Ko(e){return Q(e.x)/Q(e.y)}function qo(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function $(e){return[e(`x`),e(`y`)]}function Jo(e,t,n){let r=``,i=e.x.translate/t.x,a=e.y.translate/t.y,o=n?.z||0;if((i||a||o)&&(r=`translate3d(${i}px, ${a}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){let{transformPerspective:e,rotate:t,rotateX:i,rotateY:a,skewX:o,skewY:s}=n;e&&(r=`perspective(${e}px) ${r}`),t&&(r+=`rotate(${t}deg) `),i&&(r+=`rotateX(${i}deg) `),a&&(r+=`rotateY(${a}deg) `),o&&(r+=`skewX(${o}deg) `),s&&(r+=`skewY(${s}deg) `)}let s=e.x.scale*t.x,c=e.y.scale*t.y;return(s!==1||c!==1)&&(r+=`scale(${s}, ${c})`),r||`none`}var Yo=[`borderTopLeftRadius`,`borderTopRightRadius`,`borderBottomLeftRadius`,`borderBottomRightRadius`],Xo=Yo.length,Zo=e=>typeof e==`string`?parseFloat(e):e,Qo=e=>typeof e==`number`||F.test(e);function $o(e,t,n,r,i,a){i?(e.opacity=R(0,n.opacity??1,ts(r)),e.opacityExit=R(t.opacity??1,0,ns(r))):a&&(e.opacity=R(t.opacity??1,n.opacity??1,r));for(let i=0;i<Xo;i++){let a=Yo[i],o=es(t,a),s=es(n,a);o===void 0&&s===void 0||(o||=0,s||=0,o===0||s===0||Qo(o)===Qo(s)?(e[a]=Math.max(R(Zo(o),Zo(s),r),0),(P.test(s)||P.test(o))&&(e[a]+=`%`)):e[a]=s)}(t.rotate||n.rotate)&&(e.rotate=R(t.rotate||0,n.rotate||0,r))}function es(e,t){return e[t]===void 0?e.borderRadius:e[t]}var ts=rs(0,.5,de),ns=rs(.5,.95,y);function rs(e,t,n){return r=>r<e?0:r>t?1:n(S(e,t,r))}function is(e,t,n){let r=G(e)?e:W(e);return r.start(Tr(``,r,t,n)),r.animation}function as(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}var os=(e,t)=>e.depth-t.depth,ss=class{constructor(){this.children=[],this.isDirty=!1}add(e){d(this.children,e),this.isDirty=!0}remove(e){f(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(os),this.isDirty=!1,this.children.forEach(e)}};function cs(e,t){let n=M.now(),r=({timestamp:i})=>{let a=i-n;a>=t&&(A(r),e(a-t))};return k.setup(r,!0),()=>A(r)}function ls(e){return G(e)?e.get():e}var us=class{constructor(){this.members=[]}add(e){d(this.members,e);for(let t=this.members.length-1;t>=0;t--){let n=this.members[t];if(n===e||n===this.lead||n===this.prevLead)continue;let r=n.instance;(!r||r.isConnected===!1)&&!n.snapshot&&(f(this.members,n),n.unmount())}e.scheduleRender()}remove(e){if(f(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){for(let t=this.members.indexOf(e)-1;t>=0;t--){let e=this.members[t];if(e.isPresent!==!1&&e.instance?.isConnected!==!1)return this.promote(e),!0}return!1}promote(e,t){let n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.updateSnapshot(),e.scheduleRender();let{layoutDependency:r}=n.options,{layoutDependency:i}=e.options;(r===void 0||r!==i)&&(e.resumeFrom=n,t&&(n.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root?.isUpdating&&(e.isLayoutDirty=!0)),e.options.crossfade===!1&&n.hide()}}exitAnimationComplete(){this.members.forEach(e=>{e.options.onExitComplete?.(),e.resumingFrom?.options.onExitComplete?.()})}scheduleRender(){this.members.forEach(e=>e.instance&&e.scheduleRender(!1))}removeLeadSnapshot(){this.lead?.snapshot&&(this.lead.snapshot=void 0)}},ds={hasAnimatedSinceResize:!0,hasEverUpdated:!1},fs={nodes:0,calculatedTargetDeltas:0,calculatedProjections:0},ps=[``,`X`,`Y`,`Z`],ms=1e3,hs=0;function gs(e,t,n,r){let{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function _s(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let n=Vr(t);if(window.MotionHasOptimisedAnimation(n,`transform`)){let{layout:t,layoutId:r}=e.options;window.MotionCancelOptimisedAnimation(n,`transform`,k,!(t||r))}let{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&_s(r)}function vs({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(e={},n=t?.()){this.id=hs++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,O.value&&(fs.nodes=fs.calculatedTargetDeltas=fs.calculatedProjections=0),this.nodes.forEach(xs),this.nodes.forEach(As),this.nodes.forEach(js),this.nodes.forEach(Ss),O.addProjectionMetrics&&O.addProjectionMetrics(fs)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new ss)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new C),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){let n=this.eventHandlers.get(e);n&&n.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t){if(this.instance)return;this.isSVG=Fi(t)&&!Xi(t),this.instance=t;let{layoutId:n,layout:r,visualElement:i}=this.options;if(i&&!i.current&&i.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(r||n)&&(this.isLayoutDirty=!0),e){let n,r=0,i=()=>this.root.updateBlockedByResize=!1;k.read(()=>{r=window.innerWidth}),e(t,()=>{let e=window.innerWidth;e!==r&&(r=e,this.root.updateBlockedByResize=!0,n&&n(),n=cs(i,250),ds.hasAnimatedSinceResize&&(ds.hasAnimatedSinceResize=!1,this.nodes.forEach(ks)))})}n&&this.root.registerSharedNode(n,this),this.options.animate!==!1&&i&&(n||r)&&this.addEventListener(`didUpdate`,({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let a=this.options.transition||i.getDefaultTransition()||Rs,{onLayoutAnimationStart:o,onLayoutAnimationComplete:s}=i.getProps(),c=!this.targetLayout||!Go(this.targetLayout,r),l=!t&&n;if(this.options.layoutRoot||this.resumeFrom||l||t&&(c||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);let t={...Sr(a,`layout`),onPlay:o,onComplete:s};(i.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t),this.setAnimationOrigin(e,l)}else t||ks(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),A(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Ms),this.animationId++)}getTransformTemplate(){let{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&_s(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;e<this.path.length;e++){let t=this.path[e];t.shouldResetTransform=!0,(typeof t.latestValues.x==`string`||typeof t.latestValues.y==`string`)&&(t.isLayoutDirty=!0),t.updateScroll(`snapshot`),t.options.layoutRoot&&t.willUpdate(!1)}let{layoutId:t,layout:n}=this.options;if(t===void 0&&!n)return;let r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,``):void 0,this.updateSnapshot(),e&&this.notifyListeners(`willUpdate`)}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){let e=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),e&&this.nodes.forEach(Ts),this.nodes.forEach(ws);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Es);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Ds),this.nodes.forEach(Os),this.nodes.forEach(ys),this.nodes.forEach(bs)):this.nodes.forEach(Es),this.clearAllSnapshots();let e=M.now();j.delta=p(0,1e3/60,e-j.timestamp),j.timestamp=e,j.isProcessing=!0,Te.update.process(j),Te.preRender.process(j),Te.render.process(j),j.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,hi.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Cs),this.sharedNodes.forEach(Ns)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,k.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){k.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Q(this.snapshot.measuredBox.x)&&!Q(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;e<this.path.length;e++)this.path[e].updateScroll();let e=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected||=q(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners(`measure`,this.layout.layoutBox);let{visualElement:t}=this.options;t&&t.notify(`LayoutMeasure`,this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e=`measure`){let t=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t&&this.instance){let t=r(this.instance);this.scroll={animationId:this.root.animationId,phase:e,isRoot:t,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:t}}}resetTransform(){if(!i)return;let e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,t=this.projectionDelta&&!Vo(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,``):void 0,a=r!==this.prevTransformTemplateValue;e&&this.instance&&(t||Y(this.latestValues)||a)&&(i(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){let t=this.measurePageBox(),n=this.removeElementScroll(t);return e&&(n=this.removeTransform(n)),Hs(n),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){let{visualElement:e}=this.options;if(!e)return q();let t=e.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(Ws))){let{scroll:e}=this.root;e&&(X(t.x,e.offset.x),X(t.y,e.offset.y))}return t}removeElementScroll(e){let t=q();if(Z(t,e),this.scroll?.wasRoot)return t;for(let n=0;n<this.path.length;n++){let r=this.path[n],{scroll:i,options:a}=r;r!==this.root&&i&&a.layoutScroll&&(i.wasRoot&&Z(t,e),X(t.x,i.offset.x),X(t.y,i.offset.y))}return t}applyTransform(e,t=!1,n){let r=n||q();Z(r,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];!t&&n.options.layoutScroll&&n.scroll&&n!==n.root&&(X(r.x,-n.scroll.offset.x),X(r.y,-n.scroll.offset.y)),Y(n.latestValues)&&Ia(r,n.latestValues,n.layout?.layoutBox)}return Y(this.latestValues)&&Ia(r,this.latestValues,this.layout?.layoutBox),r}removeTransform(e){let t=q();Z(t,e);for(let e=0;e<this.path.length;e++){let n=this.path[e];if(!Y(n.latestValues))continue;let r;n.instance&&(wa(n.latestValues)&&n.updateSnapshot(),r=q(),Z(r,n.measurePageBox())),zo(t,n.latestValues,n.snapshot?.layoutBox,r)}return Y(this.latestValues)&&zo(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:e.crossfade===void 0?!0:e.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==j.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){let t=this.getLead();this.isProjectionDirty||=t.isProjectionDirty,this.isTransformDirty||=t.isTransformDirty,this.isSharedProjectionDirty||=t.isSharedProjectionDirty;let n=!!this.resumingFrom||this!==t;if(!(e||n&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:r,layoutId:i}=this.options;if(!this.layout||!(r||i))return;this.resolvedRelativeTargetAt=j.timestamp;let a=this.getClosestProjectingParent();a&&this.linkedParentVersion!==a.layoutVersion&&!a.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&a&&a.layout?this.createRelativeTarget(a,this.layout.layoutBox,a.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=q(),this.targetWithTransforms=q()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),jo(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):Z(this.target,this.layout.layoutBox),Aa(this.target,this.targetDelta)):Z(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&a&&!!a.resumingFrom==!!this.resumingFrom&&!a.options.layoutScroll&&a.target&&this.animationProgress!==1?this.createRelativeTarget(a,this.target,a.target):this.relativeParent=this.relativeTarget=void 0),O.value&&fs.calculatedTargetDeltas++)}getClosestProjectingParent(){if(!(!this.parent||wa(this.parent.latestValues)||Ta(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(e,t,n){this.relativeParent=e,this.linkedParentVersion=e.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=q(),this.relativeTargetOrigin=q(),No(this.relativeTargetOrigin,t,n,this.options.layoutAnchor||void 0),Z(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){let e=this.getLead(),t=!!this.resumingFrom||this!==e,n=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(n=!1),t&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(n=!1),this.resolvedRelativeTargetAt===j.timestamp&&(n=!1),n)return;let{layout:r,layoutId:i}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(r||i))return;Z(this.layoutCorrected,this.layout.layoutBox);let a=this.treeScale.x,o=this.treeScale.y;Na(this.layoutCorrected,this.treeScale,this.path,t),e.layout&&!e.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(e.target=e.layout.layoutBox,e.targetWithTransforms=q());let{target:s}=e;if(!s){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(bo(this.prevProjectionDelta.x,this.projectionDelta.x),bo(this.prevProjectionDelta.y,this.projectionDelta.y)),ko(this.projectionDelta,this.layoutCorrected,s,this.latestValues),(this.treeScale.x!==a||this.treeScale.y!==o||!qo(this.projectionDelta.x,this.prevProjectionDelta.x)||!qo(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners(`projectionUpdate`,s)),O.value&&fs.calculatedProjections++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){if(this.options.visualElement?.scheduleRender(),e){let e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ea(),this.projectionDelta=ea(),this.projectionDeltaWithTransform=ea()}setAnimationOrigin(e,t=!1){let n=this.snapshot,r=n?n.latestValues:{},i={...this.latestValues},a=ea();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;let o=q(),s=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),c=this.getStack(),l=!c||c.members.length<=1,u=!!(s&&!l&&this.options.crossfade===!0&&!this.path.some(Ls));this.animationProgress=0;let d;this.mixTargetDelta=t=>{let n=t/1e3;Ps(a.x,e.x,n),Ps(a.y,e.y,n),this.setTargetDelta(a),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(No(o,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),Is(this.relativeTarget,this.relativeTargetOrigin,o,n),d&&Uo(this.relativeTarget,d)&&(this.isProjectionDirty=!1),d||=q(),Z(d,this.relativeTarget)),s&&(this.animationValues=i,$o(i,r,this.latestValues,n,u,l)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners(`animationStart`),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&=(A(this.pendingAnimation),void 0),this.pendingAnimation=k.update(()=>{ds.hasAnimatedSinceResize=!0,Oe.layout++,this.motionValue||=W(0),this.motionValue.jump(0,!1),this.currentAnimation=is(this.motionValue,[0,1e3],{...e,velocity:0,isSync:!0,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onStop:()=>{Oe.layout--},onComplete:()=>{Oe.layout--,e.onComplete&&e.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners(`animationComplete`)}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(ms),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let e=this.getLead(),{targetWithTransforms:t,target:n,layout:r,latestValues:i}=e;if(!(!t||!n||!r)){if(this!==e&&this.layout&&r&&Us(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||q();let t=Q(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;let r=Q(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}Z(t,n),Ia(t,i),ko(this.projectionDeltaWithTransform,this.layoutCorrected,t,i)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new us),this.sharedNodes.get(e).add(t);let n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){let e=this.getStack();return e?e.lead===this:!0}getLead(){let{layoutId:e}=this.options;return e&&this.getStack()?.lead||this}getPrevLead(){let{layoutId:e}=this.options;return e?this.getStack()?.prevLead:void 0}getStack(){let{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){let r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){let e=this.getStack();return e?e.relegate(this):!1}resetSkewAndRotation(){let{visualElement:e}=this.options;if(!e)return;let t=!1,{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;let r={};n.z&&gs(`z`,e,r,this.animationValues);for(let t=0;t<ps.length;t++)gs(`rotate${ps[t]}`,e,r,this.animationValues),gs(`skew${ps[t]}`,e,r,this.animationValues);e.render();for(let t in r)e.setStaticValue(t,r[t]),this.animationValues&&(this.animationValues[t]=r[t]);e.scheduleRender()}applyProjectionStyles(e,t){if(!this.instance||this.isSVG)return;if(!this.isVisible){e.visibility=`hidden`;return}let n=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,e.visibility=``,e.opacity=``,e.pointerEvents=ls(t?.pointerEvents)||``,e.transform=n?n(this.latestValues,``):`none`;return}let r=this.getLead();if(!this.projectionDelta||!this.layout||!r.target){this.options.layoutId&&(e.opacity=this.latestValues.opacity===void 0?1:this.latestValues.opacity,e.pointerEvents=ls(t?.pointerEvents)||``),this.hasProjected&&!Y(this.latestValues)&&(e.transform=n?n({},``):`none`,this.hasProjected=!1);return}e.visibility=``;let i=r.animationValues||r.latestValues;this.applyTransformsToTarget();let a=Jo(this.projectionDeltaWithTransform,this.treeScale,i);n&&(a=n(i,a)),e.transform=a;let{x:o,y:s}=this.projectionDelta;e.transformOrigin=`${o.origin*100}% ${s.origin*100}% 0`,r.animationValues?e.opacity=r===this?i.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:i.opacityExit:e.opacity=r===this?i.opacity===void 0?``:i.opacity:i.opacityExit===void 0?0:i.opacityExit;for(let t in qa){if(i[t]===void 0)continue;let{correct:n,applyTo:o,isCSSVariable:s}=qa[t],c=a===`none`?i[t]:n(i[t],r);if(o){let t=o.length;for(let n=0;n<t;n++)e[o[n]]=c}else s?this.options.visualElement.renderState.vars[t]=c:e[t]=c}this.options.layoutId&&(e.pointerEvents=r===this?ls(t?.pointerEvents)||``:`none`)}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(e=>e.currentAnimation?.stop()),this.root.nodes.forEach(ws),this.root.sharedNodes.clear()}}}function ys(e){e.updateLayout()}function bs(e){let t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners(`didUpdate`)){let{layoutBox:n,measuredBox:r}=e.layout,{animationType:i}=e.options,a=t.source!==e.layout.source;if(i===`size`)$(e=>{let r=a?t.measuredBox[e]:t.layoutBox[e],i=Q(r);r.min=n[e].min,r.max=r.min+i});else if(i===`x`||i===`y`){let e=i===`x`?`y`:`x`;yo(a?t.measuredBox[e]:t.layoutBox[e],n[e])}else Us(i,t.layoutBox,n)&&$(r=>{let i=a?t.measuredBox[r]:t.layoutBox[r],o=Q(n[r]);i.max=i.min+o,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+o)});let o=ea();ko(o,n,t.layoutBox);let s=ea();a?ko(s,e.applyTransform(r,!0),t.measuredBox):ko(s,n,t.layoutBox);let c=!Vo(o),l=!1;if(!e.resumeFrom){let r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){let{snapshot:i,layout:a}=r;if(i&&a){let o=e.options.layoutAnchor||void 0,s=q();No(s,t.layoutBox,i.layoutBox,o);let c=q();No(c,n,a.layoutBox,o),Go(s,c)||(l=!0),r.options.layoutRoot&&(e.relativeTarget=c,e.relativeTargetOrigin=s,e.relativeParent=r)}}}e.notifyListeners(`didUpdate`,{layout:n,snapshot:t,delta:s,layoutDelta:o,hasLayoutChanged:c,hasRelativeLayoutChanged:l})}else if(e.isLead()){let{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function xs(e){O.value&&fs.nodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty),e.isTransformDirty||=e.parent.isTransformDirty)}function Ss(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Cs(e){e.clearSnapshot()}function ws(e){e.clearMeasurements()}function Ts(e){e.isLayoutDirty=!0,e.updateLayout()}function Es(e){e.isLayoutDirty=!1}function Ds(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function Os(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify(`BeforeLayoutMeasure`),e.resetTransform()}function ks(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function As(e){e.resolveTargetDelta()}function js(e){e.calcProjection()}function Ms(e){e.resetSkewAndRotation()}function Ns(e){e.removeLeadSnapshot()}function Ps(e,t,n){e.translate=R(t.translate,0,n),e.scale=R(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Fs(e,t,n,r){e.min=R(t.min,n.min,r),e.max=R(t.max,n.max,r)}function Is(e,t,n,r){Fs(e.x,t.x,n.x,r),Fs(e.y,t.y,n.y,r)}function Ls(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}var Rs={duration:.45,ease:[.4,0,.1,1]},zs=e=>typeof navigator<`u`&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Bs=zs(`applewebkit/`)&&!zs(`chrome/`)?Math.round:y;function Vs(e){e.min=Bs(e.min),e.max=Bs(e.max)}function Hs(e){Vs(e.x),Vs(e.y)}function Us(e,t,n){return e===`position`||e===`preserve-aspect`&&!Do(Ko(t),Ko(n),.2)}function Ws(e){return e!==e.root&&e.scroll?.wasRoot}var Gs=vs({attachResizeListener:(e,t)=>as(e,`resize`,t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body?.scrollLeft||0,y:document.documentElement.scrollTop||document.body?.scrollTop||0}),checkIsScrollRoot:()=>!0}),Ks={current:void 0},qs=vs({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Ks.current){let e=new Gs({});e.mount(window),e.setOptions({layoutScroll:!0}),Ks.current=e}return Ks.current},resetTransform:(e,t)=>{e.style.transform=t===void 0?`none`:t},checkIsScrollRoot:e=>window.getComputedStyle(e).position===`fixed`}),Js=(0,o.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:`never`});function Ys(e=!0){let t=(0,o.useContext)(u);if(t===null)return[!0,null];let{isPresent:n,onExitComplete:r,register:i}=t,a=(0,o.useId)();(0,o.useEffect)(()=>{if(e)return i(a)},[e]);let s=(0,o.useCallback)(()=>e&&r&&r(a),[a,r,e]);return!n&&r?[!1,s]:[!0]}var Xs=(0,o.createContext)({strict:!1}),Zs={animation:[`animate`,`variants`,`whileHover`,`whileTap`,`exit`,`whileInView`,`whileFocus`,`whileDrag`],exit:[`exit`],drag:[`drag`,`dragControls`],focus:[`whileFocus`],hover:[`whileHover`,`onHoverStart`,`onHoverEnd`],tap:[`whileTap`,`onTap`,`onTapStart`,`onTapCancel`],pan:[`onPan`,`onPanStart`,`onPanSessionStart`,`onPanEnd`],inView:[`whileInView`,`onViewportEnter`,`onViewportLeave`],layout:[`layout`,`layoutId`]},Qs=!1;function $s(){if(Qs)return;let e={};for(let t in Zs)e[t]={isEnabled:e=>Zs[t].some(t=>!!e[t])};ga(e),Qs=!0}function ec(){return $s(),_a()}function tc(e){let t=ec();for(let n in e)t[n]={...t[n],...e[n]};ga(t)}var nc=new Set(`animate.exit.variants.initial.style.values.variants.transition.transformTemplate.custom.inherit.onBeforeLayoutMeasure.onAnimationStart.onAnimationComplete.onUpdate.onDragStart.onDrag.onDragEnd.onMeasureDragConstraints.onDirectionLock.onDragTransitionEnd._dragX._dragY.onHoverStart.onHoverEnd.onViewportEnter.onViewportLeave.globalTapTarget.propagate.ignoreStrict.viewport`.split(`.`));function rc(e){return e.startsWith(`while`)||e.startsWith(`drag`)&&e!==`draggable`||e.startsWith(`layout`)||e.startsWith(`onTap`)||e.startsWith(`onPan`)||e.startsWith(`onLayout`)||nc.has(e)}var ic=n({default:()=>ac}),ac,oc=i((()=>{throw ac={},Error(`Could not resolve "@emotion/is-prop-valid" imported by "framer-motion". Is it installed?`)})),sc=e=>!rc(e);function cc(e){typeof e==`function`&&(sc=t=>t.startsWith(`on`)?!rc(t):e(t))}try{cc((oc(),r(ic)).default)}catch{}function lc(e,t,n){let r={};for(let i in e)i===`values`&&typeof e.values==`object`||G(e[i])||(sc(i)||n===!0&&rc(i)||!t&&!rc(i)||e.draggable&&i.startsWith(`onDrag`))&&(r[i]=e[i]);return r}var uc=(0,o.createContext)({});function dc(e,t){if(sa(e)){let{initial:t,animate:n}=e;return{initial:t===!1||ia(t)?t:void 0,animate:ia(n)?n:void 0}}return e.inherit===!1?{}:t}function fc(e){let{initial:t,animate:n}=dc(e,(0,o.useContext)(uc));return(0,o.useMemo)(()=>({initial:t,animate:n}),[pc(t),pc(n)])}function pc(e){return Array.isArray(e)?e.join(` `):e}var mc=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function hc(e,t,n){for(let r in t)!G(t[r])&&!Ja(r,n)&&(e[r]=t[r])}function gc({transformTemplate:e},t){return(0,o.useMemo)(()=>{let n=mc();return Ha(n,t,e),Object.assign({},n.vars,n.style)},[t])}function _c(e,t){let n=e.style||{},r={};return hc(r,n,e),Object.assign(r,gc(e,t)),r}function vc(e,t){let n={},r=_c(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout=`none`,r.touchAction=e.drag===!0?`none`:`pan-${e.drag===`x`?`y`:`x`}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}var yc=()=>({...mc(),attrs:{}});function bc(e,t,n,r){let i=(0,o.useMemo)(()=>{let n=yc();return no(n,t,io(r),e.transformTemplate,e.style),{...n.attrs,style:{...n.style}}},[t]);if(e.style){let t={};hc(t,e.style,e),i.style={...t,...i.style}}return i}var xc=[`animate`,`circle`,`defs`,`desc`,`ellipse`,`g`,`image`,`line`,`filter`,`marker`,`mask`,`metadata`,`path`,`pattern`,`polygon`,`polyline`,`rect`,`stop`,`switch`,`symbol`,`svg`,`text`,`tspan`,`use`,`view`];function Sc(e){return typeof e!=`string`||e.includes(`-`)?!1:!!(xc.indexOf(e)>-1||/[A-Z]/u.test(e))}function Cc(e,t,n,{latestValues:r},i,a=!1,s){let c=(s??Sc(e)?bc:vc)(t,r,i,e),l=lc(t,typeof e==`string`,a),u=e===o.Fragment?{}:{...l,...c,ref:n},{children:d}=t,f=(0,o.useMemo)(()=>G(d)?d.get():d,[d]);return(0,o.createElement)(e,{...u,children:f})}function wc({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:Tc(n,r,i,e),renderState:t()}}function Tc(e,t,n,r){let i={},a=r(e,{});for(let e in a)i[e]=ls(a[e]);let{initial:o,animate:s}=e,c=sa(e),l=ca(e);t&&l&&!c&&e.inherit!==!1&&(o===void 0&&(o=t.initial),s===void 0&&(s=t.animate));let u=n?n.initial===!1:!1;u||=o===!1;let d=u?s:o;if(d&&typeof d!=`boolean`&&!ra(d)){let t=Array.isArray(d)?d:[d];for(let n=0;n<t.length;n++){let r=Dr(e,t[n]);if(r){let{transitionEnd:e,transition:t,...n}=r;for(let e in n){let t=n[e];if(Array.isArray(t)){let e=u?t.length-1:0;t=t[e]}t!==null&&(i[e]=t)}for(let t in e)i[t]=e[t]}}}return i}var Ec=e=>(t,n)=>{let r=(0,o.useContext)(uc),i=(0,o.useContext)(u),a=()=>wc(e,t,r,i);return n?a():c(a)},Dc=Ec({scrapeMotionValuesFromProps:Ya,createRenderState:mc}),Oc=Ec({scrapeMotionValuesFromProps:oo,createRenderState:yc}),kc=Symbol.for(`motionComponentSymbol`);function Ac(e,t,n){let r=(0,o.useRef)(n);(0,o.useInsertionEffect)(()=>{r.current=n});let i=(0,o.useRef)(null);return(0,o.useCallback)(n=>{n&&e.onMount?.(n);let a=r.current;if(typeof a==`function`)if(n){let e=a(n);typeof e==`function`&&(i.current=e)}else i.current?(i.current(),i.current=null):a(n);else a&&(a.current=n);t&&(n?t.mount(n):t.unmount())},[t])}var jc=(0,o.createContext)({});function Mc(e){return e&&typeof e==`object`&&Object.prototype.hasOwnProperty.call(e,`current`)}function Nc(e,t,n,r,i,a){let{visualElement:s}=(0,o.useContext)(uc),c=(0,o.useContext)(Xs),d=(0,o.useContext)(u),f=(0,o.useContext)(Js),p=f.reducedMotion,m=f.skipAnimations,h=(0,o.useRef)(null),g=(0,o.useRef)(!1);r||=c.renderer,!h.current&&r&&(h.current=r(e,{visualState:t,parent:s,props:n,presenceContext:d,blockInitialAnimation:d?d.initial===!1:!1,reducedMotionConfig:p,skipAnimations:m,isSVG:a}),g.current&&h.current&&(h.current.manuallyAnimateOnMount=!0));let _=h.current,v=(0,o.useContext)(jc);_&&!_.projection&&i&&(_.type===`html`||_.type===`svg`)&&Pc(h.current,n,i,v);let y=(0,o.useRef)(!1);(0,o.useInsertionEffect)(()=>{_&&y.current&&_.update(n,d)});let b=n[Br],x=(0,o.useRef)(!!b&&typeof window<`u`&&!window.MotionHandoffIsComplete?.(b)&&window.MotionHasOptimisedAnimation?.(b));return l(()=>{g.current=!0,_&&(y.current=!0,window.MotionIsMounted=!0,_.updateFeatures(),_.scheduleRenderMicrotask(),x.current&&_.animationState&&_.animationState.animateChanges())}),(0,o.useEffect)(()=>{_&&(!x.current&&_.animationState&&_.animationState.animateChanges(),x.current&&=(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(b)}),!1),_.enteringChildren=void 0)}),_}function Pc(e,t,n,r){let{layoutId:i,layout:a,drag:o,dragConstraints:s,layoutScroll:c,layoutRoot:l,layoutAnchor:u,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t[`data-framer-portal-id`]?void 0:Fc(e.parent)),e.projection.setOptions({layoutId:i,layout:a,alwaysMeasureLayout:!!o||s&&Mc(s),visualElement:e,animationType:typeof a==`string`?a:`both`,initialPromotionConfig:r,crossfade:d,layoutScroll:c,layoutRoot:l,layoutAnchor:u})}function Fc(e){if(e)return e.options.allowProjection===!1?Fc(e.parent):e.projection}var Ic=e();function Lc(e,{forwardMotionProps:t=!1,type:n}={},r,i){r&&tc(r);let a=n?n===`svg`:Sc(e),s=a?Oc:Dc;function c(n,c){let l,u={...(0,o.useContext)(Js),...n,layoutId:Rc(n)},{isStatic:d}=u,f=fc(n),p=s(n,d);if(!d&&typeof window<`u`){zc(u,r);let t=Bc(u);l=t.MeasureLayout,f.visualElement=Nc(e,p,u,i,t.ProjectionNode,a)}return(0,Ic.jsxs)(uc.Provider,{value:f,children:[l&&f.visualElement?(0,Ic.jsx)(l,{visualElement:f.visualElement,...u}):null,Cc(e,n,Ac(p,f.visualElement,c),p,d,t,a)]})}c.displayName=`motion.${typeof e==`string`?e:`create(${e.displayName??e.name??``})`}`;let l=(0,o.forwardRef)(c);return l[kc]=e,l}function Rc({layoutId:e}){let t=(0,o.useContext)(s).id;return t&&e!==void 0?t+`-`+e:e}function zc(e,t){(0,o.useContext)(Xs).strict}function Bc(e){let{drag:t,layout:n}=ec();if(!t&&!n)return{};let r={...t,...n};return{MeasureLayout:t?.isEnabled(e)||n?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function Vc(e,t){if(typeof Proxy>`u`)return Lc;let n=new Map,r=(n,r)=>Lc(n,r,e,t);return new Proxy((e,t)=>r(e,t),{get:(i,a)=>a===`create`?r:(n.has(a)||n.set(a,Lc(a,void 0,e,t)),n.get(a))})}var Hc=(e,t)=>t.isSVG??Sc(e)?new so(t):new Za(t,{allowProjection:e!==o.Fragment}),Uc=class extends J{constructor(e){super(e),e.animationState||=ho(e)}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();ra(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}},Wc=0,Gc={animation:{Feature:Uc},exit:{Feature:class extends J{constructor(){super(...arguments),this.id=Wc++,this.isExitComplete=!1}update(){if(!this.node.presenceContext)return;let{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;if(e&&n===!1){if(this.isExitComplete){let{initial:e,custom:t}=this.node.getProps();if(typeof e==`string`){let n=U(this.node,e,t);if(n){let{transition:e,transitionEnd:t,...r}=n;for(let e in r)this.node.getValue(e)?.jump(r[e])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive(`exit`,!1);this.isExitComplete=!1;return}let r=this.node.animationState.setActive(`exit`,!e);t&&!e&&r.then(()=>{this.isExitComplete=!0,t(this.id)})}mount(){let{register:e,onExitComplete:t}=this.node.presenceContext||{};t&&t(this.id),e&&(this.unmount=e(this.id))}unmount(){}}}};function Kc(e){return{point:{x:e.pageX,y:e.pageY}}}var qc=e=>t=>Ci(t)&&e(t,Kc(t));function Jc(e,t,n,r){return as(e,t,qc(n),r)}var Yc=({current:e})=>e?e.ownerDocument.defaultView:null,Xc=(e,t)=>Math.abs(e-t);function Zc(e,t){let n=Xc(e.x,t.x),r=Xc(e.y,t.y);return Math.sqrt(n**2+r**2)}var Qc=new Set([`auto`,`scroll`]),$c=class{constructor(e,t,{transformPagePoint:n,contextWindow:r=window,dragSnapToOrigin:i=!1,distanceThreshold:a=3,element:o}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=e=>{this.handleScroll(e.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=el(this.lastRawMoveEventInfo,this.transformPagePoint));let e=nl(this.lastMoveEventInfo,this.history),t=this.startEvent!==null,n=Zc(e.offset,{x:0,y:0})>=this.distanceThreshold;if(!t&&!n)return;let{point:r}=e,{timestamp:i}=j;this.history.push({...r,timestamp:i});let{onStart:a,onMove:o}=this.handlers;t||(a&&a(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),o&&o(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastRawMoveEventInfo=t,this.lastMoveEventInfo=el(t,this.transformPagePoint),k.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();let{onEnd:n,onSessionEnd:r,resumeAnimation:i}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&i&&i(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let a=nl(e.type===`pointercancel`?this.lastMoveEventInfo:el(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,a),r&&r(e,a)},!Ci(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.distanceThreshold=a,this.contextWindow=r||window;let s=el(Kc(e),this.transformPagePoint),{point:c}=s,{timestamp:l}=j;this.history=[{...c,timestamp:l}];let{onSessionStart:u}=t;u&&u(e,nl(s,this.history)),this.removeListeners=x(Jc(this.contextWindow,`pointermove`,this.handlePointerMove),Jc(this.contextWindow,`pointerup`,this.handlePointerUp),Jc(this.contextWindow,`pointercancel`,this.handlePointerUp)),o&&this.startScrollTracking(o)}startScrollTracking(e){let t=e.parentElement;for(;t;){let e=getComputedStyle(t);(Qc.has(e.overflowX)||Qc.has(e.overflowY))&&this.scrollPositions.set(t,{x:t.scrollLeft,y:t.scrollTop}),t=t.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener(`scroll`,this.onElementScroll,{capture:!0}),window.addEventListener(`scroll`,this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener(`scroll`,this.onElementScroll,{capture:!0}),window.removeEventListener(`scroll`,this.onWindowScroll)}}handleScroll(e){let t=this.scrollPositions.get(e);if(!t)return;let n=e===window,r=n?{x:window.scrollX,y:window.scrollY}:{x:e.scrollLeft,y:e.scrollTop},i={x:r.x-t.x,y:r.y-t.y};i.x===0&&i.y===0||(n?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(e,r),k.update(this.updatePoint,!0))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),A(this.updatePoint)}};function el(e,t){return t?{point:t(e.point)}:e}function tl(e,t){return{x:e.x-t.x,y:e.y-t.y}}function nl({point:e},t){return{point:e,delta:tl(e,il(t)),offset:tl(e,rl(t)),velocity:al(t,.1)}}function rl(e){return e[0]}function il(e){return e[e.length-1]}function al(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=il(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>w(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>w(t)*2&&(r=e[1]);let a=T(i.timestamp-r.timestamp);if(a===0)return{x:0,y:0};let o={x:(i.x-r.x)/a,y:(i.y-r.y)/a};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function ol(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?R(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?R(n,e,r.max):Math.min(e,n)),e}function sl(e,t,n){return{min:t===void 0?void 0:e.min+t,max:n===void 0?void 0:e.max+n-(e.max-e.min)}}function cl(e,{top:t,left:n,bottom:r,right:i}){return{x:sl(e.x,n,i),y:sl(e.y,t,r)}}function ll(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function ul(e,t){return{x:ll(e.x,t.x),y:ll(e.y,t.y)}}function dl(e,t){let n=.5,r=Q(e),i=Q(t);return i>r?n=S(t.min,t.max-r,e.min):r>i&&(n=S(e.min,e.max-i,t.min)),p(0,1,n)}function fl(e,t){let n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}var pl=.35;function ml(e=pl){return e===!1?e=0:e===!0&&(e=pl),{x:hl(e,`left`,`right`),y:hl(e,`top`,`bottom`)}}function hl(e,t,n){return{min:gl(e,t),max:gl(e,n)}}function gl(e,t){return typeof e==`number`?e:e[t]||0}var _l=new WeakMap,vl=class{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=q(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e}start(e,{snapToCursor:t=!1,distanceThreshold:n}={}){let{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;let i=e=>{t&&this.snapToCursor(Kc(e).point),this.stopAnimation()},a=(e,t)=>{let{drag:n,dragPropagation:r,onDragStart:i}=this.getProps();if(n&&!r&&(this.openDragLock&&this.openDragLock(),this.openDragLock=vi(n),!this.openDragLock))return;this.latestPointerEvent=e,this.latestPanInfo=t,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),$(e=>{let t=this.getAxisMotionValue(e).get()||0;if(P.test(t)){let{projection:n}=this.visualElement;if(n&&n.layout){let r=n.layout.layoutBox[e];r&&(t=Q(r)*(parseFloat(t)/100))}}this.originPoint[e]=t}),i&&k.update(()=>i(e,t),!1,!0),Rr(this.visualElement,`transform`);let{animationState:a}=this.visualElement;a&&a.setActive(`whileDrag`,!0)},o=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t;let{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:a}=this.getProps();if(!n&&!this.openDragLock)return;let{offset:o}=t;if(r&&this.currentDirection===null){this.currentDirection=Sl(o),this.currentDirection!==null&&i&&i(this.currentDirection);return}this.updateAxis(`x`,t.point,o),this.updateAxis(`y`,t.point,o),this.visualElement.render(),a&&k.update(()=>a(e,t),!1,!0)},s=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t,this.stop(e,t),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>{let{dragSnapToOrigin:e}=this.getProps();(e||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:l}=this.getProps();this.panSession=new $c(e,{onSessionStart:i,onStart:a,onMove:o,onSessionEnd:s,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:l,distanceThreshold:n,contextWindow:Yc(this.visualElement),element:this.visualElement.current})}stop(e,t){let n=e||this.latestPointerEvent,r=t||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!r||!n)return;let{velocity:a}=r;this.startAnimation(a);let{onDragEnd:o}=this.getProps();o&&k.postRender(()=>o(n,r))}cancel(){this.isDragging=!1;let{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.endPanSession();let{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive(`whileDrag`,!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(e,t,n){let{drag:r}=this.getProps();if(!n||!xl(e,r,this.currentDirection))return;let i=this.getAxisMotionValue(e),a=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(a=ol(a,this.constraints[e],this.elastic[e])),i.set(a)}resolveConstraints(){let{dragConstraints:e,dragElastic:t}=this.getProps(),n=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,r=this.constraints;e&&Mc(e)?this.constraints||=this.resolveRefConstraints():e&&n?this.constraints=cl(n.layoutBox,e):this.constraints=!1,this.elastic=ml(t),r!==this.constraints&&!Mc(e)&&n&&this.constraints&&!this.hasMutatedConstraints&&$(e=>{this.constraints!==!1&&this.getAxisMotionValue(e)&&(this.constraints[e]=fl(n.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){let{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!e||!Mc(e))return!1;let n=e.current,{projection:r}=this.visualElement;if(!r||!r.layout)return!1;let i=Ra(n,r.root,this.visualElement.getTransformPagePoint()),a=ul(r.layout.layoutBox,i);if(t){let e=t(xa(a));this.hasMutatedConstraints=!!e,e&&(a=ba(e))}return a}startAnimation(e){let{drag:t,dragMomentum:n,dragElastic:r,dragTransition:i,dragSnapToOrigin:a,onDragTransitionEnd:o}=this.getProps(),s=this.constraints||{},c=$(o=>{if(!xl(o,t,this.currentDirection))return;let c=s&&s[o]||{};(a===!0||a===o)&&(c={min:0,max:0});let l=r?200:1e6,u=r?40:1e7,d={type:`inertia`,velocity:n?e[o]:0,bounceStiffness:l,bounceDamping:u,timeConstant:750,restDelta:1,restSpeed:10,...i,...c};return this.startAxisValueAnimation(o,d)});return Promise.all(c).then(o)}startAxisValueAnimation(e,t){let n=this.getAxisMotionValue(e);return Rr(this.visualElement,e),n.start(Tr(e,n,0,t,this.visualElement,!1))}stopAnimation(){$(e=>this.getAxisMotionValue(e).stop())}getAxisMotionValue(e){let t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps();return n[t]||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){$(t=>{let{drag:n}=this.getProps();if(!xl(t,n,this.currentDirection))return;let{projection:r}=this.visualElement,i=this.getAxisMotionValue(t);if(r&&r.layout){let{min:n,max:a}=r.layout.layoutBox[t],o=i.get()||0;i.set(e[t]-R(n,a,.5)+o)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!Mc(t)||!n||!this.constraints)return;this.stopAnimation();let r={x:0,y:0};$(e=>{let t=this.getAxisMotionValue(e);if(t&&this.constraints!==!1){let n=t.get();r[e]=dl({min:n,max:n},this.constraints[e])}});let{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},``):`none`,n.root&&n.root.updateScroll(),n.updateLayout(),this.constraints=!1,this.resolveConstraints(),$(t=>{if(!xl(t,e,null))return;let n=this.getAxisMotionValue(t),{min:i,max:a}=this.constraints[t];n.set(R(i,a,r[t]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;_l.set(this.visualElement,this);let e=this.visualElement.current,t=Jc(e,`pointerdown`,t=>{let{drag:n,dragListener:r=!0}=this.getProps(),i=t.target,a=i!==e&&Di(i);n&&r&&!a&&this.start(t)}),n,r=()=>{let{dragConstraints:t}=this.getProps();Mc(t)&&t.current&&(this.constraints=this.resolveRefConstraints(),n||=bl(e,t.current,()=>this.scalePositionWithinConstraints()))},{projection:i}=this.visualElement,a=i.addEventListener(`measure`,r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),k.read(r);let o=as(window,`resize`,()=>this.scalePositionWithinConstraints()),s=i.addEventListener(`didUpdate`,(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&($(t=>{let n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))}),this.visualElement.render())}));return()=>{o(),t(),a(),s&&s(),n&&n()}}getProps(){let e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:a=pl,dragMomentum:o=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:i,dragElastic:a,dragMomentum:o}}};function yl(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function bl(e,t,n){let r=Yi(e,yl(n)),i=Yi(t,yl(n));return()=>{r(),i()}}function xl(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function Sl(e,t=10){let n=null;return Math.abs(e.y)>t?n=`y`:Math.abs(e.x)>t&&(n=`x`),n}var Cl=class extends J{constructor(e){super(e),this.removeGroupControls=y,this.removeListeners=y,this.controls=new vl(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||y}update(){let{dragControls:e}=this.node.getProps(),{dragControls:t}=this.node.prevProps||{};e!==t&&(this.removeGroupControls(),e&&(this.removeGroupControls=e.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}},wl=e=>(t,n)=>{e&&k.update(()=>e(t,n),!1,!0)},Tl=class extends J{constructor(){super(...arguments),this.removePointerDownListener=y}onPointerDown(e){this.session=new $c(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Yc(this.node)})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:wl(e),onStart:wl(t),onMove:wl(n),onEnd:(e,t)=>{delete this.session,r&&k.postRender(()=>r(e,t))}}}mount(){this.removePointerDownListener=Jc(this.node.current,`pointerdown`,e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}},El=!1,Dl=class extends o.Component{componentDidMount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=e;i&&(t.group&&t.group.add(i),n&&n.register&&r&&n.register(i),El&&i.root.didUpdate(),i.addEventListener(`animationComplete`,()=>{this.safeToRemove()}),i.setOptions({...i.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),ds.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:t,visualElement:n,drag:r,isPresent:i}=this.props,{projection:a}=n;return a?(a.isPresent=i,e.layoutDependency!==t&&a.setOptions({...a.options,layoutDependency:t}),El=!0,r||e.layoutDependency!==t||t===void 0||e.isPresent!==i?a.willUpdate():this.safeToRemove(),e.isPresent!==i&&(i?a.promote():a.relegate()||k.postRender(()=>{let e=a.getStack();(!e||!e.members.length)&&this.safeToRemove()})),null):null}componentDidUpdate(){let{visualElement:e,layoutAnchor:t}=this.props,{projection:n}=e;n&&(n.options.layoutAnchor=t,n.root.didUpdate(),hi.postRender(()=>{!n.currentAnimation&&n.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;El=!0,r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){let{safeToRemove:e}=this.props;e&&e()}render(){return null}};function Ol(e){let[t,n]=Ys(),r=(0,o.useContext)(s);return(0,Ic.jsx)(Dl,{...e,layoutGroup:r,switchLayoutGroup:(0,o.useContext)(jc),isPresent:t,safeToRemove:n})}var kl={pan:{Feature:Tl},drag:{Feature:Cl,ProjectionNode:qs,MeasureLayout:Ol}};function Al(e,t,n){let{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive(`whileHover`,n===`Start`);let i=r[`onHover`+n];i&&k.postRender(()=>i(t,Kc(t)))}var jl=class extends J{mount(){let{current:e}=this.node;e&&(this.unmount=xi(e,(e,t)=>(Al(this.node,t,`Start`),e=>Al(this.node,e,`End`))))}unmount(){}},Ml=class extends J{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(`:focus-visible`)}catch{e=!0}!e||!this.node.animationState||(this.node.animationState.setActive(`whileFocus`,!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive(`whileFocus`,!1),this.isActive=!1)}mount(){this.unmount=x(as(this.node.current,`focus`,()=>this.onFocus()),as(this.node.current,`blur`,()=>this.onBlur()))}unmount(){}};function Nl(e,t,n){let{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive(`whileTap`,n===`Start`);let i=r[`onTap`+(n===`End`?``:n)];i&&k.postRender(()=>i(t,Kc(t)))}var Pl=class extends J{mount(){let{current:e}=this.node;if(!e)return;let{globalTapTarget:t,propagate:n}=this.node.props;this.unmount=Pi(e,(e,t)=>(Nl(this.node,t,`Start`),(e,{success:t})=>Nl(this.node,e,t?`End`:`Cancel`)),{useGlobalTarget:t,stopPropagation:n?.tap===!1})}unmount(){}},Fl=new WeakMap,Il=new WeakMap,Ll=e=>{let t=Fl.get(e.target);t&&t(e)},Rl=e=>{e.forEach(Ll)};function zl({root:e,...t}){let n=e||document;Il.has(n)||Il.set(n,{});let r=Il.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(Rl,{root:e,...t})),r[i]}function Bl(e,t,n){let r=zl(t);return Fl.set(e,n),r.observe(e),()=>{Fl.delete(e),r.unobserve(e)}}var Vl={some:0,all:1},Hl=class extends J{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.stopObserver?.();let{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r=`some`,once:i}=e,a={root:t?t.current:void 0,rootMargin:n,threshold:typeof r==`number`?r:Vl[r]};this.stopObserver=Bl(this.node.current,a,e=>{let{isIntersecting:t}=e;if(this.isInView===t||(this.isInView=t,i&&!t&&this.hasEnteredView))return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive(`whileInView`,t);let{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),a=t?n:r;a&&a(e)})}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>`u`)return;let{props:e,prevProps:t}=this.node;[`amount`,`margin`,`root`].some(Ul(e,t))&&this.startObserver()}unmount(){this.stopObserver?.(),this.hasEnteredView=!1,this.isInView=!1}};function Ul({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}var Wl={inView:{Feature:Hl},tap:{Feature:Pl},focus:{Feature:Ml},hover:{Feature:jl}},Gl={layout:{ProjectionNode:qs,MeasureLayout:Ol}},Kl=Vc({...Gc,...Wl,...kl,...Gl},Hc),ql={damping:25,stiffness:200},Jl={staggerChildren:.04},Yl={hidden:{opacity:0,y:8},visible:{opacity:1,y:0}};export{c as _,Ys as a,G as c,un as d,Zt as f,l as g,u as h,Kl as i,jr as l,k as m,Jl as n,Js as o,A as p,Yl as r,mi as s,ql as t,W as u,s as v};
@@ -0,0 +1 @@
1
+ import{It as e,Lt as t,un as n}from"./badge-LeU66vxM.js";import{A as r,F as i,b as a,m as o,n as s,p as c,r as l,t as u,u as d}from"./link-DBmH_08w.js";function f(e){return!!e?.isNotFound}var p=`__root__`;function m(e){if(e.statusCode=e.statusCode||e.code||307,!e._builtLocation&&!e.reloadDocument&&typeof e.href==`string`)try{new URL(e.href),e.reloadDocument=!0}catch{}let t=new Headers(e.headers);e.href&&t.get(`Location`)===null&&t.set(`Location`,e.href);let n=new Response(null,{status:e.statusCode,headers:t});if(n.options=e,e.throw)throw n;return n}function h(e){return e instanceof Response&&!!e.options}var g=class{get to(){return this._to}get id(){return this._id}get path(){return this._path}get fullPath(){return this._fullPath}constructor(e){if(this.init=e=>{this.originalIndex=e.originalIndex;let t=this.options,n=!t?.path&&!t?.id;this.parentRoute=this.options.getParentRoute?.(),n?this._path=p:this.parentRoute||a(!1,`Child Route instances must pass a 'getParentRoute: () => ParentRoute' option that returns a Route instance.`);let r=n?p:t?.path;r&&r!==`/`&&(r=c(r));let i=t?.id||r,s=n?p:d([this.parentRoute.id===`__root__`?``:this.parentRoute.id,i]);r===`__root__`&&(r=`/`),s!==`__root__`&&(s=d([`/`,s]));let l=s===`__root__`?`/`:d([this.parentRoute.fullPath,r]);this._path=r,this._id=s,this._fullPath=l,this._to=o(l)},this.addChildren=e=>this._addFileChildren(e),this._addFileChildren=e=>(Array.isArray(e)&&(this.children=e),typeof e==`object`&&e&&(this.children=Object.values(e)),this),this._addFileTypes=()=>this,this.updateLoader=e=>(Object.assign(this.options,e),this),this.update=e=>(Object.assign(this.options,e),this),this.lazy=e=>(this.lazyFn=e,this),this.redirect=e=>m({from:this.fullPath,...e}),this.options=e||{},this.isRoot=!e?.getParentRoute,e?.id&&e?.path)throw Error(`Route cannot have both an 'id' and a 'path' option.`)}},_=class extends g{constructor(e){super(e)}},v=n(t(),1),y=v.createContext(void 0),b=v.createContext(void 0);function x(e){let t=v.useContext(e.from?b:y);return s({select:n=>{let r=n.matches.find(n=>e.from?e.from===n.routeId:n.id===t);if(a(!((e.shouldThrow??!0)&&!r),`Could not find ${e.from?`an active match from "${e.from}"`:`a nearest match!`}`),r!==void 0)return e.select?e.select(r):r},structuralSharing:e.structuralSharing})}function S(e){return x({from:e.from,strict:e.strict,structuralSharing:e.structuralSharing,select:t=>e.select?e.select(t.loaderData):t.loaderData})}function C(e){let{select:t,...n}=e;return x({...n,select:e=>t?t(e.loaderDeps):e.loaderDeps})}function w(e){return x({from:e.from,shouldThrow:e.shouldThrow,structuralSharing:e.structuralSharing,strict:e.strict,select:t=>{let n=e.strict===!1?t.params:t._strictParams;return e.select?e.select(n):n}})}function T(e){return x({from:e.from,strict:e.strict,shouldThrow:e.shouldThrow,structuralSharing:e.structuralSharing,select:t=>e.select?e.select(t.search):t.search})}function E(e){let t=l();return v.useCallback(n=>t.navigate({...n,from:n.from??e?.from}),[e?.from,t])}function D(e){return x({...e,select:t=>e.select?e.select(t.context):t.context})}var O=e(),k=class extends g{constructor(e){super(e),this.useMatch=e=>x({select:e?.select,from:this.id,structuralSharing:e?.structuralSharing}),this.useRouteContext=e=>D({...e,from:this.id}),this.useSearch=e=>T({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useParams=e=>w({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useLoaderDeps=e=>C({...e,from:this.id}),this.useLoaderData=e=>S({...e,from:this.id}),this.useNavigate=()=>E({from:this.fullPath}),this.Link=v.forwardRef((e,t)=>(0,O.jsx)(u,{ref:t,from:this.fullPath,...e})),this.$$typeof=Symbol.for(`react.memo`)}};function A(e){return new k(e)}function j(){return e=>N(e)}var M=class extends _{constructor(e){super(e),this.useMatch=e=>x({select:e?.select,from:this.id,structuralSharing:e?.structuralSharing}),this.useRouteContext=e=>D({...e,from:this.id}),this.useSearch=e=>T({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useParams=e=>w({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useLoaderDeps=e=>C({...e,from:this.id}),this.useLoaderData=e=>S({...e,from:this.id}),this.useNavigate=()=>E({from:this.fullPath}),this.Link=v.forwardRef((e,t)=>(0,O.jsx)(u,{ref:t,from:this.fullPath,...e})),this.$$typeof=Symbol.for(`react.memo`)}};function N(e){return new M(e)}function P(e){return typeof e==`object`?new F(e,{silent:!0}).createRoute(e):new F(e,{silent:!0}).createRoute}var F=class{constructor(e,t){this.path=e,this.createRoute=e=>{let t=A(e);return t.isRoot=!1,t},this.silent=t?.silent}},I=class{constructor(e){this.useMatch=e=>x({select:e?.select,from:this.options.id,structuralSharing:e?.structuralSharing}),this.useRouteContext=e=>D({...e,from:this.options.id}),this.useSearch=e=>T({select:e?.select,structuralSharing:e?.structuralSharing,from:this.options.id}),this.useParams=e=>w({select:e?.select,structuralSharing:e?.structuralSharing,from:this.options.id}),this.useLoaderDeps=e=>C({...e,from:this.options.id}),this.useLoaderData=e=>S({...e,from:this.options.id}),this.useNavigate=()=>E({from:l().routesById[this.options.id].fullPath}),this.options=e,this.$$typeof=Symbol.for(`react.memo`)}};function L(e){return typeof e==`object`?new I(e):t=>new I({id:e,...t})}function R(e,t){let n,a,o,s,c=()=>(n||=e().then(e=>{n=void 0,a=e[t??`default`]}).catch(e=>{if(o=e,r(o)&&o instanceof Error&&typeof window<`u`&&typeof sessionStorage<`u`){let e=`tanstack_router_reload:${o.message}`;sessionStorage.getItem(e)||(sessionStorage.setItem(e,`1`),s=!0)}}),n),l=function(e){if(s)throw window.location.reload(),new Promise(()=>{});if(o)throw o;if(!a)if(i)i(c());else throw c();return v.createElement(a,e)};return l.preload=c,l}var z=`modulepreload`,B=function(e){return`/`+e},V={},H=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}r=o(t.map(t=>{if(t=B(t,n),t in V)return;V[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:z,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})};export{j as a,h as c,f as d,L as i,m as l,R as n,w as o,P as r,y as s,H as t,p as u};
@@ -0,0 +1,6 @@
1
+ import{It as e,Lt as t,T as n,un as r,w as i,x as a}from"./badge-LeU66vxM.js";var o=r(t(),1),s=e(),c=`Progress`,l=100,[u,d]=i(c),[f,p]=u(c),m=o.forwardRef((e,t)=>{let{__scopeProgress:r,value:i=null,max:a,getValueLabel:o=_,...c}=e;(a||a===0)&&!b(a)&&console.error(S(`${a}`,`Progress`));let u=b(a)?a:l;i!==null&&!x(i,u)&&console.error(C(`${i}`,`Progress`));let d=x(i,u)?i:null,p=y(d)?o(d,u):void 0;return(0,s.jsx)(f,{scope:r,value:d,max:u,children:(0,s.jsx)(n.div,{"aria-valuemax":u,"aria-valuemin":0,"aria-valuenow":y(d)?d:void 0,"aria-valuetext":p,role:`progressbar`,"data-state":v(d,u),"data-value":d??void 0,"data-max":u,...c,ref:t})})});m.displayName=c;var h=`ProgressIndicator`,g=o.forwardRef((e,t)=>{let{__scopeProgress:r,...i}=e,a=p(h,r);return(0,s.jsx)(n.div,{"data-state":v(a.value,a.max),"data-value":a.value??void 0,"data-max":a.max,...i,ref:t})});g.displayName=h;function _(e,t){return`${Math.round(e/t*100)}%`}function v(e,t){return e==null?`indeterminate`:e===t?`complete`:`loading`}function y(e){return typeof e==`number`}function b(e){return y(e)&&!isNaN(e)&&e>0}function x(e,t){return y(e)&&!isNaN(e)&&e<=t&&e>=0}function S(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${l}\`.`}function C(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
2
+ - a positive number
3
+ - less than the value passed to \`max\` (or ${l} if no \`max\` prop is set)
4
+ - \`null\` or \`undefined\` if the progress is indeterminate.
5
+
6
+ Defaulting to \`null\`.`}var w=m,T=g;function E({className:e,value:t,...n}){return(0,s.jsx)(w,{"data-slot":`progress`,className:a(`relative h-1 w-full overflow-hidden rounded-full bg-primary/20`,e),...n,children:(0,s.jsx)(T,{"data-slot":`progress-indicator`,className:`h-full w-full flex-1 bg-primary transition-all`,style:{transform:`translateX(-${100-(t||0)}%)`}})})}export{E as t};
@@ -0,0 +1 @@
1
+ import{$ as e,It as t,Lt as n,St as r,Tt as i,_ as a,at as o,j as s,mt as c,o as l,pt as u,r as d,rt as f,t as p,un as m,x as h}from"./badge-LeU66vxM.js";import{t as g}from"./link-DBmH_08w.js";import{i as _,n as v,t as y}from"./tooltip-CAuNczLe.js";import"./button-9A03BFB6.js";import{t as b}from"./progress-qFNeU9jW.js";import{_ as x,c as S,d as C,f as w,g as T,i as ee,l as E,m as D,o as O,p as te,t as ne,u as k}from"./motion-BYjuf98F.js";import{a as re,i as A,n as j,o as M,r as N,s as ie,t as ae}from"./stagger-container-GyT5nb39.js";import{i as oe,n as P,r as F,t as I}from"./card-C6aK9m3p.js";import{t as L}from"./skeleton-Cwiwlof_.js";function R(...e){let t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],i=e[1+n],a=e[2+n],o=e[3+n],s=w(i,a,o);return t?s(r):s}function z(e,t,n={}){let r=e.get(),i=null,a=r,o,s=typeof r==`string`?r.replace(/[\d.-]/g,``):void 0,c=()=>{i&&=(i.stop(),null),e.animation=void 0},l=()=>{let t=V(e.get()),r=V(a);if(t===r){c();return}let s=i?i.getGeneratorVelocity():e.getVelocity();c(),i=new C({keyframes:[t,r],velocity:s,type:`spring`,restDelta:.001,restSpeed:.01,...n,onUpdate:o})},u=()=>{l(),e.animation=i??void 0,e.events.animationStart?.notify(),i?.then(()=>{e.animation=void 0,e.events.animationComplete?.notify()})};if(e.attach((e,t)=>{a=e,o=e=>t(B(e,s)),D.postRender(u)},c),S(t)){let r=n.skipInitialAnimation===!0,i=t.on(`change`,t=>{r?(r=!1,e.jump(B(t,s),!1)):e.set(B(t,s))}),a=e.on(`destroy`,i);return()=>{i(),a()}}return c}function B(e,t){return t?e+t:e}function V(e){return typeof e==`number`?e:parseFloat(e)}var H=m(n(),1);function U(e){let t=x(()=>k(e)),{isStatic:n}=(0,H.useContext)(O);if(n){let[,n]=(0,H.useState)(e);(0,H.useEffect)(()=>t.on(`change`,n),[])}return t}function W(e,t){let n=U(t()),r=()=>n.set(t());return r(),T(()=>{let t=()=>D.preRender(r,!1,!0),n=e.map(e=>e.on(`change`,t));return()=>{n.forEach(e=>e()),te(r)}}),n}function G(e){E.current=[],e();let t=W(E.current,e);return E.current=void 0,t}function K(e,t,n,r){if(typeof e==`function`)return G(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!=`function`)return se(e,t,n,r);let i=typeof t==`function`?t:R(t,n,r),a=Array.isArray(e)?q(e,i):q([e],([e])=>i(e)),o=Array.isArray(e)?void 0:e.accelerate;return o&&!o.isTransformed&&typeof t!=`function`&&Array.isArray(n)&&r?.clamp!==!1&&(a.accelerate={...o,times:t,keyframes:n,isTransformed:!0,...r?.ease?{ease:r.ease}:{}}),a}function q(e,t){let n=x(()=>[]);return W(e,()=>{n.length=0;let r=e.length;for(let t=0;t<r;t++)n[t]=e[t].get();return t(n)})}function se(e,t,n,r){let i=x(()=>Object.keys(n)),a=x(()=>({}));for(let o of i)a[o]=K(e,t,n[o],r);return a}function ce(e,t={}){let{isStatic:n}=(0,H.useContext)(O),r=()=>S(e)?e.get():e;if(n)return K(r);let i=U(r());return(0,H.useInsertionEffect)(()=>z(i,e,t),[i,JSON.stringify(t)]),i}function le(e,t={}){return ce(e,{type:`spring`,...t})}var J=t();function ue({value:e,className:t,style:n}){let r=U(0),i=K(le(r,ne),e=>Math.round(e)),a=(0,H.useRef)(null);return(0,H.useEffect)(()=>{r.set(e)},[e,r]),(0,H.useEffect)(()=>i.on(`change`,e=>{a.current&&(a.current.textContent=String(e))}),[i]),(0,J.jsx)(ee.span,{ref:a,className:t,style:n,children:e})}function Y({label:e,value:t,icon:n,loading:r}){return(0,J.jsx)(I,{className:`border-stone-200 dark:border-stone-700`,children:(0,J.jsxs)(P,{className:`flex items-center gap-4 py-4`,children:[(0,J.jsx)(`div`,{className:`flex size-10 items-center justify-center rounded-lg bg-accent/80`,children:n}),(0,J.jsxs)(`div`,{children:[r?(0,J.jsx)(L,{className:`h-7 w-12`}):(0,J.jsx)(ue,{value:t,className:`text-2xl font-bold`,style:{fontFamily:`var(--font-display)`}}),(0,J.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:e})]})]})})}var X=[{r:45,g:139,b:122},{r:98,g:129,b:65},{r:123,g:107,b:141},{r:230,g:126,b:34},{r:64,g:81,b:59}];function de(e){let t=X[e%X.length];return`linear-gradient(90deg, rgba(${t.r},${t.g},${t.b},0.04) 0%, rgba(${t.r},${t.g},${t.b},0.12) 50%, rgba(${t.r},${t.g},${t.b},0.04) 100%)`}var Z={S:`size.S`,M:`size.M`,L:`size.L`,XL:`size.XL`,D:`size.D`};function fe(e,t){return e.status===`completed`||e.status===`done`||e.status===`cancelled`?null:e.review_status===`changes_requested`?t(`action.changesRequested`):e.review_status===`pending`&&[`M`,`L`].includes(e.size??``)?t(`action.awaitingReview`):e.focus?t(`action.implementing`):t(`action.specCreation`)}function pe({task:e,colorIndex:t}){let{t:n}=r(),i=(e.total??0)>0?(e.completed??0)/(e.total??1)*100:0,a=e.status===`completed`||e.status===`done`||e.status===`cancelled`,s=e.waves?.find(e=>e.isCurrent),c=X[t%X.length],l=`rgb(${c.r},${c.g},${c.b})`,u=fe(e,n);return(0,J.jsx)(g,{to:`/tasks/$slug`,params:{slug:e.slug},className:`block`,children:(0,J.jsx)(I,{className:h(`al-icon-wrapper h-[140px] !gap-0 !py-0 border-stone-200 transition-[border-color,transform] duration-200 hover:border-stone-300 hover:-translate-y-0.5 dark:border-stone-700 dark:hover:border-stone-600`,a&&`opacity-60`),children:(0,J.jsxs)(P,{className:`flex-1 flex flex-col p-4 gap-1.5`,children:[(0,J.jsxs)(`div`,{className:`flex items-center justify-between gap-2`,children:[(0,J.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[a?(0,J.jsx)(o,{className:`size-4 shrink-0`,style:{color:`#2d8b7a`}}):(0,J.jsx)(f,{className:`size-4 shrink-0`,style:{color:l}}),(0,J.jsx)(`span`,{className:`text-sm font-semibold font-mono truncate`,children:e.slug})]}),(0,J.jsx)(`div`,{className:`flex shrink-0 gap-1.5`,children:e.size&&(0,J.jsxs)(y,{children:[(0,J.jsx)(_,{asChild:!0,children:(0,J.jsx)(p,{variant:`outline`,className:`text-[10px] px-1.5 py-0 rounded-full cursor-help`,children:e.size})}),(0,J.jsx)(v,{children:Z[e.size]?n(Z[e.size]):e.size})]})})]}),(0,J.jsxs)(`div`,{className:`flex-1 flex flex-col justify-center gap-1`,children:[e.project_name&&(0,J.jsx)(`p`,{className:`text-[10px] font-medium text-muted-foreground`,children:e.project_name}),s&&!a?(0,J.jsxs)(`div`,{className:`relative overflow-hidden rounded-md px-2 py-1`,children:[(0,J.jsx)(`div`,{className:`absolute inset-0 animate-shimmer`,style:{background:de(t),backgroundSize:`200% 100%`}}),(0,J.jsxs)(`p`,{className:`relative text-[11px] line-clamp-1`,style:{color:l},children:[`→ `,s.key===`closing`?`Closing`:`Wave ${s.key}`,`: `,s.title,` (`,s.checked,`/`,s.total,`)`]})]}):u?(0,J.jsx)(`p`,{className:`text-[11px] text-muted-foreground`,children:u}):null]}),(0,J.jsxs)(`div`,{className:`flex items-center gap-2.5`,children:[(0,J.jsx)(b,{value:i,className:`flex-1`}),(0,J.jsxs)(`span`,{className:`text-[11px] tabular-nums text-muted-foreground`,children:[e.completed,`/`,e.total]})]})]})})})}function Q({epics:e}){let{t}=r();return!e||e.length===0?null:(0,J.jsxs)(I,{className:`border-stone-200 dark:border-stone-700`,children:[(0,J.jsx)(F,{className:`pb-3`,children:(0,J.jsx)(oe,{className:`text-sm font-semibold`,style:{fontFamily:`var(--font-display)`},children:t(`overview.epics`)})}),(0,J.jsx)(P,{className:`space-y-3`,children:e.map(e=>{let t=e.total>0?e.completed/e.total*100:0;return(0,J.jsxs)(`div`,{className:`space-y-1.5`,children:[(0,J.jsxs)(`div`,{className:`flex items-center justify-between gap-2`,children:[(0,J.jsx)(`span`,{className:`text-sm font-medium truncate`,children:e.name}),(0,J.jsxs)(`span`,{className:`text-xs tabular-nums text-muted-foreground shrink-0`,children:[e.completed,`/`,e.total]})]}),(0,J.jsx)(b,{value:t,className:``})]},e.slug)})})]})}var $=9;function me(){let{t}=r(),[n,o]=(0,H.useState)(1),{data:f,isLoading:p}=i(a()),{data:m}=i(l()),{data:h}=i(d()),g=[...f?.tasks??[]].sort((e,t)=>{let n=e.started_at??``;return(t.started_at??``).localeCompare(n)});return(0,J.jsxs)(`div`,{className:`space-y-8`,children:[(0,J.jsxs)(`div`,{className:`grid gap-4 sm:grid-cols-2 lg:grid-cols-[1fr_1fr_1fr_1fr_auto]`,children:[(0,J.jsx)(Y,{label:t(`overview.totalTasks`),value:g.length,icon:(0,J.jsx)(s,{className:`size-4`,style:{color:`#e67e22`}}),loading:p}),(0,J.jsx)(Y,{label:t(`overview.active`),value:g.filter(e=>{let t=e.status;return t!==`completed`&&t!==`done`&&t!==`cancelled`}).length,icon:(0,J.jsx)(e,{className:`size-4`,style:{color:`#40513b`}}),loading:p}),(0,J.jsx)(Y,{label:t(`overview.completed`),value:g.filter(e=>e.status===`completed`||e.status===`done`).length,icon:(0,J.jsx)(u,{className:`size-4`,style:{color:`#2d8b7a`}}),loading:p}),(0,J.jsx)(Y,{label:t(`overview.knowledge`),value:m?.total??0,icon:(0,J.jsx)(c,{className:`size-4`,style:{color:`#628141`}})}),(0,J.jsx)(he,{stats:m})]}),g.length>0&&(()=>{let e=Math.ceil(g.length/$),r=g.slice((n-1)*$,n*$);return(0,J.jsxs)(`section`,{className:`space-y-3`,children:[(0,J.jsx)(`h2`,{className:`text-2xl font-semibold tracking-tight text-foreground`,style:{fontFamily:`var(--font-display)`},children:t(`overview.tasks`)}),(0,J.jsx)(ae,{className:`grid gap-4 sm:grid-cols-2 lg:grid-cols-3`,style:{minHeight:`calc(140px * 3 + 16px * 2)`},children:r.map((e,t)=>(0,J.jsx)(pe,{task:e,colorIndex:(n-1)*$+t},e.slug))}),e>1&&(0,J.jsx)(_e,{page:n,totalPages:e,onPageChange:o})]})})(),(0,J.jsx)(Q,{epics:h?.epics?.filter(e=>e.status!==`completed`)})]})}function he({stats:e}){let{t}=r();return e?(0,J.jsx)(I,{className:`border-stone-200 dark:border-stone-700 min-w-[220px]`,children:(0,J.jsx)(P,{className:`flex items-center gap-4 py-4`,children:(0,J.jsxs)(`div`,{className:`flex flex-col gap-2 flex-1`,children:[(0,J.jsx)(`p`,{className:`text-[10px] font-medium text-muted-foreground uppercase tracking-wider`,children:t(`overview.memoryHealth`)}),(0,J.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,J.jsxs)(y,{children:[(0,J.jsx)(_,{asChild:!0,children:(0,J.jsxs)(`span`,{className:`text-sm tabular-nums font-medium cursor-help`,style:{color:(e.stale_count??0)>0?`#e67e22`:void 0},children:[e.stale_count??0,` `,(0,J.jsx)(`span`,{className:`text-[10px] text-muted-foreground`,children:t(`overview.stale`)})]})}),(0,J.jsx)(v,{children:t(`overview.staleHint`)})]}),(0,J.jsxs)(y,{children:[(0,J.jsx)(_,{asChild:!0,children:(0,J.jsxs)(`span`,{className:`text-sm tabular-nums font-medium cursor-help`,style:{color:(e.conflict_count??0)>0?`#c0392b`:void 0},children:[e.conflict_count??0,` `,(0,J.jsx)(`span`,{className:`text-[10px] text-muted-foreground`,children:t(`overview.conflicts`)})]})}),(0,J.jsx)(v,{children:t(`overview.conflictsHint`)})]})]}),e.vitality_dist&&(0,J.jsx)(ge,{dist:e.vitality_dist})]})})}):null}function ge({dist:e}){let{t}=r(),n=e.reduce((e,t)=>e+t,0)||1;return(0,J.jsxs)(y,{children:[(0,J.jsx)(_,{asChild:!0,children:(0,J.jsx)(`div`,{className:`flex h-2 w-full overflow-hidden rounded-full cursor-help`,children:e.map((e,t)=>(0,J.jsx)(`div`,{style:{width:`${e/n*100}%`,backgroundColor:`#2d8b7a`,opacity:.2+t/4*.8}},t))})}),(0,J.jsxs)(v,{children:[(0,J.jsx)(`p`,{className:`text-[10px] font-medium text-muted-foreground uppercase tracking-wider`,children:t(`overview.vitality`)}),(0,J.jsx)(`div`,{className:`flex gap-2 mt-1 text-[10px]`,children:[`0-20`,`21-40`,`41-60`,`61-80`,`81-100`].map((t,n)=>(0,J.jsxs)(`span`,{className:`tabular-nums`,children:[t,`: `,e[n]]},t))})]})]})}function _e({page:e,totalPages:t,onPageChange:n}){return(0,J.jsx)(j,{children:(0,J.jsxs)(N,{children:[(0,J.jsx)(A,{children:(0,J.jsx)(ie,{onClick:()=>n(Math.max(1,e-1)),"aria-disabled":e<=1,className:e<=1?`pointer-events-none opacity-50`:`cursor-pointer`})}),Array.from({length:t},(e,t)=>t+1).map(t=>(0,J.jsx)(A,{children:(0,J.jsx)(re,{isActive:t===e,onClick:()=>n(t),className:`cursor-pointer`,children:t})},t)),(0,J.jsx)(A,{children:(0,J.jsxs)(`span`,{className:`text-xs text-muted-foreground tabular-nums px-2`,children:[e,` / `,t]})}),(0,J.jsx)(A,{children:(0,J.jsx)(M,{onClick:()=>n(Math.min(t,e+1)),"aria-disabled":e>=t,className:e>=t?`pointer-events-none opacity-50`:`cursor-pointer`})})]})})}export{me as component};
@@ -0,0 +1,5 @@
1
+ import{A as e,C as t,It as n,Lt as r,O as i,T as a,un as o,w as s,x as c}from"./badge-LeU66vxM.js";import{c as l,d as u,f as d,h as f,l as ee,p}from"./button-9A03BFB6.js";import{i as m,n as h,r as g,t as _}from"./es2015-DCAVxrl_.js";var v=o(r(),1),y=n(),b=`Dialog`,[x,S]=s(b),[C,w]=x(b),T=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=v.useRef(null),c=v.useRef(null),[l,d]=p({prop:r,defaultProp:i??!1,onChange:a,caller:b});return(0,y.jsx)(C,{scope:t,triggerRef:s,contentRef:c,contentId:u(),titleId:u(),descriptionId:u(),open:l,onOpenChange:d,onOpenToggle:v.useCallback(()=>d(e=>!e),[d]),modal:o,children:n})};T.displayName=b;var E=`DialogTrigger`,D=v.forwardRef((t,n)=>{let{__scopeDialog:r,...i}=t,o=w(E,r),s=e(n,o.triggerRef);return(0,y.jsx)(a.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":o.open,"aria-controls":o.contentId,"data-state":G(o.open),...i,ref:s,onClick:f(t.onClick,o.onOpenToggle)})});D.displayName=E;var O=`DialogPortal`,[k,A]=x(O,{forceMount:void 0}),j=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=w(O,t);return(0,y.jsx)(k,{scope:t,forceMount:n,children:v.Children.map(r,e=>(0,y.jsx)(d,{present:n||a.open,children:(0,y.jsx)(l,{asChild:!0,container:i,children:e})}))})};j.displayName=O;var M=`DialogOverlay`,N=v.forwardRef((e,t)=>{let n=A(M,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=w(M,e.__scopeDialog);return a.modal?(0,y.jsx)(d,{present:r||a.open,children:(0,y.jsx)(F,{...i,ref:t})}):null});N.displayName=M;var P=i(`DialogOverlay.RemoveScroll`),F=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=w(M,n);return(0,y.jsx)(h,{as:P,allowPinchZoom:!0,shards:[i.contentRef],children:(0,y.jsx)(a.div,{"data-state":G(i.open),...r,ref:t,style:{pointerEvents:`auto`,...r.style}})})}),I=`DialogContent`,L=v.forwardRef((e,t)=>{let n=A(I,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=w(I,e.__scopeDialog);return(0,y.jsx)(d,{present:r||a.open,children:a.modal?(0,y.jsx)(te,{...i,ref:t}):(0,y.jsx)(ne,{...i,ref:t})})});L.displayName=I;var te=v.forwardRef((t,n)=>{let r=w(I,t.__scopeDialog),i=v.useRef(null),a=e(n,r.contentRef,i);return v.useEffect(()=>{let e=i.current;if(e)return _(e)},[]),(0,y.jsx)(R,{...t,ref:a,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:f(t.onCloseAutoFocus,e=>{e.preventDefault(),r.triggerRef.current?.focus()}),onPointerDownOutside:f(t.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:f(t.onFocusOutside,e=>e.preventDefault())})}),ne=v.forwardRef((e,t)=>{let n=w(I,e.__scopeDialog),r=v.useRef(!1),i=v.useRef(!1);return(0,y.jsx)(R,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),R=v.forwardRef((t,n)=>{let{__scopeDialog:r,trapFocus:i,onOpenAutoFocus:a,onCloseAutoFocus:o,...s}=t,c=w(I,r),l=v.useRef(null),u=e(n,l);return g(),(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(m,{asChild:!0,loop:!0,trapped:i,onMountAutoFocus:a,onUnmountAutoFocus:o,children:(0,y.jsx)(ee,{role:`dialog`,id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":G(c.open),...s,ref:u,onDismiss:()=>c.onOpenChange(!1)})}),(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(Y,{titleId:c.titleId}),(0,y.jsx)(re,{contentRef:l,descriptionId:c.descriptionId})]})]})}),z=`DialogTitle`,B=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=w(z,n);return(0,y.jsx)(a.h2,{id:i.titleId,...r,ref:t})});B.displayName=z;var V=`DialogDescription`,H=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=w(V,n);return(0,y.jsx)(a.p,{id:i.descriptionId,...r,ref:t})});H.displayName=V;var U=`DialogClose`,W=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=w(U,n);return(0,y.jsx)(a.button,{type:`button`,...r,ref:t,onClick:f(e.onClick,()=>i.onOpenChange(!1))})});W.displayName=U;function G(e){return e?`open`:`closed`}var K=`DialogTitleWarning`,[q,J]=t(K,{contentName:I,titleName:z,docsSlug:`dialog`}),Y=({titleId:e})=>{let t=J(K),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
2
+
3
+ If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
4
+
5
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return v.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},X=`DialogDescriptionWarning`,re=({contentRef:e,descriptionId:t})=>{let n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${J(X).contentName}}.`;return v.useEffect(()=>{let r=e.current?.getAttribute(`aria-describedby`);t&&r&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},ie=T,ae=D,oe=j,se=N,ce=L,Z=B,le=H,ue=W,de=`Separator`,Q=`horizontal`,fe=[`horizontal`,`vertical`],$=v.forwardRef((e,t)=>{let{decorative:n,orientation:r=Q,...i}=e,o=pe(r)?r:Q,s=o===`vertical`?o:void 0,c=n?{role:`none`}:{"aria-orientation":s,role:`separator`};return(0,y.jsx)(a.div,{"data-orientation":o,...c,...i,ref:t})});$.displayName=de;function pe(e){return fe.includes(e)}var me=$;function he({className:e,orientation:t=`horizontal`,decorative:n=!0,...r}){return(0,y.jsx)(me,{"data-slot":`separator`,decorative:n,orientation:t,className:c(`shrink-0 bg-border data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px`,e),...r})}export{se as a,Z as c,S as d,le as i,ae as l,ue as n,oe as o,ce as r,ie as s,he as t,q as u};
@@ -1 +1 @@
1
- import{$t as e,j as t}from"./badge-C_nJR3_P.js";var n=e();function r({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`skeleton`,className:t(`animate-pulse rounded-md bg-accent`,e),...r})}export{r as t};
1
+ import{It as e,x as t}from"./badge-LeU66vxM.js";var n=e();function r({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`skeleton`,className:t(`animate-pulse rounded-md bg-accent`,e),...r})}export{r as t};
@@ -0,0 +1,9 @@
1
+ import{It as e,Lt as t,ct as n,st as r,un as i,x as a}from"./badge-LeU66vxM.js";import{n as o}from"./button-9A03BFB6.js";import{_ as s,a as c,g as l,h as u,i as d,n as f,o as p,r as m,s as h,t as g,v as _}from"./motion-BYjuf98F.js";var v=i(t(),1);function y(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function b(...e){return t=>{let n=!1,r=e.map(e=>{let r=y(e,t);return!n&&typeof r==`function`&&(n=!0),r});if(n)return()=>{for(let t=0;t<r.length;t++){let n=r[t];typeof n==`function`?n():y(e[t],null)}}}}function x(...e){return v.useCallback(b(...e),e)}var S=e(),C=class extends v.Component{getSnapshotBeforeUpdate(e){let t=this.props.childRef.current;if(h(t)&&e.isPresent&&!this.props.isPresent&&this.props.pop!==!1){let e=t.offsetParent,n=h(e)&&e.offsetWidth||0,r=h(e)&&e.offsetHeight||0,i=getComputedStyle(t),a=this.props.sizeRef.current;a.height=parseFloat(i.height),a.width=parseFloat(i.width),a.top=t.offsetTop,a.left=t.offsetLeft,a.right=n-a.width-a.left,a.bottom=r-a.height-a.top}return null}componentDidUpdate(){}render(){return this.props.children}};function w({children:e,isPresent:t,anchorX:n,anchorY:r,root:i,pop:a}){let o=(0,v.useId)(),s=(0,v.useRef)(null),c=(0,v.useRef)({width:0,height:0,top:0,left:0,right:0,bottom:0}),{nonce:l}=(0,v.useContext)(p),u=x(s,e.props?.ref??e?.ref);return(0,v.useInsertionEffect)(()=>{let{width:e,height:u,top:d,left:f,right:p,bottom:m}=c.current;if(t||a===!1||!s.current||!e||!u)return;let h=n===`left`?`left: ${f}`:`right: ${p}`,g=r===`bottom`?`bottom: ${m}`:`top: ${d}`;s.current.dataset.motionPopId=o;let _=document.createElement(`style`);l&&(_.nonce=l);let v=i??document.head;return v.appendChild(_),_.sheet&&_.sheet.insertRule(`
2
+ [data-motion-pop-id="${o}"] {
3
+ position: absolute !important;
4
+ width: ${e}px !important;
5
+ height: ${u}px !important;
6
+ ${h}px !important;
7
+ ${g}px !important;
8
+ }
9
+ `),()=>{s.current?.removeAttribute(`data-motion-pop-id`),v.contains(_)&&v.removeChild(_)}},[t]),(0,S.jsx)(C,{isPresent:t,childRef:s,sizeRef:c,pop:a,children:a===!1?e:v.cloneElement(e,{ref:u})})}var T=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:a,mode:o,anchorX:c,anchorY:l,root:d})=>{let f=s(E),p=(0,v.useId)(),m=!0,h=(0,v.useMemo)(()=>(m=!1,{id:p,initial:t,isPresent:n,custom:i,onExitComplete:e=>{f.set(e,!0);for(let e of f.values())if(!e)return;r&&r()},register:e=>(f.set(e,!1),()=>f.delete(e))}),[n,f,r]);return a&&m&&(h={...h}),(0,v.useMemo)(()=>{f.forEach((e,t)=>f.set(t,!1))},[n]),v.useEffect(()=>{!n&&!f.size&&r&&r()},[n]),e=(0,S.jsx)(w,{pop:o===`popLayout`,isPresent:n,anchorX:c,anchorY:l,root:d,children:e}),(0,S.jsx)(u.Provider,{value:h,children:e})};function E(){return new Map}var D=e=>e.key||``;function O(e){let t=[];return v.Children.forEach(e,e=>{(0,v.isValidElement)(e)&&t.push(e)}),t}var k=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:a=`sync`,propagate:o=!1,anchorX:u=`left`,anchorY:d=`top`,root:f})=>{let[p,m]=c(o),h=(0,v.useMemo)(()=>O(e),[e]),g=o&&!p?[]:h.map(D),y=(0,v.useRef)(!0),b=(0,v.useRef)(h),x=s(()=>new Map),C=(0,v.useRef)(new Set),[w,E]=(0,v.useState)(h),[k,A]=(0,v.useState)(h);l(()=>{y.current=!1,b.current=h;for(let e=0;e<k.length;e++){let t=D(k[e]);g.includes(t)?(x.delete(t),C.current.delete(t)):x.get(t)!==!0&&x.set(t,!1)}},[k,g.length,g.join(`-`)]);let j=[];if(h!==w){let e=[...h];for(let t=0;t<k.length;t++){let n=k[t],r=D(n);g.includes(r)||(e.splice(t,0,n),j.push(n))}return a===`wait`&&j.length&&(e=j),A(O(e)),E(h),null}let{forceRender:M}=(0,v.useContext)(_);return(0,S.jsx)(S.Fragment,{children:k.map(e=>{let s=D(e),c=o&&!p?!1:h===k||g.includes(s);return(0,S.jsx)(T,{isPresent:c,initial:!y.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:a,root:f,onExitComplete:c?void 0:()=>{if(C.current.has(s))return;if(x.has(s))C.current.add(s),x.set(s,!0);else return;let e=!0;x.forEach(t=>{t||(e=!1)}),e&&(M?.(),A(b.current),o&&m?.(),r&&r())},anchorX:u,anchorY:d,children:e},s)})})};function A({className:e,...t}){return(0,S.jsx)(`nav`,{role:`navigation`,"aria-label":`pagination`,"data-slot":`pagination`,className:a(`mx-auto flex w-full justify-center`,e),...t})}function j({className:e,...t}){return(0,S.jsx)(`ul`,{"data-slot":`pagination-content`,className:a(`flex flex-row items-center gap-1`,e),...t})}function M({...e}){return(0,S.jsx)(`li`,{"data-slot":`pagination-item`,...e})}function N({className:e,isActive:t,size:n=`icon`,...r}){return(0,S.jsx)(`a`,{"aria-current":t?`page`:void 0,"data-slot":`pagination-link`,"data-active":t,className:a(o({variant:t?`outline`:`ghost`,size:n}),e),...r})}function P({className:e,...t}){return(0,S.jsxs)(N,{"aria-label":`Go to previous page`,size:`default`,className:a(`gap-1 px-2.5 sm:pl-2.5`,e),...t,children:[(0,S.jsx)(n,{}),(0,S.jsx)(`span`,{className:`hidden sm:block`,children:`Previous`})]})}function F({className:e,...t}){return(0,S.jsxs)(N,{"aria-label":`Go to next page`,size:`default`,className:a(`gap-1 px-2.5 sm:pr-2.5`,e),...t,children:[(0,S.jsx)(`span`,{className:`hidden sm:block`,children:`Next`}),(0,S.jsx)(r,{})]})}var I={hidden:{},visible:{transition:{...f}}};function L({children:e,className:t,style:n}){return(0,S.jsx)(d.div,{className:t,style:n,variants:I,initial:`hidden`,animate:`visible`,children:(0,S.jsx)(k,{children:v.Children.map(e,(e,t)=>e?(0,S.jsx)(d.div,{variants:m,transition:{...g},children:e},t):null)})})}export{N as a,M as i,A as n,F as o,j as r,P as s,L as t};
@@ -0,0 +1 @@
1
+ import{It as e,Lt as t,St as n,Tt as r,_ as i,at as a,it as o,lt as s,nt as c,t as l,tt as u,un as d,x as f}from"./badge-LeU66vxM.js";import{t as p}from"./link-DBmH_08w.js";import{o as m}from"./preload-helper-BmUhu0Y-.js";import{t as h}from"./progress-qFNeU9jW.js";import{c as g,n as _}from"./index-uOCUo7Eo.js";import"./motion-BYjuf98F.js";import{t as v}from"./butler-empty-DDWZ5SlJ.js";import{i as y,n as b}from"./types-Gr5neTyu.js";var x=d(t()),S=e();function C({status:e}){let t=b[e]??b.pending;return(0,S.jsx)(`span`,{style:{backgroundColor:t.bg,color:t.text},className:`inline-flex items-center rounded-full px-2 py-0.5 text-xs font-medium`,children:t.label})}var w=[{r:45,g:139,b:122},{r:98,g:129,b:65},{r:123,g:107,b:141},{r:230,g:126,b:34},{r:64,g:81,b:59}];function T(){let{t:e}=n(),{data:t}=r(i()),a=t?.tasks??[],{slug:o}=m({strict:!1}),[s,c]=(0,x.useState)(`all`),[l,u]=(0,x.useState)(new Set),d=new Set([`completed`,`done`,`cancelled`]),p=_.useNavigate(),h=a.find(e=>!d.has(e.status??``));!o&&h&&p({to:`/tasks/$slug`,params:{slug:h.slug}});let y=a.filter(e=>!(s===`active`&&d.has(e.status??``)||s===`review`&&e.review_status!==`pending`||s===`done`&&!d.has(e.status??``)||l.size>0&&!l.has(e.size??``))).sort((e,t)=>{let n=d.has(e.status??``)?1:0,r=d.has(t.status??``)?1:0;return n===r?(t.started_at??``).localeCompare(e.started_at??``):n-r}),b=e=>u(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n});return(0,S.jsxs)(`div`,{className:`flex gap-6 items-start`,children:[(0,S.jsxs)(`div`,{className:`w-72 shrink-0 space-y-2 overflow-y-auto max-h-[calc(100vh-100px)] px-1 pt-1`,children:[(0,S.jsx)(`div`,{className:`flex flex-wrap gap-1 pb-1`,children:[`all`,`active`,`done`].map(t=>(0,S.jsx)(`button`,{type:`button`,onClick:()=>c(t),className:f(`rounded-lg px-2 py-0.5 text-[10px] font-medium transition-colors border`,s===t?`bg-card text-foreground border-border`:`bg-card text-muted-foreground border-border/40 hover:text-foreground`),children:e(`filter.${t}`)},t))}),(0,S.jsx)(`div`,{className:`flex flex-wrap gap-1 pb-1`,children:[`S`,`M`,`L`].map(e=>(0,S.jsx)(`button`,{type:`button`,onClick:()=>b(e),className:f(`rounded-full px-1.5 py-0 text-[10px] font-medium transition-colors border`,l.has(e)?`bg-card text-foreground border-border`:`bg-card text-muted-foreground border-border/40 hover:text-foreground`),children:e},e))}),y.map((e,t)=>(0,S.jsx)(D,{task:e,isSelected:e.slug===o,colorIndex:t},e.slug)),y.length===0&&a.length===0&&(0,S.jsx)(v,{scene:`empty-tray`,messageKey:`empty.noTasks`})]}),(0,S.jsx)(`div`,{className:`min-w-0 flex-1`,children:(0,S.jsx)(g,{})})]})}function E({waves:e}){let{t}=n(),r=e.filter(e=>e.checked===e.total&&e.total>0).length;return(0,S.jsxs)(`span`,{children:[t(`tasks.waves`),` (`,r,`/`,e.length,`)`]})}function D({task:e,isSelected:t,colorIndex:n}){let[r,i]=(0,x.useState)(!1),a=(e.total??0)>0?(e.completed??0)/(e.total??1)*100:0,o=e.status===`completed`||e.status===`done`||e.status===`cancelled`,c=w[n%w.length];return(0,S.jsxs)(`div`,{className:f(`rounded-lg border bg-card text-card-foreground transition-colors overflow-hidden`,t&&`border-2`,o&&`opacity-60`),style:t?{borderColor:`var(--color-brand-dark)`}:void 0,children:[(0,S.jsx)(p,{to:`/tasks/$slug`,params:{slug:e.slug},className:`block p-3 pb-2`,children:(0,S.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,S.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[(0,S.jsx)(O,{status:e.status??`pending`}),(0,S.jsx)(`span`,{className:`text-sm font-medium font-mono truncate`,children:e.slug})]}),(0,S.jsxs)(`div`,{className:`flex items-center gap-1 shrink-0`,children:[(0,S.jsx)(C,{status:e.status??`pending`}),(0,S.jsx)(l,{variant:`outline`,className:`text-[10px] px-1 py-0`,children:e.size??`?`})]})]})}),(0,S.jsxs)(`div`,{className:`px-3 pb-3 space-y-1.5`,children:[(e.project_name||e.started_at)&&(0,S.jsxs)(`p`,{className:`text-[10px] font-medium`,style:{color:`#40513b`},children:[e.project_name,e.project_name&&e.started_at&&` · `,e.started_at&&(0,S.jsx)(`span`,{className:`text-muted-foreground/70 font-normal`,children:y(e.started_at)})]}),e.focus&&(0,S.jsx)(`p`,{className:`text-[11px] text-muted-foreground line-clamp-1`,children:e.focus}),(0,S.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,S.jsx)(h,{value:a,className:`h-1 flex-1 [&>div]:bg-[#e67e22]`}),(0,S.jsxs)(`span`,{className:`text-[10px] tabular-nums text-muted-foreground`,children:[e.completed,`/`,e.total]})]})]}),e.waves&&e.waves.length>0&&!o&&(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`button`,{type:`button`,onClick:e=>{e.preventDefault(),i(!r)},className:`flex w-full items-center justify-between border-t border-border/50 px-3 py-1.5 text-[10px] text-muted-foreground hover:bg-accent/50 transition-colors`,children:[(0,S.jsx)(E,{waves:e.waves}),(0,S.jsx)(s,{className:f(`size-3 transition-transform`,r&&`rotate-180`)})]}),r&&(0,S.jsx)(`div`,{className:`px-3 pb-3 space-y-1`,children:e.waves.map(e=>{let t=e.total>0&&e.checked===e.total,n=e.total>0?e.checked/e.total*100:0;return(0,S.jsxs)(`div`,{className:f(`relative rounded-md px-2 py-1.5 transition-colors`,e.isCurrent&&`overflow-hidden`),children:[e.isCurrent&&(0,S.jsx)(`div`,{className:`absolute inset-0 animate-shimmer`,style:{background:`linear-gradient(90deg, rgba(${c.r},${c.g},${c.b},0.03) 0%, rgba(${c.r},${c.g},${c.b},0.10) 50%, rgba(${c.r},${c.g},${c.b},0.03) 100%)`,backgroundSize:`200% 100%`}}),(0,S.jsxs)(`div`,{className:`relative flex items-center justify-between mb-0.5`,children:[(0,S.jsxs)(`span`,{className:f(`text-[10px] font-medium`,t&&`text-muted-foreground`,e.isCurrent&&`font-semibold`),children:[e.key===`closing`?`Closing`:`Wave ${e.key}`,`: `,e.title]}),(0,S.jsxs)(`span`,{className:`text-[10px] tabular-nums text-muted-foreground`,children:[e.checked,`/`,e.total]})]}),(0,S.jsx)(h,{value:n,className:f(`relative h-1`,t?`[&>div]:bg-[#2d8b7a]`:`[&>div]:bg-[#e67e22]`)})]},`wave-${e.key}`)})})]})]})}function O({status:e}){switch(e){case`done`:case`completed`:return(0,S.jsx)(a,{className:`size-3.5 shrink-0`,style:{color:`#2d8b7a`}});case`review`:return(0,S.jsx)(o,{className:`size-3.5 shrink-0`,style:{color:`#e67e22`}});case`deferred`:return(0,S.jsx)(c,{className:`size-3.5 shrink-0`,style:{color:`#7b6b8d`}});case`cancelled`:return(0,S.jsx)(u,{className:`size-3.5 shrink-0`,style:{color:`#c0392b`}});case`pending`:return(0,S.jsx)(o,{className:`size-3.5 shrink-0`,style:{color:`#9ca3af`}});default:return(0,S.jsx)(o,{className:`size-3.5 shrink-0 animate-spin`,style:{color:`#628141`,animationDuration:`1.5s`}})}}export{T as component};