diff --git a/assets/dotlottie-state-machine-manager-MM65C4SH-HEQNG5J3-f0445b80.js b/assets/dotlottie-state-machine-manager-DE27JEWO-HSSKNWU7-526baec8.js similarity index 99% rename from assets/dotlottie-state-machine-manager-MM65C4SH-HEQNG5J3-f0445b80.js rename to assets/dotlottie-state-machine-manager-DE27JEWO-HSSKNWU7-526baec8.js index fed39094..353f72f5 100644 --- a/assets/dotlottie-state-machine-manager-MM65C4SH-HEQNG5J3-f0445b80.js +++ b/assets/dotlottie-state-machine-manager-DE27JEWO-HSSKNWU7-526baec8.js @@ -1,4 +1,4 @@ -var Ee=Object.defineProperty;var Oe=(e,t,n)=>t in e?Ee(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var X=(e,t,n)=>(Oe(e,typeof t!="symbol"?t+"":t,n),n);import{v as It,n as Ht,F as ke,t as Te}from"./index-2024fbcb.js";var v=function(){return v=Object.assign||function(e){for(var t,n=1,i=arguments.length;n=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function O(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var i=n.call(e),r,o=[],a;try{for(;(t===void 0||t-- >0)&&!(r=i.next()).done;)o.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(a)throw a.error}}return o}function V(e,t,n){if(n||arguments.length===2)for(var i=0,r=t.length,o;i"u"||typeof i=="string"||rt(i)?{target:i,event:e}:v(v({},i),{event:e})});return n}function Ue(e){if(!(e===void 0||e===Le))return J(e)}function de(e,t,n,i,r){var o=e.options.guards,a={state:r,cond:t,_event:i};if(t.type===Rt)return((o==null?void 0:o[t.name])||t.predicate)(n,i.data,a);var s=o==null?void 0:o[t.type];if(!s)throw new Error("Guard '".concat(t.type,"' is not implemented on machine '").concat(e.id,"'."));return s(n,i.data,a)}function ve(e){return typeof e=="string"?{type:e}:e}function wt(e,t,n){var i=function(){},r=typeof e=="object",o=r?e:null;return{next:((r?e.next:e)||i).bind(o),error:((r?e.error:t)||i).bind(o),complete:((r?e.complete:n)||i).bind(o)}}function mt(e,t){return"".concat(e,":invocation[").concat(t,"]")}function $t(e){return(e.type===yt||e.type===jt&&e.to===it.Internal)&&typeof e.delay!="number"}var nt=R({type:Pe});function zt(e,t){return t&&t[e]||void 0}function vt(e,t){var n;if(j(e)||typeof e=="number"){var i=zt(e,t);T(i)?n={type:e,exec:i}:i?n=i:n={type:e,exec:void 0}}else if(T(e))n={type:e.name||e.toString(),exec:e};else{var i=zt(e.type,t);if(T(i))n=v(v({},e),{exec:i});else if(i){var r=i.type||e.type;n=v(v(v({},i),e),{type:r})}else n=e}return n}var G=function(e,t){if(!e)return[];var n=ot(e)?e:[e];return n.map(function(i){return vt(i,t)})};function Qt(e){var t=vt(e);return v(v({id:j(e)?e:t.id},t),{type:t.type})}function qe(e,t){return{type:yt,event:typeof e=="function"?e:Nt(e),delay:t?t.delay:void 0,id:t==null?void 0:t.id}}function Xe(e,t,n,i){var r={_event:n},o=R(T(e.event)?e.event(t,n.data,r):e.event),a;if(j(e.delay)){var s=i&&i[e.delay];a=T(s)?s(t,n.data,r):s}else a=T(e.delay)?e.delay(t,n.data,r):e.delay;return v(v({},e),{type:yt,_event:o,delay:a})}function Qe(e,t){return{to:t?t.to:void 0,type:jt,event:T(e)?e:Nt(e),delay:t?t.delay:void 0,id:t&&t.id!==void 0?t.id:T(e)?e.name:ue(e)}}function Ge(e,t,n,i){var r={_event:n},o=R(T(e.event)?e.event(t,n.data,r):e.event),a;if(j(e.delay)){var s=i&&i[e.delay];a=T(s)?s(t,n.data,r):s}else a=T(e.delay)?e.delay(t,n.data,r):e.delay;var c=T(e.to)?e.to(t,n.data,r):e.to;return v(v({},e),{to:c,_event:o,event:o.data,delay:a})}var We=function(e,t,n){return v(v({},e),{value:j(e.expr)?e.expr:e.expr(t,n.data,{_event:n})})},He=function(e){return{type:re,sendId:e}};function Ye(e){var t=Qt(e);return{type:N.Start,activity:t,exec:void 0}}function Ze(e){var t=T(e)?e:Qt(e);return{type:N.Stop,activity:t,exec:void 0}}function Ke(e,t,n){var i=T(e.activity)?e.activity(t,n.data):e.activity,r=typeof i=="string"?{id:i}:i,o={type:N.Stop,activity:r};return o}function tn(e,t){var n=t?"#".concat(t):"";return"".concat(N.After,"(").concat(e,")").concat(n)}function xt(e,t){var n="".concat(N.DoneState,".").concat(e),i={type:n,data:t};return i.toString=function(){return n},i}function Et(e,t){var n="".concat(N.DoneInvoke,".").concat(e),i={type:n,data:t};return i.toString=function(){return n},i}function ut(e,t){var n="".concat(N.ErrorPlatform,".").concat(e),i={type:n,data:t};return i.toString=function(){return n},i}var en=function(e){var t,n,i=[];try{for(var r=E(e),o=r.next();!o.done;o=r.next())for(var a=o.value,s=0;s0;){var u=r.shift();n=e.transition(n,u,c),i.forEach(function(f){return f.next(n)})}o=!1}},s=an({id:t.id,send:function(u){r.push(u),a()},getSnapshot:function(){return n},subscribe:function(u,f,d){var h=wt(u,f,d);return i.add(h),h.next(n),{unsubscribe:function(){i.delete(h)}}}}),c={parent:t.parent,self:s,id:t.id||"anonymous",observers:i};return n=e.start?e.start(c):n,s}var gn={sync:!1,autoForward:!1},C;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"})(C||(C={}));var mn=function(){function e(t,n){n===void 0&&(n=e.defaultOptions);var i=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=C.NotStarted,this.children=new Map,this.forwardTo=new Set,this._outgoingQueue=[],this.init=this.start,this.send=function(f,d){if(ot(f))return i.batch(f),i.state;var h=R(Nt(f,d));if(i.status===C.Stopped)return i.state;if(i.status!==C.Running&&!i.options.deferEvents)throw new Error('Event "'.concat(h.name,'" was sent to uninitialized service "').concat(i.machine.id,`". Make sure .start() is called for this service, or set { deferEvents: true } in the service options. +var Ee=Object.defineProperty;var Oe=(e,t,n)=>t in e?Ee(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var X=(e,t,n)=>(Oe(e,typeof t!="symbol"?t+"":t,n),n);import{v as It,n as Ht,F as ke,t as Te}from"./index-14a1bb9c.js";var v=function(){return v=Object.assign||function(e){for(var t,n=1,i=arguments.length;n=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function O(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var i=n.call(e),r,o=[],a;try{for(;(t===void 0||t-- >0)&&!(r=i.next()).done;)o.push(r.value)}catch(s){a={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(a)throw a.error}}return o}function V(e,t,n){if(n||arguments.length===2)for(var i=0,r=t.length,o;i"u"||typeof i=="string"||rt(i)?{target:i,event:e}:v(v({},i),{event:e})});return n}function Ue(e){if(!(e===void 0||e===Le))return J(e)}function de(e,t,n,i,r){var o=e.options.guards,a={state:r,cond:t,_event:i};if(t.type===Rt)return((o==null?void 0:o[t.name])||t.predicate)(n,i.data,a);var s=o==null?void 0:o[t.type];if(!s)throw new Error("Guard '".concat(t.type,"' is not implemented on machine '").concat(e.id,"'."));return s(n,i.data,a)}function ve(e){return typeof e=="string"?{type:e}:e}function wt(e,t,n){var i=function(){},r=typeof e=="object",o=r?e:null;return{next:((r?e.next:e)||i).bind(o),error:((r?e.error:t)||i).bind(o),complete:((r?e.complete:n)||i).bind(o)}}function mt(e,t){return"".concat(e,":invocation[").concat(t,"]")}function $t(e){return(e.type===yt||e.type===jt&&e.to===it.Internal)&&typeof e.delay!="number"}var nt=R({type:Pe});function zt(e,t){return t&&t[e]||void 0}function vt(e,t){var n;if(j(e)||typeof e=="number"){var i=zt(e,t);T(i)?n={type:e,exec:i}:i?n=i:n={type:e,exec:void 0}}else if(T(e))n={type:e.name||e.toString(),exec:e};else{var i=zt(e.type,t);if(T(i))n=v(v({},e),{exec:i});else if(i){var r=i.type||e.type;n=v(v(v({},i),e),{type:r})}else n=e}return n}var G=function(e,t){if(!e)return[];var n=ot(e)?e:[e];return n.map(function(i){return vt(i,t)})};function Qt(e){var t=vt(e);return v(v({id:j(e)?e:t.id},t),{type:t.type})}function qe(e,t){return{type:yt,event:typeof e=="function"?e:Nt(e),delay:t?t.delay:void 0,id:t==null?void 0:t.id}}function Xe(e,t,n,i){var r={_event:n},o=R(T(e.event)?e.event(t,n.data,r):e.event),a;if(j(e.delay)){var s=i&&i[e.delay];a=T(s)?s(t,n.data,r):s}else a=T(e.delay)?e.delay(t,n.data,r):e.delay;return v(v({},e),{type:yt,_event:o,delay:a})}function Qe(e,t){return{to:t?t.to:void 0,type:jt,event:T(e)?e:Nt(e),delay:t?t.delay:void 0,id:t&&t.id!==void 0?t.id:T(e)?e.name:ue(e)}}function Ge(e,t,n,i){var r={_event:n},o=R(T(e.event)?e.event(t,n.data,r):e.event),a;if(j(e.delay)){var s=i&&i[e.delay];a=T(s)?s(t,n.data,r):s}else a=T(e.delay)?e.delay(t,n.data,r):e.delay;var c=T(e.to)?e.to(t,n.data,r):e.to;return v(v({},e),{to:c,_event:o,event:o.data,delay:a})}var We=function(e,t,n){return v(v({},e),{value:j(e.expr)?e.expr:e.expr(t,n.data,{_event:n})})},He=function(e){return{type:re,sendId:e}};function Ye(e){var t=Qt(e);return{type:N.Start,activity:t,exec:void 0}}function Ze(e){var t=T(e)?e:Qt(e);return{type:N.Stop,activity:t,exec:void 0}}function Ke(e,t,n){var i=T(e.activity)?e.activity(t,n.data):e.activity,r=typeof i=="string"?{id:i}:i,o={type:N.Stop,activity:r};return o}function tn(e,t){var n=t?"#".concat(t):"";return"".concat(N.After,"(").concat(e,")").concat(n)}function xt(e,t){var n="".concat(N.DoneState,".").concat(e),i={type:n,data:t};return i.toString=function(){return n},i}function Et(e,t){var n="".concat(N.DoneInvoke,".").concat(e),i={type:n,data:t};return i.toString=function(){return n},i}function ut(e,t){var n="".concat(N.ErrorPlatform,".").concat(e),i={type:n,data:t};return i.toString=function(){return n},i}var en=function(e){var t,n,i=[];try{for(var r=E(e),o=r.next();!o.done;o=r.next())for(var a=o.value,s=0;s0;){var u=r.shift();n=e.transition(n,u,c),i.forEach(function(f){return f.next(n)})}o=!1}},s=an({id:t.id,send:function(u){r.push(u),a()},getSnapshot:function(){return n},subscribe:function(u,f,d){var h=wt(u,f,d);return i.add(h),h.next(n),{unsubscribe:function(){i.delete(h)}}}}),c={parent:t.parent,self:s,id:t.id||"anonymous",observers:i};return n=e.start?e.start(c):n,s}var gn={sync:!1,autoForward:!1},C;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"})(C||(C={}));var mn=function(){function e(t,n){n===void 0&&(n=e.defaultOptions);var i=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=C.NotStarted,this.children=new Map,this.forwardTo=new Set,this._outgoingQueue=[],this.init=this.start,this.send=function(f,d){if(ot(f))return i.batch(f),i.state;var h=R(Nt(f,d));if(i.status===C.Stopped)return i.state;if(i.status!==C.Running&&!i.options.deferEvents)throw new Error('Event "'.concat(h.name,'" was sent to uninitialized service "').concat(i.machine.id,`". Make sure .start() is called for this service, or set { deferEvents: true } in the service options. Event: `).concat(JSON.stringify(h.data)));return i.scheduler.schedule(function(){i.forward(h);var l=i._nextState(h);i.update(l,h)}),i._state},this.sendTo=function(f,d,h){var l=i.parent&&(d===it.Parent||i.parent.id===d),y=l?i.parent:j(d)?d===it.Internal?i:i.children.get(d)||st.get(d):Je(d)?d:void 0;if(!y){if(!l)throw new Error("Unable to send event to child '".concat(d,"' from service '").concat(i.id,"'."));return}if("machine"in y){if(i.status!==C.Stopped||i.parent!==y||i.state.done){var p=v(v({},f),{name:f.name===je?"".concat(ut(i.id)):f.name,origin:i.sessionId});!h&&i.machine.config.predictableActionArguments?i._outgoingQueue.push([y,p]):y.send(p)}}else!h&&i.machine.config.predictableActionArguments?i._outgoingQueue.push([y,f.data]):y.send(f.data)},this._exec=function(f,d,h,l){l===void 0&&(l=i.machine.options.actions);var y=f.exec||zt(f.type,l),p=T(y)?y:y?y.exec:f.exec;if(p)try{return p(d,h.data,i.machine.config.predictableActionArguments?{action:f,_event:h}:{action:f,state:i.state,_event:h})}catch($){throw i.parent&&i.parent.send({type:"xstate.error",data:$}),$}switch(f.type){case yt:{var b=f;i.defer(b);break}case jt:var g=f;if(typeof g.delay=="number"){i.defer(g);return}else g.to?i.sendTo(g._event,g.to,h===nt):i.send(g._event);break;case re:i.cancel(f.sendId);break;case Mt:{if(i.status!==C.Running)return;var m=f.activity;if(!i.machine.config.predictableActionArguments&&!i.state.activities[m.id||m.type])break;if(m.type===N.Invoke){var x=ve(m.src),_=i.machine.options.services?i.machine.options.services[x.type]:void 0,A=m.id,L=m.data,k="autoForward"in m?m.autoForward:!!m.forward;if(!_)return;var I=L?Tt(L,d,h):void 0;if(typeof _=="string")return;var w=T(_)?_(d,h.data,{data:I,src:x,meta:m.meta}):_;if(!w)return;var M=void 0;rt(w)&&(w=I?w.withContext(I):w,M={autoForward:k}),i.spawn(w,A,M)}else i.spawnActivity(m);break}case qt:{i.stopChild(f.activity.id);break}case ae:var S=f,P=S.label,B=S.value;P?i.logger(P,B):i.logger(B);break}};var r=v(v({},e.defaultOptions),n),o=r.clock,a=r.logger,s=r.parent,c=r.id,u=c!==void 0?c:t.id;this.id=u,this.logger=a,this.clock=o,this.parent=s,this.options=r,this.scheduler=new ie({deferEvents:this.options.deferEvents}),this.sessionId=st.bookId()}return Object.defineProperty(e.prototype,"initialState",{get:function(){var t=this;return this._initialState?this._initialState:et(this,function(){return t._initialState=t.machine.initialState,t._initialState})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"state",{get:function(){return this._state},enumerable:!1,configurable:!0}),e.prototype.execute=function(t,n){var i,r;try{for(var o=E(t.actions),a=o.next();!a.done;a=o.next()){var s=a.value;this.exec(s,t,n)}}catch(c){i={error:c}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}},e.prototype.update=function(t,n){var i,r,o,a,s,c,u,f,d=this;if(t._sessionid=this.sessionId,this._state=t,(!this.machine.config.predictableActionArguments||n===nt)&&this.options.execute)this.execute(this.state);else for(var h=void 0;h=this._outgoingQueue.shift();)h[0].send(h[1]);if(this.children.forEach(function(w){d.state.children[w.id]=w}),this.devTools&&this.devTools.send(n.data,t),t.event)try{for(var l=E(this.eventListeners),y=l.next();!y.done;y=l.next()){var p=y.value;p(t.event)}}catch(w){i={error:w}}finally{try{y&&!y.done&&(r=l.return)&&r.call(l)}finally{if(i)throw i.error}}try{for(var b=E(this.listeners),g=b.next();!g.done;g=b.next()){var p=g.value;p(t,t.event)}}catch(w){o={error:w}}finally{try{g&&!g.done&&(a=b.return)&&a.call(b)}finally{if(o)throw o.error}}try{for(var m=E(this.contextListeners),x=m.next();!x.done;x=m.next()){var _=x.value;_(this.state.context,this.state.history?this.state.history.context:void 0)}}catch(w){s={error:w}}finally{try{x&&!x.done&&(c=m.return)&&c.call(m)}finally{if(s)throw s.error}}if(this.state.done){var A=t.configuration.find(function(w){return w.type==="final"&&w.parent===d.machine}),L=A&&A.doneData?Tt(A.doneData,t.context,n):void 0;this._doneEvent=Et(this.id,L);try{for(var k=E(this.doneListeners),I=k.next();!I.done;I=k.next()){var p=I.value;p(this._doneEvent)}}catch(w){u={error:w}}finally{try{I&&!I.done&&(f=k.return)&&f.call(k)}finally{if(u)throw u.error}}this._stop(),this._stopChildren(),st.free(this.sessionId)}},e.prototype.onTransition=function(t){return this.listeners.add(t),this.status===C.Running&&t(this.state,this.state.event),this},e.prototype.subscribe=function(t,n,i){var r=this,o=wt(t,n,i);this.listeners.add(o.next),this.status!==C.NotStarted&&o.next(this.state);var a=function(){r.doneListeners.delete(a),r.stopListeners.delete(a),o.complete()};return this.status===C.Stopped?o.complete():(this.onDone(a),this.onStop(a)),{unsubscribe:function(){r.listeners.delete(o.next),r.doneListeners.delete(a),r.stopListeners.delete(a)}}},e.prototype.onEvent=function(t){return this.eventListeners.add(t),this},e.prototype.onSend=function(t){return this.sendListeners.add(t),this},e.prototype.onChange=function(t){return this.contextListeners.add(t),this},e.prototype.onStop=function(t){return this.stopListeners.add(t),this},e.prototype.onDone=function(t){return this.status===C.Stopped&&this._doneEvent?t(this._doneEvent):this.doneListeners.add(t),this},e.prototype.off=function(t){return this.listeners.delete(t),this.eventListeners.delete(t),this.sendListeners.delete(t),this.stopListeners.delete(t),this.doneListeners.delete(t),this.contextListeners.delete(t),this},e.prototype.start=function(t){var n=this;if(this.status===C.Running)return this;this.machine._init(),st.register(this.sessionId,this),this.initialized=!0,this.status=C.Running;var i=t===void 0?this.initialState:et(this,function(){return hn(t)?n.machine.resolveState(t):n.machine.resolveState(q.from(t,n.machine.context))});return this.options.devTools&&this.attachDev(),this.scheduler.initialize(function(){n.update(i,nt)}),this},e.prototype._stopChildren=function(){this.children.forEach(function(t){T(t.stop)&&t.stop()}),this.children.clear()},e.prototype._stop=function(){var t,n,i,r,o,a,s,c,u,f;try{for(var d=E(this.listeners),h=d.next();!h.done;h=d.next()){var l=h.value;this.listeners.delete(l)}}catch(k){t={error:k}}finally{try{h&&!h.done&&(n=d.return)&&n.call(d)}finally{if(t)throw t.error}}try{for(var y=E(this.stopListeners),p=y.next();!p.done;p=y.next()){var l=p.value;l(),this.stopListeners.delete(l)}}catch(k){i={error:k}}finally{try{p&&!p.done&&(r=y.return)&&r.call(y)}finally{if(i)throw i.error}}try{for(var b=E(this.contextListeners),g=b.next();!g.done;g=b.next()){var l=g.value;this.contextListeners.delete(l)}}catch(k){o={error:k}}finally{try{g&&!g.done&&(a=b.return)&&a.call(b)}finally{if(o)throw o.error}}try{for(var m=E(this.doneListeners),x=m.next();!x.done;x=m.next()){var l=x.value;this.doneListeners.delete(l)}}catch(k){s={error:k}}finally{try{x&&!x.done&&(c=m.return)&&c.call(m)}finally{if(s)throw s.error}}if(!this.initialized)return this;this.initialized=!1,this.status=C.Stopped,this._initialState=void 0;try{for(var _=E(Object.keys(this.delayedEventsMap)),A=_.next();!A.done;A=_.next()){var L=A.value;this.clock.clearTimeout(this.delayedEventsMap[L])}}catch(k){u={error:k}}finally{try{A&&!A.done&&(f=_.return)&&f.call(_)}finally{if(u)throw u.error}}this.scheduler.clear(),this.scheduler=new ie({deferEvents:this.options.deferEvents})},e.prototype.stop=function(){var t=this,n=this.scheduler;return this._stop(),n.schedule(function(){var i=R({type:"xstate.stop"}),r=et(t,function(){var o=D(V([],O(t.state.configuration),!1).sort(function(f,d){return d.order-f.order}).map(function(f){return G(f.onExit,t.machine.options.actions)})),a=O(At(t.machine,t.state,t.state.context,i,[{type:"exit",actions:o}],t.machine.config.predictableActionArguments?t._exec:void 0,t.machine.config.predictableActionArguments||t.machine.config.preserveActionOrder),2),s=a[0],c=a[1],u=new q({value:t.state.value,context:c,_event:i,_sessionid:t.sessionId,historyValue:void 0,history:t.state,actions:s.filter(function(f){return!$t(f)}),activities:{},events:[],configuration:[],transitions:[],children:{},done:t.state.done,tags:t.state.tags,machine:t.machine});return u.changed=!0,u});t.update(r,i),t._stopChildren(),st.free(t.sessionId)}),this},e.prototype.batch=function(t){var n=this;if(!(this.status===C.NotStarted&&this.options.deferEvents)&&this.status!==C.Running)throw new Error("".concat(t.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(t.length){var i=!!this.machine.config.predictableActionArguments&&this._exec;this.scheduler.schedule(function(){var r,o,a=n.state,s=!1,c=[],u=function(l){var y=R(l);n.forward(y),a=et(n,function(){return n.machine.transition(a,y,void 0,i||void 0)}),c.push.apply(c,V([],O(n.machine.config.predictableActionArguments?a.actions:a.actions.map(function(p){return fn(p,a)})),!1)),s=s||!!a.changed};try{for(var f=E(t),d=f.next();!d.done;d=f.next()){var h=d.value;u(h)}}catch(l){r={error:l}}finally{try{d&&!d.done&&(o=f.return)&&o.call(f)}finally{if(r)throw r.error}}a.changed=s,a.actions=c,n.update(a,R(t[t.length-1]))})}},e.prototype.sender=function(t){return this.send.bind(this,t)},e.prototype._nextState=function(t,n){var i=this;n===void 0&&(n=!!this.machine.config.predictableActionArguments&&this._exec);var r=R(t);if(r.name.indexOf(Yt)===0&&!this.state.nextEvents.some(function(a){return a.indexOf(Yt)===0}))throw r.data.data;var o=et(this,function(){return i.machine.transition(i.state,r,void 0,n||void 0)});return o},e.prototype.nextState=function(t){return this._nextState(t,!1)},e.prototype.forward=function(t){var n,i;try{for(var r=E(this.forwardTo),o=r.next();!o.done;o=r.next()){var a=o.value,s=this.children.get(a);if(!s)throw new Error("Unable to forward event '".concat(t,"' from interpreter '").concat(this.id,"' to nonexistant child '").concat(a,"'."));s.send(t)}}catch(c){n={error:c}}finally{try{o&&!o.done&&(i=r.return)&&i.call(r)}finally{if(n)throw n.error}}},e.prototype.defer=function(t){var n=this,i=this.clock.setTimeout(function(){"to"in t&&t.to?n.sendTo(t._event,t.to,!0):n.send(t._event)},t.delay);t.id&&(this.delayedEventsMap[t.id]=i)},e.prototype.cancel=function(t){this.clock.clearTimeout(this.delayedEventsMap[t]),delete this.delayedEventsMap[t]},e.prototype.exec=function(t,n,i){i===void 0&&(i=this.machine.options.actions),this._exec(t,n.context,n._event,i)},e.prototype.removeChild=function(t){var n;this.children.delete(t),this.forwardTo.delete(t),(n=this.state)===null||n===void 0||delete n.children[t]},e.prototype.stopChild=function(t){var n=this.children.get(t);n&&(this.removeChild(t),T(n.stop)&&n.stop())},e.prototype.spawn=function(t,n,i){if(this.status!==C.Running)return ye(t,n);if(te(t))return this.spawnPromise(Promise.resolve(t),n);if(T(t))return this.spawnCallback(t,n);if(on(t))return this.spawnActor(t,n);if(Fe(t))return this.spawnObservable(t,n);if(rt(t))return this.spawnMachine(t,v(v({},i),{id:n}));if(Re(t))return this.spawnBehavior(t,n);throw new Error('Unable to spawn entity "'.concat(n,'" of type "').concat(typeof t,'".'))},e.prototype.spawnMachine=function(t,n){var i=this;n===void 0&&(n={});var r=new e(t,v(v({},this.options),{parent:this,id:n.id||t.id})),o=v(v({},gn),n);o.sync&&r.onTransition(function(s){i.send(se,{state:s,id:r.id})});var a=r;return this.children.set(r.id,a),o.autoForward&&this.forwardTo.add(r.id),r.onDone(function(s){i.removeChild(r.id),i.send(R(s,{origin:r.id}))}).start(),a},e.prototype.spawnBehavior=function(t,n){var i=yn(t,{id:n,parent:this});return this.children.set(n,i),i},e.prototype.spawnPromise=function(t,n){var i,r=this,o=!1,a;t.then(function(c){o||(a=c,r.removeChild(n),r.send(R(Et(n,c),{origin:n})))},function(c){if(!o){r.removeChild(n);var u=ut(n,c);try{r.send(R(u,{origin:n}))}catch{r.devTools&&r.devTools.send(u,r.state),r.machine.strict&&r.stop()}}});var s=(i={id:n,send:function(){},subscribe:function(c,u,f){var d=wt(c,u,f),h=!1;return t.then(function(l){h||(d.next(l),!h&&d.complete())},function(l){h||d.error(l)}),{unsubscribe:function(){return h=!0}}},stop:function(){o=!0},toJSON:function(){return{id:n}},getSnapshot:function(){return a}},i[Q]=function(){return this},i);return this.children.set(n,s),s},e.prototype.spawnCallback=function(t,n){var i,r=this,o=!1,a=new Set,s=new Set,c,u=function(h){c=h,s.forEach(function(l){return l(h)}),!o&&r.send(R(h,{origin:n}))},f;try{f=t(u,function(h){a.add(h)})}catch(h){this.send(ut(n,h))}if(te(f))return this.spawnPromise(f,n);var d=(i={id:n,send:function(h){return a.forEach(function(l){return l(h)})},subscribe:function(h){var l=wt(h);return s.add(l.next),{unsubscribe:function(){s.delete(l.next)}}},stop:function(){o=!0,T(f)&&f()},toJSON:function(){return{id:n}},getSnapshot:function(){return c}},i[Q]=function(){return this},i);return this.children.set(n,d),d},e.prototype.spawnObservable=function(t,n){var i,r=this,o,a=t.subscribe(function(c){o=c,r.send(R(c,{origin:n}))},function(c){r.removeChild(n),r.send(R(ut(n,c),{origin:n}))},function(){r.removeChild(n),r.send(R(Et(n),{origin:n}))}),s=(i={id:n,send:function(){},subscribe:function(c,u,f){return t.subscribe(c,u,f)},stop:function(){return a.unsubscribe()},getSnapshot:function(){return o},toJSON:function(){return{id:n}}},i[Q]=function(){return this},i);return this.children.set(n,s),s},e.prototype.spawnActor=function(t,n){return this.children.set(n,t),t},e.prototype.spawnActivity=function(t){var n=this.machine.options&&this.machine.options.activities?this.machine.options.activities[t.type]:void 0;if(n){var i=n(this.state.context,t);this.spawnEffect(t.id,i)}},e.prototype.spawnEffect=function(t,n){var i;this.children.set(t,(i={id:t,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},stop:n||void 0,getSnapshot:function(){},toJSON:function(){return{id:t}}},i[Q]=function(){return this},i))},e.prototype.attachDev=function(){var t=Gt();if(this.options.devTools&&t){if(t.__REDUX_DEVTOOLS_EXTENSION__){var n=typeof this.options.devTools=="object"?this.options.devTools:void 0;this.devTools=t.__REDUX_DEVTOOLS_EXTENSION__.connect(v(v({name:this.id,autoPause:!0,stateSanitizer:function(i){return{value:i.value,context:i.context,actions:i.actions}}},n),{features:v({jump:!1,skip:!1},n?n.features:void 0)}),this.machine),this.devTools.init(this.state)}pn(this)}},e.prototype.toJSON=function(){return{id:this.id}},e.prototype[Q]=function(){return this},e.prototype.getSnapshot=function(){return this.status===C.NotStarted?this.initialState:this._state},e.defaultOptions={execute:!0,deferEvents:!0,clock:{setTimeout:function(t,n){return setTimeout(t,n)},clearTimeout:function(t){return clearTimeout(t)}},logger:console.log.bind(console),devTools:!1},e.interpret=Se,e}();function Se(e,t){var n=new mn(e,t);return n}function xn(e){if(typeof e=="string"){var t={type:e};return t.toString=function(){return e},t}return e}function bt(e){return v(v({type:Ct},e),{toJSON:function(){e.onDone,e.onError;var t=Ut(e,["onDone","onError"]);return v(v({},t),{type:Ct,src:xn(e.src)})}})}var St="",Jt="#",Dt="*",K={},tt=function(e){return e[0]===Jt},bn=function(){return{actions:{},guards:{},services:{},activities:{},delays:{}}},Sn=function(){function e(t,n,i,r){i===void 0&&(i="context"in t?t.context:void 0);var o=this,a;this.config=t,this._context=i,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(bn(),n),this.parent=r==null?void 0:r.parent,this.key=this.config.key||(r==null?void 0:r.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:ce),this.id=this.config.id||V([this.machine.key],O(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:(a=this.config.schema)!==null&&a!==void 0?a:{},this.description=this.config.description,this.initial=this.config.initial,this.states=this.config.states?ct(this.config.states,function(u,f){var d,h=new e(u,{},void 0,{parent:o,key:f});return Object.assign(o.idMap,v((d={},d[h.id]=h,d),h.idMap)),h}):K;var s=0;function c(u){var f,d;u.order=s++;try{for(var h=E(ge(u)),l=h.next();!l.done;l=h.next()){var y=l.value;c(y)}}catch(p){f={error:p}}finally{try{l&&!l.done&&(d=h.return)&&d.call(h)}finally{if(f)throw f.error}}}c(this),this.history=this.config.history===!0?"shallow":this.config.history||!1,this._transient=!!this.config.always||(this.config.on?Array.isArray(this.config.on)?this.config.on.some(function(u){var f=u.event;return f===St}):St in this.config.on:!1),this.strict=!!this.config.strict,this.onEntry=J(this.config.entry||this.config.onEntry).map(function(u){return vt(u)}),this.onExit=J(this.config.exit||this.config.onExit).map(function(u){return vt(u)}),this.meta=this.config.meta,this.doneData=this.type==="final"?this.config.data:void 0,this.invoke=J(this.config.invoke).map(function(u,f){var d,h;if(rt(u)){var l=mt(o.id,f);return o.machine.options.services=v((d={},d[l]=u,d),o.machine.options.services),bt({src:l,id:l})}else if(j(u.src)){var l=u.id||mt(o.id,f);return bt(v(v({},u),{id:l,src:u.src}))}else if(rt(u.src)||T(u.src)){var l=u.id||mt(o.id,f);return o.machine.options.services=v((h={},h[l]=u.src,h),o.machine.options.services),bt(v(v({id:l},u),{src:l}))}else{var y=u.src;return bt(v(v({id:mt(o.id,f)},u),{src:y}))}}),this.activities=J(this.config.activities).concat(this.invoke).map(function(u){return Qt(u)}),this.transition=this.transition.bind(this),this.tags=J(this.config.tags)}return e.prototype._init=function(){this.__cache.transitions||me(this).forEach(function(t){return t.on})},e.prototype.withConfig=function(t,n){var i=this.options,r=i.actions,o=i.activities,a=i.guards,s=i.services,c=i.delays;return new e(this.config,{actions:v(v({},r),t.actions),activities:v(v({},o),t.activities),guards:v(v({},a),t.guards),services:v(v({},s),t.services),delays:v(v({},c),t.delays)},n??this.context)},e.prototype.withContext=function(t){return new e(this.config,this.options,t)},Object.defineProperty(e.prototype,"context",{get:function(){return T(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:ct(this.states,function(t){return t.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 t=this.transitions;return this.__cache.on=t.reduce(function(n,i){return n[i.eventType]=n[i.eventType]||[],n[i.eventType].push(i),n},{})},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(t){if(this.__cache.candidates[t])return this.__cache.candidates[t];var n=t===St,i=this.transitions.filter(function(r){var o=r.eventType===t;return n?o:o||r.eventType===Dt});return this.__cache.candidates[t]=i,i},e.prototype.getDelayedTransitions=function(){var t=this,n=this.config.after;if(!n)return[];var i=function(o,a){var s=T(o)?"".concat(t.id,":delay[").concat(a,"]"):o,c=tn(s,t.id);return t.onEntry.push(Qe(c,{delay:o})),t.onExit.push(He(c)),c},r=ot(n)?n.map(function(o,a){var s=i(o.delay,a);return v(v({},o),{event:s})}):D(Object.keys(n).map(function(o,a){var s=n[o],c=j(s)?{target:s}:s,u=isNaN(+o)?o:+o,f=i(u,a);return J(c).map(function(d){return v(v({},d),{event:f,delay:u})})}));return r.map(function(o){var a=o.delay;return v(v({},t.formatTransition(o)),{delay:a})})},e.prototype.getStateNodes=function(t){var n,i=this;if(!t)return[];var r=t instanceof q?t.value:dt(t,this.delimiter);if(j(r)){var o=this.getStateNode(r).initial;return o!==void 0?this.getStateNodes((n={},n[r]=o,n)):[this,this.states[r]]}var a=Object.keys(r),s=[this];return s.push.apply(s,V([],O(D(a.map(function(c){return i.getStateNode(c).getStateNodes(r[c])}))),!1)),s},e.prototype.handles=function(t){var n=ue(t);return this.events.includes(n)},e.prototype.resolveState=function(t){var n=t instanceof q?t:q.create(t),i=Array.from(ht([],this.getStateNodes(n.value)));return new q(v(v({},n),{value:this.resolve(n.value),configuration:i,done:Ot(i,this),tags:ne(i),machine:this.machine}))},e.prototype.transitionLeafNode=function(t,n,i){var r=this.getStateNode(t),o=r.next(n,i);return!o||!o.transitions.length?this.next(n,i):o},e.prototype.transitionCompoundNode=function(t,n,i){var r=Object.keys(t),o=this.getStateNode(r[0]),a=o._transition(t[r[0]],n,i);return!a||!a.transitions.length?this.next(n,i):a},e.prototype.transitionParallelNode=function(t,n,i){var r,o,a={};try{for(var s=E(Object.keys(t)),c=s.next();!c.done;c=s.next()){var u=c.value,f=t[u];if(f){var d=this.getStateNode(u),h=d._transition(f,n,i);h&&(a[u]=h)}}}catch(g){r={error:g}}finally{try{c&&!c.done&&(o=s.return)&&o.call(s)}finally{if(r)throw r.error}}var l=Object.keys(a).map(function(g){return a[g]}),y=D(l.map(function(g){return g.transitions})),p=l.some(function(g){return g.transitions.length>0});if(!p)return this.next(n,i);var b=D(Object.keys(a).map(function(g){return a[g].configuration}));return{transitions:y,exitSet:D(l.map(function(g){return g.exitSet})),configuration:b,source:n,actions:D(Object.keys(a).map(function(g){return a[g].actions}))}},e.prototype._transition=function(t,n,i){return j(t)?this.transitionLeafNode(t,n,i):Object.keys(t).length===1?this.transitionCompoundNode(t,n,i):this.transitionParallelNode(t,n,i)},e.prototype.getTransitionData=function(t,n){return this._transition(t.value,t,R(n))},e.prototype.next=function(t,n){var i,r,o=this,a=n.name,s=[],c=[],u;try{for(var f=E(this.getCandidates(a)),d=f.next();!d.done;d=f.next()){var h=d.value,l=h.cond,y=h.in,p=t.context,b=y?j(y)&&tt(y)?t.matches(dt(this.getStateNodeById(y).path,this.delimiter)):Xt(dt(y,this.delimiter),De(this.path.slice(0,-2))(t.value)):!0,g=!1;try{g=!l||de(this.machine,l,p,n,t)}catch(_){throw new Error("Unable to evaluate guard '".concat(l.name||l.type,"' in transition for event '").concat(a,"' in state node '").concat(this.id,`': `).concat(_.message))}if(g&&b){h.target!==void 0&&(c=h.target),s.push.apply(s,V([],O(h.actions),!1)),u=h;break}}}catch(_){i={error:_}}finally{try{d&&!d.done&&(r=f.return)&&r.call(f)}finally{if(i)throw i.error}}if(u){if(!c.length)return{transitions:[u],exitSet:[],configuration:t.value?[this]:[],source:t,actions:s};var m=D(c.map(function(_){return o.getRelativeStateNodes(_,t.historyValue)})),x=!!u.internal;return{transitions:[u],exitSet:x?[]:D(c.map(function(_){return o.getPotentiallyReenteringNodes(_)})),configuration:m,source:t,actions:s}}},e.prototype.getPotentiallyReenteringNodes=function(t){if(this.order0,l=h?t.configuration:n?n.configuration:[],y=Ot(l,this),p=h?sn(this.machine,d):void 0,b=n?n.historyValue?n.historyValue:t.source?this.machine.historyValue(n.value):void 0:void 0,g=this.getActions(new Set(l),y,t,i,o,n,r),m=n?v({},n.activities):{};try{for(var x=E(g),_=x.next();!_.done;_=x.next()){var A=_.value;try{for(var L=(c=void 0,E(A.actions)),k=L.next();!k.done;k=L.next()){var I=k.value;I.type===Mt?m[I.activity.id||I.activity.type]=I:I.type===qt&&(m[I.activity.id||I.activity.type]=!1)}}catch(F){c={error:F}}finally{try{k&&!k.done&&(u=L.return)&&u.call(L)}finally{if(c)throw c.error}}}}catch(F){a={error:F}}finally{try{_&&!_.done&&(s=x.return)&&s.call(x)}finally{if(a)throw a.error}}var w=O(At(this,n,i,o,g,r,this.machine.config.predictableActionArguments||this.machine.config.preserveActionOrder),2),M=w[0],S=w[1],P=O(Be(M,$t),2),B=P[0],$=P[1],at=M.filter(function(F){var Y;return F.type===Mt&&((Y=F.activity)===null||Y===void 0?void 0:Y.type)===Ct}),gt=at.reduce(function(F,Y){return F[Y.activity.id]=nn(Y.activity,f.machine,S,o),F},n?v({},n.children):{}),U=new q({value:p||n.value,context:S,_event:o,_sessionid:n?n._sessionid:null,historyValue:p?b?$e(b,p):void 0:n?n.historyValue:void 0,history:!p||t.source?n:void 0,actions:p?$:[],activities:p?m:n?n.activities:{},events:[],configuration:l,transitions:t.transitions,children:gt,done:y,tags:ne(l),machine:this}),W=i!==S;U.changed=o.name===se||W;var H=U.history;H&&delete H.history;var Wt=!y&&(this._transient||d.some(function(F){return F._transient}));if(!h&&(!Wt||o.name===St))return U;var z=U;if(!y)for(Wt&&(z=this.resolveRaisedTransition(z,{type:Ae},o,r));B.length;){var _e=B.shift();z=this.resolveRaisedTransition(z,_e._event,o,r)}var we=z.changed||(H?!!z.actions.length||W||typeof H.value!=typeof z.value||!be(z.value,H.value):void 0);return z.changed=we,z.history=H,z},e.prototype.getStateNode=function(t){if(tt(t))return this.machine.getStateNodeById(t);if(!this.states)throw new Error("Unable to retrieve child state '".concat(t,"' from '").concat(this.id,"'; no child states exist."));var n=this.states[t];if(!n)throw new Error("Child state '".concat(t,"' does not exist on '").concat(this.id,"'"));return n},e.prototype.getStateNodeById=function(t){var n=tt(t)?t.slice(Jt.length):t;if(n===this.id)return this;var i=this.machine.idMap[n];if(!i)throw new Error("Child state node '#".concat(n,"' does not exist on machine '").concat(this.id,"'"));return i},e.prototype.getStateNodeByPath=function(t){if(typeof t=="string"&&tt(t))try{return this.getStateNodeById(t.slice(1))}catch{}for(var n=Bt(t,this.delimiter).slice(),i=this;n.length;){var r=n.shift();if(!r.length)break;i=i.getStateNode(r)}return i},e.prototype.resolve=function(t){var n,i=this;if(!t)return this.initialStateValue||K;switch(this.type){case"parallel":return ct(this.initialStateValue,function(o,a){return o?i.getStateNode(a).resolve(t[a]||o):K});case"compound":if(j(t)){var r=this.getStateNode(t);return r.type==="parallel"||r.type==="compound"?(n={},n[t]=r.initialStateValue,n):t}return Object.keys(t).length?ct(t,function(o,a){return o?i.getStateNode(a).resolve(o):K}):this.initialStateValue||{};default:return t||K}},e.prototype.getResolvedPath=function(t){if(tt(t)){var n=this.machine.idMap[t.slice(Jt.length)];if(!n)throw new Error("Unable to find state node '".concat(t,"'"));return n.path}return Bt(t,this.delimiter)},Object.defineProperty(e.prototype,"initialStateValue",{get:function(){var t;if(this.__cache.initialStateValue)return this.__cache.initialStateValue;var n;if(this.type==="parallel")n=Kt(this.states,function(i){return i.initialStateValue||K},function(i){return i.type!=="history"});else if(this.initial!==void 0){if(!this.states[this.initial])throw new Error("Initial state '".concat(this.initial,"' not found on '").concat(this.key,"'"));n=Pt(this.states[this.initial])?this.initial:(t={},t[this.initial]=this.states[this.initial].initialStateValue,t)}else n={};return this.__cache.initialStateValue=n,this.__cache.initialStateValue},enumerable:!1,configurable:!0}),e.prototype.getInitialState=function(t,n){this._init();var i=this.getStateNodes(t);return this.resolveTransition({configuration:i,exitSet:[],transitions:[],source:void 0,actions:[]},void 0,n??this.machine.context,void 0)},Object.defineProperty(e.prototype,"initialState",{get:function(){var t=this.initialStateValue;if(!t)throw new Error("Cannot retrieve initial state from simple state '".concat(this.id,"'."));return this.getInitialState(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"target",{get:function(){var t;if(this.type==="history"){var n=this.config;j(n.target)?t=tt(n.target)?kt(this.machine.getStateNodeById(n.target).path.slice(this.path.length-1)):n.target:t=n.target}return t},enumerable:!1,configurable:!0}),e.prototype.getRelativeStateNodes=function(t,n,i){return i===void 0&&(i=!0),i?t.type==="history"?t.resolveHistory(n):t.initialStateNodes:[t]},Object.defineProperty(e.prototype,"initialStateNodes",{get:function(){var t=this;if(Pt(this))return[this];if(this.type==="compound"&&!this.initial)return[this];var n=_t(this.initialStateValue);return D(n.map(function(i){return t.getFromRelativePath(i)}))},enumerable:!1,configurable:!0}),e.prototype.getFromRelativePath=function(t){if(!t.length)return[this];var n=O(t),i=n[0],r=n.slice(1);if(!this.states)throw new Error("Cannot retrieve subPath '".concat(i,"' from node with no states"));var o=this.getStateNode(i);if(o.type==="history")return o.resolveHistory();if(!this.states[i])throw new Error("Child state '".concat(i,"' does not exist on '").concat(this.id,"'"));return this.states[i].getFromRelativePath(r)},e.prototype.historyValue=function(t){if(Object.keys(this.states).length)return{current:t||this.initialStateValue,states:Kt(this.states,function(n,i){if(!t)return n.historyValue();var r=j(t)?void 0:t[i];return n.historyValue(r||n.initialStateValue)},function(n){return!n.history})}},e.prototype.resolveHistory=function(t){var n=this;if(this.type!=="history")return[this];var i=this.parent;if(!t){var r=this.target;return r?D(_t(r).map(function(a){return i.getFromRelativePath(a)})):i.initialStateNodes}var o=Me(i.path,"states")(t).current;return j(o)?[i.getStateNode(o)]:D(_t(o).map(function(a){return n.history==="deep"?i.getFromRelativePath(a):[i.states[a[0]]]}))},Object.defineProperty(e.prototype,"stateIds",{get:function(){var t=this,n=D(Object.keys(this.states).map(function(i){return t.states[i].stateIds}));return[this.id].concat(n)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"events",{get:function(){var t,n,i,r;if(this.__cache.events)return this.__cache.events;var o=this.states,a=new Set(this.ownEvents);if(o)try{for(var s=E(Object.keys(o)),c=s.next();!c.done;c=s.next()){var u=c.value,f=o[u];if(f.states)try{for(var d=(i=void 0,E(f.events)),h=d.next();!h.done;h=d.next()){var l=h.value;a.add("".concat(l))}}catch(y){i={error:y}}finally{try{h&&!h.done&&(r=d.return)&&r.call(d)}finally{if(i)throw i.error}}}}catch(y){t={error:y}}finally{try{c&&!c.done&&(n=s.return)&&n.call(s)}finally{if(t)throw t.error}}return this.__cache.events=Array.from(a)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ownEvents",{get:function(){var t=new Set(this.transitions.filter(function(n){return!(!n.target&&!n.actions.length&&n.internal)}).map(function(n){return n.eventType}));return Array.from(t)},enumerable:!1,configurable:!0}),e.prototype.resolveTarget=function(t){var n=this;if(t!==void 0)return t.map(function(i){if(!j(i))return i;var r=i[0]===n.delimiter;if(r&&!n.parent)return n.getStateNodeByPath(i.slice(1));var o=r?n.key+i:i;if(n.parent)try{var a=n.parent.getStateNodeByPath(o);return a}catch(s){throw new Error("Invalid transition definition for state node '".concat(n.id,`': `).concat(s.message))}else return n.getStateNodeByPath(o)})},e.prototype.formatTransition=function(t){var n=this,i=Ue(t.target),r="internal"in t?t.internal:i?i.some(function(c){return j(c)&&c[0]===n.delimiter}):!0,o=this.machine.options.guards,a=this.resolveTarget(i),s=v(v({},t),{actions:G(J(t.actions)),cond:le(t.cond,o),target:a,source:this,internal:r,eventType:t.event,toJSON:function(){return v(v({},s),{target:s.target?s.target.map(function(c){return"#".concat(c.id)}):void 0,source:"#".concat(n.id)})}});return s},e.prototype.formatTransitions=function(){var t,n,i=this,r;if(!this.config.on)r=[];else if(Array.isArray(this.config.on))r=this.config.on;else{var o=this.config.on,a=Dt,s=o[a],c=s===void 0?[]:s,u=Ut(o,[typeof a=="symbol"?a:a+""]);r=D(Object.keys(u).map(function(m){var x=Z(m,u[m]);return x}).concat(Z(Dt,c)))}var f=this.config.always?Z("",this.config.always):[],d=this.config.onDone?Z(String(xt(this.id)),this.config.onDone):[],h=D(this.invoke.map(function(m){var x=[];return m.onDone&&x.push.apply(x,V([],O(Z(String(Et(m.id)),m.onDone)),!1)),m.onError&&x.push.apply(x,V([],O(Z(String(ut(m.id)),m.onError)),!1)),x})),l=this.after,y=D(V(V(V(V([],O(d),!1),O(h),!1),O(r),!1),O(f),!1).map(function(m){return J(m).map(function(x){return i.formatTransition(x)})}));try{for(var p=E(l),b=p.next();!b.done;b=p.next()){var g=b.value;y.push(g)}}catch(m){t={error:m}}finally{try{b&&!b.done&&(n=p.return)&&n.call(p)}finally{if(t)throw t.error}}return y},e}();function _n(e,t){return new Sn(e,t)}var lt={click:"onClick",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",complete:"onComplete",after:"onAfter",enter:"onEnter",show:"onShow"},wn=Object.keys(lt),kn=class{constructor(e,t){X(this,"activeStateId","");X(this,"_service");X(this,"_domListeners",new Map);X(this,"_domElement");X(this,"_playerListeners",new Map);X(this,"_player");X(this,"_machineSchemas",new Map);X(this,"_onShowPrevValue",0);this._player=t,this._machineSchemas=this._transformToXStateSchema(e),this._domElement=t.container}start(e){this.stop();let t=this._machineSchemas.get(e);if(typeof t>"u")throw It(`invalid state machine id ${e}`);this._service=Se(_n(t)),this._addEventListeners(),this._service.start()}stop(){var e;this._removeEventListeners(),(e=this._service)==null||e.stop(),this._player.stop()}_removeEventListeners(){var e;this._requiresDomElement();for(let[t,n]of this._domListeners)t==="visibilityChange"&&this._player.stopPlayOnShow(),(e=this._domElement)==null||e.removeEventListener(t,n),this._domListeners.delete(t);for(let[t,n]of this._playerListeners)this._player.removeEventListener(t,n),this._playerListeners.delete(t)}_addEventListeners(){this._requiresDomElement();let e=n=>{this._service.send({type:n})},t=n=>{function i(){e(n)}return i};this._service.subscribe(n=>{var i;if(typeof n.changed>"u"||n.changed){this._removeEventListeners();for(let r of n.nextEvents)if(wn.filter(o=>o!=="complete"&&o!=="show").includes(r)){let o=t(r);this._domListeners.set(r,o),(i=this._domElement)==null||i.addEventListener(r,o,{once:!0})}else if(r==="complete"){let o=t(r);this._player.addEventListener(r,o),this._playerListeners.set(r,o)}else if(r==="show"){let o=t(r);this._player.addIntersectionObserver({callbackOnIntersect:a=>{a>0&&(a!==100&&this._onShowPrevValue!==a&&o(),this._onShowPrevValue=a)},threshold:[]}),this._domListeners.set("visibilityChange",o)}}})}subscribe(e){throw It(e.toString())}_transformToXStateSchema(e){let t=new Map;for(let n of e){let i={},r={};if(r.id=n.descriptor.id,typeof n.descriptor.initial<"u"&&(r.initial=n.descriptor.initial),typeof n<"u"){let o=n.states;for(let a in o)if(typeof o[a]<"u"&&o[a]){let s=o[a],c=s.playbackSettings,u=Object.keys(s).filter(h=>h.startsWith("on")),f={},d={};for(let h of u)if(typeof s[h]<"u"){let l=s[h];if(h===lt.after){let y=l;d[y.ms]={target:(l==null?void 0:l.state)??""}}else h===lt.enter?f[Ht(lt,h)]={target:(l==null?void 0:l.state)??""}:f[Ht(lt,h)]={target:(l==null?void 0:l.state)??""}}i[a]={entry:()=>{!this._player.getAnimationInstance()||s.animationId&&s.animationId!==this._player.currentAnimationId?this._player.play(s.animationId,()=>({...ke,...c})).then(()=>{this._updatePlaybackSettings(c)}).catch(h=>{Te(`State machine error: ${h.message}`)}):this._updatePlaybackSettings(c)},exit:()=>{typeof c.segments<"u"&&this._player.resetSegments(!1),typeof c.playOnScroll<"u"&&this._player.stopPlayOnScroll()},on:f,after:d,meta:c}}}r.states=i,t.set(r.id,r)}return t}_handlePlaySegments(e){if(typeof e.segments=="string")this._player.goToAndPlay(e.segments,!0);else{let[t,n]=e.segments,i=t;t!==0&&t===n&&(i=t-1),t===0&&t===n?this._player.goToAndPlay(t,!0):this._player.playSegments([i,n],!0)}}_handlePlayOnScroll(e){let t=e.playOnScroll;if(e.segments&&typeof e.segments!="string"){let n=e.segments;this._player.playOnScroll({threshold:t,segments:n})}else this._player.playOnScroll({threshold:t})}_updatePlaybackSettings(e){if(!this._player.getAnimationInstance())throw new Error("Unable to update playbackSettings. Animations is not rendered yet.");typeof e.autoplay<"u"&&(this._player.setAutoplay(e.autoplay),e.autoplay?this._player.play():this._player.pause()),typeof e.direction<"u"&&this._player.setDirection(e.direction),typeof e.intermission<"u"&&this._player.setIntermission(e.intermission),typeof e.loop<"u"&&this._player.setLoop(e.loop),typeof e.playMode<"u"&&this._player.setMode(e.playMode),typeof e.speed<"u"&&this._player.setSpeed(e.speed),typeof e.defaultTheme<"u"&&this._player.setDefaultTheme(e.defaultTheme),typeof e.playOnScroll<"u"&&this._handlePlayOnScroll(e),e.segments&&this._handlePlaySegments(e),e.autoplay||this._player.pause()}_requiresDomElement(){if(!this._domElement)throw It("Requires a DOM element to attach events.")}};/*! Bundled license information: diff --git a/assets/index-2024fbcb.js b/assets/index-14a1bb9c.js similarity index 53% rename from assets/index-2024fbcb.js rename to assets/index-14a1bb9c.js index 54daf044..c7d38c56 100644 --- a/assets/index-2024fbcb.js +++ b/assets/index-14a1bb9c.js @@ -1,4 +1,4 @@ -var Rw=Object.defineProperty;var Nw=(e,t,n)=>t in e?Rw(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var ee=(e,t,n)=>(Nw(e,typeof t!="symbol"?t+"":t,n),n);function zw(e,t){for(var n=0;nr[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const a of o.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function n(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(i){if(i.ep)return;i.ep=!0;const o=n(i);fetch(i.href,o)}})();function h0(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var m0={exports:{}},Fl={},v0={exports:{}},re={};/** +var Fw=Object.defineProperty;var Rw=(e,t,n)=>t in e?Fw(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var te=(e,t,n)=>(Rw(e,typeof t!="symbol"?t+"":t,n),n);function Nw(e,t){for(var n=0;nr[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const a of o.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function n(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(i){if(i.ep)return;i.ep=!0;const o=n(i);fetch(i.href,o)}})();function p0(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var h0={exports:{}},jl={},m0={exports:{}},re={};/** * @license React * react.production.min.js * @@ -6,7 +6,7 @@ var Rw=Object.defineProperty;var Nw=(e,t,n)=>t in e?Rw(e,t,{enumerable:!0,config * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var ha=Symbol.for("react.element"),Vw=Symbol.for("react.portal"),Bw=Symbol.for("react.fragment"),Uw=Symbol.for("react.strict_mode"),Hw=Symbol.for("react.profiler"),Ww=Symbol.for("react.provider"),qw=Symbol.for("react.context"),Kw=Symbol.for("react.forward_ref"),Gw=Symbol.for("react.suspense"),Qw=Symbol.for("react.memo"),Yw=Symbol.for("react.lazy"),ph=Symbol.iterator;function Jw(e){return e===null||typeof e!="object"?null:(e=ph&&e[ph]||e["@@iterator"],typeof e=="function"?e:null)}var g0={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},y0=Object.assign,w0={};function qi(e,t,n){this.props=e,this.context=t,this.refs=w0,this.updater=n||g0}qi.prototype.isReactComponent={};qi.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};qi.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function S0(){}S0.prototype=qi.prototype;function Ad(e,t,n){this.props=e,this.context=t,this.refs=w0,this.updater=n||g0}var Pd=Ad.prototype=new S0;Pd.constructor=Ad;y0(Pd,qi.prototype);Pd.isPureReactComponent=!0;var hh=Array.isArray,b0=Object.prototype.hasOwnProperty,Id={current:null},E0={key:!0,ref:!0,__self:!0,__source:!0};function _0(e,t,n){var r,i={},o=null,a=null;if(t!=null)for(r in t.ref!==void 0&&(a=t.ref),t.key!==void 0&&(o=""+t.key),t)b0.call(t,r)&&!E0.hasOwnProperty(r)&&(i[r]=t[r]);var s=arguments.length-2;if(s===1)i.children=n;else if(1t in e?Rw(e,t,{enumerable:!0,config * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var n3=b,r3=Symbol.for("react.element"),i3=Symbol.for("react.fragment"),o3=Object.prototype.hasOwnProperty,a3=n3.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s3={key:!0,ref:!0,__self:!0,__source:!0};function x0(e,t,n){var r,i={},o=null,a=null;n!==void 0&&(o=""+n),t.key!==void 0&&(o=""+t.key),t.ref!==void 0&&(a=t.ref);for(r in t)o3.call(t,r)&&!s3.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)i[r]===void 0&&(i[r]=t[r]);return{$$typeof:r3,type:e,key:o,ref:a,props:i,_owner:a3.current}}Fl.Fragment=i3;Fl.jsx=x0;Fl.jsxs=x0;m0.exports=Fl;var O=m0.exports,qc={},C0={exports:{}},Tt={},O0={exports:{}},k0={};/** + */var t3=b,n3=Symbol.for("react.element"),r3=Symbol.for("react.fragment"),i3=Object.prototype.hasOwnProperty,o3=t3.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a3={key:!0,ref:!0,__self:!0,__source:!0};function _0(e,t,n){var r,i={},o=null,a=null;n!==void 0&&(o=""+n),t.key!==void 0&&(o=""+t.key),t.ref!==void 0&&(a=t.ref);for(r in t)i3.call(t,r)&&!a3.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)i[r]===void 0&&(i[r]=t[r]);return{$$typeof:n3,type:e,key:o,ref:a,props:i,_owner:o3.current}}jl.Fragment=r3;jl.jsx=_0;jl.jsxs=_0;h0.exports=jl;var O=h0.exports,Wc={},x0={exports:{}},Tt={},C0={exports:{}},O0={};/** * @license React * scheduler.production.min.js * @@ -22,7 +22,7 @@ var Rw=Object.defineProperty;var Nw=(e,t,n)=>t in e?Rw(e,t,{enumerable:!0,config * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */(function(e){function t(A,I){var F=A.length;A.push(I);e:for(;0>>1,V=A[R];if(0>>1;Ri(H,F))Wi(X,H)?(A[R]=X,A[W]=F,R=W):(A[R]=H,A[N]=F,R=N);else if(Wi(X,F))A[R]=X,A[W]=F,R=W;else break e}}return I}function i(A,I){var F=A.sortIndex-I.sortIndex;return F!==0?F:A.id-I.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var a=Date,s=a.now();e.unstable_now=function(){return a.now()-s}}var l=[],u=[],c=1,f=null,d=3,h=!1,y=!1,m=!1,w=typeof setTimeout=="function"?setTimeout:null,p=typeof clearTimeout=="function"?clearTimeout:null,v=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(A){for(var I=n(u);I!==null;){if(I.callback===null)r(u);else if(I.startTime<=A)r(u),I.sortIndex=I.expirationTime,t(l,I);else break;I=n(u)}}function S(A){if(m=!1,g(A),!y)if(n(l)!==null)y=!0,M(_);else{var I=n(u);I!==null&&D(S,I.startTime-A)}}function _(A,I){y=!1,m&&(m=!1,p(C),C=-1),h=!0;var F=d;try{for(g(I),f=n(l);f!==null&&(!(f.expirationTime>I)||A&&!$());){var R=f.callback;if(typeof R=="function"){f.callback=null,d=f.priorityLevel;var V=R(f.expirationTime<=I);I=e.unstable_now(),typeof V=="function"?f.callback=V:f===n(l)&&r(l),g(I)}else r(l);f=n(l)}if(f!==null)var T=!0;else{var N=n(u);N!==null&&D(S,N.startTime-I),T=!1}return T}finally{f=null,d=F,h=!1}}var x=!1,E=null,C=-1,k=5,P=-1;function $(){return!(e.unstable_now()-PA||125R?(A.sortIndex=F,t(u,A),n(l)===null&&A===n(u)&&(m?(p(C),C=-1):m=!0,D(S,F-R))):(A.sortIndex=V,t(l,A),y||h||(y=!0,M(_))),A},e.unstable_shouldYield=$,e.unstable_wrapCallback=function(A){var I=d;return function(){var F=d;d=I;try{return A.apply(this,arguments)}finally{d=F}}}})(k0);O0.exports=k0;var l3=O0.exports;/** + */(function(e){function t(A,I){var R=A.length;A.push(I);e:for(;0>>1,V=A[N];if(0>>1;Ni(U,R))Wi(X,U)?(A[N]=X,A[W]=R,N=W):(A[N]=U,A[z]=R,N=z);else if(Wi(X,R))A[N]=X,A[W]=R,N=W;else break e}}return I}function i(A,I){var R=A.sortIndex-I.sortIndex;return R!==0?R:A.id-I.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var a=Date,s=a.now();e.unstable_now=function(){return a.now()-s}}var l=[],u=[],c=1,f=null,d=3,h=!1,y=!1,m=!1,w=typeof setTimeout=="function"?setTimeout:null,p=typeof clearTimeout=="function"?clearTimeout:null,v=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(A){for(var I=n(u);I!==null;){if(I.callback===null)r(u);else if(I.startTime<=A)r(u),I.sortIndex=I.expirationTime,t(l,I);else break;I=n(u)}}function S(A){if(m=!1,g(A),!y)if(n(l)!==null)y=!0,M(E);else{var I=n(u);I!==null&&D(S,I.startTime-A)}}function E(A,I){y=!1,m&&(m=!1,p(C),C=-1),h=!0;var R=d;try{for(g(I),f=n(l);f!==null&&(!(f.expirationTime>I)||A&&!$());){var N=f.callback;if(typeof N=="function"){f.callback=null,d=f.priorityLevel;var V=N(f.expirationTime<=I);I=e.unstable_now(),typeof V=="function"?f.callback=V:f===n(l)&&r(l),g(I)}else r(l);f=n(l)}if(f!==null)var T=!0;else{var z=n(u);z!==null&&D(S,z.startTime-I),T=!1}return T}finally{f=null,d=R,h=!1}}var x=!1,_=null,C=-1,k=5,P=-1;function $(){return!(e.unstable_now()-PA||125N?(A.sortIndex=R,t(u,A),n(l)===null&&A===n(u)&&(m?(p(C),C=-1):m=!0,D(S,R-N))):(A.sortIndex=V,t(l,A),y||h||(y=!0,M(E))),A},e.unstable_shouldYield=$,e.unstable_wrapCallback=function(A){var I=d;return function(){var R=d;d=I;try{return A.apply(this,arguments)}finally{d=R}}}})(O0);C0.exports=O0;var s3=C0.exports;/** * @license React * react-dom.production.min.js * @@ -30,14 +30,14 @@ var Rw=Object.defineProperty;var Nw=(e,t,n)=>t in e?Rw(e,t,{enumerable:!0,config * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var A0=b,Mt=l3;function B(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Kc=Object.prototype.hasOwnProperty,u3=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,vh={},gh={};function c3(e){return Kc.call(gh,e)?!0:Kc.call(vh,e)?!1:u3.test(e)?gh[e]=!0:(vh[e]=!0,!1)}function f3(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function d3(e,t,n,r){if(t===null||typeof t>"u"||f3(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function pt(e,t,n,r,i,o,a){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var Xe={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Xe[e]=new pt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Xe[t]=new pt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Xe[e]=new pt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Xe[e]=new pt(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Xe[e]=new pt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Xe[e]=new pt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Xe[e]=new pt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Xe[e]=new pt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Xe[e]=new pt(e,5,!1,e.toLowerCase(),null,!1,!1)});var Ld=/[\-:]([a-z])/g;function Td(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Ld,Td);Xe[t]=new pt(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Ld,Td);Xe[t]=new pt(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Ld,Td);Xe[t]=new pt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Xe[e]=new pt(e,1,!1,e.toLowerCase(),null,!1,!1)});Xe.xlinkHref=new pt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Xe[e]=new pt(e,1,!1,e.toLowerCase(),null,!0,!0)});function Dd(e,t,n,r){var i=Xe.hasOwnProperty(t)?Xe[t]:null;(i!==null?i.type!==0:r||!(2"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),qc=Object.prototype.hasOwnProperty,l3=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,mh={},vh={};function u3(e){return qc.call(vh,e)?!0:qc.call(mh,e)?!1:l3.test(e)?vh[e]=!0:(mh[e]=!0,!1)}function c3(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function f3(e,t,n,r){if(t===null||typeof t>"u"||c3(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function pt(e,t,n,r,i,o,a){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var Xe={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Xe[e]=new pt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Xe[t]=new pt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Xe[e]=new pt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Xe[e]=new pt(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Xe[e]=new pt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Xe[e]=new pt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Xe[e]=new pt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Xe[e]=new pt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Xe[e]=new pt(e,5,!1,e.toLowerCase(),null,!1,!1)});var Md=/[\-:]([a-z])/g;function Ld(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Md,Ld);Xe[t]=new pt(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Md,Ld);Xe[t]=new pt(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Md,Ld);Xe[t]=new pt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Xe[e]=new pt(e,1,!1,e.toLowerCase(),null,!1,!1)});Xe.xlinkHref=new pt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Xe[e]=new pt(e,1,!1,e.toLowerCase(),null,!0,!0)});function Td(e,t,n,r){var i=Xe.hasOwnProperty(t)?Xe[t]:null;(i!==null?i.type!==0:r||!(2s||i[a]!==o[s]){var l=` -`+i[a].replace(" at new "," at ");return e.displayName&&l.includes("")&&(l=l.replace("",e.displayName)),l}while(1<=a&&0<=s);break}}}finally{Wu=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?mo(e):""}function p3(e){switch(e.tag){case 5:return mo(e.type);case 16:return mo("Lazy");case 13:return mo("Suspense");case 19:return mo("SuspenseList");case 0:case 2:case 15:return e=qu(e.type,!1),e;case 11:return e=qu(e.type.render,!1),e;case 1:return e=qu(e.type,!0),e;default:return""}}function Jc(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case ci:return"Fragment";case ui:return"Portal";case Gc:return"Profiler";case $d:return"StrictMode";case Qc:return"Suspense";case Yc:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case M0:return(e.displayName||"Context")+".Consumer";case I0:return(e._context.displayName||"Context")+".Provider";case jd:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Fd:return t=e.displayName||null,t!==null?t:Jc(e.type)||"Memo";case Zn:t=e._payload,e=e._init;try{return Jc(e(t))}catch{}}return null}function h3(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Jc(t);case 8:return t===$d?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function yr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function T0(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function m3(e){var t=T0(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(a){r=""+a,o.call(this,a)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(a){r=""+a},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Fa(e){e._valueTracker||(e._valueTracker=m3(e))}function D0(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=T0(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Ns(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Zc(e,t){var n=t.checked;return Pe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function wh(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=yr(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function $0(e,t){t=t.checked,t!=null&&Dd(e,"checked",t,!1)}function Xc(e,t){$0(e,t);var n=yr(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?ef(e,t.type,n):t.hasOwnProperty("defaultValue")&&ef(e,t.type,yr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Sh(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function ef(e,t,n){(t!=="number"||Ns(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var vo=Array.isArray;function _i(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=Ra.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Vo(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Co={animationIterationCount:!0,aspectRatio:!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,gridArea:!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},v3=["Webkit","ms","Moz","O"];Object.keys(Co).forEach(function(e){v3.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Co[t]=Co[e]})});function N0(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Co.hasOwnProperty(e)&&Co[e]?(""+t).trim():t+"px"}function z0(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=N0(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var g3=Pe({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function rf(e,t){if(t){if(g3[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(B(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(B(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(B(61))}if(t.style!=null&&typeof t.style!="object")throw Error(B(62))}}function of(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var af=null;function Rd(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var sf=null,xi=null,Ci=null;function _h(e){if(e=ga(e)){if(typeof sf!="function")throw Error(B(280));var t=e.stateNode;t&&(t=Bl(t),sf(e.stateNode,e.type,t))}}function V0(e){xi?Ci?Ci.push(e):Ci=[e]:xi=e}function B0(){if(xi){var e=xi,t=Ci;if(Ci=xi=null,_h(e),t)for(e=0;e>>=0,e===0?32:31-(A3(e)/P3|0)|0}var Na=64,za=4194304;function go(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Us(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,o=e.pingedLanes,a=n&268435455;if(a!==0){var s=a&~i;s!==0?r=go(s):(o&=a,o!==0&&(r=go(o)))}else a=n&~i,a!==0?r=go(a):o!==0&&(r=go(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,o=t&-t,i>=o||i===16&&(o&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function ma(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-un(t),e[t]=n}function T3(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=ko),Lh=String.fromCharCode(32),Th=!1;function l1(e,t){switch(e){case"keyup":return sS.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function u1(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var fi=!1;function uS(e,t){switch(e){case"compositionend":return u1(t);case"keypress":return t.which!==32?null:(Th=!0,Lh);case"textInput":return e=t.data,e===Lh&&Th?null:e;default:return null}}function cS(e,t){if(fi)return e==="compositionend"||!qd&&l1(e,t)?(e=a1(),gs=Ud=rr=null,fi=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Fh(n)}}function p1(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?p1(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function h1(){for(var e=window,t=Ns();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Ns(e.document)}return t}function Kd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function wS(e){var t=h1(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&p1(n.ownerDocument.documentElement,n)){if(r!==null&&Kd(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=n.textContent.length,o=Math.min(r.start,i);r=r.end===void 0?o:Math.min(r.end,i),!e.extend&&o>r&&(i=r,r=o,o=i),i=Rh(n,o);var a=Rh(n,r);i&&a&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==a.node||e.focusOffset!==a.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(a.node,a.offset)):(t.setEnd(a.node,a.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,di=null,pf=null,Po=null,hf=!1;function Nh(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;hf||di==null||di!==Ns(r)||(r=di,"selectionStart"in r&&Kd(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Po&&Ko(Po,r)||(Po=r,r=qs(pf,"onSelect"),0mi||(e.current=Sf[mi],Sf[mi]=null,mi--)}function ve(e,t){mi++,Sf[mi]=e.current,e.current=t}var wr={},st=_r(wr),yt=_r(!1),Nr=wr;function $i(e,t){var n=e.type.contextTypes;if(!n)return wr;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},o;for(o in n)i[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function wt(e){return e=e.childContextTypes,e!=null}function Gs(){Se(yt),Se(st)}function qh(e,t,n){if(st.current!==wr)throw Error(B(168));ve(st,t),ve(yt,n)}function _1(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(B(108,h3(e)||"Unknown",i));return Pe({},n,r)}function Qs(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||wr,Nr=st.current,ve(st,e),ve(yt,yt.current),!0}function Kh(e,t,n){var r=e.stateNode;if(!r)throw Error(B(169));n?(e=_1(e,t,Nr),r.__reactInternalMemoizedMergedChildContext=e,Se(yt),Se(st),ve(st,e)):Se(yt),ve(yt,n)}var $n=null,Ul=!1,ac=!1;function x1(e){$n===null?$n=[e]:$n.push(e)}function MS(e){Ul=!0,x1(e)}function xr(){if(!ac&&$n!==null){ac=!0;var e=0,t=fe;try{var n=$n;for(fe=1;e>=a,i-=a,jn=1<<32-un(t)+i|n<C?(k=E,E=null):k=E.sibling;var P=d(p,E,g[C],S);if(P===null){E===null&&(E=k);break}e&&E&&P.alternate===null&&t(p,E),v=o(P,v,C),x===null?_=P:x.sibling=P,x=P,E=k}if(C===g.length)return n(p,E),_e&&kr(p,C),_;if(E===null){for(;CC?(k=E,E=null):k=E.sibling;var $=d(p,E,P.value,S);if($===null){E===null&&(E=k);break}e&&E&&$.alternate===null&&t(p,E),v=o($,v,C),x===null?_=$:x.sibling=$,x=$,E=k}if(P.done)return n(p,E),_e&&kr(p,C),_;if(E===null){for(;!P.done;C++,P=g.next())P=f(p,P.value,S),P!==null&&(v=o(P,v,C),x===null?_=P:x.sibling=P,x=P);return _e&&kr(p,C),_}for(E=r(p,E);!P.done;C++,P=g.next())P=h(E,p,C,P.value,S),P!==null&&(e&&P.alternate!==null&&E.delete(P.key===null?C:P.key),v=o(P,v,C),x===null?_=P:x.sibling=P,x=P);return e&&E.forEach(function(j){return t(p,j)}),_e&&kr(p,C),_}function w(p,v,g,S){if(typeof g=="object"&&g!==null&&g.type===ci&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case ja:e:{for(var _=g.key,x=v;x!==null;){if(x.key===_){if(_=g.type,_===ci){if(x.tag===7){n(p,x.sibling),v=i(x,g.props.children),v.return=p,p=v;break e}}else if(x.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Zn&&em(_)===x.type){n(p,x.sibling),v=i(x,g.props),v.ref=uo(p,x,g),v.return=p,p=v;break e}n(p,x);break}else t(p,x);x=x.sibling}g.type===ci?(v=Rr(g.props.children,p.mode,S,g.key),v.return=p,p=v):(S=Cs(g.type,g.key,g.props,null,p.mode,S),S.ref=uo(p,v,g),S.return=p,p=S)}return a(p);case ui:e:{for(x=g.key;v!==null;){if(v.key===x)if(v.tag===4&&v.stateNode.containerInfo===g.containerInfo&&v.stateNode.implementation===g.implementation){n(p,v.sibling),v=i(v,g.children||[]),v.return=p,p=v;break e}else{n(p,v);break}else t(p,v);v=v.sibling}v=hc(g,p.mode,S),v.return=p,p=v}return a(p);case Zn:return x=g._init,w(p,v,x(g._payload),S)}if(vo(g))return y(p,v,g,S);if(io(g))return m(p,v,g,S);Ka(p,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,v!==null&&v.tag===6?(n(p,v.sibling),v=i(v,g),v.return=p,p=v):(n(p,v),v=pc(g,p.mode,S),v.return=p,p=v),a(p)):n(p,v)}return w}var Fi=L1(!0),T1=L1(!1),ya={},kn=_r(ya),Jo=_r(ya),Zo=_r(ya);function Dr(e){if(e===ya)throw Error(B(174));return e}function np(e,t){switch(ve(Zo,t),ve(Jo,e),ve(kn,ya),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:nf(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=nf(t,e)}Se(kn),ve(kn,t)}function Ri(){Se(kn),Se(Jo),Se(Zo)}function D1(e){Dr(Zo.current);var t=Dr(kn.current),n=nf(t,e.type);t!==n&&(ve(Jo,e),ve(kn,n))}function rp(e){Jo.current===e&&(Se(kn),Se(Jo))}var ke=_r(0);function tl(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var sc=[];function ip(){for(var e=0;en?n:4,e(!0);var r=lc.transition;lc.transition={};try{e(!1),t()}finally{fe=n,lc.transition=r}}function Y1(){return Gt().memoizedState}function $S(e,t,n){var r=dr(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},J1(e))Z1(t,n);else if(n=A1(e,t,n,r),n!==null){var i=ft();cn(n,e,r,i),X1(n,t,r)}}function jS(e,t,n){var r=dr(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(J1(e))Z1(t,i);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var a=t.lastRenderedState,s=o(a,n);if(i.hasEagerState=!0,i.eagerState=s,dn(s,a)){var l=t.interleaved;l===null?(i.next=i,ep(t)):(i.next=l.next,l.next=i),t.interleaved=i;return}}catch{}finally{}n=A1(e,t,i,r),n!==null&&(i=ft(),cn(n,e,r,i),X1(n,t,r))}}function J1(e){var t=e.alternate;return e===Ae||t!==null&&t===Ae}function Z1(e,t){Io=nl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function X1(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,zd(e,n)}}var rl={readContext:Kt,useCallback:tt,useContext:tt,useEffect:tt,useImperativeHandle:tt,useInsertionEffect:tt,useLayoutEffect:tt,useMemo:tt,useReducer:tt,useRef:tt,useState:tt,useDebugValue:tt,useDeferredValue:tt,useTransition:tt,useMutableSource:tt,useSyncExternalStore:tt,useId:tt,unstable_isNewReconciler:!1},FS={readContext:Kt,useCallback:function(e,t){return wn().memoizedState=[e,t===void 0?null:t],e},useContext:Kt,useEffect:nm,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,bs(4194308,4,W1.bind(null,t,e),n)},useLayoutEffect:function(e,t){return bs(4194308,4,e,t)},useInsertionEffect:function(e,t){return bs(4,2,e,t)},useMemo:function(e,t){var n=wn();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=wn();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=$S.bind(null,Ae,e),[r.memoizedState,e]},useRef:function(e){var t=wn();return e={current:e},t.memoizedState=e},useState:tm,useDebugValue:up,useDeferredValue:function(e){return wn().memoizedState=e},useTransition:function(){var e=tm(!1),t=e[0];return e=DS.bind(null,e[1]),wn().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Ae,i=wn();if(_e){if(n===void 0)throw Error(B(407));n=n()}else{if(n=t(),We===null)throw Error(B(349));Vr&30||F1(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,nm(N1.bind(null,r,o,e),[e]),r.flags|=2048,ta(9,R1.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=wn(),t=We.identifierPrefix;if(_e){var n=Fn,r=jn;n=(r&~(1<<32-un(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Xo++,0")&&(l=l.replace("",e.displayName)),l}while(1<=a&&0<=s);break}}}finally{Hu=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?mo(e):""}function d3(e){switch(e.tag){case 5:return mo(e.type);case 16:return mo("Lazy");case 13:return mo("Suspense");case 19:return mo("SuspenseList");case 0:case 2:case 15:return e=Wu(e.type,!1),e;case 11:return e=Wu(e.type.render,!1),e;case 1:return e=Wu(e.type,!0),e;default:return""}}function Yc(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case ci:return"Fragment";case ui:return"Portal";case Kc:return"Profiler";case Dd:return"StrictMode";case Gc:return"Suspense";case Qc:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case I0:return(e.displayName||"Context")+".Consumer";case P0:return(e._context.displayName||"Context")+".Provider";case $d:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case jd:return t=e.displayName||null,t!==null?t:Yc(e.type)||"Memo";case Zn:t=e._payload,e=e._init;try{return Yc(e(t))}catch{}}return null}function p3(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Yc(t);case 8:return t===Dd?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function yr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function L0(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function h3(e){var t=L0(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(a){r=""+a,o.call(this,a)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(a){r=""+a},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Fa(e){e._valueTracker||(e._valueTracker=h3(e))}function T0(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=L0(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Rs(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Jc(e,t){var n=t.checked;return Pe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function yh(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=yr(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function D0(e,t){t=t.checked,t!=null&&Td(e,"checked",t,!1)}function Zc(e,t){D0(e,t);var n=yr(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Xc(e,t.type,n):t.hasOwnProperty("defaultValue")&&Xc(e,t.type,yr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function wh(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Xc(e,t,n){(t!=="number"||Rs(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var vo=Array.isArray;function _i(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=Ra.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Vo(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Co={animationIterationCount:!0,aspectRatio:!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,gridArea:!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},m3=["Webkit","ms","Moz","O"];Object.keys(Co).forEach(function(e){m3.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Co[t]=Co[e]})});function R0(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Co.hasOwnProperty(e)&&Co[e]?(""+t).trim():t+"px"}function N0(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=R0(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var v3=Pe({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function nf(e,t){if(t){if(v3[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(B(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(B(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(B(61))}if(t.style!=null&&typeof t.style!="object")throw Error(B(62))}}function rf(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var of=null;function Fd(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var af=null,xi=null,Ci=null;function Eh(e){if(e=ga(e)){if(typeof af!="function")throw Error(B(280));var t=e.stateNode;t&&(t=Vl(t),af(e.stateNode,e.type,t))}}function z0(e){xi?Ci?Ci.push(e):Ci=[e]:xi=e}function V0(){if(xi){var e=xi,t=Ci;if(Ci=xi=null,Eh(e),t)for(e=0;e>>=0,e===0?32:31-(k3(e)/A3|0)|0}var Na=64,za=4194304;function go(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Bs(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,o=e.pingedLanes,a=n&268435455;if(a!==0){var s=a&~i;s!==0?r=go(s):(o&=a,o!==0&&(r=go(o)))}else a=n&~i,a!==0?r=go(a):o!==0&&(r=go(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,o=t&-t,i>=o||i===16&&(o&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function ma(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-un(t),e[t]=n}function L3(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=ko),Mh=String.fromCharCode(32),Lh=!1;function s1(e,t){switch(e){case"keyup":return aS.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function l1(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var fi=!1;function lS(e,t){switch(e){case"compositionend":return l1(t);case"keypress":return t.which!==32?null:(Lh=!0,Mh);case"textInput":return e=t.data,e===Mh&&Lh?null:e;default:return null}}function uS(e,t){if(fi)return e==="compositionend"||!Wd&&s1(e,t)?(e=o1(),gs=Bd=rr=null,fi=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=jh(n)}}function d1(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?d1(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function p1(){for(var e=window,t=Rs();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Rs(e.document)}return t}function qd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function yS(e){var t=p1(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&d1(n.ownerDocument.documentElement,n)){if(r!==null&&qd(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=n.textContent.length,o=Math.min(r.start,i);r=r.end===void 0?o:Math.min(r.end,i),!e.extend&&o>r&&(i=r,r=o,o=i),i=Fh(n,o);var a=Fh(n,r);i&&a&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==a.node||e.focusOffset!==a.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(a.node,a.offset)):(t.setEnd(a.node,a.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,di=null,df=null,Po=null,pf=!1;function Rh(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;pf||di==null||di!==Rs(r)||(r=di,"selectionStart"in r&&qd(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Po&&Ko(Po,r)||(Po=r,r=Ws(df,"onSelect"),0mi||(e.current=wf[mi],wf[mi]=null,mi--)}function ve(e,t){mi++,wf[mi]=e.current,e.current=t}var wr={},st=_r(wr),yt=_r(!1),Nr=wr;function $i(e,t){var n=e.type.contextTypes;if(!n)return wr;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},o;for(o in n)i[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function wt(e){return e=e.childContextTypes,e!=null}function Ks(){Se(yt),Se(st)}function Wh(e,t,n){if(st.current!==wr)throw Error(B(168));ve(st,t),ve(yt,n)}function E1(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(B(108,p3(e)||"Unknown",i));return Pe({},n,r)}function Gs(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||wr,Nr=st.current,ve(st,e),ve(yt,yt.current),!0}function qh(e,t,n){var r=e.stateNode;if(!r)throw Error(B(169));n?(e=E1(e,t,Nr),r.__reactInternalMemoizedMergedChildContext=e,Se(yt),Se(st),ve(st,e)):Se(yt),ve(yt,n)}var $n=null,Bl=!1,oc=!1;function _1(e){$n===null?$n=[e]:$n.push(e)}function IS(e){Bl=!0,_1(e)}function xr(){if(!oc&&$n!==null){oc=!0;var e=0,t=fe;try{var n=$n;for(fe=1;e>=a,i-=a,jn=1<<32-un(t)+i|n<C?(k=_,_=null):k=_.sibling;var P=d(p,_,g[C],S);if(P===null){_===null&&(_=k);break}e&&_&&P.alternate===null&&t(p,_),v=o(P,v,C),x===null?E=P:x.sibling=P,x=P,_=k}if(C===g.length)return n(p,_),_e&&kr(p,C),E;if(_===null){for(;CC?(k=_,_=null):k=_.sibling;var $=d(p,_,P.value,S);if($===null){_===null&&(_=k);break}e&&_&&$.alternate===null&&t(p,_),v=o($,v,C),x===null?E=$:x.sibling=$,x=$,_=k}if(P.done)return n(p,_),_e&&kr(p,C),E;if(_===null){for(;!P.done;C++,P=g.next())P=f(p,P.value,S),P!==null&&(v=o(P,v,C),x===null?E=P:x.sibling=P,x=P);return _e&&kr(p,C),E}for(_=r(p,_);!P.done;C++,P=g.next())P=h(_,p,C,P.value,S),P!==null&&(e&&P.alternate!==null&&_.delete(P.key===null?C:P.key),v=o(P,v,C),x===null?E=P:x.sibling=P,x=P);return e&&_.forEach(function(F){return t(p,F)}),_e&&kr(p,C),E}function w(p,v,g,S){if(typeof g=="object"&&g!==null&&g.type===ci&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case ja:e:{for(var E=g.key,x=v;x!==null;){if(x.key===E){if(E=g.type,E===ci){if(x.tag===7){n(p,x.sibling),v=i(x,g.props.children),v.return=p,p=v;break e}}else if(x.elementType===E||typeof E=="object"&&E!==null&&E.$$typeof===Zn&&Xh(E)===x.type){n(p,x.sibling),v=i(x,g.props),v.ref=uo(p,x,g),v.return=p,p=v;break e}n(p,x);break}else t(p,x);x=x.sibling}g.type===ci?(v=Rr(g.props.children,p.mode,S,g.key),v.return=p,p=v):(S=Cs(g.type,g.key,g.props,null,p.mode,S),S.ref=uo(p,v,g),S.return=p,p=S)}return a(p);case ui:e:{for(x=g.key;v!==null;){if(v.key===x)if(v.tag===4&&v.stateNode.containerInfo===g.containerInfo&&v.stateNode.implementation===g.implementation){n(p,v.sibling),v=i(v,g.children||[]),v.return=p,p=v;break e}else{n(p,v);break}else t(p,v);v=v.sibling}v=pc(g,p.mode,S),v.return=p,p=v}return a(p);case Zn:return x=g._init,w(p,v,x(g._payload),S)}if(vo(g))return y(p,v,g,S);if(io(g))return m(p,v,g,S);Ka(p,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,v!==null&&v.tag===6?(n(p,v.sibling),v=i(v,g),v.return=p,p=v):(n(p,v),v=dc(g,p.mode,S),v.return=p,p=v),a(p)):n(p,v)}return w}var Fi=M1(!0),L1=M1(!1),ya={},kn=_r(ya),Jo=_r(ya),Zo=_r(ya);function Dr(e){if(e===ya)throw Error(B(174));return e}function tp(e,t){switch(ve(Zo,t),ve(Jo,e),ve(kn,ya),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:tf(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=tf(t,e)}Se(kn),ve(kn,t)}function Ri(){Se(kn),Se(Jo),Se(Zo)}function T1(e){Dr(Zo.current);var t=Dr(kn.current),n=tf(t,e.type);t!==n&&(ve(Jo,e),ve(kn,n))}function np(e){Jo.current===e&&(Se(kn),Se(Jo))}var ke=_r(0);function el(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var ac=[];function rp(){for(var e=0;en?n:4,e(!0);var r=sc.transition;sc.transition={};try{e(!1),t()}finally{fe=n,sc.transition=r}}function Q1(){return Gt().memoizedState}function DS(e,t,n){var r=dr(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Y1(e))J1(t,n);else if(n=k1(e,t,n,r),n!==null){var i=ft();cn(n,e,r,i),Z1(n,t,r)}}function $S(e,t,n){var r=dr(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Y1(e))J1(t,i);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var a=t.lastRenderedState,s=o(a,n);if(i.hasEagerState=!0,i.eagerState=s,dn(s,a)){var l=t.interleaved;l===null?(i.next=i,Xd(t)):(i.next=l.next,l.next=i),t.interleaved=i;return}}catch{}finally{}n=k1(e,t,i,r),n!==null&&(i=ft(),cn(n,e,r,i),Z1(n,t,r))}}function Y1(e){var t=e.alternate;return e===Ae||t!==null&&t===Ae}function J1(e,t){Io=tl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Z1(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Nd(e,n)}}var nl={readContext:Kt,useCallback:tt,useContext:tt,useEffect:tt,useImperativeHandle:tt,useInsertionEffect:tt,useLayoutEffect:tt,useMemo:tt,useReducer:tt,useRef:tt,useState:tt,useDebugValue:tt,useDeferredValue:tt,useTransition:tt,useMutableSource:tt,useSyncExternalStore:tt,useId:tt,unstable_isNewReconciler:!1},jS={readContext:Kt,useCallback:function(e,t){return wn().memoizedState=[e,t===void 0?null:t],e},useContext:Kt,useEffect:tm,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,bs(4194308,4,H1.bind(null,t,e),n)},useLayoutEffect:function(e,t){return bs(4194308,4,e,t)},useInsertionEffect:function(e,t){return bs(4,2,e,t)},useMemo:function(e,t){var n=wn();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=wn();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=DS.bind(null,Ae,e),[r.memoizedState,e]},useRef:function(e){var t=wn();return e={current:e},t.memoizedState=e},useState:em,useDebugValue:lp,useDeferredValue:function(e){return wn().memoizedState=e},useTransition:function(){var e=em(!1),t=e[0];return e=TS.bind(null,e[1]),wn().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Ae,i=wn();if(_e){if(n===void 0)throw Error(B(407));n=n()}else{if(n=t(),We===null)throw Error(B(349));Vr&30||j1(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,tm(R1.bind(null,r,o,e),[e]),r.flags|=2048,ta(9,F1.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=wn(),t=We.identifierPrefix;if(_e){var n=Fn,r=jn;n=(r&~(1<<32-un(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Xo++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=a.createElement(n,{is:r.is}):(e=a.createElement(n),n==="select"&&(a=e,r.multiple?a.multiple=!0:r.size&&(a.size=r.size))):e=a.createElementNS(e,n),e[En]=t,e[Yo]=r,lg(e,t,!1,!1),t.stateNode=e;e:{switch(a=of(n,r),n){case"dialog":ge("cancel",e),ge("close",e),i=r;break;case"iframe":case"object":case"embed":ge("load",e),i=r;break;case"video":case"audio":for(i=0;izi&&(t.flags|=128,r=!0,co(o,!1),t.lanes=4194304)}else{if(!r)if(e=tl(a),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),co(o,!0),o.tail===null&&o.tailMode==="hidden"&&!a.alternate&&!_e)return nt(t),null}else 2*$e()-o.renderingStartTime>zi&&n!==1073741824&&(t.flags|=128,r=!0,co(o,!1),t.lanes=4194304);o.isBackwards?(a.sibling=t.child,t.child=a):(n=o.last,n!==null?n.sibling=a:t.child=a,o.last=a)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=$e(),t.sibling=null,n=ke.current,ve(ke,r?n&1|2:n&1),t):(nt(t),null);case 22:case 23:return mp(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Ct&1073741824&&(nt(t),t.subtreeFlags&6&&(t.flags|=8192)):nt(t),null;case 24:return null;case 25:return null}throw Error(B(156,t.tag))}function WS(e,t){switch(Qd(t),t.tag){case 1:return wt(t.type)&&Gs(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ri(),Se(yt),Se(st),ip(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return rp(t),null;case 13:if(Se(ke),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(B(340));ji()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Se(ke),null;case 4:return Ri(),null;case 10:return Xd(t.type._context),null;case 22:case 23:return mp(),null;case 24:return null;default:return null}}var Qa=!1,ot=!1,qS=typeof WeakSet=="function"?WeakSet:Set,K=null;function wi(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Te(e,t,r)}else n.current=null}function Lf(e,t,n){try{n()}catch(r){Te(e,t,r)}}var fm=!1;function KS(e,t){if(mf=Hs,e=h1(),Kd(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var a=0,s=-1,l=-1,u=0,c=0,f=e,d=null;t:for(;;){for(var h;f!==n||i!==0&&f.nodeType!==3||(s=a+i),f!==o||r!==0&&f.nodeType!==3||(l=a+r),f.nodeType===3&&(a+=f.nodeValue.length),(h=f.firstChild)!==null;)d=f,f=h;for(;;){if(f===e)break t;if(d===n&&++u===i&&(s=a),d===o&&++c===r&&(l=a),(h=f.nextSibling)!==null)break;f=d,d=f.parentNode}f=h}n=s===-1||l===-1?null:{start:s,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(vf={focusedElem:e,selectionRange:n},Hs=!1,K=t;K!==null;)if(t=K,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,K=e;else for(;K!==null;){t=K;try{var y=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(y!==null){var m=y.memoizedProps,w=y.memoizedState,p=t.stateNode,v=p.getSnapshotBeforeUpdate(t.elementType===t.type?m:en(t.type,m),w);p.__reactInternalSnapshotBeforeUpdate=v}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(B(163))}}catch(S){Te(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,K=e;break}K=t.return}return y=fm,fm=!1,y}function Mo(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var o=i.destroy;i.destroy=void 0,o!==void 0&&Lf(t,n,o)}i=i.next}while(i!==r)}}function ql(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Tf(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function fg(e){var t=e.alternate;t!==null&&(e.alternate=null,fg(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[En],delete t[Yo],delete t[wf],delete t[PS],delete t[IS])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function dg(e){return e.tag===5||e.tag===3||e.tag===4}function dm(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||dg(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Df(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Ks));else if(r!==4&&(e=e.child,e!==null))for(Df(e,t,n),e=e.sibling;e!==null;)Df(e,t,n),e=e.sibling}function $f(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for($f(e,t,n),e=e.sibling;e!==null;)$f(e,t,n),e=e.sibling}var Ge=null,nn=!1;function Qn(e,t,n){for(n=n.child;n!==null;)pg(e,t,n),n=n.sibling}function pg(e,t,n){if(On&&typeof On.onCommitFiberUnmount=="function")try{On.onCommitFiberUnmount(Rl,n)}catch{}switch(n.tag){case 5:ot||wi(n,t);case 6:var r=Ge,i=nn;Ge=null,Qn(e,t,n),Ge=r,nn=i,Ge!==null&&(nn?(e=Ge,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ge.removeChild(n.stateNode));break;case 18:Ge!==null&&(nn?(e=Ge,n=n.stateNode,e.nodeType===8?oc(e.parentNode,n):e.nodeType===1&&oc(e,n),Wo(e)):oc(Ge,n.stateNode));break;case 4:r=Ge,i=nn,Ge=n.stateNode.containerInfo,nn=!0,Qn(e,t,n),Ge=r,nn=i;break;case 0:case 11:case 14:case 15:if(!ot&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var o=i,a=o.destroy;o=o.tag,a!==void 0&&(o&2||o&4)&&Lf(n,t,a),i=i.next}while(i!==r)}Qn(e,t,n);break;case 1:if(!ot&&(wi(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(s){Te(n,t,s)}Qn(e,t,n);break;case 21:Qn(e,t,n);break;case 22:n.mode&1?(ot=(r=ot)||n.memoizedState!==null,Qn(e,t,n),ot=r):Qn(e,t,n);break;default:Qn(e,t,n)}}function pm(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new qS),t.forEach(function(r){var i=nb.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Xt(e,t){var n=t.deletions;if(n!==null)for(var r=0;ri&&(i=a),r&=~o}if(r=i,r=$e()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*QS(r/1960))-r,10e?16:e,ir===null)var r=!1;else{if(e=ir,ir=null,al=0,ie&6)throw Error(B(331));var i=ie;for(ie|=4,K=e.current;K!==null;){var o=K,a=o.child;if(K.flags&16){var s=o.deletions;if(s!==null){for(var l=0;l$e()-pp?Fr(e,0):dp|=n),St(e,t)}function bg(e,t){t===0&&(e.mode&1?(t=za,za<<=1,!(za&130023424)&&(za=4194304)):t=1);var n=ft();e=Un(e,t),e!==null&&(ma(e,t,n),St(e,n))}function tb(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),bg(e,n)}function nb(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(B(314))}r!==null&&r.delete(t),bg(e,n)}var Eg;Eg=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||yt.current)vt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return vt=!1,US(e,t,n);vt=!!(e.flags&131072)}else vt=!1,_e&&t.flags&1048576&&C1(t,Js,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Es(e,t),e=t.pendingProps;var i=$i(t,st.current);ki(t,n),i=ap(null,t,r,e,i,n);var o=sp();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,wt(r)?(o=!0,Qs(t)):o=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,tp(t),i.updater=Hl,t.stateNode=i,i._reactInternals=t,Cf(t,r,e,n),t=Af(null,t,r,!0,o,n)):(t.tag=0,_e&&o&&Gd(t),lt(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Es(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=ib(r),e=en(r,e),i){case 0:t=kf(null,t,r,e,n);break e;case 1:t=lm(null,t,r,e,n);break e;case 11:t=am(null,t,r,e,n);break e;case 14:t=sm(null,t,r,en(r.type,e),n);break e}throw Error(B(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:en(r,i),kf(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:en(r,i),lm(e,t,r,i,n);case 3:e:{if(og(t),e===null)throw Error(B(387));r=t.pendingProps,o=t.memoizedState,i=o.element,P1(e,t),el(t,r,null,n);var a=t.memoizedState;if(r=a.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:a.cache,pendingSuspenseBoundaries:a.pendingSuspenseBoundaries,transitions:a.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){i=Ni(Error(B(423)),t),t=um(e,t,r,n,i);break e}else if(r!==i){i=Ni(Error(B(424)),t),t=um(e,t,r,n,i);break e}else for(At=ur(t.stateNode.containerInfo.firstChild),Pt=t,_e=!0,rn=null,n=T1(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(ji(),r===i){t=Hn(e,t,n);break e}lt(e,t,r,n)}t=t.child}return t;case 5:return D1(t),e===null&&Ef(t),r=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,a=i.children,gf(r,i)?a=null:o!==null&&gf(r,o)&&(t.flags|=32),ig(e,t),lt(e,t,a,n),t.child;case 6:return e===null&&Ef(t),null;case 13:return ag(e,t,n);case 4:return np(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Fi(t,null,r,n):lt(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:en(r,i),am(e,t,r,i,n);case 7:return lt(e,t,t.pendingProps,n),t.child;case 8:return lt(e,t,t.pendingProps.children,n),t.child;case 12:return lt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,o=t.memoizedProps,a=i.value,ve(Zs,r._currentValue),r._currentValue=a,o!==null)if(dn(o.value,a)){if(o.children===i.children&&!yt.current){t=Hn(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var s=o.dependencies;if(s!==null){a=o.child;for(var l=s.firstContext;l!==null;){if(l.context===r){if(o.tag===1){l=Rn(-1,n&-n),l.tag=2;var u=o.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),_f(o.return,n,t),s.lanes|=n;break}l=l.next}}else if(o.tag===10)a=o.type===t.type?null:o.child;else if(o.tag===18){if(a=o.return,a===null)throw Error(B(341));a.lanes|=n,s=a.alternate,s!==null&&(s.lanes|=n),_f(a,n,t),a=o.sibling}else a=o.child;if(a!==null)a.return=o;else for(a=o;a!==null;){if(a===t){a=null;break}if(o=a.sibling,o!==null){o.return=a.return,a=o;break}a=a.return}o=a}lt(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,ki(t,n),i=Kt(i),r=r(i),t.flags|=1,lt(e,t,r,n),t.child;case 14:return r=t.type,i=en(r,t.pendingProps),i=en(r.type,i),sm(e,t,r,i,n);case 15:return ng(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:en(r,i),Es(e,t),t.tag=1,wt(r)?(e=!0,Qs(t)):e=!1,ki(t,n),M1(t,r,i),Cf(t,r,i,n),Af(null,t,r,!0,e,n);case 19:return sg(e,t,n);case 22:return rg(e,t,n)}throw Error(B(156,t.tag))};function _g(e,t){return Q0(e,t)}function rb(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ht(e,t,n,r){return new rb(e,t,n,r)}function gp(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ib(e){if(typeof e=="function")return gp(e)?1:0;if(e!=null){if(e=e.$$typeof,e===jd)return 11;if(e===Fd)return 14}return 2}function pr(e,t){var n=e.alternate;return n===null?(n=Ht(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Cs(e,t,n,r,i,o){var a=2;if(r=e,typeof e=="function")gp(e)&&(a=1);else if(typeof e=="string")a=5;else e:switch(e){case ci:return Rr(n.children,i,o,t);case $d:a=8,i|=8;break;case Gc:return e=Ht(12,n,t,i|2),e.elementType=Gc,e.lanes=o,e;case Qc:return e=Ht(13,n,t,i),e.elementType=Qc,e.lanes=o,e;case Yc:return e=Ht(19,n,t,i),e.elementType=Yc,e.lanes=o,e;case L0:return Gl(n,i,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case I0:a=10;break e;case M0:a=9;break e;case jd:a=11;break e;case Fd:a=14;break e;case Zn:a=16,r=null;break e}throw Error(B(130,e==null?e:typeof e,""))}return t=Ht(a,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function Rr(e,t,n,r){return e=Ht(7,e,r,t),e.lanes=n,e}function Gl(e,t,n,r){return e=Ht(22,e,r,t),e.elementType=L0,e.lanes=n,e.stateNode={isHidden:!1},e}function pc(e,t,n){return e=Ht(6,e,null,t),e.lanes=n,e}function hc(e,t,n){return t=Ht(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function ob(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Gu(0),this.expirationTimes=Gu(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Gu(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function yp(e,t,n,r,i,o,a,s,l){return e=new ob(e,t,n,s,l),t===1?(t=1,o===!0&&(t|=8)):t=0,o=Ht(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},tp(o),e}function ab(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(kg)}catch(e){console.error(e)}}kg(),C0.exports=Tt;var Ep=C0.exports,bm=Ep;qc.createRoot=bm.createRoot,qc.hydrateRoot=bm.hydrateRoot;var Ag={exports:{}},Pg={};/** +`+o.stack}return{value:e,source:t,stack:i,digest:null}}function cc(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Cf(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var NS=typeof WeakMap=="function"?WeakMap:Map;function X1(e,t,n){n=Rn(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){il||(il=!0,$f=r),Cf(e,t)},n}function eg(e,t,n){n=Rn(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=t.value;n.payload=function(){return r(i)},n.callback=function(){Cf(e,t)}}var o=e.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(n.callback=function(){Cf(e,t),typeof r!="function"&&(fr===null?fr=new Set([this]):fr.add(this));var a=t.stack;this.componentDidCatch(t.value,{componentStack:a!==null?a:""})}),n}function nm(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new NS;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(i.add(n),e=XS.bind(null,e,t,n),t.then(e,e))}function rm(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function im(e,t,n,r,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=Rn(-1,1),t.tag=2,cr(n,t,1))),n.lanes|=1),e)}var zS=Kn.ReactCurrentOwner,vt=!1;function lt(e,t,n,r){t.child=e===null?L1(t,null,n,r):Fi(t,e.child,n,r)}function om(e,t,n,r,i){n=n.render;var o=t.ref;return ki(t,i),r=op(e,t,n,r,o,i),n=ap(),e!==null&&!vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Hn(e,t,i)):(_e&&n&&Kd(t),t.flags|=1,lt(e,t,r,i),t.child)}function am(e,t,n,r,i){if(e===null){var o=n.type;return typeof o=="function"&&!vp(o)&&o.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=o,tg(e,t,o,r,i)):(e=Cs(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(o=e.child,!(e.lanes&i)){var a=o.memoizedProps;if(n=n.compare,n=n!==null?n:Ko,n(a,r)&&e.ref===t.ref)return Hn(e,t,i)}return t.flags|=1,e=pr(o,r),e.ref=t.ref,e.return=t,t.child=e}function tg(e,t,n,r,i){if(e!==null){var o=e.memoizedProps;if(Ko(o,r)&&e.ref===t.ref)if(vt=!1,t.pendingProps=r=o,(e.lanes&i)!==0)e.flags&131072&&(vt=!0);else return t.lanes=e.lanes,Hn(e,t,i)}return Of(e,t,n,r,i)}function ng(e,t,n){var r=t.pendingProps,i=r.children,o=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},ve(Si,Ct),Ct|=n;else{if(!(n&1073741824))return e=o!==null?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,ve(Si,Ct),Ct|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=o!==null?o.baseLanes:n,ve(Si,Ct),Ct|=r}else o!==null?(r=o.baseLanes|n,t.memoizedState=null):r=n,ve(Si,Ct),Ct|=r;return lt(e,t,i,n),t.child}function rg(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Of(e,t,n,r,i){var o=wt(n)?Nr:st.current;return o=$i(t,o),ki(t,i),n=op(e,t,n,r,o,i),r=ap(),e!==null&&!vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Hn(e,t,i)):(_e&&r&&Kd(t),t.flags|=1,lt(e,t,n,i),t.child)}function sm(e,t,n,r,i){if(wt(n)){var o=!0;Gs(t)}else o=!1;if(ki(t,i),t.stateNode===null)Es(e,t),I1(t,n,r),xf(t,n,r,i),r=!0;else if(e===null){var a=t.stateNode,s=t.memoizedProps;a.props=s;var l=a.context,u=n.contextType;typeof u=="object"&&u!==null?u=Kt(u):(u=wt(n)?Nr:st.current,u=$i(t,u));var c=n.getDerivedStateFromProps,f=typeof c=="function"||typeof a.getSnapshotBeforeUpdate=="function";f||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(s!==r||l!==u)&&Zh(t,a,r,u),Xn=!1;var d=t.memoizedState;a.state=d,Xs(t,r,a,i),l=t.memoizedState,s!==r||d!==l||yt.current||Xn?(typeof c=="function"&&(_f(t,n,c,r),l=t.memoizedState),(s=Xn||Jh(t,n,s,r,d,l,u))?(f||typeof a.UNSAFE_componentWillMount!="function"&&typeof a.componentWillMount!="function"||(typeof a.componentWillMount=="function"&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount=="function"&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount=="function"&&(t.flags|=4194308)):(typeof a.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=u,r=s):(typeof a.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,A1(e,t),s=t.memoizedProps,u=t.type===t.elementType?s:en(t.type,s),a.props=u,f=t.pendingProps,d=a.context,l=n.contextType,typeof l=="object"&&l!==null?l=Kt(l):(l=wt(n)?Nr:st.current,l=$i(t,l));var h=n.getDerivedStateFromProps;(c=typeof h=="function"||typeof a.getSnapshotBeforeUpdate=="function")||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(s!==f||d!==l)&&Zh(t,a,r,l),Xn=!1,d=t.memoizedState,a.state=d,Xs(t,r,a,i);var y=t.memoizedState;s!==f||d!==y||yt.current||Xn?(typeof h=="function"&&(_f(t,n,h,r),y=t.memoizedState),(u=Xn||Jh(t,n,u,r,d,y,l)||!1)?(c||typeof a.UNSAFE_componentWillUpdate!="function"&&typeof a.componentWillUpdate!="function"||(typeof a.componentWillUpdate=="function"&&a.componentWillUpdate(r,y,l),typeof a.UNSAFE_componentWillUpdate=="function"&&a.UNSAFE_componentWillUpdate(r,y,l)),typeof a.componentDidUpdate=="function"&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof a.componentDidUpdate!="function"||s===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=y),a.props=r,a.state=y,a.context=l,r=u):(typeof a.componentDidUpdate!="function"||s===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),r=!1)}return kf(e,t,n,r,o,i)}function kf(e,t,n,r,i,o){rg(e,t);var a=(t.flags&128)!==0;if(!r&&!a)return i&&qh(t,n,!1),Hn(e,t,o);r=t.stateNode,zS.current=t;var s=a&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&a?(t.child=Fi(t,e.child,null,o),t.child=Fi(t,null,s,o)):lt(e,t,s,o),t.memoizedState=r.state,i&&qh(t,n,!0),t.child}function ig(e){var t=e.stateNode;t.pendingContext?Wh(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Wh(e,t.context,!1),tp(e,t.containerInfo)}function lm(e,t,n,r,i){return ji(),Qd(i),t.flags|=256,lt(e,t,n,r),t.child}var Af={dehydrated:null,treeContext:null,retryLane:0};function Pf(e){return{baseLanes:e,cachePool:null,transitions:null}}function og(e,t,n){var r=t.pendingProps,i=ke.current,o=!1,a=(t.flags&128)!==0,s;if((s=a)||(s=e!==null&&e.memoizedState===null?!1:(i&2)!==0),s?(o=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),ve(ke,i&1),e===null)return bf(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(a=r.children,e=r.fallback,o?(r=t.mode,o=t.child,a={mode:"hidden",children:a},!(r&1)&&o!==null?(o.childLanes=0,o.pendingProps=a):o=Kl(a,r,0,null),e=Rr(e,r,n,null),o.return=t,e.return=t,o.sibling=e,t.child=o,t.child.memoizedState=Pf(n),t.memoizedState=Af,e):up(t,a));if(i=e.memoizedState,i!==null&&(s=i.dehydrated,s!==null))return VS(e,t,a,r,s,i,n);if(o){o=r.fallback,a=t.mode,i=e.child,s=i.sibling;var l={mode:"hidden",children:r.children};return!(a&1)&&t.child!==i?(r=t.child,r.childLanes=0,r.pendingProps=l,t.deletions=null):(r=pr(i,l),r.subtreeFlags=i.subtreeFlags&14680064),s!==null?o=pr(s,o):(o=Rr(o,a,n,null),o.flags|=2),o.return=t,r.return=t,r.sibling=o,t.child=r,r=o,o=t.child,a=e.child.memoizedState,a=a===null?Pf(n):{baseLanes:a.baseLanes|n,cachePool:null,transitions:a.transitions},o.memoizedState=a,o.childLanes=e.childLanes&~n,t.memoizedState=Af,r}return o=e.child,e=o.sibling,r=pr(o,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function up(e,t){return t=Kl({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Ga(e,t,n,r){return r!==null&&Qd(r),Fi(t,e.child,null,n),e=up(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function VS(e,t,n,r,i,o,a){if(n)return t.flags&256?(t.flags&=-257,r=cc(Error(B(422))),Ga(e,t,a,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(o=r.fallback,i=t.mode,r=Kl({mode:"visible",children:r.children},i,0,null),o=Rr(o,i,a,null),o.flags|=2,r.return=t,o.return=t,r.sibling=o,t.child=r,t.mode&1&&Fi(t,e.child,null,a),t.child.memoizedState=Pf(a),t.memoizedState=Af,o);if(!(t.mode&1))return Ga(e,t,a,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var s=r.dgst;return r=s,o=Error(B(419)),r=cc(o,r,void 0),Ga(e,t,a,r)}if(s=(a&e.childLanes)!==0,vt||s){if(r=We,r!==null){switch(a&-a){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|a)?0:i,i!==0&&i!==o.retryLane&&(o.retryLane=i,Un(e,i),cn(r,e,i,-1))}return mp(),r=cc(Error(B(421))),Ga(e,t,a,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=eb.bind(null,e),i._reactRetry=t,null):(e=o.treeContext,At=ur(i.nextSibling),Pt=t,_e=!0,rn=null,e!==null&&(Bt[Ut++]=jn,Bt[Ut++]=Fn,Bt[Ut++]=zr,jn=e.id,Fn=e.overflow,zr=t),t=up(t,r.children),t.flags|=4096,t)}function um(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Ef(e.return,t,n)}function fc(e,t,n,r,i){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i)}function ag(e,t,n){var r=t.pendingProps,i=r.revealOrder,o=r.tail;if(lt(e,t,r.children,n),r=ke.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&um(e,n,t);else if(e.tag===19)um(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(ve(ke,r),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&el(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),fc(t,!1,i,n,o);break;case"backwards":for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&el(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}fc(t,!0,n,null,o);break;case"together":fc(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Es(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Hn(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Br|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(B(153));if(t.child!==null){for(e=t.child,n=pr(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=pr(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function BS(e,t,n){switch(t.tag){case 3:ig(t),ji();break;case 5:T1(t);break;case 1:wt(t.type)&&Gs(t);break;case 4:tp(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;ve(Js,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(ve(ke,ke.current&1),t.flags|=128,null):n&t.child.childLanes?og(e,t,n):(ve(ke,ke.current&1),e=Hn(e,t,n),e!==null?e.sibling:null);ve(ke,ke.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return ag(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),ve(ke,ke.current),r)break;return null;case 22:case 23:return t.lanes=0,ng(e,t,n)}return Hn(e,t,n)}var sg,If,lg,ug;sg=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};If=function(){};lg=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,Dr(kn.current);var o=null;switch(n){case"input":i=Jc(e,i),r=Jc(e,r),o=[];break;case"select":i=Pe({},i,{value:void 0}),r=Pe({},r,{value:void 0}),o=[];break;case"textarea":i=ef(e,i),r=ef(e,r),o=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=qs)}nf(n,r);var a;n=null;for(u in i)if(!r.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var s=i[u];for(a in s)s.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(zo.hasOwnProperty(u)?o||(o=[]):(o=o||[]).push(u,null));for(u in r){var l=r[u];if(s=i!=null?i[u]:void 0,r.hasOwnProperty(u)&&l!==s&&(l!=null||s!=null))if(u==="style")if(s){for(a in s)!s.hasOwnProperty(a)||l&&l.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in l)l.hasOwnProperty(a)&&s[a]!==l[a]&&(n||(n={}),n[a]=l[a])}else n||(o||(o=[]),o.push(u,n)),n=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,s=s?s.__html:void 0,l!=null&&s!==l&&(o=o||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(o=o||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(zo.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&ge("scroll",e),o||s===l||(o=[])):(o=o||[]).push(u,l))}n&&(o=o||[]).push("style",n);var u=o;(t.updateQueue=u)&&(t.flags|=4)}};ug=function(e,t,n,r){n!==r&&(t.flags|=4)};function co(e,t){if(!_e)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function nt(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function US(e,t,n){var r=t.pendingProps;switch(Gd(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return nt(t),null;case 1:return wt(t.type)&&Ks(),nt(t),null;case 3:return r=t.stateNode,Ri(),Se(yt),Se(st),rp(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(qa(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,rn!==null&&(Rf(rn),rn=null))),If(e,t),nt(t),null;case 5:np(t);var i=Dr(Zo.current);if(n=t.type,e!==null&&t.stateNode!=null)lg(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(B(166));return nt(t),null}if(e=Dr(kn.current),qa(t)){r=t.stateNode,n=t.type;var o=t.memoizedProps;switch(r[En]=t,r[Yo]=o,e=(t.mode&1)!==0,n){case"dialog":ge("cancel",r),ge("close",r);break;case"iframe":case"object":case"embed":ge("load",r);break;case"video":case"audio":for(i=0;i<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=a.createElement(n,{is:r.is}):(e=a.createElement(n),n==="select"&&(a=e,r.multiple?a.multiple=!0:r.size&&(a.size=r.size))):e=a.createElementNS(e,n),e[En]=t,e[Yo]=r,sg(e,t,!1,!1),t.stateNode=e;e:{switch(a=rf(n,r),n){case"dialog":ge("cancel",e),ge("close",e),i=r;break;case"iframe":case"object":case"embed":ge("load",e),i=r;break;case"video":case"audio":for(i=0;izi&&(t.flags|=128,r=!0,co(o,!1),t.lanes=4194304)}else{if(!r)if(e=el(a),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),co(o,!0),o.tail===null&&o.tailMode==="hidden"&&!a.alternate&&!_e)return nt(t),null}else 2*$e()-o.renderingStartTime>zi&&n!==1073741824&&(t.flags|=128,r=!0,co(o,!1),t.lanes=4194304);o.isBackwards?(a.sibling=t.child,t.child=a):(n=o.last,n!==null?n.sibling=a:t.child=a,o.last=a)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=$e(),t.sibling=null,n=ke.current,ve(ke,r?n&1|2:n&1),t):(nt(t),null);case 22:case 23:return hp(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Ct&1073741824&&(nt(t),t.subtreeFlags&6&&(t.flags|=8192)):nt(t),null;case 24:return null;case 25:return null}throw Error(B(156,t.tag))}function HS(e,t){switch(Gd(t),t.tag){case 1:return wt(t.type)&&Ks(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ri(),Se(yt),Se(st),rp(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return np(t),null;case 13:if(Se(ke),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(B(340));ji()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Se(ke),null;case 4:return Ri(),null;case 10:return Zd(t.type._context),null;case 22:case 23:return hp(),null;case 24:return null;default:return null}}var Qa=!1,ot=!1,WS=typeof WeakSet=="function"?WeakSet:Set,K=null;function wi(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Te(e,t,r)}else n.current=null}function Mf(e,t,n){try{n()}catch(r){Te(e,t,r)}}var cm=!1;function qS(e,t){if(hf=Us,e=p1(),qd(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var a=0,s=-1,l=-1,u=0,c=0,f=e,d=null;t:for(;;){for(var h;f!==n||i!==0&&f.nodeType!==3||(s=a+i),f!==o||r!==0&&f.nodeType!==3||(l=a+r),f.nodeType===3&&(a+=f.nodeValue.length),(h=f.firstChild)!==null;)d=f,f=h;for(;;){if(f===e)break t;if(d===n&&++u===i&&(s=a),d===o&&++c===r&&(l=a),(h=f.nextSibling)!==null)break;f=d,d=f.parentNode}f=h}n=s===-1||l===-1?null:{start:s,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(mf={focusedElem:e,selectionRange:n},Us=!1,K=t;K!==null;)if(t=K,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,K=e;else for(;K!==null;){t=K;try{var y=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(y!==null){var m=y.memoizedProps,w=y.memoizedState,p=t.stateNode,v=p.getSnapshotBeforeUpdate(t.elementType===t.type?m:en(t.type,m),w);p.__reactInternalSnapshotBeforeUpdate=v}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(B(163))}}catch(S){Te(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,K=e;break}K=t.return}return y=cm,cm=!1,y}function Mo(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var o=i.destroy;i.destroy=void 0,o!==void 0&&Mf(t,n,o)}i=i.next}while(i!==r)}}function Wl(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Lf(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function cg(e){var t=e.alternate;t!==null&&(e.alternate=null,cg(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[En],delete t[Yo],delete t[yf],delete t[AS],delete t[PS])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function fg(e){return e.tag===5||e.tag===3||e.tag===4}function fm(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||fg(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Tf(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=qs));else if(r!==4&&(e=e.child,e!==null))for(Tf(e,t,n),e=e.sibling;e!==null;)Tf(e,t,n),e=e.sibling}function Df(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(Df(e,t,n),e=e.sibling;e!==null;)Df(e,t,n),e=e.sibling}var Ge=null,nn=!1;function Qn(e,t,n){for(n=n.child;n!==null;)dg(e,t,n),n=n.sibling}function dg(e,t,n){if(On&&typeof On.onCommitFiberUnmount=="function")try{On.onCommitFiberUnmount(Fl,n)}catch{}switch(n.tag){case 5:ot||wi(n,t);case 6:var r=Ge,i=nn;Ge=null,Qn(e,t,n),Ge=r,nn=i,Ge!==null&&(nn?(e=Ge,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ge.removeChild(n.stateNode));break;case 18:Ge!==null&&(nn?(e=Ge,n=n.stateNode,e.nodeType===8?ic(e.parentNode,n):e.nodeType===1&&ic(e,n),Wo(e)):ic(Ge,n.stateNode));break;case 4:r=Ge,i=nn,Ge=n.stateNode.containerInfo,nn=!0,Qn(e,t,n),Ge=r,nn=i;break;case 0:case 11:case 14:case 15:if(!ot&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var o=i,a=o.destroy;o=o.tag,a!==void 0&&(o&2||o&4)&&Mf(n,t,a),i=i.next}while(i!==r)}Qn(e,t,n);break;case 1:if(!ot&&(wi(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(s){Te(n,t,s)}Qn(e,t,n);break;case 21:Qn(e,t,n);break;case 22:n.mode&1?(ot=(r=ot)||n.memoizedState!==null,Qn(e,t,n),ot=r):Qn(e,t,n);break;default:Qn(e,t,n)}}function dm(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new WS),t.forEach(function(r){var i=tb.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Xt(e,t){var n=t.deletions;if(n!==null)for(var r=0;ri&&(i=a),r&=~o}if(r=i,r=$e()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*GS(r/1960))-r,10e?16:e,ir===null)var r=!1;else{if(e=ir,ir=null,ol=0,ie&6)throw Error(B(331));var i=ie;for(ie|=4,K=e.current;K!==null;){var o=K,a=o.child;if(K.flags&16){var s=o.deletions;if(s!==null){for(var l=0;l$e()-dp?Fr(e,0):fp|=n),St(e,t)}function Sg(e,t){t===0&&(e.mode&1?(t=za,za<<=1,!(za&130023424)&&(za=4194304)):t=1);var n=ft();e=Un(e,t),e!==null&&(ma(e,t,n),St(e,n))}function eb(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Sg(e,n)}function tb(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(B(314))}r!==null&&r.delete(t),Sg(e,n)}var bg;bg=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||yt.current)vt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return vt=!1,BS(e,t,n);vt=!!(e.flags&131072)}else vt=!1,_e&&t.flags&1048576&&x1(t,Ys,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Es(e,t),e=t.pendingProps;var i=$i(t,st.current);ki(t,n),i=op(null,t,r,e,i,n);var o=ap();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,wt(r)?(o=!0,Gs(t)):o=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,ep(t),i.updater=Ul,t.stateNode=i,i._reactInternals=t,xf(t,r,e,n),t=kf(null,t,r,!0,o,n)):(t.tag=0,_e&&o&&Kd(t),lt(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Es(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=rb(r),e=en(r,e),i){case 0:t=Of(null,t,r,e,n);break e;case 1:t=sm(null,t,r,e,n);break e;case 11:t=om(null,t,r,e,n);break e;case 14:t=am(null,t,r,en(r.type,e),n);break e}throw Error(B(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:en(r,i),Of(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:en(r,i),sm(e,t,r,i,n);case 3:e:{if(ig(t),e===null)throw Error(B(387));r=t.pendingProps,o=t.memoizedState,i=o.element,A1(e,t),Xs(t,r,null,n);var a=t.memoizedState;if(r=a.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:a.cache,pendingSuspenseBoundaries:a.pendingSuspenseBoundaries,transitions:a.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){i=Ni(Error(B(423)),t),t=lm(e,t,r,n,i);break e}else if(r!==i){i=Ni(Error(B(424)),t),t=lm(e,t,r,n,i);break e}else for(At=ur(t.stateNode.containerInfo.firstChild),Pt=t,_e=!0,rn=null,n=L1(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(ji(),r===i){t=Hn(e,t,n);break e}lt(e,t,r,n)}t=t.child}return t;case 5:return T1(t),e===null&&bf(t),r=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,a=i.children,vf(r,i)?a=null:o!==null&&vf(r,o)&&(t.flags|=32),rg(e,t),lt(e,t,a,n),t.child;case 6:return e===null&&bf(t),null;case 13:return og(e,t,n);case 4:return tp(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Fi(t,null,r,n):lt(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:en(r,i),om(e,t,r,i,n);case 7:return lt(e,t,t.pendingProps,n),t.child;case 8:return lt(e,t,t.pendingProps.children,n),t.child;case 12:return lt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,o=t.memoizedProps,a=i.value,ve(Js,r._currentValue),r._currentValue=a,o!==null)if(dn(o.value,a)){if(o.children===i.children&&!yt.current){t=Hn(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var s=o.dependencies;if(s!==null){a=o.child;for(var l=s.firstContext;l!==null;){if(l.context===r){if(o.tag===1){l=Rn(-1,n&-n),l.tag=2;var u=o.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),Ef(o.return,n,t),s.lanes|=n;break}l=l.next}}else if(o.tag===10)a=o.type===t.type?null:o.child;else if(o.tag===18){if(a=o.return,a===null)throw Error(B(341));a.lanes|=n,s=a.alternate,s!==null&&(s.lanes|=n),Ef(a,n,t),a=o.sibling}else a=o.child;if(a!==null)a.return=o;else for(a=o;a!==null;){if(a===t){a=null;break}if(o=a.sibling,o!==null){o.return=a.return,a=o;break}a=a.return}o=a}lt(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,ki(t,n),i=Kt(i),r=r(i),t.flags|=1,lt(e,t,r,n),t.child;case 14:return r=t.type,i=en(r,t.pendingProps),i=en(r.type,i),am(e,t,r,i,n);case 15:return tg(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:en(r,i),Es(e,t),t.tag=1,wt(r)?(e=!0,Gs(t)):e=!1,ki(t,n),I1(t,r,i),xf(t,r,i,n),kf(null,t,r,!0,e,n);case 19:return ag(e,t,n);case 22:return ng(e,t,n)}throw Error(B(156,t.tag))};function Eg(e,t){return G0(e,t)}function nb(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ht(e,t,n,r){return new nb(e,t,n,r)}function vp(e){return e=e.prototype,!(!e||!e.isReactComponent)}function rb(e){if(typeof e=="function")return vp(e)?1:0;if(e!=null){if(e=e.$$typeof,e===$d)return 11;if(e===jd)return 14}return 2}function pr(e,t){var n=e.alternate;return n===null?(n=Ht(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Cs(e,t,n,r,i,o){var a=2;if(r=e,typeof e=="function")vp(e)&&(a=1);else if(typeof e=="string")a=5;else e:switch(e){case ci:return Rr(n.children,i,o,t);case Dd:a=8,i|=8;break;case Kc:return e=Ht(12,n,t,i|2),e.elementType=Kc,e.lanes=o,e;case Gc:return e=Ht(13,n,t,i),e.elementType=Gc,e.lanes=o,e;case Qc:return e=Ht(19,n,t,i),e.elementType=Qc,e.lanes=o,e;case M0:return Kl(n,i,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case P0:a=10;break e;case I0:a=9;break e;case $d:a=11;break e;case jd:a=14;break e;case Zn:a=16,r=null;break e}throw Error(B(130,e==null?e:typeof e,""))}return t=Ht(a,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function Rr(e,t,n,r){return e=Ht(7,e,r,t),e.lanes=n,e}function Kl(e,t,n,r){return e=Ht(22,e,r,t),e.elementType=M0,e.lanes=n,e.stateNode={isHidden:!1},e}function dc(e,t,n){return e=Ht(6,e,null,t),e.lanes=n,e}function pc(e,t,n){return t=Ht(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function ib(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Ku(0),this.expirationTimes=Ku(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ku(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function gp(e,t,n,r,i,o,a,s,l){return e=new ib(e,t,n,s,l),t===1?(t=1,o===!0&&(t|=8)):t=0,o=Ht(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},ep(o),e}function ob(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Og)}catch(e){console.error(e)}}Og(),x0.exports=Tt;var bp=x0.exports,Sm=bp;Wc.createRoot=Sm.createRoot,Wc.hydrateRoot=Sm.hydrateRoot;var kg={exports:{}},Ag={};/** * @license React * use-sync-external-store-shim.production.min.js * @@ -45,7 +45,7 @@ Error generating stack: `+o.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var Vi=b;function fb(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var db=typeof Object.is=="function"?Object.is:fb,pb=Vi.useState,hb=Vi.useEffect,mb=Vi.useLayoutEffect,vb=Vi.useDebugValue;function gb(e,t){var n=t(),r=pb({inst:{value:n,getSnapshot:t}}),i=r[0].inst,o=r[1];return mb(function(){i.value=n,i.getSnapshot=t,mc(i)&&o({inst:i})},[e,n,t]),hb(function(){return mc(i)&&o({inst:i}),e(function(){mc(i)&&o({inst:i})})},[e]),vb(n),n}function mc(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!db(e,n)}catch{return!0}}function yb(e,t){return t()}var wb=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?yb:gb;Pg.useSyncExternalStore=Vi.useSyncExternalStore!==void 0?Vi.useSyncExternalStore:wb;Ag.exports=Pg;var Sb=Ag.exports,Ig={exports:{}},Mg={};/** + */var Vi=b;function cb(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var fb=typeof Object.is=="function"?Object.is:cb,db=Vi.useState,pb=Vi.useEffect,hb=Vi.useLayoutEffect,mb=Vi.useDebugValue;function vb(e,t){var n=t(),r=db({inst:{value:n,getSnapshot:t}}),i=r[0].inst,o=r[1];return hb(function(){i.value=n,i.getSnapshot=t,hc(i)&&o({inst:i})},[e,n,t]),pb(function(){return hc(i)&&o({inst:i}),e(function(){hc(i)&&o({inst:i})})},[e]),mb(n),n}function hc(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!fb(e,n)}catch{return!0}}function gb(e,t){return t()}var yb=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?gb:vb;Ag.useSyncExternalStore=Vi.useSyncExternalStore!==void 0?Vi.useSyncExternalStore:yb;kg.exports=Ag;var wb=kg.exports,Pg={exports:{}},Ig={};/** * @license React * use-sync-external-store-shim/with-selector.production.min.js * @@ -53,14 +53,14 @@ Error generating stack: `+o.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var Xl=b,bb=Sb;function Eb(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var _b=typeof Object.is=="function"?Object.is:Eb,xb=bb.useSyncExternalStore,Cb=Xl.useRef,Ob=Xl.useEffect,kb=Xl.useMemo,Ab=Xl.useDebugValue;Mg.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var o=Cb(null);if(o.current===null){var a={hasValue:!1,value:null};o.current=a}else a=o.current;o=kb(function(){function l(h){if(!u){if(u=!0,c=h,h=r(h),i!==void 0&&a.hasValue){var y=a.value;if(i(y,h))return f=y}return f=h}if(y=f,_b(c,h))return y;var m=r(h);return i!==void 0&&i(y,m)?y:(c=h,f=m)}var u=!1,c,f,d=n===void 0?null:n;return[function(){return l(t())},d===null?void 0:function(){return l(d())}]},[t,n,r,i]);var s=xb(e,o[0],o[1]);return Ob(function(){a.hasValue=!0,a.value=s},[s]),Ab(s),s};Ig.exports=Mg;var Pb=Ig.exports;function Ib(e){e()}let Lg=Ib;const Mb=e=>Lg=e,Lb=()=>Lg,Em=Symbol.for("react-redux-context"),_m=typeof globalThis<"u"?globalThis:{};function Tb(){var e;if(!b.createContext)return{};const t=(e=_m[Em])!=null?e:_m[Em]=new Map;let n=t.get(b.createContext);return n||(n=b.createContext(null),t.set(b.createContext,n)),n}const Sr=Tb();function _p(e=Sr){return function(){return b.useContext(e)}}const Tg=_p(),Db=()=>{throw new Error("uSES not initialized!")};let Dg=Db;const $b=e=>{Dg=e},jb=(e,t)=>e===t;function Fb(e=Sr){const t=e===Sr?Tg:_p(e);return function(r,i={}){const{equalityFn:o=jb,stabilityCheck:a=void 0,noopCheck:s=void 0}=typeof i=="function"?{equalityFn:i}:i,{store:l,subscription:u,getServerState:c,stabilityCheck:f,noopCheck:d}=t();b.useRef(!0);const h=b.useCallback({[r.name](m){return r(m)}}[r.name],[r,f,a]),y=Dg(u.addNestedSub,l.getState,c||l.getState,h,o);return b.useDebugValue(y),y}}const Rb=Fb();function J(){return J=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[i]=e[i]);return n}var $g={exports:{}},de={};/** @license React v16.13.1 + */var Zl=b,Sb=wb;function bb(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Eb=typeof Object.is=="function"?Object.is:bb,_b=Sb.useSyncExternalStore,xb=Zl.useRef,Cb=Zl.useEffect,Ob=Zl.useMemo,kb=Zl.useDebugValue;Ig.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var o=xb(null);if(o.current===null){var a={hasValue:!1,value:null};o.current=a}else a=o.current;o=Ob(function(){function l(h){if(!u){if(u=!0,c=h,h=r(h),i!==void 0&&a.hasValue){var y=a.value;if(i(y,h))return f=y}return f=h}if(y=f,Eb(c,h))return y;var m=r(h);return i!==void 0&&i(y,m)?y:(c=h,f=m)}var u=!1,c,f,d=n===void 0?null:n;return[function(){return l(t())},d===null?void 0:function(){return l(d())}]},[t,n,r,i]);var s=_b(e,o[0],o[1]);return Cb(function(){a.hasValue=!0,a.value=s},[s]),kb(s),s};Pg.exports=Ig;var Ab=Pg.exports;function Pb(e){e()}let Mg=Pb;const Ib=e=>Mg=e,Mb=()=>Mg,bm=Symbol.for("react-redux-context"),Em=typeof globalThis<"u"?globalThis:{};function Lb(){var e;if(!b.createContext)return{};const t=(e=Em[bm])!=null?e:Em[bm]=new Map;let n=t.get(b.createContext);return n||(n=b.createContext(null),t.set(b.createContext,n)),n}const Sr=Lb();function Ep(e=Sr){return function(){return b.useContext(e)}}const Lg=Ep(),Tb=()=>{throw new Error("uSES not initialized!")};let Tg=Tb;const Db=e=>{Tg=e},$b=(e,t)=>e===t;function jb(e=Sr){const t=e===Sr?Lg:Ep(e);return function(r,i={}){const{equalityFn:o=$b,stabilityCheck:a=void 0,noopCheck:s=void 0}=typeof i=="function"?{equalityFn:i}:i,{store:l,subscription:u,getServerState:c,stabilityCheck:f,noopCheck:d}=t();b.useRef(!0);const h=b.useCallback({[r.name](m){return r(m)}}[r.name],[r,f,a]),y=Tg(u.addNestedSub,l.getState,c||l.getState,h,o);return b.useDebugValue(y),y}}const Fb=jb();function J(){return J=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[i]=e[i]);return n}var Dg={exports:{}},de={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var qe=typeof Symbol=="function"&&Symbol.for,xp=qe?Symbol.for("react.element"):60103,Cp=qe?Symbol.for("react.portal"):60106,eu=qe?Symbol.for("react.fragment"):60107,tu=qe?Symbol.for("react.strict_mode"):60108,nu=qe?Symbol.for("react.profiler"):60114,ru=qe?Symbol.for("react.provider"):60109,iu=qe?Symbol.for("react.context"):60110,Op=qe?Symbol.for("react.async_mode"):60111,ou=qe?Symbol.for("react.concurrent_mode"):60111,au=qe?Symbol.for("react.forward_ref"):60112,su=qe?Symbol.for("react.suspense"):60113,zb=qe?Symbol.for("react.suspense_list"):60120,lu=qe?Symbol.for("react.memo"):60115,uu=qe?Symbol.for("react.lazy"):60116,Vb=qe?Symbol.for("react.block"):60121,Bb=qe?Symbol.for("react.fundamental"):60117,Ub=qe?Symbol.for("react.responder"):60118,Hb=qe?Symbol.for("react.scope"):60119;function $t(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case xp:switch(e=e.type,e){case Op:case ou:case eu:case nu:case tu:case su:return e;default:switch(e=e&&e.$$typeof,e){case iu:case au:case uu:case lu:case ru:return e;default:return t}}case Cp:return t}}}function jg(e){return $t(e)===ou}de.AsyncMode=Op;de.ConcurrentMode=ou;de.ContextConsumer=iu;de.ContextProvider=ru;de.Element=xp;de.ForwardRef=au;de.Fragment=eu;de.Lazy=uu;de.Memo=lu;de.Portal=Cp;de.Profiler=nu;de.StrictMode=tu;de.Suspense=su;de.isAsyncMode=function(e){return jg(e)||$t(e)===Op};de.isConcurrentMode=jg;de.isContextConsumer=function(e){return $t(e)===iu};de.isContextProvider=function(e){return $t(e)===ru};de.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===xp};de.isForwardRef=function(e){return $t(e)===au};de.isFragment=function(e){return $t(e)===eu};de.isLazy=function(e){return $t(e)===uu};de.isMemo=function(e){return $t(e)===lu};de.isPortal=function(e){return $t(e)===Cp};de.isProfiler=function(e){return $t(e)===nu};de.isStrictMode=function(e){return $t(e)===tu};de.isSuspense=function(e){return $t(e)===su};de.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===eu||e===ou||e===nu||e===tu||e===su||e===zb||typeof e=="object"&&e!==null&&(e.$$typeof===uu||e.$$typeof===lu||e.$$typeof===ru||e.$$typeof===iu||e.$$typeof===au||e.$$typeof===Bb||e.$$typeof===Ub||e.$$typeof===Hb||e.$$typeof===Vb)};de.typeOf=$t;$g.exports=de;var Wb=$g.exports,Fg=Wb,qb={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Kb={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Rg={};Rg[Fg.ForwardRef]=qb;Rg[Fg.Memo]=Kb;var pe={};/** + */var qe=typeof Symbol=="function"&&Symbol.for,_p=qe?Symbol.for("react.element"):60103,xp=qe?Symbol.for("react.portal"):60106,Xl=qe?Symbol.for("react.fragment"):60107,eu=qe?Symbol.for("react.strict_mode"):60108,tu=qe?Symbol.for("react.profiler"):60114,nu=qe?Symbol.for("react.provider"):60109,ru=qe?Symbol.for("react.context"):60110,Cp=qe?Symbol.for("react.async_mode"):60111,iu=qe?Symbol.for("react.concurrent_mode"):60111,ou=qe?Symbol.for("react.forward_ref"):60112,au=qe?Symbol.for("react.suspense"):60113,Nb=qe?Symbol.for("react.suspense_list"):60120,su=qe?Symbol.for("react.memo"):60115,lu=qe?Symbol.for("react.lazy"):60116,zb=qe?Symbol.for("react.block"):60121,Vb=qe?Symbol.for("react.fundamental"):60117,Bb=qe?Symbol.for("react.responder"):60118,Ub=qe?Symbol.for("react.scope"):60119;function $t(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case _p:switch(e=e.type,e){case Cp:case iu:case Xl:case tu:case eu:case au:return e;default:switch(e=e&&e.$$typeof,e){case ru:case ou:case lu:case su:case nu:return e;default:return t}}case xp:return t}}}function $g(e){return $t(e)===iu}de.AsyncMode=Cp;de.ConcurrentMode=iu;de.ContextConsumer=ru;de.ContextProvider=nu;de.Element=_p;de.ForwardRef=ou;de.Fragment=Xl;de.Lazy=lu;de.Memo=su;de.Portal=xp;de.Profiler=tu;de.StrictMode=eu;de.Suspense=au;de.isAsyncMode=function(e){return $g(e)||$t(e)===Cp};de.isConcurrentMode=$g;de.isContextConsumer=function(e){return $t(e)===ru};de.isContextProvider=function(e){return $t(e)===nu};de.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===_p};de.isForwardRef=function(e){return $t(e)===ou};de.isFragment=function(e){return $t(e)===Xl};de.isLazy=function(e){return $t(e)===lu};de.isMemo=function(e){return $t(e)===su};de.isPortal=function(e){return $t(e)===xp};de.isProfiler=function(e){return $t(e)===tu};de.isStrictMode=function(e){return $t(e)===eu};de.isSuspense=function(e){return $t(e)===au};de.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===Xl||e===iu||e===tu||e===eu||e===au||e===Nb||typeof e=="object"&&e!==null&&(e.$$typeof===lu||e.$$typeof===su||e.$$typeof===nu||e.$$typeof===ru||e.$$typeof===ou||e.$$typeof===Vb||e.$$typeof===Bb||e.$$typeof===Ub||e.$$typeof===zb)};de.typeOf=$t;Dg.exports=de;var Hb=Dg.exports,jg=Hb,Wb={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},qb={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Fg={};Fg[jg.ForwardRef]=Wb;Fg[jg.Memo]=qb;var pe={};/** * @license React * react-is.production.min.js * @@ -68,12 +68,12 @@ Error generating stack: `+o.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var kp=Symbol.for("react.element"),Ap=Symbol.for("react.portal"),cu=Symbol.for("react.fragment"),fu=Symbol.for("react.strict_mode"),du=Symbol.for("react.profiler"),pu=Symbol.for("react.provider"),hu=Symbol.for("react.context"),Gb=Symbol.for("react.server_context"),mu=Symbol.for("react.forward_ref"),vu=Symbol.for("react.suspense"),gu=Symbol.for("react.suspense_list"),yu=Symbol.for("react.memo"),wu=Symbol.for("react.lazy"),Qb=Symbol.for("react.offscreen"),Ng;Ng=Symbol.for("react.module.reference");function Qt(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case kp:switch(e=e.type,e){case cu:case du:case fu:case vu:case gu:return e;default:switch(e=e&&e.$$typeof,e){case Gb:case hu:case mu:case wu:case yu:case pu:return e;default:return t}}case Ap:return t}}}pe.ContextConsumer=hu;pe.ContextProvider=pu;pe.Element=kp;pe.ForwardRef=mu;pe.Fragment=cu;pe.Lazy=wu;pe.Memo=yu;pe.Portal=Ap;pe.Profiler=du;pe.StrictMode=fu;pe.Suspense=vu;pe.SuspenseList=gu;pe.isAsyncMode=function(){return!1};pe.isConcurrentMode=function(){return!1};pe.isContextConsumer=function(e){return Qt(e)===hu};pe.isContextProvider=function(e){return Qt(e)===pu};pe.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===kp};pe.isForwardRef=function(e){return Qt(e)===mu};pe.isFragment=function(e){return Qt(e)===cu};pe.isLazy=function(e){return Qt(e)===wu};pe.isMemo=function(e){return Qt(e)===yu};pe.isPortal=function(e){return Qt(e)===Ap};pe.isProfiler=function(e){return Qt(e)===du};pe.isStrictMode=function(e){return Qt(e)===fu};pe.isSuspense=function(e){return Qt(e)===vu};pe.isSuspenseList=function(e){return Qt(e)===gu};pe.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===cu||e===du||e===fu||e===vu||e===gu||e===Qb||typeof e=="object"&&e!==null&&(e.$$typeof===wu||e.$$typeof===yu||e.$$typeof===pu||e.$$typeof===hu||e.$$typeof===mu||e.$$typeof===Ng||e.getModuleId!==void 0)};pe.typeOf=Qt;function Yb(){const e=Lb();let t=null,n=null;return{clear(){t=null,n=null},notify(){e(()=>{let r=t;for(;r;)r.callback(),r=r.next})},get(){let r=[],i=t;for(;i;)r.push(i),i=i.next;return r},subscribe(r){let i=!0,o=n={callback:r,next:null,prev:n};return o.prev?o.prev.next=o:t=o,function(){!i||t===null||(i=!1,o.next?o.next.prev=o.prev:n=o.prev,o.prev?o.prev.next=o.next:t=o.next)}}}}const xm={notify(){},get:()=>[]};function Jb(e,t){let n,r=xm;function i(f){return l(),r.subscribe(f)}function o(){r.notify()}function a(){c.onStateChange&&c.onStateChange()}function s(){return!!n}function l(){n||(n=t?t.addNestedSub(a):e.subscribe(a),r=Yb())}function u(){n&&(n(),n=void 0,r.clear(),r=xm)}const c={addNestedSub:i,notifyNestedSubs:o,handleChangeWrapper:a,isSubscribed:s,trySubscribe:l,tryUnsubscribe:u,getListeners:()=>r};return c}const Zb=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Xb=Zb?b.useLayoutEffect:b.useEffect;function eE({store:e,context:t,children:n,serverState:r,stabilityCheck:i="once",noopCheck:o="once"}){const a=b.useMemo(()=>{const u=Jb(e);return{store:e,subscription:u,getServerState:r?()=>r:void 0,stabilityCheck:i,noopCheck:o}},[e,r,i,o]),s=b.useMemo(()=>e.getState(),[e]);Xb(()=>{const{subscription:u}=a;return u.onStateChange=u.notifyNestedSubs,u.trySubscribe(),s!==e.getState()&&u.notifyNestedSubs(),()=>{u.tryUnsubscribe(),u.onStateChange=void 0}},[a,s]);const l=t||Sr;return b.createElement(l.Provider,{value:a},n)}function zg(e=Sr){const t=e===Sr?Tg:_p(e);return function(){const{store:r}=t();return r}}const tE=zg();function nE(e=Sr){const t=e===Sr?tE:zg(e);return function(){return t().dispatch}}const rE=nE();$b(Pb.useSyncExternalStoreWithSelector);Mb(Ep.unstable_batchedUpdates);var Vg={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},Cm=ne.createContext&&ne.createContext(Vg),hr=globalThis&&globalThis.__assign||function(){return hr=Object.assign||function(e){for(var t,n=1,r=arguments.length;ntypeof e=="number"&&!isNaN(e),Hr=e=>typeof e=="string",gt=e=>typeof e=="function",Os=e=>Hr(e)||gt(e)?e:null,vc=e=>b.isValidElement(e)||Hr(e)||gt(e)||Do(e);function uE(e,t,n){n===void 0&&(n=300);const{scrollHeight:r,style:i}=e;requestAnimationFrame(()=>{i.minHeight="initial",i.height=r+"px",i.transition=`all ${n}ms`,requestAnimationFrame(()=>{i.height="0",i.padding="0",i.margin="0",setTimeout(t,n)})})}function Su(e){let{enter:t,exit:n,appendPosition:r=!1,collapse:i=!0,collapseDuration:o=300}=e;return function(a){let{children:s,position:l,preventExitTransition:u,done:c,nodeRef:f,isIn:d}=a;const h=r?`${t}--${l}`:t,y=r?`${n}--${l}`:n,m=b.useRef(0);return b.useLayoutEffect(()=>{const w=f.current,p=h.split(" "),v=g=>{g.target===f.current&&(w.dispatchEvent(new Event("d")),w.removeEventListener("animationend",v),w.removeEventListener("animationcancel",v),m.current===0&&g.type!=="animationcancel"&&w.classList.remove(...p))};w.classList.add(...p),w.addEventListener("animationend",v),w.addEventListener("animationcancel",v)},[]),b.useEffect(()=>{const w=f.current,p=()=>{w.removeEventListener("animationend",p),i?uE(w,c,o):c()};d||(u?p():(m.current=1,w.className+=` ${y}`,w.addEventListener("animationend",p)))},[d]),ne.createElement(ne.Fragment,null,s)}}function Om(e,t){return e!=null?{content:e.content,containerId:e.props.containerId,id:e.props.toastId,theme:e.props.theme,type:e.props.type,data:e.props.data||{},isLoading:e.props.isLoading,icon:e.props.icon,status:t}:{}}const Vt={list:new Map,emitQueue:new Map,on(e,t){return this.list.has(e)||this.list.set(e,[]),this.list.get(e).push(t),this},off(e,t){if(t){const n=this.list.get(e).filter(r=>r!==t);return this.list.set(e,n),this}return this.list.delete(e),this},cancelEmit(e){const t=this.emitQueue.get(e);return t&&(t.forEach(clearTimeout),this.emitQueue.delete(e)),this},emit(e){this.list.has(e)&&this.list.get(e).forEach(t=>{const n=setTimeout(()=>{t(...[].slice.call(arguments,1))},0);this.emitQueue.has(e)||this.emitQueue.set(e,[]),this.emitQueue.get(e).push(n)})}},Za=e=>{let{theme:t,type:n,...r}=e;return ne.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:t==="colored"?"currentColor":`var(--toastify-icon-color-${n})`,...r})},gc={info:function(e){return ne.createElement(Za,{...e},ne.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(e){return ne.createElement(Za,{...e},ne.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(e){return ne.createElement(Za,{...e},ne.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(e){return ne.createElement(Za,{...e},ne.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return ne.createElement("div",{className:"Toastify__spinner"})}};function cE(e){const[,t]=b.useReducer(h=>h+1,0),[n,r]=b.useState([]),i=b.useRef(null),o=b.useRef(new Map).current,a=h=>n.indexOf(h)!==-1,s=b.useRef({toastKey:1,displayedToast:0,count:0,queue:[],props:e,containerId:null,isToastActive:a,getToast:h=>o.get(h)}).current;function l(h){let{containerId:y}=h;const{limit:m}=s.props;!m||y&&s.containerId!==y||(s.count-=s.queue.length,s.queue=[])}function u(h){r(y=>h==null?[]:y.filter(m=>m!==h))}function c(){const{toastContent:h,toastProps:y,staleId:m}=s.queue.shift();d(h,y,m)}function f(h,y){let{delay:m,staleId:w,...p}=y;if(!vc(h)||function(j){return!i.current||s.props.enableMultiContainer&&j.containerId!==s.props.containerId||o.has(j.toastId)&&j.updateId==null}(p))return;const{toastId:v,updateId:g,data:S}=p,{props:_}=s,x=()=>u(v),E=g==null;E&&s.count++;const C={..._,style:_.toastStyle,key:s.toastKey++,...Object.fromEntries(Object.entries(p).filter(j=>{let[U,z]=j;return z!=null})),toastId:v,updateId:g,data:S,closeToast:x,isIn:!1,className:Os(p.className||_.toastClassName),bodyClassName:Os(p.bodyClassName||_.bodyClassName),progressClassName:Os(p.progressClassName||_.progressClassName),autoClose:!p.isLoading&&(k=p.autoClose,P=_.autoClose,k===!1||Do(k)&&k>0?k:P),deleteToast(){const j=Om(o.get(v),"removed");o.delete(v),Vt.emit(4,j);const U=s.queue.length;if(s.count=v==null?s.count-s.displayedToast:s.count-1,s.count<0&&(s.count=0),U>0){const z=v==null?s.props.limit:1;if(U===1||z===1)s.displayedToast++,c();else{const L=z>U?U:z;s.displayedToast=L;for(let M=0;MI in gc)(z)&&(D=gc[z](A))),D}(C),gt(p.onOpen)&&(C.onOpen=p.onOpen),gt(p.onClose)&&(C.onClose=p.onClose),C.closeButton=_.closeButton,p.closeButton===!1||vc(p.closeButton)?C.closeButton=p.closeButton:p.closeButton===!0&&(C.closeButton=!vc(_.closeButton)||_.closeButton);let $=h;b.isValidElement(h)&&!Hr(h.type)?$=b.cloneElement(h,{closeToast:x,toastProps:C,data:S}):gt(h)&&($=h({closeToast:x,toastProps:C,data:S})),_.limit&&_.limit>0&&s.count>_.limit&&E?s.queue.push({toastContent:$,toastProps:C,staleId:w}):Do(m)?setTimeout(()=>{d($,C,w)},m):d($,C,w)}function d(h,y,m){const{toastId:w}=y;m&&o.delete(m);const p={content:h,props:y};o.set(w,p),r(v=>[...v,w].filter(g=>g!==m)),Vt.emit(4,Om(p,p.props.updateId==null?"added":"updated"))}return b.useEffect(()=>(s.containerId=e.containerId,Vt.cancelEmit(3).on(0,f).on(1,h=>i.current&&u(h)).on(5,l).emit(2,s),()=>{o.clear(),Vt.emit(3,s)}),[]),b.useEffect(()=>{s.props=e,s.isToastActive=a,s.displayedToast=n.length}),{getToastToRender:function(h){const y=new Map,m=Array.from(o.values());return e.newestOnTop&&m.reverse(),m.forEach(w=>{const{position:p}=w.props;y.has(p)||y.set(p,[]),y.get(p).push(w)}),Array.from(y,w=>h(w[0],w[1]))},containerRef:i,isToastActive:a}}function km(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientX:e.clientX}function Am(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientY:e.clientY}function fE(e){const[t,n]=b.useState(!1),[r,i]=b.useState(!1),o=b.useRef(null),a=b.useRef({start:0,x:0,y:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,boundingRect:null,didMove:!1}).current,s=b.useRef(e),{autoClose:l,pauseOnHover:u,closeToast:c,onClick:f,closeOnClick:d}=e;function h(S){if(e.draggable){S.nativeEvent.type==="touchstart"&&S.nativeEvent.preventDefault(),a.didMove=!1,document.addEventListener("mousemove",p),document.addEventListener("mouseup",v),document.addEventListener("touchmove",p),document.addEventListener("touchend",v);const _=o.current;a.canCloseOnClick=!0,a.canDrag=!0,a.boundingRect=_.getBoundingClientRect(),_.style.transition="",a.x=km(S.nativeEvent),a.y=Am(S.nativeEvent),e.draggableDirection==="x"?(a.start=a.x,a.removalDistance=_.offsetWidth*(e.draggablePercent/100)):(a.start=a.y,a.removalDistance=_.offsetHeight*(e.draggablePercent===80?1.5*e.draggablePercent:e.draggablePercent/100))}}function y(S){if(a.boundingRect){const{top:_,bottom:x,left:E,right:C}=a.boundingRect;S.nativeEvent.type!=="touchend"&&e.pauseOnHover&&a.x>=E&&a.x<=C&&a.y>=_&&a.y<=x?w():m()}}function m(){n(!0)}function w(){n(!1)}function p(S){const _=o.current;a.canDrag&&_&&(a.didMove=!0,t&&w(),a.x=km(S),a.y=Am(S),a.delta=e.draggableDirection==="x"?a.x-a.start:a.y-a.start,a.start!==a.x&&(a.canCloseOnClick=!1),_.style.transform=`translate${e.draggableDirection}(${a.delta}px)`,_.style.opacity=""+(1-Math.abs(a.delta/a.removalDistance)))}function v(){document.removeEventListener("mousemove",p),document.removeEventListener("mouseup",v),document.removeEventListener("touchmove",p),document.removeEventListener("touchend",v);const S=o.current;if(a.canDrag&&a.didMove&&S){if(a.canDrag=!1,Math.abs(a.delta)>a.removalDistance)return i(!0),void e.closeToast();S.style.transition="transform 0.2s, opacity 0.2s",S.style.transform=`translate${e.draggableDirection}(0)`,S.style.opacity="1"}}b.useEffect(()=>{s.current=e}),b.useEffect(()=>(o.current&&o.current.addEventListener("d",m,{once:!0}),gt(e.onOpen)&&e.onOpen(b.isValidElement(e.children)&&e.children.props),()=>{const S=s.current;gt(S.onClose)&&S.onClose(b.isValidElement(S.children)&&S.children.props)}),[]),b.useEffect(()=>(e.pauseOnFocusLoss&&(document.hasFocus()||w(),window.addEventListener("focus",m),window.addEventListener("blur",w)),()=>{e.pauseOnFocusLoss&&(window.removeEventListener("focus",m),window.removeEventListener("blur",w))}),[e.pauseOnFocusLoss]);const g={onMouseDown:h,onTouchStart:h,onMouseUp:y,onTouchEnd:y};return l&&u&&(g.onMouseEnter=w,g.onMouseLeave=m),d&&(g.onClick=S=>{f&&f(S),a.canCloseOnClick&&c()}),{playToast:m,pauseToast:w,isRunning:t,preventExitTransition:r,toastRef:o,eventHandlers:g}}function Hg(e){let{closeToast:t,theme:n,ariaLabel:r="close"}=e;return ne.createElement("button",{className:`Toastify__close-button Toastify__close-button--${n}`,type:"button",onClick:i=>{i.stopPropagation(),t(i)},"aria-label":r},ne.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},ne.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function dE(e){let{delay:t,isRunning:n,closeToast:r,type:i="default",hide:o,className:a,style:s,controlledProgress:l,progress:u,rtl:c,isIn:f,theme:d}=e;const h=o||l&&u===0,y={...s,animationDuration:`${t}ms`,animationPlayState:n?"running":"paused",opacity:h?0:1};l&&(y.transform=`scaleX(${u})`);const m=or("Toastify__progress-bar",l?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${d}`,`Toastify__progress-bar--${i}`,{"Toastify__progress-bar--rtl":c}),w=gt(a)?a({rtl:c,type:i,defaultClassName:m}):or(m,a);return ne.createElement("div",{role:"progressbar","aria-hidden":h?"true":"false","aria-label":"notification timer",className:w,style:y,[l&&u>=1?"onTransitionEnd":"onAnimationEnd"]:l&&u<1?null:()=>{f&&r()}})}const pE=e=>{const{isRunning:t,preventExitTransition:n,toastRef:r,eventHandlers:i}=fE(e),{closeButton:o,children:a,autoClose:s,onClick:l,type:u,hideProgressBar:c,closeToast:f,transition:d,position:h,className:y,style:m,bodyClassName:w,bodyStyle:p,progressClassName:v,progressStyle:g,updateId:S,role:_,progress:x,rtl:E,toastId:C,deleteToast:k,isIn:P,isLoading:$,iconOut:j,closeOnClick:U,theme:z}=e,L=or("Toastify__toast",`Toastify__toast-theme--${z}`,`Toastify__toast--${u}`,{"Toastify__toast--rtl":E},{"Toastify__toast--close-on-click":U}),M=gt(y)?y({rtl:E,position:h,type:u,defaultClassName:L}):or(L,y),D=!!x||!s,A={closeToast:f,type:u,theme:z};let I=null;return o===!1||(I=gt(o)?o(A):b.isValidElement(o)?b.cloneElement(o,A):Hg(A)),ne.createElement(d,{isIn:P,done:k,position:h,preventExitTransition:n,nodeRef:r},ne.createElement("div",{id:C,onClick:l,className:M,...i,style:m,ref:r},ne.createElement("div",{...P&&{role:_},className:gt(w)?w({type:u}):or("Toastify__toast-body",w),style:p},j!=null&&ne.createElement("div",{className:or("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!$})},j),ne.createElement("div",null,a)),I,ne.createElement(dE,{...S&&!D?{key:`pb-${S}`}:{},rtl:E,theme:z,delay:s,isRunning:t,isIn:P,closeToast:f,hide:c,type:u,style:g,className:v,controlledProgress:D,progress:x||0})))},bu=function(e,t){return t===void 0&&(t=!1),{enter:`Toastify--animate Toastify__${e}-enter`,exit:`Toastify--animate Toastify__${e}-exit`,appendPosition:t}},hE=Su(bu("bounce",!0));Su(bu("slide",!0));Su(bu("zoom"));Su(bu("flip"));const zf=b.forwardRef((e,t)=>{const{getToastToRender:n,containerRef:r,isToastActive:i}=cE(e),{className:o,style:a,rtl:s,containerId:l}=e;function u(c){const f=or("Toastify__toast-container",`Toastify__toast-container--${c}`,{"Toastify__toast-container--rtl":s});return gt(o)?o({position:c,rtl:s,defaultClassName:f}):or(f,Os(o))}return b.useEffect(()=>{t&&(t.current=r.current)},[]),ne.createElement("div",{ref:r,className:"Toastify",id:l},n((c,f)=>{const d=f.length?{...a}:{...a,pointerEvents:"none"};return ne.createElement("div",{className:u(c),style:d,key:`container-${c}`},f.map((h,y)=>{let{content:m,props:w}=h;return ne.createElement(pE,{...w,isIn:i(w.toastId),style:{...w.style,"--nth":y+1,"--len":f.length},key:`toast-${w.key}`},m)}))}))});zf.displayName="ToastContainer",zf.defaultProps={position:"top-right",transition:hE,autoClose:5e3,closeButton:Hg,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,draggable:!0,draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};let yc,Pr=new Map,wo=[],mE=1;function Wg(){return""+mE++}function vE(e){return e&&(Hr(e.toastId)||Do(e.toastId))?e.toastId:Wg()}function $o(e,t){return Pr.size>0?Vt.emit(0,e,t):wo.push({content:e,options:t}),t.toastId}function ul(e,t){return{...t,type:t&&t.type||e,toastId:vE(t)}}function Xa(e){return(t,n)=>$o(t,ul(e,n))}function me(e,t){return $o(e,ul("default",t))}me.loading=(e,t)=>$o(e,ul("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...t})),me.promise=function(e,t,n){let r,{pending:i,error:o,success:a}=t;i&&(r=Hr(i)?me.loading(i,n):me.loading(i.render,{...n,...i}));const s={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},l=(c,f,d)=>{if(f==null)return void me.dismiss(r);const h={type:c,...s,...n,data:d},y=Hr(f)?{render:f}:f;return r?me.update(r,{...h,...y}):me(y.render,{...h,...y}),d},u=gt(e)?e():e;return u.then(c=>l("success",a,c)).catch(c=>l("error",o,c)),u},me.success=Xa("success"),me.info=Xa("info"),me.error=Xa("error"),me.warning=Xa("warning"),me.warn=me.warning,me.dark=(e,t)=>$o(e,ul("default",{theme:"dark",...t})),me.dismiss=e=>{Pr.size>0?Vt.emit(1,e):wo=wo.filter(t=>e!=null&&t.options.toastId!==e)},me.clearWaitingQueue=function(e){return e===void 0&&(e={}),Vt.emit(5,e)},me.isActive=e=>{let t=!1;return Pr.forEach(n=>{n.isToastActive&&n.isToastActive(e)&&(t=!0)}),t},me.update=function(e,t){t===void 0&&(t={}),setTimeout(()=>{const n=function(r,i){let{containerId:o}=i;const a=Pr.get(o||yc);return a&&a.getToast(r)}(e,t);if(n){const{props:r,content:i}=n,o={delay:100,...r,...t,toastId:t.toastId||e,updateId:Wg()};o.toastId!==e&&(o.staleId=e);const a=o.render||i;delete o.render,$o(a,o)}},0)},me.done=e=>{me.update(e,{progress:1})},me.onChange=e=>(Vt.on(4,e),()=>{Vt.off(4,e)}),me.POSITION={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},me.TYPE={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"},Vt.on(2,e=>{yc=e.containerId||e,Pr.set(yc,e),wo.forEach(t=>{Vt.emit(0,t.content,t.options)}),wo=[]}).on(3,e=>{Pr.delete(e.containerId||e),Pr.size===0&&Vt.off(0).off(1).off(5)});var qg={exports:{}},gE="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",yE=gE,wE=yE;function Kg(){}function Gg(){}Gg.resetWarningCache=Kg;var SE=function(){function e(r,i,o,a,s,l){if(l!==wE){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:Gg,resetWarningCache:Kg};return n.PropTypes=n,n};qg.exports=SE();var bE=qg.exports;const he=h0(bE);function Qi(e,t,n,r){function i(o){return o instanceof n?o:new n(function(a){a(o)})}return new(n||(n=Promise))(function(o,a){function s(c){try{u(r.next(c))}catch(f){a(f)}}function l(c){try{u(r.throw(c))}catch(f){a(f)}}function u(c){c.done?o(c.value):i(c.value).then(s,l)}u((r=r.apply(e,t||[])).next())})}function Yi(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(u){return function(c){return l([u,c])}}function l(u){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,u[0]&&(n=0)),n;)try{if(r=1,i&&(o=u[0]&2?i.return:u[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,u[1])).done)return o;switch(i=0,o&&(u=[u[0]&2,o.value]),u[0]){case 0:case 1:o=u;break;case 4:return n.label++,{value:u[1],done:!1};case 5:n.label++,i=u[1],u=[0];continue;case 7:u=n.ops.pop(),n.trys.pop();continue;default:if(o=n.trys,!(o=o.length>0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]0)&&!(i=r.next()).done;)o.push(i.value)}catch(s){a={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o}function Im(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r0?r:e.name,writable:!1,configurable:!1,enumerable:!0})}return n}function _E(e){var t=e.name,n=t&&t.lastIndexOf(".")!==-1;if(n&&!e.type){var r=t.split(".").pop().toLowerCase(),i=EE.get(r);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}var xE=[".DS_Store","Thumbs.db"];function CE(e){return Qi(this,void 0,void 0,function(){return Yi(this,function(t){return cl(e)&&OE(e.dataTransfer)?[2,IE(e.dataTransfer,e.type)]:kE(e)?[2,AE(e)]:Array.isArray(e)&&e.every(function(n){return"getFile"in n&&typeof n.getFile=="function"})?[2,PE(e)]:[2,[]]})})}function OE(e){return cl(e)}function kE(e){return cl(e)&&cl(e.target)}function cl(e){return typeof e=="object"&&e!==null}function AE(e){return Vf(e.target.files).map(function(t){return wa(t)})}function PE(e){return Qi(this,void 0,void 0,function(){var t;return Yi(this,function(n){switch(n.label){case 0:return[4,Promise.all(e.map(function(r){return r.getFile()}))];case 1:return t=n.sent(),[2,t.map(function(r){return wa(r)})]}})})}function IE(e,t){return Qi(this,void 0,void 0,function(){var n,r;return Yi(this,function(i){switch(i.label){case 0:return e.items?(n=Vf(e.items).filter(function(o){return o.kind==="file"}),t!=="drop"?[2,n]:[4,Promise.all(n.map(ME))]):[3,2];case 1:return r=i.sent(),[2,Mm(Qg(r))];case 2:return[2,Mm(Vf(e.files).map(function(o){return wa(o)}))]}})})}function Mm(e){return e.filter(function(t){return xE.indexOf(t.name)===-1})}function Vf(e){if(e===null)return[];for(var t=[],n=0;ne.length)&&(t=e.length);for(var n=0,r=new Array(t);nn)return[!1,jm(n)];if(e.sizen)return[!1,jm(n)]}return[!0,null]}function Mr(e){return e!=null}function UE(e){var t=e.files,n=e.accept,r=e.minSize,i=e.maxSize,o=e.multiple,a=e.maxFiles,s=e.validator;return!o&&t.length>1||o&&a>=1&&t.length>a?!1:t.every(function(l){var u=ry(l,n),c=ra(u,1),f=c[0],d=iy(l,r,i),h=ra(d,1),y=h[0],m=s?s(l):null;return f&&y&&!m})}function fl(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function es(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(t){return t==="Files"||t==="application/x-moz-file"}):!!e.target&&!!e.target.files}function Rm(e){e.preventDefault()}function HE(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function WE(e){return e.indexOf("Edge/")!==-1}function qE(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return HE(e)||WE(e)}function gn(){for(var e=arguments.length,t=new Array(e),n=0;n1?i-1:0),a=1;ae.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function u_(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Eu=b.forwardRef(function(e,t){var n=e.children,r=dl(e,ZE),i=f_(r),o=i.open,a=dl(i,XE);return b.useImperativeHandle(t,function(){return{open:o}},[o]),ne.createElement(b.Fragment,null,n(Oe(Oe({},a),{},{open:o})))});Eu.displayName="Dropzone";var ly={disabled:!1,getFilesFromEvent:CE,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!0,autoFocus:!1};Eu.defaultProps=ly;Eu.propTypes={children:he.func,accept:he.objectOf(he.arrayOf(he.string)),multiple:he.bool,preventDropOnDocument:he.bool,noClick:he.bool,noKeyboard:he.bool,noDrag:he.bool,noDragEventsBubbling:he.bool,minSize:he.number,maxSize:he.number,maxFiles:he.number,disabled:he.bool,getFilesFromEvent:he.func,onFileDialogCancel:he.func,onFileDialogOpen:he.func,useFsAccessApi:he.bool,autoFocus:he.bool,onDragEnter:he.func,onDragLeave:he.func,onDragOver:he.func,onDrop:he.func,onDropAccepted:he.func,onDropRejected:he.func,onError:he.func,validator:he.func};const c_=Eu;var Wf={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function f_(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=Oe(Oe({},ly),e),n=t.accept,r=t.disabled,i=t.getFilesFromEvent,o=t.maxSize,a=t.minSize,s=t.multiple,l=t.maxFiles,u=t.onDragEnter,c=t.onDragLeave,f=t.onDragOver,d=t.onDrop,h=t.onDropAccepted,y=t.onDropRejected,m=t.onFileDialogCancel,w=t.onFileDialogOpen,p=t.useFsAccessApi,v=t.autoFocus,g=t.preventDropOnDocument,S=t.noClick,_=t.noKeyboard,x=t.noDrag,E=t.noDragEventsBubbling,C=t.onError,k=t.validator,P=b.useMemo(function(){return QE(n)},[n]),$=b.useMemo(function(){return GE(n)},[n]),j=b.useMemo(function(){return typeof w=="function"?w:zm},[w]),U=b.useMemo(function(){return typeof m=="function"?m:zm},[m]),z=b.useRef(null),L=b.useRef(null),M=b.useReducer(d_,Wf),D=Sc(M,2),A=D[0],I=D[1],F=A.isFocused,R=A.isFileDialogActive,V=b.useRef(typeof window<"u"&&window.isSecureContext&&p&&KE()),T=function(){!V.current&&R&&setTimeout(function(){if(L.current){var Z=L.current.files;Z.length||(I({type:"closeDialog"}),U())}},300)};b.useEffect(function(){return window.addEventListener("focus",T,!1),function(){window.removeEventListener("focus",T,!1)}},[L,R,U,V]);var N=b.useRef([]),H=function(Z){z.current&&z.current.contains(Z.target)||(Z.preventDefault(),N.current=[])};b.useEffect(function(){return g&&(document.addEventListener("dragover",Rm,!1),document.addEventListener("drop",H,!1)),function(){g&&(document.removeEventListener("dragover",Rm),document.removeEventListener("drop",H))}},[z,g]),b.useEffect(function(){return!r&&v&&z.current&&z.current.focus(),function(){}},[z,v,r]);var W=b.useCallback(function(q){C?C(q):console.error(q)},[C]),X=b.useCallback(function(q){q.preventDefault(),q.persist(),Ta(q),N.current=[].concat(n_(N.current),[q.target]),es(q)&&Promise.resolve(i(q)).then(function(Z){if(!(fl(q)&&!E)){var je=Z.length,Ke=je>0&&UE({files:Z,accept:P,minSize:a,maxSize:o,multiple:s,maxFiles:l,validator:k}),xt=je>0&&!Ke;I({isDragAccept:Ke,isDragReject:xt,isDragActive:!0,type:"setDraggedFiles"}),u&&u(q)}}).catch(function(Z){return W(Z)})},[i,u,W,E,P,a,o,s,l,k]),oe=b.useCallback(function(q){q.preventDefault(),q.persist(),Ta(q);var Z=es(q);if(Z&&q.dataTransfer)try{q.dataTransfer.dropEffect="copy"}catch{}return Z&&f&&f(q),!1},[f,E]),Ie=b.useCallback(function(q){q.preventDefault(),q.persist(),Ta(q);var Z=N.current.filter(function(Ke){return z.current&&z.current.contains(Ke)}),je=Z.indexOf(q.target);je!==-1&&Z.splice(je,1),N.current=Z,!(Z.length>0)&&(I({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),es(q)&&c&&c(q))},[z,c,E]),xe=b.useCallback(function(q,Z){var je=[],Ke=[];q.forEach(function(xt){var ro=ry(xt,P),ni=Sc(ro,2),ju=ni[0],Fu=ni[1],Ru=iy(xt,a,o),Da=Sc(Ru,2),Nu=Da[0],zu=Da[1],Vu=k?k(xt):null;if(ju&&Nu&&!Vu)je.push(xt);else{var Bu=[Fu,zu];Vu&&(Bu=Bu.concat(Vu)),Ke.push({file:xt,errors:Bu.filter(function(Fw){return Fw})})}}),(!s&&je.length>1||s&&l>=1&&je.length>l)&&(je.forEach(function(xt){Ke.push({file:xt,errors:[BE]})}),je.splice(0)),I({acceptedFiles:je,fileRejections:Ke,type:"setFiles"}),d&&d(je,Ke,Z),Ke.length>0&&y&&y(Ke,Z),je.length>0&&h&&h(je,Z)},[I,s,P,a,o,l,d,h,y,k]),be=b.useCallback(function(q){q.preventDefault(),q.persist(),Ta(q),N.current=[],es(q)&&Promise.resolve(i(q)).then(function(Z){fl(q)&&!E||xe(Z,q)}).catch(function(Z){return W(Z)}),I({type:"reset"})},[i,xe,W,E]),Ce=b.useCallback(function(){if(V.current){I({type:"openDialog"}),j();var q={multiple:s,types:$};window.showOpenFilePicker(q).then(function(Z){return i(Z)}).then(function(Z){xe(Z,null),I({type:"closeDialog"})}).catch(function(Z){YE(Z)?(U(Z),I({type:"closeDialog"})):JE(Z)?(V.current=!1,L.current?(L.current.value=null,L.current.click()):W(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no was provided."))):W(Z)});return}L.current&&(I({type:"openDialog"}),j(),L.current.value=null,L.current.click())},[I,j,U,p,xe,W,$,s]),Zt=b.useCallback(function(q){!z.current||!z.current.isEqualNode(q.target)||(q.key===" "||q.key==="Enter"||q.keyCode===32||q.keyCode===13)&&(q.preventDefault(),Ce())},[z,Ce]),_t=b.useCallback(function(){I({type:"focus"})},[]),Ma=b.useCallback(function(){I({type:"blur"})},[]),dh=b.useCallback(function(){S||(qE()?setTimeout(Ce,0):Ce())},[S,Ce]),ti=function(Z){return r?null:Z},$u=function(Z){return _?null:ti(Z)},La=function(Z){return x?null:ti(Z)},Ta=function(Z){E&&Z.stopPropagation()},Dw=b.useMemo(function(){return function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=q.refKey,je=Z===void 0?"ref":Z,Ke=q.role,xt=q.onKeyDown,ro=q.onFocus,ni=q.onBlur,ju=q.onClick,Fu=q.onDragEnter,Ru=q.onDragOver,Da=q.onDragLeave,Nu=q.onDrop,zu=dl(q,e_);return Oe(Oe(Hf({onKeyDown:$u(gn(xt,Zt)),onFocus:$u(gn(ro,_t)),onBlur:$u(gn(ni,Ma)),onClick:ti(gn(ju,dh)),onDragEnter:La(gn(Fu,X)),onDragOver:La(gn(Ru,oe)),onDragLeave:La(gn(Da,Ie)),onDrop:La(gn(Nu,be)),role:typeof Ke=="string"&&Ke!==""?Ke:"presentation"},je,z),!r&&!_?{tabIndex:0}:{}),zu)}},[z,Zt,_t,Ma,dh,X,oe,Ie,be,_,x,r]),$w=b.useCallback(function(q){q.stopPropagation()},[]),jw=b.useMemo(function(){return function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=q.refKey,je=Z===void 0?"ref":Z,Ke=q.onChange,xt=q.onClick,ro=dl(q,t_),ni=Hf({accept:P,multiple:s,type:"file",style:{display:"none"},onChange:ti(gn(Ke,be)),onClick:ti(gn(xt,$w)),tabIndex:-1},je,L);return Oe(Oe({},ni),ro)}},[L,n,s,be,r]);return Oe(Oe({},A),{},{isFocused:F&&!r,getRootProps:Dw,getInputProps:jw,rootRef:z,inputRef:L,open:ti(Ce)})}function d_(e,t){switch(t.type){case"focus":return Oe(Oe({},e),{},{isFocused:!0});case"blur":return Oe(Oe({},e),{},{isFocused:!1});case"openDialog":return Oe(Oe({},Wf),{},{isFileDialogActive:!0});case"closeDialog":return Oe(Oe({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return Oe(Oe({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return Oe(Oe({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections});case"reset":return Oe({},Wf);default:return e}}function zm(){}const ia=({accept:e,children:t,multiple:n,noClick:r,onDrop:i})=>{const o=b.useCallback(s=>{for(const l of s)me(`${l.errors[0].message}, ${l.file.name}`,{type:"error"})},[]),a=b.useCallback(s=>{const l=typeof s.name=="string"?s.name:"";return e==="lottie"&&!l.endsWith(".lottie")?{message:"Invalid .lottie",code:wc.FileInvalidType}:e==="json"&&s.type!=="application/json"?{message:"Invalid .json",code:wc.FileInvalidType}:e==="lss"&&!l.endsWith(".lss")?{message:"Invalid .lss",code:wc.FileInvalidType}:null},[]);return O.jsx(c_,{noClick:r,maxFiles:n?10:1,validator:a,multiple:n,onDrop:i,onDropRejected:o,children:t})};function p_(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Vm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Bm(e){for(var t=1;t=0)&&(n[i]=e[i]);return n}function m_(e,t){if(e==null)return{};var n=h_(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function v_(e,t){return g_(e)||y_(e,t)||w_(e,t)||S_()}function g_(e){if(Array.isArray(e))return e}function y_(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,i=!1,o=void 0;try{for(var a=e[Symbol.iterator](),s;!(r=(s=a.next()).done)&&(n.push(s.value),!(t&&n.length===t));r=!0);}catch(l){i=!0,o=l}finally{try{!r&&a.return!=null&&a.return()}finally{if(i)throw o}}return n}}function w_(e,t){if(e){if(typeof e=="string")return Um(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Um(e,t)}}function Um(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=e.length?e.apply(this,i):function(){for(var a=arguments.length,s=new Array(a),l=0;l1&&arguments[1]!==void 0?arguments[1]:{};ts.initial(e),ts.handler(t);var n={current:e},r=So(D_)(n,t),i=So(T_)(n),o=So(ts.changes)(e),a=So(L_)(n);function s(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:function(c){return c};return ts.selector(u),u(n.current)}function l(u){E_(r,i,o,a)(u)}return[s,l]}function L_(e,t){return oa(t)?t(e.current):t}function T_(e,t){return e.current=Wm(Wm({},e.current),t),t}function D_(e,t,n){return oa(t)?t(e.current):Object.keys(n).forEach(function(r){var i;return(i=t[r])===null||i===void 0?void 0:i.call(t,e.current[r])}),n}var $_={create:M_},j_={paths:{vs:"https://cdn.jsdelivr.net/npm/monaco-editor@0.36.1/min/vs"}};function F_(e){return function t(){for(var n=this,r=arguments.length,i=new Array(r),o=0;o=e.length?e.apply(this,i):function(){for(var a=arguments.length,s=new Array(a),l=0;l{let r=t;for(;r;)r.callback(),r=r.next})},get(){let r=[],i=t;for(;i;)r.push(i),i=i.next;return r},subscribe(r){let i=!0,o=n={callback:r,next:null,prev:n};return o.prev?o.prev.next=o:t=o,function(){!i||t===null||(i=!1,o.next?o.next.prev=o.prev:n=o.prev,o.prev?o.prev.next=o.next:t=o.next)}}}}const _m={notify(){},get:()=>[]};function Yb(e,t){let n,r=_m;function i(f){return l(),r.subscribe(f)}function o(){r.notify()}function a(){c.onStateChange&&c.onStateChange()}function s(){return!!n}function l(){n||(n=t?t.addNestedSub(a):e.subscribe(a),r=Qb())}function u(){n&&(n(),n=void 0,r.clear(),r=_m)}const c={addNestedSub:i,notifyNestedSubs:o,handleChangeWrapper:a,isSubscribed:s,trySubscribe:l,tryUnsubscribe:u,getListeners:()=>r};return c}const Jb=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Zb=Jb?b.useLayoutEffect:b.useEffect;function Xb({store:e,context:t,children:n,serverState:r,stabilityCheck:i="once",noopCheck:o="once"}){const a=b.useMemo(()=>{const u=Yb(e);return{store:e,subscription:u,getServerState:r?()=>r:void 0,stabilityCheck:i,noopCheck:o}},[e,r,i,o]),s=b.useMemo(()=>e.getState(),[e]);Zb(()=>{const{subscription:u}=a;return u.onStateChange=u.notifyNestedSubs,u.trySubscribe(),s!==e.getState()&&u.notifyNestedSubs(),()=>{u.tryUnsubscribe(),u.onStateChange=void 0}},[a,s]);const l=t||Sr;return b.createElement(l.Provider,{value:a},n)}function Ng(e=Sr){const t=e===Sr?Lg:Ep(e);return function(){const{store:r}=t();return r}}const eE=Ng();function tE(e=Sr){const t=e===Sr?eE:Ng(e);return function(){return t().dispatch}}const nE=tE();Db(Ab.useSyncExternalStoreWithSelector);Ib(bp.unstable_batchedUpdates);var zg={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},xm=ee.createContext&&ee.createContext(zg),hr=globalThis&&globalThis.__assign||function(){return hr=Object.assign||function(e){for(var t,n=1,r=arguments.length;ntypeof e=="number"&&!isNaN(e),Hr=e=>typeof e=="string",gt=e=>typeof e=="function",Os=e=>Hr(e)||gt(e)?e:null,mc=e=>b.isValidElement(e)||Hr(e)||gt(e)||Do(e);function lE(e,t,n){n===void 0&&(n=300);const{scrollHeight:r,style:i}=e;requestAnimationFrame(()=>{i.minHeight="initial",i.height=r+"px",i.transition=`all ${n}ms`,requestAnimationFrame(()=>{i.height="0",i.padding="0",i.margin="0",setTimeout(t,n)})})}function wu(e){let{enter:t,exit:n,appendPosition:r=!1,collapse:i=!0,collapseDuration:o=300}=e;return function(a){let{children:s,position:l,preventExitTransition:u,done:c,nodeRef:f,isIn:d}=a;const h=r?`${t}--${l}`:t,y=r?`${n}--${l}`:n,m=b.useRef(0);return b.useLayoutEffect(()=>{const w=f.current,p=h.split(" "),v=g=>{g.target===f.current&&(w.dispatchEvent(new Event("d")),w.removeEventListener("animationend",v),w.removeEventListener("animationcancel",v),m.current===0&&g.type!=="animationcancel"&&w.classList.remove(...p))};w.classList.add(...p),w.addEventListener("animationend",v),w.addEventListener("animationcancel",v)},[]),b.useEffect(()=>{const w=f.current,p=()=>{w.removeEventListener("animationend",p),i?lE(w,c,o):c()};d||(u?p():(m.current=1,w.className+=` ${y}`,w.addEventListener("animationend",p)))},[d]),ee.createElement(ee.Fragment,null,s)}}function Cm(e,t){return e!=null?{content:e.content,containerId:e.props.containerId,id:e.props.toastId,theme:e.props.theme,type:e.props.type,data:e.props.data||{},isLoading:e.props.isLoading,icon:e.props.icon,status:t}:{}}const Vt={list:new Map,emitQueue:new Map,on(e,t){return this.list.has(e)||this.list.set(e,[]),this.list.get(e).push(t),this},off(e,t){if(t){const n=this.list.get(e).filter(r=>r!==t);return this.list.set(e,n),this}return this.list.delete(e),this},cancelEmit(e){const t=this.emitQueue.get(e);return t&&(t.forEach(clearTimeout),this.emitQueue.delete(e)),this},emit(e){this.list.has(e)&&this.list.get(e).forEach(t=>{const n=setTimeout(()=>{t(...[].slice.call(arguments,1))},0);this.emitQueue.has(e)||this.emitQueue.set(e,[]),this.emitQueue.get(e).push(n)})}},Za=e=>{let{theme:t,type:n,...r}=e;return ee.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:t==="colored"?"currentColor":`var(--toastify-icon-color-${n})`,...r})},vc={info:function(e){return ee.createElement(Za,{...e},ee.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(e){return ee.createElement(Za,{...e},ee.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(e){return ee.createElement(Za,{...e},ee.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(e){return ee.createElement(Za,{...e},ee.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return ee.createElement("div",{className:"Toastify__spinner"})}};function uE(e){const[,t]=b.useReducer(h=>h+1,0),[n,r]=b.useState([]),i=b.useRef(null),o=b.useRef(new Map).current,a=h=>n.indexOf(h)!==-1,s=b.useRef({toastKey:1,displayedToast:0,count:0,queue:[],props:e,containerId:null,isToastActive:a,getToast:h=>o.get(h)}).current;function l(h){let{containerId:y}=h;const{limit:m}=s.props;!m||y&&s.containerId!==y||(s.count-=s.queue.length,s.queue=[])}function u(h){r(y=>h==null?[]:y.filter(m=>m!==h))}function c(){const{toastContent:h,toastProps:y,staleId:m}=s.queue.shift();d(h,y,m)}function f(h,y){let{delay:m,staleId:w,...p}=y;if(!mc(h)||function(F){return!i.current||s.props.enableMultiContainer&&F.containerId!==s.props.containerId||o.has(F.toastId)&&F.updateId==null}(p))return;const{toastId:v,updateId:g,data:S}=p,{props:E}=s,x=()=>u(v),_=g==null;_&&s.count++;const C={...E,style:E.toastStyle,key:s.toastKey++,...Object.fromEntries(Object.entries(p).filter(F=>{let[H,j]=F;return j!=null})),toastId:v,updateId:g,data:S,closeToast:x,isIn:!1,className:Os(p.className||E.toastClassName),bodyClassName:Os(p.bodyClassName||E.bodyClassName),progressClassName:Os(p.progressClassName||E.progressClassName),autoClose:!p.isLoading&&(k=p.autoClose,P=E.autoClose,k===!1||Do(k)&&k>0?k:P),deleteToast(){const F=Cm(o.get(v),"removed");o.delete(v),Vt.emit(4,F);const H=s.queue.length;if(s.count=v==null?s.count-s.displayedToast:s.count-1,s.count<0&&(s.count=0),H>0){const j=v==null?s.props.limit:1;if(H===1||j===1)s.displayedToast++,c();else{const L=j>H?H:j;s.displayedToast=L;for(let M=0;MI in vc)(j)&&(D=vc[j](A))),D}(C),gt(p.onOpen)&&(C.onOpen=p.onOpen),gt(p.onClose)&&(C.onClose=p.onClose),C.closeButton=E.closeButton,p.closeButton===!1||mc(p.closeButton)?C.closeButton=p.closeButton:p.closeButton===!0&&(C.closeButton=!mc(E.closeButton)||E.closeButton);let $=h;b.isValidElement(h)&&!Hr(h.type)?$=b.cloneElement(h,{closeToast:x,toastProps:C,data:S}):gt(h)&&($=h({closeToast:x,toastProps:C,data:S})),E.limit&&E.limit>0&&s.count>E.limit&&_?s.queue.push({toastContent:$,toastProps:C,staleId:w}):Do(m)?setTimeout(()=>{d($,C,w)},m):d($,C,w)}function d(h,y,m){const{toastId:w}=y;m&&o.delete(m);const p={content:h,props:y};o.set(w,p),r(v=>[...v,w].filter(g=>g!==m)),Vt.emit(4,Cm(p,p.props.updateId==null?"added":"updated"))}return b.useEffect(()=>(s.containerId=e.containerId,Vt.cancelEmit(3).on(0,f).on(1,h=>i.current&&u(h)).on(5,l).emit(2,s),()=>{o.clear(),Vt.emit(3,s)}),[]),b.useEffect(()=>{s.props=e,s.isToastActive=a,s.displayedToast=n.length}),{getToastToRender:function(h){const y=new Map,m=Array.from(o.values());return e.newestOnTop&&m.reverse(),m.forEach(w=>{const{position:p}=w.props;y.has(p)||y.set(p,[]),y.get(p).push(w)}),Array.from(y,w=>h(w[0],w[1]))},containerRef:i,isToastActive:a}}function Om(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientX:e.clientX}function km(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientY:e.clientY}function cE(e){const[t,n]=b.useState(!1),[r,i]=b.useState(!1),o=b.useRef(null),a=b.useRef({start:0,x:0,y:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,boundingRect:null,didMove:!1}).current,s=b.useRef(e),{autoClose:l,pauseOnHover:u,closeToast:c,onClick:f,closeOnClick:d}=e;function h(S){if(e.draggable){S.nativeEvent.type==="touchstart"&&S.nativeEvent.preventDefault(),a.didMove=!1,document.addEventListener("mousemove",p),document.addEventListener("mouseup",v),document.addEventListener("touchmove",p),document.addEventListener("touchend",v);const E=o.current;a.canCloseOnClick=!0,a.canDrag=!0,a.boundingRect=E.getBoundingClientRect(),E.style.transition="",a.x=Om(S.nativeEvent),a.y=km(S.nativeEvent),e.draggableDirection==="x"?(a.start=a.x,a.removalDistance=E.offsetWidth*(e.draggablePercent/100)):(a.start=a.y,a.removalDistance=E.offsetHeight*(e.draggablePercent===80?1.5*e.draggablePercent:e.draggablePercent/100))}}function y(S){if(a.boundingRect){const{top:E,bottom:x,left:_,right:C}=a.boundingRect;S.nativeEvent.type!=="touchend"&&e.pauseOnHover&&a.x>=_&&a.x<=C&&a.y>=E&&a.y<=x?w():m()}}function m(){n(!0)}function w(){n(!1)}function p(S){const E=o.current;a.canDrag&&E&&(a.didMove=!0,t&&w(),a.x=Om(S),a.y=km(S),a.delta=e.draggableDirection==="x"?a.x-a.start:a.y-a.start,a.start!==a.x&&(a.canCloseOnClick=!1),E.style.transform=`translate${e.draggableDirection}(${a.delta}px)`,E.style.opacity=""+(1-Math.abs(a.delta/a.removalDistance)))}function v(){document.removeEventListener("mousemove",p),document.removeEventListener("mouseup",v),document.removeEventListener("touchmove",p),document.removeEventListener("touchend",v);const S=o.current;if(a.canDrag&&a.didMove&&S){if(a.canDrag=!1,Math.abs(a.delta)>a.removalDistance)return i(!0),void e.closeToast();S.style.transition="transform 0.2s, opacity 0.2s",S.style.transform=`translate${e.draggableDirection}(0)`,S.style.opacity="1"}}b.useEffect(()=>{s.current=e}),b.useEffect(()=>(o.current&&o.current.addEventListener("d",m,{once:!0}),gt(e.onOpen)&&e.onOpen(b.isValidElement(e.children)&&e.children.props),()=>{const S=s.current;gt(S.onClose)&&S.onClose(b.isValidElement(S.children)&&S.children.props)}),[]),b.useEffect(()=>(e.pauseOnFocusLoss&&(document.hasFocus()||w(),window.addEventListener("focus",m),window.addEventListener("blur",w)),()=>{e.pauseOnFocusLoss&&(window.removeEventListener("focus",m),window.removeEventListener("blur",w))}),[e.pauseOnFocusLoss]);const g={onMouseDown:h,onTouchStart:h,onMouseUp:y,onTouchEnd:y};return l&&u&&(g.onMouseEnter=w,g.onMouseLeave=m),d&&(g.onClick=S=>{f&&f(S),a.canCloseOnClick&&c()}),{playToast:m,pauseToast:w,isRunning:t,preventExitTransition:r,toastRef:o,eventHandlers:g}}function Ug(e){let{closeToast:t,theme:n,ariaLabel:r="close"}=e;return ee.createElement("button",{className:`Toastify__close-button Toastify__close-button--${n}`,type:"button",onClick:i=>{i.stopPropagation(),t(i)},"aria-label":r},ee.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},ee.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function fE(e){let{delay:t,isRunning:n,closeToast:r,type:i="default",hide:o,className:a,style:s,controlledProgress:l,progress:u,rtl:c,isIn:f,theme:d}=e;const h=o||l&&u===0,y={...s,animationDuration:`${t}ms`,animationPlayState:n?"running":"paused",opacity:h?0:1};l&&(y.transform=`scaleX(${u})`);const m=or("Toastify__progress-bar",l?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${d}`,`Toastify__progress-bar--${i}`,{"Toastify__progress-bar--rtl":c}),w=gt(a)?a({rtl:c,type:i,defaultClassName:m}):or(m,a);return ee.createElement("div",{role:"progressbar","aria-hidden":h?"true":"false","aria-label":"notification timer",className:w,style:y,[l&&u>=1?"onTransitionEnd":"onAnimationEnd"]:l&&u<1?null:()=>{f&&r()}})}const dE=e=>{const{isRunning:t,preventExitTransition:n,toastRef:r,eventHandlers:i}=cE(e),{closeButton:o,children:a,autoClose:s,onClick:l,type:u,hideProgressBar:c,closeToast:f,transition:d,position:h,className:y,style:m,bodyClassName:w,bodyStyle:p,progressClassName:v,progressStyle:g,updateId:S,role:E,progress:x,rtl:_,toastId:C,deleteToast:k,isIn:P,isLoading:$,iconOut:F,closeOnClick:H,theme:j}=e,L=or("Toastify__toast",`Toastify__toast-theme--${j}`,`Toastify__toast--${u}`,{"Toastify__toast--rtl":_},{"Toastify__toast--close-on-click":H}),M=gt(y)?y({rtl:_,position:h,type:u,defaultClassName:L}):or(L,y),D=!!x||!s,A={closeToast:f,type:u,theme:j};let I=null;return o===!1||(I=gt(o)?o(A):b.isValidElement(o)?b.cloneElement(o,A):Ug(A)),ee.createElement(d,{isIn:P,done:k,position:h,preventExitTransition:n,nodeRef:r},ee.createElement("div",{id:C,onClick:l,className:M,...i,style:m,ref:r},ee.createElement("div",{...P&&{role:E},className:gt(w)?w({type:u}):or("Toastify__toast-body",w),style:p},F!=null&&ee.createElement("div",{className:or("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!$})},F),ee.createElement("div",null,a)),I,ee.createElement(fE,{...S&&!D?{key:`pb-${S}`}:{},rtl:_,theme:j,delay:s,isRunning:t,isIn:P,closeToast:f,hide:c,type:u,style:g,className:v,controlledProgress:D,progress:x||0})))},Su=function(e,t){return t===void 0&&(t=!1),{enter:`Toastify--animate Toastify__${e}-enter`,exit:`Toastify--animate Toastify__${e}-exit`,appendPosition:t}},pE=wu(Su("bounce",!0));wu(Su("slide",!0));wu(Su("zoom"));wu(Su("flip"));const Nf=b.forwardRef((e,t)=>{const{getToastToRender:n,containerRef:r,isToastActive:i}=uE(e),{className:o,style:a,rtl:s,containerId:l}=e;function u(c){const f=or("Toastify__toast-container",`Toastify__toast-container--${c}`,{"Toastify__toast-container--rtl":s});return gt(o)?o({position:c,rtl:s,defaultClassName:f}):or(f,Os(o))}return b.useEffect(()=>{t&&(t.current=r.current)},[]),ee.createElement("div",{ref:r,className:"Toastify",id:l},n((c,f)=>{const d=f.length?{...a}:{...a,pointerEvents:"none"};return ee.createElement("div",{className:u(c),style:d,key:`container-${c}`},f.map((h,y)=>{let{content:m,props:w}=h;return ee.createElement(dE,{...w,isIn:i(w.toastId),style:{...w.style,"--nth":y+1,"--len":f.length},key:`toast-${w.key}`},m)}))}))});Nf.displayName="ToastContainer",Nf.defaultProps={position:"top-right",transition:pE,autoClose:5e3,closeButton:Ug,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,draggable:!0,draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};let gc,Pr=new Map,wo=[],hE=1;function Hg(){return""+hE++}function mE(e){return e&&(Hr(e.toastId)||Do(e.toastId))?e.toastId:Hg()}function $o(e,t){return Pr.size>0?Vt.emit(0,e,t):wo.push({content:e,options:t}),t.toastId}function ll(e,t){return{...t,type:t&&t.type||e,toastId:mE(t)}}function Xa(e){return(t,n)=>$o(t,ll(e,n))}function me(e,t){return $o(e,ll("default",t))}me.loading=(e,t)=>$o(e,ll("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...t})),me.promise=function(e,t,n){let r,{pending:i,error:o,success:a}=t;i&&(r=Hr(i)?me.loading(i,n):me.loading(i.render,{...n,...i}));const s={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},l=(c,f,d)=>{if(f==null)return void me.dismiss(r);const h={type:c,...s,...n,data:d},y=Hr(f)?{render:f}:f;return r?me.update(r,{...h,...y}):me(y.render,{...h,...y}),d},u=gt(e)?e():e;return u.then(c=>l("success",a,c)).catch(c=>l("error",o,c)),u},me.success=Xa("success"),me.info=Xa("info"),me.error=Xa("error"),me.warning=Xa("warning"),me.warn=me.warning,me.dark=(e,t)=>$o(e,ll("default",{theme:"dark",...t})),me.dismiss=e=>{Pr.size>0?Vt.emit(1,e):wo=wo.filter(t=>e!=null&&t.options.toastId!==e)},me.clearWaitingQueue=function(e){return e===void 0&&(e={}),Vt.emit(5,e)},me.isActive=e=>{let t=!1;return Pr.forEach(n=>{n.isToastActive&&n.isToastActive(e)&&(t=!0)}),t},me.update=function(e,t){t===void 0&&(t={}),setTimeout(()=>{const n=function(r,i){let{containerId:o}=i;const a=Pr.get(o||gc);return a&&a.getToast(r)}(e,t);if(n){const{props:r,content:i}=n,o={delay:100,...r,...t,toastId:t.toastId||e,updateId:Hg()};o.toastId!==e&&(o.staleId=e);const a=o.render||i;delete o.render,$o(a,o)}},0)},me.done=e=>{me.update(e,{progress:1})},me.onChange=e=>(Vt.on(4,e),()=>{Vt.off(4,e)}),me.POSITION={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},me.TYPE={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"},Vt.on(2,e=>{gc=e.containerId||e,Pr.set(gc,e),wo.forEach(t=>{Vt.emit(0,t.content,t.options)}),wo=[]}).on(3,e=>{Pr.delete(e.containerId||e),Pr.size===0&&Vt.off(0).off(1).off(5)});var Wg={exports:{}},vE="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",gE=vE,yE=gE;function qg(){}function Kg(){}Kg.resetWarningCache=qg;var wE=function(){function e(r,i,o,a,s,l){if(l!==yE){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:Kg,resetWarningCache:qg};return n.PropTypes=n,n};Wg.exports=wE();var SE=Wg.exports;const he=p0(SE);function Qi(e,t,n,r){function i(o){return o instanceof n?o:new n(function(a){a(o)})}return new(n||(n=Promise))(function(o,a){function s(c){try{u(r.next(c))}catch(f){a(f)}}function l(c){try{u(r.throw(c))}catch(f){a(f)}}function u(c){c.done?o(c.value):i(c.value).then(s,l)}u((r=r.apply(e,t||[])).next())})}function Yi(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(u){return function(c){return l([u,c])}}function l(u){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,u[0]&&(n=0)),n;)try{if(r=1,i&&(o=u[0]&2?i.return:u[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,u[1])).done)return o;switch(i=0,o&&(u=[u[0]&2,o.value]),u[0]){case 0:case 1:o=u;break;case 4:return n.label++,{value:u[1],done:!1};case 5:n.label++,i=u[1],u=[0];continue;case 7:u=n.ops.pop(),n.trys.pop();continue;default:if(o=n.trys,!(o=o.length>0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]0)&&!(i=r.next()).done;)o.push(i.value)}catch(s){a={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o}function Pm(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r0?r:e.name,writable:!1,configurable:!1,enumerable:!0})}return n}function EE(e){var t=e.name,n=t&&t.lastIndexOf(".")!==-1;if(n&&!e.type){var r=t.split(".").pop().toLowerCase(),i=bE.get(r);i&&Object.defineProperty(e,"type",{value:i,writable:!1,configurable:!1,enumerable:!0})}return e}var _E=[".DS_Store","Thumbs.db"];function xE(e){return Qi(this,void 0,void 0,function(){return Yi(this,function(t){return ul(e)&&CE(e.dataTransfer)?[2,PE(e.dataTransfer,e.type)]:OE(e)?[2,kE(e)]:Array.isArray(e)&&e.every(function(n){return"getFile"in n&&typeof n.getFile=="function"})?[2,AE(e)]:[2,[]]})})}function CE(e){return ul(e)}function OE(e){return ul(e)&&ul(e.target)}function ul(e){return typeof e=="object"&&e!==null}function kE(e){return zf(e.target.files).map(function(t){return wa(t)})}function AE(e){return Qi(this,void 0,void 0,function(){var t;return Yi(this,function(n){switch(n.label){case 0:return[4,Promise.all(e.map(function(r){return r.getFile()}))];case 1:return t=n.sent(),[2,t.map(function(r){return wa(r)})]}})})}function PE(e,t){return Qi(this,void 0,void 0,function(){var n,r;return Yi(this,function(i){switch(i.label){case 0:return e.items?(n=zf(e.items).filter(function(o){return o.kind==="file"}),t!=="drop"?[2,n]:[4,Promise.all(n.map(IE))]):[3,2];case 1:return r=i.sent(),[2,Im(Gg(r))];case 2:return[2,Im(zf(e.files).map(function(o){return wa(o)}))]}})})}function Im(e){return e.filter(function(t){return _E.indexOf(t.name)===-1})}function zf(e){if(e===null)return[];for(var t=[],n=0;ne.length)&&(t=e.length);for(var n=0,r=new Array(t);nn)return[!1,$m(n)];if(e.sizen)return[!1,$m(n)]}return[!0,null]}function Mr(e){return e!=null}function BE(e){var t=e.files,n=e.accept,r=e.minSize,i=e.maxSize,o=e.multiple,a=e.maxFiles,s=e.validator;return!o&&t.length>1||o&&a>=1&&t.length>a?!1:t.every(function(l){var u=ny(l,n),c=ra(u,1),f=c[0],d=ry(l,r,i),h=ra(d,1),y=h[0],m=s?s(l):null;return f&&y&&!m})}function cl(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function es(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(t){return t==="Files"||t==="application/x-moz-file"}):!!e.target&&!!e.target.files}function Fm(e){e.preventDefault()}function UE(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function HE(e){return e.indexOf("Edge/")!==-1}function WE(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return UE(e)||HE(e)}function gn(){for(var e=arguments.length,t=new Array(e),n=0;n1?i-1:0),a=1;ae.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function l_(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var bu=b.forwardRef(function(e,t){var n=e.children,r=fl(e,JE),i=c_(r),o=i.open,a=fl(i,ZE);return b.useImperativeHandle(t,function(){return{open:o}},[o]),ee.createElement(b.Fragment,null,n(Oe(Oe({},a),{},{open:o})))});bu.displayName="Dropzone";var sy={disabled:!1,getFilesFromEvent:xE,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!0,autoFocus:!1};bu.defaultProps=sy;bu.propTypes={children:he.func,accept:he.objectOf(he.arrayOf(he.string)),multiple:he.bool,preventDropOnDocument:he.bool,noClick:he.bool,noKeyboard:he.bool,noDrag:he.bool,noDragEventsBubbling:he.bool,minSize:he.number,maxSize:he.number,maxFiles:he.number,disabled:he.bool,getFilesFromEvent:he.func,onFileDialogCancel:he.func,onFileDialogOpen:he.func,useFsAccessApi:he.bool,autoFocus:he.bool,onDragEnter:he.func,onDragLeave:he.func,onDragOver:he.func,onDrop:he.func,onDropAccepted:he.func,onDropRejected:he.func,onError:he.func,validator:he.func};const u_=bu;var Hf={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function c_(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=Oe(Oe({},sy),e),n=t.accept,r=t.disabled,i=t.getFilesFromEvent,o=t.maxSize,a=t.minSize,s=t.multiple,l=t.maxFiles,u=t.onDragEnter,c=t.onDragLeave,f=t.onDragOver,d=t.onDrop,h=t.onDropAccepted,y=t.onDropRejected,m=t.onFileDialogCancel,w=t.onFileDialogOpen,p=t.useFsAccessApi,v=t.autoFocus,g=t.preventDropOnDocument,S=t.noClick,E=t.noKeyboard,x=t.noDrag,_=t.noDragEventsBubbling,C=t.onError,k=t.validator,P=b.useMemo(function(){return GE(n)},[n]),$=b.useMemo(function(){return KE(n)},[n]),F=b.useMemo(function(){return typeof w=="function"?w:Nm},[w]),H=b.useMemo(function(){return typeof m=="function"?m:Nm},[m]),j=b.useRef(null),L=b.useRef(null),M=b.useReducer(f_,Hf),D=wc(M,2),A=D[0],I=D[1],R=A.isFocused,N=A.isFileDialogActive,V=b.useRef(typeof window<"u"&&window.isSecureContext&&p&&qE()),T=function(){!V.current&&N&&setTimeout(function(){if(L.current){var Z=L.current.files;Z.length||(I({type:"closeDialog"}),H())}},300)};b.useEffect(function(){return window.addEventListener("focus",T,!1),function(){window.removeEventListener("focus",T,!1)}},[L,N,H,V]);var z=b.useRef([]),U=function(Z){j.current&&j.current.contains(Z.target)||(Z.preventDefault(),z.current=[])};b.useEffect(function(){return g&&(document.addEventListener("dragover",Fm,!1),document.addEventListener("drop",U,!1)),function(){g&&(document.removeEventListener("dragover",Fm),document.removeEventListener("drop",U))}},[j,g]),b.useEffect(function(){return!r&&v&&j.current&&j.current.focus(),function(){}},[j,v,r]);var W=b.useCallback(function(q){C?C(q):console.error(q)},[C]),X=b.useCallback(function(q){q.preventDefault(),q.persist(),Ta(q),z.current=[].concat(t_(z.current),[q.target]),es(q)&&Promise.resolve(i(q)).then(function(Z){if(!(cl(q)&&!_)){var je=Z.length,Ke=je>0&&BE({files:Z,accept:P,minSize:a,maxSize:o,multiple:s,maxFiles:l,validator:k}),xt=je>0&&!Ke;I({isDragAccept:Ke,isDragReject:xt,isDragActive:!0,type:"setDraggedFiles"}),u&&u(q)}}).catch(function(Z){return W(Z)})},[i,u,W,_,P,a,o,s,l,k]),oe=b.useCallback(function(q){q.preventDefault(),q.persist(),Ta(q);var Z=es(q);if(Z&&q.dataTransfer)try{q.dataTransfer.dropEffect="copy"}catch{}return Z&&f&&f(q),!1},[f,_]),Ie=b.useCallback(function(q){q.preventDefault(),q.persist(),Ta(q);var Z=z.current.filter(function(Ke){return j.current&&j.current.contains(Ke)}),je=Z.indexOf(q.target);je!==-1&&Z.splice(je,1),z.current=Z,!(Z.length>0)&&(I({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),es(q)&&c&&c(q))},[j,c,_]),xe=b.useCallback(function(q,Z){var je=[],Ke=[];q.forEach(function(xt){var ro=ny(xt,P),ni=wc(ro,2),$u=ni[0],ju=ni[1],Fu=ry(xt,a,o),Da=wc(Fu,2),Ru=Da[0],Nu=Da[1],zu=k?k(xt):null;if($u&&Ru&&!zu)je.push(xt);else{var Vu=[ju,Nu];zu&&(Vu=Vu.concat(zu)),Ke.push({file:xt,errors:Vu.filter(function(jw){return jw})})}}),(!s&&je.length>1||s&&l>=1&&je.length>l)&&(je.forEach(function(xt){Ke.push({file:xt,errors:[VE]})}),je.splice(0)),I({acceptedFiles:je,fileRejections:Ke,type:"setFiles"}),d&&d(je,Ke,Z),Ke.length>0&&y&&y(Ke,Z),je.length>0&&h&&h(je,Z)},[I,s,P,a,o,l,d,h,y,k]),be=b.useCallback(function(q){q.preventDefault(),q.persist(),Ta(q),z.current=[],es(q)&&Promise.resolve(i(q)).then(function(Z){cl(q)&&!_||xe(Z,q)}).catch(function(Z){return W(Z)}),I({type:"reset"})},[i,xe,W,_]),Ce=b.useCallback(function(){if(V.current){I({type:"openDialog"}),F();var q={multiple:s,types:$};window.showOpenFilePicker(q).then(function(Z){return i(Z)}).then(function(Z){xe(Z,null),I({type:"closeDialog"})}).catch(function(Z){QE(Z)?(H(Z),I({type:"closeDialog"})):YE(Z)?(V.current=!1,L.current?(L.current.value=null,L.current.click()):W(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no was provided."))):W(Z)});return}L.current&&(I({type:"openDialog"}),F(),L.current.value=null,L.current.click())},[I,F,H,p,xe,W,$,s]),Zt=b.useCallback(function(q){!j.current||!j.current.isEqualNode(q.target)||(q.key===" "||q.key==="Enter"||q.keyCode===32||q.keyCode===13)&&(q.preventDefault(),Ce())},[j,Ce]),_t=b.useCallback(function(){I({type:"focus"})},[]),Ma=b.useCallback(function(){I({type:"blur"})},[]),fh=b.useCallback(function(){S||(WE()?setTimeout(Ce,0):Ce())},[S,Ce]),ti=function(Z){return r?null:Z},Du=function(Z){return E?null:ti(Z)},La=function(Z){return x?null:ti(Z)},Ta=function(Z){_&&Z.stopPropagation()},Tw=b.useMemo(function(){return function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=q.refKey,je=Z===void 0?"ref":Z,Ke=q.role,xt=q.onKeyDown,ro=q.onFocus,ni=q.onBlur,$u=q.onClick,ju=q.onDragEnter,Fu=q.onDragOver,Da=q.onDragLeave,Ru=q.onDrop,Nu=fl(q,XE);return Oe(Oe(Uf({onKeyDown:Du(gn(xt,Zt)),onFocus:Du(gn(ro,_t)),onBlur:Du(gn(ni,Ma)),onClick:ti(gn($u,fh)),onDragEnter:La(gn(ju,X)),onDragOver:La(gn(Fu,oe)),onDragLeave:La(gn(Da,Ie)),onDrop:La(gn(Ru,be)),role:typeof Ke=="string"&&Ke!==""?Ke:"presentation"},je,j),!r&&!E?{tabIndex:0}:{}),Nu)}},[j,Zt,_t,Ma,fh,X,oe,Ie,be,E,x,r]),Dw=b.useCallback(function(q){q.stopPropagation()},[]),$w=b.useMemo(function(){return function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Z=q.refKey,je=Z===void 0?"ref":Z,Ke=q.onChange,xt=q.onClick,ro=fl(q,e_),ni=Uf({accept:P,multiple:s,type:"file",style:{display:"none"},onChange:ti(gn(Ke,be)),onClick:ti(gn(xt,Dw)),tabIndex:-1},je,L);return Oe(Oe({},ni),ro)}},[L,n,s,be,r]);return Oe(Oe({},A),{},{isFocused:R&&!r,getRootProps:Tw,getInputProps:$w,rootRef:j,inputRef:L,open:ti(Ce)})}function f_(e,t){switch(t.type){case"focus":return Oe(Oe({},e),{},{isFocused:!0});case"blur":return Oe(Oe({},e),{},{isFocused:!1});case"openDialog":return Oe(Oe({},Hf),{},{isFileDialogActive:!0});case"closeDialog":return Oe(Oe({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return Oe(Oe({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return Oe(Oe({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections});case"reset":return Oe({},Hf);default:return e}}function Nm(){}const ia=({accept:e,children:t,multiple:n,noClick:r,onDrop:i})=>{const o=b.useCallback(s=>{for(const l of s)me(`${l.errors[0].message}, ${l.file.name}`,{type:"error"})},[]),a=b.useCallback(s=>{const l=typeof s.name=="string"?s.name:"";return e==="lottie"&&!l.endsWith(".lottie")?{message:"Invalid .lottie",code:yc.FileInvalidType}:e==="json"&&s.type!=="application/json"?{message:"Invalid .json",code:yc.FileInvalidType}:e==="lss"&&!l.endsWith(".lss")?{message:"Invalid .lss",code:yc.FileInvalidType}:null},[]);return O.jsx(u_,{noClick:r,maxFiles:n?10:1,validator:a,multiple:n,onDrop:i,onDropRejected:o,children:t})};function d_(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Vm(e){for(var t=1;t=0)&&(n[i]=e[i]);return n}function h_(e,t){if(e==null)return{};var n=p_(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function m_(e,t){return v_(e)||g_(e,t)||y_(e,t)||w_()}function v_(e){if(Array.isArray(e))return e}function g_(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,i=!1,o=void 0;try{for(var a=e[Symbol.iterator](),s;!(r=(s=a.next()).done)&&(n.push(s.value),!(t&&n.length===t));r=!0);}catch(l){i=!0,o=l}finally{try{!r&&a.return!=null&&a.return()}finally{if(i)throw o}}return n}}function y_(e,t){if(e){if(typeof e=="string")return Bm(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Bm(e,t)}}function Bm(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=e.length?e.apply(this,i):function(){for(var a=arguments.length,s=new Array(a),l=0;l1&&arguments[1]!==void 0?arguments[1]:{};ts.initial(e),ts.handler(t);var n={current:e},r=So(T_)(n,t),i=So(L_)(n),o=So(ts.changes)(e),a=So(M_)(n);function s(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:function(c){return c};return ts.selector(u),u(n.current)}function l(u){b_(r,i,o,a)(u)}return[s,l]}function M_(e,t){return oa(t)?t(e.current):t}function L_(e,t){return e.current=Hm(Hm({},e.current),t),t}function T_(e,t,n){return oa(t)?t(e.current):Object.keys(n).forEach(function(r){var i;return(i=t[r])===null||i===void 0?void 0:i.call(t,e.current[r])}),n}var D_={create:I_},$_={paths:{vs:"https://cdn.jsdelivr.net/npm/monaco-editor@0.36.1/min/vs"}};function j_(e){return function t(){for(var n=this,r=arguments.length,i=new Array(r),o=0;o=e.length?e.apply(this,i):function(){for(var a=arguments.length,s=new Array(a),l=0;l{r.current=!1}:e,t)}var Ot=l4;function jo(){}function bi(e,t,n,r){return u4(e,r)||c4(e,t,n,r)}function u4(e,t){return e.editor.getModel(vy(e,t))}function c4(e,t,n,r){return e.editor.createModel(t,n,r?vy(e,r):void 0)}function vy(e,t){return e.Uri.parse(t)}function f4({original:e,modified:t,language:n,originalLanguage:r,modifiedLanguage:i,originalModelPath:o,modifiedModelPath:a,keepCurrentOriginalModel:s=!1,keepCurrentModifiedModel:l=!1,theme:u="light",loading:c="Loading...",options:f={},height:d="100%",width:h="100%",className:y,wrapperProps:m={},beforeMount:w=jo,onMount:p=jo}){let[v,g]=b.useState(!1),[S,_]=b.useState(!0),x=b.useRef(null),E=b.useRef(null),C=b.useRef(null),k=b.useRef(p),P=b.useRef(w),$=b.useRef(!1);my(()=>{let L=py.init();return L.then(M=>(E.current=M)&&_(!1)).catch(M=>(M==null?void 0:M.type)!=="cancelation"&&console.error("Monaco initialization: error:",M)),()=>x.current?z():L.cancel()}),Ot(()=>{if(x.current&&E.current){let L=x.current.getOriginalEditor(),M=bi(E.current,e||"",r||n||"text",o||"");M!==L.getModel()&&L.setModel(M)}},[o],v),Ot(()=>{if(x.current&&E.current){let L=x.current.getModifiedEditor(),M=bi(E.current,t||"",i||n||"text",a||"");M!==L.getModel()&&L.setModel(M)}},[a],v),Ot(()=>{let L=x.current.getModifiedEditor();L.getOption(E.current.editor.EditorOption.readOnly)?L.setValue(t||""):t!==L.getValue()&&(L.executeEdits("",[{range:L.getModel().getFullModelRange(),text:t||"",forceMoveMarkers:!0}]),L.pushUndoStop())},[t],v),Ot(()=>{var L,M;(M=(L=x.current)==null?void 0:L.getModel())==null||M.original.setValue(e||"")},[e],v),Ot(()=>{let{original:L,modified:M}=x.current.getModel();E.current.editor.setModelLanguage(L,r||n||"text"),E.current.editor.setModelLanguage(M,i||n||"text")},[n,r,i],v),Ot(()=>{var L;(L=E.current)==null||L.editor.setTheme(u)},[u],v),Ot(()=>{var L;(L=x.current)==null||L.updateOptions(f)},[f],v);let j=b.useCallback(()=>{var D;if(!E.current)return;P.current(E.current);let L=bi(E.current,e||"",r||n||"text",o||""),M=bi(E.current,t||"",i||n||"text",a||"");(D=x.current)==null||D.setModel({original:L,modified:M})},[n,t,i,e,r,o,a]),U=b.useCallback(()=>{var L;!$.current&&C.current&&(x.current=E.current.editor.createDiffEditor(C.current,{automaticLayout:!0,...f}),j(),(L=E.current)==null||L.editor.setTheme(u),g(!0),$.current=!0)},[f,u,j]);b.useEffect(()=>{v&&k.current(x.current,E.current)},[v]),b.useEffect(()=>{!S&&!v&&U()},[S,v,U]);function z(){var M,D,A,I;let L=(M=x.current)==null?void 0:M.getModel();s||((D=L==null?void 0:L.original)==null||D.dispose()),l||((A=L==null?void 0:L.modified)==null||A.dispose()),(I=x.current)==null||I.dispose()}return ne.createElement(hy,{width:h,height:d,isEditorReady:v,loading:c,_ref:C,className:y,wrapperProps:m})}var d4=f4;b.memo(d4);function p4(e){let t=b.useRef();return b.useEffect(()=>{t.current=e},[e]),t.current}var h4=p4,ns=new Map;function m4({defaultValue:e,defaultLanguage:t,defaultPath:n,value:r,language:i,path:o,theme:a="light",line:s,loading:l="Loading...",options:u={},overrideServices:c={},saveViewState:f=!0,keepCurrentModel:d=!1,width:h="100%",height:y="100%",className:m,wrapperProps:w={},beforeMount:p=jo,onMount:v=jo,onChange:g,onValidate:S=jo}){let[_,x]=b.useState(!1),[E,C]=b.useState(!0),k=b.useRef(null),P=b.useRef(null),$=b.useRef(null),j=b.useRef(v),U=b.useRef(p),z=b.useRef(),L=b.useRef(r),M=h4(o),D=b.useRef(!1),A=b.useRef(!1);my(()=>{let R=py.init();return R.then(V=>(k.current=V)&&C(!1)).catch(V=>(V==null?void 0:V.type)!=="cancelation"&&console.error("Monaco initialization: error:",V)),()=>P.current?F():R.cancel()}),Ot(()=>{var V,T,N,H;let R=bi(k.current,e||r||"",t||i||"",o||n||"");R!==((V=P.current)==null?void 0:V.getModel())&&(f&&ns.set(M,(T=P.current)==null?void 0:T.saveViewState()),(N=P.current)==null||N.setModel(R),f&&((H=P.current)==null||H.restoreViewState(ns.get(o))))},[o],_),Ot(()=>{var R;(R=P.current)==null||R.updateOptions(u)},[u],_),Ot(()=>{!P.current||r===void 0||(P.current.getOption(k.current.editor.EditorOption.readOnly)?P.current.setValue(r):r!==P.current.getValue()&&(A.current=!0,P.current.executeEdits("",[{range:P.current.getModel().getFullModelRange(),text:r,forceMoveMarkers:!0}]),P.current.pushUndoStop(),A.current=!1))},[r],_),Ot(()=>{var V,T;let R=(V=P.current)==null?void 0:V.getModel();R&&i&&((T=k.current)==null||T.editor.setModelLanguage(R,i))},[i],_),Ot(()=>{var R;s!==void 0&&((R=P.current)==null||R.revealLine(s))},[s],_),Ot(()=>{var R;(R=k.current)==null||R.editor.setTheme(a)},[a],_);let I=b.useCallback(()=>{var R;if(!(!$.current||!k.current)&&!D.current){U.current(k.current);let V=o||n,T=bi(k.current,r||e||"",t||i||"",V||"");P.current=(R=k.current)==null?void 0:R.editor.create($.current,{model:T,automaticLayout:!0,...u},c),f&&P.current.restoreViewState(ns.get(V)),k.current.editor.setTheme(a),x(!0),D.current=!0}},[e,t,n,r,i,o,u,c,f,a]);b.useEffect(()=>{_&&j.current(P.current,k.current)},[_]),b.useEffect(()=>{!E&&!_&&I()},[E,_,I]),L.current=r,b.useEffect(()=>{var R,V;_&&g&&((R=z.current)==null||R.dispose(),z.current=(V=P.current)==null?void 0:V.onDidChangeModelContent(T=>{A.current||g(P.current.getValue(),T)}))},[_,g]),b.useEffect(()=>{if(_){let R=k.current.editor.onDidChangeMarkers(V=>{var N;let T=(N=P.current.getModel())==null?void 0:N.uri;if(T&&V.find(H=>H.path===T.path)){let H=k.current.editor.getModelMarkers({resource:T});S==null||S(H)}});return()=>{R==null||R.dispose()}}return()=>{}},[_,S]);function F(){var R,V;(R=z.current)==null||R.dispose(),d?f&&ns.set(o,P.current.saveViewState()):(V=P.current.getModel())==null||V.dispose(),P.current.dispose()}return ne.createElement(hy,{width:h,height:y,isEditorReady:_,loading:l,_ref:$,className:m,wrapperProps:w})}var v4=m4,g4=b.memo(v4),y4=g4;function gy(e){return mn({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"m18.988 2.012 3 3L19.701 7.3l-3-3zM8 16h3l7.287-7.287-3-3L8 13z"}},{tag:"path",attr:{d:"M19 19H8.158c-.026 0-.053.01-.079.01-.033 0-.066-.009-.1-.01H5V5h6.847l2-2H5c-1.103 0-2 .896-2 2v14c0 1.104.897 2 2 2h14a2 2 0 0 0 2-2v-8.668l-2 2V19z"}}]})(e)}function yy(e){return mn({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M5 21h14a2 2 0 0 0 2-2V8l-5-5H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2zM7 5h4v2h2V5h2v4H7V5zm0 8h10v6H7v-6z"}}]})(e)}const{createElement:Bi,createContext:w4,forwardRef:wy,useCallback:Jn,useContext:Sy,useEffect:Nn,useImperativeHandle:by,useLayoutEffect:S4,useMemo:b4,useRef:kt,useState:Fo}=Rs,Km=Rs["useId".toString()],hl=S4,E4=typeof Km=="function"?Km:()=>null;let _4=0;function Pp(e=null){const t=E4(),n=kt(e||t||null);return n.current===null&&(n.current=""+_4++),n.current}const xu=w4(null);xu.displayName="PanelGroupContext";function Ey({children:e=null,className:t="",collapsedSize:n=0,collapsible:r=!1,defaultSize:i=null,forwardedRef:o,id:a=null,maxSize:s=100,minSize:l=10,onCollapse:u=null,onResize:c=null,order:f=null,style:d={},tagName:h="div"}){const y=Sy(xu);if(y===null)throw Error("Panel components must be rendered within a PanelGroup container");const m=Pp(a),{collapsePanel:w,expandPanel:p,getPanelStyle:v,registerPanel:g,resizePanel:S,unregisterPanel:_}=y,x=kt({onCollapse:u,onResize:c});if(Nn(()=>{x.current.onCollapse=u,x.current.onResize=c}),l<0||l>100)throw Error(`Panel minSize must be between 0 and 100, but was ${l}`);if(s<0||s>100)throw Error(`Panel maxSize must be between 0 and 100, but was ${s}`);if(i!==null){if(i<0||i>100)throw Error(`Panel defaultSize must be between 0 and 100, but was ${i}`);l>i&&!r&&(console.error(`Panel minSize ${l} cannot be greater than defaultSize ${i}`),i=l)}const E=v(m,i),C=kt({size:Gm(E)}),k=kt({callbacksRef:x,collapsedSize:n,collapsible:r,defaultSize:i,id:m,idWasAutoGenerated:a==null,maxSize:s,minSize:l,order:f});return hl(()=>{C.current.size=Gm(E),k.current.callbacksRef=x,k.current.collapsedSize=n,k.current.collapsible=r,k.current.defaultSize=i,k.current.id=m,k.current.idWasAutoGenerated=a==null,k.current.maxSize=s,k.current.minSize=l,k.current.order=f}),hl(()=>(g(m,k),()=>{_(m)}),[f,m,g,_]),by(o,()=>({collapse:()=>w(m),expand:()=>p(m),getCollapsed(){return C.current.size===0},getSize(){return C.current.size},resize:P=>S(m,P)}),[w,p,m,S]),Bi(h,{children:e,className:t,"data-panel":"","data-panel-collapsible":r||void 0,"data-panel-id":m,"data-panel-size":parseFloat(""+E.flexGrow).toFixed(1),id:`data-panel-id-${m}`,style:{...E,...d}})}const ks=wy((e,t)=>Bi(Ey,{...e,forwardedRef:t}));Ey.displayName="Panel";ks.displayName="forwardRef(Panel)";function Gm(e){const{flexGrow:t}=e;return typeof t=="string"?parseFloat(t):t}const Wr=10;function bo(e,t,n,r,i,o,a,s){const{sizes:l}=s||{},u=l||o;if(i===0)return u;const c=zt(t),f=u.concat();let d=0;{const m=i<0?r:n,w=c.findIndex(S=>S.current.id===m),p=c[w],v=u[w],g=Qm(p,Math.abs(i),v,e);if(v===g)return u;g===0&&v>0&&a.set(m,v),i=i<0?v-g:g-v}let h=i<0?n:r,y=c.findIndex(m=>m.current.id===h);for(;;){const m=c[y],w=u[y],p=Math.abs(i)-Math.abs(d),v=Qm(m,0-p,w,e);if(w!==v&&(v===0&&w>0&&a.set(m.current.id,w),d+=w-v,f[y]=v,d.toPrecision(Wr).localeCompare(Math.abs(i).toPrecision(Wr),void 0,{numeric:!0})>=0))break;if(i<0){if(--y<0)break}else if(++y>=c.length)break}return d===0?u:(h=i<0?r:n,y=c.findIndex(m=>m.current.id===h),f[y]=u[y]+d,f)}function ii(e,t,n){t.forEach((r,i)=>{const o=e[i];if(!o)return;const{callbacksRef:a,collapsedSize:s,collapsible:l,id:u}=o.current,c=n[u];if(c!==r){n[u]=r;const{onCollapse:f,onResize:d}=a.current;d&&d(r,c),l&&f&&((c==null||c===s)&&r!==s?f(!1):c!==s&&r===s&&f(!0))}})}function xc(e,t){if(t.length<2)return[null,null];const n=t.findIndex(a=>a.current.id===e);if(n<0)return[null,null];const r=n===t.length-1,i=r?t[n-1].current.id:e,o=r?e:t[n+1].current.id;return[i,o]}function _y(e,t,n){if(e.size===1)return"100";const i=zt(e).findIndex(a=>a.current.id===t),o=n[i];return o==null?"0":o.toPrecision(Wr)}function x4(e){const t=document.querySelector(`[data-panel-id="${e}"]`);return t||null}function Ip(e){const t=document.querySelector(`[data-panel-group-id="${e}"]`);return t||null}function Cu(e){const t=document.querySelector(`[data-panel-resize-handle-id="${e}"]`);return t||null}function C4(e){return xy().findIndex(r=>r.getAttribute("data-panel-resize-handle-id")===e)??null}function xy(){return Array.from(document.querySelectorAll("[data-panel-resize-handle-id]"))}function Cy(e){return Array.from(document.querySelectorAll(`[data-panel-resize-handle-id][data-panel-group-id="${e}"]`))}function Mp(e,t,n){var l,u,c,f;const r=Cu(t),i=Cy(e),o=r?i.indexOf(r):-1,a=((u=(l=n[o])==null?void 0:l.current)==null?void 0:u.id)??null,s=((f=(c=n[o+1])==null?void 0:c.current)==null?void 0:f.id)??null;return[a,s]}function zt(e){return Array.from(e.values()).sort((t,n)=>{const r=t.current.order,i=n.current.order;return r==null&&i==null?0:r==null?-1:i==null?1:r-i})}function Qm(e,t,n,r){var c;const i=n+t,{collapsedSize:o,collapsible:a,maxSize:s,minSize:l}=e.current;if(a){if(n>o){if(i<=l/2+o)return o}else if(!((c=r==null?void 0:r.type)==null?void 0:c.startsWith("key"))&&i{const{direction:a,panels:s}=e.current,l=Ip(t),{height:u,width:c}=l.getBoundingClientRect(),d=Cy(t).map(h=>{const y=h.getAttribute("data-panel-resize-handle-id"),m=zt(s),[w,p]=Mp(t,y,m);if(w==null||p==null)return()=>{};let v=0,g=100,S=0,_=0;m.forEach($=>{$.current.id===w?(g=$.current.maxSize,v=$.current.minSize):(S+=$.current.minSize,_+=$.current.maxSize)});const x=Math.min(g,100-S),E=Math.max(v,(m.length-1)*100-_),C=_y(s,w,i);h.setAttribute("aria-valuemax",""+Math.round(x)),h.setAttribute("aria-valuemin",""+Math.round(E)),h.setAttribute("aria-valuenow",""+Math.round(parseInt(C)));const k=$=>{if(!$.defaultPrevented)switch($.key){case"Enter":{$.preventDefault();const j=m.findIndex(U=>U.current.id===w);if(j>=0){const U=m[j],z=i[j];if(z!=null){let L=0;z.toPrecision(Wr)<=U.current.minSize.toPrecision(Wr)?L=a==="horizontal"?c:u:L=-(a==="horizontal"?c:u);const M=bo($,s,w,p,L,i,o.current,null);i!==M&&r(M)}}break}}};h.addEventListener("keydown",k);const P=x4(w);return P!=null&&h.setAttribute("aria-controls",P.id),()=>{h.removeAttribute("aria-valuemax"),h.removeAttribute("aria-valuemin"),h.removeAttribute("aria-valuenow"),h.removeEventListener("keydown",k),P!=null&&h.removeAttribute("aria-controls")}});return()=>{d.forEach(h=>h())}},[e,t,n,o,r,i])}function k4({disabled:e,handleId:t,resizeHandler:n}){Nn(()=>{if(e||n==null)return;const r=Cu(t);if(r==null)return;const i=o=>{if(!o.defaultPrevented)switch(o.key){case"ArrowDown":case"ArrowLeft":case"ArrowRight":case"ArrowUp":case"End":case"Home":{o.preventDefault(),n(o);break}case"F6":{o.preventDefault();const a=xy(),s=C4(t);Oy(s!==null);const l=o.shiftKey?s>0?s-1:a.length-1:s+1{r.removeEventListener("keydown",i)}},[e,t,n])}function A4(e,t){if(e.length!==t.length)return!1;for(let n=0;nE.current.id===S),x=r[_];if(x.current.collapsible){const E=c[_];(E===0||E.toPrecision(Wr)===x.current.minSize.toPrecision(Wr))&&(p=p<0?-x.current.minSize*y:x.current.minSize*y)}return p}else return ky(e,n,i,s,l)}function I4(e){return e.type==="keydown"}function qf(e){return e.type.startsWith("mouse")}function Kf(e){return e.type.startsWith("touch")}let Gf=null,$r=null;function Ay(e){switch(e){case"horizontal":return"ew-resize";case"horizontal-max":return"w-resize";case"horizontal-min":return"e-resize";case"vertical":return"ns-resize";case"vertical-max":return"n-resize";case"vertical-min":return"s-resize"}}function M4(){$r!==null&&(document.head.removeChild($r),Gf=null,$r=null)}function Cc(e){if(Gf===e)return;Gf=e;const t=Ay(e);$r===null&&($r=document.createElement("style"),document.head.appendChild($r)),$r.innerHTML=`*{cursor: ${t}!important;}`}function L4(e,t=10){let n=null;return(...i)=>{n!==null&&clearTimeout(n),n=setTimeout(()=>{e(...i)},t)}}function Py(e){return e.map(t=>{const{minSize:n,order:r}=t.current;return r?`${r}:${n}`:`${n}`}).sort((t,n)=>t.localeCompare(n)).join(",")}function Iy(e,t){try{const n=t.getItem(`PanelGroup:sizes:${e}`);if(n){const r=JSON.parse(n);if(typeof r=="object"&&r!=null)return r}}catch{}return null}function T4(e,t,n){const r=Iy(e,n);if(r){const i=Py(t);return r[i]??null}return null}function D4(e,t,n,r){const i=Py(t),o=Iy(e,r)||{};o[i]=n;try{r.setItem(`PanelGroup:sizes:${e}`,JSON.stringify(o))}catch(a){console.error(a)}}const Oc={};function Ym(e){try{if(typeof localStorage<"u")e.getItem=t=>localStorage.getItem(t),e.setItem=(t,n)=>{localStorage.setItem(t,n)};else throw new Error("localStorage not supported in this environment")}catch(t){console.error(t),e.getItem=()=>null,e.setItem=()=>{}}}const Eo={getItem:e=>(Ym(Eo),Eo.getItem(e)),setItem:(e,t)=>{Ym(Eo),Eo.setItem(e,t)}};function My({autoSaveId:e,children:t=null,className:n="",direction:r,disablePointerEventsDuringResize:i=!1,forwardedRef:o,id:a=null,onLayout:s,storage:l=Eo,style:u={},tagName:c="div"}){const f=Pp(a),[d,h]=Fo(null),[y,m]=Fo(new Map),w=kt(null);kt({didLogDefaultSizeWarning:!1,didLogIdAndOrderWarning:!1,prevPanelIds:[]});const p=kt({onLayout:s});Nn(()=>{p.current.onLayout=s});const v=kt({}),[g,S]=Fo([]),_=kt(new Map),x=kt(0),E=kt({direction:r,panels:y,sizes:g});by(o,()=>({getLayout:()=>{const{sizes:D}=E.current;return D},setLayout:D=>{const A=D.reduce((V,T)=>V+T,0);Oy(A===100,"Panel sizes must add up to 100%");const{panels:I}=E.current,F=v.current,R=zt(I);S(D),ii(R,D,F)}}),[]),hl(()=>{E.current.direction=r,E.current.panels=y,E.current.sizes=g}),O4({committedValuesRef:E,groupId:f,panels:y,setSizes:S,sizes:g,panelSizeBeforeCollapse:_}),Nn(()=>{const{onLayout:D}=p.current,{panels:A,sizes:I}=E.current;if(I.length>0){D&&D(I);const F=v.current,R=zt(A);ii(R,I,F)}},[g]),hl(()=>{if(E.current.sizes.length===y.size)return;let A=null;if(e){const I=zt(y);A=T4(e,I,l)}if(A!=null)S(A);else{const I=zt(y);let F=0,R=0,V=0;if(I.forEach(T=>{V+=T.current.minSize,T.current.defaultSize===null?F++:R+=T.current.defaultSize}),R>100)throw new Error("Default panel sizes cannot exceed 100%");if(I.length>1&&F===0&&R!==100)throw new Error("Invalid default sizes specified for panels");if(V>100)throw new Error("Minimum panel sizes cannot exceed 100%");S(I.map(T=>T.current.defaultSize===null?(100-R)/F:T.current.defaultSize))}},[e,y,l]),Nn(()=>{if(e){if(g.length===0||g.length!==y.size)return;const D=zt(y);Oc[e]||(Oc[e]=L4(D4,100)),Oc[e](e,D,g,l)}},[e,y,g,l]);const C=Jn((D,A)=>{const{panels:I}=E.current;return I.size===0?{flexBasis:0,flexGrow:A??void 0,flexShrink:1,overflow:"hidden"}:{flexBasis:0,flexGrow:_y(I,D,g),flexShrink:1,overflow:"hidden",pointerEvents:i&&d!==null?"none":void 0}},[d,i,g]),k=Jn((D,A)=>{m(I=>{if(I.has(D))return I;const F=new Map(I);return F.set(D,A),F})},[]),P=Jn(D=>I=>{I.preventDefault();const{direction:F,panels:R,sizes:V}=E.current,T=zt(R),[N,H]=Mp(f,D,T);if(N==null||H==null)return;let W=P4(I,f,D,T,F,V,w.current);if(W===0)return;const oe=Ip(f).getBoundingClientRect(),Ie=F==="horizontal";document.dir==="rtl"&&Ie&&(W=-W);const xe=Ie?oe.width:oe.height,be=W/xe*100,Ce=bo(I,R,N,H,be,V,_.current,w.current),Zt=!A4(V,Ce);if((qf(I)||Kf(I))&&x.current!=be&&Cc(Zt?Ie?"horizontal":"vertical":Ie?W<0?"horizontal-min":"horizontal-max":W<0?"vertical-min":"vertical-max"),Zt){const _t=v.current;S(Ce),ii(T,Ce,_t)}x.current=be},[f]),$=Jn(D=>{m(A=>{if(!A.has(D))return A;const I=new Map(A);return I.delete(D),I})},[]),j=Jn(D=>{const{panels:A,sizes:I}=E.current,F=A.get(D);if(F==null)return;const{collapsedSize:R,collapsible:V}=F.current;if(!V)return;const T=zt(A),N=T.indexOf(F);if(N<0)return;const H=I[N];if(H===R)return;_.current.set(D,H);const[W,X]=xc(D,T);if(W==null||X==null)return;const Ie=N===T.length-1?H:R-H,xe=bo(null,A,W,X,Ie,I,_.current,null);if(I!==xe){const be=v.current;S(xe),ii(T,xe,be)}},[]),U=Jn(D=>{const{panels:A,sizes:I}=E.current,F=A.get(D);if(F==null)return;const{collapsedSize:R,minSize:V}=F.current,T=_.current.get(D)||V;if(!T)return;const N=zt(A),H=N.indexOf(F);if(H<0||I[H]!==R)return;const[X,oe]=xc(D,N);if(X==null||oe==null)return;const xe=H===N.length-1?R-T:T,be=bo(null,A,X,oe,xe,I,_.current,null);if(I!==be){const Ce=v.current;S(be),ii(N,be,Ce)}},[]),z=Jn((D,A)=>{const{panels:I,sizes:F}=E.current,R=I.get(D);if(R==null)return;const{collapsedSize:V,collapsible:T,maxSize:N,minSize:H}=R.current,W=zt(I),X=W.indexOf(R);if(X<0)return;const oe=F[X];if(oe===A)return;T&&A===V||(A=Math.min(N,Math.max(H,A)));const[Ie,xe]=xc(D,W);if(Ie==null||xe==null)return;const Ce=X===W.length-1?oe-A:A-oe,Zt=bo(null,I,Ie,xe,Ce,F,_.current,null);if(F!==Zt){const _t=v.current;S(Zt),ii(W,Zt,_t)}},[]),L=b4(()=>({activeHandleId:d,collapsePanel:j,direction:r,expandPanel:U,getPanelStyle:C,groupId:f,registerPanel:k,registerResizeHandle:P,resizePanel:z,startDragging:(D,A)=>{if(h(D),qf(A)||Kf(A)){const I=Cu(D);w.current={dragHandleRect:I.getBoundingClientRect(),dragOffset:ky(A,D,r),sizes:E.current.sizes}}},stopDragging:()=>{M4(),h(null),w.current=null},unregisterPanel:$}),[d,j,r,U,C,f,k,P,z,$]),M={display:"flex",flexDirection:r==="horizontal"?"row":"column",height:"100%",overflow:"hidden",width:"100%"};return Bi(xu.Provider,{children:Bi(c,{children:t,className:n,"data-panel-group":"","data-panel-group-direction":r,"data-panel-group-id":f,style:{...M,...u}}),value:L})}const Ly=wy((e,t)=>Bi(My,{...e,forwardedRef:t}));My.displayName="PanelGroup";Ly.displayName="forwardRef(PanelGroup)";function Qf({children:e=null,className:t="",disabled:n=!1,id:r=null,onDragging:i,style:o={},tagName:a="div"}){const s=kt(null),l=kt({onDragging:i});Nn(()=>{l.current.onDragging=i});const u=Sy(xu);if(u===null)throw Error("PanelResizeHandle components must be rendered within a PanelGroup container");const{activeHandleId:c,direction:f,groupId:d,registerResizeHandle:h,startDragging:y,stopDragging:m}=u,w=Pp(r),p=c===w,[v,g]=Fo(!1),[S,_]=Fo(null),x=Jn(()=>{s.current.blur(),m();const{onDragging:k}=l.current;k&&k(!1)},[m]);Nn(()=>{if(n)_(null);else{const C=h(w);_(()=>C)}},[n,w,h]),Nn(()=>{if(n||S==null||!p)return;const C=j=>{S(j)},k=j=>{S(j)},$=s.current.ownerDocument;return $.body.addEventListener("contextmenu",x),$.body.addEventListener("mousemove",C),$.body.addEventListener("touchmove",C),$.body.addEventListener("mouseleave",k),window.addEventListener("mouseup",x),window.addEventListener("touchend",x),()=>{$.body.removeEventListener("contextmenu",x),$.body.removeEventListener("mousemove",C),$.body.removeEventListener("touchmove",C),$.body.removeEventListener("mouseleave",k),window.removeEventListener("mouseup",x),window.removeEventListener("touchend",x)}},[f,n,p,S,x]),k4({disabled:n,handleId:w,resizeHandler:S});const E={cursor:Ay(f),touchAction:"none",userSelect:"none"};return Bi(a,{children:e,className:t,"data-resize-handle-active":p?"pointer":v?"keyboard":void 0,"data-panel-group-direction":f,"data-panel-group-id":d,"data-panel-resize-handle-enabled":!n,"data-panel-resize-handle-id":w,onBlur:()=>g(!1),onFocus:()=>g(!0),onMouseDown:C=>{y(w,C.nativeEvent);const{onDragging:k}=l.current;k&&k(!0)},onMouseUp:x,onTouchCancel:x,onTouchEnd:x,onTouchStart:C=>{y(w,C.nativeEvent);const{onDragging:k}=l.current;k&&k(!0)},ref:s,role:"separator",style:{...E,...o},tabIndex:0})}Qf.displayName="PanelResizeHandle";var Jm={},$4=function(e,t,n,r,i){var o=new Worker(Jm[t]||(Jm[t]=URL.createObjectURL(new Blob([e+';addEventListener("error",function(e){e=e.error;postMessage({$e$:[e.message,e.code,e.stack]})})'],{type:"text/javascript"}))));return o.onmessage=function(a){var s=a.data,l=s.$e$;if(l){var u=new Error(l[0]);u.code=l[1],u.stack=l[2],i(u,null)}else i(null,s)},o.postMessage(n,r),o},ye=Uint8Array,at=Uint16Array,Ji=Uint32Array,Zi=new ye([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),Xi=new ye([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),aa=new ye([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),Ty=function(e,t){for(var n=new at(31),r=0;r<31;++r)n[r]=t+=1<>>1|(we&21845)<<1;Yn=(Yn&52428)>>>2|(Yn&13107)<<2,Yn=(Yn&61680)>>>4|(Yn&3855)<<4,sa[we]=((Yn&65280)>>>8|(Yn&255)<<8)>>>1}var qt=function(e,t,n){for(var r=e.length,i=0,o=new at(t);i>>l]=u}else for(s=new at(r),i=0;i>>15-e[i]);return s},Wn=new ye(288);for(var we=0;we<144;++we)Wn[we]=8;for(var we=144;we<256;++we)Wn[we]=9;for(var we=256;we<280;++we)Wn[we]=7;for(var we=280;we<288;++we)Wn[we]=8;var Ui=new ye(32);for(var we=0;we<32;++we)Ui[we]=5;var Fy=qt(Wn,9,0),Ry=qt(Wn,9,1),Ny=qt(Ui,5,0),zy=qt(Ui,5,1),As=function(e){for(var t=e[0],n=1;nt&&(t=e[n]);return t},Rt=function(e,t,n){var r=t/8|0;return(e[r]|e[r+1]<<8)>>(t&7)&n},Ps=function(e,t){var n=t/8|0;return(e[n]|e[n+1]<<8|e[n+2]<<16)>>(t&7)},ba=function(e){return(e+7)/8|0},Yr=function(e,t,n){(t==null||t<0)&&(t=0),(n==null||n>e.length)&&(n=e.length);var r=new(e.BYTES_PER_ELEMENT==2?at:e.BYTES_PER_ELEMENT==4?Ji:ye)(n-t);return r.set(e.subarray(t,n)),r},Vy=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],Be=function(e,t,n){var r=new Error(t||Vy[e]);if(r.code=e,Error.captureStackTrace&&Error.captureStackTrace(r,Be),!n)throw r;return r},By=function(e,t,n){var r=e.length;if(!r||n&&n.f&&!n.l)return t||new ye(0);var i=!t||n,o=!n||n.i;n||(n={}),t||(t=new ye(r*3));var a=function(W){var X=t.length;if(W>X){var oe=new ye(Math.max(X*2,W));oe.set(t),t=oe}},s=n.f||0,l=n.p||0,u=n.b||0,c=n.l,f=n.d,d=n.m,h=n.n,y=r*8;do{if(!c){s=Rt(e,l,1);var m=Rt(e,l+1,3);if(l+=3,m)if(m==1)c=Ry,f=zy,d=9,h=5;else if(m==2){var g=Rt(e,l,31)+257,S=Rt(e,l+10,15)+4,_=g+Rt(e,l+5,31)+1;l+=14;for(var x=new ye(_),E=new ye(19),C=0;C>>4;if(w<16)x[C++]=w;else{var U=0,z=0;for(w==16?(z=3+Rt(e,l,3),l+=2,U=x[C-1]):w==17?(z=3+Rt(e,l,7),l+=3):w==18&&(z=11+Rt(e,l,127),l+=7);z--;)x[C++]=U}}var L=x.subarray(0,g),M=x.subarray(g);d=As(L),h=As(M),c=qt(L,d,1),f=qt(M,h,1)}else Be(1);else{var w=ba(l)+4,p=e[w-4]|e[w-3]<<8,v=w+p;if(v>r){o&&Be(0);break}i&&a(u+p),t.set(e.subarray(w,v),u),n.b=u+=p,n.p=l=v*8,n.f=s;continue}if(l>y){o&&Be(0);break}}i&&a(u+131072);for(var D=(1<>>4;if(l+=U&15,l>y){o&&Be(0);break}if(U||Be(2),F<256)t[u++]=F;else if(F==256){I=l,c=null;break}else{var R=F-254;if(F>264){var C=F-257,V=Zi[C];R=Rt(e,l,(1<>>4;T||Be(3),l+=T&15;var M=jy[N];if(N>3){var V=Xi[N];M+=Ps(e,l)&(1<y){o&&Be(0);break}i&&a(u+131072);for(var H=u+R;u>>8},si=function(e,t,n){n<<=t&7;var r=t/8|0;e[r]|=n,e[r+1]|=n>>>8,e[r+2]|=n>>>16},Is=function(e,t){for(var n=[],r=0;rd&&(d=o[r].s);var h=new at(d+1),y=vl(n[c-1],h,0);if(y>t){var r=0,m=0,w=y-t,p=1<t)m+=p-(1<>>=w;m>0;){var g=o[r].s;h[g]=0&&m;--r){var S=o[r].s;h[S]==t&&(--h[S],++m)}y=t}return[new ye(h),y]},vl=function(e,t,n){return e.s==-1?Math.max(vl(e.l,t,n+1),vl(e.r,t,n+1)):t[e.s]=n},Jf=function(e){for(var t=e.length;t&&!e[--t];);for(var n=new at(++t),r=0,i=e[0],o=1,a=function(l){n[r++]=l},s=1;s<=t;++s)if(e[s]==i&&s!=t)++o;else{if(!i&&o>2){for(;o>138;o-=138)a(32754);o>2&&(a(o>10?o-11<<5|28690:o-3<<5|12305),o=0)}else if(o>3){for(a(i),--o;o>6;o-=6)a(8304);o>2&&(a(o-3<<5|8208),o=0)}for(;o--;)a(i);o=1,i=e[s]}return[n.subarray(0,r),t]},li=function(e,t){for(var n=0,r=0;r>>8,e[i+2]=e[i]^255,e[i+3]=e[i+1]^255;for(var o=0;o4&&!P[aa[j-1]];--j);var U=u+5<<3,z=li(i,Wn)+li(o,Ui)+a,L=li(i,d)+li(o,m)+a+14+3*j+li(E,P)+(2*E[16]+3*E[17]+7*E[18]);if(U<=z&&U<=L)return gl(t,c,e.subarray(l,l+u));var M,D,A,I;if(yn(t,c,1+(L15&&(yn(t,c,T[C]>>>5&127),c+=T[C]>>>12)}}else M=Fy,D=Wn,A=Ny,I=Ui;for(var C=0;C255){var N=r[C]>>>18&31;si(t,c,M[N+257]),c+=D[N+257],N>7&&(yn(t,c,r[C]>>>23&31),c+=Zi[N]);var H=r[C]&31;si(t,c,A[H]),c+=I[H],H>3&&(si(t,c,r[C]>>>5&8191),c+=Xi[H])}else si(t,c,M[r[C]]),c+=D[r[C]];return si(t,c,M[256]),c+D[256]},Uy=new Ji([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),Ou=new ye(0),Hy=function(e,t,n,r,i,o){var a=e.length,s=new ye(r+a+5*(1+Math.ceil(a/7e3))+i),l=s.subarray(r,s.length-i),u=0;if(!t||a<8)for(var c=0;c<=a;c+=65535){var f=c+65535;f>=a&&(l[u>>3]=o),u=gl(l,u+1,e.subarray(c,f))}else{for(var d=Uy[t-1],h=d>>>13,y=d&8191,m=(1<7e3||P>24576)&&M>423){u=Zf(e,l,0,_,x,E,k,P,j,c-j,u),P=C=k=0,j=c;for(var D=0;D<286;++D)x[D]=0;for(var D=0;D<30;++D)E[D]=0}var A=2,I=0,F=y,R=z-L&32767;if(M>2&&U==S(c-R))for(var V=Math.min(h,M)-1,T=Math.min(32767,c),N=Math.min(258,M);R<=T&&--F&&z!=L;){if(e[c+A]==e[c+A-R]){for(var H=0;HA){if(A=H,I=R,H>V)break;for(var W=Math.min(R,H-2),X=0,D=0;DX&&(X=xe,L=oe)}}}z=L,L=w[z],R+=z-L+32768&32767}if(I){_[P++]=268435456|ml[A]<<18|Yf[I];var be=ml[A]&31,Ce=Yf[I]&31;k+=Zi[be]+Xi[Ce],++x[257+be],++E[Ce],$=c+A,++C}else _[P++]=e[c],++x[e[c]]}}u=Zf(e,l,o,_,x,E,k,P,j,c-j,u),!o&&u&7&&(u=gl(l,u+1,Ou))}return Yr(s,0,r+ba(u)+i)},j4=function(){for(var e=new Int32Array(256),t=0;t<256;++t){for(var n=t,r=9;--r;)n=(n&1&&-306674912)^n>>>1;e[t]=n}return e}(),F4=function(){var e=-1;return{p:function(t){for(var n=e,r=0;r>>8;e=n},d:function(){return~e}}},Wy=function(e,t,n,r,i){return Hy(e,t.level==null?6:t.level,t.mem==null?Math.ceil(Math.max(8,Math.min(13,Math.log(e.length)))*1.5):12+t.mem,n,r,!i)},Tp=function(e,t){var n={};for(var r in e)n[r]=e[r];for(var r in t)n[r]=t[r];return n},Zm=function(e,t,n){for(var r=e(),i=e.toString(),o=i.slice(i.indexOf("[")+1,i.lastIndexOf("]")).replace(/\s+/g,"").split(","),a=0;a>>0},kc=function(e,t){return on(e,t)+on(e,t+4)*4294967296},Qe=function(e,t,n){for(;n;++t)e[t]=n,n>>>=8};function B4(e,t,n){return n||(n=t,t={}),typeof n!="function"&&Be(7),Ky(e,t,[V4],function(r){return ku(Dp(r.data[0],r.data[1]))},0,n)}function Dp(e,t){return Wy(e,t||{},0,0)}function U4(e,t,n){return n||(n=t,t={}),typeof n!="function"&&Be(7),Ky(e,t,[z4],function(r){return ku($p(r.data[0],qy(r.data[1])))},1,n)}function $p(e,t){return By(e,t)}var Gy=function(e,t,n,r){for(var i in e){var o=e[i],a=t+i,s=r;Array.isArray(o)&&(s=Tp(r,o[1]),o=o[0]),o instanceof ye?n[a]=[o,s]:(n[a+="/"]=[new ye(0),s],Gy(o,a,n,r))}},Xm=typeof TextEncoder<"u"&&new TextEncoder,Xf=typeof TextDecoder<"u"&&new TextDecoder,H4=0;try{Xf.decode(Ou,{stream:!0}),H4=1}catch{}var W4=function(e){for(var t="",n=0;;){var r=e[n++],i=(r>127)+(r>223)+(r>239);if(n+i>e.length)return[t,Yr(e,n-1)];i?i==3?(r=((r&15)<<18|(e[n++]&63)<<12|(e[n++]&63)<<6|e[n++]&63)-65536,t+=String.fromCharCode(55296|r>>10,56320|r&1023)):i&1?t+=String.fromCharCode((r&31)<<6|e[n++]&63):t+=String.fromCharCode((r&15)<<12|(e[n++]&63)<<6|e[n++]&63):t+=String.fromCharCode(r)}};function Ei(e,t){if(t){for(var n=new ye(e.length),r=0;r>1)),a=0,s=function(c){o[a++]=c},r=0;ro.length){var l=new ye(a+8+(i-r<<1));l.set(o),o=l}var u=e.charCodeAt(r);u<128||t?s(u):u<2048?(s(192|u>>6),s(128|u&63)):u>55295&&u<57344?(u=65536+(u&1047552)|e.charCodeAt(++r)&1023,s(240|u>>18),s(128|u>>12&63),s(128|u>>6&63),s(128|u&63)):(s(224|u>>12),s(128|u>>6&63),s(128|u&63))}return Yr(o,0,a)}function ed(e,t){if(t){for(var n="",r=0;r65535&&Be(9),t+=r+4}return t},ev=function(e,t,n,r,i,o,a,s){var l=r.length,u=n.extra,c=s&&s.length,f=td(u);Qe(e,t,a!=null?33639248:67324752),t+=4,a!=null&&(e[t++]=20,e[t++]=n.os),e[t]=20,t+=2,e[t++]=n.flag<<1|(o<0&&8),e[t++]=i&&8,e[t++]=n.compression&255,e[t++]=n.compression>>8;var d=new Date(n.mtime==null?Date.now():n.mtime),h=d.getFullYear()-1980;if((h<0||h>119)&&Be(10),Qe(e,t,h<<25|d.getMonth()+1<<21|d.getDate()<<16|d.getHours()<<11|d.getMinutes()<<5|d.getSeconds()>>>1),t+=4,o!=-1&&(Qe(e,t,n.crc),Qe(e,t+4,o<0?-o-2:o),Qe(e,t+8,n.size)),Qe(e,t+12,l),Qe(e,t+14,f),t+=16,a!=null&&(Qe(e,t,c),Qe(e,t+6,n.attrs),Qe(e,t+10,a),t+=14),e.set(r,t),t+=l,f)for(var y in u){var m=u[y],w=m.length;Qe(e,t,+y),Qe(e,t+2,w),e.set(m,t+4),t+=4+w}return c&&(e.set(s,t),t+=c),t},Q4=function(e,t,n,r,i){Qe(e,t,101010256),Qe(e,t+8,n),Qe(e,t+10,n),Qe(e,t+12,r),Qe(e,t+16,i)};function Y4(e,t,n){n||(n=t,t={}),typeof n!="function"&&Be(7);var r={};Gy(e,"",r,t);var i=Object.keys(r),o=i.length,a=0,s=0,l=o,u=new Array(o),c=[],f=function(){for(var w=0;w65535&&z(Be(11,0,1),null),!U)z(null,g);else if(x<16e4)try{z(null,Dp(g,S))}catch(L){z(L,null)}else c.push(B4(g,S,z))},m=0;m65558)return a(Be(13,0,1),null),i;var l=_n(e,s+8);if(l){var u=l,c=on(e,s+16),f=c==4294967295||u==65535;if(f){var d=on(e,s-12);f=on(e,d)==101075792,f&&(u=l=on(e,d+32),c=on(e,d+48))}for(var h=t&&t.filter,y=function(w){var p=K4(e,c,f),v=p[0],g=p[1],S=p[2],_=p[3],x=p[4],E=p[5],C=q4(e,E);c=x;var k=function($,j){$?(i(),a($,null)):(j&&(o[_]=j),--l||a(null,o))};if(!h||h({name:_,size:g,originalSize:S,compression:v}))if(!v)k(null,Yr(e,C,C+g));else if(v==8){var P=e.subarray(C,C+g);if(g<32e4)try{k(null,$p(P,new ye(S)))}catch($){k($,null)}else r.push(U4(P,{size:S},k))}else k(Be(14,"unknown compression type "+v,1),null);else k(null,null)},m=0;m{if(n.path){const r=n.path.map(({key:i})=>i).join(".");t.nested[r]=[...t.nested[r]||[],n.message]}else t.root=[...t.root||[],n.message];return t},{nested:{}})}var et=class extends Error{constructor(t){super(t[0].message);ee(this,"issues");this.name="ValiError",this.issues=t}};function Jr(e,t,n){let r=e;const i=[];if(t.forEach(o=>{try{r=o(r,n)}catch(a){if(n.abortEarly||n.abortPipeEarly)throw a;i.push(...a.issues)}}),i.length)throw new et(i);return r}function la(e,t){return[...(e==null?void 0:e.path)||[],t]}function pn(e,t){const[n,r=[]]=!e||typeof e=="string"?[e,t]:[void 0,e];return{error:n,pipe:r}}function Z4(e,t,n){const{error:r,pipe:i}=pn(t,n);return{schema:"array",array:{item:e},async:!1,parse(o,a){if(!Array.isArray(o))throw new et([{reason:"type",validation:"array",origin:"value",message:r||"Invalid type",input:o,...a}]);const s=[],l=[];if(o.forEach((u,c)=>{try{s.push(e.parse(u,{...a,path:la(a,{schema:"array",input:o,key:c,value:u})}))}catch(f){if(a!=null&&a.abortEarly)throw f;l.push(...f.issues)}}),l.length)throw new et(l);return Jr(s,i,{...a,reason:"array"})}}}function Ac(e,t){const{error:n,pipe:r}=pn(e,t);return{schema:"boolean",async:!1,parse(i,o){if(typeof i!="boolean")throw new et([{reason:"type",validation:"boolean",origin:"value",message:n||"Invalid type",input:i,...o}]);return Jr(i,r,{...o,reason:"boolean"})}}}function nv(e,t){return{schema:"literal",literal:e,async:!1,parse(n,r){if(n!==e)throw new et([{reason:"type",validation:"literal",origin:"value",message:t||"Invalid type",input:n,...r}]);return n}}}function X4(e,t){return{schema:"native_enum",nativeEnum:e,async:!1,parse(n,r){if(!Object.values(e).includes(n))throw new et([{reason:"type",validation:"native_enum",origin:"value",message:t||"Invalid type",input:n,...r}]);return n}}}function Cn(e,t){const{error:n,pipe:r}=pn(e,t);return{schema:"number",async:!1,parse(i,o){if(typeof i!="number")throw new et([{reason:"type",validation:"number",origin:"value",message:n||"Invalid type",input:i,...o}]);return Jr(i,r,{...o,reason:"number"})}}}function Yt(e,t,n){const{error:r,pipe:i}=pn(t,n);return{schema:"object",object:e,async:!1,parse(o,a){if(!o||typeof o!="object"||o.toString()!=="[object Object]")throw new et([{reason:"type",validation:"object",origin:"value",message:r||"Invalid type",input:o,...a}]);const s={},l=[];if(Object.entries(e).forEach(([u,c])=>{try{const f=o[u];s[u]=c.parse(f,{...a,path:la(a,{schema:"object",input:o,key:u,value:f})})}catch(f){if(a!=null&&a.abortEarly)throw f;l.push(...f.issues)}}),l.length)throw new et(l);return Jr(s,i,{...a,reason:"object"})}}}function Re(e){return{schema:"optional",wrapped:e,async:!1,parse(t,n){return t===void 0?t:e.parse(t,n)}}}function An(e,t){const{error:n,pipe:r}=pn(e,t);return{schema:"string",async:!1,parse(i,o){if(typeof i!="string")throw new et([{reason:"type",validation:"string",origin:"value",message:n||"Invalid type",input:i,...o}]);return Jr(i,r,{...o,reason:"string"})}}}function ex(e,t,n,r){const{key:i,value:o,error:a,pipe:s}=typeof t=="object"&&!Array.isArray(t)?{key:e,value:t,...pn(n,r)}:{key:An(),value:e,...pn(t,n)};return{schema:"record",record:{key:i,value:o},async:!1,parse(l,u){if(!l||typeof l!="object"||l.toString()!=="[object Object]")throw new et([{reason:"type",validation:"record",origin:"value",message:a||"Invalid type",input:l,...u}]);const c={},f=[];if(Object.entries(l).forEach(([d,h])=>{const y=la(u,{schema:"record",input:l,key:d,value:h});let m;try{m=i.parse(d,{...u,origin:"key",path:y})}catch(p){if(u!=null&&u.abortEarly)throw p;f.push(...p.issues)}let w;try{w=[o.parse(h,{...u,path:y})]}catch(p){if(u!=null&&u.abortEarly)throw p;f.push(...p.issues)}m&&w&&(c[m]=w[0])}),f.length)throw new et(f);return Jr(c,s,{...u,reason:"record"})}}}function rv(e,t,n,r){const{rest:i,error:o,pipe:a}=typeof t=="object"&&!Array.isArray(t)?{rest:t,...pn(n,r)}:pn(t,n);return{schema:"tuple",tuple:{items:e,rest:i},async:!1,parse(s,l){if(!Array.isArray(s)||!i&&e.length!==s.length||i&&e.length>s.length)throw new et([{reason:"type",validation:"tuple",origin:"value",message:o||"Invalid type",input:s,...l}]);const u=[],c=[];if(e.forEach((f,d)=>{try{const h=s[d];u[d]=f.parse(h,{...l,path:la(l,{schema:"tuple",input:s,key:d,value:h})})}catch(h){if(l!=null&&l.abortEarly)throw h;c.push(...h.issues)}}),i&&s.slice(e.length).forEach((f,d)=>{try{const h=e.length+d;u[h]=i.parse(f,{...l,path:la(l,{schema:"tuple",input:s,key:h,value:f})})}catch(h){if(l!=null&&l.abortEarly)throw h;c.push(...h.issues)}}),c.length)throw new et(c);return Jr(u,a,{...l,reason:"tuple"})}}}function nd(e,t){return{schema:"union",union:e,async:!1,parse(n,r){let i;const o=[];for(const a of e)try{i=[a.parse(n,r)];break}catch(s){o.push(...s.issues)}if(!i)throw new et([{reason:"type",validation:"union",origin:"value",message:t||"Invalid type",input:n,issues:o,...r}]);return i[0]}}}function Ea(e,t,n){const{error:r,pipe:i}=pn(t,n);return Yt(e.reduce((o,a)=>({...o,...a.object}),{}),r,i)}function tx(e,t,n,r){const{error:i,pipe:o}=pn(n,r);return Yt(Object.entries(e.object).reduce((a,[s,l])=>t.includes(s)?a:{...a,[s]:l},{}),i,o)}function iv(e,t,n){try{return{success:!0,data:e.parse(t,n)}}catch(r){return{success:!1,error:r}}}function rd(e,t){return(n,r)=>{if(n>e)throw new et([{validation:"max_value",origin:"value",message:t||"Invalid value",input:n,...r}]);return n}}function id(e,t){return(n,r)=>{if(nt in e?jp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_a=(e,t)=>function(){return t||(0,e[Qy(e)[0]])((t={exports:{}}).exports,t),t.exports},sx=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Qy(t))!ox.call(e,i)&&i!==n&&jp(e,i,{get:()=>t[i],enumerable:!(r=rx(t,i))||r.enumerable});return e},lx=(e,t,n)=>(n=e!=null?nx(ix(e)):{},sx(t||!e||!e.__esModule?jp(n,"default",{value:e,enumerable:!0}):n,e)),te=(e,t,n)=>(ax(e,typeof t!="symbol"?t+"":t,n),n),ux=_a({"../../node_modules/.pnpm/@rgba-image+copy@0.1.3/node_modules/@rgba-image/copy/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.copy=void 0;var t=(n,r,i=0,o=0,a=n.width-i,s=n.height-o,l=0,u=0)=>{if(i=i|0,o=o|0,a=a|0,s=s|0,l=l|0,u=u|0,a<=0||s<=0)return;const c=new Uint32Array(n.data.buffer),f=new Uint32Array(r.data.buffer);for(let d=0;d=n.height)continue;const y=u+d;if(!(y<0||y>=r.height))for(let m=0;m=n.width)continue;const p=l+m;if(p<0||p>=r.width)continue;const v=h*n.width+w,g=y*r.width+p;f[g]=c[v]}}};e.copy=t}}),cx=_a({"../../node_modules/.pnpm/@rgba-image+create-image@0.1.1/node_modules/@rgba-image/create-image/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CreateImageFactory=(t=[0,0,0,0],n=4)=>{if(n=Math.floor(n),isNaN(n)||n<1)throw TypeError("channels should be a positive non-zero number");if(!("length"in t)||t.lengtho===0);return(o,a,s)=>{if(o===void 0||a===void 0)throw TypeError("Not enough arguments");if(o=Math.floor(o),a=Math.floor(a),isNaN(o)||o<1||isNaN(a)||a<1)throw TypeError("Index or size is negative or greater than the allowed amount");const l=o*a*n;if(s===void 0&&(s=new Uint8ClampedArray(l)),s instanceof Uint8ClampedArray){if(s.length!==l)throw TypeError("Index or size is negative or greater than the allowed amount");if(!r)for(let u=0;u{if(o<=-a||o>=a||o==0)return 0;const s=o*Math.PI;return Math.sin(s)/s*Math.sin(s/a)/(s/a)},r=o=>Math.round(o*((1<{const c=u?2:3,f=1/s,d=Math.min(1,s),h=c/d,y=Math.floor((h+1)*2),m=new Int16Array((y+2)*a);let w=0;for(let p=0;p>1]+=r(1-P);let $=0;for(;$0&&E[j]===0;)j--;const U=g+$,z=j-$+1;m[w++]=U,m[w++]=z,m.set(E.subarray($,j+1),w),w+=z}return m};e.filters=i}}),dx=_a({"../../node_modules/.pnpm/@rgba-image+lanczos@0.1.1/node_modules/@rgba-image/lanczos/dist/convolve.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.convolve=void 0;var t=14,n=(r,i,o,a,s,l)=>{let u=0,c=0;for(let f=0;f0;S--){const _=l[d++];w=w+_*r[m]|0,p=p+_*r[m+1]|0,v=v+_*r[m+2]|0,g=g+_*r[m+3]|0,m=m+4|0}i[c]=w+8192>>t,i[c+1]=p+8192>>t,i[c+2]=v+8192>>t,i[c+3]=g+8192>>t,c=c+a*4|0}c=(f+1)*4|0,u=(f+1)*o*4|0}};e.convolve=n}}),px=_a({"../../node_modules/.pnpm/@rgba-image+lanczos@0.1.1/node_modules/@rgba-image/lanczos/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.lanczos2=e.lanczos=void 0;var t=ux(),n=cx(),r=fx(),i=dx(),o=(l,u,c=!1)=>{const f=u.width/l.width,d=u.height/l.height,h=r.filters(l.width,u.width,f,0,c),y=r.filters(l.height,u.height,d,0,c),m=new Uint8ClampedArray(u.width*l.height*4);i.convolve(l.data,m,l.width,l.height,u.width,h),i.convolve(m,u.data,l.height,u.width,u.height,y)},a=(l,u,c=0,f=0,d=l.width-c,h=l.height-f,y=0,m=0,w=u.width-y,p=u.height-m)=>{if(c=c|0,f=f|0,d=d|0,h=h|0,y=y|0,m=m|0,w=w|0,p=p|0,d<=0||h<=0||w<=0||p<=0)return;if(c===0&&f===0&&d===l.width&&h===l.height&&y===0&&m===0&&w===u.width&&p===u.height){o(l,u);return}const v=n.createImage(d,h),g=n.createImage(w,p);t.copy(l,v,c,f),o(v,g),t.copy(g,u,0,0,g.width,g.height,y,m)};e.lanczos=a;var s=(l,u,c=0,f=0,d=l.width-c,h=l.height-f,y=0,m=0,w=u.width-y,p=u.height-m)=>{if(c=c|0,f=f|0,d=d|0,h=h|0,y=y|0,m=m|0,w=w|0,p=p|0,d<=0||h<=0||w<=0||p<=0)return;if(c===0&&f===0&&d===l.width&&h===l.height&&y===0&&m===0&&w===u.width&&p===u.height){o(l,u,!0);return}const v=n.createImage(d,h),g=n.createImage(w,p);t.copy(l,v,c,f),o(v,g,!0),t.copy(g,u,0,0,g.width,g.height,y,m)};e.lanczos2=s}}),is={name:"@dotlottie/dotlottie-js",version:"0.5.2",type:"module",description:"This library helps in creating and modifying .lottie files.",repository:{type:"git",url:"git+https://github.com/dotlottie/dotlottie-js.git",directory:"packages/dotlottie-js"},homepage:"https://github.com/dotlottie/dotlottie-js#readme",bugs:"https://github.com/dotlottie/dotlottie-js/issues",author:"dotLottie",contributors:["Karam Ali ","Sam Osborne ","Jawish Hameed ","Abdelrahman Ashraf "],license:"MIT",engines:{node:">=18.0.0"},main:"./dist/index.js",exports:{".":"./dist/index.js","./node":"./dist/node/index.js"},types:"./dist/index.d.ts",typesVersions:{"*":{node:["./dist/node"]}},files:["dist"],scripts:{build:"tsup",dev:"tsup --watch",docs:"typedoc src",lint:"eslint --fix .","stats:eslint":"cross-env TIMING=1 eslint .","stats:ts":"tsc -p tsconfig.build.json --extendedDiagnostics",test:"pnpm test:browser && pnpm test:node","test:browser":"pnpm test:build:browser && jasmine-browser-runner runSpecs --config=./jasmine/jasmine-browser.json --port=4444","test:browser:watch":"nodemon -e ts --watch src/tests --exec 'pnpm test:browser'","test:build:browser":"tsup --platform='browser' --config ./jasmine/tsup.config.js","test:build:node":"tsup --platform='node' --config ./jasmine/tsup.config.js","test:build:watch":"pnpm test:build --watch","test:node":"pnpm test:build:node && jasmine --config=./jasmine/jasmine.json --parallel=auto","test:node:watch":"nodemon -e ts --watch src/tests --exec 'pnpm test:node'","type-check":"tsc --noEmit"},dependencies:{"browser-image-hash":"0.0.5",fflate:"0.7.4",sharp:"0.32.0","sharp-phash":"2.1.0",valibot:"^0.9.0"},devDependencies:{"@lottiefiles/lottie-types":"^1.1.0","@types/jasmine":"4.3.2","@types/node":"18.0.6","@types/sharp":"0.31.1","cross-env":"7.0.3",esbuild:"0.14.49",jasmine:"5.0.0","jasmine-browser-runner":"2.0.0","jasmine-core":"5.0.0","js-base64":"3.7.5",nodemon:"2.0.20",tsup:"6.1.3",typescript:"4.7.4"},publishConfig:{access:"public"},packageManager:"pnpm@7.1.6"},Yy=(e=>(e.Bounce="bounce",e.Normal="normal",e))(Yy||{}),hx=X4(Yy),mx=Yt({autoplay:Re(Ac()),defaultTheme:Re(An()),direction:Re(nd([nv(1),nv(-1)])),hover:Re(Ac()),id:An(),intermission:Re(Cn()),loop:Re(nd([Ac(),Cn()])),playMode:Re(hx),speed:Re(Cn()),themeColor:Re(An())}),vx=tx(mx,["id"]),Zr=Yt({state:An()}),gx=Zr,yx=Ea([Zr,Yt({ms:Cn()})]),wx=Ea([Zr,Yt({count:Cn()})]),Sx=Zr,bx=Zr,Ex=Zr,_x=Ea([Zr,Yt({threshold:Re(Z4(Cn([id(0),rd(1)])))})]),xx=Yt({onAfter:Re(yx),onClick:Re(gx),onComplete:Re(Ex),onEnter:Re(wx),onMouseEnter:Re(Sx),onMouseLeave:Re(bx),onShow:Re(_x)}),Cx=Ea([vx,Yt({playOnScroll:Re(rv([Cn([id(0),rd(1)]),Cn([id(0),rd(1)])])),segments:Re(nd([rv([Cn(),Cn()]),An()]))})]),Ox=Ea([xx,Yt({animationId:Re(An()),playbackSettings:Cx})]),Jy=ex(An(),Ox),Zy=Yt({id:An(),initial:An()}),kx=Yt({descriptor:Zy,states:Jy}),Ax={jpeg:"image/jpeg",png:"image/png",gif:"image/gif",bmp:"image/bmp",svg:"image/svg+xml",webp:"image/webp"},ov={jpeg:[255,216,255],png:[137,80,78,71,13,10,26,10],gif:[71,73,70],bmp:[66,77],webp:[82,73,70,70,87,69,66,80],svg:[60,63,120]},av={"image/jpeg":"jpeg","image/png":"png","image/gif":"gif","image/bmp":"bmp","image/svg+xml":"svg","image/webp":"webp"},Px=e=>{const t=e.substring(e.indexOf(",")+1),n=typeof window>"u"?Buffer.from(t,"base64").toString("binary"):atob(t),r=new Uint8Array(n.length);for(let i=0;i{let t=null,n=[];if(!e)return null;const r=e.substring(e.indexOf(",")+1);typeof window>"u"?t=Buffer.from(r,"base64").toString("binary"):t=atob(r);const i=new Uint8Array(t.length);for(let o=0;os===a[l]))return Ax[o]}return null},e2=e=>{var n;const t=Xy(e);if(!t){const r=(n=e.split(";")[0])==null?void 0:n.split("/")[1];return r&&av[r]||"png"}return av[t]||"png"},sv=class extends Error{constructor(e,t){super(e),te(this,"code"),this.name="[dotlottie-js]",this.code=t}},G=e=>new Error(`[dotlottie-js]: ${e}`),t2=e=>{try{return new URL(e),!0}catch{return!1}};function Ix(e){let t;if(typeof window>"u")t=Buffer.from(e).toString("base64");else{const r=Array.prototype.map.call(e,i=>String.fromCharCode(i)).join("");t=window.btoa(r)}return`data:${Xy(t)};base64,${t}`}var Mx=class{constructor(e){te(this,"_descriptor"),te(this,"_zipOptions"),te(this,"_states"),this._requireValidId(e.descriptor.id),this._requireValidStates(e.states),this._requireValidDescriptor(e.descriptor),this._descriptor=e.descriptor,this._zipOptions=e.zipOptions??{},this._states=e.states}get zipOptions(){return this._zipOptions}set zipOptions(e){this._zipOptions=e}get id(){return this._descriptor.id}set id(e){this._requireValidId(e),this._descriptor.id=e}get states(){return this._states}set states(e){this._states=e}get initial(){return this._descriptor.initial}set initial(e){this._descriptor.initial=e}get descriptor(){return this._descriptor}set descriptor(e){this._descriptor=e}toString(){return JSON.stringify({descriptor:this._descriptor,states:this._states})}_requireValidId(e){if(!e)throw G("Invalid id.")}_requireValidDescriptor(e){const t=iv(Zy,e);if(!t.success){const n=`Invalid state machine declaration, ${JSON.stringify(tv(t.error).nested,null,2)}`;throw new sv(`Invalid descriptor: ${n}`,"INVALID_STATEMACHINE")}}_requireValidStates(e){const t=iv(Jy,e);if(!t.success){const n=`Invalid state machine declaration, ${JSON.stringify(tv(t.error).nested,null,2)}`;throw new sv(`Invalid states: ${n}`,"INVALID_STATEMACHINE")}}},Lx=class{constructor(e){te(this,"_data"),te(this,"_id",""),te(this,"_url"),te(this,"_animationsMap",new Map),te(this,"_zipOptions"),this._requireValidId(e.id),this._id=e.id,e.data&&(this._requireValidData(e.data),this._data=e.data),e.url&&(this._requireValidUrl(e.url),this._url=e.url),this._zipOptions=e.zipOptions??{}}get zipOptions(){return this._zipOptions}set zipOptions(e){this._zipOptions=e}get id(){return this._id}set id(e){this._requireValidId(e),this._id=e}get url(){return this._url}set url(e){this._requireValidUrl(e),this._url=e}get data(){return this._data}set data(e){this._requireValidData(e),this._data=e}get animations(){return Array.from(this._animationsMap.values())}async toString(){return!this._data&&this._url&&await this._loadDataFromUrl(this._url),this._requireValidData(this._data),this._data}addAnimation(e){this._animationsMap.set(e.id,e)}removeAnimation(e){this._animationsMap.delete(e)}_requireValidId(e){if(typeof e!="string"||!e)throw G("Invalid theme id")}_requireValidUrl(e){if(!e||!t2(e))throw G("Invalid theme url")}_requireValidData(e){if(typeof e!="string"||!e)throw G("Invalid theme data")}async _loadDataFromUrl(e){try{const n=await(await fetch(e)).text();this._data=n}catch(t){throw G(`Failed to fetch theme from url, Error: ${JSON.stringify(t)}`)}}},Tx=class{constructor(e){te(this,"_animationsMap",new Map),te(this,"_plugins",[]),te(this,"_themesMap",new Map),te(this,"_stateMachinesMap",new Map),te(this,"_author"),te(this,"_description"),te(this,"_generator"),te(this,"_keywords"),te(this,"_version"),te(this,"_revision"),te(this,"_customData"),te(this,"enableDuplicateImageOptimization"),this._author=(e==null?void 0:e.author)??"LottieFiles",this._description=(e==null?void 0:e.description)??"",this._generator=(e==null?void 0:e.generator)??`${is.name}@${is.version}`,this._keywords=(e==null?void 0:e.keywords)??"dotLottie",this._version=(e==null?void 0:e.version)??"1.0",this._customData=(e==null?void 0:e.customData)??{},this._revision=(e==null?void 0:e.revision)??1,this.enableDuplicateImageOptimization=(e==null?void 0:e.enableDuplicateImageOptimization)??!1}async toBase64(e=void 0){throw G("toBase64() method not implemented in concrete class!")}create(e){throw G("create() method not implemented in concrete class!")}async download(e,t=void 0){throw G("download(fileName:string) method not implemented in concrete class!")}addPlugins(...e){throw G("addPlugins(...plugins: DotLottiePlugin[]) not implemented in concrete class!")}addAnimation(e){throw G("addAnimation(animationOptions: AnimationOptions) not implemented in concrete class!")}async fromArrayBuffer(e){throw G("fromArrayBuffer(arrayBuffer: ArrayBuffer): Promise not implemented in concrete class!")}async toArrayBuffer(e=void 0){throw G("toArrayBuffer(): Promise is not implemented in concrete class!")}get plugins(){return this._plugins}get version(){return this._version}get revision(){return this._revision}get author(){return this._author}get description(){return this._description}get keywords(){return this._keywords}get generator(){return this._generator}get animations(){return Array.from(this._animationsMap.values())}get manifest(){return this._buildManifest()}get custom(){return this._customData}get themes(){return Array.from(this._themesMap.values())}get stateMachines(){return Array.from(this._stateMachinesMap.values())}setCustomData(e){return this._customData=e??{},this}setAuthor(e){return this._author=e??"LottieFiles",this}setDescription(e){return this._description=e??"",this}setGenerator(e){return this._generator=e??`${is.name}@${is.version}`,this}setKeywords(e){return this._keywords=e??"dotLottie",this}setVersion(e){return this._version=e??"1.0",this}setRevision(e){return this._revision=e,this}removePlugins(...e){return e.forEach(t=>{t.uninstall();const n=this._plugins.indexOf(t);n!==-1&&this._plugins.splice(n,1)}),this}_renameImage(e,t,n){e.imageAssets.forEach(r=>{if(r.id===n){if(r.renameImage(t),!e.data)throw G("No animation data available.");const i=e.data.assets;if(!i)throw G("No image assets to rename.");for(const o of i)"w"in o&&"h"in o&&o.id===n&&(o.p=r.fileName)}})}_renameImageAssets(){const e=new Map;this.animations.forEach(n=>{e.set(n.id,n.imageAssets)});let t=0;e.forEach(n=>{t+=n.length});for(let n=this.animations.length-1;n>=0;n-=1){const r=this.animations.at(n);if(r)for(let i=r.imageAssets.length-1;i>=0;i-=1){const o=r.imageAssets.at(i);o&&(this._renameImage(r,`image_${t}`,o.id),t-=1)}}}_addLottieAnimation(e){if(this._animationsMap.get(e.id))throw G("Duplicate animation id detected, aborting.");return this._animationsMap.set(e.id,e),this}async _findImageAssetAndInline(e){var r;const t=(r=e.data)==null?void 0:r.assets;if(!t)throw G("Failed to inline assets, the animation's assets are undefined.");const n=this.getImages();for(const i of t)if("w"in i&&"h"in i&&!("xt"in i)&&"p"in i)for(const o of n)o.fileName===i.p&&(i.e=1,i.u="",i.p=await o.toDataURL());return e}async getAnimation(e,t={}){if(!t.inlineAssets)return this._animationsMap.get(e);let n=this._animationsMap.get(e);if(!n)throw G("Failed to find animation.");return n=await this._findImageAssetAndInline(n),n}getAnimations(){return Array.from(this._animationsMap)}removeAnimation(e){const t=this._animationsMap.get(e);if(t){const n=t.themes;for(const r of n)this.unassignTheme({animationId:t.id,themeId:r.id});this._animationsMap.delete(t.id)}return this}getImages(){const e=[];return this.animations.map(t=>e.push(...t.imageAssets)),e}getTheme(e){return this._themesMap.get(e)}_buildManifest(){var o;const e=Array.from(this._animationsMap.values()),t=Array.from(this._themesMap.values()),n=Array.from(this._stateMachinesMap.keys()),r=((o=e.find(a=>a.defaultActiveAnimation))==null?void 0:o.id)??"",i={version:this.version,revision:this.revision,keywords:this.keywords,author:this.author,generator:this.generator,animations:e.map(a=>({id:a.id,direction:a.direction,speed:a.speed,playMode:a.playMode,loop:a.loop,autoplay:a.autoplay,hover:a.hover,intermission:a.intermission,...a.defaultTheme?{defaultTheme:a.defaultTheme}:{}})),...this.description&&this.description.trim()!==""?{description:this.description}:{},...r&&r.trim()!==""?{activeAnimationId:r}:{},...this._customData&&Object.keys(this._customData).length!==0?{custom:this._customData}:{}};return t.length>0&&(i.themes=t.map(a=>({id:a.id,animations:a.animations.map(s=>s.id)}))),n.length>0&&(i.states=n),i}async build(){this._buildManifest();for(const n of this.animations)await n.toJSON();for(const n of this.themes)await n.toString();this.animations.length>1&&this._renameImageAssets();const e=[],t=[];for(const n of this.plugins)n.parallel?e.push(n):t.push(n);await Promise.all(e.map(async n=>n.onBuild()));for(const n of t)await n.onBuild();return this}async toBlob(e=void 0){const t=await this.toArrayBuffer(e);return new Blob([t],{type:"application/zip"})}async fromURL(e){if(!t2(e))throw G("Invalid URL");try{const t=await fetch(e);if(!t.ok)throw G(t.statusText);const n=await t.arrayBuffer();return this.fromArrayBuffer(n)}catch(t){if(t instanceof Error)throw G(t.message)}throw G("Unknown error")}merge(...e){const t=this.create();for(const n of e)n.animations.forEach(r=>{r.data?t.addAnimation({id:r.id,data:r.data}):r.url&&t.addAnimation({id:r.id,url:r.url})}),n.themes.forEach(r=>{r.data?t.addTheme({id:r.id,data:r.data}):r.url&&t.addTheme({id:r.id,url:r.url}),r.animations.forEach(i=>{t.assignTheme({animationId:i.id,themeId:r.id})})}),n.stateMachines.forEach(r=>{const i={states:r.states,descriptor:{id:r.id,initial:r.initial},zipOptions:r.zipOptions};t.addStateMachine(i)});return t}addTheme(e){const t=new Lx(e);return this._themesMap.set(t.id,t),this}removeTheme(e){const t=this._themesMap.get(e);if(t){const n=t.animations;for(const r of n)this.unassignTheme({animationId:r.id,themeId:e});this._themesMap.delete(t.id)}return this}assignTheme({animationId:e,themeId:t}){const n=this._themesMap.get(t);if(!n)throw G(`Failed to find theme with id ${t}`);const r=this._animationsMap.get(e);if(!r)throw G(`Failed to find animation with id ${e}`);return n.addAnimation(r),r.addTheme(n),this}unassignTheme({animationId:e,themeId:t}){const n=this._themesMap.get(t);if(!n)throw G(`Failed to find theme with id ${t}`);const r=this._animationsMap.get(e);if(!r)throw G(`Failed to find animation with id ${e}`);return n.removeAnimation(r.id),r.removeTheme(n.id),this}addStateMachine(e){const t=new Mx(e);return this._stateMachinesMap.set(e.descriptor.id,t),this}getStateMachine(e){return this._stateMachinesMap.get(e)}removeStateMachine(e){return this._stateMachinesMap.delete(e),this}_requireValidAuthor(e){if(!e)throw G("Invalid author")}_requireValidDescription(e){if(!e)throw G("Invalid description")}_requireValidGenerator(e){if(!e)throw G("Invalid generator")}_requireValidKeywords(e){if(!e)throw G("Invalid keywords")}_requireValidVersion(e){if(!e)throw G("Invalid version")}_requireValidCustomData(e){if(!e)throw G("Invalid customData")}},Dx=class{constructor(e){te(this,"_data"),te(this,"_id",""),te(this,"_url"),te(this,"_direction"),te(this,"_speed"),te(this,"_playMode"),te(this,"_loop"),te(this,"_autoplay"),te(this,"_hover"),te(this,"_intermission"),te(this,"_zipOptions"),te(this,"_defaultActiveAnimation"),te(this,"_imageAssets",[]),te(this,"_themesMap",new Map),te(this,"_defaultTheme"),this._requireValidOptions(e),this._id=e.id,this._zipOptions=e.zipOptions??{},e.data&&(this._data=e.data),e.url&&(this._url=e.url),this._direction=e.direction??1,this._speed=e.speed??1,this._playMode=e.playMode??"normal",this._loop=e.loop??!1,this._autoplay=e.autoplay??!1,this._defaultActiveAnimation=e.defaultActiveAnimation??!1,this._hover=e.hover??!1,this._intermission=e.intermission??0}async toBase64(){throw G("lottie animation controls tobase64 not implemented!")}get zipOptions(){return this._zipOptions}set zipOptions(e){this._zipOptions=e}get id(){return this._id}set id(e){this._requireValidId(e),this._id=e}get defaultTheme(){return this._defaultTheme}set defaultTheme(e){e&&(this._defaultTheme=e)}get themes(){return Array.from(this._themesMap.values())}set themes(e){this._themesMap=new Map,e.forEach(t=>{this._themesMap.set(t.id,t)})}get imageAssets(){return this._imageAssets}set imageAssets(e){this._imageAssets=e}get data(){return this._data}set data(e){this._requireValidLottieData(e),this._data=e}get url(){return this._url}set url(e){this._requireValidUrl(e),this._url=e}get direction(){return this._direction}set direction(e){this._direction=e}get speed(){return this._speed}set speed(e){this._speed=e}get playMode(){return this._playMode}set playMode(e){this._playMode=e}get loop(){return this._loop}set loop(e){this._requireValidLoop(e),this._loop=e}get autoplay(){return this._autoplay}set autoplay(e){this._autoplay=e}get defaultActiveAnimation(){return this._defaultActiveAnimation}set defaultActiveAnimation(e){this._defaultActiveAnimation=e}get hover(){return this._hover}set hover(e){this._hover=e}get intermission(){return this._intermission}set intermission(e){this._requireValidIntermission(e),this._intermission=e}addTheme(e){this._themesMap.set(e.id,e)}removeTheme(e){this._themesMap.delete(e)}async toArrayBuffer(e={}){const t=await this.toJSON(e);return new TextEncoder().encode(JSON.stringify(t)).buffer}async _extractImageAssets(){throw G("_extractImageAssets(): Promise method not implemented in concrete class")}async toBlob(e={}){const t=await this.toJSON(e);return new Blob([JSON.stringify(t)],{type:"application/json"})}async toJSON(e={}){var t,n;if(this._url&&!this._data&&(this._data=await this._fromUrl(this._url)),this._requireValidLottieData(this._data),(t=this._data.assets)!=null&&t.length&&(await this._extractImageAssets(),e.inlineAssets)){const r=(n=this.data)==null?void 0:n.assets;if(!r)throw G("Failed to inline assets, the animation's assets are undefined.");const i=this.imageAssets;for(const o of r)if("w"in o&&"h"in o&&!("xt"in o)&&"p"in o)for(const a of i)a.fileName===o.p&&(o.e=1,o.u="",o.p=await a.toDataURL())}return this._data}async _fromUrl(e){const n=await(await fetch(e)).text();let r;try{r=JSON.parse(n)}catch(i){if(i instanceof Error)throw G(`${i.message}: Invalid json returned from url`)}return this._requireValidLottieData(r),r}_requireValidUrl(e){try{new URL(e||"")}catch{throw G("Invalid animation url")}}_requireValidLottieData(e){if(!["v","ip","op","layers","fr","w","h"].every(r=>Object.prototype.hasOwnProperty.call(e,r)))throw G("Received invalid Lottie data.")}_requireValidId(e){if(!e)throw G("Invalid animation id")}_requireValidDirection(e){if(e!==-1&&e!==1)throw G("Direction can only be -1 (backwards) or 1 (forwards)")}_requireValidIntermission(e){if(e<0||!Number.isInteger(e))throw G("intermission must be a positive number")}_requireValidLoop(e){if(typeof e=="number"&&(!Number.isInteger(e)||e<0))throw G("loop must be a positive number or boolean")}_requireValidOptions(e){if(this._requireValidId(e.id),!e.data&&!e.url)throw G("No data or url provided.");e.data&&this._requireValidLottieData(e.data),e.url&&this._requireValidUrl(e.url),e.direction&&this._requireValidDirection(e.direction),e.intermission&&this._requireValidIntermission(e.intermission),e.loop&&this._requireValidLoop(e.loop)}},$x=class{constructor(e){te(this,"_data"),te(this,"_id",""),te(this,"_url"),te(this,"_fileName",""),te(this,"_parentAnimations"),te(this,"_zipOptions"),this._requireValidId(e.id),this._requireValidFileName(e.fileName),this._zipOptions=e.zipOptions??{},e.data&&(this._data=e.data),e.id&&(this._id=e.id),e.url&&(this._url=e.url),e.fileName&&(this._fileName=e.fileName),this._parentAnimations=e.parentAnimations||[]}get zipOptions(){return this._zipOptions}set zipOptions(e){this._zipOptions=e}_requireValidId(e){if(!e)throw G("Invalid image id")}_requireValidFileName(e){if(!e)throw G("Invalid image fileName")}get fileName(){return this._fileName}set fileName(e){if(!e)throw G("Invalid image file name");this._fileName=e}get id(){return this._id}set id(e){if(!e)throw G("Invalid image id");this._id=e}get data(){return this._data}set data(e){if(!e)throw G("Invalid data");this._data=e}get url(){return this._url}set url(e){if(!e)throw new Error("Invalid url");this._url=e}get parentAnimations(){return this._parentAnimations}set parentAnimations(e){this._parentAnimations=e}async toDataURL(){if(this._data&&this._isDataURL(this._data))return this.data;const e=await this.toArrayBuffer();return Ix(new Uint8Array(e))}renameImage(e){if(this.id=e,this.fileName){let t=this.fileName.split(".").pop();t||(t=".png"),this.fileName=`${e}.${t}`}}async toArrayBuffer(){return await(await this.toBlob()).arrayBuffer()}async toBlob(){if(!this._data&&this._url&&(this._data=await this._fromUrlToBlob(this._url)),!this._data)throw new Error("Invalid data");if(this._isDataURL(this._data)){const e=this._data,[t,n]=e.split(",");if((!t||!n)&&e.length)return new Blob([e]);if(!t||!n)throw new Error("Invalid data");const r=t.replace("data:","").replace(/;base64$/,"");return new Blob([n],{type:r})}if(this._isArrayBuffer(this._data))return new Blob([this._data]);if(this._isBlob(this._data))return this._data;throw new Error("Invalid data")}async _fromUrlToBlob(e){return(await fetch(e)).blob()}_isArrayBuffer(e){return e instanceof ArrayBuffer}_isDataURL(e){return typeof e=="string"&&e.startsWith("data:")}_isBlob(e){return e instanceof Blob}},jx=class{constructor(e){te(this,"dotlottie"),te(this,"_parallel",!1),this.dotlottie=void 0,e!=null&&e.parallel&&(this._parallel=e.parallel)}install(e){this.dotlottie=e}uninstall(){this.dotlottie=void 0}get parallel(){return this._parallel}set parallel(e){this._parallel=e}async onBuild(){throw G("dotlottie-plugin build Not implemented!")}_requireDotLottie(e){if(!e)throw G("dotLottie context is null inside of duplicate image detector plugin.")}},Fp=class extends $x{constructor(e){super(e)}},Fx=class extends jx{async generatePhash(e){return""}distanceTo(e,t){return 0}async _createRecordOfDuplicates(){var n,r;this._requireDotLottie(this.dotlottie);const e=[],t={};for(const i of this.dotlottie.animations)for(const o of i.imageAssets)e.push({excludeFromExport:!1,image:o,hash:await this.generatePhash(o)});for(const i of e)for(const o of e)i.image.id!==o.image.id&&!i.excludeFromExport&&!o.excludeFromExport&&i.hash&&o.hash&&this.distanceTo(i.hash,o.hash)<5&&(!t[i.image.fileName]&&!t[o.image.fileName]?(o.excludeFromExport=!0,t[i.image.fileName]=[o.image]):t[o.image.fileName]&&((n=t[o.image.fileName])!=null&&n.find(a=>a.id===i.image.id)||(i.excludeFromExport=!0,(r=t[o.image.fileName])==null||r.push(i.image))));return t}adjustDuplicateImageAssetPath(e,t){var n;for(const r in t)r&&((n=t[r])==null||n.forEach(i=>{if(e.data){const o=e.data.assets;o&&o.forEach(a=>{if("w"in a&&"h"in a&&a.p===i.fileName){const s=r;a.p=s}})}}))}async onBuild(){var r;this._requireDotLottie(this.dotlottie);const e=await this._createRecordOfDuplicates();this.dotlottie.animations.forEach(i=>{this.adjustDuplicateImageAssetPath(i,e)});const t={},n=this.dotlottie.getImages();for(const i in e)if(i)for(const o of n)o.fileName===i&&o.data!==void 0&&(t[i]=new Fp({data:o.data,id:o.id,fileName:o.fileName}));Object.keys(t).length,Object.keys(e).length;for(const i in e)i&&((r=e[i])==null||r.forEach(o=>{if(o.parentAnimations.length)for(const a of o.parentAnimations){a.imageAssets.splice(a.imageAssets.indexOf(o),1);const s=t[i];s!==void 0&&(a.imageAssets.push(s),s.parentAnimations.push(a))}}))}},lv=function(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,o=[],a;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)o.push(i.value)}catch(s){a={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o},Rx=function(e,t){for(var n=0,r=t.length,i=e.length;n0)&&!(i=r.next()).done;)o.push(i.value)}catch(s){a={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o},Kx=function(e,t){for(var n=0,r=t.length,i=e.length;n0)&&!(i=r.next()).done;)o.push(i.value)}catch(s){a={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o},Yx=function(e,t){for(var n=0,r=t.length,i=e.length;n0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]"u")return Buffer.from(e).toString("base64");const n=new Uint8Array(e).reduce((r,i)=>r+String.fromCharCode(i),"");return window.btoa(n)}async _extractImageAssets(){if(!this._data)throw G("Asset extraction failed.");const e=this._data.assets;if(!e)throw G("Asset extraction failed.");for(const t of e)if("w"in t&&"h"in t&&!("xt"in t)&&"p"in t){const n=t.p.split(",");if(!n.length||!n[0]||!n[1])break;let r=null;r=e2(t.p);const o=`${t.id}.${r}`;this._imageAssets.push(new Fp({data:t.p,id:t.id,fileName:o,parentAnimations:[this]})),t.p=o,t.u="/images/",t.e=0}return!1}},wl=class extends Tx{constructor(e){super(e),this.enableDuplicateImageOptimization&&this.addPlugins(new iC)}addPlugins(...e){return e.forEach(t=>{t.install(this),this._plugins.push(t)}),this}addAnimation(e){const t=new oC(e);if(this._animationsMap.get(e.id))throw G("Duplicate animation id detected, aborting.");return this._animationsMap.set(t.id,t),this}async toBase64(e){const t=await this.toArrayBuffer(e),r=new Uint8Array(t).reduce((i,o)=>i+String.fromCharCode(o),"");return window.btoa(r)}async download(e,t=void 0){const n=await this.toBlob(t),r=URL.createObjectURL(n),i=document.createElement("a");i.href=r,i.download=e,i.style.display="none",document.body.append(i),i.click(),setTimeout(()=>{URL.revokeObjectURL(r),i.remove()},1e3)}create(e){return new wl(e)}async toArrayBuffer(e){const t=this._buildManifest(),n={"manifest.json":[Ei(JSON.stringify(t)),{level:0}]};for(const i of this.animations){const o=await i.toJSON();n[`animations/${i.id}.json`]=[Ei(JSON.stringify(o)),i.zipOptions];const a=i.imageAssets;for(const s of a){const l=await s.toDataURL();n[`images/${s.fileName}`]=[Px(l),s.zipOptions]}}for(const i of this.themes){const o=await i.toString();n[`themes/${i.id}.lss`]=[Ei(o),i.zipOptions]}for(const i of this.stateMachines){const o=i.toString();n[`states/${i.id}.json`]=[Ei(o),i.zipOptions]}return await new Promise((i,o)=>{Y4(n,(e==null?void 0:e.zipOptions)||{},(a,s)=>{if(a){o(a);return}i(s.buffer)})})}async fromArrayBuffer(e){var n,r,i,o,a,s;const t=new wl;try{const l=await new Promise((c,f)=>{J4(new Uint8Array(e),(d,h)=>{d&&f(d),c(h)})}),u=[];if(l["manifest.json"]instanceof Uint8Array)try{const c=JSON.parse(ed(l["manifest.json"],!1)),{author:f,custom:d,description:h,generator:y,keywords:m,version:w}=c;f&&(this._requireValidAuthor(f),t.setAuthor(f)),d&&(this._requireValidCustomData(d),t.setCustomData(d)),h&&(this._requireValidDescription(h),t.setDescription(h)),y&&(this._requireValidGenerator(y),t.setGenerator(y)),m&&(this._requireValidKeywords(m),t.setKeywords(m)),w&&(this._requireValidVersion(w),t.setVersion(w));for(const p of Object.keys(l)){const v=ed(l[p],!0);if(p.startsWith("animations/")&&p.endsWith(".json")){const g=(n=/animations\/(.+)\.json/u.exec(p))==null?void 0:n[1];if(!g)throw G("Invalid animation id");const S=JSON.parse(v),_=c.animations.find(x=>x.id===g);if(_===void 0)throw G("Animation not found inside manifest");t.addAnimation({data:S,..._})}else if(p.startsWith("images/")){const g=(r=/images\/(.+)\./u.exec(p))==null?void 0:r[1];if(!g)throw G("Invalid image id");let S=btoa(v);S=`data:image/${e2(S)};base64,${S}`,u.push(new Fp({id:g,data:S,fileName:p.split("/")[1]||""}))}else if(p.startsWith("themes/")&&p.endsWith(".lss")){const g=(i=/themes\/(.+)\.lss/u.exec(p))==null?void 0:i[1];if(!g)throw G("Invalid theme id");(o=c.themes)==null||o.forEach(S=>{S.id===g&&(t.addTheme({id:S.id,data:v}),S.animations.forEach(_=>{t.assignTheme({animationId:_,themeId:g})}))})}else if(p.startsWith("states/")&&p.endsWith(".json")){const g=(a=/states\/(.+)\.json/u.exec(p))==null?void 0:a[1];if(!g)throw G("Invalid theme id");(s=c.states)==null||s.forEach(S=>{if(S===g){const _=JSON.parse(v);t.addStateMachine(_)}})}}for(const p of u)for(const v of t.animations)if(v.data){const g=v.data.assets;if(g)for(const S of g)"w"in S&&"h"in S&&S.p.includes(p.id)&&(p.parentAnimations.push(v),v.imageAssets.push(p))}}catch{throw G("Invalid manifest inside buffer!")}else throw G("Invalid buffer")}catch(l){if(l instanceof Error)throw G(l.message)}return t}};function sn(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r3?t.i-4:t.i:Array.isArray(e)?1:Rp(e)?2:Np(e)?3:0}function Pi(e,t){return eo(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function aC(e,t){return eo(e)===2?e.get(t):e[t]}function n2(e,t,n){var r=eo(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function r2(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function Rp(e){return dC&&e instanceof Map}function Np(e){return pC&&e instanceof Set}function Ir(e){return e.o||e.t}function zp(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=o2(e);delete t[Ee];for(var n=Ii(t),r=0;r1&&(e.set=e.add=e.clear=e.delete=sC),Object.freeze(e),t&&qr(e,function(n,r){return Vp(r,!0)},!0)),e}function sC(){sn(2)}function Bp(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Pn(e){var t=ud[e];return t||sn(18,e),t}function lC(e,t){ud[e]||(ud[e]=t)}function ad(){return ua}function Pc(e,t){t&&(Pn("Patches"),e.u=[],e.s=[],e.v=t)}function Sl(e){sd(e),e.p.forEach(uC),e.p=null}function sd(e){e===ua&&(ua=e.l)}function cv(e){return ua={p:[],l:ua,h:e,m:!0,_:0}}function uC(e){var t=e[Ee];t.i===0||t.i===1?t.j():t.g=!0}function Ic(e,t){t._=t.p.length;var n=t.p[0],r=e!==void 0&&e!==n;return t.h.O||Pn("ES5").S(t,e,r),r?(n[Ee].P&&(Sl(t),sn(4)),qn(e)&&(e=bl(t,e),t.l||El(t,e)),t.u&&Pn("Patches").M(n[Ee].t,e,t.u,t.s)):e=bl(t,n,[]),Sl(t),t.u&&t.v(t.u,t.s),e!==i2?e:void 0}function bl(e,t,n){if(Bp(t))return t;var r=t[Ee];if(!r)return qr(t,function(s,l){return fv(e,r,t,s,l,n)},!0),t;if(r.A!==e)return t;if(!r.P)return El(e,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var i=r.i===4||r.i===5?r.o=zp(r.k):r.o,o=i,a=!1;r.i===3&&(o=new Set(i),i.clear(),a=!0),qr(o,function(s,l){return fv(e,r,i,s,l,n,a)}),El(e,i,!1),n&&e.u&&Pn("Patches").N(r,n,e.u,e.s)}return r.o}function fv(e,t,n,r,i,o,a){if(br(i)){var s=bl(e,i,o&&t&&t.i!==3&&!Pi(t.R,r)?o.concat(r):void 0);if(n2(n,r,s),!br(s))return;e.m=!1}else a&&n.add(i);if(qn(i)&&!Bp(i)){if(!e.h.D&&e._<1)return;bl(e,i),t&&t.A.l||El(e,i)}}function El(e,t,n){n===void 0&&(n=!1),!e.l&&e.h.D&&e.m&&Vp(t,n)}function Mc(e,t){var n=e[Ee];return(n?Ir(n):e)[t]}function dv(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function nr(e){e.P||(e.P=!0,e.l&&nr(e.l))}function Lc(e){e.o||(e.o=zp(e.t))}function ld(e,t,n){var r=Rp(t)?Pn("MapSet").F(t,n):Np(t)?Pn("MapSet").T(t,n):e.O?function(i,o){var a=Array.isArray(i),s={i:a?1:0,A:o?o.A:ad(),P:!1,I:!1,R:{},l:o,t:i,k:null,o:null,j:null,C:!1},l=s,u=ca;a&&(l=[s],u=_o);var c=Proxy.revocable(l,u),f=c.revoke,d=c.proxy;return s.k=d,s.j=f,d}(t,n):Pn("ES5").J(t,n);return(n?n.A:ad()).p.push(r),r}function cC(e){return br(e)||sn(22,e),function t(n){if(!qn(n))return n;var r,i=n[Ee],o=eo(n);if(i){if(!i.P&&(i.i<4||!Pn("ES5").K(i)))return i.t;i.I=!0,r=pv(n,o),i.I=!1}else r=pv(n,o);return qr(r,function(a,s){i&&aC(i.t,a)===s||n2(r,a,t(s))}),o===3?new Set(r):r}(e)}function pv(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return zp(e)}function fC(){function e(o,a){var s=i[o];return s?s.enumerable=a:i[o]=s={configurable:!0,enumerable:a,get:function(){var l=this[Ee];return ca.get(l,o)},set:function(l){var u=this[Ee];ca.set(u,o,l)}},s}function t(o){for(var a=o.length-1;a>=0;a--){var s=o[a][Ee];if(!s.P)switch(s.i){case 5:r(s)&&nr(s);break;case 4:n(s)&&nr(s)}}}function n(o){for(var a=o.t,s=o.k,l=Ii(s),u=l.length-1;u>=0;u--){var c=l[u];if(c!==Ee){var f=a[c];if(f===void 0&&!Pi(a,c))return!0;var d=s[c],h=d&&d[Ee];if(h?h.t!==f:!r2(d,f))return!0}}var y=!!a[Ee];return l.length!==Ii(a).length+(y?0:1)}function r(o){var a=o.k;if(a.length!==o.t.length)return!0;var s=Object.getOwnPropertyDescriptor(a,a.length-1);if(s&&!s.get)return!0;for(var l=0;l1?p-1:0),g=1;g1?c-1:0),d=1;d=0;i--){var o=r[i];if(o.path.length===0&&o.op==="replace"){n=o.value;break}}i>-1&&(r=r.slice(i+1));var a=Pn("Patches").$;return br(n)?a(n,r):this.produce(n,function(s){return a(s,r)})},e}(),Lt=new mC,a2=Lt.produce;Lt.produceWithPatches.bind(Lt);Lt.setAutoFreeze.bind(Lt);Lt.setUseProxies.bind(Lt);Lt.applyPatches.bind(Lt);Lt.createDraft.bind(Lt);Lt.finishDraft.bind(Lt);function Kr(e){"@babel/helpers - typeof";return Kr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Kr(e)}function vC(e,t){if(Kr(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Kr(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function s2(e){var t=vC(e,"string");return Kr(t)==="symbol"?t:String(t)}function xo(e,t,n){return t=s2(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Q(e){for(var t=1;t"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(it(1));return n(l2)(e,t)}if(typeof e!="function")throw new Error(it(2));var i=e,o=t,a=[],s=a,l=!1;function u(){s===a&&(s=a.slice())}function c(){if(l)throw new Error(it(3));return o}function f(m){if(typeof m!="function")throw new Error(it(4));if(l)throw new Error(it(5));var w=!0;return u(),s.push(m),function(){if(w){if(l)throw new Error(it(6));w=!1,u();var v=s.indexOf(m);s.splice(v,1),a=null}}}function d(m){if(!gC(m))throw new Error(it(7));if(typeof m.type>"u")throw new Error(it(8));if(l)throw new Error(it(9));try{l=!0,o=i(o,m)}finally{l=!1}for(var w=a=s,p=0;p"u")throw new Error(it(12));if(typeof n(void 0,{type:_l.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(it(13))})}function wC(e){for(var t=Object.keys(e),n={},r=0;r"u")throw u&&u.type,new Error(it(14));f[h]=w,c=c||w!==m}return c=c||o.length!==Object.keys(l).length,c?f:l}}function xl(){for(var e=arguments.length,t=new Array(e),n=0;n0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]{e.list=t.payload},addAnimation:(e,t)=>{e.list.push(t.payload)},removeAnimation:(e,t)=>{e.list=e.list.filter(n=>n.name!==t.payload)}}}),{addAnimation:O7,removeAnimation:k7,setAnimations:KC}=p2.actions,GC=p2.reducer,Au=rE,Fe=Rb,QC={playerUrl:void 0,workingFileName:"_.lottie"},h2=xa({name:"playground",initialState:QC,reducers:{setPlayerUrl:(e,t)=>{e.playerUrl=t.payload},setWorkingFileName:(e,t)=>{e.workingFileName=t.payload}}}),{setPlayerUrl:xv,setWorkingFileName:os}=h2.actions,YC=h2.reducer,JC={list:[]},m2=xa({name:"states",initialState:JC,reducers:{setStates:(e,t)=>{e.list=t.payload},addState:(e,t)=>{e.list.push(t.payload)},removeState:(e,t)=>{e.list=e.list.filter(n=>n.name!==t.payload)}}}),{addState:A7,removeState:P7,setStates:ZC}=m2.actions,XC=m2.reducer,e6={list:[]},v2=xa({name:"themes",initialState:e6,reducers:{setThemes:(e,t)=>{e.list=t.payload},addTheme:(e,t)=>{e.list.push(t.payload)},removeTheme:(e,t)=>{e.list=e.list.filter(n=>n.name!==t.payload)}}}),{addTheme:I7,removeTheme:M7,setThemes:t6}=v2.actions,n6=v2.reducer,r6={id:"",initial:"initialState"},i6={initialState:{animationId:"animationId",playbackSettings:{autoplay:!0,loop:!0}}},o6={descriptor:r6,states:i6},Wp=(...e)=>e.filter(Boolean).join(" ");function a6(e,t="dotLottie-common"){return new Error(`[${t}]: ${e}`)}function s6(e){try{const t=JSON.parse(e);return JSON.stringify(t,null," ")}catch(t){return JSON.stringify({error:t},null," ")}}function fd(e=""){return e.replace(/\s+/u,"_").toLowerCase()}function l6(){return structuredClone(o6)}const g2=b.createContext({dotLottie:new wl,setDotLottie:()=>{},setAnimationOptions:()=>{},addDotLottieStateMachine:()=>{},fetchAndUpdateDotLottie:()=>{},addDotLottieTheme:()=>{},addDotLottieAnimation:()=>{},downloadDotLottie:()=>{},removeDotLottieAnimation:()=>{},removeDotLottieState:()=>{},removeDotLottieTheme:()=>{},renameDotLottieAnimation:()=>{},buildAndUpdateUrl:()=>{}}),u6=({children:e})=>{const[t,n]=b.useState(new wl),r=Fe(g=>g.playground.playerUrl),i=Fe(g=>g.playground.workingFileName),o=Au(),a=b.useCallback(g=>{n(g)},[n]),s=b.useCallback(async()=>{const g=t.manifest.animations.map(x=>({name:`${x.id}`,type:"json"})).sort((x,E)=>x.name>E.name?1:-1),S=t.stateMachines.map(x=>({name:`${x.id}`,type:"json"})).sort((x,E)=>x.name>E.name?1:-1),_=t.themes.map(x=>({name:`${x.id}`,type:"lss"})).sort((x,E)=>x.name>E.name?1:-1);o(KC(g)),o(ZC(S)),o(t6(_))},[o,t]),l=b.useCallback(async()=>{const g=r;await t.build();const S=await t.toBlob(),_=URL.createObjectURL(S);o(xv("")),o(xv(_)),g&&URL.revokeObjectURL(g)},[t]),u=b.useCallback(g=>{try{kx.parse(g)}catch(S){throw me("Invalid state schema. Please verify the json.",{type:"error"}),S}},[]),c=b.useCallback((g,S)=>{u(g),S?t.removeStateMachine(S):t.removeStateMachine(g.descriptor.id),t.addStateMachine(g),s(),l()},[t,s]),f=b.useCallback((g,S)=>{t.removeTheme(S),t.addTheme({id:S,data:g}),s(),l()},[t,s]),d=b.useCallback(async(g,S)=>{const _=await t.getAnimation(g);if(_)try{t.addAnimation({id:S,data:_.data}),t.removeAnimation(g)}catch(x){me(x.message,{type:"error"}),console.error(x)}s(),l()},[t,s,l]),h=b.useCallback((g,S)=>{t.addAnimation({id:S,data:g}),s(),l()},[t,s,l]),y=b.useCallback(g=>{t.removeStateMachine(g),s(),l()},[t,s,l]),m=b.useCallback(g=>{t.removeAnimation(g),s(),l()},[t]),w=b.useCallback(g=>{t.removeTheme(g),s(),l()},[t]),p=b.useCallback(async()=>{await t.build().then(()=>{t.download(i)})},[t,i]),v=b.useCallback(async(g,S)=>{const _=await t.getAnimation(g);if(_){if(_.loop=!!S.loop,_.speed=Number(S.speed),_.autoplay=!!S.autoplay,_.playMode=S.playMode,_.direction=Number(S.direction),_.intermission=Number(S.intermission),_.hover=!!S.hover,_.defaultTheme=S.defaultTheme,S.assignedThemes){const x=S.assignedThemes.split(",");_.themes.forEach(E=>{x.includes(E.id)||t.unassignTheme({animationId:g,themeId:E.id})}),x.forEach(E=>{t.assignTheme({animationId:g,themeId:E})})}_.defaultActiveAnimation=S.defaultActiveAnimation||!1,S.defaultActiveAnimation&&t.animations.forEach(x=>{_.id!==x.id&&(x.defaultActiveAnimation=!1)})}},[t]);return O.jsx(g2.Provider,{value:{addDotLottieAnimation:h,addDotLottieStateMachine:c,addDotLottieTheme:f,buildAndUpdateUrl:l,dotLottie:t,downloadDotLottie:p,fetchAndUpdateDotLottie:s,removeDotLottieAnimation:m,removeDotLottieState:y,removeDotLottieTheme:w,renameDotLottieAnimation:d,setDotLottie:a,setAnimationOptions:v},children:e})},qp=()=>{const e=b.useContext(g2);if(typeof e>"u")throw a6("useDotLottie must be used within a DotLottieProvider");return e},c6={file:void 0,validationStatus:!0,updated:!1,animationId:"",playbackOptions:{},animationOptions:{}},y2=xa({name:"editor",initialState:c6,reducers:{setEditorFile:(e,t)=>{e.file={...e.file||{},...t.payload||{}},e.animationId=void 0,e.updated=!1},clearEditorFile:e=>{e.file=void 0,e.validationStatus=!0,e.updated=!1},updateEditorFile:(e,t)=>{e.file&&(e.file.content=t.payload)},setEditorValidatationStatus:(e,t)=>{e.validationStatus=t.payload},setEditorUpdated:(e,t)=>{e.updated=t.payload},setEditorAnimationId:(e,t)=>{e.animationId=t.payload,e.updated=!1,e.file=void 0},setEditorPlaybacOptions:(e,t)=>{e.playbackOptions={...e.playbackOptions,...t.payload||{}}},setEditorAnimationOptions:(e,t)=>{e.animationOptions=t.payload||{}},updateEditorAnimationOptions:(e,t)=>{e.animationOptions={...e.animationOptions,...t.payload||{}}},clearEditorPlaybackOptions:e=>{e.playbackOptions={},e.animationId=""},clearEditorState:e=>{e.file=void 0,e.validationStatus=!0,e.updated=!1,e.playbackOptions={},e.animationId="",e.animationOptions={}}}}),{clearEditorFile:L7,clearEditorPlaybackOptions:T7,clearEditorState:Ms,setEditorAnimationId:f6,setEditorAnimationOptions:Cv,setEditorFile:Ov,setEditorPlaybacOptions:D7,setEditorUpdated:Cl,setEditorValidatationStatus:kv,updateEditorAnimationOptions:Av,updateEditorFile:$7}=y2.actions,d6=y2.reducer,Ol=ne.forwardRef(({children:e,color:t="blue",...n},r)=>O.jsx("button",{ref:r,className:Wp("text-white rounded px-3 py-1 text-sm disabled:bg-gray-500",t==="blue"&&"bg-blue-600 hover:bg-blue-700",t==="green"&&"bg-green-600 hover:bg-green-700",t==="red"&&"bg-red-600 hover:bg-red-700"),...n,children:e})),p6=({onChange:e,title:t})=>{const[n,r]=b.useState(!1),i=b.useRef(null),o=b.useCallback(()=>{n||r(!0)},[n]),a=b.useCallback(()=>{var l;e((l=i.current)!=null&&l.value?`${i.current.value}.lottie`:t),r(!1)},[onchange,r]),s=b.useCallback(l=>{l.key==="Enter"&&a()},[a]);return O.jsxs("div",{className:"group flex items-center",children:[n&&O.jsx("input",{ref:i,autoFocus:!0,className:"bg-transparent outline-none",type:"text",onKeyDown:s,onBlur:a,defaultValue:t.replace(/.lottie$/u,"")}),!n&&O.jsx("span",{children:t||"unnamed.lottie"}),O.jsx("button",{onClick:o,className:Wp("invisible",!n&&"group-hover:visible"),children:O.jsx(gy,{size:20})})]})};var h6=function(){};function m6(e){for(var t=[],n=1;ne==="lss"?O.jsx(sE,{}):O.jsx(lE,{}),x6=({onAdd:e})=>{const t=b.useRef(null),n=b.useCallback(i=>{typeof e=="function"&&i.target.value&&e(i.target.value.replace(/\s+/gu,"_"))},[e]),r=b.useCallback(i=>{var o;i.key==="Enter"&&((o=t.current)!=null&&o.value)&&typeof e=="function"&&e(t.current.value.replace(/\s+/gu,"_"))},[e]);return O.jsxs("div",{className:"w-full bg-dark flex items-center gap-1 px-2 py-1 pl-4 text-gray-400 text-sm whitespace-nowrap hover:text-white",children:[O.jsx("span",{children:O.jsx(w2,{type:"json"})}),O.jsx("input",{autoFocus:!0,ref:t,type:"text",className:"bg-transparent outline-none",onKeyUp:r,onBlur:n})]})};function C6(e){return mn({tag:"svg",attr:{viewBox:"0 0 15 15",fill:"none"},child:[{tag:"path",attr:{fillRule:"evenodd",clipRule:"evenodd",d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor"}}]})(e)}const O6=({editable:e,file:t,onRemove:n,onRename:r,...i})=>{const[o,a]=b.useState(!1),s=b.useRef(null),l=b.useCallback(d=>{d.stopPropagation(),n==null||n(t.name)},[n,t.name]),u=b.useCallback(d=>{d.stopPropagation(),a(!0)},[a,o]),c=b.useCallback(()=>{s.current&&s.current.value!==t.name&&(r==null||r(t.name,fd(s.current.value))),a(!1)},[r,a,s]),f=b.useCallback(d=>{d.key==="Enter"&&c()},[c]);return O.jsxs("button",{className:"group w-full flex items-center gap-1 px-2 py-1 pl-4 text-sm whitespace-nowrap hover:text-white",...i,children:[O.jsx("span",{children:O.jsx(w2,{type:t.type})}),o&&O.jsx("input",{ref:s,onKeyDown:f,onBlur:c,autoFocus:!0,className:"outline-none bg-transparent flex-1 text-left",defaultValue:t.name}),!o&&O.jsx("span",{className:"flex-1 text-left",children:t.name}),!o&&O.jsxs("div",{className:"flex justify-self-end text-gray-400 gap-1",children:[e&&O.jsx("span",{onClick:u,className:"hover:text-white opacity-0 group-hover:opacity-100",children:O.jsx(gy,{size:20})}),O.jsx("span",{onClick:l,title:"Remove",className:"hover:text-white opacity-0 group-hover:opacity-100",children:O.jsx(C6,{size:20})})]})]})};function k6(e){return mn({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M480 580H372a8 8 0 0 0-8 8v48a8 8 0 0 0 8 8h108v108a8 8 0 0 0 8 8h48a8 8 0 0 0 8-8V644h108a8 8 0 0 0 8-8v-48a8 8 0 0 0-8-8H544V472a8 8 0 0 0-8-8h-48a8 8 0 0 0-8 8v108zm374.6-291.3c6 6 9.4 14.1 9.4 22.6V928c0 17.7-14.3 32-32 32H192c-17.7 0-32-14.3-32-32V96c0-17.7 14.3-32 32-32h424.7c8.5 0 16.7 3.4 22.7 9.4l215.2 215.3zM790.2 326L602 137.8V326h188.2z"}}]})(e)}function A6(e){return mn({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M464 128H272l-64-64H48C21.49 64 0 85.49 0 112v288c0 26.51 21.49 48 48 48h416c26.51 0 48-21.49 48-48V176c0-26.51-21.49-48-48-48z"}}]})(e)}function P6(e){return mn({tag:"svg",attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}},{tag:"polyline",attr:{points:"17 8 12 3 7 8"}},{tag:"line",attr:{x1:"12",x2:"12",y1:"3",y2:"15"}}]})(e)}const I6=({buttons:e,onClickAdd:t,onUpload:n,title:r,...i})=>{const o=b.useCallback(a=>{const s=a[0];n==null||n(s)},[n]);return O.jsxs("div",{className:Wp("flex w-full items-center gap-2 py-2 px-1 text-gray-400 text-md whitespace-nowrap border-y border-gray-500"),...i,children:[O.jsx("span",{children:O.jsx(A6,{})}),O.jsx("span",{className:"w-full text-left text-md",children:r}),Array.isArray(e)&&e.map(a=>{const s=[];switch(a){case"add":s.push(O.jsx("button",{className:"hover:text-white",title:"Add new",onClick:t,children:O.jsx(k6,{size:20})},a));break;case"upload":s.push(O.jsx(ia,{onDrop:o,accept:r==="Themes"?"lss":"json",children:({getInputProps:l,getRootProps:u})=>O.jsxs("button",{...u(),className:"hover:text-white",title:"Upload",children:[O.jsx("input",{...l()}),O.jsx(P6,{size:20})]})},a));break}return s})]})},jc=({className:e,files:t,onAddNew:n,onClick:r,onRemove:i,onUpload:o,title:a})=>{const{renameDotLottieAnimation:s}=qp(),l=Au(),u=b.useCallback(_=>()=>{r==null||r(a,_)},[r,a]),c=b.useMemo(()=>a.toLowerCase()==="themes"?"lss":"json",[a]),f=b.useCallback(_=>{i==null||i(a,_)},[i,a]),[d,h]=b.useState(!1),y=b.useCallback(()=>{h(!0)},[]);_6("Escape",()=>{h(!1)},{event:"keyup"});const m=b.useCallback(_=>{n==null||n(a,`${_}.${c}`),h(!1)},[n,a,c]),w=b.useCallback((_,x)=>{a==="Animations"&&(s(_,x),l(Ms()))},[a,s]),p=b.useCallback(_=>{o==null||o(a,_)},[o,a]),v=b.useCallback(_=>{p(_[0])},[p]),g=Fe(_=>{var x;return(x=_.editor.file)==null?void 0:x.name}),S=Fe(_=>_.editor.animationId);return O.jsxs("div",{className:`flex flex-col ${e}`,children:[O.jsx(I6,{title:a,onClickAdd:y,onUpload:p,buttons:a==="Animations"?["upload"]:["upload","add"]}),O.jsxs("div",{className:"relative h-full overflow-y-auto custom-scrollbar",children:[O.jsx(ia,{onDrop:v,accept:a==="Themes"?"lss":"json",noClick:!0,children:_=>O.jsxs("div",{..._.getRootProps(),children:[O.jsx("input",{..._.getInputProps()}),_.isDragActive&&O.jsxs("div",{className:"absolute inset-0 bg-black opacity-50 text-white flex justify-center items-center",children:["Drop ",a]}),O.jsxs("ul",{className:"w-full py-2",children:[Array.isArray(t)&&t.map(x=>O.jsx("li",{"data-value":a,className:`w-full ${S===x.name||g===x.name?"bg-gray-700 text-gray-100":"text-gray-400"}`,children:O.jsx(O6,{onRemove:f,onRename:w,editable:a==="Animations",file:x,onClick:u(x.name)})},x.name)),d&&O.jsx("li",{children:O.jsx(x6,{onAdd:m,extension:a==="Themes"?"lss":"json"})})]})]})}),O.jsx("div",{})]})]})};function M6(e){return mn({tag:"svg",attr:{viewBox:"0 0 256 256",fill:"currentColor"},child:[{tag:"path",attr:{d:"M176,56H80a72,72,0,0,0,0,144h96a72,72,0,0,0,0-144ZM80,168a40,40,0,1,1,40-40A40,40,0,0,1,80,168Z"}}]})(e)}function L6(e){return mn({tag:"svg",attr:{viewBox:"0 0 256 256",fill:"currentColor"},child:[{tag:"path",attr:{d:"M176,56H80a72,72,0,0,0,0,144h96a72,72,0,0,0,0-144Zm0,112a40,40,0,1,1,40-40A40,40,0,0,1,176,168Z"}}]})(e)}const Mv=({label:e,onToggle:t,value:n})=>{const r=b.useCallback(()=>{t==null||t(!n)},[t,n]);return O.jsxs("div",{className:"flex flex-col text-gray-400 w-full max-w-xs hover:text-white",children:[O.jsx("span",{className:"flex-1 text-lg text-left",children:e}),O.jsxs("button",{onClick:r,className:"flex items-center justify-between py-2 px-3 rounded bg-white text-gray-600",children:[O.jsx("div",{children:n?"On":"Off"}),O.jsx("span",{className:`${n?"text-green-700":""}`,children:n?O.jsx(L6,{size:30}):O.jsx(M6,{size:30})})]})]})},T6=({label:e,onChange:t,value:n})=>{const r=b.useCallback(i=>{t==null||t(Number(i.target.value))},[t]);return O.jsxs("div",{className:"flex flex-col text-gray-400 w-full max-w-xs hover:text-white",children:[O.jsx("span",{className:"flex-1 text-lg text-left",children:e}),O.jsx("input",{type:"number",onChange:r,value:n,name:e,className:"py-3 px-3 rounded bg-white text-gray-600"})]})};function D6(e){if(Array.isArray(e))return e}function $6(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,a,s=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=o.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw i}}return s}}function dd(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}var F6=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];function R6(e){var t=e.defaultInputValue,n=t===void 0?"":t,r=e.defaultMenuIsOpen,i=r===void 0?!1:r,o=e.defaultValue,a=o===void 0?null:o,s=e.inputValue,l=e.menuIsOpen,u=e.onChange,c=e.onInputChange,f=e.onMenuClose,d=e.onMenuOpen,h=e.value,y=Gn(e,F6),m=b.useState(s!==void 0?s:n),w=zn(m,2),p=w[0],v=w[1],g=b.useState(l!==void 0?l:i),S=zn(g,2),_=S[0],x=S[1],E=b.useState(h!==void 0?h:a),C=zn(E,2),k=C[0],P=C[1],$=b.useCallback(function(A,I){typeof u=="function"&&u(A,I),P(A)},[u]),j=b.useCallback(function(A,I){var F;typeof c=="function"&&(F=c(A,I)),v(F!==void 0?F:A)},[c]),U=b.useCallback(function(){typeof d=="function"&&d(),x(!0)},[d]),z=b.useCallback(function(){typeof f=="function"&&f(),x(!1)},[f]),L=s!==void 0?s:p,M=l!==void 0?l:_,D=h!==void 0?h:k;return Q(Q({},y),{},{inputValue:L,menuIsOpen:M,onChange:$,onInputChange:j,onMenuClose:z,onMenuOpen:U,value:D})}function N6(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Lv(e,t){for(var n=0;n"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function U6(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function H6(e,t){if(t&&(Kr(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return U6(e)}function W6(e){var t=B6();return function(){var r=kl(e),i;if(t){var o=kl(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return H6(this,i)}}function q6(e){if(Array.isArray(e))return dd(e)}function K6(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function G6(){throw new TypeError(`Invalid attempt to spread non-iterable instance. -In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function b2(e){return q6(e)||K6(e)||S2(e)||G6()}function Q6(e){if(e.sheet)return e.sheet;for(var t=0;t0?Je(to,--bt):0,Wi--,Ne===10&&(Wi=1,Iu--),Ne}function It(){return Ne=bt2||da(Ne)>3?"":" "}function l5(e,t){for(;--t&&It()&&!(Ne<48||Ne>102||Ne>57&&Ne<65||Ne>70&&Ne<97););return Ca(e,Ls()+(t<6&&In()==32&&It()==32))}function md(e){for(;It();)switch(Ne){case e:return bt;case 34:case 39:e!==34&&e!==39&&md(Ne);break;case 40:e===41&&md(e);break;case 92:It();break}return bt}function u5(e,t){for(;It()&&e+Ne!==47+10;)if(e+Ne===42+42&&In()===47)break;return"/*"+Ca(t,bt-1)+"*"+Pu(e===47?e:It())}function c5(e){for(;!da(In());)It();return Ca(e,bt)}function f5(e){return k2(Ds("",null,null,null,[""],e=O2(e),0,[0],e))}function Ds(e,t,n,r,i,o,a,s,l){for(var u=0,c=0,f=a,d=0,h=0,y=0,m=1,w=1,p=1,v=0,g="",S=i,_=o,x=r,E=g;w;)switch(y=v,v=It()){case 40:if(y!=108&&Je(E,f-1)==58){hd(E+=le(Ts(v),"&","&\f"),"&\f")!=-1&&(p=-1);break}case 34:case 39:case 91:E+=Ts(v);break;case 9:case 10:case 13:case 32:E+=s5(y);break;case 92:E+=l5(Ls()-1,7);continue;case 47:switch(In()){case 42:case 47:as(d5(u5(It(),Ls()),t,n),l);break;default:E+="/"}break;case 123*m:s[u++]=Sn(E)*p;case 125*m:case 59:case 0:switch(v){case 0:case 125:w=0;case 59+c:p==-1&&(E=le(E,/\f/g,"")),h>0&&Sn(E)-f&&as(h>32?Dv(E+";",r,n,f-1):Dv(le(E," ","")+";",r,n,f-2),l);break;case 59:E+=";";default:if(as(x=Tv(E,t,n,u,c,i,s,g,S=[],_=[],f),o),v===123)if(c===0)Ds(E,t,x,x,S,o,f,s,_);else switch(d===99&&Je(E,3)===110?100:d){case 100:case 108:case 109:case 115:Ds(e,x,x,r&&as(Tv(e,x,x,0,0,i,s,g,i,S=[],f),_),i,_,f,s,r?S:_);break;default:Ds(E,x,x,x,[""],_,0,s,_)}}u=c=h=0,m=p=1,g=E="",f=a;break;case 58:f=1+Sn(E),h=y;default:if(m<1){if(v==123)--m;else if(v==125&&m++==0&&a5()==125)continue}switch(E+=Pu(v),v*m){case 38:p=c>0?1:(E+="\f",-1);break;case 44:s[u++]=(Sn(E)-1)*p,p=1;break;case 64:In()===45&&(E+=Ts(It())),d=In(),c=f=Sn(g=E+=c5(Ls())),v++;break;case 45:y===45&&Sn(E)==2&&(m=0)}}return o}function Tv(e,t,n,r,i,o,a,s,l,u,c){for(var f=i-1,d=i===0?o:[""],h=Qp(d),y=0,m=0,w=0;y0?d[p]+" "+v:le(v,/&\f/g,d[p])))&&(l[w++]=g);return Mu(e,t,n,i===0?Kp:s,l,u,c)}function d5(e,t,n){return Mu(e,t,n,E2,Pu(o5()),fa(e,2,-2),0)}function Dv(e,t,n,r){return Mu(e,t,n,Gp,fa(e,0,r),fa(e,r+1,-1),r)}function Mi(e,t){for(var n="",r=Qp(e),i=0;i6)switch(Je(e,t+1)){case 109:if(Je(e,t+4)!==45)break;case 102:return le(e,/(.+:)(.+)-([^]+)/,"$1"+ae+"$2-$3$1"+Al+(Je(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~hd(e,"stretch")?A2(le(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Je(e,t+1)!==115)break;case 6444:switch(Je(e,Sn(e)-3-(~hd(e,"!important")&&10))){case 107:return le(e,":",":"+ae)+e;case 101:return le(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ae+(Je(e,14)===45?"inline-":"")+"box$3$1"+ae+"$2$3$1"+rt+"$2box$3")+e}break;case 5936:switch(Je(e,t+11)){case 114:return ae+e+rt+le(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return ae+e+rt+le(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return ae+e+rt+le(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return ae+e+rt+e+e}return e}var E5=function(t,n,r,i){if(t.length>-1&&!t.return)switch(t.type){case Gp:t.return=A2(t.value,t.length);break;case _2:return Mi([po(t,{value:le(t.value,"@","@"+ae)})],i);case Kp:if(t.length)return i5(t.props,function(o){switch(r5(o,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Mi([po(t,{props:[le(o,/:(read-\w+)/,":"+Al+"$1")]})],i);case"::placeholder":return Mi([po(t,{props:[le(o,/:(plac\w+)/,":"+ae+"input-$1")]}),po(t,{props:[le(o,/:(plac\w+)/,":"+Al+"$1")]}),po(t,{props:[le(o,/:(plac\w+)/,rt+"input-$1")]})],i)}return""})}},_5=[E5],x5=function(t){var n=t.key;if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(m){var w=m.getAttribute("data-emotion");w.indexOf(" ")!==-1&&(document.head.appendChild(m),m.setAttribute("data-s",""))})}var i=t.stylisPlugins||_5,o={},a,s=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(m){for(var w=m.getAttribute("data-emotion").split(" "),p=1;p=4;++r,i-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var P5={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},I5=/[A-Z]|^ms/g,M5=/_EMO_([^_]+?)_([^]*?)_EMO_/g,I2=function(t){return t.charCodeAt(1)===45},jv=function(t){return t!=null&&typeof t!="boolean"},Fc=v5(function(e){return I2(e)?e:e.replace(I5,"-$&").toLowerCase()}),Fv=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(M5,function(r,i,o){return bn={name:i,styles:o,next:bn},i})}return P5[t]!==1&&!I2(t)&&typeof n=="number"&&n!==0?n+"px":n};function pa(e,t,n){if(n==null)return"";if(n.__emotion_styles!==void 0)return n;switch(typeof n){case"boolean":return"";case"object":{if(n.anim===1)return bn={name:n.name,styles:n.styles,next:bn},n.name;if(n.styles!==void 0){var r=n.next;if(r!==void 0)for(;r!==void 0;)bn={name:r.name,styles:r.styles,next:bn},r=r.next;var i=n.styles+";";return i}return L5(e,t,n)}case"function":{if(e!==void 0){var o=bn,a=n(e);return bn=o,pa(e,t,a)}break}}if(t==null)return n;var s=t[n];return s!==void 0?s:n}function L5(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i({x:e,y:e});function q5(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function T2(e){return $2(e)?(e.nodeName||"").toLowerCase():"#document"}function fn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function D2(e){var t;return(t=($2(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function $2(e){return e instanceof Node||e instanceof fn(e).Node}function gd(e){return e instanceof Element||e instanceof fn(e).Element}function Zp(e){return e instanceof HTMLElement||e instanceof fn(e).HTMLElement}function Nv(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof fn(e).ShadowRoot}function j2(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Xp(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function K5(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function G5(e){return["html","body","#document"].includes(T2(e))}function Xp(e){return fn(e).getComputedStyle(e)}function Q5(e){if(T2(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Nv(e)&&e.host||D2(e);return Nv(t)?t.host:t}function F2(e){const t=Q5(e);return G5(t)?e.ownerDocument?e.ownerDocument.body:e.body:Zp(t)&&j2(t)?t:F2(t)}function yd(e,t){var n;t===void 0&&(t=[]);const r=F2(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=fn(r);return i?t.concat(o,o.visualViewport||[],j2(r)?r:[]):t.concat(r,yd(r))}function Y5(e){const t=Xp(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Zp(e),o=i?e.offsetWidth:n,a=i?e.offsetHeight:r,s=Pl(n)!==o||Pl(r)!==a;return s&&(n=o,r=a),{width:n,height:r,$:s}}function eh(e){return gd(e)?e:e.contextElement}function Rc(e){const t=eh(e);if(!Zp(t))return Il(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=Y5(t);let a=(o?Pl(n.width):n.width)/r,s=(o?Pl(n.height):n.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const J5=Il(0);function Z5(e){const t=fn(e);return!K5()||!t.visualViewport?J5:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function X5(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==fn(e)?!1:t}function zv(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=eh(e);let a=Il(1);t&&(r?gd(r)&&(a=Rc(r)):a=Rc(e));const s=X5(o,n,r)?Z5(o):Il(0);let l=(i.left+s.x)/a.x,u=(i.top+s.y)/a.y,c=i.width/a.x,f=i.height/a.y;if(o){const d=fn(o),h=r&&gd(r)?fn(r):r;let y=d.frameElement;for(;y&&r&&h!==d;){const m=Rc(y),w=y.getBoundingClientRect(),p=Xp(y),v=w.left+(y.clientLeft+parseFloat(p.paddingLeft))*m.x,g=w.top+(y.clientTop+parseFloat(p.paddingTop))*m.y;l*=m.x,u*=m.y,c*=m.x,f*=m.y,l+=v,u+=g,y=fn(y).frameElement}}return q5({width:c,height:f,x:l,y:u})}function eO(e,t){let n=null,r;const i=D2(e);function o(){clearTimeout(r),n&&n.disconnect(),n=null}function a(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),o();const{left:u,top:c,width:f,height:d}=e.getBoundingClientRect();if(s||t(),!f||!d)return;const h=ss(c),y=ss(i.clientWidth-(u+f)),m=ss(i.clientHeight-(c+d)),w=ss(u),v={rootMargin:-h+"px "+-y+"px "+-m+"px "+-w+"px",threshold:W5(0,H5(1,l))||1};let g=!0;function S(_){const x=_[0].intersectionRatio;if(x!==l){if(!g)return a();x?a(!1,x):r=setTimeout(()=>{a(!1,1e-7)},100)}g=!1}try{n=new IntersectionObserver(S,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(S,v)}n.observe(e)}return a(!0),o}function tO(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=eh(e),c=i||o?[...u?yd(u):[],...yd(t)]:[];c.forEach(p=>{i&&p.addEventListener("scroll",n,{passive:!0}),o&&p.addEventListener("resize",n)});const f=u&&s?eO(u,n):null;let d=-1,h=null;a&&(h=new ResizeObserver(p=>{let[v]=p;v&&v.target===u&&h&&(h.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{h&&h.observe(t)})),n()}),u&&!l&&h.observe(u),h.observe(t));let y,m=l?zv(e):null;l&&w();function w(){const p=zv(e);m&&(p.x!==m.x||p.y!==m.y||p.width!==m.width||p.height!==m.height)&&n(),m=p,y=requestAnimationFrame(w)}return n(),()=>{c.forEach(p=>{i&&p.removeEventListener("scroll",n),o&&p.removeEventListener("resize",n)}),f&&f(),h&&h.disconnect(),h=null,l&&cancelAnimationFrame(y)}}var wd=b.useLayoutEffect,nO=["className","clearValue","cx","getStyles","getClassNames","getValue","hasValue","isMulti","isRtl","options","selectOption","selectProps","setValue","theme"],Ml=function(){};function rO(e,t){return t?t[0]==="-"?e+t:e+"__"+t:e}function iO(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i-1}function oO(e){return Lu(e)?window.innerHeight:e.clientHeight}function N2(e){return Lu(e)?window.pageYOffset:e.scrollTop}function Ll(e,t){if(Lu(e)){window.scrollTo(0,t);return}e.scrollTop=t}function aO(e){var t=getComputedStyle(e),n=t.position==="absolute",r=/(auto|scroll)/;if(t.position==="fixed")return document.documentElement;for(var i=e;i=i.parentElement;)if(t=getComputedStyle(i),!(n&&t.position==="static")&&r.test(t.overflow+t.overflowY+t.overflowX))return i;return document.documentElement}function sO(e,t,n,r){return n*((e=e/r-1)*e*e+1)+t}function ls(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:200,r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:Ml,i=N2(e),o=t-i,a=10,s=0;function l(){s+=a;var u=sO(s,i,o,n);Ll(e,u),sn.bottom?Ll(e,Math.min(t.offsetTop+t.clientHeight-e.offsetHeight+i,e.scrollHeight)):r.top-i1?n-1:0),i=1;i=y)return{placement:"bottom",maxHeight:t};if(k>=y&&!a)return o&&ls(l,P,j),{placement:"bottom",maxHeight:t};if(!a&&k>=r||a&&E>=r){o&&ls(l,P,j);var U=a?E-S:k-S;return{placement:"bottom",maxHeight:U}}if(i==="auto"||a){var z=t,L=a?x:C;return L>=r&&(z=Math.min(L-S-s,t)),{placement:"top",maxHeight:z}}if(i==="bottom")return o&&Ll(l,P),{placement:"bottom",maxHeight:t};break;case"top":if(x>=y)return{placement:"top",maxHeight:t};if(C>=y&&!a)return o&&ls(l,$,j),{placement:"top",maxHeight:t};if(!a&&C>=r||a&&x>=r){var M=t;return(!a&&C>=r||a&&x>=r)&&(M=a?x-_:C-_),o&&ls(l,$,j),{placement:"top",maxHeight:M}}return{placement:"bottom",maxHeight:t};default:throw new Error('Invalid placement provided "'.concat(i,'".'))}return u}function yO(e){var t={bottom:"top",top:"bottom"};return e?t[e]:"bottom"}var V2=function(t){return t==="auto"?"bottom":t},wO=function(t,n){var r,i=t.placement,o=t.theme,a=o.borderRadius,s=o.spacing,l=o.colors;return Q((r={label:"menu"},xo(r,yO(i),"100%"),xo(r,"position","absolute"),xo(r,"width","100%"),xo(r,"zIndex",1),r),n?{}:{backgroundColor:l.neutral0,borderRadius:a,boxShadow:"0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)",marginBottom:s.menuGutter,marginTop:s.menuGutter})},B2=b.createContext(null),SO=function(t){var n=t.children,r=t.minMenuHeight,i=t.maxMenuHeight,o=t.menuPlacement,a=t.menuPosition,s=t.menuShouldScrollIntoView,l=t.theme,u=b.useContext(B2)||{},c=u.setPortalPlacement,f=b.useRef(null),d=b.useState(i),h=zn(d,2),y=h[0],m=h[1],w=b.useState(null),p=zn(w,2),v=p[0],g=p[1],S=l.spacing.controlHeight;return wd(function(){var _=f.current;if(_){var x=a==="fixed",E=s&&!x,C=gO({maxHeight:i,menuEl:_,minHeight:r,placement:o,shouldScroll:E,isFixedPosition:x,controlHeight:S});m(C.maxHeight),g(C.placement),c==null||c(C.placement)}},[i,o,a,s,r,c,S]),n({ref:f,placerProps:Q(Q({},t),{},{placement:v||V2(o),maxHeight:y})})},bO=function(t){var n=t.children,r=t.innerRef,i=t.innerProps;return Y("div",J({},De(t,"menu",{menu:!0}),{ref:r},i),n)},EO=bO,_O=function(t,n){var r=t.maxHeight,i=t.theme.spacing.baseUnit;return Q({maxHeight:r,overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},n?{}:{paddingBottom:i,paddingTop:i})},xO=function(t){var n=t.children,r=t.innerProps,i=t.innerRef,o=t.isMulti;return Y("div",J({},De(t,"menuList",{"menu-list":!0,"menu-list--is-multi":o}),{ref:i},r),n)},U2=function(t,n){var r=t.theme,i=r.spacing.baseUnit,o=r.colors;return Q({textAlign:"center"},n?{}:{color:o.neutral40,padding:"".concat(i*2,"px ").concat(i*3,"px")})},CO=U2,OO=U2,kO=function(t){var n=t.children,r=n===void 0?"No options":n,i=t.innerProps,o=Gn(t,mO);return Y("div",J({},De(Q(Q({},o),{},{children:r,innerProps:i}),"noOptionsMessage",{"menu-notice":!0,"menu-notice--no-options":!0}),i),r)},AO=function(t){var n=t.children,r=n===void 0?"Loading...":n,i=t.innerProps,o=Gn(t,vO);return Y("div",J({},De(Q(Q({},o),{},{children:r,innerProps:i}),"loadingMessage",{"menu-notice":!0,"menu-notice--loading":!0}),i),r)},PO=function(t){var n=t.rect,r=t.offset,i=t.position;return{left:n.left,position:i,top:r,width:n.width,zIndex:1}},IO=function(t){var n=t.appendTo,r=t.children,i=t.controlElement,o=t.innerProps,a=t.menuPlacement,s=t.menuPosition,l=b.useRef(null),u=b.useRef(null),c=b.useState(V2(a)),f=zn(c,2),d=f[0],h=f[1],y=b.useMemo(function(){return{setPortalPlacement:h}},[]),m=b.useState(null),w=zn(m,2),p=w[0],v=w[1],g=b.useCallback(function(){if(i){var E=lO(i),C=s==="fixed"?0:window.pageYOffset,k=E[d]+C;(k!==(p==null?void 0:p.offset)||E.left!==(p==null?void 0:p.rect.left)||E.width!==(p==null?void 0:p.rect.width))&&v({offset:k,rect:E})}},[i,s,d,p==null?void 0:p.offset,p==null?void 0:p.rect.left,p==null?void 0:p.rect.width]);wd(function(){g()},[g]);var S=b.useCallback(function(){typeof u.current=="function"&&(u.current(),u.current=null),i&&l.current&&(u.current=tO(i,l.current,g,{elementResize:"ResizeObserver"in window}))},[i,g]);wd(function(){S()},[S]);var _=b.useCallback(function(E){l.current=E,S()},[S]);if(!n&&s!=="fixed"||!p)return null;var x=Y("div",J({ref:_},De(Q(Q({},t),{},{offset:p.offset,position:s,rect:p.rect}),"menuPortal",{"menu-portal":!0}),o),r);return Y(B2.Provider,{value:y},n?Ep.createPortal(x,n):x)},MO=function(t){var n=t.isDisabled,r=t.isRtl;return{label:"container",direction:r?"rtl":void 0,pointerEvents:n?"none":void 0,position:"relative"}},LO=function(t){var n=t.children,r=t.innerProps,i=t.isDisabled,o=t.isRtl;return Y("div",J({},De(t,"container",{"--is-disabled":i,"--is-rtl":o}),r),n)},TO=function(t,n){var r=t.theme.spacing,i=t.isMulti,o=t.hasValue,a=t.selectProps.controlShouldRenderValue;return Q({alignItems:"center",display:i&&o&&a?"flex":"grid",flex:1,flexWrap:"wrap",WebkitOverflowScrolling:"touch",position:"relative",overflow:"hidden"},n?{}:{padding:"".concat(r.baseUnit/2,"px ").concat(r.baseUnit*2,"px")})},DO=function(t){var n=t.children,r=t.innerProps,i=t.isMulti,o=t.hasValue;return Y("div",J({},De(t,"valueContainer",{"value-container":!0,"value-container--is-multi":i,"value-container--has-value":o}),r),n)},$O=function(){return{alignItems:"center",alignSelf:"stretch",display:"flex",flexShrink:0}},jO=function(t){var n=t.children,r=t.innerProps;return Y("div",J({},De(t,"indicatorsContainer",{indicators:!0}),r),n)},Hv,FO=["size"],RO=["innerProps","isRtl","size"],NO={name:"8mmkcg",styles:"display:inline-block;fill:currentColor;line-height:1;stroke:currentColor;stroke-width:0"},H2=function(t){var n=t.size,r=Gn(t,FO);return Y("svg",J({height:n,width:n,viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",css:NO},r))},th=function(t){return Y(H2,J({size:20},t),Y("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"}))},W2=function(t){return Y(H2,J({size:20},t),Y("path",{d:"M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z"}))},q2=function(t,n){var r=t.isFocused,i=t.theme,o=i.spacing.baseUnit,a=i.colors;return Q({label:"indicatorContainer",display:"flex",transition:"color 150ms"},n?{}:{color:r?a.neutral60:a.neutral20,padding:o*2,":hover":{color:r?a.neutral80:a.neutral40}})},zO=q2,VO=function(t){var n=t.children,r=t.innerProps;return Y("div",J({},De(t,"dropdownIndicator",{indicator:!0,"dropdown-indicator":!0}),r),n||Y(W2,null))},BO=q2,UO=function(t){var n=t.children,r=t.innerProps;return Y("div",J({},De(t,"clearIndicator",{indicator:!0,"clear-indicator":!0}),r),n||Y(th,null))},HO=function(t,n){var r=t.isDisabled,i=t.theme,o=i.spacing.baseUnit,a=i.colors;return Q({label:"indicatorSeparator",alignSelf:"stretch",width:1},n?{}:{backgroundColor:r?a.neutral10:a.neutral20,marginBottom:o*2,marginTop:o*2})},WO=function(t){var n=t.innerProps;return Y("span",J({},n,De(t,"indicatorSeparator",{"indicator-separator":!0})))},qO=B5(Hv||(Hv=U5([` + `},Wm=j_(z_)(ly),V_={config:R_},B_=function(){for(var t=arguments.length,n=new Array(t),r=0;r{r.current=!1}:e,t)}var Ot=s4;function jo(){}function bi(e,t,n,r){return l4(e,r)||u4(e,t,n,r)}function l4(e,t){return e.editor.getModel(my(e,t))}function u4(e,t,n,r){return e.editor.createModel(t,n,r?my(e,r):void 0)}function my(e,t){return e.Uri.parse(t)}function c4({original:e,modified:t,language:n,originalLanguage:r,modifiedLanguage:i,originalModelPath:o,modifiedModelPath:a,keepCurrentOriginalModel:s=!1,keepCurrentModifiedModel:l=!1,theme:u="light",loading:c="Loading...",options:f={},height:d="100%",width:h="100%",className:y,wrapperProps:m={},beforeMount:w=jo,onMount:p=jo}){let[v,g]=b.useState(!1),[S,E]=b.useState(!0),x=b.useRef(null),_=b.useRef(null),C=b.useRef(null),k=b.useRef(p),P=b.useRef(w),$=b.useRef(!1);hy(()=>{let L=dy.init();return L.then(M=>(_.current=M)&&E(!1)).catch(M=>(M==null?void 0:M.type)!=="cancelation"&&console.error("Monaco initialization: error:",M)),()=>x.current?j():L.cancel()}),Ot(()=>{if(x.current&&_.current){let L=x.current.getOriginalEditor(),M=bi(_.current,e||"",r||n||"text",o||"");M!==L.getModel()&&L.setModel(M)}},[o],v),Ot(()=>{if(x.current&&_.current){let L=x.current.getModifiedEditor(),M=bi(_.current,t||"",i||n||"text",a||"");M!==L.getModel()&&L.setModel(M)}},[a],v),Ot(()=>{let L=x.current.getModifiedEditor();L.getOption(_.current.editor.EditorOption.readOnly)?L.setValue(t||""):t!==L.getValue()&&(L.executeEdits("",[{range:L.getModel().getFullModelRange(),text:t||"",forceMoveMarkers:!0}]),L.pushUndoStop())},[t],v),Ot(()=>{var L,M;(M=(L=x.current)==null?void 0:L.getModel())==null||M.original.setValue(e||"")},[e],v),Ot(()=>{let{original:L,modified:M}=x.current.getModel();_.current.editor.setModelLanguage(L,r||n||"text"),_.current.editor.setModelLanguage(M,i||n||"text")},[n,r,i],v),Ot(()=>{var L;(L=_.current)==null||L.editor.setTheme(u)},[u],v),Ot(()=>{var L;(L=x.current)==null||L.updateOptions(f)},[f],v);let F=b.useCallback(()=>{var D;if(!_.current)return;P.current(_.current);let L=bi(_.current,e||"",r||n||"text",o||""),M=bi(_.current,t||"",i||n||"text",a||"");(D=x.current)==null||D.setModel({original:L,modified:M})},[n,t,i,e,r,o,a]),H=b.useCallback(()=>{var L;!$.current&&C.current&&(x.current=_.current.editor.createDiffEditor(C.current,{automaticLayout:!0,...f}),F(),(L=_.current)==null||L.editor.setTheme(u),g(!0),$.current=!0)},[f,u,F]);b.useEffect(()=>{v&&k.current(x.current,_.current)},[v]),b.useEffect(()=>{!S&&!v&&H()},[S,v,H]);function j(){var M,D,A,I;let L=(M=x.current)==null?void 0:M.getModel();s||((D=L==null?void 0:L.original)==null||D.dispose()),l||((A=L==null?void 0:L.modified)==null||A.dispose()),(I=x.current)==null||I.dispose()}return ee.createElement(py,{width:h,height:d,isEditorReady:v,loading:c,_ref:C,className:y,wrapperProps:m})}var f4=c4;b.memo(f4);function d4(e){let t=b.useRef();return b.useEffect(()=>{t.current=e},[e]),t.current}var p4=d4,ns=new Map;function h4({defaultValue:e,defaultLanguage:t,defaultPath:n,value:r,language:i,path:o,theme:a="light",line:s,loading:l="Loading...",options:u={},overrideServices:c={},saveViewState:f=!0,keepCurrentModel:d=!1,width:h="100%",height:y="100%",className:m,wrapperProps:w={},beforeMount:p=jo,onMount:v=jo,onChange:g,onValidate:S=jo}){let[E,x]=b.useState(!1),[_,C]=b.useState(!0),k=b.useRef(null),P=b.useRef(null),$=b.useRef(null),F=b.useRef(v),H=b.useRef(p),j=b.useRef(),L=b.useRef(r),M=p4(o),D=b.useRef(!1),A=b.useRef(!1);hy(()=>{let N=dy.init();return N.then(V=>(k.current=V)&&C(!1)).catch(V=>(V==null?void 0:V.type)!=="cancelation"&&console.error("Monaco initialization: error:",V)),()=>P.current?R():N.cancel()}),Ot(()=>{var V,T,z,U;let N=bi(k.current,e||r||"",t||i||"",o||n||"");N!==((V=P.current)==null?void 0:V.getModel())&&(f&&ns.set(M,(T=P.current)==null?void 0:T.saveViewState()),(z=P.current)==null||z.setModel(N),f&&((U=P.current)==null||U.restoreViewState(ns.get(o))))},[o],E),Ot(()=>{var N;(N=P.current)==null||N.updateOptions(u)},[u],E),Ot(()=>{!P.current||r===void 0||(P.current.getOption(k.current.editor.EditorOption.readOnly)?P.current.setValue(r):r!==P.current.getValue()&&(A.current=!0,P.current.executeEdits("",[{range:P.current.getModel().getFullModelRange(),text:r,forceMoveMarkers:!0}]),P.current.pushUndoStop(),A.current=!1))},[r],E),Ot(()=>{var V,T;let N=(V=P.current)==null?void 0:V.getModel();N&&i&&((T=k.current)==null||T.editor.setModelLanguage(N,i))},[i],E),Ot(()=>{var N;s!==void 0&&((N=P.current)==null||N.revealLine(s))},[s],E),Ot(()=>{var N;(N=k.current)==null||N.editor.setTheme(a)},[a],E);let I=b.useCallback(()=>{var N;if(!(!$.current||!k.current)&&!D.current){H.current(k.current);let V=o||n,T=bi(k.current,r||e||"",t||i||"",V||"");P.current=(N=k.current)==null?void 0:N.editor.create($.current,{model:T,automaticLayout:!0,...u},c),f&&P.current.restoreViewState(ns.get(V)),k.current.editor.setTheme(a),x(!0),D.current=!0}},[e,t,n,r,i,o,u,c,f,a]);b.useEffect(()=>{E&&F.current(P.current,k.current)},[E]),b.useEffect(()=>{!_&&!E&&I()},[_,E,I]),L.current=r,b.useEffect(()=>{var N,V;E&&g&&((N=j.current)==null||N.dispose(),j.current=(V=P.current)==null?void 0:V.onDidChangeModelContent(T=>{A.current||g(P.current.getValue(),T)}))},[E,g]),b.useEffect(()=>{if(E){let N=k.current.editor.onDidChangeMarkers(V=>{var z;let T=(z=P.current.getModel())==null?void 0:z.uri;if(T&&V.find(U=>U.path===T.path)){let U=k.current.editor.getModelMarkers({resource:T});S==null||S(U)}});return()=>{N==null||N.dispose()}}return()=>{}},[E,S]);function R(){var N,V;(N=j.current)==null||N.dispose(),d?f&&ns.set(o,P.current.saveViewState()):(V=P.current.getModel())==null||V.dispose(),P.current.dispose()}return ee.createElement(py,{width:h,height:y,isEditorReady:E,loading:l,_ref:$,className:m,wrapperProps:w})}var m4=h4,v4=b.memo(m4),g4=v4;function vy(e){return mn({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"m18.988 2.012 3 3L19.701 7.3l-3-3zM8 16h3l7.287-7.287-3-3L8 13z"}},{tag:"path",attr:{d:"M19 19H8.158c-.026 0-.053.01-.079.01-.033 0-.066-.009-.1-.01H5V5h6.847l2-2H5c-1.103 0-2 .896-2 2v14c0 1.104.897 2 2 2h14a2 2 0 0 0 2-2v-8.668l-2 2V19z"}}]})(e)}function gy(e){return mn({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M5 21h14a2 2 0 0 0 2-2V8l-5-5H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2zM7 5h4v2h2V5h2v4H7V5zm0 8h10v6H7v-6z"}}]})(e)}const{createElement:Bi,createContext:y4,forwardRef:yy,useCallback:Jn,useContext:wy,useEffect:Nn,useImperativeHandle:Sy,useLayoutEffect:w4,useMemo:S4,useRef:kt,useState:Fo}=Fs,qm=Fs["useId".toString()],pl=w4,b4=typeof qm=="function"?qm:()=>null;let E4=0;function Ap(e=null){const t=b4(),n=kt(e||t||null);return n.current===null&&(n.current=""+E4++),n.current}const _u=y4(null);_u.displayName="PanelGroupContext";function by({children:e=null,className:t="",collapsedSize:n=0,collapsible:r=!1,defaultSize:i=null,forwardedRef:o,id:a=null,maxSize:s=100,minSize:l=10,onCollapse:u=null,onResize:c=null,order:f=null,style:d={},tagName:h="div"}){const y=wy(_u);if(y===null)throw Error("Panel components must be rendered within a PanelGroup container");const m=Ap(a),{collapsePanel:w,expandPanel:p,getPanelStyle:v,registerPanel:g,resizePanel:S,unregisterPanel:E}=y,x=kt({onCollapse:u,onResize:c});if(Nn(()=>{x.current.onCollapse=u,x.current.onResize=c}),l<0||l>100)throw Error(`Panel minSize must be between 0 and 100, but was ${l}`);if(s<0||s>100)throw Error(`Panel maxSize must be between 0 and 100, but was ${s}`);if(i!==null){if(i<0||i>100)throw Error(`Panel defaultSize must be between 0 and 100, but was ${i}`);l>i&&!r&&(console.error(`Panel minSize ${l} cannot be greater than defaultSize ${i}`),i=l)}const _=v(m,i),C=kt({size:Km(_)}),k=kt({callbacksRef:x,collapsedSize:n,collapsible:r,defaultSize:i,id:m,idWasAutoGenerated:a==null,maxSize:s,minSize:l,order:f});return pl(()=>{C.current.size=Km(_),k.current.callbacksRef=x,k.current.collapsedSize=n,k.current.collapsible=r,k.current.defaultSize=i,k.current.id=m,k.current.idWasAutoGenerated=a==null,k.current.maxSize=s,k.current.minSize=l,k.current.order=f}),pl(()=>(g(m,k),()=>{E(m)}),[f,m,g,E]),Sy(o,()=>({collapse:()=>w(m),expand:()=>p(m),getCollapsed(){return C.current.size===0},getSize(){return C.current.size},resize:P=>S(m,P)}),[w,p,m,S]),Bi(h,{children:e,className:t,"data-panel":"","data-panel-collapsible":r||void 0,"data-panel-id":m,"data-panel-size":parseFloat(""+_.flexGrow).toFixed(1),id:`data-panel-id-${m}`,style:{..._,...d}})}const ks=yy((e,t)=>Bi(by,{...e,forwardedRef:t}));by.displayName="Panel";ks.displayName="forwardRef(Panel)";function Km(e){const{flexGrow:t}=e;return typeof t=="string"?parseFloat(t):t}const Wr=10;function bo(e,t,n,r,i,o,a,s){const{sizes:l}=s||{},u=l||o;if(i===0)return u;const c=zt(t),f=u.concat();let d=0;{const m=i<0?r:n,w=c.findIndex(S=>S.current.id===m),p=c[w],v=u[w],g=Gm(p,Math.abs(i),v,e);if(v===g)return u;g===0&&v>0&&a.set(m,v),i=i<0?v-g:g-v}let h=i<0?n:r,y=c.findIndex(m=>m.current.id===h);for(;;){const m=c[y],w=u[y],p=Math.abs(i)-Math.abs(d),v=Gm(m,0-p,w,e);if(w!==v&&(v===0&&w>0&&a.set(m.current.id,w),d+=w-v,f[y]=v,d.toPrecision(Wr).localeCompare(Math.abs(i).toPrecision(Wr),void 0,{numeric:!0})>=0))break;if(i<0){if(--y<0)break}else if(++y>=c.length)break}return d===0?u:(h=i<0?r:n,y=c.findIndex(m=>m.current.id===h),f[y]=u[y]+d,f)}function ii(e,t,n){t.forEach((r,i)=>{const o=e[i];if(!o)return;const{callbacksRef:a,collapsedSize:s,collapsible:l,id:u}=o.current,c=n[u];if(c!==r){n[u]=r;const{onCollapse:f,onResize:d}=a.current;d&&d(r,c),l&&f&&((c==null||c===s)&&r!==s?f(!1):c!==s&&r===s&&f(!0))}})}function _c(e,t){if(t.length<2)return[null,null];const n=t.findIndex(a=>a.current.id===e);if(n<0)return[null,null];const r=n===t.length-1,i=r?t[n-1].current.id:e,o=r?e:t[n+1].current.id;return[i,o]}function Ey(e,t,n){if(e.size===1)return"100";const i=zt(e).findIndex(a=>a.current.id===t),o=n[i];return o==null?"0":o.toPrecision(Wr)}function _4(e){const t=document.querySelector(`[data-panel-id="${e}"]`);return t||null}function Pp(e){const t=document.querySelector(`[data-panel-group-id="${e}"]`);return t||null}function xu(e){const t=document.querySelector(`[data-panel-resize-handle-id="${e}"]`);return t||null}function x4(e){return _y().findIndex(r=>r.getAttribute("data-panel-resize-handle-id")===e)??null}function _y(){return Array.from(document.querySelectorAll("[data-panel-resize-handle-id]"))}function xy(e){return Array.from(document.querySelectorAll(`[data-panel-resize-handle-id][data-panel-group-id="${e}"]`))}function Ip(e,t,n){var l,u,c,f;const r=xu(t),i=xy(e),o=r?i.indexOf(r):-1,a=((u=(l=n[o])==null?void 0:l.current)==null?void 0:u.id)??null,s=((f=(c=n[o+1])==null?void 0:c.current)==null?void 0:f.id)??null;return[a,s]}function zt(e){return Array.from(e.values()).sort((t,n)=>{const r=t.current.order,i=n.current.order;return r==null&&i==null?0:r==null?-1:i==null?1:r-i})}function Gm(e,t,n,r){var c;const i=n+t,{collapsedSize:o,collapsible:a,maxSize:s,minSize:l}=e.current;if(a){if(n>o){if(i<=l/2+o)return o}else if(!((c=r==null?void 0:r.type)==null?void 0:c.startsWith("key"))&&i{const{direction:a,panels:s}=e.current,l=Pp(t),{height:u,width:c}=l.getBoundingClientRect(),d=xy(t).map(h=>{const y=h.getAttribute("data-panel-resize-handle-id"),m=zt(s),[w,p]=Ip(t,y,m);if(w==null||p==null)return()=>{};let v=0,g=100,S=0,E=0;m.forEach($=>{$.current.id===w?(g=$.current.maxSize,v=$.current.minSize):(S+=$.current.minSize,E+=$.current.maxSize)});const x=Math.min(g,100-S),_=Math.max(v,(m.length-1)*100-E),C=Ey(s,w,i);h.setAttribute("aria-valuemax",""+Math.round(x)),h.setAttribute("aria-valuemin",""+Math.round(_)),h.setAttribute("aria-valuenow",""+Math.round(parseInt(C)));const k=$=>{if(!$.defaultPrevented)switch($.key){case"Enter":{$.preventDefault();const F=m.findIndex(H=>H.current.id===w);if(F>=0){const H=m[F],j=i[F];if(j!=null){let L=0;j.toPrecision(Wr)<=H.current.minSize.toPrecision(Wr)?L=a==="horizontal"?c:u:L=-(a==="horizontal"?c:u);const M=bo($,s,w,p,L,i,o.current,null);i!==M&&r(M)}}break}}};h.addEventListener("keydown",k);const P=_4(w);return P!=null&&h.setAttribute("aria-controls",P.id),()=>{h.removeAttribute("aria-valuemax"),h.removeAttribute("aria-valuemin"),h.removeAttribute("aria-valuenow"),h.removeEventListener("keydown",k),P!=null&&h.removeAttribute("aria-controls")}});return()=>{d.forEach(h=>h())}},[e,t,n,o,r,i])}function O4({disabled:e,handleId:t,resizeHandler:n}){Nn(()=>{if(e||n==null)return;const r=xu(t);if(r==null)return;const i=o=>{if(!o.defaultPrevented)switch(o.key){case"ArrowDown":case"ArrowLeft":case"ArrowRight":case"ArrowUp":case"End":case"Home":{o.preventDefault(),n(o);break}case"F6":{o.preventDefault();const a=_y(),s=x4(t);Cy(s!==null);const l=o.shiftKey?s>0?s-1:a.length-1:s+1{r.removeEventListener("keydown",i)}},[e,t,n])}function k4(e,t){if(e.length!==t.length)return!1;for(let n=0;n_.current.id===S),x=r[E];if(x.current.collapsible){const _=c[E];(_===0||_.toPrecision(Wr)===x.current.minSize.toPrecision(Wr))&&(p=p<0?-x.current.minSize*y:x.current.minSize*y)}return p}else return Oy(e,n,i,s,l)}function P4(e){return e.type==="keydown"}function Wf(e){return e.type.startsWith("mouse")}function qf(e){return e.type.startsWith("touch")}let Kf=null,$r=null;function ky(e){switch(e){case"horizontal":return"ew-resize";case"horizontal-max":return"w-resize";case"horizontal-min":return"e-resize";case"vertical":return"ns-resize";case"vertical-max":return"n-resize";case"vertical-min":return"s-resize"}}function I4(){$r!==null&&(document.head.removeChild($r),Kf=null,$r=null)}function xc(e){if(Kf===e)return;Kf=e;const t=ky(e);$r===null&&($r=document.createElement("style"),document.head.appendChild($r)),$r.innerHTML=`*{cursor: ${t}!important;}`}function M4(e,t=10){let n=null;return(...i)=>{n!==null&&clearTimeout(n),n=setTimeout(()=>{e(...i)},t)}}function Ay(e){return e.map(t=>{const{minSize:n,order:r}=t.current;return r?`${r}:${n}`:`${n}`}).sort((t,n)=>t.localeCompare(n)).join(",")}function Py(e,t){try{const n=t.getItem(`PanelGroup:sizes:${e}`);if(n){const r=JSON.parse(n);if(typeof r=="object"&&r!=null)return r}}catch{}return null}function L4(e,t,n){const r=Py(e,n);if(r){const i=Ay(t);return r[i]??null}return null}function T4(e,t,n,r){const i=Ay(t),o=Py(e,r)||{};o[i]=n;try{r.setItem(`PanelGroup:sizes:${e}`,JSON.stringify(o))}catch(a){console.error(a)}}const Cc={};function Qm(e){try{if(typeof localStorage<"u")e.getItem=t=>localStorage.getItem(t),e.setItem=(t,n)=>{localStorage.setItem(t,n)};else throw new Error("localStorage not supported in this environment")}catch(t){console.error(t),e.getItem=()=>null,e.setItem=()=>{}}}const Eo={getItem:e=>(Qm(Eo),Eo.getItem(e)),setItem:(e,t)=>{Qm(Eo),Eo.setItem(e,t)}};function Iy({autoSaveId:e,children:t=null,className:n="",direction:r,disablePointerEventsDuringResize:i=!1,forwardedRef:o,id:a=null,onLayout:s,storage:l=Eo,style:u={},tagName:c="div"}){const f=Ap(a),[d,h]=Fo(null),[y,m]=Fo(new Map),w=kt(null);kt({didLogDefaultSizeWarning:!1,didLogIdAndOrderWarning:!1,prevPanelIds:[]});const p=kt({onLayout:s});Nn(()=>{p.current.onLayout=s});const v=kt({}),[g,S]=Fo([]),E=kt(new Map),x=kt(0),_=kt({direction:r,panels:y,sizes:g});Sy(o,()=>({getLayout:()=>{const{sizes:D}=_.current;return D},setLayout:D=>{const A=D.reduce((V,T)=>V+T,0);Cy(A===100,"Panel sizes must add up to 100%");const{panels:I}=_.current,R=v.current,N=zt(I);S(D),ii(N,D,R)}}),[]),pl(()=>{_.current.direction=r,_.current.panels=y,_.current.sizes=g}),C4({committedValuesRef:_,groupId:f,panels:y,setSizes:S,sizes:g,panelSizeBeforeCollapse:E}),Nn(()=>{const{onLayout:D}=p.current,{panels:A,sizes:I}=_.current;if(I.length>0){D&&D(I);const R=v.current,N=zt(A);ii(N,I,R)}},[g]),pl(()=>{if(_.current.sizes.length===y.size)return;let A=null;if(e){const I=zt(y);A=L4(e,I,l)}if(A!=null)S(A);else{const I=zt(y);let R=0,N=0,V=0;if(I.forEach(T=>{V+=T.current.minSize,T.current.defaultSize===null?R++:N+=T.current.defaultSize}),N>100)throw new Error("Default panel sizes cannot exceed 100%");if(I.length>1&&R===0&&N!==100)throw new Error("Invalid default sizes specified for panels");if(V>100)throw new Error("Minimum panel sizes cannot exceed 100%");S(I.map(T=>T.current.defaultSize===null?(100-N)/R:T.current.defaultSize))}},[e,y,l]),Nn(()=>{if(e){if(g.length===0||g.length!==y.size)return;const D=zt(y);Cc[e]||(Cc[e]=M4(T4,100)),Cc[e](e,D,g,l)}},[e,y,g,l]);const C=Jn((D,A)=>{const{panels:I}=_.current;return I.size===0?{flexBasis:0,flexGrow:A??void 0,flexShrink:1,overflow:"hidden"}:{flexBasis:0,flexGrow:Ey(I,D,g),flexShrink:1,overflow:"hidden",pointerEvents:i&&d!==null?"none":void 0}},[d,i,g]),k=Jn((D,A)=>{m(I=>{if(I.has(D))return I;const R=new Map(I);return R.set(D,A),R})},[]),P=Jn(D=>I=>{I.preventDefault();const{direction:R,panels:N,sizes:V}=_.current,T=zt(N),[z,U]=Ip(f,D,T);if(z==null||U==null)return;let W=A4(I,f,D,T,R,V,w.current);if(W===0)return;const oe=Pp(f).getBoundingClientRect(),Ie=R==="horizontal";document.dir==="rtl"&&Ie&&(W=-W);const xe=Ie?oe.width:oe.height,be=W/xe*100,Ce=bo(I,N,z,U,be,V,E.current,w.current),Zt=!k4(V,Ce);if((Wf(I)||qf(I))&&x.current!=be&&xc(Zt?Ie?"horizontal":"vertical":Ie?W<0?"horizontal-min":"horizontal-max":W<0?"vertical-min":"vertical-max"),Zt){const _t=v.current;S(Ce),ii(T,Ce,_t)}x.current=be},[f]),$=Jn(D=>{m(A=>{if(!A.has(D))return A;const I=new Map(A);return I.delete(D),I})},[]),F=Jn(D=>{const{panels:A,sizes:I}=_.current,R=A.get(D);if(R==null)return;const{collapsedSize:N,collapsible:V}=R.current;if(!V)return;const T=zt(A),z=T.indexOf(R);if(z<0)return;const U=I[z];if(U===N)return;E.current.set(D,U);const[W,X]=_c(D,T);if(W==null||X==null)return;const Ie=z===T.length-1?U:N-U,xe=bo(null,A,W,X,Ie,I,E.current,null);if(I!==xe){const be=v.current;S(xe),ii(T,xe,be)}},[]),H=Jn(D=>{const{panels:A,sizes:I}=_.current,R=A.get(D);if(R==null)return;const{collapsedSize:N,minSize:V}=R.current,T=E.current.get(D)||V;if(!T)return;const z=zt(A),U=z.indexOf(R);if(U<0||I[U]!==N)return;const[X,oe]=_c(D,z);if(X==null||oe==null)return;const xe=U===z.length-1?N-T:T,be=bo(null,A,X,oe,xe,I,E.current,null);if(I!==be){const Ce=v.current;S(be),ii(z,be,Ce)}},[]),j=Jn((D,A)=>{const{panels:I,sizes:R}=_.current,N=I.get(D);if(N==null)return;const{collapsedSize:V,collapsible:T,maxSize:z,minSize:U}=N.current,W=zt(I),X=W.indexOf(N);if(X<0)return;const oe=R[X];if(oe===A)return;T&&A===V||(A=Math.min(z,Math.max(U,A)));const[Ie,xe]=_c(D,W);if(Ie==null||xe==null)return;const Ce=X===W.length-1?oe-A:A-oe,Zt=bo(null,I,Ie,xe,Ce,R,E.current,null);if(R!==Zt){const _t=v.current;S(Zt),ii(W,Zt,_t)}},[]),L=S4(()=>({activeHandleId:d,collapsePanel:F,direction:r,expandPanel:H,getPanelStyle:C,groupId:f,registerPanel:k,registerResizeHandle:P,resizePanel:j,startDragging:(D,A)=>{if(h(D),Wf(A)||qf(A)){const I=xu(D);w.current={dragHandleRect:I.getBoundingClientRect(),dragOffset:Oy(A,D,r),sizes:_.current.sizes}}},stopDragging:()=>{I4(),h(null),w.current=null},unregisterPanel:$}),[d,F,r,H,C,f,k,P,j,$]),M={display:"flex",flexDirection:r==="horizontal"?"row":"column",height:"100%",overflow:"hidden",width:"100%"};return Bi(_u.Provider,{children:Bi(c,{children:t,className:n,"data-panel-group":"","data-panel-group-direction":r,"data-panel-group-id":f,style:{...M,...u}}),value:L})}const My=yy((e,t)=>Bi(Iy,{...e,forwardedRef:t}));Iy.displayName="PanelGroup";My.displayName="forwardRef(PanelGroup)";function Gf({children:e=null,className:t="",disabled:n=!1,id:r=null,onDragging:i,style:o={},tagName:a="div"}){const s=kt(null),l=kt({onDragging:i});Nn(()=>{l.current.onDragging=i});const u=wy(_u);if(u===null)throw Error("PanelResizeHandle components must be rendered within a PanelGroup container");const{activeHandleId:c,direction:f,groupId:d,registerResizeHandle:h,startDragging:y,stopDragging:m}=u,w=Ap(r),p=c===w,[v,g]=Fo(!1),[S,E]=Fo(null),x=Jn(()=>{s.current.blur(),m();const{onDragging:k}=l.current;k&&k(!1)},[m]);Nn(()=>{if(n)E(null);else{const C=h(w);E(()=>C)}},[n,w,h]),Nn(()=>{if(n||S==null||!p)return;const C=F=>{S(F)},k=F=>{S(F)},$=s.current.ownerDocument;return $.body.addEventListener("contextmenu",x),$.body.addEventListener("mousemove",C),$.body.addEventListener("touchmove",C),$.body.addEventListener("mouseleave",k),window.addEventListener("mouseup",x),window.addEventListener("touchend",x),()=>{$.body.removeEventListener("contextmenu",x),$.body.removeEventListener("mousemove",C),$.body.removeEventListener("touchmove",C),$.body.removeEventListener("mouseleave",k),window.removeEventListener("mouseup",x),window.removeEventListener("touchend",x)}},[f,n,p,S,x]),O4({disabled:n,handleId:w,resizeHandler:S});const _={cursor:ky(f),touchAction:"none",userSelect:"none"};return Bi(a,{children:e,className:t,"data-resize-handle-active":p?"pointer":v?"keyboard":void 0,"data-panel-group-direction":f,"data-panel-group-id":d,"data-panel-resize-handle-enabled":!n,"data-panel-resize-handle-id":w,onBlur:()=>g(!1),onFocus:()=>g(!0),onMouseDown:C=>{y(w,C.nativeEvent);const{onDragging:k}=l.current;k&&k(!0)},onMouseUp:x,onTouchCancel:x,onTouchEnd:x,onTouchStart:C=>{y(w,C.nativeEvent);const{onDragging:k}=l.current;k&&k(!0)},ref:s,role:"separator",style:{..._,...o},tabIndex:0})}Gf.displayName="PanelResizeHandle";var Ym={},D4=function(e,t,n,r,i){var o=new Worker(Ym[t]||(Ym[t]=URL.createObjectURL(new Blob([e+';addEventListener("error",function(e){e=e.error;postMessage({$e$:[e.message,e.code,e.stack]})})'],{type:"text/javascript"}))));return o.onmessage=function(a){var s=a.data,l=s.$e$;if(l){var u=new Error(l[0]);u.code=l[1],u.stack=l[2],i(u,null)}else i(null,s)},o.postMessage(n,r),o},ye=Uint8Array,at=Uint16Array,Ji=Uint32Array,Zi=new ye([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),Xi=new ye([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),aa=new ye([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),Ly=function(e,t){for(var n=new at(31),r=0;r<31;++r)n[r]=t+=1<>>1|(we&21845)<<1;Yn=(Yn&52428)>>>2|(Yn&13107)<<2,Yn=(Yn&61680)>>>4|(Yn&3855)<<4,sa[we]=((Yn&65280)>>>8|(Yn&255)<<8)>>>1}var qt=function(e,t,n){for(var r=e.length,i=0,o=new at(t);i>>l]=u}else for(s=new at(r),i=0;i>>15-e[i]);return s},Wn=new ye(288);for(var we=0;we<144;++we)Wn[we]=8;for(var we=144;we<256;++we)Wn[we]=9;for(var we=256;we<280;++we)Wn[we]=7;for(var we=280;we<288;++we)Wn[we]=8;var Ui=new ye(32);for(var we=0;we<32;++we)Ui[we]=5;var jy=qt(Wn,9,0),Fy=qt(Wn,9,1),Ry=qt(Ui,5,0),Ny=qt(Ui,5,1),As=function(e){for(var t=e[0],n=1;nt&&(t=e[n]);return t},Rt=function(e,t,n){var r=t/8|0;return(e[r]|e[r+1]<<8)>>(t&7)&n},Ps=function(e,t){var n=t/8|0;return(e[n]|e[n+1]<<8|e[n+2]<<16)>>(t&7)},ba=function(e){return(e+7)/8|0},Yr=function(e,t,n){(t==null||t<0)&&(t=0),(n==null||n>e.length)&&(n=e.length);var r=new(e.BYTES_PER_ELEMENT==2?at:e.BYTES_PER_ELEMENT==4?Ji:ye)(n-t);return r.set(e.subarray(t,n)),r},zy=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],Be=function(e,t,n){var r=new Error(t||zy[e]);if(r.code=e,Error.captureStackTrace&&Error.captureStackTrace(r,Be),!n)throw r;return r},Vy=function(e,t,n){var r=e.length;if(!r||n&&n.f&&!n.l)return t||new ye(0);var i=!t||n,o=!n||n.i;n||(n={}),t||(t=new ye(r*3));var a=function(W){var X=t.length;if(W>X){var oe=new ye(Math.max(X*2,W));oe.set(t),t=oe}},s=n.f||0,l=n.p||0,u=n.b||0,c=n.l,f=n.d,d=n.m,h=n.n,y=r*8;do{if(!c){s=Rt(e,l,1);var m=Rt(e,l+1,3);if(l+=3,m)if(m==1)c=Fy,f=Ny,d=9,h=5;else if(m==2){var g=Rt(e,l,31)+257,S=Rt(e,l+10,15)+4,E=g+Rt(e,l+5,31)+1;l+=14;for(var x=new ye(E),_=new ye(19),C=0;C>>4;if(w<16)x[C++]=w;else{var H=0,j=0;for(w==16?(j=3+Rt(e,l,3),l+=2,H=x[C-1]):w==17?(j=3+Rt(e,l,7),l+=3):w==18&&(j=11+Rt(e,l,127),l+=7);j--;)x[C++]=H}}var L=x.subarray(0,g),M=x.subarray(g);d=As(L),h=As(M),c=qt(L,d,1),f=qt(M,h,1)}else Be(1);else{var w=ba(l)+4,p=e[w-4]|e[w-3]<<8,v=w+p;if(v>r){o&&Be(0);break}i&&a(u+p),t.set(e.subarray(w,v),u),n.b=u+=p,n.p=l=v*8,n.f=s;continue}if(l>y){o&&Be(0);break}}i&&a(u+131072);for(var D=(1<>>4;if(l+=H&15,l>y){o&&Be(0);break}if(H||Be(2),R<256)t[u++]=R;else if(R==256){I=l,c=null;break}else{var N=R-254;if(R>264){var C=R-257,V=Zi[C];N=Rt(e,l,(1<>>4;T||Be(3),l+=T&15;var M=$y[z];if(z>3){var V=Xi[z];M+=Ps(e,l)&(1<y){o&&Be(0);break}i&&a(u+131072);for(var U=u+N;u>>8},si=function(e,t,n){n<<=t&7;var r=t/8|0;e[r]|=n,e[r+1]|=n>>>8,e[r+2]|=n>>>16},Is=function(e,t){for(var n=[],r=0;rd&&(d=o[r].s);var h=new at(d+1),y=ml(n[c-1],h,0);if(y>t){var r=0,m=0,w=y-t,p=1<t)m+=p-(1<>>=w;m>0;){var g=o[r].s;h[g]=0&&m;--r){var S=o[r].s;h[S]==t&&(--h[S],++m)}y=t}return[new ye(h),y]},ml=function(e,t,n){return e.s==-1?Math.max(ml(e.l,t,n+1),ml(e.r,t,n+1)):t[e.s]=n},Yf=function(e){for(var t=e.length;t&&!e[--t];);for(var n=new at(++t),r=0,i=e[0],o=1,a=function(l){n[r++]=l},s=1;s<=t;++s)if(e[s]==i&&s!=t)++o;else{if(!i&&o>2){for(;o>138;o-=138)a(32754);o>2&&(a(o>10?o-11<<5|28690:o-3<<5|12305),o=0)}else if(o>3){for(a(i),--o;o>6;o-=6)a(8304);o>2&&(a(o-3<<5|8208),o=0)}for(;o--;)a(i);o=1,i=e[s]}return[n.subarray(0,r),t]},li=function(e,t){for(var n=0,r=0;r>>8,e[i+2]=e[i]^255,e[i+3]=e[i+1]^255;for(var o=0;o4&&!P[aa[F-1]];--F);var H=u+5<<3,j=li(i,Wn)+li(o,Ui)+a,L=li(i,d)+li(o,m)+a+14+3*F+li(_,P)+(2*_[16]+3*_[17]+7*_[18]);if(H<=j&&H<=L)return vl(t,c,e.subarray(l,l+u));var M,D,A,I;if(yn(t,c,1+(L15&&(yn(t,c,T[C]>>>5&127),c+=T[C]>>>12)}}else M=jy,D=Wn,A=Ry,I=Ui;for(var C=0;C255){var z=r[C]>>>18&31;si(t,c,M[z+257]),c+=D[z+257],z>7&&(yn(t,c,r[C]>>>23&31),c+=Zi[z]);var U=r[C]&31;si(t,c,A[U]),c+=I[U],U>3&&(si(t,c,r[C]>>>5&8191),c+=Xi[U])}else si(t,c,M[r[C]]),c+=D[r[C]];return si(t,c,M[256]),c+D[256]},By=new Ji([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),Cu=new ye(0),Uy=function(e,t,n,r,i,o){var a=e.length,s=new ye(r+a+5*(1+Math.ceil(a/7e3))+i),l=s.subarray(r,s.length-i),u=0;if(!t||a<8)for(var c=0;c<=a;c+=65535){var f=c+65535;f>=a&&(l[u>>3]=o),u=vl(l,u+1,e.subarray(c,f))}else{for(var d=By[t-1],h=d>>>13,y=d&8191,m=(1<7e3||P>24576)&&M>423){u=Jf(e,l,0,E,x,_,k,P,F,c-F,u),P=C=k=0,F=c;for(var D=0;D<286;++D)x[D]=0;for(var D=0;D<30;++D)_[D]=0}var A=2,I=0,R=y,N=j-L&32767;if(M>2&&H==S(c-N))for(var V=Math.min(h,M)-1,T=Math.min(32767,c),z=Math.min(258,M);N<=T&&--R&&j!=L;){if(e[c+A]==e[c+A-N]){for(var U=0;UA){if(A=U,I=N,U>V)break;for(var W=Math.min(N,U-2),X=0,D=0;DX&&(X=xe,L=oe)}}}j=L,L=w[j],N+=j-L+32768&32767}if(I){E[P++]=268435456|hl[A]<<18|Qf[I];var be=hl[A]&31,Ce=Qf[I]&31;k+=Zi[be]+Xi[Ce],++x[257+be],++_[Ce],$=c+A,++C}else E[P++]=e[c],++x[e[c]]}}u=Jf(e,l,o,E,x,_,k,P,F,c-F,u),!o&&u&7&&(u=vl(l,u+1,Cu))}return Yr(s,0,r+ba(u)+i)},$4=function(){for(var e=new Int32Array(256),t=0;t<256;++t){for(var n=t,r=9;--r;)n=(n&1&&-306674912)^n>>>1;e[t]=n}return e}(),j4=function(){var e=-1;return{p:function(t){for(var n=e,r=0;r>>8;e=n},d:function(){return~e}}},Hy=function(e,t,n,r,i){return Uy(e,t.level==null?6:t.level,t.mem==null?Math.ceil(Math.max(8,Math.min(13,Math.log(e.length)))*1.5):12+t.mem,n,r,!i)},Lp=function(e,t){var n={};for(var r in e)n[r]=e[r];for(var r in t)n[r]=t[r];return n},Jm=function(e,t,n){for(var r=e(),i=e.toString(),o=i.slice(i.indexOf("[")+1,i.lastIndexOf("]")).replace(/\s+/g,"").split(","),a=0;a>>0},Oc=function(e,t){return on(e,t)+on(e,t+4)*4294967296},Qe=function(e,t,n){for(;n;++t)e[t]=n,n>>>=8};function V4(e,t,n){return n||(n=t,t={}),typeof n!="function"&&Be(7),qy(e,t,[z4],function(r){return Ou(Tp(r.data[0],r.data[1]))},0,n)}function Tp(e,t){return Hy(e,t||{},0,0)}function B4(e,t,n){return n||(n=t,t={}),typeof n!="function"&&Be(7),qy(e,t,[N4],function(r){return Ou(Dp(r.data[0],Wy(r.data[1])))},1,n)}function Dp(e,t){return Vy(e,t)}var Ky=function(e,t,n,r){for(var i in e){var o=e[i],a=t+i,s=r;Array.isArray(o)&&(s=Lp(r,o[1]),o=o[0]),o instanceof ye?n[a]=[o,s]:(n[a+="/"]=[new ye(0),s],Ky(o,a,n,r))}},Zm=typeof TextEncoder<"u"&&new TextEncoder,Zf=typeof TextDecoder<"u"&&new TextDecoder,U4=0;try{Zf.decode(Cu,{stream:!0}),U4=1}catch{}var H4=function(e){for(var t="",n=0;;){var r=e[n++],i=(r>127)+(r>223)+(r>239);if(n+i>e.length)return[t,Yr(e,n-1)];i?i==3?(r=((r&15)<<18|(e[n++]&63)<<12|(e[n++]&63)<<6|e[n++]&63)-65536,t+=String.fromCharCode(55296|r>>10,56320|r&1023)):i&1?t+=String.fromCharCode((r&31)<<6|e[n++]&63):t+=String.fromCharCode((r&15)<<12|(e[n++]&63)<<6|e[n++]&63):t+=String.fromCharCode(r)}};function Ei(e,t){if(t){for(var n=new ye(e.length),r=0;r>1)),a=0,s=function(c){o[a++]=c},r=0;ro.length){var l=new ye(a+8+(i-r<<1));l.set(o),o=l}var u=e.charCodeAt(r);u<128||t?s(u):u<2048?(s(192|u>>6),s(128|u&63)):u>55295&&u<57344?(u=65536+(u&1047552)|e.charCodeAt(++r)&1023,s(240|u>>18),s(128|u>>12&63),s(128|u>>6&63),s(128|u&63)):(s(224|u>>12),s(128|u>>6&63),s(128|u&63))}return Yr(o,0,a)}function Xf(e,t){if(t){for(var n="",r=0;r65535&&Be(9),t+=r+4}return t},Xm=function(e,t,n,r,i,o,a,s){var l=r.length,u=n.extra,c=s&&s.length,f=ed(u);Qe(e,t,a!=null?33639248:67324752),t+=4,a!=null&&(e[t++]=20,e[t++]=n.os),e[t]=20,t+=2,e[t++]=n.flag<<1|(o<0&&8),e[t++]=i&&8,e[t++]=n.compression&255,e[t++]=n.compression>>8;var d=new Date(n.mtime==null?Date.now():n.mtime),h=d.getFullYear()-1980;if((h<0||h>119)&&Be(10),Qe(e,t,h<<25|d.getMonth()+1<<21|d.getDate()<<16|d.getHours()<<11|d.getMinutes()<<5|d.getSeconds()>>>1),t+=4,o!=-1&&(Qe(e,t,n.crc),Qe(e,t+4,o<0?-o-2:o),Qe(e,t+8,n.size)),Qe(e,t+12,l),Qe(e,t+14,f),t+=16,a!=null&&(Qe(e,t,c),Qe(e,t+6,n.attrs),Qe(e,t+10,a),t+=14),e.set(r,t),t+=l,f)for(var y in u){var m=u[y],w=m.length;Qe(e,t,+y),Qe(e,t+2,w),e.set(m,t+4),t+=4+w}return c&&(e.set(s,t),t+=c),t},G4=function(e,t,n,r,i){Qe(e,t,101010256),Qe(e,t+8,n),Qe(e,t+10,n),Qe(e,t+12,r),Qe(e,t+16,i)};function Q4(e,t,n){n||(n=t,t={}),typeof n!="function"&&Be(7);var r={};Ky(e,"",r,t);var i=Object.keys(r),o=i.length,a=0,s=0,l=o,u=new Array(o),c=[],f=function(){for(var w=0;w65535&&j(Be(11,0,1),null),!H)j(null,g);else if(x<16e4)try{j(null,Tp(g,S))}catch(L){j(L,null)}else c.push(V4(g,S,j))},m=0;m65558)return a(Be(13,0,1),null),i;var l=_n(e,s+8);if(l){var u=l,c=on(e,s+16),f=c==4294967295||u==65535;if(f){var d=on(e,s-12);f=on(e,d)==101075792,f&&(u=l=on(e,d+32),c=on(e,d+48))}for(var h=t&&t.filter,y=function(w){var p=q4(e,c,f),v=p[0],g=p[1],S=p[2],E=p[3],x=p[4],_=p[5],C=W4(e,_);c=x;var k=function($,F){$?(i(),a($,null)):(F&&(o[E]=F),--l||a(null,o))};if(!h||h({name:E,size:g,originalSize:S,compression:v}))if(!v)k(null,Yr(e,C,C+g));else if(v==8){var P=e.subarray(C,C+g);if(g<32e4)try{k(null,Dp(P,new ye(S)))}catch($){k($,null)}else r.push(B4(P,{size:S},k))}else k(Be(14,"unknown compression type "+v,1),null);else k(null,null)},m=0;m{if(n.path){const r=n.path.map(({key:i})=>i).join(".");t.nested[r]=[...t.nested[r]||[],n.message]}else t.root=[...t.root||[],n.message];return t},{nested:{}})}var et=class extends Error{constructor(t){super(t[0].message);te(this,"issues");this.name="ValiError",this.issues=t}};function Jr(e,t,n){let r=e;const i=[];if(t.forEach(o=>{try{r=o(r,n)}catch(a){if(n.abortEarly||n.abortPipeEarly)throw a;i.push(...a.issues)}}),i.length)throw new et(i);return r}function la(e,t){return[...(e==null?void 0:e.path)||[],t]}function pn(e,t){const[n,r=[]]=!e||typeof e=="string"?[e,t]:[void 0,e];return{error:n,pipe:r}}function J4(e,t,n){const{error:r,pipe:i}=pn(t,n);return{schema:"array",array:{item:e},async:!1,parse(o,a){if(!Array.isArray(o))throw new et([{reason:"type",validation:"array",origin:"value",message:r||"Invalid type",input:o,...a}]);const s=[],l=[];if(o.forEach((u,c)=>{try{s.push(e.parse(u,{...a,path:la(a,{schema:"array",input:o,key:c,value:u})}))}catch(f){if(a!=null&&a.abortEarly)throw f;l.push(...f.issues)}}),l.length)throw new et(l);return Jr(s,i,{...a,reason:"array"})}}}function kc(e,t){const{error:n,pipe:r}=pn(e,t);return{schema:"boolean",async:!1,parse(i,o){if(typeof i!="boolean")throw new et([{reason:"type",validation:"boolean",origin:"value",message:n||"Invalid type",input:i,...o}]);return Jr(i,r,{...o,reason:"boolean"})}}}function tv(e,t){return{schema:"literal",literal:e,async:!1,parse(n,r){if(n!==e)throw new et([{reason:"type",validation:"literal",origin:"value",message:t||"Invalid type",input:n,...r}]);return n}}}function Z4(e,t){return{schema:"native_enum",nativeEnum:e,async:!1,parse(n,r){if(!Object.values(e).includes(n))throw new et([{reason:"type",validation:"native_enum",origin:"value",message:t||"Invalid type",input:n,...r}]);return n}}}function Cn(e,t){const{error:n,pipe:r}=pn(e,t);return{schema:"number",async:!1,parse(i,o){if(typeof i!="number")throw new et([{reason:"type",validation:"number",origin:"value",message:n||"Invalid type",input:i,...o}]);return Jr(i,r,{...o,reason:"number"})}}}function Yt(e,t,n){const{error:r,pipe:i}=pn(t,n);return{schema:"object",object:e,async:!1,parse(o,a){if(!o||typeof o!="object"||o.toString()!=="[object Object]")throw new et([{reason:"type",validation:"object",origin:"value",message:r||"Invalid type",input:o,...a}]);const s={},l=[];if(Object.entries(e).forEach(([u,c])=>{try{const f=o[u];s[u]=c.parse(f,{...a,path:la(a,{schema:"object",input:o,key:u,value:f})})}catch(f){if(a!=null&&a.abortEarly)throw f;l.push(...f.issues)}}),l.length)throw new et(l);return Jr(s,i,{...a,reason:"object"})}}}function Re(e){return{schema:"optional",wrapped:e,async:!1,parse(t,n){return t===void 0?t:e.parse(t,n)}}}function An(e,t){const{error:n,pipe:r}=pn(e,t);return{schema:"string",async:!1,parse(i,o){if(typeof i!="string")throw new et([{reason:"type",validation:"string",origin:"value",message:n||"Invalid type",input:i,...o}]);return Jr(i,r,{...o,reason:"string"})}}}function X4(e,t,n,r){const{key:i,value:o,error:a,pipe:s}=typeof t=="object"&&!Array.isArray(t)?{key:e,value:t,...pn(n,r)}:{key:An(),value:e,...pn(t,n)};return{schema:"record",record:{key:i,value:o},async:!1,parse(l,u){if(!l||typeof l!="object"||l.toString()!=="[object Object]")throw new et([{reason:"type",validation:"record",origin:"value",message:a||"Invalid type",input:l,...u}]);const c={},f=[];if(Object.entries(l).forEach(([d,h])=>{const y=la(u,{schema:"record",input:l,key:d,value:h});let m;try{m=i.parse(d,{...u,origin:"key",path:y})}catch(p){if(u!=null&&u.abortEarly)throw p;f.push(...p.issues)}let w;try{w=[o.parse(h,{...u,path:y})]}catch(p){if(u!=null&&u.abortEarly)throw p;f.push(...p.issues)}m&&w&&(c[m]=w[0])}),f.length)throw new et(f);return Jr(c,s,{...u,reason:"record"})}}}function nv(e,t,n,r){const{rest:i,error:o,pipe:a}=typeof t=="object"&&!Array.isArray(t)?{rest:t,...pn(n,r)}:pn(t,n);return{schema:"tuple",tuple:{items:e,rest:i},async:!1,parse(s,l){if(!Array.isArray(s)||!i&&e.length!==s.length||i&&e.length>s.length)throw new et([{reason:"type",validation:"tuple",origin:"value",message:o||"Invalid type",input:s,...l}]);const u=[],c=[];if(e.forEach((f,d)=>{try{const h=s[d];u[d]=f.parse(h,{...l,path:la(l,{schema:"tuple",input:s,key:d,value:h})})}catch(h){if(l!=null&&l.abortEarly)throw h;c.push(...h.issues)}}),i&&s.slice(e.length).forEach((f,d)=>{try{const h=e.length+d;u[h]=i.parse(f,{...l,path:la(l,{schema:"tuple",input:s,key:h,value:f})})}catch(h){if(l!=null&&l.abortEarly)throw h;c.push(...h.issues)}}),c.length)throw new et(c);return Jr(u,a,{...l,reason:"tuple"})}}}function td(e,t){return{schema:"union",union:e,async:!1,parse(n,r){let i;const o=[];for(const a of e)try{i=[a.parse(n,r)];break}catch(s){o.push(...s.issues)}if(!i)throw new et([{reason:"type",validation:"union",origin:"value",message:t||"Invalid type",input:n,issues:o,...r}]);return i[0]}}}function Ea(e,t,n){const{error:r,pipe:i}=pn(t,n);return Yt(e.reduce((o,a)=>({...o,...a.object}),{}),r,i)}function ex(e,t,n,r){const{error:i,pipe:o}=pn(n,r);return Yt(Object.entries(e.object).reduce((a,[s,l])=>t.includes(s)?a:{...a,[s]:l},{}),i,o)}function rv(e,t,n){try{return{success:!0,data:e.parse(t,n)}}catch(r){return{success:!1,error:r}}}function nd(e,t){return(n,r)=>{if(n>e)throw new et([{validation:"max_value",origin:"value",message:t||"Invalid value",input:n,...r}]);return n}}function rd(e,t){return(n,r)=>{if(nt in e?$p(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_a=(e,t)=>function(){return t||(0,e[Gy(e)[0]])((t={exports:{}}).exports,t),t.exports},ax=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Gy(t))!ix.call(e,i)&&i!==n&&$p(e,i,{get:()=>t[i],enumerable:!(r=nx(t,i))||r.enumerable});return e},sx=(e,t,n)=>(n=e!=null?tx(rx(e)):{},ax(t||!e||!e.__esModule?$p(n,"default",{value:e,enumerable:!0}):n,e)),ne=(e,t,n)=>(ox(e,typeof t!="symbol"?t+"":t,n),n),lx=_a({"../../node_modules/.pnpm/@rgba-image+copy@0.1.3/node_modules/@rgba-image/copy/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.copy=void 0;var t=(n,r,i=0,o=0,a=n.width-i,s=n.height-o,l=0,u=0)=>{if(i=i|0,o=o|0,a=a|0,s=s|0,l=l|0,u=u|0,a<=0||s<=0)return;const c=new Uint32Array(n.data.buffer),f=new Uint32Array(r.data.buffer);for(let d=0;d=n.height)continue;const y=u+d;if(!(y<0||y>=r.height))for(let m=0;m=n.width)continue;const p=l+m;if(p<0||p>=r.width)continue;const v=h*n.width+w,g=y*r.width+p;f[g]=c[v]}}};e.copy=t}}),ux=_a({"../../node_modules/.pnpm/@rgba-image+create-image@0.1.1/node_modules/@rgba-image/create-image/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CreateImageFactory=(t=[0,0,0,0],n=4)=>{if(n=Math.floor(n),isNaN(n)||n<1)throw TypeError("channels should be a positive non-zero number");if(!("length"in t)||t.lengtho===0);return(o,a,s)=>{if(o===void 0||a===void 0)throw TypeError("Not enough arguments");if(o=Math.floor(o),a=Math.floor(a),isNaN(o)||o<1||isNaN(a)||a<1)throw TypeError("Index or size is negative or greater than the allowed amount");const l=o*a*n;if(s===void 0&&(s=new Uint8ClampedArray(l)),s instanceof Uint8ClampedArray){if(s.length!==l)throw TypeError("Index or size is negative or greater than the allowed amount");if(!r)for(let u=0;u{if(o<=-a||o>=a||o==0)return 0;const s=o*Math.PI;return Math.sin(s)/s*Math.sin(s/a)/(s/a)},r=o=>Math.round(o*((1<{const c=u?2:3,f=1/s,d=Math.min(1,s),h=c/d,y=Math.floor((h+1)*2),m=new Int16Array((y+2)*a);let w=0;for(let p=0;p>1]+=r(1-P);let $=0;for(;$<_.length&&_[$]===0;)$++;let F=_.length-1;for(;F>0&&_[F]===0;)F--;const H=g+$,j=F-$+1;m[w++]=H,m[w++]=j,m.set(_.subarray($,F+1),w),w+=j}return m};e.filters=i}}),fx=_a({"../../node_modules/.pnpm/@rgba-image+lanczos@0.1.1/node_modules/@rgba-image/lanczos/dist/convolve.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.convolve=void 0;var t=14,n=(r,i,o,a,s,l)=>{let u=0,c=0;for(let f=0;f0;S--){const E=l[d++];w=w+E*r[m]|0,p=p+E*r[m+1]|0,v=v+E*r[m+2]|0,g=g+E*r[m+3]|0,m=m+4|0}i[c]=w+8192>>t,i[c+1]=p+8192>>t,i[c+2]=v+8192>>t,i[c+3]=g+8192>>t,c=c+a*4|0}c=(f+1)*4|0,u=(f+1)*o*4|0}};e.convolve=n}}),dx=_a({"../../node_modules/.pnpm/@rgba-image+lanczos@0.1.1/node_modules/@rgba-image/lanczos/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.lanczos2=e.lanczos=void 0;var t=lx(),n=ux(),r=cx(),i=fx(),o=(l,u,c=!1)=>{const f=u.width/l.width,d=u.height/l.height,h=r.filters(l.width,u.width,f,0,c),y=r.filters(l.height,u.height,d,0,c),m=new Uint8ClampedArray(u.width*l.height*4);i.convolve(l.data,m,l.width,l.height,u.width,h),i.convolve(m,u.data,l.height,u.width,u.height,y)},a=(l,u,c=0,f=0,d=l.width-c,h=l.height-f,y=0,m=0,w=u.width-y,p=u.height-m)=>{if(c=c|0,f=f|0,d=d|0,h=h|0,y=y|0,m=m|0,w=w|0,p=p|0,d<=0||h<=0||w<=0||p<=0)return;if(c===0&&f===0&&d===l.width&&h===l.height&&y===0&&m===0&&w===u.width&&p===u.height){o(l,u);return}const v=n.createImage(d,h),g=n.createImage(w,p);t.copy(l,v,c,f),o(v,g),t.copy(g,u,0,0,g.width,g.height,y,m)};e.lanczos=a;var s=(l,u,c=0,f=0,d=l.width-c,h=l.height-f,y=0,m=0,w=u.width-y,p=u.height-m)=>{if(c=c|0,f=f|0,d=d|0,h=h|0,y=y|0,m=m|0,w=w|0,p=p|0,d<=0||h<=0||w<=0||p<=0)return;if(c===0&&f===0&&d===l.width&&h===l.height&&y===0&&m===0&&w===u.width&&p===u.height){o(l,u,!0);return}const v=n.createImage(d,h),g=n.createImage(w,p);t.copy(l,v,c,f),o(v,g,!0),t.copy(g,u,0,0,g.width,g.height,y,m)};e.lanczos2=s}}),is={name:"@dotlottie/dotlottie-js",version:"0.5.2",type:"module",description:"This library helps in creating and modifying .lottie files.",repository:{type:"git",url:"git+https://github.com/dotlottie/dotlottie-js.git",directory:"packages/dotlottie-js"},homepage:"https://github.com/dotlottie/dotlottie-js#readme",bugs:"https://github.com/dotlottie/dotlottie-js/issues",author:"dotLottie",contributors:["Karam Ali ","Sam Osborne ","Jawish Hameed ","Abdelrahman Ashraf "],license:"MIT",engines:{node:">=18.0.0"},main:"./dist/index.js",exports:{".":"./dist/index.js","./node":"./dist/node/index.js"},types:"./dist/index.d.ts",typesVersions:{"*":{node:["./dist/node"]}},files:["dist"],scripts:{build:"tsup",dev:"tsup --watch",docs:"typedoc src",lint:"eslint --fix .","stats:eslint":"cross-env TIMING=1 eslint .","stats:ts":"tsc -p tsconfig.build.json --extendedDiagnostics",test:"pnpm test:browser && pnpm test:node","test:browser":"pnpm test:build:browser && jasmine-browser-runner runSpecs --config=./jasmine/jasmine-browser.json --port=4444","test:browser:watch":"nodemon -e ts --watch src/tests --exec 'pnpm test:browser'","test:build:browser":"tsup --platform='browser' --config ./jasmine/tsup.config.js","test:build:node":"tsup --platform='node' --config ./jasmine/tsup.config.js","test:build:watch":"pnpm test:build --watch","test:node":"pnpm test:build:node && jasmine --config=./jasmine/jasmine.json --parallel=auto","test:node:watch":"nodemon -e ts --watch src/tests --exec 'pnpm test:node'","type-check":"tsc --noEmit"},dependencies:{"browser-image-hash":"0.0.5",fflate:"0.7.4",sharp:"0.32.0","sharp-phash":"2.1.0",valibot:"^0.9.0"},devDependencies:{"@lottiefiles/lottie-types":"^1.1.0","@types/jasmine":"4.3.2","@types/node":"18.0.6","@types/sharp":"0.31.1","cross-env":"7.0.3",esbuild:"0.14.49",jasmine:"5.0.0","jasmine-browser-runner":"2.0.0","jasmine-core":"5.0.0","js-base64":"3.7.5",nodemon:"2.0.20",tsup:"6.1.3",typescript:"4.7.4"},publishConfig:{access:"public"},packageManager:"pnpm@7.1.6"},Qy=(e=>(e.Bounce="bounce",e.Normal="normal",e))(Qy||{}),px=Z4(Qy),hx=Yt({autoplay:Re(kc()),defaultTheme:Re(An()),direction:Re(td([tv(1),tv(-1)])),hover:Re(kc()),id:An(),intermission:Re(Cn()),loop:Re(td([kc(),Cn()])),playMode:Re(px),speed:Re(Cn()),themeColor:Re(An())}),mx=ex(hx,["id"]),Zr=Yt({state:An()}),vx=Zr,gx=Ea([Zr,Yt({ms:Cn()})]),yx=Ea([Zr,Yt({count:Cn()})]),wx=Zr,Sx=Zr,bx=Zr,Ex=Ea([Zr,Yt({threshold:Re(J4(Cn([rd(0),nd(1)])))})]),_x=Yt({onAfter:Re(gx),onClick:Re(vx),onComplete:Re(bx),onEnter:Re(yx),onMouseEnter:Re(wx),onMouseLeave:Re(Sx),onShow:Re(Ex)}),xx=Ea([mx,Yt({playOnScroll:Re(nv([Cn([rd(0),nd(1)]),Cn([rd(0),nd(1)])])),segments:Re(td([nv([Cn(),Cn()]),An()]))})]),Cx=Ea([_x,Yt({animationId:Re(An()),playbackSettings:xx})]),Yy=X4(An(),Cx),Jy=Yt({id:An(),initial:An()}),Ox=Yt({descriptor:Jy,states:Yy}),kx={jpeg:"image/jpeg",png:"image/png",gif:"image/gif",bmp:"image/bmp",svg:"image/svg+xml",webp:"image/webp"},iv={jpeg:[255,216,255],png:[137,80,78,71,13,10,26,10],gif:[71,73,70],bmp:[66,77],webp:[82,73,70,70,87,69,66,80],svg:[60,63,120]},ov={"image/jpeg":"jpeg","image/png":"png","image/gif":"gif","image/bmp":"bmp","image/svg+xml":"svg","image/webp":"webp"},Ax=e=>{const t=e.substring(e.indexOf(",")+1),n=typeof window>"u"?Buffer.from(t,"base64").toString("binary"):atob(t),r=new Uint8Array(n.length);for(let i=0;i{let t=null,n=[];if(!e)return null;const r=e.substring(e.indexOf(",")+1);typeof window>"u"?t=Buffer.from(r,"base64").toString("binary"):t=atob(r);const i=new Uint8Array(t.length);for(let o=0;os===a[l]))return kx[o]}return null},Xy=e=>{var n;const t=Zy(e);if(!t){const r=(n=e.split(";")[0])==null?void 0:n.split("/")[1];return r&&ov[r]||"png"}return ov[t]||"png"},av=class extends Error{constructor(e,t){super(e),ne(this,"code"),this.name="[dotlottie-js]",this.code=t}},G=e=>new Error(`[dotlottie-js]: ${e}`),e2=e=>{try{return new URL(e),!0}catch{return!1}};function Px(e){let t;if(typeof window>"u")t=Buffer.from(e).toString("base64");else{const r=Array.prototype.map.call(e,i=>String.fromCharCode(i)).join("");t=window.btoa(r)}return`data:${Zy(t)};base64,${t}`}var Ix=class{constructor(e){ne(this,"_descriptor"),ne(this,"_zipOptions"),ne(this,"_states"),this._requireValidId(e.descriptor.id),this._requireValidStates(e.states),this._requireValidDescriptor(e.descriptor),this._descriptor=e.descriptor,this._zipOptions=e.zipOptions??{},this._states=e.states}get zipOptions(){return this._zipOptions}set zipOptions(e){this._zipOptions=e}get id(){return this._descriptor.id}set id(e){this._requireValidId(e),this._descriptor.id=e}get states(){return this._states}set states(e){this._states=e}get initial(){return this._descriptor.initial}set initial(e){this._descriptor.initial=e}get descriptor(){return this._descriptor}set descriptor(e){this._descriptor=e}toString(){return JSON.stringify({descriptor:this._descriptor,states:this._states})}_requireValidId(e){if(!e)throw G("Invalid id.")}_requireValidDescriptor(e){const t=rv(Jy,e);if(!t.success){const n=`Invalid state machine declaration, ${JSON.stringify(ev(t.error).nested,null,2)}`;throw new av(`Invalid descriptor: ${n}`,"INVALID_STATEMACHINE")}}_requireValidStates(e){const t=rv(Yy,e);if(!t.success){const n=`Invalid state machine declaration, ${JSON.stringify(ev(t.error).nested,null,2)}`;throw new av(`Invalid states: ${n}`,"INVALID_STATEMACHINE")}}},Mx=class{constructor(e){ne(this,"_data"),ne(this,"_id",""),ne(this,"_url"),ne(this,"_animationsMap",new Map),ne(this,"_zipOptions"),this._requireValidId(e.id),this._id=e.id,e.data&&(this._requireValidData(e.data),this._data=e.data),e.url&&(this._requireValidUrl(e.url),this._url=e.url),this._zipOptions=e.zipOptions??{}}get zipOptions(){return this._zipOptions}set zipOptions(e){this._zipOptions=e}get id(){return this._id}set id(e){this._requireValidId(e),this._id=e}get url(){return this._url}set url(e){this._requireValidUrl(e),this._url=e}get data(){return this._data}set data(e){this._requireValidData(e),this._data=e}get animations(){return Array.from(this._animationsMap.values())}async toString(){return!this._data&&this._url&&await this._loadDataFromUrl(this._url),this._requireValidData(this._data),this._data}addAnimation(e){this._animationsMap.set(e.id,e)}removeAnimation(e){this._animationsMap.delete(e)}_requireValidId(e){if(typeof e!="string"||!e)throw G("Invalid theme id")}_requireValidUrl(e){if(!e||!e2(e))throw G("Invalid theme url")}_requireValidData(e){if(typeof e!="string"||!e)throw G("Invalid theme data")}async _loadDataFromUrl(e){try{const n=await(await fetch(e)).text();this._data=n}catch(t){throw G(`Failed to fetch theme from url, Error: ${JSON.stringify(t)}`)}}},Lx=class{constructor(e){ne(this,"_animationsMap",new Map),ne(this,"_plugins",[]),ne(this,"_themesMap",new Map),ne(this,"_stateMachinesMap",new Map),ne(this,"_author"),ne(this,"_description"),ne(this,"_generator"),ne(this,"_keywords"),ne(this,"_version"),ne(this,"_revision"),ne(this,"_customData"),ne(this,"enableDuplicateImageOptimization"),this._author=(e==null?void 0:e.author)??"LottieFiles",this._description=(e==null?void 0:e.description)??"",this._generator=(e==null?void 0:e.generator)??`${is.name}@${is.version}`,this._keywords=(e==null?void 0:e.keywords)??"dotLottie",this._version=(e==null?void 0:e.version)??"1.0",this._customData=(e==null?void 0:e.customData)??{},this._revision=(e==null?void 0:e.revision)??1,this.enableDuplicateImageOptimization=(e==null?void 0:e.enableDuplicateImageOptimization)??!1}async toBase64(e=void 0){throw G("toBase64() method not implemented in concrete class!")}create(e){throw G("create() method not implemented in concrete class!")}async download(e,t=void 0){throw G("download(fileName:string) method not implemented in concrete class!")}addPlugins(...e){throw G("addPlugins(...plugins: DotLottiePlugin[]) not implemented in concrete class!")}addAnimation(e){throw G("addAnimation(animationOptions: AnimationOptions) not implemented in concrete class!")}async fromArrayBuffer(e){throw G("fromArrayBuffer(arrayBuffer: ArrayBuffer): Promise not implemented in concrete class!")}async toArrayBuffer(e=void 0){throw G("toArrayBuffer(): Promise is not implemented in concrete class!")}get plugins(){return this._plugins}get version(){return this._version}get revision(){return this._revision}get author(){return this._author}get description(){return this._description}get keywords(){return this._keywords}get generator(){return this._generator}get animations(){return Array.from(this._animationsMap.values())}get manifest(){return this._buildManifest()}get custom(){return this._customData}get themes(){return Array.from(this._themesMap.values())}get stateMachines(){return Array.from(this._stateMachinesMap.values())}setCustomData(e){return this._customData=e??{},this}setAuthor(e){return this._author=e??"LottieFiles",this}setDescription(e){return this._description=e??"",this}setGenerator(e){return this._generator=e??`${is.name}@${is.version}`,this}setKeywords(e){return this._keywords=e??"dotLottie",this}setVersion(e){return this._version=e??"1.0",this}setRevision(e){return this._revision=e,this}removePlugins(...e){return e.forEach(t=>{t.uninstall();const n=this._plugins.indexOf(t);n!==-1&&this._plugins.splice(n,1)}),this}_renameImage(e,t,n){e.imageAssets.forEach(r=>{if(r.id===n){if(r.renameImage(t),!e.data)throw G("No animation data available.");const i=e.data.assets;if(!i)throw G("No image assets to rename.");for(const o of i)"w"in o&&"h"in o&&o.id===n&&(o.p=r.fileName)}})}_renameImageAssets(){const e=new Map;this.animations.forEach(n=>{e.set(n.id,n.imageAssets)});let t=0;e.forEach(n=>{t+=n.length});for(let n=this.animations.length-1;n>=0;n-=1){const r=this.animations.at(n);if(r)for(let i=r.imageAssets.length-1;i>=0;i-=1){const o=r.imageAssets.at(i);o&&(this._renameImage(r,`image_${t}`,o.id),t-=1)}}}_addLottieAnimation(e){if(this._animationsMap.get(e.id))throw G("Duplicate animation id detected, aborting.");return this._animationsMap.set(e.id,e),this}async _findImageAssetAndInline(e){var r;const t=(r=e.data)==null?void 0:r.assets;if(!t)throw G("Failed to inline assets, the animation's assets are undefined.");const n=this.getImages();for(const i of t)if("w"in i&&"h"in i&&!("xt"in i)&&"p"in i)for(const o of n)o.fileName===i.p&&(i.e=1,i.u="",i.p=await o.toDataURL());return e}async getAnimation(e,t={}){if(!t.inlineAssets)return this._animationsMap.get(e);let n=this._animationsMap.get(e);if(!n)throw G("Failed to find animation.");return n=await this._findImageAssetAndInline(n),n}getAnimations(){return Array.from(this._animationsMap)}removeAnimation(e){const t=this._animationsMap.get(e);if(t){const n=t.themes;for(const r of n)this.unassignTheme({animationId:t.id,themeId:r.id});this._animationsMap.delete(t.id)}return this}getImages(){const e=[];return this.animations.map(t=>e.push(...t.imageAssets)),e}getTheme(e){return this._themesMap.get(e)}_buildManifest(){var o;const e=Array.from(this._animationsMap.values()),t=Array.from(this._themesMap.values()),n=Array.from(this._stateMachinesMap.keys()),r=((o=e.find(a=>a.defaultActiveAnimation))==null?void 0:o.id)??"",i={version:this.version,revision:this.revision,keywords:this.keywords,author:this.author,generator:this.generator,animations:e.map(a=>({id:a.id,direction:a.direction,speed:a.speed,playMode:a.playMode,loop:a.loop,autoplay:a.autoplay,hover:a.hover,intermission:a.intermission,...a.defaultTheme?{defaultTheme:a.defaultTheme}:{}})),...this.description&&this.description.trim()!==""?{description:this.description}:{},...r&&r.trim()!==""?{activeAnimationId:r}:{},...this._customData&&Object.keys(this._customData).length!==0?{custom:this._customData}:{}};return t.length>0&&(i.themes=t.map(a=>({id:a.id,animations:a.animations.map(s=>s.id)}))),n.length>0&&(i.states=n),i}async build(){this._buildManifest();for(const n of this.animations)await n.toJSON();for(const n of this.themes)await n.toString();this.animations.length>1&&this._renameImageAssets();const e=[],t=[];for(const n of this.plugins)n.parallel?e.push(n):t.push(n);await Promise.all(e.map(async n=>n.onBuild()));for(const n of t)await n.onBuild();return this}async toBlob(e=void 0){const t=await this.toArrayBuffer(e);return new Blob([t],{type:"application/zip"})}async fromURL(e){if(!e2(e))throw G("Invalid URL");try{const t=await fetch(e);if(!t.ok)throw G(t.statusText);const n=await t.arrayBuffer();return this.fromArrayBuffer(n)}catch(t){if(t instanceof Error)throw G(t.message)}throw G("Unknown error")}merge(...e){const t=this.create();for(const n of e)n.animations.forEach(r=>{r.data?t.addAnimation({id:r.id,data:r.data}):r.url&&t.addAnimation({id:r.id,url:r.url})}),n.themes.forEach(r=>{r.data?t.addTheme({id:r.id,data:r.data}):r.url&&t.addTheme({id:r.id,url:r.url}),r.animations.forEach(i=>{t.assignTheme({animationId:i.id,themeId:r.id})})}),n.stateMachines.forEach(r=>{const i={states:r.states,descriptor:{id:r.id,initial:r.initial},zipOptions:r.zipOptions};t.addStateMachine(i)});return t}addTheme(e){const t=new Mx(e);return this._themesMap.set(t.id,t),this}removeTheme(e){const t=this._themesMap.get(e);if(t){const n=t.animations;for(const r of n)this.unassignTheme({animationId:r.id,themeId:e});this._themesMap.delete(t.id)}return this}assignTheme({animationId:e,themeId:t}){const n=this._themesMap.get(t);if(!n)throw G(`Failed to find theme with id ${t}`);const r=this._animationsMap.get(e);if(!r)throw G(`Failed to find animation with id ${e}`);return n.addAnimation(r),r.addTheme(n),this}unassignTheme({animationId:e,themeId:t}){const n=this._themesMap.get(t);if(!n)throw G(`Failed to find theme with id ${t}`);const r=this._animationsMap.get(e);if(!r)throw G(`Failed to find animation with id ${e}`);return n.removeAnimation(r.id),r.removeTheme(n.id),this}addStateMachine(e){const t=new Ix(e);return this._stateMachinesMap.set(e.descriptor.id,t),this}getStateMachine(e){return this._stateMachinesMap.get(e)}removeStateMachine(e){return this._stateMachinesMap.delete(e),this}_requireValidAuthor(e){if(!e)throw G("Invalid author")}_requireValidDescription(e){if(!e)throw G("Invalid description")}_requireValidGenerator(e){if(!e)throw G("Invalid generator")}_requireValidKeywords(e){if(!e)throw G("Invalid keywords")}_requireValidVersion(e){if(!e)throw G("Invalid version")}_requireValidCustomData(e){if(!e)throw G("Invalid customData")}},Tx=class{constructor(e){ne(this,"_data"),ne(this,"_id",""),ne(this,"_url"),ne(this,"_direction"),ne(this,"_speed"),ne(this,"_playMode"),ne(this,"_loop"),ne(this,"_autoplay"),ne(this,"_hover"),ne(this,"_intermission"),ne(this,"_zipOptions"),ne(this,"_defaultActiveAnimation"),ne(this,"_imageAssets",[]),ne(this,"_themesMap",new Map),ne(this,"_defaultTheme"),this._requireValidOptions(e),this._id=e.id,this._zipOptions=e.zipOptions??{},e.data&&(this._data=e.data),e.url&&(this._url=e.url),this._direction=e.direction??1,this._speed=e.speed??1,this._playMode=e.playMode??"normal",this._loop=e.loop??!1,this._autoplay=e.autoplay??!1,this._defaultActiveAnimation=e.defaultActiveAnimation??!1,this._hover=e.hover??!1,this._intermission=e.intermission??0}async toBase64(){throw G("lottie animation controls tobase64 not implemented!")}get zipOptions(){return this._zipOptions}set zipOptions(e){this._zipOptions=e}get id(){return this._id}set id(e){this._requireValidId(e),this._id=e}get defaultTheme(){return this._defaultTheme}set defaultTheme(e){e&&(this._defaultTheme=e)}get themes(){return Array.from(this._themesMap.values())}set themes(e){this._themesMap=new Map,e.forEach(t=>{this._themesMap.set(t.id,t)})}get imageAssets(){return this._imageAssets}set imageAssets(e){this._imageAssets=e}get data(){return this._data}set data(e){this._requireValidLottieData(e),this._data=e}get url(){return this._url}set url(e){this._requireValidUrl(e),this._url=e}get direction(){return this._direction}set direction(e){this._direction=e}get speed(){return this._speed}set speed(e){this._speed=e}get playMode(){return this._playMode}set playMode(e){this._playMode=e}get loop(){return this._loop}set loop(e){this._requireValidLoop(e),this._loop=e}get autoplay(){return this._autoplay}set autoplay(e){this._autoplay=e}get defaultActiveAnimation(){return this._defaultActiveAnimation}set defaultActiveAnimation(e){this._defaultActiveAnimation=e}get hover(){return this._hover}set hover(e){this._hover=e}get intermission(){return this._intermission}set intermission(e){this._requireValidIntermission(e),this._intermission=e}addTheme(e){this._themesMap.set(e.id,e)}removeTheme(e){this._themesMap.delete(e)}async toArrayBuffer(e={}){const t=await this.toJSON(e);return new TextEncoder().encode(JSON.stringify(t)).buffer}async _extractImageAssets(){throw G("_extractImageAssets(): Promise method not implemented in concrete class")}async toBlob(e={}){const t=await this.toJSON(e);return new Blob([JSON.stringify(t)],{type:"application/json"})}async toJSON(e={}){var t,n;if(this._url&&!this._data&&(this._data=await this._fromUrl(this._url)),this._requireValidLottieData(this._data),(t=this._data.assets)!=null&&t.length&&(await this._extractImageAssets(),e.inlineAssets)){const r=(n=this.data)==null?void 0:n.assets;if(!r)throw G("Failed to inline assets, the animation's assets are undefined.");const i=this.imageAssets;for(const o of r)if("w"in o&&"h"in o&&!("xt"in o)&&"p"in o)for(const a of i)a.fileName===o.p&&(o.e=1,o.u="",o.p=await a.toDataURL())}return this._data}async _fromUrl(e){const n=await(await fetch(e)).text();let r;try{r=JSON.parse(n)}catch(i){if(i instanceof Error)throw G(`${i.message}: Invalid json returned from url`)}return this._requireValidLottieData(r),r}_requireValidUrl(e){try{new URL(e||"")}catch{throw G("Invalid animation url")}}_requireValidLottieData(e){if(!["v","ip","op","layers","fr","w","h"].every(r=>Object.prototype.hasOwnProperty.call(e,r)))throw G("Received invalid Lottie data.")}_requireValidId(e){if(!e)throw G("Invalid animation id")}_requireValidDirection(e){if(e!==-1&&e!==1)throw G("Direction can only be -1 (backwards) or 1 (forwards)")}_requireValidIntermission(e){if(e<0||!Number.isInteger(e))throw G("intermission must be a positive number")}_requireValidLoop(e){if(typeof e=="number"&&(!Number.isInteger(e)||e<0))throw G("loop must be a positive number or boolean")}_requireValidOptions(e){if(this._requireValidId(e.id),!e.data&&!e.url)throw G("No data or url provided.");e.data&&this._requireValidLottieData(e.data),e.url&&this._requireValidUrl(e.url),e.direction&&this._requireValidDirection(e.direction),e.intermission&&this._requireValidIntermission(e.intermission),e.loop&&this._requireValidLoop(e.loop)}},Dx=class{constructor(e){ne(this,"_data"),ne(this,"_id",""),ne(this,"_url"),ne(this,"_fileName",""),ne(this,"_parentAnimations"),ne(this,"_zipOptions"),this._requireValidId(e.id),this._requireValidFileName(e.fileName),this._zipOptions=e.zipOptions??{},e.data&&(this._data=e.data),e.id&&(this._id=e.id),e.url&&(this._url=e.url),e.fileName&&(this._fileName=e.fileName),this._parentAnimations=e.parentAnimations||[]}get zipOptions(){return this._zipOptions}set zipOptions(e){this._zipOptions=e}_requireValidId(e){if(!e)throw G("Invalid image id")}_requireValidFileName(e){if(!e)throw G("Invalid image fileName")}get fileName(){return this._fileName}set fileName(e){if(!e)throw G("Invalid image file name");this._fileName=e}get id(){return this._id}set id(e){if(!e)throw G("Invalid image id");this._id=e}get data(){return this._data}set data(e){if(!e)throw G("Invalid data");this._data=e}get url(){return this._url}set url(e){if(!e)throw new Error("Invalid url");this._url=e}get parentAnimations(){return this._parentAnimations}set parentAnimations(e){this._parentAnimations=e}async toDataURL(){if(this._data&&this._isDataURL(this._data))return this.data;const e=await this.toArrayBuffer();return Px(new Uint8Array(e))}renameImage(e){if(this.id=e,this.fileName){let t=this.fileName.split(".").pop();t||(t=".png"),this.fileName=`${e}.${t}`}}async toArrayBuffer(){return await(await this.toBlob()).arrayBuffer()}async toBlob(){if(!this._data&&this._url&&(this._data=await this._fromUrlToBlob(this._url)),!this._data)throw new Error("Invalid data");if(this._isDataURL(this._data)){const e=this._data,[t,n]=e.split(",");if((!t||!n)&&e.length)return new Blob([e]);if(!t||!n)throw new Error("Invalid data");const r=t.replace("data:","").replace(/;base64$/,"");return new Blob([n],{type:r})}if(this._isArrayBuffer(this._data))return new Blob([this._data]);if(this._isBlob(this._data))return this._data;throw new Error("Invalid data")}async _fromUrlToBlob(e){return(await fetch(e)).blob()}_isArrayBuffer(e){return e instanceof ArrayBuffer}_isDataURL(e){return typeof e=="string"&&e.startsWith("data:")}_isBlob(e){return e instanceof Blob}},$x=class{constructor(e){ne(this,"dotlottie"),ne(this,"_parallel",!1),this.dotlottie=void 0,e!=null&&e.parallel&&(this._parallel=e.parallel)}install(e){this.dotlottie=e}uninstall(){this.dotlottie=void 0}get parallel(){return this._parallel}set parallel(e){this._parallel=e}async onBuild(){throw G("dotlottie-plugin build Not implemented!")}_requireDotLottie(e){if(!e)throw G("dotLottie context is null inside of duplicate image detector plugin.")}},jp=class extends Dx{constructor(e){super(e)}},jx=class extends $x{async generatePhash(e){return""}distanceTo(e,t){return 0}async _createRecordOfDuplicates(){var n,r;this._requireDotLottie(this.dotlottie);const e=[],t={};for(const i of this.dotlottie.animations)for(const o of i.imageAssets)e.push({excludeFromExport:!1,image:o,hash:await this.generatePhash(o)});for(const i of e)for(const o of e)i.image.id!==o.image.id&&!i.excludeFromExport&&!o.excludeFromExport&&i.hash&&o.hash&&this.distanceTo(i.hash,o.hash)<5&&(!t[i.image.fileName]&&!t[o.image.fileName]?(o.excludeFromExport=!0,t[i.image.fileName]=[o.image]):t[o.image.fileName]&&((n=t[o.image.fileName])!=null&&n.find(a=>a.id===i.image.id)||(i.excludeFromExport=!0,(r=t[o.image.fileName])==null||r.push(i.image))));return t}adjustDuplicateImageAssetPath(e,t){var n;for(const r in t)r&&((n=t[r])==null||n.forEach(i=>{if(e.data){const o=e.data.assets;o&&o.forEach(a=>{if("w"in a&&"h"in a&&a.p===i.fileName){const s=r;a.p=s}})}}))}async onBuild(){var r;this._requireDotLottie(this.dotlottie);const e=await this._createRecordOfDuplicates();this.dotlottie.animations.forEach(i=>{this.adjustDuplicateImageAssetPath(i,e)});const t={},n=this.dotlottie.getImages();for(const i in e)if(i)for(const o of n)o.fileName===i&&o.data!==void 0&&(t[i]=new jp({data:o.data,id:o.id,fileName:o.fileName}));Object.keys(t).length,Object.keys(e).length;for(const i in e)i&&((r=e[i])==null||r.forEach(o=>{if(o.parentAnimations.length)for(const a of o.parentAnimations){a.imageAssets.splice(a.imageAssets.indexOf(o),1);const s=t[i];s!==void 0&&(a.imageAssets.push(s),s.parentAnimations.push(a))}}))}},sv=function(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,o=[],a;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)o.push(i.value)}catch(s){a={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o},Fx=function(e,t){for(var n=0,r=t.length,i=e.length;n0)&&!(i=r.next()).done;)o.push(i.value)}catch(s){a={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o},qx=function(e,t){for(var n=0,r=t.length,i=e.length;n0)&&!(i=r.next()).done;)o.push(i.value)}catch(s){a={error:s}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(a)throw a.error}}return o},Qx=function(e,t){for(var n=0,r=t.length,i=e.length;n0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]"u")return Buffer.from(e).toString("base64");const n=new Uint8Array(e).reduce((r,i)=>r+String.fromCharCode(i),"");return window.btoa(n)}async _extractImageAssets(){if(!this._data)throw G("Asset extraction failed.");const e=this._data.assets;if(!e)throw G("Asset extraction failed.");for(const t of e)if("w"in t&&"h"in t&&!("xt"in t)&&"p"in t){const n=t.p.split(",");if(!n.length||!n[0]||!n[1])break;let r=null;r=Xy(t.p);const o=`${t.id}.${r}`;this._imageAssets.push(new jp({data:t.p,id:t.id,fileName:o,parentAnimations:[this]})),t.p=o,t.u="/images/",t.e=0}return!1}},yl=class extends Lx{constructor(e){super(e),this.enableDuplicateImageOptimization&&this.addPlugins(new rC)}addPlugins(...e){return e.forEach(t=>{t.install(this),this._plugins.push(t)}),this}addAnimation(e){const t=new iC(e);if(this._animationsMap.get(e.id))throw G("Duplicate animation id detected, aborting.");return this._animationsMap.set(t.id,t),this}async toBase64(e){const t=await this.toArrayBuffer(e),r=new Uint8Array(t).reduce((i,o)=>i+String.fromCharCode(o),"");return window.btoa(r)}async download(e,t=void 0){const n=await this.toBlob(t),r=URL.createObjectURL(n),i=document.createElement("a");i.href=r,i.download=e,i.style.display="none",document.body.append(i),i.click(),setTimeout(()=>{URL.revokeObjectURL(r),i.remove()},1e3)}create(e){return new yl(e)}async toArrayBuffer(e){const t=this._buildManifest(),n={"manifest.json":[Ei(JSON.stringify(t)),{level:0}]};for(const i of this.animations){const o=await i.toJSON();n[`animations/${i.id}.json`]=[Ei(JSON.stringify(o)),i.zipOptions];const a=i.imageAssets;for(const s of a){const l=await s.toDataURL();n[`images/${s.fileName}`]=[Ax(l),s.zipOptions]}}for(const i of this.themes){const o=await i.toString();n[`themes/${i.id}.lss`]=[Ei(o),i.zipOptions]}for(const i of this.stateMachines){const o=i.toString();n[`states/${i.id}.json`]=[Ei(o),i.zipOptions]}return await new Promise((i,o)=>{Q4(n,(e==null?void 0:e.zipOptions)||{},(a,s)=>{if(a){o(a);return}i(s.buffer)})})}async fromArrayBuffer(e){var n,r,i,o,a,s;const t=new yl;try{const l=await new Promise((c,f)=>{Y4(new Uint8Array(e),(d,h)=>{d&&f(d),c(h)})}),u=[];if(l["manifest.json"]instanceof Uint8Array)try{const c=JSON.parse(Xf(l["manifest.json"],!1)),{author:f,custom:d,description:h,generator:y,keywords:m,version:w}=c;f&&(this._requireValidAuthor(f),t.setAuthor(f)),d&&(this._requireValidCustomData(d),t.setCustomData(d)),h&&(this._requireValidDescription(h),t.setDescription(h)),y&&(this._requireValidGenerator(y),t.setGenerator(y)),m&&(this._requireValidKeywords(m),t.setKeywords(m)),w&&(this._requireValidVersion(w),t.setVersion(w));for(const p of Object.keys(l)){const v=Xf(l[p],!0);if(p.startsWith("animations/")&&p.endsWith(".json")){const g=(n=/animations\/(.+)\.json/u.exec(p))==null?void 0:n[1];if(!g)throw G("Invalid animation id");const S=JSON.parse(v),E=c.animations.find(x=>x.id===g);if(E===void 0)throw G("Animation not found inside manifest");t.addAnimation({data:S,...E})}else if(p.startsWith("images/")){const g=(r=/images\/(.+)\./u.exec(p))==null?void 0:r[1];if(!g)throw G("Invalid image id");let S=btoa(v);S=`data:image/${Xy(S)};base64,${S}`,u.push(new jp({id:g,data:S,fileName:p.split("/")[1]||""}))}else if(p.startsWith("themes/")&&p.endsWith(".lss")){const g=(i=/themes\/(.+)\.lss/u.exec(p))==null?void 0:i[1];if(!g)throw G("Invalid theme id");(o=c.themes)==null||o.forEach(S=>{S.id===g&&(t.addTheme({id:S.id,data:v}),S.animations.forEach(E=>{t.assignTheme({animationId:E,themeId:g})}))})}else if(p.startsWith("states/")&&p.endsWith(".json")){const g=(a=/states\/(.+)\.json/u.exec(p))==null?void 0:a[1];if(!g)throw G("Invalid theme id");(s=c.states)==null||s.forEach(S=>{if(S===g){const E=JSON.parse(v);t.addStateMachine(E)}})}}for(const p of u)for(const v of t.animations)if(v.data){const g=v.data.assets;if(g)for(const S of g)"w"in S&&"h"in S&&S.p.includes(p.id)&&(p.parentAnimations.push(v),v.imageAssets.push(p))}}catch{throw G("Invalid manifest inside buffer!")}else throw G("Invalid buffer")}catch(l){if(l instanceof Error)throw G(l.message)}return t}};function sn(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r3?t.i-4:t.i:Array.isArray(e)?1:Fp(e)?2:Rp(e)?3:0}function Pi(e,t){return eo(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function oC(e,t){return eo(e)===2?e.get(t):e[t]}function t2(e,t,n){var r=eo(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function n2(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function Fp(e){return fC&&e instanceof Map}function Rp(e){return dC&&e instanceof Set}function Ir(e){return e.o||e.t}function Np(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=i2(e);delete t[Ee];for(var n=Ii(t),r=0;r1&&(e.set=e.add=e.clear=e.delete=aC),Object.freeze(e),t&&qr(e,function(n,r){return zp(r,!0)},!0)),e}function aC(){sn(2)}function Vp(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Pn(e){var t=ld[e];return t||sn(18,e),t}function sC(e,t){ld[e]||(ld[e]=t)}function od(){return ua}function Ac(e,t){t&&(Pn("Patches"),e.u=[],e.s=[],e.v=t)}function wl(e){ad(e),e.p.forEach(lC),e.p=null}function ad(e){e===ua&&(ua=e.l)}function uv(e){return ua={p:[],l:ua,h:e,m:!0,_:0}}function lC(e){var t=e[Ee];t.i===0||t.i===1?t.j():t.g=!0}function Pc(e,t){t._=t.p.length;var n=t.p[0],r=e!==void 0&&e!==n;return t.h.O||Pn("ES5").S(t,e,r),r?(n[Ee].P&&(wl(t),sn(4)),qn(e)&&(e=Sl(t,e),t.l||bl(t,e)),t.u&&Pn("Patches").M(n[Ee].t,e,t.u,t.s)):e=Sl(t,n,[]),wl(t),t.u&&t.v(t.u,t.s),e!==r2?e:void 0}function Sl(e,t,n){if(Vp(t))return t;var r=t[Ee];if(!r)return qr(t,function(s,l){return cv(e,r,t,s,l,n)},!0),t;if(r.A!==e)return t;if(!r.P)return bl(e,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var i=r.i===4||r.i===5?r.o=Np(r.k):r.o,o=i,a=!1;r.i===3&&(o=new Set(i),i.clear(),a=!0),qr(o,function(s,l){return cv(e,r,i,s,l,n,a)}),bl(e,i,!1),n&&e.u&&Pn("Patches").N(r,n,e.u,e.s)}return r.o}function cv(e,t,n,r,i,o,a){if(br(i)){var s=Sl(e,i,o&&t&&t.i!==3&&!Pi(t.R,r)?o.concat(r):void 0);if(t2(n,r,s),!br(s))return;e.m=!1}else a&&n.add(i);if(qn(i)&&!Vp(i)){if(!e.h.D&&e._<1)return;Sl(e,i),t&&t.A.l||bl(e,i)}}function bl(e,t,n){n===void 0&&(n=!1),!e.l&&e.h.D&&e.m&&zp(t,n)}function Ic(e,t){var n=e[Ee];return(n?Ir(n):e)[t]}function fv(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function nr(e){e.P||(e.P=!0,e.l&&nr(e.l))}function Mc(e){e.o||(e.o=Np(e.t))}function sd(e,t,n){var r=Fp(t)?Pn("MapSet").F(t,n):Rp(t)?Pn("MapSet").T(t,n):e.O?function(i,o){var a=Array.isArray(i),s={i:a?1:0,A:o?o.A:od(),P:!1,I:!1,R:{},l:o,t:i,k:null,o:null,j:null,C:!1},l=s,u=ca;a&&(l=[s],u=_o);var c=Proxy.revocable(l,u),f=c.revoke,d=c.proxy;return s.k=d,s.j=f,d}(t,n):Pn("ES5").J(t,n);return(n?n.A:od()).p.push(r),r}function uC(e){return br(e)||sn(22,e),function t(n){if(!qn(n))return n;var r,i=n[Ee],o=eo(n);if(i){if(!i.P&&(i.i<4||!Pn("ES5").K(i)))return i.t;i.I=!0,r=dv(n,o),i.I=!1}else r=dv(n,o);return qr(r,function(a,s){i&&oC(i.t,a)===s||t2(r,a,t(s))}),o===3?new Set(r):r}(e)}function dv(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return Np(e)}function cC(){function e(o,a){var s=i[o];return s?s.enumerable=a:i[o]=s={configurable:!0,enumerable:a,get:function(){var l=this[Ee];return ca.get(l,o)},set:function(l){var u=this[Ee];ca.set(u,o,l)}},s}function t(o){for(var a=o.length-1;a>=0;a--){var s=o[a][Ee];if(!s.P)switch(s.i){case 5:r(s)&&nr(s);break;case 4:n(s)&&nr(s)}}}function n(o){for(var a=o.t,s=o.k,l=Ii(s),u=l.length-1;u>=0;u--){var c=l[u];if(c!==Ee){var f=a[c];if(f===void 0&&!Pi(a,c))return!0;var d=s[c],h=d&&d[Ee];if(h?h.t!==f:!n2(d,f))return!0}}var y=!!a[Ee];return l.length!==Ii(a).length+(y?0:1)}function r(o){var a=o.k;if(a.length!==o.t.length)return!0;var s=Object.getOwnPropertyDescriptor(a,a.length-1);if(s&&!s.get)return!0;for(var l=0;l1?p-1:0),g=1;g1?c-1:0),d=1;d=0;i--){var o=r[i];if(o.path.length===0&&o.op==="replace"){n=o.value;break}}i>-1&&(r=r.slice(i+1));var a=Pn("Patches").$;return br(n)?a(n,r):this.produce(n,function(s){return a(s,r)})},e}(),Lt=new hC,o2=Lt.produce;Lt.produceWithPatches.bind(Lt);Lt.setAutoFreeze.bind(Lt);Lt.setUseProxies.bind(Lt);Lt.applyPatches.bind(Lt);Lt.createDraft.bind(Lt);Lt.finishDraft.bind(Lt);function Kr(e){"@babel/helpers - typeof";return Kr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Kr(e)}function mC(e,t){if(Kr(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Kr(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function a2(e){var t=mC(e,"string");return Kr(t)==="symbol"?t:String(t)}function xo(e,t,n){return t=a2(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Q(e){for(var t=1;t"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(it(1));return n(s2)(e,t)}if(typeof e!="function")throw new Error(it(2));var i=e,o=t,a=[],s=a,l=!1;function u(){s===a&&(s=a.slice())}function c(){if(l)throw new Error(it(3));return o}function f(m){if(typeof m!="function")throw new Error(it(4));if(l)throw new Error(it(5));var w=!0;return u(),s.push(m),function(){if(w){if(l)throw new Error(it(6));w=!1,u();var v=s.indexOf(m);s.splice(v,1),a=null}}}function d(m){if(!vC(m))throw new Error(it(7));if(typeof m.type>"u")throw new Error(it(8));if(l)throw new Error(it(9));try{l=!0,o=i(o,m)}finally{l=!1}for(var w=a=s,p=0;p"u")throw new Error(it(12));if(typeof n(void 0,{type:El.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(it(13))})}function yC(e){for(var t=Object.keys(e),n={},r=0;r"u")throw u&&u.type,new Error(it(14));f[h]=w,c=c||w!==m}return c=c||o.length!==Object.keys(l).length,c?f:l}}function _l(){for(var e=arguments.length,t=new Array(e),n=0;n0&&o[o.length-1])&&(u[0]===6||u[0]===2)){n=0;continue}if(u[0]===3&&(!o||u[1]>o[0]&&u[1]{e.list=t.payload},addAnimation:(e,t)=>{e.list.push(t.payload)},removeAnimation:(e,t)=>{e.list=e.list.filter(n=>n.name!==t.payload)}}}),{addAnimation:C7,removeAnimation:O7,setAnimations:qC}=d2.actions,KC=d2.reducer,ku=nE,Fe=Fb,GC={playerUrl:void 0,workingFileName:"_.lottie"},p2=xa({name:"playground",initialState:GC,reducers:{setPlayerUrl:(e,t)=>{e.playerUrl=t.payload},setWorkingFileName:(e,t)=>{e.workingFileName=t.payload}}}),{setPlayerUrl:_v,setWorkingFileName:os}=p2.actions,QC=p2.reducer,YC={list:[]},h2=xa({name:"states",initialState:YC,reducers:{setStates:(e,t)=>{e.list=t.payload},addState:(e,t)=>{e.list.push(t.payload)},removeState:(e,t)=>{e.list=e.list.filter(n=>n.name!==t.payload)}}}),{addState:k7,removeState:A7,setStates:JC}=h2.actions,ZC=h2.reducer,XC={list:[]},m2=xa({name:"themes",initialState:XC,reducers:{setThemes:(e,t)=>{e.list=t.payload},addTheme:(e,t)=>{e.list.push(t.payload)},removeTheme:(e,t)=>{e.list=e.list.filter(n=>n.name!==t.payload)}}}),{addTheme:P7,removeTheme:I7,setThemes:e6}=m2.actions,t6=m2.reducer,n6={id:"",initial:"initialState"},r6={initialState:{animationId:"animationId",playbackSettings:{autoplay:!0,loop:!0}}},i6={descriptor:n6,states:r6},Hp=(...e)=>e.filter(Boolean).join(" ");function o6(e,t="dotLottie-common"){return new Error(`[${t}]: ${e}`)}function a6(e){try{const t=JSON.parse(e);return JSON.stringify(t,null," ")}catch(t){return JSON.stringify({error:t},null," ")}}function cd(e=""){return e.replace(/\s+/u,"_").toLowerCase()}function s6(){return structuredClone(i6)}const v2=b.createContext({dotLottie:new yl,setDotLottie:()=>{},setAnimationOptions:()=>{},addDotLottieStateMachine:()=>{},fetchAndUpdateDotLottie:()=>{},addDotLottieTheme:()=>{},addDotLottieAnimation:()=>{},downloadDotLottie:()=>{},removeDotLottieAnimation:()=>{},removeDotLottieState:()=>{},removeDotLottieTheme:()=>{},renameDotLottieAnimation:()=>{},buildAndUpdateUrl:()=>{}}),l6=({children:e})=>{const[t,n]=b.useState(new yl),r=Fe(g=>g.playground.playerUrl),i=Fe(g=>g.playground.workingFileName),o=ku(),a=b.useCallback(g=>{n(g)},[n]),s=b.useCallback(async()=>{const g=t.manifest.animations.map(x=>({name:`${x.id}`,type:"json"})).sort((x,_)=>x.name>_.name?1:-1),S=t.stateMachines.map(x=>({name:`${x.id}`,type:"json"})).sort((x,_)=>x.name>_.name?1:-1),E=t.themes.map(x=>({name:`${x.id}`,type:"lss"})).sort((x,_)=>x.name>_.name?1:-1);o(qC(g)),o(JC(S)),o(e6(E))},[o,t]),l=b.useCallback(async()=>{const g=r;await t.build();const S=await t.toBlob(),E=URL.createObjectURL(S);o(_v("")),o(_v(E)),g&&URL.revokeObjectURL(g)},[t]),u=b.useCallback(g=>{try{Ox.parse(g)}catch(S){throw me("Invalid state schema. Please verify the json.",{type:"error"}),S}},[]),c=b.useCallback((g,S)=>{u(g),S?t.removeStateMachine(S):t.removeStateMachine(g.descriptor.id),t.addStateMachine(g),s(),l()},[t,s]),f=b.useCallback((g,S)=>{t.removeTheme(S),t.addTheme({id:S,data:g}),s(),l()},[t,s]),d=b.useCallback(async(g,S)=>{const E=await t.getAnimation(g);if(E)try{t.addAnimation({id:S,data:E.data}),t.removeAnimation(g)}catch(x){me(x.message,{type:"error"}),console.error(x)}s(),l()},[t,s,l]),h=b.useCallback((g,S)=>{t.addAnimation({id:S,data:g}),s(),l()},[t,s,l]),y=b.useCallback(g=>{t.removeStateMachine(g),s(),l()},[t,s,l]),m=b.useCallback(g=>{t.removeAnimation(g),s(),l()},[t]),w=b.useCallback(g=>{t.removeTheme(g),s(),l()},[t]),p=b.useCallback(async()=>{await t.build().then(()=>{t.download(i)})},[t,i]),v=b.useCallback(async(g,S)=>{const E=await t.getAnimation(g);if(E){if(E.loop=!!S.loop,E.speed=Number(S.speed),E.autoplay=!!S.autoplay,E.playMode=S.playMode,E.direction=Number(S.direction),E.intermission=Number(S.intermission),E.hover=!!S.hover,E.defaultTheme=S.defaultTheme,S.assignedThemes){const x=S.assignedThemes.split(",");E.themes.forEach(_=>{x.includes(_.id)||t.unassignTheme({animationId:g,themeId:_.id})}),x.forEach(_=>{t.assignTheme({animationId:g,themeId:_})})}E.defaultActiveAnimation=S.defaultActiveAnimation||!1,S.defaultActiveAnimation&&t.animations.forEach(x=>{E.id!==x.id&&(x.defaultActiveAnimation=!1)})}},[t]);return O.jsx(v2.Provider,{value:{addDotLottieAnimation:h,addDotLottieStateMachine:c,addDotLottieTheme:f,buildAndUpdateUrl:l,dotLottie:t,downloadDotLottie:p,fetchAndUpdateDotLottie:s,removeDotLottieAnimation:m,removeDotLottieState:y,removeDotLottieTheme:w,renameDotLottieAnimation:d,setDotLottie:a,setAnimationOptions:v},children:e})},Wp=()=>{const e=b.useContext(v2);if(typeof e>"u")throw o6("useDotLottie must be used within a DotLottieProvider");return e},u6={file:void 0,validationStatus:!0,updated:!1,animationId:"",playbackOptions:{},animationOptions:{}},g2=xa({name:"editor",initialState:u6,reducers:{setEditorFile:(e,t)=>{e.file={...e.file||{},...t.payload||{}},e.animationId=void 0,e.updated=!1},clearEditorFile:e=>{e.file=void 0,e.validationStatus=!0,e.updated=!1},updateEditorFile:(e,t)=>{e.file&&(e.file.content=t.payload)},setEditorValidatationStatus:(e,t)=>{e.validationStatus=t.payload},setEditorUpdated:(e,t)=>{e.updated=t.payload},setEditorAnimationId:(e,t)=>{e.animationId=t.payload,e.updated=!1,e.file=void 0},setEditorPlaybacOptions:(e,t)=>{e.playbackOptions={...e.playbackOptions,...t.payload||{}}},setEditorAnimationOptions:(e,t)=>{e.animationOptions=t.payload||{}},updateEditorAnimationOptions:(e,t)=>{e.animationOptions={...e.animationOptions,...t.payload||{}}},clearEditorPlaybackOptions:e=>{e.playbackOptions={},e.animationId=""},clearEditorState:e=>{e.file=void 0,e.validationStatus=!0,e.updated=!1,e.playbackOptions={},e.animationId="",e.animationOptions={}}}}),{clearEditorFile:M7,clearEditorPlaybackOptions:L7,clearEditorState:Ms,setEditorAnimationId:c6,setEditorAnimationOptions:xv,setEditorFile:Cv,setEditorPlaybacOptions:T7,setEditorUpdated:xl,setEditorValidatationStatus:Ov,updateEditorAnimationOptions:kv,updateEditorFile:D7}=g2.actions,f6=g2.reducer,Cl=ee.forwardRef(({children:e,color:t="blue",...n},r)=>O.jsx("button",{ref:r,className:Hp("text-white rounded px-3 py-1 text-sm disabled:bg-gray-500",t==="blue"&&"bg-blue-600 hover:bg-blue-700",t==="green"&&"bg-green-600 hover:bg-green-700",t==="red"&&"bg-red-600 hover:bg-red-700"),...n,children:e})),d6=({onChange:e,title:t})=>{const[n,r]=b.useState(!1),i=b.useRef(null),o=b.useCallback(()=>{n||r(!0)},[n]),a=b.useCallback(()=>{var l;e((l=i.current)!=null&&l.value?`${i.current.value}.lottie`:t),r(!1)},[onchange,r]),s=b.useCallback(l=>{l.key==="Enter"&&a()},[a]);return O.jsxs("div",{className:"group flex items-center",children:[n&&O.jsx("input",{ref:i,autoFocus:!0,className:"bg-transparent outline-none",type:"text",onKeyDown:s,onBlur:a,defaultValue:t.replace(/.lottie$/u,"")}),!n&&O.jsx("span",{children:t||"unnamed.lottie"}),O.jsx("button",{onClick:o,className:Hp("invisible",!n&&"group-hover:visible"),children:O.jsx(vy,{size:20})})]})};var p6=function(){};function h6(e){for(var t=[],n=1;ne==="lss"?O.jsx(aE,{}):O.jsx(sE,{}),_6=({onAdd:e})=>{const t=b.useRef(null),n=b.useCallback(i=>{typeof e=="function"&&i.target.value&&e(i.target.value.replace(/\s+/gu,"_"))},[e]),r=b.useCallback(i=>{var o;i.key==="Enter"&&((o=t.current)!=null&&o.value)&&typeof e=="function"&&e(t.current.value.replace(/\s+/gu,"_"))},[e]);return O.jsxs("div",{className:"w-full bg-dark flex items-center gap-1 px-2 py-1 pl-4 text-gray-400 text-sm whitespace-nowrap hover:text-white",children:[O.jsx("span",{children:O.jsx(y2,{type:"json"})}),O.jsx("input",{autoFocus:!0,ref:t,type:"text",className:"bg-transparent outline-none",onKeyUp:r,onBlur:n})]})};function x6(e){return mn({tag:"svg",attr:{viewBox:"0 0 15 15",fill:"none"},child:[{tag:"path",attr:{fillRule:"evenodd",clipRule:"evenodd",d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor"}}]})(e)}const C6=({editable:e,file:t,onRemove:n,onRename:r,...i})=>{const[o,a]=b.useState(!1),s=b.useRef(null),l=b.useCallback(d=>{d.stopPropagation(),n==null||n(t.name)},[n,t.name]),u=b.useCallback(d=>{d.stopPropagation(),a(!0)},[a,o]),c=b.useCallback(()=>{s.current&&s.current.value!==t.name&&(r==null||r(t.name,cd(s.current.value))),a(!1)},[r,a,s]),f=b.useCallback(d=>{d.key==="Enter"&&c()},[c]);return O.jsxs("button",{className:"group w-full flex items-center gap-1 px-2 py-1 pl-4 text-sm whitespace-nowrap hover:text-white",...i,children:[O.jsx("span",{children:O.jsx(y2,{type:t.type})}),o&&O.jsx("input",{ref:s,onKeyDown:f,onBlur:c,autoFocus:!0,className:"outline-none bg-transparent flex-1 text-left",defaultValue:t.name}),!o&&O.jsx("span",{className:"flex-1 text-left",children:t.name}),!o&&O.jsxs("div",{className:"flex justify-self-end text-gray-400 gap-1",children:[e&&O.jsx("span",{onClick:u,className:"hover:text-white opacity-0 group-hover:opacity-100",children:O.jsx(vy,{size:20})}),O.jsx("span",{onClick:l,title:"Remove",className:"hover:text-white opacity-0 group-hover:opacity-100",children:O.jsx(x6,{size:20})})]})]})};function O6(e){return mn({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M480 580H372a8 8 0 0 0-8 8v48a8 8 0 0 0 8 8h108v108a8 8 0 0 0 8 8h48a8 8 0 0 0 8-8V644h108a8 8 0 0 0 8-8v-48a8 8 0 0 0-8-8H544V472a8 8 0 0 0-8-8h-48a8 8 0 0 0-8 8v108zm374.6-291.3c6 6 9.4 14.1 9.4 22.6V928c0 17.7-14.3 32-32 32H192c-17.7 0-32-14.3-32-32V96c0-17.7 14.3-32 32-32h424.7c8.5 0 16.7 3.4 22.7 9.4l215.2 215.3zM790.2 326L602 137.8V326h188.2z"}}]})(e)}function k6(e){return mn({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M464 128H272l-64-64H48C21.49 64 0 85.49 0 112v288c0 26.51 21.49 48 48 48h416c26.51 0 48-21.49 48-48V176c0-26.51-21.49-48-48-48z"}}]})(e)}function A6(e){return mn({tag:"svg",attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}},{tag:"polyline",attr:{points:"17 8 12 3 7 8"}},{tag:"line",attr:{x1:"12",x2:"12",y1:"3",y2:"15"}}]})(e)}const P6=({buttons:e,onClickAdd:t,onUpload:n,title:r,...i})=>{const o=b.useCallback(a=>{const s=a[0];n==null||n(s)},[n]);return O.jsxs("div",{className:Hp("flex w-full items-center gap-2 py-2 px-1 text-gray-400 text-md whitespace-nowrap border-y border-gray-500"),...i,children:[O.jsx("span",{children:O.jsx(k6,{})}),O.jsx("span",{className:"w-full text-left text-md",children:r}),Array.isArray(e)&&e.map(a=>{const s=[];switch(a){case"add":s.push(O.jsx("button",{className:"hover:text-white",title:"Add new",onClick:t,children:O.jsx(O6,{size:20})},a));break;case"upload":s.push(O.jsx(ia,{onDrop:o,accept:r==="Themes"?"lss":"json",children:({getInputProps:l,getRootProps:u})=>O.jsxs("button",{...u(),className:"hover:text-white",title:"Upload",children:[O.jsx("input",{...l()}),O.jsx(A6,{size:20})]})},a));break}return s})]})},$c=({className:e,files:t,onAddNew:n,onClick:r,onRemove:i,onUpload:o,title:a})=>{const{renameDotLottieAnimation:s}=Wp(),l=ku(),u=b.useCallback(E=>()=>{r==null||r(a,E)},[r,a]),c=b.useMemo(()=>a.toLowerCase()==="themes"?"lss":"json",[a]),f=b.useCallback(E=>{i==null||i(a,E)},[i,a]),[d,h]=b.useState(!1),y=b.useCallback(()=>{h(!0)},[]);E6("Escape",()=>{h(!1)},{event:"keyup"});const m=b.useCallback(E=>{n==null||n(a,`${E}.${c}`),h(!1)},[n,a,c]),w=b.useCallback((E,x)=>{a==="Animations"&&(s(E,x),l(Ms()))},[a,s]),p=b.useCallback(E=>{o==null||o(a,E)},[o,a]),v=b.useCallback(E=>{p(E[0])},[p]),g=Fe(E=>{var x;return(x=E.editor.file)==null?void 0:x.name}),S=Fe(E=>E.editor.animationId);return O.jsxs("div",{className:`flex flex-col ${e}`,children:[O.jsx(P6,{title:a,onClickAdd:y,onUpload:p,buttons:a==="Animations"?["upload"]:["upload","add"]}),O.jsxs("div",{className:"relative h-full overflow-y-auto custom-scrollbar",children:[O.jsx(ia,{onDrop:v,accept:a==="Themes"?"lss":"json",noClick:!0,children:E=>O.jsxs("div",{...E.getRootProps(),children:[O.jsx("input",{...E.getInputProps()}),E.isDragActive&&O.jsxs("div",{className:"absolute inset-0 bg-black opacity-50 text-white flex justify-center items-center",children:["Drop ",a]}),O.jsxs("ul",{className:"w-full py-2",children:[Array.isArray(t)&&t.map(x=>O.jsx("li",{"data-value":a,className:`w-full ${S===x.name||g===x.name?"bg-gray-700 text-gray-100":"text-gray-400"}`,children:O.jsx(C6,{onRemove:f,onRename:w,editable:a==="Animations",file:x,onClick:u(x.name)})},x.name)),d&&O.jsx("li",{children:O.jsx(_6,{onAdd:m,extension:a==="Themes"?"lss":"json"})})]})]})}),O.jsx("div",{})]})]})};function I6(e){return mn({tag:"svg",attr:{viewBox:"0 0 256 256",fill:"currentColor"},child:[{tag:"path",attr:{d:"M176,56H80a72,72,0,0,0,0,144h96a72,72,0,0,0,0-144ZM80,168a40,40,0,1,1,40-40A40,40,0,0,1,80,168Z"}}]})(e)}function M6(e){return mn({tag:"svg",attr:{viewBox:"0 0 256 256",fill:"currentColor"},child:[{tag:"path",attr:{d:"M176,56H80a72,72,0,0,0,0,144h96a72,72,0,0,0,0-144Zm0,112a40,40,0,1,1,40-40A40,40,0,0,1,176,168Z"}}]})(e)}const Iv=({label:e,onToggle:t,value:n})=>{const r=b.useCallback(()=>{t==null||t(!n)},[t,n]);return O.jsxs("div",{className:"flex flex-col text-gray-400 w-full max-w-xs hover:text-white",children:[O.jsx("span",{className:"flex-1 text-lg text-left",children:e}),O.jsxs("button",{onClick:r,className:"flex items-center justify-between py-2 px-3 rounded bg-white text-gray-600",children:[O.jsx("div",{children:n?"On":"Off"}),O.jsx("span",{className:`${n?"text-green-700":""}`,children:n?O.jsx(M6,{size:30}):O.jsx(I6,{size:30})})]})]})},L6=({label:e,onChange:t,value:n})=>{const r=b.useCallback(i=>{t==null||t(Number(i.target.value))},[t]);return O.jsxs("div",{className:"flex flex-col text-gray-400 w-full max-w-xs hover:text-white",children:[O.jsx("span",{className:"flex-1 text-lg text-left",children:e}),O.jsx("input",{type:"number",onChange:r,value:n,name:e,className:"py-3 px-3 rounded bg-white text-gray-600"})]})};function T6(e){if(Array.isArray(e))return e}function D6(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,a,s=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=o.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw i}}return s}}function fd(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}var j6=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];function F6(e){var t=e.defaultInputValue,n=t===void 0?"":t,r=e.defaultMenuIsOpen,i=r===void 0?!1:r,o=e.defaultValue,a=o===void 0?null:o,s=e.inputValue,l=e.menuIsOpen,u=e.onChange,c=e.onInputChange,f=e.onMenuClose,d=e.onMenuOpen,h=e.value,y=Gn(e,j6),m=b.useState(s!==void 0?s:n),w=zn(m,2),p=w[0],v=w[1],g=b.useState(l!==void 0?l:i),S=zn(g,2),E=S[0],x=S[1],_=b.useState(h!==void 0?h:a),C=zn(_,2),k=C[0],P=C[1],$=b.useCallback(function(A,I){typeof u=="function"&&u(A,I),P(A)},[u]),F=b.useCallback(function(A,I){var R;typeof c=="function"&&(R=c(A,I)),v(R!==void 0?R:A)},[c]),H=b.useCallback(function(){typeof d=="function"&&d(),x(!0)},[d]),j=b.useCallback(function(){typeof f=="function"&&f(),x(!1)},[f]),L=s!==void 0?s:p,M=l!==void 0?l:E,D=h!==void 0?h:k;return Q(Q({},y),{},{inputValue:L,menuIsOpen:M,onChange:$,onInputChange:F,onMenuClose:j,onMenuOpen:H,value:D})}function R6(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Mv(e,t){for(var n=0;n"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function B6(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function U6(e,t){if(t&&(Kr(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return B6(e)}function H6(e){var t=V6();return function(){var r=Ol(e),i;if(t){var o=Ol(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return U6(this,i)}}function W6(e){if(Array.isArray(e))return fd(e)}function q6(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function K6(){throw new TypeError(`Invalid attempt to spread non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function S2(e){return W6(e)||q6(e)||w2(e)||K6()}function G6(e){if(e.sheet)return e.sheet;for(var t=0;t0?Je(to,--bt):0,Wi--,Ne===10&&(Wi=1,Pu--),Ne}function It(){return Ne=bt2||da(Ne)>3?"":" "}function s5(e,t){for(;--t&&It()&&!(Ne<48||Ne>102||Ne>57&&Ne<65||Ne>70&&Ne<97););return Ca(e,Ls()+(t<6&&In()==32&&It()==32))}function hd(e){for(;It();)switch(Ne){case e:return bt;case 34:case 39:e!==34&&e!==39&&hd(Ne);break;case 40:e===41&&hd(e);break;case 92:It();break}return bt}function l5(e,t){for(;It()&&e+Ne!==47+10;)if(e+Ne===42+42&&In()===47)break;return"/*"+Ca(t,bt-1)+"*"+Au(e===47?e:It())}function u5(e){for(;!da(In());)It();return Ca(e,bt)}function c5(e){return O2(Ds("",null,null,null,[""],e=C2(e),0,[0],e))}function Ds(e,t,n,r,i,o,a,s,l){for(var u=0,c=0,f=a,d=0,h=0,y=0,m=1,w=1,p=1,v=0,g="",S=i,E=o,x=r,_=g;w;)switch(y=v,v=It()){case 40:if(y!=108&&Je(_,f-1)==58){pd(_+=le(Ts(v),"&","&\f"),"&\f")!=-1&&(p=-1);break}case 34:case 39:case 91:_+=Ts(v);break;case 9:case 10:case 13:case 32:_+=a5(y);break;case 92:_+=s5(Ls()-1,7);continue;case 47:switch(In()){case 42:case 47:as(f5(l5(It(),Ls()),t,n),l);break;default:_+="/"}break;case 123*m:s[u++]=Sn(_)*p;case 125*m:case 59:case 0:switch(v){case 0:case 125:w=0;case 59+c:p==-1&&(_=le(_,/\f/g,"")),h>0&&Sn(_)-f&&as(h>32?Tv(_+";",r,n,f-1):Tv(le(_," ","")+";",r,n,f-2),l);break;case 59:_+=";";default:if(as(x=Lv(_,t,n,u,c,i,s,g,S=[],E=[],f),o),v===123)if(c===0)Ds(_,t,x,x,S,o,f,s,E);else switch(d===99&&Je(_,3)===110?100:d){case 100:case 108:case 109:case 115:Ds(e,x,x,r&&as(Lv(e,x,x,0,0,i,s,g,i,S=[],f),E),i,E,f,s,r?S:E);break;default:Ds(_,x,x,x,[""],E,0,s,E)}}u=c=h=0,m=p=1,g=_="",f=a;break;case 58:f=1+Sn(_),h=y;default:if(m<1){if(v==123)--m;else if(v==125&&m++==0&&o5()==125)continue}switch(_+=Au(v),v*m){case 38:p=c>0?1:(_+="\f",-1);break;case 44:s[u++]=(Sn(_)-1)*p,p=1;break;case 64:In()===45&&(_+=Ts(It())),d=In(),c=f=Sn(g=_+=u5(Ls())),v++;break;case 45:y===45&&Sn(_)==2&&(m=0)}}return o}function Lv(e,t,n,r,i,o,a,s,l,u,c){for(var f=i-1,d=i===0?o:[""],h=Gp(d),y=0,m=0,w=0;y0?d[p]+" "+v:le(v,/&\f/g,d[p])))&&(l[w++]=g);return Iu(e,t,n,i===0?qp:s,l,u,c)}function f5(e,t,n){return Iu(e,t,n,b2,Au(i5()),fa(e,2,-2),0)}function Tv(e,t,n,r){return Iu(e,t,n,Kp,fa(e,0,r),fa(e,r+1,-1),r)}function Mi(e,t){for(var n="",r=Gp(e),i=0;i6)switch(Je(e,t+1)){case 109:if(Je(e,t+4)!==45)break;case 102:return le(e,/(.+:)(.+)-([^]+)/,"$1"+ae+"$2-$3$1"+kl+(Je(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~pd(e,"stretch")?k2(le(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Je(e,t+1)!==115)break;case 6444:switch(Je(e,Sn(e)-3-(~pd(e,"!important")&&10))){case 107:return le(e,":",":"+ae)+e;case 101:return le(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ae+(Je(e,14)===45?"inline-":"")+"box$3$1"+ae+"$2$3$1"+rt+"$2box$3")+e}break;case 5936:switch(Je(e,t+11)){case 114:return ae+e+rt+le(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return ae+e+rt+le(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return ae+e+rt+le(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return ae+e+rt+e+e}return e}var b5=function(t,n,r,i){if(t.length>-1&&!t.return)switch(t.type){case Kp:t.return=k2(t.value,t.length);break;case E2:return Mi([po(t,{value:le(t.value,"@","@"+ae)})],i);case qp:if(t.length)return r5(t.props,function(o){switch(n5(o,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Mi([po(t,{props:[le(o,/:(read-\w+)/,":"+kl+"$1")]})],i);case"::placeholder":return Mi([po(t,{props:[le(o,/:(plac\w+)/,":"+ae+"input-$1")]}),po(t,{props:[le(o,/:(plac\w+)/,":"+kl+"$1")]}),po(t,{props:[le(o,/:(plac\w+)/,rt+"input-$1")]})],i)}return""})}},E5=[b5],_5=function(t){var n=t.key;if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(m){var w=m.getAttribute("data-emotion");w.indexOf(" ")!==-1&&(document.head.appendChild(m),m.setAttribute("data-s",""))})}var i=t.stylisPlugins||E5,o={},a,s=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(m){for(var w=m.getAttribute("data-emotion").split(" "),p=1;p=4;++r,i-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var A5={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},P5=/[A-Z]|^ms/g,I5=/_EMO_([^_]+?)_([^]*?)_EMO_/g,P2=function(t){return t.charCodeAt(1)===45},$v=function(t){return t!=null&&typeof t!="boolean"},jc=m5(function(e){return P2(e)?e:e.replace(P5,"-$&").toLowerCase()}),jv=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(I5,function(r,i,o){return bn={name:i,styles:o,next:bn},i})}return A5[t]!==1&&!P2(t)&&typeof n=="number"&&n!==0?n+"px":n};function pa(e,t,n){if(n==null)return"";if(n.__emotion_styles!==void 0)return n;switch(typeof n){case"boolean":return"";case"object":{if(n.anim===1)return bn={name:n.name,styles:n.styles,next:bn},n.name;if(n.styles!==void 0){var r=n.next;if(r!==void 0)for(;r!==void 0;)bn={name:r.name,styles:r.styles,next:bn},r=r.next;var i=n.styles+";";return i}return M5(e,t,n)}case"function":{if(e!==void 0){var o=bn,a=n(e);return bn=o,pa(e,t,a)}break}}if(t==null)return n;var s=t[n];return s!==void 0?s:n}function M5(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i({x:e,y:e});function W5(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function L2(e){return D2(e)?(e.nodeName||"").toLowerCase():"#document"}function fn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function T2(e){var t;return(t=(D2(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function D2(e){return e instanceof Node||e instanceof fn(e).Node}function vd(e){return e instanceof Element||e instanceof fn(e).Element}function Jp(e){return e instanceof HTMLElement||e instanceof fn(e).HTMLElement}function Rv(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof fn(e).ShadowRoot}function $2(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Zp(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function q5(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function K5(e){return["html","body","#document"].includes(L2(e))}function Zp(e){return fn(e).getComputedStyle(e)}function G5(e){if(L2(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Rv(e)&&e.host||T2(e);return Rv(t)?t.host:t}function j2(e){const t=G5(e);return K5(t)?e.ownerDocument?e.ownerDocument.body:e.body:Jp(t)&&$2(t)?t:j2(t)}function gd(e,t){var n;t===void 0&&(t=[]);const r=j2(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=fn(r);return i?t.concat(o,o.visualViewport||[],$2(r)?r:[]):t.concat(r,gd(r))}function Q5(e){const t=Zp(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Jp(e),o=i?e.offsetWidth:n,a=i?e.offsetHeight:r,s=Al(n)!==o||Al(r)!==a;return s&&(n=o,r=a),{width:n,height:r,$:s}}function Xp(e){return vd(e)?e:e.contextElement}function Fc(e){const t=Xp(e);if(!Jp(t))return Pl(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=Q5(t);let a=(o?Al(n.width):n.width)/r,s=(o?Al(n.height):n.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const Y5=Pl(0);function J5(e){const t=fn(e);return!q5()||!t.visualViewport?Y5:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Z5(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==fn(e)?!1:t}function Nv(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=Xp(e);let a=Pl(1);t&&(r?vd(r)&&(a=Fc(r)):a=Fc(e));const s=Z5(o,n,r)?J5(o):Pl(0);let l=(i.left+s.x)/a.x,u=(i.top+s.y)/a.y,c=i.width/a.x,f=i.height/a.y;if(o){const d=fn(o),h=r&&vd(r)?fn(r):r;let y=d.frameElement;for(;y&&r&&h!==d;){const m=Fc(y),w=y.getBoundingClientRect(),p=Zp(y),v=w.left+(y.clientLeft+parseFloat(p.paddingLeft))*m.x,g=w.top+(y.clientTop+parseFloat(p.paddingTop))*m.y;l*=m.x,u*=m.y,c*=m.x,f*=m.y,l+=v,u+=g,y=fn(y).frameElement}}return W5({width:c,height:f,x:l,y:u})}function X5(e,t){let n=null,r;const i=T2(e);function o(){clearTimeout(r),n&&n.disconnect(),n=null}function a(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),o();const{left:u,top:c,width:f,height:d}=e.getBoundingClientRect();if(s||t(),!f||!d)return;const h=ss(c),y=ss(i.clientWidth-(u+f)),m=ss(i.clientHeight-(c+d)),w=ss(u),v={rootMargin:-h+"px "+-y+"px "+-m+"px "+-w+"px",threshold:H5(0,U5(1,l))||1};let g=!0;function S(E){const x=E[0].intersectionRatio;if(x!==l){if(!g)return a();x?a(!1,x):r=setTimeout(()=>{a(!1,1e-7)},100)}g=!1}try{n=new IntersectionObserver(S,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(S,v)}n.observe(e)}return a(!0),o}function eO(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=Xp(e),c=i||o?[...u?gd(u):[],...gd(t)]:[];c.forEach(p=>{i&&p.addEventListener("scroll",n,{passive:!0}),o&&p.addEventListener("resize",n)});const f=u&&s?X5(u,n):null;let d=-1,h=null;a&&(h=new ResizeObserver(p=>{let[v]=p;v&&v.target===u&&h&&(h.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{h&&h.observe(t)})),n()}),u&&!l&&h.observe(u),h.observe(t));let y,m=l?Nv(e):null;l&&w();function w(){const p=Nv(e);m&&(p.x!==m.x||p.y!==m.y||p.width!==m.width||p.height!==m.height)&&n(),m=p,y=requestAnimationFrame(w)}return n(),()=>{c.forEach(p=>{i&&p.removeEventListener("scroll",n),o&&p.removeEventListener("resize",n)}),f&&f(),h&&h.disconnect(),h=null,l&&cancelAnimationFrame(y)}}var yd=b.useLayoutEffect,tO=["className","clearValue","cx","getStyles","getClassNames","getValue","hasValue","isMulti","isRtl","options","selectOption","selectProps","setValue","theme"],Il=function(){};function nO(e,t){return t?t[0]==="-"?e+t:e+"__"+t:e}function rO(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i-1}function iO(e){return Mu(e)?window.innerHeight:e.clientHeight}function R2(e){return Mu(e)?window.pageYOffset:e.scrollTop}function Ml(e,t){if(Mu(e)){window.scrollTo(0,t);return}e.scrollTop=t}function oO(e){var t=getComputedStyle(e),n=t.position==="absolute",r=/(auto|scroll)/;if(t.position==="fixed")return document.documentElement;for(var i=e;i=i.parentElement;)if(t=getComputedStyle(i),!(n&&t.position==="static")&&r.test(t.overflow+t.overflowY+t.overflowX))return i;return document.documentElement}function aO(e,t,n,r){return n*((e=e/r-1)*e*e+1)+t}function ls(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:200,r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:Il,i=R2(e),o=t-i,a=10,s=0;function l(){s+=a;var u=aO(s,i,o,n);Ml(e,u),sn.bottom?Ml(e,Math.min(t.offsetTop+t.clientHeight-e.offsetHeight+i,e.scrollHeight)):r.top-i1?n-1:0),i=1;i=y)return{placement:"bottom",maxHeight:t};if(k>=y&&!a)return o&&ls(l,P,F),{placement:"bottom",maxHeight:t};if(!a&&k>=r||a&&_>=r){o&&ls(l,P,F);var H=a?_-S:k-S;return{placement:"bottom",maxHeight:H}}if(i==="auto"||a){var j=t,L=a?x:C;return L>=r&&(j=Math.min(L-S-s,t)),{placement:"top",maxHeight:j}}if(i==="bottom")return o&&Ml(l,P),{placement:"bottom",maxHeight:t};break;case"top":if(x>=y)return{placement:"top",maxHeight:t};if(C>=y&&!a)return o&&ls(l,$,F),{placement:"top",maxHeight:t};if(!a&&C>=r||a&&x>=r){var M=t;return(!a&&C>=r||a&&x>=r)&&(M=a?x-E:C-E),o&&ls(l,$,F),{placement:"top",maxHeight:M}}return{placement:"bottom",maxHeight:t};default:throw new Error('Invalid placement provided "'.concat(i,'".'))}return u}function gO(e){var t={bottom:"top",top:"bottom"};return e?t[e]:"bottom"}var z2=function(t){return t==="auto"?"bottom":t},yO=function(t,n){var r,i=t.placement,o=t.theme,a=o.borderRadius,s=o.spacing,l=o.colors;return Q((r={label:"menu"},xo(r,gO(i),"100%"),xo(r,"position","absolute"),xo(r,"width","100%"),xo(r,"zIndex",1),r),n?{}:{backgroundColor:l.neutral0,borderRadius:a,boxShadow:"0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)",marginBottom:s.menuGutter,marginTop:s.menuGutter})},V2=b.createContext(null),wO=function(t){var n=t.children,r=t.minMenuHeight,i=t.maxMenuHeight,o=t.menuPlacement,a=t.menuPosition,s=t.menuShouldScrollIntoView,l=t.theme,u=b.useContext(V2)||{},c=u.setPortalPlacement,f=b.useRef(null),d=b.useState(i),h=zn(d,2),y=h[0],m=h[1],w=b.useState(null),p=zn(w,2),v=p[0],g=p[1],S=l.spacing.controlHeight;return yd(function(){var E=f.current;if(E){var x=a==="fixed",_=s&&!x,C=vO({maxHeight:i,menuEl:E,minHeight:r,placement:o,shouldScroll:_,isFixedPosition:x,controlHeight:S});m(C.maxHeight),g(C.placement),c==null||c(C.placement)}},[i,o,a,s,r,c,S]),n({ref:f,placerProps:Q(Q({},t),{},{placement:v||z2(o),maxHeight:y})})},SO=function(t){var n=t.children,r=t.innerRef,i=t.innerProps;return Y("div",J({},De(t,"menu",{menu:!0}),{ref:r},i),n)},bO=SO,EO=function(t,n){var r=t.maxHeight,i=t.theme.spacing.baseUnit;return Q({maxHeight:r,overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},n?{}:{paddingBottom:i,paddingTop:i})},_O=function(t){var n=t.children,r=t.innerProps,i=t.innerRef,o=t.isMulti;return Y("div",J({},De(t,"menuList",{"menu-list":!0,"menu-list--is-multi":o}),{ref:i},r),n)},B2=function(t,n){var r=t.theme,i=r.spacing.baseUnit,o=r.colors;return Q({textAlign:"center"},n?{}:{color:o.neutral40,padding:"".concat(i*2,"px ").concat(i*3,"px")})},xO=B2,CO=B2,OO=function(t){var n=t.children,r=n===void 0?"No options":n,i=t.innerProps,o=Gn(t,hO);return Y("div",J({},De(Q(Q({},o),{},{children:r,innerProps:i}),"noOptionsMessage",{"menu-notice":!0,"menu-notice--no-options":!0}),i),r)},kO=function(t){var n=t.children,r=n===void 0?"Loading...":n,i=t.innerProps,o=Gn(t,mO);return Y("div",J({},De(Q(Q({},o),{},{children:r,innerProps:i}),"loadingMessage",{"menu-notice":!0,"menu-notice--loading":!0}),i),r)},AO=function(t){var n=t.rect,r=t.offset,i=t.position;return{left:n.left,position:i,top:r,width:n.width,zIndex:1}},PO=function(t){var n=t.appendTo,r=t.children,i=t.controlElement,o=t.innerProps,a=t.menuPlacement,s=t.menuPosition,l=b.useRef(null),u=b.useRef(null),c=b.useState(z2(a)),f=zn(c,2),d=f[0],h=f[1],y=b.useMemo(function(){return{setPortalPlacement:h}},[]),m=b.useState(null),w=zn(m,2),p=w[0],v=w[1],g=b.useCallback(function(){if(i){var _=sO(i),C=s==="fixed"?0:window.pageYOffset,k=_[d]+C;(k!==(p==null?void 0:p.offset)||_.left!==(p==null?void 0:p.rect.left)||_.width!==(p==null?void 0:p.rect.width))&&v({offset:k,rect:_})}},[i,s,d,p==null?void 0:p.offset,p==null?void 0:p.rect.left,p==null?void 0:p.rect.width]);yd(function(){g()},[g]);var S=b.useCallback(function(){typeof u.current=="function"&&(u.current(),u.current=null),i&&l.current&&(u.current=eO(i,l.current,g,{elementResize:"ResizeObserver"in window}))},[i,g]);yd(function(){S()},[S]);var E=b.useCallback(function(_){l.current=_,S()},[S]);if(!n&&s!=="fixed"||!p)return null;var x=Y("div",J({ref:E},De(Q(Q({},t),{},{offset:p.offset,position:s,rect:p.rect}),"menuPortal",{"menu-portal":!0}),o),r);return Y(V2.Provider,{value:y},n?bp.createPortal(x,n):x)},IO=function(t){var n=t.isDisabled,r=t.isRtl;return{label:"container",direction:r?"rtl":void 0,pointerEvents:n?"none":void 0,position:"relative"}},MO=function(t){var n=t.children,r=t.innerProps,i=t.isDisabled,o=t.isRtl;return Y("div",J({},De(t,"container",{"--is-disabled":i,"--is-rtl":o}),r),n)},LO=function(t,n){var r=t.theme.spacing,i=t.isMulti,o=t.hasValue,a=t.selectProps.controlShouldRenderValue;return Q({alignItems:"center",display:i&&o&&a?"flex":"grid",flex:1,flexWrap:"wrap",WebkitOverflowScrolling:"touch",position:"relative",overflow:"hidden"},n?{}:{padding:"".concat(r.baseUnit/2,"px ").concat(r.baseUnit*2,"px")})},TO=function(t){var n=t.children,r=t.innerProps,i=t.isMulti,o=t.hasValue;return Y("div",J({},De(t,"valueContainer",{"value-container":!0,"value-container--is-multi":i,"value-container--has-value":o}),r),n)},DO=function(){return{alignItems:"center",alignSelf:"stretch",display:"flex",flexShrink:0}},$O=function(t){var n=t.children,r=t.innerProps;return Y("div",J({},De(t,"indicatorsContainer",{indicators:!0}),r),n)},Uv,jO=["size"],FO=["innerProps","isRtl","size"],RO={name:"8mmkcg",styles:"display:inline-block;fill:currentColor;line-height:1;stroke:currentColor;stroke-width:0"},U2=function(t){var n=t.size,r=Gn(t,jO);return Y("svg",J({height:n,width:n,viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",css:RO},r))},eh=function(t){return Y(U2,J({size:20},t),Y("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"}))},H2=function(t){return Y(U2,J({size:20},t),Y("path",{d:"M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z"}))},W2=function(t,n){var r=t.isFocused,i=t.theme,o=i.spacing.baseUnit,a=i.colors;return Q({label:"indicatorContainer",display:"flex",transition:"color 150ms"},n?{}:{color:r?a.neutral60:a.neutral20,padding:o*2,":hover":{color:r?a.neutral80:a.neutral40}})},NO=W2,zO=function(t){var n=t.children,r=t.innerProps;return Y("div",J({},De(t,"dropdownIndicator",{indicator:!0,"dropdown-indicator":!0}),r),n||Y(H2,null))},VO=W2,BO=function(t){var n=t.children,r=t.innerProps;return Y("div",J({},De(t,"clearIndicator",{indicator:!0,"clear-indicator":!0}),r),n||Y(eh,null))},UO=function(t,n){var r=t.isDisabled,i=t.theme,o=i.spacing.baseUnit,a=i.colors;return Q({label:"indicatorSeparator",alignSelf:"stretch",width:1},n?{}:{backgroundColor:r?a.neutral10:a.neutral20,marginBottom:o*2,marginTop:o*2})},HO=function(t){var n=t.innerProps;return Y("span",J({},n,De(t,"indicatorSeparator",{"indicator-separator":!0})))},WO=V5(Uv||(Uv=B5([` 0%, 80%, 100% { opacity: 0; } 40% { opacity: 1; } -`]))),KO=function(t,n){var r=t.isFocused,i=t.size,o=t.theme,a=o.colors,s=o.spacing.baseUnit;return Q({label:"loadingIndicator",display:"flex",transition:"color 150ms",alignSelf:"center",fontSize:i,lineHeight:1,marginRight:i,textAlign:"center",verticalAlign:"middle"},n?{}:{color:r?a.neutral60:a.neutral20,padding:s*2})},Nc=function(t){var n=t.delay,r=t.offset;return Y("span",{css:Jp({animation:"".concat(qO," 1s ease-in-out ").concat(n,"ms infinite;"),backgroundColor:"currentColor",borderRadius:"1em",display:"inline-block",marginLeft:r?"1em":void 0,height:"1em",verticalAlign:"top",width:"1em"},"","")})},GO=function(t){var n=t.innerProps,r=t.isRtl,i=t.size,o=i===void 0?4:i,a=Gn(t,RO);return Y("div",J({},De(Q(Q({},a),{},{innerProps:n,isRtl:r,size:o}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),n),Y(Nc,{delay:0,offset:r}),Y(Nc,{delay:160,offset:!0}),Y(Nc,{delay:320,offset:!r}))},QO=function(t,n){var r=t.isDisabled,i=t.isFocused,o=t.theme,a=o.colors,s=o.borderRadius,l=o.spacing;return Q({label:"control",alignItems:"center",cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:l.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms"},n?{}:{backgroundColor:r?a.neutral5:a.neutral0,borderColor:r?a.neutral10:i?a.primary:a.neutral20,borderRadius:s,borderStyle:"solid",borderWidth:1,boxShadow:i?"0 0 0 1px ".concat(a.primary):void 0,"&:hover":{borderColor:i?a.primary:a.neutral30}})},YO=function(t){var n=t.children,r=t.isDisabled,i=t.isFocused,o=t.innerRef,a=t.innerProps,s=t.menuIsOpen;return Y("div",J({ref:o},De(t,"control",{control:!0,"control--is-disabled":r,"control--is-focused":i,"control--menu-is-open":s}),a),n)},JO=YO,ZO=["data"],XO=function(t,n){var r=t.theme.spacing;return n?{}:{paddingBottom:r.baseUnit*2,paddingTop:r.baseUnit*2}},e8=function(t){var n=t.children,r=t.cx,i=t.getStyles,o=t.getClassNames,a=t.Heading,s=t.headingProps,l=t.innerProps,u=t.label,c=t.theme,f=t.selectProps;return Y("div",J({},De(t,"group",{group:!0}),l),Y(a,J({},s,{selectProps:f,theme:c,getStyles:i,getClassNames:o,cx:r}),u),Y("div",null,n))},t8=function(t,n){var r=t.theme,i=r.colors,o=r.spacing;return Q({label:"group",cursor:"default",display:"block"},n?{}:{color:i.neutral40,fontSize:"75%",fontWeight:500,marginBottom:"0.25em",paddingLeft:o.baseUnit*3,paddingRight:o.baseUnit*3,textTransform:"uppercase"})},n8=function(t){var n=R2(t);n.data;var r=Gn(n,ZO);return Y("div",J({},De(t,"groupHeading",{"group-heading":!0}),r))},r8=e8,i8=["innerRef","isDisabled","isHidden","inputClassName"],o8=function(t,n){var r=t.isDisabled,i=t.value,o=t.theme,a=o.spacing,s=o.colors;return Q(Q({visibility:r?"hidden":"visible",transform:i?"translateZ(0)":""},a8),n?{}:{margin:a.baseUnit/2,paddingBottom:a.baseUnit/2,paddingTop:a.baseUnit/2,color:s.neutral80})},K2={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},a8={flex:"1 1 auto",display:"inline-grid",gridArea:"1 / 1 / 2 / 3",gridTemplateColumns:"0 min-content","&:after":Q({content:'attr(data-value) " "',visibility:"hidden",whiteSpace:"pre"},K2)},s8=function(t){return Q({label:"input",color:"inherit",background:0,opacity:t?0:1,width:"100%"},K2)},l8=function(t){var n=t.cx,r=t.value,i=R2(t),o=i.innerRef,a=i.isDisabled,s=i.isHidden,l=i.inputClassName,u=Gn(i,i8);return Y("div",J({},De(t,"input",{"input-container":!0}),{"data-value":r||""}),Y("input",J({className:n({input:!0},l),ref:o,style:s8(s),disabled:a},u)))},u8=l8,c8=function(t,n){var r=t.theme,i=r.spacing,o=r.borderRadius,a=r.colors;return Q({label:"multiValue",display:"flex",minWidth:0},n?{}:{backgroundColor:a.neutral10,borderRadius:o/2,margin:i.baseUnit/2})},f8=function(t,n){var r=t.theme,i=r.borderRadius,o=r.colors,a=t.cropWithEllipsis;return Q({overflow:"hidden",textOverflow:a||a===void 0?"ellipsis":void 0,whiteSpace:"nowrap"},n?{}:{borderRadius:i/2,color:o.neutral80,fontSize:"85%",padding:3,paddingLeft:6})},d8=function(t,n){var r=t.theme,i=r.spacing,o=r.borderRadius,a=r.colors,s=t.isFocused;return Q({alignItems:"center",display:"flex"},n?{}:{borderRadius:o/2,backgroundColor:s?a.dangerLight:void 0,paddingLeft:i.baseUnit,paddingRight:i.baseUnit,":hover":{backgroundColor:a.dangerLight,color:a.danger}})},G2=function(t){var n=t.children,r=t.innerProps;return Y("div",r,n)},p8=G2,h8=G2;function m8(e){var t=e.children,n=e.innerProps;return Y("div",J({role:"button"},n),t||Y(th,{size:14}))}var v8=function(t){var n=t.children,r=t.components,i=t.data,o=t.innerProps,a=t.isDisabled,s=t.removeProps,l=t.selectProps,u=r.Container,c=r.Label,f=r.Remove;return Y(u,{data:i,innerProps:Q(Q({},De(t,"multiValue",{"multi-value":!0,"multi-value--is-disabled":a})),o),selectProps:l},Y(c,{data:i,innerProps:Q({},De(t,"multiValueLabel",{"multi-value__label":!0})),selectProps:l},n),Y(f,{data:i,innerProps:Q(Q({},De(t,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(n||"option")},s),selectProps:l}))},g8=v8,y8=function(t,n){var r=t.isDisabled,i=t.isFocused,o=t.isSelected,a=t.theme,s=a.spacing,l=a.colors;return Q({label:"option",cursor:"default",display:"block",fontSize:"inherit",width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)"},n?{}:{backgroundColor:o?l.primary:i?l.primary25:"transparent",color:r?l.neutral20:o?l.neutral0:"inherit",padding:"".concat(s.baseUnit*2,"px ").concat(s.baseUnit*3,"px"),":active":{backgroundColor:r?void 0:o?l.primary:l.primary50}})},w8=function(t){var n=t.children,r=t.isDisabled,i=t.isFocused,o=t.isSelected,a=t.innerRef,s=t.innerProps;return Y("div",J({},De(t,"option",{option:!0,"option--is-disabled":r,"option--is-focused":i,"option--is-selected":o}),{ref:a,"aria-disabled":r},s),n)},S8=w8,b8=function(t,n){var r=t.theme,i=r.spacing,o=r.colors;return Q({label:"placeholder",gridArea:"1 / 1 / 2 / 3"},n?{}:{color:o.neutral50,marginLeft:i.baseUnit/2,marginRight:i.baseUnit/2})},E8=function(t){var n=t.children,r=t.innerProps;return Y("div",J({},De(t,"placeholder",{placeholder:!0}),r),n)},_8=E8,x8=function(t,n){var r=t.isDisabled,i=t.theme,o=i.spacing,a=i.colors;return Q({label:"singleValue",gridArea:"1 / 1 / 2 / 3",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},n?{}:{color:r?a.neutral40:a.neutral80,marginLeft:o.baseUnit/2,marginRight:o.baseUnit/2})},C8=function(t){var n=t.children,r=t.isDisabled,i=t.innerProps;return Y("div",J({},De(t,"singleValue",{"single-value":!0,"single-value--is-disabled":r}),i),n)},O8=C8,k8={ClearIndicator:UO,Control:JO,DropdownIndicator:VO,DownChevron:W2,CrossIcon:th,Group:r8,GroupHeading:n8,IndicatorsContainer:jO,IndicatorSeparator:WO,Input:u8,LoadingIndicator:GO,Menu:EO,MenuList:xO,MenuPortal:IO,LoadingMessage:AO,NoOptionsMessage:kO,MultiValue:g8,MultiValueContainer:p8,MultiValueLabel:h8,MultiValueRemove:m8,Option:S8,Placeholder:_8,SelectContainer:LO,SingleValue:O8,ValueContainer:DO},A8=function(t){return Q(Q({},k8),t.components)},Wv=Number.isNaN||function(t){return typeof t=="number"&&t!==t};function P8(e,t){return!!(e===t||Wv(e)&&Wv(t))}function I8(e,t){if(e.length!==t.length)return!1;for(var n=0;n1?"s":""," ").concat(o.join(","),", selected.");case"select-option":return a?"option ".concat(i," is disabled. Select another option."):"option ".concat(i,", selected.");default:return""}},onFocus:function(t){var n=t.context,r=t.focused,i=t.options,o=t.label,a=o===void 0?"":o,s=t.selectValue,l=t.isDisabled,u=t.isSelected,c=function(y,m){return y&&y.length?"".concat(y.indexOf(m)+1," of ").concat(y.length):""};if(n==="value"&&s)return"value ".concat(a," focused, ").concat(c(s,r),".");if(n==="menu"){var f=l?" disabled":"",d="".concat(u?"selected":"focused").concat(f);return"option ".concat(a," ").concat(d,", ").concat(c(i,r),".")}return""},onFilter:function(t){var n=t.inputValue,r=t.resultsMessage;return"".concat(r).concat(n?" for search term "+n:"",".")}},$8=function(t){var n=t.ariaSelection,r=t.focusedOption,i=t.focusedValue,o=t.focusableOptions,a=t.isFocused,s=t.selectValue,l=t.selectProps,u=t.id,c=l.ariaLiveMessages,f=l.getOptionLabel,d=l.inputValue,h=l.isMulti,y=l.isOptionDisabled,m=l.isSearchable,w=l.menuIsOpen,p=l.options,v=l.screenReaderStatus,g=l.tabSelectsValue,S=l["aria-label"],_=l["aria-live"],x=b.useMemo(function(){return Q(Q({},D8),c||{})},[c]),E=b.useMemo(function(){var z="";if(n&&x.onChange){var L=n.option,M=n.options,D=n.removedValue,A=n.removedValues,I=n.value,F=function(X){return Array.isArray(X)?null:X},R=D||L||F(I),V=R?f(R):"",T=M||A||void 0,N=T?T.map(f):[],H=Q({isDisabled:R&&y(R,s),label:V,labels:N},n);z=x.onChange(H)}return z},[n,x,y,s,f]),C=b.useMemo(function(){var z="",L=r||i,M=!!(r&&s&&s.includes(r));if(L&&x.onFocus){var D={focused:L,label:f(L),isDisabled:y(L,s),isSelected:M,options:o,context:L===r?"menu":"value",selectValue:s};z=x.onFocus(D)}return z},[r,i,f,y,x,o,s]),k=b.useMemo(function(){var z="";if(w&&p.length&&x.onFilter){var L=v({count:o.length});z=x.onFilter({inputValue:d,resultsMessage:L})}return z},[o,d,w,x,p,v]),P=b.useMemo(function(){var z="";if(x.guidance){var L=i?"value":w?"menu":"input";z=x.guidance({"aria-label":S,context:L,isDisabled:r&&y(r,s),isMulti:h,isSearchable:m,tabSelectsValue:g})}return z},[S,r,i,h,y,m,w,x,s,g]),$="".concat(C," ").concat(k," ").concat(P),j=Y(b.Fragment,null,Y("span",{id:"aria-selection"},E),Y("span",{id:"aria-context"},$)),U=(n==null?void 0:n.action)==="initial-input-focus";return Y(b.Fragment,null,Y(qv,{id:u},U&&j),Y(qv,{"aria-live":_,"aria-atomic":"false","aria-relevant":"additions text"},a&&!U&&j))},j8=$8,Sd=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],F8=new RegExp("["+Sd.map(function(e){return e.letters}).join("")+"]","g"),Q2={};for(var zc=0;zc-1}},V8=["innerRef"];function B8(e){var t=e.innerRef,n=Gn(e,V8),r=hO(n,"onExited","in","enter","exit","appear");return Y("input",J({ref:t},r,{css:Jp({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var U8=function(t){t.preventDefault(),t.stopPropagation()};function H8(e){var t=e.isEnabled,n=e.onBottomArrive,r=e.onBottomLeave,i=e.onTopArrive,o=e.onTopLeave,a=b.useRef(!1),s=b.useRef(!1),l=b.useRef(0),u=b.useRef(null),c=b.useCallback(function(w,p){if(u.current!==null){var v=u.current,g=v.scrollTop,S=v.scrollHeight,_=v.clientHeight,x=u.current,E=p>0,C=S-_-g,k=!1;C>p&&a.current&&(r&&r(w),a.current=!1),E&&s.current&&(o&&o(w),s.current=!1),E&&p>C?(n&&!a.current&&n(w),x.scrollTop=S,k=!0,a.current=!0):!E&&-p>g&&(i&&!s.current&&i(w),x.scrollTop=0,k=!0,s.current=!0),k&&U8(w)}},[n,r,i,o]),f=b.useCallback(function(w){c(w,w.deltaY)},[c]),d=b.useCallback(function(w){l.current=w.changedTouches[0].clientY},[]),h=b.useCallback(function(w){var p=l.current-w.changedTouches[0].clientY;c(w,p)},[c]),y=b.useCallback(function(w){if(w){var p=fO?{passive:!1}:!1;w.addEventListener("wheel",f,p),w.addEventListener("touchstart",d,p),w.addEventListener("touchmove",h,p)}},[h,d,f]),m=b.useCallback(function(w){w&&(w.removeEventListener("wheel",f,!1),w.removeEventListener("touchstart",d,!1),w.removeEventListener("touchmove",h,!1))},[h,d,f]);return b.useEffect(function(){if(t){var w=u.current;return y(w),function(){m(w)}}},[t,y,m]),function(w){u.current=w}}var Gv=["boxSizing","height","overflow","paddingRight","position"],Qv={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function Yv(e){e.preventDefault()}function Jv(e){e.stopPropagation()}function Zv(){var e=this.scrollTop,t=this.scrollHeight,n=e+this.offsetHeight;e===0?this.scrollTop=1:n===t&&(this.scrollTop=e-1)}function Xv(){return"ontouchstart"in window||navigator.maxTouchPoints}var e0=!!(typeof window<"u"&&window.document&&window.document.createElement),ho=0,oi={capture:!1,passive:!1};function W8(e){var t=e.isEnabled,n=e.accountForScrollbars,r=n===void 0?!0:n,i=b.useRef({}),o=b.useRef(null),a=b.useCallback(function(l){if(e0){var u=document.body,c=u&&u.style;if(r&&Gv.forEach(function(y){var m=c&&c[y];i.current[y]=m}),r&&ho<1){var f=parseInt(i.current.paddingRight,10)||0,d=document.body?document.body.clientWidth:0,h=window.innerWidth-d+f||0;Object.keys(Qv).forEach(function(y){var m=Qv[y];c&&(c[y]=m)}),c&&(c.paddingRight="".concat(h,"px"))}u&&Xv()&&(u.addEventListener("touchmove",Yv,oi),l&&(l.addEventListener("touchstart",Zv,oi),l.addEventListener("touchmove",Jv,oi))),ho+=1}},[r]),s=b.useCallback(function(l){if(e0){var u=document.body,c=u&&u.style;ho=Math.max(ho-1,0),r&&ho<1&&Gv.forEach(function(f){var d=i.current[f];c&&(c[f]=d)}),u&&Xv()&&(u.removeEventListener("touchmove",Yv,oi),l&&(l.removeEventListener("touchstart",Zv,oi),l.removeEventListener("touchmove",Jv,oi)))}},[r]);return b.useEffect(function(){if(t){var l=o.current;return a(l),function(){s(l)}}},[t,a,s]),function(l){o.current=l}}var q8=function(){return document.activeElement&&document.activeElement.blur()},K8={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function G8(e){var t=e.children,n=e.lockEnabled,r=e.captureEnabled,i=r===void 0?!0:r,o=e.onBottomArrive,a=e.onBottomLeave,s=e.onTopArrive,l=e.onTopLeave,u=H8({isEnabled:i,onBottomArrive:o,onBottomLeave:a,onTopArrive:s,onTopLeave:l}),c=W8({isEnabled:n}),f=function(h){u(h),c(h)};return Y(b.Fragment,null,n&&Y("div",{onClick:q8,css:K8}),t(f))}var Q8={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},Y8=function(t){var n=t.name,r=t.onFocus;return Y("input",{required:!0,name:n,tabIndex:-1,"aria-hidden":"true",onFocus:r,css:Q8,value:"",onChange:function(){}})},J8=Y8,Z8=function(t){return t.label},X8=function(t){return t.label},ek=function(t){return t.value},tk=function(t){return!!t.isDisabled},nk={clearIndicator:BO,container:MO,control:QO,dropdownIndicator:zO,group:XO,groupHeading:t8,indicatorsContainer:$O,indicatorSeparator:HO,input:o8,loadingIndicator:KO,loadingMessage:OO,menu:wO,menuList:_O,menuPortal:PO,multiValue:c8,multiValueLabel:f8,multiValueRemove:d8,noOptionsMessage:CO,option:y8,placeholder:b8,singleValue:x8,valueContainer:TO},rk={primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},ik=4,J2=4,ok=38,ak=J2*2,sk={baseUnit:J2,controlHeight:ok,menuGutter:ak},Uc={borderRadius:ik,colors:rk,spacing:sk},lk={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:Uv(),captureMenuScroll:!Uv(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:z8(),formatGroupLabel:Z8,getOptionLabel:X8,getOptionValue:ek,isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:tk,loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!uO(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(t){var n=t.count;return"".concat(n," result").concat(n!==1?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function t0(e,t,n,r){var i=tw(e,t,n),o=nw(e,t,n),a=ew(e,t),s=Tl(e,t);return{type:"option",data:t,isDisabled:i,isSelected:o,label:a,value:s,index:r}}function Z2(e,t){return e.options.map(function(n,r){if("options"in n){var i=n.options.map(function(a,s){return t0(e,a,t,s)}).filter(function(a){return n0(e,a)});return i.length>0?{type:"group",data:n,options:i,index:r}:void 0}var o=t0(e,n,t,r);return n0(e,o)?o:void 0}).filter(dO)}function X2(e){return e.reduce(function(t,n){return n.type==="group"?t.push.apply(t,b2(n.options.map(function(r){return r.data}))):t.push(n.data),t},[])}function uk(e,t){return X2(Z2(e,t))}function n0(e,t){var n=e.inputValue,r=n===void 0?"":n,i=t.data,o=t.isSelected,a=t.label,s=t.value;return(!iw(e)||!o)&&rw(e,{label:a,value:s,data:i},r)}function ck(e,t){var n=e.focusedValue,r=e.selectValue,i=r.indexOf(n);if(i>-1){var o=t.indexOf(n);if(o>-1)return n;if(i-1?n:t[0]}var ew=function(t,n){return t.getOptionLabel(n)},Tl=function(t,n){return t.getOptionValue(n)};function tw(e,t,n){return typeof e.isOptionDisabled=="function"?e.isOptionDisabled(t,n):!1}function nw(e,t,n){if(n.indexOf(t)>-1)return!0;if(typeof e.isOptionSelected=="function")return e.isOptionSelected(t,n);var r=Tl(e,t);return n.some(function(i){return Tl(e,i)===r})}function rw(e,t,n){return e.filterOption?e.filterOption(t,n):!0}var iw=function(t){var n=t.hideSelectedOptions,r=t.isMulti;return n===void 0?r:n},dk=1,ow=function(e){V6(n,e);var t=W6(n);function n(r){var i;if(N6(this,n),i=t.call(this,r),i.state={ariaSelection:null,focusedOption:null,focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0},i.blockOptionHover=!1,i.isComposing=!1,i.commonProps=void 0,i.initialTouchX=0,i.initialTouchY=0,i.instancePrefix="",i.openAfterFocus=!1,i.scrollToFocusedOptionOnUpdate=!1,i.userIsDragging=void 0,i.controlRef=null,i.getControlRef=function(s){i.controlRef=s},i.focusedOptionRef=null,i.getFocusedOptionRef=function(s){i.focusedOptionRef=s},i.menuListRef=null,i.getMenuListRef=function(s){i.menuListRef=s},i.inputRef=null,i.getInputRef=function(s){i.inputRef=s},i.focus=i.focusInput,i.blur=i.blurInput,i.onChange=function(s,l){var u=i.props,c=u.onChange,f=u.name;l.name=f,i.ariaOnChange(s,l),c(s,l)},i.setValue=function(s,l,u){var c=i.props,f=c.closeMenuOnSelect,d=c.isMulti,h=c.inputValue;i.onInputChange("",{action:"set-value",prevInputValue:h}),f&&(i.setState({inputIsHiddenAfterUpdate:!d}),i.onMenuClose()),i.setState({clearFocusValueOnUpdate:!0}),i.onChange(s,{action:l,option:u})},i.selectOption=function(s){var l=i.props,u=l.blurInputOnSelect,c=l.isMulti,f=l.name,d=i.state.selectValue,h=c&&i.isOptionSelected(s,d),y=i.isOptionDisabled(s,d);if(h){var m=i.getOptionValue(s);i.setValue(d.filter(function(w){return i.getOptionValue(w)!==m}),"deselect-option",s)}else if(!y)c?i.setValue([].concat(b2(d),[s]),"select-option",s):i.setValue(s,"select-option");else{i.ariaOnChange(s,{action:"select-option",option:s,name:f});return}u&&i.blurInput()},i.removeValue=function(s){var l=i.props.isMulti,u=i.state.selectValue,c=i.getOptionValue(s),f=u.filter(function(h){return i.getOptionValue(h)!==c}),d=cs(l,f,f[0]||null);i.onChange(d,{action:"remove-value",removedValue:s}),i.focusInput()},i.clearValue=function(){var s=i.state.selectValue;i.onChange(cs(i.props.isMulti,[],null),{action:"clear",removedValues:s})},i.popValue=function(){var s=i.props.isMulti,l=i.state.selectValue,u=l[l.length-1],c=l.slice(0,l.length-1),f=cs(s,c,c[0]||null);i.onChange(f,{action:"pop-value",removedValue:u})},i.getValue=function(){return i.state.selectValue},i.cx=function(){for(var s=arguments.length,l=new Array(s),u=0;ud||f>d}},i.onTouchEnd=function(s){i.userIsDragging||(i.controlRef&&!i.controlRef.contains(s.target)&&i.menuListRef&&!i.menuListRef.contains(s.target)&&i.blurInput(),i.initialTouchX=0,i.initialTouchY=0)},i.onControlTouchEnd=function(s){i.userIsDragging||i.onControlMouseDown(s)},i.onClearIndicatorTouchEnd=function(s){i.userIsDragging||i.onClearIndicatorMouseDown(s)},i.onDropdownIndicatorTouchEnd=function(s){i.userIsDragging||i.onDropdownIndicatorMouseDown(s)},i.handleInputChange=function(s){var l=i.props.inputValue,u=s.currentTarget.value;i.setState({inputIsHiddenAfterUpdate:!1}),i.onInputChange(u,{action:"input-change",prevInputValue:l}),i.props.menuIsOpen||i.onMenuOpen()},i.onInputFocus=function(s){i.props.onFocus&&i.props.onFocus(s),i.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(i.openAfterFocus||i.props.openMenuOnFocus)&&i.openMenu("first"),i.openAfterFocus=!1},i.onInputBlur=function(s){var l=i.props.inputValue;if(i.menuListRef&&i.menuListRef.contains(document.activeElement)){i.inputRef.focus();return}i.props.onBlur&&i.props.onBlur(s),i.onInputChange("",{action:"input-blur",prevInputValue:l}),i.onMenuClose(),i.setState({focusedValue:null,isFocused:!1})},i.onOptionHover=function(s){i.blockOptionHover||i.state.focusedOption===s||i.setState({focusedOption:s})},i.shouldHideSelectedOptions=function(){return iw(i.props)},i.onValueInputFocus=function(s){s.preventDefault(),s.stopPropagation(),i.focus()},i.onKeyDown=function(s){var l=i.props,u=l.isMulti,c=l.backspaceRemovesValue,f=l.escapeClearsValue,d=l.inputValue,h=l.isClearable,y=l.isDisabled,m=l.menuIsOpen,w=l.onKeyDown,p=l.tabSelectsValue,v=l.openMenuOnFocus,g=i.state,S=g.focusedOption,_=g.focusedValue,x=g.selectValue;if(!y&&!(typeof w=="function"&&(w(s),s.defaultPrevented))){switch(i.blockOptionHover=!0,s.key){case"ArrowLeft":if(!u||d)return;i.focusValue("previous");break;case"ArrowRight":if(!u||d)return;i.focusValue("next");break;case"Delete":case"Backspace":if(d)return;if(_)i.removeValue(_);else{if(!c)return;u?i.popValue():h&&i.clearValue()}break;case"Tab":if(i.isComposing||s.shiftKey||!m||!p||!S||v&&i.isOptionSelected(S,x))return;i.selectOption(S);break;case"Enter":if(s.keyCode===229)break;if(m){if(!S||i.isComposing)return;i.selectOption(S);break}return;case"Escape":m?(i.setState({inputIsHiddenAfterUpdate:!1}),i.onInputChange("",{action:"menu-close",prevInputValue:d}),i.onMenuClose()):h&&f&&i.clearValue();break;case" ":if(d)return;if(!m){i.openMenu("first");break}if(!S)return;i.selectOption(S);break;case"ArrowUp":m?i.focusOption("up"):i.openMenu("last");break;case"ArrowDown":m?i.focusOption("down"):i.openMenu("first");break;case"PageUp":if(!m)return;i.focusOption("pageup");break;case"PageDown":if(!m)return;i.focusOption("pagedown");break;case"Home":if(!m)return;i.focusOption("first");break;case"End":if(!m)return;i.focusOption("last");break;default:return}s.preventDefault()}},i.instancePrefix="react-select-"+(i.props.instanceId||++dk),i.state.selectValue=Vv(r.value),r.menuIsOpen&&i.state.selectValue.length){var o=i.buildFocusableOptions(),a=o.indexOf(i.state.selectValue[0]);i.state.focusedOption=o[a]}return i}return z6(n,[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&Bv(this.menuListRef,this.focusedOptionRef)}},{key:"componentDidUpdate",value:function(i){var o=this.props,a=o.isDisabled,s=o.menuIsOpen,l=this.state.isFocused;(l&&!a&&i.isDisabled||l&&s&&!i.menuIsOpen)&&this.focusInput(),l&&a&&!i.isDisabled?this.setState({isFocused:!1},this.onMenuClose):!l&&!a&&i.isDisabled&&this.inputRef===document.activeElement&&this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(Bv(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(i,o){this.props.onInputChange(i,o)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(i){var o=this,a=this.state,s=a.selectValue,l=a.isFocused,u=this.buildFocusableOptions(),c=i==="first"?0:u.length-1;if(!this.props.isMulti){var f=u.indexOf(s[0]);f>-1&&(c=f)}this.scrollToFocusedOptionOnUpdate=!(l&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:u[c]},function(){return o.onMenuOpen()})}},{key:"focusValue",value:function(i){var o=this.state,a=o.selectValue,s=o.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var l=a.indexOf(s);s||(l=-1);var u=a.length-1,c=-1;if(a.length){switch(i){case"previous":l===0?c=0:l===-1?c=u:c=l-1;break;case"next":l>-1&&l0&&arguments[0]!==void 0?arguments[0]:"first",o=this.props.pageSize,a=this.state.focusedOption,s=this.getFocusableOptions();if(s.length){var l=0,u=s.indexOf(a);a||(u=-1),i==="up"?l=u>0?u-1:s.length-1:i==="down"?l=(u+1)%s.length:i==="pageup"?(l=u-o,l<0&&(l=0)):i==="pagedown"?(l=u+o,l>s.length-1&&(l=s.length-1)):i==="last"&&(l=s.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:s[l],focusedValue:null})}}},{key:"getTheme",value:function(){return this.props.theme?typeof this.props.theme=="function"?this.props.theme(Uc):Q(Q({},Uc),this.props.theme):Uc}},{key:"getCommonProps",value:function(){var i=this.clearValue,o=this.cx,a=this.getStyles,s=this.getClassNames,l=this.getValue,u=this.selectOption,c=this.setValue,f=this.props,d=f.isMulti,h=f.isRtl,y=f.options,m=this.hasValue();return{clearValue:i,cx:o,getStyles:a,getClassNames:s,getValue:l,hasValue:m,isMulti:d,isRtl:h,options:y,selectOption:u,selectProps:f,setValue:c,theme:this.getTheme()}}},{key:"hasValue",value:function(){var i=this.state.selectValue;return i.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var i=this.props,o=i.isClearable,a=i.isMulti;return o===void 0?a:o}},{key:"isOptionDisabled",value:function(i,o){return tw(this.props,i,o)}},{key:"isOptionSelected",value:function(i,o){return nw(this.props,i,o)}},{key:"filterOption",value:function(i,o){return rw(this.props,i,o)}},{key:"formatOptionLabel",value:function(i,o){if(typeof this.props.formatOptionLabel=="function"){var a=this.props.inputValue,s=this.state.selectValue;return this.props.formatOptionLabel(i,{context:o,inputValue:a,selectValue:s})}else return this.getOptionLabel(i)}},{key:"formatGroupLabel",value:function(i){return this.props.formatGroupLabel(i)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var i=this.props,o=i.isDisabled,a=i.isSearchable,s=i.inputId,l=i.inputValue,u=i.tabIndex,c=i.form,f=i.menuIsOpen,d=i.required,h=this.getComponents(),y=h.Input,m=this.state,w=m.inputIsHidden,p=m.ariaSelection,v=this.commonProps,g=s||this.getElementId("input"),S=Q(Q(Q({"aria-autocomplete":"list","aria-expanded":f,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":d,role:"combobox"},f&&{"aria-controls":this.getElementId("listbox"),"aria-owns":this.getElementId("listbox")}),!a&&{"aria-readonly":!0}),this.hasValue()?(p==null?void 0:p.action)==="initial-input-focus"&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return a?b.createElement(y,J({},v,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:g,innerRef:this.getInputRef,isDisabled:o,isHidden:w,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:u,form:c,type:"text",value:l},S)):b.createElement(B8,J({id:g,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:Ml,onFocus:this.onInputFocus,disabled:o,tabIndex:u,inputMode:"none",form:c,value:""},S))}},{key:"renderPlaceholderOrValue",value:function(){var i=this,o=this.getComponents(),a=o.MultiValue,s=o.MultiValueContainer,l=o.MultiValueLabel,u=o.MultiValueRemove,c=o.SingleValue,f=o.Placeholder,d=this.commonProps,h=this.props,y=h.controlShouldRenderValue,m=h.isDisabled,w=h.isMulti,p=h.inputValue,v=h.placeholder,g=this.state,S=g.selectValue,_=g.focusedValue,x=g.isFocused;if(!this.hasValue()||!y)return p?null:b.createElement(f,J({},d,{key:"placeholder",isDisabled:m,isFocused:x,innerProps:{id:this.getElementId("placeholder")}}),v);if(w)return S.map(function(C,k){var P=C===_,$="".concat(i.getOptionLabel(C),"-").concat(i.getOptionValue(C));return b.createElement(a,J({},d,{components:{Container:s,Label:l,Remove:u},isFocused:P,isDisabled:m,key:$,index:k,removeProps:{onClick:function(){return i.removeValue(C)},onTouchEnd:function(){return i.removeValue(C)},onMouseDown:function(U){U.preventDefault()}},data:C}),i.formatOptionLabel(C,"value"))});if(p)return null;var E=S[0];return b.createElement(c,J({},d,{data:E,isDisabled:m}),this.formatOptionLabel(E,"value"))}},{key:"renderClearIndicator",value:function(){var i=this.getComponents(),o=i.ClearIndicator,a=this.commonProps,s=this.props,l=s.isDisabled,u=s.isLoading,c=this.state.isFocused;if(!this.isClearable()||!o||l||!this.hasValue()||u)return null;var f={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return b.createElement(o,J({},a,{innerProps:f,isFocused:c}))}},{key:"renderLoadingIndicator",value:function(){var i=this.getComponents(),o=i.LoadingIndicator,a=this.commonProps,s=this.props,l=s.isDisabled,u=s.isLoading,c=this.state.isFocused;if(!o||!u)return null;var f={"aria-hidden":"true"};return b.createElement(o,J({},a,{innerProps:f,isDisabled:l,isFocused:c}))}},{key:"renderIndicatorSeparator",value:function(){var i=this.getComponents(),o=i.DropdownIndicator,a=i.IndicatorSeparator;if(!o||!a)return null;var s=this.commonProps,l=this.props.isDisabled,u=this.state.isFocused;return b.createElement(a,J({},s,{isDisabled:l,isFocused:u}))}},{key:"renderDropdownIndicator",value:function(){var i=this.getComponents(),o=i.DropdownIndicator;if(!o)return null;var a=this.commonProps,s=this.props.isDisabled,l=this.state.isFocused,u={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return b.createElement(o,J({},a,{innerProps:u,isDisabled:s,isFocused:l}))}},{key:"renderMenu",value:function(){var i=this,o=this.getComponents(),a=o.Group,s=o.GroupHeading,l=o.Menu,u=o.MenuList,c=o.MenuPortal,f=o.LoadingMessage,d=o.NoOptionsMessage,h=o.Option,y=this.commonProps,m=this.state.focusedOption,w=this.props,p=w.captureMenuScroll,v=w.inputValue,g=w.isLoading,S=w.loadingMessage,_=w.minMenuHeight,x=w.maxMenuHeight,E=w.menuIsOpen,C=w.menuPlacement,k=w.menuPosition,P=w.menuPortalTarget,$=w.menuShouldBlockScroll,j=w.menuShouldScrollIntoView,U=w.noOptionsMessage,z=w.onMenuScrollToTop,L=w.onMenuScrollToBottom;if(!E)return null;var M=function(T,N){var H=T.type,W=T.data,X=T.isDisabled,oe=T.isSelected,Ie=T.label,xe=T.value,be=m===W,Ce=X?void 0:function(){return i.onOptionHover(W)},Zt=X?void 0:function(){return i.selectOption(W)},_t="".concat(i.getElementId("option"),"-").concat(N),Ma={id:_t,onClick:Zt,onMouseMove:Ce,onMouseOver:Ce,tabIndex:-1};return b.createElement(h,J({},y,{innerProps:Ma,data:W,isDisabled:X,isSelected:oe,key:_t,label:Ie,type:H,value:xe,isFocused:be,innerRef:be?i.getFocusedOptionRef:void 0}),i.formatOptionLabel(T.data,"menu"))},D;if(this.hasOptions())D=this.getCategorizedOptions().map(function(V){if(V.type==="group"){var T=V.data,N=V.options,H=V.index,W="".concat(i.getElementId("group"),"-").concat(H),X="".concat(W,"-heading");return b.createElement(a,J({},y,{key:W,data:T,options:N,Heading:s,headingProps:{id:X,data:V.data},label:i.formatGroupLabel(V.data)}),V.options.map(function(oe){return M(oe,"".concat(H,"-").concat(oe.index))}))}else if(V.type==="option")return M(V,"".concat(V.index))});else if(g){var A=S({inputValue:v});if(A===null)return null;D=b.createElement(f,y,A)}else{var I=U({inputValue:v});if(I===null)return null;D=b.createElement(d,y,I)}var F={minMenuHeight:_,maxMenuHeight:x,menuPlacement:C,menuPosition:k,menuShouldScrollIntoView:j},R=b.createElement(SO,J({},y,F),function(V){var T=V.ref,N=V.placerProps,H=N.placement,W=N.maxHeight;return b.createElement(l,J({},y,F,{innerRef:T,innerProps:{onMouseDown:i.onMenuMouseDown,onMouseMove:i.onMenuMouseMove,id:i.getElementId("listbox")},isLoading:g,placement:H}),b.createElement(G8,{captureEnabled:p,onTopArrive:z,onBottomArrive:L,lockEnabled:$},function(X){return b.createElement(u,J({},y,{innerRef:function(Ie){i.getMenuListRef(Ie),X(Ie)},isLoading:g,maxHeight:W,focusedOption:m}),D)}))});return P||k==="fixed"?b.createElement(c,J({},y,{appendTo:P,controlElement:this.controlRef,menuPlacement:C,menuPosition:k}),R):R}},{key:"renderFormField",value:function(){var i=this,o=this.props,a=o.delimiter,s=o.isDisabled,l=o.isMulti,u=o.name,c=o.required,f=this.state.selectValue;if(c&&!this.hasValue()&&!s)return b.createElement(J8,{name:u,onFocus:this.onValueInputFocus});if(!(!u||s))if(l)if(a){var d=f.map(function(m){return i.getOptionValue(m)}).join(a);return b.createElement("input",{name:u,type:"hidden",value:d})}else{var h=f.length>0?f.map(function(m,w){return b.createElement("input",{key:"i-".concat(w),name:u,type:"hidden",value:i.getOptionValue(m)})}):b.createElement("input",{name:u,type:"hidden",value:""});return b.createElement("div",null,h)}else{var y=f[0]?this.getOptionValue(f[0]):"";return b.createElement("input",{name:u,type:"hidden",value:y})}}},{key:"renderLiveRegion",value:function(){var i=this.commonProps,o=this.state,a=o.ariaSelection,s=o.focusedOption,l=o.focusedValue,u=o.isFocused,c=o.selectValue,f=this.getFocusableOptions();return b.createElement(j8,J({},i,{id:this.getElementId("live-region"),ariaSelection:a,focusedOption:s,focusedValue:l,isFocused:u,selectValue:c,focusableOptions:f}))}},{key:"render",value:function(){var i=this.getComponents(),o=i.Control,a=i.IndicatorsContainer,s=i.SelectContainer,l=i.ValueContainer,u=this.props,c=u.className,f=u.id,d=u.isDisabled,h=u.menuIsOpen,y=this.state.isFocused,m=this.commonProps=this.getCommonProps();return b.createElement(s,J({},m,{className:c,innerProps:{id:f,onKeyDown:this.onKeyDown},isDisabled:d,isFocused:y}),this.renderLiveRegion(),b.createElement(o,J({},m,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:d,isFocused:y,menuIsOpen:h}),b.createElement(l,J({},m,{isDisabled:d}),this.renderPlaceholderOrValue(),this.renderInput()),b.createElement(a,J({},m,{isDisabled:d}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],[{key:"getDerivedStateFromProps",value:function(i,o){var a=o.prevProps,s=o.clearFocusValueOnUpdate,l=o.inputIsHiddenAfterUpdate,u=o.ariaSelection,c=o.isFocused,f=o.prevWasFocused,d=i.options,h=i.value,y=i.menuIsOpen,m=i.inputValue,w=i.isMulti,p=Vv(h),v={};if(a&&(h!==a.value||d!==a.options||y!==a.menuIsOpen||m!==a.inputValue)){var g=y?uk(i,p):[],S=s?ck(o,p):null,_=fk(o,g);v={selectValue:p,focusedOption:_,focusedValue:S,clearFocusValueOnUpdate:!1}}var x=l!=null&&i!==a?{inputIsHidden:l,inputIsHiddenAfterUpdate:void 0}:{},E=u,C=c&&f;return c&&!C&&(E={value:cs(w,p,p[0]||null),options:p,action:"initial-input-focus"},C=!f),(u==null?void 0:u.action)==="initial-input-focus"&&(E=null),Q(Q(Q({},v),x),{},{prevProps:i,ariaSelection:E,prevWasFocused:C})}}]),n}(b.Component);ow.defaultProps=lk;var pk=b.forwardRef(function(e,t){var n=R6(e);return b.createElement(ow,J({ref:t},n))}),hk=pk;function mk(e){return O.jsx(hk,{classNames:{container:()=>"text-lg bg-white rounded text-gray-400",valueContainer:()=>"text-lg !text-gray-600 !py-1",singleValue:()=>"text-lg !text-gray-600 py-1",multiValue:()=>"text-lg !text-gray-600",menuList:()=>"text-lg !text-gray-600"},...e})}const fs=({label:e,multiple:t,onChange:n,options:r,value:i})=>{const o=b.useMemo(()=>{if(!i)return t?[]:void 0;const s=i.split(",");return t?r.filter(l=>s.includes(l.value)):r.find(l=>l.value===i)},[i,r,t]),a=b.useCallback(s=>{if(Array.isArray(s))n==null||n(s.map(l=>l.value).join(","));else{const l=s;n==null||n((l==null?void 0:l.value)||"")}},[n]);return O.jsxs("div",{className:"flex flex-col text-gray-400 w-full max-w-xs hover:text-white",children:[O.jsx("span",{className:"flex-1 text-lg text-left",children:e}),O.jsx(mk,{value:o,isMulti:t,name:e,options:r,onChange:a})]})},vk=({onUpdate:e})=>{const{dotLottie:t,setAnimationOptions:n}=qp(),r=Au(),i=Fe(d=>d.editor.animationOptions),o=Fe(d=>d.editor.animationId),a=Fe(d=>d.editor.updated),s=Fe(d=>d.themes.list),l=b.useMemo(()=>s.map(({name:d})=>({label:d,value:d})),[s]),u=b.useMemo(()=>{var h;const d=[{label:"None",value:""}];return typeof i.assignedThemes<"u"&&Array.isArray(i.assignedThemes)?d:d.concat(((h=i.assignedThemes)==null?void 0:h.split(",").map(y=>({label:y,value:y})))||[])},[i,o]);b.useEffect(()=>{if(o)return(async()=>{const d=await t.getAnimation(o);d&&r(Cv({direction:d.direction,speed:d.speed,playMode:d.playMode,loop:d.loop,autoplay:d.autoplay,hover:d.hover,intermission:d.intermission,defaultTheme:d.defaultTheme,assignedThemes:d.themes.map(h=>h.id).join(",")||void 0,defaultActiveAnimation:d.defaultActiveAnimation}))})(),()=>{r(Cv({}))}},[r,t,o]);const c=b.useCallback(d=>h=>{d==="assignedThemes"&&!String(h).split(",").includes(i.defaultTheme||"")&&r(Av({defaultTheme:""})),r(Av({[d]:h})),r(Cl(!0))},[r,i]),f=b.useCallback(()=>{o&&(n(o,i),r(Cl(!1)),e())},[o,i,n,r,e]);return O.jsxs("div",{className:"h-full flex flex-col",children:[O.jsxs("div",{className:"flex justify-between items-stretch pr-4 flex-shrink border-b border-gray-600",children:[O.jsxs("span",{className:"text-white text-sm border-b border-b-blue-500 border-r border-gray-600 px-4 flex items-center",children:["Animation: ",o]}),O.jsx("button",{title:"Save",className:"text-gray-400 py-1 hover:text-white disabled:text-gray-700",onClick:f,disabled:!a,children:O.jsx(yy,{size:33})})]}),O.jsxs("div",{className:"p-8 flex-1 max-h-[calc(100vh-5.5rem)] overflow-y-auto custom-scrollbar",children:[O.jsx("div",{className:"text-white",children:"Playback options"}),O.jsx("ul",{children:Object.keys(i).map(d=>["loop","autoplay","hover"].includes(d)?O.jsx("li",{children:O.jsx(Mv,{label:d,value:i[d],onToggle:c(d)})},d):["playMode"].includes(d)?O.jsx("li",{children:O.jsx(fs,{onChange:c(d),label:d,value:i[d],options:[{label:"Normal",value:"normal"},{label:"Bounce",value:"bounce"}]})},d):["direction"].includes(d)?O.jsx("li",{children:O.jsx(fs,{onChange:c(d),label:d,value:String(i[d]),options:[{label:"Normal",value:"1"},{label:"Inverted",value:"-1"}]})},d):["speed","intermission"].includes(d)?O.jsx("li",{children:O.jsx(T6,{label:d,value:i[d],onChange:c(d)})},d):["defaultTheme"].includes(d)?O.jsx("li",{children:O.jsx(fs,{onChange:c(d),label:"defaultTheme",options:u||[],value:i[d]||""})},d):void 0)}),O.jsx("div",{className:"text-white mt-8",children:"Other options"}),O.jsxs("div",{children:[O.jsx(fs,{multiple:!0,onChange:c("assignedThemes"),label:"Assign Themes",value:i.assignedThemes,options:l}),O.jsx(Mv,{label:"Default ActiveAnimation",value:i.defaultActiveAnimation,onToggle:c("defaultActiveAnimation")})]})]})]})},gk="modulepreload",yk=function(e){return"/player-component/"+e},r0={},tn=function(t,n,r){if(!n||n.length===0)return t();const i=document.getElementsByTagName("link");return Promise.all(n.map(o=>{if(o=yk(o),o in r0)return;r0[o]=!0;const a=o.endsWith(".css"),s=a?'[rel="stylesheet"]':"";if(!!r)for(let c=i.length-1;c>=0;c--){const f=i[c];if(f.href===o&&(!a||f.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${o}"]${s}`))return;const u=document.createElement("link");if(u.rel=a?"stylesheet":gk,a||(u.as="script",u.crossOrigin=""),u.href=o,document.head.appendChild(u),a)return new Promise((c,f)=>{u.addEventListener("load",c),u.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${o}`)))})})).then(()=>t()).catch(o=>{const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o})};var i0={},wk=function(e,t,n,r,i){var o=new Worker(i0[t]||(i0[t]=URL.createObjectURL(new Blob([e+';addEventListener("error",function(e){e=e.error;postMessage({$e$:[e.message,e.code,e.stack]})})'],{type:"text/javascript"}))));return o.onmessage=function(a){var s=a.data,l=s.$e$;if(l){var u=new Error(l[0]);u.code=l[1],u.stack=l[2],i(u,null)}else i(null,s)},o.postMessage(n,r),o},ct=Uint8Array,jr=Uint16Array,aw=Int32Array,nh=new ct([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),rh=new ct([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),sw=new ct([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),lw=function(e,t){for(var n=new jr(31),r=0;r<31;++r)n[r]=t+=1<>1|(ue&21845)<<1,Ln=(Ln&52428)>>2|(Ln&13107)<<2,Ln=(Ln&61680)>>4|(Ln&3855)<<4,Dl[ue]=((Ln&65280)>>8|(Ln&255)<<8)>>1;var Ln,ue,Li=function(e,t,n){for(var r=e.length,i=0,o=new jr(t);i>l]=u}else for(s=new jr(r),i=0;i>15-e[i]);return s},Oa=new ct(288);for(ue=0;ue<144;++ue)Oa[ue]=8;var ue;for(ue=144;ue<256;++ue)Oa[ue]=9;var ue;for(ue=256;ue<280;++ue)Oa[ue]=7;var ue;for(ue=280;ue<288;++ue)Oa[ue]=8;var ue,fw=new ct(32);for(ue=0;ue<32;++ue)fw[ue]=5;var ue,dw=Li(Oa,9,1),pw=Li(fw,5,1),$s=function(e){for(var t=e[0],n=1;nt&&(t=e[n]);return t},Nt=function(e,t,n){var r=t/8|0;return(e[r]|e[r+1]<<8)>>(t&7)&n},js=function(e,t){var n=t/8|0;return(e[n]|e[n+1]<<8|e[n+2]<<16)>>(t&7)},hw=function(e){return(e+7)/8|0},Tu=function(e,t,n){(t==null||t<0)&&(t=0),(n==null||n>e.length)&&(n=e.length);var r=new ct(n-t);return r.set(e.subarray(t,n)),r},mw=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],ut=function(e,t,n){var r=new Error(t||mw[e]);if(r.code=e,Error.captureStackTrace&&Error.captureStackTrace(r,ut),!n)throw r;return r},vw=function(e,t,n,r){var i=e.length,o=r?r.length:0;if(!i||t.f&&!t.l)return n||new ct(0);var a=!n||t.i!=2,s=t.i;n||(n=new ct(i*3));var l=function(xe){var be=n.length;if(xe>be){var Ce=new ct(Math.max(be*2,xe));Ce.set(n),n=Ce}},u=t.f||0,c=t.p||0,f=t.b||0,d=t.l,h=t.d,y=t.m,m=t.n,w=i*8;do{if(!d){u=Nt(e,c,1);var p=Nt(e,c+1,3);if(c+=3,p)if(p==1)d=dw,h=pw,y=9,m=5;else if(p==2){var v=Nt(e,c,31)+257,g=Nt(e,c+10,15)+4,S=v+Nt(e,c+5,31)+1;c+=14;for(var _=new ct(S),x=new ct(19),E=0;E>4;if(j<16)_[E++]=j;else{var U=0,z=0;for(j==16?(z=3+Nt(e,c,3),c+=2,U=_[E-1]):j==17?(z=3+Nt(e,c,7),c+=3):j==18&&(z=11+Nt(e,c,127),c+=7);z--;)_[E++]=U}}var L=_.subarray(0,v),M=_.subarray(v);y=$s(L),m=$s(M),d=Li(L,y,1),h=Li(M,m,1)}else ut(1);else{var j=hw(c)+4,D=e[j-4]|e[j-3]<<8,A=j+D;if(A>i){s&&ut(0);break}a&&l(f+D),n.set(e.subarray(j,A),f),t.b=f+=D,t.p=c=A*8,t.f=u;continue}if(c>w){s&&ut(0);break}}a&&l(f+131072);for(var I=(1<>4;if(c+=U&15,c>w){s&&ut(0);break}if(U||ut(2),V<256)n[f++]=V;else if(V==256){R=c,d=null;break}else{var T=V-254;if(V>264){var E=V-257,N=nh[E];T=Nt(e,c,(1<>4;H||ut(3),c+=H&15;var M=cw[W];if(W>3){var N=rh[W];M+=js(e,c)&(1<w){s&&ut(0);break}a&&l(f+131072);var X=f+T;if(f>>0},Hc=function(e,t){return an(e,t)+an(e,t+4)*4294967296};function Ak(e,t,n){return n||(n=t,t={}),typeof n!="function"&&ut(7),kk(e,t,[Ok],function(r){return gw(oh(r.data[0],yw(r.data[1])))},1,n)}function oh(e,t){return vw(e,{i:2},t&&t.out,t&&t.dictionary)}var bd=typeof TextDecoder<"u"&&new TextDecoder,Pk=0;try{bd.decode(Ek,{stream:!0}),Pk=1}catch{}var Ik=function(e){for(var t="",n=0;;){var r=e[n++],i=(r>127)+(r>223)+(r>239);if(n+i>e.length)return{s:t,r:Tu(e,n-1)};i?i==3?(r=((r&15)<<18|(e[n++]&63)<<12|(e[n++]&63)<<6|e[n++]&63)-65536,t+=String.fromCharCode(55296|r>>10,56320|r&1023)):i&1?t+=String.fromCharCode((r&31)<<6|e[n++]&63):t+=String.fromCharCode((r&15)<<12|(e[n++]&63)<<6|e[n++]&63):t+=String.fromCharCode(r)}};function no(e,t){if(t){for(var n="",r=0;r65558)return a(ut(13,0,1),null),i;var l=xn(e,s+8);if(l){var u=l,c=an(e,s+16),f=c==4294967295||u==65535;if(f){var d=an(e,s-12);f=an(e,d)==101075792,f&&(u=l=an(e,d+32),c=an(e,d+48))}for(var h=t&&t.filter,y=function(w){var p=Lk(e,c,f),v=p[0],g=p[1],S=p[2],_=p[3],x=p[4],E=p[5],C=Mk(e,E);c=x;var k=function($,j){$?(i(),a($,null)):(j&&(o[_]=j),--l||a(null,o))};if(!h||h({name:_,size:g,originalSize:S,compression:v}))if(!v)k(null,Tu(e,C,C+g));else if(v==8){var P=e.subarray(C,C+g);if(g<32e4)try{k(null,oh(P,{out:new ct(S)}))}catch($){k($,null)}else r.push(Ak(P,{size:S},k))}else k(ut(14,"unknown compression type "+v,1),null);else k(null,null)},m=0;m{if(n.path){let r=n.path.map(({key:i})=>i).join(".");t.nested[r]=[...t.nested[r]||[],n.message]}else t.root=[...t.root||[],n.message];return t},{nested:{}})}var jk=class extends Error{constructor(t){super(t[0].message);ee(this,"issues");this.name="ValiError",this.issues=t}};function Fk(e,t){return{reason:e==null?void 0:e.reason,validation:t.validation,origin:(e==null?void 0:e.origin)||"value",message:t.message,input:t.input,abortEarly:e==null?void 0:e.abortEarly,abortPipeEarly:e==null?void 0:e.abortPipeEarly}}function Rk(e,t){return{reason:t,origin:e==null?void 0:e.origin,abortEarly:e==null?void 0:e.abortEarly,abortPipeEarly:e==null?void 0:e.abortPipeEarly}}function Cr(e,t,n,r){if(!t||!t.length)return{output:e};let i,o,a=e;for(let s of t){let l=s(a);if(l.issue){i=i||Rk(n,r);let u=Fk(i,l.issue);if(o?o.push(u):o=[u],i.abortEarly||i.abortPipeEarly)break}else a=l.output}return o?{issues:o}:{output:a}}function hn(e,t){return!e||typeof e=="string"?[e,t]:[void 0,e]}function Mn(e,t,n,r,i,o){return{issues:[{reason:t,validation:n,origin:(e==null?void 0:e.origin)||"value",message:r,input:i,issues:o,abortEarly:e==null?void 0:e.abortEarly,abortPipeEarly:e==null?void 0:e.abortPipeEarly}]}}function Nk(e=[]){return{schema:"any",async:!1,_parse(t,n){return Cr(t,e,n,"any")}}}function Ro(e,t,n){let[r,i]=hn(t,n);return{schema:"array",array:{item:e},async:!1,_parse(o,a){if(!Array.isArray(o))return Mn(a,"type","array",r||"Invalid type",o);let s,l=[];for(let u=0;us.length)return Mn(l,"type","tuple",o||"Invalid type",s);let u,c=[];for(let f=0;f({...o,...a.object}),{}),r,i)}function Wk(e,t,n,r){let[i,o]=hn(n,r);return Jt(Object.entries(e.object).reduce((a,[s,l])=>t.includes(s)?a:{...a,[s]:l},{}),i,o)}function qk(e,t,n){let r=e._parse(t,n);return r.issues?{success:!1,error:new jk(r.issues),issues:r.issues}:{success:!0,data:r.output,output:r.output}}function _d(e,t){return n=>n>e?{issue:{validation:"max_value",message:t||"Invalid value",input:n}}:{output:n}}function xd(e,t){return n=>nt in e?ah(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Aa=(e,t)=>function(){return t||(0,e[ww(e)[0]])((t={exports:{}}).exports,t),t.exports},Zk=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of ww(t))!Yk.call(e,i)&&i!==n&&ah(e,i,{get:()=>t[i],enumerable:!(r=Gk(t,i))||r.enumerable});return e},Xk=(e,t,n)=>(n=e!=null?Kk(Qk(e)):{},Zk(t||!e||!e.__esModule?ah(n,"default",{value:e,enumerable:!0}):n,e)),eA=(e,t,n)=>(Jk(e,typeof t!="symbol"?t+"":t,n),n),tA=Aa({"../../node_modules/.pnpm/@rgba-image+copy@0.1.3/node_modules/@rgba-image/copy/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.copy=void 0;var t=(n,r,i=0,o=0,a=n.width-i,s=n.height-o,l=0,u=0)=>{if(i=i|0,o=o|0,a=a|0,s=s|0,l=l|0,u=u|0,a<=0||s<=0)return;let c=new Uint32Array(n.data.buffer),f=new Uint32Array(r.data.buffer);for(let d=0;d=n.height)continue;let y=u+d;if(!(y<0||y>=r.height))for(let m=0;m=n.width)continue;let p=l+m;if(p<0||p>=r.width)continue;let v=h*n.width+w,g=y*r.width+p;f[g]=c[v]}}};e.copy=t}}),nA=Aa({"../../node_modules/.pnpm/@rgba-image+create-image@0.1.1/node_modules/@rgba-image/create-image/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CreateImageFactory=(t=[0,0,0,0],n=4)=>{if(n=Math.floor(n),isNaN(n)||n<1)throw TypeError("channels should be a positive non-zero number");if(!("length"in t)||t.lengthi===0);return(i,o,a)=>{if(i===void 0||o===void 0)throw TypeError("Not enough arguments");if(i=Math.floor(i),o=Math.floor(o),isNaN(i)||i<1||isNaN(o)||o<1)throw TypeError("Index or size is negative or greater than the allowed amount");let s=i*o*n;if(a===void 0&&(a=new Uint8ClampedArray(s)),a instanceof Uint8ClampedArray){if(a.length!==s)throw TypeError("Index or size is negative or greater than the allowed amount");if(!r)for(let l=0;l{if(o<=-a||o>=a||o==0)return 0;let s=o*Math.PI;return Math.sin(s)/s*Math.sin(s/a)/(s/a)},r=o=>Math.round(o*((1<{let c=u?2:3,f=1/s,d=Math.min(1,s),h=c/d,y=Math.floor((h+1)*2),m=new Int16Array((y+2)*a),w=0;for(let p=0;p>1]+=r(1-P);let $=0;for(;$0&&E[j]===0;)j--;let U=g+$,z=j-$+1;m[w++]=U,m[w++]=z,m.set(E.subarray($,j+1),w),w+=z}return m};e.filters=i}}),iA=Aa({"../../node_modules/.pnpm/@rgba-image+lanczos@0.1.1/node_modules/@rgba-image/lanczos/dist/convolve.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.convolve=void 0;var t=14,n=(r,i,o,a,s,l)=>{let u=0,c=0;for(let f=0;f0;S--){let _=l[d++];w=w+_*r[m]|0,p=p+_*r[m+1]|0,v=v+_*r[m+2]|0,g=g+_*r[m+3]|0,m=m+4|0}i[c]=w+8192>>t,i[c+1]=p+8192>>t,i[c+2]=v+8192>>t,i[c+3]=g+8192>>t,c=c+a*4|0}c=(f+1)*4|0,u=(f+1)*o*4|0}};e.convolve=n}}),oA=Aa({"../../node_modules/.pnpm/@rgba-image+lanczos@0.1.1/node_modules/@rgba-image/lanczos/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.lanczos2=e.lanczos=void 0;var t=tA(),n=nA(),r=rA(),i=iA(),o=(l,u,c=!1)=>{let f=u.width/l.width,d=u.height/l.height,h=r.filters(l.width,u.width,f,0,c),y=r.filters(l.height,u.height,d,0,c),m=new Uint8ClampedArray(u.width*l.height*4);i.convolve(l.data,m,l.width,l.height,u.width,h),i.convolve(m,u.data,l.height,u.width,u.height,y)},a=(l,u,c=0,f=0,d=l.width-c,h=l.height-f,y=0,m=0,w=u.width-y,p=u.height-m)=>{if(c=c|0,f=f|0,d=d|0,h=h|0,y=y|0,m=m|0,w=w|0,p=p|0,d<=0||h<=0||w<=0||p<=0)return;if(c===0&&f===0&&d===l.width&&h===l.height&&y===0&&m===0&&w===u.width&&p===u.height){o(l,u);return}let v=n.createImage(d,h),g=n.createImage(w,p);t.copy(l,v,c,f),o(v,g),t.copy(g,u,0,0,g.width,g.height,y,m)};e.lanczos=a;var s=(l,u,c=0,f=0,d=l.width-c,h=l.height-f,y=0,m=0,w=u.width-y,p=u.height-m)=>{if(c=c|0,f=f|0,d=d|0,h=h|0,y=y|0,m=m|0,w=w|0,p=p|0,d<=0||h<=0||w<=0||p<=0)return;if(c===0&&f===0&&d===l.width&&h===l.height&&y===0&&m===0&&w===u.width&&p===u.height){o(l,u,!0);return}let v=n.createImage(d,h),g=n.createImage(w,p);t.copy(l,v,c,f),o(v,g,!0),t.copy(g,u,0,0,g.width,g.height,y,m)};e.lanczos2=s}}),Sw=(e=>(e.Bounce="bounce",e.Normal="normal",e))(Sw||{}),aA=zk(Sw),bw=Jt({autoplay:ce(Wc()),defaultTheme:ce(Ye()),direction:ce(Ed([s0(1),s0(-1)])),hover:ce(Wc()),id:Ye(),intermission:ce(ln()),loop:ce(Ed([Wc(),ln()])),playMode:ce(aA),speed:ce(ln()),themeColor:ce(Ye())}),sA=Jt({animations:Ro(Ye()),id:Ye()}),lA=Jt({activeAnimationId:ce(Ye()),animations:Ro(bw),author:ce(Ye()),custom:ce(Uk(Ye(),Nk())),description:ce(Ye()),generator:ce(Ye()),keywords:ce(Ye()),revision:ce(ln()),themes:ce(Ro(sA)),states:ce(Ro(Ye())),version:ce(Ye())}),Ew=Wk(bw,["id"]),Xr=Jt({state:Ye()}),uA=Xr,cA=ka([Xr,Jt({ms:ln()})]),fA=ka([Xr,Jt({count:ln()})]),dA=Xr,pA=Xr,hA=Xr,mA=ka([Xr,Jt({threshold:ce(Ro(ln([xd(0),_d(1)])))})]),vA=Jt({onAfter:ce(cA),onClick:ce(uA),onComplete:ce(hA),onEnter:ce(fA),onMouseEnter:ce(dA),onMouseLeave:ce(pA),onShow:ce(mA)}),gA=ka([Ew,Jt({playOnScroll:ce(l0([ln([xd(0),_d(1)]),ln([xd(0),_d(1)])])),segments:ce(Ed([l0([ln(),ln()]),Ye()]))})]);ka([vA,Jt({animationId:ce(Ye()),playbackSettings:gA})]);var yA={jpeg:"image/jpeg",png:"image/png",gif:"image/gif",bmp:"image/bmp",svg:"image/svg+xml",webp:"image/webp",mpeg:"audio/mpeg",mp3:"audio/mp3"},u0={jpeg:[255,216,255],png:[137,80,78,71,13,10,26,10],gif:[71,73,70],bmp:[66,77],webp:[82,73,70,70,87,69,66,80],svg:[60,63,120],mp3:[73,68,51,3,0,0,0,0],mpeg:[73,68,51,3,0,0,0,0]},wA=e=>{let t=null,n=[];if(!e)return null;let r=e.substring(e.indexOf(",")+1);typeof window>"u"?t=Buffer.from(r,"base64").toString("binary"):t=atob(r);let i=new Uint8Array(t.length);for(let o=0;os===a[l]))return yA[o]}return null},sh=class extends Error{constructor(e,t){super(e),eA(this,"code"),this.name="[dotlottie-js]",this.code=t}};function _w(e){let t;if(typeof window>"u")t=Buffer.from(e).toString("base64");else{let n=Array.prototype.map.call(e,r=>String.fromCharCode(r)).join("");t=window.btoa(n)}return`data:${wA(t)};base64,${t}`}function c0(e){return"w"in e&&"h"in e&&!("xt"in e)&&"p"in e}function Cd(e){return!("h"in e)&&!("w"in e)&&"p"in e&&"e"in e&&"u"in e&&"id"in e}async function Pa(e,t=()=>!0){if(!(e instanceof Uint8Array))throw new sh("DotLottie not found","INVALID_DOTLOTTIE");return await new Promise((n,r)=>{Dk(e,{filter:t},(i,o)=>{i&&r(i),n(o)})})}async function lh(e,t,n){if(!(e instanceof Uint8Array))throw new sh("DotLottie not found","INVALID_DOTLOTTIE");return(await Pa(e,r=>r.name===t&&(!n||n(r))))[t]}async function Od(e){let t="manifest.json",n=(await Pa(e,r=>r.name===t))[t];if(!(typeof n>"u"))return JSON.parse(no(n,!1))}async function SA(e){if(!(e instanceof Uint8Array))return{success:!1,error:"DotLottie not found"};let t=await Od(e);if(typeof t>"u")return{success:!1,error:"Invalid .lottie file, manifest.json is missing"};let n=qk(lA,t);return n.success?{success:!0}:{success:!1,error:`Invalid .lottie file, manifest.json structure is invalid, ${JSON.stringify($k(n.error).nested,null,2)}`}}async function f0(e){let t=new Uint8Array(e),n=await SA(t);if(n.error)throw new sh(n.error,"INVALID_DOTLOTTIE");return t}async function bA(e,t){let n=await Pa(e,i=>{let o=i.name.replace("audio/","");return i.name.startsWith("audio/")&&(!t||t({...i,name:o}))}),r={};for(let i in n){let o=n[i];if(o instanceof Uint8Array){let a=i.replace("audio/","");r[a]=_w(o)}}return r}async function EA(e,t){var i;let n=new Map;for(let[o,a]of Object.entries(t))for(let s of a.assets||[])if(Cd(s)){let l=s.p;n.has(l)||n.set(l,new Set),(i=n.get(l))==null||i.add(o)}let r=await bA(e,o=>n.has(o.name));for(let[o,a]of n){let s=r[o];if(s)for(let l of a){let u=t[l];for(let c of(u==null?void 0:u.assets)||[])Cd(c)&&c.p===o&&(c.p=s,c.u="",c.e=1)}}}async function _A(e,t){let n=await Pa(e,i=>{let o=i.name.replace("images/","");return i.name.startsWith("images/")&&(!t||t({...i,name:o}))}),r={};for(let i in n){let o=n[i];if(o instanceof Uint8Array){let a=i.replace("images/","");r[a]=_w(o)}}return r}async function xA(e,t){var i;let n=new Map;for(let[o,a]of Object.entries(t))for(let s of a.assets||[])if(c0(s)){let l=s.p;n.has(l)||n.set(l,new Set),(i=n.get(l))==null||i.add(o)}let r=await _A(e,o=>n.has(o.name));for(let[o,a]of n){let s=r[o];if(s)for(let l of a){let u=t[l];for(let c of(u==null?void 0:u.assets)||[])c0(c)&&c.p===o&&(c.p=s,c.u="",c.e=1)}}}async function CA(e,t,{inlineAssets:n}={},r){let i=`animations/${t}.json`,o=await lh(e,i,r);if(typeof o>"u")return;let a=JSON.parse(no(o,!1));if(!n)return a;let s={[t]:a};return await xA(e,s),await EA(e,s),a}async function OA(e,t,n){let r=`themes/${t}.lss`,i=await lh(e,r,n);if(!(typeof i>"u"))return no(i,!1)}async function kA(e,t){let n={},r=await Pa(e,i=>{let o=i.name.replace("states/","").replace(".json","");return i.name.startsWith("states/")&&(!t||t({...i,name:o}))});for(let i in r){let o=r[i];if(o instanceof Uint8Array){let a=i.replace("states/","").replace(".json","");n[a]=no(o,!1)}}return n}async function AA(e,t,n){let r=`states/${t}.json`,i=await lh(e,r,n);return typeof i>"u"?void 0:JSON.parse(no(i,!1))}Xk(oA());function se(e,t="dotLottie-common"){return new Error(`[${t}]: ${e}`)}function ai(e,t="dotLottie-common",...n){console.error(`[${t}]:`,e,...n)}function Me(e,t="dotLottie-common",...n){console.warn(`[${t}]:`,e,...n)}function PA(e=""){let t=e.trim(),n=t.lastIndexOf("/"),r=t.substring(n+1),i=r.indexOf(".");return i!==-1?r.substring(0,i):r}function $l(e){return["v","ip","op","layers","fr","w","h"].every(t=>Object.prototype.hasOwnProperty.call(e,t))}function IA(e){let t=e.assets;return t?t.some(n=>Cd(n)):!1}function MA(e){try{let t=JSON.parse(e);return $l(t)}catch{return!1}}function j7(e,t){let n=Object.keys(e).find(r=>e[r]===t);if(n===void 0)throw new Error("Value not found in the object.");return n}var LA=class{constructor(){ee(this,"_dotLottie");ee(this,"_animationsMap",new Map);ee(this,"_themeMap",new Map);ee(this,"_stateMachinesMap",new Map);ee(this,"_manifest")}get dotLottie(){return this._dotLottie}get animationsMap(){return this._animationsMap}get themeMap(){return this._themeMap}get stateMachinesMap(){return this._stateMachinesMap}get manifest(){return this._manifest}async loadFromUrl(e){var n;let t=await fetch(e,{method:"GET",mode:"cors"});if(!t.ok)throw new Error(`Failed to load dotLottie from ${e} with status ${t.status}`);if((n=t.headers.get("content-type"))!=null&&n.includes("application/json")){let r=await t.json();if(!$l(r))throw new Error(`Invalid lottie JSON at ${e}`);let i=PA(e);this._animationsMap.set(i,r);let o={activeAnimationId:i,animations:[{id:i}]};this._manifest=o}else{this._dotLottie=await f0(await t.arrayBuffer());let r=await Od(this._dotLottie);if(!r)throw new Error("Manifest not found");this._manifest=r}}loadFromLottieJSON(e){if(!$l(e))throw new Error("Invalid lottie JSON");let t="my-animation";this._animationsMap.set(t,e);let n={activeAnimationId:t,animations:[{id:t}]};this._manifest=n}async loadFromArrayBuffer(e){this._dotLottie=await f0(e);let t=await Od(this._dotLottie);if(!t)throw new Error("Manifest not found");this._manifest=t}async getAnimation(e){if(this._animationsMap.get(e))return this._animationsMap.get(e);if(!this._dotLottie)return;let t=await CA(this._dotLottie,e,{inlineAssets:!0});return t&&this._animationsMap.set(e,t),t}async getTheme(e){if(this._themeMap.get(e))return this._themeMap.get(e);if(!this._dotLottie)return;let t=await OA(this._dotLottie,e);return t&&this._themeMap.set(e,t),t}async getStateMachines(){if(!this._dotLottie)return;let e=await kA(this._dotLottie);for(let t in e)if(t){let n=e[t];if(n){let r=JSON.parse(n);if(r){let i=r.descriptor.id;this._stateMachinesMap.get(i)||this._stateMachinesMap.set(i,r)}}}return Array.from(this._stateMachinesMap.values())}async getStateMachine(e){if(this._stateMachinesMap.get(e))return this._stateMachinesMap.get(e);if(!this._dotLottie)return;let t=await AA(this._dotLottie,e);return t&&this._stateMachinesMap.set(t.descriptor.id,t),t}};async function TA(e,t){let[{relottie:n},{default:r}]=await Promise.all([tn(()=>import("./dist-AIQGIF54-AIRDCTYW-3493aa73.js"),["assets/dist-AIQGIF54-AIRDCTYW-3493aa73.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]),tn(()=>import("./dist-4JHQ5UB4-UQC3DUUT-48854257.js"),["assets/dist-4JHQ5UB4-UQC3DUUT-48854257.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"])]),i=await n().use(r,{lss:t}).process(JSON.stringify(e));return JSON.parse(i.value)}function Du(){throw new Error("Cycle detected")}function uh(){if(Ti>1)Ti--;else{for(var e,t=!1;No!==void 0;){var n=No;for(No=void 0,kd++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&Cw(n))try{n.c()}catch(i){t||(e=i,t=!0)}n=r}}if(kd=0,Ti--,t)throw e}}var Le=void 0,No=void 0,Ti=0,kd=0,jl=0;function xw(e){if(Le!==void 0){var t=e.n;if(t===void 0||t.t!==Le)return t={i:0,S:e,p:Le.s,n:void 0,t:Le,e:void 0,x:void 0,r:t},Le.s!==void 0&&(Le.s.n=t),Le.s=t,e.n=t,32&Le.f&&e.S(t),t;if(t.i===-1)return t.i=0,t.n!==void 0&&(t.n.p=t.p,t.p!==void 0&&(t.p.n=t.n),t.p=Le.s,t.n=void 0,Le.s.n=t,Le.s=t),t}}function Et(e){this.v=e,this.i=0,this.n=void 0,this.t=void 0}Et.prototype.h=function(){return!0};Et.prototype.S=function(e){this.t!==e&&e.e===void 0&&(e.x=this.t,this.t!==void 0&&(this.t.e=e),this.t=e)};Et.prototype.U=function(e){if(this.t!==void 0){var t=e.e,n=e.x;t!==void 0&&(t.x=n,e.e=void 0),n!==void 0&&(n.e=t,e.x=void 0),e===this.t&&(this.t=n)}};Et.prototype.subscribe=function(e){var t=this;return jA(function(){var n=t.value,r=32&this.f;this.f&=-33;try{e(n)}finally{this.f|=r}})};Et.prototype.valueOf=function(){return this.value};Et.prototype.toString=function(){return this.value+""};Et.prototype.toJSON=function(){return this.value};Et.prototype.peek=function(){return this.v};Object.defineProperty(Et.prototype,"value",{get:function(){var e=xw(this);return e!==void 0&&(e.i=this.i),this.v},set:function(e){if(Le instanceof ei&&function(){throw new Error("Computed cannot have side-effects")}(),e!==this.v){kd>100&&Du(),this.v=e,this.i++,jl++,Ti++;try{for(var t=this.t;t!==void 0;t=t.x)t.t.N()}finally{uh()}}}});function DA(e){return new Et(e)}function Cw(e){for(var t=e.s;t!==void 0;t=t.n)if(t.S.i!==t.i||!t.S.h()||t.S.i!==t.i)return!0;return!1}function Ow(e){for(var t=e.s;t!==void 0;t=t.n){var n=t.S.n;if(n!==void 0&&(t.r=n),t.S.n=t,t.i=-1,t.n===void 0){e.s=t;break}}}function kw(e){for(var t=e.s,n=void 0;t!==void 0;){var r=t.p;t.i===-1?(t.S.U(t),r!==void 0&&(r.n=t.n),t.n!==void 0&&(t.n.p=r)):n=t,t.S.n=t.r,t.r!==void 0&&(t.r=void 0),t=r}e.s=n}function ei(e){Et.call(this,void 0),this.x=e,this.s=void 0,this.g=jl-1,this.f=4}(ei.prototype=new Et).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===jl))return!0;if(this.g=jl,this.f|=1,this.i>0&&!Cw(this))return this.f&=-2,!0;var e=Le;try{Ow(this),Le=this;var t=this.x();(16&this.f||this.v!==t||this.i===0)&&(this.v=t,this.f&=-17,this.i++)}catch(n){this.v=n,this.f|=16,this.i++}return Le=e,kw(this),this.f&=-2,!0};ei.prototype.S=function(e){if(this.t===void 0){this.f|=36;for(var t=this.s;t!==void 0;t=t.n)t.S.S(t)}Et.prototype.S.call(this,e)};ei.prototype.U=function(e){if(this.t!==void 0&&(Et.prototype.U.call(this,e),this.t===void 0)){this.f&=-33;for(var t=this.s;t!==void 0;t=t.n)t.S.U(t)}};ei.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var e=this.t;e!==void 0;e=e.x)e.t.N()}};ei.prototype.peek=function(){if(this.h()||Du(),16&this.f)throw this.v;return this.v};Object.defineProperty(ei.prototype,"value",{get:function(){1&this.f&&Du();var e=xw(this);if(this.h(),e!==void 0&&(e.i=this.i),16&this.f)throw this.v;return this.v}});function Aw(e){var t=e.u;if(e.u=void 0,typeof t=="function"){Ti++;var n=Le;Le=void 0;try{t()}catch(r){throw e.f&=-2,e.f|=8,ch(e),r}finally{Le=n,uh()}}}function ch(e){for(var t=e.s;t!==void 0;t=t.n)t.S.U(t);e.x=void 0,e.s=void 0,Aw(e)}function $A(e){if(Le!==this)throw new Error("Out-of-order effect");kw(this),Le=e,this.f&=-2,8&this.f&&ch(this),uh()}function Ia(e){this.x=e,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}Ia.prototype.c=function(){var e=this.S();try{if(8&this.f||this.x===void 0)return;var t=this.x();typeof t=="function"&&(this.u=t)}finally{e()}};Ia.prototype.S=function(){1&this.f&&Du(),this.f|=1,this.f&=-9,Aw(this),Ow(this),Ti++;var e=Le;return Le=this,$A.bind(this,e)};Ia.prototype.N=function(){2&this.f||(this.f|=2,this.o=No,No=this)};Ia.prototype.d=function(){this.f|=8,1&this.f||ch(this)};function jA(e){var t=new Ia(e);try{t.c()}catch(n){throw t.d(),n}return t.d.bind(t)}var FA=class{constructor(e){ee(this,"_state");ee(this,"_prevState");this._prevState=e,this._state=DA(e)}setState(e){this._prevState=this._state.value,this._state.value=e}subscribe(e){return this._state.subscribe(t=>e(t,this._prevState))}};async function RA(e,t){let[{DotLottieStateMachineManager:n}]=await Promise.all([tn(()=>import("./dotlottie-state-machine-manager-MM65C4SH-HEQNG5J3-f0445b80.js"),[])]);if(!e.length)throw se("No state machines available inside this .lottie!");return new n(e,t)}var NA={name:"@dotlottie/common",version:"0.6.0",type:"module",description:"",author:"Afsal , Sam Osborne ",license:"MIT",private:!0,engines:{node:">18.0.0"},module:"dist/index.js",types:"dist/index.d.ts",files:["dist"],keywords:[],scripts:{build:"tsup",dev:"tsup --watch",lint:"eslint .","type-check":"tsc --noEmit"},dependencies:{"@dotlottie/dotlottie-js":"0.6.0","@lottiefiles/relottie":"1.0.0","@lottiefiles/relottie-style":"0.4.1","@preact/signals-core":"^1.2.3",howler:"^2.2.3","lottie-web":"^5.12.2",xstate:"^4.38.1"},devDependencies:{"@lottiefiles/lottie-types":"^1.2.0","@types/howler":"^2.2.8",tsup:"^6.1.3",typescript:"^4.7.4"},publishConfig:{access:"restricted"}},ht=(e=>(e.Complete="complete",e.DataFail="data_fail",e.DataReady="data_ready",e.Error="error",e.Frame="frame",e.Freeze="freeze",e.LoopComplete="loopComplete",e.Pause="pause",e.Play="play",e.Ready="ready",e.Stop="stop",e.VisibilityChange="visibilityChange",e))(ht||{}),Dn=(e=>(e.Completed="completed",e.Error="error",e.Fetching="fetching",e.Frozen="frozen",e.Initial="initial",e.Loading="loading",e.Paused="paused",e.Playing="playing",e.Ready="ready",e.Stopped="stopped",e))(Dn||{}),zA=(e=>(e.Bounce="bounce",e.Normal="normal",e))(zA||{}),jt={autoplay:!1,direction:1,hover:!1,intermission:0,loop:!1,playMode:"normal",speed:1,defaultTheme:""},fh={activeStateId:"",autoplay:!1,currentState:"initial",frame:0,seeker:0,direction:1,hover:!1,loop:!1,playMode:"normal",speed:1,background:"transparent",intermission:0,currentAnimationId:void 0,visibilityPercentage:0},Fs=class{constructor(e,t,n){ee(this,"_lottie");ee(this,"_src");ee(this,"_animationConfig");ee(this,"_prevUserPlaybackOptions",{});ee(this,"_userPlaybackOptions");ee(this,"_hover",!1);ee(this,"_loop",!1);ee(this,"_counter",0);ee(this,"_intermission",0);ee(this,"_counterInterval",null);ee(this,"_container",null);ee(this,"_name");ee(this,"_mode","normal");ee(this,"_background","transparent");ee(this,"_animation");ee(this,"_defaultTheme");ee(this,"_activeAnimationId");ee(this,"_currentAnimationId");ee(this,"_testId");ee(this,"_listeners",new Map);ee(this,"_currentState","initial");ee(this,"_stateBeforeFreeze","initial");ee(this,"state",new FA(fh));ee(this,"_light",!1);ee(this,"_worker",!1);ee(this,"_dotLottieLoader",new LA);ee(this,"_activeStateId");ee(this,"_inInteractiveMode",!1);ee(this,"_scrollTicking",!1);ee(this,"_scrollCallback");ee(this,"_onShowIntersectionObserver");ee(this,"_visibilityPercentage",0);ee(this,"_audios",[]);ee(this,"_stateMachineManager");this._src=structuredClone(e),n!=null&&n.testId&&(this._testId=n.testId),this._defaultTheme=(n==null?void 0:n.defaultTheme)||"",this._userPlaybackOptions=this._validatePlaybackOptions(n||{}),typeof(n==null?void 0:n.activeAnimationId)=="string"&&(this._activeAnimationId=n.activeAnimationId),this._container=t||null,typeof(n==null?void 0:n.background)=="string"&&this.setBackground(n.background),typeof(n==null?void 0:n.activeStateId)<"u"&&(this._activeStateId=n.activeStateId);let{rendererSettings:r,...i}=n||{};this._animationConfig={loop:!1,autoplay:!1,renderer:"svg",rendererSettings:{clearCanvas:!0,progressiveLoad:!0,hideOnTransparent:!0,filterSize:{width:"200%",height:"200%",x:"-50%",y:"-50%"},...r},...i},n!=null&&n.light&&(this._light=n.light),n!=null&&n.worker&&(this._worker=n.worker),this._listenToHover(),this._listenToVisibilityChange()}_listenToHover(){var n,r,i,o;let e=()=>{this._hover&&this.currentState!=="playing"&&this.play()},t=()=>{this._hover&&this.currentState==="playing"&&this.stop()};(n=this._container)==null||n.removeEventListener("mouseenter",e),(r=this._container)==null||r.removeEventListener("mouseleave",t),(i=this._container)==null||i.addEventListener("mouseleave",t),(o=this._container)==null||o.addEventListener("mouseenter",e)}_onVisibilityChange(){!this._lottie||typeof document>"u"||(document.hidden&&this.currentState==="playing"?this.freeze():this.currentState==="frozen"&&this.unfreeze())}_listenToVisibilityChange(){typeof document<"u"&&typeof document.hidden<"u"&&document.addEventListener("visibilitychange",()=>this._onVisibilityChange())}_getOption(e){var n;if(typeof this._userPlaybackOptions[e]<"u")return this._userPlaybackOptions[e];let t=(n=this._dotLottieLoader.manifest)==null?void 0:n.animations.find(r=>r.id===this._currentAnimationId);return t&&typeof t[e]<"u"?t[e]:jt[e]}_getPlaybackOptions(){let e={};for(let t in jt)typeof jt[t]<"u"&&(e[t]=this._getOption(t));return e}_setPlayerState(e){var n,r,i;let t=e(this._getPlaybackOptions());try{Ew._parse(t)}catch{Me(`Invalid PlaybackOptions, ${JSON.stringify(t,null,2)}`);return}typeof t.defaultTheme<"u"&&(this._defaultTheme=t.defaultTheme),typeof t.playMode<"u"&&(this._mode=t.playMode),typeof t.intermission<"u"&&(this._intermission=t.intermission),typeof t.hover<"u"&&(this._hover=t.hover),typeof t.loop<"u"&&(this.clearCountTimer(),this._loop=t.loop,this._counter=0,(n=this._lottie)==null||n.setLoop(typeof t.loop=="number"?!0:t.loop)),typeof t.speed<"u"&&((r=this._lottie)==null||r.setSpeed(t.speed)),typeof t.autoplay<"u"&&this._lottie&&(this._lottie.autoplay=t.autoplay),typeof t.direction<"u"&&((i=this._lottie)==null||i.setDirection(t.direction))}_getOptionsFromAnimation(e){let{id:t,...n}=e;return{...jt,...n}}_updateTestData(){!this._testId||!this._lottie||(window.dotLottiePlayer||(window.dotLottiePlayer={[this._testId]:{}}),window.dotLottiePlayer[this._testId]={direction:this._lottie.playDirection,currentState:this._currentState,loop:this.loop,mode:this._mode,speed:this._lottie.playSpeed})}get currentState(){return this._currentState}clearCountTimer(){this._counterInterval&&clearInterval(this._counterInterval)}setCurrentState(e){this._currentState=e,this._notify(),this._updateTestData()}static isPathJSON(e){var t;return((t=e.split(".").pop())==null?void 0:t.toLowerCase())==="json"}get src(){return this._src}updateSrc(e){this._src!==e&&(this._src=structuredClone(e),this._activeAnimationId=void 0,this._currentAnimationId=void 0,this.load())}get intermission(){return this._intermission}get hover(){return this._hover}setHover(e){typeof e=="boolean"&&(this._hover=e,this._userPlaybackOptions.hover=e,this._notify())}setIntermission(e){this._intermission=e,this._userPlaybackOptions.intermission=e,this._notify()}get mode(){return this._mode}get animations(){return this._dotLottieLoader.animationsMap}get themes(){return this._dotLottieLoader.themeMap}setMode(e){typeof e=="string"&&(this._mode=e,this._userPlaybackOptions.playMode=e,this._setPlayerState(()=>({playMode:e})),this._notify(),this._updateTestData())}get container(){if(this._container)return this._container}goToAndPlay(e,t,n){if(!this._lottie||["loading"].includes(this._currentState)){Me("goToAndPlay() Can't use whilst loading.");return}this._lottie.goToAndPlay(e,t,n),this.setCurrentState("playing")}goToAndStop(e,t,n){if(!this._lottie||["loading"].includes(this._currentState)){Me("goToAndStop() Can't use whilst loading.");return}this._lottie.goToAndStop(e,t,n),this.setCurrentState("stopped")}seek(e){if(!this._lottie||["loading"].includes(this._currentState)){Me("seek() Can't use whilst loading.");return}let t=e;typeof t=="number"&&(t=Math.round(t));let n=/^(\d+)(%?)$/u.exec(t.toString());if(!n)return;let r=n[2]==="%"?this.totalFrames*Number(n[1])/100:n[1];r!==void 0&&(this._lottie.goToAndPlay(r,!0),this.currentState==="playing"?this.play():this.currentState==="frozen"?this.freeze():this.pause())}_areNumbersInRange(e,t){return e>=0&&e<=1&&t>=0&&t<=1}_updatePosition(e,t,n){let[r,i]=e??[0,this.totalFrames-1],[o,a]=t??[0,1];if(!this._areNumbersInRange(o,a)){ai("threshold values must be between 0 and 1");return}if(this.container){let{height:s,top:l}=this.container.getBoundingClientRect(),u=window.innerHeight-l,c=window.innerHeight+s,f=u/c,d=r+Math.round((f-o)/(a-o)*(i-r));n&&n(f),this.goToAndStop(d,!0),(d>=i||f>=a)&&this._handleAnimationComplete()}this._scrollTicking=!1}_requestTick(e,t,n){this._scrollTicking||(requestAnimationFrame(()=>this._updatePosition(e,t,n)),this._scrollTicking=!0)}playOnScroll(e){this.stop(),this._scrollCallback&&this.stopPlayOnScroll(),this._scrollCallback=()=>this._requestTick(e==null?void 0:e.segments,e==null?void 0:e.threshold,e==null?void 0:e.positionCallback),window.addEventListener("scroll",this._scrollCallback)}stopPlayOnScroll(){this._scrollCallback&&(window.removeEventListener("scroll",this._scrollCallback),this._scrollCallback=void 0)}stopPlayOnShow(){this._onShowIntersectionObserver&&(this._onShowIntersectionObserver.disconnect(),this._onShowIntersectionObserver=void 0)}addIntersectionObserver(e){if(!this.container)throw se("Can't play on show, player container element not available.");let t={root:null,rootMargin:"0px",threshold:e!=null&&e.threshold?e.threshold:[0,1]},n=r=>{r.forEach(i=>{var o,a;this._visibilityPercentage=i.intersectionRatio*100,i.isIntersecting?(e!=null&&e.callbackOnIntersect&&e.callbackOnIntersect(this._visibilityPercentage),(o=this._container)==null||o.dispatchEvent(new Event("visibilityChange"))):e!=null&&e.callbackOnIntersect&&(e.callbackOnIntersect(0),(a=this._container)==null||a.dispatchEvent(new Event("visibilityChange")))})};this._onShowIntersectionObserver=new IntersectionObserver(n,t),this._onShowIntersectionObserver.observe(this.container)}playOnShow(e){if(this.stop(),!this.container)throw se("Can't play on show, player container element not available.");this._onShowIntersectionObserver&&this.stopPlayOnShow(),this.addIntersectionObserver({threshold:(e==null?void 0:e.threshold)??[],callbackOnIntersect:t=>{t===0?this.pause():this.play()}})}_validatePlaybackOptions(e){if(!e)return{};let t={};for(let[n,r]of Object.entries(e))switch(n){case"autoplay":typeof r=="boolean"&&(t.autoplay=r);break;case"direction":typeof r=="number"&&[1,-1].includes(r)&&(t.direction=r);break;case"loop":(typeof r=="boolean"||typeof r=="number")&&(t.loop=r);break;case"playMode":typeof r=="string"&&["normal","bounce"].includes(r)&&(t.playMode=r);break;case"speed":typeof r=="number"&&(t.speed=r);break;case"themeColor":typeof r=="string"&&(t.themeColor=r);break;case"hover":typeof r=="boolean"&&(t.hover=r);break;case"intermission":typeof r=="number"&&(t.intermission=r);break;case"defaultTheme":typeof r=="string"&&(t.defaultTheme=r);break}return this._requireValidPlaybackOptions(t),t}_requireAnimationsInTheManifest(){var e;if(!((e=this._dotLottieLoader.manifest)!=null&&e.animations.length))throw se("No animations found in manifest.")}_requireAnimationsToBeLoaded(){if(this._dotLottieLoader.animationsMap.size===0)throw se("No animations have been loaded.")}async play(e,t){var n,r;if(["initial","loading"].includes(this._currentState)){Me("Player unable to play whilst loading.");return}if(this._requireAnimationsInTheManifest(),this._requireAnimationsToBeLoaded(),this._lottie&&!e){this._lottie.playDirection===-1&&this._lottie.currentFrame===0?this._lottie.goToAndPlay(this._lottie.totalFrames,!0):this._lottie.play(),this.setCurrentState("playing");return}if(typeof e=="number"){let i=(n=this._dotLottieLoader.manifest)==null?void 0:n.animations[e];if(!i)throw se("animation not found.");typeof t=="function"?await this.render({id:i.id,...t(this._getPlaybackOptions(),this._getOptionsFromAnimation(i))}):await this.render({id:i.id})}if(typeof e=="string"){let i=(r=this._dotLottieLoader.manifest)==null?void 0:r.animations.find(o=>o.id===e);if(!i)throw se("animation not found.");typeof t=="function"?await this.render({id:i.id,...t(this._getPlaybackOptions(),this._getOptionsFromAnimation(i))}):await this.render({id:i.id})}}playSegments(e,t){if(!this._lottie||["loading"].includes(this._currentState)){Me("playSegments() Can't use whilst loading.");return}this._lottie.playSegments(e,t),this.setCurrentState("playing")}resetSegments(e){if(!this._lottie||["loading"].includes(this._currentState)){Me("resetSegments() Can't use whilst loading.");return}this._lottie.resetSegments(e)}togglePlay(){this.currentState==="playing"?this.pause():this.play()}_getAnimationByIdOrIndex(e){var t,n;if(this._requireAnimationsInTheManifest(),this._requireAnimationsToBeLoaded(),typeof e=="number"){let r=(t=this._dotLottieLoader.manifest)==null?void 0:t.animations[e];if(!r)throw se("animation not found.");return r}if(typeof e=="string"){let r=(n=this._dotLottieLoader.manifest)==null?void 0:n.animations.find(i=>i.id===e);if(!r)throw se("animation not found.");return r}throw se("first param must be a number or string")}get activeAnimationId(){return this._getActiveAnimationId()}get currentAnimationId(){return this._currentAnimationId}get activeStateId(){return this._activeStateId}async _startInteractivity(e){if(!this._inInteractiveMode){ai("Can't start interactivity. Not in interactive mode. Call enterInteractiveMode(stateId: string) to start.");return}if(this._dotLottieLoader.stateMachinesMap.size===0&&await this._dotLottieLoader.getStateMachines(),this._dotLottieLoader.stateMachinesMap.size===0)throw se("No interactivity states are available.");if(e==="undefined")throw se("stateId is not specified.");this._stateMachineManager||(this._stateMachineManager=await RA(Array.from(this._dotLottieLoader.stateMachinesMap.values()),this)),this._stateMachineManager.start(e)}enterInteractiveMode(e){var t;if(e)this._inInteractiveMode||(this._prevUserPlaybackOptions={...this._userPlaybackOptions}),this._inInteractiveMode&&((t=this._stateMachineManager)==null||t.stop()),this._activeStateId=e,this._inInteractiveMode=!0,this._startInteractivity(e);else throw se("stateId must be a non-empty string.")}exitInteractiveMode(){var e;this._inInteractiveMode&&(this._inInteractiveMode=!1,this._activeStateId="",(e=this._stateMachineManager)==null||e.stop(),this._userPlaybackOptions={},this._userPlaybackOptions={...this._prevUserPlaybackOptions},this._prevUserPlaybackOptions={},this.reset())}reset(){var n;let e=this._getActiveAnimationId(),t=(n=this._dotLottieLoader.manifest)==null?void 0:n.animations.find(r=>r.id===e);if(this._inInteractiveMode&&this.exitInteractiveMode(),!t)throw se("animation not found.");this.play(e)}previous(e){if(!this._dotLottieLoader.manifest||!this._dotLottieLoader.manifest.animations.length)throw se("manifest not found.");if(this._inInteractiveMode){Me("previous() is not supported in interactive mode.");return}let t=this._dotLottieLoader.manifest.animations.findIndex(r=>r.id===this._currentAnimationId);if(t===-1)throw se("animation not found.");let n=this._dotLottieLoader.manifest.animations[(t-1+this._dotLottieLoader.manifest.animations.length)%this._dotLottieLoader.manifest.animations.length];if(!n||!n.id)throw se("animation not found.");typeof e=="function"?this.render({id:n.id,...e(this._getPlaybackOptions(),this._getOptionsFromAnimation(n))}):this.render({id:n.id})}next(e){if(!this._dotLottieLoader.manifest||!this._dotLottieLoader.manifest.animations.length)throw se("manifest not found.");if(this._inInteractiveMode){Me("next() is not supported in interactive mode.");return}let t=this._dotLottieLoader.manifest.animations.findIndex(r=>r.id===this._currentAnimationId);if(t===-1)throw se("animation not found.");let n=this._dotLottieLoader.manifest.animations[(t+1)%this._dotLottieLoader.manifest.animations.length];if(!n||!n.id)throw se("animation not found.");typeof e=="function"?this.render({id:n.id,...e(this._getPlaybackOptions(),this._getOptionsFromAnimation(n))}):this.render({id:n.id})}getManifest(){return this._dotLottieLoader.manifest}resize(){if(!this._lottie||["loading"].includes(this._currentState)){Me("resize() Can't use whilst loading.");return}this._lottie.resize()}stop(){if(!this._lottie||["loading"].includes(this._currentState)){Me("stop() Can't use whilst loading.");return}this.clearCountTimer(),this._counter=0,this._setPlayerState(()=>({direction:this._getOption("direction")})),this._lottie.stop(),this.setCurrentState("stopped")}pause(){if(!this._lottie||["loading"].includes(this._currentState)){Me("pause() Can't use whilst loading.");return}this.clearCountTimer(),this._lottie.pause(),this.setCurrentState("paused")}freeze(){if(!this._lottie||["loading"].includes(this._currentState)){Me("freeze() Can't use whilst loading.");return}this.currentState!=="frozen"&&(this._stateBeforeFreeze=this.currentState),this._lottie.pause(),this.setCurrentState("frozen")}unfreeze(){if(!this._lottie||["loading"].includes(this._currentState)){Me("unfreeze() Can't use whilst loading.");return}this._stateBeforeFreeze==="playing"?this.play():this.pause()}destroy(){var e,t;(e=this._container)!=null&&e.__lottie&&(this._container.__lottie.destroy(),this._container.__lottie=null),this._audios.length&&(this._audios.forEach(n=>{n.unload()}),this._audios=[]),this.clearCountTimer(),typeof document<"u"&&document.removeEventListener("visibilitychange",()=>this._onVisibilityChange()),this._counter=0,(t=this._lottie)==null||t.destroy()}getAnimationInstance(){return this._lottie}static getLottieWebVersion(){return`${NA.dependencies["lottie-web"]}`}addEventListener(e,t){var n,r,i;this._listeners.has(e)||this._listeners.set(e,new Set),(n=this._listeners.get(e))==null||n.add(t);try{e==="complete"?(r=this._container)==null||r.addEventListener(e,t):(i=this._lottie)==null||i.addEventListener(e,t)}catch(o){ai(`addEventListener ${o}`)}}getState(){var e,t,n;return{autoplay:((e=this._lottie)==null?void 0:e.autoplay)??!1,currentState:this._currentState,frame:this._frame,visibilityPercentage:this._visibilityPercentage,seeker:this._seeker,direction:((t=this._lottie)==null?void 0:t.playDirection)??1,hover:this._hover,loop:this._loop||!1,playMode:this._mode,speed:((n=this._lottie)==null?void 0:n.playSpeed)??1,background:this._background,intermission:this._intermission,defaultTheme:this._defaultTheme,currentAnimationId:this._currentAnimationId,activeStateId:this._activeStateId??""}}_notify(){this.state.setState(this.getState())}get totalFrames(){var e;return((e=this._lottie)==null?void 0:e.totalFrames)||0}get direction(){return this._lottie?this._lottie.playDirection:1}setDirection(e){this._requireValidDirection(e),this._setPlayerState(()=>({direction:e})),this._userPlaybackOptions.direction=e}get speed(){var e;return((e=this._lottie)==null?void 0:e.playSpeed)||1}setSpeed(e){this._requireValidSpeed(e),this._setPlayerState(()=>({speed:e})),this._userPlaybackOptions.speed=e}get autoplay(){var e;return((e=this._lottie)==null?void 0:e.autoplay)??!1}setAutoplay(e){if(this._requireValidAutoplay(e),!this._lottie||["loading"].includes(this._currentState)){Me("setAutoplay() Can't use whilst loading.");return}this._setPlayerState(()=>({autoplay:e})),this._userPlaybackOptions.autoplay=e}toggleAutoplay(){if(!this._lottie||["loading"].includes(this._currentState)){Me("toggleAutoplay() Can't use whilst loading.");return}this.setAutoplay(!this._lottie.autoplay)}get defaultTheme(){return this._defaultTheme}setDefaultTheme(e){this._setPlayerState(()=>({defaultTheme:e})),this._userPlaybackOptions.defaultTheme=e,this._animation&&this.render()}get loop(){return this._loop}setLoop(e){this._requireValidLoop(e),this._setPlayerState(()=>({loop:e})),this._userPlaybackOptions.loop=e}toggleLoop(){if(!this._lottie||["loading"].includes(this._currentState)){Me("toggleLoop() Can't use whilst loading.");return}this.setLoop(!this._loop)}get background(){return this._background}setBackground(e){this._requireValidBackground(e),this._container&&(this._background=e,this._container.style.backgroundColor=e)}get _frame(){return this._lottie?this.currentState==="completed"?this.direction===-1?0:this._lottie.totalFrames:this._lottie.currentFrame:0}get _seeker(){return this._lottie?this._frame/this._lottie.totalFrames*100:0}async revertToManifestValues(e){var r;let t;!Array.isArray(e)||e.length===0?t=["autoplay","defaultTheme","direction","hover","intermission","loop","playMode","speed","activeAnimationId"]:t=e;let n=!1;if(t.includes("activeAnimationId")){let i=(r=this._dotLottieLoader.manifest)==null?void 0:r.activeAnimationId,o=this._getAnimationByIdOrIndex(i||0);this._activeAnimationId=i,await this._setCurrentAnimation(o.id),n=!0}t.forEach(i=>{switch(i){case"autoplay":delete this._userPlaybackOptions.autoplay,this.setAutoplay(this._getOption("autoplay"));break;case"defaultTheme":delete this._userPlaybackOptions.defaultTheme,this.setDefaultTheme(this._getOption("defaultTheme"));break;case"direction":delete this._userPlaybackOptions.direction,this.setDirection(this._getOption("direction"));break;case"hover":delete this._userPlaybackOptions.hover,this.setHover(this._getOption("hover"));break;case"intermission":delete this._userPlaybackOptions.intermission,this.setIntermission(this._getOption("intermission"));break;case"loop":delete this._userPlaybackOptions.loop,this.setLoop(this._getOption("loop"));break;case"playMode":delete this._userPlaybackOptions.playMode,this.setMode(this._getOption("playMode")),this.setDirection(this._getOption("direction"));break;case"speed":delete this._userPlaybackOptions.speed,this.setSpeed(this._getOption("speed"));break}}),n&&this.render()}removeEventListener(e,t){var n,r,i;try{e==="complete"?(n=this._container)==null||n.removeEventListener(e,t):(r=this._lottie)==null||r.removeEventListener(e,t),(i=this._listeners.get(e))==null||i.delete(t)}catch(o){ai("removeEventListener",o)}}_handleAnimationComplete(){var t;typeof this._loop=="number"&&this.stop();let e=this.direction===-1?0:this.totalFrames;this.goToAndStop(e,!0),this._counter=0,this.clearCountTimer(),this.setCurrentState("completed"),(t=this._container)==null||t.dispatchEvent(new Event("complete"))}addEventListeners(){var e;if(!this._lottie||["loading"].includes(this._currentState)){Me("addEventListeners() Can't use whilst loading.");return}this._lottie.addEventListener("enterFrame",()=>{var t;if(!this._lottie){Me("enterFrame event : Lottie is undefined.");return}Math.floor(this._lottie.currentFrame)===0&&this.direction===-1&&((t=this._container)==null||t.dispatchEvent(new Event("complete")),this.loop||this.setCurrentState("completed")),this._notify()}),this._lottie.addEventListener("loopComplete",()=>{var r;if(!this._lottie){Me("loopComplete event : Lottie is undefined.");return}(r=this._container)==null||r.dispatchEvent(new Event("loopComplete")),this.intermission>0&&this.pause();let t=this._lottie.playDirection;if(typeof this._loop=="number"&&this._loop>0&&(this._counter+=this._mode==="bounce"?.5:1,this._counter>=this._loop)){this._handleAnimationComplete();return}this._mode==="bounce"&&typeof t=="number"&&(t=Number(t)*-1);let n=t===-1?this._lottie.totalFrames-1:0;this.intermission?(this.goToAndPlay(n,!0),this.pause(),this._counterInterval=window.setTimeout(()=>{this._lottie&&(this._setPlayerState(()=>({direction:t})),this.goToAndPlay(n,!0))},this._intermission)):(this._setPlayerState(()=>({direction:t})),this.goToAndPlay(t===-1?this.totalFrames-1:0,!0))}),this._lottie.addEventListener("complete",()=>{if(this._lottie&&this._loop===!1&&this._mode==="bounce"){if(this._counter+=.5,this._counter>=1){this._handleAnimationComplete();return}this._counterInterval=window.setTimeout(()=>{if(!this._lottie)return;let t=this._lottie.playDirection;this._mode==="bounce"&&typeof t=="number"&&(t=Number(t)*-1);let n=t===-1?this.totalFrames-1:0;this._setPlayerState(()=>({direction:t})),this.goToAndPlay(n,!0)},this._intermission)}else this._handleAnimationComplete()});for(let[t,n]of this._listeners)if(t==="complete")for(let r of n)(e=this._container)==null||e.addEventListener(t,r);else for(let r of n)this._lottie.addEventListener(t,r)}async _setCurrentAnimation(e){this._currentState="loading";let t=await this._dotLottieLoader.getAnimation(e);this._currentAnimationId=e,this._animation=t,this._currentState="ready"}async render(e){if(e!=null&&e.id)await this._setCurrentAnimation(e.id);else if(!this._animation)throw se("no animation selected");let t=jt.loop,n=jt.autoplay,r=jt.playMode,i=jt.intermission,o=jt.hover,a=jt.direction,s=jt.speed,l=jt.defaultTheme;t=(e==null?void 0:e.loop)??this._getOption("loop"),n=(e==null?void 0:e.autoplay)??this._getOption("autoplay"),r=(e==null?void 0:e.playMode)??this._getOption("playMode"),i=(e==null?void 0:e.intermission)??this._getOption("intermission"),o=(e==null?void 0:e.hover)??this._getOption("hover"),a=(e==null?void 0:e.direction)??this._getOption("direction"),s=(e==null?void 0:e.speed)??this._getOption("speed"),l=(e==null?void 0:e.defaultTheme)??this._getOption("defaultTheme");let u={...this._animationConfig,autoplay:o?!1:n,loop:typeof t=="number"?!0:t,renderer:this._worker?"svg":this._animationConfig.renderer??"svg"},c=await this._dotLottieLoader.getTheme(l);c&&this._animation?this._animation=await TA(this._animation,c):this._animation=await this._dotLottieLoader.getAnimation(this._currentAnimationId??"");let f=await this._getLottiePlayerInstance();if(this._activeStateId&&!this._inInteractiveMode){this.enterInteractiveMode(this._activeStateId);return}this.destroy(),this._setPlayerState(()=>({defaultTheme:l,playMode:r,intermission:i,hover:o,loop:t}));let d;if(this._animation&&IA(this._animation)){let{DotLottieAudio:h}=await tn(()=>import("./dotlottie-audio-XNJDYXTA-f557bb12.js"),["assets/dotlottie-audio-XNJDYXTA-f557bb12.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]);d=y=>{let m=new h({src:[y]});return this._audios.push(m),m}}d?this._lottie=f.loadAnimation({...u,container:this._container,animationData:this._animation,audioFactory:d}):this._lottie=f.loadAnimation({...u,container:this._container,animationData:this._animation}),typeof this._lottie.resetSegments>"u"&&(this._lottie.resetSegments=()=>{var h;(h=this._lottie)==null||h.playSegments([0,this._lottie.totalFrames],!0)}),this.addEventListeners(),this._container&&(this._container.__lottie=this._lottie),this._setPlayerState(()=>({direction:a,speed:s})),n&&!o&&this.play(),this._updateTestData()}async _getLottiePlayerInstance(){let e=this._animationConfig.renderer??"svg",t;if(this._worker)return e!=="svg"&&Me("Worker is only supported with svg renderer. Change or remove renderer prop to get rid of this warning."),t=await tn(()=>import("./lottie_worker-WHOD5EO7-VF575QIV-6e8b61e9.js"),["assets/lottie_worker-WHOD5EO7-VF575QIV-6e8b61e9.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]),t.default;switch(e){case"svg":{this._light?t=await tn(()=>import("./lottie_light-IOYK46WR-C42PZIWW-842cd67b.js"),["assets/lottie_light-IOYK46WR-C42PZIWW-842cd67b.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]):t=await tn(()=>import("./lottie_svg-NPHRPZVQ-SN5HKEBW-b354eb1e.js"),["assets/lottie_svg-NPHRPZVQ-SN5HKEBW-b354eb1e.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]);break}case"canvas":{this._light?t=await tn(()=>import("./lottie_light_canvas-JOJMVDMY-Y3JQKMNA-129b1fdc.js"),["assets/lottie_light_canvas-JOJMVDMY-Y3JQKMNA-129b1fdc.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]):t=await tn(()=>import("./lottie_canvas-MBHU2YSW-VFQ5A67K-34d36756.js"),["assets/lottie_canvas-MBHU2YSW-VFQ5A67K-34d36756.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]);break}case"html":{this._light?t=await tn(()=>import("./lottie_light_html-QXO6XUZK-N4R277UW-62a905c2.js"),["assets/lottie_light_html-QXO6XUZK-N4R277UW-62a905c2.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]):t=await tn(()=>import("./lottie_html-DEQZ7JWN-7UJDZM6D-84fdb830.js"),["assets/lottie_html-DEQZ7JWN-7UJDZM6D-84fdb830.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]);break}default:throw new Error(`Invalid renderer: ${e}`)}return t.default}_getActiveAnimationId(){var t;let e=this._dotLottieLoader.manifest;return this._activeAnimationId??(e==null?void 0:e.activeAnimationId)??((t=e==null?void 0:e.animations[0])==null?void 0:t.id)??void 0}async load(e){if(this._currentState==="loading"){Me("Loading in progress..");return}try{if(this.setCurrentState("loading"),typeof this._src=="string")if(MA(this._src)){let n=JSON.parse(this._src);this._dotLottieLoader.loadFromLottieJSON(n)}else{let n=new URL(this._src,window.location.href);await this._dotLottieLoader.loadFromUrl(n.toString())}else if(typeof this._src=="object"&&$l(this._src))this._dotLottieLoader.loadFromLottieJSON(this._src);else throw se("Invalid src provided");if(!this._dotLottieLoader.manifest)throw se("No manifest found");let t=this._getActiveAnimationId();if(!t)throw se("No active animation found");await this._setCurrentAnimation(t),await this.render(e)}catch(t){this.setCurrentState("error"),t instanceof Error&&ai(`Error loading animation: ${t.message}`)}}setErrorState(e){this.setCurrentState("error"),ai(e)}_requireValidDirection(e){if(e!==-1&&e!==1)throw se("Direction can only be -1 (backwards) or 1 (forwards)")}_requireValidIntermission(e){if(e<0||!Number.isInteger(e))throw se("intermission must be a positive number")}_requireValidLoop(e){if(typeof e=="number"&&(!Number.isInteger(e)||e<0))throw se("loop must be a positive number or boolean")}_requireValidSpeed(e){if(typeof e!="number")throw se("speed must be a number")}_requireValidBackground(e){if(typeof e!="string")throw se("background must be a string")}_requireValidAutoplay(e){if(typeof e!="boolean")throw se("autoplay must be a boolean")}_requireValidPlaybackOptions(e){e.direction&&this._requireValidDirection(e.direction),e.intermission&&this._requireValidIntermission(e.intermission),e.loop&&this._requireValidLoop(e.loop),e.speed&&this._requireValidSpeed(e.speed)}};function VA(){var e=b.useRef(!0);return e.current?(e.current=!1,!0):e.current}var BA=function(e,t){var n=VA();b.useEffect(function(){if(!n)return e()},t)},Ft=BA,UA=function(){};function Pw(e){for(var t=[],n=1;n{let e=b.useContext(Mw);if(typeof e>"u")throw se("useDotLottieContext must be used within a DotLottieProvider");return e},Tw=(e,t,n)=>{let[r,i]=b.useState(()=>n());return b.useEffect(()=>{let o=e(()=>{let a=t();i(a)});return()=>{o()}},[e]),r};function Or(e){let t=Lw(),n=b.useCallback(()=>e(t.getState()),[e,t]),r=b.useCallback(i=>t.state.subscribe(i),[t]);return Tw(r,n,()=>e(fh))}var t7=e=>O.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:[O.jsx("path",{d:"M8.33325 11.6667C7.78097 11.6667 7.33325 12.1144 7.33325 12.6667C7.33325 13.2189 7.78097 13.6667 8.33325 13.6667C8.88554 13.6667 9.33325 13.2189 9.33325 12.6667C9.33325 12.1144 8.88554 11.6667 8.33325 11.6667Z",fill:"currentColor"}),O.jsx("path",{d:"M7.33325 8C7.33325 7.44771 7.78097 7 8.33325 7C8.88554 7 9.33325 7.44771 9.33325 8C9.33325 8.55228 8.88554 9 8.33325 9C7.78097 9 7.33325 8.55228 7.33325 8Z",fill:"currentColor"}),O.jsx("path",{d:"M7.33325 3.33333C7.33325 2.78105 7.78097 2.33333 8.33325 2.33333C8.88554 2.33333 9.33325 2.78105 9.33325 3.33333C9.33325 3.88562 8.88554 4.33333 8.33325 4.33333C7.78097 4.33333 7.33325 3.88562 7.33325 3.33333Z",fill:"currentColor"})]}),n7=e=>O.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:[O.jsx("path",{d:"M10.8654 2.31311C11.0607 2.11785 11.3772 2.11785 11.5725 2.31311L13.4581 4.19873C13.6534 4.39399 13.6534 4.71058 13.4581 4.90584L11.5725 6.79146C11.3772 6.98672 11.0607 6.98672 10.8654 6.79146C10.6701 6.5962 10.6701 6.27961 10.8654 6.08435L11.6162 5.33354H4V6.66687C4 7.03506 3.70152 7.33354 3.33333 7.33354C2.96514 7.33354 2.66666 7.03506 2.66666 6.66687L2.66666 4.66687C2.66666 4.29868 2.96514 4.0002 3.33333 4.0002H11.8454L10.8654 3.02022C10.6701 2.82496 10.6701 2.50838 10.8654 2.31311Z",fill:"currentColor"}),O.jsx("path",{d:"M12.4375 11.9998C12.8057 11.9998 13.1042 11.7013 13.1042 11.3331V9.33313C13.1042 8.96494 12.8057 8.66647 12.4375 8.66647C12.0693 8.66647 11.7708 8.96494 11.7708 9.33313V10.6665H4.15462L4.90543 9.91565C5.10069 9.72039 5.10069 9.40381 4.90543 9.20854C4.71017 9.01328 4.39359 9.01328 4.19832 9.20854L2.31271 11.0942C2.11744 11.2894 2.11744 11.606 2.31271 11.8013L4.19832 13.6869C4.39359 13.8821 4.71017 13.8821 4.90543 13.6869C5.10069 13.4916 5.10069 13.175 4.90543 12.9798L3.92545 11.9998H12.4375Z",fill:"currentColor"})]}),r7=e=>O.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M14.3336 2.5C14.3336 2.22386 14.1097 2 13.8336 2C13.5574 2 13.3336 2.22386 13.3336 2.5V13.5C13.3336 13.7761 13.5574 14 13.8336 14C14.1097 14 14.3336 13.7761 14.3336 13.5V2.5ZM3.50618 2.21722C2.83954 1.82595 2 2.30667 2 3.07965V12.9201C2 13.6931 2.83954 14.1738 3.50618 13.7825L11.8893 8.86231C12.5477 8.47586 12.5477 7.52389 11.8893 7.13745L3.50618 2.21722Z",fill:"currentColor"})}),i7=e=>O.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:[O.jsx("path",{d:"M3.99996 2C3.26358 2 2.66663 2.59695 2.66663 3.33333V12.6667C2.66663 13.403 3.26358 14 3.99996 14H5.33329C6.06967 14 6.66663 13.403 6.66663 12.6667V3.33333C6.66663 2.59695 6.06967 2 5.33329 2H3.99996Z",fill:"currentColor"}),O.jsx("path",{d:"M10.6666 2C9.93025 2 9.33329 2.59695 9.33329 3.33333V12.6667C9.33329 13.403 9.93025 14 10.6666 14H12C12.7363 14 13.3333 13.403 13.3333 12.6667V3.33333C13.3333 2.59695 12.7363 2 12 2H10.6666Z",fill:"currentColor"})]}),o7=e=>O.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{d:"M3.33337 3.46787C3.33337 2.52312 4.35948 1.93558 5.17426 2.41379L12.8961 6.94592C13.7009 7.41824 13.7009 8.58176 12.8961 9.05408L5.17426 13.5862C4.35948 14.0644 3.33337 13.4769 3.33337 12.5321V3.46787Z",fill:"currentColor"})}),a7=e=>O.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M1.69214 13.5C1.69214 13.7761 1.916 14 2.19214 14C2.46828 14 2.69214 13.7761 2.69214 13.5L2.69214 2.5C2.69214 2.22386 2.46828 2 2.19214 2C1.916 2 1.69214 2.22386 1.69214 2.5V13.5ZM12.5192 13.7828C13.1859 14.174 14.0254 13.6933 14.0254 12.9204L14.0254 3.0799C14.0254 2.30692 13.1859 1.8262 12.5192 2.21747L4.13612 7.13769C3.47769 7.52414 3.47769 8.4761 4.13612 8.86255L12.5192 13.7828Z",fill:"currentColor"})}),s7=e=>O.jsx("svg",{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M13.5303 6.46967C13.8232 6.76256 13.8232 7.23744 13.5303 7.53033L9.06066 12L13.5303 16.4697C13.8232 16.7626 13.8232 17.2374 13.5303 17.5303C13.2374 17.8232 12.7626 17.8232 12.4697 17.5303L7.46967 12.5303C7.17678 12.2374 7.17678 11.7626 7.46967 11.4697L12.4697 6.46967C12.7626 6.17678 13.2374 6.17678 13.5303 6.46967Z",fill:"currentColor"})}),l7=e=>O.jsx("svg",{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M10.4697 17.5303C10.1768 17.2374 10.1768 16.7626 10.4697 16.4697L14.9393 12L10.4697 7.53033C10.1768 7.23744 10.1768 6.76256 10.4697 6.46967C10.7626 6.17678 11.2374 6.17678 11.5303 6.46967L16.5303 11.4697C16.8232 11.7626 16.8232 12.2374 16.5303 12.5303L11.5303 17.5303C11.2374 17.8232 10.7626 17.8232 10.4697 17.5303Z",fill:"currentColor"})}),u7=({children:e,enableReset:t,expand:n=!1,onBack:r,onExpand:i,onReset:o,title:a})=>{let s=b.useCallback(()=>{r()},[r]),l=b.useCallback(()=>{i()},[i]),u=b.useCallback(()=>{o()},[o]);return O.jsxs(O.Fragment,{children:[!n&&O.jsxs("button",{className:"popover-item","aria-label":`Go to ${a}`,onClick:l,children:[O.jsx("span",{style:{flex:1},children:a}),O.jsx("span",{children:O.jsx(l7,{})})]}),n&&O.jsxs("div",{className:"popover-submenu",children:[O.jsxs("div",{className:"popover-header",children:[O.jsx("button",{onClick:s,children:O.jsx(s7,{})}),O.jsxs("div",{className:"popover-header-title",style:{flex:1},children:[O.jsx("span",{children:a}),t&&O.jsx("button",{className:"reset-theme",onClick:u,"aria-label":`Reset ${a}`,children:"Reset"})]})]}),e]})]})},c7=e=>O.jsx("svg",{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M20.5283 5.9372C20.8211 6.23009 20.8211 6.70497 20.5283 6.99786L9.4631 18.063C9.32181 18.2043 9.12997 18.2833 8.93016 18.2826C8.73035 18.2819 8.53907 18.2015 8.39877 18.0593L3.46807 13.0596C3.17722 12.7647 3.18052 12.2898 3.47544 11.999C3.77036 11.7081 4.24522 11.7114 4.53608 12.0063L8.93646 16.4683L19.4676 5.9372C19.7605 5.64431 20.2354 5.64431 20.5283 5.9372Z",fill:"currentColor"})}),f7=({onSelectItem:e,selected:t=!1,value:n,...r})=>{let i=b.useCallback(()=>{e==null||e(n)},[e,n]);return O.jsxs("button",{"aria-label":`Select ${n}`,className:`popover-item ${t?"selected":""}`,onClick:i,...r,children:[O.jsx("span",{style:{visibility:t?"visible":"hidden"},children:O.jsx(c7,{})}),O.jsx("span",{style:{flex:1},children:n})]})},d7=({items:e=[],onSelectItem:t,onDismiss:n,...r})=>{let[i,o]=b.useState(""),a=b.useRef(null);KA(a,()=>{o(""),n()}),XA("Escape",()=>{o(""),n()});let s=b.useCallback(()=>{o("")},[o]),l=b.useCallback(c=>()=>o(c),[o]),u=b.useCallback((c,f)=>()=>t(c,f),[t]);return O.jsx("dialog",{ref:a,style:{padding:i?"0px":"8px"},className:"popover","aria-label":"Popover Menu",...r,children:O.jsx("ul",{"aria-label":"Popover content",className:"popover-content",children:e.map(c=>O.jsx("li",{style:{width:"100%"},children:(i===c.title||!i)&&O.jsx(u7,{expand:i===c.title,title:c.title,onExpand:l(c.title),onBack:s,enableReset:c.enableReset,onReset:u(c.title,""),children:O.jsx("ul",{className:"popover-items","aria-label":`List of ${c.title}`,children:c.items.map(f=>O.jsx("li",{children:O.jsx(f7,{value:f.value,selected:f.selected,onSelectItem:u(c.title,f.value)})},f.value))})})},c.title))})})},p7=["play","stop","loop","next","previous","animations","themes"],h7=({buttons:e=p7,...t})=>{let n=Lw(),r=Or(M=>M.loop),i=Or(M=>M.currentState),o=Or(M=>M.seeker),a=Or(M=>M.currentAnimationId),s=Or(M=>M.defaultTheme),l=Or(M=>M.direction),u=Or(M=>M.activeStateId),c=b.useMemo(()=>i===Dn.Playing,[i]),[f,d]=b.useState(!1),[h,y]=b.useState([]),[m,w]=b.useState([]),[p,v]=b.useState([]),g=b.useMemo(()=>{let M=[],D=h.map(F=>({value:F.id,selected:a===F.id})),A=m.filter(F=>F.animations.includes(a||"")).map(F=>({value:F.id,selected:s===F.id})),I=p.map(F=>({value:F,selected:u===F}));return Array.isArray(D)&&D.length!==0&&M.push({title:"Animations",items:D,enableReset:!1}),Array.isArray(I)&&I.length!==0&&M.push({title:"States",items:I,enableReset:!0}),Array.isArray(A)&&A.length!==0&&M.push({title:"Themes",items:A,enableReset:!!s}),M},[h,m,a,s,p,u]),S=b.useMemo(()=>e.includes("themes")&&Array.isArray(m)&&m.length?!0:e.includes("animations")&&Array.isArray(h)&&h.length>1,[g]),_=b.useCallback(()=>{d(!f)},[d]),x=b.useCallback(()=>{d(!1)},[d]),E=b.useCallback(()=>{n.toggleLoop()},[n]),C=b.useCallback(()=>{n.freeze()},[n]),k=b.useCallback(()=>{n.unfreeze()},[n]),P=b.useCallback(()=>{n.next()},[n]),$=b.useCallback(()=>{n.previous()},[n]),j=b.useCallback(()=>{n.togglePlay()},[n]),U=b.useCallback((M,D)=>{M==="Animations"&&n.play(D),M==="Themes"&&n.setDefaultTheme(D),M==="States"&&(D?n.enterInteractiveMode(D):n.exitInteractiveMode())},[n]),z=b.useCallback(M=>{n.seek(String(M.currentTarget.value).concat("%"))},[n]);function L(){var I,F,R;let M=(I=n.getManifest())==null?void 0:I.animations,D=(F=n.getManifest())==null?void 0:F.themes,A=(R=n.getManifest())==null?void 0:R.states;M&&y(M),D&&w(D),A&&v(A)}return b.useEffect(()=>{if(!(typeof n>"u"))return n.addEventListener("DOMLoaded",L),()=>{n.removeEventListener("DOMLoaded",L)}},[n]),O.jsxs("div",{"aria-label":"lottie-animation-controls",className:"toolbar",...t,children:[e.includes("previous")&&h.length>1&&O.jsx("button",{onClick:$,"aria-label":"play-previous",children:O.jsx(a7,{})}),e.includes("play")&&O.jsx("button",{onClick:j,"aria-label":"play-pause",children:c?O.jsx(i7,{}):O.jsx(o7,{})}),e.includes("next")&&h.length>1&&O.jsx("button",{onClick:P,"aria-label":"play-next",children:O.jsx(r7,{})}),O.jsx("input",{style:{width:"100%","--seeker":o},className:`seeker ${l===1?"":"to-left"}`,type:"range",min:0,step:0,max:100,value:o||0,onInput:z,onMouseDown:C,onMouseUp:k,"aria-valuemin":1,"aria-valuemax":100,role:"slider","aria-valuenow":o,"aria-label":"lottie-seek-input"}),e.includes("loop")&&O.jsx("button",{onClick:E,className:r?"active":"","aria-label":"loop-toggle",children:O.jsx(n7,{})}),S&&O.jsxs("div",{style:{position:"relative"},children:[O.jsx(d7,{items:g,open:f,onDismiss:x,onSelectItem:U}),O.jsx("button",{className:`${f?"popover-active":""}`,"aria-label":"open-popover",onClick:_,children:O.jsx(t7,{})})]})]})},m7={name:"@dotlottie/react-player",version:"1.5.0",type:"module",description:"dotlottie animation player react component.",repository:"https://github.com/dotlottie/player-component.git",homepage:"https://dotlottie.com/players",bugs:"https://github.com/dotlottie/player-component/issues",author:"Afsal ",license:"MIT",module:"dist/index.js",types:"dist/index.d.ts",files:["dist"],keywords:["dotlottie","animation","react","component","player"],scripts:{build:"tsup","cypress:open":"cypress open --component",dev:"tsup --watch",lint:"eslint .",test:"cypress run --component","type-check":"tsc --noEmit"},peerDependencies:{react:"^16.8.0 || ^17.0.0 || ^18.0.0"},devDependencies:{"@dotlottie/common":"workspace:^","@lottiefiles/lottie-types":"^1.2.0","@types/react":"^16.8.0","@types/react-dom":"^16.8.0","@vitejs/plugin-react":"^3.1.0",autoprefixer:"^10.4.14","axe-core":"^4.7.2",cypress:"^12.11.0","cypress-axe":"^1.4.0",postcss:"^8.4.24",react:"^16.8.0","react-dom":"^16.8.0","react-use":"^17.4.0",tsup:"^6.1.3",typescript:"^4.7.4",vite:"^4.2.1"}},v7=e=>{let t=b.useRef(!1);b.useEffect(()=>{let n;return t.current||(t.current=!0,n=e()),()=>{typeof n=="function"&&n()}},[])},g7=(e,t,n)=>{let[r,i]=b.useState(()=>new Fs(e,t.current,n)),o=b.useCallback(()=>{let s=new Fs(e,t.current,n);return s.load(),s},[t,e,n]),a=b.useCallback(()=>{r.destroy(),i(o())},[o,r]);return n!=null&&n.lottieRef&&b.useImperativeHandle(n.lottieRef,()=>({play:(s,l)=>{r.play(s,l)},previous:s=>{r.previous(s)},next:s=>{r.next(s)},reset:()=>{r.reset()},getManifest:()=>r.getManifest(),getState:()=>r.getState(),getCurrentAnimationId:()=>r.currentAnimationId,getLottie:()=>r.getAnimationInstance(),getVersions:()=>({lottieWebVersion:Fs.getLottieWebVersion(),dotLottieReactVersion:`${m7.version}`}),setDefaultTheme:s=>{r.setDefaultTheme(s)},setBackground:s=>{r.setBackground(s)},setAutoplay:s=>{r.setAutoplay(s)},setDirection:s=>{r.setDirection(s)},setHover:s=>{r.setHover(s)},setIntermission:s=>{r.setIntermission(s)},setLoop:s=>{r.setLoop(s)},setPlayMode:s=>{r.setMode(s)},setSpeed:s=>{r.setSpeed(s)},revertToManifestValues:s=>{r.revertToManifestValues(s)},pause:()=>{r.pause()},seek:s=>{r.seek(s)},getContainer:()=>r.container,goToAndPlay:(s,l,u)=>{r.goToAndPlay(s,l,u)},goToAndStop:(s,l,u)=>{r.goToAndStop(s,l,u)},stop:()=>{r.stop()},togglePlay:()=>{r.togglePlay()},resize:()=>{r.resize()},enterInteractiveMode:s=>{r.enterInteractiveMode(s)},playOnShow:s=>{r.playOnShow(s)},stopPlayOnShow:()=>{r.stopPlayOnShow()},playOnScroll:s=>{r.playOnScroll(s)},stopPlayOnScroll:()=>{r.stopPlayOnScroll()},exitInteractiveMode:()=>{r.exitInteractiveMode()}}),[n.lottieRef.current,r]),v7(()=>(a(),()=>{r.destroy()})),{dotLottiePlayer:r,initDotLottiePlayer:a}};function ps(e,t){let n=b.useCallback(()=>t(e.getState()),[t,e]),r=b.useCallback(i=>e.state.subscribe(i),[e]);return Tw(r,n,()=>t(fh))}var y7=({onEvent:e,activeAnimationId:t,autoplay:n,background:r="transparent",direction:i,intermission:o,loop:a,playMode:s,hover:l,speed:u,renderer:c="svg",rendererSettings:f={},lottieRef:d,src:h,className:y="",testId:m,children:w,defaultTheme:p,light:v=!1,worker:g=!1,activeStateId:S,..._})=>{let x=b.useRef(null),{dotLottiePlayer:E,initDotLottiePlayer:C}=g7(h,x,{lottieRef:d,renderer:c,activeAnimationId:t,rendererSettings:{clearCanvas:!0,progressiveLoad:!1,hideOnTransparent:!0,...f},hover:l,loop:a,direction:i,speed:u,intermission:o,background:r,playMode:s,autoplay:l?!1:n,testId:m,defaultTheme:p,light:v,worker:g,activeStateId:S}),k=ps(E,U=>U.currentState),P=ps(E,U=>U.frame),$=ps(E,U=>U.seeker),j=ps(E,U=>U.currentAnimationId);return Ft(()=>{typeof a>"u"?E.revertToManifestValues(["loop"]):E.setLoop(a)},[a]),Ft(()=>{typeof n>"u"?E.revertToManifestValues(["autoplay"]):E.setAutoplay(n)},[n]),Ft(()=>{typeof i>"u"?E.revertToManifestValues(["direction"]):E.setDirection(i)},[i]),Ft(()=>{typeof u>"u"?E.revertToManifestValues(["speed"]):E.setSpeed(u)},[u]),Ft(()=>{typeof s>"u"?E.revertToManifestValues(["playMode"]):E.setMode(s)},[s]),Ft(()=>{typeof l>"u"?E.revertToManifestValues(["hover"]):E.setHover(l)},[l]),Ft(()=>{typeof r>"u"?E.setBackground("transparent"):E.setBackground(r)},[r]),Ft(()=>{typeof o>"u"?E.revertToManifestValues(["intermission"]):E.setIntermission(o)},[o]),Ft(()=>{typeof p>"u"||!p?E.revertToManifestValues(["defaultTheme"]):E.setDefaultTheme(p)},[p]),Ft(()=>{t&&E.play(t)},[t]),Ft(()=>(typeof S<"u"&&E.enterInteractiveMode(S),()=>{E.exitInteractiveMode()}),[S]),Ft(()=>{typeof h<"u"&&C()},[h]),b.useEffect(()=>{E.addEventListener("DOMLoaded",()=>{e==null||e(ht.Ready)}),E.addEventListener("data_ready",()=>{e==null||e(ht.DataReady)}),E.addEventListener("data_failed",()=>{e==null||e(ht.DataFail)}),E.addEventListener("complete",()=>{E.currentState!==Dn.Playing&&(e==null||e(ht.Complete))}),E.addEventListener("loopComplete",()=>{e==null||e(ht.LoopComplete)})},[E]),b.useEffect(()=>{switch(k){case Dn.Stopped:e==null||e(ht.Stop);break;case Dn.Paused:e==null||e(ht.Pause);break;case Dn.Playing:e==null||e(ht.Play);break;case Dn.Frozen:e==null||e(ht.Freeze);break;case Dn.Error:e==null||e(ht.Error);break}},[k]),b.useEffect(()=>{e==null||e(ht.Frame,{frame:P,seeker:$})},[P]),O.jsx(e7,{value:E,children:O.jsxs("div",{className:`dotlottie-container main ${w?"controls":""} ${y}`,lang:"en",...m&&{"data-testid":m},..._,children:[O.jsx("div",{ref:x,"data-name":`${j}`,role:"figure",className:`animation ${w?"controls":""}`,style:{position:"relative"},...m&&{"data-testid":"animation"},children:k===Dn.Error&&O.jsx("div",{...m&&{"data-testid":"error"},className:"error",children:"⚠️"})}),w]})})};const w7=({activeAnimationId:e})=>{const t=b.useRef(),n=Fe(d=>d.playground.playerUrl),[r,i]=b.useState([]),[o,a]=b.useState(""),[s,l]=b.useState(0),u=b.useCallback((d,h)=>{var m,w,p;if(d===ht.Ready){const v=(w=(m=t.current)==null?void 0:m.getManifest())==null?void 0:w.states;i(v||[])}if(d===ht.Frame){const{frame:v}=h;l(Math.floor(v))}const y=(p=t.current)==null?void 0:p.getState();y&&a(y.activeStateId||"")},[t]),c=b.useCallback(()=>()=>{t.current&&t.current.exitInteractiveMode()},[t]),f=b.useCallback(d=>()=>{t.current&&t.current.enterInteractiveMode(d)},[t]);if(n)return O.jsx("div",{children:O.jsxs(O.Fragment,{children:[O.jsx(y7,{activeAnimationId:e||void 0,background:"white",onEvent:u,lottieRef:t,src:n,children:O.jsxs("div",{className:"bg-white",children:[O.jsx(h7,{}),O.jsx("div",{className:"px-3 pb-1",children:O.jsxs("span",{className:"bg-gray-300 rounded px-2",children:["# ",O.jsx("span",{children:s})]})})]})}),O.jsx("div",{className:"flex flex-wrap gap-2 p-2 text-white",children:O.jsxs("div",{className:"text-white",children:[O.jsxs("div",{className:"mb-2 flex gap-2",children:[O.jsx("span",{children:"Interactivity states:"}),O.jsx(Ol,{disabled:!o,color:"red",onClick:c(),children:"Exit Interactivity"})]}),O.jsx("div",{className:"flex flex-wrap gap-2",children:r.map(d=>O.jsx(Ol,{color:o===d?"green":"blue",onClick:f(d),children:d},d))})]})})]})})};const S7=({file:e,fileName:t})=>{const n=Au(),r=b.useRef(),i=Fe(T=>T.animations.list),o=Fe(T=>T.themes.list),a=Fe(T=>T.states.list),{addDotLottieAnimation:s,addDotLottieStateMachine:l,addDotLottieTheme:u,buildAndUpdateUrl:c,dotLottie:f,downloadDotLottie:d,fetchAndUpdateDotLottie:h,removeDotLottieAnimation:y,removeDotLottieState:m,removeDotLottieTheme:w,setDotLottie:p}=qp(),v=Fe(T=>{var N;return(N=T.editor.file)==null?void 0:N.content}),g=Fe(T=>{var N;return((N=T.editor.file)==null?void 0:N.type)||"json"}),S=Fe(T=>T.editor.animationId),_=Fe(T=>T.playground.workingFileName),x=b.useCallback(async(T,N)=>{let H,W="";if(T instanceof File?(H=await T.arrayBuffer(),W=T.name):(H=T,W=N||"new_awesome"),typeof H<"u")try{const X=await f.fromArrayBuffer(H);n(Ms()),n(os(W)),p(X)}catch(X){me(X.message,{type:"error"})}},[os,p]),E=b.useCallback(T=>{const N=T[0];typeof N>"u"||x(N)},[x]);b.useEffect(()=>{x(e,t)},[x]);const C=Fe(T=>T.editor.validationStatus),k=Fe(T=>{var N;return(N=T.editor.file)==null?void 0:N.name}),P=Fe(T=>{var N;return(N=T.editor.file)==null?void 0:N.path}),$=b.useCallback(T=>{C&&T&&n(Cl(T))},[C,n]),j=Fe(T=>T.editor.updated),U=b.useCallback(()=>{var H;if(!C||!k)return;const T=(H=r.current)==null?void 0:H.getValue();let N;if(T){switch(P){case"States":if(N=JSON.parse(T),T&&k){const W=N.descriptor.id;l(N,k),n(Ov({name:W}))}break;case"Themes":k&&u(T,k);break}n(Cl(!1))}},[C,k,n,P]);function z(T){r.current=T}b.useEffect(()=>{f.animations.length&&(h(),c())},[f,c,h]);const L=b.useCallback(async(T,N)=>{var X,oe;n(Ms());let H,W=!1;switch(T){case"States":H=(X=f.getStateMachine(N))==null?void 0:X.toString();break;case"Themes":H=await((oe=f.getTheme(N))==null?void 0:oe.toString()),W=!0;break}H&&n(Ov({name:N,type:W?"css":"json",path:T,content:W?H:s6(H)}))},[f,n]),M=b.useCallback(T=>{if(T.some(H=>H.severity===8)){n(kv(!1));return}n(kv(!0))},[n]),D=b.useCallback((T,N)=>{switch(T){case"States":m(N);break;case"Animations":y(N);break;case"Themes":w(N);break}(k===N||S===N)&&n(Ms())},[f,n,k,S]),A=b.useCallback(async(T,N)=>{const H=fd(N.name).replace(/(.json|.lss)/gu,"");let W;switch(T){case"States":W=JSON.parse(await N.text()),l(W);break;case"Animations":W=JSON.parse(await N.text()),s(W,H);break;case"Themes":W=await N.text(),u(W,N.name);break}},[f]),I=b.useCallback(()=>{h(),c()},[h,c]),F=b.useCallback(async(T,N)=>{const H=fd(N).replace(/(.json|.lss)/gu,"");let W;switch(T){case"States":W=l6(),W.descriptor.id=H,l(W);break;case"Themes":u("/* Make your animations colorful */",H);break}},[f]),R=b.useCallback((T,N)=>{n(f6(N.replace(/.json/gu,"")))},[n]),V=b.useCallback(T=>{n(os(T))},[os,n]);return O.jsxs("div",{className:"h-full flex flex-col",children:[O.jsxs("div",{className:"w-full bg-dark p-2 flex gap-2 justify-end",children:[O.jsx(ia,{onDrop:E,accept:"lottie",children:T=>O.jsxs(Ol,{...T.getRootProps(),children:[O.jsx("input",{...T.getInputProps()}),"Start Over"]})}),O.jsx("div",{className:"flex-1 flex justify-center items-center text-gray-400 text-sm",children:O.jsx(p6,{title:_,onChange:V})}),O.jsx(Ol,{onClick:d,children:"Download"})]}),O.jsx("div",{className:"flex grow border-t border-gray-600 flex-1 max-h-[calc(100vh-2.9rem)]",children:O.jsxs(Ly,{autoSaveId:"dotlottie-playground",direction:"horizontal",className:"h-full",children:[O.jsx(ks,{defaultSize:10,maxSize:40,className:"bg-dark",children:O.jsxs("section",{className:"flex flex-col h-full",children:[O.jsx(jc,{className:"flex-1 h-1/3",title:"Animations",files:i,onClick:R,onRemove:D,onUpload:A}),O.jsx(jc,{className:"flex-1 h-1/3",title:"States",files:a,onClick:L,onRemove:D,onUpload:A,onAddNew:F}),O.jsx(jc,{className:"flex-1 h-1/3",title:"Themes",files:o,onClick:L,onRemove:D,onUpload:A,onAddNew:F})]})}),O.jsx(Qf,{className:"bg-gray-500 w-1"}),O.jsx(ks,{children:O.jsx(ia,{onDrop:E,accept:"lottie",noClick:!0,children:T=>O.jsxs("div",{className:"flex flex-col w-full h-full relative",...T.getRootProps(),children:[O.jsx("input",{...T.getInputProps()}),T.isDragActive&&O.jsx("div",{className:"absolute z-10 inset-0 bg-gray-500 opacity-80 flex justify-center items-center text-white text-3xl",children:"Drop your .lottie here"}),S&&O.jsx(vk,{onUpdate:I}),v&&O.jsxs("div",{className:"h-full flex flex-col",children:[O.jsxs("div",{className:"flex justify-between items-stretch pr-4 flex-shrink border-b border-gray-600",children:[O.jsx("span",{className:"text-white text-sm border-b border-b-blue-500 border-r border-gray-600 px-4 flex items-center",children:k}),O.jsx("button",{title:"Save",className:"text-gray-400 py-1 hover:text-white disabled:text-gray-700",onClick:U,disabled:!j,children:O.jsx(yy,{size:33})})]}),O.jsx(y4,{className:"flex-1 max-h-[calc(100vh-5.5rem)]",language:g,width:"100%",theme:"vs-dark",options:{fontSize:15,formatOnPaste:!0,formatOnType:!0,minimap:{enabled:!1}},loading:"Loading...",value:v,onChange:$,onMount:z,onValidate:M})]})]})})}),O.jsx(Qf,{className:"bg-gray-500 w-1"}),O.jsx(ks,{defaultSize:25,children:O.jsx(w7,{activeAnimationId:S})})]})})]})},b7=[{name:"toggle.lottie",path:"/player-component/toggle.lottie"},{name:"interactivity_example.lottie",path:"/player-component/interactivity_example.lottie"},{name:"aniki_hamster.lottie",path:"/player-component/aniki_hamster.lottie"}],E7=({onStart:e})=>{const t=b.useCallback(async(o,a)=>{let s,l="";o instanceof File?(s=await o.arrayBuffer(),l=o.name):(s=o,l=a||"new_awesome"),typeof s<"u"&&e(s,l)},[e]),n=b.useCallback(o=>{const a=o[0];a&&t(a)},[e]),r=b.useCallback(async(o,a)=>{const l=await(await fetch(o)).arrayBuffer();t(l,a)},[]),i=b.useCallback(o=>()=>{r(o.path,o.name)},[e]);return O.jsx(ia,{onDrop:n,accept:"lottie",noClick:!0,children:o=>O.jsxs("div",{...o.getRootProps(),className:"h-full bg-dark text-white flex justify-center items-center",children:[O.jsx("input",{...o.getInputProps()}),o.isDragActive?O.jsx("h1",{className:"text-5xl mb-4",children:"Drop it!!!! Almost there :)"}):O.jsxs("div",{className:"p-10 rounded text-gray-400 max-w-2xl",children:[O.jsx("h1",{className:"text-5xl mb-4",children:"DotLottie Playground :)"}),O.jsxs("p",{className:"text-2xl mb-6",children:["To start drop a ",O.jsx("span",{className:"text-red-600",children:".lottie"}),". You could also select a sample file below."]}),O.jsx("h2",{className:"text-lg mb-2",children:"Sample files"}),O.jsx("ul",{className:"text-sm",children:b7.map(a=>O.jsx("li",{children:O.jsxs("button",{className:"flex gap-2 items-center hover:text-white mb-1",onClick:i(a),children:[O.jsx(aE,{className:"fill-yellow-500"}),a.name]})},a.name))})]})]})})},_7=()=>{const[e,t]=b.useState({}),n=b.useCallback((r,i)=>{t({name:i,arrayBuffer:r})},[t]);return O.jsxs("div",{className:"h-screen bg-dark",children:[e.arrayBuffer?O.jsx(S7,{file:e.arrayBuffer,fileName:e.name||"unammed.lottie"}):O.jsx(E7,{onStart:n}),O.jsx(zf,{})]})},x7=jC({reducer:{animations:GC,themes:n6,states:XC,editor:d6,playground:YC}});qc.createRoot(document.getElementById("root")).render(O.jsx(ne.StrictMode,{children:O.jsx(eE,{store:x7,children:O.jsx(u6,{children:O.jsx(_7,{})})})}));export{jt as F,j7 as n,ai as t,se as v}; +`]))),qO=function(t,n){var r=t.isFocused,i=t.size,o=t.theme,a=o.colors,s=o.spacing.baseUnit;return Q({label:"loadingIndicator",display:"flex",transition:"color 150ms",alignSelf:"center",fontSize:i,lineHeight:1,marginRight:i,textAlign:"center",verticalAlign:"middle"},n?{}:{color:r?a.neutral60:a.neutral20,padding:s*2})},Rc=function(t){var n=t.delay,r=t.offset;return Y("span",{css:Yp({animation:"".concat(WO," 1s ease-in-out ").concat(n,"ms infinite;"),backgroundColor:"currentColor",borderRadius:"1em",display:"inline-block",marginLeft:r?"1em":void 0,height:"1em",verticalAlign:"top",width:"1em"},"","")})},KO=function(t){var n=t.innerProps,r=t.isRtl,i=t.size,o=i===void 0?4:i,a=Gn(t,FO);return Y("div",J({},De(Q(Q({},a),{},{innerProps:n,isRtl:r,size:o}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),n),Y(Rc,{delay:0,offset:r}),Y(Rc,{delay:160,offset:!0}),Y(Rc,{delay:320,offset:!r}))},GO=function(t,n){var r=t.isDisabled,i=t.isFocused,o=t.theme,a=o.colors,s=o.borderRadius,l=o.spacing;return Q({label:"control",alignItems:"center",cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:l.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms"},n?{}:{backgroundColor:r?a.neutral5:a.neutral0,borderColor:r?a.neutral10:i?a.primary:a.neutral20,borderRadius:s,borderStyle:"solid",borderWidth:1,boxShadow:i?"0 0 0 1px ".concat(a.primary):void 0,"&:hover":{borderColor:i?a.primary:a.neutral30}})},QO=function(t){var n=t.children,r=t.isDisabled,i=t.isFocused,o=t.innerRef,a=t.innerProps,s=t.menuIsOpen;return Y("div",J({ref:o},De(t,"control",{control:!0,"control--is-disabled":r,"control--is-focused":i,"control--menu-is-open":s}),a),n)},YO=QO,JO=["data"],ZO=function(t,n){var r=t.theme.spacing;return n?{}:{paddingBottom:r.baseUnit*2,paddingTop:r.baseUnit*2}},XO=function(t){var n=t.children,r=t.cx,i=t.getStyles,o=t.getClassNames,a=t.Heading,s=t.headingProps,l=t.innerProps,u=t.label,c=t.theme,f=t.selectProps;return Y("div",J({},De(t,"group",{group:!0}),l),Y(a,J({},s,{selectProps:f,theme:c,getStyles:i,getClassNames:o,cx:r}),u),Y("div",null,n))},e8=function(t,n){var r=t.theme,i=r.colors,o=r.spacing;return Q({label:"group",cursor:"default",display:"block"},n?{}:{color:i.neutral40,fontSize:"75%",fontWeight:500,marginBottom:"0.25em",paddingLeft:o.baseUnit*3,paddingRight:o.baseUnit*3,textTransform:"uppercase"})},t8=function(t){var n=F2(t);n.data;var r=Gn(n,JO);return Y("div",J({},De(t,"groupHeading",{"group-heading":!0}),r))},n8=XO,r8=["innerRef","isDisabled","isHidden","inputClassName"],i8=function(t,n){var r=t.isDisabled,i=t.value,o=t.theme,a=o.spacing,s=o.colors;return Q(Q({visibility:r?"hidden":"visible",transform:i?"translateZ(0)":""},o8),n?{}:{margin:a.baseUnit/2,paddingBottom:a.baseUnit/2,paddingTop:a.baseUnit/2,color:s.neutral80})},q2={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},o8={flex:"1 1 auto",display:"inline-grid",gridArea:"1 / 1 / 2 / 3",gridTemplateColumns:"0 min-content","&:after":Q({content:'attr(data-value) " "',visibility:"hidden",whiteSpace:"pre"},q2)},a8=function(t){return Q({label:"input",color:"inherit",background:0,opacity:t?0:1,width:"100%"},q2)},s8=function(t){var n=t.cx,r=t.value,i=F2(t),o=i.innerRef,a=i.isDisabled,s=i.isHidden,l=i.inputClassName,u=Gn(i,r8);return Y("div",J({},De(t,"input",{"input-container":!0}),{"data-value":r||""}),Y("input",J({className:n({input:!0},l),ref:o,style:a8(s),disabled:a},u)))},l8=s8,u8=function(t,n){var r=t.theme,i=r.spacing,o=r.borderRadius,a=r.colors;return Q({label:"multiValue",display:"flex",minWidth:0},n?{}:{backgroundColor:a.neutral10,borderRadius:o/2,margin:i.baseUnit/2})},c8=function(t,n){var r=t.theme,i=r.borderRadius,o=r.colors,a=t.cropWithEllipsis;return Q({overflow:"hidden",textOverflow:a||a===void 0?"ellipsis":void 0,whiteSpace:"nowrap"},n?{}:{borderRadius:i/2,color:o.neutral80,fontSize:"85%",padding:3,paddingLeft:6})},f8=function(t,n){var r=t.theme,i=r.spacing,o=r.borderRadius,a=r.colors,s=t.isFocused;return Q({alignItems:"center",display:"flex"},n?{}:{borderRadius:o/2,backgroundColor:s?a.dangerLight:void 0,paddingLeft:i.baseUnit,paddingRight:i.baseUnit,":hover":{backgroundColor:a.dangerLight,color:a.danger}})},K2=function(t){var n=t.children,r=t.innerProps;return Y("div",r,n)},d8=K2,p8=K2;function h8(e){var t=e.children,n=e.innerProps;return Y("div",J({role:"button"},n),t||Y(eh,{size:14}))}var m8=function(t){var n=t.children,r=t.components,i=t.data,o=t.innerProps,a=t.isDisabled,s=t.removeProps,l=t.selectProps,u=r.Container,c=r.Label,f=r.Remove;return Y(u,{data:i,innerProps:Q(Q({},De(t,"multiValue",{"multi-value":!0,"multi-value--is-disabled":a})),o),selectProps:l},Y(c,{data:i,innerProps:Q({},De(t,"multiValueLabel",{"multi-value__label":!0})),selectProps:l},n),Y(f,{data:i,innerProps:Q(Q({},De(t,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(n||"option")},s),selectProps:l}))},v8=m8,g8=function(t,n){var r=t.isDisabled,i=t.isFocused,o=t.isSelected,a=t.theme,s=a.spacing,l=a.colors;return Q({label:"option",cursor:"default",display:"block",fontSize:"inherit",width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)"},n?{}:{backgroundColor:o?l.primary:i?l.primary25:"transparent",color:r?l.neutral20:o?l.neutral0:"inherit",padding:"".concat(s.baseUnit*2,"px ").concat(s.baseUnit*3,"px"),":active":{backgroundColor:r?void 0:o?l.primary:l.primary50}})},y8=function(t){var n=t.children,r=t.isDisabled,i=t.isFocused,o=t.isSelected,a=t.innerRef,s=t.innerProps;return Y("div",J({},De(t,"option",{option:!0,"option--is-disabled":r,"option--is-focused":i,"option--is-selected":o}),{ref:a,"aria-disabled":r},s),n)},w8=y8,S8=function(t,n){var r=t.theme,i=r.spacing,o=r.colors;return Q({label:"placeholder",gridArea:"1 / 1 / 2 / 3"},n?{}:{color:o.neutral50,marginLeft:i.baseUnit/2,marginRight:i.baseUnit/2})},b8=function(t){var n=t.children,r=t.innerProps;return Y("div",J({},De(t,"placeholder",{placeholder:!0}),r),n)},E8=b8,_8=function(t,n){var r=t.isDisabled,i=t.theme,o=i.spacing,a=i.colors;return Q({label:"singleValue",gridArea:"1 / 1 / 2 / 3",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},n?{}:{color:r?a.neutral40:a.neutral80,marginLeft:o.baseUnit/2,marginRight:o.baseUnit/2})},x8=function(t){var n=t.children,r=t.isDisabled,i=t.innerProps;return Y("div",J({},De(t,"singleValue",{"single-value":!0,"single-value--is-disabled":r}),i),n)},C8=x8,O8={ClearIndicator:BO,Control:YO,DropdownIndicator:zO,DownChevron:H2,CrossIcon:eh,Group:n8,GroupHeading:t8,IndicatorsContainer:$O,IndicatorSeparator:HO,Input:l8,LoadingIndicator:KO,Menu:bO,MenuList:_O,MenuPortal:PO,LoadingMessage:kO,NoOptionsMessage:OO,MultiValue:v8,MultiValueContainer:d8,MultiValueLabel:p8,MultiValueRemove:h8,Option:w8,Placeholder:E8,SelectContainer:MO,SingleValue:C8,ValueContainer:TO},k8=function(t){return Q(Q({},O8),t.components)},Hv=Number.isNaN||function(t){return typeof t=="number"&&t!==t};function A8(e,t){return!!(e===t||Hv(e)&&Hv(t))}function P8(e,t){if(e.length!==t.length)return!1;for(var n=0;n1?"s":""," ").concat(o.join(","),", selected.");case"select-option":return a?"option ".concat(i," is disabled. Select another option."):"option ".concat(i,", selected.");default:return""}},onFocus:function(t){var n=t.context,r=t.focused,i=t.options,o=t.label,a=o===void 0?"":o,s=t.selectValue,l=t.isDisabled,u=t.isSelected,c=function(y,m){return y&&y.length?"".concat(y.indexOf(m)+1," of ").concat(y.length):""};if(n==="value"&&s)return"value ".concat(a," focused, ").concat(c(s,r),".");if(n==="menu"){var f=l?" disabled":"",d="".concat(u?"selected":"focused").concat(f);return"option ".concat(a," ").concat(d,", ").concat(c(i,r),".")}return""},onFilter:function(t){var n=t.inputValue,r=t.resultsMessage;return"".concat(r).concat(n?" for search term "+n:"",".")}},D8=function(t){var n=t.ariaSelection,r=t.focusedOption,i=t.focusedValue,o=t.focusableOptions,a=t.isFocused,s=t.selectValue,l=t.selectProps,u=t.id,c=l.ariaLiveMessages,f=l.getOptionLabel,d=l.inputValue,h=l.isMulti,y=l.isOptionDisabled,m=l.isSearchable,w=l.menuIsOpen,p=l.options,v=l.screenReaderStatus,g=l.tabSelectsValue,S=l["aria-label"],E=l["aria-live"],x=b.useMemo(function(){return Q(Q({},T8),c||{})},[c]),_=b.useMemo(function(){var j="";if(n&&x.onChange){var L=n.option,M=n.options,D=n.removedValue,A=n.removedValues,I=n.value,R=function(X){return Array.isArray(X)?null:X},N=D||L||R(I),V=N?f(N):"",T=M||A||void 0,z=T?T.map(f):[],U=Q({isDisabled:N&&y(N,s),label:V,labels:z},n);j=x.onChange(U)}return j},[n,x,y,s,f]),C=b.useMemo(function(){var j="",L=r||i,M=!!(r&&s&&s.includes(r));if(L&&x.onFocus){var D={focused:L,label:f(L),isDisabled:y(L,s),isSelected:M,options:o,context:L===r?"menu":"value",selectValue:s};j=x.onFocus(D)}return j},[r,i,f,y,x,o,s]),k=b.useMemo(function(){var j="";if(w&&p.length&&x.onFilter){var L=v({count:o.length});j=x.onFilter({inputValue:d,resultsMessage:L})}return j},[o,d,w,x,p,v]),P=b.useMemo(function(){var j="";if(x.guidance){var L=i?"value":w?"menu":"input";j=x.guidance({"aria-label":S,context:L,isDisabled:r&&y(r,s),isMulti:h,isSearchable:m,tabSelectsValue:g})}return j},[S,r,i,h,y,m,w,x,s,g]),$="".concat(C," ").concat(k," ").concat(P),F=Y(b.Fragment,null,Y("span",{id:"aria-selection"},_),Y("span",{id:"aria-context"},$)),H=(n==null?void 0:n.action)==="initial-input-focus";return Y(b.Fragment,null,Y(Wv,{id:u},H&&F),Y(Wv,{"aria-live":E,"aria-atomic":"false","aria-relevant":"additions text"},a&&!H&&F))},$8=D8,wd=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],j8=new RegExp("["+wd.map(function(e){return e.letters}).join("")+"]","g"),G2={};for(var Nc=0;Nc-1}},z8=["innerRef"];function V8(e){var t=e.innerRef,n=Gn(e,z8),r=pO(n,"onExited","in","enter","exit","appear");return Y("input",J({ref:t},r,{css:Yp({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var B8=function(t){t.preventDefault(),t.stopPropagation()};function U8(e){var t=e.isEnabled,n=e.onBottomArrive,r=e.onBottomLeave,i=e.onTopArrive,o=e.onTopLeave,a=b.useRef(!1),s=b.useRef(!1),l=b.useRef(0),u=b.useRef(null),c=b.useCallback(function(w,p){if(u.current!==null){var v=u.current,g=v.scrollTop,S=v.scrollHeight,E=v.clientHeight,x=u.current,_=p>0,C=S-E-g,k=!1;C>p&&a.current&&(r&&r(w),a.current=!1),_&&s.current&&(o&&o(w),s.current=!1),_&&p>C?(n&&!a.current&&n(w),x.scrollTop=S,k=!0,a.current=!0):!_&&-p>g&&(i&&!s.current&&i(w),x.scrollTop=0,k=!0,s.current=!0),k&&B8(w)}},[n,r,i,o]),f=b.useCallback(function(w){c(w,w.deltaY)},[c]),d=b.useCallback(function(w){l.current=w.changedTouches[0].clientY},[]),h=b.useCallback(function(w){var p=l.current-w.changedTouches[0].clientY;c(w,p)},[c]),y=b.useCallback(function(w){if(w){var p=cO?{passive:!1}:!1;w.addEventListener("wheel",f,p),w.addEventListener("touchstart",d,p),w.addEventListener("touchmove",h,p)}},[h,d,f]),m=b.useCallback(function(w){w&&(w.removeEventListener("wheel",f,!1),w.removeEventListener("touchstart",d,!1),w.removeEventListener("touchmove",h,!1))},[h,d,f]);return b.useEffect(function(){if(t){var w=u.current;return y(w),function(){m(w)}}},[t,y,m]),function(w){u.current=w}}var Kv=["boxSizing","height","overflow","paddingRight","position"],Gv={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function Qv(e){e.preventDefault()}function Yv(e){e.stopPropagation()}function Jv(){var e=this.scrollTop,t=this.scrollHeight,n=e+this.offsetHeight;e===0?this.scrollTop=1:n===t&&(this.scrollTop=e-1)}function Zv(){return"ontouchstart"in window||navigator.maxTouchPoints}var Xv=!!(typeof window<"u"&&window.document&&window.document.createElement),ho=0,oi={capture:!1,passive:!1};function H8(e){var t=e.isEnabled,n=e.accountForScrollbars,r=n===void 0?!0:n,i=b.useRef({}),o=b.useRef(null),a=b.useCallback(function(l){if(Xv){var u=document.body,c=u&&u.style;if(r&&Kv.forEach(function(y){var m=c&&c[y];i.current[y]=m}),r&&ho<1){var f=parseInt(i.current.paddingRight,10)||0,d=document.body?document.body.clientWidth:0,h=window.innerWidth-d+f||0;Object.keys(Gv).forEach(function(y){var m=Gv[y];c&&(c[y]=m)}),c&&(c.paddingRight="".concat(h,"px"))}u&&Zv()&&(u.addEventListener("touchmove",Qv,oi),l&&(l.addEventListener("touchstart",Jv,oi),l.addEventListener("touchmove",Yv,oi))),ho+=1}},[r]),s=b.useCallback(function(l){if(Xv){var u=document.body,c=u&&u.style;ho=Math.max(ho-1,0),r&&ho<1&&Kv.forEach(function(f){var d=i.current[f];c&&(c[f]=d)}),u&&Zv()&&(u.removeEventListener("touchmove",Qv,oi),l&&(l.removeEventListener("touchstart",Jv,oi),l.removeEventListener("touchmove",Yv,oi)))}},[r]);return b.useEffect(function(){if(t){var l=o.current;return a(l),function(){s(l)}}},[t,a,s]),function(l){o.current=l}}var W8=function(){return document.activeElement&&document.activeElement.blur()},q8={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function K8(e){var t=e.children,n=e.lockEnabled,r=e.captureEnabled,i=r===void 0?!0:r,o=e.onBottomArrive,a=e.onBottomLeave,s=e.onTopArrive,l=e.onTopLeave,u=U8({isEnabled:i,onBottomArrive:o,onBottomLeave:a,onTopArrive:s,onTopLeave:l}),c=H8({isEnabled:n}),f=function(h){u(h),c(h)};return Y(b.Fragment,null,n&&Y("div",{onClick:W8,css:q8}),t(f))}var G8={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},Q8=function(t){var n=t.name,r=t.onFocus;return Y("input",{required:!0,name:n,tabIndex:-1,"aria-hidden":"true",onFocus:r,css:G8,value:"",onChange:function(){}})},Y8=Q8,J8=function(t){return t.label},Z8=function(t){return t.label},X8=function(t){return t.value},ek=function(t){return!!t.isDisabled},tk={clearIndicator:VO,container:IO,control:GO,dropdownIndicator:NO,group:ZO,groupHeading:e8,indicatorsContainer:DO,indicatorSeparator:UO,input:i8,loadingIndicator:qO,loadingMessage:CO,menu:yO,menuList:EO,menuPortal:AO,multiValue:u8,multiValueLabel:c8,multiValueRemove:f8,noOptionsMessage:xO,option:g8,placeholder:S8,singleValue:_8,valueContainer:LO},nk={primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},rk=4,Y2=4,ik=38,ok=Y2*2,ak={baseUnit:Y2,controlHeight:ik,menuGutter:ok},Bc={borderRadius:rk,colors:nk,spacing:ak},sk={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:Bv(),captureMenuScroll:!Bv(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:N8(),formatGroupLabel:J8,getOptionLabel:Z8,getOptionValue:X8,isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:ek,loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!lO(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(t){var n=t.count;return"".concat(n," result").concat(n!==1?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function e0(e,t,n,r){var i=ew(e,t,n),o=tw(e,t,n),a=X2(e,t),s=Ll(e,t);return{type:"option",data:t,isDisabled:i,isSelected:o,label:a,value:s,index:r}}function J2(e,t){return e.options.map(function(n,r){if("options"in n){var i=n.options.map(function(a,s){return e0(e,a,t,s)}).filter(function(a){return t0(e,a)});return i.length>0?{type:"group",data:n,options:i,index:r}:void 0}var o=e0(e,n,t,r);return t0(e,o)?o:void 0}).filter(fO)}function Z2(e){return e.reduce(function(t,n){return n.type==="group"?t.push.apply(t,S2(n.options.map(function(r){return r.data}))):t.push(n.data),t},[])}function lk(e,t){return Z2(J2(e,t))}function t0(e,t){var n=e.inputValue,r=n===void 0?"":n,i=t.data,o=t.isSelected,a=t.label,s=t.value;return(!rw(e)||!o)&&nw(e,{label:a,value:s,data:i},r)}function uk(e,t){var n=e.focusedValue,r=e.selectValue,i=r.indexOf(n);if(i>-1){var o=t.indexOf(n);if(o>-1)return n;if(i-1?n:t[0]}var X2=function(t,n){return t.getOptionLabel(n)},Ll=function(t,n){return t.getOptionValue(n)};function ew(e,t,n){return typeof e.isOptionDisabled=="function"?e.isOptionDisabled(t,n):!1}function tw(e,t,n){if(n.indexOf(t)>-1)return!0;if(typeof e.isOptionSelected=="function")return e.isOptionSelected(t,n);var r=Ll(e,t);return n.some(function(i){return Ll(e,i)===r})}function nw(e,t,n){return e.filterOption?e.filterOption(t,n):!0}var rw=function(t){var n=t.hideSelectedOptions,r=t.isMulti;return n===void 0?r:n},fk=1,iw=function(e){z6(n,e);var t=H6(n);function n(r){var i;if(R6(this,n),i=t.call(this,r),i.state={ariaSelection:null,focusedOption:null,focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0},i.blockOptionHover=!1,i.isComposing=!1,i.commonProps=void 0,i.initialTouchX=0,i.initialTouchY=0,i.instancePrefix="",i.openAfterFocus=!1,i.scrollToFocusedOptionOnUpdate=!1,i.userIsDragging=void 0,i.controlRef=null,i.getControlRef=function(s){i.controlRef=s},i.focusedOptionRef=null,i.getFocusedOptionRef=function(s){i.focusedOptionRef=s},i.menuListRef=null,i.getMenuListRef=function(s){i.menuListRef=s},i.inputRef=null,i.getInputRef=function(s){i.inputRef=s},i.focus=i.focusInput,i.blur=i.blurInput,i.onChange=function(s,l){var u=i.props,c=u.onChange,f=u.name;l.name=f,i.ariaOnChange(s,l),c(s,l)},i.setValue=function(s,l,u){var c=i.props,f=c.closeMenuOnSelect,d=c.isMulti,h=c.inputValue;i.onInputChange("",{action:"set-value",prevInputValue:h}),f&&(i.setState({inputIsHiddenAfterUpdate:!d}),i.onMenuClose()),i.setState({clearFocusValueOnUpdate:!0}),i.onChange(s,{action:l,option:u})},i.selectOption=function(s){var l=i.props,u=l.blurInputOnSelect,c=l.isMulti,f=l.name,d=i.state.selectValue,h=c&&i.isOptionSelected(s,d),y=i.isOptionDisabled(s,d);if(h){var m=i.getOptionValue(s);i.setValue(d.filter(function(w){return i.getOptionValue(w)!==m}),"deselect-option",s)}else if(!y)c?i.setValue([].concat(S2(d),[s]),"select-option",s):i.setValue(s,"select-option");else{i.ariaOnChange(s,{action:"select-option",option:s,name:f});return}u&&i.blurInput()},i.removeValue=function(s){var l=i.props.isMulti,u=i.state.selectValue,c=i.getOptionValue(s),f=u.filter(function(h){return i.getOptionValue(h)!==c}),d=cs(l,f,f[0]||null);i.onChange(d,{action:"remove-value",removedValue:s}),i.focusInput()},i.clearValue=function(){var s=i.state.selectValue;i.onChange(cs(i.props.isMulti,[],null),{action:"clear",removedValues:s})},i.popValue=function(){var s=i.props.isMulti,l=i.state.selectValue,u=l[l.length-1],c=l.slice(0,l.length-1),f=cs(s,c,c[0]||null);i.onChange(f,{action:"pop-value",removedValue:u})},i.getValue=function(){return i.state.selectValue},i.cx=function(){for(var s=arguments.length,l=new Array(s),u=0;ud||f>d}},i.onTouchEnd=function(s){i.userIsDragging||(i.controlRef&&!i.controlRef.contains(s.target)&&i.menuListRef&&!i.menuListRef.contains(s.target)&&i.blurInput(),i.initialTouchX=0,i.initialTouchY=0)},i.onControlTouchEnd=function(s){i.userIsDragging||i.onControlMouseDown(s)},i.onClearIndicatorTouchEnd=function(s){i.userIsDragging||i.onClearIndicatorMouseDown(s)},i.onDropdownIndicatorTouchEnd=function(s){i.userIsDragging||i.onDropdownIndicatorMouseDown(s)},i.handleInputChange=function(s){var l=i.props.inputValue,u=s.currentTarget.value;i.setState({inputIsHiddenAfterUpdate:!1}),i.onInputChange(u,{action:"input-change",prevInputValue:l}),i.props.menuIsOpen||i.onMenuOpen()},i.onInputFocus=function(s){i.props.onFocus&&i.props.onFocus(s),i.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(i.openAfterFocus||i.props.openMenuOnFocus)&&i.openMenu("first"),i.openAfterFocus=!1},i.onInputBlur=function(s){var l=i.props.inputValue;if(i.menuListRef&&i.menuListRef.contains(document.activeElement)){i.inputRef.focus();return}i.props.onBlur&&i.props.onBlur(s),i.onInputChange("",{action:"input-blur",prevInputValue:l}),i.onMenuClose(),i.setState({focusedValue:null,isFocused:!1})},i.onOptionHover=function(s){i.blockOptionHover||i.state.focusedOption===s||i.setState({focusedOption:s})},i.shouldHideSelectedOptions=function(){return rw(i.props)},i.onValueInputFocus=function(s){s.preventDefault(),s.stopPropagation(),i.focus()},i.onKeyDown=function(s){var l=i.props,u=l.isMulti,c=l.backspaceRemovesValue,f=l.escapeClearsValue,d=l.inputValue,h=l.isClearable,y=l.isDisabled,m=l.menuIsOpen,w=l.onKeyDown,p=l.tabSelectsValue,v=l.openMenuOnFocus,g=i.state,S=g.focusedOption,E=g.focusedValue,x=g.selectValue;if(!y&&!(typeof w=="function"&&(w(s),s.defaultPrevented))){switch(i.blockOptionHover=!0,s.key){case"ArrowLeft":if(!u||d)return;i.focusValue("previous");break;case"ArrowRight":if(!u||d)return;i.focusValue("next");break;case"Delete":case"Backspace":if(d)return;if(E)i.removeValue(E);else{if(!c)return;u?i.popValue():h&&i.clearValue()}break;case"Tab":if(i.isComposing||s.shiftKey||!m||!p||!S||v&&i.isOptionSelected(S,x))return;i.selectOption(S);break;case"Enter":if(s.keyCode===229)break;if(m){if(!S||i.isComposing)return;i.selectOption(S);break}return;case"Escape":m?(i.setState({inputIsHiddenAfterUpdate:!1}),i.onInputChange("",{action:"menu-close",prevInputValue:d}),i.onMenuClose()):h&&f&&i.clearValue();break;case" ":if(d)return;if(!m){i.openMenu("first");break}if(!S)return;i.selectOption(S);break;case"ArrowUp":m?i.focusOption("up"):i.openMenu("last");break;case"ArrowDown":m?i.focusOption("down"):i.openMenu("first");break;case"PageUp":if(!m)return;i.focusOption("pageup");break;case"PageDown":if(!m)return;i.focusOption("pagedown");break;case"Home":if(!m)return;i.focusOption("first");break;case"End":if(!m)return;i.focusOption("last");break;default:return}s.preventDefault()}},i.instancePrefix="react-select-"+(i.props.instanceId||++fk),i.state.selectValue=zv(r.value),r.menuIsOpen&&i.state.selectValue.length){var o=i.buildFocusableOptions(),a=o.indexOf(i.state.selectValue[0]);i.state.focusedOption=o[a]}return i}return N6(n,[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&Vv(this.menuListRef,this.focusedOptionRef)}},{key:"componentDidUpdate",value:function(i){var o=this.props,a=o.isDisabled,s=o.menuIsOpen,l=this.state.isFocused;(l&&!a&&i.isDisabled||l&&s&&!i.menuIsOpen)&&this.focusInput(),l&&a&&!i.isDisabled?this.setState({isFocused:!1},this.onMenuClose):!l&&!a&&i.isDisabled&&this.inputRef===document.activeElement&&this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(Vv(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(i,o){this.props.onInputChange(i,o)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(i){var o=this,a=this.state,s=a.selectValue,l=a.isFocused,u=this.buildFocusableOptions(),c=i==="first"?0:u.length-1;if(!this.props.isMulti){var f=u.indexOf(s[0]);f>-1&&(c=f)}this.scrollToFocusedOptionOnUpdate=!(l&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:u[c]},function(){return o.onMenuOpen()})}},{key:"focusValue",value:function(i){var o=this.state,a=o.selectValue,s=o.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var l=a.indexOf(s);s||(l=-1);var u=a.length-1,c=-1;if(a.length){switch(i){case"previous":l===0?c=0:l===-1?c=u:c=l-1;break;case"next":l>-1&&l0&&arguments[0]!==void 0?arguments[0]:"first",o=this.props.pageSize,a=this.state.focusedOption,s=this.getFocusableOptions();if(s.length){var l=0,u=s.indexOf(a);a||(u=-1),i==="up"?l=u>0?u-1:s.length-1:i==="down"?l=(u+1)%s.length:i==="pageup"?(l=u-o,l<0&&(l=0)):i==="pagedown"?(l=u+o,l>s.length-1&&(l=s.length-1)):i==="last"&&(l=s.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:s[l],focusedValue:null})}}},{key:"getTheme",value:function(){return this.props.theme?typeof this.props.theme=="function"?this.props.theme(Bc):Q(Q({},Bc),this.props.theme):Bc}},{key:"getCommonProps",value:function(){var i=this.clearValue,o=this.cx,a=this.getStyles,s=this.getClassNames,l=this.getValue,u=this.selectOption,c=this.setValue,f=this.props,d=f.isMulti,h=f.isRtl,y=f.options,m=this.hasValue();return{clearValue:i,cx:o,getStyles:a,getClassNames:s,getValue:l,hasValue:m,isMulti:d,isRtl:h,options:y,selectOption:u,selectProps:f,setValue:c,theme:this.getTheme()}}},{key:"hasValue",value:function(){var i=this.state.selectValue;return i.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var i=this.props,o=i.isClearable,a=i.isMulti;return o===void 0?a:o}},{key:"isOptionDisabled",value:function(i,o){return ew(this.props,i,o)}},{key:"isOptionSelected",value:function(i,o){return tw(this.props,i,o)}},{key:"filterOption",value:function(i,o){return nw(this.props,i,o)}},{key:"formatOptionLabel",value:function(i,o){if(typeof this.props.formatOptionLabel=="function"){var a=this.props.inputValue,s=this.state.selectValue;return this.props.formatOptionLabel(i,{context:o,inputValue:a,selectValue:s})}else return this.getOptionLabel(i)}},{key:"formatGroupLabel",value:function(i){return this.props.formatGroupLabel(i)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var i=this.props,o=i.isDisabled,a=i.isSearchable,s=i.inputId,l=i.inputValue,u=i.tabIndex,c=i.form,f=i.menuIsOpen,d=i.required,h=this.getComponents(),y=h.Input,m=this.state,w=m.inputIsHidden,p=m.ariaSelection,v=this.commonProps,g=s||this.getElementId("input"),S=Q(Q(Q({"aria-autocomplete":"list","aria-expanded":f,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":d,role:"combobox"},f&&{"aria-controls":this.getElementId("listbox"),"aria-owns":this.getElementId("listbox")}),!a&&{"aria-readonly":!0}),this.hasValue()?(p==null?void 0:p.action)==="initial-input-focus"&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return a?b.createElement(y,J({},v,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:g,innerRef:this.getInputRef,isDisabled:o,isHidden:w,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:u,form:c,type:"text",value:l},S)):b.createElement(V8,J({id:g,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:Il,onFocus:this.onInputFocus,disabled:o,tabIndex:u,inputMode:"none",form:c,value:""},S))}},{key:"renderPlaceholderOrValue",value:function(){var i=this,o=this.getComponents(),a=o.MultiValue,s=o.MultiValueContainer,l=o.MultiValueLabel,u=o.MultiValueRemove,c=o.SingleValue,f=o.Placeholder,d=this.commonProps,h=this.props,y=h.controlShouldRenderValue,m=h.isDisabled,w=h.isMulti,p=h.inputValue,v=h.placeholder,g=this.state,S=g.selectValue,E=g.focusedValue,x=g.isFocused;if(!this.hasValue()||!y)return p?null:b.createElement(f,J({},d,{key:"placeholder",isDisabled:m,isFocused:x,innerProps:{id:this.getElementId("placeholder")}}),v);if(w)return S.map(function(C,k){var P=C===E,$="".concat(i.getOptionLabel(C),"-").concat(i.getOptionValue(C));return b.createElement(a,J({},d,{components:{Container:s,Label:l,Remove:u},isFocused:P,isDisabled:m,key:$,index:k,removeProps:{onClick:function(){return i.removeValue(C)},onTouchEnd:function(){return i.removeValue(C)},onMouseDown:function(H){H.preventDefault()}},data:C}),i.formatOptionLabel(C,"value"))});if(p)return null;var _=S[0];return b.createElement(c,J({},d,{data:_,isDisabled:m}),this.formatOptionLabel(_,"value"))}},{key:"renderClearIndicator",value:function(){var i=this.getComponents(),o=i.ClearIndicator,a=this.commonProps,s=this.props,l=s.isDisabled,u=s.isLoading,c=this.state.isFocused;if(!this.isClearable()||!o||l||!this.hasValue()||u)return null;var f={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return b.createElement(o,J({},a,{innerProps:f,isFocused:c}))}},{key:"renderLoadingIndicator",value:function(){var i=this.getComponents(),o=i.LoadingIndicator,a=this.commonProps,s=this.props,l=s.isDisabled,u=s.isLoading,c=this.state.isFocused;if(!o||!u)return null;var f={"aria-hidden":"true"};return b.createElement(o,J({},a,{innerProps:f,isDisabled:l,isFocused:c}))}},{key:"renderIndicatorSeparator",value:function(){var i=this.getComponents(),o=i.DropdownIndicator,a=i.IndicatorSeparator;if(!o||!a)return null;var s=this.commonProps,l=this.props.isDisabled,u=this.state.isFocused;return b.createElement(a,J({},s,{isDisabled:l,isFocused:u}))}},{key:"renderDropdownIndicator",value:function(){var i=this.getComponents(),o=i.DropdownIndicator;if(!o)return null;var a=this.commonProps,s=this.props.isDisabled,l=this.state.isFocused,u={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return b.createElement(o,J({},a,{innerProps:u,isDisabled:s,isFocused:l}))}},{key:"renderMenu",value:function(){var i=this,o=this.getComponents(),a=o.Group,s=o.GroupHeading,l=o.Menu,u=o.MenuList,c=o.MenuPortal,f=o.LoadingMessage,d=o.NoOptionsMessage,h=o.Option,y=this.commonProps,m=this.state.focusedOption,w=this.props,p=w.captureMenuScroll,v=w.inputValue,g=w.isLoading,S=w.loadingMessage,E=w.minMenuHeight,x=w.maxMenuHeight,_=w.menuIsOpen,C=w.menuPlacement,k=w.menuPosition,P=w.menuPortalTarget,$=w.menuShouldBlockScroll,F=w.menuShouldScrollIntoView,H=w.noOptionsMessage,j=w.onMenuScrollToTop,L=w.onMenuScrollToBottom;if(!_)return null;var M=function(T,z){var U=T.type,W=T.data,X=T.isDisabled,oe=T.isSelected,Ie=T.label,xe=T.value,be=m===W,Ce=X?void 0:function(){return i.onOptionHover(W)},Zt=X?void 0:function(){return i.selectOption(W)},_t="".concat(i.getElementId("option"),"-").concat(z),Ma={id:_t,onClick:Zt,onMouseMove:Ce,onMouseOver:Ce,tabIndex:-1};return b.createElement(h,J({},y,{innerProps:Ma,data:W,isDisabled:X,isSelected:oe,key:_t,label:Ie,type:U,value:xe,isFocused:be,innerRef:be?i.getFocusedOptionRef:void 0}),i.formatOptionLabel(T.data,"menu"))},D;if(this.hasOptions())D=this.getCategorizedOptions().map(function(V){if(V.type==="group"){var T=V.data,z=V.options,U=V.index,W="".concat(i.getElementId("group"),"-").concat(U),X="".concat(W,"-heading");return b.createElement(a,J({},y,{key:W,data:T,options:z,Heading:s,headingProps:{id:X,data:V.data},label:i.formatGroupLabel(V.data)}),V.options.map(function(oe){return M(oe,"".concat(U,"-").concat(oe.index))}))}else if(V.type==="option")return M(V,"".concat(V.index))});else if(g){var A=S({inputValue:v});if(A===null)return null;D=b.createElement(f,y,A)}else{var I=H({inputValue:v});if(I===null)return null;D=b.createElement(d,y,I)}var R={minMenuHeight:E,maxMenuHeight:x,menuPlacement:C,menuPosition:k,menuShouldScrollIntoView:F},N=b.createElement(wO,J({},y,R),function(V){var T=V.ref,z=V.placerProps,U=z.placement,W=z.maxHeight;return b.createElement(l,J({},y,R,{innerRef:T,innerProps:{onMouseDown:i.onMenuMouseDown,onMouseMove:i.onMenuMouseMove,id:i.getElementId("listbox")},isLoading:g,placement:U}),b.createElement(K8,{captureEnabled:p,onTopArrive:j,onBottomArrive:L,lockEnabled:$},function(X){return b.createElement(u,J({},y,{innerRef:function(Ie){i.getMenuListRef(Ie),X(Ie)},isLoading:g,maxHeight:W,focusedOption:m}),D)}))});return P||k==="fixed"?b.createElement(c,J({},y,{appendTo:P,controlElement:this.controlRef,menuPlacement:C,menuPosition:k}),N):N}},{key:"renderFormField",value:function(){var i=this,o=this.props,a=o.delimiter,s=o.isDisabled,l=o.isMulti,u=o.name,c=o.required,f=this.state.selectValue;if(c&&!this.hasValue()&&!s)return b.createElement(Y8,{name:u,onFocus:this.onValueInputFocus});if(!(!u||s))if(l)if(a){var d=f.map(function(m){return i.getOptionValue(m)}).join(a);return b.createElement("input",{name:u,type:"hidden",value:d})}else{var h=f.length>0?f.map(function(m,w){return b.createElement("input",{key:"i-".concat(w),name:u,type:"hidden",value:i.getOptionValue(m)})}):b.createElement("input",{name:u,type:"hidden",value:""});return b.createElement("div",null,h)}else{var y=f[0]?this.getOptionValue(f[0]):"";return b.createElement("input",{name:u,type:"hidden",value:y})}}},{key:"renderLiveRegion",value:function(){var i=this.commonProps,o=this.state,a=o.ariaSelection,s=o.focusedOption,l=o.focusedValue,u=o.isFocused,c=o.selectValue,f=this.getFocusableOptions();return b.createElement($8,J({},i,{id:this.getElementId("live-region"),ariaSelection:a,focusedOption:s,focusedValue:l,isFocused:u,selectValue:c,focusableOptions:f}))}},{key:"render",value:function(){var i=this.getComponents(),o=i.Control,a=i.IndicatorsContainer,s=i.SelectContainer,l=i.ValueContainer,u=this.props,c=u.className,f=u.id,d=u.isDisabled,h=u.menuIsOpen,y=this.state.isFocused,m=this.commonProps=this.getCommonProps();return b.createElement(s,J({},m,{className:c,innerProps:{id:f,onKeyDown:this.onKeyDown},isDisabled:d,isFocused:y}),this.renderLiveRegion(),b.createElement(o,J({},m,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:d,isFocused:y,menuIsOpen:h}),b.createElement(l,J({},m,{isDisabled:d}),this.renderPlaceholderOrValue(),this.renderInput()),b.createElement(a,J({},m,{isDisabled:d}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],[{key:"getDerivedStateFromProps",value:function(i,o){var a=o.prevProps,s=o.clearFocusValueOnUpdate,l=o.inputIsHiddenAfterUpdate,u=o.ariaSelection,c=o.isFocused,f=o.prevWasFocused,d=i.options,h=i.value,y=i.menuIsOpen,m=i.inputValue,w=i.isMulti,p=zv(h),v={};if(a&&(h!==a.value||d!==a.options||y!==a.menuIsOpen||m!==a.inputValue)){var g=y?lk(i,p):[],S=s?uk(o,p):null,E=ck(o,g);v={selectValue:p,focusedOption:E,focusedValue:S,clearFocusValueOnUpdate:!1}}var x=l!=null&&i!==a?{inputIsHidden:l,inputIsHiddenAfterUpdate:void 0}:{},_=u,C=c&&f;return c&&!C&&(_={value:cs(w,p,p[0]||null),options:p,action:"initial-input-focus"},C=!f),(u==null?void 0:u.action)==="initial-input-focus"&&(_=null),Q(Q(Q({},v),x),{},{prevProps:i,ariaSelection:_,prevWasFocused:C})}}]),n}(b.Component);iw.defaultProps=sk;var dk=b.forwardRef(function(e,t){var n=F6(e);return b.createElement(iw,J({ref:t},n))}),pk=dk;function hk(e){return O.jsx(pk,{classNames:{container:()=>"text-lg bg-white rounded text-gray-400",valueContainer:()=>"text-lg !text-gray-600 !py-1",singleValue:()=>"text-lg !text-gray-600 py-1",multiValue:()=>"text-lg !text-gray-600",menuList:()=>"text-lg !text-gray-600"},...e})}const fs=({label:e,multiple:t,onChange:n,options:r,value:i})=>{const o=b.useMemo(()=>{if(!i)return t?[]:void 0;const s=i.split(",");return t?r.filter(l=>s.includes(l.value)):r.find(l=>l.value===i)},[i,r,t]),a=b.useCallback(s=>{if(Array.isArray(s))n==null||n(s.map(l=>l.value).join(","));else{const l=s;n==null||n((l==null?void 0:l.value)||"")}},[n]);return O.jsxs("div",{className:"flex flex-col text-gray-400 w-full max-w-xs hover:text-white",children:[O.jsx("span",{className:"flex-1 text-lg text-left",children:e}),O.jsx(hk,{value:o,isMulti:t,name:e,options:r,onChange:a})]})},mk=({onUpdate:e})=>{const{dotLottie:t,setAnimationOptions:n}=Wp(),r=ku(),i=Fe(d=>d.editor.animationOptions),o=Fe(d=>d.editor.animationId),a=Fe(d=>d.editor.updated),s=Fe(d=>d.themes.list),l=b.useMemo(()=>s.map(({name:d})=>({label:d,value:d})),[s]),u=b.useMemo(()=>{var h;const d=[{label:"None",value:""}];return typeof i.assignedThemes<"u"&&Array.isArray(i.assignedThemes)?d:d.concat(((h=i.assignedThemes)==null?void 0:h.split(",").map(y=>({label:y,value:y})))||[])},[i,o]);b.useEffect(()=>{if(o)return(async()=>{const d=await t.getAnimation(o);d&&r(xv({direction:d.direction,speed:d.speed,playMode:d.playMode,loop:d.loop,autoplay:d.autoplay,hover:d.hover,intermission:d.intermission,defaultTheme:d.defaultTheme,assignedThemes:d.themes.map(h=>h.id).join(",")||void 0,defaultActiveAnimation:d.defaultActiveAnimation}))})(),()=>{r(xv({}))}},[r,t,o]);const c=b.useCallback(d=>h=>{d==="assignedThemes"&&!String(h).split(",").includes(i.defaultTheme||"")&&r(kv({defaultTheme:""})),r(kv({[d]:h})),r(xl(!0))},[r,i]),f=b.useCallback(()=>{o&&(n(o,i),r(xl(!1)),e())},[o,i,n,r,e]);return O.jsxs("div",{className:"h-full flex flex-col",children:[O.jsxs("div",{className:"flex justify-between items-stretch pr-4 flex-shrink border-b border-gray-600",children:[O.jsxs("span",{className:"text-white text-sm border-b border-b-blue-500 border-r border-gray-600 px-4 flex items-center",children:["Animation: ",o]}),O.jsx("button",{title:"Save",className:"text-gray-400 py-1 hover:text-white disabled:text-gray-700",onClick:f,disabled:!a,children:O.jsx(gy,{size:33})})]}),O.jsxs("div",{className:"p-8 flex-1 max-h-[calc(100vh-5.5rem)] overflow-y-auto custom-scrollbar",children:[O.jsx("div",{className:"text-white",children:"Playback options"}),O.jsx("ul",{children:Object.keys(i).map(d=>["loop","autoplay","hover"].includes(d)?O.jsx("li",{children:O.jsx(Iv,{label:d,value:i[d],onToggle:c(d)})},d):["playMode"].includes(d)?O.jsx("li",{children:O.jsx(fs,{onChange:c(d),label:d,value:i[d],options:[{label:"Normal",value:"normal"},{label:"Bounce",value:"bounce"}]})},d):["direction"].includes(d)?O.jsx("li",{children:O.jsx(fs,{onChange:c(d),label:d,value:String(i[d]),options:[{label:"Normal",value:"1"},{label:"Inverted",value:"-1"}]})},d):["speed","intermission"].includes(d)?O.jsx("li",{children:O.jsx(L6,{label:d,value:i[d],onChange:c(d)})},d):["defaultTheme"].includes(d)?O.jsx("li",{children:O.jsx(fs,{onChange:c(d),label:"defaultTheme",options:u||[],value:i[d]||""})},d):void 0)}),O.jsx("div",{className:"text-white mt-8",children:"Other options"}),O.jsxs("div",{children:[O.jsx(fs,{multiple:!0,onChange:c("assignedThemes"),label:"Assign Themes",value:i.assignedThemes,options:l}),O.jsx(Iv,{label:"Default ActiveAnimation",value:i.defaultActiveAnimation,onToggle:c("defaultActiveAnimation")})]})]})]})},vk="modulepreload",gk=function(e){return"/player-component/"+e},n0={},tn=function(t,n,r){if(!n||n.length===0)return t();const i=document.getElementsByTagName("link");return Promise.all(n.map(o=>{if(o=gk(o),o in n0)return;n0[o]=!0;const a=o.endsWith(".css"),s=a?'[rel="stylesheet"]':"";if(!!r)for(let c=i.length-1;c>=0;c--){const f=i[c];if(f.href===o&&(!a||f.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${o}"]${s}`))return;const u=document.createElement("link");if(u.rel=a?"stylesheet":vk,a||(u.as="script",u.crossOrigin=""),u.href=o,document.head.appendChild(u),a)return new Promise((c,f)=>{u.addEventListener("load",c),u.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${o}`)))})})).then(()=>t()).catch(o=>{const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o})};var r0={},yk=function(e,t,n,r,i){var o=new Worker(r0[t]||(r0[t]=URL.createObjectURL(new Blob([e+';addEventListener("error",function(e){e=e.error;postMessage({$e$:[e.message,e.code,e.stack]})})'],{type:"text/javascript"}))));return o.onmessage=function(a){var s=a.data,l=s.$e$;if(l){var u=new Error(l[0]);u.code=l[1],u.stack=l[2],i(u,null)}else i(null,s)},o.postMessage(n,r),o},ct=Uint8Array,jr=Uint16Array,ow=Int32Array,th=new ct([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),nh=new ct([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),aw=new ct([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),sw=function(e,t){for(var n=new jr(31),r=0;r<31;++r)n[r]=t+=1<>1|(ue&21845)<<1,Ln=(Ln&52428)>>2|(Ln&13107)<<2,Ln=(Ln&61680)>>4|(Ln&3855)<<4,Tl[ue]=((Ln&65280)>>8|(Ln&255)<<8)>>1;var Ln,ue,Li=function(e,t,n){for(var r=e.length,i=0,o=new jr(t);i>l]=u}else for(s=new jr(r),i=0;i>15-e[i]);return s},Oa=new ct(288);for(ue=0;ue<144;++ue)Oa[ue]=8;var ue;for(ue=144;ue<256;++ue)Oa[ue]=9;var ue;for(ue=256;ue<280;++ue)Oa[ue]=7;var ue;for(ue=280;ue<288;++ue)Oa[ue]=8;var ue,cw=new ct(32);for(ue=0;ue<32;++ue)cw[ue]=5;var ue,fw=Li(Oa,9,1),dw=Li(cw,5,1),$s=function(e){for(var t=e[0],n=1;nt&&(t=e[n]);return t},Nt=function(e,t,n){var r=t/8|0;return(e[r]|e[r+1]<<8)>>(t&7)&n},js=function(e,t){var n=t/8|0;return(e[n]|e[n+1]<<8|e[n+2]<<16)>>(t&7)},pw=function(e){return(e+7)/8|0},Lu=function(e,t,n){(t==null||t<0)&&(t=0),(n==null||n>e.length)&&(n=e.length);var r=new ct(n-t);return r.set(e.subarray(t,n)),r},hw=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],ut=function(e,t,n){var r=new Error(t||hw[e]);if(r.code=e,Error.captureStackTrace&&Error.captureStackTrace(r,ut),!n)throw r;return r},mw=function(e,t,n,r){var i=e.length,o=r?r.length:0;if(!i||t.f&&!t.l)return n||new ct(0);var a=!n||t.i!=2,s=t.i;n||(n=new ct(i*3));var l=function(xe){var be=n.length;if(xe>be){var Ce=new ct(Math.max(be*2,xe));Ce.set(n),n=Ce}},u=t.f||0,c=t.p||0,f=t.b||0,d=t.l,h=t.d,y=t.m,m=t.n,w=i*8;do{if(!d){u=Nt(e,c,1);var p=Nt(e,c+1,3);if(c+=3,p)if(p==1)d=fw,h=dw,y=9,m=5;else if(p==2){var v=Nt(e,c,31)+257,g=Nt(e,c+10,15)+4,S=v+Nt(e,c+5,31)+1;c+=14;for(var E=new ct(S),x=new ct(19),_=0;_>4;if(F<16)E[_++]=F;else{var H=0,j=0;for(F==16?(j=3+Nt(e,c,3),c+=2,H=E[_-1]):F==17?(j=3+Nt(e,c,7),c+=3):F==18&&(j=11+Nt(e,c,127),c+=7);j--;)E[_++]=H}}var L=E.subarray(0,v),M=E.subarray(v);y=$s(L),m=$s(M),d=Li(L,y,1),h=Li(M,m,1)}else ut(1);else{var F=pw(c)+4,D=e[F-4]|e[F-3]<<8,A=F+D;if(A>i){s&&ut(0);break}a&&l(f+D),n.set(e.subarray(F,A),f),t.b=f+=D,t.p=c=A*8,t.f=u;continue}if(c>w){s&&ut(0);break}}a&&l(f+131072);for(var I=(1<>4;if(c+=H&15,c>w){s&&ut(0);break}if(H||ut(2),V<256)n[f++]=V;else if(V==256){N=c,d=null;break}else{var T=V-254;if(V>264){var _=V-257,z=th[_];T=Nt(e,c,(1<>4;U||ut(3),c+=U&15;var M=uw[W];if(W>3){var z=nh[W];M+=js(e,c)&(1<w){s&&ut(0);break}a&&l(f+131072);var X=f+T;if(f>>0},Uc=function(e,t){return an(e,t)+an(e,t+4)*4294967296};function kk(e,t,n){return n||(n=t,t={}),typeof n!="function"&&ut(7),Ok(e,t,[Ck],function(r){return vw(ih(r.data[0],gw(r.data[1])))},1,n)}function ih(e,t){return mw(e,{i:2},t&&t.out,t&&t.dictionary)}var Sd=typeof TextDecoder<"u"&&new TextDecoder,Ak=0;try{Sd.decode(bk,{stream:!0}),Ak=1}catch{}var Pk=function(e){for(var t="",n=0;;){var r=e[n++],i=(r>127)+(r>223)+(r>239);if(n+i>e.length)return{s:t,r:Lu(e,n-1)};i?i==3?(r=((r&15)<<18|(e[n++]&63)<<12|(e[n++]&63)<<6|e[n++]&63)-65536,t+=String.fromCharCode(55296|r>>10,56320|r&1023)):i&1?t+=String.fromCharCode((r&31)<<6|e[n++]&63):t+=String.fromCharCode((r&15)<<12|(e[n++]&63)<<6|e[n++]&63):t+=String.fromCharCode(r)}};function no(e,t){if(t){for(var n="",r=0;r65558)return a(ut(13,0,1),null),i;var l=xn(e,s+8);if(l){var u=l,c=an(e,s+16),f=c==4294967295||u==65535;if(f){var d=an(e,s-12);f=an(e,d)==101075792,f&&(u=l=an(e,d+32),c=an(e,d+48))}for(var h=t&&t.filter,y=function(w){var p=Mk(e,c,f),v=p[0],g=p[1],S=p[2],E=p[3],x=p[4],_=p[5],C=Ik(e,_);c=x;var k=function($,F){$?(i(),a($,null)):(F&&(o[E]=F),--l||a(null,o))};if(!h||h({name:E,size:g,originalSize:S,compression:v}))if(!v)k(null,Lu(e,C,C+g));else if(v==8){var P=e.subarray(C,C+g);if(g<32e4)try{k(null,ih(P,{out:new ct(S)}))}catch($){k($,null)}else r.push(kk(P,{size:S},k))}else k(ut(14,"unknown compression type "+v,1),null);else k(null,null)},m=0;m{if(n.path){let r=n.path.map(({key:i})=>i).join(".");t.nested[r]=[...t.nested[r]||[],n.message]}else t.root=[...t.root||[],n.message];return t},{nested:{}})}var $k=class extends Error{constructor(t){super(t[0].message);te(this,"issues");this.name="ValiError",this.issues=t}};function jk(e,t){return{reason:e==null?void 0:e.reason,validation:t.validation,origin:(e==null?void 0:e.origin)||"value",message:t.message,input:t.input,abortEarly:e==null?void 0:e.abortEarly,abortPipeEarly:e==null?void 0:e.abortPipeEarly}}function Fk(e,t){return{reason:t,origin:e==null?void 0:e.origin,abortEarly:e==null?void 0:e.abortEarly,abortPipeEarly:e==null?void 0:e.abortPipeEarly}}function Cr(e,t,n,r){if(!t||!t.length)return{output:e};let i,o,a=e;for(let s of t){let l=s(a);if(l.issue){i=i||Fk(n,r);let u=jk(i,l.issue);if(o?o.push(u):o=[u],i.abortEarly||i.abortPipeEarly)break}else a=l.output}return o?{issues:o}:{output:a}}function hn(e,t){return!e||typeof e=="string"?[e,t]:[void 0,e]}function Mn(e,t,n,r,i,o){return{issues:[{reason:t,validation:n,origin:(e==null?void 0:e.origin)||"value",message:r,input:i,issues:o,abortEarly:e==null?void 0:e.abortEarly,abortPipeEarly:e==null?void 0:e.abortPipeEarly}]}}function Rk(e=[]){return{schema:"any",async:!1,_parse(t,n){return Cr(t,e,n,"any")}}}function Ro(e,t,n){let[r,i]=hn(t,n);return{schema:"array",array:{item:e},async:!1,_parse(o,a){if(!Array.isArray(o))return Mn(a,"type","array",r||"Invalid type",o);let s,l=[];for(let u=0;us.length)return Mn(l,"type","tuple",o||"Invalid type",s);let u,c=[];for(let f=0;f({...o,...a.object}),{}),r,i)}function Hk(e,t,n,r){let[i,o]=hn(n,r);return Jt(Object.entries(e.object).reduce((a,[s,l])=>t.includes(s)?a:{...a,[s]:l},{}),i,o)}function Wk(e,t,n){let r=e._parse(t,n);return r.issues?{success:!1,error:new $k(r.issues),issues:r.issues}:{success:!0,data:r.output,output:r.output}}function Ed(e,t){return n=>n>e?{issue:{validation:"max_value",message:t||"Invalid value",input:n}}:{output:n}}function _d(e,t){return n=>nt in e?oh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Aa=(e,t)=>function(){return t||(0,e[yw(e)[0]])((t={exports:{}}).exports,t),t.exports},Jk=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of yw(t))!Qk.call(e,i)&&i!==n&&oh(e,i,{get:()=>t[i],enumerable:!(r=Kk(t,i))||r.enumerable});return e},Zk=(e,t,n)=>(n=e!=null?qk(Gk(e)):{},Jk(t||!e||!e.__esModule?oh(n,"default",{value:e,enumerable:!0}):n,e)),Xk=(e,t,n)=>(Yk(e,typeof t!="symbol"?t+"":t,n),n),eA=Aa({"../../node_modules/.pnpm/@rgba-image+copy@0.1.3/node_modules/@rgba-image/copy/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.copy=void 0;var t=(n,r,i=0,o=0,a=n.width-i,s=n.height-o,l=0,u=0)=>{if(i=i|0,o=o|0,a=a|0,s=s|0,l=l|0,u=u|0,a<=0||s<=0)return;let c=new Uint32Array(n.data.buffer),f=new Uint32Array(r.data.buffer);for(let d=0;d=n.height)continue;let y=u+d;if(!(y<0||y>=r.height))for(let m=0;m=n.width)continue;let p=l+m;if(p<0||p>=r.width)continue;let v=h*n.width+w,g=y*r.width+p;f[g]=c[v]}}};e.copy=t}}),tA=Aa({"../../node_modules/.pnpm/@rgba-image+create-image@0.1.1/node_modules/@rgba-image/create-image/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CreateImageFactory=(t=[0,0,0,0],n=4)=>{if(n=Math.floor(n),isNaN(n)||n<1)throw TypeError("channels should be a positive non-zero number");if(!("length"in t)||t.lengthi===0);return(i,o,a)=>{if(i===void 0||o===void 0)throw TypeError("Not enough arguments");if(i=Math.floor(i),o=Math.floor(o),isNaN(i)||i<1||isNaN(o)||o<1)throw TypeError("Index or size is negative or greater than the allowed amount");let s=i*o*n;if(a===void 0&&(a=new Uint8ClampedArray(s)),a instanceof Uint8ClampedArray){if(a.length!==s)throw TypeError("Index or size is negative or greater than the allowed amount");if(!r)for(let l=0;l{if(o<=-a||o>=a||o==0)return 0;let s=o*Math.PI;return Math.sin(s)/s*Math.sin(s/a)/(s/a)},r=o=>Math.round(o*((1<{let c=u?2:3,f=1/s,d=Math.min(1,s),h=c/d,y=Math.floor((h+1)*2),m=new Int16Array((y+2)*a),w=0;for(let p=0;p>1]+=r(1-P);let $=0;for(;$<_.length&&_[$]===0;)$++;let F=_.length-1;for(;F>0&&_[F]===0;)F--;let H=g+$,j=F-$+1;m[w++]=H,m[w++]=j,m.set(_.subarray($,F+1),w),w+=j}return m};e.filters=i}}),rA=Aa({"../../node_modules/.pnpm/@rgba-image+lanczos@0.1.1/node_modules/@rgba-image/lanczos/dist/convolve.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.convolve=void 0;var t=14,n=(r,i,o,a,s,l)=>{let u=0,c=0;for(let f=0;f0;S--){let E=l[d++];w=w+E*r[m]|0,p=p+E*r[m+1]|0,v=v+E*r[m+2]|0,g=g+E*r[m+3]|0,m=m+4|0}i[c]=w+8192>>t,i[c+1]=p+8192>>t,i[c+2]=v+8192>>t,i[c+3]=g+8192>>t,c=c+a*4|0}c=(f+1)*4|0,u=(f+1)*o*4|0}};e.convolve=n}}),iA=Aa({"../../node_modules/.pnpm/@rgba-image+lanczos@0.1.1/node_modules/@rgba-image/lanczos/dist/index.js"(e){Object.defineProperty(e,"__esModule",{value:!0}),e.lanczos2=e.lanczos=void 0;var t=eA(),n=tA(),r=nA(),i=rA(),o=(l,u,c=!1)=>{let f=u.width/l.width,d=u.height/l.height,h=r.filters(l.width,u.width,f,0,c),y=r.filters(l.height,u.height,d,0,c),m=new Uint8ClampedArray(u.width*l.height*4);i.convolve(l.data,m,l.width,l.height,u.width,h),i.convolve(m,u.data,l.height,u.width,u.height,y)},a=(l,u,c=0,f=0,d=l.width-c,h=l.height-f,y=0,m=0,w=u.width-y,p=u.height-m)=>{if(c=c|0,f=f|0,d=d|0,h=h|0,y=y|0,m=m|0,w=w|0,p=p|0,d<=0||h<=0||w<=0||p<=0)return;if(c===0&&f===0&&d===l.width&&h===l.height&&y===0&&m===0&&w===u.width&&p===u.height){o(l,u);return}let v=n.createImage(d,h),g=n.createImage(w,p);t.copy(l,v,c,f),o(v,g),t.copy(g,u,0,0,g.width,g.height,y,m)};e.lanczos=a;var s=(l,u,c=0,f=0,d=l.width-c,h=l.height-f,y=0,m=0,w=u.width-y,p=u.height-m)=>{if(c=c|0,f=f|0,d=d|0,h=h|0,y=y|0,m=m|0,w=w|0,p=p|0,d<=0||h<=0||w<=0||p<=0)return;if(c===0&&f===0&&d===l.width&&h===l.height&&y===0&&m===0&&w===u.width&&p===u.height){o(l,u,!0);return}let v=n.createImage(d,h),g=n.createImage(w,p);t.copy(l,v,c,f),o(v,g,!0),t.copy(g,u,0,0,g.width,g.height,y,m)};e.lanczos2=s}}),ww=(e=>(e.Bounce="bounce",e.Normal="normal",e))(ww||{}),oA=Nk(ww),Sw=Jt({autoplay:ce(Hc()),defaultTheme:ce(Ye()),direction:ce(bd([a0(1),a0(-1)])),hover:ce(Hc()),id:Ye(),intermission:ce(ln()),loop:ce(bd([Hc(),ln()])),playMode:ce(oA),speed:ce(ln()),themeColor:ce(Ye())}),aA=Jt({animations:Ro(Ye()),id:Ye()}),sA=Jt({activeAnimationId:ce(Ye()),animations:Ro(Sw),author:ce(Ye()),custom:ce(Bk(Ye(),Rk())),description:ce(Ye()),generator:ce(Ye()),keywords:ce(Ye()),revision:ce(ln()),themes:ce(Ro(aA)),states:ce(Ro(Ye())),version:ce(Ye())}),bw=Hk(Sw,["id"]),Xr=Jt({state:Ye()}),lA=Xr,uA=ka([Xr,Jt({ms:ln()})]),cA=ka([Xr,Jt({count:ln()})]),fA=Xr,dA=Xr,pA=Xr,hA=ka([Xr,Jt({threshold:ce(Ro(ln([_d(0),Ed(1)])))})]),mA=Jt({onAfter:ce(uA),onClick:ce(lA),onComplete:ce(pA),onEnter:ce(cA),onMouseEnter:ce(fA),onMouseLeave:ce(dA),onShow:ce(hA)}),vA=ka([bw,Jt({playOnScroll:ce(s0([ln([_d(0),Ed(1)]),ln([_d(0),Ed(1)])])),segments:ce(bd([s0([ln(),ln()]),Ye()]))})]);ka([mA,Jt({animationId:ce(Ye()),playbackSettings:vA})]);var gA={jpeg:"image/jpeg",png:"image/png",gif:"image/gif",bmp:"image/bmp",svg:"image/svg+xml",webp:"image/webp",mpeg:"audio/mpeg",mp3:"audio/mp3"},l0={jpeg:[255,216,255],png:[137,80,78,71,13,10,26,10],gif:[71,73,70],bmp:[66,77],webp:[82,73,70,70,87,69,66,80],svg:[60,63,120],mp3:[73,68,51,3,0,0,0,0],mpeg:[73,68,51,3,0,0,0,0]},yA=e=>{let t=null,n=[];if(!e)return null;let r=e.substring(e.indexOf(",")+1);typeof window>"u"?t=Buffer.from(r,"base64").toString("binary"):t=atob(r);let i=new Uint8Array(t.length);for(let o=0;os===a[l]))return gA[o]}return null},ah=class extends Error{constructor(e,t){super(e),Xk(this,"code"),this.name="[dotlottie-js]",this.code=t}};function Ew(e){let t;if(typeof window>"u")t=Buffer.from(e).toString("base64");else{let n=Array.prototype.map.call(e,r=>String.fromCharCode(r)).join("");t=window.btoa(n)}return`data:${yA(t)};base64,${t}`}function u0(e){return"w"in e&&"h"in e&&!("xt"in e)&&"p"in e}function xd(e){return!("h"in e)&&!("w"in e)&&"p"in e&&"e"in e&&"u"in e&&"id"in e}async function Pa(e,t=()=>!0){if(!(e instanceof Uint8Array))throw new ah("DotLottie not found","INVALID_DOTLOTTIE");return await new Promise((n,r)=>{Tk(e,{filter:t},(i,o)=>{i&&r(i),n(o)})})}async function sh(e,t,n){if(!(e instanceof Uint8Array))throw new ah("DotLottie not found","INVALID_DOTLOTTIE");return(await Pa(e,r=>r.name===t&&(!n||n(r))))[t]}async function Cd(e){let t="manifest.json",n=(await Pa(e,r=>r.name===t))[t];if(!(typeof n>"u"))return JSON.parse(no(n,!1))}async function wA(e){if(!(e instanceof Uint8Array))return{success:!1,error:"DotLottie not found"};let t=await Cd(e);if(typeof t>"u")return{success:!1,error:"Invalid .lottie file, manifest.json is missing"};let n=Wk(sA,t);return n.success?{success:!0}:{success:!1,error:`Invalid .lottie file, manifest.json structure is invalid, ${JSON.stringify(Dk(n.error).nested,null,2)}`}}async function c0(e){let t=new Uint8Array(e),n=await wA(t);if(n.error)throw new ah(n.error,"INVALID_DOTLOTTIE");return t}async function SA(e,t){let n=await Pa(e,i=>{let o=i.name.replace("audio/","");return i.name.startsWith("audio/")&&(!t||t({...i,name:o}))}),r={};for(let i in n){let o=n[i];if(o instanceof Uint8Array){let a=i.replace("audio/","");r[a]=Ew(o)}}return r}async function bA(e,t){var i;let n=new Map;for(let[o,a]of Object.entries(t))for(let s of a.assets||[])if(xd(s)){let l=s.p;n.has(l)||n.set(l,new Set),(i=n.get(l))==null||i.add(o)}let r=await SA(e,o=>n.has(o.name));for(let[o,a]of n){let s=r[o];if(s)for(let l of a){let u=t[l];for(let c of(u==null?void 0:u.assets)||[])xd(c)&&c.p===o&&(c.p=s,c.u="",c.e=1)}}}async function EA(e,t){let n=await Pa(e,i=>{let o=i.name.replace("images/","");return i.name.startsWith("images/")&&(!t||t({...i,name:o}))}),r={};for(let i in n){let o=n[i];if(o instanceof Uint8Array){let a=i.replace("images/","");r[a]=Ew(o)}}return r}async function _A(e,t){var i;let n=new Map;for(let[o,a]of Object.entries(t))for(let s of a.assets||[])if(u0(s)){let l=s.p;n.has(l)||n.set(l,new Set),(i=n.get(l))==null||i.add(o)}let r=await EA(e,o=>n.has(o.name));for(let[o,a]of n){let s=r[o];if(s)for(let l of a){let u=t[l];for(let c of(u==null?void 0:u.assets)||[])u0(c)&&c.p===o&&(c.p=s,c.u="",c.e=1)}}}async function xA(e,t,{inlineAssets:n}={},r){let i=`animations/${t}.json`,o=await sh(e,i,r);if(typeof o>"u")return;let a=JSON.parse(no(o,!1));if(!n)return a;let s={[t]:a};return await _A(e,s),await bA(e,s),a}async function CA(e,t,n){let r=`themes/${t}.lss`,i=await sh(e,r,n);if(!(typeof i>"u"))return no(i,!1)}async function OA(e,t){let n={},r=await Pa(e,i=>{let o=i.name.replace("states/","").replace(".json","");return i.name.startsWith("states/")&&(!t||t({...i,name:o}))});for(let i in r){let o=r[i];if(o instanceof Uint8Array){let a=i.replace("states/","").replace(".json","");n[a]=no(o,!1)}}return n}async function kA(e,t,n){let r=`states/${t}.json`,i=await sh(e,r,n);return typeof i>"u"?void 0:JSON.parse(no(i,!1))}Zk(iA());function se(e,t="dotLottie-common"){return new Error(`[${t}]: ${e}`)}function ai(e,t="dotLottie-common",...n){console.error(`[${t}]:`,e,...n)}function Me(e,t="dotLottie-common",...n){console.warn(`[${t}]:`,e,...n)}function AA(e=""){let t=e.trim(),n=t.lastIndexOf("/"),r=t.substring(n+1),i=r.indexOf(".");return i!==-1?r.substring(0,i):r}function Dl(e){return["v","ip","op","layers","fr","w","h"].every(t=>Object.prototype.hasOwnProperty.call(e,t))}function PA(e){let t=e.assets;return t?t.some(n=>xd(n)):!1}function IA(e){try{let t=JSON.parse(e);return Dl(t)}catch{return!1}}function $7(e,t){let n=Object.keys(e).find(r=>e[r]===t);if(n===void 0)throw new Error("Value not found in the object.");return n}var MA=class{constructor(){te(this,"_dotLottie");te(this,"_animationsMap",new Map);te(this,"_themeMap",new Map);te(this,"_stateMachinesMap",new Map);te(this,"_manifest")}get dotLottie(){return this._dotLottie}get animationsMap(){return this._animationsMap}get themeMap(){return this._themeMap}get stateMachinesMap(){return this._stateMachinesMap}get manifest(){return this._manifest}async loadFromUrl(e){var n;let t=await fetch(e,{method:"GET",mode:"cors"});if(!t.ok)throw new Error(`Failed to load dotLottie from ${e} with status ${t.status}`);if((n=t.headers.get("content-type"))!=null&&n.includes("application/json")){let r=await t.json();if(!Dl(r))throw new Error(`Invalid lottie JSON at ${e}`);let i=AA(e);this._animationsMap.set(i,r);let o={activeAnimationId:i,animations:[{id:i}]};this._manifest=o}else{this._dotLottie=await c0(await t.arrayBuffer());let r=await Cd(this._dotLottie);if(!r)throw new Error("Manifest not found");this._manifest=r}}loadFromLottieJSON(e){if(!Dl(e))throw new Error("Invalid lottie JSON");let t="my-animation";this._animationsMap.set(t,e);let n={activeAnimationId:t,animations:[{id:t}]};this._manifest=n}async loadFromArrayBuffer(e){this._dotLottie=await c0(e);let t=await Cd(this._dotLottie);if(!t)throw new Error("Manifest not found");this._manifest=t}async getAnimation(e){if(this._animationsMap.get(e))return this._animationsMap.get(e);if(!this._dotLottie)return;let t=await xA(this._dotLottie,e,{inlineAssets:!0});return t&&this._animationsMap.set(e,t),t}async getTheme(e){if(this._themeMap.get(e))return this._themeMap.get(e);if(!this._dotLottie)return;let t=await CA(this._dotLottie,e);return t&&this._themeMap.set(e,t),t}async getStateMachines(){if(!this._dotLottie)return;let e=await OA(this._dotLottie);for(let t in e)if(t){let n=e[t];if(n){let r=JSON.parse(n);if(r){let i=r.descriptor.id;this._stateMachinesMap.get(i)||this._stateMachinesMap.set(i,r)}}}return Array.from(this._stateMachinesMap.values())}async getStateMachine(e){if(this._stateMachinesMap.get(e))return this._stateMachinesMap.get(e);if(!this._dotLottie)return;let t=await kA(this._dotLottie,e);return t&&this._stateMachinesMap.set(t.descriptor.id,t),t}};async function LA(e,t){let[{relottie:n},{default:r}]=await Promise.all([tn(()=>import("./dist-AIQGIF54-AIRDCTYW-3493aa73.js"),["assets/dist-AIQGIF54-AIRDCTYW-3493aa73.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]),tn(()=>import("./dist-4JHQ5UB4-UQC3DUUT-48854257.js"),["assets/dist-4JHQ5UB4-UQC3DUUT-48854257.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"])]),i=await n().use(r,{lss:t}).process(JSON.stringify(e));return JSON.parse(i.value)}function Tu(){throw new Error("Cycle detected")}function lh(){if(Ti>1)Ti--;else{for(var e,t=!1;No!==void 0;){var n=No;for(No=void 0,Od++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&xw(n))try{n.c()}catch(i){t||(e=i,t=!0)}n=r}}if(Od=0,Ti--,t)throw e}}var Le=void 0,No=void 0,Ti=0,Od=0,$l=0;function _w(e){if(Le!==void 0){var t=e.n;if(t===void 0||t.t!==Le)return t={i:0,S:e,p:Le.s,n:void 0,t:Le,e:void 0,x:void 0,r:t},Le.s!==void 0&&(Le.s.n=t),Le.s=t,e.n=t,32&Le.f&&e.S(t),t;if(t.i===-1)return t.i=0,t.n!==void 0&&(t.n.p=t.p,t.p!==void 0&&(t.p.n=t.n),t.p=Le.s,t.n=void 0,Le.s.n=t,Le.s=t),t}}function Et(e){this.v=e,this.i=0,this.n=void 0,this.t=void 0}Et.prototype.h=function(){return!0};Et.prototype.S=function(e){this.t!==e&&e.e===void 0&&(e.x=this.t,this.t!==void 0&&(this.t.e=e),this.t=e)};Et.prototype.U=function(e){if(this.t!==void 0){var t=e.e,n=e.x;t!==void 0&&(t.x=n,e.e=void 0),n!==void 0&&(n.e=t,e.x=void 0),e===this.t&&(this.t=n)}};Et.prototype.subscribe=function(e){var t=this;return $A(function(){var n=t.value,r=32&this.f;this.f&=-33;try{e(n)}finally{this.f|=r}})};Et.prototype.valueOf=function(){return this.value};Et.prototype.toString=function(){return this.value+""};Et.prototype.toJSON=function(){return this.value};Et.prototype.peek=function(){return this.v};Object.defineProperty(Et.prototype,"value",{get:function(){var e=_w(this);return e!==void 0&&(e.i=this.i),this.v},set:function(e){if(Le instanceof ei&&function(){throw new Error("Computed cannot have side-effects")}(),e!==this.v){Od>100&&Tu(),this.v=e,this.i++,$l++,Ti++;try{for(var t=this.t;t!==void 0;t=t.x)t.t.N()}finally{lh()}}}});function TA(e){return new Et(e)}function xw(e){for(var t=e.s;t!==void 0;t=t.n)if(t.S.i!==t.i||!t.S.h()||t.S.i!==t.i)return!0;return!1}function Cw(e){for(var t=e.s;t!==void 0;t=t.n){var n=t.S.n;if(n!==void 0&&(t.r=n),t.S.n=t,t.i=-1,t.n===void 0){e.s=t;break}}}function Ow(e){for(var t=e.s,n=void 0;t!==void 0;){var r=t.p;t.i===-1?(t.S.U(t),r!==void 0&&(r.n=t.n),t.n!==void 0&&(t.n.p=r)):n=t,t.S.n=t.r,t.r!==void 0&&(t.r=void 0),t=r}e.s=n}function ei(e){Et.call(this,void 0),this.x=e,this.s=void 0,this.g=$l-1,this.f=4}(ei.prototype=new Et).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===$l))return!0;if(this.g=$l,this.f|=1,this.i>0&&!xw(this))return this.f&=-2,!0;var e=Le;try{Cw(this),Le=this;var t=this.x();(16&this.f||this.v!==t||this.i===0)&&(this.v=t,this.f&=-17,this.i++)}catch(n){this.v=n,this.f|=16,this.i++}return Le=e,Ow(this),this.f&=-2,!0};ei.prototype.S=function(e){if(this.t===void 0){this.f|=36;for(var t=this.s;t!==void 0;t=t.n)t.S.S(t)}Et.prototype.S.call(this,e)};ei.prototype.U=function(e){if(this.t!==void 0&&(Et.prototype.U.call(this,e),this.t===void 0)){this.f&=-33;for(var t=this.s;t!==void 0;t=t.n)t.S.U(t)}};ei.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var e=this.t;e!==void 0;e=e.x)e.t.N()}};ei.prototype.peek=function(){if(this.h()||Tu(),16&this.f)throw this.v;return this.v};Object.defineProperty(ei.prototype,"value",{get:function(){1&this.f&&Tu();var e=_w(this);if(this.h(),e!==void 0&&(e.i=this.i),16&this.f)throw this.v;return this.v}});function kw(e){var t=e.u;if(e.u=void 0,typeof t=="function"){Ti++;var n=Le;Le=void 0;try{t()}catch(r){throw e.f&=-2,e.f|=8,uh(e),r}finally{Le=n,lh()}}}function uh(e){for(var t=e.s;t!==void 0;t=t.n)t.S.U(t);e.x=void 0,e.s=void 0,kw(e)}function DA(e){if(Le!==this)throw new Error("Out-of-order effect");Ow(this),Le=e,this.f&=-2,8&this.f&&uh(this),lh()}function Ia(e){this.x=e,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}Ia.prototype.c=function(){var e=this.S();try{if(8&this.f||this.x===void 0)return;var t=this.x();typeof t=="function"&&(this.u=t)}finally{e()}};Ia.prototype.S=function(){1&this.f&&Tu(),this.f|=1,this.f&=-9,kw(this),Cw(this),Ti++;var e=Le;return Le=this,DA.bind(this,e)};Ia.prototype.N=function(){2&this.f||(this.f|=2,this.o=No,No=this)};Ia.prototype.d=function(){this.f|=8,1&this.f||uh(this)};function $A(e){var t=new Ia(e);try{t.c()}catch(n){throw t.d(),n}return t.d.bind(t)}var jA=class{constructor(e){te(this,"_state");te(this,"_prevState");this._prevState=e,this._state=TA(e)}setState(e){this._prevState=this._state.value,this._state.value=e}subscribe(e){return this._state.subscribe(t=>e(t,this._prevState))}};async function FA(e,t){let[{DotLottieStateMachineManager:n}]=await Promise.all([tn(()=>import("./dotlottie-state-machine-manager-DE27JEWO-HSSKNWU7-526baec8.js"),[])]);if(!e.length)throw se("No state machines available inside this .lottie!");return new n(e,t)}var RA={name:"@dotlottie/common",version:"0.6.0",type:"module",description:"",author:"Afsal , Sam Osborne ",license:"MIT",private:!0,engines:{node:">18.0.0"},module:"dist/index.js",types:"dist/index.d.ts",files:["dist"],keywords:[],scripts:{build:"tsup",dev:"tsup --watch",lint:"eslint .","type-check":"tsc --noEmit"},dependencies:{"@dotlottie/dotlottie-js":"0.6.0","@lottiefiles/relottie":"1.0.0","@lottiefiles/relottie-style":"0.4.1","@preact/signals-core":"^1.2.3",howler:"^2.2.3","lottie-web":"^5.12.2",xstate:"^4.38.1"},devDependencies:{"@lottiefiles/lottie-types":"^1.2.0","@types/howler":"^2.2.8",tsup:"^6.1.3",typescript:"^4.7.4"},publishConfig:{access:"restricted"}},ht=(e=>(e.Complete="complete",e.DataFail="data_fail",e.DataReady="data_ready",e.Error="error",e.Frame="frame",e.Freeze="freeze",e.LoopComplete="loopComplete",e.Pause="pause",e.Play="play",e.Ready="ready",e.Stop="stop",e.VisibilityChange="visibilityChange",e))(ht||{}),Dn=(e=>(e.Completed="completed",e.Error="error",e.Fetching="fetching",e.Frozen="frozen",e.Initial="initial",e.Loading="loading",e.Paused="paused",e.Playing="playing",e.Ready="ready",e.Stopped="stopped",e))(Dn||{}),NA=(e=>(e.Bounce="bounce",e.Normal="normal",e))(NA||{}),jt={autoplay:!1,direction:1,hover:!1,intermission:0,loop:!1,playMode:"normal",speed:1,defaultTheme:""},ch={activeStateId:"",autoplay:!1,currentState:"initial",frame:0,seeker:0,direction:1,hover:!1,loop:!1,playMode:"normal",speed:1,background:"transparent",intermission:0,currentAnimationId:void 0,visibilityPercentage:0},zA=class{constructor(e,t,n){te(this,"_lottie");te(this,"_src");te(this,"_animationConfig");te(this,"_prevUserPlaybackOptions",{});te(this,"_userPlaybackOptions");te(this,"_hover",!1);te(this,"_loop",!1);te(this,"_counter",0);te(this,"_intermission",0);te(this,"_counterInterval",null);te(this,"_container",null);te(this,"_name");te(this,"_mode","normal");te(this,"_background","transparent");te(this,"_animation");te(this,"_defaultTheme");te(this,"_activeAnimationId");te(this,"_currentAnimationId");te(this,"_testId");te(this,"_listeners",new Map);te(this,"_currentState","initial");te(this,"_stateBeforeFreeze","initial");te(this,"state",new jA(ch));te(this,"_light",!1);te(this,"_worker",!1);te(this,"_dotLottieLoader",new MA);te(this,"_activeStateId");te(this,"_inInteractiveMode",!1);te(this,"_scrollTicking",!1);te(this,"_scrollCallback");te(this,"_onShowIntersectionObserver");te(this,"_visibilityPercentage",0);te(this,"_audios",[]);te(this,"_stateMachineManager");this._src=structuredClone(e),n!=null&&n.testId&&(this._testId=n.testId),this._defaultTheme=(n==null?void 0:n.defaultTheme)||"",this._userPlaybackOptions=this._validatePlaybackOptions(n||{}),typeof(n==null?void 0:n.activeAnimationId)=="string"&&(this._activeAnimationId=n.activeAnimationId),this._container=t||null,typeof(n==null?void 0:n.background)=="string"&&this.setBackground(n.background),typeof(n==null?void 0:n.activeStateId)<"u"&&(this._activeStateId=n.activeStateId);let{rendererSettings:r,...i}=n||{};this._animationConfig={loop:!1,autoplay:!1,renderer:"svg",rendererSettings:{clearCanvas:!0,progressiveLoad:!0,hideOnTransparent:!0,filterSize:{width:"200%",height:"200%",x:"-50%",y:"-50%"},...r},...i},n!=null&&n.light&&(this._light=n.light),n!=null&&n.worker&&(this._worker=n.worker),this._listenToHover(),this._listenToVisibilityChange()}_listenToHover(){var n,r,i,o;let e=()=>{this._hover&&this.currentState!=="playing"&&this.play()},t=()=>{this._hover&&this.currentState==="playing"&&this.stop()};(n=this._container)==null||n.removeEventListener("mouseenter",e),(r=this._container)==null||r.removeEventListener("mouseleave",t),(i=this._container)==null||i.addEventListener("mouseleave",t),(o=this._container)==null||o.addEventListener("mouseenter",e)}_onVisibilityChange(){!this._lottie||typeof document>"u"||(document.hidden&&this.currentState==="playing"?this.freeze():this.currentState==="frozen"&&this.unfreeze())}_listenToVisibilityChange(){typeof document<"u"&&typeof document.hidden<"u"&&document.addEventListener("visibilitychange",()=>this._onVisibilityChange())}_getOption(e){var n;if(typeof this._userPlaybackOptions[e]<"u")return this._userPlaybackOptions[e];let t=(n=this._dotLottieLoader.manifest)==null?void 0:n.animations.find(r=>r.id===this._currentAnimationId);return t&&typeof t[e]<"u"?t[e]:jt[e]}_getPlaybackOptions(){let e={};for(let t in jt)typeof jt[t]<"u"&&(e[t]=this._getOption(t));return e}_setPlayerState(e){var n,r,i;let t=e(this._getPlaybackOptions());try{bw._parse(t)}catch{Me(`Invalid PlaybackOptions, ${JSON.stringify(t,null,2)}`);return}typeof t.defaultTheme<"u"&&(this._defaultTheme=t.defaultTheme),typeof t.playMode<"u"&&(this._mode=t.playMode),typeof t.intermission<"u"&&(this._intermission=t.intermission),typeof t.hover<"u"&&(this._hover=t.hover),typeof t.loop<"u"&&(this.clearCountTimer(),this._loop=t.loop,this._counter=0,(n=this._lottie)==null||n.setLoop(typeof t.loop=="number"?!0:t.loop)),typeof t.speed<"u"&&((r=this._lottie)==null||r.setSpeed(t.speed)),typeof t.autoplay<"u"&&this._lottie&&(this._lottie.autoplay=t.autoplay),typeof t.direction<"u"&&((i=this._lottie)==null||i.setDirection(t.direction))}_getOptionsFromAnimation(e){let{id:t,...n}=e;return{...jt,...n}}_updateTestData(){!this._testId||!this._lottie||(window.dotLottiePlayer||(window.dotLottiePlayer={[this._testId]:{}}),window.dotLottiePlayer[this._testId]={direction:this._lottie.playDirection,currentState:this._currentState,loop:this.loop,mode:this._mode,speed:this._lottie.playSpeed})}setContainer(e){e!==this._container&&(this._container=e,this.setBackground(this._background),this._listenToHover())}get currentState(){return this._currentState}clearCountTimer(){this._counterInterval&&clearInterval(this._counterInterval)}setCurrentState(e){this._currentState=e,this._notify(),this._updateTestData()}static isPathJSON(e){var t;return((t=e.split(".").pop())==null?void 0:t.toLowerCase())==="json"}get src(){return this._src}updateSrc(e){this._src!==e&&(this._src=structuredClone(e),this._activeAnimationId=void 0,this._currentAnimationId=void 0,this.load())}get intermission(){return this._intermission}get hover(){return this._hover}setHover(e){typeof e=="boolean"&&(this._hover=e,this._userPlaybackOptions.hover=e,this._notify())}setIntermission(e){this._intermission=e,this._userPlaybackOptions.intermission=e,this._notify()}get mode(){return this._mode}get animations(){return this._dotLottieLoader.animationsMap}get themes(){return this._dotLottieLoader.themeMap}setMode(e){typeof e=="string"&&(this._mode=e,this._userPlaybackOptions.playMode=e,this._setPlayerState(()=>({playMode:e})),this._notify(),this._updateTestData())}get container(){if(this._container)return this._container}goToAndPlay(e,t,n){if(!this._lottie||["loading"].includes(this._currentState)){Me("goToAndPlay() Can't use whilst loading.");return}this._lottie.goToAndPlay(e,t,n),this.setCurrentState("playing")}goToAndStop(e,t,n){if(!this._lottie||["loading"].includes(this._currentState)){Me("goToAndStop() Can't use whilst loading.");return}this._lottie.goToAndStop(e,t,n),this.setCurrentState("stopped")}seek(e){if(!this._lottie||["loading"].includes(this._currentState)){Me("seek() Can't use whilst loading.");return}let t=e;typeof t=="number"&&(t=Math.round(t));let n=/^(\d+)(%?)$/u.exec(t.toString());if(!n)return;let r=n[2]==="%"?this.totalFrames*Number(n[1])/100:n[1];r!==void 0&&(this._lottie.goToAndPlay(r,!0),this.currentState==="playing"?this.play():this.currentState==="frozen"?this.freeze():this.pause())}_areNumbersInRange(e,t){return e>=0&&e<=1&&t>=0&&t<=1}_updatePosition(e,t,n){let[r,i]=e??[0,this.totalFrames-1],[o,a]=t??[0,1];if(!this._areNumbersInRange(o,a)){ai("threshold values must be between 0 and 1");return}if(this.container){let{height:s,top:l}=this.container.getBoundingClientRect(),u=window.innerHeight-l,c=window.innerHeight+s,f=u/c,d=r+Math.round((f-o)/(a-o)*(i-r));n&&n(f),this.goToAndStop(d,!0),(d>=i||f>=a)&&this._handleAnimationComplete()}this._scrollTicking=!1}_requestTick(e,t,n){this._scrollTicking||(requestAnimationFrame(()=>this._updatePosition(e,t,n)),this._scrollTicking=!0)}playOnScroll(e){this.stop(),this._scrollCallback&&this.stopPlayOnScroll(),this._scrollCallback=()=>this._requestTick(e==null?void 0:e.segments,e==null?void 0:e.threshold,e==null?void 0:e.positionCallback),window.addEventListener("scroll",this._scrollCallback)}stopPlayOnScroll(){this._scrollCallback&&(window.removeEventListener("scroll",this._scrollCallback),this._scrollCallback=void 0)}stopPlayOnShow(){this._onShowIntersectionObserver&&(this._onShowIntersectionObserver.disconnect(),this._onShowIntersectionObserver=void 0)}addIntersectionObserver(e){if(!this.container)throw se("Can't play on show, player container element not available.");let t={root:null,rootMargin:"0px",threshold:e!=null&&e.threshold?e.threshold:[0,1]},n=r=>{r.forEach(i=>{var o,a;this._visibilityPercentage=i.intersectionRatio*100,i.isIntersecting?(e!=null&&e.callbackOnIntersect&&e.callbackOnIntersect(this._visibilityPercentage),(o=this._container)==null||o.dispatchEvent(new Event("visibilityChange"))):e!=null&&e.callbackOnIntersect&&(e.callbackOnIntersect(0),(a=this._container)==null||a.dispatchEvent(new Event("visibilityChange")))})};this._onShowIntersectionObserver=new IntersectionObserver(n,t),this._onShowIntersectionObserver.observe(this.container)}playOnShow(e){if(this.stop(),!this.container)throw se("Can't play on show, player container element not available.");this._onShowIntersectionObserver&&this.stopPlayOnShow(),this.addIntersectionObserver({threshold:(e==null?void 0:e.threshold)??[],callbackOnIntersect:t=>{t===0?this.pause():this.play()}})}_validatePlaybackOptions(e){if(!e)return{};let t={};for(let[n,r]of Object.entries(e))switch(n){case"autoplay":typeof r=="boolean"&&(t.autoplay=r);break;case"direction":typeof r=="number"&&[1,-1].includes(r)&&(t.direction=r);break;case"loop":(typeof r=="boolean"||typeof r=="number")&&(t.loop=r);break;case"playMode":typeof r=="string"&&["normal","bounce"].includes(r)&&(t.playMode=r);break;case"speed":typeof r=="number"&&(t.speed=r);break;case"themeColor":typeof r=="string"&&(t.themeColor=r);break;case"hover":typeof r=="boolean"&&(t.hover=r);break;case"intermission":typeof r=="number"&&(t.intermission=r);break;case"defaultTheme":typeof r=="string"&&(t.defaultTheme=r);break}return this._requireValidPlaybackOptions(t),t}_requireAnimationsInTheManifest(){var e;if(!((e=this._dotLottieLoader.manifest)!=null&&e.animations.length))throw se("No animations found in manifest.")}_requireAnimationsToBeLoaded(){if(this._dotLottieLoader.animationsMap.size===0)throw se("No animations have been loaded.")}async play(e,t){var n,r;if(["initial","loading"].includes(this._currentState)){Me("Player unable to play whilst loading.");return}if(this._requireAnimationsInTheManifest(),this._requireAnimationsToBeLoaded(),this._lottie&&!e){this._lottie.playDirection===-1&&this._lottie.currentFrame===0?this._lottie.goToAndPlay(this._lottie.totalFrames,!0):this._lottie.play(),this.setCurrentState("playing");return}if(typeof e=="number"){let i=(n=this._dotLottieLoader.manifest)==null?void 0:n.animations[e];if(!i)throw se("animation not found.");typeof t=="function"?await this.render({id:i.id,...t(this._getPlaybackOptions(),this._getOptionsFromAnimation(i))}):await this.render({id:i.id})}if(typeof e=="string"){let i=(r=this._dotLottieLoader.manifest)==null?void 0:r.animations.find(o=>o.id===e);if(!i)throw se("animation not found.");typeof t=="function"?await this.render({id:i.id,...t(this._getPlaybackOptions(),this._getOptionsFromAnimation(i))}):await this.render({id:i.id})}}playSegments(e,t){if(!this._lottie||["loading"].includes(this._currentState)){Me("playSegments() Can't use whilst loading.");return}this._lottie.playSegments(e,t),this.setCurrentState("playing")}resetSegments(e){if(!this._lottie||["loading"].includes(this._currentState)){Me("resetSegments() Can't use whilst loading.");return}this._lottie.resetSegments(e)}togglePlay(){this.currentState==="playing"?this.pause():this.play()}_getAnimationByIdOrIndex(e){var t,n;if(this._requireAnimationsInTheManifest(),this._requireAnimationsToBeLoaded(),typeof e=="number"){let r=(t=this._dotLottieLoader.manifest)==null?void 0:t.animations[e];if(!r)throw se("animation not found.");return r}if(typeof e=="string"){let r=(n=this._dotLottieLoader.manifest)==null?void 0:n.animations.find(i=>i.id===e);if(!r)throw se("animation not found.");return r}throw se("first param must be a number or string")}get activeAnimationId(){return this._getActiveAnimationId()}get currentAnimationId(){return this._currentAnimationId}get activeStateId(){return this._activeStateId}async _startInteractivity(e){if(!this._inInteractiveMode){ai("Can't start interactivity. Not in interactive mode. Call enterInteractiveMode(stateId: string) to start.");return}if(this._dotLottieLoader.stateMachinesMap.size===0&&await this._dotLottieLoader.getStateMachines(),this._dotLottieLoader.stateMachinesMap.size===0)throw se("No interactivity states are available.");if(e==="undefined")throw se("stateId is not specified.");this._stateMachineManager||(this._stateMachineManager=await FA(Array.from(this._dotLottieLoader.stateMachinesMap.values()),this)),this._stateMachineManager.start(e)}enterInteractiveMode(e){var t;if(e)this._inInteractiveMode||(this._prevUserPlaybackOptions={...this._userPlaybackOptions}),this._inInteractiveMode&&((t=this._stateMachineManager)==null||t.stop()),this._activeStateId=e,this._inInteractiveMode=!0,this._startInteractivity(e);else throw se("stateId must be a non-empty string.")}exitInteractiveMode(){var e;this._inInteractiveMode&&(this._inInteractiveMode=!1,this._activeStateId="",(e=this._stateMachineManager)==null||e.stop(),this._userPlaybackOptions={},this._userPlaybackOptions={...this._prevUserPlaybackOptions},this._prevUserPlaybackOptions={},this.reset())}reset(){var n;let e=this._getActiveAnimationId(),t=(n=this._dotLottieLoader.manifest)==null?void 0:n.animations.find(r=>r.id===e);if(this._inInteractiveMode&&this.exitInteractiveMode(),!t)throw se("animation not found.");this.play(e)}previous(e){if(!this._dotLottieLoader.manifest||!this._dotLottieLoader.manifest.animations.length)throw se("manifest not found.");if(this._inInteractiveMode){Me("previous() is not supported in interactive mode.");return}let t=this._dotLottieLoader.manifest.animations.findIndex(r=>r.id===this._currentAnimationId);if(t===-1)throw se("animation not found.");let n=this._dotLottieLoader.manifest.animations[(t-1+this._dotLottieLoader.manifest.animations.length)%this._dotLottieLoader.manifest.animations.length];if(!n||!n.id)throw se("animation not found.");typeof e=="function"?this.render({id:n.id,...e(this._getPlaybackOptions(),this._getOptionsFromAnimation(n))}):this.render({id:n.id})}next(e){if(!this._dotLottieLoader.manifest||!this._dotLottieLoader.manifest.animations.length)throw se("manifest not found.");if(this._inInteractiveMode){Me("next() is not supported in interactive mode.");return}let t=this._dotLottieLoader.manifest.animations.findIndex(r=>r.id===this._currentAnimationId);if(t===-1)throw se("animation not found.");let n=this._dotLottieLoader.manifest.animations[(t+1)%this._dotLottieLoader.manifest.animations.length];if(!n||!n.id)throw se("animation not found.");typeof e=="function"?this.render({id:n.id,...e(this._getPlaybackOptions(),this._getOptionsFromAnimation(n))}):this.render({id:n.id})}getManifest(){return this._dotLottieLoader.manifest}resize(){if(!this._lottie||["loading"].includes(this._currentState)){Me("resize() Can't use whilst loading.");return}this._lottie.resize()}stop(){if(!this._lottie||["loading"].includes(this._currentState)){Me("stop() Can't use whilst loading.");return}this.clearCountTimer(),this._counter=0,this._setPlayerState(()=>({direction:this._getOption("direction")})),this._lottie.stop(),this.setCurrentState("stopped")}pause(){if(!this._lottie||["loading"].includes(this._currentState)){Me("pause() Can't use whilst loading.");return}this.clearCountTimer(),this._lottie.pause(),this.setCurrentState("paused")}freeze(){if(!this._lottie||["loading"].includes(this._currentState)){Me("freeze() Can't use whilst loading.");return}this.currentState!=="frozen"&&(this._stateBeforeFreeze=this.currentState),this._lottie.pause(),this.setCurrentState("frozen")}unfreeze(){if(!this._lottie||["loading"].includes(this._currentState)){Me("unfreeze() Can't use whilst loading.");return}this._stateBeforeFreeze==="playing"?this.play():this.pause()}destroy(){var e,t;(e=this._container)!=null&&e.__lottie&&(this._container.__lottie.destroy(),this._container.__lottie=null),this._audios.length&&(this._audios.forEach(n=>{n.unload()}),this._audios=[]),this.clearCountTimer(),typeof document<"u"&&document.removeEventListener("visibilitychange",()=>this._onVisibilityChange()),this._counter=0,(t=this._lottie)==null||t.destroy()}getAnimationInstance(){return this._lottie}static getLottieWebVersion(){return`${RA.dependencies["lottie-web"]}`}addEventListener(e,t){var n,r,i;this._listeners.has(e)||this._listeners.set(e,new Set),(n=this._listeners.get(e))==null||n.add(t);try{e==="complete"?(r=this._container)==null||r.addEventListener(e,t):(i=this._lottie)==null||i.addEventListener(e,t)}catch(o){ai(`addEventListener ${o}`)}}getState(){var e,t,n;return{autoplay:((e=this._lottie)==null?void 0:e.autoplay)??!1,currentState:this._currentState,frame:this._frame,visibilityPercentage:this._visibilityPercentage,seeker:this._seeker,direction:((t=this._lottie)==null?void 0:t.playDirection)??1,hover:this._hover,loop:this._loop||!1,playMode:this._mode,speed:((n=this._lottie)==null?void 0:n.playSpeed)??1,background:this._background,intermission:this._intermission,defaultTheme:this._defaultTheme,currentAnimationId:this._currentAnimationId,activeStateId:this._activeStateId??""}}_notify(){this.state.setState(this.getState())}get totalFrames(){var e;return((e=this._lottie)==null?void 0:e.totalFrames)||0}get direction(){return this._lottie?this._lottie.playDirection:1}setDirection(e){this._requireValidDirection(e),this._setPlayerState(()=>({direction:e})),this._userPlaybackOptions.direction=e}get speed(){var e;return((e=this._lottie)==null?void 0:e.playSpeed)||1}setSpeed(e){this._requireValidSpeed(e),this._setPlayerState(()=>({speed:e})),this._userPlaybackOptions.speed=e}get autoplay(){var e;return((e=this._lottie)==null?void 0:e.autoplay)??!1}setAutoplay(e){if(this._requireValidAutoplay(e),!this._lottie||["loading"].includes(this._currentState)){Me("setAutoplay() Can't use whilst loading.");return}this._setPlayerState(()=>({autoplay:e})),this._userPlaybackOptions.autoplay=e}toggleAutoplay(){if(!this._lottie||["loading"].includes(this._currentState)){Me("toggleAutoplay() Can't use whilst loading.");return}this.setAutoplay(!this._lottie.autoplay)}get defaultTheme(){return this._defaultTheme}setDefaultTheme(e){this._setPlayerState(()=>({defaultTheme:e})),this._userPlaybackOptions.defaultTheme=e,this._animation&&this.render()}get loop(){return this._loop}setLoop(e){this._requireValidLoop(e),this._setPlayerState(()=>({loop:e})),this._userPlaybackOptions.loop=e}toggleLoop(){if(!this._lottie||["loading"].includes(this._currentState)){Me("toggleLoop() Can't use whilst loading.");return}this.setLoop(!this._loop)}get background(){return this._background}setBackground(e){this._requireValidBackground(e),this._background=e,this._container&&(this._container.style.backgroundColor=e)}get _frame(){return this._lottie?this.currentState==="completed"?this.direction===-1?0:this._lottie.totalFrames:this._lottie.currentFrame:0}get _seeker(){return this._lottie?this._frame/this._lottie.totalFrames*100:0}async revertToManifestValues(e){var r;let t;!Array.isArray(e)||e.length===0?t=["autoplay","defaultTheme","direction","hover","intermission","loop","playMode","speed","activeAnimationId"]:t=e;let n=!1;if(t.includes("activeAnimationId")){let i=(r=this._dotLottieLoader.manifest)==null?void 0:r.activeAnimationId,o=this._getAnimationByIdOrIndex(i||0);this._activeAnimationId=i,await this._setCurrentAnimation(o.id),n=!0}t.forEach(i=>{switch(i){case"autoplay":delete this._userPlaybackOptions.autoplay,this.setAutoplay(this._getOption("autoplay"));break;case"defaultTheme":delete this._userPlaybackOptions.defaultTheme,this.setDefaultTheme(this._getOption("defaultTheme"));break;case"direction":delete this._userPlaybackOptions.direction,this.setDirection(this._getOption("direction"));break;case"hover":delete this._userPlaybackOptions.hover,this.setHover(this._getOption("hover"));break;case"intermission":delete this._userPlaybackOptions.intermission,this.setIntermission(this._getOption("intermission"));break;case"loop":delete this._userPlaybackOptions.loop,this.setLoop(this._getOption("loop"));break;case"playMode":delete this._userPlaybackOptions.playMode,this.setMode(this._getOption("playMode")),this.setDirection(this._getOption("direction"));break;case"speed":delete this._userPlaybackOptions.speed,this.setSpeed(this._getOption("speed"));break}}),n&&this.render()}removeEventListener(e,t){var n,r,i;try{e==="complete"?(n=this._container)==null||n.removeEventListener(e,t):(r=this._lottie)==null||r.removeEventListener(e,t),(i=this._listeners.get(e))==null||i.delete(t)}catch(o){ai("removeEventListener",o)}}_handleAnimationComplete(){var t;typeof this._loop=="number"&&this.stop();let e=this.direction===-1?0:this.totalFrames;this.goToAndStop(e,!0),this._counter=0,this.clearCountTimer(),this.setCurrentState("completed"),(t=this._container)==null||t.dispatchEvent(new Event("complete"))}addEventListeners(){var e;if(!this._lottie||["loading"].includes(this._currentState)){Me("addEventListeners() Can't use whilst loading.");return}this._lottie.addEventListener("enterFrame",()=>{var t;if(!this._lottie){Me("enterFrame event : Lottie is undefined.");return}Math.floor(this._lottie.currentFrame)===0&&this.direction===-1&&((t=this._container)==null||t.dispatchEvent(new Event("complete")),this.loop||this.setCurrentState("completed")),this._notify()}),this._lottie.addEventListener("loopComplete",()=>{var r;if(!this._lottie){Me("loopComplete event : Lottie is undefined.");return}(r=this._container)==null||r.dispatchEvent(new Event("loopComplete")),this.intermission>0&&this.pause();let t=this._lottie.playDirection;if(typeof this._loop=="number"&&this._loop>0&&(this._counter+=this._mode==="bounce"?.5:1,this._counter>=this._loop)){this._handleAnimationComplete();return}this._mode==="bounce"&&typeof t=="number"&&(t=Number(t)*-1);let n=t===-1?this._lottie.totalFrames-1:0;this.intermission?(this.goToAndPlay(n,!0),this.pause(),this._counterInterval=window.setTimeout(()=>{this._lottie&&(this._setPlayerState(()=>({direction:t})),this.goToAndPlay(n,!0))},this._intermission)):(this._setPlayerState(()=>({direction:t})),this.goToAndPlay(t===-1?this.totalFrames-1:0,!0))}),this._lottie.addEventListener("complete",()=>{if(this._lottie&&this._loop===!1&&this._mode==="bounce"){if(this._counter+=.5,this._counter>=1){this._handleAnimationComplete();return}this._counterInterval=window.setTimeout(()=>{if(!this._lottie)return;let t=this._lottie.playDirection;this._mode==="bounce"&&typeof t=="number"&&(t=Number(t)*-1);let n=t===-1?this.totalFrames-1:0;this._setPlayerState(()=>({direction:t})),this.goToAndPlay(n,!0)},this._intermission)}else this._handleAnimationComplete()});for(let[t,n]of this._listeners)if(t==="complete")for(let r of n)(e=this._container)==null||e.addEventListener(t,r);else for(let r of n)this._lottie.addEventListener(t,r)}async _setCurrentAnimation(e){this._currentState="loading";let t=await this._dotLottieLoader.getAnimation(e);this._currentAnimationId=e,this._animation=t,this._currentState="ready"}async _getAudioFactory(){if(this._animation&&PA(this._animation)){let{DotLottieAudio:e}=await tn(()=>import("./dotlottie-audio-XNJDYXTA-f557bb12.js"),["assets/dotlottie-audio-XNJDYXTA-f557bb12.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]);return t=>{let n=new e({src:[t]});return this._audios.push(n),n}}return null}async render(e){if(e!=null&&e.id)await this._setCurrentAnimation(e.id);else if(!this._animation)throw se("no animation selected");let t=jt.loop,n=jt.autoplay,r=jt.playMode,i=jt.intermission,o=jt.hover,a=jt.direction,s=jt.speed,l=jt.defaultTheme;t=(e==null?void 0:e.loop)??this._getOption("loop"),n=(e==null?void 0:e.autoplay)??this._getOption("autoplay"),r=(e==null?void 0:e.playMode)??this._getOption("playMode"),i=(e==null?void 0:e.intermission)??this._getOption("intermission"),o=(e==null?void 0:e.hover)??this._getOption("hover"),a=(e==null?void 0:e.direction)??this._getOption("direction"),s=(e==null?void 0:e.speed)??this._getOption("speed"),l=(e==null?void 0:e.defaultTheme)??this._getOption("defaultTheme");let u={...this._animationConfig,autoplay:o?!1:n,loop:typeof t=="number"?!0:t,renderer:this._worker?"svg":this._animationConfig.renderer??"svg"},[c,f,d]=await Promise.all([this._dotLottieLoader.getTheme(l),this._getLottiePlayerInstance(),this._getAudioFactory()]);if(c&&this._animation?this._animation=await LA(this._animation,c):this._animation=await this._dotLottieLoader.getAnimation(this._currentAnimationId??""),this._activeStateId&&!this._inInteractiveMode){this.enterInteractiveMode(this._activeStateId);return}this.destroy(),this._setPlayerState(()=>({defaultTheme:l,playMode:r,intermission:i,hover:o,loop:t})),d?this._lottie=f.loadAnimation({...u,container:this._container,animationData:this._animation,audioFactory:d}):this._lottie=f.loadAnimation({...u,container:this._container,animationData:this._animation}),typeof this._lottie.resetSegments>"u"&&(this._lottie.resetSegments=()=>{var h;(h=this._lottie)==null||h.playSegments([0,this._lottie.totalFrames],!0)}),this.addEventListeners(),this._container&&(this._container.__lottie=this._lottie),this._setPlayerState(()=>({direction:a,speed:s})),n&&!o&&this.play(),this._updateTestData()}async _getLottiePlayerInstance(){let e=this._animationConfig.renderer??"svg",t;if(this._worker)return e!=="svg"&&Me("Worker is only supported with svg renderer. Change or remove renderer prop to get rid of this warning."),t=await tn(()=>import("./lottie_worker-WHOD5EO7-VF575QIV-6e8b61e9.js"),["assets/lottie_worker-WHOD5EO7-VF575QIV-6e8b61e9.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]),t.default;switch(e){case"svg":{this._light?t=await tn(()=>import("./lottie_light-IOYK46WR-C42PZIWW-842cd67b.js"),["assets/lottie_light-IOYK46WR-C42PZIWW-842cd67b.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]):t=await tn(()=>import("./lottie_svg-NPHRPZVQ-SN5HKEBW-b354eb1e.js"),["assets/lottie_svg-NPHRPZVQ-SN5HKEBW-b354eb1e.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]);break}case"canvas":{this._light?t=await tn(()=>import("./lottie_light_canvas-JOJMVDMY-Y3JQKMNA-129b1fdc.js"),["assets/lottie_light_canvas-JOJMVDMY-Y3JQKMNA-129b1fdc.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]):t=await tn(()=>import("./lottie_canvas-MBHU2YSW-VFQ5A67K-34d36756.js"),["assets/lottie_canvas-MBHU2YSW-VFQ5A67K-34d36756.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]);break}case"html":{this._light?t=await tn(()=>import("./lottie_light_html-QXO6XUZK-N4R277UW-62a905c2.js"),["assets/lottie_light_html-QXO6XUZK-N4R277UW-62a905c2.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]):t=await tn(()=>import("./lottie_html-DEQZ7JWN-7UJDZM6D-84fdb830.js"),["assets/lottie_html-DEQZ7JWN-7UJDZM6D-84fdb830.js","assets/chunk-M2BEWT7H-2d4e7f2d.js"]);break}default:throw new Error(`Invalid renderer: ${e}`)}return t.default}_getActiveAnimationId(){var t;let e=this._dotLottieLoader.manifest;return this._activeAnimationId??(e==null?void 0:e.activeAnimationId)??((t=e==null?void 0:e.animations[0])==null?void 0:t.id)??void 0}async load(e){if(this._currentState==="loading"){Me("Loading in progress..");return}try{if(this.setCurrentState("loading"),typeof this._src=="string")if(IA(this._src)){let n=JSON.parse(this._src);this._dotLottieLoader.loadFromLottieJSON(n)}else{let n=new URL(this._src,window.location.href);await this._dotLottieLoader.loadFromUrl(n.toString())}else if(typeof this._src=="object"&&Dl(this._src))this._dotLottieLoader.loadFromLottieJSON(this._src);else throw se("Invalid src provided");if(!this._dotLottieLoader.manifest)throw se("No manifest found");let t=this._getActiveAnimationId();if(!t)throw se("No active animation found");await this._setCurrentAnimation(t),await this.render(e)}catch(t){this.setCurrentState("error"),t instanceof Error&&ai(`Error loading animation: ${t.message}`)}}setErrorState(e){this.setCurrentState("error"),ai(e)}_requireValidDirection(e){if(e!==-1&&e!==1)throw se("Direction can only be -1 (backwards) or 1 (forwards)")}_requireValidIntermission(e){if(e<0||!Number.isInteger(e))throw se("intermission must be a positive number")}_requireValidLoop(e){if(typeof e=="number"&&(!Number.isInteger(e)||e<0))throw se("loop must be a positive number or boolean")}_requireValidSpeed(e){if(typeof e!="number")throw se("speed must be a number")}_requireValidBackground(e){if(typeof e!="string")throw se("background must be a string")}_requireValidAutoplay(e){if(typeof e!="boolean")throw se("autoplay must be a boolean")}_requireValidPlaybackOptions(e){e.direction&&this._requireValidDirection(e.direction),e.intermission&&this._requireValidIntermission(e.intermission),e.loop&&this._requireValidLoop(e.loop),e.speed&&this._requireValidSpeed(e.speed)}};function VA(){var e=b.useRef(!0);return e.current?(e.current=!1,!0):e.current}var BA=function(e,t){var n=VA();b.useEffect(function(){if(!n)return e()},t)},Ft=BA,UA=function(){};function Aw(e){for(var t=[],n=1;n{let e=b.useContext(Iw);if(typeof e>"u")throw se("useDotLottieContext must be used within a DotLottieProvider");return e},Lw=(e,t,n)=>{let[r,i]=b.useState(()=>n());return b.useEffect(()=>{let o=e(()=>{let a=t();i(a)});return()=>{o()}},[e]),r},t7=()=>{};function Or(e){let t=Mw(),n=b.useCallback(()=>{if(t!==null)return e(t.getState())},[e,t]),r=b.useCallback(i=>t===null?t7:t.state.subscribe(i),[t]);return Lw(r,n,()=>e(ch))}var n7=e=>O.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:[O.jsx("path",{d:"M8.33325 11.6667C7.78097 11.6667 7.33325 12.1144 7.33325 12.6667C7.33325 13.2189 7.78097 13.6667 8.33325 13.6667C8.88554 13.6667 9.33325 13.2189 9.33325 12.6667C9.33325 12.1144 8.88554 11.6667 8.33325 11.6667Z",fill:"currentColor"}),O.jsx("path",{d:"M7.33325 8C7.33325 7.44771 7.78097 7 8.33325 7C8.88554 7 9.33325 7.44771 9.33325 8C9.33325 8.55228 8.88554 9 8.33325 9C7.78097 9 7.33325 8.55228 7.33325 8Z",fill:"currentColor"}),O.jsx("path",{d:"M7.33325 3.33333C7.33325 2.78105 7.78097 2.33333 8.33325 2.33333C8.88554 2.33333 9.33325 2.78105 9.33325 3.33333C9.33325 3.88562 8.88554 4.33333 8.33325 4.33333C7.78097 4.33333 7.33325 3.88562 7.33325 3.33333Z",fill:"currentColor"})]}),r7=e=>O.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:[O.jsx("path",{d:"M10.8654 2.31311C11.0607 2.11785 11.3772 2.11785 11.5725 2.31311L13.4581 4.19873C13.6534 4.39399 13.6534 4.71058 13.4581 4.90584L11.5725 6.79146C11.3772 6.98672 11.0607 6.98672 10.8654 6.79146C10.6701 6.5962 10.6701 6.27961 10.8654 6.08435L11.6162 5.33354H4V6.66687C4 7.03506 3.70152 7.33354 3.33333 7.33354C2.96514 7.33354 2.66666 7.03506 2.66666 6.66687L2.66666 4.66687C2.66666 4.29868 2.96514 4.0002 3.33333 4.0002H11.8454L10.8654 3.02022C10.6701 2.82496 10.6701 2.50838 10.8654 2.31311Z",fill:"currentColor"}),O.jsx("path",{d:"M12.4375 11.9998C12.8057 11.9998 13.1042 11.7013 13.1042 11.3331V9.33313C13.1042 8.96494 12.8057 8.66647 12.4375 8.66647C12.0693 8.66647 11.7708 8.96494 11.7708 9.33313V10.6665H4.15462L4.90543 9.91565C5.10069 9.72039 5.10069 9.40381 4.90543 9.20854C4.71017 9.01328 4.39359 9.01328 4.19832 9.20854L2.31271 11.0942C2.11744 11.2894 2.11744 11.606 2.31271 11.8013L4.19832 13.6869C4.39359 13.8821 4.71017 13.8821 4.90543 13.6869C5.10069 13.4916 5.10069 13.175 4.90543 12.9798L3.92545 11.9998H12.4375Z",fill:"currentColor"})]}),i7=e=>O.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M14.3336 2.5C14.3336 2.22386 14.1097 2 13.8336 2C13.5574 2 13.3336 2.22386 13.3336 2.5V13.5C13.3336 13.7761 13.5574 14 13.8336 14C14.1097 14 14.3336 13.7761 14.3336 13.5V2.5ZM3.50618 2.21722C2.83954 1.82595 2 2.30667 2 3.07965V12.9201C2 13.6931 2.83954 14.1738 3.50618 13.7825L11.8893 8.86231C12.5477 8.47586 12.5477 7.52389 11.8893 7.13745L3.50618 2.21722Z",fill:"currentColor"})}),o7=e=>O.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:[O.jsx("path",{d:"M3.99996 2C3.26358 2 2.66663 2.59695 2.66663 3.33333V12.6667C2.66663 13.403 3.26358 14 3.99996 14H5.33329C6.06967 14 6.66663 13.403 6.66663 12.6667V3.33333C6.66663 2.59695 6.06967 2 5.33329 2H3.99996Z",fill:"currentColor"}),O.jsx("path",{d:"M10.6666 2C9.93025 2 9.33329 2.59695 9.33329 3.33333V12.6667C9.33329 13.403 9.93025 14 10.6666 14H12C12.7363 14 13.3333 13.403 13.3333 12.6667V3.33333C13.3333 2.59695 12.7363 2 12 2H10.6666Z",fill:"currentColor"})]}),a7=e=>O.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{d:"M3.33337 3.46787C3.33337 2.52312 4.35948 1.93558 5.17426 2.41379L12.8961 6.94592C13.7009 7.41824 13.7009 8.58176 12.8961 9.05408L5.17426 13.5862C4.35948 14.0644 3.33337 13.4769 3.33337 12.5321V3.46787Z",fill:"currentColor"})}),s7=e=>O.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M1.69214 13.5C1.69214 13.7761 1.916 14 2.19214 14C2.46828 14 2.69214 13.7761 2.69214 13.5L2.69214 2.5C2.69214 2.22386 2.46828 2 2.19214 2C1.916 2 1.69214 2.22386 1.69214 2.5V13.5ZM12.5192 13.7828C13.1859 14.174 14.0254 13.6933 14.0254 12.9204L14.0254 3.0799C14.0254 2.30692 13.1859 1.8262 12.5192 2.21747L4.13612 7.13769C3.47769 7.52414 3.47769 8.4761 4.13612 8.86255L12.5192 13.7828Z",fill:"currentColor"})}),l7=e=>O.jsx("svg",{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M13.5303 6.46967C13.8232 6.76256 13.8232 7.23744 13.5303 7.53033L9.06066 12L13.5303 16.4697C13.8232 16.7626 13.8232 17.2374 13.5303 17.5303C13.2374 17.8232 12.7626 17.8232 12.4697 17.5303L7.46967 12.5303C7.17678 12.2374 7.17678 11.7626 7.46967 11.4697L12.4697 6.46967C12.7626 6.17678 13.2374 6.17678 13.5303 6.46967Z",fill:"currentColor"})}),u7=e=>O.jsx("svg",{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M10.4697 17.5303C10.1768 17.2374 10.1768 16.7626 10.4697 16.4697L14.9393 12L10.4697 7.53033C10.1768 7.23744 10.1768 6.76256 10.4697 6.46967C10.7626 6.17678 11.2374 6.17678 11.5303 6.46967L16.5303 11.4697C16.8232 11.7626 16.8232 12.2374 16.5303 12.5303L11.5303 17.5303C11.2374 17.8232 10.7626 17.8232 10.4697 17.5303Z",fill:"currentColor"})}),c7=({children:e,enableReset:t,expand:n=!1,onBack:r,onExpand:i,onReset:o,title:a})=>{let s=b.useCallback(()=>{r()},[r]),l=b.useCallback(()=>{i()},[i]),u=b.useCallback(()=>{o()},[o]);return O.jsxs(O.Fragment,{children:[!n&&O.jsxs("button",{className:"popover-item","aria-label":`Go to ${a}`,onClick:l,children:[O.jsx("span",{style:{flex:1},children:a}),O.jsx("span",{children:O.jsx(u7,{})})]}),n&&O.jsxs("div",{className:"popover-submenu",children:[O.jsxs("div",{className:"popover-header",children:[O.jsx("button",{onClick:s,children:O.jsx(l7,{})}),O.jsxs("div",{className:"popover-header-title",style:{flex:1},children:[O.jsx("span",{children:a}),t&&O.jsx("button",{className:"reset-theme",onClick:u,"aria-label":`Reset ${a}`,children:"Reset"})]})]}),e]})]})},f7=e=>O.jsx("svg",{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M20.5283 5.9372C20.8211 6.23009 20.8211 6.70497 20.5283 6.99786L9.4631 18.063C9.32181 18.2043 9.12997 18.2833 8.93016 18.2826C8.73035 18.2819 8.53907 18.2015 8.39877 18.0593L3.46807 13.0596C3.17722 12.7647 3.18052 12.2898 3.47544 11.999C3.77036 11.7081 4.24522 11.7114 4.53608 12.0063L8.93646 16.4683L19.4676 5.9372C19.7605 5.64431 20.2354 5.64431 20.5283 5.9372Z",fill:"currentColor"})}),d7=({onSelectItem:e,selected:t=!1,value:n,...r})=>{let i=b.useCallback(()=>{e==null||e(n)},[e,n]);return O.jsxs("button",{"aria-label":`Select ${n}`,className:`popover-item ${t?"selected":""}`,onClick:i,...r,children:[O.jsx("span",{style:{visibility:t?"visible":"hidden"},children:O.jsx(f7,{})}),O.jsx("span",{style:{flex:1},children:n})]})},p7=({items:e=[],onSelectItem:t,onDismiss:n,...r})=>{let[i,o]=b.useState(""),a=b.useRef(null);KA(a,()=>{o(""),n()}),XA("Escape",()=>{o(""),n()});let s=b.useCallback(()=>{o("")},[o]),l=b.useCallback(c=>()=>o(c),[o]),u=b.useCallback((c,f)=>()=>t(c,f),[t]);return O.jsx("dialog",{ref:a,style:{padding:i?"0px":"8px"},className:"popover","aria-label":"Popover Menu",...r,children:O.jsx("ul",{"aria-label":"Popover content",className:"popover-content",children:e.map(c=>O.jsx("li",{style:{width:"100%"},children:(i===c.title||!i)&&O.jsx(c7,{expand:i===c.title,title:c.title,onExpand:l(c.title),onBack:s,enableReset:c.enableReset,onReset:u(c.title,""),children:O.jsx("ul",{className:"popover-items","aria-label":`List of ${c.title}`,children:c.items.map(f=>O.jsx("li",{children:O.jsx(d7,{value:f.value,selected:f.selected,onSelectItem:u(c.title,f.value)})},f.value))})})},c.title))})})},h7=["play","stop","loop","next","previous","animations","themes"],m7=({buttons:e=h7,...t})=>{let n=Mw(),r=Or(M=>M.loop),i=Or(M=>M.currentState),o=Or(M=>M.seeker),a=Or(M=>M.currentAnimationId),s=Or(M=>M.defaultTheme),l=Or(M=>M.direction),u=Or(M=>M.activeStateId),c=b.useMemo(()=>i===Dn.Playing,[i]),[f,d]=b.useState(!1),[h,y]=b.useState([]),[m,w]=b.useState([]),[p,v]=b.useState([]),g=b.useMemo(()=>{let M=[],D=h.map(R=>({value:R.id,selected:a===R.id})),A=m.filter(R=>R.animations.includes(a||"")).map(R=>({value:R.id,selected:s===R.id})),I=p.map(R=>({value:R,selected:u===R}));return Array.isArray(D)&&D.length!==0&&M.push({title:"Animations",items:D,enableReset:!1}),Array.isArray(I)&&I.length!==0&&M.push({title:"States",items:I,enableReset:!0}),Array.isArray(A)&&A.length!==0&&M.push({title:"Themes",items:A,enableReset:!!s}),M},[h,m,a,s,p,u]),S=b.useMemo(()=>e.includes("themes")&&Array.isArray(m)&&m.length?!0:e.includes("animations")&&Array.isArray(h)&&h.length>1,[g]),E=b.useCallback(()=>{d(!f)},[d]),x=b.useCallback(()=>{d(!1)},[d]),_=b.useCallback(()=>{n==null||n.toggleLoop()},[n]),C=b.useCallback(()=>{n==null||n.freeze()},[n]),k=b.useCallback(()=>{n==null||n.unfreeze()},[n]),P=b.useCallback(()=>{n==null||n.next()},[n]),$=b.useCallback(()=>{n==null||n.previous()},[n]),F=b.useCallback(()=>{n==null||n.togglePlay()},[n]),H=b.useCallback((M,D)=>{M==="Animations"&&(n==null||n.play(D)),M==="Themes"&&(n==null||n.setDefaultTheme(D)),M==="States"&&(D?n==null||n.enterInteractiveMode(D):n==null||n.exitInteractiveMode())},[n]),j=b.useCallback(M=>{n==null||n.seek(String(M.currentTarget.value).concat("%"))},[n]);function L(){var I,R,N;let M=(I=n==null?void 0:n.getManifest())==null?void 0:I.animations,D=(R=n==null?void 0:n.getManifest())==null?void 0:R.themes,A=(N=n==null?void 0:n.getManifest())==null?void 0:N.states;M&&y(M),D&&w(D),A&&v(A)}return b.useEffect(()=>{if(!(typeof n>"u"))return n==null||n.addEventListener("DOMLoaded",L),()=>{n==null||n.removeEventListener("DOMLoaded",L)}},[n]),O.jsxs("div",{"aria-label":"lottie-animation-controls",className:"toolbar",...t,children:[e.includes("previous")&&h.length>1&&O.jsx("button",{onClick:$,"aria-label":"play-previous",children:O.jsx(s7,{})}),e.includes("play")&&O.jsx("button",{onClick:F,"aria-label":"play-pause",children:c?O.jsx(o7,{}):O.jsx(a7,{})}),e.includes("next")&&h.length>1&&O.jsx("button",{onClick:P,"aria-label":"play-next",children:O.jsx(i7,{})}),O.jsx("input",{style:{width:"100%","--seeker":o},className:`seeker ${l===1?"":"to-left"}`,type:"range",min:0,step:0,max:100,value:o||0,onInput:j,onMouseDown:C,onMouseUp:k,"aria-valuemin":1,"aria-valuemax":100,role:"slider","aria-valuenow":o,"aria-label":"lottie-seek-input"}),e.includes("loop")&&O.jsx("button",{onClick:_,className:r?"active":"","aria-label":"loop-toggle",children:O.jsx(r7,{})}),S&&O.jsxs("div",{style:{position:"relative"},children:[O.jsx(p7,{items:g,open:f,onDismiss:x,onSelectItem:H}),O.jsx("button",{className:`${f?"popover-active":""}`,"aria-label":"open-popover",onClick:E,children:O.jsx(n7,{})})]})]})},v7=(e,t,n)=>{let[r]=b.useState(()=>new zA(e,t.current,n)),i=b.useRef(!1);return b.useLayoutEffect(()=>{async function o(){!i.current&&t.current&&(i.current=!0,r.setContainer(t.current),await r.load())}return o(),()=>{i.current&&r.destroy()}},[r]),r};function ps(e,t){let n=b.useCallback(()=>t(e.getState()),[t,e]),r=b.useCallback(i=>e.state.subscribe(i),[e]);return Lw(r,n,()=>t(ch))}var g7=ee.forwardRef(({onEvent:e,activeAnimationId:t,autoplay:n,background:r="transparent",direction:i,intermission:o,loop:a,playMode:s,hover:l,speed:u,renderer:c="svg",rendererSettings:f={},src:d,className:h="",testId:y,children:m,defaultTheme:w,light:p=!1,worker:v=!1,activeStateId:g,lottieRef:S,...E},x)=>{let _=b.useRef(null),C=v7(d,_,{renderer:c,activeAnimationId:t,rendererSettings:{clearCanvas:!0,progressiveLoad:!1,hideOnTransparent:!0,...f},hover:l,loop:a,direction:i,speed:u,intermission:o,background:r,playMode:s,autoplay:l?!1:n,testId:y,defaultTheme:w,light:p,worker:v,activeStateId:g}),k=b.useRef(C);k.current=C,ee.useImperativeHandle(x,()=>C,[C]),ee.useImperativeHandle(S,()=>C,[C]);let P=ps(C,j=>j.currentState),$=ps(C,j=>j.frame),F=ps(C,j=>j.seeker),H=ps(C,j=>j.currentAnimationId);return Ft(()=>{typeof a>"u"?k.current.revertToManifestValues(["loop"]):k.current.setLoop(a)},[a]),Ft(()=>{typeof n>"u"?k.current.revertToManifestValues(["autoplay"]):k.current.setAutoplay(n)},[n]),Ft(()=>{typeof i>"u"?k.current.revertToManifestValues(["direction"]):k.current.setDirection(i)},[i]),Ft(()=>{typeof u>"u"?k.current.revertToManifestValues(["speed"]):k.current.setSpeed(u)},[u]),Ft(()=>{typeof s>"u"?k.current.revertToManifestValues(["playMode"]):k.current.setMode(s)},[s]),Ft(()=>{typeof l>"u"?k.current.revertToManifestValues(["hover"]):k.current.setHover(l)},[l]),Ft(()=>{typeof r>"u"?k.current.setBackground("transparent"):k.current.setBackground(r)},[r]),Ft(()=>{typeof o>"u"?k.current.revertToManifestValues(["intermission"]):k.current.setIntermission(o)},[o]),Ft(()=>{typeof w>"u"||!w?k.current.revertToManifestValues(["defaultTheme"]):k.current.setDefaultTheme(w)},[w]),Ft(()=>{t&&k.current.play(t)},[t]),Ft(()=>(typeof g<"u"&&k.current.enterInteractiveMode(g),()=>{k.current.exitInteractiveMode()}),[g]),Ft(()=>{typeof d<"u"&&k.current.updateSrc(d)},[d]),b.useEffect(()=>{let j=()=>{e==null||e(ht.Ready)},L=()=>{e==null||e(ht.DataReady)},M=()=>{e==null||e(ht.DataFail)},D=()=>{k.current.currentState!==Dn.Playing&&(e==null||e(ht.Complete))},A=()=>{e==null||e(ht.LoopComplete)};k.current.addEventListener("DOMLoaded",j),k.current.addEventListener("data_ready",L),k.current.addEventListener("data_failed",M),k.current.addEventListener("complete",D),k.current.addEventListener("loopComplete",A)},[]),b.useEffect(()=>{switch(P){case Dn.Stopped:e==null||e(ht.Stop);break;case Dn.Paused:e==null||e(ht.Pause);break;case Dn.Playing:e==null||e(ht.Play);break;case Dn.Frozen:e==null||e(ht.Freeze);break;case Dn.Error:e==null||e(ht.Error);break}},[P]),b.useEffect(()=>{e==null||e(ht.Frame,{frame:$,seeker:F})},[$]),O.jsx(e7,{value:C,children:O.jsxs("div",{className:`dotlottie-container main ${m?"controls":""} ${h}`,lang:"en",...y&&{"data-testid":y},...E,children:[O.jsx("div",{ref:_,"data-name":`${H}`,role:"figure",className:`animation ${m?"controls":""}`,style:{position:"relative"},...y&&{"data-testid":"animation"},children:P===Dn.Error&&O.jsx("div",{...y&&{"data-testid":"error"},className:"error",children:"⚠️"})}),m]})})});const y7=({activeAnimationId:e})=>{const t=b.useRef(),n=Fe(d=>d.playground.playerUrl),[r,i]=b.useState([]),[o,a]=b.useState(""),[s,l]=b.useState(0),u=b.useCallback((d,h)=>{var m,w,p;if(d===ht.Ready){const v=(w=(m=t.current)==null?void 0:m.getManifest())==null?void 0:w.states;i(v||[])}if(d===ht.Frame){const{frame:v}=h;l(Math.floor(v))}const y=(p=t.current)==null?void 0:p.getState();y&&a(y.activeStateId||"")},[t]),c=b.useCallback(()=>()=>{t.current&&t.current.exitInteractiveMode()},[t]),f=b.useCallback(d=>()=>{t.current&&t.current.enterInteractiveMode(d)},[t]);if(n)return O.jsx("div",{children:O.jsxs(O.Fragment,{children:[O.jsx(g7,{activeAnimationId:e||void 0,background:"white",onEvent:u,ref:t,src:n,children:O.jsxs("div",{className:"bg-white",children:[O.jsx(m7,{}),O.jsx("div",{className:"px-3 pb-1",children:O.jsxs("span",{className:"bg-gray-300 rounded px-2",children:["# ",O.jsx("span",{children:s})]})})]})}),O.jsx("div",{className:"flex flex-wrap gap-2 p-2 text-white",children:O.jsxs("div",{className:"text-white",children:[O.jsxs("div",{className:"mb-2 flex gap-2",children:[O.jsx("span",{children:"Interactivity states:"}),O.jsx(Cl,{disabled:!o,color:"red",onClick:c(),children:"Exit Interactivity"})]}),O.jsx("div",{className:"flex flex-wrap gap-2",children:r.map(d=>O.jsx(Cl,{color:o===d?"green":"blue",onClick:f(d),children:d},d))})]})})]})})};const w7=({file:e,fileName:t})=>{const n=ku(),r=b.useRef(),i=Fe(T=>T.animations.list),o=Fe(T=>T.themes.list),a=Fe(T=>T.states.list),{addDotLottieAnimation:s,addDotLottieStateMachine:l,addDotLottieTheme:u,buildAndUpdateUrl:c,dotLottie:f,downloadDotLottie:d,fetchAndUpdateDotLottie:h,removeDotLottieAnimation:y,removeDotLottieState:m,removeDotLottieTheme:w,setDotLottie:p}=Wp(),v=Fe(T=>{var z;return(z=T.editor.file)==null?void 0:z.content}),g=Fe(T=>{var z;return((z=T.editor.file)==null?void 0:z.type)||"json"}),S=Fe(T=>T.editor.animationId),E=Fe(T=>T.playground.workingFileName),x=b.useCallback(async(T,z)=>{let U,W="";if(T instanceof File?(U=await T.arrayBuffer(),W=T.name):(U=T,W=z||"new_awesome"),typeof U<"u")try{const X=await f.fromArrayBuffer(U);n(Ms()),n(os(W)),p(X)}catch(X){me(X.message,{type:"error"})}},[os,p]),_=b.useCallback(T=>{const z=T[0];typeof z>"u"||x(z)},[x]);b.useEffect(()=>{x(e,t)},[x]);const C=Fe(T=>T.editor.validationStatus),k=Fe(T=>{var z;return(z=T.editor.file)==null?void 0:z.name}),P=Fe(T=>{var z;return(z=T.editor.file)==null?void 0:z.path}),$=b.useCallback(T=>{C&&T&&n(xl(T))},[C,n]),F=Fe(T=>T.editor.updated),H=b.useCallback(()=>{var U;if(!C||!k)return;const T=(U=r.current)==null?void 0:U.getValue();let z;if(T){switch(P){case"States":if(z=JSON.parse(T),T&&k){const W=z.descriptor.id;l(z,k),n(Cv({name:W}))}break;case"Themes":k&&u(T,k);break}n(xl(!1))}},[C,k,n,P]);function j(T){r.current=T}b.useEffect(()=>{f.animations.length&&(h(),c())},[f,c,h]);const L=b.useCallback(async(T,z)=>{var X,oe;n(Ms());let U,W=!1;switch(T){case"States":U=(X=f.getStateMachine(z))==null?void 0:X.toString();break;case"Themes":U=await((oe=f.getTheme(z))==null?void 0:oe.toString()),W=!0;break}U&&n(Cv({name:z,type:W?"css":"json",path:T,content:W?U:a6(U)}))},[f,n]),M=b.useCallback(T=>{if(T.some(U=>U.severity===8)){n(Ov(!1));return}n(Ov(!0))},[n]),D=b.useCallback((T,z)=>{switch(T){case"States":m(z);break;case"Animations":y(z);break;case"Themes":w(z);break}(k===z||S===z)&&n(Ms())},[f,n,k,S]),A=b.useCallback(async(T,z)=>{const U=cd(z.name).replace(/(.json|.lss)/gu,"");let W;switch(T){case"States":W=JSON.parse(await z.text()),l(W);break;case"Animations":W=JSON.parse(await z.text()),s(W,U);break;case"Themes":W=await z.text(),u(W,z.name);break}},[f]),I=b.useCallback(()=>{h(),c()},[h,c]),R=b.useCallback(async(T,z)=>{const U=cd(z).replace(/(.json|.lss)/gu,"");let W;switch(T){case"States":W=s6(),W.descriptor.id=U,l(W);break;case"Themes":u("/* Make your animations colorful */",U);break}},[f]),N=b.useCallback((T,z)=>{n(c6(z.replace(/.json/gu,"")))},[n]),V=b.useCallback(T=>{n(os(T))},[os,n]);return O.jsxs("div",{className:"h-full flex flex-col",children:[O.jsxs("div",{className:"w-full bg-dark p-2 flex gap-2 justify-end",children:[O.jsx(ia,{onDrop:_,accept:"lottie",children:T=>O.jsxs(Cl,{...T.getRootProps(),children:[O.jsx("input",{...T.getInputProps()}),"Start Over"]})}),O.jsx("div",{className:"flex-1 flex justify-center items-center text-gray-400 text-sm",children:O.jsx(d6,{title:E,onChange:V})}),O.jsx(Cl,{onClick:d,children:"Download"})]}),O.jsx("div",{className:"flex grow border-t border-gray-600 flex-1 max-h-[calc(100vh-2.9rem)]",children:O.jsxs(My,{autoSaveId:"dotlottie-playground",direction:"horizontal",className:"h-full",children:[O.jsx(ks,{defaultSize:10,maxSize:40,className:"bg-dark",children:O.jsxs("section",{className:"flex flex-col h-full",children:[O.jsx($c,{className:"flex-1 h-1/3",title:"Animations",files:i,onClick:N,onRemove:D,onUpload:A}),O.jsx($c,{className:"flex-1 h-1/3",title:"States",files:a,onClick:L,onRemove:D,onUpload:A,onAddNew:R}),O.jsx($c,{className:"flex-1 h-1/3",title:"Themes",files:o,onClick:L,onRemove:D,onUpload:A,onAddNew:R})]})}),O.jsx(Gf,{className:"bg-gray-500 w-1"}),O.jsx(ks,{children:O.jsx(ia,{onDrop:_,accept:"lottie",noClick:!0,children:T=>O.jsxs("div",{className:"flex flex-col w-full h-full relative",...T.getRootProps(),children:[O.jsx("input",{...T.getInputProps()}),T.isDragActive&&O.jsx("div",{className:"absolute z-10 inset-0 bg-gray-500 opacity-80 flex justify-center items-center text-white text-3xl",children:"Drop your .lottie here"}),S&&O.jsx(mk,{onUpdate:I}),v&&O.jsxs("div",{className:"h-full flex flex-col",children:[O.jsxs("div",{className:"flex justify-between items-stretch pr-4 flex-shrink border-b border-gray-600",children:[O.jsx("span",{className:"text-white text-sm border-b border-b-blue-500 border-r border-gray-600 px-4 flex items-center",children:k}),O.jsx("button",{title:"Save",className:"text-gray-400 py-1 hover:text-white disabled:text-gray-700",onClick:H,disabled:!F,children:O.jsx(gy,{size:33})})]}),O.jsx(g4,{className:"flex-1 max-h-[calc(100vh-5.5rem)]",language:g,width:"100%",theme:"vs-dark",options:{fontSize:15,formatOnPaste:!0,formatOnType:!0,minimap:{enabled:!1}},loading:"Loading...",value:v,onChange:$,onMount:j,onValidate:M})]})]})})}),O.jsx(Gf,{className:"bg-gray-500 w-1"}),O.jsx(ks,{defaultSize:25,children:O.jsx(y7,{activeAnimationId:S})})]})})]})},S7=[{name:"toggle.lottie",path:"/player-component/toggle.lottie"},{name:"interactivity_example.lottie",path:"/player-component/interactivity_example.lottie"},{name:"aniki_hamster.lottie",path:"/player-component/aniki_hamster.lottie"}],b7=({onStart:e})=>{const t=b.useCallback(async(o,a)=>{let s,l="";o instanceof File?(s=await o.arrayBuffer(),l=o.name):(s=o,l=a||"new_awesome"),typeof s<"u"&&e(s,l)},[e]),n=b.useCallback(o=>{const a=o[0];a&&t(a)},[e]),r=b.useCallback(async(o,a)=>{const l=await(await fetch(o)).arrayBuffer();t(l,a)},[]),i=b.useCallback(o=>()=>{r(o.path,o.name)},[e]);return O.jsx(ia,{onDrop:n,accept:"lottie",noClick:!0,children:o=>O.jsxs("div",{...o.getRootProps(),className:"h-full bg-dark text-white flex justify-center items-center",children:[O.jsx("input",{...o.getInputProps()}),o.isDragActive?O.jsx("h1",{className:"text-5xl mb-4",children:"Drop it!!!! Almost there :)"}):O.jsxs("div",{className:"p-10 rounded text-gray-400 max-w-2xl",children:[O.jsx("h1",{className:"text-5xl mb-4",children:"DotLottie Playground :)"}),O.jsxs("p",{className:"text-2xl mb-6",children:["To start drop a ",O.jsx("span",{className:"text-red-600",children:".lottie"}),". You could also select a sample file below."]}),O.jsx("h2",{className:"text-lg mb-2",children:"Sample files"}),O.jsx("ul",{className:"text-sm",children:S7.map(a=>O.jsx("li",{children:O.jsxs("button",{className:"flex gap-2 items-center hover:text-white mb-1",onClick:i(a),children:[O.jsx(oE,{className:"fill-yellow-500"}),a.name]})},a.name))})]})]})})},E7=()=>{const[e,t]=b.useState({}),n=b.useCallback((r,i)=>{t({name:i,arrayBuffer:r})},[t]);return O.jsxs("div",{className:"h-screen bg-dark",children:[e.arrayBuffer?O.jsx(w7,{file:e.arrayBuffer,fileName:e.name||"unammed.lottie"}):O.jsx(b7,{onStart:n}),O.jsx(Nf,{})]})},_7=$C({reducer:{animations:KC,themes:t6,states:ZC,editor:f6,playground:QC}});Wc.createRoot(document.getElementById("root")).render(O.jsx(ee.StrictMode,{children:O.jsx(Xb,{store:_7,children:O.jsx(l6,{children:O.jsx(E7,{})})})}));export{jt as F,$7 as n,ai as t,se as v}; diff --git a/index.html b/index.html index ef26e5a8..33558e65 100644 --- a/index.html +++ b/index.html @@ -5,7 +5,7 @@ DotLottie Playground - +