PageSourceSearch

https://insacret.org/_next/static/chunks/296-5d742a851acc25de.js

js insacret.org collected 2026-10-03 21:05:39 UTC 190,067 bytes, 4 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[296],{4367:function(){},2130:function(){},9950:function(e,t,n){"use strict";let r,i,o,a,s;n.d(t,{R:function(){return iw}});var u,c,l,d,f,h,v,p,y,g,m,b,w,E,S,x,O,T,k=n(7294);n(2473);var P="undefined"!=typeof window&&window.document&&window.document.createElement?k.useLayoutEffect:k.useEffect;"undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();var R=n(3935),C=function(e){var t,n=e.children,r=e.type,i=void 0===r?"reach-portal":r,o=(0,k.useRef)(null),a=(0,k.useRef)(null),s=(t=(0,k.useState)(Object.create(null))[1],(0,k.useCallback)(function(){t(Object.create(null))},[]));return P(function(){if(o.current){var e=o.current.ownerDocument;return a.current=null==e?void 0:e.createElement(i),e.body.appendChild(a.current),s(),function(){a.current&&a.current.ownerDocument&&a.current.ownerDocument.body.removeChild(a.current)}}},[i,s]),a.current?(0,R.createPortal)(n,a.current):(0,k.createElement)("span",{ref:o})},A=function(){return(A=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function N(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)0>t.indexOf(r[i])&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function _(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function j(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function L(e,t,n){if(n||2==arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}var D={},F="xstate.guard";(u=b||(b={})).Start="xstate.start",u.Stop="xstate.stop",u.Raise="xstate.raise",u.Send="xstate.send",u.Cancel="xstate.cancel",u.NullEvent="",u.Assign="xstate.assign",u.After="xstate.after",u.DoneState="done.state",u.DoneInvoke="done.invoke",u.Log="xstate.log",u.Init="xstate.init",u.Invoke="xstate.invoke",u.ErrorExecution="error.execution",u.ErrorCommunication="error.communication",u.ErrorPlatform="error.platform",u.ErrorCustom="xstate.error",u.Update="xstate.update",u.Pure="xstate.pure",u.Choose="xstate.choose",(c=w||(w={})).Parent="#_parent",c.Internal="#_internal";var M=b.Start,I=b.Stop,V=b.Raise,z=b.Send,H=b.Cancel,B=b.NullEvent,G=b.Assign;b.After,b.DoneState;var q=b.Log,U=b.Init,K=b.Invoke;b.ErrorExecution;var Y=b.ErrorPlatform,W=b.ErrorCustom,Z=b.Update,$=b.Choose,X=b.Pure;function J(e,t,n){void 0===n&&(n=".");var r=et(e,n),i=et(t,n);return ep(i)?!!ep(r)&&i===r:ep(r)?r in i:Object.keys(r).every(function(e){return e in i&&J(r[e],i[e])})}function Q(e){try{return ep(e)||"number"==typeof e?"".concat(e):e.type}catch(e){throw Error("Events must be strings or objects with a string event.type property.")}}function ee(e,t){try{if(eh(e))return e;return e.toString().split(t)}catch(t){throw Error("'".concat(e,"' is not a valid state path."))}}function et(e,t){return"object"==typeof e&&"value"in e&&"context"in e&&"event"in e&&"_event"in e?e.value:eh(e)?en(e):"string"!=typeof e?e:en(ee(e,t))}function en(e){if(1===e.length)return e[0];for(var t={},n=t,r=0;r<e.length-1;r++)r===e.length-2?n[e[r]]=e[r+1]:(n[e[r]]={},n=n[e[r]]);return t}function er(e,t){for(var n={},r=Object.keys(e),i=0;i<r.length;i++){var o=r[i];n[o]=t(e[o],o,e,i)}return n}function ei(e,t,n){var r,i,o={};try{for(var a=_(Object.keys(e)),s=a.next();!s.done;s=a.next()){var u=s.value,c=e[u];n(c)&&(o[u]=t(c,u,e))}}catch(e){r={error:e}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}return o}var eo=function(e){return function(t){var n,r,i=t;try{for(var o=_(e),a=o.next();!a.done;a=o.next())i=i[a.value]}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return i}};function ea(e){return e?ep(e)?[[e]]:es(Object.keys(e).map(function(t){var n=e[t];return"string"==typeof n||n&&Object.keys(n).length?ea(e[t]).map(function(e){return[t].concat(e)}):[[t]]})):[[]]}function es(e){var t;
1return(t=[]).concat.apply(t,L([],j(e),!1))}function eu(e){return void 0===e?[]:eh(e)?e:[e]}function ec(e,t,n){if(ev(e))return e(t,n.data);var r,i,o={};try{for(var a=_(Object.keys(e)),s=a.next();!s.done;s=a.next()){var u=s.value,c=e[u];ev(c)?o[u]=c(t,n.data):o[u]=c}}catch(e){r={error:e}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}return o}function el(e){return!!(e instanceof Promise||null!==e&&(ev(e)||"object"==typeof e)&&ev(e.then))}function ed(e,t,n,r){return e?n.reduce(function(e,n){var i,o,a=n.assignment,s={state:r,action:n,_event:t},u={};if(ev(a))u=a(e,t.data,s);else try{for(var c=_(Object.keys(a)),l=c.next();!l.done;l=c.next()){var d=l.value,f=a[d];u[d]=ev(f)?f(e,t.data,s):f}}catch(e){i={error:e}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(i)throw i.error}}return Object.assign({},e,u)},e):e}var ef=function(){};function eh(e){return Array.isArray(e)}function ev(e){return"function"==typeof e}function ep(e){return"string"==typeof e}function ey(e,t){return e?ep(e)?{type:F,name:e,predicate:t?t[e]:void 0}:ev(e)?{type:F,name:e.name,predicate:e}:e:void 0}var eg="function"==typeof Symbol&&Symbol.observable||"@@observable";function em(e){return!!e&&"__xstatenode"in e}function eb(e,t){return ep(e)||"number"==typeof e?A({type:e},t):e}function ew(e,t){if(!ep(e)&&"$$type"in e&&"scxml"===e.$$type)return e;var n=eb(e);return A({name:n.type,data:n,$$type:"scxml",type:"external"},t)}function eE(e,t){return(eh(t)?t:[t]).map(function(t){return void 0===t||"string"==typeof t||em(t)?{target:t,event:e}:A(A({},t),{event:e})})}function eS(e,t,n,r,i){var o=e.options.guards,a={state:i,cond:t,_event:r};if(t.type===F)return((null==o?void 0:o[t.name])||t.predicate)(n,r.data,a);var s=null==o?void 0:o[t.type];if(!s)throw Error("Guard '".concat(t.type,"' is not implemented on machine '").concat(e.id,"'."));return s(n,r.data,a)}function ex(e){return"string"==typeof e?{type:e}:e}function eO(e,t,n){var r=function(){},i="object"==typeof e,o=i?e:null;return{next:((i?e.next:e)||r).bind(o),error:((i?e.error:t)||r).bind(o),complete:((i?e.complete:n)||r).bind(o)}}function eT(e,t){return"".concat(e,":invocation[").concat(t,"]")}function ek(e){return(e.type===V||e.type===z&&e.to===w.Internal)&&"number"!=typeof e.delay}(E={})[eg]=function(){return this},E[Symbol.observable]=function(){return this};var eP=function(e){return"atomic"===e.type||"final"===e.type};function eR(e){return Object.keys(e.states).map(function(t){return e.states[t]})}function eC(e){return eR(e).filter(function(e){return"history"!==e.type})}function eA(e,t){var n,r,i,o,a,s,u,c,l=eN(new Set(e)),d=new Set(t);try{for(var f=_(d),h=f.next();!h.done;h=f.next())for(var v=h.value,p=v.parent;p&&!d.has(p);)d.add(p),p=p.parent}catch(e){n={error:e}}finally{try{h&&!h.done&&(r=f.return)&&r.call(f)}finally{if(n)throw n.error}}var y=eN(d);try{for(var g=_(d),m=g.next();!m.done;m=g.next()){var v=m.value;if("compound"!==v.type||y.get(v)&&y.get(v).length){if("parallel"===v.type)try{for(var b=(a=void 0,_(eC(v))),w=b.next();!w.done;w=b.next()){var E=w.value;d.has(E)||(d.add(E),l.get(E)?l.get(E).forEach(function(e){return d.add(e)}):E.initialStateNodes.forEach(function(e){return d.add(e)}))}}catch(e){a={error:e}}finally{try{w&&!w.done&&(s=b.return)&&s.call(b)}finally{if(a)throw a.error}}}else l.get(v)?l.get(v).forEach(function(e){return d.add(e)}):v.initialStateNodes.forEach(function(e){return d.add(e)})}}catch(e){i={error:e}}finally{try{m&&!m.done&&(o=g.return)&&o.call(g)}finally{if(i)throw i.error}}try{for(var S=_(d),x=S.next();!x.done;x=S.next())for(var v=x.value,p=v.parent;p&&!d.has(p);)d.add(p),p=p.parent}catch(e){u={error:e}}finally{try{x&&!x.done&&(c=S.return)&&c.call(S)}finally{if(u)throw u.error}}return d}function eN(e){var t,n,r=new Map;try{for(var i=_(e),o=i.next();!o.done;o=i.next()){var a=o.value;r.has(a)||r.set(a,[]),a.parent&&(r.has(a.parent)||r.set(a.parent,[]),r.get(a.parent).push(a))}}catch(e){t={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r}function e_(e,t){return Array.isArray(e)?e.some(function(e){return e===t}):e instanceof Set&&e.has(t)}function ej(e,t){return"compound"===t.type?eC(t).some(function(t){return"final"===t.type&&e_(e,t)}):"parallel"===t.type&&eC(t).every(function(t){return ej(e,t)})}function eL(e){return new Set(es(e.map(function(e){return e.tags})))}var eD=ew({type:U});function eF(e,t){return t&&t[e]||void 0}function eM(e,t){var n;if(ep(e)||"number"==typeof e){var r=eF(e,t);n=ev(r)?{type:e,exec:r}:r||{type:e,exec:void 0}}else if(ev(e))n={type:e.name||e.toString(),exec:e};else{var r=eF(e.type,t);if(ev(r))n=A(A({},e),{exec:r});else if(r){var i=r.type||e.type;n=A(A(A({},r),e),{type:i})}else n=e}return n}var eI=function(e,t){return e?(eh(e)?e:[e]).map(function(e){return eM(e,t)}):[]};function eV(e){var t=eM(e);return A(A({id:ep(e)?e:t.id},t),{type:t.type})}function ez(e,t){var n="".concat(b.DoneState,".").concat(e),r={type:n,data:t};return r.toString=function(){return n},r}function eH(e,t){var n="".concat(b.DoneInvoke,".").concat(e),r={type:n,data:t};return r.toString=function(){return n},r}function eB(e,t){var n="".concat(b.ErrorPlatform,".").concat(e),r={type:n,data:t};return r.toString=function(){return n},r}var eG=function(e){var t,n,r=[];try{for(var i=_(e),o=i.next();!o.done;o=i.next())for(var a=o.value,s=0;s<a.actions.length;){if(a.actions[s].type===G){r.push(a.actions[s]),a.actions.splice(s,1);continue}s++}}catch(e){t={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r};function eq(e,t,n,r,i,o,a){void 0===a&&(a=!1);var s=a?[]:eG(i),u=s.length?ed(n,r,s,t):n,c=a?[n]:void 0,l=[];return[es(i.map(function(i){var s,d,f=[];try{for(var h=_(i.actions),v=h.next();!v.done;v=h.next()){var p=v.value,y=function(i,s){var d;switch(s.type){case V:var f=function(e,t,n,r){var i,o={_event:n},a=ew(ev(e.event)?e.event(t,n.data,o):e.event);if(ep(e.delay)){var s=r&&r[e.delay];i=ev(s)?s(t,n.data,o):s}else i=ev(e.delay)?e.delay(t,n.data,o):e.delay;return A(A({},e),{type:V,_event:a,delay:i})}(s,u,r,e.options.delays);return o&&"number"==typeof f.delay&&o(f,u,r),f;case z:var h=function(e,t,n,r){var i,o={_event:n},a=ew(ev(e.event)?e.event(t,n.data,o):e.event);if(ep(e.delay)){var s=r&&r[e.delay];i=ev(s)?s(t,n.data,o):s}else i=ev(e.delay)?e.delay(t,n.data,o):e.delay;var u=ev(e.to)?e.to(t,n.data,o):e.to;return A(A({},e),{to:u,_event:a,event:a.data,delay:i})}(s,u,r,e.options.delays);return o&&h.to!==w.Internal&&("entry"===i?l.push(h):o(h,u,r)),h;case q:var v,p=(v=u,A(A({},s),{value:ep(s.expr)?s.expr:s.expr(v,r.data,{_event:r})}));return null==o||o(p,u,r),p;case $:var y=null===(d=s.conds.find(function(n){var i=ey(n.cond,e.o
1ptions.guards);return!i||eS(e,i,u,r,o?void 0:t)}))||void 0===d?void 0:d.actions;if(!y)return[];var g=j(eq(e,t,u,r,[{type:i,actions:eI(eu(y),e.options.actions)}],o,a),2),m=g[0];return u=g[1],null==c||c.push(u),m;case X:var y=s.get(u,r.data);if(!y)return[];var E=j(eq(e,t,u,r,[{type:i,actions:eI(eu(y),e.options.actions)}],o,a),2),S=E[0];return u=E[1],null==c||c.push(u),S;case I:var x,O,p=(x=u,O=ev(s.activity)?s.activity(x,r.data):s.activity,{type:b.Stop,activity:"string"==typeof O?{id:O}:O});return null==o||o(p,n,r),p;case G:u=ed(u,r,[s],o?void 0:t),null==c||c.push(u);break;default:var T=eM(s,e.options.actions),k=T.exec;if(o)o(T,u,r);else if(k&&c){var P=c.length-1;T=A(A({},T),{exec:function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];k.apply(void 0,L([c[P]],j(t),!1))}})}return T}}(i.type,p);y&&(f=f.concat(y))}}catch(e){s={error:e}}finally{try{v&&!v.done&&(d=h.return)&&d.call(h)}finally{if(s)throw s.error}}return l.forEach(function(e){o(e,u,r)}),l.length=0,f})),u]}var eU=function(){function e(e){var t,n,r=this;this.actions=[],this.activities=D,this.meta={},this.events=[],this.value=e.value,this.context=e.context,this._event=e._event,this._sessionid=e._sessionid,this.event=this._event.data,this.historyValue=e.historyValue,this.history=e.history,this.actions=e.actions||[],this.activities=e.activities||D,this.meta=(void 0===(t=e.configuration)&&(t=[]),t.reduce(function(e,t){return void 0!==t.meta&&(e[t.id]=t.meta),e},{})),this.events=e.events||[],this.matches=this.matches.bind(this),this.toStrings=this.toStrings.bind(this),this.configuration=e.configuration,this.transitions=e.transitions,this.children=e.children,this.done=!!e.done,this.tags=null!==(n=Array.isArray(e.tags)?new Set(e.tags):e.tags)&&void 0!==n?n:new Set,this.machine=e.machine,Object.defineProperty(this,"nextEvents",{get:function(){return L([],j(new Set(es(L([],j(r.configuration.map(function(e){return e.ownEvents})),!1)))),!1)}})}return e.from=function(t,n){return t instanceof e?t.context!==n?new e({value:t.value,context:n,_event:t._event,_sessionid:null,historyValue:t.historyValue,history:t.history,actions:[],activities:t.activities,meta:{},events:[],configuration:[],transitions:[],children:{}}):t:new e({value:t,context:n,_event:eD,_sessionid:null,historyValue:void 0,history:void 0,actions:[],activities:void 0,meta:void 0,events:[],configuration:[],transitions:[],children:{}})},e.create=function(t){return new e(t)},e.inert=function(t,n){return t instanceof e?t.actions.length?new e({value:t.value,context:n,_event:eD,_sessionid:null,historyValue:t.historyValue,history:t.history,activities:t.activities,configuration:t.configuration,transitions:[],children:{}}):t:e.from(t,n)},e.prototype.toStrings=function(e,t){var n=this;if(void 0===e&&(e=this.value),void 0===t&&(t="."),ep(e))return[e];var r=Object.keys(e);return r.concat.apply(r,L([],j(r.map(function(r){return n.toStrings(e[r],t).map(function(e){return r+t+e})})),!1))},e.prototype.toJSON=function(){this.configuration,this.transitions;var e=this.tags;this.machine;var t=N(this,["configuration","transitions","tags","machine"]);return A(A({},t),{tags:Array.from(e)})},e.prototype.matches=function(e){return J(e,this.value)},e.prototype.hasTag=function(e){return this.tags.has(e)},e.prototype.can=function(e){ef(!!this.machine,"state.can(...) used outside of a machine-created State object; this will always return false.");var t,n=null===(t=this.machine)||void 0===t?void 0:t.getTransitionData(this,e);return!!(null==n?void 0:n.transitions.length)&&n.transitions.some(function(e){return void 0!==e.target||e.actions.length})},e}(),eK=k.useLayoutEffect,eY={deferEvents:!1},eW=function(){function e(e){this.processingEvent=!1,this.queue=[],this.initialized=!1,this.options=A(A({},eY),e)}return e.prototype.initialize=function(e){if(this.initialized=!0,e){if(!this.options.deferEvents){this.schedule(e);return}this.process(e)}this.flushEvents()},e.prototype.schedule=function(e){if(!this.initialized||this.processingEvent){this.queue.push(e);return}if(0!==this.queue.length)throw Error("Event queue should be empty when it is not processing events");this.process(e),this.flushEvents()},e.prototype.clear=function(){this.queue=[]},e.prototype.flushEvents=function(){for(var e=this.queue.shift();e;)this.process(e),e=this.queue.shift()},e.prototype.process=function(e){this.processingEvent=!0;try{e()}catch(e){throw this.clear(),e}finally{this.processingEvent=!1}},e}(),eZ=[],e$=function(e,t){eZ.push(e);var n=t(e);return eZ.pop(),n};function eX(e){var t;return(t={id:e,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},getSnapshot:function(){},toJSON:function(){return{id:e}}})[eg]=function(){return this},t}function eJ(e,t,n){var r=eX(t);if(r.deferred=!0,em(e)){var i=r.state=e$(void 0,function(){return(n?e.withContext(n):e).initialState});r.getSnapshot=function(){return i}}return r}var eQ=new Map,e0=0,e1={bookId:function(){return"x:".concat(e0++)},register:function(e,t){return eQ.set(e,t),e},get:function(e){return eQ.get(e)},free:function(e){eQ.delete(e)}};function e2(){return"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==n.g?n.g:void 0}var e5={sync:!1,autoForward:!1};(l=S||(S={}))[l.NotStarted=0]="NotStarted",l[l.Running=1]="Running",l[l.Stopped=2]="Stopped";var e3=function(){function e(t,n){void 0===n&&(n=e.defaultOptions);var r=this;this.machine=t,this.delayedEventsMap={},this.listeners=new Set,this.contextListeners=new Set,this.stopListeners=new Set,this.doneListeners=new Set,this.eventListeners=new Set,this.sendListeners=new Set,this.initialized=!1,this.status=S.NotStarted,this.children=new Map,this.forwardTo=new Set,this._outgoingQueue=[],this.init=this.start,this.send=function(e,t){if(eh(e))return r.batch(e),r.state;var n=ew(eb(e,t));if(r.status===S.Stopped)return r.state;if(r.status!==S.Running&&!r.options.deferEvents)throw Error('Event "'.concat(n.name,'" was sent to uninitialized service "').concat(r.machine.id,'". Make sure .start() is called for this service, or set { deferEvents: true } in the service options.\nEvent: ').concat(JSON.stringify(n.data)));return r.scheduler.schedule(function(){r.forward(n);var e=r._nextState(n);r.update(e,n)}),r._state},this.sendTo=function(e,t,n){var i=r.parent&&(t===w.Parent||r.parent.id===t),o=i?r.parent:ep(t)?t===w.Internal?r:r.children.get(t)||e1.get(t):t&&"function"==typeof t.send?t:void 0;if(!o){if(!i)throw Error("Unable to send event to child '".concat(t,"' from service '").concat(r.id,"'."));return}if("machine"in o){if(r.status!==S.Stopped||r.parent!==o||r.state.done){var a=A(A({},e),{name:e.name===W?"".concat(eB(r.id)):e.name,origin:r.sessionId});!n&&r.machine.config.predictableActionArguments?r._outgoingQueue.push([o,a]):o.send(a)}}else!n&&r.machine.config.predictableActionArguments?r._outgoingQueue.push([o,e.data]):o.send(e.data)},this._exec=function(e,t,n,i){void 0===i&&(i=r.machine.options.actions);var o=e.exec||eF(e.type,i),a=ev(o)?o:o?o.exec:e.exec;if(a)try{return a(t,n.data,r.machine.config.predictableActionArguments?{action:e,_event:n}:{action:e,state:r.state,_event:n})}catch(e){throw r.parent&&r.parent.send({type:"xstate.error",data:e}),e}switch(e.type){case V:r.defer(e);break;case z:if("number"==typeof e.delay){r.defer(e);return}e.to?r.sendTo(e._event,e.to,n===eD):r.send(e._event);break;case H:r.cancel(e.sendId);break;case M:if(r.status!==S.Running)return;var s=e.activity;if(!r.machine.config.predictableActionArguments&&!r.state.activities[s.id||s.type])break;if(s.type===b.Invoke){var u=ex(s.src),c=r.machine.options.services?r.machine.options.services[u.type]:void 0,l=s.id,d=s.data,f="autoForward"in s?s.autoForward:!!s.forward;if(!c)return;var h=d?ec(d,t,n):void 0;if("string"==typeof c)return;var v=ev(c)?c(t,n.data,{data:h,src:u,meta:s.meta}):c;if(!v)return;var p=void 0;em(v)&&(v=h?v.withContext(h):v,p={autoForward:f}),r.spawn(v,l,p)}else r.spawnActivity(s);break;case I:r.stopChild(e.activity.id);break;case q:var y=e.label,g=e.value;y?r.logger(y,g):r.logger(g)}};var i=A(A({},e.defaultOptions),n),o=i.clock,a=i.logger,s=i.parent,u=i.id,c=void 0!==u?u:t.i
1d;this.id=c,this.logger=a,this.clock=o,this.parent=s,this.options=i,this.scheduler=new eW({deferEvents:this.options.deferEvents}),this.sessionId=e1.bookId()}return Object.defineProperty(e.prototype,"initialState",{get:function(){var e=this;return this._initialState?this._initialState:e$(this,function(){return e._initialState=e.machine.initialState,e._initialState})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"state",{get:function(){return this._state},enumerable:!1,configurable:!0}),e.prototype.execute=function(e,t){var n,r;try{for(var i=_(e.actions),o=i.next();!o.done;o=i.next()){var a=o.value;this.exec(a,e,t)}}catch(e){n={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}},e.prototype.update=function(e,t){var n,r,i,o,a,s,u,c,l=this;if(e._sessionid=this.sessionId,this._state=e,(!this.machine.config.predictableActionArguments||t===eD)&&this.options.execute)this.execute(this.state);else for(var d=void 0;d=this._outgoingQueue.shift();)d[0].send(d[1]);if(this.children.forEach(function(e){l.state.children[e.id]=e}),this.devTools&&this.devTools.send(t.data,e),e.event)try{for(var f=_(this.eventListeners),h=f.next();!h.done;h=f.next()){var v=h.value;v(e.event)}}catch(e){n={error:e}}finally{try{h&&!h.done&&(r=f.return)&&r.call(f)}finally{if(n)throw n.error}}try{for(var p=_(this.listeners),y=p.next();!y.done;y=p.next()){var v=y.value;v(e,e.event)}}catch(e){i={error:e}}finally{try{y&&!y.done&&(o=p.return)&&o.call(p)}finally{if(i)throw i.error}}try{for(var g=_(this.contextListeners),m=g.next();!m.done;m=g.next())(0,m.value)(this.state.context,this.state.history?this.state.history.context:void 0)}catch(e){a={error:e}}finally{try{m&&!m.done&&(s=g.return)&&s.call(g)}finally{if(a)throw a.error}}if(this.state.done){var b=e.configuration.find(function(e){return"final"===e.type&&e.parent===l.machine}),w=b&&b.doneData?ec(b.doneData,e.context,t):void 0;this._doneEvent=eH(this.id,w);try{for(var E=_(this.doneListeners),S=E.next();!S.done;S=E.next()){var v=S.value;v(this._doneEvent)}}catch(e){u={error:e}}finally{try{S&&!S.done&&(c=E.return)&&c.call(E)}finally{if(u)throw u.error}}this._stop(),this._stopChildren(),e1.free(this.sessionId)}},e.prototype.onTransition=function(e){return this.listeners.add(e),this.status===S.Running&&e(this.state,this.state.event),this},e.prototype.subscribe=function(e,t,n){var r=this,i=eO(e,t,n);this.listeners.add(i.next),this.status!==S.NotStarted&&i.next(this.state);var o=function(){r.doneListeners.delete(o),r.stopListeners.delete(o),i.complete()};return this.status===S.Stopped?i.complete():(this.onDone(o),this.onStop(o)),{unsubscribe:function(){r.listeners.delete(i.next),r.doneListeners.delete(o),r.stopListeners.delete(o)}}},e.prototype.onEvent=function(e){return this.eventListeners.add(e),this},e.prototype.onSend=function(e){return this.sendListeners.add(e),this},e.prototype.onChange=function(e){return this.contextListeners.add(e),this},e.prototype.onStop=function(e){return this.stopListeners.add(e),this},e.prototype.onDone=function(e){return this.status===S.Stopped&&this._doneEvent?e(this._doneEvent):this.doneListeners.add(e),this},e.prototype.off=function(e){return this.listeners.delete(e),this.eventListeners.delete(e),this.sendListeners.delete(e),this.stopListeners.delete(e),this.doneListeners.delete(e),this.contextListeners.delete(e),this},e.prototype.start=function(e){var t=this;if(this.status===S.Running)return this;this.machine._init(),e1.register(this.sessionId,this),this.initialized=!0,this.status=S.Running;var n=void 0===e?this.initialState:e$(this,function(){return"object"==typeof e&&null!==e&&"value"in e&&"_event"in e?t.machine.resolveState(e):t.machine.resolveState(eU.from(e,t.machine.context))});return this.options.devTools&&this.attachDev(),this.scheduler.initialize(function(){t.update(n,eD)}),this},e.prototype._stopChildren=function(){this.children.forEach(function(e){ev(e.stop)&&e.stop()}),this.children.clear()},e.prototype._stop=function(){var e,t,n,r,i,o,a,s,u,c;try{for(var l=_(this.listeners),d=l.next();!d.done;d=l.next()){var f=d.value;this.listeners.delete(f)}}catch(t){e={error:t}}finally{try{d&&!d.done&&(t=l.return)&&t.call(l)}finally{if(e)throw e.error}}try{for(var h=_(this.stopListeners),v=h.next();!v.done;v=h.next()){var f=v.value;f(),this.stopListeners.delete(f)}}catch(e){n={error:e}}finally{try{v&&!v.done&&(r=h.return)&&r.call(h)}finally{if(n)throw n.error}}try{for(var p=_(this.contextListeners),y=p.next();!y.done;y=p.next()){var f=y.value;this.contextListeners.delete(f)}}catch(e){i={error:e}}
1finally{try{y&&!y.done&&(o=p.return)&&o.call(p)}finally{if(i)throw i.error}}try{for(var g=_(this.doneListeners),m=g.next();!m.done;m=g.next()){var f=m.value;this.doneListeners.delete(f)}}catch(e){a={error:e}}finally{try{m&&!m.done&&(s=g.return)&&s.call(g)}finally{if(a)throw a.error}}if(!this.initialized)return this;this.initialized=!1,this.status=S.Stopped,this._initialState=void 0;try{for(var b=_(Object.keys(this.delayedEventsMap)),w=b.next();!w.done;w=b.next()){var E=w.value;this.clock.clearTimeout(this.delayedEventsMap[E])}}catch(e){u={error:e}}finally{try{w&&!w.done&&(c=b.return)&&c.call(b)}finally{if(u)throw u.error}}this.scheduler.clear(),this.scheduler=new eW({deferEvents:this.options.deferEvents})},e.prototype.stop=function(){var e=this,t=this.scheduler;return this._stop(),t.schedule(function(){if(null===(t=e._state)||void 0===t||!t.done){var t,n=ew({type:"xstate.stop"}),r=e$(e,function(){var t=es(L([],j(e.state.configuration),!1).sort(function(e,t){return t.order-e.order}).map(function(t){return eI(t.onExit,e.machine.options.actions)})),r=j(eq(e.machine,e.state,e.state.context,n,[{type:"exit",actions:t}],e.machine.config.predictableActionArguments?e._exec:void 0,e.machine.config.predictableActionArguments||e.machine.config.preserveActionOrder),2),i=r[0],o=r[1],a=new eU({value:e.state.value,context:o,_event:n,_sessionid:e.sessionId,historyValue:void 0,history:e.state,actions:i.filter(function(e){return!ek(e)}),activities:{},events:[],configuration:[],transitions:[],children:{},done:e.state.done,tags:e.state.tags,machine:e.machine});return a.changed=!0,a});e.update(r,n),e._stopChildren(),e1.free(e.sessionId)}}),this},e.prototype.batch=function(e){var t=this;if(this.status===S.NotStarted&&this.options.deferEvents);else if(this.status!==S.Running)throw Error("".concat(e.length,' event(s) were sent to uninitialized service "').concat(this.machine.id,'". Make sure .start() is called for this service, or set { deferEvents: true } in the service options.'));if(e.length){var n=!!this.machine.config.predictableActionArguments&&this._exec;this.scheduler.schedule(function(){var r,i,o=t.state,a=!1,s=[];try{for(var u=_(e),c=u.next();!c.done;c=u.next()){var l=c.value;!function(e){var r=ew(e);t.forward(r),o=e$(t,function(){return t.machine.transition(o,r,void 0,n||void 0)}),s.push.apply(s,L([],j(t.machine.config.predictableActionArguments?o.actions:o.actions.map(function(e){var t,n;return t=o,n=e.exec,A(A({},e),{exec:void 0!==n?function(){return n(t.context,t.event,{action:e,state:t,_event:t._event})}:void 0})})),!1)),a=a||!!o.changed}(l)}}catch(e){r={error:e}}finally{try{c&&!c.done&&(i=u.return)&&i.call(u)}finally{if(r)throw r.error}}o.changed=a,o.actions=s,t.update(o,ew(e[e.length-1]))})}},e.prototype.sender=function(e){return this.send.bind(this,e)},e.prototype._nextState=function(e,t){var n=this;void 0===t&&(t=!!this.machine.config.predictableActionArguments&&this._exec);var r=ew(e);if(0===r.name.indexOf(Y)&&!this.state.nextEvents.some(function(e){return 0===e.indexOf(Y)}))throw r.data.data;return e$(this,function(){return n.machine.transition(n.state,r,void 0,t||void 0)})},e.prototype.nextState=function(e){return this._nextState(e,!1)},e.prototype.forward=function(e){var t,n;try{for(var r=_(this.forwardTo),i=r.next();!i.done;i=r.next()){var o=i.value,a=this.children.get(o);if(!a)throw Error("Unable to forward event '".concat(e,"' from interpreter '").concat(this.id,"' to nonexistant child '").concat(o,"'."));a.send(e)}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}},e.prototype.defer=function(e){var t=this,n=this.clock.setTimeout(function(){"to"in e&&e.to?t.sendTo(e._event,e.to,!0):t.send(e._event)},e.delay);e.id&&(this.delayedEventsMap[e.id]=n)},e.prototype.cancel=function(e){this.clock.clearTimeout(this.delayedEventsMap[e]),delete this.delayedEventsMap[e]},e.prototype.exec=function(e,t,n){void 0===n&&(n=this.machine.options.actions),this._exec(e,t.context,t._event,n)},e.prototype.removeChild=function(e){var t;this.children.delete(e),this.forwardTo.delete(e),null===(t=this.state)||void 0===t||delete t.children[e]},e.prototype.stopChild=function(e){var t=this.children.get(e);t&&(this.removeChild(e),ev(t.stop)&&t.stop())},e.prototype.spawn=function(e,t,n){if(this.status!==S.Running)return eJ(e,t);
1if(el(e))return this.spawnPromise(Promise.resolve(e),t);if(ev(e))return this.spawnCallback(e,t);if(function(e){try{return"function"==typeof e.send}catch(e){return!1}}(e)&&"id"in e)return this.spawnActor(e,t);if(function(e){try{return"subscribe"in e&&ev(e.subscribe)}catch(e){return!1}}(e))return this.spawnObservable(e,t);if(em(e))return this.spawnMachine(e,A(A({},n),{id:t}));if(null!==e&&"object"==typeof e&&"transition"in e&&"function"==typeof e.transition)return this.spawnBehavior(e,t);throw Error('Unable to spawn entity "'.concat(t,'" of type "').concat(typeof e,'".'))},e.prototype.spawnMachine=function(t,n){var r=this;void 0===n&&(n={});var i=new e(t,A(A({},this.options),{parent:this,id:n.id||t.id})),o=A(A({},e5),n);return o.sync&&i.onTransition(function(e){r.send(Z,{state:e,id:i.id})}),this.children.set(i.id,i),o.autoForward&&this.forwardTo.add(i.id),i.onDone(function(e){r.removeChild(i.id),r.send(ew(e,{origin:i.id}))}).start(),i},e.prototype.spawnBehavior=function(e,t){var n,r,i,o,a,s,u,c,l,d,f=(n={id:t,parent:this},r=e.initialState,i=new Set,o=[],a=!1,s=function(){if(!a){for(a=!0;o.length>0;){var t=o.shift();r=e.transition(r,t,d),i.forEach(function(e){return e.next(r)})}a=!1}},u={id:n.id,send:function(e){o.push(e),s()},getSnapshot:function(){return r},subscribe:function(e,t,n){var o=eO(e,t,n);return i.add(o),o.next(r),{unsubscribe:function(){i.delete(o)}}}},l=A(((c={subscribe:function(){return{unsubscribe:function(){}}},id:"anonymous",getSnapshot:function(){}})[eg]=function(){return this},c),u),d={parent:n.parent,self:l,id:n.id||"anonymous",observers:i},r=e.start?e.start(d):r,l);return this.children.set(t,f),f},e.prototype.spawnPromise=function(e,t){var n,r,i=this,o=!1;e.then(function(e){o||(r=e,i.removeChild(t),i.send(ew(eH(t,e),{origin:t})))},function(e){if(!o){i.removeChild(t);var n=eB(t,e);try{i.send(ew(n,{origin:t}))}catch(e){i.devTools&&i.devTools.send(n,i.state),i.machine.strict&&i.stop()}}});var a=((n={id:t,send:function(){},subscribe:function(t,n,r){var i=eO(t,n,r),o=!1;return e.then(function(e){!o&&(i.next(e),o||i.complete())},function(e){o||i.error(e)}),{unsubscribe:function(){return o=!0}}},stop:function(){o=!0},toJSON:function(){return{id:t}},getSnapshot:function(){return r}})[eg]=function(){return this},n);return this.children.set(t,a),a},e.prototype.spawnCallback=function(e,t){var n,r,i,o=this,a=!1,s=new Set,u=new Set;try{i=e(function(e){r=e,u.forEach(function(t){return t(e)}),a||o.send(ew(e,{origin:t}))},function(e){s.add(e)})}catch(e){this.send(eB(t,e))}if(el(i))return this.spawnPromise(i,t);var c=((n={id:t,send:function(e){return s.forEach(function(t){return t(e)})},subscribe:function(e){var t=eO(e);return u.add(t.next),{unsubscribe:function(){u.delete(t.next)}}},stop:function(){a=!0,ev(i)&&i()},toJSON:function(){return{id:t}},getSnapshot:function(){return r}})[eg]=function(){return this},n);return this.children.set(t,c),c},e.prototype.spawnObservable=function(e,t){var n,r,i=this,o=e.subscribe(function(e){r=e,i.send(ew(e,{origin:t}))},function(e){i.removeChild(t),i.send(ew(eB(t,e),{origin:t}))},function(){i.removeChild(t),i.send(ew(eH(t),{origin:t}))}),a=((n={id:t,send:function(){},subscribe:function(t,n,r){return e.subscribe(t,n,r)},stop:function(){return o.unsubscribe()},getSnapshot:function(){return r},toJSON:function(){return{id:t}}})[eg]=function(){return this},n);return this.children.set(t,a),a},e.prototype.spawnActor=function(e,t){return this.children.set(t,e),e},e.prototype.spawnActivity=function(e){var t=this.machine.options&&this.machine.options.activities?this.machine.options.activities[e.type]:void 0;if(t){var n=t(this.state.context,e);this.spawnEffect(e.id,n)}},e.prototype.spawnEffect=function(e,t){var n;this.children.set(e,((n={id:e,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},stop:t||void 0,getSnapshot:function(){},toJSON:function(){return{id:e}}})[eg]=function(){return this},n))},e.prototype.attachDev=function(){var e=e2();if(this.options.devTools&&e){if(e.__REDUX_DEVTOOLS_EXTENSION__){var t="object"==typeof this.options.devTools?this.options.devTools:void 0;this.devTools=e.__REDUX_DEVTOOLS_EXTENSION__.connect(A(A({name:this.id,autoPause:!0,stateSanitizer:function(e){return{value:e.value,context:e.context,actions:e.actions}}},t),{features:A({jump:!1,skip:!1},t?t.features:void 0)}),this.machine),this.devTools.init(this.state)}!function(e){if(e2()){var t=function(){var e=e2();if(e&&"__xstate__"in e)return e.__xstate__}();t&&t.register(e)}}(this)}},e.prototype.toJSON=function(){return{id:this.id}},e.prototype[eg]=function(){return this},e.prototype.getSnapshot=function(){return this.status===S.NotStarted?this.initialState:this._state},e.defaultOptions={execute:!0,deferEvents:!0,clock:{setTimeout:function(e,t){return setTimeout(e,t)},clearTimeout:function(e){return clearTimeout(e)}},logger:console.log.bind(console),devTools:!1},e.interpret=e4,e}();function e4(e,t){return new e3(e,t)}function e7(e){var t=k.useRef();return t.current||(t.current={v:e()}),t.current.v}(d=x||(x={}))[d.Effect=1]="Effect",d[d.LayoutEffect=2]="LayoutEffect";var e9=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},e8=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);
1if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},e6=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},te=function(e,t,n){if(n||2==arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))};function tt(e,t){(0,e.exec)(t.context,t._event.data,{action:e,state:t,_event:t._event})()}var tn=function(){return(tn=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},tr=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)0>t.indexOf(r[i])&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n},ti=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a};function to(){return(to=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(null,arguments)}function ta(e,t){if(null==e)return{};var n={};for(var r in e)if(({}).hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}let ts={arr:Array.isArray,obj:e=>"[object Object]"===Object.prototype.toString.call(e),fun:e=>"function"==typeof e,str:e=>"string"==typeof e,num:e=>"number"==typeof e,und:e=>void 0===e,nul:e=>null===e,set:e=>e instanceof Set,map:e=>e instanceof Map,equ(e,t){let n;if(typeof e!=typeof t)return!1;if(ts.str(e)||ts.num(e))return e===t;if(ts.obj(e)&&ts.obj(t)&&Object.keys(e).length+Object.keys(t).length===0)return!0;for(n in e)if(!(n in t))return!1;for(n in t)if(e[n]!==t[n])return!1;return!ts.und(n)||e===t}};function tu(e,t){return ts.und(e)||ts.nul(e)?t:e}function tc(e){return ts.und(e)?[]:ts.arr(e)?e:[e]}function tl(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return ts.fun(e)?e(...n):e}function td(e){let t=(e.to,e.from,e.config,e.onStart,e.onRest,e.onFrame,e.children,e.reset,e.reverse,e.force,e.immediate,e.delay,e.attach,e.destroyed,e.interpolateTo,e.ref,e.lazy,ta(e,["to","from","config","onStart","onRest","onFrame","children","reset","reverse","force","immediate","delay","attach","destroyed","interpolateTo","ref","lazy"]));if(ts.und(t))return to({to:t},e);let n=Object.keys(e).reduce((n,r)=>ts.und(t[r])?to({},n,{[r]:e[r]}):n,{});return to({to:t},n)}class tf{constructor(){this.payload=void 0,this.children=[]}getAnimatedValue(){return this.getValue()}getPayload(){return this.payload||this}attach(){}detach(){}getChildren(){return this.children}addChild(e){0===this.children.length&&this.attach(),this.children.push(e)}removeChild(e){let t=this.children.indexOf(e);this.children.splice(t,1),0===this.children.length&&this.detach()}}class th extends tf{constructor(){super(...arguments),this.payload=[],this.attach=()=>this.payload.forEach(e=>e instanceof tf&&e.addChild(this)),this.detach=()=>this.payload.forEach(e=>e instanceof tf&&e.removeChild(this))}}class tv extends tf{constructor(){super(...arguments),this.payload={},this.attach=()=>Object.values(this.payload).forEach(e=>e instanceof tf&&e.addChild(this)),this.detach=()=>Object.values(this.payload).forEach(e=>e instanceof tf&&e.removeChild(this))}getValue(e){void 0===e&&(e=!1);let t={};for(let n in this.payload){let r=this.payload[n];(!e||r instanceof tf)&&(t[n]=r instanceof tf?r[e?"getAnimatedValue":"getValue"]():r)}return t}getAnimatedValue(){return this.getValue(!0)}}let tp=e=>"undefined"!=typeof window?window.requestAnimationFrame(e):-1,ty=()=>Date.now(),tg=e=>e.current;class tm extends tv{constructor(e,t){super(),this.update=void 0,this.payload=e.style?to({},e,{style:a(e.style)}
1):e,this.update=t,this.attach()}}let tb=e=>ts.fun(e)&&!(e.prototype instanceof k.Component),tw=!1,tE=new Set,tS=()=>{if(!tw)return!1;let e=ty();for(let t of tE){let n=!1;for(let r=0;r<t.configs.length;r++){let i,o,a=t.configs[r];for(let t=0;t<a.animatedValues.length;t++){let r=a.animatedValues[t];if(r.done)continue;let s=a.fromValues[t],u=a.toValues[t],c=r.lastPosition,l=u instanceof tf,d=Array.isArray(a.initialVelocity)?a.initialVelocity[t]:a.initialVelocity;if(l&&(u=u.getValue()),a.immediate||"string"==typeof s||"string"==typeof u){r.setValue(u),r.done=!0;continue}if(void 0!==a.duration)c=s+a.easing((e-r.startTime)/a.duration)*(u-s),i=e>=r.startTime+a.duration;else if(a.decay)c=s+d/(1-.998)*(1-Math.exp(-(1-.998)*(e-r.startTime))),(i=.1>Math.abs(r.lastPosition-c))&&(u=c);else{o=void 0!==r.lastTime?r.lastTime:e,d=void 0!==r.lastVelocity?r.lastVelocity:a.initialVelocity,e>o+64&&(o=e);let t=Math.floor(e-o);for(let e=0;e<t;++e){let e=(-a.tension*(c-u)+-a.friction*d)/a.mass;d+=1*e/1e3,c+=1*d/1e3}let n=!!a.clamp&&0!==a.tension&&(s<u?c>u:c<u),l=Math.abs(d)<=a.precision,f=0===a.tension||Math.abs(u-c)<=a.precision;i=n||l&&f,r.lastVelocity=d,r.lastTime=e}l&&!a.toValues[t].done&&(i=!1),i?(r.value!==u&&(c=u),r.done=!0):n=!0,r.setValue(c),r.lastPosition=c}t.props.onFrame&&(t.values[a.name]=a.interpolation.getValue())}t.props.onFrame&&t.props.onFrame(t.values),n||(tE.delete(t),t.stop(!0))}return tE.size?s?s():tp(tS):tw=!1,tw},tx=e=>{tE.has(e)||tE.add(e),tw||(tw=!0,s?tp(s):tp(tS))},tO=e=>{tE.has(e)&&tE.delete(e)};function tT(e,t,n){if("function"==typeof e)return e;if(Array.isArray(e))return tT({range:e,output:t,extrapolate:n});if(o&&"string"==typeof e.output[0])return o(e);let r=e.output,i=e.range||[0,1],a=e.extrapolateLeft||e.extrapolate||"extend",s=e.extrapolateRight||e.extrapolate||"extend",u=e.easing||(e=>e);return t=>{let n=function(e,t){for(var n=1;n<t.length-1&&!(t[n]>=e);++n);return n-1}(t,i);return function(e,t,n,r,i,o,a,s,u){let c=u?u(e):e;if(c<t){if("identity"===a)return c;"clamp"===a&&(c=t)}if(c>n){if("identity"===s)return c;"clamp"===s&&(c=n)}return r===i?r:t===n?e<=t?r:i:(t===-1/0?c=-c:n===1/0?c-=t:c=(c-t)/(n-t),c=o(c),r===-1/0?c=-c:i===1/0?c+=r:c=c*(i-r)+r,c)}(t,i[n],i[n+1],r[n],r[n+1],u,a,s,e.map)}}class tk extends th{constructor(e,t,n,r){super(),this.calc=void 0,this.payload=e instanceof th&&!(e instanceof tk)?e.getPayload():Array.isArray(e)?e:[e],this.calc=tT(t,n,r)}getValue(){return this.calc(...this.payload.map(e=>e.getValue()))}updateConfig(e,t,n){this.calc=tT(e,t,n)}interpolate(e,t,n){return new tk(this,e,t,n)}}let tP=(e,t,n)=>e&&new tk(e,t,n);class tR extends tf{constructor(e){var t;super(),t=this,this.animatedStyles=new Set,this.value=void 0,this.startPosition=void 0,this.lastPosition=void 0,this.lastVelocity=void 0,this.startTime=void 0,this.lastTime=void 0,this.done=!1,this.setValue=function(e,n){void 0===n&&(n=!0),t.value=e,n&&t.flush()},this.value=e,this.startPosition=e,this.lastPosition=e}flush(){0===this.animatedStyles.size&&function e(t,n){"update"in t?n.add(t):t.getChildren().forEac
1h(t=>e(t,n))}(this,this.animatedStyles),this.animatedStyles.forEach(e=>e.update())}clearStyles(){this.animatedStyles.clear()}getValue(){return this.value}interpolate(e,t,n){return new tk(this,e,t,n)}}class tC extends th{constructor(e){super(),this.payload=e.map(e=>new tR(e))}setValue(e,t){void 0===t&&(t=!0),Array.isArray(e)?e.length===this.payload.length&&e.forEach((e,n)=>this.payload[n].setValue(e,t)):this.payload.forEach(n=>n.setValue(e,t))}getValue(){return this.payload.map(e=>e.getValue())}interpolate(e,t){return new tk(this,e,t)}}let tA=0;class tN{constructor(){this.id=void 0,this.idle=!0,this.hasChanged=!1,this.guid=0,this.local=0,this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.listeners=[],this.queue=[],this.localQueue=void 0,this.getValues=()=>this.interpolations,this.id=tA++}update(e){if(!e)return this;let t=td(e),n=t.delay,r=void 0===n?0:n,i=t.to,o=ta(t,["delay","to"]);if(ts.arr(i)||ts.fun(i))this.queue.push(to({},o,{delay:r,to:i}));else if(i){let e={};Object.entries(i).forEach(t=>{let n=t[0],i=t[1],a=to({to:{[n]:i},delay:tl(r,n)},o),s=e[a.delay]&&e[a.delay].to;e[a.delay]=to({},e[a.delay],a,{to:to({},s,a.to)})}),this.queue=Object.values(e)}return this.queue=this.queue.sort((e,t)=>e.delay-t.delay),this.diff(o),this}start(e){if(this.queue.length){this.idle=!1,this.localQueue&&this.localQueue.forEach(e=>{let t=e.from,n=void 0===t?{}:t,r=e.to,i=void 0===r?{}:r;ts.obj(n)&&(this.merged=to({},n,this.merged)),ts.obj(i)&&(this.merged=to({},this.merged,i))});let t=this.local=++this.guid,n=this.localQueue=this.queue;this.queue=[],n.forEach((r,i)=>{let o=r.delay,a=ta(r,["delay"]),s=r=>{i===n.length-1&&t===this.guid&&r&&(this.idle=!0,this.props.onRest&&this.props.onRest(this.merged)),e&&e()},u=ts.arr(a.to)||ts.fun(a.to);o?setTimeout(()=>{t===this.guid&&(u?this.runAsync(a,s):this.diff(a).start(s))},o):u?this.runAsync(a,s):this.diff(a).start(s)})}else ts.fun(e)&&this.listeners.push(e),this.props.onStart&&this.props.onStart(),tx(this);return this}stop(e){return this.listeners.forEach(t=>t(e)),this.listeners=[],this}pause(e){return this.stop(!0),e&&tO(this),this}runAsync(e,t){var n=this;e.delay;let r=ta(e,["delay"]),i=this.local,o=Promise.resolve(void 0);if(ts.arr(r.to))for(let e=0;e<r.to.length;e++){let t=e,n=to({},r,td(r.to[t]));ts.arr(n.config)&&(n.config=n.config[t]),o=o.then(()=>{if(i===this.guid)return new Promise(e=>this.diff(n).start(e))})}else if(ts.fun(r.to)){let e,t=0;o=o.then(()=>r.to(n=>{let o=to({},r,td(n));if(ts.arr(o.config)&&(o.config=o.config[t]),t++,i===this.guid)return e=new Promise(e=>this.diff(o).start(e))},function(e){return void 0===e&&(e=!0),n.stop(e)}).then(()=>e))}o.then(t)}diff(e){this.props=to({},this.props,e);let t=this.props,n=t.from,r=void 0===n?{}:n,a=t.to,s=void 0===a?{}:a,u=t.config,c=void 0===u?{}:u,l=t.reverse,d=t.attach,f=t.reset,h=t.immediate;if(l){var v=[s,r];r=v[0],s=v[1]}this.merged=to({},r,this.merged,s),this.hasChanged=!1;let p=d&&d(this);if(this.animations=Object.entries(this.merged).reduce((e,t)=>{let n=t[0],a=t[1],s=e[n]||{},u=ts.num(a),l=ts.str(a)&&!a.startsWith("#")&&!/\d/.test(a)&&!i[a],d=ts.arr(a),v=!u&&!d&&!l,y=ts.und(r[n])?a:r[n],g=u||d?a:l?a:1,m=tl(c,n);p&&(g=p.animations[n].parent);let b=s.parent,w=s.interpolation,E=tc(p?g.getPayload():g),S,x=a;v&&(x=o({range:[0,1],output:[a,a]})(1));let O=w&&w.getValue(),T=!ts.und(b)&&s.animatedValues.some(e=>!e.done),k=!ts.equ(x,O),P=!ts.equ(x,s.previous),R=!ts.equ(m,s.config);if(f||P&&k||R){if(u||l)b=w=s.parent||new tR(y);else if(d)b=w=s.parent||new tC(y);else if(v){let e=s.interpolation&&s.interpolation.calc(s.parent.value);e=void 0===e||f?y:e,s.parent?(b=s.parent).setValue(0,!1):b=new tR(0);let t={output:[e,a]};s.interpolation?(w=s.interpolation,s.interpolation.updateConfig(t)):w=b.interpolate(t)}return E=tc(p?g.getPayload():g),S=tc(b.getPayload()),f&&!v&&b.setValue(y,!1),this.hasChanged=!0,S.forEach(e=>{e.startPosition=e.value,e.lastPosition=e.value,e.lastVelocity=T?e.lastVelocity:void 0,e.lastTime=T?e.lastTime:void 0,e.startTime=ty(),e.done=!1,e.animatedStyles.clear()}),tl(h,n)&&b.setValue(v?g:a,!1),to({},e,{[n]:to({},s,{name:n,parent:b,interpolation:w,animatedValues:S,toValues:E,previous:x,config:m,fromValues:tc(b.getValue()),immediate:tl(h,n),initialVelocity:tu(m.velocity,0),clamp:tu(m.clamp,!1),precision:tu(m.precision,.01),tension:tu(m.tension,170),friction:tu(m.friction,26),mass:tu(m.mass,1),duration:m.duration,easing:tu(m.easing,e=>e),decay:m.decay})})}return k?e:(v&&(b.setValue(1,!1),w.updateConfig({output:[x,x]})),b.done=!0,this.hasChanged=!0,to({},e,{[n]:to({},e[n],{previous:x})}))},this.animations),this.hasChanged)for(let e in this.configs=Object.values(this.animations),this.values={},this.interpolations={},this.animations)this.interpolations[e]=this.animations[e].interpolation,this.values[e]=this.animations[e].interpolation.getValue();return this}destroy(){this.stop(),this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.local=0}}let t_=(e,t)=>
1{let n=(0,k.useRef)(!1),r=(0,k.useRef)(),i=ts.fun(t),o=(0,k.useMemo)(()=>{let n;return r.current&&(r.current.map(e=>e.destroy()),r.current=void 0),[Array(e).fill().map((e,r)=>{let o=new tN,a=i?tl(t,r,o):t[r];return 0===r&&(n=a.ref),o.update(a),n||o.start(),o}),n]},[e]),a=o[0],s=o[1];r.current=a,(0,k.useImperativeHandle)(s,()=>({start:()=>Promise.all(r.current.map(e=>new Promise(t=>e.start(t)))),stop:e=>r.current.forEach(t=>t.stop(e)),get controllers(){return r.current}}));let u=(0,k.useMemo)(()=>e=>r.current.map((t,n)=>{t.update(i?tl(e,n,t):e[n]),s||t.start()}),[e]);(0,k.useEffect)(()=>{n.current?i||u(t):s||r.current.forEach(e=>e.start())}),(0,k.useEffect)(()=>(n.current=!0,()=>r.current.forEach(e=>e.destroy())),[]);let c=r.current.map(e=>e.getValues());return i?[c,u,e=>r.current.forEach(t=>t.pause(e))]:c},tj=e=>{let t=ts.fun(e),n=t_(1,t?e:[e]),r=n[0],i=n[1],o=n[2];return t?[r[0],i,o]:r};class tL extends tv{constructor(e){void 0===e&&(e={}),super(),!e.transform||e.transform instanceof tf||(e=r.transform(e)),this.payload=e}}let tD={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},tF="[-+]?\\d*\\.?\\d+",tM=tF+"%";function tI(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return"\\(\\s*("+t.join(")\\s*,\\s*(")+")\\s*\\)"}
1let tV=RegExp("rgb"+tI(tF,tF,tF)),tz=RegExp("rgba"+tI(tF,tF,tF,tF)),tH=RegExp("hsl"+tI(tF,tM,tM)),tB=RegExp("hsla"+tI(tF,tM,tM,tF)),tG=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,tq=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,tU=/^#([0-9a-fA-F]{6})$/,tK=/^#([0-9a-fA-F]{8})$/;function tY(e,t,n){return(n<0&&(n+=1),n>1&&(n-=1),n<1/6)?e+(t-e)*6*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function tW(e,t,n){let r=n<.5?n*(1+t):n+t-n*t,i=2*n-r;return Math.round(255*tY(i,r,e+1/3))<<24|Math.round(255*tY(i,r,e))<<16|Math.round(255*tY(i,r,e-1/3))<<8}function tZ(e){let t=parseInt(e,10);return t<0?0:t>255?255:t}function t$(e){return(parseFloat(e)%360+360)%360/360}function tX(e){let t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function tJ(e){let t=parseFloat(e);return t<0?0:t>100?1:t/100}function tQ(e){let t;let n="number"==typeof e?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=tU.exec(e))?parseInt(t[1]+"ff",16)>>>0:tD.hasOwnProperty(e)?tD[e]:(t=tV.exec(e))?(tZ(t[1])<<24|tZ(t[2])<<16|tZ(t[3])<<8|255)>>>0:(t=tz.exec(e))?(tZ(t[1])<<24|tZ(t[2])<<16|tZ(t[3])<<8|tX(t[4]))>>>0:(t=tG.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+"ff",16)>>>0:(t=tK.exec(e))?parseInt(t[1],16)>>>0:(t=tq.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=tH.exec(e))?(255|tW(t$(t[1]),tJ(t[2]),tJ(t[3])))>>>0:(t=tB.exec(e))?(tW(t$(t[1]),tJ(t[2]),tJ(t[3]))|tX(t[4]))>>>0:null;if(null===n)return e;let r=(4278190080&(n=n||0))>>>24,i=(16711680&n)>>>16,o=(65280&n)>>>8,a=(255&n)/255;return`rgba(${r}, ${i}, ${o}, ${a})`}let t0=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,t1=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,t2=RegExp(`(${Object.keys(tD).join("|")})`,"g"),t5={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},t3=(e,t)=>e+t.charAt(0).toUpperCase()+t.substring(1),t4=["Webkit","Ms","Moz","O"];t5=Object.keys(t5).reduce((e,t)=>(t4.forEach(n=>e[t3(n,t)]=e[t]),e),t5);let t7={};
1a=e=>new tL(e),o=e=>{let t=e.output.map(e=>e.replace(t1,tQ)).map(e=>e.replace(t2,tQ)),n=t[0].match(t0).map(()=>[]);t.forEach(e=>{e.match(t0).forEach((e,t)=>n[t].push(+e))});let r=t[0].match(t0).map((t,r)=>tT(to({},e,{output:n[r]})));return e=>{let n=0;return t[0].replace(t0,()=>r[n++](e)).replace(/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,(e,t,n,r,i)=>`rgba(${Math.round(t)}, ${Math.round(n)}, ${Math.round(r)}, ${i})`)}},i=tD,r={fn:(e,t)=>{if(!e.nodeType||void 0===e.setAttribute)return!1;{let a=t.style,s=t.children,u=t.scrollTop,c=t.scrollLeft,l=ta(t,["style","children","scrollTop","scrollLeft"]),d="filter"===e.nodeName||e.parentNode&&"filter"===e.parentNode.nodeName;for(let t in void 0!==u&&(e.scrollTop=u),void 0!==c&&(e.scrollLeft=c),void 0!==s&&(e.textContent=s),a)if(a.hasOwnProperty(t)){var n,r,i=0===t.indexOf("--"),o=(n=t,null==(r=a[t])||"boolean"==typeof r||""===r?"":i||"number"!=typeof r||0===r||t5.hasOwnProperty(n)&&t5[n]?(""+r).trim():r+"px");"float"===t&&(t="cssFloat"),i?e.style.setProperty(t,o):e.style[t]=o}for(let t in l){let n=d?t:t7[t]||(t7[t]=t.replace(/([A-Z])/g,e=>"-"+e.toLowerCase()));void 0!==e.getAttribute(n)&&e.setAttribute(n,l[t])}return}},transform:e=>e};let t9=(f=e=>(0,k.forwardRef)((t,n)=>{let i=function(){let e=(0,k.useState)(!1)[1];return(0,k.useCallback)(()=>e(e=>!e),[])}(),o=(0,k.useRef)(!0),a=(0,k.useRef)(null),s=(0,k.useRef)(null),u=(0,k.useCallback)(e=>{let t=a.current;a.current=new tm(e,()=>{let e=!1;s.current&&(e=r.fn(s.current,a.current.getAnimatedValue())),s.current&&!1!==e||i()}),t&&t.detach()},[]);(0,k.useEffect)(()=>()=>{o.current=!1,a.current&&a.current.detach()},[]),(0,k.useImperativeHandle)(n,()=>tg(s,o,i)),u(t);let c=a.current.getValue(),l=(c.scrollTop,c.scrollLeft,ta(c,["scrollTop","scrollLeft"])),d=tb(e)?void 0:e=>s.current=(n&&(ts.fun(n)?n(e):ts.obj(n)&&(n.current=e)),e);return k.createElement(e,to({},l,{ref:d}))}),void 0===(h=!1)&&(h=!0),e=>(ts.arr(e)?e:Object.keys(e)).reduce((e,t)=>{let n=h?t[0].toLowerCase()+t.substring(1):t;return e[n]=f(n),e},f))(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]);function t8(e,t){return e.map(function(e,n){return e+t[n]})}function t6(e,t){return e.map(function(e,n){return e-t[n]})}function ne(e){return Math.hypot.apply(Math,e)}function nt(e){return Math.sign?Math.sign(e):Number(e>0)-Number(e<0)||+e}function nn(e,t,n){return 0===t||Math.abs(t)===1/0?Math.pow(e,5*n):e*t*n/(t+n*e)}function nr(e,t,n,r){return(void 0===r&&(r=.15),0===r)?Math.max(t,Math.min(e,n)):e<t?-nn(t-e,n-t,r)+t:e>n?+nn(e-n,n-t,r)+n:e}function ni(){return(ni=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function no(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function na(e){if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ns(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function nu(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return ns(e,void 0);var n=Object.prototype.toString.call(e).slice(8,-1);if("Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ns(e,void 0)}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}function nc(){}function nl(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return 0===t.length?nc:1===t.length?t[0]:function(){for(var e,n,r=nu(t);!(n=r()).done;)e=n.value.apply(this,arguments)||e;return e}}
1function nd(e,t){if(void 0===e){if(void 0===t)throw Error("Must define fallback value if undefined is expected");e=t}return Array.isArray(e)?e:[e,e]}function nf(e){if("function"!=typeof e)return e;for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.apply(void 0,n)}function nh(e,t){void 0===e&&(e={});for(var n={},r=0,i=Object.entries(t);r<i.length;r++){var o=i[r],a=o[0],s=o[1];switch(typeof s){case"function":n[a]=s.call(n,e[a],a,e);break;case"object":n[a]=nh(e[a],s);break;case"boolean":s&&(n[a]=e[a])}}return n}var nv=ni({},{threshold:function(e){return void 0===e&&(e=0),nd(e)},rubberband:function(e){switch(void 0===e&&(e=0),e){case!0:return nd(.15);case!1:return nd(0);default:return nd(e)}},enabled:function(e){return void 0===e&&(e=!0),e},triggerAllEvents:function(e){return void 0===e&&(e=!1),e},initial:function(e){return(void 0===e&&(e=0),"function"==typeof e)?e:nd(e)}},{axis:!0,lockDirection:function(e){return void 0===e&&(e=!1),e},bounds:function(e){if(void 0===e&&(e={}),"function"==typeof e)return function(t){return nv.bounds(e(t))};var t=e,n=t.left,r=t.right,i=t.top,o=t.bottom;return[[void 0===n?-1/0:n,void 0===r?1/0:r],[void 0===i?-1/0:i,void 0===o?1/0:o]]}}),np="undefined"!=typeof window&&window.document&&window.document.createElement,ny={enabled:function(e){return void 0===e&&(e=!0),e},domTarget:!0,window:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}(function(e){return void 0===e&&(e=np?window:void 0),e}),eventOptions:function(e){var t=void 0===e?{}:e,n=t.passive,r=t.capture;return{passive:void 0===n||n,capture:void 0!==r&&r}}},ng=ni({},nv,{threshold:function(e,t,n){var r=n.filterTaps,i=void 0!==r&&r,o=n.lockDirection,a=n.axis,s=nd(e,i?3:void 0!==o&&o?1:(void 0===a?void 0:a)?1:0);return this.filterTaps=i||s[0]+s[1]>0,s},swipeVelocity:function(e){return void 0===e&&(e=.5),nd(e)},swipeDistance:function(e){return void 0===e&&(e=60),nd(e)},delay:function(e){switch(void 0===e&&(e=0),e){case!0:return 180;case!1:return 0;default:return e}}});function nm(e){var t,n=e.domTarget,r=e.eventOptions,i=e.window,o=e.enabled,a=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)t.indexOf(n=o[r])>=0||(i[n]=e[n]);return i}(e,["domTarget","eventOptions","window","enabled"]),s=nh({domTarget:n,eventOptions:r,window:i,enabled:o},ny);return s.drag=(void 0===(t=a)&&(t={}),nh(t,ng)),s}function nb(e){return ni({_active:!1,_blocked:!1,_intentional:[!1,!1],_movement:[0,0],_initial:[0,0],_bounds:[[-1/0,1/0],[-1/0,1/0]],_lastEventType:void 0,event:void 0,intentional:!1,values:[0,0],velocities:[0,0],delta:[0,0],movement:[0,0],offset:[0,0],lastOffset:[0,0],direction:[0,0],initial:[0,0],previous:[0,0],first:!1,last:!1,active:!1,timeStamp:0,startTime:0,elapsedTime:0,cancel:nc,canceled:!1,memo:void 0,args:void 0},e)}function nw(){return{shared:{hovering:!1,scrolling:!1,wheeling:!1,dragging:!1,moving:!1,pinching:!1,touches:0,buttons:0,down:!1,shiftKey:!1,altKey:!1,metaKey:!1,ctrlKey:!1},drag:nb({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0,_isTap:!0,_delayedEvent:!1,_pointerId:void 0,tap:!1,swipe:[0,0]}),pinch:nb({da:[0,0],vdva:[0,0],origin:void 0,turns:0}),wheel:nb({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0}),move:nb({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0}),scroll:nb({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0})}}var nE=new Map,nS=function(){function e(e,t){var n=this;void 0===t&&(t=[]),this.controller=e,this.args=t,this.debounced=!0,this.setTimeout=function(e,t){var r;void 0===t&&(t=140),clearTimeout(n.controller.timeouts[n.stateKey]);for(var i=arguments.length,o=Array(i>2?i-2:0),a=2;a<i;a++)o[a-2]=arguments[a];n.controller.timeouts[n.stateKey]=(r=window).setTimeout.apply(r,[e,t].concat(o))},this.clearTimeout=function(){clearTimeout(n.controller.timeouts[n.stateKey])},this.fireGestureHandler=function(e){if(void 0===e&&(e=!1),n.state._blocked)return n.debounced||(n.state._active=!1,n.clean()),null;if(!e&&!n.state.intentional&&!n.config.triggerAllEvents)return null;if(n.state.intentional){var t=n.state.active,r=n.state._active;n.state.active=r,n.state.first=r&&!t,n.state.last=t&&!r,n.controller.state.shared[n.ingKey]=r}var i=ni({},n.controller.state.shared,n.state,n.mapStateValues(n.state)),o=n.handler(i);return n.state.memo=void 0!==o?o:n.state.memo,n.state._active||n.clean(),i}}var t=e.prototype;return t.updateSharedState=function(e){Object.assign(this.controller.state.shared,e)},t.updateGestureState=function(e){Object.assign(this.state,e)},t.checkIntentionality=function(e,t){return{_intentional:e,_blocked:!1}},t.getMovement=function(e){var t,n,r,i,o=this.config,a=o.initial,s=o.bounds,u=o.rubberband,c=o.threshold,l=this.state,d=l._bounds,f=l._initial,h=l._active,v=l._intentional,p=l.lastOffset,y=l.movement,g=this.getInternalMovement(e,this.state),m=!1===v[0]?nx(g[0],c[0]):v[0],b=!1===v[1]?nx(g[1],c[1]):v[1],w=this.checkIntentionality([m,b],g);if(w._blocked)return ni({},w,{_movement:g,delta:[0,0]});var E=w._intentional;!1!==E[0]&&!1===v[0]&&(n=nf(a,this.state),t=nf(s,this.state),f[0]=n[0],d[0]=t[0]),!1!==E[1]&&!1===v[1]&&(n=null!=(r=n)?r:nf(a,this.state),t=null!=(i=t)?i:nf(s,this.state),f[1]=n[1],d[1]=t[1]);var S=[!1!==E[0]?g[0]-E[0]:f[0],!1!==E[1]?g[1]-E[1]:f[1]],x=t8(S,p),O=h?u:[0,0];return S=nO(d,t8(S,f),O),ni({},w,{intentional:!1!==E[0]||!1!==E[1],_initial:f,_movement:g,movement:S,values:e,offset:nO(d,x,O),delta:t6(S,y)})},t.clean=function(){this.clearTimeout()},function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}
1(e.prototype,[{key:"config",get:function(){return this.controller.config[this.stateKey]}},{key:"enabled",get:function(){return this.controller.config.enabled&&this.config.enabled}},{key:"state",get:function(){return this.controller.state[this.stateKey]}},{key:"handler",get:function(){return this.controller.handlers[this.stateKey]}}]),e}();function nx(e,t){return Math.abs(e)>=t&&nt(e)*t}function nO(e,t,n){var r=t[0],i=t[1],o=n[0],a=n[1],s=e[0],u=s[0],c=s[1],l=e[1],d=l[0],f=l[1];return[nr(r,u,c,o),nr(i,d,f,a)]}function nT(e,t,n){var r=e.state,i=e.args,o=t.timeStamp,a=t.type,s=r.values,u=n?0:o-r.startTime;return{_lastEventType:a,event:t,timeStamp:o,elapsedTime:u,args:i,previous:s}}var nk=function(e){var t=this;this.classes=e,this.bind=function(){for(var e={},n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];for(var o,a=nu(t.classes);!(o=a()).done;)new o.value(t,r).addBindings(e);for(var s=0,u=Object.entries(t.nativeRefs);s<u.length;s++){var c=u[s];nC(e,c[0],function(e,t){return function(n){for(var r=arguments.length,i=Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];return e.call.apply(e,[this,ni({},t,{event:n})].concat(i))}}(c[1],ni({},t.state.shared,{args:r})))}return t.config.domTarget?function(e,t){var n=e.config,r=e.domListeners,i=nR(n);if(!i)throw Error("domTarget must be defined");var o=n.eventOptions;nN(i,nP(r),o);for(var a=0,s=Object.entries(t);a<s.length;a++){var u=s[a],c=u[0],l=u[1],d=c.slice(2).toLowerCase();r.push([d,nl.apply(void 0,l)])}nA(i,r,o)}(t,e):function(e,t){for(var n=e.config,r={},i=n.eventOptions.capture?"Capture":"",o=0,a=Object.entries(t);o<a.length;o++){var s=a[o],u=s[0],c=s[1],l=Array.isArray(c)?c:[c];r[u+i]=nl.apply(void 0,l)}return r}(t,e)},this.effect=function(){return t.config.domTarget&&t.bind(),t.clean},this.clean=function(){var e=nR(t.config),n=t.config.eventOptions;e&&nN(e,nP(t.domListeners),n),Object.values(t.timeouts).forEach(clearTimeout),function(e){var t=e.config,n=t.window,r=t.eventOptions,i=e.windowListeners;if(n){for(var o in i)nN(n,i[o],r);e.windowListeners={}}}(t)},this.state=nw(),this.timeouts={},this.domListeners=[],this.windowListeners={}};function nP(e){return void 0===e&&(e=[]),e.splice(0,e.length)}function nR(e){var t=e.domTarget;return t&&"current"in t?t.current:t}function nC(e,t,n){e[t]||(e[t]=[]),e[t].push(n)}function nA(e,t,n){void 0===t&&(t=[]),void 0===n&&(n={});for(var r,i=nu(t);!(r=i()).done;){var o=r.value,a=o[0],s=o[1];e.addEventListener(a,s,n)}}function nN(e,t,n){void 0===t&&(t=[]),void 0===n&&(n={});for(var r,i=nu(t);!(r=i()).done;){var o=r.value,a=o[0],s=o[1];e.removeEventListener(a,s,n)}}function n_(){}function nj(e){if("touches"in e){var t=e.targetTouches,n=e.changedTouches;return t.length>0?t:n}return null}function nL(e){var t="buttons"in e?e.buttons:0,n=nj(e),r=n&&n.length||0;return{touches:r,down:r>0||t>0,buttons:t,shiftKey:e.shiftKey,altKey:e.altKey,metaKey:e.metaKey,ctrlKey:e.ctrlKey}}function nD(e){var t=nj(e),n=t?t[0]:e;return[n.clientX,n.clientY]}var nF=function(e){function t(){var t;return t=e.apply(this,arguments)||this,t.ingKey="dragging",t.stateKey="drag",t.onDragStart=function(e){if(t.enabled&&!t.state._active){var n,r,i,o,a;n=t.controller,r=t.stateKey,i=[["pointermove",t.onDragChange],["pointerup",t.onDragEnd],["pointercancel",t.onDragEnd]],o=n.config,a=n.windowListeners,void 0===i&&(i=[]),o.window&&(nN(o.window,a[r],o.eventOptions),nA(o.window,a[r]=i,o.eventOptions)),t.updateGestureState({_pointerId:e.pointerId}),t.config.delay>0?(t.state._delayedEvent=!0,"persist"in e&&"function"==typeof e.persist&&e.persist(),t.setTimeout(t.startDrag.bind(na(t)),t.config.delay,e)):t.startDrag(e)}},t.onDragChange=function(e){if(!t.state.canceled&&e.pointerId===t.state._pointerId){if(!t.state._active){t.state._delayedEvent&&(t.clearTimeout(),t.startDrag(e));return}var n=nL(e);if(!n.down){t.onDragEnd(e);return}t.updateSharedState(n);var r=nD(e),i=t.getKinematics(r,e),o=nT(na(t),e),a=t.state._isTap,s=ne(i._movement);a&&s>=3&&(a=!1),t.updateGestureState(ni({},o,i,{_isTap:a})),t.fireGestureHandler()}},t.onDragEnd=function(e){if(e.pointerId===t.state._pointerId){t.state._active=!1,t.updateSharedState({down:!1,buttons:0,touches:0});var n=t.state._isTap,r=t.state.velocities,i=r[0],o=r[1],a=t.state.movement,s=a[0],u=a[1],c=t.state._intentional,l=c[0],d=c[1],f=t.config.swipeVelocity,h=f[0],v=f[1],p=t.config.swipeDistance,y=p[0],g=p[1],m=ni({},nT(na(t),e),t.getMovement(t.state.values)),b=[0,0];m.elapsedTime<220&&(!1!==l&&Math.abs(i)>h&&Math.abs(s)>y&&(b[0]=nt(i)),!1!==d&&Math.abs(o)>v&&Math.abs(u)>g&&(b[1]=nt(o))),t.updateGestureState(ni({},m,{tap:n,swipe:b})),t.fireGestureHandler(!0===n)}},t.clean=function(){var n,r,i,o;
1e.prototype.clean.call(na(t)),t.state._delayedEvent=!1,n=t.controller,r=t.stateKey,i=n.config,o=n.windowListeners,i.window&&(nN(i.window,o[r],i.eventOptions),delete o[r])},t.onCancel=function(){t.state.canceled||(t.updateGestureState({canceled:!0}),t.state._active=!1,t.updateSharedState({down:!1,buttons:0,touches:0}),requestAnimationFrame(function(){return t.fireGestureHandler()}))},t.onClick=function(e){t.state._isTap||e.stopPropagation()},t}no(t,e);var n=t.prototype;return n.startDrag=function(e){var t,n,r=nD(e);this.updateSharedState(nL(e)),this.updateGestureState(ni({},(t=this.state.offset,n=e.timeStamp,ni({},nw()[this.stateKey],{_active:!0,values:r,initial:r,offset:t,lastOffset:t,startTime:n})),nT(this,e,!0),{_pointerId:e.pointerId,cancel:this.onCancel})),this.updateGestureState(this.getMovement(r)),this.fireGestureHandler()},n.addBindings=function(e){nC(e,"onPointerDown",this.onDragStart),this.config.filterTaps&&nC(e,this.controller.config.eventOptions.capture?"onClick":"onClickCapture",this.onClick)},t}(function(e){function t(){return e.apply(this,arguments)||this}no(t,e);var n=t.prototype;return n.getInternalMovement=function(e,t){return t6(e,t.initial)},n.checkIntentionality=function(e,t){if(!1===e[0]&&!1===e[1])return{_intentional:e,axis:this.state.axis};var n=t.map(Math.abs),r=n[0],i=n[1],o=this.state.axis||(r>i?"x":r<i?"y":void 0);return this.config.axis||this.config.lockDirection?o?this.config.axis&&o!==this.config.axis?{_intentional:e,_blocked:!0,axis:o}:(e["x"===o?1:0]=!1,{_intentional:e,_blocked:!1,axis:o}):{_intentional:[!1,!1],_blocked:!1,axis:o}:{_intentional:e,_blocked:!1,axis:o}},n.getKinematics=function(e,t){var n=this.getMovement(e);if(!n._blocked){var r,i,o,a,s,u,c,l=t.timeStamp-this.state.timeStamp;Object.assign(n,(r=n.movement,a=0===(o=ne(i=n.delta))?0:1/o,s=0===l?0:1/l,u=i.map(function(e){return s*e}),c=i.map(function(e){return a*e}),{velocities:u,velocity:s*o,distance:ne(r),direction:c}))}return n},n.mapStateValues=function(e){return{xy:e.values,vxvy:e.velocities}},t}(nS)),nM=["input","select","textarea","a[href]","button","[tabindex]:not(slot)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])',"details>summary:first-of-type","details"],nI=nM.join(","),nV="undefined"==typeof Element,nz=nV?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,nH=!nV&&Element.prototype.getRootNode?function(e){return e.getRootNode()}:function(e){return e.ownerDocument},nB=function(e,t,n){var r=Array.prototype.slice.apply(e.querySelectorAll(nI));return t&&nz.call(e,nI)&&r.unshift(e),r=r.filter(n)},nG=function e(t,n,r){for(var i=[],o=Array.from(t);o.length;){var a=o.shift();if("SLOT"===a.tagName){var s=a.assignedElements(),u=e(s.length?s:a.children,!0,r);r.flatten?i.push.apply(i,u):i.push({scope:a,candidates:u})}else{nz.call(a,nI)&&r.filter(a)&&(n||!t.includes(a))&&i.push(a);var c=a.shadowRoot||"function"==typeof r.getShadowRoot&&r.getShadowRoot(a),l=!r.shadowRootFilter||r.shadowRootFilter(a);if(c&&l){var d=e(!0===c?a.children:c.children,!0,r);r.flatten?i.push.apply(i,d):i.push({scope:a,candidates:d})}else o.unshift.apply(o,a.children)}}return i},nq=function(e,t){return e.tabIndex<0&&(t||/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||e.isContentEditable)&&isNaN(parseInt(e.getAttribute("tabindex"),10))?0:e.tabIndex},nU=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},nK=function(e){return"INPUT"===e.tagName},nY=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]},nW=function(e){if(!e.name)return!0;var t,n=e.form||nH(e),r=function(e){return n.querySelectorAll('input[type="radio"][name="'+e+'"]')};if("undefined"!=typeof window&&void 0!==window.CSS&&"function"==typeof window.CSS.escape)t=r(window.CSS.escape(e.name));else try{t=r(e.name)}catch(e){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",e.message),!1}var i=nY(t,e.form);return!i||i===e}
1,nZ=function(e){var t=e.getBoundingClientRect(),n=t.width,r=t.height;return 0===n&&0===r},n$=function(e,t){var n=t.displayCheck,r=t.getShadowRoot;if("hidden"===getComputedStyle(e).visibility)return!0;var i=nz.call(e,"details>summary:first-of-type")?e.parentElement:e;if(nz.call(i,"details:not([open]) *"))return!0;var o=nH(e).host,a=(null==o?void 0:o.ownerDocument.contains(o))||e.ownerDocument.contains(e);if(n&&"full"!==n){if("non-zero-area"===n)return nZ(e)}else{if("function"==typeof r){for(var s=e;e;){var u=e.parentElement,c=nH(e);if(u&&!u.shadowRoot&&!0===r(u))return nZ(e);e=e.assignedSlot?e.assignedSlot:u||c===e.ownerDocument?u:c.host}e=s}if(a)return!e.getClientRects().length}return!1},nX=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if("FIELDSET"===t.tagName&&t.disabled){for(var n=0;n<t.children.length;n++){var r=t.children.item(n);if("LEGEND"===r.tagName)return!!nz.call(t,"fieldset[disabled] *")||!r.contains(e)}return!0}t=t.parentElement}return!1},nJ=function(e,t){return!(t.disabled||nK(t)&&"hidden"===t.type||n$
1(t,e)||"DETAILS"===t.tagName&&Array.prototype.slice.apply(t.children).some(function(e){return"SUMMARY"===e.tagName})||nX(t))},nQ=function(e,t){var n;return!(nK(n=t)&&"radio"===n.type&&!nW(n)||0>nq(t))&&!!nJ(e,t)},n0=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!isNaN(t)||t>=0},n1=function e(t){var n=[],r=[];return t.forEach(function(t,i){var o=!!t.scope,a=o?t.scope:t,s=nq(a,o),u=o?e(t.candidates):a;0===s?o?n.push.apply(n,u):n.push(a):r.push({documentOrder:i,tabIndex:s,item:t,isScope:o,content:u})}),r.sort(nU).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(n)},n2=function(e,t){if(t=t||{},!e)throw Error("No node provided");return!1!==nz.call(e,nI)&&nQ(t,e)},n5=nM.concat("iframe").join(","),n3=function(e,t){if(t=t||{},!e)throw Error("No node provided");return!1!==nz.call(e,n5)&&nJ(t,e)};/*!
2* focus-trap 6.9.4
3* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
4*/function n4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function n7(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?n4(Object(n),!0).forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):n4(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var n9=(v=[],{activateTrap:function(e){if(v.length>0){var t=v[v.length-1];t!==e&&t.pause()}var n=v.indexOf(e);-1===n||v.splice(n,1),v.push(e)},deactivateTrap:function(e){var t=v.indexOf(e);-1!==t&&v.splice(t,1),v.length>0&&v[v.length-1].unpause()}}),n8=function(e){return setTimeout(e,0)},n6=function(e,t){var n=-1;return e.every(function(e,r){return!t(e)||(n=r,!1)}),n},re=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return"function"==typeof e?e.apply(void 0,n):e},rt=function(e){return e.target.shadowRoot&&"function"==typeof e.composedPath?e.composedPath()[0]:e.target},rn=function(e,t){var n,r=(null==t?void 0:t.document)||document,i=n7({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0},t),o={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0},a=function(e,t,n){return e&&void 0!==e[t]?e[t]:i[n||t]},s=function(e){return o.containerGroups.findIndex(function(t){var n=t.container,r=t.tabbableNodes;return n.contains(e)||r.find(function(t){return t===e})})},u=function(e){var t=i[e];if("function"==typeof t){for(var n=arguments.length,o=Array(n>1?n-1:0),a=1;a<n;a++)o[a-1]=arguments[a];t=t.apply(void 0,o)}if(!0===t&&(t=void 0),!t){if(void 0===t||!1===t)return t;throw Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var s=t;if("string"==typeof t&&!(s=r.querySelector(t)))throw Error("`".concat(e,"` as selector refers to no known node"));return s},c=function(){var e=u("initialFocus");if(!1===e)return!1;if(void 0===e){if(s(r.activeElement)>=0)e=r.activeElement;else{var t=o.tabbableGroups[0];e=t&&t.firstTabbableNode||u("fallbackFocus")}}if(!e)throw Error("Your focus-trap needs to have at least one focusable element");return e},l=function(){if(o.containerGroups=o.containers.map(function(e){var t,n,r,o,a=(t=e,n1((n=(n=i.tabbableOptions)||{}).getShadowRoot?nG([t],n.includeContainer,{filter:nQ.bind(null,n),flatten:!1,getShadowRoot:n.getShadowRoot,shadowRootFilter:n0}):nB(t,n.includeContainer,nQ.bind(null,n)))),s=(r=e,(o=(o=i.tabbableOptions)||{}).getShadowRoot?nG([r],o.includeContainer,{filter:nJ.bind(null,o),flatten:!0,getShadowRoot:o.getShadowRoot}):nB(r,o.includeContainer,nJ.bind(null,o)));return{container:e,tabbableNodes:a,focusableNodes:s,firstTabbableNode:a.length>0?a[0]:null,lastTabbableNode:a.length>0?a[a.length-1]:null,nextTabbableNode:function(e){var t=!(arguments.length>1)||void 0===arguments[1]||arguments[1],n=s.findIndex(function(t){return t===e});return n<0?void 0:t?s.slice(n+1).find(function(e){return n2(e,i.tabbableOptions)}):s.slice(0,n).reverse().find(function(e){return n2(e,i.tabbableOptions)})}}}),o.tabbableGroups=o.containerGroups.filter(function(e){return e.tabbableNodes.length>0}),o.tabbableGroups.length<=0&&!u("fallbackFocus"))throw Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times")},d=function e(t){if(!1!==t&&t!==r.activeElement){if(!t||!t.focus){e(c());return}t.focus({preventScroll:!!i.preventScroll}),o.mostRecentlyFocusedNode=t,t.tagName&&"input"===t.tagName.toLowerCase()&&"function"==typeof t.select&&t.select()}},f=function(e){var t=u("setReturnFocus",e);return t||!1!==t&&e},h=function(e){var t=rt(e);if(!(s(t)>
4=0)){if(re(i.clickOutsideDeactivates,e)){n.deactivate({returnFocus:i.returnFocusOnDeactivate&&!n3(t,i.tabbableOptions)});return}re(i.allowOutsideClick,e)||e.preventDefault()}},v=function(e){var t=rt(e),n=s(t)>=0;n||t instanceof Document?n&&(o.mostRecentlyFocusedNode=t):(e.stopImmediatePropagation(),d(o.mostRecentlyFocusedNode||c()))},p=function(e){var t=rt(e);l();var n=null;if(o.tabbableGroups.length>0){var r=s(t),a=r>=0?o.containerGroups[r]:void 0;if(r<0)n=e.shiftKey?o.tabbableGroups[o.tabbableGroups.length-1].lastTabbableNode:o.tabbableGroups[0].firstTabbableNode;else if(e.shiftKey){var c=n6(o.tabbableGroups,function(e){return t===e.firstTabbableNode});if(c<0&&(a.container===t||n3(t,i.tabbableOptions)&&!n2(t,i.tabbableOptions)&&!a.nextTabbableNode(t,!1))&&(c=r),c>=0){var f=0===c?o.tabbableGroups.length-1:c-1;n=o.tabbableGroups[f].lastTabbableNode}}else{var h=n6(o.tabbableGroups,function(e){return t===e.lastTabbableNode});if(h<0&&(a.container===t||n3(t,i.tabbableOptions)&&!n2(t,i.tabbableOptions)&&!a.nextTabbableNode(t))&&(h=r),h>=0){var v=h===o.tabbableGroups.length-1?0:h+1;n=o.tabbableGroups[v].firstTabbableNode}}}else n=u("fallbackFocus");n&&(e.preventDefault(),d(n))},y=function(e){if(("Escape"===e.key||"Esc"===e.key||27===e.keyCode)&&!1!==re(i.escapeDeactivates,e)){e.preventDefault(),n.deactivate();return}if("Tab"===e.key||9===e.keyCode){p(e);return}},g=function(e){s(rt(e))>=0||re(i.clickOutsideDeactivates,e)||re(i.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())},m=function(){if(o.active)return n9.activateTrap(n),o.delayInitialFocusTimer=i.delayInitialFocus?n8(function(){d(c())}):d(c()),r.addEventListener("focusin",v,!0),r.addEventListener("mousedown",h,{capture:!0,passive:!1}),r.addEventListener("touchstart",h,{capture:!0,passive:!1}),r.addEventListener("click",g,{capture:!0,passive:!1}),r.addEventListener("keydown",y,{capture:!0,passive:!1}),n},b=function(){if(o.active)return r.removeEventListener("focusin",v,!0),r.removeEventListener("mousedown",h,!0),r.removeEventListener("touchstart",h,!0),r.removeEventListener("click",g,!0),r.removeEventListener("keydown",y,!0),n};return(n={get active(){return o.active},get paused(){return o.paused},activate:function(e){if(o.active)return this;var t=a(e,"onActivate"),n=a(e,"onPostActivate"),i=a(e,"checkCanFocusTrap");i||l(),o.active=!0,o.paused=!1,o.nodeFocusedBeforeActivation=r.activeElement,t&&t();var s=function(){i&&l(),m(),n&&n()};return i?i(o.containers.concat()).then(s,s):s(),this},deactivate:function(e){if(!o.active)return this;var t=n7({onDeactivate:i.onDeactivate,onPostDeactivate:i.onPostDeactivate,checkCanReturnFocus:i.checkCanReturnFocus},e);clearTimeout(o.delayInitialFocusTimer),o.delayInitialFocusTimer=void 0,b(),o.active=!1,o.paused=!1,n9.deactivateTrap(n);var r=a(t,"onDeactivate"),s=a(t,"onPostDeactivate"),u=a(t,"checkCanReturnFocus"),c=a(t,"returnFocus","returnFocusOnDeactivate");r&&r();var l=function(){n8(function(){c&&d(f(o.nodeFocusedBeforeActivation)),s&&s()})};return c&&u?u(f(o.nodeFocusedBeforeActivation)).then(l,l):l(),this},pause:function(){return o.paused||!o.active||(o.paused=!0,b()),this},unpause:function(){return o.paused&&o.active&&(o.paused=!1,l(),m()),this}
4,updateContainerElements:function(e){var t=[].concat(e).filter(Boolean);return o.containers=t.map(function(e){return"string"==typeof e?r.querySelector(e):e}),o.active&&l(),this}}).updateContainerElements(e),n},rr=!1;if("undefined"!=typeof window){var ri={get passive(){rr=!0;return}};window.addEventListener("testPassive",null,ri),window.removeEventListener("testPassive",null,ri)}var ro="undefined"!=typeof window&&window.navigator&&window.navigator.platform&&(/iP(ad|hone|od)/.test(window.navigator.platform)||"MacIntel"===window.navigator.platform&&window.navigator.maxTouchPoints>1),ra=[],rs=!1,ru=-1,rc=void 0,rl=void 0,rd=function(e){return ra.some(function(t){return!!(t.options.allowTouchMove&&t.options.allowTouchMove(e))})},rf=function(e){var t=e||window.event;return!!rd(t.target)||t.touches.length>1||(t.preventDefault&&t.preventDefault(),!1)},rh=function(e){if(void 0===rl){var t=!!e&&!0===e.reserveScrollBarGap,n=window.innerWidth-document.documentElement.clientWidth;t&&n>0&&(rl=document.body.style.paddingRight,document.body.style.paddingRight=n+"px")}void 0===rc&&(rc=document.body.style.overflow,document.body.style.overflow="hidden")},rv=function(){void 0!==rl&&(document.body.style.paddingRight=rl,rl=void 0),void 0!==rc&&(document.body.style.overflow=rc,rc=void 0)},rp=function(e,t){var n=e.targetTouches[0].clientY-ru;return!rd(e.target)&&(t&&0===t.scrollTop&&n>0?rf(e):t&&t.scrollHeight-t.scrollTop<=t.clientHeight&&n<0?rf(e):(e.stopPropagation(),!0))},ry=function(e,t){if(!e){console.error("disableBodyScroll unsuccessful - targetElement must be provided when calling disableBodyScroll on IOS devices.");return}!ra.some(function(t){return t.targetElement===e})&&(ra=[].concat(function(e){if(!Array.isArray(e))return Array.from(e);for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}(ra),[{targetElement:e,options:t||{}}]),ro?(e.ontouchstart=function(e){1===e.targetTouches.length&&(ru=e.targetTouches[0].clientY)},e.ontouchmove=function(t){1===t.targetTouches.length&&rp(t,e)},rs||(document.addEventListener("touchmove",rf,rr?{passive:!1}:void 0),rs=!0)):rh(t))},rg=function(e){if(!e){console.error("enableBodyScroll unsuccessful - targetElement must be provided when calling enableBodyScroll on IOS devices.");return}ra=ra.filter(function(t){return t.targetElement!==e}),ro?(e.ontouchstart=null,e.ontouchmove=null,rs&&0===ra.length&&(document.removeEventListener("touchmove",rf,rr?{passive:!1}:void 0),rs=!1)):ra.length||rv()},rm=[],rb="ResizeObserver loop completed with undelivered notifications.",rw=function(){var e;"function"==typeof ErrorEvent?e=new ErrorEvent("error",{message:rb}):((e=document.createEvent("Event")).initEvent("error",!1,!1),e.message=rb),window.dispatchEvent(e)};(p=O||(O={})).BORDER_BOX="border-box",p.CONTENT_BOX="content-box",p.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box";var rE=function(e){return Object.freeze(e)},rS=function(e,t){this.inlineSize=e,this.blockSize=t,rE(this)},rx=function(){function e(e,t,n,r){return this.x=e,this.y=t,this.width=n,this.height=r,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,rE(this)}return e.prototype.toJSON=function(){return{x:this.x,y:this.y,top:this.top,right:this.right,bottom:this.bottom,left:this.left,width:this.width,height:this.height}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e}(),rO=function(e){return e instanceof SVGElement&&"getBBox"in e},rT=function(e){if(rO(e)){var t=e.getBBox(),n=t.width,r=t.height;return!n&&!r}var i=e.offsetWidth,o=e.offsetHeight;return!(i||o||e.getClientRects().length)},rk=function(e){if(e instanceof Element)return!0;var t,n=null===(t=null==e?void 0:e.ownerDocument)||void 0===t?void 0:t.defaultView;return!!(n&&e instanceof n.Element)},rP=function(e){switch(e.tagName){case"INPUT":if("image"!==e.type)break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},rR="undefined"!=typeof window?window:{},rC=new WeakMap,rA=/auto|scroll/,rN=/^tb|vertical/,r_=/msie|trident/i.test(rR.navigator&&rR.navigator.userAgent),rj=function(e){return parseFloat(e||"0")},rL=function(e,t,n){return void 0===e&&(e=0),void 0===t&&(t=0),void 0===n&&(n=!1),new rS((n?t:e)||0,(n?e:t)||0)},rD=rE({devicePixelContentBoxSize:rL(),borderBoxSize:rL(),contentBoxSize:rL(),contentRect:new rx(0,0,0,0)}),rF=function(e,t){if(void 0===t&&(t=!1),rC.has(e)&&!t)return rC.get(e);if(rT(e))return rC.set(e,rD),rD;var n=getComputedStyle(e),r=rO(e)&&e.ownerSVGElement&&e.getBBox(),i=!r_&&"border-box"===n.boxSizing,o=rN.test(n.writingMode||""),a=!r&&rA.test(n.overflowY||""),s=!r&&rA.test(n.overflowX||""),u=r?0:rj(n.paddingTop),c=r?0:rj(n.paddingRight),l=r?0:rj(n.paddingBottom),d=r?0:rj(n.paddingLeft),f=r?0:rj(n.borderTopWidth),h=r?0:rj(n.borderRightWidth),v=r?0:rj(n.borderBottomWidth),p=r?0:rj(n.borderLeftWidth),y=d+c,g=u+l,m=p+h,b=f+v,w=s?e.offsetHeight-b-e.clientHeight:0,E=a?e.offsetWidth-m-e.clientWidth:0,S=r?r.width:rj(n.width)-(i?y+m:0)-E,x=r?r.height:rj(n.height)-(i?g+b:0)-w,O=S+y+E+m,T=x+g+w+b,k=rE({devicePixelContentBoxSize:rL(Math.round(S*devicePixelRatio),Math.round(x*devicePixelRatio),o),borderBoxSize:rL(O,T,o),contentBoxSize:rL(S,x,o),contentRect:new rx(d,u,S,x)});return rC.set(e,k),k},rM=function(e,t,n){var r=rF(e,n),i=r.borderBoxSize,o=r.contentBoxSize,a=r.devicePixelContentBoxSize;switch(t){case O.DEVICE_PIXEL_CONTENT_BOX:return a;case O.BORDER_BOX:return i;default:return o}},rI=function(e){var t=rF(e);this.target=e,this.contentRect=t.contentRect,this.borderBoxSize=rE([t.borderBoxSize]),this.contentBoxSize=rE([t.contentBoxSize]),this.devicePixelContentBoxSize=rE([t.devicePixelContentBoxSize])},rV=function(e){if(rT(e))return 1/0;for(var t=0,n=e.parentNode;n;)t+=1,n=n.parentNode;return t},rz=function(){var e=1/0,t=[];rm.forEach(function(n){if(0!==n.activeTargets.length){var r=[];
4n.activeTargets.forEach(function(t){var n=new rI(t.target),i=rV(t.target);r.push(n),t.lastReportedSize=rM(t.target,t.observedBox),i<e&&(e=i)}),t.push(function(){n.callback.call(n.observer,r,n.observer)}),n.activeTargets.splice(0,n.activeTargets.length)}});for(var n=0;n<t.length;n++)(0,t[n])();return e},rH=function(e){rm.forEach(function(t){t.activeTargets.splice(0,t.activeTargets.length),t.skippedTargets.splice(0,t.skippedTargets.length),t.observationTargets.forEach(function(n){n.isActive()&&(rV(n.target)>e?t.activeTargets.push(n):t.skippedTargets.push(n))})})},rB=function(){var e=0;for(rH(0);rm.some(function(e){return e.activeTargets.length>0});)rH(e=rz());return rm.some(function(e){return e.skippedTargets.length>0})&&rw(),e>0},rG=[],rq=function(e){if(!T){var t=0,n=document.createTextNode("");new MutationObserver(function(){return rG.splice(0).forEach(function(e){return e()})}).observe(n,{characterData:!0}),T=function(){n.textContent="".concat(t?t--:t++)}}rG.push(e),T()},rU=function(e){rq(function(){requestAnimationFrame(e)})},rK=0,rY={attributes:!0,characterData:!0,childList:!0,subtree:!0},rW=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],rZ=function(e){return void 0===e&&(e=0),Date.now()+e},r$=!1,rX=new(function(){function e(){var e=this;this.stopped=!0,this.listener=function(){return e.schedule()}}return e.prototype.run=function(e){var t=this;if(void 0===e&&(e=250),!r$){r$=!0;var n=rZ(e);rU(function(){var r=!1;try{r=rB()}finally{if(r$=!1,e=n-rZ(),!rK)return;r?t.run(1e3):e>0?t.run(e):t.start()}})}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var e=this,t=function(){return e.observer&&e.observer.observe(document.body,rY)};document.body?t():rR.addEventListener("DOMContentLoaded",t)},e.prototype.start=function(){var e=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),rW.forEach(function(t){return rR.addEventListener(t,e.listener,!0)}))},e.prototype.stop=function(){var e=this;this.stopped||(this.observer&&this.observer.disconnect(),rW.forEach(function(t){return rR.removeEventListener(t,e.listener,!0)}),this.stopped=!0)},e}()),rJ=function(e){!rK&&e>0&&rX.start(),(rK+=e)||rX.stop()},rQ=function(){function e(e,t){this.target=e,this.observedBox=t||O.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var e,t=rM(this.target,this.observedBox,!0);return rO(e=this.target)||rP(e)||"inline"!==getComputedStyle(e).display||(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},e}(),r0=function(e,t){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=e,this.callback=t},r1=new WeakMap,r2=function(e,t){for(var n=0;n<e.length;n+=1)if(e[n].target===t)return n;return -1},r5=function(){function e(){}return e.connect=function(e,t){var n=new r0(e,t);r1.set(e,n)},e.observe=function(e,t,n){var r=r1.get(e),i=0===r.observationTargets.length;0>r2(r.observationTargets,t)&&(i&&rm.push(r),r.observationTargets.push(new rQ(t,n&&n.box)),rJ(1),rX.schedule())},e.unobserve=function(e,t){var n=r1.get(e),r=r2(n.observationTargets,t),i=1===n.observationTargets.length;r>=0&&(i&&rm.splice(rm.indexOf(n),1),n.observationTargets.splice(r,1),rJ(-1))},e.disconnect=function(e){var t=this,n=r1.get(e);n.observationTargets.slice().forEach(function(n){return t.unobserve(e,n.target)}),n.activeTargets.splice(0,n.activeTargets.length)},e}(),r3=function(){function e(e){if(0==arguments.length)throw TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if("function"!=typeof e)throw TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");r5.connect(this,e)}return e.prototype.observe=function(e,t){if(0==arguments.length)throw TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!rk(e))throw TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");r5.observe(this,e,t)},e.prototype.unobserve=function(e){if(0==arguments.length)throw TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!rk(e))throw TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");r5.unobserve(this,e)},e.prototype.disconnect=function(){r5.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e}();function r4(e){return A(A({type:K},e),{toJSON:function(){e.onDone,e.onError;var t=N(e,["onDone","onError"]);return A(A({},t),{type:K,src:function(e){if("string"==typeof e){var t={type:e};return t.toString=function(){return e},t}return e}(e.src)})}})}var r7={},r9=function(e){return"#"===e[0]},r8=function(){function e(t,n,r,i){void 0===r&&(r="context"in t?t.context:void 0);var o,a=this;this.config=t,this._context=r,this.order=-1,this.__xstatenode=!0,this.__cache={events:void 0,relativeValue:new Map,initialStateValue:void 0,initialState:void 0,on:void 0,transitions:void 0,candidates:{},delayedTransitions:void 0},this.idMap={},this.tags=[],this.options=Object.assign({actions:{},guards:{},services:{},activities:{},delays:{}},n),this.parent=null==i?void 0:i.parent,this.key=this.config.key||(null==i?void 0:i.key)||this.config.id||"(machine)",this.machine=this.parent?this.parent.machine:this,this.path=this.parent?this.parent.path.concat(this.key):[],this.delimiter=this.config.delimiter||(this.parent?this.parent.delimiter:"."),this.id=this.config.id||L([this.machine.key],j(this.path),!1).join(this.delimiter),this.version=this.parent?this.parent.version:this.config.version,this.type=this.config.type||(this.config.parallel?"parallel":this.config.states&&Object.keys(this.config.states).length?"compound":this.config.history?"history":"atomic"),this.schema=this.parent?this.machine.schema:null!==(o=this.config.schema)&&void 0!==o?o:{},this.description=this.config.description,this.initial=this.config.initial,this.states=this.config.states?er(this.config.states,function(t,n){var r,i=new e(t,{},void 0,{parent:a,key:n});return Object.assign(a.idMap,A(((r={})[i.id]=i,r),i.idMap)),i}):r7;var s=0;!function e(t){var n,r;t.order=s++;try{for(var i=_(eR(t)),o=i.next();!o.done;o=i.next()){var a=o.value;e(a)}}catch(e){n={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}(this),this.history=!0===this.config.history?"shallow":this.config.history||
4!1,this._transient=!!this.config.always||!!this.config.on&&(Array.isArray(this.config.on)?this.config.on.some(function(e){return""===e.event}):""in this.config.on),this.strict=!!this.config.strict,this.onEntry=eu(this.config.entry||this.config.onEntry).map(function(e){return eM(e)}),this.onExit=eu(this.config.exit||this.config.onExit).map(function(e){return eM(e)}),this.meta=this.config.meta,this.doneData="final"===this.type?this.config.data:void 0,this.invoke=eu(this.config.invoke).map(function(e,t){if(em(e)){var n,r,i=eT(a.id,t);return a.machine.options.services=A(((n={})[i]=e,n),a.machine.options.services),r4({src:i,id:i})}if(ep(e.src)){var i=e.id||eT(a.id,t);return r4(A(A({},e),{id:i,src:e.src}))}if(em(e.src)||ev(e.src)){var i=e.id||eT(a.id,t);return a.machine.options.services=A(((r={})[i]=e.src,r),a.machine.options.services),r4(A(A({id:i},e),{src:i}))}var o=e.src;return r4(A(A({id:eT(a.id,t)},e),{src:o}))}),this.activities=eu(this.config.activities).concat(this.invoke).map(function(e){return eV(e)}),this.transition=this.transition.bind(this),this.tags=eu(this.config.tags)}return e.prototype._init=function(){this.__cache.transitions||(function e(t){var n=[t];return eP(t)?n:n.concat(es(eC(t).map(e)))})(this).forEach(function(e){return e.on})},e.prototype.withConfig=function(t,n){var r=this.options,i=r.actions,o=r.activities,a=r.guards,s=r.services,u=r.delays;return new e(this.config,{actions:A(A({},i),t.actions),activities:A(A({},o),t.activities),guards:A(A({},a),t.guards),services:A(A({},s),t.services),delays:A(A({},u),t.delays)},null!=n?n:this.context)},e.prototype.withContext=function(t){return new e(this.config,this.options,t)},Object.defineProperty(e.prototype,"context",{get:function(){return ev(this._context)?this._context():this._context},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"definition",{get:function(){return{id:this.id,key:this.key,version:this.version,context:this.context,type:this.type,initial:this.initial,history:this.history,states:er(this.states,function(e){return e.definition}),on:this.on,transitions:this.transitions,entry:this.onEntry,exit:this.onExit,activities:this.activities||[],meta:this.meta,order:this.order||-1,data:this.doneData,invoke:this.invoke,description:this.description,tags:this.tags}},enumerable:!1,configurable:!0}),e.prototype.toJSON=function(){return this.definition},Object.defineProperty(e.prototype,"on",{get:function(){if(this.__cache.on)return this.__cache.on;var e=this.transitions;return this.__cache.on=e.reduce(function(e,t){return e[t.eventType]=e[t.eventType]||[],e[t.eventType].push(t),e},{})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"after",{get:function(){return this.__cache.delayedTransitions||(this.__cache.delayedTransitions=this.getDelayedTransitions(),this.__cache.delayedTransitions)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"transitions",{get:function(){return this.__cache.transitions||(this.__cache.transitions=this.formatTransitions(),this.__cache.transitions)},enumerable:!1,configurable:!0}),e.prototype.getCandidates=function(e){if(this.__cache.candidates[e])return this.__cache.candidates[e];var t=""===e,n=this.transitions.filter(function(n){var r=n.eventType===e;return t?r:r||"*"===n.eventType});return this.__cache.candidates[e]=n,n},e.prototype.getDelayedTransitions=function(){var e=this,t=this.config.after;if(!t)return[];var n=function(t,n){var r,i,o,a=(r=ev(t)?"".concat(e.id,":delay[").concat(n,"]"):t,i=e.id,"".concat(b.After,"(").concat(r,")").concat(i?"#".concat(i):""));return e.onEntry.push({to:(o={delay:t}).to,type:z,event:ev(a)?a:eb(a),delay:o?o.delay:void 0,id:o&&void 0!==o.id?o.id:ev(a)?a.name:Q(a)}),e.onExit.push({type:H,sendId:a}),a};return(eh(t)?t.map(function(e,t){var r=n(e.delay,t);return A(A({},e),{event:r})}):es(Object.keys(t).map(function(e,r){var i=t[e],o=ep(i)?{target:i}:i,a=isNaN(+e)?e:+e,s=n(a,r);return eu(o).map(function(e){return A(A({},e),{event:s,delay:a})})}))).map(function(t){var n=t.delay;return A(A({},e.formatTransition(t)),{delay:n})})},e.prototype.getStateNodes=function(e){var t,n=this;if(!e)return[];var r=e instanceof eU?e.value:et(e,this.delimiter);if(ep(r)){var i=this.getStateNode(r).initial;
vendor: 1,946 bytes, line 4
4return void 0!==i?this.getStateNodes(((t={})[r]=i,t)):[this,this.states[r]]}var o=Object.keys(r),a=[this];return a.push.apply(a,L([],j(es(o.map(function(e){return n.getStateNode(e).getStateNodes(r[e])}))),!1)),a},e.prototype.handles=function(e){var t=Q(e);return this.events.includes(t)},e.prototype.resolveState=function(e){var t=e instanceof eU?e:eU.create(e),n=Array.from(eA([],this.getStateNodes(t.value)));return new eU(A(A({},t),{value:this.resolve(t.value),configuration:n,done:ej(n,this),tags:eL(n),machine:this.machine}))},e.prototype.transitionLeafNode=function(e,t,n){var r=this.getStateNode(e).next(t,n);return r&&r.transitions.length?r:this.next(t,n)},e.prototype.transitionCompoundNode=function(e,t,n){var r=Object.keys(e),i=this.getStateNode(r[0])._transition(e[r[0]],t,n);return i&&i.transitions.length?i:this.next(t,n)},e.prototype.transitionParallelNode=function(e,t,n){var r,i,o={};try{for(var a=_(Object.keys(e)),s=a.next();!s.done;s=a.next()){var u=s.value,c=e[u];if(c){var l=this.getStateNode(u)._transition(c,t,n);l&&(o[u]=l)}}}catch(e){r={error:e}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}var d=Object.keys(o).map(function(e){return o[e]}),f=es(d.map(function(e){return e.transitions}));if(!d.some(function(e){return e.transitions.length>0}))return this.next(t,n);var h=es(Object.keys(o).map(function(e){return o[e].configuration}));return{transitions:f,exitSet:es(d.map(function(e){return e.exitSet})),configuration:h,source:t,actions:es(Object.keys(o).map(function(e){return o[e].actions}))}},e.prototype._transition=function(e,t,n){return ep(e)?this.transitionLeafNode(e,t,n):1===Object.keys(e).length?this.transitionCompoundNode(e,t,n):this.transitionParallelNode(e,t,n)},e.prototype.getTransitionData=function(e,t){return this._transition(e.value,e,ew(t))},e.prototype.next=function(e,t){var n,r,i,o=this,a=t.name,s=[],u=[];try{for(var c=_(this.getCandidates(a)),l=c.next();!l.done;
4l=c.next()){var d=l.value,f=d.cond,h=d.in,v=e.context,p=!h||(ep(h)&&r9(h)?e.matches(et(this.getStateNodeById(h).path,this.delimiter)):J(et(h,this.delimiter),eo(this.path.slice(0,-2))(e.value))),y=!1;try{y=!f||eS(this.machine,f,v,t,e)}catch(e){throw Error("Unable to evaluate guard '".concat(f.name||f.type,"' in transition for event '").concat(a,"' in state node '").concat(this.id,"':\n").concat(e.message))}if(y&&p){void 0!==d.target&&(u=d.target),s.push.apply(s,L([],j(d.actions),!1)),i=d;break}}}catch(e){n={error:e}}finally{try{l&&!l.done&&(r=c.return)&&r.call(c)}finally{if(n)throw n.error}}if(i){if(!u.length)return{transitions:[i],exitSet:[],configuration:e.value?[this]:[],source:e,actions:s};var g=es(u.map(function(t){return o.getRelativeStateNodes(t,e.historyValue)})),m=!!i.internal;return{transitions:[i],exitSet:m?[]:es(u.map(function(e){return o.getPotentiallyReenteringNodes(e)})),configuration:g,source:e,actions:s}}},e.prototype.getPotentiallyReenteringNodes=function(e){if(this.order<e.order)return[this];for(var t=[],n=this;n&&n!==e;)t.push(n),n=n.parent;return n!==e?[]:(t.push(e),t)},e.prototype.getActions=function(e,t,n,r,i,o,a){var s,u,c,l,d=this,f=o?eA([],this.getStateNodes(o.value)):[],h=new Set;try{for(var v=_(Array.from(e).sort(function(e,t){return e.order-t.order})),p=v.next();!p.done;p=v.next()){var y=p.value;(!e_(f,y)||e_(n.exitSet,y)||y.parent&&h.has(y.parent))&&h.add(y)}}catch(e){s={error:e}}finally{try{p&&!p.done&&(u=v.return)&&u.call(v)}finally{if(s)throw s.error}}try{for(var g=_(f),m=g.next();!m.done;m=g.next()){var y=m.value;(!e_(e,y)||e_(n.exitSet,y.parent))&&n.exitSet.push(y)}}catch(e){c={error:e}}finally{try{m&&!m.done&&(l=g.return)&&l.call(g)}finally{if(c)throw c.error}}n.exitSet.sort(function(e,t){return t.order-e.order});var w=Array.from(h).sort(function(e,t){return e.order-t.order}),E=new Set(n.exitSet),S=es(w.map(function(e){var t=[];if("final"!==e.type)return t;var o=e.parent;if(!o.parent)return t;
4t.push(ez(e.id,e.doneData),ez(o.id,e.doneData?ec(e.doneData,r,i):void 0));var a=o.parent;return"parallel"===a.type&&eC(a).every(function(e){return ej(n.configuration,e)})&&t.push(ez(a.id)),t})),x=w.map(function(e){var t=e.onEntry,n=e.activities.map(function(e){var t;return t=eV(e),{type:b.Start,activity:t,exec:void 0}});return{type:"entry",actions:eI(a?L(L([],j(t),!1),j(n),!1):L(L([],j(n),!1),j(t),!1),d.machine.options.actions)}}).concat({type:"state_done",actions:S.map(function(e){var t;return{type:V,event:"function"==typeof e?e:eb(e),delay:void 0,id:null==t?void 0:t.id}})}),O=Array.from(E).map(function(e){return{type:"exit",actions:eI(L(L([],j(e.onExit),!1),j(e.activities.map(function(e){var t;return t=ev(e)?e:eV(e),{type:b.Stop,activity:t,exec:void 0}})),!1),d.machine.options.actions)}}).concat({type:"transition",actions:eI(n.actions,this.machine.options.actions)}).concat(x);if(t){var T=eI(es(L([],j(e),!1).sort(function(e,t){return t.order-e.order}).map(function(e){return e.onExit})),this.machine.options.actions).filter(function(e){return!ek(e)});return O.concat({type:"stop",actions:T})}return O},e.prototype.transition=function(e,t,n,r){void 0===e&&(e=this.initialState);var i,o,a=ew(t);if(e instanceof eU)o=void 0===n?e:this.resolveState(eU.from(e,n));else{var s=ep(e)?this.resolve(en(this.getResolvedPath(e))):this.resolve(e),u=null!=n?n:this.machine.context;o=this.resolveState(eU.from(s,u))}if(this.strict&&!this.events.includes(a.name)&&(i=a.name,!/^(done|error)\./.test(i)))throw Error("Machine '".concat(this.id,"' does not accept event '").concat(a.name,"'"));var c=this._transition(o.value,o,a)||{transitions:[],configuration:[],exitSet:[],source:o,actions:[]},l=eA([],this.getStateNodes(o.value)),d=c.configuration.length?eA(l,c.configuration):l;return c.configuration=L([],j(d),!1),this.resolveTransition(c,o,o.context,r,a)},e.prototype.resolveRaisedTransition=function(e,t,n,r){var i,o=e.actions;return(e=this.transition(e,t,void 0,r))._event=n,e.event=n.data,(i=e.actions).unshift.apply(i,L([],j(o),!1)),e},e.prototype.resolveTransition=function(e,t,n,r,i){var o,a,s,u,c,l,d=this;void 0===i&&(i=eD);var f=e.configuration,h=!t||e.transitions.length>0,v=h?e.configuration:t?t.configuration:[],p=ej(v,this),y=h?(a=eA([o=this.machine],f),function e(t,n){var r=n.get(t);if(!r)return{};if("compound"===t.type){var i=r[0];if(!i)return{};if(eP(i))return i.key}var o={};return r.forEach(function(t){o[t.key]=e(t,n)}),o}(o,eN(a))):void 0,g=t?t.historyValue?t.historyValue:e.source?this.machine.historyValue(t.value):void 0:void 0,m=this.getActions(new Set(v),p,e,n,i,t,r),b=t?A({},t.activities):{};try{for(var w=_(m),E=w.next();!E.done;E=w.next()){var S=E.value;try{for(var x=(c=void 0,_(S.actions)),O=x.next();!O.done;O=x.next()){var T=O.value;T.type===M?b[T.activity.id||T.activity.type]=T:T.type===I&&(b[T.activity.id||T.activity.type]=!1)}}catch(e){c={error:e}}finally{try{O&&!O.done&&(l=x.return)&&l.call(x)}finally{if(c)throw c.error}}}}catch(e){s={error:e}}finally{try{E&&!E.done&&(u=w.return)&&u.call(w)}finally{if(s)throw s.error}}var k=j(eq(this,t,n,i,m,r,this.machine.config.predictableActionArguments||this.machine.config.preserveActionOrder),2),P=k[0],R=k[1],C=j(function(e,t){var n,r,i=j([[],[]],2),o=i[0],a=i[1];try{for(var s=_(e),u=s.next();!u.done;u=s.next()){var c=u.value;t(c)?o.push(c):a.push(c)}}catch(e){n={error:e}}finally{try{u&&!u.done&&(r=s.return)&&r.call(s)}finally{if(n)throw n.error}}return[o,a]}(P,ek),2),N=C[0],L=C[1],D=P.filter(function(e){var t;return e.type===M&&(null===(t=e.activity)||void 0===t?void 0:t.type)===K}).reduce(function(e,t){var n,r,o,a,s,u,c,l;return e[t.activity.id]=(n=t.activity,r=d.machine,o=i,s=ex(n.src),u=null===(a=null==r?void 0:r.options.services)||void 0===a?void 0:a[s.type],c=n.data?ec(n.data,R,o):void 0,(l=u?eJ(u,n.id,c):eX(n.id)).meta=n,l),e},t?A({},t.children):{}),F=new eU({value:y||t.value,context:R,_event:i,_sessionid:t?t._sessionid:null,historyValue:y?g?{current:y,states:function e(t,n){return er(t.states,function(t,r){if(t){var i=(ep(n)?void 0:n[r])||(t?t.current:void 0);if(i)return{current:i,states:e(t,i)}}})}(g,y)}:void 0:t?t.historyValue:void 0,history:!y||e.source?t:void 0,actions:y?L:[],activities:y?b:t?t.activities:{},events:[],configuration:v,transitions:e.transitions,children:D,done:p,tags:eL(v),machine:this}),V=n!==R;
4F.changed=i.name===Z||V;var z=F.history;z&&delete z.history;var H=!p&&(this._transient||f.some(function(e){return e._transient}));if(!h&&(!H||""===i.name))return F;var G=F;if(!p)for(H&&(G=this.resolveRaisedTransition(G,{type:B},i,r));N.length;){var q=N.shift();G=this.resolveRaisedTransition(G,q._event,i,r)}var U=G.changed||(z?!!G.actions.length||V||typeof z.value!=typeof G.value||!function e(t,n){if(t===n)return!0;if(void 0===t||void 0===n)return!1;if(ep(t)||ep(n))return t===n;var r=Object.keys(t),i=Object.keys(n);return r.length===i.length&&r.every(function(r){return e(t[r],n[r])})}(G.value,z.value):void 0);return G.changed=U,G.history=z,G},e.prototype.getStateNode=function(e){if(r9(e))return this.machine.getStateNodeById(e);if(!this.states)throw Error("Unable to retrieve child state '".concat(e,"' from '").concat(this.id,"'; no child states exist."));var t=this.states[e];if(!t)throw Error("Child state '".concat(e,"' does not exist on '").concat(this.id,"'"));return t},e.prototype.getStateNodeById=function(e){var t=r9(e)?e.slice(1):e;if(t===this.id)return this;var n=this.machine.idMap[t];if(!n)throw Error("Child state node '#".concat(t,"' does not exist on machine '").concat(this.id,"'"));return n},e.prototype.getStateNodeByPath=function(e){if("string"==typeof e&&r9(e))try{return this.getStateNodeById(e.slice(1))}catch(e){}for(var t=ee(e,this.delimiter).slice(),n=this;t.length;){var r=t.shift();if(!r.length)break;n=n.getStateNode(r)}return n},e.prototype.resolve=function(e){var t,n=this;if(!e)return this.initialStateValue||r7;switch(this.type){case"parallel":return er(this.initialStateValue,function(t,r){return t?n.getStateNode(r).resolve(e[r]||t):r7});case"compound":if(ep(e)){var r=this.getStateNode(e);if("parallel"===r.type||"compound"===r.type)return(t={})[e]=r.initialStateValue,t;return e}if(!Object.keys(e).length)return this.initialStateValue||{};return er(e,function(e,t){return e?n.getStateNode(t).resolve(e):r7});default:return e||r7}},e.prototype.getResolvedPath=function(e){if(r9(e)){var t=this.machine.idMap[e.slice(1)];if(!t)throw Error("Unable to find state node '".concat(e,"'"));return t.path}return ee(e,this.delimiter)},Object.defineProperty(e.prototype,"initialStateValue",{get:function(){var e,t;if(this.__cache.initialStateValue)return this.__cache.initialStateValue;if("parallel"===this.type)t=ei(this.states,function(e){return e.initialStateValue||r7},function(e){return"history"!==e.type});else if(void 0!==this.initial){if(!this.states[this.initial])throw Error("Initial state '".concat(this.initial,"' not found on '").concat(this.key,"'"));t=eP(this.states[this.initial])?this.initial:((e={})[this.initial]=this.states[this.initial].initialStateValue,e)}else t={};return this.__cache.initialStateValue=t,this.__cache.initialStateValue},enumerable:!1,configurable:!0}),e.prototype.getInitialState=function(e,t){this._init();var n=this.getStateNodes(e);return this.resolveTransition({configuration:n,exitSet:[],transitions:[],source:void 0,actions:[]},void 0,null!=t?t:this.machine.context,void 0)},Object.defineProperty(e.prototype,"initialState",{get:function(){var e=this.initialStateValue;if(!e)throw Error("Cannot retrieve initial state from simple state '".concat(this.id,"'."));return this.getInitialState(e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"target",{get:function(){var e;if("history"===this.type){var t=this.config;e=ep(t.target)&&r9(t.target)?en(this.machine.getStateNodeById(t.target).path.slice(this.path.length-1)):t.target}return e},enumerable:!1,configurable:!0}),e.prototype.getRelativeStateNodes=function(e,t,n){return void 0===n&&(n=!0),n?"history"===e.type?e.resolveHistory(t):e.initialStateNodes:[e]},Object.defineProperty(e.prototype,"initialStateNodes",{get:function(){var e=this;return eP(this)?[this]:"compound"!==this.type||this.initial?es(ea(this.initialStateValue).map(function(t){return e.getFromRelativePath(t)})):[this]},enumerable:!1,configurable:!0}),e.prototype.getFromRelativePath=function(e){if(!e.length)return[this];var t=j(e),n=t[0],r=t.slice(1);if(!this.states)throw Error("Cannot retrieve subPath '".concat(n,"' from node with no states"));var i=this.getStateNode(n);if("history"===i.type)return i.resolveHistory();if(!this.states[n])throw Error("Child state '".concat(n,"' does not exist on '").concat(this.id,"'"));return this.states[n].getFromRelativePath(r)},e.prototype.historyValue=function(e){if(Object.keys(this.states).length)return{current:e||this.initialStateValue,states:ei(this.states,function(t,n){if(!e)return t.historyValue();var r=ep(e)?void 0:e[n];return t.historyValue(r||t.initialStateValue)},function(e){return!e.history})}},e.prototype.resolveHistory=function(e){var t,n=this;if("history"!==this.type)return[this];var r=this.parent;if(!e){var i=this.target;return i?es(ea(i).map(function(e){return r.getFromRelativePath(e)})):r.initialStateNodes}var o=(t=r.path,function(e){var n,r,i=e;try{for(var o=_(t),a=o.next();!a.done;a=o.next()){var s=a.value;i=i.states[s]}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return i})(e).current;return ep(o)?[r.getStateNode(o)]:es(ea(o).map(function(e){return"deep"===n.history?r.getFromRelativePath(e):[r.states[e[0]]]}))},Object.defineProperty(e.prototype,"stateIds",{get:function(){var e=this,t=es(Object.keys(this.states).map(function(t){return e.states[t].stateIds}));return[this.id].concat(t)}
4,enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"events",{get:function(){if(this.__cache.events)return this.__cache.events;var e,t,n,r,i=this.states,o=new Set(this.ownEvents);if(i)try{for(var a=_(Object.keys(i)),s=a.next();!s.done;s=a.next()){var u=i[s.value];if(u.states)try{for(var c=(n=void 0,_(u.events)),l=c.next();!l.done;l=c.next()){var d=l.value;o.add("".concat(d))}}catch(e){n={error:e}}finally{try{l&&!l.done&&(r=c.return)&&r.call(c)}finally{if(n)throw n.error}}}}catch(t){e={error:t}}finally{try{s&&!s.done&&(t=a.return)&&t.call(a)}finally{if(e)throw e.error}}return this.__cache.events=Array.from(o)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ownEvents",{get:function(){return Array.from(new Set(this.transitions.filter(function(e){return!(!e.target&&!e.actions.length&&e.internal)}).map(function(e){return e.eventType})))},enumerable:!1,configurable:!0}),e.prototype.resolveTarget=function(e){var t=this;if(void 0!==e)return e.map(function(e){if(!ep(e))return e;var n=e[0]===t.delimiter;if(n&&!t.parent)return t.getStateNodeByPath(e.slice(1));var r=n?t.key+e:e;if(!t.parent)return t.getStateNodeByPath(r);try{return t.parent.getStateNodeByPath(r)}catch(e){throw Error("Invalid transition definition for state node '".concat(t.id,"':\n").concat(e.message))}})},e.prototype.formatTransition=function(e){var t=this,n=function(e){if(void 0!==e&&""!==e)return eu(e)}(e.target),r="internal"in e?e.internal:!n||n.some(function(e){return ep(e)&&e[0]===t.delimiter}),i=this.machine.options.guards,o=this.resolveTarget(n),a=A(A({},e),{actions:eI(eu(e.actions)),cond:ey(e.cond,i),target:o,source:this,internal:r,eventType:e.event,toJSON:function(){return A(A({},a),{target:a.target?a.target.map(function(e){return"#".concat(e.id)}):void 0,source:"#".concat(t.id)})}});return a},e.prototype.formatTransitions=function(){var e,t,n,r=this;if(this.config.on){if(Array.isArray(this.config.on))n=this.config.on;else{var i=this.config.on,o=i["*"],a=N(i,["*"]);n=es(Object.keys(a).map(function(e){return eE(e,a[e])}).concat(eE("*",void 0===o?[]:o)))}}else n=[];var s=this.config.always?eE("",this.config.always):[],u=this.config.onDone?eE(String(ez(this.id)),this.config.onDone):[],c=es(this.invoke.map(function(e){var t=[];return e.onDone&&t.push.apply(t,L([],j(eE(String(eH(e.id)),e.onDone)),!1)),e.onError&&t.push.apply(t,L([],j(eE(String(eB(e.id)),e.onError)),!1)),t})),l=this.after,d=es(L(L(L(L([],j(u),!1),j(c),!1),j(n),!1),j(s),!1).map(function(e){return eu(e).map(function(e){return r.formatTransition(e)})}));try{for(var f=_(l),h=f.next();!h.done;h=f.next()){var v=h.value;d.push(v)}}catch(t){e={error:t}}finally{try{h&&!h.done&&(t=f.return)&&t.call(f)}finally{if(e)throw e.error}}return d},e}();function r6(){return(r6=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function ie(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)t.indexOf(n=o[r])>=0||(i[n]=e[n]);return i}var it="undefined"!=typeof window?k.useLayoutEffect:k.useEffect;function ir(e,t,n){return t=(t=+t)==t?t:0,n=(n=+n)==n?n:0,(e=+e)==e&&(e=(e=e<=n?e:n)>=t?e:t),e}function ii(e){var t=Math.round(e);if(Number.isNaN(e))throw TypeError("Found a NaN! Check your snapPoints / defaultSnap / snapTo ");return t}var io={box:"border-box"};function ia(e,t){var n=t.label,r=t.enabled,i=t.resizeSourceRef,o=(0,k.useState)(0),a=o[0],s=o[1];(0,k.useDebugValue)(n+": "+a);var u=(0,k.useCallback)(function(e){s(e[0].borderBoxSize[0].blockSize),i.current="element"},[i]);return it(function(){if(e.current&&r){var t=new r3(u);return t.observe(e.current,io),function(){t.disconnect()}}},[e,u,r]),r?a:0}function is(e){return void 0===e&&(e=1e3),new Promise(function(t){return setTimeout(t,e)})}var iu={DRAG:{target:"#overlay.dragging",actions:"onOpenEnd"}},ic={RESIZE:{target:"#overlay.resizing",actions:"onOpenEnd"}},il=(y={id:"overlay",initial:"closed",context:{initialState:"CLOSED"},states:{closed:{on:{OPEN:"opening",CLOSE:void 0}},opening:{initial:"start",states:{start:{invoke:{src:"onOpenStart",onDone:"transition"}},transition:{always:[{target:"immediately",cond:"initiallyOpen"},{target:"smoothly",cond:"initiallyClosed"}]},immediately:{initial:"open",states:{open:{invoke:{src:"openImmediately",onDone:"activating"}},activating:{invoke:{src:"activate",onDone:"#overlay.opening.end"},on:r6({},iu,ic)}}},smoothly:{initial:"visuallyHidden",states:{visuallyHidden:{invoke:{src:"renderVisuallyHidden",onDone:"activating"}},activating:{invoke:{src:"activate",onDone:"open"}},open:{invoke:{src:"openSmoothly",onDone:"#overlay.opening.end"},on:r6({},iu,ic)}}},end:{invoke:{src:"onOpenEnd",onDone:"done"},on:{CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:r6({},{CLOSE:{target:"#overlay.closing",actions:"onOpenCancel"}}),onDone:"open"},open:{on:{DRAG:"#overlay.dragging",SNAP:"snapping",RESIZE:"resizing"}},dragging:{on:{SNAP:"snapping"}},snapping:{initial:"start",states:{start:{invoke:{src:"onSnapStart",onDone:"snappingSmoothly"}
4,entry:[{type:G,assignment:{y:function(e,t){return t.payload.y},velocity:function(e,t){return t.payload.velocity},snapSource:function(e,t){var n=t.payload.source;return void 0===n?"custom":n}}}]},snappingSmoothly:{invoke:{src:"snapSmoothly",onDone:"end"}},end:{invoke:{src:"onSnapEnd",onDone:"done"},on:{RESIZE:"#overlay.resizing",SNAP:"#overlay.snapping",CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:{SNAP:{target:"snapping",actions:"onSnapEnd"},RESIZE:{target:"#overlay.resizing",actions:"onSnapCancel"},DRAG:{target:"#overlay.dragging",actions:"onSnapCancel"},CLOSE:{target:"#overlay.closing",actions:"onSnapCancel"}},onDone:"open"},resizing:{initial:"start",states:{start:{invoke:{src:"onResizeStart",onDone:"resizingSmoothly"}},resizingSmoothly:{invoke:{src:"resizeSmoothly",onDone:"end"}},end:{invoke:{src:"onResizeEnd",onDone:"done"},on:{SNAP:"#overlay.snapping",CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:{RESIZE:{target:"resizing",actions:"onResizeEnd"},SNAP:{target:"snapping",actions:"onResizeCancel"},DRAG:{target:"#overlay.dragging",actions:"onResizeCancel"},CLOSE:{target:"#overlay.closing",actions:"onResizeCancel"}},onDone:"open"},closing:{initial:"start",states:{start:{invoke:{src:"onCloseStart",onDone:"deactivating"},on:{OPEN:{target:"#overlay.open",actions:"onCloseCancel"}}},deactivating:{invoke:{src:"deactivate",onDone:"closingSmoothly"}},closingSmoothly:{invoke:{src:"closeSmoothly",onDone:"end"}},end:{invoke:{src:"onCloseEnd",onDone:"done"},on:{OPEN:{target:"#overlay.opening",actions:"onCloseCancel"}}},done:{type:"final"}},on:{CLOSE:void 0,OPEN:{target:"#overlay.opening",actions:"onCloseCancel"}},onDone:"closed"}},on:{CLOSE:"closing"}},g={actions:{onOpenCancel:function(e,t){},onSnapCancel:function(e,t){},onResizeCancel:function(e,t){},onCloseCancel:function(e,t){},onOpenEnd:function(e,t){},onSnapEnd:function(e,t){},onRezizeEnd:function(e,t){}},services:{onSnapStart:function(){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},onOpenStart:function(){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},onCloseStart:function(){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},onResizeStart:function(){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},onSnapEnd:function(){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},onOpenEnd:function(){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},onCloseEnd:function(){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},onResizeEnd:function(){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},renderVisuallyHidden:function(e,t){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},activate:function(e,t){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},deactivate:function(e,t){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},openSmoothly:function(e,t){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},openImmediately:function(e,t){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},snapSmoothly:function(e,t){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},resizeSmoothly:function(e,t){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}},closeSmoothly:function(e,t){try{return Promise.resolve(is()).then(function(){})}catch(e){return Promise.reject(e)}}},guards:{initiallyClosed:function(e){return"CLOSED"===e.initialState},initiallyOpen:function(e){return"OPEN"===e.initialState}}},void 0===m&&(m=y.context),new r8(y,g,m)),id=["children","sibling","className","footer","header","open","initialState","lastSnapRef","initialFocusRef","onDismiss","maxHeight","defaultSnap","snapPoints","blocking","scrollLocking","style","onSpringStart","onSpringCancel","onSpringEnd","reserveScrollBarGap","expandOnContentDrag"],ih=["velocity"],iv=["onRest","config"],ip=k.forwardRef(function(e,t){var n,r,i,o,a,s,u,c,l,d,f,h,v,p,y,g,m,b,w,E,S,O,T,P,R,C=e.children,A=e.sibling,N=e.className,_=e.footer,j=e.header,L=e.open,D=e.initialState,F=e.lastSnapRef,M=e.initialFocusRef,I=e.onDismiss,V=e.maxHeight,z=e.defaultSnap,H=void 0===z?ig:z,B=e.snapPoints,G=e.blocking,q=void 0===G||G,U=e.scrollLocking,K=e.style,Y=e.onSpringStart,W=e.onSpringCancel,Z=e.onSpringEnd,$=e.reserveScrollBarGap,X=void 0===$?q:$,J=e.expandOnContentDrag,Q=void 0!==J&&J,ee=ie(e,id),et=(ec=(eu=(0,k.useState)(!1))[0],el=eu[1],ef=(ed=(0,k.useState)({}))[0],eh=ed[1],ev=(0,k.useCallback)(function(e){return eh(function(t){var n;return r6({},t,((n={})[e]=!1,n))}),function(){eh(function(t){var n;return r6({},t,((n={})[e]=!0,n))})}},[]),(0,k.useEffect)(function(){var e=Object.values(ef);0!==e.length&&e.every(Boolean)&&el(!0)},[ef]),{ready:ec,registerReady:ev}),en=et.ready,er=et.registerReady,ei=(0,k.useRef)(!1),eo=(0,k.useRef)(Y),ea=(0,k.useRef)(W),es=(0,k.useRef)(Z);(0,k.useEffect)(function(){eo.current=Y,ea.current=W,es.current=Z},[W,Y,Z]);var eu,ec,el,ed,ef,eh,ev,ep,ey,eg,em,eb,ew,eE,eS,ex,eO,eT,ek,eP,eR,eC,eA,eN,e_,ej,eL,eD,eF,eM,eI,eV,ez,eH,eB,eG,eq,eY,eW,eZ,e$,eX,eJ,eQ,e0,e1,e2,e5,e3,to,ta,ts,tu,tc,tl,td,tf,th,tv,tp=tj(function(){return{y:0,ready:0,maxHeight:0,minSnap:0,maxSnap:0}}),ty=tp[0],tg=tp[1],tm=(0,k.useRef)(null),tb=(0,k.useRef)(null),tw=(0,k.useRef)(null),tE=(0,k.useRef)(null),tS=(0,k.useRef)(null),tx=(0,k.useRef)(null),tO=(0,k.useRef)(0),tT=(0,k.useRef)(),tk=(0,k.useRef)(!1),tR=(th=(0,k.useMemo)(function(){return"undefined"!=typeof window?window.matchMedia("(prefers-reduced-motion: reduce)"):null},[]),tv=(0,k.useRef)(null==th?void 0:th.matches),(0,k.useDebugValue)(tv.current?"reduce":"no-preference"),(0,k.useEffect)(function(){var e=function(e){tv.current=e.matches};return null==th||th.addListener(e),function(){return null==th?void 0:th.removeListener(e)}}
4,[th]),tv),tC=(ey=(ep={targetRef:tb,enabled:en&&(void 0===U||U),reserveScrollBarGap:X}).targetRef,eg=ep.enabled,em=ep.reserveScrollBarGap,eb=(0,k.useRef)({activate:function(){throw TypeError("Tried to activate scroll lock too early")},deactivate:function(){}}),(0,k.useDebugValue)(eg?"Enabled":"Disabled"),(0,k.useEffect)(function(){if(!eg)return eb.current.deactivate(),void(eb.current={activate:function(){},deactivate:function(){}});var e=ey.current,t=!1;eb.current={activate:function(){t||(t=!0,ry(e,{allowTouchMove:function(e){return e.closest("[data-body-scroll-lock-ignore]")},reserveScrollBarGap:em}))},deactivate:function(){t&&(t=!1,rg(e))}}},[eg,ey,em]),eb),tA=(eE=(ew={targetRef:tm,enabled:en&&q}).targetRef,eS=ew.enabled,ex=(0,k.useRef)({activate:function(){throw TypeError("Tried to activate aria hider too early")},deactivate:function(){}}),(0,k.useDebugValue)(eS?"Enabled":"Disabled"),(0,k.useEffect)(function(){if(!eS)return ex.current.deactivate(),void(ex.current={activate:function(){},deactivate:function(){}});var e=eE.current,t=!1,n=[],r=[];ex.current={activate:function(){if(!t){t=!0;var i=e.parentNode;document.querySelectorAll("body > *").forEach(function(e){if(e!==i){var t=e.getAttribute("aria-hidden");null!==t&&"false"!==t||(n.push(t),r.push(e),e.setAttribute("aria-hidden","true"))}})}},deactivate:function(){t&&(t=!1,r.forEach(function(e,t){var r=n[t];null===r?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",r)}),n=[],r=[])}}},[eE,eS]),ex),tN=(eT=(eO={targetRef:tm,fallbackRef:tx,initialFocusRef:M||void 0,enabled:en&&q&&!1!==M}).targetRef,ek=eO.fallbackRef,eP=eO.initialFocusRef,eR=eO.enabled,eC=(0,k.useRef)({activate:function(){throw TypeError("Tried to activate focus trap too early")},deactivate:function(){}}),(0,k.useDebugValue)(eR?"Enabled":"Disabled"),(0,k.useEffect)(function(){if(!eR)return eC.current.deactivate(),void(eC.current={activate:function(){},deactivate:function(){}});var e=ek.current,t=rn(eT.current,{onActivate:void 0,initialFocus:eP?function(){return(null==eP?void 0:eP.current)||e}:void 0,fallbackFocus:e,escapeDeactivates:!1,clickOutsideDeactivates:!1}),n=!1;eC.current={activate:function(){try{return n?Promise.resolve():(n=!0,Promise.resolve(t.activate()).then(function(){return Promise.resolve(new Promise(function(e){return setTimeout(function(){return e(void 0)},0)})).then(function(){})}))}catch(e){return Promise.reject(e)}},deactivate:function(){n&&(n=!1,t.deactivate())}}},[eR,ek,eP,eT]),eC),t_=(e0=(eA={contentRef:tw,controlledMaxHeight:V,footerEnabled:!!_,footerRef:tS,getSnapPoints:void 0===B?im:B,headerEnabled:!1!==j,headerRef:tE,heightRef:tO,lastSnapRef:F,ready:en,registerReady:er,resizeSourceRef:tT}).getSnapPoints,e1=eA.heightRef,e2=eA.lastSnapRef,e5=eA.ready,to=(eI=(eN={contentRef:eA.contentRef,controlledMaxHeight:eA.controlledMaxHeight,footerEnabled:eA.footerEnabled,footerRef:eA.footerRef,headerEnabled:eA.headerEnabled,headerRef:eA.headerRef,registerReady:eA.registerReady,resizeSourceRef:eA.resizeSourceRef}).contentRef,eV=eN.controlledMaxHeight,ez=eN.footerEnabled,eH=eN.footerRef,eB=eN.headerEnabled,eG=eN.headerRef,eq=eN.registerReady,eY=eN.resizeSourceRef,eW=(0,k.useMemo)(function(){return eq("contentHeight")},[eq]),e_=(0,k.useMemo)(function(){return eq("maxHeight")},[eq]),eL=(ej=(0,k.useState)(function(){return ii(eV)||"undefined"!=typeof window?window.innerHeight:0}))[0],eD=ej[1],eF=eL>0,eM=(0,k.useRef)(0),(0,k.useDebugValue)(eV?"controlled":"auto"),(0,k.useEffect)(function(){eF&&e_()},[eF,e_]),it(function(){if(eV)return eD(ii(eV)),void(eY.current="maxheightprop");var e=function(){eM.current||(eM.current=requestAnimationFrame(function(){eD(window.innerHeight),eY.current="window",eM.current=0}))};return window.addEventListener("resize",e),eD(window.innerHeight),eY.current="window",e_(),function(){window.removeEventListener("resize",e),cancelAnimationFrame(eM.current)}},[eV,e_,eY]),eZ=ia(eG,{label:"headerHeight",enabled:eB,resizeSourceRef:eY}),e$=ia(eI,{label:"contentHeight",enabled:!0,resizeSourceRef:eY}),eJ=Math.min(eL-eZ-(eX=ia(eH,{label:"footerHeight",enabled:ez,resizeSourceRef:eY})),e$)+eZ+eX,(0,k.useDebugValue)("minHeight: "+eJ),eQ=e$>0,(0,k.useEffect)(function(){eQ&&eW()},[eQ,eW]),e3={maxHeight:eL,minHeight:eJ,headerHeight:eZ,footerHeight:eX}).maxHeight,ta=e3.minHeight,ts=e3.headerHeight,tu=e3.footerHeight,tl=(tc=function(e,t){var n=Array.from([].concat(e).map(ii).reduce(function(e,n){return e.add(ir(n,0,t)),e},new Set)),r=Math.min.apply(Math,n);if(Number.isNaN(r))throw TypeError("minSnap is NaN");var i=Math.max.apply(Math,n);if(Number.isNaN(i))throw TypeError("maxSnap is NaN");return{snapPoints:n,minSnap:r,maxSnap:i}}(e5?e0({height:e1.current,footerHeight:tu,headerHeight:ts,minHeight:ta,maxHeight:to}
4):[0],to)).snapPoints,td=tc.minSnap,tf=tc.maxSnap,(0,k.useDebugValue)("minSnap: "+td+", maxSnap:"+tf),{minSnap:td,maxSnap:tf,findSnap:function(e){var t=ii("function"==typeof e?e({footerHeight:tu,headerHeight:ts,height:e1.current,minHeight:ta,maxHeight:to,snapPoints:tl,lastSnap:e2.current}):e);return tl.reduce(function(e,n){return Math.abs(n-t)<Math.abs(e-t)?n:e},td)},maxHeight:to}),tL=t_.minSnap,tD=t_.maxSnap,tF=t_.maxHeight,tM=t_.findSnap,tI=(0,k.useRef)(tF),tV=(0,k.useRef)(tL),tz=(0,k.useRef)(tD),tH=(0,k.useRef)(tM),tB=(0,k.useRef)(0);it(function(){tI.current=tF,tz.current=tD,tV.current=tL,tH.current=tM,tB.current=tM(H)},[tM,H,tF,tD,tL]);var tG=(0,k.useCallback)(function(e){var t=e.onRest,n=e.config,r=(n=void 0===n?{}:n).velocity,i=void 0===r?1:r,o=ie(n,ih),a=ie(e,iv);return new Promise(function(e){return tg(r6({},a,{config:r6({velocity:i},o,{mass:1,tension:170,friction:Math.max(26,26+(26-26*i))}),onRest:function(){var n=[].slice.call(arguments);e.apply(void 0,n),null==t||t.apply(void 0,n)}}))})},[tg]),tq=(n={devTools:!1,actions:{onOpenCancel:(0,k.useCallback)(function(){return null==ea.current?void 0:ea.current({type:"OPEN"})},[]),onSnapCancel:(0,k.useCallback)(function(e){return null==ea.current?void 0:ea.current({type:"SNAP",source:e.snapSource})},[]),onCloseCancel:(0,k.useCallback)(function(){return null==ea.current?void 0:ea.current({type:"CLOSE"})},[]),onResizeCancel:(0,k.useCallback)(function(){return null==ea.current?void 0:ea.current({type:"RESIZE",source:tT.current})},[]),onOpenEnd:(0,k.useCallback)(function(){return null==es.current?void 0:es.current({type:"OPEN"})},[]),onSnapEnd:(0,k.useCallback)(function(e,t){return null==es.current?void 0:es.current({type:"SNAP",source:e.snapSource})},[]),onResizeEnd:(0,k.useCallback)(function(){return null==es.current?void 0:es.current({type:"RESIZE",source:tT.current})},[])},context:{initialState:D},services:{onSnapStart:(0,k.useCallback)(function(e,t){try{return Promise.resolve(null==eo.current?void 0:eo.current({type:"SNAP",source:t.payload.source||"custom"}))}catch(e){return Promise.reject(e)}},[]),onOpenStart:(0,k.useCallback)(function(){try{return Promise.resolve(null==eo.current?void 0:eo.current({type:"OPEN"}))}catch(e){return Promise.reject(e)}},[]),onCloseStart:(0,k.useCallback)(function(){try{return Promise.resolve(null==eo.current?void 0:eo.current({type:"CLOSE"}))}catch(e){return Promise.reject(e)}},[]),onResizeStart:(0,k.useCallback)(function(){try{return Promise.resolve(null==eo.current?void 0:eo.current({type:"RESIZE",source:tT.current}))}catch(e){return Promise.reject(e)}},[]),onSnapEnd:(0,k.useCallback)(function(e,t){try{return Promise.resolve(null==es.current?void 0:es.current({type:"SNAP",source:e.snapSource}))}catch(e){return Promise.reject(e)}},[]),onOpenEnd:(0,k.useCallback)(function(){try{return Promise.resolve(null==es.current?void 0:es.current({type:"OPEN"}))}catch(e){return Promise.reject(e)}},[]),onCloseEnd:(0,k.useCallback)(function(){try{return Promise.resolve(null==es.current?void 0:es.current({type:"CLOSE"}))}catch(e){return Promise.reject(e)}},[]),onResizeEnd:(0,k.useCallback)(function(){try{return Promise.resolve(null==es.current?void 0:es.current({type:"RESIZE",source:tT.current}))}catch(e){return Promise.reject(e)}},[]),renderVisuallyHidden:(0,k.useCallback)(function(e,t){try{return Promise.resolve(tG({y:tB.current,ready:0,maxHeight:tI.current,maxSnap:tz.current,minSnap:tB.current,immediate:!0})).then(function(){})}catch(e){return Promise.reject(e)}},[tG]),activate:(0,k.useCallback)(function(e,t){try{return ei.current=!0,Promise.resolve(Promise.all([tC.current.activate(),tN.current.activate(),tA.current.activate()])).then(function(){})}catch(e){return Promise.reject(e)}},[tA,tN,tC]),deactivate:(0,k.useCallback)(function(){try{return tC.current.deactivate(),tN.current.deactivate(),tA.current.deactivate(),ei.current=!1,Promise.resolve()}catch(e){return Promise.reject(e)}},[tA,tN,tC]),openImmediately:(0,k.useCallback)(function(){try{return tO.current=tB.current,Promise.resolve(tG({y:tB.current,ready:1,maxHeight:tI.current,maxSnap:tz.current,minSnap:tB.current,immediate:!0})).then(function(){})}catch(e){return Promise.reject(e)}},[tG]),openSmoothly:(0,k.useCallback)(function(){try{return Promise.resolve(tG({y:0,ready:1,maxHeight:tI.current,maxSnap:tz.current,minSnap:tB.current,immediate:!0})).then(function(){return tO.current=tB.current,Promise.resolve(tG({y:tB.current,ready:1,maxHeight:tI.current,maxSnap:tz.current,minSnap:tB.current,immediate:tR.current})).then(function(){})})}catch(e){return Promise.reject(e)}},[tG,tR]),snapSmoothly:(0,k.useCallback)(function(e,t){try{var n=tH.current(e.y);return tO.current=n,F.current=n,Promise.resolve(tG({y:n,ready:1,maxHeight:tI.current,maxSnap:tz.current,minSnap:tV.current,immediate:tR.current,config:{velocity:e.velocity}})).then(function(){})}catch(e){return Promise.reject(e)}},[tG,F,tR]),resizeSmoothly:(0,k.useCallback)(function(){try{var e=tH.current(tO.current);return tO.current=e,F.current=e,Promise.resolve(tG({y:e,ready:1,maxHeight:tI.current,maxSnap:tz.current,minSnap:tV.current,immediate:"element"!==tT.current||tR.current})).then(function(){})}catch(e){return Promise.reject(e)}},[tG,F,tR]),closeSmoothly:(0,k.useCallback)(function(e,t){try{return tG({minSnap:tO.current,immediate:!0}),tO.current=0,Promise.resolve(tG({y:0,maxHeight:tI.current,maxSnap:tz.current,immediate:tR.current})).then(function(){return Promise.resolve(tG({ready:0,immediate:!0})).then(function(){})})}catch(e){return Promise.reject(e)}},[tG,tR])}},r=(0,k.useCallback)(function(e){var t=void 0===e.changed&&Object.keys(e.children).length;(e.changed||t)&&b(e)},[]),void 0===(i=n)&&(i={}),o=e7(function(){return"function"==typeof il?il():il}),a=i.context,s=i.guards,u=i.actions,c=i.activities,l=i.services,d=i.delays,f=i.state,h=tr(i,["context","guards","actions","activities","services","delays","state"]),v=e7(function(){return e4(o.withConfig({context:a,guards:s,actions:u,activities:c,services:l,delays:d},function(){return tn(tn({},o.context),a)}),tn({deferEvents:!0},h))}),eK(function(){var e;return r&&(e=v.subscribe(function(e,t,n){if("object"==typeof e)return e;var r=function(){};return{next:e,error:r,complete:r}}(r))),function(){null==e||e.unsubscribe()}},[r]),eK(function(){return v.start(f?eU.create(f):void 0),function(){v.stop()}},[]),eK(function(){Object.assign(v.machine.options.actions,u),Object.assign(v.machine.options.guards,s),Object.assign(v.machine.options.activities,c),Object.assign(v.machine.options.services,l),Object.assign(v.machine.options.delays,d)},[u,s,c,l,d]),p=(0,k.useRef)([]),y=(0,k.useRef)([]),eK(function(){var e=v.subscribe(function(e){var t,n;if(e.actions.length){var r=e6(function(e,t){var n,r,i=e9([[],[]],2),o=i[0],a=i[1];try{for(var s=e8(e),u=s.next();!u.done;u=s.next()){var c=u.value;t(c)?o.push(c):a.push(c)}}catch(e){n={error:e}}finally{try{u&&!u.done&&(r=s.return)&&r.call(s)}finally{if(n)throw n.error}}return[o,a]}(e.actions.filter(function(e){return"function"==typeof e.exec&&"__effect"in e.exec}),function(e){return e.exec.__effect===x.Effect}),2),i=r[0],o=r[1];(t=p.current).push.apply(t,te([],e6(i.map(function(t){return[t,e]})),!1)),(n=y.current).push.apply(n,te([],e6(o.map(function(t){return[t,e]})),!1))}});return function(){e.unsubscribe()}},[]),eK(function(){for(;y.current.length;){var e=e6(y.current.shift(),2);tt(e[0],e[1])}}),(0,k.useEffect)(function(){for(;p.current.length;){var e=e6(p.current.shift(),2);tt(e[0],e[1])}}),m=(g=ti((0,k.useState)(function(){var e=v.machine.initialState;return n.state?eU.create(n.state):e}),2))[0],b=g[1],[m,v.send,v]),tU=tq[0],tK=tq[1];(0,k.useEffect)(function(){en&&tK(L?"OPEN":"CLOSE")}
4,[L,tK,en]),it(function(){(tF||tD||tL)&&tK("RESIZE")},[tF,tD,tL,tK]),(0,k.useEffect)(function(){return function(){tC.current.deactivate(),tN.current.deactivate(),tA.current.deactivate()}},[tA,tN,tC]),(0,k.useImperativeHandle)(t,function(){return{snapTo:function(e,t){var n=void 0===t?{}:t,r=n.velocity,i=n.source;tK("SNAP",{payload:{y:tH.current(e),velocity:void 0===r?1:r,source:void 0===i?"custom":i}})},get height(){return tO.current}}},[tK]),(0,k.useEffect)(function(){var e=tb.current,t=function(e){tk.current&&e.preventDefault()},n=function(t){e.scrollTop<0&&(requestAnimationFrame(function(){e.style.overflow="hidden",e.scrollTop=0,e.style.removeProperty("overflow")}),t.preventDefault())};return Q&&(e.addEventListener("scroll",t),e.addEventListener("touchmove",t),e.addEventListener("touchstart",n)),function(){e.removeEventListener("scroll",t),e.removeEventListener("touchmove",t),e.removeEventListener("touchstart",n)}},[Q,tb]);var tY=function(e,t){void 0===t&&(t={}),nE.set("drag",nF);var n,r,i,o,a,s,u,c,l,d=(0,k.useRef)();return d.current||(d.current=(o=[],a=!1,function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return a&&r===this&&function(e,t){try{return function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){var r,i,o,a;if(t.constructor!==n.constructor)return!1;if(Array.isArray(t)){if((r=t.length)!==n.length)return!1;for(i=r;0!=i--;)if(!e(t[i],n[i]))return!1;return!0}if("function"==typeof Map&&t instanceof Map&&n instanceof Map){if(t.size!==n.size)return!1;for(a=t.entries();!(i=a.next()).done;)if(!n.has(i.value[0]))return!1;for(a=t.entries();!(i=a.next()).done;)if(!e(i.value[1],n.get(i.value[0])))return!1;return!0}if("function"==typeof Set&&t instanceof Set&&n instanceof Set){if(t.size!==n.size)return!1;for(a=t.entries();!(i=a.next()).done;)if(!n.has(i.value[0]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((r=(o=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(i=r;0!=i--;)if(!Object.prototype.hasOwnProperty.call(n,o[i]))return!1;if("undefined"!=typeof Element&&t instanceof Element)return!1;for(i=r;0!=i--;)if(("_owner"!==o[i]||!t.$$typeof)&&!e(t[o[i]],n[o[i]]))return!1;return!0}return t!=t&&n!=n}(e,t)}catch(e){if((e.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw e}}(t,o)||(i=nm.apply(this,t),a=!0,r=this,o=t),i})),s={drag:e},u=d.current(t),void 0===c&&(c={}),n=new Set,s.drag&&n.add(nE.get("drag")),s.wheel&&n.add(nE.get("wheel")),s.scroll&&n.add(nE.get("scroll")),s.move&&n.add(nE.get("move")),s.pinch&&n.add(nE.get("pinch")),s.hover&&n.add(nE.get("hover")),((l=k.useMemo(function(){return new nk(n)},[])).config=u,l.handlers=s,l.nativeRefs=c,k.useEffect(l.effect,[]),l.config.domTarget)?n_:l.bind}(function(e){var t=e.args,n=(t=void 0===t?[]:t)[0],r=(n=void 0===n?{}:n).closeOnTap,i=n.isContentDragging,o=e.cancel,a=e.direction[1],s=e.down,u=e.first,c=e.last,l=e.memo,d=void 0===l?ty.y.getValue():l,f=e.tap,h=e.velocity,v=-1*e.movement[1];if(!ei.current)return o(),d;if(I&&void 0!==r&&r&&f)return o(),setTimeout(function(){return I()},0),d;if(f)return d;var p=d+v,y=v*h,g=Math.max(tV.current,Math.min(tz.current,p+2*y));if(!s&&I&&a>0&&p+y<tV.current/2)return o(),I(),d;var m=s?I||tV.current!==tz.current?nr(p,I?0:tV.current,tz.current,.55):p<tV.current?nr(p,tV.current,2*tz.current,.55):nr(p,tV.current/2,tz.current,.55):g;return Q&&void 0!==i&&i?(m>=tz.current&&(m=tz.current),d===tz.current&&tb.current.scrollTop>0&&(m=tz.current),tk.current=m<tz.current):tk.current=!1,u&&tK("DRAG"),c?tK("SNAP",{payload:{y:m,velocity:h>.05?h:1,source:"dragging"}}):tg({y:m,ready:1,maxHeight:tI.current,maxSnap:tz.current,minSnap:tV.current,immediate:!0,config:{velocity:h}}),d},{filterTaps:!0});if(Number.isNaN(tz.current))throw TypeError("maxSnapRef is NaN!!");if(Number.isNaN(tV.current))throw TypeError("minSnapRef is NaN!!");var tW=(E=tP([ty.y,ty.maxHeight],function(e,t){return Math.round(ir(t-e,0,16))+"px"}),S=tP([ty.y,ty.minSnap,ty.maxSnap],function(e,t,n){return ir(e,t,n)+"px"}),O=tP([ty.y,ty.minSnap,ty.maxSnap],function(e,t,n){return e<t?t-e+"px":e>n?n-e+"px":"0px"}),T=tP([ty.y,ty.maxSnap],function(e,t){return e>=t?Math.ceil(e-t):0}),P=tP([ty.y,ty.minSnap],function(e,t){if(!t)return 0;var n=Math.max(t/2-45,0);return ir((e-n)*(1/(Math.min(t/2+45,t)-n)+0),0,1)}),R=tP([ty.y,ty.minSnap],function(e,t){return t?ir(e/t,0,1):0}),(w={})["--rsbs-content-opacity"]=P,w["--rsbs-backdrop-opacity"]=R,w["--rsbs-antigap-scale-y"]=T,w["--rsbs-overlay-translate-y"]=O,w["--rsbs-overlay-rounded"]=E,w["--rsbs-overlay-h"]=S,w);return k.createElement(t9.div,r6({},ee,{"data-rsbs-root":!0,"data-rsbs-state":iy.find(tU.matches),"data-rsbs-is-blocking":q,"data-rsbs-is-dismissable":!!I,"data-rsbs-has-header":!!j,"data-rsbs-has-footer":!!_,className:N,ref:tm,style:r6({},tW,K,{opacity:ty.ready})}),A,q&&k.createElement("div",r6({key:"backdrop","data-rsbs-backdrop":!0},tY({closeOnTap:!0}))),k.createElement("div",{key:"overlay","aria-modal":"true",role:"dialog","data-rsbs-overlay":!0,tabIndex:-1,ref:tx,onKeyDown:function(e){"Escape"===e.key&&(e.stopPropagation(),I&&I())}},!1!==j&&k.createElement("div",r6({key:"header","data-rsbs-header":!0,ref:tE},tY()),j),k.createElement("div",r6({key:"scroll","data-rsbs-scroll":!0,ref:tb},Q?tY({isContentDragging:!0}):{}),k.createElement("div",{"data-rsbs-content":!0,ref:tw},C)),_&&k.createElement("div",r6({key:"footer",ref:tS,"data-rsbs-footer":!0},tY()),_)))}),iy=["closed","opening","open","closing","dragging","snapping","resizing"];function ig(e){var t=e.lastSnap;return null!=t?t:Math.min.apply(Math,e.snapPoints)}function im(e){return e.minHeight}var ib=["onSpringStart","onSpringEnd","skipInitialTransition"],iw=(0,k.forwardRef)(function(e,t){var n=e.onSpringStart,r=e.onSpringEnd,i=e.skipInitialTransition,o=ie(e,ib),a=(0,k.useState)(!1),s=a[0],u=a[1],c=(0,k.useRef)(),l=(0,k.useRef)(null),d=(0,k.useRef)(i&&o.open?"OPEN":"CLOSED");it(function(){if(o.open)return cancelAnimationFrame(c.current),u(!0),function(){d.current="CLOSED"}},[o.open]);var f=(0,k.useCallback)(function(e){return Promise.resolve(null==n?void 0:n(e)).then(function(){"OPEN"===e.type&&cancelAnimationFrame(c.current)})},[n]),h=(0,k.useCallback)(function(e){return Promise.resolve(null==r?void 0:r(e)).then(function(){"CLOSE"===e.type&&(c.current=requestAnimationFrame(function(){return u(!1)}))})},[r]);return s?k.createElement(C,{"data-rsbs-portal":!0},k.createElement(ip,r6({},o,{lastSnapRef:l,ref:t,initialState:d.current,onSpringStart:f,onSpringEnd:h}))):null})},2473:function(e){"use strict";e.exports=function(){}},1022:function(e,t,n){"use strict";let r,i,o,a,s,u,c,l,d,f,h,v,p,y;n.d(t,{Vq:function(){return eV},EM:function(){return eM},$N:function(){return eI}});var g,m,b=n(7294),w=n(3),E=n(5508);function S(e,t,n,r){let i=(0,E.E)(n);(0,b.useEffect)(()=>{function n(e){i.current(e)}return(e=null!=e?e:window).addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)},[e,t,r])}var x=n(3580),O=n(1830);function T(e){return O.O.isServer?null:e instanceof Node?e.ownerDocument:null!=e&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}var k=n(1378);let P=new Map,R=new Map;function C(e){var t;let n=null!=(t=R.get(e))?t:0;return R.set(e,n+1),0!==n||(P.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),e.setAttribute("aria-hidden","true"),e.inert=!0),()=>(function(e){var t;let n=null!=(t=R.get(e))?t:1;if(1===n?R.delete(e):R.set(e,n-1),1!==n)return;let r=P.get(e);r&&(null===r["aria-hidden"]?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",r["aria-hidden"]),e.inert=r.inert,P.delete(e))})(e)}var A=n(607),N=n(8844);let _=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(e=>"".concat(e,":not([tabindex='-1'])")).join(","),j=["[data-autofocus]"].map(e=>"".concat(e,":not([tabindex='-1'])")).join(",");var L=((r=L||{})[r.First=1]="First",r[r.Previous=2]="Previous",r[r.Next=4]="Next",r[r.Last=8]="Last",r[r.WrapAround=16]="WrapAround",r[r.NoScroll=32]="NoScroll",r[r.AutoFocus=64]="AutoFocus",r),D=((i=D||{})[i.Error=0]="Error",i[i.Overflow=1]="Overflow",i[i.Success=2]="Success",i[i.Underflow=3]="Underflow",i),F=((o=F||{})[o.Previous=-1]="Previous",o[o.Next=1]="Next",o),M=((a=M||{})[a.Strict=0]="Strict",a[a.Loose=1]="Loose",a),I=((s=I||{})[s.Keyboard=0]="Keyboard",s[s.Mouse=1]="Mouse",s);function V(e){null==e||e.focus({preventScroll:!0})}function z(e,t){var n,r,i;let{sorted:o=!0,relativeTo:a=null,skipElements:s=[]}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},u=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,c=Array.isArray(e)?o?function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e=>e;return e.slice().sort((e,n)=>{let r=t(e),i=t(n);if(null===r||null===i)return 0;let o=r.compareDocumentPosition(i);return o&Node.DOCUMENT_POSITION_FOLLOWING?-1:o&Node.DOCUMENT_POSITION_PRECEDING?1:0})}(e):e:64&t?function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return null==e?[]:Array.from(e.querySelectorAll(j)).sort((e,t)=>
4Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER)))}(e):function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return null==e?[]:Array.from(e.querySelectorAll(_)).sort((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER)))}(e);s.length>0&&c.length>1&&(c=c.filter(e=>!s.some(t=>null!=t&&"current"in t?(null==t?void 0:t.current)===e:t===e))),a=null!=a?a:u.activeElement;let l=(()=>{if(5&t)return 1;if(10&t)return -1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),d=(()=>{if(1&t)return 0;if(2&t)return Math.max(0,c.indexOf(a))-1;if(4&t)return Math.max(0,c.indexOf(a))+1;if(8&t)return c.length-1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),f=32&t?{preventScroll:!0}:{},h=0,v=c.length,p;do{if(h>=v||h+v<=0)return 0;let e=d+h;if(16&t)e=(e+v)%v;else{if(e<0)return 3;if(e>=v)return 1}null==(p=c[e])||p.focus(f),h+=l}while(p!==u.activeElement);return 6&t&&null!=(i=null==(r=null==(n=p)?void 0:n.matches)?void 0:r.call(n,"textarea,input"))&&i&&p.select(),2}function H(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function B(e,t,n){let r=(0,E.E)(t);(0,b.useEffect)(()=>{function t(e){r.current(e)}return document.addEventListener(e,t,n),()=>document.removeEventListener(e,t,n)},[e,n])}function G(e,t,n){let r=(0,E.E)(t);(0,b.useEffect)(()=>{function t(e){r.current(e)}return window.addEventListener(e,t,n),()=>window.removeEventListener(e,t,n)},[e,n])}function q(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,b.useMemo)(()=>T(...t),[...t])}"undefined"!=typeof document&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{1===e.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===e.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));var U=n(8287),K=((u=K||{})[u.None=1]="None",u[u.Focusable=2]="Focusable",u[u.Hidden=4]="Hidden",u);let Y=(0,U.yV)(function(e,t){var n;let{features:r=1,...i}=e,o={ref:t,"aria-hidden":(2&r)==2||(null!=(n=i["aria-hidden"])?n:void 0),hidden:(4&r)==4||void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(4&r)==4&&(2&r)!=2&&{display:"none"}}};return(0,U.sY)({ourProps:o,theirProps:i,slot:{},defaultTag:"div",name:"Hidden"})}),W=(g=()=>new Map,m={PUSH(e,t){var n;let r=null!=(n=this.get(e))?n:{doc:e,count:0,d:(0,x.k)(),meta:new Set};return r.count++,r.meta.add(t),this.set(e,r),this},POP(e,t){let n=this.get(e);return n&&(n.count--,n.meta.delete(t)),this},SCROLL_PREVENT(e){let t,{doc:n,d:r,meta:i}=e,o={doc:n,d:r,meta:function(e){let t={};for(let n of e)Object.assign(t,n(t));return t}(i)},a=[H()?{before(e){let{doc:t,d:n,meta:r}=e;function i(e){return r.containers.flatMap(e=>e()).some(t=>t.contains(e))}n.microTask(()=>{var e;if("auto"!==window.getComputedStyle(t.documentElement).scrollBehavior){let e=(0,x.k)();e.style(t.documentElement,"scrollBehavior","auto"),n.add(()=>n.microTask(()=>e.dispose()))}let r=null!=(e=window.scrollY)?e:window.pageYOffset,o=null;n.addEventListener(t,"click",e=>{if(e.target instanceof HTMLElement)try{let n=e.target.closest("a");if(!n)return;let{hash:r}=new URL(n.href),a=t.querySelector(r);a&&!i(a)&&(o=a)}catch(e){}},!0),n.addEventListener(t,"touchstart",e=>{if(e.target instanceof HTMLElement){if(i(e.target)){let t=e.target;for(;t.parentElement&&i(t.parentElement);)t=t.parentElement;n.style(t,"overscrollBehavior","contain")}else n.style(e.target,"touchAction","none")}}),n.addEventListener(t,"touchmove",e=>{if(e.target instanceof HTMLElement&&"INPUT"!==e.target.tagName){if(i(e.target)){let t=e.target;for(;t.parentElement&&""!==t.dataset.headlessuiPortal&&!(t.scrollHeight>t.clientHeight||t.scrollWidth>t.clientWidth);)t=t.parentElement;""===t.dataset.headlessuiPortal&&e.preventDefault()}else e.preventDefault()}},{passive:!1}),n.add(()=>{var e;r!==(null!=(e=window.scrollY)?e:window.pageYOffset)&&window.scrollTo(0,r),o&&o.isConnected&&(o.scrollIntoView({block:"nearest"}),o=null)})})}}:{},{before(e){var n;let{doc:r}=e,i=r.documentElement;t=Math.max(0,(null!=(n=r.defaultView)?n:window).innerWidth-i.clientWidth)},after(e){let{doc:n,d:r}=e,i=n.documentElement,o=Math.max(0,i.clientWidth-i.offsetWidth),a=Math.max(0,t-o);r.style(i,"paddingRight","".concat(a,"px"))}},{before(e){let{doc:t,d:n}=e;n.style(t.documentElement,"overflow","hidden")}}];
4a.forEach(e=>{let{before:t}=e;return null==t?void 0:t(o)}),a.forEach(e=>{let{after:t}=e;return null==t?void 0:t(o)})},SCROLL_ALLOW(e){let{d:t}=e;t.dispose()},TEARDOWN(e){let{doc:t}=e;this.delete(t)}},c=g(),l=new Set,{getSnapshot:()=>c,subscribe:e=>(l.add(e),()=>l.delete(e)),dispatch(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];let i=m[e].call(c,...n);i&&(c=i,l.forEach(e=>e()))}});W.subscribe(()=>{let e=W.getSnapshot(),t=new Map;for(let[n]of e)t.set(n,n.documentElement.style.overflow);for(let n of e.values()){let e="hidden"===t.get(n.doc),r=0!==n.count;(r&&!e||!r&&e)&&W.dispatch(n.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",n),0===n.count&&W.dispatch("TEARDOWN",n)}});var Z=n(2047),$=n(1813);let X=(0,b.createContext)(()=>{});function J(e){let{value:t,children:n}=e;return b.createElement(X.Provider,{value:t},n)}var Q=n(3935);let ee=(0,b.createContext)(null);function et(e){let{children:t}=e,n=(0,b.useContext)(ee);if(!n)return b.createElement(b.Fragment,null,t);let{target:r}=n;return r?(0,Q.createPortal)(b.createElement(b.Fragment,null,t),r):null}var en=n(4358);let er=(0,b.createContext)(!1);function ei(e){return b.createElement(er.Provider,{value:e.force},e.children)}let eo=(0,b.createContext)(()=>{});eo.displayName="StackContext";var ea=((d=ea||{})[d.Add=0]="Add",d[d.Remove=1]="Remove",d);function es(e){let{children:t,onUpdate:n,type:r,element:i,enabled:o}=e,a=(0,b.useContext)(eo),s=(0,w.z)(function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];null==n||n(...t),a(...t)});return(0,k.e)(()=>{let e=void 0===o||!0===o;return e&&s(0,r,i),()=>{e&&s(1,r,i)}},[s,r,i,o]),b.createElement(eo.Provider,{value:s},t)}let eu=(0,b.createContext)(void 0),ec=(0,b.createContext)(null);ec.displayName="DescriptionContext";let el=Object.assign((0,U.yV)(function(e,t){let n=(0,b.useId)(),r=(0,b.useContext)(eu),{id:i="headlessui-description-".concat(n),...o}=e,a=function e(){let t=(0,b.useContext)(ec);if(null===t){let t=Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,e),t}return t}(),s=(0,$.T)(t);(0,k.e)(()=>a.register(i),[i,a.register]);let u=r||!1,c=(0,b.useMemo)(()=>({...a.slot,disabled:u}),[a.slot,u]),l={ref:s,...a.props,id:i};return(0,U.sY)({ourProps:l,theirProps:o,slot:c,defaultTag:"p",name:a.name||"Description"})}),{});var ed=n(3285),ef=n(2308),eh=n(1291);function ev(e){let t=(0,w.z)(e),n=(0,b.useRef)(!1);(0,b.useEffect)(()=>(n.current=!1,()=>{n.current=!0,(0,eh.Y)(()=>{n.current&&t()})}),[t])}var ep=((f=ep||{})[f.Forwards=0]="Forwards",f[f.Backwards=1]="Backwards",f);function ey(e,t){let n=(0,b.useRef)([]),r=(0,w.z)(e);(0,b.useEffect)(()=>{let e=[...n.current];for(let[i,o]of t.entries())if(n.current[i]!==o){let i=r(t,e);return n.current=t,i}},[r,...t])}let eg=[];function em(e){if(!e)return new Set;if("function"==typeof e)return new Set(e());let t=new Set;for(let n of e.current)n.current instanceof HTMLElement&&t.add(n.current);return t}!function(e){function t(){"loading"!==document.readyState&&(e(),document.removeEventListener("DOMContentLoaded",t))}"undefined"!=typeof document&&(document.addEventListener("DOMContentLoaded",t),t())}(()=>{function e(e){e.target instanceof HTMLElement&&e.target!==document.body&&eg[0]!==e.target&&(eg.unshift(e.target),(eg=eg.filter(e=>null!=e&&e.isConnected)).splice(10))}window.addEventListener("click",e,{capture:!0}),window.addEventListener("mousedown",e,{capture:!0}),window.addEventListener("focus",e,{capture:!0}),document.body.addEventListener("click",e,{capture:!0}),document.body.addEventListener("mousedown",e,{capture:!0}),document.body.addEventListener("focus",e,{capture:!0})});var eb=((h=eb||{})[h.None=1]="None",h[h.InitialFocus=2]="InitialFocus",h[h.TabLock=4]="TabLock",h[h.FocusLock=8]="FocusLock",h[h.RestoreFocus=16]="RestoreFocus",h[h.AutoFocus=32]="AutoFocus",h[h.All=30]="All",h);let ew=Object.assign((0,U.yV)(function(e,t){let n,r=(0,b.useRef)(null),i=(0,$.T)(r,t),{initialFocus:o,initialFocusFallback:a,containers:s,features:u=30,...c}=e;(0,Z.H)()||(u=1);let l=q(r);!function(e,t){let{ownerDocument:n}=e,r=function(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0],t=(0,b.useRef)(eg.slice());return ey((e,n)=>{let[r]=e,[i]=n;!0===i&&!1===r&&(0,eh.Y)(()=>{t.current.splice(0)}),!1===i&&!0===r&&(t.current=eg.slice())},[e,eg,t]),(0,w.z)(()=>{var e;return null!=(e=t.current.find(e=>null!=e&&e.isConnected))?e:null})}(t);ey(()=>{t||(null==n?void 0:n.activeElement)===(null==n?void 0:n.body)&&V(r())},[t]),ev(()=>{t&&V(r())})}({ownerDocument:l},!!(16&u));let d=function(e,t){let{ownerDocument:n,container:r,initialFocus:i,initialFocusFallback:o}=e,a=!!(2&t),s=(0,b.useRef)(null),u=(0,ef.t)();return ey(()=>
4{if(!a){null!=o&&o.current&&V(o.current);return}let e=r.current;e&&(0,eh.Y)(()=>{if(!u.current)return;let r=null==n?void 0:n.activeElement;if(null!=i&&i.current){if((null==i?void 0:i.current)===r){s.current=r;return}}else if(e.contains(r)){s.current=r;return}if(null!=i&&i.current)V(i.current);else{if(32&t){if(z(e,L.First|L.AutoFocus)!==D.Error)return}else if(z(e,L.First)!==D.Error)return;if(null!=o&&o.current&&(V(o.current),(null==n?void 0:n.activeElement)===o.current))return;console.warn("There are no focusable elements inside the <FocusTrap />")}s.current=null==n?void 0:n.activeElement})},[o,a,t]),s}({ownerDocument:l,container:r,initialFocus:o,initialFocusFallback:a},u);!function(e,t){let{ownerDocument:n,container:r,containers:i,previousActiveElement:o}=e,a=(0,ef.t)();S(null==n?void 0:n.defaultView,"focus",e=>{if(!t||!a.current)return;let n=em(i);r.current instanceof HTMLElement&&n.add(r.current);let s=o.current;if(!s)return;let u=e.target;u&&u instanceof HTMLElement?eE(n,u)?(o.current=u,V(u)):(e.preventDefault(),e.stopPropagation(),V(s)):V(o.current)},!0)}({ownerDocument:l,container:r,containers:s,previousActiveElement:d},!!(8&u));let f=(n=(0,b.useRef)(0),G("keydown",e=>{"Tab"===e.key&&(n.current=e.shiftKey?1:0)},!0),n),h=(0,w.z)(e=>{let t=r.current;t&&(0,N.E)(f.current,{[ep.Forwards]:()=>{z(t,L.First,{skipElements:[e.relatedTarget,a]})},[ep.Backwards]:()=>{z(t,L.Last,{skipElements:[e.relatedTarget,a]})}})}),v=(0,ed.G)(),p=(0,b.useRef)(!1);return b.createElement(b.Fragment,null,!!(4&u)&&b.createElement(Y,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:h,features:K.Focusable}),(0,U.sY)({ourProps:{ref:i,onKeyDown(e){"Tab"==e.key&&(p.current=!0,v.requestAnimationFrame(()=>{p.current=!1}))},onBlur(e){if(!(8&u))return;let t=em(s);r.current instanceof HTMLElement&&t.add(r.current);let n=e.relatedTarget;n instanceof HTMLElement&&"true"!==n.dataset.headlessuiFocusGuard&&(eE(t,n)||(p.current?z(r.current,(0,N.E)(f.current,{[ep.Forwards]:()=>L.Next,[ep.Backwards]:()=>L.Previous})|L.WrapAround,{relativeTo:e.target}):e.target instanceof HTMLElement&&V(e.target)))}},theirProps:c,defaultTag:"div",name:"FocusTrap"}),!!(4&u)&&b.createElement(Y,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:h,features:K.Focusable}))}),{features:eb});function eE(e,t){for(let n of e)if(n.contains(t))return!0;return!1}var eS=((v=eS||{}).Space=" ",v.Enter="Enter",v.Escape="Escape",v.Backspace="Backspace",v.Delete="Delete",v.ArrowLeft="ArrowLeft",v.ArrowUp="ArrowUp",v.ArrowRight="ArrowRight",v.ArrowDown="ArrowDown",v.Home="Home",v.End="End",v.PageUp="PageUp",v.PageDown="PageDown",v.Tab="Tab",v);let ex=b.Fragment,eO=(0,U.yV)(function(e,t){let n=(0,b.useRef)(null),r=(0,$.T)((0,$.h)(e=>{n.current=e}),t),i=q(n),o=function(e){let t=(0,b.useContext)(er),n=(0,b.useContext)(ek),r=q(e),[i,o]=(0,b.useState)(()=>{var e;if(!t&&null!==n)return null!=(e=n.current)?e:null;if(O.O.isServer)return null;let i=null==r?void 0:r.getElementById("headlessui-portal-root");if(i)return i;if(null===r)return null;let o=r.createElement("div");return o.setAttribute("id","headlessui-portal-root"),r.body.appendChild(o)});return(0,b.useEffect)(()=>{null!==i&&(null!=r&&r.body.contains(i)||null==r||r.body.appendChild(i))},[i,r]),(0,b.useEffect)(()=>{t||null!==n&&o(n.current)},[n,o,t]),i}(n),[a]=(0,b.useState)(()=>{var e;return O.O.isServer?null:null!=(e=null==i?void 0:i.createElement("div"))?e:null}),s=(0,b.useContext)(eP),u=(0,Z.H)();return(0,k.e)(()=>{!o||!a||o.contains(a)||(a.setAttribute("data-headlessui-portal",""),o.appendChild(a))},[o,a]),(0,k.e)(()=>{if(a&&s)return s.register(a)},[s,a]),ev(()=>{var e;o&&a&&(a instanceof Node&&o.contains(a)&&o.removeChild(a),o.childNodes.length<=0&&(null==(e=o.parentElement)||e.removeChild(o)))}),u&&o&&a?(0,Q.createPortal)((0,U.sY)({ourProps:{ref:r},theirProps:e,slot:{},defaultTag:ex,name:"Portal"}),a):null}),eT=b.Fragment,ek=(0,b.createContext)(null),eP=(0,b.createContext)(null),eR=Object.assign((0,U.yV)(function(e,t){let n=(0,$.T)(t),{enabled:r=!0,...i}=e;return r?b.createElement(eO,{...i,ref:n}):(0,U.sY)({ourProps:{ref:n},theirProps:i,slot:{},defaultTag:ex,name:"Portal"})}),{Group:(0,U.yV)(function(e,t){let{target:n,...r}=e,i={ref:(0,$.T)(t)};return b.createElement(ek.Provider,{value:n},(0,U.sY)({ourProps:i,theirProps:r,defaultTag:eT,name:"Popover.Group"}))})});var eC=((p=eC||{})[p.Open=0]="Open",p[p.Closed=1]="Closed",p),eA=((y=eA||{})[y.SetTitleId=0]="SetTitleId",y);let eN={0:(e,t)=>e.titleId===t.id?e:{...e,titleId:t.id}},e_=(0,b.createContext)(null);function ej(e){let t=(0,b.useContext)(e_);if(null===t){let t=Error("<".concat(e," /> is missing a parent <Dialog /> component."));throw Error.captureStackTrace&&Error.captureStackTrace(t,ej),t}return t}function eL(e,t){return(0,N.E)(t.type,eN,e,t)}e_.displayName="DialogContext";let eD=U.VN.RenderStrategy|U.VN.Static,eF=(0,U.yV)(function(e,t){let n,r,i,o,a,s=(0,b.useId)(),{id:u="headlessui-dialog-".concat(s),open:c,onClose:l,initialFocus:d,role:f="dialog",autoFocus:h=!0,__demoMode:v=!1,...p}=e,[y,g]=(0,b.useState)(0),m=(0,b.useRef)(!1);
4f="dialog"===f||"alertdialog"===f?f:(m.current||(m.current=!0,console.warn("Invalid role [".concat(f,"] passed to <Dialog />. Only `dialog` and and `alertdialog` are supported. Using `dialog` instead."))),"dialog");let E=(0,en.oJ)();void 0===c&&null!==E&&(c=(E&en.ZM.Open)===en.ZM.Open);let O=(0,b.useRef)(null),P=(0,$.T)(O,t),R=q(O),j=e.hasOwnProperty("open")||null!==E,L=e.hasOwnProperty("onClose");if(!j&&!L)throw Error("You have to provide an `open` and an `onClose` prop to the `Dialog` component.");if(!j)throw Error("You provided an `onClose` prop to the `Dialog`, but forgot an `open` prop.");if(!L)throw Error("You provided an `open` prop to the `Dialog`, but forgot an `onClose` prop.");if("boolean"!=typeof c)throw Error("You provided an `open` prop to the `Dialog`, but the value is not a boolean. Received: ".concat(c));if("function"!=typeof l)throw Error("You provided an `onClose` prop to the `Dialog`, but the value is not a function. Received: ".concat(l));let D=c?0:1,[F,I]=(0,b.useReducer)(eL,{titleId:null,descriptionId:null,panelRef:(0,b.createRef)()}),V=(0,w.z)(()=>l(!1)),z=(0,w.z)(e=>I({type:0,id:e})),X=!!(0,Z.H)()&&0===D,Q=y>1,ee=null!==(0,b.useContext)(e_),[er,eo]=(n=(0,b.useContext)(eP),r=(0,b.useRef)([]),i=(0,w.z)(e=>(r.current.push(e),n&&n.register(e),()=>o(e))),o=(0,w.z)(e=>{let t=r.current.indexOf(e);-1!==t&&r.current.splice(t,1),n&&n.unregister(e)}),a=(0,b.useMemo)(()=>({register:i,unregister:o,portals:r}),[i,o,r]),[r,(0,b.useMemo)(()=>function(e){let{children:t}=e;return b.createElement(eP.Provider,{value:a},t)},[a])]),{resolveContainers:eu,mainTreeNodeRef:el,MainTreeNode:ed}=function(){var e;let{defaultContainers:t=[],portals:n,mainTreeNodeRef:r}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=(0,b.useRef)(null!=(e=null==r?void 0:r.current)?e:null),o=q(i),a=(0,w.z)(()=>{var e,r,a;let s=[];for(let e of t)null!==e&&(e instanceof HTMLElement?s.push(e):"current"in e&&e.current instanceof HTMLElement&&s.push(e.current));if(null!=n&&n.current)for(let e of n.current)s.push(e);for(let t of null!=(e=null==o?void 0:o.querySelectorAll("html > *, body > *"))?e:[])t!==document.body&&t!==document.head&&t instanceof HTMLElement&&"headlessui-portal-root"!==t.id&&(t.contains(i.current)||t.contains(null==(a=null==(r=i.current)?void 0:r.getRootNode())?void 0:a.host)||s.some(e=>t.contains(e))||s.push(t));return s});
4return{resolveContainers:a,contains:(0,w.z)(e=>a().some(t=>t.contains(e))),mainTreeNodeRef:i,MainTreeNode:(0,b.useMemo)(()=>function(){return null!=r?null:b.createElement(Y,{features:K.Hidden,ref:i})},[i,r])}}({portals:er,defaultContainers:[{get current(){var ef;return null!=(ef=F.panelRef.current)?ef:O.current}}]}),eh=null!==E&&(E&en.ZM.Closing)===en.ZM.Closing;!function(){let{allowed:e,disallowed:t}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=!(arguments.length>1)||void 0===arguments[1]||arguments[1];(0,k.e)(()=>{var r,i;if(!n)return;let o=(0,x.k)();for(let e of null!=(r=null==t?void 0:t())?r:[])e&&o.add(C(e));let a=null!=(i=null==e?void 0:e())?i:[];for(let e of a){if(!e)continue;let t=T(e);if(!t)continue;let n=e.parentElement;for(;n&&n!==t.body;){for(let e of n.children)a.some(t=>e.contains(t))||o.add(C(e));n=n.parentElement}}return o.dispose},[n,e,t])}({allowed:(0,w.z)(()=>{var e,t;return[null!=(t=null==(e=O.current)?void 0:e.closest("[data-headlessui-portal]"))?t:null]}),disallowed:(0,w.z)(()=>{var e,t;return[null!=(t=null==(e=el.current)?void 0:e.closest("body > *:not(#headlessui-portal-root)"))?t:null]})},!v&&!Q&&!eh&&X),function(e,t){let n=!(arguments.length>2)||void 0===arguments[2]||arguments[2],r=(0,b.useRef)(!1);function i(n,i){if(!r.current||n.defaultPrevented)return;let o=i(n);if(null!==o&&o.getRootNode().contains(o)&&o.isConnected){for(let t of function e(t){return"function"==typeof t?e(t()):Array.isArray(t)||t instanceof Set?t:[t]}(e)){if(null===t)continue;let e=t instanceof HTMLElement?t:t.current;if(null!=e&&e.contains(o)||n.composed&&n.composedPath().includes(e))return}return!function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return e!==(null==(t=T(e))?void 0:t.body)&&(0,N.E)(n,{0:()=>e.matches(_),1(){let t=e;for(;null!==t;){if(t.matches(_))return!0;t=t.parentElement}return!1}})}(o,M.Loose)&&-1!==o.tabIndex&&n.preventDefault(),t(n,o)}}(0,b.useEffect)(()=>{requestAnimationFrame(()=>{r.current=n})},[n]);let o=(0,b.useRef)(null);B("pointerdown",e=>{var t,n;r.current&&(o.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target)},!0),B("mousedown",e=>{var t,n;r.current&&(o.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target)},!0),B("click",e=>{H()||/Android/gi.test(window.navigator.userAgent)||o.current&&(i(e,()=>o.current),o.current=null)},!0),B("touchend",e=>i(e,()=>e.target instanceof HTMLElement?e.target:null),!0),G("blur",e=>i(e,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}(eu,e=>{e.preventDefault(),V()},!(!X||Q));let ev=!(Q||0!==D);S(null==R?void 0:R.defaultView,"keydown",e=>{ev&&(e.defaultPrevented||e.key===eS.Escape&&(e.preventDefault(),e.stopPropagation(),V()))});let ep=!(eh||0!==D||ee);(function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>[document.body];!function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>({containers:[]}),r=(0,b.useSyncExternalStore)(W.subscribe,W.getSnapshot,W.getSnapshot),i=e?r.get(e):void 0;i&&i.count,(0,k.e)(()=>{if(!(!e||!t))return W.dispatch("PUSH",e,n),()=>W.dispatch("POP",e,n)},[t,e])}(e,t,e=>{var t;return{containers:[...null!=(t=e.containers)?t:[],n]}})})(R,!v&&ep,eu),(0,A.m)(O,V,0===D);let[ey,eg]=function(){let[e,t]=(0,b.useState)([]);return[e.length>0?e.join(" "):void 0,(0,b.useMemo)(()=>function(e){let n=(0,w.z)(e=>(t(t=>[...t,e]),()=>t(t=>{let n=t.slice(),r=n.indexOf(e);return -1!==r&&n.splice(r,1),n}))),r=(0,b.useMemo)(()=>({register:n,slot:e.slot,name:e.name,props:e.props,value:e.value}),[n,e.slot,e.name,e.props,e.value]);return b.createElement(ec.Provider,{value:r},e.children)},[t])]}(),em=(0,b.useMemo)(()=>[{dialogState:D,close:V,setTitleId:z},F],[D,F,V,z]),eE=(0,b.useMemo)(()=>({open:0===D}),[D]),ex={ref:P,id:u,role:f,tabIndex:-1,"aria-modal":0===D||void 0,"aria-labelledby":F.titleId,"aria-describedby":ey},eO=!function(){var e;let[t]=(0,b.useState)(()=>"function"==typeof window.matchMedia?window.matchMedia("(pointer: coarse)"):null),[n,r]=(0,b.useState)(null!=(e=null==t?void 0:t.matches)&&e);return(0,k.e)(()=>
4{if(t)return t.addEventListener("change",e),()=>t.removeEventListener("change",e);function e(e){r(e.matches)}},[t]),n}(),eT=X?(0,N.E)(Q?"parent":"leaf",{parent:eb.RestoreFocus,leaf:eb.All&~eb.FocusLock}):eb.None;return h&&(eT|=eb.AutoFocus),eO||(eT&=~eb.InitialFocus),v&&(eT=eb.None),b.createElement(es,{type:"Dialog",enabled:0===D,element:O,onUpdate:(0,w.z)((e,t)=>{"Dialog"===t&&(0,N.E)(e,{[ea.Add]:()=>g(e=>e+1),[ea.Remove]:()=>g(e=>e-1)})})},b.createElement(ei,{force:!0},b.createElement(eR,null,b.createElement(e_.Provider,{value:em},b.createElement(eR.Group,{target:O},b.createElement(ei,{force:!1},b.createElement(eg,{slot:eE,name:"Dialog.Description"},b.createElement(eo,null,b.createElement(ew,{initialFocus:d,initialFocusFallback:O,containers:eu,features:eT},b.createElement(J,{value:V},(0,U.sY)({ourProps:ex,theirProps:p,slot:eE,defaultTag:"div",features:eD,visible:0===D,name:"Dialog"})))))))))),b.createElement(et,null,b.createElement(ed,null)))}),eM=(0,U.yV)(function(e,t){let n=(0,b.useId)(),{id:r="headlessui-dialog-panel-".concat(n),...i}=e,[{dialogState:o},a]=ej("Dialog.Panel"),s=(0,$.T)(t,a.panelRef),u=(0,b.useMemo)(()=>({open:0===o}),[o]),c=(0,w.z)(e=>{e.stopPropagation()});return(0,U.sY)({ourProps:{ref:s,id:r,onClick:c},theirProps:i,slot:u,defaultTag:"div",name:"Dialog.Panel"})}),eI=(0,U.yV)(function(e,t){let n=(0,b.useId)(),{id:r="headlessui-dialog-title-".concat(n),...i}=e,[{dialogState:o,setTitleId:a}]=ej("Dialog.Title"),s=(0,$.T)(t);(0,b.useEffect)(()=>(a(r),()=>a(null)),[r,a]);let u=(0,b.useMemo)(()=>({open:0===o}),[o]);return(0,U.sY)({ourProps:{ref:s,id:r},theirProps:i,slot:u,defaultTag:"h2",name:"Dialog.Title"})}),eV=Object.assign(eF,{Panel:eM,Title:eI,Description:el})},5247:function(e,t,n){"use strict";let r;n.d(t,{u:function(){return j},x:function(){return _}});var i=n(7294),o=n(3285),a=n(3),s=n(2308),u=n(1378),c=n(5508),l=n(607),d=n(2047),f=n(1813),h=n(3580),v=n(8844);function p(e){let t={called:!1};return function(){for(var n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];if(!t.called)return t.called=!0,e(...r)}}function y(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];e&&n.length>0&&e.classList.add(...n)}function g(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];e&&n.length>0&&e.classList.remove(...n)}var m=n(4358),b=n(5602),w=n(8287);function E(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e.split(/\s+/).filter(e=>e.length>1)}function S(e){var t;return!!(e.enter||e.enterFrom||e.enterTo||e.leave||e.leaveFrom||e.leaveTo)||(null!=(t=e.as)?t:R)!==i.Fragment||1===i.Children.count(e.children)}let x=(0,i.createContext)(null);x.displayName="TransitionContext";var O=((r=O||{}).Visible="visible",r.Hidden="hidden",r);let T=(0,i.createContext)(null);function k(e){return"children"in e?k(e.children):e.current.filter(e=>{let{el:t}=e;return null!==t.current}).filter(e=>{let{state:t}=e;return"visible"===t}).length>0}function P(e,t){let n=(0,c.E)(e),r=(0,i.useRef)([]),u=(0,s.t)(),l=(0,o.G)(),d=(0,a.z)(function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:w.l4.Hidden,i=r.current.findIndex(t=>{let{el:n}=t;return n===e});
4-1!==i&&((0,v.E)(t,{[w.l4.Unmount](){r.current.splice(i,1)},[w.l4.Hidden](){r.current[i].state="hidden"}}),l.microTask(()=>{var e;!k(r)&&u.current&&(null==(e=n.current)||e.call(n))}))}),f=(0,a.z)(e=>{let t=r.current.find(t=>{let{el:n}=t;return n===e});return t?"visible"!==t.state&&(t.state="visible"):r.current.push({el:e,state:"visible"}),()=>d(e,w.l4.Unmount)}),h=(0,i.useRef)([]),p=(0,i.useRef)(Promise.resolve()),y=(0,i.useRef)({enter:[],leave:[],idle:[]}),g=(0,a.z)((e,n,r)=>{h.current.splice(0),t&&(t.chains.current[n]=t.chains.current[n].filter(t=>{let[n]=t;return n!==e})),null==t||t.chains.current[n].push([e,new Promise(e=>{h.current.push(e)})]),null==t||t.chains.current[n].push([e,new Promise(e=>{Promise.all(y.current[n].map(e=>{let[t,n]=e;return n})).then(()=>e())})]),"enter"===n?p.current=p.current.then(()=>null==t?void 0:t.wait.current).then(()=>r(n)):r(n)}),m=(0,a.z)((e,t,n)=>{Promise.all(y.current[t].splice(0).map(e=>{let[t,n]=e;return n})).then(()=>{var e;null==(e=h.current.shift())||e()}).then(()=>n(t))});return(0,i.useMemo)(()=>({children:r,register:f,unregister:d,onStart:g,onStop:m,wait:p,chains:y}),[f,d,r,g,m,y,p])}T.displayName="NestingContext";let R=i.Fragment,C=w.VN.RenderStrategy,A=(0,w.yV)(function(e,t){let{show:n,appear:r=!1,unmount:o=!0,...s}=e,c=(0,i.useRef)(null),h=S(e),v=(0,f.T)(...h?[c,t]:null===t?[]:[t]);(0,d.H)();let p=(0,m.oJ)();if(void 0===n&&null!==p&&(n=(p&m.ZM.Open)===m.ZM.Open),void 0===n)throw Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[y,g]=(0,i.useState)(n?"visible":"hidden"),b=P(()=>{n||g("hidden")}),[E,O]=(0,i.useState)(!0),R=(0,i.useRef)([n]);(0,u.e)(()=>{!1!==E&&R.current[R.current.length-1]!==n&&(R.current.push(n),O(!1))},[R,n]);let A=(0,i.useMemo)(()=>({show:n,appear:r,initial:E}),[n,r,E]);(0,l.m)(c,()=>g("hidden")),(0,u.e)(()=>{n?g("visible"):k(b)||null===c.current||g("hidden")},[n,b]);let _={unmount:o},j=(0,a.z)(()=>{var t;E&&O(!1),null==(t=e.beforeEnter)||t.call(e)}),L=(0,a.z)(()=>{var t;E&&O(!1),null==(t=e.beforeLeave)||t.call(e)});return i.createElement(T.Provider,{value:b},i.createElement(x.Provider,{value:A},(0,w.sY)({ourProps:{..._,as:i.Fragment,children:i.createElement(N,{ref:v,..._,...s,beforeEnter:j,beforeLeave:L})},theirProps:{},defaultTag:i.Fragment,features:C,visible:"visible"===y,name:"Transition"})))}),N=(0,w.yV)(function(e,t){var n,r,l;let{beforeEnter:O,afterEnter:A,beforeLeave:N,afterLeave:_,enter:j,enterFrom:L,enterTo:D,entered:F,leave:M,leaveFrom:I,leaveTo:V,...z}=e,H=(0,i.useRef)(null),B=S(e),G=(0,f.T)(...B?[H,t]:null===t?[]:[t]),q=null==(n=z.unmount)||n?w.l4.Unmount:w.l4.Hidden,{show:U,appear:K,initial:Y}=function(){let e=(0,i.useContext)(x);if(null===e)throw Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),[W,Z]=(0,i.useState)(U?"visible":"hidden"),$=function(){let e=(0,i.useContext)(T);if(null===e)throw Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),{register:X,unregister:J}=$;(0,u.e)(()=>X(H),[X,H]),(0,u.e)(()=>{if(q===w.l4.Hidden&&H.current){if(U&&"visible"!==W){Z("visible");return}return(0,v.E)(W,{hidden:()=>J(H),visible:()=>X(H)})}},[W,H,X,J,U,q]);let Q=(0,c.E)({base:E(z.className),enter:E(j),enterFrom:E(L),enterTo:E(D),entered:E(F),leave:E(M),leaveFrom:E(I),leaveTo:E(V)}),ee=(0,c.E)({beforeEnter:O,afterEnter:A,beforeLeave:N,afterLeave:_}),et=(0,d.H)();(0,u.e)(()=>{if(B&&et&&"visible"===W&&null===H.current)throw Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[H,W,et,B]);let en=K&&U&&Y,er=en?"enter":et&&(!Y||K)?U?"enter":"leave":"idle",ei=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,[t,n]=(0,i.useState)(e),r=(0,s.t)(),o=(0,i.useCallback)(e=>{r.current&&n(t=>t|e)},[t,r]),a=(0,i.useCallback)(e=>!!(t&e),[t]);return{flags:t,addFlag:o,hasFlag:a,removeFlag:(0,i.useCallback)(e=>{r.current&&n(t=>t&~e)},[n,r]),toggleFlag:(0,i.useCallback)(e=>{r.current&&n(t=>t^e)},[n])}}(0),eo=(0,a.z)(e=>(0,v.E)(e,{enter:()=>{var e,t;ei.addFlag(m.ZM.Opening),null==(t=(e=ee.current).beforeEnter)||t.call(e)},leave:()=>{var e,t;ei.addFlag(m.ZM.Closing),null==(t=(e=ee.current).beforeLeave)||t.call(e)},idle:()=>{}})),ea=(0,a.z)(e=>(0,v.E)(e,{enter:()=>{var e,t;ei.removeFlag(m.ZM.Opening),null==(t=(e=ee.current).afterEnter)||t.call(e)},leave:()=>{var e,t;ei.removeFlag(m.ZM.Closing),null==(t=(e=ee.current).afterLeave)||t.call(e)},idle:()=>{}})),es=(0,i.useRef)(!1),eu=P(()=>{es.current||(Z("hidden"),J(H))},$);
4!function(e){let{container:t,direction:n,classes:r,onStart:a,onStop:c}=e,l=(0,s.t)(),d=(0,o.G)(),f=(0,i.useRef)(!1);(0,u.e)(()=>{if("idle"===n||!l.current)return;a.current(n);let e=t.current;return e?d.add(function(e,t){let{direction:n,done:r,classes:i,inFlight:o}=t,a=(0,h.k)(),s=void 0!==r?p(r):()=>{};"enter"===n&&(e.removeAttribute("hidden"),e.style.display="");let u=(0,v.E)(n,{enter:()=>i.enter,leave:()=>i.leave}),c=(0,v.E)(n,{enter:()=>i.enterTo,leave:()=>i.leaveTo}),l=(0,v.E)(n,{enter:()=>i.enterFrom,leave:()=>i.leaveFrom});return function(e,t){let{inFlight:n,prepare:r}=t;if(null!=n&&n.current){r();return}let i=e.style.transition;e.style.transition="none",r(),e.offsetHeight,e.style.transition=i}(e,{prepare(){g(e,...i.base,...i.enter,...i.enterTo,...i.enterFrom,...i.leave,...i.leaveFrom,...i.leaveTo,...i.entered),y(e,...i.base,...u,...l)},inFlight:o}),o&&(o.current=!0),a.nextFrame(()=>{a.add(function(e,t){let n=p(t),r=(0,h.k)();if(!e)return r.dispose;let{transitionDuration:i,transitionDelay:o}=getComputedStyle(e),[a,s]=[i,o].map(e=>{let[t=0]=e.split(",").filter(Boolean).map(e=>e.includes("ms")?parseFloat(e):1e3*parseFloat(e)).sort((e,t)=>t-e);return t}),u=a+s;if(0!==u){let t=r.group(r=>{let i=r.setTimeout(()=>{n(),r.dispose()},u);r.addEventListener(e,"transitionrun",o=>{o.target===o.currentTarget&&(i(),r.addEventListener(e,"transitioncancel",e=>{e.target===e.currentTarget&&(n(),t())}))})});r.addEventListener(e,"transitionend",e=>{e.target===e.currentTarget&&(n(),r.dispose())})}else n();return r.dispose}(e,()=>(g(e,...i.base,...u),y(e,...i.base,...i.entered,...c),o&&(o.current=!1),s()))),g(e,...i.base,...u,...l),y(e,...i.base,...u,...c)}),a.dispose}(e,{direction:n,classes:r.current,inFlight:f,done(){c.current(n)}})):c.current(n),d.dispose},[n])}({container:H,classes:Q,direction:er,onStart:(0,c.E)(e=>{es.current=!0,eu.onStart(H,e,eo)}),onStop:(0,c.E)(e=>{es.current=!1,eu.onStop(H,e,ea),"leave"!==e||k(eu)||(Z("hidden"),J(H))})});let ec=z;return en?ec={...ec,className:(0,b.A)(z.className,...Q.current.enter,...Q.current.enterFrom)}:(es.current?ec.className=(0,b.A)(z.className,null==(r=H.current)?void 0:r.className):ec.className=(0,b.A)(z.className,null==(l=H.current)?void 0:l.className,...(0,v.E)(er,{enter:[...Q.current.enterTo,...Q.current.entered],leave:Q.current.leaveTo,idle:[]})),""===ec.className&&delete ec.className),i.createElement(T.Provider,{value:eu},i.createElement(m.up,{value:(0,v.E)(W,{visible:m.ZM.Open,hidden:m.ZM.Closed})|ei.flags},(0,w.sY)({ourProps:{ref:G},theirProps:ec,defaultTag:R,features:C,visible:"visible"===W,name:"Transition.Child"})))}),_=(0,w.yV)(function(e,t){let n=null!==(0,i.useContext)(x),r=null!==(0,m.oJ)();return i.createElement(i.Fragment,null,!n&&r?i.createElement(A,{ref:t,...e}):i.createElement(N,{ref:t,...e}))}),j=Object.assign(A,{Child:_,Root:A})},3285:function(e,t,n){"use strict";n.d(t,{G:function(){return o}});var r=n(7294),i=n(3580);function o(){let[e]=(0,r.useState)(i.k);return(0,r.useEffect)(()=>()=>e.dispose(),[e]),e}},3:function(e,t,n){"use strict";n.d(t,{z:function(){return o}});var r=n(7294),i=n(5508);let o=function(e){let t=(0,i.E)(e);return r.useCallback(function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.current(...n)},[t])}},2308:function(e,t,n){"use strict";n.d(t,{t:function(){return o}});var r=n(7294),i=n(1378);function o(){let e=(0,r.useRef)(!1);return(0,i.e)(()=>(e.current=!0,()=>{e.current=!1}),[]),e}},1378:function(e,t,n){"use strict";n.d(t,{e:function(){return o}});var r=n(7294),i=n(1830);let o=(e,t)=>{i.O.isServer?(0,r.useEffect)(e,t):(0,r.useLayoutEffect)(e,t)}},5508:function(e,t,n){"use strict";n.d(t,{E:function(){return o}});var r=n(7294),i=n(1378);function o(e){let t=(0,r.useRef)(e);return(0,i.e)(()=>{t.current=e},[e]),t}},607:function(e,t,n){"use strict";n.d(t,{m:function(){return a}});var r=n(7294),i=n(3580),o=n(5508);function a(e,t){let n=!(arguments.length>2)||void 0===arguments[2]||arguments[2],a=(0,o.E)(e=>{let n=e.getBoundingClientRect();0===n.x&&0===n.y&&0===n.width&&0===n.height&&t()});(0,r.useEffect)(()=>{if(!n)return;let t=null===e?null:e instanceof HTMLElement?e:e.current;if(!t)return;let r=(0,i.k)();if("undefined"!=typeof ResizeObserver){let e=new ResizeObserver(()=>a.current(t));e.observe(t),r.add(()=>e.disconnect())}if("undefined"!=typeof IntersectionObserver){let e=new IntersectionObserver(()=>a.current(t));e.observe(t),r.add(()=>e.disconnect())}return()=>r.dispose()},[e,a,n])}},2047:function(e,t,n){"use strict";n.d(t,{H:function(){return a}});var r,i=n(7294),o=n(1830);function a(){let e;let t=(e="undefined"==typeof document,(0,(r||(r=n.t(i,2))).useSyncExternalStore)(()=>()=>{},()=>!1,()=>!e)),[a,s]=i.useState(o.O.isHandoffComplete);return a&&!1===o.O.isHandoffComplete&&s(!1),i.useEffect(()=>{!0!==a&&s(!0)},[a]),i.useEffect(()=>o.O.handoff(),[]),!t&&a}},1813:function(e,t,n){"use strict";n.d(t,{T:function(){return s},h:function(){return a}});var r=n(7294),i=n(3);let o=Symbol();function a(e){let t=!(arguments.length>1)||void 0===arguments[1]||arguments[1];return Object.assign(e,{[o]:t})}function s(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];let a=(0,r.useRef)(t);(0,r.useEffect)(()=>{a.current=t},[t]);let s=(0,i.z)(e=>{for(let t of a.current)null!=t&&("function"==typeof t?t(e):t.current=e)});return t.every(e=>null==e||(null==e?void 0:e[o]))?void 0:s}},4358:function(e,t,n){"use strict";let r;n.d(t,{ZM:function(){return a},oJ:function(){return s},up:function(){return u}});var i=n(7294);let o=(0,i.createContext)(null);o.displayName="OpenClosedContext";var a=((r=a||{})[r.Open=1]="Open",r[r.Closed=2]="Closed",r[r.Closing=4]="Closing",r[r.Opening=8]="Opening",r);function s(){return(0,i.useContext)(o)}function u(e){let{value:t,children:n}=e;return i.createElement(o.Provider,{value:t},n)}},5602:function(e,t,n){"use strict";function r(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return Array.from(new Set(t.flatMap(e=>
4"string"==typeof e?e.split(" "):[]))).filter(Boolean).join(" ")}n.d(t,{A:function(){return r}})},3580:function(e,t,n){"use strict";n.d(t,{k:function(){return function e(){let t=[],n={addEventListener:(e,t,r,i)=>(e.addEventListener(t,r,i),n.add(()=>e.removeEventListener(t,r,i))),requestAnimationFrame(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let i=requestAnimationFrame(...t);return n.add(()=>cancelAnimationFrame(i))},nextFrame(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return n.requestAnimationFrame(()=>n.requestAnimationFrame(...t))},setTimeout(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let i=setTimeout(...t);return n.add(()=>clearTimeout(i))},microTask(){for(var e=arguments.length,t=Array(e),i=0;i<e;i++)t[i]=arguments[i];let o={current:!0};return(0,r.Y)(()=>{o.current&&t[0]()}),n.add(()=>{o.current=!1})},style(e,t,n){let r=e.style.getPropertyValue(t);return Object.assign(e.style,{[t]:n}),this.add(()=>{Object.assign(e.style,{[t]:r})})},group(t){let n=e();return t(n),this.add(()=>n.dispose())},add:e=>(t.includes(e)||t.push(e),()=>{let n=t.indexOf(e);if(n>=0)for(let e of t.splice(n,1))e()}),dispose(){for(let e of t.splice(0))e()}};return n}}});var r=n(1291)},1830:function(e,t,n){"use strict";n.d(t,{O:function(){return s}});var r=Object.defineProperty,i=(e,t,n)=>t in e?r(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,o=(e,t,n)=>(i(e,"symbol"!=typeof t?t+"":t,n),n);class a{set(e){this.current!==e&&(this.handoffState="pending",this.currentId=0,this.current=e)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return"server"===this.current}get isClient(){return"client"===this.current}detect(){return"undefined"==typeof document?"server":"client"}handoff(){"pending"===this.handoffState&&(this.handoffState="complete")}get isHandoffComplete(){return"complete"===this.handoffState}constructor(){o(this,"current",this.detect()),o(this,"handoffState","pending"),o(this,"currentId",0)}}let s=new a},8844:function(e,t,n){"use strict";function r(e,t){for(var n=arguments.length,i=Array(n>2?n-2:0),o=2;o<n;o++)i[o-2]=arguments[o];if(e in t){let n=t[e];return"function"==typeof n?n(...i):n}let a=Error('Tried to handle "'.concat(e,'" but there is no handler defined. Only defined handlers are: ').concat(Object.keys(t).map(e=>'"'.concat(e,'"')).join(", "),"."));throw Error.captureStackTrace&&Error.captureStackTrace(a,r),a}n.d(t,{E:function(){return r}})},1291:function(e,t,n){"use strict";function r(e){"function"==typeof queueMicrotask?queueMicrotask(e):Promise.resolve().then(e).catch(e=>setTimeout(()=>{throw e}))}n.d(t,{Y:function(){return r}})},8287:function(e,t,n){"use strict";let r,i;n.d(t,{VN:function(){return u},l4:function(){return c},sY:function(){return l},yV:function(){return v}});var o=n(7294),a=n(5602),s=n(8844),u=((r=u||{})[r.None=0]="None",r[r.RenderStrategy=1]="RenderStrategy",r[r.Static=2]="Static",r),c=((i=c||{})[i.Unmount=0]="Unmount",i[i.Hidden=1]="Hidden",i);function l(e){let{ourProps:t,theirProps:n,slot:r,defaultTag:i,features:o,visible:a=!0,name:u,mergeRefs:c}=e;c=null!=c?c:f;let l=h(n,t);if(a)return d(l,r,i,u,c);let v=null!=o?o:0;if(2&v){let{static:e=!1,...t}=l;if(e)return d(t,r,i,u,c)}if(1&v){let{unmount:e=!0,...t}=l;return(0,s.E)(e?0:1,{0:()=>null,1:()=>d({...t,hidden:!0,style:{display:"none"}},r,i,u,c)})}return d(l,r,i,u,c)}function d(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0,{as:s=n,children:u,refName:c="ref",...l}=y(e,["unmount","static"]),d=void 0!==e.ref?{[c]:e.ref}:{},f="function"==typeof u?u(t):u;"className"in l&&l.className&&"function"==typeof l.className&&(l.className=l.className(t)),l["aria-labelledby"]&&l["aria-labelledby"]===l.id&&(l["aria-labelledby"]=void 0);let v={};if(t){let e=!1,n=[];for(let[r,i]of Object.entries(t))"boolean"==typeof i&&(e=!0),!0===i&&n.push(r.replace(/([A-Z])/g,e=>"-".concat(e.toLowerCase())));if(e)for(let e of(v["data-headlessui-state"]=n.join(" "),n))v["data-".concat(e)
4]=""}if(s===o.Fragment&&(Object.keys(p(l)).length>0||Object.keys(p(v)).length>0)){if(!(0,o.isValidElement)(f)||Array.isArray(f)&&f.length>1){if(Object.keys(p(l)).length>0)throw Error(['Passing props on "Fragment"!',"","The current component <".concat(r,' /> is rendering a "Fragment".'),"However we need to passthrough the following props:",Object.keys(p(l)).concat(Object.keys(p(v))).map(e=>"  - ".concat(e)).join("\n"),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map(e=>"  - ".concat(e)).join("\n")].join("\n"))}else{let e=f.props,t=null==e?void 0:e.className,n="function"==typeof t?function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return(0,a.A)(t(...n),l.className)}:(0,a.A)(t,l.className),r=h(f.props,p(y(l,["ref"])));for(let e in v)e in r&&delete v[e];return(0,o.cloneElement)(f,Object.assign({},r,v,d,{ref:i(f.ref,d.ref)},n?{className:n}:{}))}}return(0,o.createElement)(s,Object.assign({},y(l,["ref"]),s!==o.Fragment&&d,s!==o.Fragment&&v),f)}function f(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.every(e=>null==e)?void 0:e=>{for(let n of t)null!=n&&("function"==typeof n?n(e):n.current=e)}}function h(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];if(0===t.length)return{};if(1===t.length)return t[0];let r={},i={};for(let e of t)for(let t in e)t.startsWith("on")&&"function"==typeof e[t]?(null!=i[t]||(i[t]=[]),i[t].push(e[t])):r[t]=e[t];if(r.disabled||r["aria-disabled"])for(let e in i)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(e)&&(i[e]=[e=>{var t;return null==(t=null==e?void 0:e.preventDefault)?void 0:t.call(e)}]);for(let e in i)Object.assign(r,{[e](t){for(var n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];for(let n of i[e]){if((t instanceof Event||(null==t?void 0:t.nativeEvent)instanceof Event)&&t.defaultPrevented)return;n(t,...r)}}});return r}function v(e){var t;return Object.assign((0,o.forwardRef)(e),{displayName:null!=(t=e.displayName)?t:e.name})}function p(e){let t=Object.assign({},e);for(let e in t)void 0===t[e]&&delete t[e];return t}function y(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=Object.assign({},e);for(let e of t)e in n&&delete n[e];return n}},6856:function(e,t,n){"use strict";var r=n(7294);let i=r.forwardRef(function(e,t){let{title:n,titleId:i,...o}=e;return r.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},o),n?r.createElement("title",{id:i},n):null,r.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5M16.5 12 12 16.5m0 0L7.5 12m4.5 4.5V3"}))});t.Z=i},8223:function(e,t,n){"use strict";var r=n(7294);let i=r.forwardRef(function(e,t){let{title:n,titleId:i,...o}=e;return r.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},o),n?r.createElement("title",{id:i},n):null,r.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M10.5 19.5 3 12m0 0 7.5-7.5M3 12h18"}))});t.Z=i},777:function(e,t,n){"use strict";var r=n(7294);let i=r.forwardRef(function(e,t){let{title:n,titleId:i,...o}=e;return r.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},o),n?r.createElement("title",{id:i},n):null,r.createElement("path",{fillRule:"evenodd",d:"M17.834 6.166a8.25 8.25 0 1 0 0 11.668.75.75 0 0 1 1.06 1.06c-3.807 3.808-9.98 3.808-13.788 0-3.808-3.807-3.808-9.98 0-13.788 3.807-3.808 9.98-3.808 13.788 0A9.722 9.722 0 0 1 21.75 12c0 .975-.296 1.887-.809 2.571-.514.685-1.28 1.179-2.191 1.179-.904 0-1.666-.487-2.18-1.164a5.25 5.25 0 1 1-.82-6.26V8.25a.75.75 0 0 1 1.5 0V12c0 .682.208 1.27.509 1.671.3.401.659.579.991.579.332 0 .69-.178.991-.579.3-.4.509-.99.509-1.671a8.222 8.222 0 0 0-2.416-5.834ZM15.75 12a3.75 3.75 0 1 0-7.5 0 3.75 3.75 0 0 0 7.5 0Z",clipRule:"evenodd"}))});t.Z=i},7243:function(e,t,n){"use strict";var r=n(7294);let i=r.forwardRef(function(e,t){let{title:n,titleId:i,...o}=e;return r.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"
4currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},o),n?r.createElement("title",{id:i},n):null,r.createElement("path",{fillRule:"evenodd",d:"M4.5 5.653c0-1.427 1.529-2.33 2.779-1.643l11.54 6.347c1.295.712 1.295 2.573 0 3.286L7.28 19.99c-1.25.687-2.779-.217-2.779-1.643V5.653Z",clipRule:"evenodd"}))});t.Z=i},9226:function(e,t,n){"use strict";var r=n(7294);let i=r.forwardRef(function(e,t){let{title:n,titleId:i,...o}=e;return r.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},o),n?r.createElement("title",{id:i},n):null,r.createElement("path",{fillRule:"evenodd",d:"M5.47 5.47a.75.75 0 0 1 1.06 0L12 10.94l5.47-5.47a.75.75 0 1 1 1.06 1.06L13.06 12l5.47 5.47a.75.75 0 1 1-1.06 1.06L12 13.06l-5.47 5.47a.75.75 0 0 1-1.06-1.06L10.94 12 5.47 6.53a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"}))});t.Z=i}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.