@flarehr/promoted-benefits-admin 0.3.1680 → 0.3.1765
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +36 -36
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
var t,e,n,r,i,o,s,a,l,u,c,d,h,p,f,m,v,g,y,b,w,x,_,S,E,k,P,T,C,A,R,O,F,L,M,D,V,j,I,B,N,U,W,H,$,z,q,K,G,Y,Q,X,Z,J,tt,et,nt,rt,it,ot,st,at,lt,ut,ct,dt,ht,pt,ft,mt,vt,gt,yt=Object.defineProperty,bt=t=>{throw TypeError(t)},wt=(t,e,n)=>((t,e,n)=>e in t?yt(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n)(t,"symbol"!=typeof e?e+"":e,n),xt=(t,e,n)=>e.has(t)||bt("Cannot "+n),_t=(t,e,n)=>(xt(t,e,"read from private field"),n?n.call(t):e.get(t)),St=(t,e,n)=>e.has(t)?bt("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,n),Et=(t,e,n,r)=>(xt(t,e,"write to private field"),r?r.call(t,n):e.set(t,n),n),kt=(t,e,n)=>(xt(t,e,"access private method"),n),Pt=(t,e,n,r)=>({set _(r){Et(t,e,r,n)},get _(){return _t(t,e,r)}});!function(){const t=document.createElement("link").relList;if(!(t&&t.supports&&t.supports("modulepreload"))){for(const t of document.querySelectorAll('link[rel="modulepreload"]'))e(t);new MutationObserver((t=>{for(const n of t)if("childList"===n.type)for(const t of n.addedNodes)"LINK"===t.tagName&&"modulepreload"===t.rel&&e(t)})).observe(document,{childList:!0,subtree:!0})}function e(t){if(t.ep)return;t.ep=!0;const e=function(t){const e={};return t.integrity&&(e.integrity=t.integrity),t.referrerPolicy&&(e.referrerPolicy=t.referrerPolicy),"use-credentials"===t.crossOrigin?e.credentials="include":"anonymous"===t.crossOrigin?e.credentials="omit":e.credentials="same-origin",e}(t);fetch(t.href,e)}}();var Tt,Ct,At,Rt,Ot,Ft,Lt,Mt,Dt,Vt,jt,It={},Bt=[],Nt=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Ut=Array.isArray;function Wt(t,e){for(var n in e)t[n]=e[n];return t}function Ht(t){var e=t.parentNode;e&&e.removeChild(t)}function $t(t,e,n){var r,i,o,s={};for(o in e)"key"==o?r=e[o]:"ref"==o?i=e[o]:s[o]=e[o];if(arguments.length>2&&(s.children=arguments.length>3?Tt.call(arguments,2):n),"function"==typeof t&&null!=t.defaultProps)for(o in t.defaultProps)void 0===s[o]&&(s[o]=t.defaultProps[o]);return zt(t,s,r,i,null)}function zt(t,e,n,r,i){var o={type:t,props:e,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==i?++At:i,__i:-1,__u:0};return null==i&&null!=Ct.vnode&&Ct.vnode(o),o}function qt(){return{current:null}}function Kt(t){return t.children}function Gt(t,e){this.props=t,this.context=e}function Yt(t,e){if(null==e)return t.__?Yt(t.__,t.__i+1):null;for(var n;e<t.__k.length;e++)if(null!=(n=t.__k[e])&&null!=n.__e)return n.__e;return"function"==typeof t.type?Yt(t):null}function Qt(t){var e,n;if(null!=(t=t.__)&&null!=t.__c){for(t.__e=t.__c.base=null,e=0;e<t.__k.length;e++)if(null!=(n=t.__k[e])&&null!=n.__e){t.__e=t.__c.base=n.__e;break}return Qt(t)}}function Xt(t){(!t.__d&&(t.__d=!0)&&Rt.push(t)&&!Zt.__r++||Ot!==Ct.debounceRendering)&&((Ot=Ct.debounceRendering)||Ft)(Zt)}function Zt(){var t,e,n,r,i,o,s,a;for(Rt.sort(Lt);t=Rt.shift();)t.__d&&(e=Rt.length,r=void 0,o=(i=(n=t).__v).__e,s=[],a=[],n.__P&&((r=Wt({},i)).__v=i.__v+1,Ct.vnode&&Ct.vnode(r),se(n.__P,r,i,n.__n,n.__P.namespaceURI,32&i.__u?[o]:null,s,null==o?Yt(i):o,!!(32&i.__u),a),r.__v=i.__v,r.__.__k[r.__i]=r,ae(s,r,a),r.__e!=o&&Qt(r)),Rt.length>e&&Rt.sort(Lt));Zt.__r=0}function Jt(t,e,n,r,i,o,s,a,l,u,c){var d,h,p,f,m,v=r&&r.__k||Bt,g=e.length;for(n.__d=l,function(t,e,n){var r,i,o,s,a,l=e.length,u=n.length,c=u,d=0;for(t.__k=[],r=0;r<l;r++)s=r+d,null!=(i=t.__k[r]=null==(i=e[r])||"boolean"==typeof i||"function"==typeof i?null:"string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?zt(null,i,null,null,null):Ut(i)?zt(Kt,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?zt(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)?(i.__=t,i.__b=t.__b+1,a=ne(i,n,s,c),i.__i=a,o=null,-1!==a&&(c--,(o=n[a])&&(o.__u|=131072)),null==o||null===o.__v?(-1==a&&d--,"function"!=typeof i.type&&(i.__u|=65536)):a!==s&&(a==s-1?d--:a==s+1?d++:a>s?c>l-s?d+=a-s:d--:a<s&&(a==s-d?d-=a-s:d++),a!==r+d&&(i.__u|=65536))):(o=n[s])&&null==o.key&&o.__e&&!(131072&o.__u)&&(o.__e==t.__d&&(t.__d=Yt(o)),ue(o,o,!1),n[s]=null,c--);if(c)for(r=0;r<u;r++)null!=(o=n[r])&&!(131072&o.__u)&&(o.__e==t.__d&&(t.__d=Yt(o)),ue(o,o))}(n,e,v),l=n.__d,d=0;d<g;d++)null!=(p=n.__k[d])&&"boolean"!=typeof p&&"function"!=typeof p&&(h=-1===p.__i?It:v[p.__i]||It,p.__i=d,se(t,p,h,i,o,s,a,l,u,c),f=p.__e,p.ref&&h.ref!=p.ref&&(h.ref&&le(h.ref,null,p),c.push(p.ref,p.__c||f,p)),null==m&&null!=f&&(m=f),65536&p.__u||h.__k===p.__k?l=te(p,l,t):"function"==typeof p.type&&void 0!==p.__d?l=p.__d:f&&(l=f.nextSibling),p.__d=void 0,p.__u&=-196609);n.__d=l,n.__e=m}function te(t,e,n){var r,i;if("function"==typeof t.type){for(r=t.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=t,e=te(r[i],e,n));return e}t.__e!=e&&(e&&t.type&&!n.contains(e)&&(e=Yt(t)),n.insertBefore(t.__e,e||null),e=t.__e);do{e=e&&e.nextSibling}while(null!=e&&8===e.nodeType);return e}function ee(t,e){return e=e||[],null==t||"boolean"==typeof t||(Ut(t)?t.some((function(t){ee(t,e)})):e.push(t)),e}function ne(t,e,n,r){var i=t.key,o=t.type,s=n-1,a=n+1,l=e[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(;s>=0||a<e.length;){if(s>=0){if((l=e[s])&&!(131072&l.__u)&&i==l.key&&o===l.type)return s;s--}if(a<e.length){if((l=e[a])&&!(131072&l.__u)&&i==l.key&&o===l.type)return a;a++}}return-1}function re(t,e,n){"-"===e[0]?t.setProperty(e,null==n?"":n):t[e]=null==n?"":"number"!=typeof n||Nt.test(e)?n:n+"px"}function ie(t,e,n,r,i){var o;t:if("style"===e)if("string"==typeof n)t.style.cssText=n;else{if("string"==typeof r&&(t.style.cssText=r=""),r)for(e in r)n&&e in n||re(t.style,e,"");if(n)for(e in n)r&&n[e]===r[e]||re(t.style,e,n[e])}else if("o"===e[0]&&"n"===e[1])o=e!==(e=e.replace(/(PointerCapture)$|Capture$/i,"$1")),e=e.toLowerCase()in t||"onFocusOut"===e||"onFocusIn"===e?e.toLowerCase().slice(2):e.slice(2),t.l||(t.l={}),t.l[e+o]=n,n?r?n.u=r.u:(n.u=Mt,t.addEventListener(e,o?Vt:Dt,o)):t.removeEventListener(e,o?Vt:Dt,o);else{if("http://www.w3.org/2000/svg"==i)e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=e&&"height"!=e&&"href"!=e&&"list"!=e&&"form"!=e&&"tabIndex"!=e&&"download"!=e&&"rowSpan"!=e&&"colSpan"!=e&&"role"!=e&&"popover"!=e&&e in t)try{t[e]=null==n?"":n;break t}catch(s){}"function"==typeof n||(null==n||!1===n&&"-"!==e[4]?t.removeAttribute(e):t.setAttribute(e,"popover"==e&&1==n?"":n))}}function oe(t){return function(e){if(this.l){var n=this.l[e.type+t];if(null==e.t)e.t=Mt++;else if(e.t<n.u)return;return n(Ct.event?Ct.event(e):e)}}}function se(t,e,n,r,i,o,s,a,l,u){var c,d,h,p,f,m,v,g,y,b,w,x,_,S,E,k,P=e.type;if(void 0!==e.constructor)return null;128&n.__u&&(l=!!(32&n.__u),o=[a=e.__e=n.__e]),(c=Ct.__b)&&c(e);t:if("function"==typeof P)try{if(g=e.props,y="prototype"in P&&P.prototype.render,b=(c=P.contextType)&&r[c.__c],w=c?b?b.props.value:c.__:r,n.__c?v=(d=e.__c=n.__c).__=d.__E:(y?e.__c=d=new P(g,w):(e.__c=d=new Gt(g,w),d.constructor=P,d.render=ce),b&&b.sub(d),d.props=g,d.state||(d.state={}),d.context=w,d.__n=r,h=d.__d=!0,d.__h=[],d._sb=[]),y&&null==d.__s&&(d.__s=d.state),y&&null!=P.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=Wt({},d.__s)),Wt(d.__s,P.getDerivedStateFromProps(g,d.__s))),p=d.props,f=d.state,d.__v=e,h)y&&null==P.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),y&&null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(y&&null==P.getDerivedStateFromProps&&g!==p&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(g,w),!d.__e&&(null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(g,d.__s,w)||e.__v===n.__v)){for(e.__v!==n.__v&&(d.props=g,d.state=d.__s,d.__d=!1),e.__e=n.__e,e.__k=n.__k,e.__k.forEach((function(t){t&&(t.__=e)})),x=0;x<d._sb.length;x++)d.__h.push(d._sb[x]);d._sb=[],d.__h.length&&s.push(d);break t}null!=d.componentWillUpdate&&d.componentWillUpdate(g,d.__s,w),y&&null!=d.componentDidUpdate&&d.__h.push((function(){d.componentDidUpdate(p,f,m)}))}if(d.context=w,d.props=g,d.__P=t,d.__e=!1,_=Ct.__r,S=0,y){for(d.state=d.__s,d.__d=!1,_&&_(e),c=d.render(d.props,d.state,d.context),E=0;E<d._sb.length;E++)d.__h.push(d._sb[E]);d._sb=[]}else do{d.__d=!1,_&&_(e),c=d.render(d.props,d.state,d.context),d.state=d.__s}while(d.__d&&++S<25);d.state=d.__s,null!=d.getChildContext&&(r=Wt(Wt({},r),d.getChildContext())),y&&!h&&null!=d.getSnapshotBeforeUpdate&&(m=d.getSnapshotBeforeUpdate(p,f)),Jt(t,Ut(k=null!=c&&c.type===Kt&&null==c.key?c.props.children:c)?k:[k],e,n,r,i,o,s,a,l,u),d.base=e.__e,e.__u&=-161,d.__h.length&&s.push(d),v&&(d.__E=d.__=null)}catch(T){if(e.__v=null,l||null!=o){for(e.__u|=l?160:32;a&&8===a.nodeType&&a.nextSibling;)a=a.nextSibling;o[o.indexOf(a)]=null,e.__e=a}else e.__e=n.__e,e.__k=n.__k;Ct.__e(T,e,n)}else null==o&&e.__v===n.__v?(e.__k=n.__k,e.__e=n.__e):e.__e=function(t,e,n,r,i,o,s,a,l){var u,c,d,h,p,f,m,v=n.props,g=e.props,y=e.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(u=0;u<o.length;u++)if((p=o[u])&&"setAttribute"in p==!!y&&(y?p.localName===y:3===p.nodeType)){t=p,o[u]=null;break}if(null==t){if(null===y)return document.createTextNode(g);t=document.createElementNS(i,y,g.is&&g),o=null,a=!1}if(null===y)v===g||a&&t.data===g||(t.data=g);else{if(o=o&&Tt.call(t.childNodes),v=n.props||It,!a&&null!=o)for(v={},u=0;u<t.attributes.length;u++)v[(p=t.attributes[u]).name]=p.value;for(u in v)if(p=v[u],"children"==u);else if("dangerouslySetInnerHTML"==u)d=p;else if("key"!==u&&!(u in g)){if("value"==u&&"defaultValue"in g||"checked"==u&&"defaultChecked"in g)continue;ie(t,u,null,p,i)}for(u in g)p=g[u],"children"==u?h=p:"dangerouslySetInnerHTML"==u?c=p:"value"==u?f=p:"checked"==u?m=p:"key"===u||a&&"function"!=typeof p||v[u]===p||ie(t,u,p,v[u],i);if(c)a||d&&(c.__html===d.__html||c.__html===t.innerHTML)||(t.innerHTML=c.__html),e.__k=[];else if(d&&(t.innerHTML=""),Jt(t,Ut(h)?h:[h],e,n,r,"foreignObject"===y?"http://www.w3.org/1999/xhtml":i,o,s,o?o[0]:n.__k&&Yt(n,0),a,l),null!=o)for(u=o.length;u--;)null!=o[u]&&Ht(o[u]);a||(u="value",void 0!==f&&(f!==t[u]||"progress"===y&&!f||"option"===y&&f!==v[u])&&ie(t,u,f,v[u],i),u="checked",void 0!==m&&m!==t[u]&&ie(t,u,m,v[u],i))}return t}(n.__e,e,n,r,i,o,s,l,u);(c=Ct.diffed)&&c(e)}function ae(t,e,n){e.__d=void 0;for(var r=0;r<n.length;r++)le(n[r],n[++r],n[++r]);Ct.__c&&Ct.__c(e,t),t.some((function(e){try{t=e.__h,e.__h=[],t.some((function(t){t.call(e)}))}catch(n){Ct.__e(n,e.__v)}}))}function le(t,e,n){try{if("function"==typeof t){var r="function"==typeof t.__u;r&&t.__u(),r&&null==e||(t.__u=t(e))}else t.current=e}catch(i){Ct.__e(i,n)}}function ue(t,e,n){var r,i;if(Ct.unmount&&Ct.unmount(t),(r=t.ref)&&(r.current&&r.current!==t.__e||le(r,null,e)),null!=(r=t.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(o){Ct.__e(o,e)}r.base=r.__P=null}if(r=t.__k)for(i=0;i<r.length;i++)r[i]&&ue(r[i],e,n||"function"!=typeof t.type);n||null==t.__e||Ht(t.__e),t.__c=t.__=t.__e=t.__d=void 0}function ce(t,e,n){return this.constructor(t,n)}function de(t,e,n){var r,i,o,s;Ct.__&&Ct.__(t,e),i=(r="function"==typeof n)?null:n&&n.__k||e.__k,o=[],s=[],se(e,t=(!r&&n||e).__k=$t(Kt,null,[t]),i||It,It,e.namespaceURI,!r&&n?[n]:i?null:e.firstChild?Tt.call(e.childNodes):null,o,!r&&n?n:i?i.__e:e.firstChild,r,s),ae(o,t,s)}function he(t,e){de(t,e,he)}function pe(t,e,n){var r,i,o,s,a=Wt({},t.props);for(o in t.type&&t.type.defaultProps&&(s=t.type.defaultProps),e)"key"==o?r=e[o]:"ref"==o?i=e[o]:a[o]=void 0===e[o]&&void 0!==s?s[o]:e[o];return arguments.length>2&&(a.children=arguments.length>3?Tt.call(arguments,2):n),zt(t.type,a,r||t.key,i||t.ref,null)}function fe(t,e){var n={__c:e="__cC"+jt++,__:t,Consumer:function(t,e){return t.children(e)},Provider:function(t){var n,r;return this.getChildContext||(n=[],(r={})[e]=this,this.getChildContext=function(){return r},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(t){this.props.value!==t.value&&n.some((function(t){t.__e=!0,Xt(t)}))},this.sub=function(t){n.push(t);var e=t.componentWillUnmount;t.componentWillUnmount=function(){n&&n.splice(n.indexOf(t),1),e&&e.call(t)}}),t.children}};return n.Provider.__=n.Consumer.contextType=n}function me(){return(me=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t}).apply(this,arguments)}Tt=Bt.slice,Ct={__e:function(t,e,n,r){for(var i,o,s;e=e.__;)if((i=e.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(t)),s=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(t,r||{}),s=i.__d),s)return i.__E=i}catch(a){t=a}throw t}},At=0,Gt.prototype.setState=function(t,e){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=Wt({},this.state),"function"==typeof t&&(t=t(Wt({},n),this.props)),t&&Wt(n,t),null!=t&&this.__v&&(e&&this._sb.push(e),Xt(this))},Gt.prototype.forceUpdate=function(t){this.__v&&(this.__e=!0,t&&this.__h.push(t),Xt(this))},Gt.prototype.render=Kt,Rt=[],Ft="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Lt=function(t,e){return t.__v.__b-e.__v.__b},Zt.__r=0,Mt=0,Dt=oe(!1),Vt=oe(!0),jt=0;var ve=["context","children"];function ge(t){return this.getChildContext=function(){return t.context},pe(t.children,function(t,e){if(null==t)return{};var n,r,i={},o=Object.keys(t);for(r=0;r<o.length;r++)e.indexOf(n=o[r])>=0||(i[n]=t[n]);return i}(t,ve))}function ye(){var t=new CustomEvent("_preact",{detail:{},bubbles:!0,cancelable:!0});this.dispatchEvent(t),this._vdom=$t(ge,me({},this._props,{context:t.detail.context}),function t(e,n){if(3===e.nodeType)return e.data;if(1!==e.nodeType)return null;var r=[],i={},o=0,s=e.attributes,a=e.childNodes;for(o=s.length;o--;)"slot"!==s[o].name&&(i[s[o].name]=s[o].value,i[be(s[o].name)]=s[o].value);for(o=a.length;o--;){var l=t(a[o],null),u=a[o].slot;u?i[u]=$t(_e,{name:u},l):r[o]=l}var c=n?$t(_e,null,r):r;return $t(n||e.nodeName.toLowerCase(),i,c)}(this,this._vdomComponent)),(this.hasAttribute("hydrate")?he:de)(this._vdom,this._root)}function be(t){return t.replace(/-(\w)/g,(function(t,e){return e?e.toUpperCase():""}))}function we(t,e,n){if(this._vdom){var r={};r[t]=n=null==n?void 0:n,r[be(t)]=n,this._vdom=pe(this._vdom,r),de(this._vdom,this._root)}}function xe(){de(this._vdom=null,this._root)}function _e(t,e){var n=this;return $t("slot",me({},t,{ref:function(t){t?(n.ref=t,n._listener||(n._listener=function(t){t.stopPropagation(),t.detail.context=e},t.addEventListener("_preact",n._listener))):n.ref.removeEventListener("_preact",n._listener)}}))}var Se=function(){function t(t){var e=this;this._insertTag=function(t){var n;n=0===e.tags.length?e.insertionPoint?e.insertionPoint.nextSibling:e.prepend?e.container.firstChild:e.before:e.tags[e.tags.length-1].nextSibling,e.container.insertBefore(t,n),e.tags.push(t)},this.isSpeedy=void 0===t.speedy||t.speedy,this.tags=[],this.ctr=0,this.nonce=t.nonce,this.key=t.key,this.container=t.container,this.prepend=t.prepend,this.insertionPoint=t.insertionPoint,this.before=null}var e=t.prototype;return e.hydrate=function(t){t.forEach(this._insertTag)},e.insert=function(t){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(t){var e=document.createElement("style");return e.setAttribute("data-emotion",t.key),void 0!==t.nonce&&e.setAttribute("nonce",t.nonce),e.appendChild(document.createTextNode("")),e.setAttribute("data-s",""),e}(this));var e=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(t){if(t.sheet)return t.sheet;for(var e=0;e<document.styleSheets.length;e++)if(document.styleSheets[e].ownerNode===t)return document.styleSheets[e]}(e);try{n.insertRule(t,n.cssRules.length)}catch(yy){}}else e.appendChild(document.createTextNode(t));this.ctr++},e.flush=function(){this.tags.forEach((function(t){var e;return null==(e=t.parentNode)?void 0:e.removeChild(t)})),this.tags=[],this.ctr=0},t}(),Ee="-ms-",ke="-moz-",Pe="-webkit-",Te="comm",Ce="rule",Ae="decl",Re="@keyframes",Oe=Math.abs,Fe=String.fromCharCode,Le=Object.assign;function Me(t){return t.trim()}function De(t,e,n){return t.replace(e,n)}function Ve(t,e){return t.indexOf(e)}function je(t,e){return 0|t.charCodeAt(e)}function Ie(t,e,n){return t.slice(e,n)}function Be(t){return t.length}function Ne(t){return t.length}function Ue(t,e){return e.push(t),t}var We=1,He=1,$e=0,ze=0,qe=0,Ke="";function Ge(t,e,n,r,i,o,s){return{value:t,root:e,parent:n,type:r,props:i,children:o,line:We,column:He,length:s,return:""}}function Ye(t,e){return Le(Ge("",null,null,"",null,null,0),t,{length:-t.length},e)}function Qe(){return qe=ze<$e?je(Ke,ze++):0,He++,10===qe&&(He=1,We++),qe}function Xe(){return je(Ke,ze)}function Ze(){return ze}function Je(t,e){return Ie(Ke,t,e)}function tn(t){switch(t){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 en(t){return We=He=1,$e=Be(Ke=t),ze=0,[]}function nn(t){return Ke="",t}function rn(t){return Me(Je(ze-1,an(91===t?t+2:40===t?t+1:t)))}function on(t){for(;(qe=Xe())&&qe<33;)Qe();return tn(t)>2||tn(qe)>3?"":" "}function sn(t,e){for(;--e&&Qe()&&!(qe<48||qe>102||qe>57&&qe<65||qe>70&&qe<97););return Je(t,Ze()+(e<6&&32==Xe()&&32==Qe()))}function an(t){for(;Qe();)switch(qe){case t:return ze;case 34:case 39:34!==t&&39!==t&&an(qe);break;case 40:41===t&&an(t);break;case 92:Qe()}return ze}function ln(t,e){for(;Qe()&&t+qe!==57&&(t+qe!==84||47!==Xe()););return"/*"+Je(e,ze-1)+"*"+Fe(47===t?t:Qe())}function un(t){for(;!tn(Xe());)Qe();return Je(t,ze)}function cn(t){return nn(dn("",null,null,null,[""],t=en(t),0,[0],t))}function dn(t,e,n,r,i,o,s,a,l){for(var u=0,c=0,d=s,h=0,p=0,f=0,m=1,v=1,g=1,y=0,b="",w=i,x=o,_=r,S=b;v;)switch(f=y,y=Qe()){case 40:if(108!=f&&58==je(S,d-1)){-1!=Ve(S+=De(rn(y),"&","&\f"),"&\f")&&(g=-1);break}case 34:case 39:case 91:S+=rn(y);break;case 9:case 10:case 13:case 32:S+=on(f);break;case 92:S+=sn(Ze()-1,7);continue;case 47:switch(Xe()){case 42:case 47:Ue(pn(ln(Qe(),Ze()),e,n),l);break;default:S+="/"}break;case 123*m:a[u++]=Be(S)*g;case 125*m:case 59:case 0:switch(y){case 0:case 125:v=0;case 59+c:-1==g&&(S=De(S,/\f/g,"")),p>0&&Be(S)-d&&Ue(p>32?fn(S+";",r,n,d-1):fn(De(S," ","")+";",r,n,d-2),l);break;case 59:S+=";";default:if(Ue(_=hn(S,e,n,u,c,i,a,b,w=[],x=[],d),o),123===y)if(0===c)dn(S,e,_,_,w,o,d,a,x);else switch(99===h&&110===je(S,3)?100:h){case 100:case 108:case 109:case 115:dn(t,_,_,r&&Ue(hn(t,_,_,0,0,i,a,b,i,w=[],d),x),i,x,d,a,r?w:x);break;default:dn(S,_,_,_,[""],x,0,a,x)}}u=c=p=0,m=g=1,b=S="",d=s;break;case 58:d=1+Be(S),p=f;default:if(m<1)if(123==y)--m;else if(125==y&&0==m++&&125==(qe=ze>0?je(Ke,--ze):0,He--,10===qe&&(He=1,We--),qe))continue;switch(S+=Fe(y),y*m){case 38:g=c>0?1:(S+="\f",-1);break;case 44:a[u++]=(Be(S)-1)*g,g=1;break;case 64:45===Xe()&&(S+=rn(Qe())),h=Xe(),c=d=Be(b=S+=un(Ze())),y++;break;case 45:45===f&&2==Be(S)&&(m=0)}}return o}function hn(t,e,n,r,i,o,s,a,l,u,c){for(var d=i-1,h=0===i?o:[""],p=Ne(h),f=0,m=0,v=0;f<r;++f)for(var g=0,y=Ie(t,d+1,d=Oe(m=s[f])),b=t;g<p;++g)(b=Me(m>0?h[g]+" "+y:De(y,/&\f/g,h[g])))&&(l[v++]=b);return Ge(t,e,n,0===i?Ce:a,l,u,c)}function pn(t,e,n){return Ge(t,e,n,Te,Fe(qe),Ie(t,2,-2),0)}function fn(t,e,n,r){return Ge(t,e,n,Ae,Ie(t,0,r),Ie(t,r+1,-1),r)}function mn(t,e){for(var n="",r=Ne(t),i=0;i<r;i++)n+=e(t[i],i,t,e)||"";return n}function vn(t,e,n,r){switch(t.type){case"@layer":if(t.children.length)break;case"@import":case Ae:return t.return=t.return||t.value;case Te:return"";case Re:return t.return=t.value+"{"+mn(t.children,r)+"}";case Ce:t.value=t.props.join(",")}return Be(n=mn(t.children,r))?t.return=t.value+"{"+n+"}":""}function gn(t){var e=Object.create(null);return function(n){return void 0===e[n]&&(e[n]=t(n)),e[n]}}var yn=function(t,e,n){for(var r=0,i=0;r=i,i=Xe(),38===r&&12===i&&(e[n]=1),!tn(i);)Qe();return Je(t,ze)},bn=function(t,e){return nn(function(t,e){var n=-1,r=44;do{switch(tn(r)){case 0:38===r&&12===Xe()&&(e[n]=1),t[n]+=yn(ze-1,e,n);break;case 2:t[n]+=rn(r);break;case 4:if(44===r){t[++n]=58===Xe()?"&\f":"",e[n]=t[n].length;break}default:t[n]+=Fe(r)}}while(r=Qe());return t}(en(t),e))},wn=new WeakMap,xn=function(t){if("rule"===t.type&&t.parent&&!(t.length<1)){for(var e=t.value,n=t.parent,r=t.column===n.column&&t.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==t.props.length||58===e.charCodeAt(0)||wn.get(n))&&!r){wn.set(t,!0);for(var i=[],o=bn(e,i),s=n.props,a=0,l=0;a<o.length;a++)for(var u=0;u<s.length;u++,l++)t.props[l]=i[a]?o[a].replace(/&\f/g,s[u]):s[u]+" "+o[a]}}},_n=function(t){if("decl"===t.type){var e=t.value;108===e.charCodeAt(0)&&98===e.charCodeAt(2)&&(t.return="",t.value="")}};function Sn(t,e){switch(function(t,e){return 45^je(t,0)?(((e<<2^je(t,0))<<2^je(t,1))<<2^je(t,2))<<2^je(t,3):0}(t,e)){case 5103:return Pe+"print-"+t+t;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 Pe+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return Pe+t+ke+t+Ee+t+t;case 6828:case 4268:return Pe+t+Ee+t+t;case 6165:return Pe+t+Ee+"flex-"+t+t;case 5187:return Pe+t+De(t,/(\w+).+(:[^]+)/,Pe+"box-$1$2"+Ee+"flex-$1$2")+t;case 5443:return Pe+t+Ee+"flex-item-"+De(t,/flex-|-self/,"")+t;case 4675:return Pe+t+Ee+"flex-line-pack"+De(t,/align-content|flex-|-self/,"")+t;case 5548:return Pe+t+Ee+De(t,"shrink","negative")+t;case 5292:return Pe+t+Ee+De(t,"basis","preferred-size")+t;case 6060:return Pe+"box-"+De(t,"-grow","")+Pe+t+Ee+De(t,"grow","positive")+t;case 4554:return Pe+De(t,/([^-])(transform)/g,"$1"+Pe+"$2")+t;case 6187:return De(De(De(t,/(zoom-|grab)/,Pe+"$1"),/(image-set)/,Pe+"$1"),t,"")+t;case 5495:case 3959:return De(t,/(image-set\([^]*)/,Pe+"$1$`$1");case 4968:return De(De(t,/(.+:)(flex-)?(.*)/,Pe+"box-pack:$3"+Ee+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Pe+t+t;case 4095:case 3583:case 4068:case 2532:return De(t,/(.+)-inline(.+)/,Pe+"$1$2")+t;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(Be(t)-1-e>6)switch(je(t,e+1)){case 109:if(45!==je(t,e+4))break;case 102:return De(t,/(.+:)(.+)-([^]+)/,"$1"+Pe+"$2-$3$1"+ke+(108==je(t,e+3)?"$3":"$2-$3"))+t;case 115:return~Ve(t,"stretch")?Sn(De(t,"stretch","fill-available"),e)+t:t}break;case 4949:if(115!==je(t,e+1))break;case 6444:switch(je(t,Be(t)-3-(~Ve(t,"!important")&&10))){case 107:return De(t,":",":"+Pe)+t;case 101:return De(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Pe+(45===je(t,14)?"inline-":"")+"box$3$1"+Pe+"$2$3$1"+Ee+"$2box$3")+t}break;case 5936:switch(je(t,e+11)){case 114:return Pe+t+Ee+De(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return Pe+t+Ee+De(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return Pe+t+Ee+De(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return Pe+t+Ee+t+t}return t}var En,kn,Pn,Tn,Cn=[function(t,e,n,r){if(t.length>-1&&!t.return)switch(t.type){case Ae:t.return=Sn(t.value,t.length);break;case Re:return mn([Ye(t,{value:De(t.value,"@","@"+Pe)})],r);case Ce:if(t.length)return function(t,e){return t.map(e).join("")}(t.props,(function(e){switch(function(t,e){return(t=e.exec(t))?t[0]:t}(e,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return mn([Ye(t,{props:[De(e,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return mn([Ye(t,{props:[De(e,/:(plac\w+)/,":"+Pe+"input-$1")]}),Ye(t,{props:[De(e,/:(plac\w+)/,":-moz-$1")]}),Ye(t,{props:[De(e,/:(plac\w+)/,Ee+"input-$1")]})],r)}return""}))}}],An=function(t){var e=t.key;if("css"===e){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(t){-1!==t.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(t),t.setAttribute("data-s",""))}))}var r,i,o=t.stylisPlugins||Cn,s={},a=[];r=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+e+' "]'),(function(t){for(var e=t.getAttribute("data-emotion").split(" "),n=1;n<e.length;n++)s[e[n]]=!0;a.push(t)}));var l,u,c,d,h=[vn,(d=function(t){l.insert(t)},function(t){t.root||(t=t.return)&&d(t)})],p=(u=[xn,_n].concat(o,h),c=Ne(u),function(t,e,n,r){for(var i="",o=0;o<c;o++)i+=u[o](t,e,n,r)||"";return i});i=function(t,e,n,r){l=n,mn(cn(t?t+"{"+e.styles+"}":e.styles),p),r&&(f.inserted[e.name]=!0)};var f={key:e,sheet:new Se({key:e,container:r,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:s,registered:{},insert:i};return f.sheet.hydrate(a),f},Rn=0,On=[],Fn=Ct,Ln=Fn.__b,Mn=Fn.__r,Dn=Fn.diffed,Vn=Fn.__c,jn=Fn.unmount,In=Fn.__;function Bn(t,e){Fn.__h&&Fn.__h(kn,t,Rn||e),Rn=0;var n=kn.__H||(kn.__H={__:[],__h:[]});return t>=n.__.length&&n.__.push({}),n.__[t]}function Nn(t){return Rn=1,Un(rr,t)}function Un(t,e,n){var r=Bn(En++,2);if(r.t=t,!r.__c&&(r.__=[n?n(e):rr(void 0,e),function(t){var e=r.__N?r.__N[0]:r.__[0],n=r.t(e,t);e!==n&&(r.__N=[n,r.__[1]],r.__c.setState({}))}],r.__c=kn,!kn.u)){var i=function(t,e,n){if(!r.__c.__H)return!0;var i=r.__c.__H.__.filter((function(t){return!!t.__c}));if(i.every((function(t){return!t.__N})))return!o||o.call(this,t,e,n);var s=!1;return i.forEach((function(t){if(t.__N){var e=t.__[0];t.__=t.__N,t.__N=void 0,e!==t.__[0]&&(s=!0)}})),!(!s&&r.__c.props===t)&&(!o||o.call(this,t,e,n))};kn.u=!0;var o=kn.shouldComponentUpdate,s=kn.componentWillUpdate;kn.componentWillUpdate=function(t,e,n){if(this.__e){var r=o;o=void 0,i(t,e,n),o=r}s&&s.call(this,t,e,n)},kn.shouldComponentUpdate=i}return r.__N||r.__}function Wn(t,e){var n=Bn(En++,3);!Fn.__s&&nr(n.__H,e)&&(n.__=t,n.i=e,kn.__H.__h.push(n))}function Hn(t,e){var n=Bn(En++,4);!Fn.__s&&nr(n.__H,e)&&(n.__=t,n.i=e,kn.__h.push(n))}function $n(t){return Rn=5,qn((function(){return{current:t}}),[])}function zn(t,e,n){Rn=6,Hn((function(){return"function"==typeof t?(t(e()),function(){return t(null)}):t?(t.current=e(),function(){return t.current=null}):void 0}),null==n?n:n.concat(t))}function qn(t,e){var n=Bn(En++,7);return nr(n.__H,e)&&(n.__=t(),n.__H=e,n.__h=t),n.__}function Kn(t,e){return Rn=8,qn((function(){return t}),e)}function Gn(t){var e=kn.context[t.__c],n=Bn(En++,9);return n.c=t,e?(null==n.__&&(n.__=!0,e.sub(kn)),e.props.value):t.__}function Yn(t,e){Fn.useDebugValue&&Fn.useDebugValue(e?e(t):t)}function Qn(){var t=Bn(En++,11);if(!t.__){for(var e=kn.__v;null!==e&&!e.__m&&null!==e.__;)e=e.__;var n=e.__m||(e.__m=[0,0]);t.__="P"+n[0]+"-"+n[1]++}return t.__}function Xn(){for(var t;t=On.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach(tr),t.__H.__h.forEach(er),t.__H.__h=[]}catch(_b){t.__H.__h=[],Fn.__e(_b,t.__v)}}Fn.__b=function(t){kn=null,Ln&&Ln(t)},Fn.__=function(t,e){t&&e.__k&&e.__k.__m&&(t.__m=e.__k.__m),In&&In(t,e)},Fn.__r=function(t){Mn&&Mn(t),En=0;var e=(kn=t.__c).__H;e&&(Pn===kn?(e.__h=[],kn.__h=[],e.__.forEach((function(t){t.__N&&(t.__=t.__N),t.i=t.__N=void 0}))):(e.__h.forEach(tr),e.__h.forEach(er),e.__h=[],En=0)),Pn=kn},Fn.diffed=function(t){Dn&&Dn(t);var e=t.__c;e&&e.__H&&(e.__H.__h.length&&(1!==On.push(e)&&Tn===Fn.requestAnimationFrame||((Tn=Fn.requestAnimationFrame)||Jn)(Xn)),e.__H.__.forEach((function(t){t.i&&(t.__H=t.i),t.i=void 0}))),Pn=kn=null},Fn.__c=function(t,e){e.some((function(t){try{t.__h.forEach(tr),t.__h=t.__h.filter((function(t){return!t.__||er(t)}))}catch(eb){e.some((function(t){t.__h&&(t.__h=[])})),e=[],Fn.__e(eb,t.__v)}})),Vn&&Vn(t,e)},Fn.unmount=function(t){jn&&jn(t);var e,n=t.__c;n&&n.__H&&(n.__H.__.forEach((function(t){try{tr(t)}catch(n){e=n}})),n.__H=void 0,e&&Fn.__e(e,n.__v))};var Zn="function"==typeof requestAnimationFrame;function Jn(t){var e,n=function(){clearTimeout(r),Zn&&cancelAnimationFrame(e),setTimeout(t)},r=setTimeout(n,100);Zn&&(e=requestAnimationFrame(n))}function tr(t){var e=kn,n=t.__c;"function"==typeof n&&(t.__c=void 0,n()),kn=e}function er(t){var e=kn;t.__c=t.__(),kn=e}function nr(t,e){return!t||t.length!==e.length||e.some((function(e,n){return e!==t[n]}))}function rr(t,e){return"function"==typeof e?e(t):e}function ir(t,e){for(var n in e)t[n]=e[n];return t}function or(t,e){for(var n in t)if("__source"!==n&&!(n in e))return!0;for(var r in e)if("__source"!==r&&t[r]!==e[r])return!0;return!1}function sr(t,e){this.props=t,this.context=e}function ar(t,e){function n(t){var n=this.props.ref,r=n==t.ref;return!r&&n&&(n.call?n(null):n.current=null),e?!e(this.props,t)||!r:or(this.props,t)}function r(e){return this.shouldComponentUpdate=n,$t(t,e)}return r.displayName="Memo("+(t.displayName||t.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(sr.prototype=new Gt).isPureReactComponent=!0,sr.prototype.shouldComponentUpdate=function(t,e){return or(this.props,t)||or(this.state,e)};var lr=Ct.__b;Ct.__b=function(t){t.type&&t.type.__f&&t.ref&&(t.props.ref=t.ref,t.ref=null),lr&&lr(t)};var ur="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function cr(t){function e(e){var n=ir({},e);return delete n.ref,t(n,e.ref||null)}return e.$$typeof=ur,e.render=e,e.prototype.isReactComponent=e.__f=!0,e.displayName="ForwardRef("+(t.displayName||t.name)+")",e}var dr=function(t,e){return null==t?null:ee(ee(t).map(e))},hr={map:dr,forEach:dr,count:function(t){return t?ee(t).length:0},only:function(t){var e=ee(t);if(1!==e.length)throw"Children.only";return e[0]},toArray:ee},pr=Ct.__e;Ct.__e=function(t,e,n,r){if(t.then)for(var i,o=e;o=o.__;)if((i=o.__c)&&i.__c)return null==e.__e&&(e.__e=n.__e,e.__k=n.__k),i.__c(t,e);pr(t,e,n,r)};var fr=Ct.unmount;function mr(t,e,n){return t&&(t.__c&&t.__c.__H&&(t.__c.__H.__.forEach((function(t){"function"==typeof t.__c&&t.__c()})),t.__c.__H=null),null!=(t=ir({},t)).__c&&(t.__c.__P===n&&(t.__c.__P=e),t.__c=null),t.__k=t.__k&&t.__k.map((function(t){return mr(t,e,n)}))),t}function vr(t,e,n){return t&&n&&(t.__v=null,t.__k=t.__k&&t.__k.map((function(t){return vr(t,e,n)})),t.__c&&t.__c.__P===e&&(t.__e&&n.appendChild(t.__e),t.__c.__e=!0,t.__c.__P=n)),t}function gr(){this.__u=0,this.t=null,this.__b=null}function yr(t){var e=t.__.__c;return e&&e.__a&&e.__a(t)}function br(t){var e,n,r;function i(i){if(e||(e=t()).then((function(t){n=t.default||t}),(function(t){r=t})),r)throw r;if(!n)throw e;return $t(n,i)}return i.displayName="Lazy",i.__f=!0,i}function wr(){this.u=null,this.o=null}Ct.unmount=function(t){var e=t.__c;e&&e.__R&&e.__R(),e&&32&t.__u&&(t.type=null),fr&&fr(t)},(gr.prototype=new Gt).__c=function(t,e){var n=e.__c,r=this;null==r.t&&(r.t=[]),r.t.push(n);var i=yr(r.__v),o=!1,s=function(){o||(o=!0,n.__R=null,i?i(a):a())};n.__R=s;var a=function(){if(! --r.__u){if(r.state.__a){var t=r.state.__a;r.__v.__k[0]=vr(t,t.__c.__P,t.__c.__O)}var e;for(r.setState({__a:r.__b=null});e=r.t.pop();)e.forceUpdate()}};r.__u++||32&e.__u||r.setState({__a:r.__b=r.__v.__k[0]}),t.then(s,s)},gr.prototype.componentWillUnmount=function(){this.t=[]},gr.prototype.render=function(t,e){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=mr(this.__b,n,r.__O=r.__P)}this.__b=null}var i=e.__a&&$t(Kt,null,t.fallback);return i&&(i.__u&=-33),[$t(Kt,null,e.__a?null:t.children),i]};var xr=function(t,e,n){if(++n[1]===n[0]&&t.o.delete(e),t.props.revealOrder&&("t"!==t.props.revealOrder[0]||!t.o.size))for(n=t.u;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;t.u=n=n[2]}};function _r(t){return this.getChildContext=function(){return t.context},t.children}function Sr(t){var e=this,n=t.i;e.componentWillUnmount=function(){de(null,e.l),e.l=null,e.i=null},e.i&&e.i!==n&&e.componentWillUnmount(),e.l||(e.i=n,e.l={nodeType:1,parentNode:n,childNodes:[],contains:function(){return!0},appendChild:function(t){this.childNodes.push(t),e.i.appendChild(t)},insertBefore:function(t,n){this.childNodes.push(t),e.i.appendChild(t)},removeChild:function(t){this.childNodes.splice(this.childNodes.indexOf(t)>>>1,1),e.i.removeChild(t)}}),de($t(_r,{context:e.context},t.__v),e.l)}function Er(t,e){var n=$t(Sr,{__v:t,i:e});return n.containerInfo=e,n}(wr.prototype=new Gt).__a=function(t){var e=this,n=yr(e.__v),r=e.o.get(t);return r[0]++,function(i){var o=function(){e.props.revealOrder?(r.push(i),xr(e,t,r)):i()};n?n(o):o()}},wr.prototype.render=function(t){this.u=null,this.o=new Map;var e=ee(t.children);t.revealOrder&&"b"===t.revealOrder[0]&&e.reverse();for(var n=e.length;n--;)this.o.set(e[n],this.u=[1,0,this.u]);return t.children},wr.prototype.componentDidUpdate=wr.prototype.componentDidMount=function(){var t=this;this.o.forEach((function(e,n){xr(t,n,e)}))};var kr="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]/,Tr=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,Cr=/[A-Z0-9]/g,Ar="undefined"!=typeof document,Rr=function(t){return("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(t)};function Or(t,e,n){return null==e.__k&&(e.textContent=""),de(t,e),"function"==typeof n&&n(),t?t.__c:null}function Fr(t,e,n){return he(t,e),"function"==typeof n&&n(),t?t.__c:null}Gt.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach((function(t){Object.defineProperty(Gt.prototype,t,{configurable:!0,get:function(){return this["UNSAFE_"+t]},set:function(e){Object.defineProperty(this,t,{configurable:!0,writable:!0,value:e})}})}));var Lr=Ct.event;function Mr(){}function Dr(){return this.cancelBubble}function Vr(){return this.defaultPrevented}Ct.event=function(t){return Lr&&(t=Lr(t)),t.persist=Mr,t.isPropagationStopped=Dr,t.isDefaultPrevented=Vr,t.nativeEvent=t};var jr,Ir={enumerable:!1,configurable:!0,get:function(){return this.class}},Br=Ct.vnode;Ct.vnode=function(t){"string"==typeof t.type&&function(t){var e=t.props,n=t.type,r={},i=-1===n.indexOf("-");for(var o in e){var s=e[o];if(!("value"===o&&"defaultValue"in e&&null==s||Ar&&"children"===o&&"noscript"===n||"class"===o||"className"===o)){var a=o.toLowerCase();"defaultValue"===o&&"value"in e&&null==e.value?o="value":"download"===o&&!0===s?s="":"translate"===a&&"no"===s?s=!1:"o"===a[0]&&"n"===a[1]?"ondoubleclick"===a?o="ondblclick":"onchange"!==a||"input"!==n&&"textarea"!==n||Rr(e.type)?"onfocus"===a?o="onfocusin":"onblur"===a?o="onfocusout":Tr.test(o)&&(o=a):a=o="oninput":i&&Pr.test(o)?o=o.replace(Cr,"-$&").toLowerCase():null===s&&(s=void 0),"oninput"===a&&r[o=a]&&(o="oninputCapture"),r[o]=s}}"select"==n&&r.multiple&&Array.isArray(r.value)&&(r.value=ee(e.children).forEach((function(t){t.props.selected=-1!=r.value.indexOf(t.props.value)}))),"select"==n&&null!=r.defaultValue&&(r.value=ee(e.children).forEach((function(t){t.props.selected=r.multiple?-1!=r.defaultValue.indexOf(t.props.value):r.defaultValue==t.props.value}))),e.class&&!e.className?(r.class=e.class,Object.defineProperty(r,"className",Ir)):(e.className&&!e.class||e.class&&e.className)&&(r.class=r.className=e.className),t.props=r}(t),t.$$typeof=kr,Br&&Br(t)};var Nr=Ct.__r;Ct.__r=function(t){Nr&&Nr(t),jr=t.__c};var Ur=Ct.diffed;Ct.diffed=function(t){Ur&&Ur(t);var e=t.props,n=t.__e;null!=n&&"textarea"===t.type&&"value"in e&&e.value!==n.value&&(n.value=null==e.value?"":e.value),jr=null};var Wr={ReactCurrentDispatcher:{current:{readContext:function(t){return jr.__n[t.__c].props.value},useCallback:Kn,useContext:Gn,useDebugValue:Yn,useDeferredValue:ti,useEffect:Wn,useId:Qn,useImperativeHandle:zn,useInsertionEffect:ni,useLayoutEffect:Hn,useMemo:qn,useReducer:Un,useRef:$n,useState:Nn,useSyncExternalStore:ii,useTransition:ei}}};function Hr(t){return $t.bind(null,t)}function $r(t){return!!t&&t.$$typeof===kr}function zr(t){return $r(t)&&t.type===Kt}function qr(t){return!!t&&!!t.displayName&&("string"==typeof t.displayName||t.displayName instanceof String)&&t.displayName.startsWith("Memo(")}function Kr(t){return $r(t)?pe.apply(null,arguments):t}function Gr(t){return!!t.__k&&(de(null,t),!0)}function Yr(t){return t&&(t.base||1===t.nodeType&&t)||null}var Qr=function(t,e){return t(e)},Xr=function(t,e){return t(e)},Zr=Kt;function Jr(t){t()}function ti(t){return t}function ei(){return[!1,Jr]}var ni=Hn,ri=$r;function ii(t,e){var n=e(),r=Nn({h:{__:n,v:e}}),i=r[0].h,o=r[1];return Hn((function(){i.__=n,i.v=e,oi(i)&&o({h:i})}),[t,n,e]),Wn((function(){return oi(i)&&o({h:i}),t((function(){oi(i)&&o({h:i})}))}),[t]),n}function oi(t){var e,n,r=t.v,i=t.__;try{var o=r();return!((e=i)===(n=o)&&(0!==e||1/e==1/n)||e!=e&&n!=n)}catch(s){return!0}}var si={useState:Nn,useId:Qn,useReducer:Un,useEffect:Wn,useLayoutEffect:Hn,useInsertionEffect:ni,useTransition:ei,useDeferredValue:ti,useSyncExternalStore:ii,startTransition:Jr,useRef:$n,useImperativeHandle:zn,useMemo:qn,useCallback:Kn,useContext:Gn,useDebugValue:Yn,version:"17.0.2",Children:hr,render:Or,hydrate:Fr,unmountComponentAtNode:Gr,createPortal:Er,createElement:$t,createContext:fe,createFactory:Hr,cloneElement:Kr,createRef:qt,Fragment:Kt,isValidElement:$r,isElement:ri,isFragment:zr,isMemo:qr,findDOMNode:Yr,Component:Gt,PureComponent:sr,memo:ar,forwardRef:cr,flushSync:Xr,unstable_batchedUpdates:Qr,StrictMode:Zr,Suspense:gr,SuspenseList:wr,lazy:br,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Wr};const ai=Object.freeze(Object.defineProperty({__proto__:null,Children:hr,Component:Gt,Fragment:Kt,PureComponent:sr,StrictMode:Zr,Suspense:gr,SuspenseList:wr,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Wr,cloneElement:Kr,createContext:fe,createElement:$t,createFactory:Hr,createPortal:Er,createRef:qt,default:si,findDOMNode:Yr,flushSync:Xr,forwardRef:cr,hydrate:Fr,isElement:ri,isFragment:zr,isMemo:qr,isValidElement:$r,lazy:br,memo:ar,render:Or,startTransition:Jr,unmountComponentAtNode:Gr,unstable_batchedUpdates:Qr,useCallback:Kn,useContext:Gn,useDebugValue:Yn,useDeferredValue:ti,useEffect:Wn,useErrorBoundary:function(t){var e=Bn(En++,10),n=Nn();return e.__=t,kn.componentDidCatch||(kn.componentDidCatch=function(t,r){e.__&&e.__(t,r),n[1](t)}),[n[0],function(){n[1](void 0)}]},useId:Qn,useImperativeHandle:zn,useInsertionEffect:ni,useLayoutEffect:Hn,useMemo:qn,useReducer:Un,useRef:$n,useState:Nn,useSyncExternalStore:ii,useTransition:ei,version:"17.0.2"},Symbol.toStringTag,{value:"Module"}));function li(){return li=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},li.apply(null,arguments)}var ui={exports:{}},ci={},di="function"==typeof Symbol&&Symbol.for,hi=di?Symbol.for("react.element"):60103,pi=di?Symbol.for("react.portal"):60106,fi=di?Symbol.for("react.fragment"):60107,mi=di?Symbol.for("react.strict_mode"):60108,vi=di?Symbol.for("react.profiler"):60114,gi=di?Symbol.for("react.provider"):60109,yi=di?Symbol.for("react.context"):60110,bi=di?Symbol.for("react.async_mode"):60111,wi=di?Symbol.for("react.concurrent_mode"):60111,xi=di?Symbol.for("react.forward_ref"):60112,_i=di?Symbol.for("react.suspense"):60113,Si=di?Symbol.for("react.suspense_list"):60120,Ei=di?Symbol.for("react.memo"):60115,ki=di?Symbol.for("react.lazy"):60116,Pi=di?Symbol.for("react.block"):60121,Ti=di?Symbol.for("react.fundamental"):60117,Ci=di?Symbol.for("react.responder"):60118,Ai=di?Symbol.for("react.scope"):60119;function Ri(t){if("object"==typeof t&&null!==t){var e=t.$$typeof;switch(e){case hi:switch(t=t.type){case bi:case wi:case fi:case vi:case mi:case _i:return t;default:switch(t=t&&t.$$typeof){case yi:case xi:case ki:case Ei:case gi:return t;default:return e}}case pi:return e}}}function Oi(t){return Ri(t)===wi}ci.AsyncMode=bi,ci.ConcurrentMode=wi,ci.ContextConsumer=yi,ci.ContextProvider=gi,ci.Element=hi,ci.ForwardRef=xi,ci.Fragment=fi,ci.Lazy=ki,ci.Memo=Ei,ci.Portal=pi,ci.Profiler=vi,ci.StrictMode=mi,ci.Suspense=_i,ci.isAsyncMode=function(t){return Oi(t)||Ri(t)===bi},ci.isConcurrentMode=Oi,ci.isContextConsumer=function(t){return Ri(t)===yi},ci.isContextProvider=function(t){return Ri(t)===gi},ci.isElement=function(t){return"object"==typeof t&&null!==t&&t.$$typeof===hi},ci.isForwardRef=function(t){return Ri(t)===xi},ci.isFragment=function(t){return Ri(t)===fi},ci.isLazy=function(t){return Ri(t)===ki},ci.isMemo=function(t){return Ri(t)===Ei},ci.isPortal=function(t){return Ri(t)===pi},ci.isProfiler=function(t){return Ri(t)===vi},ci.isStrictMode=function(t){return Ri(t)===mi},ci.isSuspense=function(t){return Ri(t)===_i},ci.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===fi||t===wi||t===vi||t===mi||t===_i||t===Si||"object"==typeof t&&null!==t&&(t.$$typeof===ki||t.$$typeof===Ei||t.$$typeof===gi||t.$$typeof===yi||t.$$typeof===xi||t.$$typeof===Ti||t.$$typeof===Ci||t.$$typeof===Ai||t.$$typeof===Pi)},ci.typeOf=Ri,ui.exports=ci;var Fi=ui.exports,Li={};Li[Fi.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Li[Fi.Memo]={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0};function Mi(t,e,n){var r="";return n.split(" ").forEach((function(n){void 0!==t[n]?e.push(t[n]+";"):r+=n+" "})),r}var Di=function(t,e,n){var r=t.key+"-"+e.name;!1===n&&void 0===t.registered[r]&&(t.registered[r]=e.styles)},Vi=function(t,e,n){Di(t,e,n);var r=t.key+"-"+e.name;if(void 0===t.inserted[e.name]){var i=e;do{t.insert(e===i?"."+r:"",i,t.sheet,!0),i=i.next}while(void 0!==i)}};var ji={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},Ii=!1,Bi=/[A-Z]|^ms/g,Ni=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Ui=function(t){return 45===t.charCodeAt(1)},Wi=function(t){return null!=t&&"boolean"!=typeof t},Hi=gn((function(t){return Ui(t)?t:t.replace(Bi,"-$&").toLowerCase()})),$i=function(t,e){switch(t){case"animation":case"animationName":if("string"==typeof e)return e.replace(Ni,(function(t,e,n){return Ki={name:e,styles:n,next:Ki},e}))}return 1===ji[t]||Ui(t)||"number"!=typeof e||0===e?e:e+"px"},zi="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function qi(t,e,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 Ki={name:i.name,styles:i.styles,next:Ki},i.name;var o=n;if(void 0!==o.styles){var s=o.next;if(void 0!==s)for(;void 0!==s;)Ki={name:s.name,styles:s.styles,next:Ki},s=s.next;return o.styles+";"}return function(t,e,n){var r="";if(Array.isArray(n))for(var i=0;i<n.length;i++)r+=qi(t,e,n[i])+";";else for(var o in n){var s=n[o];if("object"!=typeof s){var a=s;null!=e&&void 0!==e[a]?r+=o+"{"+e[a]+"}":Wi(a)&&(r+=Hi(o)+":"+$i(o,a)+";")}else{if("NO_COMPONENT_SELECTOR"===o&&Ii)throw new Error(zi);if(!Array.isArray(s)||"string"!=typeof s[0]||null!=e&&void 0!==e[s[0]]){var l=qi(t,e,s);switch(o){case"animation":case"animationName":r+=Hi(o)+":"+l+";";break;default:r+=o+"{"+l+"}"}}else for(var u=0;u<s.length;u++)Wi(s[u])&&(r+=Hi(o)+":"+$i(o,s[u])+";")}}return r}(t,e,n);case"function":if(void 0!==t){var a=Ki,l=n(t);return Ki=a,qi(t,e,l)}}var u=n;if(null==e)return u;var c=e[u];return void 0!==c?c:u}var Ki,Gi=/label:\s*([^\s;\n{]+)\s*(;|$)/g;function Yi(t,e,n){if(1===t.length&&"object"==typeof t[0]&&null!==t[0]&&void 0!==t[0].styles)return t[0];var r=!0,i="";Ki=void 0;var o=t[0];null==o||void 0===o.raw?(r=!1,i+=qi(n,e,o)):i+=o[0];for(var s=1;s<t.length;s++){if(i+=qi(n,e,t[s]),r)i+=o[s]}Gi.lastIndex=0;for(var a,l="";null!==(a=Gi.exec(i));)l+="-"+a[1];var u=function(t){for(var e,n=0,r=0,i=t.length;i>=4;++r,i-=4)e=1540483477*(65535&(e=255&t.charCodeAt(r)|(255&t.charCodeAt(++r))<<8|(255&t.charCodeAt(++r))<<16|(255&t.charCodeAt(++r))<<24))+(59797*(e>>>16)<<16),n=1540483477*(65535&(e^=e>>>24))+(59797*(e>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(i){case 3:n^=(255&t.charCodeAt(r+2))<<16;case 2:n^=(255&t.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&t.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:u,styles:i,next:Ki}}var Qi=!!ai.useInsertionEffect&&ai.useInsertionEffect,Xi=Qi||function(t){return t()},Zi=Qi||Hn,Ji=fe("undefined"!=typeof HTMLElement?An({key:"css"}):null),to=Ji.Provider,eo=function(t){return cr((function(e,n){var r=Gn(Ji);return t(e,r,n)}))},no=fe({}),ro={}.hasOwnProperty,io="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",oo=function(t,e){var n={};for(var r in e)ro.call(e,r)&&(n[r]=e[r]);return n[io]=t,n},so=function(t){var e=t.cache,n=t.serialized,r=t.isStringTag;return Di(e,n,r),Xi((function(){return Vi(e,n,r)})),null},ao=eo((function(t,e,n){var r=t.css;"string"==typeof r&&void 0!==e.registered[r]&&(r=e.registered[r]);var i=t[io],o=[r],s="";"string"==typeof t.className?s=Mi(e.registered,o,t.className):null!=t.className&&(s=t.className+" ");var a=Yi(o,void 0,Gn(no));s+=e.key+"-"+a.name;var l={};for(var u in t)ro.call(t,u)&&"css"!==u&&u!==io&&(l[u]=t[u]);return l.className=s,n&&(l.ref=n),$t(Kt,null,$t(so,{cache:e,serialized:a,isStringTag:"string"==typeof i}),$t(i,l))})),lo=eo((function(t,e){var n=Yi([t.styles],void 0,Gn(no)),r=$n();return Zi((function(){var t=e.key+"-global",i=new e.sheet.constructor({key:t,nonce:e.sheet.nonce,container:e.sheet.container,speedy:e.sheet.isSpeedy}),o=!1,s=document.querySelector('style[data-emotion="'+t+" "+n.name+'"]');return e.sheet.tags.length&&(i.before=e.sheet.tags[0]),null!==s&&(o=!0,s.setAttribute("data-emotion",t),i.hydrate([s])),r.current=[i,o],function(){i.flush()}}),[e]),Zi((function(){var t=r.current,i=t[0];if(t[1])t[1]=!1;else{if(void 0!==n.next&&Vi(e,n.next,!0),i.tags.length){var o=i.tags[i.tags.length-1].nextElementSibling;i.before=o,i.flush()}e.insert("",n,i,!1)}}),[e,n.name]),null}));function uo(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return Yi(e)}var co=0;function ho(t,e,n,r,i,o){e||(e={});var s,a,l=e;if("ref"in l)for(a in l={},e)"ref"==a?s=e[a]:l[a]=e[a];var u={type:t,props:l,key:n,ref:s,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--co,__i:-1,__u:0,__source:i,__self:o};if("function"==typeof t&&(s=t.defaultProps))for(a in s)void 0===l[a]&&(l[a]=s[a]);return Ct.vnode&&Ct.vnode(u),u}var po=Kt;function fo(t,e,n){return ro.call(e,"css")?ho(ao,oo(t,e),n):ho(t,e,n)}function mo(t,e,n){return ro.call(e,"css")?ho(ao,oo(t,e),n):ho(t,e,n)}const vo=uo({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"}}),go=()=>mo(Kt,{children:[fo(lo,{styles:uo`
|
|
1
|
+
var __defProp=Object.defineProperty,__typeError=t=>{throw TypeError(t)},__defNormalProp=(t,e,n)=>e in t?__defProp(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,__publicField=(t,e,n)=>__defNormalProp(t,"symbol"!=typeof e?e+"":e,n),__accessCheck=(t,e,n)=>e.has(t)||__typeError("Cannot "+n),__privateGet=(t,e,n)=>(__accessCheck(t,e,"read from private field"),n?n.call(t):e.get(t)),__privateAdd=(t,e,n)=>e.has(t)?__typeError("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,n),__privateSet=(t,e,n,r)=>(__accessCheck(t,e,"write to private field"),r?r.call(t,n):e.set(t,n),n),__privateMethod=(t,e,n)=>(__accessCheck(t,e,"access private method"),n),__privateWrapper=(t,e,n,r)=>({set _(r){__privateSet(t,e,r,n)},get _(){return __privateGet(t,e,r)}});!function(){"use strict";var t,e,n,r,i,o,s,a,l,u,c,d,h,p,f,m,v,g,y,_,b,w,x,S,E,k,P,T,A,C,R,O,M,F,L,D,V,j,I,B,N,G,U,W,H,$,z,q,K,Y,Q,X,Z,J,tt,et,nt,rt,it,ot,st,at,lt,ut,ct,dt,ht,pt,ft,mt,vt,gt,yt,_t,bt,wt,xt,St,Et,kt,Pt,Tt,At,Ct={},Rt=[],Ot=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Mt=Array.isArray;function Ft(t,e){for(var n in e)t[n]=e[n];return t}function Lt(t){var e=t.parentNode;e&&e.removeChild(t)}function Dt(t,e,n){var r,i,o,s={};for(o in e)"key"==o?r=e[o]:"ref"==o?i=e[o]:s[o]=e[o];if(arguments.length>2&&(s.children=arguments.length>3?yt.call(arguments,2):n),"function"==typeof t&&null!=t.defaultProps)for(o in t.defaultProps)void 0===s[o]&&(s[o]=t.defaultProps[o]);return Vt(t,s,r,i,null)}function Vt(t,e,n,r,i){var o={type:t,props:e,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==i?++bt:i,__i:-1,__u:0};return null==i&&null!=_t.vnode&&_t.vnode(o),o}function jt(){return{current:null}}function It(t){return t.children}function Bt(t,e){this.props=t,this.context=e}function Nt(t,e){if(null==e)return t.__?Nt(t.__,t.__i+1):null;for(var n;e<t.__k.length;e++)if(null!=(n=t.__k[e])&&null!=n.__e)return n.__e;return"function"==typeof t.type?Nt(t):null}function Gt(t){var e,n;if(null!=(t=t.__)&&null!=t.__c){for(t.__e=t.__c.base=null,e=0;e<t.__k.length;e++)if(null!=(n=t.__k[e])&&null!=n.__e){t.__e=t.__c.base=n.__e;break}return Gt(t)}}function Ut(t){(!t.__d&&(t.__d=!0)&&wt.push(t)&&!Wt.__r++||xt!==_t.debounceRendering)&&((xt=_t.debounceRendering)||St)(Wt)}function Wt(){var t,e,n,r,i,o,s,a;for(wt.sort(Et);t=wt.shift();)t.__d&&(e=wt.length,r=void 0,o=(i=(n=t).__v).__e,s=[],a=[],n.__P&&((r=Ft({},i)).__v=i.__v+1,_t.vnode&&_t.vnode(r),Xt(n.__P,r,i,n.__n,n.__P.namespaceURI,32&i.__u?[o]:null,s,null==o?Nt(i):o,!!(32&i.__u),a),r.__v=i.__v,r.__.__k[r.__i]=r,Zt(s,r,a),r.__e!=o&&Gt(r)),wt.length>e&&wt.sort(Et));Wt.__r=0}function Ht(t,e,n,r,i,o,s,a,l,u,c){var d,h,p,f,m,v=r&&r.__k||Rt,g=e.length;for(n.__d=l,function(t,e,n){var r,i,o,s,a,l=e.length,u=n.length,c=u,d=0;for(t.__k=[],r=0;r<l;r++)s=r+d,null!=(i=t.__k[r]=null==(i=e[r])||"boolean"==typeof i||"function"==typeof i?null:"string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?Vt(null,i,null,null,null):Mt(i)?Vt(It,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?Vt(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)?(i.__=t,i.__b=t.__b+1,a=qt(i,n,s,c),i.__i=a,o=null,-1!==a&&(c--,(o=n[a])&&(o.__u|=131072)),null==o||null===o.__v?(-1==a&&d--,"function"!=typeof i.type&&(i.__u|=65536)):a!==s&&(a==s-1?d--:a==s+1?d++:a>s?c>l-s?d+=a-s:d--:a<s&&(a==s-d?d-=a-s:d++),a!==r+d&&(i.__u|=65536))):(o=n[s])&&null==o.key&&o.__e&&!(131072&o.__u)&&(o.__e==t.__d&&(t.__d=Nt(o)),te(o,o,!1),n[s]=null,c--);if(c)for(r=0;r<u;r++)null!=(o=n[r])&&!(131072&o.__u)&&(o.__e==t.__d&&(t.__d=Nt(o)),te(o,o))}(n,e,v),l=n.__d,d=0;d<g;d++)null!=(p=n.__k[d])&&"boolean"!=typeof p&&"function"!=typeof p&&(h=-1===p.__i?Ct:v[p.__i]||Ct,p.__i=d,Xt(t,p,h,i,o,s,a,l,u,c),f=p.__e,p.ref&&h.ref!=p.ref&&(h.ref&&Jt(h.ref,null,p),c.push(p.ref,p.__c||f,p)),null==m&&null!=f&&(m=f),65536&p.__u||h.__k===p.__k?l=$t(p,l,t):"function"==typeof p.type&&void 0!==p.__d?l=p.__d:f&&(l=f.nextSibling),p.__d=void 0,p.__u&=-196609);n.__d=l,n.__e=m}function $t(t,e,n){var r,i;if("function"==typeof t.type){for(r=t.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=t,e=$t(r[i],e,n));return e}t.__e!=e&&(e&&t.type&&!n.contains(e)&&(e=Nt(t)),n.insertBefore(t.__e,e||null),e=t.__e);do{e=e&&e.nextSibling}while(null!=e&&8===e.nodeType);return e}function zt(t,e){return e=e||[],null==t||"boolean"==typeof t||(Mt(t)?t.some((function(t){zt(t,e)})):e.push(t)),e}function qt(t,e,n,r){var i=t.key,o=t.type,s=n-1,a=n+1,l=e[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(;s>=0||a<e.length;){if(s>=0){if((l=e[s])&&!(131072&l.__u)&&i==l.key&&o===l.type)return s;s--}if(a<e.length){if((l=e[a])&&!(131072&l.__u)&&i==l.key&&o===l.type)return a;a++}}return-1}function Kt(t,e,n){"-"===e[0]?t.setProperty(e,null==n?"":n):t[e]=null==n?"":"number"!=typeof n||Ot.test(e)?n:n+"px"}function Yt(t,e,n,r,i){var o;t:if("style"===e)if("string"==typeof n)t.style.cssText=n;else{if("string"==typeof r&&(t.style.cssText=r=""),r)for(e in r)n&&e in n||Kt(t.style,e,"");if(n)for(e in n)r&&n[e]===r[e]||Kt(t.style,e,n[e])}else if("o"===e[0]&&"n"===e[1])o=e!==(e=e.replace(/(PointerCapture)$|Capture$/i,"$1")),e=e.toLowerCase()in t||"onFocusOut"===e||"onFocusIn"===e?e.toLowerCase().slice(2):e.slice(2),t.l||(t.l={}),t.l[e+o]=n,n?r?n.u=r.u:(n.u=kt,t.addEventListener(e,o?Tt:Pt,o)):t.removeEventListener(e,o?Tt:Pt,o);else{if("http://www.w3.org/2000/svg"==i)e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=e&&"height"!=e&&"href"!=e&&"list"!=e&&"form"!=e&&"tabIndex"!=e&&"download"!=e&&"rowSpan"!=e&&"colSpan"!=e&&"role"!=e&&"popover"!=e&&e in t)try{t[e]=null==n?"":n;break t}catch(s){}"function"==typeof n||(null==n||!1===n&&"-"!==e[4]?t.removeAttribute(e):t.setAttribute(e,"popover"==e&&1==n?"":n))}}function Qt(t){return function(e){if(this.l){var n=this.l[e.type+t];if(null==e.t)e.t=kt++;else if(e.t<n.u)return;return n(_t.event?_t.event(e):e)}}}function Xt(t,e,n,r,i,o,s,a,l,u){var c,d,h,p,f,m,v,g,y,_,b,w,x,S,E,k,P=e.type;if(void 0!==e.constructor)return null;128&n.__u&&(l=!!(32&n.__u),o=[a=e.__e=n.__e]),(c=_t.__b)&&c(e);t:if("function"==typeof P)try{if(g=e.props,y="prototype"in P&&P.prototype.render,_=(c=P.contextType)&&r[c.__c],b=c?_?_.props.value:c.__:r,n.__c?v=(d=e.__c=n.__c).__=d.__E:(y?e.__c=d=new P(g,b):(e.__c=d=new Bt(g,b),d.constructor=P,d.render=ee),_&&_.sub(d),d.props=g,d.state||(d.state={}),d.context=b,d.__n=r,h=d.__d=!0,d.__h=[],d._sb=[]),y&&null==d.__s&&(d.__s=d.state),y&&null!=P.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=Ft({},d.__s)),Ft(d.__s,P.getDerivedStateFromProps(g,d.__s))),p=d.props,f=d.state,d.__v=e,h)y&&null==P.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),y&&null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(y&&null==P.getDerivedStateFromProps&&g!==p&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(g,b),!d.__e&&(null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(g,d.__s,b)||e.__v===n.__v)){for(e.__v!==n.__v&&(d.props=g,d.state=d.__s,d.__d=!1),e.__e=n.__e,e.__k=n.__k,e.__k.forEach((function(t){t&&(t.__=e)})),w=0;w<d._sb.length;w++)d.__h.push(d._sb[w]);d._sb=[],d.__h.length&&s.push(d);break t}null!=d.componentWillUpdate&&d.componentWillUpdate(g,d.__s,b),y&&null!=d.componentDidUpdate&&d.__h.push((function(){d.componentDidUpdate(p,f,m)}))}if(d.context=b,d.props=g,d.__P=t,d.__e=!1,x=_t.__r,S=0,y){for(d.state=d.__s,d.__d=!1,x&&x(e),c=d.render(d.props,d.state,d.context),E=0;E<d._sb.length;E++)d.__h.push(d._sb[E]);d._sb=[]}else do{d.__d=!1,x&&x(e),c=d.render(d.props,d.state,d.context),d.state=d.__s}while(d.__d&&++S<25);d.state=d.__s,null!=d.getChildContext&&(r=Ft(Ft({},r),d.getChildContext())),y&&!h&&null!=d.getSnapshotBeforeUpdate&&(m=d.getSnapshotBeforeUpdate(p,f)),Ht(t,Mt(k=null!=c&&c.type===It&&null==c.key?c.props.children:c)?k:[k],e,n,r,i,o,s,a,l,u),d.base=e.__e,e.__u&=-161,d.__h.length&&s.push(d),v&&(d.__E=d.__=null)}catch(T){if(e.__v=null,l||null!=o){for(e.__u|=l?160:32;a&&8===a.nodeType&&a.nextSibling;)a=a.nextSibling;o[o.indexOf(a)]=null,e.__e=a}else e.__e=n.__e,e.__k=n.__k;_t.__e(T,e,n)}else null==o&&e.__v===n.__v?(e.__k=n.__k,e.__e=n.__e):e.__e=function(t,e,n,r,i,o,s,a,l){var u,c,d,h,p,f,m,v=n.props,g=e.props,y=e.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(u=0;u<o.length;u++)if((p=o[u])&&"setAttribute"in p==!!y&&(y?p.localName===y:3===p.nodeType)){t=p,o[u]=null;break}if(null==t){if(null===y)return document.createTextNode(g);t=document.createElementNS(i,y,g.is&&g),o=null,a=!1}if(null===y)v===g||a&&t.data===g||(t.data=g);else{if(o=o&&yt.call(t.childNodes),v=n.props||Ct,!a&&null!=o)for(v={},u=0;u<t.attributes.length;u++)v[(p=t.attributes[u]).name]=p.value;for(u in v)if(p=v[u],"children"==u);else if("dangerouslySetInnerHTML"==u)d=p;else if("key"!==u&&!(u in g)){if("value"==u&&"defaultValue"in g||"checked"==u&&"defaultChecked"in g)continue;Yt(t,u,null,p,i)}for(u in g)p=g[u],"children"==u?h=p:"dangerouslySetInnerHTML"==u?c=p:"value"==u?f=p:"checked"==u?m=p:"key"===u||a&&"function"!=typeof p||v[u]===p||Yt(t,u,p,v[u],i);if(c)a||d&&(c.__html===d.__html||c.__html===t.innerHTML)||(t.innerHTML=c.__html),e.__k=[];else if(d&&(t.innerHTML=""),Ht(t,Mt(h)?h:[h],e,n,r,"foreignObject"===y?"http://www.w3.org/1999/xhtml":i,o,s,o?o[0]:n.__k&&Nt(n,0),a,l),null!=o)for(u=o.length;u--;)null!=o[u]&&Lt(o[u]);a||(u="value",void 0!==f&&(f!==t[u]||"progress"===y&&!f||"option"===y&&f!==v[u])&&Yt(t,u,f,v[u],i),u="checked",void 0!==m&&m!==t[u]&&Yt(t,u,m,v[u],i))}return t}(n.__e,e,n,r,i,o,s,l,u);(c=_t.diffed)&&c(e)}function Zt(t,e,n){e.__d=void 0;for(var r=0;r<n.length;r++)Jt(n[r],n[++r],n[++r]);_t.__c&&_t.__c(e,t),t.some((function(e){try{t=e.__h,e.__h=[],t.some((function(t){t.call(e)}))}catch(n){_t.__e(n,e.__v)}}))}function Jt(t,e,n){try{if("function"==typeof t){var r="function"==typeof t.__u;r&&t.__u(),r&&null==e||(t.__u=t(e))}else t.current=e}catch(i){_t.__e(i,n)}}function te(t,e,n){var r,i;if(_t.unmount&&_t.unmount(t),(r=t.ref)&&(r.current&&r.current!==t.__e||Jt(r,null,e)),null!=(r=t.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(o){_t.__e(o,e)}r.base=r.__P=null}if(r=t.__k)for(i=0;i<r.length;i++)r[i]&&te(r[i],e,n||"function"!=typeof t.type);n||null==t.__e||Lt(t.__e),t.__c=t.__=t.__e=t.__d=void 0}function ee(t,e,n){return this.constructor(t,n)}function ne(t,e,n){var r,i,o,s;_t.__&&_t.__(t,e),i=(r="function"==typeof n)?null:n&&n.__k||e.__k,o=[],s=[],Xt(e,t=(!r&&n||e).__k=Dt(It,null,[t]),i||Ct,Ct,e.namespaceURI,!r&&n?[n]:i?null:e.firstChild?yt.call(e.childNodes):null,o,!r&&n?n:i?i.__e:e.firstChild,r,s),Zt(o,t,s)}function re(t,e){ne(t,e,re)}function ie(t,e,n){var r,i,o,s,a=Ft({},t.props);for(o in t.type&&t.type.defaultProps&&(s=t.type.defaultProps),e)"key"==o?r=e[o]:"ref"==o?i=e[o]:a[o]=void 0===e[o]&&void 0!==s?s[o]:e[o];return arguments.length>2&&(a.children=arguments.length>3?yt.call(arguments,2):n),Vt(t.type,a,r||t.key,i||t.ref,null)}function oe(t,e){var n={__c:e="__cC"+At++,__:t,Consumer:function(t,e){return t.children(e)},Provider:function(t){var n,r;return this.getChildContext||(n=[],(r={})[e]=this,this.getChildContext=function(){return r},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(t){this.props.value!==t.value&&n.some((function(t){t.__e=!0,Ut(t)}))},this.sub=function(t){n.push(t);var e=t.componentWillUnmount;t.componentWillUnmount=function(){n&&n.splice(n.indexOf(t),1),e&&e.call(t)}}),t.children}};return n.Provider.__=n.Consumer.contextType=n}function se(){return(se=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t}).apply(this,arguments)}yt=Rt.slice,_t={__e:function(t,e,n,r){for(var i,o,s;e=e.__;)if((i=e.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(t)),s=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(t,r||{}),s=i.__d),s)return i.__E=i}catch(a){t=a}throw t}},bt=0,Bt.prototype.setState=function(t,e){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=Ft({},this.state),"function"==typeof t&&(t=t(Ft({},n),this.props)),t&&Ft(n,t),null!=t&&this.__v&&(e&&this._sb.push(e),Ut(this))},Bt.prototype.forceUpdate=function(t){this.__v&&(this.__e=!0,t&&this.__h.push(t),Ut(this))},Bt.prototype.render=It,wt=[],St="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Et=function(t,e){return t.__v.__b-e.__v.__b},Wt.__r=0,kt=0,Pt=Qt(!1),Tt=Qt(!0),At=0;var ae=["context","children"];function le(t){return this.getChildContext=function(){return t.context},ie(t.children,function(t,e){if(null==t)return{};var n,r,i={},o=Object.keys(t);for(r=0;r<o.length;r++)e.indexOf(n=o[r])>=0||(i[n]=t[n]);return i}(t,ae))}function ue(){var t=new CustomEvent("_preact",{detail:{},bubbles:!0,cancelable:!0});this.dispatchEvent(t),this._vdom=Dt(le,se({},this._props,{context:t.detail.context}),function t(e,n){if(3===e.nodeType)return e.data;if(1!==e.nodeType)return null;var r=[],i={},o=0,s=e.attributes,a=e.childNodes;for(o=s.length;o--;)"slot"!==s[o].name&&(i[s[o].name]=s[o].value,i[ce(s[o].name)]=s[o].value);for(o=a.length;o--;){var l=t(a[o],null),u=a[o].slot;u?i[u]=Dt(pe,{name:u},l):r[o]=l}var c=n?Dt(pe,null,r):r;return Dt(n||e.nodeName.toLowerCase(),i,c)}(this,this._vdomComponent)),(this.hasAttribute("hydrate")?re:ne)(this._vdom,this._root)}function ce(t){return t.replace(/-(\w)/g,(function(t,e){return e?e.toUpperCase():""}))}function de(t,e,n){if(this._vdom){var r={};r[t]=n=null==n?void 0:n,r[ce(t)]=n,this._vdom=ie(this._vdom,r),ne(this._vdom,this._root)}}function he(){ne(this._vdom=null,this._root)}function pe(t,e){var n=this;return Dt("slot",se({},t,{ref:function(t){t?(n.ref=t,n._listener||(n._listener=function(t){t.stopPropagation(),t.detail.context=e},t.addEventListener("_preact",n._listener))):n.ref.removeEventListener("_preact",n._listener)}}))}var fe=function(){function t(t){var e=this;this._insertTag=function(t){var n;n=0===e.tags.length?e.insertionPoint?e.insertionPoint.nextSibling:e.prepend?e.container.firstChild:e.before:e.tags[e.tags.length-1].nextSibling,e.container.insertBefore(t,n),e.tags.push(t)},this.isSpeedy=void 0===t.speedy||t.speedy,this.tags=[],this.ctr=0,this.nonce=t.nonce,this.key=t.key,this.container=t.container,this.prepend=t.prepend,this.insertionPoint=t.insertionPoint,this.before=null}var e=t.prototype;return e.hydrate=function(t){t.forEach(this._insertTag)},e.insert=function(t){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(t){var e=document.createElement("style");return e.setAttribute("data-emotion",t.key),void 0!==t.nonce&&e.setAttribute("nonce",t.nonce),e.appendChild(document.createTextNode("")),e.setAttribute("data-s",""),e}(this));var e=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(t){if(t.sheet)return t.sheet;for(var e=0;e<document.styleSheets.length;e++)if(document.styleSheets[e].ownerNode===t)return document.styleSheets[e]}(e);try{n.insertRule(t,n.cssRules.length)}catch(uy){}}else e.appendChild(document.createTextNode(t));this.ctr++},e.flush=function(){this.tags.forEach((function(t){var e;return null==(e=t.parentNode)?void 0:e.removeChild(t)})),this.tags=[],this.ctr=0},t}(),me="-ms-",ve="-moz-",ge="-webkit-",ye="comm",_e="rule",be="decl",we="@keyframes",xe=Math.abs,Se=String.fromCharCode,Ee=Object.assign;function ke(t){return t.trim()}function Pe(t,e,n){return t.replace(e,n)}function Te(t,e){return t.indexOf(e)}function Ae(t,e){return 0|t.charCodeAt(e)}function Ce(t,e,n){return t.slice(e,n)}function Re(t){return t.length}function Oe(t){return t.length}function Me(t,e){return e.push(t),t}var Fe=1,Le=1,De=0,Ve=0,je=0,Ie="";function Be(t,e,n,r,i,o,s){return{value:t,root:e,parent:n,type:r,props:i,children:o,line:Fe,column:Le,length:s,return:""}}function Ne(t,e){return Ee(Be("",null,null,"",null,null,0),t,{length:-t.length},e)}function Ge(){return je=Ve<De?Ae(Ie,Ve++):0,Le++,10===je&&(Le=1,Fe++),je}function Ue(){return Ae(Ie,Ve)}function We(){return Ve}function He(t,e){return Ce(Ie,t,e)}function $e(t){switch(t){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 ze(t){return Fe=Le=1,De=Re(Ie=t),Ve=0,[]}function qe(t){return Ie="",t}function Ke(t){return ke(He(Ve-1,Xe(91===t?t+2:40===t?t+1:t)))}function Ye(t){for(;(je=Ue())&&je<33;)Ge();return $e(t)>2||$e(je)>3?"":" "}function Qe(t,e){for(;--e&&Ge()&&!(je<48||je>102||je>57&&je<65||je>70&&je<97););return He(t,We()+(e<6&&32==Ue()&&32==Ge()))}function Xe(t){for(;Ge();)switch(je){case t:return Ve;case 34:case 39:34!==t&&39!==t&&Xe(je);break;case 40:41===t&&Xe(t);break;case 92:Ge()}return Ve}function Ze(t,e){for(;Ge()&&t+je!==57&&(t+je!==84||47!==Ue()););return"/*"+He(e,Ve-1)+"*"+Se(47===t?t:Ge())}function Je(t){for(;!$e(Ue());)Ge();return He(t,Ve)}function tn(t){return qe(en("",null,null,null,[""],t=ze(t),0,[0],t))}function en(t,e,n,r,i,o,s,a,l){for(var u=0,c=0,d=s,h=0,p=0,f=0,m=1,v=1,g=1,y=0,_="",b=i,w=o,x=r,S=_;v;)switch(f=y,y=Ge()){case 40:if(108!=f&&58==Ae(S,d-1)){-1!=Te(S+=Pe(Ke(y),"&","&\f"),"&\f")&&(g=-1);break}case 34:case 39:case 91:S+=Ke(y);break;case 9:case 10:case 13:case 32:S+=Ye(f);break;case 92:S+=Qe(We()-1,7);continue;case 47:switch(Ue()){case 42:case 47:Me(rn(Ze(Ge(),We()),e,n),l);break;default:S+="/"}break;case 123*m:a[u++]=Re(S)*g;case 125*m:case 59:case 0:switch(y){case 0:case 125:v=0;case 59+c:-1==g&&(S=Pe(S,/\f/g,"")),p>0&&Re(S)-d&&Me(p>32?on(S+";",r,n,d-1):on(Pe(S," ","")+";",r,n,d-2),l);break;case 59:S+=";";default:if(Me(x=nn(S,e,n,u,c,i,a,_,b=[],w=[],d),o),123===y)if(0===c)en(S,e,x,x,b,o,d,a,w);else switch(99===h&&110===Ae(S,3)?100:h){case 100:case 108:case 109:case 115:en(t,x,x,r&&Me(nn(t,x,x,0,0,i,a,_,i,b=[],d),w),i,w,d,a,r?b:w);break;default:en(S,x,x,x,[""],w,0,a,w)}}u=c=p=0,m=g=1,_=S="",d=s;break;case 58:d=1+Re(S),p=f;default:if(m<1)if(123==y)--m;else if(125==y&&0==m++&&125==(je=Ve>0?Ae(Ie,--Ve):0,Le--,10===je&&(Le=1,Fe--),je))continue;switch(S+=Se(y),y*m){case 38:g=c>0?1:(S+="\f",-1);break;case 44:a[u++]=(Re(S)-1)*g,g=1;break;case 64:45===Ue()&&(S+=Ke(Ge())),h=Ue(),c=d=Re(_=S+=Je(We())),y++;break;case 45:45===f&&2==Re(S)&&(m=0)}}return o}function nn(t,e,n,r,i,o,s,a,l,u,c){for(var d=i-1,h=0===i?o:[""],p=Oe(h),f=0,m=0,v=0;f<r;++f)for(var g=0,y=Ce(t,d+1,d=xe(m=s[f])),_=t;g<p;++g)(_=ke(m>0?h[g]+" "+y:Pe(y,/&\f/g,h[g])))&&(l[v++]=_);return Be(t,e,n,0===i?_e:a,l,u,c)}function rn(t,e,n){return Be(t,e,n,ye,Se(je),Ce(t,2,-2),0)}function on(t,e,n,r){return Be(t,e,n,be,Ce(t,0,r),Ce(t,r+1,-1),r)}function sn(t,e){for(var n="",r=Oe(t),i=0;i<r;i++)n+=e(t[i],i,t,e)||"";return n}function an(t,e,n,r){switch(t.type){case"@layer":if(t.children.length)break;case"@import":case be:return t.return=t.return||t.value;case ye:return"";case we:return t.return=t.value+"{"+sn(t.children,r)+"}";case _e:t.value=t.props.join(",")}return Re(n=sn(t.children,r))?t.return=t.value+"{"+n+"}":""}function ln(t){var e=Object.create(null);return function(n){return void 0===e[n]&&(e[n]=t(n)),e[n]}}var un=function(t,e,n){for(var r=0,i=0;r=i,i=Ue(),38===r&&12===i&&(e[n]=1),!$e(i);)Ge();return He(t,Ve)},cn=function(t,e){return qe(function(t,e){var n=-1,r=44;do{switch($e(r)){case 0:38===r&&12===Ue()&&(e[n]=1),t[n]+=un(Ve-1,e,n);break;case 2:t[n]+=Ke(r);break;case 4:if(44===r){t[++n]=58===Ue()?"&\f":"",e[n]=t[n].length;break}default:t[n]+=Se(r)}}while(r=Ge());return t}(ze(t),e))},dn=new WeakMap,hn=function(t){if("rule"===t.type&&t.parent&&!(t.length<1)){for(var e=t.value,n=t.parent,r=t.column===n.column&&t.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==t.props.length||58===e.charCodeAt(0)||dn.get(n))&&!r){dn.set(t,!0);for(var i=[],o=cn(e,i),s=n.props,a=0,l=0;a<o.length;a++)for(var u=0;u<s.length;u++,l++)t.props[l]=i[a]?o[a].replace(/&\f/g,s[u]):s[u]+" "+o[a]}}},pn=function(t){if("decl"===t.type){var e=t.value;108===e.charCodeAt(0)&&98===e.charCodeAt(2)&&(t.return="",t.value="")}};function fn(t,e){switch(function(t,e){return 45^Ae(t,0)?(((e<<2^Ae(t,0))<<2^Ae(t,1))<<2^Ae(t,2))<<2^Ae(t,3):0}(t,e)){case 5103:return ge+"print-"+t+t;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 ge+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return ge+t+ve+t+me+t+t;case 6828:case 4268:return ge+t+me+t+t;case 6165:return ge+t+me+"flex-"+t+t;case 5187:return ge+t+Pe(t,/(\w+).+(:[^]+)/,ge+"box-$1$2"+me+"flex-$1$2")+t;case 5443:return ge+t+me+"flex-item-"+Pe(t,/flex-|-self/,"")+t;case 4675:return ge+t+me+"flex-line-pack"+Pe(t,/align-content|flex-|-self/,"")+t;case 5548:return ge+t+me+Pe(t,"shrink","negative")+t;case 5292:return ge+t+me+Pe(t,"basis","preferred-size")+t;case 6060:return ge+"box-"+Pe(t,"-grow","")+ge+t+me+Pe(t,"grow","positive")+t;case 4554:return ge+Pe(t,/([^-])(transform)/g,"$1"+ge+"$2")+t;case 6187:return Pe(Pe(Pe(t,/(zoom-|grab)/,ge+"$1"),/(image-set)/,ge+"$1"),t,"")+t;case 5495:case 3959:return Pe(t,/(image-set\([^]*)/,ge+"$1$`$1");case 4968:return Pe(Pe(t,/(.+:)(flex-)?(.*)/,ge+"box-pack:$3"+me+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+ge+t+t;case 4095:case 3583:case 4068:case 2532:return Pe(t,/(.+)-inline(.+)/,ge+"$1$2")+t;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(Re(t)-1-e>6)switch(Ae(t,e+1)){case 109:if(45!==Ae(t,e+4))break;case 102:return Pe(t,/(.+:)(.+)-([^]+)/,"$1"+ge+"$2-$3$1"+ve+(108==Ae(t,e+3)?"$3":"$2-$3"))+t;case 115:return~Te(t,"stretch")?fn(Pe(t,"stretch","fill-available"),e)+t:t}break;case 4949:if(115!==Ae(t,e+1))break;case 6444:switch(Ae(t,Re(t)-3-(~Te(t,"!important")&&10))){case 107:return Pe(t,":",":"+ge)+t;case 101:return Pe(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ge+(45===Ae(t,14)?"inline-":"")+"box$3$1"+ge+"$2$3$1"+me+"$2box$3")+t}break;case 5936:switch(Ae(t,e+11)){case 114:return ge+t+me+Pe(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return ge+t+me+Pe(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return ge+t+me+Pe(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return ge+t+me+t+t}return t}var mn,vn,gn,yn,_n=[function(t,e,n,r){if(t.length>-1&&!t.return)switch(t.type){case be:t.return=fn(t.value,t.length);break;case we:return sn([Ne(t,{value:Pe(t.value,"@","@"+ge)})],r);case _e:if(t.length)return function(t,e){return t.map(e).join("")}(t.props,(function(e){switch(function(t,e){return(t=e.exec(t))?t[0]:t}(e,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return sn([Ne(t,{props:[Pe(e,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return sn([Ne(t,{props:[Pe(e,/:(plac\w+)/,":"+ge+"input-$1")]}),Ne(t,{props:[Pe(e,/:(plac\w+)/,":-moz-$1")]}),Ne(t,{props:[Pe(e,/:(plac\w+)/,me+"input-$1")]})],r)}return""}))}}],bn=function(t){var e=t.key;if("css"===e){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(t){-1!==t.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(t),t.setAttribute("data-s",""))}))}var r,i,o=t.stylisPlugins||_n,s={},a=[];r=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+e+' "]'),(function(t){for(var e=t.getAttribute("data-emotion").split(" "),n=1;n<e.length;n++)s[e[n]]=!0;a.push(t)}));var l,u,c,d,h=[an,(d=function(t){l.insert(t)},function(t){t.root||(t=t.return)&&d(t)})],p=(u=[hn,pn].concat(o,h),c=Oe(u),function(t,e,n,r){for(var i="",o=0;o<c;o++)i+=u[o](t,e,n,r)||"";return i});i=function(t,e,n,r){l=n,sn(tn(t?t+"{"+e.styles+"}":e.styles),p),r&&(f.inserted[e.name]=!0)};var f={key:e,sheet:new fe({key:e,container:r,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:s,registered:{},insert:i};return f.sheet.hydrate(a),f},wn=0,xn=[],Sn=_t,En=Sn.__b,kn=Sn.__r,Pn=Sn.diffed,Tn=Sn.__c,An=Sn.unmount,Cn=Sn.__;function Rn(t,e){Sn.__h&&Sn.__h(vn,t,wn||e),wn=0;var n=vn.__H||(vn.__H={__:[],__h:[]});return t>=n.__.length&&n.__.push({}),n.__[t]}function On(t){return wn=1,Mn(Kn,t)}function Mn(t,e,n){var r=Rn(mn++,2);if(r.t=t,!r.__c&&(r.__=[n?n(e):Kn(void 0,e),function(t){var e=r.__N?r.__N[0]:r.__[0],n=r.t(e,t);e!==n&&(r.__N=[n,r.__[1]],r.__c.setState({}))}],r.__c=vn,!vn.u)){var i=function(t,e,n){if(!r.__c.__H)return!0;var i=r.__c.__H.__.filter((function(t){return!!t.__c}));if(i.every((function(t){return!t.__N})))return!o||o.call(this,t,e,n);var s=!1;return i.forEach((function(t){if(t.__N){var e=t.__[0];t.__=t.__N,t.__N=void 0,e!==t.__[0]&&(s=!0)}})),!(!s&&r.__c.props===t)&&(!o||o.call(this,t,e,n))};vn.u=!0;var o=vn.shouldComponentUpdate,s=vn.componentWillUpdate;vn.componentWillUpdate=function(t,e,n){if(this.__e){var r=o;o=void 0,i(t,e,n),o=r}s&&s.call(this,t,e,n)},vn.shouldComponentUpdate=i}return r.__N||r.__}function Fn(t,e){var n=Rn(mn++,3);!Sn.__s&&qn(n.__H,e)&&(n.__=t,n.i=e,vn.__H.__h.push(n))}function Ln(t,e){var n=Rn(mn++,4);!Sn.__s&&qn(n.__H,e)&&(n.__=t,n.i=e,vn.__h.push(n))}function Dn(t){return wn=5,jn((function(){return{current:t}}),[])}function Vn(t,e,n){wn=6,Ln((function(){return"function"==typeof t?(t(e()),function(){return t(null)}):t?(t.current=e(),function(){return t.current=null}):void 0}),null==n?n:n.concat(t))}function jn(t,e){var n=Rn(mn++,7);return qn(n.__H,e)&&(n.__=t(),n.__H=e,n.__h=t),n.__}function In(t,e){return wn=8,jn((function(){return t}),e)}function Bn(t){var e=vn.context[t.__c],n=Rn(mn++,9);return n.c=t,e?(null==n.__&&(n.__=!0,e.sub(vn)),e.props.value):t.__}function Nn(t,e){Sn.useDebugValue&&Sn.useDebugValue(e?e(t):t)}function Gn(){var t=Rn(mn++,11);if(!t.__){for(var e=vn.__v;null!==e&&!e.__m&&null!==e.__;)e=e.__;var n=e.__m||(e.__m=[0,0]);t.__="P"+n[0]+"-"+n[1]++}return t.__}function Un(){for(var t;t=xn.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach($n),t.__H.__h.forEach(zn),t.__H.__h=[]}catch(p_){t.__H.__h=[],Sn.__e(p_,t.__v)}}Sn.__b=function(t){vn=null,En&&En(t)},Sn.__=function(t,e){t&&e.__k&&e.__k.__m&&(t.__m=e.__k.__m),Cn&&Cn(t,e)},Sn.__r=function(t){kn&&kn(t),mn=0;var e=(vn=t.__c).__H;e&&(gn===vn?(e.__h=[],vn.__h=[],e.__.forEach((function(t){t.__N&&(t.__=t.__N),t.i=t.__N=void 0}))):(e.__h.forEach($n),e.__h.forEach(zn),e.__h=[],mn=0)),gn=vn},Sn.diffed=function(t){Pn&&Pn(t);var e=t.__c;e&&e.__H&&(e.__H.__h.length&&(1!==xn.push(e)&&yn===Sn.requestAnimationFrame||((yn=Sn.requestAnimationFrame)||Hn)(Un)),e.__H.__.forEach((function(t){t.i&&(t.__H=t.i),t.i=void 0}))),gn=vn=null},Sn.__c=function(t,e){e.some((function(t){try{t.__h.forEach($n),t.__h=t.__h.filter((function(t){return!t.__||zn(t)}))}catch(zy){e.some((function(t){t.__h&&(t.__h=[])})),e=[],Sn.__e(zy,t.__v)}})),Tn&&Tn(t,e)},Sn.unmount=function(t){An&&An(t);var e,n=t.__c;n&&n.__H&&(n.__H.__.forEach((function(t){try{$n(t)}catch(n){e=n}})),n.__H=void 0,e&&Sn.__e(e,n.__v))};var Wn="function"==typeof requestAnimationFrame;function Hn(t){var e,n=function(){clearTimeout(r),Wn&&cancelAnimationFrame(e),setTimeout(t)},r=setTimeout(n,100);Wn&&(e=requestAnimationFrame(n))}function $n(t){var e=vn,n=t.__c;"function"==typeof n&&(t.__c=void 0,n()),vn=e}function zn(t){var e=vn;t.__c=t.__(),vn=e}function qn(t,e){return!t||t.length!==e.length||e.some((function(e,n){return e!==t[n]}))}function Kn(t,e){return"function"==typeof e?e(t):e}function Yn(t,e){for(var n in e)t[n]=e[n];return t}function Qn(t,e){for(var n in t)if("__source"!==n&&!(n in e))return!0;for(var r in e)if("__source"!==r&&t[r]!==e[r])return!0;return!1}function Xn(t,e){this.props=t,this.context=e}function Zn(t,e){function n(t){var n=this.props.ref,r=n==t.ref;return!r&&n&&(n.call?n(null):n.current=null),e?!e(this.props,t)||!r:Qn(this.props,t)}function r(e){return this.shouldComponentUpdate=n,Dt(t,e)}return r.displayName="Memo("+(t.displayName||t.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(Xn.prototype=new Bt).isPureReactComponent=!0,Xn.prototype.shouldComponentUpdate=function(t,e){return Qn(this.props,t)||Qn(this.state,e)};var Jn=_t.__b;_t.__b=function(t){t.type&&t.type.__f&&t.ref&&(t.props.ref=t.ref,t.ref=null),Jn&&Jn(t)};var tr="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function er(t){function e(e){var n=Yn({},e);return delete n.ref,t(n,e.ref||null)}return e.$$typeof=tr,e.render=e,e.prototype.isReactComponent=e.__f=!0,e.displayName="ForwardRef("+(t.displayName||t.name)+")",e}var nr=function(t,e){return null==t?null:zt(zt(t).map(e))},rr={map:nr,forEach:nr,count:function(t){return t?zt(t).length:0},only:function(t){var e=zt(t);if(1!==e.length)throw"Children.only";return e[0]},toArray:zt},ir=_t.__e;_t.__e=function(t,e,n,r){if(t.then)for(var i,o=e;o=o.__;)if((i=o.__c)&&i.__c)return null==e.__e&&(e.__e=n.__e,e.__k=n.__k),i.__c(t,e);ir(t,e,n,r)};var or=_t.unmount;function sr(t,e,n){return t&&(t.__c&&t.__c.__H&&(t.__c.__H.__.forEach((function(t){"function"==typeof t.__c&&t.__c()})),t.__c.__H=null),null!=(t=Yn({},t)).__c&&(t.__c.__P===n&&(t.__c.__P=e),t.__c=null),t.__k=t.__k&&t.__k.map((function(t){return sr(t,e,n)}))),t}function ar(t,e,n){return t&&n&&(t.__v=null,t.__k=t.__k&&t.__k.map((function(t){return ar(t,e,n)})),t.__c&&t.__c.__P===e&&(t.__e&&n.appendChild(t.__e),t.__c.__e=!0,t.__c.__P=n)),t}function lr(){this.__u=0,this.t=null,this.__b=null}function ur(t){var e=t.__.__c;return e&&e.__a&&e.__a(t)}function cr(t){var e,n,r;function i(i){if(e||(e=t()).then((function(t){n=t.default||t}),(function(t){r=t})),r)throw r;if(!n)throw e;return Dt(n,i)}return i.displayName="Lazy",i.__f=!0,i}function dr(){this.u=null,this.o=null}_t.unmount=function(t){var e=t.__c;e&&e.__R&&e.__R(),e&&32&t.__u&&(t.type=null),or&&or(t)},(lr.prototype=new Bt).__c=function(t,e){var n=e.__c,r=this;null==r.t&&(r.t=[]),r.t.push(n);var i=ur(r.__v),o=!1,s=function(){o||(o=!0,n.__R=null,i?i(a):a())};n.__R=s;var a=function(){if(! --r.__u){if(r.state.__a){var t=r.state.__a;r.__v.__k[0]=ar(t,t.__c.__P,t.__c.__O)}var e;for(r.setState({__a:r.__b=null});e=r.t.pop();)e.forceUpdate()}};r.__u++||32&e.__u||r.setState({__a:r.__b=r.__v.__k[0]}),t.then(s,s)},lr.prototype.componentWillUnmount=function(){this.t=[]},lr.prototype.render=function(t,e){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=sr(this.__b,n,r.__O=r.__P)}this.__b=null}var i=e.__a&&Dt(It,null,t.fallback);return i&&(i.__u&=-33),[Dt(It,null,e.__a?null:t.children),i]};var hr=function(t,e,n){if(++n[1]===n[0]&&t.o.delete(e),t.props.revealOrder&&("t"!==t.props.revealOrder[0]||!t.o.size))for(n=t.u;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;t.u=n=n[2]}};function pr(t){return this.getChildContext=function(){return t.context},t.children}function fr(t){var e=this,n=t.i;e.componentWillUnmount=function(){ne(null,e.l),e.l=null,e.i=null},e.i&&e.i!==n&&e.componentWillUnmount(),e.l||(e.i=n,e.l={nodeType:1,parentNode:n,childNodes:[],contains:function(){return!0},appendChild:function(t){this.childNodes.push(t),e.i.appendChild(t)},insertBefore:function(t,n){this.childNodes.push(t),e.i.appendChild(t)},removeChild:function(t){this.childNodes.splice(this.childNodes.indexOf(t)>>>1,1),e.i.removeChild(t)}}),ne(Dt(pr,{context:e.context},t.__v),e.l)}function mr(t,e){var n=Dt(fr,{__v:t,i:e});return n.containerInfo=e,n}(dr.prototype=new Bt).__a=function(t){var e=this,n=ur(e.__v),r=e.o.get(t);return r[0]++,function(i){var o=function(){e.props.revealOrder?(r.push(i),hr(e,t,r)):i()};n?n(o):o()}},dr.prototype.render=function(t){this.u=null,this.o=new Map;var e=zt(t.children);t.revealOrder&&"b"===t.revealOrder[0]&&e.reverse();for(var n=e.length;n--;)this.o.set(e[n],this.u=[1,0,this.u]);return t.children},dr.prototype.componentDidUpdate=dr.prototype.componentDidMount=function(){var t=this;this.o.forEach((function(e,n){hr(t,n,e)}))};var vr="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,gr=/^(?: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]/,yr=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,_r=/[A-Z0-9]/g,br="undefined"!=typeof document,wr=function(t){return("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(t)};function xr(t,e,n){return null==e.__k&&(e.textContent=""),ne(t,e),"function"==typeof n&&n(),t?t.__c:null}function Sr(t,e,n){return re(t,e),"function"==typeof n&&n(),t?t.__c:null}Bt.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach((function(t){Object.defineProperty(Bt.prototype,t,{configurable:!0,get:function(){return this["UNSAFE_"+t]},set:function(e){Object.defineProperty(this,t,{configurable:!0,writable:!0,value:e})}})}));var Er=_t.event;function kr(){}function Pr(){return this.cancelBubble}function Tr(){return this.defaultPrevented}_t.event=function(t){return Er&&(t=Er(t)),t.persist=kr,t.isPropagationStopped=Pr,t.isDefaultPrevented=Tr,t.nativeEvent=t};var Ar,Cr={enumerable:!1,configurable:!0,get:function(){return this.class}},Rr=_t.vnode;_t.vnode=function(t){"string"==typeof t.type&&function(t){var e=t.props,n=t.type,r={},i=-1===n.indexOf("-");for(var o in e){var s=e[o];if(!("value"===o&&"defaultValue"in e&&null==s||br&&"children"===o&&"noscript"===n||"class"===o||"className"===o)){var a=o.toLowerCase();"defaultValue"===o&&"value"in e&&null==e.value?o="value":"download"===o&&!0===s?s="":"translate"===a&&"no"===s?s=!1:"o"===a[0]&&"n"===a[1]?"ondoubleclick"===a?o="ondblclick":"onchange"!==a||"input"!==n&&"textarea"!==n||wr(e.type)?"onfocus"===a?o="onfocusin":"onblur"===a?o="onfocusout":yr.test(o)&&(o=a):a=o="oninput":i&&gr.test(o)?o=o.replace(_r,"-$&").toLowerCase():null===s&&(s=void 0),"oninput"===a&&r[o=a]&&(o="oninputCapture"),r[o]=s}}"select"==n&&r.multiple&&Array.isArray(r.value)&&(r.value=zt(e.children).forEach((function(t){t.props.selected=-1!=r.value.indexOf(t.props.value)}))),"select"==n&&null!=r.defaultValue&&(r.value=zt(e.children).forEach((function(t){t.props.selected=r.multiple?-1!=r.defaultValue.indexOf(t.props.value):r.defaultValue==t.props.value}))),e.class&&!e.className?(r.class=e.class,Object.defineProperty(r,"className",Cr)):(e.className&&!e.class||e.class&&e.className)&&(r.class=r.className=e.className),t.props=r}(t),t.$$typeof=vr,Rr&&Rr(t)};var Or=_t.__r;_t.__r=function(t){Or&&Or(t),Ar=t.__c};var Mr=_t.diffed;_t.diffed=function(t){Mr&&Mr(t);var e=t.props,n=t.__e;null!=n&&"textarea"===t.type&&"value"in e&&e.value!==n.value&&(n.value=null==e.value?"":e.value),Ar=null};var Fr={ReactCurrentDispatcher:{current:{readContext:function(t){return Ar.__n[t.__c].props.value},useCallback:In,useContext:Bn,useDebugValue:Nn,useDeferredValue:$r,useEffect:Fn,useId:Gn,useImperativeHandle:Vn,useInsertionEffect:qr,useLayoutEffect:Ln,useMemo:jn,useReducer:Mn,useRef:Dn,useState:On,useSyncExternalStore:Yr,useTransition:zr}}};function Lr(t){return Dt.bind(null,t)}function Dr(t){return!!t&&t.$$typeof===vr}function Vr(t){return Dr(t)&&t.type===It}function jr(t){return!!t&&!!t.displayName&&("string"==typeof t.displayName||t.displayName instanceof String)&&t.displayName.startsWith("Memo(")}function Ir(t){return Dr(t)?ie.apply(null,arguments):t}function Br(t){return!!t.__k&&(ne(null,t),!0)}function Nr(t){return t&&(t.base||1===t.nodeType&&t)||null}var Gr=function(t,e){return t(e)},Ur=function(t,e){return t(e)},Wr=It;function Hr(t){t()}function $r(t){return t}function zr(){return[!1,Hr]}var qr=Ln,Kr=Dr;function Yr(t,e){var n=e(),r=On({h:{__:n,v:e}}),i=r[0].h,o=r[1];return Ln((function(){i.__=n,i.v=e,Qr(i)&&o({h:i})}),[t,n,e]),Fn((function(){return Qr(i)&&o({h:i}),t((function(){Qr(i)&&o({h:i})}))}),[t]),n}function Qr(t){var e,n,r=t.v,i=t.__;try{var o=r();return!((e=i)===(n=o)&&(0!==e||1/e==1/n)||e!=e&&n!=n)}catch(s){return!0}}var Xr={useState:On,useId:Gn,useReducer:Mn,useEffect:Fn,useLayoutEffect:Ln,useInsertionEffect:qr,useTransition:zr,useDeferredValue:$r,useSyncExternalStore:Yr,startTransition:Hr,useRef:Dn,useImperativeHandle:Vn,useMemo:jn,useCallback:In,useContext:Bn,useDebugValue:Nn,version:"17.0.2",Children:rr,render:xr,hydrate:Sr,unmountComponentAtNode:Br,createPortal:mr,createElement:Dt,createContext:oe,createFactory:Lr,cloneElement:Ir,createRef:jt,Fragment:It,isValidElement:Dr,isElement:Kr,isFragment:Vr,isMemo:jr,findDOMNode:Nr,Component:Bt,PureComponent:Xn,memo:Zn,forwardRef:er,flushSync:Ur,unstable_batchedUpdates:Gr,StrictMode:Wr,Suspense:lr,SuspenseList:dr,lazy:cr,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Fr};const Zr=Object.freeze(Object.defineProperty({__proto__:null,Children:rr,Component:Bt,Fragment:It,PureComponent:Xn,StrictMode:Wr,Suspense:lr,SuspenseList:dr,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Fr,cloneElement:Ir,createContext:oe,createElement:Dt,createFactory:Lr,createPortal:mr,createRef:jt,default:Xr,findDOMNode:Nr,flushSync:Ur,forwardRef:er,hydrate:Sr,isElement:Kr,isFragment:Vr,isMemo:jr,isValidElement:Dr,lazy:cr,memo:Zn,render:xr,startTransition:Hr,unmountComponentAtNode:Br,unstable_batchedUpdates:Gr,useCallback:In,useContext:Bn,useDebugValue:Nn,useDeferredValue:$r,useEffect:Fn,useErrorBoundary:function(t){var e=Rn(mn++,10),n=On();return e.__=t,vn.componentDidCatch||(vn.componentDidCatch=function(t,r){e.__&&e.__(t,r),n[1](t)}),[n[0],function(){n[1](void 0)}]},useId:Gn,useImperativeHandle:Vn,useInsertionEffect:qr,useLayoutEffect:Ln,useMemo:jn,useReducer:Mn,useRef:Dn,useState:On,useSyncExternalStore:Yr,useTransition:zr,version:"17.0.2"},Symbol.toStringTag,{value:"Module"}));function Jr(){return Jr=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},Jr.apply(null,arguments)}var ti={exports:{}},ei={},ni="function"==typeof Symbol&&Symbol.for,ri=ni?Symbol.for("react.element"):60103,ii=ni?Symbol.for("react.portal"):60106,oi=ni?Symbol.for("react.fragment"):60107,si=ni?Symbol.for("react.strict_mode"):60108,ai=ni?Symbol.for("react.profiler"):60114,li=ni?Symbol.for("react.provider"):60109,ui=ni?Symbol.for("react.context"):60110,ci=ni?Symbol.for("react.async_mode"):60111,di=ni?Symbol.for("react.concurrent_mode"):60111,hi=ni?Symbol.for("react.forward_ref"):60112,pi=ni?Symbol.for("react.suspense"):60113,fi=ni?Symbol.for("react.suspense_list"):60120,mi=ni?Symbol.for("react.memo"):60115,vi=ni?Symbol.for("react.lazy"):60116,gi=ni?Symbol.for("react.block"):60121,yi=ni?Symbol.for("react.fundamental"):60117,_i=ni?Symbol.for("react.responder"):60118,bi=ni?Symbol.for("react.scope"):60119;function wi(t){if("object"==typeof t&&null!==t){var e=t.$$typeof;switch(e){case ri:switch(t=t.type){case ci:case di:case oi:case ai:case si:case pi:return t;default:switch(t=t&&t.$$typeof){case ui:case hi:case vi:case mi:case li:return t;default:return e}}case ii:return e}}}function xi(t){return wi(t)===di}ei.AsyncMode=ci,ei.ConcurrentMode=di,ei.ContextConsumer=ui,ei.ContextProvider=li,ei.Element=ri,ei.ForwardRef=hi,ei.Fragment=oi,ei.Lazy=vi,ei.Memo=mi,ei.Portal=ii,ei.Profiler=ai,ei.StrictMode=si,ei.Suspense=pi,ei.isAsyncMode=function(t){return xi(t)||wi(t)===ci},ei.isConcurrentMode=xi,ei.isContextConsumer=function(t){return wi(t)===ui},ei.isContextProvider=function(t){return wi(t)===li},ei.isElement=function(t){return"object"==typeof t&&null!==t&&t.$$typeof===ri},ei.isForwardRef=function(t){return wi(t)===hi},ei.isFragment=function(t){return wi(t)===oi},ei.isLazy=function(t){return wi(t)===vi},ei.isMemo=function(t){return wi(t)===mi},ei.isPortal=function(t){return wi(t)===ii},ei.isProfiler=function(t){return wi(t)===ai},ei.isStrictMode=function(t){return wi(t)===si},ei.isSuspense=function(t){return wi(t)===pi},ei.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===oi||t===di||t===ai||t===si||t===pi||t===fi||"object"==typeof t&&null!==t&&(t.$$typeof===vi||t.$$typeof===mi||t.$$typeof===li||t.$$typeof===ui||t.$$typeof===hi||t.$$typeof===yi||t.$$typeof===_i||t.$$typeof===bi||t.$$typeof===gi)},ei.typeOf=wi,ti.exports=ei;var Si=ti.exports,Ei={};Ei[Si.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Ei[Si.Memo]={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0};function ki(t,e,n){var r="";return n.split(" ").forEach((function(n){void 0!==t[n]?e.push(t[n]+";"):r+=n+" "})),r}var Pi=function(t,e,n){var r=t.key+"-"+e.name;!1===n&&void 0===t.registered[r]&&(t.registered[r]=e.styles)},Ti=function(t,e,n){Pi(t,e,n);var r=t.key+"-"+e.name;if(void 0===t.inserted[e.name]){var i=e;do{t.insert(e===i?"."+r:"",i,t.sheet,!0),i=i.next}while(void 0!==i)}};var Ai={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},Ci=!1,Ri=/[A-Z]|^ms/g,Oi=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Mi=function(t){return 45===t.charCodeAt(1)},Fi=function(t){return null!=t&&"boolean"!=typeof t},Li=ln((function(t){return Mi(t)?t:t.replace(Ri,"-$&").toLowerCase()})),Di=function(t,e){switch(t){case"animation":case"animationName":if("string"==typeof e)return e.replace(Oi,(function(t,e,n){return Ii={name:e,styles:n,next:Ii},e}))}return 1===Ai[t]||Mi(t)||"number"!=typeof e||0===e?e:e+"px"},Vi="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function ji(t,e,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 Ii={name:i.name,styles:i.styles,next:Ii},i.name;var o=n;if(void 0!==o.styles){var s=o.next;if(void 0!==s)for(;void 0!==s;)Ii={name:s.name,styles:s.styles,next:Ii},s=s.next;return o.styles+";"}return function(t,e,n){var r="";if(Array.isArray(n))for(var i=0;i<n.length;i++)r+=ji(t,e,n[i])+";";else for(var o in n){var s=n[o];if("object"!=typeof s){var a=s;null!=e&&void 0!==e[a]?r+=o+"{"+e[a]+"}":Fi(a)&&(r+=Li(o)+":"+Di(o,a)+";")}else{if("NO_COMPONENT_SELECTOR"===o&&Ci)throw new Error(Vi);if(!Array.isArray(s)||"string"!=typeof s[0]||null!=e&&void 0!==e[s[0]]){var l=ji(t,e,s);switch(o){case"animation":case"animationName":r+=Li(o)+":"+l+";";break;default:r+=o+"{"+l+"}"}}else for(var u=0;u<s.length;u++)Fi(s[u])&&(r+=Li(o)+":"+Di(o,s[u])+";")}}return r}(t,e,n);case"function":if(void 0!==t){var a=Ii,l=n(t);return Ii=a,ji(t,e,l)}}var u=n;if(null==e)return u;var c=e[u];return void 0!==c?c:u}var Ii,Bi=/label:\s*([^\s;\n{]+)\s*(;|$)/g;function Ni(t,e,n){if(1===t.length&&"object"==typeof t[0]&&null!==t[0]&&void 0!==t[0].styles)return t[0];var r=!0,i="";Ii=void 0;var o=t[0];null==o||void 0===o.raw?(r=!1,i+=ji(n,e,o)):i+=o[0];for(var s=1;s<t.length;s++){if(i+=ji(n,e,t[s]),r)i+=o[s]}Bi.lastIndex=0;for(var a,l="";null!==(a=Bi.exec(i));)l+="-"+a[1];var u=function(t){for(var e,n=0,r=0,i=t.length;i>=4;++r,i-=4)e=1540483477*(65535&(e=255&t.charCodeAt(r)|(255&t.charCodeAt(++r))<<8|(255&t.charCodeAt(++r))<<16|(255&t.charCodeAt(++r))<<24))+(59797*(e>>>16)<<16),n=1540483477*(65535&(e^=e>>>24))+(59797*(e>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(i){case 3:n^=(255&t.charCodeAt(r+2))<<16;case 2:n^=(255&t.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&t.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:u,styles:i,next:Ii}}var Gi=!!Zr.useInsertionEffect&&Zr.useInsertionEffect,Ui=Gi||function(t){return t()},Wi=Gi||Ln,Hi=oe("undefined"!=typeof HTMLElement?bn({key:"css"}):null),$i=Hi.Provider,zi=function(t){return er((function(e,n){var r=Bn(Hi);return t(e,r,n)}))},qi=oe({}),Ki={}.hasOwnProperty,Yi="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",Qi=function(t,e){var n={};for(var r in e)Ki.call(e,r)&&(n[r]=e[r]);return n[Yi]=t,n},Xi=function(t){var e=t.cache,n=t.serialized,r=t.isStringTag;return Pi(e,n,r),Ui((function(){return Ti(e,n,r)})),null},Zi=zi((function(t,e,n){var r=t.css;"string"==typeof r&&void 0!==e.registered[r]&&(r=e.registered[r]);var i=t[Yi],o=[r],s="";"string"==typeof t.className?s=ki(e.registered,o,t.className):null!=t.className&&(s=t.className+" ");var a=Ni(o,void 0,Bn(qi));s+=e.key+"-"+a.name;var l={};for(var u in t)Ki.call(t,u)&&"css"!==u&&u!==Yi&&(l[u]=t[u]);return l.className=s,n&&(l.ref=n),Dt(It,null,Dt(Xi,{cache:e,serialized:a,isStringTag:"string"==typeof i}),Dt(i,l))})),Ji=zi((function(t,e){var n=Ni([t.styles],void 0,Bn(qi)),r=Dn();return Wi((function(){var t=e.key+"-global",i=new e.sheet.constructor({key:t,nonce:e.sheet.nonce,container:e.sheet.container,speedy:e.sheet.isSpeedy}),o=!1,s=document.querySelector('style[data-emotion="'+t+" "+n.name+'"]');return e.sheet.tags.length&&(i.before=e.sheet.tags[0]),null!==s&&(o=!0,s.setAttribute("data-emotion",t),i.hydrate([s])),r.current=[i,o],function(){i.flush()}}),[e]),Wi((function(){var t=r.current,i=t[0];if(t[1])t[1]=!1;else{if(void 0!==n.next&&Ti(e,n.next,!0),i.tags.length){var o=i.tags[i.tags.length-1].nextElementSibling;i.before=o,i.flush()}e.insert("",n,i,!1)}}),[e,n.name]),null}));function to(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return Ni(e)}var eo=0;function no(t,e,n,r,i,o){e||(e={});var s,a,l=e;if("ref"in l)for(a in l={},e)"ref"==a?s=e[a]:l[a]=e[a];var u={type:t,props:l,key:n,ref:s,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--eo,__i:-1,__u:0,__source:i,__self:o};if("function"==typeof t&&(s=t.defaultProps))for(a in s)void 0===l[a]&&(l[a]=s[a]);return _t.vnode&&_t.vnode(u),u}var ro=It;function io(t,e,n){return Ki.call(e,"css")?no(Zi,Qi(t,e),n):no(t,e,n)}function oo(t,e,n){return Ki.call(e,"css")?no(Zi,Qi(t,e),n):no(t,e,n)}const so=to({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"}}),ao=()=>oo(It,{children:[io(Ji,{styles:to`
|
|
2
2
|
${{"*, ::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]":{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"}}}
|
|
3
|
-
`}),fo(lo,{styles:vo})]});let yo;class bo extends Error{constructor(t,e){super(t),wt(this,"response"),this.response=e}}const wo=async(t,e,n,r)=>{await xo(t,e,n,r,!0)},xo=async(t,e,n,r,i)=>{const o=await fetch(t,{method:n,body:r?JSON.stringify(r):void 0,headers:{"content-type":"application/json","x-app-version":"0.3.1680",authorization:`Bearer ${e}`},signal:(null==AbortSignal?void 0:AbortSignal.timeout)&&AbortSignal.timeout(15e3)});if(!o.ok)throw new bo(`[API Error] Status: ${o.statusText}. Response: ${await o.text()}`,o);return i?{}:await o.json()},_o=t=>async e=>{const n=new URL(`${t.url}/promoted-benefits/admin/v1.0/promotion`);return wo(n,t.accessToken,"POST",e)},So=t=>e=>async n=>{const r=new URL(`${t.url}/promoted-benefits/admin/v1.0/promotion/${e}`);return wo(r,t.accessToken,"PUT",n)},Eo=()=>{const t=Gn(yo);return{getAllPromotions:(e=t.backend,async()=>{const t=new URL(`${e.url}/promoted-benefits/admin/v1.0/promotion`);return xo(t,e.accessToken,"GET")}),createPromotion:_o(t.backend),updatePromotion:So(t.backend)};var e};var ko=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Po="undefined"==typeof window||"Deno"in globalThis;function To(){}function Co(t){return"number"==typeof t&&t>=0&&t!==1/0}function Ao(t,e){return Math.max(t+(e||0)-Date.now(),0)}function Ro(t,e){return"function"==typeof t?t(e):t}function Oo(t,e){return"function"==typeof t?t(e):t}function Fo(t,e){const{type:n="all",exact:r,fetchStatus:i,predicate:o,queryKey:s,stale:a}=t;if(s)if(r){if(e.queryHash!==Mo(s,e.options))return!1}else if(!Vo(e.queryKey,s))return!1;if("all"!==n){const t=e.isActive();if("active"===n&&!t)return!1;if("inactive"===n&&t)return!1}return("boolean"!=typeof a||e.isStale()===a)&&((!i||i===e.state.fetchStatus)&&!(o&&!o(e)))}function Lo(t,e){const{exact:n,status:r,predicate:i,mutationKey:o}=t;if(o){if(!e.options.mutationKey)return!1;if(n){if(Do(e.options.mutationKey)!==Do(o))return!1}else if(!Vo(e.options.mutationKey,o))return!1}return(!r||e.state.status===r)&&!(i&&!i(e))}function Mo(t,e){return((null==e?void 0:e.queryKeyHashFn)||Do)(t)}function Do(t){return JSON.stringify(t,((t,e)=>No(e)?Object.keys(e).sort().reduce(((t,n)=>(t[n]=e[n],t)),{}):e))}function Vo(t,e){return t===e||typeof t==typeof e&&(!(!t||!e||"object"!=typeof t||"object"!=typeof e)&&!Object.keys(e).some((n=>!Vo(t[n],e[n]))))}function jo(t,e){if(t===e)return t;const n=Bo(t)&&Bo(e);if(n||No(t)&&No(e)){const r=n?t:Object.keys(t),i=r.length,o=n?e:Object.keys(e),s=o.length,a=n?[]:{};let l=0;for(let u=0;u<s;u++){const i=n?u:o[u];(!n&&r.includes(i)||n)&&void 0===t[i]&&void 0===e[i]?(a[i]=void 0,l++):(a[i]=jo(t[i],e[i]),a[i]===t[i]&&void 0!==t[i]&&l++)}return i===s&&l===i?t:a}return e}function Io(t,e){if(!e||Object.keys(t).length!==Object.keys(e).length)return!1;for(const n in t)if(t[n]!==e[n])return!1;return!0}function Bo(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function No(t){if(!Uo(t))return!1;const e=t.constructor;if(void 0===e)return!0;const n=e.prototype;return!!Uo(n)&&(!!n.hasOwnProperty("isPrototypeOf")&&Object.getPrototypeOf(t)===Object.prototype)}function Uo(t){return"[object Object]"===Object.prototype.toString.call(t)}function Wo(t,e,n){return"function"==typeof n.structuralSharing?n.structuralSharing(t,e):!1!==n.structuralSharing?jo(t,e):e}function Ho(t,e,n=0){const r=[...t,e];return n&&r.length>n?r.slice(1):r}function $o(t,e,n=0){const r=[e,...t];return n&&r.length>n?r.slice(0,-1):r}var zo=Symbol();function qo(t,e){return!t.queryFn&&(null==e?void 0:e.initialPromise)?()=>e.initialPromise:t.queryFn&&t.queryFn!==zo?t.queryFn:()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`))}var Ko=new(r=class extends ko{constructor(){super(),St(this,t),St(this,e),St(this,n),Et(this,n,(t=>{if(!Po&&window.addEventListener){const e=()=>t();return window.addEventListener("visibilitychange",e,!1),()=>{window.removeEventListener("visibilitychange",e)}}}))}onSubscribe(){_t(this,e)||this.setEventListener(_t(this,n))}onUnsubscribe(){var t;this.hasListeners()||(null==(t=_t(this,e))||t.call(this),Et(this,e,void 0))}setEventListener(t){var r;Et(this,n,t),null==(r=_t(this,e))||r.call(this),Et(this,e,t((t=>{"boolean"==typeof t?this.setFocused(t):this.onFocus()})))}setFocused(e){_t(this,t)!==e&&(Et(this,t,e),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach((e=>{e(t)}))}isFocused(){var e;return"boolean"==typeof _t(this,t)?_t(this,t):"hidden"!==(null==(e=globalThis.document)?void 0:e.visibilityState)}},t=new WeakMap,e=new WeakMap,n=new WeakMap,r),Go=new(a=class extends ko{constructor(){super(),St(this,i,!0),St(this,o),St(this,s),Et(this,s,(t=>{if(!Po&&window.addEventListener){const e=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",e,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",e),window.removeEventListener("offline",n)}}}))}onSubscribe(){_t(this,o)||this.setEventListener(_t(this,s))}onUnsubscribe(){var t;this.hasListeners()||(null==(t=_t(this,o))||t.call(this),Et(this,o,void 0))}setEventListener(t){var e;Et(this,s,t),null==(e=_t(this,o))||e.call(this),Et(this,o,t(this.setOnline.bind(this)))}setOnline(t){_t(this,i)!==t&&(Et(this,i,t),this.listeners.forEach((e=>{e(t)})))}isOnline(){return _t(this,i)}},i=new WeakMap,o=new WeakMap,s=new WeakMap,a);function Yo(t){return Math.min(1e3*2**t,3e4)}function Qo(t){return"online"!==(t??"online")||Go.isOnline()}var Xo=class extends Error{constructor(t){super("CancelledError"),this.revert=null==t?void 0:t.revert,this.silent=null==t?void 0:t.silent}};function Zo(t){return t instanceof Xo}function Jo(t){let e,n,r,i=!1,o=0,s=!1;const a=new Promise(((t,e)=>{n=t,r=e})),l=()=>Ko.isFocused()&&("always"===t.networkMode||Go.isOnline())&&t.canRun(),u=()=>Qo(t.networkMode)&&t.canRun(),c=r=>{var i;s||(s=!0,null==(i=t.onSuccess)||i.call(t,r),null==e||e(),n(r))},d=n=>{var i;s||(s=!0,null==(i=t.onError)||i.call(t,n),null==e||e(),r(n))},h=()=>new Promise((n=>{var r;e=t=>{(s||l())&&n(t)},null==(r=t.onPause)||r.call(t)})).then((()=>{var n;e=void 0,s||null==(n=t.onContinue)||n.call(t)})),p=()=>{if(s)return;let e;const n=0===o?t.initialPromise:void 0;try{e=n??t.fn()}catch(r){e=Promise.reject(r)}Promise.resolve(e).then(c).catch((e=>{var n;if(s)return;const r=t.retry??(Po?0:3),a=t.retryDelay??Yo,u="function"==typeof a?a(o,e):a,c=!0===r||"number"==typeof r&&o<r||"function"==typeof r&&r(o,e);var f;!i&&c?(o++,null==(n=t.onFail)||n.call(t,o,e),(f=u,new Promise((t=>{setTimeout(t,f)}))).then((()=>l()?void 0:h())).then((()=>{i?d(e):p()}))):d(e)}))};return{promise:a,cancel:e=>{var n;s||(d(new Xo(e)),null==(n=t.abort)||n.call(t))},continue:()=>(null==e||e(),a),cancelRetry:()=>{i=!0},continueRetry:()=>{i=!1},canStart:u,start:()=>(u()?p():h().then(p),a)}}var ts=function(){let t=[],e=0,n=t=>{t()},r=t=>{t()},i=t=>setTimeout(t,0);const o=r=>{e?t.push(r):i((()=>{n(r)}))};return{batch:o=>{let s;e++;try{s=o()}finally{e--,e||(()=>{const e=t;t=[],e.length&&i((()=>{r((()=>{e.forEach((t=>{n(t)}))}))}))})()}return s},batchCalls:t=>(...e)=>{o((()=>{t(...e)}))},schedule:o,setNotifyFunction:t=>{n=t},setBatchNotifyFunction:t=>{r=t},setScheduler:t=>{i=t}}}(),es=(u=class{constructor(){St(this,l)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Co(this.gcTime)&&Et(this,l,setTimeout((()=>{this.optionalRemove()}),this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(Po?1/0:3e5))}clearGcTimeout(){_t(this,l)&&(clearTimeout(_t(this,l)),Et(this,l,void 0))}},l=new WeakMap,u),ns=(y=class extends es{constructor(t){super(),St(this,v),St(this,c),St(this,d),St(this,h),St(this,p),St(this,f),St(this,m),Et(this,m,!1),Et(this,f,t.defaultOptions),this.setOptions(t.options),this.observers=[],Et(this,h,t.cache),this.queryKey=t.queryKey,this.queryHash=t.queryHash,Et(this,c,function(t){const e="function"==typeof t.initialData?t.initialData():t.initialData,n=void 0!==e,r=n?"function"==typeof t.initialDataUpdatedAt?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:e,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=t.state??_t(this,c),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return null==(t=_t(this,p))?void 0:t.promise}setOptions(t){this.options={..._t(this,f),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){this.observers.length||"idle"!==this.state.fetchStatus||_t(this,h).remove(this)}setData(t,e){const n=Wo(this.state.data,t,this.options);return kt(this,v,g).call(this,{data:n,type:"success",dataUpdatedAt:null==e?void 0:e.updatedAt,manual:null==e?void 0:e.manual}),n}setState(t,e){kt(this,v,g).call(this,{type:"setState",state:t,setStateOptions:e})}cancel(t){var e,n;const r=null==(e=_t(this,p))?void 0:e.promise;return null==(n=_t(this,p))||n.cancel(t),r?r.then(To).catch(To):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(_t(this,c))}isActive(){return this.observers.some((t=>!1!==Oo(t.options.enabled,this)))}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return!!this.state.isInvalidated||(this.getObserversCount()>0?this.observers.some((t=>t.getCurrentResult().isStale)):void 0===this.state.data)}isStaleByTime(t=0){return this.state.isInvalidated||void 0===this.state.data||!Ao(this.state.dataUpdatedAt,t)}onFocus(){var t;const e=this.observers.find((t=>t.shouldFetchOnWindowFocus()));null==e||e.refetch({cancelRefetch:!1}),null==(t=_t(this,p))||t.continue()}onOnline(){var t;const e=this.observers.find((t=>t.shouldFetchOnReconnect()));null==e||e.refetch({cancelRefetch:!1}),null==(t=_t(this,p))||t.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),_t(this,h).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter((e=>e!==t)),this.observers.length||(_t(this,p)&&(_t(this,m)?_t(this,p).cancel({revert:!0}):_t(this,p).cancelRetry()),this.scheduleGc()),_t(this,h).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||kt(this,v,g).call(this,{type:"invalidate"})}fetch(t,e){var n,r,i;if("idle"!==this.state.fetchStatus)if(void 0!==this.state.data&&(null==e?void 0:e.cancelRefetch))this.cancel({silent:!0});else if(_t(this,p))return _t(this,p).continueRetry(),_t(this,p).promise;if(t&&this.setOptions(t),!this.options.queryFn){const t=this.observers.find((t=>t.options.queryFn));t&&this.setOptions(t.options)}const o=new AbortController,s=t=>{Object.defineProperty(t,"signal",{enumerable:!0,get:()=>(Et(this,m,!0),o.signal)})},a={fetchOptions:e,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>{const t=qo(this.options,e),n={queryKey:this.queryKey,meta:this.meta};return s(n),Et(this,m,!1),this.options.persister?this.options.persister(t,n,this):t(n)}};s(a),null==(n=this.options.behavior)||n.onFetch(a,this),Et(this,d,this.state),"idle"!==this.state.fetchStatus&&this.state.fetchMeta===(null==(r=a.fetchOptions)?void 0:r.meta)||kt(this,v,g).call(this,{type:"fetch",meta:null==(i=a.fetchOptions)?void 0:i.meta});const l=t=>{var e,n,r,i;Zo(t)&&t.silent||kt(this,v,g).call(this,{type:"error",error:t}),Zo(t)||(null==(n=(e=_t(this,h).config).onError)||n.call(e,t,this),null==(i=(r=_t(this,h).config).onSettled)||i.call(r,this.state.data,t,this)),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return Et(this,p,Jo({initialPromise:null==e?void 0:e.initialPromise,fn:a.fetchFn,abort:o.abort.bind(o),onSuccess:t=>{var e,n,r,i;if(void 0!==t){try{this.setData(t)}catch(o){return void l(o)}null==(n=(e=_t(this,h).config).onSuccess)||n.call(e,t,this),null==(i=(r=_t(this,h).config).onSettled)||i.call(r,t,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1}else l(new Error(`${this.queryHash} data is undefined`))},onError:l,onFail:(t,e)=>{kt(this,v,g).call(this,{type:"failed",failureCount:t,error:e})},onPause:()=>{kt(this,v,g).call(this,{type:"pause"})},onContinue:()=>{kt(this,v,g).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),_t(this,p).start()}},c=new WeakMap,d=new WeakMap,h=new WeakMap,p=new WeakMap,f=new WeakMap,m=new WeakMap,v=new WeakSet,g=function(t){this.state=(e=>{switch(t.type){case"failed":return{...e,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...e,fetchStatus:"paused"};case"continue":return{...e,fetchStatus:"fetching"};case"fetch":return{...e,...rs(e.data,this.options),fetchMeta:t.meta??null};case"success":return{...e,data:t.data,dataUpdateCount:e.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const n=t.error;return Zo(n)&&n.revert&&_t(this,d)?{..._t(this,d),fetchStatus:"idle"}:{...e,error:n,errorUpdateCount:e.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:e.fetchFailureCount+1,fetchFailureReason:n,fetchStatus:"idle",status:"error"};case"invalidate":return{...e,isInvalidated:!0};case"setState":return{...e,...t.state}}})(this.state),ts.batch((()=>{this.observers.forEach((t=>{t.onQueryUpdate()})),_t(this,h).notify({query:this,type:"updated",action:t})}))},y);function rs(t,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Qo(e.networkMode)?"fetching":"paused",...void 0===t&&{error:null,status:"pending"}}}var is=(w=class extends ko{constructor(t={}){super(),St(this,b),this.config=t,Et(this,b,new Map)}build(t,e,n){const r=e.queryKey,i=e.queryHash??Mo(r,e);let o=this.get(i);return o||(o=new ns({cache:this,queryKey:r,queryHash:i,options:t.defaultQueryOptions(e),state:n,defaultOptions:t.getQueryDefaults(r)}),this.add(o)),o}add(t){_t(this,b).has(t.queryHash)||(_t(this,b).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const e=_t(this,b).get(t.queryHash);e&&(t.destroy(),e===t&&_t(this,b).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){ts.batch((()=>{this.getAll().forEach((t=>{this.remove(t)}))}))}get(t){return _t(this,b).get(t)}getAll(){return[..._t(this,b).values()]}find(t){const e={exact:!0,...t};return this.getAll().find((t=>Fo(e,t)))}findAll(t={}){const e=this.getAll();return Object.keys(t).length>0?e.filter((e=>Fo(t,e))):e}notify(t){ts.batch((()=>{this.listeners.forEach((e=>{e(t)}))}))}onFocus(){ts.batch((()=>{this.getAll().forEach((t=>{t.onFocus()}))}))}onOnline(){ts.batch((()=>{this.getAll().forEach((t=>{t.onOnline()}))}))}},b=new WeakMap,w),os=(P=class extends es{constructor(t){super(),St(this,E),St(this,x),St(this,_),St(this,S),this.mutationId=t.mutationId,Et(this,_,t.mutationCache),Et(this,x,[]),this.state=t.state||{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0},this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){_t(this,x).includes(t)||(_t(this,x).push(t),this.clearGcTimeout(),_t(this,_).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){Et(this,x,_t(this,x).filter((e=>e!==t))),this.scheduleGc(),_t(this,_).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){_t(this,x).length||("pending"===this.state.status?this.scheduleGc():_t(this,_).remove(this))}continue(){var t;return(null==(t=_t(this,S))?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var e,n,r,i,o,s,a,l,u,c,d,h,p,f,m,v,g,y,b,w;Et(this,S,Jo({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(t,e)=>{kt(this,E,k).call(this,{type:"failed",failureCount:t,error:e})},onPause:()=>{kt(this,E,k).call(this,{type:"pause"})},onContinue:()=>{kt(this,E,k).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>_t(this,_).canRun(this)}));const x="pending"===this.state.status,P=!_t(this,S).canStart();try{if(!x){kt(this,E,k).call(this,{type:"pending",variables:t,isPaused:P}),await(null==(n=(e=_t(this,_).config).onMutate)?void 0:n.call(e,t,this));const o=await(null==(i=(r=this.options).onMutate)?void 0:i.call(r,t));o!==this.state.context&&kt(this,E,k).call(this,{type:"pending",context:o,variables:t,isPaused:P})}const p=await _t(this,S).start();return await(null==(s=(o=_t(this,_).config).onSuccess)?void 0:s.call(o,p,t,this.state.context,this)),await(null==(l=(a=this.options).onSuccess)?void 0:l.call(a,p,t,this.state.context)),await(null==(c=(u=_t(this,_).config).onSettled)?void 0:c.call(u,p,null,this.state.variables,this.state.context,this)),await(null==(h=(d=this.options).onSettled)?void 0:h.call(d,p,null,t,this.state.context)),kt(this,E,k).call(this,{type:"success",data:p}),p}catch(T){try{throw await(null==(f=(p=_t(this,_).config).onError)?void 0:f.call(p,T,t,this.state.context,this)),await(null==(v=(m=this.options).onError)?void 0:v.call(m,T,t,this.state.context)),await(null==(y=(g=_t(this,_).config).onSettled)?void 0:y.call(g,void 0,T,this.state.variables,this.state.context,this)),await(null==(w=(b=this.options).onSettled)?void 0:w.call(b,void 0,T,t,this.state.context)),T}finally{kt(this,E,k).call(this,{type:"error",error:T})}}finally{_t(this,_).runNext(this)}}},x=new WeakMap,_=new WeakMap,S=new WeakMap,E=new WeakSet,k=function(t){this.state=(e=>{switch(t.type){case"failed":return{...e,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...e,isPaused:!0};case"continue":return{...e,isPaused:!1};case"pending":return{...e,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...e,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...e,data:void 0,error:t.error,failureCount:e.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}})(this.state),ts.batch((()=>{_t(this,x).forEach((e=>{e.onMutationUpdate(t)})),_t(this,_).notify({mutation:this,type:"updated",action:t})}))},P);var ss=(A=class extends ko{constructor(t={}){super(),St(this,T),St(this,C),this.config=t,Et(this,T,new Map),Et(this,C,Date.now())}build(t,e,n){const r=new os({mutationCache:this,mutationId:++Pt(this,C)._,options:t.defaultMutationOptions(e),state:n});return this.add(r),r}add(t){const e=as(t),n=_t(this,T).get(e)??[];n.push(t),_t(this,T).set(e,n),this.notify({type:"added",mutation:t})}remove(t){var e;const n=as(t);if(_t(this,T).has(n)){const r=null==(e=_t(this,T).get(n))?void 0:e.filter((e=>e!==t));r&&(0===r.length?_t(this,T).delete(n):_t(this,T).set(n,r))}this.notify({type:"removed",mutation:t})}canRun(t){var e;const n=null==(e=_t(this,T).get(as(t)))?void 0:e.find((t=>"pending"===t.state.status));return!n||n===t}runNext(t){var e;const n=null==(e=_t(this,T).get(as(t)))?void 0:e.find((e=>e!==t&&e.state.isPaused));return(null==n?void 0:n.continue())??Promise.resolve()}clear(){ts.batch((()=>{this.getAll().forEach((t=>{this.remove(t)}))}))}getAll(){return[..._t(this,T).values()].flat()}find(t){const e={exact:!0,...t};return this.getAll().find((t=>Lo(e,t)))}findAll(t={}){return this.getAll().filter((e=>Lo(t,e)))}notify(t){ts.batch((()=>{this.listeners.forEach((e=>{e(t)}))}))}resumePausedMutations(){const t=this.getAll().filter((t=>t.state.isPaused));return ts.batch((()=>Promise.all(t.map((t=>t.continue().catch(To))))))}},T=new WeakMap,C=new WeakMap,A);function as(t){var e;return(null==(e=t.options.scope)?void 0:e.id)??String(t.mutationId)}function ls(t){return{onFetch:(e,n)=>{var r,i,o,s,a;const l=e.options,u=null==(o=null==(i=null==(r=e.fetchOptions)?void 0:r.meta)?void 0:i.fetchMore)?void 0:o.direction,c=(null==(s=e.state.data)?void 0:s.pages)||[],d=(null==(a=e.state.data)?void 0:a.pageParams)||[];let h={pages:[],pageParams:[]},p=0;const f=async()=>{let n=!1;const r=qo(e.options,e.fetchOptions),i=async(t,i,o)=>{if(n)return Promise.reject();if(null==i&&t.pages.length)return Promise.resolve(t);const s={queryKey:e.queryKey,pageParam:i,direction:o?"backward":"forward",meta:e.options.meta};var a;a=s,Object.defineProperty(a,"signal",{enumerable:!0,get:()=>(e.signal.aborted?n=!0:e.signal.addEventListener("abort",(()=>{n=!0})),e.signal)});const l=await r(s),{maxPages:u}=e.options,c=o?$o:Ho;return{pages:c(t.pages,l,u),pageParams:c(t.pageParams,i,u)}};if(u&&c.length){const t="backward"===u,e={pages:c,pageParams:d},n=(t?cs:us)(l,e);h=await i(e,n,t)}else{const e=t??c.length;do{const t=0===p?d[0]??l.initialPageParam:us(l,h);if(p>0&&null==t)break;h=await i(h,t),p++}while(p<e)}return h};e.options.persister?e.fetchFn=()=>{var t,r;return null==(r=(t=e.options).persister)?void 0:r.call(t,f,{queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},n)}:e.fetchFn=f}}}function us(t,{pages:e,pageParams:n}){const r=e.length-1;return e.length>0?t.getNextPageParam(e[r],e,n[r],n):void 0}function cs(t,{pages:e,pageParams:n}){var r;return e.length>0?null==(r=t.getPreviousPageParam)?void 0:r.call(t,e[0],e,n[0],n):void 0}var ds=(I=class{constructor(t={}){St(this,R),St(this,O),St(this,F),St(this,L),St(this,M),St(this,D),St(this,V),St(this,j),Et(this,R,t.queryCache||new is),Et(this,O,t.mutationCache||new ss),Et(this,F,t.defaultOptions||{}),Et(this,L,new Map),Et(this,M,new Map),Et(this,D,0)}mount(){Pt(this,D)._++,1===_t(this,D)&&(Et(this,V,Ko.subscribe((async t=>{t&&(await this.resumePausedMutations(),_t(this,R).onFocus())}))),Et(this,j,Go.subscribe((async t=>{t&&(await this.resumePausedMutations(),_t(this,R).onOnline())}))))}unmount(){var t,e;Pt(this,D)._--,0===_t(this,D)&&(null==(t=_t(this,V))||t.call(this),Et(this,V,void 0),null==(e=_t(this,j))||e.call(this),Et(this,j,void 0))}isFetching(t){return _t(this,R).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return _t(this,O).findAll({...t,status:"pending"}).length}getQueryData(t){var e;const n=this.defaultQueryOptions({queryKey:t});return null==(e=_t(this,R).get(n.queryHash))?void 0:e.state.data}ensureQueryData(t){const e=this.getQueryData(t.queryKey);if(void 0===e)return this.fetchQuery(t);{const n=this.defaultQueryOptions(t),r=_t(this,R).build(this,n);return t.revalidateIfStale&&r.isStaleByTime(Ro(n.staleTime,r))&&this.prefetchQuery(n),Promise.resolve(e)}}getQueriesData(t){return _t(this,R).findAll(t).map((({queryKey:t,state:e})=>[t,e.data]))}setQueryData(t,e,n){const r=this.defaultQueryOptions({queryKey:t}),i=_t(this,R).get(r.queryHash),o=function(t,e){return"function"==typeof t?t(e):t}(e,null==i?void 0:i.state.data);if(void 0!==o)return _t(this,R).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(t,e,n){return ts.batch((()=>_t(this,R).findAll(t).map((({queryKey:t})=>[t,this.setQueryData(t,e,n)]))))}getQueryState(t){var e;const n=this.defaultQueryOptions({queryKey:t});return null==(e=_t(this,R).get(n.queryHash))?void 0:e.state}removeQueries(t){const e=_t(this,R);ts.batch((()=>{e.findAll(t).forEach((t=>{e.remove(t)}))}))}resetQueries(t,e){const n=_t(this,R),r={type:"active",...t};return ts.batch((()=>(n.findAll(t).forEach((t=>{t.reset()})),this.refetchQueries(r,e))))}cancelQueries(t={},e={}){const n={revert:!0,...e},r=ts.batch((()=>_t(this,R).findAll(t).map((t=>t.cancel(n)))));return Promise.all(r).then(To).catch(To)}invalidateQueries(t={},e={}){return ts.batch((()=>{if(_t(this,R).findAll(t).forEach((t=>{t.invalidate()})),"none"===t.refetchType)return Promise.resolve();const n={...t,type:t.refetchType??t.type??"active"};return this.refetchQueries(n,e)}))}refetchQueries(t={},e){const n={...e,cancelRefetch:(null==e?void 0:e.cancelRefetch)??!0},r=ts.batch((()=>_t(this,R).findAll(t).filter((t=>!t.isDisabled())).map((t=>{let e=t.fetch(void 0,n);return n.throwOnError||(e=e.catch(To)),"paused"===t.state.fetchStatus?Promise.resolve():e}))));return Promise.all(r).then(To)}fetchQuery(t){const e=this.defaultQueryOptions(t);void 0===e.retry&&(e.retry=!1);const n=_t(this,R).build(this,e);return n.isStaleByTime(Ro(e.staleTime,n))?n.fetch(e):Promise.resolve(n.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(To).catch(To)}fetchInfiniteQuery(t){return t.behavior=ls(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(To).catch(To)}ensureInfiniteQueryData(t){return t.behavior=ls(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return Go.isOnline()?_t(this,O).resumePausedMutations():Promise.resolve()}getQueryCache(){return _t(this,R)}getMutationCache(){return _t(this,O)}getDefaultOptions(){return _t(this,F)}setDefaultOptions(t){Et(this,F,t)}setQueryDefaults(t,e){_t(this,L).set(Do(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){const e=[..._t(this,L).values()];let n={};return e.forEach((e=>{Vo(t,e.queryKey)&&(n={...n,...e.defaultOptions})})),n}setMutationDefaults(t,e){_t(this,M).set(Do(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){const e=[..._t(this,M).values()];let n={};return e.forEach((e=>{Vo(t,e.mutationKey)&&(n={...n,...e.defaultOptions})})),n}defaultQueryOptions(t){if(t._defaulted)return t;const e={..._t(this,F).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=Mo(e.queryKey,e)),void 0===e.refetchOnReconnect&&(e.refetchOnReconnect="always"!==e.networkMode),void 0===e.throwOnError&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),!0!==e.enabled&&e.queryFn===zo&&(e.enabled=!1),e}defaultMutationOptions(t){return(null==t?void 0:t._defaulted)?t:{..._t(this,F).mutations,...(null==t?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){_t(this,R).clear(),_t(this,O).clear()}},R=new WeakMap,O=new WeakMap,F=new WeakMap,L=new WeakMap,M=new WeakMap,D=new WeakMap,V=new WeakMap,j=new WeakMap,I),hs=(ut=class extends ko{constructor(t,e){super(),St(this,J),St(this,B),St(this,N),St(this,U),St(this,W),St(this,H),St(this,$),St(this,z),St(this,q),St(this,K),St(this,G),St(this,Y),St(this,Q),St(this,X),St(this,Z,new Set),this.options=e,Et(this,B,t),Et(this,z,null),this.bindMethods(),this.setOptions(e)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(_t(this,N).addObserver(this),ps(_t(this,N),this.options)?kt(this,J,tt).call(this):this.updateResult(),kt(this,J,it).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return fs(_t(this,N),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return fs(_t(this,N),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,kt(this,J,ot).call(this),kt(this,J,st).call(this),_t(this,N).removeObserver(this)}setOptions(t,e){const n=this.options,r=_t(this,N);if(this.options=_t(this,B).defaultQueryOptions(t),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled&&"function"!=typeof this.options.enabled&&"boolean"!=typeof Oo(this.options.enabled,_t(this,N)))throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");kt(this,J,at).call(this),_t(this,N).setOptions(this.options),n._defaulted&&!Io(this.options,n)&&_t(this,B).getQueryCache().notify({type:"observerOptionsUpdated",query:_t(this,N),observer:this});const i=this.hasListeners();i&&ms(_t(this,N),r,this.options,n)&&kt(this,J,tt).call(this),this.updateResult(e),!i||_t(this,N)===r&&Oo(this.options.enabled,_t(this,N))===Oo(n.enabled,_t(this,N))&&Ro(this.options.staleTime,_t(this,N))===Ro(n.staleTime,_t(this,N))||kt(this,J,et).call(this);const o=kt(this,J,nt).call(this);!i||_t(this,N)===r&&Oo(this.options.enabled,_t(this,N))===Oo(n.enabled,_t(this,N))&&o===_t(this,X)||kt(this,J,rt).call(this,o)}getOptimisticResult(t){const e=_t(this,B).getQueryCache().build(_t(this,B),t),n=this.createResult(e,t);return function(t,e){if(!Io(t.getCurrentResult(),e))return!0;return!1}(this,n)&&(Et(this,W,n),Et(this,$,this.options),Et(this,H,_t(this,N).state)),n}getCurrentResult(){return _t(this,W)}trackResult(t,e){const n={};return Object.keys(t).forEach((r=>{Object.defineProperty(n,r,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(r),null==e||e(r),t[r])})})),n}trackProp(t){_t(this,Z).add(t)}getCurrentQuery(){return _t(this,N)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const e=_t(this,B).defaultQueryOptions(t),n=_t(this,B).getQueryCache().build(_t(this,B),e);return n.isFetchingOptimistic=!0,n.fetch().then((()=>this.createResult(n,e)))}fetch(t){return kt(this,J,tt).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then((()=>(this.updateResult(),_t(this,W))))}createResult(t,e){var n;const r=_t(this,N),i=this.options,o=_t(this,W),s=_t(this,H),a=_t(this,$),l=t!==r?t.state:_t(this,U),{state:u}=t;let c,d={...u},h=!1;if(e._optimisticResults){const n=this.hasListeners(),o=!n&&ps(t,e),s=n&&ms(t,r,e,i);(o||s)&&(d={...d,...rs(u.data,t.options)}),"isRestoring"===e._optimisticResults&&(d.fetchStatus="idle")}let{error:p,errorUpdatedAt:f,status:m}=d;if(e.select&&void 0!==d.data)if(o&&d.data===(null==s?void 0:s.data)&&e.select===_t(this,q))c=_t(this,K);else try{Et(this,q,e.select),c=e.select(d.data),c=Wo(null==o?void 0:o.data,c,e),Et(this,K,c),Et(this,z,null)}catch(x){Et(this,z,x)}else c=d.data;if(void 0!==e.placeholderData&&void 0===c&&"pending"===m){let t;if((null==o?void 0:o.isPlaceholderData)&&e.placeholderData===(null==a?void 0:a.placeholderData))t=o.data;else if(t="function"==typeof e.placeholderData?e.placeholderData(null==(n=_t(this,G))?void 0:n.state.data,_t(this,G)):e.placeholderData,e.select&&void 0!==t)try{t=e.select(t),Et(this,z,null)}catch(x){Et(this,z,x)}void 0!==t&&(m="success",c=Wo(null==o?void 0:o.data,t,e),h=!0)}_t(this,z)&&(p=_t(this,z),c=_t(this,K),f=Date.now(),m="error");const v="fetching"===d.fetchStatus,g="pending"===m,y="error"===m,b=g&&v,w=void 0!==c;return{status:m,fetchStatus:d.fetchStatus,isPending:g,isSuccess:"success"===m,isError:y,isInitialLoading:b,isLoading:b,data:c,dataUpdatedAt:d.dataUpdatedAt,error:p,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:v,isRefetching:v&&!g,isLoadingError:y&&!w,isPaused:"paused"===d.fetchStatus,isPlaceholderData:h,isRefetchError:y&&w,isStale:vs(t,e),refetch:this.refetch}}updateResult(t){const e=_t(this,W),n=this.createResult(_t(this,N),this.options);if(Et(this,H,_t(this,N).state),Et(this,$,this.options),void 0!==_t(this,H).data&&Et(this,G,_t(this,N)),Io(n,e))return;Et(this,W,n);const r={};!1!==(null==t?void 0:t.listeners)&&(()=>{if(!e)return!0;const{notifyOnChangeProps:t}=this.options,n="function"==typeof t?t():t;if("all"===n||!n&&!_t(this,Z).size)return!0;const r=new Set(n??_t(this,Z));return this.options.throwOnError&&r.add("error"),Object.keys(_t(this,W)).some((t=>{const n=t;return _t(this,W)[n]!==e[n]&&r.has(n)}))})()&&(r.listeners=!0),kt(this,J,lt).call(this,{...r,...t})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&kt(this,J,it).call(this)}},B=new WeakMap,N=new WeakMap,U=new WeakMap,W=new WeakMap,H=new WeakMap,$=new WeakMap,z=new WeakMap,q=new WeakMap,K=new WeakMap,G=new WeakMap,Y=new WeakMap,Q=new WeakMap,X=new WeakMap,Z=new WeakMap,J=new WeakSet,tt=function(t){kt(this,J,at).call(this);let e=_t(this,N).fetch(this.options,t);return(null==t?void 0:t.throwOnError)||(e=e.catch(To)),e},et=function(){kt(this,J,ot).call(this);const t=Ro(this.options.staleTime,_t(this,N));if(Po||_t(this,W).isStale||!Co(t))return;const e=Ao(_t(this,W).dataUpdatedAt,t);Et(this,Y,setTimeout((()=>{_t(this,W).isStale||this.updateResult()}),e+1))},nt=function(){return("function"==typeof this.options.refetchInterval?this.options.refetchInterval(_t(this,N)):this.options.refetchInterval)??!1},rt=function(t){kt(this,J,st).call(this),Et(this,X,t),!Po&&!1!==Oo(this.options.enabled,_t(this,N))&&Co(_t(this,X))&&0!==_t(this,X)&&Et(this,Q,setInterval((()=>{(this.options.refetchIntervalInBackground||Ko.isFocused())&&kt(this,J,tt).call(this)}),_t(this,X)))},it=function(){kt(this,J,et).call(this),kt(this,J,rt).call(this,kt(this,J,nt).call(this))},ot=function(){_t(this,Y)&&(clearTimeout(_t(this,Y)),Et(this,Y,void 0))},st=function(){_t(this,Q)&&(clearInterval(_t(this,Q)),Et(this,Q,void 0))},at=function(){const t=_t(this,B).getQueryCache().build(_t(this,B),this.options);if(t===_t(this,N))return;const e=_t(this,N);Et(this,N,t),Et(this,U,t.state),this.hasListeners()&&(null==e||e.removeObserver(this),t.addObserver(this))},lt=function(t){ts.batch((()=>{t.listeners&&this.listeners.forEach((t=>{t(_t(this,W))})),_t(this,B).getQueryCache().notify({query:_t(this,N),type:"observerResultsUpdated"})}))},ut);function ps(t,e){return function(t,e){return!1!==Oo(e.enabled,t)&&void 0===t.state.data&&!("error"===t.state.status&&!1===e.retryOnMount)}(t,e)||void 0!==t.state.data&&fs(t,e,e.refetchOnMount)}function fs(t,e,n){if(!1!==Oo(e.enabled,t)){const r="function"==typeof n?n(t):n;return"always"===r||!1!==r&&vs(t,e)}return!1}function ms(t,e,n,r){return(t!==e||!1===Oo(r.enabled,t))&&(!n.suspense||"error"!==t.state.status)&&vs(t,n)}function vs(t,e){return!1!==Oo(e.enabled,t)&&t.isStaleByTime(Ro(e.staleTime,t))}var gs=(gt=class extends ko{constructor(t,e){super(),St(this,ft),St(this,ct),St(this,dt),St(this,ht),St(this,pt),Et(this,ct,t),this.setOptions(e),this.bindMethods(),kt(this,ft,mt).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(t){var e;const n=this.options;this.options=_t(this,ct).defaultMutationOptions(t),Io(this.options,n)||_t(this,ct).getMutationCache().notify({type:"observerOptionsUpdated",mutation:_t(this,ht),observer:this}),(null==n?void 0:n.mutationKey)&&this.options.mutationKey&&Do(n.mutationKey)!==Do(this.options.mutationKey)?this.reset():"pending"===(null==(e=_t(this,ht))?void 0:e.state.status)&&_t(this,ht).setOptions(this.options)}onUnsubscribe(){var t;this.hasListeners()||null==(t=_t(this,ht))||t.removeObserver(this)}onMutationUpdate(t){kt(this,ft,mt).call(this),kt(this,ft,vt).call(this,t)}getCurrentResult(){return _t(this,dt)}reset(){var t;null==(t=_t(this,ht))||t.removeObserver(this),Et(this,ht,void 0),kt(this,ft,mt).call(this),kt(this,ft,vt).call(this)}mutate(t,e){var n;return Et(this,pt,e),null==(n=_t(this,ht))||n.removeObserver(this),Et(this,ht,_t(this,ct).getMutationCache().build(_t(this,ct),this.options)),_t(this,ht).addObserver(this),_t(this,ht).execute(t)}},ct=new WeakMap,dt=new WeakMap,ht=new WeakMap,pt=new WeakMap,ft=new WeakSet,mt=function(){var t;const e=(null==(t=_t(this,ht))?void 0:t.state)??{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0};Et(this,dt,{...e,isPending:"pending"===e.status,isSuccess:"success"===e.status,isError:"error"===e.status,isIdle:"idle"===e.status,mutate:this.mutate,reset:this.reset})},vt=function(t){ts.batch((()=>{var e,n,r,i,o,s,a,l;if(_t(this,pt)&&this.hasListeners()){const u=_t(this,dt).variables,c=_t(this,dt).context;"success"===(null==t?void 0:t.type)?(null==(n=(e=_t(this,pt)).onSuccess)||n.call(e,t.data,u,c),null==(i=(r=_t(this,pt)).onSettled)||i.call(r,t.data,null,u,c)):"error"===(null==t?void 0:t.type)&&(null==(s=(o=_t(this,pt)).onError)||s.call(o,t.error,u,c),null==(l=(a=_t(this,pt)).onSettled)||l.call(a,void 0,t.error,u,c))}this.listeners.forEach((t=>{t(_t(this,dt))}))}))},gt),ys=fe(void 0),bs=t=>{const e=Gn(ys);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},ws=({client:t,children:e})=>(Wn((()=>(t.mount(),()=>{t.unmount()})),[t]),ho(ys.Provider,{value:t,children:e})),xs=fe(!1),_s=()=>Gn(xs);xs.Provider;var Ss=fe(function(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}()),Es=()=>Gn(Ss);function ks(t,e){return"function"==typeof t?t(...e):!!t}function Ps(){}var Ts=(t,e)=>{(t.suspense||t.throwOnError)&&(e.isReset()||(t.retryOnMount=!1))},Cs=t=>{Wn((()=>{t.clearReset()}),[t])},As=({result:t,errorResetBoundary:e,throwOnError:n,query:r})=>t.isError&&!e.isReset()&&!t.isFetching&&r&&ks(n,[t.error,r]),Rs=t=>{t.suspense&&("number"!=typeof t.staleTime&&(t.staleTime=1e3),"number"==typeof t.gcTime&&(t.gcTime=Math.max(t.gcTime,1e3)))},Os=(t,e)=>(null==t?void 0:t.suspense)&&e.isPending,Fs=(t,e,n)=>e.fetchOptimistic(t).catch((()=>{n.clearReset()}));function Ls(t,e){return function(t,e){var n,r,i,o;const s=bs(),a=_s(),l=Es(),u=s.defaultQueryOptions(t);null==(r=null==(n=s.getDefaultOptions().queries)?void 0:n._experimental_beforeQuery)||r.call(n,u),u._optimisticResults=a?"isRestoring":"optimistic",Rs(u),Ts(u,l),Cs(l);const[c]=Nn((()=>new e(s,u))),d=c.getOptimisticResult(u);if(ii(Kn((t=>{const e=a?()=>{}:c.subscribe(ts.batchCalls(t));return c.updateResult(),e}),[c,a]),(()=>c.getCurrentResult())),Wn((()=>{c.setOptions(u,{listeners:!1})}),[u,c]),Os(u,d))throw Fs(u,c,l);if(As({result:d,errorResetBoundary:l,throwOnError:u.throwOnError,query:s.getQueryCache().get(u.queryHash)}))throw d.error;return null==(o=null==(i=s.getDefaultOptions().queries)?void 0:i._experimental_afterQuery)||o.call(i,u,d),u.notifyOnChangeProps?d:c.trackResult(d)}(t,hs)}var Ms=/^((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|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)-.*))$/,Ds=gn((function(t){return Ms.test(t)||111===t.charCodeAt(0)&&110===t.charCodeAt(1)&&t.charCodeAt(2)<91})),Vs=function(t){return"theme"!==t},js=function(t){return"string"==typeof t&&t.charCodeAt(0)>96?Ds:Vs},Is=function(t,e,n){var r;if(e){var i=e.shouldForwardProp;r=t.__emotion_forwardProp&&i?function(e){return t.__emotion_forwardProp(e)&&i(e)}:i}return"function"!=typeof r&&n&&(r=t.__emotion_forwardProp),r},Bs=function(t){var e=t.cache,n=t.serialized,r=t.isStringTag;return Di(e,n,r),Xi((function(){return Vi(e,n,r)})),null},Ns=function t(e,n){var r,i,o=e.__emotion_real===e,s=o&&e.__emotion_base||e;void 0!==n&&(r=n.label,i=n.target);var a=Is(e,n,o),l=a||js(s),u=!l("as");return function(){var c=arguments,d=o&&void 0!==e.__emotion_styles?e.__emotion_styles.slice(0):[];if(void 0!==r&&d.push("label:"+r+";"),null==c[0]||void 0===c[0].raw)d.push.apply(d,c);else{d.push(c[0][0]);for(var h=c.length,p=1;p<h;p++)d.push(c[p],c[0][p])}var f=eo((function(t,e,n){var r=u&&t.as||s,o="",c=[],h=t;if(null==t.theme){for(var p in h={},t)h[p]=t[p];h.theme=Gn(no)}"string"==typeof t.className?o=Mi(e.registered,c,t.className):null!=t.className&&(o=t.className+" ");var f=Yi(d.concat(c),e.registered,h);o+=e.key+"-"+f.name,void 0!==i&&(o+=" "+i);var m=u&&void 0===a?js(r):l,v={};for(var g in t)u&&"as"===g||m(g)&&(v[g]=t[g]);return v.className=o,n&&(v.ref=n),$t(Kt,null,$t(Bs,{cache:e,serialized:f,isStringTag:"string"==typeof r}),$t(r,v))}));return f.displayName=void 0!==r?r:"Styled("+("string"==typeof s?s:s.displayName||s.name||"Component")+")",f.defaultProps=e.defaultProps,f.__emotion_real=f,f.__emotion_base=s,f.__emotion_styles=d,f.__emotion_forwardProp=a,Object.defineProperty(f,"toString",{value:function(){return"."+i}}),f.withComponent=function(e,r){return t(e,li({},n,r,{shouldForwardProp:Is(f,r,!0)})).apply(void 0,d)},f}}.bind();["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(t){Ns[t]=Ns(t)}));const Us=Ns.td`
|
|
3
|
+
`}),io(Ji,{styles:so})]});let lo;class uo extends Error{constructor(t,e){super(t),__publicField(this,"response"),this.response=e}}const co=async(t,e,n,r)=>{await ho(t,e,n,r,!0)},ho=async(t,e,n,r,i)=>{const o=await fetch(t,{method:n,body:r?JSON.stringify(r):void 0,headers:{"content-type":"application/json","x-app-version":"0.3.1765",authorization:`Bearer ${e}`},signal:(null==AbortSignal?void 0:AbortSignal.timeout)&&AbortSignal.timeout(15e3)});if(!o.ok)throw new uo(`[API Error] Status: ${o.statusText}. Response: ${await o.text()}`,o);return i?{}:await o.json()},po=t=>async e=>{const n=new URL(`${t.url}/promoted-benefits/admin/v1.0/promotion`);return co(n,t.accessToken,"POST",e)},fo=t=>e=>async n=>{const r=new URL(`${t.url}/promoted-benefits/admin/v1.0/promotion/${e}`);return co(r,t.accessToken,"PUT",n)},mo=()=>{const t=Bn(lo);return{getAllPromotions:(e=t.backend,async()=>{const t=new URL(`${e.url}/promoted-benefits/admin/v1.0/promotion`);return ho(t,e.accessToken,"GET")}),createPromotion:po(t.backend),updatePromotion:fo(t.backend)};var e};var vo=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},go="undefined"==typeof window||"Deno"in globalThis;function yo(){}function _o(t){return"number"==typeof t&&t>=0&&t!==1/0}function bo(t,e){return Math.max(t+(e||0)-Date.now(),0)}function wo(t,e){return"function"==typeof t?t(e):t}function xo(t,e){return"function"==typeof t?t(e):t}function So(t,e){const{type:n="all",exact:r,fetchStatus:i,predicate:o,queryKey:s,stale:a}=t;if(s)if(r){if(e.queryHash!==ko(s,e.options))return!1}else if(!To(e.queryKey,s))return!1;if("all"!==n){const t=e.isActive();if("active"===n&&!t)return!1;if("inactive"===n&&t)return!1}return("boolean"!=typeof a||e.isStale()===a)&&((!i||i===e.state.fetchStatus)&&!(o&&!o(e)))}function Eo(t,e){const{exact:n,status:r,predicate:i,mutationKey:o}=t;if(o){if(!e.options.mutationKey)return!1;if(n){if(Po(e.options.mutationKey)!==Po(o))return!1}else if(!To(e.options.mutationKey,o))return!1}return(!r||e.state.status===r)&&!(i&&!i(e))}function ko(t,e){return((null==e?void 0:e.queryKeyHashFn)||Po)(t)}function Po(t){return JSON.stringify(t,((t,e)=>Oo(e)?Object.keys(e).sort().reduce(((t,n)=>(t[n]=e[n],t)),{}):e))}function To(t,e){return t===e||typeof t==typeof e&&(!(!t||!e||"object"!=typeof t||"object"!=typeof e)&&!Object.keys(e).some((n=>!To(t[n],e[n]))))}function Ao(t,e){if(t===e)return t;const n=Ro(t)&&Ro(e);if(n||Oo(t)&&Oo(e)){const r=n?t:Object.keys(t),i=r.length,o=n?e:Object.keys(e),s=o.length,a=n?[]:{};let l=0;for(let u=0;u<s;u++){const i=n?u:o[u];(!n&&r.includes(i)||n)&&void 0===t[i]&&void 0===e[i]?(a[i]=void 0,l++):(a[i]=Ao(t[i],e[i]),a[i]===t[i]&&void 0!==t[i]&&l++)}return i===s&&l===i?t:a}return e}function Co(t,e){if(!e||Object.keys(t).length!==Object.keys(e).length)return!1;for(const n in t)if(t[n]!==e[n])return!1;return!0}function Ro(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function Oo(t){if(!Mo(t))return!1;const e=t.constructor;if(void 0===e)return!0;const n=e.prototype;return!!Mo(n)&&(!!n.hasOwnProperty("isPrototypeOf")&&Object.getPrototypeOf(t)===Object.prototype)}function Mo(t){return"[object Object]"===Object.prototype.toString.call(t)}function Fo(t,e,n){return"function"==typeof n.structuralSharing?n.structuralSharing(t,e):!1!==n.structuralSharing?Ao(t,e):e}function Lo(t,e,n=0){const r=[...t,e];return n&&r.length>n?r.slice(1):r}function Do(t,e,n=0){const r=[e,...t];return n&&r.length>n?r.slice(0,-1):r}var Vo=Symbol();function jo(t,e){return!t.queryFn&&(null==e?void 0:e.initialPromise)?()=>e.initialPromise:t.queryFn&&t.queryFn!==Vo?t.queryFn:()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`))}var Io=new(r=class extends vo{constructor(){super(),__privateAdd(this,t),__privateAdd(this,e),__privateAdd(this,n),__privateSet(this,n,(t=>{if(!go&&window.addEventListener){const e=()=>t();return window.addEventListener("visibilitychange",e,!1),()=>{window.removeEventListener("visibilitychange",e)}}}))}onSubscribe(){__privateGet(this,e)||this.setEventListener(__privateGet(this,n))}onUnsubscribe(){var t;this.hasListeners()||(null==(t=__privateGet(this,e))||t.call(this),__privateSet(this,e,void 0))}setEventListener(t){var r;__privateSet(this,n,t),null==(r=__privateGet(this,e))||r.call(this),__privateSet(this,e,t((t=>{"boolean"==typeof t?this.setFocused(t):this.onFocus()})))}setFocused(e){__privateGet(this,t)!==e&&(__privateSet(this,t,e),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach((e=>{e(t)}))}isFocused(){var e;return"boolean"==typeof __privateGet(this,t)?__privateGet(this,t):"hidden"!==(null==(e=globalThis.document)?void 0:e.visibilityState)}},t=new WeakMap,e=new WeakMap,n=new WeakMap,r),Bo=new(a=class extends vo{constructor(){super(),__privateAdd(this,i,!0),__privateAdd(this,o),__privateAdd(this,s),__privateSet(this,s,(t=>{if(!go&&window.addEventListener){const e=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",e,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",e),window.removeEventListener("offline",n)}}}))}onSubscribe(){__privateGet(this,o)||this.setEventListener(__privateGet(this,s))}onUnsubscribe(){var t;this.hasListeners()||(null==(t=__privateGet(this,o))||t.call(this),__privateSet(this,o,void 0))}setEventListener(t){var e;__privateSet(this,s,t),null==(e=__privateGet(this,o))||e.call(this),__privateSet(this,o,t(this.setOnline.bind(this)))}setOnline(t){__privateGet(this,i)!==t&&(__privateSet(this,i,t),this.listeners.forEach((e=>{e(t)})))}isOnline(){return __privateGet(this,i)}},i=new WeakMap,o=new WeakMap,s=new WeakMap,a);function No(t){return Math.min(1e3*2**t,3e4)}function Go(t){return"online"!==(t??"online")||Bo.isOnline()}var Uo=class extends Error{constructor(t){super("CancelledError"),this.revert=null==t?void 0:t.revert,this.silent=null==t?void 0:t.silent}};function Wo(t){return t instanceof Uo}function Ho(t){let e,n,r,i=!1,o=0,s=!1;const a=new Promise(((t,e)=>{n=t,r=e})),l=()=>Io.isFocused()&&("always"===t.networkMode||Bo.isOnline())&&t.canRun(),u=()=>Go(t.networkMode)&&t.canRun(),c=r=>{var i;s||(s=!0,null==(i=t.onSuccess)||i.call(t,r),null==e||e(),n(r))},d=n=>{var i;s||(s=!0,null==(i=t.onError)||i.call(t,n),null==e||e(),r(n))},h=()=>new Promise((n=>{var r;e=t=>{(s||l())&&n(t)},null==(r=t.onPause)||r.call(t)})).then((()=>{var n;e=void 0,s||null==(n=t.onContinue)||n.call(t)})),p=()=>{if(s)return;let e;const n=0===o?t.initialPromise:void 0;try{e=n??t.fn()}catch(r){e=Promise.reject(r)}Promise.resolve(e).then(c).catch((e=>{var n;if(s)return;const r=t.retry??(go?0:3),a=t.retryDelay??No,u="function"==typeof a?a(o,e):a,c=!0===r||"number"==typeof r&&o<r||"function"==typeof r&&r(o,e);var f;!i&&c?(o++,null==(n=t.onFail)||n.call(t,o,e),(f=u,new Promise((t=>{setTimeout(t,f)}))).then((()=>l()?void 0:h())).then((()=>{i?d(e):p()}))):d(e)}))};return{promise:a,cancel:e=>{var n;s||(d(new Uo(e)),null==(n=t.abort)||n.call(t))},continue:()=>(null==e||e(),a),cancelRetry:()=>{i=!0},continueRetry:()=>{i=!1},canStart:u,start:()=>(u()?p():h().then(p),a)}}var $o=function(){let t=[],e=0,n=t=>{t()},r=t=>{t()},i=t=>setTimeout(t,0);const o=r=>{e?t.push(r):i((()=>{n(r)}))};return{batch:o=>{let s;e++;try{s=o()}finally{e--,e||(()=>{const e=t;t=[],e.length&&i((()=>{r((()=>{e.forEach((t=>{n(t)}))}))}))})()}return s},batchCalls:t=>(...e)=>{o((()=>{t(...e)}))},schedule:o,setNotifyFunction:t=>{n=t},setBatchNotifyFunction:t=>{r=t},setScheduler:t=>{i=t}}}(),zo=(u=class{constructor(){__privateAdd(this,l)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),_o(this.gcTime)&&__privateSet(this,l,setTimeout((()=>{this.optionalRemove()}),this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(go?1/0:3e5))}clearGcTimeout(){__privateGet(this,l)&&(clearTimeout(__privateGet(this,l)),__privateSet(this,l,void 0))}},l=new WeakMap,u),qo=(y=class extends zo{constructor(t){super(),__privateAdd(this,v),__privateAdd(this,c),__privateAdd(this,d),__privateAdd(this,h),__privateAdd(this,p),__privateAdd(this,f),__privateAdd(this,m),__privateSet(this,m,!1),__privateSet(this,f,t.defaultOptions),this.setOptions(t.options),this.observers=[],__privateSet(this,h,t.cache),this.queryKey=t.queryKey,this.queryHash=t.queryHash,__privateSet(this,c,function(t){const e="function"==typeof t.initialData?t.initialData():t.initialData,n=void 0!==e,r=n?"function"==typeof t.initialDataUpdatedAt?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:e,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=t.state??__privateGet(this,c),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return null==(t=__privateGet(this,p))?void 0:t.promise}setOptions(t){this.options={...__privateGet(this,f),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){this.observers.length||"idle"!==this.state.fetchStatus||__privateGet(this,h).remove(this)}setData(t,e){const n=Fo(this.state.data,t,this.options);return __privateMethod(this,v,g).call(this,{data:n,type:"success",dataUpdatedAt:null==e?void 0:e.updatedAt,manual:null==e?void 0:e.manual}),n}setState(t,e){__privateMethod(this,v,g).call(this,{type:"setState",state:t,setStateOptions:e})}cancel(t){var e,n;const r=null==(e=__privateGet(this,p))?void 0:e.promise;return null==(n=__privateGet(this,p))||n.cancel(t),r?r.then(yo).catch(yo):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(__privateGet(this,c))}isActive(){return this.observers.some((t=>!1!==xo(t.options.enabled,this)))}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return!!this.state.isInvalidated||(this.getObserversCount()>0?this.observers.some((t=>t.getCurrentResult().isStale)):void 0===this.state.data)}isStaleByTime(t=0){return this.state.isInvalidated||void 0===this.state.data||!bo(this.state.dataUpdatedAt,t)}onFocus(){var t;const e=this.observers.find((t=>t.shouldFetchOnWindowFocus()));null==e||e.refetch({cancelRefetch:!1}),null==(t=__privateGet(this,p))||t.continue()}onOnline(){var t;const e=this.observers.find((t=>t.shouldFetchOnReconnect()));null==e||e.refetch({cancelRefetch:!1}),null==(t=__privateGet(this,p))||t.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),__privateGet(this,h).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter((e=>e!==t)),this.observers.length||(__privateGet(this,p)&&(__privateGet(this,m)?__privateGet(this,p).cancel({revert:!0}):__privateGet(this,p).cancelRetry()),this.scheduleGc()),__privateGet(this,h).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||__privateMethod(this,v,g).call(this,{type:"invalidate"})}fetch(t,e){var n,r,i;if("idle"!==this.state.fetchStatus)if(void 0!==this.state.data&&(null==e?void 0:e.cancelRefetch))this.cancel({silent:!0});else if(__privateGet(this,p))return __privateGet(this,p).continueRetry(),__privateGet(this,p).promise;if(t&&this.setOptions(t),!this.options.queryFn){const t=this.observers.find((t=>t.options.queryFn));t&&this.setOptions(t.options)}const o=new AbortController,s=t=>{Object.defineProperty(t,"signal",{enumerable:!0,get:()=>(__privateSet(this,m,!0),o.signal)})},a={fetchOptions:e,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>{const t=jo(this.options,e),n={queryKey:this.queryKey,meta:this.meta};return s(n),__privateSet(this,m,!1),this.options.persister?this.options.persister(t,n,this):t(n)}};s(a),null==(n=this.options.behavior)||n.onFetch(a,this),__privateSet(this,d,this.state),"idle"!==this.state.fetchStatus&&this.state.fetchMeta===(null==(r=a.fetchOptions)?void 0:r.meta)||__privateMethod(this,v,g).call(this,{type:"fetch",meta:null==(i=a.fetchOptions)?void 0:i.meta});const l=t=>{var e,n,r,i;Wo(t)&&t.silent||__privateMethod(this,v,g).call(this,{type:"error",error:t}),Wo(t)||(null==(n=(e=__privateGet(this,h).config).onError)||n.call(e,t,this),null==(i=(r=__privateGet(this,h).config).onSettled)||i.call(r,this.state.data,t,this)),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return __privateSet(this,p,Ho({initialPromise:null==e?void 0:e.initialPromise,fn:a.fetchFn,abort:o.abort.bind(o),onSuccess:t=>{var e,n,r,i;if(void 0!==t){try{this.setData(t)}catch(o){return void l(o)}null==(n=(e=__privateGet(this,h).config).onSuccess)||n.call(e,t,this),null==(i=(r=__privateGet(this,h).config).onSettled)||i.call(r,t,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1}else l(new Error(`${this.queryHash} data is undefined`))},onError:l,onFail:(t,e)=>{__privateMethod(this,v,g).call(this,{type:"failed",failureCount:t,error:e})},onPause:()=>{__privateMethod(this,v,g).call(this,{type:"pause"})},onContinue:()=>{__privateMethod(this,v,g).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),__privateGet(this,p).start()}},c=new WeakMap,d=new WeakMap,h=new WeakMap,p=new WeakMap,f=new WeakMap,m=new WeakMap,v=new WeakSet,g=function(t){this.state=(e=>{switch(t.type){case"failed":return{...e,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...e,fetchStatus:"paused"};case"continue":return{...e,fetchStatus:"fetching"};case"fetch":return{...e,...Ko(e.data,this.options),fetchMeta:t.meta??null};case"success":return{...e,data:t.data,dataUpdateCount:e.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const n=t.error;return Wo(n)&&n.revert&&__privateGet(this,d)?{...__privateGet(this,d),fetchStatus:"idle"}:{...e,error:n,errorUpdateCount:e.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:e.fetchFailureCount+1,fetchFailureReason:n,fetchStatus:"idle",status:"error"};case"invalidate":return{...e,isInvalidated:!0};case"setState":return{...e,...t.state}}})(this.state),$o.batch((()=>{this.observers.forEach((t=>{t.onQueryUpdate()})),__privateGet(this,h).notify({query:this,type:"updated",action:t})}))},y);function Ko(t,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Go(e.networkMode)?"fetching":"paused",...void 0===t&&{error:null,status:"pending"}}}var Yo=(b=class extends vo{constructor(t={}){super(),__privateAdd(this,_),this.config=t,__privateSet(this,_,new Map)}build(t,e,n){const r=e.queryKey,i=e.queryHash??ko(r,e);let o=this.get(i);return o||(o=new qo({cache:this,queryKey:r,queryHash:i,options:t.defaultQueryOptions(e),state:n,defaultOptions:t.getQueryDefaults(r)}),this.add(o)),o}add(t){__privateGet(this,_).has(t.queryHash)||(__privateGet(this,_).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const e=__privateGet(this,_).get(t.queryHash);e&&(t.destroy(),e===t&&__privateGet(this,_).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){$o.batch((()=>{this.getAll().forEach((t=>{this.remove(t)}))}))}get(t){return __privateGet(this,_).get(t)}getAll(){return[...__privateGet(this,_).values()]}find(t){const e={exact:!0,...t};return this.getAll().find((t=>So(e,t)))}findAll(t={}){const e=this.getAll();return Object.keys(t).length>0?e.filter((e=>So(t,e))):e}notify(t){$o.batch((()=>{this.listeners.forEach((e=>{e(t)}))}))}onFocus(){$o.batch((()=>{this.getAll().forEach((t=>{t.onFocus()}))}))}onOnline(){$o.batch((()=>{this.getAll().forEach((t=>{t.onOnline()}))}))}},_=new WeakMap,b),Qo=(P=class extends zo{constructor(t){super(),__privateAdd(this,E),__privateAdd(this,w),__privateAdd(this,x),__privateAdd(this,S),this.mutationId=t.mutationId,__privateSet(this,x,t.mutationCache),__privateSet(this,w,[]),this.state=t.state||{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0},this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){__privateGet(this,w).includes(t)||(__privateGet(this,w).push(t),this.clearGcTimeout(),__privateGet(this,x).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){__privateSet(this,w,__privateGet(this,w).filter((e=>e!==t))),this.scheduleGc(),__privateGet(this,x).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){__privateGet(this,w).length||("pending"===this.state.status?this.scheduleGc():__privateGet(this,x).remove(this))}continue(){var t;return(null==(t=__privateGet(this,S))?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var e,n,r,i,o,s,a,l,u,c,d,h,p,f,m,v,g,y,_,b;__privateSet(this,S,Ho({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(t,e)=>{__privateMethod(this,E,k).call(this,{type:"failed",failureCount:t,error:e})},onPause:()=>{__privateMethod(this,E,k).call(this,{type:"pause"})},onContinue:()=>{__privateMethod(this,E,k).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>__privateGet(this,x).canRun(this)}));const w="pending"===this.state.status,P=!__privateGet(this,S).canStart();try{if(!w){__privateMethod(this,E,k).call(this,{type:"pending",variables:t,isPaused:P}),await(null==(n=(e=__privateGet(this,x).config).onMutate)?void 0:n.call(e,t,this));const o=await(null==(i=(r=this.options).onMutate)?void 0:i.call(r,t));o!==this.state.context&&__privateMethod(this,E,k).call(this,{type:"pending",context:o,variables:t,isPaused:P})}const p=await __privateGet(this,S).start();return await(null==(s=(o=__privateGet(this,x).config).onSuccess)?void 0:s.call(o,p,t,this.state.context,this)),await(null==(l=(a=this.options).onSuccess)?void 0:l.call(a,p,t,this.state.context)),await(null==(c=(u=__privateGet(this,x).config).onSettled)?void 0:c.call(u,p,null,this.state.variables,this.state.context,this)),await(null==(h=(d=this.options).onSettled)?void 0:h.call(d,p,null,t,this.state.context)),__privateMethod(this,E,k).call(this,{type:"success",data:p}),p}catch(T){try{throw await(null==(f=(p=__privateGet(this,x).config).onError)?void 0:f.call(p,T,t,this.state.context,this)),await(null==(v=(m=this.options).onError)?void 0:v.call(m,T,t,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==(b=(_=this.options).onSettled)?void 0:b.call(_,void 0,T,t,this.state.context)),T}finally{__privateMethod(this,E,k).call(this,{type:"error",error:T})}}finally{__privateGet(this,x).runNext(this)}}},w=new WeakMap,x=new WeakMap,S=new WeakMap,E=new WeakSet,k=function(t){this.state=(e=>{switch(t.type){case"failed":return{...e,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...e,isPaused:!0};case"continue":return{...e,isPaused:!1};case"pending":return{...e,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...e,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...e,data:void 0,error:t.error,failureCount:e.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}})(this.state),$o.batch((()=>{__privateGet(this,w).forEach((e=>{e.onMutationUpdate(t)})),__privateGet(this,x).notify({mutation:this,type:"updated",action:t})}))},P);var Xo=(C=class extends vo{constructor(t={}){super(),__privateAdd(this,T),__privateAdd(this,A),this.config=t,__privateSet(this,T,new Map),__privateSet(this,A,Date.now())}build(t,e,n){const r=new Qo({mutationCache:this,mutationId:++__privateWrapper(this,A)._,options:t.defaultMutationOptions(e),state:n});return this.add(r),r}add(t){const e=Zo(t),n=__privateGet(this,T).get(e)??[];n.push(t),__privateGet(this,T).set(e,n),this.notify({type:"added",mutation:t})}remove(t){var e;const n=Zo(t);if(__privateGet(this,T).has(n)){const r=null==(e=__privateGet(this,T).get(n))?void 0:e.filter((e=>e!==t));r&&(0===r.length?__privateGet(this,T).delete(n):__privateGet(this,T).set(n,r))}this.notify({type:"removed",mutation:t})}canRun(t){var e;const n=null==(e=__privateGet(this,T).get(Zo(t)))?void 0:e.find((t=>"pending"===t.state.status));return!n||n===t}runNext(t){var e;const n=null==(e=__privateGet(this,T).get(Zo(t)))?void 0:e.find((e=>e!==t&&e.state.isPaused));return(null==n?void 0:n.continue())??Promise.resolve()}clear(){$o.batch((()=>{this.getAll().forEach((t=>{this.remove(t)}))}))}getAll(){return[...__privateGet(this,T).values()].flat()}find(t){const e={exact:!0,...t};return this.getAll().find((t=>Eo(e,t)))}findAll(t={}){return this.getAll().filter((e=>Eo(t,e)))}notify(t){$o.batch((()=>{this.listeners.forEach((e=>{e(t)}))}))}resumePausedMutations(){const t=this.getAll().filter((t=>t.state.isPaused));return $o.batch((()=>Promise.all(t.map((t=>t.continue().catch(yo))))))}},T=new WeakMap,A=new WeakMap,C);function Zo(t){var e;return(null==(e=t.options.scope)?void 0:e.id)??String(t.mutationId)}function Jo(t){return{onFetch:(e,n)=>{var r,i,o,s,a;const l=e.options,u=null==(o=null==(i=null==(r=e.fetchOptions)?void 0:r.meta)?void 0:i.fetchMore)?void 0:o.direction,c=(null==(s=e.state.data)?void 0:s.pages)||[],d=(null==(a=e.state.data)?void 0:a.pageParams)||[];let h={pages:[],pageParams:[]},p=0;const f=async()=>{let n=!1;const r=jo(e.options,e.fetchOptions),i=async(t,i,o)=>{if(n)return Promise.reject();if(null==i&&t.pages.length)return Promise.resolve(t);const s={queryKey:e.queryKey,pageParam:i,direction:o?"backward":"forward",meta:e.options.meta};var a;a=s,Object.defineProperty(a,"signal",{enumerable:!0,get:()=>(e.signal.aborted?n=!0:e.signal.addEventListener("abort",(()=>{n=!0})),e.signal)});const l=await r(s),{maxPages:u}=e.options,c=o?Do:Lo;return{pages:c(t.pages,l,u),pageParams:c(t.pageParams,i,u)}};if(u&&c.length){const t="backward"===u,e={pages:c,pageParams:d},n=(t?es:ts)(l,e);h=await i(e,n,t)}else{const e=t??c.length;do{const t=0===p?d[0]??l.initialPageParam:ts(l,h);if(p>0&&null==t)break;h=await i(h,t),p++}while(p<e)}return h};e.options.persister?e.fetchFn=()=>{var t,r;return null==(r=(t=e.options).persister)?void 0:r.call(t,f,{queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},n)}:e.fetchFn=f}}}function ts(t,{pages:e,pageParams:n}){const r=e.length-1;return e.length>0?t.getNextPageParam(e[r],e,n[r],n):void 0}function es(t,{pages:e,pageParams:n}){var r;return e.length>0?null==(r=t.getPreviousPageParam)?void 0:r.call(t,e[0],e,n[0],n):void 0}var ns=(I=class{constructor(t={}){__privateAdd(this,R),__privateAdd(this,O),__privateAdd(this,M),__privateAdd(this,F),__privateAdd(this,L),__privateAdd(this,D),__privateAdd(this,V),__privateAdd(this,j),__privateSet(this,R,t.queryCache||new Yo),__privateSet(this,O,t.mutationCache||new Xo),__privateSet(this,M,t.defaultOptions||{}),__privateSet(this,F,new Map),__privateSet(this,L,new Map),__privateSet(this,D,0)}mount(){__privateWrapper(this,D)._++,1===__privateGet(this,D)&&(__privateSet(this,V,Io.subscribe((async t=>{t&&(await this.resumePausedMutations(),__privateGet(this,R).onFocus())}))),__privateSet(this,j,Bo.subscribe((async t=>{t&&(await this.resumePausedMutations(),__privateGet(this,R).onOnline())}))))}unmount(){var t,e;__privateWrapper(this,D)._--,0===__privateGet(this,D)&&(null==(t=__privateGet(this,V))||t.call(this),__privateSet(this,V,void 0),null==(e=__privateGet(this,j))||e.call(this),__privateSet(this,j,void 0))}isFetching(t){return __privateGet(this,R).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return __privateGet(this,O).findAll({...t,status:"pending"}).length}getQueryData(t){var e;const n=this.defaultQueryOptions({queryKey:t});return null==(e=__privateGet(this,R).get(n.queryHash))?void 0:e.state.data}ensureQueryData(t){const e=this.getQueryData(t.queryKey);if(void 0===e)return this.fetchQuery(t);{const n=this.defaultQueryOptions(t),r=__privateGet(this,R).build(this,n);return t.revalidateIfStale&&r.isStaleByTime(wo(n.staleTime,r))&&this.prefetchQuery(n),Promise.resolve(e)}}getQueriesData(t){return __privateGet(this,R).findAll(t).map((({queryKey:t,state:e})=>[t,e.data]))}setQueryData(t,e,n){const r=this.defaultQueryOptions({queryKey:t}),i=__privateGet(this,R).get(r.queryHash),o=function(t,e){return"function"==typeof t?t(e):t}(e,null==i?void 0:i.state.data);if(void 0!==o)return __privateGet(this,R).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(t,e,n){return $o.batch((()=>__privateGet(this,R).findAll(t).map((({queryKey:t})=>[t,this.setQueryData(t,e,n)]))))}getQueryState(t){var e;const n=this.defaultQueryOptions({queryKey:t});return null==(e=__privateGet(this,R).get(n.queryHash))?void 0:e.state}removeQueries(t){const e=__privateGet(this,R);$o.batch((()=>{e.findAll(t).forEach((t=>{e.remove(t)}))}))}resetQueries(t,e){const n=__privateGet(this,R),r={type:"active",...t};return $o.batch((()=>(n.findAll(t).forEach((t=>{t.reset()})),this.refetchQueries(r,e))))}cancelQueries(t={},e={}){const n={revert:!0,...e},r=$o.batch((()=>__privateGet(this,R).findAll(t).map((t=>t.cancel(n)))));return Promise.all(r).then(yo).catch(yo)}invalidateQueries(t={},e={}){return $o.batch((()=>{if(__privateGet(this,R).findAll(t).forEach((t=>{t.invalidate()})),"none"===t.refetchType)return Promise.resolve();const n={...t,type:t.refetchType??t.type??"active"};return this.refetchQueries(n,e)}))}refetchQueries(t={},e){const n={...e,cancelRefetch:(null==e?void 0:e.cancelRefetch)??!0},r=$o.batch((()=>__privateGet(this,R).findAll(t).filter((t=>!t.isDisabled())).map((t=>{let e=t.fetch(void 0,n);return n.throwOnError||(e=e.catch(yo)),"paused"===t.state.fetchStatus?Promise.resolve():e}))));return Promise.all(r).then(yo)}fetchQuery(t){const e=this.defaultQueryOptions(t);void 0===e.retry&&(e.retry=!1);const n=__privateGet(this,R).build(this,e);return n.isStaleByTime(wo(e.staleTime,n))?n.fetch(e):Promise.resolve(n.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(yo).catch(yo)}fetchInfiniteQuery(t){return t.behavior=Jo(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(yo).catch(yo)}ensureInfiniteQueryData(t){return t.behavior=Jo(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return Bo.isOnline()?__privateGet(this,O).resumePausedMutations():Promise.resolve()}getQueryCache(){return __privateGet(this,R)}getMutationCache(){return __privateGet(this,O)}getDefaultOptions(){return __privateGet(this,M)}setDefaultOptions(t){__privateSet(this,M,t)}setQueryDefaults(t,e){__privateGet(this,F).set(Po(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){const e=[...__privateGet(this,F).values()];let n={};return e.forEach((e=>{To(t,e.queryKey)&&(n={...n,...e.defaultOptions})})),n}setMutationDefaults(t,e){__privateGet(this,L).set(Po(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){const e=[...__privateGet(this,L).values()];let n={};return e.forEach((e=>{To(t,e.mutationKey)&&(n={...n,...e.defaultOptions})})),n}defaultQueryOptions(t){if(t._defaulted)return t;const e={...__privateGet(this,M).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=ko(e.queryKey,e)),void 0===e.refetchOnReconnect&&(e.refetchOnReconnect="always"!==e.networkMode),void 0===e.throwOnError&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),!0!==e.enabled&&e.queryFn===Vo&&(e.enabled=!1),e}defaultMutationOptions(t){return(null==t?void 0:t._defaulted)?t:{...__privateGet(this,M).mutations,...(null==t?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){__privateGet(this,R).clear(),__privateGet(this,O).clear()}},R=new WeakMap,O=new WeakMap,M=new WeakMap,F=new WeakMap,L=new WeakMap,D=new WeakMap,V=new WeakMap,j=new WeakMap,I),rs=(ut=class extends vo{constructor(t,e){super(),__privateAdd(this,J),__privateAdd(this,B),__privateAdd(this,N),__privateAdd(this,G),__privateAdd(this,U),__privateAdd(this,W),__privateAdd(this,H),__privateAdd(this,$),__privateAdd(this,z),__privateAdd(this,q),__privateAdd(this,K),__privateAdd(this,Y),__privateAdd(this,Q),__privateAdd(this,X),__privateAdd(this,Z,new Set),this.options=e,__privateSet(this,B,t),__privateSet(this,$,null),this.bindMethods(),this.setOptions(e)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(__privateGet(this,N).addObserver(this),is(__privateGet(this,N),this.options)?__privateMethod(this,J,tt).call(this):this.updateResult(),__privateMethod(this,J,it).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return os(__privateGet(this,N),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return os(__privateGet(this,N),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,__privateMethod(this,J,ot).call(this),__privateMethod(this,J,st).call(this),__privateGet(this,N).removeObserver(this)}setOptions(t,e){const n=this.options,r=__privateGet(this,N);if(this.options=__privateGet(this,B).defaultQueryOptions(t),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled&&"function"!=typeof this.options.enabled&&"boolean"!=typeof xo(this.options.enabled,__privateGet(this,N)))throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");__privateMethod(this,J,at).call(this),__privateGet(this,N).setOptions(this.options),n._defaulted&&!Co(this.options,n)&&__privateGet(this,B).getQueryCache().notify({type:"observerOptionsUpdated",query:__privateGet(this,N),observer:this});const i=this.hasListeners();i&&ss(__privateGet(this,N),r,this.options,n)&&__privateMethod(this,J,tt).call(this),this.updateResult(e),!i||__privateGet(this,N)===r&&xo(this.options.enabled,__privateGet(this,N))===xo(n.enabled,__privateGet(this,N))&&wo(this.options.staleTime,__privateGet(this,N))===wo(n.staleTime,__privateGet(this,N))||__privateMethod(this,J,et).call(this);const o=__privateMethod(this,J,nt).call(this);!i||__privateGet(this,N)===r&&xo(this.options.enabled,__privateGet(this,N))===xo(n.enabled,__privateGet(this,N))&&o===__privateGet(this,X)||__privateMethod(this,J,rt).call(this,o)}getOptimisticResult(t){const e=__privateGet(this,B).getQueryCache().build(__privateGet(this,B),t),n=this.createResult(e,t);return function(t,e){if(!Co(t.getCurrentResult(),e))return!0;return!1}(this,n)&&(__privateSet(this,U,n),__privateSet(this,H,this.options),__privateSet(this,W,__privateGet(this,N).state)),n}getCurrentResult(){return __privateGet(this,U)}trackResult(t,e){const n={};return Object.keys(t).forEach((r=>{Object.defineProperty(n,r,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(r),null==e||e(r),t[r])})})),n}trackProp(t){__privateGet(this,Z).add(t)}getCurrentQuery(){return __privateGet(this,N)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const e=__privateGet(this,B).defaultQueryOptions(t),n=__privateGet(this,B).getQueryCache().build(__privateGet(this,B),e);return n.isFetchingOptimistic=!0,n.fetch().then((()=>this.createResult(n,e)))}fetch(t){return __privateMethod(this,J,tt).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then((()=>(this.updateResult(),__privateGet(this,U))))}createResult(t,e){var n;const r=__privateGet(this,N),i=this.options,o=__privateGet(this,U),s=__privateGet(this,W),a=__privateGet(this,H),l=t!==r?t.state:__privateGet(this,G),{state:u}=t;let c,d={...u},h=!1;if(e._optimisticResults){const n=this.hasListeners(),o=!n&&is(t,e),s=n&&ss(t,r,e,i);(o||s)&&(d={...d,...Ko(u.data,t.options)}),"isRestoring"===e._optimisticResults&&(d.fetchStatus="idle")}let{error:p,errorUpdatedAt:f,status:m}=d;if(e.select&&void 0!==d.data)if(o&&d.data===(null==s?void 0:s.data)&&e.select===__privateGet(this,z))c=__privateGet(this,q);else try{__privateSet(this,z,e.select),c=e.select(d.data),c=Fo(null==o?void 0:o.data,c,e),__privateSet(this,q,c),__privateSet(this,$,null)}catch(w){__privateSet(this,$,w)}else c=d.data;if(void 0!==e.placeholderData&&void 0===c&&"pending"===m){let t;if((null==o?void 0:o.isPlaceholderData)&&e.placeholderData===(null==a?void 0:a.placeholderData))t=o.data;else if(t="function"==typeof e.placeholderData?e.placeholderData(null==(n=__privateGet(this,K))?void 0:n.state.data,__privateGet(this,K)):e.placeholderData,e.select&&void 0!==t)try{t=e.select(t),__privateSet(this,$,null)}catch(w){__privateSet(this,$,w)}void 0!==t&&(m="success",c=Fo(null==o?void 0:o.data,t,e),h=!0)}__privateGet(this,$)&&(p=__privateGet(this,$),c=__privateGet(this,q),f=Date.now(),m="error");const v="fetching"===d.fetchStatus,g="pending"===m,y="error"===m,_=g&&v,b=void 0!==c;return{status:m,fetchStatus:d.fetchStatus,isPending:g,isSuccess:"success"===m,isError:y,isInitialLoading:_,isLoading:_,data:c,dataUpdatedAt:d.dataUpdatedAt,error:p,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:v,isRefetching:v&&!g,isLoadingError:y&&!b,isPaused:"paused"===d.fetchStatus,isPlaceholderData:h,isRefetchError:y&&b,isStale:as(t,e),refetch:this.refetch}}updateResult(t){const e=__privateGet(this,U),n=this.createResult(__privateGet(this,N),this.options);if(__privateSet(this,W,__privateGet(this,N).state),__privateSet(this,H,this.options),void 0!==__privateGet(this,W).data&&__privateSet(this,K,__privateGet(this,N)),Co(n,e))return;__privateSet(this,U,n);const r={};!1!==(null==t?void 0:t.listeners)&&(()=>{if(!e)return!0;const{notifyOnChangeProps:t}=this.options,n="function"==typeof t?t():t;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((t=>{const n=t;return __privateGet(this,U)[n]!==e[n]&&r.has(n)}))})()&&(r.listeners=!0),__privateMethod(this,J,lt).call(this,{...r,...t})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&__privateMethod(this,J,it).call(this)}},B=new WeakMap,N=new WeakMap,G=new WeakMap,U=new WeakMap,W=new WeakMap,H=new WeakMap,$=new WeakMap,z=new WeakMap,q=new WeakMap,K=new WeakMap,Y=new WeakMap,Q=new WeakMap,X=new WeakMap,Z=new WeakMap,J=new WeakSet,tt=function(t){__privateMethod(this,J,at).call(this);let e=__privateGet(this,N).fetch(this.options,t);return(null==t?void 0:t.throwOnError)||(e=e.catch(yo)),e},et=function(){__privateMethod(this,J,ot).call(this);const t=wo(this.options.staleTime,__privateGet(this,N));if(go||__privateGet(this,U).isStale||!_o(t))return;const e=bo(__privateGet(this,U).dataUpdatedAt,t);__privateSet(this,Y,setTimeout((()=>{__privateGet(this,U).isStale||this.updateResult()}),e+1))},nt=function(){return("function"==typeof this.options.refetchInterval?this.options.refetchInterval(__privateGet(this,N)):this.options.refetchInterval)??!1},rt=function(t){__privateMethod(this,J,st).call(this),__privateSet(this,X,t),!go&&!1!==xo(this.options.enabled,__privateGet(this,N))&&_o(__privateGet(this,X))&&0!==__privateGet(this,X)&&__privateSet(this,Q,setInterval((()=>{(this.options.refetchIntervalInBackground||Io.isFocused())&&__privateMethod(this,J,tt).call(this)}),__privateGet(this,X)))},it=function(){__privateMethod(this,J,et).call(this),__privateMethod(this,J,rt).call(this,__privateMethod(this,J,nt).call(this))},ot=function(){__privateGet(this,Y)&&(clearTimeout(__privateGet(this,Y)),__privateSet(this,Y,void 0))},st=function(){__privateGet(this,Q)&&(clearInterval(__privateGet(this,Q)),__privateSet(this,Q,void 0))},at=function(){const t=__privateGet(this,B).getQueryCache().build(__privateGet(this,B),this.options);if(t===__privateGet(this,N))return;const e=__privateGet(this,N);__privateSet(this,N,t),__privateSet(this,G,t.state),this.hasListeners()&&(null==e||e.removeObserver(this),t.addObserver(this))},lt=function(t){$o.batch((()=>{t.listeners&&this.listeners.forEach((t=>{t(__privateGet(this,U))})),__privateGet(this,B).getQueryCache().notify({query:__privateGet(this,N),type:"observerResultsUpdated"})}))},ut);function is(t,e){return function(t,e){return!1!==xo(e.enabled,t)&&void 0===t.state.data&&!("error"===t.state.status&&!1===e.retryOnMount)}(t,e)||void 0!==t.state.data&&os(t,e,e.refetchOnMount)}function os(t,e,n){if(!1!==xo(e.enabled,t)){const r="function"==typeof n?n(t):n;return"always"===r||!1!==r&&as(t,e)}return!1}function ss(t,e,n,r){return(t!==e||!1===xo(r.enabled,t))&&(!n.suspense||"error"!==t.state.status)&&as(t,n)}function as(t,e){return!1!==xo(e.enabled,t)&&t.isStaleByTime(wo(e.staleTime,t))}var ls=(gt=class extends vo{constructor(t,e){super(),__privateAdd(this,ft),__privateAdd(this,ct),__privateAdd(this,dt),__privateAdd(this,ht),__privateAdd(this,pt),__privateSet(this,ct,t),this.setOptions(e),this.bindMethods(),__privateMethod(this,ft,mt).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(t){var e;const n=this.options;this.options=__privateGet(this,ct).defaultMutationOptions(t),Co(this.options,n)||__privateGet(this,ct).getMutationCache().notify({type:"observerOptionsUpdated",mutation:__privateGet(this,ht),observer:this}),(null==n?void 0:n.mutationKey)&&this.options.mutationKey&&Po(n.mutationKey)!==Po(this.options.mutationKey)?this.reset():"pending"===(null==(e=__privateGet(this,ht))?void 0:e.state.status)&&__privateGet(this,ht).setOptions(this.options)}onUnsubscribe(){var t;this.hasListeners()||null==(t=__privateGet(this,ht))||t.removeObserver(this)}onMutationUpdate(t){__privateMethod(this,ft,mt).call(this),__privateMethod(this,ft,vt).call(this,t)}getCurrentResult(){return __privateGet(this,dt)}reset(){var t;null==(t=__privateGet(this,ht))||t.removeObserver(this),__privateSet(this,ht,void 0),__privateMethod(this,ft,mt).call(this),__privateMethod(this,ft,vt).call(this)}mutate(t,e){var n;return __privateSet(this,pt,e),null==(n=__privateGet(this,ht))||n.removeObserver(this),__privateSet(this,ht,__privateGet(this,ct).getMutationCache().build(__privateGet(this,ct),this.options)),__privateGet(this,ht).addObserver(this),__privateGet(this,ht).execute(t)}},ct=new WeakMap,dt=new WeakMap,ht=new WeakMap,pt=new WeakMap,ft=new WeakSet,mt=function(){var t;const e=(null==(t=__privateGet(this,ht))?void 0:t.state)??{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0};__privateSet(this,dt,{...e,isPending:"pending"===e.status,isSuccess:"success"===e.status,isError:"error"===e.status,isIdle:"idle"===e.status,mutate:this.mutate,reset:this.reset})},vt=function(t){$o.batch((()=>{var e,n,r,i,o,s,a,l;if(__privateGet(this,pt)&&this.hasListeners()){const u=__privateGet(this,dt).variables,c=__privateGet(this,dt).context;"success"===(null==t?void 0:t.type)?(null==(n=(e=__privateGet(this,pt)).onSuccess)||n.call(e,t.data,u,c),null==(i=(r=__privateGet(this,pt)).onSettled)||i.call(r,t.data,null,u,c)):"error"===(null==t?void 0:t.type)&&(null==(s=(o=__privateGet(this,pt)).onError)||s.call(o,t.error,u,c),null==(l=(a=__privateGet(this,pt)).onSettled)||l.call(a,void 0,t.error,u,c))}this.listeners.forEach((t=>{t(__privateGet(this,dt))}))}))},gt),us=oe(void 0),cs=t=>{const e=Bn(us);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},ds=({client:t,children:e})=>(Fn((()=>(t.mount(),()=>{t.unmount()})),[t]),no(us.Provider,{value:t,children:e})),hs=oe(!1),ps=()=>Bn(hs);hs.Provider;var fs=oe(function(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}()),ms=()=>Bn(fs);function vs(t,e){return"function"==typeof t?t(...e):!!t}function gs(){}var ys=(t,e)=>{(t.suspense||t.throwOnError)&&(e.isReset()||(t.retryOnMount=!1))},_s=t=>{Fn((()=>{t.clearReset()}),[t])},bs=({result:t,errorResetBoundary:e,throwOnError:n,query:r})=>t.isError&&!e.isReset()&&!t.isFetching&&r&&vs(n,[t.error,r]),ws=t=>{t.suspense&&("number"!=typeof t.staleTime&&(t.staleTime=1e3),"number"==typeof t.gcTime&&(t.gcTime=Math.max(t.gcTime,1e3)))},xs=(t,e)=>(null==t?void 0:t.suspense)&&e.isPending,Ss=(t,e,n)=>e.fetchOptimistic(t).catch((()=>{n.clearReset()}));function Es(t,e){return function(t,e){var n,r,i,o;const s=cs(),a=ps(),l=ms(),u=s.defaultQueryOptions(t);null==(r=null==(n=s.getDefaultOptions().queries)?void 0:n._experimental_beforeQuery)||r.call(n,u),u._optimisticResults=a?"isRestoring":"optimistic",ws(u),ys(u,l),_s(l);const[c]=On((()=>new e(s,u))),d=c.getOptimisticResult(u);if(Yr(In((t=>{const e=a?()=>{}:c.subscribe($o.batchCalls(t));return c.updateResult(),e}),[c,a]),(()=>c.getCurrentResult())),Fn((()=>{c.setOptions(u,{listeners:!1})}),[u,c]),xs(u,d))throw Ss(u,c,l);if(bs({result:d,errorResetBoundary:l,throwOnError:u.throwOnError,query:s.getQueryCache().get(u.queryHash)}))throw d.error;return null==(o=null==(i=s.getDefaultOptions().queries)?void 0:i._experimental_afterQuery)||o.call(i,u,d),u.notifyOnChangeProps?d:c.trackResult(d)}(t,rs)}var ks=/^((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|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)-.*))$/,Ps=ln((function(t){return ks.test(t)||111===t.charCodeAt(0)&&110===t.charCodeAt(1)&&t.charCodeAt(2)<91})),Ts=function(t){return"theme"!==t},As=function(t){return"string"==typeof t&&t.charCodeAt(0)>96?Ps:Ts},Cs=function(t,e,n){var r;if(e){var i=e.shouldForwardProp;r=t.__emotion_forwardProp&&i?function(e){return t.__emotion_forwardProp(e)&&i(e)}:i}return"function"!=typeof r&&n&&(r=t.__emotion_forwardProp),r},Rs=function(t){var e=t.cache,n=t.serialized,r=t.isStringTag;return Pi(e,n,r),Ui((function(){return Ti(e,n,r)})),null},Os=function t(e,n){var r,i,o=e.__emotion_real===e,s=o&&e.__emotion_base||e;void 0!==n&&(r=n.label,i=n.target);var a=Cs(e,n,o),l=a||As(s),u=!l("as");return function(){var c=arguments,d=o&&void 0!==e.__emotion_styles?e.__emotion_styles.slice(0):[];if(void 0!==r&&d.push("label:"+r+";"),null==c[0]||void 0===c[0].raw)d.push.apply(d,c);else{d.push(c[0][0]);for(var h=c.length,p=1;p<h;p++)d.push(c[p],c[0][p])}var f=zi((function(t,e,n){var r=u&&t.as||s,o="",c=[],h=t;if(null==t.theme){for(var p in h={},t)h[p]=t[p];h.theme=Bn(qi)}"string"==typeof t.className?o=ki(e.registered,c,t.className):null!=t.className&&(o=t.className+" ");var f=Ni(d.concat(c),e.registered,h);o+=e.key+"-"+f.name,void 0!==i&&(o+=" "+i);var m=u&&void 0===a?As(r):l,v={};for(var g in t)u&&"as"===g||m(g)&&(v[g]=t[g]);return v.className=o,n&&(v.ref=n),Dt(It,null,Dt(Rs,{cache:e,serialized:f,isStringTag:"string"==typeof r}),Dt(r,v))}));return f.displayName=void 0!==r?r:"Styled("+("string"==typeof s?s:s.displayName||s.name||"Component")+")",f.defaultProps=e.defaultProps,f.__emotion_real=f,f.__emotion_base=s,f.__emotion_styles=d,f.__emotion_forwardProp=a,Object.defineProperty(f,"toString",{value:function(){return"."+i}}),f.withComponent=function(e,r){return t(e,Jr({},n,r,{shouldForwardProp:Cs(f,r,!0)})).apply(void 0,d)},f}}.bind();["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(t){Os[t]=Os(t)}));const Ms=Os.td`
|
|
4
4
|
${{whiteSpace:"nowrap",paddingTop:"1rem",paddingBottom:"1rem",paddingLeft:"1rem",paddingRight:"0.75rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"}}
|
|
5
|
-
`,
|
|
5
|
+
`,Fs=Os.td`
|
|
6
6
|
${{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))"}}
|
|
7
|
-
`,
|
|
7
|
+
`,Ls=Os.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"},(t=>t.className)),Ds=t=>{const e=new Date(t.value);return oo(Ms,{children:[e.toLocaleDateString(),io("br",{}),e.toLocaleTimeString()]})},Vs=(t,e)=>{var n;switch(null==e?void 0:e.kind){case"status":return io(Fs,{children:io(Ls,{className:null==(n=e.styleOverrides)?void 0:n[t],children:t})});case"date":return io(Ds,{value:t});default:return io(Ms,{children:t})}},js=t=>io(ro,{children:oo("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:[oo("div",{css:{"@media (min-width: 640px)":{display:"flex",alignItems:"center"}},children:[oo("div",{css:{"@media (min-width: 640px)":{flex:"1 1 auto"}},children:[io("h1",{css:{fontSize:"1rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:t.title}),io("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:t.subtitle})]}),io("div",{css:{marginTop:"1rem","@media (min-width: 640px)":{marginLeft:"4rem",marginTop:"0px",flex:"none"}},children:io("button",{type:"button",onClick:t.onAdd,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:t.addButtonText})})]}),io("div",{css:{marginTop:"2rem",display:"flow-root"},children:io("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:io("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:io("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:oo("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:[io("thead",{css:{"--tw-bg-opacity":"1",backgroundColor:"rgb(249 250 251 / var(--tw-bg-opacity))"},children:io("tr",{children:t.columns.map((t=>io("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:t.name},t.field)))})}),io("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:t.data.map(((e,n)=>io("tr",{css:{cursor:"pointer",":hover":{"--tw-bg-opacity":"1",backgroundColor:"rgb(243 244 246 / var(--tw-bg-opacity))"}},onClick:()=>t.onClick(e.id),children:t.columns.map(((t,r)=>io(It,{children:Vs(e[t.field],t.type)},`${e[t.field]}-${n}-${r}`)))},`${e[t.columns[0].field]}-${n}`)))})]})})})})})]})});
|
|
8
8
|
/**
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
function
|
|
9
|
+
* @remix-run/router v1.19.2
|
|
10
|
+
*
|
|
11
|
+
* Copyright (c) Remix Software Inc.
|
|
12
|
+
*
|
|
13
|
+
* This source code is licensed under the MIT license found in the
|
|
14
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
15
|
+
*
|
|
16
|
+
* @license MIT
|
|
17
|
+
*/
|
|
18
|
+
function Is(){return Is=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},Is.apply(this,arguments)}var Bs,Ns;(Ns=Bs||(Bs={})).Pop="POP",Ns.Push="PUSH",Ns.Replace="REPLACE";const Gs="popstate";function Us(t){return void 0===t&&(t={}),function(t,e,n,r){void 0===r&&(r={});let{window:i=document.defaultView,v5Compat:o=!1}=r,s=i.history,a=Bs.Pop,l=null,u=c();null==u&&(u=0,s.replaceState(Is({},s.state,{idx:u}),""));function c(){return(s.state||{idx:null}).idx}function d(){a=Bs.Pop;let t=c(),e=null==t?null:t-u;u=t,l&&l({action:a,location:m.location,delta:e})}function h(t,e){a=Bs.Push;let r=zs(m.location,t,e);n&&n(r,t),u=c()+1;let d=$s(r,u),h=m.createHref(r);try{s.pushState(d,"",h)}catch(p){if(p instanceof DOMException&&"DataCloneError"===p.name)throw p;i.location.assign(h)}o&&l&&l({action:a,location:m.location,delta:1})}function p(t,e){a=Bs.Replace;let r=zs(m.location,t,e);n&&n(r,t),u=c();let i=$s(r,u),d=m.createHref(r);s.replaceState(i,"",d),o&&l&&l({action:a,location:m.location,delta:0})}function f(t){let e="null"!==i.location.origin?i.location.origin:i.location.href,n="string"==typeof t?t:qs(t);return n=n.replace(/ $/,"%20"),Ws(e,"No window.location.(origin|href) available to create URL for href: "+n),new URL(n,e)}let m={get action(){return a},get location(){return t(i,s)},listen(t){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(Gs,d),l=t,()=>{i.removeEventListener(Gs,d),l=null}},createHref:t=>e(i,t),createURL:f,encodeLocation(t){let e=f(t);return{pathname:e.pathname,search:e.search,hash:e.hash}},push:h,replace:p,go:t=>s.go(t)};return m}((function(t,e){let{pathname:n="/",search:r="",hash:i=""}=Ks(t.location.hash.substr(1));return n.startsWith("/")||n.startsWith(".")||(n="/"+n),zs("",{pathname:n,search:r,hash:i},e.state&&e.state.usr||null,e.state&&e.state.key||"default")}),(function(t,e){let n=t.document.querySelector("base"),r="";if(n&&n.getAttribute("href")){let e=t.location.href,n=e.indexOf("#");r=-1===n?e:e.slice(0,n)}return r+"#"+("string"==typeof e?e:qs(e))}),(function(t,e){Hs("/"===t.pathname.charAt(0),"relative pathnames are not supported in hash history.push("+JSON.stringify(e)+")")}),t)}function Ws(t,e){if(!1===t||null==t)throw new Error(e)}function Hs(t,e){if(!t){"undefined"!=typeof console&&console.warn(e);try{throw new Error(e)}catch(uy){}}}function $s(t,e){return{usr:t.state,key:t.key,idx:e}}function zs(t,e,n,r){return void 0===n&&(n=null),Is({pathname:"string"==typeof t?t:t.pathname,search:"",hash:""},"string"==typeof e?Ks(e):e,{state:n,key:e&&e.key||r||Math.random().toString(36).substr(2,8)})}function qs(t){let{pathname:e="/",search:n="",hash:r=""}=t;return n&&"?"!==n&&(e+="?"===n.charAt(0)?n:"?"+n),r&&"#"!==r&&(e+="#"===r.charAt(0)?r:"#"+r),e}function Ks(t){let e={};if(t){let n=t.indexOf("#");n>=0&&(e.hash=t.substr(n),t=t.substr(0,n));let r=t.indexOf("?");r>=0&&(e.search=t.substr(r),t=t.substr(0,r)),t&&(e.pathname=t)}return e}var Ys,Qs;function Xs(t,e,n){return void 0===n&&(n="/"),function(t,e,n,r){let i="string"==typeof e?Ks(e):e,o=da(i.pathname||"/",n);if(null==o)return null;let s=Zs(t);!function(t){t.sort(((t,e)=>t.score!==e.score?e.score-t.score:function(t,e){let n=t.length===e.length&&t.slice(0,-1).every(((t,n)=>t===e[n]));return n?t[t.length-1]-e[e.length-1]:0}(t.routesMeta.map((t=>t.childrenIndex)),e.routesMeta.map((t=>t.childrenIndex)))))}(s);let a=null;for(let l=0;null==a&&l<s.length;++l){let t=ca(o);a=la(s[l],t,r)}return a}(t,e,n,!1)}function Zs(t,e,n,r){void 0===e&&(e=[]),void 0===n&&(n=[]),void 0===r&&(r="");let i=(t,i,o)=>{let s={relativePath:void 0===o?t.path||"":o,caseSensitive:!0===t.caseSensitive,childrenIndex:i,route:t};s.relativePath.startsWith("/")&&(Ws(s.relativePath.startsWith(r),'Absolute route path "'+s.relativePath+'" nested under path "'+r+'" is not valid. An absolute child route path must start with the combined path of all its parent routes.'),s.relativePath=s.relativePath.slice(r.length));let a=fa([r,s.relativePath]),l=n.concat(s);t.children&&t.children.length>0&&(Ws(!0!==t.index,'Index routes must not have child routes. Please remove all child routes from route path "'+a+'".'),Zs(t.children,e,l,a)),(null!=t.path||t.index)&&e.push({path:a,score:aa(a,t.index),routesMeta:l})};return t.forEach(((t,e)=>{var n;if(""!==t.path&&null!=(n=t.path)&&n.includes("?"))for(let r of Js(t.path))i(t,e,r);else i(t,e)})),e}function Js(t){let e=t.split("/");if(0===e.length)return[];let[n,...r]=e,i=n.endsWith("?"),o=n.replace(/\?$/,"");if(0===r.length)return i?[o,""]:[o];let s=Js(r.join("/")),a=[];return a.push(...s.map((t=>""===t?o:[o,t].join("/")))),i&&a.push(...s),a.map((e=>t.startsWith("/")&&""===e?"/":e))}(Qs=Ys||(Ys={})).data="data",Qs.deferred="deferred",Qs.redirect="redirect",Qs.error="error";const ta=/^:[\w-]+$/,ea=3,na=2,ra=1,ia=10,oa=-2,sa=t=>"*"===t;function aa(t,e){let n=t.split("/"),r=n.length;return n.some(sa)&&(r+=oa),e&&(r+=na),n.filter((t=>!sa(t))).reduce(((t,e)=>t+(ta.test(e)?ea:""===e?ra:ia)),r)}function la(t,e,n){let{routesMeta:r}=t,i={},o="/",s=[];for(let a=0;a<r.length;++a){let t=r[a],l=a===r.length-1,u="/"===o?e:e.slice(o.length)||"/",c=ua({path:t.relativePath,caseSensitive:t.caseSensitive,end:l},u),d=t.route;if(!c&&l&&n&&!r[r.length-1].route.index&&(c=ua({path:t.relativePath,caseSensitive:t.caseSensitive,end:!1},u)),!c)return null;Object.assign(i,c.params),s.push({params:i,pathname:fa([o,c.pathname]),pathnameBase:ma(fa([o,c.pathnameBase])),route:d}),"/"!==c.pathnameBase&&(o=fa([o,c.pathnameBase]))}return s}function ua(t,e){"string"==typeof t&&(t={path:t,caseSensitive:!1,end:!0});let[n,r]=function(t,e,n){void 0===e&&(e=!1);void 0===n&&(n=!0);Hs("*"===t||!t.endsWith("*")||t.endsWith("/*"),'Route path "'+t+'" will be treated as if it were "'+t.replace(/\*$/,"/*")+'" because the `*` character must always follow a `/` in the pattern. To get rid of this warning, please change the route path to "'+t.replace(/\*$/,"/*")+'".');let r=[],i="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,((t,e,n)=>(r.push({paramName:e,isOptional:null!=n}),n?"/?([^\\/]+)?":"/([^\\/]+)")));t.endsWith("*")?(r.push({paramName:"*"}),i+="*"===t||"/*"===t?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":""!==t&&"/"!==t&&(i+="(?:(?=\\/|$))");let o=new RegExp(i,e?void 0:"i");return[o,r]}(t.path,t.caseSensitive,t.end),i=e.match(n);if(!i)return null;let o=i[0],s=o.replace(/(.)\/+$/,"$1"),a=i.slice(1);return{params:r.reduce(((t,e,n)=>{let{paramName:r,isOptional:i}=e;if("*"===r){let t=a[n]||"";s=o.slice(0,o.length-t.length).replace(/(.)\/+$/,"$1")}const l=a[n];return t[r]=i&&!l?void 0:(l||"").replace(/%2F/g,"/"),t}),{}),pathname:o,pathnameBase:s,pattern:t}}function ca(t){try{return t.split("/").map((t=>decodeURIComponent(t).replace(/\//g,"%2F"))).join("/")}catch(e){return Hs(!1,'The URL path "'+t+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent encoding ('+e+")."),t}}function da(t,e){if("/"===e)return t;if(!t.toLowerCase().startsWith(e.toLowerCase()))return null;let n=e.endsWith("/")?e.length-1:e.length,r=t.charAt(n);return r&&"/"!==r?null:t.slice(n)||"/"}function ha(t,e,n,r){return"Cannot include a '"+t+"' character in a manually specified `to."+e+"` 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 pa(t,e,n,r){let i;void 0===r&&(r=!1),"string"==typeof t?i=Ks(t):(i=Is({},t),Ws(!i.pathname||!i.pathname.includes("?"),ha("?","pathname","search",i)),Ws(!i.pathname||!i.pathname.includes("#"),ha("#","pathname","hash",i)),Ws(!i.search||!i.search.includes("#"),ha("#","search","hash",i)));let o,s=""===t||""===i.pathname,a=s?"/":i.pathname;if(null==a)o=n;else{let t=e.length-1;if(!r&&a.startsWith("..")){let e=a.split("/");for(;".."===e[0];)e.shift(),t-=1;i.pathname=e.join("/")}o=t>=0?e[t]:"/"}let l=function(t,e){void 0===e&&(e="/");let{pathname:n,search:r="",hash:i=""}="string"==typeof t?Ks(t):t,o=n?n.startsWith("/")?n:function(t,e){let n=e.replace(/\/+$/,"").split("/");return t.split("/").forEach((t=>{".."===t?n.length>1&&n.pop():"."!==t&&n.push(t)})),n.length>1?n.join("/"):"/"}(n,e):e;return{pathname:o,search:va(r),hash:ga(i)}}(i,o),u=a&&"/"!==a&&a.endsWith("/"),c=(s||"."===a)&&n.endsWith("/");return l.pathname.endsWith("/")||!u&&!c||(l.pathname+="/"),l}const fa=t=>t.join("/").replace(/\/\/+/g,"/"),ma=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),va=t=>t&&"?"!==t?t.startsWith("?")?t:"?"+t:"",ga=t=>t&&"#"!==t?t.startsWith("#")?t:"#"+t:"";const ya=["post","put","patch","delete"];new Set(ya);const _a=["get",...ya];
|
|
19
19
|
/**
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
function
|
|
20
|
+
* React Router v6.26.2
|
|
21
|
+
*
|
|
22
|
+
* Copyright (c) Remix Software Inc.
|
|
23
|
+
*
|
|
24
|
+
* This source code is licensed under the MIT license found in the
|
|
25
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
26
|
+
*
|
|
27
|
+
* @license MIT
|
|
28
|
+
*/
|
|
29
|
+
function ba(){return ba=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},ba.apply(this,arguments)}new Set(_a);const wa=oe(null),xa=oe(null),Sa=oe(null),Ea=oe(null),ka=oe({outlet:null,matches:[],isDataRoute:!1}),Pa=oe(null);function Ta(){return null!=Bn(Ea)}function Aa(){return Ta()||Ws(!1),Bn(Ea).location}function Ca(t){Bn(Sa).static||Ln(t)}function Ra(){let{isDataRoute:t}=Bn(ka);return t?function(){let{router:t}=function(){let t=Bn(wa);return t||Ws(!1),t}(Va.UseNavigateStable),e=Ia(ja.UseNavigateStable),n=Dn(!1);return Ca((()=>{n.current=!0})),In((function(r,i){void 0===i&&(i={}),n.current&&("number"==typeof r?t.navigate(r):t.navigate(r,ba({fromRouteId:e},i)))}),[t,e])}():function(){Ta()||Ws(!1);let t=Bn(wa),{basename:e,future:n,navigator:r}=Bn(Sa),{matches:i}=Bn(ka),{pathname:o}=Aa(),s=JSON.stringify(function(t,e){let n=function(t){return t.filter(((t,e)=>0===e||t.route.path&&t.route.path.length>0))}(t);return e?n.map(((t,e)=>e===n.length-1?t.pathname:t.pathnameBase)):n.map((t=>t.pathnameBase))}(i,n.v7_relativeSplatPath)),a=Dn(!1);return Ca((()=>{a.current=!0})),In((function(n,i){if(void 0===i&&(i={}),!a.current)return;if("number"==typeof n)return void r.go(n);let l=pa(n,JSON.parse(s),o,"path"===i.relative);null==t&&"/"!==e&&(l.pathname="/"===l.pathname?e:fa([e,l.pathname])),(i.replace?r.replace:r.push)(l,i.state,i)}),[e,r,s,o,t])}()}function Oa(t,e){return function(t,e,n,r){Ta()||Ws(!1);let{navigator:i}=Bn(Sa),{matches:o}=Bn(ka),s=o[o.length-1],a=s?s.params:{};!s||s.pathname;let l=s?s.pathnameBase:"/";s&&s.route;let u,c=Aa();if(e){var d;let t="string"==typeof e?Ks(e):e;"/"===l||(null==(d=t.pathname)?void 0:d.startsWith(l))||Ws(!1),u=t}else u=c;let h=u.pathname||"/",p=h;if("/"!==l){let t=l.replace(/^\//,"").split("/");p="/"+h.replace(/^\//,"").split("/").slice(t.length).join("/")}let f=Xs(t,{pathname:p}),m=function(t,e,n,r){var i;void 0===e&&(e=[]);void 0===n&&(n=null);void 0===r&&(r=null);if(null==t){var o;if(!n)return null;if(n.errors)t=n.matches;else{if(!(null!=(o=r)&&o.v7_partialHydration&&0===e.length&&!n.initialized&&n.matches.length>0))return null;t=n.matches}}let s=t,a=null==(i=n)?void 0:i.errors;if(null!=a){let t=s.findIndex((t=>t.route.id&&void 0!==(null==a?void 0:a[t.route.id])));t>=0||Ws(!1),s=s.slice(0,Math.min(s.length,t+1))}let l=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let c=0;c<s.length;c++){let t=s[c];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(u=c),t.route.id){let{loaderData:e,errors:r}=n,i=t.route.loader&&void 0===e[t.route.id]&&(!r||void 0===r[t.route.id]);if(t.route.lazy||i){l=!0,s=u>=0?s.slice(0,u+1):[s[0]];break}}}return s.reduceRight(((t,r,i)=>{let o,c=!1,d=null,h=null;n&&(o=a&&r.route.id?a[r.route.id]:void 0,d=r.route.errorElement||Fa,l&&(u<0&&0===i?(c=!0,h=null):u===i&&(c=!0,h=r.route.hydrateFallbackElement||null)));let p=e.concat(s.slice(0,i+1)),f=()=>{let e;return e=o?d:c?h:r.route.Component?Dt(r.route.Component,null):r.route.element?r.route.element:t,Dt(Da,{match:r,routeContext:{outlet:t,matches:p,isDataRoute:null!=n},children:e})};return n&&(r.route.ErrorBoundary||r.route.errorElement||0===i)?Dt(La,{location:n.location,revalidation:n.revalidation,component:d,error:o,children:f(),routeContext:{outlet:null,matches:p,isDataRoute:!0}}):f()}),null)}(f&&f.map((t=>Object.assign({},t,{params:Object.assign({},a,t.params),pathname:fa([l,i.encodeLocation?i.encodeLocation(t.pathname).pathname:t.pathname]),pathnameBase:"/"===t.pathnameBase?l:fa([l,i.encodeLocation?i.encodeLocation(t.pathnameBase).pathname:t.pathnameBase])}))),o,n,r);if(e&&m)return Dt(Ea.Provider,{value:{location:ba({pathname:"/",search:"",hash:"",state:null,key:"default"},u),navigationType:Bs.Pop}},m);return m}(t,e)}function Ma(){let t=function(){var t;let e=Bn(Pa),n=function(){let t=Bn(xa);return t||Ws(!1),t}(ja.UseRouteError),r=Ia(ja.UseRouteError);if(void 0!==e)return e;return null==(t=n.errors)?void 0:t[r]}(),e=function(t){return null!=t&&"number"==typeof t.status&&"string"==typeof t.statusText&&"boolean"==typeof t.internal&&"data"in t}(t)?t.status+" "+t.statusText:t instanceof Error?t.message:JSON.stringify(t),n=t instanceof Error?t.stack:null,r={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return Dt(It,null,Dt("h2",null,"Unexpected Application Error!"),Dt("h3",{style:{fontStyle:"italic"}},e),n?Dt("pre",{style:r},n):null,null)}const Fa=Dt(Ma,null);class La extends Bt{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,e){return e.location!==t.location||"idle"!==e.revalidation&&"idle"===t.revalidation?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:void 0!==t.error?t.error:e.error,location:e.location,revalidation:t.revalidation||e.revalidation}}componentDidCatch(t,e){console.error("React Router caught the following error during render",t,e)}render(){return void 0!==this.state.error?Dt(ka.Provider,{value:this.props.routeContext},Dt(Pa.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function Da(t){let{routeContext:e,match:n,children:r}=t,i=Bn(wa);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),Dt(ka.Provider,{value:e},r)}var Va=function(t){return t.UseBlocker="useBlocker",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t}(Va||{}),ja=function(t){return t.UseBlocker="useBlocker",t.UseLoaderData="useLoaderData",t.UseActionData="useActionData",t.UseRouteError="useRouteError",t.UseNavigation="useNavigation",t.UseRouteLoaderData="useRouteLoaderData",t.UseMatches="useMatches",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t.UseRouteId="useRouteId",t}(ja||{});function Ia(t){let e=function(){let t=Bn(ka);return t||Ws(!1),t}(),n=e.matches[e.matches.length-1];return n.route.id||Ws(!1),n.route.id}function Ba(t){Ws(!1)}function Na(t){let{basename:e="/",children:n=null,location:r,navigationType:i=Bs.Pop,navigator:o,static:s=!1,future:a}=t;Ta()&&Ws(!1);let l=e.replace(/^\/*/,"/"),u=jn((()=>({basename:l,navigator:o,static:s,future:ba({v7_relativeSplatPath:!1},a)})),[l,a,o,s]);"string"==typeof r&&(r=Ks(r));let{pathname:c="/",search:d="",hash:h="",state:p=null,key:f="default"}=r,m=jn((()=>{let t=da(c,l);return null==t?null:{location:{pathname:t,search:d,hash:h,state:p,key:f},navigationType:i}}),[l,c,d,h,p,f,i]);return null==m?null:Dt(Sa.Provider,{value:u},Dt(Ea.Provider,{children:n,value:m}))}function Ga(t){let{children:e,location:n}=t;return Oa(Ua(e),n)}function Ua(t,e){void 0===e&&(e=[]);let n=[];return rr.forEach(t,((t,r)=>{if(!Dr(t))return;let i=[...e,r];if(t.type===It)return void n.push.apply(n,Ua(t.props.children,i));t.type!==Ba&&Ws(!1),t.props.index&&t.props.children&&Ws(!1);let o={id:t.props.id||i.join("-"),caseSensitive:t.props.caseSensitive,element:t.props.element,Component:t.props.Component,index:t.props.index,path:t.props.path,loader:t.props.loader,action:t.props.action,errorElement:t.props.errorElement,ErrorBoundary:t.props.ErrorBoundary,hasErrorBoundary:null!=t.props.ErrorBoundary||null!=t.props.errorElement,shouldRevalidate:t.props.shouldRevalidate,handle:t.props.handle,lazy:t.props.lazy};t.props.children&&(o.children=Ua(t.props.children,i)),n.push(o)})),n}
|
|
30
30
|
/**
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
*/new Promise((()=>{}));try{window.__reactRouterVersion="6"}catch(yy){}const Za=ai.startTransition;function Ja(t){let{basename:e,children:n,future:r,window:i}=t,o=$n();null==o.current&&(o.current=Xs({window:i,v5Compat:!0}));let s=o.current,[a,l]=Nn({action:s.action,location:s.location}),{v7_startTransition:u}=r||{},c=Kn((t=>{u&&Za?Za((()=>l(t))):l(t)}),[l,u]);return Hn((()=>s.listen(c)),[s,c]),$t(Ya,{basename:e,children:n,location:a.location,navigationType:a.action,navigator:s,future:r})}var tl,el,nl,rl;let il;(el=tl||(tl={})).UseScrollRestoration="useScrollRestoration",el.UseSubmit="useSubmit",el.UseSubmitFetcher="useSubmitFetcher",el.UseFetcher="useFetcher",el.useViewTransitionState="useViewTransitionState",(rl=nl||(nl={})).UseFetcher="useFetcher",rl.UseFetchers="useFetchers",rl.UseScrollRestoration="useScrollRestoration";const ol=()=>{if(il)return il;return il=new ds({defaultOptions:{queries:{retry:(t,e)=>{var n;return e instanceof bo&&![401,403].includes((null==(n=e.response)?void 0:n.status)||0)}}}}),il},sl="getAllPromotions",al=[{name:"Id",field:"id"},{name:"Category",field:"category"},{name:"Promotion Status",field:"promotionStatus",type:{kind:"status",styleOverrides:{Enabled:{"--tw-bg-opacity":"1",backgroundColor:"rgb(240 253 244 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(21 128 61 / var(--tw-text-opacity))","--tw-ring-color":"rgb(22 163 74 / 0.2)"},Disabled:{"--tw-bg-opacity":"1",backgroundColor:"rgb(254 242 242 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(185 28 28 / var(--tw-text-opacity))","--tw-ring-color":"rgb(220 38 38 / 0.2)"}}}},{name:"Contentful Status",field:"contentfulStatus",type:{kind:"status",styleOverrides:{Linked:{"--tw-bg-opacity":"1",backgroundColor:"rgb(240 253 244 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(21 128 61 / var(--tw-text-opacity))","--tw-ring-color":"rgb(22 163 74 / 0.2)"},Unlinked:{"--tw-bg-opacity":"1",backgroundColor:"rgb(254 242 242 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(185 28 28 / var(--tw-text-opacity))","--tw-ring-color":"rgb(220 38 38 / 0.2)"}}}},{name:"Created At",field:"createdAt",type:{kind:"date"}},{name:"Updated At",field:"updatedAt",type:{kind:"date"}}],ll=()=>{const{getAllPromotions:t}=Eo(),e=Ba(),{isPending:n,error:r,data:i}=Ls({queryKey:[sl],queryFn:t});switch(!0){case n:return fo(po,{children:"Loading..."});case!!r:return mo(po,{children:["An error has occurred: ",r.message]});case!!i:return fo(qs,{columns:al,data:(o=i,o.data.map((t=>({id:t.id,category:t.category.title,promotionStatus:t.status,contentfulStatus:t.contentfulContent?"Linked":"Unlinked",createdAt:t.createdAt,updatedAt:t.updatedAt}))).sort(((t,e)=>new Date(e.updatedAt).valueOf()-new Date(t.updatedAt).valueOf()))),title:"Promotions",subtitle:"A list of currently configured promoted benefits",addButtonText:"Add New Promotion",onAdd:()=>e("/promotion"),onClick:t=>e(`/promotion/${t}`)});default:return fo(po,{children:"No data returned from backend"})}var o};function ul(t){if("undefined"==typeof Proxy)return t;const e=new Map;return new Proxy(((...e)=>t(...e)),{get:(n,r)=>"create"===r?t:(e.has(r)||e.set(r,t(r)),e.get(r))})}function cl(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}const dl=t=>Array.isArray(t);function hl(t,e){if(!Array.isArray(e))return!1;const n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}function pl(t){return"string"==typeof t||Array.isArray(t)}function fl(t){const e=[{},{}];return null==t||t.values.forEach(((t,n)=>{e[0][n]=t.get(),e[1][n]=t.getVelocity()})),e}function ml(t,e,n,r){if("function"==typeof e){const[i,o]=fl(r);e=e(void 0!==n?n:t.custom,i,o)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[i,o]=fl(r);e=e(void 0!==n?n:t.custom,i,o)}return e}function vl(t,e,n){const r=t.getProps();return ml(r,e,void 0!==n?n:r.custom,t)}const gl=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],yl=["initial",...gl],bl=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],wl=new Set(bl),xl=t=>1e3*t,_l=t=>t/1e3,Sl={type:"spring",stiffness:500,damping:25,restSpeed:10},El={type:"keyframes",duration:.8},kl={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Pl=(t,{keyframes:e})=>e.length>2?El:wl.has(t)?t.startsWith("scale")?{type:"spring",stiffness:550,damping:0===e[1]?2*Math.sqrt(550):30,restSpeed:10}:Sl:kl;function Tl(t,e){return t[e]||t.default||t}const Cl=!1,Al=t=>null!==t;function Rl(t,{repeat:e,repeatType:n="loop"},r){const i=t.filter(Al),o=e&&"loop"!==n&&e%2==1?0:i.length-1;return o&&void 0!==r?r:i[o]}const Ol=t=>t;const Fl=["read","resolveKeyframes","update","preRender","render","postRender"];function Ll(t,e){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,s=Fl.reduce(((t,e)=>(t[e]=function(t){let e=new Set,n=new Set,r=!1,i=!1;const o=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1};function a(e){o.has(e)&&(l.schedule(e),t()),e(s)}const l={schedule:(t,i=!1,s=!1)=>{const a=s&&r?e:n;return i&&o.add(t),a.has(t)||a.add(t),t},cancel:t=>{n.delete(t),o.delete(t)},process:t=>{s=t,r?i=!0:(r=!0,[e,n]=[n,e],n.clear(),e.forEach(a),r=!1,i&&(i=!1,l.process(t)))}};return l}(o),t)),{}),{read:a,resolveKeyframes:l,update:u,preRender:c,render:d,postRender:h}=s,p=()=>{const o=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(o-i.timestamp,40),1),i.timestamp=o,i.isProcessing=!0,a.process(i),l.process(i),u.process(i),c.process(i),d.process(i),h.process(i),i.isProcessing=!1,n&&e&&(r=!1,t(p))};return{schedule:Fl.reduce(((e,o)=>{const a=s[o];return e[o]=(e,o=!1,s=!1)=>(n||(n=!0,r=!0,i.isProcessing||t(p)),a.schedule(e,o,s)),e}),{}),cancel:t=>{for(let e=0;e<Fl.length;e++)s[Fl[e]].cancel(t)},state:i,steps:s}}const{schedule:Ml,cancel:Dl,state:Vl,steps:jl}=Ll("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:Ol,!0),Il=t=>/^0[^.\s]+$/u.test(t);let Bl=Ol;const Nl=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),Ul=t=>e=>"string"==typeof e&&e.startsWith(t),Wl=Ul("--"),Hl=Ul("var(--"),$l=t=>!!Hl(t)&&zl.test(t.split("/*")[0].trim()),zl=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,ql=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Kl(t,e,n=1){const[r,i]=function(t){const e=ql.exec(t);if(!e)return[,];const[,n,r,i]=e;return[`--${null!=n?n:r}`,i]}(t);if(!r)return;const o=window.getComputedStyle(e).getPropertyValue(r);if(o){const t=o.trim();return Nl(t)?parseFloat(t):t}return $l(i)?Kl(i,e,n+1):i}const Gl=(t,e,n)=>n>e?e:n<t?t:n,Yl={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},Ql={...Yl,transform:t=>Gl(0,1,t)},Xl={...Yl,default:1},Zl=t=>Math.round(1e5*t)/1e5,Jl=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,tu=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,eu=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;function nu(t){return"string"==typeof t}const ru=t=>({test:e=>nu(e)&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),iu=ru("deg"),ou=ru("%"),su=ru("px"),au=ru("vh"),lu=ru("vw"),uu={...ou,parse:t=>ou.parse(t)/100,transform:t=>ou.transform(100*t)},cu=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),du=t=>t===Yl||t===su,hu=(t,e)=>parseFloat(t.split(", ")[e]),pu=(t,e)=>(n,{transform:r})=>{if("none"===r||!r)return 0;const i=r.match(/^matrix3d\((.+)\)$/u);if(i)return hu(i[1],e);{const e=r.match(/^matrix\((.+)\)$/u);return e?hu(e[1],t):0}},fu=new Set(["x","y","z"]),mu=bl.filter((t=>!fu.has(t)));const vu={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:pu(4,13),y:pu(5,14)};vu.translateX=vu.x,vu.translateY=vu.y;const gu=t=>e=>e.test(t),yu=[Yl,su,ou,iu,lu,au,{test:t=>"auto"===t,parse:t=>t}],bu=t=>yu.find(gu(t)),wu=new Set;let xu=!1,_u=!1;function Su(){if(_u){const t=Array.from(wu).filter((t=>t.needsMeasurement)),e=new Set(t.map((t=>t.element))),n=new Map;e.forEach((t=>{const e=function(t){const e=[];return mu.forEach((n=>{const r=t.getValue(n);void 0!==r&&(e.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))})),e}(t);e.length&&(n.set(t,e),t.render())})),t.forEach((t=>t.measureInitialState())),e.forEach((t=>{t.render();const e=n.get(t);e&&e.forEach((([e,n])=>{var r;null===(r=t.getValue(e))||void 0===r||r.set(n)}))})),t.forEach((t=>t.measureEndState())),t.forEach((t=>{void 0!==t.suspendedScrollY&&window.scrollTo(0,t.suspendedScrollY)}))}_u=!1,xu=!1,wu.forEach((t=>t.complete())),wu.clear()}function Eu(){wu.forEach((t=>{t.readKeyframes(),t.needsMeasurement&&(_u=!0)}))}class ku{constructor(t,e,n,r,i,o=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=e,this.name=n,this.motionValue=r,this.element=i,this.isAsync=o}scheduleResolve(){this.isScheduled=!0,this.isAsync?(wu.add(this),xu||(xu=!0,Ml.read(Eu),Ml.resolveKeyframes(Su))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:e,element:n,motionValue:r}=this;for(let i=0;i<t.length;i++)if(null===t[i])if(0===i){const i=null==r?void 0:r.get(),o=t[t.length-1];if(void 0!==i)t[0]=i;else if(n&&e){const r=n.readValue(e,o);null!=r&&(t[0]=r)}void 0===t[0]&&(t[0]=o),r&&void 0===i&&r.set(t[0])}else t[i]=t[i-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),wu.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,wu.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}const Pu=(t,e)=>n=>Boolean(nu(n)&&eu.test(n)&&n.startsWith(t)||e&&!function(t){return null==t}(n)&&Object.prototype.hasOwnProperty.call(n,e)),Tu=(t,e,n)=>r=>{if(!nu(r))return r;const[i,o,s,a]=r.match(Jl);return{[t]:parseFloat(i),[e]:parseFloat(o),[n]:parseFloat(s),alpha:void 0!==a?parseFloat(a):1}},Cu={...Yl,transform:t=>Math.round((t=>Gl(0,255,t))(t))},Au={test:Pu("rgb","red"),parse:Tu("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:r=1})=>"rgba("+Cu.transform(t)+", "+Cu.transform(e)+", "+Cu.transform(n)+", "+Zl(Ql.transform(r))+")"};const Ru={test:Pu("#"),parse:function(t){let e="",n="",r="",i="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),r=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),r=t.substring(3,4),i=t.substring(4,5),e+=e,n+=n,r+=r,i+=i),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}},transform:Au.transform},Ou={test:Pu("hsl","hue"),parse:Tu("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:r=1})=>"hsla("+Math.round(t)+", "+ou.transform(Zl(e))+", "+ou.transform(Zl(n))+", "+Zl(Ql.transform(r))+")"},Fu={test:t=>Au.test(t)||Ru.test(t)||Ou.test(t),parse:t=>Au.test(t)?Au.parse(t):Ou.test(t)?Ou.parse(t):Ru.parse(t),transform:t=>nu(t)?t:t.hasOwnProperty("red")?Au.transform(t):Ou.transform(t)};const Lu="number",Mu="color",Du="var",Vu="var(",ju="${}",Iu=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Bu(t){const e=t.toString(),n=[],r={color:[],number:[],var:[]},i=[];let o=0;const s=e.replace(Iu,(t=>(Fu.test(t)?(r.color.push(o),i.push(Mu),n.push(Fu.parse(t))):t.startsWith(Vu)?(r.var.push(o),i.push(Du),n.push(t)):(r.number.push(o),i.push(Lu),n.push(parseFloat(t))),++o,ju))).split(ju);return{values:n,split:s,indexes:r,types:i}}function Nu(t){return Bu(t).values}function Uu(t){const{split:e,types:n}=Bu(t),r=e.length;return t=>{let i="";for(let o=0;o<r;o++)if(i+=e[o],void 0!==t[o]){const e=n[o];i+=e===Lu?Zl(t[o]):e===Mu?Fu.transform(t[o]):t[o]}return i}}const Wu=t=>"number"==typeof t?0:t;const Hu={test:function(t){var e,n;return isNaN(t)&&nu(t)&&((null===(e=t.match(Jl))||void 0===e?void 0:e.length)||0)+((null===(n=t.match(tu))||void 0===n?void 0:n.length)||0)>0},parse:Nu,createTransformer:Uu,getAnimatableNone:function(t){const e=Nu(t);return Uu(t)(e.map(Wu))}},$u=new Set(["brightness","contrast","saturate","opacity"]);function zu(t){const[e,n]=t.slice(0,-1).split("(");if("drop-shadow"===e)return t;const[r]=n.match(Jl)||[];if(!r)return t;const i=n.replace(r,"");let o=$u.has(e)?1:0;return r!==n&&(o*=100),e+"("+o+i+")"}const qu=/\b([a-z-]*)\(.*?\)/gu,Ku={...Hu,getAnimatableNone:t=>{const e=t.match(qu);return e?e.map(zu).join(" "):t}},Gu={...Yl,transform:Math.round},Yu={borderWidth:su,borderTopWidth:su,borderRightWidth:su,borderBottomWidth:su,borderLeftWidth:su,borderRadius:su,radius:su,borderTopLeftRadius:su,borderTopRightRadius:su,borderBottomRightRadius:su,borderBottomLeftRadius:su,width:su,maxWidth:su,height:su,maxHeight:su,size:su,top:su,right:su,bottom:su,left:su,padding:su,paddingTop:su,paddingRight:su,paddingBottom:su,paddingLeft:su,margin:su,marginTop:su,marginRight:su,marginBottom:su,marginLeft:su,rotate:iu,rotateX:iu,rotateY:iu,rotateZ:iu,scale:Xl,scaleX:Xl,scaleY:Xl,scaleZ:Xl,skew:iu,skewX:iu,skewY:iu,distance:su,translateX:su,translateY:su,translateZ:su,x:su,y:su,z:su,perspective:su,transformPerspective:su,opacity:Ql,originX:uu,originY:uu,originZ:su,zIndex:Gu,backgroundPositionX:su,backgroundPositionY:su,fillOpacity:Ql,strokeOpacity:Ql,numOctaves:Gu},Qu={...Yu,color:Fu,backgroundColor:Fu,outlineColor:Fu,fill:Fu,stroke:Fu,borderColor:Fu,borderTopColor:Fu,borderRightColor:Fu,borderBottomColor:Fu,borderLeftColor:Fu,filter:Ku,WebkitFilter:Ku},Xu=t=>Qu[t];function Zu(t,e){let n=Xu(t);return n!==Ku&&(n=Hu),n.getAnimatableNone?n.getAnimatableNone(e):void 0}const Ju=new Set(["auto","none","0"]);class tc extends ku{constructor(t,e,n,r,i){super(t,e,n,r,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:e,name:n}=this;if(!e||!e.current)return;super.readKeyframes();for(let a=0;a<t.length;a++){let n=t[a];if("string"==typeof n&&(n=n.trim(),$l(n))){const r=Kl(n,e.current);void 0!==r&&(t[a]=r),a===t.length-1&&(this.finalKeyframe=n)}}if(this.resolveNoneKeyframes(),!cu.has(n)||2!==t.length)return;const[r,i]=t,o=bu(r),s=bu(i);if(o!==s)if(du(o)&&du(s))for(let a=0;a<t.length;a++){const e=t[a];"string"==typeof e&&(t[a]=parseFloat(e))}else this.needsMeasurement=!0}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:e}=this,n=[];for(let i=0;i<t.length;i++)("number"==typeof(r=t[i])?0===r:null===r||"none"===r||"0"===r||Il(r))&&n.push(i);var r;n.length&&function(t,e,n){let r,i=0;for(;i<t.length&&!r;){const e=t[i];"string"==typeof e&&!Ju.has(e)&&Bu(e).values.length&&(r=t[i]),i++}if(r&&n)for(const o of e)t[o]=Zu(n,r)}(t,n,e)}measureInitialState(){const{element:t,unresolvedKeyframes:e,name:n}=this;if(!t||!t.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=vu[n](t.measureViewportBox(),window.getComputedStyle(t.current)),e[0]=this.measuredOrigin;const r=e[e.length-1];void 0!==r&&t.getValue(n,r).jump(r,!1)}measureEndState(){var t;const{element:e,name:n,unresolvedKeyframes:r}=this;if(!e||!e.current)return;const i=e.getValue(n);i&&i.jump(this.measuredOrigin,!1);const o=r.length-1,s=r[o];r[o]=vu[n](e.measureViewportBox(),window.getComputedStyle(e.current)),null!==s&&void 0===this.finalKeyframe&&(this.finalKeyframe=s),(null===(t=this.removedTransforms)||void 0===t?void 0:t.length)&&this.removedTransforms.forEach((([t,n])=>{e.getValue(t).set(n)})),this.resolveNoneKeyframes()}}function ec(t){let e;return()=>(void 0===e&&(e=t()),e)}let nc;function rc(){nc=void 0}const ic={now:()=>(void 0===nc&&ic.set(Vl.isProcessing||Cl?Vl.timestamp:performance.now()),nc),set:t=>{nc=t,queueMicrotask(rc)}},oc=(t,e)=>"zIndex"!==e&&(!("number"!=typeof t&&!Array.isArray(t))||!("string"!=typeof t||!Hu.test(t)&&"0"!==t||t.startsWith("url(")));class sc{constructor({autoplay:t=!0,delay:e=0,type:n="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:o="loop",...s}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=ic.now(),this.options={autoplay:t,delay:e,type:n,repeat:r,repeatDelay:i,repeatType:o,...s},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(Eu(),Su()),this._resolved}onKeyframesResolved(t,e){this.resolvedAt=ic.now(),this.hasAttemptedResolve=!0;const{name:n,type:r,velocity:i,delay:o,onComplete:s,onUpdate:a,isGenerator:l}=this.options;if(!l&&!function(t,e,n,r){const i=t[0];if(null===i)return!1;if("display"===e||"visibility"===e)return!0;const o=t[t.length-1],s=oc(i,e),a=oc(o,e);return!(!s||!a)&&(function(t){const e=t[0];if(1===t.length)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}(t)||"spring"===n&&r)}(t,n,r,i)){if(!o)return null==a||a(Rl(t,this.options,e)),null==s||s(),void this.resolveFinishedPromise();this.options.duration=0}const u=this.initPlayback(t,e);!1!==u&&(this._resolved={keyframes:t,finalKeyframe:e,...u},this.onPostResolved())}onPostResolved(){}then(t,e){return this.currentFinishedPromise.then(t,e)}updateFinishedPromise(){this.currentFinishedPromise=new Promise((t=>{this.resolveFinishedPromise=t}))}}function ac(t,e){return e?t*(1e3/e):0}const lc=5;function uc(t,e,n){const r=Math.max(e-lc,0);return ac(n-t(r),e-r)}const cc=.001,dc=.01,hc=10,pc=.05,fc=1;function mc({duration:t=800,bounce:e=.25,velocity:n=0,mass:r=1}){let i,o,s=1-e;s=Gl(pc,fc,s),t=Gl(dc,hc,_l(t)),s<1?(i=e=>{const r=e*s,i=r*t,o=r-n,a=gc(e,s),l=Math.exp(-i);return cc-o/a*l},o=e=>{const r=e*s*t,o=r*n+n,a=Math.pow(s,2)*Math.pow(e,2)*t,l=Math.exp(-r),u=gc(Math.pow(e,2),s);return(-i(e)+cc>0?-1:1)*((o-a)*l)/u}):(i=e=>Math.exp(-e*t)*((e-n)*t+1)-cc,o=e=>Math.exp(-e*t)*(t*t*(n-e)));const a=function(t,e,n){let r=n;for(let i=1;i<vc;i++)r-=t(r)/e(r);return r}(i,o,5/t);if(t=xl(t),isNaN(a))return{stiffness:100,damping:10,duration:t};{const e=Math.pow(a,2)*r;return{stiffness:e,damping:2*s*Math.sqrt(r*e),duration:t}}}const vc=12;function gc(t,e){return t*Math.sqrt(1-e*e)}const yc=["duration","bounce"],bc=["stiffness","damping","mass"];function wc(t,e){return e.some((e=>void 0!==t[e]))}function xc({keyframes:t,restDelta:e,restSpeed:n,...r}){const i=t[0],o=t[t.length-1],s={done:!1,value:i},{stiffness:a,damping:l,mass:u,duration:c,velocity:d,isResolvedFromDuration:h}=function(t){let e={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...t};if(!wc(t,bc)&&wc(t,yc)){const n=mc(t);e={...e,...n,mass:1},e.isResolvedFromDuration=!0}return e}({...r,velocity:-_l(r.velocity||0)}),p=d||0,f=l/(2*Math.sqrt(a*u)),m=o-i,v=_l(Math.sqrt(a/u)),g=Math.abs(m)<5;let y;if(n||(n=g?.01:2),e||(e=g?.005:.5),f<1){const t=gc(v,f);y=e=>{const n=Math.exp(-f*v*e);return o-n*((p+f*v*m)/t*Math.sin(t*e)+m*Math.cos(t*e))}}else if(1===f)y=t=>o-Math.exp(-v*t)*(m+(p+v*m)*t);else{const t=v*Math.sqrt(f*f-1);y=e=>{const n=Math.exp(-f*v*e),r=Math.min(t*e,300);return o-n*((p+f*v*m)*Math.sinh(r)+t*m*Math.cosh(r))/t}}return{calculatedDuration:h&&c||null,next:t=>{const r=y(t);if(h)s.done=t>=c;else{let i=0;f<1&&(i=0===t?xl(p):uc(y,t,r));const a=Math.abs(i)<=n,l=Math.abs(o-r)<=e;s.done=a&&l}return s.value=s.done?o:r,s}}}function _c({keyframes:t,velocity:e=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:s,min:a,max:l,restDelta:u=.5,restSpeed:c}){const d=t[0],h={done:!1,value:d},p=t=>void 0===a?l:void 0===l||Math.abs(a-t)<Math.abs(l-t)?a:l;let f=n*e;const m=d+f,v=void 0===s?m:s(m);v!==m&&(f=v-d);const g=t=>-f*Math.exp(-t/r),y=t=>v+g(t),b=t=>{const e=g(t),n=y(t);h.done=Math.abs(e)<=u,h.value=h.done?v:n};let w,x;const _=t=>{var e;(e=h.value,void 0!==a&&e<a||void 0!==l&&e>l)&&(w=t,x=xc({keyframes:[h.value,p(h.value)],velocity:uc(y,t,h.value),damping:i,stiffness:o,restDelta:u,restSpeed:c}))};return _(0),{calculatedDuration:null,next:t=>{let e=!1;return x||void 0!==w||(e=!0,b(t),_(t)),void 0!==w&&t>=w?x.next(t-w):(!e&&b(t),h)}}}const Sc=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,Ec=1e-7,kc=12;function Pc(t,e,n,r){if(t===e&&n===r)return Ol;const i=e=>function(t,e,n,r,i){let o,s,a=0;do{s=e+(n-e)/2,o=Sc(s,r,i)-t,o>0?n=s:e=s}while(Math.abs(o)>Ec&&++a<kc);return s}(e,0,1,t,n);return t=>0===t||1===t?t:Sc(i(t),e,r)}const Tc=Pc(.42,0,1,1),Cc=Pc(0,0,.58,1),Ac=Pc(.42,0,.58,1),Rc=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,Oc=t=>e=>1-t(1-e),Fc=t=>1-Math.sin(Math.acos(t)),Lc=Oc(Fc),Mc=Rc(Fc),Dc=Pc(.33,1.53,.69,.99),Vc=Oc(Dc),jc={linear:Ol,easeIn:Tc,easeInOut:Ac,easeOut:Cc,circIn:Fc,circInOut:Mc,circOut:Lc,backIn:Vc,backInOut:Rc(Vc),backOut:Dc,anticipate:t=>(t*=2)<1?.5*Vc(t):.5*(2-Math.pow(2,-10*(t-1)))},Ic=t=>{if(Array.isArray(t)){Bl(4===t.length);const[e,n,r,i]=t;return Pc(e,n,r,i)}return"string"==typeof t?(Bl(void 0!==jc[t]),jc[t]):t},Bc=(t,e)=>n=>e(t(n)),Nc=(...t)=>t.reduce(Bc),Uc=(t,e,n)=>{const r=e-t;return 0===r?1:(n-t)/r},Wc=(t,e,n)=>t+(e-t)*n;function Hc(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function $c(t,e){return n=>n>0?e:t}const zc=(t,e,n)=>{const r=t*t,i=n*(e*e-r)+r;return i<0?0:Math.sqrt(i)},qc=[Ru,Au,Ou];function Kc(t){const e=(n=t,qc.find((t=>t.test(n))));var n;if(!Boolean(e))return!1;let r=e.parse(t);return e===Ou&&(r=function({hue:t,saturation:e,lightness:n,alpha:r}){t/=360,n/=100;let i=0,o=0,s=0;if(e/=100){const r=n<.5?n*(1+e):n+e-n*e,a=2*n-r;i=Hc(a,r,t+1/3),o=Hc(a,r,t),s=Hc(a,r,t-1/3)}else i=o=s=n;return{red:Math.round(255*i),green:Math.round(255*o),blue:Math.round(255*s),alpha:r}}(r)),r}const Gc=(t,e)=>{const n=Kc(t),r=Kc(e);if(!n||!r)return $c(t,e);const i={...n};return t=>(i.red=zc(n.red,r.red,t),i.green=zc(n.green,r.green,t),i.blue=zc(n.blue,r.blue,t),i.alpha=Wc(n.alpha,r.alpha,t),Au.transform(i))},Yc=new Set(["none","hidden"]);function Qc(t,e){return n=>Wc(t,e,n)}function Xc(t){return"number"==typeof t?Qc:"string"==typeof t?$l(t)?$c:Fu.test(t)?Gc:td:Array.isArray(t)?Zc:"object"==typeof t?Fu.test(t)?Gc:Jc:$c}function Zc(t,e){const n=[...t],r=n.length,i=t.map(((t,n)=>Xc(t)(t,e[n])));return t=>{for(let e=0;e<r;e++)n[e]=i[e](t);return n}}function Jc(t,e){const n={...t,...e},r={};for(const i in n)void 0!==t[i]&&void 0!==e[i]&&(r[i]=Xc(t[i])(t[i],e[i]));return t=>{for(const e in r)n[e]=r[e](t);return n}}const td=(t,e)=>{const n=Hu.createTransformer(e),r=Bu(t),i=Bu(e);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Yc.has(t)&&!i.values.length||Yc.has(e)&&!r.values.length?function(t,e){return Yc.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}(t,e):Nc(Zc(function(t,e){var n;const r=[],i={color:0,var:0,number:0};for(let o=0;o<e.values.length;o++){const s=e.types[o],a=t.indexes[s][i[s]],l=null!==(n=t.values[a])&&void 0!==n?n:0;r[o]=l,i[s]++}return r}(r,i),i.values),n):$c(t,e)};function ed(t,e,n){if("number"==typeof t&&"number"==typeof e&&"number"==typeof n)return Wc(t,e,n);return Xc(t)(t,e)}function nd(t,e,{clamp:n=!0,ease:r,mixer:i}={}){const o=t.length;if(Bl(o===e.length),1===o)return()=>e[0];if(2===o&&t[0]===t[1])return()=>e[1];t[0]>t[o-1]&&(t=[...t].reverse(),e=[...e].reverse());const s=function(t,e,n){const r=[],i=n||ed,o=t.length-1;for(let s=0;s<o;s++){let n=i(t[s],t[s+1]);if(e){const t=Array.isArray(e)?e[s]||Ol:e;n=Nc(t,n)}r.push(n)}return r}(e,r,i),a=s.length,l=e=>{let n=0;if(a>1)for(;n<t.length-2&&!(e<t[n+1]);n++);const r=Uc(t[n],t[n+1],e);return s[n](r)};return n?e=>l(Gl(t[0],t[o-1],e)):l}function rd(t){const e=[0];return function(t,e){const n=t[t.length-1];for(let r=1;r<=e;r++){const i=Uc(0,e,r);t.push(Wc(n,1,i))}}(e,t.length-1),e}function id({duration:t=300,keyframes:e,times:n,ease:r="easeInOut"}){const i=(t=>Array.isArray(t)&&"number"!=typeof t[0])(r)?r.map(Ic):Ic(r),o={done:!1,value:e[0]},s=function(t,e){return t.map((t=>t*e))}(n&&n.length===e.length?n:rd(e),t),a=nd(s,e,{ease:Array.isArray(i)?i:(l=e,u=i,l.map((()=>u||Ac)).splice(0,l.length-1))});var l,u;return{calculatedDuration:t,next:e=>(o.value=a(e),o.done=e>=t,o)}}const od=t=>{const e=({timestamp:e})=>t(e);return{start:()=>Ml.update(e,!0),stop:()=>Dl(e),now:()=>Vl.isProcessing?Vl.timestamp:ic.now()}},sd={decay:_c,inertia:_c,tween:id,keyframes:id,spring:xc},ad=t=>t/100;class ld extends sc{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.teardown();const{onStop:t}=this.options;t&&t()};const{name:e,motionValue:n,element:r,keyframes:i}=this.options,o=(null==r?void 0:r.KeyframeResolver)||ku;this.resolver=new o(i,((t,e)=>this.onKeyframesResolved(t,e)),e,n,r),this.resolver.scheduleResolve()}initPlayback(t){const{type:e="keyframes",repeat:n=0,repeatDelay:r=0,repeatType:i,velocity:o=0}=this.options,s=sd[e]||id;let a,l;s!==id&&"number"!=typeof t[0]&&(a=Nc(ad,ed(t[0],t[1])),t=[0,100]);const u=s({...this.options,keyframes:t});"mirror"===i&&(l=s({...this.options,keyframes:[...t].reverse(),velocity:-o})),null===u.calculatedDuration&&(u.calculatedDuration=function(t){let e=0,n=t.next(e);for(;!n.done&&e<2e4;)e+=50,n=t.next(e);return e>=2e4?1/0:e}(u));const{calculatedDuration:c}=u,d=c+r;return{generator:u,mirroredGenerator:l,mapPercentToKeyframes:a,calculatedDuration:c,resolvedDuration:d,totalDuration:d*(n+1)-r}}onPostResolved(){const{autoplay:t=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&t?this.state=this.pendingPlayState:this.pause()}tick(t,e=!1){const{resolved:n}=this;if(!n){const{keyframes:t}=this.options;return{done:!0,value:t[t.length-1]}}const{finalKeyframe:r,generator:i,mirroredGenerator:o,mapPercentToKeyframes:s,keyframes:a,calculatedDuration:l,totalDuration:u,resolvedDuration:c}=n;if(null===this.startTime)return i.next(0);const{delay:d,repeat:h,repeatType:p,repeatDelay:f,onUpdate:m}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-u/this.speed,this.startTime)),e?this.currentTime=t:null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;const v=this.currentTime-d*(this.speed>=0?1:-1),g=this.speed>=0?v<0:v>u;this.currentTime=Math.max(v,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=u);let y=this.currentTime,b=i;if(h){const t=Math.min(this.currentTime,u)/c;let e=Math.floor(t),n=t%1;!n&&t>=1&&(n=1),1===n&&e--,e=Math.min(e,h+1);Boolean(e%2)&&("reverse"===p?(n=1-n,f&&(n-=f/c)):"mirror"===p&&(b=o)),y=Gl(0,1,n)*c}const w=g?{done:!1,value:a[0]}:b.next(y);s&&(w.value=s(w.value));let{done:x}=w;g||null===l||(x=this.speed>=0?this.currentTime>=u:this.currentTime<=0);const _=null===this.holdTime&&("finished"===this.state||"running"===this.state&&x);return _&&void 0!==r&&(w.value=Rl(a,this.options,r)),m&&m(w.value),_&&this.finish(),w}get duration(){const{resolved:t}=this;return t?_l(t.calculatedDuration):0}get time(){return _l(this.currentTime)}set time(t){t=xl(t),this.currentTime=t,null!==this.holdTime||0===this.speed?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){const e=this.playbackSpeed!==t;this.playbackSpeed=t,e&&(this.time=_l(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved)return void(this.pendingPlayState="running");if(this.isStopped)return;const{driver:t=od,onPlay:e,startTime:n}=this.options;this.driver||(this.driver=t((t=>this.tick(t)))),e&&e();const r=this.driver.now();null!==this.holdTime?this.startTime=r-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=r):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;this._resolved?(this.state="paused",this.holdTime=null!==(t=this.currentTime)&&void 0!==t?t:0):this.pendingPlayState="paused"}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:t}=this.options;t&&t()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}}const ud=new Set(["opacity","clipPath","filter","transform"]),cd=t=>Array.isArray(t)&&"number"==typeof t[0];function dd(t){return Boolean(!t||"string"==typeof t&&t in pd||cd(t)||Array.isArray(t)&&t.every(dd))}const hd=([t,e,n,r])=>`cubic-bezier(${t}, ${e}, ${n}, ${r})`,pd={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:hd([0,.65,.55,1]),circOut:hd([.55,0,1,.45]),backIn:hd([.31,.01,.66,-.59]),backOut:hd([.33,1.53,.69,.99])};function fd(t){return md(t)||pd.easeOut}function md(t){return t?cd(t)?hd(t):Array.isArray(t)?t.map(fd):pd[t]:void 0}const vd=ec((()=>Object.hasOwnProperty.call(Element.prototype,"animate")));class gd extends sc{constructor(t){super(t);const{name:e,motionValue:n,element:r,keyframes:i}=this.options;this.resolver=new tc(i,((t,e)=>this.onKeyframesResolved(t,e)),e,n,r),this.resolver.scheduleResolve()}initPlayback(t,e){var n;let{duration:r=300,times:i,ease:o,type:s,motionValue:a,name:l,startTime:u}=this.options;if(!(null===(n=a.owner)||void 0===n?void 0:n.current))return!1;if("spring"===(c=this.options).type||!dd(c.ease)){const{onComplete:e,onUpdate:n,motionValue:a,element:l,...u}=this.options,c=function(t,e){const n=new ld({...e,keyframes:t,repeat:0,delay:0,isGenerator:!0});let r={done:!1,value:t[0]};const i=[];let o=0;for(;!r.done&&o<2e4;)r=n.sample(o),i.push(r.value),o+=10;return{times:void 0,keyframes:i,duration:o-10,ease:"linear"}}(t,u);1===(t=c.keyframes).length&&(t[1]=t[0]),r=c.duration,i=c.times,o=c.ease,s="keyframes"}var c;const d=function(t,e,n,{delay:r=0,duration:i=300,repeat:o=0,repeatType:s="loop",ease:a,times:l}={}){const u={[e]:n};l&&(u.offset=l);const c=md(a);return Array.isArray(c)&&(u.easing=c),t.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:o+1,direction:"reverse"===s?"alternate":"normal"})}(a.owner.current,l,t,{...this.options,duration:r,times:i,ease:o});return d.startTime=null!=u?u:this.calcStartTime(),this.pendingTimeline?(d.timeline=this.pendingTimeline,this.pendingTimeline=void 0):d.onfinish=()=>{const{onComplete:n}=this.options;a.set(Rl(t,this.options,e)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:r,times:i,type:s,ease:o,keyframes:t}}get duration(){const{resolved:t}=this;if(!t)return 0;const{duration:e}=t;return _l(e)}get time(){const{resolved:t}=this;if(!t)return 0;const{animation:e}=t;return _l(e.currentTime||0)}set time(t){const{resolved:e}=this;if(!e)return;const{animation:n}=e;n.currentTime=xl(t)}get speed(){const{resolved:t}=this;if(!t)return 1;const{animation:e}=t;return e.playbackRate}set speed(t){const{resolved:e}=this;if(!e)return;const{animation:n}=e;n.playbackRate=t}get state(){const{resolved:t}=this;if(!t)return"idle";const{animation:e}=t;return e.playState}get startTime(){const{resolved:t}=this;if(!t)return null;const{animation:e}=t;return e.startTime}attachTimeline(t){if(this._resolved){const{resolved:e}=this;if(!e)return Ol;const{animation:n}=e;n.timeline=t,n.onfinish=null}else this.pendingTimeline=t;return Ol}play(){if(this.isStopped)return;const{resolved:t}=this;if(!t)return;const{animation:e}=t;"finished"===e.playState&&this.updateFinishedPromise(),e.play()}pause(){const{resolved:t}=this;if(!t)return;const{animation:e}=t;e.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:t}=this;if(!t)return;const{animation:e,keyframes:n,duration:r,type:i,ease:o,times:s}=t;if("idle"===e.playState||"finished"===e.playState)return;if(this.time){const{motionValue:t,onUpdate:e,onComplete:a,element:l,...u}=this.options,c=new ld({...u,keyframes:n,duration:r,type:i,ease:o,times:s,isGenerator:!0}),d=xl(this.time);t.setWithVelocity(c.sample(d-10).value,c.sample(d).value,10)}const{onStop:a}=this.options;a&&a(),this.cancel()}complete(){const{resolved:t}=this;t&&t.animation.finish()}cancel(){const{resolved:t}=this;t&&t.animation.cancel()}static supports(t){const{motionValue:e,name:n,repeatDelay:r,repeatType:i,damping:o,type:s}=t;return vd()&&n&&ud.has(n)&&e&&e.owner&&e.owner.current instanceof HTMLElement&&!e.owner.getProps().onUpdate&&!r&&"mirror"!==i&&0!==o&&"inertia"!==s}}const yd=ec((()=>void 0!==window.ScrollTimeline));class bd{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}then(t,e){return Promise.all(this.animations).then(t).catch(e)}getAll(t){return this.animations[0][t]}setAll(t,e){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=e}attachTimeline(t){const e=this.animations.map((e=>{if(!yd()||!e.attachTimeline)return e.pause(),function(t,e){let n;const r=()=>{const{currentTime:r}=e,i=(null===r?0:r.value)/100;n!==i&&t(i),n=i};return Ml.update(r,!0),()=>Dl(r)}((t=>{e.time=e.duration*t}),t);e.attachTimeline(t)}));return()=>{e.forEach(((t,e)=>{t&&t(),this.animations[e].stop()}))}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let e=0;e<this.animations.length;e++)t=Math.max(t,this.animations[e].duration);return t}runAll(t){this.animations.forEach((e=>e[t]()))}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}const wd=(t,e,n,r={},i,o,s)=>a=>{const l=Tl(r,t)||{},u=l.delay||r.delay||0;let{elapsed:c=0}=r;c-=xl(u);let d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity(),...l,delay:-c,onUpdate:t=>{e.set(t),l.onUpdate&&l.onUpdate(t)},onComplete:()=>{a(),l.onComplete&&l.onComplete(),s&&s()},onStop:s,name:t,motionValue:e,element:o?void 0:i};(function({when:t,delay:e,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:s,repeatDelay:a,from:l,elapsed:u,...c}){return!!Object.keys(c).length})(l)||(d={...d,...Pl(t,d)}),d.duration&&(d.duration=xl(d.duration)),d.repeatDelay&&(d.repeatDelay=xl(d.repeatDelay)),void 0!==d.from&&(d.keyframes[0]=d.from);let h=!1;if((!1===d.type||0===d.duration&&!d.repeatDelay)&&(d.duration=0,0===d.delay&&(h=!0)),h&&!o&&void 0!==e.get()){const t=Rl(d.keyframes,l);if(void 0!==t)return Ml.update((()=>{d.onUpdate(t),d.onComplete()})),new bd([])}return!o&&gd.supports(d)?new gd(d):new ld(d)},xd=t=>Boolean(t&&"object"==typeof t&&t.mix&&t.toValue),_d=t=>dl(t)?t[t.length-1]||0:t;function Sd(t,e){-1===t.indexOf(e)&&t.push(e)}function Ed(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}class kd{constructor(){this.subscriptions=[]}add(t){return Sd(this.subscriptions,t),()=>Ed(this.subscriptions,t)}notify(t,e,n){const r=this.subscriptions.length;if(r)if(1===r)this.subscriptions[0](t,e,n);else for(let i=0;i<r;i++){const r=this.subscriptions[i];r&&r(t,e,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}class Pd{constructor(t,e={}){this.version="11.5.4",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(t,e=!0)=>{const n=ic.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(t),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),e&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=e.owner}setCurrent(t){var e;this.current=t,this.updatedAt=ic.now(),null===this.canTrackVelocity&&void 0!==t&&(this.canTrackVelocity=(e=this.current,!isNaN(parseFloat(e))))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,e){this.events[t]||(this.events[t]=new kd);const n=this.events[t].add(e);return"change"===t?()=>{n(),Ml.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,e){this.passiveEffect=t,this.stopPassiveEffect=e}set(t,e=!0){e&&this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t,e)}setWithVelocity(t,e,n){this.set(e),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,e=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,e&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=ic.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||t-this.updatedAt>30)return 0;const e=Math.min(this.updatedAt-this.prevUpdatedAt,30);return ac(parseFloat(this.current)-parseFloat(this.prevFrameValue),e)}start(t){return this.stop(),new Promise((e=>{this.hasAnimated=!0,this.animation=t(e),this.events.animationStart&&this.events.animationStart.notify()})).then((()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()}))}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Td(t,e){return new Pd(t,e)}function Cd(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,Td(n))}const Ad=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Rd="data-"+Ad("framerAppearId");function Od(t){return t.props[Rd]}function Fd(t){return wl.has(t)?"transform":ud.has(t)?Ad(t):void 0}class Ld extends Pd{constructor(){super(...arguments),this.output=[],this.counts=new Map}add(t){const e=Fd(t);if(!e)return;const n=this.counts.get(e)||0;this.counts.set(e,n+1),0===n&&(this.output.push(e),this.update());let r=!1;return()=>{if(r)return;r=!0;const t=this.counts.get(e)-1;this.counts.set(e,t),0===t&&(Ed(this.output,e),this.update())}}update(){this.set(this.output.length?this.output.join(", "):"auto")}}const Md=t=>Boolean(t&&t.getVelocity);function Dd(t,e){var n;if(!t.applyWillChange)return;let r=t.getValue("willChange");return r||(null===(n=t.props.style)||void 0===n?void 0:n.willChange)||(r=new Ld("auto"),t.addValue("willChange",r)),i=r,Boolean(Md(i)&&i.add)?r.add(e):void 0;var i}function Vd({protectedKeys:t,needsAnimating:e},n){const r=t.hasOwnProperty(n)&&!0!==e[n];return e[n]=!1,r}function jd(t,e,{delay:n=0,transitionOverride:r,type:i}={}){var o;let{transition:s=t.getDefaultTransition(),transitionEnd:a,...l}=e;r&&(s=r);const u=[],c=i&&t.animationState&&t.animationState.getState()[i];for(const d in l){const e=t.getValue(d,null!==(o=t.latestValues[d])&&void 0!==o?o:null),r=l[d];if(void 0===r||c&&Vd(c,d))continue;const i={delay:n,...Tl(s||{},d)};let a=!1;if(window.MotionHandoffAnimation){const e=Od(t);if(e){const t=window.MotionHandoffAnimation(e,d,Ml);null!==t&&(i.startTime=t,a=!0)}}e.start(wd(d,e,r,t.shouldReduceMotion&&wl.has(d)?{type:!1}:i,t,a,Dd(t,d)));const h=e.animation;h&&u.push(h)}return a&&Promise.all(u).then((()=>{Ml.update((()=>{a&&function(t,e){const n=vl(t,e);let{transitionEnd:r={},transition:i={},...o}=n||{};o={...o,...r};for(const s in o)Cd(t,s,_d(o[s]))}(t,a)}))})),u}function Id(t,e,n={}){var r;const i=vl(t,e,"exit"===n.type?null===(r=t.presenceContext)||void 0===r?void 0:r.custom:void 0);let{transition:o=t.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(o=n.transitionOverride);const s=i?()=>Promise.all(jd(t,i,n)):()=>Promise.resolve(),a=t.variantChildren&&t.variantChildren.size?(r=0)=>{const{delayChildren:i=0,staggerChildren:s,staggerDirection:a}=o;return function(t,e,n=0,r=0,i=1,o){const s=[],a=(t.variantChildren.size-1)*r,l=1===i?(t=0)=>t*r:(t=0)=>a-t*r;return Array.from(t.variantChildren).sort(Bd).forEach(((t,r)=>{t.notify("AnimationStart",e),s.push(Id(t,e,{...o,delay:n+l(r)}).then((()=>t.notify("AnimationComplete",e))))})),Promise.all(s)}(t,e,i+r,s,a,n)}:()=>Promise.resolve(),{when:l}=o;if(l){const[t,e]="beforeChildren"===l?[s,a]:[a,s];return t().then((()=>e()))}return Promise.all([s(),a(n.delay)])}function Bd(t,e){return t.sortNodePosition(e)}const Nd=[...gl].reverse(),Ud=gl.length;function Wd(t){return e=>Promise.all(e.map((({animation:e,options:n})=>function(t,e,n={}){let r;if(t.notify("AnimationStart",e),Array.isArray(e)){const i=e.map((e=>Id(t,e,n)));r=Promise.all(i)}else if("string"==typeof e)r=Id(t,e,n);else{const i="function"==typeof e?vl(t,e,n.custom):e;r=Promise.all(jd(t,i,n))}return r.then((()=>{t.notify("AnimationComplete",e)}))}(t,e,n))))}function Hd(t,e){return"string"==typeof e?e!==t:!!Array.isArray(e)&&!hl(e,t)}function $d(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function zd(){return{animate:$d(!0),whileInView:$d(),whileHover:$d(),whileTap:$d(),whileDrag:$d(),whileFocus:$d(),exit:$d()}}class qd{constructor(t){this.isMounted=!1,this.node=t}update(){}}let Kd=0;const Gd={animation:{Feature:class extends qd{constructor(t){super(t),t.animationState||(t.animationState=function(t){let e=Wd(t),n=zd(),r=!0;const i=e=>(n,r)=>{var i;const o=vl(t,r,"exit"===e?null===(i=t.presenceContext)||void 0===i?void 0:i.custom:void 0);if(o){const{transition:t,transitionEnd:e,...r}=o;n={...n,...r,...e}}return n};function o(o){const s=t.getProps(),a=t.getVariantContext(!0)||{},l=[],u=new Set;let c={},d=1/0;for(let e=0;e<Ud;e++){const h=Nd[e],p=n[h],f=void 0!==s[h]?s[h]:a[h],m=pl(f),v=h===o?p.isActive:null;!1===v&&(d=e);let g=f===a[h]&&f!==s[h]&&m;if(g&&r&&t.manuallyAnimateOnMount&&(g=!1),p.protectedKeys={...c},!p.isActive&&null===v||!f&&!p.prevProp||cl(f)||"boolean"==typeof f)continue;let y=Hd(p.prevProp,f)||h===o&&p.isActive&&!g&&m||e>d&&m,b=!1;const w=Array.isArray(f)?f:[f];let x=w.reduce(i(h),{});!1===v&&(x={});const{prevResolvedValues:_={}}=p,S={..._,...x},E=e=>{y=!0,u.has(e)&&(b=!0,u.delete(e)),p.needsAnimating[e]=!0;const n=t.getValue(e);n&&(n.liveStyle=!1)};for(const t in S){const e=x[t],n=_[t];if(c.hasOwnProperty(t))continue;let r=!1;r=dl(e)&&dl(n)?!hl(e,n):e!==n,r?null!=e?E(t):u.add(t):void 0!==e&&u.has(t)?E(t):p.protectedKeys[t]=!0}p.prevProp=f,p.prevResolvedValues=x,p.isActive&&(c={...c,...x}),r&&t.blockInitialAnimation&&(y=!1),!y||g&&!b||l.push(...w.map((t=>({animation:t,options:{type:h}}))))}if(u.size){const e={};u.forEach((n=>{const r=t.getBaseTarget(n),i=t.getValue(n);i&&(i.liveStyle=!0),e[n]=null!=r?r:null})),l.push({animation:e})}let h=Boolean(l.length);return!r||!1!==s.initial&&s.initial!==s.animate||t.manuallyAnimateOnMount||(h=!1),r=!1,h?e(l):Promise.resolve()}return{animateChanges:o,setActive:function(e,r){var i;if(n[e].isActive===r)return Promise.resolve();null===(i=t.variantChildren)||void 0===i||i.forEach((t=>{var n;return null===(n=t.animationState)||void 0===n?void 0:n.setActive(e,r)})),n[e].isActive=r;const s=o(e);for(const t in n)n[t].protectedKeys={};return s},setAnimateFunction:function(n){e=n(t)},getState:()=>n,reset:()=>{n=zd(),r=!0}}}(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();cl(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:e}=this.node.prevProps||{};t!==e&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),null===(t=this.unmountControls)||void 0===t||t.call(this)}}},exit:{Feature:class extends qd{constructor(){super(...arguments),this.id=Kd++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:e}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===n)return;const r=this.node.animationState.setActive("exit",!t);e&&!t&&r.then((()=>e(this.id)))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}}},Yd=t=>"mouse"===t.pointerType?"number"!=typeof t.button||t.button<=0:!1!==t.isPrimary;function Qd(t,e="page"){return{point:{x:t[`${e}X`],y:t[`${e}Y`]}}}const Xd=t=>e=>Yd(e)&&t(e,Qd(e));function Zd(t,e,n,r={passive:!0}){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n)}function Jd(t,e,n,r){return Zd(t,e,Xd(n),r)}const th=(t,e)=>Math.abs(t-e);class eh{constructor(t,e,{transformPagePoint:n,contextWindow:r,dragSnapToOrigin:i=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!this.lastMoveEvent||!this.lastMoveEventInfo)return;const t=ih(this.lastMoveEventInfo,this.history),e=null!==this.startEvent,n=function(t,e){const n=th(t.x,e.x),r=th(t.y,e.y);return Math.sqrt(n**2+r**2)}(t.offset,{x:0,y:0})>=3;if(!e&&!n)return;const{point:r}=t,{timestamp:i}=Vl;this.history.push({...r,timestamp:i});const{onStart:o,onMove:s}=this.handlers;e||(o&&o(this.lastMoveEvent,t),this.startEvent=this.lastMoveEvent),s&&s(this.lastMoveEvent,t)},this.handlePointerMove=(t,e)=>{this.lastMoveEvent=t,this.lastMoveEventInfo=nh(e,this.transformPagePoint),Ml.update(this.updatePoint,!0)},this.handlePointerUp=(t,e)=>{this.end();const{onEnd:n,onSessionEnd:r,resumeAnimation:i}=this.handlers;if(this.dragSnapToOrigin&&i&&i(),!this.lastMoveEvent||!this.lastMoveEventInfo)return;const o=ih("pointercancel"===t.type?this.lastMoveEventInfo:nh(e,this.transformPagePoint),this.history);this.startEvent&&n&&n(t,o),r&&r(t,o)},!Yd(t))return;this.dragSnapToOrigin=i,this.handlers=e,this.transformPagePoint=n,this.contextWindow=r||window;const o=nh(Qd(t),this.transformPagePoint),{point:s}=o,{timestamp:a}=Vl;this.history=[{...s,timestamp:a}];const{onSessionStart:l}=e;l&&l(t,ih(o,this.history)),this.removeListeners=Nc(Jd(this.contextWindow,"pointermove",this.handlePointerMove),Jd(this.contextWindow,"pointerup",this.handlePointerUp),Jd(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Dl(this.updatePoint)}}function nh(t,e){return e?{point:e(t.point)}:t}function rh(t,e){return{x:t.x-e.x,y:t.y-e.y}}function ih({point:t},e){return{point:t,delta:rh(t,sh(e)),offset:rh(t,oh(e)),velocity:ah(e,.1)}}function oh(t){return t[0]}function sh(t){return t[t.length-1]}function ah(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,r=null;const i=sh(t);for(;n>=0&&(r=t[n],!(i.timestamp-r.timestamp>xl(e)));)n--;if(!r)return{x:0,y:0};const o=_l(i.timestamp-r.timestamp);if(0===o)return{x:0,y:0};const s={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function lh(t){let e=null;return()=>{const n=()=>{e=null};return null===e&&(e=t,n)}}const uh=lh("dragHorizontal"),ch=lh("dragVertical");function dh(t){let e=!1;if("y"===t)e=ch();else if("x"===t)e=uh();else{const t=uh(),n=ch();t&&n?e=()=>{t(),n()}:(t&&t(),n&&n())}return e}function hh(){const t=dh(!0);return!t||(t(),!1)}function ph(t){return t&&"object"==typeof t&&Object.prototype.hasOwnProperty.call(t,"current")}const fh=.9999,mh=1.0001,vh=-.01,gh=.01;function yh(t){return t.max-t.min}function bh(t,e,n,r=.5){t.origin=r,t.originPoint=Wc(e.min,e.max,t.origin),t.scale=yh(n)/yh(e),t.translate=Wc(n.min,n.max,t.origin)-t.originPoint,(t.scale>=fh&&t.scale<=mh||isNaN(t.scale))&&(t.scale=1),(t.translate>=vh&&t.translate<=gh||isNaN(t.translate))&&(t.translate=0)}function wh(t,e,n,r){bh(t.x,e.x,n.x,r?r.originX:void 0),bh(t.y,e.y,n.y,r?r.originY:void 0)}function xh(t,e,n){t.min=n.min+e.min,t.max=t.min+yh(e)}function _h(t,e,n){t.min=e.min-n.min,t.max=t.min+yh(e)}function Sh(t,e,n){_h(t.x,e.x,n.x),_h(t.y,e.y,n.y)}function Eh(t,e,n){return{min:void 0!==e?t.min+e:void 0,max:void 0!==n?t.max+n-(t.max-t.min):void 0}}function kh(t,e){let n=e.min-t.min,r=e.max-t.max;return e.max-e.min<t.max-t.min&&([n,r]=[r,n]),{min:n,max:r}}const Ph=.35;function Th(t,e,n){return{min:Ch(t,e),max:Ch(t,n)}}function Ch(t,e){return"number"==typeof t?t:t[e]||0}const Ah=()=>({x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}}),Rh=()=>({x:{min:0,max:0},y:{min:0,max:0}});function Oh(t){return[t("x"),t("y")]}function Fh({top:t,left:e,right:n,bottom:r}){return{x:{min:e,max:n},y:{min:t,max:r}}}function Lh(t){return void 0===t||1===t}function Mh({scale:t,scaleX:e,scaleY:n}){return!Lh(t)||!Lh(e)||!Lh(n)}function Dh(t){return Mh(t)||Vh(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function Vh(t){return jh(t.x)||jh(t.y)}function jh(t){return t&&"0%"!==t}function Ih(t,e,n){return n+e*(t-n)}function Bh(t,e,n,r,i){return void 0!==i&&(t=Ih(t,i,r)),Ih(t,n,r)+e}function Nh(t,e=0,n=1,r,i){t.min=Bh(t.min,e,n,r,i),t.max=Bh(t.max,e,n,r,i)}function Uh(t,{x:e,y:n}){Nh(t.x,e.translate,e.scale,e.originPoint),Nh(t.y,n.translate,n.scale,n.originPoint)}const Wh=.999999999999,Hh=1.0000000000001;function $h(t,e){t.min=t.min+e,t.max=t.max+e}function zh(t,e,n,r,i=.5){Nh(t,e,n,Wc(t.min,t.max,i),r)}function qh(t,e){zh(t.x,e.x,e.scaleX,e.scale,e.originX),zh(t.y,e.y,e.scaleY,e.scale,e.originY)}function Kh(t,e){return Fh(function(t,e){if(!e)return t;const n=e({x:t.left,y:t.top}),r=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(t.getBoundingClientRect(),e))}const Gh=({current:t})=>t?t.ownerDocument.defaultView:null,Yh=new WeakMap;class Qh{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Rh(),this.visualElement=t}start(t,{snapToCursor:e=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;const{dragSnapToOrigin:r}=this.getProps();this.panSession=new eh(t,{onSessionStart:t=>{const{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),e&&this.snapToCursor(Qd(t,"page").point)},onStart:(t,e)=>{var n;const{drag:r,dragPropagation:i,onDragStart:o}=this.getProps();if(r&&!i&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=dh(r),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Oh((t=>{let e=this.getAxisMotionValue(t).get()||0;if(ou.test(e)){const{projection:n}=this.visualElement;if(n&&n.layout){const r=n.layout.layoutBox[t];if(r){e=yh(r)*(parseFloat(e)/100)}}}this.originPoint[t]=e})),o&&Ml.postRender((()=>o(t,e))),null===(n=this.removeWillChange)||void 0===n||n.call(this),this.removeWillChange=Dd(this.visualElement,"transform");const{animationState:s}=this.visualElement;s&&s.setActive("whileDrag",!0)},onMove:(t,e)=>{const{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:o}=this.getProps();if(!n&&!this.openGlobalLock)return;const{offset:s}=e;if(r&&null===this.currentDirection)return this.currentDirection=function(t,e=10){let n=null;Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x");return n}(s),void(null!==this.currentDirection&&i&&i(this.currentDirection));this.updateAxis("x",e.point,s),this.updateAxis("y",e.point,s),this.visualElement.render(),o&&o(t,e)},onSessionEnd:(t,e)=>this.stop(t,e),resumeAnimation:()=>Oh((t=>{var e;return"paused"===this.getAnimationState(t)&&(null===(e=this.getAxisMotionValue(t).animation)||void 0===e?void 0:e.play())}))},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:r,contextWindow:Gh(this.visualElement)})}stop(t,e){var n;null===(n=this.removeWillChange)||void 0===n||n.call(this);const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:i}=e;this.startAnimation(i);const{onDragEnd:o}=this.getProps();o&&Ml.postRender((()=>o(t,e)))}cancel(){this.isDragging=!1;const{projection:t,animationState:e}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),e&&e.setActive("whileDrag",!1)}updateAxis(t,e,n){const{drag:r}=this.getProps();if(!n||!Xh(t,r,this.currentDirection))return;const i=this.getAxisMotionValue(t);let o=this.originPoint[t]+n[t];this.constraints&&this.constraints[t]&&(o=function(t,{min:e,max:n},r){return void 0!==e&&t<e?t=r?Wc(e,t,r.min):Math.max(t,e):void 0!==n&&t>n&&(t=r?Wc(n,t,r.max):Math.min(t,n)),t}(o,this.constraints[t],this.elastic[t])),i.set(o)}resolveConstraints(){var t;const{dragConstraints:e,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null===(t=this.visualElement.projection)||void 0===t?void 0:t.layout,i=this.constraints;e&&ph(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):this.constraints=!(!e||!r)&&function(t,{top:e,left:n,bottom:r,right:i}){return{x:Eh(t.x,n,i),y:Eh(t.y,e,r)}}(r.layoutBox,e),this.elastic=function(t=Ph){return!1===t?t=0:!0===t&&(t=Ph),{x:Th(t,"left","right"),y:Th(t,"top","bottom")}}(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Oh((t=>{!1!==this.constraints&&this.getAxisMotionValue(t)&&(this.constraints[t]=function(t,e){const n={};return void 0!==e.min&&(n.min=e.min-t.min),void 0!==e.max&&(n.max=e.max-t.min),n}(r.layoutBox[t],this.constraints[t]))}))}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:e}=this.getProps();if(!t||!ph(t))return!1;const n=t.current,{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const i=function(t,e,n){const r=Kh(t,n),{scroll:i}=e;return i&&($h(r.x,i.offset.x),$h(r.y,i.offset.y)),r}(n,r.root,this.visualElement.getTransformPagePoint());let o=function(t,e){return{x:kh(t.x,e.x),y:kh(t.y,e.y)}}(r.layout.layoutBox,i);if(e){const t=e(function({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}(o));this.hasMutatedConstraints=!!t,t&&(o=Fh(t))}return o}startAnimation(t){const{drag:e,dragMomentum:n,dragElastic:r,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:s}=this.getProps(),a=this.constraints||{},l=Oh((s=>{if(!Xh(s,e,this.currentDirection))return;let l=a&&a[s]||{};o&&(l={min:0,max:0});const u=r?200:1e6,c=r?40:1e7,d={type:"inertia",velocity:n?t[s]:0,bounceStiffness:u,bounceDamping:c,timeConstant:750,restDelta:1,restSpeed:10,...i,...l};return this.startAxisValueAnimation(s,d)}));return Promise.all(l).then(s)}startAxisValueAnimation(t,e){const n=this.getAxisMotionValue(t);return n.start(wd(t,n,0,e,this.visualElement,!1,Dd(this.visualElement,t)))}stopAnimation(){Oh((t=>this.getAxisMotionValue(t).stop()))}pauseAnimation(){Oh((t=>{var e;return null===(e=this.getAxisMotionValue(t).animation)||void 0===e?void 0:e.pause()}))}getAnimationState(t){var e;return null===(e=this.getAxisMotionValue(t).animation)||void 0===e?void 0:e.state}getAxisMotionValue(t){const e=`_drag${t.toUpperCase()}`,n=this.visualElement.getProps(),r=n[e];return r||this.visualElement.getValue(t,(n.initial?n.initial[t]:void 0)||0)}snapToCursor(t){Oh((e=>{const{drag:n}=this.getProps();if(!Xh(e,n,this.currentDirection))return;const{projection:r}=this.visualElement,i=this.getAxisMotionValue(e);if(r&&r.layout){const{min:n,max:o}=r.layout.layoutBox[e];i.set(t[e]-Wc(n,o,.5))}}))}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:e}=this.getProps(),{projection:n}=this.visualElement;if(!ph(e)||!n||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};Oh((t=>{const e=this.getAxisMotionValue(t);if(e&&!1!==this.constraints){const n=e.get();r[t]=function(t,e){let n=.5;const r=yh(t),i=yh(e);return i>r?n=Uc(e.min,e.max-r,t.min):r>i&&(n=Uc(t.min,t.max-i,e.min)),Gl(0,1,n)}({min:n,max:n},this.constraints[t])}}));const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),Oh((e=>{if(!Xh(e,t,null))return;const n=this.getAxisMotionValue(e),{min:i,max:o}=this.constraints[e];n.set(Wc(i,o,r[e]))}))}addListeners(){if(!this.visualElement.current)return;Yh.set(this.visualElement,this);const t=Jd(this.visualElement.current,"pointerdown",(t=>{const{drag:e,dragListener:n=!0}=this.getProps();e&&n&&this.start(t)})),e=()=>{const{dragConstraints:t}=this.getProps();ph(t)&&t.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",e);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),Ml.read(e);const i=Zd(window,"resize",(()=>this.scalePositionWithinConstraints())),o=n.addEventListener("didUpdate",(({delta:t,hasLayoutChanged:e})=>{this.isDragging&&e&&(Oh((e=>{const n=this.getAxisMotionValue(e);n&&(this.originPoint[e]+=t[e].translate,n.set(n.get()+t[e].translate))})),this.visualElement.render())}));return()=>{i(),t(),r(),o&&o()}}getProps(){const t=this.visualElement.getProps(),{drag:e=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:o=Ph,dragMomentum:s=!0}=t;return{...t,drag:e,dragDirectionLock:n,dragPropagation:r,dragConstraints:i,dragElastic:o,dragMomentum:s}}}function Xh(t,e,n){return!(!0!==e&&e!==t||null!==n&&n!==t)}const Zh=t=>(e,n)=>{t&&Ml.postRender((()=>t(e,n)))};const Jh=fe(null);const tp=fe({}),ep=fe({}),np={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function rp(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}const ip={correct:(t,e)=>{if(!e.target)return t;if("string"==typeof t){if(!su.test(t))return t;t=parseFloat(t)}return`${rp(t,e.target.x)}% ${rp(t,e.target.y)}%`}},op={correct:(t,{treeScale:e,projectionDelta:n})=>{const r=t,i=Hu.parse(t);if(i.length>5)return r;const o=Hu.createTransformer(t),s="number"!=typeof i[0]?1:0,a=n.x.scale*e.x,l=n.y.scale*e.y;i[0+s]/=a,i[1+s]/=l;const u=Wc(a,l,.5);return"number"==typeof i[2+s]&&(i[2+s]/=u),"number"==typeof i[3+s]&&(i[3+s]/=u),o(i)}},sp={};const{schedule:ap,cancel:lp}=Ll(queueMicrotask,!1);class up extends Gt{componentDidMount(){const{visualElement:t,layoutGroup:e,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=t;var o;o=dp,Object.assign(sp,o),i&&(e.group&&e.group.add(i),n&&n.register&&r&&n.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",(()=>{this.safeToRemove()})),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),np.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:e,visualElement:n,drag:r,isPresent:i}=this.props,o=n.projection;return o?(o.isPresent=i,r||t.layoutDependency!==e||void 0===e?o.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?o.promote():o.relegate()||Ml.postRender((()=>{const t=o.getStack();t&&t.members.length||this.safeToRemove()}))),null):null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),ap.postRender((()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()})))}componentWillUnmount(){const{visualElement:t,layoutGroup:e,switchLayoutGroup:n}=this.props,{projection:r}=t;r&&(r.scheduleCheckAfterUnmount(),e&&e.group&&e.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function cp(t){const[e,n]=function(){const t=Gn(Jh);if(null===t)return[!0,null];const{isPresent:e,onExitComplete:n,register:r}=t,i=Qn();Wn((()=>r(i)),[]);const o=Kn((()=>n&&n(i)),[i,n]);return!e&&n?[!1,o]:[!0]}(),r=Gn(tp);return ho(up,{...t,layoutGroup:r,switchLayoutGroup:Gn(ep),isPresent:e,safeToRemove:n})}const dp={borderRadius:{...ip,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:ip,borderTopRightRadius:ip,borderBottomLeftRadius:ip,borderBottomRightRadius:ip,boxShadow:op},hp=["TopLeft","TopRight","BottomLeft","BottomRight"],pp=hp.length,fp=t=>"string"==typeof t?parseFloat(t):t,mp=t=>"number"==typeof t||su.test(t);function vp(t,e){return void 0!==t[e]?t[e]:t.borderRadius}const gp=bp(0,.5,Lc),yp=bp(.5,.95,Ol);function bp(t,e,n){return r=>r<t?0:r>e?1:n(Uc(t,e,r))}function wp(t,e){t.min=e.min,t.max=e.max}function xp(t,e){wp(t.x,e.x),wp(t.y,e.y)}function _p(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}function Sp(t,e,n,r,i){return t=Ih(t-=e,1/n,r),void 0!==i&&(t=Ih(t,1/i,r)),t}function Ep(t,e,[n,r,i],o,s){!function(t,e=0,n=1,r=.5,i,o=t,s=t){ou.test(e)&&(e=parseFloat(e),e=Wc(s.min,s.max,e/100)-s.min);if("number"!=typeof e)return;let a=Wc(o.min,o.max,r);t===o&&(a-=e),t.min=Sp(t.min,e,n,a,i),t.max=Sp(t.max,e,n,a,i)}(t,e[n],e[r],e[i],e.scale,o,s)}const kp=["x","scaleX","originX"],Pp=["y","scaleY","originY"];function Tp(t,e,n,r){Ep(t.x,e,kp,n?n.x:void 0,r?r.x:void 0),Ep(t.y,e,Pp,n?n.y:void 0,r?r.y:void 0)}function Cp(t){return 0===t.translate&&1===t.scale}function Ap(t){return Cp(t.x)&&Cp(t.y)}function Rp(t,e){return t.min===e.min&&t.max===e.max}function Op(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function Fp(t,e){return Op(t.x,e.x)&&Op(t.y,e.y)}function Lp(t){return yh(t.x)/yh(t.y)}function Mp(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}class Dp{constructor(){this.members=[]}add(t){Sd(this.members,t),t.scheduleRender()}remove(t){if(Ed(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const t=this.members[this.members.length-1];t&&this.promote(t)}}relegate(t){const e=this.members.findIndex((e=>t===e));if(0===e)return!1;let n;for(let r=e;r>=0;r--){const t=this.members[r];if(!1!==t.isPresent){n=t;break}}return!!n&&(this.promote(n),!0)}promote(t,e){const n=this.lead;if(t!==n&&(this.prevLead=n,this.lead=t,t.show(),n)){n.instance&&n.scheduleRender(),t.scheduleRender(),t.resumeFrom=n,e&&(t.resumeFrom.preserveOpacity=!0),n.snapshot&&(t.snapshot=n.snapshot,t.snapshot.latestValues=n.animationValues||n.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:r}=t.options;!1===r&&n.hide()}}exitAnimationComplete(){this.members.forEach((t=>{const{options:e,resumingFrom:n}=t;e.onExitComplete&&e.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()}))}scheduleRender(){this.members.forEach((t=>{t.instance&&t.scheduleRender(!1)}))}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const Vp=(t,e)=>t.depth-e.depth;class jp{constructor(){this.children=[],this.isDirty=!1}add(t){Sd(this.children,t),this.isDirty=!0}remove(t){Ed(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(Vp),this.isDirty=!1,this.children.forEach(t)}}function Ip(t){const e=Md(t)?t.get():t;return xd(e)?e.toValue():e}const Bp={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},Np="undefined"!=typeof window&&void 0!==window.MotionDebug,Up=["","X","Y","Z"],Wp={visibility:"hidden"};let Hp=0;function $p(t,e,n,r){const{latestValues:i}=e;i[t]&&(n[t]=i[t],e.setStaticValue(t,0),r&&(r[t]=0))}function zp(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;const{visualElement:e}=t.options;if(!e)return;const n=Od(e);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:e,layoutId:r}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",Ml,!(e||r))}const{parent:r}=t;r&&!r.hasCheckedOptimisedAppear&&zp(r)}function qp({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(t={},n=(null==e?void 0:e())){this.id=Hp++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,Np&&(Bp.totalNodes=Bp.resolvedTargetDeltas=Bp.recalculatedProjection=0),this.nodes.forEach(Yp),this.nodes.forEach(nf),this.nodes.forEach(rf),this.nodes.forEach(Qp),Np&&window.MotionDebug.record(Bp)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=t,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new jp)}addEventListener(t,e){return this.eventHandlers.has(t)||this.eventHandlers.set(t,new kd),this.eventHandlers.get(t).add(e)}notifyListeners(t,...e){const n=this.eventHandlers.get(t);n&&n.notify(...e)}hasListeners(t){return this.eventHandlers.has(t)}mount(e,n=this.root.hasTreeAnimated){if(this.instance)return;var r;this.isSVG=(r=e)instanceof SVGElement&&"svg"!==r.tagName,this.instance=e;const{layoutId:i,layout:o,visualElement:s}=this.options;if(s&&!s.current&&s.mount(e),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),n&&(o||i)&&(this.isLayoutDirty=!0),t){let n;const r=()=>this.root.updateBlockedByResize=!1;t(e,(()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(t,e){const n=ic.now(),r=({timestamp:i})=>{const o=i-n;o>=e&&(Dl(r),t(o-e))};return Ml.read(r,!0),()=>Dl(r)}(r,250),np.hasAnimatedSinceResize&&(np.hasAnimatedSinceResize=!1,this.nodes.forEach(ef))}))}i&&this.root.registerSharedNode(i,this),!1!==this.options.animate&&s&&(i||o)&&this.addEventListener("didUpdate",(({delta:t,hasLayoutChanged:e,hasRelativeTargetChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked())return this.target=void 0,void(this.relativeTarget=void 0);const i=this.options.transition||s.getDefaultTransition()||cf,{onLayoutAnimationStart:o,onLayoutAnimationComplete:a}=s.getProps(),l=!this.targetLayout||!Fp(this.targetLayout,r)||n,u=!e&&n;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||u||e&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(t,u);const e={...Tl(i,"layout"),onPlay:o,onComplete:a};(s.shouldReduceMotion||this.options.layoutRoot)&&(e.delay=0,e.type=!1),this.startAnimation(e)}else e||ef(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const t=this.getStack();t&&t.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Dl(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(of),this.animationId++)}getTransformTemplate(){const{visualElement:t}=this.options;return t&&t.getProps().transformTemplate}willUpdate(t=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked())return void(this.options.onExitComplete&&this.options.onExitComplete());if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&zp(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let i=0;i<this.path.length;i++){const t=this.path[i];t.shouldResetTransform=!0,t.updateScroll("snapshot"),t.options.layoutRoot&&t.willUpdate(!1)}const{layoutId:e,layout:n}=this.options;if(void 0===e&&!n)return;const r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,""):void 0,this.updateSnapshot(),t&&this.notifyListeners("willUpdate")}update(){this.updateScheduled=!1;if(this.isUpdateBlocked())return this.unblockUpdate(),this.clearAllSnapshots(),void this.nodes.forEach(Zp);this.isUpdating||this.nodes.forEach(Jp),this.isUpdating=!1,this.nodes.forEach(tf),this.nodes.forEach(Kp),this.nodes.forEach(Gp),this.clearAllSnapshots();const t=ic.now();Vl.delta=Gl(0,1e3/60,t-Vl.timestamp),Vl.timestamp=t,Vl.isProcessing=!0,jl.update.process(Vl),jl.preRender.process(Vl),jl.render.process(Vl),Vl.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,ap.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Xp),this.sharedNodes.forEach(sf)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,Ml.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){Ml.postRender((()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()}))}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure())}updateLayout(){if(!this.instance)return;if(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead()||this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let n=0;n<this.path.length;n++){this.path[n].updateScroll()}const t=this.layout;this.layout=this.measure(!1),this.layoutCorrected=Rh(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:e}=this.options;e&&e.notify("LayoutMeasure",this.layout.layoutBox,t?t.layoutBox:void 0)}updateScroll(t="measure"){let e=Boolean(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===t&&(e=!1),e){const e=r(this.instance);this.scroll={animationId:this.root.animationId,phase:t,isRoot:e,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:e}}}resetTransform(){if(!i)return;const t=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,e=this.projectionDelta&&!Ap(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,""):void 0,o=r!==this.prevTransformTemplateValue;t&&(e||Dh(this.latestValues)||o)&&(i(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(t=!0){const e=this.measurePageBox();let n=this.removeElementScroll(e);var r;return t&&(n=this.removeTransform(n)),pf((r=n).x),pf(r.y),{animationId:this.root.animationId,measuredBox:e,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){var t;const{visualElement:e}=this.options;if(!e)return Rh();const n=e.measureViewportBox();if(!((null===(t=this.scroll)||void 0===t?void 0:t.wasRoot)||this.path.some(mf))){const{scroll:t}=this.root;t&&($h(n.x,t.offset.x),$h(n.y,t.offset.y))}return n}removeElementScroll(t){var e;const n=Rh();if(xp(n,t),null===(e=this.scroll)||void 0===e?void 0:e.wasRoot)return n;for(let r=0;r<this.path.length;r++){const e=this.path[r],{scroll:i,options:o}=e;e!==this.root&&i&&o.layoutScroll&&(i.wasRoot&&xp(n,t),$h(n.x,i.offset.x),$h(n.y,i.offset.y))}return n}applyTransform(t,e=!1){const n=Rh();xp(n,t);for(let r=0;r<this.path.length;r++){const t=this.path[r];!e&&t.options.layoutScroll&&t.scroll&&t!==t.root&&qh(n,{x:-t.scroll.offset.x,y:-t.scroll.offset.y}),Dh(t.latestValues)&&qh(n,t.latestValues)}return Dh(this.latestValues)&&qh(n,this.latestValues),n}removeTransform(t){const e=Rh();xp(e,t);for(let n=0;n<this.path.length;n++){const t=this.path[n];if(!t.instance)continue;if(!Dh(t.latestValues))continue;Mh(t.latestValues)&&t.updateSnapshot();const r=Rh();xp(r,t.measurePageBox()),Tp(e,t.latestValues,t.snapshot?t.snapshot.layoutBox:void 0,r)}return Dh(this.latestValues)&&Tp(e,this.latestValues),e}setTargetDelta(t){this.targetDelta=t,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(t){this.options={...this.options,...t,crossfade:void 0===t.crossfade||t.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Vl.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(t=!1){var e;const n=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=n.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=n.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=n.isSharedProjectionDirty);const r=Boolean(this.resumingFrom)||this!==n;if(!(t||r&&this.isSharedProjectionDirty||this.isProjectionDirty||(null===(e=this.parent)||void 0===e?void 0:e.isProjectionDirty)||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:i,layoutId:o}=this.options;if(this.layout&&(i||o)){if(this.resolvedRelativeTargetAt=Vl.timestamp,!this.targetDelta&&!this.relativeTarget){const t=this.getClosestProjectingParent();t&&t.layout&&1!==this.animationProgress?(this.relativeParent=t,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Rh(),this.relativeTargetOrigin=Rh(),Sh(this.relativeTargetOrigin,this.layout.layoutBox,t.layout.layoutBox),xp(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(this.relativeTarget||this.targetDelta){var s,a,l;if(this.target||(this.target=Rh(),this.targetWithTransforms=Rh()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),s=this.target,a=this.relativeTarget,l=this.relativeParent.target,xh(s.x,a.x,l.x),xh(s.y,a.y,l.y)):this.targetDelta?(Boolean(this.resumingFrom)?this.target=this.applyTransform(this.layout.layoutBox):xp(this.target,this.layout.layoutBox),Uh(this.target,this.targetDelta)):xp(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const t=this.getClosestProjectingParent();t&&Boolean(t.resumingFrom)===Boolean(this.resumingFrom)&&!t.options.layoutScroll&&t.target&&1!==this.animationProgress?(this.relativeParent=t,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Rh(),this.relativeTargetOrigin=Rh(),Sh(this.relativeTargetOrigin,this.target,t.target),xp(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}Np&&Bp.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(this.parent&&!Mh(this.parent.latestValues)&&!Vh(this.parent.latestValues))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return Boolean((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var t;const e=this.getLead(),n=Boolean(this.resumingFrom)||this!==e;let r=!0;if((this.isProjectionDirty||(null===(t=this.parent)||void 0===t?void 0:t.isProjectionDirty))&&(r=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(r=!1),this.resolvedRelativeTargetAt===Vl.timestamp&&(r=!1),r)return;const{layout:i,layoutId:o}=this.options;if(this.isTreeAnimating=Boolean(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!i&&!o)return;xp(this.layoutCorrected,this.layout.layoutBox);const s=this.treeScale.x,a=this.treeScale.y;!function(t,e,n,r=!1){const i=n.length;if(!i)return;let o,s;e.x=e.y=1;for(let a=0;a<i;a++){o=n[a],s=o.projectionDelta;const{visualElement:i}=o.options;i&&i.props.style&&"contents"===i.props.style.display||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&qh(t,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),s&&(e.x*=s.x.scale,e.y*=s.y.scale,Uh(t,s)),r&&Dh(o.latestValues)&&qh(t,o.latestValues))}e.x<Hh&&e.x>Wh&&(e.x=1),e.y<Hh&&e.y>Wh&&(e.y=1)}(this.layoutCorrected,this.treeScale,this.path,n),!e.layout||e.target||1===this.treeScale.x&&1===this.treeScale.y||(e.target=e.layout.layoutBox,e.targetWithTransforms=Rh());const{target:l}=e;l?(this.projectionDelta&&this.prevProjectionDelta?(_p(this.prevProjectionDelta.x,this.projectionDelta.x),_p(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),wh(this.projectionDelta,this.layoutCorrected,l,this.latestValues),this.treeScale.x===s&&this.treeScale.y===a&&Mp(this.projectionDelta.x,this.prevProjectionDelta.x)&&Mp(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",l)),Np&&Bp.recalculatedProjection++):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(t=!0){var e;if(null===(e=this.options.visualElement)||void 0===e||e.scheduleRender(),t){const t=this.getStack();t&&t.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Ah(),this.projectionDelta=Ah(),this.projectionDeltaWithTransform=Ah()}setAnimationOrigin(t,e=!1){const n=this.snapshot,r=n?n.latestValues:{},i={...this.latestValues},o=Ah();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!e;const s=Rh(),a=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),l=this.getStack(),u=!l||l.members.length<=1,c=Boolean(a&&!u&&!0===this.options.crossfade&&!this.path.some(uf));let d;this.animationProgress=0,this.mixTargetDelta=e=>{const n=e/1e3;var l,h,p,f,m,v;af(o.x,t.x,n),af(o.y,t.y,n),this.setTargetDelta(o),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Sh(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox),p=this.relativeTarget,f=this.relativeTargetOrigin,m=s,v=n,lf(p.x,f.x,m.x,v),lf(p.y,f.y,m.y,v),d&&(l=this.relativeTarget,h=d,Rp(l.x,h.x)&&Rp(l.y,h.y))&&(this.isProjectionDirty=!1),d||(d=Rh()),xp(d,this.relativeTarget)),a&&(this.animationValues=i,function(t,e,n,r,i,o){i?(t.opacity=Wc(0,void 0!==n.opacity?n.opacity:1,gp(r)),t.opacityExit=Wc(void 0!==e.opacity?e.opacity:1,0,yp(r))):o&&(t.opacity=Wc(void 0!==e.opacity?e.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let s=0;s<pp;s++){const i=`border${hp[s]}Radius`;let o=vp(e,i),a=vp(n,i);void 0===o&&void 0===a||(o||(o=0),a||(a=0),0===o||0===a||mp(o)===mp(a)?(t[i]=Math.max(Wc(fp(o),fp(a),r),0),(ou.test(a)||ou.test(o))&&(t[i]+="%")):t[i]=a)}(e.rotate||n.rotate)&&(t.rotate=Wc(e.rotate||0,n.rotate||0,r))}(i,r,this.latestValues,n,c,u)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(t){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(Dl(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Ml.update((()=>{np.hasAnimatedSinceResize=!0,this.currentAnimation=function(t,e,n){const r=Md(t)?t:Td(t);return r.start(wd("",r,e,n)),r.animation}(0,1e3,{...t,onUpdate:e=>{this.mixTargetDelta(e),t.onUpdate&&t.onUpdate(e)},onComplete:()=>{t.onComplete&&t.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0}))}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const t=this.getStack();t&&t.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const t=this.getLead();let{targetWithTransforms:e,target:n,layout:r,latestValues:i}=t;if(e&&n&&r){if(this!==t&&this.layout&&r&&ff(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||Rh();const e=yh(this.layout.layoutBox.x);n.x.min=t.target.x.min,n.x.max=n.x.min+e;const r=yh(this.layout.layoutBox.y);n.y.min=t.target.y.min,n.y.max=n.y.min+r}xp(e,n),qh(e,i),wh(this.projectionDeltaWithTransform,this.layoutCorrected,e,i)}}registerSharedNode(t,e){this.sharedNodes.has(t)||this.sharedNodes.set(t,new Dp);this.sharedNodes.get(t).add(e);const n=e.options.initialPromotionConfig;e.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(e):void 0})}isLead(){const t=this.getStack();return!t||t.lead===this}getLead(){var t;const{layoutId:e}=this.options;return e&&(null===(t=this.getStack())||void 0===t?void 0:t.lead)||this}getPrevLead(){var t;const{layoutId:e}=this.options;return e?null===(t=this.getStack())||void 0===t?void 0:t.prevLead:void 0}getStack(){const{layoutId:t}=this.options;if(t)return this.root.sharedNodes.get(t)}promote({needsReset:t,transition:e,preserveFollowOpacity:n}={}){const r=this.getStack();r&&r.promote(this,n),t&&(this.projectionDelta=void 0,this.needsReset=!0),e&&this.setOptions({transition:e})}relegate(){const t=this.getStack();return!!t&&t.relegate(this)}resetSkewAndRotation(){const{visualElement:t}=this.options;if(!t)return;let e=!1;const{latestValues:n}=t;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(e=!0),!e)return;const r={};n.z&&$p("z",t,r,this.animationValues);for(let i=0;i<Up.length;i++)$p(`rotate${Up[i]}`,t,r,this.animationValues),$p(`skew${Up[i]}`,t,r,this.animationValues);t.render();for(const i in r)t.setStaticValue(i,r[i]),this.animationValues&&(this.animationValues[i]=r[i]);t.scheduleRender()}getProjectionStyles(t){var e,n;if(!this.instance||this.isSVG)return;if(!this.isVisible)return Wp;const r={visibility:""},i=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,r.opacity="",r.pointerEvents=Ip(null==t?void 0:t.pointerEvents)||"",r.transform=i?i(this.latestValues,""):"none",r;const o=this.getLead();if(!this.projectionDelta||!this.layout||!o.target){const e={};return this.options.layoutId&&(e.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,e.pointerEvents=Ip(null==t?void 0:t.pointerEvents)||""),this.hasProjected&&!Dh(this.latestValues)&&(e.transform=i?i({},""):"none",this.hasProjected=!1),e}const s=o.animationValues||o.latestValues;this.applyTransformsToTarget(),r.transform=function(t,e,n){let r="";const i=t.x.translate/e.x,o=t.y.translate/e.y,s=(null==n?void 0:n.z)||0;if((i||o||s)&&(r=`translate3d(${i}px, ${o}px, ${s}px) `),1===e.x&&1===e.y||(r+=`scale(${1/e.x}, ${1/e.y}) `),n){const{transformPerspective:t,rotate:e,rotateX:i,rotateY:o,skewX:s,skewY:a}=n;t&&(r=`perspective(${t}px) ${r}`),e&&(r+=`rotate(${e}deg) `),i&&(r+=`rotateX(${i}deg) `),o&&(r+=`rotateY(${o}deg) `),s&&(r+=`skewX(${s}deg) `),a&&(r+=`skewY(${a}deg) `)}const a=t.x.scale*e.x,l=t.y.scale*e.y;return 1===a&&1===l||(r+=`scale(${a}, ${l})`),r||"none"}(this.projectionDeltaWithTransform,this.treeScale,s),i&&(r.transform=i(s,r.transform));const{x:a,y:l}=this.projectionDelta;r.transformOrigin=`${100*a.origin}% ${100*l.origin}% 0`,o.animationValues?r.opacity=o===this?null!==(n=null!==(e=s.opacity)&&void 0!==e?e:this.latestValues.opacity)&&void 0!==n?n:1:this.preserveOpacity?this.latestValues.opacity:s.opacityExit:r.opacity=o===this?void 0!==s.opacity?s.opacity:"":void 0!==s.opacityExit?s.opacityExit:0;for(const u in sp){if(void 0===s[u])continue;const{correct:t,applyTo:e}=sp[u],n="none"===r.transform?s[u]:t(s[u],o);if(e){const t=e.length;for(let i=0;i<t;i++)r[e[i]]=n}else r[u]=n}return this.options.layoutId&&(r.pointerEvents=o===this?Ip(null==t?void 0:t.pointerEvents)||"":"none"),r}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach((t=>{var e;return null===(e=t.currentAnimation)||void 0===e?void 0:e.stop()})),this.root.nodes.forEach(Zp),this.root.sharedNodes.clear()}}}function Kp(t){t.updateLayout()}function Gp(t){var e;const n=(null===(e=t.resumeFrom)||void 0===e?void 0:e.snapshot)||t.snapshot;if(t.isLead()&&t.layout&&n&&t.hasListeners("didUpdate")){const{layoutBox:e,measuredBox:r}=t.layout,{animationType:i}=t.options,o=n.source!==t.layout.source;"size"===i?Oh((t=>{const r=o?n.measuredBox[t]:n.layoutBox[t],i=yh(r);r.min=e[t].min,r.max=r.min+i})):ff(i,n.layoutBox,e)&&Oh((r=>{const i=o?n.measuredBox[r]:n.layoutBox[r],s=yh(e[r]);i.max=i.min+s,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[r].max=t.relativeTarget[r].min+s)}));const s=Ah();wh(s,e,n.layoutBox);const a=Ah();o?wh(a,t.applyTransform(r,!0),n.measuredBox):wh(a,e,n.layoutBox);const l=!Ap(s);let u=!1;if(!t.resumeFrom){const r=t.getClosestProjectingParent();if(r&&!r.resumeFrom){const{snapshot:i,layout:o}=r;if(i&&o){const s=Rh();Sh(s,n.layoutBox,i.layoutBox);const a=Rh();Sh(a,e,o.layoutBox),Fp(s,a)||(u=!0),r.options.layoutRoot&&(t.relativeTarget=a,t.relativeTargetOrigin=s,t.relativeParent=r)}}}t.notifyListeners("didUpdate",{layout:e,snapshot:n,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeTargetChanged:u})}else if(t.isLead()){const{onExitComplete:e}=t.options;e&&e()}t.options.transition=void 0}function Yp(t){Np&&Bp.totalNodes++,t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=Boolean(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function Qp(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function Xp(t){t.clearSnapshot()}function Zp(t){t.clearMeasurements()}function Jp(t){t.isLayoutDirty=!1}function tf(t){const{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function ef(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function nf(t){t.resolveTargetDelta()}function rf(t){t.calcProjection()}function of(t){t.resetSkewAndRotation()}function sf(t){t.removeLeadSnapshot()}function af(t,e,n){t.translate=Wc(e.translate,0,n),t.scale=Wc(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function lf(t,e,n,r){t.min=Wc(e.min,n.min,r),t.max=Wc(e.max,n.max,r)}function uf(t){return t.animationValues&&void 0!==t.animationValues.opacityExit}const cf={duration:.45,ease:[.4,0,.1,1]},df=t=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),hf=df("applewebkit/")&&!df("chrome/")?Math.round:Ol;function pf(t){t.min=hf(t.min),t.max=hf(t.max)}function ff(t,e,n){return"position"===t||"preserve-aspect"===t&&(r=Lp(e),i=Lp(n),o=.2,!(Math.abs(r-i)<=o));var r,i,o}function mf(t){var e;return t!==t.root&&(null===(e=t.scroll)||void 0===e?void 0:e.wasRoot)}const vf=qp({attachResizeListener:(t,e)=>Zd(t,"resize",e),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),gf={current:void 0},yf=qp({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!gf.current){const t=new vf({});t.mount(window),t.setOptions({layoutScroll:!0}),gf.current=t}return gf.current},resetTransform:(t,e)=>{t.style.transform=void 0!==e?e:"none"},checkIsScrollRoot:t=>Boolean("fixed"===window.getComputedStyle(t).position)}),bf={pan:{Feature:class extends qd{constructor(){super(...arguments),this.removePointerDownListener=Ol}onPointerDown(t){this.session=new eh(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Gh(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:e,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:Zh(t),onStart:Zh(e),onMove:n,onEnd:(t,e)=>{delete this.session,r&&Ml.postRender((()=>r(t,e)))}}}mount(){this.removePointerDownListener=Jd(this.node.current,"pointerdown",(t=>this.onPointerDown(t)))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends qd{constructor(t){super(t),this.removeGroupControls=Ol,this.removeListeners=Ol,this.controls=new Qh(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ol}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:yf,MeasureLayout:cp}};function wf(t,e){const n=e?"pointerenter":"pointerleave",r=e?"onHoverStart":"onHoverEnd";return Jd(t.current,n,((n,i)=>{if("touch"===n.pointerType||hh())return;const o=t.getProps();t.animationState&&o.whileHover&&t.animationState.setActive("whileHover",e);const s=o[r];s&&Ml.postRender((()=>s(n,i)))}),{passive:!t.getProps()[r]})}const xf=(t,e)=>!!e&&(t===e||xf(t,e.parentElement));function _f(t,e){if(!e)return;const n=new PointerEvent("pointer"+t);e(n,Qd(n))}const Sf=new WeakMap,Ef=new WeakMap,kf=t=>{const e=Sf.get(t.target);e&&e(t)},Pf=t=>{t.forEach(kf)};function Tf(t,e,n){const r=function({root:t,...e}){const n=t||document;Ef.has(n)||Ef.set(n,{});const r=Ef.get(n),i=JSON.stringify(e);return r[i]||(r[i]=new IntersectionObserver(Pf,{root:t,...e})),r[i]}(e);return Sf.set(t,n),r.observe(t),()=>{Sf.delete(t),r.unobserve(t)}}const Cf={some:0,all:1};const Af={inView:{Feature:class extends qd{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:e,margin:n,amount:r="some",once:i}=t,o={root:e?e.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:Cf[r]};return Tf(this.node.current,o,(t=>{const{isIntersecting:e}=t;if(this.isInView===e)return;if(this.isInView=e,i&&!e&&this.hasEnteredView)return;e&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",e);const{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),o=e?n:r;o&&o(t)}))}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;const{props:t,prevProps:e}=this.node;["amount","margin","root"].some(function({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}(t,e))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends qd{constructor(){super(...arguments),this.removeStartListeners=Ol,this.removeEndListeners=Ol,this.removeAccessibleListeners=Ol,this.startPointerPress=(t,e)=>{if(this.isPressing)return;this.removeEndListeners();const n=this.node.getProps(),r=Jd(window,"pointerup",((t,e)=>{if(!this.checkPressEnd())return;const{onTap:n,onTapCancel:r,globalTapTarget:i}=this.node.getProps(),o=i||xf(this.node.current,t.target)?n:r;o&&Ml.update((()=>o(t,e)))}),{passive:!(n.onTap||n.onPointerUp)}),i=Jd(window,"pointercancel",((t,e)=>this.cancelPress(t,e)),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=Nc(r,i),this.startPress(t,e)},this.startAccessiblePress=()=>{const t=Zd(this.node.current,"keydown",(t=>{if("Enter"!==t.key||this.isPressing)return;this.removeEndListeners(),this.removeEndListeners=Zd(this.node.current,"keyup",(t=>{"Enter"===t.key&&this.checkPressEnd()&&_f("up",((t,e)=>{const{onTap:n}=this.node.getProps();n&&Ml.postRender((()=>n(t,e)))}))})),_f("down",((t,e)=>{this.startPress(t,e)}))})),e=Zd(this.node.current,"blur",(()=>{this.isPressing&&_f("cancel",((t,e)=>this.cancelPress(t,e)))}));this.removeAccessibleListeners=Nc(t,e)}}startPress(t,e){this.isPressing=!0;const{onTapStart:n,whileTap:r}=this.node.getProps();r&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&Ml.postRender((()=>n(t,e)))}checkPressEnd(){this.removeEndListeners(),this.isPressing=!1;return this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!hh()}cancelPress(t,e){if(!this.checkPressEnd())return;const{onTapCancel:n}=this.node.getProps();n&&Ml.postRender((()=>n(t,e)))}mount(){const t=this.node.getProps(),e=Jd(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),n=Zd(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Nc(e,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}},focus:{Feature:class extends qd{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch(yy){t=!0}t&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Nc(Zd(this.node.current,"focus",(()=>this.onFocus())),Zd(this.node.current,"blur",(()=>this.onBlur())))}unmount(){}}},hover:{Feature:class extends qd{mount(){this.unmount=Nc(wf(this.node,!0),wf(this.node,!1))}unmount(){}}}},Rf={layout:{ProjectionNode:yf,MeasureLayout:cp}},Of=fe({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),Ff=fe({}),Lf="undefined"!=typeof window,Mf=Lf?Hn:Wn,Df=fe({strict:!1});let Vf=!1;function jf(t,e,n,r,i){var o;const{visualElement:s}=Gn(Ff),a=Gn(Df),l=Gn(Jh),u=Gn(Of).reducedMotion,c=$n();r=r||a.renderer,!c.current&&r&&(c.current=r(t,{visualState:e,parent:s,props:n,presenceContext:l,blockInitialAnimation:!!l&&!1===l.initial,reducedMotionConfig:u}));const d=c.current,h=Gn(ep);!d||d.projection||!i||"html"!==d.type&&"svg"!==d.type||function(t,e,n,r){const{layoutId:i,layout:o,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:u}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:Bf(t.parent)),t.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:Boolean(s)||a&&ph(a),visualElement:t,animationType:"string"==typeof o?o:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:u})}(c.current,n,i,h),ni((()=>{d&&d.update(n,l)}));const p=n[Rd],f=$n(Boolean(p)&&!window.MotionHandoffIsComplete&&(null===(o=window.MotionHasOptimisedAnimation)||void 0===o?void 0:o.call(window,p)));return Mf((()=>{d&&(d.updateFeatures(),ap.render(d.render),f.current&&d.animationState&&d.animationState.animateChanges())})),Wn((()=>{d&&(!f.current&&d.animationState&&d.animationState.animateChanges(),f.current=!1,Vf||(Vf=!0,queueMicrotask(If)))})),d}function If(){window.MotionHandoffIsComplete=!0}function Bf(t){if(t)return!1!==t.options.allowProjection?t.projection:Bf(t.parent)}function Nf(t,e,n){return Kn((r=>{r&&t.mount&&t.mount(r),e&&(r?e.mount(r):e.unmount()),n&&("function"==typeof n?n(r):ph(n)&&(n.current=r))}),[e])}function Uf(t){return cl(t.animate)||yl.some((e=>pl(t[e])))}function Wf(t){return Boolean(Uf(t)||t.variants)}function Hf(t){const{initial:e,animate:n}=function(t,e){if(Uf(t)){const{initial:e,animate:n}=t;return{initial:!1===e||pl(e)?e:void 0,animate:pl(n)?n:void 0}}return!1!==t.inherit?e:{}}(t,Gn(Ff));return qn((()=>({initial:e,animate:n})),[$f(e),$f(n)])}function $f(t){return Array.isArray(t)?t.join(" "):t}const zf={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},qf={};for(const vS in zf)qf[vS]={isEnabled:t=>zf[vS].some((e=>!!t[e]))};const Kf=Symbol.for("motionComponentSymbol");function Gf({preloadedFeatures:t,createVisualElement:e,useRender:n,useVisualState:r,Component:i}){t&&function(t){for(const e in t)qf[e]={...qf[e],...t[e]}}(t);const o=cr((function(t,o){let s;const a={...Gn(Of),...t,layoutId:Yf(t)},{isStatic:l}=a,u=Hf(t),c=r(t,l);if(!l&&Lf){Gn(Df).strict;const t=function(t){const{drag:e,layout:n}=qf;if(!e&&!n)return{};const r={...e,...n};return{MeasureLayout:(null==e?void 0:e.isEnabled(t))||(null==n?void 0:n.isEnabled(t))?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(a);s=t.MeasureLayout,u.visualElement=jf(i,c,a,e,t.ProjectionNode)}return ho(Ff.Provider,{value:u,children:[s&&u.visualElement?ho(s,{visualElement:u.visualElement,...a}):null,n(i,t,Nf(c,u.visualElement,o),c,l,u.visualElement)]})}));return o[Kf]=i,o}function Yf({layoutId:t}){const e=Gn(tp).id;return e&&void 0!==t?e+"-"+t:t}const Qf=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Xf(t){return"string"==typeof t&&!t.includes("-")&&!!(Qf.indexOf(t)>-1||/[A-Z]/u.test(t))}function Zf(t,{style:e,vars:n},r,i){Object.assign(t.style,e,i&&i.getProjectionStyles(r));for(const o in n)t.style.setProperty(o,n[o])}const Jf=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function tm(t,e,n,r){Zf(t,e,void 0,r);for(const i in e.attrs)t.setAttribute(Jf.has(i)?i:Ad(i),e.attrs[i])}function em(t,{layout:e,layoutId:n}){return wl.has(t)||t.startsWith("origin")||(e||void 0!==n)&&(!!sp[t]||"opacity"===t)}function nm(t,e,n){var r;const{style:i}=t,o={};for(const s in i)(Md(i[s])||e.style&&Md(e.style[s])||em(s,t)||void 0!==(null===(r=null==n?void 0:n.getValue(s))||void 0===r?void 0:r.liveStyle))&&(o[s]=i[s]);return n&&i&&"string"==typeof i.willChange&&(n.applyWillChange=!1),o}function rm(t,e,n){const r=nm(t,e,n);for(const i in t)if(Md(t[i])||Md(e[i])){r[-1!==bl.indexOf(i)?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i]=t[i]}return r}function im(t){const e=$n(null);return null===e.current&&(e.current=t()),e.current}const om=t=>(e,n)=>{const r=Gn(Ff),i=Gn(Jh),o=()=>function({applyWillChange:t=!1,scrapeMotionValuesFromProps:e,createRenderState:n,onMount:r},i,o,s,a){const l={latestValues:lm(i,o,s,!a&&t,e),renderState:n()};return r&&(l.mount=t=>r(i,t,l)),l}(t,e,r,i,n);return n?o():im(o)};function sm(t,e){const n=Fd(e);n&&Sd(t,n)}function am(t,e,n){const r=Array.isArray(e)?e:[e];for(let i=0;i<r.length;i++){const e=ml(t,r[i]);if(e){const{transitionEnd:t,transition:r,...i}=e;n(i,t)}}}function lm(t,e,n,r,i){var o;const s={},a=[],l=r&&void 0===(null===(o=t.style)||void 0===o?void 0:o.willChange),u=i(t,{});for(const v in u)s[v]=Ip(u[v]);let{initial:c,animate:d}=t;const h=Uf(t),p=Wf(t);e&&p&&!h&&!1!==t.inherit&&(void 0===c&&(c=e.initial),void 0===d&&(d=e.animate));let f=!!n&&!1===n.initial;f=f||!1===c;const m=f?d:c;return m&&"boolean"!=typeof m&&!cl(m)&&am(t,m,((t,e)=>{for(const n in t){let e=t[n];if(Array.isArray(e)){e=e[f?e.length-1:0]}null!==e&&(s[n]=e)}for(const n in e)s[n]=e[n]})),l&&(d&&!1!==c&&!cl(d)&&am(t,d,(t=>{for(const e in t)sm(a,e)})),a.length&&(s.willChange=a.join(","))),s}const um=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),cm=()=>({...um(),attrs:{}}),dm=(t,e)=>e&&"number"==typeof t?e.transform(t):t,hm={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},pm=bl.length;function fm(t,e,n){const{style:r,vars:i,transformOrigin:o}=t;let s=!1,a=!1;for(const l in e){const t=e[l];if(wl.has(l))s=!0;else if(Wl(l))i[l]=t;else{const e=dm(t,Yu[l]);l.startsWith("origin")?(a=!0,o[l]=e):r[l]=e}}if(e.transform||(s||n?r.transform=function(t,e,n){let r="",i=!0;for(let o=0;o<pm;o++){const s=bl[o],a=t[s];if(void 0===a)continue;let l=!0;if(l="number"==typeof a?a===(s.startsWith("scale")?1:0):0===parseFloat(a),!l||n){const t=dm(a,Yu[s]);l||(i=!1,r+=`${hm[s]||s}(${t}) `),n&&(e[s]=t)}}return r=r.trim(),n?r=n(e,i?"":r):i&&(r="none"),r}(e,t.transform,n):r.transform&&(r.transform="none")),a){const{originX:t="50%",originY:e="50%",originZ:n=0}=o;r.transformOrigin=`${t} ${e} ${n}`}}function mm(t,e,n){return"string"==typeof t?t:su.transform(e+n*t)}const vm={offset:"stroke-dashoffset",array:"stroke-dasharray"},gm={offset:"strokeDashoffset",array:"strokeDasharray"};function ym(t,{attrX:e,attrY:n,attrScale:r,originX:i,originY:o,pathLength:s,pathSpacing:a=1,pathOffset:l=0,...u},c,d){if(fm(t,u,d),c)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:h,style:p,dimensions:f}=t;h.transform&&(f&&(p.transform=h.transform),delete h.transform),f&&(void 0!==i||void 0!==o||p.transform)&&(p.transformOrigin=function(t,e,n){return`${mm(e,t.x,t.width)} ${mm(n,t.y,t.height)}`}(f,void 0!==i?i:.5,void 0!==o?o:.5)),void 0!==e&&(h.x=e),void 0!==n&&(h.y=n),void 0!==r&&(h.scale=r),void 0!==s&&function(t,e,n=1,r=0,i=!0){t.pathLength=1;const o=i?vm:gm;t[o.offset]=su.transform(-r);const s=su.transform(e),a=su.transform(n);t[o.array]=`${s} ${a}`}(h,s,a,l,!1)}const bm=t=>"string"==typeof t&&"svg"===t.toLowerCase(),wm={useVisualState:om({scrapeMotionValuesFromProps:rm,createRenderState:cm,onMount:(t,e,{renderState:n,latestValues:r})=>{Ml.read((()=>{try{n.dimensions="function"==typeof e.getBBox?e.getBBox():e.getBoundingClientRect()}catch(yy){n.dimensions={x:0,y:0,width:0,height:0}}})),Ml.render((()=>{ym(n,r,bm(e.tagName),t.transformTemplate),tm(e,n)}))}})},xm={useVisualState:om({applyWillChange:!0,scrapeMotionValuesFromProps:nm,createRenderState:um})};function _m(t,e,n){for(const r in e)Md(e[r])||em(r,n)||(t[r]=e[r])}function Sm(t,e){const n={};return _m(n,t.style||{},t),Object.assign(n,function({transformTemplate:t},e){return qn((()=>{const n=um();return fm(n,e,t),Object.assign({},n.vars,n.style)}),[e])}(t,e)),n}function Em(t,e){const n={},r=Sm(t,e);return t.drag&&!1!==t.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===t.drag?"none":"pan-"+("x"===t.drag?"y":"x")),void 0===t.tabIndex&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=r,n}const km=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Pm(t){return t.startsWith("while")||t.startsWith("drag")&&"draggable"!==t||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||km.has(t)}let Tm=t=>!Pm(t);try{(Cm=require("@emotion/is-prop-valid").default)&&(Tm=t=>t.startsWith("on")?!Pm(t):Cm(t))}catch(mS){}var Cm;function Am(t,e,n,r){const i=qn((()=>{const n=cm();return ym(n,e,bm(r),t.transformTemplate),{...n.attrs,style:{...n.style}}}),[e]);if(t.style){const e={};_m(e,t.style,t),i.style={...e,...i.style}}return i}function Rm(t=!1){return(e,n,r,{latestValues:i},o)=>{const s=(Xf(e)?Am:Em)(n,i,o,e),a=function(t,e,n){const r={};for(const i in t)"values"===i&&"object"==typeof t.values||(Tm(i)||!0===n&&Pm(i)||!e&&!Pm(i)||t.draggable&&i.startsWith("onDrag"))&&(r[i]=t[i]);return r}(n,"string"==typeof e,t),l=e!==Kt?{...a,...s,ref:r}:{},{children:u}=n;return $t(e,{...l,children:qn((()=>Md(u)?u.get():u),[u])})}}function Om(t,e){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){return Gf({...Xf(n)?wm:xm,preloadedFeatures:t,useRender:Rm(r),createVisualElement:e,Component:n})}}const Fm={current:null},Lm={current:!1};const Mm=new WeakMap,Dm=[...yu,Fu,Hu],Vm=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],jm=yl.length;class Im{scrapeMotionValuesFromProps(t,e,n){return{}}constructor({parent:t,props:e,presenceContext:n,reducedMotionConfig:r,blockInitialAnimation:i,visualState:o},s={}){this.applyWillChange=!1,this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=ku,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.isRenderScheduled=!1,this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.isRenderScheduled=!1,this.scheduleRender=()=>{this.isRenderScheduled||(this.isRenderScheduled=!0,Ml.render(this.render,!1,!0))};const{latestValues:a,renderState:l}=o;this.latestValues=a,this.baseTarget={...a},this.initialValues=e.initial?{...a}:{},this.renderState=l,this.parent=t,this.props=e,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.options=s,this.blockInitialAnimation=Boolean(i),this.isControllingVariants=Uf(e),this.isVariantNode=Wf(e),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(t&&t.current);const{willChange:u,...c}=this.scrapeMotionValuesFromProps(e,{},this);for(const d in c){const t=c[d];void 0!==a[d]&&Md(t)&&t.set(a[d],!1)}}mount(t){this.current=t,Mm.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach(((t,e)=>this.bindToMotionValue(e,t))),Lm.current||function(){if(Lm.current=!0,Lf)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),e=()=>Fm.current=t.matches;t.addListener(e),e()}else Fm.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||Fm.current),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){Mm.delete(this.current),this.projection&&this.projection.unmount(),Dl(this.notifyUpdate),Dl(this.render),this.valueSubscriptions.forEach((t=>t())),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const e=this.features[t];e&&(e.unmount(),e.isMounted=!1)}this.current=null}bindToMotionValue(t,e){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const n=wl.has(t),r=e.on("change",(e=>{this.latestValues[t]=e,this.props.onUpdate&&Ml.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),i=e.on("renderRequest",this.scheduleRender);let o;window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,e)),this.valueSubscriptions.set(t,(()=>{r(),i(),o&&o(),e.owner&&e.stop()}))}sortNodePosition(t){return this.current&&this.sortInstanceNodePosition&&this.type===t.type?this.sortInstanceNodePosition(this.current,t.current):0}updateFeatures(){let t="animation";for(t in qf){const e=qf[t];if(!e)continue;const{isEnabled:n,Feature:r}=e;if(!this.features[t]&&r&&n(this.props)&&(this.features[t]=new r(this)),this.features[t]){const e=this.features[t];e.isMounted?e.update():(e.mount(),e.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Rh()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,e){this.latestValues[t]=e}update(t,e){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=e;for(let n=0;n<Vm.length;n++){const e=Vm[n];this.propEventSubscriptions[e]&&(this.propEventSubscriptions[e](),delete this.propEventSubscriptions[e]);const r=t["on"+e];r&&(this.propEventSubscriptions[e]=this.on(e,r))}this.prevMotionValues=function(t,e,n){for(const r in e){const i=e[r],o=n[r];if(Md(i))t.addValue(r,i);else if(Md(o))t.addValue(r,Td(i,{owner:t}));else if(o!==i)if(t.hasValue(r)){const e=t.getValue(r);!0===e.liveStyle?e.jump(i):e.hasAnimated||e.set(i)}else{const e=t.getStaticValue(r);t.addValue(r,Td(void 0!==e?e:i,{owner:t}))}}for(const r in n)void 0===e[r]&&t.removeValue(r);return e}(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}getVariantContext(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){const t=this.parent&&this.parent.getVariantContext()||{};return void 0!==this.props.initial&&(t.initial=this.props.initial),t}const e={};for(let n=0;n<jm;n++){const t=yl[n],r=this.props[t];(pl(r)||!1===r)&&(e[t]=r)}return e}addVariantChild(t){const e=this.getClosestVariantNode();if(e)return e.variantChildren&&e.variantChildren.add(t),()=>e.variantChildren.delete(t)}addValue(t,e){const n=this.values.get(t);e!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,e),this.values.set(t,e),this.latestValues[t]=e.get())}removeValue(t){this.values.delete(t);const e=this.valueSubscriptions.get(t);e&&(e(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,e){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return void 0===n&&void 0!==e&&(n=Td(null===e?void 0:e,{owner:this}),this.addValue(t,n)),n}readValue(t,e){var n;let r=void 0===this.latestValues[t]&&this.current?null!==(n=this.getBaseTargetFromProps(this.props,t))&&void 0!==n?n:this.readValueFromInstance(this.current,t,this.options):this.latestValues[t];var i;return null!=r&&("string"==typeof r&&(Nl(r)||Il(r))?r=parseFloat(r):(i=r,!Dm.find(gu(i))&&Hu.test(e)&&(r=Zu(t,e))),this.setBaseTarget(t,Md(r)?r.get():r)),Md(r)?r.get():r}setBaseTarget(t,e){this.baseTarget[t]=e}getBaseTarget(t){var e;const{initial:n}=this.props;let r;if("string"==typeof n||"object"==typeof n){const i=ml(this.props,n,null===(e=this.presenceContext)||void 0===e?void 0:e.custom);i&&(r=i[t])}if(n&&void 0!==r)return r;const i=this.getBaseTargetFromProps(this.props,t);return void 0===i||Md(i)?void 0!==this.initialValues[t]&&void 0===r?void 0:this.baseTarget[t]:i}on(t,e){return this.events[t]||(this.events[t]=new kd),this.events[t].add(e)}notify(t,...e){this.events[t]&&this.events[t].notify(...e)}}class Bm extends Im{constructor(){super(...arguments),this.KeyframeResolver=tc}sortInstanceNodePosition(t,e){return 2&t.compareDocumentPosition(e)?1:-1}getBaseTargetFromProps(t,e){return t.style?t.style[e]:void 0}removeValueFromRenderState(t,{vars:e,style:n}){delete e[t],delete n[t]}}class Nm extends Bm{constructor(){super(...arguments),this.type="html",this.applyWillChange=!0,this.renderInstance=Zf}readValueFromInstance(t,e){if(wl.has(e)){const t=Xu(e);return t&&t.default||0}{const r=(n=t,window.getComputedStyle(n)),i=(Wl(e)?r.getPropertyValue(e):r[e])||0;return"string"==typeof i?i.trim():i}var n}measureInstanceViewportBox(t,{transformPagePoint:e}){return Kh(t,e)}build(t,e,n){fm(t,e,n.transformTemplate)}scrapeMotionValuesFromProps(t,e,n){return nm(t,e,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Md(t)&&(this.childSubscription=t.on("change",(t=>{this.current&&(this.current.textContent=`${t}`)})))}}class Um extends Bm{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Rh}getBaseTargetFromProps(t,e){return t[e]}readValueFromInstance(t,e){if(wl.has(e)){const t=Xu(e);return t&&t.default||0}return e=Jf.has(e)?e:Ad(e),t.getAttribute(e)}scrapeMotionValuesFromProps(t,e,n){return rm(t,e,n)}build(t,e,n){ym(t,e,this.isSVGTag,n.transformTemplate)}renderInstance(t,e,n,r){tm(t,e,0,r)}mount(t){this.isSVGTag=bm(t.tagName),super.mount(t)}}const Wm=ul(Om({...Gd,...Af,...bf,...Rf},((t,e)=>Xf(t)?new Um(e):new Nm(e,{allowProjection:t!==Kt}))));class Hm extends Gt{getSnapshotBeforeUpdate(t){const e=this.props.childRef.current;if(e&&t.isPresent&&!this.props.isPresent){const t=this.props.sizeRef.current;t.height=e.offsetHeight||0,t.width=e.offsetWidth||0,t.top=e.offsetTop,t.left=e.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}}function $m({children:t,isPresent:e}){const n=Qn(),r=$n(null),i=$n({width:0,height:0,top:0,left:0}),{nonce:o}=Gn(Of);return ni((()=>{const{width:t,height:s,top:a,left:l}=i.current;if(e||!r.current||!t||!s)return;r.current.dataset.motionPopId=n;const u=document.createElement("style");return o&&(u.nonce=o),document.head.appendChild(u),u.sheet&&u.sheet.insertRule(`\n [data-motion-pop-id="${n}"] {\n position: absolute !important;\n width: ${t}px !important;\n height: ${s}px !important;\n top: ${a}px !important;\n left: ${l}px !important;\n }\n `),()=>{document.head.removeChild(u)}}),[e]),ho(Hm,{isPresent:e,childRef:r,sizeRef:i,children:Kr(t,{ref:r})})}const zm=({children:t,initial:e,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:o,mode:s})=>{const a=im(qm),l=Qn(),u=qn((()=>({id:l,initial:e,isPresent:n,custom:i,onExitComplete:t=>{a.set(t,!0);for(const e of a.values())if(!e)return;r&&r()},register:t=>(a.set(t,!1),()=>a.delete(t))})),o?[Math.random()]:[n]);return qn((()=>{a.forEach(((t,e)=>a.set(e,!1)))}),[n]),Wn((()=>{!n&&!a.size&&r&&r()}),[n]),"popLayout"===s&&(t=ho($m,{isPresent:n,children:t})),ho(Jh.Provider,{value:u,children:t})};function qm(){return new Map}const Km=t=>t.key||"";function Gm(t){const e=[];return hr.forEach(t,(t=>{$r(t)&&e.push(t)})),e}const Ym=({children:t,exitBeforeEnter:e,custom:n,initial:r=!0,onExitComplete:i,presenceAffectsLayout:o=!0,mode:s="sync"})=>{const a=qn((()=>Gm(t)),[t]),l=a.map(Km),u=$n(!0),c=$n(a),d=im((()=>new Map)),[h,p]=Nn(a),[f,m]=Nn(a);Mf((()=>{u.current=!1,c.current=a;for(let t=0;t<f.length;t++){const e=Km(f[t]);l.includes(e)?d.delete(e):!0!==d.get(e)&&d.set(e,!1)}}),[f,l.length,l.join("-")]);const v=[];if(a!==h){let t=[...a];for(let e=0;e<f.length;e++){const n=f[e],r=Km(n);l.includes(r)||(t.splice(e,0,n),v.push(n))}return"wait"===s&&v.length&&(t=v),m(Gm(t)),void p(a)}const{forceRender:g}=Gn(tp);return ho(Kt,{children:f.map((t=>{const e=Km(t),h=a===f||l.includes(e);return ho(zm,{isPresent:h,initial:!(u.current&&!r)&&void 0,custom:h?void 0:n,presenceAffectsLayout:o,mode:s,onExitComplete:h?void 0:()=>{if(!d.has(e))return;d.set(e,!0);let t=!0;d.forEach((e=>{e||(t=!1)})),t&&(null==g||g(),m(c.current),i&&i())},children:t},e)}))})},Qm=Ns.input`
|
|
31
|
+
* React Router DOM v6.26.2
|
|
32
|
+
*
|
|
33
|
+
* Copyright (c) Remix Software Inc.
|
|
34
|
+
*
|
|
35
|
+
* This source code is licensed under the MIT license found in the
|
|
36
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
37
|
+
*
|
|
38
|
+
* @license MIT
|
|
39
|
+
*/new Promise((()=>{}));try{window.__reactRouterVersion="6"}catch(uy){}const Wa=Zr.startTransition;function Ha(t){let{basename:e,children:n,future:r,window:i}=t,o=Dn();null==o.current&&(o.current=Us({window:i,v5Compat:!0}));let s=o.current,[a,l]=On({action:s.action,location:s.location}),{v7_startTransition:u}=r||{},c=In((t=>{u&&Wa?Wa((()=>l(t))):l(t)}),[l,u]);return Ln((()=>s.listen(c)),[s,c]),Dt(Na,{basename:e,children:n,location:a.location,navigationType:a.action,navigator:s,future:r})}var $a,za,qa,Ka;let Ya;(za=$a||($a={})).UseScrollRestoration="useScrollRestoration",za.UseSubmit="useSubmit",za.UseSubmitFetcher="useSubmitFetcher",za.UseFetcher="useFetcher",za.useViewTransitionState="useViewTransitionState",(Ka=qa||(qa={})).UseFetcher="useFetcher",Ka.UseFetchers="useFetchers",Ka.UseScrollRestoration="useScrollRestoration";const Qa=()=>{if(Ya)return Ya;return Ya=new ns({defaultOptions:{queries:{retry:(t,e)=>{var n;return e instanceof uo&&![401,403].includes((null==(n=e.response)?void 0:n.status)||0)}}}}),Ya},Xa="getAllPromotions",Za=[{name:"Id",field:"id"},{name:"Category",field:"category"},{name:"Promotion Status",field:"promotionStatus",type:{kind:"status",styleOverrides:{Enabled:{"--tw-bg-opacity":"1",backgroundColor:"rgb(240 253 244 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(21 128 61 / var(--tw-text-opacity))","--tw-ring-color":"rgb(22 163 74 / 0.2)"},Disabled:{"--tw-bg-opacity":"1",backgroundColor:"rgb(254 242 242 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(185 28 28 / var(--tw-text-opacity))","--tw-ring-color":"rgb(220 38 38 / 0.2)"}}}},{name:"Contentful Status",field:"contentfulStatus",type:{kind:"status",styleOverrides:{Linked:{"--tw-bg-opacity":"1",backgroundColor:"rgb(240 253 244 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(21 128 61 / var(--tw-text-opacity))","--tw-ring-color":"rgb(22 163 74 / 0.2)"},Unlinked:{"--tw-bg-opacity":"1",backgroundColor:"rgb(254 242 242 / var(--tw-bg-opacity))","--tw-text-opacity":"1",color:"rgb(185 28 28 / var(--tw-text-opacity))","--tw-ring-color":"rgb(220 38 38 / 0.2)"}}}},{name:"Created At",field:"createdAt",type:{kind:"date"}},{name:"Updated At",field:"updatedAt",type:{kind:"date"}}],Ja=()=>{const{getAllPromotions:t}=mo(),e=Ra(),{isPending:n,error:r,data:i}=Es({queryKey:[Xa],queryFn:t});switch(!0){case n:return io(ro,{children:"Loading..."});case!!r:return oo(ro,{children:["An error has occurred: ",r.message]});case!!i:return io(js,{columns:Za,data:(o=i,o.data.map((t=>({id:t.id,category:t.category.title,promotionStatus:t.status,contentfulStatus:t.contentfulContent?"Linked":"Unlinked",createdAt:t.createdAt,updatedAt:t.updatedAt}))).sort(((t,e)=>new Date(e.updatedAt).valueOf()-new Date(t.updatedAt).valueOf()))),title:"Promotions",subtitle:"A list of currently configured promoted benefits",addButtonText:"Add New Promotion",onAdd:()=>e("/promotion"),onClick:t=>e(`/promotion/${t}`)});default:return io(ro,{children:"No data returned from backend"})}var o};function tl(t){if("undefined"==typeof Proxy)return t;const e=new Map;return new Proxy(((...e)=>t(...e)),{get:(n,r)=>"create"===r?t:(e.has(r)||e.set(r,t(r)),e.get(r))})}function el(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}const nl=t=>Array.isArray(t);function rl(t,e){if(!Array.isArray(e))return!1;const n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}function il(t){return"string"==typeof t||Array.isArray(t)}function ol(t){const e=[{},{}];return null==t||t.values.forEach(((t,n)=>{e[0][n]=t.get(),e[1][n]=t.getVelocity()})),e}function sl(t,e,n,r){if("function"==typeof e){const[i,o]=ol(r);e=e(void 0!==n?n:t.custom,i,o)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){const[i,o]=ol(r);e=e(void 0!==n?n:t.custom,i,o)}return e}function al(t,e,n){const r=t.getProps();return sl(r,e,void 0!==n?n:r.custom,t)}const ll=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],ul=["initial",...ll],cl=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],dl=new Set(cl),hl=t=>1e3*t,pl=t=>t/1e3,fl={type:"spring",stiffness:500,damping:25,restSpeed:10},ml={type:"keyframes",duration:.8},vl={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},gl=(t,{keyframes:e})=>e.length>2?ml:dl.has(t)?t.startsWith("scale")?{type:"spring",stiffness:550,damping:0===e[1]?2*Math.sqrt(550):30,restSpeed:10}:fl:vl;function yl(t,e){return t[e]||t.default||t}const _l=!1,bl=t=>null!==t;function wl(t,{repeat:e,repeatType:n="loop"},r){const i=t.filter(bl),o=e&&"loop"!==n&&e%2==1?0:i.length-1;return o&&void 0!==r?r:i[o]}const xl=t=>t;const Sl=["read","resolveKeyframes","update","preRender","render","postRender"];function El(t,e){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,s=Sl.reduce(((t,e)=>(t[e]=function(t){let e=new Set,n=new Set,r=!1,i=!1;const o=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1};function a(e){o.has(e)&&(l.schedule(e),t()),e(s)}const l={schedule:(t,i=!1,s=!1)=>{const a=s&&r?e:n;return i&&o.add(t),a.has(t)||a.add(t),t},cancel:t=>{n.delete(t),o.delete(t)},process:t=>{s=t,r?i=!0:(r=!0,[e,n]=[n,e],n.clear(),e.forEach(a),r=!1,i&&(i=!1,l.process(t)))}};return l}(o),t)),{}),{read:a,resolveKeyframes:l,update:u,preRender:c,render:d,postRender:h}=s,p=()=>{const o=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(o-i.timestamp,40),1),i.timestamp=o,i.isProcessing=!0,a.process(i),l.process(i),u.process(i),c.process(i),d.process(i),h.process(i),i.isProcessing=!1,n&&e&&(r=!1,t(p))};return{schedule:Sl.reduce(((e,o)=>{const a=s[o];return e[o]=(e,o=!1,s=!1)=>(n||(n=!0,r=!0,i.isProcessing||t(p)),a.schedule(e,o,s)),e}),{}),cancel:t=>{for(let e=0;e<Sl.length;e++)s[Sl[e]].cancel(t)},state:i,steps:s}}const{schedule:kl,cancel:Pl,state:Tl,steps:Al}=El("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:xl,!0),Cl=t=>/^0[^.\s]+$/u.test(t);let Rl=xl;const Ol=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),Ml=t=>e=>"string"==typeof e&&e.startsWith(t),Fl=Ml("--"),Ll=Ml("var(--"),Dl=t=>!!Ll(t)&&Vl.test(t.split("/*")[0].trim()),Vl=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,jl=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Il(t,e,n=1){const[r,i]=function(t){const e=jl.exec(t);if(!e)return[,];const[,n,r,i]=e;return[`--${null!=n?n:r}`,i]}(t);if(!r)return;const o=window.getComputedStyle(e).getPropertyValue(r);if(o){const t=o.trim();return Ol(t)?parseFloat(t):t}return Dl(i)?Il(i,e,n+1):i}const Bl=(t,e,n)=>n>e?e:n<t?t:n,Nl={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},Gl={...Nl,transform:t=>Bl(0,1,t)},Ul={...Nl,default:1},Wl=t=>Math.round(1e5*t)/1e5,Hl=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,$l=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,zl=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;function ql(t){return"string"==typeof t}const Kl=t=>({test:e=>ql(e)&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),Yl=Kl("deg"),Ql=Kl("%"),Xl=Kl("px"),Zl=Kl("vh"),Jl=Kl("vw"),tu={...Ql,parse:t=>Ql.parse(t)/100,transform:t=>Ql.transform(100*t)},eu=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),nu=t=>t===Nl||t===Xl,ru=(t,e)=>parseFloat(t.split(", ")[e]),iu=(t,e)=>(n,{transform:r})=>{if("none"===r||!r)return 0;const i=r.match(/^matrix3d\((.+)\)$/u);if(i)return ru(i[1],e);{const e=r.match(/^matrix\((.+)\)$/u);return e?ru(e[1],t):0}},ou=new Set(["x","y","z"]),su=cl.filter((t=>!ou.has(t)));const au={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:iu(4,13),y:iu(5,14)};au.translateX=au.x,au.translateY=au.y;const lu=t=>e=>e.test(t),uu=[Nl,Xl,Ql,Yl,Jl,Zl,{test:t=>"auto"===t,parse:t=>t}],cu=t=>uu.find(lu(t)),du=new Set;let hu=!1,pu=!1;function fu(){if(pu){const t=Array.from(du).filter((t=>t.needsMeasurement)),e=new Set(t.map((t=>t.element))),n=new Map;e.forEach((t=>{const e=function(t){const e=[];return su.forEach((n=>{const r=t.getValue(n);void 0!==r&&(e.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))})),e}(t);e.length&&(n.set(t,e),t.render())})),t.forEach((t=>t.measureInitialState())),e.forEach((t=>{t.render();const e=n.get(t);e&&e.forEach((([e,n])=>{var r;null===(r=t.getValue(e))||void 0===r||r.set(n)}))})),t.forEach((t=>t.measureEndState())),t.forEach((t=>{void 0!==t.suspendedScrollY&&window.scrollTo(0,t.suspendedScrollY)}))}pu=!1,hu=!1,du.forEach((t=>t.complete())),du.clear()}function mu(){du.forEach((t=>{t.readKeyframes(),t.needsMeasurement&&(pu=!0)}))}class vu{constructor(t,e,n,r,i,o=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=e,this.name=n,this.motionValue=r,this.element=i,this.isAsync=o}scheduleResolve(){this.isScheduled=!0,this.isAsync?(du.add(this),hu||(hu=!0,kl.read(mu),kl.resolveKeyframes(fu))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:e,element:n,motionValue:r}=this;for(let i=0;i<t.length;i++)if(null===t[i])if(0===i){const i=null==r?void 0:r.get(),o=t[t.length-1];if(void 0!==i)t[0]=i;else if(n&&e){const r=n.readValue(e,o);null!=r&&(t[0]=r)}void 0===t[0]&&(t[0]=o),r&&void 0===i&&r.set(t[0])}else t[i]=t[i-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),du.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,du.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}const gu=(t,e)=>n=>Boolean(ql(n)&&zl.test(n)&&n.startsWith(t)||e&&!function(t){return null==t}(n)&&Object.prototype.hasOwnProperty.call(n,e)),yu=(t,e,n)=>r=>{if(!ql(r))return r;const[i,o,s,a]=r.match(Hl);return{[t]:parseFloat(i),[e]:parseFloat(o),[n]:parseFloat(s),alpha:void 0!==a?parseFloat(a):1}},_u={...Nl,transform:t=>Math.round((t=>Bl(0,255,t))(t))},bu={test:gu("rgb","red"),parse:yu("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:r=1})=>"rgba("+_u.transform(t)+", "+_u.transform(e)+", "+_u.transform(n)+", "+Wl(Gl.transform(r))+")"};const wu={test:gu("#"),parse:function(t){let e="",n="",r="",i="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),r=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),r=t.substring(3,4),i=t.substring(4,5),e+=e,n+=n,r+=r,i+=i),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}},transform:bu.transform},xu={test:gu("hsl","hue"),parse:yu("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:r=1})=>"hsla("+Math.round(t)+", "+Ql.transform(Wl(e))+", "+Ql.transform(Wl(n))+", "+Wl(Gl.transform(r))+")"},Su={test:t=>bu.test(t)||wu.test(t)||xu.test(t),parse:t=>bu.test(t)?bu.parse(t):xu.test(t)?xu.parse(t):wu.parse(t),transform:t=>ql(t)?t:t.hasOwnProperty("red")?bu.transform(t):xu.transform(t)};const Eu="number",ku="color",Pu="var",Tu="var(",Au="${}",Cu=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Ru(t){const e=t.toString(),n=[],r={color:[],number:[],var:[]},i=[];let o=0;const s=e.replace(Cu,(t=>(Su.test(t)?(r.color.push(o),i.push(ku),n.push(Su.parse(t))):t.startsWith(Tu)?(r.var.push(o),i.push(Pu),n.push(t)):(r.number.push(o),i.push(Eu),n.push(parseFloat(t))),++o,Au))).split(Au);return{values:n,split:s,indexes:r,types:i}}function Ou(t){return Ru(t).values}function Mu(t){const{split:e,types:n}=Ru(t),r=e.length;return t=>{let i="";for(let o=0;o<r;o++)if(i+=e[o],void 0!==t[o]){const e=n[o];i+=e===Eu?Wl(t[o]):e===ku?Su.transform(t[o]):t[o]}return i}}const Fu=t=>"number"==typeof t?0:t;const Lu={test:function(t){var e,n;return isNaN(t)&&ql(t)&&((null===(e=t.match(Hl))||void 0===e?void 0:e.length)||0)+((null===(n=t.match($l))||void 0===n?void 0:n.length)||0)>0},parse:Ou,createTransformer:Mu,getAnimatableNone:function(t){const e=Ou(t);return Mu(t)(e.map(Fu))}},Du=new Set(["brightness","contrast","saturate","opacity"]);function Vu(t){const[e,n]=t.slice(0,-1).split("(");if("drop-shadow"===e)return t;const[r]=n.match(Hl)||[];if(!r)return t;const i=n.replace(r,"");let o=Du.has(e)?1:0;return r!==n&&(o*=100),e+"("+o+i+")"}const ju=/\b([a-z-]*)\(.*?\)/gu,Iu={...Lu,getAnimatableNone:t=>{const e=t.match(ju);return e?e.map(Vu).join(" "):t}},Bu={...Nl,transform:Math.round},Nu={borderWidth:Xl,borderTopWidth:Xl,borderRightWidth:Xl,borderBottomWidth:Xl,borderLeftWidth:Xl,borderRadius:Xl,radius:Xl,borderTopLeftRadius:Xl,borderTopRightRadius:Xl,borderBottomRightRadius:Xl,borderBottomLeftRadius:Xl,width:Xl,maxWidth:Xl,height:Xl,maxHeight:Xl,size:Xl,top:Xl,right:Xl,bottom:Xl,left:Xl,padding:Xl,paddingTop:Xl,paddingRight:Xl,paddingBottom:Xl,paddingLeft:Xl,margin:Xl,marginTop:Xl,marginRight:Xl,marginBottom:Xl,marginLeft:Xl,rotate:Yl,rotateX:Yl,rotateY:Yl,rotateZ:Yl,scale:Ul,scaleX:Ul,scaleY:Ul,scaleZ:Ul,skew:Yl,skewX:Yl,skewY:Yl,distance:Xl,translateX:Xl,translateY:Xl,translateZ:Xl,x:Xl,y:Xl,z:Xl,perspective:Xl,transformPerspective:Xl,opacity:Gl,originX:tu,originY:tu,originZ:Xl,zIndex:Bu,backgroundPositionX:Xl,backgroundPositionY:Xl,fillOpacity:Gl,strokeOpacity:Gl,numOctaves:Bu},Gu={...Nu,color:Su,backgroundColor:Su,outlineColor:Su,fill:Su,stroke:Su,borderColor:Su,borderTopColor:Su,borderRightColor:Su,borderBottomColor:Su,borderLeftColor:Su,filter:Iu,WebkitFilter:Iu},Uu=t=>Gu[t];function Wu(t,e){let n=Uu(t);return n!==Iu&&(n=Lu),n.getAnimatableNone?n.getAnimatableNone(e):void 0}const Hu=new Set(["auto","none","0"]);class $u extends vu{constructor(t,e,n,r,i){super(t,e,n,r,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:e,name:n}=this;if(!e||!e.current)return;super.readKeyframes();for(let a=0;a<t.length;a++){let n=t[a];if("string"==typeof n&&(n=n.trim(),Dl(n))){const r=Il(n,e.current);void 0!==r&&(t[a]=r),a===t.length-1&&(this.finalKeyframe=n)}}if(this.resolveNoneKeyframes(),!eu.has(n)||2!==t.length)return;const[r,i]=t,o=cu(r),s=cu(i);if(o!==s)if(nu(o)&&nu(s))for(let a=0;a<t.length;a++){const e=t[a];"string"==typeof e&&(t[a]=parseFloat(e))}else this.needsMeasurement=!0}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:e}=this,n=[];for(let i=0;i<t.length;i++)("number"==typeof(r=t[i])?0===r:null===r||"none"===r||"0"===r||Cl(r))&&n.push(i);var r;n.length&&function(t,e,n){let r,i=0;for(;i<t.length&&!r;){const e=t[i];"string"==typeof e&&!Hu.has(e)&&Ru(e).values.length&&(r=t[i]),i++}if(r&&n)for(const o of e)t[o]=Wu(n,r)}(t,n,e)}measureInitialState(){const{element:t,unresolvedKeyframes:e,name:n}=this;if(!t||!t.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=au[n](t.measureViewportBox(),window.getComputedStyle(t.current)),e[0]=this.measuredOrigin;const r=e[e.length-1];void 0!==r&&t.getValue(n,r).jump(r,!1)}measureEndState(){var t;const{element:e,name:n,unresolvedKeyframes:r}=this;if(!e||!e.current)return;const i=e.getValue(n);i&&i.jump(this.measuredOrigin,!1);const o=r.length-1,s=r[o];r[o]=au[n](e.measureViewportBox(),window.getComputedStyle(e.current)),null!==s&&void 0===this.finalKeyframe&&(this.finalKeyframe=s),(null===(t=this.removedTransforms)||void 0===t?void 0:t.length)&&this.removedTransforms.forEach((([t,n])=>{e.getValue(t).set(n)})),this.resolveNoneKeyframes()}}function zu(t){let e;return()=>(void 0===e&&(e=t()),e)}let qu;function Ku(){qu=void 0}const Yu={now:()=>(void 0===qu&&Yu.set(Tl.isProcessing||_l?Tl.timestamp:performance.now()),qu),set:t=>{qu=t,queueMicrotask(Ku)}},Qu=(t,e)=>"zIndex"!==e&&(!("number"!=typeof t&&!Array.isArray(t))||!("string"!=typeof t||!Lu.test(t)&&"0"!==t||t.startsWith("url(")));class Xu{constructor({autoplay:t=!0,delay:e=0,type:n="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:o="loop",...s}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=Yu.now(),this.options={autoplay:t,delay:e,type:n,repeat:r,repeatDelay:i,repeatType:o,...s},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(mu(),fu()),this._resolved}onKeyframesResolved(t,e){this.resolvedAt=Yu.now(),this.hasAttemptedResolve=!0;const{name:n,type:r,velocity:i,delay:o,onComplete:s,onUpdate:a,isGenerator:l}=this.options;if(!l&&!function(t,e,n,r){const i=t[0];if(null===i)return!1;if("display"===e||"visibility"===e)return!0;const o=t[t.length-1],s=Qu(i,e),a=Qu(o,e);return!(!s||!a)&&(function(t){const e=t[0];if(1===t.length)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}(t)||"spring"===n&&r)}(t,n,r,i)){if(!o)return null==a||a(wl(t,this.options,e)),null==s||s(),void this.resolveFinishedPromise();this.options.duration=0}const u=this.initPlayback(t,e);!1!==u&&(this._resolved={keyframes:t,finalKeyframe:e,...u},this.onPostResolved())}onPostResolved(){}then(t,e){return this.currentFinishedPromise.then(t,e)}updateFinishedPromise(){this.currentFinishedPromise=new Promise((t=>{this.resolveFinishedPromise=t}))}}function Zu(t,e){return e?t*(1e3/e):0}const Ju=5;function tc(t,e,n){const r=Math.max(e-Ju,0);return Zu(n-t(r),e-r)}const ec=.001,nc=.01,rc=10,ic=.05,oc=1;function sc({duration:t=800,bounce:e=.25,velocity:n=0,mass:r=1}){let i,o,s=1-e;s=Bl(ic,oc,s),t=Bl(nc,rc,pl(t)),s<1?(i=e=>{const r=e*s,i=r*t,o=r-n,a=lc(e,s),l=Math.exp(-i);return ec-o/a*l},o=e=>{const r=e*s*t,o=r*n+n,a=Math.pow(s,2)*Math.pow(e,2)*t,l=Math.exp(-r),u=lc(Math.pow(e,2),s);return(-i(e)+ec>0?-1:1)*((o-a)*l)/u}):(i=e=>Math.exp(-e*t)*((e-n)*t+1)-ec,o=e=>Math.exp(-e*t)*(t*t*(n-e)));const a=function(t,e,n){let r=n;for(let i=1;i<ac;i++)r-=t(r)/e(r);return r}(i,o,5/t);if(t=hl(t),isNaN(a))return{stiffness:100,damping:10,duration:t};{const e=Math.pow(a,2)*r;return{stiffness:e,damping:2*s*Math.sqrt(r*e),duration:t}}}const ac=12;function lc(t,e){return t*Math.sqrt(1-e*e)}const uc=["duration","bounce"],cc=["stiffness","damping","mass"];function dc(t,e){return e.some((e=>void 0!==t[e]))}function hc({keyframes:t,restDelta:e,restSpeed:n,...r}){const i=t[0],o=t[t.length-1],s={done:!1,value:i},{stiffness:a,damping:l,mass:u,duration:c,velocity:d,isResolvedFromDuration:h}=function(t){let e={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...t};if(!dc(t,cc)&&dc(t,uc)){const n=sc(t);e={...e,...n,mass:1},e.isResolvedFromDuration=!0}return e}({...r,velocity:-pl(r.velocity||0)}),p=d||0,f=l/(2*Math.sqrt(a*u)),m=o-i,v=pl(Math.sqrt(a/u)),g=Math.abs(m)<5;let y;if(n||(n=g?.01:2),e||(e=g?.005:.5),f<1){const t=lc(v,f);y=e=>{const n=Math.exp(-f*v*e);return o-n*((p+f*v*m)/t*Math.sin(t*e)+m*Math.cos(t*e))}}else if(1===f)y=t=>o-Math.exp(-v*t)*(m+(p+v*m)*t);else{const t=v*Math.sqrt(f*f-1);y=e=>{const n=Math.exp(-f*v*e),r=Math.min(t*e,300);return o-n*((p+f*v*m)*Math.sinh(r)+t*m*Math.cosh(r))/t}}return{calculatedDuration:h&&c||null,next:t=>{const r=y(t);if(h)s.done=t>=c;else{let i=0;f<1&&(i=0===t?hl(p):tc(y,t,r));const a=Math.abs(i)<=n,l=Math.abs(o-r)<=e;s.done=a&&l}return s.value=s.done?o:r,s}}}function pc({keyframes:t,velocity:e=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:s,min:a,max:l,restDelta:u=.5,restSpeed:c}){const d=t[0],h={done:!1,value:d},p=t=>void 0===a?l:void 0===l||Math.abs(a-t)<Math.abs(l-t)?a:l;let f=n*e;const m=d+f,v=void 0===s?m:s(m);v!==m&&(f=v-d);const g=t=>-f*Math.exp(-t/r),y=t=>v+g(t),_=t=>{const e=g(t),n=y(t);h.done=Math.abs(e)<=u,h.value=h.done?v:n};let b,w;const x=t=>{var e;(e=h.value,void 0!==a&&e<a||void 0!==l&&e>l)&&(b=t,w=hc({keyframes:[h.value,p(h.value)],velocity:tc(y,t,h.value),damping:i,stiffness:o,restDelta:u,restSpeed:c}))};return x(0),{calculatedDuration:null,next:t=>{let e=!1;return w||void 0!==b||(e=!0,_(t),x(t)),void 0!==b&&t>=b?w.next(t-b):(!e&&_(t),h)}}}const fc=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,mc=1e-7,vc=12;function gc(t,e,n,r){if(t===e&&n===r)return xl;const i=e=>function(t,e,n,r,i){let o,s,a=0;do{s=e+(n-e)/2,o=fc(s,r,i)-t,o>0?n=s:e=s}while(Math.abs(o)>mc&&++a<vc);return s}(e,0,1,t,n);return t=>0===t||1===t?t:fc(i(t),e,r)}const yc=gc(.42,0,1,1),_c=gc(0,0,.58,1),bc=gc(.42,0,.58,1),wc=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,xc=t=>e=>1-t(1-e),Sc=t=>1-Math.sin(Math.acos(t)),Ec=xc(Sc),kc=wc(Sc),Pc=gc(.33,1.53,.69,.99),Tc=xc(Pc),Ac={linear:xl,easeIn:yc,easeInOut:bc,easeOut:_c,circIn:Sc,circInOut:kc,circOut:Ec,backIn:Tc,backInOut:wc(Tc),backOut:Pc,anticipate:t=>(t*=2)<1?.5*Tc(t):.5*(2-Math.pow(2,-10*(t-1)))},Cc=t=>{if(Array.isArray(t)){Rl(4===t.length);const[e,n,r,i]=t;return gc(e,n,r,i)}return"string"==typeof t?(Rl(void 0!==Ac[t]),Ac[t]):t},Rc=(t,e)=>n=>e(t(n)),Oc=(...t)=>t.reduce(Rc),Mc=(t,e,n)=>{const r=e-t;return 0===r?1:(n-t)/r},Fc=(t,e,n)=>t+(e-t)*n;function Lc(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function Dc(t,e){return n=>n>0?e:t}const Vc=(t,e,n)=>{const r=t*t,i=n*(e*e-r)+r;return i<0?0:Math.sqrt(i)},jc=[wu,bu,xu];function Ic(t){const e=(n=t,jc.find((t=>t.test(n))));var n;if(!Boolean(e))return!1;let r=e.parse(t);return e===xu&&(r=function({hue:t,saturation:e,lightness:n,alpha:r}){t/=360,n/=100;let i=0,o=0,s=0;if(e/=100){const r=n<.5?n*(1+e):n+e-n*e,a=2*n-r;i=Lc(a,r,t+1/3),o=Lc(a,r,t),s=Lc(a,r,t-1/3)}else i=o=s=n;return{red:Math.round(255*i),green:Math.round(255*o),blue:Math.round(255*s),alpha:r}}(r)),r}const Bc=(t,e)=>{const n=Ic(t),r=Ic(e);if(!n||!r)return Dc(t,e);const i={...n};return t=>(i.red=Vc(n.red,r.red,t),i.green=Vc(n.green,r.green,t),i.blue=Vc(n.blue,r.blue,t),i.alpha=Fc(n.alpha,r.alpha,t),bu.transform(i))},Nc=new Set(["none","hidden"]);function Gc(t,e){return n=>Fc(t,e,n)}function Uc(t){return"number"==typeof t?Gc:"string"==typeof t?Dl(t)?Dc:Su.test(t)?Bc:$c:Array.isArray(t)?Wc:"object"==typeof t?Su.test(t)?Bc:Hc:Dc}function Wc(t,e){const n=[...t],r=n.length,i=t.map(((t,n)=>Uc(t)(t,e[n])));return t=>{for(let e=0;e<r;e++)n[e]=i[e](t);return n}}function Hc(t,e){const n={...t,...e},r={};for(const i in n)void 0!==t[i]&&void 0!==e[i]&&(r[i]=Uc(t[i])(t[i],e[i]));return t=>{for(const e in r)n[e]=r[e](t);return n}}const $c=(t,e)=>{const n=Lu.createTransformer(e),r=Ru(t),i=Ru(e);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Nc.has(t)&&!i.values.length||Nc.has(e)&&!r.values.length?function(t,e){return Nc.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}(t,e):Oc(Wc(function(t,e){var n;const r=[],i={color:0,var:0,number:0};for(let o=0;o<e.values.length;o++){const s=e.types[o],a=t.indexes[s][i[s]],l=null!==(n=t.values[a])&&void 0!==n?n:0;r[o]=l,i[s]++}return r}(r,i),i.values),n):Dc(t,e)};function zc(t,e,n){if("number"==typeof t&&"number"==typeof e&&"number"==typeof n)return Fc(t,e,n);return Uc(t)(t,e)}function qc(t,e,{clamp:n=!0,ease:r,mixer:i}={}){const o=t.length;if(Rl(o===e.length),1===o)return()=>e[0];if(2===o&&t[0]===t[1])return()=>e[1];t[0]>t[o-1]&&(t=[...t].reverse(),e=[...e].reverse());const s=function(t,e,n){const r=[],i=n||zc,o=t.length-1;for(let s=0;s<o;s++){let n=i(t[s],t[s+1]);if(e){const t=Array.isArray(e)?e[s]||xl:e;n=Oc(t,n)}r.push(n)}return r}(e,r,i),a=s.length,l=e=>{let n=0;if(a>1)for(;n<t.length-2&&!(e<t[n+1]);n++);const r=Mc(t[n],t[n+1],e);return s[n](r)};return n?e=>l(Bl(t[0],t[o-1],e)):l}function Kc(t){const e=[0];return function(t,e){const n=t[t.length-1];for(let r=1;r<=e;r++){const i=Mc(0,e,r);t.push(Fc(n,1,i))}}(e,t.length-1),e}function Yc({duration:t=300,keyframes:e,times:n,ease:r="easeInOut"}){const i=(t=>Array.isArray(t)&&"number"!=typeof t[0])(r)?r.map(Cc):Cc(r),o={done:!1,value:e[0]},s=function(t,e){return t.map((t=>t*e))}(n&&n.length===e.length?n:Kc(e),t),a=qc(s,e,{ease:Array.isArray(i)?i:(l=e,u=i,l.map((()=>u||bc)).splice(0,l.length-1))});var l,u;return{calculatedDuration:t,next:e=>(o.value=a(e),o.done=e>=t,o)}}const Qc=t=>{const e=({timestamp:e})=>t(e);return{start:()=>kl.update(e,!0),stop:()=>Pl(e),now:()=>Tl.isProcessing?Tl.timestamp:Yu.now()}},Xc={decay:pc,inertia:pc,tween:Yc,keyframes:Yc,spring:hc},Zc=t=>t/100;class Jc extends Xu{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.teardown();const{onStop:t}=this.options;t&&t()};const{name:e,motionValue:n,element:r,keyframes:i}=this.options,o=(null==r?void 0:r.KeyframeResolver)||vu;this.resolver=new o(i,((t,e)=>this.onKeyframesResolved(t,e)),e,n,r),this.resolver.scheduleResolve()}initPlayback(t){const{type:e="keyframes",repeat:n=0,repeatDelay:r=0,repeatType:i,velocity:o=0}=this.options,s=Xc[e]||Yc;let a,l;s!==Yc&&"number"!=typeof t[0]&&(a=Oc(Zc,zc(t[0],t[1])),t=[0,100]);const u=s({...this.options,keyframes:t});"mirror"===i&&(l=s({...this.options,keyframes:[...t].reverse(),velocity:-o})),null===u.calculatedDuration&&(u.calculatedDuration=function(t){let e=0,n=t.next(e);for(;!n.done&&e<2e4;)e+=50,n=t.next(e);return e>=2e4?1/0:e}(u));const{calculatedDuration:c}=u,d=c+r;return{generator:u,mirroredGenerator:l,mapPercentToKeyframes:a,calculatedDuration:c,resolvedDuration:d,totalDuration:d*(n+1)-r}}onPostResolved(){const{autoplay:t=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&t?this.state=this.pendingPlayState:this.pause()}tick(t,e=!1){const{resolved:n}=this;if(!n){const{keyframes:t}=this.options;return{done:!0,value:t[t.length-1]}}const{finalKeyframe:r,generator:i,mirroredGenerator:o,mapPercentToKeyframes:s,keyframes:a,calculatedDuration:l,totalDuration:u,resolvedDuration:c}=n;if(null===this.startTime)return i.next(0);const{delay:d,repeat:h,repeatType:p,repeatDelay:f,onUpdate:m}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-u/this.speed,this.startTime)),e?this.currentTime=t:null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;const v=this.currentTime-d*(this.speed>=0?1:-1),g=this.speed>=0?v<0:v>u;this.currentTime=Math.max(v,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=u);let y=this.currentTime,_=i;if(h){const t=Math.min(this.currentTime,u)/c;let e=Math.floor(t),n=t%1;!n&&t>=1&&(n=1),1===n&&e--,e=Math.min(e,h+1);Boolean(e%2)&&("reverse"===p?(n=1-n,f&&(n-=f/c)):"mirror"===p&&(_=o)),y=Bl(0,1,n)*c}const b=g?{done:!1,value:a[0]}:_.next(y);s&&(b.value=s(b.value));let{done:w}=b;g||null===l||(w=this.speed>=0?this.currentTime>=u:this.currentTime<=0);const x=null===this.holdTime&&("finished"===this.state||"running"===this.state&&w);return x&&void 0!==r&&(b.value=wl(a,this.options,r)),m&&m(b.value),x&&this.finish(),b}get duration(){const{resolved:t}=this;return t?pl(t.calculatedDuration):0}get time(){return pl(this.currentTime)}set time(t){t=hl(t),this.currentTime=t,null!==this.holdTime||0===this.speed?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){const e=this.playbackSpeed!==t;this.playbackSpeed=t,e&&(this.time=pl(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved)return void(this.pendingPlayState="running");if(this.isStopped)return;const{driver:t=Qc,onPlay:e,startTime:n}=this.options;this.driver||(this.driver=t((t=>this.tick(t)))),e&&e();const r=this.driver.now();null!==this.holdTime?this.startTime=r-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=r):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;this._resolved?(this.state="paused",this.holdTime=null!==(t=this.currentTime)&&void 0!==t?t:0):this.pendingPlayState="paused"}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:t}=this.options;t&&t()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}}const td=new Set(["opacity","clipPath","filter","transform"]),ed=t=>Array.isArray(t)&&"number"==typeof t[0];function nd(t){return Boolean(!t||"string"==typeof t&&t in id||ed(t)||Array.isArray(t)&&t.every(nd))}const rd=([t,e,n,r])=>`cubic-bezier(${t}, ${e}, ${n}, ${r})`,id={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:rd([0,.65,.55,1]),circOut:rd([.55,0,1,.45]),backIn:rd([.31,.01,.66,-.59]),backOut:rd([.33,1.53,.69,.99])};function od(t){return sd(t)||id.easeOut}function sd(t){return t?ed(t)?rd(t):Array.isArray(t)?t.map(od):id[t]:void 0}const ad=zu((()=>Object.hasOwnProperty.call(Element.prototype,"animate")));class ld extends Xu{constructor(t){super(t);const{name:e,motionValue:n,element:r,keyframes:i}=this.options;this.resolver=new $u(i,((t,e)=>this.onKeyframesResolved(t,e)),e,n,r),this.resolver.scheduleResolve()}initPlayback(t,e){var n;let{duration:r=300,times:i,ease:o,type:s,motionValue:a,name:l,startTime:u}=this.options;if(!(null===(n=a.owner)||void 0===n?void 0:n.current))return!1;if("spring"===(c=this.options).type||!nd(c.ease)){const{onComplete:e,onUpdate:n,motionValue:a,element:l,...u}=this.options,c=function(t,e){const n=new Jc({...e,keyframes:t,repeat:0,delay:0,isGenerator:!0});let r={done:!1,value:t[0]};const i=[];let o=0;for(;!r.done&&o<2e4;)r=n.sample(o),i.push(r.value),o+=10;return{times:void 0,keyframes:i,duration:o-10,ease:"linear"}}(t,u);1===(t=c.keyframes).length&&(t[1]=t[0]),r=c.duration,i=c.times,o=c.ease,s="keyframes"}var c;const d=function(t,e,n,{delay:r=0,duration:i=300,repeat:o=0,repeatType:s="loop",ease:a,times:l}={}){const u={[e]:n};l&&(u.offset=l);const c=sd(a);return Array.isArray(c)&&(u.easing=c),t.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:o+1,direction:"reverse"===s?"alternate":"normal"})}(a.owner.current,l,t,{...this.options,duration:r,times:i,ease:o});return d.startTime=null!=u?u:this.calcStartTime(),this.pendingTimeline?(d.timeline=this.pendingTimeline,this.pendingTimeline=void 0):d.onfinish=()=>{const{onComplete:n}=this.options;a.set(wl(t,this.options,e)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:r,times:i,type:s,ease:o,keyframes:t}}get duration(){const{resolved:t}=this;if(!t)return 0;const{duration:e}=t;return pl(e)}get time(){const{resolved:t}=this;if(!t)return 0;const{animation:e}=t;return pl(e.currentTime||0)}set time(t){const{resolved:e}=this;if(!e)return;const{animation:n}=e;n.currentTime=hl(t)}get speed(){const{resolved:t}=this;if(!t)return 1;const{animation:e}=t;return e.playbackRate}set speed(t){const{resolved:e}=this;if(!e)return;const{animation:n}=e;n.playbackRate=t}get state(){const{resolved:t}=this;if(!t)return"idle";const{animation:e}=t;return e.playState}get startTime(){const{resolved:t}=this;if(!t)return null;const{animation:e}=t;return e.startTime}attachTimeline(t){if(this._resolved){const{resolved:e}=this;if(!e)return xl;const{animation:n}=e;n.timeline=t,n.onfinish=null}else this.pendingTimeline=t;return xl}play(){if(this.isStopped)return;const{resolved:t}=this;if(!t)return;const{animation:e}=t;"finished"===e.playState&&this.updateFinishedPromise(),e.play()}pause(){const{resolved:t}=this;if(!t)return;const{animation:e}=t;e.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:t}=this;if(!t)return;const{animation:e,keyframes:n,duration:r,type:i,ease:o,times:s}=t;if("idle"===e.playState||"finished"===e.playState)return;if(this.time){const{motionValue:t,onUpdate:e,onComplete:a,element:l,...u}=this.options,c=new Jc({...u,keyframes:n,duration:r,type:i,ease:o,times:s,isGenerator:!0}),d=hl(this.time);t.setWithVelocity(c.sample(d-10).value,c.sample(d).value,10)}const{onStop:a}=this.options;a&&a(),this.cancel()}complete(){const{resolved:t}=this;t&&t.animation.finish()}cancel(){const{resolved:t}=this;t&&t.animation.cancel()}static supports(t){const{motionValue:e,name:n,repeatDelay:r,repeatType:i,damping:o,type:s}=t;return ad()&&n&&td.has(n)&&e&&e.owner&&e.owner.current instanceof HTMLElement&&!e.owner.getProps().onUpdate&&!r&&"mirror"!==i&&0!==o&&"inertia"!==s}}const ud=zu((()=>void 0!==window.ScrollTimeline));class cd{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}then(t,e){return Promise.all(this.animations).then(t).catch(e)}getAll(t){return this.animations[0][t]}setAll(t,e){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=e}attachTimeline(t){const e=this.animations.map((e=>{if(!ud()||!e.attachTimeline)return e.pause(),function(t,e){let n;const r=()=>{const{currentTime:r}=e,i=(null===r?0:r.value)/100;n!==i&&t(i),n=i};return kl.update(r,!0),()=>Pl(r)}((t=>{e.time=e.duration*t}),t);e.attachTimeline(t)}));return()=>{e.forEach(((t,e)=>{t&&t(),this.animations[e].stop()}))}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let e=0;e<this.animations.length;e++)t=Math.max(t,this.animations[e].duration);return t}runAll(t){this.animations.forEach((e=>e[t]()))}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}const dd=(t,e,n,r={},i,o,s)=>a=>{const l=yl(r,t)||{},u=l.delay||r.delay||0;let{elapsed:c=0}=r;c-=hl(u);let d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity(),...l,delay:-c,onUpdate:t=>{e.set(t),l.onUpdate&&l.onUpdate(t)},onComplete:()=>{a(),l.onComplete&&l.onComplete(),s&&s()},onStop:s,name:t,motionValue:e,element:o?void 0:i};(function({when:t,delay:e,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:s,repeatDelay:a,from:l,elapsed:u,...c}){return!!Object.keys(c).length})(l)||(d={...d,...gl(t,d)}),d.duration&&(d.duration=hl(d.duration)),d.repeatDelay&&(d.repeatDelay=hl(d.repeatDelay)),void 0!==d.from&&(d.keyframes[0]=d.from);let h=!1;if((!1===d.type||0===d.duration&&!d.repeatDelay)&&(d.duration=0,0===d.delay&&(h=!0)),h&&!o&&void 0!==e.get()){const t=wl(d.keyframes,l);if(void 0!==t)return kl.update((()=>{d.onUpdate(t),d.onComplete()})),new cd([])}return!o&&ld.supports(d)?new ld(d):new Jc(d)},hd=t=>Boolean(t&&"object"==typeof t&&t.mix&&t.toValue),pd=t=>nl(t)?t[t.length-1]||0:t;function fd(t,e){-1===t.indexOf(e)&&t.push(e)}function md(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}class vd{constructor(){this.subscriptions=[]}add(t){return fd(this.subscriptions,t),()=>md(this.subscriptions,t)}notify(t,e,n){const r=this.subscriptions.length;if(r)if(1===r)this.subscriptions[0](t,e,n);else for(let i=0;i<r;i++){const r=this.subscriptions[i];r&&r(t,e,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}class gd{constructor(t,e={}){this.version="11.5.4",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(t,e=!0)=>{const n=Yu.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(t),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),e&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=e.owner}setCurrent(t){var e;this.current=t,this.updatedAt=Yu.now(),null===this.canTrackVelocity&&void 0!==t&&(this.canTrackVelocity=(e=this.current,!isNaN(parseFloat(e))))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,e){this.events[t]||(this.events[t]=new vd);const n=this.events[t].add(e);return"change"===t?()=>{n(),kl.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,e){this.passiveEffect=t,this.stopPassiveEffect=e}set(t,e=!0){e&&this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t,e)}setWithVelocity(t,e,n){this.set(e),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,e=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,e&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=Yu.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||t-this.updatedAt>30)return 0;const e=Math.min(this.updatedAt-this.prevUpdatedAt,30);return Zu(parseFloat(this.current)-parseFloat(this.prevFrameValue),e)}start(t){return this.stop(),new Promise((e=>{this.hasAnimated=!0,this.animation=t(e),this.events.animationStart&&this.events.animationStart.notify()})).then((()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()}))}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function yd(t,e){return new gd(t,e)}function _d(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,yd(n))}const bd=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),wd="data-"+bd("framerAppearId");function xd(t){return t.props[wd]}function Sd(t){return dl.has(t)?"transform":td.has(t)?bd(t):void 0}class Ed extends gd{constructor(){super(...arguments),this.output=[],this.counts=new Map}add(t){const e=Sd(t);if(!e)return;const n=this.counts.get(e)||0;this.counts.set(e,n+1),0===n&&(this.output.push(e),this.update());let r=!1;return()=>{if(r)return;r=!0;const t=this.counts.get(e)-1;this.counts.set(e,t),0===t&&(md(this.output,e),this.update())}}update(){this.set(this.output.length?this.output.join(", "):"auto")}}const kd=t=>Boolean(t&&t.getVelocity);function Pd(t,e){var n;if(!t.applyWillChange)return;let r=t.getValue("willChange");return r||(null===(n=t.props.style)||void 0===n?void 0:n.willChange)||(r=new Ed("auto"),t.addValue("willChange",r)),i=r,Boolean(kd(i)&&i.add)?r.add(e):void 0;var i}function Td({protectedKeys:t,needsAnimating:e},n){const r=t.hasOwnProperty(n)&&!0!==e[n];return e[n]=!1,r}function Ad(t,e,{delay:n=0,transitionOverride:r,type:i}={}){var o;let{transition:s=t.getDefaultTransition(),transitionEnd:a,...l}=e;r&&(s=r);const u=[],c=i&&t.animationState&&t.animationState.getState()[i];for(const d in l){const e=t.getValue(d,null!==(o=t.latestValues[d])&&void 0!==o?o:null),r=l[d];if(void 0===r||c&&Td(c,d))continue;const i={delay:n,...yl(s||{},d)};let a=!1;if(window.MotionHandoffAnimation){const e=xd(t);if(e){const t=window.MotionHandoffAnimation(e,d,kl);null!==t&&(i.startTime=t,a=!0)}}e.start(dd(d,e,r,t.shouldReduceMotion&&dl.has(d)?{type:!1}:i,t,a,Pd(t,d)));const h=e.animation;h&&u.push(h)}return a&&Promise.all(u).then((()=>{kl.update((()=>{a&&function(t,e){const n=al(t,e);let{transitionEnd:r={},transition:i={},...o}=n||{};o={...o,...r};for(const s in o)_d(t,s,pd(o[s]))}(t,a)}))})),u}function Cd(t,e,n={}){var r;const i=al(t,e,"exit"===n.type?null===(r=t.presenceContext)||void 0===r?void 0:r.custom:void 0);let{transition:o=t.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(o=n.transitionOverride);const s=i?()=>Promise.all(Ad(t,i,n)):()=>Promise.resolve(),a=t.variantChildren&&t.variantChildren.size?(r=0)=>{const{delayChildren:i=0,staggerChildren:s,staggerDirection:a}=o;return function(t,e,n=0,r=0,i=1,o){const s=[],a=(t.variantChildren.size-1)*r,l=1===i?(t=0)=>t*r:(t=0)=>a-t*r;return Array.from(t.variantChildren).sort(Rd).forEach(((t,r)=>{t.notify("AnimationStart",e),s.push(Cd(t,e,{...o,delay:n+l(r)}).then((()=>t.notify("AnimationComplete",e))))})),Promise.all(s)}(t,e,i+r,s,a,n)}:()=>Promise.resolve(),{when:l}=o;if(l){const[t,e]="beforeChildren"===l?[s,a]:[a,s];return t().then((()=>e()))}return Promise.all([s(),a(n.delay)])}function Rd(t,e){return t.sortNodePosition(e)}const Od=[...ll].reverse(),Md=ll.length;function Fd(t){return e=>Promise.all(e.map((({animation:e,options:n})=>function(t,e,n={}){let r;if(t.notify("AnimationStart",e),Array.isArray(e)){const i=e.map((e=>Cd(t,e,n)));r=Promise.all(i)}else if("string"==typeof e)r=Cd(t,e,n);else{const i="function"==typeof e?al(t,e,n.custom):e;r=Promise.all(Ad(t,i,n))}return r.then((()=>{t.notify("AnimationComplete",e)}))}(t,e,n))))}function Ld(t,e){return"string"==typeof e?e!==t:!!Array.isArray(e)&&!rl(e,t)}function Dd(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Vd(){return{animate:Dd(!0),whileInView:Dd(),whileHover:Dd(),whileTap:Dd(),whileDrag:Dd(),whileFocus:Dd(),exit:Dd()}}class jd{constructor(t){this.isMounted=!1,this.node=t}update(){}}let Id=0;const Bd={animation:{Feature:class extends jd{constructor(t){super(t),t.animationState||(t.animationState=function(t){let e=Fd(t),n=Vd(),r=!0;const i=e=>(n,r)=>{var i;const o=al(t,r,"exit"===e?null===(i=t.presenceContext)||void 0===i?void 0:i.custom:void 0);if(o){const{transition:t,transitionEnd:e,...r}=o;n={...n,...r,...e}}return n};function o(o){const s=t.getProps(),a=t.getVariantContext(!0)||{},l=[],u=new Set;let c={},d=1/0;for(let e=0;e<Md;e++){const h=Od[e],p=n[h],f=void 0!==s[h]?s[h]:a[h],m=il(f),v=h===o?p.isActive:null;!1===v&&(d=e);let g=f===a[h]&&f!==s[h]&&m;if(g&&r&&t.manuallyAnimateOnMount&&(g=!1),p.protectedKeys={...c},!p.isActive&&null===v||!f&&!p.prevProp||el(f)||"boolean"==typeof f)continue;let y=Ld(p.prevProp,f)||h===o&&p.isActive&&!g&&m||e>d&&m,_=!1;const b=Array.isArray(f)?f:[f];let w=b.reduce(i(h),{});!1===v&&(w={});const{prevResolvedValues:x={}}=p,S={...x,...w},E=e=>{y=!0,u.has(e)&&(_=!0,u.delete(e)),p.needsAnimating[e]=!0;const n=t.getValue(e);n&&(n.liveStyle=!1)};for(const t in S){const e=w[t],n=x[t];if(c.hasOwnProperty(t))continue;let r=!1;r=nl(e)&&nl(n)?!rl(e,n):e!==n,r?null!=e?E(t):u.add(t):void 0!==e&&u.has(t)?E(t):p.protectedKeys[t]=!0}p.prevProp=f,p.prevResolvedValues=w,p.isActive&&(c={...c,...w}),r&&t.blockInitialAnimation&&(y=!1),!y||g&&!_||l.push(...b.map((t=>({animation:t,options:{type:h}}))))}if(u.size){const e={};u.forEach((n=>{const r=t.getBaseTarget(n),i=t.getValue(n);i&&(i.liveStyle=!0),e[n]=null!=r?r:null})),l.push({animation:e})}let h=Boolean(l.length);return!r||!1!==s.initial&&s.initial!==s.animate||t.manuallyAnimateOnMount||(h=!1),r=!1,h?e(l):Promise.resolve()}return{animateChanges:o,setActive:function(e,r){var i;if(n[e].isActive===r)return Promise.resolve();null===(i=t.variantChildren)||void 0===i||i.forEach((t=>{var n;return null===(n=t.animationState)||void 0===n?void 0:n.setActive(e,r)})),n[e].isActive=r;const s=o(e);for(const t in n)n[t].protectedKeys={};return s},setAnimateFunction:function(n){e=n(t)},getState:()=>n,reset:()=>{n=Vd(),r=!0}}}(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();el(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:e}=this.node.prevProps||{};t!==e&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),null===(t=this.unmountControls)||void 0===t||t.call(this)}}},exit:{Feature:class extends jd{constructor(){super(...arguments),this.id=Id++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:e}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===n)return;const r=this.node.animationState.setActive("exit",!t);e&&!t&&r.then((()=>e(this.id)))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}}},Nd=t=>"mouse"===t.pointerType?"number"!=typeof t.button||t.button<=0:!1!==t.isPrimary;function Gd(t,e="page"){return{point:{x:t[`${e}X`],y:t[`${e}Y`]}}}const Ud=t=>e=>Nd(e)&&t(e,Gd(e));function Wd(t,e,n,r={passive:!0}){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n)}function Hd(t,e,n,r){return Wd(t,e,Ud(n),r)}const $d=(t,e)=>Math.abs(t-e);class zd{constructor(t,e,{transformPagePoint:n,contextWindow:r,dragSnapToOrigin:i=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!this.lastMoveEvent||!this.lastMoveEventInfo)return;const t=Yd(this.lastMoveEventInfo,this.history),e=null!==this.startEvent,n=function(t,e){const n=$d(t.x,e.x),r=$d(t.y,e.y);return Math.sqrt(n**2+r**2)}(t.offset,{x:0,y:0})>=3;if(!e&&!n)return;const{point:r}=t,{timestamp:i}=Tl;this.history.push({...r,timestamp:i});const{onStart:o,onMove:s}=this.handlers;e||(o&&o(this.lastMoveEvent,t),this.startEvent=this.lastMoveEvent),s&&s(this.lastMoveEvent,t)},this.handlePointerMove=(t,e)=>{this.lastMoveEvent=t,this.lastMoveEventInfo=qd(e,this.transformPagePoint),kl.update(this.updatePoint,!0)},this.handlePointerUp=(t,e)=>{this.end();const{onEnd:n,onSessionEnd:r,resumeAnimation:i}=this.handlers;if(this.dragSnapToOrigin&&i&&i(),!this.lastMoveEvent||!this.lastMoveEventInfo)return;const o=Yd("pointercancel"===t.type?this.lastMoveEventInfo:qd(e,this.transformPagePoint),this.history);this.startEvent&&n&&n(t,o),r&&r(t,o)},!Nd(t))return;this.dragSnapToOrigin=i,this.handlers=e,this.transformPagePoint=n,this.contextWindow=r||window;const o=qd(Gd(t),this.transformPagePoint),{point:s}=o,{timestamp:a}=Tl;this.history=[{...s,timestamp:a}];const{onSessionStart:l}=e;l&&l(t,Yd(o,this.history)),this.removeListeners=Oc(Hd(this.contextWindow,"pointermove",this.handlePointerMove),Hd(this.contextWindow,"pointerup",this.handlePointerUp),Hd(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Pl(this.updatePoint)}}function qd(t,e){return e?{point:e(t.point)}:t}function Kd(t,e){return{x:t.x-e.x,y:t.y-e.y}}function Yd({point:t},e){return{point:t,delta:Kd(t,Xd(e)),offset:Kd(t,Qd(e)),velocity:Zd(e,.1)}}function Qd(t){return t[0]}function Xd(t){return t[t.length-1]}function Zd(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,r=null;const i=Xd(t);for(;n>=0&&(r=t[n],!(i.timestamp-r.timestamp>hl(e)));)n--;if(!r)return{x:0,y:0};const o=pl(i.timestamp-r.timestamp);if(0===o)return{x:0,y:0};const s={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function Jd(t){let e=null;return()=>{const n=()=>{e=null};return null===e&&(e=t,n)}}const th=Jd("dragHorizontal"),eh=Jd("dragVertical");function nh(t){let e=!1;if("y"===t)e=eh();else if("x"===t)e=th();else{const t=th(),n=eh();t&&n?e=()=>{t(),n()}:(t&&t(),n&&n())}return e}function rh(){const t=nh(!0);return!t||(t(),!1)}function ih(t){return t&&"object"==typeof t&&Object.prototype.hasOwnProperty.call(t,"current")}const oh=.9999,sh=1.0001,ah=-.01,lh=.01;function uh(t){return t.max-t.min}function ch(t,e,n,r=.5){t.origin=r,t.originPoint=Fc(e.min,e.max,t.origin),t.scale=uh(n)/uh(e),t.translate=Fc(n.min,n.max,t.origin)-t.originPoint,(t.scale>=oh&&t.scale<=sh||isNaN(t.scale))&&(t.scale=1),(t.translate>=ah&&t.translate<=lh||isNaN(t.translate))&&(t.translate=0)}function dh(t,e,n,r){ch(t.x,e.x,n.x,r?r.originX:void 0),ch(t.y,e.y,n.y,r?r.originY:void 0)}function hh(t,e,n){t.min=n.min+e.min,t.max=t.min+uh(e)}function ph(t,e,n){t.min=e.min-n.min,t.max=t.min+uh(e)}function fh(t,e,n){ph(t.x,e.x,n.x),ph(t.y,e.y,n.y)}function mh(t,e,n){return{min:void 0!==e?t.min+e:void 0,max:void 0!==n?t.max+n-(t.max-t.min):void 0}}function vh(t,e){let n=e.min-t.min,r=e.max-t.max;return e.max-e.min<t.max-t.min&&([n,r]=[r,n]),{min:n,max:r}}const gh=.35;function yh(t,e,n){return{min:_h(t,e),max:_h(t,n)}}function _h(t,e){return"number"==typeof t?t:t[e]||0}const bh=()=>({x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}}),wh=()=>({x:{min:0,max:0},y:{min:0,max:0}});function xh(t){return[t("x"),t("y")]}function Sh({top:t,left:e,right:n,bottom:r}){return{x:{min:e,max:n},y:{min:t,max:r}}}function Eh(t){return void 0===t||1===t}function kh({scale:t,scaleX:e,scaleY:n}){return!Eh(t)||!Eh(e)||!Eh(n)}function Ph(t){return kh(t)||Th(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function Th(t){return Ah(t.x)||Ah(t.y)}function Ah(t){return t&&"0%"!==t}function Ch(t,e,n){return n+e*(t-n)}function Rh(t,e,n,r,i){return void 0!==i&&(t=Ch(t,i,r)),Ch(t,n,r)+e}function Oh(t,e=0,n=1,r,i){t.min=Rh(t.min,e,n,r,i),t.max=Rh(t.max,e,n,r,i)}function Mh(t,{x:e,y:n}){Oh(t.x,e.translate,e.scale,e.originPoint),Oh(t.y,n.translate,n.scale,n.originPoint)}const Fh=.999999999999,Lh=1.0000000000001;function Dh(t,e){t.min=t.min+e,t.max=t.max+e}function Vh(t,e,n,r,i=.5){Oh(t,e,n,Fc(t.min,t.max,i),r)}function jh(t,e){Vh(t.x,e.x,e.scaleX,e.scale,e.originX),Vh(t.y,e.y,e.scaleY,e.scale,e.originY)}function Ih(t,e){return Sh(function(t,e){if(!e)return t;const n=e({x:t.left,y:t.top}),r=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(t.getBoundingClientRect(),e))}const Bh=({current:t})=>t?t.ownerDocument.defaultView:null,Nh=new WeakMap;class Gh{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=wh(),this.visualElement=t}start(t,{snapToCursor:e=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;const{dragSnapToOrigin:r}=this.getProps();this.panSession=new zd(t,{onSessionStart:t=>{const{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),e&&this.snapToCursor(Gd(t,"page").point)},onStart:(t,e)=>{var n;const{drag:r,dragPropagation:i,onDragStart:o}=this.getProps();if(r&&!i&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=nh(r),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),xh((t=>{let e=this.getAxisMotionValue(t).get()||0;if(Ql.test(e)){const{projection:n}=this.visualElement;if(n&&n.layout){const r=n.layout.layoutBox[t];if(r){e=uh(r)*(parseFloat(e)/100)}}}this.originPoint[t]=e})),o&&kl.postRender((()=>o(t,e))),null===(n=this.removeWillChange)||void 0===n||n.call(this),this.removeWillChange=Pd(this.visualElement,"transform");const{animationState:s}=this.visualElement;s&&s.setActive("whileDrag",!0)},onMove:(t,e)=>{const{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:o}=this.getProps();if(!n&&!this.openGlobalLock)return;const{offset:s}=e;if(r&&null===this.currentDirection)return this.currentDirection=function(t,e=10){let n=null;Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x");return n}(s),void(null!==this.currentDirection&&i&&i(this.currentDirection));this.updateAxis("x",e.point,s),this.updateAxis("y",e.point,s),this.visualElement.render(),o&&o(t,e)},onSessionEnd:(t,e)=>this.stop(t,e),resumeAnimation:()=>xh((t=>{var e;return"paused"===this.getAnimationState(t)&&(null===(e=this.getAxisMotionValue(t).animation)||void 0===e?void 0:e.play())}))},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:r,contextWindow:Bh(this.visualElement)})}stop(t,e){var n;null===(n=this.removeWillChange)||void 0===n||n.call(this);const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:i}=e;this.startAnimation(i);const{onDragEnd:o}=this.getProps();o&&kl.postRender((()=>o(t,e)))}cancel(){this.isDragging=!1;const{projection:t,animationState:e}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),e&&e.setActive("whileDrag",!1)}updateAxis(t,e,n){const{drag:r}=this.getProps();if(!n||!Uh(t,r,this.currentDirection))return;const i=this.getAxisMotionValue(t);let o=this.originPoint[t]+n[t];this.constraints&&this.constraints[t]&&(o=function(t,{min:e,max:n},r){return void 0!==e&&t<e?t=r?Fc(e,t,r.min):Math.max(t,e):void 0!==n&&t>n&&(t=r?Fc(n,t,r.max):Math.min(t,n)),t}(o,this.constraints[t],this.elastic[t])),i.set(o)}resolveConstraints(){var t;const{dragConstraints:e,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null===(t=this.visualElement.projection)||void 0===t?void 0:t.layout,i=this.constraints;e&&ih(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):this.constraints=!(!e||!r)&&function(t,{top:e,left:n,bottom:r,right:i}){return{x:mh(t.x,n,i),y:mh(t.y,e,r)}}(r.layoutBox,e),this.elastic=function(t=gh){return!1===t?t=0:!0===t&&(t=gh),{x:yh(t,"left","right"),y:yh(t,"top","bottom")}}(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&xh((t=>{!1!==this.constraints&&this.getAxisMotionValue(t)&&(this.constraints[t]=function(t,e){const n={};return void 0!==e.min&&(n.min=e.min-t.min),void 0!==e.max&&(n.max=e.max-t.min),n}(r.layoutBox[t],this.constraints[t]))}))}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:e}=this.getProps();if(!t||!ih(t))return!1;const n=t.current,{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const i=function(t,e,n){const r=Ih(t,n),{scroll:i}=e;return i&&(Dh(r.x,i.offset.x),Dh(r.y,i.offset.y)),r}(n,r.root,this.visualElement.getTransformPagePoint());let o=function(t,e){return{x:vh(t.x,e.x),y:vh(t.y,e.y)}}(r.layout.layoutBox,i);if(e){const t=e(function({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}(o));this.hasMutatedConstraints=!!t,t&&(o=Sh(t))}return o}startAnimation(t){const{drag:e,dragMomentum:n,dragElastic:r,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:s}=this.getProps(),a=this.constraints||{},l=xh((s=>{if(!Uh(s,e,this.currentDirection))return;let l=a&&a[s]||{};o&&(l={min:0,max:0});const u=r?200:1e6,c=r?40:1e7,d={type:"inertia",velocity:n?t[s]:0,bounceStiffness:u,bounceDamping:c,timeConstant:750,restDelta:1,restSpeed:10,...i,...l};return this.startAxisValueAnimation(s,d)}));return Promise.all(l).then(s)}startAxisValueAnimation(t,e){const n=this.getAxisMotionValue(t);return n.start(dd(t,n,0,e,this.visualElement,!1,Pd(this.visualElement,t)))}stopAnimation(){xh((t=>this.getAxisMotionValue(t).stop()))}pauseAnimation(){xh((t=>{var e;return null===(e=this.getAxisMotionValue(t).animation)||void 0===e?void 0:e.pause()}))}getAnimationState(t){var e;return null===(e=this.getAxisMotionValue(t).animation)||void 0===e?void 0:e.state}getAxisMotionValue(t){const e=`_drag${t.toUpperCase()}`,n=this.visualElement.getProps(),r=n[e];return r||this.visualElement.getValue(t,(n.initial?n.initial[t]:void 0)||0)}snapToCursor(t){xh((e=>{const{drag:n}=this.getProps();if(!Uh(e,n,this.currentDirection))return;const{projection:r}=this.visualElement,i=this.getAxisMotionValue(e);if(r&&r.layout){const{min:n,max:o}=r.layout.layoutBox[e];i.set(t[e]-Fc(n,o,.5))}}))}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:e}=this.getProps(),{projection:n}=this.visualElement;if(!ih(e)||!n||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};xh((t=>{const e=this.getAxisMotionValue(t);if(e&&!1!==this.constraints){const n=e.get();r[t]=function(t,e){let n=.5;const r=uh(t),i=uh(e);return i>r?n=Mc(e.min,e.max-r,t.min):r>i&&(n=Mc(t.min,t.max-i,e.min)),Bl(0,1,n)}({min:n,max:n},this.constraints[t])}}));const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),xh((e=>{if(!Uh(e,t,null))return;const n=this.getAxisMotionValue(e),{min:i,max:o}=this.constraints[e];n.set(Fc(i,o,r[e]))}))}addListeners(){if(!this.visualElement.current)return;Nh.set(this.visualElement,this);const t=Hd(this.visualElement.current,"pointerdown",(t=>{const{drag:e,dragListener:n=!0}=this.getProps();e&&n&&this.start(t)})),e=()=>{const{dragConstraints:t}=this.getProps();ih(t)&&t.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",e);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),kl.read(e);const i=Wd(window,"resize",(()=>this.scalePositionWithinConstraints())),o=n.addEventListener("didUpdate",(({delta:t,hasLayoutChanged:e})=>{this.isDragging&&e&&(xh((e=>{const n=this.getAxisMotionValue(e);n&&(this.originPoint[e]+=t[e].translate,n.set(n.get()+t[e].translate))})),this.visualElement.render())}));return()=>{i(),t(),r(),o&&o()}}getProps(){const t=this.visualElement.getProps(),{drag:e=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:o=gh,dragMomentum:s=!0}=t;return{...t,drag:e,dragDirectionLock:n,dragPropagation:r,dragConstraints:i,dragElastic:o,dragMomentum:s}}}function Uh(t,e,n){return!(!0!==e&&e!==t||null!==n&&n!==t)}const Wh=t=>(e,n)=>{t&&kl.postRender((()=>t(e,n)))};const Hh=oe(null);const $h=oe({}),zh=oe({}),qh={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Kh(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}const Yh={correct:(t,e)=>{if(!e.target)return t;if("string"==typeof t){if(!Xl.test(t))return t;t=parseFloat(t)}return`${Kh(t,e.target.x)}% ${Kh(t,e.target.y)}%`}},Qh={correct:(t,{treeScale:e,projectionDelta:n})=>{const r=t,i=Lu.parse(t);if(i.length>5)return r;const o=Lu.createTransformer(t),s="number"!=typeof i[0]?1:0,a=n.x.scale*e.x,l=n.y.scale*e.y;i[0+s]/=a,i[1+s]/=l;const u=Fc(a,l,.5);return"number"==typeof i[2+s]&&(i[2+s]/=u),"number"==typeof i[3+s]&&(i[3+s]/=u),o(i)}},Xh={};const{schedule:Zh,cancel:Jh}=El(queueMicrotask,!1);class tp extends Bt{componentDidMount(){const{visualElement:t,layoutGroup:e,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=t;var o;o=np,Object.assign(Xh,o),i&&(e.group&&e.group.add(i),n&&n.register&&r&&n.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",(()=>{this.safeToRemove()})),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),qh.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:e,visualElement:n,drag:r,isPresent:i}=this.props,o=n.projection;return o?(o.isPresent=i,r||t.layoutDependency!==e||void 0===e?o.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?o.promote():o.relegate()||kl.postRender((()=>{const t=o.getStack();t&&t.members.length||this.safeToRemove()}))),null):null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Zh.postRender((()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()})))}componentWillUnmount(){const{visualElement:t,layoutGroup:e,switchLayoutGroup:n}=this.props,{projection:r}=t;r&&(r.scheduleCheckAfterUnmount(),e&&e.group&&e.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function ep(t){const[e,n]=function(){const t=Bn(Hh);if(null===t)return[!0,null];const{isPresent:e,onExitComplete:n,register:r}=t,i=Gn();Fn((()=>r(i)),[]);const o=In((()=>n&&n(i)),[i,n]);return!e&&n?[!1,o]:[!0]}(),r=Bn($h);return no(tp,{...t,layoutGroup:r,switchLayoutGroup:Bn(zh),isPresent:e,safeToRemove:n})}const np={borderRadius:{...Yh,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Yh,borderTopRightRadius:Yh,borderBottomLeftRadius:Yh,borderBottomRightRadius:Yh,boxShadow:Qh},rp=["TopLeft","TopRight","BottomLeft","BottomRight"],ip=rp.length,op=t=>"string"==typeof t?parseFloat(t):t,sp=t=>"number"==typeof t||Xl.test(t);function ap(t,e){return void 0!==t[e]?t[e]:t.borderRadius}const lp=cp(0,.5,Ec),up=cp(.5,.95,xl);function cp(t,e,n){return r=>r<t?0:r>e?1:n(Mc(t,e,r))}function dp(t,e){t.min=e.min,t.max=e.max}function hp(t,e){dp(t.x,e.x),dp(t.y,e.y)}function pp(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}function fp(t,e,n,r,i){return t=Ch(t-=e,1/n,r),void 0!==i&&(t=Ch(t,1/i,r)),t}function mp(t,e,[n,r,i],o,s){!function(t,e=0,n=1,r=.5,i,o=t,s=t){Ql.test(e)&&(e=parseFloat(e),e=Fc(s.min,s.max,e/100)-s.min);if("number"!=typeof e)return;let a=Fc(o.min,o.max,r);t===o&&(a-=e),t.min=fp(t.min,e,n,a,i),t.max=fp(t.max,e,n,a,i)}(t,e[n],e[r],e[i],e.scale,o,s)}const vp=["x","scaleX","originX"],gp=["y","scaleY","originY"];function yp(t,e,n,r){mp(t.x,e,vp,n?n.x:void 0,r?r.x:void 0),mp(t.y,e,gp,n?n.y:void 0,r?r.y:void 0)}function _p(t){return 0===t.translate&&1===t.scale}function bp(t){return _p(t.x)&&_p(t.y)}function wp(t,e){return t.min===e.min&&t.max===e.max}function xp(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function Sp(t,e){return xp(t.x,e.x)&&xp(t.y,e.y)}function Ep(t){return uh(t.x)/uh(t.y)}function kp(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}class Pp{constructor(){this.members=[]}add(t){fd(this.members,t),t.scheduleRender()}remove(t){if(md(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const t=this.members[this.members.length-1];t&&this.promote(t)}}relegate(t){const e=this.members.findIndex((e=>t===e));if(0===e)return!1;let n;for(let r=e;r>=0;r--){const t=this.members[r];if(!1!==t.isPresent){n=t;break}}return!!n&&(this.promote(n),!0)}promote(t,e){const n=this.lead;if(t!==n&&(this.prevLead=n,this.lead=t,t.show(),n)){n.instance&&n.scheduleRender(),t.scheduleRender(),t.resumeFrom=n,e&&(t.resumeFrom.preserveOpacity=!0),n.snapshot&&(t.snapshot=n.snapshot,t.snapshot.latestValues=n.animationValues||n.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:r}=t.options;!1===r&&n.hide()}}exitAnimationComplete(){this.members.forEach((t=>{const{options:e,resumingFrom:n}=t;e.onExitComplete&&e.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()}))}scheduleRender(){this.members.forEach((t=>{t.instance&&t.scheduleRender(!1)}))}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const Tp=(t,e)=>t.depth-e.depth;class Ap{constructor(){this.children=[],this.isDirty=!1}add(t){fd(this.children,t),this.isDirty=!0}remove(t){md(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(Tp),this.isDirty=!1,this.children.forEach(t)}}function Cp(t){const e=kd(t)?t.get():t;return hd(e)?e.toValue():e}const Rp={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},Op="undefined"!=typeof window&&void 0!==window.MotionDebug,Mp=["","X","Y","Z"],Fp={visibility:"hidden"};let Lp=0;function Dp(t,e,n,r){const{latestValues:i}=e;i[t]&&(n[t]=i[t],e.setStaticValue(t,0),r&&(r[t]=0))}function Vp(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;const{visualElement:e}=t.options;if(!e)return;const n=xd(e);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:e,layoutId:r}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",kl,!(e||r))}const{parent:r}=t;r&&!r.hasCheckedOptimisedAppear&&Vp(r)}function jp({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(t={},n=(null==e?void 0:e())){this.id=Lp++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,Op&&(Rp.totalNodes=Rp.resolvedTargetDeltas=Rp.recalculatedProjection=0),this.nodes.forEach(Np),this.nodes.forEach(qp),this.nodes.forEach(Kp),this.nodes.forEach(Gp),Op&&window.MotionDebug.record(Rp)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=t,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;e<this.path.length;e++)this.path[e].shouldResetTransform=!0;this.root===this&&(this.nodes=new Ap)}addEventListener(t,e){return this.eventHandlers.has(t)||this.eventHandlers.set(t,new vd),this.eventHandlers.get(t).add(e)}notifyListeners(t,...e){const n=this.eventHandlers.get(t);n&&n.notify(...e)}hasListeners(t){return this.eventHandlers.has(t)}mount(e,n=this.root.hasTreeAnimated){if(this.instance)return;var r;this.isSVG=(r=e)instanceof SVGElement&&"svg"!==r.tagName,this.instance=e;const{layoutId:i,layout:o,visualElement:s}=this.options;if(s&&!s.current&&s.mount(e),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),n&&(o||i)&&(this.isLayoutDirty=!0),t){let n;const r=()=>this.root.updateBlockedByResize=!1;t(e,(()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(t,e){const n=Yu.now(),r=({timestamp:i})=>{const o=i-n;o>=e&&(Pl(r),t(o-e))};return kl.read(r,!0),()=>Pl(r)}(r,250),qh.hasAnimatedSinceResize&&(qh.hasAnimatedSinceResize=!1,this.nodes.forEach(zp))}))}i&&this.root.registerSharedNode(i,this),!1!==this.options.animate&&s&&(i||o)&&this.addEventListener("didUpdate",(({delta:t,hasLayoutChanged:e,hasRelativeTargetChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked())return this.target=void 0,void(this.relativeTarget=void 0);const i=this.options.transition||s.getDefaultTransition()||tf,{onLayoutAnimationStart:o,onLayoutAnimationComplete:a}=s.getProps(),l=!this.targetLayout||!Sp(this.targetLayout,r)||n,u=!e&&n;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||u||e&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(t,u);const e={...yl(i,"layout"),onPlay:o,onComplete:a};(s.shouldReduceMotion||this.options.layoutRoot)&&(e.delay=0,e.type=!1),this.startAnimation(e)}else e||zp(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const t=this.getStack();t&&t.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Pl(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Yp),this.animationId++)}getTransformTemplate(){const{visualElement:t}=this.options;return t&&t.getProps().transformTemplate}willUpdate(t=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked())return void(this.options.onExitComplete&&this.options.onExitComplete());if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Vp(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let i=0;i<this.path.length;i++){const t=this.path[i];t.shouldResetTransform=!0,t.updateScroll("snapshot"),t.options.layoutRoot&&t.willUpdate(!1)}const{layoutId:e,layout:n}=this.options;if(void 0===e&&!n)return;const r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,""):void 0,this.updateSnapshot(),t&&this.notifyListeners("willUpdate")}update(){this.updateScheduled=!1;if(this.isUpdateBlocked())return this.unblockUpdate(),this.clearAllSnapshots(),void this.nodes.forEach(Wp);this.isUpdating||this.nodes.forEach(Hp),this.isUpdating=!1,this.nodes.forEach($p),this.nodes.forEach(Ip),this.nodes.forEach(Bp),this.clearAllSnapshots();const t=Yu.now();Tl.delta=Bl(0,1e3/60,t-Tl.timestamp),Tl.timestamp=t,Tl.isProcessing=!0,Al.update.process(Tl),Al.preRender.process(Tl),Al.render.process(Tl),Tl.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Zh.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Up),this.sharedNodes.forEach(Qp)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,kl.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){kl.postRender((()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()}))}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure())}updateLayout(){if(!this.instance)return;if(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead()||this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let n=0;n<this.path.length;n++){this.path[n].updateScroll()}const t=this.layout;this.layout=this.measure(!1),this.layoutCorrected=wh(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:e}=this.options;e&&e.notify("LayoutMeasure",this.layout.layoutBox,t?t.layoutBox:void 0)}updateScroll(t="measure"){let e=Boolean(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===t&&(e=!1),e){const e=r(this.instance);this.scroll={animationId:this.root.animationId,phase:t,isRoot:e,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:e}}}resetTransform(){if(!i)return;const t=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,e=this.projectionDelta&&!bp(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,""):void 0,o=r!==this.prevTransformTemplateValue;t&&(e||Ph(this.latestValues)||o)&&(i(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(t=!0){const e=this.measurePageBox();let n=this.removeElementScroll(e);var r;return t&&(n=this.removeTransform(n)),rf((r=n).x),rf(r.y),{animationId:this.root.animationId,measuredBox:e,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){var t;const{visualElement:e}=this.options;if(!e)return wh();const n=e.measureViewportBox();if(!((null===(t=this.scroll)||void 0===t?void 0:t.wasRoot)||this.path.some(sf))){const{scroll:t}=this.root;t&&(Dh(n.x,t.offset.x),Dh(n.y,t.offset.y))}return n}removeElementScroll(t){var e;const n=wh();if(hp(n,t),null===(e=this.scroll)||void 0===e?void 0:e.wasRoot)return n;for(let r=0;r<this.path.length;r++){const e=this.path[r],{scroll:i,options:o}=e;e!==this.root&&i&&o.layoutScroll&&(i.wasRoot&&hp(n,t),Dh(n.x,i.offset.x),Dh(n.y,i.offset.y))}return n}applyTransform(t,e=!1){const n=wh();hp(n,t);for(let r=0;r<this.path.length;r++){const t=this.path[r];!e&&t.options.layoutScroll&&t.scroll&&t!==t.root&&jh(n,{x:-t.scroll.offset.x,y:-t.scroll.offset.y}),Ph(t.latestValues)&&jh(n,t.latestValues)}return Ph(this.latestValues)&&jh(n,this.latestValues),n}removeTransform(t){const e=wh();hp(e,t);for(let n=0;n<this.path.length;n++){const t=this.path[n];if(!t.instance)continue;if(!Ph(t.latestValues))continue;kh(t.latestValues)&&t.updateSnapshot();const r=wh();hp(r,t.measurePageBox()),yp(e,t.latestValues,t.snapshot?t.snapshot.layoutBox:void 0,r)}return Ph(this.latestValues)&&yp(e,this.latestValues),e}setTargetDelta(t){this.targetDelta=t,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(t){this.options={...this.options,...t,crossfade:void 0===t.crossfade||t.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Tl.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(t=!1){var e;const n=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=n.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=n.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=n.isSharedProjectionDirty);const r=Boolean(this.resumingFrom)||this!==n;if(!(t||r&&this.isSharedProjectionDirty||this.isProjectionDirty||(null===(e=this.parent)||void 0===e?void 0:e.isProjectionDirty)||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:i,layoutId:o}=this.options;if(this.layout&&(i||o)){if(this.resolvedRelativeTargetAt=Tl.timestamp,!this.targetDelta&&!this.relativeTarget){const t=this.getClosestProjectingParent();t&&t.layout&&1!==this.animationProgress?(this.relativeParent=t,this.forceRelativeParentToResolveTarget(),this.relativeTarget=wh(),this.relativeTargetOrigin=wh(),fh(this.relativeTargetOrigin,this.layout.layoutBox,t.layout.layoutBox),hp(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(this.relativeTarget||this.targetDelta){var s,a,l;if(this.target||(this.target=wh(),this.targetWithTransforms=wh()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),s=this.target,a=this.relativeTarget,l=this.relativeParent.target,hh(s.x,a.x,l.x),hh(s.y,a.y,l.y)):this.targetDelta?(Boolean(this.resumingFrom)?this.target=this.applyTransform(this.layout.layoutBox):hp(this.target,this.layout.layoutBox),Mh(this.target,this.targetDelta)):hp(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const t=this.getClosestProjectingParent();t&&Boolean(t.resumingFrom)===Boolean(this.resumingFrom)&&!t.options.layoutScroll&&t.target&&1!==this.animationProgress?(this.relativeParent=t,this.forceRelativeParentToResolveTarget(),this.relativeTarget=wh(),this.relativeTargetOrigin=wh(),fh(this.relativeTargetOrigin,this.target,t.target),hp(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}Op&&Rp.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(this.parent&&!kh(this.parent.latestValues)&&!Th(this.parent.latestValues))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return Boolean((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var t;const e=this.getLead(),n=Boolean(this.resumingFrom)||this!==e;let r=!0;if((this.isProjectionDirty||(null===(t=this.parent)||void 0===t?void 0:t.isProjectionDirty))&&(r=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(r=!1),this.resolvedRelativeTargetAt===Tl.timestamp&&(r=!1),r)return;const{layout:i,layoutId:o}=this.options;if(this.isTreeAnimating=Boolean(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!i&&!o)return;hp(this.layoutCorrected,this.layout.layoutBox);const s=this.treeScale.x,a=this.treeScale.y;!function(t,e,n,r=!1){const i=n.length;if(!i)return;let o,s;e.x=e.y=1;for(let a=0;a<i;a++){o=n[a],s=o.projectionDelta;const{visualElement:i}=o.options;i&&i.props.style&&"contents"===i.props.style.display||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&jh(t,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),s&&(e.x*=s.x.scale,e.y*=s.y.scale,Mh(t,s)),r&&Ph(o.latestValues)&&jh(t,o.latestValues))}e.x<Lh&&e.x>Fh&&(e.x=1),e.y<Lh&&e.y>Fh&&(e.y=1)}(this.layoutCorrected,this.treeScale,this.path,n),!e.layout||e.target||1===this.treeScale.x&&1===this.treeScale.y||(e.target=e.layout.layoutBox,e.targetWithTransforms=wh());const{target:l}=e;l?(this.projectionDelta&&this.prevProjectionDelta?(pp(this.prevProjectionDelta.x,this.projectionDelta.x),pp(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),dh(this.projectionDelta,this.layoutCorrected,l,this.latestValues),this.treeScale.x===s&&this.treeScale.y===a&&kp(this.projectionDelta.x,this.prevProjectionDelta.x)&&kp(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",l)),Op&&Rp.recalculatedProjection++):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(t=!0){var e;if(null===(e=this.options.visualElement)||void 0===e||e.scheduleRender(),t){const t=this.getStack();t&&t.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=bh(),this.projectionDelta=bh(),this.projectionDeltaWithTransform=bh()}setAnimationOrigin(t,e=!1){const n=this.snapshot,r=n?n.latestValues:{},i={...this.latestValues},o=bh();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!e;const s=wh(),a=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),l=this.getStack(),u=!l||l.members.length<=1,c=Boolean(a&&!u&&!0===this.options.crossfade&&!this.path.some(Jp));let d;this.animationProgress=0,this.mixTargetDelta=e=>{const n=e/1e3;var l,h,p,f,m,v;Xp(o.x,t.x,n),Xp(o.y,t.y,n),this.setTargetDelta(o),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(fh(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox),p=this.relativeTarget,f=this.relativeTargetOrigin,m=s,v=n,Zp(p.x,f.x,m.x,v),Zp(p.y,f.y,m.y,v),d&&(l=this.relativeTarget,h=d,wp(l.x,h.x)&&wp(l.y,h.y))&&(this.isProjectionDirty=!1),d||(d=wh()),hp(d,this.relativeTarget)),a&&(this.animationValues=i,function(t,e,n,r,i,o){i?(t.opacity=Fc(0,void 0!==n.opacity?n.opacity:1,lp(r)),t.opacityExit=Fc(void 0!==e.opacity?e.opacity:1,0,up(r))):o&&(t.opacity=Fc(void 0!==e.opacity?e.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let s=0;s<ip;s++){const i=`border${rp[s]}Radius`;let o=ap(e,i),a=ap(n,i);void 0===o&&void 0===a||(o||(o=0),a||(a=0),0===o||0===a||sp(o)===sp(a)?(t[i]=Math.max(Fc(op(o),op(a),r),0),(Ql.test(a)||Ql.test(o))&&(t[i]+="%")):t[i]=a)}(e.rotate||n.rotate)&&(t.rotate=Fc(e.rotate||0,n.rotate||0,r))}(i,r,this.latestValues,n,c,u)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(t){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(Pl(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=kl.update((()=>{qh.hasAnimatedSinceResize=!0,this.currentAnimation=function(t,e,n){const r=kd(t)?t:yd(t);return r.start(dd("",r,e,n)),r.animation}(0,1e3,{...t,onUpdate:e=>{this.mixTargetDelta(e),t.onUpdate&&t.onUpdate(e)},onComplete:()=>{t.onComplete&&t.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0}))}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const t=this.getStack();t&&t.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const t=this.getLead();let{targetWithTransforms:e,target:n,layout:r,latestValues:i}=t;if(e&&n&&r){if(this!==t&&this.layout&&r&&of(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||wh();const e=uh(this.layout.layoutBox.x);n.x.min=t.target.x.min,n.x.max=n.x.min+e;const r=uh(this.layout.layoutBox.y);n.y.min=t.target.y.min,n.y.max=n.y.min+r}hp(e,n),jh(e,i),dh(this.projectionDeltaWithTransform,this.layoutCorrected,e,i)}}registerSharedNode(t,e){this.sharedNodes.has(t)||this.sharedNodes.set(t,new Pp);this.sharedNodes.get(t).add(e);const n=e.options.initialPromotionConfig;e.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(e):void 0})}isLead(){const t=this.getStack();return!t||t.lead===this}getLead(){var t;const{layoutId:e}=this.options;return e&&(null===(t=this.getStack())||void 0===t?void 0:t.lead)||this}getPrevLead(){var t;const{layoutId:e}=this.options;return e?null===(t=this.getStack())||void 0===t?void 0:t.prevLead:void 0}getStack(){const{layoutId:t}=this.options;if(t)return this.root.sharedNodes.get(t)}promote({needsReset:t,transition:e,preserveFollowOpacity:n}={}){const r=this.getStack();r&&r.promote(this,n),t&&(this.projectionDelta=void 0,this.needsReset=!0),e&&this.setOptions({transition:e})}relegate(){const t=this.getStack();return!!t&&t.relegate(this)}resetSkewAndRotation(){const{visualElement:t}=this.options;if(!t)return;let e=!1;const{latestValues:n}=t;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(e=!0),!e)return;const r={};n.z&&Dp("z",t,r,this.animationValues);for(let i=0;i<Mp.length;i++)Dp(`rotate${Mp[i]}`,t,r,this.animationValues),Dp(`skew${Mp[i]}`,t,r,this.animationValues);t.render();for(const i in r)t.setStaticValue(i,r[i]),this.animationValues&&(this.animationValues[i]=r[i]);t.scheduleRender()}getProjectionStyles(t){var e,n;if(!this.instance||this.isSVG)return;if(!this.isVisible)return Fp;const r={visibility:""},i=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,r.opacity="",r.pointerEvents=Cp(null==t?void 0:t.pointerEvents)||"",r.transform=i?i(this.latestValues,""):"none",r;const o=this.getLead();if(!this.projectionDelta||!this.layout||!o.target){const e={};return this.options.layoutId&&(e.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,e.pointerEvents=Cp(null==t?void 0:t.pointerEvents)||""),this.hasProjected&&!Ph(this.latestValues)&&(e.transform=i?i({},""):"none",this.hasProjected=!1),e}const s=o.animationValues||o.latestValues;this.applyTransformsToTarget(),r.transform=function(t,e,n){let r="";const i=t.x.translate/e.x,o=t.y.translate/e.y,s=(null==n?void 0:n.z)||0;if((i||o||s)&&(r=`translate3d(${i}px, ${o}px, ${s}px) `),1===e.x&&1===e.y||(r+=`scale(${1/e.x}, ${1/e.y}) `),n){const{transformPerspective:t,rotate:e,rotateX:i,rotateY:o,skewX:s,skewY:a}=n;t&&(r=`perspective(${t}px) ${r}`),e&&(r+=`rotate(${e}deg) `),i&&(r+=`rotateX(${i}deg) `),o&&(r+=`rotateY(${o}deg) `),s&&(r+=`skewX(${s}deg) `),a&&(r+=`skewY(${a}deg) `)}const a=t.x.scale*e.x,l=t.y.scale*e.y;return 1===a&&1===l||(r+=`scale(${a}, ${l})`),r||"none"}(this.projectionDeltaWithTransform,this.treeScale,s),i&&(r.transform=i(s,r.transform));const{x:a,y:l}=this.projectionDelta;r.transformOrigin=`${100*a.origin}% ${100*l.origin}% 0`,o.animationValues?r.opacity=o===this?null!==(n=null!==(e=s.opacity)&&void 0!==e?e:this.latestValues.opacity)&&void 0!==n?n:1:this.preserveOpacity?this.latestValues.opacity:s.opacityExit:r.opacity=o===this?void 0!==s.opacity?s.opacity:"":void 0!==s.opacityExit?s.opacityExit:0;for(const u in Xh){if(void 0===s[u])continue;const{correct:t,applyTo:e}=Xh[u],n="none"===r.transform?s[u]:t(s[u],o);if(e){const t=e.length;for(let i=0;i<t;i++)r[e[i]]=n}else r[u]=n}return this.options.layoutId&&(r.pointerEvents=o===this?Cp(null==t?void 0:t.pointerEvents)||"":"none"),r}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach((t=>{var e;return null===(e=t.currentAnimation)||void 0===e?void 0:e.stop()})),this.root.nodes.forEach(Wp),this.root.sharedNodes.clear()}}}function Ip(t){t.updateLayout()}function Bp(t){var e;const n=(null===(e=t.resumeFrom)||void 0===e?void 0:e.snapshot)||t.snapshot;if(t.isLead()&&t.layout&&n&&t.hasListeners("didUpdate")){const{layoutBox:e,measuredBox:r}=t.layout,{animationType:i}=t.options,o=n.source!==t.layout.source;"size"===i?xh((t=>{const r=o?n.measuredBox[t]:n.layoutBox[t],i=uh(r);r.min=e[t].min,r.max=r.min+i})):of(i,n.layoutBox,e)&&xh((r=>{const i=o?n.measuredBox[r]:n.layoutBox[r],s=uh(e[r]);i.max=i.min+s,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[r].max=t.relativeTarget[r].min+s)}));const s=bh();dh(s,e,n.layoutBox);const a=bh();o?dh(a,t.applyTransform(r,!0),n.measuredBox):dh(a,e,n.layoutBox);const l=!bp(s);let u=!1;if(!t.resumeFrom){const r=t.getClosestProjectingParent();if(r&&!r.resumeFrom){const{snapshot:i,layout:o}=r;if(i&&o){const s=wh();fh(s,n.layoutBox,i.layoutBox);const a=wh();fh(a,e,o.layoutBox),Sp(s,a)||(u=!0),r.options.layoutRoot&&(t.relativeTarget=a,t.relativeTargetOrigin=s,t.relativeParent=r)}}}t.notifyListeners("didUpdate",{layout:e,snapshot:n,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeTargetChanged:u})}else if(t.isLead()){const{onExitComplete:e}=t.options;e&&e()}t.options.transition=void 0}function Np(t){Op&&Rp.totalNodes++,t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=Boolean(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function Gp(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function Up(t){t.clearSnapshot()}function Wp(t){t.clearMeasurements()}function Hp(t){t.isLayoutDirty=!1}function $p(t){const{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function zp(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function qp(t){t.resolveTargetDelta()}function Kp(t){t.calcProjection()}function Yp(t){t.resetSkewAndRotation()}function Qp(t){t.removeLeadSnapshot()}function Xp(t,e,n){t.translate=Fc(e.translate,0,n),t.scale=Fc(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function Zp(t,e,n,r){t.min=Fc(e.min,n.min,r),t.max=Fc(e.max,n.max,r)}function Jp(t){return t.animationValues&&void 0!==t.animationValues.opacityExit}const tf={duration:.45,ease:[.4,0,.1,1]},ef=t=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),nf=ef("applewebkit/")&&!ef("chrome/")?Math.round:xl;function rf(t){t.min=nf(t.min),t.max=nf(t.max)}function of(t,e,n){return"position"===t||"preserve-aspect"===t&&(r=Ep(e),i=Ep(n),o=.2,!(Math.abs(r-i)<=o));var r,i,o}function sf(t){var e;return t!==t.root&&(null===(e=t.scroll)||void 0===e?void 0:e.wasRoot)}const af=jp({attachResizeListener:(t,e)=>Wd(t,"resize",e),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),lf={current:void 0},uf=jp({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!lf.current){const t=new af({});t.mount(window),t.setOptions({layoutScroll:!0}),lf.current=t}return lf.current},resetTransform:(t,e)=>{t.style.transform=void 0!==e?e:"none"},checkIsScrollRoot:t=>Boolean("fixed"===window.getComputedStyle(t).position)}),cf={pan:{Feature:class extends jd{constructor(){super(...arguments),this.removePointerDownListener=xl}onPointerDown(t){this.session=new zd(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Bh(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:e,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:Wh(t),onStart:Wh(e),onMove:n,onEnd:(t,e)=>{delete this.session,r&&kl.postRender((()=>r(t,e)))}}}mount(){this.removePointerDownListener=Hd(this.node.current,"pointerdown",(t=>this.onPointerDown(t)))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends jd{constructor(t){super(t),this.removeGroupControls=xl,this.removeListeners=xl,this.controls=new Gh(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||xl}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:uf,MeasureLayout:ep}};function df(t,e){const n=e?"pointerenter":"pointerleave",r=e?"onHoverStart":"onHoverEnd";return Hd(t.current,n,((n,i)=>{if("touch"===n.pointerType||rh())return;const o=t.getProps();t.animationState&&o.whileHover&&t.animationState.setActive("whileHover",e);const s=o[r];s&&kl.postRender((()=>s(n,i)))}),{passive:!t.getProps()[r]})}const hf=(t,e)=>!!e&&(t===e||hf(t,e.parentElement));function pf(t,e){if(!e)return;const n=new PointerEvent("pointer"+t);e(n,Gd(n))}const ff=new WeakMap,mf=new WeakMap,vf=t=>{const e=ff.get(t.target);e&&e(t)},gf=t=>{t.forEach(vf)};function yf(t,e,n){const r=function({root:t,...e}){const n=t||document;mf.has(n)||mf.set(n,{});const r=mf.get(n),i=JSON.stringify(e);return r[i]||(r[i]=new IntersectionObserver(gf,{root:t,...e})),r[i]}(e);return ff.set(t,n),r.observe(t),()=>{ff.delete(t),r.unobserve(t)}}const _f={some:0,all:1};const bf={inView:{Feature:class extends jd{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:e,margin:n,amount:r="some",once:i}=t,o={root:e?e.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:_f[r]};return yf(this.node.current,o,(t=>{const{isIntersecting:e}=t;if(this.isInView===e)return;if(this.isInView=e,i&&!e&&this.hasEnteredView)return;e&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",e);const{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),o=e?n:r;o&&o(t)}))}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;const{props:t,prevProps:e}=this.node;["amount","margin","root"].some(function({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}(t,e))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends jd{constructor(){super(...arguments),this.removeStartListeners=xl,this.removeEndListeners=xl,this.removeAccessibleListeners=xl,this.startPointerPress=(t,e)=>{if(this.isPressing)return;this.removeEndListeners();const n=this.node.getProps(),r=Hd(window,"pointerup",((t,e)=>{if(!this.checkPressEnd())return;const{onTap:n,onTapCancel:r,globalTapTarget:i}=this.node.getProps(),o=i||hf(this.node.current,t.target)?n:r;o&&kl.update((()=>o(t,e)))}),{passive:!(n.onTap||n.onPointerUp)}),i=Hd(window,"pointercancel",((t,e)=>this.cancelPress(t,e)),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=Oc(r,i),this.startPress(t,e)},this.startAccessiblePress=()=>{const t=Wd(this.node.current,"keydown",(t=>{if("Enter"!==t.key||this.isPressing)return;this.removeEndListeners(),this.removeEndListeners=Wd(this.node.current,"keyup",(t=>{"Enter"===t.key&&this.checkPressEnd()&&pf("up",((t,e)=>{const{onTap:n}=this.node.getProps();n&&kl.postRender((()=>n(t,e)))}))})),pf("down",((t,e)=>{this.startPress(t,e)}))})),e=Wd(this.node.current,"blur",(()=>{this.isPressing&&pf("cancel",((t,e)=>this.cancelPress(t,e)))}));this.removeAccessibleListeners=Oc(t,e)}}startPress(t,e){this.isPressing=!0;const{onTapStart:n,whileTap:r}=this.node.getProps();r&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&kl.postRender((()=>n(t,e)))}checkPressEnd(){this.removeEndListeners(),this.isPressing=!1;return this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!rh()}cancelPress(t,e){if(!this.checkPressEnd())return;const{onTapCancel:n}=this.node.getProps();n&&kl.postRender((()=>n(t,e)))}mount(){const t=this.node.getProps(),e=Hd(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),n=Wd(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Oc(e,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}},focus:{Feature:class extends jd{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch(uy){t=!0}t&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Oc(Wd(this.node.current,"focus",(()=>this.onFocus())),Wd(this.node.current,"blur",(()=>this.onBlur())))}unmount(){}}},hover:{Feature:class extends jd{mount(){this.unmount=Oc(df(this.node,!0),df(this.node,!1))}unmount(){}}}},wf={layout:{ProjectionNode:uf,MeasureLayout:ep}},xf=oe({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),Sf=oe({}),Ef="undefined"!=typeof window,kf=Ef?Ln:Fn,Pf=oe({strict:!1});let Tf=!1;function Af(t,e,n,r,i){var o;const{visualElement:s}=Bn(Sf),a=Bn(Pf),l=Bn(Hh),u=Bn(xf).reducedMotion,c=Dn();r=r||a.renderer,!c.current&&r&&(c.current=r(t,{visualState:e,parent:s,props:n,presenceContext:l,blockInitialAnimation:!!l&&!1===l.initial,reducedMotionConfig:u}));const d=c.current,h=Bn(zh);!d||d.projection||!i||"html"!==d.type&&"svg"!==d.type||function(t,e,n,r){const{layoutId:i,layout:o,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:u}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:Rf(t.parent)),t.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:Boolean(s)||a&&ih(a),visualElement:t,animationType:"string"==typeof o?o:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:u})}(c.current,n,i,h),qr((()=>{d&&d.update(n,l)}));const p=n[wd],f=Dn(Boolean(p)&&!window.MotionHandoffIsComplete&&(null===(o=window.MotionHasOptimisedAnimation)||void 0===o?void 0:o.call(window,p)));return kf((()=>{d&&(d.updateFeatures(),Zh.render(d.render),f.current&&d.animationState&&d.animationState.animateChanges())})),Fn((()=>{d&&(!f.current&&d.animationState&&d.animationState.animateChanges(),f.current=!1,Tf||(Tf=!0,queueMicrotask(Cf)))})),d}function Cf(){window.MotionHandoffIsComplete=!0}function Rf(t){if(t)return!1!==t.options.allowProjection?t.projection:Rf(t.parent)}function Of(t,e,n){return In((r=>{r&&t.mount&&t.mount(r),e&&(r?e.mount(r):e.unmount()),n&&("function"==typeof n?n(r):ih(n)&&(n.current=r))}),[e])}function Mf(t){return el(t.animate)||ul.some((e=>il(t[e])))}function Ff(t){return Boolean(Mf(t)||t.variants)}function Lf(t){const{initial:e,animate:n}=function(t,e){if(Mf(t)){const{initial:e,animate:n}=t;return{initial:!1===e||il(e)?e:void 0,animate:il(n)?n:void 0}}return!1!==t.inherit?e:{}}(t,Bn(Sf));return jn((()=>({initial:e,animate:n})),[Df(e),Df(n)])}function Df(t){return Array.isArray(t)?t.join(" "):t}const Vf={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},jf={};for(const aS in Vf)jf[aS]={isEnabled:t=>Vf[aS].some((e=>!!t[e]))};const If=Symbol.for("motionComponentSymbol");function Bf({preloadedFeatures:t,createVisualElement:e,useRender:n,useVisualState:r,Component:i}){t&&function(t){for(const e in t)jf[e]={...jf[e],...t[e]}}(t);const o=er((function(t,o){let s;const a={...Bn(xf),...t,layoutId:Nf(t)},{isStatic:l}=a,u=Lf(t),c=r(t,l);if(!l&&Ef){Bn(Pf).strict;const t=function(t){const{drag:e,layout:n}=jf;if(!e&&!n)return{};const r={...e,...n};return{MeasureLayout:(null==e?void 0:e.isEnabled(t))||(null==n?void 0:n.isEnabled(t))?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(a);s=t.MeasureLayout,u.visualElement=Af(i,c,a,e,t.ProjectionNode)}return no(Sf.Provider,{value:u,children:[s&&u.visualElement?no(s,{visualElement:u.visualElement,...a}):null,n(i,t,Of(c,u.visualElement,o),c,l,u.visualElement)]})}));return o[If]=i,o}function Nf({layoutId:t}){const e=Bn($h).id;return e&&void 0!==t?e+"-"+t:t}const Gf=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Uf(t){return"string"==typeof t&&!t.includes("-")&&!!(Gf.indexOf(t)>-1||/[A-Z]/u.test(t))}function Wf(t,{style:e,vars:n},r,i){Object.assign(t.style,e,i&&i.getProjectionStyles(r));for(const o in n)t.style.setProperty(o,n[o])}const Hf=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function $f(t,e,n,r){Wf(t,e,void 0,r);for(const i in e.attrs)t.setAttribute(Hf.has(i)?i:bd(i),e.attrs[i])}function zf(t,{layout:e,layoutId:n}){return dl.has(t)||t.startsWith("origin")||(e||void 0!==n)&&(!!Xh[t]||"opacity"===t)}function qf(t,e,n){var r;const{style:i}=t,o={};for(const s in i)(kd(i[s])||e.style&&kd(e.style[s])||zf(s,t)||void 0!==(null===(r=null==n?void 0:n.getValue(s))||void 0===r?void 0:r.liveStyle))&&(o[s]=i[s]);return n&&i&&"string"==typeof i.willChange&&(n.applyWillChange=!1),o}function Kf(t,e,n){const r=qf(t,e,n);for(const i in t)if(kd(t[i])||kd(e[i])){r[-1!==cl.indexOf(i)?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i]=t[i]}return r}function Yf(t){const e=Dn(null);return null===e.current&&(e.current=t()),e.current}const Qf=t=>(e,n)=>{const r=Bn(Sf),i=Bn(Hh),o=()=>function({applyWillChange:t=!1,scrapeMotionValuesFromProps:e,createRenderState:n,onMount:r},i,o,s,a){const l={latestValues:Jf(i,o,s,!a&&t,e),renderState:n()};return r&&(l.mount=t=>r(i,t,l)),l}(t,e,r,i,n);return n?o():Yf(o)};function Xf(t,e){const n=Sd(e);n&&fd(t,n)}function Zf(t,e,n){const r=Array.isArray(e)?e:[e];for(let i=0;i<r.length;i++){const e=sl(t,r[i]);if(e){const{transitionEnd:t,transition:r,...i}=e;n(i,t)}}}function Jf(t,e,n,r,i){var o;const s={},a=[],l=r&&void 0===(null===(o=t.style)||void 0===o?void 0:o.willChange),u=i(t,{});for(const v in u)s[v]=Cp(u[v]);let{initial:c,animate:d}=t;const h=Mf(t),p=Ff(t);e&&p&&!h&&!1!==t.inherit&&(void 0===c&&(c=e.initial),void 0===d&&(d=e.animate));let f=!!n&&!1===n.initial;f=f||!1===c;const m=f?d:c;return m&&"boolean"!=typeof m&&!el(m)&&Zf(t,m,((t,e)=>{for(const n in t){let e=t[n];if(Array.isArray(e)){e=e[f?e.length-1:0]}null!==e&&(s[n]=e)}for(const n in e)s[n]=e[n]})),l&&(d&&!1!==c&&!el(d)&&Zf(t,d,(t=>{for(const e in t)Xf(a,e)})),a.length&&(s.willChange=a.join(","))),s}const tm=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),em=()=>({...tm(),attrs:{}}),nm=(t,e)=>e&&"number"==typeof t?e.transform(t):t,rm={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},im=cl.length;function om(t,e,n){const{style:r,vars:i,transformOrigin:o}=t;let s=!1,a=!1;for(const l in e){const t=e[l];if(dl.has(l))s=!0;else if(Fl(l))i[l]=t;else{const e=nm(t,Nu[l]);l.startsWith("origin")?(a=!0,o[l]=e):r[l]=e}}if(e.transform||(s||n?r.transform=function(t,e,n){let r="",i=!0;for(let o=0;o<im;o++){const s=cl[o],a=t[s];if(void 0===a)continue;let l=!0;if(l="number"==typeof a?a===(s.startsWith("scale")?1:0):0===parseFloat(a),!l||n){const t=nm(a,Nu[s]);l||(i=!1,r+=`${rm[s]||s}(${t}) `),n&&(e[s]=t)}}return r=r.trim(),n?r=n(e,i?"":r):i&&(r="none"),r}(e,t.transform,n):r.transform&&(r.transform="none")),a){const{originX:t="50%",originY:e="50%",originZ:n=0}=o;r.transformOrigin=`${t} ${e} ${n}`}}function sm(t,e,n){return"string"==typeof t?t:Xl.transform(e+n*t)}const am={offset:"stroke-dashoffset",array:"stroke-dasharray"},lm={offset:"strokeDashoffset",array:"strokeDasharray"};function um(t,{attrX:e,attrY:n,attrScale:r,originX:i,originY:o,pathLength:s,pathSpacing:a=1,pathOffset:l=0,...u},c,d){if(om(t,u,d),c)return void(t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox));t.attrs=t.style,t.style={};const{attrs:h,style:p,dimensions:f}=t;h.transform&&(f&&(p.transform=h.transform),delete h.transform),f&&(void 0!==i||void 0!==o||p.transform)&&(p.transformOrigin=function(t,e,n){return`${sm(e,t.x,t.width)} ${sm(n,t.y,t.height)}`}(f,void 0!==i?i:.5,void 0!==o?o:.5)),void 0!==e&&(h.x=e),void 0!==n&&(h.y=n),void 0!==r&&(h.scale=r),void 0!==s&&function(t,e,n=1,r=0,i=!0){t.pathLength=1;const o=i?am:lm;t[o.offset]=Xl.transform(-r);const s=Xl.transform(e),a=Xl.transform(n);t[o.array]=`${s} ${a}`}(h,s,a,l,!1)}const cm=t=>"string"==typeof t&&"svg"===t.toLowerCase(),dm={useVisualState:Qf({scrapeMotionValuesFromProps:Kf,createRenderState:em,onMount:(t,e,{renderState:n,latestValues:r})=>{kl.read((()=>{try{n.dimensions="function"==typeof e.getBBox?e.getBBox():e.getBoundingClientRect()}catch(uy){n.dimensions={x:0,y:0,width:0,height:0}}})),kl.render((()=>{um(n,r,cm(e.tagName),t.transformTemplate),$f(e,n)}))}})},hm={useVisualState:Qf({applyWillChange:!0,scrapeMotionValuesFromProps:qf,createRenderState:tm})};function pm(t,e,n){for(const r in e)kd(e[r])||zf(r,n)||(t[r]=e[r])}function fm(t,e){const n={};return pm(n,t.style||{},t),Object.assign(n,function({transformTemplate:t},e){return jn((()=>{const n=tm();return om(n,e,t),Object.assign({},n.vars,n.style)}),[e])}(t,e)),n}function mm(t,e){const n={},r=fm(t,e);return t.drag&&!1!==t.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===t.drag?"none":"pan-"+("x"===t.drag?"y":"x")),void 0===t.tabIndex&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=r,n}const vm=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function gm(t){return t.startsWith("while")||t.startsWith("drag")&&"draggable"!==t||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||vm.has(t)}let ym=t=>!gm(t);try{(_m=require("@emotion/is-prop-valid").default)&&(ym=t=>t.startsWith("on")?!gm(t):_m(t))}catch(sS){}var _m;function bm(t,e,n,r){const i=jn((()=>{const n=em();return um(n,e,cm(r),t.transformTemplate),{...n.attrs,style:{...n.style}}}),[e]);if(t.style){const e={};pm(e,t.style,t),i.style={...e,...i.style}}return i}function wm(t=!1){return(e,n,r,{latestValues:i},o)=>{const s=(Uf(e)?bm:mm)(n,i,o,e),a=function(t,e,n){const r={};for(const i in t)"values"===i&&"object"==typeof t.values||(ym(i)||!0===n&&gm(i)||!e&&!gm(i)||t.draggable&&i.startsWith("onDrag"))&&(r[i]=t[i]);return r}(n,"string"==typeof e,t),l=e!==It?{...a,...s,ref:r}:{},{children:u}=n;return Dt(e,{...l,children:jn((()=>kd(u)?u.get():u),[u])})}}function xm(t,e){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){return Bf({...Uf(n)?dm:hm,preloadedFeatures:t,useRender:wm(r),createVisualElement:e,Component:n})}}const Sm={current:null},Em={current:!1};const km=new WeakMap,Pm=[...uu,Su,Lu],Tm=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],Am=ul.length;class Cm{scrapeMotionValuesFromProps(t,e,n){return{}}constructor({parent:t,props:e,presenceContext:n,reducedMotionConfig:r,blockInitialAnimation:i,visualState:o},s={}){this.applyWillChange=!1,this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=vu,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.isRenderScheduled=!1,this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.isRenderScheduled=!1,this.scheduleRender=()=>{this.isRenderScheduled||(this.isRenderScheduled=!0,kl.render(this.render,!1,!0))};const{latestValues:a,renderState:l}=o;this.latestValues=a,this.baseTarget={...a},this.initialValues=e.initial?{...a}:{},this.renderState=l,this.parent=t,this.props=e,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.options=s,this.blockInitialAnimation=Boolean(i),this.isControllingVariants=Mf(e),this.isVariantNode=Ff(e),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(t&&t.current);const{willChange:u,...c}=this.scrapeMotionValuesFromProps(e,{},this);for(const d in c){const t=c[d];void 0!==a[d]&&kd(t)&&t.set(a[d],!1)}}mount(t){this.current=t,km.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach(((t,e)=>this.bindToMotionValue(e,t))),Em.current||function(){if(Em.current=!0,Ef)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),e=()=>Sm.current=t.matches;t.addListener(e),e()}else Sm.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||Sm.current),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){km.delete(this.current),this.projection&&this.projection.unmount(),Pl(this.notifyUpdate),Pl(this.render),this.valueSubscriptions.forEach((t=>t())),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const e=this.features[t];e&&(e.unmount(),e.isMounted=!1)}this.current=null}bindToMotionValue(t,e){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const n=dl.has(t),r=e.on("change",(e=>{this.latestValues[t]=e,this.props.onUpdate&&kl.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),i=e.on("renderRequest",this.scheduleRender);let o;window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,e)),this.valueSubscriptions.set(t,(()=>{r(),i(),o&&o(),e.owner&&e.stop()}))}sortNodePosition(t){return this.current&&this.sortInstanceNodePosition&&this.type===t.type?this.sortInstanceNodePosition(this.current,t.current):0}updateFeatures(){let t="animation";for(t in jf){const e=jf[t];if(!e)continue;const{isEnabled:n,Feature:r}=e;if(!this.features[t]&&r&&n(this.props)&&(this.features[t]=new r(this)),this.features[t]){const e=this.features[t];e.isMounted?e.update():(e.mount(),e.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):wh()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,e){this.latestValues[t]=e}update(t,e){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=e;for(let n=0;n<Tm.length;n++){const e=Tm[n];this.propEventSubscriptions[e]&&(this.propEventSubscriptions[e](),delete this.propEventSubscriptions[e]);const r=t["on"+e];r&&(this.propEventSubscriptions[e]=this.on(e,r))}this.prevMotionValues=function(t,e,n){for(const r in e){const i=e[r],o=n[r];if(kd(i))t.addValue(r,i);else if(kd(o))t.addValue(r,yd(i,{owner:t}));else if(o!==i)if(t.hasValue(r)){const e=t.getValue(r);!0===e.liveStyle?e.jump(i):e.hasAnimated||e.set(i)}else{const e=t.getStaticValue(r);t.addValue(r,yd(void 0!==e?e:i,{owner:t}))}}for(const r in n)void 0===e[r]&&t.removeValue(r);return e}(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}getVariantContext(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){const t=this.parent&&this.parent.getVariantContext()||{};return void 0!==this.props.initial&&(t.initial=this.props.initial),t}const e={};for(let n=0;n<Am;n++){const t=ul[n],r=this.props[t];(il(r)||!1===r)&&(e[t]=r)}return e}addVariantChild(t){const e=this.getClosestVariantNode();if(e)return e.variantChildren&&e.variantChildren.add(t),()=>e.variantChildren.delete(t)}addValue(t,e){const n=this.values.get(t);e!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,e),this.values.set(t,e),this.latestValues[t]=e.get())}removeValue(t){this.values.delete(t);const e=this.valueSubscriptions.get(t);e&&(e(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,e){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return void 0===n&&void 0!==e&&(n=yd(null===e?void 0:e,{owner:this}),this.addValue(t,n)),n}readValue(t,e){var n;let r=void 0===this.latestValues[t]&&this.current?null!==(n=this.getBaseTargetFromProps(this.props,t))&&void 0!==n?n:this.readValueFromInstance(this.current,t,this.options):this.latestValues[t];var i;return null!=r&&("string"==typeof r&&(Ol(r)||Cl(r))?r=parseFloat(r):(i=r,!Pm.find(lu(i))&&Lu.test(e)&&(r=Wu(t,e))),this.setBaseTarget(t,kd(r)?r.get():r)),kd(r)?r.get():r}setBaseTarget(t,e){this.baseTarget[t]=e}getBaseTarget(t){var e;const{initial:n}=this.props;let r;if("string"==typeof n||"object"==typeof n){const i=sl(this.props,n,null===(e=this.presenceContext)||void 0===e?void 0:e.custom);i&&(r=i[t])}if(n&&void 0!==r)return r;const i=this.getBaseTargetFromProps(this.props,t);return void 0===i||kd(i)?void 0!==this.initialValues[t]&&void 0===r?void 0:this.baseTarget[t]:i}on(t,e){return this.events[t]||(this.events[t]=new vd),this.events[t].add(e)}notify(t,...e){this.events[t]&&this.events[t].notify(...e)}}class Rm extends Cm{constructor(){super(...arguments),this.KeyframeResolver=$u}sortInstanceNodePosition(t,e){return 2&t.compareDocumentPosition(e)?1:-1}getBaseTargetFromProps(t,e){return t.style?t.style[e]:void 0}removeValueFromRenderState(t,{vars:e,style:n}){delete e[t],delete n[t]}}class Om extends Rm{constructor(){super(...arguments),this.type="html",this.applyWillChange=!0,this.renderInstance=Wf}readValueFromInstance(t,e){if(dl.has(e)){const t=Uu(e);return t&&t.default||0}{const r=(n=t,window.getComputedStyle(n)),i=(Fl(e)?r.getPropertyValue(e):r[e])||0;return"string"==typeof i?i.trim():i}var n}measureInstanceViewportBox(t,{transformPagePoint:e}){return Ih(t,e)}build(t,e,n){om(t,e,n.transformTemplate)}scrapeMotionValuesFromProps(t,e,n){return qf(t,e,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;kd(t)&&(this.childSubscription=t.on("change",(t=>{this.current&&(this.current.textContent=`${t}`)})))}}class Mm extends Rm{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=wh}getBaseTargetFromProps(t,e){return t[e]}readValueFromInstance(t,e){if(dl.has(e)){const t=Uu(e);return t&&t.default||0}return e=Hf.has(e)?e:bd(e),t.getAttribute(e)}scrapeMotionValuesFromProps(t,e,n){return Kf(t,e,n)}build(t,e,n){um(t,e,this.isSVGTag,n.transformTemplate)}renderInstance(t,e,n,r){$f(t,e,0,r)}mount(t){this.isSVGTag=cm(t.tagName),super.mount(t)}}const Fm=tl(xm({...Bd,...bf,...cf,...wf},((t,e)=>Uf(t)?new Mm(e):new Om(e,{allowProjection:t!==It}))));class Lm extends Bt{getSnapshotBeforeUpdate(t){const e=this.props.childRef.current;if(e&&t.isPresent&&!this.props.isPresent){const t=this.props.sizeRef.current;t.height=e.offsetHeight||0,t.width=e.offsetWidth||0,t.top=e.offsetTop,t.left=e.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}}function Dm({children:t,isPresent:e}){const n=Gn(),r=Dn(null),i=Dn({width:0,height:0,top:0,left:0}),{nonce:o}=Bn(xf);return qr((()=>{const{width:t,height:s,top:a,left:l}=i.current;if(e||!r.current||!t||!s)return;r.current.dataset.motionPopId=n;const u=document.createElement("style");return o&&(u.nonce=o),document.head.appendChild(u),u.sheet&&u.sheet.insertRule(`\n [data-motion-pop-id="${n}"] {\n position: absolute !important;\n width: ${t}px !important;\n height: ${s}px !important;\n top: ${a}px !important;\n left: ${l}px !important;\n }\n `),()=>{document.head.removeChild(u)}}),[e]),no(Lm,{isPresent:e,childRef:r,sizeRef:i,children:Ir(t,{ref:r})})}const Vm=({children:t,initial:e,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:o,mode:s})=>{const a=Yf(jm),l=Gn(),u=jn((()=>({id:l,initial:e,isPresent:n,custom:i,onExitComplete:t=>{a.set(t,!0);for(const e of a.values())if(!e)return;r&&r()},register:t=>(a.set(t,!1),()=>a.delete(t))})),o?[Math.random()]:[n]);return jn((()=>{a.forEach(((t,e)=>a.set(e,!1)))}),[n]),Fn((()=>{!n&&!a.size&&r&&r()}),[n]),"popLayout"===s&&(t=no(Dm,{isPresent:n,children:t})),no(Hh.Provider,{value:u,children:t})};function jm(){return new Map}const Im=t=>t.key||"";function Bm(t){const e=[];return rr.forEach(t,(t=>{Dr(t)&&e.push(t)})),e}const Nm=({children:t,exitBeforeEnter:e,custom:n,initial:r=!0,onExitComplete:i,presenceAffectsLayout:o=!0,mode:s="sync"})=>{const a=jn((()=>Bm(t)),[t]),l=a.map(Im),u=Dn(!0),c=Dn(a),d=Yf((()=>new Map)),[h,p]=On(a),[f,m]=On(a);kf((()=>{u.current=!1,c.current=a;for(let t=0;t<f.length;t++){const e=Im(f[t]);l.includes(e)?d.delete(e):!0!==d.get(e)&&d.set(e,!1)}}),[f,l.length,l.join("-")]);const v=[];if(a!==h){let t=[...a];for(let e=0;e<f.length;e++){const n=f[e],r=Im(n);l.includes(r)||(t.splice(e,0,n),v.push(n))}return"wait"===s&&v.length&&(t=v),m(Bm(t)),void p(a)}const{forceRender:g}=Bn($h);return no(It,{children:f.map((t=>{const e=Im(t),h=a===f||l.includes(e);return no(Vm,{isPresent:h,initial:!(u.current&&!r)&&void 0,custom:h?void 0:n,presenceAffectsLayout:o,mode:s,onExitComplete:h?void 0:()=>{if(!d.has(e))return;d.set(e,!0);let t=!0;d.forEach((e=>{e||(t=!1)})),t&&(null==g||g(),m(c.current),i&&i())},children:t},e)}))})},Gm=Os.input`
|
|
40
40
|
${()=>({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"}})}
|
|
41
41
|
|
|
42
42
|
${({prefix:t})=>t?{paddingLeft:"1.75rem"}:{paddingLeft:"0.75rem"}}
|
|
43
43
|
|
|
44
44
|
${({hasError:t})=>t?{"--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)"}}}
|
|
45
|
-
`,Xm=cr((({label:t,id:e,type:n,placeholder:r,setPlaceholderOnFocus:i,value:o,className:s,onChange:a,onBlur:l,error:u,helperText:c,disabled:d},h)=>mo("div",{className:s,children:[fo("label",{htmlFor:e,css:{display:"block",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:t}),fo("div",{css:{marginTop:"0.5rem"},children:fo(Qm,{type:n,value:o,name:e,id:e,placeholder:r,onChange:t=>{const e=t;e.target instanceof HTMLInputElement&&a(e.target.value.trim())},onBlur:t=>{const e=t;e.target instanceof HTMLInputElement&&l&&l(e.target.value.trim())},onFocus:()=>{r&&i&&!(null==o?void 0:o.trim())&&a(r)},hasError:!!u,ref:h,disabled:d})}),u&&fo("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:u}),c&&fo("span",{css:{fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:c})]})));var Zm=t=>"checkbox"===t.type,Jm=t=>t instanceof Date,tv=t=>null==t;const ev=t=>"object"==typeof t;var nv=t=>!tv(t)&&!Array.isArray(t)&&ev(t)&&!Jm(t),rv=t=>nv(t)&&t.target?Zm(t.target)?t.target.checked:t.target.value:t,iv=(t,e)=>t.has((t=>t.substring(0,t.search(/\.\d+(\.|$)/))||t)(e)),ov=t=>{const e=t.constructor&&t.constructor.prototype;return nv(e)&&e.hasOwnProperty("isPrototypeOf")},sv="undefined"!=typeof window&&void 0!==window.HTMLElement&&"undefined"!=typeof document;function av(t){let e;const n=Array.isArray(t);if(t instanceof Date)e=new Date(t);else if(t instanceof Set)e=new Set(t);else{if(sv&&(t instanceof Blob||t instanceof FileList)||!n&&!nv(t))return t;if(e=n?[]:{},n||ov(t))for(const n in t)t.hasOwnProperty(n)&&(e[n]=av(t[n]));else e=t}return e}var lv=t=>Array.isArray(t)?t.filter(Boolean):[],uv=t=>void 0===t,cv=(t,e,n)=>{if(!e||!nv(t))return n;const r=lv(e.split(/[,[\].]+?/)).reduce(((t,e)=>tv(t)?t:t[e]),t);return uv(r)||r===t?uv(t[e])?n:t[e]:r},dv=t=>"boolean"==typeof t,hv=t=>/^\w*$/.test(t),pv=t=>lv(t.replace(/["|']|\]/g,"").split(/\.|\[/)),fv=(t,e,n)=>{let r=-1;const i=hv(e)?[e]:pv(e),o=i.length,s=o-1;for(;++r<o;){const e=i[r];let o=n;if(r!==s){const n=t[e];o=nv(n)||Array.isArray(n)?n:isNaN(+i[r+1])?{}:[]}if("__proto__"===e)return;t[e]=o,t=t[e]}return t};const mv={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},vv={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},gv="max",yv="min",bv="maxLength",wv="minLength",xv="pattern",_v="required",Sv="validate",Ev=si.createContext(null),kv=()=>si.useContext(Ev);var Pv=(t,e,n,r=!0)=>{const i={defaultValues:e._defaultValues};for(const o in t)Object.defineProperty(i,o,{get:()=>{const i=o;return e._proxyFormState[i]!==vv.all&&(e._proxyFormState[i]=!r||vv.all),n&&(n[i]=!0),t[i]}});return i},Tv=t=>nv(t)&&!Object.keys(t).length,Cv=(t,e,n,r)=>{n(t);const{name:i,...o}=t;return Tv(o)||Object.keys(o).length>=Object.keys(e).length||Object.keys(o).find((t=>e[t]===(!r||vv.all)))},Av=t=>Array.isArray(t)?t:[t],Rv=(t,e,n)=>!t||!e||t===e||Av(t).some((t=>t&&(n?t===e:t.startsWith(e)||e.startsWith(t))));function Ov(t){const e=si.useRef(t);e.current=t,si.useEffect((()=>{const n=!t.disabled&&e.current.subject&&e.current.subject.subscribe({next:e.current.next});return()=>{n&&n.unsubscribe()}}),[t.disabled])}var Fv=t=>"string"==typeof t,Lv=(t,e,n,r,i)=>Fv(t)?(r&&e.watch.add(t),cv(n,t,i)):Array.isArray(t)?t.map((t=>(r&&e.watch.add(t),cv(n,t)))):(r&&(e.watchAll=!0),n);function Mv(t){const e=kv(),{name:n,disabled:r,control:i=e.control,shouldUnregister:o}=t,s=iv(i._names.array,n),a=function(t){const e=kv(),{control:n=e.control,name:r,defaultValue:i,disabled:o,exact:s}=t||{},a=si.useRef(r);a.current=r,Ov({disabled:o,subject:n._subjects.values,next:t=>{Rv(a.current,t.name,s)&&u(av(Lv(a.current,n._names,t.values||n._formValues,!1,i)))}});const[l,u]=si.useState(n._getWatch(r,i));return si.useEffect((()=>n._removeUnmounted())),l}({control:i,name:n,defaultValue:cv(i._formValues,n,cv(i._defaultValues,n,t.defaultValue)),exact:!0}),l=function(t){const e=kv(),{control:n=e.control,disabled:r,name:i,exact:o}=t||{},[s,a]=si.useState(n._formState),l=si.useRef(!0),u=si.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),c=si.useRef(i);return c.current=i,Ov({disabled:r,next:t=>l.current&&Rv(c.current,t.name,o)&&Cv(t,u.current,n._updateFormState)&&a({...n._formState,...t}),subject:n._subjects.state}),si.useEffect((()=>(l.current=!0,u.current.isValid&&n._updateValid(!0),()=>{l.current=!1})),[n]),Pv(s,n,u.current,!1)}({control:i,name:n,exact:!0}),u=si.useRef(i.register(n,{...t.rules,value:a,...dv(t.disabled)?{disabled:t.disabled}:{}}));return si.useEffect((()=>{const t=i._options.shouldUnregister||o,e=(t,e)=>{const n=cv(i._fields,t);n&&n._f&&(n._f.mount=e)};if(e(n,!0),t){const t=av(cv(i._options.defaultValues,n));fv(i._defaultValues,n,t),uv(cv(i._formValues,n))&&fv(i._formValues,n,t)}return()=>{(s?t&&!i._state.action:t)?i.unregister(n):e(n,!1)}}),[n,i,s,o]),si.useEffect((()=>{cv(i._fields,n)&&i._updateDisabledField({disabled:r,fields:i._fields,name:n,value:cv(i._fields,n)._f.value})}),[r,n,i]),{field:{name:n,value:a,...dv(r)||l.disabled?{disabled:l.disabled||r}:{},onChange:si.useCallback((t=>u.current.onChange({target:{value:rv(t),name:n},type:mv.CHANGE})),[n]),onBlur:si.useCallback((()=>u.current.onBlur({target:{value:cv(i._formValues,n),name:n},type:mv.BLUR})),[n,i]),ref:si.useCallback((t=>{const e=cv(i._fields,n);e&&t&&(e._f.ref={focus:()=>t.focus(),select:()=>t.select(),setCustomValidity:e=>t.setCustomValidity(e),reportValidity:()=>t.reportValidity()})}),[i._fields,n])},formState:l,fieldState:Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!cv(l.errors,n)},isDirty:{enumerable:!0,get:()=>!!cv(l.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!cv(l.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!cv(l.validatingFields,n)},error:{enumerable:!0,get:()=>cv(l.errors,n)}})}}const Dv=t=>t.render(Mv(t));var Vv=(t,e,n,r,i)=>e?{...n[t],types:{...n[t]&&n[t].types?n[t].types:{},[r]:i||!0}}:{},jv=t=>({isOnSubmit:!t||t===vv.onSubmit,isOnBlur:t===vv.onBlur,isOnChange:t===vv.onChange,isOnAll:t===vv.all,isOnTouch:t===vv.onTouched}),Iv=(t,e,n)=>!n&&(e.watchAll||e.watch.has(t)||[...e.watch].some((e=>t.startsWith(e)&&/^\.\w+/.test(t.slice(e.length)))));const Bv=(t,e,n,r)=>{for(const i of n||Object.keys(t)){const n=cv(t,i);if(n){const{_f:t,...o}=n;if(t){if(t.refs&&t.refs[0]&&e(t.refs[0],i)&&!r)return!0;if(t.ref&&e(t.ref,t.name)&&!r)return!0;if(Bv(o,e))break}else if(nv(o)&&Bv(o,e))break}}};var Nv=(t,e,n)=>{const r=Av(cv(t,n));return fv(r,"root",e[n]),fv(t,n,r),t},Uv=t=>"file"===t.type,Wv=t=>"function"==typeof t,Hv=t=>{if(!sv)return!1;const e=t?t.ownerDocument:0;return t instanceof(e&&e.defaultView?e.defaultView.HTMLElement:HTMLElement)},$v=t=>Fv(t),zv=t=>"radio"===t.type,qv=t=>t instanceof RegExp;const Kv={value:!1,isValid:!1},Gv={value:!0,isValid:!0};var Yv=t=>{if(Array.isArray(t)){if(t.length>1){const e=t.filter((t=>t&&t.checked&&!t.disabled)).map((t=>t.value));return{value:e,isValid:!!e.length}}return t[0].checked&&!t[0].disabled?t[0].attributes&&!uv(t[0].attributes.value)?uv(t[0].value)||""===t[0].value?Gv:{value:t[0].value,isValid:!0}:Gv:Kv}return Kv};const Qv={isValid:!1,value:null};var Xv=t=>Array.isArray(t)?t.reduce(((t,e)=>e&&e.checked&&!e.disabled?{isValid:!0,value:e.value}:t),Qv):Qv;function Zv(t,e,n="validate"){if($v(t)||Array.isArray(t)&&t.every($v)||dv(t)&&!t)return{type:n,message:$v(t)?t:"",ref:e}}var Jv=t=>nv(t)&&!qv(t)?t:{value:t,message:""},tg=async(t,e,n,r,i)=>{const{ref:o,refs:s,required:a,maxLength:l,minLength:u,min:c,max:d,pattern:h,validate:p,name:f,valueAsNumber:m,mount:v,disabled:g}=t._f,y=cv(e,f);if(!v||g)return{};const b=s?s[0]:o,w=t=>{r&&b.reportValidity&&(b.setCustomValidity(dv(t)?"":t||""),b.reportValidity())},x={},_=zv(o),S=Zm(o),E=_||S,k=(m||Uv(o))&&uv(o.value)&&uv(y)||Hv(o)&&""===o.value||""===y||Array.isArray(y)&&!y.length,P=Vv.bind(null,f,n,x),T=(t,e,n,r=bv,i=wv)=>{const s=t?e:n;x[f]={type:t?r:i,message:s,ref:o,...P(t?r:i,s)}};if(i?!Array.isArray(y)||!y.length:a&&(!E&&(k||tv(y))||dv(y)&&!y||S&&!Yv(s).isValid||_&&!Xv(s).isValid)){const{value:t,message:e}=$v(a)?{value:!!a,message:a}:Jv(a);if(t&&(x[f]={type:_v,message:e,ref:b,...P(_v,e)},!n))return w(e),x}if(!(k||tv(c)&&tv(d))){let t,e;const r=Jv(d),i=Jv(c);if(tv(y)||isNaN(y)){const n=o.valueAsDate||new Date(y),s=t=>new Date((new Date).toDateString()+" "+t),a="time"==o.type,l="week"==o.type;Fv(r.value)&&y&&(t=a?s(y)>s(r.value):l?y>r.value:n>new Date(r.value)),Fv(i.value)&&y&&(e=a?s(y)<s(i.value):l?y<i.value:n<new Date(i.value))}else{const n=o.valueAsNumber||(y?+y:y);tv(r.value)||(t=n>r.value),tv(i.value)||(e=n<i.value)}if((t||e)&&(T(!!t,r.message,i.message,gv,yv),!n))return w(x[f].message),x}if((l||u)&&!k&&(Fv(y)||i&&Array.isArray(y))){const t=Jv(l),e=Jv(u),r=!tv(t.value)&&y.length>+t.value,i=!tv(e.value)&&y.length<+e.value;if((r||i)&&(T(r,t.message,e.message),!n))return w(x[f].message),x}if(h&&!k&&Fv(y)){const{value:t,message:e}=Jv(h);if(qv(t)&&!y.match(t)&&(x[f]={type:xv,message:e,ref:o,...P(xv,e)},!n))return w(e),x}if(p)if(Wv(p)){const t=Zv(await p(y,e),b);if(t&&(x[f]={...t,...P(Sv,t.message)},!n))return w(t.message),x}else if(nv(p)){let t={};for(const r in p){if(!Tv(t)&&!n)break;const i=Zv(await p[r](y,e),b,r);i&&(t={...i,...P(r,i.message)},w(i.message),n&&(x[f]=t))}if(!Tv(t)&&(x[f]={ref:b,...t},!n))return x}return w(!0),x};function eg(t,e){const n=Array.isArray(e)?e:hv(e)?[e]:pv(e),r=1===n.length?t:function(t,e){const n=e.slice(0,-1).length;let r=0;for(;r<n;)t=uv(t)?r++:t[e[r++]];return t}(t,n),i=n.length-1,o=n[i];return r&&delete r[o],0!==i&&(nv(r)&&Tv(r)||Array.isArray(r)&&function(t){for(const e in t)if(t.hasOwnProperty(e)&&!uv(t[e]))return!1;return!0}(r))&&eg(t,n.slice(0,-1)),t}var ng=()=>{let t=[];return{get observers(){return t},next:e=>{for(const n of t)n.next&&n.next(e)},subscribe:e=>(t.push(e),{unsubscribe:()=>{t=t.filter((t=>t!==e))}}),unsubscribe:()=>{t=[]}}},rg=t=>tv(t)||!ev(t);function ig(t,e){if(rg(t)||rg(e))return t===e;if(Jm(t)&&Jm(e))return t.getTime()===e.getTime();const n=Object.keys(t),r=Object.keys(e);if(n.length!==r.length)return!1;for(const i of n){const n=t[i];if(!r.includes(i))return!1;if("ref"!==i){const t=e[i];if(Jm(n)&&Jm(t)||nv(n)&&nv(t)||Array.isArray(n)&&Array.isArray(t)?!ig(n,t):n!==t)return!1}}return!0}var og=t=>"select-multiple"===t.type,sg=t=>zv(t)||Zm(t),ag=t=>Hv(t)&&t.isConnected,lg=t=>{for(const e in t)if(Wv(t[e]))return!0;return!1};function ug(t,e={}){const n=Array.isArray(t);if(nv(t)||n)for(const r in t)Array.isArray(t[r])||nv(t[r])&&!lg(t[r])?(e[r]=Array.isArray(t[r])?[]:{},ug(t[r],e[r])):tv(t[r])||(e[r]=!0);return e}function cg(t,e,n){const r=Array.isArray(t);if(nv(t)||r)for(const i in t)Array.isArray(t[i])||nv(t[i])&&!lg(t[i])?uv(e)||rg(n[i])?n[i]=Array.isArray(t[i])?ug(t[i],[]):{...ug(t[i])}:cg(t[i],tv(e)?{}:e[i],n[i]):n[i]=!ig(t[i],e[i]);return n}var dg=(t,e)=>cg(t,e,ug(e)),hg=(t,{valueAsNumber:e,valueAsDate:n,setValueAs:r})=>uv(t)?t:e?""===t?NaN:t?+t:t:n&&Fv(t)?new Date(t):r?r(t):t;function pg(t){const e=t.ref;if(!(t.refs?t.refs.every((t=>t.disabled)):e.disabled))return Uv(e)?e.files:zv(e)?Xv(t.refs).value:og(e)?[...e.selectedOptions].map((({value:t})=>t)):Zm(e)?Yv(t.refs).value:hg(uv(e.value)?t.ref.value:e.value,t)}var fg=(t,e,n,r)=>{const i={};for(const o of t){const t=cv(e,o);t&&fv(i,o,t._f)}return{criteriaMode:n,names:[...t],fields:i,shouldUseNativeValidation:r}},mg=t=>uv(t)?t:qv(t)?t.source:nv(t)?qv(t.value)?t.value.source:t.value:t;const vg="AsyncFunction";var gg=t=>!(t&&t.validate||!(Wv(t.validate)&&t.validate.constructor.name===vg||nv(t.validate)&&Object.values(t.validate).find((t=>t.constructor.name===vg)))),yg=t=>t.mount&&(t.required||t.min||t.max||t.maxLength||t.minLength||t.pattern||t.validate);function bg(t,e,n){const r=cv(t,n);if(r||hv(n))return{error:r,name:n};const i=n.split(".");for(;i.length;){const r=i.join("."),o=cv(e,r),s=cv(t,r);if(o&&!Array.isArray(o)&&n!==r)return{name:n};if(s&&s.type)return{name:r,error:s};i.pop()}return{name:n}}var wg=(t,e,n,r,i)=>!i.isOnAll&&(!n&&i.isOnTouch?!(e||t):(n?r.isOnBlur:i.isOnBlur)?!t:!(n?r.isOnChange:i.isOnChange)||t),xg=(t,e)=>!lv(cv(t,e)).length&&eg(t,e);const _g={mode:vv.onSubmit,reValidateMode:vv.onChange,shouldFocusError:!0};function Sg(t={}){let e,n={..._g,...t},r={submitCount:0,isDirty:!1,isLoading:Wv(n.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:n.errors||{},disabled:n.disabled||!1},i={},o=(nv(n.defaultValues)||nv(n.values))&&av(n.defaultValues||n.values)||{},s=n.shouldUnregister?{}:av(o),a={action:!1,mount:!1,watch:!1},l={mount:new Set,unMount:new Set,array:new Set,watch:new Set},u=0;const c={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},d={values:ng(),array:ng(),state:ng()},h=jv(n.mode),p=jv(n.reValidateMode),f=n.criteriaMode===vv.all,m=async t=>{if(c.isValid||t){const t=n.resolver?Tv((await w()).errors):await x(i,!0);t!==r.isValid&&d.state.next({isValid:t})}},v=(t,e)=>{(c.isValidating||c.validatingFields)&&((t||Array.from(l.mount)).forEach((t=>{t&&(e?fv(r.validatingFields,t,e):eg(r.validatingFields,t))})),d.state.next({validatingFields:r.validatingFields,isValidating:!Tv(r.validatingFields)}))},g=(t,e,n,r)=>{const l=cv(i,t);if(l){const i=cv(s,t,uv(n)?cv(o,t):n);uv(i)||r&&r.defaultChecked||e?fv(s,t,e?i:pg(l._f)):E(t,i),a.mount&&m()}},y=(t,e,n,s,a)=>{let l=!1,u=!1;const h={name:t},p=!!(cv(i,t)&&cv(i,t)._f&&cv(i,t)._f.disabled);if(!n||s){c.isDirty&&(u=r.isDirty,r.isDirty=h.isDirty=_(),l=u!==h.isDirty);const n=p||ig(cv(o,t),e);u=!(p||!cv(r.dirtyFields,t)),n||p?eg(r.dirtyFields,t):fv(r.dirtyFields,t,!0),h.dirtyFields=r.dirtyFields,l=l||c.dirtyFields&&u!==!n}if(n){const e=cv(r.touchedFields,t);e||(fv(r.touchedFields,t,n),h.touchedFields=r.touchedFields,l=l||c.touchedFields&&e!==n)}return l&&a&&d.state.next(h),l?h:{}},b=(n,i,o,s)=>{const a=cv(r.errors,n),l=c.isValid&&dv(i)&&r.isValid!==i;var h;if(t.delayError&&o?(h=()=>((t,e)=>{fv(r.errors,t,e),d.state.next({errors:r.errors})})(n,o),e=t=>{clearTimeout(u),u=setTimeout(h,t)},e(t.delayError)):(clearTimeout(u),e=null,o?fv(r.errors,n,o):eg(r.errors,n)),(o?!ig(a,o):a)||!Tv(s)||l){const t={...s,...l&&dv(i)?{isValid:i}:{},errors:r.errors,name:n};r={...r,...t},d.state.next(t)}},w=async t=>{v(t,!0);const e=await n.resolver(s,n.context,fg(t||l.mount,i,n.criteriaMode,n.shouldUseNativeValidation));return v(t),e},x=async(t,e,i={valid:!0})=>{for(const o in t){const a=t[o];if(a){const{_f:t,...u}=a;if(t){const u=l.array.has(t.name),d=a._f&&gg(a._f);d&&c.validatingFields&&v([o],!0);const h=await tg(a,s,f,n.shouldUseNativeValidation&&!e,u);if(d&&c.validatingFields&&v([o]),h[t.name]&&(i.valid=!1,e))break;!e&&(cv(h,t.name)?u?Nv(r.errors,h,t.name):fv(r.errors,t.name,h[t.name]):eg(r.errors,t.name))}!Tv(u)&&await x(u,e,i)}}return i.valid},_=(t,e)=>(t&&e&&fv(s,t,e),!ig(R(),o)),S=(t,e,n)=>Lv(t,l,{...a.mount?s:uv(e)?o:Fv(t)?{[t]:e}:e},n,e),E=(t,e,n={})=>{const r=cv(i,t);let o=e;if(r){const n=r._f;n&&(!n.disabled&&fv(s,t,hg(e,n)),o=Hv(n.ref)&&tv(e)?"":e,og(n.ref)?[...n.ref.options].forEach((t=>t.selected=o.includes(t.value))):n.refs?Zm(n.ref)?n.refs.length>1?n.refs.forEach((t=>(!t.defaultChecked||!t.disabled)&&(t.checked=Array.isArray(o)?!!o.find((e=>e===t.value)):o===t.value))):n.refs[0]&&(n.refs[0].checked=!!o):n.refs.forEach((t=>t.checked=t.value===o)):Uv(n.ref)?n.ref.value="":(n.ref.value=o,n.ref.type||d.values.next({name:t,values:{...s}})))}(n.shouldDirty||n.shouldTouch)&&y(t,o,n.shouldTouch,n.shouldDirty,!0),n.shouldValidate&&A(t)},k=(t,e,n)=>{for(const r in e){const o=e[r],s=`${t}.${r}`,a=cv(i,s);!l.array.has(t)&&rg(o)&&(!a||a._f)||Jm(o)?E(s,o,n):k(s,o,n)}},P=(t,e,n={})=>{const u=cv(i,t),h=l.array.has(t),p=av(e);fv(s,t,p),h?(d.array.next({name:t,values:{...s}}),(c.isDirty||c.dirtyFields)&&n.shouldDirty&&d.state.next({name:t,dirtyFields:dg(o,s),isDirty:_(t,p)})):!u||u._f||tv(p)?E(t,p,n):k(t,p,n),Iv(t,l)&&d.state.next({...r}),d.values.next({name:a.mount?t:void 0,values:{...s}})},T=async o=>{a.mount=!0;const u=o.target;let g=u.name,_=!0;const S=cv(i,g),E=t=>{_=Number.isNaN(t)||ig(t,cv(s,g,t))};if(S){let a,k;const P=u.type?pg(S._f):rv(o),T=o.type===mv.BLUR||o.type===mv.FOCUS_OUT,C=!yg(S._f)&&!n.resolver&&!cv(r.errors,g)&&!S._f.deps||wg(T,cv(r.touchedFields,g),r.isSubmitted,p,h),R=Iv(g,l,T);fv(s,g,P),T?(S._f.onBlur&&S._f.onBlur(o),e&&e(0)):S._f.onChange&&S._f.onChange(o);const O=y(g,P,T,!1),F=!Tv(O)||R;if(!T&&d.values.next({name:g,type:o.type,values:{...s}}),C)return c.isValid&&("onBlur"===t.mode?T&&m():m()),F&&d.state.next({name:g,...R?{}:O});if(!T&&R&&d.state.next({...r}),n.resolver){const{errors:t}=await w([g]);if(E(P),_){const e=bg(r.errors,i,g),n=bg(t,i,e.name||g);a=n.error,g=n.name,k=Tv(t)}}else v([g],!0),a=(await tg(S,s,f,n.shouldUseNativeValidation))[g],v([g]),E(P),_&&(a?k=!1:c.isValid&&(k=await x(i,!0)));_&&(S._f.deps&&A(S._f.deps),b(g,k,a,O))}},C=(t,e)=>{if(cv(r.errors,e)&&t.focus)return t.focus(),1},A=async(t,e={})=>{let o,s;const a=Av(t);if(n.resolver){const e=await(async t=>{const{errors:e}=await w(t);if(t)for(const n of t){const t=cv(e,n);t?fv(r.errors,n,t):eg(r.errors,n)}else r.errors=e;return e})(uv(t)?t:a);o=Tv(e),s=t?!a.some((t=>cv(e,t))):o}else t?(s=(await Promise.all(a.map((async t=>{const e=cv(i,t);return await x(e&&e._f?{[t]:e}:e)})))).every(Boolean),(s||r.isValid)&&m()):s=o=await x(i);return d.state.next({...!Fv(t)||c.isValid&&o!==r.isValid?{}:{name:t},...n.resolver||!t?{isValid:o}:{},errors:r.errors}),e.shouldFocus&&!s&&Bv(i,C,t?a:l.mount),s},R=t=>{const e={...a.mount?s:o};return uv(t)?e:Fv(t)?cv(e,t):t.map((t=>cv(e,t)))},O=(t,e)=>({invalid:!!cv((e||r).errors,t),isDirty:!!cv((e||r).dirtyFields,t),error:cv((e||r).errors,t),isValidating:!!cv(r.validatingFields,t),isTouched:!!cv((e||r).touchedFields,t)}),F=(t,e,n)=>{const o=(cv(i,t,{_f:{}})._f||{}).ref,s=cv(r.errors,t)||{},{ref:a,message:l,type:u,...c}=s;fv(r.errors,t,{...c,...e,ref:o}),d.state.next({name:t,errors:r.errors,isValid:!1}),n&&n.shouldFocus&&o&&o.focus&&o.focus()},L=(t,e={})=>{for(const a of t?Av(t):l.mount)l.mount.delete(a),l.array.delete(a),e.keepValue||(eg(i,a),eg(s,a)),!e.keepError&&eg(r.errors,a),!e.keepDirty&&eg(r.dirtyFields,a),!e.keepTouched&&eg(r.touchedFields,a),!e.keepIsValidating&&eg(r.validatingFields,a),!n.shouldUnregister&&!e.keepDefaultValue&&eg(o,a);d.values.next({values:{...s}}),d.state.next({...r,...e.keepDirty?{isDirty:_()}:{}}),!e.keepIsValid&&m()},M=({disabled:t,name:e,field:n,fields:r,value:i})=>{if(dv(t)&&a.mount||t){const o=t?void 0:uv(i)?pg(n?n._f:cv(r,e)._f):i;fv(s,e,o),y(e,o,!1,!1,!0)}},D=(e,r={})=>{let s=cv(i,e);const u=dv(r.disabled)||dv(t.disabled);return fv(i,e,{...s||{},_f:{...s&&s._f?s._f:{ref:{name:e}},name:e,mount:!0,...r}}),l.mount.add(e),s?M({field:s,disabled:dv(r.disabled)?r.disabled:t.disabled,name:e,value:r.value}):g(e,!0,r.value),{...u?{disabled:r.disabled||t.disabled}:{},...n.progressive?{required:!!r.required,min:mg(r.min),max:mg(r.max),minLength:mg(r.minLength),maxLength:mg(r.maxLength),pattern:mg(r.pattern)}:{},name:e,onChange:T,onBlur:T,ref:t=>{if(t){D(e,r),s=cv(i,e);const n=uv(t.value)&&t.querySelectorAll&&t.querySelectorAll("input,select,textarea")[0]||t,a=sg(n),l=s._f.refs||[];if(a?l.find((t=>t===n)):n===s._f.ref)return;fv(i,e,{_f:{...s._f,...a?{refs:[...l.filter(ag),n,...Array.isArray(cv(o,e))?[{}]:[]],ref:{type:n.type,name:e}}:{ref:n}}}),g(e,!1,void 0,n)}else s=cv(i,e,{}),s._f&&(s._f.mount=!1),(n.shouldUnregister||r.shouldUnregister)&&(!iv(l.array,e)||!a.action)&&l.unMount.add(e)}}},V=()=>n.shouldFocusError&&Bv(i,C,l.mount),j=(t,e)=>async o=>{let a;o&&(o.preventDefault&&o.preventDefault(),o.persist&&o.persist());let l=av(s);if(d.state.next({isSubmitting:!0}),n.resolver){const{errors:t,values:e}=await w();r.errors=t,l=e}else await x(i);if(eg(r.errors,"root"),Tv(r.errors)){d.state.next({errors:{}});try{await t(l,o)}catch(u){a=u}}else e&&await e({...r.errors},o),V(),setTimeout(V);if(d.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Tv(r.errors)&&!a,submitCount:r.submitCount+1,errors:r.errors}),a)throw a},I=(e,n={})=>{const u=e?av(e):o,h=av(u),p=Tv(e),f=p?o:h;if(n.keepDefaultValues||(o=u),!n.keepValues){if(n.keepDirtyValues)for(const t of l.mount)cv(r.dirtyFields,t)?fv(f,t,cv(s,t)):P(t,cv(f,t));else{if(sv&&uv(e))for(const t of l.mount){const e=cv(i,t);if(e&&e._f){const t=Array.isArray(e._f.refs)?e._f.refs[0]:e._f.ref;if(Hv(t)){const e=t.closest("form");if(e){e.reset();break}}}}i={}}s=t.shouldUnregister?n.keepDefaultValues?av(o):{}:av(f),d.array.next({values:{...f}}),d.values.next({values:{...f}})}l={mount:n.keepDirtyValues?l.mount:new Set,unMount:new Set,array:new Set,watch:new Set,watchAll:!1,focus:""},a.mount=!c.isValid||!!n.keepIsValid||!!n.keepDirtyValues,a.watch=!!t.shouldUnregister,d.state.next({submitCount:n.keepSubmitCount?r.submitCount:0,isDirty:!p&&(n.keepDirty?r.isDirty:!(!n.keepDefaultValues||ig(e,o))),isSubmitted:!!n.keepIsSubmitted&&r.isSubmitted,dirtyFields:p?{}:n.keepDirtyValues?n.keepDefaultValues&&s?dg(o,s):r.dirtyFields:n.keepDefaultValues&&e?dg(o,e):n.keepDirty?r.dirtyFields:{},touchedFields:n.keepTouched?r.touchedFields:{},errors:n.keepErrors?r.errors:{},isSubmitSuccessful:!!n.keepIsSubmitSuccessful&&r.isSubmitSuccessful,isSubmitting:!1})},B=(t,e)=>I(Wv(t)?t(s):t,e);return{control:{register:D,unregister:L,getFieldState:O,handleSubmit:j,setError:F,_executeSchema:w,_getWatch:S,_getDirty:_,_updateValid:m,_removeUnmounted:()=>{for(const t of l.unMount){const e=cv(i,t);e&&(e._f.refs?e._f.refs.every((t=>!ag(t))):!ag(e._f.ref))&&L(t)}l.unMount=new Set},_updateFieldArray:(t,e=[],n,l,u=!0,h=!0)=>{if(l&&n){if(a.action=!0,h&&Array.isArray(cv(i,t))){const e=n(cv(i,t),l.argA,l.argB);u&&fv(i,t,e)}if(h&&Array.isArray(cv(r.errors,t))){const e=n(cv(r.errors,t),l.argA,l.argB);u&&fv(r.errors,t,e),xg(r.errors,t)}if(c.touchedFields&&h&&Array.isArray(cv(r.touchedFields,t))){const e=n(cv(r.touchedFields,t),l.argA,l.argB);u&&fv(r.touchedFields,t,e)}c.dirtyFields&&(r.dirtyFields=dg(o,s)),d.state.next({name:t,isDirty:_(t,e),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else fv(s,t,e)},_updateDisabledField:M,_getFieldArray:e=>lv(cv(a.mount?s:o,e,t.shouldUnregister?cv(o,e,[]):[])),_reset:I,_resetDefaultValues:()=>Wv(n.defaultValues)&&n.defaultValues().then((t=>{B(t,n.resetOptions),d.state.next({isLoading:!1})})),_updateFormState:t=>{r={...r,...t}},_disableForm:t=>{dv(t)&&(d.state.next({disabled:t}),Bv(i,((e,n)=>{const r=cv(i,n);r&&(e.disabled=r._f.disabled||t,Array.isArray(r._f.refs)&&r._f.refs.forEach((e=>{e.disabled=r._f.disabled||t})))}),0,!1))},_subjects:d,_proxyFormState:c,_setErrors:t=>{r.errors=t,d.state.next({errors:r.errors,isValid:!1})},get _fields(){return i},get _formValues(){return s},get _state(){return a},set _state(t){a=t},get _defaultValues(){return o},get _names(){return l},set _names(t){l=t},get _formState(){return r},set _formState(t){r=t},get _options(){return n},set _options(t){n={...n,...t}}},trigger:A,register:D,handleSubmit:j,watch:(t,e)=>Wv(t)?d.values.subscribe({next:n=>t(S(void 0,e),n)}):S(t,e,!0),setValue:P,getValues:R,reset:B,resetField:(t,e={})=>{cv(i,t)&&(uv(e.defaultValue)?P(t,av(cv(o,t))):(P(t,e.defaultValue),fv(o,t,av(e.defaultValue))),e.keepTouched||eg(r.touchedFields,t),e.keepDirty||(eg(r.dirtyFields,t),r.isDirty=e.defaultValue?_(t,av(cv(o,t))):_()),e.keepError||(eg(r.errors,t),c.isValid&&m()),d.state.next({...r}))},clearErrors:t=>{t&&Av(t).forEach((t=>eg(r.errors,t))),d.state.next({errors:t?r.errors:{}})},unregister:L,setError:F,setFocus:(t,e={})=>{const n=cv(i,t),r=n&&n._f;if(r){const t=r.refs?r.refs[0]:r.ref;t.focus&&(t.focus(),e.shouldSelect&&t.select())}},getFieldState:O}}const Eg="undefined"!=typeof document?si.useLayoutEffect:()=>{};const kg=t=>{var e;return null!==(e=null==t?void 0:t.ownerDocument)&&void 0!==e?e:document},Pg=t=>{if(t&&"window"in t&&t.window===t)return t;return kg(t).defaultView||window};function Tg(t){let e=null;return()=>(null==e&&(e=t()),e)}const Cg=Tg((function(){return t=/^Mac/i,"undefined"!=typeof window&&null!=window.navigator&&t.test((null===(e=window.navigator.userAgentData)||void 0===e?void 0:e.platform)||window.navigator.platform);var t,e})),Ag=Tg((function(){return t=/Android/i,"undefined"!=typeof window&&null!=window.navigator&&((null===(e=window.navigator.userAgentData)||void 0===e?void 0:e.brands.some((e=>t.test(e.brand))))||t.test(window.navigator.userAgent));var t,e}));class Rg{isDefaultPrevented(){return this.nativeEvent.defaultPrevented}preventDefault(){this.defaultPrevented=!0,this.nativeEvent.preventDefault()}stopPropagation(){this.nativeEvent.stopPropagation(),this.isPropagationStopped=()=>!0}isPropagationStopped(){return!1}persist(){}constructor(t,e){this.nativeEvent=e,this.target=e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget,this.bubbles=e.bubbles,this.cancelable=e.cancelable,this.defaultPrevented=e.defaultPrevented,this.eventPhase=e.eventPhase,this.isTrusted=e.isTrusted,this.timeStamp=e.timeStamp,this.type=t}}function Og(t){let e=$n({isFocused:!1,observer:null});Eg((()=>{const t=e.current;return()=>{t.observer&&(t.observer.disconnect(),t.observer=null)}}),[]);let n=function(t){const e=$n(null);return Eg((()=>{e.current=t}),[t]),Kn(((...t)=>{const n=e.current;return null==n?void 0:n(...t)}),[])}((e=>{null==t||t(e)}));return Kn((t=>{if(t.target instanceof HTMLButtonElement||t.target instanceof HTMLInputElement||t.target instanceof HTMLTextAreaElement||t.target instanceof HTMLSelectElement){e.current.isFocused=!0;let r=t.target,i=t=>{e.current.isFocused=!1,r.disabled&&n(new Rg("blur",t)),e.current.observer&&(e.current.observer.disconnect(),e.current.observer=null)};r.addEventListener("focusout",i,{once:!0}),e.current.observer=new MutationObserver((()=>{if(e.current.isFocused&&r.disabled){var t;null===(t=e.current.observer)||void 0===t||t.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}))}})),e.current.observer.observe(r,{attributes:!0,attributeFilter:["disabled"]})}}),[n])}let Fg=null,Lg=new Set,Mg=new Map,Dg=!1,Vg=!1;const jg={Tab:!0,Escape:!0};function Ig(t,e){for(let n of Lg)n(t,e)}function Bg(t){Dg=!0,function(t){return!(t.metaKey||!Cg()&&t.altKey||t.ctrlKey||"Control"===t.key||"Shift"===t.key||"Meta"===t.key)}(t)&&(Fg="keyboard",Ig("keyboard",t))}function Ng(t){Fg="pointer","mousedown"!==t.type&&"pointerdown"!==t.type||(Dg=!0,Ig("pointer",t))}function Ug(t){var e;(0===(e=t).mozInputSource&&e.isTrusted||(Ag()&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType))&&(Dg=!0,Fg="virtual")}function Wg(t){t.target!==window&&t.target!==document&&(Dg||Vg||(Fg="virtual",Ig("virtual",t)),Dg=!1,Vg=!1)}function Hg(){Dg=!1,Vg=!0}function $g(t){if("undefined"==typeof window||Mg.get(Pg(t)))return;const e=Pg(t),n=kg(t);let r=e.HTMLElement.prototype.focus;e.HTMLElement.prototype.focus=function(){Dg=!0,r.apply(this,arguments)},n.addEventListener("keydown",Bg,!0),n.addEventListener("keyup",Bg,!0),n.addEventListener("click",Ug,!0),e.addEventListener("focus",Wg,!0),e.addEventListener("blur",Hg,!1),"undefined"!=typeof PointerEvent?(n.addEventListener("pointerdown",Ng,!0),n.addEventListener("pointermove",Ng,!0),n.addEventListener("pointerup",Ng,!0)):(n.addEventListener("mousedown",Ng,!0),n.addEventListener("mousemove",Ng,!0),n.addEventListener("mouseup",Ng,!0)),e.addEventListener("beforeunload",(()=>{zg(t)}),{once:!0}),Mg.set(e,{focus:r})}const zg=(t,e)=>{const n=Pg(t),r=kg(t);e&&r.removeEventListener("DOMContentLoaded",e),Mg.has(n)&&(n.HTMLElement.prototype.focus=Mg.get(n).focus,r.removeEventListener("keydown",Bg,!0),r.removeEventListener("keyup",Bg,!0),r.removeEventListener("click",Ug,!0),n.removeEventListener("focus",Wg,!0),n.removeEventListener("blur",Hg,!1),"undefined"!=typeof PointerEvent?(r.removeEventListener("pointerdown",Ng,!0),r.removeEventListener("pointermove",Ng,!0),r.removeEventListener("pointerup",Ng,!0)):(r.removeEventListener("mousedown",Ng,!0),r.removeEventListener("mousemove",Ng,!0),r.removeEventListener("mouseup",Ng,!0)),Mg.delete(n))};function qg(){return"pointer"!==Fg}"undefined"!=typeof document&&function(t){const e=kg(t);let n;"loading"!==e.readyState?$g(t):(n=()=>{$g(t)},e.addEventListener("DOMContentLoaded",n))}();const Kg=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function Gg(t,e,n){$g(),Wn((()=>{let e=(e,r)=>{(function(t,e,n){var r;const i="undefined"!=typeof window?Pg(null==n?void 0:n.target).HTMLInputElement:HTMLInputElement,o="undefined"!=typeof window?Pg(null==n?void 0:n.target).HTMLTextAreaElement:HTMLTextAreaElement,s="undefined"!=typeof window?Pg(null==n?void 0:n.target).HTMLElement:HTMLElement,a="undefined"!=typeof window?Pg(null==n?void 0:n.target).KeyboardEvent:KeyboardEvent;return!((t=t||(null==n?void 0:n.target)instanceof i&&!Kg.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 s&&(null==n?void 0:n.target.isContentEditable))&&"keyboard"===e&&n instanceof a&&!jg[n.key])})(!!(null==n?void 0:n.isTextInput),e,r)&&t(qg())};return Lg.add(e),()=>{Lg.delete(e)}}),e)}let Yg=!1,Qg=0;function Xg(){Yg=!0,setTimeout((()=>{Yg=!1}),50)}function Zg(t){"touch"===t.pointerType&&Xg()}function Jg(){if("undefined"!=typeof document)return"undefined"!=typeof PointerEvent?document.addEventListener("pointerup",Zg):document.addEventListener("touchend",Xg),Qg++,()=>{Qg--,Qg>0||("undefined"!=typeof PointerEvent?document.removeEventListener("pointerup",Zg):document.removeEventListener("touchend",Xg))}}function ty(t){let{onHoverStart:e,onHoverChange:n,onHoverEnd:r,isDisabled:i}=t,[o,s]=Nn(!1),a=$n({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;Wn(Jg,[]);let{hoverProps:l,triggerHoverEnd:u}=qn((()=>{let t=(t,r)=>{if(a.pointerType=r,i||"touch"===r||a.isHovered||!t.currentTarget.contains(t.target))return;a.isHovered=!0;let o=t.currentTarget;a.target=o,e&&e({type:"hoverstart",target:o,pointerType:r}),n&&n(!0),s(!0)},o=(t,e)=>{if(a.pointerType="",a.target=null,"touch"===e||!a.isHovered)return;a.isHovered=!1;let i=t.currentTarget;r&&r({type:"hoverend",target:i,pointerType:e}),n&&n(!1),s(!1)},l={};return"undefined"!=typeof PointerEvent?(l.onPointerEnter=e=>{Yg&&"mouse"===e.pointerType||t(e,e.pointerType)},l.onPointerLeave=t=>{!i&&t.currentTarget.contains(t.target)&&o(t,t.pointerType)}):(l.onTouchStart=()=>{a.ignoreEmulatedMouseEvents=!0},l.onMouseEnter=e=>{a.ignoreEmulatedMouseEvents||Yg||t(e,"mouse"),a.ignoreEmulatedMouseEvents=!1},l.onMouseLeave=t=>{!i&&t.currentTarget.contains(t.target)&&o(t,"mouse")}),{hoverProps:l,triggerHoverEnd:o}}),[e,n,r,i,a]);return Wn((()=>{i&&u({currentTarget:a.target},a.pointerType)}),[i]),{hoverProps:l,isHovered:o}}function ey(t={}){let{autoFocus:e=!1,isTextInput:n,within:r}=t,i=$n({isFocused:!1,isFocusVisible:e||qg()}),[o,s]=Nn(!1),[a,l]=Nn((()=>i.current.isFocused&&i.current.isFocusVisible)),u=Kn((()=>l(i.current.isFocused&&i.current.isFocusVisible)),[]),c=Kn((t=>{i.current.isFocused=t,s(t),u()}),[u]);Gg((t=>{i.current.isFocusVisible=t,u()}),[],{isTextInput:n});let{focusProps:d}=function(t){let{isDisabled:e,onFocus:n,onBlur:r,onFocusChange:i}=t;const o=Kn((t=>{if(t.target===t.currentTarget)return r&&r(t),i&&i(!1),!0}),[r,i]),s=Og(o),a=Kn((t=>{const e=kg(t.target);t.target===t.currentTarget&&e.activeElement===t.target&&(n&&n(t),i&&i(!0),s(t))}),[i,n,s]);return{focusProps:{onFocus:!e&&(n||i||r)?a:void 0,onBlur:e||!r&&!i?void 0:o}}}({isDisabled:r,onFocusChange:c}),{focusWithinProps:h}=function(t){let{isDisabled:e,onBlurWithin:n,onFocusWithin:r,onFocusWithinChange:i}=t,o=$n({isFocusWithin:!1}),s=Kn((t=>{o.current.isFocusWithin&&!t.currentTarget.contains(t.relatedTarget)&&(o.current.isFocusWithin=!1,n&&n(t),i&&i(!1))}),[n,i,o]),a=Og(s),l=Kn((t=>{o.current.isFocusWithin||document.activeElement!==t.target||(r&&r(t),i&&i(!0),o.current.isFocusWithin=!0,a(t))}),[r,i,a]);return e?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:l,onBlur:s}}}({isDisabled:!r,onFocusWithinChange:c});return{isFocused:o,isFocusVisible:a,focusProps:r?h:d}}var ny=Object.defineProperty,ry=(t,e,n)=>(((t,e,n)=>{e in t?ny(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n})(t,"symbol"!=typeof e?e+"":e,n),n);let iy=new class{constructor(){ry(this,"current",this.detect()),ry(this,"handoffState","pending"),ry(this,"currentId",0)}set(t){this.current!==t&&(this.handoffState="pending",this.currentId=0,this.current=t)}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 oy(t){return iy.isServer?null:t instanceof Node?t.ownerDocument:null!=t&&t.hasOwnProperty("current")&&t.current instanceof Node?t.current.ownerDocument:document}function sy(t){"function"==typeof queueMicrotask?queueMicrotask(t):Promise.resolve().then(t).catch((t=>setTimeout((()=>{throw t}))))}function ay(){let t=[],e={addEventListener:(t,n,r,i)=>(t.addEventListener(n,r,i),e.add((()=>t.removeEventListener(n,r,i)))),requestAnimationFrame(...t){let n=requestAnimationFrame(...t);return e.add((()=>cancelAnimationFrame(n)))},nextFrame:(...t)=>e.requestAnimationFrame((()=>e.requestAnimationFrame(...t))),setTimeout(...t){let n=setTimeout(...t);return e.add((()=>clearTimeout(n)))},microTask(...t){let n={current:!0};return sy((()=>{n.current&&t[0]()})),e.add((()=>{n.current=!1}))},style(t,e,n){let r=t.style.getPropertyValue(e);return Object.assign(t.style,{[e]:n}),this.add((()=>{Object.assign(t.style,{[e]:r})}))},group(t){let e=ay();return t(e),this.add((()=>e.dispose()))},add:e=>(t.includes(e)||t.push(e),()=>{let n=t.indexOf(e);if(n>=0)for(let e of t.splice(n,1))e()}),dispose(){for(let e of t.splice(0))e()}};return e}function ly(){let[t]=Nn(ay);return Wn((()=>()=>t.dispose()),[t]),t}let uy=(t,e)=>{iy.isServer?Wn(t,e):Hn(t,e)};function cy(t){let e=$n(t);return uy((()=>{e.current=t}),[t]),e}let dy=function(t){let e=cy(t);return si.useCallback(((...t)=>e.current(...t)),[e])};function hy({disabled:t=!1}={}){let e=$n(null),[n,r]=Nn(!1),i=ly(),o=dy((()=>{e.current=null,r(!1),i.dispose()})),s=dy((t=>{if(i.dispose(),null===e.current){e.current=t.currentTarget,r(!0);{let n=oy(t.currentTarget);i.addEventListener(n,"pointerup",o,!1),i.addEventListener(n,"pointermove",(t=>{if(e.current){let n=function(t){let e=t.width/2,n=t.height/2;return{top:t.clientY-n,right:t.clientX+e,bottom:t.clientY+n,left:t.clientX-e}}(t);r(function(t,e){return!(!t||!e||t.right<e.left||t.left>e.right||t.bottom<e.top||t.top>e.bottom)}(n,e.current.getBoundingClientRect()))}}),!1),i.addEventListener(n,"pointercancel",o,!1)}}}));return{pressed:n,pressProps:t?{}:{onPointerDown:s,onPointerUp:o,onClick:o}}}let py=fe(void 0);function fy(){return Gn(py)}function my({value:t,children:e}){return si.createElement(py.Provider,{value:t},e)}function vy(...t){return Array.from(new Set(t.flatMap((t=>"string"==typeof t?t.split(" "):[])))).filter(Boolean).join(" ")}function gy(t,e,...n){if(t in e){let r=e[t];return"function"==typeof r?r(...n):r}let r=new Error(`Tried to handle "${t}" but there is no handler defined. Only defined handlers are: ${Object.keys(e).map((t=>`"${t}"`)).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,gy),r}var yy,by,wy=((by=wy||{})[by.None=0]="None",by[by.RenderStrategy=1]="RenderStrategy",by[by.Static=2]="Static",by),xy=((yy=xy||{})[yy.Unmount=0]="Unmount",yy[yy.Hidden=1]="Hidden",yy);function _y({ourProps:t,theirProps:e,slot:n,defaultTag:r,features:i,visible:o=!0,name:s,mergeRefs:a}){a=null!=a?a:Ey;let l=ky(e,t);if(o)return Sy(l,n,r,s,a);let u=null!=i?i:0;if(2&u){let{static:t=!1,...e}=l;if(t)return Sy(e,n,r,s,a)}if(1&u){let{unmount:t=!0,...e}=l;return gy(t?0:1,{0:()=>null,1:()=>Sy({...e,hidden:!0,style:{display:"none"}},n,r,s,a)})}return Sy(l,n,r,s,a)}function Sy(t,e={},n,r,i){let{as:o=n,children:s,refName:a="ref",...l}=Ay(t,["unmount","static"]),u=void 0!==t.ref?{[a]:t.ref}:{},c="function"==typeof s?s(e):s;"className"in l&&l.className&&"function"==typeof l.className&&(l.className=l.className(e)),l["aria-labelledby"]&&l["aria-labelledby"]===l.id&&(l["aria-labelledby"]=void 0);let d={};if(e){let t=!1,n=[];for(let[r,i]of Object.entries(e))"boolean"==typeof i&&(t=!0),!0===i&&n.push(r.replace(/([A-Z])/g,(t=>`-${t.toLowerCase()}`)));if(t){d["data-headlessui-state"]=n.join(" ");for(let t of n)d[`data-${t}`]=""}}if(o===Kt&&(Object.keys(Cy(l)).length>0||Object.keys(Cy(d)).length>0)){if($r(c)&&!(Array.isArray(c)&&c.length>1)){let t=c.props,e=null==t?void 0:t.className,n="function"==typeof e?(...t)=>vy(e(...t),l.className):vy(e,l.className),r=n?{className:n}:{},o=ky(c.props,Cy(Ay(l,["ref"])));for(let i in d)i in o&&delete d[i];return Kr(c,Object.assign({},o,d,u,{ref:i(c.ref,u.ref)},r))}if(Object.keys(Cy(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(Cy(l)).concat(Object.keys(Cy(d))).map((t=>` - ${t}`)).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((t=>` - ${t}`)).join("\n")].join("\n"))}return $t(o,Object.assign({},Ay(l,["ref"]),o!==Kt&&u,o!==Kt&&d),c)}function Ey(...t){return t.every((t=>null==t))?void 0:e=>{for(let n of t)null!=n&&("function"==typeof n?n(e):n.current=e)}}function ky(...t){if(0===t.length)return{};if(1===t.length)return t[0];let e={},n={};for(let r of t)for(let t in r)t.startsWith("on")&&"function"==typeof r[t]?(null!=n[t]||(n[t]=[]),n[t].push(r[t])):e[t]=r[t];if(e.disabled||e["aria-disabled"])for(let r in n)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(r)&&(n[r]=[t=>{var e;return null==(e=null==t?void 0:t.preventDefault)?void 0:e.call(t)}]);for(let r in n)Object.assign(e,{[r](t,...e){let i=n[r];for(let n of i){if((t instanceof Event||(null==t?void 0:t.nativeEvent)instanceof Event)&&t.defaultPrevented)return;n(t,...e)}}});return e}function Py(...t){if(0===t.length)return{};if(1===t.length)return t[0];let e={},n={};for(let r of t)for(let t in r)t.startsWith("on")&&"function"==typeof r[t]?(null!=n[t]||(n[t]=[]),n[t].push(r[t])):e[t]=r[t];for(let r in n)Object.assign(e,{[r](...t){let e=n[r];for(let n of e)null==n||n(...t)}});return e}function Ty(t){var e;return Object.assign(cr(t),{displayName:null!=(e=t.displayName)?e:t.name})}function Cy(t){let e=Object.assign({},t);for(let n in e)void 0===e[n]&&delete e[n];return e}function Ay(t,e=[]){let n=Object.assign({},t);for(let r of e)r in n&&delete n[r];return n}function Ry(t,e,n){let[r,i]=Nn(n),o=void 0!==t,s=$n(o),a=$n(!1),l=$n(!1);return!o||s.current||a.current?!o&&s.current&&!l.current&&(l.current=!0,s.current=o,console.error("A component is changing from controlled to uncontrolled. This may be caused by the value changing from a defined value to undefined, which should not happen.")):(a.current=!0,s.current=o,console.error("A component is changing from uncontrolled to controlled. This may be caused by the value changing from undefined to a defined value, which should not happen.")),[o?t:r,dy((t=>(o||i(t),null==e?void 0:e(t))))]}function Oy(t){let[e]=Nn(t);return e}function Fy(t={},e=null,n=[]){for(let[r,i]of Object.entries(t))My(n,Ly(e,r),i);return n}function Ly(t,e){return t?t+"["+e+"]":e}function My(t,e,n){if(Array.isArray(n))for(let[r,i]of n.entries())My(t,Ly(e,r.toString()),i);else n instanceof Date?t.push([e,n.toISOString()]):"boolean"==typeof n?t.push([e,n?"1":"0"]):"string"==typeof n?t.push([e,n]):"number"==typeof n?t.push([e,`${n}`]):null==n?t.push([e,""]):Fy(n,e,t)}function Dy(t){var e,n;let r=null!=(e=null==t?void 0:t.form)?e:t.closest("form");if(r){for(let e of r.elements)if(e!==t&&("INPUT"===e.tagName&&"submit"===e.type||"BUTTON"===e.tagName&&"submit"===e.type||"INPUT"===e.nodeName&&"image"===e.type))return void e.click();null==(n=r.requestSubmit)||n.call(r)}}var Vy=(t=>(t[t.None=1]="None",t[t.Focusable=2]="Focusable",t[t.Hidden=4]="Hidden",t))(Vy||{});let jy=Ty((function(t,e){var n;let{features:r=1,...i}=t;return _y({ourProps:{ref:e,"aria-hidden":!(2&~r)||(null!=(n=i["aria-hidden"])?n:void 0),hidden:!(4&~r)||void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...!(4&~r)&&!!(2&~r)&&{display:"none"}}},theirProps:i,slot:{},defaultTag:"span",name:"Hidden"})})),Iy=fe(null);function By(t){let[e,n]=Nn(null);return si.createElement(Iy.Provider,{value:{target:e}},t.children,si.createElement(jy,{features:Vy.Hidden,ref:n}))}function Ny({children:t}){let e=Gn(Iy);if(!e)return si.createElement(si.Fragment,null,t);let{target:n}=e;return n?Er(si.createElement(si.Fragment,null,t),n):null}function Uy({data:t,form:e,disabled:n,onReset:r,overrides:i}){let[o,s]=Nn(null),a=ly();return Wn((()=>{if(r&&o)return a.addEventListener(o,"reset",r)}),[o,e,r]),si.createElement(Ny,null,si.createElement(Wy,{setForm:s,formId:e}),Fy(t).map((([t,r])=>si.createElement(jy,{features:Vy.Hidden,...Cy({key:t,as:"input",type:"hidden",hidden:!0,readOnly:!0,form:e,disabled:n,name:t,value:r,...i})}))))}function Wy({setForm:t,formId:e}){return Wn((()=>{if(e){let n=document.getElementById(e);n&&t(n)}}),[t,e]),e?null:si.createElement(jy,{features:Vy.Hidden,as:"input",type:"hidden",hidden:!0,readOnly:!0,ref:e=>{if(!e)return;let n=e.closest("form");n&&t(n)}})}let Hy=fe(void 0);function $y(){return Gn(Hy)}function zy({id:t,children:e}){return si.createElement(Hy.Provider,{value:t},e)}function qy(t){let e=t.parentElement,n=null;for(;e&&!(e instanceof HTMLFieldSetElement);)e instanceof HTMLLegendElement&&(n=e),e=e.parentElement;let r=""===(null==e?void 0:e.getAttribute("disabled"));return(!r||!function(t){if(!t)return!1;let e=t.previousElementSibling;for(;null!==e;){if(e instanceof HTMLLegendElement)return!1;e=e.previousElementSibling}return!0}(n))&&r}let Ky=Symbol();function Gy(...t){let e=$n(t);Wn((()=>{e.current=t}),[t]);let n=dy((t=>{for(let n of e.current)null!=n&&("function"==typeof n?n(t):n.current=t)}));return t.every((t=>null==t||(null==t?void 0:t[Ky])))?void 0:n}let Yy=fe(null);function Qy(){let t=Gn(Yy);if(null===t){let t=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,Qy),t}return t}function Xy(){var t,e;return null!=(e=null==(t=Gn(Yy))?void 0:t.value)?e:void 0}function Zy(){let[t,e]=Nn([]);return[t.length>0?t.join(" "):void 0,qn((()=>function(t){let n=dy((t=>(e((e=>[...e,t])),()=>e((e=>{let n=e.slice(),r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}))))),r=qn((()=>({register:n,slot:t.slot,name:t.name,props:t.props,value:t.value})),[n,t.slot,t.name,t.props,t.value]);return si.createElement(Yy.Provider,{value:r},t.children)}),[e])]}Yy.displayName="DescriptionContext";let Jy=Ty((function(t,e){let n=Qn(),r=fy(),{id:i=`headlessui-description-${n}`,...o}=t,s=Qy(),a=Gy(e);uy((()=>s.register(i)),[i,s.register]);let l=r||!1,u=qn((()=>({...s.slot,disabled:l})),[s.slot,l]);return _y({ourProps:{ref:a,...s.props,id:i},theirProps:o,slot:u,defaultTag:"p",name:s.name||"Description"})})),tb=Object.assign(Jy,{});var eb,nb=((eb=nb||{}).Space=" ",eb.Enter="Enter",eb.Escape="Escape",eb.Backspace="Backspace",eb.Delete="Delete",eb.ArrowLeft="ArrowLeft",eb.ArrowUp="ArrowUp",eb.ArrowRight="ArrowRight",eb.ArrowDown="ArrowDown",eb.Home="Home",eb.End="End",eb.PageUp="PageUp",eb.PageDown="PageDown",eb.Tab="Tab",eb);let rb=fe(null);function ib(){let t=Gn(rb);if(null===t){let t=new Error("You used a <Label /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,ib),t}return t}function ob(t){var e,n,r;let i=null!=(n=null==(e=Gn(rb))?void 0:e.value)?n:void 0;return(null!=(r=null==t?void 0:t.length)?r:0)>0?[i,...t].filter(Boolean).join(" "):i}function sb({inherit:t=!1}={}){let e=ob(),[n,r]=Nn([]),i=t?[e,...n].filter(Boolean):n;return[i.length>0?i.join(" "):void 0,qn((()=>function(t){let e=dy((t=>(r((e=>[...e,t])),()=>r((e=>{let n=e.slice(),r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}))))),n=qn((()=>({register:e,slot:t.slot,name:t.name,props:t.props,value:t.value})),[e,t.slot,t.name,t.props,t.value]);return si.createElement(rb.Provider,{value:n},t.children)}),[r])]}rb.displayName="LabelContext";let ab=Ty((function(t,e){var n;let r=Qn(),i=ib(),o=$y(),s=fy(),{id:a=`headlessui-label-${r}`,htmlFor:l=(null!=o?o:null==(n=i.props)?void 0:n.htmlFor),passive:u=!1,...c}=t,d=Gy(e);uy((()=>i.register(a)),[a,i.register]);let h=dy((t=>{let e=t.currentTarget;if(e instanceof HTMLLabelElement&&t.preventDefault(),i.props&&"onClick"in i.props&&"function"==typeof i.props.onClick&&i.props.onClick(t),e instanceof HTMLLabelElement){let t=document.getElementById(e.htmlFor);if(t){let e=t.getAttribute("disabled");if("true"===e||""===e)return;let n=t.getAttribute("aria-disabled");if("true"===n||""===n)return;(t instanceof HTMLInputElement&&("radio"===t.type||"checkbox"===t.type)||"radio"===t.role||"checkbox"===t.role||"switch"===t.role)&&t.click(),t.focus({preventScroll:!0})}}})),p=s||!1,f=qn((()=>({...i.slot,disabled:p})),[i.slot,p]),m={ref:d,...i.props,id:a,htmlFor:l,onClick:h};return u&&("onClick"in m&&(delete m.htmlFor,delete m.onClick),"onClick"in c&&delete c.onClick),_y({ourProps:m,theirProps:c,slot:f,defaultTag:l?"label":"div",name:i.name||"Label"})})),lb=Object.assign(ab,{});function ub(t,e){return null!==t&&null!==e&&"object"==typeof t&&"object"==typeof e&&"id"in t&&"id"in e?t.id===e.id:t===e}function cb(t,e=!1){let[n,r]=Un((()=>({})),{}),i=qn((()=>function(t){if(null===t)return{width:0,height:0};let{width:e,height:n}=t.getBoundingClientRect();return{width:e,height:n}}(t)),[t,n]);return uy((()=>{if(!t)return;let e=new ResizeObserver(r);return e.observe(t),()=>{e.disconnect()}}),[t]),e?{width:`${i.width}px`,height:`${i.height}px`}:i}let db=class extends Map{constructor(t){super(),this.factory=t}get(t){let e=super.get(t);return void 0===e&&(e=this.factory(t),this.set(t,e)),e}};function hb(t,e){let n=t(),r=new Set;return{getSnapshot:()=>n,subscribe:t=>(r.add(t),()=>r.delete(t)),dispatch(t,...i){let o=e[t].call(n,...i);o&&(n=o,r.forEach((t=>t())))}}}function pb(t){return ii(t.subscribe,t.getSnapshot,t.getSnapshot)}let fb=new db((()=>hb((()=>[]),{ADD(t){return this.includes(t)?this:[...this,t]},REMOVE(t){let e=this.indexOf(t);if(-1===e)return this;let n=this.slice();return n.splice(e,1),n}})));function mb(t,e){let n=fb.get(e),r=Qn(),i=pb(n);if(uy((()=>{if(t)return n.dispatch("ADD",r),()=>n.dispatch("REMOVE",r)}),[n,t]),!t)return!1;let o=i.indexOf(r),s=i.length;return-1===o&&(o=s,s+=1),o===s-1}let vb=new Map,gb=new Map;function yb(t){var e;let n=null!=(e=gb.get(t))?e:0;return gb.set(t,n+1),0!==n||(vb.set(t,{"aria-hidden":t.getAttribute("aria-hidden"),inert:t.inert}),t.setAttribute("aria-hidden","true"),t.inert=!0),()=>bb(t)}function bb(t){var e;let n=null!=(e=gb.get(t))?e:1;if(1===n?gb.delete(t):gb.set(t,n-1),1!==n)return;let r=vb.get(t);r&&(null===r["aria-hidden"]?t.removeAttribute("aria-hidden"):t.setAttribute("aria-hidden",r["aria-hidden"]),t.inert=r.inert,vb.delete(t))}let wb=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map((t=>`${t}:not([tabindex='-1'])`)).join(","),xb=["[data-autofocus]"].map((t=>`${t}:not([tabindex='-1'])`)).join(",");var _b,Sb,Eb,kb=((Eb=kb||{})[Eb.First=1]="First",Eb[Eb.Previous=2]="Previous",Eb[Eb.Next=4]="Next",Eb[Eb.Last=8]="Last",Eb[Eb.WrapAround=16]="WrapAround",Eb[Eb.NoScroll=32]="NoScroll",Eb[Eb.AutoFocus=64]="AutoFocus",Eb),Pb=((Sb=Pb||{})[Sb.Error=0]="Error",Sb[Sb.Overflow=1]="Overflow",Sb[Sb.Success=2]="Success",Sb[Sb.Underflow=3]="Underflow",Sb),Tb=((_b=Tb||{})[_b.Previous=-1]="Previous",_b[_b.Next=1]="Next",_b);function Cb(t=document.body){return null==t?[]:Array.from(t.querySelectorAll(wb)).sort(((t,e)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(e.tabIndex||Number.MAX_SAFE_INTEGER))))}var Ab=(t=>(t[t.Strict=0]="Strict",t[t.Loose=1]="Loose",t))(Ab||{});function Rb(t,e=0){var n;return t!==(null==(n=oy(t))?void 0:n.body)&&gy(e,{0:()=>t.matches(wb),1(){let e=t;for(;null!==e;){if(e.matches(wb))return!0;e=e.parentElement}return!1}})}var Ob=(t=>(t[t.Keyboard=0]="Keyboard",t[t.Mouse=1]="Mouse",t))(Ob||{});"undefined"!=typeof window&&"undefined"!=typeof document&&(document.addEventListener("keydown",(t=>{t.metaKey||t.altKey||t.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")}),!0),document.addEventListener("click",(t=>{1===t.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===t.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")}),!0));let Fb=["textarea","input"].join(",");function Lb(t,e=t=>t){return t.slice().sort(((t,n)=>{let r=e(t),i=e(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 Mb(t,e){return function(t,e,{sorted:n=!0,relativeTo:r=null,skipElements:i=[]}={}){let o=Array.isArray(t)?t.length>0?t[0].ownerDocument:document:t.ownerDocument,s=Array.isArray(t)?n?Lb(t):t:64&e?function(t=document.body){return null==t?[]:Array.from(t.querySelectorAll(xb)).sort(((t,e)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(e.tabIndex||Number.MAX_SAFE_INTEGER))))}(t):Cb(t);i.length>0&&s.length>1&&(s=s.filter((t=>!i.some((e=>null!=e&&"current"in e?(null==e?void 0:e.current)===t:e===t))))),r=null!=r?r:o.activeElement;let a,l=(()=>{if(5&e)return 1;if(10&e)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),u=(()=>{if(1&e)return 0;if(2&e)return Math.max(0,s.indexOf(r))-1;if(4&e)return Math.max(0,s.indexOf(r))+1;if(8&e)return s.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),c=32&e?{preventScroll:!0}:{},d=0,h=s.length;do{if(d>=h||d+h<=0)return 0;let t=u+d;if(16&e)t=(t+h)%h;else{if(t<0)return 3;if(t>=h)return 1}a=s[t],null==a||a.focus(c),d+=l}while(a!==o.activeElement);return 6&e&&function(t){var e,n;return null!=(n=null==(e=null==t?void 0:t.matches)?void 0:e.call(t,Fb))&&n}(a)&&a.select(),2}(Cb(),e,{relativeTo:t})}function Db(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function Vb(){return Db()||/Android/gi.test(window.navigator.userAgent)}function jb(t,e,n,r){let i=cy(n);Wn((()=>{if(t)return document.addEventListener(e,n,r),()=>document.removeEventListener(e,n,r);function n(t){i.current(t)}}),[t,e,r])}const Ib=30;function Bb(t,e,n){let r=mb(t,"outside-click"),i=cy(n),o=Kn((function(t,n){if(t.defaultPrevented)return;let r=n(t);if(null===r||!r.getRootNode().contains(r)||!r.isConnected)return;let o=function t(e){return"function"==typeof e?t(e()):Array.isArray(e)||e instanceof Set?e:[e]}(e);for(let e of o)if(null!==e&&(e.contains(r)||t.composed&&t.composedPath().includes(e)))return;return!Rb(r,Ab.Loose)&&-1!==r.tabIndex&&t.preventDefault(),i.current(t,r)}),[i,e]),s=$n(null);jb(r,"pointerdown",(t=>{var e,n;s.current=(null==(n=null==(e=t.composedPath)?void 0:e.call(t))?void 0:n[0])||t.target}),!0),jb(r,"mousedown",(t=>{var e,n;s.current=(null==(n=null==(e=t.composedPath)?void 0:e.call(t))?void 0:n[0])||t.target}),!0),jb(r,"click",(t=>{Vb()||s.current&&(o(t,(()=>s.current)),s.current=null)}),!0);let a=$n({x:0,y:0});jb(r,"touchstart",(t=>{a.current.x=t.touches[0].clientX,a.current.y=t.touches[0].clientY}),!0),jb(r,"touchend",(t=>{let e=t.changedTouches[0].clientX,n=t.changedTouches[0].clientY;if(!(Math.abs(e-a.current.x)>=Ib||Math.abs(n-a.current.y)>=Ib))return o(t,(()=>t.target instanceof HTMLElement?t.target:null))}),!0),function(t,e,n,r){let i=cy(n);Wn((()=>{if(t)return window.addEventListener(e,n,r),()=>window.removeEventListener(e,n,r);function n(t){i.current(t)}}),[t,e,r])}(r,"blur",(t=>o(t,(()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null))),!0)}function Nb(...t){return qn((()=>oy(...t)),[...t])}function Ub(t,e){return qn((()=>{var n;if(t.type)return t.type;let r=null!=(n=t.as)?n:"button";return"string"==typeof r&&"button"===r.toLowerCase()||"BUTTON"===(null==e?void 0:e.tagName)&&!e.hasAttribute("type")?"button":void 0}),[t.type,t.as,e])}function Wb(){let t;return{before({doc:e}){var n;let r=e.documentElement,i=null!=(n=e.defaultView)?n:window;t=Math.max(0,i.innerWidth-r.clientWidth)},after({doc:e,d:n}){let r=e.documentElement,i=Math.max(0,r.clientWidth-r.offsetWidth),o=Math.max(0,t-i);n.style(r,"paddingRight",`${o}px`)}}}function Hb(t){let e={};for(let n of t)Object.assign(e,n(e));return e}let $b=hb((()=>new Map),{PUSH(t,e){var n;let r=null!=(n=this.get(t))?n:{doc:t,count:0,d:ay(),meta:new Set};return r.count++,r.meta.add(e),this.set(t,r),this},POP(t,e){let n=this.get(t);return n&&(n.count--,n.meta.delete(e)),this},SCROLL_PREVENT({doc:t,d:e,meta:n}){let r={doc:t,d:e,meta:Hb(n)},i=[Db()?{before({doc:t,d:e,meta:n}){function r(t){return n.containers.flatMap((t=>t())).some((e=>e.contains(t)))}e.microTask((()=>{var n;if("auto"!==window.getComputedStyle(t.documentElement).scrollBehavior){let n=ay();n.style(t.documentElement,"scrollBehavior","auto"),e.add((()=>e.microTask((()=>n.dispose()))))}let i=null!=(n=window.scrollY)?n:window.pageYOffset,o=null;e.addEventListener(t,"click",(e=>{if(e.target instanceof HTMLElement)try{let n=e.target.closest("a");if(!n)return;let{hash:i}=new URL(n.href),s=t.querySelector(i);s&&!r(s)&&(o=s)}catch{}}),!0),e.addEventListener(t,"touchstart",(t=>{if(t.target instanceof HTMLElement)if(r(t.target)){let n=t.target;for(;n.parentElement&&r(n.parentElement);)n=n.parentElement;e.style(n,"overscrollBehavior","contain")}else e.style(t.target,"touchAction","none")})),e.addEventListener(t,"touchmove",(t=>{if(t.target instanceof HTMLElement){if("INPUT"===t.target.tagName)return;if(r(t.target)){let e=t.target;for(;e.parentElement&&""!==e.dataset.headlessuiPortal&&!(e.scrollHeight>e.clientHeight||e.scrollWidth>e.clientWidth);)e=e.parentElement;""===e.dataset.headlessuiPortal&&t.preventDefault()}else t.preventDefault()}}),{passive:!1}),e.add((()=>{var t;let e=null!=(t=window.scrollY)?t:window.pageYOffset;i!==e&&window.scrollTo(0,i),o&&o.isConnected&&(o.scrollIntoView({block:"nearest"}),o=null)}))}))}}:{},Wb(),{before({doc:t,d:e}){e.style(t.documentElement,"overflow","hidden")}}];i.forEach((({before:t})=>null==t?void 0:t(r))),i.forEach((({after:t})=>null==t?void 0:t(r)))},SCROLL_ALLOW({d:t}){t.dispose()},TEARDOWN({doc:t}){this.delete(t)}});function zb(t,e,n=()=>[document.body]){!function(t,e,n=()=>({containers:[]})){let r=pb($b),i=e?r.get(e):void 0,o=!!i&&i.count>0;uy((()=>{if(e&&t)return $b.dispatch("PUSH",e,n),()=>$b.dispatch("POP",e,n)}),[t,e])}(mb(t,"scroll-lock"),e,(t=>{var e;return{containers:[...null!=(e=t.containers)?e:[],n]}}))}function qb(t){return[t.screenX,t.screenY]}$b.subscribe((()=>{let t=$b.getSnapshot(),e=new Map;for(let[n]of t)e.set(n,n.documentElement.style.overflow);for(let n of t.values()){let t="hidden"===e.get(n.doc),r=0!==n.count;(r&&!t||!r&&t)&&$b.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),0===n.count&&$b.dispatch("TEARDOWN",n)}}));var Kb;"undefined"!=typeof process&&"undefined"!=typeof globalThis&&"test"===(null==(Kb=null==process?void 0:{})?void 0:Kb.NODE_ENV)&&void 0===Element.prototype.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 Gb=(t=>(t[t.None=0]="None",t[t.Closed=1]="Closed",t[t.Enter=2]="Enter",t[t.Leave=4]="Leave",t))(Gb||{});function Yb(t){let e={};for(let n in t)!0===t[n]&&(e[`data-${n}`]="");return e}function Qb(t,e,n,r){let[i,o]=Nn(n),{hasFlag:s,addFlag:a,removeFlag:l}=function(t=0){let[e,n]=Nn(t),r=Kn((t=>n(t)),[e]),i=Kn((t=>n((e=>e|t))),[e]),o=Kn((t=>(e&t)===t),[e]),s=Kn((t=>n((e=>e&~t))),[n]),a=Kn((t=>n((e=>e^t))),[n]);return{flags:e,setFlag:r,addFlag:i,hasFlag:o,removeFlag:s,toggleFlag:a}}(t&&i?3:0),u=$n(!1),c=$n(!1),d=ly();return uy((()=>{var i;if(t)return n&&o(!0),e?(null==(i=null==r?void 0:r.start)||i.call(r,n),function(t,{prepare:e,run:n,done:r,inFlight:i}){let o=ay();return function(t,{inFlight:e,prepare:n}){if(null!=e&&e.current)return void n();let r=t.style.transition;t.style.transition="none",n(),t.offsetHeight,t.style.transition=r}(t,{prepare:e,inFlight:i}),o.nextFrame((()=>{n(),o.requestAnimationFrame((()=>{o.add(function(t,e){var n,r;let i=ay();if(!t)return i.dispose;let o=!1;i.add((()=>{o=!0}));let s=null!=(r=null==(n=t.getAnimations)?void 0:n.call(t).filter((t=>t instanceof CSSTransition)))?r:[];return 0===s.length?(e(),i.dispose):(Promise.allSettled(s.map((t=>t.finished))).then((()=>{o||e()})),i.dispose)}(t,r))}))})),o.dispose}(e,{inFlight:u,prepare(){c.current?c.current=!1:c.current=u.current,u.current=!0,!c.current&&(n?(a(3),l(4)):(a(4),l(2)))},run(){c.current?n?(l(3),a(4)):(l(4),a(3)):n?l(1):a(1)},done(){var t;c.current&&"function"==typeof e.getAnimations&&e.getAnimations().length>0||(u.current=!1,l(7),n||o(!1),null==(t=null==r?void 0:r.end)||t.call(r,n))}})):void(n&&a(3))}),[t,n,e,d]),t?[i,{closed:s(1),enter:s(2),leave:s(4),transition:s(2)||s(4)}]:[n,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function Xb(){return"undefined"!=typeof window}function Zb(t){return ew(t)?(t.nodeName||"").toLowerCase():"#document"}function Jb(t){var e;return(null==t||null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function tw(t){var e;return null==(e=(ew(t)?t.ownerDocument:t.document)||window.document)?void 0:e.documentElement}function ew(t){return!!Xb()&&(t instanceof Node||t instanceof Jb(t).Node)}function nw(t){return!!Xb()&&(t instanceof Element||t instanceof Jb(t).Element)}function rw(t){return!!Xb()&&(t instanceof HTMLElement||t instanceof Jb(t).HTMLElement)}function iw(t){return!(!Xb()||"undefined"==typeof ShadowRoot)&&(t instanceof ShadowRoot||t instanceof Jb(t).ShadowRoot)}function ow(t){const{overflow:e,overflowX:n,overflowY:r,display:i}=dw(t);return/auto|scroll|overlay|hidden|clip/.test(e+r+n)&&!["inline","contents"].includes(i)}function sw(t){return["table","td","th"].includes(Zb(t))}function aw(t){return[":popover-open",":modal"].some((e=>{try{return t.matches(e)}catch(yy){return!1}}))}function lw(t){const e=uw(),n=nw(t)?dw(t):t;return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!e&&!!n.backdropFilter&&"none"!==n.backdropFilter||!e&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((t=>(n.willChange||"").includes(t)))||["paint","layout","strict","content"].some((t=>(n.contain||"").includes(t)))}function uw(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function cw(t){return["html","body","#document"].includes(Zb(t))}function dw(t){return Jb(t).getComputedStyle(t)}function hw(t){return nw(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function pw(t){if("html"===Zb(t))return t;const e=t.assignedSlot||t.parentNode||iw(t)&&t.host||tw(t);return iw(e)?e.host:e}function fw(t){const e=pw(t);return cw(e)?t.ownerDocument?t.ownerDocument.body:t.body:rw(e)&&ow(e)?e:fw(e)}function mw(t,e,n){var r;void 0===e&&(e=[]),void 0===n&&(n=!0);const i=fw(t),o=i===(null==(r=t.ownerDocument)?void 0:r.body),s=Jb(i);if(o){const t=vw(s);return e.concat(s,s.visualViewport||[],ow(i)?i:[],t&&n?mw(t):[])}return e.concat(i,mw(i,[],n))}function vw(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}const gw=Math.min,yw=Math.max,bw=Math.round,ww=Math.floor,xw=t=>({x:t,y:t}),_w={left:"right",right:"left",bottom:"top",top:"bottom"},Sw={start:"end",end:"start"};function Ew(t,e,n){return yw(t,gw(e,n))}function kw(t,e){return"function"==typeof t?t(e):t}function Pw(t){return t.split("-")[0]}function Tw(t){return t.split("-")[1]}function Cw(t){return"x"===t?"y":"x"}function Aw(t){return"y"===t?"height":"width"}function Rw(t){return["top","bottom"].includes(Pw(t))?"y":"x"}function Ow(t){return Cw(Rw(t))}function Fw(t){return t.replace(/start|end/g,(t=>Sw[t]))}function Lw(t){return t.replace(/left|right|bottom|top/g,(t=>_w[t]))}function Mw(t){const{x:e,y:n,width:r,height:i}=t;return{width:r,height:i,top:n,left:e,right:e+r,bottom:n+i,x:e,y:n}}function Dw(t,e,n){let{reference:r,floating:i}=t;const o=Rw(e),s=Ow(e),a=Aw(s),l=Pw(e),u="y"===o,c=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,h=r[a]/2-i[a]/2;let p;switch(l){case"top":p={x:c,y:r.y-i.height};break;case"bottom":p={x:c,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:d};break;case"left":p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(Tw(e)){case"start":p[s]-=h*(n&&u?-1:1);break;case"end":p[s]+=h*(n&&u?-1:1)}return p}async function Vw(t,e){var n;void 0===e&&(e={});const{x:r,y:i,platform:o,rects:s,elements:a,strategy:l}=t,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:h=!1,padding:p=0}=kw(e,t),f=function(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}(p),m=a[h?"floating"===d?"reference":"floating":d],v=Mw(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(m)))||n?m:m.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(a.floating)),boundary:u,rootBoundary:c,strategy:l})),g="floating"===d?{x:r,y:i,width:s.floating.width,height:s.floating.height}:s.reference,y=await(null==o.getOffsetParent?void 0:o.getOffsetParent(a.floating)),b=await(null==o.isElement?void 0:o.isElement(y))&&await(null==o.getScale?void 0:o.getScale(y))||{x:1,y:1},w=Mw(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:g,offsetParent:y,strategy:l}):g);return{top:(v.top-w.top+f.top)/b.y,bottom:(w.bottom-v.bottom+f.bottom)/b.y,left:(v.left-w.left+f.left)/b.x,right:(w.right-v.right+f.right)/b.x}}function jw(t){const e=dw(t);let n=parseFloat(e.width)||0,r=parseFloat(e.height)||0;const i=rw(t),o=i?t.offsetWidth:n,s=i?t.offsetHeight:r,a=bw(n)!==o||bw(r)!==s;return a&&(n=o,r=s),{width:n,height:r,$:a}}function Iw(t){return nw(t)?t:t.contextElement}function Bw(t){const e=Iw(t);if(!rw(e))return xw(1);const n=e.getBoundingClientRect(),{width:r,height:i,$:o}=jw(e);let s=(o?bw(n.width):n.width)/r,a=(o?bw(n.height):n.height)/i;return s&&Number.isFinite(s)||(s=1),a&&Number.isFinite(a)||(a=1),{x:s,y:a}}const Nw=xw(0);function Uw(t){const e=Jb(t);return uw()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:Nw}function Ww(t,e,n,r){void 0===e&&(e=!1),void 0===n&&(n=!1);const i=t.getBoundingClientRect(),o=Iw(t);let s=xw(1);e&&(r?nw(r)&&(s=Bw(r)):s=Bw(t));const a=function(t,e,n){return void 0===e&&(e=!1),!(!n||e&&n!==Jb(t))&&e}(o,n,r)?Uw(o):xw(0);let l=(i.left+a.x)/s.x,u=(i.top+a.y)/s.y,c=i.width/s.x,d=i.height/s.y;if(o){const t=Jb(o),e=r&&nw(r)?Jb(r):r;let n=t,i=vw(n);for(;i&&r&&e!==n;){const t=Bw(i),e=i.getBoundingClientRect(),r=dw(i),o=e.left+(i.clientLeft+parseFloat(r.paddingLeft))*t.x,s=e.top+(i.clientTop+parseFloat(r.paddingTop))*t.y;l*=t.x,u*=t.y,c*=t.x,d*=t.y,l+=o,u+=s,n=Jb(i),i=vw(n)}}return Mw({width:c,height:d,x:l,y:u})}function Hw(t,e){const n=hw(t).scrollLeft;return e?e.left+n:Ww(tw(t)).left+n}function $w(t,e,n){let r;if("viewport"===e)r=function(t,e){const n=Jb(t),r=tw(t),i=n.visualViewport;let o=r.clientWidth,s=r.clientHeight,a=0,l=0;if(i){o=i.width,s=i.height;const t=uw();(!t||t&&"fixed"===e)&&(a=i.offsetLeft,l=i.offsetTop)}return{width:o,height:s,x:a,y:l}}(t,n);else if("document"===e)r=function(t){const e=tw(t),n=hw(t),r=t.ownerDocument.body,i=yw(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),o=yw(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+Hw(t);const a=-n.scrollTop;return"rtl"===dw(r).direction&&(s+=yw(e.clientWidth,r.clientWidth)-i),{width:i,height:o,x:s,y:a}}(tw(t));else if(nw(e))r=function(t,e){const n=Ww(t,!0,"fixed"===e),r=n.top+t.clientTop,i=n.left+t.clientLeft,o=rw(t)?Bw(t):xw(1);return{width:t.clientWidth*o.x,height:t.clientHeight*o.y,x:i*o.x,y:r*o.y}}(e,n);else{const n=Uw(t);r={...e,x:e.x-n.x,y:e.y-n.y}}return Mw(r)}function zw(t,e){const n=pw(t);return!(n===e||!nw(n)||cw(n))&&("fixed"===dw(n).position||zw(n,e))}function qw(t,e,n){const r=rw(e),i=tw(e),o="fixed"===n,s=Ww(t,!0,o,e);let a={scrollLeft:0,scrollTop:0};const l=xw(0);if(r||!r&&!o)if(("body"!==Zb(e)||ow(i))&&(a=hw(e)),r){const t=Ww(e,!0,o,e);l.x=t.x+e.clientLeft,l.y=t.y+e.clientTop}else i&&(l.x=Hw(i));let u=0,c=0;if(i&&!r&&!o){const t=i.getBoundingClientRect();c=t.top+a.scrollTop,u=t.left+a.scrollLeft-Hw(i,t)}return{x:s.left+a.scrollLeft-l.x-u,y:s.top+a.scrollTop-l.y-c,width:s.width,height:s.height}}function Kw(t){return"static"===dw(t).position}function Gw(t,e){if(!rw(t)||"fixed"===dw(t).position)return null;if(e)return e(t);let n=t.offsetParent;return tw(t)===n&&(n=n.ownerDocument.body),n}function Yw(t,e){const n=Jb(t);if(aw(t))return n;if(!rw(t)){let e=pw(t);for(;e&&!cw(e);){if(nw(e)&&!Kw(e))return e;e=pw(e)}return n}let r=Gw(t,e);for(;r&&sw(r)&&Kw(r);)r=Gw(r,e);return r&&cw(r)&&Kw(r)&&!lw(r)?n:r||function(t){let e=pw(t);for(;rw(e)&&!cw(e);){if(lw(e))return e;if(aw(e))return null;e=pw(e)}return null}(t)||n}const Qw={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{elements:e,rect:n,offsetParent:r,strategy:i}=t;const o="fixed"===i,s=tw(r),a=!!e&&aw(e.floating);if(r===s||a&&o)return n;let l={scrollLeft:0,scrollTop:0},u=xw(1);const c=xw(0),d=rw(r);if((d||!d&&!o)&&(("body"!==Zb(r)||ow(s))&&(l=hw(r)),rw(r))){const t=Ww(r);u=Bw(r),c.x=t.x+r.clientLeft,c.y=t.y+r.clientTop}return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+c.x,y:n.y*u.y-l.scrollTop*u.y+c.y}},getDocumentElement:tw,getClippingRect:function(t){let{element:e,boundary:n,rootBoundary:r,strategy:i}=t;const o=[..."clippingAncestors"===n?aw(e)?[]:function(t,e){const n=e.get(t);if(n)return n;let r=mw(t,[],!1).filter((t=>nw(t)&&"body"!==Zb(t))),i=null;const o="fixed"===dw(t).position;let s=o?pw(t):t;for(;nw(s)&&!cw(s);){const e=dw(s),n=lw(s);n||"fixed"!==e.position||(i=null),(o?!n&&!i:!n&&"static"===e.position&&i&&["absolute","fixed"].includes(i.position)||ow(s)&&!n&&zw(t,s))?r=r.filter((t=>t!==s)):i=e,s=pw(s)}return e.set(t,r),r}(e,this._c):[].concat(n),r],s=o[0],a=o.reduce(((t,n)=>{const r=$w(e,n,i);return t.top=yw(r.top,t.top),t.right=gw(r.right,t.right),t.bottom=gw(r.bottom,t.bottom),t.left=yw(r.left,t.left),t}),$w(e,s,i));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}},getOffsetParent:Yw,getElementRects:async function(t){const e=this.getOffsetParent||Yw,n=this.getDimensions,r=await n(t.floating);return{reference:qw(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){const{width:e,height:n}=jw(t);return{width:e,height:n}},getScale:Bw,isElement:nw,isRTL:function(t){return"rtl"===dw(t).direction}};function Xw(t,e,n,r){void 0===r&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s="function"==typeof ResizeObserver,layoutShift:a="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,u=Iw(t),c=i||o?[...u?mw(u):[],...mw(e)]:[];c.forEach((t=>{i&&t.addEventListener("scroll",n,{passive:!0}),o&&t.addEventListener("resize",n)}));const d=u&&a?function(t,e){let n,r=null;const i=tw(t);function o(){var t;clearTimeout(n),null==(t=r)||t.disconnect(),r=null}return function s(a,l){void 0===a&&(a=!1),void 0===l&&(l=1),o();const{left:u,top:c,width:d,height:h}=t.getBoundingClientRect();if(a||e(),!d||!h)return;const p={rootMargin:-ww(c)+"px "+-ww(i.clientWidth-(u+d))+"px "+-ww(i.clientHeight-(c+h))+"px "+-ww(u)+"px",threshold:yw(0,gw(1,l))||1};let f=!0;function m(t){const e=t[0].intersectionRatio;if(e!==l){if(!f)return s();e?s(!1,e):n=setTimeout((()=>{s(!1,1e-7)}),1e3)}f=!1}try{r=new IntersectionObserver(m,{...p,root:i.ownerDocument})}catch(yy){r=new IntersectionObserver(m,p)}r.observe(t)}(!0),o}(u,n):null;let h,p=-1,f=null;s&&(f=new ResizeObserver((t=>{let[r]=t;r&&r.target===u&&f&&(f.unobserve(e),cancelAnimationFrame(p),p=requestAnimationFrame((()=>{var t;null==(t=f)||t.observe(e)}))),n()})),u&&!l&&f.observe(u),f.observe(e));let m=l?Ww(t):null;return l&&function e(){const r=Ww(t);!m||r.x===m.x&&r.y===m.y&&r.width===m.width&&r.height===m.height||n();m=r,h=requestAnimationFrame(e)}(),n(),()=>{var t;c.forEach((t=>{i&&t.removeEventListener("scroll",n),o&&t.removeEventListener("resize",n)})),null==d||d(),null==(t=f)||t.disconnect(),f=null,l&&cancelAnimationFrame(h)}}const Zw=Vw,Jw=function(t){return void 0===t&&(t=0),{name:"offset",options:t,async fn(e){var n,r;const{x:i,y:o,placement:s,middlewareData:a}=e,l=await async function(t,e){const{placement:n,platform:r,elements:i}=t,o=await(null==r.isRTL?void 0:r.isRTL(i.floating)),s=Pw(n),a=Tw(n),l="y"===Rw(n),u=["left","top"].includes(s)?-1:1,c=o&&l?-1:1,d=kw(e,t);let{mainAxis:h,crossAxis:p,alignmentAxis:f}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&"number"==typeof f&&(p="end"===a?-1*f:f),l?{x:p*c,y:h*u}:{x:h*u,y:p*c}}(e,t);return s===(null==(n=a.offset)?void 0:n.placement)&&null!=(r=a.arrow)&&r.alignmentOffset?{}:{x:i+l.x,y:o+l.y,data:{...l,placement:s}}}}},tx=function(t){return void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:r,placement:i}=e,{mainAxis:o=!0,crossAxis:s=!1,limiter:a={fn:t=>{let{x:e,y:n}=t;return{x:e,y:n}}},...l}=kw(t,e),u={x:n,y:r},c=await Vw(e,l),d=Rw(Pw(i)),h=Cw(d);let p=u[h],f=u[d];if(o){const t="y"===h?"bottom":"right";p=Ew(p+c["y"===h?"top":"left"],p,p-c[t])}if(s){const t="y"===d?"bottom":"right";f=Ew(f+c["y"===d?"top":"left"],f,f-c[t])}const m=a.fn({...e,[h]:p,[d]:f});return{...m,data:{x:m.x-n,y:m.y-r,enabled:{[h]:o,[d]:s}}}}}},ex=function(t){return void 0===t&&(t={}),{name:"flip",options:t,async fn(e){var n,r;const{placement:i,middlewareData:o,rects:s,initialPlacement:a,platform:l,elements:u}=e,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:m=!0,...v}=kw(t,e);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const g=Pw(i),y=Rw(a),b=Pw(a)===a,w=await(null==l.isRTL?void 0:l.isRTL(u.floating)),x=h||(b||!m?[Lw(a)]:function(t){const e=Lw(t);return[Fw(t),e,Fw(e)]}(a)),_="none"!==f;!h&&_&&x.push(...function(t,e,n,r){const i=Tw(t);let o=function(t,e,n){const r=["left","right"],i=["right","left"],o=["top","bottom"],s=["bottom","top"];switch(t){case"top":case"bottom":return n?e?i:r:e?r:i;case"left":case"right":return e?o:s;default:return[]}}(Pw(t),"start"===n,r);return i&&(o=o.map((t=>t+"-"+i)),e&&(o=o.concat(o.map(Fw)))),o}(a,m,f,w));const S=[a,...x],E=await Vw(e,v),k=[];let P=(null==(r=o.flip)?void 0:r.overflows)||[];if(c&&k.push(E[g]),d){const t=function(t,e,n){void 0===n&&(n=!1);const r=Tw(t),i=Ow(t),o=Aw(i);let s="x"===i?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return e.reference[o]>e.floating[o]&&(s=Lw(s)),[s,Lw(s)]}(i,s,w);k.push(E[t[0]],E[t[1]])}if(P=[...P,{placement:i,overflows:k}],!k.every((t=>t<=0))){var T,C;const t=((null==(T=o.flip)?void 0:T.index)||0)+1,e=S[t];if(e)return{data:{index:t,overflows:P},reset:{placement:e}};let n=null==(C=P.filter((t=>t.overflows[0]<=0)).sort(((t,e)=>t.overflows[1]-e.overflows[1]))[0])?void 0:C.placement;if(!n)switch(p){case"bestFit":{var A;const t=null==(A=P.filter((t=>{if(_){const e=Rw(t.placement);return e===y||"y"===e}return!0})).map((t=>[t.placement,t.overflows.filter((t=>t>0)).reduce(((t,e)=>t+e),0)])).sort(((t,e)=>t[1]-e[1]))[0])?void 0:A[0];t&&(n=t);break}case"initialPlacement":n=a}if(i!==n)return{reset:{placement:n}}}return{}}}},nx=function(t){return void 0===t&&(t={}),{name:"size",options:t,async fn(e){var n,r;const{placement:i,rects:o,platform:s,elements:a}=e,{apply:l=()=>{},...u}=kw(t,e),c=await Vw(e,u),d=Pw(i),h=Tw(i),p="y"===Rw(i),{width:f,height:m}=o.floating;let v,g;"top"===d||"bottom"===d?(v=d,g=h===(await(null==s.isRTL?void 0:s.isRTL(a.floating))?"start":"end")?"left":"right"):(g=d,v="end"===h?"top":"bottom");const y=m-c.top-c.bottom,b=f-c.left-c.right,w=gw(m-c[v],y),x=gw(f-c[g],b),_=!e.middlewareData.shift;let S=w,E=x;if(null!=(n=e.middlewareData.shift)&&n.enabled.x&&(E=b),null!=(r=e.middlewareData.shift)&&r.enabled.y&&(S=y),_&&!h){const t=yw(c.left,0),e=yw(c.right,0),n=yw(c.top,0),r=yw(c.bottom,0);p?E=f-2*(0!==t||0!==e?t+e:yw(c.left,c.right)):S=m-2*(0!==n||0!==r?n+r:yw(c.top,c.bottom))}await l({...e,availableWidth:E,availableHeight:S});const k=await s.getDimensions(a.floating);return f!==k.width||m!==k.height?{reset:{rects:!0}}:{}}}},rx=(t,e,n)=>{const r=new Map,i={platform:Qw,...n},o={...i.platform,_c:r};return(async(t,e,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:s}=n,a=o.filter(Boolean),l=await(null==s.isRTL?void 0:s.isRTL(e));let u=await s.getElementRects({reference:t,floating:e,strategy:i}),{x:c,y:d}=Dw(u,r,l),h=r,p={},f=0;for(let m=0;m<a.length;m++){const{name:n,fn:o}=a[m],{x:v,y:g,data:y,reset:b}=await o({x:c,y:d,initialPlacement:r,placement:h,strategy:i,middlewareData:p,rects:u,platform:s,elements:{reference:t,floating:e}});c=null!=v?v:c,d=null!=g?g:d,p={...p,[n]:{...p[n],...y}},b&&f<=50&&(f++,"object"==typeof b&&(b.placement&&(h=b.placement),b.rects&&(u=!0===b.rects?await s.getElementRects({reference:t,floating:e,strategy:i}):b.rects),({x:c,y:d}=Dw(u,h,l))),m=-1)}return{x:c,y:d,placement:h,strategy:i,middlewareData:p}})(t,e,{...i,platform:o})};var ix="undefined"!=typeof document?Hn:Wn;function ox(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if("function"==typeof t&&t.toString()===e.toString())return!0;let n,r,i;if(t&&e&&"object"==typeof t){if(Array.isArray(t)){if(n=t.length,n!==e.length)return!1;for(r=n;0!=r--;)if(!ox(t[r],e[r]))return!1;return!0}if(i=Object.keys(t),n=i.length,n!==Object.keys(e).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(e,i[r]))return!1;for(r=n;0!=r--;){const n=i[r];if(("_owner"!==n||!t.$$typeof)&&!ox(t[n],e[n]))return!1}return!0}return t!=t&&e!=e}function sx(t){if("undefined"==typeof window)return 1;return(t.ownerDocument.defaultView||window).devicePixelRatio||1}function ax(t,e){const n=sx(t);return Math.round(e*n)/n}function lx(t){const e=$n(t);return ix((()=>{e.current=t})),e}const ux=(t,e)=>({...Jw(t),options:[t,e]}),cx=(t,e)=>({...tx(t),options:[t,e]}),dx=(t,e)=>({...ex(t),options:[t,e]}),hx=(t,e)=>({...nx(t),options:[t,e]}),px={...ai},fx=px.useInsertionEffect||(t=>t());function mx(t){const e=$n((()=>{}));return fx((()=>{e.current=t})),Kn((function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return null==e.current?void 0:e.current(...n)}),[])}var vx="undefined"!=typeof document?Hn:Wn;let gx=!1,yx=0;const bx=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+yx++;const wx=px.useId||function(){const[t,e]=Nn((()=>gx?bx():void 0));return vx((()=>{null==t&&e(bx())}),[]),Wn((()=>{gx=!0}),[]),t};const xx=fe(null),_x=fe(null),Sx=()=>{var t;return(null==(t=Gn(xx))?void 0:t.id)||null},Ex=()=>Gn(_x),kx="data-floating-ui-focusable";function Px(t){const{open:e=!1,onOpenChange:n,elements:r}=t,i=wx(),o=$n({}),[s]=Nn((()=>function(){const t=new Map;return{emit(e,n){var r;null==(r=t.get(e))||r.forEach((t=>t(n)))},on(e,n){t.set(e,[...t.get(e)||[],n])},off(e,n){var r;t.set(e,(null==(r=t.get(e))?void 0:r.filter((t=>t!==n)))||[])}}}())),a=null!=Sx(),[l,u]=Nn(r.reference),c=mx(((t,e,r)=>{o.current.openEvent=t?e:void 0,s.emit("openchange",{open:t,event:e,reason:r,nested:a}),null==n||n(t,e,r)})),d=qn((()=>({setPositionReference:u})),[]),h=qn((()=>({reference:l||r.reference||null,floating:r.floating||null,domReference:r.reference})),[l,r.reference,r.floating]);return qn((()=>({dataRef:o,open:e,onOpenChange:c,elements:h,events:s,floatingId:i,refs:d})),[e,c,h,s,i,d])}function Tx(t){void 0===t&&(t={});const{nodeId:e}=t,n=Px({...t,elements:{reference:null,floating:null,...t.elements}}),r=t.rootContext||n,i=r.elements,[o,s]=Nn(null),[a,l]=Nn(null),u=(null==i?void 0:i.reference)||o,c=$n(null),d=Ex();vx((()=>{u&&(c.current=u)}),[u]);const h=function(t){void 0===t&&(t={});const{placement:e="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:a=!0,whileElementsMounted:l,open:u}=t,[c,d]=Nn({x:0,y:0,strategy:n,placement:e,middlewareData:{},isPositioned:!1}),[h,p]=Nn(r);ox(h,r)||p(r);const[f,m]=Nn(null),[v,g]=Nn(null),y=Kn((t=>{t!==_.current&&(_.current=t,m(t))}),[]),b=Kn((t=>{t!==S.current&&(S.current=t,g(t))}),[]),w=o||f,x=s||v,_=$n(null),S=$n(null),E=$n(c),k=null!=l,P=lx(l),T=lx(i),C=lx(u),A=Kn((()=>{if(!_.current||!S.current)return;const t={placement:e,strategy:n,middleware:h};T.current&&(t.platform=T.current),rx(_.current,S.current,t).then((t=>{const e={...t,isPositioned:!1!==C.current};R.current&&!ox(E.current,e)&&(E.current=e,Xr((()=>{d(e)})))}))}),[h,e,n,T,C]);ix((()=>{!1===u&&E.current.isPositioned&&(E.current.isPositioned=!1,d((t=>({...t,isPositioned:!1}))))}),[u]);const R=$n(!1);ix((()=>(R.current=!0,()=>{R.current=!1})),[]),ix((()=>{if(w&&(_.current=w),x&&(S.current=x),w&&x){if(P.current)return P.current(w,x,A);A()}}),[w,x,A,P,k]);const O=qn((()=>({reference:_,floating:S,setReference:y,setFloating:b})),[y,b]),F=qn((()=>({reference:w,floating:x})),[w,x]),L=qn((()=>{const t={position:n,left:0,top:0};if(!F.floating)return t;const e=ax(F.floating,c.x),r=ax(F.floating,c.y);return a?{...t,transform:"translate("+e+"px, "+r+"px)",...sx(F.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:e,top:r}}),[n,a,F.floating,c.x,c.y]);return qn((()=>({...c,update:A,refs:O,elements:F,floatingStyles:L})),[c,A,O,F,L])}({...t,elements:{...i,...a&&{reference:a}}}),p=Kn((t=>{const e=nw(t)?{getBoundingClientRect:()=>t.getBoundingClientRect(),contextElement:t}:t;l(e),h.refs.setReference(e)}),[h.refs]),f=Kn((t=>{(nw(t)||null===t)&&(c.current=t,s(t)),(nw(h.refs.reference.current)||null===h.refs.reference.current||null!==t&&!nw(t))&&h.refs.setReference(t)}),[h.refs]),m=qn((()=>({...h.refs,setReference:f,setPositionReference:p,domReference:c})),[h.refs,f,p]),v=qn((()=>({...h.elements,domReference:u})),[h.elements,u]),g=qn((()=>({...h,...r,refs:m,elements:v,nodeId:e})),[h,m,v,e,r]);return vx((()=>{r.dataRef.current.floatingContext=g;const t=null==d?void 0:d.nodesRef.current.find((t=>t.id===e));t&&(t.context=g)})),qn((()=>({...h,context:g,refs:m,elements:v})),[h,m,v,g])}const Cx="active",Ax="selected";function Rx(t,e,n){const r=new Map,i="item"===n;let o=t;if(i&&t){const{[Cx]:e,[Ax]:n,...r}=t;o=r}return{..."floating"===n&&{tabIndex:-1,[kx]:""},...o,...e.map((e=>{const r=e?e[n]:null;return"function"==typeof r?t?r(t):null:r})).concat(t).reduce(((t,e)=>e?(Object.entries(e).forEach((e=>{let[n,o]=e;var s;i&&[Cx,Ax].includes(n)||(0===n.indexOf("on")?(r.has(n)||r.set(n,[]),"function"==typeof o&&(null==(s=r.get(n))||s.push(o),t[n]=function(){for(var t,e=arguments.length,i=new Array(e),o=0;o<e;o++)i[o]=arguments[o];return null==(t=r.get(n))?void 0:t.map((t=>t(...i))).find((t=>void 0!==t))})):t[n]=o)})),t):t),{})}}function Ox(t,e){return{...t,rects:{...t.rects,floating:{...t.rects.floating,height:e}}}}const Fx=t=>({name:"inner",options:t,async fn(e){const{listRef:n,overflowRef:r,onFallbackChange:i,offset:o=0,index:s=0,minItemsVisible:a=4,referenceOverflowThreshold:l=0,scrollRef:u,...c}=kw(t,e),{rects:d,elements:{floating:h}}=e,p=n.current[s],f=(null==u?void 0:u.current)||h,m=h.clientTop||f.clientTop,v=0!==h.clientTop,g=0!==f.clientTop,y=h===f;if(!p)return{};const b={...e,...await ux(-p.offsetTop-h.clientTop-d.reference.height/2-p.offsetHeight/2-o).fn(e)},w=await Zw(Ox(b,f.scrollHeight+m+h.clientTop),c),x=await Zw(b,{...c,elementContext:"reference"}),_=yw(0,w.top),S=b.y+_,E=bw(yw(0,f.scrollHeight+(v&&y||g?2*m:0)-_-yw(0,w.bottom)));if(f.style.maxHeight=E+"px",f.scrollTop=_,i){const t=f.scrollHeight>f.offsetHeight&&f.offsetHeight<p.offsetHeight*a-1||x.top>=-l||x.bottom>=-l;Xr((()=>i(t)))}return r&&(r.current=await Zw(Ox({...b,y:S},f.offsetHeight+m+h.clientTop),c)),{y:S}}});function Lx(t,e){const{open:n,elements:r}=t,{enabled:i=!0,overflowRef:o,scrollRef:s,onChange:a}=e,l=mx(a),u=$n(!1),c=$n(null),d=$n(null);Wn((()=>{if(!i)return;function t(t){if(t.ctrlKey||!e||null==o.current)return;const n=t.deltaY,r=o.current.top>=-.5,i=o.current.bottom>=-.5,s=e.scrollHeight-e.clientHeight,a=n<0?-1:1,u=n<0?"max":"min";e.scrollHeight<=e.clientHeight||(!r&&n>0||!i&&n<0?(t.preventDefault(),Xr((()=>{l((t=>t+Math[u](n,s*a)))}))):/firefox/i.test(function(){const t=navigator.userAgentData;return t&&Array.isArray(t.brands)?t.brands.map((t=>{let{brand:e,version:n}=t;return e+"/"+n})).join(" "):navigator.userAgent}())&&(e.scrollTop+=n))}const e=(null==s?void 0:s.current)||r.floating;return n&&e?(e.addEventListener("wheel",t),requestAnimationFrame((()=>{c.current=e.scrollTop,null!=o.current&&(d.current={...o.current})})),()=>{c.current=null,d.current=null,e.removeEventListener("wheel",t)}):void 0}),[i,n,r.floating,o,s,l]);const h=qn((()=>({onKeyDown(){u.current=!0},onWheel(){u.current=!1},onPointerMove(){u.current=!1},onScroll(){const t=(null==s?void 0:s.current)||r.floating;if(o.current&&t&&u.current){if(null!==c.current){const e=t.scrollTop-c.current;(o.current.bottom<-.5&&e<-1||o.current.top<-.5&&e>1)&&Xr((()=>l((t=>t+e))))}requestAnimationFrame((()=>{c.current=t.scrollTop}))}}})),[r.floating,l,o,s]);return qn((()=>i?{floating:h}:{}),[i,h])}let Mx=fe({styles:void 0,setReference:()=>{},setFloating:()=>{},getReferenceProps:()=>({}),getFloatingProps:()=>({}),slot:{}});Mx.displayName="FloatingContext";let Dx=fe(null);Dx.displayName="PlacementContext";let Vx=4;function jx({children:t,enabled:e=!0}){let[n,r]=Nn(null),[i,o]=Nn(0),s=$n(null),[a,l]=Nn(null);!function(t){uy((()=>{if(!t)return;let e=new MutationObserver((()=>{let e=window.getComputedStyle(t).maxHeight,n=parseFloat(e);if(isNaN(n))return;let r=parseInt(e);isNaN(r)||n!==r&&(t.style.maxHeight=`${Math.ceil(n)}px`)}));return e.observe(t,{attributes:!0,attributeFilter:["style"]}),()=>{e.disconnect()}}),[t])}(a);let u=e&&null!==n&&null!==a,{to:c="bottom",gap:d=0,offset:h=0,padding:p=0,inner:f}=function(t,e){var n,r,i;let o=Ix(null!=(n=null==t?void 0:t.gap)?n:"var(--anchor-gap, 0)",e),s=Ix(null!=(r=null==t?void 0:t.offset)?r:"var(--anchor-offset, 0)",e),a=Ix(null!=(i=null==t?void 0:t.padding)?i:"var(--anchor-padding, 0)",e);return{...t,gap:o,offset:s,padding:a}}(n,a),[m,v="center"]=c.split(" ");uy((()=>{u&&o(0)}),[u]);let{refs:g,floatingStyles:y,context:b}=Tx({open:u,placement:"selection"===m?"center"===v?"bottom":`bottom-${v}`:"center"===v?`${m}`:`${m}-${v}`,strategy:"absolute",transform:!1,middleware:[ux({mainAxis:"selection"===m?0:d,crossAxis:h}),cx({padding:p}),"selection"!==m&&dx({padding:p}),"selection"===m&&f?Fx({...f,padding:p,overflowRef:s,offset:i,minItemsVisible:Vx,referenceOverflowThreshold:p,onFallbackChange(t){var e,n;if(!t)return;let r=b.elements.floating;if(!r)return;let i=parseFloat(getComputedStyle(r).scrollPaddingBottom)||0,s=Math.min(Vx,r.childElementCount),a=0,l=0;for(let o of null!=(n=null==(e=b.elements.floating)?void 0:e.childNodes)?n:[])if(o instanceof HTMLElement){let t=o.offsetTop,e=t+o.clientHeight+i,n=r.scrollTop,u=n+r.clientHeight;if(!(t>=n&&e<=u)){l=Math.max(0,Math.min(e,u)-Math.max(t,n)),a=o.clientHeight;break}s--}s>=1&&o((t=>{let e=a*s-l+i;return t>=e?t:e}))}}):null,hx({padding:p,apply({availableWidth:t,availableHeight:e,elements:n}){Object.assign(n.floating.style,{overflow:"auto",maxWidth:`${t}px`,maxHeight:`min(var(--anchor-max-height, 100vh), ${e}px)`})}})].filter(Boolean),whileElementsMounted:Xw}),[w=m,x=v]=b.placement.split("-");"selection"===m&&(w="selection");let _=qn((()=>({anchor:[w,x].filter(Boolean).join(" ")})),[w,x]),S=Lx(b,{overflowRef:s,onChange:o}),{getReferenceProps:E,getFloatingProps:k}=function(t){void 0===t&&(t=[]);const e=t.map((t=>null==t?void 0:t.reference)),n=t.map((t=>null==t?void 0:t.floating)),r=t.map((t=>null==t?void 0:t.item)),i=Kn((e=>Rx(e,t,"reference")),e),o=Kn((e=>Rx(e,t,"floating")),n),s=Kn((e=>Rx(e,t,"item")),r);return qn((()=>({getReferenceProps:i,getFloatingProps:o,getItemProps:s})),[i,o,s])}([S]),P=dy((t=>{l(t),g.setFloating(t)}));return $t(Dx.Provider,{value:r},$t(Mx.Provider,{value:{setFloating:P,setReference:g.setReference,styles:y,getReferenceProps:E,getFloatingProps:k,slot:_}},t))}function Ix(t,e,n=void 0){let r=ly(),i=dy(((t,e)=>{if(null==t)return[n,null];if("number"==typeof t)return[t,null];if("string"==typeof t){if(!e)return[n,null];let i=Nx(t,e);return[i,n=>{let o=Bx(t);{let s=o.map((t=>window.getComputedStyle(e).getPropertyValue(t)));r.requestAnimationFrame((function a(){r.nextFrame(a);let l=!1;for(let[t,n]of o.entries()){let r=window.getComputedStyle(e).getPropertyValue(n);if(s[t]!==r){s[t]=r,l=!0;break}}if(!l)return;let u=Nx(t,e);i!==u&&(n(u),i=u)}))}return r.dispose}]}return[n,null]})),o=qn((()=>i(t,e)[0]),[t,e]),[s=o,a]=Nn();return uy((()=>{let[n,r]=i(t,e);if(a(n),r)return r(a)}),[t,e]),s}function Bx(t){let e=/var\((.*)\)/.exec(t);if(e){let t=e[1].indexOf(",");if(-1===t)return[e[1]];let n=e[1].slice(0,t).trim(),r=e[1].slice(t+1).trim();return r?[n,...Bx(r)]:[n]}return[]}function Nx(t,e){let n=document.createElement("div");e.appendChild(n),n.style.setProperty("margin-top","0px","important"),n.style.setProperty("margin-top",t,"important");let r=parseFloat(window.getComputedStyle(n).marginTop)||0;return e.removeChild(n),r}let Ux=fe(null);Ux.displayName="OpenClosedContext";var Wx=(t=>(t[t.Open=1]="Open",t[t.Closed=2]="Closed",t[t.Closing=4]="Closing",t[t.Opening=8]="Opening",t))(Wx||{});function Hx(){return Gn(Ux)}function $x({value:t,children:e}){return si.createElement(Ux.Provider,{value:t},e)}var zx,qx=((zx=qx||{})[zx.First=0]="First",zx[zx.Previous=1]="Previous",zx[zx.Next=2]="Next",zx[zx.Last=3]="Last",zx[zx.Specific=4]="Specific",zx[zx.Nothing=5]="Nothing",zx);function Kx(t,e){let n=e.resolveItems();if(n.length<=0)return null;let r=e.resolveActiveIndex(),i=null!=r?r:-1;switch(t.focus){case 0:for(let t=0;t<n.length;++t)if(!e.resolveDisabled(n[t],t,n))return t;return r;case 1:-1===i&&(i=n.length);for(let t=i-1;t>=0;--t)if(!e.resolveDisabled(n[t],t,n))return t;return r;case 2:for(let t=i+1;t<n.length;++t)if(!e.resolveDisabled(n[t],t,n))return t;return r;case 3:for(let t=n.length-1;t>=0;--t)if(!e.resolveDisabled(n[t],t,n))return t;return r;case 4:for(let r=0;r<n.length;++r)if(e.resolveId(n[r],r,n)===t.id)return r;return r;case 5:return null;default:!function(t){throw new Error("Unexpected object: "+t)}(t)}}function Gx(){let t=function(){let t="undefined"==typeof document;return"useSyncExternalStore"in ai&&ai.useSyncExternalStore((()=>()=>{}),(()=>!1),(()=>!t))}(),[e,n]=Nn(iy.isHandoffComplete);return e&&!1===iy.isHandoffComplete&&n(!1),Wn((()=>{!0!==e&&n(!0)}),[e]),Wn((()=>iy.handoff()),[]),!t&&e}let Yx=fe(!1);function Qx(t){let e=Gn(Yx),n=Gn(t_),r=Nb(t),[i,o]=Nn((()=>{var t;if(!e&&null!==n)return null!=(t=n.current)?t:null;if(iy.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 Wn((()=>{null!==i&&(null!=r&&r.body.contains(i)||null==r||r.body.appendChild(i))}),[i,r]),Wn((()=>{e||null!==n&&o(n.current)}),[n,o,e]),i}let Xx=Kt,Zx=Ty((function(t,e){let n=t,r=$n(null),i=Gy(function(t,e=!0){return Object.assign(t,{[Ky]:e})}((t=>{r.current=t})),e),o=Nb(r),s=Qx(r),[a]=Nn((()=>{var t;return iy.isServer?null:null!=(t=null==o?void 0:o.createElement("div"))?t:null})),l=Gn(e_),u=Gx();return uy((()=>{!s||!a||s.contains(a)||(a.setAttribute("data-headlessui-portal",""),s.appendChild(a))}),[s,a]),uy((()=>{if(a&&l)return l.register(a)}),[l,a]),function(t){let e=dy(t),n=$n(!1);Wn((()=>(n.current=!1,()=>{n.current=!0,sy((()=>{n.current&&e()}))})),[e])}((()=>{var t;!s||!a||(a instanceof Node&&s.contains(a)&&s.removeChild(a),s.childNodes.length<=0&&(null==(t=s.parentElement)||t.removeChild(s)))})),u&&s&&a?Er(_y({ourProps:{ref:i},theirProps:n,slot:{},defaultTag:Xx,name:"Portal"}),a):null}));let Jx=Kt,t_=fe(null);let e_=fe(null),n_=Ty((function(t,e){let n=Gy(e),{enabled:r=!0,...i}=t;return r?si.createElement(Zx,{...i,ref:n}):_y({ourProps:{ref:n},theirProps:i,slot:{},defaultTag:Xx,name:"Portal"})})),r_=Ty((function(t,e){let{target:n,...r}=t,i={ref:Gy(e)};return si.createElement(t_.Provider,{value:n},_y({ourProps:i,theirProps:r,defaultTag:Jx,name:"Popover.Group"}))})),i_=Object.assign(n_,{Group:r_});function o_(t){var e;return!!(t.enter||t.enterFrom||t.enterTo||t.leave||t.leaveFrom||t.leaveTo)||(null!=(e=t.as)?e:d_)!==Kt||1===si.Children.count(t.children)}let s_=fe(null);s_.displayName="TransitionContext";var a_=(t=>(t.Visible="visible",t.Hidden="hidden",t))(a_||{});let l_=fe(null);function u_(t){return"children"in t?u_(t.children):t.current.filter((({el:t})=>null!==t.current)).filter((({state:t})=>"visible"===t)).length>0}function c_(t,e){let n=cy(t),r=$n([]),i=function(){let t=$n(!1);return uy((()=>(t.current=!0,()=>{t.current=!1})),[]),t}(),o=ly(),s=dy(((t,e=xy.Hidden)=>{let s=r.current.findIndex((({el:e})=>e===t));-1!==s&&(gy(e,{[xy.Unmount](){r.current.splice(s,1)},[xy.Hidden](){r.current[s].state="hidden"}}),o.microTask((()=>{var t;!u_(r)&&i.current&&(null==(t=n.current)||t.call(n))})))})),a=dy((t=>{let e=r.current.find((({el:e})=>e===t));return e?"visible"!==e.state&&(e.state="visible"):r.current.push({el:t,state:"visible"}),()=>s(t,xy.Unmount)})),l=$n([]),u=$n(Promise.resolve()),c=$n({enter:[],leave:[]}),d=dy(((t,n,r)=>{l.current.splice(0),e&&(e.chains.current[n]=e.chains.current[n].filter((([e])=>e!==t))),null==e||e.chains.current[n].push([t,new Promise((t=>{l.current.push(t)}))]),null==e||e.chains.current[n].push([t,new Promise((t=>{Promise.all(c.current[n].map((([t,e])=>e))).then((()=>t()))}))]),"enter"===n?u.current=u.current.then((()=>null==e?void 0:e.wait.current)).then((()=>r(n))):r(n)})),h=dy(((t,e,n)=>{Promise.all(c.current[e].splice(0).map((([t,e])=>e))).then((()=>{var t;null==(t=l.current.shift())||t()})).then((()=>n(e)))}));return qn((()=>({children:r,register:a,unregister:s,onStart:d,onStop:h,wait:u,chains:c})),[a,s,r,d,h,c,u])}l_.displayName="NestingContext";let d_=Kt,h_=wy.RenderStrategy;let p_=Ty((function(t,e){let{show:n,appear:r=!1,unmount:i=!0,...o}=t,s=$n(null),a=Gy(...o_(t)?[s,e]:null===e?[]:[e]);Gx();let l=Hx();if(void 0===n&&null!==l&&(n=(l&Wx.Open)===Wx.Open),void 0===n)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[u,c]=Nn(n?"visible":"hidden"),d=c_((()=>{n||c("hidden")})),[h,p]=Nn(!0),f=$n([n]);uy((()=>{!1!==h&&f.current[f.current.length-1]!==n&&(f.current.push(n),p(!1))}),[f,n]);let m=qn((()=>({show:n,appear:r,initial:h})),[n,r,h]);uy((()=>{n?c("visible"):!u_(d)&&null!==s.current&&c("hidden")}),[n,d]);let v={unmount:i},g=dy((()=>{var e;h&&p(!1),null==(e=t.beforeEnter)||e.call(t)})),y=dy((()=>{var e;h&&p(!1),null==(e=t.beforeLeave)||e.call(t)}));return si.createElement(l_.Provider,{value:d},si.createElement(s_.Provider,{value:m},_y({ourProps:{...v,as:Kt,children:si.createElement(f_,{ref:a,...v,...o,beforeEnter:g,beforeLeave:y})},theirProps:{},defaultTag:Kt,features:h_,visible:"visible"===u,name:"Transition"})))})),f_=Ty((function(t,e){var n,r;let{transition:i=!0,beforeEnter:o,afterEnter:s,beforeLeave:a,afterLeave:l,enter:u,enterFrom:c,enterTo:d,entered:h,leave:p,leaveFrom:f,leaveTo:m,...v}=t,[g,y]=Nn(null),b=$n(null),w=o_(t),x=Gy(...w?[b,e,y]:null===e?[]:[e]),_=null==(n=v.unmount)||n?xy.Unmount:xy.Hidden,{show:S,appear:E,initial:k}=function(){let t=Gn(s_);if(null===t)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return t}(),[P,T]=Nn(S?"visible":"hidden"),C=function(){let t=Gn(l_);if(null===t)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return t}(),{register:A,unregister:R}=C;uy((()=>A(b)),[A,b]),uy((()=>{if(_===xy.Hidden&&b.current)return S&&"visible"!==P?void T("visible"):gy(P,{hidden:()=>R(b),visible:()=>A(b)})}),[P,b,A,R,S,_]);let O=Gx();uy((()=>{if(w&&O&&"visible"===P&&null===b.current)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")}),[b,P,O,w]);let F=k&&!E,L=E&&S&&k,M=$n(!1),D=c_((()=>{M.current||(T("hidden"),R(b))}),C),V=dy((t=>{M.current=!0;let e=t?"enter":"leave";D.onStart(b,e,(t=>{"enter"===t?null==o||o():"leave"===t&&(null==a||a())}))})),j=dy((t=>{let e=t?"enter":"leave";M.current=!1,D.onStop(b,e,(t=>{"enter"===t?null==s||s():"leave"===t&&(null==l||l())})),"leave"===e&&!u_(D)&&(T("hidden"),R(b))}));Wn((()=>{w&&i||(V(S),j(S))}),[S,w,i]);let I=(()=>!(!i||!w||!O||F))(),[,B]=Qb(I,g,S,{start:V,end:j}),N=Cy({ref:x,className:(null==(r=vy(v.className,L&&u,L&&c,B.enter&&u,B.enter&&B.closed&&c,B.enter&&!B.closed&&d,B.leave&&p,B.leave&&!B.closed&&f,B.leave&&B.closed&&m,!B.transition&&S&&h))?void 0:r.trim())||void 0,...Yb(B)}),U=0;return"visible"===P&&(U|=Wx.Open),"hidden"===P&&(U|=Wx.Closed),B.enter&&(U|=Wx.Opening),B.leave&&(U|=Wx.Closing),si.createElement(l_.Provider,{value:D},si.createElement($x,{value:U},_y({ourProps:N,theirProps:v,defaultTag:d_,features:h_,visible:"visible"===P,name:"Transition.Child"})))})),m_=Ty((function(t,e){let n=null!==Gn(s_),r=null!==Hx();return si.createElement(si.Fragment,null,!n&&r?si.createElement(p_,{ref:e,...t}):si.createElement(f_,{ref:e,...t}))})),v_=Object.assign(p_,{Child:m_,Root:p_});let g_=Ty((function(t,e){let n=`headlessui-control-${Qn()}`,[r,i]=sb(),[o,s]=Zy(),a=fy(),{disabled:l=a||!1,...u}=t,c=qn((()=>({disabled:l})),[l]);return si.createElement(my,{value:l},si.createElement(i,{value:r},si.createElement(s,{value:o},si.createElement(zy,{id:n},_y({ourProps:{ref:e,disabled:l||void 0,"aria-disabled":l||void 0},theirProps:{...u,children:si.createElement(By,null,"function"==typeof u.children?u.children(c):u.children)},slot:c,defaultTag:"div",name:"Field"})))))}));let y_=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;function b_(t){var e,n;let r=null!=(e=t.innerText)?e:"",i=t.cloneNode(!0);if(!(i instanceof HTMLElement))return r;let o=!1;for(let a of i.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))a.remove(),o=!0;let s=o?null!=(n=i.innerText)?n:"":r;return y_.test(s)&&(s=s.replace(y_,"")),s}function w_(t){let e=$n(""),n=$n("");return dy((()=>{let r=t.current;if(!r)return"";let i=r.innerText;if(e.current===i)return n.current;let o=function(t){let e=t.getAttribute("aria-label");if("string"==typeof e)return e.trim();let n=t.getAttribute("aria-labelledby");if(n){let t=n.split(" ").map((t=>{let e=document.getElementById(t);if(e){let t=e.getAttribute("aria-label");return"string"==typeof t?t.trim():b_(e).trim()}return null})).filter(Boolean);if(t.length>0)return t.join(", ")}return b_(t).trim()}(r).trim().toLowerCase();return e.current=i,n.current=o,o}))}var x_=(t=>(t[t.Open=0]="Open",t[t.Closed=1]="Closed",t))(x_||{}),__=(t=>(t[t.Single=0]="Single",t[t.Multi=1]="Multi",t))(__||{}),S_=(t=>(t[t.Pointer=0]="Pointer",t[t.Other=1]="Other",t))(S_||{}),E_=(t=>(t[t.OpenListbox=0]="OpenListbox",t[t.CloseListbox=1]="CloseListbox",t[t.GoToOption=2]="GoToOption",t[t.Search=3]="Search",t[t.ClearSearch=4]="ClearSearch",t[t.RegisterOption=5]="RegisterOption",t[t.UnregisterOption=6]="UnregisterOption",t[t.SetButtonElement=7]="SetButtonElement",t[t.SetOptionsElement=8]="SetOptionsElement",t))(E_||{});function k_(t,e=t=>t){let n=null!==t.activeOptionIndex?t.options[t.activeOptionIndex]:null,r=Lb(e(t.options.slice()),(t=>t.dataRef.current.domRef.current)),i=n?r.indexOf(n):null;return-1===i&&(i=null),{options:r,activeOptionIndex:i}}let P_={1:t=>t.dataRef.current.disabled||1===t.listboxState?t:{...t,activeOptionIndex:null,listboxState:1,__demoMode:!1},0(t){if(t.dataRef.current.disabled||0===t.listboxState)return t;let e=t.activeOptionIndex,{isSelected:n}=t.dataRef.current,r=t.options.findIndex((t=>n(t.dataRef.current.value)));return-1!==r&&(e=r),{...t,listboxState:0,activeOptionIndex:e,__demoMode:!1}},2(t,e){var n,r,i,o,s;if(t.dataRef.current.disabled||1===t.listboxState)return t;let a={...t,searchQuery:"",activationTrigger:null!=(n=e.trigger)?n:1,__demoMode:!1};if(e.focus===qx.Nothing)return{...a,activeOptionIndex:null};if(e.focus===qx.Specific)return{...a,activeOptionIndex:t.options.findIndex((t=>t.id===e.id))};if(e.focus===qx.Previous){let n=t.activeOptionIndex;if(null!==n){let o=t.options[n].dataRef.current.domRef,s=Kx(e,{resolveItems:()=>t.options,resolveActiveIndex:()=>t.activeOptionIndex,resolveId:t=>t.id,resolveDisabled:t=>t.dataRef.current.disabled});if(null!==s){let e=t.options[s].dataRef.current.domRef;if((null==(r=o.current)?void 0:r.previousElementSibling)===e.current||null===(null==(i=e.current)?void 0:i.previousElementSibling))return{...a,activeOptionIndex:s}}}}else if(e.focus===qx.Next){let n=t.activeOptionIndex;if(null!==n){let r=t.options[n].dataRef.current.domRef,i=Kx(e,{resolveItems:()=>t.options,resolveActiveIndex:()=>t.activeOptionIndex,resolveId:t=>t.id,resolveDisabled:t=>t.dataRef.current.disabled});if(null!==i){let e=t.options[i].dataRef.current.domRef;if((null==(o=r.current)?void 0:o.nextElementSibling)===e.current||null===(null==(s=e.current)?void 0:s.nextElementSibling))return{...a,activeOptionIndex:i}}}}let l=k_(t),u=Kx(e,{resolveItems:()=>l.options,resolveActiveIndex:()=>l.activeOptionIndex,resolveId:t=>t.id,resolveDisabled:t=>t.dataRef.current.disabled});return{...a,...l,activeOptionIndex:u}},3:(t,e)=>{if(t.dataRef.current.disabled||1===t.listboxState)return t;let n=""!==t.searchQuery?0:1,r=t.searchQuery+e.value.toLowerCase(),i=(null!==t.activeOptionIndex?t.options.slice(t.activeOptionIndex+n).concat(t.options.slice(0,t.activeOptionIndex+n)):t.options).find((t=>{var e;return!t.dataRef.current.disabled&&(null==(e=t.dataRef.current.textValue)?void 0:e.startsWith(r))})),o=i?t.options.indexOf(i):-1;return-1===o||o===t.activeOptionIndex?{...t,searchQuery:r}:{...t,searchQuery:r,activeOptionIndex:o,activationTrigger:1}},4:t=>t.dataRef.current.disabled||1===t.listboxState||""===t.searchQuery?t:{...t,searchQuery:""},5:(t,e)=>{let n={id:e.id,dataRef:e.dataRef},r=k_(t,(t=>[...t,n]));return null===t.activeOptionIndex&&t.dataRef.current.isSelected(e.dataRef.current.value)&&(r.activeOptionIndex=r.options.indexOf(n)),{...t,...r}},6:(t,e)=>{let n=k_(t,(t=>{let n=t.findIndex((t=>t.id===e.id));return-1!==n&&t.splice(n,1),t}));return{...t,...n,activationTrigger:1}},7:(t,e)=>t.buttonElement===e.element?t:{...t,buttonElement:e.element},8:(t,e)=>t.optionsElement===e.element?t:{...t,optionsElement:e.element}},T_=fe(null);function C_(t){let e=Gn(T_);if(null===e){let e=new Error(`<${t} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(e,C_),e}return e}T_.displayName="ListboxActionsContext";let A_=fe(null);function R_(t){let e=Gn(A_);if(null===e){let e=new Error(`<${t} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(e,R_),e}return e}function O_(t,e){return gy(e.type,P_,t,e)}A_.displayName="ListboxDataContext";let F_=Kt;let L_=fe(!1),M_=wy.RenderStrategy|wy.Static;let D_=Kt;let V_=Ty((function(t,e){var n;let r=fy(),{value:i,defaultValue:o,form:s,name:a,onChange:l,by:u,invalid:c=!1,disabled:d=r||!1,horizontal:h=!1,multiple:p=!1,__demoMode:f=!1,...m}=t;const v=h?"horizontal":"vertical";let g=Gy(e),y=Oy(o),[b=(p?[]:void 0),w]=Ry(i,l,y),[x,_]=Un(O_,{dataRef:{current:null},listboxState:f?0:1,options:[],searchQuery:"",activeOptionIndex:null,activationTrigger:1,optionsVisible:!1,buttonElement:null,optionsElement:null,__demoMode:f}),S=$n({static:!1,hold:!1}),E=$n(new Map),k=function(t=ub){return Kn(((e,n)=>{if("string"==typeof t){let r=t;return(null==e?void 0:e[r])===(null==n?void 0:n[r])}return t(e,n)}),[t])}(u),P=Kn((t=>gy(T.mode,{1:()=>b.some((e=>k(e,t))),0:()=>k(b,t)})),[b]),T=qn((()=>({...x,value:b,disabled:d,invalid:c,mode:p?1:0,orientation:v,compare:k,isSelected:P,optionsPropsRef:S,listRef:E})),[b,d,c,p,x,E]);uy((()=>{x.dataRef.current=T}),[T]),Bb(0===T.listboxState,[T.buttonElement,T.optionsElement],((t,e)=>{var n;_({type:1}),Rb(e,Ab.Loose)||(t.preventDefault(),null==(n=T.buttonElement)||n.focus())}));let C=qn((()=>({open:0===T.listboxState,disabled:d,invalid:c,value:b})),[T,d,b,c]),A=dy((t=>{let e=T.options.find((e=>e.id===t));e&&V(e.dataRef.current.value)})),R=dy((()=>{if(null!==T.activeOptionIndex){let{dataRef:t,id:e}=T.options[T.activeOptionIndex];V(t.current.value),_({type:2,focus:qx.Specific,id:e})}})),O=dy((()=>_({type:0}))),F=dy((()=>_({type:1}))),L=ly(),M=dy(((t,e,n)=>{L.dispose(),L.microTask((()=>t===qx.Specific?_({type:2,focus:qx.Specific,id:e,trigger:n}):_({type:2,focus:t,trigger:n})))})),D=dy(((t,e)=>(_({type:5,id:t,dataRef:e}),()=>_({type:6,id:t})))),V=dy((t=>gy(T.mode,{0:()=>null==w?void 0:w(t),1(){let e=T.value.slice(),n=e.findIndex((e=>k(e,t)));return-1===n?e.push(t):e.splice(n,1),null==w?void 0:w(e)}}))),j=dy((t=>_({type:3,value:t}))),I=dy((()=>_({type:4}))),B=dy((t=>{_({type:7,element:t})})),N=dy((t=>{_({type:8,element:t})})),U=qn((()=>({onChange:V,registerOption:D,goToOption:M,closeListbox:F,openListbox:O,selectActiveOption:R,selectOption:A,search:j,clearSearch:I,setButtonElement:B,setOptionsElement:N})),[]),[W,H]=sb({inherit:!0}),$={ref:g},z=Kn((()=>{if(void 0!==y)return null==w?void 0:w(y)}),[w,y]);return si.createElement(H,{value:W,props:{htmlFor:null==(n=T.buttonElement)?void 0:n.id},slot:{open:0===T.listboxState,disabled:d}},si.createElement(jx,null,si.createElement(T_.Provider,{value:U},si.createElement(A_.Provider,{value:T},si.createElement($x,{value:gy(T.listboxState,{0:Wx.Open,1:Wx.Closed})},null!=a&&null!=b&&si.createElement(Uy,{disabled:d,data:{[a]:b},form:s,onReset:z}),_y({ourProps:$,theirProps:m,slot:C,defaultTag:F_,name:"Listbox"}))))))})),j_=Ty((function(t,e){var n;let r=R_("Listbox.Button"),i=C_("Listbox.Button"),o=Qn(),s=$y(),{id:a=s||`headlessui-listbox-button-${o}`,disabled:l=r.disabled||!1,autoFocus:u=!1,...c}=t,d=function(){let t=$n([]),e=Kn((e=>{for(let n of t.current)null!=n&&("function"==typeof n?n(e):n.current=e)}),[]);return(...n)=>{if(!n.every((t=>null==t)))return t.current=n,e}}(),h=Gy(e,Gn(Mx).setReference,i.setButtonElement),p=Gn(Mx).getReferenceProps,f=dy((t=>{switch(t.key){case nb.Enter:Dy(t.currentTarget);break;case nb.Space:case nb.ArrowDown:t.preventDefault(),Xr((()=>i.openListbox())),r.value||i.goToOption(qx.First);break;case nb.ArrowUp:t.preventDefault(),Xr((()=>i.openListbox())),r.value||i.goToOption(qx.Last)}})),m=dy((t=>{if(t.key===nb.Space)t.preventDefault()})),v=dy((t=>{var e;if(qy(t.currentTarget))return t.preventDefault();0===r.listboxState?(Xr((()=>i.closeListbox())),null==(e=r.buttonElement)||e.focus({preventScroll:!0})):(t.preventDefault(),i.openListbox())})),g=dy((t=>t.preventDefault())),y=ob([a]),b=Xy(),{isFocusVisible:w,focusProps:x}=ey({autoFocus:u}),{isHovered:_,hoverProps:S}=ty({isDisabled:l}),{pressed:E,pressProps:k}=hy({disabled:l}),P=qn((()=>({open:0===r.listboxState,active:E||0===r.listboxState,disabled:l,invalid:r.invalid,value:r.value,hover:_,focus:w,autofocus:u})),[r.listboxState,r.value,l,_,w,E,r.invalid,u]);return _y({mergeRefs:d,ourProps:Py(p(),{ref:h,id:a,type:Ub(t,r.buttonElement),"aria-haspopup":"listbox","aria-controls":null==(n=r.optionsElement)?void 0:n.id,"aria-expanded":0===r.listboxState,"aria-labelledby":y,"aria-describedby":b,disabled:l||void 0,autoFocus:u,onKeyDown:f,onKeyUp:m,onKeyPress:g,onClick:v},x,S,k),theirProps:c,slot:P,defaultTag:"button",name:"Listbox.Button"})})),I_=lb,B_=Ty((function(t,e){var n,r;let i=Qn(),{id:o=`headlessui-listbox-options-${i}`,anchor:s,portal:a=!1,modal:l=!0,transition:u=!1,...c}=t,d=function(t){return qn((()=>t?"string"==typeof t?{to:t}:t:null),[t])}(s),[h,p]=Nn(null);d&&(a=!0);let f=R_("Listbox.Options"),m=C_("Listbox.Options"),v=Nb(f.optionsElement),g=Hx(),[y,b]=Qb(u,h,null!==g?(g&Wx.Open)===Wx.Open:0===f.listboxState);!function(t,e,n){let r=cy((t=>{let e=t.getBoundingClientRect();0===e.x&&0===e.y&&0===e.width&&0===e.height&&n()}));Wn((()=>{if(!t)return;let n=null===e?null:e instanceof HTMLElement?e:e.current;if(!n)return;let i=ay();if("undefined"!=typeof ResizeObserver){let t=new ResizeObserver((()=>r.current(n)));t.observe(n),i.add((()=>t.disconnect()))}if("undefined"!=typeof IntersectionObserver){let t=new IntersectionObserver((()=>r.current(n)));t.observe(n),i.add((()=>t.disconnect()))}return()=>i.dispose()}),[e,r,t])}(y,f.buttonElement,m.closeListbox),zb(!f.__demoMode&&(l&&0===f.listboxState),v),function(t,{allowed:e,disallowed:n}={}){let r=mb(t,"inert-others");uy((()=>{var t,i;if(!r)return;let o=ay();for(let e of null!=(t=null==n?void 0:n())?t:[])e&&o.add(yb(e));let s=null!=(i=null==e?void 0:e())?i:[];for(let e of s){if(!e)continue;let t=oy(e);if(!t)continue;let n=e.parentElement;for(;n&&n!==t.body;){for(let t of n.children)s.some((e=>t.contains(e)))||o.add(yb(t));n=n.parentElement}}return o.dispose}),[r,e,n])}(!f.__demoMode&&(l&&0===f.listboxState),{allowed:Kn((()=>[f.buttonElement,f.optionsElement]),[f.buttonElement,f.optionsElement])});let w=!function(t,e){let n=$n({left:0,top:0});if(uy((()=>{if(!e)return;let t=e.getBoundingClientRect();t&&(n.current=t)}),[t,e]),null==e||!t||e===document.activeElement)return!1;let r=e.getBoundingClientRect();return r.top!==n.current.top||r.left!==n.current.left}(0!==f.listboxState,f.buttonElement)&&y,x=function(t,e){let[n,r]=Nn(e);return!t&&n!==e&&r(e),t?n:e}(y&&1===f.listboxState,f.value),_=dy((t=>f.compare(x,t))),S=qn((()=>{var t;if(null==d||null==(t=null==d?void 0:d.to)||!t.includes("selection"))return null;let e=f.options.findIndex((t=>_(t.dataRef.current.value)));return-1===e&&(e=0),e}),[d,f.options]),E=(()=>{if(null==d)return;if(null===S)return{...d,inner:void 0};let t=Array.from(f.listRef.current.values());return{...d,inner:{listRef:{current:t},index:S}}})(),[k,P]=function(t=null){!1===t&&(t=null),"string"==typeof t&&(t={to:t});let e=Gn(Dx),n=qn((()=>t),[JSON.stringify(t,"undefined"!=typeof HTMLElement?(t,e)=>e instanceof HTMLElement?e.outerHTML:e:void 0)]);uy((()=>{null==e||e(null!=n?n:null)}),[e,n]);let r=Gn(Mx);return qn((()=>[r.setFloating,t?r.styles:{}]),[r.setFloating,t,r.styles])}(E),T=function(){let{getFloatingProps:t,slot:e}=Gn(Mx);return Kn(((...n)=>Object.assign({},t(...n),{"data-anchor":e.anchor})),[t,e])}(),C=Gy(e,d?k:null,m.setOptionsElement,p),A=ly();Wn((()=>{var t;let e=f.optionsElement;e&&0===f.listboxState&&e!==(null==(t=oy(e))?void 0:t.activeElement)&&(null==e||e.focus({preventScroll:!0}))}),[f.listboxState,f.optionsElement]);let R=dy((t=>{var e,n;switch(A.dispose(),t.key){case nb.Space:if(""!==f.searchQuery)return t.preventDefault(),t.stopPropagation(),m.search(t.key);case nb.Enter:if(t.preventDefault(),t.stopPropagation(),null!==f.activeOptionIndex){let{dataRef:t}=f.options[f.activeOptionIndex];m.onChange(t.current.value)}0===f.mode&&(Xr((()=>m.closeListbox())),null==(e=f.buttonElement)||e.focus({preventScroll:!0}));break;case gy(f.orientation,{vertical:nb.ArrowDown,horizontal:nb.ArrowRight}):return t.preventDefault(),t.stopPropagation(),m.goToOption(qx.Next);case gy(f.orientation,{vertical:nb.ArrowUp,horizontal:nb.ArrowLeft}):return t.preventDefault(),t.stopPropagation(),m.goToOption(qx.Previous);case nb.Home:case nb.PageUp:return t.preventDefault(),t.stopPropagation(),m.goToOption(qx.First);case nb.End:case nb.PageDown:return t.preventDefault(),t.stopPropagation(),m.goToOption(qx.Last);case nb.Escape:return t.preventDefault(),t.stopPropagation(),Xr((()=>m.closeListbox())),void(null==(n=f.buttonElement)||n.focus({preventScroll:!0}));case nb.Tab:t.preventDefault(),t.stopPropagation(),Xr((()=>m.closeListbox())),Mb(f.buttonElement,t.shiftKey?kb.Previous:kb.Next);break;default:1===t.key.length&&(m.search(t.key),A.setTimeout((()=>m.clearSearch()),350))}})),O=null==(n=f.buttonElement)?void 0:n.id,F=qn((()=>({open:0===f.listboxState})),[f.listboxState]),L=Py(d?T():{},{id:o,ref:C,"aria-activedescendant":null===f.activeOptionIndex||null==(r=f.options[f.activeOptionIndex])?void 0:r.id,"aria-multiselectable":1===f.mode||void 0,"aria-labelledby":O,"aria-orientation":f.orientation,onKeyDown:R,role:"listbox",tabIndex:0===f.listboxState?0:void 0,style:{...c.style,...P,"--button-width":cb(f.buttonElement,!0).width},...Yb(b)});return si.createElement(i_,{enabled:!!a&&(t.static||y)},si.createElement(A_.Provider,{value:1===f.mode?f:{...f,isSelected:_}},_y({ourProps:L,theirProps:c,slot:F,defaultTag:"div",features:M_,visible:w,name:"Listbox.Options"})))})),N_=Ty((function(t,e){let n=Qn(),{id:r=`headlessui-listbox-option-${n}`,disabled:i=!1,value:o,...s}=t,a=!0===Gn(L_),l=R_("Listbox.Option"),u=C_("Listbox.Option"),c=null!==l.activeOptionIndex&&l.options[l.activeOptionIndex].id===r,d=l.isSelected(o),h=$n(null),p=w_(h),f=cy({disabled:i,value:o,domRef:h,get textValue(){return p()}}),m=Gy(e,h,(t=>{t?l.listRef.current.set(r,t):l.listRef.current.delete(r)}));uy((()=>{if(!l.__demoMode&&0===l.listboxState&&c&&0!==l.activationTrigger)return ay().requestAnimationFrame((()=>{var t,e;null==(e=null==(t=h.current)?void 0:t.scrollIntoView)||e.call(t,{block:"nearest"})}))}),[h,c,l.__demoMode,l.listboxState,l.activationTrigger,l.activeOptionIndex]),uy((()=>{if(!a)return u.registerOption(r,f)}),[f,r,a]);let v=dy((t=>{var e;if(i)return t.preventDefault();u.onChange(o),0===l.mode&&(Xr((()=>u.closeListbox())),null==(e=l.buttonElement)||e.focus({preventScroll:!0}))})),g=dy((()=>{if(i)return u.goToOption(qx.Nothing);u.goToOption(qx.Specific,r)})),y=function(){let t=$n([-1,-1]);return{wasMoved(e){let n=qb(e);return(t.current[0]!==n[0]||t.current[1]!==n[1])&&(t.current=n,!0)},update(e){t.current=qb(e)}}}(),b=dy((t=>{y.update(t),!i&&(c||u.goToOption(qx.Specific,r,0))})),w=dy((t=>{y.wasMoved(t)&&(i||c||u.goToOption(qx.Specific,r,0))})),x=dy((t=>{y.wasMoved(t)&&(i||c&&u.goToOption(qx.Nothing))})),_=qn((()=>({active:c,focus:c,selected:d,disabled:i,selectedOption:d&&a})),[c,d,i,a]);return!d&&a?null:_y({ourProps:a?{}:{id:r,ref:m,role:"option",tabIndex:!0===i?void 0:-1,"aria-disabled":!0===i||void 0,"aria-selected":d,disabled:void 0,onClick:v,onFocus:g,onPointerEnter:b,onMouseEnter:b,onPointerMove:w,onMouseMove:w,onPointerLeave:x,onMouseLeave:x},theirProps:s,slot:_,defaultTag:"div",name:"Listbox.Option"})})),U_=Ty((function(t,e){let{options:n,placeholder:r,...i}=t,o={ref:Gy(e)},s=R_("ListboxSelectedOption"),a=qn((()=>({})),[]),l=void 0===s.value||null===s.value||1===s.mode&&Array.isArray(s.value)&&0===s.value.length;return si.createElement(L_.Provider,{value:!0},_y({ourProps:o,theirProps:{...i,children:si.createElement(si.Fragment,null,r&&l?r:n)},slot:a,defaultTag:D_,name:"ListboxSelectedOption"}))})),W_=Object.assign(V_,{Button:j_,Label:I_,Options:B_,Option:N_,SelectedOption:U_}),H_=fe(null);H_.displayName="GroupContext";let $_=Kt;let z_=Ty((function(t,e){var n;let r=Qn(),i=$y(),o=fy(),{id:s=i||`headlessui-switch-${r}`,disabled:a=o||!1,checked:l,defaultChecked:u,onChange:c,name:d,value:h,form:p,autoFocus:f=!1,...m}=t,v=Gn(H_),[g,y]=Nn(null),b=Gy($n(null),e,null===v?null:v.setSwitch,y),w=Oy(u),[x,_]=Ry(l,c,null!=w&&w),S=ly(),[E,k]=Nn(!1),P=dy((()=>{k(!0),null==_||_(!x),S.nextFrame((()=>{k(!1)}))})),T=dy((t=>{if(qy(t.currentTarget))return t.preventDefault();t.preventDefault(),P()})),C=dy((t=>{t.key===nb.Space?(t.preventDefault(),P()):t.key===nb.Enter&&Dy(t.currentTarget)})),A=dy((t=>t.preventDefault())),R=ob(),O=Xy(),{isFocusVisible:F,focusProps:L}=ey({autoFocus:f}),{isHovered:M,hoverProps:D}=ty({isDisabled:a}),{pressed:V,pressProps:j}=hy({disabled:a}),I=qn((()=>({checked:x,disabled:a,hover:M,focus:F,active:V,autofocus:f,changing:E})),[x,M,F,V,a,E,f]),B=Py({id:s,ref:b,role:"switch",type:Ub(t,g),tabIndex:-1===t.tabIndex?0:null!=(n=t.tabIndex)?n:0,"aria-checked":x,"aria-labelledby":R,"aria-describedby":O,disabled:a||void 0,autoFocus:f,onClick:T,onKeyUp:C,onKeyPress:A},L,D,j),N=Kn((()=>{if(void 0!==w)return null==_?void 0:_(w)}),[_,w]);return si.createElement(si.Fragment,null,null!=d&&si.createElement(Uy,{disabled:a,data:{[d]:h||"on"},overrides:{type:"checkbox",checked:x},form:p,onReset:N}),_y({ourProps:B,theirProps:m,slot:I,defaultTag:"button",name:"Switch"}))})),q_=function(t){var e;let[n,r]=Nn(null),[i,o]=sb(),[s,a]=Zy(),l=qn((()=>({switch:n,setSwitch:r})),[n,r]),u=t;return si.createElement(a,{name:"Switch.Description",value:s},si.createElement(o,{name:"Switch.Label",value:i,props:{htmlFor:null==(e=l.switch)?void 0:e.id,onClick(t){n&&(t.currentTarget instanceof HTMLLabelElement&&t.preventDefault(),n.click(),n.focus({preventScroll:!0}))}}},si.createElement(H_.Provider,{value:l},_y({ourProps:{},theirProps:u,slot:{},defaultTag:$_,name:"Switch.Group"}))))},K_=lb,G_=tb,Y_=Object.assign(z_,{Group:q_,Label:K_,Description:G_});function Q_(t,e){if(void 0===t.inserted[e.name])return t.insert("",e,t.sheet,!0)}function X_(t,e,n){var r=[],i=Mi(t,r,n);return r.length<2?n:i+e(r)}var Z_=function t(e){for(var n="",r=0;r<e.length;r++){var i=e[r];if(null!=i){var o=void 0;switch(typeof i){case"boolean":break;case"object":if(Array.isArray(i))o=t(i);else for(var s in o="",i)i[s]&&s&&(o&&(o+=" "),o+=s);break;default:o=i}o&&(n&&(n+=" "),n+=o)}}return n},J_=function(t){var e=An(t);e.sheet.speedy=function(t){this.isSpeedy=t},e.compat=!0;var n=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Yi(n,e.registered,void 0);return Vi(e,i,!1),e.key+"-"+i.name};return{css:n,cx:function(){for(var t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];return X_(e.registered,n,Z_(r))},injectGlobal:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Yi(n,e.registered);Q_(e,i)},keyframes:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Yi(n,e.registered),o="animation-"+i.name;return Q_(e,{name:i.name,styles:"@keyframes "+o+"{"+i.styles+"}"}),o},hydrate:function(t){t.forEach((function(t){e.inserted[t]=!0}))},flush:function(){e.registered={},e.inserted={},e.sheet.flush()},sheet:e.sheet,cache:e,getRegisteredStyles:Mi.bind(null,e.registered),merge:X_.bind(null,e.registered,n)}}({key:"css"}),tS=J_.cx,eS=J_.css;const nS=Ns(j_)`
|
|
45
|
+
`,Um=er((({label:t,id:e,type:n,placeholder:r,setPlaceholderOnFocus:i,value:o,className:s,onChange:a,onBlur:l,error:u,helperText:c,disabled:d},h)=>oo("div",{className:s,children:[io("label",{htmlFor:e,css:{display:"block",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:t}),io("div",{css:{marginTop:"0.5rem"},children:io(Gm,{type:n,value:o,name:e,id:e,placeholder:r,onChange:t=>{const e=t;e.target instanceof HTMLInputElement&&a(e.target.value.trim())},onBlur:t=>{const e=t;e.target instanceof HTMLInputElement&&l&&l(e.target.value.trim())},onFocus:()=>{r&&i&&!(null==o?void 0:o.trim())&&a(r)},hasError:!!u,ref:h,disabled:d})}),u&&io("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:u}),c&&io("span",{css:{fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:c})]})));var Wm=t=>"checkbox"===t.type,Hm=t=>t instanceof Date,$m=t=>null==t;const zm=t=>"object"==typeof t;var qm=t=>!$m(t)&&!Array.isArray(t)&&zm(t)&&!Hm(t),Km=t=>qm(t)&&t.target?Wm(t.target)?t.target.checked:t.target.value:t,Ym=(t,e)=>t.has((t=>t.substring(0,t.search(/\.\d+(\.|$)/))||t)(e)),Qm=t=>{const e=t.constructor&&t.constructor.prototype;return qm(e)&&e.hasOwnProperty("isPrototypeOf")},Xm="undefined"!=typeof window&&void 0!==window.HTMLElement&&"undefined"!=typeof document;function Zm(t){let e;const n=Array.isArray(t);if(t instanceof Date)e=new Date(t);else if(t instanceof Set)e=new Set(t);else{if(Xm&&(t instanceof Blob||t instanceof FileList)||!n&&!qm(t))return t;if(e=n?[]:{},n||Qm(t))for(const n in t)t.hasOwnProperty(n)&&(e[n]=Zm(t[n]));else e=t}return e}var Jm=t=>Array.isArray(t)?t.filter(Boolean):[],tv=t=>void 0===t,ev=(t,e,n)=>{if(!e||!qm(t))return n;const r=Jm(e.split(/[,[\].]+?/)).reduce(((t,e)=>$m(t)?t:t[e]),t);return tv(r)||r===t?tv(t[e])?n:t[e]:r},nv=t=>"boolean"==typeof t,rv=t=>/^\w*$/.test(t),iv=t=>Jm(t.replace(/["|']|\]/g,"").split(/\.|\[/)),ov=(t,e,n)=>{let r=-1;const i=rv(e)?[e]:iv(e),o=i.length,s=o-1;for(;++r<o;){const e=i[r];let o=n;if(r!==s){const n=t[e];o=qm(n)||Array.isArray(n)?n:isNaN(+i[r+1])?{}:[]}if("__proto__"===e)return;t[e]=o,t=t[e]}return t};const sv={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},av={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},lv="max",uv="min",cv="maxLength",dv="minLength",hv="pattern",pv="required",fv="validate",mv=Xr.createContext(null),vv=()=>Xr.useContext(mv);var gv=(t,e,n,r=!0)=>{const i={defaultValues:e._defaultValues};for(const o in t)Object.defineProperty(i,o,{get:()=>{const i=o;return e._proxyFormState[i]!==av.all&&(e._proxyFormState[i]=!r||av.all),n&&(n[i]=!0),t[i]}});return i},yv=t=>qm(t)&&!Object.keys(t).length,_v=(t,e,n,r)=>{n(t);const{name:i,...o}=t;return yv(o)||Object.keys(o).length>=Object.keys(e).length||Object.keys(o).find((t=>e[t]===(!r||av.all)))},bv=t=>Array.isArray(t)?t:[t],wv=(t,e,n)=>!t||!e||t===e||bv(t).some((t=>t&&(n?t===e:t.startsWith(e)||e.startsWith(t))));function xv(t){const e=Xr.useRef(t);e.current=t,Xr.useEffect((()=>{const n=!t.disabled&&e.current.subject&&e.current.subject.subscribe({next:e.current.next});return()=>{n&&n.unsubscribe()}}),[t.disabled])}var Sv=t=>"string"==typeof t,Ev=(t,e,n,r,i)=>Sv(t)?(r&&e.watch.add(t),ev(n,t,i)):Array.isArray(t)?t.map((t=>(r&&e.watch.add(t),ev(n,t)))):(r&&(e.watchAll=!0),n);function kv(t){const e=vv(),{name:n,disabled:r,control:i=e.control,shouldUnregister:o}=t,s=Ym(i._names.array,n),a=function(t){const e=vv(),{control:n=e.control,name:r,defaultValue:i,disabled:o,exact:s}=t||{},a=Xr.useRef(r);a.current=r,xv({disabled:o,subject:n._subjects.values,next:t=>{wv(a.current,t.name,s)&&u(Zm(Ev(a.current,n._names,t.values||n._formValues,!1,i)))}});const[l,u]=Xr.useState(n._getWatch(r,i));return Xr.useEffect((()=>n._removeUnmounted())),l}({control:i,name:n,defaultValue:ev(i._formValues,n,ev(i._defaultValues,n,t.defaultValue)),exact:!0}),l=function(t){const e=vv(),{control:n=e.control,disabled:r,name:i,exact:o}=t||{},[s,a]=Xr.useState(n._formState),l=Xr.useRef(!0),u=Xr.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),c=Xr.useRef(i);return c.current=i,xv({disabled:r,next:t=>l.current&&wv(c.current,t.name,o)&&_v(t,u.current,n._updateFormState)&&a({...n._formState,...t}),subject:n._subjects.state}),Xr.useEffect((()=>(l.current=!0,u.current.isValid&&n._updateValid(!0),()=>{l.current=!1})),[n]),gv(s,n,u.current,!1)}({control:i,name:n,exact:!0}),u=Xr.useRef(i.register(n,{...t.rules,value:a,...nv(t.disabled)?{disabled:t.disabled}:{}}));return Xr.useEffect((()=>{const t=i._options.shouldUnregister||o,e=(t,e)=>{const n=ev(i._fields,t);n&&n._f&&(n._f.mount=e)};if(e(n,!0),t){const t=Zm(ev(i._options.defaultValues,n));ov(i._defaultValues,n,t),tv(ev(i._formValues,n))&&ov(i._formValues,n,t)}return()=>{(s?t&&!i._state.action:t)?i.unregister(n):e(n,!1)}}),[n,i,s,o]),Xr.useEffect((()=>{ev(i._fields,n)&&i._updateDisabledField({disabled:r,fields:i._fields,name:n,value:ev(i._fields,n)._f.value})}),[r,n,i]),{field:{name:n,value:a,...nv(r)||l.disabled?{disabled:l.disabled||r}:{},onChange:Xr.useCallback((t=>u.current.onChange({target:{value:Km(t),name:n},type:sv.CHANGE})),[n]),onBlur:Xr.useCallback((()=>u.current.onBlur({target:{value:ev(i._formValues,n),name:n},type:sv.BLUR})),[n,i]),ref:Xr.useCallback((t=>{const e=ev(i._fields,n);e&&t&&(e._f.ref={focus:()=>t.focus(),select:()=>t.select(),setCustomValidity:e=>t.setCustomValidity(e),reportValidity:()=>t.reportValidity()})}),[i._fields,n])},formState:l,fieldState:Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!ev(l.errors,n)},isDirty:{enumerable:!0,get:()=>!!ev(l.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!ev(l.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!ev(l.validatingFields,n)},error:{enumerable:!0,get:()=>ev(l.errors,n)}})}}const Pv=t=>t.render(kv(t));var Tv=(t,e,n,r,i)=>e?{...n[t],types:{...n[t]&&n[t].types?n[t].types:{},[r]:i||!0}}:{},Av=t=>({isOnSubmit:!t||t===av.onSubmit,isOnBlur:t===av.onBlur,isOnChange:t===av.onChange,isOnAll:t===av.all,isOnTouch:t===av.onTouched}),Cv=(t,e,n)=>!n&&(e.watchAll||e.watch.has(t)||[...e.watch].some((e=>t.startsWith(e)&&/^\.\w+/.test(t.slice(e.length)))));const Rv=(t,e,n,r)=>{for(const i of n||Object.keys(t)){const n=ev(t,i);if(n){const{_f:t,...o}=n;if(t){if(t.refs&&t.refs[0]&&e(t.refs[0],i)&&!r)return!0;if(t.ref&&e(t.ref,t.name)&&!r)return!0;if(Rv(o,e))break}else if(qm(o)&&Rv(o,e))break}}};var Ov=(t,e,n)=>{const r=bv(ev(t,n));return ov(r,"root",e[n]),ov(t,n,r),t},Mv=t=>"file"===t.type,Fv=t=>"function"==typeof t,Lv=t=>{if(!Xm)return!1;const e=t?t.ownerDocument:0;return t instanceof(e&&e.defaultView?e.defaultView.HTMLElement:HTMLElement)},Dv=t=>Sv(t),Vv=t=>"radio"===t.type,jv=t=>t instanceof RegExp;const Iv={value:!1,isValid:!1},Bv={value:!0,isValid:!0};var Nv=t=>{if(Array.isArray(t)){if(t.length>1){const e=t.filter((t=>t&&t.checked&&!t.disabled)).map((t=>t.value));return{value:e,isValid:!!e.length}}return t[0].checked&&!t[0].disabled?t[0].attributes&&!tv(t[0].attributes.value)?tv(t[0].value)||""===t[0].value?Bv:{value:t[0].value,isValid:!0}:Bv:Iv}return Iv};const Gv={isValid:!1,value:null};var Uv=t=>Array.isArray(t)?t.reduce(((t,e)=>e&&e.checked&&!e.disabled?{isValid:!0,value:e.value}:t),Gv):Gv;function Wv(t,e,n="validate"){if(Dv(t)||Array.isArray(t)&&t.every(Dv)||nv(t)&&!t)return{type:n,message:Dv(t)?t:"",ref:e}}var Hv=t=>qm(t)&&!jv(t)?t:{value:t,message:""},$v=async(t,e,n,r,i)=>{const{ref:o,refs:s,required:a,maxLength:l,minLength:u,min:c,max:d,pattern:h,validate:p,name:f,valueAsNumber:m,mount:v,disabled:g}=t._f,y=ev(e,f);if(!v||g)return{};const _=s?s[0]:o,b=t=>{r&&_.reportValidity&&(_.setCustomValidity(nv(t)?"":t||""),_.reportValidity())},w={},x=Vv(o),S=Wm(o),E=x||S,k=(m||Mv(o))&&tv(o.value)&&tv(y)||Lv(o)&&""===o.value||""===y||Array.isArray(y)&&!y.length,P=Tv.bind(null,f,n,w),T=(t,e,n,r=cv,i=dv)=>{const s=t?e:n;w[f]={type:t?r:i,message:s,ref:o,...P(t?r:i,s)}};if(i?!Array.isArray(y)||!y.length:a&&(!E&&(k||$m(y))||nv(y)&&!y||S&&!Nv(s).isValid||x&&!Uv(s).isValid)){const{value:t,message:e}=Dv(a)?{value:!!a,message:a}:Hv(a);if(t&&(w[f]={type:pv,message:e,ref:_,...P(pv,e)},!n))return b(e),w}if(!(k||$m(c)&&$m(d))){let t,e;const r=Hv(d),i=Hv(c);if($m(y)||isNaN(y)){const n=o.valueAsDate||new Date(y),s=t=>new Date((new Date).toDateString()+" "+t),a="time"==o.type,l="week"==o.type;Sv(r.value)&&y&&(t=a?s(y)>s(r.value):l?y>r.value:n>new Date(r.value)),Sv(i.value)&&y&&(e=a?s(y)<s(i.value):l?y<i.value:n<new Date(i.value))}else{const n=o.valueAsNumber||(y?+y:y);$m(r.value)||(t=n>r.value),$m(i.value)||(e=n<i.value)}if((t||e)&&(T(!!t,r.message,i.message,lv,uv),!n))return b(w[f].message),w}if((l||u)&&!k&&(Sv(y)||i&&Array.isArray(y))){const t=Hv(l),e=Hv(u),r=!$m(t.value)&&y.length>+t.value,i=!$m(e.value)&&y.length<+e.value;if((r||i)&&(T(r,t.message,e.message),!n))return b(w[f].message),w}if(h&&!k&&Sv(y)){const{value:t,message:e}=Hv(h);if(jv(t)&&!y.match(t)&&(w[f]={type:hv,message:e,ref:o,...P(hv,e)},!n))return b(e),w}if(p)if(Fv(p)){const t=Wv(await p(y,e),_);if(t&&(w[f]={...t,...P(fv,t.message)},!n))return b(t.message),w}else if(qm(p)){let t={};for(const r in p){if(!yv(t)&&!n)break;const i=Wv(await p[r](y,e),_,r);i&&(t={...i,...P(r,i.message)},b(i.message),n&&(w[f]=t))}if(!yv(t)&&(w[f]={ref:_,...t},!n))return w}return b(!0),w};function zv(t,e){const n=Array.isArray(e)?e:rv(e)?[e]:iv(e),r=1===n.length?t:function(t,e){const n=e.slice(0,-1).length;let r=0;for(;r<n;)t=tv(t)?r++:t[e[r++]];return t}(t,n),i=n.length-1,o=n[i];return r&&delete r[o],0!==i&&(qm(r)&&yv(r)||Array.isArray(r)&&function(t){for(const e in t)if(t.hasOwnProperty(e)&&!tv(t[e]))return!1;return!0}(r))&&zv(t,n.slice(0,-1)),t}var qv=()=>{let t=[];return{get observers(){return t},next:e=>{for(const n of t)n.next&&n.next(e)},subscribe:e=>(t.push(e),{unsubscribe:()=>{t=t.filter((t=>t!==e))}}),unsubscribe:()=>{t=[]}}},Kv=t=>$m(t)||!zm(t);function Yv(t,e){if(Kv(t)||Kv(e))return t===e;if(Hm(t)&&Hm(e))return t.getTime()===e.getTime();const n=Object.keys(t),r=Object.keys(e);if(n.length!==r.length)return!1;for(const i of n){const n=t[i];if(!r.includes(i))return!1;if("ref"!==i){const t=e[i];if(Hm(n)&&Hm(t)||qm(n)&&qm(t)||Array.isArray(n)&&Array.isArray(t)?!Yv(n,t):n!==t)return!1}}return!0}var Qv=t=>"select-multiple"===t.type,Xv=t=>Vv(t)||Wm(t),Zv=t=>Lv(t)&&t.isConnected,Jv=t=>{for(const e in t)if(Fv(t[e]))return!0;return!1};function tg(t,e={}){const n=Array.isArray(t);if(qm(t)||n)for(const r in t)Array.isArray(t[r])||qm(t[r])&&!Jv(t[r])?(e[r]=Array.isArray(t[r])?[]:{},tg(t[r],e[r])):$m(t[r])||(e[r]=!0);return e}function eg(t,e,n){const r=Array.isArray(t);if(qm(t)||r)for(const i in t)Array.isArray(t[i])||qm(t[i])&&!Jv(t[i])?tv(e)||Kv(n[i])?n[i]=Array.isArray(t[i])?tg(t[i],[]):{...tg(t[i])}:eg(t[i],$m(e)?{}:e[i],n[i]):n[i]=!Yv(t[i],e[i]);return n}var ng=(t,e)=>eg(t,e,tg(e)),rg=(t,{valueAsNumber:e,valueAsDate:n,setValueAs:r})=>tv(t)?t:e?""===t?NaN:t?+t:t:n&&Sv(t)?new Date(t):r?r(t):t;function ig(t){const e=t.ref;if(!(t.refs?t.refs.every((t=>t.disabled)):e.disabled))return Mv(e)?e.files:Vv(e)?Uv(t.refs).value:Qv(e)?[...e.selectedOptions].map((({value:t})=>t)):Wm(e)?Nv(t.refs).value:rg(tv(e.value)?t.ref.value:e.value,t)}var og=(t,e,n,r)=>{const i={};for(const o of t){const t=ev(e,o);t&&ov(i,o,t._f)}return{criteriaMode:n,names:[...t],fields:i,shouldUseNativeValidation:r}},sg=t=>tv(t)?t:jv(t)?t.source:qm(t)?jv(t.value)?t.value.source:t.value:t;const ag="AsyncFunction";var lg=t=>!(t&&t.validate||!(Fv(t.validate)&&t.validate.constructor.name===ag||qm(t.validate)&&Object.values(t.validate).find((t=>t.constructor.name===ag)))),ug=t=>t.mount&&(t.required||t.min||t.max||t.maxLength||t.minLength||t.pattern||t.validate);function cg(t,e,n){const r=ev(t,n);if(r||rv(n))return{error:r,name:n};const i=n.split(".");for(;i.length;){const r=i.join("."),o=ev(e,r),s=ev(t,r);if(o&&!Array.isArray(o)&&n!==r)return{name:n};if(s&&s.type)return{name:r,error:s};i.pop()}return{name:n}}var dg=(t,e,n,r,i)=>!i.isOnAll&&(!n&&i.isOnTouch?!(e||t):(n?r.isOnBlur:i.isOnBlur)?!t:!(n?r.isOnChange:i.isOnChange)||t),hg=(t,e)=>!Jm(ev(t,e)).length&&zv(t,e);const pg={mode:av.onSubmit,reValidateMode:av.onChange,shouldFocusError:!0};function fg(t={}){let e,n={...pg,...t},r={submitCount:0,isDirty:!1,isLoading:Fv(n.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:n.errors||{},disabled:n.disabled||!1},i={},o=(qm(n.defaultValues)||qm(n.values))&&Zm(n.defaultValues||n.values)||{},s=n.shouldUnregister?{}:Zm(o),a={action:!1,mount:!1,watch:!1},l={mount:new Set,unMount:new Set,array:new Set,watch:new Set},u=0;const c={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},d={values:qv(),array:qv(),state:qv()},h=Av(n.mode),p=Av(n.reValidateMode),f=n.criteriaMode===av.all,m=async t=>{if(c.isValid||t){const t=n.resolver?yv((await b()).errors):await w(i,!0);t!==r.isValid&&d.state.next({isValid:t})}},v=(t,e)=>{(c.isValidating||c.validatingFields)&&((t||Array.from(l.mount)).forEach((t=>{t&&(e?ov(r.validatingFields,t,e):zv(r.validatingFields,t))})),d.state.next({validatingFields:r.validatingFields,isValidating:!yv(r.validatingFields)}))},g=(t,e,n,r)=>{const l=ev(i,t);if(l){const i=ev(s,t,tv(n)?ev(o,t):n);tv(i)||r&&r.defaultChecked||e?ov(s,t,e?i:ig(l._f)):E(t,i),a.mount&&m()}},y=(t,e,n,s,a)=>{let l=!1,u=!1;const h={name:t},p=!!(ev(i,t)&&ev(i,t)._f&&ev(i,t)._f.disabled);if(!n||s){c.isDirty&&(u=r.isDirty,r.isDirty=h.isDirty=x(),l=u!==h.isDirty);const n=p||Yv(ev(o,t),e);u=!(p||!ev(r.dirtyFields,t)),n||p?zv(r.dirtyFields,t):ov(r.dirtyFields,t,!0),h.dirtyFields=r.dirtyFields,l=l||c.dirtyFields&&u!==!n}if(n){const e=ev(r.touchedFields,t);e||(ov(r.touchedFields,t,n),h.touchedFields=r.touchedFields,l=l||c.touchedFields&&e!==n)}return l&&a&&d.state.next(h),l?h:{}},_=(n,i,o,s)=>{const a=ev(r.errors,n),l=c.isValid&&nv(i)&&r.isValid!==i;var h;if(t.delayError&&o?(h=()=>((t,e)=>{ov(r.errors,t,e),d.state.next({errors:r.errors})})(n,o),e=t=>{clearTimeout(u),u=setTimeout(h,t)},e(t.delayError)):(clearTimeout(u),e=null,o?ov(r.errors,n,o):zv(r.errors,n)),(o?!Yv(a,o):a)||!yv(s)||l){const t={...s,...l&&nv(i)?{isValid:i}:{},errors:r.errors,name:n};r={...r,...t},d.state.next(t)}},b=async t=>{v(t,!0);const e=await n.resolver(s,n.context,og(t||l.mount,i,n.criteriaMode,n.shouldUseNativeValidation));return v(t),e},w=async(t,e,i={valid:!0})=>{for(const o in t){const a=t[o];if(a){const{_f:t,...u}=a;if(t){const u=l.array.has(t.name),d=a._f&&lg(a._f);d&&c.validatingFields&&v([o],!0);const h=await $v(a,s,f,n.shouldUseNativeValidation&&!e,u);if(d&&c.validatingFields&&v([o]),h[t.name]&&(i.valid=!1,e))break;!e&&(ev(h,t.name)?u?Ov(r.errors,h,t.name):ov(r.errors,t.name,h[t.name]):zv(r.errors,t.name))}!yv(u)&&await w(u,e,i)}}return i.valid},x=(t,e)=>(t&&e&&ov(s,t,e),!Yv(R(),o)),S=(t,e,n)=>Ev(t,l,{...a.mount?s:tv(e)?o:Sv(t)?{[t]:e}:e},n,e),E=(t,e,n={})=>{const r=ev(i,t);let o=e;if(r){const n=r._f;n&&(!n.disabled&&ov(s,t,rg(e,n)),o=Lv(n.ref)&&$m(e)?"":e,Qv(n.ref)?[...n.ref.options].forEach((t=>t.selected=o.includes(t.value))):n.refs?Wm(n.ref)?n.refs.length>1?n.refs.forEach((t=>(!t.defaultChecked||!t.disabled)&&(t.checked=Array.isArray(o)?!!o.find((e=>e===t.value)):o===t.value))):n.refs[0]&&(n.refs[0].checked=!!o):n.refs.forEach((t=>t.checked=t.value===o)):Mv(n.ref)?n.ref.value="":(n.ref.value=o,n.ref.type||d.values.next({name:t,values:{...s}})))}(n.shouldDirty||n.shouldTouch)&&y(t,o,n.shouldTouch,n.shouldDirty,!0),n.shouldValidate&&C(t)},k=(t,e,n)=>{for(const r in e){const o=e[r],s=`${t}.${r}`,a=ev(i,s);!l.array.has(t)&&Kv(o)&&(!a||a._f)||Hm(o)?E(s,o,n):k(s,o,n)}},P=(t,e,n={})=>{const u=ev(i,t),h=l.array.has(t),p=Zm(e);ov(s,t,p),h?(d.array.next({name:t,values:{...s}}),(c.isDirty||c.dirtyFields)&&n.shouldDirty&&d.state.next({name:t,dirtyFields:ng(o,s),isDirty:x(t,p)})):!u||u._f||$m(p)?E(t,p,n):k(t,p,n),Cv(t,l)&&d.state.next({...r}),d.values.next({name:a.mount?t:void 0,values:{...s}})},T=async o=>{a.mount=!0;const u=o.target;let g=u.name,x=!0;const S=ev(i,g),E=t=>{x=Number.isNaN(t)||Yv(t,ev(s,g,t))};if(S){let a,k;const P=u.type?ig(S._f):Km(o),T=o.type===sv.BLUR||o.type===sv.FOCUS_OUT,A=!ug(S._f)&&!n.resolver&&!ev(r.errors,g)&&!S._f.deps||dg(T,ev(r.touchedFields,g),r.isSubmitted,p,h),R=Cv(g,l,T);ov(s,g,P),T?(S._f.onBlur&&S._f.onBlur(o),e&&e(0)):S._f.onChange&&S._f.onChange(o);const O=y(g,P,T,!1),M=!yv(O)||R;if(!T&&d.values.next({name:g,type:o.type,values:{...s}}),A)return c.isValid&&("onBlur"===t.mode?T&&m():m()),M&&d.state.next({name:g,...R?{}:O});if(!T&&R&&d.state.next({...r}),n.resolver){const{errors:t}=await b([g]);if(E(P),x){const e=cg(r.errors,i,g),n=cg(t,i,e.name||g);a=n.error,g=n.name,k=yv(t)}}else v([g],!0),a=(await $v(S,s,f,n.shouldUseNativeValidation))[g],v([g]),E(P),x&&(a?k=!1:c.isValid&&(k=await w(i,!0)));x&&(S._f.deps&&C(S._f.deps),_(g,k,a,O))}},A=(t,e)=>{if(ev(r.errors,e)&&t.focus)return t.focus(),1},C=async(t,e={})=>{let o,s;const a=bv(t);if(n.resolver){const e=await(async t=>{const{errors:e}=await b(t);if(t)for(const n of t){const t=ev(e,n);t?ov(r.errors,n,t):zv(r.errors,n)}else r.errors=e;return e})(tv(t)?t:a);o=yv(e),s=t?!a.some((t=>ev(e,t))):o}else t?(s=(await Promise.all(a.map((async t=>{const e=ev(i,t);return await w(e&&e._f?{[t]:e}:e)})))).every(Boolean),(s||r.isValid)&&m()):s=o=await w(i);return d.state.next({...!Sv(t)||c.isValid&&o!==r.isValid?{}:{name:t},...n.resolver||!t?{isValid:o}:{},errors:r.errors}),e.shouldFocus&&!s&&Rv(i,A,t?a:l.mount),s},R=t=>{const e={...a.mount?s:o};return tv(t)?e:Sv(t)?ev(e,t):t.map((t=>ev(e,t)))},O=(t,e)=>({invalid:!!ev((e||r).errors,t),isDirty:!!ev((e||r).dirtyFields,t),error:ev((e||r).errors,t),isValidating:!!ev(r.validatingFields,t),isTouched:!!ev((e||r).touchedFields,t)}),M=(t,e,n)=>{const o=(ev(i,t,{_f:{}})._f||{}).ref,s=ev(r.errors,t)||{},{ref:a,message:l,type:u,...c}=s;ov(r.errors,t,{...c,...e,ref:o}),d.state.next({name:t,errors:r.errors,isValid:!1}),n&&n.shouldFocus&&o&&o.focus&&o.focus()},F=(t,e={})=>{for(const a of t?bv(t):l.mount)l.mount.delete(a),l.array.delete(a),e.keepValue||(zv(i,a),zv(s,a)),!e.keepError&&zv(r.errors,a),!e.keepDirty&&zv(r.dirtyFields,a),!e.keepTouched&&zv(r.touchedFields,a),!e.keepIsValidating&&zv(r.validatingFields,a),!n.shouldUnregister&&!e.keepDefaultValue&&zv(o,a);d.values.next({values:{...s}}),d.state.next({...r,...e.keepDirty?{isDirty:x()}:{}}),!e.keepIsValid&&m()},L=({disabled:t,name:e,field:n,fields:r,value:i})=>{if(nv(t)&&a.mount||t){const o=t?void 0:tv(i)?ig(n?n._f:ev(r,e)._f):i;ov(s,e,o),y(e,o,!1,!1,!0)}},D=(e,r={})=>{let s=ev(i,e);const u=nv(r.disabled)||nv(t.disabled);return ov(i,e,{...s||{},_f:{...s&&s._f?s._f:{ref:{name:e}},name:e,mount:!0,...r}}),l.mount.add(e),s?L({field:s,disabled:nv(r.disabled)?r.disabled:t.disabled,name:e,value:r.value}):g(e,!0,r.value),{...u?{disabled:r.disabled||t.disabled}:{},...n.progressive?{required:!!r.required,min:sg(r.min),max:sg(r.max),minLength:sg(r.minLength),maxLength:sg(r.maxLength),pattern:sg(r.pattern)}:{},name:e,onChange:T,onBlur:T,ref:t=>{if(t){D(e,r),s=ev(i,e);const n=tv(t.value)&&t.querySelectorAll&&t.querySelectorAll("input,select,textarea")[0]||t,a=Xv(n),l=s._f.refs||[];if(a?l.find((t=>t===n)):n===s._f.ref)return;ov(i,e,{_f:{...s._f,...a?{refs:[...l.filter(Zv),n,...Array.isArray(ev(o,e))?[{}]:[]],ref:{type:n.type,name:e}}:{ref:n}}}),g(e,!1,void 0,n)}else s=ev(i,e,{}),s._f&&(s._f.mount=!1),(n.shouldUnregister||r.shouldUnregister)&&(!Ym(l.array,e)||!a.action)&&l.unMount.add(e)}}},V=()=>n.shouldFocusError&&Rv(i,A,l.mount),j=(t,e)=>async o=>{let a;o&&(o.preventDefault&&o.preventDefault(),o.persist&&o.persist());let l=Zm(s);if(d.state.next({isSubmitting:!0}),n.resolver){const{errors:t,values:e}=await b();r.errors=t,l=e}else await w(i);if(zv(r.errors,"root"),yv(r.errors)){d.state.next({errors:{}});try{await t(l,o)}catch(u){a=u}}else e&&await e({...r.errors},o),V(),setTimeout(V);if(d.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:yv(r.errors)&&!a,submitCount:r.submitCount+1,errors:r.errors}),a)throw a},I=(e,n={})=>{const u=e?Zm(e):o,h=Zm(u),p=yv(e),f=p?o:h;if(n.keepDefaultValues||(o=u),!n.keepValues){if(n.keepDirtyValues)for(const t of l.mount)ev(r.dirtyFields,t)?ov(f,t,ev(s,t)):P(t,ev(f,t));else{if(Xm&&tv(e))for(const t of l.mount){const e=ev(i,t);if(e&&e._f){const t=Array.isArray(e._f.refs)?e._f.refs[0]:e._f.ref;if(Lv(t)){const e=t.closest("form");if(e){e.reset();break}}}}i={}}s=t.shouldUnregister?n.keepDefaultValues?Zm(o):{}:Zm(f),d.array.next({values:{...f}}),d.values.next({values:{...f}})}l={mount:n.keepDirtyValues?l.mount:new Set,unMount:new Set,array:new Set,watch:new Set,watchAll:!1,focus:""},a.mount=!c.isValid||!!n.keepIsValid||!!n.keepDirtyValues,a.watch=!!t.shouldUnregister,d.state.next({submitCount:n.keepSubmitCount?r.submitCount:0,isDirty:!p&&(n.keepDirty?r.isDirty:!(!n.keepDefaultValues||Yv(e,o))),isSubmitted:!!n.keepIsSubmitted&&r.isSubmitted,dirtyFields:p?{}:n.keepDirtyValues?n.keepDefaultValues&&s?ng(o,s):r.dirtyFields:n.keepDefaultValues&&e?ng(o,e):n.keepDirty?r.dirtyFields:{},touchedFields:n.keepTouched?r.touchedFields:{},errors:n.keepErrors?r.errors:{},isSubmitSuccessful:!!n.keepIsSubmitSuccessful&&r.isSubmitSuccessful,isSubmitting:!1})},B=(t,e)=>I(Fv(t)?t(s):t,e);return{control:{register:D,unregister:F,getFieldState:O,handleSubmit:j,setError:M,_executeSchema:b,_getWatch:S,_getDirty:x,_updateValid:m,_removeUnmounted:()=>{for(const t of l.unMount){const e=ev(i,t);e&&(e._f.refs?e._f.refs.every((t=>!Zv(t))):!Zv(e._f.ref))&&F(t)}l.unMount=new Set},_updateFieldArray:(t,e=[],n,l,u=!0,h=!0)=>{if(l&&n){if(a.action=!0,h&&Array.isArray(ev(i,t))){const e=n(ev(i,t),l.argA,l.argB);u&&ov(i,t,e)}if(h&&Array.isArray(ev(r.errors,t))){const e=n(ev(r.errors,t),l.argA,l.argB);u&&ov(r.errors,t,e),hg(r.errors,t)}if(c.touchedFields&&h&&Array.isArray(ev(r.touchedFields,t))){const e=n(ev(r.touchedFields,t),l.argA,l.argB);u&&ov(r.touchedFields,t,e)}c.dirtyFields&&(r.dirtyFields=ng(o,s)),d.state.next({name:t,isDirty:x(t,e),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else ov(s,t,e)},_updateDisabledField:L,_getFieldArray:e=>Jm(ev(a.mount?s:o,e,t.shouldUnregister?ev(o,e,[]):[])),_reset:I,_resetDefaultValues:()=>Fv(n.defaultValues)&&n.defaultValues().then((t=>{B(t,n.resetOptions),d.state.next({isLoading:!1})})),_updateFormState:t=>{r={...r,...t}},_disableForm:t=>{nv(t)&&(d.state.next({disabled:t}),Rv(i,((e,n)=>{const r=ev(i,n);r&&(e.disabled=r._f.disabled||t,Array.isArray(r._f.refs)&&r._f.refs.forEach((e=>{e.disabled=r._f.disabled||t})))}),0,!1))},_subjects:d,_proxyFormState:c,_setErrors:t=>{r.errors=t,d.state.next({errors:r.errors,isValid:!1})},get _fields(){return i},get _formValues(){return s},get _state(){return a},set _state(t){a=t},get _defaultValues(){return o},get _names(){return l},set _names(t){l=t},get _formState(){return r},set _formState(t){r=t},get _options(){return n},set _options(t){n={...n,...t}}},trigger:C,register:D,handleSubmit:j,watch:(t,e)=>Fv(t)?d.values.subscribe({next:n=>t(S(void 0,e),n)}):S(t,e,!0),setValue:P,getValues:R,reset:B,resetField:(t,e={})=>{ev(i,t)&&(tv(e.defaultValue)?P(t,Zm(ev(o,t))):(P(t,e.defaultValue),ov(o,t,Zm(e.defaultValue))),e.keepTouched||zv(r.touchedFields,t),e.keepDirty||(zv(r.dirtyFields,t),r.isDirty=e.defaultValue?x(t,Zm(ev(o,t))):x()),e.keepError||(zv(r.errors,t),c.isValid&&m()),d.state.next({...r}))},clearErrors:t=>{t&&bv(t).forEach((t=>zv(r.errors,t))),d.state.next({errors:t?r.errors:{}})},unregister:F,setError:M,setFocus:(t,e={})=>{const n=ev(i,t),r=n&&n._f;if(r){const t=r.refs?r.refs[0]:r.ref;t.focus&&(t.focus(),e.shouldSelect&&t.select())}},getFieldState:O}}const mg="undefined"!=typeof document?Xr.useLayoutEffect:()=>{};const vg=t=>{var e;return null!==(e=null==t?void 0:t.ownerDocument)&&void 0!==e?e:document},gg=t=>{if(t&&"window"in t&&t.window===t)return t;return vg(t).defaultView||window};function yg(t){let e=null;return()=>(null==e&&(e=t()),e)}const _g=yg((function(){return t=/^Mac/i,"undefined"!=typeof window&&null!=window.navigator&&t.test((null===(e=window.navigator.userAgentData)||void 0===e?void 0:e.platform)||window.navigator.platform);var t,e})),bg=yg((function(){return t=/Android/i,"undefined"!=typeof window&&null!=window.navigator&&((null===(e=window.navigator.userAgentData)||void 0===e?void 0:e.brands.some((e=>t.test(e.brand))))||t.test(window.navigator.userAgent));var t,e}));class wg{isDefaultPrevented(){return this.nativeEvent.defaultPrevented}preventDefault(){this.defaultPrevented=!0,this.nativeEvent.preventDefault()}stopPropagation(){this.nativeEvent.stopPropagation(),this.isPropagationStopped=()=>!0}isPropagationStopped(){return!1}persist(){}constructor(t,e){this.nativeEvent=e,this.target=e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget,this.bubbles=e.bubbles,this.cancelable=e.cancelable,this.defaultPrevented=e.defaultPrevented,this.eventPhase=e.eventPhase,this.isTrusted=e.isTrusted,this.timeStamp=e.timeStamp,this.type=t}}function xg(t){let e=Dn({isFocused:!1,observer:null});mg((()=>{const t=e.current;return()=>{t.observer&&(t.observer.disconnect(),t.observer=null)}}),[]);let n=function(t){const e=Dn(null);return mg((()=>{e.current=t}),[t]),In(((...t)=>{const n=e.current;return null==n?void 0:n(...t)}),[])}((e=>{null==t||t(e)}));return In((t=>{if(t.target instanceof HTMLButtonElement||t.target instanceof HTMLInputElement||t.target instanceof HTMLTextAreaElement||t.target instanceof HTMLSelectElement){e.current.isFocused=!0;let r=t.target,i=t=>{e.current.isFocused=!1,r.disabled&&n(new wg("blur",t)),e.current.observer&&(e.current.observer.disconnect(),e.current.observer=null)};r.addEventListener("focusout",i,{once:!0}),e.current.observer=new MutationObserver((()=>{if(e.current.isFocused&&r.disabled){var t;null===(t=e.current.observer)||void 0===t||t.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}))}})),e.current.observer.observe(r,{attributes:!0,attributeFilter:["disabled"]})}}),[n])}let Sg=null,Eg=new Set,kg=new Map,Pg=!1,Tg=!1;const Ag={Tab:!0,Escape:!0};function Cg(t,e){for(let n of Eg)n(t,e)}function Rg(t){Pg=!0,function(t){return!(t.metaKey||!_g()&&t.altKey||t.ctrlKey||"Control"===t.key||"Shift"===t.key||"Meta"===t.key)}(t)&&(Sg="keyboard",Cg("keyboard",t))}function Og(t){Sg="pointer","mousedown"!==t.type&&"pointerdown"!==t.type||(Pg=!0,Cg("pointer",t))}function Mg(t){var e;(0===(e=t).mozInputSource&&e.isTrusted||(bg()&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType))&&(Pg=!0,Sg="virtual")}function Fg(t){t.target!==window&&t.target!==document&&(Pg||Tg||(Sg="virtual",Cg("virtual",t)),Pg=!1,Tg=!1)}function Lg(){Pg=!1,Tg=!0}function Dg(t){if("undefined"==typeof window||kg.get(gg(t)))return;const e=gg(t),n=vg(t);let r=e.HTMLElement.prototype.focus;e.HTMLElement.prototype.focus=function(){Pg=!0,r.apply(this,arguments)},n.addEventListener("keydown",Rg,!0),n.addEventListener("keyup",Rg,!0),n.addEventListener("click",Mg,!0),e.addEventListener("focus",Fg,!0),e.addEventListener("blur",Lg,!1),"undefined"!=typeof PointerEvent?(n.addEventListener("pointerdown",Og,!0),n.addEventListener("pointermove",Og,!0),n.addEventListener("pointerup",Og,!0)):(n.addEventListener("mousedown",Og,!0),n.addEventListener("mousemove",Og,!0),n.addEventListener("mouseup",Og,!0)),e.addEventListener("beforeunload",(()=>{Vg(t)}),{once:!0}),kg.set(e,{focus:r})}const Vg=(t,e)=>{const n=gg(t),r=vg(t);e&&r.removeEventListener("DOMContentLoaded",e),kg.has(n)&&(n.HTMLElement.prototype.focus=kg.get(n).focus,r.removeEventListener("keydown",Rg,!0),r.removeEventListener("keyup",Rg,!0),r.removeEventListener("click",Mg,!0),n.removeEventListener("focus",Fg,!0),n.removeEventListener("blur",Lg,!1),"undefined"!=typeof PointerEvent?(r.removeEventListener("pointerdown",Og,!0),r.removeEventListener("pointermove",Og,!0),r.removeEventListener("pointerup",Og,!0)):(r.removeEventListener("mousedown",Og,!0),r.removeEventListener("mousemove",Og,!0),r.removeEventListener("mouseup",Og,!0)),kg.delete(n))};function jg(){return"pointer"!==Sg}"undefined"!=typeof document&&function(t){const e=vg(t);let n;"loading"!==e.readyState?Dg(t):(n=()=>{Dg(t)},e.addEventListener("DOMContentLoaded",n))}();const Ig=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);function Bg(t,e,n){Dg(),Fn((()=>{let e=(e,r)=>{(function(t,e,n){var r;const i="undefined"!=typeof window?gg(null==n?void 0:n.target).HTMLInputElement:HTMLInputElement,o="undefined"!=typeof window?gg(null==n?void 0:n.target).HTMLTextAreaElement:HTMLTextAreaElement,s="undefined"!=typeof window?gg(null==n?void 0:n.target).HTMLElement:HTMLElement,a="undefined"!=typeof window?gg(null==n?void 0:n.target).KeyboardEvent:KeyboardEvent;return!((t=t||(null==n?void 0:n.target)instanceof i&&!Ig.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 s&&(null==n?void 0:n.target.isContentEditable))&&"keyboard"===e&&n instanceof a&&!Ag[n.key])})(!!(null==n?void 0:n.isTextInput),e,r)&&t(jg())};return Eg.add(e),()=>{Eg.delete(e)}}),e)}let Ng=!1,Gg=0;function Ug(){Ng=!0,setTimeout((()=>{Ng=!1}),50)}function Wg(t){"touch"===t.pointerType&&Ug()}function Hg(){if("undefined"!=typeof document)return"undefined"!=typeof PointerEvent?document.addEventListener("pointerup",Wg):document.addEventListener("touchend",Ug),Gg++,()=>{Gg--,Gg>0||("undefined"!=typeof PointerEvent?document.removeEventListener("pointerup",Wg):document.removeEventListener("touchend",Ug))}}function $g(t){let{onHoverStart:e,onHoverChange:n,onHoverEnd:r,isDisabled:i}=t,[o,s]=On(!1),a=Dn({isHovered:!1,ignoreEmulatedMouseEvents:!1,pointerType:"",target:null}).current;Fn(Hg,[]);let{hoverProps:l,triggerHoverEnd:u}=jn((()=>{let t=(t,r)=>{if(a.pointerType=r,i||"touch"===r||a.isHovered||!t.currentTarget.contains(t.target))return;a.isHovered=!0;let o=t.currentTarget;a.target=o,e&&e({type:"hoverstart",target:o,pointerType:r}),n&&n(!0),s(!0)},o=(t,e)=>{if(a.pointerType="",a.target=null,"touch"===e||!a.isHovered)return;a.isHovered=!1;let i=t.currentTarget;r&&r({type:"hoverend",target:i,pointerType:e}),n&&n(!1),s(!1)},l={};return"undefined"!=typeof PointerEvent?(l.onPointerEnter=e=>{Ng&&"mouse"===e.pointerType||t(e,e.pointerType)},l.onPointerLeave=t=>{!i&&t.currentTarget.contains(t.target)&&o(t,t.pointerType)}):(l.onTouchStart=()=>{a.ignoreEmulatedMouseEvents=!0},l.onMouseEnter=e=>{a.ignoreEmulatedMouseEvents||Ng||t(e,"mouse"),a.ignoreEmulatedMouseEvents=!1},l.onMouseLeave=t=>{!i&&t.currentTarget.contains(t.target)&&o(t,"mouse")}),{hoverProps:l,triggerHoverEnd:o}}),[e,n,r,i,a]);return Fn((()=>{i&&u({currentTarget:a.target},a.pointerType)}),[i]),{hoverProps:l,isHovered:o}}function zg(t={}){let{autoFocus:e=!1,isTextInput:n,within:r}=t,i=Dn({isFocused:!1,isFocusVisible:e||jg()}),[o,s]=On(!1),[a,l]=On((()=>i.current.isFocused&&i.current.isFocusVisible)),u=In((()=>l(i.current.isFocused&&i.current.isFocusVisible)),[]),c=In((t=>{i.current.isFocused=t,s(t),u()}),[u]);Bg((t=>{i.current.isFocusVisible=t,u()}),[],{isTextInput:n});let{focusProps:d}=function(t){let{isDisabled:e,onFocus:n,onBlur:r,onFocusChange:i}=t;const o=In((t=>{if(t.target===t.currentTarget)return r&&r(t),i&&i(!1),!0}),[r,i]),s=xg(o),a=In((t=>{const e=vg(t.target);t.target===t.currentTarget&&e.activeElement===t.target&&(n&&n(t),i&&i(!0),s(t))}),[i,n,s]);return{focusProps:{onFocus:!e&&(n||i||r)?a:void 0,onBlur:e||!r&&!i?void 0:o}}}({isDisabled:r,onFocusChange:c}),{focusWithinProps:h}=function(t){let{isDisabled:e,onBlurWithin:n,onFocusWithin:r,onFocusWithinChange:i}=t,o=Dn({isFocusWithin:!1}),s=In((t=>{o.current.isFocusWithin&&!t.currentTarget.contains(t.relatedTarget)&&(o.current.isFocusWithin=!1,n&&n(t),i&&i(!1))}),[n,i,o]),a=xg(s),l=In((t=>{o.current.isFocusWithin||document.activeElement!==t.target||(r&&r(t),i&&i(!0),o.current.isFocusWithin=!0,a(t))}),[r,i,a]);return e?{focusWithinProps:{onFocus:void 0,onBlur:void 0}}:{focusWithinProps:{onFocus:l,onBlur:s}}}({isDisabled:!r,onFocusWithinChange:c});return{isFocused:o,isFocusVisible:a,focusProps:r?h:d}}var qg=Object.defineProperty,Kg=(t,e,n)=>(((t,e,n)=>{e in t?qg(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n})(t,"symbol"!=typeof e?e+"":e,n),n);let Yg=new class{constructor(){Kg(this,"current",this.detect()),Kg(this,"handoffState","pending"),Kg(this,"currentId",0)}set(t){this.current!==t&&(this.handoffState="pending",this.currentId=0,this.current=t)}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 Qg(t){return Yg.isServer?null:t instanceof Node?t.ownerDocument:null!=t&&t.hasOwnProperty("current")&&t.current instanceof Node?t.current.ownerDocument:document}function Xg(t){"function"==typeof queueMicrotask?queueMicrotask(t):Promise.resolve().then(t).catch((t=>setTimeout((()=>{throw t}))))}function Zg(){let t=[],e={addEventListener:(t,n,r,i)=>(t.addEventListener(n,r,i),e.add((()=>t.removeEventListener(n,r,i)))),requestAnimationFrame(...t){let n=requestAnimationFrame(...t);return e.add((()=>cancelAnimationFrame(n)))},nextFrame:(...t)=>e.requestAnimationFrame((()=>e.requestAnimationFrame(...t))),setTimeout(...t){let n=setTimeout(...t);return e.add((()=>clearTimeout(n)))},microTask(...t){let n={current:!0};return Xg((()=>{n.current&&t[0]()})),e.add((()=>{n.current=!1}))},style(t,e,n){let r=t.style.getPropertyValue(e);return Object.assign(t.style,{[e]:n}),this.add((()=>{Object.assign(t.style,{[e]:r})}))},group(t){let e=Zg();return t(e),this.add((()=>e.dispose()))},add:e=>(t.includes(e)||t.push(e),()=>{let n=t.indexOf(e);if(n>=0)for(let e of t.splice(n,1))e()}),dispose(){for(let e of t.splice(0))e()}};return e}function Jg(){let[t]=On(Zg);return Fn((()=>()=>t.dispose()),[t]),t}let ty=(t,e)=>{Yg.isServer?Fn(t,e):Ln(t,e)};function ey(t){let e=Dn(t);return ty((()=>{e.current=t}),[t]),e}let ny=function(t){let e=ey(t);return Xr.useCallback(((...t)=>e.current(...t)),[e])};function ry({disabled:t=!1}={}){let e=Dn(null),[n,r]=On(!1),i=Jg(),o=ny((()=>{e.current=null,r(!1),i.dispose()})),s=ny((t=>{if(i.dispose(),null===e.current){e.current=t.currentTarget,r(!0);{let n=Qg(t.currentTarget);i.addEventListener(n,"pointerup",o,!1),i.addEventListener(n,"pointermove",(t=>{if(e.current){let n=function(t){let e=t.width/2,n=t.height/2;return{top:t.clientY-n,right:t.clientX+e,bottom:t.clientY+n,left:t.clientX-e}}(t);r(function(t,e){return!(!t||!e||t.right<e.left||t.left>e.right||t.bottom<e.top||t.top>e.bottom)}(n,e.current.getBoundingClientRect()))}}),!1),i.addEventListener(n,"pointercancel",o,!1)}}}));return{pressed:n,pressProps:t?{}:{onPointerDown:s,onPointerUp:o,onClick:o}}}let iy=oe(void 0);function oy(){return Bn(iy)}function sy({value:t,children:e}){return Xr.createElement(iy.Provider,{value:t},e)}function ay(...t){return Array.from(new Set(t.flatMap((t=>"string"==typeof t?t.split(" "):[])))).filter(Boolean).join(" ")}function ly(t,e,...n){if(t in e){let r=e[t];return"function"==typeof r?r(...n):r}let r=new Error(`Tried to handle "${t}" but there is no handler defined. Only defined handlers are: ${Object.keys(e).map((t=>`"${t}"`)).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,ly),r}var uy,cy,dy=((cy=dy||{})[cy.None=0]="None",cy[cy.RenderStrategy=1]="RenderStrategy",cy[cy.Static=2]="Static",cy),hy=((uy=hy||{})[uy.Unmount=0]="Unmount",uy[uy.Hidden=1]="Hidden",uy);function py({ourProps:t,theirProps:e,slot:n,defaultTag:r,features:i,visible:o=!0,name:s,mergeRefs:a}){a=null!=a?a:my;let l=vy(e,t);if(o)return fy(l,n,r,s,a);let u=null!=i?i:0;if(2&u){let{static:t=!1,...e}=l;if(t)return fy(e,n,r,s,a)}if(1&u){let{unmount:t=!0,...e}=l;return ly(t?0:1,{0:()=>null,1:()=>fy({...e,hidden:!0,style:{display:"none"}},n,r,s,a)})}return fy(l,n,r,s,a)}function fy(t,e={},n,r,i){let{as:o=n,children:s,refName:a="ref",...l}=by(t,["unmount","static"]),u=void 0!==t.ref?{[a]:t.ref}:{},c="function"==typeof s?s(e):s;"className"in l&&l.className&&"function"==typeof l.className&&(l.className=l.className(e)),l["aria-labelledby"]&&l["aria-labelledby"]===l.id&&(l["aria-labelledby"]=void 0);let d={};if(e){let t=!1,n=[];for(let[r,i]of Object.entries(e))"boolean"==typeof i&&(t=!0),!0===i&&n.push(r.replace(/([A-Z])/g,(t=>`-${t.toLowerCase()}`)));if(t){d["data-headlessui-state"]=n.join(" ");for(let t of n)d[`data-${t}`]=""}}if(o===It&&(Object.keys(_y(l)).length>0||Object.keys(_y(d)).length>0)){if(Dr(c)&&!(Array.isArray(c)&&c.length>1)){let t=c.props,e=null==t?void 0:t.className,n="function"==typeof e?(...t)=>ay(e(...t),l.className):ay(e,l.className),r=n?{className:n}:{},o=vy(c.props,_y(by(l,["ref"])));for(let i in d)i in o&&delete d[i];return Ir(c,Object.assign({},o,d,u,{ref:i(c.ref,u.ref)},r))}if(Object.keys(_y(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(_y(l)).concat(Object.keys(_y(d))).map((t=>` - ${t}`)).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((t=>` - ${t}`)).join("\n")].join("\n"))}return Dt(o,Object.assign({},by(l,["ref"]),o!==It&&u,o!==It&&d),c)}function my(...t){return t.every((t=>null==t))?void 0:e=>{for(let n of t)null!=n&&("function"==typeof n?n(e):n.current=e)}}function vy(...t){if(0===t.length)return{};if(1===t.length)return t[0];let e={},n={};for(let r of t)for(let t in r)t.startsWith("on")&&"function"==typeof r[t]?(null!=n[t]||(n[t]=[]),n[t].push(r[t])):e[t]=r[t];if(e.disabled||e["aria-disabled"])for(let r in n)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(r)&&(n[r]=[t=>{var e;return null==(e=null==t?void 0:t.preventDefault)?void 0:e.call(t)}]);for(let r in n)Object.assign(e,{[r](t,...e){let i=n[r];for(let n of i){if((t instanceof Event||(null==t?void 0:t.nativeEvent)instanceof Event)&&t.defaultPrevented)return;n(t,...e)}}});return e}function gy(...t){if(0===t.length)return{};if(1===t.length)return t[0];let e={},n={};for(let r of t)for(let t in r)t.startsWith("on")&&"function"==typeof r[t]?(null!=n[t]||(n[t]=[]),n[t].push(r[t])):e[t]=r[t];for(let r in n)Object.assign(e,{[r](...t){let e=n[r];for(let n of e)null==n||n(...t)}});return e}function yy(t){var e;return Object.assign(er(t),{displayName:null!=(e=t.displayName)?e:t.name})}function _y(t){let e=Object.assign({},t);for(let n in e)void 0===e[n]&&delete e[n];return e}function by(t,e=[]){let n=Object.assign({},t);for(let r of e)r in n&&delete n[r];return n}function wy(t,e,n){let[r,i]=On(n),o=void 0!==t,s=Dn(o),a=Dn(!1),l=Dn(!1);return!o||s.current||a.current?!o&&s.current&&!l.current&&(l.current=!0,s.current=o,console.error("A component is changing from controlled to uncontrolled. This may be caused by the value changing from a defined value to undefined, which should not happen.")):(a.current=!0,s.current=o,console.error("A component is changing from uncontrolled to controlled. This may be caused by the value changing from undefined to a defined value, which should not happen.")),[o?t:r,ny((t=>(o||i(t),null==e?void 0:e(t))))]}function xy(t){let[e]=On(t);return e}function Sy(t={},e=null,n=[]){for(let[r,i]of Object.entries(t))ky(n,Ey(e,r),i);return n}function Ey(t,e){return t?t+"["+e+"]":e}function ky(t,e,n){if(Array.isArray(n))for(let[r,i]of n.entries())ky(t,Ey(e,r.toString()),i);else n instanceof Date?t.push([e,n.toISOString()]):"boolean"==typeof n?t.push([e,n?"1":"0"]):"string"==typeof n?t.push([e,n]):"number"==typeof n?t.push([e,`${n}`]):null==n?t.push([e,""]):Sy(n,e,t)}function Py(t){var e,n;let r=null!=(e=null==t?void 0:t.form)?e:t.closest("form");if(r){for(let e of r.elements)if(e!==t&&("INPUT"===e.tagName&&"submit"===e.type||"BUTTON"===e.tagName&&"submit"===e.type||"INPUT"===e.nodeName&&"image"===e.type))return void e.click();null==(n=r.requestSubmit)||n.call(r)}}var Ty=(t=>(t[t.None=1]="None",t[t.Focusable=2]="Focusable",t[t.Hidden=4]="Hidden",t))(Ty||{});let Ay=yy((function(t,e){var n;let{features:r=1,...i}=t;return py({ourProps:{ref:e,"aria-hidden":!(2&~r)||(null!=(n=i["aria-hidden"])?n:void 0),hidden:!(4&~r)||void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...!(4&~r)&&!!(2&~r)&&{display:"none"}}},theirProps:i,slot:{},defaultTag:"span",name:"Hidden"})})),Cy=oe(null);function Ry(t){let[e,n]=On(null);return Xr.createElement(Cy.Provider,{value:{target:e}},t.children,Xr.createElement(Ay,{features:Ty.Hidden,ref:n}))}function Oy({children:t}){let e=Bn(Cy);if(!e)return Xr.createElement(Xr.Fragment,null,t);let{target:n}=e;return n?mr(Xr.createElement(Xr.Fragment,null,t),n):null}function My({data:t,form:e,disabled:n,onReset:r,overrides:i}){let[o,s]=On(null),a=Jg();return Fn((()=>{if(r&&o)return a.addEventListener(o,"reset",r)}),[o,e,r]),Xr.createElement(Oy,null,Xr.createElement(Fy,{setForm:s,formId:e}),Sy(t).map((([t,r])=>Xr.createElement(Ay,{features:Ty.Hidden,..._y({key:t,as:"input",type:"hidden",hidden:!0,readOnly:!0,form:e,disabled:n,name:t,value:r,...i})}))))}function Fy({setForm:t,formId:e}){return Fn((()=>{if(e){let n=document.getElementById(e);n&&t(n)}}),[t,e]),e?null:Xr.createElement(Ay,{features:Ty.Hidden,as:"input",type:"hidden",hidden:!0,readOnly:!0,ref:e=>{if(!e)return;let n=e.closest("form");n&&t(n)}})}let Ly=oe(void 0);function Dy(){return Bn(Ly)}function Vy({id:t,children:e}){return Xr.createElement(Ly.Provider,{value:t},e)}function jy(t){let e=t.parentElement,n=null;for(;e&&!(e instanceof HTMLFieldSetElement);)e instanceof HTMLLegendElement&&(n=e),e=e.parentElement;let r=""===(null==e?void 0:e.getAttribute("disabled"));return(!r||!function(t){if(!t)return!1;let e=t.previousElementSibling;for(;null!==e;){if(e instanceof HTMLLegendElement)return!1;e=e.previousElementSibling}return!0}(n))&&r}let Iy=Symbol();function By(...t){let e=Dn(t);Fn((()=>{e.current=t}),[t]);let n=ny((t=>{for(let n of e.current)null!=n&&("function"==typeof n?n(t):n.current=t)}));return t.every((t=>null==t||(null==t?void 0:t[Iy])))?void 0:n}let Ny=oe(null);function Gy(){let t=Bn(Ny);if(null===t){let t=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,Gy),t}return t}function Uy(){var t,e;return null!=(e=null==(t=Bn(Ny))?void 0:t.value)?e:void 0}function Wy(){let[t,e]=On([]);return[t.length>0?t.join(" "):void 0,jn((()=>function(t){let n=ny((t=>(e((e=>[...e,t])),()=>e((e=>{let n=e.slice(),r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}))))),r=jn((()=>({register:n,slot:t.slot,name:t.name,props:t.props,value:t.value})),[n,t.slot,t.name,t.props,t.value]);return Xr.createElement(Ny.Provider,{value:r},t.children)}),[e])]}Ny.displayName="DescriptionContext";let Hy=yy((function(t,e){let n=Gn(),r=oy(),{id:i=`headlessui-description-${n}`,...o}=t,s=Gy(),a=By(e);ty((()=>s.register(i)),[i,s.register]);let l=r||!1,u=jn((()=>({...s.slot,disabled:l})),[s.slot,l]);return py({ourProps:{ref:a,...s.props,id:i},theirProps:o,slot:u,defaultTag:"p",name:s.name||"Description"})})),$y=Object.assign(Hy,{});var zy,qy=((zy=qy||{}).Space=" ",zy.Enter="Enter",zy.Escape="Escape",zy.Backspace="Backspace",zy.Delete="Delete",zy.ArrowLeft="ArrowLeft",zy.ArrowUp="ArrowUp",zy.ArrowRight="ArrowRight",zy.ArrowDown="ArrowDown",zy.Home="Home",zy.End="End",zy.PageUp="PageUp",zy.PageDown="PageDown",zy.Tab="Tab",zy);let Ky=oe(null);function Yy(){let t=Bn(Ky);if(null===t){let t=new Error("You used a <Label /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,Yy),t}return t}function Qy(t){var e,n,r;let i=null!=(n=null==(e=Bn(Ky))?void 0:e.value)?n:void 0;return(null!=(r=null==t?void 0:t.length)?r:0)>0?[i,...t].filter(Boolean).join(" "):i}function Xy({inherit:t=!1}={}){let e=Qy(),[n,r]=On([]),i=t?[e,...n].filter(Boolean):n;return[i.length>0?i.join(" "):void 0,jn((()=>function(t){let e=ny((t=>(r((e=>[...e,t])),()=>r((e=>{let n=e.slice(),r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}))))),n=jn((()=>({register:e,slot:t.slot,name:t.name,props:t.props,value:t.value})),[e,t.slot,t.name,t.props,t.value]);return Xr.createElement(Ky.Provider,{value:n},t.children)}),[r])]}Ky.displayName="LabelContext";let Zy=yy((function(t,e){var n;let r=Gn(),i=Yy(),o=Dy(),s=oy(),{id:a=`headlessui-label-${r}`,htmlFor:l=(null!=o?o:null==(n=i.props)?void 0:n.htmlFor),passive:u=!1,...c}=t,d=By(e);ty((()=>i.register(a)),[a,i.register]);let h=ny((t=>{let e=t.currentTarget;if(e instanceof HTMLLabelElement&&t.preventDefault(),i.props&&"onClick"in i.props&&"function"==typeof i.props.onClick&&i.props.onClick(t),e instanceof HTMLLabelElement){let t=document.getElementById(e.htmlFor);if(t){let e=t.getAttribute("disabled");if("true"===e||""===e)return;let n=t.getAttribute("aria-disabled");if("true"===n||""===n)return;(t instanceof HTMLInputElement&&("radio"===t.type||"checkbox"===t.type)||"radio"===t.role||"checkbox"===t.role||"switch"===t.role)&&t.click(),t.focus({preventScroll:!0})}}})),p=s||!1,f=jn((()=>({...i.slot,disabled:p})),[i.slot,p]),m={ref:d,...i.props,id:a,htmlFor:l,onClick:h};return u&&("onClick"in m&&(delete m.htmlFor,delete m.onClick),"onClick"in c&&delete c.onClick),py({ourProps:m,theirProps:c,slot:f,defaultTag:l?"label":"div",name:i.name||"Label"})})),Jy=Object.assign(Zy,{});function t_(t,e){return null!==t&&null!==e&&"object"==typeof t&&"object"==typeof e&&"id"in t&&"id"in e?t.id===e.id:t===e}function e_(t,e=!1){let[n,r]=Mn((()=>({})),{}),i=jn((()=>function(t){if(null===t)return{width:0,height:0};let{width:e,height:n}=t.getBoundingClientRect();return{width:e,height:n}}(t)),[t,n]);return ty((()=>{if(!t)return;let e=new ResizeObserver(r);return e.observe(t),()=>{e.disconnect()}}),[t]),e?{width:`${i.width}px`,height:`${i.height}px`}:i}let n_=class extends Map{constructor(t){super(),this.factory=t}get(t){let e=super.get(t);return void 0===e&&(e=this.factory(t),this.set(t,e)),e}};function r_(t,e){let n=t(),r=new Set;return{getSnapshot:()=>n,subscribe:t=>(r.add(t),()=>r.delete(t)),dispatch(t,...i){let o=e[t].call(n,...i);o&&(n=o,r.forEach((t=>t())))}}}function i_(t){return Yr(t.subscribe,t.getSnapshot,t.getSnapshot)}let o_=new n_((()=>r_((()=>[]),{ADD(t){return this.includes(t)?this:[...this,t]},REMOVE(t){let e=this.indexOf(t);if(-1===e)return this;let n=this.slice();return n.splice(e,1),n}})));function s_(t,e){let n=o_.get(e),r=Gn(),i=i_(n);if(ty((()=>{if(t)return n.dispatch("ADD",r),()=>n.dispatch("REMOVE",r)}),[n,t]),!t)return!1;let o=i.indexOf(r),s=i.length;return-1===o&&(o=s,s+=1),o===s-1}let a_=new Map,l_=new Map;function u_(t){var e;let n=null!=(e=l_.get(t))?e:0;return l_.set(t,n+1),0!==n||(a_.set(t,{"aria-hidden":t.getAttribute("aria-hidden"),inert:t.inert}),t.setAttribute("aria-hidden","true"),t.inert=!0),()=>c_(t)}function c_(t){var e;let n=null!=(e=l_.get(t))?e:1;if(1===n?l_.delete(t):l_.set(t,n-1),1!==n)return;let r=a_.get(t);r&&(null===r["aria-hidden"]?t.removeAttribute("aria-hidden"):t.setAttribute("aria-hidden",r["aria-hidden"]),t.inert=r.inert,a_.delete(t))}let d_=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map((t=>`${t}:not([tabindex='-1'])`)).join(","),h_=["[data-autofocus]"].map((t=>`${t}:not([tabindex='-1'])`)).join(",");var p_,f_,m_,v_=((m_=v_||{})[m_.First=1]="First",m_[m_.Previous=2]="Previous",m_[m_.Next=4]="Next",m_[m_.Last=8]="Last",m_[m_.WrapAround=16]="WrapAround",m_[m_.NoScroll=32]="NoScroll",m_[m_.AutoFocus=64]="AutoFocus",m_),g_=((f_=g_||{})[f_.Error=0]="Error",f_[f_.Overflow=1]="Overflow",f_[f_.Success=2]="Success",f_[f_.Underflow=3]="Underflow",f_),y_=((p_=y_||{})[p_.Previous=-1]="Previous",p_[p_.Next=1]="Next",p_);function __(t=document.body){return null==t?[]:Array.from(t.querySelectorAll(d_)).sort(((t,e)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(e.tabIndex||Number.MAX_SAFE_INTEGER))))}var b_=(t=>(t[t.Strict=0]="Strict",t[t.Loose=1]="Loose",t))(b_||{});function w_(t,e=0){var n;return t!==(null==(n=Qg(t))?void 0:n.body)&&ly(e,{0:()=>t.matches(d_),1(){let e=t;for(;null!==e;){if(e.matches(d_))return!0;e=e.parentElement}return!1}})}var x_=(t=>(t[t.Keyboard=0]="Keyboard",t[t.Mouse=1]="Mouse",t))(x_||{});"undefined"!=typeof window&&"undefined"!=typeof document&&(document.addEventListener("keydown",(t=>{t.metaKey||t.altKey||t.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")}),!0),document.addEventListener("click",(t=>{1===t.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===t.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")}),!0));let S_=["textarea","input"].join(",");function E_(t,e=t=>t){return t.slice().sort(((t,n)=>{let r=e(t),i=e(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 k_(t,e){return function(t,e,{sorted:n=!0,relativeTo:r=null,skipElements:i=[]}={}){let o=Array.isArray(t)?t.length>0?t[0].ownerDocument:document:t.ownerDocument,s=Array.isArray(t)?n?E_(t):t:64&e?function(t=document.body){return null==t?[]:Array.from(t.querySelectorAll(h_)).sort(((t,e)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(e.tabIndex||Number.MAX_SAFE_INTEGER))))}(t):__(t);i.length>0&&s.length>1&&(s=s.filter((t=>!i.some((e=>null!=e&&"current"in e?(null==e?void 0:e.current)===t:e===t))))),r=null!=r?r:o.activeElement;let a,l=(()=>{if(5&e)return 1;if(10&e)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),u=(()=>{if(1&e)return 0;if(2&e)return Math.max(0,s.indexOf(r))-1;if(4&e)return Math.max(0,s.indexOf(r))+1;if(8&e)return s.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),c=32&e?{preventScroll:!0}:{},d=0,h=s.length;do{if(d>=h||d+h<=0)return 0;let t=u+d;if(16&e)t=(t+h)%h;else{if(t<0)return 3;if(t>=h)return 1}a=s[t],null==a||a.focus(c),d+=l}while(a!==o.activeElement);return 6&e&&function(t){var e,n;return null!=(n=null==(e=null==t?void 0:t.matches)?void 0:e.call(t,S_))&&n}(a)&&a.select(),2}(__(),e,{relativeTo:t})}function P_(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function T_(){return P_()||/Android/gi.test(window.navigator.userAgent)}function A_(t,e,n,r){let i=ey(n);Fn((()=>{if(t)return document.addEventListener(e,n,r),()=>document.removeEventListener(e,n,r);function n(t){i.current(t)}}),[t,e,r])}const C_=30;function R_(t,e,n){let r=s_(t,"outside-click"),i=ey(n),o=In((function(t,n){if(t.defaultPrevented)return;let r=n(t);if(null===r||!r.getRootNode().contains(r)||!r.isConnected)return;let o=function t(e){return"function"==typeof e?t(e()):Array.isArray(e)||e instanceof Set?e:[e]}(e);for(let e of o)if(null!==e&&(e.contains(r)||t.composed&&t.composedPath().includes(e)))return;return!w_(r,b_.Loose)&&-1!==r.tabIndex&&t.preventDefault(),i.current(t,r)}),[i,e]),s=Dn(null);A_(r,"pointerdown",(t=>{var e,n;s.current=(null==(n=null==(e=t.composedPath)?void 0:e.call(t))?void 0:n[0])||t.target}),!0),A_(r,"mousedown",(t=>{var e,n;s.current=(null==(n=null==(e=t.composedPath)?void 0:e.call(t))?void 0:n[0])||t.target}),!0),A_(r,"click",(t=>{T_()||s.current&&(o(t,(()=>s.current)),s.current=null)}),!0);let a=Dn({x:0,y:0});A_(r,"touchstart",(t=>{a.current.x=t.touches[0].clientX,a.current.y=t.touches[0].clientY}),!0),A_(r,"touchend",(t=>{let e=t.changedTouches[0].clientX,n=t.changedTouches[0].clientY;if(!(Math.abs(e-a.current.x)>=C_||Math.abs(n-a.current.y)>=C_))return o(t,(()=>t.target instanceof HTMLElement?t.target:null))}),!0),function(t,e,n,r){let i=ey(n);Fn((()=>{if(t)return window.addEventListener(e,n,r),()=>window.removeEventListener(e,n,r);function n(t){i.current(t)}}),[t,e,r])}(r,"blur",(t=>o(t,(()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null))),!0)}function O_(...t){return jn((()=>Qg(...t)),[...t])}function M_(t,e){return jn((()=>{var n;if(t.type)return t.type;let r=null!=(n=t.as)?n:"button";return"string"==typeof r&&"button"===r.toLowerCase()||"BUTTON"===(null==e?void 0:e.tagName)&&!e.hasAttribute("type")?"button":void 0}),[t.type,t.as,e])}function F_(){let t;return{before({doc:e}){var n;let r=e.documentElement,i=null!=(n=e.defaultView)?n:window;t=Math.max(0,i.innerWidth-r.clientWidth)},after({doc:e,d:n}){let r=e.documentElement,i=Math.max(0,r.clientWidth-r.offsetWidth),o=Math.max(0,t-i);n.style(r,"paddingRight",`${o}px`)}}}function L_(t){let e={};for(let n of t)Object.assign(e,n(e));return e}let D_=r_((()=>new Map),{PUSH(t,e){var n;let r=null!=(n=this.get(t))?n:{doc:t,count:0,d:Zg(),meta:new Set};return r.count++,r.meta.add(e),this.set(t,r),this},POP(t,e){let n=this.get(t);return n&&(n.count--,n.meta.delete(e)),this},SCROLL_PREVENT({doc:t,d:e,meta:n}){let r={doc:t,d:e,meta:L_(n)},i=[P_()?{before({doc:t,d:e,meta:n}){function r(t){return n.containers.flatMap((t=>t())).some((e=>e.contains(t)))}e.microTask((()=>{var n;if("auto"!==window.getComputedStyle(t.documentElement).scrollBehavior){let n=Zg();n.style(t.documentElement,"scrollBehavior","auto"),e.add((()=>e.microTask((()=>n.dispose()))))}let i=null!=(n=window.scrollY)?n:window.pageYOffset,o=null;e.addEventListener(t,"click",(e=>{if(e.target instanceof HTMLElement)try{let n=e.target.closest("a");if(!n)return;let{hash:i}=new URL(n.href),s=t.querySelector(i);s&&!r(s)&&(o=s)}catch{}}),!0),e.addEventListener(t,"touchstart",(t=>{if(t.target instanceof HTMLElement)if(r(t.target)){let n=t.target;for(;n.parentElement&&r(n.parentElement);)n=n.parentElement;e.style(n,"overscrollBehavior","contain")}else e.style(t.target,"touchAction","none")})),e.addEventListener(t,"touchmove",(t=>{if(t.target instanceof HTMLElement){if("INPUT"===t.target.tagName)return;if(r(t.target)){let e=t.target;for(;e.parentElement&&""!==e.dataset.headlessuiPortal&&!(e.scrollHeight>e.clientHeight||e.scrollWidth>e.clientWidth);)e=e.parentElement;""===e.dataset.headlessuiPortal&&t.preventDefault()}else t.preventDefault()}}),{passive:!1}),e.add((()=>{var t;let e=null!=(t=window.scrollY)?t:window.pageYOffset;i!==e&&window.scrollTo(0,i),o&&o.isConnected&&(o.scrollIntoView({block:"nearest"}),o=null)}))}))}}:{},F_(),{before({doc:t,d:e}){e.style(t.documentElement,"overflow","hidden")}}];i.forEach((({before:t})=>null==t?void 0:t(r))),i.forEach((({after:t})=>null==t?void 0:t(r)))},SCROLL_ALLOW({d:t}){t.dispose()},TEARDOWN({doc:t}){this.delete(t)}});function V_(t,e,n=()=>[document.body]){!function(t,e,n=()=>({containers:[]})){let r=i_(D_),i=e?r.get(e):void 0,o=!!i&&i.count>0;ty((()=>{if(e&&t)return D_.dispatch("PUSH",e,n),()=>D_.dispatch("POP",e,n)}),[t,e])}(s_(t,"scroll-lock"),e,(t=>{var e;return{containers:[...null!=(e=t.containers)?e:[],n]}}))}function j_(t){return[t.screenX,t.screenY]}D_.subscribe((()=>{let t=D_.getSnapshot(),e=new Map;for(let[n]of t)e.set(n,n.documentElement.style.overflow);for(let n of t.values()){let t="hidden"===e.get(n.doc),r=0!==n.count;(r&&!t||!r&&t)&&D_.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),0===n.count&&D_.dispatch("TEARDOWN",n)}}));var I_;"undefined"!=typeof process&&"undefined"!=typeof globalThis&&"test"===(null==(I_=null==process?void 0:{})?void 0:I_.NODE_ENV)&&void 0===Element.prototype.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 B_=(t=>(t[t.None=0]="None",t[t.Closed=1]="Closed",t[t.Enter=2]="Enter",t[t.Leave=4]="Leave",t))(B_||{});function N_(t){let e={};for(let n in t)!0===t[n]&&(e[`data-${n}`]="");return e}function G_(t,e,n,r){let[i,o]=On(n),{hasFlag:s,addFlag:a,removeFlag:l}=function(t=0){let[e,n]=On(t),r=In((t=>n(t)),[e]),i=In((t=>n((e=>e|t))),[e]),o=In((t=>(e&t)===t),[e]),s=In((t=>n((e=>e&~t))),[n]),a=In((t=>n((e=>e^t))),[n]);return{flags:e,setFlag:r,addFlag:i,hasFlag:o,removeFlag:s,toggleFlag:a}}(t&&i?3:0),u=Dn(!1),c=Dn(!1),d=Jg();return ty((()=>{var i;if(t)return n&&o(!0),e?(null==(i=null==r?void 0:r.start)||i.call(r,n),function(t,{prepare:e,run:n,done:r,inFlight:i}){let o=Zg();return function(t,{inFlight:e,prepare:n}){if(null!=e&&e.current)return void n();let r=t.style.transition;t.style.transition="none",n(),t.offsetHeight,t.style.transition=r}(t,{prepare:e,inFlight:i}),o.nextFrame((()=>{n(),o.requestAnimationFrame((()=>{o.add(function(t,e){var n,r;let i=Zg();if(!t)return i.dispose;let o=!1;i.add((()=>{o=!0}));let s=null!=(r=null==(n=t.getAnimations)?void 0:n.call(t).filter((t=>t instanceof CSSTransition)))?r:[];return 0===s.length?(e(),i.dispose):(Promise.allSettled(s.map((t=>t.finished))).then((()=>{o||e()})),i.dispose)}(t,r))}))})),o.dispose}(e,{inFlight:u,prepare(){c.current?c.current=!1:c.current=u.current,u.current=!0,!c.current&&(n?(a(3),l(4)):(a(4),l(2)))},run(){c.current?n?(l(3),a(4)):(l(4),a(3)):n?l(1):a(1)},done(){var t;c.current&&"function"==typeof e.getAnimations&&e.getAnimations().length>0||(u.current=!1,l(7),n||o(!1),null==(t=null==r?void 0:r.end)||t.call(r,n))}})):void(n&&a(3))}),[t,n,e,d]),t?[i,{closed:s(1),enter:s(2),leave:s(4),transition:s(2)||s(4)}]:[n,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function U_(){return"undefined"!=typeof window}function W_(t){return z_(t)?(t.nodeName||"").toLowerCase():"#document"}function H_(t){var e;return(null==t||null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function $_(t){var e;return null==(e=(z_(t)?t.ownerDocument:t.document)||window.document)?void 0:e.documentElement}function z_(t){return!!U_()&&(t instanceof Node||t instanceof H_(t).Node)}function q_(t){return!!U_()&&(t instanceof Element||t instanceof H_(t).Element)}function K_(t){return!!U_()&&(t instanceof HTMLElement||t instanceof H_(t).HTMLElement)}function Y_(t){return!(!U_()||"undefined"==typeof ShadowRoot)&&(t instanceof ShadowRoot||t instanceof H_(t).ShadowRoot)}function Q_(t){const{overflow:e,overflowX:n,overflowY:r,display:i}=nb(t);return/auto|scroll|overlay|hidden|clip/.test(e+r+n)&&!["inline","contents"].includes(i)}function X_(t){return["table","td","th"].includes(W_(t))}function Z_(t){return[":popover-open",":modal"].some((e=>{try{return t.matches(e)}catch(uy){return!1}}))}function J_(t){const e=tb(),n=q_(t)?nb(t):t;return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!e&&!!n.backdropFilter&&"none"!==n.backdropFilter||!e&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((t=>(n.willChange||"").includes(t)))||["paint","layout","strict","content"].some((t=>(n.contain||"").includes(t)))}function tb(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function eb(t){return["html","body","#document"].includes(W_(t))}function nb(t){return H_(t).getComputedStyle(t)}function rb(t){return q_(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function ib(t){if("html"===W_(t))return t;const e=t.assignedSlot||t.parentNode||Y_(t)&&t.host||$_(t);return Y_(e)?e.host:e}function ob(t){const e=ib(t);return eb(e)?t.ownerDocument?t.ownerDocument.body:t.body:K_(e)&&Q_(e)?e:ob(e)}function sb(t,e,n){var r;void 0===e&&(e=[]),void 0===n&&(n=!0);const i=ob(t),o=i===(null==(r=t.ownerDocument)?void 0:r.body),s=H_(i);if(o){const t=ab(s);return e.concat(s,s.visualViewport||[],Q_(i)?i:[],t&&n?sb(t):[])}return e.concat(i,sb(i,[],n))}function ab(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}const lb=Math.min,ub=Math.max,cb=Math.round,db=Math.floor,hb=t=>({x:t,y:t}),pb={left:"right",right:"left",bottom:"top",top:"bottom"},fb={start:"end",end:"start"};function mb(t,e,n){return ub(t,lb(e,n))}function vb(t,e){return"function"==typeof t?t(e):t}function gb(t){return t.split("-")[0]}function yb(t){return t.split("-")[1]}function _b(t){return"x"===t?"y":"x"}function bb(t){return"y"===t?"height":"width"}function wb(t){return["top","bottom"].includes(gb(t))?"y":"x"}function xb(t){return _b(wb(t))}function Sb(t){return t.replace(/start|end/g,(t=>fb[t]))}function Eb(t){return t.replace(/left|right|bottom|top/g,(t=>pb[t]))}function kb(t){const{x:e,y:n,width:r,height:i}=t;return{width:r,height:i,top:n,left:e,right:e+r,bottom:n+i,x:e,y:n}}function Pb(t,e,n){let{reference:r,floating:i}=t;const o=wb(e),s=xb(e),a=bb(s),l=gb(e),u="y"===o,c=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,h=r[a]/2-i[a]/2;let p;switch(l){case"top":p={x:c,y:r.y-i.height};break;case"bottom":p={x:c,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:d};break;case"left":p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(yb(e)){case"start":p[s]-=h*(n&&u?-1:1);break;case"end":p[s]+=h*(n&&u?-1:1)}return p}async function Tb(t,e){var n;void 0===e&&(e={});const{x:r,y:i,platform:o,rects:s,elements:a,strategy:l}=t,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:h=!1,padding:p=0}=vb(e,t),f=function(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}(p),m=a[h?"floating"===d?"reference":"floating":d],v=kb(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(m)))||n?m:m.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(a.floating)),boundary:u,rootBoundary:c,strategy:l})),g="floating"===d?{x:r,y:i,width:s.floating.width,height:s.floating.height}:s.reference,y=await(null==o.getOffsetParent?void 0:o.getOffsetParent(a.floating)),_=await(null==o.isElement?void 0:o.isElement(y))&&await(null==o.getScale?void 0:o.getScale(y))||{x:1,y:1},b=kb(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:g,offsetParent:y,strategy:l}):g);return{top:(v.top-b.top+f.top)/_.y,bottom:(b.bottom-v.bottom+f.bottom)/_.y,left:(v.left-b.left+f.left)/_.x,right:(b.right-v.right+f.right)/_.x}}function Ab(t){const e=nb(t);let n=parseFloat(e.width)||0,r=parseFloat(e.height)||0;const i=K_(t),o=i?t.offsetWidth:n,s=i?t.offsetHeight:r,a=cb(n)!==o||cb(r)!==s;return a&&(n=o,r=s),{width:n,height:r,$:a}}function Cb(t){return q_(t)?t:t.contextElement}function Rb(t){const e=Cb(t);if(!K_(e))return hb(1);const n=e.getBoundingClientRect(),{width:r,height:i,$:o}=Ab(e);let s=(o?cb(n.width):n.width)/r,a=(o?cb(n.height):n.height)/i;return s&&Number.isFinite(s)||(s=1),a&&Number.isFinite(a)||(a=1),{x:s,y:a}}const Ob=hb(0);function Mb(t){const e=H_(t);return tb()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:Ob}function Fb(t,e,n,r){void 0===e&&(e=!1),void 0===n&&(n=!1);const i=t.getBoundingClientRect(),o=Cb(t);let s=hb(1);e&&(r?q_(r)&&(s=Rb(r)):s=Rb(t));const a=function(t,e,n){return void 0===e&&(e=!1),!(!n||e&&n!==H_(t))&&e}(o,n,r)?Mb(o):hb(0);let l=(i.left+a.x)/s.x,u=(i.top+a.y)/s.y,c=i.width/s.x,d=i.height/s.y;if(o){const t=H_(o),e=r&&q_(r)?H_(r):r;let n=t,i=ab(n);for(;i&&r&&e!==n;){const t=Rb(i),e=i.getBoundingClientRect(),r=nb(i),o=e.left+(i.clientLeft+parseFloat(r.paddingLeft))*t.x,s=e.top+(i.clientTop+parseFloat(r.paddingTop))*t.y;l*=t.x,u*=t.y,c*=t.x,d*=t.y,l+=o,u+=s,n=H_(i),i=ab(n)}}return kb({width:c,height:d,x:l,y:u})}function Lb(t,e){const n=rb(t).scrollLeft;return e?e.left+n:Fb($_(t)).left+n}function Db(t,e,n){let r;if("viewport"===e)r=function(t,e){const n=H_(t),r=$_(t),i=n.visualViewport;let o=r.clientWidth,s=r.clientHeight,a=0,l=0;if(i){o=i.width,s=i.height;const t=tb();(!t||t&&"fixed"===e)&&(a=i.offsetLeft,l=i.offsetTop)}return{width:o,height:s,x:a,y:l}}(t,n);else if("document"===e)r=function(t){const e=$_(t),n=rb(t),r=t.ownerDocument.body,i=ub(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),o=ub(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+Lb(t);const a=-n.scrollTop;return"rtl"===nb(r).direction&&(s+=ub(e.clientWidth,r.clientWidth)-i),{width:i,height:o,x:s,y:a}}($_(t));else if(q_(e))r=function(t,e){const n=Fb(t,!0,"fixed"===e),r=n.top+t.clientTop,i=n.left+t.clientLeft,o=K_(t)?Rb(t):hb(1);return{width:t.clientWidth*o.x,height:t.clientHeight*o.y,x:i*o.x,y:r*o.y}}(e,n);else{const n=Mb(t);r={...e,x:e.x-n.x,y:e.y-n.y}}return kb(r)}function Vb(t,e){const n=ib(t);return!(n===e||!q_(n)||eb(n))&&("fixed"===nb(n).position||Vb(n,e))}function jb(t,e,n){const r=K_(e),i=$_(e),o="fixed"===n,s=Fb(t,!0,o,e);let a={scrollLeft:0,scrollTop:0};const l=hb(0);if(r||!r&&!o)if(("body"!==W_(e)||Q_(i))&&(a=rb(e)),r){const t=Fb(e,!0,o,e);l.x=t.x+e.clientLeft,l.y=t.y+e.clientTop}else i&&(l.x=Lb(i));let u=0,c=0;if(i&&!r&&!o){const t=i.getBoundingClientRect();c=t.top+a.scrollTop,u=t.left+a.scrollLeft-Lb(i,t)}return{x:s.left+a.scrollLeft-l.x-u,y:s.top+a.scrollTop-l.y-c,width:s.width,height:s.height}}function Ib(t){return"static"===nb(t).position}function Bb(t,e){if(!K_(t)||"fixed"===nb(t).position)return null;if(e)return e(t);let n=t.offsetParent;return $_(t)===n&&(n=n.ownerDocument.body),n}function Nb(t,e){const n=H_(t);if(Z_(t))return n;if(!K_(t)){let e=ib(t);for(;e&&!eb(e);){if(q_(e)&&!Ib(e))return e;e=ib(e)}return n}let r=Bb(t,e);for(;r&&X_(r)&&Ib(r);)r=Bb(r,e);return r&&eb(r)&&Ib(r)&&!J_(r)?n:r||function(t){let e=ib(t);for(;K_(e)&&!eb(e);){if(J_(e))return e;if(Z_(e))return null;e=ib(e)}return null}(t)||n}const Gb={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{elements:e,rect:n,offsetParent:r,strategy:i}=t;const o="fixed"===i,s=$_(r),a=!!e&&Z_(e.floating);if(r===s||a&&o)return n;let l={scrollLeft:0,scrollTop:0},u=hb(1);const c=hb(0),d=K_(r);if((d||!d&&!o)&&(("body"!==W_(r)||Q_(s))&&(l=rb(r)),K_(r))){const t=Fb(r);u=Rb(r),c.x=t.x+r.clientLeft,c.y=t.y+r.clientTop}return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+c.x,y:n.y*u.y-l.scrollTop*u.y+c.y}},getDocumentElement:$_,getClippingRect:function(t){let{element:e,boundary:n,rootBoundary:r,strategy:i}=t;const o=[..."clippingAncestors"===n?Z_(e)?[]:function(t,e){const n=e.get(t);if(n)return n;let r=sb(t,[],!1).filter((t=>q_(t)&&"body"!==W_(t))),i=null;const o="fixed"===nb(t).position;let s=o?ib(t):t;for(;q_(s)&&!eb(s);){const e=nb(s),n=J_(s);n||"fixed"!==e.position||(i=null),(o?!n&&!i:!n&&"static"===e.position&&i&&["absolute","fixed"].includes(i.position)||Q_(s)&&!n&&Vb(t,s))?r=r.filter((t=>t!==s)):i=e,s=ib(s)}return e.set(t,r),r}(e,this._c):[].concat(n),r],s=o[0],a=o.reduce(((t,n)=>{const r=Db(e,n,i);return t.top=ub(r.top,t.top),t.right=lb(r.right,t.right),t.bottom=lb(r.bottom,t.bottom),t.left=ub(r.left,t.left),t}),Db(e,s,i));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}},getOffsetParent:Nb,getElementRects:async function(t){const e=this.getOffsetParent||Nb,n=this.getDimensions,r=await n(t.floating);return{reference:jb(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){const{width:e,height:n}=Ab(t);return{width:e,height:n}},getScale:Rb,isElement:q_,isRTL:function(t){return"rtl"===nb(t).direction}};function Ub(t,e,n,r){void 0===r&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s="function"==typeof ResizeObserver,layoutShift:a="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,u=Cb(t),c=i||o?[...u?sb(u):[],...sb(e)]:[];c.forEach((t=>{i&&t.addEventListener("scroll",n,{passive:!0}),o&&t.addEventListener("resize",n)}));const d=u&&a?function(t,e){let n,r=null;const i=$_(t);function o(){var t;clearTimeout(n),null==(t=r)||t.disconnect(),r=null}return function s(a,l){void 0===a&&(a=!1),void 0===l&&(l=1),o();const{left:u,top:c,width:d,height:h}=t.getBoundingClientRect();if(a||e(),!d||!h)return;const p={rootMargin:-db(c)+"px "+-db(i.clientWidth-(u+d))+"px "+-db(i.clientHeight-(c+h))+"px "+-db(u)+"px",threshold:ub(0,lb(1,l))||1};let f=!0;function m(t){const e=t[0].intersectionRatio;if(e!==l){if(!f)return s();e?s(!1,e):n=setTimeout((()=>{s(!1,1e-7)}),1e3)}f=!1}try{r=new IntersectionObserver(m,{...p,root:i.ownerDocument})}catch(uy){r=new IntersectionObserver(m,p)}r.observe(t)}(!0),o}(u,n):null;let h,p=-1,f=null;s&&(f=new ResizeObserver((t=>{let[r]=t;r&&r.target===u&&f&&(f.unobserve(e),cancelAnimationFrame(p),p=requestAnimationFrame((()=>{var t;null==(t=f)||t.observe(e)}))),n()})),u&&!l&&f.observe(u),f.observe(e));let m=l?Fb(t):null;return l&&function e(){const r=Fb(t);!m||r.x===m.x&&r.y===m.y&&r.width===m.width&&r.height===m.height||n();m=r,h=requestAnimationFrame(e)}(),n(),()=>{var t;c.forEach((t=>{i&&t.removeEventListener("scroll",n),o&&t.removeEventListener("resize",n)})),null==d||d(),null==(t=f)||t.disconnect(),f=null,l&&cancelAnimationFrame(h)}}const Wb=Tb,Hb=function(t){return void 0===t&&(t=0),{name:"offset",options:t,async fn(e){var n,r;const{x:i,y:o,placement:s,middlewareData:a}=e,l=await async function(t,e){const{placement:n,platform:r,elements:i}=t,o=await(null==r.isRTL?void 0:r.isRTL(i.floating)),s=gb(n),a=yb(n),l="y"===wb(n),u=["left","top"].includes(s)?-1:1,c=o&&l?-1:1,d=vb(e,t);let{mainAxis:h,crossAxis:p,alignmentAxis:f}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&"number"==typeof f&&(p="end"===a?-1*f:f),l?{x:p*c,y:h*u}:{x:h*u,y:p*c}}(e,t);return s===(null==(n=a.offset)?void 0:n.placement)&&null!=(r=a.arrow)&&r.alignmentOffset?{}:{x:i+l.x,y:o+l.y,data:{...l,placement:s}}}}},$b=function(t){return void 0===t&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:r,placement:i}=e,{mainAxis:o=!0,crossAxis:s=!1,limiter:a={fn:t=>{let{x:e,y:n}=t;return{x:e,y:n}}},...l}=vb(t,e),u={x:n,y:r},c=await Tb(e,l),d=wb(gb(i)),h=_b(d);let p=u[h],f=u[d];if(o){const t="y"===h?"bottom":"right";p=mb(p+c["y"===h?"top":"left"],p,p-c[t])}if(s){const t="y"===d?"bottom":"right";f=mb(f+c["y"===d?"top":"left"],f,f-c[t])}const m=a.fn({...e,[h]:p,[d]:f});return{...m,data:{x:m.x-n,y:m.y-r,enabled:{[h]:o,[d]:s}}}}}},zb=function(t){return void 0===t&&(t={}),{name:"flip",options:t,async fn(e){var n,r;const{placement:i,middlewareData:o,rects:s,initialPlacement:a,platform:l,elements:u}=e,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:m=!0,...v}=vb(t,e);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const g=gb(i),y=wb(a),_=gb(a)===a,b=await(null==l.isRTL?void 0:l.isRTL(u.floating)),w=h||(_||!m?[Eb(a)]:function(t){const e=Eb(t);return[Sb(t),e,Sb(e)]}(a)),x="none"!==f;!h&&x&&w.push(...function(t,e,n,r){const i=yb(t);let o=function(t,e,n){const r=["left","right"],i=["right","left"],o=["top","bottom"],s=["bottom","top"];switch(t){case"top":case"bottom":return n?e?i:r:e?r:i;case"left":case"right":return e?o:s;default:return[]}}(gb(t),"start"===n,r);return i&&(o=o.map((t=>t+"-"+i)),e&&(o=o.concat(o.map(Sb)))),o}(a,m,f,b));const S=[a,...w],E=await Tb(e,v),k=[];let P=(null==(r=o.flip)?void 0:r.overflows)||[];if(c&&k.push(E[g]),d){const t=function(t,e,n){void 0===n&&(n=!1);const r=yb(t),i=xb(t),o=bb(i);let s="x"===i?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return e.reference[o]>e.floating[o]&&(s=Eb(s)),[s,Eb(s)]}(i,s,b);k.push(E[t[0]],E[t[1]])}if(P=[...P,{placement:i,overflows:k}],!k.every((t=>t<=0))){var T,A;const t=((null==(T=o.flip)?void 0:T.index)||0)+1,e=S[t];if(e)return{data:{index:t,overflows:P},reset:{placement:e}};let n=null==(A=P.filter((t=>t.overflows[0]<=0)).sort(((t,e)=>t.overflows[1]-e.overflows[1]))[0])?void 0:A.placement;if(!n)switch(p){case"bestFit":{var C;const t=null==(C=P.filter((t=>{if(x){const e=wb(t.placement);return e===y||"y"===e}return!0})).map((t=>[t.placement,t.overflows.filter((t=>t>0)).reduce(((t,e)=>t+e),0)])).sort(((t,e)=>t[1]-e[1]))[0])?void 0:C[0];t&&(n=t);break}case"initialPlacement":n=a}if(i!==n)return{reset:{placement:n}}}return{}}}},qb=function(t){return void 0===t&&(t={}),{name:"size",options:t,async fn(e){var n,r;const{placement:i,rects:o,platform:s,elements:a}=e,{apply:l=()=>{},...u}=vb(t,e),c=await Tb(e,u),d=gb(i),h=yb(i),p="y"===wb(i),{width:f,height:m}=o.floating;let v,g;"top"===d||"bottom"===d?(v=d,g=h===(await(null==s.isRTL?void 0:s.isRTL(a.floating))?"start":"end")?"left":"right"):(g=d,v="end"===h?"top":"bottom");const y=m-c.top-c.bottom,_=f-c.left-c.right,b=lb(m-c[v],y),w=lb(f-c[g],_),x=!e.middlewareData.shift;let S=b,E=w;if(null!=(n=e.middlewareData.shift)&&n.enabled.x&&(E=_),null!=(r=e.middlewareData.shift)&&r.enabled.y&&(S=y),x&&!h){const t=ub(c.left,0),e=ub(c.right,0),n=ub(c.top,0),r=ub(c.bottom,0);p?E=f-2*(0!==t||0!==e?t+e:ub(c.left,c.right)):S=m-2*(0!==n||0!==r?n+r:ub(c.top,c.bottom))}await l({...e,availableWidth:E,availableHeight:S});const k=await s.getDimensions(a.floating);return f!==k.width||m!==k.height?{reset:{rects:!0}}:{}}}},Kb=(t,e,n)=>{const r=new Map,i={platform:Gb,...n},o={...i.platform,_c:r};return(async(t,e,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:s}=n,a=o.filter(Boolean),l=await(null==s.isRTL?void 0:s.isRTL(e));let u=await s.getElementRects({reference:t,floating:e,strategy:i}),{x:c,y:d}=Pb(u,r,l),h=r,p={},f=0;for(let m=0;m<a.length;m++){const{name:n,fn:o}=a[m],{x:v,y:g,data:y,reset:_}=await o({x:c,y:d,initialPlacement:r,placement:h,strategy:i,middlewareData:p,rects:u,platform:s,elements:{reference:t,floating:e}});c=null!=v?v:c,d=null!=g?g:d,p={...p,[n]:{...p[n],...y}},_&&f<=50&&(f++,"object"==typeof _&&(_.placement&&(h=_.placement),_.rects&&(u=!0===_.rects?await s.getElementRects({reference:t,floating:e,strategy:i}):_.rects),({x:c,y:d}=Pb(u,h,l))),m=-1)}return{x:c,y:d,placement:h,strategy:i,middlewareData:p}})(t,e,{...i,platform:o})};var Yb="undefined"!=typeof document?Ln:Fn;function Qb(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if("function"==typeof t&&t.toString()===e.toString())return!0;let n,r,i;if(t&&e&&"object"==typeof t){if(Array.isArray(t)){if(n=t.length,n!==e.length)return!1;for(r=n;0!=r--;)if(!Qb(t[r],e[r]))return!1;return!0}if(i=Object.keys(t),n=i.length,n!==Object.keys(e).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(e,i[r]))return!1;for(r=n;0!=r--;){const n=i[r];if(("_owner"!==n||!t.$$typeof)&&!Qb(t[n],e[n]))return!1}return!0}return t!=t&&e!=e}function Xb(t){if("undefined"==typeof window)return 1;return(t.ownerDocument.defaultView||window).devicePixelRatio||1}function Zb(t,e){const n=Xb(t);return Math.round(e*n)/n}function Jb(t){const e=Dn(t);return Yb((()=>{e.current=t})),e}const tw=(t,e)=>({...Hb(t),options:[t,e]}),ew=(t,e)=>({...$b(t),options:[t,e]}),nw=(t,e)=>({...zb(t),options:[t,e]}),rw=(t,e)=>({...qb(t),options:[t,e]}),iw={...Zr},ow=iw.useInsertionEffect||(t=>t());function sw(t){const e=Dn((()=>{}));return ow((()=>{e.current=t})),In((function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return null==e.current?void 0:e.current(...n)}),[])}var aw="undefined"!=typeof document?Ln:Fn;let lw=!1,uw=0;const cw=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+uw++;const dw=iw.useId||function(){const[t,e]=On((()=>lw?cw():void 0));return aw((()=>{null==t&&e(cw())}),[]),Fn((()=>{lw=!0}),[]),t};const hw=oe(null),pw=oe(null),fw=()=>{var t;return(null==(t=Bn(hw))?void 0:t.id)||null},mw=()=>Bn(pw),vw="data-floating-ui-focusable";function gw(t){const{open:e=!1,onOpenChange:n,elements:r}=t,i=dw(),o=Dn({}),[s]=On((()=>function(){const t=new Map;return{emit(e,n){var r;null==(r=t.get(e))||r.forEach((t=>t(n)))},on(e,n){t.set(e,[...t.get(e)||[],n])},off(e,n){var r;t.set(e,(null==(r=t.get(e))?void 0:r.filter((t=>t!==n)))||[])}}}())),a=null!=fw(),[l,u]=On(r.reference),c=sw(((t,e,r)=>{o.current.openEvent=t?e:void 0,s.emit("openchange",{open:t,event:e,reason:r,nested:a}),null==n||n(t,e,r)})),d=jn((()=>({setPositionReference:u})),[]),h=jn((()=>({reference:l||r.reference||null,floating:r.floating||null,domReference:r.reference})),[l,r.reference,r.floating]);return jn((()=>({dataRef:o,open:e,onOpenChange:c,elements:h,events:s,floatingId:i,refs:d})),[e,c,h,s,i,d])}function yw(t){void 0===t&&(t={});const{nodeId:e}=t,n=gw({...t,elements:{reference:null,floating:null,...t.elements}}),r=t.rootContext||n,i=r.elements,[o,s]=On(null),[a,l]=On(null),u=(null==i?void 0:i.reference)||o,c=Dn(null),d=mw();aw((()=>{u&&(c.current=u)}),[u]);const h=function(t){void 0===t&&(t={});const{placement:e="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:a=!0,whileElementsMounted:l,open:u}=t,[c,d]=On({x:0,y:0,strategy:n,placement:e,middlewareData:{},isPositioned:!1}),[h,p]=On(r);Qb(h,r)||p(r);const[f,m]=On(null),[v,g]=On(null),y=In((t=>{t!==x.current&&(x.current=t,m(t))}),[]),_=In((t=>{t!==S.current&&(S.current=t,g(t))}),[]),b=o||f,w=s||v,x=Dn(null),S=Dn(null),E=Dn(c),k=null!=l,P=Jb(l),T=Jb(i),A=Jb(u),C=In((()=>{if(!x.current||!S.current)return;const t={placement:e,strategy:n,middleware:h};T.current&&(t.platform=T.current),Kb(x.current,S.current,t).then((t=>{const e={...t,isPositioned:!1!==A.current};R.current&&!Qb(E.current,e)&&(E.current=e,Ur((()=>{d(e)})))}))}),[h,e,n,T,A]);Yb((()=>{!1===u&&E.current.isPositioned&&(E.current.isPositioned=!1,d((t=>({...t,isPositioned:!1}))))}),[u]);const R=Dn(!1);Yb((()=>(R.current=!0,()=>{R.current=!1})),[]),Yb((()=>{if(b&&(x.current=b),w&&(S.current=w),b&&w){if(P.current)return P.current(b,w,C);C()}}),[b,w,C,P,k]);const O=jn((()=>({reference:x,floating:S,setReference:y,setFloating:_})),[y,_]),M=jn((()=>({reference:b,floating:w})),[b,w]),F=jn((()=>{const t={position:n,left:0,top:0};if(!M.floating)return t;const e=Zb(M.floating,c.x),r=Zb(M.floating,c.y);return a?{...t,transform:"translate("+e+"px, "+r+"px)",...Xb(M.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:e,top:r}}),[n,a,M.floating,c.x,c.y]);return jn((()=>({...c,update:C,refs:O,elements:M,floatingStyles:F})),[c,C,O,M,F])}({...t,elements:{...i,...a&&{reference:a}}}),p=In((t=>{const e=q_(t)?{getBoundingClientRect:()=>t.getBoundingClientRect(),contextElement:t}:t;l(e),h.refs.setReference(e)}),[h.refs]),f=In((t=>{(q_(t)||null===t)&&(c.current=t,s(t)),(q_(h.refs.reference.current)||null===h.refs.reference.current||null!==t&&!q_(t))&&h.refs.setReference(t)}),[h.refs]),m=jn((()=>({...h.refs,setReference:f,setPositionReference:p,domReference:c})),[h.refs,f,p]),v=jn((()=>({...h.elements,domReference:u})),[h.elements,u]),g=jn((()=>({...h,...r,refs:m,elements:v,nodeId:e})),[h,m,v,e,r]);return aw((()=>{r.dataRef.current.floatingContext=g;const t=null==d?void 0:d.nodesRef.current.find((t=>t.id===e));t&&(t.context=g)})),jn((()=>({...h,context:g,refs:m,elements:v})),[h,m,v,g])}const _w="active",bw="selected";function ww(t,e,n){const r=new Map,i="item"===n;let o=t;if(i&&t){const{[_w]:e,[bw]:n,...r}=t;o=r}return{..."floating"===n&&{tabIndex:-1,[vw]:""},...o,...e.map((e=>{const r=e?e[n]:null;return"function"==typeof r?t?r(t):null:r})).concat(t).reduce(((t,e)=>e?(Object.entries(e).forEach((e=>{let[n,o]=e;var s;i&&[_w,bw].includes(n)||(0===n.indexOf("on")?(r.has(n)||r.set(n,[]),"function"==typeof o&&(null==(s=r.get(n))||s.push(o),t[n]=function(){for(var t,e=arguments.length,i=new Array(e),o=0;o<e;o++)i[o]=arguments[o];return null==(t=r.get(n))?void 0:t.map((t=>t(...i))).find((t=>void 0!==t))})):t[n]=o)})),t):t),{})}}function xw(t,e){return{...t,rects:{...t.rects,floating:{...t.rects.floating,height:e}}}}const Sw=t=>({name:"inner",options:t,async fn(e){const{listRef:n,overflowRef:r,onFallbackChange:i,offset:o=0,index:s=0,minItemsVisible:a=4,referenceOverflowThreshold:l=0,scrollRef:u,...c}=vb(t,e),{rects:d,elements:{floating:h}}=e,p=n.current[s],f=(null==u?void 0:u.current)||h,m=h.clientTop||f.clientTop,v=0!==h.clientTop,g=0!==f.clientTop,y=h===f;if(!p)return{};const _={...e,...await tw(-p.offsetTop-h.clientTop-d.reference.height/2-p.offsetHeight/2-o).fn(e)},b=await Wb(xw(_,f.scrollHeight+m+h.clientTop),c),w=await Wb(_,{...c,elementContext:"reference"}),x=ub(0,b.top),S=_.y+x,E=cb(ub(0,f.scrollHeight+(v&&y||g?2*m:0)-x-ub(0,b.bottom)));if(f.style.maxHeight=E+"px",f.scrollTop=x,i){const t=f.scrollHeight>f.offsetHeight&&f.offsetHeight<p.offsetHeight*a-1||w.top>=-l||w.bottom>=-l;Ur((()=>i(t)))}return r&&(r.current=await Wb(xw({..._,y:S},f.offsetHeight+m+h.clientTop),c)),{y:S}}});function Ew(t,e){const{open:n,elements:r}=t,{enabled:i=!0,overflowRef:o,scrollRef:s,onChange:a}=e,l=sw(a),u=Dn(!1),c=Dn(null),d=Dn(null);Fn((()=>{if(!i)return;function t(t){if(t.ctrlKey||!e||null==o.current)return;const n=t.deltaY,r=o.current.top>=-.5,i=o.current.bottom>=-.5,s=e.scrollHeight-e.clientHeight,a=n<0?-1:1,u=n<0?"max":"min";e.scrollHeight<=e.clientHeight||(!r&&n>0||!i&&n<0?(t.preventDefault(),Ur((()=>{l((t=>t+Math[u](n,s*a)))}))):/firefox/i.test(function(){const t=navigator.userAgentData;return t&&Array.isArray(t.brands)?t.brands.map((t=>{let{brand:e,version:n}=t;return e+"/"+n})).join(" "):navigator.userAgent}())&&(e.scrollTop+=n))}const e=(null==s?void 0:s.current)||r.floating;return n&&e?(e.addEventListener("wheel",t),requestAnimationFrame((()=>{c.current=e.scrollTop,null!=o.current&&(d.current={...o.current})})),()=>{c.current=null,d.current=null,e.removeEventListener("wheel",t)}):void 0}),[i,n,r.floating,o,s,l]);const h=jn((()=>({onKeyDown(){u.current=!0},onWheel(){u.current=!1},onPointerMove(){u.current=!1},onScroll(){const t=(null==s?void 0:s.current)||r.floating;if(o.current&&t&&u.current){if(null!==c.current){const e=t.scrollTop-c.current;(o.current.bottom<-.5&&e<-1||o.current.top<-.5&&e>1)&&Ur((()=>l((t=>t+e))))}requestAnimationFrame((()=>{c.current=t.scrollTop}))}}})),[r.floating,l,o,s]);return jn((()=>i?{floating:h}:{}),[i,h])}let kw=oe({styles:void 0,setReference:()=>{},setFloating:()=>{},getReferenceProps:()=>({}),getFloatingProps:()=>({}),slot:{}});kw.displayName="FloatingContext";let Pw=oe(null);Pw.displayName="PlacementContext";let Tw=4;function Aw({children:t,enabled:e=!0}){let[n,r]=On(null),[i,o]=On(0),s=Dn(null),[a,l]=On(null);!function(t){ty((()=>{if(!t)return;let e=new MutationObserver((()=>{let e=window.getComputedStyle(t).maxHeight,n=parseFloat(e);if(isNaN(n))return;let r=parseInt(e);isNaN(r)||n!==r&&(t.style.maxHeight=`${Math.ceil(n)}px`)}));return e.observe(t,{attributes:!0,attributeFilter:["style"]}),()=>{e.disconnect()}}),[t])}(a);let u=e&&null!==n&&null!==a,{to:c="bottom",gap:d=0,offset:h=0,padding:p=0,inner:f}=function(t,e){var n,r,i;let o=Cw(null!=(n=null==t?void 0:t.gap)?n:"var(--anchor-gap, 0)",e),s=Cw(null!=(r=null==t?void 0:t.offset)?r:"var(--anchor-offset, 0)",e),a=Cw(null!=(i=null==t?void 0:t.padding)?i:"var(--anchor-padding, 0)",e);return{...t,gap:o,offset:s,padding:a}}(n,a),[m,v="center"]=c.split(" ");ty((()=>{u&&o(0)}),[u]);let{refs:g,floatingStyles:y,context:_}=yw({open:u,placement:"selection"===m?"center"===v?"bottom":`bottom-${v}`:"center"===v?`${m}`:`${m}-${v}`,strategy:"absolute",transform:!1,middleware:[tw({mainAxis:"selection"===m?0:d,crossAxis:h}),ew({padding:p}),"selection"!==m&&nw({padding:p}),"selection"===m&&f?Sw({...f,padding:p,overflowRef:s,offset:i,minItemsVisible:Tw,referenceOverflowThreshold:p,onFallbackChange(t){var e,n;if(!t)return;let r=_.elements.floating;if(!r)return;let i=parseFloat(getComputedStyle(r).scrollPaddingBottom)||0,s=Math.min(Tw,r.childElementCount),a=0,l=0;for(let o of null!=(n=null==(e=_.elements.floating)?void 0:e.childNodes)?n:[])if(o instanceof HTMLElement){let t=o.offsetTop,e=t+o.clientHeight+i,n=r.scrollTop,u=n+r.clientHeight;if(!(t>=n&&e<=u)){l=Math.max(0,Math.min(e,u)-Math.max(t,n)),a=o.clientHeight;break}s--}s>=1&&o((t=>{let e=a*s-l+i;return t>=e?t:e}))}}):null,rw({padding:p,apply({availableWidth:t,availableHeight:e,elements:n}){Object.assign(n.floating.style,{overflow:"auto",maxWidth:`${t}px`,maxHeight:`min(var(--anchor-max-height, 100vh), ${e}px)`})}})].filter(Boolean),whileElementsMounted:Ub}),[b=m,w=v]=_.placement.split("-");"selection"===m&&(b="selection");let x=jn((()=>({anchor:[b,w].filter(Boolean).join(" ")})),[b,w]),S=Ew(_,{overflowRef:s,onChange:o}),{getReferenceProps:E,getFloatingProps:k}=function(t){void 0===t&&(t=[]);const e=t.map((t=>null==t?void 0:t.reference)),n=t.map((t=>null==t?void 0:t.floating)),r=t.map((t=>null==t?void 0:t.item)),i=In((e=>ww(e,t,"reference")),e),o=In((e=>ww(e,t,"floating")),n),s=In((e=>ww(e,t,"item")),r);return jn((()=>({getReferenceProps:i,getFloatingProps:o,getItemProps:s})),[i,o,s])}([S]),P=ny((t=>{l(t),g.setFloating(t)}));return Dt(Pw.Provider,{value:r},Dt(kw.Provider,{value:{setFloating:P,setReference:g.setReference,styles:y,getReferenceProps:E,getFloatingProps:k,slot:x}},t))}function Cw(t,e,n=void 0){let r=Jg(),i=ny(((t,e)=>{if(null==t)return[n,null];if("number"==typeof t)return[t,null];if("string"==typeof t){if(!e)return[n,null];let i=Ow(t,e);return[i,n=>{let o=Rw(t);{let s=o.map((t=>window.getComputedStyle(e).getPropertyValue(t)));r.requestAnimationFrame((function a(){r.nextFrame(a);let l=!1;for(let[t,n]of o.entries()){let r=window.getComputedStyle(e).getPropertyValue(n);if(s[t]!==r){s[t]=r,l=!0;break}}if(!l)return;let u=Ow(t,e);i!==u&&(n(u),i=u)}))}return r.dispose}]}return[n,null]})),o=jn((()=>i(t,e)[0]),[t,e]),[s=o,a]=On();return ty((()=>{let[n,r]=i(t,e);if(a(n),r)return r(a)}),[t,e]),s}function Rw(t){let e=/var\((.*)\)/.exec(t);if(e){let t=e[1].indexOf(",");if(-1===t)return[e[1]];let n=e[1].slice(0,t).trim(),r=e[1].slice(t+1).trim();return r?[n,...Rw(r)]:[n]}return[]}function Ow(t,e){let n=document.createElement("div");e.appendChild(n),n.style.setProperty("margin-top","0px","important"),n.style.setProperty("margin-top",t,"important");let r=parseFloat(window.getComputedStyle(n).marginTop)||0;return e.removeChild(n),r}let Mw=oe(null);Mw.displayName="OpenClosedContext";var Fw=(t=>(t[t.Open=1]="Open",t[t.Closed=2]="Closed",t[t.Closing=4]="Closing",t[t.Opening=8]="Opening",t))(Fw||{});function Lw(){return Bn(Mw)}function Dw({value:t,children:e}){return Xr.createElement(Mw.Provider,{value:t},e)}var Vw,jw=((Vw=jw||{})[Vw.First=0]="First",Vw[Vw.Previous=1]="Previous",Vw[Vw.Next=2]="Next",Vw[Vw.Last=3]="Last",Vw[Vw.Specific=4]="Specific",Vw[Vw.Nothing=5]="Nothing",Vw);function Iw(t,e){let n=e.resolveItems();if(n.length<=0)return null;let r=e.resolveActiveIndex(),i=null!=r?r:-1;switch(t.focus){case 0:for(let t=0;t<n.length;++t)if(!e.resolveDisabled(n[t],t,n))return t;return r;case 1:-1===i&&(i=n.length);for(let t=i-1;t>=0;--t)if(!e.resolveDisabled(n[t],t,n))return t;return r;case 2:for(let t=i+1;t<n.length;++t)if(!e.resolveDisabled(n[t],t,n))return t;return r;case 3:for(let t=n.length-1;t>=0;--t)if(!e.resolveDisabled(n[t],t,n))return t;return r;case 4:for(let r=0;r<n.length;++r)if(e.resolveId(n[r],r,n)===t.id)return r;return r;case 5:return null;default:!function(t){throw new Error("Unexpected object: "+t)}(t)}}function Bw(){let t=function(){let t="undefined"==typeof document;return"useSyncExternalStore"in Zr&&(t=>t.useSyncExternalStore)(Zr)((()=>()=>{}),(()=>!1),(()=>!t))}(),[e,n]=On(Yg.isHandoffComplete);return e&&!1===Yg.isHandoffComplete&&n(!1),Fn((()=>{!0!==e&&n(!0)}),[e]),Fn((()=>Yg.handoff()),[]),!t&&e}let Nw=oe(!1);function Gw(t){let e=Bn(Nw),n=Bn($w),r=O_(t),[i,o]=On((()=>{var t;if(!e&&null!==n)return null!=(t=n.current)?t:null;if(Yg.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 Fn((()=>{null!==i&&(null!=r&&r.body.contains(i)||null==r||r.body.appendChild(i))}),[i,r]),Fn((()=>{e||null!==n&&o(n.current)}),[n,o,e]),i}let Uw=It,Ww=yy((function(t,e){let n=t,r=Dn(null),i=By(function(t,e=!0){return Object.assign(t,{[Iy]:e})}((t=>{r.current=t})),e),o=O_(r),s=Gw(r),[a]=On((()=>{var t;return Yg.isServer?null:null!=(t=null==o?void 0:o.createElement("div"))?t:null})),l=Bn(zw),u=Bw();return ty((()=>{!s||!a||s.contains(a)||(a.setAttribute("data-headlessui-portal",""),s.appendChild(a))}),[s,a]),ty((()=>{if(a&&l)return l.register(a)}),[l,a]),function(t){let e=ny(t),n=Dn(!1);Fn((()=>(n.current=!1,()=>{n.current=!0,Xg((()=>{n.current&&e()}))})),[e])}((()=>{var t;!s||!a||(a instanceof Node&&s.contains(a)&&s.removeChild(a),s.childNodes.length<=0&&(null==(t=s.parentElement)||t.removeChild(s)))})),u&&s&&a?mr(py({ourProps:{ref:i},theirProps:n,slot:{},defaultTag:Uw,name:"Portal"}),a):null}));let Hw=It,$w=oe(null);let zw=oe(null),qw=yy((function(t,e){let n=By(e),{enabled:r=!0,...i}=t;return r?Xr.createElement(Ww,{...i,ref:n}):py({ourProps:{ref:n},theirProps:i,slot:{},defaultTag:Uw,name:"Portal"})})),Kw=yy((function(t,e){let{target:n,...r}=t,i={ref:By(e)};return Xr.createElement($w.Provider,{value:n},py({ourProps:i,theirProps:r,defaultTag:Hw,name:"Popover.Group"}))})),Yw=Object.assign(qw,{Group:Kw});function Qw(t){var e;return!!(t.enter||t.enterFrom||t.enterTo||t.leave||t.leaveFrom||t.leaveTo)||(null!=(e=t.as)?e:nx)!==It||1===Xr.Children.count(t.children)}let Xw=oe(null);Xw.displayName="TransitionContext";var Zw=(t=>(t.Visible="visible",t.Hidden="hidden",t))(Zw||{});let Jw=oe(null);function tx(t){return"children"in t?tx(t.children):t.current.filter((({el:t})=>null!==t.current)).filter((({state:t})=>"visible"===t)).length>0}function ex(t,e){let n=ey(t),r=Dn([]),i=function(){let t=Dn(!1);return ty((()=>(t.current=!0,()=>{t.current=!1})),[]),t}(),o=Jg(),s=ny(((t,e=hy.Hidden)=>{let s=r.current.findIndex((({el:e})=>e===t));-1!==s&&(ly(e,{[hy.Unmount](){r.current.splice(s,1)},[hy.Hidden](){r.current[s].state="hidden"}}),o.microTask((()=>{var t;!tx(r)&&i.current&&(null==(t=n.current)||t.call(n))})))})),a=ny((t=>{let e=r.current.find((({el:e})=>e===t));return e?"visible"!==e.state&&(e.state="visible"):r.current.push({el:t,state:"visible"}),()=>s(t,hy.Unmount)})),l=Dn([]),u=Dn(Promise.resolve()),c=Dn({enter:[],leave:[]}),d=ny(((t,n,r)=>{l.current.splice(0),e&&(e.chains.current[n]=e.chains.current[n].filter((([e])=>e!==t))),null==e||e.chains.current[n].push([t,new Promise((t=>{l.current.push(t)}))]),null==e||e.chains.current[n].push([t,new Promise((t=>{Promise.all(c.current[n].map((([t,e])=>e))).then((()=>t()))}))]),"enter"===n?u.current=u.current.then((()=>null==e?void 0:e.wait.current)).then((()=>r(n))):r(n)})),h=ny(((t,e,n)=>{Promise.all(c.current[e].splice(0).map((([t,e])=>e))).then((()=>{var t;null==(t=l.current.shift())||t()})).then((()=>n(e)))}));return jn((()=>({children:r,register:a,unregister:s,onStart:d,onStop:h,wait:u,chains:c})),[a,s,r,d,h,c,u])}Jw.displayName="NestingContext";let nx=It,rx=dy.RenderStrategy;let ix=yy((function(t,e){let{show:n,appear:r=!1,unmount:i=!0,...o}=t,s=Dn(null),a=By(...Qw(t)?[s,e]:null===e?[]:[e]);Bw();let l=Lw();if(void 0===n&&null!==l&&(n=(l&Fw.Open)===Fw.Open),void 0===n)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[u,c]=On(n?"visible":"hidden"),d=ex((()=>{n||c("hidden")})),[h,p]=On(!0),f=Dn([n]);ty((()=>{!1!==h&&f.current[f.current.length-1]!==n&&(f.current.push(n),p(!1))}),[f,n]);let m=jn((()=>({show:n,appear:r,initial:h})),[n,r,h]);ty((()=>{n?c("visible"):!tx(d)&&null!==s.current&&c("hidden")}),[n,d]);let v={unmount:i},g=ny((()=>{var e;h&&p(!1),null==(e=t.beforeEnter)||e.call(t)})),y=ny((()=>{var e;h&&p(!1),null==(e=t.beforeLeave)||e.call(t)}));return Xr.createElement(Jw.Provider,{value:d},Xr.createElement(Xw.Provider,{value:m},py({ourProps:{...v,as:It,children:Xr.createElement(ox,{ref:a,...v,...o,beforeEnter:g,beforeLeave:y})},theirProps:{},defaultTag:It,features:rx,visible:"visible"===u,name:"Transition"})))})),ox=yy((function(t,e){var n,r;let{transition:i=!0,beforeEnter:o,afterEnter:s,beforeLeave:a,afterLeave:l,enter:u,enterFrom:c,enterTo:d,entered:h,leave:p,leaveFrom:f,leaveTo:m,...v}=t,[g,y]=On(null),_=Dn(null),b=Qw(t),w=By(...b?[_,e,y]:null===e?[]:[e]),x=null==(n=v.unmount)||n?hy.Unmount:hy.Hidden,{show:S,appear:E,initial:k}=function(){let t=Bn(Xw);if(null===t)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return t}(),[P,T]=On(S?"visible":"hidden"),A=function(){let t=Bn(Jw);if(null===t)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return t}(),{register:C,unregister:R}=A;ty((()=>C(_)),[C,_]),ty((()=>{if(x===hy.Hidden&&_.current)return S&&"visible"!==P?void T("visible"):ly(P,{hidden:()=>R(_),visible:()=>C(_)})}),[P,_,C,R,S,x]);let O=Bw();ty((()=>{if(b&&O&&"visible"===P&&null===_.current)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")}),[_,P,O,b]);let M=k&&!E,F=E&&S&&k,L=Dn(!1),D=ex((()=>{L.current||(T("hidden"),R(_))}),A),V=ny((t=>{L.current=!0;let e=t?"enter":"leave";D.onStart(_,e,(t=>{"enter"===t?null==o||o():"leave"===t&&(null==a||a())}))})),j=ny((t=>{let e=t?"enter":"leave";L.current=!1,D.onStop(_,e,(t=>{"enter"===t?null==s||s():"leave"===t&&(null==l||l())})),"leave"===e&&!tx(D)&&(T("hidden"),R(_))}));Fn((()=>{b&&i||(V(S),j(S))}),[S,b,i]);let I=(()=>!(!i||!b||!O||M))(),[,B]=G_(I,g,S,{start:V,end:j}),N=_y({ref:w,className:(null==(r=ay(v.className,F&&u,F&&c,B.enter&&u,B.enter&&B.closed&&c,B.enter&&!B.closed&&d,B.leave&&p,B.leave&&!B.closed&&f,B.leave&&B.closed&&m,!B.transition&&S&&h))?void 0:r.trim())||void 0,...N_(B)}),G=0;return"visible"===P&&(G|=Fw.Open),"hidden"===P&&(G|=Fw.Closed),B.enter&&(G|=Fw.Opening),B.leave&&(G|=Fw.Closing),Xr.createElement(Jw.Provider,{value:D},Xr.createElement(Dw,{value:G},py({ourProps:N,theirProps:v,defaultTag:nx,features:rx,visible:"visible"===P,name:"Transition.Child"})))})),sx=yy((function(t,e){let n=null!==Bn(Xw),r=null!==Lw();return Xr.createElement(Xr.Fragment,null,!n&&r?Xr.createElement(ix,{ref:e,...t}):Xr.createElement(ox,{ref:e,...t}))})),ax=Object.assign(ix,{Child:sx,Root:ix});let lx=yy((function(t,e){let n=`headlessui-control-${Gn()}`,[r,i]=Xy(),[o,s]=Wy(),a=oy(),{disabled:l=a||!1,...u}=t,c=jn((()=>({disabled:l})),[l]);return Xr.createElement(sy,{value:l},Xr.createElement(i,{value:r},Xr.createElement(s,{value:o},Xr.createElement(Vy,{id:n},py({ourProps:{ref:e,disabled:l||void 0,"aria-disabled":l||void 0},theirProps:{...u,children:Xr.createElement(Ry,null,"function"==typeof u.children?u.children(c):u.children)},slot:c,defaultTag:"div",name:"Field"})))))}));let ux=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;function cx(t){var e,n;let r=null!=(e=t.innerText)?e:"",i=t.cloneNode(!0);if(!(i instanceof HTMLElement))return r;let o=!1;for(let a of i.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))a.remove(),o=!0;let s=o?null!=(n=i.innerText)?n:"":r;return ux.test(s)&&(s=s.replace(ux,"")),s}function dx(t){let e=Dn(""),n=Dn("");return ny((()=>{let r=t.current;if(!r)return"";let i=r.innerText;if(e.current===i)return n.current;let o=function(t){let e=t.getAttribute("aria-label");if("string"==typeof e)return e.trim();let n=t.getAttribute("aria-labelledby");if(n){let t=n.split(" ").map((t=>{let e=document.getElementById(t);if(e){let t=e.getAttribute("aria-label");return"string"==typeof t?t.trim():cx(e).trim()}return null})).filter(Boolean);if(t.length>0)return t.join(", ")}return cx(t).trim()}(r).trim().toLowerCase();return e.current=i,n.current=o,o}))}var hx=(t=>(t[t.Open=0]="Open",t[t.Closed=1]="Closed",t))(hx||{}),px=(t=>(t[t.Single=0]="Single",t[t.Multi=1]="Multi",t))(px||{}),fx=(t=>(t[t.Pointer=0]="Pointer",t[t.Other=1]="Other",t))(fx||{}),mx=(t=>(t[t.OpenListbox=0]="OpenListbox",t[t.CloseListbox=1]="CloseListbox",t[t.GoToOption=2]="GoToOption",t[t.Search=3]="Search",t[t.ClearSearch=4]="ClearSearch",t[t.RegisterOption=5]="RegisterOption",t[t.UnregisterOption=6]="UnregisterOption",t[t.SetButtonElement=7]="SetButtonElement",t[t.SetOptionsElement=8]="SetOptionsElement",t))(mx||{});function vx(t,e=t=>t){let n=null!==t.activeOptionIndex?t.options[t.activeOptionIndex]:null,r=E_(e(t.options.slice()),(t=>t.dataRef.current.domRef.current)),i=n?r.indexOf(n):null;return-1===i&&(i=null),{options:r,activeOptionIndex:i}}let gx={1:t=>t.dataRef.current.disabled||1===t.listboxState?t:{...t,activeOptionIndex:null,listboxState:1,__demoMode:!1},0(t){if(t.dataRef.current.disabled||0===t.listboxState)return t;let e=t.activeOptionIndex,{isSelected:n}=t.dataRef.current,r=t.options.findIndex((t=>n(t.dataRef.current.value)));return-1!==r&&(e=r),{...t,listboxState:0,activeOptionIndex:e,__demoMode:!1}},2(t,e){var n,r,i,o,s;if(t.dataRef.current.disabled||1===t.listboxState)return t;let a={...t,searchQuery:"",activationTrigger:null!=(n=e.trigger)?n:1,__demoMode:!1};if(e.focus===jw.Nothing)return{...a,activeOptionIndex:null};if(e.focus===jw.Specific)return{...a,activeOptionIndex:t.options.findIndex((t=>t.id===e.id))};if(e.focus===jw.Previous){let n=t.activeOptionIndex;if(null!==n){let o=t.options[n].dataRef.current.domRef,s=Iw(e,{resolveItems:()=>t.options,resolveActiveIndex:()=>t.activeOptionIndex,resolveId:t=>t.id,resolveDisabled:t=>t.dataRef.current.disabled});if(null!==s){let e=t.options[s].dataRef.current.domRef;if((null==(r=o.current)?void 0:r.previousElementSibling)===e.current||null===(null==(i=e.current)?void 0:i.previousElementSibling))return{...a,activeOptionIndex:s}}}}else if(e.focus===jw.Next){let n=t.activeOptionIndex;if(null!==n){let r=t.options[n].dataRef.current.domRef,i=Iw(e,{resolveItems:()=>t.options,resolveActiveIndex:()=>t.activeOptionIndex,resolveId:t=>t.id,resolveDisabled:t=>t.dataRef.current.disabled});if(null!==i){let e=t.options[i].dataRef.current.domRef;if((null==(o=r.current)?void 0:o.nextElementSibling)===e.current||null===(null==(s=e.current)?void 0:s.nextElementSibling))return{...a,activeOptionIndex:i}}}}let l=vx(t),u=Iw(e,{resolveItems:()=>l.options,resolveActiveIndex:()=>l.activeOptionIndex,resolveId:t=>t.id,resolveDisabled:t=>t.dataRef.current.disabled});return{...a,...l,activeOptionIndex:u}},3:(t,e)=>{if(t.dataRef.current.disabled||1===t.listboxState)return t;let n=""!==t.searchQuery?0:1,r=t.searchQuery+e.value.toLowerCase(),i=(null!==t.activeOptionIndex?t.options.slice(t.activeOptionIndex+n).concat(t.options.slice(0,t.activeOptionIndex+n)):t.options).find((t=>{var e;return!t.dataRef.current.disabled&&(null==(e=t.dataRef.current.textValue)?void 0:e.startsWith(r))})),o=i?t.options.indexOf(i):-1;return-1===o||o===t.activeOptionIndex?{...t,searchQuery:r}:{...t,searchQuery:r,activeOptionIndex:o,activationTrigger:1}},4:t=>t.dataRef.current.disabled||1===t.listboxState||""===t.searchQuery?t:{...t,searchQuery:""},5:(t,e)=>{let n={id:e.id,dataRef:e.dataRef},r=vx(t,(t=>[...t,n]));return null===t.activeOptionIndex&&t.dataRef.current.isSelected(e.dataRef.current.value)&&(r.activeOptionIndex=r.options.indexOf(n)),{...t,...r}},6:(t,e)=>{let n=vx(t,(t=>{let n=t.findIndex((t=>t.id===e.id));return-1!==n&&t.splice(n,1),t}));return{...t,...n,activationTrigger:1}},7:(t,e)=>t.buttonElement===e.element?t:{...t,buttonElement:e.element},8:(t,e)=>t.optionsElement===e.element?t:{...t,optionsElement:e.element}},yx=oe(null);function _x(t){let e=Bn(yx);if(null===e){let e=new Error(`<${t} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(e,_x),e}return e}yx.displayName="ListboxActionsContext";let bx=oe(null);function wx(t){let e=Bn(bx);if(null===e){let e=new Error(`<${t} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(e,wx),e}return e}function xx(t,e){return ly(e.type,gx,t,e)}bx.displayName="ListboxDataContext";let Sx=It;let Ex=oe(!1),kx=dy.RenderStrategy|dy.Static;let Px=It;let Tx=yy((function(t,e){var n;let r=oy(),{value:i,defaultValue:o,form:s,name:a,onChange:l,by:u,invalid:c=!1,disabled:d=r||!1,horizontal:h=!1,multiple:p=!1,__demoMode:f=!1,...m}=t;const v=h?"horizontal":"vertical";let g=By(e),y=xy(o),[_=(p?[]:void 0),b]=wy(i,l,y),[w,x]=Mn(xx,{dataRef:{current:null},listboxState:f?0:1,options:[],searchQuery:"",activeOptionIndex:null,activationTrigger:1,optionsVisible:!1,buttonElement:null,optionsElement:null,__demoMode:f}),S=Dn({static:!1,hold:!1}),E=Dn(new Map),k=function(t=t_){return In(((e,n)=>{if("string"==typeof t){let r=t;return(null==e?void 0:e[r])===(null==n?void 0:n[r])}return t(e,n)}),[t])}(u),P=In((t=>ly(T.mode,{1:()=>_.some((e=>k(e,t))),0:()=>k(_,t)})),[_]),T=jn((()=>({...w,value:_,disabled:d,invalid:c,mode:p?1:0,orientation:v,compare:k,isSelected:P,optionsPropsRef:S,listRef:E})),[_,d,c,p,w,E]);ty((()=>{w.dataRef.current=T}),[T]),R_(0===T.listboxState,[T.buttonElement,T.optionsElement],((t,e)=>{var n;x({type:1}),w_(e,b_.Loose)||(t.preventDefault(),null==(n=T.buttonElement)||n.focus())}));let A=jn((()=>({open:0===T.listboxState,disabled:d,invalid:c,value:_})),[T,d,_,c]),C=ny((t=>{let e=T.options.find((e=>e.id===t));e&&V(e.dataRef.current.value)})),R=ny((()=>{if(null!==T.activeOptionIndex){let{dataRef:t,id:e}=T.options[T.activeOptionIndex];V(t.current.value),x({type:2,focus:jw.Specific,id:e})}})),O=ny((()=>x({type:0}))),M=ny((()=>x({type:1}))),F=Jg(),L=ny(((t,e,n)=>{F.dispose(),F.microTask((()=>t===jw.Specific?x({type:2,focus:jw.Specific,id:e,trigger:n}):x({type:2,focus:t,trigger:n})))})),D=ny(((t,e)=>(x({type:5,id:t,dataRef:e}),()=>x({type:6,id:t})))),V=ny((t=>ly(T.mode,{0:()=>null==b?void 0:b(t),1(){let e=T.value.slice(),n=e.findIndex((e=>k(e,t)));return-1===n?e.push(t):e.splice(n,1),null==b?void 0:b(e)}}))),j=ny((t=>x({type:3,value:t}))),I=ny((()=>x({type:4}))),B=ny((t=>{x({type:7,element:t})})),N=ny((t=>{x({type:8,element:t})})),G=jn((()=>({onChange:V,registerOption:D,goToOption:L,closeListbox:M,openListbox:O,selectActiveOption:R,selectOption:C,search:j,clearSearch:I,setButtonElement:B,setOptionsElement:N})),[]),[U,W]=Xy({inherit:!0}),H={ref:g},$=In((()=>{if(void 0!==y)return null==b?void 0:b(y)}),[b,y]);return Xr.createElement(W,{value:U,props:{htmlFor:null==(n=T.buttonElement)?void 0:n.id},slot:{open:0===T.listboxState,disabled:d}},Xr.createElement(Aw,null,Xr.createElement(yx.Provider,{value:G},Xr.createElement(bx.Provider,{value:T},Xr.createElement(Dw,{value:ly(T.listboxState,{0:Fw.Open,1:Fw.Closed})},null!=a&&null!=_&&Xr.createElement(My,{disabled:d,data:{[a]:_},form:s,onReset:$}),py({ourProps:H,theirProps:m,slot:A,defaultTag:Sx,name:"Listbox"}))))))})),Ax=yy((function(t,e){var n;let r=wx("Listbox.Button"),i=_x("Listbox.Button"),o=Gn(),s=Dy(),{id:a=s||`headlessui-listbox-button-${o}`,disabled:l=r.disabled||!1,autoFocus:u=!1,...c}=t,d=function(){let t=Dn([]),e=In((e=>{for(let n of t.current)null!=n&&("function"==typeof n?n(e):n.current=e)}),[]);return(...n)=>{if(!n.every((t=>null==t)))return t.current=n,e}}(),h=By(e,Bn(kw).setReference,i.setButtonElement),p=Bn(kw).getReferenceProps,f=ny((t=>{switch(t.key){case qy.Enter:Py(t.currentTarget);break;case qy.Space:case qy.ArrowDown:t.preventDefault(),Ur((()=>i.openListbox())),r.value||i.goToOption(jw.First);break;case qy.ArrowUp:t.preventDefault(),Ur((()=>i.openListbox())),r.value||i.goToOption(jw.Last)}})),m=ny((t=>{if(t.key===qy.Space)t.preventDefault()})),v=ny((t=>{var e;if(jy(t.currentTarget))return t.preventDefault();0===r.listboxState?(Ur((()=>i.closeListbox())),null==(e=r.buttonElement)||e.focus({preventScroll:!0})):(t.preventDefault(),i.openListbox())})),g=ny((t=>t.preventDefault())),y=Qy([a]),_=Uy(),{isFocusVisible:b,focusProps:w}=zg({autoFocus:u}),{isHovered:x,hoverProps:S}=$g({isDisabled:l}),{pressed:E,pressProps:k}=ry({disabled:l}),P=jn((()=>({open:0===r.listboxState,active:E||0===r.listboxState,disabled:l,invalid:r.invalid,value:r.value,hover:x,focus:b,autofocus:u})),[r.listboxState,r.value,l,x,b,E,r.invalid,u]);return py({mergeRefs:d,ourProps:gy(p(),{ref:h,id:a,type:M_(t,r.buttonElement),"aria-haspopup":"listbox","aria-controls":null==(n=r.optionsElement)?void 0:n.id,"aria-expanded":0===r.listboxState,"aria-labelledby":y,"aria-describedby":_,disabled:l||void 0,autoFocus:u,onKeyDown:f,onKeyUp:m,onKeyPress:g,onClick:v},w,S,k),theirProps:c,slot:P,defaultTag:"button",name:"Listbox.Button"})})),Cx=Jy,Rx=yy((function(t,e){var n,r;let i=Gn(),{id:o=`headlessui-listbox-options-${i}`,anchor:s,portal:a=!1,modal:l=!0,transition:u=!1,...c}=t,d=function(t){return jn((()=>t?"string"==typeof t?{to:t}:t:null),[t])}(s),[h,p]=On(null);d&&(a=!0);let f=wx("Listbox.Options"),m=_x("Listbox.Options"),v=O_(f.optionsElement),g=Lw(),[y,_]=G_(u,h,null!==g?(g&Fw.Open)===Fw.Open:0===f.listboxState);!function(t,e,n){let r=ey((t=>{let e=t.getBoundingClientRect();0===e.x&&0===e.y&&0===e.width&&0===e.height&&n()}));Fn((()=>{if(!t)return;let n=null===e?null:e instanceof HTMLElement?e:e.current;if(!n)return;let i=Zg();if("undefined"!=typeof ResizeObserver){let t=new ResizeObserver((()=>r.current(n)));t.observe(n),i.add((()=>t.disconnect()))}if("undefined"!=typeof IntersectionObserver){let t=new IntersectionObserver((()=>r.current(n)));t.observe(n),i.add((()=>t.disconnect()))}return()=>i.dispose()}),[e,r,t])}(y,f.buttonElement,m.closeListbox),V_(!f.__demoMode&&(l&&0===f.listboxState),v),function(t,{allowed:e,disallowed:n}={}){let r=s_(t,"inert-others");ty((()=>{var t,i;if(!r)return;let o=Zg();for(let e of null!=(t=null==n?void 0:n())?t:[])e&&o.add(u_(e));let s=null!=(i=null==e?void 0:e())?i:[];for(let e of s){if(!e)continue;let t=Qg(e);if(!t)continue;let n=e.parentElement;for(;n&&n!==t.body;){for(let t of n.children)s.some((e=>t.contains(e)))||o.add(u_(t));n=n.parentElement}}return o.dispose}),[r,e,n])}(!f.__demoMode&&(l&&0===f.listboxState),{allowed:In((()=>[f.buttonElement,f.optionsElement]),[f.buttonElement,f.optionsElement])});let b=!function(t,e){let n=Dn({left:0,top:0});if(ty((()=>{if(!e)return;let t=e.getBoundingClientRect();t&&(n.current=t)}),[t,e]),null==e||!t||e===document.activeElement)return!1;let r=e.getBoundingClientRect();return r.top!==n.current.top||r.left!==n.current.left}(0!==f.listboxState,f.buttonElement)&&y,w=function(t,e){let[n,r]=On(e);return!t&&n!==e&&r(e),t?n:e}(y&&1===f.listboxState,f.value),x=ny((t=>f.compare(w,t))),S=jn((()=>{var t;if(null==d||null==(t=null==d?void 0:d.to)||!t.includes("selection"))return null;let e=f.options.findIndex((t=>x(t.dataRef.current.value)));return-1===e&&(e=0),e}),[d,f.options]),E=(()=>{if(null==d)return;if(null===S)return{...d,inner:void 0};let t=Array.from(f.listRef.current.values());return{...d,inner:{listRef:{current:t},index:S}}})(),[k,P]=function(t=null){!1===t&&(t=null),"string"==typeof t&&(t={to:t});let e=Bn(Pw),n=jn((()=>t),[JSON.stringify(t,"undefined"!=typeof HTMLElement?(t,e)=>e instanceof HTMLElement?e.outerHTML:e:void 0)]);ty((()=>{null==e||e(null!=n?n:null)}),[e,n]);let r=Bn(kw);return jn((()=>[r.setFloating,t?r.styles:{}]),[r.setFloating,t,r.styles])}(E),T=function(){let{getFloatingProps:t,slot:e}=Bn(kw);return In(((...n)=>Object.assign({},t(...n),{"data-anchor":e.anchor})),[t,e])}(),A=By(e,d?k:null,m.setOptionsElement,p),C=Jg();Fn((()=>{var t;let e=f.optionsElement;e&&0===f.listboxState&&e!==(null==(t=Qg(e))?void 0:t.activeElement)&&(null==e||e.focus({preventScroll:!0}))}),[f.listboxState,f.optionsElement]);let R=ny((t=>{var e,n;switch(C.dispose(),t.key){case qy.Space:if(""!==f.searchQuery)return t.preventDefault(),t.stopPropagation(),m.search(t.key);case qy.Enter:if(t.preventDefault(),t.stopPropagation(),null!==f.activeOptionIndex){let{dataRef:t}=f.options[f.activeOptionIndex];m.onChange(t.current.value)}0===f.mode&&(Ur((()=>m.closeListbox())),null==(e=f.buttonElement)||e.focus({preventScroll:!0}));break;case ly(f.orientation,{vertical:qy.ArrowDown,horizontal:qy.ArrowRight}):return t.preventDefault(),t.stopPropagation(),m.goToOption(jw.Next);case ly(f.orientation,{vertical:qy.ArrowUp,horizontal:qy.ArrowLeft}):return t.preventDefault(),t.stopPropagation(),m.goToOption(jw.Previous);case qy.Home:case qy.PageUp:return t.preventDefault(),t.stopPropagation(),m.goToOption(jw.First);case qy.End:case qy.PageDown:return t.preventDefault(),t.stopPropagation(),m.goToOption(jw.Last);case qy.Escape:return t.preventDefault(),t.stopPropagation(),Ur((()=>m.closeListbox())),void(null==(n=f.buttonElement)||n.focus({preventScroll:!0}));case qy.Tab:t.preventDefault(),t.stopPropagation(),Ur((()=>m.closeListbox())),k_(f.buttonElement,t.shiftKey?v_.Previous:v_.Next);break;default:1===t.key.length&&(m.search(t.key),C.setTimeout((()=>m.clearSearch()),350))}})),O=null==(n=f.buttonElement)?void 0:n.id,M=jn((()=>({open:0===f.listboxState})),[f.listboxState]),F=gy(d?T():{},{id:o,ref:A,"aria-activedescendant":null===f.activeOptionIndex||null==(r=f.options[f.activeOptionIndex])?void 0:r.id,"aria-multiselectable":1===f.mode||void 0,"aria-labelledby":O,"aria-orientation":f.orientation,onKeyDown:R,role:"listbox",tabIndex:0===f.listboxState?0:void 0,style:{...c.style,...P,"--button-width":e_(f.buttonElement,!0).width},...N_(_)});return Xr.createElement(Yw,{enabled:!!a&&(t.static||y)},Xr.createElement(bx.Provider,{value:1===f.mode?f:{...f,isSelected:x}},py({ourProps:F,theirProps:c,slot:M,defaultTag:"div",features:kx,visible:b,name:"Listbox.Options"})))})),Ox=yy((function(t,e){let n=Gn(),{id:r=`headlessui-listbox-option-${n}`,disabled:i=!1,value:o,...s}=t,a=!0===Bn(Ex),l=wx("Listbox.Option"),u=_x("Listbox.Option"),c=null!==l.activeOptionIndex&&l.options[l.activeOptionIndex].id===r,d=l.isSelected(o),h=Dn(null),p=dx(h),f=ey({disabled:i,value:o,domRef:h,get textValue(){return p()}}),m=By(e,h,(t=>{t?l.listRef.current.set(r,t):l.listRef.current.delete(r)}));ty((()=>{if(!l.__demoMode&&0===l.listboxState&&c&&0!==l.activationTrigger)return Zg().requestAnimationFrame((()=>{var t,e;null==(e=null==(t=h.current)?void 0:t.scrollIntoView)||e.call(t,{block:"nearest"})}))}),[h,c,l.__demoMode,l.listboxState,l.activationTrigger,l.activeOptionIndex]),ty((()=>{if(!a)return u.registerOption(r,f)}),[f,r,a]);let v=ny((t=>{var e;if(i)return t.preventDefault();u.onChange(o),0===l.mode&&(Ur((()=>u.closeListbox())),null==(e=l.buttonElement)||e.focus({preventScroll:!0}))})),g=ny((()=>{if(i)return u.goToOption(jw.Nothing);u.goToOption(jw.Specific,r)})),y=function(){let t=Dn([-1,-1]);return{wasMoved(e){let n=j_(e);return(t.current[0]!==n[0]||t.current[1]!==n[1])&&(t.current=n,!0)},update(e){t.current=j_(e)}}}(),_=ny((t=>{y.update(t),!i&&(c||u.goToOption(jw.Specific,r,0))})),b=ny((t=>{y.wasMoved(t)&&(i||c||u.goToOption(jw.Specific,r,0))})),w=ny((t=>{y.wasMoved(t)&&(i||c&&u.goToOption(jw.Nothing))})),x=jn((()=>({active:c,focus:c,selected:d,disabled:i,selectedOption:d&&a})),[c,d,i,a]);return!d&&a?null:py({ourProps:a?{}:{id:r,ref:m,role:"option",tabIndex:!0===i?void 0:-1,"aria-disabled":!0===i||void 0,"aria-selected":d,disabled:void 0,onClick:v,onFocus:g,onPointerEnter:_,onMouseEnter:_,onPointerMove:b,onMouseMove:b,onPointerLeave:w,onMouseLeave:w},theirProps:s,slot:x,defaultTag:"div",name:"Listbox.Option"})})),Mx=yy((function(t,e){let{options:n,placeholder:r,...i}=t,o={ref:By(e)},s=wx("ListboxSelectedOption"),a=jn((()=>({})),[]),l=void 0===s.value||null===s.value||1===s.mode&&Array.isArray(s.value)&&0===s.value.length;return Xr.createElement(Ex.Provider,{value:!0},py({ourProps:o,theirProps:{...i,children:Xr.createElement(Xr.Fragment,null,r&&l?r:n)},slot:a,defaultTag:Px,name:"ListboxSelectedOption"}))})),Fx=Object.assign(Tx,{Button:Ax,Label:Cx,Options:Rx,Option:Ox,SelectedOption:Mx}),Lx=oe(null);Lx.displayName="GroupContext";let Dx=It;let Vx=yy((function(t,e){var n;let r=Gn(),i=Dy(),o=oy(),{id:s=i||`headlessui-switch-${r}`,disabled:a=o||!1,checked:l,defaultChecked:u,onChange:c,name:d,value:h,form:p,autoFocus:f=!1,...m}=t,v=Bn(Lx),[g,y]=On(null),_=By(Dn(null),e,null===v?null:v.setSwitch,y),b=xy(u),[w,x]=wy(l,c,null!=b&&b),S=Jg(),[E,k]=On(!1),P=ny((()=>{k(!0),null==x||x(!w),S.nextFrame((()=>{k(!1)}))})),T=ny((t=>{if(jy(t.currentTarget))return t.preventDefault();t.preventDefault(),P()})),A=ny((t=>{t.key===qy.Space?(t.preventDefault(),P()):t.key===qy.Enter&&Py(t.currentTarget)})),C=ny((t=>t.preventDefault())),R=Qy(),O=Uy(),{isFocusVisible:M,focusProps:F}=zg({autoFocus:f}),{isHovered:L,hoverProps:D}=$g({isDisabled:a}),{pressed:V,pressProps:j}=ry({disabled:a}),I=jn((()=>({checked:w,disabled:a,hover:L,focus:M,active:V,autofocus:f,changing:E})),[w,L,M,V,a,E,f]),B=gy({id:s,ref:_,role:"switch",type:M_(t,g),tabIndex:-1===t.tabIndex?0:null!=(n=t.tabIndex)?n:0,"aria-checked":w,"aria-labelledby":R,"aria-describedby":O,disabled:a||void 0,autoFocus:f,onClick:T,onKeyUp:A,onKeyPress:C},F,D,j),N=In((()=>{if(void 0!==b)return null==x?void 0:x(b)}),[x,b]);return Xr.createElement(Xr.Fragment,null,null!=d&&Xr.createElement(My,{disabled:a,data:{[d]:h||"on"},overrides:{type:"checkbox",checked:w},form:p,onReset:N}),py({ourProps:B,theirProps:m,slot:I,defaultTag:"button",name:"Switch"}))})),jx=function(t){var e;let[n,r]=On(null),[i,o]=Xy(),[s,a]=Wy(),l=jn((()=>({switch:n,setSwitch:r})),[n,r]),u=t;return Xr.createElement(a,{name:"Switch.Description",value:s},Xr.createElement(o,{name:"Switch.Label",value:i,props:{htmlFor:null==(e=l.switch)?void 0:e.id,onClick(t){n&&(t.currentTarget instanceof HTMLLabelElement&&t.preventDefault(),n.click(),n.focus({preventScroll:!0}))}}},Xr.createElement(Lx.Provider,{value:l},py({ourProps:{},theirProps:u,slot:{},defaultTag:Dx,name:"Switch.Group"}))))},Ix=Jy,Bx=$y,Nx=Object.assign(Vx,{Group:jx,Label:Ix,Description:Bx});function Gx(t,e){if(void 0===t.inserted[e.name])return t.insert("",e,t.sheet,!0)}function Ux(t,e,n){var r=[],i=ki(t,r,n);return r.length<2?n:i+e(r)}var Wx=function t(e){for(var n="",r=0;r<e.length;r++){var i=e[r];if(null!=i){var o=void 0;switch(typeof i){case"boolean":break;case"object":if(Array.isArray(i))o=t(i);else for(var s in o="",i)i[s]&&s&&(o&&(o+=" "),o+=s);break;default:o=i}o&&(n&&(n+=" "),n+=o)}}return n},Hx=function(t){var e=bn(t);e.sheet.speedy=function(t){this.isSpeedy=t},e.compat=!0;var n=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Ni(n,e.registered,void 0);return Ti(e,i,!1),e.key+"-"+i.name};return{css:n,cx:function(){for(var t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];return Ux(e.registered,n,Wx(r))},injectGlobal:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Ni(n,e.registered);Gx(e,i)},keyframes:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=Ni(n,e.registered),o="animation-"+i.name;return Gx(e,{name:i.name,styles:"@keyframes "+o+"{"+i.styles+"}"}),o},hydrate:function(t){t.forEach((function(t){e.inserted[t]=!0}))},flush:function(){e.registered={},e.inserted={},e.sheet.flush()},sheet:e.sheet,cache:e,getRegisteredStyles:ki.bind(null,e.registered),merge:Ux.bind(null,e.registered,n)}}({key:"css"}),$x=Hx.cx,zx=Hx.css;const qx=Os(Ax)`
|
|
46
46
|
${{position:"relative",minHeight:"2.25rem",width:"100%",cursor:"pointer",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))",paddingTop:"0.5rem",paddingBottom:"0.5rem",paddingLeft:"0.75rem",paddingRight:"2.5rem",textAlign:"left",fontSize:"1rem",lineHeight:"1.5rem","--tw-text-opacity":"1",color:"rgb(17 24 39 / 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), 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-inset":"inset",":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)"},"@media (min-width: 640px)":{fontSize:"0.875rem",lineHeight:"1.5rem"},"@media (min-width: 768px)":{paddingTop:"0.375rem",paddingBottom:"0.375rem"}}}
|
|
47
47
|
|
|
48
48
|
${({hasError:t})=>t?{"--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)"}}}
|
|
49
|
-
`,
|
|
49
|
+
`,Kx=Os(Jy)`
|
|
50
50
|
${{display:"block",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"}}
|
|
51
|
-
`;function iS({title:t,titleId:e,...n},r){return $t("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":e},n),t?$t("title",{id:e},t):null,$t("path",{fillRule:"evenodd",d:"M16.704 4.153a.75.75 0 0 1 .143 1.052l-8 10.5a.75.75 0 0 1-1.127.075l-4.5-4.5a.75.75 0 0 1 1.06-1.06l3.894 3.893 7.48-9.817a.75.75 0 0 1 1.05-.143Z",clipRule:"evenodd"}))}const oS=cr(iS);function sS({title:t,titleId:e,...n},r){return $t("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":e},n),t?$t("title",{id:e},t):null,$t("path",{fillRule:"evenodd",d:"M5.22 8.22a.75.75 0 0 1 1.06 0L10 11.94l3.72-3.72a.75.75 0 1 1 1.06 1.06l-4.25 4.25a.75.75 0 0 1-1.06 0L5.22 9.28a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"}))}const aS=cr(sS),lS=(t,e)=>{var n;return t?(null==(n=e.find((e=>e.key==t)))?void 0:n.displayValue)??"Select":"Select"},uS=(t,e)=>t&&Array.isArray(t)&&0!==t.length?t.map((t=>{var n;return null==(n=e.find((e=>e.key==t)))?void 0:n.displayValue})).join(", "):"Select",cS=cr((({label:t,items:e,value:n,className:r,onChange:i,error:o,helperText:s,isMultiSelect:a},l)=>mo("div",{className:r,children:[fo(W_,{value:n||(a?[]:""),onChange:t=>{if(a){const n=t,r=t.findIndex((t=>{var n;return null==(n=e.find((e=>e.key==t)))?void 0:n.isReset}));0===r&&n.length>1?i([...n.slice(1)]):i(r>-1?[n[r]]:t)}else i(t)},multiple:a,children:({open:r})=>mo(po,{children:[fo(rS,{children:t}),mo("div",{css:{position:"relative",marginTop:"0.5rem"},children:[mo(nS,{as:"button",ref:l,hasError:!!o,children:[fo("span",{css:{display:"block",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:a?uS(n,e):lS(n,e)}),fo("span",{css:{pointerEvents:"none",position:"absolute",top:"0px",bottom:"0px",right:"0px",display:"flex",alignItems:"center",fill:"#4b5563",paddingRight:"0.75rem","--tw-text-opacity":"1",color:"rgb(75 85 99 / var(--tw-text-opacity))"},children:fo(aS,{css:{height:"1.25rem",width:"1.25rem"},"aria-hidden":"true"})})]}),fo(v_,{show:r,leave:tS(eS({transitionProperty:"color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter",transitionTimingFunction:"cubic-bezier(0.4, 0, 1, 1)",transitionDuration:"100ms"})),leaveFrom:tS(eS({opacity:"1"})),leaveTo:tS(eS({opacity:"0"})),children:fo(B_,{css:{position:"absolute",zIndex:"10",marginTop:"0.25rem",maxHeight:"15rem",width:"100%",overflow:"auto",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))",paddingTop:"0.25rem",paddingBottom:"0.25rem",fontSize:"1rem",lineHeight:"1.5rem","--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-opacity":"0.05","--tw-ring-color":"rgb(0 0 0 / var(--tw-ring-opacity))",":focus":{outline:"2px solid transparent",outlineOffset:"2px"},"@media (min-width: 640px)":{fontSize:"0.875rem",lineHeight:"1.25rem"}},children:e.map((t=>mo(N_,{className:"group",css:{position:"relative",cursor:"default",userSelect:"none",paddingTop:"0.5rem",paddingBottom:"0.5rem",paddingLeft:"0.75rem",paddingRight:"2.25rem","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))","&[data-active]":{backgroundColor:"var(--fl-color-primary-600)","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))"},"&[data-selected]":{fontWeight:"600"}},value:t.key,children:[fo("span",{css:{display:"block",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:t.displayValue}),fo("span",{css:{visibility:"hidden",position:"absolute",top:"0px",bottom:"0px",right:"0px",display:"flex",alignItems:"center",fill:"var(--fl-color-primary-600)",paddingRight:"0.75rem",".group[data-selected] &":{visibility:"visible"},".group[data-active] &":{fill:"#fff"}},children:fo(oS,{css:{height:"1.25rem",width:"1.25rem",fill:"inherit"},"aria-hidden":"true"})})]},t.key)))})})]})]})}),o&&fo("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:o}),s&&fo("span",{css:{fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:s})]}))),dS=t=>mo("div",{children:[mo(g_,{children:[fo(lb,{as:"p",css:{fontSize:"0.875rem",lineHeight:"1.25rem"},children:fo("span",{css:{fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:t.label})}),fo(Y_,{checked:t.value,onChange:t.onChange,className:"group",css:{position:"relative",marginTop:"0.5rem",display:"inline-flex",height:"1.5rem",width:"2.75rem",flexShrink:"0",cursor:"pointer",borderRadius:"9999px",borderWidth:"2px",borderColor:"transparent","--tw-bg-opacity":"1",backgroundColor:"rgb(229 231 235 / var(--tw-bg-opacity))",transitionProperty:"color, background-color, border-color, text-decoration-color, fill, stroke",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"200ms",":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(79 70 229 / var(--tw-ring-opacity))","--tw-ring-offset-width":"2px"},"&[data-checked]":{"--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))"}},children:fo("span",{"aria-hidden":"true",css:{pointerEvents:"none",display:"inline-block",height:"1.25rem",width:"1.25rem",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))",borderRadius:"9999px","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))","--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(0px + var(--tw-ring-offset-width)) var(--tw-ring-color)",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:"200ms",".group[data-checked] &":{"--tw-translate-x":"1.25rem",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))"}}})})]}),t.helperText&&fo("p",{css:{marginTop:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:t.helperText})]}),hS=()=>{const t=function(){let{matches:t}=Gn(Ma),e=t[t.length-1];return e?e.params:{}}(),e=Ba(),{createPromotion:n,updatePromotion:r,getAllPromotions:i}=Eo(),o=bs(),{isPending:s,error:a,data:l}=Ls({queryKey:[sl],queryFn:i}),u=function(t){const e=bs(),[n]=Nn((()=>new gs(e,t)));Wn((()=>{n.setOptions(t)}),[n,t]);const r=ii(Kn((t=>n.subscribe(ts.batchCalls(t))),[n]),(()=>n.getCurrentResult())),i=Kn(((t,e)=>{n.mutate(t,e).catch(Ps)}),[n]);if(r.error&&ks(n.options.throwOnError,[r.error]))throw r.error;return{...r,mutate:i,mutateAsync:r.mutate}}({mutationFn:t.promotionId?r(t.promotionId):n,onSuccess:()=>o.invalidateQueries({queryKey:[sl]})}),c=null==l?void 0:l.data.find((e=>e.id===t.promotionId)),{handleSubmit:d,control:h}=function(t={}){const e=si.useRef(),n=si.useRef(),[r,i]=si.useState({isDirty:!1,isValidating:!1,isLoading:Wv(t.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1,defaultValues:Wv(t.defaultValues)?void 0:t.defaultValues});e.current||(e.current={...Sg(t),formState:r});const o=e.current.control;return o._options=t,Ov({subject:o._subjects.state,next:t=>{Cv(t,o._proxyFormState,o._updateFormState,!0)&&i({...o._formState})}}),si.useEffect((()=>o._disableForm(t.disabled)),[o,t.disabled]),si.useEffect((()=>{if(o._proxyFormState.isDirty){const t=o._getDirty();t!==r.isDirty&&o._subjects.state.next({isDirty:t})}}),[o,r.isDirty]),si.useEffect((()=>{t.values&&!ig(t.values,n.current)?(o._reset(t.values,o._options.resetOptions),n.current=t.values,i((t=>({...t})))):o._resetDefaultValues()}),[t.values,o]),si.useEffect((()=>{t.errors&&o._setErrors(t.errors)}),[t.errors,o]),si.useEffect((()=>{o._state.mount||(o._updateValid(),o._state.mount=!0),o._state.watch&&(o._state.watch=!1,o._subjects.state.next({...o._formState})),o._removeUnmounted()})),si.useEffect((()=>{t.shouldUnregister&&o._subjects.values.next({values:o._getWatch()})}),[t.shouldUnregister,o]),e.current.formState=Pv(r,o),e.current}({mode:"onBlur",values:{id:t.promotionId||"",category:(null==c?void 0:c.category.title)||"",isEnabled:"Enabled"===(null==c?void 0:c.status)}}),p=t=>{const e={promotionId:(n=t).id,category:n.category,isEnabled:n.isEnabled};var n;u.mutate(e)};Wn((()=>{u.isSuccess&&e("/")}),[e,u]);const f=t.promotionId?"Edit":"Add";switch(!0){case"Edit"===f&&s:return fo("div",{children:"Loading..."});case"Edit"===f&&!!a:return mo("div",{children:[fo("p",{children:a.message}),fo("button",{css:{marginTop:"1rem",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",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"}},onClick:()=>e("/"),children:"Back"})]});default:return mo("div",{css:{display:"flex",gap:"2rem",paddingLeft:"1rem",paddingRight:"1rem","@media (min-width: 640px)":{paddingLeft:"1.5rem",paddingRight:"1.5rem"},"@media (min-width: 1024px)":{paddingLeft:"2rem",paddingRight:"2rem"}},children:[fo("div",{css:{marginTop:"1rem",verticalAlign:"top"},children:fo("button",{onClick:()=>e("/"),children:"<"})}),mo("form",{onSubmit:d(p),children:[fo("div",{css:{"> :not([hidden]) ~ :not([hidden])":{"--tw-space-y-reverse":"0",marginTop:"calc(3rem * calc(1 - var(--tw-space-y-reverse)))",marginBottom:"calc(3rem * var(--tw-space-y-reverse))"}},children:mo("div",{css:{borderBottomWidth:"1px",borderColor:"rgb(17 24 39 / 0.1)",paddingBottom:"3rem"},children:[mo("h2",{css:{fontSize:"1rem",lineHeight:"1.75rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:[f," Promotion"]}),mo("p",{css:{marginTop:"0.25rem",fontSize:"0.875rem",lineHeight:"1.5rem","--tw-text-opacity":"1",color:"rgb(75 85 99 / var(--tw-text-opacity))"},children:[f," a promoted benefit"]}),mo("div",{css:{marginTop:"2.5rem",display:"grid",gridTemplateColumns:"repeat(1, minmax(0, 1fr))",columnGap:"1.5rem",rowGap:"2rem","@media (min-width: 640px)":{gridTemplateColumns:"repeat(6, minmax(0, 1fr))"}},children:[fo("div",{css:{"@media (min-width: 640px)":{gridColumn:"span 4 / span 4"}},children:fo(Dv,{name:"id",control:h,rules:{required:"Please provide an ID",pattern:{value:/^[a-z0-9\\-]+$/i,message:"Id must be lowercase and can only contain letters, numbers and hyphens."}},render:({field:t,fieldState:e})=>{var n;return fo(Xm,{label:"Promotion Id",id:"id",type:"text",disabled:"Edit"==f,helperText:"This should be the same as the contentful slug",error:null==(n=e.error)?void 0:n.message,...t})}})}),fo("div",{css:{"@media (min-width: 640px)":{gridColumn:"span 4 / span 4"}},children:fo(Dv,{name:"category",control:h,rules:{required:"Please provide a category"},render:({field:t,fieldState:e})=>{var n;return fo(cS,{items:[{key:"cars",displayValue:"Cars"},{key:"health",displayValue:"Health"},{key:"energy",displayValue:"Energy"},{key:"everyday",displayValue:"Everyday"},{key:"savingsAccount",displayValue:"Savings Account"},{key:"homeLoan",displayValue:"Home Loan"}],label:"Category",error:null==(n=e.error)?void 0:n.message,...t})}})}),"Edit"===f&&fo("div",{css:{"@media (min-width: 640px)":{gridColumn:"span 4 / span 4"}},children:fo(Dv,{name:"isEnabled",control:h,render:({field:t})=>fo(dS,{label:"Enabled",id:"id",helperText:"A promotion will be shown to users if it is 'Enabled' and Contentful content is available.",...t})})})]})]})}),u.isError&&fo("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:u.error.message}),fo("div",{css:{marginTop:"1.5rem",display:"flex",alignItems:"center",justifyContent:"flex-end",columnGap:"1.5rem"},children:u.isPending?fo("div",{css:{fontSize:"0.875rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:"Loading..."}):fo("button",{type:"submit",css:{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",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:"Save"})})]})]})}},pS=t=>fo(Wm.div,{css:{position:"absolute",bottom:"0px",left:"0px",right:"0px",top:"0px"},initial:{x:"forward"===t.direction?"100%":"-100%"},animate:{x:"0"},exit:{x:"forward"===t.direction?"-100%":"100%"},transition:{duration:.5,type:"spring"},children:fo("div",{css:{"--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))","--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, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)","@media (min-width: 640px)":{borderRadius:"0.5rem"}},children:fo("div",{css:{paddingLeft:"1rem",paddingRight:"1rem",paddingTop:"1.25rem",paddingBottom:"1.25rem","@media (min-width: 640px)":{padding:"1.5rem"}},children:t.children})})}),fS=t=>{const e=ja(),[n,r]=Nn("forward");var i;return i={backend:{url:t.backendUrl,accessToken:t.accessToken}},yo=fe({...i,backend:{url:i.backend.url.replace(/\/?$/,""),accessToken:i.backend.accessToken}}),Wn((()=>{if("/"===e.pathname)r("forward");else r("backward")}),[e.pathname]),fo("div",{class:"mx-auto max-w-7xl sm:px-6 lg:px-8 relative",children:fo(Ym,{initial:!1,children:mo(Qa,{location:e,children:[fo(Ga,{path:"/",element:fo(pS,{direction:n,children:fo(ll,{})})}),fo(Ga,{path:"/promotion",element:fo(pS,{direction:n,children:fo(hS,{})})}),fo(Ga,{path:"/promotion/:promotionId",element:fo(pS,{direction:n,children:fo(hS,{})})})]},e.pathname)})})};!function(t,e,n,r){function i(){var e=Reflect.construct(HTMLElement,[],i);return e._vdomComponent=t,e._root=r&&r.shadow?e.attachShadow({mode:r.mode||"open"}):e,e}(i.prototype=Object.create(HTMLElement.prototype)).constructor=i,i.prototype.connectedCallback=ye,i.prototype.attributeChangedCallback=we,i.prototype.disconnectedCallback=xe,n=n||t.observedAttributes||Object.keys(t.propTypes||{}),i.observedAttributes=n,n.forEach((function(t){Object.defineProperty(i.prototype,t,{get:function(){return this._vdom.props[t]},set:function(e){this._vdom?this.attributeChangedCallback(t,null,e):(this._props||(this._props={}),this._props[t]=e,this.connectedCallback());var n=typeof e;null!=e&&"string"!==n&&"boolean"!==n&&"number"!==n||this.setAttribute(t,e)}})})),customElements.define(e,i)}((t=>{const e=$n(null),{EmotionProvider:n}=((t,e)=>{const[n,r]=Nn();return Wn((()=>{if(e&&e.current){const n=e=>{document.getElementsByTagName(t).length>0?e():requestAnimationFrame((()=>n(e)))};n((()=>{r(An({container:e.current,key:t}))}))}}),[t,e]),{EmotionProvider:({children:t})=>n?fo(to,{value:n,children:t}):fo(po,{})}})("promoted-benefits-admin",e);return mo(po,{children:[fo("head",{ref:e}),fo(n,{children:fo(ws,{client:ol(),children:mo(Ja,{basename:t.hashRouteBase,children:[fo(go,{}),fo("body",{children:fo(fS,{...t})})]})})})]})}),"promoted-benefits-admin",["backend-url","access-token"],{shadow:!0});
|
|
51
|
+
`;function Yx({title:t,titleId:e,...n},r){return Dt("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":e},n),t?Dt("title",{id:e},t):null,Dt("path",{fillRule:"evenodd",d:"M16.704 4.153a.75.75 0 0 1 .143 1.052l-8 10.5a.75.75 0 0 1-1.127.075l-4.5-4.5a.75.75 0 0 1 1.06-1.06l3.894 3.893 7.48-9.817a.75.75 0 0 1 1.05-.143Z",clipRule:"evenodd"}))}const Qx=er(Yx);function Xx({title:t,titleId:e,...n},r){return Dt("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":e},n),t?Dt("title",{id:e},t):null,Dt("path",{fillRule:"evenodd",d:"M5.22 8.22a.75.75 0 0 1 1.06 0L10 11.94l3.72-3.72a.75.75 0 1 1 1.06 1.06l-4.25 4.25a.75.75 0 0 1-1.06 0L5.22 9.28a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"}))}const Zx=er(Xx),Jx=(t,e)=>{var n;return t?(null==(n=e.find((e=>e.key==t)))?void 0:n.displayValue)??"Select":"Select"},tS=(t,e)=>t&&Array.isArray(t)&&0!==t.length?t.map((t=>{var n;return null==(n=e.find((e=>e.key==t)))?void 0:n.displayValue})).join(", "):"Select",eS=er((({label:t,items:e,value:n,className:r,onChange:i,error:o,helperText:s,isMultiSelect:a},l)=>oo("div",{className:r,children:[io(Fx,{value:n||(a?[]:""),onChange:t=>{if(a){const n=t,r=t.findIndex((t=>{var n;return null==(n=e.find((e=>e.key==t)))?void 0:n.isReset}));0===r&&n.length>1?i([...n.slice(1)]):i(r>-1?[n[r]]:t)}else i(t)},multiple:a,children:({open:r})=>oo(ro,{children:[io(Kx,{children:t}),oo("div",{css:{position:"relative",marginTop:"0.5rem"},children:[oo(qx,{as:"button",ref:l,hasError:!!o,children:[io("span",{css:{display:"block",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:a?tS(n,e):Jx(n,e)}),io("span",{css:{pointerEvents:"none",position:"absolute",top:"0px",bottom:"0px",right:"0px",display:"flex",alignItems:"center",fill:"#4b5563",paddingRight:"0.75rem","--tw-text-opacity":"1",color:"rgb(75 85 99 / var(--tw-text-opacity))"},children:io(Zx,{css:{height:"1.25rem",width:"1.25rem"},"aria-hidden":"true"})})]}),io(ax,{show:r,leave:$x(zx({transitionProperty:"color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter",transitionTimingFunction:"cubic-bezier(0.4, 0, 1, 1)",transitionDuration:"100ms"})),leaveFrom:$x(zx({opacity:"1"})),leaveTo:$x(zx({opacity:"0"})),children:io(Rx,{css:{position:"absolute",zIndex:"10",marginTop:"0.25rem",maxHeight:"15rem",width:"100%",overflow:"auto",borderRadius:"0.375rem","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))",paddingTop:"0.25rem",paddingBottom:"0.25rem",fontSize:"1rem",lineHeight:"1.5rem","--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-opacity":"0.05","--tw-ring-color":"rgb(0 0 0 / var(--tw-ring-opacity))",":focus":{outline:"2px solid transparent",outlineOffset:"2px"},"@media (min-width: 640px)":{fontSize:"0.875rem",lineHeight:"1.25rem"}},children:e.map((t=>oo(Ox,{className:"group",css:{position:"relative",cursor:"default",userSelect:"none",paddingTop:"0.5rem",paddingBottom:"0.5rem",paddingLeft:"0.75rem",paddingRight:"2.25rem","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))","&[data-active]":{backgroundColor:"var(--fl-color-primary-600)","--tw-text-opacity":"1",color:"rgb(255 255 255 / var(--tw-text-opacity))"},"&[data-selected]":{fontWeight:"600"}},value:t.key,children:[io("span",{css:{display:"block",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:t.displayValue}),io("span",{css:{visibility:"hidden",position:"absolute",top:"0px",bottom:"0px",right:"0px",display:"flex",alignItems:"center",fill:"var(--fl-color-primary-600)",paddingRight:"0.75rem",".group[data-selected] &":{visibility:"visible"},".group[data-active] &":{fill:"#fff"}},children:io(Qx,{css:{height:"1.25rem",width:"1.25rem",fill:"inherit"},"aria-hidden":"true"})})]},t.key)))})})]})]})}),o&&io("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:o}),s&&io("span",{css:{fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:s})]}))),nS=t=>oo("div",{children:[oo(lx,{children:[io(Jy,{as:"p",css:{fontSize:"0.875rem",lineHeight:"1.25rem"},children:io("span",{css:{fontWeight:"500","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:t.label})}),io(Nx,{checked:t.value,onChange:t.onChange,className:"group",css:{position:"relative",marginTop:"0.5rem",display:"inline-flex",height:"1.5rem",width:"2.75rem",flexShrink:"0",cursor:"pointer",borderRadius:"9999px",borderWidth:"2px",borderColor:"transparent","--tw-bg-opacity":"1",backgroundColor:"rgb(229 231 235 / var(--tw-bg-opacity))",transitionProperty:"color, background-color, border-color, text-decoration-color, fill, stroke",transitionTimingFunction:"cubic-bezier(0.4, 0, 0.2, 1)",transitionDuration:"200ms",":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(79 70 229 / var(--tw-ring-opacity))","--tw-ring-offset-width":"2px"},"&[data-checked]":{"--tw-bg-opacity":"1",backgroundColor:"rgb(79 70 229 / var(--tw-bg-opacity))"}},children:io("span",{"aria-hidden":"true",css:{pointerEvents:"none",display:"inline-block",height:"1.25rem",width:"1.25rem",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))",borderRadius:"9999px","--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))","--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(0px + var(--tw-ring-offset-width)) var(--tw-ring-color)",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:"200ms",".group[data-checked] &":{"--tw-translate-x":"1.25rem",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))"}}})})]}),t.helperText&&io("p",{css:{marginTop:"0.5rem",fontSize:"0.875rem",lineHeight:"1.25rem",fontWeight:"400","--tw-text-opacity":"1",color:"rgb(107 114 128 / var(--tw-text-opacity))"},children:t.helperText})]}),rS=()=>{const t=function(){let{matches:t}=Bn(ka),e=t[t.length-1];return e?e.params:{}}(),e=Ra(),{createPromotion:n,updatePromotion:r,getAllPromotions:i}=mo(),o=cs(),{isPending:s,error:a,data:l}=Es({queryKey:[Xa],queryFn:i}),u=function(t){const e=cs(),[n]=On((()=>new ls(e,t)));Fn((()=>{n.setOptions(t)}),[n,t]);const r=Yr(In((t=>n.subscribe($o.batchCalls(t))),[n]),(()=>n.getCurrentResult())),i=In(((t,e)=>{n.mutate(t,e).catch(gs)}),[n]);if(r.error&&vs(n.options.throwOnError,[r.error]))throw r.error;return{...r,mutate:i,mutateAsync:r.mutate}}({mutationFn:t.promotionId?r(t.promotionId):n,onSuccess:()=>o.invalidateQueries({queryKey:[Xa]})}),c=null==l?void 0:l.data.find((e=>e.id===t.promotionId)),{handleSubmit:d,control:h}=function(t={}){const e=Xr.useRef(),n=Xr.useRef(),[r,i]=Xr.useState({isDirty:!1,isValidating:!1,isLoading:Fv(t.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1,defaultValues:Fv(t.defaultValues)?void 0:t.defaultValues});e.current||(e.current={...fg(t),formState:r});const o=e.current.control;return o._options=t,xv({subject:o._subjects.state,next:t=>{_v(t,o._proxyFormState,o._updateFormState,!0)&&i({...o._formState})}}),Xr.useEffect((()=>o._disableForm(t.disabled)),[o,t.disabled]),Xr.useEffect((()=>{if(o._proxyFormState.isDirty){const t=o._getDirty();t!==r.isDirty&&o._subjects.state.next({isDirty:t})}}),[o,r.isDirty]),Xr.useEffect((()=>{t.values&&!Yv(t.values,n.current)?(o._reset(t.values,o._options.resetOptions),n.current=t.values,i((t=>({...t})))):o._resetDefaultValues()}),[t.values,o]),Xr.useEffect((()=>{t.errors&&o._setErrors(t.errors)}),[t.errors,o]),Xr.useEffect((()=>{o._state.mount||(o._updateValid(),o._state.mount=!0),o._state.watch&&(o._state.watch=!1,o._subjects.state.next({...o._formState})),o._removeUnmounted()})),Xr.useEffect((()=>{t.shouldUnregister&&o._subjects.values.next({values:o._getWatch()})}),[t.shouldUnregister,o]),e.current.formState=gv(r,o),e.current}({mode:"onBlur",values:{id:t.promotionId||"",category:(null==c?void 0:c.category.title)||"",isEnabled:"Enabled"===(null==c?void 0:c.status)}}),p=t=>{const e={promotionId:(n=t).id,category:n.category,isEnabled:n.isEnabled};var n;u.mutate(e)};Fn((()=>{u.isSuccess&&e("/")}),[e,u]);const f=t.promotionId?"Edit":"Add";switch(!0){case"Edit"===f&&s:return io("div",{children:"Loading..."});case"Edit"===f&&!!a:return oo("div",{children:[io("p",{children:a.message}),io("button",{css:{marginTop:"1rem",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",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"}},onClick:()=>e("/"),children:"Back"})]});default:return oo("div",{css:{display:"flex",gap:"2rem",paddingLeft:"1rem",paddingRight:"1rem","@media (min-width: 640px)":{paddingLeft:"1.5rem",paddingRight:"1.5rem"},"@media (min-width: 1024px)":{paddingLeft:"2rem",paddingRight:"2rem"}},children:[io("div",{css:{marginTop:"1rem",verticalAlign:"top"},children:io("button",{onClick:()=>e("/"),children:"<"})}),oo("form",{onSubmit:d(p),children:[io("div",{css:{"> :not([hidden]) ~ :not([hidden])":{"--tw-space-y-reverse":"0",marginTop:"calc(3rem * calc(1 - var(--tw-space-y-reverse)))",marginBottom:"calc(3rem * var(--tw-space-y-reverse))"}},children:oo("div",{css:{borderBottomWidth:"1px",borderColor:"rgb(17 24 39 / 0.1)",paddingBottom:"3rem"},children:[oo("h2",{css:{fontSize:"1rem",lineHeight:"1.75rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:[f," Promotion"]}),oo("p",{css:{marginTop:"0.25rem",fontSize:"0.875rem",lineHeight:"1.5rem","--tw-text-opacity":"1",color:"rgb(75 85 99 / var(--tw-text-opacity))"},children:[f," a promoted benefit"]}),oo("div",{css:{marginTop:"2.5rem",display:"grid",gridTemplateColumns:"repeat(1, minmax(0, 1fr))",columnGap:"1.5rem",rowGap:"2rem","@media (min-width: 640px)":{gridTemplateColumns:"repeat(6, minmax(0, 1fr))"}},children:[io("div",{css:{"@media (min-width: 640px)":{gridColumn:"span 4 / span 4"}},children:io(Pv,{name:"id",control:h,rules:{required:"Please provide an ID",pattern:{value:/^[a-z0-9\\-]+$/i,message:"Id must be lowercase and can only contain letters, numbers and hyphens."}},render:({field:t,fieldState:e})=>{var n;return io(Um,{label:"Promotion Id",id:"id",type:"text",disabled:"Edit"==f,helperText:"This should be the same as the contentful slug",error:null==(n=e.error)?void 0:n.message,...t})}})}),io("div",{css:{"@media (min-width: 640px)":{gridColumn:"span 4 / span 4"}},children:io(Pv,{name:"category",control:h,rules:{required:"Please provide a category"},render:({field:t,fieldState:e})=>{var n;return io(eS,{items:[{key:"cars",displayValue:"Cars"},{key:"health",displayValue:"Health"},{key:"energy",displayValue:"Energy"},{key:"everyday",displayValue:"Everyday"},{key:"savingsAccount",displayValue:"Savings Account"},{key:"homeLoan",displayValue:"Home Loan"}],label:"Category",error:null==(n=e.error)?void 0:n.message,...t})}})}),"Edit"===f&&io("div",{css:{"@media (min-width: 640px)":{gridColumn:"span 4 / span 4"}},children:io(Pv,{name:"isEnabled",control:h,render:({field:t})=>io(nS,{label:"Enabled",id:"id",helperText:"A promotion will be shown to users if it is 'Enabled' and Contentful content is available.",...t})})})]})]})}),u.isError&&io("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:u.error.message}),io("div",{css:{marginTop:"1.5rem",display:"flex",alignItems:"center",justifyContent:"flex-end",columnGap:"1.5rem"},children:u.isPending?io("div",{css:{fontSize:"0.875rem",lineHeight:"1.5rem",fontWeight:"600","--tw-text-opacity":"1",color:"rgb(17 24 39 / var(--tw-text-opacity))"},children:"Loading..."}):io("button",{type:"submit",css:{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",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:"Save"})})]})]})}},iS=t=>io(Fm.div,{css:{position:"absolute",bottom:"0px",left:"0px",right:"0px",top:"0px"},initial:{x:"forward"===t.direction?"100%":"-100%"},animate:{x:"0"},exit:{x:"forward"===t.direction?"-100%":"100%"},transition:{duration:.5,type:"spring"},children:io("div",{css:{"--tw-bg-opacity":"1",backgroundColor:"rgb(255 255 255 / var(--tw-bg-opacity))","--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, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)","@media (min-width: 640px)":{borderRadius:"0.5rem"}},children:io("div",{css:{paddingLeft:"1rem",paddingRight:"1rem",paddingTop:"1.25rem",paddingBottom:"1.25rem","@media (min-width: 640px)":{padding:"1.5rem"}},children:t.children})})}),oS=t=>{const e=Aa(),[n,r]=On("forward");var i;return i={backend:{url:t.backendUrl,accessToken:t.accessToken}},lo=oe({...i,backend:{url:i.backend.url.replace(/\/?$/,""),accessToken:i.backend.accessToken}}),Fn((()=>{if("/"===e.pathname)r("forward");else r("backward")}),[e.pathname]),io("div",{class:"mx-auto max-w-7xl sm:px-6 lg:px-8 relative",children:io(Nm,{initial:!1,children:oo(Ga,{location:e,children:[io(Ba,{path:"/",element:io(iS,{direction:n,children:io(Ja,{})})}),io(Ba,{path:"/promotion",element:io(iS,{direction:n,children:io(rS,{})})}),io(Ba,{path:"/promotion/:promotionId",element:io(iS,{direction:n,children:io(rS,{})})})]},e.pathname)})})};!function(t,e,n,r){function i(){var e=Reflect.construct(HTMLElement,[],i);return e._vdomComponent=t,e._root=r&&r.shadow?e.attachShadow({mode:r.mode||"open"}):e,e}(i.prototype=Object.create(HTMLElement.prototype)).constructor=i,i.prototype.connectedCallback=ue,i.prototype.attributeChangedCallback=de,i.prototype.disconnectedCallback=he,n=n||t.observedAttributes||Object.keys(t.propTypes||{}),i.observedAttributes=n,n.forEach((function(t){Object.defineProperty(i.prototype,t,{get:function(){return this._vdom.props[t]},set:function(e){this._vdom?this.attributeChangedCallback(t,null,e):(this._props||(this._props={}),this._props[t]=e,this.connectedCallback());var n=typeof e;null!=e&&"string"!==n&&"boolean"!==n&&"number"!==n||this.setAttribute(t,e)}})})),customElements.define(e,i)}((t=>{const e=Dn(null),{EmotionProvider:n}=((t,e)=>{const[n,r]=On();return Fn((()=>{if(e&&e.current){const n=e=>{document.getElementsByTagName(t).length>0?e():requestAnimationFrame((()=>n(e)))};n((()=>{r(bn({container:e.current,key:t}))}))}}),[t,e]),{EmotionProvider:({children:t})=>n?io($i,{value:n,children:t}):io(ro,{})}})("promoted-benefits-admin",e);return oo(ro,{children:[io("head",{ref:e}),io(n,{children:io(ds,{client:Qa(),children:oo(Ha,{basename:t.hashRouteBase,children:[io(ao,{}),io("body",{children:io(oS,{...t})})]})})})]})}),"promoted-benefits-admin",["backend-url","access-token"],{shadow:!0})}();
|