airport-one-embeddable-widgets 0.33.0 → 0.34.0
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.
|
@@ -40,7 +40,7 @@ Error generating stack: `+o.message+`
|
|
|
40
40
|
`+o.stack}return{value:e,source:t,stack:i,digest:null}}function Zl(e,t,n){return{value:e,source:null,stack:n!=null?n:null,digest:t!=null?t:null}}function Jl(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var am=typeof WeakMap=="function"?WeakMap:Map;function Lf(e,t,n){n=Lt(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Oo||(Oo=!0,pu=r),Jl(e,t)},n}function If(e,t,n){n=Lt(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=t.value;n.payload=function(){return r(i)},n.callback=function(){Jl(e,t)}}var o=e.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(n.callback=function(){Jl(e,t),typeof r!="function"&&(rn===null?rn=new Set([this]):rn.add(this));var a=t.stack;this.componentDidCatch(t.value,{componentStack:a!==null?a:""})}),n}function $f(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new am;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(i.add(n),e=Sm.bind(null,e,t,n),t.then(e,e))}function Af(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Uf(e,t,n,r,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=Lt(-1,1),t.tag=2,tn(n,t,1))),n.lanes|=1),e)}var lm=_t.ReactCurrentOwner,Be=!1;function Ue(e,t,n,r){t.child=e===null?df(t,null,n,r):ur(t,e.child,n,r)}function zf(e,t,n,r,i){n=n.render;var o=t.ref;return lr(t,i),r=Vl(e,t,n,r,o,i),n=ql(),e!==null&&!Be?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,It(e,t,i)):(le&&n&&Pl(t),t.flags|=1,Ue(e,t,r,i),t.child)}function jf(e,t,n,r,i){if(e===null){var o=n.type;return typeof o=="function"&&!xu(o)&&o.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=o,Qf(e,t,o,r,i)):(e=Fo(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(o=e.child,!(e.lanes&i)){var a=o.memoizedProps;if(n=n.compare,n=n!==null?n:Vr,n(a,r)&&e.ref===t.ref)return It(e,t,i)}return t.flags|=1,e=un(o,r),e.ref=t.ref,e.return=t,t.child=e}function Qf(e,t,n,r,i){if(e!==null){var o=e.memoizedProps;if(Vr(o,r)&&e.ref===t.ref)if(Be=!1,t.pendingProps=r=o,(e.lanes&i)!==0)e.flags&131072&&(Be=!0);else return t.lanes=e.lanes,It(e,t,i)}return eu(e,t,n,r,i)}function Wf(e,t,n){var r=t.pendingProps,i=r.children,o=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},ee(dr,Je),Je|=n;else{if(!(n&1073741824))return e=o!==null?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,ee(dr,Je),Je|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=o!==null?o.baseLanes:n,ee(dr,Je),Je|=r}else o!==null?(r=o.baseLanes|n,t.memoizedState=null):r=n,ee(dr,Je),Je|=r;return Ue(e,t,i,n),t.child}function Hf(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function eu(e,t,n,r,i){var o=He(n)?wn:Re.current;return o=nr(t,o),lr(t,i),n=Vl(e,t,n,r,o,i),r=ql(),e!==null&&!Be?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,It(e,t,i)):(le&&r&&Pl(t),t.flags|=1,Ue(e,t,n,i),t.child)}function Bf(e,t,n,r,i){if(He(n)){var o=!0;no(t)}else o=!1;if(lr(t,i),t.stateNode===null)xo(e,t),uf(t,n,r),Ul(t,n,r,i),r=!0;else if(e===null){var a=t.stateNode,l=t.memoizedProps;a.props=l;var u=a.context,s=n.contextType;typeof s=="object"&&s!==null?s=lt(s):(s=He(n)?wn:Re.current,s=nr(t,s));var f=n.getDerivedStateFromProps,p=typeof f=="function"||typeof a.getSnapshotBeforeUpdate=="function";p||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(l!==r||u!==s)&&sf(t,a,r,s),en=!1;var c=t.memoizedState;a.state=c,co(t,r,a,i),u=t.memoizedState,l!==r||c!==u||We.current||en?(typeof f=="function"&&(Al(t,n,f,r),u=t.memoizedState),(l=en||lf(t,n,l,r,c,u,s))?(p||typeof a.UNSAFE_componentWillMount!="function"&&typeof a.componentWillMount!="function"||(typeof a.componentWillMount=="function"&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount=="function"&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount=="function"&&(t.flags|=4194308)):(typeof a.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=u),a.props=r,a.state=u,a.context=s,r=l):(typeof a.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,nf(e,t),l=t.memoizedProps,s=t.type===t.elementType?l:vt(t.type,l),a.props=s,p=t.pendingProps,c=a.context,u=n.contextType,typeof u=="object"&&u!==null?u=lt(u):(u=He(n)?wn:Re.current,u=nr(t,u));var v=n.getDerivedStateFromProps;(f=typeof v=="function"||typeof a.getSnapshotBeforeUpdate=="function")||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(l!==p||c!==u)&&sf(t,a,r,u),en=!1,c=t.memoizedState,a.state=c,co(t,r,a,i);var m=t.memoizedState;l!==p||c!==m||We.current||en?(typeof v=="function"&&(Al(t,n,v,r),m=t.memoizedState),(s=en||lf(t,n,s,r,c,m,u)||!1)?(f||typeof a.UNSAFE_componentWillUpdate!="function"&&typeof a.componentWillUpdate!="function"||(typeof a.componentWillUpdate=="function"&&a.componentWillUpdate(r,m,u),typeof a.UNSAFE_componentWillUpdate=="function"&&a.UNSAFE_componentWillUpdate(r,m,u)),typeof a.componentDidUpdate=="function"&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof a.componentDidUpdate!="function"||l===e.memoizedProps&&c===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&c===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=m),a.props=r,a.state=m,a.context=u,r=s):(typeof a.componentDidUpdate!="function"||l===e.memoizedProps&&c===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&c===e.memoizedState||(t.flags|=1024),r=!1)}return tu(e,t,n,r,o,i)}function tu(e,t,n,r,i,o){Hf(e,t);var a=(t.flags&128)!==0;if(!r&&!a)return i&&Yc(t,n,!1),It(e,t,o);r=t.stateNode,lm.current=t;var l=a&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&a?(t.child=ur(t,e.child,null,o),t.child=ur(t,null,l,o)):Ue(e,t,l,o),t.memoizedState=r.state,i&&Yc(t,n,!0),t.child}function Vf(e){var t=e.stateNode;t.pendingContext?Vc(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Vc(e,t.context,!1),zl(e,t.containerInfo)}function qf(e,t,n,r,i){return or(),Dl(i),t.flags|=256,Ue(e,t,n,r),t.child}var nu={dehydrated:null,treeContext:null,retryLane:0};function ru(e){return{baseLanes:e,cachePool:null,transitions:null}}function Yf(e,t,n){var r=t.pendingProps,i=se.current,o=!1,a=(t.flags&128)!==0,l;if((l=a)||(l=e!==null&&e.memoizedState===null?!1:(i&2)!==0),l?(o=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),ee(se,i&1),e===null)return Rl(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(a=r.children,e=r.fallback,o?(r=t.mode,o=t.child,a={mode:"hidden",children:a},!(r&1)&&o!==null?(o.childLanes=0,o.pendingProps=a):o=No(a,r,0,null),e=_n(e,r,n,null),o.return=t,e.return=t,o.sibling=e,t.child=o,t.child.memoizedState=ru(n),t.memoizedState=nu,e):iu(t,a));if(i=e.memoizedState,i!==null&&(l=i.dehydrated,l!==null))return um(e,t,a,r,l,i,n);if(o){o=r.fallback,a=t.mode,i=e.child,l=i.sibling;var u={mode:"hidden",children:r.children};return!(a&1)&&t.child!==i?(r=t.child,r.childLanes=0,r.pendingProps=u,t.deletions=null):(r=un(i,u),r.subtreeFlags=i.subtreeFlags&14680064),l!==null?o=un(l,o):(o=_n(o,a,n,null),o.flags|=2),o.return=t,r.return=t,r.sibling=o,t.child=r,r=o,o=t.child,a=e.child.memoizedState,a=a===null?ru(n):{baseLanes:a.baseLanes|n,cachePool:null,transitions:a.transitions},o.memoizedState=a,o.childLanes=e.childLanes&~n,t.memoizedState=nu,r}return o=e.child,e=o.sibling,r=un(o,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function iu(e,t){return t=No({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function So(e,t,n,r){return r!==null&&Dl(r),ur(t,e.child,null,n),e=iu(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function um(e,t,n,r,i,o,a){if(n)return t.flags&256?(t.flags&=-257,r=Zl(Error(E(422))),So(e,t,a,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(o=r.fallback,i=t.mode,r=No({mode:"visible",children:r.children},i,0,null),o=_n(o,i,a,null),o.flags|=2,r.return=t,o.return=t,r.sibling=o,t.child=r,t.mode&1&&ur(t,e.child,null,a),t.child.memoizedState=ru(a),t.memoizedState=nu,o);if(!(t.mode&1))return So(e,t,a,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var l=r.dgst;return r=l,o=Error(E(419)),r=Zl(o,r,void 0),So(e,t,a,r)}if(l=(a&e.childLanes)!==0,Be||l){if(r=ke,r!==null){switch(a&-a){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|a)?0:i,i!==0&&i!==o.retryLane&&(o.retryLane=i,Mt(e,i),gt(r,e,i,-1))}return Su(),r=Zl(Error(E(421))),So(e,t,a,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=xm.bind(null,e),i._reactRetry=t,null):(e=o.treeContext,Ze=Gt(i.nextSibling),Xe=t,le=!0,pt=null,e!==null&&(ot[at++]=Ft,ot[at++]=Nt,ot[at++]=Sn,Ft=e.id,Nt=e.overflow,Sn=t),t=iu(t,r.children),t.flags|=4096,t)}function Kf(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Ll(e.return,t,n)}function ou(e,t,n,r,i){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i)}function Gf(e,t,n){var r=t.pendingProps,i=r.revealOrder,o=r.tail;if(Ue(e,t,r.children,n),r=se.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Kf(e,n,t);else if(e.tag===19)Kf(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(ee(se,r),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&po(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),ou(t,!1,i,n,o);break;case"backwards":for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&po(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}ou(t,!0,n,null,o);break;case"together":ou(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function xo(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function It(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),En|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(E(153));if(t.child!==null){for(e=t.child,n=un(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=un(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function sm(e,t,n){switch(t.tag){case 3:Vf(t),or();break;case 5:hf(t);break;case 1:He(t.type)&&no(t);break;case 4:zl(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;ee(lo,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(ee(se,se.current&1),t.flags|=128,null):n&t.child.childLanes?Yf(e,t,n):(ee(se,se.current&1),e=It(e,t,n),e!==null?e.sibling:null);ee(se,se.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return Gf(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),ee(se,se.current),r)break;return null;case 22:case 23:return t.lanes=0,Wf(e,t,n)}return It(e,t,n)}var Xf,au,Zf,Jf;Xf=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}},au=function(){},Zf=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,Cn(kt.current);var o=null;switch(n){case"input":i=La(e,i),r=La(e,r),o=[];break;case"select":i=ue({},i,{value:void 0}),r=ue({},r,{value:void 0}),o=[];break;case"textarea":i=Aa(e,i),r=Aa(e,r),o=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Ji)}za(n,r);var a;n=null;for(s in i)if(!r.hasOwnProperty(s)&&i.hasOwnProperty(s)&&i[s]!=null)if(s==="style"){var l=i[s];for(a in l)l.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else s!=="dangerouslySetInnerHTML"&&s!=="children"&&s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(Er.hasOwnProperty(s)?o||(o=[]):(o=o||[]).push(s,null));for(s in r){var u=r[s];if(l=i!=null?i[s]:void 0,r.hasOwnProperty(s)&&u!==l&&(u!=null||l!=null))if(s==="style")if(l){for(a in l)!l.hasOwnProperty(a)||u&&u.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in u)u.hasOwnProperty(a)&&l[a]!==u[a]&&(n||(n={}),n[a]=u[a])}else n||(o||(o=[]),o.push(s,n)),n=u;else s==="dangerouslySetInnerHTML"?(u=u?u.__html:void 0,l=l?l.__html:void 0,u!=null&&l!==u&&(o=o||[]).push(s,u)):s==="children"?typeof u!="string"&&typeof u!="number"||(o=o||[]).push(s,""+u):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&(Er.hasOwnProperty(s)?(u!=null&&s==="onScroll"&&ie("scroll",e),o||l===u||(o=[])):(o=o||[]).push(s,u))}n&&(o=o||[]).push("style",n);var s=o;(t.updateQueue=s)&&(t.flags|=4)}},Jf=function(e,t,n,r){n!==r&&(t.flags|=4)};function li(e,t){if(!le)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Fe(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function cm(e,t,n){var r=t.pendingProps;switch(Tl(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Fe(t),null;case 1:return He(t.type)&&to(),Fe(t),null;case 3:return r=t.stateNode,sr(),oe(We),oe(Re),Wl(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(ao(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,pt!==null&&(yu(pt),pt=null))),au(e,t),Fe(t),null;case 5:jl(t);var i=Cn(ni.current);if(n=t.type,e!==null&&t.stateNode!=null)Zf(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(E(166));return Fe(t),null}if(e=Cn(kt.current),ao(t)){r=t.stateNode,n=t.type;var o=t.memoizedProps;switch(r[xt]=t,r[Xr]=o,e=(t.mode&1)!==0,n){case"dialog":ie("cancel",r),ie("close",r);break;case"iframe":case"object":case"embed":ie("load",r);break;case"video":case"audio":for(i=0;i<Yr.length;i++)ie(Yr[i],r);break;case"source":ie("error",r);break;case"img":case"image":case"link":ie("error",r),ie("load",r);break;case"details":ie("toggle",r);break;case"input":Ds(r,o),ie("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!o.multiple},ie("invalid",r);break;case"textarea":Ms(r,o),ie("invalid",r)}za(n,o),i=null;for(var a in o)if(o.hasOwnProperty(a)){var l=o[a];a==="children"?typeof l=="string"?r.textContent!==l&&(o.suppressHydrationWarning!==!0&&Zi(r.textContent,l,e),i=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(o.suppressHydrationWarning!==!0&&Zi(r.textContent,l,e),i=["children",""+l]):Er.hasOwnProperty(a)&&l!=null&&a==="onScroll"&&ie("scroll",r)}switch(n){case"input":_i(r),Ns(r,o,!0);break;case"textarea":_i(r),Is(r);break;case"select":case"option":break;default:typeof o.onClick=="function"&&(r.onclick=Ji)}r=i,t.updateQueue=r,r!==null&&(t.flags|=4)}else{a=i.nodeType===9?i:i.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=$s(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=a.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=a.createElement(n,{is:r.is}):(e=a.createElement(n),n==="select"&&(a=e,r.multiple?a.multiple=!0:r.size&&(a.size=r.size))):e=a.createElementNS(e,n),e[xt]=t,e[Xr]=r,Xf(e,t,!1,!1),t.stateNode=e;e:{switch(a=ja(n,r),n){case"dialog":ie("cancel",e),ie("close",e),i=r;break;case"iframe":case"object":case"embed":ie("load",e),i=r;break;case"video":case"audio":for(i=0;i<Yr.length;i++)ie(Yr[i],e);i=r;break;case"source":ie("error",e),i=r;break;case"img":case"image":case"link":ie("error",e),ie("load",e),i=r;break;case"details":ie("toggle",e),i=r;break;case"input":Ds(e,r),i=La(e,r),ie("invalid",e);break;case"option":i=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},i=ue({},r,{value:void 0}),ie("invalid",e);break;case"textarea":Ms(e,r),i=Aa(e,r),ie("invalid",e);break;default:i=r}za(n,i),l=i;for(o in l)if(l.hasOwnProperty(o)){var u=l[o];o==="style"?zs(e,u):o==="dangerouslySetInnerHTML"?(u=u?u.__html:void 0,u!=null&&As(e,u)):o==="children"?typeof u=="string"?(n!=="textarea"||u!=="")&&_r(e,u):typeof u=="number"&&_r(e,""+u):o!=="suppressContentEditableWarning"&&o!=="suppressHydrationWarning"&&o!=="autoFocus"&&(Er.hasOwnProperty(o)?u!=null&&o==="onScroll"&&ie("scroll",e):u!=null&&ba(e,o,u,a))}switch(n){case"input":_i(e),Ns(e,r,!1);break;case"textarea":_i(e),Is(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Wt(r.value));break;case"select":e.multiple=!!r.multiple,o=r.value,o!=null?Hn(e,!!r.multiple,o,!1):r.defaultValue!=null&&Hn(e,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=Ji)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return Fe(t),null;case 6:if(e&&t.stateNode!=null)Jf(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(E(166));if(n=Cn(ni.current),Cn(kt.current),ao(t)){if(r=t.stateNode,n=t.memoizedProps,r[xt]=t,(o=r.nodeValue!==n)&&(e=Xe,e!==null))switch(e.tag){case 3:Zi(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Zi(r.nodeValue,n,(e.mode&1)!==0)}o&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[xt]=t,t.stateNode=r}return Fe(t),null;case 13:if(oe(se),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(le&&Ze!==null&&t.mode&1&&!(t.flags&128))ef(),or(),t.flags|=98560,o=!1;else if(o=ao(t),r!==null&&r.dehydrated!==null){if(e===null){if(!o)throw Error(E(318));if(o=t.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error(E(317));o[xt]=t}else or(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Fe(t),o=!1}else pt!==null&&(yu(pt),pt=null),o=!0;if(!o)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||se.current&1?Se===0&&(Se=3):Su())),t.updateQueue!==null&&(t.flags|=4),Fe(t),null);case 4:return sr(),au(e,t),e===null&&Kr(t.stateNode.containerInfo),Fe(t),null;case 10:return Ml(t.type._context),Fe(t),null;case 17:return He(t.type)&&to(),Fe(t),null;case 19:if(oe(se),o=t.memoizedState,o===null)return Fe(t),null;if(r=(t.flags&128)!==0,a=o.rendering,a===null)if(r)li(o,!1);else{if(Se!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(a=po(e),a!==null){for(t.flags|=128,li(o,!1),r=a.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)o=n,e=r,o.flags&=14680066,a=o.alternate,a===null?(o.childLanes=0,o.lanes=e,o.child=null,o.subtreeFlags=0,o.memoizedProps=null,o.memoizedState=null,o.updateQueue=null,o.dependencies=null,o.stateNode=null):(o.childLanes=a.childLanes,o.lanes=a.lanes,o.child=a.child,o.subtreeFlags=0,o.deletions=null,o.memoizedProps=a.memoizedProps,o.memoizedState=a.memoizedState,o.updateQueue=a.updateQueue,o.type=a.type,e=a.dependencies,o.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return ee(se,se.current&1|2),t.child}e=e.sibling}o.tail!==null&&me()>hr&&(t.flags|=128,r=!0,li(o,!1),t.lanes=4194304)}else{if(!r)if(e=po(a),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),li(o,!0),o.tail===null&&o.tailMode==="hidden"&&!a.alternate&&!le)return Fe(t),null}else 2*me()-o.renderingStartTime>hr&&n!==1073741824&&(t.flags|=128,r=!0,li(o,!1),t.lanes=4194304);o.isBackwards?(a.sibling=t.child,t.child=a):(n=o.last,n!==null?n.sibling=a:t.child=a,o.last=a)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=me(),t.sibling=null,n=se.current,ee(se,r?n&1|2:n&1),t):(Fe(t),null);case 22:case 23:return wu(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Je&1073741824&&(Fe(t),t.subtreeFlags&6&&(t.flags|=8192)):Fe(t),null;case 24:return null;case 25:return null}throw Error(E(156,t.tag))}function fm(e,t){switch(Tl(t),t.tag){case 1:return He(t.type)&&to(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return sr(),oe(We),oe(Re),Wl(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return jl(t),null;case 13:if(oe(se),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(E(340));or()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return oe(se),null;case 4:return sr(),null;case 10:return Ml(t.type._context),null;case 22:case 23:return wu(),null;case 24:return null;default:return null}}var ko=!1,Ne=!1,dm=typeof WeakSet=="function"?WeakSet:Set,D=null;function fr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){de(e,t,r)}else n.current=null}function lu(e,t,n){try{n()}catch(r){de(e,t,r)}}var ed=!1;function hm(e,t){if(wl=ji,e=Rc(),fl(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch(w){n=null;break e}var a=0,l=-1,u=-1,s=0,f=0,p=e,c=null;t:for(;;){for(var v;p!==n||i!==0&&p.nodeType!==3||(l=a+i),p!==o||r!==0&&p.nodeType!==3||(u=a+r),p.nodeType===3&&(a+=p.nodeValue.length),(v=p.firstChild)!==null;)c=p,p=v;for(;;){if(p===e)break t;if(c===n&&++s===i&&(l=a),c===o&&++f===r&&(u=a),(v=p.nextSibling)!==null)break;p=c,c=p.parentNode}p=v}n=l===-1||u===-1?null:{start:l,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(Sl={focusedElem:e,selectionRange:n},ji=!1,D=t;D!==null;)if(t=D,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,D=e;else for(;D!==null;){t=D;try{var m=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(m!==null){var g=m.memoizedProps,x=m.memoizedState,h=t.stateNode,d=h.getSnapshotBeforeUpdate(t.elementType===t.type?g:vt(t.type,g),x);h.__reactInternalSnapshotBeforeUpdate=d}break;case 3:var y=t.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(E(163))}}catch(w){de(t,t.return,w)}if(e=t.sibling,e!==null){e.return=t.return,D=e;break}D=t.return}return m=ed,ed=!1,m}function ui(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var o=i.destroy;i.destroy=void 0,o!==void 0&&lu(t,n,o)}i=i.next}while(i!==r)}}function Co(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function uu(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function td(e){var t=e.alternate;t!==null&&(e.alternate=null,td(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[xt],delete t[Xr],delete t[bl],delete t[Kv],delete t[Gv])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function nd(e){return e.tag===5||e.tag===3||e.tag===4}function rd(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||nd(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function su(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Ji));else if(r!==4&&(e=e.child,e!==null))for(su(e,t,n),e=e.sibling;e!==null;)su(e,t,n),e=e.sibling}function cu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(cu(e,t,n),e=e.sibling;e!==null;)cu(e,t,n),e=e.sibling}var Ee=null,mt=!1;function nn(e,t,n){for(n=n.child;n!==null;)id(e,t,n),n=n.sibling}function id(e,t,n){if(St&&typeof St.onCommitFiberUnmount=="function")try{St.onCommitFiberUnmount(Li,n)}catch(l){}switch(n.tag){case 5:Ne||fr(n,t);case 6:var r=Ee,i=mt;Ee=null,nn(e,t,n),Ee=r,mt=i,Ee!==null&&(mt?(e=Ee,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ee.removeChild(n.stateNode));break;case 18:Ee!==null&&(mt?(e=Ee,n=n.stateNode,e.nodeType===8?Cl(e.parentNode,n):e.nodeType===1&&Cl(e,n),zr(e)):Cl(Ee,n.stateNode));break;case 4:r=Ee,i=mt,Ee=n.stateNode.containerInfo,mt=!0,nn(e,t,n),Ee=r,mt=i;break;case 0:case 11:case 14:case 15:if(!Ne&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var o=i,a=o.destroy;o=o.tag,a!==void 0&&(o&2||o&4)&&lu(n,t,a),i=i.next}while(i!==r)}nn(e,t,n);break;case 1:if(!Ne&&(fr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){de(n,t,l)}nn(e,t,n);break;case 21:nn(e,t,n);break;case 22:n.mode&1?(Ne=(r=Ne)||n.memoizedState!==null,nn(e,t,n),Ne=r):nn(e,t,n);break;default:nn(e,t,n)}}function od(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new dm),t.forEach(function(r){var i=km.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function yt(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];try{var o=e,a=t,l=a;e:for(;l!==null;){switch(l.tag){case 5:Ee=l.stateNode,mt=!1;break e;case 3:Ee=l.stateNode.containerInfo,mt=!0;break e;case 4:Ee=l.stateNode.containerInfo,mt=!0;break e}l=l.return}if(Ee===null)throw Error(E(160));id(o,a,i),Ee=null,mt=!1;var u=i.alternate;u!==null&&(u.return=null),i.return=null}catch(s){de(i,t,s)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)ad(t,e),t=t.sibling}function ad(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(yt(t,e),bt(e),r&4){try{ui(3,e,e.return),Co(3,e)}catch(g){de(e,e.return,g)}try{ui(5,e,e.return)}catch(g){de(e,e.return,g)}}break;case 1:yt(t,e),bt(e),r&512&&n!==null&&fr(n,n.return);break;case 5:if(yt(t,e),bt(e),r&512&&n!==null&&fr(n,n.return),e.flags&32){var i=e.stateNode;try{_r(i,"")}catch(g){de(e,e.return,g)}}if(r&4&&(i=e.stateNode,i!=null)){var o=e.memoizedProps,a=n!==null?n.memoizedProps:o,l=e.type,u=e.updateQueue;if(e.updateQueue=null,u!==null)try{l==="input"&&o.type==="radio"&&o.name!=null&&Fs(i,o),ja(l,a);var s=ja(l,o);for(a=0;a<u.length;a+=2){var f=u[a],p=u[a+1];f==="style"?zs(i,p):f==="dangerouslySetInnerHTML"?As(i,p):f==="children"?_r(i,p):ba(i,f,p,s)}switch(l){case"input":Ia(i,o);break;case"textarea":Ls(i,o);break;case"select":var c=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!o.multiple;var v=o.value;v!=null?Hn(i,!!o.multiple,v,!1):c!==!!o.multiple&&(o.defaultValue!=null?Hn(i,!!o.multiple,o.defaultValue,!0):Hn(i,!!o.multiple,o.multiple?[]:"",!1))}i[Xr]=o}catch(g){de(e,e.return,g)}}break;case 6:if(yt(t,e),bt(e),r&4){if(e.stateNode===null)throw Error(E(162));i=e.stateNode,o=e.memoizedProps;try{i.nodeValue=o}catch(g){de(e,e.return,g)}}break;case 3:if(yt(t,e),bt(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{zr(t.containerInfo)}catch(g){de(e,e.return,g)}break;case 4:yt(t,e),bt(e);break;case 13:yt(t,e),bt(e),i=e.child,i.flags&8192&&(o=i.memoizedState!==null,i.stateNode.isHidden=o,!o||i.alternate!==null&&i.alternate.memoizedState!==null||(hu=me())),r&4&&od(e);break;case 22:if(f=n!==null&&n.memoizedState!==null,e.mode&1?(Ne=(s=Ne)||f,yt(t,e),Ne=s):yt(t,e),bt(e),r&8192){if(s=e.memoizedState!==null,(e.stateNode.isHidden=s)&&!f&&e.mode&1)for(D=e,f=e.child;f!==null;){for(p=D=f;D!==null;){switch(c=D,v=c.child,c.tag){case 0:case 11:case 14:case 15:ui(4,c,c.return);break;case 1:fr(c,c.return);var m=c.stateNode;if(typeof m.componentWillUnmount=="function"){r=c,n=c.return;try{t=r,m.props=t.memoizedProps,m.state=t.memoizedState,m.componentWillUnmount()}catch(g){de(r,n,g)}}break;case 5:fr(c,c.return);break;case 22:if(c.memoizedState!==null){sd(p);continue}}v!==null?(v.return=c,D=v):sd(p)}f=f.sibling}e:for(f=null,p=e;;){if(p.tag===5){if(f===null){f=p;try{i=p.stateNode,s?(o=i.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none"):(l=p.stateNode,u=p.memoizedProps.style,a=u!=null&&u.hasOwnProperty("display")?u.display:null,l.style.display=Us("display",a))}catch(g){de(e,e.return,g)}}}else if(p.tag===6){if(f===null)try{p.stateNode.nodeValue=s?"":p.memoizedProps}catch(g){de(e,e.return,g)}}else if((p.tag!==22&&p.tag!==23||p.memoizedState===null||p===e)&&p.child!==null){p.child.return=p,p=p.child;continue}if(p===e)break e;for(;p.sibling===null;){if(p.return===null||p.return===e)break e;f===p&&(f=null),p=p.return}f===p&&(f=null),p.sibling.return=p.return,p=p.sibling}}break;case 19:yt(t,e),bt(e),r&4&&od(e);break;case 21:break;default:yt(t,e),bt(e)}}function bt(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(nd(n)){var r=n;break e}n=n.return}throw Error(E(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(_r(i,""),r.flags&=-33);var o=rd(e);cu(e,o,i);break;case 3:case 4:var a=r.stateNode.containerInfo,l=rd(e);su(e,l,a);break;default:throw Error(E(161))}}catch(u){de(e,e.return,u)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function pm(e,t,n){D=e,ld(e)}function ld(e,t,n){for(var r=(e.mode&1)!==0;D!==null;){var i=D,o=i.child;if(i.tag===22&&r){var a=i.memoizedState!==null||ko;if(!a){var l=i.alternate,u=l!==null&&l.memoizedState!==null||Ne;l=ko;var s=Ne;if(ko=a,(Ne=u)&&!s)for(D=i;D!==null;)a=D,u=a.child,a.tag===22&&a.memoizedState!==null?cd(i):u!==null?(u.return=a,D=u):cd(i);for(;o!==null;)D=o,ld(o),o=o.sibling;D=i,ko=l,Ne=s}ud(e)}else i.subtreeFlags&8772&&o!==null?(o.return=i,D=o):ud(e)}}function ud(e){for(;D!==null;){var t=D;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Ne||Co(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!Ne)if(n===null)r.componentDidMount();else{var i=t.elementType===t.type?n.memoizedProps:vt(t.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var o=t.updateQueue;o!==null&&of(t,o,r);break;case 3:var a=t.updateQueue;if(a!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}of(t,a,n)}break;case 5:var l=t.stateNode;if(n===null&&t.flags&4){n=l;var u=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":u.autoFocus&&n.focus();break;case"img":u.src&&(n.src=u.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var s=t.alternate;if(s!==null){var f=s.memoizedState;if(f!==null){var p=f.dehydrated;p!==null&&zr(p)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(E(163))}Ne||t.flags&512&&uu(t)}catch(c){de(t,t.return,c)}}if(t===e){D=null;break}if(n=t.sibling,n!==null){n.return=t.return,D=n;break}D=t.return}}function sd(e){for(;D!==null;){var t=D;if(t===e){D=null;break}var n=t.sibling;if(n!==null){n.return=t.return,D=n;break}D=t.return}}function cd(e){for(;D!==null;){var t=D;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Co(4,t)}catch(u){de(t,n,u)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var i=t.return;try{r.componentDidMount()}catch(u){de(t,i,u)}}var o=t.return;try{uu(t)}catch(u){de(t,o,u)}break;case 5:var a=t.return;try{uu(t)}catch(u){de(t,a,u)}}}catch(u){de(t,t.return,u)}if(t===e){D=null;break}var l=t.sibling;if(l!==null){l.return=t.return,D=l;break}D=t.return}}var vm=Math.ceil,bo=_t.ReactCurrentDispatcher,fu=_t.ReactCurrentOwner,st=_t.ReactCurrentBatchConfig,B=0,ke=null,ye=null,Oe=0,Je=0,dr=Xt(0),Se=0,si=null,En=0,Eo=0,du=0,ci=null,Ve=null,hu=0,hr=1/0,$t=null,Oo=!1,pu=null,rn=null,Po=!1,on=null,To=0,fi=0,vu=null,_o=-1,Ro=0;function ze(){return B&6?me():_o!==-1?_o:_o=me()}function an(e){return e.mode&1?B&2&&Oe!==0?Oe&-Oe:Zv.transition!==null?(Ro===0&&(Ro=tc()),Ro):(e=X,e!==0||(e=window.event,e=e===void 0?16:cc(e.type)),e):1}function gt(e,t,n,r){if(50<fi)throw fi=0,vu=null,Error(E(185));Lr(e,n,r),(!(B&2)||e!==ke)&&(e===ke&&(!(B&2)&&(Eo|=n),Se===4&&ln(e,Oe)),qe(e,r),n===1&&B===0&&!(t.mode&1)&&(hr=me()+500,ro&&Jt()))}function qe(e,t){var n=e.callbackNode;Zp(e,t);var r=Ai(e,e===ke?Oe:0);if(r===0)n!==null&&Zs(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&Zs(n),t===1)e.tag===0?Xv(dd.bind(null,e)):Kc(dd.bind(null,e)),qv(function(){!(B&6)&&Jt()}),n=null;else{switch(nc(r)){case 1:n=Ya;break;case 4:n=Js;break;case 16:n=Mi;break;case 536870912:n=ec;break;default:n=Mi}n=Sd(n,fd.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function fd(e,t){if(_o=-1,Ro=0,B&6)throw Error(E(327));var n=e.callbackNode;if(pr()&&e.callbackNode!==n)return null;var r=Ai(e,e===ke?Oe:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Do(e,r);else{t=r;var i=B;B|=2;var o=pd();(ke!==e||Oe!==t)&&($t=null,hr=me()+500,Pn(e,t));do try{gm();break}catch(l){hd(e,l)}while(1);Nl(),bo.current=o,B=i,ye!==null?t=0:(ke=null,Oe=0,t=Se)}if(t!==0){if(t===2&&(i=Ka(e),i!==0&&(r=i,t=mu(e,i))),t===1)throw n=si,Pn(e,0),ln(e,r),qe(e,me()),n;if(t===6)ln(e,r);else{if(i=e.current.alternate,!(r&30)&&!mm(i)&&(t=Do(e,r),t===2&&(o=Ka(e),o!==0&&(r=o,t=mu(e,o))),t===1))throw n=si,Pn(e,0),ln(e,r),qe(e,me()),n;switch(e.finishedWork=i,e.finishedLanes=r,t){case 0:case 1:throw Error(E(345));case 2:Tn(e,Ve,$t);break;case 3:if(ln(e,r),(r&130023424)===r&&(t=hu+500-me(),10<t)){if(Ai(e,0)!==0)break;if(i=e.suspendedLanes,(i&r)!==r){ze(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=kl(Tn.bind(null,e,Ve,$t),t);break}Tn(e,Ve,$t);break;case 4:if(ln(e,r),(r&4194240)===r)break;for(t=e.eventTimes,i=-1;0<r;){var a=31-dt(r);o=1<<a,a=t[a],a>i&&(i=a),r&=~o}if(r=i,r=me()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*vm(r/1960))-r,10<r){e.timeoutHandle=kl(Tn.bind(null,e,Ve,$t),r);break}Tn(e,Ve,$t);break;case 5:Tn(e,Ve,$t);break;default:throw Error(E(329))}}}return qe(e,me()),e.callbackNode===n?fd.bind(null,e):null}function mu(e,t){var n=ci;return e.current.memoizedState.isDehydrated&&(Pn(e,t).flags|=256),e=Do(e,t),e!==2&&(t=Ve,Ve=n,t!==null&&yu(t)),e}function yu(e){Ve===null?Ve=e:Ve.push.apply(Ve,e)}function mm(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var i=n[r],o=i.getSnapshot;i=i.value;try{if(!ht(o(),i))return!1}catch(a){return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function ln(e,t){for(t&=~du,t&=~Eo,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-dt(t),r=1<<n;e[n]=-1,t&=~r}}function dd(e){if(B&6)throw Error(E(327));pr();var t=Ai(e,0);if(!(t&1))return qe(e,me()),null;var n=Do(e,t);if(e.tag!==0&&n===2){var r=Ka(e);r!==0&&(t=r,n=mu(e,r))}if(n===1)throw n=si,Pn(e,0),ln(e,t),qe(e,me()),n;if(n===6)throw Error(E(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Tn(e,Ve,$t),qe(e,me()),null}function gu(e,t){var n=B;B|=1;try{return e(t)}finally{B=n,B===0&&(hr=me()+500,ro&&Jt())}}function On(e){on!==null&&on.tag===0&&!(B&6)&&pr();var t=B;B|=1;var n=st.transition,r=X;try{if(st.transition=null,X=1,e)return e()}finally{X=r,st.transition=n,B=t,!(B&6)&&Jt()}}function wu(){Je=dr.current,oe(dr)}function Pn(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,Vv(n)),ye!==null)for(n=ye.return;n!==null;){var r=n;switch(Tl(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&to();break;case 3:sr(),oe(We),oe(Re),Wl();break;case 5:jl(r);break;case 4:sr();break;case 13:oe(se);break;case 19:oe(se);break;case 10:Ml(r.type._context);break;case 22:case 23:wu()}n=n.return}if(ke=e,ye=e=un(e.current,null),Oe=Je=t,Se=0,si=null,du=Eo=En=0,Ve=ci=null,kn!==null){for(t=0;t<kn.length;t++)if(n=kn[t],r=n.interleaved,r!==null){n.interleaved=null;var i=r.next,o=n.pending;if(o!==null){var a=o.next;o.next=i,r.next=a}n.pending=r}kn=null}return e}function hd(e,t){do{var n=ye;try{if(Nl(),vo.current=wo,mo){for(var r=ce.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}mo=!1}if(bn=0,xe=we=ce=null,ri=!1,ii=0,fu.current=null,n===null||n.return===null){Se=1,si=t,ye=null;break}e:{var o=e,a=n.return,l=n,u=t;if(t=Oe,l.flags|=32768,u!==null&&typeof u=="object"&&typeof u.then=="function"){var s=u,f=l,p=f.tag;if(!(f.mode&1)&&(p===0||p===11||p===15)){var c=f.alternate;c?(f.updateQueue=c.updateQueue,f.memoizedState=c.memoizedState,f.lanes=c.lanes):(f.updateQueue=null,f.memoizedState=null)}var v=Af(a);if(v!==null){v.flags&=-257,Uf(v,a,l,o,t),v.mode&1&&$f(o,s,t),t=v,u=s;var m=t.updateQueue;if(m===null){var g=new Set;g.add(u),t.updateQueue=g}else m.add(u);break e}else{if(!(t&1)){$f(o,s,t),Su();break e}u=Error(E(426))}}else if(le&&l.mode&1){var x=Af(a);if(x!==null){!(x.flags&65536)&&(x.flags|=256),Uf(x,a,l,o,t),Dl(cr(u,l));break e}}o=u=cr(u,l),Se!==4&&(Se=2),ci===null?ci=[o]:ci.push(o),o=a;do{switch(o.tag){case 3:o.flags|=65536,t&=-t,o.lanes|=t;var h=Lf(o,u,t);rf(o,h);break e;case 1:l=u;var d=o.type,y=o.stateNode;if(!(o.flags&128)&&(typeof d.getDerivedStateFromError=="function"||y!==null&&typeof y.componentDidCatch=="function"&&(rn===null||!rn.has(y)))){o.flags|=65536,t&=-t,o.lanes|=t;var w=If(o,l,t);rf(o,w);break e}}o=o.return}while(o!==null)}md(n)}catch(C){t=C,ye===n&&n!==null&&(ye=n=n.return);continue}break}while(1)}function pd(){var e=bo.current;return bo.current=wo,e===null?wo:e}function Su(){(Se===0||Se===3||Se===2)&&(Se=4),ke===null||!(En&268435455)&&!(Eo&268435455)||ln(ke,Oe)}function Do(e,t){var n=B;B|=2;var r=pd();(ke!==e||Oe!==t)&&($t=null,Pn(e,t));do try{ym();break}catch(i){hd(e,i)}while(1);if(Nl(),B=n,bo.current=r,ye!==null)throw Error(E(261));return ke=null,Oe=0,Se}function ym(){for(;ye!==null;)vd(ye)}function gm(){for(;ye!==null&&!Wp();)vd(ye)}function vd(e){var t=wd(e.alternate,e,Je);e.memoizedProps=e.pendingProps,t===null?md(e):ye=t,fu.current=null}function md(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=fm(n,t),n!==null){n.flags&=32767,ye=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Se=6,ye=null;return}}else if(n=cm(n,t,Je),n!==null){ye=n;return}if(t=t.sibling,t!==null){ye=t;return}ye=t=e}while(t!==null);Se===0&&(Se=5)}function Tn(e,t,n){var r=X,i=st.transition;try{st.transition=null,X=1,wm(e,t,n,r)}finally{st.transition=i,X=r}return null}function wm(e,t,n,r){do pr();while(on!==null);if(B&6)throw Error(E(327));n=e.finishedWork;var i=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(E(177));e.callbackNode=null,e.callbackPriority=0;var o=n.lanes|n.childLanes;if(Jp(e,o),e===ke&&(ye=ke=null,Oe=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Po||(Po=!0,Sd(Mi,function(){return pr(),null})),o=(n.flags&15990)!==0,n.subtreeFlags&15990||o){o=st.transition,st.transition=null;var a=X;X=1;var l=B;B|=4,fu.current=null,hm(e,n),ad(n,e),Uv(Sl),ji=!!wl,Sl=wl=null,e.current=n,pm(n),Hp(),B=l,X=a,st.transition=o}else e.current=n;if(Po&&(Po=!1,on=e,To=i),o=e.pendingLanes,o===0&&(rn=null),qp(n.stateNode),qe(e,me()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)i=t[n],r(i.value,{componentStack:i.stack,digest:i.digest});if(Oo)throw Oo=!1,e=pu,pu=null,e;return To&1&&e.tag!==0&&pr(),o=e.pendingLanes,o&1?e===vu?fi++:(fi=0,vu=e):fi=0,Jt(),null}function pr(){if(on!==null){var e=nc(To),t=st.transition,n=X;try{if(st.transition=null,X=16>e?16:e,on===null)var r=!1;else{if(e=on,on=null,To=0,B&6)throw Error(E(331));var i=B;for(B|=4,D=e.current;D!==null;){var o=D,a=o.child;if(D.flags&16){var l=o.deletions;if(l!==null){for(var u=0;u<l.length;u++){var s=l[u];for(D=s;D!==null;){var f=D;switch(f.tag){case 0:case 11:case 15:ui(8,f,o)}var p=f.child;if(p!==null)p.return=f,D=p;else for(;D!==null;){f=D;var c=f.sibling,v=f.return;if(td(f),f===s){D=null;break}if(c!==null){c.return=v,D=c;break}D=v}}}var m=o.alternate;if(m!==null){var g=m.child;if(g!==null){m.child=null;do{var x=g.sibling;g.sibling=null,g=x}while(g!==null)}}D=o}}if(o.subtreeFlags&2064&&a!==null)a.return=o,D=a;else e:for(;D!==null;){if(o=D,o.flags&2048)switch(o.tag){case 0:case 11:case 15:ui(9,o,o.return)}var h=o.sibling;if(h!==null){h.return=o.return,D=h;break e}D=o.return}}var d=e.current;for(D=d;D!==null;){a=D;var y=a.child;if(a.subtreeFlags&2064&&y!==null)y.return=a,D=y;else e:for(a=d;D!==null;){if(l=D,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:Co(9,l)}}catch(C){de(l,l.return,C)}if(l===a){D=null;break e}var w=l.sibling;if(w!==null){w.return=l.return,D=w;break e}D=l.return}}if(B=i,Jt(),St&&typeof St.onPostCommitFiberRoot=="function")try{St.onPostCommitFiberRoot(Li,e)}catch(C){}r=!0}return r}finally{X=n,st.transition=t}}return!1}function yd(e,t,n){t=cr(n,t),t=Lf(e,t,1),e=tn(e,t,1),t=ze(),e!==null&&(Lr(e,1,t),qe(e,t))}function de(e,t,n){if(e.tag===3)yd(e,e,n);else for(;t!==null;){if(t.tag===3){yd(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(rn===null||!rn.has(r))){e=cr(n,e),e=If(t,e,1),t=tn(t,e,1),e=ze(),t!==null&&(Lr(t,1,e),qe(t,e));break}}t=t.return}}function Sm(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=ze(),e.pingedLanes|=e.suspendedLanes&n,ke===e&&(Oe&n)===n&&(Se===4||Se===3&&(Oe&130023424)===Oe&&500>me()-hu?Pn(e,0):du|=n),qe(e,t)}function gd(e,t){t===0&&(e.mode&1?(t=$i,$i<<=1,!($i&130023424)&&($i=4194304)):t=1);var n=ze();e=Mt(e,t),e!==null&&(Lr(e,t,n),qe(e,n))}function xm(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),gd(e,n)}function km(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(E(314))}r!==null&&r.delete(t),gd(e,n)}var wd;wd=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||We.current)Be=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Be=!1,sm(e,t,n);Be=!!(e.flags&131072)}else Be=!1,le&&t.flags&1048576&&Gc(t,oo,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;xo(e,t),e=t.pendingProps;var i=nr(t,Re.current);lr(t,n),i=Vl(null,t,r,e,i,n);var o=ql();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,He(r)?(o=!0,no(t)):o=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,$l(t),i.updater=fo,t.stateNode=i,i._reactInternals=t,Ul(t,r,e,n),t=tu(null,t,r,!0,o,n)):(t.tag=0,le&&o&&Pl(t),Ue(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(xo(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=bm(r),e=vt(r,e),i){case 0:t=eu(null,t,r,e,n);break e;case 1:t=Bf(null,t,r,e,n);break e;case 11:t=zf(null,t,r,e,n);break e;case 14:t=jf(null,t,r,vt(r.type,e),n);break e}throw Error(E(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:vt(r,i),eu(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:vt(r,i),Bf(e,t,r,i,n);case 3:e:{if(Vf(t),e===null)throw Error(E(387));r=t.pendingProps,o=t.memoizedState,i=o.element,nf(e,t),co(t,r,null,n);var a=t.memoizedState;if(r=a.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:a.cache,pendingSuspenseBoundaries:a.pendingSuspenseBoundaries,transitions:a.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){i=cr(Error(E(423)),t),t=qf(e,t,r,n,i);break e}else if(r!==i){i=cr(Error(E(424)),t),t=qf(e,t,r,n,i);break e}else for(Ze=Gt(t.stateNode.containerInfo.firstChild),Xe=t,le=!0,pt=null,n=df(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(or(),r===i){t=It(e,t,n);break e}Ue(e,t,r,n)}t=t.child}return t;case 5:return hf(t),e===null&&Rl(t),r=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,a=i.children,xl(r,i)?a=null:o!==null&&xl(r,o)&&(t.flags|=32),Hf(e,t),Ue(e,t,a,n),t.child;case 6:return e===null&&Rl(t),null;case 13:return Yf(e,t,n);case 4:return zl(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=ur(t,null,r,n):Ue(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:vt(r,i),zf(e,t,r,i,n);case 7:return Ue(e,t,t.pendingProps,n),t.child;case 8:return Ue(e,t,t.pendingProps.children,n),t.child;case 12:return Ue(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,o=t.memoizedProps,a=i.value,ee(lo,r._currentValue),r._currentValue=a,o!==null)if(ht(o.value,a)){if(o.children===i.children&&!We.current){t=It(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var l=o.dependencies;if(l!==null){a=o.child;for(var u=l.firstContext;u!==null;){if(u.context===r){if(o.tag===1){u=Lt(-1,n&-n),u.tag=2;var s=o.updateQueue;if(s!==null){s=s.shared;var f=s.pending;f===null?u.next=u:(u.next=f.next,f.next=u),s.pending=u}}o.lanes|=n,u=o.alternate,u!==null&&(u.lanes|=n),Ll(o.return,n,t),l.lanes|=n;break}u=u.next}}else if(o.tag===10)a=o.type===t.type?null:o.child;else if(o.tag===18){if(a=o.return,a===null)throw Error(E(341));a.lanes|=n,l=a.alternate,l!==null&&(l.lanes|=n),Ll(a,n,t),a=o.sibling}else a=o.child;if(a!==null)a.return=o;else for(a=o;a!==null;){if(a===t){a=null;break}if(o=a.sibling,o!==null){o.return=a.return,a=o;break}a=a.return}o=a}Ue(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,lr(t,n),i=lt(i),r=r(i),t.flags|=1,Ue(e,t,r,n),t.child;case 14:return r=t.type,i=vt(r,t.pendingProps),i=vt(r.type,i),jf(e,t,r,i,n);case 15:return Qf(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:vt(r,i),xo(e,t),t.tag=1,He(r)?(e=!0,no(t)):e=!1,lr(t,n),uf(t,r,i),Ul(t,r,i,n),tu(null,t,r,!0,e,n);case 19:return Gf(e,t,n);case 22:return Wf(e,t,n)}throw Error(E(156,t.tag))};function Sd(e,t){return Xs(e,t)}function Cm(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ct(e,t,n,r){return new Cm(e,t,n,r)}function xu(e){return e=e.prototype,!(!e||!e.isReactComponent)}function bm(e){if(typeof e=="function")return xu(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Pa)return 11;if(e===Ra)return 14}return 2}function un(e,t){var n=e.alternate;return n===null?(n=ct(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Fo(e,t,n,r,i,o){var a=2;if(r=e,typeof e=="function")xu(e)&&(a=1);else if(typeof e=="string")a=5;else e:switch(e){case Wn:return _n(n.children,i,o,t);case Ea:a=8,i|=8;break;case Oa:return e=ct(12,n,t,i|2),e.elementType=Oa,e.lanes=o,e;case Ta:return e=ct(13,n,t,i),e.elementType=Ta,e.lanes=o,e;case _a:return e=ct(19,n,t,i),e.elementType=_a,e.lanes=o,e;case Ps:return No(n,i,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Es:a=10;break e;case Os:a=9;break e;case Pa:a=11;break e;case Ra:a=14;break e;case Qt:a=16,r=null;break e}throw Error(E(130,e==null?e:typeof e,""))}return t=ct(a,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function _n(e,t,n,r){return e=ct(7,e,r,t),e.lanes=n,e}function No(e,t,n,r){return e=ct(22,e,r,t),e.elementType=Ps,e.lanes=n,e.stateNode={isHidden:!1},e}function ku(e,t,n){return e=ct(6,e,null,t),e.lanes=n,e}function Cu(e,t,n){return t=ct(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Em(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Ga(0),this.expirationTimes=Ga(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ga(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function bu(e,t,n,r,i,o,a,l,u){return e=new Em(e,t,n,l,u),t===1?(t=1,o===!0&&(t|=8)):t=0,o=ct(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},$l(o),e}function Om(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Qn,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function xd(e){if(!e)return Zt;e=e._reactInternals;e:{if(yn(e)!==e||e.tag!==1)throw Error(E(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(He(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(E(171))}if(e.tag===1){var n=e.type;if(He(n))return qc(e,n,t)}return t}function kd(e,t,n,r,i,o,a,l,u){return e=bu(n,r,!0,e,i,o,a,l,u),e.context=xd(null),n=e.current,r=ze(),i=an(n),o=Lt(r,i),o.callback=t!=null?t:null,tn(n,o,i),e.current.lanes=i,Lr(e,i,r),qe(e,r),e}function Mo(e,t,n,r){var i=t.current,o=ze(),a=an(i);return n=xd(n),t.context===null?t.context=n:t.pendingContext=n,t=Lt(o,a),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=tn(i,t,a),e!==null&&(gt(e,i,a,o),so(e,i,a)),a}function Lo(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function Cd(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Eu(e,t){Cd(e,t),(e=e.alternate)&&Cd(e,t)}function Pm(){return null}var bd=typeof reportError=="function"?reportError:function(e){console.error(e)};function Ou(e){this._internalRoot=e}Io.prototype.render=Ou.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(E(409));Mo(e,t,null,null)},Io.prototype.unmount=Ou.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;On(function(){Mo(null,e,null,null)}),t[Rt]=null}};function Io(e){this._internalRoot=e}Io.prototype.unstable_scheduleHydration=function(e){if(e){var t=oc();e={blockedOn:null,target:e,priority:t};for(var n=0;n<qt.length&&t!==0&&t<qt[n].priority;n++);qt.splice(n,0,e),n===0&&uc(e)}};function Pu(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function $o(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function Ed(){}function Tm(e,t,n,r,i){if(i){if(typeof r=="function"){var o=r;r=function(){var s=Lo(a);o.call(s)}}var a=kd(t,r,e,0,null,!1,!1,"",Ed);return e._reactRootContainer=a,e[Rt]=a.current,Kr(e.nodeType===8?e.parentNode:e),On(),a}for(;i=e.lastChild;)e.removeChild(i);if(typeof r=="function"){var l=r;r=function(){var s=Lo(u);l.call(s)}}var u=bu(e,0,!1,null,null,!1,!1,"",Ed);return e._reactRootContainer=u,e[Rt]=u.current,Kr(e.nodeType===8?e.parentNode:e),On(function(){Mo(t,u,n,r)}),u}function Ao(e,t,n,r,i){var o=n._reactRootContainer;if(o){var a=o;if(typeof i=="function"){var l=i;i=function(){var u=Lo(a);l.call(u)}}Mo(t,a,e,i)}else a=Tm(n,t,e,i,r);return Lo(a)}rc=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Mr(t.pendingLanes);n!==0&&(Xa(t,n|1),qe(t,me()),!(B&6)&&(hr=me()+500,Jt()))}break;case 13:On(function(){var r=Mt(e,1);if(r!==null){var i=ze();gt(r,e,1,i)}}),Eu(e,1)}},Za=function(e){if(e.tag===13){var t=Mt(e,134217728);if(t!==null){var n=ze();gt(t,e,134217728,n)}Eu(e,134217728)}},ic=function(e){if(e.tag===13){var t=an(e),n=Mt(e,t);if(n!==null){var r=ze();gt(n,e,t,r)}Eu(e,t)}},oc=function(){return X},ac=function(e,t){var n=X;try{return X=e,t()}finally{X=n}},Ha=function(e,t,n){switch(t){case"input":if(Ia(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=eo(r);if(!i)throw Error(E(90));Rs(r),Ia(r,i)}}}break;case"textarea":Ls(e,n);break;case"select":t=n.value,t!=null&&Hn(e,!!n.multiple,t,!1)}},Hs=gu,Bs=On;var _m={usingClientEntryPoint:!1,Events:[Zr,er,eo,Qs,Ws,gu]},di={findFiberByHostInstance:gn,bundleType:0,version:"18.2.0",rendererPackageName:"react-dom"},Rm={bundleType:di.bundleType,version:di.version,rendererPackageName:di.rendererPackageName,rendererConfig:di.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:_t.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Ks(e),e===null?null:e.stateNode},findFiberByHostInstance:di.findFiberByHostInstance||Pm,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.2.0-next-9e3b772b8-20220608"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!="undefined"){var Uo=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Uo.isDisabled&&Uo.supportsFiber)try{Li=Uo.inject(Rm),St=Uo}catch(e){}}Ye.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=_m,Ye.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Pu(t))throw Error(E(200));return Om(e,t,null,n)},Ye.createRoot=function(e,t){if(!Pu(e))throw Error(E(299));var n=!1,r="",i=bd;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=bu(e,1,!1,null,null,n,!1,r,i),e[Rt]=t.current,Kr(e.nodeType===8?e.parentNode:e),new Ou(t)},Ye.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(E(188)):(e=Object.keys(e).join(","),Error(E(268,e)));return e=Ks(t),e=e===null?null:e.stateNode,e},Ye.flushSync=function(e){return On(e)},Ye.hydrate=function(e,t,n){if(!$o(t))throw Error(E(200));return Ao(null,e,t,!0,n)},Ye.hydrateRoot=function(e,t,n){if(!Pu(e))throw Error(E(405));var r=n!=null&&n.hydratedSources||null,i=!1,o="",a=bd;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(o=n.identifierPrefix),n.onRecoverableError!==void 0&&(a=n.onRecoverableError)),t=kd(t,null,e,1,n!=null?n:null,i,!1,o,a),e[Rt]=t.current,Kr(e),r)for(e=0;e<r.length;e++)n=r[e],i=n._getVersion,i=i(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,i]:t.mutableSourceEagerHydrationData.push(n,i);return new Io(t)},Ye.render=function(e,t,n){if(!$o(t))throw Error(E(200));return Ao(null,e,t,!1,n)},Ye.unmountComponentAtNode=function(e){if(!$o(e))throw Error(E(40));return e._reactRootContainer?(On(function(){Ao(null,null,e,!1,function(){e._reactRootContainer=null,e[Rt]=null})}),!0):!1},Ye.unstable_batchedUpdates=gu,Ye.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!$o(n))throw Error(E(200));if(e==null||e._reactInternals===void 0)throw Error(E(38));return Ao(e,t,n,!1,r)},Ye.version="18.2.0-next-9e3b772b8-20220608";function Od(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__=="undefined"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Od)}catch(e){console.error(e)}}Od(),gs.exports=Ye;var Pd=gs.exports;const Dm=ve(Pd);var Td=Pd;Sa.createRoot=Td.createRoot,Sa.hydrateRoot=Td.hydrateRoot;var Fm=Object.defineProperty,Nm=(e,t,n)=>t in e?Fm(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tu=(e,t,n)=>(Nm(e,typeof t!="symbol"?t+"":t,n),n);let Mm=class{constructor(){Tu(this,"current",this.detect()),Tu(this,"handoffState","pending"),Tu(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 this.current==="server"}get isClient(){return this.current==="client"}detect(){return typeof window=="undefined"||typeof document=="undefined"?"server":"client"}handoff(){this.handoffState==="pending"&&(this.handoffState="complete")}get isHandoffComplete(){return this.handoffState==="complete"}},Rn=new Mm,Me=(e,t)=>{Rn.isServer?S.useEffect(e,t):S.useLayoutEffect(e,t)};function At(e){let t=S.useRef(e);return Me(()=>{t.current=e},[e]),t}function _u(e,t){let[n,r]=S.useState(e),i=At(e);return Me(()=>r(i.current),[i,r,...t]),n}function Lm(e){typeof queueMicrotask=="function"?queueMicrotask(e):Promise.resolve().then(e).catch(t=>setTimeout(()=>{throw t}))}function Dn(){let e=[],t={addEventListener(n,r,i,o){return n.addEventListener(r,i,o),t.add(()=>n.removeEventListener(r,i,o))},requestAnimationFrame(...n){let r=requestAnimationFrame(...n);return t.add(()=>cancelAnimationFrame(r))},nextFrame(...n){return t.requestAnimationFrame(()=>t.requestAnimationFrame(...n))},setTimeout(...n){let r=setTimeout(...n);return t.add(()=>clearTimeout(r))},microTask(...n){let r={current:!0};return Lm(()=>{r.current&&n[0]()}),t.add(()=>{r.current=!1})},style(n,r,i){let o=n.style.getPropertyValue(r);return Object.assign(n.style,{[r]:i}),this.add(()=>{Object.assign(n.style,{[r]:o})})},group(n){let r=Dn();return n(r),this.add(()=>r.dispose())},add(n){return e.push(n),()=>{let r=e.indexOf(n);if(r>=0)for(let i of e.splice(r,1))i()}},dispose(){for(let n of e.splice(0))n()}};return t}function hi(){let[e]=S.useState(Dn);return S.useEffect(()=>()=>e.dispose(),[e]),e}let V=function(e){let t=At(e);return Y.useCallback((...n)=>t.current(...n),[t])};function Ru(){let[e,t]=S.useState(Rn.isHandoffComplete);return e&&Rn.isHandoffComplete===!1&&t(!1),S.useEffect(()=>{e!==!0&&t(!0)},[e]),S.useEffect(()=>Rn.handoff(),[]),e}var _d;let pi=(_d=Y.useId)!=null?_d:function(){let e=Ru(),[t,n]=Y.useState(e?()=>Rn.nextId():null);return Me(()=>{t===null&&n(Rn.nextId())},[t]),t!=null?""+t:void 0};function Pe(e,t,...n){if(e in t){let i=t[e];return typeof i=="function"?i(...n):i}let r=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map(i=>`"${i}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,Pe),r}function Rd(e){return Rn.isServer?null:e instanceof Node?e.ownerDocument:e!=null&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}let Dd=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(e=>`${e}:not([tabindex='-1'])`).join(",");var Im=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e))(Im||{}),$m=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))($m||{}),Am=(e=>(e[e.Previous=-1]="Previous",e[e.Next=1]="Next",e))(Am||{}),Fd=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(Fd||{});function Um(e,t=0){var n;return e===((n=Rd(e))==null?void 0:n.body)?!1:Pe(t,{[0](){return e.matches(Dd)},[1](){let r=e;for(;r!==null;){if(r.matches(Dd))return!0;r=r.parentElement}return!1}})}var zm=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(zm||{});typeof window!="undefined"&&typeof document!="undefined"&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{e.detail===1?delete document.documentElement.dataset.headlessuiFocusVisible:e.detail===0&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));function jm(e,t=n=>n){return e.slice().sort((n,r)=>{let i=t(n),o=t(r);if(i===null||o===null)return 0;let a=i.compareDocumentPosition(o);return a&Node.DOCUMENT_POSITION_FOLLOWING?-1:a&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function Du(e,t,n){let r=At(t);S.useEffect(()=>{function i(o){r.current(o)}return document.addEventListener(e,i,n),()=>document.removeEventListener(e,i,n)},[e,n])}function Qm(e,t,n=!0){let r=S.useRef(!1);S.useEffect(()=>{requestAnimationFrame(()=>{r.current=n})},[n]);function i(a,l){if(!r.current||a.defaultPrevented)return;let u=function f(p){return typeof p=="function"?f(p()):Array.isArray(p)||p instanceof Set?p:[p]}(e),s=l(a);if(s!==null&&s.getRootNode().contains(s)){for(let f of u){if(f===null)continue;let p=f instanceof HTMLElement?f:f.current;if(p!=null&&p.contains(s)||a.composed&&a.composedPath().includes(p))return}return!Um(s,Fd.Loose)&&s.tabIndex!==-1&&a.preventDefault(),t(a,s)}}let o=S.useRef(null);Du("mousedown",a=>{var l,u;r.current&&(o.current=((u=(l=a.composedPath)==null?void 0:l.call(a))==null?void 0:u[0])||a.target)},!0),Du("click",a=>{o.current&&(i(a,()=>o.current),o.current=null)},!0),Du("blur",a=>i(a,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}function Nd(e){var t;if(e.type)return e.type;let n=(t=e.as)!=null?t:"button";if(typeof n=="string"&&n.toLowerCase()==="button")return"button"}function Wm(e,t){let[n,r]=S.useState(()=>Nd(e));return Me(()=>{r(Nd(e))},[e.type,e.as]),Me(()=>{n||t.current&&t.current instanceof HTMLButtonElement&&!t.current.hasAttribute("type")&&r("button")},[n,t]),n}let Hm=Symbol();function Fn(...e){let t=S.useRef(e);S.useEffect(()=>{t.current=e},[e]);let n=V(r=>{for(let i of t.current)i!=null&&(typeof i=="function"?i(r):i.current=r)});return e.every(r=>r==null||(r==null?void 0:r[Hm]))?void 0:n}function Bm({container:e,accept:t,walk:n,enabled:r=!0}){let i=S.useRef(t),o=S.useRef(n);S.useEffect(()=>{i.current=t,o.current=n},[t,n]),Me(()=>{if(!e||!r)return;let a=Rd(e);if(!a)return;let l=i.current,u=o.current,s=Object.assign(p=>l(p),{acceptNode:l}),f=a.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,s,!1);for(;f.nextNode();)u(f.currentNode)},[e,r,i,o])}function Vm(e){throw new Error("Unexpected object: "+e)}var Te=(e=>(e[e.First=0]="First",e[e.Previous=1]="Previous",e[e.Next=2]="Next",e[e.Last=3]="Last",e[e.Specific=4]="Specific",e[e.Nothing=5]="Nothing",e))(Te||{});function qm(e,t){let n=t.resolveItems();if(n.length<=0)return null;let r=t.resolveActiveIndex(),i=r!=null?r:-1,o=(()=>{switch(e.focus){case 0:return n.findIndex(a=>!t.resolveDisabled(a));case 1:{let a=n.slice().reverse().findIndex((l,u,s)=>i!==-1&&s.length-u-1>=i?!1:!t.resolveDisabled(l));return a===-1?a:n.length-1-a}case 2:return n.findIndex((a,l)=>l<=i?!1:!t.resolveDisabled(a));case 3:{let a=n.slice().reverse().findIndex(l=>!t.resolveDisabled(l));return a===-1?a:n.length-1-a}case 4:return n.findIndex(a=>t.resolveId(a)===e.id);case 5:return null;default:Vm(e)}})();return o===-1?r:o}function Fu(...e){return e.filter(Boolean).join(" ")}var zo=(e=>(e[e.None=0]="None",e[e.RenderStrategy=1]="RenderStrategy",e[e.Static=2]="Static",e))(zo||{}),Ut=(e=>(e[e.Unmount=0]="Unmount",e[e.Hidden=1]="Hidden",e))(Ut||{});function zt({ourProps:e,theirProps:t,slot:n,defaultTag:r,features:i,visible:o=!0,name:a}){let l=Md(t,e);if(o)return jo(l,n,r,a);let u=i!=null?i:0;if(u&2){let s=l,{static:p=!1}=s,c=it(s,["static"]);if(p)return jo(c,n,r,a)}if(u&1){let f=l,{unmount:p=!0}=f,c=it(f,["unmount"]);return Pe(p?0:1,{[0](){return null},[1](){return jo(ge(G({},c),{hidden:!0,style:{display:"none"}}),n,r,a)}})}return jo(l,n,r,a)}function jo(e,t={},n,r){let p=Mu(e,["unmount","static"]),{as:i=n,children:o,refName:a="ref"}=p,l=it(p,["as","children","refName"]),u=e.ref!==void 0?{[a]:e.ref}:{},s=typeof o=="function"?o(t):o;"className"in l&&l.className&&typeof l.className=="function"&&(l.className=l.className(t));let f={};if(t){let c=!1,v=[];for(let[m,g]of Object.entries(t))typeof g=="boolean"&&(c=!0),g===!0&&v.push(m);c&&(f["data-headlessui-state"]=v.join(" "))}if(i===S.Fragment&&Object.keys(Nu(l)).length>0){if(!S.isValidElement(s)||Array.isArray(s)&&s.length>1)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(l).map(g=>` - ${g}`).join(`
|
|
41
41
|
`),"","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(g=>` - ${g}`).join(`
|
|
42
42
|
`)].join(`
|
|
43
|
-
`));let c=s.props,v=typeof(c==null?void 0:c.className)=="function"?(...g)=>Fu(c==null?void 0:c.className(...g),l.className):Fu(c==null?void 0:c.className,l.className),m=v?{className:v}:{};return S.cloneElement(s,Object.assign({},Md(s.props,Nu(Mu(l,["ref"]))),f,u,Ym(s.ref,u.ref),m))}return S.createElement(i,Object.assign({},Mu(l,["ref"]),i!==S.Fragment&&u,i!==S.Fragment&&f),s)}function Ym(...e){return{ref:e.every(t=>t==null)?void 0:t=>{for(let n of e)n!=null&&(typeof n=="function"?n(t):n.current=t)}}}function Md(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},n={};for(let r of e)for(let i in r)i.startsWith("on")&&typeof r[i]=="function"?(n[i]!=null||(n[i]=[]),n[i].push(r[i])):t[i]=r[i];if(t.disabled||t["aria-disabled"])return Object.assign(t,Object.fromEntries(Object.keys(n).map(r=>[r,void 0])));for(let r in n)Object.assign(t,{[r](i,...o){let a=n[r];for(let l of a){if((i instanceof Event||(i==null?void 0:i.nativeEvent)instanceof Event)&&i.defaultPrevented)return;l(i,...o)}}});return t}function Et(e){var t;return Object.assign(S.forwardRef(e),{displayName:(t=e.displayName)!=null?t:e.name})}function Nu(e){let t=Object.assign({},e);for(let n in t)t[n]===void 0&&delete t[n];return t}function Mu(e,t=[]){let n=Object.assign({},e);for(let r of t)r in n&&delete n[r];return n}function Km(e){let t=e.parentElement,n=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(n=t),t=t.parentElement;let r=(t==null?void 0:t.getAttribute("disabled"))==="";return r&&Gm(n)?!1:r}function Gm(e){if(!e)return!1;let t=e.previousElementSibling;for(;t!==null;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}function Ld(e={},t=null,n=[]){for(let[r,i]of Object.entries(e))$d(n,Id(t,r),i);return n}function Id(e,t){return e?e+"["+t+"]":t}function $d(e,t,n){if(Array.isArray(n))for(let[r,i]of n.entries())$d(e,Id(t,r.toString()),i);else n instanceof Date?e.push([t,n.toISOString()]):typeof n=="boolean"?e.push([t,n?"1":"0"]):typeof n=="string"?e.push([t,n]):typeof n=="number"?e.push([t,`${n}`]):n==null?e.push([t,""]):Ld(n,t,e)}let Xm="div";var Ad=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(Ad||{});function Zm(e,t){let o=e,{features:n=1}=o,r=it(o,["features"]),i={ref:t,"aria-hidden":(n&2)===2?!0:void 0,style:G({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"},(n&4)===4&&(n&2)!==2&&{display:"none"})};return zt({ourProps:i,theirProps:r,slot:{},defaultTag:Xm,name:"Hidden"})}let Jm=Et(Zm),Lu=S.createContext(null);Lu.displayName="OpenClosedContext";var et=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(et||{});function Iu(){return S.useContext(Lu)}function Ud({value:e,children:t}){return Y.createElement(Lu.Provider,{value:e},t)}var je=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(je||{});function e0(e,t,n){let[r,i]=S.useState(n),o=e!==void 0,a=S.useRef(o),l=S.useRef(!1),u=S.useRef(!1);return o&&!a.current&&!l.current?(l.current=!0,a.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&&a.current&&!u.current&&(u.current=!0,a.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.")),[o?e:r,V(s=>(o||i(s),t==null?void 0:t(s)))]}function zd(e,t){let n=S.useRef([]),r=V(e);S.useEffect(()=>{let i=[...n.current];for(let[o,a]of t.entries())if(n.current[o]!==a){let l=r(t,i);return n.current=t,l}},[r,...t])}function jd(e){return[e.screenX,e.screenY]}function t0(){let e=S.useRef([-1,-1]);return{wasMoved(t){let n=jd(t);return e.current[0]===n[0]&&e.current[1]===n[1]?!1:(e.current=n,!0)},update(t){e.current=jd(t)}}}function n0(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function r0(){return/Android/gi.test(window.navigator.userAgent)}function i0(){return n0()||r0()}var o0=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(o0||{}),a0=(e=>(e[e.Single=0]="Single",e[e.Multi=1]="Multi",e))(a0||{}),l0=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(l0||{}),u0=(e=>(e[e.OpenCombobox=0]="OpenCombobox",e[e.CloseCombobox=1]="CloseCombobox",e[e.GoToOption=2]="GoToOption",e[e.RegisterOption=3]="RegisterOption",e[e.UnregisterOption=4]="UnregisterOption",e[e.RegisterLabel=5]="RegisterLabel",e))(u0||{});function $u(e,t=n=>n){let n=e.activeOptionIndex!==null?e.options[e.activeOptionIndex]:null,r=jm(t(e.options.slice()),o=>o.dataRef.current.domRef.current),i=n?r.indexOf(n):null;return i===-1&&(i=null),{options:r,activeOptionIndex:i}}let s0={[1](e){var t;return(t=e.dataRef.current)!=null&&t.disabled||e.comboboxState===1?e:ge(G({},e),{activeOptionIndex:null,comboboxState:1})},[0](e){var t;if((t=e.dataRef.current)!=null&&t.disabled||e.comboboxState===0)return e;let n=e.activeOptionIndex;if(e.dataRef.current){let{isSelected:r}=e.dataRef.current,i=e.options.findIndex(o=>r(o.dataRef.current.value));i!==-1&&(n=i)}return ge(G({},e),{comboboxState:0,activeOptionIndex:n})},[2](e,t){var n,r,i,o;if((n=e.dataRef.current)!=null&&n.disabled||(r=e.dataRef.current)!=null&&r.optionsRef.current&&!((i=e.dataRef.current)!=null&&i.optionsPropsRef.current.static)&&e.comboboxState===1)return e;let a=$u(e);if(a.activeOptionIndex===null){let u=a.options.findIndex(s=>!s.dataRef.current.disabled);u!==-1&&(a.activeOptionIndex=u)}let l=qm(t,{resolveItems:()=>a.options,resolveActiveIndex:()=>a.activeOptionIndex,resolveId:u=>u.id,resolveDisabled:u=>u.dataRef.current.disabled});return ge(G(G({},e),a),{activeOptionIndex:l,activationTrigger:(o=t.trigger)!=null?o:1})},[3]:(e,t)=>{var n,r;let i={id:t.id,dataRef:t.dataRef},o=$u(e,l=>[...l,i]);e.activeOptionIndex===null&&(n=e.dataRef.current)!=null&&n.isSelected(t.dataRef.current.value)&&(o.activeOptionIndex=o.options.indexOf(i));let a=ge(G(G({},e),o),{activationTrigger:1});return(r=e.dataRef.current)!=null&&r.__demoMode&&e.dataRef.current.value===void 0&&(a.activeOptionIndex=0),a},[4]:(e,t)=>{let n=$u(e,r=>{let i=r.findIndex(o=>o.id===t.id);return i!==-1&&r.splice(i,1),r});return ge(G(G({},e),n),{activationTrigger:1})},[5]:(e,t)=>ge(G({},e),{labelId:t.id})},Au=S.createContext(null);Au.displayName="ComboboxActionsContext";function vi(e){let t=S.useContext(Au);if(t===null){let n=new Error(`<${e} /> is missing a parent <Combobox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,vi),n}return t}let Uu=S.createContext(null);Uu.displayName="ComboboxDataContext";function vr(e){let t=S.useContext(Uu);if(t===null){let n=new Error(`<${e} /> is missing a parent <Combobox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,vr),n}return t}function c0(e,t){return Pe(t.type,s0,e,t)}let f0=S.Fragment;function d0(e,t){let nt=e,{value:n,defaultValue:r,onChange:i,form:o,name:a,by:l=(I,W)=>I===W,disabled:u=!1,__demoMode:s=!1,nullable:f=!1,multiple:p=!1}=nt,c=it(nt,["value","defaultValue","onChange","form","name","by","disabled","__demoMode","nullable","multiple"]),[v=p?[]:void 0,m]=e0(n,i,r),[g,x]=S.useReducer(c0,{dataRef:S.createRef(),comboboxState:s?0:1,options:[],activeOptionIndex:null,activationTrigger:1,labelId:null}),h=S.useRef(!1),d=S.useRef({static:!1,hold:!1}),y=S.useRef(null),w=S.useRef(null),C=S.useRef(null),k=S.useRef(null),b=V(typeof l=="string"?(I,W)=>{let pe=l;return(I==null?void 0:I[pe])===(W==null?void 0:W[pe])}:l),O=S.useCallback(I=>Pe(_.mode,{[1]:()=>v.some(W=>b(W,I)),[0]:()=>b(v,I)}),[v]),_=S.useMemo(()=>ge(G({},g),{optionsPropsRef:d,labelRef:y,inputRef:w,buttonRef:C,optionsRef:k,value:v,defaultValue:r,disabled:u,mode:p?1:0,get activeOptionIndex(){if(h.current&&g.activeOptionIndex===null&&g.options.length>0){let I=g.options.findIndex(W=>!W.dataRef.current.disabled);if(I!==-1)return I}return g.activeOptionIndex},compare:b,isSelected:O,nullable:f,__demoMode:s}),[v,r,u,p,f,s,g]),T=S.useRef(_.activeOptionIndex!==null?_.options[_.activeOptionIndex]:null);S.useEffect(()=>{let I=_.activeOptionIndex!==null?_.options[_.activeOptionIndex]:null;T.current!==I&&(T.current=I)}),Me(()=>{g.dataRef.current=_},[_]),Qm([_.buttonRef,_.inputRef,_.optionsRef],()=>M.closeCombobox(),_.comboboxState===0);let L=S.useMemo(()=>({open:_.comboboxState===0,disabled:u,activeIndex:_.activeOptionIndex,activeOption:_.activeOptionIndex===null?null:_.options[_.activeOptionIndex].dataRef.current.value,value:v}),[_,u,v]),R=V(I=>{let W=_.options.find(pe=>pe.id===I);W&&N(W.dataRef.current.value)}),$=V(()=>{if(_.activeOptionIndex!==null){let{dataRef:I,id:W}=_.options[_.activeOptionIndex];N(I.current.value),M.goToOption(Te.Specific,W)}}),z=V(()=>{x({type:0}),h.current=!0}),U=V(()=>{x({type:1}),h.current=!1}),j=V((I,W,pe)=>(h.current=!1,I===Te.Specific?x({type:2,focus:Te.Specific,id:W,trigger:pe}):x({type:2,focus:I,trigger:pe}))),J=V((I,W)=>(x({type:3,id:I,dataRef:W}),()=>{var pe;((pe=T.current)==null?void 0:pe.id)===I&&(h.current=!0),x({type:4,id:I})})),P=V(I=>(x({type:5,id:I}),()=>x({type:5,id:null}))),N=V(I=>Pe(_.mode,{[0](){return m==null?void 0:m(I)},[1](){let W=_.value.slice(),pe=W.findIndex(pn=>b(pn,I));return pe===-1?W.push(I):W.splice(pe,1),m==null?void 0:m(W)}})),M=S.useMemo(()=>({onChange:N,registerOption:J,registerLabel:P,goToOption:j,closeCombobox:U,openCombobox:z,selectActiveOption:$,selectOption:R}),[]),q=t===null?{}:{ref:t},Q=S.useRef(null),hn=hi();return S.useEffect(()=>{Q.current&&r!==void 0&&hn.addEventListener(Q.current,"reset",()=>{N(r)})},[Q,N]),Y.createElement(Au.Provider,{value:M},Y.createElement(Uu.Provider,{value:_},Y.createElement(Ud,{value:Pe(_.comboboxState,{[0]:et.Open,[1]:et.Closed})},a!=null&&v!=null&&Ld({[a]:v}).map(([I,W],pe)=>Y.createElement(Jm,G({features:Ad.Hidden,ref:pe===0?pn=>{var bi;Q.current=(bi=pn==null?void 0:pn.closest("form"))!=null?bi:null}:void 0},Nu({key:I,as:"input",type:"hidden",hidden:!0,readOnly:!0,form:o,name:I,value:W})))),zt({ourProps:q,theirProps:c,slot:L,defaultTag:f0,name:"Combobox"}))))}let h0="input";function p0(e,t){var n,r,i,o;let a=pi(),L=e,{id:l=`headlessui-combobox-input-${a}`,onChange:u,displayValue:s,type:f="text"}=L,p=it(L,["id","onChange","displayValue","type"]),c=vr("Combobox.Input"),v=vi("Combobox.Input"),m=Fn(c.inputRef,t),g=S.useRef(!1),x=hi(),h=function(){var R;return typeof s=="function"&&c.value!==void 0?(R=s(c.value))!=null?R:"":typeof c.value=="string"?c.value:""}();zd(([R,$],[z,U])=>{g.current||c.inputRef.current&&(U===0&&$===1||R!==z)&&(c.inputRef.current.value=R)},[h,c.comboboxState]),zd(([R],[$])=>{if(R===0&&$===1){let z=c.inputRef.current;if(!z)return;let U=z.value,{selectionStart:j,selectionEnd:J,selectionDirection:P}=z;z.value="",z.value=U,P!==null?z.setSelectionRange(j,J,P):z.setSelectionRange(j,J)}},[c.comboboxState]);let d=S.useRef(!1),y=V(()=>{d.current=!0}),w=V(()=>{setTimeout(()=>{d.current=!1})}),C=V(R=>{switch(g.current=!0,R.key){case je.Backspace:case je.Delete:if(c.mode!==0||!c.nullable)return;let $=R.currentTarget;x.requestAnimationFrame(()=>{$.value===""&&(v.onChange(null),c.optionsRef.current&&(c.optionsRef.current.scrollTop=0),v.goToOption(Te.Nothing))});break;case je.Enter:if(g.current=!1,c.comboboxState!==0||d.current)return;if(R.preventDefault(),R.stopPropagation(),c.activeOptionIndex===null){v.closeCombobox();return}v.selectActiveOption(),c.mode===0&&v.closeCombobox();break;case je.ArrowDown:return g.current=!1,R.preventDefault(),R.stopPropagation(),Pe(c.comboboxState,{[0]:()=>{v.goToOption(Te.Next)},[1]:()=>{v.openCombobox()}});case je.ArrowUp:return g.current=!1,R.preventDefault(),R.stopPropagation(),Pe(c.comboboxState,{[0]:()=>{v.goToOption(Te.Previous)},[1]:()=>{v.openCombobox(),x.nextFrame(()=>{c.value||v.goToOption(Te.Last)})}});case je.Home:if(R.shiftKey)break;return g.current=!1,R.preventDefault(),R.stopPropagation(),v.goToOption(Te.First);case je.PageUp:return g.current=!1,R.preventDefault(),R.stopPropagation(),v.goToOption(Te.First);case je.End:if(R.shiftKey)break;return g.current=!1,R.preventDefault(),R.stopPropagation(),v.goToOption(Te.Last);case je.PageDown:return g.current=!1,R.preventDefault(),R.stopPropagation(),v.goToOption(Te.Last);case je.Escape:return g.current=!1,c.comboboxState!==0?void 0:(R.preventDefault(),c.optionsRef.current&&!c.optionsPropsRef.current.static&&R.stopPropagation(),v.closeCombobox());case je.Tab:if(g.current=!1,c.comboboxState!==0)return;c.mode===0&&v.selectActiveOption(),v.closeCombobox();break}}),k=V(R=>{v.openCombobox(),u==null||u(R)}),b=V(()=>{g.current=!1}),O=_u(()=>{if(c.labelId)return[c.labelId].join(" ")},[c.labelId]),_=S.useMemo(()=>({open:c.comboboxState===0,disabled:c.disabled}),[c]),T={ref:m,id:l,role:"combobox",type:f,"aria-controls":(n=c.optionsRef.current)==null?void 0:n.id,"aria-expanded":c.disabled?void 0:c.comboboxState===0,"aria-activedescendant":c.activeOptionIndex===null||(r=c.options[c.activeOptionIndex])==null?void 0:r.id,"aria-labelledby":O,"aria-autocomplete":"list",defaultValue:(o=(i=e.defaultValue)!=null?i:c.defaultValue!==void 0?s==null?void 0:s(c.defaultValue):null)!=null?o:c.defaultValue,disabled:c.disabled,onCompositionStart:y,onCompositionEnd:w,onKeyDown:C,onChange:k,onBlur:b};return zt({ourProps:T,theirProps:p,slot:_,defaultTag:h0,name:"Combobox.Input"})}let v0="button";function m0(e,t){var n;let r=vr("Combobox.Button"),i=vi("Combobox.Button"),o=Fn(r.buttonRef,t),a=pi(),g=e,{id:l=`headlessui-combobox-button-${a}`}=g,u=it(g,["id"]),s=hi(),f=V(x=>{switch(x.key){case je.ArrowDown:return x.preventDefault(),x.stopPropagation(),r.comboboxState===1&&i.openCombobox(),s.nextFrame(()=>{var h;return(h=r.inputRef.current)==null?void 0:h.focus({preventScroll:!0})});case je.ArrowUp:return x.preventDefault(),x.stopPropagation(),r.comboboxState===1&&(i.openCombobox(),s.nextFrame(()=>{r.value||i.goToOption(Te.Last)})),s.nextFrame(()=>{var h;return(h=r.inputRef.current)==null?void 0:h.focus({preventScroll:!0})});case je.Escape:return r.comboboxState!==0?void 0:(x.preventDefault(),r.optionsRef.current&&!r.optionsPropsRef.current.static&&x.stopPropagation(),i.closeCombobox(),s.nextFrame(()=>{var h;return(h=r.inputRef.current)==null?void 0:h.focus({preventScroll:!0})}));default:return}}),p=V(x=>{if(Km(x.currentTarget))return x.preventDefault();r.comboboxState===0?i.closeCombobox():(x.preventDefault(),i.openCombobox()),s.nextFrame(()=>{var h;return(h=r.inputRef.current)==null?void 0:h.focus({preventScroll:!0})})}),c=_u(()=>{if(r.labelId)return[r.labelId,l].join(" ")},[r.labelId,l]),v=S.useMemo(()=>({open:r.comboboxState===0,disabled:r.disabled,value:r.value}),[r]),m={ref:o,id:l,type:Wm(e,r.buttonRef),tabIndex:-1,"aria-haspopup":"listbox","aria-controls":(n=r.optionsRef.current)==null?void 0:n.id,"aria-expanded":r.disabled?void 0:r.comboboxState===0,"aria-labelledby":c,disabled:r.disabled,onClick:p,onKeyDown:f};return zt({ourProps:m,theirProps:u,slot:v,defaultTag:v0,name:"Combobox.Button"})}let y0="label";function g0(e,t){let n=pi(),f=e,{id:r=`headlessui-combobox-label-${n}`}=f,i=it(f,["id"]),o=vr("Combobox.Label"),a=vi("Combobox.Label"),l=Fn(o.labelRef,t);Me(()=>a.registerLabel(r),[r]);let u=V(()=>{var p;return(p=o.inputRef.current)==null?void 0:p.focus({preventScroll:!0})}),s=S.useMemo(()=>({open:o.comboboxState===0,disabled:o.disabled}),[o]);return zt({ourProps:{ref:l,id:r,onClick:u},theirProps:i,slot:s,defaultTag:y0,name:"Combobox.Label"})}let w0="ul",S0=zo.RenderStrategy|zo.Static;function x0(e,t){let n=pi(),v=e,{id:r=`headlessui-combobox-options-${n}`,hold:i=!1}=v,o=it(v,["id","hold"]),a=vr("Combobox.Options"),l=Fn(a.optionsRef,t),u=Iu(),s=(()=>u!==null?(u&et.Open)===et.Open:a.comboboxState===0)();Me(()=>{var m;a.optionsPropsRef.current.static=(m=e.static)!=null?m:!1},[a.optionsPropsRef,e.static]),Me(()=>{a.optionsPropsRef.current.hold=i},[a.optionsPropsRef,i]),Bm({container:a.optionsRef.current,enabled:a.comboboxState===0,accept(m){return m.getAttribute("role")==="option"?NodeFilter.FILTER_REJECT:m.hasAttribute("role")?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT},walk(m){m.setAttribute("role","none")}});let f=_u(()=>{var m,g;return(g=a.labelId)!=null?g:(m=a.buttonRef.current)==null?void 0:m.id},[a.labelId,a.buttonRef.current]),p=S.useMemo(()=>({open:a.comboboxState===0}),[a]),c={"aria-labelledby":f,role:"listbox","aria-multiselectable":a.mode===1?!0:void 0,id:r,ref:l};return zt({ourProps:c,theirProps:o,slot:p,defaultTag:w0,features:S0,visible:s,name:"Combobox.Options"})}let k0="li";function C0(e,t){var n,r;let i=pi(),_=e,{id:o=`headlessui-combobox-option-${i}`,disabled:a=!1,value:l}=_,u=it(_,["id","disabled","value"]),s=vr("Combobox.Option"),f=vi("Combobox.Option"),p=s.activeOptionIndex!==null?s.options[s.activeOptionIndex].id===o:!1,c=s.isSelected(l),v=S.useRef(null),m=At({disabled:a,value:l,domRef:v,textValue:(r=(n=v.current)==null?void 0:n.textContent)==null?void 0:r.toLowerCase()}),g=Fn(t,v),x=V(()=>f.selectOption(o));Me(()=>f.registerOption(o,m),[m,o]);let h=S.useRef(!s.__demoMode);Me(()=>{if(!s.__demoMode)return;let T=Dn();return T.requestAnimationFrame(()=>{h.current=!0}),T.dispose},[]),Me(()=>{if(s.comboboxState!==0||!p||!h.current||s.activationTrigger===0)return;let T=Dn();return T.requestAnimationFrame(()=>{var L,R;(R=(L=v.current)==null?void 0:L.scrollIntoView)==null||R.call(L,{block:"nearest"})}),T.dispose},[v,p,s.comboboxState,s.activationTrigger,s.activeOptionIndex]);let d=V(T=>{if(a)return T.preventDefault();x(),s.mode===0&&f.closeCombobox(),i0()||requestAnimationFrame(()=>{var L;return(L=s.inputRef.current)==null?void 0:L.focus()})}),y=V(()=>{if(a)return f.goToOption(Te.Nothing);f.goToOption(Te.Specific,o)}),w=t0(),C=V(T=>w.update(T)),k=V(T=>{w.wasMoved(T)&&(a||p||f.goToOption(Te.Specific,o,0))}),b=V(T=>{w.wasMoved(T)&&(a||p&&(s.optionsPropsRef.current.hold||f.goToOption(Te.Nothing)))}),O=S.useMemo(()=>({active:p,selected:c,disabled:a}),[p,c,a]);return zt({ourProps:{id:o,ref:g,role:"option",tabIndex:a===!0?void 0:-1,"aria-disabled":a===!0?!0:void 0,"aria-selected":c,disabled:void 0,onClick:d,onFocus:y,onPointerEnter:C,onMouseEnter:C,onPointerMove:k,onMouseMove:k,onPointerLeave:b,onMouseLeave:b},theirProps:u,slot:O,defaultTag:k0,name:"Combobox.Option"})}let b0=Et(d0),E0=Et(m0),O0=Et(p0),P0=Et(g0),T0=Et(x0),_0=Et(C0),Qo=Object.assign(b0,{Input:O0,Button:E0,Label:P0,Options:T0,Option:_0});function zu(){let e=S.useRef(!1);return Me(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function R0(e=0){let[t,n]=S.useState(e),r=zu(),i=S.useCallback(u=>{r.current&&n(s=>s|u)},[t,r]),o=S.useCallback(u=>!!(t&u),[t]),a=S.useCallback(u=>{r.current&&n(s=>s&~u)},[n,r]),l=S.useCallback(u=>{r.current&&n(s=>s^u)},[n]);return{flags:t,addFlag:i,hasFlag:o,removeFlag:a,toggleFlag:l}}function D0(e){let t={called:!1};return(...n)=>{if(!t.called)return t.called=!0,e(...n)}}function ju(e,...t){e&&t.length>0&&e.classList.add(...t)}function Qu(e,...t){e&&t.length>0&&e.classList.remove(...t)}function F0(e,t){let n=Dn();if(!e)return n.dispose;let{transitionDuration:r,transitionDelay:i}=getComputedStyle(e),[o,a]=[r,i].map(u=>{let[s=0]=u.split(",").filter(Boolean).map(f=>f.includes("ms")?parseFloat(f):parseFloat(f)*1e3).sort((f,p)=>p-f);return s}),l=o+a;if(l!==0){n.group(s=>{s.setTimeout(()=>{t(),s.dispose()},l),s.addEventListener(e,"transitionrun",f=>{f.target===f.currentTarget&&s.dispose()})});let u=n.addEventListener(e,"transitionend",s=>{s.target===s.currentTarget&&(t(),u())})}else t();return n.add(()=>t()),n.dispose}function N0(e,t,n,r){let i=n?"enter":"leave",o=Dn(),a=r!==void 0?D0(r):()=>{};i==="enter"&&(e.removeAttribute("hidden"),e.style.display="");let l=Pe(i,{enter:()=>t.enter,leave:()=>t.leave}),u=Pe(i,{enter:()=>t.enterTo,leave:()=>t.leaveTo}),s=Pe(i,{enter:()=>t.enterFrom,leave:()=>t.leaveFrom});return Qu(e,...t.enter,...t.enterTo,...t.enterFrom,...t.leave,...t.leaveFrom,...t.leaveTo,...t.entered),ju(e,...l,...s),o.nextFrame(()=>{Qu(e,...s),ju(e,...u),F0(e,()=>(Qu(e,...l),ju(e,...t.entered),a()))}),o.dispose}function M0({container:e,direction:t,classes:n,onStart:r,onStop:i}){let o=zu(),a=hi(),l=At(t);Me(()=>{let u=Dn();a.add(u.dispose);let s=e.current;if(s&&l.current!=="idle"&&o.current)return u.dispose(),r.current(l.current),u.add(N0(s,n.current,l.current==="enter",()=>{u.dispose(),i.current(l.current)})),u.dispose},[t])}function Nn(e=""){return e.split(" ").filter(t=>t.trim().length>1)}let Wo=S.createContext(null);Wo.displayName="TransitionContext";var L0=(e=>(e.Visible="visible",e.Hidden="hidden",e))(L0||{});function I0(){let e=S.useContext(Wo);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}function $0(){let e=S.useContext(Ho);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}let Ho=S.createContext(null);Ho.displayName="NestingContext";function Bo(e){return"children"in e?Bo(e.children):e.current.filter(({el:t})=>t.current!==null).filter(({state:t})=>t==="visible").length>0}function Qd(e,t){let n=At(e),r=S.useRef([]),i=zu(),o=hi(),a=V((v,m=Ut.Hidden)=>{let g=r.current.findIndex(({el:x})=>x===v);g!==-1&&(Pe(m,{[Ut.Unmount](){r.current.splice(g,1)},[Ut.Hidden](){r.current[g].state="hidden"}}),o.microTask(()=>{var x;!Bo(r)&&i.current&&((x=n.current)==null||x.call(n))}))}),l=V(v=>{let m=r.current.find(({el:g})=>g===v);return m?m.state!=="visible"&&(m.state="visible"):r.current.push({el:v,state:"visible"}),()=>a(v,Ut.Unmount)}),u=S.useRef([]),s=S.useRef(Promise.resolve()),f=S.useRef({enter:[],leave:[],idle:[]}),p=V((v,m,g)=>{u.current.splice(0),t&&(t.chains.current[m]=t.chains.current[m].filter(([x])=>x!==v)),t==null||t.chains.current[m].push([v,new Promise(x=>{u.current.push(x)})]),t==null||t.chains.current[m].push([v,new Promise(x=>{Promise.all(f.current[m].map(([h,d])=>d)).then(()=>x())})]),m==="enter"?s.current=s.current.then(()=>t==null?void 0:t.wait.current).then(()=>g(m)):g(m)}),c=V((v,m,g)=>{Promise.all(f.current[m].splice(0).map(([x,h])=>h)).then(()=>{var x;(x=u.current.shift())==null||x()}).then(()=>g(m))});return S.useMemo(()=>({children:r,register:l,unregister:a,onStart:p,onStop:c,wait:s,chains:f}),[l,a,r,p,c,f,s])}function A0(){}let U0=["beforeEnter","afterEnter","beforeLeave","afterLeave"];function Wd(e){var t;let n={};for(let r of U0)n[r]=(t=e[r])!=null?t:A0;return n}function z0(e){let t=S.useRef(Wd(e));return S.useEffect(()=>{t.current=Wd(e)},[e]),t}let j0="div",Hd=zo.RenderStrategy;function Q0(e,t){let q=e,{beforeEnter:n,afterEnter:r,beforeLeave:i,afterLeave:o,enter:a,enterFrom:l,enterTo:u,entered:s,leave:f,leaveFrom:p,leaveTo:c}=q,v=it(q,["beforeEnter","afterEnter","beforeLeave","afterLeave","enter","enterFrom","enterTo","entered","leave","leaveFrom","leaveTo"]),m=S.useRef(null),g=Fn(m,t),x=v.unmount?Ut.Unmount:Ut.Hidden,{show:h,appear:d,initial:y}=I0(),[w,C]=S.useState(h?"visible":"hidden"),k=$0(),{register:b,unregister:O}=k,_=S.useRef(null);S.useEffect(()=>b(m),[b,m]),S.useEffect(()=>{if(x===Ut.Hidden&&m.current){if(h&&w!=="visible"){C("visible");return}return Pe(w,{hidden:()=>O(m),visible:()=>b(m)})}},[w,m,b,O,h,x]);let T=At({enter:Nn(a),enterFrom:Nn(l),enterTo:Nn(u),entered:Nn(s),leave:Nn(f),leaveFrom:Nn(p),leaveTo:Nn(c)}),L=z0({beforeEnter:n,afterEnter:r,beforeLeave:i,afterLeave:o}),R=Ru();S.useEffect(()=>{if(R&&w==="visible"&&m.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[m,w,R]);let $=y&&!d,z=(()=>!R||$||_.current===h?"idle":h?"enter":"leave")(),U=R0(0),j=V(Q=>Pe(Q,{enter:()=>{U.addFlag(et.Opening),L.current.beforeEnter()},leave:()=>{U.addFlag(et.Closing),L.current.beforeLeave()},idle:()=>{}})),J=V(Q=>Pe(Q,{enter:()=>{U.removeFlag(et.Opening),L.current.afterEnter()},leave:()=>{U.removeFlag(et.Closing),L.current.afterLeave()},idle:()=>{}})),P=Qd(()=>{C("hidden"),O(m)},k);M0({container:m,classes:T,direction:z,onStart:At(Q=>{P.onStart(m,Q,j)}),onStop:At(Q=>{P.onStop(m,Q,J),Q==="leave"&&!Bo(P)&&(C("hidden"),O(m))})}),S.useEffect(()=>{$&&(x===Ut.Hidden?_.current=null:_.current=h)},[h,$,w]);let N=v,M={ref:g};return d&&h&&(N=ge(G({},N),{className:Fu(v.className,...T.current.enter,...T.current.enterFrom)})),Y.createElement(Ho.Provider,{value:P},Y.createElement(Ud,{value:Pe(w,{visible:et.Open,hidden:et.Closed})|U.flags},zt({ourProps:M,theirProps:N,defaultTag:j0,features:Hd,visible:w==="visible",name:"Transition.Child"})))}function W0(e,t){let h=e,{show:n,appear:r=!1,unmount:i}=h,o=it(h,["show","appear","unmount"]),a=S.useRef(null),l=Fn(a,t);Ru();let u=Iu();if(n===void 0&&u!==null&&(n=(u&et.Open)===et.Open),![!0,!1].includes(n))throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[s,f]=S.useState(n?"visible":"hidden"),p=Qd(()=>{f("hidden")}),[c,v]=S.useState(!0),m=S.useRef([n]);Me(()=>{c!==!1&&m.current[m.current.length-1]!==n&&(m.current.push(n),v(!1))},[m,n]);let g=S.useMemo(()=>({show:n,appear:r,initial:c}),[n,r,c]);S.useEffect(()=>{if(n)f("visible");else if(!Bo(p))f("hidden");else{let d=a.current;if(!d)return;let y=d.getBoundingClientRect();y.x===0&&y.y===0&&y.width===0&&y.height===0&&f("hidden")}},[n,p]);let x={unmount:i};return Y.createElement(Ho.Provider,{value:p},Y.createElement(Wo.Provider,{value:g},zt({ourProps:ge(G({},x),{as:S.Fragment,children:Y.createElement(Bd,G(G({ref:l},x),o))}),theirProps:{},defaultTag:S.Fragment,features:Hd,visible:s==="visible",name:"Transition"})))}function H0(e,t){let n=S.useContext(Wo)!==null,r=Iu()!==null;return Y.createElement(Y.Fragment,null,!n&&r?Y.createElement(Wu,G({ref:t},e)):Y.createElement(Bd,G({ref:t},e)))}let Wu=Et(W0),Bd=Et(Q0),B0=Et(H0),Vd=Object.assign(Wu,{Child:B0,Root:Wu});function V0(){return F("div",{"aria-label":"Loading...",role:"status",children:$e("svg",{className:"a1-h-6 a1-w-6 a1-animate-spin",viewBox:"3 3 18 18",children:[F("path",{className:"a1-fill-indigo-200",d:"M12 5C8.13401 5 5 8.13401 5 12C5 15.866 8.13401 19 12 19C15.866 19 19 15.866 19 12C19 8.13401 15.866 5 12 5ZM3 12C3 7.02944 7.02944 3 12 3C16.9706 3 21 7.02944 21 12C21 16.9706 16.9706 21 12 21C7.02944 21 3 16.9706 3 12Z"}),F("path",{className:"a1-fill-indigo-800",d:"M16.9497 7.05015C14.2161 4.31648 9.78392 4.31648 7.05025 7.05015C6.65973 7.44067 6.02656 7.44067 5.63604 7.05015C5.24551 6.65962 5.24551 6.02646 5.63604 5.63593C9.15076 2.12121 14.8492 2.12121 18.364 5.63593C18.7545 6.02646 18.7545 6.65962 18.364 7.05015C17.9734 7.44067 17.3403 7.44067 16.9497 7.05015Z"})]})})}const q0=(e,t,n,r)=>F("li",{className:`${n}`,children:r});function qd({label:e,name:t,items:n,value:r=null,primaryColor:i,secondaryColor:o,status:a=null,onChange:l,getKey:u,getValue:s,filter:f,children:p=q0,disabled:c=!1,icon:v}){const[m,g]=S.useState(null),[x,h]=S.useState(""),[d,y]=S.useState(!1);S.useEffect(()=>{typeof l=="function"&&l(x)},[x]),S.useEffect(()=>{d||h(m||"")},[d,m]);const w=x===""?n:n==null?void 0:n.filter($=>f(x,$)),C="a1-z-100 a1-absolute a1-max-h-56 a1-max-w-full lg:a1-max-w-[none] a1-rounded-lg a1-border a1-border-gray-200 a1-bg-white a1-shadow-lg a1-mt-2 a1-overflow-x-hidden",k="a1-border-b a1-border-gray-200 a1-text-left a1-border-l-0 a1-border-r-0 a1-px-4 a1-py-2 a1-cursor-pointer a1-overflow-hidden",b="a1-bg-secondary",O="a1-bg-primary a1-text-white",_="a1-text-gray-900 a1-bg-white a1-rounded-lg focus:a1-border-primary",T="a1-ring-2 a1-ring-primary";let L={};i&&(L["--color-primary"]=i),o&&(L["--color-secondary"]=o);let R=null;return v&&(R=F("span",{className:"a1-p-3",children:v})),a==="loading"&&(R=F("span",{className:"a1-p-3",children:F(V0,{})})),F("div",{style:L,children:F(Qo,{disabled:c,name:t,value:r,onChange:$=>{g($),$&&h($)},children:({open:$})=>F(Pp,{children:$e("div",{className:"a1-relative",children:[$e("div",{className:`a1-flex a1-flex-row a1-items-center a1-gap-1 ${_} ${d?T:"a1-ring-2 a1-ring-gray-200"} ${c?"a1-opacity-50":""}`,children:[R,F(Qo.Input,{autoComplete:"off",className:"focus:a1-outline-none a1-w-full",onChange:z=>h(z.target.value),onFocus:()=>y(!0),onBlur:()=>setTimeout(()=>y(!1),200),placeholder:e})]}),F(Vd,{show:$||d&&x==="",className:"a1-relative a1-z-10",enter:"a1-transition a1-duration-100 a1-ease-out",enterFrom:"a1-transform a1-scale-95 a1-opacity-0",enterTo:"a1-transform a1-scale-100 a1-opacity-100",leave:"a1-transition a1-duration-75 a1-ease-out",leaveFrom:"a1-transform a1-scale-100 a1-opacity-100",leaveTo:"a1-transform a1-scale-95 a1-opacity-0",children:F(Qo.Options,{className:`${C}`,children:w==null?void 0:w.slice(0,25).map((z,U)=>F(Qo.Option,{value:s(z),as:S.Fragment,children:({active:j,selected:J})=>p(j,J,`${k} ${j?b:""} ${J?O:"a1-text-gray-900"} ${!j&&!J?"a1-bg-white":""}`,z)},`${u(z)}-${U}`))})})]})})})})}function mr(e){return mr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mr(e)}function te(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function ne(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function Ce(e){ne(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||mr(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console!="undefined"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function Vo(e,t){ne(2,arguments);var n=Ce(e),r=te(t);return isNaN(r)?new Date(NaN):(r&&n.setDate(n.getDate()+r),n)}function Yd(e,t){ne(2,arguments);var n=Ce(e),r=te(t);if(isNaN(r))return new Date(NaN);if(!r)return n;var i=n.getDate(),o=new Date(n.getTime());o.setMonth(n.getMonth()+r+1,0);var a=o.getDate();return i>=a?o:(n.setFullYear(o.getFullYear(),o.getMonth(),i),n)}function Y0(e,t){if(ne(2,arguments),!t||mr(t)!=="object")return new Date(NaN);var n=t.years?te(t.years):0,r=t.months?te(t.months):0,i=t.weeks?te(t.weeks):0,o=t.days?te(t.days):0,a=t.hours?te(t.hours):0,l=t.minutes?te(t.minutes):0,u=t.seconds?te(t.seconds):0,s=Ce(e),f=r||n?Yd(s,r+n*12):s,p=o||i?Vo(f,o+i*7):f,c=l+a*60,v=u+c*60,m=v*1e3,g=new Date(p.getTime()+m);return g}function K0(e,t){ne(2,arguments);var n=Ce(e).getTime(),r=te(t);return new Date(n+r)}var G0={};function mi(){return G0}function X0(e,t){var n,r,i,o,a,l,u,s;ne(1,arguments);var f=mi(),p=te((n=(r=(i=(o=t==null?void 0:t.weekStartsOn)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(l=a.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&i!==void 0?i:f.weekStartsOn)!==null&&r!==void 0?r:(u=f.locale)===null||u===void 0||(s=u.options)===null||s===void 0?void 0:s.weekStartsOn)!==null&&n!==void 0?n:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var c=Ce(e),v=c.getDay(),m=(v<p?7:0)+v-p;return c.setDate(c.getDate()-m),c.setHours(0,0,0,0),c}function Z0(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}function Kd(e){ne(1,arguments);var t=Ce(e);return t.setHours(0,0,0,0),t}function qo(e,t){ne(2,arguments);var n=Kd(e),r=Kd(t);return n.getTime()===r.getTime()}function J0(e){return ne(1,arguments),e instanceof Date||mr(e)==="object"&&Object.prototype.toString.call(e)==="[object Date]"}function ey(e){if(ne(1,arguments),!J0(e)&&typeof e!="number")return!1;var t=Ce(e);return!isNaN(Number(t))}function ty(e){ne(1,arguments);var t=Ce(e);return t.setDate(1),t.setHours(0,0,0,0),t}function ny(e,t){ne(2,arguments);var n=te(t);return K0(e,-n)}var ry=864e5;function iy(e){ne(1,arguments);var t=Ce(e),n=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var r=t.getTime(),i=n-r;return Math.floor(i/ry)+1}function Yo(e){ne(1,arguments);var t=1,n=Ce(e),r=n.getUTCDay(),i=(r<t?7:0)+r-t;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function Gd(e){ne(1,arguments);var t=Ce(e),n=t.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=Yo(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var a=Yo(o);return t.getTime()>=i.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function oy(e){ne(1,arguments);var t=Gd(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=Yo(n);return r}var ay=6048e5;function ly(e){ne(1,arguments);var t=Ce(e),n=Yo(t).getTime()-oy(t).getTime();return Math.round(n/ay)+1}function Ko(e,t){var n,r,i,o,a,l,u,s;ne(1,arguments);var f=mi(),p=te((n=(r=(i=(o=t==null?void 0:t.weekStartsOn)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(l=a.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&i!==void 0?i:f.weekStartsOn)!==null&&r!==void 0?r:(u=f.locale)===null||u===void 0||(s=u.options)===null||s===void 0?void 0:s.weekStartsOn)!==null&&n!==void 0?n:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var c=Ce(e),v=c.getUTCDay(),m=(v<p?7:0)+v-p;return c.setUTCDate(c.getUTCDate()-m),c.setUTCHours(0,0,0,0),c}function Xd(e,t){var n,r,i,o,a,l,u,s;ne(1,arguments);var f=Ce(e),p=f.getUTCFullYear(),c=mi(),v=te((n=(r=(i=(o=t==null?void 0:t.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(l=a.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&i!==void 0?i:c.firstWeekContainsDate)!==null&&r!==void 0?r:(u=c.locale)===null||u===void 0||(s=u.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(v>=1&&v<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var m=new Date(0);m.setUTCFullYear(p+1,0,v),m.setUTCHours(0,0,0,0);var g=Ko(m,t),x=new Date(0);x.setUTCFullYear(p,0,v),x.setUTCHours(0,0,0,0);var h=Ko(x,t);return f.getTime()>=g.getTime()?p+1:f.getTime()>=h.getTime()?p:p-1}function uy(e,t){var n,r,i,o,a,l,u,s;ne(1,arguments);var f=mi(),p=te((n=(r=(i=(o=t==null?void 0:t.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(l=a.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&i!==void 0?i:f.firstWeekContainsDate)!==null&&r!==void 0?r:(u=f.locale)===null||u===void 0||(s=u.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&n!==void 0?n:1),c=Xd(e,t),v=new Date(0);v.setUTCFullYear(c,0,p),v.setUTCHours(0,0,0,0);var m=Ko(v,t);return m}var sy=6048e5;function cy(e,t){ne(1,arguments);var n=Ce(e),r=Ko(n,t).getTime()-uy(n,t).getTime();return Math.round(r/sy)+1}function Z(e,t){for(var n=e<0?"-":"",r=Math.abs(e).toString();r.length<t;)r="0"+r;return n+r}var fy={y:function(t,n){var r=t.getUTCFullYear(),i=r>0?r:1-r;return Z(n==="yy"?i%100:i,n.length)},M:function(t,n){var r=t.getUTCMonth();return n==="M"?String(r+1):Z(r+1,2)},d:function(t,n){return Z(t.getUTCDate(),n.length)},a:function(t,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.toUpperCase();case"aaa":return r;case"aaaaa":return r[0];case"aaaa":default:return r==="am"?"a.m.":"p.m."}},h:function(t,n){return Z(t.getUTCHours()%12||12,n.length)},H:function(t,n){return Z(t.getUTCHours(),n.length)},m:function(t,n){return Z(t.getUTCMinutes(),n.length)},s:function(t,n){return Z(t.getUTCSeconds(),n.length)},S:function(t,n){var r=n.length,i=t.getUTCMilliseconds(),o=Math.floor(i*Math.pow(10,r-3));return Z(o,n.length)}};const sn=fy;var yr={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},dy={G:function(t,n,r){var i=t.getUTCFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return r.era(i,{width:"abbreviated"});case"GGGGG":return r.era(i,{width:"narrow"});case"GGGG":default:return r.era(i,{width:"wide"})}},y:function(t,n,r){if(n==="yo"){var i=t.getUTCFullYear(),o=i>0?i:1-i;return r.ordinalNumber(o,{unit:"year"})}return sn.y(t,n)},Y:function(t,n,r,i){var o=Xd(t,i),a=o>0?o:1-o;if(n==="YY"){var l=a%100;return Z(l,2)}return n==="Yo"?r.ordinalNumber(a,{unit:"year"}):Z(a,n.length)},R:function(t,n){var r=Gd(t);return Z(r,n.length)},u:function(t,n){var r=t.getUTCFullYear();return Z(r,n.length)},Q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"Q":return String(i);case"QQ":return Z(i,2);case"Qo":return r.ordinalNumber(i,{unit:"quarter"});case"QQQ":return r.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return r.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(i,{width:"wide",context:"formatting"})}},q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"q":return String(i);case"qq":return Z(i,2);case"qo":return r.ordinalNumber(i,{unit:"quarter"});case"qqq":return r.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return r.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(i,{width:"wide",context:"standalone"})}},M:function(t,n,r){var i=t.getUTCMonth();switch(n){case"M":case"MM":return sn.M(t,n);case"Mo":return r.ordinalNumber(i+1,{unit:"month"});case"MMM":return r.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return r.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(i,{width:"wide",context:"formatting"})}},L:function(t,n,r){var i=t.getUTCMonth();switch(n){case"L":return String(i+1);case"LL":return Z(i+1,2);case"Lo":return r.ordinalNumber(i+1,{unit:"month"});case"LLL":return r.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return r.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(i,{width:"wide",context:"standalone"})}},w:function(t,n,r,i){var o=cy(t,i);return n==="wo"?r.ordinalNumber(o,{unit:"week"}):Z(o,n.length)},I:function(t,n,r){var i=ly(t);return n==="Io"?r.ordinalNumber(i,{unit:"week"}):Z(i,n.length)},d:function(t,n,r){return n==="do"?r.ordinalNumber(t.getUTCDate(),{unit:"date"}):sn.d(t,n)},D:function(t,n,r){var i=iy(t);return n==="Do"?r.ordinalNumber(i,{unit:"dayOfYear"}):Z(i,n.length)},E:function(t,n,r){var i=t.getUTCDay();switch(n){case"E":case"EE":case"EEE":return r.day(i,{width:"abbreviated",context:"formatting"});case"EEEEE":return r.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(i,{width:"short",context:"formatting"});case"EEEE":default:return r.day(i,{width:"wide",context:"formatting"})}},e:function(t,n,r,i){var o=t.getUTCDay(),a=(o-i.weekStartsOn+8)%7||7;switch(n){case"e":return String(a);case"ee":return Z(a,2);case"eo":return r.ordinalNumber(a,{unit:"day"});case"eee":return r.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return r.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(o,{width:"short",context:"formatting"});case"eeee":default:return r.day(o,{width:"wide",context:"formatting"})}},c:function(t,n,r,i){var o=t.getUTCDay(),a=(o-i.weekStartsOn+8)%7||7;switch(n){case"c":return String(a);case"cc":return Z(a,n.length);case"co":return r.ordinalNumber(a,{unit:"day"});case"ccc":return r.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return r.day(o,{width:"narrow",context:"standalone"});case"cccccc":return r.day(o,{width:"short",context:"standalone"});case"cccc":default:return r.day(o,{width:"wide",context:"standalone"})}},i:function(t,n,r){var i=t.getUTCDay(),o=i===0?7:i;switch(n){case"i":return String(o);case"ii":return Z(o,n.length);case"io":return r.ordinalNumber(o,{unit:"day"});case"iii":return r.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return r.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return r.day(i,{width:"short",context:"formatting"});case"iiii":default:return r.day(i,{width:"wide",context:"formatting"})}},a:function(t,n,r){var i=t.getUTCHours(),o=i/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(t,n,r){var i=t.getUTCHours(),o;switch(i===12?o=yr.noon:i===0?o=yr.midnight:o=i/12>=1?"pm":"am",n){case"b":case"bb":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(t,n,r){var i=t.getUTCHours(),o;switch(i>=17?o=yr.evening:i>=12?o=yr.afternoon:i>=4?o=yr.morning:o=yr.night,n){case"B":case"BB":case"BBB":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(t,n,r){if(n==="ho"){var i=t.getUTCHours()%12;return i===0&&(i=12),r.ordinalNumber(i,{unit:"hour"})}return sn.h(t,n)},H:function(t,n,r){return n==="Ho"?r.ordinalNumber(t.getUTCHours(),{unit:"hour"}):sn.H(t,n)},K:function(t,n,r){var i=t.getUTCHours()%12;return n==="Ko"?r.ordinalNumber(i,{unit:"hour"}):Z(i,n.length)},k:function(t,n,r){var i=t.getUTCHours();return i===0&&(i=24),n==="ko"?r.ordinalNumber(i,{unit:"hour"}):Z(i,n.length)},m:function(t,n,r){return n==="mo"?r.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):sn.m(t,n)},s:function(t,n,r){return n==="so"?r.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):sn.s(t,n)},S:function(t,n){return sn.S(t,n)},X:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();if(a===0)return"Z";switch(n){case"X":return Jd(a);case"XXXX":case"XX":return Mn(a);case"XXXXX":case"XXX":default:return Mn(a,":")}},x:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"x":return Jd(a);case"xxxx":case"xx":return Mn(a);case"xxxxx":case"xxx":default:return Mn(a,":")}},O:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+Zd(a,":");case"OOOO":default:return"GMT"+Mn(a,":")}},z:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+Zd(a,":");case"zzzz":default:return"GMT"+Mn(a,":")}},t:function(t,n,r,i){var o=i._originalDate||t,a=Math.floor(o.getTime()/1e3);return Z(a,n.length)},T:function(t,n,r,i){var o=i._originalDate||t,a=o.getTime();return Z(a,n.length)}};function Zd(e,t){var n=e>0?"-":"+",r=Math.abs(e),i=Math.floor(r/60),o=r%60;if(o===0)return n+String(i);var a=t||"";return n+String(i)+a+Z(o,2)}function Jd(e,t){if(e%60===0){var n=e>0?"-":"+";return n+Z(Math.abs(e)/60,2)}return Mn(e,t)}function Mn(e,t){var n=t||"",r=e>0?"-":"+",i=Math.abs(e),o=Z(Math.floor(i/60),2),a=Z(i%60,2);return r+o+n+a}const hy=dy;var eh=function(t,n){switch(t){case"P":return n.date({width:"short"});case"PP":return n.date({width:"medium"});case"PPP":return n.date({width:"long"});case"PPPP":default:return n.date({width:"full"})}},th=function(t,n){switch(t){case"p":return n.time({width:"short"});case"pp":return n.time({width:"medium"});case"ppp":return n.time({width:"long"});case"pppp":default:return n.time({width:"full"})}},py=function(t,n){var r=t.match(/(P+)(p+)?/)||[],i=r[1],o=r[2];if(!o)return eh(t,n);var a;switch(i){case"P":a=n.dateTime({width:"short"});break;case"PP":a=n.dateTime({width:"medium"});break;case"PPP":a=n.dateTime({width:"long"});break;case"PPPP":default:a=n.dateTime({width:"full"});break}return a.replace("{{date}}",eh(i,n)).replace("{{time}}",th(o,n))},vy={p:th,P:py};const my=vy;var yy=["D","DD"],gy=["YY","YYYY"];function wy(e){return yy.indexOf(e)!==-1}function Sy(e){return gy.indexOf(e)!==-1}function nh(e,t,n){if(e==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var xy={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},ky=function(t,n,r){var i,o=xy[t];return typeof o=="string"?i=o:n===1?i=o.one:i=o.other.replace("{{count}}",n.toString()),r!=null&&r.addSuffix?r.comparison&&r.comparison>0?"in "+i:i+" ago":i};const Cy=ky;function Hu(e){return function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.width?String(t.width):e.defaultWidth,r=e.formats[n]||e.formats[e.defaultWidth];return r}}var by={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Ey={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Oy={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Py={date:Hu({formats:by,defaultWidth:"full"}),time:Hu({formats:Ey,defaultWidth:"full"}),dateTime:Hu({formats:Oy,defaultWidth:"full"})};const Ty=Py;var _y={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Ry=function(t,n,r,i){return _y[t]};const Dy=Ry;function yi(e){return function(t,n){var r=n!=null&&n.context?String(n.context):"standalone",i;if(r==="formatting"&&e.formattingValues){var o=e.defaultFormattingWidth||e.defaultWidth,a=n!=null&&n.width?String(n.width):o;i=e.formattingValues[a]||e.formattingValues[o]}else{var l=e.defaultWidth,u=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[u]||e.values[l]}var s=e.argumentCallback?e.argumentCallback(t):t;return i[s]}}var Fy={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Ny={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},My={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Ly={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Iy={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},$y={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},Ay=function(t,n){var r=Number(t),i=r%100;if(i>20||i<10)switch(i%10){case 1:return r+"st";case 2:return r+"nd";case 3:return r+"rd"}return r+"th"},Uy={ordinalNumber:Ay,era:yi({values:Fy,defaultWidth:"wide"}),quarter:yi({values:Ny,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:yi({values:My,defaultWidth:"wide"}),day:yi({values:Ly,defaultWidth:"wide"}),dayPeriod:yi({values:Iy,defaultWidth:"wide",formattingValues:$y,defaultFormattingWidth:"wide"})};const zy=Uy;function gi(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;var a=o[0],l=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],u=Array.isArray(l)?Qy(l,function(p){return p.test(a)}):jy(l,function(p){return p.test(a)}),s;s=e.valueCallback?e.valueCallback(u):u,s=n.valueCallback?n.valueCallback(s):s;var f=t.slice(a.length);return{value:s,rest:f}}}function jy(e,t){for(var n in e)if(e.hasOwnProperty(n)&&t(e[n]))return n}function Qy(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return n}function Wy(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.match(e.matchPattern);if(!r)return null;var i=r[0],o=t.match(e.parsePattern);if(!o)return null;var a=e.valueCallback?e.valueCallback(o[0]):o[0];a=n.valueCallback?n.valueCallback(a):a;var l=t.slice(i.length);return{value:a,rest:l}}}var Hy=/^(\d+)(th|st|nd|rd)?/i,By=/\d+/i,Vy={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},qy={any:[/^b/i,/^(a|c)/i]},Yy={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Ky={any:[/1/i,/2/i,/3/i,/4/i]},Gy={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Xy={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Zy={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Jy={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},eg={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},tg={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},ng={ordinalNumber:Wy({matchPattern:Hy,parsePattern:By,valueCallback:function(t){return parseInt(t,10)}}),era:gi({matchPatterns:Vy,defaultMatchWidth:"wide",parsePatterns:qy,defaultParseWidth:"any"}),quarter:gi({matchPatterns:Yy,defaultMatchWidth:"wide",parsePatterns:Ky,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:gi({matchPatterns:Gy,defaultMatchWidth:"wide",parsePatterns:Xy,defaultParseWidth:"any"}),day:gi({matchPatterns:Zy,defaultMatchWidth:"wide",parsePatterns:Jy,defaultParseWidth:"any"}),dayPeriod:gi({matchPatterns:eg,defaultMatchWidth:"any",parsePatterns:tg,defaultParseWidth:"any"})},rg={code:"en-US",formatDistance:Cy,formatLong:Ty,formatRelative:Dy,localize:zy,match:ng,options:{weekStartsOn:0,firstWeekContainsDate:1}};const ig=rg;var og=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,ag=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,lg=/^'([^]*?)'?$/,ug=/''/g,sg=/[a-zA-Z]/;function cg(e,t,n){var r,i,o,a,l,u,s,f,p,c,v,m,g,x,h,d,y,w;ne(2,arguments);var C=String(t),k=mi(),b=(r=(i=n==null?void 0:n.locale)!==null&&i!==void 0?i:k.locale)!==null&&r!==void 0?r:ig,O=te((o=(a=(l=(u=n==null?void 0:n.firstWeekContainsDate)!==null&&u!==void 0?u:n==null||(s=n.locale)===null||s===void 0||(f=s.options)===null||f===void 0?void 0:f.firstWeekContainsDate)!==null&&l!==void 0?l:k.firstWeekContainsDate)!==null&&a!==void 0?a:(p=k.locale)===null||p===void 0||(c=p.options)===null||c===void 0?void 0:c.firstWeekContainsDate)!==null&&o!==void 0?o:1);if(!(O>=1&&O<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var _=te((v=(m=(g=(x=n==null?void 0:n.weekStartsOn)!==null&&x!==void 0?x:n==null||(h=n.locale)===null||h===void 0||(d=h.options)===null||d===void 0?void 0:d.weekStartsOn)!==null&&g!==void 0?g:k.weekStartsOn)!==null&&m!==void 0?m:(y=k.locale)===null||y===void 0||(w=y.options)===null||w===void 0?void 0:w.weekStartsOn)!==null&&v!==void 0?v:0);if(!(_>=0&&_<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!b.localize)throw new RangeError("locale must contain localize property");if(!b.formatLong)throw new RangeError("locale must contain formatLong property");var T=Ce(e);if(!ey(T))throw new RangeError("Invalid time value");var L=Z0(T),R=ny(T,L),$={firstWeekContainsDate:O,weekStartsOn:_,locale:b,_originalDate:T},z=C.match(ag).map(function(U){var j=U[0];if(j==="p"||j==="P"){var J=my[j];return J(U,b.formatLong)}return U}).join("").match(og).map(function(U){if(U==="''")return"'";var j=U[0];if(j==="'")return fg(U);var J=hy[j];if(J)return!(n!=null&&n.useAdditionalWeekYearTokens)&&Sy(U)&&nh(U,t,String(e)),!(n!=null&&n.useAdditionalDayOfYearTokens)&&wy(U)&&nh(U,t,String(e)),J(R,U,b.localize,$);if(j.match(sg))throw new RangeError("Format string contains an unescaped latin alphabet character `"+j+"`");return U}).join("");return z}function fg(e){var t=e.match(lg);return t?t[1].replace(ug,"'"):e}function dg(e,t){ne(2,arguments);var n=Ce(e),r=Ce(t);return n.getTime()<r.getTime()}function Bu(e,t){return Bu=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Bu(e,t)}function hg(e,t){ne(2,arguments);var n=te(t);return Vo(e,-n)}function pg(e,t){ne(2,arguments);var n=te(t);return Yd(e,-n)}function vg(e,t){if(ne(2,arguments),!t||mr(t)!=="object")return new Date(NaN);var n=t.years?te(t.years):0,r=t.months?te(t.months):0,i=t.weeks?te(t.weeks):0,o=t.days?te(t.days):0,a=t.hours?te(t.hours):0,l=t.minutes?te(t.minutes):0,u=t.seconds?te(t.seconds):0,s=pg(e,r+n*12),f=hg(s,o+i*7),p=l+a*60,c=u+p*60,v=c*1e3,m=new Date(f.getTime()-v);return m}var Vu=function(e,t){return Vu=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},Vu(e,t)};function cn(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Vu(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function mg(e,t,n,r){function i(o){return o instanceof n?o:new n(function(a){a(o)})}return new(n||(n=Promise))(function(o,a){function l(f){try{s(r.next(f))}catch(p){a(p)}}function u(f){try{s(r.throw(f))}catch(p){a(p)}}function s(f){f.done?o(f.value):i(f.value).then(l,u)}s((r=r.apply(e,t||[])).next())})}function rh(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,i,o,a;return a={next:l(0),throw:l(1),return:l(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function l(s){return function(f){return u([s,f])}}function u(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(n=0)),n;)try{if(r=1,i&&(o=s[0]&2?i.return:s[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,s[1])).done)return o;switch(i=0,o&&(s=[s[0]&2,o.value]),s[0]){case 0:case 1:o=s;break;case 4:return n.label++,{value:s[1],done:!1};case 5:n.label++,i=s[1],s=[0];continue;case 7:s=n.ops.pop(),n.trys.pop();continue;default:if(o=n.trys,!(o=o.length>0&&o[o.length-1])&&(s[0]===6||s[0]===2)){n=0;continue}if(s[0]===3&&(!o||s[1]>o[0]&&s[1]<o[3])){n.label=s[1];break}if(s[0]===6&&n.label<o[1]){n.label=o[1],o=s;break}if(o&&n.label<o[2]){n.label=o[2],n.ops.push(s);break}o[2]&&n.ops.pop(),n.trys.pop();continue}s=t.call(e,n)}catch(f){s=[6,f],i=0}finally{r=o=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function Ln(e){var t=typeof Symbol=="function"&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function fn(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,o=[],a;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)o.push(i.value)}catch(l){a={error:l}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o}function In(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}function gr(e){return this instanceof gr?(this.v=e,this):new gr(e)}function yg(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(e,t||[]),i,o=[];return i={},a("next"),a("throw"),a("return"),i[Symbol.asyncIterator]=function(){return this},i;function a(c){r[c]&&(i[c]=function(v){return new Promise(function(m,g){o.push([c,v,m,g])>1||l(c,v)})})}function l(c,v){try{u(r[c](v))}catch(m){p(o[0][3],m)}}function u(c){c.value instanceof gr?Promise.resolve(c.value.v).then(s,f):p(o[0][2],c)}function s(c){l("next",c)}function f(c){l("throw",c)}function p(c,v){c(v),o.shift(),o.length&&l(o[0][0],o[0][1])}}function gg(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof Ln=="function"?Ln(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(o){n[o]=e[o]&&function(a){return new Promise(function(l,u){a=e[o](a),i(l,u,a.done,a.value)})}}function i(o,a,l,u){Promise.resolve(u).then(function(s){o({value:s,done:l})},a)}}function re(e){return typeof e=="function"}function ih(e){var t=function(r){Error.call(r),r.stack=new Error().stack},n=e(t);return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}var qu=ih(function(e){return function(n){e(this),this.message=n?n.length+` errors occurred during unsubscription:
|
|
43
|
+
`));let c=s.props,v=typeof(c==null?void 0:c.className)=="function"?(...g)=>Fu(c==null?void 0:c.className(...g),l.className):Fu(c==null?void 0:c.className,l.className),m=v?{className:v}:{};return S.cloneElement(s,Object.assign({},Md(s.props,Nu(Mu(l,["ref"]))),f,u,Ym(s.ref,u.ref),m))}return S.createElement(i,Object.assign({},Mu(l,["ref"]),i!==S.Fragment&&u,i!==S.Fragment&&f),s)}function Ym(...e){return{ref:e.every(t=>t==null)?void 0:t=>{for(let n of e)n!=null&&(typeof n=="function"?n(t):n.current=t)}}}function Md(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},n={};for(let r of e)for(let i in r)i.startsWith("on")&&typeof r[i]=="function"?(n[i]!=null||(n[i]=[]),n[i].push(r[i])):t[i]=r[i];if(t.disabled||t["aria-disabled"])return Object.assign(t,Object.fromEntries(Object.keys(n).map(r=>[r,void 0])));for(let r in n)Object.assign(t,{[r](i,...o){let a=n[r];for(let l of a){if((i instanceof Event||(i==null?void 0:i.nativeEvent)instanceof Event)&&i.defaultPrevented)return;l(i,...o)}}});return t}function Et(e){var t;return Object.assign(S.forwardRef(e),{displayName:(t=e.displayName)!=null?t:e.name})}function Nu(e){let t=Object.assign({},e);for(let n in t)t[n]===void 0&&delete t[n];return t}function Mu(e,t=[]){let n=Object.assign({},e);for(let r of t)r in n&&delete n[r];return n}function Km(e){let t=e.parentElement,n=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(n=t),t=t.parentElement;let r=(t==null?void 0:t.getAttribute("disabled"))==="";return r&&Gm(n)?!1:r}function Gm(e){if(!e)return!1;let t=e.previousElementSibling;for(;t!==null;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}function Ld(e={},t=null,n=[]){for(let[r,i]of Object.entries(e))$d(n,Id(t,r),i);return n}function Id(e,t){return e?e+"["+t+"]":t}function $d(e,t,n){if(Array.isArray(n))for(let[r,i]of n.entries())$d(e,Id(t,r.toString()),i);else n instanceof Date?e.push([t,n.toISOString()]):typeof n=="boolean"?e.push([t,n?"1":"0"]):typeof n=="string"?e.push([t,n]):typeof n=="number"?e.push([t,`${n}`]):n==null?e.push([t,""]):Ld(n,t,e)}let Xm="div";var Ad=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(Ad||{});function Zm(e,t){let o=e,{features:n=1}=o,r=it(o,["features"]),i={ref:t,"aria-hidden":(n&2)===2?!0:void 0,style:G({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"},(n&4)===4&&(n&2)!==2&&{display:"none"})};return zt({ourProps:i,theirProps:r,slot:{},defaultTag:Xm,name:"Hidden"})}let Jm=Et(Zm),Lu=S.createContext(null);Lu.displayName="OpenClosedContext";var et=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(et||{});function Iu(){return S.useContext(Lu)}function Ud({value:e,children:t}){return Y.createElement(Lu.Provider,{value:e},t)}var je=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(je||{});function e0(e,t,n){let[r,i]=S.useState(n),o=e!==void 0,a=S.useRef(o),l=S.useRef(!1),u=S.useRef(!1);return o&&!a.current&&!l.current?(l.current=!0,a.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&&a.current&&!u.current&&(u.current=!0,a.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.")),[o?e:r,V(s=>(o||i(s),t==null?void 0:t(s)))]}function zd(e,t){let n=S.useRef([]),r=V(e);S.useEffect(()=>{let i=[...n.current];for(let[o,a]of t.entries())if(n.current[o]!==a){let l=r(t,i);return n.current=t,l}},[r,...t])}function jd(e){return[e.screenX,e.screenY]}function t0(){let e=S.useRef([-1,-1]);return{wasMoved(t){let n=jd(t);return e.current[0]===n[0]&&e.current[1]===n[1]?!1:(e.current=n,!0)},update(t){e.current=jd(t)}}}function n0(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function r0(){return/Android/gi.test(window.navigator.userAgent)}function i0(){return n0()||r0()}var o0=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(o0||{}),a0=(e=>(e[e.Single=0]="Single",e[e.Multi=1]="Multi",e))(a0||{}),l0=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(l0||{}),u0=(e=>(e[e.OpenCombobox=0]="OpenCombobox",e[e.CloseCombobox=1]="CloseCombobox",e[e.GoToOption=2]="GoToOption",e[e.RegisterOption=3]="RegisterOption",e[e.UnregisterOption=4]="UnregisterOption",e[e.RegisterLabel=5]="RegisterLabel",e))(u0||{});function $u(e,t=n=>n){let n=e.activeOptionIndex!==null?e.options[e.activeOptionIndex]:null,r=jm(t(e.options.slice()),o=>o.dataRef.current.domRef.current),i=n?r.indexOf(n):null;return i===-1&&(i=null),{options:r,activeOptionIndex:i}}let s0={[1](e){var t;return(t=e.dataRef.current)!=null&&t.disabled||e.comboboxState===1?e:ge(G({},e),{activeOptionIndex:null,comboboxState:1})},[0](e){var t;if((t=e.dataRef.current)!=null&&t.disabled||e.comboboxState===0)return e;let n=e.activeOptionIndex;if(e.dataRef.current){let{isSelected:r}=e.dataRef.current,i=e.options.findIndex(o=>r(o.dataRef.current.value));i!==-1&&(n=i)}return ge(G({},e),{comboboxState:0,activeOptionIndex:n})},[2](e,t){var n,r,i,o;if((n=e.dataRef.current)!=null&&n.disabled||(r=e.dataRef.current)!=null&&r.optionsRef.current&&!((i=e.dataRef.current)!=null&&i.optionsPropsRef.current.static)&&e.comboboxState===1)return e;let a=$u(e);if(a.activeOptionIndex===null){let u=a.options.findIndex(s=>!s.dataRef.current.disabled);u!==-1&&(a.activeOptionIndex=u)}let l=qm(t,{resolveItems:()=>a.options,resolveActiveIndex:()=>a.activeOptionIndex,resolveId:u=>u.id,resolveDisabled:u=>u.dataRef.current.disabled});return ge(G(G({},e),a),{activeOptionIndex:l,activationTrigger:(o=t.trigger)!=null?o:1})},[3]:(e,t)=>{var n,r;let i={id:t.id,dataRef:t.dataRef},o=$u(e,l=>[...l,i]);e.activeOptionIndex===null&&(n=e.dataRef.current)!=null&&n.isSelected(t.dataRef.current.value)&&(o.activeOptionIndex=o.options.indexOf(i));let a=ge(G(G({},e),o),{activationTrigger:1});return(r=e.dataRef.current)!=null&&r.__demoMode&&e.dataRef.current.value===void 0&&(a.activeOptionIndex=0),a},[4]:(e,t)=>{let n=$u(e,r=>{let i=r.findIndex(o=>o.id===t.id);return i!==-1&&r.splice(i,1),r});return ge(G(G({},e),n),{activationTrigger:1})},[5]:(e,t)=>ge(G({},e),{labelId:t.id})},Au=S.createContext(null);Au.displayName="ComboboxActionsContext";function vi(e){let t=S.useContext(Au);if(t===null){let n=new Error(`<${e} /> is missing a parent <Combobox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,vi),n}return t}let Uu=S.createContext(null);Uu.displayName="ComboboxDataContext";function vr(e){let t=S.useContext(Uu);if(t===null){let n=new Error(`<${e} /> is missing a parent <Combobox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,vr),n}return t}function c0(e,t){return Pe(t.type,s0,e,t)}let f0=S.Fragment;function d0(e,t){let nt=e,{value:n,defaultValue:r,onChange:i,form:o,name:a,by:l=(I,W)=>I===W,disabled:u=!1,__demoMode:s=!1,nullable:f=!1,multiple:p=!1}=nt,c=it(nt,["value","defaultValue","onChange","form","name","by","disabled","__demoMode","nullable","multiple"]),[v=p?[]:void 0,m]=e0(n,i,r),[g,x]=S.useReducer(c0,{dataRef:S.createRef(),comboboxState:s?0:1,options:[],activeOptionIndex:null,activationTrigger:1,labelId:null}),h=S.useRef(!1),d=S.useRef({static:!1,hold:!1}),y=S.useRef(null),w=S.useRef(null),C=S.useRef(null),k=S.useRef(null),b=V(typeof l=="string"?(I,W)=>{let pe=l;return(I==null?void 0:I[pe])===(W==null?void 0:W[pe])}:l),O=S.useCallback(I=>Pe(_.mode,{[1]:()=>v.some(W=>b(W,I)),[0]:()=>b(v,I)}),[v]),_=S.useMemo(()=>ge(G({},g),{optionsPropsRef:d,labelRef:y,inputRef:w,buttonRef:C,optionsRef:k,value:v,defaultValue:r,disabled:u,mode:p?1:0,get activeOptionIndex(){if(h.current&&g.activeOptionIndex===null&&g.options.length>0){let I=g.options.findIndex(W=>!W.dataRef.current.disabled);if(I!==-1)return I}return g.activeOptionIndex},compare:b,isSelected:O,nullable:f,__demoMode:s}),[v,r,u,p,f,s,g]),T=S.useRef(_.activeOptionIndex!==null?_.options[_.activeOptionIndex]:null);S.useEffect(()=>{let I=_.activeOptionIndex!==null?_.options[_.activeOptionIndex]:null;T.current!==I&&(T.current=I)}),Me(()=>{g.dataRef.current=_},[_]),Qm([_.buttonRef,_.inputRef,_.optionsRef],()=>M.closeCombobox(),_.comboboxState===0);let L=S.useMemo(()=>({open:_.comboboxState===0,disabled:u,activeIndex:_.activeOptionIndex,activeOption:_.activeOptionIndex===null?null:_.options[_.activeOptionIndex].dataRef.current.value,value:v}),[_,u,v]),R=V(I=>{let W=_.options.find(pe=>pe.id===I);W&&N(W.dataRef.current.value)}),$=V(()=>{if(_.activeOptionIndex!==null){let{dataRef:I,id:W}=_.options[_.activeOptionIndex];N(I.current.value),M.goToOption(Te.Specific,W)}}),z=V(()=>{x({type:0}),h.current=!0}),U=V(()=>{x({type:1}),h.current=!1}),j=V((I,W,pe)=>(h.current=!1,I===Te.Specific?x({type:2,focus:Te.Specific,id:W,trigger:pe}):x({type:2,focus:I,trigger:pe}))),J=V((I,W)=>(x({type:3,id:I,dataRef:W}),()=>{var pe;((pe=T.current)==null?void 0:pe.id)===I&&(h.current=!0),x({type:4,id:I})})),P=V(I=>(x({type:5,id:I}),()=>x({type:5,id:null}))),N=V(I=>Pe(_.mode,{[0](){return m==null?void 0:m(I)},[1](){let W=_.value.slice(),pe=W.findIndex(pn=>b(pn,I));return pe===-1?W.push(I):W.splice(pe,1),m==null?void 0:m(W)}})),M=S.useMemo(()=>({onChange:N,registerOption:J,registerLabel:P,goToOption:j,closeCombobox:U,openCombobox:z,selectActiveOption:$,selectOption:R}),[]),q=t===null?{}:{ref:t},Q=S.useRef(null),hn=hi();return S.useEffect(()=>{Q.current&&r!==void 0&&hn.addEventListener(Q.current,"reset",()=>{N(r)})},[Q,N]),Y.createElement(Au.Provider,{value:M},Y.createElement(Uu.Provider,{value:_},Y.createElement(Ud,{value:Pe(_.comboboxState,{[0]:et.Open,[1]:et.Closed})},a!=null&&v!=null&&Ld({[a]:v}).map(([I,W],pe)=>Y.createElement(Jm,G({features:Ad.Hidden,ref:pe===0?pn=>{var bi;Q.current=(bi=pn==null?void 0:pn.closest("form"))!=null?bi:null}:void 0},Nu({key:I,as:"input",type:"hidden",hidden:!0,readOnly:!0,form:o,name:I,value:W})))),zt({ourProps:q,theirProps:c,slot:L,defaultTag:f0,name:"Combobox"}))))}let h0="input";function p0(e,t){var n,r,i,o;let a=pi(),L=e,{id:l=`headlessui-combobox-input-${a}`,onChange:u,displayValue:s,type:f="text"}=L,p=it(L,["id","onChange","displayValue","type"]),c=vr("Combobox.Input"),v=vi("Combobox.Input"),m=Fn(c.inputRef,t),g=S.useRef(!1),x=hi(),h=function(){var R;return typeof s=="function"&&c.value!==void 0?(R=s(c.value))!=null?R:"":typeof c.value=="string"?c.value:""}();zd(([R,$],[z,U])=>{g.current||c.inputRef.current&&(U===0&&$===1||R!==z)&&(c.inputRef.current.value=R)},[h,c.comboboxState]),zd(([R],[$])=>{if(R===0&&$===1){let z=c.inputRef.current;if(!z)return;let U=z.value,{selectionStart:j,selectionEnd:J,selectionDirection:P}=z;z.value="",z.value=U,P!==null?z.setSelectionRange(j,J,P):z.setSelectionRange(j,J)}},[c.comboboxState]);let d=S.useRef(!1),y=V(()=>{d.current=!0}),w=V(()=>{setTimeout(()=>{d.current=!1})}),C=V(R=>{switch(g.current=!0,R.key){case je.Backspace:case je.Delete:if(c.mode!==0||!c.nullable)return;let $=R.currentTarget;x.requestAnimationFrame(()=>{$.value===""&&(v.onChange(null),c.optionsRef.current&&(c.optionsRef.current.scrollTop=0),v.goToOption(Te.Nothing))});break;case je.Enter:if(g.current=!1,c.comboboxState!==0||d.current)return;if(R.preventDefault(),R.stopPropagation(),c.activeOptionIndex===null){v.closeCombobox();return}v.selectActiveOption(),c.mode===0&&v.closeCombobox();break;case je.ArrowDown:return g.current=!1,R.preventDefault(),R.stopPropagation(),Pe(c.comboboxState,{[0]:()=>{v.goToOption(Te.Next)},[1]:()=>{v.openCombobox()}});case je.ArrowUp:return g.current=!1,R.preventDefault(),R.stopPropagation(),Pe(c.comboboxState,{[0]:()=>{v.goToOption(Te.Previous)},[1]:()=>{v.openCombobox(),x.nextFrame(()=>{c.value||v.goToOption(Te.Last)})}});case je.Home:if(R.shiftKey)break;return g.current=!1,R.preventDefault(),R.stopPropagation(),v.goToOption(Te.First);case je.PageUp:return g.current=!1,R.preventDefault(),R.stopPropagation(),v.goToOption(Te.First);case je.End:if(R.shiftKey)break;return g.current=!1,R.preventDefault(),R.stopPropagation(),v.goToOption(Te.Last);case je.PageDown:return g.current=!1,R.preventDefault(),R.stopPropagation(),v.goToOption(Te.Last);case je.Escape:return g.current=!1,c.comboboxState!==0?void 0:(R.preventDefault(),c.optionsRef.current&&!c.optionsPropsRef.current.static&&R.stopPropagation(),v.closeCombobox());case je.Tab:if(g.current=!1,c.comboboxState!==0)return;c.mode===0&&v.selectActiveOption(),v.closeCombobox();break}}),k=V(R=>{v.openCombobox(),u==null||u(R)}),b=V(()=>{g.current=!1}),O=_u(()=>{if(c.labelId)return[c.labelId].join(" ")},[c.labelId]),_=S.useMemo(()=>({open:c.comboboxState===0,disabled:c.disabled}),[c]),T={ref:m,id:l,role:"combobox",type:f,"aria-controls":(n=c.optionsRef.current)==null?void 0:n.id,"aria-expanded":c.disabled?void 0:c.comboboxState===0,"aria-activedescendant":c.activeOptionIndex===null||(r=c.options[c.activeOptionIndex])==null?void 0:r.id,"aria-labelledby":O,"aria-autocomplete":"list",defaultValue:(o=(i=e.defaultValue)!=null?i:c.defaultValue!==void 0?s==null?void 0:s(c.defaultValue):null)!=null?o:c.defaultValue,disabled:c.disabled,onCompositionStart:y,onCompositionEnd:w,onKeyDown:C,onChange:k,onBlur:b};return zt({ourProps:T,theirProps:p,slot:_,defaultTag:h0,name:"Combobox.Input"})}let v0="button";function m0(e,t){var n;let r=vr("Combobox.Button"),i=vi("Combobox.Button"),o=Fn(r.buttonRef,t),a=pi(),g=e,{id:l=`headlessui-combobox-button-${a}`}=g,u=it(g,["id"]),s=hi(),f=V(x=>{switch(x.key){case je.ArrowDown:return x.preventDefault(),x.stopPropagation(),r.comboboxState===1&&i.openCombobox(),s.nextFrame(()=>{var h;return(h=r.inputRef.current)==null?void 0:h.focus({preventScroll:!0})});case je.ArrowUp:return x.preventDefault(),x.stopPropagation(),r.comboboxState===1&&(i.openCombobox(),s.nextFrame(()=>{r.value||i.goToOption(Te.Last)})),s.nextFrame(()=>{var h;return(h=r.inputRef.current)==null?void 0:h.focus({preventScroll:!0})});case je.Escape:return r.comboboxState!==0?void 0:(x.preventDefault(),r.optionsRef.current&&!r.optionsPropsRef.current.static&&x.stopPropagation(),i.closeCombobox(),s.nextFrame(()=>{var h;return(h=r.inputRef.current)==null?void 0:h.focus({preventScroll:!0})}));default:return}}),p=V(x=>{if(Km(x.currentTarget))return x.preventDefault();r.comboboxState===0?i.closeCombobox():(x.preventDefault(),i.openCombobox()),s.nextFrame(()=>{var h;return(h=r.inputRef.current)==null?void 0:h.focus({preventScroll:!0})})}),c=_u(()=>{if(r.labelId)return[r.labelId,l].join(" ")},[r.labelId,l]),v=S.useMemo(()=>({open:r.comboboxState===0,disabled:r.disabled,value:r.value}),[r]),m={ref:o,id:l,type:Wm(e,r.buttonRef),tabIndex:-1,"aria-haspopup":"listbox","aria-controls":(n=r.optionsRef.current)==null?void 0:n.id,"aria-expanded":r.disabled?void 0:r.comboboxState===0,"aria-labelledby":c,disabled:r.disabled,onClick:p,onKeyDown:f};return zt({ourProps:m,theirProps:u,slot:v,defaultTag:v0,name:"Combobox.Button"})}let y0="label";function g0(e,t){let n=pi(),f=e,{id:r=`headlessui-combobox-label-${n}`}=f,i=it(f,["id"]),o=vr("Combobox.Label"),a=vi("Combobox.Label"),l=Fn(o.labelRef,t);Me(()=>a.registerLabel(r),[r]);let u=V(()=>{var p;return(p=o.inputRef.current)==null?void 0:p.focus({preventScroll:!0})}),s=S.useMemo(()=>({open:o.comboboxState===0,disabled:o.disabled}),[o]);return zt({ourProps:{ref:l,id:r,onClick:u},theirProps:i,slot:s,defaultTag:y0,name:"Combobox.Label"})}let w0="ul",S0=zo.RenderStrategy|zo.Static;function x0(e,t){let n=pi(),v=e,{id:r=`headlessui-combobox-options-${n}`,hold:i=!1}=v,o=it(v,["id","hold"]),a=vr("Combobox.Options"),l=Fn(a.optionsRef,t),u=Iu(),s=(()=>u!==null?(u&et.Open)===et.Open:a.comboboxState===0)();Me(()=>{var m;a.optionsPropsRef.current.static=(m=e.static)!=null?m:!1},[a.optionsPropsRef,e.static]),Me(()=>{a.optionsPropsRef.current.hold=i},[a.optionsPropsRef,i]),Bm({container:a.optionsRef.current,enabled:a.comboboxState===0,accept(m){return m.getAttribute("role")==="option"?NodeFilter.FILTER_REJECT:m.hasAttribute("role")?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT},walk(m){m.setAttribute("role","none")}});let f=_u(()=>{var m,g;return(g=a.labelId)!=null?g:(m=a.buttonRef.current)==null?void 0:m.id},[a.labelId,a.buttonRef.current]),p=S.useMemo(()=>({open:a.comboboxState===0}),[a]),c={"aria-labelledby":f,role:"listbox","aria-multiselectable":a.mode===1?!0:void 0,id:r,ref:l};return zt({ourProps:c,theirProps:o,slot:p,defaultTag:w0,features:S0,visible:s,name:"Combobox.Options"})}let k0="li";function C0(e,t){var n,r;let i=pi(),_=e,{id:o=`headlessui-combobox-option-${i}`,disabled:a=!1,value:l}=_,u=it(_,["id","disabled","value"]),s=vr("Combobox.Option"),f=vi("Combobox.Option"),p=s.activeOptionIndex!==null?s.options[s.activeOptionIndex].id===o:!1,c=s.isSelected(l),v=S.useRef(null),m=At({disabled:a,value:l,domRef:v,textValue:(r=(n=v.current)==null?void 0:n.textContent)==null?void 0:r.toLowerCase()}),g=Fn(t,v),x=V(()=>f.selectOption(o));Me(()=>f.registerOption(o,m),[m,o]);let h=S.useRef(!s.__demoMode);Me(()=>{if(!s.__demoMode)return;let T=Dn();return T.requestAnimationFrame(()=>{h.current=!0}),T.dispose},[]),Me(()=>{if(s.comboboxState!==0||!p||!h.current||s.activationTrigger===0)return;let T=Dn();return T.requestAnimationFrame(()=>{var L,R;(R=(L=v.current)==null?void 0:L.scrollIntoView)==null||R.call(L,{block:"nearest"})}),T.dispose},[v,p,s.comboboxState,s.activationTrigger,s.activeOptionIndex]);let d=V(T=>{if(a)return T.preventDefault();x(),s.mode===0&&f.closeCombobox(),i0()||requestAnimationFrame(()=>{var L;return(L=s.inputRef.current)==null?void 0:L.focus()})}),y=V(()=>{if(a)return f.goToOption(Te.Nothing);f.goToOption(Te.Specific,o)}),w=t0(),C=V(T=>w.update(T)),k=V(T=>{w.wasMoved(T)&&(a||p||f.goToOption(Te.Specific,o,0))}),b=V(T=>{w.wasMoved(T)&&(a||p&&(s.optionsPropsRef.current.hold||f.goToOption(Te.Nothing)))}),O=S.useMemo(()=>({active:p,selected:c,disabled:a}),[p,c,a]);return zt({ourProps:{id:o,ref:g,role:"option",tabIndex:a===!0?void 0:-1,"aria-disabled":a===!0?!0:void 0,"aria-selected":c,disabled:void 0,onClick:d,onFocus:y,onPointerEnter:C,onMouseEnter:C,onPointerMove:k,onMouseMove:k,onPointerLeave:b,onMouseLeave:b},theirProps:u,slot:O,defaultTag:k0,name:"Combobox.Option"})}let b0=Et(d0),E0=Et(m0),O0=Et(p0),P0=Et(g0),T0=Et(x0),_0=Et(C0),Qo=Object.assign(b0,{Input:O0,Button:E0,Label:P0,Options:T0,Option:_0});function zu(){let e=S.useRef(!1);return Me(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function R0(e=0){let[t,n]=S.useState(e),r=zu(),i=S.useCallback(u=>{r.current&&n(s=>s|u)},[t,r]),o=S.useCallback(u=>!!(t&u),[t]),a=S.useCallback(u=>{r.current&&n(s=>s&~u)},[n,r]),l=S.useCallback(u=>{r.current&&n(s=>s^u)},[n]);return{flags:t,addFlag:i,hasFlag:o,removeFlag:a,toggleFlag:l}}function D0(e){let t={called:!1};return(...n)=>{if(!t.called)return t.called=!0,e(...n)}}function ju(e,...t){e&&t.length>0&&e.classList.add(...t)}function Qu(e,...t){e&&t.length>0&&e.classList.remove(...t)}function F0(e,t){let n=Dn();if(!e)return n.dispose;let{transitionDuration:r,transitionDelay:i}=getComputedStyle(e),[o,a]=[r,i].map(u=>{let[s=0]=u.split(",").filter(Boolean).map(f=>f.includes("ms")?parseFloat(f):parseFloat(f)*1e3).sort((f,p)=>p-f);return s}),l=o+a;if(l!==0){n.group(s=>{s.setTimeout(()=>{t(),s.dispose()},l),s.addEventListener(e,"transitionrun",f=>{f.target===f.currentTarget&&s.dispose()})});let u=n.addEventListener(e,"transitionend",s=>{s.target===s.currentTarget&&(t(),u())})}else t();return n.add(()=>t()),n.dispose}function N0(e,t,n,r){let i=n?"enter":"leave",o=Dn(),a=r!==void 0?D0(r):()=>{};i==="enter"&&(e.removeAttribute("hidden"),e.style.display="");let l=Pe(i,{enter:()=>t.enter,leave:()=>t.leave}),u=Pe(i,{enter:()=>t.enterTo,leave:()=>t.leaveTo}),s=Pe(i,{enter:()=>t.enterFrom,leave:()=>t.leaveFrom});return Qu(e,...t.enter,...t.enterTo,...t.enterFrom,...t.leave,...t.leaveFrom,...t.leaveTo,...t.entered),ju(e,...l,...s),o.nextFrame(()=>{Qu(e,...s),ju(e,...u),F0(e,()=>(Qu(e,...l),ju(e,...t.entered),a()))}),o.dispose}function M0({container:e,direction:t,classes:n,onStart:r,onStop:i}){let o=zu(),a=hi(),l=At(t);Me(()=>{let u=Dn();a.add(u.dispose);let s=e.current;if(s&&l.current!=="idle"&&o.current)return u.dispose(),r.current(l.current),u.add(N0(s,n.current,l.current==="enter",()=>{u.dispose(),i.current(l.current)})),u.dispose},[t])}function Nn(e=""){return e.split(" ").filter(t=>t.trim().length>1)}let Wo=S.createContext(null);Wo.displayName="TransitionContext";var L0=(e=>(e.Visible="visible",e.Hidden="hidden",e))(L0||{});function I0(){let e=S.useContext(Wo);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}function $0(){let e=S.useContext(Ho);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}let Ho=S.createContext(null);Ho.displayName="NestingContext";function Bo(e){return"children"in e?Bo(e.children):e.current.filter(({el:t})=>t.current!==null).filter(({state:t})=>t==="visible").length>0}function Qd(e,t){let n=At(e),r=S.useRef([]),i=zu(),o=hi(),a=V((v,m=Ut.Hidden)=>{let g=r.current.findIndex(({el:x})=>x===v);g!==-1&&(Pe(m,{[Ut.Unmount](){r.current.splice(g,1)},[Ut.Hidden](){r.current[g].state="hidden"}}),o.microTask(()=>{var x;!Bo(r)&&i.current&&((x=n.current)==null||x.call(n))}))}),l=V(v=>{let m=r.current.find(({el:g})=>g===v);return m?m.state!=="visible"&&(m.state="visible"):r.current.push({el:v,state:"visible"}),()=>a(v,Ut.Unmount)}),u=S.useRef([]),s=S.useRef(Promise.resolve()),f=S.useRef({enter:[],leave:[],idle:[]}),p=V((v,m,g)=>{u.current.splice(0),t&&(t.chains.current[m]=t.chains.current[m].filter(([x])=>x!==v)),t==null||t.chains.current[m].push([v,new Promise(x=>{u.current.push(x)})]),t==null||t.chains.current[m].push([v,new Promise(x=>{Promise.all(f.current[m].map(([h,d])=>d)).then(()=>x())})]),m==="enter"?s.current=s.current.then(()=>t==null?void 0:t.wait.current).then(()=>g(m)):g(m)}),c=V((v,m,g)=>{Promise.all(f.current[m].splice(0).map(([x,h])=>h)).then(()=>{var x;(x=u.current.shift())==null||x()}).then(()=>g(m))});return S.useMemo(()=>({children:r,register:l,unregister:a,onStart:p,onStop:c,wait:s,chains:f}),[l,a,r,p,c,f,s])}function A0(){}let U0=["beforeEnter","afterEnter","beforeLeave","afterLeave"];function Wd(e){var t;let n={};for(let r of U0)n[r]=(t=e[r])!=null?t:A0;return n}function z0(e){let t=S.useRef(Wd(e));return S.useEffect(()=>{t.current=Wd(e)},[e]),t}let j0="div",Hd=zo.RenderStrategy;function Q0(e,t){let q=e,{beforeEnter:n,afterEnter:r,beforeLeave:i,afterLeave:o,enter:a,enterFrom:l,enterTo:u,entered:s,leave:f,leaveFrom:p,leaveTo:c}=q,v=it(q,["beforeEnter","afterEnter","beforeLeave","afterLeave","enter","enterFrom","enterTo","entered","leave","leaveFrom","leaveTo"]),m=S.useRef(null),g=Fn(m,t),x=v.unmount?Ut.Unmount:Ut.Hidden,{show:h,appear:d,initial:y}=I0(),[w,C]=S.useState(h?"visible":"hidden"),k=$0(),{register:b,unregister:O}=k,_=S.useRef(null);S.useEffect(()=>b(m),[b,m]),S.useEffect(()=>{if(x===Ut.Hidden&&m.current){if(h&&w!=="visible"){C("visible");return}return Pe(w,{hidden:()=>O(m),visible:()=>b(m)})}},[w,m,b,O,h,x]);let T=At({enter:Nn(a),enterFrom:Nn(l),enterTo:Nn(u),entered:Nn(s),leave:Nn(f),leaveFrom:Nn(p),leaveTo:Nn(c)}),L=z0({beforeEnter:n,afterEnter:r,beforeLeave:i,afterLeave:o}),R=Ru();S.useEffect(()=>{if(R&&w==="visible"&&m.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[m,w,R]);let $=y&&!d,z=(()=>!R||$||_.current===h?"idle":h?"enter":"leave")(),U=R0(0),j=V(Q=>Pe(Q,{enter:()=>{U.addFlag(et.Opening),L.current.beforeEnter()},leave:()=>{U.addFlag(et.Closing),L.current.beforeLeave()},idle:()=>{}})),J=V(Q=>Pe(Q,{enter:()=>{U.removeFlag(et.Opening),L.current.afterEnter()},leave:()=>{U.removeFlag(et.Closing),L.current.afterLeave()},idle:()=>{}})),P=Qd(()=>{C("hidden"),O(m)},k);M0({container:m,classes:T,direction:z,onStart:At(Q=>{P.onStart(m,Q,j)}),onStop:At(Q=>{P.onStop(m,Q,J),Q==="leave"&&!Bo(P)&&(C("hidden"),O(m))})}),S.useEffect(()=>{$&&(x===Ut.Hidden?_.current=null:_.current=h)},[h,$,w]);let N=v,M={ref:g};return d&&h&&(N=ge(G({},N),{className:Fu(v.className,...T.current.enter,...T.current.enterFrom)})),Y.createElement(Ho.Provider,{value:P},Y.createElement(Ud,{value:Pe(w,{visible:et.Open,hidden:et.Closed})|U.flags},zt({ourProps:M,theirProps:N,defaultTag:j0,features:Hd,visible:w==="visible",name:"Transition.Child"})))}function W0(e,t){let h=e,{show:n,appear:r=!1,unmount:i}=h,o=it(h,["show","appear","unmount"]),a=S.useRef(null),l=Fn(a,t);Ru();let u=Iu();if(n===void 0&&u!==null&&(n=(u&et.Open)===et.Open),![!0,!1].includes(n))throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[s,f]=S.useState(n?"visible":"hidden"),p=Qd(()=>{f("hidden")}),[c,v]=S.useState(!0),m=S.useRef([n]);Me(()=>{c!==!1&&m.current[m.current.length-1]!==n&&(m.current.push(n),v(!1))},[m,n]);let g=S.useMemo(()=>({show:n,appear:r,initial:c}),[n,r,c]);S.useEffect(()=>{if(n)f("visible");else if(!Bo(p))f("hidden");else{let d=a.current;if(!d)return;let y=d.getBoundingClientRect();y.x===0&&y.y===0&&y.width===0&&y.height===0&&f("hidden")}},[n,p]);let x={unmount:i};return Y.createElement(Ho.Provider,{value:p},Y.createElement(Wo.Provider,{value:g},zt({ourProps:ge(G({},x),{as:S.Fragment,children:Y.createElement(Bd,G(G({ref:l},x),o))}),theirProps:{},defaultTag:S.Fragment,features:Hd,visible:s==="visible",name:"Transition"})))}function H0(e,t){let n=S.useContext(Wo)!==null,r=Iu()!==null;return Y.createElement(Y.Fragment,null,!n&&r?Y.createElement(Wu,G({ref:t},e)):Y.createElement(Bd,G({ref:t},e)))}let Wu=Et(W0),Bd=Et(Q0),B0=Et(H0),Vd=Object.assign(Wu,{Child:B0,Root:Wu});function V0(){return F("div",{"aria-label":"Loading...",role:"status",children:$e("svg",{className:"a1-h-6 a1-w-6 a1-animate-spin",viewBox:"3 3 18 18",children:[F("path",{className:"a1-fill-indigo-200",d:"M12 5C8.13401 5 5 8.13401 5 12C5 15.866 8.13401 19 12 19C15.866 19 19 15.866 19 12C19 8.13401 15.866 5 12 5ZM3 12C3 7.02944 7.02944 3 12 3C16.9706 3 21 7.02944 21 12C21 16.9706 16.9706 21 12 21C7.02944 21 3 16.9706 3 12Z"}),F("path",{className:"a1-fill-indigo-800",d:"M16.9497 7.05015C14.2161 4.31648 9.78392 4.31648 7.05025 7.05015C6.65973 7.44067 6.02656 7.44067 5.63604 7.05015C5.24551 6.65962 5.24551 6.02646 5.63604 5.63593C9.15076 2.12121 14.8492 2.12121 18.364 5.63593C18.7545 6.02646 18.7545 6.65962 18.364 7.05015C17.9734 7.44067 17.3403 7.44067 16.9497 7.05015Z"})]})})}const q0=(e,t,n,r)=>F("li",{className:`${n}`,children:r});function qd({label:e,name:t,items:n,value:r=null,primaryColor:i,secondaryColor:o,status:a=null,onChange:l,getKey:u,getValue:s,filter:f,children:p=q0,disabled:c=!1,icon:v}){const[m,g]=S.useState(null),[x,h]=S.useState(""),[d,y]=S.useState(!1);S.useEffect(()=>{typeof l=="function"&&l(x)},[x]),S.useEffect(()=>{d||h(m||"")},[d,m]),S.useEffect(()=>{x!==m&&g(null)},[x,m]);const w=x===""?n:n==null?void 0:n.filter($=>f(x,$)),C="a1-z-100 a1-absolute a1-max-h-56 a1-max-w-full lg:a1-max-w-[none] a1-rounded-lg a1-border a1-border-gray-200 a1-bg-white a1-shadow-lg a1-mt-2 a1-overflow-x-hidden",k="a1-border-b a1-border-gray-200 a1-text-left a1-border-l-0 a1-border-r-0 a1-px-4 a1-py-2 a1-cursor-pointer a1-overflow-hidden",b="a1-bg-secondary",O="a1-bg-primary a1-text-white",_="a1-text-gray-900 a1-bg-white a1-rounded-lg focus:a1-border-primary",T="a1-ring-2 a1-ring-primary";let L={};i&&(L["--color-primary"]=i),o&&(L["--color-secondary"]=o);let R=null;return v&&(R=F("span",{className:"a1-p-3",children:v})),a==="loading"&&(R=F("span",{className:"a1-p-3",children:F(V0,{})})),F("div",{style:L,children:F(Qo,{disabled:c,name:t,value:r,onChange:$=>{g($),$&&h($)},children:({open:$})=>F(Pp,{children:$e("div",{className:"a1-relative",children:[$e("div",{className:`a1-flex a1-flex-row a1-items-center a1-gap-1 ${_} ${d?T:"a1-ring-2 a1-ring-gray-200"} ${c?"a1-opacity-50":""}`,children:[R,F(Qo.Input,{autoComplete:"off",className:"focus:a1-outline-none a1-w-full",onChange:z=>h(z.target.value),onFocus:()=>y(!0),onBlur:()=>setTimeout(()=>y(!1),200),placeholder:e})]}),F(Vd,{show:$||d&&x==="",className:"a1-relative a1-z-10",enter:"a1-transition a1-duration-100 a1-ease-out",enterFrom:"a1-transform a1-scale-95 a1-opacity-0",enterTo:"a1-transform a1-scale-100 a1-opacity-100",leave:"a1-transition a1-duration-75 a1-ease-out",leaveFrom:"a1-transform a1-scale-100 a1-opacity-100",leaveTo:"a1-transform a1-scale-95 a1-opacity-0",children:F(Qo.Options,{className:`${C}`,children:w==null?void 0:w.slice(0,25).map((z,U)=>F(Qo.Option,{value:s(z),as:S.Fragment,children:({active:j,selected:J})=>p(j,J,`${k} ${j?b:""} ${J?O:"a1-text-gray-900"} ${!j&&!J?"a1-bg-white":""}`,z)},`${u(z)}-${U}`))})})]})})})})}function mr(e){return mr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mr(e)}function te(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function ne(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function Ce(e){ne(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||mr(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console!="undefined"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function Vo(e,t){ne(2,arguments);var n=Ce(e),r=te(t);return isNaN(r)?new Date(NaN):(r&&n.setDate(n.getDate()+r),n)}function Yd(e,t){ne(2,arguments);var n=Ce(e),r=te(t);if(isNaN(r))return new Date(NaN);if(!r)return n;var i=n.getDate(),o=new Date(n.getTime());o.setMonth(n.getMonth()+r+1,0);var a=o.getDate();return i>=a?o:(n.setFullYear(o.getFullYear(),o.getMonth(),i),n)}function Y0(e,t){if(ne(2,arguments),!t||mr(t)!=="object")return new Date(NaN);var n=t.years?te(t.years):0,r=t.months?te(t.months):0,i=t.weeks?te(t.weeks):0,o=t.days?te(t.days):0,a=t.hours?te(t.hours):0,l=t.minutes?te(t.minutes):0,u=t.seconds?te(t.seconds):0,s=Ce(e),f=r||n?Yd(s,r+n*12):s,p=o||i?Vo(f,o+i*7):f,c=l+a*60,v=u+c*60,m=v*1e3,g=new Date(p.getTime()+m);return g}function K0(e,t){ne(2,arguments);var n=Ce(e).getTime(),r=te(t);return new Date(n+r)}var G0={};function mi(){return G0}function X0(e,t){var n,r,i,o,a,l,u,s;ne(1,arguments);var f=mi(),p=te((n=(r=(i=(o=t==null?void 0:t.weekStartsOn)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(l=a.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&i!==void 0?i:f.weekStartsOn)!==null&&r!==void 0?r:(u=f.locale)===null||u===void 0||(s=u.options)===null||s===void 0?void 0:s.weekStartsOn)!==null&&n!==void 0?n:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var c=Ce(e),v=c.getDay(),m=(v<p?7:0)+v-p;return c.setDate(c.getDate()-m),c.setHours(0,0,0,0),c}function Z0(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}function Kd(e){ne(1,arguments);var t=Ce(e);return t.setHours(0,0,0,0),t}function qo(e,t){ne(2,arguments);var n=Kd(e),r=Kd(t);return n.getTime()===r.getTime()}function J0(e){return ne(1,arguments),e instanceof Date||mr(e)==="object"&&Object.prototype.toString.call(e)==="[object Date]"}function ey(e){if(ne(1,arguments),!J0(e)&&typeof e!="number")return!1;var t=Ce(e);return!isNaN(Number(t))}function ty(e){ne(1,arguments);var t=Ce(e);return t.setDate(1),t.setHours(0,0,0,0),t}function ny(e,t){ne(2,arguments);var n=te(t);return K0(e,-n)}var ry=864e5;function iy(e){ne(1,arguments);var t=Ce(e),n=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var r=t.getTime(),i=n-r;return Math.floor(i/ry)+1}function Yo(e){ne(1,arguments);var t=1,n=Ce(e),r=n.getUTCDay(),i=(r<t?7:0)+r-t;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function Gd(e){ne(1,arguments);var t=Ce(e),n=t.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=Yo(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var a=Yo(o);return t.getTime()>=i.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function oy(e){ne(1,arguments);var t=Gd(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=Yo(n);return r}var ay=6048e5;function ly(e){ne(1,arguments);var t=Ce(e),n=Yo(t).getTime()-oy(t).getTime();return Math.round(n/ay)+1}function Ko(e,t){var n,r,i,o,a,l,u,s;ne(1,arguments);var f=mi(),p=te((n=(r=(i=(o=t==null?void 0:t.weekStartsOn)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(l=a.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&i!==void 0?i:f.weekStartsOn)!==null&&r!==void 0?r:(u=f.locale)===null||u===void 0||(s=u.options)===null||s===void 0?void 0:s.weekStartsOn)!==null&&n!==void 0?n:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var c=Ce(e),v=c.getUTCDay(),m=(v<p?7:0)+v-p;return c.setUTCDate(c.getUTCDate()-m),c.setUTCHours(0,0,0,0),c}function Xd(e,t){var n,r,i,o,a,l,u,s;ne(1,arguments);var f=Ce(e),p=f.getUTCFullYear(),c=mi(),v=te((n=(r=(i=(o=t==null?void 0:t.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(l=a.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&i!==void 0?i:c.firstWeekContainsDate)!==null&&r!==void 0?r:(u=c.locale)===null||u===void 0||(s=u.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(v>=1&&v<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var m=new Date(0);m.setUTCFullYear(p+1,0,v),m.setUTCHours(0,0,0,0);var g=Ko(m,t),x=new Date(0);x.setUTCFullYear(p,0,v),x.setUTCHours(0,0,0,0);var h=Ko(x,t);return f.getTime()>=g.getTime()?p+1:f.getTime()>=h.getTime()?p:p-1}function uy(e,t){var n,r,i,o,a,l,u,s;ne(1,arguments);var f=mi(),p=te((n=(r=(i=(o=t==null?void 0:t.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(l=a.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&i!==void 0?i:f.firstWeekContainsDate)!==null&&r!==void 0?r:(u=f.locale)===null||u===void 0||(s=u.options)===null||s===void 0?void 0:s.firstWeekContainsDate)!==null&&n!==void 0?n:1),c=Xd(e,t),v=new Date(0);v.setUTCFullYear(c,0,p),v.setUTCHours(0,0,0,0);var m=Ko(v,t);return m}var sy=6048e5;function cy(e,t){ne(1,arguments);var n=Ce(e),r=Ko(n,t).getTime()-uy(n,t).getTime();return Math.round(r/sy)+1}function Z(e,t){for(var n=e<0?"-":"",r=Math.abs(e).toString();r.length<t;)r="0"+r;return n+r}var fy={y:function(t,n){var r=t.getUTCFullYear(),i=r>0?r:1-r;return Z(n==="yy"?i%100:i,n.length)},M:function(t,n){var r=t.getUTCMonth();return n==="M"?String(r+1):Z(r+1,2)},d:function(t,n){return Z(t.getUTCDate(),n.length)},a:function(t,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.toUpperCase();case"aaa":return r;case"aaaaa":return r[0];case"aaaa":default:return r==="am"?"a.m.":"p.m."}},h:function(t,n){return Z(t.getUTCHours()%12||12,n.length)},H:function(t,n){return Z(t.getUTCHours(),n.length)},m:function(t,n){return Z(t.getUTCMinutes(),n.length)},s:function(t,n){return Z(t.getUTCSeconds(),n.length)},S:function(t,n){var r=n.length,i=t.getUTCMilliseconds(),o=Math.floor(i*Math.pow(10,r-3));return Z(o,n.length)}};const sn=fy;var yr={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},dy={G:function(t,n,r){var i=t.getUTCFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return r.era(i,{width:"abbreviated"});case"GGGGG":return r.era(i,{width:"narrow"});case"GGGG":default:return r.era(i,{width:"wide"})}},y:function(t,n,r){if(n==="yo"){var i=t.getUTCFullYear(),o=i>0?i:1-i;return r.ordinalNumber(o,{unit:"year"})}return sn.y(t,n)},Y:function(t,n,r,i){var o=Xd(t,i),a=o>0?o:1-o;if(n==="YY"){var l=a%100;return Z(l,2)}return n==="Yo"?r.ordinalNumber(a,{unit:"year"}):Z(a,n.length)},R:function(t,n){var r=Gd(t);return Z(r,n.length)},u:function(t,n){var r=t.getUTCFullYear();return Z(r,n.length)},Q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"Q":return String(i);case"QQ":return Z(i,2);case"Qo":return r.ordinalNumber(i,{unit:"quarter"});case"QQQ":return r.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return r.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(i,{width:"wide",context:"formatting"})}},q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"q":return String(i);case"qq":return Z(i,2);case"qo":return r.ordinalNumber(i,{unit:"quarter"});case"qqq":return r.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return r.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(i,{width:"wide",context:"standalone"})}},M:function(t,n,r){var i=t.getUTCMonth();switch(n){case"M":case"MM":return sn.M(t,n);case"Mo":return r.ordinalNumber(i+1,{unit:"month"});case"MMM":return r.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return r.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(i,{width:"wide",context:"formatting"})}},L:function(t,n,r){var i=t.getUTCMonth();switch(n){case"L":return String(i+1);case"LL":return Z(i+1,2);case"Lo":return r.ordinalNumber(i+1,{unit:"month"});case"LLL":return r.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return r.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(i,{width:"wide",context:"standalone"})}},w:function(t,n,r,i){var o=cy(t,i);return n==="wo"?r.ordinalNumber(o,{unit:"week"}):Z(o,n.length)},I:function(t,n,r){var i=ly(t);return n==="Io"?r.ordinalNumber(i,{unit:"week"}):Z(i,n.length)},d:function(t,n,r){return n==="do"?r.ordinalNumber(t.getUTCDate(),{unit:"date"}):sn.d(t,n)},D:function(t,n,r){var i=iy(t);return n==="Do"?r.ordinalNumber(i,{unit:"dayOfYear"}):Z(i,n.length)},E:function(t,n,r){var i=t.getUTCDay();switch(n){case"E":case"EE":case"EEE":return r.day(i,{width:"abbreviated",context:"formatting"});case"EEEEE":return r.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(i,{width:"short",context:"formatting"});case"EEEE":default:return r.day(i,{width:"wide",context:"formatting"})}},e:function(t,n,r,i){var o=t.getUTCDay(),a=(o-i.weekStartsOn+8)%7||7;switch(n){case"e":return String(a);case"ee":return Z(a,2);case"eo":return r.ordinalNumber(a,{unit:"day"});case"eee":return r.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return r.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(o,{width:"short",context:"formatting"});case"eeee":default:return r.day(o,{width:"wide",context:"formatting"})}},c:function(t,n,r,i){var o=t.getUTCDay(),a=(o-i.weekStartsOn+8)%7||7;switch(n){case"c":return String(a);case"cc":return Z(a,n.length);case"co":return r.ordinalNumber(a,{unit:"day"});case"ccc":return r.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return r.day(o,{width:"narrow",context:"standalone"});case"cccccc":return r.day(o,{width:"short",context:"standalone"});case"cccc":default:return r.day(o,{width:"wide",context:"standalone"})}},i:function(t,n,r){var i=t.getUTCDay(),o=i===0?7:i;switch(n){case"i":return String(o);case"ii":return Z(o,n.length);case"io":return r.ordinalNumber(o,{unit:"day"});case"iii":return r.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return r.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return r.day(i,{width:"short",context:"formatting"});case"iiii":default:return r.day(i,{width:"wide",context:"formatting"})}},a:function(t,n,r){var i=t.getUTCHours(),o=i/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(t,n,r){var i=t.getUTCHours(),o;switch(i===12?o=yr.noon:i===0?o=yr.midnight:o=i/12>=1?"pm":"am",n){case"b":case"bb":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(t,n,r){var i=t.getUTCHours(),o;switch(i>=17?o=yr.evening:i>=12?o=yr.afternoon:i>=4?o=yr.morning:o=yr.night,n){case"B":case"BB":case"BBB":return r.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return r.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(t,n,r){if(n==="ho"){var i=t.getUTCHours()%12;return i===0&&(i=12),r.ordinalNumber(i,{unit:"hour"})}return sn.h(t,n)},H:function(t,n,r){return n==="Ho"?r.ordinalNumber(t.getUTCHours(),{unit:"hour"}):sn.H(t,n)},K:function(t,n,r){var i=t.getUTCHours()%12;return n==="Ko"?r.ordinalNumber(i,{unit:"hour"}):Z(i,n.length)},k:function(t,n,r){var i=t.getUTCHours();return i===0&&(i=24),n==="ko"?r.ordinalNumber(i,{unit:"hour"}):Z(i,n.length)},m:function(t,n,r){return n==="mo"?r.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):sn.m(t,n)},s:function(t,n,r){return n==="so"?r.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):sn.s(t,n)},S:function(t,n){return sn.S(t,n)},X:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();if(a===0)return"Z";switch(n){case"X":return Jd(a);case"XXXX":case"XX":return Mn(a);case"XXXXX":case"XXX":default:return Mn(a,":")}},x:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"x":return Jd(a);case"xxxx":case"xx":return Mn(a);case"xxxxx":case"xxx":default:return Mn(a,":")}},O:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+Zd(a,":");case"OOOO":default:return"GMT"+Mn(a,":")}},z:function(t,n,r,i){var o=i._originalDate||t,a=o.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+Zd(a,":");case"zzzz":default:return"GMT"+Mn(a,":")}},t:function(t,n,r,i){var o=i._originalDate||t,a=Math.floor(o.getTime()/1e3);return Z(a,n.length)},T:function(t,n,r,i){var o=i._originalDate||t,a=o.getTime();return Z(a,n.length)}};function Zd(e,t){var n=e>0?"-":"+",r=Math.abs(e),i=Math.floor(r/60),o=r%60;if(o===0)return n+String(i);var a=t||"";return n+String(i)+a+Z(o,2)}function Jd(e,t){if(e%60===0){var n=e>0?"-":"+";return n+Z(Math.abs(e)/60,2)}return Mn(e,t)}function Mn(e,t){var n=t||"",r=e>0?"-":"+",i=Math.abs(e),o=Z(Math.floor(i/60),2),a=Z(i%60,2);return r+o+n+a}const hy=dy;var eh=function(t,n){switch(t){case"P":return n.date({width:"short"});case"PP":return n.date({width:"medium"});case"PPP":return n.date({width:"long"});case"PPPP":default:return n.date({width:"full"})}},th=function(t,n){switch(t){case"p":return n.time({width:"short"});case"pp":return n.time({width:"medium"});case"ppp":return n.time({width:"long"});case"pppp":default:return n.time({width:"full"})}},py=function(t,n){var r=t.match(/(P+)(p+)?/)||[],i=r[1],o=r[2];if(!o)return eh(t,n);var a;switch(i){case"P":a=n.dateTime({width:"short"});break;case"PP":a=n.dateTime({width:"medium"});break;case"PPP":a=n.dateTime({width:"long"});break;case"PPPP":default:a=n.dateTime({width:"full"});break}return a.replace("{{date}}",eh(i,n)).replace("{{time}}",th(o,n))},vy={p:th,P:py};const my=vy;var yy=["D","DD"],gy=["YY","YYYY"];function wy(e){return yy.indexOf(e)!==-1}function Sy(e){return gy.indexOf(e)!==-1}function nh(e,t,n){if(e==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var xy={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},ky=function(t,n,r){var i,o=xy[t];return typeof o=="string"?i=o:n===1?i=o.one:i=o.other.replace("{{count}}",n.toString()),r!=null&&r.addSuffix?r.comparison&&r.comparison>0?"in "+i:i+" ago":i};const Cy=ky;function Hu(e){return function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.width?String(t.width):e.defaultWidth,r=e.formats[n]||e.formats[e.defaultWidth];return r}}var by={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Ey={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Oy={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Py={date:Hu({formats:by,defaultWidth:"full"}),time:Hu({formats:Ey,defaultWidth:"full"}),dateTime:Hu({formats:Oy,defaultWidth:"full"})};const Ty=Py;var _y={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Ry=function(t,n,r,i){return _y[t]};const Dy=Ry;function yi(e){return function(t,n){var r=n!=null&&n.context?String(n.context):"standalone",i;if(r==="formatting"&&e.formattingValues){var o=e.defaultFormattingWidth||e.defaultWidth,a=n!=null&&n.width?String(n.width):o;i=e.formattingValues[a]||e.formattingValues[o]}else{var l=e.defaultWidth,u=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[u]||e.values[l]}var s=e.argumentCallback?e.argumentCallback(t):t;return i[s]}}var Fy={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Ny={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},My={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Ly={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Iy={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},$y={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},Ay=function(t,n){var r=Number(t),i=r%100;if(i>20||i<10)switch(i%10){case 1:return r+"st";case 2:return r+"nd";case 3:return r+"rd"}return r+"th"},Uy={ordinalNumber:Ay,era:yi({values:Fy,defaultWidth:"wide"}),quarter:yi({values:Ny,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:yi({values:My,defaultWidth:"wide"}),day:yi({values:Ly,defaultWidth:"wide"}),dayPeriod:yi({values:Iy,defaultWidth:"wide",formattingValues:$y,defaultFormattingWidth:"wide"})};const zy=Uy;function gi(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;var a=o[0],l=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],u=Array.isArray(l)?Qy(l,function(p){return p.test(a)}):jy(l,function(p){return p.test(a)}),s;s=e.valueCallback?e.valueCallback(u):u,s=n.valueCallback?n.valueCallback(s):s;var f=t.slice(a.length);return{value:s,rest:f}}}function jy(e,t){for(var n in e)if(e.hasOwnProperty(n)&&t(e[n]))return n}function Qy(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return n}function Wy(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.match(e.matchPattern);if(!r)return null;var i=r[0],o=t.match(e.parsePattern);if(!o)return null;var a=e.valueCallback?e.valueCallback(o[0]):o[0];a=n.valueCallback?n.valueCallback(a):a;var l=t.slice(i.length);return{value:a,rest:l}}}var Hy=/^(\d+)(th|st|nd|rd)?/i,By=/\d+/i,Vy={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},qy={any:[/^b/i,/^(a|c)/i]},Yy={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Ky={any:[/1/i,/2/i,/3/i,/4/i]},Gy={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Xy={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Zy={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Jy={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},eg={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},tg={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},ng={ordinalNumber:Wy({matchPattern:Hy,parsePattern:By,valueCallback:function(t){return parseInt(t,10)}}),era:gi({matchPatterns:Vy,defaultMatchWidth:"wide",parsePatterns:qy,defaultParseWidth:"any"}),quarter:gi({matchPatterns:Yy,defaultMatchWidth:"wide",parsePatterns:Ky,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:gi({matchPatterns:Gy,defaultMatchWidth:"wide",parsePatterns:Xy,defaultParseWidth:"any"}),day:gi({matchPatterns:Zy,defaultMatchWidth:"wide",parsePatterns:Jy,defaultParseWidth:"any"}),dayPeriod:gi({matchPatterns:eg,defaultMatchWidth:"any",parsePatterns:tg,defaultParseWidth:"any"})},rg={code:"en-US",formatDistance:Cy,formatLong:Ty,formatRelative:Dy,localize:zy,match:ng,options:{weekStartsOn:0,firstWeekContainsDate:1}};const ig=rg;var og=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,ag=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,lg=/^'([^]*?)'?$/,ug=/''/g,sg=/[a-zA-Z]/;function cg(e,t,n){var r,i,o,a,l,u,s,f,p,c,v,m,g,x,h,d,y,w;ne(2,arguments);var C=String(t),k=mi(),b=(r=(i=n==null?void 0:n.locale)!==null&&i!==void 0?i:k.locale)!==null&&r!==void 0?r:ig,O=te((o=(a=(l=(u=n==null?void 0:n.firstWeekContainsDate)!==null&&u!==void 0?u:n==null||(s=n.locale)===null||s===void 0||(f=s.options)===null||f===void 0?void 0:f.firstWeekContainsDate)!==null&&l!==void 0?l:k.firstWeekContainsDate)!==null&&a!==void 0?a:(p=k.locale)===null||p===void 0||(c=p.options)===null||c===void 0?void 0:c.firstWeekContainsDate)!==null&&o!==void 0?o:1);if(!(O>=1&&O<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var _=te((v=(m=(g=(x=n==null?void 0:n.weekStartsOn)!==null&&x!==void 0?x:n==null||(h=n.locale)===null||h===void 0||(d=h.options)===null||d===void 0?void 0:d.weekStartsOn)!==null&&g!==void 0?g:k.weekStartsOn)!==null&&m!==void 0?m:(y=k.locale)===null||y===void 0||(w=y.options)===null||w===void 0?void 0:w.weekStartsOn)!==null&&v!==void 0?v:0);if(!(_>=0&&_<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!b.localize)throw new RangeError("locale must contain localize property");if(!b.formatLong)throw new RangeError("locale must contain formatLong property");var T=Ce(e);if(!ey(T))throw new RangeError("Invalid time value");var L=Z0(T),R=ny(T,L),$={firstWeekContainsDate:O,weekStartsOn:_,locale:b,_originalDate:T},z=C.match(ag).map(function(U){var j=U[0];if(j==="p"||j==="P"){var J=my[j];return J(U,b.formatLong)}return U}).join("").match(og).map(function(U){if(U==="''")return"'";var j=U[0];if(j==="'")return fg(U);var J=hy[j];if(J)return!(n!=null&&n.useAdditionalWeekYearTokens)&&Sy(U)&&nh(U,t,String(e)),!(n!=null&&n.useAdditionalDayOfYearTokens)&&wy(U)&&nh(U,t,String(e)),J(R,U,b.localize,$);if(j.match(sg))throw new RangeError("Format string contains an unescaped latin alphabet character `"+j+"`");return U}).join("");return z}function fg(e){var t=e.match(lg);return t?t[1].replace(ug,"'"):e}function dg(e,t){ne(2,arguments);var n=Ce(e),r=Ce(t);return n.getTime()<r.getTime()}function Bu(e,t){return Bu=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Bu(e,t)}function hg(e,t){ne(2,arguments);var n=te(t);return Vo(e,-n)}function pg(e,t){ne(2,arguments);var n=te(t);return Yd(e,-n)}function vg(e,t){if(ne(2,arguments),!t||mr(t)!=="object")return new Date(NaN);var n=t.years?te(t.years):0,r=t.months?te(t.months):0,i=t.weeks?te(t.weeks):0,o=t.days?te(t.days):0,a=t.hours?te(t.hours):0,l=t.minutes?te(t.minutes):0,u=t.seconds?te(t.seconds):0,s=pg(e,r+n*12),f=hg(s,o+i*7),p=l+a*60,c=u+p*60,v=c*1e3,m=new Date(f.getTime()-v);return m}var Vu=function(e,t){return Vu=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},Vu(e,t)};function cn(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Vu(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function mg(e,t,n,r){function i(o){return o instanceof n?o:new n(function(a){a(o)})}return new(n||(n=Promise))(function(o,a){function l(f){try{s(r.next(f))}catch(p){a(p)}}function u(f){try{s(r.throw(f))}catch(p){a(p)}}function s(f){f.done?o(f.value):i(f.value).then(l,u)}s((r=r.apply(e,t||[])).next())})}function rh(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,i,o,a;return a={next:l(0),throw:l(1),return:l(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function l(s){return function(f){return u([s,f])}}function u(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(n=0)),n;)try{if(r=1,i&&(o=s[0]&2?i.return:s[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,s[1])).done)return o;switch(i=0,o&&(s=[s[0]&2,o.value]),s[0]){case 0:case 1:o=s;break;case 4:return n.label++,{value:s[1],done:!1};case 5:n.label++,i=s[1],s=[0];continue;case 7:s=n.ops.pop(),n.trys.pop();continue;default:if(o=n.trys,!(o=o.length>0&&o[o.length-1])&&(s[0]===6||s[0]===2)){n=0;continue}if(s[0]===3&&(!o||s[1]>o[0]&&s[1]<o[3])){n.label=s[1];break}if(s[0]===6&&n.label<o[1]){n.label=o[1],o=s;break}if(o&&n.label<o[2]){n.label=o[2],n.ops.push(s);break}o[2]&&n.ops.pop(),n.trys.pop();continue}s=t.call(e,n)}catch(f){s=[6,f],i=0}finally{r=o=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function Ln(e){var t=typeof Symbol=="function"&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function fn(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,o=[],a;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)o.push(i.value)}catch(l){a={error:l}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o}function In(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}function gr(e){return this instanceof gr?(this.v=e,this):new gr(e)}function yg(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(e,t||[]),i,o=[];return i={},a("next"),a("throw"),a("return"),i[Symbol.asyncIterator]=function(){return this},i;function a(c){r[c]&&(i[c]=function(v){return new Promise(function(m,g){o.push([c,v,m,g])>1||l(c,v)})})}function l(c,v){try{u(r[c](v))}catch(m){p(o[0][3],m)}}function u(c){c.value instanceof gr?Promise.resolve(c.value.v).then(s,f):p(o[0][2],c)}function s(c){l("next",c)}function f(c){l("throw",c)}function p(c,v){c(v),o.shift(),o.length&&l(o[0][0],o[0][1])}}function gg(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof Ln=="function"?Ln(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(o){n[o]=e[o]&&function(a){return new Promise(function(l,u){a=e[o](a),i(l,u,a.done,a.value)})}}function i(o,a,l,u){Promise.resolve(u).then(function(s){o({value:s,done:l})},a)}}function re(e){return typeof e=="function"}function ih(e){var t=function(r){Error.call(r),r.stack=new Error().stack},n=e(t);return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}var qu=ih(function(e){return function(n){e(this),this.message=n?n.length+` errors occurred during unsubscription:
|
|
44
44
|
`+n.map(function(r,i){return i+1+") "+r.toString()}).join(`
|
|
45
45
|
`):"",this.name="UnsubscriptionError",this.errors=n}});function wi(e,t){if(e){var n=e.indexOf(t);0<=n&&e.splice(n,1)}}var wr=function(){function e(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return e.prototype.unsubscribe=function(){var t,n,r,i,o;if(!this.closed){this.closed=!0;var a=this._parentage;if(a)if(this._parentage=null,Array.isArray(a))try{for(var l=Ln(a),u=l.next();!u.done;u=l.next()){var s=u.value;s.remove(this)}}catch(g){t={error:g}}finally{try{u&&!u.done&&(n=l.return)&&n.call(l)}finally{if(t)throw t.error}}else a.remove(this);var f=this.initialTeardown;if(re(f))try{f()}catch(g){o=g instanceof qu?g.errors:[g]}var p=this._finalizers;if(p){this._finalizers=null;try{for(var c=Ln(p),v=c.next();!v.done;v=c.next()){var m=v.value;try{lh(m)}catch(g){o=o!=null?o:[],g instanceof qu?o=In(In([],fn(o)),fn(g.errors)):o.push(g)}}}catch(g){r={error:g}}finally{try{v&&!v.done&&(i=c.return)&&i.call(c)}finally{if(r)throw r.error}}}if(o)throw new qu(o)}},e.prototype.add=function(t){var n;if(t&&t!==this)if(this.closed)lh(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=(n=this._finalizers)!==null&&n!==void 0?n:[]).push(t)}},e.prototype._hasParent=function(t){var n=this._parentage;return n===t||Array.isArray(n)&&n.includes(t)},e.prototype._addParent=function(t){var n=this._parentage;this._parentage=Array.isArray(n)?(n.push(t),n):n?[n,t]:t},e.prototype._removeParent=function(t){var n=this._parentage;n===t?this._parentage=null:Array.isArray(n)&&wi(n,t)},e.prototype.remove=function(t){var n=this._finalizers;n&&wi(n,t),t instanceof e&&t._removeParent(this)},e.EMPTY=function(){var t=new e;return t.closed=!0,t}(),e}(),oh=wr.EMPTY;function ah(e){return e instanceof wr||e&&"closed"in e&&re(e.remove)&&re(e.add)&&re(e.unsubscribe)}function lh(e){re(e)?e():e.unsubscribe()}var uh={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Yu={setTimeout:function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i=Yu.delegate;return i!=null&&i.setTimeout?i.setTimeout.apply(i,In([e,t],fn(n))):setTimeout.apply(void 0,In([e,t],fn(n)))},clearTimeout:function(e){var t=Yu.delegate;return((t==null?void 0:t.clearTimeout)||clearTimeout)(e)},delegate:void 0};function sh(e){Yu.setTimeout(function(){throw e})}function ch(){}function Go(e){e()}var Ku=function(e){cn(t,e);function t(n){var r=e.call(this)||this;return r.isStopped=!1,n?(r.destination=n,ah(n)&&n.add(r)):r.destination=kg,r}return t.create=function(n,r,i){return new Xu(n,r,i)},t.prototype.next=function(n){this.isStopped||this._next(n)},t.prototype.error=function(n){this.isStopped||(this.isStopped=!0,this._error(n))},t.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,e.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(n){this.destination.next(n)},t.prototype._error=function(n){try{this.destination.error(n)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t}(wr),wg=Function.prototype.bind;function Gu(e,t){return wg.call(e,t)}var Sg=function(){function e(t){this.partialObserver=t}return e.prototype.next=function(t){var n=this.partialObserver;if(n.next)try{n.next(t)}catch(r){Xo(r)}},e.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(r){Xo(r)}else Xo(t)},e.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(n){Xo(n)}},e}(),Xu=function(e){cn(t,e);function t(n,r,i){var o=e.call(this)||this,a;if(re(n)||!n)a={next:n!=null?n:void 0,error:r!=null?r:void 0,complete:i!=null?i:void 0};else{var l;o&&uh.useDeprecatedNextContext?(l=Object.create(n),l.unsubscribe=function(){return o.unsubscribe()},a={next:n.next&&Gu(n.next,l),error:n.error&&Gu(n.error,l),complete:n.complete&&Gu(n.complete,l)}):a=n}return o.destination=new Sg(a),o}return t}(Ku);function Xo(e){sh(e)}function xg(e){throw e}var kg={closed:!0,next:ch,error:xg,complete:ch},Zu=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function fh(e){return e}function Cg(e){return e.length===0?fh:e.length===1?e[0]:function(n){return e.reduce(function(r,i){return i(r)},n)}}var tt=function(){function e(t){t&&(this._subscribe=t)}return e.prototype.lift=function(t){var n=new e;return n.source=this,n.operator=t,n},e.prototype.subscribe=function(t,n,r){var i=this,o=Eg(t)?t:new Xu(t,n,r);return Go(function(){var a=i,l=a.operator,u=a.source;o.add(l?l.call(o,u):u?i._subscribe(o):i._trySubscribe(o))}),o},e.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(n){t.error(n)}},e.prototype.forEach=function(t,n){var r=this;return n=dh(n),new n(function(i,o){var a=new Xu({next:function(l){try{t(l)}catch(u){o(u),a.unsubscribe()}},error:o,complete:i});r.subscribe(a)})},e.prototype._subscribe=function(t){var n;return(n=this.source)===null||n===void 0?void 0:n.subscribe(t)},e.prototype[Zu]=function(){return this},e.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return Cg(t)(this)},e.prototype.toPromise=function(t){var n=this;return t=dh(t),new t(function(r,i){var o;n.subscribe(function(a){return o=a},function(a){return i(a)},function(){return r(o)})})},e.create=function(t){return new e(t)},e}();function dh(e){var t;return(t=e!=null?e:uh.Promise)!==null&&t!==void 0?t:Promise}function bg(e){return e&&re(e.next)&&re(e.error)&&re(e.complete)}function Eg(e){return e&&e instanceof Ku||bg(e)&&ah(e)}function Og(e){return re(e==null?void 0:e.lift)}function Sr(e){return function(t){if(Og(t))return t.lift(function(n){try{return e(n,this)}catch(r){this.error(r)}});throw new TypeError("Unable to lift unknown Observable type")}}function xr(e,t,n,r,i){return new Pg(e,t,n,r,i)}var Pg=function(e){cn(t,e);function t(n,r,i,o,a,l){var u=e.call(this,n)||this;return u.onFinalize=a,u.shouldUnsubscribe=l,u._next=r?function(s){try{r(s)}catch(f){n.error(f)}}:e.prototype._next,u._error=o?function(s){try{o(s)}catch(f){n.error(f)}finally{this.unsubscribe()}}:e.prototype._error,u._complete=i?function(){try{i()}catch(s){n.error(s)}finally{this.unsubscribe()}}:e.prototype._complete,u}return t.prototype.unsubscribe=function(){var n;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var r=this.closed;e.prototype.unsubscribe.call(this),!r&&((n=this.onFinalize)===null||n===void 0||n.call(this))}},t}(Ku),Tg=ih(function(e){return function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),hh=function(e){cn(t,e);function t(){var n=e.call(this)||this;return n.closed=!1,n.currentObservers=null,n.observers=[],n.isStopped=!1,n.hasError=!1,n.thrownError=null,n}return t.prototype.lift=function(n){var r=new ph(this,this);return r.operator=n,r},t.prototype._throwIfClosed=function(){if(this.closed)throw new Tg},t.prototype.next=function(n){var r=this;Go(function(){var i,o;if(r._throwIfClosed(),!r.isStopped){r.currentObservers||(r.currentObservers=Array.from(r.observers));try{for(var a=Ln(r.currentObservers),l=a.next();!l.done;l=a.next()){var u=l.value;u.next(n)}}catch(s){i={error:s}}finally{try{l&&!l.done&&(o=a.return)&&o.call(a)}finally{if(i)throw i.error}}}})},t.prototype.error=function(n){var r=this;Go(function(){if(r._throwIfClosed(),!r.isStopped){r.hasError=r.isStopped=!0,r.thrownError=n;for(var i=r.observers;i.length;)i.shift().error(n)}})},t.prototype.complete=function(){var n=this;Go(function(){if(n._throwIfClosed(),!n.isStopped){n.isStopped=!0;for(var r=n.observers;r.length;)r.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,"observed",{get:function(){var n;return((n=this.observers)===null||n===void 0?void 0:n.length)>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(n){return this._throwIfClosed(),e.prototype._trySubscribe.call(this,n)},t.prototype._subscribe=function(n){return this._throwIfClosed(),this._checkFinalizedStatuses(n),this._innerSubscribe(n)},t.prototype._innerSubscribe=function(n){var r=this,i=this,o=i.hasError,a=i.isStopped,l=i.observers;return o||a?oh:(this.currentObservers=null,l.push(n),new wr(function(){r.currentObservers=null,wi(l,n)}))},t.prototype._checkFinalizedStatuses=function(n){var r=this,i=r.hasError,o=r.thrownError,a=r.isStopped;i?n.error(o):a&&n.complete()},t.prototype.asObservable=function(){var n=new tt;return n.source=this,n},t.create=function(n,r){return new ph(n,r)},t}(tt),ph=function(e){cn(t,e);function t(n,r){var i=e.call(this)||this;return i.destination=n,i.source=r,i}return t.prototype.next=function(n){var r,i;(i=(r=this.destination)===null||r===void 0?void 0:r.next)===null||i===void 0||i.call(r,n)},t.prototype.error=function(n){var r,i;(i=(r=this.destination)===null||r===void 0?void 0:r.error)===null||i===void 0||i.call(r,n)},t.prototype.complete=function(){var n,r;(r=(n=this.destination)===null||n===void 0?void 0:n.complete)===null||r===void 0||r.call(n)},t.prototype._subscribe=function(n){var r,i;return(i=(r=this.source)===null||r===void 0?void 0:r.subscribe(n))!==null&&i!==void 0?i:oh},t}(hh),vh={now:function(){return(vh.delegate||Date).now()},delegate:void 0},_g=function(e){cn(t,e);function t(n,r){return e.call(this)||this}return t.prototype.schedule=function(n,r){return this},t}(wr),Zo={setInterval:function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i=Zo.delegate;return i!=null&&i.setInterval?i.setInterval.apply(i,In([e,t],fn(n))):setInterval.apply(void 0,In([e,t],fn(n)))},clearInterval:function(e){var t=Zo.delegate;return((t==null?void 0:t.clearInterval)||clearInterval)(e)},delegate:void 0},Rg=function(e){cn(t,e);function t(n,r){var i=e.call(this,n,r)||this;return i.scheduler=n,i.work=r,i.pending=!1,i}return t.prototype.schedule=function(n,r){var i;if(r===void 0&&(r=0),this.closed)return this;this.state=n;var o=this.id,a=this.scheduler;return o!=null&&(this.id=this.recycleAsyncId(a,o,r)),this.pending=!0,this.delay=r,this.id=(i=this.id)!==null&&i!==void 0?i:this.requestAsyncId(a,this.id,r),this},t.prototype.requestAsyncId=function(n,r,i){return i===void 0&&(i=0),Zo.setInterval(n.flush.bind(n,this),i)},t.prototype.recycleAsyncId=function(n,r,i){if(i===void 0&&(i=0),i!=null&&this.delay===i&&this.pending===!1)return r;r!=null&&Zo.clearInterval(r)},t.prototype.execute=function(n,r){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;var i=this._execute(n,r);if(i)return i;this.pending===!1&&this.id!=null&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},t.prototype._execute=function(n,r){var i=!1,o;try{this.work(n)}catch(a){i=!0,o=a||new Error("Scheduled action threw falsy error")}if(i)return this.unsubscribe(),o},t.prototype.unsubscribe=function(){if(!this.closed){var n=this,r=n.id,i=n.scheduler,o=i.actions;this.work=this.state=this.scheduler=null,this.pending=!1,wi(o,this),r!=null&&(this.id=this.recycleAsyncId(i,r,null)),this.delay=null,e.prototype.unsubscribe.call(this)}},t}(_g),mh=function(){function e(t,n){n===void 0&&(n=e.now),this.schedulerActionCtor=t,this.now=n}return e.prototype.schedule=function(t,n,r){return n===void 0&&(n=0),new this.schedulerActionCtor(this,t).schedule(r,n)},e.now=vh.now,e}(),Dg=function(e){cn(t,e);function t(n,r){r===void 0&&(r=mh.now);var i=e.call(this,n,r)||this;return i.actions=[],i._active=!1,i}return t.prototype.flush=function(n){var r=this.actions;if(this._active){r.push(n);return}var i;this._active=!0;do if(i=n.execute(n.state,n.delay))break;while(n=r.shift());if(this._active=!1,i){for(;n=r.shift();)n.unsubscribe();throw i}},t}(mh),Fg=new Dg(Rg),Ng=new tt(function(e){return e.complete()});function Mg(e){return e&&re(e.schedule)}function yh(e){return e[e.length-1]}function gh(e){return Mg(yh(e))?e.pop():void 0}function Lg(e,t){return typeof yh(e)=="number"?e.pop():t}var Ju=function(e){return e&&typeof e.length=="number"&&typeof e!="function"};function wh(e){return re(e==null?void 0:e.then)}function Sh(e){return re(e[Zu])}function xh(e){return Symbol.asyncIterator&&re(e==null?void 0:e[Symbol.asyncIterator])}function kh(e){return new TypeError("You provided "+(e!==null&&typeof e=="object"?"an invalid object":"'"+e+"'")+" where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.")}function Ig(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var Ch=Ig();function bh(e){return re(e==null?void 0:e[Ch])}function Eh(e){return yg(this,arguments,function(){var n,r,i,o;return rh(this,function(a){switch(a.label){case 0:n=e.getReader(),a.label=1;case 1:a.trys.push([1,,9,10]),a.label=2;case 2:return[4,gr(n.read())];case 3:return r=a.sent(),i=r.value,o=r.done,o?[4,gr(void 0)]:[3,5];case 4:return[2,a.sent()];case 5:return[4,gr(i)];case 6:return[4,a.sent()];case 7:return a.sent(),[3,2];case 8:return[3,10];case 9:return n.releaseLock(),[7];case 10:return[2]}})})}function Oh(e){return re(e==null?void 0:e.getReader)}function $n(e){if(e instanceof tt)return e;if(e!=null){if(Sh(e))return $g(e);if(Ju(e))return Ag(e);if(wh(e))return Ug(e);if(xh(e))return Ph(e);if(bh(e))return zg(e);if(Oh(e))return jg(e)}throw kh(e)}function $g(e){return new tt(function(t){var n=e[Zu]();if(re(n.subscribe))return n.subscribe(t);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function Ag(e){return new tt(function(t){for(var n=0;n<e.length&&!t.closed;n++)t.next(e[n]);t.complete()})}function Ug(e){return new tt(function(t){e.then(function(n){t.closed||(t.next(n),t.complete())},function(n){return t.error(n)}).then(null,sh)})}function zg(e){return new tt(function(t){var n,r;try{for(var i=Ln(e),o=i.next();!o.done;o=i.next()){var a=o.value;if(t.next(a),t.closed)return}}catch(l){n={error:l}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}t.complete()})}function Ph(e){return new tt(function(t){Qg(e,t).catch(function(n){return t.error(n)})})}function jg(e){return Ph(Eh(e))}function Qg(e,t){var n,r,i,o;return mg(this,void 0,void 0,function(){var a,l;return rh(this,function(u){switch(u.label){case 0:u.trys.push([0,5,6,11]),n=gg(e),u.label=1;case 1:return[4,n.next()];case 2:if(r=u.sent(),!!r.done)return[3,4];if(a=r.value,t.next(a),t.closed)return[2];u.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return l=u.sent(),i={error:l},[3,11];case 6:return u.trys.push([6,,9,10]),r&&!r.done&&(o=n.return)?[4,o.call(n)]:[3,8];case 7:u.sent(),u.label=8;case 8:return[3,10];case 9:if(i)throw i.error;return[7];case 10:return[7];case 11:return t.complete(),[2]}})})}function Ot(e,t,n,r,i){r===void 0&&(r=0),i===void 0&&(i=!1);var o=t.schedule(function(){n(),i?e.add(this.schedule(null,r)):this.unsubscribe()},r);if(e.add(o),!i)return o}function Th(e,t){return t===void 0&&(t=0),Sr(function(n,r){n.subscribe(xr(r,function(i){return Ot(r,e,function(){return r.next(i)},t)},function(){return Ot(r,e,function(){return r.complete()},t)},function(i){return Ot(r,e,function(){return r.error(i)},t)}))})}function _h(e,t){return t===void 0&&(t=0),Sr(function(n,r){r.add(e.schedule(function(){return n.subscribe(r)},t))})}function Wg(e,t){return $n(e).pipe(_h(t),Th(t))}function Hg(e,t){return $n(e).pipe(_h(t),Th(t))}function Bg(e,t){return new tt(function(n){var r=0;return t.schedule(function(){r===e.length?n.complete():(n.next(e[r++]),n.closed||this.schedule())})})}function Vg(e,t){return new tt(function(n){var r;return Ot(n,t,function(){r=e[Ch](),Ot(n,t,function(){var i,o,a;try{i=r.next(),o=i.value,a=i.done}catch(l){n.error(l);return}a?n.complete():n.next(o)},0,!0)}),function(){return re(r==null?void 0:r.return)&&r.return()}})}function Rh(e,t){if(!e)throw new Error("Iterable cannot be null");return new tt(function(n){Ot(n,t,function(){var r=e[Symbol.asyncIterator]();Ot(n,t,function(){r.next().then(function(i){i.done?n.complete():n.next(i.value)})},0,!0)})})}function qg(e,t){return Rh(Eh(e),t)}function Yg(e,t){if(e!=null){if(Sh(e))return Wg(e,t);if(Ju(e))return Bg(e,t);if(wh(e))return Hg(e,t);if(xh(e))return Rh(e,t);if(bh(e))return Vg(e,t);if(Oh(e))return qg(e,t)}throw kh(e)}function Kg(e,t){return t?Yg(e,t):$n(e)}function Si(e,t){return Sr(function(n,r){var i=0;n.subscribe(xr(r,function(o){r.next(e.call(t,o,i++))}))})}var Gg=Array.isArray;function Xg(e,t){return Gg(t)?e.apply(void 0,In([],fn(t))):e(t)}function Zg(e){return Si(function(t){return Xg(e,t)})}function Jg(e,t,n,r,i,o,a,l){var u=[],s=0,f=0,p=!1,c=function(){p&&!u.length&&!s&&t.complete()},v=function(g){return s<r?m(g):u.push(g)},m=function(g){o&&t.next(g),s++;var x=!1;$n(n(g,f++)).subscribe(xr(t,function(h){i==null||i(h),o?v(h):t.next(h)},function(){x=!0},void 0,function(){if(x)try{s--;for(var h=function(){var d=u.shift();a?Ot(t,a,function(){return m(d)}):m(d)};u.length&&s<r;)h();c()}catch(d){t.error(d)}}))};return e.subscribe(xr(t,v,function(){p=!0,c()})),function(){l==null||l()}}function es(e,t,n){return n===void 0&&(n=1/0),re(t)?es(function(r,i){return Si(function(o,a){return t(r,o,i,a)})($n(e(r,i)))},n):(typeof t=="number"&&(n=t),Sr(function(r,i){return Jg(r,i,e,n)}))}function e1(e){return e===void 0&&(e=1/0),es(fh,e)}var t1=["addListener","removeListener"],n1=["addEventListener","removeEventListener"],r1=["on","off"];function Jo(e,t,n,r){if(re(n)&&(r=n,n=void 0),r)return Jo(e,t,n).pipe(Zg(r));var i=fn(a1(e)?n1.map(function(l){return function(u){return e[l](t,u,n)}}):i1(e)?t1.map(Dh(e,t)):o1(e)?r1.map(Dh(e,t)):[],2),o=i[0],a=i[1];if(!o&&Ju(e))return es(function(l){return Jo(l,t,n)})($n(e));if(!o)throw new TypeError("Invalid event target");return new tt(function(l){var u=function(){for(var s=[],f=0;f<arguments.length;f++)s[f]=arguments[f];return l.next(1<s.length?s:s[0])};return o(u),function(){return a(u)}})}function Dh(e,t){return function(n){return function(r){return e[n](t,r)}}}function i1(e){return re(e.addListener)&&re(e.removeListener)}function o1(e){return re(e.on)&&re(e.off)}function a1(e){return re(e.addEventListener)&&re(e.removeEventListener)}function l1(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=gh(e),r=Lg(e,1/0),i=e;return i.length?i.length===1?$n(i[0]):e1(r)(Kg(i,n)):Ng}function u1(e,t){return Sr(function(n,r){var i=0;n.subscribe(xr(r,function(o){return e.call(t,o,i++)&&r.next(o)}))})}function s1(e){for(var t,n,r=[],i=1;i<arguments.length;i++)r[i-1]=arguments[i];var o=(t=gh(r))!==null&&t!==void 0?t:Fg,a=(n=r[0])!==null&&n!==void 0?n:null,l=r[1]||1/0;return Sr(function(u,s){var f=[],p=!1,c=function(g){var x=g.buffer,h=g.subs;h.unsubscribe(),wi(f,g),s.next(x),p&&v()},v=function(){if(f){var g=new wr;s.add(g);var x=[],h={buffer:x,subs:g};f.push(h),Ot(g,o,function(){return c(h)},e)}};a!==null&&a>=0?Ot(s,o,v,a,!0):p=!0,v();var m=xr(s,function(g){var x,h,d=f.slice();try{for(var y=Ln(d),w=y.next();!w.done;w=y.next()){var C=w.value,k=C.buffer;k.push(g),l<=k.length&&c(C)}}catch(b){x={error:b}}finally{try{w&&!w.done&&(h=y.return)&&h.call(y)}finally{if(x)throw x.error}}},function(){for(;f!=null&&f.length;)s.next(f.shift().buffer);m==null||m.unsubscribe(),s.complete(),s.unsubscribe()},void 0,function(){return f=null});u.subscribe(m)})}function c1({date:e,startDate:t,endDate:n,onChange:r,onHover:i}){const o=t?qo(e,t):!1;let a=t&&n?e>t&&e<n:!1,l=n?qo(e,n):!1,u=e<new Date;const s="after:a1-absolute after:a1-bg-primary after:a1-top-0 after:a1-bottom-0 after:a1-left-0 after:a1-right-0 after:a1-rounded-full",p=`a1-relative ${n?"before:a1-absolute before:a1-left-1/2 before:a1-right-0 before:a1-top-0 before:a1-bottom-0 before:a1-bg-secondary":""} ${s}`,c="a1-rounded-none",m=`a1-relative ${s} before:a1-absolute before:a1-left-0 before:a1-right-1/2 before:a1-top-0 before:a1-bottom-0 before:a1-bg-secondary`;return F("div",{className:`a1-w-10 a1-h-10 a1-flex a1-items-center a1-justify-center a1-cursor-pointer ${o||l?"a1-text-white":a?"a1-bg-secondary":"a1-text-gray-700"} ${o?p:a?c:l?m:""} ${u?"a1-opacity-50 a1-cursor-not-allowed":"a1-relative hover:after:a1-z-10 hover:after:a1-left-0 hover:after:a1-right-0 hover:after:a1-absolute hover:after:a1-w-full hover:after:a1-h-full hover:after:a1-rounded-full hover:after:a1-ring-2 hover:before:a1-ring-primary"}`,onClick:()=>{u||r(new Date(e))},onMouseOver:()=>{u||i(new Date(e))},children:F("span",{className:"a1-relative a1-z-20",children:e.getDate()})})}function f1({initialDate:e,startDate:t,endDate:n,onChange:r,onReset:i}){const[o,a]=S.useState(ty(e)),l=cg(o,"MMMM yyyy"),u=X0(o),[s,f]=S.useState(null),[p,c]=S.useState(null);S.useEffect(()=>{c(t&&!n?s:n)},[s,t,n]);const v=["S","M","T","W","T","F","S"],m=new Array(6*7).fill(0).map((g,x)=>Vo(u,x));return $e("div",{className:"a1-w-max",children:[$e("div",{className:"a1-px-4 a1-py-2 a1-flex a1-gap-4",children:[F("button",{type:"button",onClick:()=>i(),className:"a1-text-primary a1-tracking-wide a1-uppercase a1-text-xs a1-bold",children:"Reset"}),$e("div",{className:"a1-flex a1-flex-grow a1-justify-between a1-items-center a1-text-gray-700",children:[F("button",{type:"button",className:"a1-w-8 a1-h-8 a1-bg-white a1-rounded-full a1-flex a1-items-center a1-justify-center a1-text-gray-700 a1-p-0",onClick:()=>a(vg(o,{months:1})),children:F("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"a1-w-6 a1-h-6",children:F("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15.75 19.5L8.25 12l7.5-7.5"})})}),F("div",{className:"mx-2",children:l}),F("button",{type:"button",className:"a1-w-8 a1-h-8 a1-bg-white a1-rounded-full a1-flex a1-items-center a1-justify-center a1-text-gray-700 a1-p-0",onClick:()=>a(Y0(o,{months:1})),children:F("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"a1-w-6 a1-h-6",children:F("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8.25 4.5l7.5 7.5-7.5 7.5"})})})]})]}),F("div",{className:"a1-grid a1-grid-cols-7",children:v.map((g,x)=>F("div",{className:"a1-w-10 a1-h-10 a1-rounded-full a1-flex a1-items-center a1-justify-center",children:g},`${g}-${x}`))}),F("div",{className:"a1-grid a1-grid-cols-7 a1-grid-rows-6",children:m.map(g=>F(c1,{date:g,startDate:t,endDate:p,onChange:r,onHover:()=>f(g)},g.toISOString()))})]})}function d1({onChange:e,className:t,primaryColor:n,secondaryColor:r,startDateLabel:i="Start Date",endDateLabel:o="End Date"}){const[a,l]=S.useState(null),[u,s]=S.useState(null),[f,p]=S.useState(!1),[c,v]=S.useState(new Date),m=S.useRef(null),[g,x]=S.useState(new hh),h=O=>{a?u?qo(O,a)&&qo(O,u)?(l(O),s(null)):dg(O,Vo(a,3))?l(O):s(O):s(O):l(O)},d=()=>{l(null),s(null)};S.useEffect(()=>{let O=null;if(m!=null&&m.current){const _=Jo(document,"click"),T=Jo(m.current,"click");O=l1(_.pipe(Si(()=>!1)),g.pipe(Si(()=>!0)),T.pipe(Si(()=>!0))).pipe(s1(50),u1(R=>R.length>0)).subscribe(R=>{let $=R.some(z=>z===!0);p($)})}return()=>{O==null||O.unsubscribe()}},[m]),S.useEffect(()=>{e(a,u)},[a,u]);const y="a1-bg-white a1-border a1-border-gray-300 a1-rounded-lg a1-shadow-md",w="a1-absolute a1-left-2 a1-right-2 a1-top-1/2 md:a1-top-2 md:a1-bottom-2 md:a1-left-1/2 a1-rounded-lg a1-h-[2px] md:a1-h-[initial] md:a1-w-[2px] a1-bg-gray-200",k=`a1-relative a1-h-full a1-flex a1-flex-col md:a1-flex-row md:a1-items-center a1-gap-4 a1-p-3 a1-rounded-lg a1-bg-white ${f?"a1-ring-2 a1-ring-primary":"a1-ring-2 a1-ring-gray-200"}`;let b={};return n&&(b["--color-primary"]=n),r&&(b["--color-secondary"]=r),F("div",{id:"A1-DateRangePicker",className:t,style:b,children:$e("div",{ref:m,className:k,children:[$e("div",{className:"a1-flex a1-grow a1-gap-2",children:[F("span",{children:F("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"a1-w-6 a1-h-6",children:F("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6.75 3v2.25M17.25 3v2.25M3 18.75V7.5a2.25 2.25 0 012.25-2.25h13.5A2.25 2.25 0 0121 7.5v11.25m-18 0A2.25 2.25 0 005.25 21h13.5A2.25 2.25 0 0021 18.75m-18 0v-7.5A2.25 2.25 0 015.25 9h13.5A2.25 2.25 0 0121 11.25v7.5m-9-6h.008v.008H12v-.008zM12 15h.008v.008H12V15zm0 2.25h.008v.008H12v-.008zM9.75 15h.008v.008H9.75V15zm0 2.25h.008v.008H9.75v-.008zM7.5 15h.008v.008H7.5V15zm0 2.25h.008v.008H7.5v-.008zm6.75-4.5h.008v.008h-.008v-.008zm0 2.25h.008v.008h-.008V15zm0 2.25h.008v.008h-.008v-.008zm2.25-4.5h.008v.008H16.5v-.008zm0 2.25h.008v.008H16.5V15z"})})}),F("input",{type:"text",name:"start-date",defaultValue:(a==null?void 0:a.toLocaleDateString())||"",placeholder:i,autoComplete:"off",className:"a1-all-initial focus:a1-outline-none"})]}),F("div",{className:w}),F("div",{className:"a1-grow",children:F("input",{type:"text",name:"end-date",defaultValue:(u==null?void 0:u.toLocaleDateString())||"",placeholder:o,autoComplete:"off",className:"focus:a1-outline-none"})}),F(Vd,{show:f,className:"a1-absolute a1-z-10 a1-top-full a1-left-1/2 a1--translate-x-1/2",enter:"a1-transition a1-duration-100 a1-ease-out",enterFrom:"a1-transform a1-scale-95 a1-opacity-0",enterTo:"a1-transform a1-scale-100 a1-opacity-100",leave:"a1-transition a1-duration-75 a1-ease-out",leaveFrom:"a1-transform a1-scale-100 a1-opacity-100",leaveTo:"a1-transform a1-scale-95 a1-opacity-0",children:F("div",{id:"Calendar",className:`a1-mt-2 ${y}`,onClick:O=>g.next(!0),children:F(f1,{initialDate:c,startDate:a,endDate:u,onChange:h,onReset:d},c.toISOString())})})]})})}var Fh={exports:{}},h1="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",p1=h1,v1=p1;function Nh(){}function Mh(){}Mh.resetWarningCache=Nh;var m1=function(){function e(r,i,o,a,l,u){if(u!==v1){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:Mh,resetWarningCache:Nh};return n.PropTypes=n,n};Fh.exports=m1();var y1=Fh.exports;const Qe=ve(y1);function xi(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Bu(e,t)}var ki=function(){function e(){this.listeners=[]}var t=e.prototype;return t.subscribe=function(r){var i=this,o=r||function(){};return this.listeners.push(o),this.onSubscribe(),function(){i.listeners=i.listeners.filter(function(a){return a!==o}),i.onUnsubscribe()}},t.hasListeners=function(){return this.listeners.length>0},t.onSubscribe=function(){},t.onUnsubscribe=function(){},e}();function K(){return K=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},K.apply(this,arguments)}var ea=typeof window=="undefined";function Le(){}function g1(e,t){return typeof e=="function"?e(t):e}function ts(e){return typeof e=="number"&&e>=0&&e!==1/0}function ta(e){return Array.isArray(e)?e:[e]}function Lh(e,t){return Math.max(e+(t||0)-Date.now(),0)}function na(e,t,n){return oa(e)?typeof t=="function"?K({},n,{queryKey:e,queryFn:t}):K({},t,{queryKey:e}):e}function dn(e,t,n){return oa(e)?[K({},t,{queryKey:e}),n]:[e||{},t]}function w1(e,t){if(e===!0&&t===!0||e==null&&t==null)return"all";if(e===!1&&t===!1)return"none";var n=e!=null?e:!t;return n?"active":"inactive"}function Ih(e,t){var n=e.active,r=e.exact,i=e.fetching,o=e.inactive,a=e.predicate,l=e.queryKey,u=e.stale;if(oa(l)){if(r){if(t.queryHash!==ns(l,t.options))return!1}else if(!ra(t.queryKey,l))return!1}var s=w1(n,o);if(s==="none")return!1;if(s!=="all"){var f=t.isActive();if(s==="active"&&!f||s==="inactive"&&f)return!1}return!(typeof u=="boolean"&&t.isStale()!==u||typeof i=="boolean"&&t.isFetching()!==i||a&&!a(t))}function $h(e,t){var n=e.exact,r=e.fetching,i=e.predicate,o=e.mutationKey;if(oa(o)){if(!t.options.mutationKey)return!1;if(n){if(An(t.options.mutationKey)!==An(o))return!1}else if(!ra(t.options.mutationKey,o))return!1}return!(typeof r=="boolean"&&t.state.status==="loading"!==r||i&&!i(t))}function ns(e,t){var n=(t==null?void 0:t.queryKeyHashFn)||An;return n(e)}function An(e){var t=ta(e);return S1(t)}function S1(e){return JSON.stringify(e,function(t,n){return rs(n)?Object.keys(n).sort().reduce(function(r,i){return r[i]=n[i],r},{}):n})}function ra(e,t){return Ah(ta(e),ta(t))}function Ah(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(function(n){return!Ah(e[n],t[n])}):!1}function ia(e,t){if(e===t)return e;var n=Array.isArray(e)&&Array.isArray(t);if(n||rs(e)&&rs(t)){for(var r=n?e.length:Object.keys(e).length,i=n?t:Object.keys(t),o=i.length,a=n?[]:{},l=0,u=0;u<o;u++){var s=n?u:i[u];a[s]=ia(e[s],t[s]),a[s]===e[s]&&l++}return r===o&&l===r?e:a}return t}function x1(e,t){if(e&&!t||t&&!e)return!1;for(var n in e)if(e[n]!==t[n])return!1;return!0}function rs(e){if(!Uh(e))return!1;var t=e.constructor;if(typeof t=="undefined")return!0;var n=t.prototype;return!(!Uh(n)||!n.hasOwnProperty("isPrototypeOf"))}function Uh(e){return Object.prototype.toString.call(e)==="[object Object]"}function oa(e){return typeof e=="string"||Array.isArray(e)}function k1(e){return new Promise(function(t){setTimeout(t,e)})}function zh(e){Promise.resolve().then(e).catch(function(t){return setTimeout(function(){throw t})})}function jh(){if(typeof AbortController=="function")return new AbortController}var C1=function(e){xi(t,e);function t(){var r;return r=e.call(this)||this,r.setup=function(i){var o;if(!ea&&((o=window)!=null&&o.addEventListener)){var a=function(){return i()};return window.addEventListener("visibilitychange",a,!1),window.addEventListener("focus",a,!1),function(){window.removeEventListener("visibilitychange",a),window.removeEventListener("focus",a)}}},r}var n=t.prototype;return n.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},n.onUnsubscribe=function(){if(!this.hasListeners()){var i;(i=this.cleanup)==null||i.call(this),this.cleanup=void 0}},n.setEventListener=function(i){var o,a=this;this.setup=i,(o=this.cleanup)==null||o.call(this),this.cleanup=i(function(l){typeof l=="boolean"?a.setFocused(l):a.onFocus()})},n.setFocused=function(i){this.focused=i,i&&this.onFocus()},n.onFocus=function(){this.listeners.forEach(function(i){i()})},n.isFocused=function(){return typeof this.focused=="boolean"?this.focused:typeof document=="undefined"?!0:[void 0,"visible","prerender"].includes(document.visibilityState)},t}(ki),Ci=new C1,b1=function(e){xi(t,e);function t(){var r;return r=e.call(this)||this,r.setup=function(i){var o;if(!ea&&((o=window)!=null&&o.addEventListener)){var a=function(){return i()};return window.addEventListener("online",a,!1),window.addEventListener("offline",a,!1),function(){window.removeEventListener("online",a),window.removeEventListener("offline",a)}}},r}var n=t.prototype;return n.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},n.onUnsubscribe=function(){if(!this.hasListeners()){var i;(i=this.cleanup)==null||i.call(this),this.cleanup=void 0}},n.setEventListener=function(i){var o,a=this;this.setup=i,(o=this.cleanup)==null||o.call(this),this.cleanup=i(function(l){typeof l=="boolean"?a.setOnline(l):a.onOnline()})},n.setOnline=function(i){this.online=i,i&&this.onOnline()},n.onOnline=function(){this.listeners.forEach(function(i){i()})},n.isOnline=function(){return typeof this.online=="boolean"?this.online:typeof navigator=="undefined"||typeof navigator.onLine=="undefined"?!0:navigator.onLine},t}(ki),aa=new b1;function E1(e){return Math.min(1e3*Math.pow(2,e),3e4)}function la(e){return typeof(e==null?void 0:e.cancel)=="function"}var Qh=function(t){this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent};function ua(e){return e instanceof Qh}var Wh=function(t){var n=this,r=!1,i,o,a,l;this.abort=t.abort,this.cancel=function(c){return i==null?void 0:i(c)},this.cancelRetry=function(){r=!0},this.continueRetry=function(){r=!1},this.continue=function(){return o==null?void 0:o()},this.failureCount=0,this.isPaused=!1,this.isResolved=!1,this.isTransportCancelable=!1,this.promise=new Promise(function(c,v){a=c,l=v});var u=function(v){n.isResolved||(n.isResolved=!0,t.onSuccess==null||t.onSuccess(v),o==null||o(),a(v))},s=function(v){n.isResolved||(n.isResolved=!0,t.onError==null||t.onError(v),o==null||o(),l(v))},f=function(){return new Promise(function(v){o=v,n.isPaused=!0,t.onPause==null||t.onPause()}).then(function(){o=void 0,n.isPaused=!1,t.onContinue==null||t.onContinue()})},p=function c(){if(!n.isResolved){var v;try{v=t.fn()}catch(m){v=Promise.reject(m)}i=function(g){if(!n.isResolved&&(s(new Qh(g)),n.abort==null||n.abort(),la(v)))try{v.cancel()}catch(x){}},n.isTransportCancelable=la(v),Promise.resolve(v).then(u).catch(function(m){var g,x;if(!n.isResolved){var h=(g=t.retry)!=null?g:3,d=(x=t.retryDelay)!=null?x:E1,y=typeof d=="function"?d(n.failureCount,m):d,w=h===!0||typeof h=="number"&&n.failureCount<h||typeof h=="function"&&h(n.failureCount,m);if(r||!w){s(m);return}n.failureCount++,t.onFail==null||t.onFail(n.failureCount,m),k1(y).then(function(){if(!Ci.isFocused()||!aa.isOnline())return f()}).then(function(){r?s(m):c()})}})}};p()},O1=function(){function e(){this.queue=[],this.transactions=0,this.notifyFn=function(n){n()},this.batchNotifyFn=function(n){n()}}var t=e.prototype;return t.batch=function(r){var i;this.transactions++;try{i=r()}finally{this.transactions--,this.transactions||this.flush()}return i},t.schedule=function(r){var i=this;this.transactions?this.queue.push(r):zh(function(){i.notifyFn(r)})},t.batchCalls=function(r){var i=this;return function(){for(var o=arguments.length,a=new Array(o),l=0;l<o;l++)a[l]=arguments[l];i.schedule(function(){r.apply(void 0,a)})}},t.flush=function(){var r=this,i=this.queue;this.queue=[],i.length&&zh(function(){r.batchNotifyFn(function(){i.forEach(function(o){r.notifyFn(o)})})})},t.setNotifyFunction=function(r){this.notifyFn=r},t.setBatchNotifyFunction=function(r){this.batchNotifyFn=r},e}(),he=new O1,Hh=console;function sa(){return Hh}function P1(e){Hh=e}var T1=function(){function e(n){this.abortSignalConsumed=!1,this.hadObservers=!1,this.defaultOptions=n.defaultOptions,this.setOptions(n.options),this.observers=[],this.cache=n.cache,this.queryKey=n.queryKey,this.queryHash=n.queryHash,this.initialState=n.state||this.getDefaultState(this.options),this.state=this.initialState,this.meta=n.meta,this.scheduleGc()}var t=e.prototype;return t.setOptions=function(r){var i;this.options=K({},this.defaultOptions,r),this.meta=r==null?void 0:r.meta,this.cacheTime=Math.max(this.cacheTime||0,(i=this.options.cacheTime)!=null?i:5*60*1e3)},t.setDefaultOptions=function(r){this.defaultOptions=r},t.scheduleGc=function(){var r=this;this.clearGcTimeout(),ts(this.cacheTime)&&(this.gcTimeout=setTimeout(function(){r.optionalRemove()},this.cacheTime))},t.clearGcTimeout=function(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)},t.optionalRemove=function(){this.observers.length||(this.state.isFetching?this.hadObservers&&this.scheduleGc():this.cache.remove(this))},t.setData=function(r,i){var o,a,l=this.state.data,u=g1(r,l);return(o=(a=this.options).isDataEqual)!=null&&o.call(a,l,u)?u=l:this.options.structuralSharing!==!1&&(u=ia(l,u)),this.dispatch({data:u,type:"success",dataUpdatedAt:i==null?void 0:i.updatedAt}),u},t.setState=function(r,i){this.dispatch({type:"setState",state:r,setStateOptions:i})},t.cancel=function(r){var i,o=this.promise;return(i=this.retryer)==null||i.cancel(r),o?o.then(Le).catch(Le):Promise.resolve()},t.destroy=function(){this.clearGcTimeout(),this.cancel({silent:!0})},t.reset=function(){this.destroy(),this.setState(this.initialState)},t.isActive=function(){return this.observers.some(function(r){return r.options.enabled!==!1})},t.isFetching=function(){return this.state.isFetching},t.isStale=function(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(function(r){return r.getCurrentResult().isStale})},t.isStaleByTime=function(r){return r===void 0&&(r=0),this.state.isInvalidated||!this.state.dataUpdatedAt||!Lh(this.state.dataUpdatedAt,r)},t.onFocus=function(){var r,i=this.observers.find(function(o){return o.shouldFetchOnWindowFocus()});i&&i.refetch(),(r=this.retryer)==null||r.continue()},t.onOnline=function(){var r,i=this.observers.find(function(o){return o.shouldFetchOnReconnect()});i&&i.refetch(),(r=this.retryer)==null||r.continue()},t.addObserver=function(r){this.observers.indexOf(r)===-1&&(this.observers.push(r),this.hadObservers=!0,this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:r}))},t.removeObserver=function(r){this.observers.indexOf(r)!==-1&&(this.observers=this.observers.filter(function(i){return i!==r}),this.observers.length||(this.retryer&&(this.retryer.isTransportCancelable||this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.cacheTime?this.scheduleGc():this.cache.remove(this)),this.cache.notify({type:"observerRemoved",query:this,observer:r}))},t.getObserversCount=function(){return this.observers.length},t.invalidate=function(){this.state.isInvalidated||this.dispatch({type:"invalidate"})},t.fetch=function(r,i){var o=this,a,l,u;if(this.state.isFetching){if(this.state.dataUpdatedAt&&(i!=null&&i.cancelRefetch))this.cancel({silent:!0});else if(this.promise){var s;return(s=this.retryer)==null||s.continueRetry(),this.promise}}if(r&&this.setOptions(r),!this.options.queryFn){var f=this.observers.find(function(d){return d.options.queryFn});f&&this.setOptions(f.options)}var p=ta(this.queryKey),c=jh(),v={queryKey:p,pageParam:void 0,meta:this.meta};Object.defineProperty(v,"signal",{enumerable:!0,get:function(){if(c)return o.abortSignalConsumed=!0,c.signal}});var m=function(){return o.options.queryFn?(o.abortSignalConsumed=!1,o.options.queryFn(v)):Promise.reject("Missing queryFn")},g={fetchOptions:i,options:this.options,queryKey:p,state:this.state,fetchFn:m,meta:this.meta};if((a=this.options.behavior)!=null&&a.onFetch){var x;(x=this.options.behavior)==null||x.onFetch(g)}if(this.revertState=this.state,!this.state.isFetching||this.state.fetchMeta!==((l=g.fetchOptions)==null?void 0:l.meta)){var h;this.dispatch({type:"fetch",meta:(h=g.fetchOptions)==null?void 0:h.meta})}return this.retryer=new Wh({fn:g.fetchFn,abort:c==null||(u=c.abort)==null?void 0:u.bind(c),onSuccess:function(y){o.setData(y),o.cache.config.onSuccess==null||o.cache.config.onSuccess(y,o),o.cacheTime===0&&o.optionalRemove()},onError:function(y){ua(y)&&y.silent||o.dispatch({type:"error",error:y}),ua(y)||(o.cache.config.onError==null||o.cache.config.onError(y,o),sa().error(y)),o.cacheTime===0&&o.optionalRemove()},onFail:function(){o.dispatch({type:"failed"})},onPause:function(){o.dispatch({type:"pause"})},onContinue:function(){o.dispatch({type:"continue"})},retry:g.options.retry,retryDelay:g.options.retryDelay}),this.promise=this.retryer.promise,this.promise},t.dispatch=function(r){var i=this;this.state=this.reducer(this.state,r),he.batch(function(){i.observers.forEach(function(o){o.onQueryUpdate(r)}),i.cache.notify({query:i,type:"queryUpdated",action:r})})},t.getDefaultState=function(r){var i=typeof r.initialData=="function"?r.initialData():r.initialData,o=typeof r.initialData!="undefined",a=o?typeof r.initialDataUpdatedAt=="function"?r.initialDataUpdatedAt():r.initialDataUpdatedAt:0,l=typeof i!="undefined";return{data:i,dataUpdateCount:0,dataUpdatedAt:l?a!=null?a:Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchMeta:null,isFetching:!1,isInvalidated:!1,isPaused:!1,status:l?"success":"idle"}},t.reducer=function(r,i){var o,a;switch(i.type){case"failed":return K({},r,{fetchFailureCount:r.fetchFailureCount+1});case"pause":return K({},r,{isPaused:!0});case"continue":return K({},r,{isPaused:!1});case"fetch":return K({},r,{fetchFailureCount:0,fetchMeta:(o=i.meta)!=null?o:null,isFetching:!0,isPaused:!1},!r.dataUpdatedAt&&{error:null,status:"loading"});case"success":return K({},r,{data:i.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:(a=i.dataUpdatedAt)!=null?a:Date.now(),error:null,fetchFailureCount:0,isFetching:!1,isInvalidated:!1,isPaused:!1,status:"success"});case"error":var l=i.error;return ua(l)&&l.revert&&this.revertState?K({},this.revertState):K({},r,{error:l,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,isFetching:!1,isPaused:!1,status:"error"});case"invalidate":return K({},r,{isInvalidated:!0});case"setState":return K({},r,i.state);default:return r}},e}(),_1=function(e){xi(t,e);function t(r){var i;return i=e.call(this)||this,i.config=r||{},i.queries=[],i.queriesMap={},i}var n=t.prototype;return n.build=function(i,o,a){var l,u=o.queryKey,s=(l=o.queryHash)!=null?l:ns(u,o),f=this.get(s);return f||(f=new T1({cache:this,queryKey:u,queryHash:s,options:i.defaultQueryOptions(o),state:a,defaultOptions:i.getQueryDefaults(u),meta:o.meta}),this.add(f)),f},n.add=function(i){this.queriesMap[i.queryHash]||(this.queriesMap[i.queryHash]=i,this.queries.push(i),this.notify({type:"queryAdded",query:i}))},n.remove=function(i){var o=this.queriesMap[i.queryHash];o&&(i.destroy(),this.queries=this.queries.filter(function(a){return a!==i}),o===i&&delete this.queriesMap[i.queryHash],this.notify({type:"queryRemoved",query:i}))},n.clear=function(){var i=this;he.batch(function(){i.queries.forEach(function(o){i.remove(o)})})},n.get=function(i){return this.queriesMap[i]},n.getAll=function(){return this.queries},n.find=function(i,o){var a=dn(i,o),l=a[0];return typeof l.exact=="undefined"&&(l.exact=!0),this.queries.find(function(u){return Ih(l,u)})},n.findAll=function(i,o){var a=dn(i,o),l=a[0];return Object.keys(l).length>0?this.queries.filter(function(u){return Ih(l,u)}):this.queries},n.notify=function(i){var o=this;he.batch(function(){o.listeners.forEach(function(a){a(i)})})},n.onFocus=function(){var i=this;he.batch(function(){i.queries.forEach(function(o){o.onFocus()})})},n.onOnline=function(){var i=this;he.batch(function(){i.queries.forEach(function(o){o.onOnline()})})},t}(ki),R1=function(){function e(n){this.options=K({},n.defaultOptions,n.options),this.mutationId=n.mutationId,this.mutationCache=n.mutationCache,this.observers=[],this.state=n.state||D1(),this.meta=n.meta}var t=e.prototype;return t.setState=function(r){this.dispatch({type:"setState",state:r})},t.addObserver=function(r){this.observers.indexOf(r)===-1&&this.observers.push(r)},t.removeObserver=function(r){this.observers=this.observers.filter(function(i){return i!==r})},t.cancel=function(){return this.retryer?(this.retryer.cancel(),this.retryer.promise.then(Le).catch(Le)):Promise.resolve()},t.continue=function(){return this.retryer?(this.retryer.continue(),this.retryer.promise):this.execute()},t.execute=function(){var r=this,i,o=this.state.status==="loading",a=Promise.resolve();return o||(this.dispatch({type:"loading",variables:this.options.variables}),a=a.then(function(){r.mutationCache.config.onMutate==null||r.mutationCache.config.onMutate(r.state.variables,r)}).then(function(){return r.options.onMutate==null?void 0:r.options.onMutate(r.state.variables)}).then(function(l){l!==r.state.context&&r.dispatch({type:"loading",context:l,variables:r.state.variables})})),a.then(function(){return r.executeMutation()}).then(function(l){i=l,r.mutationCache.config.onSuccess==null||r.mutationCache.config.onSuccess(i,r.state.variables,r.state.context,r)}).then(function(){return r.options.onSuccess==null?void 0:r.options.onSuccess(i,r.state.variables,r.state.context)}).then(function(){return r.options.onSettled==null?void 0:r.options.onSettled(i,null,r.state.variables,r.state.context)}).then(function(){return r.dispatch({type:"success",data:i}),i}).catch(function(l){return r.mutationCache.config.onError==null||r.mutationCache.config.onError(l,r.state.variables,r.state.context,r),sa().error(l),Promise.resolve().then(function(){return r.options.onError==null?void 0:r.options.onError(l,r.state.variables,r.state.context)}).then(function(){return r.options.onSettled==null?void 0:r.options.onSettled(void 0,l,r.state.variables,r.state.context)}).then(function(){throw r.dispatch({type:"error",error:l}),l})})},t.executeMutation=function(){var r=this,i;return this.retryer=new Wh({fn:function(){return r.options.mutationFn?r.options.mutationFn(r.state.variables):Promise.reject("No mutationFn found")},onFail:function(){r.dispatch({type:"failed"})},onPause:function(){r.dispatch({type:"pause"})},onContinue:function(){r.dispatch({type:"continue"})},retry:(i=this.options.retry)!=null?i:0,retryDelay:this.options.retryDelay}),this.retryer.promise},t.dispatch=function(r){var i=this;this.state=F1(this.state,r),he.batch(function(){i.observers.forEach(function(o){o.onMutationUpdate(r)}),i.mutationCache.notify(i)})},e}();function D1(){return{context:void 0,data:void 0,error:null,failureCount:0,isPaused:!1,status:"idle",variables:void 0}}function F1(e,t){switch(t.type){case"failed":return K({},e,{failureCount:e.failureCount+1});case"pause":return K({},e,{isPaused:!0});case"continue":return K({},e,{isPaused:!1});case"loading":return K({},e,{context:t.context,data:void 0,error:null,isPaused:!1,status:"loading",variables:t.variables});case"success":return K({},e,{data:t.data,error:null,status:"success",isPaused:!1});case"error":return K({},e,{data:void 0,error:t.error,failureCount:e.failureCount+1,isPaused:!1,status:"error"});case"setState":return K({},e,t.state);default:return e}}var N1=function(e){xi(t,e);function t(r){var i;return i=e.call(this)||this,i.config=r||{},i.mutations=[],i.mutationId=0,i}var n=t.prototype;return n.build=function(i,o,a){var l=new R1({mutationCache:this,mutationId:++this.mutationId,options:i.defaultMutationOptions(o),state:a,defaultOptions:o.mutationKey?i.getMutationDefaults(o.mutationKey):void 0,meta:o.meta});return this.add(l),l},n.add=function(i){this.mutations.push(i),this.notify(i)},n.remove=function(i){this.mutations=this.mutations.filter(function(o){return o!==i}),i.cancel(),this.notify(i)},n.clear=function(){var i=this;he.batch(function(){i.mutations.forEach(function(o){i.remove(o)})})},n.getAll=function(){return this.mutations},n.find=function(i){return typeof i.exact=="undefined"&&(i.exact=!0),this.mutations.find(function(o){return $h(i,o)})},n.findAll=function(i){return this.mutations.filter(function(o){return $h(i,o)})},n.notify=function(i){var o=this;he.batch(function(){o.listeners.forEach(function(a){a(i)})})},n.onFocus=function(){this.resumePausedMutations()},n.onOnline=function(){this.resumePausedMutations()},n.resumePausedMutations=function(){var i=this.mutations.filter(function(o){return o.state.isPaused});return he.batch(function(){return i.reduce(function(o,a){return o.then(function(){return a.continue().catch(Le)})},Promise.resolve())})},t}(ki);function M1(){return{onFetch:function(t){t.fetchFn=function(){var n,r,i,o,a,l,u=(n=t.fetchOptions)==null||(r=n.meta)==null?void 0:r.refetchPage,s=(i=t.fetchOptions)==null||(o=i.meta)==null?void 0:o.fetchMore,f=s==null?void 0:s.pageParam,p=(s==null?void 0:s.direction)==="forward",c=(s==null?void 0:s.direction)==="backward",v=((a=t.state.data)==null?void 0:a.pages)||[],m=((l=t.state.data)==null?void 0:l.pageParams)||[],g=jh(),x=g==null?void 0:g.signal,h=m,d=!1,y=t.options.queryFn||function(){return Promise.reject("Missing queryFn")},w=function(z,U,j,J){return h=J?[U].concat(h):[].concat(h,[U]),J?[j].concat(z):[].concat(z,[j])},C=function(z,U,j,J){if(d)return Promise.reject("Cancelled");if(typeof j=="undefined"&&!U&&z.length)return Promise.resolve(z);var P={queryKey:t.queryKey,signal:x,pageParam:j,meta:t.meta},N=y(P),M=Promise.resolve(N).then(function(Q){return w(z,j,Q,J)});if(la(N)){var q=M;q.cancel=N.cancel}return M},k;if(!v.length)k=C([]);else if(p){var b=typeof f!="undefined",O=b?f:Bh(t.options,v);k=C(v,b,O)}else if(c){var _=typeof f!="undefined",T=_?f:L1(t.options,v);k=C(v,_,T,!0)}else(function(){h=[];var $=typeof t.options.getNextPageParam=="undefined",z=u&&v[0]?u(v[0],0,v):!0;k=z?C([],$,m[0]):Promise.resolve(w([],m[0],v[0]));for(var U=function(P){k=k.then(function(N){var M=u&&v[P]?u(v[P],P,v):!0;if(M){var q=$?m[P]:Bh(t.options,N);return C(N,$,q)}return Promise.resolve(w(N,m[P],v[P]))})},j=1;j<v.length;j++)U(j)})();var L=k.then(function($){return{pages:$,pageParams:h}}),R=L;return R.cancel=function(){d=!0,g==null||g.abort(),la(k)&&k.cancel()},L}}}}function Bh(e,t){return e.getNextPageParam==null?void 0:e.getNextPageParam(t[t.length-1],t)}function L1(e,t){return e.getPreviousPageParam==null?void 0:e.getPreviousPageParam(t[0],t)}var Vh=function(){function e(n){n===void 0&&(n={}),this.queryCache=n.queryCache||new _1,this.mutationCache=n.mutationCache||new N1,this.defaultOptions=n.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[]}var t=e.prototype;return t.mount=function(){var r=this;this.unsubscribeFocus=Ci.subscribe(function(){Ci.isFocused()&&aa.isOnline()&&(r.mutationCache.onFocus(),r.queryCache.onFocus())}),this.unsubscribeOnline=aa.subscribe(function(){Ci.isFocused()&&aa.isOnline()&&(r.mutationCache.onOnline(),r.queryCache.onOnline())})},t.unmount=function(){var r,i;(r=this.unsubscribeFocus)==null||r.call(this),(i=this.unsubscribeOnline)==null||i.call(this)},t.isFetching=function(r,i){var o=dn(r,i),a=o[0];return a.fetching=!0,this.queryCache.findAll(a).length},t.isMutating=function(r){return this.mutationCache.findAll(K({},r,{fetching:!0})).length},t.getQueryData=function(r,i){var o;return(o=this.queryCache.find(r,i))==null?void 0:o.state.data},t.getQueriesData=function(r){return this.getQueryCache().findAll(r).map(function(i){var o=i.queryKey,a=i.state,l=a.data;return[o,l]})},t.setQueryData=function(r,i,o){var a=na(r),l=this.defaultQueryOptions(a);return this.queryCache.build(this,l).setData(i,o)},t.setQueriesData=function(r,i,o){var a=this;return he.batch(function(){return a.getQueryCache().findAll(r).map(function(l){var u=l.queryKey;return[u,a.setQueryData(u,i,o)]})})},t.getQueryState=function(r,i){var o;return(o=this.queryCache.find(r,i))==null?void 0:o.state},t.removeQueries=function(r,i){var o=dn(r,i),a=o[0],l=this.queryCache;he.batch(function(){l.findAll(a).forEach(function(u){l.remove(u)})})},t.resetQueries=function(r,i,o){var a=this,l=dn(r,i,o),u=l[0],s=l[1],f=this.queryCache,p=K({},u,{active:!0});return he.batch(function(){return f.findAll(u).forEach(function(c){c.reset()}),a.refetchQueries(p,s)})},t.cancelQueries=function(r,i,o){var a=this,l=dn(r,i,o),u=l[0],s=l[1],f=s===void 0?{}:s;typeof f.revert=="undefined"&&(f.revert=!0);var p=he.batch(function(){return a.queryCache.findAll(u).map(function(c){return c.cancel(f)})});return Promise.all(p).then(Le).catch(Le)},t.invalidateQueries=function(r,i,o){var a,l,u,s=this,f=dn(r,i,o),p=f[0],c=f[1],v=K({},p,{active:(a=(l=p.refetchActive)!=null?l:p.active)!=null?a:!0,inactive:(u=p.refetchInactive)!=null?u:!1});return he.batch(function(){return s.queryCache.findAll(p).forEach(function(m){m.invalidate()}),s.refetchQueries(v,c)})},t.refetchQueries=function(r,i,o){var a=this,l=dn(r,i,o),u=l[0],s=l[1],f=he.batch(function(){return a.queryCache.findAll(u).map(function(c){return c.fetch(void 0,K({},s,{meta:{refetchPage:u==null?void 0:u.refetchPage}}))})}),p=Promise.all(f).then(Le);return s!=null&&s.throwOnError||(p=p.catch(Le)),p},t.fetchQuery=function(r,i,o){var a=na(r,i,o),l=this.defaultQueryOptions(a);typeof l.retry=="undefined"&&(l.retry=!1);var u=this.queryCache.build(this,l);return u.isStaleByTime(l.staleTime)?u.fetch(l):Promise.resolve(u.state.data)},t.prefetchQuery=function(r,i,o){return this.fetchQuery(r,i,o).then(Le).catch(Le)},t.fetchInfiniteQuery=function(r,i,o){var a=na(r,i,o);return a.behavior=M1(),this.fetchQuery(a)},t.prefetchInfiniteQuery=function(r,i,o){return this.fetchInfiniteQuery(r,i,o).then(Le).catch(Le)},t.cancelMutations=function(){var r=this,i=he.batch(function(){return r.mutationCache.getAll().map(function(o){return o.cancel()})});return Promise.all(i).then(Le).catch(Le)},t.resumePausedMutations=function(){return this.getMutationCache().resumePausedMutations()},t.executeMutation=function(r){return this.mutationCache.build(this,r).execute()},t.getQueryCache=function(){return this.queryCache},t.getMutationCache=function(){return this.mutationCache},t.getDefaultOptions=function(){return this.defaultOptions},t.setDefaultOptions=function(r){this.defaultOptions=r},t.setQueryDefaults=function(r,i){var o=this.queryDefaults.find(function(a){return An(r)===An(a.queryKey)});o?o.defaultOptions=i:this.queryDefaults.push({queryKey:r,defaultOptions:i})},t.getQueryDefaults=function(r){var i;return r?(i=this.queryDefaults.find(function(o){return ra(r,o.queryKey)}))==null?void 0:i.defaultOptions:void 0},t.setMutationDefaults=function(r,i){var o=this.mutationDefaults.find(function(a){return An(r)===An(a.mutationKey)});o?o.defaultOptions=i:this.mutationDefaults.push({mutationKey:r,defaultOptions:i})},t.getMutationDefaults=function(r){var i;return r?(i=this.mutationDefaults.find(function(o){return ra(r,o.mutationKey)}))==null?void 0:i.defaultOptions:void 0},t.defaultQueryOptions=function(r){if(r!=null&&r._defaulted)return r;var i=K({},this.defaultOptions.queries,this.getQueryDefaults(r==null?void 0:r.queryKey),r,{_defaulted:!0});return!i.queryHash&&i.queryKey&&(i.queryHash=ns(i.queryKey,i)),i},t.defaultQueryObserverOptions=function(r){return this.defaultQueryOptions(r)},t.defaultMutationOptions=function(r){return r!=null&&r._defaulted?r:K({},this.defaultOptions.mutations,this.getMutationDefaults(r==null?void 0:r.mutationKey),r,{_defaulted:!0})},t.clear=function(){this.queryCache.clear(),this.mutationCache.clear()},e}(),I1=function(e){xi(t,e);function t(r,i){var o;return o=e.call(this)||this,o.client=r,o.options=i,o.trackedProps=[],o.selectError=null,o.bindMethods(),o.setOptions(i),o}var n=t.prototype;return n.bindMethods=function(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)},n.onSubscribe=function(){this.listeners.length===1&&(this.currentQuery.addObserver(this),qh(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())},n.onUnsubscribe=function(){this.listeners.length||this.destroy()},n.shouldFetchOnReconnect=function(){return is(this.currentQuery,this.options,this.options.refetchOnReconnect)},n.shouldFetchOnWindowFocus=function(){return is(this.currentQuery,this.options,this.options.refetchOnWindowFocus)},n.destroy=function(){this.listeners=[],this.clearTimers(),this.currentQuery.removeObserver(this)},n.setOptions=function(i,o){var a=this.options,l=this.currentQuery;if(this.options=this.client.defaultQueryObserverOptions(i),typeof this.options.enabled!="undefined"&&typeof this.options.enabled!="boolean")throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=a.queryKey),this.updateQuery();var u=this.hasListeners();u&&Yh(this.currentQuery,l,this.options,a)&&this.executeFetch(),this.updateResult(o),u&&(this.currentQuery!==l||this.options.enabled!==a.enabled||this.options.staleTime!==a.staleTime)&&this.updateStaleTimeout();var s=this.computeRefetchInterval();u&&(this.currentQuery!==l||this.options.enabled!==a.enabled||s!==this.currentRefetchInterval)&&this.updateRefetchInterval(s)},n.getOptimisticResult=function(i){var o=this.client.defaultQueryObserverOptions(i),a=this.client.getQueryCache().build(this.client,o);return this.createResult(a,o)},n.getCurrentResult=function(){return this.currentResult},n.trackResult=function(i,o){var a=this,l={},u=function(f){a.trackedProps.includes(f)||a.trackedProps.push(f)};return Object.keys(i).forEach(function(s){Object.defineProperty(l,s,{configurable:!1,enumerable:!0,get:function(){return u(s),i[s]}})}),(o.useErrorBoundary||o.suspense)&&u("error"),l},n.getNextResult=function(i){var o=this;return new Promise(function(a,l){var u=o.subscribe(function(s){s.isFetching||(u(),s.isError&&(i!=null&&i.throwOnError)?l(s.error):a(s))})})},n.getCurrentQuery=function(){return this.currentQuery},n.remove=function(){this.client.getQueryCache().remove(this.currentQuery)},n.refetch=function(i){return this.fetch(K({},i,{meta:{refetchPage:i==null?void 0:i.refetchPage}}))},n.fetchOptimistic=function(i){var o=this,a=this.client.defaultQueryObserverOptions(i),l=this.client.getQueryCache().build(this.client,a);return l.fetch().then(function(){return o.createResult(l,a)})},n.fetch=function(i){var o=this;return this.executeFetch(i).then(function(){return o.updateResult(),o.currentResult})},n.executeFetch=function(i){this.updateQuery();var o=this.currentQuery.fetch(this.options,i);return i!=null&&i.throwOnError||(o=o.catch(Le)),o},n.updateStaleTimeout=function(){var i=this;if(this.clearStaleTimeout(),!(ea||this.currentResult.isStale||!ts(this.options.staleTime))){var o=Lh(this.currentResult.dataUpdatedAt,this.options.staleTime),a=o+1;this.staleTimeoutId=setTimeout(function(){i.currentResult.isStale||i.updateResult()},a)}},n.computeRefetchInterval=function(){var i;return typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.currentResult.data,this.currentQuery):(i=this.options.refetchInterval)!=null?i:!1},n.updateRefetchInterval=function(i){var o=this;this.clearRefetchInterval(),this.currentRefetchInterval=i,!(ea||this.options.enabled===!1||!ts(this.currentRefetchInterval)||this.currentRefetchInterval===0)&&(this.refetchIntervalId=setInterval(function(){(o.options.refetchIntervalInBackground||Ci.isFocused())&&o.executeFetch()},this.currentRefetchInterval))},n.updateTimers=function(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())},n.clearTimers=function(){this.clearStaleTimeout(),this.clearRefetchInterval()},n.clearStaleTimeout=function(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)},n.clearRefetchInterval=function(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)},n.createResult=function(i,o){var a=this.currentQuery,l=this.options,u=this.currentResult,s=this.currentResultState,f=this.currentResultOptions,p=i!==a,c=p?i.state:this.currentQueryInitialState,v=p?this.currentResult:this.previousQueryResult,m=i.state,g=m.dataUpdatedAt,x=m.error,h=m.errorUpdatedAt,d=m.isFetching,y=m.status,w=!1,C=!1,k;if(o.optimisticResults){var b=this.hasListeners(),O=!b&&qh(i,o),_=b&&Yh(i,a,o,l);(O||_)&&(d=!0,g||(y="loading"))}if(o.keepPreviousData&&!m.dataUpdateCount&&(v!=null&&v.isSuccess)&&y!=="error")k=v.data,g=v.dataUpdatedAt,y=v.status,w=!0;else if(o.select&&typeof m.data!="undefined")if(u&&m.data===(s==null?void 0:s.data)&&o.select===this.selectFn)k=this.selectResult;else try{this.selectFn=o.select,k=o.select(m.data),o.structuralSharing!==!1&&(k=ia(u==null?void 0:u.data,k)),this.selectResult=k,this.selectError=null}catch(R){sa().error(R),this.selectError=R}else k=m.data;if(typeof o.placeholderData!="undefined"&&typeof k=="undefined"&&(y==="loading"||y==="idle")){var T;if(u!=null&&u.isPlaceholderData&&o.placeholderData===(f==null?void 0:f.placeholderData))T=u.data;else if(T=typeof o.placeholderData=="function"?o.placeholderData():o.placeholderData,o.select&&typeof T!="undefined")try{T=o.select(T),o.structuralSharing!==!1&&(T=ia(u==null?void 0:u.data,T)),this.selectError=null}catch(R){sa().error(R),this.selectError=R}typeof T!="undefined"&&(y="success",k=T,C=!0)}this.selectError&&(x=this.selectError,k=this.selectResult,h=Date.now(),y="error");var L={status:y,isLoading:y==="loading",isSuccess:y==="success",isError:y==="error",isIdle:y==="idle",data:k,dataUpdatedAt:g,error:x,errorUpdatedAt:h,failureCount:m.fetchFailureCount,errorUpdateCount:m.errorUpdateCount,isFetched:m.dataUpdateCount>0||m.errorUpdateCount>0,isFetchedAfterMount:m.dataUpdateCount>c.dataUpdateCount||m.errorUpdateCount>c.errorUpdateCount,isFetching:d,isRefetching:d&&y!=="loading",isLoadingError:y==="error"&&m.dataUpdatedAt===0,isPlaceholderData:C,isPreviousData:w,isRefetchError:y==="error"&&m.dataUpdatedAt!==0,isStale:os(i,o),refetch:this.refetch,remove:this.remove};return L},n.shouldNotifyListeners=function(i,o){if(!o)return!0;var a=this.options,l=a.notifyOnChangeProps,u=a.notifyOnChangePropsExclusions;if(!l&&!u||l==="tracked"&&!this.trackedProps.length)return!0;var s=l==="tracked"?this.trackedProps:l;return Object.keys(i).some(function(f){var p=f,c=i[p]!==o[p],v=s==null?void 0:s.some(function(g){return g===f}),m=u==null?void 0:u.some(function(g){return g===f});return c&&!m&&(!s||v)})},n.updateResult=function(i){var o=this.currentResult;if(this.currentResult=this.createResult(this.currentQuery,this.options),this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,!x1(this.currentResult,o)){var a={cache:!0};(i==null?void 0:i.listeners)!==!1&&this.shouldNotifyListeners(this.currentResult,o)&&(a.listeners=!0),this.notify(K({},a,i))}},n.updateQuery=function(){var i=this.client.getQueryCache().build(this.client,this.options);if(i!==this.currentQuery){var o=this.currentQuery;this.currentQuery=i,this.currentQueryInitialState=i.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(o==null||o.removeObserver(this),i.addObserver(this))}},n.onQueryUpdate=function(i){var o={};i.type==="success"?o.onSuccess=!0:i.type==="error"&&!ua(i.error)&&(o.onError=!0),this.updateResult(o),this.hasListeners()&&this.updateTimers()},n.notify=function(i){var o=this;he.batch(function(){i.onSuccess?(o.options.onSuccess==null||o.options.onSuccess(o.currentResult.data),o.options.onSettled==null||o.options.onSettled(o.currentResult.data,null)):i.onError&&(o.options.onError==null||o.options.onError(o.currentResult.error),o.options.onSettled==null||o.options.onSettled(void 0,o.currentResult.error)),i.listeners&&o.listeners.forEach(function(a){a(o.currentResult)}),i.cache&&o.client.getQueryCache().notify({query:o.currentQuery,type:"observerResultsUpdated"})})},t}(ki);function $1(e,t){return t.enabled!==!1&&!e.state.dataUpdatedAt&&!(e.state.status==="error"&&t.retryOnMount===!1)}function qh(e,t){return $1(e,t)||e.state.dataUpdatedAt>0&&is(e,t,t.refetchOnMount)}function is(e,t,n){if(t.enabled!==!1){var r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&os(e,t)}return!1}function Yh(e,t,n,r){return n.enabled!==!1&&(e!==t||r.enabled===!1)&&(!n.suspense||e.state.status!=="error")&&os(e,n)}function os(e,t){return e.isStaleByTime(t.staleTime)}var A1=Dm.unstable_batchedUpdates;he.setBatchNotifyFunction(A1);var U1=console;P1(U1);var Kh=Y.createContext(void 0),Gh=Y.createContext(!1);function Xh(e){return e&&typeof window!="undefined"?(window.ReactQueryClientContext||(window.ReactQueryClientContext=Kh),window.ReactQueryClientContext):Kh}var z1=function(){var t=Y.useContext(Xh(Y.useContext(Gh)));if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Zh=function(t){var n=t.client,r=t.contextSharing,i=r===void 0?!1:r,o=t.children;Y.useEffect(function(){return n.mount(),function(){n.unmount()}},[n]);var a=Xh(i);return Y.createElement(Gh.Provider,{value:i},Y.createElement(a.Provider,{value:n},o))};function j1(){var e=!1;return{clearReset:function(){e=!1},reset:function(){e=!0},isReset:function(){return e}}}var Q1=Y.createContext(j1()),W1=function(){return Y.useContext(Q1)};function H1(e,t,n){return typeof t=="function"?t.apply(void 0,n):typeof t=="boolean"?t:!!e}function B1(e,t){var n=Y.useRef(!1),r=Y.useState(0),i=r[1],o=z1(),a=W1(),l=o.defaultQueryObserverOptions(e);l.optimisticResults=!0,l.onError&&(l.onError=he.batchCalls(l.onError)),l.onSuccess&&(l.onSuccess=he.batchCalls(l.onSuccess)),l.onSettled&&(l.onSettled=he.batchCalls(l.onSettled)),l.suspense&&(typeof l.staleTime!="number"&&(l.staleTime=1e3),l.cacheTime===0&&(l.cacheTime=1)),(l.suspense||l.useErrorBoundary)&&(a.isReset()||(l.retryOnMount=!1));var u=Y.useState(function(){return new t(o,l)}),s=u[0],f=s.getOptimisticResult(l);if(Y.useEffect(function(){n.current=!0,a.clearReset();var p=s.subscribe(he.batchCalls(function(){n.current&&i(function(c){return c+1})}));return s.updateResult(),function(){n.current=!1,p()}},[a,s]),Y.useEffect(function(){s.setOptions(l,{listeners:!1})},[l,s]),l.suspense&&f.isLoading)throw s.fetchOptimistic(l).then(function(p){var c=p.data;l.onSuccess==null||l.onSuccess(c),l.onSettled==null||l.onSettled(c,null)}).catch(function(p){a.clearReset(),l.onError==null||l.onError(p),l.onSettled==null||l.onSettled(void 0,p)});if(f.isError&&!a.isReset()&&!f.isFetching&&H1(l.suspense,l.useErrorBoundary,[f.error,s.getCurrentQuery()]))throw f.error;return l.notifyOnChangeProps==="tracked"&&(f=s.trackResult(f,l)),f}function Jh(e,t,n){var r=na(e,t,n);return B1(r,I1)}const ep={apiDomain:Qe.string.isRequired,origin:Qe.string,destination:Qe.string,airlines:Qe.string,providers:Qe.string,destinations:Qe.string,primaryColor:Qe.string,secondaryColor:Qe.string,locationId:Qe.string,experimentId:Qe.string,clickId:Qe.string,arrivalAirportLabel:Qe.string,departureAirportLabel:Qe.string,departureDateLabel:Qe.string,returnDateLabel:Qe.string},V1=new Vh;function tp(e,t){return up(this,null,function*(){return(yield(yield fetch(`${e}/api/search?q=${t}`)).json()).data})}function np({apiDomain:e,origin:t,destination:n,airlines:r,providers:i,destinations:o,primaryColor:a,secondaryColor:l,locationId:u,experimentId:s,clickId:f,arrivalAirportLabel:p="Arrival Airport",departureAirportLabel:c="Departure Airport",departureDateLabel:v="Departure Date",returnDateLabel:m="Return Date"}){var bi;const[g,x]=S.useState({origin:t||null,destination:n||null,startDate:null,endDate:null});if(u&&u.length>50)throw new Error("locationId must be less than 50 characters");if(s&&s!=="0"&&s!=="1")throw new Error("experimentId must be 0 or 1");if(f&&!/^[a-zA-Z0-9_]{1,50}$/.test(f))throw new Error("clickId must be 1-50 characters and can only use letters, numbers and _");t=t==null?void 0:t.toLocaleUpperCase(),n=n==null?void 0:n.toLocaleUpperCase();const h=r==null?void 0:r.split(",").map(H=>H.toLocaleUpperCase().trim()).filter(H=>H!==""),d=i==null?void 0:i.split(",").map(H=>H.toLocaleUpperCase().trim()).filter(H=>H!==""),y=o==null?void 0:o.split(",").map(H=>H.toLocaleUpperCase().trim()).filter(H=>H!==""),[w,C]=S.useState(!1),[k,b]=S.useState(!!t),[O,_]=S.useState(!!n),{data:T,status:L}=Jh(["airports",g.origin],()=>tp(e,g.origin||"")),{data:R,status:$}=Jh(["airports",g.destination],()=>tp(e,g.destination||"")),z=()=>{const{origin:H,destination:rt,startDate:jt,endDate:wt}=g;C(!!(H&&rt&&jt&&wt))};S.useEffect(()=>{x(ge(G({},g),{origin:t||null,destination:n||null})),b(!!t),_(!!n)},[t,n]),S.useEffect(()=>{z()},[g.origin,g.destination,g.startDate,g.endDate]);const U=H=>{x(ge(G({},g),{origin:H}))},j=H=>{x(ge(G({},g),{destination:H}))},J=(H,rt)=>{x(ge(G({},g),{startDate:H,endDate:rt}))},P=()=>{const{origin:H,destination:rt}=g;b(O),_(k),x(ge(G({},g),{origin:rt,destination:H}))},N=H=>{H.preventDefault();const rt=new FormData(H.currentTarget),jt=Object.fromEntries(rt.entries()),{origin:wt,destination:ip}=jt;let fa=jt["start-date"]||"",da=jt["end-date"]||"";if(!wt||!ip||!fa||!da)throw new Error("All fields must be filled out");fa=new Date(fa).toISOString().split("T")[0],da=new Date(da).toISOString().split("T")[0];let ft=`/fma/${wt}/${wt}-${ip}/${fa}/${da}/v1`;if(u){const Un=!ft.includes("?")?"?":"&";ft+=`${Un}enc_lid=${u}`}if(s){const Un=!ft.includes("?")?"?":"&";ft+=`${Un}enc_eid=${s}`}if(f){const Un=!ft.includes("?")?"?":"&";ft+=`${Un}enc_cid=${f}`}if(h!=null&&h.length||d!=null&&d.length){const Un=!ft.includes("?")?"?":"&";ft+=`${Un}fs=`,h!=null&&h.length&&(ft+=`airlines=${h.join(",")}`,d!=null&&d.length&&(ft+=";")),d!=null&&d.length&&(ft+=`providers=${d.join(",")}`)}const K1=`https://worker.flymyairport.com${ft}`;window.open(K1,"_blank")},M={value:null,filter:(H,rt)=>(H.toLocaleLowerCase(),!!rt.iata_code),getKey:H=>H.iata_code,getValue:H=>H.iata_code},q=ge(G({},M),{items:(T==null?void 0:T.airports)||[],status:L,label:c,name:"origin",onChange:U,value:g.origin,disabled:k,icon:F("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"a1-w-6 a1-h-6",children:F("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 3v2.25m6.364.386l-1.591 1.591M21 12h-2.25m-.386 6.364l-1.591-1.591M12 18.75V21m-4.773-4.227l-1.591 1.591M5.25 12H3m4.227-4.773L5.636 5.636M15.75 12a3.75 3.75 0 11-7.5 0 3.75 3.75 0 017.5 0z"})})}),Q=y!=null&&y.length&&((bi=R==null?void 0:R.airports)!=null&&bi.length)?R.airports.filter(H=>y==null?void 0:y.find(rt=>rt===H.iata_code)):(R==null?void 0:R.airports)||[],hn=ge(G({},M),{items:Q,status:$,label:p,name:"destination",value:g.destination,disabled:O,onChange:j,icon:$e("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"a1-w-6 a1-h-6",children:[F("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 10.5a3 3 0 11-6 0 3 3 0 016 0z"}),F("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19.5 10.5c0 7.142-7.5 11.25-7.5 11.25S4.5 17.642 4.5 10.5a7.5 7.5 0 1115 0z"})]})}),nt="a1-truncate a1-block",I="a1-opacity-80",W="a1-h-full a1-grow-0 a1-rounded-lg a1-flex a1-align-center a1-items-center a1-gap-1 a1-bg-primary a1-text-white a1-px-4 a1-py-2 hover:a1-bg-secondary disabled:a1-bg-gray-400",pe="a1-h-full a1-w-6 a1-flex a1-justify-center a1-items-center a1-text-gray-500 a1-rotate-90 lg:a1-rotate-0",pn={};return a&&a!=""&&a!=null&&(pn["--color-primary"]=a),l&&l!=""&&l!=null&&(pn["--color-secondary"]=l),F(Zh,{client:V1,contextSharing:!0,children:F("div",{style:pn,children:$e("form",{className:"a1-flex a1-flex-col lg:a1-flex-row lg:a1-h-[48px] a1-gap-6",onSubmit:N,children:[$e("div",{className:"a1-flex a1-flex-col lg:a1-flex-row a1-items-center a1-gap-2",children:[F("div",{className:"a1-w-full",children:F(qd,ge(G({},q),{children:(H,rt,jt,wt)=>$e("li",{className:`${jt}`,children:[F("span",{className:nt,children:wt.name}),F("span",{className:I,children:wt.iata_code})]})}))}),F("button",{type:"button",className:pe,onClick:P,children:F("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"a1-w-6 a1-h-6",children:F("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M7.5 21L3 16.5m0 0L7.5 12M3 16.5h13.5m0-13.5L21 7.5m0 0L16.5 12M21 7.5H7.5"})})}),F("div",{className:"a1-w-full",children:F(qd,ge(G({},hn),{children:(H,rt,jt,wt)=>$e("li",{className:`${jt}`,children:[F("span",{className:nt,children:wt.name}),F("span",{className:I,children:wt.iata_code})]})}))})]}),F(d1,{startDateLabel:v,endDateLabel:m,onChange:J}),F("div",{className:"a1-flex a1-items-center a1-justify-center",children:$e("button",{disabled:!w,type:"submit",className:W,children:[F("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"a1-w-6 a1-h-6",children:F("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607z"})}),F("span",{className:"lg:a1-hidden",children:"Search"})]})})]})})})}np.propTypes=ep;const q1=`/*! tailwindcss v3.3.2 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-variation-settings:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}flight-search-form{--color-primary:#1d4ed8;--color-secondary:#bfdbfe}*,:after,:before{--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: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--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-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::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: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--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-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.a1-absolute{position:absolute}.a1-relative{position:relative}.a1-left-1\\/2{left:50%}.a1-left-2{left:.5rem}.a1-right-2{right:.5rem}.a1-top-1\\/2{top:50%}.a1-top-full{top:100%}.a1-z-10{z-index:10}.a1-z-20{z-index:20}.a1-mt-2{margin-top:8px}.a1-block{display:block}.a1-flex{display:flex}.a1-grid{display:grid}.a1-h-10{height:40px}.a1-h-6{height:24px}.a1-h-8{height:32px}.a1-h-\\[2px\\]{height:2px}.a1-h-full{height:100%}.a1-max-h-56{max-height:224px}.a1-w-10{width:40px}.a1-w-6{width:24px}.a1-w-8{width:32px}.a1-w-full{width:100%}.a1-w-max{width:-moz-max-content;width:max-content}.a1-max-w-full{max-width:100%}.a1-flex-grow,.a1-grow{flex-grow:1}.a1-grow-0{flex-grow:0}.a1--translate-x-1\\/2{--tw-translate-x:-50%}.a1--translate-x-1\\/2,.a1-rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.a1-rotate-90{--tw-rotate:90deg}.a1-scale-100{--tw-scale-x:1;--tw-scale-y:1}.a1-scale-100,.a1-scale-95{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.a1-scale-95{--tw-scale-x:.95;--tw-scale-y:.95}.a1-transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes a1-spin{to{transform:rotate(1turn)}}.a1-animate-spin{animation:a1-spin 1s linear infinite}.a1-cursor-not-allowed{cursor:not-allowed}.a1-cursor-pointer{cursor:pointer}.a1-grid-cols-7{grid-template-columns:repeat(7,minmax(0,1fr))}.a1-grid-rows-6{grid-template-rows:repeat(6,minmax(0,1fr))}.a1-flex-row{flex-direction:row}.a1-flex-col{flex-direction:column}.a1-items-center{align-items:center}.a1-justify-center{justify-content:center}.a1-justify-between{justify-content:space-between}.a1-gap-1{gap:4px}.a1-gap-2{gap:8px}.a1-gap-4{gap:16px}.a1-gap-6{gap:24px}.a1-overflow-hidden{overflow:hidden}.a1-overflow-x-hidden{overflow-x:hidden}.a1-truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.a1-rounded-full{border-radius:9999px}.a1-rounded-lg{border-radius:8px}.a1-rounded-none{border-radius:0}.a1-border{border-width:1px}.a1-border-b{border-bottom-width:1px}.a1-border-l-0{border-left-width:0}.a1-border-r-0{border-right-width:0}.a1-border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.a1-border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity))}.a1-bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.a1-bg-primary{background-color:var(--color-primary)}.a1-bg-secondary{background-color:var(--color-secondary)}.a1-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.a1-fill-indigo-200{fill:#c7d2fe}.a1-fill-indigo-800{fill:#3730a3}.a1-p-0{padding:0}.a1-p-3{padding:12px}.a1-px-4{padding-left:16px;padding-right:16px}.a1-py-2{padding-bottom:8px;padding-top:8px}.a1-text-left{text-align:left}.a1-text-xs{font-size:12px}.a1-uppercase{text-transform:uppercase}.a1-tracking-wide{letter-spacing:.025em}.a1-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.a1-text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity))}.a1-text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity))}.a1-text-primary{color:var(--color-primary)}.a1-text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.a1-opacity-0{opacity:0}.a1-opacity-100{opacity:1}.a1-opacity-50{opacity:.5}.a1-opacity-80{opacity:.8}.a1-shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.a1-shadow-lg,.a1-shadow-md{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.a1-shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}.a1-ring-2{--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);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.a1-ring-gray-200{--tw-ring-opacity:1;--tw-ring-color:rgb(229 231 235/var(--tw-ring-opacity))}.a1-ring-primary{--tw-ring-color:var(--color-primary)}.a1-transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.a1-duration-100{transition-duration:.1s}.a1-duration-75{transition-duration:75ms}.a1-ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.before\\:a1-absolute:before{content:var(--tw-content);position:absolute}.before\\:a1-bottom-0:before{bottom:0;content:var(--tw-content)}.before\\:a1-left-0:before{content:var(--tw-content);left:0}.before\\:a1-left-1\\/2:before{content:var(--tw-content);left:50%}.before\\:a1-right-0:before{content:var(--tw-content);right:0}.before\\:a1-right-1\\/2:before{content:var(--tw-content);right:50%}.before\\:a1-top-0:before{content:var(--tw-content);top:0}.before\\:a1-bg-secondary:before{background-color:var(--color-secondary);content:var(--tw-content)}.after\\:a1-absolute:after{content:var(--tw-content);position:absolute}.after\\:a1-bottom-0:after{bottom:0;content:var(--tw-content)}.after\\:a1-left-0:after{content:var(--tw-content);left:0}.after\\:a1-right-0:after{content:var(--tw-content);right:0}.after\\:a1-top-0:after{content:var(--tw-content);top:0}.after\\:a1-rounded-full:after{border-radius:9999px;content:var(--tw-content)}.after\\:a1-bg-primary:after{background-color:var(--color-primary);content:var(--tw-content)}.hover\\:a1-bg-secondary:hover{background-color:var(--color-secondary)}.hover\\:before\\:a1-ring-primary:hover:before{--tw-ring-color:var(--color-primary);content:var(--tw-content)}.hover\\:after\\:a1-absolute:hover:after{content:var(--tw-content);position:absolute}.hover\\:after\\:a1-left-0:hover:after{content:var(--tw-content);left:0}.hover\\:after\\:a1-right-0:hover:after{content:var(--tw-content);right:0}.hover\\:after\\:a1-z-10:hover:after{content:var(--tw-content);z-index:10}.hover\\:after\\:a1-h-full:hover:after{content:var(--tw-content);height:100%}.hover\\:after\\:a1-w-full:hover:after{content:var(--tw-content);width:100%}.hover\\:after\\:a1-rounded-full:hover:after{border-radius:9999px;content:var(--tw-content)}.hover\\:after\\:a1-ring-2:hover:after{--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);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000);content:var(--tw-content)}.focus\\:a1-border-primary:focus{border-color:var(--color-primary)}.focus\\:a1-outline-none:focus{outline:2px solid transparent;outline-offset:2px}.disabled\\:a1-bg-gray-400:disabled{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity))}@media (min-width:768px){.md\\:a1-bottom-2{bottom:.5rem}.md\\:a1-left-1\\/2{left:50%}.md\\:a1-top-2{top:.5rem}.md\\:a1-h-\\[initial\\]{height:auto}.md\\:a1-w-\\[2px\\]{width:2px}.md\\:a1-flex-row{flex-direction:row}.md\\:a1-items-center{align-items:center}}@media (min-width:1024px){.lg\\:a1-hidden{display:none}.lg\\:a1-h-\\[48px\\]{height:48px}.lg\\:a1-max-w-\\[none\\]{max-width:none}.lg\\:a1-rotate-0{--tw-rotate:0deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:a1-flex-row{flex-direction:row}}
|
|
46
46
|
`,Y1=new Vh;function ca(e){return $e(Zh,{client:Y1,contextSharing:!0,children:[F("style",{children:q1}),F(np,G({},e))]})}ca.propTypes=ep;class rp extends HTMLElement{connectedCallback(){const t=document.createElement("span");this.appendChild(t);const n=Object.keys(ca.propTypes).reduce((i,o)=>{const a=this.getAttribute(o.toLocaleLowerCase());return a!=null&&(i[o]=a),i},{});Sa.createRoot(t).render(F(ca,G({apiDomain:"https://flymyairport.vercel.app"},n)))}}return customElements.define("flight-search-form",rp),ae.FlightSearchForm=rp,ae.default=ca,Object.defineProperties(ae,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}}),ae}({});
|