@flarehr/superhero-salpac-profile-admin 1.0.802 → 1.0.803

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- var __defProp=Object.defineProperty,__typeError=e=>{throw TypeError(e)},__defNormalProp=(e,t,n)=>t in e?__defProp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__publicField=(e,t,n)=>__defNormalProp(e,"symbol"!=typeof t?t+"":t,n),__accessCheck=(e,t,n)=>t.has(e)||__typeError("Cannot "+n),__privateGet=(e,t,n)=>(__accessCheck(e,t,"read from private field"),n?n.call(e):t.get(e)),__privateAdd=(e,t,n)=>t.has(e)?__typeError("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),__privateSet=(e,t,n,r)=>(__accessCheck(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),__privateMethod=(e,t,n)=>(__accessCheck(e,t,"access private method"),n),__privateWrapper=(e,t,n,r)=>({set _(r){__privateSet(e,t,r,n)},get _(){return __privateGet(e,t,r)}});!function(){"use strict";var e,t,n,r,i,o,a,s,l,c,u,d,p,h,f,v,m,g,y,_,w,b,x,k,S,E,C,T,P,R,A,O,L,M,F,I,D,G,N,$,H,W,U,j,B,z,q,K,V,Q,Y,X,J,Z,ee,te,ne,re,ie,oe,ae,se,le,ce,ue,de,pe,he,fe,ve,me,ge,ye,_e,we,be,xe,ke,Se,Ee,Ce,Te,Pe,Re,Ae={},Oe=[],Le=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Me=Array.isArray;function Fe(e,t){for(var n in t)e[n]=t[n];return e}function Ie(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function De(e,t,n){var r,i,o,a={};for(o in t)"key"==o?r=t[o]:"ref"==o?i=t[o]:a[o]=t[o];if(arguments.length>2&&(a.children=arguments.length>3?_e.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(o in e.defaultProps)void 0===a[o]&&(a[o]=e.defaultProps[o]);return Ge(e,a,r,i,null)}function Ge(e,t,n,r,i){var o={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==i?++be:i,__i:-1,__u:0};return null==i&&null!=we.vnode&&we.vnode(o),o}function Ne(){return{current:null}}function $e(e){return e.children}function He(e,t){this.props=e,this.context=t}function We(e,t){if(null==t)return e.__?We(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e)return n.__e;return"function"==typeof e.type?We(e):null}function Ue(e){var t,n;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e){e.__e=e.__c.base=n.__e;break}return Ue(e)}}function je(e){(!e.__d&&(e.__d=!0)&&xe.push(e)&&!Be.__r++||ke!==we.debounceRendering)&&((ke=we.debounceRendering)||Se)(Be)}function Be(){var e,t,n,r,i,o,a,s;for(xe.sort(Ee);e=xe.shift();)e.__d&&(t=xe.length,r=void 0,o=(i=(n=e).__v).__e,a=[],s=[],n.__P&&((r=Fe({},i)).__v=i.__v+1,we.vnode&&we.vnode(r),Je(n.__P,r,i,n.__n,n.__P.namespaceURI,32&i.__u?[o]:null,a,null==o?We(i):o,!!(32&i.__u),s),r.__v=i.__v,r.__.__k[r.__i]=r,Ze(a,r,s),r.__e!=o&&Ue(r)),xe.length>t&&xe.sort(Ee));Be.__r=0}function ze(e,t,n,r,i,o,a,s,l,c,u){var d,p,h,f,v,m=r&&r.__k||Oe,g=t.length;for(n.__d=l,function(e,t,n){var r,i,o,a,s,l=t.length,c=n.length,u=c,d=0;for(e.__k=[],r=0;r<l;r++)null!=(i=t[r])&&"boolean"!=typeof i&&"function"!=typeof i?(a=r+d,(i=e.__k[r]="string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?Ge(null,i,null,null,null):Me(i)?Ge($e,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?Ge(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i).__=e,i.__b=e.__b+1,o=null,-1!==(s=i.__i=Ve(i,n,a,u))&&(u--,(o=n[s])&&(o.__u|=131072)),null==o||null===o.__v?(-1==s&&d--,"function"!=typeof i.type&&(i.__u|=65536)):s!==a&&(s==a-1?d--:s==a+1?d++:(s>a?d--:d++,i.__u|=65536))):i=e.__k[r]=null;if(u)for(r=0;r<c;r++)null!=(o=n[r])&&!(131072&o.__u)&&(o.__e==e.__d&&(e.__d=We(o)),tt(o,o))}(n,t,m),l=n.__d,d=0;d<g;d++)null!=(h=n.__k[d])&&(p=-1===h.__i?Ae:m[h.__i]||Ae,h.__i=d,Je(e,h,p,i,o,a,s,l,c,u),f=h.__e,h.ref&&p.ref!=h.ref&&(p.ref&&et(p.ref,null,h),u.push(h.ref,h.__c||f,h)),null==v&&null!=f&&(v=f),65536&h.__u||p.__k===h.__k?l=qe(h,l,e):"function"==typeof h.type&&void 0!==h.__d?l=h.__d:f&&(l=f.nextSibling),h.__d=void 0,h.__u&=-196609);n.__d=l,n.__e=v}function qe(e,t,n){var r,i;if("function"==typeof e.type){for(r=e.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=e,t=qe(r[i],t,n));return t}e.__e!=t&&(t&&e.type&&!n.contains(t)&&(t=We(e)),n.insertBefore(e.__e,t||null),t=e.__e);do{t=t&&t.nextSibling}while(null!=t&&8===t.nodeType);return t}function Ke(e,t){return t=t||[],null==e||"boolean"==typeof e||(Me(e)?e.some((function(e){Ke(e,t)})):t.push(e)),t}function Ve(e,t,n,r){var i=e.key,o=e.type,a=n-1,s=n+1,l=t[n];if(null===l||l&&i==l.key&&o===l.type&&!(131072&l.__u))return n;if(r>(null==l||131072&l.__u?0:1))for(;a>=0||s<t.length;){if(a>=0){if((l=t[a])&&!(131072&l.__u)&&i==l.key&&o===l.type)return a;a--}if(s<t.length){if((l=t[s])&&!(131072&l.__u)&&i==l.key&&o===l.type)return s;s++}}return-1}function Qe(e,t,n){"-"===t[0]?e.setProperty(t,null==n?"":n):e[t]=null==n?"":"number"!=typeof n||Le.test(t)?n:n+"px"}function Ye(e,t,n,r,i){var o;e:if("style"===t)if("string"==typeof n)e.style.cssText=n;else{if("string"==typeof r&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||Qe(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||Qe(e.style,t,n[t])}else if("o"===t[0]&&"n"===t[1])o=t!==(t=t.replace(/(PointerCapture)$|Capture$/i,"$1")),t=t.toLowerCase()in e||"onFocusOut"===t||"onFocusIn"===t?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+o]=n,n?r?n.u=r.u:(n.u=Ce,e.addEventListener(t,o?Pe:Te,o)):e.removeEventListener(t,o?Pe:Te,o);else{if("http://www.w3.org/2000/svg"==i)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=t&&"height"!=t&&"href"!=t&&"list"!=t&&"form"!=t&&"tabIndex"!=t&&"download"!=t&&"rowSpan"!=t&&"colSpan"!=t&&"role"!=t&&"popover"!=t&&t in e)try{e[t]=null==n?"":n;break e}catch(a){}"function"==typeof n||(null==n||!1===n&&"-"!==t[4]?e.removeAttribute(t):e.setAttribute(t,"popover"==t&&1==n?"":n))}}function Xe(e){return function(t){if(this.l){var n=this.l[t.type+e];if(null==t.t)t.t=Ce++;else if(t.t<n.u)return;return n(we.event?we.event(t):t)}}}function Je(e,t,n,r,i,o,a,s,l,c){var u,d,p,h,f,v,m,g,y,_,w,b,x,k,S,E,C=t.type;if(void 0!==t.constructor)return null;128&n.__u&&(l=!!(32&n.__u),o=[s=t.__e=n.__e]),(u=we.__b)&&u(t);e:if("function"==typeof C)try{if(g=t.props,y="prototype"in C&&C.prototype.render,_=(u=C.contextType)&&r[u.__c],w=u?_?_.props.value:u.__:r,n.__c?m=(d=t.__c=n.__c).__=d.__E:(y?t.__c=d=new C(g,w):(t.__c=d=new He(g,w),d.constructor=C,d.render=nt),_&&_.sub(d),d.props=g,d.state||(d.state={}),d.context=w,d.__n=r,p=d.__d=!0,d.__h=[],d._sb=[]),y&&null==d.__s&&(d.__s=d.state),y&&null!=C.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=Fe({},d.__s)),Fe(d.__s,C.getDerivedStateFromProps(g,d.__s))),h=d.props,f=d.state,d.__v=t,p)y&&null==C.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),y&&null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(y&&null==C.getDerivedStateFromProps&&g!==h&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(g,w),!d.__e&&(null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(g,d.__s,w)||t.__v===n.__v)){for(t.__v!==n.__v&&(d.props=g,d.state=d.__s,d.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some((function(e){e&&(e.__=t)})),b=0;b<d._sb.length;b++)d.__h.push(d._sb[b]);d._sb=[],d.__h.length&&a.push(d);break e}null!=d.componentWillUpdate&&d.componentWillUpdate(g,d.__s,w),y&&null!=d.componentDidUpdate&&d.__h.push((function(){d.componentDidUpdate(h,f,v)}))}if(d.context=w,d.props=g,d.__P=e,d.__e=!1,x=we.__r,k=0,y){for(d.state=d.__s,d.__d=!1,x&&x(t),u=d.render(d.props,d.state,d.context),S=0;S<d._sb.length;S++)d.__h.push(d._sb[S]);d._sb=[]}else do{d.__d=!1,x&&x(t),u=d.render(d.props,d.state,d.context),d.state=d.__s}while(d.__d&&++k<25);d.state=d.__s,null!=d.getChildContext&&(r=Fe(Fe({},r),d.getChildContext())),y&&!p&&null!=d.getSnapshotBeforeUpdate&&(v=d.getSnapshotBeforeUpdate(h,f)),ze(e,Me(E=null!=u&&u.type===$e&&null==u.key?u.props.children:u)?E:[E],t,n,r,i,o,a,s,l,c),d.base=t.__e,t.__u&=-161,d.__h.length&&a.push(d),m&&(d.__E=d.__=null)}catch(T){if(t.__v=null,l||null!=o){for(t.__u|=l?160:128;s&&8===s.nodeType&&s.nextSibling;)s=s.nextSibling;o[o.indexOf(s)]=null,t.__e=s}else t.__e=n.__e,t.__k=n.__k;we.__e(T,t,n)}else null==o&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=function(e,t,n,r,i,o,a,s,l){var c,u,d,p,h,f,v,m=n.props,g=t.props,y=t.type;if("svg"===y?i="http://www.w3.org/2000/svg":"math"===y?i="http://www.w3.org/1998/Math/MathML":i||(i="http://www.w3.org/1999/xhtml"),null!=o)for(c=0;c<o.length;c++)if((h=o[c])&&"setAttribute"in h==!!y&&(y?h.localName===y:3===h.nodeType)){e=h,o[c]=null;break}if(null==e){if(null===y)return document.createTextNode(g);e=document.createElementNS(i,y,g.is&&g),s&&(we.__m&&we.__m(t,o),s=!1),o=null}if(null===y)m===g||s&&e.data===g||(e.data=g);else{if(o=o&&_e.call(e.childNodes),m=n.props||Ae,!s&&null!=o)for(m={},c=0;c<e.attributes.length;c++)m[(h=e.attributes[c]).name]=h.value;for(c in m)if(h=m[c],"children"==c);else if("dangerouslySetInnerHTML"==c)d=h;else if(!(c in g)){if("value"==c&&"defaultValue"in g||"checked"==c&&"defaultChecked"in g)continue;Ye(e,c,null,h,i)}for(c in g)h=g[c],"children"==c?p=h:"dangerouslySetInnerHTML"==c?u=h:"value"==c?f=h:"checked"==c?v=h:s&&"function"!=typeof h||m[c]===h||Ye(e,c,h,m[c],i);if(u)s||d&&(u.__html===d.__html||u.__html===e.innerHTML)||(e.innerHTML=u.__html),t.__k=[];else if(d&&(e.innerHTML=""),ze(e,Me(p)?p:[p],t,n,r,"foreignObject"===y?"http://www.w3.org/1999/xhtml":i,o,a,o?o[0]:n.__k&&We(n,0),s,l),null!=o)for(c=o.length;c--;)Ie(o[c]);s||(c="value","progress"===y&&null==f?e.removeAttribute("value"):void 0!==f&&(f!==e[c]||"progress"===y&&!f||"option"===y&&f!==m[c])&&Ye(e,c,f,m[c],i),c="checked",void 0!==v&&v!==e[c]&&Ye(e,c,v,m[c],i))}return e}(n.__e,t,n,r,i,o,a,l,c);(u=we.diffed)&&u(t)}function Ze(e,t,n){t.__d=void 0;for(var r=0;r<n.length;r++)et(n[r],n[++r],n[++r]);we.__c&&we.__c(t,e),e.some((function(t){try{e=t.__h,t.__h=[],e.some((function(e){e.call(t)}))}catch(n){we.__e(n,t.__v)}}))}function et(e,t,n){try{if("function"==typeof e){var r="function"==typeof e.__u;r&&e.__u(),r&&null==t||(e.__u=e(t))}else e.current=t}catch(i){we.__e(i,n)}}function tt(e,t,n){var r,i;if(we.unmount&&we.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||et(r,null,t)),null!=(r=e.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(o){we.__e(o,t)}r.base=r.__P=null}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&tt(r[i],t,n||"function"!=typeof e.type);n||Ie(e.__e),e.__c=e.__=e.__e=e.__d=void 0}function nt(e,t,n){return this.constructor(e,n)}function rt(e,t,n){var r,i,o,a;we.__&&we.__(e,t),i=(r="function"==typeof n)?null:n&&n.__k||t.__k,o=[],a=[],Je(t,e=(!r&&n||t).__k=De($e,null,[e]),i||Ae,Ae,t.namespaceURI,!r&&n?[n]:i?null:t.firstChild?_e.call(t.childNodes):null,o,!r&&n?n:i?i.__e:t.firstChild,r,a),Ze(o,e,a)}function it(e,t){rt(e,t,it)}function ot(e,t,n){var r,i,o,a,s=Fe({},e.props);for(o in e.type&&e.type.defaultProps&&(a=e.type.defaultProps),t)"key"==o?r=t[o]:"ref"==o?i=t[o]:s[o]=void 0===t[o]&&void 0!==a?a[o]:t[o];return arguments.length>2&&(s.children=arguments.length>3?_e.call(arguments,2):n),Ge(e.type,s,r||e.key,i||e.ref,null)}function at(e,t){var n={__c:t="__cC"+Re++,__:e,Consumer:function(e,t){return e.children(t)},Provider:function(e){var n,r;return this.getChildContext||(n=new Set,(r={})[t]=this,this.getChildContext=function(){return r},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(e){this.props.value!==e.value&&n.forEach((function(e){e.__e=!0,je(e)}))},this.sub=function(e){n.add(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n&&n.delete(e),t&&t.call(e)}}),e.children}};return n.Provider.__=n.Consumer.contextType=n}function st(){return(st=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}_e=Oe.slice,we={__e:function(e,t,n,r){for(var i,o,a;t=t.__;)if((i=t.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(e)),a=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(e,r||{}),a=i.__d),a)return i.__E=i}catch(s){e=s}throw e}},be=0,He.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=Fe({},this.state),"function"==typeof e&&(e=e(Fe({},n),this.props)),e&&Fe(n,e),null!=e&&this.__v&&(t&&this._sb.push(t),je(this))},He.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),je(this))},He.prototype.render=$e,xe=[],Se="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Ee=function(e,t){return e.__v.__b-t.__v.__b},Be.__r=0,Ce=0,Te=Xe(!1),Pe=Xe(!0),Re=0;var lt=["context","children"];function ct(e){return this.getChildContext=function(){return e.context},ot(e.children,function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)t.indexOf(n=o[r])>=0||(i[n]=e[n]);return i}(e,lt))}function ut(){var e=new CustomEvent("_preact",{detail:{},bubbles:!0,cancelable:!0});this.dispatchEvent(e),this._vdom=De(ct,st({},this._props,{context:e.detail.context}),function e(t,n){if(3===t.nodeType)return t.data;if(1!==t.nodeType)return null;var r=[],i={},o=0,a=t.attributes,s=t.childNodes;for(o=a.length;o--;)"slot"!==a[o].name&&(i[a[o].name]=a[o].value,i[dt(a[o].name)]=a[o].value);for(o=s.length;o--;){var l=e(s[o],null),c=s[o].slot;c?i[c]=De(ft,{name:c},l):r[o]=l}var u=n?De(ft,null,r):r;return De(n||t.nodeName.toLowerCase(),i,u)}(this,this._vdomComponent)),(this.hasAttribute("hydrate")?it:rt)(this._vdom,this._root)}function dt(e){return e.replace(/-(\w)/g,(function(e,t){return t?t.toUpperCase():""}))}function pt(e,t,n){if(this._vdom){var r={};r[e]=n=null==n?void 0:n,r[dt(e)]=n,this._vdom=ot(this._vdom,r),rt(this._vdom,this._root)}}function ht(){rt(this._vdom=null,this._root)}function ft(e,t){var n=this;return De("slot",st({},e,{ref:function(e){e?(n.ref=e,n._listener||(n._listener=function(e){e.stopPropagation(),e.detail.context=t},e.addEventListener("_preact",n._listener))):n.ref.removeEventListener("_preact",n._listener)}}))}var vt,mt,gt,yt,_t=0,wt=[],bt=we,xt=bt.__b,kt=bt.__r,St=bt.diffed,Et=bt.__c,Ct=bt.unmount,Tt=bt.__;function Pt(e,t){bt.__h&&bt.__h(mt,e,_t||t),_t=0;var n=mt.__H||(mt.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function Rt(e){return _t=1,At(qt,e)}function At(e,t,n){var r=Pt(vt++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):qt(void 0,t),function(e){var t=r.__N?r.__N[0]:r.__[0],n=r.t(t,e);t!==n&&(r.__N=[n,r.__[1]],r.__c.setState({}))}],r.__c=mt,!mt.u)){var i=function(e,t,n){if(!r.__c.__H)return!0;var i=r.__c.__H.__.filter((function(e){return!!e.__c}));if(i.every((function(e){return!e.__N})))return!o||o.call(this,e,t,n);var a=!1;return i.forEach((function(e){if(e.__N){var t=e.__[0];e.__=e.__N,e.__N=void 0,t!==e.__[0]&&(a=!0)}})),!(!a&&r.__c.props===e)&&(!o||o.call(this,e,t,n))};mt.u=!0;var o=mt.shouldComponentUpdate,a=mt.componentWillUpdate;mt.componentWillUpdate=function(e,t,n){if(this.__e){var r=o;o=void 0,i(e,t,n),o=r}a&&a.call(this,e,t,n)},mt.shouldComponentUpdate=i}return r.__N||r.__}function Ot(e,t){var n=Pt(vt++,3);!bt.__s&&zt(n.__H,t)&&(n.__=e,n.i=t,mt.__H.__h.push(n))}function Lt(e,t){var n=Pt(vt++,4);!bt.__s&&zt(n.__H,t)&&(n.__=e,n.i=t,mt.__h.push(n))}function Mt(e){return _t=5,It((function(){return{current:e}}),[])}function Ft(e,t,n){_t=6,Lt((function(){return"function"==typeof e?(e(t()),function(){return e(null)}):e?(e.current=t(),function(){return e.current=null}):void 0}),null==n?n:n.concat(e))}function It(e,t){var n=Pt(vt++,7);return zt(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function Dt(e,t){return _t=8,It((function(){return e}),t)}function Gt(e){var t=mt.context[e.__c],n=Pt(vt++,9);return n.c=e,t?(null==n.__&&(n.__=!0,t.sub(mt)),t.props.value):e.__}function Nt(e,t){bt.useDebugValue&&bt.useDebugValue(t?t(e):e)}function $t(){var e=Pt(vt++,11);if(!e.__){for(var t=mt.__v;null!==t&&!t.__m&&null!==t.__;)t=t.__;var n=t.__m||(t.__m=[0,0]);e.__="P"+n[0]+"-"+n[1]++}return e.__}function Ht(){for(var e;e=wt.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(jt),e.__H.__h.forEach(Bt),e.__H.__h=[]}catch(yu){e.__H.__h=[],bt.__e(yu,e.__v)}}bt.__b=function(e){mt=null,xt&&xt(e)},bt.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Tt&&Tt(e,t)},bt.__r=function(e){kt&&kt(e),vt=0;var t=(mt=e.__c).__H;t&&(gt===mt?(t.__h=[],mt.__h=[],t.__.forEach((function(e){e.__N&&(e.__=e.__N),e.i=e.__N=void 0}))):(t.__h.forEach(jt),t.__h.forEach(Bt),t.__h=[],vt=0)),gt=mt},bt.diffed=function(e){St&&St(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(1!==wt.push(t)&&yt===bt.requestAnimationFrame||((yt=bt.requestAnimationFrame)||Ut)(Ht)),t.__H.__.forEach((function(e){e.i&&(e.__H=e.i),e.i=void 0}))),gt=mt=null},bt.__c=function(e,t){t.some((function(e){try{e.__h.forEach(jt),e.__h=e.__h.filter((function(e){return!e.__||Bt(e)}))}catch(eu){t.some((function(e){e.__h&&(e.__h=[])})),t=[],bt.__e(eu,e.__v)}})),Et&&Et(e,t)},bt.unmount=function(e){Ct&&Ct(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach((function(e){try{jt(e)}catch(n){t=n}})),n.__H=void 0,t&&bt.__e(t,n.__v))};var Wt="function"==typeof requestAnimationFrame;function Ut(e){var t,n=function(){clearTimeout(r),Wt&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);Wt&&(t=requestAnimationFrame(n))}function jt(e){var t=mt,n=e.__c;"function"==typeof n&&(e.__c=void 0,n()),mt=t}function Bt(e){var t=mt;e.__c=e.__(),mt=t}function zt(e,t){return!e||e.length!==t.length||t.some((function(t,n){return t!==e[n]}))}function qt(e,t){return"function"==typeof t?t(e):t}class Kt extends Error{}function Vt(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return function(e){return decodeURIComponent(atob(e).replace(/(.)/g,((e,t)=>{let n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(t)}catch(n){return atob(t)}}Kt.prototype.name="InvalidTokenError";class Qt{constructor(e){__publicField(this,"roles"),__publicField(this,"isAuthorized"),this.roles=e,this.isAuthorized=e.includes("SalaryPackaging.Access")}static create(e){const t=e?function(e,t){if("string"!=typeof e)throw new Kt("Invalid token specified: must be a string");t||(t={});const n=!0===t.header?0:1,r=e.split(".")[n];if("string"!=typeof r)throw new Kt(`Invalid token specified: missing part #${n+1}`);let i;try{i=Vt(r)}catch(Fc){throw new Kt(`Invalid token specified: invalid base64 for part #${n+1} (${Fc.message})`)}try{return JSON.parse(i)}catch(Fc){throw new Kt(`Invalid token specified: invalid json for part #${n+1} (${Fc.message})`)}}(e):{roles:[]};return new Qt(t.roles)}}var Yt=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Xt="undefined"==typeof window||"Deno"in globalThis;function Jt(){}function Zt(e){return"number"==typeof e&&e>=0&&e!==1/0}function en(e,t){return Math.max(e+(t||0)-Date.now(),0)}function tn(e,t){return"function"==typeof e?e(t):e}function nn(e,t){return"function"==typeof e?e(t):e}function rn(e,t){const{type:n="all",exact:r,fetchStatus:i,predicate:o,queryKey:a,stale:s}=e;if(a)if(r){if(t.queryHash!==an(a,t.options))return!1}else if(!ln(t.queryKey,a))return!1;if("all"!==n){const e=t.isActive();if("active"===n&&!e)return!1;if("inactive"===n&&e)return!1}return("boolean"!=typeof s||t.isStale()===s)&&((!i||i===t.state.fetchStatus)&&!(o&&!o(t)))}function on(e,t){const{exact:n,status:r,predicate:i,mutationKey:o}=e;if(o){if(!t.options.mutationKey)return!1;if(n){if(sn(t.options.mutationKey)!==sn(o))return!1}else if(!ln(t.options.mutationKey,o))return!1}return(!r||t.state.status===r)&&!(i&&!i(t))}function an(e,t){return((null==t?void 0:t.queryKeyHashFn)||sn)(e)}function sn(e){return JSON.stringify(e,((e,t)=>pn(t)?Object.keys(t).sort().reduce(((e,n)=>(e[n]=t[n],e)),{}):t))}function ln(e,t){return e===t||typeof e==typeof t&&(!(!e||!t||"object"!=typeof e||"object"!=typeof t)&&!Object.keys(t).some((n=>!ln(e[n],t[n]))))}function cn(e,t){if(e===t)return e;const n=dn(e)&&dn(t);if(n||pn(e)&&pn(t)){const r=n?e:Object.keys(e),i=r.length,o=n?t:Object.keys(t),a=o.length,s=n?[]:{};let l=0;for(let c=0;c<a;c++){const i=n?c:o[c];(!n&&r.includes(i)||n)&&void 0===e[i]&&void 0===t[i]?(s[i]=void 0,l++):(s[i]=cn(e[i],t[i]),s[i]===e[i]&&void 0!==e[i]&&l++)}return i===a&&l===i?e:s}return t}function un(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function dn(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function pn(e){if(!hn(e))return!1;const t=e.constructor;if(void 0===t)return!0;const n=t.prototype;return!!hn(n)&&(!!n.hasOwnProperty("isPrototypeOf")&&Object.getPrototypeOf(e)===Object.prototype)}function hn(e){return"[object Object]"===Object.prototype.toString.call(e)}function fn(e,t,n){return"function"==typeof n.structuralSharing?n.structuralSharing(e,t):!1!==n.structuralSharing?cn(e,t):t}function vn(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function mn(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var gn=Symbol();function yn(e,t){return!e.queryFn&&(null==t?void 0:t.initialPromise)?()=>t.initialPromise:e.queryFn&&e.queryFn!==gn?e.queryFn:()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`))}var _n=new(r=class extends Yt{constructor(){super(),__privateAdd(this,e),__privateAdd(this,t),__privateAdd(this,n),__privateSet(this,n,(e=>{if(!Xt&&window.addEventListener){const t=()=>e();return window.addEventListener("visibilitychange",t,!1),()=>{window.removeEventListener("visibilitychange",t)}}}))}onSubscribe(){__privateGet(this,t)||this.setEventListener(__privateGet(this,n))}onUnsubscribe(){var e;this.hasListeners()||(null==(e=__privateGet(this,t))||e.call(this),__privateSet(this,t,void 0))}setEventListener(e){var r;__privateSet(this,n,e),null==(r=__privateGet(this,t))||r.call(this),__privateSet(this,t,e((e=>{"boolean"==typeof e?this.setFocused(e):this.onFocus()})))}setFocused(t){__privateGet(this,e)!==t&&(__privateSet(this,e,t),this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach((t=>{t(e)}))}isFocused(){var t;return"boolean"==typeof __privateGet(this,e)?__privateGet(this,e):"hidden"!==(null==(t=globalThis.document)?void 0:t.visibilityState)}},e=new WeakMap,t=new WeakMap,n=new WeakMap,r),wn=new(s=class extends Yt{constructor(){super(),__privateAdd(this,i,!0),__privateAdd(this,o),__privateAdd(this,a),__privateSet(this,a,(e=>{if(!Xt&&window.addEventListener){const t=()=>e(!0),n=()=>e(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",t),window.removeEventListener("offline",n)}}}))}onSubscribe(){__privateGet(this,o)||this.setEventListener(__privateGet(this,a))}onUnsubscribe(){var e;this.hasListeners()||(null==(e=__privateGet(this,o))||e.call(this),__privateSet(this,o,void 0))}setEventListener(e){var t;__privateSet(this,a,e),null==(t=__privateGet(this,o))||t.call(this),__privateSet(this,o,e(this.setOnline.bind(this)))}setOnline(e){__privateGet(this,i)!==e&&(__privateSet(this,i,e),this.listeners.forEach((t=>{t(e)})))}isOnline(){return __privateGet(this,i)}},i=new WeakMap,o=new WeakMap,a=new WeakMap,s);function bn(){let e,t;const n=new Promise(((n,r)=>{e=n,t=r}));function r(e){Object.assign(n,e),delete n.resolve,delete n.reject}return n.status="pending",n.catch((()=>{})),n.resolve=t=>{r({status:"fulfilled",value:t}),e(t)},n.reject=e=>{r({status:"rejected",reason:e}),t(e)},n}function xn(e){return Math.min(1e3*2**e,3e4)}function kn(e){return"online"!==(e??"online")||wn.isOnline()}var Sn=class extends Error{constructor(e){super("CancelledError"),this.revert=null==e?void 0:e.revert,this.silent=null==e?void 0:e.silent}};function En(e){return e instanceof Sn}function Cn(e){let t,n=!1,r=0,i=!1;const o=bn(),a=()=>_n.isFocused()&&("always"===e.networkMode||wn.isOnline())&&e.canRun(),s=()=>kn(e.networkMode)&&e.canRun(),l=n=>{var r;i||(i=!0,null==(r=e.onSuccess)||r.call(e,n),null==t||t(),o.resolve(n))},c=n=>{var r;i||(i=!0,null==(r=e.onError)||r.call(e,n),null==t||t(),o.reject(n))},u=()=>new Promise((n=>{var r;t=e=>{(i||a())&&n(e)},null==(r=e.onPause)||r.call(e)})).then((()=>{var n;t=void 0,i||null==(n=e.onContinue)||n.call(e)})),d=()=>{if(i)return;let t;const o=0===r?e.initialPromise:void 0;try{t=o??e.fn()}catch(s){t=Promise.reject(s)}Promise.resolve(t).then(l).catch((t=>{var o;if(i)return;const s=e.retry??(Xt?0:3),l=e.retryDelay??xn,p="function"==typeof l?l(r,t):l,h=!0===s||"number"==typeof s&&r<s||"function"==typeof s&&s(r,t);var f;!n&&h?(r++,null==(o=e.onFail)||o.call(e,r,t),(f=p,new Promise((e=>{setTimeout(e,f)}))).then((()=>a()?void 0:u())).then((()=>{n?c(t):d()}))):c(t)}))};return{promise:o,cancel:t=>{var n;i||(c(new Sn(t)),null==(n=e.abort)||n.call(e))},continue:()=>(null==t||t(),o),cancelRetry:()=>{n=!0},continueRetry:()=>{n=!1},canStart:s,start:()=>(s()?d():u().then(d),o)}}var Tn=function(){let e=[],t=0,n=e=>{e()},r=e=>{e()},i=e=>setTimeout(e,0);const o=r=>{t?e.push(r):i((()=>{n(r)}))};return{batch:o=>{let a;t++;try{a=o()}finally{t--,t||(()=>{const t=e;e=[],t.length&&i((()=>{r((()=>{t.forEach((e=>{n(e)}))}))}))})()}return a},batchCalls:e=>(...t)=>{o((()=>{e(...t)}))},schedule:o,setNotifyFunction:e=>{n=e},setBatchNotifyFunction:e=>{r=e},setScheduler:e=>{i=e}}}(),Pn=(c=class{constructor(){__privateAdd(this,l)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Zt(this.gcTime)&&__privateSet(this,l,setTimeout((()=>{this.optionalRemove()}),this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Xt?1/0:3e5))}clearGcTimeout(){__privateGet(this,l)&&(clearTimeout(__privateGet(this,l)),__privateSet(this,l,void 0))}},l=new WeakMap,c),Rn=(y=class extends Pn{constructor(e){super(),__privateAdd(this,m),__privateAdd(this,u),__privateAdd(this,d),__privateAdd(this,p),__privateAdd(this,h),__privateAdd(this,f),__privateAdd(this,v),__privateSet(this,v,!1),__privateSet(this,f,e.defaultOptions),this.setOptions(e.options),this.observers=[],__privateSet(this,p,e.cache),this.queryKey=e.queryKey,this.queryHash=e.queryHash,__privateSet(this,u,function(e){const t="function"==typeof e.initialData?e.initialData():e.initialData,n=void 0!==t,r=n?"function"==typeof e.initialDataUpdatedAt?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}(this.options)),this.state=e.state??__privateGet(this,u),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var e;return null==(e=__privateGet(this,h))?void 0:e.promise}setOptions(e){this.options={...__privateGet(this,f),...e},this.updateGcTime(this.options.gcTime)}optionalRemove(){this.observers.length||"idle"!==this.state.fetchStatus||__privateGet(this,p).remove(this)}setData(e,t){const n=fn(this.state.data,e,this.options);return __privateMethod(this,m,g).call(this,{data:n,type:"success",dataUpdatedAt:null==t?void 0:t.updatedAt,manual:null==t?void 0:t.manual}),n}setState(e,t){__privateMethod(this,m,g).call(this,{type:"setState",state:e,setStateOptions:t})}cancel(e){var t,n;const r=null==(t=__privateGet(this,h))?void 0:t.promise;return null==(n=__privateGet(this,h))||n.cancel(e),r?r.then(Jt).catch(Jt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(__privateGet(this,u))}isActive(){return this.observers.some((e=>!1!==nn(e.options.enabled,this)))}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===gn||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return!!this.state.isInvalidated||(this.getObserversCount()>0?this.observers.some((e=>e.getCurrentResult().isStale)):void 0===this.state.data)}isStaleByTime(e=0){return this.state.isInvalidated||void 0===this.state.data||!en(this.state.dataUpdatedAt,e)}onFocus(){var e;const t=this.observers.find((e=>e.shouldFetchOnWindowFocus()));null==t||t.refetch({cancelRefetch:!1}),null==(e=__privateGet(this,h))||e.continue()}onOnline(){var e;const t=this.observers.find((e=>e.shouldFetchOnReconnect()));null==t||t.refetch({cancelRefetch:!1}),null==(e=__privateGet(this,h))||e.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),__privateGet(this,p).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter((t=>t!==e)),this.observers.length||(__privateGet(this,h)&&(__privateGet(this,v)?__privateGet(this,h).cancel({revert:!0}):__privateGet(this,h).cancelRetry()),this.scheduleGc()),__privateGet(this,p).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||__privateMethod(this,m,g).call(this,{type:"invalidate"})}fetch(e,t){var n,r,i;if("idle"!==this.state.fetchStatus)if(void 0!==this.state.data&&(null==t?void 0:t.cancelRefetch))this.cancel({silent:!0});else if(__privateGet(this,h))return __privateGet(this,h).continueRetry(),__privateGet(this,h).promise;if(e&&this.setOptions(e),!this.options.queryFn){const e=this.observers.find((e=>e.options.queryFn));e&&this.setOptions(e.options)}const o=new AbortController,a=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(__privateSet(this,v,!0),o.signal)})},s={fetchOptions:t,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>{const e=yn(this.options,t),n={queryKey:this.queryKey,meta:this.meta};return a(n),__privateSet(this,v,!1),this.options.persister?this.options.persister(e,n,this):e(n)}};a(s),null==(n=this.options.behavior)||n.onFetch(s,this),__privateSet(this,d,this.state),"idle"!==this.state.fetchStatus&&this.state.fetchMeta===(null==(r=s.fetchOptions)?void 0:r.meta)||__privateMethod(this,m,g).call(this,{type:"fetch",meta:null==(i=s.fetchOptions)?void 0:i.meta});const l=e=>{var t,n,r,i;En(e)&&e.silent||__privateMethod(this,m,g).call(this,{type:"error",error:e}),En(e)||(null==(n=(t=__privateGet(this,p).config).onError)||n.call(t,e,this),null==(i=(r=__privateGet(this,p).config).onSettled)||i.call(r,this.state.data,e,this)),this.scheduleGc()};return __privateSet(this,h,Cn({initialPromise:null==t?void 0:t.initialPromise,fn:s.fetchFn,abort:o.abort.bind(o),onSuccess:e=>{var t,n,r,i;if(void 0!==e){try{this.setData(e)}catch(o){return void l(o)}null==(n=(t=__privateGet(this,p).config).onSuccess)||n.call(t,e,this),null==(i=(r=__privateGet(this,p).config).onSettled)||i.call(r,e,this.state.error,this),this.scheduleGc()}else l(new Error(`${this.queryHash} data is undefined`))},onError:l,onFail:(e,t)=>{__privateMethod(this,m,g).call(this,{type:"failed",failureCount:e,error:t})},onPause:()=>{__privateMethod(this,m,g).call(this,{type:"pause"})},onContinue:()=>{__privateMethod(this,m,g).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0})),__privateGet(this,h).start()}},u=new WeakMap,d=new WeakMap,p=new WeakMap,h=new WeakMap,f=new WeakMap,v=new WeakMap,m=new WeakSet,g=function(e){this.state=(t=>{switch(e.type){case"failed":return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...t,fetchStatus:"paused"};case"continue":return{...t,fetchStatus:"fetching"};case"fetch":return{...t,...An(t.data,this.options),fetchMeta:e.meta??null};case"success":return{...t,data:e.data,dataUpdateCount:t.dataUpdateCount+1,dataUpdatedAt:e.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const n=e.error;return En(n)&&n.revert&&__privateGet(this,d)?{...__privateGet(this,d),fetchStatus:"idle"}:{...t,error:n,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:n,fetchStatus:"idle",status:"error"};case"invalidate":return{...t,isInvalidated:!0};case"setState":return{...t,...e.state}}})(this.state),Tn.batch((()=>{this.observers.forEach((e=>{e.onQueryUpdate()})),__privateGet(this,p).notify({query:this,type:"updated",action:e})}))},y);function An(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:kn(t.networkMode)?"fetching":"paused",...void 0===e&&{error:null,status:"pending"}}}var On=(w=class extends Yt{constructor(e={}){super(),__privateAdd(this,_),this.config=e,__privateSet(this,_,new Map)}build(e,t,n){const r=t.queryKey,i=t.queryHash??an(r,t);let o=this.get(i);return o||(o=new Rn({cache:this,queryKey:r,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(o)),o}add(e){__privateGet(this,_).has(e.queryHash)||(__privateGet(this,_).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const t=__privateGet(this,_).get(e.queryHash);t&&(e.destroy(),t===e&&__privateGet(this,_).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){Tn.batch((()=>{this.getAll().forEach((e=>{this.remove(e)}))}))}get(e){return __privateGet(this,_).get(e)}getAll(){return[...__privateGet(this,_).values()]}find(e){const t={exact:!0,...e};return this.getAll().find((e=>rn(t,e)))}findAll(e={}){const t=this.getAll();return Object.keys(e).length>0?t.filter((t=>rn(e,t))):t}notify(e){Tn.batch((()=>{this.listeners.forEach((t=>{t(e)}))}))}onFocus(){Tn.batch((()=>{this.getAll().forEach((e=>{e.onFocus()}))}))}onOnline(){Tn.batch((()=>{this.getAll().forEach((e=>{e.onOnline()}))}))}},_=new WeakMap,w),Ln=(C=class extends Pn{constructor(e){super(),__privateAdd(this,S),__privateAdd(this,b),__privateAdd(this,x),__privateAdd(this,k),this.mutationId=e.mutationId,__privateSet(this,x,e.mutationCache),__privateSet(this,b,[]),this.state=e.state||{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0},this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){__privateGet(this,b).includes(e)||(__privateGet(this,b).push(e),this.clearGcTimeout(),__privateGet(this,x).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){__privateSet(this,b,__privateGet(this,b).filter((t=>t!==e))),this.scheduleGc(),__privateGet(this,x).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){__privateGet(this,b).length||("pending"===this.state.status?this.scheduleGc():__privateGet(this,x).remove(this))}continue(){var e;return(null==(e=__privateGet(this,k))?void 0:e.continue())??this.execute(this.state.variables)}async execute(e){var t,n,r,i,o,a,s,l,c,u,d,p,h,f,v,m,g,y,_,w;__privateSet(this,k,Cn({fn:()=>this.options.mutationFn?this.options.mutationFn(e):Promise.reject(new Error("No mutationFn found")),onFail:(e,t)=>{__privateMethod(this,S,E).call(this,{type:"failed",failureCount:e,error:t})},onPause:()=>{__privateMethod(this,S,E).call(this,{type:"pause"})},onContinue:()=>{__privateMethod(this,S,E).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>__privateGet(this,x).canRun(this)}));const b="pending"===this.state.status,C=!__privateGet(this,k).canStart();try{if(!b){__privateMethod(this,S,E).call(this,{type:"pending",variables:e,isPaused:C}),await(null==(n=(t=__privateGet(this,x).config).onMutate)?void 0:n.call(t,e,this));const o=await(null==(i=(r=this.options).onMutate)?void 0:i.call(r,e));o!==this.state.context&&__privateMethod(this,S,E).call(this,{type:"pending",context:o,variables:e,isPaused:C})}const h=await __privateGet(this,k).start();return await(null==(a=(o=__privateGet(this,x).config).onSuccess)?void 0:a.call(o,h,e,this.state.context,this)),await(null==(l=(s=this.options).onSuccess)?void 0:l.call(s,h,e,this.state.context)),await(null==(u=(c=__privateGet(this,x).config).onSettled)?void 0:u.call(c,h,null,this.state.variables,this.state.context,this)),await(null==(p=(d=this.options).onSettled)?void 0:p.call(d,h,null,e,this.state.context)),__privateMethod(this,S,E).call(this,{type:"success",data:h}),h}catch(T){try{throw await(null==(f=(h=__privateGet(this,x).config).onError)?void 0:f.call(h,T,e,this.state.context,this)),await(null==(m=(v=this.options).onError)?void 0:m.call(v,T,e,this.state.context)),await(null==(y=(g=__privateGet(this,x).config).onSettled)?void 0:y.call(g,void 0,T,this.state.variables,this.state.context,this)),await(null==(w=(_=this.options).onSettled)?void 0:w.call(_,void 0,T,e,this.state.context)),T}finally{__privateMethod(this,S,E).call(this,{type:"error",error:T})}}finally{__privateGet(this,x).runNext(this)}}},b=new WeakMap,x=new WeakMap,k=new WeakMap,S=new WeakSet,E=function(e){this.state=(t=>{switch(e.type){case"failed":return{...t,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...t,isPaused:!0};case"continue":return{...t,isPaused:!1};case"pending":return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}})(this.state),Tn.batch((()=>{__privateGet(this,b).forEach((t=>{t.onMutationUpdate(e)})),__privateGet(this,x).notify({mutation:this,type:"updated",action:e})}))},C);var Mn=(R=class extends Yt{constructor(e={}){super(),__privateAdd(this,T),__privateAdd(this,P),this.config=e,__privateSet(this,T,new Map),__privateSet(this,P,Date.now())}build(e,t,n){const r=new Ln({mutationCache:this,mutationId:++__privateWrapper(this,P)._,options:e.defaultMutationOptions(t),state:n});return this.add(r),r}add(e){const t=Fn(e),n=__privateGet(this,T).get(t)??[];n.push(e),__privateGet(this,T).set(t,n),this.notify({type:"added",mutation:e})}remove(e){var t;const n=Fn(e);if(__privateGet(this,T).has(n)){const r=null==(t=__privateGet(this,T).get(n))?void 0:t.filter((t=>t!==e));r&&(0===r.length?__privateGet(this,T).delete(n):__privateGet(this,T).set(n,r))}this.notify({type:"removed",mutation:e})}canRun(e){var t;const n=null==(t=__privateGet(this,T).get(Fn(e)))?void 0:t.find((e=>"pending"===e.state.status));return!n||n===e}runNext(e){var t;const n=null==(t=__privateGet(this,T).get(Fn(e)))?void 0:t.find((t=>t!==e&&t.state.isPaused));return(null==n?void 0:n.continue())??Promise.resolve()}clear(){Tn.batch((()=>{this.getAll().forEach((e=>{this.remove(e)}))}))}getAll(){return[...__privateGet(this,T).values()].flat()}find(e){const t={exact:!0,...e};return this.getAll().find((e=>on(t,e)))}findAll(e={}){return this.getAll().filter((t=>on(e,t)))}notify(e){Tn.batch((()=>{this.listeners.forEach((t=>{t(e)}))}))}resumePausedMutations(){const e=this.getAll().filter((e=>e.state.isPaused));return Tn.batch((()=>Promise.all(e.map((e=>e.continue().catch(Jt))))))}},T=new WeakMap,P=new WeakMap,R);function Fn(e){var t;return(null==(t=e.options.scope)?void 0:t.id)??String(e.mutationId)}function In(e){return{onFetch:(t,n)=>{var r,i,o,a,s;const l=t.options,c=null==(o=null==(i=null==(r=t.fetchOptions)?void 0:r.meta)?void 0:i.fetchMore)?void 0:o.direction,u=(null==(a=t.state.data)?void 0:a.pages)||[],d=(null==(s=t.state.data)?void 0:s.pageParams)||[];let p={pages:[],pageParams:[]},h=0;const f=async()=>{let n=!1;const r=yn(t.options,t.fetchOptions),i=async(e,i,o)=>{if(n)return Promise.reject();if(null==i&&e.pages.length)return Promise.resolve(e);const a={queryKey:t.queryKey,pageParam:i,direction:o?"backward":"forward",meta:t.options.meta};var s;s=a,Object.defineProperty(s,"signal",{enumerable:!0,get:()=>(t.signal.aborted?n=!0:t.signal.addEventListener("abort",(()=>{n=!0})),t.signal)});const l=await r(a),{maxPages:c}=t.options,u=o?mn:vn;return{pages:u(e.pages,l,c),pageParams:u(e.pageParams,i,c)}};if(c&&u.length){const e="backward"===c,t={pages:u,pageParams:d},n=(e?Gn:Dn)(l,t);p=await i(t,n,e)}else{const t=e??u.length;do{const e=0===h?d[0]??l.initialPageParam:Dn(l,p);if(h>0&&null==e)break;p=await i(p,e),h++}while(h<t)}return p};t.options.persister?t.fetchFn=()=>{var e,r;return null==(r=(e=t.options).persister)?void 0:r.call(e,f,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=f}}}function Dn(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function Gn(e,{pages:t,pageParams:n}){var r;return t.length>0?null==(r=e.getPreviousPageParam)?void 0:r.call(e,t[0],t,n[0],n):void 0}var Nn=(N=class{constructor(e={}){__privateAdd(this,A),__privateAdd(this,O),__privateAdd(this,L),__privateAdd(this,M),__privateAdd(this,F),__privateAdd(this,I),__privateAdd(this,D),__privateAdd(this,G),__privateSet(this,A,e.queryCache||new On),__privateSet(this,O,e.mutationCache||new Mn),__privateSet(this,L,e.defaultOptions||{}),__privateSet(this,M,new Map),__privateSet(this,F,new Map),__privateSet(this,I,0)}mount(){__privateWrapper(this,I)._++,1===__privateGet(this,I)&&(__privateSet(this,D,_n.subscribe((async e=>{e&&(await this.resumePausedMutations(),__privateGet(this,A).onFocus())}))),__privateSet(this,G,wn.subscribe((async e=>{e&&(await this.resumePausedMutations(),__privateGet(this,A).onOnline())}))))}unmount(){var e,t;__privateWrapper(this,I)._--,0===__privateGet(this,I)&&(null==(e=__privateGet(this,D))||e.call(this),__privateSet(this,D,void 0),null==(t=__privateGet(this,G))||t.call(this),__privateSet(this,G,void 0))}isFetching(e){return __privateGet(this,A).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return __privateGet(this,O).findAll({...e,status:"pending"}).length}getQueryData(e){var t;const n=this.defaultQueryOptions({queryKey:e});return null==(t=__privateGet(this,A).get(n.queryHash))?void 0:t.state.data}ensureQueryData(e){const t=this.getQueryData(e.queryKey);if(void 0===t)return this.fetchQuery(e);{const n=this.defaultQueryOptions(e),r=__privateGet(this,A).build(this,n);return e.revalidateIfStale&&r.isStaleByTime(tn(n.staleTime,r))&&this.prefetchQuery(n),Promise.resolve(t)}}getQueriesData(e){return __privateGet(this,A).findAll(e).map((({queryKey:e,state:t})=>[e,t.data]))}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),i=__privateGet(this,A).get(r.queryHash),o=function(e,t){return"function"==typeof e?e(t):e}(t,null==i?void 0:i.state.data);if(void 0!==o)return __privateGet(this,A).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(e,t,n){return Tn.batch((()=>__privateGet(this,A).findAll(e).map((({queryKey:e})=>[e,this.setQueryData(e,t,n)]))))}getQueryState(e){var t;const n=this.defaultQueryOptions({queryKey:e});return null==(t=__privateGet(this,A).get(n.queryHash))?void 0:t.state}removeQueries(e){const t=__privateGet(this,A);Tn.batch((()=>{t.findAll(e).forEach((e=>{t.remove(e)}))}))}resetQueries(e,t){const n=__privateGet(this,A),r={type:"active",...e};return Tn.batch((()=>(n.findAll(e).forEach((e=>{e.reset()})),this.refetchQueries(r,t))))}cancelQueries(e={},t={}){const n={revert:!0,...t},r=Tn.batch((()=>__privateGet(this,A).findAll(e).map((e=>e.cancel(n)))));return Promise.all(r).then(Jt).catch(Jt)}invalidateQueries(e={},t={}){return Tn.batch((()=>{if(__privateGet(this,A).findAll(e).forEach((e=>{e.invalidate()})),"none"===e.refetchType)return Promise.resolve();const n={...e,type:e.refetchType??e.type??"active"};return this.refetchQueries(n,t)}))}refetchQueries(e={},t){const n={...t,cancelRefetch:(null==t?void 0:t.cancelRefetch)??!0},r=Tn.batch((()=>__privateGet(this,A).findAll(e).filter((e=>!e.isDisabled())).map((e=>{let t=e.fetch(void 0,n);return n.throwOnError||(t=t.catch(Jt)),"paused"===e.state.fetchStatus?Promise.resolve():t}))));return Promise.all(r).then(Jt)}fetchQuery(e){const t=this.defaultQueryOptions(e);void 0===t.retry&&(t.retry=!1);const n=__privateGet(this,A).build(this,t);return n.isStaleByTime(tn(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Jt).catch(Jt)}fetchInfiniteQuery(e){return e.behavior=In(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Jt).catch(Jt)}ensureInfiniteQueryData(e){return e.behavior=In(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return wn.isOnline()?__privateGet(this,O).resumePausedMutations():Promise.resolve()}getQueryCache(){return __privateGet(this,A)}getMutationCache(){return __privateGet(this,O)}getDefaultOptions(){return __privateGet(this,L)}setDefaultOptions(e){__privateSet(this,L,e)}setQueryDefaults(e,t){__privateGet(this,M).set(sn(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...__privateGet(this,M).values()];let n={};return t.forEach((t=>{ln(e,t.queryKey)&&(n={...n,...t.defaultOptions})})),n}setMutationDefaults(e,t){__privateGet(this,F).set(sn(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...__privateGet(this,F).values()];let n={};return t.forEach((t=>{ln(e,t.mutationKey)&&(n={...n,...t.defaultOptions})})),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...__privateGet(this,L).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=an(t.queryKey,t)),void 0===t.refetchOnReconnect&&(t.refetchOnReconnect="always"!==t.networkMode),void 0===t.throwOnError&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),!0!==t.enabled&&t.queryFn===gn&&(t.enabled=!1),t}defaultMutationOptions(e){return(null==e?void 0:e._defaulted)?e:{...__privateGet(this,L).mutations,...(null==e?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){__privateGet(this,A).clear(),__privateGet(this,O).clear()}},A=new WeakMap,O=new WeakMap,L=new WeakMap,M=new WeakMap,F=new WeakMap,I=new WeakMap,D=new WeakMap,G=new WeakMap,N),$n=(ue=class extends Yt{constructor(e,t){super(),__privateAdd(this,ee),__privateAdd(this,$),__privateAdd(this,H),__privateAdd(this,W),__privateAdd(this,U),__privateAdd(this,j),__privateAdd(this,B),__privateAdd(this,z),__privateAdd(this,q),__privateAdd(this,K),__privateAdd(this,V),__privateAdd(this,Q),__privateAdd(this,Y),__privateAdd(this,X),__privateAdd(this,J),__privateAdd(this,Z,new Set),this.options=t,__privateSet(this,$,e),__privateSet(this,q,null),__privateSet(this,z,bn()),this.options.experimental_prefetchInRender||__privateGet(this,z).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(t)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(__privateGet(this,H).addObserver(this),Hn(__privateGet(this,H),this.options)?__privateMethod(this,ee,te).call(this):this.updateResult(),__privateMethod(this,ee,oe).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Wn(__privateGet(this,H),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Wn(__privateGet(this,H),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,__privateMethod(this,ee,ae).call(this),__privateMethod(this,ee,se).call(this),__privateGet(this,H).removeObserver(this)}setOptions(e,t){const n=this.options,r=__privateGet(this,H);if(this.options=__privateGet(this,$).defaultQueryOptions(e),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled&&"function"!=typeof this.options.enabled&&"boolean"!=typeof nn(this.options.enabled,__privateGet(this,H)))throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");__privateMethod(this,ee,le).call(this),__privateGet(this,H).setOptions(this.options),n._defaulted&&!un(this.options,n)&&__privateGet(this,$).getQueryCache().notify({type:"observerOptionsUpdated",query:__privateGet(this,H),observer:this});const i=this.hasListeners();i&&Un(__privateGet(this,H),r,this.options,n)&&__privateMethod(this,ee,te).call(this),this.updateResult(t),!i||__privateGet(this,H)===r&&nn(this.options.enabled,__privateGet(this,H))===nn(n.enabled,__privateGet(this,H))&&tn(this.options.staleTime,__privateGet(this,H))===tn(n.staleTime,__privateGet(this,H))||__privateMethod(this,ee,ne).call(this);const o=__privateMethod(this,ee,re).call(this);!i||__privateGet(this,H)===r&&nn(this.options.enabled,__privateGet(this,H))===nn(n.enabled,__privateGet(this,H))&&o===__privateGet(this,J)||__privateMethod(this,ee,ie).call(this,o)}getOptimisticResult(e){const t=__privateGet(this,$).getQueryCache().build(__privateGet(this,$),e),n=this.createResult(t,e);return function(e,t){if(!un(e.getCurrentResult(),t))return!0;return!1}(this,n)&&(__privateSet(this,U,n),__privateSet(this,B,this.options),__privateSet(this,j,__privateGet(this,H).state)),n}getCurrentResult(){return __privateGet(this,U)}trackResult(e,t){const n={};return Object.keys(e).forEach((r=>{Object.defineProperty(n,r,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(r),null==t||t(r),e[r])})})),n}trackProp(e){__privateGet(this,Z).add(e)}getCurrentQuery(){return __privateGet(this,H)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const t=__privateGet(this,$).defaultQueryOptions(e),n=__privateGet(this,$).getQueryCache().build(__privateGet(this,$),t);return n.fetch().then((()=>this.createResult(n,t)))}fetch(e){return __privateMethod(this,ee,te).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then((()=>(this.updateResult(),__privateGet(this,U))))}createResult(e,t){var n;const r=__privateGet(this,H),i=this.options,o=__privateGet(this,U),a=__privateGet(this,j),s=__privateGet(this,B),l=e!==r?e.state:__privateGet(this,W),{state:c}=e;let u,d={...c},p=!1;if(t._optimisticResults){const n=this.hasListeners(),o=!n&&Hn(e,t),a=n&&Un(e,r,t,i);(o||a)&&(d={...d,...An(c.data,e.options)}),"isRestoring"===t._optimisticResults&&(d.fetchStatus="idle")}let{error:h,errorUpdatedAt:f,status:v}=d;if(t.select&&void 0!==d.data)if(o&&d.data===(null==a?void 0:a.data)&&t.select===__privateGet(this,K))u=__privateGet(this,V);else try{__privateSet(this,K,t.select),u=t.select(d.data),u=fn(null==o?void 0:o.data,u,t),__privateSet(this,V,u),__privateSet(this,q,null)}catch(x){__privateSet(this,q,x)}else u=d.data;if(void 0!==t.placeholderData&&void 0===u&&"pending"===v){let e;if((null==o?void 0:o.isPlaceholderData)&&t.placeholderData===(null==s?void 0:s.placeholderData))e=o.data;else if(e="function"==typeof t.placeholderData?t.placeholderData(null==(n=__privateGet(this,Q))?void 0:n.state.data,__privateGet(this,Q)):t.placeholderData,t.select&&void 0!==e)try{e=t.select(e),__privateSet(this,q,null)}catch(x){__privateSet(this,q,x)}void 0!==e&&(v="success",u=fn(null==o?void 0:o.data,e,t),p=!0)}__privateGet(this,q)&&(h=__privateGet(this,q),u=__privateGet(this,V),f=Date.now(),v="error");const m="fetching"===d.fetchStatus,g="pending"===v,y="error"===v,_=g&&m,w=void 0!==u,b={status:v,fetchStatus:d.fetchStatus,isPending:g,isSuccess:"success"===v,isError:y,isInitialLoading:_,isLoading:_,data:u,dataUpdatedAt:d.dataUpdatedAt,error:h,errorUpdatedAt:f,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>l.dataUpdateCount||d.errorUpdateCount>l.errorUpdateCount,isFetching:m,isRefetching:m&&!g,isLoadingError:y&&!w,isPaused:"paused"===d.fetchStatus,isPlaceholderData:p,isRefetchError:y&&w,isStale:jn(e,t),refetch:this.refetch,promise:__privateGet(this,z)};if(this.options.experimental_prefetchInRender){const t=e=>{"error"===b.status?e.reject(b.error):void 0!==b.data&&e.resolve(b.data)},n=()=>{const e=__privateSet(this,z,b.promise=bn());t(e)},i=__privateGet(this,z);switch(i.status){case"pending":e.queryHash===r.queryHash&&t(i);break;case"fulfilled":"error"!==b.status&&b.data===i.value||n();break;case"rejected":"error"===b.status&&b.error===i.reason||n()}}return b}updateResult(e){const t=__privateGet(this,U),n=this.createResult(__privateGet(this,H),this.options);if(__privateSet(this,j,__privateGet(this,H).state),__privateSet(this,B,this.options),void 0!==__privateGet(this,j).data&&__privateSet(this,Q,__privateGet(this,H)),un(n,t))return;__privateSet(this,U,n);const r={};!1!==(null==e?void 0:e.listeners)&&(()=>{if(!t)return!0;const{notifyOnChangeProps:e}=this.options,n="function"==typeof e?e():e;if("all"===n||!n&&!__privateGet(this,Z).size)return!0;const r=new Set(n??__privateGet(this,Z));return this.options.throwOnError&&r.add("error"),Object.keys(__privateGet(this,U)).some((e=>{const n=e;return __privateGet(this,U)[n]!==t[n]&&r.has(n)}))})()&&(r.listeners=!0),__privateMethod(this,ee,ce).call(this,{...r,...e})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&__privateMethod(this,ee,oe).call(this)}},$=new WeakMap,H=new WeakMap,W=new WeakMap,U=new WeakMap,j=new WeakMap,B=new WeakMap,z=new WeakMap,q=new WeakMap,K=new WeakMap,V=new WeakMap,Q=new WeakMap,Y=new WeakMap,X=new WeakMap,J=new WeakMap,Z=new WeakMap,ee=new WeakSet,te=function(e){__privateMethod(this,ee,le).call(this);let t=__privateGet(this,H).fetch(this.options,e);return(null==e?void 0:e.throwOnError)||(t=t.catch(Jt)),t},ne=function(){__privateMethod(this,ee,ae).call(this);const e=tn(this.options.staleTime,__privateGet(this,H));if(Xt||__privateGet(this,U).isStale||!Zt(e))return;const t=en(__privateGet(this,U).dataUpdatedAt,e);__privateSet(this,Y,setTimeout((()=>{__privateGet(this,U).isStale||this.updateResult()}),t+1))},re=function(){return("function"==typeof this.options.refetchInterval?this.options.refetchInterval(__privateGet(this,H)):this.options.refetchInterval)??!1},ie=function(e){__privateMethod(this,ee,se).call(this),__privateSet(this,J,e),!Xt&&!1!==nn(this.options.enabled,__privateGet(this,H))&&Zt(__privateGet(this,J))&&0!==__privateGet(this,J)&&__privateSet(this,X,setInterval((()=>{(this.options.refetchIntervalInBackground||_n.isFocused())&&__privateMethod(this,ee,te).call(this)}),__privateGet(this,J)))},oe=function(){__privateMethod(this,ee,ne).call(this),__privateMethod(this,ee,ie).call(this,__privateMethod(this,ee,re).call(this))},ae=function(){__privateGet(this,Y)&&(clearTimeout(__privateGet(this,Y)),__privateSet(this,Y,void 0))},se=function(){__privateGet(this,X)&&(clearInterval(__privateGet(this,X)),__privateSet(this,X,void 0))},le=function(){const e=__privateGet(this,$).getQueryCache().build(__privateGet(this,$),this.options);if(e===__privateGet(this,H))return;const t=__privateGet(this,H);__privateSet(this,H,e),__privateSet(this,W,e.state),this.hasListeners()&&(null==t||t.removeObserver(this),e.addObserver(this))},ce=function(e){Tn.batch((()=>{e.listeners&&this.listeners.forEach((e=>{e(__privateGet(this,U))})),__privateGet(this,$).getQueryCache().notify({query:__privateGet(this,H),type:"observerResultsUpdated"})}))},ue);function Hn(e,t){return function(e,t){return!1!==nn(t.enabled,e)&&void 0===e.state.data&&!("error"===e.state.status&&!1===t.retryOnMount)}(e,t)||void 0!==e.state.data&&Wn(e,t,t.refetchOnMount)}function Wn(e,t,n){if(!1!==nn(t.enabled,e)){const r="function"==typeof n?n(e):n;return"always"===r||!1!==r&&jn(e,t)}return!1}function Un(e,t,n,r){return(e!==t||!1===nn(r.enabled,e))&&(!n.suspense||"error"!==e.state.status)&&jn(e,n)}function jn(e,t){return!1!==nn(t.enabled,e)&&e.isStaleByTime(tn(t.staleTime,e))}var Bn=(ye=class extends Yt{constructor(e,t){super(),__privateAdd(this,ve),__privateAdd(this,de),__privateAdd(this,pe),__privateAdd(this,he),__privateAdd(this,fe),__privateSet(this,de,e),this.setOptions(t),this.bindMethods(),__privateMethod(this,ve,me).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){var t;const n=this.options;this.options=__privateGet(this,de).defaultMutationOptions(e),un(this.options,n)||__privateGet(this,de).getMutationCache().notify({type:"observerOptionsUpdated",mutation:__privateGet(this,he),observer:this}),(null==n?void 0:n.mutationKey)&&this.options.mutationKey&&sn(n.mutationKey)!==sn(this.options.mutationKey)?this.reset():"pending"===(null==(t=__privateGet(this,he))?void 0:t.state.status)&&__privateGet(this,he).setOptions(this.options)}onUnsubscribe(){var e;this.hasListeners()||null==(e=__privateGet(this,he))||e.removeObserver(this)}onMutationUpdate(e){__privateMethod(this,ve,me).call(this),__privateMethod(this,ve,ge).call(this,e)}getCurrentResult(){return __privateGet(this,pe)}reset(){var e;null==(e=__privateGet(this,he))||e.removeObserver(this),__privateSet(this,he,void 0),__privateMethod(this,ve,me).call(this),__privateMethod(this,ve,ge).call(this)}mutate(e,t){var n;return __privateSet(this,fe,t),null==(n=__privateGet(this,he))||n.removeObserver(this),__privateSet(this,he,__privateGet(this,de).getMutationCache().build(__privateGet(this,de),this.options)),__privateGet(this,he).addObserver(this),__privateGet(this,he).execute(e)}},de=new WeakMap,pe=new WeakMap,he=new WeakMap,fe=new WeakMap,ve=new WeakSet,me=function(){var e;const t=(null==(e=__privateGet(this,he))?void 0:e.state)??{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0};__privateSet(this,pe,{...t,isPending:"pending"===t.status,isSuccess:"success"===t.status,isError:"error"===t.status,isIdle:"idle"===t.status,mutate:this.mutate,reset:this.reset})},ge=function(e){Tn.batch((()=>{var t,n,r,i,o,a,s,l;if(__privateGet(this,fe)&&this.hasListeners()){const c=__privateGet(this,pe).variables,u=__privateGet(this,pe).context;"success"===(null==e?void 0:e.type)?(null==(n=(t=__privateGet(this,fe)).onSuccess)||n.call(t,e.data,c,u),null==(i=(r=__privateGet(this,fe)).onSettled)||i.call(r,e.data,null,c,u)):"error"===(null==e?void 0:e.type)&&(null==(a=(o=__privateGet(this,fe)).onError)||a.call(o,e.error,c,u),null==(l=(s=__privateGet(this,fe)).onSettled)||l.call(s,void 0,e.error,c,u))}this.listeners.forEach((e=>{e(__privateGet(this,pe))}))}))},ye);function zn(e,t){for(var n in e)if("__source"!==n&&!(n in t))return!0;for(var r in t)if("__source"!==r&&e[r]!==t[r])return!0;return!1}function qn(e,t){this.props=e,this.context=t}function Kn(e,t){function n(e){var n=this.props.ref,r=n==e.ref;return!r&&n&&(n.call?n(null):n.current=null),t?!t(this.props,e)||!r:zn(this.props,e)}function r(t){return this.shouldComponentUpdate=n,De(e,t)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(qn.prototype=new He).isPureReactComponent=!0,qn.prototype.shouldComponentUpdate=function(e,t){return zn(this.props,e)||zn(this.state,t)};var Vn=we.__b;we.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),Vn&&Vn(e)};var Qn="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function Yn(e){function t(t){if(!("ref"in t))return e(t,null);var n=t.ref;delete t.ref;var r=e(t,n);return t.ref=n,r}return t.$$typeof=Qn,t.render=t,t.prototype.isReactComponent=t.__f=!0,t.displayName="ForwardRef("+(e.displayName||e.name)+")",t}var Xn=function(e,t){return null==e?null:Ke(Ke(e).map(t))},Jn={map:Xn,forEach:Xn,count:function(e){return e?Ke(e).length:0},only:function(e){var t=Ke(e);if(1!==t.length)throw"Children.only";return t[0]},toArray:Ke},Zn=we.__e;we.__e=function(e,t,n,r){if(e.then)for(var i,o=t;o=o.__;)if((i=o.__c)&&i.__c)return null==t.__e&&(t.__e=n.__e,t.__k=n.__k),i.__c(e,t);Zn(e,t,n,r)};var er=we.unmount;function tr(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach((function(e){"function"==typeof e.__c&&e.__c()})),e.__c.__H=null),null!=(e=function(e,t){for(var n in t)e[n]=t[n];return e}({},e)).__c&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map((function(e){return tr(e,t,n)}))),e}function nr(e,t,n){return e&&n&&(e.__v=null,e.__k=e.__k&&e.__k.map((function(e){return nr(e,t,n)})),e.__c&&e.__c.__P===t&&(e.__e&&n.appendChild(e.__e),e.__c.__e=!0,e.__c.__P=n)),e}function rr(){this.__u=0,this.t=null,this.__b=null}function ir(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function or(e){var t,n,r;function i(i){if(t||(t=e()).then((function(e){n=e.default||e}),(function(e){r=e})),r)throw r;if(!n)throw t;return De(n,i)}return i.displayName="Lazy",i.__f=!0,i}function ar(){this.u=null,this.o=null}we.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&32&e.__u&&(e.type=null),er&&er(e)},(rr.prototype=new He).__c=function(e,t){var n=t.__c,r=this;null==r.t&&(r.t=[]),r.t.push(n);var i=ir(r.__v),o=!1,a=function(){o||(o=!0,n.__R=null,i?i(s):s())};n.__R=a;var s=function(){if(! --r.__u){if(r.state.__a){var e=r.state.__a;r.__v.__k[0]=nr(e,e.__c.__P,e.__c.__O)}var t;for(r.setState({__a:r.__b=null});t=r.t.pop();)t.forceUpdate()}};r.__u++||32&t.__u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(a,a)},rr.prototype.componentWillUnmount=function(){this.t=[]},rr.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=tr(this.__b,n,r.__O=r.__P)}this.__b=null}var i=t.__a&&De($e,null,e.fallback);return i&&(i.__u&=-33),[De($e,null,t.__a?null:e.children),i]};var sr=function(e,t,n){if(++n[1]===n[0]&&e.o.delete(t),e.props.revealOrder&&("t"!==e.props.revealOrder[0]||!e.o.size))for(n=e.u;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.u=n=n[2]}};function lr(e){return this.getChildContext=function(){return e.context},e.children}function cr(e){var t=this,n=e.i;t.componentWillUnmount=function(){rt(null,t.l),t.l=null,t.i=null},t.i&&t.i!==n&&t.componentWillUnmount(),t.l||(t.i=n,t.l={nodeType:1,parentNode:n,childNodes:[],contains:function(){return!0},appendChild:function(e){this.childNodes.push(e),t.i.appendChild(e)},insertBefore:function(e,n){this.childNodes.push(e),t.i.appendChild(e)},removeChild:function(e){this.childNodes.splice(this.childNodes.indexOf(e)>>>1,1),t.i.removeChild(e)}}),rt(De(lr,{context:t.context},e.__v),t.l)}function ur(e,t){var n=De(cr,{__v:e,i:t});return n.containerInfo=t,n}(ar.prototype=new He).__a=function(e){var t=this,n=ir(t.__v),r=t.o.get(e);return r[0]++,function(i){var o=function(){t.props.revealOrder?(r.push(i),sr(t,e,r)):i()};n?n(o):o()}},ar.prototype.render=function(e){this.u=null,this.o=new Map;var t=Ke(e.children);e.revealOrder&&"b"===e.revealOrder[0]&&t.reverse();for(var n=t.length;n--;)this.o.set(t[n],this.u=[1,0,this.u]);return e.children},ar.prototype.componentDidUpdate=ar.prototype.componentDidMount=function(){var e=this;this.o.forEach((function(t,n){sr(e,n,t)}))};var dr="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,pr=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,hr=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,fr=/[A-Z0-9]/g,vr="undefined"!=typeof document,mr=function(e){return("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(e)};function gr(e,t,n){return null==t.__k&&(t.textContent=""),rt(e,t),"function"==typeof n&&n(),e?e.__c:null}function yr(e,t,n){return it(e,t),"function"==typeof n&&n(),e?e.__c:null}He.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach((function(e){Object.defineProperty(He.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})}));var _r=we.event;function wr(){}function br(){return this.cancelBubble}function xr(){return this.defaultPrevented}we.event=function(e){return _r&&(e=_r(e)),e.persist=wr,e.isPropagationStopped=br,e.isDefaultPrevented=xr,e.nativeEvent=e};var kr,Sr={enumerable:!1,configurable:!0,get:function(){return this.class}},Er=we.vnode;we.vnode=function(e){"string"==typeof e.type&&function(e){var t=e.props,n=e.type,r={},i=-1===n.indexOf("-");for(var o in t){var a=t[o];if(!("value"===o&&"defaultValue"in t&&null==a||vr&&"children"===o&&"noscript"===n||"class"===o||"className"===o)){var s=o.toLowerCase();"defaultValue"===o&&"value"in t&&null==t.value?o="value":"download"===o&&!0===a?a="":"translate"===s&&"no"===a?a=!1:"o"===s[0]&&"n"===s[1]?"ondoubleclick"===s?o="ondblclick":"onchange"!==s||"input"!==n&&"textarea"!==n||mr(t.type)?"onfocus"===s?o="onfocusin":"onblur"===s?o="onfocusout":hr.test(o)&&(o=s):s=o="oninput":i&&pr.test(o)?o=o.replace(fr,"-$&").toLowerCase():null===a&&(a=void 0),"oninput"===s&&r[o=s]&&(o="oninputCapture"),r[o]=a}}"select"==n&&r.multiple&&Array.isArray(r.value)&&(r.value=Ke(t.children).forEach((function(e){e.props.selected=-1!=r.value.indexOf(e.props.value)}))),"select"==n&&null!=r.defaultValue&&(r.value=Ke(t.children).forEach((function(e){e.props.selected=r.multiple?-1!=r.defaultValue.indexOf(e.props.value):r.defaultValue==e.props.value}))),t.class&&!t.className?(r.class=t.class,Object.defineProperty(r,"className",Sr)):(t.className&&!t.class||t.class&&t.className)&&(r.class=r.className=t.className),e.props=r}(e),e.$$typeof=dr,Er&&Er(e)};var Cr=we.__r;we.__r=function(e){Cr&&Cr(e),kr=e.__c};var Tr=we.diffed;we.diffed=function(e){Tr&&Tr(e);var t=e.props,n=e.__e;null!=n&&"textarea"===e.type&&"value"in t&&t.value!==n.value&&(n.value=null==t.value?"":t.value),kr=null};var Pr={ReactCurrentDispatcher:{current:{readContext:function(e){return kr.__n[e.__c].props.value},useCallback:Dt,useContext:Gt,useDebugValue:Nt,useDeferredValue:Hr,useEffect:Ot,useId:$t,useImperativeHandle:Ft,useInsertionEffect:Ur,useLayoutEffect:Lt,useMemo:It,useReducer:At,useRef:Mt,useState:Rt,useSyncExternalStore:Br,useTransition:Wr}}};function Rr(e){return De.bind(null,e)}function Ar(e){return!!e&&e.$$typeof===dr}function Or(e){return Ar(e)&&e.type===$e}function Lr(e){return!!e&&!!e.displayName&&("string"==typeof e.displayName||e.displayName instanceof String)&&e.displayName.startsWith("Memo(")}function Mr(e){return Ar(e)?ot.apply(null,arguments):e}function Fr(e){return!!e.__k&&(rt(null,e),!0)}function Ir(e){return e&&(e.base||1===e.nodeType&&e)||null}var Dr=function(e,t){return e(t)},Gr=function(e,t){return e(t)},Nr=$e;function $r(e){e()}function Hr(e){return e}function Wr(){return[!1,$r]}var Ur=Lt,jr=Ar;function Br(e,t){var n=t(),r=Rt({h:{__:n,v:t}}),i=r[0].h,o=r[1];return Lt((function(){i.__=n,i.v=t,zr(i)&&o({h:i})}),[e,n,t]),Ot((function(){return zr(i)&&o({h:i}),e((function(){zr(i)&&o({h:i})}))}),[e]),n}function zr(e){var t,n,r=e.v,i=e.__;try{var o=r();return!((t=i)===(n=o)&&(0!==t||1/t==1/n)||t!=t&&n!=n)}catch(a){return!0}}var qr={useState:Rt,useId:$t,useReducer:At,useEffect:Ot,useLayoutEffect:Lt,useInsertionEffect:Ur,useTransition:Wr,useDeferredValue:Hr,useSyncExternalStore:Br,startTransition:$r,useRef:Mt,useImperativeHandle:Ft,useMemo:It,useCallback:Dt,useContext:Gt,useDebugValue:Nt,version:"18.3.1",Children:Jn,render:gr,hydrate:yr,unmountComponentAtNode:Fr,createPortal:ur,createElement:De,createContext:at,createFactory:Rr,cloneElement:Mr,createRef:Ne,Fragment:$e,isValidElement:Ar,isElement:jr,isFragment:Or,isMemo:Lr,findDOMNode:Ir,Component:He,PureComponent:qn,memo:Kn,forwardRef:Yn,flushSync:Gr,unstable_batchedUpdates:Dr,StrictMode:Nr,Suspense:rr,SuspenseList:ar,lazy:or,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Pr};const Kr=Object.freeze(Object.defineProperty({__proto__:null,Children:Jn,Component:He,Fragment:$e,PureComponent:qn,StrictMode:Nr,Suspense:rr,SuspenseList:ar,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Pr,cloneElement:Mr,createContext:at,createElement:De,createFactory:Rr,createPortal:ur,createRef:Ne,default:qr,findDOMNode:Ir,flushSync:Gr,forwardRef:Yn,hydrate:yr,isElement:jr,isFragment:Or,isMemo:Lr,isValidElement:Ar,lazy:or,memo:Kn,render:gr,startTransition:$r,unmountComponentAtNode:Fr,unstable_batchedUpdates:Dr,useCallback:Dt,useContext:Gt,useDebugValue:Nt,useDeferredValue:Hr,useEffect:Ot,useErrorBoundary:function(e){var t=Pt(vt++,10),n=Rt();return t.__=e,mt.componentDidCatch||(mt.componentDidCatch=function(e,r){t.__&&t.__(e,r),n[1](e)}),[n[0],function(){n[1](void 0)}]},useId:$t,useImperativeHandle:Ft,useInsertionEffect:Ur,useLayoutEffect:Lt,useMemo:It,useReducer:At,useRef:Mt,useState:Rt,useSyncExternalStore:Br,useTransition:Wr,version:"18.3.1"},Symbol.toStringTag,{value:"Module"}));var Vr=0;function Qr(e,t,n,r,i,o){t||(t={});var a,s,l=t;"ref"in t&&(a=t.ref,delete t.ref);var c={type:e,props:l,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--Vr,__i:-1,__u:0,__source:i,__self:o};if("function"==typeof e&&(a=e.defaultProps))for(s in a)void 0===l[s]&&(l[s]=a[s]);return we.vnode&&we.vnode(c),c}var Yr=at(void 0),Xr=e=>{const t=Gt(Yr);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Jr=({client:e,children:t})=>(Ot((()=>(e.mount(),()=>{e.unmount()})),[e]),Qr(Yr.Provider,{value:e,children:t})),Zr=at(!1);Zr.Provider;var ei=at(function(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}());function ti(e,t){return"function"==typeof e?e(...t):!!e}function ni(){}var ri=(e,t,n)=>t.fetchOptimistic(e).catch((()=>{n.clearReset()}));function ii(e,t,n){var r,i,o,a,s;const l=Xr(),c=Gt(Zr),u=Gt(ei),d=l.defaultQueryOptions(e);null==(i=null==(r=l.getDefaultOptions().queries)?void 0:r._experimental_beforeQuery)||i.call(r,d),d._optimisticResults=c?"isRestoring":"optimistic",(e=>{e.suspense&&(void 0===e.staleTime&&(e.staleTime=1e3),"number"==typeof e.gcTime&&(e.gcTime=Math.max(e.gcTime,1e3)))})(d),((e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))})(d,u),(e=>{Ot((()=>{e.clearReset()}),[e])})(u);const p=!l.getQueryCache().get(d.queryHash),[h]=Rt((()=>new t(l,d))),f=h.getOptimisticResult(d);if(Br(Dt((e=>{const t=c?ni:h.subscribe(Tn.batchCalls(e));return h.updateResult(),t}),[h,c]),(()=>h.getCurrentResult())),Ot((()=>{h.setOptions(d,{listeners:!1})}),[d,h]),((e,t)=>(null==e?void 0:e.suspense)&&t.isPending)(d,f))throw ri(d,h,u);if((({result:e,errorResetBoundary:t,throwOnError:n,query:r})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&ti(n,[e.error,r]))({result:f,errorResetBoundary:u,throwOnError:d.throwOnError,query:l.getQueryCache().get(d.queryHash)}))throw f.error;if(null==(a=null==(o=l.getDefaultOptions().queries)?void 0:o._experimental_afterQuery)||a.call(o,d,f),d.experimental_prefetchInRender&&!Xt&&((e,t)=>e.isLoading&&e.isFetching&&!t)(f,c)){const e=p?ri(d,h,u):null==(s=l.getQueryCache().get(d.queryHash))?void 0:s.promise;null==e||e.catch(ni).finally((()=>{h.updateResult()}))}return d.notifyOnChangeProps?f:h.trackResult(f)}function oi(e,t){return ii(e,$n)}const ai=at({account:{accountId:""},backend:{url:"",accessToken:""}}),si=()=>Gt(ai);class li extends Error{constructor(e,t){super(e),__publicField(this,"_response"),this._response=t,Object.setPrototypeOf(this,li.prototype)}get response(){return this._response}}const ci=async(e,t,n,r)=>{const i=await fetch(e,{method:n,body:r?JSON.stringify(r):void 0,headers:{"content-type":"application/json","x-app-version":"1.0.802",authorization:`Bearer ${t}`},signal:(null==AbortSignal?void 0:AbortSignal.timeout)&&AbortSignal.timeout(15e3)});if(!i.ok)throw new li(`[API Error] Status: ${i.status}, ${i.statusText}`,i);return i},ui=async(e,t,n,r)=>{const i=await ci(e,t,n,r);return await i.json()},di=e=>{const t=si();return It((()=>e(t)),[e,t])};let pi;const hi=()=>{if(pi)return pi;return pi=new Nn({defaultOptions:{queries:{retry:(e,t)=>{var n;return t instanceof li&&![401,403].includes((null==(n=t.response)?void 0:n.status)||0)}}}}),pi},fi="linkedAccount",vi="linkedProfilesForAccount",mi="salaryPackagedItem",gi="checkProfileSearchAuthorization",yi="payrollAdvice",_i="invoices",wi="/salary-packaging/admin/v1.0",bi=e=>async()=>{const t=new URL(`${e.backend.url}${wi}/accounts/${e.account.accountId}/auth`);return ui(t,e.backend.accessToken,"GET")},xi=e=>async t=>{const n=new URL(`${e.backend.url}${wi}/accounts/${e.account.accountId}/profile-search?search=${t}`);return ui(n,e.backend.accessToken,"GET")},ki=e=>async()=>{const t=new Date;t.setUTCDate((new Date).getUTCDate()-2);const n=new Date;n.setUTCDate((new Date).getUTCDate()+2);const r=new URL(`${e.backend.url}${wi}/ingest/clients`);await ci(r,e.backend.accessToken,"POST",{startDate:t.toISOString().split("T")[0],endDate:n.toISOString().split("T")[0]})},Si=e=>async()=>{const t=new URL(`${e.backend.url}${wi}/accounts/${e.account.accountId}`);return ui(t,e.backend.accessToken,"GET")},Ei=e=>async()=>{const t=new URL(`${e.backend.url}${wi}/accounts/${e.account.accountId}/profiles`);return ui(t,e.backend.accessToken,"GET")},Ci=e=>async t=>{const n=new URL(`${e.backend.url}${wi}/accounts/${e.account.accountId}/profiles/${t}/unlink`);await ci(n,e.backend.accessToken,"POST")},Ti=e=>async(t,n)=>{const r=new URL(`${e.backend.url}${wi}/accounts/${e.account.accountId}/profiles/${t}/items/${n}`);return ui(r,e.backend.accessToken,"GET")},Pi=e=>async t=>{const n=new URL(`${e.backend.url}${wi}/accounts/${e.account.accountId}/profiles/${t}/payroll-advice`);return ui(n,e.backend.accessToken,"GET")},Ri=e=>async()=>{const t=new URL(`${e.backend.url}${wi}/accounts/${e.account.accountId}/invoices`);return ui(t,e.backend.accessToken,"GET")},Ai=()=>({checkProfileSearchAuthorization:di(bi),searchProfilesForAccount:di(xi),ingestClient:di(ki),linkedAccount:di(Si),linkedProfilesForAccount:di(Ei),unlinkProfile:di(Ci),salaryPackagedItem:di(Ti),payrollAdvice:di(Pi),invoices:di(Ri)});var Oi={};Object.defineProperty(Oi,"__esModule",{value:!0}),Oi.parse=function(e,t){const n=new Gi,r=e.length;if(r<2)return n;const i=(null==t?void 0:t.decode)||Hi;let o=0;do{const t=e.indexOf("=",o);if(-1===t)break;const a=e.indexOf(";",o),s=-1===a?r:a;if(t>s){o=e.lastIndexOf(";",t-1)+1;continue}const l=Ni(e,o,t),c=$i(e,t,l),u=e.slice(l,c);if(void 0===n[u]){let r=Ni(e,t+1,s),o=$i(e,s,r);const a=i(e.slice(r,o));n[u]=a}o=s+1}while(o<r);return n},Oi.serialize=function(e,t,n){const r=(null==n?void 0:n.encode)||encodeURIComponent;if(!Li.test(e))throw new TypeError(`argument name is invalid: ${e}`);const i=r(t);if(!Mi.test(i))throw new TypeError(`argument val is invalid: ${t}`);let o=e+"="+i;if(!n)return o;if(void 0!==n.maxAge){if(!Number.isInteger(n.maxAge))throw new TypeError(`option maxAge is invalid: ${n.maxAge}`);o+="; Max-Age="+n.maxAge}if(n.domain){if(!Fi.test(n.domain))throw new TypeError(`option domain is invalid: ${n.domain}`);o+="; Domain="+n.domain}if(n.path){if(!Ii.test(n.path))throw new TypeError(`option path is invalid: ${n.path}`);o+="; Path="+n.path}if(n.expires){if(!function(e){return"[object Date]"===Di.call(e)}
1
+ var __defProp=Object.defineProperty,__typeError=e=>{throw TypeError(e)},__defNormalProp=(e,t,n)=>t in e?__defProp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__publicField=(e,t,n)=>__defNormalProp(e,"symbol"!=typeof t?t+"":t,n),__accessCheck=(e,t,n)=>t.has(e)||__typeError("Cannot "+n),__privateGet=(e,t,n)=>(__accessCheck(e,t,"read from private field"),n?n.call(e):t.get(e)),__privateAdd=(e,t,n)=>t.has(e)?__typeError("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),__privateSet=(e,t,n,r)=>(__accessCheck(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),__privateMethod=(e,t,n)=>(__accessCheck(e,t,"access private method"),n),__privateWrapper=(e,t,n,r)=>({set _(r){__privateSet(e,t,r,n)},get _(){return __privateGet(e,t,r)}});!function(){"use strict";var e,t,n,r,i,o,a,s,l,c,u,d,p,h,f,v,m,g,y,_,w,b,x,k,S,E,C,T,P,R,A,O,L,M,F,I,D,G,N,$,H,W,U,j,B,z,q,K,V,Q,Y,X,J,Z,ee,te,ne,re,ie,oe,ae,se,le,ce,ue,de,pe,he,fe,ve,me,ge,ye,_e,we,be,xe,ke,Se,Ee,Ce,Te,Pe,Re,Ae={},Oe=[],Le=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Me=Array.isArray;function Fe(e,t){for(var n in t)e[n]=t[n];return e}function Ie(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function De(e,t,n){var r,i,o,a={};for(o in t)"key"==o?r=t[o]:"ref"==o?i=t[o]:a[o]=t[o];if(arguments.length>2&&(a.children=arguments.length>3?_e.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(o in e.defaultProps)void 0===a[o]&&(a[o]=e.defaultProps[o]);return Ge(e,a,r,i,null)}function Ge(e,t,n,r,i){var o={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==i?++be:i,__i:-1,__u:0};return null==i&&null!=we.vnode&&we.vnode(o),o}function Ne(){return{current:null}}function $e(e){return e.children}function He(e,t){this.props=e,this.context=t}function We(e,t){if(null==t)return e.__?We(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e)return n.__e;return"function"==typeof e.type?We(e):null}function Ue(e){var t,n;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e){e.__e=e.__c.base=n.__e;break}return Ue(e)}}function je(e){(!e.__d&&(e.__d=!0)&&xe.push(e)&&!Be.__r++||ke!==we.debounceRendering)&&((ke=we.debounceRendering)||Se)(Be)}function Be(){var e,t,n,r,i,o,a,s;for(xe.sort(Ee);e=xe.shift();)e.__d&&(t=xe.length,r=void 0,o=(i=(n=e).__v).__e,a=[],s=[],n.__P&&((r=Fe({},i)).__v=i.__v+1,we.vnode&&we.vnode(r),Je(n.__P,r,i,n.__n,n.__P.namespaceURI,32&i.__u?[o]:null,a,null==o?We(i):o,!!(32&i.__u),s),r.__v=i.__v,r.__.__k[r.__i]=r,Ze(a,r,s),r.__e!=o&&Ue(r)),xe.length>t&&xe.sort(Ee));Be.__r=0}function ze(e,t,n,r,i,o,a,s,l,c,u){var d,p,h,f,v,m=r&&r.__k||Oe,g=t.length;for(n.__d=l,function(e,t,n){var r,i,o,a,s,l=t.length,c=n.length,u=c,d=0;for(e.__k=[],r=0;r<l;r++)null!=(i=t[r])&&"boolean"!=typeof i&&"function"!=typeof i?(a=r+d,(i=e.__k[r]="string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?Ge(null,i,null,null,null):Me(i)?Ge($e,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?Ge(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i).__=e,i.__b=e.__b+1,o=null,-1!==(s=i.__i=Ve(i,n,a,u))&&(u--,(o=n[s])&&(o.__u|=131072)),null==o||null===o.__v?(-1==s&&d--,"function"!=typeof i.type&&(i.__u|=65536)):s!==a&&(s==a-1?d--:s==a+1?d++:(s>a?d--:d++,i.__u|=65536))):i=e.__k[r]=null;if(u)for(r=0;r<c;r++)null!=(o=n[r])&&!(131072&o.__u)&&(o.__e==e.__d&&(e.__d=We(o)),tt(o,o))}(n,t,m),l=n.__d,d=0;d<g;d++)null!=(h=n.__k[d])&&(p=-1===h.__i?Ae:m[h.__i]||Ae,h.__i=d,Je(e,h,p,i,o,a,s,l,c,u),f=h.__e,h.ref&&p.ref!=h.ref&&(p.ref&&et(p.ref,null,h),u.push(h.ref,h.__c||f,h)),null==v&&null!=f&&(v=f),65536&h.__u||p.__k===h.__k?l=qe(h,l,e):"function"==typeof h.type&&void 0!==h.__d?l=h.__d:f&&(l=f.nextSibling),h.__d=void 0,h.__u&=-196609);n.__d=l,n.__e=v}function qe(e,t,n){var r,i;if("function"==typeof e.type){for(r=e.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=e,t=qe(r[i],t,n));return t}e.__e!=t&&(t&&e.type&&!n.contains(t)&&(t=We(e)),n.insertBefore(e.__e,t||null),t=e.__e);do{t=t&&t.nextSibling}while(null!=t&&8===t.nodeType);return t}function Ke(e,t){return t=t||[],null==e||"boolean"==typeof e||(Me(e)?e.some((function(e){Ke(e,t)})):t.push(e)),t}function Ve(e,t,n,r){var i=e.key,o=e.type,a=n-1,s=n+1,l=t[n];if(null===l||l&&i==l.key&&o===l.type&&!(131072&l.__u))return n;if(r>(null==l||131072&l.__u?0:1))for(;a>=0||s<t.length;){if(a>=0){if((l=t[a])&&!(131072&l.__u)&&i==l.key&&o===l.type)return a;a--}if(s<t.length){if((l=t[s])&&!(131072&l.__u)&&i==l.key&&o===l.type)return s;s++}}return-1}function Qe(e,t,n){"-"===t[0]?e.setProperty(t,null==n?"":n):e[t]=null==n?"":"number"!=typeof n||Le.test(t)?n:n+"px"}function Ye(e,t,n,r,i){var o;e:if("style"===t)if("string"==typeof n)e.style.cssText=n;else{if("string"==typeof r&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||Qe(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||Qe(e.style,t,n[t])}else if("o"===t[0]&&"n"===t[1])o=t!==(t=t.replace(/(PointerCapture)$|Capture$/i,"$1")),t=t.toLowerCase()in e||"onFocusOut"===t||"onFocusIn"===t?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+o]=n,n?r?n.u=r.u:(n.u=Ce,e.addEventListener(t,o?Pe:Te,o)):e.removeEventListener(t,o?Pe:Te,o);else{if("http://www.w3.org/2000/svg"==i)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=t&&"height"!=t&&"href"!=t&&"list"!=t&&"form"!=t&&"tabIndex"!=t&&"download"!=t&&"rowSpan"!=t&&"colSpan"!=t&&"role"!=t&&"popover"!=t&&t in e)try{e[t]=null==n?"":n;break e}catch(a){}"function"==typeof n||(null==n||!1===n&&"-"!==t[4]?e.removeAttribute(t):e.setAttribute(t,"popover"==t&&1==n?"":n))}}function Xe(e){return function(t){if(this.l){var n=this.l[t.type+e];if(null==t.t)t.t=Ce++;else if(t.t<n.u)return;return n(we.event?we.event(t):t)}}}function Je(e,t,n,r,i,o,a,s,l,c){var u,d,p,h,f,v,m,g,y,_,w,b,x,k,S,E,C=t.type;if(void 0!==t.constructor)return null;128&n.__u&&(l=!!(32&n.__u),o=[s=t.__e=n.__e]),(u=we.__b)&&u(t);e:if("function"==typeof C)try{if(g=t.props,y="prototype"in C&&C.prototype.render,_=(u=C.contextType)&&r[u.__c],w=u?_?_.props.value:u.__:r,n.__c?m=(d=t.__c=n.__c).__=d.__E:(y?t.__c=d=new C(g,w):(t.__c=d=new He(g,w),d.constructor=C,d.render=nt),_&&_.sub(d),d.props=g,d.state||(d.state={}),d.context=w,d.__n=r,p=d.__d=!0,d.__h=[],d._sb=[]),y&&null==d.__s&&(d.__s=d.state),y&&null!=C.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=Fe({},d.__s)),Fe(d.__s,C.getDerivedStateFromProps(g,d.__s))),h=d.props,f=d.state,d.__v=t,p)y&&null==C.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),y&&null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(y&&null==C.getDerivedStateFromProps&&g!==h&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(g,w),!d.__e&&(null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(g,d.__s,w)||t.__v===n.__v)){for(t.__v!==n.__v&&(d.props=g,d.state=d.__s,d.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some((function(e){e&&(e.__=t)})),b=0;b<d._sb.length;b++)d.__h.push(d._sb[b]);d._sb=[],d.__h.length&&a.push(d);break e}null!=d.componentWillUpdate&&d.componentWillUpdate(g,d.__s,w),y&&null!=d.componentDidUpdate&&d.__h.push((function(){d.componentDidUpdate(h,f,v)}))}if(d.context=w,d.props=g,d.__P=e,d.__e=!1,x=we.__r,k=0,y){for(d.state=d.__s,d.__d=!1,x&&x(t),u=d.render(d.props,d.state,d.context),S=0;S<d._sb.length;S++)d.__h.push(d._sb[S]);d._sb=[]}else do{d.__d=!1,x&&x(t),u=d.render(d.props,d.state,d.context),d.state=d.__s}while(d.__d&&++k<25);d.state=d.__s,null!=d.getChildContext&&(r=Fe(Fe({},r),d.getChildContext())),y&&!p&&null!=d.getSnapshotBeforeUpdate&&(v=d.getSnapshotBeforeUpdate(h,f)),ze(e,Me(E=null!=u&&u.type===$e&&null==u.key?u.props.children:u)?E:[E],t,n,r,i,o,a,s,l,c),d.base=t.__e,t.__u&=-161,d.__h.length&&a.push(d),m&&(d.__E=d.__=null)}catch(T){if(t.__v=null,l||null!=o){for(t.__u|=l?160:128;s&&8===s.nodeType&&s.nextSibling;)s=s.nextSibling;o[o.indexOf(s)]=null,t.__e=s}else t.__e=n.__e,t.__k=n.__k;we.__e(T,t,n)}else null==o&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=function(e,t,n,r,i,o,a,s,l){var c,u,d,p,h,f,v,m=n.props,g=t.props,y=t.type;if("svg"===y?i="http://www.w3.org/2000/svg":"math"===y?i="http://www.w3.org/1998/Math/MathML":i||(i="http://www.w3.org/1999/xhtml"),null!=o)for(c=0;c<o.length;c++)if((h=o[c])&&"setAttribute"in h==!!y&&(y?h.localName===y:3===h.nodeType)){e=h,o[c]=null;break}if(null==e){if(null===y)return document.createTextNode(g);e=document.createElementNS(i,y,g.is&&g),s&&(we.__m&&we.__m(t,o),s=!1),o=null}if(null===y)m===g||s&&e.data===g||(e.data=g);else{if(o=o&&_e.call(e.childNodes),m=n.props||Ae,!s&&null!=o)for(m={},c=0;c<e.attributes.length;c++)m[(h=e.attributes[c]).name]=h.value;for(c in m)if(h=m[c],"children"==c);else if("dangerouslySetInnerHTML"==c)d=h;else if(!(c in g)){if("value"==c&&"defaultValue"in g||"checked"==c&&"defaultChecked"in g)continue;Ye(e,c,null,h,i)}for(c in g)h=g[c],"children"==c?p=h:"dangerouslySetInnerHTML"==c?u=h:"value"==c?f=h:"checked"==c?v=h:s&&"function"!=typeof h||m[c]===h||Ye(e,c,h,m[c],i);if(u)s||d&&(u.__html===d.__html||u.__html===e.innerHTML)||(e.innerHTML=u.__html),t.__k=[];else if(d&&(e.innerHTML=""),ze(e,Me(p)?p:[p],t,n,r,"foreignObject"===y?"http://www.w3.org/1999/xhtml":i,o,a,o?o[0]:n.__k&&We(n,0),s,l),null!=o)for(c=o.length;c--;)Ie(o[c]);s||(c="value","progress"===y&&null==f?e.removeAttribute("value"):void 0!==f&&(f!==e[c]||"progress"===y&&!f||"option"===y&&f!==m[c])&&Ye(e,c,f,m[c],i),c="checked",void 0!==v&&v!==e[c]&&Ye(e,c,v,m[c],i))}return e}(n.__e,t,n,r,i,o,a,l,c);(u=we.diffed)&&u(t)}function Ze(e,t,n){t.__d=void 0;for(var r=0;r<n.length;r++)et(n[r],n[++r],n[++r]);we.__c&&we.__c(t,e),e.some((function(t){try{e=t.__h,t.__h=[],e.some((function(e){e.call(t)}))}catch(n){we.__e(n,t.__v)}}))}function et(e,t,n){try{if("function"==typeof e){var r="function"==typeof e.__u;r&&e.__u(),r&&null==t||(e.__u=e(t))}else e.current=t}catch(i){we.__e(i,n)}}function tt(e,t,n){var r,i;if(we.unmount&&we.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||et(r,null,t)),null!=(r=e.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(o){we.__e(o,t)}r.base=r.__P=null}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&tt(r[i],t,n||"function"!=typeof e.type);n||Ie(e.__e),e.__c=e.__=e.__e=e.__d=void 0}function nt(e,t,n){return this.constructor(e,n)}function rt(e,t,n){var r,i,o,a;we.__&&we.__(e,t),i=(r="function"==typeof n)?null:n&&n.__k||t.__k,o=[],a=[],Je(t,e=(!r&&n||t).__k=De($e,null,[e]),i||Ae,Ae,t.namespaceURI,!r&&n?[n]:i?null:t.firstChild?_e.call(t.childNodes):null,o,!r&&n?n:i?i.__e:t.firstChild,r,a),Ze(o,e,a)}function it(e,t){rt(e,t,it)}function ot(e,t,n){var r,i,o,a,s=Fe({},e.props);for(o in e.type&&e.type.defaultProps&&(a=e.type.defaultProps),t)"key"==o?r=t[o]:"ref"==o?i=t[o]:s[o]=void 0===t[o]&&void 0!==a?a[o]:t[o];return arguments.length>2&&(s.children=arguments.length>3?_e.call(arguments,2):n),Ge(e.type,s,r||e.key,i||e.ref,null)}function at(e,t){var n={__c:t="__cC"+Re++,__:e,Consumer:function(e,t){return e.children(t)},Provider:function(e){var n,r;return this.getChildContext||(n=new Set,(r={})[t]=this,this.getChildContext=function(){return r},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(e){this.props.value!==e.value&&n.forEach((function(e){e.__e=!0,je(e)}))},this.sub=function(e){n.add(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n&&n.delete(e),t&&t.call(e)}}),e.children}};return n.Provider.__=n.Consumer.contextType=n}function st(){return(st=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}_e=Oe.slice,we={__e:function(e,t,n,r){for(var i,o,a;t=t.__;)if((i=t.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(e)),a=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(e,r||{}),a=i.__d),a)return i.__E=i}catch(s){e=s}throw e}},be=0,He.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=Fe({},this.state),"function"==typeof e&&(e=e(Fe({},n),this.props)),e&&Fe(n,e),null!=e&&this.__v&&(t&&this._sb.push(t),je(this))},He.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),je(this))},He.prototype.render=$e,xe=[],Se="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Ee=function(e,t){return e.__v.__b-t.__v.__b},Be.__r=0,Ce=0,Te=Xe(!1),Pe=Xe(!0),Re=0;var lt=["context","children"];function ct(e){return this.getChildContext=function(){return e.context},ot(e.children,function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)t.indexOf(n=o[r])>=0||(i[n]=e[n]);return i}(e,lt))}function ut(){var e=new CustomEvent("_preact",{detail:{},bubbles:!0,cancelable:!0});this.dispatchEvent(e),this._vdom=De(ct,st({},this._props,{context:e.detail.context}),function e(t,n){if(3===t.nodeType)return t.data;if(1!==t.nodeType)return null;var r=[],i={},o=0,a=t.attributes,s=t.childNodes;for(o=a.length;o--;)"slot"!==a[o].name&&(i[a[o].name]=a[o].value,i[dt(a[o].name)]=a[o].value);for(o=s.length;o--;){var l=e(s[o],null),c=s[o].slot;c?i[c]=De(ft,{name:c},l):r[o]=l}var u=n?De(ft,null,r):r;return De(n||t.nodeName.toLowerCase(),i,u)}(this,this._vdomComponent)),(this.hasAttribute("hydrate")?it:rt)(this._vdom,this._root)}function dt(e){return e.replace(/-(\w)/g,(function(e,t){return t?t.toUpperCase():""}))}function pt(e,t,n){if(this._vdom){var r={};r[e]=n=null==n?void 0:n,r[dt(e)]=n,this._vdom=ot(this._vdom,r),rt(this._vdom,this._root)}}function ht(){rt(this._vdom=null,this._root)}function ft(e,t){var n=this;return De("slot",st({},e,{ref:function(e){e?(n.ref=e,n._listener||(n._listener=function(e){e.stopPropagation(),e.detail.context=t},e.addEventListener("_preact",n._listener))):n.ref.removeEventListener("_preact",n._listener)}}))}var vt,mt,gt,yt,_t=0,wt=[],bt=we,xt=bt.__b,kt=bt.__r,St=bt.diffed,Et=bt.__c,Ct=bt.unmount,Tt=bt.__;function Pt(e,t){bt.__h&&bt.__h(mt,e,_t||t),_t=0;var n=mt.__H||(mt.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function Rt(e){return _t=1,At(qt,e)}function At(e,t,n){var r=Pt(vt++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):qt(void 0,t),function(e){var t=r.__N?r.__N[0]:r.__[0],n=r.t(t,e);t!==n&&(r.__N=[n,r.__[1]],r.__c.setState({}))}],r.__c=mt,!mt.u)){var i=function(e,t,n){if(!r.__c.__H)return!0;var i=r.__c.__H.__.filter((function(e){return!!e.__c}));if(i.every((function(e){return!e.__N})))return!o||o.call(this,e,t,n);var a=!1;return i.forEach((function(e){if(e.__N){var t=e.__[0];e.__=e.__N,e.__N=void 0,t!==e.__[0]&&(a=!0)}})),!(!a&&r.__c.props===e)&&(!o||o.call(this,e,t,n))};mt.u=!0;var o=mt.shouldComponentUpdate,a=mt.componentWillUpdate;mt.componentWillUpdate=function(e,t,n){if(this.__e){var r=o;o=void 0,i(e,t,n),o=r}a&&a.call(this,e,t,n)},mt.shouldComponentUpdate=i}return r.__N||r.__}function Ot(e,t){var n=Pt(vt++,3);!bt.__s&&zt(n.__H,t)&&(n.__=e,n.i=t,mt.__H.__h.push(n))}function Lt(e,t){var n=Pt(vt++,4);!bt.__s&&zt(n.__H,t)&&(n.__=e,n.i=t,mt.__h.push(n))}function Mt(e){return _t=5,It((function(){return{current:e}}),[])}function Ft(e,t,n){_t=6,Lt((function(){return"function"==typeof e?(e(t()),function(){return e(null)}):e?(e.current=t(),function(){return e.current=null}):void 0}),null==n?n:n.concat(e))}function It(e,t){var n=Pt(vt++,7);return zt(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function Dt(e,t){return _t=8,It((function(){return e}),t)}function Gt(e){var t=mt.context[e.__c],n=Pt(vt++,9);return n.c=e,t?(null==n.__&&(n.__=!0,t.sub(mt)),t.props.value):e.__}function Nt(e,t){bt.useDebugValue&&bt.useDebugValue(t?t(e):e)}function $t(){var e=Pt(vt++,11);if(!e.__){for(var t=mt.__v;null!==t&&!t.__m&&null!==t.__;)t=t.__;var n=t.__m||(t.__m=[0,0]);e.__="P"+n[0]+"-"+n[1]++}return e.__}function Ht(){for(var e;e=wt.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(jt),e.__H.__h.forEach(Bt),e.__H.__h=[]}catch(gu){e.__H.__h=[],bt.__e(gu,e.__v)}}bt.__b=function(e){mt=null,xt&&xt(e)},bt.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Tt&&Tt(e,t)},bt.__r=function(e){kt&&kt(e),vt=0;var t=(mt=e.__c).__H;t&&(gt===mt?(t.__h=[],mt.__h=[],t.__.forEach((function(e){e.__N&&(e.__=e.__N),e.i=e.__N=void 0}))):(t.__h.forEach(jt),t.__h.forEach(Bt),t.__h=[],vt=0)),gt=mt},bt.diffed=function(e){St&&St(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(1!==wt.push(t)&&yt===bt.requestAnimationFrame||((yt=bt.requestAnimationFrame)||Ut)(Ht)),t.__H.__.forEach((function(e){e.i&&(e.__H=e.i),e.i=void 0}))),gt=mt=null},bt.__c=function(e,t){t.some((function(e){try{e.__h.forEach(jt),e.__h=e.__h.filter((function(e){return!e.__||Bt(e)}))}catch(Zc){t.some((function(e){e.__h&&(e.__h=[])})),t=[],bt.__e(Zc,e.__v)}})),Et&&Et(e,t)},bt.unmount=function(e){Ct&&Ct(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach((function(e){try{jt(e)}catch(n){t=n}})),n.__H=void 0,t&&bt.__e(t,n.__v))};var Wt="function"==typeof requestAnimationFrame;function Ut(e){var t,n=function(){clearTimeout(r),Wt&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);Wt&&(t=requestAnimationFrame(n))}function jt(e){var t=mt,n=e.__c;"function"==typeof n&&(e.__c=void 0,n()),mt=t}function Bt(e){var t=mt;e.__c=e.__(),mt=t}function zt(e,t){return!e||e.length!==t.length||t.some((function(t,n){return t!==e[n]}))}function qt(e,t){return"function"==typeof t?t(e):t}class Kt extends Error{}function Vt(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return function(e){return decodeURIComponent(atob(e).replace(/(.)/g,((e,t)=>{let n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(t)}catch(n){return atob(t)}}Kt.prototype.name="InvalidTokenError";class Qt{constructor(e){__publicField(this,"roles"),__publicField(this,"isAuthorized"),this.roles=e,this.isAuthorized=e.includes("SalaryPackaging.Access")}static create(e){const t=e?function(e,t){if("string"!=typeof e)throw new Kt("Invalid token specified: must be a string");t||(t={});const n=!0===t.header?0:1,r=e.split(".")[n];if("string"!=typeof r)throw new Kt(`Invalid token specified: missing part #${n+1}`);let i;try{i=Vt(r)}catch(Mc){throw new Kt(`Invalid token specified: invalid base64 for part #${n+1} (${Mc.message})`)}try{return JSON.parse(i)}catch(Mc){throw new Kt(`Invalid token specified: invalid json for part #${n+1} (${Mc.message})`)}}(e):{roles:[]};return new Qt(t.roles)}}var Yt=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Xt="undefined"==typeof window||"Deno"in globalThis;function Jt(){}function Zt(e){return"number"==typeof e&&e>=0&&e!==1/0}function en(e,t){return Math.max(e+(t||0)-Date.now(),0)}function tn(e,t){return"function"==typeof e?e(t):e}function nn(e,t){return"function"==typeof e?e(t):e}function rn(e,t){const{type:n="all",exact:r,fetchStatus:i,predicate:o,queryKey:a,stale:s}=e;if(a)if(r){if(t.queryHash!==an(a,t.options))return!1}else if(!ln(t.queryKey,a))return!1;if("all"!==n){const e=t.isActive();if("active"===n&&!e)return!1;if("inactive"===n&&e)return!1}return("boolean"!=typeof s||t.isStale()===s)&&((!i||i===t.state.fetchStatus)&&!(o&&!o(t)))}function on(e,t){const{exact:n,status:r,predicate:i,mutationKey:o}=e;if(o){if(!t.options.mutationKey)return!1;if(n){if(sn(t.options.mutationKey)!==sn(o))return!1}else if(!ln(t.options.mutationKey,o))return!1}return(!r||t.state.status===r)&&!(i&&!i(t))}function an(e,t){return((null==t?void 0:t.queryKeyHashFn)||sn)(e)}function sn(e){return JSON.stringify(e,((e,t)=>pn(t)?Object.keys(t).sort().reduce(((e,n)=>(e[n]=t[n],e)),{}):t))}function ln(e,t){return e===t||typeof e==typeof t&&(!(!e||!t||"object"!=typeof e||"object"!=typeof t)&&!Object.keys(t).some((n=>!ln(e[n],t[n]))))}function cn(e,t){if(e===t)return e;const n=dn(e)&&dn(t);if(n||pn(e)&&pn(t)){const r=n?e:Object.keys(e),i=r.length,o=n?t:Object.keys(t),a=o.length,s=n?[]:{};let l=0;for(let c=0;c<a;c++){const i=n?c:o[c];(!n&&r.includes(i)||n)&&void 0===e[i]&&void 0===t[i]?(s[i]=void 0,l++):(s[i]=cn(e[i],t[i]),s[i]===e[i]&&void 0!==e[i]&&l++)}return i===a&&l===i?e:s}return t}function un(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function dn(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function pn(e){if(!hn(e))return!1;const t=e.constructor;if(void 0===t)return!0;const n=t.prototype;return!!hn(n)&&(!!n.hasOwnProperty("isPrototypeOf")&&Object.getPrototypeOf(e)===Object.prototype)}function hn(e){return"[object Object]"===Object.prototype.toString.call(e)}function fn(e,t,n){return"function"==typeof n.structuralSharing?n.structuralSharing(e,t):!1!==n.structuralSharing?cn(e,t):t}function vn(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function mn(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var gn=Symbol();function yn(e,t){return!e.queryFn&&(null==t?void 0:t.initialPromise)?()=>t.initialPromise:e.queryFn&&e.queryFn!==gn?e.queryFn:()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`))}var _n=new(r=class extends Yt{constructor(){super(),__privateAdd(this,e),__privateAdd(this,t),__privateAdd(this,n),__privateSet(this,n,(e=>{if(!Xt&&window.addEventListener){const t=()=>e();return window.addEventListener("visibilitychange",t,!1),()=>{window.removeEventListener("visibilitychange",t)}}}))}onSubscribe(){__privateGet(this,t)||this.setEventListener(__privateGet(this,n))}onUnsubscribe(){var e;this.hasListeners()||(null==(e=__privateGet(this,t))||e.call(this),__privateSet(this,t,void 0))}setEventListener(e){var r;__privateSet(this,n,e),null==(r=__privateGet(this,t))||r.call(this),__privateSet(this,t,e((e=>{"boolean"==typeof e?this.setFocused(e):this.onFocus()})))}setFocused(t){__privateGet(this,e)!==t&&(__privateSet(this,e,t),this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach((t=>{t(e)}))}isFocused(){var t;return"boolean"==typeof __privateGet(this,e)?__privateGet(this,e):"hidden"!==(null==(t=globalThis.document)?void 0:t.visibilityState)}},e=new WeakMap,t=new WeakMap,n=new WeakMap,r),wn=new(s=class extends Yt{constructor(){super(),__privateAdd(this,i,!0),__privateAdd(this,o),__privateAdd(this,a),__privateSet(this,a,(e=>{if(!Xt&&window.addEventListener){const t=()=>e(!0),n=()=>e(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",t),window.removeEventListener("offline",n)}}}))}onSubscribe(){__privateGet(this,o)||this.setEventListener(__privateGet(this,a))}onUnsubscribe(){var e;this.hasListeners()||(null==(e=__privateGet(this,o))||e.call(this),__privateSet(this,o,void 0))}setEventListener(e){var t;__privateSet(this,a,e),null==(t=__privateGet(this,o))||t.call(this),__privateSet(this,o,e(this.setOnline.bind(this)))}setOnline(e){__privateGet(this,i)!==e&&(__privateSet(this,i,e),this.listeners.forEach((t=>{t(e)})))}isOnline(){return __privateGet(this,i)}},i=new WeakMap,o=new WeakMap,a=new WeakMap,s);function bn(){let e,t;const n=new Promise(((n,r)=>{e=n,t=r}));function r(e){Object.assign(n,e),delete n.resolve,delete n.reject}return n.status="pending",n.catch((()=>{})),n.resolve=t=>{r({status:"fulfilled",value:t}),e(t)},n.reject=e=>{r({status:"rejected",reason:e}),t(e)},n}function xn(e){return Math.min(1e3*2**e,3e4)}function kn(e){return"online"!==(e??"online")||wn.isOnline()}var Sn=class extends Error{constructor(e){super("CancelledError"),this.revert=null==e?void 0:e.revert,this.silent=null==e?void 0:e.silent}};function En(e){return e instanceof Sn}function Cn(e){let t,n=!1,r=0,i=!1;const o=bn(),a=()=>_n.isFocused()&&("always"===e.networkMode||wn.isOnline())&&e.canRun(),s=()=>kn(e.networkMode)&&e.canRun(),l=n=>{var r;i||(i=!0,null==(r=e.onSuccess)||r.call(e,n),null==t||t(),o.resolve(n))},c=n=>{var r;i||(i=!0,null==(r=e.onError)||r.call(e,n),null==t||t(),o.reject(n))},u=()=>new Promise((n=>{var r;t=e=>{(i||a())&&n(e)},null==(r=e.onPause)||r.call(e)})).then((()=>{var n;t=void 0,i||null==(n=e.onContinue)||n.call(e)})),d=()=>{if(i)return;let t;const o=0===r?e.initialPromise:void 0;try{t=o??e.fn()}catch(s){t=Promise.reject(s)}Promise.resolve(t).then(l).catch((t=>{var o;if(i)return;const s=e.retry??(Xt?0:3),l=e.retryDelay??xn,p="function"==typeof l?l(r,t):l,h=!0===s||"number"==typeof s&&r<s||"function"==typeof s&&s(r,t);var f;!n&&h?(r++,null==(o=e.onFail)||o.call(e,r,t),(f=p,new Promise((e=>{setTimeout(e,f)}))).then((()=>a()?void 0:u())).then((()=>{n?c(t):d()}))):c(t)}))};return{promise:o,cancel:t=>{var n;i||(c(new Sn(t)),null==(n=e.abort)||n.call(e))},continue:()=>(null==t||t(),o),cancelRetry:()=>{n=!0},continueRetry:()=>{n=!1},canStart:s,start:()=>(s()?d():u().then(d),o)}}var Tn=function(){let e=[],t=0,n=e=>{e()},r=e=>{e()},i=e=>setTimeout(e,0);const o=r=>{t?e.push(r):i((()=>{n(r)}))};return{batch:o=>{let a;t++;try{a=o()}finally{t--,t||(()=>{const t=e;e=[],t.length&&i((()=>{r((()=>{t.forEach((e=>{n(e)}))}))}))})()}return a},batchCalls:e=>(...t)=>{o((()=>{e(...t)}))},schedule:o,setNotifyFunction:e=>{n=e},setBatchNotifyFunction:e=>{r=e},setScheduler:e=>{i=e}}}(),Pn=(c=class{constructor(){__privateAdd(this,l)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Zt(this.gcTime)&&__privateSet(this,l,setTimeout((()=>{this.optionalRemove()}),this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Xt?1/0:3e5))}clearGcTimeout(){__privateGet(this,l)&&(clearTimeout(__privateGet(this,l)),__privateSet(this,l,void 0))}},l=new WeakMap,c),Rn=(y=class extends Pn{constructor(e){super(),__privateAdd(this,m),__privateAdd(this,u),__privateAdd(this,d),__privateAdd(this,p),__privateAdd(this,h),__privateAdd(this,f),__privateAdd(this,v),__privateSet(this,v,!1),__privateSet(this,f,e.defaultOptions),this.setOptions(e.options),this.observers=[],__privateSet(this,p,e.cache),this.queryKey=e.queryKey,this.queryHash=e.queryHash,__privateSet(this,u,function(e){const t="function"==typeof e.initialData?e.initialData():e.initialData,n=void 0!==t,r=n?"function"==typeof e.initialDataUpdatedAt?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}(this.options)),this.state=e.state??__privateGet(this,u),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var e;return null==(e=__privateGet(this,h))?void 0:e.promise}setOptions(e){this.options={...__privateGet(this,f),...e},this.updateGcTime(this.options.gcTime)}optionalRemove(){this.observers.length||"idle"!==this.state.fetchStatus||__privateGet(this,p).remove(this)}setData(e,t){const n=fn(this.state.data,e,this.options);return __privateMethod(this,m,g).call(this,{data:n,type:"success",dataUpdatedAt:null==t?void 0:t.updatedAt,manual:null==t?void 0:t.manual}),n}setState(e,t){__privateMethod(this,m,g).call(this,{type:"setState",state:e,setStateOptions:t})}cancel(e){var t,n;const r=null==(t=__privateGet(this,h))?void 0:t.promise;return null==(n=__privateGet(this,h))||n.cancel(e),r?r.then(Jt).catch(Jt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(__privateGet(this,u))}isActive(){return this.observers.some((e=>!1!==nn(e.options.enabled,this)))}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===gn||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return!!this.state.isInvalidated||(this.getObserversCount()>0?this.observers.some((e=>e.getCurrentResult().isStale)):void 0===this.state.data)}isStaleByTime(e=0){return this.state.isInvalidated||void 0===this.state.data||!en(this.state.dataUpdatedAt,e)}onFocus(){var e;const t=this.observers.find((e=>e.shouldFetchOnWindowFocus()));null==t||t.refetch({cancelRefetch:!1}),null==(e=__privateGet(this,h))||e.continue()}onOnline(){var e;const t=this.observers.find((e=>e.shouldFetchOnReconnect()));null==t||t.refetch({cancelRefetch:!1}),null==(e=__privateGet(this,h))||e.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),__privateGet(this,p).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter((t=>t!==e)),this.observers.length||(__privateGet(this,h)&&(__privateGet(this,v)?__privateGet(this,h).cancel({revert:!0}):__privateGet(this,h).cancelRetry()),this.scheduleGc()),__privateGet(this,p).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||__privateMethod(this,m,g).call(this,{type:"invalidate"})}fetch(e,t){var n,r,i;if("idle"!==this.state.fetchStatus)if(void 0!==this.state.data&&(null==t?void 0:t.cancelRefetch))this.cancel({silent:!0});else if(__privateGet(this,h))return __privateGet(this,h).continueRetry(),__privateGet(this,h).promise;if(e&&this.setOptions(e),!this.options.queryFn){const e=this.observers.find((e=>e.options.queryFn));e&&this.setOptions(e.options)}const o=new AbortController,a=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(__privateSet(this,v,!0),o.signal)})},s={fetchOptions:t,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>{const e=yn(this.options,t),n={queryKey:this.queryKey,meta:this.meta};return a(n),__privateSet(this,v,!1),this.options.persister?this.options.persister(e,n,this):e(n)}};a(s),null==(n=this.options.behavior)||n.onFetch(s,this),__privateSet(this,d,this.state),"idle"!==this.state.fetchStatus&&this.state.fetchMeta===(null==(r=s.fetchOptions)?void 0:r.meta)||__privateMethod(this,m,g).call(this,{type:"fetch",meta:null==(i=s.fetchOptions)?void 0:i.meta});const l=e=>{var t,n,r,i;En(e)&&e.silent||__privateMethod(this,m,g).call(this,{type:"error",error:e}),En(e)||(null==(n=(t=__privateGet(this,p).config).onError)||n.call(t,e,this),null==(i=(r=__privateGet(this,p).config).onSettled)||i.call(r,this.state.data,e,this)),this.scheduleGc()};return __privateSet(this,h,Cn({initialPromise:null==t?void 0:t.initialPromise,fn:s.fetchFn,abort:o.abort.bind(o),onSuccess:e=>{var t,n,r,i;if(void 0!==e){try{this.setData(e)}catch(o){return void l(o)}null==(n=(t=__privateGet(this,p).config).onSuccess)||n.call(t,e,this),null==(i=(r=__privateGet(this,p).config).onSettled)||i.call(r,e,this.state.error,this),this.scheduleGc()}else l(new Error(`${this.queryHash} data is undefined`))},onError:l,onFail:(e,t)=>{__privateMethod(this,m,g).call(this,{type:"failed",failureCount:e,error:t})},onPause:()=>{__privateMethod(this,m,g).call(this,{type:"pause"})},onContinue:()=>{__privateMethod(this,m,g).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0})),__privateGet(this,h).start()}},u=new WeakMap,d=new WeakMap,p=new WeakMap,h=new WeakMap,f=new WeakMap,v=new WeakMap,m=new WeakSet,g=function(e){this.state=(t=>{switch(e.type){case"failed":return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...t,fetchStatus:"paused"};case"continue":return{...t,fetchStatus:"fetching"};case"fetch":return{...t,...An(t.data,this.options),fetchMeta:e.meta??null};case"success":return{...t,data:e.data,dataUpdateCount:t.dataUpdateCount+1,dataUpdatedAt:e.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const n=e.error;return En(n)&&n.revert&&__privateGet(this,d)?{...__privateGet(this,d),fetchStatus:"idle"}:{...t,error:n,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:n,fetchStatus:"idle",status:"error"};case"invalidate":return{...t,isInvalidated:!0};case"setState":return{...t,...e.state}}})(this.state),Tn.batch((()=>{this.observers.forEach((e=>{e.onQueryUpdate()})),__privateGet(this,p).notify({query:this,type:"updated",action:e})}))},y);function An(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:kn(t.networkMode)?"fetching":"paused",...void 0===e&&{error:null,status:"pending"}}}var On=(w=class extends Yt{constructor(e={}){super(),__privateAdd(this,_),this.config=e,__privateSet(this,_,new Map)}build(e,t,n){const r=t.queryKey,i=t.queryHash??an(r,t);let o=this.get(i);return o||(o=new Rn({cache:this,queryKey:r,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(o)),o}add(e){__privateGet(this,_).has(e.queryHash)||(__privateGet(this,_).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const t=__privateGet(this,_).get(e.queryHash);t&&(e.destroy(),t===e&&__privateGet(this,_).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){Tn.batch((()=>{this.getAll().forEach((e=>{this.remove(e)}))}))}get(e){return __privateGet(this,_).get(e)}getAll(){return[...__privateGet(this,_).values()]}find(e){const t={exact:!0,...e};return this.getAll().find((e=>rn(t,e)))}findAll(e={}){const t=this.getAll();return Object.keys(e).length>0?t.filter((t=>rn(e,t))):t}notify(e){Tn.batch((()=>{this.listeners.forEach((t=>{t(e)}))}))}onFocus(){Tn.batch((()=>{this.getAll().forEach((e=>{e.onFocus()}))}))}onOnline(){Tn.batch((()=>{this.getAll().forEach((e=>{e.onOnline()}))}))}},_=new WeakMap,w),Ln=(C=class extends Pn{constructor(e){super(),__privateAdd(this,S),__privateAdd(this,b),__privateAdd(this,x),__privateAdd(this,k),this.mutationId=e.mutationId,__privateSet(this,x,e.mutationCache),__privateSet(this,b,[]),this.state=e.state||{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0},this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){__privateGet(this,b).includes(e)||(__privateGet(this,b).push(e),this.clearGcTimeout(),__privateGet(this,x).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){__privateSet(this,b,__privateGet(this,b).filter((t=>t!==e))),this.scheduleGc(),__privateGet(this,x).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){__privateGet(this,b).length||("pending"===this.state.status?this.scheduleGc():__privateGet(this,x).remove(this))}continue(){var e;return(null==(e=__privateGet(this,k))?void 0:e.continue())??this.execute(this.state.variables)}async execute(e){var t,n,r,i,o,a,s,l,c,u,d,p,h,f,v,m,g,y,_,w;__privateSet(this,k,Cn({fn:()=>this.options.mutationFn?this.options.mutationFn(e):Promise.reject(new Error("No mutationFn found")),onFail:(e,t)=>{__privateMethod(this,S,E).call(this,{type:"failed",failureCount:e,error:t})},onPause:()=>{__privateMethod(this,S,E).call(this,{type:"pause"})},onContinue:()=>{__privateMethod(this,S,E).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>__privateGet(this,x).canRun(this)}));const b="pending"===this.state.status,C=!__privateGet(this,k).canStart();try{if(!b){__privateMethod(this,S,E).call(this,{type:"pending",variables:e,isPaused:C}),await(null==(n=(t=__privateGet(this,x).config).onMutate)?void 0:n.call(t,e,this));const o=await(null==(i=(r=this.options).onMutate)?void 0:i.call(r,e));o!==this.state.context&&__privateMethod(this,S,E).call(this,{type:"pending",context:o,variables:e,isPaused:C})}const h=await __privateGet(this,k).start();return await(null==(a=(o=__privateGet(this,x).config).onSuccess)?void 0:a.call(o,h,e,this.state.context,this)),await(null==(l=(s=this.options).onSuccess)?void 0:l.call(s,h,e,this.state.context)),await(null==(u=(c=__privateGet(this,x).config).onSettled)?void 0:u.call(c,h,null,this.state.variables,this.state.context,this)),await(null==(p=(d=this.options).onSettled)?void 0:p.call(d,h,null,e,this.state.context)),__privateMethod(this,S,E).call(this,{type:"success",data:h}),h}catch(T){try{throw await(null==(f=(h=__privateGet(this,x).config).onError)?void 0:f.call(h,T,e,this.state.context,this)),await(null==(m=(v=this.options).onError)?void 0:m.call(v,T,e,this.state.context)),await(null==(y=(g=__privateGet(this,x).config).onSettled)?void 0:y.call(g,void 0,T,this.state.variables,this.state.context,this)),await(null==(w=(_=this.options).onSettled)?void 0:w.call(_,void 0,T,e,this.state.context)),T}finally{__privateMethod(this,S,E).call(this,{type:"error",error:T})}}finally{__privateGet(this,x).runNext(this)}}},b=new WeakMap,x=new WeakMap,k=new WeakMap,S=new WeakSet,E=function(e){this.state=(t=>{switch(e.type){case"failed":return{...t,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...t,isPaused:!0};case"continue":return{...t,isPaused:!1};case"pending":return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}})(this.state),Tn.batch((()=>{__privateGet(this,b).forEach((t=>{t.onMutationUpdate(e)})),__privateGet(this,x).notify({mutation:this,type:"updated",action:e})}))},C);var Mn=(R=class extends Yt{constructor(e={}){super(),__privateAdd(this,T),__privateAdd(this,P),this.config=e,__privateSet(this,T,new Map),__privateSet(this,P,Date.now())}build(e,t,n){const r=new Ln({mutationCache:this,mutationId:++__privateWrapper(this,P)._,options:e.defaultMutationOptions(t),state:n});return this.add(r),r}add(e){const t=Fn(e),n=__privateGet(this,T).get(t)??[];n.push(e),__privateGet(this,T).set(t,n),this.notify({type:"added",mutation:e})}remove(e){var t;const n=Fn(e);if(__privateGet(this,T).has(n)){const r=null==(t=__privateGet(this,T).get(n))?void 0:t.filter((t=>t!==e));r&&(0===r.length?__privateGet(this,T).delete(n):__privateGet(this,T).set(n,r))}this.notify({type:"removed",mutation:e})}canRun(e){var t;const n=null==(t=__privateGet(this,T).get(Fn(e)))?void 0:t.find((e=>"pending"===e.state.status));return!n||n===e}runNext(e){var t;const n=null==(t=__privateGet(this,T).get(Fn(e)))?void 0:t.find((t=>t!==e&&t.state.isPaused));return(null==n?void 0:n.continue())??Promise.resolve()}clear(){Tn.batch((()=>{this.getAll().forEach((e=>{this.remove(e)}))}))}getAll(){return[...__privateGet(this,T).values()].flat()}find(e){const t={exact:!0,...e};return this.getAll().find((e=>on(t,e)))}findAll(e={}){return this.getAll().filter((t=>on(e,t)))}notify(e){Tn.batch((()=>{this.listeners.forEach((t=>{t(e)}))}))}resumePausedMutations(){const e=this.getAll().filter((e=>e.state.isPaused));return Tn.batch((()=>Promise.all(e.map((e=>e.continue().catch(Jt))))))}},T=new WeakMap,P=new WeakMap,R);function Fn(e){var t;return(null==(t=e.options.scope)?void 0:t.id)??String(e.mutationId)}function In(e){return{onFetch:(t,n)=>{var r,i,o,a,s;const l=t.options,c=null==(o=null==(i=null==(r=t.fetchOptions)?void 0:r.meta)?void 0:i.fetchMore)?void 0:o.direction,u=(null==(a=t.state.data)?void 0:a.pages)||[],d=(null==(s=t.state.data)?void 0:s.pageParams)||[];let p={pages:[],pageParams:[]},h=0;const f=async()=>{let n=!1;const r=yn(t.options,t.fetchOptions),i=async(e,i,o)=>{if(n)return Promise.reject();if(null==i&&e.pages.length)return Promise.resolve(e);const a={queryKey:t.queryKey,pageParam:i,direction:o?"backward":"forward",meta:t.options.meta};var s;s=a,Object.defineProperty(s,"signal",{enumerable:!0,get:()=>(t.signal.aborted?n=!0:t.signal.addEventListener("abort",(()=>{n=!0})),t.signal)});const l=await r(a),{maxPages:c}=t.options,u=o?mn:vn;return{pages:u(e.pages,l,c),pageParams:u(e.pageParams,i,c)}};if(c&&u.length){const e="backward"===c,t={pages:u,pageParams:d},n=(e?Gn:Dn)(l,t);p=await i(t,n,e)}else{const t=e??u.length;do{const e=0===h?d[0]??l.initialPageParam:Dn(l,p);if(h>0&&null==e)break;p=await i(p,e),h++}while(h<t)}return p};t.options.persister?t.fetchFn=()=>{var e,r;return null==(r=(e=t.options).persister)?void 0:r.call(e,f,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=f}}}function Dn(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function Gn(e,{pages:t,pageParams:n}){var r;return t.length>0?null==(r=e.getPreviousPageParam)?void 0:r.call(e,t[0],t,n[0],n):void 0}var Nn=(N=class{constructor(e={}){__privateAdd(this,A),__privateAdd(this,O),__privateAdd(this,L),__privateAdd(this,M),__privateAdd(this,F),__privateAdd(this,I),__privateAdd(this,D),__privateAdd(this,G),__privateSet(this,A,e.queryCache||new On),__privateSet(this,O,e.mutationCache||new Mn),__privateSet(this,L,e.defaultOptions||{}),__privateSet(this,M,new Map),__privateSet(this,F,new Map),__privateSet(this,I,0)}mount(){__privateWrapper(this,I)._++,1===__privateGet(this,I)&&(__privateSet(this,D,_n.subscribe((async e=>{e&&(await this.resumePausedMutations(),__privateGet(this,A).onFocus())}))),__privateSet(this,G,wn.subscribe((async e=>{e&&(await this.resumePausedMutations(),__privateGet(this,A).onOnline())}))))}unmount(){var e,t;__privateWrapper(this,I)._--,0===__privateGet(this,I)&&(null==(e=__privateGet(this,D))||e.call(this),__privateSet(this,D,void 0),null==(t=__privateGet(this,G))||t.call(this),__privateSet(this,G,void 0))}isFetching(e){return __privateGet(this,A).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return __privateGet(this,O).findAll({...e,status:"pending"}).length}getQueryData(e){var t;const n=this.defaultQueryOptions({queryKey:e});return null==(t=__privateGet(this,A).get(n.queryHash))?void 0:t.state.data}ensureQueryData(e){const t=this.getQueryData(e.queryKey);if(void 0===t)return this.fetchQuery(e);{const n=this.defaultQueryOptions(e),r=__privateGet(this,A).build(this,n);return e.revalidateIfStale&&r.isStaleByTime(tn(n.staleTime,r))&&this.prefetchQuery(n),Promise.resolve(t)}}getQueriesData(e){return __privateGet(this,A).findAll(e).map((({queryKey:e,state:t})=>[e,t.data]))}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),i=__privateGet(this,A).get(r.queryHash),o=function(e,t){return"function"==typeof e?e(t):e}(t,null==i?void 0:i.state.data);if(void 0!==o)return __privateGet(this,A).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(e,t,n){return Tn.batch((()=>__privateGet(this,A).findAll(e).map((({queryKey:e})=>[e,this.setQueryData(e,t,n)]))))}getQueryState(e){var t;const n=this.defaultQueryOptions({queryKey:e});return null==(t=__privateGet(this,A).get(n.queryHash))?void 0:t.state}removeQueries(e){const t=__privateGet(this,A);Tn.batch((()=>{t.findAll(e).forEach((e=>{t.remove(e)}))}))}resetQueries(e,t){const n=__privateGet(this,A),r={type:"active",...e};return Tn.batch((()=>(n.findAll(e).forEach((e=>{e.reset()})),this.refetchQueries(r,t))))}cancelQueries(e={},t={}){const n={revert:!0,...t},r=Tn.batch((()=>__privateGet(this,A).findAll(e).map((e=>e.cancel(n)))));return Promise.all(r).then(Jt).catch(Jt)}invalidateQueries(e={},t={}){return Tn.batch((()=>{if(__privateGet(this,A).findAll(e).forEach((e=>{e.invalidate()})),"none"===e.refetchType)return Promise.resolve();const n={...e,type:e.refetchType??e.type??"active"};return this.refetchQueries(n,t)}))}refetchQueries(e={},t){const n={...t,cancelRefetch:(null==t?void 0:t.cancelRefetch)??!0},r=Tn.batch((()=>__privateGet(this,A).findAll(e).filter((e=>!e.isDisabled())).map((e=>{let t=e.fetch(void 0,n);return n.throwOnError||(t=t.catch(Jt)),"paused"===e.state.fetchStatus?Promise.resolve():t}))));return Promise.all(r).then(Jt)}fetchQuery(e){const t=this.defaultQueryOptions(e);void 0===t.retry&&(t.retry=!1);const n=__privateGet(this,A).build(this,t);return n.isStaleByTime(tn(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Jt).catch(Jt)}fetchInfiniteQuery(e){return e.behavior=In(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Jt).catch(Jt)}ensureInfiniteQueryData(e){return e.behavior=In(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return wn.isOnline()?__privateGet(this,O).resumePausedMutations():Promise.resolve()}getQueryCache(){return __privateGet(this,A)}getMutationCache(){return __privateGet(this,O)}getDefaultOptions(){return __privateGet(this,L)}setDefaultOptions(e){__privateSet(this,L,e)}setQueryDefaults(e,t){__privateGet(this,M).set(sn(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...__privateGet(this,M).values()];let n={};return t.forEach((t=>{ln(e,t.queryKey)&&(n={...n,...t.defaultOptions})})),n}setMutationDefaults(e,t){__privateGet(this,F).set(sn(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...__privateGet(this,F).values()];let n={};return t.forEach((t=>{ln(e,t.mutationKey)&&(n={...n,...t.defaultOptions})})),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...__privateGet(this,L).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=an(t.queryKey,t)),void 0===t.refetchOnReconnect&&(t.refetchOnReconnect="always"!==t.networkMode),void 0===t.throwOnError&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),!0!==t.enabled&&t.queryFn===gn&&(t.enabled=!1),t}defaultMutationOptions(e){return(null==e?void 0:e._defaulted)?e:{...__privateGet(this,L).mutations,...(null==e?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){__privateGet(this,A).clear(),__privateGet(this,O).clear()}},A=new WeakMap,O=new WeakMap,L=new WeakMap,M=new WeakMap,F=new WeakMap,I=new WeakMap,D=new WeakMap,G=new WeakMap,N),$n=(ue=class extends Yt{constructor(e,t){super(),__privateAdd(this,ee),__privateAdd(this,$),__privateAdd(this,H),__privateAdd(this,W),__privateAdd(this,U),__privateAdd(this,j),__privateAdd(this,B),__privateAdd(this,z),__privateAdd(this,q),__privateAdd(this,K),__privateAdd(this,V),__privateAdd(this,Q),__privateAdd(this,Y),__privateAdd(this,X),__privateAdd(this,J),__privateAdd(this,Z,new Set),this.options=t,__privateSet(this,$,e),__privateSet(this,q,null),__privateSet(this,z,bn()),this.options.experimental_prefetchInRender||__privateGet(this,z).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(t)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(__privateGet(this,H).addObserver(this),Hn(__privateGet(this,H),this.options)?__privateMethod(this,ee,te).call(this):this.updateResult(),__privateMethod(this,ee,oe).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Wn(__privateGet(this,H),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Wn(__privateGet(this,H),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,__privateMethod(this,ee,ae).call(this),__privateMethod(this,ee,se).call(this),__privateGet(this,H).removeObserver(this)}setOptions(e,t){const n=this.options,r=__privateGet(this,H);if(this.options=__privateGet(this,$).defaultQueryOptions(e),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled&&"function"!=typeof this.options.enabled&&"boolean"!=typeof nn(this.options.enabled,__privateGet(this,H)))throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");__privateMethod(this,ee,le).call(this),__privateGet(this,H).setOptions(this.options),n._defaulted&&!un(this.options,n)&&__privateGet(this,$).getQueryCache().notify({type:"observerOptionsUpdated",query:__privateGet(this,H),observer:this});const i=this.hasListeners();i&&Un(__privateGet(this,H),r,this.options,n)&&__privateMethod(this,ee,te).call(this),this.updateResult(t),!i||__privateGet(this,H)===r&&nn(this.options.enabled,__privateGet(this,H))===nn(n.enabled,__privateGet(this,H))&&tn(this.options.staleTime,__privateGet(this,H))===tn(n.staleTime,__privateGet(this,H))||__privateMethod(this,ee,ne).call(this);const o=__privateMethod(this,ee,re).call(this);!i||__privateGet(this,H)===r&&nn(this.options.enabled,__privateGet(this,H))===nn(n.enabled,__privateGet(this,H))&&o===__privateGet(this,J)||__privateMethod(this,ee,ie).call(this,o)}getOptimisticResult(e){const t=__privateGet(this,$).getQueryCache().build(__privateGet(this,$),e),n=this.createResult(t,e);return function(e,t){if(!un(e.getCurrentResult(),t))return!0;return!1}(this,n)&&(__privateSet(this,U,n),__privateSet(this,B,this.options),__privateSet(this,j,__privateGet(this,H).state)),n}getCurrentResult(){return __privateGet(this,U)}trackResult(e,t){const n={};return Object.keys(e).forEach((r=>{Object.defineProperty(n,r,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(r),null==t||t(r),e[r])})})),n}trackProp(e){__privateGet(this,Z).add(e)}getCurrentQuery(){return __privateGet(this,H)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const t=__privateGet(this,$).defaultQueryOptions(e),n=__privateGet(this,$).getQueryCache().build(__privateGet(this,$),t);return n.fetch().then((()=>this.createResult(n,t)))}fetch(e){return __privateMethod(this,ee,te).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then((()=>(this.updateResult(),__privateGet(this,U))))}createResult(e,t){var n;const r=__privateGet(this,H),i=this.options,o=__privateGet(this,U),a=__privateGet(this,j),s=__privateGet(this,B),l=e!==r?e.state:__privateGet(this,W),{state:c}=e;let u,d={...c},p=!1;if(t._optimisticResults){const n=this.hasListeners(),o=!n&&Hn(e,t),a=n&&Un(e,r,t,i);(o||a)&&(d={...d,...An(c.data,e.options)}),"isRestoring"===t._optimisticResults&&(d.fetchStatus="idle")}let{error:h,errorUpdatedAt:f,status:v}=d;if(t.select&&void 0!==d.data)if(o&&d.data===(null==a?void 0:a.data)&&t.select===__privateGet(this,K))u=__privateGet(this,V);else try{__privateSet(this,K,t.select),u=t.select(d.data),u=fn(null==o?void 0:o.data,u,t),__privateSet(this,V,u),__privateSet(this,q,null)}catch(x){__privateSet(this,q,x)}else u=d.data;if(void 0!==t.placeholderData&&void 0===u&&"pending"===v){let e;if((null==o?void 0:o.isPlaceholderData)&&t.placeholderData===(null==s?void 0:s.placeholderData))e=o.data;else if(e="function"==typeof t.placeholderData?t.placeholderData(null==(n=__privateGet(this,Q))?void 0:n.state.data,__privateGet(this,Q)):t.placeholderData,t.select&&void 0!==e)try{e=t.select(e),__privateSet(this,q,null)}catch(x){__privateSet(this,q,x)}void 0!==e&&(v="success",u=fn(null==o?void 0:o.data,e,t),p=!0)}__privateGet(this,q)&&(h=__privateGet(this,q),u=__privateGet(this,V),f=Date.now(),v="error");const m="fetching"===d.fetchStatus,g="pending"===v,y="error"===v,_=g&&m,w=void 0!==u,b={status:v,fetchStatus:d.fetchStatus,isPending:g,isSuccess:"success"===v,isError:y,isInitialLoading:_,isLoading:_,data:u,dataUpdatedAt:d.dataUpdatedAt,error:h,errorUpdatedAt:f,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>l.dataUpdateCount||d.errorUpdateCount>l.errorUpdateCount,isFetching:m,isRefetching:m&&!g,isLoadingError:y&&!w,isPaused:"paused"===d.fetchStatus,isPlaceholderData:p,isRefetchError:y&&w,isStale:jn(e,t),refetch:this.refetch,promise:__privateGet(this,z)};if(this.options.experimental_prefetchInRender){const t=e=>{"error"===b.status?e.reject(b.error):void 0!==b.data&&e.resolve(b.data)},n=()=>{const e=__privateSet(this,z,b.promise=bn());t(e)},i=__privateGet(this,z);switch(i.status){case"pending":e.queryHash===r.queryHash&&t(i);break;case"fulfilled":"error"!==b.status&&b.data===i.value||n();break;case"rejected":"error"===b.status&&b.error===i.reason||n()}}return b}updateResult(e){const t=__privateGet(this,U),n=this.createResult(__privateGet(this,H),this.options);if(__privateSet(this,j,__privateGet(this,H).state),__privateSet(this,B,this.options),void 0!==__privateGet(this,j).data&&__privateSet(this,Q,__privateGet(this,H)),un(n,t))return;__privateSet(this,U,n);const r={};!1!==(null==e?void 0:e.listeners)&&(()=>{if(!t)return!0;const{notifyOnChangeProps:e}=this.options,n="function"==typeof e?e():e;if("all"===n||!n&&!__privateGet(this,Z).size)return!0;const r=new Set(n??__privateGet(this,Z));return this.options.throwOnError&&r.add("error"),Object.keys(__privateGet(this,U)).some((e=>{const n=e;return __privateGet(this,U)[n]!==t[n]&&r.has(n)}))})()&&(r.listeners=!0),__privateMethod(this,ee,ce).call(this,{...r,...e})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&__privateMethod(this,ee,oe).call(this)}},$=new WeakMap,H=new WeakMap,W=new WeakMap,U=new WeakMap,j=new WeakMap,B=new WeakMap,z=new WeakMap,q=new WeakMap,K=new WeakMap,V=new WeakMap,Q=new WeakMap,Y=new WeakMap,X=new WeakMap,J=new WeakMap,Z=new WeakMap,ee=new WeakSet,te=function(e){__privateMethod(this,ee,le).call(this);let t=__privateGet(this,H).fetch(this.options,e);return(null==e?void 0:e.throwOnError)||(t=t.catch(Jt)),t},ne=function(){__privateMethod(this,ee,ae).call(this);const e=tn(this.options.staleTime,__privateGet(this,H));if(Xt||__privateGet(this,U).isStale||!Zt(e))return;const t=en(__privateGet(this,U).dataUpdatedAt,e);__privateSet(this,Y,setTimeout((()=>{__privateGet(this,U).isStale||this.updateResult()}),t+1))},re=function(){return("function"==typeof this.options.refetchInterval?this.options.refetchInterval(__privateGet(this,H)):this.options.refetchInterval)??!1},ie=function(e){__privateMethod(this,ee,se).call(this),__privateSet(this,J,e),!Xt&&!1!==nn(this.options.enabled,__privateGet(this,H))&&Zt(__privateGet(this,J))&&0!==__privateGet(this,J)&&__privateSet(this,X,setInterval((()=>{(this.options.refetchIntervalInBackground||_n.isFocused())&&__privateMethod(this,ee,te).call(this)}),__privateGet(this,J)))},oe=function(){__privateMethod(this,ee,ne).call(this),__privateMethod(this,ee,ie).call(this,__privateMethod(this,ee,re).call(this))},ae=function(){__privateGet(this,Y)&&(clearTimeout(__privateGet(this,Y)),__privateSet(this,Y,void 0))},se=function(){__privateGet(this,X)&&(clearInterval(__privateGet(this,X)),__privateSet(this,X,void 0))},le=function(){const e=__privateGet(this,$).getQueryCache().build(__privateGet(this,$),this.options);if(e===__privateGet(this,H))return;const t=__privateGet(this,H);__privateSet(this,H,e),__privateSet(this,W,e.state),this.hasListeners()&&(null==t||t.removeObserver(this),e.addObserver(this))},ce=function(e){Tn.batch((()=>{e.listeners&&this.listeners.forEach((e=>{e(__privateGet(this,U))})),__privateGet(this,$).getQueryCache().notify({query:__privateGet(this,H),type:"observerResultsUpdated"})}))},ue);function Hn(e,t){return function(e,t){return!1!==nn(t.enabled,e)&&void 0===e.state.data&&!("error"===e.state.status&&!1===t.retryOnMount)}(e,t)||void 0!==e.state.data&&Wn(e,t,t.refetchOnMount)}function Wn(e,t,n){if(!1!==nn(t.enabled,e)){const r="function"==typeof n?n(e):n;return"always"===r||!1!==r&&jn(e,t)}return!1}function Un(e,t,n,r){return(e!==t||!1===nn(r.enabled,e))&&(!n.suspense||"error"!==e.state.status)&&jn(e,n)}function jn(e,t){return!1!==nn(t.enabled,e)&&e.isStaleByTime(tn(t.staleTime,e))}var Bn=(ye=class extends Yt{constructor(e,t){super(),__privateAdd(this,ve),__privateAdd(this,de),__privateAdd(this,pe),__privateAdd(this,he),__privateAdd(this,fe),__privateSet(this,de,e),this.setOptions(t),this.bindMethods(),__privateMethod(this,ve,me).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){var t;const n=this.options;this.options=__privateGet(this,de).defaultMutationOptions(e),un(this.options,n)||__privateGet(this,de).getMutationCache().notify({type:"observerOptionsUpdated",mutation:__privateGet(this,he),observer:this}),(null==n?void 0:n.mutationKey)&&this.options.mutationKey&&sn(n.mutationKey)!==sn(this.options.mutationKey)?this.reset():"pending"===(null==(t=__privateGet(this,he))?void 0:t.state.status)&&__privateGet(this,he).setOptions(this.options)}onUnsubscribe(){var e;this.hasListeners()||null==(e=__privateGet(this,he))||e.removeObserver(this)}onMutationUpdate(e){__privateMethod(this,ve,me).call(this),__privateMethod(this,ve,ge).call(this,e)}getCurrentResult(){return __privateGet(this,pe)}reset(){var e;null==(e=__privateGet(this,he))||e.removeObserver(this),__privateSet(this,he,void 0),__privateMethod(this,ve,me).call(this),__privateMethod(this,ve,ge).call(this)}mutate(e,t){var n;return __privateSet(this,fe,t),null==(n=__privateGet(this,he))||n.removeObserver(this),__privateSet(this,he,__privateGet(this,de).getMutationCache().build(__privateGet(this,de),this.options)),__privateGet(this,he).addObserver(this),__privateGet(this,he).execute(e)}},de=new WeakMap,pe=new WeakMap,he=new WeakMap,fe=new WeakMap,ve=new WeakSet,me=function(){var e;const t=(null==(e=__privateGet(this,he))?void 0:e.state)??{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0};__privateSet(this,pe,{...t,isPending:"pending"===t.status,isSuccess:"success"===t.status,isError:"error"===t.status,isIdle:"idle"===t.status,mutate:this.mutate,reset:this.reset})},ge=function(e){Tn.batch((()=>{var t,n,r,i,o,a,s,l;if(__privateGet(this,fe)&&this.hasListeners()){const c=__privateGet(this,pe).variables,u=__privateGet(this,pe).context;"success"===(null==e?void 0:e.type)?(null==(n=(t=__privateGet(this,fe)).onSuccess)||n.call(t,e.data,c,u),null==(i=(r=__privateGet(this,fe)).onSettled)||i.call(r,e.data,null,c,u)):"error"===(null==e?void 0:e.type)&&(null==(a=(o=__privateGet(this,fe)).onError)||a.call(o,e.error,c,u),null==(l=(s=__privateGet(this,fe)).onSettled)||l.call(s,void 0,e.error,c,u))}this.listeners.forEach((e=>{e(__privateGet(this,pe))}))}))},ye);function zn(e,t){for(var n in e)if("__source"!==n&&!(n in t))return!0;for(var r in t)if("__source"!==r&&e[r]!==t[r])return!0;return!1}function qn(e,t){this.props=e,this.context=t}function Kn(e,t){function n(e){var n=this.props.ref,r=n==e.ref;return!r&&n&&(n.call?n(null):n.current=null),t?!t(this.props,e)||!r:zn(this.props,e)}function r(t){return this.shouldComponentUpdate=n,De(e,t)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(qn.prototype=new He).isPureReactComponent=!0,qn.prototype.shouldComponentUpdate=function(e,t){return zn(this.props,e)||zn(this.state,t)};var Vn=we.__b;we.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),Vn&&Vn(e)};var Qn="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function Yn(e){function t(t){if(!("ref"in t))return e(t,null);var n=t.ref;delete t.ref;var r=e(t,n);return t.ref=n,r}return t.$$typeof=Qn,t.render=t,t.prototype.isReactComponent=t.__f=!0,t.displayName="ForwardRef("+(e.displayName||e.name)+")",t}var Xn=function(e,t){return null==e?null:Ke(Ke(e).map(t))},Jn={map:Xn,forEach:Xn,count:function(e){return e?Ke(e).length:0},only:function(e){var t=Ke(e);if(1!==t.length)throw"Children.only";return t[0]},toArray:Ke},Zn=we.__e;we.__e=function(e,t,n,r){if(e.then)for(var i,o=t;o=o.__;)if((i=o.__c)&&i.__c)return null==t.__e&&(t.__e=n.__e,t.__k=n.__k),i.__c(e,t);Zn(e,t,n,r)};var er=we.unmount;function tr(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach((function(e){"function"==typeof e.__c&&e.__c()})),e.__c.__H=null),null!=(e=function(e,t){for(var n in t)e[n]=t[n];return e}({},e)).__c&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map((function(e){return tr(e,t,n)}))),e}function nr(e,t,n){return e&&n&&(e.__v=null,e.__k=e.__k&&e.__k.map((function(e){return nr(e,t,n)})),e.__c&&e.__c.__P===t&&(e.__e&&n.appendChild(e.__e),e.__c.__e=!0,e.__c.__P=n)),e}function rr(){this.__u=0,this.t=null,this.__b=null}function ir(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function or(e){var t,n,r;function i(i){if(t||(t=e()).then((function(e){n=e.default||e}),(function(e){r=e})),r)throw r;if(!n)throw t;return De(n,i)}return i.displayName="Lazy",i.__f=!0,i}function ar(){this.u=null,this.o=null}we.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&32&e.__u&&(e.type=null),er&&er(e)},(rr.prototype=new He).__c=function(e,t){var n=t.__c,r=this;null==r.t&&(r.t=[]),r.t.push(n);var i=ir(r.__v),o=!1,a=function(){o||(o=!0,n.__R=null,i?i(s):s())};n.__R=a;var s=function(){if(! --r.__u){if(r.state.__a){var e=r.state.__a;r.__v.__k[0]=nr(e,e.__c.__P,e.__c.__O)}var t;for(r.setState({__a:r.__b=null});t=r.t.pop();)t.forceUpdate()}};r.__u++||32&t.__u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(a,a)},rr.prototype.componentWillUnmount=function(){this.t=[]},rr.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=tr(this.__b,n,r.__O=r.__P)}this.__b=null}var i=t.__a&&De($e,null,e.fallback);return i&&(i.__u&=-33),[De($e,null,t.__a?null:e.children),i]};var sr=function(e,t,n){if(++n[1]===n[0]&&e.o.delete(t),e.props.revealOrder&&("t"!==e.props.revealOrder[0]||!e.o.size))for(n=e.u;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.u=n=n[2]}};function lr(e){return this.getChildContext=function(){return e.context},e.children}function cr(e){var t=this,n=e.i;t.componentWillUnmount=function(){rt(null,t.l),t.l=null,t.i=null},t.i&&t.i!==n&&t.componentWillUnmount(),t.l||(t.i=n,t.l={nodeType:1,parentNode:n,childNodes:[],contains:function(){return!0},appendChild:function(e){this.childNodes.push(e),t.i.appendChild(e)},insertBefore:function(e,n){this.childNodes.push(e),t.i.appendChild(e)},removeChild:function(e){this.childNodes.splice(this.childNodes.indexOf(e)>>>1,1),t.i.removeChild(e)}}),rt(De(lr,{context:t.context},e.__v),t.l)}function ur(e,t){var n=De(cr,{__v:e,i:t});return n.containerInfo=t,n}(ar.prototype=new He).__a=function(e){var t=this,n=ir(t.__v),r=t.o.get(e);return r[0]++,function(i){var o=function(){t.props.revealOrder?(r.push(i),sr(t,e,r)):i()};n?n(o):o()}},ar.prototype.render=function(e){this.u=null,this.o=new Map;var t=Ke(e.children);e.revealOrder&&"b"===e.revealOrder[0]&&t.reverse();for(var n=t.length;n--;)this.o.set(t[n],this.u=[1,0,this.u]);return e.children},ar.prototype.componentDidUpdate=ar.prototype.componentDidMount=function(){var e=this;this.o.forEach((function(t,n){sr(e,n,t)}))};var dr="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,pr=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,hr=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,fr=/[A-Z0-9]/g,vr="undefined"!=typeof document,mr=function(e){return("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(e)};function gr(e,t,n){return null==t.__k&&(t.textContent=""),rt(e,t),"function"==typeof n&&n(),e?e.__c:null}function yr(e,t,n){return it(e,t),"function"==typeof n&&n(),e?e.__c:null}He.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach((function(e){Object.defineProperty(He.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})}));var _r=we.event;function wr(){}function br(){return this.cancelBubble}function xr(){return this.defaultPrevented}we.event=function(e){return _r&&(e=_r(e)),e.persist=wr,e.isPropagationStopped=br,e.isDefaultPrevented=xr,e.nativeEvent=e};var kr,Sr={enumerable:!1,configurable:!0,get:function(){return this.class}},Er=we.vnode;we.vnode=function(e){"string"==typeof e.type&&function(e){var t=e.props,n=e.type,r={},i=-1===n.indexOf("-");for(var o in t){var a=t[o];if(!("value"===o&&"defaultValue"in t&&null==a||vr&&"children"===o&&"noscript"===n||"class"===o||"className"===o)){var s=o.toLowerCase();"defaultValue"===o&&"value"in t&&null==t.value?o="value":"download"===o&&!0===a?a="":"translate"===s&&"no"===a?a=!1:"o"===s[0]&&"n"===s[1]?"ondoubleclick"===s?o="ondblclick":"onchange"!==s||"input"!==n&&"textarea"!==n||mr(t.type)?"onfocus"===s?o="onfocusin":"onblur"===s?o="onfocusout":hr.test(o)&&(o=s):s=o="oninput":i&&pr.test(o)?o=o.replace(fr,"-$&").toLowerCase():null===a&&(a=void 0),"oninput"===s&&r[o=s]&&(o="oninputCapture"),r[o]=a}}"select"==n&&r.multiple&&Array.isArray(r.value)&&(r.value=Ke(t.children).forEach((function(e){e.props.selected=-1!=r.value.indexOf(e.props.value)}))),"select"==n&&null!=r.defaultValue&&(r.value=Ke(t.children).forEach((function(e){e.props.selected=r.multiple?-1!=r.defaultValue.indexOf(e.props.value):r.defaultValue==e.props.value}))),t.class&&!t.className?(r.class=t.class,Object.defineProperty(r,"className",Sr)):(t.className&&!t.class||t.class&&t.className)&&(r.class=r.className=t.className),e.props=r}(e),e.$$typeof=dr,Er&&Er(e)};var Cr=we.__r;we.__r=function(e){Cr&&Cr(e),kr=e.__c};var Tr=we.diffed;we.diffed=function(e){Tr&&Tr(e);var t=e.props,n=e.__e;null!=n&&"textarea"===e.type&&"value"in t&&t.value!==n.value&&(n.value=null==t.value?"":t.value),kr=null};var Pr={ReactCurrentDispatcher:{current:{readContext:function(e){return kr.__n[e.__c].props.value},useCallback:Dt,useContext:Gt,useDebugValue:Nt,useDeferredValue:Hr,useEffect:Ot,useId:$t,useImperativeHandle:Ft,useInsertionEffect:Ur,useLayoutEffect:Lt,useMemo:It,useReducer:At,useRef:Mt,useState:Rt,useSyncExternalStore:Br,useTransition:Wr}}};function Rr(e){return De.bind(null,e)}function Ar(e){return!!e&&e.$$typeof===dr}function Or(e){return Ar(e)&&e.type===$e}function Lr(e){return!!e&&!!e.displayName&&("string"==typeof e.displayName||e.displayName instanceof String)&&e.displayName.startsWith("Memo(")}function Mr(e){return Ar(e)?ot.apply(null,arguments):e}function Fr(e){return!!e.__k&&(rt(null,e),!0)}function Ir(e){return e&&(e.base||1===e.nodeType&&e)||null}var Dr=function(e,t){return e(t)},Gr=function(e,t){return e(t)},Nr=$e;function $r(e){e()}function Hr(e){return e}function Wr(){return[!1,$r]}var Ur=Lt,jr=Ar;function Br(e,t){var n=t(),r=Rt({h:{__:n,v:t}}),i=r[0].h,o=r[1];return Lt((function(){i.__=n,i.v=t,zr(i)&&o({h:i})}),[e,n,t]),Ot((function(){return zr(i)&&o({h:i}),e((function(){zr(i)&&o({h:i})}))}),[e]),n}function zr(e){var t,n,r=e.v,i=e.__;try{var o=r();return!((t=i)===(n=o)&&(0!==t||1/t==1/n)||t!=t&&n!=n)}catch(a){return!0}}var qr={useState:Rt,useId:$t,useReducer:At,useEffect:Ot,useLayoutEffect:Lt,useInsertionEffect:Ur,useTransition:Wr,useDeferredValue:Hr,useSyncExternalStore:Br,startTransition:$r,useRef:Mt,useImperativeHandle:Ft,useMemo:It,useCallback:Dt,useContext:Gt,useDebugValue:Nt,version:"18.3.1",Children:Jn,render:gr,hydrate:yr,unmountComponentAtNode:Fr,createPortal:ur,createElement:De,createContext:at,createFactory:Rr,cloneElement:Mr,createRef:Ne,Fragment:$e,isValidElement:Ar,isElement:jr,isFragment:Or,isMemo:Lr,findDOMNode:Ir,Component:He,PureComponent:qn,memo:Kn,forwardRef:Yn,flushSync:Gr,unstable_batchedUpdates:Dr,StrictMode:Nr,Suspense:rr,SuspenseList:ar,lazy:or,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Pr};const Kr=Object.freeze(Object.defineProperty({__proto__:null,Children:Jn,Component:He,Fragment:$e,PureComponent:qn,StrictMode:Nr,Suspense:rr,SuspenseList:ar,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Pr,cloneElement:Mr,createContext:at,createElement:De,createFactory:Rr,createPortal:ur,createRef:Ne,default:qr,findDOMNode:Ir,flushSync:Gr,forwardRef:Yn,hydrate:yr,isElement:jr,isFragment:Or,isMemo:Lr,isValidElement:Ar,lazy:or,memo:Kn,render:gr,startTransition:$r,unmountComponentAtNode:Fr,unstable_batchedUpdates:Dr,useCallback:Dt,useContext:Gt,useDebugValue:Nt,useDeferredValue:Hr,useEffect:Ot,useErrorBoundary:function(e){var t=Pt(vt++,10),n=Rt();return t.__=e,mt.componentDidCatch||(mt.componentDidCatch=function(e,r){t.__&&t.__(e,r),n[1](e)}),[n[0],function(){n[1](void 0)}]},useId:$t,useImperativeHandle:Ft,useInsertionEffect:Ur,useLayoutEffect:Lt,useMemo:It,useReducer:At,useRef:Mt,useState:Rt,useSyncExternalStore:Br,useTransition:Wr,version:"18.3.1"},Symbol.toStringTag,{value:"Module"}));var Vr=0;function Qr(e,t,n,r,i,o){t||(t={});var a,s,l=t;"ref"in t&&(a=t.ref,delete t.ref);var c={type:e,props:l,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--Vr,__i:-1,__u:0,__source:i,__self:o};if("function"==typeof e&&(a=e.defaultProps))for(s in a)void 0===l[s]&&(l[s]=a[s]);return we.vnode&&we.vnode(c),c}var Yr=at(void 0),Xr=e=>{const t=Gt(Yr);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Jr=({client:e,children:t})=>(Ot((()=>(e.mount(),()=>{e.unmount()})),[e]),Qr(Yr.Provider,{value:e,children:t})),Zr=at(!1);Zr.Provider;var ei=at(function(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}());function ti(e,t){return"function"==typeof e?e(...t):!!e}function ni(){}var ri=(e,t,n)=>t.fetchOptimistic(e).catch((()=>{n.clearReset()}));function ii(e,t,n){var r,i,o,a,s;const l=Xr(),c=Gt(Zr),u=Gt(ei),d=l.defaultQueryOptions(e);null==(i=null==(r=l.getDefaultOptions().queries)?void 0:r._experimental_beforeQuery)||i.call(r,d),d._optimisticResults=c?"isRestoring":"optimistic",(e=>{e.suspense&&(void 0===e.staleTime&&(e.staleTime=1e3),"number"==typeof e.gcTime&&(e.gcTime=Math.max(e.gcTime,1e3)))})(d),((e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))})(d,u),(e=>{Ot((()=>{e.clearReset()}),[e])})(u);const p=!l.getQueryCache().get(d.queryHash),[h]=Rt((()=>new t(l,d))),f=h.getOptimisticResult(d);if(Br(Dt((e=>{const t=c?ni:h.subscribe(Tn.batchCalls(e));return h.updateResult(),t}),[h,c]),(()=>h.getCurrentResult())),Ot((()=>{h.setOptions(d,{listeners:!1})}),[d,h]),((e,t)=>(null==e?void 0:e.suspense)&&t.isPending)(d,f))throw ri(d,h,u);if((({result:e,errorResetBoundary:t,throwOnError:n,query:r})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&ti(n,[e.error,r]))({result:f,errorResetBoundary:u,throwOnError:d.throwOnError,query:l.getQueryCache().get(d.queryHash)}))throw f.error;if(null==(a=null==(o=l.getDefaultOptions().queries)?void 0:o._experimental_afterQuery)||a.call(o,d,f),d.experimental_prefetchInRender&&!Xt&&((e,t)=>e.isLoading&&e.isFetching&&!t)(f,c)){const e=p?ri(d,h,u):null==(s=l.getQueryCache().get(d.queryHash))?void 0:s.promise;null==e||e.catch(ni).finally((()=>{h.updateResult()}))}return d.notifyOnChangeProps?f:h.trackResult(f)}function oi(e,t){return ii(e,$n)}const ai=at({account:{accountId:""},backend:{url:"",accessToken:""}});class si extends Error{constructor(e,t){super(e),__publicField(this,"_response"),this._response=t,Object.setPrototypeOf(this,si.prototype)}get response(){return this._response}}const li=async(e,t,n,r)=>{const i=await fetch(e,{method:n,body:r?JSON.stringify(r):void 0,headers:{"content-type":"application/json","x-app-version":"1.0.803",authorization:`Bearer ${t}`},signal:(null==AbortSignal?void 0:AbortSignal.timeout)&&AbortSignal.timeout(15e3)});if(!i.ok)throw new si(`[API Error] Status: ${i.status}, ${i.statusText}`,i);return i},ci=async(e,t,n,r)=>{const i=await li(e,t,n,r);return await i.json()},ui=e=>{const t=Gt(ai);return It((()=>e(t)),[e,t])};let di;const pi=()=>{if(di)return di;return di=new Nn({defaultOptions:{queries:{retry:(e,t)=>{var n;return t instanceof si&&![401,403].includes((null==(n=t.response)?void 0:n.status)||0)}}}}),di},hi="linkedAccount",fi="linkedProfilesForAccount",vi="salaryPackagedItem",mi="checkProfileSearchAuthorization",gi="payrollAdvice",yi="invoices",_i="/salary-packaging/admin/v1.0",wi=e=>async()=>{const t=new URL(`${e.backend.url}${_i}/accounts/${e.account.accountId}/auth`);return ci(t,e.backend.accessToken,"GET")},bi=e=>async t=>{const n=new URL(`${e.backend.url}${_i}/accounts/${e.account.accountId}/profile-search?search=${t}`);return ci(n,e.backend.accessToken,"GET")},xi=e=>async()=>{const t=new Date;t.setUTCDate((new Date).getUTCDate()-2);const n=new Date;n.setUTCDate((new Date).getUTCDate()+2);const r=new URL(`${e.backend.url}${_i}/ingest/clients`);await li(r,e.backend.accessToken,"POST",{startDate:t.toISOString().split("T")[0],endDate:n.toISOString().split("T")[0]})},ki=e=>async()=>{const t=new URL(`${e.backend.url}${_i}/accounts/${e.account.accountId}`);return ci(t,e.backend.accessToken,"GET")},Si=e=>async()=>{const t=new URL(`${e.backend.url}${_i}/accounts/${e.account.accountId}/profiles`);return ci(t,e.backend.accessToken,"GET")},Ei=e=>async t=>{const n=new URL(`${e.backend.url}${_i}/accounts/${e.account.accountId}/profiles/${t}/unlink`);await li(n,e.backend.accessToken,"POST")},Ci=e=>async(t,n)=>{const r=new URL(`${e.backend.url}${_i}/accounts/${e.account.accountId}/profiles/${t}/items/${n}`);return ci(r,e.backend.accessToken,"GET")},Ti=e=>async t=>{const n=new URL(`${e.backend.url}${_i}/accounts/${e.account.accountId}/profiles/${t}/payroll-advice`);return ci(n,e.backend.accessToken,"GET")},Pi=e=>async()=>{const t=new URL(`${e.backend.url}${_i}/accounts/${e.account.accountId}/invoices`);return ci(t,e.backend.accessToken,"GET")},Ri=()=>({checkProfileSearchAuthorization:ui(wi),searchProfilesForAccount:ui(bi),ingestClient:ui(xi),linkedAccount:ui(ki),linkedProfilesForAccount:ui(Si),unlinkProfile:ui(Ei),salaryPackagedItem:ui(Ci),payrollAdvice:ui(Ti),invoices:ui(Pi)});var Ai={};Object.defineProperty(Ai,"__esModule",{value:!0}),Ai.parse=function(e,t){const n=new Di,r=e.length;if(r<2)return n;const i=(null==t?void 0:t.decode)||$i;let o=0;do{const t=e.indexOf("=",o);if(-1===t)break;const a=e.indexOf(";",o),s=-1===a?r:a;if(t>s){o=e.lastIndexOf(";",t-1)+1;continue}const l=Gi(e,o,t),c=Ni(e,t,l),u=e.slice(l,c);if(void 0===n[u]){let r=Gi(e,t+1,s),o=Ni(e,s,r);const a=i(e.slice(r,o));n[u]=a}o=s+1}while(o<r);return n},Ai.serialize=function(e,t,n){const r=(null==n?void 0:n.encode)||encodeURIComponent;if(!Oi.test(e))throw new TypeError(`argument name is invalid: ${e}`);const i=r(t);if(!Li.test(i))throw new TypeError(`argument val is invalid: ${t}`);let o=e+"="+i;if(!n)return o;if(void 0!==n.maxAge){if(!Number.isInteger(n.maxAge))throw new TypeError(`option maxAge is invalid: ${n.maxAge}`);o+="; Max-Age="+n.maxAge}if(n.domain){if(!Mi.test(n.domain))throw new TypeError(`option domain is invalid: ${n.domain}`);o+="; Domain="+n.domain}if(n.path){if(!Fi.test(n.path))throw new TypeError(`option path is invalid: ${n.path}`);o+="; Path="+n.path}if(n.expires){if(!function(e){return"[object Date]"===Ii.call(e)}
2
2
  /**
3
3
  * react-router v7.1.1
4
4
  *
@@ -8,19 +8,19 @@ var __defProp=Object.defineProperty,__typeError=e=>{throw TypeError(e)},__defNor
8
8
  * LICENSE.md file in the root directory of this source tree.
9
9
  *
10
10
  * @license MIT
11
- */(n.expires)||!Number.isFinite(n.expires.valueOf()))throw new TypeError(`option expires is invalid: ${n.expires}`);o+="; Expires="+n.expires.toUTCString()}n.httpOnly&&(o+="; HttpOnly");n.secure&&(o+="; Secure");n.partitioned&&(o+="; Partitioned");if(n.priority){switch("string"==typeof n.priority?n.priority.toLowerCase():void 0){case"low":o+="; Priority=Low";break;case"medium":o+="; Priority=Medium";break;case"high":o+="; Priority=High";break;default:throw new TypeError(`option priority is invalid: ${n.priority}`)}}if(n.sameSite){switch("string"==typeof n.sameSite?n.sameSite.toLowerCase():n.sameSite){case!0:case"strict":o+="; SameSite=Strict";break;case"lax":o+="; SameSite=Lax";break;case"none":o+="; SameSite=None";break;default:throw new TypeError(`option sameSite is invalid: ${n.sameSite}`)}}return o};const Li=/^[\u0021-\u003A\u003C\u003E-\u007E]+$/,Mi=/^[\u0021-\u003A\u003C-\u007E]*$/,Fi=/^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,Ii=/^[\u0020-\u003A\u003D-\u007E]*$/,Di=Object.prototype.toString,Gi=(()=>{const e=function(){};return e.prototype=Object.create(null),e})();function Ni(e,t,n){do{const n=e.charCodeAt(t);if(32!==n&&9!==n)return t}while(++t<n);return n}function $i(e,t,n){for(;t>n;){const n=e.charCodeAt(--t);if(32!==n&&9!==n)return t+1}return n}function Hi(e){if(-1===e.indexOf("%"))return e;try{return decodeURIComponent(e)}catch(Fc){return e}}var Wi="popstate";function Ui(e={}){return function(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:o=!1}=r,a=i.history,s="POP",l=null,c=u();null==c&&(c=0,a.replaceState({...a.state,idx:c},""));function u(){return(a.state||{idx:null}).idx}function d(){s="POP";let e=u(),t=null==e?null:e-c;c=e,l&&l({action:s,location:v.location,delta:t})}function p(e,t){s="PUSH";let r=qi(v.location,e,t);n&&n(r,e),c=u()+1;let d=zi(r,c),p=v.createHref(r);try{a.pushState(d,"",p)}catch(h){if(h instanceof DOMException&&"DataCloneError"===h.name)throw h;i.location.assign(p)}o&&l&&l({action:s,location:v.location,delta:1})}function h(e,t){s="REPLACE";let r=qi(v.location,e,t);n&&n(r,e),c=u();let i=zi(r,c),d=v.createHref(r);a.replaceState(i,"",d),o&&l&&l({action:s,location:v.location,delta:0})}function f(e){let t="null"!==i.location.origin?i.location.origin:i.location.href,n="string"==typeof e?e:Ki(e);return n=n.replace(/ $/,"%20"),ji(t,`No window.location.(origin|href) available to create URL for href: ${n}`),new URL(n,t)}let v={get action(){return s},get location(){return e(i,a)},listen(e){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(Wi,d),l=e,()=>{i.removeEventListener(Wi,d),l=null}},createHref:e=>t(i,e),createURL:f,encodeLocation(e){let t=f(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:p,replace:h,go:e=>a.go(e)};return v}((function(e,t){let{pathname:n="/",search:r="",hash:i=""}=Vi(e.location.hash.substring(1));return n.startsWith("/")||n.startsWith(".")||(n="/"+n),qi("",{pathname:n,search:r,hash:i},t.state&&t.state.usr||null,t.state&&t.state.key||"default")}),(function(e,t){let n=e.document.querySelector("base"),r="";if(n&&n.getAttribute("href")){let t=e.location.href,n=t.indexOf("#");r=-1===n?t:t.slice(0,n)}return r+"#"+("string"==typeof t?t:Ki(t))}),(function(e,t){Bi("/"===e.pathname.charAt(0),`relative pathnames are not supported in hash history.push(${JSON.stringify(t)})`)}),e)}function ji(e,t){if(!1===e||null==e)throw new Error(t)}function Bi(e,t){if(!e){"undefined"!=typeof console&&console.warn(t);try{throw new Error(t)}catch(Fc){}}}function zi(e,t){return{usr:e.state,key:e.key,idx:t}}function qi(e,t,n=null,r){return{pathname:"string"==typeof e?e:e.pathname,search:"",hash:"",..."string"==typeof t?Vi(t):t,state:n,key:t&&t.key||r||Math.random().toString(36).substring(2,10)}}function Ki({pathname:e="/",search:t="",hash:n=""}){return t&&"?"!==t&&(e+="?"===t.charAt(0)?t:"?"+t),n&&"#"!==n&&(e+="#"===n.charAt(0)?n:"#"+n),e}function Vi(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function Qi(e,t,n="/"){return function(e,t,n,r){let i="string"==typeof t?Vi(t):t,o=co(i.pathname||"/",n);if(null==o)return null;let a=Yi(e);!function(e){e.sort(((e,t)=>e.score!==t.score?t.score-e.score:function(e,t){let n=e.length===t.length&&e.slice(0,-1).every(((e,n)=>e===t[n]));return n?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map((e=>e.childrenIndex)),t.routesMeta.map((e=>e.childrenIndex)))))}(a);let s=null;for(let l=0;null==s&&l<a.length;++l){let e=lo(o);s=ao(a[l],e,r)}return s}(e,t,n,!1)}function Yi(e,t=[],n=[],r=""){let i=(e,i,o)=>{let a={relativePath:void 0===o?e.path||"":o,caseSensitive:!0===e.caseSensitive,childrenIndex:i,route:e};a.relativePath.startsWith("/")&&(ji(a.relativePath.startsWith(r),`Absolute route path "${a.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),a.relativePath=a.relativePath.slice(r.length));let s=fo([r,a.relativePath]),l=n.concat(a);e.children&&e.children.length>0&&(ji(!0!==e.index,`Index routes must not have child routes. Please remove all child routes from route path "${s}".`),Yi(e.children,t,l,s)),(null!=e.path||e.index)&&t.push({path:s,score:oo(s,e.index),routesMeta:l})};return e.forEach(((e,t)=>{var n;if(""!==e.path&&(null==(n=e.path)?void 0:n.includes("?")))for(let r of Xi(e.path))i(e,t,r);else i(e,t)})),t}function Xi(e){let t=e.split("/");if(0===t.length)return[];let[n,...r]=t,i=n.endsWith("?"),o=n.replace(/\?$/,"");if(0===r.length)return i?[o,""]:[o];let a=Xi(r.join("/")),s=[];return s.push(...a.map((e=>""===e?o:[o,e].join("/")))),i&&s.push(...a),s.map((t=>e.startsWith("/")&&""===t?"/":t))}var Ji=/^:[\w-]+$/,Zi=3,eo=2,to=1,no=10,ro=-2,io=e=>"*"===e;function oo(e,t){let n=e.split("/"),r=n.length;return n.some(io)&&(r+=ro),t&&(r+=eo),n.filter((e=>!io(e))).reduce(((e,t)=>e+(Ji.test(t)?Zi:""===t?to:no)),r)}function ao(e,t,n=!1){let{routesMeta:r}=e,i={},o="/",a=[];for(let s=0;s<r.length;++s){let e=r[s],l=s===r.length-1,c="/"===o?t:t.slice(o.length)||"/",u=so({path:e.relativePath,caseSensitive:e.caseSensitive,end:l},c),d=e.route;if(!u&&l&&n&&!r[r.length-1].route.index&&(u=so({path:e.relativePath,caseSensitive:e.caseSensitive,end:!1},c)),!u)return null;Object.assign(i,u.params),a.push({params:i,pathname:fo([o,u.pathname]),pathnameBase:vo(fo([o,u.pathnameBase])),route:d}),"/"!==u.pathnameBase&&(o=fo([o,u.pathnameBase]))}return a}function so(e,t){"string"==typeof e&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=function(e,t=!1,n=!0){Bi("*"===e||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,((e,t,n)=>(r.push({paramName:t,isOptional:null!=n}),n?"/?([^\\/]+)?":"/([^\\/]+)")));e.endsWith("*")?(r.push({paramName:"*"}),i+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":""!==e&&"/"!==e&&(i+="(?:(?=\\/|$))");let o=new RegExp(i,t?void 0:"i");return[o,r]}(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let o=i[0],a=o.replace(/(.)\/+$/,"$1"),s=i.slice(1);return{params:r.reduce(((e,{paramName:t,isOptional:n},r)=>{if("*"===t){let e=s[r]||"";a=o.slice(0,o.length-e.length).replace(/(.)\/+$/,"$1")}const i=s[r];return e[t]=n&&!i?void 0:(i||"").replace(/%2F/g,"/"),e}),{}),pathname:o,pathnameBase:a,pattern:e}}function lo(e){try{return e.split("/").map((e=>decodeURIComponent(e).replace(/\//g,"%2F"))).join("/")}catch(t){return Bi(!1,`The URL path "${e}" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function co(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&"/"!==r?null:e.slice(n)||"/"}function uo(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function po(e){let t=function(e){return e.filter(((e,t)=>0===t||e.route.path&&e.route.path.length>0))}(e);return t.map(((e,n)=>n===t.length-1?e.pathname:e.pathnameBase))}function ho(e,t,n,r=!1){let i;"string"==typeof e?i=Vi(e):(i={...e},ji(!i.pathname||!i.pathname.includes("?"),uo("?","pathname","search",i)),ji(!i.pathname||!i.pathname.includes("#"),uo("#","pathname","hash",i)),ji(!i.search||!i.search.includes("#"),uo("#","search","hash",i)));let o,a=""===e||""===i.pathname,s=a?"/":i.pathname;if(null==s)o=n;else{let e=t.length-1;if(!r&&s.startsWith("..")){let t=s.split("/");for(;".."===t[0];)t.shift(),e-=1;i.pathname=t.join("/")}o=e>=0?t[e]:"/"}let l=function(e,t="/"){let{pathname:n,search:r="",hash:i=""}="string"==typeof e?Vi(e):e,o=n?n.startsWith("/")?n:function(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach((e=>{".."===e?n.length>1&&n.pop():"."!==e&&n.push(e)})),n.length>1?n.join("/"):"/"}(n,t):t;return{pathname:o,search:mo(r),hash:go(i)}}(i,o),c=s&&"/"!==s&&s.endsWith("/"),u=(a||"."===s)&&n.endsWith("/");return l.pathname.endsWith("/")||!c&&!u||(l.pathname+="/"),l}var fo=e=>e.join("/").replace(/\/\/+/g,"/"),vo=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),mo=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",go=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";var yo=["POST","PUT","PATCH","DELETE"];new Set(yo);var _o=["GET",...yo];new Set(_o);var wo=at(null);wo.displayName="DataRouter";var bo=at(null);bo.displayName="DataRouterState";var xo=at({isTransitioning:!1});xo.displayName="ViewTransition",at(new Map).displayName="Fetchers",at(null).displayName="Await";var ko=at(null);ko.displayName="Navigation";var So=at(null);So.displayName="Location";var Eo=at({outlet:null,matches:[],isDataRoute:!1});Eo.displayName="Route";var Co=at(null);function To(){return null!=Gt(So)}function Po(){return ji(To(),"useLocation() may be used only in the context of a <Router> component."),Gt(So).location}Co.displayName="RouteError";var Ro="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Ao(e){Gt(ko).static||Lt(e)}function Oo(){let{isDataRoute:e}=Gt(Eo);return e?function(){let{router:e}=function(e){let t=Gt(wo);return ji(t,Ho(e)),t}("useNavigate"),t=Wo("useNavigate"),n=Mt(!1);return Ao((()=>{n.current=!0})),Dt((async(r,i={})=>{Bi(n.current,Ro),n.current&&("number"==typeof r?e.navigate(r):await e.navigate(r,{fromRouteId:t,...i}))}),[e,t])}():function(){ji(To(),"useNavigate() may be used only in the context of a <Router> component.");let e=Gt(wo),{basename:t,navigator:n}=Gt(ko),{matches:r}=Gt(Eo),{pathname:i}=Po(),o=JSON.stringify(po(r)),a=Mt(!1);return Ao((()=>{a.current=!0})),Dt(((r,s={})=>{if(Bi(a.current,Ro),!a.current)return;if("number"==typeof r)return void n.go(r);let l=ho(r,JSON.parse(o),i,"path"===s.relative);null==e&&"/"!==t&&(l.pathname="/"===l.pathname?t:fo([t,l.pathname])),(s.replace?n.replace:n.push)(l,s.state,s)}),[t,n,o,i,e])}()}var Lo=at(null);function Mo(e){let t=Gt(Eo).outlet;return t?De(Lo.Provider,{value:e},t):t}function Fo(e,{relative:t}={}){let{matches:n}=Gt(Eo),{pathname:r}=Po(),i=JSON.stringify(po(n));return It((()=>ho(e,JSON.parse(i),r,"path"===t)),[e,i,r,t])}function Io(e,t,n,r){var i;ji(To(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:o}=Gt(ko),{matches:a}=Gt(Eo),s=a[a.length-1],l=s?s.params:{},c=s?s.pathname:"/",u=s?s.pathnameBase:"/",d=s&&s.route;{let e=d&&d.path||"";jo(c,!d||e.endsWith("*")||e.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${c}" (under <Route path="${e}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.\n\nPlease change the parent <Route path="${e}"> to <Route path="${"/"===e?"*":`${e}/*`}">.`)}let p,h=Po();if(t){let e="string"==typeof t?Vi(t):t;ji("/"===u||(null==(i=e.pathname)?void 0:i.startsWith(u)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${u}" but pathname "${e.pathname}" was given in the \`location\` prop.`),p=e}else p=h;let f=p.pathname||"/",v=f;if("/"!==u){let e=u.replace(/^\//,"").split("/");v="/"+f.replace(/^\//,"").split("/").slice(e.length).join("/")}let m=Qi(e,{pathname:v});Bi(d||null!=m,`No routes matched location "${p.pathname}${p.search}${p.hash}" `),Bi(null==m||void 0!==m[m.length-1].route.element||void 0!==m[m.length-1].route.Component||void 0!==m[m.length-1].route.lazy,`Matched leaf route at location "${p.pathname}${p.search}${p.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let g=function(e,t=[],n=null){if(null==e){if(!n)return null;if(n.errors)e=n.matches;else{if(0!==t.length||n.initialized||!(n.matches.length>0))return null;e=n.matches}}let r=e,i=null==n?void 0:n.errors;if(null!=i){let e=r.findIndex((e=>e.route.id&&void 0!==(null==i?void 0:i[e.route.id])));ji(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(i).join(",")}`),r=r.slice(0,Math.min(r.length,e+1))}let o=!1,a=-1;if(n)for(let s=0;s<r.length;s++){let e=r[s];if((e.route.HydrateFallback||e.route.hydrateFallbackElement)&&(a=s),e.route.id){let{loaderData:t,errors:i}=n,s=e.route.loader&&!t.hasOwnProperty(e.route.id)&&(!i||void 0===i[e.route.id]);if(e.route.lazy||s){o=!0,r=a>=0?r.slice(0,a+1):[r[0]];break}}}return r.reduceRight(((e,s,l)=>{let c,u=!1,d=null,p=null;n&&(c=i&&s.route.id?i[s.route.id]:void 0,d=s.route.errorElement||Go,o&&(a<0&&0===l?(jo("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),u=!0,p=null):a===l&&(u=!0,p=s.route.hydrateFallbackElement||null)));let h=t.concat(r.slice(0,l+1)),f=()=>{let t;return t=c?d:u?p:s.route.Component?De(s.route.Component,null):s.route.element?s.route.element:e,De($o,{match:s,routeContext:{outlet:e,matches:h,isDataRoute:null!=n},children:t})};return n&&(s.route.ErrorBoundary||s.route.errorElement||0===l)?De(No,{location:n.location,revalidation:n.revalidation,component:d,error:c,children:f(),routeContext:{outlet:null,matches:h,isDataRoute:!0}}):f()}),null)}(m&&m.map((e=>Object.assign({},e,{params:Object.assign({},l,e.params),pathname:fo([u,o.encodeLocation?o.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?u:fo([u,o.encodeLocation?o.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])}))),a,n,r);return t&&g?De(So.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...p},navigationType:"POP"}},g):g}function Do(){let e=function(){var e;let t=Gt(Co),n=function(e){let t=Gt(bo);return ji(t,Ho(e)),t}("useRouteError"),r=Wo("useRouteError");if(void 0!==t)return t;return null==(e=n.errors)?void 0:e[r]}(),t=function(e){return null!=e&&"number"==typeof e.status&&"string"==typeof e.statusText&&"boolean"==typeof e.internal&&"data"in e}(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",i={padding:"0.5rem",backgroundColor:r},o={padding:"2px 4px",backgroundColor:r},a=null;return console.error("Error handled by React Router default ErrorBoundary:",e),a=De($e,null,De("p",null,"💿 Hey developer 👋"),De("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",De("code",{style:o},"ErrorBoundary")," or"," ",De("code",{style:o},"errorElement")," prop on your route.")),De($e,null,De("h2",null,"Unexpected Application Error!"),De("h3",{style:{fontStyle:"italic"}},t),n?De("pre",{style:i},n):null,a)}var Go=De(Do,null),No=class extends He{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||"idle"!==t.revalidation&&"idle"===e.revalidation?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:void 0!==e.error?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){console.error("React Router caught the following error during render",e,t)}render(){return void 0!==this.state.error?De(Eo.Provider,{value:this.props.routeContext},De(Co.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function $o({routeContext:e,match:t,children:n}){let r=Gt(wo);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),De(Eo.Provider,{value:e},n)}function Ho(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Wo(e){let t=function(e){let t=Gt(Eo);return ji(t,Ho(e)),t}(e),n=t.matches[t.matches.length-1];return ji(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}var Uo={};function jo(e,t,n){t||Uo[e]||(Uo[e]=!0,Bi(!1,n))}function Bo({to:e,replace:t,state:n,relative:r}){ji(To(),"<Navigate> may be used only in the context of a <Router> component.");let{static:i}=Gt(ko);Bi(!i,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:o}=Gt(Eo),{pathname:a}=Po(),s=Oo(),l=ho(e,po(o),a,"path"===r),c=JSON.stringify(l);return Ot((()=>{s(JSON.parse(c),{replace:t,state:n,relative:r})}),[s,c,r,t,n]),null}function zo(e){return Mo(e.context)}function qo(e){ji(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function Ko({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:i,static:o=!1}){ji(!To(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let a=e.replace(/^\/*/,"/"),s=It((()=>({basename:a,navigator:i,static:o,future:{}})),[a,i,o]);"string"==typeof n&&(n=Vi(n));let{pathname:l="/",search:c="",hash:u="",state:d=null,key:p="default"}=n,h=It((()=>{let e=co(l,a);return null==e?null:{location:{pathname:e,search:c,hash:u,state:d,key:p},navigationType:r}}),[a,l,c,u,d,p,r]);return Bi(null!=h,`<Router basename="${a}"> is not able to match the URL "${l}${c}${u}" because it does not start with the basename, so the <Router> won't render anything.`),null==h?null:De(ko.Provider,{value:s},De(So.Provider,{children:t,value:h}))}function Vo({children:e,location:t}){return Io(Qo(e),t)}function Qo(e,t=[]){let n=[];return Jn.forEach(e,((e,r)=>{if(!Ar(e))return;let i=[...t,r];if(e.type===$e)return void n.push.apply(n,Qo(e.props.children,i));ji(e.type===qo,`[${"string"==typeof e.type?e.type:e.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),ji(!e.props.index||!e.props.children,"An index route cannot have child routes.");let o={id:e.props.id||i.join("-"),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,loader:e.props.loader,action:e.props.action,hydrateFallbackElement:e.props.hydrateFallbackElement,HydrateFallback:e.props.HydrateFallback,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:!0===e.props.hasErrorBoundary||null!=e.props.ErrorBoundary||null!=e.props.errorElement,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(o.children=Qo(e.props.children,i)),n.push(o)})),n}Kn((function({routes:e,future:t,state:n}){return Io(e,void 0,n,t)}));var Yo="get",Xo="application/x-www-form-urlencoded";function Jo(e){return null!=e&&"string"==typeof e.tagName}var Zo=null;var ea=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function ta(e){return null==e||ea.has(e)?e:(Bi(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Xo}"`),null)}function na(e,t){let n,r,i,o,a;if(Jo(s=e)&&"form"===s.tagName.toLowerCase()){let a=e.getAttribute("action");r=a?co(a,t):null,n=e.getAttribute("method")||Yo,i=ta(e.getAttribute("enctype"))||Xo,o=new FormData(e)}else if(function(e){return Jo(e)&&"button"===e.tagName.toLowerCase()}(e)||function(e){return Jo(e)&&"input"===e.tagName.toLowerCase()}(e)&&("submit"===e.type||"image"===e.type)){let a=e.form;if(null==a)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let s=e.getAttribute("formaction")||a.getAttribute("action");if(r=s?co(s,t):null,n=e.getAttribute("formmethod")||a.getAttribute("method")||Yo,i=ta(e.getAttribute("formenctype"))||ta(a.getAttribute("enctype"))||Xo,o=new FormData(a,e),!function(){if(null===Zo)try{new FormData(document.createElement("form"),0),Zo=!1}catch(Fc){Zo=!0}return Zo}()){let{name:t,type:n,value:r}=e;if("image"===n){let e=t?`${t}.`:"";o.append(`${e}x`,"0"),o.append(`${e}y`,"0")}else t&&o.append(t,r)}}else{if(Jo(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=Yo,r=null,i=Xo,a=e}var s;return o&&"text/plain"===i&&(a=o,o=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:o,body:a}}function ra(e,t){if(!1===e||null==e)throw new Error(t)}function ia(e){return null!=e&&(null==e.href?"preload"===e.rel&&"string"==typeof e.imageSrcSet&&"string"==typeof e.imageSizes:"string"==typeof e.rel&&"string"==typeof e.href)}async function oa(e,t,n){return function(e,t){let n=new Set;return new Set(t),e.reduce(((e,t)=>{let r=JSON.stringify(function(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}(t));return n.has(r)||(n.add(r),e.push({key:r,link:t})),e}),[])}((await Promise.all(e.map((async e=>{let r=t.routes[e.route.id];if(r){let e=await async function(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise((()=>{}))}}(r,n);return e.links?e.links():[]}return[]})))).flat(1).filter(ia).filter((e=>"stylesheet"===e.rel||"preload"===e.rel)).map((e=>"stylesheet"===e.rel?{...e,rel:"prefetch",as:"style"}:{...e,rel:"prefetch"})))}function aa(e,t,n,r,i,o){let a=(e,t)=>!n[t]||e.route.id!==n[t].route.id,s=(e,t)=>{var r;return n[t].pathname!==e.pathname||(null==(r=n[t].route.path)?void 0:r.endsWith("*"))&&n[t].params["*"]!==e.params["*"]};return"assets"===o?t.filter(((e,t)=>a(e,t)||s(e,t))):"data"===o?t.filter(((t,o)=>{var l;let c=r.routes[t.route.id];if(!c||!c.hasLoader)return!1;if(a(t,o)||s(t,o))return!0;if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:(null==(l=n[0])?void 0:l.params)||{},nextUrl:new URL(e,window.origin),nextParams:t.params,defaultShouldRevalidate:!0});if("boolean"==typeof r)return r}return!0})):[]}function sa(e,t){return n=e.map((e=>{let n=t.routes[e.route.id];if(!n)return[];let r=[n.module];return n.imports&&(r=r.concat(n.imports)),r})).flat(1),[...new Set(n)];var n}var la=at(void 0);function ca(){let e=Gt(la);return ra(e,"You must render this element inside a <HydratedRouter> element"),e}function ua(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function da({page:e,...t}){let{router:n}=function(){let e=Gt(wo);return ra(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}(),r=It((()=>Qi(n.routes,e,n.basename)),[n.routes,e,n.basename]);return r?De(pa,{page:e,matches:r,...t}):null}function pa({page:e,matches:t,...n}){let r=Po(),{manifest:i,routeModules:o}=ca(),{loaderData:a,matches:s}=function(){let e=Gt(bo);return ra(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}(),l=It((()=>aa(e,t,s,i,r,"data")),[e,t,s,i,r]),c=It((()=>aa(e,t,s,i,r,"assets")),[e,t,s,i,r]),u=It((()=>{if(e===r.pathname+r.search+r.hash)return[];let n=new Set,s=!1;if(t.forEach((e=>{var t;let r=i.routes[e.route.id];r&&r.hasLoader&&(!l.some((t=>t.route.id===e.route.id))&&e.route.id in a&&(null==(t=o[e.route.id])?void 0:t.shouldRevalidate)||r.hasClientLoader?s=!0:n.add(e.route.id))})),0===n.size)return[];let c=function(e){let t="string"==typeof e?new URL(e,"undefined"==typeof window?"server://singlefetch/":window.location.origin):e;return"/"===t.pathname?t.pathname="_root.data":t.pathname=`${t.pathname.replace(/\/$/,"")}.data`,t}(e);return s&&n.size>0&&c.searchParams.set("_routes",t.filter((e=>n.has(e.route.id))).map((e=>e.route.id)).join(",")),[c.pathname+c.search]}),[a,r,i,l,t,e,o]),d=It((()=>sa(c,i)),[c,i]),p=function(e){let{manifest:t,routeModules:n}=ca(),[r,i]=Rt([]);return Ot((()=>{let r=!1;return oa(e,t,n).then((e=>{r||i(e)})),()=>{r=!0}}),[e,t,n]),r}(c);return De($e,null,u.map((e=>De("link",{key:e,rel:"prefetch",as:"fetch",href:e,...n}))),d.map((e=>De("link",{key:e,rel:"modulepreload",href:e,...n}))),p.map((({key:e,link:t})=>De("link",{key:e,...t}))))}function ha(...e){return t=>{e.forEach((e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)}))}}la.displayName="FrameworkContext";var fa="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement;try{fa&&(window.__reactRouterVersion="7.1.1")}catch(Fc){}function va({basename:e,children:t,window:n}){let r=Mt();null==r.current&&(r.current=Ui({window:n,v5Compat:!0}));let i=r.current,[o,a]=Rt({action:i.action,location:i.location}),s=Dt((e=>{$r((()=>a(e)))}),[a]);return Lt((()=>i.listen(s)),[i,s]),De(Ko,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:i})}var ma=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,ga=Yn((function({onClick:e,discover:t="render",prefetch:n="none",relative:r,reloadDocument:i,replace:o,state:a,target:s,to:l,preventScrollReset:c,viewTransition:u,...d},p){let h,{basename:f}=Gt(ko),v="string"==typeof l&&ma.test(l),m=!1;if("string"==typeof l&&v&&(h=l,fa))try{let e=new URL(window.location.href),t=l.startsWith("//")?new URL(e.protocol+l):new URL(l),n=co(t.pathname,f);t.origin===e.origin&&null!=n?l=n+t.search+t.hash:m=!0}catch(Fc){Bi(!1,`<Link to="${l}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let g=function(e,{relative:t}={}){ji(To(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=Gt(ko),{hash:i,pathname:o,search:a}=Fo(e,{relative:t}),s=o;return"/"!==n&&(s="/"===o?n:fo([n,o])),r.createHref({pathname:s,search:a,hash:i})}(l,{relative:r}),[y,_,w]=function(e,t){let n=Gt(la),[r,i]=Rt(!1),[o,a]=Rt(!1),{onFocus:s,onBlur:l,onMouseEnter:c,onMouseLeave:u,onTouchStart:d}=t,p=Mt(null);Ot((()=>{if("render"===e&&a(!0),"viewport"===e){let e=new IntersectionObserver((e=>{e.forEach((e=>{a(e.isIntersecting)}))}),{threshold:.5});return p.current&&e.observe(p.current),()=>{e.disconnect()}}}),[e]),Ot((()=>{if(r){let e=setTimeout((()=>{a(!0)}),100);return()=>{clearTimeout(e)}}}),[r]);let h=()=>{i(!0)},f=()=>{i(!1),a(!1)};return n?"intent"!==e?[o,p,{}]:[o,p,{onFocus:ua(s,h),onBlur:ua(l,f),onMouseEnter:ua(c,h),onMouseLeave:ua(u,f),onTouchStart:ua(d,h)}]:[!1,p,{}]}(n,d),b=function(e,{target:t,replace:n,state:r,preventScrollReset:i,relative:o,viewTransition:a}={}){let s=Oo(),l=Po(),c=Fo(e,{relative:o});return Dt((u=>{if(function(e,t){return!(0!==e.button||t&&"_self"!==t||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e))}(u,t)){u.preventDefault();let t=void 0!==n?n:Ki(l)===Ki(c);s(e,{replace:t,state:r,preventScrollReset:i,relative:o,viewTransition:a})}}),[l,s,c,n,r,t,e,i,o,a])}(l,{replace:o,state:a,target:s,preventScrollReset:c,relative:r,viewTransition:u});let x=De("a",{...d,...w,href:h||g,onClick:m||i?e:function(t){e&&e(t),t.defaultPrevented||b(t)},ref:ha(p,_),target:s,"data-discover":v||"render"!==t?void 0:"true"});return y&&!v?De($e,null,x,De(da,{page:g})):x}));ga.displayName="Link";var ya=Yn((function({"aria-current":e="page",caseSensitive:t=!1,className:n="",end:r=!1,style:i,to:o,viewTransition:a,children:s,...l},c){let u=Fo(o,{relative:l.relative}),d=Po(),p=Gt(bo),{navigator:h,basename:f}=Gt(ko),v=null!=p&&function(e,t={}){let n=Gt(xo);ji(null!=n,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=_a("useViewTransitionState"),i=Fo(e,{relative:t.relative});if(!n.isTransitioning)return!1;let o=co(n.currentLocation.pathname,r)||n.currentLocation.pathname,a=co(n.nextLocation.pathname,r)||n.nextLocation.pathname;return null!=so(i.pathname,a)||null!=so(i.pathname,o)}(u)&&!0===a,m=h.encodeLocation?h.encodeLocation(u).pathname:u.pathname,g=d.pathname,y=p&&p.navigation&&p.navigation.location?p.navigation.location.pathname:null;t||(g=g.toLowerCase(),y=y?y.toLowerCase():null,m=m.toLowerCase()),y&&f&&(y=co(y,f)||y);const _="/"!==m&&m.endsWith("/")?m.length-1:m.length;let w,b=g===m||!r&&g.startsWith(m)&&"/"===g.charAt(_),x=null!=y&&(y===m||!r&&y.startsWith(m)&&"/"===y.charAt(m.length)),k={isActive:b,isPending:x,isTransitioning:v},S=b?e:void 0;w="function"==typeof n?n(k):[n,b?"active":null,x?"pending":null,v?"transitioning":null].filter(Boolean).join(" ");let E="function"==typeof i?i(k):i;return De(ga,{...l,"aria-current":S,className:w,ref:c,style:E,to:o,viewTransition:a},"function"==typeof s?s(k):s)}));function _a(e){let t=Gt(wo);return ji(t,function(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}(e)),t}ya.displayName="NavLink",Yn((({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:o,method:a=Yo,action:s,onSubmit:l,relative:c,preventScrollReset:u,viewTransition:d,...p},h)=>{let f=function(){let{router:e}=_a("useSubmit"),{basename:t}=Gt(ko),n=Wo("useRouteId");return Dt((async(r,i={})=>{let{action:o,method:a,encType:s,formData:l,body:c}=na(r,t);if(!1===i.navigate){let t=i.fetcherKey||ba();await e.fetch(t,n,i.action||o,{preventScrollReset:i.preventScrollReset,formData:l,body:c,formMethod:i.method||a,formEncType:i.encType||s,flushSync:i.flushSync})}else await e.navigate(i.action||o,{preventScrollReset:i.preventScrollReset,formData:l,body:c,formMethod:i.method||a,formEncType:i.encType||s,replace:i.replace,state:i.state,fromRouteId:n,flushSync:i.flushSync,viewTransition:i.viewTransition})}),[e,t,n])}(),v=function(e,{relative:t}={}){let{basename:n}=Gt(ko),r=Gt(Eo);ji(r,"useFormAction must be used inside a RouteContext");let[i]=r.matches.slice(-1),o={...Fo(e||".",{relative:t})},a=Po();if(null==e){o.search=a.search;let e=new URLSearchParams(o.search),t=e.getAll("index");if(t.some((e=>""===e))){e.delete("index"),t.filter((e=>e)).forEach((t=>e.append("index",t)));let n=e.toString();o.search=n?`?${n}`:""}}e&&"."!==e||!i.route.index||(o.search=o.search?o.search.replace(/^\?/,"?index&"):"?index");"/"!==n&&(o.pathname="/"===o.pathname?n:fo([n,o.pathname]));return Ki(o)}(s,{relative:c}),m="get"===a.toLowerCase()?"get":"post",g="string"==typeof s&&ma.test(s);return De("form",{ref:h,method:m,action:v,onSubmit:r?l:e=>{if(l&&l(e),e.defaultPrevented)return;e.preventDefault();let r=e.nativeEvent.submitter,s=(null==r?void 0:r.getAttribute("formmethod"))||a;f(r||e.currentTarget,{fetcherKey:t,method:s,navigate:n,replace:i,state:o,relative:c,preventScrollReset:u,viewTransition:d})},...p,"data-discover":g||"render"!==e?void 0:"true"})})).displayName="Form";var wa=0,ba=()=>`__${String(++wa)}__`;function xa(){return xa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},xa.apply(null,arguments)}new TextEncoder;var ka=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(t);try{n.insertRule(e,n.cssRules.length)}catch(Fc){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach((function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)})),this.tags=[],this.ctr=0},e}(),Sa="-ms-",Ea="-moz-",Ca="-webkit-",Ta="comm",Pa="rule",Ra="decl",Aa="@keyframes",Oa=Math.abs,La=String.fromCharCode,Ma=Object.assign;function Fa(e){return e.trim()}function Ia(e,t,n){return e.replace(t,n)}function Da(e,t){return e.indexOf(t)}function Ga(e,t){return 0|e.charCodeAt(t)}function Na(e,t,n){return e.slice(t,n)}function $a(e){return e.length}function Ha(e){return e.length}function Wa(e,t){return t.push(e),e}var Ua=1,ja=1,Ba=0,za=0,qa=0,Ka="";function Va(e,t,n,r,i,o,a){return{value:e,root:t,parent:n,type:r,props:i,children:o,line:Ua,column:ja,length:a,return:""}}function Qa(e,t){return Ma(Va("",null,null,"",null,null,0),e,{length:-e.length},t)}function Ya(){return qa=za<Ba?Ga(Ka,za++):0,ja++,10===qa&&(ja=1,Ua++),qa}function Xa(){return Ga(Ka,za)}function Ja(){return za}function Za(e,t){return Na(Ka,e,t)}function es(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function ts(e){return Ua=ja=1,Ba=$a(Ka=e),za=0,[]}function ns(e){return Ka="",e}function rs(e){return Fa(Za(za-1,as(91===e?e+2:40===e?e+1:e)))}function is(e){for(;(qa=Xa())&&qa<33;)Ya();return es(e)>2||es(qa)>3?"":" "}function os(e,t){for(;--t&&Ya()&&!(qa<48||qa>102||qa>57&&qa<65||qa>70&&qa<97););return Za(e,Ja()+(t<6&&32==Xa()&&32==Ya()))}function as(e){for(;Ya();)switch(qa){case e:return za;case 34:case 39:34!==e&&39!==e&&as(qa);break;case 40:41===e&&as(e);break;case 92:Ya()}return za}function ss(e,t){for(;Ya()&&e+qa!==57&&(e+qa!==84||47!==Xa()););return"/*"+Za(t,za-1)+"*"+La(47===e?e:Ya())}function ls(e){for(;!es(Xa());)Ya();return Za(e,za)}function cs(e){return ns(us("",null,null,null,[""],e=ts(e),0,[0],e))}function us(e,t,n,r,i,o,a,s,l){for(var c=0,u=0,d=a,p=0,h=0,f=0,v=1,m=1,g=1,y=0,_="",w=i,b=o,x=r,k=_;m;)switch(f=y,y=Ya()){case 40:if(108!=f&&58==Ga(k,d-1)){-1!=Da(k+=Ia(rs(y),"&","&\f"),"&\f")&&(g=-1);break}case 34:case 39:case 91:k+=rs(y);break;case 9:case 10:case 13:case 32:k+=is(f);break;case 92:k+=os(Ja()-1,7);continue;case 47:switch(Xa()){case 42:case 47:Wa(ps(ss(Ya(),Ja()),t,n),l);break;default:k+="/"}break;case 123*v:s[c++]=$a(k)*g;case 125*v:case 59:case 0:switch(y){case 0:case 125:m=0;case 59+u:-1==g&&(k=Ia(k,/\f/g,"")),h>0&&$a(k)-d&&Wa(h>32?hs(k+";",r,n,d-1):hs(Ia(k," ","")+";",r,n,d-2),l);break;case 59:k+=";";default:if(Wa(x=ds(k,t,n,c,u,i,s,_,w=[],b=[],d),o),123===y)if(0===u)us(k,t,x,x,w,o,d,s,b);else switch(99===p&&110===Ga(k,3)?100:p){case 100:case 108:case 109:case 115:us(e,x,x,r&&Wa(ds(e,x,x,0,0,i,s,_,i,w=[],d),b),i,b,d,s,r?w:b);break;default:us(k,x,x,x,[""],b,0,s,b)}}c=u=h=0,v=g=1,_=k="",d=a;break;case 58:d=1+$a(k),h=f;default:if(v<1)if(123==y)--v;else if(125==y&&0==v++&&125==(qa=za>0?Ga(Ka,--za):0,ja--,10===qa&&(ja=1,Ua--),qa))continue;switch(k+=La(y),y*v){case 38:g=u>0?1:(k+="\f",-1);break;case 44:s[c++]=($a(k)-1)*g,g=1;break;case 64:45===Xa()&&(k+=rs(Ya())),p=Xa(),u=d=$a(_=k+=ls(Ja())),y++;break;case 45:45===f&&2==$a(k)&&(v=0)}}return o}function ds(e,t,n,r,i,o,a,s,l,c,u){for(var d=i-1,p=0===i?o:[""],h=Ha(p),f=0,v=0,m=0;f<r;++f)for(var g=0,y=Na(e,d+1,d=Oa(v=a[f])),_=e;g<h;++g)(_=Fa(v>0?p[g]+" "+y:Ia(y,/&\f/g,p[g])))&&(l[m++]=_);return Va(e,t,n,0===i?Pa:s,l,c,u)}function ps(e,t,n){return Va(e,t,n,Ta,La(qa),Na(e,2,-2),0)}function hs(e,t,n,r){return Va(e,t,n,Ra,Na(e,0,r),Na(e,r+1,-1),r)}function fs(e,t){for(var n="",r=Ha(e),i=0;i<r;i++)n+=t(e[i],i,e,t)||"";return n}function vs(e,t,n,r){switch(e.type){case"@layer":if(e.children.length)break;case"@import":case Ra:return e.return=e.return||e.value;case Ta:return"";case Aa:return e.return=e.value+"{"+fs(e.children,r)+"}";case Pa:e.value=e.props.join(",")}return $a(n=fs(e.children,r))?e.return=e.value+"{"+n+"}":""}function ms(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}var gs=function(e,t,n){for(var r=0,i=0;r=i,i=Xa(),38===r&&12===i&&(t[n]=1),!es(i);)Ya();return Za(e,za)},ys=function(e,t){return ns(function(e,t){var n=-1,r=44;do{switch(es(r)){case 0:38===r&&12===Xa()&&(t[n]=1),e[n]+=gs(za-1,t,n);break;case 2:e[n]+=rs(r);break;case 4:if(44===r){e[++n]=58===Xa()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=La(r)}}while(r=Ya());return e}(ts(e),t))},_s=new WeakMap,ws=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||_s.get(n))&&!r){_s.set(e,!0);for(var i=[],o=ys(t,i),a=n.props,s=0,l=0;s<o.length;s++)for(var c=0;c<a.length;c++,l++)e.props[l]=i[s]?o[s].replace(/&\f/g,a[c]):a[c]+" "+o[s]}}},bs=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function xs(e,t){switch(function(e,t){return 45^Ga(e,0)?(((t<<2^Ga(e,0))<<2^Ga(e,1))<<2^Ga(e,2))<<2^Ga(e,3):0}(e,t)){case 5103:return Ca+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Ca+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Ca+e+Ea+e+Sa+e+e;case 6828:case 4268:return Ca+e+Sa+e+e;case 6165:return Ca+e+Sa+"flex-"+e+e;case 5187:return Ca+e+Ia(e,/(\w+).+(:[^]+)/,Ca+"box-$1$2"+Sa+"flex-$1$2")+e;case 5443:return Ca+e+Sa+"flex-item-"+Ia(e,/flex-|-self/,"")+e;case 4675:return Ca+e+Sa+"flex-line-pack"+Ia(e,/align-content|flex-|-self/,"")+e;case 5548:return Ca+e+Sa+Ia(e,"shrink","negative")+e;case 5292:return Ca+e+Sa+Ia(e,"basis","preferred-size")+e;case 6060:return Ca+"box-"+Ia(e,"-grow","")+Ca+e+Sa+Ia(e,"grow","positive")+e;case 4554:return Ca+Ia(e,/([^-])(transform)/g,"$1"+Ca+"$2")+e;case 6187:return Ia(Ia(Ia(e,/(zoom-|grab)/,Ca+"$1"),/(image-set)/,Ca+"$1"),e,"")+e;case 5495:case 3959:return Ia(e,/(image-set\([^]*)/,Ca+"$1$`$1");case 4968:return Ia(Ia(e,/(.+:)(flex-)?(.*)/,Ca+"box-pack:$3"+Sa+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Ca+e+e;case 4095:case 3583:case 4068:case 2532:return Ia(e,/(.+)-inline(.+)/,Ca+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if($a(e)-1-t>6)switch(Ga(e,t+1)){case 109:if(45!==Ga(e,t+4))break;case 102:return Ia(e,/(.+:)(.+)-([^]+)/,"$1"+Ca+"$2-$3$1"+Ea+(108==Ga(e,t+3)?"$3":"$2-$3"))+e;case 115:return~Da(e,"stretch")?xs(Ia(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==Ga(e,t+1))break;case 6444:switch(Ga(e,$a(e)-3-(~Da(e,"!important")&&10))){case 107:return Ia(e,":",":"+Ca)+e;case 101:return Ia(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Ca+(45===Ga(e,14)?"inline-":"")+"box$3$1"+Ca+"$2$3$1"+Sa+"$2box$3")+e}break;case 5936:switch(Ga(e,t+11)){case 114:return Ca+e+Sa+Ia(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Ca+e+Sa+Ia(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Ca+e+Sa+Ia(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Ca+e+Sa+e+e}return e}var ks=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case Ra:e.return=xs(e.value,e.length);break;case Aa:return fs([Qa(e,{value:Ia(e.value,"@","@"+Ca)})],r);case Pa:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(function(e,t){return(e=t.exec(e))?e[0]:e}(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return fs([Qa(e,{props:[Ia(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return fs([Qa(e,{props:[Ia(t,/:(plac\w+)/,":"+Ca+"input-$1")]}),Qa(e,{props:[Ia(t,/:(plac\w+)/,":-moz-$1")]}),Qa(e,{props:[Ia(t,/:(plac\w+)/,Sa+"input-$1")]})],r)}return""}))}}],Ss=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var r,i,o=e.stylisPlugins||ks,a={},s=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n<t.length;n++)a[t[n]]=!0;s.push(e)}));var l,c,u,d,p=[vs,(d=function(e){l.insert(e)},function(e){e.root||(e=e.return)&&d(e)})],h=(c=[ws,bs].concat(o,p),u=Ha(c),function(e,t,n,r){for(var i="",o=0;o<u;o++)i+=c[o](e,t,n,r)||"";return i});i=function(e,t,n,r){l=n,fs(cs(e?e+"{"+t.styles+"}":t.styles),h),r&&(f.inserted[t.name]=!0)};var f={key:t,sheet:new ka({key:t,container:r,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:a,registered:{},insert:i};return f.sheet.hydrate(s),f},Es={exports:{}},Cs={},Ts="function"==typeof Symbol&&Symbol.for,Ps=Ts?Symbol.for("react.element"):60103,Rs=Ts?Symbol.for("react.portal"):60106,As=Ts?Symbol.for("react.fragment"):60107,Os=Ts?Symbol.for("react.strict_mode"):60108,Ls=Ts?Symbol.for("react.profiler"):60114,Ms=Ts?Symbol.for("react.provider"):60109,Fs=Ts?Symbol.for("react.context"):60110,Is=Ts?Symbol.for("react.async_mode"):60111,Ds=Ts?Symbol.for("react.concurrent_mode"):60111,Gs=Ts?Symbol.for("react.forward_ref"):60112,Ns=Ts?Symbol.for("react.suspense"):60113,$s=Ts?Symbol.for("react.suspense_list"):60120,Hs=Ts?Symbol.for("react.memo"):60115,Ws=Ts?Symbol.for("react.lazy"):60116,Us=Ts?Symbol.for("react.block"):60121,js=Ts?Symbol.for("react.fundamental"):60117,Bs=Ts?Symbol.for("react.responder"):60118,zs=Ts?Symbol.for("react.scope"):60119;function qs(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case Ps:switch(e=e.type){case Is:case Ds:case As:case Ls:case Os:case Ns:return e;default:switch(e=e&&e.$$typeof){case Fs:case Gs:case Ws:case Hs:case Ms:return e;default:return t}}case Rs:return t}}}function Ks(e){return qs(e)===Ds}Cs.AsyncMode=Is,Cs.ConcurrentMode=Ds,Cs.ContextConsumer=Fs,Cs.ContextProvider=Ms,Cs.Element=Ps,Cs.ForwardRef=Gs,Cs.Fragment=As,Cs.Lazy=Ws,Cs.Memo=Hs,Cs.Portal=Rs,Cs.Profiler=Ls,Cs.StrictMode=Os,Cs.Suspense=Ns,Cs.isAsyncMode=function(e){return Ks(e)||qs(e)===Is},Cs.isConcurrentMode=Ks,Cs.isContextConsumer=function(e){return qs(e)===Fs},Cs.isContextProvider=function(e){return qs(e)===Ms},Cs.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===Ps},Cs.isForwardRef=function(e){return qs(e)===Gs},Cs.isFragment=function(e){return qs(e)===As},Cs.isLazy=function(e){return qs(e)===Ws},Cs.isMemo=function(e){return qs(e)===Hs},Cs.isPortal=function(e){return qs(e)===Rs},Cs.isProfiler=function(e){return qs(e)===Ls},Cs.isStrictMode=function(e){return qs(e)===Os},Cs.isSuspense=function(e){return qs(e)===Ns},Cs.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===As||e===Ds||e===Ls||e===Os||e===Ns||e===$s||"object"==typeof e&&null!==e&&(e.$$typeof===Ws||e.$$typeof===Hs||e.$$typeof===Ms||e.$$typeof===Fs||e.$$typeof===Gs||e.$$typeof===js||e.$$typeof===Bs||e.$$typeof===zs||e.$$typeof===Us)},Cs.typeOf=qs,Es.exports=Cs;var Vs=Es.exports,Qs={};Qs[Vs.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Qs[Vs.Memo]={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0};function Ys(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]+";"):n&&(r+=n+" ")})),r}var Xs=function(e,t,n){var r=e.key+"-"+t.name;!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},Js=function(e,t,n){Xs(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var i=t;do{e.insert(t===i?"."+r:"",i,e.sheet,!0),i=i.next}while(void 0!==i)}};var Zs={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},el=/[A-Z]|^ms/g,tl=/_EMO_([^_]+?)_([^]*?)_EMO_/g,nl=function(e){return 45===e.charCodeAt(1)},rl=function(e){return null!=e&&"boolean"!=typeof e},il=ms((function(e){return nl(e)?e:e.replace(el,"-$&").toLowerCase()})),ol=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(tl,(function(e,t,n){return sl={name:t,styles:n,next:sl},t}))}return 1===Zs[e]||nl(e)||"number"!=typeof t||0===t?t:t+"px"};function al(e,t,n){if(null==n)return"";var r=n;if(void 0!==r.__emotion_styles)return r;switch(typeof n){case"boolean":return"";case"object":var i=n;if(1===i.anim)return sl={name:i.name,styles:i.styles,next:sl},i.name;var o=n;if(void 0!==o.styles){var a=o.next;if(void 0!==a)for(;void 0!==a;)sl={name:a.name,styles:a.styles,next:sl},a=a.next;return o.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i<n.length;i++)r+=al(e,t,n[i])+";";else for(var o in n){var a=n[o];if("object"!=typeof a){var s=a;null!=t&&void 0!==t[s]?r+=o+"{"+t[s]+"}":rl(s)&&(r+=il(o)+":"+ol(o,s)+";")}else if(!Array.isArray(a)||"string"!=typeof a[0]||null!=t&&void 0!==t[a[0]]){var l=al(e,t,a);switch(o){case"animation":case"animationName":r+=il(o)+":"+l+";";break;default:r+=o+"{"+l+"}"}}else for(var c=0;c<a.length;c++)rl(a[c])&&(r+=il(o)+":"+ol(o,a[c])+";")}return r}(e,t,n);case"function":if(void 0!==e){var s=sl,l=n(e);return sl=s,al(e,t,l)}}var c=n;if(null==t)return c;var u=t[c];return void 0!==u?u:c}var sl,ll=/label:\s*([^\s;{]+)\s*(;|$)/g;function cl(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,i="";sl=void 0;var o=e[0];null==o||void 0===o.raw?(r=!1,i+=al(n,t,o)):i+=o[0];for(var a=1;a<e.length;a++){if(i+=al(n,t,e[a]),r)i+=o[a]}ll.lastIndex=0;for(var s,l="";null!==(s=ll.exec(i));)l+="-"+s[1];var c=function(e){for(var t,n=0,r=0,i=e.length;i>=4;++r,i-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(i){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(i)+l;return{name:c,styles:i,next:sl}}var ul,dl,pl=!!Kr.useInsertionEffect&&Kr.useInsertionEffect,hl=pl||function(e){return e()},fl=pl||Lt,vl=at("undefined"!=typeof HTMLElement?Ss({key:"css"}):null),ml=vl.Provider,gl=function(e){return Yn((function(t,n){var r=Gt(vl);return e(t,r,n)}))},yl=at({}),_l={}.hasOwnProperty,wl="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",bl=function(e,t){var n={};for(var r in t)_l.call(t,r)&&(n[r]=t[r]);return n[wl]=e,n},xl=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return Xs(t,n,r),hl((function(){return Js(t,n,r)})),null},kl=gl((function(e,t,n){var r=e.css;"string"==typeof r&&void 0!==t.registered[r]&&(r=t.registered[r]);var i=e[wl],o=[r],a="";"string"==typeof e.className?a=Ys(t.registered,o,e.className):null!=e.className&&(a=e.className+" ");var s=cl(o,void 0,Gt(yl));a+=t.key+"-"+s.name;var l={};for(var c in e)_l.call(e,c)&&"css"!==c&&c!==wl&&(l[c]=e[c]);return l.className=a,n&&(l.ref=n),De($e,null,De(xl,{cache:t,serialized:s,isStringTag:"string"==typeof i}),De(i,l))})),Sl=function(e,t){var n=arguments;if(null==t||!_l.call(t,"css"))return De.apply(void 0,n);var r=n.length,i=new Array(r);i[0]=kl,i[1]=bl(e,t);for(var o=2;o<r;o++)i[o]=n[o];return De.apply(null,i)};ul=Sl||(Sl={}),dl||(dl=ul.JSX||(ul.JSX={}));var El=gl((function(e,t){var n=cl([e.styles],void 0,Gt(yl)),r=Mt();return fl((function(){var e=t.key+"-global",i=new t.sheet.constructor({key:e,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),o=!1,a=document.querySelector('style[data-emotion="'+e+" "+n.name+'"]');return t.sheet.tags.length&&(i.before=t.sheet.tags[0]),null!==a&&(o=!0,a.setAttribute("data-emotion",e),i.hydrate([a])),r.current=[i,o],function(){i.flush()}}),[t]),fl((function(){var e=r.current,i=e[0];if(e[1])e[1]=!1;else{if(void 0!==n.next&&Js(t,n.next,!0),i.tags.length){var o=i.tags[i.tags.length-1].nextElementSibling;i.before=o,i.flush()}t.insert("",n,i,!1)}}),[t,n.name]),null}));function Cl(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return cl(t)}var Tl=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Pl=ms((function(e){return Tl.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91})),Rl=function(e){return"theme"!==e},Al=function(e){return"string"==typeof e&&e.charCodeAt(0)>96?Pl:Rl},Ol=function(e,t,n){var r;if(t){var i=t.shouldForwardProp;r=e.__emotion_forwardProp&&i?function(t){return e.__emotion_forwardProp(t)&&i(t)}:i}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},Ll=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return Xs(t,n,r),hl((function(){return Js(t,n,r)})),null},Ml=function e(t,n){var r,i,o=t.__emotion_real===t,a=o&&t.__emotion_base||t;void 0!==n&&(r=n.label,i=n.target);var s=Ol(t,n,o),l=s||Al(a),c=!l("as");return function(){var u=arguments,d=o&&void 0!==t.__emotion_styles?t.__emotion_styles.slice(0):[];if(void 0!==r&&d.push("label:"+r+";"),null==u[0]||void 0===u[0].raw)d.push.apply(d,u);else{var p=u[0];d.push(p[0]);for(var h=u.length,f=1;f<h;f++)d.push(u[f],p[f])}var v=gl((function(e,t,n){var r=c&&e.as||a,o="",u=[],p=e;if(null==e.theme){for(var h in p={},e)p[h]=e[h];p.theme=Gt(yl)}"string"==typeof e.className?o=Ys(t.registered,u,e.className):null!=e.className&&(o=e.className+" ");var f=cl(d.concat(u),t.registered,p);o+=t.key+"-"+f.name,void 0!==i&&(o+=" "+i);var v=c&&void 0===s?Al(r):l,m={};for(var g in e)c&&"as"===g||v(g)&&(m[g]=e[g]);return m.className=o,n&&(m.ref=n),De($e,null,De(Ll,{cache:t,serialized:f,isStringTag:"string"==typeof r}),De(r,m))}));return v.displayName=void 0!==r?r:"Styled("+("string"==typeof a?a:a.displayName||a.name||"Component")+")",v.defaultProps=t.defaultProps,v.__emotion_real=v,v.__emotion_base=a,v.__emotion_styles=d,v.__emotion_forwardProp=s,Object.defineProperty(v,"toString",{value:function(){return"."+i}}),v.withComponent=function(t,r){return e(t,xa({},n,r,{shouldForwardProp:Ol(v,r,!0)})).apply(void 0,d)},v}}.bind(null);["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"].forEach((function(e){Ml[e]=Ml(e)}));const Fl=Ml.span({whiteSpace:"nowrap",borderBottomWidth:"2px",paddingLeft:"0.25rem",paddingRight:"0.25rem",paddingTop:"1rem",paddingBottom:"1rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500"},(({isActive:e})=>e?{cursor:"default","--tw-border-opacity":"1",borderColor:"rgb(99 102 241 / var(--tw-border-opacity))","--tw-text-opacity":"1",color:"rgb(79 70 229 / var(--tw-text-opacity))"}:{cursor:"pointer",borderColor:"transparent","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))",":hover":{"--tw-border-opacity":"1",borderColor:"rgb(209 213 219 / var(--tw-border-opacity))","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"}})),Il=Ml.span({marginLeft:"0.25rem",display:"inline-flex",width:"1.25rem",alignItems:"center",justifyContent:"center",borderRadius:"9999px",fontFamily:'ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace',fontWeight:"700","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))"},(({isActive:e})=>e?{"--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))"}:{"--tw-bg-opacity":"1",backgroundColor:"rgb(107 114 128 / var(--tw-bg-opacity))",".group:hover &":{"--tw-bg-opacity":"1",backgroundColor:"rgb(55 65 81 / var(--tw-bg-opacity))"}}));var Dl=$e,Gl=function(e,t,n){return _l.call(t,"css")?Qr(kl,bl(e,t),n):Qr(e,t,n)},Nl=function(e,t,n){return _l.call(t,"css")?Qr(kl,bl(e,t),n):Qr(e,t,n)};const $l=({tabs:e})=>Gl("div",{css:{display:"block"},children:Gl("div",{css:{borderBottomWidth:"1px","--tw-border-opacity":"1",borderColor:"rgb(229 231 235 / var(--tw-border-opacity))",paddingBottom:"1rem"},children:Gl("nav",{"aria-label":"Tabs",css:{marginBottom:"-2px",display:"flex","> :not([hidden]) ~ :not([hidden])":{"--tw-space-x-reverse":"0",marginRight:"calc(2rem * var(--tw-space-x-reverse))",marginLeft:"calc(2rem * calc(1 - var(--tw-space-x-reverse)))"},paddingTop:"1rem"},children:e.map((e=>Gl(ya,{to:e.id,children:({isActive:t})=>Nl(Fl,{className:"group",isActive:t,children:[e.displayName,void 0!==e.count&&Gl(Il,{isActive:t,children:e.count})]})},e.id)))})})}),Hl=e=>{var t,n;const{linkedProfilesForAccount:r,checkProfileSearchAuthorization:i,linkedAccount:o}=Ai(),a=oi({queryKey:[fi],queryFn:o}),s=oi({queryKey:[vi],queryFn:r}),l=oi({queryKey:[gi],queryFn:i});Ot((()=>{l.error&&e.onError(l.error.message),s.error&&e.onError(s.error.message)}),[l.error,s.error,e]);const c=It((()=>{var e;return[{id:"search",displayName:"Search"},{id:"profiles",displayName:"Linked Profiles",count:null==(e=s.data)?void 0:e.length},{id:"invoices",displayName:"Invoices"}]}),[s.data]);return l.isSuccess&&"Linked"!==l.data.status?Gl(Bo,{to:"unlinked",replace:!0}):l.isSuccess?Nl("div",{children:[Nl("dl",{css:{marginLeft:"0.25rem",paddingTop:"1rem"},children:[Nl("div",{css:{display:"flex",gap:"0.5rem"},children:[Gl("dt",{css:{width:"5rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:"Account"}),Gl("dd",{css:{marginLeft:"-1px",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"},children:null==(t=a.data)?void 0:t.id})]}),Nl("div",{css:{display:"flex",gap:"0.5rem"},children:[Gl("dt",{css:{width:"5rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:"Client"}),Gl("dd",{css:{marginLeft:"-1px",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"},children:null==(n=a.data)?void 0:n.catchEClientId})]})]}),Gl($l,{tabs:c}),Gl("div",{css:{marginLeft:"1rem",marginTop:"1rem"},children:Gl(zo,{})})]}):Gl("div",{children:"Loading..."})},Wl=e=>Gl(Uh,{children:Gl("button",{as:"button",onClick:()=>e.onClick(e.id),css:{display:"inline-flex",alignItems:"center",fill:"var(--fl-color-primary-600)",paddingLeft:"0.25rem",paddingRight:"0.25rem"},children:e.children})}),Ul=e=>Gl(Wh,{children:Gl("ul",{css:{listStyleType:"none"},children:e.value.split(",").map((t=>Gl("li",{children:e.navTo?Gl(ya,{css:{"--tw-text-opacity":"1",color:"rgb(79 70 229 / var(--tw-text-opacity))",textDecorationLine:"underline"},to:e.navTo,children:t}):t},t)))})}),jl="undefined"!=typeof document?qr.useLayoutEffect:()=>{};const Bl=e=>{var t;return null!==(t=null==e?void 0:e.ownerDocument)&&void 0!==t?t:document},zl=e=>{if(e&&"window"in e&&e.window===e)return e;return Bl(e).defaultView||window};function ql(e){let t=null;return()=>(null==t&&(t=e()),t)}const Kl=ql((function(){return e=/^Mac/i,"undefined"!=typeof window&&null!=window.navigator&&e.test((null===(t=window.navigator.userAgentData)||void 0===t?void 0:t.platform)||window.navigator.platform);var e,t})),Vl=ql((function(){return e=/Android/i,"undefined"!=typeof window&&null!=window.navigator&&((null===(t=window.navigator.userAgentData)||void 0===t?void 0:t.brands.some((t=>e.test(t.brand))))||e.test(window.navigator.userAgent));var e,t}));class Ql{isDefaultPrevented(){return this.nativeEvent.defaultPrevented}preventDefault(){this.defaultPrevented=!0,this.nativeEvent.preventDefault()}stopPropagation(){this.nativeEvent.stopPropagation(),this.isPropagationStopped=()=>!0}isPropagationStopped(){return!1}persist(){}constructor(e,t){this.nativeEvent=t,this.target=t.target,this.currentTarget=t.currentTarget,this.relatedTarget=t.relatedTarget,this.bubbles=t.bubbles,this.cancelable=t.cancelable,this.defaultPrevented=t.defaultPrevented,this.eventPhase=t.eventPhase,this.isTrusted=t.isTrusted,this.timeStamp=t.timeStamp,this.type=e}}function Yl(e){let t=Mt({isFocused:!1,observer:null});jl((()=>{const e=t.current;return()=>{e.observer&&(e.observer.disconnect(),e.observer=null)}}),[]);let n=function(e){const t=Mt(null);return jl((()=>{t.current=e}),[e]),Dt(((...e)=>{const n=t.current;return null==n?void 0:n(...e)}),[])}((t=>{null==e||e(t)}));return Dt((e=>{if(e.target instanceof HTMLButtonElement||e.target instanceof HTMLInputElement||e.target instanceof HTMLTextAreaElement||e.target instanceof HTMLSelectElement){t.current.isFocused=!0;let r=e.target,i=e=>{t.current.isFocused=!1,r.disabled&&n(new Ql("blur",e)),t.current.observer&&(t.current.observer.disconnect(),t.current.observer=null)};r.addEventListener("focusout",i,{once:!0}),t.current.observer=new MutationObserver((()=>{if(t.current.isFocused&&r.disabled){var e;null===(e=t.current.observer)||void 0===e||e.disconnect();let n=r===document.activeElement?null:document.activeElement;r.dispatchEvent(new FocusEvent("blur",{relatedTarget:n})),r.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:n}))}})),t.current.observer.observe(r,{attributes:!0,attributeFilter:["disabled"]})}}),[n])}let Xl=null,Jl=new Set,Zl=new Map,ec=!1,tc=!1;const nc={Tab:!0,Escape:!0};function rc(e,t){for(let n of Jl)n(e,t)}function ic(e){ec=!0,function(e){return!(e.metaKey||!Kl()&&e.altKey||e.ctrlKey||"Control"===e.key||"Shift"===e.key||"Meta"===e.key)}(e)&&(Xl="keyboard",rc("keyboard",e))}function oc(e){Xl="pointer","mousedown"!==e.type&&"pointerdown"!==e.type||(ec=!0,rc("pointer",e))}function ac(e){var t;(0===(t=e).mozInputSource&&t.isTrusted||(Vl()&&t.pointerType?"click"===t.type&&1===t.buttons:0===t.detail&&!t.pointerType))&&(ec=!0,Xl="virtual")}function sc(e){e.target!==window&&e.target!==document&&(ec||tc||(Xl="virtual",rc("virtual",e)),ec=!1,tc=!1)}function lc(){ec=!1,tc=!0}function cc(e){if("undefined"==typeof window||Zl.get(zl(e)))return;const t=zl(e),n=Bl(e);let r=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){ec=!0,r.apply(this,arguments)},n.addEventListener("keydown",ic,!0),n.addEventListener("keyup",ic,!0),n.addEventListener("click",ac,!0),t.addEventListener("focus",sc,!0),t.addEventListener("blur",lc,!1),"undefined"!=typeof PointerEvent?(n.addEventListener("pointerdown",oc,!0),n.addEventListener("pointermove",oc,!0),n.addEventListener("pointerup",oc,!0)):(n.addEventListener("mousedown",oc,!0),n.addEventListener("mousemove",oc,!0),n.addEventListener("mouseup",oc,!0)),t.addEventListener("beforeunload",(()=>{uc(e)}),{once:!0}),Zl.set(t,{focus:r})}const uc=(e,t)=>{const n=zl(e),r=Bl(e);t&&r.removeEventListener("DOMContentLoaded",t),Zl.has(n)&&(n.HTMLElement.prototype.focus=Zl.get(n).focus,r.removeEventListener("keydown",ic,!0),r.removeEventListener("keyup",ic,!0),r.removeEventListener("click",ac,!0),n.removeEventListener("focus",sc,!0),n.removeEventListener("blur",lc,!1),"undefined"!=typeof PointerEvent?(r.removeEventListener("pointerdown",oc,!0),r.removeEventListener("pointermove",oc,!0),r.removeEventListener("pointerup",oc,!0)):(r.removeEventListener("mousedown",oc,!0),r.removeEventListener("mousemove",oc,!0),r.removeEventListener("mouseup",oc,!0)),Zl.delete(n))};function dc(){return"pointer"!==Xl}"undefined"!=typeof document&&function(e){const t=Bl(e);let n;"loading"!==t.readyState?cc(e):(n=()=>{cc(e)},t.addEventListener("DOMContentLoaded",n))}();const pc=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function hc(e,t,n){cc(),Ot((()=>{let t=(t,r)=>{(function(e,t,n){var r;const i="undefined"!=typeof window?zl(null==n?void 0:n.target).HTMLInputElement:HTMLInputElement,o="undefined"!=typeof window?zl(null==n?void 0:n.target).HTMLTextAreaElement:HTMLTextAreaElement,a="undefined"!=typeof window?zl(null==n?void 0:n.target).HTMLElement:HTMLElement,s="undefined"!=typeof window?zl(null==n?void 0:n.target).KeyboardEvent:KeyboardEvent;return!((e=e||(null==n?void 0:n.target)instanceof i&&!pc.has(null==n||null===(r=n.target)||void 0===r?void 0:r.type)||(null==n?void 0:n.target)instanceof o||(null==n?void 0:n.target)instanceof a&&(null==n?void 0:n.target.isContentEditable))&&"keyboard"===t&&n instanceof s&&!nc[n.key])})(!!(null==n?void 0:n.isTextInput),t,r)&&e(dc())};return Jl.add(t),()=>{Jl.delete(t)}}),t)}let fc=!1,vc=0;function mc(){fc=!0,setTimeout((()=>{fc=!1}),50)}function gc(e){"touch"===e.pointerType&&mc()}function yc(){if("undefined"!=typeof document)return"undefined"!=typeof PointerEvent?document.addEventListener("pointerup",gc):document.addEventListener("touchend",mc),vc++,()=>{vc--,vc>0||("undefined"!=typeof PointerEvent?document.removeEventListener("pointerup",gc):document.removeEventListener("touchend",mc))}}function _c(e={}){let{autoFocus:t=!1,isTextInput:n,within:r}=e,i=Mt({isFocused:!1,isFocusVisible:t||dc()}),[o,a]=Rt(!1),[s,l]=Rt((()=>i.current.isFocused&&i.current.isFocusVisible)),c=Dt((()=>l(i.current.isFocused&&i.current.isFocusVisible)),[]),u=Dt((e=>{i.current.isFocused=e,a(e),c()}),[c]);hc((e=>{i.current.isFocusVisible=e,c()}),[],{isTextInput:n});let{focusProps:d}=function(e){let{isDisabled:t,onFocus:n,onBlur:r,onFocusChange:i}=e;const o=Dt((e=>{if(e.target===e.currentTarget)return r&&r(e),i&&i(!1),!0}),[r,i]),a=Yl(o),s=Dt((e=>{const t=Bl(e.target);e.target===e.currentTarget&&t.activeElement===e.target&&(n&&n(e),i&&i(!0),a(e))}),[i,n,a]);return{focusProps:{onFocus:!t&&(n||i||r)?s:void 0,onBlur:t||!r&&!i?void 0:o}}}({isDisabled:r,onFocusChange:u}),{focusWithinProps:p}=function(e){let{isDisabled:t,onBlurWithin:n,onFocusWithin:r,onFocusWithinChange:i}=e,o=Mt({isFocusWithin:!1}),a=Dt((e=>{o.current.isFocusWithin&&!e.currentTarget.contains(e.relatedTarget)&&(o.current.isFocusWithin=!1,n&&n(e),i&&i(!1))}),[n,i,o]),s=Yl(a),l=Dt((e=>{o.current.isFocusWithin||document.activeElement!==e.target||(r&&r(e),i&&i(!0),o.current.isFocusWithin=!0,s(e))}),[r,i,s]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:l,onBlur:a}}}({isDisabled:!r,onFocusWithinChange:u});return{isFocused:o,isFocusVisible:s,focusProps:r?p:d}}var wc=Object.defineProperty,bc=(e,t,n)=>(((e,t,n)=>{t in e?wc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);let xc=new class{constructor(){bc(this,"current",this.detect()),bc(this,"handoffState","pending"),bc(this,"currentId",0)}set(e){this.current!==e&&(this.handoffState="pending",this.currentId=0,this.current=e)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return"server"===this.current}get isClient(){return"client"===this.current}detect(){return"undefined"==typeof window||"undefined"==typeof document?"server":"client"}handoff(){"pending"===this.handoffState&&(this.handoffState="complete")}get isHandoffComplete(){return"complete"===this.handoffState}};function kc(e){return xc.isServer?null:e instanceof Node?e.ownerDocument:null!=e&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}function Sc(e){"function"==typeof queueMicrotask?queueMicrotask(e):Promise.resolve().then(e).catch((e=>setTimeout((()=>{throw e}))))}function Ec(){let e=[],t={addEventListener:(e,n,r,i)=>(e.addEventListener(n,r,i),t.add((()=>e.removeEventListener(n,r,i)))),requestAnimationFrame(...e){let n=requestAnimationFrame(...e);return t.add((()=>cancelAnimationFrame(n)))},nextFrame:(...e)=>t.requestAnimationFrame((()=>t.requestAnimationFrame(...e))),setTimeout(...e){let n=setTimeout(...e);return t.add((()=>clearTimeout(n)))},microTask(...e){let n={current:!0};return Sc((()=>{n.current&&e[0]()})),t.add((()=>{n.current=!1}))},style(e,t,n){let r=e.style.getPropertyValue(t);return Object.assign(e.style,{[t]:n}),this.add((()=>{Object.assign(e.style,{[t]:r})}))},group(e){let t=Ec();return e(t),this.add((()=>t.dispose()))},add:t=>(e.includes(t)||e.push(t),()=>{let n=e.indexOf(t);if(n>=0)for(let t of e.splice(n,1))t()}),dispose(){for(let t of e.splice(0))t()}};return t}function Cc(){let[e]=Rt(Ec);return Ot((()=>()=>e.dispose()),[e]),e}let Tc=(e,t)=>{xc.isServer?Ot(e,t):Lt(e,t)};function Pc(e){let t=Mt(e);return Tc((()=>{t.current=e}),[e]),t}let Rc=function(e){let t=Pc(e);return qr.useCallback(((...e)=>t.current(...e)),[t])};let Ac=at(void 0);function Oc(){return Gt(Ac)}function Lc(...e){return Array.from(new Set(e.flatMap((e=>"string"==typeof e?e.split(" "):[])))).filter(Boolean).join(" ")}function Mc(e,t,...n){if(e in t){let r=t[e];return"function"==typeof r?r(...n):r}let r=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map((e=>`"${e}"`)).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,Mc),r}var Fc,Ic,Dc=((Ic=Dc||{})[Ic.None=0]="None",Ic[Ic.RenderStrategy=1]="RenderStrategy",Ic[Ic.Static=2]="Static",Ic),Gc=((Fc=Gc||{})[Fc.Unmount=0]="Unmount",Fc[Fc.Hidden=1]="Hidden",Fc);function Nc(){let e=function(){let e=Mt([]),t=Dt((t=>{for(let n of e.current)null!=n&&("function"==typeof n?n(t):n.current=t)}),[]);return(...n)=>{if(!n.every((e=>null==e)))return e.current=n,t}}();return Dt((t=>function({ourProps:e,theirProps:t,slot:n,defaultTag:r,features:i,visible:o=!0,name:a,mergeRefs:s}){s=null!=s?s:Hc;let l=Wc(t,e);if(o)return $c(l,n,r,a,s);let c=null!=i?i:0;if(2&c){let{static:e=!1,...t}=l;if(e)return $c(t,n,r,a,s)}if(1&c){let{unmount:e=!0,...t}=l;return Mc(e?0:1,{0:()=>null,1:()=>$c({...t,hidden:!0,style:{display:"none"}},n,r,a,s)})}return $c(l,n,r,a,s)}({mergeRefs:e,...t})),[e])}function $c(e,t={},n,r,i){let{as:o=n,children:a,refName:s="ref",...l}=zc(e,["unmount","static"]),c=void 0!==e.ref?{[s]:e.ref}:{},u="function"==typeof a?a(t):a;"className"in l&&l.className&&"function"==typeof l.className&&(l.className=l.className(t)),l["aria-labelledby"]&&l["aria-labelledby"]===l.id&&(l["aria-labelledby"]=void 0);let d={};if(t){let e=!1,n=[];for(let[r,i]of Object.entries(t))"boolean"==typeof i&&(e=!0),!0===i&&n.push(r.replace(/([A-Z])/g,(e=>`-${e.toLowerCase()}`)));if(e){d["data-headlessui-state"]=n.join(" ");for(let e of n)d[`data-${e}`]=""}}if(o===$e&&(Object.keys(Bc(l)).length>0||Object.keys(Bc(d)).length>0)){if(Ar(u)&&!(Array.isArray(u)&&u.length>1)){let e=u.props,t=null==e?void 0:e.className,n="function"==typeof t?(...e)=>Lc(t(...e),l.className):Lc(t,l.className),r=n?{className:n}:{},o=Wc(u.props,Bc(zc(l,["ref"])));for(let i in d)i in o&&delete d[i];return Mr(u,Object.assign({},o,d,c,{ref:i(qc(u),c.ref)},r))}if(Object.keys(Bc(l)).length>0)throw new Error(['Passing props on "Fragment"!',"",`The current component <${r} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(Bc(l)).concat(Object.keys(Bc(d))).map((e=>` - ${e}`)).join("\n"),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map((e=>` - ${e}`)).join("\n")].join("\n"))}return De(o,Object.assign({},zc(l,["ref"]),o!==$e&&c,o!==$e&&d),u)}function Hc(...e){return e.every((e=>null==e))?void 0:t=>{for(let n of e)null!=n&&("function"==typeof n?n(t):n.current=t)}}function Wc(...e){if(0===e.length)return{};if(1===e.length)return e[0];let t={},n={};for(let r of e)for(let e in r)e.startsWith("on")&&"function"==typeof r[e]?(null!=n[e]||(n[e]=[]),n[e].push(r[e])):t[e]=r[e];if(t.disabled||t["aria-disabled"])for(let r in n)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(r)&&(n[r]=[e=>{var t;return null==(t=null==e?void 0:e.preventDefault)?void 0:t.call(e)}]);for(let r in n)Object.assign(t,{[r](e,...t){let i=n[r];for(let n of i){if((e instanceof Event||(null==e?void 0:e.nativeEvent)instanceof Event)&&e.defaultPrevented)return;n(e,...t)}}});return t}function Uc(...e){if(0===e.length)return{};if(1===e.length)return e[0];let t={},n={};for(let r of e)for(let e in r)e.startsWith("on")&&"function"==typeof r[e]?(null!=n[e]||(n[e]=[]),n[e].push(r[e])):t[e]=r[e];for(let r in n)Object.assign(t,{[r](...e){let t=n[r];for(let n of t)null==n||n(...e)}});return t}function jc(e){var t;return Object.assign(Yn(e),{displayName:null!=(t=e.displayName)?t:e.name})}function Bc(e){let t=Object.assign({},e);for(let n in t)void 0===t[n]&&delete t[n];return t}function zc(e,t=[]){let n=Object.assign({},e);for(let r of t)r in n&&delete n[r];return n}function qc(e){return qr.version.split(".")[0]>="19"?e.props.ref:e.ref}let Kc=at(void 0);function Vc(e){let t=e.parentElement,n=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(n=t),t=t.parentElement;let r=""===(null==t?void 0:t.getAttribute("disabled"));return(!r||!function(e){if(!e)return!1;let t=e.previousElementSibling;for(;null!==t;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}(n))&&r}let Qc=Symbol();function Yc(...e){let t=Mt(e);Ot((()=>{t.current=e}),[e]);let n=Rc((e=>{for(let n of t.current)null!=n&&("function"==typeof n?n(e):n.current=e)}));return e.every((e=>null==e||(null==e?void 0:e[Qc])))?void 0:n}let Xc=at(null);function Jc(){let e=Gt(Xc);if(null===e){let e=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(e,Jc),e}return e}Xc.displayName="DescriptionContext";let Zc=jc((function(e,t){let n=$t(),r=Oc(),{id:i=`headlessui-description-${n}`,...o}=e,a=Jc(),s=Yc(t);Tc((()=>a.register(i)),[i,a.register]);let l=r||!1,c=It((()=>({...a.slot,disabled:l})),[a.slot,l]),u={ref:s,...a.props,id:i};return Nc()({ourProps:u,theirProps:o,slot:c,defaultTag:"p",name:a.name||"Description"})}));Object.assign(Zc,{});var eu,tu=((eu=tu||{}).Space=" ",eu.Enter="Enter",eu.Escape="Escape",eu.Backspace="Backspace",eu.Delete="Delete",eu.ArrowLeft="ArrowLeft",eu.ArrowUp="ArrowUp",eu.ArrowRight="ArrowRight",eu.ArrowDown="ArrowDown",eu.Home="Home",eu.End="End",eu.PageUp="PageUp",eu.PageDown="PageDown",eu.Tab="Tab",eu);let nu=at(null);function ru(){let e=Gt(nu);if(null===e){let e=new Error("You used a <Label /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(e,ru),e}return e}function iu({inherit:e=!1}={}){let t=function(){var e,t;let n=null!=(t=null==(e=Gt(nu))?void 0:e.value)?t:void 0;return n}(),[n,r]=Rt([]),i=e?[t,...n].filter(Boolean):n;return[i.length>0?i.join(" "):void 0,It((()=>function(e){let t=Rc((e=>(r((t=>[...t,e])),()=>r((t=>{let n=t.slice(),r=n.indexOf(e);return-1!==r&&n.splice(r,1),n}))))),n=It((()=>({register:t,slot:e.slot,name:e.name,props:e.props,value:e.value})),[t,e.slot,e.name,e.props,e.value]);return qr.createElement(nu.Provider,{value:n},e.children)}),[r])]}nu.displayName="LabelContext";let ou=jc((function(e,t){var n;let r=$t(),i=ru(),o=Gt(Kc),a=Oc(),{id:s=`headlessui-label-${r}`,htmlFor:l=(null!=o?o:null==(n=i.props)?void 0:n.htmlFor),passive:c=!1,...u}=e,d=Yc(t);Tc((()=>i.register(s)),[s,i.register]);let p=Rc((e=>{let t=e.currentTarget;if(t instanceof HTMLLabelElement&&e.preventDefault(),i.props&&"onClick"in i.props&&"function"==typeof i.props.onClick&&i.props.onClick(e),t instanceof HTMLLabelElement){let e=document.getElementById(t.htmlFor);if(e){let t=e.getAttribute("disabled");if("true"===t||""===t)return;let n=e.getAttribute("aria-disabled");if("true"===n||""===n)return;(e instanceof HTMLInputElement&&("radio"===e.type||"checkbox"===e.type)||"radio"===e.role||"checkbox"===e.role||"switch"===e.role)&&e.click(),e.focus({preventScroll:!0})}}})),h=a||!1,f=It((()=>({...i.slot,disabled:h})),[i.slot,h]),v={ref:d,...i.props,id:s,htmlFor:l,onClick:p};return c&&("onClick"in v&&(delete v.htmlFor,delete v.onClick),"onClick"in u&&delete u.onClick),Nc()({ourProps:v,theirProps:u,slot:f,defaultTag:l?"label":"div",name:i.name||"Label"})}));function au(e,t=!1){let[n,r]=At((()=>({})),{}),i=It((()=>function(e){if(null===e)return{width:0,height:0};let{width:t,height:n}=e.getBoundingClientRect();return{width:t,height:n}}(e)),[e,n]);return Tc((()=>{if(!e)return;let t=new ResizeObserver(r);return t.observe(e),()=>{t.disconnect()}}),[e]),t?{width:`${i.width}px`,height:`${i.height}px`}:i}Object.assign(ou,{});let su=class extends Map{constructor(e){super(),this.factory=e}get(e){let t=super.get(e);return void 0===t&&(t=this.factory(e),this.set(e,t)),t}};function lu(e,t){let n=e(),r=new Set;return{getSnapshot:()=>n,subscribe:e=>(r.add(e),()=>r.delete(e)),dispatch(e,...i){let o=t[e].call(n,...i);o&&(n=o,r.forEach((e=>e())))}}}function cu(e){return Br(e.subscribe,e.getSnapshot,e.getSnapshot)}let uu=new su((()=>lu((()=>[]),{ADD(e){return this.includes(e)?this:[...this,e]},REMOVE(e){let t=this.indexOf(e);if(-1===t)return this;let n=this.slice();return n.splice(t,1),n}})));function du(e,t){let n=uu.get(t),r=$t(),i=cu(n);if(Tc((()=>{if(e)return n.dispatch("ADD",r),()=>n.dispatch("REMOVE",r)}),[n,e]),!e)return!1;let o=i.indexOf(r),a=i.length;return-1===o&&(o=a,a+=1),o===a-1}let pu=new Map,hu=new Map;function fu(e){var t;let n=null!=(t=hu.get(e))?t:0;return hu.set(e,n+1),0!==n||(pu.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),e.setAttribute("aria-hidden","true"),e.inert=!0),()=>vu(e)}function vu(e){var t;let n=null!=(t=hu.get(e))?t:1;if(1===n?hu.delete(e):hu.set(e,n-1),1!==n)return;let r=pu.get(e);r&&(null===r["aria-hidden"]?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",r["aria-hidden"]),e.inert=r.inert,pu.delete(e))}let mu=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map((e=>`${e}:not([tabindex='-1'])`)).join(","),gu=["[data-autofocus]"].map((e=>`${e}:not([tabindex='-1'])`)).join(",");var yu,_u,wu,bu=((wu=bu||{})[wu.First=1]="First",wu[wu.Previous=2]="Previous",wu[wu.Next=4]="Next",wu[wu.Last=8]="Last",wu[wu.WrapAround=16]="WrapAround",wu[wu.NoScroll=32]="NoScroll",wu[wu.AutoFocus=64]="AutoFocus",wu),xu=((_u=xu||{})[_u.Error=0]="Error",_u[_u.Overflow=1]="Overflow",_u[_u.Success=2]="Success",_u[_u.Underflow=3]="Underflow",_u),ku=((yu=ku||{})[yu.Previous=-1]="Previous",yu[yu.Next=1]="Next",yu);function Su(e=document.body){return null==e?[]:Array.from(e.querySelectorAll(mu)).sort(((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER))))}var Eu=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(Eu||{});function Cu(e,t=0){var n;return e!==(null==(n=kc(e))?void 0:n.body)&&Mc(t,{0:()=>e.matches(mu),1(){let t=e;for(;null!==t;){if(t.matches(mu))return!0;t=t.parentElement}return!1}})}function Tu(e){let t=kc(e);Ec().nextFrame((()=>{t&&!Cu(t.activeElement,0)&&function(e){null==e||e.focus({preventScroll:!0})}(e)}))}var Pu=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(Pu||{});"undefined"!=typeof window&&"undefined"!=typeof document&&(document.addEventListener("keydown",(e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")}),!0),document.addEventListener("click",(e=>{1===e.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===e.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")}),!0));let Ru=["textarea","input"].join(",");function Au(e,t=e=>e){return e.slice().sort(((e,n)=>{let r=t(e),i=t(n);if(null===r||null===i)return 0;let o=r.compareDocumentPosition(i);return o&Node.DOCUMENT_POSITION_FOLLOWING?-1:o&Node.DOCUMENT_POSITION_PRECEDING?1:0}))}function Ou(e,t){return function(e,t,{sorted:n=!0,relativeTo:r=null,skipElements:i=[]}={}){let o=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,a=Array.isArray(e)?n?Au(e):e:64&t?function(e=document.body){return null==e?[]:Array.from(e.querySelectorAll(gu)).sort(((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER))))}(e):Su(e);i.length>0&&a.length>1&&(a=a.filter((e=>!i.some((t=>null!=t&&"current"in t?(null==t?void 0:t.current)===e:t===e))))),r=null!=r?r:o.activeElement;let s,l=(()=>{if(5&t)return 1;if(10&t)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),c=(()=>{if(1&t)return 0;if(2&t)return Math.max(0,a.indexOf(r))-1;if(4&t)return Math.max(0,a.indexOf(r))+1;if(8&t)return a.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),u=32&t?{preventScroll:!0}:{},d=0,p=a.length;do{if(d>=p||d+p<=0)return 0;let e=c+d;if(16&t)e=(e+p)%p;else{if(e<0)return 3;if(e>=p)return 1}s=a[e],null==s||s.focus(u),d+=l}while(s!==o.activeElement);return 6&t&&function(e){var t,n;return null!=(n=null==(t=null==e?void 0:e.matches)?void 0:t.call(e,Ru))&&n}(s)&&s.select(),2}(Su(),t,{relativeTo:e})}function Lu(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function Mu(){return Lu()||/Android/gi.test(window.navigator.userAgent)}function Fu(e,t,n,r){let i=Pc(n);Ot((()=>{if(e)return document.addEventListener(t,n,r),()=>document.removeEventListener(t,n,r);function n(e){i.current(e)}}),[e,t,r])}function Iu(e,t,n){let r=du(e,"outside-click"),i=Pc(n),o=Dt((function(e,n){if(e.defaultPrevented)return;let r=n(e);if(null===r||!r.getRootNode().contains(r)||!r.isConnected)return;let o=function e(t){return"function"==typeof t?e(t()):Array.isArray(t)||t instanceof Set?t:[t]}(t);for(let t of o)if(null!==t&&(t.contains(r)||e.composed&&e.composedPath().includes(t)))return;return!Cu(r,Eu.Loose)&&-1!==r.tabIndex&&e.preventDefault(),i.current(e,r)}),[i,t]),a=Mt(null);Fu(r,"pointerdown",(e=>{var t,n;a.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target}),!0),Fu(r,"mousedown",(e=>{var t,n;a.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target}),!0),Fu(r,"click",(e=>{Mu()||a.current&&(o(e,(()=>a.current)),a.current=null)}),!0);let s=Mt({x:0,y:0});Fu(r,"touchstart",(e=>{s.current.x=e.touches[0].clientX,s.current.y=e.touches[0].clientY}),!0),Fu(r,"touchend",(e=>{let t=e.changedTouches[0].clientX,n=e.changedTouches[0].clientY;if(!(Math.abs(t-s.current.x)>=30||Math.abs(n-s.current.y)>=30))return o(e,(()=>e.target instanceof HTMLElement?e.target:null))}),!0),function(e,t,n,r){let i=Pc(n);Ot((()=>{if(e)return window.addEventListener(t,n,r),()=>window.removeEventListener(t,n,r);function n(e){i.current(e)}}),[e,t,r])}(r,"blur",(e=>o(e,(()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null))),!0)}function Du(...e){return It((()=>kc(...e)),[...e])}function Gu(e,t){return It((()=>{var n;if(e.type)return e.type;let r=null!=(n=e.as)?n:"button";return"string"==typeof r&&"button"===r.toLowerCase()||"BUTTON"===(null==t?void 0:t.tagName)&&!t.hasAttribute("type")?"button":void 0}),[e.type,e.as,t])}function Nu(){let e;return{before({doc:t}){var n;let r=t.documentElement,i=null!=(n=t.defaultView)?n:window;e=Math.max(0,i.innerWidth-r.clientWidth)},after({doc:t,d:n}){let r=t.documentElement,i=Math.max(0,r.clientWidth-r.offsetWidth),o=Math.max(0,e-i);n.style(r,"paddingRight",`${o}px`)}}}function $u(e){let t={};for(let n of e)Object.assign(t,n(t));return t}let Hu=lu((()=>new Map),{PUSH(e,t){var n;let r=null!=(n=this.get(e))?n:{doc:e,count:0,d:Ec(),meta:new Set};return r.count++,r.meta.add(t),this.set(e,r),this},POP(e,t){let n=this.get(e);return n&&(n.count--,n.meta.delete(t)),this},SCROLL_PREVENT({doc:e,d:t,meta:n}){let r={doc:e,d:t,meta:$u(n)},i=[Lu()?{before({doc:e,d:t,meta:n}){function r(e){return n.containers.flatMap((e=>e())).some((t=>t.contains(e)))}t.microTask((()=>{var n;if("auto"!==window.getComputedStyle(e.documentElement).scrollBehavior){let n=Ec();n.style(e.documentElement,"scrollBehavior","auto"),t.add((()=>t.microTask((()=>n.dispose()))))}let i=null!=(n=window.scrollY)?n:window.pageYOffset,o=null;t.addEventListener(e,"click",(t=>{if(t.target instanceof HTMLElement)try{let n=t.target.closest("a");if(!n)return;let{hash:i}=new URL(n.href),a=e.querySelector(i);a&&!r(a)&&(o=a)}catch{}}),!0),t.addEventListener(e,"touchstart",(e=>{if(e.target instanceof HTMLElement)if(r(e.target)){let n=e.target;for(;n.parentElement&&r(n.parentElement);)n=n.parentElement;t.style(n,"overscrollBehavior","contain")}else t.style(e.target,"touchAction","none")})),t.addEventListener(e,"touchmove",(e=>{if(e.target instanceof HTMLElement){if("INPUT"===e.target.tagName)return;if(r(e.target)){let t=e.target;for(;t.parentElement&&""!==t.dataset.headlessuiPortal&&!(t.scrollHeight>t.clientHeight||t.scrollWidth>t.clientWidth);)t=t.parentElement;""===t.dataset.headlessuiPortal&&e.preventDefault()}else e.preventDefault()}}),{passive:!1}),t.add((()=>{var e;let t=null!=(e=window.scrollY)?e:window.pageYOffset;i!==t&&window.scrollTo(0,i),o&&o.isConnected&&(o.scrollIntoView({block:"nearest"}),o=null)}))}))}}:{},Nu(),{before({doc:e,d:t}){t.style(e.documentElement,"overflow","hidden")}}];i.forEach((({before:e})=>null==e?void 0:e(r))),i.forEach((({after:e})=>null==e?void 0:e(r)))},SCROLL_ALLOW({d:e}){e.dispose()},TEARDOWN({doc:e}){this.delete(e)}});function Wu(e,t,n=()=>[document.body]){!function(e,t,n=()=>({containers:[]})){let r=cu(Hu),i=t?r.get(t):void 0,o=!!i&&i.count>0;Tc((()=>{if(t&&e)return Hu.dispatch("PUSH",t,n),()=>Hu.dispatch("POP",t,n)}),[e,t])}(du(e,"scroll-lock"),t,(e=>{var t;return{containers:[...null!=(t=e.containers)?t:[],n]}}))}function Uu(e){return[e.screenX,e.screenY]}Hu.subscribe((()=>{let e=Hu.getSnapshot(),t=new Map;for(let[n]of e)t.set(n,n.documentElement.style.overflow);for(let n of e.values()){let e="hidden"===t.get(n.doc),r=0!==n.count;(r&&!e||!r&&e)&&Hu.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),0===n.count&&Hu.dispatch("TEARDOWN",n)}}));var ju,Bu;"undefined"!=typeof process&&"undefined"!=typeof globalThis&&"undefined"!=typeof Element&&"test"===(null==(ju=null==process?void 0:{})?void 0:ju.NODE_ENV)&&void 0===(null==(Bu=null==Element?void 0:Element.prototype)?void 0:Bu.getAnimations)&&(Element.prototype.getAnimations=function(){return console.warn(["Headless UI has polyfilled `Element.prototype.getAnimations` for your tests.","Please install a proper polyfill e.g. `jsdom-testing-mocks`, to silence these warnings.","","Example usage:","```js","import { mockAnimationsApi } from 'jsdom-testing-mocks'","mockAnimationsApi()","```"].join("\n")),[]});var zu=(e=>(e[e.None=0]="None",e[e.Closed=1]="Closed",e[e.Enter=2]="Enter",e[e.Leave=4]="Leave",e))(zu||{});function qu(e){let t={};for(let n in e)!0===e[n]&&(t[`data-${n}`]="");return t}function Ku(e,t,n,r){let[i,o]=Rt(n),{hasFlag:a,addFlag:s,removeFlag:l}=function(e=0){let[t,n]=Rt(e),r=Dt((e=>n(e)),[t]),i=Dt((e=>n((t=>t|e))),[t]),o=Dt((e=>(t&e)===e),[t]),a=Dt((e=>n((t=>t&~e))),[n]),s=Dt((e=>n((t=>t^e))),[n]);return{flags:t,setFlag:r,addFlag:i,hasFlag:o,removeFlag:a,toggleFlag:s}}(e&&i?3:0),c=Mt(!1),u=Mt(!1),d=Cc();return Tc((()=>{var i;if(e)return n&&o(!0),t?(null==(i=null==r?void 0:r.start)||i.call(r,n),function(e,{prepare:t,run:n,done:r,inFlight:i}){let o=Ec();return function(e,{inFlight:t,prepare:n}){if(null!=t&&t.current)return void n();let r=e.style.transition;e.style.transition="none",n(),e.offsetHeight,e.style.transition=r}(e,{prepare:t,inFlight:i}),o.nextFrame((()=>{n(),o.requestAnimationFrame((()=>{o.add(function(e,t){var n,r;let i=Ec();if(!e)return i.dispose;let o=!1;i.add((()=>{o=!0}));let a=null!=(r=null==(n=e.getAnimations)?void 0:n.call(e).filter((e=>e instanceof CSSTransition)))?r:[];return 0===a.length?(t(),i.dispose):(Promise.allSettled(a.map((e=>e.finished))).then((()=>{o||t()})),i.dispose)}(e,r))}))})),o.dispose}(t,{inFlight:c,prepare(){u.current?u.current=!1:u.current=c.current,c.current=!0,!u.current&&(n?(s(3),l(4)):(s(4),l(2)))},run(){u.current?n?(l(3),s(4)):(l(4),s(3)):n?l(1):s(1)},done(){var e;u.current&&"function"==typeof t.getAnimations&&t.getAnimations().length>0||(c.current=!1,l(7),n||o(!1),null==(e=null==r?void 0:r.end)||e.call(r,n))}})):void(n&&s(3))}),[e,n,t,d]),e?[i,{closed:a(1),enter:a(2),leave:a(4),transition:a(2)||a(4)}]:[n,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function Vu(){return"undefined"!=typeof window}function Qu(e){return Ju(e)?(e.nodeName||"").toLowerCase():"#document"}function Yu(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Xu(e){var t;return null==(t=(Ju(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function Ju(e){return!!Vu()&&(e instanceof Node||e instanceof Yu(e).Node)}function Zu(e){return!!Vu()&&(e instanceof Element||e instanceof Yu(e).Element)}function ed(e){return!!Vu()&&(e instanceof HTMLElement||e instanceof Yu(e).HTMLElement)}function td(e){return!(!Vu()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof Yu(e).ShadowRoot)}function nd(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=ld(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function rd(e){return["table","td","th"].includes(Qu(e))}function id(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch(Fc){return!1}}))}function od(e){const t=ad(),n=Zu(e)?ld(e):e;return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function ad(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function sd(e){return["html","body","#document"].includes(Qu(e))}function ld(e){return Yu(e).getComputedStyle(e)}function cd(e){return Zu(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ud(e){if("html"===Qu(e))return e;const t=e.assignedSlot||e.parentNode||td(e)&&e.host||Xu(e);return td(t)?t.host:t}function dd(e){const t=ud(e);return sd(t)?e.ownerDocument?e.ownerDocument.body:e.body:ed(t)&&nd(t)?t:dd(t)}function pd(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const i=dd(e),o=i===(null==(r=e.ownerDocument)?void 0:r.body),a=Yu(i);if(o){const e=hd(a);return t.concat(a,a.visualViewport||[],nd(i)?i:[],e&&n?pd(e):[])}return t.concat(i,pd(i,[],n))}function hd(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}const fd=Math.min,vd=Math.max,md=Math.round,gd=Math.floor,yd=e=>({x:e,y:e}),_d={left:"right",right:"left",bottom:"top",top:"bottom"},wd={start:"end",end:"start"};function bd(e,t,n){return vd(e,fd(t,n))}function xd(e,t){return"function"==typeof e?e(t):e}function kd(e){return e.split("-")[0]}function Sd(e){return e.split("-")[1]}function Ed(e){return"x"===e?"y":"x"}function Cd(e){return"y"===e?"height":"width"}function Td(e){return["top","bottom"].includes(kd(e))?"y":"x"}function Pd(e){return Ed(Td(e))}function Rd(e){return e.replace(/start|end/g,(e=>wd[e]))}function Ad(e){return e.replace(/left|right|bottom|top/g,(e=>_d[e]))}function Od(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function Ld(e,t,n){let{reference:r,floating:i}=e;const o=Td(t),a=Pd(t),s=Cd(a),l=kd(t),c="y"===o,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,p=r[s]/2-i[s]/2;let h;switch(l){case"top":h={x:u,y:r.y-i.height};break;case"bottom":h={x:u,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:d};break;case"left":h={x:r.x-i.width,y:d};break;default:h={x:r.x,y:r.y}}switch(Sd(t)){case"start":h[a]-=p*(n&&c?-1:1);break;case"end":h[a]+=p*(n&&c?-1:1)}return h}async function Md(e,t){var n;void 0===t&&(t={});const{x:r,y:i,platform:o,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:p=!1,padding:h=0}=xd(t,e),f=function(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}(h),v=s[p?"floating"===d?"reference":"floating":d],m=Od(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(v)))||n?v:v.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:u,strategy:l})),g="floating"===d?{x:r,y:i,width:a.floating.width,height:a.floating.height}:a.reference,y=await(null==o.getOffsetParent?void 0:o.getOffsetParent(s.floating)),_=await(null==o.isElement?void 0:o.isElement(y))&&await(null==o.getScale?void 0:o.getScale(y))||{x:1,y:1},w=Od(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:g,offsetParent:y,strategy:l}):g);return{top:(m.top-w.top+f.top)/_.y,bottom:(w.bottom-m.bottom+f.bottom)/_.y,left:(m.left-w.left+f.left)/_.x,right:(w.right-m.right+f.right)/_.x}}function Fd(e){const t=ld(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=ed(e),o=i?e.offsetWidth:n,a=i?e.offsetHeight:r,s=md(n)!==o||md(r)!==a;return s&&(n=o,r=a),{width:n,height:r,$:s}}function Id(e){return Zu(e)?e:e.contextElement}function Dd(e){const t=Id(e);if(!ed(t))return yd(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=Fd(t);let a=(o?md(n.width):n.width)/r,s=(o?md(n.height):n.height)/i;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const Gd=yd(0);function Nd(e){const t=Yu(e);return ad()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Gd}function $d(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const i=e.getBoundingClientRect(),o=Id(e);let a=yd(1);t&&(r?Zu(r)&&(a=Dd(r)):a=Dd(e));const s=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==Yu(e))&&t}(o,n,r)?Nd(o):yd(0);let l=(i.left+s.x)/a.x,c=(i.top+s.y)/a.y,u=i.width/a.x,d=i.height/a.y;if(o){const e=Yu(o),t=r&&Zu(r)?Yu(r):r;let n=e,i=hd(n);for(;i&&r&&t!==n;){const e=Dd(i),t=i.getBoundingClientRect(),r=ld(i),o=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,a=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;l*=e.x,c*=e.y,u*=e.x,d*=e.y,l+=o,c+=a,n=Yu(i),i=hd(n)}}return Od({width:u,height:d,x:l,y:c})}function Hd(e,t){const n=cd(e).scrollLeft;return t?t.left+n:$d(Xu(e)).left+n}function Wd(e,t,n){void 0===n&&(n=!1);const r=e.getBoundingClientRect();return{x:r.left+t.scrollLeft-(n?0:Hd(e,r)),y:r.top+t.scrollTop}}function Ud(e,t,n){let r;if("viewport"===t)r=function(e,t){const n=Yu(e),r=Xu(e),i=n.visualViewport;let o=r.clientWidth,a=r.clientHeight,s=0,l=0;if(i){o=i.width,a=i.height;const e=ad();(!e||e&&"fixed"===t)&&(s=i.offsetLeft,l=i.offsetTop)}return{width:o,height:a,x:s,y:l}}(e,n);else if("document"===t)r=function(e){const t=Xu(e),n=cd(e),r=e.ownerDocument.body,i=vd(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=vd(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+Hd(e);const s=-n.scrollTop;return"rtl"===ld(r).direction&&(a+=vd(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:a,y:s}}(Xu(e));else if(Zu(t))r=function(e,t){const n=$d(e,!0,"fixed"===t),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=ed(e)?Dd(e):yd(1);return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:i*o.x,y:r*o.y}}(t,n);else{const n=Nd(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Od(r)}function jd(e,t){const n=ud(e);return!(n===t||!Zu(n)||sd(n))&&("fixed"===ld(n).position||jd(n,t))}function Bd(e,t,n){const r=ed(t),i=Xu(t),o="fixed"===n,a=$d(e,!0,o,t);let s={scrollLeft:0,scrollTop:0};const l=yd(0);if(r||!r&&!o)if(("body"!==Qu(t)||nd(i))&&(s=cd(t)),r){const e=$d(t,!0,o,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else i&&(l.x=Hd(i));const c=!i||r||o?yd(0):Wd(i,s);return{x:a.left+s.scrollLeft-l.x-c.x,y:a.top+s.scrollTop-l.y-c.y,width:a.width,height:a.height}}function zd(e){return"static"===ld(e).position}function qd(e,t){if(!ed(e)||"fixed"===ld(e).position)return null;if(t)return t(e);let n=e.offsetParent;return Xu(e)===n&&(n=n.ownerDocument.body),n}function Kd(e,t){const n=Yu(e);if(id(e))return n;if(!ed(e)){let t=ud(e);for(;t&&!sd(t);){if(Zu(t)&&!zd(t))return t;t=ud(t)}return n}let r=qd(e,t);for(;r&&rd(r)&&zd(r);)r=qd(r,t);return r&&sd(r)&&zd(r)&&!od(r)?n:r||function(e){let t=ud(e);for(;ed(t)&&!sd(t);){if(od(t))return t;if(id(t))return null;t=ud(t)}return null}(e)||n}const Vd={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const o="fixed"===i,a=Xu(r),s=!!t&&id(t.floating);if(r===a||s&&o)return n;let l={scrollLeft:0,scrollTop:0},c=yd(1);const u=yd(0),d=ed(r);if((d||!d&&!o)&&(("body"!==Qu(r)||nd(a))&&(l=cd(r)),ed(r))){const e=$d(r);c=Dd(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}const p=!a||d||o?yd(0):Wd(a,l,!0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+u.x+p.x,y:n.y*c.y-l.scrollTop*c.y+u.y+p.y}},getDocumentElement:Xu,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=[..."clippingAncestors"===n?id(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let r=pd(e,[],!1).filter((e=>Zu(e)&&"body"!==Qu(e))),i=null;const o="fixed"===ld(e).position;let a=o?ud(e):e;for(;Zu(a)&&!sd(a);){const t=ld(a),n=od(a);n||"fixed"!==t.position||(i=null),(o?!n&&!i:!n&&"static"===t.position&&i&&["absolute","fixed"].includes(i.position)||nd(a)&&!n&&jd(e,a))?r=r.filter((e=>e!==a)):i=t,a=ud(a)}return t.set(e,r),r}(t,this._c):[].concat(n),r],a=o[0],s=o.reduce(((e,n)=>{const r=Ud(t,n,i);return e.top=vd(r.top,e.top),e.right=fd(r.right,e.right),e.bottom=fd(r.bottom,e.bottom),e.left=vd(r.left,e.left),e}),Ud(t,a,i));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:Kd,getElementRects:async function(e){const t=this.getOffsetParent||Kd,n=this.getDimensions,r=await n(e.floating);return{reference:Bd(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=Fd(e);return{width:t,height:n}},getScale:Dd,isElement:Zu,isRTL:function(e){return"rtl"===ld(e).direction}};function Qd(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,c=Id(e),u=i||o?[...c?pd(c):[],...pd(t)]:[];u.forEach((e=>{i&&e.addEventListener("scroll",n,{passive:!0}),o&&e.addEventListener("resize",n)}));const d=c&&s?function(e,t){let n,r=null;const i=Xu(e);function o(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function a(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),o();const{left:c,top:u,width:d,height:p}=e.getBoundingClientRect();if(s||t(),!d||!p)return;const h={rootMargin:-gd(u)+"px "+-gd(i.clientWidth-(c+d))+"px "+-gd(i.clientHeight-(u+p))+"px "+-gd(c)+"px",threshold:vd(0,fd(1,l))||1};let f=!0;function v(e){const t=e[0].intersectionRatio;if(t!==l){if(!f)return a();t?a(!1,t):n=setTimeout((()=>{a(!1,1e-7)}),1e3)}f=!1}try{r=new IntersectionObserver(v,{...h,root:i.ownerDocument})}catch(Fc){r=new IntersectionObserver(v,h)}r.observe(e)}(!0),o}(c,n):null;let p,h=-1,f=null;a&&(f=new ResizeObserver((e=>{let[r]=e;r&&r.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame((()=>{var e;null==(e=f)||e.observe(t)}))),n()})),c&&!l&&f.observe(c),f.observe(t));let v=l?$d(e):null;return l&&function t(){const r=$d(e);!v||r.x===v.x&&r.y===v.y&&r.width===v.width&&r.height===v.height||n();v=r,p=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach((e=>{i&&e.removeEventListener("scroll",n),o&&e.removeEventListener("resize",n)})),null==d||d(),null==(e=f)||e.disconnect(),f=null,l&&cancelAnimationFrame(p)}}const Yd=Md,Xd=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:o,placement:a,middlewareData:s}=t,l=await async function(e,t){const{placement:n,platform:r,elements:i}=e,o=await(null==r.isRTL?void 0:r.isRTL(i.floating)),a=kd(n),s=Sd(n),l="y"===Td(n),c=["left","top"].includes(a)?-1:1,u=o&&l?-1:1,d=xd(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:f}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof f&&(h="end"===s?-1*f:f),l?{x:h*u,y:p*c}:{x:p*c,y:h*u}}(t,e);return a===(null==(n=s.offset)?void 0:n.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:i+l.x,y:o+l.y,data:{...l,placement:a}}}}},Jd=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:o=!0,crossAxis:a=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=xd(e,t),c={x:n,y:r},u=await Md(t,l),d=Td(kd(i)),p=Ed(d);let h=c[p],f=c[d];if(o){const e="y"===p?"bottom":"right";h=bd(h+u["y"===p?"top":"left"],h,h-u[e])}if(a){const e="y"===d?"bottom":"right";f=bd(f+u["y"===d?"top":"left"],f,f-u[e])}const v=s.fn({...t,[p]:h,[d]:f});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[p]:o,[d]:a}}}}}},Zd=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:o,rects:a,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:v=!0,...m}=xd(e,t);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const g=kd(i),y=Td(s),_=kd(s)===s,w=await(null==l.isRTL?void 0:l.isRTL(c.floating)),b=p||(_||!v?[Ad(s)]:function(e){const t=Ad(e);return[Rd(e),t,Rd(t)]}(s)),x="none"!==f;!p&&x&&b.push(...function(e,t,n,r){const i=Sd(e);let o=function(e,t,n){const r=["left","right"],i=["right","left"],o=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?o:a;default:return[]}}(kd(e),"start"===n,r);return i&&(o=o.map((e=>e+"-"+i)),t&&(o=o.concat(o.map(Rd)))),o}(s,v,f,w));const k=[s,...b],S=await Md(t,m),E=[];let C=(null==(r=o.flip)?void 0:r.overflows)||[];if(u&&E.push(S[g]),d){const e=function(e,t,n){void 0===n&&(n=!1);const r=Sd(e),i=Pd(e),o=Cd(i);let a="x"===i?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=Ad(a)),[a,Ad(a)]}(i,a,w);E.push(S[e[0]],S[e[1]])}if(C=[...C,{placement:i,overflows:E}],!E.every((e=>e<=0))){var T,P;const e=((null==(T=o.flip)?void 0:T.index)||0)+1,t=k[e];if(t)return{data:{index:e,overflows:C},reset:{placement:t}};let n=null==(P=C.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:P.placement;if(!n)switch(h){case"bestFit":{var R;const e=null==(R=C.filter((e=>{if(x){const t=Td(e.placement);return t===y||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:R[0];e&&(n=e);break}case"initialPlacement":n=s}if(i!==n)return{reset:{placement:n}}}return{}}}},ep=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:o,platform:a,elements:s}=t,{apply:l=()=>{},...c}=xd(e,t),u=await Md(t,c),d=kd(i),p=Sd(i),h="y"===Td(i),{width:f,height:v}=o.floating;let m,g;"top"===d||"bottom"===d?(m=d,g=p===(await(null==a.isRTL?void 0:a.isRTL(s.floating))?"start":"end")?"left":"right"):(g=d,m="end"===p?"top":"bottom");const y=v-u.top-u.bottom,_=f-u.left-u.right,w=fd(v-u[m],y),b=fd(f-u[g],_),x=!t.middlewareData.shift;let k=w,S=b;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(S=_),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(k=y),x&&!p){const e=vd(u.left,0),t=vd(u.right,0),n=vd(u.top,0),r=vd(u.bottom,0);h?S=f-2*(0!==e||0!==t?e+t:vd(u.left,u.right)):k=v-2*(0!==n||0!==r?n+r:vd(u.top,u.bottom))}await l({...t,availableWidth:S,availableHeight:k});const E=await a.getDimensions(s.floating);return f!==E.width||v!==E.height?{reset:{rects:!0}}:{}}}},tp=(e,t,n)=>{const r=new Map,i={platform:Vd,...n},o={...i.platform,_c:r};return(async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:a}=n,s=o.filter(Boolean),l=await(null==a.isRTL?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=Ld(c,r,l),p=r,h={},f=0;for(let v=0;v<s.length;v++){const{name:n,fn:o}=s[v],{x:m,y:g,data:y,reset:_}=await o({x:u,y:d,initialPlacement:r,placement:p,strategy:i,middlewareData:h,rects:c,platform:a,elements:{reference:e,floating:t}});u=null!=m?m:u,d=null!=g?g:d,h={...h,[n]:{...h[n],...y}},_&&f<=50&&(f++,"object"==typeof _&&(_.placement&&(p=_.placement),_.rects&&(c=!0===_.rects?await a.getElementRects({reference:e,floating:t,strategy:i}):_.rects),({x:u,y:d}=Ld(c,p,l))),v=-1)}return{x:u,y:d,placement:p,strategy:i,middlewareData:h}})(e,t,{...i,platform:o})};var np="undefined"!=typeof document?Lt:Ot;function rp(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;0!=r--;)if(!rp(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;0!=r--;){const n=i[r];if(("_owner"!==n||!e.$$typeof)&&!rp(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function ip(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function op(e,t){const n=ip(e);return Math.round(t*n)/n}function ap(e){const t=Mt(e);return np((()=>{t.current=e})),t}const sp=(e,t)=>({...Xd(e),options:[e,t]}),lp=(e,t)=>({...Zd(e),options:[e,t]}),cp=(e,t)=>({...ep(e),options:[e,t]}),up={...Kr},dp=up.useInsertionEffect||(e=>e());function pp(e){const t=Mt((()=>{}));return dp((()=>{t.current=e})),Dt((function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return null==t.current?void 0:t.current(...n)}),[])}var hp="undefined"!=typeof document?Lt:Ot;let fp=!1,vp=0;const mp=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+vp++;const gp=up.useId||function(){const[e,t]=Rt((()=>fp?mp():void 0));return hp((()=>{null==e&&t(mp())}),[]),Ot((()=>{fp=!0}),[]),e};const yp=at(null),_p=at(null),wp="data-floating-ui-focusable";function bp(e){const{open:t=!1,onOpenChange:n,elements:r}=e,i=gp(),o=Mt({}),[a]=Rt((()=>function(){const e=new Map;return{emit(t,n){var r;null==(r=e.get(t))||r.forEach((e=>e(n)))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var r;e.set(t,(null==(r=e.get(t))?void 0:r.filter((e=>e!==n)))||[])}}}())),s=null!=((null==(l=Gt(yp))?void 0:l.id)||null);var l;const[c,u]=Rt(r.reference),d=pp(((e,t,r)=>{o.current.openEvent=e?t:void 0,a.emit("openchange",{open:e,event:t,reason:r,nested:s}),null==n||n(e,t,r)})),p=It((()=>({setPositionReference:u})),[]),h=It((()=>({reference:c||r.reference||null,floating:r.floating||null,domReference:r.reference})),[c,r.reference,r.floating]);return It((()=>({dataRef:o,open:t,onOpenChange:d,elements:h,events:a,floatingId:i,refs:p})),[t,d,h,a,i,p])}function xp(e){void 0===e&&(e={});const{nodeId:t}=e,n=bp({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,i=r.elements,[o,a]=Rt(null),[s,l]=Rt(null),c=(null==i?void 0:i.domReference)||o,u=Mt(null),d=Gt(_p);hp((()=>{c&&(u.current=c)}),[c]);const p=function(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:a}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[u,d]=Rt({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,h]=Rt(r);rp(p,r)||h(r);const[f,v]=Rt(null),[m,g]=Rt(null),y=Dt((e=>{e!==x.current&&(x.current=e,v(e))}),[]),_=Dt((e=>{e!==k.current&&(k.current=e,g(e))}),[]),w=o||f,b=a||m,x=Mt(null),k=Mt(null),S=Mt(u),E=null!=l,C=ap(l),T=ap(i),P=ap(c),R=Dt((()=>{if(!x.current||!k.current)return;const e={placement:t,strategy:n,middleware:p};T.current&&(e.platform=T.current),tp(x.current,k.current,e).then((e=>{const t={...e,isPositioned:!1!==P.current};A.current&&!rp(S.current,t)&&(S.current=t,Gr((()=>{d(t)})))}))}),[p,t,n,T,P]);np((()=>{!1===c&&S.current.isPositioned&&(S.current.isPositioned=!1,d((e=>({...e,isPositioned:!1}))))}),[c]);const A=Mt(!1);np((()=>(A.current=!0,()=>{A.current=!1})),[]),np((()=>{if(w&&(x.current=w),b&&(k.current=b),w&&b){if(C.current)return C.current(w,b,R);R()}}),[w,b,R,C,E]);const O=It((()=>({reference:x,floating:k,setReference:y,setFloating:_})),[y,_]),L=It((()=>({reference:w,floating:b})),[w,b]),M=It((()=>{const e={position:n,left:0,top:0};if(!L.floating)return e;const t=op(L.floating,u.x),r=op(L.floating,u.y);return s?{...e,transform:"translate("+t+"px, "+r+"px)",...ip(L.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}}),[n,s,L.floating,u.x,u.y]);return It((()=>({...u,update:R,refs:O,elements:L,floatingStyles:M})),[u,R,O,L,M])}({...e,elements:{...i,...s&&{reference:s}}}),h=Dt((e=>{const t=Zu(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),contextElement:e}:e;l(t),p.refs.setReference(t)}),[p.refs]),f=Dt((e=>{(Zu(e)||null===e)&&(u.current=e,a(e)),(Zu(p.refs.reference.current)||null===p.refs.reference.current||null!==e&&!Zu(e))&&p.refs.setReference(e)}),[p.refs]),v=It((()=>({...p.refs,setReference:f,setPositionReference:h,domReference:u})),[p.refs,f,h]),m=It((()=>({...p.elements,domReference:c})),[p.elements,c]),g=It((()=>({...p,...r,refs:v,elements:m,nodeId:t})),[p,v,m,t,r]);return hp((()=>{r.dataRef.current.floatingContext=g;const e=null==d?void 0:d.nodesRef.current.find((e=>e.id===t));e&&(e.context=g)})),It((()=>({...p,context:g,refs:v,elements:m})),[p,v,m,g])}const kp="active",Sp="selected";function Ep(e,t,n){const r=new Map,i="item"===n;let o=e;if(i&&e){const{[kp]:t,[Sp]:n,...r}=e;o=r}return{..."floating"===n&&{tabIndex:-1,[wp]:""},...o,...t.map((t=>{const r=t?t[n]:null;return"function"==typeof r?e?r(e):null:r})).concat(e).reduce(((e,t)=>t?(Object.entries(t).forEach((t=>{let[n,o]=t;var a;i&&[kp,Sp].includes(n)||(0===n.indexOf("on")?(r.has(n)||r.set(n,[]),"function"==typeof o&&(null==(a=r.get(n))||a.push(o),e[n]=function(){for(var e,t=arguments.length,i=new Array(t),o=0;o<t;o++)i[o]=arguments[o];return null==(e=r.get(n))?void 0:e.map((e=>e(...i))).find((e=>void 0!==e))})):e[n]=o)})),e):e),{})}}function Cp(e,t){return{...e,rects:{...e.rects,floating:{...e.rects.floating,height:t}}}}function Tp(e,t){const{open:n,elements:r}=e,{enabled:i=!0,overflowRef:o,scrollRef:a,onChange:s}=t,l=pp(s),c=Mt(!1),u=Mt(null),d=Mt(null);Ot((()=>{if(!i)return;function e(e){if(e.ctrlKey||!t||null==o.current)return;const n=e.deltaY,r=o.current.top>=-.5,i=o.current.bottom>=-.5,a=t.scrollHeight-t.clientHeight,s=n<0?-1:1,c=n<0?"max":"min";t.scrollHeight<=t.clientHeight||(!r&&n>0||!i&&n<0?(e.preventDefault(),Gr((()=>{l((e=>e+Math[c](n,a*s)))}))):/firefox/i.test(function(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map((e=>{let{brand:t,version:n}=e;return t+"/"+n})).join(" "):navigator.userAgent}())&&(t.scrollTop+=n))}const t=(null==a?void 0:a.current)||r.floating;return n&&t?(t.addEventListener("wheel",e),requestAnimationFrame((()=>{u.current=t.scrollTop,null!=o.current&&(d.current={...o.current})})),()=>{u.current=null,d.current=null,t.removeEventListener("wheel",e)}):void 0}),[i,n,r.floating,o,a,l]);const p=It((()=>({onKeyDown(){c.current=!0},onWheel(){c.current=!1},onPointerMove(){c.current=!1},onScroll(){const e=(null==a?void 0:a.current)||r.floating;if(o.current&&e&&c.current){if(null!==u.current){const t=e.scrollTop-u.current;(o.current.bottom<-.5&&t<-1||o.current.top<-.5&&t>1)&&Gr((()=>l((e=>e+t))))}requestAnimationFrame((()=>{u.current=e.scrollTop}))}}})),[r.floating,l,o,a]);return It((()=>i?{floating:p}:{}),[i,p])}let Pp=at({styles:void 0,setReference:()=>{},setFloating:()=>{},getReferenceProps:()=>({}),getFloatingProps:()=>({}),slot:{}});Pp.displayName="FloatingContext";let Rp=at(null);Rp.displayName="PlacementContext";function Ap({children:e,enabled:t=!0}){let[n,r]=Rt(null),[i,o]=Rt(0),a=Mt(null),[s,l]=Rt(null);!function(e){Tc((()=>{if(!e)return;let t=new MutationObserver((()=>{let t=window.getComputedStyle(e).maxHeight,n=parseFloat(t);if(isNaN(n))return;let r=parseInt(t);isNaN(r)||n!==r&&(e.style.maxHeight=`${Math.ceil(n)}px`)}));return t.observe(e,{attributes:!0,attributeFilter:["style"]}),()=>{t.disconnect()}}),[e])}(s);let c=t&&null!==n&&null!==s,{to:u="bottom",gap:d=0,offset:p=0,padding:h=0,inner:f}=function(e,t){var n,r,i;let o=Op(null!=(n=null==e?void 0:e.gap)?n:"var(--anchor-gap, 0)",t),a=Op(null!=(r=null==e?void 0:e.offset)?r:"var(--anchor-offset, 0)",t),s=Op(null!=(i=null==e?void 0:e.padding)?i:"var(--anchor-padding, 0)",t);return{...e,gap:o,offset:a,padding:s}}(n,s),[v,m="center"]=u.split(" ");Tc((()=>{c&&o(0)}),[c]);let{refs:g,floatingStyles:y,context:_}=xp({open:c,placement:"selection"===v?"center"===m?"bottom":`bottom-${m}`:"center"===m?`${v}`:`${v}-${m}`,strategy:"absolute",transform:!1,middleware:[sp({mainAxis:"selection"===v?0:d,crossAxis:p}),(k={padding:h},{...Jd(k),options:[k,S]}),"selection"!==v&&lp({padding:h}),"selection"===v&&f?(x={...f,padding:h,overflowRef:a,offset:i,minItemsVisible:4,referenceOverflowThreshold:h,onFallbackChange(e){var t,n;if(!e)return;let r=_.elements.floating;if(!r)return;let i=parseFloat(getComputedStyle(r).scrollPaddingBottom)||0,a=Math.min(4,r.childElementCount),s=0,l=0;for(let o of null!=(n=null==(t=_.elements.floating)?void 0:t.childNodes)?n:[])if(o instanceof HTMLElement){let e=o.offsetTop,t=e+o.clientHeight+i,n=r.scrollTop,c=n+r.clientHeight;if(!(e>=n&&t<=c)){l=Math.max(0,Math.min(t,c)-Math.max(e,n)),s=o.clientHeight;break}a--}a>=1&&o((e=>{let t=s*a-l+i;return e>=t?e:t}))}},{name:"inner",options:x,async fn(e){const{listRef:t,overflowRef:n,onFallbackChange:r,offset:i=0,index:o=0,minItemsVisible:a=4,referenceOverflowThreshold:s=0,scrollRef:l,...c}=xd(x,e),{rects:u,elements:{floating:d}}=e,p=t.current[o],h=(null==l?void 0:l.current)||d,f=d.clientTop||h.clientTop,v=0!==d.clientTop,m=0!==h.clientTop,g=d===h;if(!p)return{};const y={...e,...await sp(-p.offsetTop-d.clientTop-u.reference.height/2-p.offsetHeight/2-i).fn(e)},_=await Yd(Cp(y,h.scrollHeight+f+d.clientTop),c),w=await Yd(y,{...c,elementContext:"reference"}),b=vd(0,_.top),k=y.y+b,S=h.scrollHeight>h.clientHeight,E=(S?e=>e:md)(vd(0,h.scrollHeight+(v&&g||m?2*f:0)-b-vd(0,_.bottom)));if(h.style.maxHeight=E+"px",h.scrollTop=b,r){const e=S&&h.offsetHeight<p.offsetHeight*a-1||w.top>=-s||w.bottom>=-s;Gr((()=>r(e)))}return n&&(n.current=await Yd(Cp({...y,y:k},h.offsetHeight+f+d.clientTop),c)),{y:k}}}):null,cp({padding:h,apply({availableWidth:e,availableHeight:t,elements:n}){Object.assign(n.floating.style,{overflow:"auto",maxWidth:`${e}px`,maxHeight:`min(var(--anchor-max-height, 100vh), ${t}px)`})}})].filter(Boolean),whileElementsMounted:Qd}),[w=v,b=m]=_.placement.split("-");var x,k,S;"selection"===v&&(w="selection");let E=It((()=>({anchor:[w,b].filter(Boolean).join(" ")})),[w,b]),C=Tp(_,{overflowRef:a,onChange:o}),{getReferenceProps:T,getFloatingProps:P}=function(e){void 0===e&&(e=[]);const t=e.map((e=>null==e?void 0:e.reference)),n=e.map((e=>null==e?void 0:e.floating)),r=e.map((e=>null==e?void 0:e.item)),i=Dt((t=>Ep(t,e,"reference")),t),o=Dt((t=>Ep(t,e,"floating")),n),a=Dt((t=>Ep(t,e,"item")),r);return It((()=>({getReferenceProps:i,getFloatingProps:o,getItemProps:a})),[i,o,a])}([C]),R=Rc((e=>{l(e),g.setFloating(e)}));return De(Rp.Provider,{value:r},De(Pp.Provider,{value:{setFloating:R,setReference:g.setReference,styles:y,getReferenceProps:T,getFloatingProps:P,slot:E}},e))}function Op(e,t,n=void 0){let r=Cc(),i=Rc(((e,t)=>{if(null==e)return[n,null];if("number"==typeof e)return[e,null];if("string"==typeof e){if(!t)return[n,null];let i=Mp(e,t);return[i,n=>{let o=Lp(e);{let a=o.map((e=>window.getComputedStyle(t).getPropertyValue(e)));r.requestAnimationFrame((function s(){r.nextFrame(s);let l=!1;for(let[e,n]of o.entries()){let r=window.getComputedStyle(t).getPropertyValue(n);if(a[e]!==r){a[e]=r,l=!0;break}}if(!l)return;let c=Mp(e,t);i!==c&&(n(c),i=c)}))}return r.dispose}]}return[n,null]})),o=It((()=>i(e,t)[0]),[e,t]),[a=o,s]=Rt();return Tc((()=>{let[n,r]=i(e,t);if(s(n),r)return r(s)}),[e,t]),a}function Lp(e){let t=/var\((.*)\)/.exec(e);if(t){let e=t[1].indexOf(",");if(-1===e)return[t[1]];let n=t[1].slice(0,e).trim(),r=t[1].slice(e+1).trim();return r?[n,...Lp(r)]:[n]}return[]}function Mp(e,t){let n=document.createElement("div");t.appendChild(n),n.style.setProperty("margin-top","0px","important"),n.style.setProperty("margin-top",e,"important");let r=parseFloat(window.getComputedStyle(n).marginTop)||0;return t.removeChild(n),r}let Fp=at(null);Fp.displayName="OpenClosedContext";var Ip=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(Ip||{});function Dp(){return Gt(Fp)}function Gp({value:e,children:t}){return qr.createElement(Fp.Provider,{value:e},t)}var Np,$p=((Np=$p||{})[Np.First=0]="First",Np[Np.Previous=1]="Previous",Np[Np.Next=2]="Next",Np[Np.Last=3]="Last",Np[Np.Specific=4]="Specific",Np[Np.Nothing=5]="Nothing",Np);function Hp(e,t){let n=t.resolveItems();if(n.length<=0)return null;let r=t.resolveActiveIndex(),i=null!=r?r:-1;switch(e.focus){case 0:for(let e=0;e<n.length;++e)if(!t.resolveDisabled(n[e],e,n))return e;return r;case 1:-1===i&&(i=n.length);for(let e=i-1;e>=0;--e)if(!t.resolveDisabled(n[e],e,n))return e;return r;case 2:for(let e=i+1;e<n.length;++e)if(!t.resolveDisabled(n[e],e,n))return e;return r;case 3:for(let e=n.length-1;e>=0;--e)if(!t.resolveDisabled(n[e],e,n))return e;return r;case 4:for(let r=0;r<n.length;++r)if(t.resolveId(n[r],r,n)===e.id)return r;return r;case 5:return null;default:!function(e){throw new Error("Unexpected object: "+e)}(e)}}function Wp(){let e=function(){let e="undefined"==typeof document;return"useSyncExternalStore"in Kr&&(e=>e.useSyncExternalStore)(Kr)((()=>()=>{}),(()=>!1),(()=>!e))}(),[t,n]=Rt(xc.isHandoffComplete);return t&&!1===xc.isHandoffComplete&&n(!1),Ot((()=>{!0!==t&&n(!0)}),[t]),Ot((()=>xc.handoff()),[]),!e&&t}let Up=at(!1);function jp(e){let t=Gt(Up),n=Gt(Kp),r=Du(e),[i,o]=Rt((()=>{var e;if(!t&&null!==n)return null!=(e=n.current)?e:null;if(xc.isServer)return null;let i=null==r?void 0:r.getElementById("headlessui-portal-root");if(i)return i;if(null===r)return null;let o=r.createElement("div");return o.setAttribute("id","headlessui-portal-root"),r.body.appendChild(o)}));return Ot((()=>{null!==i&&(null!=r&&r.body.contains(i)||null==r||r.body.appendChild(i))}),[i,r]),Ot((()=>{t||null!==n&&o(n.current)}),[n,o,t]),i}let Bp=$e,zp=jc((function(e,t){let n=e,r=Mt(null),i=Yc(function(e,t=!0){return Object.assign(e,{[Qc]:t})}((e=>{r.current=e})),t),o=Du(r),a=jp(r),[s]=Rt((()=>{var e;return xc.isServer?null:null!=(e=null==o?void 0:o.createElement("div"))?e:null})),l=Gt(Vp),c=Wp();Tc((()=>{!a||!s||a.contains(s)||(s.setAttribute("data-headlessui-portal",""),a.appendChild(s))}),[a,s]),Tc((()=>{if(s&&l)return l.register(s)}),[l,s]),function(e){let t=Rc(e),n=Mt(!1);Ot((()=>(n.current=!1,()=>{n.current=!0,Sc((()=>{n.current&&t()}))})),[t])}((()=>{var e;!a||!s||(s instanceof Node&&a.contains(s)&&a.removeChild(s),a.childNodes.length<=0&&(null==(e=a.parentElement)||e.removeChild(a)))}));let u=Nc();return c&&a&&s?ur(u({ourProps:{ref:i},theirProps:n,slot:{},defaultTag:Bp,name:"Portal"}),s):null}));let qp=$e,Kp=at(null);let Vp=at(null),Qp=jc((function(e,t){let n=Yc(t),{enabled:r=!0,...i}=e,o=Nc();return r?qr.createElement(zp,{...i,ref:n}):o({ourProps:{ref:n},theirProps:i,slot:{},defaultTag:Bp,name:"Portal"})})),Yp=jc((function(e,t){let{target:n,...r}=e,i={ref:Yc(t)},o=Nc();return qr.createElement(Kp.Provider,{value:n},o({ourProps:i,theirProps:r,defaultTag:qp,name:"Popover.Group"}))})),Xp=Object.assign(Qp,{Group:Yp});function Jp(e){var t;return!!(e.enter||e.enterFrom||e.enterTo||e.leave||e.leaveFrom||e.leaveTo)||(null!=(t=e.as)?t:ih)!==$e||1===qr.Children.count(e.children)}let Zp=at(null);Zp.displayName="TransitionContext";var eh=(e=>(e.Visible="visible",e.Hidden="hidden",e))(eh||{});let th=at(null);function nh(e){return"children"in e?nh(e.children):e.current.filter((({el:e})=>null!==e.current)).filter((({state:e})=>"visible"===e)).length>0}function rh(e,t){let n=Pc(e),r=Mt([]),i=function(){let e=Mt(!1);return Tc((()=>(e.current=!0,()=>{e.current=!1})),[]),e}(),o=Cc(),a=Rc(((e,t=Gc.Hidden)=>{let a=r.current.findIndex((({el:t})=>t===e));-1!==a&&(Mc(t,{[Gc.Unmount](){r.current.splice(a,1)},[Gc.Hidden](){r.current[a].state="hidden"}}),o.microTask((()=>{var e;!nh(r)&&i.current&&(null==(e=n.current)||e.call(n))})))})),s=Rc((e=>{let t=r.current.find((({el:t})=>t===e));return t?"visible"!==t.state&&(t.state="visible"):r.current.push({el:e,state:"visible"}),()=>a(e,Gc.Unmount)})),l=Mt([]),c=Mt(Promise.resolve()),u=Mt({enter:[],leave:[]}),d=Rc(((e,n,r)=>{l.current.splice(0),t&&(t.chains.current[n]=t.chains.current[n].filter((([t])=>t!==e))),null==t||t.chains.current[n].push([e,new Promise((e=>{l.current.push(e)}))]),null==t||t.chains.current[n].push([e,new Promise((e=>{Promise.all(u.current[n].map((([e,t])=>t))).then((()=>e()))}))]),"enter"===n?c.current=c.current.then((()=>null==t?void 0:t.wait.current)).then((()=>r(n))):r(n)})),p=Rc(((e,t,n)=>{Promise.all(u.current[t].splice(0).map((([e,t])=>t))).then((()=>{var e;null==(e=l.current.shift())||e()})).then((()=>n(t)))}));return It((()=>({children:r,register:s,unregister:a,onStart:d,onStop:p,wait:c,chains:u})),[s,a,r,d,p,u,c])}th.displayName="NestingContext";let ih=$e,oh=Dc.RenderStrategy;let ah=jc((function(e,t){let{show:n,appear:r=!1,unmount:i=!0,...o}=e,a=Mt(null),s=Yc(...Jp(e)?[a,t]:null===t?[]:[t]);Wp();let l=Dp();if(void 0===n&&null!==l&&(n=(l&Ip.Open)===Ip.Open),void 0===n)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[c,u]=Rt(n?"visible":"hidden"),d=rh((()=>{n||u("hidden")})),[p,h]=Rt(!0),f=Mt([n]);Tc((()=>{!1!==p&&f.current[f.current.length-1]!==n&&(f.current.push(n),h(!1))}),[f,n]);let v=It((()=>({show:n,appear:r,initial:p})),[n,r,p]);Tc((()=>{n?u("visible"):!nh(d)&&null!==a.current&&u("hidden")}),[n,d]);let m={unmount:i},g=Rc((()=>{var t;p&&h(!1),null==(t=e.beforeEnter)||t.call(e)})),y=Rc((()=>{var t;p&&h(!1),null==(t=e.beforeLeave)||t.call(e)})),_=Nc();return qr.createElement(th.Provider,{value:d},qr.createElement(Zp.Provider,{value:v},_({ourProps:{...m,as:$e,children:qr.createElement(sh,{ref:s,...m,...o,beforeEnter:g,beforeLeave:y})},theirProps:{},defaultTag:$e,features:oh,visible:"visible"===c,name:"Transition"})))})),sh=jc((function(e,t){var n,r;let{transition:i=!0,beforeEnter:o,afterEnter:a,beforeLeave:s,afterLeave:l,enter:c,enterFrom:u,enterTo:d,entered:p,leave:h,leaveFrom:f,leaveTo:v,...m}=e,[g,y]=Rt(null),_=Mt(null),w=Jp(e),b=Yc(...w?[_,t,y]:null===t?[]:[t]),x=null==(n=m.unmount)||n?Gc.Unmount:Gc.Hidden,{show:k,appear:S,initial:E}=function(){let e=Gt(Zp);if(null===e)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),[C,T]=Rt(k?"visible":"hidden"),P=function(){let e=Gt(th);if(null===e)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),{register:R,unregister:A}=P;Tc((()=>R(_)),[R,_]),Tc((()=>{if(x===Gc.Hidden&&_.current)return k&&"visible"!==C?void T("visible"):Mc(C,{hidden:()=>A(_),visible:()=>R(_)})}),[C,_,R,A,k,x]);let O=Wp();Tc((()=>{if(w&&O&&"visible"===C&&null===_.current)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")}),[_,C,O,w]);let L=E&&!S,M=S&&k&&E,F=Mt(!1),I=rh((()=>{F.current||(T("hidden"),A(_))}),P),D=Rc((e=>{F.current=!0;let t=e?"enter":"leave";I.onStart(_,t,(e=>{"enter"===e?null==o||o():"leave"===e&&(null==s||s())}))})),G=Rc((e=>{let t=e?"enter":"leave";F.current=!1,I.onStop(_,t,(e=>{"enter"===e?null==a||a():"leave"===e&&(null==l||l())})),"leave"===t&&!nh(I)&&(T("hidden"),A(_))}));Ot((()=>{w&&i||(D(k),G(k))}),[k,w,i]);let N=(()=>!(!i||!w||!O||L))(),[,$]=Ku(N,g,k,{start:D,end:G}),H=Bc({ref:b,className:(null==(r=Lc(m.className,M&&c,M&&u,$.enter&&c,$.enter&&$.closed&&u,$.enter&&!$.closed&&d,$.leave&&h,$.leave&&!$.closed&&f,$.leave&&$.closed&&v,!$.transition&&k&&p))?void 0:r.trim())||void 0,...qu($)}),W=0;"visible"===C&&(W|=Ip.Open),"hidden"===C&&(W|=Ip.Closed),$.enter&&(W|=Ip.Opening),$.leave&&(W|=Ip.Closing);let U=Nc();return qr.createElement(th.Provider,{value:I},qr.createElement(Gp,{value:W},U({ourProps:H,theirProps:m,defaultTag:ih,features:oh,visible:"visible"===C,name:"Transition.Child"})))})),lh=jc((function(e,t){let n=null!==Gt(Zp),r=null!==Dp();return qr.createElement(qr.Fragment,null,!n&&r?qr.createElement(ah,{ref:t,...e}):qr.createElement(sh,{ref:t,...e}))})),ch=Object.assign(ah,{Child:lh,Root:ah});let uh=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;function dh(e){var t,n;let r=null!=(t=e.innerText)?t:"",i=e.cloneNode(!0);if(!(i instanceof HTMLElement))return r;let o=!1;for(let s of i.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))s.remove(),o=!0;let a=o?null!=(n=i.innerText)?n:"":r;return uh.test(a)&&(a=a.replace(uh,"")),a}function ph(e){let t=Mt(""),n=Mt("");return Rc((()=>{let r=e.current;if(!r)return"";let i=r.innerText;if(t.current===i)return n.current;let o=function(e){let t=e.getAttribute("aria-label");if("string"==typeof t)return t.trim();let n=e.getAttribute("aria-labelledby");if(n){let e=n.split(" ").map((e=>{let t=document.getElementById(e);if(t){let e=t.getAttribute("aria-label");return"string"==typeof e?e.trim():dh(t).trim()}return null})).filter(Boolean);if(e.length>0)return e.join(", ")}return dh(e).trim()}(r).trim().toLowerCase();return t.current=i,n.current=o,o}))}var hh=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(hh||{}),fh=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(fh||{}),vh=(e=>(e[e.OpenMenu=0]="OpenMenu",e[e.CloseMenu=1]="CloseMenu",e[e.GoToItem=2]="GoToItem",e[e.Search=3]="Search",e[e.ClearSearch=4]="ClearSearch",e[e.RegisterItem=5]="RegisterItem",e[e.UnregisterItem=6]="UnregisterItem",e[e.SetButtonElement=7]="SetButtonElement",e[e.SetItemsElement=8]="SetItemsElement",e))(vh||{});function mh(e,t=e=>e){let n=null!==e.activeItemIndex?e.items[e.activeItemIndex]:null,r=Au(t(e.items.slice()),(e=>e.dataRef.current.domRef.current)),i=n?r.indexOf(n):null;return-1===i&&(i=null),{items:r,activeItemIndex:i}}let gh={1:e=>1===e.menuState?e:{...e,activeItemIndex:null,menuState:1},0:e=>0===e.menuState?e:{...e,__demoMode:!1,menuState:0},2:(e,t)=>{var n,r,i,o,a;if(1===e.menuState)return e;let s={...e,searchQuery:"",activationTrigger:null!=(n=t.trigger)?n:1,__demoMode:!1};if(t.focus===$p.Nothing)return{...s,activeItemIndex:null};if(t.focus===$p.Specific)return{...s,activeItemIndex:e.items.findIndex((e=>e.id===t.id))};if(t.focus===$p.Previous){let n=e.activeItemIndex;if(null!==n){let o=e.items[n].dataRef.current.domRef,a=Hp(t,{resolveItems:()=>e.items,resolveActiveIndex:()=>e.activeItemIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});if(null!==a){let t=e.items[a].dataRef.current.domRef;if((null==(r=o.current)?void 0:r.previousElementSibling)===t.current||null===(null==(i=t.current)?void 0:i.previousElementSibling))return{...s,activeItemIndex:a}}}}else if(t.focus===$p.Next){let n=e.activeItemIndex;if(null!==n){let r=e.items[n].dataRef.current.domRef,i=Hp(t,{resolveItems:()=>e.items,resolveActiveIndex:()=>e.activeItemIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});if(null!==i){let t=e.items[i].dataRef.current.domRef;if((null==(o=r.current)?void 0:o.nextElementSibling)===t.current||null===(null==(a=t.current)?void 0:a.nextElementSibling))return{...s,activeItemIndex:i}}}}let l=mh(e),c=Hp(t,{resolveItems:()=>l.items,resolveActiveIndex:()=>l.activeItemIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});return{...s,...l,activeItemIndex:c}},3:(e,t)=>{let n=""!==e.searchQuery?0:1,r=e.searchQuery+t.value.toLowerCase(),i=(null!==e.activeItemIndex?e.items.slice(e.activeItemIndex+n).concat(e.items.slice(0,e.activeItemIndex+n)):e.items).find((e=>{var t;return(null==(t=e.dataRef.current.textValue)?void 0:t.startsWith(r))&&!e.dataRef.current.disabled})),o=i?e.items.indexOf(i):-1;return-1===o||o===e.activeItemIndex?{...e,searchQuery:r}:{...e,searchQuery:r,activeItemIndex:o,activationTrigger:1}},4:e=>""===e.searchQuery?e:{...e,searchQuery:"",searchActiveItemIndex:null},5:(e,t)=>{let n=mh(e,(e=>[...e,{id:t.id,dataRef:t.dataRef}]));return{...e,...n}},6:(e,t)=>{let n=mh(e,(e=>{let n=e.findIndex((e=>e.id===t.id));return-1!==n&&e.splice(n,1),e}));return{...e,...n,activationTrigger:1}},7:(e,t)=>e.buttonElement===t.element?e:{...e,buttonElement:t.element},8:(e,t)=>e.itemsElement===t.element?e:{...e,itemsElement:t.element}},yh=at(null);function _h(e){let t=Gt(yh);if(null===t){let t=new Error(`<${e} /> is missing a parent <Menu /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(t,_h),t}return t}function wh(e,t){return Mc(t.type,gh,e,t)}yh.displayName="MenuContext";let bh=$e;let xh=Dc.RenderStrategy|Dc.Static;let kh=$e;let Sh=jc((function(e,t){let{__demoMode:n=!1,...r}=e,i=At(wh,{__demoMode:n,menuState:n?0:1,buttonElement:null,itemsElement:null,items:[],searchQuery:"",activeItemIndex:null,activationTrigger:1}),[{menuState:o,itemsElement:a,buttonElement:s},l]=i,c=Yc(t);Iu(0===o,[s,a],((e,t)=>{l({type:1}),Cu(t,Eu.Loose)||(e.preventDefault(),null==s||s.focus())}));let u=Rc((()=>{l({type:1})})),d=It((()=>({open:0===o,close:u})),[o,u]),p={ref:c},h=Nc();return qr.createElement(Ap,null,qr.createElement(yh.Provider,{value:i},qr.createElement(Gp,{value:Mc(o,{0:Ip.Open,1:Ip.Closed})},h({ourProps:p,theirProps:r,slot:d,defaultTag:bh,name:"Menu"}))))})),Eh=jc((function(e,t){var n;let r=$t(),{id:i=`headlessui-menu-button-${r}`,disabled:o=!1,autoFocus:a=!1,...s}=e,[l,c]=_h("Menu.Button"),u=Gt(Pp).getReferenceProps,d=Yc(t,Gt(Pp).setReference,Rc((e=>c({type:7,element:e})))),p=Rc((e=>{switch(e.key){case tu.Space:case tu.Enter:case tu.ArrowDown:e.preventDefault(),e.stopPropagation(),Gr((()=>c({type:0}))),c({type:2,focus:$p.First});break;case tu.ArrowUp:e.preventDefault(),e.stopPropagation(),Gr((()=>c({type:0}))),c({type:2,focus:$p.Last})}})),h=Rc((e=>{if(e.key===tu.Space)e.preventDefault()})),f=Rc((e=>{var t;if(Vc(e.currentTarget))return e.preventDefault();o||(0===l.menuState?(Gr((()=>c({type:1}))),null==(t=l.buttonElement)||t.focus({preventScroll:!0})):(e.preventDefault(),c({type:0})))})),{isFocusVisible:v,focusProps:m}=_c({autoFocus:a}),{isHovered:g,hoverProps:y}=function(e){let{onHoverStart:t,onHoverChange:n,onHoverEnd:r,isDisabled:i}=e,[o,a]=Rt(!1),s=Mt({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;Ot(yc,[]);let{hoverProps:l,triggerHoverEnd:c}=It((()=>{let e=(e,r)=>{if(s.pointerType=r,i||"touch"===r||s.isHovered||!e.currentTarget.contains(e.target))return;s.isHovered=!0;let o=e.currentTarget;s.target=o,t&&t({type:"hoverstart",target:o,pointerType:r}),n&&n(!0),a(!0)},o=(e,t)=>{if(s.pointerType="",s.target=null,"touch"===t||!s.isHovered)return;s.isHovered=!1;let i=e.currentTarget;r&&r({type:"hoverend",target:i,pointerType:t}),n&&n(!1),a(!1)},l={};return"undefined"!=typeof PointerEvent?(l.onPointerEnter=t=>{fc&&"mouse"===t.pointerType||e(t,t.pointerType)},l.onPointerLeave=e=>{!i&&e.currentTarget.contains(e.target)&&o(e,e.pointerType)}):(l.onTouchStart=()=>{s.ignoreEmulatedMouseEvents=!0},l.onMouseEnter=t=>{s.ignoreEmulatedMouseEvents||fc||e(t,"mouse"),s.ignoreEmulatedMouseEvents=!1},l.onMouseLeave=e=>{!i&&e.currentTarget.contains(e.target)&&o(e,"mouse")}),{hoverProps:l,triggerHoverEnd:o}}),[t,n,r,i,s]);return Ot((()=>{i&&c({currentTarget:s.target},s.pointerType)}),[i]),{hoverProps:l,isHovered:o}}({isDisabled:o}),{pressed:_,pressProps:w}=function({disabled:e=!1}={}){let t=Mt(null),[n,r]=Rt(!1),i=Cc(),o=Rc((()=>{t.current=null,r(!1),i.dispose()})),a=Rc((e=>{if(i.dispose(),null===t.current){t.current=e.currentTarget,r(!0);{let n=kc(e.currentTarget);i.addEventListener(n,"pointerup",o,!1),i.addEventListener(n,"pointermove",(e=>{if(t.current){let n=function(e){let t=e.width/2,n=e.height/2;return{top:e.clientY-n,right:e.clientX+t,bottom:e.clientY+n,left:e.clientX-t}}(e);r(function(e,t){return!(!e||!t||e.right<t.left||e.left>t.right||e.bottom<t.top||e.top>t.bottom)}(n,t.current.getBoundingClientRect()))}}),!1),i.addEventListener(n,"pointercancel",o,!1)}}}));return{pressed:n,pressProps:e?{}:{onPointerDown:a,onPointerUp:o,onClick:o}}}({disabled:o}),b=It((()=>({open:0===l.menuState,active:_||0===l.menuState,disabled:o,hover:g,focus:v,autofocus:a})),[l,g,v,_,o,a]),x=Uc(u(),{ref:d,id:i,type:Gu(e,l.buttonElement),"aria-haspopup":"menu","aria-controls":null==(n=l.itemsElement)?void 0:n.id,"aria-expanded":0===l.menuState,disabled:o||void 0,autoFocus:a,onKeyDown:p,onKeyUp:h,onClick:f},m,y,w);return Nc()({ourProps:x,theirProps:s,slot:b,defaultTag:"button",name:"Menu.Button"})})),Ch=jc((function(e,t){var n,r;let i=$t(),{id:o=`headlessui-menu-items-${i}`,anchor:a,portal:s=!1,modal:l=!0,transition:c=!1,...u}=e,d=function(e){return It((()=>e?"string"==typeof e?{to:e}:e:null),[e])}(a),[p,h]=_h("Menu.Items"),[f,v]=function(e=null){!1===e&&(e=null),"string"==typeof e&&(e={to:e});let t=Gt(Rp),n=It((()=>e),[JSON.stringify(e,((e,t)=>{var n;return null!=(n=null==t?void 0:t.outerHTML)?n:t}))]);Tc((()=>{null==t||t(null!=n?n:null)}),[t,n]);let r=Gt(Pp);return It((()=>[r.setFloating,e?r.styles:{}]),[r.setFloating,e,r.styles])}(d),m=function(){let{getFloatingProps:e,slot:t}=Gt(Pp);return Dt(((...n)=>Object.assign({},e(...n),{"data-anchor":t.anchor})),[e,t])}(),[g,y]=Rt(null),_=Yc(t,d?f:null,Rc((e=>h({type:8,element:e}))),y),w=Du(p.itemsElement);d&&(s=!0);let b=Dp(),[x,k]=Ku(c,g,null!==b?(b&Ip.Open)===Ip.Open:0===p.menuState);!function(e,t,n){let r=Pc((e=>{let t=e.getBoundingClientRect();0===t.x&&0===t.y&&0===t.width&&0===t.height&&n()}));Ot((()=>{if(!e)return;let n=null===t?null:t instanceof HTMLElement?t:t.current;if(!n)return;let i=Ec();if("undefined"!=typeof ResizeObserver){let e=new ResizeObserver((()=>r.current(n)));e.observe(n),i.add((()=>e.disconnect()))}if("undefined"!=typeof IntersectionObserver){let e=new IntersectionObserver((()=>r.current(n)));e.observe(n),i.add((()=>e.disconnect()))}return()=>i.dispose()}),[t,r,e])}(x,p.buttonElement,(()=>{h({type:1})})),Wu(!p.__demoMode&&(l&&0===p.menuState),w),function(e,{allowed:t,disallowed:n}={}){let r=du(e,"inert-others");Tc((()=>{var e,i;if(!r)return;let o=Ec();for(let t of null!=(e=null==n?void 0:n())?e:[])t&&o.add(fu(t));let a=null!=(i=null==t?void 0:t())?i:[];for(let t of a){if(!t)continue;let e=kc(t);if(!e)continue;let n=t.parentElement;for(;n&&n!==e.body;){for(let e of n.children)a.some((t=>e.contains(t)))||o.add(fu(e));n=n.parentElement}}return o.dispose}),[r,t,n])}(!p.__demoMode&&(l&&0===p.menuState),{allowed:Dt((()=>[p.buttonElement,p.itemsElement]),[p.buttonElement,p.itemsElement])});let S=!function(e,t){let n=Mt({left:0,top:0});if(Tc((()=>{if(!t)return;let e=t.getBoundingClientRect();e&&(n.current=e)}),[e,t]),null==t||!e||t===document.activeElement)return!1;let r=t.getBoundingClientRect();return r.top!==n.current.top||r.left!==n.current.left}(0!==p.menuState,p.buttonElement)&&x;Ot((()=>{let e=p.itemsElement;e&&0===p.menuState&&e!==(null==w?void 0:w.activeElement)&&e.focus({preventScroll:!0})}),[p.menuState,p.itemsElement,w]),function(e,{container:t,accept:n,walk:r}){let i=Mt(n),o=Mt(r);Ot((()=>{i.current=n,o.current=r}),[n,r]),Tc((()=>{if(!t||!e)return;let n=kc(t);if(!n)return;let r=i.current,a=o.current,s=Object.assign((e=>r(e)),{acceptNode:r}),l=n.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,s,!1);for(;l.nextNode();)a(l.currentNode)}),[t,e,i,o])}(0===p.menuState,{container:p.itemsElement,accept:e=>"menuitem"===e.getAttribute("role")?NodeFilter.FILTER_REJECT:e.hasAttribute("role")?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT,walk(e){e.setAttribute("role","none")}});let E=Cc(),C=Rc((e=>{var t,n,r;switch(E.dispose(),e.key){case tu.Space:if(""!==p.searchQuery)return e.preventDefault(),e.stopPropagation(),h({type:3,value:e.key});case tu.Enter:if(e.preventDefault(),e.stopPropagation(),h({type:1}),null!==p.activeItemIndex){let{dataRef:e}=p.items[p.activeItemIndex];null==(n=null==(t=e.current)?void 0:t.domRef.current)||n.click()}Tu(p.buttonElement);break;case tu.ArrowDown:return e.preventDefault(),e.stopPropagation(),h({type:2,focus:$p.Next});case tu.ArrowUp:return e.preventDefault(),e.stopPropagation(),h({type:2,focus:$p.Previous});case tu.Home:case tu.PageUp:return e.preventDefault(),e.stopPropagation(),h({type:2,focus:$p.First});case tu.End:case tu.PageDown:return e.preventDefault(),e.stopPropagation(),h({type:2,focus:$p.Last});case tu.Escape:e.preventDefault(),e.stopPropagation(),Gr((()=>h({type:1}))),null==(r=p.buttonElement)||r.focus({preventScroll:!0});break;case tu.Tab:e.preventDefault(),e.stopPropagation(),Gr((()=>h({type:1}))),Ou(p.buttonElement,e.shiftKey?bu.Previous:bu.Next);break;default:1===e.key.length&&(h({type:3,value:e.key}),E.setTimeout((()=>h({type:4})),350))}})),T=Rc((e=>{if(e.key===tu.Space)e.preventDefault()})),P=It((()=>({open:0===p.menuState})),[p.menuState]),R=Uc(d?m():{},{"aria-activedescendant":null===p.activeItemIndex||null==(n=p.items[p.activeItemIndex])?void 0:n.id,"aria-labelledby":null==(r=p.buttonElement)?void 0:r.id,id:o,onKeyDown:C,onKeyUp:T,role:"menu",tabIndex:0===p.menuState?0:void 0,ref:_,style:{...u.style,...v,"--button-width":au(p.buttonElement,!0).width},...qu(k)}),A=Nc();return qr.createElement(Xp,{enabled:!!s&&(e.static||x)},A({ourProps:R,theirProps:u,slot:P,defaultTag:"div",features:xh,visible:S,name:"Menu.Items"}))})),Th=jc((function(e,t){let n=$t(),{id:r=`headlessui-menu-item-${n}`,disabled:i=!1,...o}=e,[a,s]=_h("Menu.Item"),l=null!==a.activeItemIndex&&a.items[a.activeItemIndex].id===r,c=Mt(null),u=Yc(t,c);Tc((()=>{if(!a.__demoMode&&0===a.menuState&&l&&0!==a.activationTrigger)return Ec().requestAnimationFrame((()=>{var e,t;null==(t=null==(e=c.current)?void 0:e.scrollIntoView)||t.call(e,{block:"nearest"})}))}),[a.__demoMode,c,l,a.menuState,a.activationTrigger,a.activeItemIndex]);let d=ph(c),p=Mt({disabled:i,domRef:c,get textValue(){return d()}});Tc((()=>{p.current.disabled=i}),[p,i]),Tc((()=>(s({type:5,id:r,dataRef:p}),()=>s({type:6,id:r}))),[p,r]);let h=Rc((()=>{s({type:1})})),f=Rc((e=>{if(i)return e.preventDefault();s({type:1}),Tu(a.buttonElement)})),v=Rc((()=>{if(i)return s({type:2,focus:$p.Nothing});s({type:2,focus:$p.Specific,id:r})})),m=function(){let e=Mt([-1,-1]);return{wasMoved(t){let n=Uu(t);return(e.current[0]!==n[0]||e.current[1]!==n[1])&&(e.current=n,!0)},update(t){e.current=Uu(t)}}}(),g=Rc((e=>{m.update(e),!i&&(l||s({type:2,focus:$p.Specific,id:r,trigger:0}))})),y=Rc((e=>{m.wasMoved(e)&&(i||l||s({type:2,focus:$p.Specific,id:r,trigger:0}))})),_=Rc((e=>{m.wasMoved(e)&&(i||l&&s({type:2,focus:$p.Nothing}))})),[w,b]=iu(),[x,k]=function(){let[e,t]=Rt([]);return[e.length>0?e.join(" "):void 0,It((()=>function(e){let n=Rc((e=>(t((t=>[...t,e])),()=>t((t=>{let n=t.slice(),r=n.indexOf(e);return-1!==r&&n.splice(r,1),n}))))),r=It((()=>({register:n,slot:e.slot,name:e.name,props:e.props,value:e.value})),[n,e.slot,e.name,e.props,e.value]);return qr.createElement(Xc.Provider,{value:r},e.children)}),[t])]}(),S=It((()=>({active:l,focus:l,disabled:i,close:h})),[l,i,h]),E={id:r,ref:u,role:"menuitem",tabIndex:!0===i?void 0:-1,"aria-disabled":!0===i||void 0,"aria-labelledby":w,"aria-describedby":x,disabled:void 0,onClick:f,onFocus:v,onPointerEnter:g,onMouseEnter:g,onPointerMove:y,onMouseMove:y,onPointerLeave:_,onMouseLeave:_},C=Nc();return qr.createElement(b,null,qr.createElement(k,null,C({ourProps:E,theirProps:o,slot:S,defaultTag:kh,name:"Menu.Item"})))})),Ph=jc((function(e,t){let[n,r]=iu(),i=e,o={ref:t,"aria-labelledby":n,role:"group"},a=Nc();return qr.createElement(r,null,a({ourProps:o,theirProps:i,slot:{},defaultTag:"div",name:"Menu.Section"}))})),Rh=jc((function(e,t){let n=$t(),{id:r=`headlessui-menu-heading-${n}`,...i}=e,o=ru();Tc((()=>o.register(r)),[r,o.register]);let a={id:r,ref:t,role:"presentation",...o.props};return Nc()({ourProps:a,theirProps:i,slot:{},defaultTag:"header",name:"Menu.Heading"})})),Ah=jc((function(e,t){let n=e,r={ref:t,role:"separator"};return Nc()({ourProps:r,theirProps:n,slot:{},defaultTag:"div",name:"Menu.Separator"})})),Oh=Object.assign(Sh,{Button:Eh,Items:Ch,Item:Th,Section:Ph,Heading:Rh,Separator:Ah});function Lh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8.625 12a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0H8.25m4.125 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0H12m4.125 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0h-.375M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"}))}const Mh=Yn(Lh);function Fh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z"}))}const Ih=Yn(Fh),Dh=e=>Gl(Wh,{children:Nl(Oh,{as:"div",children:[Gl("div",{children:Nl(Eh,{css:{display:"flex",alignItems:"center",borderRadius:"9999px","--tw-bg-opacity":"1",backgroundColor:"rgb(243 244 246 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(156 163 175 / var(--tw-text-opacity))",":hover":{"--tw-text-opacity":"1",color:"rgb(75 85 99 / var(--tw-text-opacity))"},":focus":{outline:"2px solid transparent",outlineOffset:"2px","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-opacity":"1","--tw-ring-color":"rgb(99 102 241 / var(--tw-ring-opacity))","--tw-ring-offset-width":"2px","--tw-ring-offset-color":"#f3f4f6"}},children:[Gl("span",{css:{position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"},children:"Open options"}),Gl(Mh,{"aria-hidden":"true",css:{width:"1.25rem",height:"1.25rem"}})]})}),Gl(Ch,{transition:!0,className:"right-45 w-30",css:{position:"fixed",zIndex:"10",marginTop:"0.5rem",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))","--tw-shadow":"0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)","--tw-shadow-colored":"0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)","--tw-ring-color":"rgb(0 0 0 / 0.05)",transitionProperty:"color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"150ms",":focus":{outline:"2px solid transparent",outlineOffset:"2px"},"&[data-closed]":{"--tw-scale-x":".95","--tw-scale-y":".95",transform:"translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))",opacity:"0"},"&[data-enter]":{transitionDuration:"100ms",transitionTimingFunction:"cubic-bezier(0, 0, 0.2, 1)"},"&[data-leave]":{transitionDuration:"75ms",transitionTimingFunction:"cubic-bezier(0.4, 0, 1, 1)"}},children:e.items.map(((t,n)=>Gl(Th,{children:Gl("button",{type:"button",css:{display:"block",paddingLeft:"1rem",paddingRight:"1rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))","&[data-focus]":{"--tw-bg-opacity":"1",backgroundColor:"rgb(243 244 246 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))",outline:"2px solid transparent",outlineOffset:"2px"}},onClick:()=>{t.onClick(e.id)},children:t.label},n)},n)))})]})}),Gh=e=>e&&new Date(e).toLocaleDateString("en-AU")||void 0,Nh=e=>void 0!==e&&`$ ${Number(e).toLocaleString("en-US")}`||void 0,$h=e=>Nl(Wh,{children:[Gh(e.value),Gl("br",{}),Gh(e.value)]}),Hh=e=>{const[t,n]=Rt(!1);return Nl(Wh,{css:{position:"relative"},children:[Gl(ch,{show:t,children:Gl("div",{css:{position:"absolute",bottom:"3rem",display:"flex",height:"2rem",width:"4.313rem",flexDirection:"row",alignItems:"flex-start",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(17 24 39 / var(--tw-bg-opacity))",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",opacity:"0.9","--tw-shadow":"0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)","--tw-shadow-colored":"0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",transitionProperty:"opacity",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"150ms","&[data-closed]":{opacity:"0"},"&[data-enter]":{transitionDuration:"100ms",transitionTimingFunction:"cubic-bezier(0.4, 0, 1, 1)"},"&[data-leave]":{transitionDuration:"500ms",transitionTimingFunction:"cubic-bezier(0, 0, 0.2, 1)"}},children:Gl("p",{css:{order:"0",height:"1rem",width:"2.813rem",flex:"none",flexGrow:"0",fontSize:"0.75rem",lineHeight:"1rem",fontWeight:"500",fontStyle:"normal","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))"},children:"Copied"})})}),Gl("button",{onClick:async()=>{await(async e=>{await navigator.clipboard.writeText(e)})(e.value),n(!0),setTimeout((()=>{n(!1)}),3e3)},type:"button",css:{display:"block",flexShrink:"1",borderRadius:"0.375rem",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(209 213 219 / var(--tw-bg-opacity))"},"&[data-focus]":{"--tw-bg-opacity":"1",backgroundColor:"rgb(243 244 246 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))",outline:"2px solid transparent",outlineOffset:"2px"}},children:e.value})]})},Wh=Ml.td`
11
+ */(n.expires)||!Number.isFinite(n.expires.valueOf()))throw new TypeError(`option expires is invalid: ${n.expires}`);o+="; Expires="+n.expires.toUTCString()}n.httpOnly&&(o+="; HttpOnly");n.secure&&(o+="; Secure");n.partitioned&&(o+="; Partitioned");if(n.priority){switch("string"==typeof n.priority?n.priority.toLowerCase():void 0){case"low":o+="; Priority=Low";break;case"medium":o+="; Priority=Medium";break;case"high":o+="; Priority=High";break;default:throw new TypeError(`option priority is invalid: ${n.priority}`)}}if(n.sameSite){switch("string"==typeof n.sameSite?n.sameSite.toLowerCase():n.sameSite){case!0:case"strict":o+="; SameSite=Strict";break;case"lax":o+="; SameSite=Lax";break;case"none":o+="; SameSite=None";break;default:throw new TypeError(`option sameSite is invalid: ${n.sameSite}`)}}return o};const Oi=/^[\u0021-\u003A\u003C\u003E-\u007E]+$/,Li=/^[\u0021-\u003A\u003C-\u007E]*$/,Mi=/^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,Fi=/^[\u0020-\u003A\u003D-\u007E]*$/,Ii=Object.prototype.toString,Di=(()=>{const e=function(){};return e.prototype=Object.create(null),e})();function Gi(e,t,n){do{const n=e.charCodeAt(t);if(32!==n&&9!==n)return t}while(++t<n);return n}function Ni(e,t,n){for(;t>n;){const n=e.charCodeAt(--t);if(32!==n&&9!==n)return t+1}return n}function $i(e){if(-1===e.indexOf("%"))return e;try{return decodeURIComponent(e)}catch(Mc){return e}}var Hi="popstate";function Wi(e={}){return function(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:o=!1}=r,a=i.history,s="POP",l=null,c=u();null==c&&(c=0,a.replaceState({...a.state,idx:c},""));function u(){return(a.state||{idx:null}).idx}function d(){s="POP";let e=u(),t=null==e?null:e-c;c=e,l&&l({action:s,location:v.location,delta:t})}function p(e,t){s="PUSH";let r=zi(v.location,e,t);n&&n(r,e),c=u()+1;let d=Bi(r,c),p=v.createHref(r);try{a.pushState(d,"",p)}catch(h){if(h instanceof DOMException&&"DataCloneError"===h.name)throw h;i.location.assign(p)}o&&l&&l({action:s,location:v.location,delta:1})}function h(e,t){s="REPLACE";let r=zi(v.location,e,t);n&&n(r,e),c=u();let i=Bi(r,c),d=v.createHref(r);a.replaceState(i,"",d),o&&l&&l({action:s,location:v.location,delta:0})}function f(e){let t="null"!==i.location.origin?i.location.origin:i.location.href,n="string"==typeof e?e:qi(e);return n=n.replace(/ $/,"%20"),Ui(t,`No window.location.(origin|href) available to create URL for href: ${n}`),new URL(n,t)}let v={get action(){return s},get location(){return e(i,a)},listen(e){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(Hi,d),l=e,()=>{i.removeEventListener(Hi,d),l=null}},createHref:e=>t(i,e),createURL:f,encodeLocation(e){let t=f(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:p,replace:h,go:e=>a.go(e)};return v}((function(e,t){let{pathname:n="/",search:r="",hash:i=""}=Ki(e.location.hash.substring(1));return n.startsWith("/")||n.startsWith(".")||(n="/"+n),zi("",{pathname:n,search:r,hash:i},t.state&&t.state.usr||null,t.state&&t.state.key||"default")}),(function(e,t){let n=e.document.querySelector("base"),r="";if(n&&n.getAttribute("href")){let t=e.location.href,n=t.indexOf("#");r=-1===n?t:t.slice(0,n)}return r+"#"+("string"==typeof t?t:qi(t))}),(function(e,t){ji("/"===e.pathname.charAt(0),`relative pathnames are not supported in hash history.push(${JSON.stringify(t)})`)}),e)}function Ui(e,t){if(!1===e||null==e)throw new Error(t)}function ji(e,t){if(!e){"undefined"!=typeof console&&console.warn(t);try{throw new Error(t)}catch(Mc){}}}function Bi(e,t){return{usr:e.state,key:e.key,idx:t}}function zi(e,t,n=null,r){return{pathname:"string"==typeof e?e:e.pathname,search:"",hash:"",..."string"==typeof t?Ki(t):t,state:n,key:t&&t.key||r||Math.random().toString(36).substring(2,10)}}function qi({pathname:e="/",search:t="",hash:n=""}){return t&&"?"!==t&&(e+="?"===t.charAt(0)?t:"?"+t),n&&"#"!==n&&(e+="#"===n.charAt(0)?n:"#"+n),e}function Ki(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function Vi(e,t,n="/"){return function(e,t,n,r){let i="string"==typeof t?Ki(t):t,o=lo(i.pathname||"/",n);if(null==o)return null;let a=Qi(e);!function(e){e.sort(((e,t)=>e.score!==t.score?t.score-e.score:function(e,t){let n=e.length===t.length&&e.slice(0,-1).every(((e,n)=>e===t[n]));return n?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map((e=>e.childrenIndex)),t.routesMeta.map((e=>e.childrenIndex)))))}(a);let s=null;for(let l=0;null==s&&l<a.length;++l){let e=so(o);s=oo(a[l],e,r)}return s}(e,t,n,!1)}function Qi(e,t=[],n=[],r=""){let i=(e,i,o)=>{let a={relativePath:void 0===o?e.path||"":o,caseSensitive:!0===e.caseSensitive,childrenIndex:i,route:e};a.relativePath.startsWith("/")&&(Ui(a.relativePath.startsWith(r),`Absolute route path "${a.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),a.relativePath=a.relativePath.slice(r.length));let s=ho([r,a.relativePath]),l=n.concat(a);e.children&&e.children.length>0&&(Ui(!0!==e.index,`Index routes must not have child routes. Please remove all child routes from route path "${s}".`),Qi(e.children,t,l,s)),(null!=e.path||e.index)&&t.push({path:s,score:io(s,e.index),routesMeta:l})};return e.forEach(((e,t)=>{var n;if(""!==e.path&&(null==(n=e.path)?void 0:n.includes("?")))for(let r of Yi(e.path))i(e,t,r);else i(e,t)})),t}function Yi(e){let t=e.split("/");if(0===t.length)return[];let[n,...r]=t,i=n.endsWith("?"),o=n.replace(/\?$/,"");if(0===r.length)return i?[o,""]:[o];let a=Yi(r.join("/")),s=[];return s.push(...a.map((e=>""===e?o:[o,e].join("/")))),i&&s.push(...a),s.map((t=>e.startsWith("/")&&""===t?"/":t))}var Xi=/^:[\w-]+$/,Ji=3,Zi=2,eo=1,to=10,no=-2,ro=e=>"*"===e;function io(e,t){let n=e.split("/"),r=n.length;return n.some(ro)&&(r+=no),t&&(r+=Zi),n.filter((e=>!ro(e))).reduce(((e,t)=>e+(Xi.test(t)?Ji:""===t?eo:to)),r)}function oo(e,t,n=!1){let{routesMeta:r}=e,i={},o="/",a=[];for(let s=0;s<r.length;++s){let e=r[s],l=s===r.length-1,c="/"===o?t:t.slice(o.length)||"/",u=ao({path:e.relativePath,caseSensitive:e.caseSensitive,end:l},c),d=e.route;if(!u&&l&&n&&!r[r.length-1].route.index&&(u=ao({path:e.relativePath,caseSensitive:e.caseSensitive,end:!1},c)),!u)return null;Object.assign(i,u.params),a.push({params:i,pathname:ho([o,u.pathname]),pathnameBase:fo(ho([o,u.pathnameBase])),route:d}),"/"!==u.pathnameBase&&(o=ho([o,u.pathnameBase]))}return a}function ao(e,t){"string"==typeof e&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=function(e,t=!1,n=!0){ji("*"===e||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,((e,t,n)=>(r.push({paramName:t,isOptional:null!=n}),n?"/?([^\\/]+)?":"/([^\\/]+)")));e.endsWith("*")?(r.push({paramName:"*"}),i+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":""!==e&&"/"!==e&&(i+="(?:(?=\\/|$))");let o=new RegExp(i,t?void 0:"i");return[o,r]}(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let o=i[0],a=o.replace(/(.)\/+$/,"$1"),s=i.slice(1);return{params:r.reduce(((e,{paramName:t,isOptional:n},r)=>{if("*"===t){let e=s[r]||"";a=o.slice(0,o.length-e.length).replace(/(.)\/+$/,"$1")}const i=s[r];return e[t]=n&&!i?void 0:(i||"").replace(/%2F/g,"/"),e}),{}),pathname:o,pathnameBase:a,pattern:e}}function so(e){try{return e.split("/").map((e=>decodeURIComponent(e).replace(/\//g,"%2F"))).join("/")}catch(t){return ji(!1,`The URL path "${e}" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function lo(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&"/"!==r?null:e.slice(n)||"/"}function co(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function uo(e){let t=function(e){return e.filter(((e,t)=>0===t||e.route.path&&e.route.path.length>0))}(e);return t.map(((e,n)=>n===t.length-1?e.pathname:e.pathnameBase))}function po(e,t,n,r=!1){let i;"string"==typeof e?i=Ki(e):(i={...e},Ui(!i.pathname||!i.pathname.includes("?"),co("?","pathname","search",i)),Ui(!i.pathname||!i.pathname.includes("#"),co("#","pathname","hash",i)),Ui(!i.search||!i.search.includes("#"),co("#","search","hash",i)));let o,a=""===e||""===i.pathname,s=a?"/":i.pathname;if(null==s)o=n;else{let e=t.length-1;if(!r&&s.startsWith("..")){let t=s.split("/");for(;".."===t[0];)t.shift(),e-=1;i.pathname=t.join("/")}o=e>=0?t[e]:"/"}let l=function(e,t="/"){let{pathname:n,search:r="",hash:i=""}="string"==typeof e?Ki(e):e,o=n?n.startsWith("/")?n:function(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach((e=>{".."===e?n.length>1&&n.pop():"."!==e&&n.push(e)})),n.length>1?n.join("/"):"/"}(n,t):t;return{pathname:o,search:vo(r),hash:mo(i)}}(i,o),c=s&&"/"!==s&&s.endsWith("/"),u=(a||"."===s)&&n.endsWith("/");return l.pathname.endsWith("/")||!c&&!u||(l.pathname+="/"),l}var ho=e=>e.join("/").replace(/\/\/+/g,"/"),fo=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),vo=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",mo=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";var go=["POST","PUT","PATCH","DELETE"];new Set(go);var yo=["GET",...go];new Set(yo);var _o=at(null);_o.displayName="DataRouter";var wo=at(null);wo.displayName="DataRouterState";var bo=at({isTransitioning:!1});bo.displayName="ViewTransition",at(new Map).displayName="Fetchers",at(null).displayName="Await";var xo=at(null);xo.displayName="Navigation";var ko=at(null);ko.displayName="Location";var So=at({outlet:null,matches:[],isDataRoute:!1});So.displayName="Route";var Eo=at(null);function Co(){return null!=Gt(ko)}function To(){return Ui(Co(),"useLocation() may be used only in the context of a <Router> component."),Gt(ko).location}Eo.displayName="RouteError";var Po="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Ro(e){Gt(xo).static||Lt(e)}function Ao(){let{isDataRoute:e}=Gt(So);return e?function(){let{router:e}=function(e){let t=Gt(_o);return Ui(t,$o(e)),t}("useNavigate"),t=Ho("useNavigate"),n=Mt(!1);return Ro((()=>{n.current=!0})),Dt((async(r,i={})=>{ji(n.current,Po),n.current&&("number"==typeof r?e.navigate(r):await e.navigate(r,{fromRouteId:t,...i}))}),[e,t])}():function(){Ui(Co(),"useNavigate() may be used only in the context of a <Router> component.");let e=Gt(_o),{basename:t,navigator:n}=Gt(xo),{matches:r}=Gt(So),{pathname:i}=To(),o=JSON.stringify(uo(r)),a=Mt(!1);return Ro((()=>{a.current=!0})),Dt(((r,s={})=>{if(ji(a.current,Po),!a.current)return;if("number"==typeof r)return void n.go(r);let l=po(r,JSON.parse(o),i,"path"===s.relative);null==e&&"/"!==t&&(l.pathname="/"===l.pathname?t:ho([t,l.pathname])),(s.replace?n.replace:n.push)(l,s.state,s)}),[t,n,o,i,e])}()}var Oo=at(null);function Lo(e){let t=Gt(So).outlet;return t?De(Oo.Provider,{value:e},t):t}function Mo(e,{relative:t}={}){let{matches:n}=Gt(So),{pathname:r}=To(),i=JSON.stringify(uo(n));return It((()=>po(e,JSON.parse(i),r,"path"===t)),[e,i,r,t])}function Fo(e,t,n,r){var i;Ui(Co(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:o}=Gt(xo),{matches:a}=Gt(So),s=a[a.length-1],l=s?s.params:{},c=s?s.pathname:"/",u=s?s.pathnameBase:"/",d=s&&s.route;{let e=d&&d.path||"";Uo(c,!d||e.endsWith("*")||e.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${c}" (under <Route path="${e}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.\n\nPlease change the parent <Route path="${e}"> to <Route path="${"/"===e?"*":`${e}/*`}">.`)}let p,h=To();if(t){let e="string"==typeof t?Ki(t):t;Ui("/"===u||(null==(i=e.pathname)?void 0:i.startsWith(u)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${u}" but pathname "${e.pathname}" was given in the \`location\` prop.`),p=e}else p=h;let f=p.pathname||"/",v=f;if("/"!==u){let e=u.replace(/^\//,"").split("/");v="/"+f.replace(/^\//,"").split("/").slice(e.length).join("/")}let m=Vi(e,{pathname:v});ji(d||null!=m,`No routes matched location "${p.pathname}${p.search}${p.hash}" `),ji(null==m||void 0!==m[m.length-1].route.element||void 0!==m[m.length-1].route.Component||void 0!==m[m.length-1].route.lazy,`Matched leaf route at location "${p.pathname}${p.search}${p.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let g=function(e,t=[],n=null){if(null==e){if(!n)return null;if(n.errors)e=n.matches;else{if(0!==t.length||n.initialized||!(n.matches.length>0))return null;e=n.matches}}let r=e,i=null==n?void 0:n.errors;if(null!=i){let e=r.findIndex((e=>e.route.id&&void 0!==(null==i?void 0:i[e.route.id])));Ui(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(i).join(",")}`),r=r.slice(0,Math.min(r.length,e+1))}let o=!1,a=-1;if(n)for(let s=0;s<r.length;s++){let e=r[s];if((e.route.HydrateFallback||e.route.hydrateFallbackElement)&&(a=s),e.route.id){let{loaderData:t,errors:i}=n,s=e.route.loader&&!t.hasOwnProperty(e.route.id)&&(!i||void 0===i[e.route.id]);if(e.route.lazy||s){o=!0,r=a>=0?r.slice(0,a+1):[r[0]];break}}}return r.reduceRight(((e,s,l)=>{let c,u=!1,d=null,p=null;n&&(c=i&&s.route.id?i[s.route.id]:void 0,d=s.route.errorElement||Do,o&&(a<0&&0===l?(Uo("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),u=!0,p=null):a===l&&(u=!0,p=s.route.hydrateFallbackElement||null)));let h=t.concat(r.slice(0,l+1)),f=()=>{let t;return t=c?d:u?p:s.route.Component?De(s.route.Component,null):s.route.element?s.route.element:e,De(No,{match:s,routeContext:{outlet:e,matches:h,isDataRoute:null!=n},children:t})};return n&&(s.route.ErrorBoundary||s.route.errorElement||0===l)?De(Go,{location:n.location,revalidation:n.revalidation,component:d,error:c,children:f(),routeContext:{outlet:null,matches:h,isDataRoute:!0}}):f()}),null)}(m&&m.map((e=>Object.assign({},e,{params:Object.assign({},l,e.params),pathname:ho([u,o.encodeLocation?o.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?u:ho([u,o.encodeLocation?o.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])}))),a,n,r);return t&&g?De(ko.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...p},navigationType:"POP"}},g):g}function Io(){let e=function(){var e;let t=Gt(Eo),n=function(e){let t=Gt(wo);return Ui(t,$o(e)),t}("useRouteError"),r=Ho("useRouteError");if(void 0!==t)return t;return null==(e=n.errors)?void 0:e[r]}(),t=function(e){return null!=e&&"number"==typeof e.status&&"string"==typeof e.statusText&&"boolean"==typeof e.internal&&"data"in e}(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",i={padding:"0.5rem",backgroundColor:r},o={padding:"2px 4px",backgroundColor:r},a=null;return console.error("Error handled by React Router default ErrorBoundary:",e),a=De($e,null,De("p",null,"💿 Hey developer 👋"),De("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",De("code",{style:o},"ErrorBoundary")," or"," ",De("code",{style:o},"errorElement")," prop on your route.")),De($e,null,De("h2",null,"Unexpected Application Error!"),De("h3",{style:{fontStyle:"italic"}},t),n?De("pre",{style:i},n):null,a)}var Do=De(Io,null),Go=class extends He{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||"idle"!==t.revalidation&&"idle"===e.revalidation?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:void 0!==e.error?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){console.error("React Router caught the following error during render",e,t)}render(){return void 0!==this.state.error?De(So.Provider,{value:this.props.routeContext},De(Eo.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function No({routeContext:e,match:t,children:n}){let r=Gt(_o);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),De(So.Provider,{value:e},n)}function $o(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Ho(e){let t=function(e){let t=Gt(So);return Ui(t,$o(e)),t}(e),n=t.matches[t.matches.length-1];return Ui(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}var Wo={};function Uo(e,t,n){t||Wo[e]||(Wo[e]=!0,ji(!1,n))}function jo({to:e,replace:t,state:n,relative:r}){Ui(Co(),"<Navigate> may be used only in the context of a <Router> component.");let{static:i}=Gt(xo);ji(!i,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:o}=Gt(So),{pathname:a}=To(),s=Ao(),l=po(e,uo(o),a,"path"===r),c=JSON.stringify(l);return Ot((()=>{s(JSON.parse(c),{replace:t,state:n,relative:r})}),[s,c,r,t,n]),null}function Bo(e){return Lo(e.context)}function zo(e){Ui(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function qo({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:i,static:o=!1}){Ui(!Co(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let a=e.replace(/^\/*/,"/"),s=It((()=>({basename:a,navigator:i,static:o,future:{}})),[a,i,o]);"string"==typeof n&&(n=Ki(n));let{pathname:l="/",search:c="",hash:u="",state:d=null,key:p="default"}=n,h=It((()=>{let e=lo(l,a);return null==e?null:{location:{pathname:e,search:c,hash:u,state:d,key:p},navigationType:r}}),[a,l,c,u,d,p,r]);return ji(null!=h,`<Router basename="${a}"> is not able to match the URL "${l}${c}${u}" because it does not start with the basename, so the <Router> won't render anything.`),null==h?null:De(xo.Provider,{value:s},De(ko.Provider,{children:t,value:h}))}function Ko({children:e,location:t}){return Fo(Vo(e),t)}function Vo(e,t=[]){let n=[];return Jn.forEach(e,((e,r)=>{if(!Ar(e))return;let i=[...t,r];if(e.type===$e)return void n.push.apply(n,Vo(e.props.children,i));Ui(e.type===zo,`[${"string"==typeof e.type?e.type:e.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),Ui(!e.props.index||!e.props.children,"An index route cannot have child routes.");let o={id:e.props.id||i.join("-"),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,loader:e.props.loader,action:e.props.action,hydrateFallbackElement:e.props.hydrateFallbackElement,HydrateFallback:e.props.HydrateFallback,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:!0===e.props.hasErrorBoundary||null!=e.props.ErrorBoundary||null!=e.props.errorElement,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(o.children=Vo(e.props.children,i)),n.push(o)})),n}Kn((function({routes:e,future:t,state:n}){return Fo(e,void 0,n,t)}));var Qo="get",Yo="application/x-www-form-urlencoded";function Xo(e){return null!=e&&"string"==typeof e.tagName}var Jo=null;var Zo=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function ea(e){return null==e||Zo.has(e)?e:(ji(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Yo}"`),null)}function ta(e,t){let n,r,i,o,a;if(Xo(s=e)&&"form"===s.tagName.toLowerCase()){let a=e.getAttribute("action");r=a?lo(a,t):null,n=e.getAttribute("method")||Qo,i=ea(e.getAttribute("enctype"))||Yo,o=new FormData(e)}else if(function(e){return Xo(e)&&"button"===e.tagName.toLowerCase()}(e)||function(e){return Xo(e)&&"input"===e.tagName.toLowerCase()}(e)&&("submit"===e.type||"image"===e.type)){let a=e.form;if(null==a)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let s=e.getAttribute("formaction")||a.getAttribute("action");if(r=s?lo(s,t):null,n=e.getAttribute("formmethod")||a.getAttribute("method")||Qo,i=ea(e.getAttribute("formenctype"))||ea(a.getAttribute("enctype"))||Yo,o=new FormData(a,e),!function(){if(null===Jo)try{new FormData(document.createElement("form"),0),Jo=!1}catch(Mc){Jo=!0}return Jo}()){let{name:t,type:n,value:r}=e;if("image"===n){let e=t?`${t}.`:"";o.append(`${e}x`,"0"),o.append(`${e}y`,"0")}else t&&o.append(t,r)}}else{if(Xo(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=Qo,r=null,i=Yo,a=e}var s;return o&&"text/plain"===i&&(a=o,o=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:o,body:a}}function na(e,t){if(!1===e||null==e)throw new Error(t)}function ra(e){return null!=e&&(null==e.href?"preload"===e.rel&&"string"==typeof e.imageSrcSet&&"string"==typeof e.imageSizes:"string"==typeof e.rel&&"string"==typeof e.href)}async function ia(e,t,n){return function(e,t){let n=new Set;return new Set(t),e.reduce(((e,t)=>{let r=JSON.stringify(function(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}(t));return n.has(r)||(n.add(r),e.push({key:r,link:t})),e}),[])}((await Promise.all(e.map((async e=>{let r=t.routes[e.route.id];if(r){let e=await async function(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise((()=>{}))}}(r,n);return e.links?e.links():[]}return[]})))).flat(1).filter(ra).filter((e=>"stylesheet"===e.rel||"preload"===e.rel)).map((e=>"stylesheet"===e.rel?{...e,rel:"prefetch",as:"style"}:{...e,rel:"prefetch"})))}function oa(e,t,n,r,i,o){let a=(e,t)=>!n[t]||e.route.id!==n[t].route.id,s=(e,t)=>{var r;return n[t].pathname!==e.pathname||(null==(r=n[t].route.path)?void 0:r.endsWith("*"))&&n[t].params["*"]!==e.params["*"]};return"assets"===o?t.filter(((e,t)=>a(e,t)||s(e,t))):"data"===o?t.filter(((t,o)=>{var l;let c=r.routes[t.route.id];if(!c||!c.hasLoader)return!1;if(a(t,o)||s(t,o))return!0;if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:(null==(l=n[0])?void 0:l.params)||{},nextUrl:new URL(e,window.origin),nextParams:t.params,defaultShouldRevalidate:!0});if("boolean"==typeof r)return r}return!0})):[]}function aa(e,t){return n=e.map((e=>{let n=t.routes[e.route.id];if(!n)return[];let r=[n.module];return n.imports&&(r=r.concat(n.imports)),r})).flat(1),[...new Set(n)];var n}var sa=at(void 0);function la(){let e=Gt(sa);return na(e,"You must render this element inside a <HydratedRouter> element"),e}function ca(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function ua({page:e,...t}){let{router:n}=function(){let e=Gt(_o);return na(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}(),r=It((()=>Vi(n.routes,e,n.basename)),[n.routes,e,n.basename]);return r?De(da,{page:e,matches:r,...t}):null}function da({page:e,matches:t,...n}){let r=To(),{manifest:i,routeModules:o}=la(),{loaderData:a,matches:s}=function(){let e=Gt(wo);return na(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}(),l=It((()=>oa(e,t,s,i,r,"data")),[e,t,s,i,r]),c=It((()=>oa(e,t,s,i,r,"assets")),[e,t,s,i,r]),u=It((()=>{if(e===r.pathname+r.search+r.hash)return[];let n=new Set,s=!1;if(t.forEach((e=>{var t;let r=i.routes[e.route.id];r&&r.hasLoader&&(!l.some((t=>t.route.id===e.route.id))&&e.route.id in a&&(null==(t=o[e.route.id])?void 0:t.shouldRevalidate)||r.hasClientLoader?s=!0:n.add(e.route.id))})),0===n.size)return[];let c=function(e){let t="string"==typeof e?new URL(e,"undefined"==typeof window?"server://singlefetch/":window.location.origin):e;return"/"===t.pathname?t.pathname="_root.data":t.pathname=`${t.pathname.replace(/\/$/,"")}.data`,t}(e);return s&&n.size>0&&c.searchParams.set("_routes",t.filter((e=>n.has(e.route.id))).map((e=>e.route.id)).join(",")),[c.pathname+c.search]}),[a,r,i,l,t,e,o]),d=It((()=>aa(c,i)),[c,i]),p=function(e){let{manifest:t,routeModules:n}=la(),[r,i]=Rt([]);return Ot((()=>{let r=!1;return ia(e,t,n).then((e=>{r||i(e)})),()=>{r=!0}}),[e,t,n]),r}(c);return De($e,null,u.map((e=>De("link",{key:e,rel:"prefetch",as:"fetch",href:e,...n}))),d.map((e=>De("link",{key:e,rel:"modulepreload",href:e,...n}))),p.map((({key:e,link:t})=>De("link",{key:e,...t}))))}function pa(...e){return t=>{e.forEach((e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)}))}}sa.displayName="FrameworkContext";var ha="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement;try{ha&&(window.__reactRouterVersion="7.1.1")}catch(Mc){}function fa({basename:e,children:t,window:n}){let r=Mt();null==r.current&&(r.current=Wi({window:n,v5Compat:!0}));let i=r.current,[o,a]=Rt({action:i.action,location:i.location}),s=Dt((e=>{$r((()=>a(e)))}),[a]);return Lt((()=>i.listen(s)),[i,s]),De(qo,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:i})}var va=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,ma=Yn((function({onClick:e,discover:t="render",prefetch:n="none",relative:r,reloadDocument:i,replace:o,state:a,target:s,to:l,preventScrollReset:c,viewTransition:u,...d},p){let h,{basename:f}=Gt(xo),v="string"==typeof l&&va.test(l),m=!1;if("string"==typeof l&&v&&(h=l,ha))try{let e=new URL(window.location.href),t=l.startsWith("//")?new URL(e.protocol+l):new URL(l),n=lo(t.pathname,f);t.origin===e.origin&&null!=n?l=n+t.search+t.hash:m=!0}catch(Mc){ji(!1,`<Link to="${l}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let g=function(e,{relative:t}={}){Ui(Co(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=Gt(xo),{hash:i,pathname:o,search:a}=Mo(e,{relative:t}),s=o;return"/"!==n&&(s="/"===o?n:ho([n,o])),r.createHref({pathname:s,search:a,hash:i})}(l,{relative:r}),[y,_,w]=function(e,t){let n=Gt(sa),[r,i]=Rt(!1),[o,a]=Rt(!1),{onFocus:s,onBlur:l,onMouseEnter:c,onMouseLeave:u,onTouchStart:d}=t,p=Mt(null);Ot((()=>{if("render"===e&&a(!0),"viewport"===e){let e=new IntersectionObserver((e=>{e.forEach((e=>{a(e.isIntersecting)}))}),{threshold:.5});return p.current&&e.observe(p.current),()=>{e.disconnect()}}}),[e]),Ot((()=>{if(r){let e=setTimeout((()=>{a(!0)}),100);return()=>{clearTimeout(e)}}}),[r]);let h=()=>{i(!0)},f=()=>{i(!1),a(!1)};return n?"intent"!==e?[o,p,{}]:[o,p,{onFocus:ca(s,h),onBlur:ca(l,f),onMouseEnter:ca(c,h),onMouseLeave:ca(u,f),onTouchStart:ca(d,h)}]:[!1,p,{}]}(n,d),b=function(e,{target:t,replace:n,state:r,preventScrollReset:i,relative:o,viewTransition:a}={}){let s=Ao(),l=To(),c=Mo(e,{relative:o});return Dt((u=>{if(function(e,t){return!(0!==e.button||t&&"_self"!==t||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e))}(u,t)){u.preventDefault();let t=void 0!==n?n:qi(l)===qi(c);s(e,{replace:t,state:r,preventScrollReset:i,relative:o,viewTransition:a})}}),[l,s,c,n,r,t,e,i,o,a])}(l,{replace:o,state:a,target:s,preventScrollReset:c,relative:r,viewTransition:u});let x=De("a",{...d,...w,href:h||g,onClick:m||i?e:function(t){e&&e(t),t.defaultPrevented||b(t)},ref:pa(p,_),target:s,"data-discover":v||"render"!==t?void 0:"true"});return y&&!v?De($e,null,x,De(ua,{page:g})):x}));ma.displayName="Link";var ga=Yn((function({"aria-current":e="page",caseSensitive:t=!1,className:n="",end:r=!1,style:i,to:o,viewTransition:a,children:s,...l},c){let u=Mo(o,{relative:l.relative}),d=To(),p=Gt(wo),{navigator:h,basename:f}=Gt(xo),v=null!=p&&function(e,t={}){let n=Gt(bo);Ui(null!=n,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=ya("useViewTransitionState"),i=Mo(e,{relative:t.relative});if(!n.isTransitioning)return!1;let o=lo(n.currentLocation.pathname,r)||n.currentLocation.pathname,a=lo(n.nextLocation.pathname,r)||n.nextLocation.pathname;return null!=ao(i.pathname,a)||null!=ao(i.pathname,o)}(u)&&!0===a,m=h.encodeLocation?h.encodeLocation(u).pathname:u.pathname,g=d.pathname,y=p&&p.navigation&&p.navigation.location?p.navigation.location.pathname:null;t||(g=g.toLowerCase(),y=y?y.toLowerCase():null,m=m.toLowerCase()),y&&f&&(y=lo(y,f)||y);const _="/"!==m&&m.endsWith("/")?m.length-1:m.length;let w,b=g===m||!r&&g.startsWith(m)&&"/"===g.charAt(_),x=null!=y&&(y===m||!r&&y.startsWith(m)&&"/"===y.charAt(m.length)),k={isActive:b,isPending:x,isTransitioning:v},S=b?e:void 0;w="function"==typeof n?n(k):[n,b?"active":null,x?"pending":null,v?"transitioning":null].filter(Boolean).join(" ");let E="function"==typeof i?i(k):i;return De(ma,{...l,"aria-current":S,className:w,ref:c,style:E,to:o,viewTransition:a},"function"==typeof s?s(k):s)}));function ya(e){let t=Gt(_o);return Ui(t,function(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}(e)),t}ga.displayName="NavLink",Yn((({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:o,method:a=Qo,action:s,onSubmit:l,relative:c,preventScrollReset:u,viewTransition:d,...p},h)=>{let f=function(){let{router:e}=ya("useSubmit"),{basename:t}=Gt(xo),n=Ho("useRouteId");return Dt((async(r,i={})=>{let{action:o,method:a,encType:s,formData:l,body:c}=ta(r,t);if(!1===i.navigate){let t=i.fetcherKey||wa();await e.fetch(t,n,i.action||o,{preventScrollReset:i.preventScrollReset,formData:l,body:c,formMethod:i.method||a,formEncType:i.encType||s,flushSync:i.flushSync})}else await e.navigate(i.action||o,{preventScrollReset:i.preventScrollReset,formData:l,body:c,formMethod:i.method||a,formEncType:i.encType||s,replace:i.replace,state:i.state,fromRouteId:n,flushSync:i.flushSync,viewTransition:i.viewTransition})}),[e,t,n])}(),v=function(e,{relative:t}={}){let{basename:n}=Gt(xo),r=Gt(So);Ui(r,"useFormAction must be used inside a RouteContext");let[i]=r.matches.slice(-1),o={...Mo(e||".",{relative:t})},a=To();if(null==e){o.search=a.search;let e=new URLSearchParams(o.search),t=e.getAll("index");if(t.some((e=>""===e))){e.delete("index"),t.filter((e=>e)).forEach((t=>e.append("index",t)));let n=e.toString();o.search=n?`?${n}`:""}}e&&"."!==e||!i.route.index||(o.search=o.search?o.search.replace(/^\?/,"?index&"):"?index");"/"!==n&&(o.pathname="/"===o.pathname?n:ho([n,o.pathname]));return qi(o)}(s,{relative:c}),m="get"===a.toLowerCase()?"get":"post",g="string"==typeof s&&va.test(s);return De("form",{ref:h,method:m,action:v,onSubmit:r?l:e=>{if(l&&l(e),e.defaultPrevented)return;e.preventDefault();let r=e.nativeEvent.submitter,s=(null==r?void 0:r.getAttribute("formmethod"))||a;f(r||e.currentTarget,{fetcherKey:t,method:s,navigate:n,replace:i,state:o,relative:c,preventScrollReset:u,viewTransition:d})},...p,"data-discover":g||"render"!==e?void 0:"true"})})).displayName="Form";var _a=0,wa=()=>`__${String(++_a)}__`;function ba(){return ba=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ba.apply(null,arguments)}new TextEncoder;var xa=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(t);try{n.insertRule(e,n.cssRules.length)}catch(Mc){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach((function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)})),this.tags=[],this.ctr=0},e}(),ka="-ms-",Sa="-moz-",Ea="-webkit-",Ca="comm",Ta="rule",Pa="decl",Ra="@keyframes",Aa=Math.abs,Oa=String.fromCharCode,La=Object.assign;function Ma(e){return e.trim()}function Fa(e,t,n){return e.replace(t,n)}function Ia(e,t){return e.indexOf(t)}function Da(e,t){return 0|e.charCodeAt(t)}function Ga(e,t,n){return e.slice(t,n)}function Na(e){return e.length}function $a(e){return e.length}function Ha(e,t){return t.push(e),e}var Wa=1,Ua=1,ja=0,Ba=0,za=0,qa="";function Ka(e,t,n,r,i,o,a){return{value:e,root:t,parent:n,type:r,props:i,children:o,line:Wa,column:Ua,length:a,return:""}}function Va(e,t){return La(Ka("",null,null,"",null,null,0),e,{length:-e.length},t)}function Qa(){return za=Ba<ja?Da(qa,Ba++):0,Ua++,10===za&&(Ua=1,Wa++),za}function Ya(){return Da(qa,Ba)}function Xa(){return Ba}function Ja(e,t){return Ga(qa,e,t)}function Za(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function es(e){return Wa=Ua=1,ja=Na(qa=e),Ba=0,[]}function ts(e){return qa="",e}function ns(e){return Ma(Ja(Ba-1,os(91===e?e+2:40===e?e+1:e)))}function rs(e){for(;(za=Ya())&&za<33;)Qa();return Za(e)>2||Za(za)>3?"":" "}function is(e,t){for(;--t&&Qa()&&!(za<48||za>102||za>57&&za<65||za>70&&za<97););return Ja(e,Xa()+(t<6&&32==Ya()&&32==Qa()))}function os(e){for(;Qa();)switch(za){case e:return Ba;case 34:case 39:34!==e&&39!==e&&os(za);break;case 40:41===e&&os(e);break;case 92:Qa()}return Ba}function as(e,t){for(;Qa()&&e+za!==57&&(e+za!==84||47!==Ya()););return"/*"+Ja(t,Ba-1)+"*"+Oa(47===e?e:Qa())}function ss(e){for(;!Za(Ya());)Qa();return Ja(e,Ba)}function ls(e){return ts(cs("",null,null,null,[""],e=es(e),0,[0],e))}function cs(e,t,n,r,i,o,a,s,l){for(var c=0,u=0,d=a,p=0,h=0,f=0,v=1,m=1,g=1,y=0,_="",w=i,b=o,x=r,k=_;m;)switch(f=y,y=Qa()){case 40:if(108!=f&&58==Da(k,d-1)){-1!=Ia(k+=Fa(ns(y),"&","&\f"),"&\f")&&(g=-1);break}case 34:case 39:case 91:k+=ns(y);break;case 9:case 10:case 13:case 32:k+=rs(f);break;case 92:k+=is(Xa()-1,7);continue;case 47:switch(Ya()){case 42:case 47:Ha(ds(as(Qa(),Xa()),t,n),l);break;default:k+="/"}break;case 123*v:s[c++]=Na(k)*g;case 125*v:case 59:case 0:switch(y){case 0:case 125:m=0;case 59+u:-1==g&&(k=Fa(k,/\f/g,"")),h>0&&Na(k)-d&&Ha(h>32?ps(k+";",r,n,d-1):ps(Fa(k," ","")+";",r,n,d-2),l);break;case 59:k+=";";default:if(Ha(x=us(k,t,n,c,u,i,s,_,w=[],b=[],d),o),123===y)if(0===u)cs(k,t,x,x,w,o,d,s,b);else switch(99===p&&110===Da(k,3)?100:p){case 100:case 108:case 109:case 115:cs(e,x,x,r&&Ha(us(e,x,x,0,0,i,s,_,i,w=[],d),b),i,b,d,s,r?w:b);break;default:cs(k,x,x,x,[""],b,0,s,b)}}c=u=h=0,v=g=1,_=k="",d=a;break;case 58:d=1+Na(k),h=f;default:if(v<1)if(123==y)--v;else if(125==y&&0==v++&&125==(za=Ba>0?Da(qa,--Ba):0,Ua--,10===za&&(Ua=1,Wa--),za))continue;switch(k+=Oa(y),y*v){case 38:g=u>0?1:(k+="\f",-1);break;case 44:s[c++]=(Na(k)-1)*g,g=1;break;case 64:45===Ya()&&(k+=ns(Qa())),p=Ya(),u=d=Na(_=k+=ss(Xa())),y++;break;case 45:45===f&&2==Na(k)&&(v=0)}}return o}function us(e,t,n,r,i,o,a,s,l,c,u){for(var d=i-1,p=0===i?o:[""],h=$a(p),f=0,v=0,m=0;f<r;++f)for(var g=0,y=Ga(e,d+1,d=Aa(v=a[f])),_=e;g<h;++g)(_=Ma(v>0?p[g]+" "+y:Fa(y,/&\f/g,p[g])))&&(l[m++]=_);return Ka(e,t,n,0===i?Ta:s,l,c,u)}function ds(e,t,n){return Ka(e,t,n,Ca,Oa(za),Ga(e,2,-2),0)}function ps(e,t,n,r){return Ka(e,t,n,Pa,Ga(e,0,r),Ga(e,r+1,-1),r)}function hs(e,t){for(var n="",r=$a(e),i=0;i<r;i++)n+=t(e[i],i,e,t)||"";return n}function fs(e,t,n,r){switch(e.type){case"@layer":if(e.children.length)break;case"@import":case Pa:return e.return=e.return||e.value;case Ca:return"";case Ra:return e.return=e.value+"{"+hs(e.children,r)+"}";case Ta:e.value=e.props.join(",")}return Na(n=hs(e.children,r))?e.return=e.value+"{"+n+"}":""}function vs(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}var ms=function(e,t,n){for(var r=0,i=0;r=i,i=Ya(),38===r&&12===i&&(t[n]=1),!Za(i);)Qa();return Ja(e,Ba)},gs=function(e,t){return ts(function(e,t){var n=-1,r=44;do{switch(Za(r)){case 0:38===r&&12===Ya()&&(t[n]=1),e[n]+=ms(Ba-1,t,n);break;case 2:e[n]+=ns(r);break;case 4:if(44===r){e[++n]=58===Ya()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=Oa(r)}}while(r=Qa());return e}(es(e),t))},ys=new WeakMap,_s=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||ys.get(n))&&!r){ys.set(e,!0);for(var i=[],o=gs(t,i),a=n.props,s=0,l=0;s<o.length;s++)for(var c=0;c<a.length;c++,l++)e.props[l]=i[s]?o[s].replace(/&\f/g,a[c]):a[c]+" "+o[s]}}},ws=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function bs(e,t){switch(function(e,t){return 45^Da(e,0)?(((t<<2^Da(e,0))<<2^Da(e,1))<<2^Da(e,2))<<2^Da(e,3):0}(e,t)){case 5103:return Ea+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Ea+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Ea+e+Sa+e+ka+e+e;case 6828:case 4268:return Ea+e+ka+e+e;case 6165:return Ea+e+ka+"flex-"+e+e;case 5187:return Ea+e+Fa(e,/(\w+).+(:[^]+)/,Ea+"box-$1$2"+ka+"flex-$1$2")+e;case 5443:return Ea+e+ka+"flex-item-"+Fa(e,/flex-|-self/,"")+e;case 4675:return Ea+e+ka+"flex-line-pack"+Fa(e,/align-content|flex-|-self/,"")+e;case 5548:return Ea+e+ka+Fa(e,"shrink","negative")+e;case 5292:return Ea+e+ka+Fa(e,"basis","preferred-size")+e;case 6060:return Ea+"box-"+Fa(e,"-grow","")+Ea+e+ka+Fa(e,"grow","positive")+e;case 4554:return Ea+Fa(e,/([^-])(transform)/g,"$1"+Ea+"$2")+e;case 6187:return Fa(Fa(Fa(e,/(zoom-|grab)/,Ea+"$1"),/(image-set)/,Ea+"$1"),e,"")+e;case 5495:case 3959:return Fa(e,/(image-set\([^]*)/,Ea+"$1$`$1");case 4968:return Fa(Fa(e,/(.+:)(flex-)?(.*)/,Ea+"box-pack:$3"+ka+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Ea+e+e;case 4095:case 3583:case 4068:case 2532:return Fa(e,/(.+)-inline(.+)/,Ea+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Na(e)-1-t>6)switch(Da(e,t+1)){case 109:if(45!==Da(e,t+4))break;case 102:return Fa(e,/(.+:)(.+)-([^]+)/,"$1"+Ea+"$2-$3$1"+Sa+(108==Da(e,t+3)?"$3":"$2-$3"))+e;case 115:return~Ia(e,"stretch")?bs(Fa(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==Da(e,t+1))break;case 6444:switch(Da(e,Na(e)-3-(~Ia(e,"!important")&&10))){case 107:return Fa(e,":",":"+Ea)+e;case 101:return Fa(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Ea+(45===Da(e,14)?"inline-":"")+"box$3$1"+Ea+"$2$3$1"+ka+"$2box$3")+e}break;case 5936:switch(Da(e,t+11)){case 114:return Ea+e+ka+Fa(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Ea+e+ka+Fa(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Ea+e+ka+Fa(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Ea+e+ka+e+e}return e}var xs=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case Pa:e.return=bs(e.value,e.length);break;case Ra:return hs([Va(e,{value:Fa(e.value,"@","@"+Ea)})],r);case Ta:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(function(e,t){return(e=t.exec(e))?e[0]:e}(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return hs([Va(e,{props:[Fa(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return hs([Va(e,{props:[Fa(t,/:(plac\w+)/,":"+Ea+"input-$1")]}),Va(e,{props:[Fa(t,/:(plac\w+)/,":-moz-$1")]}),Va(e,{props:[Fa(t,/:(plac\w+)/,ka+"input-$1")]})],r)}return""}))}}],ks=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var r,i,o=e.stylisPlugins||xs,a={},s=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n<t.length;n++)a[t[n]]=!0;s.push(e)}));var l,c,u,d,p=[fs,(d=function(e){l.insert(e)},function(e){e.root||(e=e.return)&&d(e)})],h=(c=[_s,ws].concat(o,p),u=$a(c),function(e,t,n,r){for(var i="",o=0;o<u;o++)i+=c[o](e,t,n,r)||"";return i});i=function(e,t,n,r){l=n,hs(ls(e?e+"{"+t.styles+"}":t.styles),h),r&&(f.inserted[t.name]=!0)};var f={key:t,sheet:new xa({key:t,container:r,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:a,registered:{},insert:i};return f.sheet.hydrate(s),f},Ss={exports:{}},Es={},Cs="function"==typeof Symbol&&Symbol.for,Ts=Cs?Symbol.for("react.element"):60103,Ps=Cs?Symbol.for("react.portal"):60106,Rs=Cs?Symbol.for("react.fragment"):60107,As=Cs?Symbol.for("react.strict_mode"):60108,Os=Cs?Symbol.for("react.profiler"):60114,Ls=Cs?Symbol.for("react.provider"):60109,Ms=Cs?Symbol.for("react.context"):60110,Fs=Cs?Symbol.for("react.async_mode"):60111,Is=Cs?Symbol.for("react.concurrent_mode"):60111,Ds=Cs?Symbol.for("react.forward_ref"):60112,Gs=Cs?Symbol.for("react.suspense"):60113,Ns=Cs?Symbol.for("react.suspense_list"):60120,$s=Cs?Symbol.for("react.memo"):60115,Hs=Cs?Symbol.for("react.lazy"):60116,Ws=Cs?Symbol.for("react.block"):60121,Us=Cs?Symbol.for("react.fundamental"):60117,js=Cs?Symbol.for("react.responder"):60118,Bs=Cs?Symbol.for("react.scope"):60119;function zs(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case Ts:switch(e=e.type){case Fs:case Is:case Rs:case Os:case As:case Gs:return e;default:switch(e=e&&e.$$typeof){case Ms:case Ds:case Hs:case $s:case Ls:return e;default:return t}}case Ps:return t}}}function qs(e){return zs(e)===Is}Es.AsyncMode=Fs,Es.ConcurrentMode=Is,Es.ContextConsumer=Ms,Es.ContextProvider=Ls,Es.Element=Ts,Es.ForwardRef=Ds,Es.Fragment=Rs,Es.Lazy=Hs,Es.Memo=$s,Es.Portal=Ps,Es.Profiler=Os,Es.StrictMode=As,Es.Suspense=Gs,Es.isAsyncMode=function(e){return qs(e)||zs(e)===Fs},Es.isConcurrentMode=qs,Es.isContextConsumer=function(e){return zs(e)===Ms},Es.isContextProvider=function(e){return zs(e)===Ls},Es.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===Ts},Es.isForwardRef=function(e){return zs(e)===Ds},Es.isFragment=function(e){return zs(e)===Rs},Es.isLazy=function(e){return zs(e)===Hs},Es.isMemo=function(e){return zs(e)===$s},Es.isPortal=function(e){return zs(e)===Ps},Es.isProfiler=function(e){return zs(e)===Os},Es.isStrictMode=function(e){return zs(e)===As},Es.isSuspense=function(e){return zs(e)===Gs},Es.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===Rs||e===Is||e===Os||e===As||e===Gs||e===Ns||"object"==typeof e&&null!==e&&(e.$$typeof===Hs||e.$$typeof===$s||e.$$typeof===Ls||e.$$typeof===Ms||e.$$typeof===Ds||e.$$typeof===Us||e.$$typeof===js||e.$$typeof===Bs||e.$$typeof===Ws)},Es.typeOf=zs,Ss.exports=Es;var Ks=Ss.exports,Vs={};Vs[Ks.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Vs[Ks.Memo]={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0};function Qs(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]+";"):n&&(r+=n+" ")})),r}var Ys=function(e,t,n){var r=e.key+"-"+t.name;!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},Xs=function(e,t,n){Ys(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var i=t;do{e.insert(t===i?"."+r:"",i,e.sheet,!0),i=i.next}while(void 0!==i)}};var Js={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Zs=/[A-Z]|^ms/g,el=/_EMO_([^_]+?)_([^]*?)_EMO_/g,tl=function(e){return 45===e.charCodeAt(1)},nl=function(e){return null!=e&&"boolean"!=typeof e},rl=vs((function(e){return tl(e)?e:e.replace(Zs,"-$&").toLowerCase()})),il=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(el,(function(e,t,n){return al={name:t,styles:n,next:al},t}))}return 1===Js[e]||tl(e)||"number"!=typeof t||0===t?t:t+"px"};function ol(e,t,n){if(null==n)return"";var r=n;if(void 0!==r.__emotion_styles)return r;switch(typeof n){case"boolean":return"";case"object":var i=n;if(1===i.anim)return al={name:i.name,styles:i.styles,next:al},i.name;var o=n;if(void 0!==o.styles){var a=o.next;if(void 0!==a)for(;void 0!==a;)al={name:a.name,styles:a.styles,next:al},a=a.next;return o.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i<n.length;i++)r+=ol(e,t,n[i])+";";else for(var o in n){var a=n[o];if("object"!=typeof a){var s=a;null!=t&&void 0!==t[s]?r+=o+"{"+t[s]+"}":nl(s)&&(r+=rl(o)+":"+il(o,s)+";")}else if(!Array.isArray(a)||"string"!=typeof a[0]||null!=t&&void 0!==t[a[0]]){var l=ol(e,t,a);switch(o){case"animation":case"animationName":r+=rl(o)+":"+l+";";break;default:r+=o+"{"+l+"}"}}else for(var c=0;c<a.length;c++)nl(a[c])&&(r+=rl(o)+":"+il(o,a[c])+";")}return r}(e,t,n);case"function":if(void 0!==e){var s=al,l=n(e);return al=s,ol(e,t,l)}}var c=n;if(null==t)return c;var u=t[c];return void 0!==u?u:c}var al,sl=/label:\s*([^\s;{]+)\s*(;|$)/g;function ll(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,i="";al=void 0;var o=e[0];null==o||void 0===o.raw?(r=!1,i+=ol(n,t,o)):i+=o[0];for(var a=1;a<e.length;a++){if(i+=ol(n,t,e[a]),r)i+=o[a]}sl.lastIndex=0;for(var s,l="";null!==(s=sl.exec(i));)l+="-"+s[1];var c=function(e){for(var t,n=0,r=0,i=e.length;i>=4;++r,i-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(i){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(i)+l;return{name:c,styles:i,next:al}}var cl,ul,dl=!!Kr.useInsertionEffect&&Kr.useInsertionEffect,pl=dl||function(e){return e()},hl=dl||Lt,fl=at("undefined"!=typeof HTMLElement?ks({key:"css"}):null),vl=fl.Provider,ml=function(e){return Yn((function(t,n){var r=Gt(fl);return e(t,r,n)}))},gl=at({}),yl={}.hasOwnProperty,_l="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",wl=function(e,t){var n={};for(var r in t)yl.call(t,r)&&(n[r]=t[r]);return n[_l]=e,n},bl=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return Ys(t,n,r),pl((function(){return Xs(t,n,r)})),null},xl=ml((function(e,t,n){var r=e.css;"string"==typeof r&&void 0!==t.registered[r]&&(r=t.registered[r]);var i=e[_l],o=[r],a="";"string"==typeof e.className?a=Qs(t.registered,o,e.className):null!=e.className&&(a=e.className+" ");var s=ll(o,void 0,Gt(gl));a+=t.key+"-"+s.name;var l={};for(var c in e)yl.call(e,c)&&"css"!==c&&c!==_l&&(l[c]=e[c]);return l.className=a,n&&(l.ref=n),De($e,null,De(bl,{cache:t,serialized:s,isStringTag:"string"==typeof i}),De(i,l))})),kl=function(e,t){var n=arguments;if(null==t||!yl.call(t,"css"))return De.apply(void 0,n);var r=n.length,i=new Array(r);i[0]=xl,i[1]=wl(e,t);for(var o=2;o<r;o++)i[o]=n[o];return De.apply(null,i)};cl=kl||(kl={}),ul||(ul=cl.JSX||(cl.JSX={}));var Sl=ml((function(e,t){var n=ll([e.styles],void 0,Gt(gl)),r=Mt();return hl((function(){var e=t.key+"-global",i=new t.sheet.constructor({key:e,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),o=!1,a=document.querySelector('style[data-emotion="'+e+" "+n.name+'"]');return t.sheet.tags.length&&(i.before=t.sheet.tags[0]),null!==a&&(o=!0,a.setAttribute("data-emotion",e),i.hydrate([a])),r.current=[i,o],function(){i.flush()}}),[t]),hl((function(){var e=r.current,i=e[0];if(e[1])e[1]=!1;else{if(void 0!==n.next&&Xs(t,n.next,!0),i.tags.length){var o=i.tags[i.tags.length-1].nextElementSibling;i.before=o,i.flush()}t.insert("",n,i,!1)}}),[t,n.name]),null}));function El(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return ll(t)}var Cl=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Tl=vs((function(e){return Cl.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91})),Pl=function(e){return"theme"!==e},Rl=function(e){return"string"==typeof e&&e.charCodeAt(0)>96?Tl:Pl},Al=function(e,t,n){var r;if(t){var i=t.shouldForwardProp;r=e.__emotion_forwardProp&&i?function(t){return e.__emotion_forwardProp(t)&&i(t)}:i}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},Ol=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return Ys(t,n,r),pl((function(){return Xs(t,n,r)})),null},Ll=function e(t,n){var r,i,o=t.__emotion_real===t,a=o&&t.__emotion_base||t;void 0!==n&&(r=n.label,i=n.target);var s=Al(t,n,o),l=s||Rl(a),c=!l("as");return function(){var u=arguments,d=o&&void 0!==t.__emotion_styles?t.__emotion_styles.slice(0):[];if(void 0!==r&&d.push("label:"+r+";"),null==u[0]||void 0===u[0].raw)d.push.apply(d,u);else{var p=u[0];d.push(p[0]);for(var h=u.length,f=1;f<h;f++)d.push(u[f],p[f])}var v=ml((function(e,t,n){var r=c&&e.as||a,o="",u=[],p=e;if(null==e.theme){for(var h in p={},e)p[h]=e[h];p.theme=Gt(gl)}"string"==typeof e.className?o=Qs(t.registered,u,e.className):null!=e.className&&(o=e.className+" ");var f=ll(d.concat(u),t.registered,p);o+=t.key+"-"+f.name,void 0!==i&&(o+=" "+i);var v=c&&void 0===s?Rl(r):l,m={};for(var g in e)c&&"as"===g||v(g)&&(m[g]=e[g]);return m.className=o,n&&(m.ref=n),De($e,null,De(Ol,{cache:t,serialized:f,isStringTag:"string"==typeof r}),De(r,m))}));return v.displayName=void 0!==r?r:"Styled("+("string"==typeof a?a:a.displayName||a.name||"Component")+")",v.defaultProps=t.defaultProps,v.__emotion_real=v,v.__emotion_base=a,v.__emotion_styles=d,v.__emotion_forwardProp=s,Object.defineProperty(v,"toString",{value:function(){return"."+i}}),v.withComponent=function(t,r){return e(t,ba({},n,r,{shouldForwardProp:Al(v,r,!0)})).apply(void 0,d)},v}}.bind(null);["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"].forEach((function(e){Ll[e]=Ll(e)}));const Ml=Ll.span({whiteSpace:"nowrap",borderBottomWidth:"2px",paddingLeft:"0.25rem",paddingRight:"0.25rem",paddingTop:"1rem",paddingBottom:"1rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500"},(({isActive:e})=>e?{cursor:"default","--tw-border-opacity":"1",borderColor:"rgb(99 102 241 / var(--tw-border-opacity))","--tw-text-opacity":"1",color:"rgb(79 70 229 / var(--tw-text-opacity))"}:{cursor:"pointer",borderColor:"transparent","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))",":hover":{"--tw-border-opacity":"1",borderColor:"rgb(209 213 219 / var(--tw-border-opacity))","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"}})),Fl=Ll.span({marginLeft:"0.25rem",display:"inline-flex",width:"1.25rem",alignItems:"center",justifyContent:"center",borderRadius:"9999px",fontFamily:'ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace',fontWeight:"700","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))"},(({isActive:e})=>e?{"--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))"}:{"--tw-bg-opacity":"1",backgroundColor:"rgb(107 114 128 / var(--tw-bg-opacity))",".group:hover &":{"--tw-bg-opacity":"1",backgroundColor:"rgb(55 65 81 / var(--tw-bg-opacity))"}}));var Il=$e,Dl=function(e,t,n){return yl.call(t,"css")?Qr(xl,wl(e,t),n):Qr(e,t,n)},Gl=function(e,t,n){return yl.call(t,"css")?Qr(xl,wl(e,t),n):Qr(e,t,n)};const Nl=({tabs:e})=>Dl("div",{css:{display:"block"},children:Dl("div",{css:{borderBottomWidth:"1px","--tw-border-opacity":"1",borderColor:"rgb(229 231 235 / var(--tw-border-opacity))",paddingBottom:"1rem"},children:Dl("nav",{"aria-label":"Tabs",css:{marginBottom:"-2px",display:"flex","> :not([hidden]) ~ :not([hidden])":{"--tw-space-x-reverse":"0",marginRight:"calc(2rem * var(--tw-space-x-reverse))",marginLeft:"calc(2rem * calc(1 - var(--tw-space-x-reverse)))"},paddingTop:"1rem"},children:e.map((e=>Dl(ga,{to:e.id,children:({isActive:t})=>Gl(Ml,{className:"group",isActive:t,children:[e.displayName,void 0!==e.count&&Dl(Fl,{isActive:t,children:e.count})]})},e.id)))})})}),$l=e=>{var t,n;const{linkedProfilesForAccount:r,checkProfileSearchAuthorization:i,linkedAccount:o}=Ri(),a=oi({queryKey:[hi],queryFn:o}),s=oi({queryKey:[fi],queryFn:r}),l=oi({queryKey:[mi],queryFn:i});Ot((()=>{l.error&&e.onError(l.error.message),s.error&&e.onError(s.error.message)}),[l.error,s.error,e]);const c=It((()=>{var e;return[{id:"search",displayName:"Search"},{id:"profiles",displayName:"Linked Profiles",count:null==(e=s.data)?void 0:e.length},{id:"invoices",displayName:"Invoices"}]}),[s.data]);return l.isSuccess&&"Linked"!==l.data.status?Dl(jo,{to:"unlinked",replace:!0}):l.isSuccess?Gl("div",{children:[Gl("dl",{css:{marginLeft:"0.25rem",paddingTop:"1rem"},children:[Gl("div",{css:{display:"flex",gap:"0.5rem"},children:[Dl("dt",{css:{width:"5rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:"Account"}),Dl("dd",{css:{marginLeft:"-1px",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"},children:null==(t=a.data)?void 0:t.id})]}),Gl("div",{css:{display:"flex",gap:"0.5rem"},children:[Dl("dt",{css:{width:"5rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:"Client"}),Dl("dd",{css:{marginLeft:"-1px",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"},children:null==(n=a.data)?void 0:n.catchEClientId})]})]}),Dl(Nl,{tabs:c}),Dl("div",{css:{marginLeft:"1rem",marginTop:"1rem"},children:Dl(Bo,{})})]}):Dl("div",{children:"Loading..."})},Hl=e=>Dl(Wh,{children:Dl("button",{as:"button",onClick:()=>e.onClick(e.id),css:{display:"inline-flex",alignItems:"center",fill:"var(--fl-color-primary-600)",paddingLeft:"0.25rem",paddingRight:"0.25rem"},children:e.children})}),Wl=e=>Dl(Hh,{children:Dl("ul",{css:{listStyleType:"none"},children:e.value.split(",").map((t=>Dl("li",{children:e.navTo?Dl(ga,{css:{"--tw-text-opacity":"1",color:"rgb(79 70 229 / var(--tw-text-opacity))",textDecorationLine:"underline"},to:e.navTo,children:t}):t},t)))})}),Ul="undefined"!=typeof document?qr.useLayoutEffect:()=>{};const jl=e=>{var t;return null!==(t=null==e?void 0:e.ownerDocument)&&void 0!==t?t:document},Bl=e=>{if(e&&"window"in e&&e.window===e)return e;return jl(e).defaultView||window};function zl(e){let t=null;return()=>(null==t&&(t=e()),t)}const ql=zl((function(){return e=/^Mac/i,"undefined"!=typeof window&&null!=window.navigator&&e.test((null===(t=window.navigator.userAgentData)||void 0===t?void 0:t.platform)||window.navigator.platform);var e,t})),Kl=zl((function(){return e=/Android/i,"undefined"!=typeof window&&null!=window.navigator&&((null===(t=window.navigator.userAgentData)||void 0===t?void 0:t.brands.some((t=>e.test(t.brand))))||e.test(window.navigator.userAgent));var e,t}));class Vl{isDefaultPrevented(){return this.nativeEvent.defaultPrevented}preventDefault(){this.defaultPrevented=!0,this.nativeEvent.preventDefault()}stopPropagation(){this.nativeEvent.stopPropagation(),this.isPropagationStopped=()=>!0}isPropagationStopped(){return!1}persist(){}constructor(e,t){this.nativeEvent=t,this.target=t.target,this.currentTarget=t.currentTarget,this.relatedTarget=t.relatedTarget,this.bubbles=t.bubbles,this.cancelable=t.cancelable,this.defaultPrevented=t.defaultPrevented,this.eventPhase=t.eventPhase,this.isTrusted=t.isTrusted,this.timeStamp=t.timeStamp,this.type=e}}function Ql(e){let t=Mt({isFocused:!1,observer:null});Ul((()=>{const e=t.current;return()=>{e.observer&&(e.observer.disconnect(),e.observer=null)}}),[]);let n=function(e){const t=Mt(null);return Ul((()=>{t.current=e}),[e]),Dt(((...e)=>{const n=t.current;return null==n?void 0:n(...e)}),[])}((t=>{null==e||e(t)}));return Dt((e=>{if(e.target instanceof HTMLButtonElement||e.target instanceof HTMLInputElement||e.target instanceof HTMLTextAreaElement||e.target instanceof HTMLSelectElement){t.current.isFocused=!0;let r=e.target,i=e=>{t.current.isFocused=!1,r.disabled&&n(new Vl("blur",e)),t.current.observer&&(t.current.observer.disconnect(),t.current.observer=null)};r.addEventListener("focusout",i,{once:!0}),t.current.observer=new MutationObserver((()=>{if(t.current.isFocused&&r.disabled){var e;null===(e=t.current.observer)||void 0===e||e.disconnect();let n=r===document.activeElement?null:document.activeElement;r.dispatchEvent(new FocusEvent("blur",{relatedTarget:n})),r.dispatchEvent(new FocusEvent("focusout",{bubbles:!0,relatedTarget:n}))}})),t.current.observer.observe(r,{attributes:!0,attributeFilter:["disabled"]})}}),[n])}let Yl=null,Xl=new Set,Jl=new Map,Zl=!1,ec=!1;const tc={Tab:!0,Escape:!0};function nc(e,t){for(let n of Xl)n(e,t)}function rc(e){Zl=!0,function(e){return!(e.metaKey||!ql()&&e.altKey||e.ctrlKey||"Control"===e.key||"Shift"===e.key||"Meta"===e.key)}(e)&&(Yl="keyboard",nc("keyboard",e))}function ic(e){Yl="pointer","mousedown"!==e.type&&"pointerdown"!==e.type||(Zl=!0,nc("pointer",e))}function oc(e){var t;(0===(t=e).mozInputSource&&t.isTrusted||(Kl()&&t.pointerType?"click"===t.type&&1===t.buttons:0===t.detail&&!t.pointerType))&&(Zl=!0,Yl="virtual")}function ac(e){e.target!==window&&e.target!==document&&(Zl||ec||(Yl="virtual",nc("virtual",e)),Zl=!1,ec=!1)}function sc(){Zl=!1,ec=!0}function lc(e){if("undefined"==typeof window||Jl.get(Bl(e)))return;const t=Bl(e),n=jl(e);let r=t.HTMLElement.prototype.focus;t.HTMLElement.prototype.focus=function(){Zl=!0,r.apply(this,arguments)},n.addEventListener("keydown",rc,!0),n.addEventListener("keyup",rc,!0),n.addEventListener("click",oc,!0),t.addEventListener("focus",ac,!0),t.addEventListener("blur",sc,!1),"undefined"!=typeof PointerEvent?(n.addEventListener("pointerdown",ic,!0),n.addEventListener("pointermove",ic,!0),n.addEventListener("pointerup",ic,!0)):(n.addEventListener("mousedown",ic,!0),n.addEventListener("mousemove",ic,!0),n.addEventListener("mouseup",ic,!0)),t.addEventListener("beforeunload",(()=>{cc(e)}),{once:!0}),Jl.set(t,{focus:r})}const cc=(e,t)=>{const n=Bl(e),r=jl(e);t&&r.removeEventListener("DOMContentLoaded",t),Jl.has(n)&&(n.HTMLElement.prototype.focus=Jl.get(n).focus,r.removeEventListener("keydown",rc,!0),r.removeEventListener("keyup",rc,!0),r.removeEventListener("click",oc,!0),n.removeEventListener("focus",ac,!0),n.removeEventListener("blur",sc,!1),"undefined"!=typeof PointerEvent?(r.removeEventListener("pointerdown",ic,!0),r.removeEventListener("pointermove",ic,!0),r.removeEventListener("pointerup",ic,!0)):(r.removeEventListener("mousedown",ic,!0),r.removeEventListener("mousemove",ic,!0),r.removeEventListener("mouseup",ic,!0)),Jl.delete(n))};function uc(){return"pointer"!==Yl}"undefined"!=typeof document&&function(e){const t=jl(e);let n;"loading"!==t.readyState?lc(e):(n=()=>{lc(e)},t.addEventListener("DOMContentLoaded",n))}();const dc=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function pc(e,t,n){lc(),Ot((()=>{let t=(t,r)=>{(function(e,t,n){var r;const i="undefined"!=typeof window?Bl(null==n?void 0:n.target).HTMLInputElement:HTMLInputElement,o="undefined"!=typeof window?Bl(null==n?void 0:n.target).HTMLTextAreaElement:HTMLTextAreaElement,a="undefined"!=typeof window?Bl(null==n?void 0:n.target).HTMLElement:HTMLElement,s="undefined"!=typeof window?Bl(null==n?void 0:n.target).KeyboardEvent:KeyboardEvent;return!((e=e||(null==n?void 0:n.target)instanceof i&&!dc.has(null==n||null===(r=n.target)||void 0===r?void 0:r.type)||(null==n?void 0:n.target)instanceof o||(null==n?void 0:n.target)instanceof a&&(null==n?void 0:n.target.isContentEditable))&&"keyboard"===t&&n instanceof s&&!tc[n.key])})(!!(null==n?void 0:n.isTextInput),t,r)&&e(uc())};return Xl.add(t),()=>{Xl.delete(t)}}),t)}let hc=!1,fc=0;function vc(){hc=!0,setTimeout((()=>{hc=!1}),50)}function mc(e){"touch"===e.pointerType&&vc()}function gc(){if("undefined"!=typeof document)return"undefined"!=typeof PointerEvent?document.addEventListener("pointerup",mc):document.addEventListener("touchend",vc),fc++,()=>{fc--,fc>0||("undefined"!=typeof PointerEvent?document.removeEventListener("pointerup",mc):document.removeEventListener("touchend",vc))}}function yc(e={}){let{autoFocus:t=!1,isTextInput:n,within:r}=e,i=Mt({isFocused:!1,isFocusVisible:t||uc()}),[o,a]=Rt(!1),[s,l]=Rt((()=>i.current.isFocused&&i.current.isFocusVisible)),c=Dt((()=>l(i.current.isFocused&&i.current.isFocusVisible)),[]),u=Dt((e=>{i.current.isFocused=e,a(e),c()}),[c]);pc((e=>{i.current.isFocusVisible=e,c()}),[],{isTextInput:n});let{focusProps:d}=function(e){let{isDisabled:t,onFocus:n,onBlur:r,onFocusChange:i}=e;const o=Dt((e=>{if(e.target===e.currentTarget)return r&&r(e),i&&i(!1),!0}),[r,i]),a=Ql(o),s=Dt((e=>{const t=jl(e.target);e.target===e.currentTarget&&t.activeElement===e.target&&(n&&n(e),i&&i(!0),a(e))}),[i,n,a]);return{focusProps:{onFocus:!t&&(n||i||r)?s:void 0,onBlur:t||!r&&!i?void 0:o}}}({isDisabled:r,onFocusChange:u}),{focusWithinProps:p}=function(e){let{isDisabled:t,onBlurWithin:n,onFocusWithin:r,onFocusWithinChange:i}=e,o=Mt({isFocusWithin:!1}),a=Dt((e=>{o.current.isFocusWithin&&!e.currentTarget.contains(e.relatedTarget)&&(o.current.isFocusWithin=!1,n&&n(e),i&&i(!1))}),[n,i,o]),s=Ql(a),l=Dt((e=>{o.current.isFocusWithin||document.activeElement!==e.target||(r&&r(e),i&&i(!0),o.current.isFocusWithin=!0,s(e))}),[r,i,s]);return t?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:l,onBlur:a}}}({isDisabled:!r,onFocusWithinChange:u});return{isFocused:o,isFocusVisible:s,focusProps:r?p:d}}var _c=Object.defineProperty,wc=(e,t,n)=>(((e,t,n)=>{t in e?_c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);let bc=new class{constructor(){wc(this,"current",this.detect()),wc(this,"handoffState","pending"),wc(this,"currentId",0)}set(e){this.current!==e&&(this.handoffState="pending",this.currentId=0,this.current=e)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return"server"===this.current}get isClient(){return"client"===this.current}detect(){return"undefined"==typeof window||"undefined"==typeof document?"server":"client"}handoff(){"pending"===this.handoffState&&(this.handoffState="complete")}get isHandoffComplete(){return"complete"===this.handoffState}};function xc(e){return bc.isServer?null:e instanceof Node?e.ownerDocument:null!=e&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}function kc(e){"function"==typeof queueMicrotask?queueMicrotask(e):Promise.resolve().then(e).catch((e=>setTimeout((()=>{throw e}))))}function Sc(){let e=[],t={addEventListener:(e,n,r,i)=>(e.addEventListener(n,r,i),t.add((()=>e.removeEventListener(n,r,i)))),requestAnimationFrame(...e){let n=requestAnimationFrame(...e);return t.add((()=>cancelAnimationFrame(n)))},nextFrame:(...e)=>t.requestAnimationFrame((()=>t.requestAnimationFrame(...e))),setTimeout(...e){let n=setTimeout(...e);return t.add((()=>clearTimeout(n)))},microTask(...e){let n={current:!0};return kc((()=>{n.current&&e[0]()})),t.add((()=>{n.current=!1}))},style(e,t,n){let r=e.style.getPropertyValue(t);return Object.assign(e.style,{[t]:n}),this.add((()=>{Object.assign(e.style,{[t]:r})}))},group(e){let t=Sc();return e(t),this.add((()=>t.dispose()))},add:t=>(e.includes(t)||e.push(t),()=>{let n=e.indexOf(t);if(n>=0)for(let t of e.splice(n,1))t()}),dispose(){for(let t of e.splice(0))t()}};return t}function Ec(){let[e]=Rt(Sc);return Ot((()=>()=>e.dispose()),[e]),e}let Cc=(e,t)=>{bc.isServer?Ot(e,t):Lt(e,t)};function Tc(e){let t=Mt(e);return Cc((()=>{t.current=e}),[e]),t}let Pc=function(e){let t=Tc(e);return qr.useCallback(((...e)=>t.current(...e)),[t])};let Rc=at(void 0);function Ac(){return Gt(Rc)}function Oc(...e){return Array.from(new Set(e.flatMap((e=>"string"==typeof e?e.split(" "):[])))).filter(Boolean).join(" ")}function Lc(e,t,...n){if(e in t){let r=t[e];return"function"==typeof r?r(...n):r}let r=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map((e=>`"${e}"`)).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,Lc),r}var Mc,Fc,Ic=((Fc=Ic||{})[Fc.None=0]="None",Fc[Fc.RenderStrategy=1]="RenderStrategy",Fc[Fc.Static=2]="Static",Fc),Dc=((Mc=Dc||{})[Mc.Unmount=0]="Unmount",Mc[Mc.Hidden=1]="Hidden",Mc);function Gc(){let e=function(){let e=Mt([]),t=Dt((t=>{for(let n of e.current)null!=n&&("function"==typeof n?n(t):n.current=t)}),[]);return(...n)=>{if(!n.every((e=>null==e)))return e.current=n,t}}();return Dt((t=>function({ourProps:e,theirProps:t,slot:n,defaultTag:r,features:i,visible:o=!0,name:a,mergeRefs:s}){s=null!=s?s:$c;let l=Hc(t,e);if(o)return Nc(l,n,r,a,s);let c=null!=i?i:0;if(2&c){let{static:e=!1,...t}=l;if(e)return Nc(t,n,r,a,s)}if(1&c){let{unmount:e=!0,...t}=l;return Lc(e?0:1,{0:()=>null,1:()=>Nc({...t,hidden:!0,style:{display:"none"}},n,r,a,s)})}return Nc(l,n,r,a,s)}({mergeRefs:e,...t})),[e])}function Nc(e,t={},n,r,i){let{as:o=n,children:a,refName:s="ref",...l}=Bc(e,["unmount","static"]),c=void 0!==e.ref?{[s]:e.ref}:{},u="function"==typeof a?a(t):a;"className"in l&&l.className&&"function"==typeof l.className&&(l.className=l.className(t)),l["aria-labelledby"]&&l["aria-labelledby"]===l.id&&(l["aria-labelledby"]=void 0);let d={};if(t){let e=!1,n=[];for(let[r,i]of Object.entries(t))"boolean"==typeof i&&(e=!0),!0===i&&n.push(r.replace(/([A-Z])/g,(e=>`-${e.toLowerCase()}`)));if(e){d["data-headlessui-state"]=n.join(" ");for(let e of n)d[`data-${e}`]=""}}if(o===$e&&(Object.keys(jc(l)).length>0||Object.keys(jc(d)).length>0)){if(Ar(u)&&!(Array.isArray(u)&&u.length>1)){let e=u.props,t=null==e?void 0:e.className,n="function"==typeof t?(...e)=>Oc(t(...e),l.className):Oc(t,l.className),r=n?{className:n}:{},o=Hc(u.props,jc(Bc(l,["ref"])));for(let i in d)i in o&&delete d[i];return Mr(u,Object.assign({},o,d,c,{ref:i(zc(u),c.ref)},r))}if(Object.keys(jc(l)).length>0)throw new Error(['Passing props on "Fragment"!',"",`The current component <${r} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(jc(l)).concat(Object.keys(jc(d))).map((e=>` - ${e}`)).join("\n"),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map((e=>` - ${e}`)).join("\n")].join("\n"))}return De(o,Object.assign({},Bc(l,["ref"]),o!==$e&&c,o!==$e&&d),u)}function $c(...e){return e.every((e=>null==e))?void 0:t=>{for(let n of e)null!=n&&("function"==typeof n?n(t):n.current=t)}}function Hc(...e){if(0===e.length)return{};if(1===e.length)return e[0];let t={},n={};for(let r of e)for(let e in r)e.startsWith("on")&&"function"==typeof r[e]?(null!=n[e]||(n[e]=[]),n[e].push(r[e])):t[e]=r[e];if(t.disabled||t["aria-disabled"])for(let r in n)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(r)&&(n[r]=[e=>{var t;return null==(t=null==e?void 0:e.preventDefault)?void 0:t.call(e)}]);for(let r in n)Object.assign(t,{[r](e,...t){let i=n[r];for(let n of i){if((e instanceof Event||(null==e?void 0:e.nativeEvent)instanceof Event)&&e.defaultPrevented)return;n(e,...t)}}});return t}function Wc(...e){if(0===e.length)return{};if(1===e.length)return e[0];let t={},n={};for(let r of e)for(let e in r)e.startsWith("on")&&"function"==typeof r[e]?(null!=n[e]||(n[e]=[]),n[e].push(r[e])):t[e]=r[e];for(let r in n)Object.assign(t,{[r](...e){let t=n[r];for(let n of t)null==n||n(...e)}});return t}function Uc(e){var t;return Object.assign(Yn(e),{displayName:null!=(t=e.displayName)?t:e.name})}function jc(e){let t=Object.assign({},e);for(let n in t)void 0===t[n]&&delete t[n];return t}function Bc(e,t=[]){let n=Object.assign({},e);for(let r of t)r in n&&delete n[r];return n}function zc(e){return qr.version.split(".")[0]>="19"?e.props.ref:e.ref}let qc=at(void 0);function Kc(e){let t=e.parentElement,n=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(n=t),t=t.parentElement;let r=""===(null==t?void 0:t.getAttribute("disabled"));return(!r||!function(e){if(!e)return!1;let t=e.previousElementSibling;for(;null!==t;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}(n))&&r}let Vc=Symbol();function Qc(...e){let t=Mt(e);Ot((()=>{t.current=e}),[e]);let n=Pc((e=>{for(let n of t.current)null!=n&&("function"==typeof n?n(e):n.current=e)}));return e.every((e=>null==e||(null==e?void 0:e[Vc])))?void 0:n}let Yc=at(null);function Xc(){let e=Gt(Yc);if(null===e){let e=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(e,Xc),e}return e}Yc.displayName="DescriptionContext";let Jc=Uc((function(e,t){let n=$t(),r=Ac(),{id:i=`headlessui-description-${n}`,...o}=e,a=Xc(),s=Qc(t);Cc((()=>a.register(i)),[i,a.register]);let l=r||!1,c=It((()=>({...a.slot,disabled:l})),[a.slot,l]),u={ref:s,...a.props,id:i};return Gc()({ourProps:u,theirProps:o,slot:c,defaultTag:"p",name:a.name||"Description"})}));Object.assign(Jc,{});var Zc,eu=((Zc=eu||{}).Space=" ",Zc.Enter="Enter",Zc.Escape="Escape",Zc.Backspace="Backspace",Zc.Delete="Delete",Zc.ArrowLeft="ArrowLeft",Zc.ArrowUp="ArrowUp",Zc.ArrowRight="ArrowRight",Zc.ArrowDown="ArrowDown",Zc.Home="Home",Zc.End="End",Zc.PageUp="PageUp",Zc.PageDown="PageDown",Zc.Tab="Tab",Zc);let tu=at(null);function nu(){let e=Gt(tu);if(null===e){let e=new Error("You used a <Label /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(e,nu),e}return e}function ru({inherit:e=!1}={}){let t=function(){var e,t;let n=null!=(t=null==(e=Gt(tu))?void 0:e.value)?t:void 0;return n}(),[n,r]=Rt([]),i=e?[t,...n].filter(Boolean):n;return[i.length>0?i.join(" "):void 0,It((()=>function(e){let t=Pc((e=>(r((t=>[...t,e])),()=>r((t=>{let n=t.slice(),r=n.indexOf(e);return-1!==r&&n.splice(r,1),n}))))),n=It((()=>({register:t,slot:e.slot,name:e.name,props:e.props,value:e.value})),[t,e.slot,e.name,e.props,e.value]);return qr.createElement(tu.Provider,{value:n},e.children)}),[r])]}tu.displayName="LabelContext";let iu=Uc((function(e,t){var n;let r=$t(),i=nu(),o=Gt(qc),a=Ac(),{id:s=`headlessui-label-${r}`,htmlFor:l=(null!=o?o:null==(n=i.props)?void 0:n.htmlFor),passive:c=!1,...u}=e,d=Qc(t);Cc((()=>i.register(s)),[s,i.register]);let p=Pc((e=>{let t=e.currentTarget;if(t instanceof HTMLLabelElement&&e.preventDefault(),i.props&&"onClick"in i.props&&"function"==typeof i.props.onClick&&i.props.onClick(e),t instanceof HTMLLabelElement){let e=document.getElementById(t.htmlFor);if(e){let t=e.getAttribute("disabled");if("true"===t||""===t)return;let n=e.getAttribute("aria-disabled");if("true"===n||""===n)return;(e instanceof HTMLInputElement&&("radio"===e.type||"checkbox"===e.type)||"radio"===e.role||"checkbox"===e.role||"switch"===e.role)&&e.click(),e.focus({preventScroll:!0})}}})),h=a||!1,f=It((()=>({...i.slot,disabled:h})),[i.slot,h]),v={ref:d,...i.props,id:s,htmlFor:l,onClick:p};return c&&("onClick"in v&&(delete v.htmlFor,delete v.onClick),"onClick"in u&&delete u.onClick),Gc()({ourProps:v,theirProps:u,slot:f,defaultTag:l?"label":"div",name:i.name||"Label"})}));function ou(e,t=!1){let[n,r]=At((()=>({})),{}),i=It((()=>function(e){if(null===e)return{width:0,height:0};let{width:t,height:n}=e.getBoundingClientRect();return{width:t,height:n}}(e)),[e,n]);return Cc((()=>{if(!e)return;let t=new ResizeObserver(r);return t.observe(e),()=>{t.disconnect()}}),[e]),t?{width:`${i.width}px`,height:`${i.height}px`}:i}Object.assign(iu,{});let au=class extends Map{constructor(e){super(),this.factory=e}get(e){let t=super.get(e);return void 0===t&&(t=this.factory(e),this.set(e,t)),t}};function su(e,t){let n=e(),r=new Set;return{getSnapshot:()=>n,subscribe:e=>(r.add(e),()=>r.delete(e)),dispatch(e,...i){let o=t[e].call(n,...i);o&&(n=o,r.forEach((e=>e())))}}}function lu(e){return Br(e.subscribe,e.getSnapshot,e.getSnapshot)}let cu=new au((()=>su((()=>[]),{ADD(e){return this.includes(e)?this:[...this,e]},REMOVE(e){let t=this.indexOf(e);if(-1===t)return this;let n=this.slice();return n.splice(t,1),n}})));function uu(e,t){let n=cu.get(t),r=$t(),i=lu(n);if(Cc((()=>{if(e)return n.dispatch("ADD",r),()=>n.dispatch("REMOVE",r)}),[n,e]),!e)return!1;let o=i.indexOf(r),a=i.length;return-1===o&&(o=a,a+=1),o===a-1}let du=new Map,pu=new Map;function hu(e){var t;let n=null!=(t=pu.get(e))?t:0;return pu.set(e,n+1),0!==n||(du.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),e.setAttribute("aria-hidden","true"),e.inert=!0),()=>fu(e)}function fu(e){var t;let n=null!=(t=pu.get(e))?t:1;if(1===n?pu.delete(e):pu.set(e,n-1),1!==n)return;let r=du.get(e);r&&(null===r["aria-hidden"]?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",r["aria-hidden"]),e.inert=r.inert,du.delete(e))}let vu=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map((e=>`${e}:not([tabindex='-1'])`)).join(","),mu=["[data-autofocus]"].map((e=>`${e}:not([tabindex='-1'])`)).join(",");var gu,yu,_u,wu=((_u=wu||{})[_u.First=1]="First",_u[_u.Previous=2]="Previous",_u[_u.Next=4]="Next",_u[_u.Last=8]="Last",_u[_u.WrapAround=16]="WrapAround",_u[_u.NoScroll=32]="NoScroll",_u[_u.AutoFocus=64]="AutoFocus",_u),bu=((yu=bu||{})[yu.Error=0]="Error",yu[yu.Overflow=1]="Overflow",yu[yu.Success=2]="Success",yu[yu.Underflow=3]="Underflow",yu),xu=((gu=xu||{})[gu.Previous=-1]="Previous",gu[gu.Next=1]="Next",gu);function ku(e=document.body){return null==e?[]:Array.from(e.querySelectorAll(vu)).sort(((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER))))}var Su=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(Su||{});function Eu(e,t=0){var n;return e!==(null==(n=xc(e))?void 0:n.body)&&Lc(t,{0:()=>e.matches(vu),1(){let t=e;for(;null!==t;){if(t.matches(vu))return!0;t=t.parentElement}return!1}})}function Cu(e){let t=xc(e);Sc().nextFrame((()=>{t&&!Eu(t.activeElement,0)&&function(e){null==e||e.focus({preventScroll:!0})}(e)}))}var Tu=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(Tu||{});"undefined"!=typeof window&&"undefined"!=typeof document&&(document.addEventListener("keydown",(e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")}),!0),document.addEventListener("click",(e=>{1===e.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===e.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")}),!0));let Pu=["textarea","input"].join(",");function Ru(e,t=e=>e){return e.slice().sort(((e,n)=>{let r=t(e),i=t(n);if(null===r||null===i)return 0;let o=r.compareDocumentPosition(i);return o&Node.DOCUMENT_POSITION_FOLLOWING?-1:o&Node.DOCUMENT_POSITION_PRECEDING?1:0}))}function Au(e,t){return function(e,t,{sorted:n=!0,relativeTo:r=null,skipElements:i=[]}={}){let o=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,a=Array.isArray(e)?n?Ru(e):e:64&t?function(e=document.body){return null==e?[]:Array.from(e.querySelectorAll(mu)).sort(((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER))))}(e):ku(e);i.length>0&&a.length>1&&(a=a.filter((e=>!i.some((t=>null!=t&&"current"in t?(null==t?void 0:t.current)===e:t===e))))),r=null!=r?r:o.activeElement;let s,l=(()=>{if(5&t)return 1;if(10&t)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),c=(()=>{if(1&t)return 0;if(2&t)return Math.max(0,a.indexOf(r))-1;if(4&t)return Math.max(0,a.indexOf(r))+1;if(8&t)return a.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),u=32&t?{preventScroll:!0}:{},d=0,p=a.length;do{if(d>=p||d+p<=0)return 0;let e=c+d;if(16&t)e=(e+p)%p;else{if(e<0)return 3;if(e>=p)return 1}s=a[e],null==s||s.focus(u),d+=l}while(s!==o.activeElement);return 6&t&&function(e){var t,n;return null!=(n=null==(t=null==e?void 0:e.matches)?void 0:t.call(e,Pu))&&n}(s)&&s.select(),2}(ku(),t,{relativeTo:e})}function Ou(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function Lu(){return Ou()||/Android/gi.test(window.navigator.userAgent)}function Mu(e,t,n,r){let i=Tc(n);Ot((()=>{if(e)return document.addEventListener(t,n,r),()=>document.removeEventListener(t,n,r);function n(e){i.current(e)}}),[e,t,r])}function Fu(e,t,n){let r=uu(e,"outside-click"),i=Tc(n),o=Dt((function(e,n){if(e.defaultPrevented)return;let r=n(e);if(null===r||!r.getRootNode().contains(r)||!r.isConnected)return;let o=function e(t){return"function"==typeof t?e(t()):Array.isArray(t)||t instanceof Set?t:[t]}(t);for(let t of o)if(null!==t&&(t.contains(r)||e.composed&&e.composedPath().includes(t)))return;return!Eu(r,Su.Loose)&&-1!==r.tabIndex&&e.preventDefault(),i.current(e,r)}),[i,t]),a=Mt(null);Mu(r,"pointerdown",(e=>{var t,n;a.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target}),!0),Mu(r,"mousedown",(e=>{var t,n;a.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target}),!0),Mu(r,"click",(e=>{Lu()||a.current&&(o(e,(()=>a.current)),a.current=null)}),!0);let s=Mt({x:0,y:0});Mu(r,"touchstart",(e=>{s.current.x=e.touches[0].clientX,s.current.y=e.touches[0].clientY}),!0),Mu(r,"touchend",(e=>{let t=e.changedTouches[0].clientX,n=e.changedTouches[0].clientY;if(!(Math.abs(t-s.current.x)>=30||Math.abs(n-s.current.y)>=30))return o(e,(()=>e.target instanceof HTMLElement?e.target:null))}),!0),function(e,t,n,r){let i=Tc(n);Ot((()=>{if(e)return window.addEventListener(t,n,r),()=>window.removeEventListener(t,n,r);function n(e){i.current(e)}}),[e,t,r])}(r,"blur",(e=>o(e,(()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null))),!0)}function Iu(...e){return It((()=>xc(...e)),[...e])}function Du(e,t){return It((()=>{var n;if(e.type)return e.type;let r=null!=(n=e.as)?n:"button";return"string"==typeof r&&"button"===r.toLowerCase()||"BUTTON"===(null==t?void 0:t.tagName)&&!t.hasAttribute("type")?"button":void 0}),[e.type,e.as,t])}function Gu(){let e;return{before({doc:t}){var n;let r=t.documentElement,i=null!=(n=t.defaultView)?n:window;e=Math.max(0,i.innerWidth-r.clientWidth)},after({doc:t,d:n}){let r=t.documentElement,i=Math.max(0,r.clientWidth-r.offsetWidth),o=Math.max(0,e-i);n.style(r,"paddingRight",`${o}px`)}}}function Nu(e){let t={};for(let n of e)Object.assign(t,n(t));return t}let $u=su((()=>new Map),{PUSH(e,t){var n;let r=null!=(n=this.get(e))?n:{doc:e,count:0,d:Sc(),meta:new Set};return r.count++,r.meta.add(t),this.set(e,r),this},POP(e,t){let n=this.get(e);return n&&(n.count--,n.meta.delete(t)),this},SCROLL_PREVENT({doc:e,d:t,meta:n}){let r={doc:e,d:t,meta:Nu(n)},i=[Ou()?{before({doc:e,d:t,meta:n}){function r(e){return n.containers.flatMap((e=>e())).some((t=>t.contains(e)))}t.microTask((()=>{var n;if("auto"!==window.getComputedStyle(e.documentElement).scrollBehavior){let n=Sc();n.style(e.documentElement,"scrollBehavior","auto"),t.add((()=>t.microTask((()=>n.dispose()))))}let i=null!=(n=window.scrollY)?n:window.pageYOffset,o=null;t.addEventListener(e,"click",(t=>{if(t.target instanceof HTMLElement)try{let n=t.target.closest("a");if(!n)return;let{hash:i}=new URL(n.href),a=e.querySelector(i);a&&!r(a)&&(o=a)}catch{}}),!0),t.addEventListener(e,"touchstart",(e=>{if(e.target instanceof HTMLElement)if(r(e.target)){let n=e.target;for(;n.parentElement&&r(n.parentElement);)n=n.parentElement;t.style(n,"overscrollBehavior","contain")}else t.style(e.target,"touchAction","none")})),t.addEventListener(e,"touchmove",(e=>{if(e.target instanceof HTMLElement){if("INPUT"===e.target.tagName)return;if(r(e.target)){let t=e.target;for(;t.parentElement&&""!==t.dataset.headlessuiPortal&&!(t.scrollHeight>t.clientHeight||t.scrollWidth>t.clientWidth);)t=t.parentElement;""===t.dataset.headlessuiPortal&&e.preventDefault()}else e.preventDefault()}}),{passive:!1}),t.add((()=>{var e;let t=null!=(e=window.scrollY)?e:window.pageYOffset;i!==t&&window.scrollTo(0,i),o&&o.isConnected&&(o.scrollIntoView({block:"nearest"}),o=null)}))}))}}:{},Gu(),{before({doc:e,d:t}){t.style(e.documentElement,"overflow","hidden")}}];i.forEach((({before:e})=>null==e?void 0:e(r))),i.forEach((({after:e})=>null==e?void 0:e(r)))},SCROLL_ALLOW({d:e}){e.dispose()},TEARDOWN({doc:e}){this.delete(e)}});function Hu(e,t,n=()=>[document.body]){!function(e,t,n=()=>({containers:[]})){let r=lu($u),i=t?r.get(t):void 0,o=!!i&&i.count>0;Cc((()=>{if(t&&e)return $u.dispatch("PUSH",t,n),()=>$u.dispatch("POP",t,n)}),[e,t])}(uu(e,"scroll-lock"),t,(e=>{var t;return{containers:[...null!=(t=e.containers)?t:[],n]}}))}function Wu(e){return[e.screenX,e.screenY]}$u.subscribe((()=>{let e=$u.getSnapshot(),t=new Map;for(let[n]of e)t.set(n,n.documentElement.style.overflow);for(let n of e.values()){let e="hidden"===t.get(n.doc),r=0!==n.count;(r&&!e||!r&&e)&&$u.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),0===n.count&&$u.dispatch("TEARDOWN",n)}}));var Uu,ju;"undefined"!=typeof process&&"undefined"!=typeof globalThis&&"undefined"!=typeof Element&&"test"===(null==(Uu=null==process?void 0:{})?void 0:Uu.NODE_ENV)&&void 0===(null==(ju=null==Element?void 0:Element.prototype)?void 0:ju.getAnimations)&&(Element.prototype.getAnimations=function(){return console.warn(["Headless UI has polyfilled `Element.prototype.getAnimations` for your tests.","Please install a proper polyfill e.g. `jsdom-testing-mocks`, to silence these warnings.","","Example usage:","```js","import { mockAnimationsApi } from 'jsdom-testing-mocks'","mockAnimationsApi()","```"].join("\n")),[]});var Bu=(e=>(e[e.None=0]="None",e[e.Closed=1]="Closed",e[e.Enter=2]="Enter",e[e.Leave=4]="Leave",e))(Bu||{});function zu(e){let t={};for(let n in e)!0===e[n]&&(t[`data-${n}`]="");return t}function qu(e,t,n,r){let[i,o]=Rt(n),{hasFlag:a,addFlag:s,removeFlag:l}=function(e=0){let[t,n]=Rt(e),r=Dt((e=>n(e)),[t]),i=Dt((e=>n((t=>t|e))),[t]),o=Dt((e=>(t&e)===e),[t]),a=Dt((e=>n((t=>t&~e))),[n]),s=Dt((e=>n((t=>t^e))),[n]);return{flags:t,setFlag:r,addFlag:i,hasFlag:o,removeFlag:a,toggleFlag:s}}(e&&i?3:0),c=Mt(!1),u=Mt(!1),d=Ec();return Cc((()=>{var i;if(e)return n&&o(!0),t?(null==(i=null==r?void 0:r.start)||i.call(r,n),function(e,{prepare:t,run:n,done:r,inFlight:i}){let o=Sc();return function(e,{inFlight:t,prepare:n}){if(null!=t&&t.current)return void n();let r=e.style.transition;e.style.transition="none",n(),e.offsetHeight,e.style.transition=r}(e,{prepare:t,inFlight:i}),o.nextFrame((()=>{n(),o.requestAnimationFrame((()=>{o.add(function(e,t){var n,r;let i=Sc();if(!e)return i.dispose;let o=!1;i.add((()=>{o=!0}));let a=null!=(r=null==(n=e.getAnimations)?void 0:n.call(e).filter((e=>e instanceof CSSTransition)))?r:[];return 0===a.length?(t(),i.dispose):(Promise.allSettled(a.map((e=>e.finished))).then((()=>{o||t()})),i.dispose)}(e,r))}))})),o.dispose}(t,{inFlight:c,prepare(){u.current?u.current=!1:u.current=c.current,c.current=!0,!u.current&&(n?(s(3),l(4)):(s(4),l(2)))},run(){u.current?n?(l(3),s(4)):(l(4),s(3)):n?l(1):s(1)},done(){var e;u.current&&"function"==typeof t.getAnimations&&t.getAnimations().length>0||(c.current=!1,l(7),n||o(!1),null==(e=null==r?void 0:r.end)||e.call(r,n))}})):void(n&&s(3))}),[e,n,t,d]),e?[i,{closed:a(1),enter:a(2),leave:a(4),transition:a(2)||a(4)}]:[n,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function Ku(){return"undefined"!=typeof window}function Vu(e){return Xu(e)?(e.nodeName||"").toLowerCase():"#document"}function Qu(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Yu(e){var t;return null==(t=(Xu(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function Xu(e){return!!Ku()&&(e instanceof Node||e instanceof Qu(e).Node)}function Ju(e){return!!Ku()&&(e instanceof Element||e instanceof Qu(e).Element)}function Zu(e){return!!Ku()&&(e instanceof HTMLElement||e instanceof Qu(e).HTMLElement)}function ed(e){return!(!Ku()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof Qu(e).ShadowRoot)}function td(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=sd(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function nd(e){return["table","td","th"].includes(Vu(e))}function rd(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch(Mc){return!1}}))}function id(e){const t=od(),n=Ju(e)?sd(e):e;return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function od(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function ad(e){return["html","body","#document"].includes(Vu(e))}function sd(e){return Qu(e).getComputedStyle(e)}function ld(e){return Ju(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function cd(e){if("html"===Vu(e))return e;const t=e.assignedSlot||e.parentNode||ed(e)&&e.host||Yu(e);return ed(t)?t.host:t}function ud(e){const t=cd(e);return ad(t)?e.ownerDocument?e.ownerDocument.body:e.body:Zu(t)&&td(t)?t:ud(t)}function dd(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const i=ud(e),o=i===(null==(r=e.ownerDocument)?void 0:r.body),a=Qu(i);if(o){const e=pd(a);return t.concat(a,a.visualViewport||[],td(i)?i:[],e&&n?dd(e):[])}return t.concat(i,dd(i,[],n))}function pd(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}const hd=Math.min,fd=Math.max,vd=Math.round,md=Math.floor,gd=e=>({x:e,y:e}),yd={left:"right",right:"left",bottom:"top",top:"bottom"},_d={start:"end",end:"start"};function wd(e,t,n){return fd(e,hd(t,n))}function bd(e,t){return"function"==typeof e?e(t):e}function xd(e){return e.split("-")[0]}function kd(e){return e.split("-")[1]}function Sd(e){return"x"===e?"y":"x"}function Ed(e){return"y"===e?"height":"width"}function Cd(e){return["top","bottom"].includes(xd(e))?"y":"x"}function Td(e){return Sd(Cd(e))}function Pd(e){return e.replace(/start|end/g,(e=>_d[e]))}function Rd(e){return e.replace(/left|right|bottom|top/g,(e=>yd[e]))}function Ad(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function Od(e,t,n){let{reference:r,floating:i}=e;const o=Cd(t),a=Td(t),s=Ed(a),l=xd(t),c="y"===o,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,p=r[s]/2-i[s]/2;let h;switch(l){case"top":h={x:u,y:r.y-i.height};break;case"bottom":h={x:u,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:d};break;case"left":h={x:r.x-i.width,y:d};break;default:h={x:r.x,y:r.y}}switch(kd(t)){case"start":h[a]-=p*(n&&c?-1:1);break;case"end":h[a]+=p*(n&&c?-1:1)}return h}async function Ld(e,t){var n;void 0===t&&(t={});const{x:r,y:i,platform:o,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:p=!1,padding:h=0}=bd(t,e),f=function(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}(h),v=s[p?"floating"===d?"reference":"floating":d],m=Ad(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(v)))||n?v:v.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:u,strategy:l})),g="floating"===d?{x:r,y:i,width:a.floating.width,height:a.floating.height}:a.reference,y=await(null==o.getOffsetParent?void 0:o.getOffsetParent(s.floating)),_=await(null==o.isElement?void 0:o.isElement(y))&&await(null==o.getScale?void 0:o.getScale(y))||{x:1,y:1},w=Ad(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:g,offsetParent:y,strategy:l}):g);return{top:(m.top-w.top+f.top)/_.y,bottom:(w.bottom-m.bottom+f.bottom)/_.y,left:(m.left-w.left+f.left)/_.x,right:(w.right-m.right+f.right)/_.x}}function Md(e){const t=sd(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Zu(e),o=i?e.offsetWidth:n,a=i?e.offsetHeight:r,s=vd(n)!==o||vd(r)!==a;return s&&(n=o,r=a),{width:n,height:r,$:s}}function Fd(e){return Ju(e)?e:e.contextElement}function Id(e){const t=Fd(e);if(!Zu(t))return gd(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=Md(t);let a=(o?vd(n.width):n.width)/r,s=(o?vd(n.height):n.height)/i;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const Dd=gd(0);function Gd(e){const t=Qu(e);return od()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Dd}function Nd(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const i=e.getBoundingClientRect(),o=Fd(e);let a=gd(1);t&&(r?Ju(r)&&(a=Id(r)):a=Id(e));const s=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==Qu(e))&&t}(o,n,r)?Gd(o):gd(0);let l=(i.left+s.x)/a.x,c=(i.top+s.y)/a.y,u=i.width/a.x,d=i.height/a.y;if(o){const e=Qu(o),t=r&&Ju(r)?Qu(r):r;let n=e,i=pd(n);for(;i&&r&&t!==n;){const e=Id(i),t=i.getBoundingClientRect(),r=sd(i),o=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,a=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;l*=e.x,c*=e.y,u*=e.x,d*=e.y,l+=o,c+=a,n=Qu(i),i=pd(n)}}return Ad({width:u,height:d,x:l,y:c})}function $d(e,t){const n=ld(e).scrollLeft;return t?t.left+n:Nd(Yu(e)).left+n}function Hd(e,t,n){void 0===n&&(n=!1);const r=e.getBoundingClientRect();return{x:r.left+t.scrollLeft-(n?0:$d(e,r)),y:r.top+t.scrollTop}}function Wd(e,t,n){let r;if("viewport"===t)r=function(e,t){const n=Qu(e),r=Yu(e),i=n.visualViewport;let o=r.clientWidth,a=r.clientHeight,s=0,l=0;if(i){o=i.width,a=i.height;const e=od();(!e||e&&"fixed"===t)&&(s=i.offsetLeft,l=i.offsetTop)}return{width:o,height:a,x:s,y:l}}(e,n);else if("document"===t)r=function(e){const t=Yu(e),n=ld(e),r=e.ownerDocument.body,i=fd(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=fd(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+$d(e);const s=-n.scrollTop;return"rtl"===sd(r).direction&&(a+=fd(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:a,y:s}}(Yu(e));else if(Ju(t))r=function(e,t){const n=Nd(e,!0,"fixed"===t),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=Zu(e)?Id(e):gd(1);return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:i*o.x,y:r*o.y}}(t,n);else{const n=Gd(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Ad(r)}function Ud(e,t){const n=cd(e);return!(n===t||!Ju(n)||ad(n))&&("fixed"===sd(n).position||Ud(n,t))}function jd(e,t,n){const r=Zu(t),i=Yu(t),o="fixed"===n,a=Nd(e,!0,o,t);let s={scrollLeft:0,scrollTop:0};const l=gd(0);if(r||!r&&!o)if(("body"!==Vu(t)||td(i))&&(s=ld(t)),r){const e=Nd(t,!0,o,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else i&&(l.x=$d(i));const c=!i||r||o?gd(0):Hd(i,s);return{x:a.left+s.scrollLeft-l.x-c.x,y:a.top+s.scrollTop-l.y-c.y,width:a.width,height:a.height}}function Bd(e){return"static"===sd(e).position}function zd(e,t){if(!Zu(e)||"fixed"===sd(e).position)return null;if(t)return t(e);let n=e.offsetParent;return Yu(e)===n&&(n=n.ownerDocument.body),n}function qd(e,t){const n=Qu(e);if(rd(e))return n;if(!Zu(e)){let t=cd(e);for(;t&&!ad(t);){if(Ju(t)&&!Bd(t))return t;t=cd(t)}return n}let r=zd(e,t);for(;r&&nd(r)&&Bd(r);)r=zd(r,t);return r&&ad(r)&&Bd(r)&&!id(r)?n:r||function(e){let t=cd(e);for(;Zu(t)&&!ad(t);){if(id(t))return t;if(rd(t))return null;t=cd(t)}return null}(e)||n}const Kd={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const o="fixed"===i,a=Yu(r),s=!!t&&rd(t.floating);if(r===a||s&&o)return n;let l={scrollLeft:0,scrollTop:0},c=gd(1);const u=gd(0),d=Zu(r);if((d||!d&&!o)&&(("body"!==Vu(r)||td(a))&&(l=ld(r)),Zu(r))){const e=Nd(r);c=Id(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}const p=!a||d||o?gd(0):Hd(a,l,!0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+u.x+p.x,y:n.y*c.y-l.scrollTop*c.y+u.y+p.y}},getDocumentElement:Yu,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=[..."clippingAncestors"===n?rd(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let r=dd(e,[],!1).filter((e=>Ju(e)&&"body"!==Vu(e))),i=null;const o="fixed"===sd(e).position;let a=o?cd(e):e;for(;Ju(a)&&!ad(a);){const t=sd(a),n=id(a);n||"fixed"!==t.position||(i=null),(o?!n&&!i:!n&&"static"===t.position&&i&&["absolute","fixed"].includes(i.position)||td(a)&&!n&&Ud(e,a))?r=r.filter((e=>e!==a)):i=t,a=cd(a)}return t.set(e,r),r}(t,this._c):[].concat(n),r],a=o[0],s=o.reduce(((e,n)=>{const r=Wd(t,n,i);return e.top=fd(r.top,e.top),e.right=hd(r.right,e.right),e.bottom=hd(r.bottom,e.bottom),e.left=fd(r.left,e.left),e}),Wd(t,a,i));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:qd,getElementRects:async function(e){const t=this.getOffsetParent||qd,n=this.getDimensions,r=await n(e.floating);return{reference:jd(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=Md(e);return{width:t,height:n}},getScale:Id,isElement:Ju,isRTL:function(e){return"rtl"===sd(e).direction}};function Vd(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,c=Fd(e),u=i||o?[...c?dd(c):[],...dd(t)]:[];u.forEach((e=>{i&&e.addEventListener("scroll",n,{passive:!0}),o&&e.addEventListener("resize",n)}));const d=c&&s?function(e,t){let n,r=null;const i=Yu(e);function o(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function a(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),o();const{left:c,top:u,width:d,height:p}=e.getBoundingClientRect();if(s||t(),!d||!p)return;const h={rootMargin:-md(u)+"px "+-md(i.clientWidth-(c+d))+"px "+-md(i.clientHeight-(u+p))+"px "+-md(c)+"px",threshold:fd(0,hd(1,l))||1};let f=!0;function v(e){const t=e[0].intersectionRatio;if(t!==l){if(!f)return a();t?a(!1,t):n=setTimeout((()=>{a(!1,1e-7)}),1e3)}f=!1}try{r=new IntersectionObserver(v,{...h,root:i.ownerDocument})}catch(Mc){r=new IntersectionObserver(v,h)}r.observe(e)}(!0),o}(c,n):null;let p,h=-1,f=null;a&&(f=new ResizeObserver((e=>{let[r]=e;r&&r.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame((()=>{var e;null==(e=f)||e.observe(t)}))),n()})),c&&!l&&f.observe(c),f.observe(t));let v=l?Nd(e):null;return l&&function t(){const r=Nd(e);!v||r.x===v.x&&r.y===v.y&&r.width===v.width&&r.height===v.height||n();v=r,p=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach((e=>{i&&e.removeEventListener("scroll",n),o&&e.removeEventListener("resize",n)})),null==d||d(),null==(e=f)||e.disconnect(),f=null,l&&cancelAnimationFrame(p)}}const Qd=Ld,Yd=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:o,placement:a,middlewareData:s}=t,l=await async function(e,t){const{placement:n,platform:r,elements:i}=e,o=await(null==r.isRTL?void 0:r.isRTL(i.floating)),a=xd(n),s=kd(n),l="y"===Cd(n),c=["left","top"].includes(a)?-1:1,u=o&&l?-1:1,d=bd(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:f}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof f&&(h="end"===s?-1*f:f),l?{x:h*u,y:p*c}:{x:p*c,y:h*u}}(t,e);return a===(null==(n=s.offset)?void 0:n.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:i+l.x,y:o+l.y,data:{...l,placement:a}}}}},Xd=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:o=!0,crossAxis:a=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=bd(e,t),c={x:n,y:r},u=await Ld(t,l),d=Cd(xd(i)),p=Sd(d);let h=c[p],f=c[d];if(o){const e="y"===p?"bottom":"right";h=wd(h+u["y"===p?"top":"left"],h,h-u[e])}if(a){const e="y"===d?"bottom":"right";f=wd(f+u["y"===d?"top":"left"],f,f-u[e])}const v=s.fn({...t,[p]:h,[d]:f});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[p]:o,[d]:a}}}}}},Jd=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:o,rects:a,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:v=!0,...m}=bd(e,t);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const g=xd(i),y=Cd(s),_=xd(s)===s,w=await(null==l.isRTL?void 0:l.isRTL(c.floating)),b=p||(_||!v?[Rd(s)]:function(e){const t=Rd(e);return[Pd(e),t,Pd(t)]}(s)),x="none"!==f;!p&&x&&b.push(...function(e,t,n,r){const i=kd(e);let o=function(e,t,n){const r=["left","right"],i=["right","left"],o=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?o:a;default:return[]}}(xd(e),"start"===n,r);return i&&(o=o.map((e=>e+"-"+i)),t&&(o=o.concat(o.map(Pd)))),o}(s,v,f,w));const k=[s,...b],S=await Ld(t,m),E=[];let C=(null==(r=o.flip)?void 0:r.overflows)||[];if(u&&E.push(S[g]),d){const e=function(e,t,n){void 0===n&&(n=!1);const r=kd(e),i=Td(e),o=Ed(i);let a="x"===i?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=Rd(a)),[a,Rd(a)]}(i,a,w);E.push(S[e[0]],S[e[1]])}if(C=[...C,{placement:i,overflows:E}],!E.every((e=>e<=0))){var T,P;const e=((null==(T=o.flip)?void 0:T.index)||0)+1,t=k[e];if(t)return{data:{index:e,overflows:C},reset:{placement:t}};let n=null==(P=C.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:P.placement;if(!n)switch(h){case"bestFit":{var R;const e=null==(R=C.filter((e=>{if(x){const t=Cd(e.placement);return t===y||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:R[0];e&&(n=e);break}case"initialPlacement":n=s}if(i!==n)return{reset:{placement:n}}}return{}}}},Zd=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:o,platform:a,elements:s}=t,{apply:l=()=>{},...c}=bd(e,t),u=await Ld(t,c),d=xd(i),p=kd(i),h="y"===Cd(i),{width:f,height:v}=o.floating;let m,g;"top"===d||"bottom"===d?(m=d,g=p===(await(null==a.isRTL?void 0:a.isRTL(s.floating))?"start":"end")?"left":"right"):(g=d,m="end"===p?"top":"bottom");const y=v-u.top-u.bottom,_=f-u.left-u.right,w=hd(v-u[m],y),b=hd(f-u[g],_),x=!t.middlewareData.shift;let k=w,S=b;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(S=_),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(k=y),x&&!p){const e=fd(u.left,0),t=fd(u.right,0),n=fd(u.top,0),r=fd(u.bottom,0);h?S=f-2*(0!==e||0!==t?e+t:fd(u.left,u.right)):k=v-2*(0!==n||0!==r?n+r:fd(u.top,u.bottom))}await l({...t,availableWidth:S,availableHeight:k});const E=await a.getDimensions(s.floating);return f!==E.width||v!==E.height?{reset:{rects:!0}}:{}}}},ep=(e,t,n)=>{const r=new Map,i={platform:Kd,...n},o={...i.platform,_c:r};return(async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:a}=n,s=o.filter(Boolean),l=await(null==a.isRTL?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=Od(c,r,l),p=r,h={},f=0;for(let v=0;v<s.length;v++){const{name:n,fn:o}=s[v],{x:m,y:g,data:y,reset:_}=await o({x:u,y:d,initialPlacement:r,placement:p,strategy:i,middlewareData:h,rects:c,platform:a,elements:{reference:e,floating:t}});u=null!=m?m:u,d=null!=g?g:d,h={...h,[n]:{...h[n],...y}},_&&f<=50&&(f++,"object"==typeof _&&(_.placement&&(p=_.placement),_.rects&&(c=!0===_.rects?await a.getElementRects({reference:e,floating:t,strategy:i}):_.rects),({x:u,y:d}=Od(c,p,l))),v=-1)}return{x:u,y:d,placement:p,strategy:i,middlewareData:h}})(e,t,{...i,platform:o})};var tp="undefined"!=typeof document?Lt:Ot;function np(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;0!=r--;)if(!np(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;0!=r--;){const n=i[r];if(("_owner"!==n||!e.$$typeof)&&!np(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function rp(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ip(e,t){const n=rp(e);return Math.round(t*n)/n}function op(e){const t=Mt(e);return tp((()=>{t.current=e})),t}const ap=(e,t)=>({...Yd(e),options:[e,t]}),sp=(e,t)=>({...Jd(e),options:[e,t]}),lp=(e,t)=>({...Zd(e),options:[e,t]}),cp={...Kr},up=cp.useInsertionEffect||(e=>e());function dp(e){const t=Mt((()=>{}));return up((()=>{t.current=e})),Dt((function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return null==t.current?void 0:t.current(...n)}),[])}var pp="undefined"!=typeof document?Lt:Ot;let hp=!1,fp=0;const vp=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+fp++;const mp=cp.useId||function(){const[e,t]=Rt((()=>hp?vp():void 0));return pp((()=>{null==e&&t(vp())}),[]),Ot((()=>{hp=!0}),[]),e};const gp=at(null),yp=at(null),_p="data-floating-ui-focusable";function wp(e){const{open:t=!1,onOpenChange:n,elements:r}=e,i=mp(),o=Mt({}),[a]=Rt((()=>function(){const e=new Map;return{emit(t,n){var r;null==(r=e.get(t))||r.forEach((e=>e(n)))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var r;e.set(t,(null==(r=e.get(t))?void 0:r.filter((e=>e!==n)))||[])}}}())),s=null!=((null==(l=Gt(gp))?void 0:l.id)||null);var l;const[c,u]=Rt(r.reference),d=dp(((e,t,r)=>{o.current.openEvent=e?t:void 0,a.emit("openchange",{open:e,event:t,reason:r,nested:s}),null==n||n(e,t,r)})),p=It((()=>({setPositionReference:u})),[]),h=It((()=>({reference:c||r.reference||null,floating:r.floating||null,domReference:r.reference})),[c,r.reference,r.floating]);return It((()=>({dataRef:o,open:t,onOpenChange:d,elements:h,events:a,floatingId:i,refs:p})),[t,d,h,a,i,p])}function bp(e){void 0===e&&(e={});const{nodeId:t}=e,n=wp({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,i=r.elements,[o,a]=Rt(null),[s,l]=Rt(null),c=(null==i?void 0:i.domReference)||o,u=Mt(null),d=Gt(yp);pp((()=>{c&&(u.current=c)}),[c]);const p=function(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:a}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[u,d]=Rt({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,h]=Rt(r);np(p,r)||h(r);const[f,v]=Rt(null),[m,g]=Rt(null),y=Dt((e=>{e!==x.current&&(x.current=e,v(e))}),[]),_=Dt((e=>{e!==k.current&&(k.current=e,g(e))}),[]),w=o||f,b=a||m,x=Mt(null),k=Mt(null),S=Mt(u),E=null!=l,C=op(l),T=op(i),P=op(c),R=Dt((()=>{if(!x.current||!k.current)return;const e={placement:t,strategy:n,middleware:p};T.current&&(e.platform=T.current),ep(x.current,k.current,e).then((e=>{const t={...e,isPositioned:!1!==P.current};A.current&&!np(S.current,t)&&(S.current=t,Gr((()=>{d(t)})))}))}),[p,t,n,T,P]);tp((()=>{!1===c&&S.current.isPositioned&&(S.current.isPositioned=!1,d((e=>({...e,isPositioned:!1}))))}),[c]);const A=Mt(!1);tp((()=>(A.current=!0,()=>{A.current=!1})),[]),tp((()=>{if(w&&(x.current=w),b&&(k.current=b),w&&b){if(C.current)return C.current(w,b,R);R()}}),[w,b,R,C,E]);const O=It((()=>({reference:x,floating:k,setReference:y,setFloating:_})),[y,_]),L=It((()=>({reference:w,floating:b})),[w,b]),M=It((()=>{const e={position:n,left:0,top:0};if(!L.floating)return e;const t=ip(L.floating,u.x),r=ip(L.floating,u.y);return s?{...e,transform:"translate("+t+"px, "+r+"px)",...rp(L.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}}),[n,s,L.floating,u.x,u.y]);return It((()=>({...u,update:R,refs:O,elements:L,floatingStyles:M})),[u,R,O,L,M])}({...e,elements:{...i,...s&&{reference:s}}}),h=Dt((e=>{const t=Ju(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),contextElement:e}:e;l(t),p.refs.setReference(t)}),[p.refs]),f=Dt((e=>{(Ju(e)||null===e)&&(u.current=e,a(e)),(Ju(p.refs.reference.current)||null===p.refs.reference.current||null!==e&&!Ju(e))&&p.refs.setReference(e)}),[p.refs]),v=It((()=>({...p.refs,setReference:f,setPositionReference:h,domReference:u})),[p.refs,f,h]),m=It((()=>({...p.elements,domReference:c})),[p.elements,c]),g=It((()=>({...p,...r,refs:v,elements:m,nodeId:t})),[p,v,m,t,r]);return pp((()=>{r.dataRef.current.floatingContext=g;const e=null==d?void 0:d.nodesRef.current.find((e=>e.id===t));e&&(e.context=g)})),It((()=>({...p,context:g,refs:v,elements:m})),[p,v,m,g])}const xp="active",kp="selected";function Sp(e,t,n){const r=new Map,i="item"===n;let o=e;if(i&&e){const{[xp]:t,[kp]:n,...r}=e;o=r}return{..."floating"===n&&{tabIndex:-1,[_p]:""},...o,...t.map((t=>{const r=t?t[n]:null;return"function"==typeof r?e?r(e):null:r})).concat(e).reduce(((e,t)=>t?(Object.entries(t).forEach((t=>{let[n,o]=t;var a;i&&[xp,kp].includes(n)||(0===n.indexOf("on")?(r.has(n)||r.set(n,[]),"function"==typeof o&&(null==(a=r.get(n))||a.push(o),e[n]=function(){for(var e,t=arguments.length,i=new Array(t),o=0;o<t;o++)i[o]=arguments[o];return null==(e=r.get(n))?void 0:e.map((e=>e(...i))).find((e=>void 0!==e))})):e[n]=o)})),e):e),{})}}function Ep(e,t){return{...e,rects:{...e.rects,floating:{...e.rects.floating,height:t}}}}function Cp(e,t){const{open:n,elements:r}=e,{enabled:i=!0,overflowRef:o,scrollRef:a,onChange:s}=t,l=dp(s),c=Mt(!1),u=Mt(null),d=Mt(null);Ot((()=>{if(!i)return;function e(e){if(e.ctrlKey||!t||null==o.current)return;const n=e.deltaY,r=o.current.top>=-.5,i=o.current.bottom>=-.5,a=t.scrollHeight-t.clientHeight,s=n<0?-1:1,c=n<0?"max":"min";t.scrollHeight<=t.clientHeight||(!r&&n>0||!i&&n<0?(e.preventDefault(),Gr((()=>{l((e=>e+Math[c](n,a*s)))}))):/firefox/i.test(function(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map((e=>{let{brand:t,version:n}=e;return t+"/"+n})).join(" "):navigator.userAgent}())&&(t.scrollTop+=n))}const t=(null==a?void 0:a.current)||r.floating;return n&&t?(t.addEventListener("wheel",e),requestAnimationFrame((()=>{u.current=t.scrollTop,null!=o.current&&(d.current={...o.current})})),()=>{u.current=null,d.current=null,t.removeEventListener("wheel",e)}):void 0}),[i,n,r.floating,o,a,l]);const p=It((()=>({onKeyDown(){c.current=!0},onWheel(){c.current=!1},onPointerMove(){c.current=!1},onScroll(){const e=(null==a?void 0:a.current)||r.floating;if(o.current&&e&&c.current){if(null!==u.current){const t=e.scrollTop-u.current;(o.current.bottom<-.5&&t<-1||o.current.top<-.5&&t>1)&&Gr((()=>l((e=>e+t))))}requestAnimationFrame((()=>{u.current=e.scrollTop}))}}})),[r.floating,l,o,a]);return It((()=>i?{floating:p}:{}),[i,p])}let Tp=at({styles:void 0,setReference:()=>{},setFloating:()=>{},getReferenceProps:()=>({}),getFloatingProps:()=>({}),slot:{}});Tp.displayName="FloatingContext";let Pp=at(null);Pp.displayName="PlacementContext";function Rp({children:e,enabled:t=!0}){let[n,r]=Rt(null),[i,o]=Rt(0),a=Mt(null),[s,l]=Rt(null);!function(e){Cc((()=>{if(!e)return;let t=new MutationObserver((()=>{let t=window.getComputedStyle(e).maxHeight,n=parseFloat(t);if(isNaN(n))return;let r=parseInt(t);isNaN(r)||n!==r&&(e.style.maxHeight=`${Math.ceil(n)}px`)}));return t.observe(e,{attributes:!0,attributeFilter:["style"]}),()=>{t.disconnect()}}),[e])}(s);let c=t&&null!==n&&null!==s,{to:u="bottom",gap:d=0,offset:p=0,padding:h=0,inner:f}=function(e,t){var n,r,i;let o=Ap(null!=(n=null==e?void 0:e.gap)?n:"var(--anchor-gap, 0)",t),a=Ap(null!=(r=null==e?void 0:e.offset)?r:"var(--anchor-offset, 0)",t),s=Ap(null!=(i=null==e?void 0:e.padding)?i:"var(--anchor-padding, 0)",t);return{...e,gap:o,offset:a,padding:s}}(n,s),[v,m="center"]=u.split(" ");Cc((()=>{c&&o(0)}),[c]);let{refs:g,floatingStyles:y,context:_}=bp({open:c,placement:"selection"===v?"center"===m?"bottom":`bottom-${m}`:"center"===m?`${v}`:`${v}-${m}`,strategy:"absolute",transform:!1,middleware:[ap({mainAxis:"selection"===v?0:d,crossAxis:p}),(k={padding:h},{...Xd(k),options:[k,S]}),"selection"!==v&&sp({padding:h}),"selection"===v&&f?(x={...f,padding:h,overflowRef:a,offset:i,minItemsVisible:4,referenceOverflowThreshold:h,onFallbackChange(e){var t,n;if(!e)return;let r=_.elements.floating;if(!r)return;let i=parseFloat(getComputedStyle(r).scrollPaddingBottom)||0,a=Math.min(4,r.childElementCount),s=0,l=0;for(let o of null!=(n=null==(t=_.elements.floating)?void 0:t.childNodes)?n:[])if(o instanceof HTMLElement){let e=o.offsetTop,t=e+o.clientHeight+i,n=r.scrollTop,c=n+r.clientHeight;if(!(e>=n&&t<=c)){l=Math.max(0,Math.min(t,c)-Math.max(e,n)),s=o.clientHeight;break}a--}a>=1&&o((e=>{let t=s*a-l+i;return e>=t?e:t}))}},{name:"inner",options:x,async fn(e){const{listRef:t,overflowRef:n,onFallbackChange:r,offset:i=0,index:o=0,minItemsVisible:a=4,referenceOverflowThreshold:s=0,scrollRef:l,...c}=bd(x,e),{rects:u,elements:{floating:d}}=e,p=t.current[o],h=(null==l?void 0:l.current)||d,f=d.clientTop||h.clientTop,v=0!==d.clientTop,m=0!==h.clientTop,g=d===h;if(!p)return{};const y={...e,...await ap(-p.offsetTop-d.clientTop-u.reference.height/2-p.offsetHeight/2-i).fn(e)},_=await Qd(Ep(y,h.scrollHeight+f+d.clientTop),c),w=await Qd(y,{...c,elementContext:"reference"}),b=fd(0,_.top),k=y.y+b,S=h.scrollHeight>h.clientHeight,E=(S?e=>e:vd)(fd(0,h.scrollHeight+(v&&g||m?2*f:0)-b-fd(0,_.bottom)));if(h.style.maxHeight=E+"px",h.scrollTop=b,r){const e=S&&h.offsetHeight<p.offsetHeight*a-1||w.top>=-s||w.bottom>=-s;Gr((()=>r(e)))}return n&&(n.current=await Qd(Ep({...y,y:k},h.offsetHeight+f+d.clientTop),c)),{y:k}}}):null,lp({padding:h,apply({availableWidth:e,availableHeight:t,elements:n}){Object.assign(n.floating.style,{overflow:"auto",maxWidth:`${e}px`,maxHeight:`min(var(--anchor-max-height, 100vh), ${t}px)`})}})].filter(Boolean),whileElementsMounted:Vd}),[w=v,b=m]=_.placement.split("-");var x,k,S;"selection"===v&&(w="selection");let E=It((()=>({anchor:[w,b].filter(Boolean).join(" ")})),[w,b]),C=Cp(_,{overflowRef:a,onChange:o}),{getReferenceProps:T,getFloatingProps:P}=function(e){void 0===e&&(e=[]);const t=e.map((e=>null==e?void 0:e.reference)),n=e.map((e=>null==e?void 0:e.floating)),r=e.map((e=>null==e?void 0:e.item)),i=Dt((t=>Sp(t,e,"reference")),t),o=Dt((t=>Sp(t,e,"floating")),n),a=Dt((t=>Sp(t,e,"item")),r);return It((()=>({getReferenceProps:i,getFloatingProps:o,getItemProps:a})),[i,o,a])}([C]),R=Pc((e=>{l(e),g.setFloating(e)}));return De(Pp.Provider,{value:r},De(Tp.Provider,{value:{setFloating:R,setReference:g.setReference,styles:y,getReferenceProps:T,getFloatingProps:P,slot:E}},e))}function Ap(e,t,n=void 0){let r=Ec(),i=Pc(((e,t)=>{if(null==e)return[n,null];if("number"==typeof e)return[e,null];if("string"==typeof e){if(!t)return[n,null];let i=Lp(e,t);return[i,n=>{let o=Op(e);{let a=o.map((e=>window.getComputedStyle(t).getPropertyValue(e)));r.requestAnimationFrame((function s(){r.nextFrame(s);let l=!1;for(let[e,n]of o.entries()){let r=window.getComputedStyle(t).getPropertyValue(n);if(a[e]!==r){a[e]=r,l=!0;break}}if(!l)return;let c=Lp(e,t);i!==c&&(n(c),i=c)}))}return r.dispose}]}return[n,null]})),o=It((()=>i(e,t)[0]),[e,t]),[a=o,s]=Rt();return Cc((()=>{let[n,r]=i(e,t);if(s(n),r)return r(s)}),[e,t]),a}function Op(e){let t=/var\((.*)\)/.exec(e);if(t){let e=t[1].indexOf(",");if(-1===e)return[t[1]];let n=t[1].slice(0,e).trim(),r=t[1].slice(e+1).trim();return r?[n,...Op(r)]:[n]}return[]}function Lp(e,t){let n=document.createElement("div");t.appendChild(n),n.style.setProperty("margin-top","0px","important"),n.style.setProperty("margin-top",e,"important");let r=parseFloat(window.getComputedStyle(n).marginTop)||0;return t.removeChild(n),r}let Mp=at(null);Mp.displayName="OpenClosedContext";var Fp=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(Fp||{});function Ip(){return Gt(Mp)}function Dp({value:e,children:t}){return qr.createElement(Mp.Provider,{value:e},t)}var Gp,Np=((Gp=Np||{})[Gp.First=0]="First",Gp[Gp.Previous=1]="Previous",Gp[Gp.Next=2]="Next",Gp[Gp.Last=3]="Last",Gp[Gp.Specific=4]="Specific",Gp[Gp.Nothing=5]="Nothing",Gp);function $p(e,t){let n=t.resolveItems();if(n.length<=0)return null;let r=t.resolveActiveIndex(),i=null!=r?r:-1;switch(e.focus){case 0:for(let e=0;e<n.length;++e)if(!t.resolveDisabled(n[e],e,n))return e;return r;case 1:-1===i&&(i=n.length);for(let e=i-1;e>=0;--e)if(!t.resolveDisabled(n[e],e,n))return e;return r;case 2:for(let e=i+1;e<n.length;++e)if(!t.resolveDisabled(n[e],e,n))return e;return r;case 3:for(let e=n.length-1;e>=0;--e)if(!t.resolveDisabled(n[e],e,n))return e;return r;case 4:for(let r=0;r<n.length;++r)if(t.resolveId(n[r],r,n)===e.id)return r;return r;case 5:return null;default:!function(e){throw new Error("Unexpected object: "+e)}(e)}}function Hp(){let e=function(){let e="undefined"==typeof document;return"useSyncExternalStore"in Kr&&(e=>e.useSyncExternalStore)(Kr)((()=>()=>{}),(()=>!1),(()=>!e))}(),[t,n]=Rt(bc.isHandoffComplete);return t&&!1===bc.isHandoffComplete&&n(!1),Ot((()=>{!0!==t&&n(!0)}),[t]),Ot((()=>bc.handoff()),[]),!e&&t}let Wp=at(!1);function Up(e){let t=Gt(Wp),n=Gt(qp),r=Iu(e),[i,o]=Rt((()=>{var e;if(!t&&null!==n)return null!=(e=n.current)?e:null;if(bc.isServer)return null;let i=null==r?void 0:r.getElementById("headlessui-portal-root");if(i)return i;if(null===r)return null;let o=r.createElement("div");return o.setAttribute("id","headlessui-portal-root"),r.body.appendChild(o)}));return Ot((()=>{null!==i&&(null!=r&&r.body.contains(i)||null==r||r.body.appendChild(i))}),[i,r]),Ot((()=>{t||null!==n&&o(n.current)}),[n,o,t]),i}let jp=$e,Bp=Uc((function(e,t){let n=e,r=Mt(null),i=Qc(function(e,t=!0){return Object.assign(e,{[Vc]:t})}((e=>{r.current=e})),t),o=Iu(r),a=Up(r),[s]=Rt((()=>{var e;return bc.isServer?null:null!=(e=null==o?void 0:o.createElement("div"))?e:null})),l=Gt(Kp),c=Hp();Cc((()=>{!a||!s||a.contains(s)||(s.setAttribute("data-headlessui-portal",""),a.appendChild(s))}),[a,s]),Cc((()=>{if(s&&l)return l.register(s)}),[l,s]),function(e){let t=Pc(e),n=Mt(!1);Ot((()=>(n.current=!1,()=>{n.current=!0,kc((()=>{n.current&&t()}))})),[t])}((()=>{var e;!a||!s||(s instanceof Node&&a.contains(s)&&a.removeChild(s),a.childNodes.length<=0&&(null==(e=a.parentElement)||e.removeChild(a)))}));let u=Gc();return c&&a&&s?ur(u({ourProps:{ref:i},theirProps:n,slot:{},defaultTag:jp,name:"Portal"}),s):null}));let zp=$e,qp=at(null);let Kp=at(null),Vp=Uc((function(e,t){let n=Qc(t),{enabled:r=!0,...i}=e,o=Gc();return r?qr.createElement(Bp,{...i,ref:n}):o({ourProps:{ref:n},theirProps:i,slot:{},defaultTag:jp,name:"Portal"})})),Qp=Uc((function(e,t){let{target:n,...r}=e,i={ref:Qc(t)},o=Gc();return qr.createElement(qp.Provider,{value:n},o({ourProps:i,theirProps:r,defaultTag:zp,name:"Popover.Group"}))})),Yp=Object.assign(Vp,{Group:Qp});function Xp(e){var t;return!!(e.enter||e.enterFrom||e.enterTo||e.leave||e.leaveFrom||e.leaveTo)||(null!=(t=e.as)?t:rh)!==$e||1===qr.Children.count(e.children)}let Jp=at(null);Jp.displayName="TransitionContext";var Zp=(e=>(e.Visible="visible",e.Hidden="hidden",e))(Zp||{});let eh=at(null);function th(e){return"children"in e?th(e.children):e.current.filter((({el:e})=>null!==e.current)).filter((({state:e})=>"visible"===e)).length>0}function nh(e,t){let n=Tc(e),r=Mt([]),i=function(){let e=Mt(!1);return Cc((()=>(e.current=!0,()=>{e.current=!1})),[]),e}(),o=Ec(),a=Pc(((e,t=Dc.Hidden)=>{let a=r.current.findIndex((({el:t})=>t===e));-1!==a&&(Lc(t,{[Dc.Unmount](){r.current.splice(a,1)},[Dc.Hidden](){r.current[a].state="hidden"}}),o.microTask((()=>{var e;!th(r)&&i.current&&(null==(e=n.current)||e.call(n))})))})),s=Pc((e=>{let t=r.current.find((({el:t})=>t===e));return t?"visible"!==t.state&&(t.state="visible"):r.current.push({el:e,state:"visible"}),()=>a(e,Dc.Unmount)})),l=Mt([]),c=Mt(Promise.resolve()),u=Mt({enter:[],leave:[]}),d=Pc(((e,n,r)=>{l.current.splice(0),t&&(t.chains.current[n]=t.chains.current[n].filter((([t])=>t!==e))),null==t||t.chains.current[n].push([e,new Promise((e=>{l.current.push(e)}))]),null==t||t.chains.current[n].push([e,new Promise((e=>{Promise.all(u.current[n].map((([e,t])=>t))).then((()=>e()))}))]),"enter"===n?c.current=c.current.then((()=>null==t?void 0:t.wait.current)).then((()=>r(n))):r(n)})),p=Pc(((e,t,n)=>{Promise.all(u.current[t].splice(0).map((([e,t])=>t))).then((()=>{var e;null==(e=l.current.shift())||e()})).then((()=>n(t)))}));return It((()=>({children:r,register:s,unregister:a,onStart:d,onStop:p,wait:c,chains:u})),[s,a,r,d,p,u,c])}eh.displayName="NestingContext";let rh=$e,ih=Ic.RenderStrategy;let oh=Uc((function(e,t){let{show:n,appear:r=!1,unmount:i=!0,...o}=e,a=Mt(null),s=Qc(...Xp(e)?[a,t]:null===t?[]:[t]);Hp();let l=Ip();if(void 0===n&&null!==l&&(n=(l&Fp.Open)===Fp.Open),void 0===n)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[c,u]=Rt(n?"visible":"hidden"),d=nh((()=>{n||u("hidden")})),[p,h]=Rt(!0),f=Mt([n]);Cc((()=>{!1!==p&&f.current[f.current.length-1]!==n&&(f.current.push(n),h(!1))}),[f,n]);let v=It((()=>({show:n,appear:r,initial:p})),[n,r,p]);Cc((()=>{n?u("visible"):!th(d)&&null!==a.current&&u("hidden")}),[n,d]);let m={unmount:i},g=Pc((()=>{var t;p&&h(!1),null==(t=e.beforeEnter)||t.call(e)})),y=Pc((()=>{var t;p&&h(!1),null==(t=e.beforeLeave)||t.call(e)})),_=Gc();return qr.createElement(eh.Provider,{value:d},qr.createElement(Jp.Provider,{value:v},_({ourProps:{...m,as:$e,children:qr.createElement(ah,{ref:s,...m,...o,beforeEnter:g,beforeLeave:y})},theirProps:{},defaultTag:$e,features:ih,visible:"visible"===c,name:"Transition"})))})),ah=Uc((function(e,t){var n,r;let{transition:i=!0,beforeEnter:o,afterEnter:a,beforeLeave:s,afterLeave:l,enter:c,enterFrom:u,enterTo:d,entered:p,leave:h,leaveFrom:f,leaveTo:v,...m}=e,[g,y]=Rt(null),_=Mt(null),w=Xp(e),b=Qc(...w?[_,t,y]:null===t?[]:[t]),x=null==(n=m.unmount)||n?Dc.Unmount:Dc.Hidden,{show:k,appear:S,initial:E}=function(){let e=Gt(Jp);if(null===e)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),[C,T]=Rt(k?"visible":"hidden"),P=function(){let e=Gt(eh);if(null===e)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),{register:R,unregister:A}=P;Cc((()=>R(_)),[R,_]),Cc((()=>{if(x===Dc.Hidden&&_.current)return k&&"visible"!==C?void T("visible"):Lc(C,{hidden:()=>A(_),visible:()=>R(_)})}),[C,_,R,A,k,x]);let O=Hp();Cc((()=>{if(w&&O&&"visible"===C&&null===_.current)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")}),[_,C,O,w]);let L=E&&!S,M=S&&k&&E,F=Mt(!1),I=nh((()=>{F.current||(T("hidden"),A(_))}),P),D=Pc((e=>{F.current=!0;let t=e?"enter":"leave";I.onStart(_,t,(e=>{"enter"===e?null==o||o():"leave"===e&&(null==s||s())}))})),G=Pc((e=>{let t=e?"enter":"leave";F.current=!1,I.onStop(_,t,(e=>{"enter"===e?null==a||a():"leave"===e&&(null==l||l())})),"leave"===t&&!th(I)&&(T("hidden"),A(_))}));Ot((()=>{w&&i||(D(k),G(k))}),[k,w,i]);let N=(()=>!(!i||!w||!O||L))(),[,$]=qu(N,g,k,{start:D,end:G}),H=jc({ref:b,className:(null==(r=Oc(m.className,M&&c,M&&u,$.enter&&c,$.enter&&$.closed&&u,$.enter&&!$.closed&&d,$.leave&&h,$.leave&&!$.closed&&f,$.leave&&$.closed&&v,!$.transition&&k&&p))?void 0:r.trim())||void 0,...zu($)}),W=0;"visible"===C&&(W|=Fp.Open),"hidden"===C&&(W|=Fp.Closed),$.enter&&(W|=Fp.Opening),$.leave&&(W|=Fp.Closing);let U=Gc();return qr.createElement(eh.Provider,{value:I},qr.createElement(Dp,{value:W},U({ourProps:H,theirProps:m,defaultTag:rh,features:ih,visible:"visible"===C,name:"Transition.Child"})))})),sh=Uc((function(e,t){let n=null!==Gt(Jp),r=null!==Ip();return qr.createElement(qr.Fragment,null,!n&&r?qr.createElement(oh,{ref:t,...e}):qr.createElement(ah,{ref:t,...e}))})),lh=Object.assign(oh,{Child:sh,Root:oh});let ch=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;function uh(e){var t,n;let r=null!=(t=e.innerText)?t:"",i=e.cloneNode(!0);if(!(i instanceof HTMLElement))return r;let o=!1;for(let s of i.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))s.remove(),o=!0;let a=o?null!=(n=i.innerText)?n:"":r;return ch.test(a)&&(a=a.replace(ch,"")),a}function dh(e){let t=Mt(""),n=Mt("");return Pc((()=>{let r=e.current;if(!r)return"";let i=r.innerText;if(t.current===i)return n.current;let o=function(e){let t=e.getAttribute("aria-label");if("string"==typeof t)return t.trim();let n=e.getAttribute("aria-labelledby");if(n){let e=n.split(" ").map((e=>{let t=document.getElementById(e);if(t){let e=t.getAttribute("aria-label");return"string"==typeof e?e.trim():uh(t).trim()}return null})).filter(Boolean);if(e.length>0)return e.join(", ")}return uh(e).trim()}(r).trim().toLowerCase();return t.current=i,n.current=o,o}))}var ph=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(ph||{}),hh=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(hh||{}),fh=(e=>(e[e.OpenMenu=0]="OpenMenu",e[e.CloseMenu=1]="CloseMenu",e[e.GoToItem=2]="GoToItem",e[e.Search=3]="Search",e[e.ClearSearch=4]="ClearSearch",e[e.RegisterItem=5]="RegisterItem",e[e.UnregisterItem=6]="UnregisterItem",e[e.SetButtonElement=7]="SetButtonElement",e[e.SetItemsElement=8]="SetItemsElement",e))(fh||{});function vh(e,t=e=>e){let n=null!==e.activeItemIndex?e.items[e.activeItemIndex]:null,r=Ru(t(e.items.slice()),(e=>e.dataRef.current.domRef.current)),i=n?r.indexOf(n):null;return-1===i&&(i=null),{items:r,activeItemIndex:i}}let mh={1:e=>1===e.menuState?e:{...e,activeItemIndex:null,menuState:1},0:e=>0===e.menuState?e:{...e,__demoMode:!1,menuState:0},2:(e,t)=>{var n,r,i,o,a;if(1===e.menuState)return e;let s={...e,searchQuery:"",activationTrigger:null!=(n=t.trigger)?n:1,__demoMode:!1};if(t.focus===Np.Nothing)return{...s,activeItemIndex:null};if(t.focus===Np.Specific)return{...s,activeItemIndex:e.items.findIndex((e=>e.id===t.id))};if(t.focus===Np.Previous){let n=e.activeItemIndex;if(null!==n){let o=e.items[n].dataRef.current.domRef,a=$p(t,{resolveItems:()=>e.items,resolveActiveIndex:()=>e.activeItemIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});if(null!==a){let t=e.items[a].dataRef.current.domRef;if((null==(r=o.current)?void 0:r.previousElementSibling)===t.current||null===(null==(i=t.current)?void 0:i.previousElementSibling))return{...s,activeItemIndex:a}}}}else if(t.focus===Np.Next){let n=e.activeItemIndex;if(null!==n){let r=e.items[n].dataRef.current.domRef,i=$p(t,{resolveItems:()=>e.items,resolveActiveIndex:()=>e.activeItemIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});if(null!==i){let t=e.items[i].dataRef.current.domRef;if((null==(o=r.current)?void 0:o.nextElementSibling)===t.current||null===(null==(a=t.current)?void 0:a.nextElementSibling))return{...s,activeItemIndex:i}}}}let l=vh(e),c=$p(t,{resolveItems:()=>l.items,resolveActiveIndex:()=>l.activeItemIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});return{...s,...l,activeItemIndex:c}},3:(e,t)=>{let n=""!==e.searchQuery?0:1,r=e.searchQuery+t.value.toLowerCase(),i=(null!==e.activeItemIndex?e.items.slice(e.activeItemIndex+n).concat(e.items.slice(0,e.activeItemIndex+n)):e.items).find((e=>{var t;return(null==(t=e.dataRef.current.textValue)?void 0:t.startsWith(r))&&!e.dataRef.current.disabled})),o=i?e.items.indexOf(i):-1;return-1===o||o===e.activeItemIndex?{...e,searchQuery:r}:{...e,searchQuery:r,activeItemIndex:o,activationTrigger:1}},4:e=>""===e.searchQuery?e:{...e,searchQuery:"",searchActiveItemIndex:null},5:(e,t)=>{let n=vh(e,(e=>[...e,{id:t.id,dataRef:t.dataRef}]));return{...e,...n}},6:(e,t)=>{let n=vh(e,(e=>{let n=e.findIndex((e=>e.id===t.id));return-1!==n&&e.splice(n,1),e}));return{...e,...n,activationTrigger:1}},7:(e,t)=>e.buttonElement===t.element?e:{...e,buttonElement:t.element},8:(e,t)=>e.itemsElement===t.element?e:{...e,itemsElement:t.element}},gh=at(null);function yh(e){let t=Gt(gh);if(null===t){let t=new Error(`<${e} /> is missing a parent <Menu /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(t,yh),t}return t}function _h(e,t){return Lc(t.type,mh,e,t)}gh.displayName="MenuContext";let wh=$e;let bh=Ic.RenderStrategy|Ic.Static;let xh=$e;let kh=Uc((function(e,t){let{__demoMode:n=!1,...r}=e,i=At(_h,{__demoMode:n,menuState:n?0:1,buttonElement:null,itemsElement:null,items:[],searchQuery:"",activeItemIndex:null,activationTrigger:1}),[{menuState:o,itemsElement:a,buttonElement:s},l]=i,c=Qc(t);Fu(0===o,[s,a],((e,t)=>{l({type:1}),Eu(t,Su.Loose)||(e.preventDefault(),null==s||s.focus())}));let u=Pc((()=>{l({type:1})})),d=It((()=>({open:0===o,close:u})),[o,u]),p={ref:c},h=Gc();return qr.createElement(Rp,null,qr.createElement(gh.Provider,{value:i},qr.createElement(Dp,{value:Lc(o,{0:Fp.Open,1:Fp.Closed})},h({ourProps:p,theirProps:r,slot:d,defaultTag:wh,name:"Menu"}))))})),Sh=Uc((function(e,t){var n;let r=$t(),{id:i=`headlessui-menu-button-${r}`,disabled:o=!1,autoFocus:a=!1,...s}=e,[l,c]=yh("Menu.Button"),u=Gt(Tp).getReferenceProps,d=Qc(t,Gt(Tp).setReference,Pc((e=>c({type:7,element:e})))),p=Pc((e=>{switch(e.key){case eu.Space:case eu.Enter:case eu.ArrowDown:e.preventDefault(),e.stopPropagation(),Gr((()=>c({type:0}))),c({type:2,focus:Np.First});break;case eu.ArrowUp:e.preventDefault(),e.stopPropagation(),Gr((()=>c({type:0}))),c({type:2,focus:Np.Last})}})),h=Pc((e=>{if(e.key===eu.Space)e.preventDefault()})),f=Pc((e=>{var t;if(Kc(e.currentTarget))return e.preventDefault();o||(0===l.menuState?(Gr((()=>c({type:1}))),null==(t=l.buttonElement)||t.focus({preventScroll:!0})):(e.preventDefault(),c({type:0})))})),{isFocusVisible:v,focusProps:m}=yc({autoFocus:a}),{isHovered:g,hoverProps:y}=function(e){let{onHoverStart:t,onHoverChange:n,onHoverEnd:r,isDisabled:i}=e,[o,a]=Rt(!1),s=Mt({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;Ot(gc,[]);let{hoverProps:l,triggerHoverEnd:c}=It((()=>{let e=(e,r)=>{if(s.pointerType=r,i||"touch"===r||s.isHovered||!e.currentTarget.contains(e.target))return;s.isHovered=!0;let o=e.currentTarget;s.target=o,t&&t({type:"hoverstart",target:o,pointerType:r}),n&&n(!0),a(!0)},o=(e,t)=>{if(s.pointerType="",s.target=null,"touch"===t||!s.isHovered)return;s.isHovered=!1;let i=e.currentTarget;r&&r({type:"hoverend",target:i,pointerType:t}),n&&n(!1),a(!1)},l={};return"undefined"!=typeof PointerEvent?(l.onPointerEnter=t=>{hc&&"mouse"===t.pointerType||e(t,t.pointerType)},l.onPointerLeave=e=>{!i&&e.currentTarget.contains(e.target)&&o(e,e.pointerType)}):(l.onTouchStart=()=>{s.ignoreEmulatedMouseEvents=!0},l.onMouseEnter=t=>{s.ignoreEmulatedMouseEvents||hc||e(t,"mouse"),s.ignoreEmulatedMouseEvents=!1},l.onMouseLeave=e=>{!i&&e.currentTarget.contains(e.target)&&o(e,"mouse")}),{hoverProps:l,triggerHoverEnd:o}}),[t,n,r,i,s]);return Ot((()=>{i&&c({currentTarget:s.target},s.pointerType)}),[i]),{hoverProps:l,isHovered:o}}({isDisabled:o}),{pressed:_,pressProps:w}=function({disabled:e=!1}={}){let t=Mt(null),[n,r]=Rt(!1),i=Ec(),o=Pc((()=>{t.current=null,r(!1),i.dispose()})),a=Pc((e=>{if(i.dispose(),null===t.current){t.current=e.currentTarget,r(!0);{let n=xc(e.currentTarget);i.addEventListener(n,"pointerup",o,!1),i.addEventListener(n,"pointermove",(e=>{if(t.current){let n=function(e){let t=e.width/2,n=e.height/2;return{top:e.clientY-n,right:e.clientX+t,bottom:e.clientY+n,left:e.clientX-t}}(e);r(function(e,t){return!(!e||!t||e.right<t.left||e.left>t.right||e.bottom<t.top||e.top>t.bottom)}(n,t.current.getBoundingClientRect()))}}),!1),i.addEventListener(n,"pointercancel",o,!1)}}}));return{pressed:n,pressProps:e?{}:{onPointerDown:a,onPointerUp:o,onClick:o}}}({disabled:o}),b=It((()=>({open:0===l.menuState,active:_||0===l.menuState,disabled:o,hover:g,focus:v,autofocus:a})),[l,g,v,_,o,a]),x=Wc(u(),{ref:d,id:i,type:Du(e,l.buttonElement),"aria-haspopup":"menu","aria-controls":null==(n=l.itemsElement)?void 0:n.id,"aria-expanded":0===l.menuState,disabled:o||void 0,autoFocus:a,onKeyDown:p,onKeyUp:h,onClick:f},m,y,w);return Gc()({ourProps:x,theirProps:s,slot:b,defaultTag:"button",name:"Menu.Button"})})),Eh=Uc((function(e,t){var n,r;let i=$t(),{id:o=`headlessui-menu-items-${i}`,anchor:a,portal:s=!1,modal:l=!0,transition:c=!1,...u}=e,d=function(e){return It((()=>e?"string"==typeof e?{to:e}:e:null),[e])}(a),[p,h]=yh("Menu.Items"),[f,v]=function(e=null){!1===e&&(e=null),"string"==typeof e&&(e={to:e});let t=Gt(Pp),n=It((()=>e),[JSON.stringify(e,((e,t)=>{var n;return null!=(n=null==t?void 0:t.outerHTML)?n:t}))]);Cc((()=>{null==t||t(null!=n?n:null)}),[t,n]);let r=Gt(Tp);return It((()=>[r.setFloating,e?r.styles:{}]),[r.setFloating,e,r.styles])}(d),m=function(){let{getFloatingProps:e,slot:t}=Gt(Tp);return Dt(((...n)=>Object.assign({},e(...n),{"data-anchor":t.anchor})),[e,t])}(),[g,y]=Rt(null),_=Qc(t,d?f:null,Pc((e=>h({type:8,element:e}))),y),w=Iu(p.itemsElement);d&&(s=!0);let b=Ip(),[x,k]=qu(c,g,null!==b?(b&Fp.Open)===Fp.Open:0===p.menuState);!function(e,t,n){let r=Tc((e=>{let t=e.getBoundingClientRect();0===t.x&&0===t.y&&0===t.width&&0===t.height&&n()}));Ot((()=>{if(!e)return;let n=null===t?null:t instanceof HTMLElement?t:t.current;if(!n)return;let i=Sc();if("undefined"!=typeof ResizeObserver){let e=new ResizeObserver((()=>r.current(n)));e.observe(n),i.add((()=>e.disconnect()))}if("undefined"!=typeof IntersectionObserver){let e=new IntersectionObserver((()=>r.current(n)));e.observe(n),i.add((()=>e.disconnect()))}return()=>i.dispose()}),[t,r,e])}(x,p.buttonElement,(()=>{h({type:1})})),Hu(!p.__demoMode&&(l&&0===p.menuState),w),function(e,{allowed:t,disallowed:n}={}){let r=uu(e,"inert-others");Cc((()=>{var e,i;if(!r)return;let o=Sc();for(let t of null!=(e=null==n?void 0:n())?e:[])t&&o.add(hu(t));let a=null!=(i=null==t?void 0:t())?i:[];for(let t of a){if(!t)continue;let e=xc(t);if(!e)continue;let n=t.parentElement;for(;n&&n!==e.body;){for(let e of n.children)a.some((t=>e.contains(t)))||o.add(hu(e));n=n.parentElement}}return o.dispose}),[r,t,n])}(!p.__demoMode&&(l&&0===p.menuState),{allowed:Dt((()=>[p.buttonElement,p.itemsElement]),[p.buttonElement,p.itemsElement])});let S=!function(e,t){let n=Mt({left:0,top:0});if(Cc((()=>{if(!t)return;let e=t.getBoundingClientRect();e&&(n.current=e)}),[e,t]),null==t||!e||t===document.activeElement)return!1;let r=t.getBoundingClientRect();return r.top!==n.current.top||r.left!==n.current.left}(0!==p.menuState,p.buttonElement)&&x;Ot((()=>{let e=p.itemsElement;e&&0===p.menuState&&e!==(null==w?void 0:w.activeElement)&&e.focus({preventScroll:!0})}),[p.menuState,p.itemsElement,w]),function(e,{container:t,accept:n,walk:r}){let i=Mt(n),o=Mt(r);Ot((()=>{i.current=n,o.current=r}),[n,r]),Cc((()=>{if(!t||!e)return;let n=xc(t);if(!n)return;let r=i.current,a=o.current,s=Object.assign((e=>r(e)),{acceptNode:r}),l=n.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,s,!1);for(;l.nextNode();)a(l.currentNode)}),[t,e,i,o])}(0===p.menuState,{container:p.itemsElement,accept:e=>"menuitem"===e.getAttribute("role")?NodeFilter.FILTER_REJECT:e.hasAttribute("role")?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT,walk(e){e.setAttribute("role","none")}});let E=Ec(),C=Pc((e=>{var t,n,r;switch(E.dispose(),e.key){case eu.Space:if(""!==p.searchQuery)return e.preventDefault(),e.stopPropagation(),h({type:3,value:e.key});case eu.Enter:if(e.preventDefault(),e.stopPropagation(),h({type:1}),null!==p.activeItemIndex){let{dataRef:e}=p.items[p.activeItemIndex];null==(n=null==(t=e.current)?void 0:t.domRef.current)||n.click()}Cu(p.buttonElement);break;case eu.ArrowDown:return e.preventDefault(),e.stopPropagation(),h({type:2,focus:Np.Next});case eu.ArrowUp:return e.preventDefault(),e.stopPropagation(),h({type:2,focus:Np.Previous});case eu.Home:case eu.PageUp:return e.preventDefault(),e.stopPropagation(),h({type:2,focus:Np.First});case eu.End:case eu.PageDown:return e.preventDefault(),e.stopPropagation(),h({type:2,focus:Np.Last});case eu.Escape:e.preventDefault(),e.stopPropagation(),Gr((()=>h({type:1}))),null==(r=p.buttonElement)||r.focus({preventScroll:!0});break;case eu.Tab:e.preventDefault(),e.stopPropagation(),Gr((()=>h({type:1}))),Au(p.buttonElement,e.shiftKey?wu.Previous:wu.Next);break;default:1===e.key.length&&(h({type:3,value:e.key}),E.setTimeout((()=>h({type:4})),350))}})),T=Pc((e=>{if(e.key===eu.Space)e.preventDefault()})),P=It((()=>({open:0===p.menuState})),[p.menuState]),R=Wc(d?m():{},{"aria-activedescendant":null===p.activeItemIndex||null==(n=p.items[p.activeItemIndex])?void 0:n.id,"aria-labelledby":null==(r=p.buttonElement)?void 0:r.id,id:o,onKeyDown:C,onKeyUp:T,role:"menu",tabIndex:0===p.menuState?0:void 0,ref:_,style:{...u.style,...v,"--button-width":ou(p.buttonElement,!0).width},...zu(k)}),A=Gc();return qr.createElement(Yp,{enabled:!!s&&(e.static||x)},A({ourProps:R,theirProps:u,slot:P,defaultTag:"div",features:bh,visible:S,name:"Menu.Items"}))})),Ch=Uc((function(e,t){let n=$t(),{id:r=`headlessui-menu-item-${n}`,disabled:i=!1,...o}=e,[a,s]=yh("Menu.Item"),l=null!==a.activeItemIndex&&a.items[a.activeItemIndex].id===r,c=Mt(null),u=Qc(t,c);Cc((()=>{if(!a.__demoMode&&0===a.menuState&&l&&0!==a.activationTrigger)return Sc().requestAnimationFrame((()=>{var e,t;null==(t=null==(e=c.current)?void 0:e.scrollIntoView)||t.call(e,{block:"nearest"})}))}),[a.__demoMode,c,l,a.menuState,a.activationTrigger,a.activeItemIndex]);let d=dh(c),p=Mt({disabled:i,domRef:c,get textValue(){return d()}});Cc((()=>{p.current.disabled=i}),[p,i]),Cc((()=>(s({type:5,id:r,dataRef:p}),()=>s({type:6,id:r}))),[p,r]);let h=Pc((()=>{s({type:1})})),f=Pc((e=>{if(i)return e.preventDefault();s({type:1}),Cu(a.buttonElement)})),v=Pc((()=>{if(i)return s({type:2,focus:Np.Nothing});s({type:2,focus:Np.Specific,id:r})})),m=function(){let e=Mt([-1,-1]);return{wasMoved(t){let n=Wu(t);return(e.current[0]!==n[0]||e.current[1]!==n[1])&&(e.current=n,!0)},update(t){e.current=Wu(t)}}}(),g=Pc((e=>{m.update(e),!i&&(l||s({type:2,focus:Np.Specific,id:r,trigger:0}))})),y=Pc((e=>{m.wasMoved(e)&&(i||l||s({type:2,focus:Np.Specific,id:r,trigger:0}))})),_=Pc((e=>{m.wasMoved(e)&&(i||l&&s({type:2,focus:Np.Nothing}))})),[w,b]=ru(),[x,k]=function(){let[e,t]=Rt([]);return[e.length>0?e.join(" "):void 0,It((()=>function(e){let n=Pc((e=>(t((t=>[...t,e])),()=>t((t=>{let n=t.slice(),r=n.indexOf(e);return-1!==r&&n.splice(r,1),n}))))),r=It((()=>({register:n,slot:e.slot,name:e.name,props:e.props,value:e.value})),[n,e.slot,e.name,e.props,e.value]);return qr.createElement(Yc.Provider,{value:r},e.children)}),[t])]}(),S=It((()=>({active:l,focus:l,disabled:i,close:h})),[l,i,h]),E={id:r,ref:u,role:"menuitem",tabIndex:!0===i?void 0:-1,"aria-disabled":!0===i||void 0,"aria-labelledby":w,"aria-describedby":x,disabled:void 0,onClick:f,onFocus:v,onPointerEnter:g,onMouseEnter:g,onPointerMove:y,onMouseMove:y,onPointerLeave:_,onMouseLeave:_},C=Gc();return qr.createElement(b,null,qr.createElement(k,null,C({ourProps:E,theirProps:o,slot:S,defaultTag:xh,name:"Menu.Item"})))})),Th=Uc((function(e,t){let[n,r]=ru(),i=e,o={ref:t,"aria-labelledby":n,role:"group"},a=Gc();return qr.createElement(r,null,a({ourProps:o,theirProps:i,slot:{},defaultTag:"div",name:"Menu.Section"}))})),Ph=Uc((function(e,t){let n=$t(),{id:r=`headlessui-menu-heading-${n}`,...i}=e,o=nu();Cc((()=>o.register(r)),[r,o.register]);let a={id:r,ref:t,role:"presentation",...o.props};return Gc()({ourProps:a,theirProps:i,slot:{},defaultTag:"header",name:"Menu.Heading"})})),Rh=Uc((function(e,t){let n=e,r={ref:t,role:"separator"};return Gc()({ourProps:r,theirProps:n,slot:{},defaultTag:"div",name:"Menu.Separator"})})),Ah=Object.assign(kh,{Button:Sh,Items:Eh,Item:Ch,Section:Th,Heading:Ph,Separator:Rh});function Oh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8.625 12a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0H8.25m4.125 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0H12m4.125 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0h-.375M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"}))}const Lh=Yn(Oh);function Mh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z"}))}const Fh=Yn(Mh),Ih=e=>Dl(Hh,{children:Gl(Ah,{as:"div",children:[Dl("div",{children:Gl(Sh,{css:{display:"flex",alignItems:"center",borderRadius:"9999px","--tw-bg-opacity":"1",backgroundColor:"rgb(243 244 246 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(156 163 175 / var(--tw-text-opacity))",":hover":{"--tw-text-opacity":"1",color:"rgb(75 85 99 / var(--tw-text-opacity))"},":focus":{outline:"2px solid transparent",outlineOffset:"2px","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-opacity":"1","--tw-ring-color":"rgb(99 102 241 / var(--tw-ring-opacity))","--tw-ring-offset-width":"2px","--tw-ring-offset-color":"#f3f4f6"}},children:[Dl("span",{css:{position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"},children:"Open options"}),Dl(Lh,{"aria-hidden":"true",css:{width:"1.25rem",height:"1.25rem"}})]})}),Dl(Eh,{transition:!0,className:"right-45 w-30",css:{position:"fixed",zIndex:"10",marginTop:"0.5rem",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))","--tw-shadow":"0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)","--tw-shadow-colored":"0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)","--tw-ring-color":"rgb(0 0 0 / 0.05)",transitionProperty:"color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"150ms",":focus":{outline:"2px solid transparent",outlineOffset:"2px"},"&[data-closed]":{"--tw-scale-x":".95","--tw-scale-y":".95",transform:"translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))",opacity:"0"},"&[data-enter]":{transitionDuration:"100ms",transitionTimingFunction:"cubic-bezier(0, 0, 0.2, 1)"},"&[data-leave]":{transitionDuration:"75ms",transitionTimingFunction:"cubic-bezier(0.4, 0, 1, 1)"}},children:e.items.map(((t,n)=>Dl(Ch,{children:Dl("button",{type:"button",css:{display:"block",paddingLeft:"1rem",paddingRight:"1rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))","&[data-focus]":{"--tw-bg-opacity":"1",backgroundColor:"rgb(243 244 246 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))",outline:"2px solid transparent",outlineOffset:"2px"}},onClick:()=>{t.onClick(e.id)},children:t.label},n)},n)))})]})}),Dh=e=>e&&new Date(e).toLocaleDateString("en-AU")||void 0,Gh=e=>void 0!==e&&`$ ${Number(e).toLocaleString("en-US")}`||void 0,Nh=e=>Gl(Hh,{children:[Dh(e.value),Dl("br",{}),Dh(e.value)]}),$h=e=>{const[t,n]=Rt(!1);return Gl(Hh,{css:{position:"relative"},children:[Dl(lh,{show:t,children:Dl("div",{css:{position:"absolute",bottom:"3rem",display:"flex",height:"2rem",width:"4.313rem",flexDirection:"row",alignItems:"flex-start",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(17 24 39 / var(--tw-bg-opacity))",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",opacity:"0.9","--tw-shadow":"0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)","--tw-shadow-colored":"0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",transitionProperty:"opacity",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"150ms","&[data-closed]":{opacity:"0"},"&[data-enter]":{transitionDuration:"100ms",transitionTimingFunction:"cubic-bezier(0.4, 0, 1, 1)"},"&[data-leave]":{transitionDuration:"500ms",transitionTimingFunction:"cubic-bezier(0, 0, 0.2, 1)"}},children:Dl("p",{css:{order:"0",height:"1rem",width:"2.813rem",flex:"none",flexGrow:"0",fontSize:"0.75rem",lineHeight:"1rem",fontWeight:"500",fontStyle:"normal","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))"},children:"Copied"})})}),Dl("button",{onClick:async()=>{await(async e=>{await navigator.clipboard.writeText(e)})(e.value),n(!0),setTimeout((()=>{n(!1)}),3e3)},type:"button",css:{display:"block",flexShrink:"1",borderRadius:"0.375rem",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(209 213 219 / var(--tw-bg-opacity))"},"&[data-focus]":{"--tw-bg-opacity":"1",backgroundColor:"rgb(243 244 246 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))",outline:"2px solid transparent",outlineOffset:"2px"}},children:e.value})]})},Hh=Ll.td`
12
12
  ${{whiteSpace:"nowrap",paddingTop:"1rem",paddingBottom:"1rem",paddingLeft:"1rem",paddingRight:"0.75rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"}}
13
- `,Uh=Ml.td`
13
+ `,Wh=Ll.td`
14
14
  ${{whiteSpace:"nowrap",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"1.25rem",paddingBottom:"1.25rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"}}
15
- `,jh=Ml.span({display:"inline-flex",alignItems:"center",borderRadius:"0.375rem",paddingLeft:"0.5rem",paddingRight:"0.5rem",paddingTop:"0.25rem",paddingBottom:"0.25rem",fontSize:"0.75rem",lineHeight:"1rem",fontWeight:"500","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-inset":"inset"},(e=>e.className)),Bh=(e,t,n,r)=>{var i;switch(null==r?void 0:r.kind){case"status":return Gl(Uh,{children:Gl(jh,{className:null==(i=r.styleOverrides)?void 0:i[t],children:t})});case"date":return Gl($h,{value:t});case"button":return Gl(Wl,{id:e,value:t,onClick:r.onClick,children:r.children});case"list":return Gl(Ul,{value:t,navTo:r.navTo&&r.navTo(n,t)});case"menu":return Gl(Dh,{id:e,items:r.items});case"copy":return Gl(Hh,{value:t});default:return Gl(Wh,{children:t})}};function zh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{fillRule:"evenodd",d:"M10 3a.75.75 0 0 1 .75.75v10.638l3.96-4.158a.75.75 0 1 1 1.08 1.04l-5.25 5.5a.75.75 0 0 1-1.08 0l-5.25-5.5a.75.75 0 1 1 1.08-1.04l3.96 4.158V3.75A.75.75 0 0 1 10 3Z",clipRule:"evenodd"}))}const qh=Yn(zh);function Kh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{fillRule:"evenodd",d:"M10 17a.75.75 0 0 1-.75-.75V5.612L5.29 9.77a.75.75 0 0 1-1.08-1.04l5.25-5.5a.75.75 0 0 1 1.08 0l5.25 5.5a.75.75 0 1 1-1.08 1.04l-3.96-4.158V16.25A.75.75 0 0 1 10 17Z",clipRule:"evenodd"}))}const Vh=Yn(Kh);function Qh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{fillRule:"evenodd",d:"M18 10a8 8 0 1 1-16 0 8 8 0 0 1 16 0Zm-8-5a.75.75 0 0 1 .75.75v4.5a.75.75 0 0 1-1.5 0v-4.5A.75.75 0 0 1 10 5Zm0 10a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z",clipRule:"evenodd"}))}const Yh=Yn(Qh),Xh=Ml.button({marginRight:"1rem",display:"inline-flex",alignItems:"center",borderRadius:"0.375rem",paddingLeft:"0.5rem",paddingRight:"0.5rem",paddingTop:"0.25rem",paddingBottom:"0.25rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"700","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},(e=>e.className),(({isActive:e})=>e&&{"--tw-bg-opacity":"1",backgroundColor:"rgb(229 231 235 / var(--tw-bg-opacity))"})),Jh=Ml.input`
15
+ `,Uh=Ll.span({display:"inline-flex",alignItems:"center",borderRadius:"0.375rem",paddingLeft:"0.5rem",paddingRight:"0.5rem",paddingTop:"0.25rem",paddingBottom:"0.25rem",fontSize:"0.75rem",lineHeight:"1rem",fontWeight:"500","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-inset":"inset"},(e=>e.className)),jh=(e,t,n,r)=>{var i;switch(null==r?void 0:r.kind){case"status":return Dl(Wh,{children:Dl(Uh,{className:null==(i=r.styleOverrides)?void 0:i[t],children:t})});case"date":return Dl(Nh,{value:t});case"button":return Dl(Hl,{id:e,value:t,onClick:r.onClick,children:r.children});case"list":return Dl(Wl,{value:t,navTo:r.navTo&&r.navTo(n,t)});case"menu":return Dl(Ih,{id:e,items:r.items});case"copy":return Dl($h,{value:t});default:return Dl(Hh,{children:t})}};function Bh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{fillRule:"evenodd",d:"M10 3a.75.75 0 0 1 .75.75v10.638l3.96-4.158a.75.75 0 1 1 1.08 1.04l-5.25 5.5a.75.75 0 0 1-1.08 0l-5.25-5.5a.75.75 0 1 1 1.08-1.04l3.96 4.158V3.75A.75.75 0 0 1 10 3Z",clipRule:"evenodd"}))}const zh=Yn(Bh);function qh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{fillRule:"evenodd",d:"M10 17a.75.75 0 0 1-.75-.75V5.612L5.29 9.77a.75.75 0 0 1-1.08-1.04l5.25-5.5a.75.75 0 0 1 1.08 0l5.25 5.5a.75.75 0 1 1-1.08 1.04l-3.96-4.158V16.25A.75.75 0 0 1 10 17Z",clipRule:"evenodd"}))}const Kh=Yn(qh);function Vh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{fillRule:"evenodd",d:"M18 10a8 8 0 1 1-16 0 8 8 0 0 1 16 0Zm-8-5a.75.75 0 0 1 .75.75v4.5a.75.75 0 0 1-1.5 0v-4.5A.75.75 0 0 1 10 5Zm0 10a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z",clipRule:"evenodd"}))}const Qh=Yn(Vh),Yh=Ll.button({marginRight:"1rem",display:"inline-flex",alignItems:"center",borderRadius:"0.375rem",paddingLeft:"0.5rem",paddingRight:"0.5rem",paddingTop:"0.25rem",paddingBottom:"0.25rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"700","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},(e=>e.className),(({isActive:e})=>e&&{"--tw-bg-opacity":"1",backgroundColor:"rgb(229 231 235 / var(--tw-bg-opacity))"})),Xh=Ll.input`
16
16
  ${()=>({display:"block",minHeight:"2.25rem",width:"100%",borderRadius:"0.375rem",borderWidth:"0px",paddingTop:"0.375rem",paddingBottom:"0.375rem",paddingRight:"5rem",fontSize:"1rem",lineHeight:"1.5rem","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-inset":"inset","::placeholder":{"--tw-text-opacity":"1",color:"rgb(156 163 175 / var(--tw-text-opacity))"},":focus":{"--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-inset":"inset"},":disabled":{"--tw-bg-opacity":"1",backgroundColor:"rgb(229 231 235 / var(--tw-bg-opacity))"},"@media (min-width: 640px)":{fontSize:"0.875rem",lineHeight:"1.5rem"}})}
17
17
 
18
18
  ${({prefix:e})=>e?{paddingLeft:"2.5rem"}:{paddingLeft:"0.75rem"}}
19
19
 
20
20
  ${({hasError:e})=>e?{"--tw-ring-opacity":"1","--tw-ring-color":"rgb(252 165 165 / var(--tw-ring-opacity))",":focus":{"--tw-ring-opacity":"1","--tw-ring-color":"rgb(220 38 38 / var(--tw-ring-opacity))"}}:{"--tw-ring-opacity":"1","--tw-ring-color":"rgb(209 213 219 / var(--tw-ring-opacity))",":focus":{"--tw-ring-color":"var(--fl-color-primary-600)"}}}
21
- `;function Zh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{fillRule:"evenodd",d:"M5.47 5.47a.75.75 0 0 1 1.06 0L12 10.94l5.47-5.47a.75.75 0 1 1 1.06 1.06L13.06 12l5.47 5.47a.75.75 0 1 1-1.06 1.06L12 13.06l-5.47 5.47a.75.75 0 0 1-1.06-1.06L10.94 12 5.47 6.53a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"}))}const ef=Yn(Zh),tf=Yn((({label:e,id:t,type:n,icon:r,placeholder:i,setPlaceholderOnFocus:o,value:a,className:s,onChange:l,onBlur:c,onEnter:u,error:d,helperText:p,disabled:h,remove:f},v)=>Nl("div",{className:s,children:[e&&Gl("label",{htmlFor:t,css:{position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"},children:e}),Nl("div",{css:{position:"relative",marginTop:"0.5rem"},children:[r&&Gl("span",{css:{position:"absolute",marginLeft:"0.5rem",marginTop:"0.5rem"},children:r}),Nl("div",{css:{marginTop:"0.5rem",display:"flex",alignItems:"center"},children:[Gl(Jh,{type:n,value:a,name:t,id:t,placeholder:i,onChange:e=>{const t=e;t.target instanceof HTMLInputElement&&l(t.target.value.trim())},onBlur:e=>{const t=e;t.target instanceof HTMLInputElement&&c&&c(t.target.value.trim())},onFocus:()=>{i&&o&&!(null==a?void 0:a.trim())&&l(i)},onKeyDown:e=>{"Enter"===e.key&&u&&u()},hasError:!!d,ref:v,disabled:h,prefix:!!r}),f&&Nl("button",{type:"button",children:[Gl(ef,{css:{marginLeft:"0.5rem",height:"1.25rem",width:"1.25rem"},onClick:()=>f()})," "]})]})]}),d&&Gl("p",{css:{marginTop:"0.5rem",marginBottom:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(220 38 38 / var(--tw-text-opacity))"},children:d}),p&&Gl("span",{css:{fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:p})]}))),nf="asc",rf="desc",of=e=>{var t,n;const[r,i]=Rt(""),[o,a]=Rt([]),[s,l]=Rt(e.columns[0]),[c,u]=Rt(nf),d=It((()=>s?[...e.data].sort(((e,t)=>{const n=s.sort?s.sort(e[s.field],t[s.field]):e[s.field].localeCompare(t[s.field]);return c===rf?-1*n:n})):e.data),[e.data,s,c]),p=It((()=>{const t=o.reduce(((e,t)=>e.filter(t.filterFunction)),d);return r&&!e.searchButton?t.filter((e=>e.id.toLowerCase().includes(r.toLowerCase()))):t}),[d,r,o,e.searchButton]),h=It((()=>e.columns.filter((e=>e.filters&&e.filters.length>0)).length>0),[e.columns]),f=()=>{e.searchButton&&e.searchButton.onClick(r)},v=(e,t)=>{const n={name:e.name,filterFunction:n=>e.predicate(n[t.field])},r=o.filter((e=>e.name!==n.name));return()=>r.length<o.length?a([...r]):a([...r,n])};return Gl(Dl,{children:Nl("div",{css:{paddingLeft:"1rem",paddingRight:"1rem","@media (min-width: 640px)":{paddingLeft:"1.5rem",paddingRight:"1.5rem"},"@media (min-width: 1024px)":{paddingLeft:"2rem",paddingRight:"2rem"}},children:[Nl("div",{css:{"@media (min-width: 640px)":{display:"flex",alignItems:"center"}},children:[Nl("div",{css:{"@media (min-width: 640px)":{flex:"1 1 auto"}},children:[Gl("h1",{css:{fontSize:"1rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:e.title}),e.subtitle&&Gl("p",{css:{marginTop:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"},children:e.subtitle}),Nl("div",{css:{marginTop:"0.5rem",display:"inline-flex"},children:[Gl(tf,{css:{marginTop:"auto",marginBottom:"auto",maxWidth:"20rem"},label:null==(t=e.searchButton)?void 0:t.text,icon:Gl(Ih,{css:{height:"1.25rem",width:"1.25rem","--tw-text-opacity":"1",color:"rgb(156 163 175 / var(--tw-text-opacity))"}}),id:"search",type:"text",error:null==(n=e.searchButton)?void 0:n.error,onChange:e=>i(e),onEnter:f}),e.searchButton&&Gl("div",{css:{marginLeft:"1rem",marginTop:"0.5rem"},children:Gl("button",{type:"button",onClick:f,css:{display:"block",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",textAlign:"center",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))","--tw-shadow":"0 1px 2px 0 rgb(0 0 0 / 0.05)","--tw-shadow-colored":"0 1px 2px 0 var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(99 102 241 / var(--tw-bg-opacity))"},":focus-visible":{outlineStyle:"solid",outlineWidth:"2px",outlineOffset:"2px",outlineColor:"#4f46e5"}},children:e.searchButton.text})})]})]}),e.addButton&&Gl("div",{css:{marginTop:"1rem","@media (min-width: 640px)":{marginLeft:"4rem",marginTop:"0px",flex:"none"}},children:Gl("button",{type:"button",onClick:e.addButton.onClick,css:{display:"block",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",textAlign:"center",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))","--tw-shadow":"0 1px 2px 0 rgb(0 0 0 / 0.05)","--tw-shadow-colored":"0 1px 2px 0 var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(99 102 241 / var(--tw-bg-opacity))"},":focus-visible":{outlineStyle:"solid",outlineWidth:"2px",outlineOffset:"2px",outlineColor:"#4f46e5"}},children:e.addButton.text})})]}),e.error&&Gl("div",{css:{marginBottom:"1rem",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(254 242 242 / var(--tw-bg-opacity))",padding:"1rem"},children:Nl("div",{css:{display:"flex"},children:[Gl("div",{css:{flexShrink:"0"},children:Gl(Yh,{css:{height:"1.25rem",width:"1.25rem","--tw-text-opacity":"1",color:"rgb(248 113 113 / var(--tw-text-opacity))"},"aria-hidden":"true"})}),Gl("div",{css:{marginLeft:"0.75rem"},children:Gl("h3",{css:{fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(153 27 27 / var(--tw-text-opacity))"},children:e.error})})]})}),Gl("div",{css:{marginTop:"2rem",display:"flow-root"},children:Gl("div",{css:{marginLeft:"-1rem",marginRight:"-1rem",marginTop:"-0.5rem",marginBottom:"-0.5rem",overflowX:"auto","@media (min-width: 640px)":{marginLeft:"-1.5rem",marginRight:"-1.5rem"},"@media (min-width: 1024px)":{marginLeft:"-2rem",marginRight:"-2rem"}},children:Gl("div",{css:{display:"inline-block",minWidth:"100%",paddingTop:"0.5rem",paddingBottom:"0.5rem",verticalAlign:"middle","@media (min-width: 640px)":{paddingLeft:"1.5rem",paddingRight:"1.5rem"},"@media (min-width: 1024px)":{paddingLeft:"2rem",paddingRight:"2rem"}},children:Gl("div",{css:{overflow:"hidden","--tw-shadow":"0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1)","--tw-shadow-colored":"0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)","--tw-ring-opacity":"0.05","--tw-ring-color":"rgb(0 0 0 / var(--tw-ring-opacity))","@media (min-width: 640px)":{borderRadius:"0.5rem"}},children:Nl("table",{css:{minWidth:"100%","> :not([hidden]) ~ :not([hidden])":{"--tw-divide-y-reverse":"0",borderTopWidth:"calc(1px * calc(1 - var(--tw-divide-y-reverse)))",borderBottomWidth:"calc(1px * var(--tw-divide-y-reverse))","--tw-divide-opacity":"1",borderColor:"rgb(209 213 219 / var(--tw-divide-opacity))"}},children:[h&&Gl("thead",{children:Gl("tr",{children:Nl("td",{css:{padding:"1rem"},colSpan:e.columns.length,children:[Gl(Xh,{onClick:()=>a([]),isActive:0==o.length,children:"All"}),e.columns.map((e=>{var t;return null==(t=e.filters)?void 0:t.map((t=>Gl(Xh,{onClick:v(t,e),isActive:!!o.find((e=>e.name===t.name)),children:t.name},t.name)))}))]})})}),Gl("thead",{css:{"--tw-bg-opacity":"1",backgroundColor:"rgb(249 250 251 / var(--tw-bg-opacity))"},children:Gl("tr",{children:e.columns.map((e=>Gl("th",{scope:"col",css:{paddingTop:"0.875rem",paddingBottom:"0.875rem",paddingLeft:"1rem",paddingRight:"0.75rem",textAlign:"left",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:Nl("button",{disabled:!e.isSortable,onClick:()=>(e=>{s===e?u(c===nf?rf:nf):(l(e),u(nf))})(e),css:{display:"inline-flex"},children:[Gl("span",{children:e.name}),Nl("span",{css:{marginLeft:"0.5rem"},children:[s===e&&c===nf&&Gl(qh,{css:{height:"1.25rem",width:"1.25rem"}}),s===e&&c===rf&&Gl(Vh,{css:{height:"1.25rem",width:"1.25rem"}}),s!==e&&Gl("svg",{css:{height:"1.25rem",width:"1.25rem"}})]})]})},e.field)))})}),Gl("tbody",{css:{"> :not([hidden]) ~ :not([hidden])":{"--tw-divide-y-reverse":"0",borderTopWidth:"calc(1px * calc(1 - var(--tw-divide-y-reverse)))",borderBottomWidth:"calc(1px * var(--tw-divide-y-reverse))","--tw-divide-opacity":"1",borderColor:"rgb(229 231 235 / var(--tw-divide-opacity))"},"--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))"},children:p.map(((t,n)=>Gl("tr",{children:e.columns.map(((e,r)=>Gl($e,{children:Bh(t.id,t[e.field],t,e.type)},`${t[e.field]}-${n}-${r}`)))},`${t[e.columns[0].field]}-${n}`)))})]})})})})})]})})},af=[{name:"Profile Id",field:"id",isSortable:!0,type:{kind:"copy"}},{name:"Name",field:"name",isSortable:!0},{name:"Email",field:"email",isSortable:!0},{name:"External Id",field:"externalId",isSortable:!0},{name:"Catch-E Driver Id",field:"catchEId",isSortable:!0}],sf=async e=>{if(!(e instanceof li))return"Unexpected error occurred";try{return(await e.response.json()).message||`${e.response.status} error occurred`}catch{return`${e.response.status} error occurred`}},lf=()=>{const[e,t]=Rt(""),[n,r]=Rt(""),{searchProfilesForAccount:i}=Ai(),o=["searchProfilesForAccount",si().account.accountId];const{data:a,refetch:s,error:l,isFetched:c,isRefetching:u}=oi({queryKey:o,queryFn:()=>i(e),enabled:!1,retry:!1});Ot((()=>{e&&s()}),[e,s]),Ot((()=>{l?(async()=>{r(await sf(l))})():r("")}),[l]),Ot((()=>{c&&0===(null==a?void 0:a.length)&&r("No profiles found"),u&&r("")}),[u,c,a]);return Gl(of,{columns:af,data:a||[],title:"Profile Search",subtitle:"Search for a profile using name or email",searchButton:{onClick:e=>{t(e)},text:"Search",error:n}})},cf=e=>({id:e.id,catchEDriverId:e.catchEDriverId,salaryPackagedItems:e.salaryPackagedItems.map((e=>e.catchEContractId)).join(",")}),uf=e=>[{name:"Profile Id",field:"id",isSortable:!0,type:{kind:"copy"}},{name:"Catch-E Driver Id",field:"catchEDriverId",isSortable:!0},{name:"Contracts",field:"salaryPackagedItems",isSortable:!0,type:{kind:"list",navTo:(e,t)=>`${e.id}/contracts/${t}`}},{name:"Actions",field:"menu",isSortable:!1,type:{kind:"menu",items:e}}],df=Ml.div((({isOpen:e})=>e?{display:"block"}:{display:"none"})),pf=e=>Nl(df,{isOpen:e.isOpen,css:{position:"relative",zIndex:"10"},"aria-labelledby":"modal-title",role:"dialog","aria-modal":"true",children:[Gl("div",{css:{position:"fixed",inset:"0px",backgroundColor:"rgb(107 114 128 / 0.75)",transitionProperty:"opacity",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"150ms"},"aria-hidden":"true"}),Gl("div",{css:{position:"fixed",inset:"0px",zIndex:"10",width:"100vw",overflowY:"auto"},children:Gl("div",{css:{display:"flex",minHeight:"100%",alignItems:"flex-end",justifyContent:"center",padding:"1rem",textAlign:"center","@media (min-width: 640px)":{alignItems:"center",padding:"0px"}},children:Nl("div",{css:{position:"relative",transform:"translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))",overflow:"hidden",overflowWrap:"break-word",borderRadius:"0.5rem","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))",textAlign:"left","--tw-shadow":"0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)","--tw-shadow-colored":"0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",transitionProperty:"all",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"150ms","@media (min-width: 640px)":{marginTop:"2rem",marginBottom:"2rem",width:"100%",maxWidth:"24rem"}},children:[Gl("div",{children:e.children}),Gl("div",{css:{position:"absolute",right:"0px",top:"0px",padding:"0.5rem"},children:Gl("button",{type:"button",onClick:e.onClose,children:Gl(ef,{css:{height:"1.25rem",width:"1.25rem"}})})})]})})})]}),hf=()=>{const{linkedProfilesForAccount:e,unlinkProfile:t}=Ai(),[n,r]=Rt(""),i=Oo(),o=Mo(),a=Xr(),{data:s,error:l}=oi({queryKey:[vi],queryFn:e}),c=It((()=>null==s?void 0:s.map(cf)),[s]),u=[{label:"Unlink",onClick:function(e){const t=Xr(),[n]=Rt((()=>new Bn(t,e)));Ot((()=>{n.setOptions(e)}),[n,e]);const r=Br(Dt((e=>n.subscribe(Tn.batchCalls(e))),[n]),(()=>n.getCurrentResult())),i=Dt(((e,t)=>{n.mutate(e,t).catch(ni)}),[n]);if(r.error&&ti(n.options.throwOnError,[r.error]))throw r.error;return{...r,mutate:i,mutateAsync:r.mutate}}({mutationFn:t,onSuccess:()=>{a.invalidateQueries({queryKey:[vi]})},onError:async e=>{r(await sf(e))}}).mutate}];return Ot((()=>{l?(async()=>{r(await sf(l))})():r("")}),[l]),Nl(Dl,{children:[Gl(of,{columns:uf(u),data:c||[],title:"Linked Profiles",subtitle:"Linked profiles for this account",error:n}),Gl(pf,{isOpen:null!==o,onClose:()=>i("/profiles"),children:Gl(zo,{})})]})},ff=Ml.button({marginLeft:"0.75rem",display:"inline-flex",justifyContent:"center",borderRadius:"0.375rem",borderWidth:"1px",borderColor:"transparent","--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))",paddingLeft:"1rem",paddingRight:"1rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))","--tw-shadow":"0 1px 2px 0 rgb(0 0 0 / 0.05)","--tw-shadow-colored":"0 1px 2px 0 var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(67 56 202 / var(--tw-bg-opacity))"},":focus":{outline:"2px solid transparent",outlineOffset:"2px","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-opacity":"1","--tw-ring-color":"rgb(99 102 241 / var(--tw-ring-opacity))","--tw-ring-offset-width":"2px"},":disabled":{cursor:"not-allowed","--tw-bg-opacity":"1",backgroundColor:"rgb(107 114 128 / var(--tw-bg-opacity))"}}),vf=Ml.div({height:"1.25rem",width:"1.25rem","@keyframes spin":{to:{transform:"rotate(360deg)"}},animation:"spin 1s linear infinite",borderRadius:"9999px",borderWidth:"2px",borderColor:"var(--fl-color-primary-600)",borderLeftColor:"transparent",borderTopColor:"transparent"}),mf=e=>{const[t,n]=Rt(!1);((e,t)=>{const n=Mt();Ot((()=>{n.current=e}),[e]),Ot((()=>{if(t){const e=setInterval(((...e)=>{var t;return null==(t=null==n?void 0:n.current)?void 0:t.call(n,...e)}),t);return()=>clearInterval(e)}}),[t])})((async()=>{await e.onCheck()&&n(!1)}),t?e.checkInterval:void 0),Ot((()=>{if(t){const r=setTimeout((()=>{t&&e.onTimeout(),n(!1)}),e.timeout);return()=>clearTimeout(r)}}));return Gl(ff,{onClick:async()=>{n(!0),await e.onClick()||n(!1)},disabled:t,children:t?Nl(Dl,{children:[Gl(vf,{}),Gl("span",{css:{marginLeft:"0.5rem"},children:e.processingText})]}):Gl(Dl,{children:e.text})})},gf=e=>{var t;const n=Oo(),{ingestClient:r,checkProfileSearchAuthorization:i}=Ai(),o=oi({queryKey:[gi],queryFn:i});Ot((()=>{o.error&&e.onError(o.error.message)}),[e,o]),Ot((()=>{var e;"Linked"===(null==(e=o.data)?void 0:e.status)&&n("/")}),[o.data,n]);return Nl("div",{children:[Gl("h1",{css:{marginBottom:"1rem",marginLeft:"1rem","--tw-text-opacity":"1",color:"rgb(239 68 68 / var(--tw-text-opacity))"},children:null==(t=null==o?void 0:o.data)?void 0:t.message}),Gl(mf,{onClick:async()=>{try{return await r(),!0}catch(t){return e.onError(await sf(t)),!1}},onCheck:async()=>(await o.refetch(),!1),onTimeout:()=>e.onError("Client sync took too long. Please confirm you have updated Catch-E correctly, refresh the page and try again."),checkInterval:5e3,timeout:3e4,text:"Sync Clients",processingText:"Syncing..."})]})},yf=Ml.div`
21
+ `;function Jh({title:e,titleId:t,...n},r){return De("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?De("title",{id:t},e):null,De("path",{fillRule:"evenodd",d:"M5.47 5.47a.75.75 0 0 1 1.06 0L12 10.94l5.47-5.47a.75.75 0 1 1 1.06 1.06L13.06 12l5.47 5.47a.75.75 0 1 1-1.06 1.06L12 13.06l-5.47 5.47a.75.75 0 0 1-1.06-1.06L10.94 12 5.47 6.53a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"}))}const Zh=Yn(Jh),ef=Yn((({label:e,id:t,type:n,icon:r,placeholder:i,setPlaceholderOnFocus:o,value:a,className:s,onChange:l,onBlur:c,onEnter:u,error:d,helperText:p,disabled:h,remove:f},v)=>Gl("div",{className:s,children:[e&&Dl("label",{htmlFor:t,css:{position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"},children:e}),Gl("div",{css:{position:"relative",marginTop:"0.5rem"},children:[r&&Dl("span",{css:{position:"absolute",marginLeft:"0.5rem",marginTop:"0.5rem"},children:r}),Gl("div",{css:{marginTop:"0.5rem",display:"flex",alignItems:"center"},children:[Dl(Xh,{type:n,value:a,name:t,id:t,placeholder:i,onChange:e=>{const t=e;t.target instanceof HTMLInputElement&&l(t.target.value.trim())},onBlur:e=>{const t=e;t.target instanceof HTMLInputElement&&c&&c(t.target.value.trim())},onFocus:()=>{i&&o&&!(null==a?void 0:a.trim())&&l(i)},onKeyDown:e=>{"Enter"===e.key&&u&&u()},hasError:!!d,ref:v,disabled:h,prefix:!!r}),f&&Gl("button",{type:"button",children:[Dl(Zh,{css:{marginLeft:"0.5rem",height:"1.25rem",width:"1.25rem"},onClick:()=>f()})," "]})]})]}),d&&Dl("p",{css:{marginTop:"0.5rem",marginBottom:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(220 38 38 / var(--tw-text-opacity))"},children:d}),p&&Dl("span",{css:{fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:p})]}))),tf="asc",nf="desc",rf=e=>{var t,n;const[r,i]=Rt(""),[o,a]=Rt([]),[s,l]=Rt(e.columns[0]),[c,u]=Rt(tf),d=It((()=>s?[...e.data].sort(((e,t)=>{const n=s.sort?s.sort(e[s.field],t[s.field]):e[s.field].localeCompare(t[s.field]);return c===nf?-1*n:n})):e.data),[e.data,s,c]),p=It((()=>{const t=o.reduce(((e,t)=>e.filter(t.filterFunction)),d);return r&&!e.searchButton?t.filter((e=>e.id.toLowerCase().includes(r.toLowerCase()))):t}),[d,r,o,e.searchButton]),h=It((()=>e.columns.filter((e=>e.filters&&e.filters.length>0)).length>0),[e.columns]),f=()=>{e.searchButton&&e.searchButton.onClick(r)},v=(e,t)=>{const n={name:e.name,filterFunction:n=>e.predicate(n[t.field])},r=o.filter((e=>e.name!==n.name));return()=>r.length<o.length?a([...r]):a([...r,n])};return Dl(Il,{children:Gl("div",{css:{paddingLeft:"1rem",paddingRight:"1rem","@media (min-width: 640px)":{paddingLeft:"1.5rem",paddingRight:"1.5rem"},"@media (min-width: 1024px)":{paddingLeft:"2rem",paddingRight:"2rem"}},children:[Gl("div",{css:{"@media (min-width: 640px)":{display:"flex",alignItems:"center"}},children:[Gl("div",{css:{"@media (min-width: 640px)":{flex:"1 1 auto"}},children:[Dl("h1",{css:{fontSize:"1rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:e.title}),e.subtitle&&Dl("p",{css:{marginTop:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"},children:e.subtitle}),Gl("div",{css:{marginTop:"0.5rem",display:"inline-flex"},children:[Dl(ef,{css:{marginTop:"auto",marginBottom:"auto",maxWidth:"20rem"},label:null==(t=e.searchButton)?void 0:t.text,icon:Dl(Fh,{css:{height:"1.25rem",width:"1.25rem","--tw-text-opacity":"1",color:"rgb(156 163 175 / var(--tw-text-opacity))"}}),id:"search",type:"text",error:null==(n=e.searchButton)?void 0:n.error,onChange:e=>i(e),onEnter:f}),e.searchButton&&Dl("div",{css:{marginLeft:"1rem",marginTop:"0.5rem"},children:Dl("button",{type:"button",onClick:f,css:{display:"block",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",textAlign:"center",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))","--tw-shadow":"0 1px 2px 0 rgb(0 0 0 / 0.05)","--tw-shadow-colored":"0 1px 2px 0 var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(99 102 241 / var(--tw-bg-opacity))"},":focus-visible":{outlineStyle:"solid",outlineWidth:"2px",outlineOffset:"2px",outlineColor:"#4f46e5"}},children:e.searchButton.text})})]})]}),e.addButton&&Dl("div",{css:{marginTop:"1rem","@media (min-width: 640px)":{marginLeft:"4rem",marginTop:"0px",flex:"none"}},children:Dl("button",{type:"button",onClick:e.addButton.onClick,css:{display:"block",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))",paddingLeft:"0.75rem",paddingRight:"0.75rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",textAlign:"center",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))","--tw-shadow":"0 1px 2px 0 rgb(0 0 0 / 0.05)","--tw-shadow-colored":"0 1px 2px 0 var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(99 102 241 / var(--tw-bg-opacity))"},":focus-visible":{outlineStyle:"solid",outlineWidth:"2px",outlineOffset:"2px",outlineColor:"#4f46e5"}},children:e.addButton.text})})]}),e.error&&Dl("div",{css:{marginBottom:"1rem",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(254 242 242 / var(--tw-bg-opacity))",padding:"1rem"},children:Gl("div",{css:{display:"flex"},children:[Dl("div",{css:{flexShrink:"0"},children:Dl(Qh,{css:{height:"1.25rem",width:"1.25rem","--tw-text-opacity":"1",color:"rgb(248 113 113 / var(--tw-text-opacity))"},"aria-hidden":"true"})}),Dl("div",{css:{marginLeft:"0.75rem"},children:Dl("h3",{css:{fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(153 27 27 / var(--tw-text-opacity))"},children:e.error})})]})}),Dl("div",{css:{marginTop:"2rem",display:"flow-root"},children:Dl("div",{css:{marginLeft:"-1rem",marginRight:"-1rem",marginTop:"-0.5rem",marginBottom:"-0.5rem",overflowX:"auto","@media (min-width: 640px)":{marginLeft:"-1.5rem",marginRight:"-1.5rem"},"@media (min-width: 1024px)":{marginLeft:"-2rem",marginRight:"-2rem"}},children:Dl("div",{css:{display:"inline-block",minWidth:"100%",paddingTop:"0.5rem",paddingBottom:"0.5rem",verticalAlign:"middle","@media (min-width: 640px)":{paddingLeft:"1.5rem",paddingRight:"1.5rem"},"@media (min-width: 1024px)":{paddingLeft:"2rem",paddingRight:"2rem"}},children:Dl("div",{css:{overflow:"hidden","--tw-shadow":"0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1)","--tw-shadow-colored":"0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)","--tw-ring-opacity":"0.05","--tw-ring-color":"rgb(0 0 0 / var(--tw-ring-opacity))","@media (min-width: 640px)":{borderRadius:"0.5rem"}},children:Gl("table",{css:{minWidth:"100%","> :not([hidden]) ~ :not([hidden])":{"--tw-divide-y-reverse":"0",borderTopWidth:"calc(1px * calc(1 - var(--tw-divide-y-reverse)))",borderBottomWidth:"calc(1px * var(--tw-divide-y-reverse))","--tw-divide-opacity":"1",borderColor:"rgb(209 213 219 / var(--tw-divide-opacity))"}},children:[h&&Dl("thead",{children:Dl("tr",{children:Gl("td",{css:{padding:"1rem"},colSpan:e.columns.length,children:[Dl(Yh,{onClick:()=>a([]),isActive:0==o.length,children:"All"}),e.columns.map((e=>{var t;return null==(t=e.filters)?void 0:t.map((t=>Dl(Yh,{onClick:v(t,e),isActive:!!o.find((e=>e.name===t.name)),children:t.name},t.name)))}))]})})}),Dl("thead",{css:{"--tw-bg-opacity":"1",backgroundColor:"rgb(249 250 251 / var(--tw-bg-opacity))"},children:Dl("tr",{children:e.columns.map((e=>Dl("th",{scope:"col",css:{paddingTop:"0.875rem",paddingBottom:"0.875rem",paddingLeft:"1rem",paddingRight:"0.75rem",textAlign:"left",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:Gl("button",{disabled:!e.isSortable,onClick:()=>(e=>{s===e?u(c===tf?nf:tf):(l(e),u(tf))})(e),css:{display:"inline-flex"},children:[Dl("span",{children:e.name}),Gl("span",{css:{marginLeft:"0.5rem"},children:[s===e&&c===tf&&Dl(zh,{css:{height:"1.25rem",width:"1.25rem"}}),s===e&&c===nf&&Dl(Kh,{css:{height:"1.25rem",width:"1.25rem"}}),s!==e&&Dl("svg",{css:{height:"1.25rem",width:"1.25rem"}})]})]})},e.field)))})}),Dl("tbody",{css:{"> :not([hidden]) ~ :not([hidden])":{"--tw-divide-y-reverse":"0",borderTopWidth:"calc(1px * calc(1 - var(--tw-divide-y-reverse)))",borderBottomWidth:"calc(1px * var(--tw-divide-y-reverse))","--tw-divide-opacity":"1",borderColor:"rgb(229 231 235 / var(--tw-divide-opacity))"},"--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))"},children:p.map(((t,n)=>Dl("tr",{children:e.columns.map(((e,r)=>Dl($e,{children:jh(t.id,t[e.field],t,e.type)},`${t[e.field]}-${n}-${r}`)))},`${t[e.columns[0].field]}-${n}`)))})]})})})})})]})})},of=[{name:"Profile Id",field:"id",isSortable:!0,type:{kind:"copy"}},{name:"Name",field:"name",isSortable:!0},{name:"Email",field:"email",isSortable:!0},{name:"External Id",field:"externalId",isSortable:!0},{name:"Catch-E Driver Id",field:"catchEId",isSortable:!0}],af=async e=>{if(!(e instanceof si))return"Unexpected error occurred";try{return(await e.response.json()).message||`${e.response.status} error occurred`}catch{return`${e.response.status} error occurred`}},sf=()=>{const[e,t]=Rt(""),[n,r]=Rt(""),{searchProfilesForAccount:i}=Ri(),{data:o,refetch:a,error:s,isFetched:l,isRefetching:c}=oi({queryKey:["searchProfilesForAccount"],queryFn:()=>i(e),enabled:!1,retry:!1});Ot((()=>{e&&a()}),[e,a]),Ot((()=>{s?(async()=>{r(await af(s))})():r("")}),[s]),Ot((()=>{l&&0===(null==o?void 0:o.length)&&r("No profiles found"),c&&r("")}),[c,l,o]);return Dl(rf,{columns:of,data:o||[],title:"Profile Search",subtitle:"Search for a profile using name or email",searchButton:{onClick:e=>{t(e)},text:"Search",error:n}})},lf=e=>({id:e.id,catchEDriverId:e.catchEDriverId,salaryPackagedItems:e.salaryPackagedItems.map((e=>e.catchEContractId)).join(",")}),cf=e=>[{name:"Profile Id",field:"id",isSortable:!0,type:{kind:"copy"}},{name:"Catch-E Driver Id",field:"catchEDriverId",isSortable:!0},{name:"Contracts",field:"salaryPackagedItems",isSortable:!0,type:{kind:"list",navTo:(e,t)=>`${e.id}/contracts/${t}`}},{name:"Actions",field:"menu",isSortable:!1,type:{kind:"menu",items:e}}],uf=Ll.div((({isOpen:e})=>e?{display:"block"}:{display:"none"})),df=e=>Gl(uf,{isOpen:e.isOpen,css:{position:"relative",zIndex:"10"},"aria-labelledby":"modal-title",role:"dialog","aria-modal":"true",children:[Dl("div",{css:{position:"fixed",inset:"0px",backgroundColor:"rgb(107 114 128 / 0.75)",transitionProperty:"opacity",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"150ms"},"aria-hidden":"true"}),Dl("div",{css:{position:"fixed",inset:"0px",zIndex:"10",width:"100vw",overflowY:"auto"},children:Dl("div",{css:{display:"flex",minHeight:"100%",alignItems:"flex-end",justifyContent:"center",padding:"1rem",textAlign:"center","@media (min-width: 640px)":{alignItems:"center",padding:"0px"}},children:Gl("div",{css:{position:"relative",transform:"translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))",overflow:"hidden",overflowWrap:"break-word",borderRadius:"0.5rem","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))",textAlign:"left","--tw-shadow":"0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)","--tw-shadow-colored":"0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",transitionProperty:"all",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"150ms","@media (min-width: 640px)":{marginTop:"2rem",marginBottom:"2rem",width:"100%",maxWidth:"24rem"}},children:[Dl("div",{children:e.children}),Dl("div",{css:{position:"absolute",right:"0px",top:"0px",padding:"0.5rem"},children:Dl("button",{type:"button",onClick:e.onClose,children:Dl(Zh,{css:{height:"1.25rem",width:"1.25rem"}})})})]})})})]}),pf=()=>{const{linkedProfilesForAccount:e,unlinkProfile:t}=Ri(),[n,r]=Rt(""),i=Ao(),o=Lo(),a=Xr(),{data:s,error:l}=oi({queryKey:[fi],queryFn:e}),c=It((()=>null==s?void 0:s.map(lf)),[s]),u=[{label:"Unlink",onClick:function(e){const t=Xr(),[n]=Rt((()=>new Bn(t,e)));Ot((()=>{n.setOptions(e)}),[n,e]);const r=Br(Dt((e=>n.subscribe(Tn.batchCalls(e))),[n]),(()=>n.getCurrentResult())),i=Dt(((e,t)=>{n.mutate(e,t).catch(ni)}),[n]);if(r.error&&ti(n.options.throwOnError,[r.error]))throw r.error;return{...r,mutate:i,mutateAsync:r.mutate}}({mutationFn:t,onSuccess:()=>{a.invalidateQueries({queryKey:[fi]})},onError:async e=>{r(await af(e))}}).mutate}];return Ot((()=>{l?(async()=>{r(await af(l))})():r("")}),[l]),Gl(Il,{children:[Dl(rf,{columns:cf(u),data:c||[],title:"Linked Profiles",subtitle:"Linked profiles for this account",error:n}),Dl(df,{isOpen:null!==o,onClose:()=>i("/profiles"),children:Dl(Bo,{})})]})},hf=Ll.button({marginLeft:"0.75rem",display:"inline-flex",justifyContent:"center",borderRadius:"0.375rem",borderWidth:"1px",borderColor:"transparent","--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))",paddingLeft:"1rem",paddingRight:"1rem",paddingTop:"0.5rem",paddingBottom:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))","--tw-shadow":"0 1px 2px 0 rgb(0 0 0 / 0.05)","--tw-shadow-colored":"0 1px 2px 0 var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(67 56 202 / var(--tw-bg-opacity))"},":focus":{outline:"2px solid transparent",outlineOffset:"2px","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-opacity":"1","--tw-ring-color":"rgb(99 102 241 / var(--tw-ring-opacity))","--tw-ring-offset-width":"2px"},":disabled":{cursor:"not-allowed","--tw-bg-opacity":"1",backgroundColor:"rgb(107 114 128 / var(--tw-bg-opacity))"}}),ff=Ll.div({height:"1.25rem",width:"1.25rem","@keyframes spin":{to:{transform:"rotate(360deg)"}},animation:"spin 1s linear infinite",borderRadius:"9999px",borderWidth:"2px",borderColor:"var(--fl-color-primary-600)",borderLeftColor:"transparent",borderTopColor:"transparent"}),vf=e=>{const[t,n]=Rt(!1);((e,t)=>{const n=Mt();Ot((()=>{n.current=e}),[e]),Ot((()=>{if(t){const e=setInterval(((...e)=>{var t;return null==(t=null==n?void 0:n.current)?void 0:t.call(n,...e)}),t);return()=>clearInterval(e)}}),[t])})((async()=>{await e.onCheck()&&n(!1)}),t?e.checkInterval:void 0),Ot((()=>{if(t){const r=setTimeout((()=>{t&&e.onTimeout(),n(!1)}),e.timeout);return()=>clearTimeout(r)}}));return Dl(hf,{onClick:async()=>{n(!0),await e.onClick()||n(!1)},disabled:t,children:t?Gl(Il,{children:[Dl(ff,{}),Dl("span",{css:{marginLeft:"0.5rem"},children:e.processingText})]}):Dl(Il,{children:e.text})})},mf=e=>{var t;const n=Ao(),{ingestClient:r,checkProfileSearchAuthorization:i}=Ri(),o=oi({queryKey:[mi],queryFn:i});Ot((()=>{o.error&&e.onError(o.error.message)}),[e,o]),Ot((()=>{var e;"Linked"===(null==(e=o.data)?void 0:e.status)&&n("/")}),[o.data,n]);return Gl("div",{children:[Dl("h1",{css:{marginBottom:"1rem",marginLeft:"1rem","--tw-text-opacity":"1",color:"rgb(239 68 68 / var(--tw-text-opacity))"},children:null==(t=null==o?void 0:o.data)?void 0:t.message}),Dl(vf,{onClick:async()=>{try{return await r(),!0}catch(t){return e.onError(await af(t)),!1}},onCheck:async()=>(await o.refetch(),!1),onTimeout:()=>e.onError("Client sync took too long. Please confirm you have updated Catch-E correctly, refresh the page and try again."),checkInterval:5e3,timeout:3e4,text:"Sync Clients",processingText:"Syncing..."})]})},gf=Ll.div`
22
22
  width: ${({width:e})=>e?`${e}rem`:"100%"};
23
23
  height: ${({height:e})=>e}rem;
24
- `,_f=({height:e,width:t,className:n})=>Gl("div",{className:n,children:Gl("div",{css:{display:"flex",height:"100%","@keyframes pulse":{"50%":{opacity:".5"}},animation:"pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite",flexDirection:"row"},children:Gl(yf,{width:t,height:e,css:{marginTop:"auto",marginBottom:"auto",borderRadius:"0.25rem","--tw-bg-opacity":"1",backgroundColor:"rgb(209 213 219 / var(--tw-bg-opacity))"}})})}),wf=()=>{const{salaryPackagedItem:e,linkedProfilesForAccount:t,payrollAdvice:n}=Ai(),{profileId:r,contractId:i}=function(){let{matches:e}=Gt(Eo),t=e[e.length-1];return t?t.params:{}}(),[o,a]=Rt(""),s=oi({queryKey:[vi],queryFn:t}),l=oi({queryKey:[yi,r],queryFn:()=>r?n(r):Promise.resolve([])}),c=It((()=>{var e,t,n;return(null==(n=null==(t=null==(e=s.data)?void 0:e.find((e=>e.id===r)))?void 0:t.salaryPackagedItems.find((e=>e.catchEContractId===i)))?void 0:n.itemId)||""}),[i,r,s.data]),u=oi({queryKey:[mi,r,c],queryFn:()=>c&&r?e(r,c):Promise.resolve(void 0)});Ot((()=>{u.error&&a(u.error.message),l.error&&a(l.error.message)}),[u.error,l.error]);const d=It((()=>{var e;return s.isPending||u.isPending?void 0:((e,t)=>{var n;return{id:(null==(n=null==e?void 0:e.salaryPackagedItems.find((e=>e.itemId===(null==t?void 0:t.itemId))))?void 0:n.catchEContractId)||"",status:(null==t?void 0:t.status)||"",start:(null==t?void 0:t.details.contractStart)||"",end:(null==t?void 0:t.details.contractEnd)||"",term:(null==t?void 0:t.details.termInMonths)?`${null==t?void 0:t.details.termInMonths} months`:"",vehicle:(null==t?void 0:t.details.vehicle.description)||"",fbtValue:(null==t?void 0:t.details.vehicle.fbtCapitalValue.toString())||""}})(null==(e=s.data)?void 0:e.find((e=>e.id===r)),u.data)}),[s,u,r]),p=It((()=>{var e;return null==(e=l.data)?void 0:e.find((e=>"active"===e.status))}),[l.data]),h=It((()=>{const e=null==p?void 0:p.salaryPackagedItems.find((e=>e.itemId===c));return e?{preTax:e.deduction.preTaxExGst,postTax:e.deduction.postTaxIncGst,luxuryCarCharge:e.deduction.luxuryCarCharge||0}:void 0}),[p,c]);return{contractData:d,payrollAdviceData:p,contractPayrollAdviceData:h,error:o,isPayrollAdvicePending:l.isPending}},bf=({name:e,value:t})=>Nl("div",{className:"=gap-4",css:{display:"grid",gridTemplateColumns:"repeat(5, minmax(0, 1fr))",paddingTop:"0.5rem",paddingBottom:"0.5rem"},children:[Gl("dt",{css:{gridColumn:"span 2 / span 2",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:e}),t?Gl("dd",{css:{gridColumn:"span 3 / span 3",marginTop:"0px",fontSize:"0.875rem",lineHeight:"1.5rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"},children:t}):Gl(_f,{css:{gridColumn:"span 3 / span 3"},height:1,width:8})]}),xf=()=>{const{contractData:e,payrollAdviceData:t,contractPayrollAdviceData:n,error:r,isPayrollAdvicePending:i}=wf();return Gl(Dl,{children:Gl("div",r?{css:{"--tw-text-opacity":"1",color:"rgb(239 68 68 / var(--tw-text-opacity))"},children:r}:{css:{"@media (min-width: 1024px)":{gridColumnStart:"3",gridRowEnd:"1"}},children:Gl("div",{css:{borderRadius:"0.5rem","--tw-bg-opacity":"1",backgroundColor:"rgb(249 250 251 / var(--tw-bg-opacity))","--tw-shadow":"0 1px 2px 0 rgb(0 0 0 / 0.05)","--tw-shadow-colored":"0 1px 2px 0 var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)","--tw-ring-color":"rgb(17 24 39 / 0.05)"},children:Nl("dl",{css:{display:"flex",flexWrap:"wrap"},children:[Nl("div",{css:{flex:"1 1 auto",paddingLeft:"1.5rem",paddingTop:"1.5rem"},children:[Gl("dt",{css:{fontSize:"0.875rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:"Contract"}),Gl("dd",{css:{marginTop:"0.25rem",fontSize:"1rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:null==e?void 0:e.id})]}),Nl("div",{css:{flex:"none",alignSelf:"flex-end",paddingLeft:"1.5rem",paddingRight:"1.5rem",paddingTop:"1rem"},children:[Gl("dt",{css:{position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"},children:"Status"}),Gl("dd",{css:{display:"inline-flex",alignItems:"center",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(240 253 244 / var(--tw-bg-opacity))",paddingLeft:"0.5rem",paddingRight:"0.5rem",paddingTop:"0.25rem",paddingBottom:"0.25rem",fontSize:"0.75rem",lineHeight:"1rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(21 128 61 / var(--tw-text-opacity))","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-inset":"inset","--tw-ring-color":"rgb(22 163 74 / 0.2)"},children:"active"===(null==e?void 0:e.status)?"Active":null==e?void 0:e.status})]}),Gl("div",{css:{marginTop:"1.5rem",display:"flex",width:"100%",flex:"none",columnGap:"1rem",borderTopWidth:"1px",borderColor:"rgb(17 24 39 / 0.05)",paddingLeft:"1.5rem",paddingRight:"1.5rem",paddingTop:"1.5rem"},children:Nl("dl",{css:{"> :not([hidden]) ~ :not([hidden])":{"--tw-divide-y-reverse":"0",borderTopWidth:"calc(1px * calc(1 - var(--tw-divide-y-reverse)))",borderBottomWidth:"calc(1px * var(--tw-divide-y-reverse))","--tw-divide-opacity":"1",borderColor:"rgb(243 244 246 / var(--tw-divide-opacity))"}},children:[Gl(bf,{name:"Vehicle",value:null==e?void 0:e.vehicle}),Gl(bf,{name:"FBT Value",value:Nh(null==e?void 0:e.fbtValue)}),Gl(bf,{name:"Period",value:e?`${Gh(e.start)} to ${Gh(e.end)}`:void 0}),Gl(bf,{name:"Term",value:null==e?void 0:e.term}),Gl("div",{className:"=gap-4",css:{display:"grid",gridTemplateColumns:"repeat(4, minmax(0, 1fr))",paddingTop:"0.5rem",paddingBottom:"0.5rem"},children:Nl("dt",{css:{gridColumn:"span 4 / span 4",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:["Deductions",i?"":` for ${Gh(null==t?void 0:t.fromDate)} to ${Gh(null==t?void 0:t.toDate)}`]})}),Gl(bf,{name:"Pre-Tax Ex GST",value:Nh(null==n?void 0:n.preTax)}),Gl(bf,{name:"Post-Tax Inc GST",value:Nh(null==n?void 0:n.postTax)}),Gl(bf,{name:"Luxury Vehicle Adjustment",value:Nh(null==n?void 0:n.luxuryCarCharge)})]})})]})})})})},kf=e=>({invoiceRef:e.invoiceRef,postedDate:e.postedDate,status:e.status,amountNet:Nh(e.amountNet)||"$0",amountGst:Nh(e.amountGst)||"$0",amountReceived:Nh(e.amountRecieved)||"$0"}),Sf=[{name:"Reference",field:"invoiceRef",isSortable:!0},{name:"Posted Date",field:"postedDate",isSortable:!0,type:{kind:"date"}},{name:"Status",field:"status",isSortable:!0,type:{kind:"status"}},{name:"Net",field:"amountNet",isSortable:!0},{name:"Gst",field:"amountGst",isSortable:!0},{name:"Received",field:"amountReceived",isSortable:!0}],Ef=()=>{const{data:e,error:t}=(()=>{const{invoices:e}=Ai(),[t,n]=Rt(""),r=oi({queryKey:[_i],queryFn:e}),i=It((()=>{var e;return null==(e=r.data)?void 0:e.data.map(kf)}),[r]);return Ot((()=>{r.isError?n(r.error.message):n("")}),[r]),{data:i,error:t}})();return Gl(of,{columns:Sf,data:e||[],title:"Invoices",subtitle:"Posted invoices for this account",error:t})},Cf=e=>{const[t]=Rt(Qt.create(e.accessToken)),n=It((()=>({account:{accountId:e.accountId},backend:{url:e.backendUrl.replace(/\/?$/,""),accessToken:e.accessToken}})),[e]),[r,i]=Rt(),o=Oo();Ot((()=>{t&&!t.isAuthorized&&(i("Access Denied"),o("error"))}),[t,o]);const a=e=>{i(e),o("error")};return Gl(ai.Provider,{value:n,children:Nl(Vo,{children:[Nl(qo,{path:"",element:Gl(Hl,{onError:a}),children:[Gl(qo,{index:!0,element:Gl(Bo,{to:"search",replace:!0})}),Gl(qo,{path:"search",element:Gl(lf,{})}),Gl(qo,{path:"profiles",element:Gl(hf,{}),children:Gl(qo,{path:":profileId/contracts/:contractId",element:Gl(xf,{})})}),Gl(qo,{path:"invoices",element:Gl(Ef,{})})]}),Gl(qo,{path:"error",element:r?Gl("h1",{css:{"--tw-text-opacity":"1",color:"rgb(239 68 68 / var(--tw-text-opacity))"},children:r}):Gl(Bo,{to:"/search",replace:!0})}),Gl(qo,{path:"unlinked",element:Gl(gf,{onError:a})}),Gl(qo,{path:"*",element:Gl("h1",{css:{"--tw-text-opacity":"1",color:"rgb(239 68 68 / var(--tw-text-opacity))"},children:"Page not found"})})]})})},Tf=Cl({body:{WebkitTapHighlightColor:"#a855f7",WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale"},":host":{"--fl-color-primary-900":"#000563","--fl-color-primary-800":"#031495","--fl-color-primary-700":"#1033c6","--fl-color-primary-600":"#2e66f7","--fl-color-primary-500":"#5786f8","--fl-color-primary-400":"#88abfa","--fl-color-primary-300":"#b5cbfb","--fl-color-primary-200":"#d6e2fc","--fl-color-primary-100":"#eaf0fe","--fl-color-primary-50":"#f2f6ff","--kit-font-family":"Inter, 'Source Sans Pro', sans-serif",fontFamily:"Inter, 'Source Sans Pro', sans-serif"}}),Pf=()=>Nl($e,{children:[Gl(El,{styles:Cl`
24
+ `,yf=({height:e,width:t,className:n})=>Dl("div",{className:n,children:Dl("div",{css:{display:"flex",height:"100%","@keyframes pulse":{"50%":{opacity:".5"}},animation:"pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite",flexDirection:"row"},children:Dl(gf,{width:t,height:e,css:{marginTop:"auto",marginBottom:"auto",borderRadius:"0.25rem","--tw-bg-opacity":"1",backgroundColor:"rgb(209 213 219 / var(--tw-bg-opacity))"}})})}),_f=()=>{const{salaryPackagedItem:e,linkedProfilesForAccount:t,payrollAdvice:n}=Ri(),{profileId:r,contractId:i}=function(){let{matches:e}=Gt(So),t=e[e.length-1];return t?t.params:{}}(),[o,a]=Rt(""),s=oi({queryKey:[fi],queryFn:t}),l=oi({queryKey:[gi,r],queryFn:()=>r?n(r):Promise.resolve([])}),c=It((()=>{var e,t,n;return(null==(n=null==(t=null==(e=s.data)?void 0:e.find((e=>e.id===r)))?void 0:t.salaryPackagedItems.find((e=>e.catchEContractId===i)))?void 0:n.itemId)||""}),[i,r,s.data]),u=oi({queryKey:[vi,r,c],queryFn:()=>c&&r?e(r,c):Promise.resolve(void 0)});Ot((()=>{u.error&&a(u.error.message),l.error&&a(l.error.message)}),[u.error,l.error]);const d=It((()=>{var e;return s.isPending||u.isPending?void 0:((e,t)=>{var n;return{id:(null==(n=null==e?void 0:e.salaryPackagedItems.find((e=>e.itemId===(null==t?void 0:t.itemId))))?void 0:n.catchEContractId)||"",status:(null==t?void 0:t.status)||"",start:(null==t?void 0:t.details.contractStart)||"",end:(null==t?void 0:t.details.contractEnd)||"",term:(null==t?void 0:t.details.termInMonths)?`${null==t?void 0:t.details.termInMonths} months`:"",vehicle:(null==t?void 0:t.details.vehicle.description)||"",fbtValue:(null==t?void 0:t.details.vehicle.fbtCapitalValue.toString())||""}})(null==(e=s.data)?void 0:e.find((e=>e.id===r)),u.data)}),[s,u,r]),p=It((()=>{var e;return null==(e=l.data)?void 0:e.find((e=>"active"===e.status))}),[l.data]),h=It((()=>{const e=null==p?void 0:p.salaryPackagedItems.find((e=>e.itemId===c));return e?{preTax:e.deduction.preTaxExGst,postTax:e.deduction.postTaxIncGst,luxuryCarCharge:e.deduction.luxuryCarCharge||0}:void 0}),[p,c]);return{contractData:d,payrollAdviceData:p,contractPayrollAdviceData:h,error:o,isPayrollAdvicePending:l.isPending}},wf=({name:e,value:t})=>Gl("div",{className:"=gap-4",css:{display:"grid",gridTemplateColumns:"repeat(5, minmax(0, 1fr))",paddingTop:"0.5rem",paddingBottom:"0.5rem"},children:[Dl("dt",{css:{gridColumn:"span 2 / span 2",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:e}),t?Dl("dd",{css:{gridColumn:"span 3 / span 3",marginTop:"0px",fontSize:"0.875rem",lineHeight:"1.5rem","--tw-text-opacity":"1",color:"rgb(55 65 81 / var(--tw-text-opacity))"},children:t}):Dl(yf,{css:{gridColumn:"span 3 / span 3"},height:1,width:8})]}),bf=()=>{const{contractData:e,payrollAdviceData:t,contractPayrollAdviceData:n,error:r,isPayrollAdvicePending:i}=_f();return Dl(Il,{children:Dl("div",r?{css:{"--tw-text-opacity":"1",color:"rgb(239 68 68 / var(--tw-text-opacity))"},children:r}:{css:{"@media (min-width: 1024px)":{gridColumnStart:"3",gridRowEnd:"1"}},children:Dl("div",{css:{borderRadius:"0.5rem","--tw-bg-opacity":"1",backgroundColor:"rgb(249 250 251 / var(--tw-bg-opacity))","--tw-shadow":"0 1px 2px 0 rgb(0 0 0 / 0.05)","--tw-shadow-colored":"0 1px 2px 0 var(--tw-shadow-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)","--tw-ring-color":"rgb(17 24 39 / 0.05)"},children:Gl("dl",{css:{display:"flex",flexWrap:"wrap"},children:[Gl("div",{css:{flex:"1 1 auto",paddingLeft:"1.5rem",paddingTop:"1.5rem"},children:[Dl("dt",{css:{fontSize:"0.875rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:"Contract"}),Dl("dd",{css:{marginTop:"0.25rem",fontSize:"1rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:null==e?void 0:e.id})]}),Gl("div",{css:{flex:"none",alignSelf:"flex-end",paddingLeft:"1.5rem",paddingRight:"1.5rem",paddingTop:"1rem"},children:[Dl("dt",{css:{position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"},children:"Status"}),Dl("dd",{css:{display:"inline-flex",alignItems:"center",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(240 253 244 / var(--tw-bg-opacity))",paddingLeft:"0.5rem",paddingRight:"0.5rem",paddingTop:"0.25rem",paddingBottom:"0.25rem",fontSize:"0.75rem",lineHeight:"1rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(21 128 61 / var(--tw-text-opacity))","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)","--tw-ring-inset":"inset","--tw-ring-color":"rgb(22 163 74 / 0.2)"},children:"active"===(null==e?void 0:e.status)?"Active":null==e?void 0:e.status})]}),Dl("div",{css:{marginTop:"1.5rem",display:"flex",width:"100%",flex:"none",columnGap:"1rem",borderTopWidth:"1px",borderColor:"rgb(17 24 39 / 0.05)",paddingLeft:"1.5rem",paddingRight:"1.5rem",paddingTop:"1.5rem"},children:Gl("dl",{css:{"> :not([hidden]) ~ :not([hidden])":{"--tw-divide-y-reverse":"0",borderTopWidth:"calc(1px * calc(1 - var(--tw-divide-y-reverse)))",borderBottomWidth:"calc(1px * var(--tw-divide-y-reverse))","--tw-divide-opacity":"1",borderColor:"rgb(243 244 246 / var(--tw-divide-opacity))"}},children:[Dl(wf,{name:"Vehicle",value:null==e?void 0:e.vehicle}),Dl(wf,{name:"FBT Value",value:Gh(null==e?void 0:e.fbtValue)}),Dl(wf,{name:"Period",value:e?`${Dh(e.start)} to ${Dh(e.end)}`:void 0}),Dl(wf,{name:"Term",value:null==e?void 0:e.term}),Dl("div",{className:"=gap-4",css:{display:"grid",gridTemplateColumns:"repeat(4, minmax(0, 1fr))",paddingTop:"0.5rem",paddingBottom:"0.5rem"},children:Gl("dt",{css:{gridColumn:"span 4 / span 4",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:["Deductions",i?"":` for ${Dh(null==t?void 0:t.fromDate)} to ${Dh(null==t?void 0:t.toDate)}`]})}),Dl(wf,{name:"Pre-Tax Ex GST",value:Gh(null==n?void 0:n.preTax)}),Dl(wf,{name:"Post-Tax Inc GST",value:Gh(null==n?void 0:n.postTax)}),Dl(wf,{name:"Luxury Vehicle Adjustment",value:Gh(null==n?void 0:n.luxuryCarCharge)})]})})]})})})})},xf=e=>({invoiceRef:e.invoiceRef,postedDate:e.postedDate,status:e.status,amountNet:Gh(e.amountNet)||"$0",amountGst:Gh(e.amountGst)||"$0",amountReceived:Gh(e.amountRecieved)||"$0"}),kf=[{name:"Reference",field:"invoiceRef",isSortable:!0},{name:"Posted Date",field:"postedDate",isSortable:!0,type:{kind:"date"}},{name:"Status",field:"status",isSortable:!0,type:{kind:"status"}},{name:"Net",field:"amountNet",isSortable:!0},{name:"Gst",field:"amountGst",isSortable:!0},{name:"Received",field:"amountReceived",isSortable:!0}],Sf=()=>{const{data:e,error:t}=(()=>{const{invoices:e}=Ri(),[t,n]=Rt(""),r=oi({queryKey:[yi],queryFn:e}),i=It((()=>{var e;return null==(e=r.data)?void 0:e.data.map(xf)}),[r]);return Ot((()=>{r.isError?n(r.error.message):n("")}),[r]),{data:i,error:t}})();return Dl(rf,{columns:kf,data:e||[],title:"Invoices",subtitle:"Posted invoices for this account",error:t})},Ef=e=>{const[t]=Rt(Qt.create(e.accessToken)),n=It((()=>({account:{accountId:e.accountId},backend:{url:e.backendUrl.replace(/\/?$/,""),accessToken:e.accessToken}})),[e]),[r,i]=Rt(),o=Ao();Ot((()=>{t&&!t.isAuthorized&&(i("Access Denied"),o("error"))}),[t,o]);const a=e=>{i(e),o("error")};return Dl(ai.Provider,{value:n,children:Gl(Ko,{children:[Gl(zo,{path:"",element:Dl($l,{onError:a}),children:[Dl(zo,{index:!0,element:Dl(jo,{to:"search",replace:!0})}),Dl(zo,{path:"search",element:Dl(sf,{})}),Dl(zo,{path:"profiles",element:Dl(pf,{}),children:Dl(zo,{path:":profileId/contracts/:contractId",element:Dl(bf,{})})}),Dl(zo,{path:"invoices",element:Dl(Sf,{})})]}),Dl(zo,{path:"error",element:r?Dl("h1",{css:{"--tw-text-opacity":"1",color:"rgb(239 68 68 / var(--tw-text-opacity))"},children:r}):Dl(jo,{to:"/search",replace:!0})}),Dl(zo,{path:"unlinked",element:Dl(mf,{onError:a})}),Dl(zo,{path:"*",element:Dl("h1",{css:{"--tw-text-opacity":"1",color:"rgb(239 68 68 / var(--tw-text-opacity))"},children:"Page not found"})})]})})},Cf=El({body:{WebkitTapHighlightColor:"#a855f7",WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale"},":host":{"--fl-color-primary-900":"#000563","--fl-color-primary-800":"#031495","--fl-color-primary-700":"#1033c6","--fl-color-primary-600":"#2e66f7","--fl-color-primary-500":"#5786f8","--fl-color-primary-400":"#88abfa","--fl-color-primary-300":"#b5cbfb","--fl-color-primary-200":"#d6e2fc","--fl-color-primary-100":"#eaf0fe","--fl-color-primary-50":"#f2f6ff","--kit-font-family":"Inter, 'Source Sans Pro', sans-serif",fontFamily:"Inter, 'Source Sans Pro', sans-serif"}}),Tf=()=>Gl($e,{children:[Dl(Sl,{styles:El`
25
25
  ${{"*, ::before, ::after":{boxSizing:"border-box",borderWidth:"0",borderStyle:"solid",borderColor:"#e5e7eb","--tw-border-spacing-x":"0","--tw-border-spacing-y":"0","--tw-translate-x":"0","--tw-translate-y":"0","--tw-rotate":"0","--tw-skew-x":"0","--tw-skew-y":"0","--tw-scale-x":"1","--tw-scale-y":"1","--tw-pan-x":"var(--tw-empty,/*!*/ /*!*/)","--tw-pan-y":"var(--tw-empty,/*!*/ /*!*/)","--tw-pinch-zoom":"var(--tw-empty,/*!*/ /*!*/)","--tw-scroll-snap-strictness":"proximity","--tw-gradient-from-position":"var(--tw-empty,/*!*/ /*!*/)","--tw-gradient-via-position":"var(--tw-empty,/*!*/ /*!*/)","--tw-gradient-to-position":"var(--tw-empty,/*!*/ /*!*/)","--tw-ordinal":"var(--tw-empty,/*!*/ /*!*/)","--tw-slashed-zero":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-figure":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-spacing":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-fraction":"var(--tw-empty,/*!*/ /*!*/)","--tw-ring-offset-shadow":"0 0 #0000","--tw-ring-shadow":"0 0 #0000","--tw-shadow":"0 0 #0000","--tw-shadow-colored":"0 0 #0000","--tw-ring-inset":"var(--tw-empty,/*!*/ /*!*/)","--tw-ring-offset-width":"0px","--tw-ring-offset-color":"#fff","--tw-ring-color":"rgb(59 130 246 / 0.5)","--tw-blur":"var(--tw-empty,/*!*/ /*!*/)","--tw-brightness":"var(--tw-empty,/*!*/ /*!*/)","--tw-contrast":"var(--tw-empty,/*!*/ /*!*/)","--tw-grayscale":"var(--tw-empty,/*!*/ /*!*/)","--tw-hue-rotate":"var(--tw-empty,/*!*/ /*!*/)","--tw-invert":"var(--tw-empty,/*!*/ /*!*/)","--tw-saturate":"var(--tw-empty,/*!*/ /*!*/)","--tw-sepia":"var(--tw-empty,/*!*/ /*!*/)","--tw-drop-shadow":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-blur":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-brightness":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-contrast":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-grayscale":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-hue-rotate":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-invert":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-opacity":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-saturate":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-sepia":"var(--tw-empty,/*!*/ /*!*/)","--tw-contain-size":"var(--tw-empty,/*!*/ /*!*/)","--tw-contain-layout":"var(--tw-empty,/*!*/ /*!*/)","--tw-contain-paint":"var(--tw-empty,/*!*/ /*!*/)","--tw-contain-style":"var(--tw-empty,/*!*/ /*!*/)"},"::before, ::after":{"--tw-content":"''"},"html, :host":{lineHeight:"1.5",WebkitTextSizeAdjust:"100%",MozTabSize:"4",tabSize:"4",fontFamily:'Inter, ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"',fontFeatureSettings:" normal",fontVariationSettings:" normal",WebkitTapHighlightColor:"transparent"},body:{margin:"0",lineHeight:"inherit"},hr:{height:"0",color:"inherit",borderTopWidth:"1px"},"abbr:where([title])":{textDecoration:"underline dotted"},"h1, h2, h3, h4, h5, h6":{fontSize:"inherit",fontWeight:"inherit"},a:{color:"inherit",textDecoration:"inherit"},"b, strong":{fontWeight:"bolder"},"code, kbd, samp, pre":{fontFamily:'ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace',fontFeatureSettings:" normal",fontVariationSettings:" normal",fontSize:"1em"},small:{fontSize:"80%"},"sub, sup":{fontSize:"75%",lineHeight:"0",position:"relative",verticalAlign:"baseline"},sub:{bottom:"-0.25em"},sup:{top:"-0.5em"},table:{textIndent:"0",borderColor:"inherit",borderCollapse:"collapse"},"button, input, optgroup, select, textarea":{fontFamily:"inherit",fontFeatureSettings:"inherit",fontVariationSettings:"inherit",fontSize:"100%",fontWeight:"inherit",lineHeight:"inherit",letterSpacing:"inherit",color:"inherit",margin:"0",padding:"0"},"button, select":{textTransform:"none"},"button, input:where([type='button']), input:where([type='reset']), input:where([type='submit'])":{WebkitAppearance:"button",backgroundColor:"transparent",backgroundImage:"none"},":-moz-focusring":{outline:"auto"},":-moz-ui-invalid":{boxShadow:"none"},progress:{verticalAlign:"baseline"},"::-webkit-inner-spin-button, ::-webkit-outer-spin-button":{height:"auto"},"[type='search']":{WebkitAppearance:"textfield",outlineOffset:"-2px"},"::-webkit-search-decoration":{WebkitAppearance:"none"},"::-webkit-file-upload-button":{WebkitAppearance:"button",font:"inherit"},summary:{display:"list-item"},"blockquote, dl, dd, h1, h2, h3, h4, h5, h6, hr, figure, p, pre":{margin:"0"},fieldset:{margin:"0",padding:"0"},legend:{padding:"0"},"ol, ul, menu":{listStyle:"none",margin:"0",padding:"0"},dialog:{padding:"0"},textarea:{resize:"vertical"},"input::placeholder, textarea::placeholder":{opacity:"1",color:"#9ca3af"},'button, [role="button"]':{cursor:"pointer"},":disabled":{cursor:"default"},"img, svg, video, canvas, audio, iframe, embed, object":{display:"block",verticalAlign:"middle"},"img, video":{maxWidth:"100%",height:"auto"},'[hidden]:where(:not([hidden="until-found"]))':{display:"none"},"::backdrop":{"--tw-border-spacing-x":"0","--tw-border-spacing-y":"0","--tw-translate-x":"0","--tw-translate-y":"0","--tw-rotate":"0","--tw-skew-x":"0","--tw-skew-y":"0","--tw-scale-x":"1","--tw-scale-y":"1","--tw-pan-x":"var(--tw-empty,/*!*/ /*!*/)","--tw-pan-y":"var(--tw-empty,/*!*/ /*!*/)","--tw-pinch-zoom":"var(--tw-empty,/*!*/ /*!*/)","--tw-scroll-snap-strictness":"proximity","--tw-gradient-from-position":"var(--tw-empty,/*!*/ /*!*/)","--tw-gradient-via-position":"var(--tw-empty,/*!*/ /*!*/)","--tw-gradient-to-position":"var(--tw-empty,/*!*/ /*!*/)","--tw-ordinal":"var(--tw-empty,/*!*/ /*!*/)","--tw-slashed-zero":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-figure":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-spacing":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-fraction":"var(--tw-empty,/*!*/ /*!*/)","--tw-ring-offset-shadow":"0 0 #0000","--tw-ring-shadow":"0 0 #0000","--tw-shadow":"0 0 #0000","--tw-shadow-colored":"0 0 #0000","--tw-ring-inset":"var(--tw-empty,/*!*/ /*!*/)","--tw-ring-offset-width":"0px","--tw-ring-offset-color":"#fff","--tw-ring-color":"rgb(59 130 246 / 0.5)","--tw-blur":"var(--tw-empty,/*!*/ /*!*/)","--tw-brightness":"var(--tw-empty,/*!*/ /*!*/)","--tw-contrast":"var(--tw-empty,/*!*/ /*!*/)","--tw-grayscale":"var(--tw-empty,/*!*/ /*!*/)","--tw-hue-rotate":"var(--tw-empty,/*!*/ /*!*/)","--tw-invert":"var(--tw-empty,/*!*/ /*!*/)","--tw-saturate":"var(--tw-empty,/*!*/ /*!*/)","--tw-sepia":"var(--tw-empty,/*!*/ /*!*/)","--tw-drop-shadow":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-blur":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-brightness":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-contrast":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-grayscale":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-hue-rotate":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-invert":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-opacity":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-saturate":"var(--tw-empty,/*!*/ /*!*/)","--tw-backdrop-sepia":"var(--tw-empty,/*!*/ /*!*/)","--tw-contain-size":"var(--tw-empty,/*!*/ /*!*/)","--tw-contain-layout":"var(--tw-empty,/*!*/ /*!*/)","--tw-contain-paint":"var(--tw-empty,/*!*/ /*!*/)","--tw-contain-style":"var(--tw-empty,/*!*/ /*!*/)"},"[type='text'],input:where(:not([type])),[type='email'],[type='url'],[type='password'],[type='number'],[type='date'],[type='datetime-local'],[type='month'],[type='search'],[type='tel'],[type='time'],[type='week'],[multiple],textarea,select":{appearance:"none",backgroundColor:"#fff",borderColor:"#6b7280",borderWidth:"1px",borderRadius:"0px",paddingTop:"0.5rem",paddingRight:"0.75rem",paddingBottom:"0.5rem",paddingLeft:"0.75rem",fontSize:"1rem",lineHeight:"1.5rem","--tw-shadow":"0 0 #0000"},"[type='text']:focus, input:where(:not([type])):focus, [type='email']:focus, [type='url']:focus, [type='password']:focus, [type='number']:focus, [type='date']:focus, [type='datetime-local']:focus, [type='month']:focus, [type='search']:focus, [type='tel']:focus, [type='time']:focus, [type='week']:focus, [multiple]:focus, textarea:focus, select:focus":{outline:"2px solid transparent",outlineOffset:"2px","--tw-ring-inset":"var(--tw-empty,/*!*/ /*!*/)","--tw-ring-offset-width":"0px","--tw-ring-offset-color":"#fff","--tw-ring-color":"#2563eb","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)",borderColor:"#2563eb"},"input::placeholder,textarea::placeholder":{color:"#6b7280",opacity:"1"},"::-webkit-datetime-edit-fields-wrapper":{padding:"0"},"::-webkit-date-and-time-value":{minHeight:"1.5em",textAlign:"inherit"},"::-webkit-datetime-edit":{display:"inline-flex"},"::-webkit-datetime-edit,::-webkit-datetime-edit-year-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute-field,::-webkit-datetime-edit-second-field,::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-meridiem-field":{paddingTop:"0",paddingBottom:"0"},select:{backgroundImage:"url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e\")",backgroundPosition:"right 0.5rem center",backgroundRepeat:"no-repeat",backgroundSize:"1.5em 1.5em",paddingRight:"2.5rem",printColorAdjust:"exact"},'[multiple],[size]:where(select:not([size="1"]))':{backgroundImage:"initial",backgroundPosition:"initial",backgroundRepeat:"unset",backgroundSize:"initial",paddingRight:"0.75rem",printColorAdjust:"unset"},"[type='checkbox'],[type='radio']":{appearance:"none",padding:"0",printColorAdjust:"exact",display:"inline-block",verticalAlign:"middle",backgroundOrigin:"border-box",userSelect:"none",flexShrink:"0",height:"1rem",width:"1rem",color:"#2563eb",backgroundColor:"#fff",borderColor:"#6b7280",borderWidth:"1px","--tw-shadow":"0 0 #0000"},"[type='checkbox']":{borderRadius:"0px"},"[type='radio']":{borderRadius:"100%"},"[type='checkbox']:focus,[type='radio']:focus":{outline:"2px solid transparent",outlineOffset:"2px","--tw-ring-inset":"var(--tw-empty,/*!*/ /*!*/)","--tw-ring-offset-width":"2px","--tw-ring-offset-color":"#fff","--tw-ring-color":"#2563eb","--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":"var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)",boxShadow:"var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)"},"[type='checkbox']:checked,[type='radio']:checked":{borderColor:"transparent",backgroundColor:"currentColor",backgroundSize:"100% 100%",backgroundPosition:"center",backgroundRepeat:"no-repeat"},"[type='checkbox']:checked":{backgroundImage:"url(\"data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e\")"},"@media (forced-colors: active)":{"[type='checkbox']:checked":{appearance:"auto"},"[type='radio']:checked":{appearance:"auto"},"[type='checkbox']:indeterminate":{appearance:"auto"}},"[type='radio']:checked":{backgroundImage:"url(\"data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e\")"},"[type='checkbox']:checked:hover,[type='checkbox']:checked:focus,[type='radio']:checked:hover,[type='radio']:checked:focus":{borderColor:"transparent",backgroundColor:"currentColor"},"[type='checkbox']:indeterminate":{backgroundImage:"url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='white' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h8'/%3e%3c/svg%3e\")",borderColor:"transparent",backgroundColor:"currentColor",backgroundSize:"100% 100%",backgroundPosition:"center",backgroundRepeat:"no-repeat"},"[type='checkbox']:indeterminate:hover,[type='checkbox']:indeterminate:focus":{borderColor:"transparent",backgroundColor:"currentColor"},"[type='file']":{background:"unset",borderColor:"inherit",borderWidth:"0",borderRadius:"0",padding:"0",fontSize:"unset",lineHeight:"inherit"},"[type='file']:focus":{outline:"1px auto -webkit-focus-ring-color"}}}
26
- `}),Gl(El,{styles:Tf})]}),Rf="/salary-packaging-configuration",Af=()=>{const e=window.location.hash.split("#").pop()||"",t=e.lastIndexOf(Rf);return t>-1?e.substring(0,t+31):"/"};!function(e,t,n,r){function i(){var t=Reflect.construct(HTMLElement,[],i);return t._vdomComponent=e,t._root=r&&r.shadow?t.attachShadow({mode:r.mode||"open"}):t,t}(i.prototype=Object.create(HTMLElement.prototype)).constructor=i,i.prototype.connectedCallback=ut,i.prototype.attributeChangedCallback=pt,i.prototype.disconnectedCallback=ht,n=n||e.observedAttributes||Object.keys(e.propTypes||{}),i.observedAttributes=n,n.forEach((function(e){Object.defineProperty(i.prototype,e,{get:function(){return this._vdom.props[e]},set:function(t){this._vdom?this.attributeChangedCallback(e,null,t):(this._props||(this._props={}),this._props[e]=t,this.connectedCallback());var n=typeof t;null!=t&&"string"!==n&&"boolean"!==n&&"number"!==n||this.setAttribute(e,t)}})})),customElements.define(t,i)}((e=>{const t=Mt(null),{EmotionProvider:n}=((e,t)=>{const[n,r]=Rt();return Ot((()=>{const n=e=>{t&&t.current?e():requestAnimationFrame((()=>n(e)))};n((()=>{r(Ss({container:t.current,key:e,speedy:!1}))}))}),[e,t]),{EmotionProvider:({children:e})=>n?Gl(ml,{value:n,children:e}):Gl(Dl,{})}})("superhero-salpac-profile-admin",t);return Nl(Dl,{children:[Gl("head",{ref:t}),Nl(n,{children:[Gl(Pf,{}),Gl(Jr,{client:hi(),children:Gl(va,{basename:Af(),children:Gl("body",{children:Gl(Cf,{backendUrl:e.backendUrl||"",accessToken:e.accessToken||"",accountId:e.accountId||""})})})})]})]})}),"superhero-salpac-profile-admin",["backend-url","access-token","account-id"],{shadow:!0})}();
26
+ `}),Dl(Sl,{styles:Cf})]}),Pf="/salary-packaging-configuration",Rf=()=>{const e=window.location.hash.split("#").pop()||"",t=e.lastIndexOf(Pf);return t>-1?e.substring(0,t+31):"/"};!function(e,t,n,r){function i(){var t=Reflect.construct(HTMLElement,[],i);return t._vdomComponent=e,t._root=r&&r.shadow?t.attachShadow({mode:r.mode||"open"}):t,t}(i.prototype=Object.create(HTMLElement.prototype)).constructor=i,i.prototype.connectedCallback=ut,i.prototype.attributeChangedCallback=pt,i.prototype.disconnectedCallback=ht,n=n||e.observedAttributes||Object.keys(e.propTypes||{}),i.observedAttributes=n,n.forEach((function(e){Object.defineProperty(i.prototype,e,{get:function(){return this._vdom.props[e]},set:function(t){this._vdom?this.attributeChangedCallback(e,null,t):(this._props||(this._props={}),this._props[e]=t,this.connectedCallback());var n=typeof t;null!=t&&"string"!==n&&"boolean"!==n&&"number"!==n||this.setAttribute(e,t)}})})),customElements.define(t,i)}((e=>{const t=Mt(null),{EmotionProvider:n}=((e,t)=>{const[n,r]=Rt();return Ot((()=>{const n=e=>{t&&t.current?e():requestAnimationFrame((()=>n(e)))};n((()=>{r(ks({container:t.current,key:e,speedy:!1}))}))}),[e,t]),{EmotionProvider:({children:e})=>n?Dl(vl,{value:n,children:e}):Dl(Il,{})}})("superhero-salpac-profile-admin",t);return Gl(Il,{children:[Dl("head",{ref:t}),Gl(n,{children:[Dl(Tf,{}),Dl(Jr,{client:pi(),children:Dl(fa,{basename:Rf(),children:Dl("body",{children:Dl(Ef,{backendUrl:e.backendUrl||"",accessToken:e.accessToken||"",accountId:e.accountId||""})})})})]})]})}),"superhero-salpac-profile-admin",["backend-url","access-token","account-id"],{shadow:!0})}();