@aws-amplify/ui-vue 4.2.5 → 4.2.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/version.d.ts +1 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -17,7 +17,7 @@ Event: `).concat(JSON.stringify(f.data))),o.state;if(o.status!==K.Running&&!o.op
|
|
|
17
17
|
Event: `).concat(JSON.stringify(f.data)));return o.scheduler.schedule(function(){o.forward(f);var p=o._nextState(f);o.update(p,f)}),o._state},this.sendTo=function(d,m,f){var p=o.parent&&(m===Pe.Parent||o.parent.id===m),h=p?o.parent:F(m)?m===Pe.Internal?o:o.children.get(m)||it.get(m):Pc(m)?m:void 0;if(!h){if(!p)throw new Error("Unable to send event to child '".concat(m,"' from service '").concat(o.id,"'."));W||q(!1,"Service '".concat(o.id,"' has no parent: unable to send event ").concat(d.type));return}if("machine"in h){if(o.status!==K.Stopped||o.parent!==h||o.state.done){var v=C(C({},d),{name:d.name===cr?"".concat(ze(o.id)):d.name,origin:o.sessionId});!f&&o.machine.config.predictableActionArguments?o._outgoingQueue.push([h,v]):h.send(v)}}else!f&&o.machine.config.predictableActionArguments?o._outgoingQueue.push([h,d.data]):h.send(d.data)},this._exec=function(d,m,f,p){p===void 0&&(p=o.machine.options.actions);var h=d.exec||Ht(d.type,p),v=M(h)?h:h?h.exec:d.exec;if(v)try{return v(m,f.data,o.machine.config.predictableActionArguments?{action:d,_event:f}:{action:d,state:o.state,_event:f})}catch(Y){throw o.parent&&o.parent.send({type:"xstate.error",data:Y}),Y}switch(d.type){case qe:{var S=d;o.defer(S);break}case Ct:var g=d;if(typeof g.delay=="number"){o.defer(g);return}else g.to?o.sendTo(g._event,g.to,f===Re):o.send(g._event);break;case sr:o.cancel(d.sendId);break;case Gt:{if(o.status!==K.Running)return;var w=d.activity;if(!o.machine.config.predictableActionArguments&&!o.state.activities[w.id||w.type])break;if(w.type===V.Invoke){var y=di(w.src),_=o.machine.options.services?o.machine.options.services[y.type]:void 0,b=w.id,A=w.data;W||q(!("forward"in w),"`forward` property is deprecated (found in invocation of '".concat(w.src,"' in in machine '").concat(o.machine.id,"'). ")+"Please use `autoForward` instead.");var E="autoForward"in w?w.autoForward:!!w.forward;if(!_){W||q(!1,"No service found for invocation '".concat(w.src,"' in machine '").concat(o.machine.id,"'."));return}var I=A?Wt(A,m,f):void 0;if(typeof _=="string")return;var N=M(_)?_(m,f.data,{data:I,src:y,meta:w.meta}):_;if(!N)return;var P=void 0;Ce(N)&&(N=I?N.withContext(I):N,P={autoForward:E}),o.spawn(N,b,P)}else o.spawnActivity(w);break}case rn:{o.stopChild(d.activity.id);break}case an:var k=d,x=k.label,$=k.value;x?o.logger(x,$):o.logger($);break;default:W||q(!1,"No implementation found for action type '".concat(d.type,"'"));break}};var i=C(C({},e.defaultOptions),n),a=i.clock,s=i.logger,c=i.parent,l=i.id,u=l!==void 0?l:t.id;this.id=u,this.logger=s,this.clock=a,this.parent=c,this.options=i,this.scheduler=new ro({deferEvents:this.options.deferEvents}),this.sessionId=it.bookId()}return Object.defineProperty(e.prototype,"initialState",{get:function(){var t=this;return this._initialState?this._initialState:Le(this,function(){return t._initialState=t.machine.initialState,t._initialState})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"state",{get:function(){return W||q(this.status!==K.NotStarted,"Attempted to read state from uninitialized service '".concat(this.id,"'. Make sure the service is started first.")),this._state},enumerable:!1,configurable:!0}),e.prototype.execute=function(t,n){var o,i;try{for(var a=O(t.actions),s=a.next();!s.done;s=a.next()){var c=s.value;this.exec(c,t,n)}}catch(l){o={error:l}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(o)throw o.error}}},e.prototype.update=function(t,n){var o,i,a,s,c,l,u,d,m=this;if(t._sessionid=this.sessionId,this._state=t,(!this.machine.config.predictableActionArguments||n===Re)&&this.options.execute)this.execute(this.state);else for(var f=void 0;f=this._outgoingQueue.shift();)f[0].send(f[1]);if(this.children.forEach(function(N){m.state.children[N.id]=N}),this.devTools&&this.devTools.send(n.data,t),t.event)try{for(var p=O(this.eventListeners),h=p.next();!h.done;h=p.next()){var v=h.value;v(t.event)}}catch(N){o={error:N}}finally{try{h&&!h.done&&(i=p.return)&&i.call(p)}finally{if(o)throw o.error}}try{for(var S=O(this.listeners),g=S.next();!g.done;g=S.next()){var v=g.value;v(t,t.event)}}catch(N){a={error:N}}finally{try{g&&!g.done&&(s=S.return)&&s.call(S)}finally{if(a)throw a.error}}try{for(var w=O(this.contextListeners),y=w.next();!y.done;y=w.next()){var _=y.value;_(this.state.context,this.state.history?this.state.history.context:void 0)}}catch(N){c={error:N}}finally{try{y&&!y.done&&(l=w.return)&&l.call(w)}finally{if(c)throw c.error}}if(this.state.done){var b=t.configuration.find(function(N){return N.type==="final"&&N.parent===m.machine}),A=b&&b.doneData?Wt(b.doneData,t.context,n):void 0;this._doneEvent=gt(this.id,A);try{for(var E=O(this.doneListeners),I=E.next();!I.done;I=E.next()){var v=I.value;v(this._doneEvent)}}catch(N){u={error:N}}finally{try{I&&!I.done&&(d=E.return)&&d.call(E)}finally{if(u)throw u.error}}this._stop(),this._stopChildren(),it.free(this.sessionId)}},e.prototype.onTransition=function(t){return this.listeners.add(t),this.status===K.Running&&t(this.state,this.state.event),this},e.prototype.subscribe=function(t,n,o){var i=this,a=Vt(t,n,o);this.listeners.add(a.next),this.status!==K.NotStarted&&a.next(this.state);var s=function(){i.doneListeners.delete(s),i.stopListeners.delete(s),a.complete()};return this.status===K.Stopped?a.complete():(this.onDone(s),this.onStop(s)),{unsubscribe:function(){i.listeners.delete(a.next),i.doneListeners.delete(s),i.stopListeners.delete(s)}}},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===K.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===K.Running)return this;this.machine._init(),it.register(this.sessionId,this),this.initialized=!0,this.status=K.Running;var o=t===void 0?this.initialState:Le(this,function(){return Jc(t)?n.machine.resolveState(t):n.machine.resolveState(de.from(t,n.machine.context))});return this.options.devTools&&this.attachDev(),this.scheduler.initialize(function(){n.update(o,Re)}),this},e.prototype._stopChildren=function(){this.children.forEach(function(t){M(t.stop)&&t.stop()}),this.children.clear()},e.prototype._stop=function(){var t,n,o,i,a,s,c,l,u,d;try{for(var m=O(this.listeners),f=m.next();!f.done;f=m.next()){var p=f.value;this.listeners.delete(p)}}catch(E){t={error:E}}finally{try{f&&!f.done&&(n=m.return)&&n.call(m)}finally{if(t)throw t.error}}try{for(var h=O(this.stopListeners),v=h.next();!v.done;v=h.next()){var p=v.value;p(),this.stopListeners.delete(p)}}catch(E){o={error:E}}finally{try{v&&!v.done&&(i=h.return)&&i.call(h)}finally{if(o)throw o.error}}try{for(var S=O(this.contextListeners),g=S.next();!g.done;g=S.next()){var p=g.value;this.contextListeners.delete(p)}}catch(E){a={error:E}}finally{try{g&&!g.done&&(s=S.return)&&s.call(S)}finally{if(a)throw a.error}}try{for(var w=O(this.doneListeners),y=w.next();!y.done;y=w.next()){var p=y.value;this.doneListeners.delete(p)}}catch(E){c={error:E}}finally{try{y&&!y.done&&(l=w.return)&&l.call(w)}finally{if(c)throw c.error}}if(!this.initialized)return this;this.initialized=!1,this.status=K.Stopped,this._initialState=void 0;try{for(var _=O(Object.keys(this.delayedEventsMap)),b=_.next();!b.done;b=_.next()){var A=b.value;this.clock.clearTimeout(this.delayedEventsMap[A])}}catch(E){u={error:E}}finally{try{b&&!b.done&&(d=_.return)&&d.call(_)}finally{if(u)throw u.error}}this.scheduler.clear(),this.scheduler=new ro({deferEvents:this.options.deferEvents})},e.prototype.stop=function(){var t=this,n=this.scheduler;return this._stop(),n.schedule(function(){var o=J({type:"xstate.stop"}),i=Le(t,function(){var a=j(G([],D(t.state.configuration),!1).sort(function(d,m){return m.order-d.order}).map(function(d){return Se(d.onExit,t.machine.options.actions)})),s=D(wt(t.machine,t.state,t.state.context,o,[{type:"exit",actions:a}],t.machine.config.predictableActionArguments?t._exec:void 0,t.machine.config.predictableActionArguments||t.machine.config.preserveActionOrder),2),c=s[0],l=s[1],u=new de({value:t.state.value,context:l,_event:o,_sessionid:t.sessionId,historyValue:void 0,history:t.state,actions:c.filter(function(d){return!zn(d)}),activities:{},events:[],configuration:[],transitions:[],children:{},done:t.state.done,tags:t.state.tags,machine:t.machine});return u.changed=!0,u});t.update(i,o),t._stopChildren(),it.free(t.sessionId)}),this},e.prototype.batch=function(t){var n=this;if(this.status===K.NotStarted&&this.options.deferEvents)W||q(!1,"".concat(t.length,' event(s) were sent to uninitialized service "').concat(this.machine.id,`" and are deferred. Make sure .start() is called for this service.
|
|
18
18
|
Event: `).concat(JSON.stringify(event)));else if(this.status!==K.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 o=!!this.machine.config.predictableActionArguments&&this._exec;this.scheduler.schedule(function(){var i,a,s=n.state,c=!1,l=[],u=function(p){var h=J(p);n.forward(h),s=Le(n,function(){return n.machine.transition(s,h,void 0,o||void 0)}),l.push.apply(l,G([],D(n.machine.config.predictableActionArguments?s.actions:s.actions.map(function(v){return Zc(v,s)})),!1)),c=c||!!s.changed};try{for(var d=O(t),m=d.next();!m.done;m=d.next()){var f=m.value;u(f)}}catch(p){i={error:p}}finally{try{m&&!m.done&&(a=d.return)&&a.call(d)}finally{if(i)throw i.error}}s.changed=c,s.actions=l,n.update(s,J(t[t.length-1]))})}},e.prototype.sender=function(t){return this.send.bind(this,t)},e.prototype._nextState=function(t,n){var o=this;n===void 0&&(n=!!this.machine.config.predictableActionArguments&&this._exec);var i=J(t);if(i.name.indexOf(Vn)===0&&!this.state.nextEvents.some(function(s){return s.indexOf(Vn)===0}))throw i.data.data;var a=Le(this,function(){return o.machine.transition(o.state,i,void 0,n||void 0)});return a},e.prototype.nextState=function(t){return this._nextState(t,!1)},e.prototype.forward=function(t){var n,o;try{for(var i=O(this.forwardTo),a=i.next();!a.done;a=i.next()){var s=a.value,c=this.children.get(s);if(!c)throw new Error("Unable to forward event '".concat(t,"' from interpreter '").concat(this.id,"' to nonexistant child '").concat(s,"'."));c.send(t)}}catch(l){n={error:l}}finally{try{a&&!a.done&&(o=i.return)&&o.call(i)}finally{if(n)throw n.error}}},e.prototype.defer=function(t){var n=this,o=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]=o)},e.prototype.cancel=function(t){this.clock.clearTimeout(this.delayedEventsMap[t]),delete this.delayedEventsMap[t]},e.prototype.exec=function(t,n,o){o===void 0&&(o=this.machine.options.actions),this._exec(t,n.context,n._event,o)},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),M(n.stop)&&n.stop())},e.prototype.spawn=function(t,n,o){if(this.status!==K.Running)return dr(t,n);if(eo(t))return this.spawnPromise(Promise.resolve(t),n);if(M(t))return this.spawnCallback(t,n);if(Wc(t))return this.spawnActor(t,n);if(Nc(t))return this.spawnObservable(t,n);if(Ce(t))return this.spawnMachine(t,C(C({},o),{id:n}));if(Ec(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 o=this;n===void 0&&(n={});var i=new e(t,C(C({},this.options),{parent:this,id:n.id||t.id})),a=C(C({},Wn),n);a.sync&&i.onTransition(function(c){o.send(sn,{state:c,id:i.id})});var s=i;return this.children.set(i.id,s),a.autoForward&&this.forwardTo.add(i.id),i.onDone(function(c){o.removeChild(i.id),o.send(J(c,{origin:i.id}))}).start(),s},e.prototype.spawnBehavior=function(t,n){var o=nl(t,{id:n,parent:this});return this.children.set(n,o),o},e.prototype.spawnPromise=function(t,n){var o,i=this,a=!1,s;t.then(function(l){a||(s=l,i.removeChild(n),i.send(J(gt(n,l),{origin:n})))},function(l){if(!a){i.removeChild(n);var u=ze(n,l);try{i.send(J(u,{origin:n}))}catch(d){Uc(l,d,n),i.devTools&&i.devTools.send(u,i.state),i.machine.strict&&i.stop()}}});var c=(o={id:n,send:function(){},subscribe:function(l,u,d){var m=Vt(l,u,d),f=!1;return t.then(function(p){f||(m.next(p),!f&&m.complete())},function(p){f||m.error(p)}),{unsubscribe:function(){return f=!0}}},stop:function(){a=!0},toJSON:function(){return{id:n}},getSnapshot:function(){return s}},o[Ie]=function(){return this},o);return this.children.set(n,c),c},e.prototype.spawnCallback=function(t,n){var o,i=this,a=!1,s=new Set,c=new Set,l,u=function(f){l=f,c.forEach(function(p){return p(f)}),!a&&i.send(J(f,{origin:n}))},d;try{d=t(u,function(f){s.add(f)})}catch(f){this.send(ze(n,f))}if(eo(d))return this.spawnPromise(d,n);var m=(o={id:n,send:function(f){return s.forEach(function(p){return p(f)})},subscribe:function(f){var p=Vt(f);return c.add(p.next),{unsubscribe:function(){c.delete(p.next)}}},stop:function(){a=!0,M(d)&&d()},toJSON:function(){return{id:n}},getSnapshot:function(){return l}},o[Ie]=function(){return this},o);return this.children.set(n,m),m},e.prototype.spawnObservable=function(t,n){var o,i=this,a,s=t.subscribe(function(l){a=l,i.send(J(l,{origin:n}))},function(l){i.removeChild(n),i.send(J(ze(n,l),{origin:n}))},function(){i.removeChild(n),i.send(J(gt(n),{origin:n}))}),c=(o={id:n,send:function(){},subscribe:function(l,u,d){return t.subscribe(l,u,d)},stop:function(){return s.unsubscribe()},getSnapshot:function(){return a},toJSON:function(){return{id:n}}},o[Ie]=function(){return this},o);return this.children.set(n,c),c},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){W||q(!1,"No implementation found for activity '".concat(t.type,"'"));return}var o=n(this.state.context,t);this.spawnEffect(t.id,o)},e.prototype.spawnEffect=function(t,n){var o;this.children.set(t,(o={id:t,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},stop:n||void 0,getSnapshot:function(){},toJSON:function(){return{id:t}}},o[Ie]=function(){return this},o))},e.prototype.attachDev=function(){var t=fr();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(C(C({name:this.id,autoPause:!0,stateSanitizer:function(o){return{value:o.value,context:o.context,actions:o.actions}}},n),{features:C({jump:!1,skip:!1},n?n.features:void 0)}),this.machine),this.devTools.init(this.state)}tl(this)}},e.prototype.toJSON=function(){return{id:this.id}},e.prototype[Ie]=function(){return this},e.prototype.getSnapshot=function(){return this.status===K.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=ki,e}(),ol=function(e){return F(e)?C(C({},Wn),{name:e}):C(C(C({},Wn),{name:kc()}),e)};function at(e,t){var n=ol(t);return Gc(function(o){if(!W){var i=Ce(e)||M(e);q(!!o||i,'Attempted to spawn an Actor (ID: "'.concat(Ce(e)?e.id:"undefined",'") outside of a service. This will have no effect.'))}return o?o.spawn(e,n.name,n):dr(e,n.name)})}function ki(e,t){var n=new rl(e,t);return n}function il(e){if(typeof e=="string"){var t={type:e};return t.toString=function(){return e},t}return e}function kt(e){return C(C({type:zt},e),{toJSON:function(){e.onDone,e.onError;var t=ar(e,["onDone","onError"]);return C(C({},t),{type:zt,src:il(e.src)})}})}var Ge="",Hn="#",st="*",Be={},Ve=function(e){return e[0]===Hn},al=function(){return{actions:{},guards:{},services:{},activities:{},delays:{}}},sl=function(e,t,n){var o=n.slice(0,-1).some(function(a){return!("cond"in a)&&!("in"in a)&&(F(a.target)||Ce(a.target))}),i=t===Ge?"the transient event":"event '".concat(t,"'");q(!o,"One or more transitions for ".concat(i," on state '").concat(e.id,"' are unreachable. ")+"Make sure that the default transition is the last one defined.")},cl=function(){function e(t,n,o,i){o===void 0&&(o="context"in t?t.context:void 0);var a=this,s;this.config=t,this._context=o,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(al(),n),this.parent=i==null?void 0:i.parent,this.key=this.config.key||(i==null?void 0:i.key)||this.config.id||"(machine)",this.machine=this.parent?this.parent.machine:this,this.path=this.parent?this.parent.path.concat(this.key):[],this.delimiter=this.config.delimiter||(this.parent?this.parent.delimiter:ii),this.id=this.config.id||G([this.machine.key],D(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:(s=this.config.schema)!==null&&s!==void 0?s:{},this.description=this.config.description,W||q(!("parallel"in this.config),'The "parallel" property is deprecated and will be removed in version 4.1. '.concat(this.config.parallel?"Replace with `type: 'parallel'`":"Use `type: '".concat(this.type,"'`")," in the config for state node '").concat(this.id,"' instead.")),this.initial=this.config.initial,this.states=this.config.states?ut(this.config.states,function(u,d){var m,f=new e(u,{},void 0,{parent:a,key:d});return Object.assign(a.idMap,C((m={},m[f.id]=f,m),f.idMap)),f}):Be;var c=0;function l(u){var d,m;u.order=c++;try{for(var f=O(Ii(u)),p=f.next();!p.done;p=f.next()){var h=p.value;l(h)}}catch(v){d={error:v}}finally{try{p&&!p.done&&(m=f.return)&&m.call(f)}finally{if(d)throw d.error}}}l(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 d=u.event;return d===Ge}):Ge in this.config.on:!1),this.strict=!!this.config.strict,this.onEntry=ue(this.config.entry||this.config.onEntry).map(function(u){return je(u)}),this.onExit=ue(this.config.exit||this.config.onExit).map(function(u){return je(u)}),this.meta=this.config.meta,this.doneData=this.type==="final"?this.config.data:void 0,this.invoke=ue(this.config.invoke).map(function(u,d){var m,f;if(Ce(u)){var p=Pt(a.id,d);return a.machine.options.services=C((m={},m[p]=u,m),a.machine.options.services),kt({src:p,id:p})}else if(F(u.src)){var p=u.id||Pt(a.id,d);return kt(C(C({},u),{id:p,src:u.src}))}else if(Ce(u.src)||M(u.src)){var p=u.id||Pt(a.id,d);return a.machine.options.services=C((f={},f[p]=u.src,f),a.machine.options.services),kt(C(C({id:p},u),{src:p}))}else{var h=u.src;return kt(C(C({id:Pt(a.id,d)},u),{src:h}))}}),this.activities=ue(this.config.activities).concat(this.invoke).map(function(u){return ln(u)}),this.transition=this.transition.bind(this),this.tags=ue(this.config.tags)}return e.prototype._init=function(){this.__cache.transitions||Ti(this).forEach(function(t){return t.on})},e.prototype.withConfig=function(t,n){var o=this.options,i=o.actions,a=o.activities,s=o.guards,c=o.services,l=o.delays;return new e(this.config,{actions:C(C({},i),t.actions),activities:C(C({},a),t.activities),guards:C(C({},s),t.guards),services:C(C({},c),t.services),delays:C(C({},l),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 M(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:ut(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,o){return n[o.eventType]=n[o.eventType]||[],n[o.eventType].push(o),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===Ge,o=this.transitions.filter(function(i){var a=i.eventType===t;return n?a:a||i.eventType===st});return this.__cache.candidates[t]=o,o},e.prototype.getDelayedTransitions=function(){var t=this,n=this.config.after;if(!n)return[];var o=function(a,s){var c=M(a)?"".concat(t.id,":delay[").concat(s,"]"):a,l=Ci(c,t.id);return t.onEntry.push(Ze(l,{delay:a})),t.onExit.push(yi(l)),l},i=Je(n)?n.map(function(a,s){var c=o(a.delay,s);return C(C({},a),{event:c})}):j(Object.keys(n).map(function(a,s){var c=n[a],l=F(c)?{target:c}:c,u=isNaN(+a)?a:+a,d=o(u,s);return ue(l).map(function(m){return C(C({},m),{event:d,delay:u})})}));return i.map(function(a){var s=a.delay;return C(C({},t.formatTransition(a)),{delay:s})})},e.prototype.getStateNodes=function(t){var n,o=this;if(!t)return[];var i=t instanceof de?t.value:mt(t,this.delimiter);if(F(i)){var a=this.getStateNode(i).initial;return a!==void 0?this.getStateNodes((n={},n[i]=a,n)):[this,this.states[i]]}var s=Object.keys(i),c=[this];return c.push.apply(c,G([],D(j(s.map(function(l){return o.getStateNode(l).getStateNodes(i[l])}))),!1)),c},e.prototype.handles=function(t){var n=ai(t);return this.events.includes(n)},e.prototype.resolveState=function(t){var n=t instanceof de?t:de.create(t),o=Array.from(ft([],this.getStateNodes(n.value)));return new de(C(C({},n),{value:this.resolve(n.value),configuration:o,done:Lt(o,this),tags:no(o),machine:this.machine}))},e.prototype.transitionLeafNode=function(t,n,o){var i=this.getStateNode(t),a=i.next(n,o);return!a||!a.transitions.length?this.next(n,o):a},e.prototype.transitionCompoundNode=function(t,n,o){var i=Object.keys(t),a=this.getStateNode(i[0]),s=a._transition(t[i[0]],n,o);return!s||!s.transitions.length?this.next(n,o):s},e.prototype.transitionParallelNode=function(t,n,o){var i,a,s={};try{for(var c=O(Object.keys(t)),l=c.next();!l.done;l=c.next()){var u=l.value,d=t[u];if(d){var m=this.getStateNode(u),f=m._transition(d,n,o);f&&(s[u]=f)}}}catch(g){i={error:g}}finally{try{l&&!l.done&&(a=c.return)&&a.call(c)}finally{if(i)throw i.error}}var p=Object.keys(s).map(function(g){return s[g]}),h=j(p.map(function(g){return g.transitions})),v=p.some(function(g){return g.transitions.length>0});if(!v)return this.next(n,o);var S=j(Object.keys(s).map(function(g){return s[g].configuration}));return{transitions:h,exitSet:j(p.map(function(g){return g.exitSet})),configuration:S,source:n,actions:j(Object.keys(s).map(function(g){return s[g].actions}))}},e.prototype._transition=function(t,n,o){return F(t)?this.transitionLeafNode(t,n,o):Object.keys(t).length===1?this.transitionCompoundNode(t,n,o):this.transitionParallelNode(t,n,o)},e.prototype.getTransitionData=function(t,n){return this._transition(t.value,t,J(n))},e.prototype.next=function(t,n){var o,i,a=this,s=n.name,c=[],l=[],u;try{for(var d=O(this.getCandidates(s)),m=d.next();!m.done;m=d.next()){var f=m.value,p=f.cond,h=f.in,v=t.context,S=h?F(h)&&Ve(h)?t.matches(mt(this.getStateNodeById(h).path,this.delimiter)):lr(mt(h,this.delimiter),Cc(this.path.slice(0,-2))(t.value)):!0,g=!1;try{g=!p||ui(this.machine,p,v,n,t)}catch(_){throw new Error("Unable to evaluate guard '".concat(p.name||p.type,"' in transition for event '").concat(s,"' in state node '").concat(this.id,`':
|
|
19
19
|
`).concat(_.message))}if(g&&S){f.target!==void 0&&(l=f.target),c.push.apply(c,G([],D(f.actions),!1)),u=f;break}}}catch(_){o={error:_}}finally{try{m&&!m.done&&(i=d.return)&&i.call(d)}finally{if(o)throw o.error}}if(u){if(!l.length)return{transitions:[u],exitSet:[],configuration:t.value?[this]:[],source:t,actions:c};var w=j(l.map(function(_){return a.getRelativeStateNodes(_,t.historyValue)})),y=!!u.internal;return{transitions:[u],exitSet:y?[]:j(l.map(function(_){return a.getPotentiallyReenteringNodes(_)})),configuration:w,source:t,actions:c}}},e.prototype.getPotentiallyReenteringNodes=function(t){if(this.order<t.order)return[this];for(var n=[],o=this,i=t;o&&o!==i;)n.push(o),o=o.parent;return o!==i?[]:(n.push(i),n)},e.prototype.getActions=function(t,n,o,i,a,s,c){var l,u,d,m,f=this,p=s?ft([],this.getStateNodes(s.value)):[],h=new Set;try{for(var v=O(Array.from(t).sort(function(k,x){return k.order-x.order})),S=v.next();!S.done;S=v.next()){var g=S.value;(!pt(p,g)||pt(o.exitSet,g)||g.parent&&h.has(g.parent))&&h.add(g)}}catch(k){l={error:k}}finally{try{S&&!S.done&&(u=v.return)&&u.call(v)}finally{if(l)throw l.error}}try{for(var w=O(p),y=w.next();!y.done;y=w.next()){var g=y.value;(!pt(t,g)||pt(o.exitSet,g.parent))&&o.exitSet.push(g)}}catch(k){d={error:k}}finally{try{y&&!y.done&&(m=w.return)&&m.call(w)}finally{if(d)throw d.error}}o.exitSet.sort(function(k,x){return x.order-k.order});var _=Array.from(h).sort(function(k,x){return k.order-x.order}),b=new Set(o.exitSet),A=j(_.map(function(k){var x=[];if(k.type!=="final")return x;var $=k.parent;if(!$.parent)return x;x.push(dt(k.id,k.doneData),dt($.id,k.doneData?Wt(k.doneData,i,a):void 0));var Y=$.parent;return Y.type==="parallel"&&_t(Y).every(function(ae){return Lt(o.configuration,ae)})&&x.push(dt(Y.id)),x})),E=_.map(function(k){var x=k.onEntry,$=k.activities.map(function(Y){return vi(Y)});return{type:"entry",actions:Se(c?G(G([],D(x),!1),D($),!1):G(G([],D($),!1),D(x),!1),f.machine.options.actions)}}).concat({type:"state_done",actions:A.map(function(k){return fi(k)})}),I=Array.from(b).map(function(k){return{type:"exit",actions:Se(G(G([],D(k.onExit),!1),D(k.activities.map(function(x){return wi(x)})),!1),f.machine.options.actions)}}),N=I.concat({type:"transition",actions:Se(o.actions,this.machine.options.actions)}).concat(E);if(n){var P=Se(j(G([],D(t),!1).sort(function(k,x){return x.order-k.order}).map(function(k){return k.onExit})),this.machine.options.actions).filter(function(k){return!zn(k)});return N.concat({type:"stop",actions:P})}return N},e.prototype.transition=function(t,n,o,i){t===void 0&&(t=this.initialState);var a=J(n),s;if(t instanceof de)s=o===void 0?t:this.resolveState(de.from(t,o));else{var c=F(t)?this.resolve(jt(this.getResolvedPath(t))):this.resolve(t),l=o??this.machine.context;s=this.resolveState(de.from(c,l))}if(!W&&a.name===st)throw new Error("An event cannot have the wildcard type ('".concat(st,"')"));if(this.strict&&!this.events.includes(a.name)&&!Ac(a.name))throw new Error("Machine '".concat(this.id,"' does not accept event '").concat(a.name,"'"));var u=this._transition(s.value,s,a)||{transitions:[],configuration:[],exitSet:[],source:s,actions:[]},d=ft([],this.getStateNodes(s.value)),m=u.configuration.length?ft(d,u.configuration):d;return u.configuration=G([],D(m),!1),this.resolveTransition(u,s,s.context,i,a)},e.prototype.resolveRaisedTransition=function(t,n,o,i){var a,s=t.actions;return t=this.transition(t,n,void 0,i),t._event=o,t.event=o.data,(a=t.actions).unshift.apply(a,G([],D(s),!1)),t},e.prototype.resolveTransition=function(t,n,o,i,a){var s,c,l,u,d=this;a===void 0&&(a=Re);var m=t.configuration,f=!n||t.transitions.length>0,p=f?t.configuration:n?n.configuration:[],h=Lt(p,this),v=f?Yc(this.machine,m):void 0,S=n?n.historyValue?n.historyValue:t.source?this.machine.historyValue(n.value):void 0:void 0,g=this.getActions(new Set(p),h,t,o,a,n,i),w=n?C({},n.activities):{};try{for(var y=O(g),_=y.next();!_.done;_=y.next()){var b=_.value;try{for(var A=(l=void 0,O(b.actions)),E=A.next();!E.done;E=A.next()){var I=E.value;I.type===Gt?w[I.activity.id||I.activity.type]=I:I.type===rn&&(w[I.activity.id||I.activity.type]=!1)}}catch(te){l={error:te}}finally{try{E&&!E.done&&(u=A.return)&&u.call(A)}finally{if(l)throw l.error}}}}catch(te){s={error:te}}finally{try{_&&!_.done&&(c=y.return)&&c.call(y)}finally{if(s)throw s.error}}var N=D(wt(this,n,o,a,g,i,this.machine.config.predictableActionArguments||this.machine.config.preserveActionOrder),2),P=N[0],k=N[1],x=D(Ic(P,zn),2),$=x[0],Y=x[1],ae=P.filter(function(te){var Ee;return te.type===Gt&&((Ee=te.activity)===null||Ee===void 0?void 0:Ee.type)===zt}),le=ae.reduce(function(te,Ee){return te[Ee.activity.id]=zc(Ee.activity,d.machine,k,a),te},n?C({},n.children):{}),Z=new de({value:v||n.value,context:k,_event:a,_sessionid:n?n._sessionid:null,historyValue:v?S?Tc(S,v):void 0:n?n.historyValue:void 0,history:!v||t.source?n:void 0,actions:v?Y:[],activities:v?w:n?n.activities:{},events:[],configuration:p,transitions:t.transitions,children:le,done:h,tags:no(p),machine:this}),se=o!==k;Z.changed=a.name===sn||se;var re=Z.history;re&&delete re.history;var Fe=!h&&(this._transient||m.some(function(te){return te._transient}));if(!f&&(!Fe||a.name===Ge))return Z;var oe=Z;if(!h)for(Fe&&(oe=this.resolveRaisedTransition(oe,{type:ti},a,i));$.length;){var U=$.shift();oe=this.resolveRaisedTransition(oe,U._event,a,i)}var Kr=oe.changed||(re?!!oe.actions.length||se||typeof re.value!=typeof oe.value||!Pi(oe.value,re.value):void 0);return oe.changed=Kr,oe.history=re,oe},e.prototype.getStateNode=function(t){if(Ve(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=Ve(t)?t.slice(Hn.length):t;if(n===this.id)return this;var o=this.machine.idMap[n];if(!o)throw new Error("Child state node '#".concat(n,"' does not exist on machine '").concat(this.id,"'"));return o},e.prototype.getStateNodeByPath=function(t){if(typeof t=="string"&&Ve(t))try{return this.getStateNodeById(t.slice(1))}catch{}for(var n=Gn(t,this.delimiter).slice(),o=this;n.length;){var i=n.shift();if(!i.length)break;o=o.getStateNode(i)}return o},e.prototype.resolve=function(t){var n,o=this;if(!t)return this.initialStateValue||Be;switch(this.type){case"parallel":return ut(this.initialStateValue,function(a,s){return a?o.getStateNode(s).resolve(t[s]||a):Be});case"compound":if(F(t)){var i=this.getStateNode(t);return i.type==="parallel"||i.type==="compound"?(n={},n[t]=i.initialStateValue,n):t}return Object.keys(t).length?ut(t,function(a,s){return a?o.getStateNode(s).resolve(a):Be}):this.initialStateValue||{};default:return t||Be}},e.prototype.getResolvedPath=function(t){if(Ve(t)){var n=this.machine.idMap[t.slice(Hn.length)];if(!n)throw new Error("Unable to find state node '".concat(t,"'"));return n.path}return Gn(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=Xr(this.states,function(o){return o.initialStateValue||Be},function(o){return o.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=Kt(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 o=this.getStateNodes(t);return this.resolveTransition({configuration:o,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;F(n.target)?t=Ve(n.target)?jt(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,o){return o===void 0&&(o=!0),o?t.type==="history"?t.resolveHistory(n):t.initialStateNodes:[t]},Object.defineProperty(e.prototype,"initialStateNodes",{get:function(){var t=this;if(Kt(this))return[this];if(this.type==="compound"&&!this.initial)return W||q(!1,"Compound state node '".concat(this.id,"' has no initial state.")),[this];var n=Bt(this.initialStateValue);return j(n.map(function(o){return t.getFromRelativePath(o)}))},enumerable:!1,configurable:!0}),e.prototype.getFromRelativePath=function(t){if(!t.length)return[this];var n=D(t),o=n[0],i=n.slice(1);if(!this.states)throw new Error("Cannot retrieve subPath '".concat(o,"' from node with no states"));var a=this.getStateNode(o);if(a.type==="history")return a.resolveHistory();if(!this.states[o])throw new Error("Child state '".concat(o,"' does not exist on '").concat(this.id,"'"));return this.states[o].getFromRelativePath(i)},e.prototype.historyValue=function(t){if(Object.keys(this.states).length)return{current:t||this.initialStateValue,states:Xr(this.states,function(n,o){if(!t)return n.historyValue();var i=F(t)?void 0:t[o];return n.historyValue(i||n.initialStateValue)},function(n){return!n.history})}},e.prototype.resolveHistory=function(t){var n=this;if(this.type!=="history")return[this];var o=this.parent;if(!t){var i=this.target;return i?j(Bt(i).map(function(s){return o.getFromRelativePath(s)})):o.initialStateNodes}var a=bc(o.path,"states")(t).current;return F(a)?[o.getStateNode(a)]:j(Bt(a).map(function(s){return n.history==="deep"?o.getFromRelativePath(s):[o.states[s[0]]]}))},Object.defineProperty(e.prototype,"stateIds",{get:function(){var t=this,n=j(Object.keys(this.states).map(function(o){return t.states[o].stateIds}));return[this.id].concat(n)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"events",{get:function(){var t,n,o,i;if(this.__cache.events)return this.__cache.events;var a=this.states,s=new Set(this.ownEvents);if(a)try{for(var c=O(Object.keys(a)),l=c.next();!l.done;l=c.next()){var u=l.value,d=a[u];if(d.states)try{for(var m=(o=void 0,O(d.events)),f=m.next();!f.done;f=m.next()){var p=f.value;s.add("".concat(p))}}catch(h){o={error:h}}finally{try{f&&!f.done&&(i=m.return)&&i.call(m)}finally{if(o)throw o.error}}}}catch(h){t={error:h}}finally{try{l&&!l.done&&(n=c.return)&&n.call(c)}finally{if(t)throw t.error}}return this.__cache.events=Array.from(s)},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(o){if(!F(o))return o;var i=o[0]===n.delimiter;if(i&&!n.parent)return n.getStateNodeByPath(o.slice(1));var a=i?n.key+o:o;if(n.parent)try{var s=n.parent.getStateNodeByPath(a);return s}catch(c){throw new Error("Invalid transition definition for state node '".concat(n.id,`':
|
|
20
|
-
`).concat(c.message))}else return n.getStateNodeByPath(a)})},e.prototype.formatTransition=function(t){var n=this,o=xc(t.target),i="internal"in t?t.internal:o?o.some(function(l){return F(l)&&l[0]===n.delimiter}):!0,a=this.machine.options.guards,s=this.resolveTarget(o),c=C(C({},t),{actions:Se(ue(t.actions)),cond:li(t.cond,a),target:s,source:this,internal:i,eventType:t.event,toJSON:function(){return C(C({},c),{target:c.target?c.target.map(function(l){return"#".concat(l.id)}):void 0,source:"#".concat(n.id)})}});return c},e.prototype.formatTransitions=function(){var t,n,o=this,i;if(!this.config.on)i=[];else if(Array.isArray(this.config.on))i=this.config.on;else{var a=this.config.on,s=st,c=a[s],l=c===void 0?[]:c,u=ar(a,[typeof s=="symbol"?s:s+""]);i=j(Object.keys(u).map(function(w){!W&&w===Ge&&q(!1,"Empty string transition configs (e.g., `{ on: { '': ... }}`) for transient transitions are deprecated. Specify the transition in the `{ always: ... }` property instead. "+'Please check the `on` configuration for "#'.concat(o.id,'".'));var y=Me(w,u[w]);return W||sl(o,w,y),y}).concat(Me(st,l)))}var d=this.config.always?Me("",this.config.always):[],m=this.config.onDone?Me(String(dt(this.id)),this.config.onDone):[];W||q(!(this.config.onDone&&!this.parent),'Root nodes cannot have an ".onDone" transition. Please check the config of "'.concat(this.id,'".'));var f=j(this.invoke.map(function(w){var y=[];return w.onDone&&y.push.apply(y,G([],D(Me(String(gt(w.id)),w.onDone)),!1)),w.onError&&y.push.apply(y,G([],D(Me(String(ze(w.id)),w.onError)),!1)),y})),p=this.after,h=j(G(G(G(G([],D(m),!1),D(f),!1),D(i),!1),D(d),!1).map(function(w){return ue(w).map(function(y){return o.formatTransition(y)})}));try{for(var v=O(p),S=v.next();!S.done;S=v.next()){var g=S.value;h.push(g)}}catch(w){t={error:w}}finally{try{S&&!S.done&&(n=v.return)&&n.call(v)}finally{if(t)throw t.error}}return h},e}(),oo=!1;function Qe(e,t){return!W&&!("predictableActionArguments"in e)&&!oo&&(oo=!0,console.warn("It is highly recommended to set `predictableActionArguments` to `true` when using `createMachine`. https://xstate.js.org/docs/guides/actions.html")),new cl(e,t)}var _e=Si,un=gi,ll=bi,xt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function xi(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function ul(e,t){for(var n=-1,o=e==null?0:e.length,i=Array(o);++n<o;)i[n]=t(e[n],n,e);return i}var Ui=ul;function dl(){this.__data__=[],this.size=0}var fl=dl;function pl(e,t){return e===t||e!==e&&t!==t}var bt=pl,ml=bt;function gl(e,t){for(var n=e.length;n--;)if(ml(e[n][0],t))return n;return-1}var dn=gl,hl=dn,yl=Array.prototype,vl=yl.splice;function wl(e){var t=this.__data__,n=hl(t,e);if(n<0)return!1;var o=t.length-1;return n==o?t.pop():vl.call(t,n,1),--this.size,!0}var _l=wl,Sl=dn;function Cl(e){var t=this.__data__,n=Sl(t,e);return n<0?void 0:t[n][1]}var bl=Cl,Al=dn;function El(e){return Al(this.__data__,e)>-1}var Il=El,Tl=dn;function Nl(e,t){var n=this.__data__,o=Tl(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}var Pl=Nl,kl=fl,xl=_l,Ul=bl,$l=Il,Rl=Pl;function Xe(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}Xe.prototype.clear=kl;Xe.prototype.delete=xl;Xe.prototype.get=Ul;Xe.prototype.has=$l;Xe.prototype.set=Rl;var fn=Xe,Ol=fn;function Dl(){this.__data__=new Ol,this.size=0}var Fl=Dl;function Ml(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}var Bl=Ml;function Vl(e){return this.__data__.get(e)}var Ll=Vl;function Gl(e){return this.__data__.has(e)}var zl=Gl,jl=typeof xt=="object"&&xt&&xt.Object===Object&&xt,$i=jl,Wl=$i,Hl=typeof self=="object"&&self&&self.Object===Object&&self,Yl=Wl||Hl||Function("return this")(),ge=Yl,Kl=ge,ql=Kl.Symbol,pn=ql,io=pn,Ri=Object.prototype,Jl=Ri.hasOwnProperty,Zl=Ri.toString,ct=io?io.toStringTag:void 0;function Ql(e){var t=Jl.call(e,ct),n=e[ct];try{e[ct]=void 0;var o=!0}catch{}var i=Zl.call(e);return o&&(t?e[ct]=n:delete e[ct]),i}var Xl=Ql,eu=Object.prototype,tu=eu.toString;function nu(e){return tu.call(e)}var ru=nu,ao=pn,ou=Xl,iu=ru,au="[object Null]",su="[object Undefined]",so=ao?ao.toStringTag:void 0;function cu(e){return e==null?e===void 0?su:au:so&&so in Object(e)?ou(e):iu(e)}var et=cu;function lu(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var be=lu,uu=et,du=be,fu="[object AsyncFunction]",pu="[object Function]",mu="[object GeneratorFunction]",gu="[object Proxy]";function hu(e){if(!du(e))return!1;var t=uu(e);return t==pu||t==mu||t==fu||t==gu}var pr=hu,yu=ge,vu=yu["__core-js_shared__"],wu=vu,xn=wu,co=function(){var e=/[^.]+$/.exec(xn&&xn.keys&&xn.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function _u(e){return!!co&&co in e}var Su=_u,Cu=Function.prototype,bu=Cu.toString;function Au(e){if(e!=null){try{return bu.call(e)}catch{}try{return e+""}catch{}}return""}var Oi=Au,Eu=pr,Iu=Su,Tu=be,Nu=Oi,Pu=/[\\^$.*+?()[\]{}|]/g,ku=/^\[object .+?Constructor\]$/,xu=Function.prototype,Uu=Object.prototype,$u=xu.toString,Ru=Uu.hasOwnProperty,Ou=RegExp("^"+$u.call(Ru).replace(Pu,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Du(e){if(!Tu(e)||Iu(e))return!1;var t=Eu(e)?Ou:ku;return t.test(Nu(e))}var Fu=Du;function Mu(e,t){return e==null?void 0:e[t]}var Bu=Mu,Vu=Fu,Lu=Bu;function Gu(e,t){var n=Lu(e,t);return Vu(n)?n:void 0}var Oe=Gu,zu=Oe,ju=ge,Wu=zu(ju,"Map"),mr=Wu,Hu=Oe,Yu=Hu(Object,"create"),mn=Yu,lo=mn;function Ku(){this.__data__=lo?lo(null):{},this.size=0}var qu=Ku;function Ju(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Zu=Ju,Qu=mn,Xu="__lodash_hash_undefined__",ed=Object.prototype,td=ed.hasOwnProperty;function nd(e){var t=this.__data__;if(Qu){var n=t[e];return n===Xu?void 0:n}return td.call(t,e)?t[e]:void 0}var rd=nd,od=mn,id=Object.prototype,ad=id.hasOwnProperty;function sd(e){var t=this.__data__;return od?t[e]!==void 0:ad.call(t,e)}var cd=sd,ld=mn,ud="__lodash_hash_undefined__";function dd(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ld&&t===void 0?ud:t,this}var fd=dd,pd=qu,md=Zu,gd=rd,hd=cd,yd=fd;function tt(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}tt.prototype.clear=pd;tt.prototype.delete=md;tt.prototype.get=gd;tt.prototype.has=hd;tt.prototype.set=yd;var vd=tt,uo=vd,wd=fn,_d=mr;function Sd(){this.size=0,this.__data__={hash:new uo,map:new(_d||wd),string:new uo}}var Cd=Sd;function bd(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var Ad=bd,Ed=Ad;function Id(e,t){var n=e.__data__;return Ed(t)?n[typeof t=="string"?"string":"hash"]:n.map}var gn=Id,Td=gn;function Nd(e){var t=Td(this,e).delete(e);return this.size-=t?1:0,t}var Pd=Nd,kd=gn;function xd(e){return kd(this,e).get(e)}var Ud=xd,$d=gn;function Rd(e){return $d(this,e).has(e)}var Od=Rd,Dd=gn;function Fd(e,t){var n=Dd(this,e),o=n.size;return n.set(e,t),this.size+=n.size==o?0:1,this}var Md=Fd,Bd=Cd,Vd=Pd,Ld=Ud,Gd=Od,zd=Md;function nt(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}nt.prototype.clear=Bd;nt.prototype.delete=Vd;nt.prototype.get=Ld;nt.prototype.has=Gd;nt.prototype.set=zd;var gr=nt,jd=fn,Wd=mr,Hd=gr,Yd=200;function Kd(e,t){var n=this.__data__;if(n instanceof jd){var o=n.__data__;if(!Wd||o.length<Yd-1)return o.push([e,t]),this.size=++n.size,this;n=this.__data__=new Hd(o)}return n.set(e,t),this.size=n.size,this}var qd=Kd,Jd=fn,Zd=Fl,Qd=Bl,Xd=Ll,ef=zl,tf=qd;function rt(e){var t=this.__data__=new Jd(e);this.size=t.size}rt.prototype.clear=Zd;rt.prototype.delete=Qd;rt.prototype.get=Xd;rt.prototype.has=ef;rt.prototype.set=tf;var hr=rt,nf="__lodash_hash_undefined__";function rf(e){return this.__data__.set(e,nf),this}var of=rf;function af(e){return this.__data__.has(e)}var sf=af,cf=gr,lf=of,uf=sf;function qt(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new cf;++t<n;)this.add(e[t])}qt.prototype.add=qt.prototype.push=lf;qt.prototype.has=uf;var df=qt;function ff(e,t){for(var n=-1,o=e==null?0:e.length;++n<o;)if(t(e[n],n,e))return!0;return!1}var pf=ff;function mf(e,t){return e.has(t)}var gf=mf,hf=df,yf=pf,vf=gf,wf=1,_f=2;function Sf(e,t,n,o,i,a){var s=n&wf,c=e.length,l=t.length;if(c!=l&&!(s&&l>c))return!1;var u=a.get(e),d=a.get(t);if(u&&d)return u==t&&d==e;var m=-1,f=!0,p=n&_f?new hf:void 0;for(a.set(e,t),a.set(t,e);++m<c;){var h=e[m],v=t[m];if(o)var S=s?o(v,h,m,t,e,a):o(h,v,m,e,t,a);if(S!==void 0){if(S)continue;f=!1;break}if(p){if(!yf(t,function(g,w){if(!vf(p,w)&&(h===g||i(h,g,n,o,a)))return p.push(w)})){f=!1;break}}else if(!(h===v||i(h,v,n,o,a))){f=!1;break}}return a.delete(e),a.delete(t),f}var Di=Sf,Cf=ge,bf=Cf.Uint8Array,Fi=bf;function Af(e){var t=-1,n=Array(e.size);return e.forEach(function(o,i){n[++t]=[i,o]}),n}var Ef=Af;function If(e){var t=-1,n=Array(e.size);return e.forEach(function(o){n[++t]=o}),n}var Tf=If,fo=pn,po=Fi,Nf=bt,Pf=Di,kf=Ef,xf=Tf,Uf=1,$f=2,Rf="[object Boolean]",Of="[object Date]",Df="[object Error]",Ff="[object Map]",Mf="[object Number]",Bf="[object RegExp]",Vf="[object Set]",Lf="[object String]",Gf="[object Symbol]",zf="[object ArrayBuffer]",jf="[object DataView]",mo=fo?fo.prototype:void 0,Un=mo?mo.valueOf:void 0;function Wf(e,t,n,o,i,a,s){switch(n){case jf:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case zf:return!(e.byteLength!=t.byteLength||!a(new po(e),new po(t)));case Rf:case Of:case Mf:return Nf(+e,+t);case Df:return e.name==t.name&&e.message==t.message;case Bf:case Lf:return e==t+"";case Ff:var c=kf;case Vf:var l=o&Uf;if(c||(c=xf),e.size!=t.size&&!l)return!1;var u=s.get(e);if(u)return u==t;o|=$f,s.set(e,t);var d=Pf(c(e),c(t),o,i,a,s);return s.delete(e),d;case Gf:if(Un)return Un.call(e)==Un.call(t)}return!1}var Hf=Wf;function Yf(e,t){for(var n=-1,o=t.length,i=e.length;++n<o;)e[i+n]=t[n];return e}var Mi=Yf,Kf=Array.isArray,Ae=Kf,qf=Mi,Jf=Ae;function Zf(e,t,n){var o=t(e);return Jf(e)?o:qf(o,n(e))}var Bi=Zf;function Qf(e,t){for(var n=-1,o=e==null?0:e.length,i=0,a=[];++n<o;){var s=e[n];t(s,n,e)&&(a[i++]=s)}return a}var Xf=Qf;function ep(){return[]}var Vi=ep,tp=Xf,np=Vi,rp=Object.prototype,op=rp.propertyIsEnumerable,go=Object.getOwnPropertySymbols,ip=go?function(e){return e==null?[]:(e=Object(e),tp(go(e),function(t){return op.call(e,t)}))}:np,Li=ip;function ap(e,t){for(var n=-1,o=Array(e);++n<e;)o[n]=t(n);return o}var sp=ap;function cp(e){return e!=null&&typeof e=="object"}var De=cp,lp=et,up=De,dp="[object Arguments]";function fp(e){return up(e)&&lp(e)==dp}var pp=fp,ho=pp,mp=De,Gi=Object.prototype,gp=Gi.hasOwnProperty,hp=Gi.propertyIsEnumerable,yp=ho(function(){return arguments}())?ho:function(e){return mp(e)&&gp.call(e,"callee")&&!hp.call(e,"callee")},yr=yp,Jt={exports:{}};function vp(){return!1}var wp=vp;Jt.exports;(function(e,t){var n=ge,o=wp,i=t&&!t.nodeType&&t,a=i&&!0&&e&&!e.nodeType&&e,s=a&&a.exports===i,c=s?n.Buffer:void 0,l=c?c.isBuffer:void 0,u=l||o;e.exports=u})(Jt,Jt.exports);var vr=Jt.exports,_p=9007199254740991,Sp=/^(?:0|[1-9]\d*)$/;function Cp(e,t){var n=typeof e;return t=t??_p,!!t&&(n=="number"||n!="symbol"&&Sp.test(e))&&e>-1&&e%1==0&&e<t}var hn=Cp,bp=9007199254740991;function Ap(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=bp}var wr=Ap,Ep=et,Ip=wr,Tp=De,Np="[object Arguments]",Pp="[object Array]",kp="[object Boolean]",xp="[object Date]",Up="[object Error]",$p="[object Function]",Rp="[object Map]",Op="[object Number]",Dp="[object Object]",Fp="[object RegExp]",Mp="[object Set]",Bp="[object String]",Vp="[object WeakMap]",Lp="[object ArrayBuffer]",Gp="[object DataView]",zp="[object Float32Array]",jp="[object Float64Array]",Wp="[object Int8Array]",Hp="[object Int16Array]",Yp="[object Int32Array]",Kp="[object Uint8Array]",qp="[object Uint8ClampedArray]",Jp="[object Uint16Array]",Zp="[object Uint32Array]",z={};z[zp]=z[jp]=z[Wp]=z[Hp]=z[Yp]=z[Kp]=z[qp]=z[Jp]=z[Zp]=!0;z[Np]=z[Pp]=z[Lp]=z[kp]=z[Gp]=z[xp]=z[Up]=z[$p]=z[Rp]=z[Op]=z[Dp]=z[Fp]=z[Mp]=z[Bp]=z[Vp]=!1;function Qp(e){return Tp(e)&&Ip(e.length)&&!!z[Ep(e)]}var Xp=Qp;function em(e){return function(t){return e(t)}}var tm=em,Zt={exports:{}};Zt.exports;(function(e,t){var n=$i,o=t&&!t.nodeType&&t,i=o&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===o,s=a&&n.process,c=function(){try{var l=i&&i.require&&i.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}}();e.exports=c})(Zt,Zt.exports);var nm=Zt.exports,rm=Xp,om=tm,yo=nm,vo=yo&&yo.isTypedArray,im=vo?om(vo):rm,_r=im,am=sp,sm=yr,cm=Ae,lm=vr,um=hn,dm=_r,fm=Object.prototype,pm=fm.hasOwnProperty;function mm(e,t){var n=cm(e),o=!n&&sm(e),i=!n&&!o&&lm(e),a=!n&&!o&&!i&&dm(e),s=n||o||i||a,c=s?am(e.length,String):[],l=c.length;for(var u in e)(t||pm.call(e,u))&&!(s&&(u=="length"||i&&(u=="offset"||u=="parent")||a&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||um(u,l)))&&c.push(u);return c}var zi=mm,gm=Object.prototype;function hm(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||gm;return e===n}var Sr=hm;function ym(e,t){return function(n){return e(t(n))}}var ji=ym,vm=ji,wm=vm(Object.keys,Object),_m=wm,Sm=Sr,Cm=_m,bm=Object.prototype,Am=bm.hasOwnProperty;function Em(e){if(!Sm(e))return Cm(e);var t=[];for(var n in Object(e))Am.call(e,n)&&n!="constructor"&&t.push(n);return t}var Im=Em,Tm=pr,Nm=wr;function Pm(e){return e!=null&&Nm(e.length)&&!Tm(e)}var yn=Pm,km=zi,xm=Im,Um=yn;function $m(e){return Um(e)?km(e):xm(e)}var Wi=$m,Rm=Bi,Om=Li,Dm=Wi;function Fm(e){return Rm(e,Dm,Om)}var Mm=Fm,wo=Mm,Bm=1,Vm=Object.prototype,Lm=Vm.hasOwnProperty;function Gm(e,t,n,o,i,a){var s=n&Bm,c=wo(e),l=c.length,u=wo(t),d=u.length;if(l!=d&&!s)return!1;for(var m=l;m--;){var f=c[m];if(!(s?f in t:Lm.call(t,f)))return!1}var p=a.get(e),h=a.get(t);if(p&&h)return p==t&&h==e;var v=!0;a.set(e,t),a.set(t,e);for(var S=s;++m<l;){f=c[m];var g=e[f],w=t[f];if(o)var y=s?o(w,g,f,t,e,a):o(g,w,f,e,t,a);if(!(y===void 0?g===w||i(g,w,n,o,a):y)){v=!1;break}S||(S=f=="constructor")}if(v&&!S){var _=e.constructor,b=t.constructor;_!=b&&"constructor"in e&&"constructor"in t&&!(typeof _=="function"&&_ instanceof _&&typeof b=="function"&&b instanceof b)&&(v=!1)}return a.delete(e),a.delete(t),v}var zm=Gm,jm=Oe,Wm=ge,Hm=jm(Wm,"DataView"),Ym=Hm,Km=Oe,qm=ge,Jm=Km(qm,"Promise"),Zm=Jm,Qm=Oe,Xm=ge,eg=Qm(Xm,"Set"),tg=eg,ng=Oe,rg=ge,og=ng(rg,"WeakMap"),ig=og,Yn=Ym,Kn=mr,qn=Zm,Jn=tg,Zn=ig,Hi=et,ot=Oi,_o="[object Map]",ag="[object Object]",So="[object Promise]",Co="[object Set]",bo="[object WeakMap]",Ao="[object DataView]",sg=ot(Yn),cg=ot(Kn),lg=ot(qn),ug=ot(Jn),dg=ot(Zn),$e=Hi;(Yn&&$e(new Yn(new ArrayBuffer(1)))!=Ao||Kn&&$e(new Kn)!=_o||qn&&$e(qn.resolve())!=So||Jn&&$e(new Jn)!=Co||Zn&&$e(new Zn)!=bo)&&($e=function(e){var t=Hi(e),n=t==ag?e.constructor:void 0,o=n?ot(n):"";if(o)switch(o){case sg:return Ao;case cg:return _o;case lg:return So;case ug:return Co;case dg:return bo}return t});var fg=$e,$n=hr,pg=Di,mg=Hf,gg=zm,Eo=fg,Io=Ae,To=vr,hg=_r,yg=1,No="[object Arguments]",Po="[object Array]",Ut="[object Object]",vg=Object.prototype,ko=vg.hasOwnProperty;function wg(e,t,n,o,i,a){var s=Io(e),c=Io(t),l=s?Po:Eo(e),u=c?Po:Eo(t);l=l==No?Ut:l,u=u==No?Ut:u;var d=l==Ut,m=u==Ut,f=l==u;if(f&&To(e)){if(!To(t))return!1;s=!0,d=!1}if(f&&!d)return a||(a=new $n),s||hg(e)?pg(e,t,n,o,i,a):mg(e,t,l,n,o,i,a);if(!(n&yg)){var p=d&&ko.call(e,"__wrapped__"),h=m&&ko.call(t,"__wrapped__");if(p||h){var v=p?e.value():e,S=h?t.value():t;return a||(a=new $n),i(v,S,n,o,a)}}return f?(a||(a=new $n),gg(e,t,n,o,i,a)):!1}var _g=wg,Sg=_g,xo=De;function Yi(e,t,n,o,i){return e===t?!0:e==null||t==null||!xo(e)&&!xo(t)?e!==e&&t!==t:Sg(e,t,n,o,Yi,i)}var Ki=Yi,Cg=hr,bg=Ki,Ag=1,Eg=2;function Ig(e,t,n,o){var i=n.length,a=i,s=!o;if(e==null)return!a;for(e=Object(e);i--;){var c=n[i];if(s&&c[2]?c[1]!==e[c[0]]:!(c[0]in e))return!1}for(;++i<a;){c=n[i];var l=c[0],u=e[l],d=c[1];if(s&&c[2]){if(u===void 0&&!(l in e))return!1}else{var m=new Cg;if(o)var f=o(u,d,l,e,t,m);if(!(f===void 0?bg(d,u,Ag|Eg,o,m):f))return!1}}return!0}var Tg=Ig,Ng=be;function Pg(e){return e===e&&!Ng(e)}var qi=Pg,kg=qi,xg=Wi;function Ug(e){for(var t=xg(e),n=t.length;n--;){var o=t[n],i=e[o];t[n]=[o,i,kg(i)]}return t}var $g=Ug;function Rg(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}var Ji=Rg,Og=Tg,Dg=$g,Fg=Ji;function Mg(e){var t=Dg(e);return t.length==1&&t[0][2]?Fg(t[0][0],t[0][1]):function(n){return n===e||Og(n,e,t)}}var Bg=Mg,Vg=et,Lg=De,Gg="[object Symbol]";function zg(e){return typeof e=="symbol"||Lg(e)&&Vg(e)==Gg}var Cr=zg,jg=Ae,Wg=Cr,Hg=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Yg=/^\w*$/;function Kg(e,t){if(jg(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Wg(e)?!0:Yg.test(e)||!Hg.test(e)||t!=null&&e in Object(t)}var br=Kg,Zi=gr,qg="Expected a function";function Ar(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(qg);var n=function(){var o=arguments,i=t?t.apply(this,o):o[0],a=n.cache;if(a.has(i))return a.get(i);var s=e.apply(this,o);return n.cache=a.set(i,s)||a,s};return n.cache=new(Ar.Cache||Zi),n}Ar.Cache=Zi;var Jg=Ar,Zg=Jg,Qg=500;function Xg(e){var t=Zg(e,function(o){return n.size===Qg&&n.clear(),o}),n=t.cache;return t}var eh=Xg,th=eh,nh=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,rh=/\\(\\)?/g,oh=th(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(nh,function(n,o,i,a){t.push(i?a.replace(rh,"$1"):o||n)}),t}),ih=oh,Uo=pn,ah=Ui,sh=Ae,ch=Cr,lh=1/0,$o=Uo?Uo.prototype:void 0,Ro=$o?$o.toString:void 0;function Qi(e){if(typeof e=="string")return e;if(sh(e))return ah(e,Qi)+"";if(ch(e))return Ro?Ro.call(e):"";var t=e+"";return t=="0"&&1/e==-lh?"-0":t}var uh=Qi,dh=uh;function fh(e){return e==null?"":dh(e)}var ph=fh,mh=Ae,gh=br,hh=ih,yh=ph;function vh(e,t){return mh(e)?e:gh(e,t)?[e]:hh(yh(e))}var vn=vh,wh=Cr,_h=1/0;function Sh(e){if(typeof e=="string"||wh(e))return e;var t=e+"";return t=="0"&&1/e==-_h?"-0":t}var At=Sh,Ch=vn,bh=At;function Ah(e,t){t=Ch(t,e);for(var n=0,o=t.length;e!=null&&n<o;)e=e[bh(t[n++])];return n&&n==o?e:void 0}var Er=Ah,Eh=Er;function Ih(e,t,n){var o=e==null?void 0:Eh(e,t);return o===void 0?n:o}var Th=Ih;function Nh(e,t){return e!=null&&t in Object(e)}var Ph=Nh,kh=vn,xh=yr,Uh=Ae,$h=hn,Rh=wr,Oh=At;function Dh(e,t,n){t=kh(t,e);for(var o=-1,i=t.length,a=!1;++o<i;){var s=Oh(t[o]);if(!(a=e!=null&&n(e,s)))break;e=e[s]}return a||++o!=i?a:(i=e==null?0:e.length,!!i&&Rh(i)&&$h(s,i)&&(Uh(e)||xh(e)))}var Fh=Dh,Mh=Ph,Bh=Fh;function Vh(e,t){return e!=null&&Bh(e,t,Mh)}var Lh=Vh,Gh=Ki,zh=Th,jh=Lh,Wh=br,Hh=qi,Yh=Ji,Kh=At,qh=1,Jh=2;function Zh(e,t){return Wh(e)&&Hh(t)?Yh(Kh(e),t):function(n){var o=zh(n,e);return o===void 0&&o===t?jh(n,e):Gh(t,o,qh|Jh)}}var Qh=Zh;function Xh(e){return e}var Ir=Xh;function ey(e){return function(t){return t==null?void 0:t[e]}}var ty=ey,ny=Er;function ry(e){return function(t){return ny(t,e)}}var oy=ry,iy=ty,ay=oy,sy=br,cy=At;function ly(e){return sy(e)?iy(cy(e)):ay(e)}var uy=ly,dy=Bg,fy=Qh,py=Ir,my=Ae,gy=uy;function hy(e){return typeof e=="function"?e:e==null?py:typeof e=="object"?my(e)?fy(e[0],e[1]):dy(e):gy(e)}var yy=hy,vy=Oe,wy=function(){try{var e=vy(Object,"defineProperty");return e({},"",{}),e}catch{}}(),Xi=wy,Oo=Xi;function _y(e,t,n){t=="__proto__"&&Oo?Oo(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var Tr=_y,Sy=Tr,Cy=bt,by=Object.prototype,Ay=by.hasOwnProperty;function Ey(e,t,n){var o=e[t];(!(Ay.call(e,t)&&Cy(o,n))||n===void 0&&!(t in e))&&Sy(e,t,n)}var ea=Ey,Iy=ea,Ty=vn,Ny=hn,Do=be,Py=At;function ky(e,t,n,o){if(!Do(e))return e;t=Ty(t,e);for(var i=-1,a=t.length,s=a-1,c=e;c!=null&&++i<a;){var l=Py(t[i]),u=n;if(l==="__proto__"||l==="constructor"||l==="prototype")return e;if(i!=s){var d=c[l];u=o?o(d,l,c):void 0,u===void 0&&(u=Do(d)?d:Ny(t[i+1])?[]:{})}Iy(c,l,u),c=c[l]}return e}var xy=ky,Uy=Er,$y=xy,Ry=vn;function Oy(e,t,n){for(var o=-1,i=t.length,a={};++o<i;){var s=t[o],c=Uy(e,s);n(c,s)&&$y(a,Ry(s,e),c)}return a}var Dy=Oy,Fy=ji,My=Fy(Object.getPrototypeOf,Object),Nr=My,By=Mi,Vy=Nr,Ly=Li,Gy=Vi,zy=Object.getOwnPropertySymbols,jy=zy?function(e){for(var t=[];e;)By(t,Ly(e)),e=Vy(e);return t}:Gy,Wy=jy;function Hy(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var Yy=Hy,Ky=be,qy=Sr,Jy=Yy,Zy=Object.prototype,Qy=Zy.hasOwnProperty;function Xy(e){if(!Ky(e))return Jy(e);var t=qy(e),n=[];for(var o in e)o=="constructor"&&(t||!Qy.call(e,o))||n.push(o);return n}var ev=Xy,tv=zi,nv=ev,rv=yn;function ov(e){return rv(e)?tv(e,!0):nv(e)}var Pr=ov,iv=Bi,av=Wy,sv=Pr;function cv(e){return iv(e,sv,av)}var lv=cv,uv=Ui,dv=yy,fv=Dy,pv=lv;function mv(e,t){if(e==null)return{};var n=uv(pv(e),function(o){return[o]});return t=dv(t),fv(e,n,function(o,i){return t(o,i[0])})}var gv=mv;const hv=xi(gv),yv=!0,vv="",wn=(e,t)=>`${e}${t}`.replace(/[^A-Z0-9+]/gi,""),wv=(e,t)=>{switch(t){case"address":case"birthdate":case"email":case"family_name":case"gender":case"given_name":case"locale":case"middle_name":case"name":case"nickname":case"phone_number":case"picture":case"preferred_username":case"profile":case"updated_at":case"website":case"zoneinfo":return!0;default:return t.startsWith("custom:")}},_v=e=>{const{phone_number:t,...n}=hv(e,wv);if(Jo(t)&&t!==vv){const{country_code:o}=e;return{...n,phone_number:wn(o,t)}}return n},Sv=(e,t,n)=>{const{password:o,...i}=t,a=_v(i),s={autoSignIn:yv,userAttributes:{...n==="phone_number"?{...a,phone_number:e}:a}};return{username:e,password:o,options:s}},Cv=({formValues:e,loginMechanisms:t})=>{const n=t[0];if(n==="phone_number"){const{country_code:o,phone_number:i}=e;return wn(o,i)}return e[n]},{assign:B}=Ai,bv=B({actorDoneData:void 0}),Av=B({challengeName:void 0}),Ev=B({missingAttributes:void 0}),Iv=B({remoteError:void 0}),Tv=B({formValues:{}}),Nv=B({touched:{}}),Pv=B({user:void 0}),kv=B({validationError:{}}),xv=B({totpSecretCode:(e,{data:t})=>{var o;const{sharedSecret:n}=((o=t.nextStep)==null?void 0:o.totpSetupDetails)??{};return n}}),Uv=B({step:"SIGN_IN"}),$v=B({step:"SHOULD_CONFIRM_USER_ATTRIBUTE"}),Rv=B({step:"CONFIRM_ATTRIBUTE_COMPLETE"}),Ov=B({challengeName:(e,{data:t})=>{const{signInStep:n}=t.nextStep;return n==="CONFIRM_SIGN_IN_WITH_SMS_CODE"?"SMS_MFA":n==="CONFIRM_SIGN_IN_WITH_TOTP_CODE"?"SOFTWARE_TOKEN_MFA":void 0}}),Dv=B({username:({formValues:e,loginMechanisms:t})=>{const n=t[0],{username:o,country_code:i}=e;return n==="phone_number"?wn(i,o):o}}),Fv=B({username:Cv}),Mv=B({username:({formValues:e,loginMechanisms:t})=>{const n=t[0],{username:o,country_code:i}=e;return n==="phone_number"?wn(i,o):o}}),Bv=B({step:(e,{data:t})=>t.nextStep.signInStep==="DONE"?"SIGN_IN_COMPLETE":t.nextStep.signInStep}),Vv=B({step:(e,{data:t})=>t.nextStep.signUpStep==="DONE"?"SIGN_UP_COMPLETE":t.nextStep.signUpStep}),Lv=B({step:(e,{data:t})=>t.nextStep.resetPasswordStep==="DONE"?"RESET_PASSWORD_COMPLETE":t.nextStep.resetPasswordStep}),Gv=B({missingAttributes:(e,{data:t})=>{var n;return(n=t.nextStep)==null?void 0:n.missingAttributes}}),zv=B({validationError:(e,{data:t})=>t}),jv=B({remoteError:(e,{data:t})=>t.name==="NoUserPoolError"?"Configuration error (see console) – please contact the administrator":(t==null?void 0:t.message)||t}),Wv=B({user:(e,{data:t})=>t}),Fo=e=>({Destination:e.destination,DeliveryMedium:e.deliveryMedium,AttributeName:e.attributName}),Hv=B({codeDeliveryDetails:(e,{data:t})=>{var n;return(n=t==null?void 0:t.nextStep)!=null&&n.codeDeliveryDetails?Fo(t.nextStep.codeDeliveryDetails):Fo(t)}}),Yv=B({formValues:(e,{data:t})=>{const{name:n,value:o}=t;return{...e.formValues,[n]:o}}}),Kv=B({formValues:(e,{data:t})=>ds({...e.formValues,...t},"password")}),qv=B({touched:(e,{data:t})=>({...e.touched,[t.name]:!0})}),Jv=B({unverifiedUserAttributes:(e,{data:t})=>{const{email:n,phone_number:o}=t;return{...n&&{email:n},...o&&{phone_number:o}}}}),Zv=B({selectedUserAttribute:void 0}),Qv=B({selectedUserAttribute:e=>{var t;return(t=e.formValues)==null?void 0:t.unverifiedAttr}}),Xv=B({step:"CONFIRM_SIGN_UP"}),Et={clearActorDoneData:bv,clearChallengeName:Av,clearError:Iv,clearFormValues:Tv,clearMissingAttributes:Ev,clearSelectedUserAttribute:Zv,clearTouched:Nv,clearUser:Pv,clearValidationError:kv,handleBlur:qv,handleInput:Yv,handleSubmit:Kv,setChallengeName:Ov,setCodeDeliveryDetails:Hv,setFieldErrors:zv,setMissingAttributes:Gv,setNextResetPasswordStep:Lv,setNextSignInStep:Bv,setNextSignUpStep:Vv,setRemoteError:jv,setConfirmAttributeCompleteStep:Rv,setConfirmSignUpSignUpStep:Xv,setShouldVerifyUserAttributeStep:$v,setSelectedUserAttribute:Qv,setSignInStep:Uv,setTotpSecretCode:xv,setUser:Wv,setUnverifiedUserAttributes:Jv,setUsernameForgotPassword:Dv,setUsernameSignIn:Mv,setUsernameSignUp:Fv},ew=["CONFIRM_SIGN_IN_WITH_SMS_CODE","CONFIRM_SIGN_IN_WITH_TOTP_CODE"],tw=(e,{data:t})=>(t==null?void 0:t.nextStep.signInStep)==="CONFIRM_SIGN_IN_WITH_NEW_PASSWORD_REQUIRED",nw=(e,{data:t})=>{var n;return((n=t==null?void 0:t.nextStep)==null?void 0:n.signInStep)==="RESET_PASSWORD"},rw=(e,{data:t})=>(t==null?void 0:t.nextStep.signInStep)==="CONFIRM_SIGN_UP",ow=(e,{data:t})=>(t==null?void 0:t.nextStep.signUpStep)==="COMPLETE_AUTO_SIGN_IN",iw=(e,{data:t})=>(t==null?void 0:t.nextStep.signInStep)==="DONE",aw=(e,{data:t})=>(t==null?void 0:t.nextStep.signUpStep)==="DONE",sw=(e,{data:t})=>(t==null?void 0:t.nextStep.resetPasswordStep)==="DONE",cw=(e,{data:t})=>(t==null?void 0:t.step)==="CONFIRM_ATTRIBUTE_COMPLETE",lw=(e,{data:t})=>(t==null?void 0:t.step)==="CONFIRM_ATTRIBUTE_WITH_CODE",uw=(e,{data:t})=>(t==null?void 0:t.step)==="SHOULD_CONFIRM_USER_ATTRIBUTE",dw=(e,{data:t})=>(t==null?void 0:t.step)==="RESET_PASSWORD",fw=(e,{data:t})=>(t==null?void 0:t.step)==="CONFIRM_SIGN_UP",pw=({step:e})=>ew.includes(e),mw=({step:e})=>e==="CONTINUE_SIGN_IN_WITH_TOTP_SETUP",gw=({step:e})=>e==="RESET_PASSWORD",hw=({step:e})=>e==="CONFIRM_RESET_PASSWORD_WITH_CODE",yw=({step:e})=>e==="CONFIRM_SIGN_UP",vw=(e,{data:t})=>{const{phone_number_verified:n,email_verified:o}=t;return(o===void 0||o==="false")&&(n===void 0||n==="false")},ww=(e,{data:t})=>t.message==="User is already confirmed.",_n={hasCompletedAttributeConfirmation:cw,hasCompletedResetPassword:sw,hasCompletedSignIn:iw,hasCompletedSignUp:aw,isConfirmSignUpStep:fw,isConfirmUserAttributeStep:lw,isResetPasswordStep:dw,isShouldConfirmUserAttributeStep:uw,isUserAlreadyConfirmed:ww,shouldAutoSignIn:ow,shouldConfirmResetPassword:hw,shouldConfirmSignIn:pw,shouldConfirmSignInWithNewPassword:tw,shouldConfirmSignUp:yw,shouldConfirmSignUpFromSignIn:rw,shouldResetPassword:gw,shouldResetPasswordFromSignIn:nw,shouldSetupTotp:mw,shouldVerifyAttribute:vw};var _w=Tr,Sw=bt;function Cw(e,t,n){(n!==void 0&&!Sw(e[t],n)||n===void 0&&!(t in e))&&_w(e,t,n)}var ta=Cw;function bw(e){return function(t,n,o){for(var i=-1,a=Object(t),s=o(t),c=s.length;c--;){var l=s[e?c:++i];if(n(a[l],l,a)===!1)break}return t}}var Aw=bw,Ew=Aw,Iw=Ew(),Tw=Iw,Qt={exports:{}};Qt.exports;(function(e,t){var n=ge,o=t&&!t.nodeType&&t,i=o&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===o,s=a?n.Buffer:void 0,c=s?s.allocUnsafe:void 0;function l(u,d){if(d)return u.slice();var m=u.length,f=c?c(m):new u.constructor(m);return u.copy(f),f}e.exports=l})(Qt,Qt.exports);var Nw=Qt.exports,Mo=Fi;function Pw(e){var t=new e.constructor(e.byteLength);return new Mo(t).set(new Mo(e)),t}var kw=Pw,xw=kw;function Uw(e,t){var n=t?xw(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var $w=Uw;function Rw(e,t){var n=-1,o=e.length;for(t||(t=Array(o));++n<o;)t[n]=e[n];return t}var Ow=Rw,Dw=be,Bo=Object.create,Fw=function(){function e(){}return function(t){if(!Dw(t))return{};if(Bo)return Bo(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}(),Mw=Fw,Bw=Mw,Vw=Nr,Lw=Sr;function Gw(e){return typeof e.constructor=="function"&&!Lw(e)?Bw(Vw(e)):{}}var zw=Gw,jw=yn,Ww=De;function Hw(e){return Ww(e)&&jw(e)}var Yw=Hw,Kw=et,qw=Nr,Jw=De,Zw="[object Object]",Qw=Function.prototype,Xw=Object.prototype,na=Qw.toString,e_=Xw.hasOwnProperty,t_=na.call(Object);function n_(e){if(!Jw(e)||Kw(e)!=Zw)return!1;var t=qw(e);if(t===null)return!0;var n=e_.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&na.call(n)==t_}var r_=n_;function o_(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var ra=o_,i_=ea,a_=Tr;function s_(e,t,n,o){var i=!n;n||(n={});for(var a=-1,s=t.length;++a<s;){var c=t[a],l=o?o(n[c],e[c],c,n,e):void 0;l===void 0&&(l=e[c]),i?a_(n,c,l):i_(n,c,l)}return n}var c_=s_,l_=c_,u_=Pr;function d_(e){return l_(e,u_(e))}var f_=d_,Vo=ta,p_=Nw,m_=$w,g_=Ow,h_=zw,Lo=yr,Go=Ae,y_=Yw,v_=vr,w_=pr,__=be,S_=r_,C_=_r,zo=ra,b_=f_;function A_(e,t,n,o,i,a,s){var c=zo(e,n),l=zo(t,n),u=s.get(l);if(u){Vo(e,n,u);return}var d=a?a(c,l,n+"",e,t,s):void 0,m=d===void 0;if(m){var f=Go(l),p=!f&&v_(l),h=!f&&!p&&C_(l);d=l,f||p||h?Go(c)?d=c:y_(c)?d=g_(c):p?(m=!1,d=p_(l,!0)):h?(m=!1,d=m_(l,!0)):d=[]:S_(l)||Lo(l)?(d=c,Lo(c)?d=b_(c):(!__(c)||w_(c))&&(d=h_(l))):m=!1}m&&(s.set(l,d),i(d,l,o,a,s),s.delete(l)),Vo(e,n,d)}var E_=A_,I_=hr,T_=ta,N_=Tw,P_=E_,k_=be,x_=Pr,U_=ra;function oa(e,t,n,o,i){e!==t&&N_(t,function(a,s){if(i||(i=new I_),k_(a))P_(e,t,s,n,oa,o,i);else{var c=o?o(U_(e,s),a,s+"",e,t,i):void 0;c===void 0&&(c=a),T_(e,s,c)}},x_)}var $_=oa;function R_(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var O_=R_,D_=O_,jo=Math.max;function F_(e,t,n){return t=jo(t===void 0?e.length-1:t,0),function(){for(var o=arguments,i=-1,a=jo(o.length-t,0),s=Array(a);++i<a;)s[i]=o[t+i];i=-1;for(var c=Array(t+1);++i<t;)c[i]=o[i];return c[t]=n(s),D_(e,this,c)}}var M_=F_;function B_(e){return function(){return e}}var V_=B_,L_=V_,Wo=Xi,G_=Ir,z_=Wo?function(e,t){return Wo(e,"toString",{configurable:!0,enumerable:!1,value:L_(t),writable:!0})}:G_,j_=z_,W_=800,H_=16,Y_=Date.now;function K_(e){var t=0,n=0;return function(){var o=Y_(),i=H_-(o-n);if(n=o,i>0){if(++t>=W_)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var q_=K_,J_=j_,Z_=q_,Q_=Z_(J_),X_=Q_,eS=Ir,tS=M_,nS=X_;function rS(e,t){return nS(tS(e,t,eS),e+"")}var oS=rS,iS=bt,aS=yn,sS=hn,cS=be;function lS(e,t,n){if(!cS(n))return!1;var o=typeof t;return(o=="number"?aS(n)&&sS(t,n.length):o=="string"&&t in n)?iS(n[t],e):!1}var uS=lS,dS=oS,fS=uS;function pS(e){return dS(function(t,n){var o=-1,i=n.length,a=i>1?n[i-1]:void 0,s=i>2?n[2]:void 0;for(a=e.length>3&&typeof a=="function"?(i--,a):void 0,s&&fS(n[0],n[1],s)&&(a=i<3?void 0:a,i=1),t=Object(t);++o<i;){var c=n[o];c&&e(t,c,o,a)}return t})}var mS=pS,gS=$_,hS=mS,yS=hS(function(e,t,n){gS(e,t,n)}),vS=yS;const wS=xi(vS),Sn=async(e,t,n,o)=>{const i=await Promise.all(o.map(s=>s(e,t,n))),a=wS({},...i);return Zo(a)?Promise.resolve():Promise.reject(a)},_S=8,SS=e=>Array.isArray(e),CS=e=>{if(e)return SS(e)?Object.entries(e).map(([t,n])=>Object.keys(n)[0]):Object.keys(e)},ke={async getAmplifyConfig(){var c,l,u,d;const e=Ua.Amplify.getConfig(),t=(c=e.Auth)==null?void 0:c.Cognito,{loginWith:n,userAttributes:o}=((l=e.Auth)==null?void 0:l.Cognito)??{},i=n?Object.entries(n).filter(([m,f])=>m!=="oauth").filter(([m,f])=>!!f).map(m=>m[0]==="phone"?"phone_number":m[0]):void 0,a=CS(o),s=(u=n==null?void 0:n.oauth)!=null&&u.providers?(d=n.oauth.providers)==null?void 0:d.map(m=>m.toString().toLowerCase()):void 0;return{...t,loginMechanisms:i,signUpAttributes:a,socialProviders:s}},getCurrentUser:H.getCurrentUser,handleSignIn:H.signIn,handleSignUp:H.signUp,handleConfirmSignIn:H.confirmSignIn,handleConfirmSignUp:H.confirmSignUp,handleForgotPasswordSubmit:H.confirmResetPassword,handleForgotPassword:H.resetPassword,async validateCustomSignUp(e,t){},async validateFormPassword(e,t,n){const{password:o}=e,{password:i}=t;if(!i||!n)return null;const a=[],s=n.minLength??_S;return o.length<s&&a.push(`Password must have at least ${s} characters`),n.requireLowercase&&!/[a-z]/.test(o)&&a.push("Password must have lower case letters"),n.requireUppercase&&!/[A-Z]/.test(o)&&a.push("Password must have upper case letters"),n.requireNumbers&&!/[0-9]/.test(o)&&a.push("Password must have numbers"),n.requireSpecialCharacters&&!ls(o)&&a.push("Password must have special characters"),a.length!==0?{password:a}:null},async validateConfirmPassword(e,t){const{password:n,confirm_password:o}=e,{confirm_password:i,password:a}=t;if(!n&&!o)return null;if((n||o)&&n!==o&&(i&&a||(n==null?void 0:n.length)>=6&&(o==null?void 0:o.length)>=6))return{confirm_password:"Your passwords must match"}},async validatePreferredUsername(e,t){}};function bS({services:e}){return Qe({id:"forgotPasswordActor",initial:"init",predictableActionArguments:!0,states:{init:{always:[{cond:"shouldResetPassword",target:"confirmResetPassword"},{cond:"shouldConfirmResetPassword",target:"confirmResetPassword"},{target:"forgotPassword"}]},forgotPassword:{initial:"edit",entry:"sendUpdate",exit:["clearError","clearTouched"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},CHANGE:{actions:"handleInput"},BLUR:{actions:"handleBlur"}}},submit:{tags:"pending",entry:["sendUpdate","clearError","setUsernameForgotPassword"],invoke:{src:"handleResetPassword",onDone:{actions:["setCodeDeliveryDetails","setNextResetPasswordStep"],target:"#forgotPasswordActor.confirmResetPassword"},onError:{actions:"setRemoteError",target:"edit"}}}}},confirmResetPassword:{type:"parallel",exit:["clearFormValues","clearError","clearTouched"],states:{validation:{initial:"pending",states:{pending:{invoke:{src:"validateFields",onDone:{target:"valid",actions:"clearValidationError"},onError:{target:"invalid",actions:"setFieldErrors"}}},valid:{entry:"sendUpdate"},invalid:{entry:"sendUpdate"}},on:{CHANGE:{actions:"handleInput",target:".pending"},BLUR:{actions:"handleBlur",target:".pending"}}},submission:{initial:"idle",states:{idle:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"validate"},RESEND:"resendCode",CHANGE:{actions:"handleInput"},BLUR:{actions:"handleBlur"}}},validate:{entry:"sendUpdate",invoke:{src:"validateFields",onDone:{target:"pending",actions:"clearValidationError"},onError:{target:"idle",actions:"setFieldErrors"}}},resendCode:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"handleResetPassword",onDone:{target:"idle"},onError:{actions:"setRemoteError",target:"idle"}}},pending:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"handleConfirmResetPassword",onDone:[{cond:"hasCompletedResetPassword",actions:"setNextResetPasswordStep",target:"#forgotPasswordActor.resolved"},{actions:"setSignInStep",target:"#forgotPasswordActor.resolved"}],onError:{actions:"setRemoteError",target:"idle"}}}}}}},resolved:{type:"final",data:({step:t})=>({step:t})}}},{actions:{...Et,sendUpdate:un()},guards:_n,services:{handleResetPassword({username:t}){return e.handleForgotPassword({username:t})},handleConfirmResetPassword({formValues:t,username:n}){const{confirmation_code:o,password:i}=t;return e.handleForgotPasswordSubmit({confirmationCode:o,newPassword:i,username:n})},validateFields(t){return Sn(t.formValues,t.touched,t.passwordSettings,[ke.validateFormPassword,ke.validateConfirmPassword])}}})}const ia=e=>({entry:["sendUpdate","clearError"],invoke:{src:"signInWithRedirect",onDone:{target:e},onError:{actions:"setRemoteError",target:e}}}),$t={onDone:[{cond:"hasCompletedSignIn",actions:"setNextSignInStep",target:"#signInActor.fetchUserAttributes"},{cond:"shouldConfirmSignInWithNewPassword",actions:["setMissingAttributes","setNextSignInStep"],target:"#signInActor.forceChangePassword"},{cond:"shouldResetPasswordFromSignIn",actions:"setNextSignInStep",target:"#signInActor.resetPassword"},{cond:"shouldConfirmSignUpFromSignIn",actions:"setNextSignInStep",target:"#signInActor.resendSignUpCode"},{actions:["setChallengeName","setMissingAttributes","setNextSignInStep","setTotpSecretCode"],target:"#signInActor.init"}],onError:{actions:"setRemoteError",target:"edit"}},AS={onDone:[{cond:"shouldVerifyAttribute",actions:["setShouldVerifyUserAttributeStep","setUnverifiedUserAttributes"],target:"#signInActor.resolved"},{actions:"setConfirmAttributeCompleteStep",target:"#signInActor.resolved"}],onError:{actions:"setConfirmAttributeCompleteStep",target:"#signInActor.resolved"}};function ES({services:e}){return Qe({id:"signInActor",initial:"init",predictableActionArguments:!0,states:{init:{always:[{cond:"shouldConfirmSignIn",target:"confirmSignIn"},{cond:"shouldSetupTotp",target:"setupTotp"},{cond:({step:t})=>t==="CONFIRM_SIGN_IN_WITH_NEW_PASSWORD_REQUIRED",actions:"setActorDoneData",target:"forceChangePassword"},{target:"signIn"}]},federatedSignIn:ia("signIn"),fetchUserAttributes:{invoke:{src:"fetchUserAttributes",...AS}},resendSignUpCode:{invoke:{src:"handleResendSignUpCode",onDone:{actions:"setCodeDeliveryDetails",target:"#signInActor.resolved"},onError:{actions:"setRemoteError",target:"#signInActor.signIn"}}},resetPassword:{invoke:{src:"resetPassword",onDone:[{actions:"setCodeDeliveryDetails",target:"#signInActor.resolved"}],onError:{actions:["setRemoteError","sendUpdate"]}}},signIn:{initial:"edit",exit:"clearTouched",states:{edit:{entry:"sendUpdate",on:{CHANGE:{actions:"handleInput"},FEDERATED_SIGN_IN:{target:"#signInActor.federatedSignIn"},SUBMIT:{actions:"handleSubmit",target:"submit"}}},submit:{tags:"pending",entry:["clearError","sendUpdate","setUsernameSignIn"],exit:"clearFormValues",invoke:{src:"handleSignIn",...$t}}}},confirmSignIn:{initial:"edit",exit:["clearChallengeName","clearFormValues","clearError","clearTouched"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},SIGN_IN:"#signInActor.signIn",CHANGE:{actions:"handleInput"}}},submit:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"confirmSignIn",...$t}}}},forceChangePassword:{entry:"sendUpdate",type:"parallel",exit:["clearFormValues","clearError","clearTouched"],states:{validation:{initial:"pending",states:{pending:{invoke:{src:"validateFields",onDone:{target:"valid",actions:"clearValidationError"},onError:{target:"invalid",actions:"setFieldErrors"}}},valid:{entry:"sendUpdate"},invalid:{entry:"sendUpdate"}},on:{SIGN_IN:{actions:"setSignInStep",target:"#signInActor.resolved"},CHANGE:{actions:"handleInput",target:".pending"},BLUR:{actions:"handleBlur",target:".pending"}}},submit:{initial:"edit",entry:"clearError",states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"validate"}}},validate:{entry:"sendUpdate",invoke:{src:"validateFields",onDone:{actions:"clearValidationError",target:"pending"},onError:{actions:"setFieldErrors",target:"edit"}}},pending:{tags:"pending",entry:["sendUpdate","clearError"],invoke:{src:"handleForceChangePassword",...$t}}}}}},setupTotp:{initial:"edit",exit:["clearFormValues","clearError","clearTouched"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},SIGN_IN:"#signInActor.signIn",CHANGE:{actions:"handleInput"}}},submit:{tags:"pending",entry:["sendUpdate","clearError"],invoke:{src:"confirmSignIn",...$t}}}},resolved:{type:"final",data:t=>({codeDeliveryDetails:t.codeDeliveryDetails,remoteError:t.remoteError,step:t.step,unverifiedUserAttributes:t.unverifiedUserAttributes,username:t.username})}}},{actions:{...Et,sendUpdate:un()},guards:_n,services:{async fetchUserAttributes(){return H.fetchUserAttributes()},resetPassword({username:t}){return H.resetPassword({username:t})},handleResendSignUpCode({username:t}){return H.resendSignUpCode({username:t})},handleSignIn({formValues:t,username:n}){const{password:o}=t;return e.handleSignIn({username:n,password:o})},confirmSignIn({formValues:t}){const{confirmation_code:n}=t;return e.handleConfirmSignIn({challengeResponse:n})},async handleForceChangePassword({formValues:t}){let{password:n,phone_number:o,country_code:i,confirm_password:a,...s}=t,c;o&&(c=`${i}${o}`.replace(/[^A-Z0-9+]/gi,""),s={...s,phone_number:c});const l={challengeResponse:n,options:{userAttributes:s}};return H.confirmSignIn(l)},signInWithRedirect(t,{data:n}){return H.signInWithRedirect(n)},async validateFields(t){return Sn(t.formValues,t.touched,t.passwordSettings,[ke.validateFormPassword,ke.validateConfirmPassword])}}})}const IS={onDone:[{actions:"setCodeDeliveryDetails",target:"#signUpActor.resolved"}],onError:{actions:["setRemoteError","sendUpdate"]}},TS={onDone:[{cond:"hasCompletedSignIn",actions:"setNextSignInStep",target:"#signUpActor.fetchUserAttributes"},{cond:"shouldConfirmSignInWithNewPassword",actions:"setNextSignInStep",target:"#signUpActor.resolved"},{cond:"shouldResetPasswordFromSignIn",actions:"setNextSignInStep",target:"#signUpActor.resetPassword"},{cond:"shouldConfirmSignUpFromSignIn",actions:"setNextSignInStep",target:"#signUpActor.resendSignUpCode"},{actions:["setNextSignInStep","setChallengeName","setMissingAttributes","setTotpSecretCode"],target:"#signUpActor.resolved"}],onError:{actions:"setRemoteError",target:"#signUpActor.resolved"}},NS={onDone:[{cond:"shouldVerifyAttribute",actions:["setShouldVerifyUserAttributeStep","setUnverifiedUserAttributes"],target:"#signUpActor.resolved"},{actions:"setConfirmAttributeCompleteStep",target:"#signUpActor.resolved"}],onError:{actions:"setConfirmAttributeCompleteStep",target:"#signUpActor.resolved"}};function PS({services:e}){return Qe({id:"signUpActor",initial:"init",predictableActionArguments:!0,states:{init:{always:[{cond:"shouldConfirmSignUp",target:"confirmSignUp"},{target:"signUp"}]},autoSignIn:{tags:"pending",invoke:{src:"autoSignIn",...TS}},fetchUserAttributes:{invoke:{src:"fetchUserAttributes",...NS}},federatedSignIn:ia("signUp"),resetPassword:{invoke:{src:"resetPassword",...IS}},resendSignUpCode:{tags:"pending",entry:"sendUpdate",exit:"sendUpdate",invoke:{src:"resendSignUpCode",onDone:{actions:["setCodeDeliveryDetails","sendUpdate"],target:"#signUpActor.confirmSignUp"},onError:[{cond:"isUserAlreadyConfirmed",target:"#signUpActor.resolved"},{actions:["setRemoteError","sendUpdate"]}]}},signUp:{type:"parallel",exit:"clearTouched",on:{FEDERATED_SIGN_IN:{target:"federatedSignIn"}},states:{validation:{initial:"pending",states:{pending:{invoke:{src:"validateSignUp",onDone:{actions:"clearValidationError",target:"valid"},onError:{actions:"setFieldErrors",target:"invalid"}}},valid:{entry:"sendUpdate"},invalid:{entry:"sendUpdate"}},on:{BLUR:{actions:"handleBlur",target:".pending"},CHANGE:{actions:"handleInput",target:".pending"}}},submission:{initial:"idle",states:{idle:{entry:["sendUpdate"],on:{SUBMIT:{actions:"handleSubmit",target:"validate"}}},validate:{entry:"sendUpdate",invoke:{src:"validateSignUp",onDone:{target:"handleSignUp",actions:"clearValidationError"},onError:{actions:"setFieldErrors",target:"idle"}}},handleSignUp:{tags:"pending",entry:["setUsernameSignUp","clearError"],exit:"sendUpdate",invoke:{src:"handleSignUp",onDone:[{cond:"hasCompletedSignUp",actions:"setNextSignUpStep",target:"#signUpActor.resolved"},{cond:"shouldAutoSignIn",actions:"setNextSignUpStep",target:"#signUpActor.autoSignIn"},{actions:["setCodeDeliveryDetails","setNextSignUpStep"],target:"#signUpActor.init"}],onError:{actions:["sendUpdate","setRemoteError"],target:"idle"}}}}}}},confirmSignUp:{initial:"edit",entry:"sendUpdate",states:{edit:{on:{SUBMIT:{actions:"handleSubmit",target:"submit"},CHANGE:{actions:"handleInput"},BLUR:{actions:"handleBlur"},RESEND:"#signUpActor.resendSignUpCode"}},submit:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"confirmSignUp",onDone:[{cond:"shouldAutoSignIn",actions:["setNextSignUpStep","clearFormValues"],target:"#signUpActor.autoSignIn"},{actions:"setNextSignUpStep",target:"#signUpActor.init"}],onError:{actions:["setRemoteError","sendUpdate"],target:"edit"}}}}},resolved:{type:"final",data:t=>({challengeName:t.challengeName,missingAttributes:t.missingAttributes,remoteError:t.remoteError,step:t.step,totpSecretCode:t.totpSecretCode,username:t.username,unverifiedUserAttributes:t.unverifiedUserAttributes})}}},{actions:{...Et,sendUpdate:un()},guards:_n,services:{autoSignIn(){return H.autoSignIn()},async fetchUserAttributes(){return H.fetchUserAttributes()},confirmSignUp({formValues:t,username:n}){const{confirmation_code:o}=t,i={username:n,confirmationCode:o};return e.handleConfirmSignUp(i)},resendSignUpCode({username:t}){return H.resendSignUpCode({username:t})},signInWithRedirect(t,{data:n}){return H.signInWithRedirect(n)},handleSignUp(t){const{formValues:n,loginMechanisms:o,username:i}=t,a=o[0],s=Sv(i,n,a);return e.handleSignUp(s)},async validateSignUp(t){return Sn(t.formValues,t.touched,t.passwordSettings,[e.validateFormPassword,e.validateConfirmPassword,e.validatePreferredUsername,e.validateCustomSignUp])}}})}const kS=()=>Qe({initial:"pending",id:"signOutActor",predictableActionArguments:!0,states:{pending:{tags:"pending",invoke:{src:"signOut",onDone:"resolved",onError:"rejected"}},resolved:{type:"final"},rejected:{type:"final"}}},{services:{signOut:()=>H.signOut()}});function xS(){return Qe({id:"verifyUserAttributesActor",initial:"selectUserAttributes",predictableActionArguments:!0,states:{selectUserAttributes:{initial:"edit",exit:["clearError","clearTouched","sendUpdate"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},SKIP:{target:"#verifyUserAttributesActor.resolved"},CHANGE:{actions:"handleInput"}}},submit:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"sendUserAttributeVerificationCode",onDone:{actions:["setSelectedUserAttribute","setCodeDeliveryDetails"],target:"#verifyUserAttributesActor.confirmVerifyUserAttribute"},onError:{actions:"setRemoteError",target:"edit"}}}}},confirmVerifyUserAttribute:{initial:"edit",exit:["clearError","clearFormValues","clearTouched"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},SKIP:"#verifyUserAttributesActor.resolved",CHANGE:{actions:"handleInput"}}},submit:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"confirmVerifyUserAttribute",onDone:{actions:["setConfirmAttributeCompleteStep","clearSelectedUserAttribute"],target:"#verifyUserAttributesActor.resolved"},onError:{actions:"setRemoteError",target:"edit"}}}}},resolved:{type:"final",data:({step:e})=>({step:e})}}},{actions:{...Et,sendUpdate:un()},services:{sendUserAttributeVerificationCode({formValues:{unverifiedAttr:e}}){const t={userAttributeKey:e};return H.sendUserAttributeVerificationCode(t)},async confirmVerifyUserAttribute({formValues:{confirmation_code:e},selectedUserAttribute:t}){const n={confirmationCode:e,userAttributeKey:t};return H.confirmUserAttribute(n)},async validateFields(e){return Sn(e.formValues,e.touched,e.passwordSettings,[ke.validateFormPassword,ke.validateConfirmPassword])}}})}const Rt=(e,t)=>{var n,o,i,a,s,c;return{...e.actorDoneData,step:((n=e==null?void 0:e.actorDoneData)==null?void 0:n.step)??t,formValues:{},touched:{},validationError:{},formFields:(o=e.config)==null?void 0:o.formFields,loginMechanisms:(i=e.config)==null?void 0:i.loginMechanisms,passwordSettings:(a=e.config)==null?void 0:a.passwordSettings,signUpAttributes:(s=e.config)==null?void 0:s.signUpAttributes,socialProviders:(c=e.config)==null?void 0:c.socialProviders}},{choose:US,stop:$S}=Ai,lt=e=>$S(e),RS={on:{INIT:{actions:"configure",target:"getConfig"},SIGN_OUT:"#authenticator.signOut"}},OS={always:{actions:"configure",target:"getConfig"}};function DS(e){const{useNextWaitConfig:t,...n}=e??{};return Qe({id:"authenticator",initial:"idle",context:{user:void 0,config:{},services:ke,actorRef:void 0,hasSetup:!1},predictableActionArguments:!0,states:{idle:{invoke:{src:"handleGetCurrentUser",onDone:{actions:"setUser",target:"setup"},onError:{target:"setup"}}},setup:{initial:"initConfig",states:{initConfig:t?OS:RS,getConfig:{invoke:{src:"getAmplifyConfig",onDone:[{actions:["applyAmplifyConfig","setHasSetup"],cond:"hasUser",target:"#authenticator.authenticated"},{actions:["applyAmplifyConfig","setHasSetup"],target:"goToInitialState"}]}},goToInitialState:{always:[{cond:"isInitialStateSignUp",target:"#authenticator.signUpActor"},{cond:"isInitialStateResetPassword",target:"#authenticator.forgotPasswordActor"},{target:"#authenticator.signInActor"}]}}},getCurrentUser:{invoke:{src:"handleGetCurrentUser",onDone:{actions:"setUser",target:"#authenticator.authenticated"},onError:{target:"#authenticator.setup"}}},signInActor:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnSignInActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("signInActor")}},on:{FORGOT_PASSWORD:"forgotPasswordActor",SIGN_IN:"signInActor",SIGN_UP:"signUpActor","done.invoke.signInActor":[{cond:"hasCompletedAttributeConfirmation",target:"#authenticator.getCurrentUser"},{cond:"isShouldConfirmUserAttributeStep",actions:"setActorDoneData",target:"#authenticator.verifyUserAttributesActor"},{cond:"isResetPasswordStep",actions:"setActorDoneData",target:"#authenticator.forgotPasswordActor"},{cond:"isConfirmSignUpStep",actions:"setActorDoneData",target:"#authenticator.signUpActor"}]}},signUpActor:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnSignUpActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("signUpActor")}},on:{SIGN_IN:"signInActor","done.invoke.signUpActor":[{cond:"hasCompletedAttributeConfirmation",target:"#authenticator.getCurrentUser"},{cond:"isShouldConfirmUserAttributeStep",actions:"setActorDoneData",target:"#authenticator.verifyUserAttributesActor"},{cond:"isConfirmUserAttributeStep",target:"#authenticator.verifyUserAttributesActor"},{actions:"setActorDoneData",target:"#authenticator.signInActor"}]}},forgotPasswordActor:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnForgotPasswordActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("forgotPasswordActor")}},on:{SIGN_IN:"signInActor","done.invoke.forgotPasswordActor":[{target:"#authenticator.signInActor"}]}},verifyUserAttributesActor:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnVerifyUserAttributesActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("verifyUserAttributesActor")}},on:{"done.invoke.verifyUserAttributesActor":[{actions:"setActorDoneData",target:"#authenticator.getCurrentUser"}]}},authenticated:{initial:"idle",states:{idle:{on:{TOKEN_REFRESH:"refreshUser"}},refreshUser:{invoke:{src:"#authenticator.getCurrentUser",onDone:{actions:"setUser",target:"idle"},onError:{target:"#authenticator.signOut"}}}},on:{SIGN_OUT:"signOut"}},signOut:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnSignOutActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("signOutActor")}},on:{"done.invoke.signOutActor":{actions:"clearUser",target:"setup.getConfig"}}}},on:{SIGN_IN_WITH_REDIRECT:{target:"#authenticator.getCurrentUser"},CHANGE:{actions:"forwardToActor"},BLUR:{actions:"forwardToActor"},SUBMIT:{actions:"forwardToActor"},FEDERATED_SIGN_IN:{actions:"forwardToActor"},RESEND:{actions:"forwardToActor"},SIGN_IN:{actions:"forwardToActor"},SKIP:{actions:"forwardToActor"}}},{actions:{...Et,forwardToActor:US([{cond:"hasActor",actions:ll(({actorRef:i})=>i)}]),setActorDoneData:_e({actorDoneData:(i,a)=>({challengeName:a.data.challengeName,codeDeliveryDetails:a.data.codeDeliveryDetails,missingAttributes:a.data.missingAttributes,remoteError:a.data.remoteError,username:a.data.username,step:a.data.step,totpSecretCode:a.data.totpSecretCode,unverifiedUserAttributes:a.data.unverifiedUserAttributes})}),applyAmplifyConfig:_e({config(i,{data:a}){const{loginMechanisms:s=a.loginMechanisms??[],signUpAttributes:c=a.signUpAttributes??[],socialProviders:l=a.socialProviders??[],initialState:u,formFields:d,passwordSettings:m=a.passwordFormat??{}}=i.config;return s.length===0&&s.push("username"),{formFields:FS(d)??{},initialState:u,loginMechanisms:s,passwordSettings:m,signUpAttributes:c,socialProviders:l}}}),spawnSignInActor:_e({actorRef:(i,a)=>{const{services:s}=i,c=ES({services:s}).withContext(Rt(i,"SIGN_IN"));return at(c,{name:"signInActor"})}}),spawnSignUpActor:_e({actorRef:(i,a)=>{const{services:s}=i,c=PS({services:s}).withContext(Rt(i,"SIGN_UP"));return at(c,{name:"signUpActor"})}}),spawnForgotPasswordActor:_e({actorRef:(i,a)=>{const{services:s}=i,c=bS({services:s}).withContext(Rt(i,"FORGOT_PASSWORD"));return at(c,{name:"forgotPasswordActor"})}}),spawnVerifyUserAttributesActor:_e({actorRef:i=>{const a=xS().withContext(Rt(i));return at(a,{name:"verifyUserAttributesActor"})}}),spawnSignOutActor:_e({actorRef:i=>{const a=kS().withContext({user:i==null?void 0:i.user});return at(a,{name:"signOutActor"})}}),configure:_e((i,a)=>{const{services:s,...c}=ja(n)?a.data??{}:n;return{services:{...ke,...s},config:c}}),setHasSetup:_e({hasSetup:!0})},guards:{..._n,hasActor:({actorRef:i})=>!!i,isInitialStateSignUp:({config:i})=>i.initialState==="signUp",isInitialStateResetPassword:({config:i})=>i.initialState==="forgotPassword",shouldSetup:({hasSetup:i})=>!i,hasUser:({user:i})=>!!i},services:{getAmplifyConfig:({services:i})=>i.getAmplifyConfig(),handleGetCurrentUser:({services:i})=>i.getCurrentUser()}})}function FS(e){return e&&Object.keys(e).forEach(t=>{Object.keys(e[t]).forEach(n=>{let o=e[t][n];o.required=o.isRequired})}),e}const Q={Accordion:"amplify-accordion",AccordionItem:"amplify-accordion__item",AccordionItemTrigger:"amplify-accordion__item__trigger",AccordionItemContent:"amplify-accordion__item__content",AccordionItemIcon:"amplify-accordion__item__icon",Alert:"amplify-alert",AlertIcon:"amplify-alert__icon",AlertHeading:"amplify-alert__heading",AlertBody:"amplify-alert__body",AlertDismiss:"amplify-alert__dismiss",Autocomplete:"amplify-autocomplete",AutocompleteMenu:"amplify-autocomplete__menu",AutocompleteMenuEmpty:"amplify-autocomplete__menu--empty",AutocompleteMenuFooter:"amplify-autocomplete__menu__footer",AutocompleteMenuHeader:"amplify-autocomplete__menu__header",AutocompleteMenuLoading:"amplify-autocomplete__menu--loading",AutocompleteMenuOption:"amplify-autocomplete__menu__option",AutocompleteMenuOptions:"amplify-autocomplete__menu__options",Badge:"amplify-badge",Breadcrumbs:"amplify-breadcrumbs",BreadcrumbsList:"amplify-breadcrumbs__list",BreadcrumbsItem:"amplify-breadcrumbs__item",BreadcrumbsSeparator:"amplify-breadcrumbs__separator",BreadcrumbsLink:"amplify-breadcrumbs__link",Button:"amplify-button",ButtonGroup:"amplify-buttongroup",ButtonLoaderWrapper:"amplify-button__loader-wrapper",Card:"amplify-card",Checkbox:"amplify-checkbox",CheckboxButton:"amplify-checkbox__button",CheckboxIcon:"amplify-checkbox__icon",CheckboxInput:"amplify-checkbox__input",CheckboxLabel:"amplify-checkbox__label",CheckboxField:"amplify-checkboxfield",Collection:"amplify-collection",CollectionItems:"amplify-collection-items",CollectionSearch:"amplify-collection-search",CollectionPagination:"amplify-collection-pagination",CountryCodeSelect:"amplify-countrycodeselect",DialCodeSelect:"amplify-dialcodeselect",Divider:"amplify-divider",DividerLabel:"amplify-divider--label",DropZone:"amplify-dropzone",Field:"amplify-field",FieldDescription:"amplify-field__description",FieldErrorMessage:"amplify-field__error-message",FieldGroup:"amplify-field-group",FieldGroupControl:"amplify-field-group__control",FieldGroupOuterEnd:"amplify-field-group__outer-end",FieldGroupOuterStart:"amplify-field-group__outer-start",FieldGroupInnerEnd:"amplify-field-group__inner-end",FieldGroupInnerStart:"amplify-field-group__inner-start",FieldGroupIcon:"amplify-field-group__icon",FieldGroupIconButton:"amplify-field-group__icon-button",FieldGroupHasInnerEnd:"amplify-field-group--has-inner-end",FieldGroupHasInnerStart:"amplify-field-group--has-inner-start",FieldShowPassword:"amplify-field__show-password",FieldGroupFieldWrapper:"amplify-field-group__field-wrapper",Fieldset:"amplify-fieldset",FieldsetLegend:"amplify-fieldset__legend",Flex:"amplify-flex",Grid:"amplify-grid",Heading:"amplify-heading",HighlightMatch:"amplify-highlightmatch",HighlightMatchHighlighted:"amplify-highlightmatch__highlighted",Icon:"amplify-icon",Image:"amplify-image",Input:"amplify-input",Label:"amplify-label",Link:"amplify-link",Loader:"amplify-loader",LoaderLabel:"amplify-loader__label",MenuContent:"amplify-menu__content",MenuItem:"amplify-menu__content__item",MenuTrigger:"amplify-menu__trigger",MenuWrapper:"amplify-menu__wrapper",Message:"amplify-message",MessageIcon:"amplify-message__icon",MessageHeading:"amplify-message__heading",MessageBody:"amplify-message__body",MessageContent:"amplify-message__content",MessageDismiss:"amplify-message__dismiss",Pagination:"amplify-pagination",PaginationItem:"amplify-pagination__item",PasswordField:"amplify-passwordfield",PhoneNumberField:"amplify-phonenumberfield",Placeholder:"amplify-placeholder",Radio:"amplify-radio",RadioButton:"amplify-radio__button",RadioInput:"amplify-radio__input",RadioLabel:"amplify-radio__label",RadioGroupField:"amplify-radiogroupfield",RadioGroup:"amplify-radiogroup",Rating:"amplify-rating",RatingItem:"amplify-rating__item",RatingIcon:"amplify-rating__icon",RatingLabel:"amplify-rating__label",ScrollView:"amplify-scrollview",SearchField:"amplify-searchfield",SearchFieldClear:"amplify-searchfield__clear",SearchFieldSearch:"amplify-searchfield__search",Select:"amplify-select",SelectField:"amplify-selectfield",SelectWrapper:"amplify-select__wrapper",SelectIcon:"amplify-select__icon",SliderField:"amplify-sliderfield",SliderFieldGroup:"amplify-sliderfield__group",SliderFieldLabel:"amplify-sliderfield__label",SliderFieldRange:"amplify-sliderfield__range",SliderFieldRoot:"amplify-sliderfield__root",SliderFieldThumb:"amplify-sliderfield__thumb",SliderFieldTrack:"amplify-sliderfield__track",StepperField:"amplify-stepperfield",StepperFieldButtonDecrease:"amplify-stepperfield__button--decrease",StepperFieldButtonIncrease:"amplify-stepperfield__button--increase",StepperFieldInput:"amplify-stepperfield__input",StorageImage:"amplify-storageimage",StorageManager:"amplify-storagemanager",StorageManagerDropZone:"amplify-storagemanager__dropzone",StorageManagerDropZoneIcon:"amplify-storagemanager__dropzone__icon",StorageManagerDropZoneText:"amplify-storagemanager__dropzone__text",StorageManagerFilePicker:"amplify-storagemanager__file__picker",StorageManagerFile:"amplify-storagemanager__file",StorageManagerFileWrapper:"amplify-storagemanager__file__wrapper",StorageManagerFileList:"amplify-storagemanager__file__list",StorageManagerFileName:"amplify-storagemanager__file__name",StorageManagerFileSize:"amplify-storagemanager__file__size",StorageManagerFileInfo:"amplify-storagemanager__file__info",StorageManagerFileImage:"amplify-storagemanager__file__image",StorageManagerFileMain:"amplify-storagemanager__file__main",StorageManagerFileStatus:"amplify-storagemanager__file__status",StorageManagerLoader:"amplify-storagemanager__loader",StorageManagerPreviewer:"amplify-storagemanager__previewer",StorageManagerPreviewerText:"amplify-storagemanager__previewer__text",StorageManagerPreviewerActions:"amplify-storagemanager__previewer__actions",StorageManagerPreviewerFooter:"amplify-storagemanager__previewer__footer",SwitchField:"amplify-switchfield",SwitchLabel:"amplify-switch__label",SwitchThumb:"amplify-switch__thumb",SwitchTrack:"amplify-switch__track",SwitchWrapper:"amplify-switch__wrapper",Table:"amplify-table",TableCaption:"amplify-table__caption",TableBody:"amplify-table__body",TableTd:"amplify-table__td",TableTh:"amplify-table__th",TableFoot:"amplify-table__foot",TableHead:"amplify-table__head",TableRow:"amplify-table__row",Tabs:"amplify-tabs",TabsList:"amplify-tabs__list",TabsItem:"amplify-tabs__item",TabsPanel:"amplify-tabs__panel",Text:"amplify-text",Textarea:"amplify-textarea",TextAreaField:"amplify-textareafield",TextField:"amplify-textfield",ToggleButton:"amplify-togglebutton",ToggleButtonGroup:"amplify-togglebuttongroup",VisuallyHidden:"amplify-visually-hidden"},MS=({componentName:e,packageName:t,version:n})=>{const o=[`ui-${t}`,n];switch(e){case"Authenticator":{L.setCustomUserAgent({...Fa,additionalDetails:[[e],o]});break}case"ChangePassword":case"DeleteUser":{L.setCustomUserAgent({...Da,additionalDetails:[["AccountSettings"],o]});break}case"InAppMessaging":{L.setCustomUserAgent({...Ma,additionalDetails:[[e],o]});break}case"LocationSearch":{L.setCustomUserAgent({...Ba,additionalDetails:[[e],o]});break}case"MapView":{L.setCustomUserAgent({...Va,additionalDetails:[[e],o]});break}case"StorageManager":{L.setCustomUserAgent({...La,additionalDetails:[[e],o]});break}}return Ha},BS={key:0,class:"amplify-flex amplify-alert amplify-alert--error amplify-authenticator__base","data-variation":"error",role:"alert"},VS={class:"amplify-flex amplify-authenticator__icon-wrapper"},LS=r.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",class:"amplify-icon","aria-hidden":"true",viewBox:"0 0 24 24",fill:"currentColor"},[r.createElementVNode("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"})],-1),GS=r.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",class:"amplify-icon","aria-hidden":"true",viewBox:"0 0 24 24",fill:"currentColor"},[r.createElementVNode("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"})],-1),he=r.defineComponent({__name:"base-alert",setup(e){const t=r.ref(!0),n=T("Dismiss alert");function o(){t.value=!1}return(i,a)=>{const s=ne;return t.value?(r.openBlock(),r.createElementBlock("div",BS,[r.createElementVNode("div",VS,[LS,r.createElementVNode("div",null,[r.renderSlot(i.$slots,"default")])]),r.createVNode(s,{class:"amplify-field-group__control amplify-alert__dismiss","aria-label":r.unref(n),fullwidth:!1,variation:"link",type:"button",onClick:o},{default:r.withCtx(()=>[GS]),_:1},8,["aria-label"])])):r.createCommentVNode("",!0)}}}),ye=r.defineComponent({__name:"base-field-set",setup(e){const t=r.useSlots();return(n,o)=>r.renderSlot(n.$slots,"fieldSetI",r.mergeProps(n.$attrs,{slotData:r.unref(t).default&&r.unref(t).default()}),()=>[r.createElementVNode("fieldset",r.mergeProps(n.$attrs,{"data-amplify-fieldset":""}),[r.renderSlot(n.$slots,"default")],16)])}});function zS(e){return r.getCurrentScope()?(r.onScopeDispose(e),!0):!1}function aa(e){let t=0,n,o;const i=()=>{t-=1,o&&t<=0&&(o.stop(),n=void 0,o=void 0)};return(...a)=>(t+=1,n||(o=r.effectScope(!0),n=o.run(()=>e(...a))),zS(i),n)}function jS(e){return"state"in e}var Ho=function(){};function WS(e){return"getSnapshot"in e?e.getSnapshot():jS(e)?e.state:void 0}function HS(e,t){t===void 0&&(t=WS);var n=r.isRef(e)?e:r.shallowRef(e),o=r.shallowRef(t(n.value)),i=function(a){n.value.send(a)};return r.watch(n,function(a,s,c){o.value=t(a);var l=a.subscribe({next:function(u){return o.value=u},error:Ho,complete:Ho}).unsubscribe;c(function(){return l()})},{immediate:!0}),{state:o,send:i}}const YS=e=>{var t,n,o;return{...(o=(n=(t=or(e))==null?void 0:t.formFields)==null?void 0:n.setupTotp)==null?void 0:o.QR}},kr=aa(()=>{const e=DS(),t=ki(e).start(),n=r.ref("configuring"),{state:o,send:i}=HS(t),a=()=>{n.value="authenticated"},s=()=>{n.value="unauthenticated"},c=Ya(t,(l,u)=>Qo(l,u,{onSignIn:a,onSignOut:s}));return H.getCurrentUser().then(()=>{n.value="authenticated"}).catch(()=>{n.value="unauthenticated"}),r.onScopeDispose(()=>{c()}),{authStatus:n,service:t,send:i,state:o}}),ee=aa(()=>{const{authStatus:e,state:t,send:n}=kr(),o=r.reactive({});return r.watchEffect(()=>{const i=Xa({send:n,state:t.value});for(const s of Object.keys(i))o[s]=i[s];const a=i.route==="setupTotp"?YS(t.value):null;o.QRFields=a,o.authStatus=e.value,o.send=n,o.state=t}),o});let KS=(e=21)=>{let t="",n=crypto.getRandomValues(new Uint8Array(e));for(;e--;){let o=n[e]&63;o<36?t+=o.toString(36):o<62?t+=(o-26).toString(36).toUpperCase():o<63?t+="_":t+="-"}return t};const Cn=r.defineComponent({__name:"base-input",emits:["update:modelValue"],setup(e,{emit:t}){const n=o=>{t("update:modelValue",o.target.value)};return(o,i)=>(r.openBlock(),r.createElementBlock("input",{onChange:i[0]||(i[0]=a=>n(a)),"data-amplify-input":""},null,32))}}),qS={},JS={"data-amplify-label":""};function ZS(e,t){return r.openBlock(),r.createElementBlock("label",JS,[r.renderSlot(e.$slots,"default")])}const bn=tn(qS,[["render",ZS]]),QS=["aria-label","aria-checked"],XS=r.createElementVNode("path",{d:"M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"},null,-1),eC=[XS],tC=r.createElementVNode("path",{d:"M0 0h24v24H0zm0 0h24v24H0zm0 0h24v24H0zm0 0h24v24H0z",fill:"none"},null,-1),nC=r.createElementVNode("path",{d:"M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2zm4.31-.78l3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"},null,-1),rC=[tC,nC],oC={inheritAttrs:!1},xr=r.defineComponent({...oC,__name:"password-control",props:{name:null,label:null,autocomplete:{default:"new-password"},hasError:{type:Boolean,default:!1},labelHidden:{type:Boolean},placeholder:null,required:{type:Boolean,default:!0},describedBy:null},setup(e){const t=e,n=T("Show password"),o=T("Hide password"),i=r.ref("password"),a=r.ref(n),s=Math.floor(Math.random()*999999),{name:c,label:l,autocomplete:u,hasError:d,labelHidden:m,placeholder:f,required:p}=r.toRefs(t),h=r.ref("");function v(){a.value=a.value===n?o:n,i.value=i.value==="password"?"text":"password"}const S=T((f==null?void 0:f.value)??l.value),g=T(l.value);return(w,y)=>{const _=bn,b=Cn,A=X;return r.openBlock(),r.createBlock(A,{class:r.normalizeClass([r.unref(Q).Flex,r.unref(Q).Field,r.unref(Q).TextField,r.unref(Q).PasswordField])},{default:r.withCtx(()=>[r.createVNode(_,{class:r.normalizeClass(["amplify-label",{"amplify-visually-hidden":r.unref(m)}]),for:"amplify-field-"+r.unref(s)},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(g)),1)]),_:1},8,["class","for"]),r.createVNode(A,{class:r.normalizeClass([r.unref(Q).Flex,r.unref(Q).FieldGroup])},{default:r.withCtx(()=>[r.createVNode(A,{class:r.normalizeClass(r.unref(Q).FieldGroupFieldWrapper)},{default:r.withCtx(()=>[r.createVNode(b,r.mergeProps(w.$attrs,{modelValue:h.value,"onUpdate:modelValue":y[0]||(y[0]=E=>h.value=E),class:[r.unref(Q).Input,r.unref(Q).FieldGroupControl],id:"amplify-field-"+r.unref(s),"data-amplify-password":"true",name:r.unref(c),autocomplete:r.unref(u),required:r.unref(p)??!0,placeholder:r.unref(S),type:i.value,"aria-invalid":r.unref(d),"aria-describedBy":e.describedBy,autocapitalize:"off"}),null,16,["modelValue","class","id","name","autocomplete","required","placeholder","type","aria-invalid","aria-describedBy"])]),_:1},8,["class"]),r.createVNode(A,{class:r.normalizeClass(r.unref(Q).FieldGroupOuterEnd)},{default:r.withCtx(()=>[r.createElementVNode("button",{"aria-label":a.value,"aria-checked":i.value!=="password",class:r.normalizeClass([r.unref(Q).Button,r.unref(Q).FieldGroupControl,r.unref(Q).FieldShowPassword]),"data-fullwidth":"false",type:"button",role:"switch",onClick:v},[i.value==="password"?(r.openBlock(),r.createElementBlock("svg",{key:0,xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24",class:r.normalizeClass(r.unref(Q).Icon)},eC,2)):(r.openBlock(),r.createElementBlock("svg",{key:1,xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24",class:r.normalizeClass(r.unref(Q).Icon)},rC,2))],10,QS)]),_:1},8,["class"])]),_:1},8,["class"])]),_:1},8,["class"])}}}),iC=["value","selected"],aC=r.defineComponent({__name:"base-select",props:{selectValue:{default:""},options:null},emits:["update:selectValue"],setup(e,{emit:t}){const n=e,{options:o,selectValue:i}=r.toRefs(n),a=s=>{t("update:selectValue",s.target.value)};return(s,c)=>(r.openBlock(),r.createElementBlock("select",{onChange:c[0]||(c[0]=l=>a(l))},[(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(r.unref(o),(l,u)=>(r.openBlock(),r.createElementBlock("option",{key:u,value:l,selected:l==r.unref(i)?!0:void 0},r.toDisplayString(l),9,iC))),128))],32))}}),sC=r.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24",class:"amplify-icon"},[r.createElementVNode("path",{d:"M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"})],-1),cC=r.defineComponent({__name:"alias-control",props:{label:{default:"Username"},name:{default:"username"},placeholder:{default:""},autocomplete:{default:""},labelHidden:{type:Boolean},required:{type:Boolean,default:!0},dialCode:null,dialCodeList:null,type:{default:"text"},hasError:{type:Boolean},describedBy:null},setup(e){const t=e,{label:n,name:o,placeholder:i,autocomplete:a,labelHidden:s,required:c,dialCode:l,dialCodeList:u}=r.toRefs(t),d=Math.floor(Math.random()*999999),m=Math.floor(Math.random()*999999);return(f,p)=>{const h=bn,v=aC,S=X,g=Cn;return r.openBlock(),r.createBlock(S,{class:"amplify-flex amplify-field amplify-textfield amplify-phonenumberfield"},{default:r.withCtx(()=>[r.createVNode(h,r.mergeProps({for:"amplify-field-"+r.unref(d),class:["amplify-label",{"amplify-visually-hidden":r.unref(s)}]},f.$attrs),{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(n)),1)]),_:1},16,["for","class"]),r.createVNode(S,{class:"amplify-flex amplify-field-group"},{default:r.withCtx(()=>[r.createVNode(S,{class:"amplify-field-group__outer-start"},{default:r.withCtx(()=>[e.type==="tel"?(r.openBlock(),r.createBlock(S,{key:0,class:"amplify-flex amplify-field amplify-selectfield amplify-countrycodeselect amplify-dialcodeselect amplify-authenticator__column"},{default:r.withCtx(()=>[r.createVNode(h,r.mergeProps({for:"amplify-field-"+r.unref(m),class:"amplify-label amplify-visually-hidden"},f.$attrs),{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString("Country Code"))]),_:1},16,["for"]),r.createVNode(S,{class:"amplify-select__wrapper"},{default:r.withCtx(()=>[r.createVNode(v,{class:"amplify-select amplify-field-group__control",id:"amplify-field-"+r.unref(m),autocomplete:"tel-country-code","aria-label":"country code",name:"country_code",options:r.unref(u),"select-value":r.unref(l)},null,8,["id","options","select-value"]),r.createVNode(S,{class:"amplify-flex amplify-select__icon"},{default:r.withCtx(()=>[sC]),_:1})]),_:1})]),_:1})):r.createCommentVNode("",!0)]),_:1}),r.createVNode(S,{class:"amplify-field-group__field-wrapper"},{default:r.withCtx(()=>[r.createVNode(g,{class:"amplify-input amplify-field-group__control",id:"amplify-field-"+r.unref(d),autocomplete:r.unref(a),name:r.unref(o),required:r.unref(c)??!0,type:e.type,placeholder:r.unref(i),"aria-invalid":e.hasError,"aria-describedBy":e.describedBy,autocapitalize:"off"},null,8,["id","autocomplete","name","required","type","placeholder","aria-invalid","aria-describedBy"])]),_:1})]),_:1})]),_:1})}}}),lC=["id"],sa=r.defineComponent({__name:"base-form-field",props:{name:{default:""},formField:{default:()=>({})}},setup(e){const t=e,{name:n,formField:o}=r.toRefs(t),{validationErrors:i}=r.toRefs(ee()),{type:a}=o.value,s=a==="password",c=KS(12),l=r.computed(()=>os(i.value[n.value])),u=r.computed(()=>{var m;return((m=l.value)==null?void 0:m.length)>0}),d=r.computed(()=>u.value?c:void 0);return(m,f)=>(r.openBlock(),r.createElementBlock(r.Fragment,null,[s?(r.openBlock(),r.createBlock(xr,{key:0,name:r.unref(n),label:r.unref(o).label,placeholder:r.unref(o).placeholder,required:r.unref(o).isRequired,"label-hidden":r.unref(o).labelHidden,autocomplete:r.unref(o).autocomplete,hasError:r.unref(u),describedBy:r.unref(d)},null,8,["name","label","placeholder","required","label-hidden","autocomplete","hasError","describedBy"])):(r.openBlock(),r.createBlock(cC,{key:1,name:r.unref(n),label:r.unref(o).label,placeholder:r.unref(o).placeholder,required:r.unref(o).isRequired,"label-hidden":r.unref(o).labelHidden,autocomplete:r.unref(o).autocomplete,"dial-code":r.unref(o).dialCode,"dial-code-list":r.unref(o).dialCodeList,type:r.unref(o).type,hasError:r.unref(u),describedBy:r.unref(d)},null,8,["name","label","placeholder","required","label-hidden","autocomplete","dial-code","dial-code-list","type","hasError","describedBy"])),r.unref(u)?(r.openBlock(),r.createElementBlock("div",{key:2,id:r.unref(d)},[(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(r.unref(l),(p,h)=>(r.openBlock(),r.createElementBlock("p",{key:h,role:"alert","data-variation":"error",class:"amplify-text amplify-text--error"},r.toDisplayString(r.unref(T)(p)),1))),128))],8,lC)):r.createCommentVNode("",!0)],64))}}),ve=r.defineComponent({__name:"base-form-fields",props:{route:null},setup(e){const t=e,{route:n}=r.toRefs(t),{state:o}=kr();let i=[];return r.onBeforeMount(()=>{i=uc(n.value,o.value)}),(a,s)=>(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(r.unref(i),([c,l])=>(r.openBlock(),r.createBlock(sa,{name:c,key:c,formField:l},null,8,["name","formField"]))),128))}}),Ot=r.defineComponent({__name:"federated-sign-in-button",props:{provider:null},setup(e){const t=e,{provider:n}=r.toRefs(t),{toFederatedSignIn:o}=ee(),i=()=>{o({provider:n.value})};return(a,s)=>{const c=ne;return r.openBlock(),r.createBlock(c,{class:"amplify-authenticator__federated-button",type:"button",onClick:i},{default:r.withCtx(()=>[r.renderSlot(a.$slots,"default")]),_:3})}}}),uC=r.createElementVNode("svg",{"aria-label":"Amazon icon",class:"amplify-icon",viewBox:"0 0 248 268"},[r.createElementVNode("path",{d:"M139.056521,147.024612 C133.548808,156.744524 124.782731,162.726926 115.087401,162.726926 C101.790721,162.726926 93.9937779,152.612964 93.9937779,137.68681 C93.9937779,108.224571 120.447551,102.879017 145.533369,102.879017 L145.533369,110.365976 C145.533369,123.831358 145.876354,135.063787 139.056521,147.024612 M207.206992,162.579655 C209.400505,165.692256 209.887066,169.437725 207.063416,171.770186 C199.996315,177.653081 187.429476,188.590967 180.513926,194.716661 L180.46208,194.621133 C178.176838,196.663031 174.862638,196.810303 172.27828,195.445057 C160.780281,185.9162 158.686473,181.494078 152.405048,172.403055 C133.405233,191.751331 119.909143,197.534719 95.309886,197.534719 C66.1281801,197.534719 43.4791563,179.599451 43.4791563,143.669212 C43.4791563,115.616003 58.6782107,96.5105248 80.4019706,87.1727225 C99.2063636,78.9096034 125.464714,77.4528107 145.533369,75.1641337 L145.533369,70.694248 C145.533369,62.4749122 146.167493,52.7510201 141.297893,45.6541312 C137.110277,39.2856386 129.018206,36.6586354 121.859376,36.6586354 C108.658413,36.6586354 96.9171331,43.4171982 94.0416364,57.4199213 C93.4593582,60.532522 91.1701278,63.5933787 88.003492,63.7406501 L54.4387473,60.1424518 C51.6150972,59.5095829 48.4484614,57.2248862 49.2740201,52.8982915 C56.9712583,12.2553679 93.7983558,0 126.732964,0 C143.587124,0 165.606011,4.47386604 178.902691,17.2148315 C195.760839,32.917146 194.149604,53.8694866 194.149604,76.6726704 L194.149604,130.542157 C194.149604,146.734049 200.87372,153.830938 207.206992,162.579655 Z M233.826346,208.038962 C230.467669,203.683255 211.550709,205.9821 203.056405,206.998432 C200.470662,207.321077 200.076227,205.042397 202.406981,203.404973 C217.475208,192.664928 242.201125,195.766353 245.081698,199.363845 C247.966255,202.981502 244.336653,228.071183 230.172839,240.049379 C228.001452,241.888455 225.929671,240.904388 226.89783,238.468418 C230.077218,230.430525 237.204944,212.418868 233.826346,208.038962 Z M126.768855,264 C74.0234043,264 42.0764048,241.955028 17.7852554,217.541992 C12.9733903,212.705982 6.71799208,206.295994 3.31151296,200.690918 C1.90227474,198.372135 5.59096074,195.021875 8.0442063,196.84375 C38.2390146,219.267578 82.1011654,239.538304 125.529506,239.538304 C154.819967,239.538304 191.046475,227.469543 220.66851,214.867659 C225.146771,212.966167 225.146771,219.180222 224.511585,221.060516 C224.183264,222.03242 209.514625,236.221149 189.247207,247.047411 C170.304273,257.166172 146.397132,264 126.768855,264 Z",fill:"#FF9900"})],-1),dC={class:"amplify-text"},fC=r.createElementVNode("svg",{"aria-label":"Apple icon",class:"amplify-icon",fill:"#000",preserveAspectRatio:"xMidYMid",stroke:"#000",strokeWidth:"0",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg"},[r.createElementVNode("path",{d:"M747.4 535.7c-.4-68.2 30.5-119.6 92.9-157.5-34.9-50-87.7-77.5-157.3-82.8-65.9-5.2-138 38.4-164.4 38.4-27.9 0-91.7-36.6-141.9-36.6C273.1 298.8 163 379.8 163 544.6c0 48.7 8.9 99 26.7 150.8 23.8 68.2 109.6 235.3 199.1 232.6 46.8-1.1 79.9-33.2 140.8-33.2 59.1 0 89.7 33.2 141.9 33.2 90.3-1.3 167.9-153.2 190.5-221.6-121.1-57.1-114.6-167.2-114.6-170.7zm-105.1-305c50.7-60.2 46.1-115 44.6-134.7-44.8 2.6-96.6 30.5-126.1 64.8-32.5 36.8-51.6 82.3-47.5 133.6 48.4 3.7 92.6-21.2 129-63.7z"})],-1),pC={class:"amplify-text"},mC=r.createElementVNode("svg",{"aria-label":"Facebook icon",class:"amplify-icon",viewBox:"0 0 279 538"},[r.createElementVNode("path",{d:"M82.3409742,538 L82.3409742,292.936652 L0,292.936652 L0,196.990154 L82.2410458,196.990154 L82.2410458,126.4295 C82.2410458,44.575144 132.205229,0 205.252865,0 C240.227794,0 270.306232,2.59855099 279,3.79788222 L279,89.2502322 L228.536175,89.2502322 C188.964542,89.2502322 181.270057,108.139699 181.270057,135.824262 L181.270057,196.89021 L276.202006,196.89021 L263.810888,292.836708 L181.16913,292.836708 L181.16913,538 L82.3409742,538 Z",fill:"#1877F2"})],-1),gC={class:"amplify-text"},hC=r.createElementVNode("svg",{"aria-label":"Google icon",class:"amplify-icon",viewBox:"0 0 256 262",xmlns:"http://www.w3.org/2000/svg",preserveAspectRatio:"xMidYMid"},[r.createElementVNode("path",{d:"M255.878 133.451c0-10.734-.871-18.567-2.756-26.69H130.55v48.448h71.947c-1.45 12.04-9.283 30.172-26.69 42.356l-.244 1.622 38.755 30.023 2.685.268c24.659-22.774 38.875-56.282 38.875-96.027",fill:"#4285F4"}),r.createElementVNode("path",{d:"M130.55 261.1c35.248 0 64.839-11.605 86.453-31.622l-41.196-31.913c-11.024 7.688-25.82 13.055-45.257 13.055-34.523 0-63.824-22.773-74.269-54.25l-1.531.13-40.298 31.187-.527 1.465C35.393 231.798 79.49 261.1 130.55 261.1",fill:"#34A853"}),r.createElementVNode("path",{d:"M56.281 156.37c-2.756-8.123-4.351-16.827-4.351-25.82 0-8.994 1.595-17.697 4.206-25.82l-.073-1.73L15.26 71.312l-1.335.635C5.077 89.644 0 109.517 0 130.55s5.077 40.905 13.925 58.602l42.356-32.782",fill:"#FBBC05"}),r.createElementVNode("path",{d:"M130.55 50.479c24.514 0 41.05 10.589 50.479 19.438l36.844-35.974C195.245 12.91 165.798 0 130.55 0 79.49 0 35.393 29.301 13.925 71.947l42.211 32.783c10.59-31.477 39.891-54.251 74.414-54.251",fill:"#EB4335"})],-1),yC={class:"amplify-text"},vC=["data-label"],An=r.defineComponent({__name:"federated-sign-in",setup(e){const t=ee(),{route:n,socialProviders:o}=t,i=o==null?void 0:o.includes("amazon"),a=o==null?void 0:o.includes("apple"),s=o==null?void 0:o.includes("facebook"),c=o==null?void 0:o.includes("google"),l=s||c||i||a,{getSignInWithFederationText:u,getOrText:d}=ce,m=r.computed(()=>Bn),f=r.computed(()=>u(n,"amazon")),p=r.computed(()=>u(n,"apple")),h=r.computed(()=>u(n,"facebook")),v=r.computed(()=>u(n,"google")),S=r.computed(()=>d());return(g,w)=>{const y=X;return r.unref(l)?(r.openBlock(),r.createBlock(y,{key:0,class:"amplify-flex amplify-authenticator__federated-buttons"},{default:r.withCtx(()=>[r.unref(i)?(r.openBlock(),r.createBlock(Ot,{key:0,provider:r.unref(m).Amazon},{default:r.withCtx(()=>[uC,r.createElementVNode("span",dC,r.toDisplayString(r.unref(f)),1)]),_:1},8,["provider"])):r.createCommentVNode("",!0),r.unref(a)?(r.openBlock(),r.createBlock(Ot,{key:1,provider:r.unref(m).Apple},{default:r.withCtx(()=>[fC,r.createElementVNode("span",pC,r.toDisplayString(r.unref(p)),1)]),_:1},8,["provider"])):r.createCommentVNode("",!0),r.unref(s)?(r.openBlock(),r.createBlock(Ot,{key:2,provider:r.unref(m).Facebook},{default:r.withCtx(()=>[mC,r.createElementVNode("span",gC,r.toDisplayString(r.unref(h)),1)]),_:1},8,["provider"])):r.createCommentVNode("",!0),r.unref(c)?(r.openBlock(),r.createBlock(Ot,{key:3,provider:r.unref(m).Google},{default:r.withCtx(()=>[hC,r.createElementVNode("span",yC,r.toDisplayString(r.unref(v)),1)]),_:1},8,["provider"])):r.createCommentVNode("",!0),r.createElementVNode("hr",{class:"amplify-divider amplify-divider--horizontal amplify-divider--small","aria-orientation":"horizontal","data-label":r.unref(S)},null,8,vC)]),_:1})):r.createCommentVNode("",!0)}}}),wC=r.createElementVNode("legend",{class:"amplify-visually-hidden"},"Sign in",-1),_C={"data-amplify-footer":""},Ur=r.defineComponent({__name:"sign-in",setup(e){const t=ee(),{submitForm:n,updateForm:o,toForgotPassword:i}=t,{error:a,isPending:s}=r.toRefs(t),{getForgotPasswordText:c,getSignInText:l,getSigningInText:u}=ce,d=r.computed(()=>c()),m=r.computed(()=>l()),f=r.computed(()=>u()),p=S=>{const{name:g,value:w}=S.target;o({name:g,value:w})},h=S=>{n(me(S))},v=()=>{i()};return(S,g)=>{const w=ye,y=he,_=ne,b=X,A=pe,E=fe;return r.renderSlot(S.$slots,"signInSlotI",r.normalizeProps(r.guardReactiveProps(S.$attrs)),()=>[r.renderSlot(S.$slots,"header"),r.createVNode(b,r.normalizeProps(r.guardReactiveProps(S.$attrs)),{default:r.withCtx(()=>[r.createVNode(A,{"data-amplify-authenticator-signin":"",onInput:p,onSubmit:r.withModifiers(h,["prevent"]),method:"post"},{formt:r.withCtx(({slotData:I})=>[r.renderSlot(S.$slots,"form",{info:I,onSignInSubmit:h,onInput:p,onForgotPasswordClicked:v})]),default:r.withCtx(()=>[r.createVNode(An),r.createVNode(b,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.createVNode(w,{disabled:r.unref(s),class:"amplify-flex amplify-authenticator__column"},{fieldSetI:r.withCtx(({slotData:I})=>[r.renderSlot(S.$slots,"signin-fields",{info:I})]),default:r.withCtx(()=>[wC,r.createVNode(ve,{route:"signIn"})]),_:3},8,["disabled"]),r.unref(a)?(r.openBlock(),r.createBlock(y,{key:0},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(T)(r.unref(a))),1)]),_:1})):r.createCommentVNode("",!0),r.createVNode(_,{disabled:r.unref(s),class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!0,loading:!1,variation:"primary"},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(s)?r.unref(f):r.unref(m)),1)]),_:1},8,["disabled"])]),_:3})]),_:3},8,["onSubmit"])]),_:3},16),r.createVNode(E,null,{default:r.withCtx(()=>[r.renderSlot(S.$slots,"footer",{},()=>[r.createElementVNode("div",_C,[r.createVNode(_,{onClick:v,class:"amplify-field-group__control amplify-authenticator__font",variation:"link",fullwidth:!0,size:"small",style:{"font-weight":"normal"},type:"button"},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(d)),1)]),_:1})])])]),_:3})])}}}),$r=r.defineComponent({__name:"authenticator-sign-up-form-fields",setup(e){return(t,n)=>(r.openBlock(),r.createBlock(ve,{route:"signUp"}))}}),Rr=r.defineComponent({__name:"sign-up",setup(e){const t=ee(),{submitForm:n,updateBlur:o,updateForm:i}=t,{error:a,hasValidationErrors:s,isPending:c}=r.toRefs(t),{getCreateAccountText:l}=ce,u=r.computed(()=>l()),d=p=>{const{checked:h,name:v,type:S,value:g}=p.target;i({name:v,value:S==="checkbox"&&!h?void 0:g})};function m(p){const{name:h}=p.target;o({name:h})}const f=p=>{n(me(p))};return(p,h)=>{const v=ye,S=he,g=ne,w=X,y=pe,_=fe;return r.renderSlot(p.$slots,"signUpSlotI",r.normalizeProps(r.guardReactiveProps(p.$attrs)),()=>[r.renderSlot(p.$slots,"header"),r.createVNode(w,r.normalizeProps(r.guardReactiveProps(p.$attrs)),{default:r.withCtx(()=>[r.createVNode(y,{onInput:d,onBlurCapture:m,onSubmit:r.withModifiers(f,["prevent"])},{default:r.withCtx(()=>[r.createVNode(An),r.createVNode(w,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.createVNode(v,{class:"amplify-flex amplify-authenticator__column",disabled:r.unref(c)},{fieldSetI:r.withCtx(({slotData:b})=>[r.renderSlot(p.$slots,"signup-fields",{info:b})]),default:r.withCtx(()=>[r.createVNode($r)]),_:3},8,["disabled"]),r.unref(a)?(r.openBlock(),r.createBlock(S,{key:0},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(T)(r.unref(a))),1)]),_:1})):r.createCommentVNode("",!0),r.createVNode(g,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!0,loading:!1,variation:"primary",style:{"border-radius":"0px","font-weight":"normal"},disabled:r.unref(c)||r.unref(s)},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(u)),1)]),_:1},8,["disabled"])]),_:3})]),_:3},8,["onSubmit"])]),_:3},16),r.createVNode(_,null,{default:r.withCtx(()=>[r.renderSlot(p.$slots,"footer")]),_:3})])}}}),SC={};function CC(e,t){const n=X;return r.openBlock(),r.createBlock(n,{tabindex:"0","aria-orientation":"horizontal","data-orientation":"horizontal",class:"amplify-authenticator__tabs amplify-tabs"},{default:r.withCtx(()=>[r.createVNode(n,{class:"amplify-tabs__list amplify-tabs__list--top amplify-tabs__list--equal amplify-authenticator__tabs-wrapper",role:"tablist"},{default:r.withCtx(()=>[r.renderSlot(e.$slots,"default")]),_:3})]),_:3})}const bC=tn(SC,[["render",CC]]),AC=["tabindex","aria-selected","id","aria-controls"],EC=r.defineComponent({__name:"base-two-tab-item",props:{label:null,id:null,active:{type:Boolean,default:!1}},setup(e){const t=e,{active:n,id:o,label:i}=r.toRefs(t);return(a,s)=>(r.openBlock(),r.createElementBlock("button",{tabindex:r.unref(n)?0:-1,"aria-selected":r.unref(n)?"true":"false",class:r.normalizeClass([{"amplify-tabs__item--active":r.unref(n)},"amplify-tabs__item"]),id:`${r.unref(o)}-tab`,"aria-controls":`${r.unref(o)}-panel`,role:"tab"},r.toDisplayString(r.unref(i)),11,AC))}}),IC="4.2.5",TC={};function NC(e,t){return r.renderSlot(e.$slots,"textI",r.normalizeProps(r.guardReactiveProps(e.$attrs)),()=>[r.createElementVNode("span",r.mergeProps(e.$attrs,{"data-amplify-text":""}),[r.renderSlot(e.$slots,"default")],16)])}const ca=tn(TC,[["render",NC]]),xe=r.defineComponent({props:{level:{type:Number,default:1}},inheritAttrs:!1,setup(e,{slots:t,attrs:n}){var s,c;const o=t.default?t.default():[],i=t.headingI?t.headingI():[],a=`${n.class||""} amplify-heading--${e.level}`;if(((c=(s=i[0])==null?void 0:s.children)==null?void 0:c.length)===0)i[0].children=[r.h(`h${e.level}`,{...n,class:a},[o])];else return()=>r.h(`h${e.level}`,{"data-amplify-heading":"",...n,class:a},[i[0]?r.h(i[0].children[0]):r.h(o[0])]);return()=>i}}),Or=r.defineComponent({__name:"confirm-sign-up",setup(e){const t=ee(),{codeDeliveryDetails:n,error:o,isPending:i}=r.toRefs(t),{resendCode:a,submitForm:s,updateForm:c}=t,{getDeliveryMethodText:l,getDeliveryMessageText:u,getResendCodeText:d,getConfirmText:m}=ce,f=r.computed(()=>l(n.value)),p=r.computed(()=>d()),h=r.computed(()=>m()),v=r.computed(()=>u(n.value)),S=_=>{const{name:b,value:A}=_.target;c({name:b,value:A})},g=_=>{w(_)},w=_=>{s(me(_))},y=()=>{a()};return(_,b)=>{const A=xe,E=ca,I=ye,N=he,P=ne,k=fe,x=X,$=pe;return r.renderSlot(_.$slots,"confirmSignUpSlotI",r.normalizeProps(r.guardReactiveProps(_.$attrs)),()=>[r.createVNode(x,r.normalizeProps(r.guardReactiveProps(_.$attrs)),{default:r.withCtx(()=>[r.createVNode($,{onInput:S,onSubmit:r.withModifiers(g,["prevent"])},{default:r.withCtx(()=>[r.createVNode(x,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.renderSlot(_.$slots,"header",{},()=>[r.createVNode(A,{class:"amplify-heading amplify-authenticator__heading",level:3},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(f)),1)]),_:1})]),r.createVNode(E,{class:"amplify-authenticator__subtitle"},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(v)),1)]),_:1}),r.createVNode(I,{class:"amplify-flex amplify-authenticator__column",disabled:r.unref(i)},{default:r.withCtx(()=>[r.createVNode(ve,{route:"confirmSignUp"})]),_:1},8,["disabled"]),r.createVNode(k,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.unref(o)?(r.openBlock(),r.createBlock(N,{key:0},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(T)(r.unref(o))),1)]),_:1})):r.createCommentVNode("",!0),r.createVNode(P,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!1,loading:!1,variation:"primary",type:"submit",disabled:r.unref(i)},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(h)),1)]),_:1},8,["disabled"]),r.createVNode(P,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!1,variation:"default",style:{"font-weight":"normal"},type:"button",onClick:r.withModifiers(y,["prevent"])},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(p)),1)]),_:1},8,["onClick"]),r.renderSlot(_.$slots,"footer")]),_:3})]),_:3})]),_:3},8,["onSubmit"])]),_:3},16)])}}}),Dr=r.defineComponent({__name:"confirm-sign-in",setup(e){const t=ee(),{submitForm:n,toSignIn:o,updateForm:i}=t,{error:a,isPending:s,challengeName:c}=r.toRefs(t),l=r.computed(()=>c.value),{getBackToSignInText:u,getConfirmText:d,getChallengeText:m}=ce,f=r.computed(()=>m(l.value)),p=r.computed(()=>u()),h=r.computed(()=>d()),v=w=>{const{name:y,value:_}=w.target;i({name:y,value:_})},S=w=>{n(me(w))},g=()=>{o()};return(w,y)=>{const _=xe,b=X,A=he,E=ne,I=fe,N=ye,P=pe;return r.renderSlot(w.$slots,"confirmSignInSlotI",r.normalizeProps(r.guardReactiveProps(w.$attrs)),()=>[r.createVNode(b,r.normalizeProps(r.guardReactiveProps(w.$attrs)),{default:r.withCtx(()=>[r.createVNode(P,{"data-amplify-authenticator-confirmsignin":"",onInput:v,onSubmit:r.withModifiers(S,["prevent"])},{default:r.withCtx(()=>[r.createVNode(N,{class:"amplify-flex amplify-authenticator__column",disabled:r.unref(s)},{default:r.withCtx(()=>[r.renderSlot(w.$slots,"header",{},()=>[r.createVNode(_,{level:3,class:"amplify-heading"},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(f)),1)]),_:1})]),r.createVNode(b,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.createVNode(ve,{route:"confirmSignIn"})]),_:1}),r.createVNode(I,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.unref(a)?(r.openBlock(),r.createBlock(A,{key:0},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(T)(r.unref(a))),1)]),_:1})):r.createCommentVNode("",!0),r.createVNode(E,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!1,loading:!1,variation:"primary",style:{"font-weight":"normal"},disabled:r.unref(s)},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(h)),1)]),_:1},8,["disabled"]),r.createVNode(E,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!1,size:"small",variation:"link",style:{"font-weight":"normal"},type:"button",onClick:r.withModifiers(g,["prevent"])},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(p)),1)]),_:1},8,["onClick"]),r.renderSlot(w.$slots,"footer")]),_:3})]),_:3},8,["disabled"])]),_:3},8,["onSubmit"])]),_:3},16)])}}});var It={},PC=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then},la={},ie={};let Fr;const kC=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];ie.getSymbolSize=function(t){if(!t)throw new Error('"version" cannot be null or undefined');if(t<1||t>40)throw new Error('"version" should be in range from 1 to 40');return t*4+17};ie.getSymbolTotalCodewords=function(t){return kC[t]};ie.getBCHDigit=function(e){let t=0;for(;e!==0;)t++,e>>>=1;return t};ie.setToSJISFunction=function(t){if(typeof t!="function")throw new Error('"toSJISFunc" is not a valid function.');Fr=t};ie.isKanjiModeEnabled=function(){return typeof Fr<"u"};ie.toSJIS=function(t){return Fr(t)};var En={};(function(e){e.L={bit:1},e.M={bit:0},e.Q={bit:3},e.H={bit:2};function t(n){if(typeof n!="string")throw new Error("Param is not a string");switch(n.toLowerCase()){case"l":case"low":return e.L;case"m":case"medium":return e.M;case"q":case"quartile":return e.Q;case"h":case"high":return e.H;default:throw new Error("Unknown EC Level: "+n)}}e.isValid=function(o){return o&&typeof o.bit<"u"&&o.bit>=0&&o.bit<4},e.from=function(o,i){if(e.isValid(o))return o;try{return t(o)}catch{return i}}})(En);function ua(){this.buffer=[],this.length=0}ua.prototype={get:function(e){const t=Math.floor(e/8);return(this.buffer[t]>>>7-e%8&1)===1},put:function(e,t){for(let n=0;n<t;n++)this.putBit((e>>>t-n-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(e){const t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}};var xC=ua;function Tt(e){if(!e||e<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=e,this.data=new Uint8Array(e*e),this.reservedBit=new Uint8Array(e*e)}Tt.prototype.set=function(e,t,n,o){const i=e*this.size+t;this.data[i]=n,o&&(this.reservedBit[i]=!0)};Tt.prototype.get=function(e,t){return this.data[e*this.size+t]};Tt.prototype.xor=function(e,t,n){this.data[e*this.size+t]^=n};Tt.prototype.isReserved=function(e,t){return this.reservedBit[e*this.size+t]};var UC=Tt,da={};(function(e){const t=ie.getSymbolSize;e.getRowColCoords=function(o){if(o===1)return[];const i=Math.floor(o/7)+2,a=t(o),s=a===145?26:Math.ceil((a-13)/(2*i-2))*2,c=[a-7];for(let l=1;l<i-1;l++)c[l]=c[l-1]-s;return c.push(6),c.reverse()},e.getPositions=function(o){const i=[],a=e.getRowColCoords(o),s=a.length;for(let c=0;c<s;c++)for(let l=0;l<s;l++)c===0&&l===0||c===0&&l===s-1||c===s-1&&l===0||i.push([a[c],a[l]]);return i}})(da);var fa={};const $C=ie.getSymbolSize,Yo=7;fa.getPositions=function(t){const n=$C(t);return[[0,0],[n-Yo,0],[0,n-Yo]]};var pa={};(function(e){e.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};const t={N1:3,N2:3,N3:40,N4:10};e.isValid=function(i){return i!=null&&i!==""&&!isNaN(i)&&i>=0&&i<=7},e.from=function(i){return e.isValid(i)?parseInt(i,10):void 0},e.getPenaltyN1=function(i){const a=i.size;let s=0,c=0,l=0,u=null,d=null;for(let m=0;m<a;m++){c=l=0,u=d=null;for(let f=0;f<a;f++){let p=i.get(m,f);p===u?c++:(c>=5&&(s+=t.N1+(c-5)),u=p,c=1),p=i.get(f,m),p===d?l++:(l>=5&&(s+=t.N1+(l-5)),d=p,l=1)}c>=5&&(s+=t.N1+(c-5)),l>=5&&(s+=t.N1+(l-5))}return s},e.getPenaltyN2=function(i){const a=i.size;let s=0;for(let c=0;c<a-1;c++)for(let l=0;l<a-1;l++){const u=i.get(c,l)+i.get(c,l+1)+i.get(c+1,l)+i.get(c+1,l+1);(u===4||u===0)&&s++}return s*t.N2},e.getPenaltyN3=function(i){const a=i.size;let s=0,c=0,l=0;for(let u=0;u<a;u++){c=l=0;for(let d=0;d<a;d++)c=c<<1&2047|i.get(u,d),d>=10&&(c===1488||c===93)&&s++,l=l<<1&2047|i.get(d,u),d>=10&&(l===1488||l===93)&&s++}return s*t.N3},e.getPenaltyN4=function(i){let a=0;const s=i.data.length;for(let l=0;l<s;l++)a+=i.data[l];return Math.abs(Math.ceil(a*100/s/5)-10)*t.N4};function n(o,i,a){switch(o){case e.Patterns.PATTERN000:return(i+a)%2===0;case e.Patterns.PATTERN001:return i%2===0;case e.Patterns.PATTERN010:return a%3===0;case e.Patterns.PATTERN011:return(i+a)%3===0;case e.Patterns.PATTERN100:return(Math.floor(i/2)+Math.floor(a/3))%2===0;case e.Patterns.PATTERN101:return i*a%2+i*a%3===0;case e.Patterns.PATTERN110:return(i*a%2+i*a%3)%2===0;case e.Patterns.PATTERN111:return(i*a%3+(i+a)%2)%2===0;default:throw new Error("bad maskPattern:"+o)}}e.applyMask=function(i,a){const s=a.size;for(let c=0;c<s;c++)for(let l=0;l<s;l++)a.isReserved(l,c)||a.xor(l,c,n(i,l,c))},e.getBestMask=function(i,a){const s=Object.keys(e.Patterns).length;let c=0,l=1/0;for(let u=0;u<s;u++){a(u),e.applyMask(u,i);const d=e.getPenaltyN1(i)+e.getPenaltyN2(i)+e.getPenaltyN3(i)+e.getPenaltyN4(i);e.applyMask(u,i),d<l&&(l=d,c=u)}return c}})(pa);var In={};const Te=En,Dt=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],Ft=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];In.getBlocksCount=function(t,n){switch(n){case Te.L:return Dt[(t-1)*4+0];case Te.M:return Dt[(t-1)*4+1];case Te.Q:return Dt[(t-1)*4+2];case Te.H:return Dt[(t-1)*4+3];default:return}};In.getTotalCodewordsCount=function(t,n){switch(n){case Te.L:return Ft[(t-1)*4+0];case Te.M:return Ft[(t-1)*4+1];case Te.Q:return Ft[(t-1)*4+2];case Te.H:return Ft[(t-1)*4+3];default:return}};var ma={},Tn={};const ht=new Uint8Array(512),Xt=new Uint8Array(256);(function(){let t=1;for(let n=0;n<255;n++)ht[n]=t,Xt[t]=n,t<<=1,t&256&&(t^=285);for(let n=255;n<512;n++)ht[n]=ht[n-255]})();Tn.log=function(t){if(t<1)throw new Error("log("+t+")");return Xt[t]};Tn.exp=function(t){return ht[t]};Tn.mul=function(t,n){return t===0||n===0?0:ht[Xt[t]+Xt[n]]};(function(e){const t=Tn;e.mul=function(o,i){const a=new Uint8Array(o.length+i.length-1);for(let s=0;s<o.length;s++)for(let c=0;c<i.length;c++)a[s+c]^=t.mul(o[s],i[c]);return a},e.mod=function(o,i){let a=new Uint8Array(o);for(;a.length-i.length>=0;){const s=a[0];for(let l=0;l<i.length;l++)a[l]^=t.mul(i[l],s);let c=0;for(;c<a.length&&a[c]===0;)c++;a=a.slice(c)}return a},e.generateECPolynomial=function(o){let i=new Uint8Array([1]);for(let a=0;a<o;a++)i=e.mul(i,new Uint8Array([1,t.exp(a)]));return i}})(ma);const ga=ma;function Mr(e){this.genPoly=void 0,this.degree=e,this.degree&&this.initialize(this.degree)}Mr.prototype.initialize=function(t){this.degree=t,this.genPoly=ga.generateECPolynomial(this.degree)};Mr.prototype.encode=function(t){if(!this.genPoly)throw new Error("Encoder not initialized");const n=new Uint8Array(t.length+this.degree);n.set(t);const o=ga.mod(n,this.genPoly),i=this.degree-o.length;if(i>0){const a=new Uint8Array(this.degree);return a.set(o,i),a}return o};var RC=Mr,ha={},Ue={},Br={};Br.isValid=function(t){return!isNaN(t)&&t>=1&&t<=40};var we={};const ya="[0-9]+",OC="[A-Z $%*+\\-./:]+";let St="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";St=St.replace(/u/g,"\\u");const DC="(?:(?![A-Z0-9 $%*+\\-./:]|"+St+`)(?:.|[\r
|
|
20
|
+
`).concat(c.message))}else return n.getStateNodeByPath(a)})},e.prototype.formatTransition=function(t){var n=this,o=xc(t.target),i="internal"in t?t.internal:o?o.some(function(l){return F(l)&&l[0]===n.delimiter}):!0,a=this.machine.options.guards,s=this.resolveTarget(o),c=C(C({},t),{actions:Se(ue(t.actions)),cond:li(t.cond,a),target:s,source:this,internal:i,eventType:t.event,toJSON:function(){return C(C({},c),{target:c.target?c.target.map(function(l){return"#".concat(l.id)}):void 0,source:"#".concat(n.id)})}});return c},e.prototype.formatTransitions=function(){var t,n,o=this,i;if(!this.config.on)i=[];else if(Array.isArray(this.config.on))i=this.config.on;else{var a=this.config.on,s=st,c=a[s],l=c===void 0?[]:c,u=ar(a,[typeof s=="symbol"?s:s+""]);i=j(Object.keys(u).map(function(w){!W&&w===Ge&&q(!1,"Empty string transition configs (e.g., `{ on: { '': ... }}`) for transient transitions are deprecated. Specify the transition in the `{ always: ... }` property instead. "+'Please check the `on` configuration for "#'.concat(o.id,'".'));var y=Me(w,u[w]);return W||sl(o,w,y),y}).concat(Me(st,l)))}var d=this.config.always?Me("",this.config.always):[],m=this.config.onDone?Me(String(dt(this.id)),this.config.onDone):[];W||q(!(this.config.onDone&&!this.parent),'Root nodes cannot have an ".onDone" transition. Please check the config of "'.concat(this.id,'".'));var f=j(this.invoke.map(function(w){var y=[];return w.onDone&&y.push.apply(y,G([],D(Me(String(gt(w.id)),w.onDone)),!1)),w.onError&&y.push.apply(y,G([],D(Me(String(ze(w.id)),w.onError)),!1)),y})),p=this.after,h=j(G(G(G(G([],D(m),!1),D(f),!1),D(i),!1),D(d),!1).map(function(w){return ue(w).map(function(y){return o.formatTransition(y)})}));try{for(var v=O(p),S=v.next();!S.done;S=v.next()){var g=S.value;h.push(g)}}catch(w){t={error:w}}finally{try{S&&!S.done&&(n=v.return)&&n.call(v)}finally{if(t)throw t.error}}return h},e}(),oo=!1;function Qe(e,t){return!W&&!("predictableActionArguments"in e)&&!oo&&(oo=!0,console.warn("It is highly recommended to set `predictableActionArguments` to `true` when using `createMachine`. https://xstate.js.org/docs/guides/actions.html")),new cl(e,t)}var _e=Si,un=gi,ll=bi,xt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function xi(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function ul(e,t){for(var n=-1,o=e==null?0:e.length,i=Array(o);++n<o;)i[n]=t(e[n],n,e);return i}var Ui=ul;function dl(){this.__data__=[],this.size=0}var fl=dl;function pl(e,t){return e===t||e!==e&&t!==t}var bt=pl,ml=bt;function gl(e,t){for(var n=e.length;n--;)if(ml(e[n][0],t))return n;return-1}var dn=gl,hl=dn,yl=Array.prototype,vl=yl.splice;function wl(e){var t=this.__data__,n=hl(t,e);if(n<0)return!1;var o=t.length-1;return n==o?t.pop():vl.call(t,n,1),--this.size,!0}var _l=wl,Sl=dn;function Cl(e){var t=this.__data__,n=Sl(t,e);return n<0?void 0:t[n][1]}var bl=Cl,Al=dn;function El(e){return Al(this.__data__,e)>-1}var Il=El,Tl=dn;function Nl(e,t){var n=this.__data__,o=Tl(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}var Pl=Nl,kl=fl,xl=_l,Ul=bl,$l=Il,Rl=Pl;function Xe(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}Xe.prototype.clear=kl;Xe.prototype.delete=xl;Xe.prototype.get=Ul;Xe.prototype.has=$l;Xe.prototype.set=Rl;var fn=Xe,Ol=fn;function Dl(){this.__data__=new Ol,this.size=0}var Fl=Dl;function Ml(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}var Bl=Ml;function Vl(e){return this.__data__.get(e)}var Ll=Vl;function Gl(e){return this.__data__.has(e)}var zl=Gl,jl=typeof xt=="object"&&xt&&xt.Object===Object&&xt,$i=jl,Wl=$i,Hl=typeof self=="object"&&self&&self.Object===Object&&self,Yl=Wl||Hl||Function("return this")(),ge=Yl,Kl=ge,ql=Kl.Symbol,pn=ql,io=pn,Ri=Object.prototype,Jl=Ri.hasOwnProperty,Zl=Ri.toString,ct=io?io.toStringTag:void 0;function Ql(e){var t=Jl.call(e,ct),n=e[ct];try{e[ct]=void 0;var o=!0}catch{}var i=Zl.call(e);return o&&(t?e[ct]=n:delete e[ct]),i}var Xl=Ql,eu=Object.prototype,tu=eu.toString;function nu(e){return tu.call(e)}var ru=nu,ao=pn,ou=Xl,iu=ru,au="[object Null]",su="[object Undefined]",so=ao?ao.toStringTag:void 0;function cu(e){return e==null?e===void 0?su:au:so&&so in Object(e)?ou(e):iu(e)}var et=cu;function lu(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var be=lu,uu=et,du=be,fu="[object AsyncFunction]",pu="[object Function]",mu="[object GeneratorFunction]",gu="[object Proxy]";function hu(e){if(!du(e))return!1;var t=uu(e);return t==pu||t==mu||t==fu||t==gu}var pr=hu,yu=ge,vu=yu["__core-js_shared__"],wu=vu,xn=wu,co=function(){var e=/[^.]+$/.exec(xn&&xn.keys&&xn.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function _u(e){return!!co&&co in e}var Su=_u,Cu=Function.prototype,bu=Cu.toString;function Au(e){if(e!=null){try{return bu.call(e)}catch{}try{return e+""}catch{}}return""}var Oi=Au,Eu=pr,Iu=Su,Tu=be,Nu=Oi,Pu=/[\\^$.*+?()[\]{}|]/g,ku=/^\[object .+?Constructor\]$/,xu=Function.prototype,Uu=Object.prototype,$u=xu.toString,Ru=Uu.hasOwnProperty,Ou=RegExp("^"+$u.call(Ru).replace(Pu,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Du(e){if(!Tu(e)||Iu(e))return!1;var t=Eu(e)?Ou:ku;return t.test(Nu(e))}var Fu=Du;function Mu(e,t){return e==null?void 0:e[t]}var Bu=Mu,Vu=Fu,Lu=Bu;function Gu(e,t){var n=Lu(e,t);return Vu(n)?n:void 0}var Oe=Gu,zu=Oe,ju=ge,Wu=zu(ju,"Map"),mr=Wu,Hu=Oe,Yu=Hu(Object,"create"),mn=Yu,lo=mn;function Ku(){this.__data__=lo?lo(null):{},this.size=0}var qu=Ku;function Ju(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Zu=Ju,Qu=mn,Xu="__lodash_hash_undefined__",ed=Object.prototype,td=ed.hasOwnProperty;function nd(e){var t=this.__data__;if(Qu){var n=t[e];return n===Xu?void 0:n}return td.call(t,e)?t[e]:void 0}var rd=nd,od=mn,id=Object.prototype,ad=id.hasOwnProperty;function sd(e){var t=this.__data__;return od?t[e]!==void 0:ad.call(t,e)}var cd=sd,ld=mn,ud="__lodash_hash_undefined__";function dd(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ld&&t===void 0?ud:t,this}var fd=dd,pd=qu,md=Zu,gd=rd,hd=cd,yd=fd;function tt(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}tt.prototype.clear=pd;tt.prototype.delete=md;tt.prototype.get=gd;tt.prototype.has=hd;tt.prototype.set=yd;var vd=tt,uo=vd,wd=fn,_d=mr;function Sd(){this.size=0,this.__data__={hash:new uo,map:new(_d||wd),string:new uo}}var Cd=Sd;function bd(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var Ad=bd,Ed=Ad;function Id(e,t){var n=e.__data__;return Ed(t)?n[typeof t=="string"?"string":"hash"]:n.map}var gn=Id,Td=gn;function Nd(e){var t=Td(this,e).delete(e);return this.size-=t?1:0,t}var Pd=Nd,kd=gn;function xd(e){return kd(this,e).get(e)}var Ud=xd,$d=gn;function Rd(e){return $d(this,e).has(e)}var Od=Rd,Dd=gn;function Fd(e,t){var n=Dd(this,e),o=n.size;return n.set(e,t),this.size+=n.size==o?0:1,this}var Md=Fd,Bd=Cd,Vd=Pd,Ld=Ud,Gd=Od,zd=Md;function nt(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}nt.prototype.clear=Bd;nt.prototype.delete=Vd;nt.prototype.get=Ld;nt.prototype.has=Gd;nt.prototype.set=zd;var gr=nt,jd=fn,Wd=mr,Hd=gr,Yd=200;function Kd(e,t){var n=this.__data__;if(n instanceof jd){var o=n.__data__;if(!Wd||o.length<Yd-1)return o.push([e,t]),this.size=++n.size,this;n=this.__data__=new Hd(o)}return n.set(e,t),this.size=n.size,this}var qd=Kd,Jd=fn,Zd=Fl,Qd=Bl,Xd=Ll,ef=zl,tf=qd;function rt(e){var t=this.__data__=new Jd(e);this.size=t.size}rt.prototype.clear=Zd;rt.prototype.delete=Qd;rt.prototype.get=Xd;rt.prototype.has=ef;rt.prototype.set=tf;var hr=rt,nf="__lodash_hash_undefined__";function rf(e){return this.__data__.set(e,nf),this}var of=rf;function af(e){return this.__data__.has(e)}var sf=af,cf=gr,lf=of,uf=sf;function qt(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new cf;++t<n;)this.add(e[t])}qt.prototype.add=qt.prototype.push=lf;qt.prototype.has=uf;var df=qt;function ff(e,t){for(var n=-1,o=e==null?0:e.length;++n<o;)if(t(e[n],n,e))return!0;return!1}var pf=ff;function mf(e,t){return e.has(t)}var gf=mf,hf=df,yf=pf,vf=gf,wf=1,_f=2;function Sf(e,t,n,o,i,a){var s=n&wf,c=e.length,l=t.length;if(c!=l&&!(s&&l>c))return!1;var u=a.get(e),d=a.get(t);if(u&&d)return u==t&&d==e;var m=-1,f=!0,p=n&_f?new hf:void 0;for(a.set(e,t),a.set(t,e);++m<c;){var h=e[m],v=t[m];if(o)var S=s?o(v,h,m,t,e,a):o(h,v,m,e,t,a);if(S!==void 0){if(S)continue;f=!1;break}if(p){if(!yf(t,function(g,w){if(!vf(p,w)&&(h===g||i(h,g,n,o,a)))return p.push(w)})){f=!1;break}}else if(!(h===v||i(h,v,n,o,a))){f=!1;break}}return a.delete(e),a.delete(t),f}var Di=Sf,Cf=ge,bf=Cf.Uint8Array,Fi=bf;function Af(e){var t=-1,n=Array(e.size);return e.forEach(function(o,i){n[++t]=[i,o]}),n}var Ef=Af;function If(e){var t=-1,n=Array(e.size);return e.forEach(function(o){n[++t]=o}),n}var Tf=If,fo=pn,po=Fi,Nf=bt,Pf=Di,kf=Ef,xf=Tf,Uf=1,$f=2,Rf="[object Boolean]",Of="[object Date]",Df="[object Error]",Ff="[object Map]",Mf="[object Number]",Bf="[object RegExp]",Vf="[object Set]",Lf="[object String]",Gf="[object Symbol]",zf="[object ArrayBuffer]",jf="[object DataView]",mo=fo?fo.prototype:void 0,Un=mo?mo.valueOf:void 0;function Wf(e,t,n,o,i,a,s){switch(n){case jf:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case zf:return!(e.byteLength!=t.byteLength||!a(new po(e),new po(t)));case Rf:case Of:case Mf:return Nf(+e,+t);case Df:return e.name==t.name&&e.message==t.message;case Bf:case Lf:return e==t+"";case Ff:var c=kf;case Vf:var l=o&Uf;if(c||(c=xf),e.size!=t.size&&!l)return!1;var u=s.get(e);if(u)return u==t;o|=$f,s.set(e,t);var d=Pf(c(e),c(t),o,i,a,s);return s.delete(e),d;case Gf:if(Un)return Un.call(e)==Un.call(t)}return!1}var Hf=Wf;function Yf(e,t){for(var n=-1,o=t.length,i=e.length;++n<o;)e[i+n]=t[n];return e}var Mi=Yf,Kf=Array.isArray,Ae=Kf,qf=Mi,Jf=Ae;function Zf(e,t,n){var o=t(e);return Jf(e)?o:qf(o,n(e))}var Bi=Zf;function Qf(e,t){for(var n=-1,o=e==null?0:e.length,i=0,a=[];++n<o;){var s=e[n];t(s,n,e)&&(a[i++]=s)}return a}var Xf=Qf;function ep(){return[]}var Vi=ep,tp=Xf,np=Vi,rp=Object.prototype,op=rp.propertyIsEnumerable,go=Object.getOwnPropertySymbols,ip=go?function(e){return e==null?[]:(e=Object(e),tp(go(e),function(t){return op.call(e,t)}))}:np,Li=ip;function ap(e,t){for(var n=-1,o=Array(e);++n<e;)o[n]=t(n);return o}var sp=ap;function cp(e){return e!=null&&typeof e=="object"}var De=cp,lp=et,up=De,dp="[object Arguments]";function fp(e){return up(e)&&lp(e)==dp}var pp=fp,ho=pp,mp=De,Gi=Object.prototype,gp=Gi.hasOwnProperty,hp=Gi.propertyIsEnumerable,yp=ho(function(){return arguments}())?ho:function(e){return mp(e)&&gp.call(e,"callee")&&!hp.call(e,"callee")},yr=yp,Jt={exports:{}};function vp(){return!1}var wp=vp;Jt.exports;(function(e,t){var n=ge,o=wp,i=t&&!t.nodeType&&t,a=i&&!0&&e&&!e.nodeType&&e,s=a&&a.exports===i,c=s?n.Buffer:void 0,l=c?c.isBuffer:void 0,u=l||o;e.exports=u})(Jt,Jt.exports);var vr=Jt.exports,_p=9007199254740991,Sp=/^(?:0|[1-9]\d*)$/;function Cp(e,t){var n=typeof e;return t=t??_p,!!t&&(n=="number"||n!="symbol"&&Sp.test(e))&&e>-1&&e%1==0&&e<t}var hn=Cp,bp=9007199254740991;function Ap(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=bp}var wr=Ap,Ep=et,Ip=wr,Tp=De,Np="[object Arguments]",Pp="[object Array]",kp="[object Boolean]",xp="[object Date]",Up="[object Error]",$p="[object Function]",Rp="[object Map]",Op="[object Number]",Dp="[object Object]",Fp="[object RegExp]",Mp="[object Set]",Bp="[object String]",Vp="[object WeakMap]",Lp="[object ArrayBuffer]",Gp="[object DataView]",zp="[object Float32Array]",jp="[object Float64Array]",Wp="[object Int8Array]",Hp="[object Int16Array]",Yp="[object Int32Array]",Kp="[object Uint8Array]",qp="[object Uint8ClampedArray]",Jp="[object Uint16Array]",Zp="[object Uint32Array]",z={};z[zp]=z[jp]=z[Wp]=z[Hp]=z[Yp]=z[Kp]=z[qp]=z[Jp]=z[Zp]=!0;z[Np]=z[Pp]=z[Lp]=z[kp]=z[Gp]=z[xp]=z[Up]=z[$p]=z[Rp]=z[Op]=z[Dp]=z[Fp]=z[Mp]=z[Bp]=z[Vp]=!1;function Qp(e){return Tp(e)&&Ip(e.length)&&!!z[Ep(e)]}var Xp=Qp;function em(e){return function(t){return e(t)}}var tm=em,Zt={exports:{}};Zt.exports;(function(e,t){var n=$i,o=t&&!t.nodeType&&t,i=o&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===o,s=a&&n.process,c=function(){try{var l=i&&i.require&&i.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}}();e.exports=c})(Zt,Zt.exports);var nm=Zt.exports,rm=Xp,om=tm,yo=nm,vo=yo&&yo.isTypedArray,im=vo?om(vo):rm,_r=im,am=sp,sm=yr,cm=Ae,lm=vr,um=hn,dm=_r,fm=Object.prototype,pm=fm.hasOwnProperty;function mm(e,t){var n=cm(e),o=!n&&sm(e),i=!n&&!o&&lm(e),a=!n&&!o&&!i&&dm(e),s=n||o||i||a,c=s?am(e.length,String):[],l=c.length;for(var u in e)(t||pm.call(e,u))&&!(s&&(u=="length"||i&&(u=="offset"||u=="parent")||a&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||um(u,l)))&&c.push(u);return c}var zi=mm,gm=Object.prototype;function hm(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||gm;return e===n}var Sr=hm;function ym(e,t){return function(n){return e(t(n))}}var ji=ym,vm=ji,wm=vm(Object.keys,Object),_m=wm,Sm=Sr,Cm=_m,bm=Object.prototype,Am=bm.hasOwnProperty;function Em(e){if(!Sm(e))return Cm(e);var t=[];for(var n in Object(e))Am.call(e,n)&&n!="constructor"&&t.push(n);return t}var Im=Em,Tm=pr,Nm=wr;function Pm(e){return e!=null&&Nm(e.length)&&!Tm(e)}var yn=Pm,km=zi,xm=Im,Um=yn;function $m(e){return Um(e)?km(e):xm(e)}var Wi=$m,Rm=Bi,Om=Li,Dm=Wi;function Fm(e){return Rm(e,Dm,Om)}var Mm=Fm,wo=Mm,Bm=1,Vm=Object.prototype,Lm=Vm.hasOwnProperty;function Gm(e,t,n,o,i,a){var s=n&Bm,c=wo(e),l=c.length,u=wo(t),d=u.length;if(l!=d&&!s)return!1;for(var m=l;m--;){var f=c[m];if(!(s?f in t:Lm.call(t,f)))return!1}var p=a.get(e),h=a.get(t);if(p&&h)return p==t&&h==e;var v=!0;a.set(e,t),a.set(t,e);for(var S=s;++m<l;){f=c[m];var g=e[f],w=t[f];if(o)var y=s?o(w,g,f,t,e,a):o(g,w,f,e,t,a);if(!(y===void 0?g===w||i(g,w,n,o,a):y)){v=!1;break}S||(S=f=="constructor")}if(v&&!S){var _=e.constructor,b=t.constructor;_!=b&&"constructor"in e&&"constructor"in t&&!(typeof _=="function"&&_ instanceof _&&typeof b=="function"&&b instanceof b)&&(v=!1)}return a.delete(e),a.delete(t),v}var zm=Gm,jm=Oe,Wm=ge,Hm=jm(Wm,"DataView"),Ym=Hm,Km=Oe,qm=ge,Jm=Km(qm,"Promise"),Zm=Jm,Qm=Oe,Xm=ge,eg=Qm(Xm,"Set"),tg=eg,ng=Oe,rg=ge,og=ng(rg,"WeakMap"),ig=og,Yn=Ym,Kn=mr,qn=Zm,Jn=tg,Zn=ig,Hi=et,ot=Oi,_o="[object Map]",ag="[object Object]",So="[object Promise]",Co="[object Set]",bo="[object WeakMap]",Ao="[object DataView]",sg=ot(Yn),cg=ot(Kn),lg=ot(qn),ug=ot(Jn),dg=ot(Zn),$e=Hi;(Yn&&$e(new Yn(new ArrayBuffer(1)))!=Ao||Kn&&$e(new Kn)!=_o||qn&&$e(qn.resolve())!=So||Jn&&$e(new Jn)!=Co||Zn&&$e(new Zn)!=bo)&&($e=function(e){var t=Hi(e),n=t==ag?e.constructor:void 0,o=n?ot(n):"";if(o)switch(o){case sg:return Ao;case cg:return _o;case lg:return So;case ug:return Co;case dg:return bo}return t});var fg=$e,$n=hr,pg=Di,mg=Hf,gg=zm,Eo=fg,Io=Ae,To=vr,hg=_r,yg=1,No="[object Arguments]",Po="[object Array]",Ut="[object Object]",vg=Object.prototype,ko=vg.hasOwnProperty;function wg(e,t,n,o,i,a){var s=Io(e),c=Io(t),l=s?Po:Eo(e),u=c?Po:Eo(t);l=l==No?Ut:l,u=u==No?Ut:u;var d=l==Ut,m=u==Ut,f=l==u;if(f&&To(e)){if(!To(t))return!1;s=!0,d=!1}if(f&&!d)return a||(a=new $n),s||hg(e)?pg(e,t,n,o,i,a):mg(e,t,l,n,o,i,a);if(!(n&yg)){var p=d&&ko.call(e,"__wrapped__"),h=m&&ko.call(t,"__wrapped__");if(p||h){var v=p?e.value():e,S=h?t.value():t;return a||(a=new $n),i(v,S,n,o,a)}}return f?(a||(a=new $n),gg(e,t,n,o,i,a)):!1}var _g=wg,Sg=_g,xo=De;function Yi(e,t,n,o,i){return e===t?!0:e==null||t==null||!xo(e)&&!xo(t)?e!==e&&t!==t:Sg(e,t,n,o,Yi,i)}var Ki=Yi,Cg=hr,bg=Ki,Ag=1,Eg=2;function Ig(e,t,n,o){var i=n.length,a=i,s=!o;if(e==null)return!a;for(e=Object(e);i--;){var c=n[i];if(s&&c[2]?c[1]!==e[c[0]]:!(c[0]in e))return!1}for(;++i<a;){c=n[i];var l=c[0],u=e[l],d=c[1];if(s&&c[2]){if(u===void 0&&!(l in e))return!1}else{var m=new Cg;if(o)var f=o(u,d,l,e,t,m);if(!(f===void 0?bg(d,u,Ag|Eg,o,m):f))return!1}}return!0}var Tg=Ig,Ng=be;function Pg(e){return e===e&&!Ng(e)}var qi=Pg,kg=qi,xg=Wi;function Ug(e){for(var t=xg(e),n=t.length;n--;){var o=t[n],i=e[o];t[n]=[o,i,kg(i)]}return t}var $g=Ug;function Rg(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}var Ji=Rg,Og=Tg,Dg=$g,Fg=Ji;function Mg(e){var t=Dg(e);return t.length==1&&t[0][2]?Fg(t[0][0],t[0][1]):function(n){return n===e||Og(n,e,t)}}var Bg=Mg,Vg=et,Lg=De,Gg="[object Symbol]";function zg(e){return typeof e=="symbol"||Lg(e)&&Vg(e)==Gg}var Cr=zg,jg=Ae,Wg=Cr,Hg=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Yg=/^\w*$/;function Kg(e,t){if(jg(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Wg(e)?!0:Yg.test(e)||!Hg.test(e)||t!=null&&e in Object(t)}var br=Kg,Zi=gr,qg="Expected a function";function Ar(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(qg);var n=function(){var o=arguments,i=t?t.apply(this,o):o[0],a=n.cache;if(a.has(i))return a.get(i);var s=e.apply(this,o);return n.cache=a.set(i,s)||a,s};return n.cache=new(Ar.Cache||Zi),n}Ar.Cache=Zi;var Jg=Ar,Zg=Jg,Qg=500;function Xg(e){var t=Zg(e,function(o){return n.size===Qg&&n.clear(),o}),n=t.cache;return t}var eh=Xg,th=eh,nh=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,rh=/\\(\\)?/g,oh=th(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(nh,function(n,o,i,a){t.push(i?a.replace(rh,"$1"):o||n)}),t}),ih=oh,Uo=pn,ah=Ui,sh=Ae,ch=Cr,lh=1/0,$o=Uo?Uo.prototype:void 0,Ro=$o?$o.toString:void 0;function Qi(e){if(typeof e=="string")return e;if(sh(e))return ah(e,Qi)+"";if(ch(e))return Ro?Ro.call(e):"";var t=e+"";return t=="0"&&1/e==-lh?"-0":t}var uh=Qi,dh=uh;function fh(e){return e==null?"":dh(e)}var ph=fh,mh=Ae,gh=br,hh=ih,yh=ph;function vh(e,t){return mh(e)?e:gh(e,t)?[e]:hh(yh(e))}var vn=vh,wh=Cr,_h=1/0;function Sh(e){if(typeof e=="string"||wh(e))return e;var t=e+"";return t=="0"&&1/e==-_h?"-0":t}var At=Sh,Ch=vn,bh=At;function Ah(e,t){t=Ch(t,e);for(var n=0,o=t.length;e!=null&&n<o;)e=e[bh(t[n++])];return n&&n==o?e:void 0}var Er=Ah,Eh=Er;function Ih(e,t,n){var o=e==null?void 0:Eh(e,t);return o===void 0?n:o}var Th=Ih;function Nh(e,t){return e!=null&&t in Object(e)}var Ph=Nh,kh=vn,xh=yr,Uh=Ae,$h=hn,Rh=wr,Oh=At;function Dh(e,t,n){t=kh(t,e);for(var o=-1,i=t.length,a=!1;++o<i;){var s=Oh(t[o]);if(!(a=e!=null&&n(e,s)))break;e=e[s]}return a||++o!=i?a:(i=e==null?0:e.length,!!i&&Rh(i)&&$h(s,i)&&(Uh(e)||xh(e)))}var Fh=Dh,Mh=Ph,Bh=Fh;function Vh(e,t){return e!=null&&Bh(e,t,Mh)}var Lh=Vh,Gh=Ki,zh=Th,jh=Lh,Wh=br,Hh=qi,Yh=Ji,Kh=At,qh=1,Jh=2;function Zh(e,t){return Wh(e)&&Hh(t)?Yh(Kh(e),t):function(n){var o=zh(n,e);return o===void 0&&o===t?jh(n,e):Gh(t,o,qh|Jh)}}var Qh=Zh;function Xh(e){return e}var Ir=Xh;function ey(e){return function(t){return t==null?void 0:t[e]}}var ty=ey,ny=Er;function ry(e){return function(t){return ny(t,e)}}var oy=ry,iy=ty,ay=oy,sy=br,cy=At;function ly(e){return sy(e)?iy(cy(e)):ay(e)}var uy=ly,dy=Bg,fy=Qh,py=Ir,my=Ae,gy=uy;function hy(e){return typeof e=="function"?e:e==null?py:typeof e=="object"?my(e)?fy(e[0],e[1]):dy(e):gy(e)}var yy=hy,vy=Oe,wy=function(){try{var e=vy(Object,"defineProperty");return e({},"",{}),e}catch{}}(),Xi=wy,Oo=Xi;function _y(e,t,n){t=="__proto__"&&Oo?Oo(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var Tr=_y,Sy=Tr,Cy=bt,by=Object.prototype,Ay=by.hasOwnProperty;function Ey(e,t,n){var o=e[t];(!(Ay.call(e,t)&&Cy(o,n))||n===void 0&&!(t in e))&&Sy(e,t,n)}var ea=Ey,Iy=ea,Ty=vn,Ny=hn,Do=be,Py=At;function ky(e,t,n,o){if(!Do(e))return e;t=Ty(t,e);for(var i=-1,a=t.length,s=a-1,c=e;c!=null&&++i<a;){var l=Py(t[i]),u=n;if(l==="__proto__"||l==="constructor"||l==="prototype")return e;if(i!=s){var d=c[l];u=o?o(d,l,c):void 0,u===void 0&&(u=Do(d)?d:Ny(t[i+1])?[]:{})}Iy(c,l,u),c=c[l]}return e}var xy=ky,Uy=Er,$y=xy,Ry=vn;function Oy(e,t,n){for(var o=-1,i=t.length,a={};++o<i;){var s=t[o],c=Uy(e,s);n(c,s)&&$y(a,Ry(s,e),c)}return a}var Dy=Oy,Fy=ji,My=Fy(Object.getPrototypeOf,Object),Nr=My,By=Mi,Vy=Nr,Ly=Li,Gy=Vi,zy=Object.getOwnPropertySymbols,jy=zy?function(e){for(var t=[];e;)By(t,Ly(e)),e=Vy(e);return t}:Gy,Wy=jy;function Hy(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var Yy=Hy,Ky=be,qy=Sr,Jy=Yy,Zy=Object.prototype,Qy=Zy.hasOwnProperty;function Xy(e){if(!Ky(e))return Jy(e);var t=qy(e),n=[];for(var o in e)o=="constructor"&&(t||!Qy.call(e,o))||n.push(o);return n}var ev=Xy,tv=zi,nv=ev,rv=yn;function ov(e){return rv(e)?tv(e,!0):nv(e)}var Pr=ov,iv=Bi,av=Wy,sv=Pr;function cv(e){return iv(e,sv,av)}var lv=cv,uv=Ui,dv=yy,fv=Dy,pv=lv;function mv(e,t){if(e==null)return{};var n=uv(pv(e),function(o){return[o]});return t=dv(t),fv(e,n,function(o,i){return t(o,i[0])})}var gv=mv;const hv=xi(gv),yv=!0,vv="",wn=(e,t)=>`${e}${t}`.replace(/[^A-Z0-9+]/gi,""),wv=(e,t)=>{switch(t){case"address":case"birthdate":case"email":case"family_name":case"gender":case"given_name":case"locale":case"middle_name":case"name":case"nickname":case"phone_number":case"picture":case"preferred_username":case"profile":case"updated_at":case"website":case"zoneinfo":return!0;default:return t.startsWith("custom:")}},_v=e=>{const{phone_number:t,...n}=hv(e,wv);if(Jo(t)&&t!==vv){const{country_code:o}=e;return{...n,phone_number:wn(o,t)}}return n},Sv=(e,t,n)=>{const{password:o,...i}=t,a=_v(i),s={autoSignIn:yv,userAttributes:{...n==="phone_number"?{...a,phone_number:e}:a}};return{username:e,password:o,options:s}},Cv=({formValues:e,loginMechanisms:t})=>{const n=t[0];if(n==="phone_number"){const{country_code:o,phone_number:i}=e;return wn(o,i)}return e[n]},{assign:B}=Ai,bv=B({actorDoneData:void 0}),Av=B({challengeName:void 0}),Ev=B({missingAttributes:void 0}),Iv=B({remoteError:void 0}),Tv=B({formValues:{}}),Nv=B({touched:{}}),Pv=B({user:void 0}),kv=B({validationError:{}}),xv=B({totpSecretCode:(e,{data:t})=>{var o;const{sharedSecret:n}=((o=t.nextStep)==null?void 0:o.totpSetupDetails)??{};return n}}),Uv=B({step:"SIGN_IN"}),$v=B({step:"SHOULD_CONFIRM_USER_ATTRIBUTE"}),Rv=B({step:"CONFIRM_ATTRIBUTE_COMPLETE"}),Ov=B({challengeName:(e,{data:t})=>{const{signInStep:n}=t.nextStep;return n==="CONFIRM_SIGN_IN_WITH_SMS_CODE"?"SMS_MFA":n==="CONFIRM_SIGN_IN_WITH_TOTP_CODE"?"SOFTWARE_TOKEN_MFA":void 0}}),Dv=B({username:({formValues:e,loginMechanisms:t})=>{const n=t[0],{username:o,country_code:i}=e;return n==="phone_number"?wn(i,o):o}}),Fv=B({username:Cv}),Mv=B({username:({formValues:e,loginMechanisms:t})=>{const n=t[0],{username:o,country_code:i}=e;return n==="phone_number"?wn(i,o):o}}),Bv=B({step:(e,{data:t})=>t.nextStep.signInStep==="DONE"?"SIGN_IN_COMPLETE":t.nextStep.signInStep}),Vv=B({step:(e,{data:t})=>t.nextStep.signUpStep==="DONE"?"SIGN_UP_COMPLETE":t.nextStep.signUpStep}),Lv=B({step:(e,{data:t})=>t.nextStep.resetPasswordStep==="DONE"?"RESET_PASSWORD_COMPLETE":t.nextStep.resetPasswordStep}),Gv=B({missingAttributes:(e,{data:t})=>{var n;return(n=t.nextStep)==null?void 0:n.missingAttributes}}),zv=B({validationError:(e,{data:t})=>t}),jv=B({remoteError:(e,{data:t})=>t.name==="NoUserPoolError"?"Configuration error (see console) – please contact the administrator":(t==null?void 0:t.message)||t}),Wv=B({user:(e,{data:t})=>t}),Fo=e=>({Destination:e.destination,DeliveryMedium:e.deliveryMedium,AttributeName:e.attributName}),Hv=B({codeDeliveryDetails:(e,{data:t})=>{var n;return(n=t==null?void 0:t.nextStep)!=null&&n.codeDeliveryDetails?Fo(t.nextStep.codeDeliveryDetails):Fo(t)}}),Yv=B({formValues:(e,{data:t})=>{const{name:n,value:o}=t;return{...e.formValues,[n]:o}}}),Kv=B({formValues:(e,{data:t})=>ds({...e.formValues,...t},"password")}),qv=B({touched:(e,{data:t})=>({...e.touched,[t.name]:!0})}),Jv=B({unverifiedUserAttributes:(e,{data:t})=>{const{email:n,phone_number:o}=t;return{...n&&{email:n},...o&&{phone_number:o}}}}),Zv=B({selectedUserAttribute:void 0}),Qv=B({selectedUserAttribute:e=>{var t;return(t=e.formValues)==null?void 0:t.unverifiedAttr}}),Xv=B({step:"CONFIRM_SIGN_UP"}),Et={clearActorDoneData:bv,clearChallengeName:Av,clearError:Iv,clearFormValues:Tv,clearMissingAttributes:Ev,clearSelectedUserAttribute:Zv,clearTouched:Nv,clearUser:Pv,clearValidationError:kv,handleBlur:qv,handleInput:Yv,handleSubmit:Kv,setChallengeName:Ov,setCodeDeliveryDetails:Hv,setFieldErrors:zv,setMissingAttributes:Gv,setNextResetPasswordStep:Lv,setNextSignInStep:Bv,setNextSignUpStep:Vv,setRemoteError:jv,setConfirmAttributeCompleteStep:Rv,setConfirmSignUpSignUpStep:Xv,setShouldVerifyUserAttributeStep:$v,setSelectedUserAttribute:Qv,setSignInStep:Uv,setTotpSecretCode:xv,setUser:Wv,setUnverifiedUserAttributes:Jv,setUsernameForgotPassword:Dv,setUsernameSignIn:Mv,setUsernameSignUp:Fv},ew=["CONFIRM_SIGN_IN_WITH_SMS_CODE","CONFIRM_SIGN_IN_WITH_TOTP_CODE"],tw=(e,{data:t})=>(t==null?void 0:t.nextStep.signInStep)==="CONFIRM_SIGN_IN_WITH_NEW_PASSWORD_REQUIRED",nw=(e,{data:t})=>{var n;return((n=t==null?void 0:t.nextStep)==null?void 0:n.signInStep)==="RESET_PASSWORD"},rw=(e,{data:t})=>(t==null?void 0:t.nextStep.signInStep)==="CONFIRM_SIGN_UP",ow=(e,{data:t})=>(t==null?void 0:t.nextStep.signUpStep)==="COMPLETE_AUTO_SIGN_IN",iw=(e,{data:t})=>(t==null?void 0:t.nextStep.signInStep)==="DONE",aw=(e,{data:t})=>(t==null?void 0:t.nextStep.signUpStep)==="DONE",sw=(e,{data:t})=>(t==null?void 0:t.nextStep.resetPasswordStep)==="DONE",cw=(e,{data:t})=>(t==null?void 0:t.step)==="CONFIRM_ATTRIBUTE_COMPLETE",lw=(e,{data:t})=>(t==null?void 0:t.step)==="CONFIRM_ATTRIBUTE_WITH_CODE",uw=(e,{data:t})=>(t==null?void 0:t.step)==="SHOULD_CONFIRM_USER_ATTRIBUTE",dw=(e,{data:t})=>(t==null?void 0:t.step)==="RESET_PASSWORD",fw=(e,{data:t})=>(t==null?void 0:t.step)==="CONFIRM_SIGN_UP",pw=({step:e})=>ew.includes(e),mw=({step:e})=>e==="CONTINUE_SIGN_IN_WITH_TOTP_SETUP",gw=({step:e})=>e==="RESET_PASSWORD",hw=({step:e})=>e==="CONFIRM_RESET_PASSWORD_WITH_CODE",yw=({step:e})=>e==="CONFIRM_SIGN_UP",vw=(e,{data:t})=>{const{phone_number_verified:n,email_verified:o}=t;return(o===void 0||o==="false")&&(n===void 0||n==="false")},ww=(e,{data:t})=>t.message==="User is already confirmed.",_n={hasCompletedAttributeConfirmation:cw,hasCompletedResetPassword:sw,hasCompletedSignIn:iw,hasCompletedSignUp:aw,isConfirmSignUpStep:fw,isConfirmUserAttributeStep:lw,isResetPasswordStep:dw,isShouldConfirmUserAttributeStep:uw,isUserAlreadyConfirmed:ww,shouldAutoSignIn:ow,shouldConfirmResetPassword:hw,shouldConfirmSignIn:pw,shouldConfirmSignInWithNewPassword:tw,shouldConfirmSignUp:yw,shouldConfirmSignUpFromSignIn:rw,shouldResetPassword:gw,shouldResetPasswordFromSignIn:nw,shouldSetupTotp:mw,shouldVerifyAttribute:vw};var _w=Tr,Sw=bt;function Cw(e,t,n){(n!==void 0&&!Sw(e[t],n)||n===void 0&&!(t in e))&&_w(e,t,n)}var ta=Cw;function bw(e){return function(t,n,o){for(var i=-1,a=Object(t),s=o(t),c=s.length;c--;){var l=s[e?c:++i];if(n(a[l],l,a)===!1)break}return t}}var Aw=bw,Ew=Aw,Iw=Ew(),Tw=Iw,Qt={exports:{}};Qt.exports;(function(e,t){var n=ge,o=t&&!t.nodeType&&t,i=o&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===o,s=a?n.Buffer:void 0,c=s?s.allocUnsafe:void 0;function l(u,d){if(d)return u.slice();var m=u.length,f=c?c(m):new u.constructor(m);return u.copy(f),f}e.exports=l})(Qt,Qt.exports);var Nw=Qt.exports,Mo=Fi;function Pw(e){var t=new e.constructor(e.byteLength);return new Mo(t).set(new Mo(e)),t}var kw=Pw,xw=kw;function Uw(e,t){var n=t?xw(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var $w=Uw;function Rw(e,t){var n=-1,o=e.length;for(t||(t=Array(o));++n<o;)t[n]=e[n];return t}var Ow=Rw,Dw=be,Bo=Object.create,Fw=function(){function e(){}return function(t){if(!Dw(t))return{};if(Bo)return Bo(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}(),Mw=Fw,Bw=Mw,Vw=Nr,Lw=Sr;function Gw(e){return typeof e.constructor=="function"&&!Lw(e)?Bw(Vw(e)):{}}var zw=Gw,jw=yn,Ww=De;function Hw(e){return Ww(e)&&jw(e)}var Yw=Hw,Kw=et,qw=Nr,Jw=De,Zw="[object Object]",Qw=Function.prototype,Xw=Object.prototype,na=Qw.toString,e_=Xw.hasOwnProperty,t_=na.call(Object);function n_(e){if(!Jw(e)||Kw(e)!=Zw)return!1;var t=qw(e);if(t===null)return!0;var n=e_.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&na.call(n)==t_}var r_=n_;function o_(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var ra=o_,i_=ea,a_=Tr;function s_(e,t,n,o){var i=!n;n||(n={});for(var a=-1,s=t.length;++a<s;){var c=t[a],l=o?o(n[c],e[c],c,n,e):void 0;l===void 0&&(l=e[c]),i?a_(n,c,l):i_(n,c,l)}return n}var c_=s_,l_=c_,u_=Pr;function d_(e){return l_(e,u_(e))}var f_=d_,Vo=ta,p_=Nw,m_=$w,g_=Ow,h_=zw,Lo=yr,Go=Ae,y_=Yw,v_=vr,w_=pr,__=be,S_=r_,C_=_r,zo=ra,b_=f_;function A_(e,t,n,o,i,a,s){var c=zo(e,n),l=zo(t,n),u=s.get(l);if(u){Vo(e,n,u);return}var d=a?a(c,l,n+"",e,t,s):void 0,m=d===void 0;if(m){var f=Go(l),p=!f&&v_(l),h=!f&&!p&&C_(l);d=l,f||p||h?Go(c)?d=c:y_(c)?d=g_(c):p?(m=!1,d=p_(l,!0)):h?(m=!1,d=m_(l,!0)):d=[]:S_(l)||Lo(l)?(d=c,Lo(c)?d=b_(c):(!__(c)||w_(c))&&(d=h_(l))):m=!1}m&&(s.set(l,d),i(d,l,o,a,s),s.delete(l)),Vo(e,n,d)}var E_=A_,I_=hr,T_=ta,N_=Tw,P_=E_,k_=be,x_=Pr,U_=ra;function oa(e,t,n,o,i){e!==t&&N_(t,function(a,s){if(i||(i=new I_),k_(a))P_(e,t,s,n,oa,o,i);else{var c=o?o(U_(e,s),a,s+"",e,t,i):void 0;c===void 0&&(c=a),T_(e,s,c)}},x_)}var $_=oa;function R_(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var O_=R_,D_=O_,jo=Math.max;function F_(e,t,n){return t=jo(t===void 0?e.length-1:t,0),function(){for(var o=arguments,i=-1,a=jo(o.length-t,0),s=Array(a);++i<a;)s[i]=o[t+i];i=-1;for(var c=Array(t+1);++i<t;)c[i]=o[i];return c[t]=n(s),D_(e,this,c)}}var M_=F_;function B_(e){return function(){return e}}var V_=B_,L_=V_,Wo=Xi,G_=Ir,z_=Wo?function(e,t){return Wo(e,"toString",{configurable:!0,enumerable:!1,value:L_(t),writable:!0})}:G_,j_=z_,W_=800,H_=16,Y_=Date.now;function K_(e){var t=0,n=0;return function(){var o=Y_(),i=H_-(o-n);if(n=o,i>0){if(++t>=W_)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var q_=K_,J_=j_,Z_=q_,Q_=Z_(J_),X_=Q_,eS=Ir,tS=M_,nS=X_;function rS(e,t){return nS(tS(e,t,eS),e+"")}var oS=rS,iS=bt,aS=yn,sS=hn,cS=be;function lS(e,t,n){if(!cS(n))return!1;var o=typeof t;return(o=="number"?aS(n)&&sS(t,n.length):o=="string"&&t in n)?iS(n[t],e):!1}var uS=lS,dS=oS,fS=uS;function pS(e){return dS(function(t,n){var o=-1,i=n.length,a=i>1?n[i-1]:void 0,s=i>2?n[2]:void 0;for(a=e.length>3&&typeof a=="function"?(i--,a):void 0,s&&fS(n[0],n[1],s)&&(a=i<3?void 0:a,i=1),t=Object(t);++o<i;){var c=n[o];c&&e(t,c,o,a)}return t})}var mS=pS,gS=$_,hS=mS,yS=hS(function(e,t,n){gS(e,t,n)}),vS=yS;const wS=xi(vS),Sn=async(e,t,n,o)=>{const i=await Promise.all(o.map(s=>s(e,t,n))),a=wS({},...i);return Zo(a)?Promise.resolve():Promise.reject(a)},_S=8,SS=e=>Array.isArray(e),CS=e=>{if(e)return SS(e)?Object.entries(e).map(([t,n])=>Object.keys(n)[0]):Object.keys(e)},ke={async getAmplifyConfig(){var c,l,u,d;const e=Ua.Amplify.getConfig(),t=(c=e.Auth)==null?void 0:c.Cognito,{loginWith:n,userAttributes:o}=((l=e.Auth)==null?void 0:l.Cognito)??{},i=n?Object.entries(n).filter(([m,f])=>m!=="oauth").filter(([m,f])=>!!f).map(m=>m[0]==="phone"?"phone_number":m[0]):void 0,a=CS(o),s=(u=n==null?void 0:n.oauth)!=null&&u.providers?(d=n.oauth.providers)==null?void 0:d.map(m=>m.toString().toLowerCase()):void 0;return{...t,loginMechanisms:i,signUpAttributes:a,socialProviders:s}},getCurrentUser:H.getCurrentUser,handleSignIn:H.signIn,handleSignUp:H.signUp,handleConfirmSignIn:H.confirmSignIn,handleConfirmSignUp:H.confirmSignUp,handleForgotPasswordSubmit:H.confirmResetPassword,handleForgotPassword:H.resetPassword,async validateCustomSignUp(e,t){},async validateFormPassword(e,t,n){const{password:o}=e,{password:i}=t;if(!i||!n)return null;const a=[],s=n.minLength??_S;return o.length<s&&a.push(`Password must have at least ${s} characters`),n.requireLowercase&&!/[a-z]/.test(o)&&a.push("Password must have lower case letters"),n.requireUppercase&&!/[A-Z]/.test(o)&&a.push("Password must have upper case letters"),n.requireNumbers&&!/[0-9]/.test(o)&&a.push("Password must have numbers"),n.requireSpecialCharacters&&!ls(o)&&a.push("Password must have special characters"),a.length!==0?{password:a}:null},async validateConfirmPassword(e,t){const{password:n,confirm_password:o}=e,{confirm_password:i,password:a}=t;if(!n&&!o)return null;if((n||o)&&n!==o&&(i&&a||(n==null?void 0:n.length)>=6&&(o==null?void 0:o.length)>=6))return{confirm_password:"Your passwords must match"}},async validatePreferredUsername(e,t){}};function bS({services:e}){return Qe({id:"forgotPasswordActor",initial:"init",predictableActionArguments:!0,states:{init:{always:[{cond:"shouldResetPassword",target:"confirmResetPassword"},{cond:"shouldConfirmResetPassword",target:"confirmResetPassword"},{target:"forgotPassword"}]},forgotPassword:{initial:"edit",entry:"sendUpdate",exit:["clearError","clearTouched"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},CHANGE:{actions:"handleInput"},BLUR:{actions:"handleBlur"}}},submit:{tags:"pending",entry:["sendUpdate","clearError","setUsernameForgotPassword"],invoke:{src:"handleResetPassword",onDone:{actions:["setCodeDeliveryDetails","setNextResetPasswordStep"],target:"#forgotPasswordActor.confirmResetPassword"},onError:{actions:"setRemoteError",target:"edit"}}}}},confirmResetPassword:{type:"parallel",exit:["clearFormValues","clearError","clearTouched"],states:{validation:{initial:"pending",states:{pending:{invoke:{src:"validateFields",onDone:{target:"valid",actions:"clearValidationError"},onError:{target:"invalid",actions:"setFieldErrors"}}},valid:{entry:"sendUpdate"},invalid:{entry:"sendUpdate"}},on:{CHANGE:{actions:"handleInput",target:".pending"},BLUR:{actions:"handleBlur",target:".pending"}}},submission:{initial:"idle",states:{idle:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"validate"},RESEND:"resendCode",CHANGE:{actions:"handleInput"},BLUR:{actions:"handleBlur"}}},validate:{entry:"sendUpdate",invoke:{src:"validateFields",onDone:{target:"pending",actions:"clearValidationError"},onError:{target:"idle",actions:"setFieldErrors"}}},resendCode:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"handleResetPassword",onDone:{target:"idle"},onError:{actions:"setRemoteError",target:"idle"}}},pending:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"handleConfirmResetPassword",onDone:[{cond:"hasCompletedResetPassword",actions:"setNextResetPasswordStep",target:"#forgotPasswordActor.resolved"},{actions:"setSignInStep",target:"#forgotPasswordActor.resolved"}],onError:{actions:"setRemoteError",target:"idle"}}}}}}},resolved:{type:"final",data:({step:t})=>({step:t})}}},{actions:{...Et,sendUpdate:un()},guards:_n,services:{handleResetPassword({username:t}){return e.handleForgotPassword({username:t})},handleConfirmResetPassword({formValues:t,username:n}){const{confirmation_code:o,password:i}=t;return e.handleForgotPasswordSubmit({confirmationCode:o,newPassword:i,username:n})},validateFields(t){return Sn(t.formValues,t.touched,t.passwordSettings,[ke.validateFormPassword,ke.validateConfirmPassword])}}})}const ia=e=>({entry:["sendUpdate","clearError"],invoke:{src:"signInWithRedirect",onDone:{target:e},onError:{actions:"setRemoteError",target:e}}}),$t={onDone:[{cond:"hasCompletedSignIn",actions:"setNextSignInStep",target:"#signInActor.fetchUserAttributes"},{cond:"shouldConfirmSignInWithNewPassword",actions:["setMissingAttributes","setNextSignInStep"],target:"#signInActor.forceChangePassword"},{cond:"shouldResetPasswordFromSignIn",actions:"setNextSignInStep",target:"#signInActor.resetPassword"},{cond:"shouldConfirmSignUpFromSignIn",actions:"setNextSignInStep",target:"#signInActor.resendSignUpCode"},{actions:["setChallengeName","setMissingAttributes","setNextSignInStep","setTotpSecretCode"],target:"#signInActor.init"}],onError:{actions:"setRemoteError",target:"edit"}},AS={onDone:[{cond:"shouldVerifyAttribute",actions:["setShouldVerifyUserAttributeStep","setUnverifiedUserAttributes"],target:"#signInActor.resolved"},{actions:"setConfirmAttributeCompleteStep",target:"#signInActor.resolved"}],onError:{actions:"setConfirmAttributeCompleteStep",target:"#signInActor.resolved"}};function ES({services:e}){return Qe({id:"signInActor",initial:"init",predictableActionArguments:!0,states:{init:{always:[{cond:"shouldConfirmSignIn",target:"confirmSignIn"},{cond:"shouldSetupTotp",target:"setupTotp"},{cond:({step:t})=>t==="CONFIRM_SIGN_IN_WITH_NEW_PASSWORD_REQUIRED",actions:"setActorDoneData",target:"forceChangePassword"},{target:"signIn"}]},federatedSignIn:ia("signIn"),fetchUserAttributes:{invoke:{src:"fetchUserAttributes",...AS}},resendSignUpCode:{invoke:{src:"handleResendSignUpCode",onDone:{actions:"setCodeDeliveryDetails",target:"#signInActor.resolved"},onError:{actions:"setRemoteError",target:"#signInActor.signIn"}}},resetPassword:{invoke:{src:"resetPassword",onDone:[{actions:"setCodeDeliveryDetails",target:"#signInActor.resolved"}],onError:{actions:["setRemoteError","sendUpdate"]}}},signIn:{initial:"edit",exit:"clearTouched",states:{edit:{entry:"sendUpdate",on:{CHANGE:{actions:"handleInput"},FEDERATED_SIGN_IN:{target:"#signInActor.federatedSignIn"},SUBMIT:{actions:"handleSubmit",target:"submit"}}},submit:{tags:"pending",entry:["clearError","sendUpdate","setUsernameSignIn"],exit:"clearFormValues",invoke:{src:"handleSignIn",...$t}}}},confirmSignIn:{initial:"edit",exit:["clearChallengeName","clearFormValues","clearError","clearTouched"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},SIGN_IN:"#signInActor.signIn",CHANGE:{actions:"handleInput"}}},submit:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"confirmSignIn",...$t}}}},forceChangePassword:{entry:"sendUpdate",type:"parallel",exit:["clearFormValues","clearError","clearTouched"],states:{validation:{initial:"pending",states:{pending:{invoke:{src:"validateFields",onDone:{target:"valid",actions:"clearValidationError"},onError:{target:"invalid",actions:"setFieldErrors"}}},valid:{entry:"sendUpdate"},invalid:{entry:"sendUpdate"}},on:{SIGN_IN:{actions:"setSignInStep",target:"#signInActor.resolved"},CHANGE:{actions:"handleInput",target:".pending"},BLUR:{actions:"handleBlur",target:".pending"}}},submit:{initial:"edit",entry:"clearError",states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"validate"}}},validate:{entry:"sendUpdate",invoke:{src:"validateFields",onDone:{actions:"clearValidationError",target:"pending"},onError:{actions:"setFieldErrors",target:"edit"}}},pending:{tags:"pending",entry:["sendUpdate","clearError"],invoke:{src:"handleForceChangePassword",...$t}}}}}},setupTotp:{initial:"edit",exit:["clearFormValues","clearError","clearTouched"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},SIGN_IN:"#signInActor.signIn",CHANGE:{actions:"handleInput"}}},submit:{tags:"pending",entry:["sendUpdate","clearError"],invoke:{src:"confirmSignIn",...$t}}}},resolved:{type:"final",data:t=>({codeDeliveryDetails:t.codeDeliveryDetails,remoteError:t.remoteError,step:t.step,unverifiedUserAttributes:t.unverifiedUserAttributes,username:t.username})}}},{actions:{...Et,sendUpdate:un()},guards:_n,services:{async fetchUserAttributes(){return H.fetchUserAttributes()},resetPassword({username:t}){return H.resetPassword({username:t})},handleResendSignUpCode({username:t}){return H.resendSignUpCode({username:t})},handleSignIn({formValues:t,username:n}){const{password:o}=t;return e.handleSignIn({username:n,password:o})},confirmSignIn({formValues:t}){const{confirmation_code:n}=t;return e.handleConfirmSignIn({challengeResponse:n})},async handleForceChangePassword({formValues:t}){let{password:n,phone_number:o,country_code:i,confirm_password:a,...s}=t,c;o&&(c=`${i}${o}`.replace(/[^A-Z0-9+]/gi,""),s={...s,phone_number:c});const l={challengeResponse:n,options:{userAttributes:s}};return H.confirmSignIn(l)},signInWithRedirect(t,{data:n}){return H.signInWithRedirect(n)},async validateFields(t){return Sn(t.formValues,t.touched,t.passwordSettings,[ke.validateFormPassword,ke.validateConfirmPassword])}}})}const IS={onDone:[{actions:"setCodeDeliveryDetails",target:"#signUpActor.resolved"}],onError:{actions:["setRemoteError","sendUpdate"]}},TS={onDone:[{cond:"hasCompletedSignIn",actions:"setNextSignInStep",target:"#signUpActor.fetchUserAttributes"},{cond:"shouldConfirmSignInWithNewPassword",actions:"setNextSignInStep",target:"#signUpActor.resolved"},{cond:"shouldResetPasswordFromSignIn",actions:"setNextSignInStep",target:"#signUpActor.resetPassword"},{cond:"shouldConfirmSignUpFromSignIn",actions:"setNextSignInStep",target:"#signUpActor.resendSignUpCode"},{actions:["setNextSignInStep","setChallengeName","setMissingAttributes","setTotpSecretCode"],target:"#signUpActor.resolved"}],onError:{actions:"setRemoteError",target:"#signUpActor.resolved"}},NS={onDone:[{cond:"shouldVerifyAttribute",actions:["setShouldVerifyUserAttributeStep","setUnverifiedUserAttributes"],target:"#signUpActor.resolved"},{actions:"setConfirmAttributeCompleteStep",target:"#signUpActor.resolved"}],onError:{actions:"setConfirmAttributeCompleteStep",target:"#signUpActor.resolved"}};function PS({services:e}){return Qe({id:"signUpActor",initial:"init",predictableActionArguments:!0,states:{init:{always:[{cond:"shouldConfirmSignUp",target:"confirmSignUp"},{target:"signUp"}]},autoSignIn:{tags:"pending",invoke:{src:"autoSignIn",...TS}},fetchUserAttributes:{invoke:{src:"fetchUserAttributes",...NS}},federatedSignIn:ia("signUp"),resetPassword:{invoke:{src:"resetPassword",...IS}},resendSignUpCode:{tags:"pending",entry:"sendUpdate",exit:"sendUpdate",invoke:{src:"resendSignUpCode",onDone:{actions:["setCodeDeliveryDetails","sendUpdate"],target:"#signUpActor.confirmSignUp"},onError:[{cond:"isUserAlreadyConfirmed",target:"#signUpActor.resolved"},{actions:["setRemoteError","sendUpdate"]}]}},signUp:{type:"parallel",exit:"clearTouched",on:{FEDERATED_SIGN_IN:{target:"federatedSignIn"}},states:{validation:{initial:"pending",states:{pending:{invoke:{src:"validateSignUp",onDone:{actions:"clearValidationError",target:"valid"},onError:{actions:"setFieldErrors",target:"invalid"}}},valid:{entry:"sendUpdate"},invalid:{entry:"sendUpdate"}},on:{BLUR:{actions:"handleBlur",target:".pending"},CHANGE:{actions:"handleInput",target:".pending"}}},submission:{initial:"idle",states:{idle:{entry:["sendUpdate"],on:{SUBMIT:{actions:"handleSubmit",target:"validate"}}},validate:{entry:"sendUpdate",invoke:{src:"validateSignUp",onDone:{target:"handleSignUp",actions:"clearValidationError"},onError:{actions:"setFieldErrors",target:"idle"}}},handleSignUp:{tags:"pending",entry:["setUsernameSignUp","clearError"],exit:"sendUpdate",invoke:{src:"handleSignUp",onDone:[{cond:"hasCompletedSignUp",actions:"setNextSignUpStep",target:"#signUpActor.resolved"},{cond:"shouldAutoSignIn",actions:"setNextSignUpStep",target:"#signUpActor.autoSignIn"},{actions:["setCodeDeliveryDetails","setNextSignUpStep"],target:"#signUpActor.init"}],onError:{actions:["sendUpdate","setRemoteError"],target:"idle"}}}}}}},confirmSignUp:{initial:"edit",entry:"sendUpdate",states:{edit:{on:{SUBMIT:{actions:"handleSubmit",target:"submit"},CHANGE:{actions:"handleInput"},BLUR:{actions:"handleBlur"},RESEND:"#signUpActor.resendSignUpCode"}},submit:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"confirmSignUp",onDone:[{cond:"shouldAutoSignIn",actions:["setNextSignUpStep","clearFormValues"],target:"#signUpActor.autoSignIn"},{actions:"setNextSignUpStep",target:"#signUpActor.init"}],onError:{actions:["setRemoteError","sendUpdate"],target:"edit"}}}}},resolved:{type:"final",data:t=>({challengeName:t.challengeName,missingAttributes:t.missingAttributes,remoteError:t.remoteError,step:t.step,totpSecretCode:t.totpSecretCode,username:t.username,unverifiedUserAttributes:t.unverifiedUserAttributes})}}},{actions:{...Et,sendUpdate:un()},guards:_n,services:{autoSignIn(){return H.autoSignIn()},async fetchUserAttributes(){return H.fetchUserAttributes()},confirmSignUp({formValues:t,username:n}){const{confirmation_code:o}=t,i={username:n,confirmationCode:o};return e.handleConfirmSignUp(i)},resendSignUpCode({username:t}){return H.resendSignUpCode({username:t})},signInWithRedirect(t,{data:n}){return H.signInWithRedirect(n)},handleSignUp(t){const{formValues:n,loginMechanisms:o,username:i}=t,a=o[0],s=Sv(i,n,a);return e.handleSignUp(s)},async validateSignUp(t){return Sn(t.formValues,t.touched,t.passwordSettings,[e.validateFormPassword,e.validateConfirmPassword,e.validatePreferredUsername,e.validateCustomSignUp])}}})}const kS=()=>Qe({initial:"pending",id:"signOutActor",predictableActionArguments:!0,states:{pending:{tags:"pending",invoke:{src:"signOut",onDone:"resolved",onError:"rejected"}},resolved:{type:"final"},rejected:{type:"final"}}},{services:{signOut:()=>H.signOut()}});function xS(){return Qe({id:"verifyUserAttributesActor",initial:"selectUserAttributes",predictableActionArguments:!0,states:{selectUserAttributes:{initial:"edit",exit:["clearError","clearTouched","sendUpdate"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},SKIP:{target:"#verifyUserAttributesActor.resolved"},CHANGE:{actions:"handleInput"}}},submit:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"sendUserAttributeVerificationCode",onDone:{actions:["setSelectedUserAttribute","setCodeDeliveryDetails"],target:"#verifyUserAttributesActor.confirmVerifyUserAttribute"},onError:{actions:"setRemoteError",target:"edit"}}}}},confirmVerifyUserAttribute:{initial:"edit",exit:["clearError","clearFormValues","clearTouched"],states:{edit:{entry:"sendUpdate",on:{SUBMIT:{actions:"handleSubmit",target:"submit"},SKIP:"#verifyUserAttributesActor.resolved",CHANGE:{actions:"handleInput"}}},submit:{tags:"pending",entry:["clearError","sendUpdate"],invoke:{src:"confirmVerifyUserAttribute",onDone:{actions:["setConfirmAttributeCompleteStep","clearSelectedUserAttribute"],target:"#verifyUserAttributesActor.resolved"},onError:{actions:"setRemoteError",target:"edit"}}}}},resolved:{type:"final",data:({step:e})=>({step:e})}}},{actions:{...Et,sendUpdate:un()},services:{sendUserAttributeVerificationCode({formValues:{unverifiedAttr:e}}){const t={userAttributeKey:e};return H.sendUserAttributeVerificationCode(t)},async confirmVerifyUserAttribute({formValues:{confirmation_code:e},selectedUserAttribute:t}){const n={confirmationCode:e,userAttributeKey:t};return H.confirmUserAttribute(n)},async validateFields(e){return Sn(e.formValues,e.touched,e.passwordSettings,[ke.validateFormPassword,ke.validateConfirmPassword])}}})}const Rt=(e,t)=>{var n,o,i,a,s,c;return{...e.actorDoneData,step:((n=e==null?void 0:e.actorDoneData)==null?void 0:n.step)??t,formValues:{},touched:{},validationError:{},formFields:(o=e.config)==null?void 0:o.formFields,loginMechanisms:(i=e.config)==null?void 0:i.loginMechanisms,passwordSettings:(a=e.config)==null?void 0:a.passwordSettings,signUpAttributes:(s=e.config)==null?void 0:s.signUpAttributes,socialProviders:(c=e.config)==null?void 0:c.socialProviders}},{choose:US,stop:$S}=Ai,lt=e=>$S(e),RS={on:{INIT:{actions:"configure",target:"getConfig"},SIGN_OUT:"#authenticator.signOut"}},OS={always:{actions:"configure",target:"getConfig"}};function DS(e){const{useNextWaitConfig:t,...n}=e??{};return Qe({id:"authenticator",initial:"idle",context:{user:void 0,config:{},services:ke,actorRef:void 0,hasSetup:!1},predictableActionArguments:!0,states:{idle:{invoke:{src:"handleGetCurrentUser",onDone:{actions:"setUser",target:"setup"},onError:{target:"setup"}}},setup:{initial:"initConfig",states:{initConfig:t?OS:RS,getConfig:{invoke:{src:"getAmplifyConfig",onDone:[{actions:["applyAmplifyConfig","setHasSetup"],cond:"hasUser",target:"#authenticator.authenticated"},{actions:["applyAmplifyConfig","setHasSetup"],target:"goToInitialState"}]}},goToInitialState:{always:[{cond:"isInitialStateSignUp",target:"#authenticator.signUpActor"},{cond:"isInitialStateResetPassword",target:"#authenticator.forgotPasswordActor"},{target:"#authenticator.signInActor"}]}}},getCurrentUser:{invoke:{src:"handleGetCurrentUser",onDone:{actions:"setUser",target:"#authenticator.authenticated"},onError:{target:"#authenticator.setup"}}},signInActor:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnSignInActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("signInActor")}},on:{FORGOT_PASSWORD:"forgotPasswordActor",SIGN_IN:"signInActor",SIGN_UP:"signUpActor","done.invoke.signInActor":[{cond:"hasCompletedAttributeConfirmation",target:"#authenticator.getCurrentUser"},{cond:"isShouldConfirmUserAttributeStep",actions:"setActorDoneData",target:"#authenticator.verifyUserAttributesActor"},{cond:"isResetPasswordStep",actions:"setActorDoneData",target:"#authenticator.forgotPasswordActor"},{cond:"isConfirmSignUpStep",actions:"setActorDoneData",target:"#authenticator.signUpActor"}]}},signUpActor:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnSignUpActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("signUpActor")}},on:{SIGN_IN:"signInActor","done.invoke.signUpActor":[{cond:"hasCompletedAttributeConfirmation",target:"#authenticator.getCurrentUser"},{cond:"isShouldConfirmUserAttributeStep",actions:"setActorDoneData",target:"#authenticator.verifyUserAttributesActor"},{cond:"isConfirmUserAttributeStep",target:"#authenticator.verifyUserAttributesActor"},{actions:"setActorDoneData",target:"#authenticator.signInActor"}]}},forgotPasswordActor:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnForgotPasswordActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("forgotPasswordActor")}},on:{SIGN_IN:"signInActor","done.invoke.forgotPasswordActor":[{target:"#authenticator.signInActor"}]}},verifyUserAttributesActor:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnVerifyUserAttributesActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("verifyUserAttributesActor")}},on:{"done.invoke.verifyUserAttributesActor":[{actions:"setActorDoneData",target:"#authenticator.getCurrentUser"}]}},authenticated:{initial:"idle",states:{idle:{on:{TOKEN_REFRESH:"refreshUser"}},refreshUser:{invoke:{src:"#authenticator.getCurrentUser",onDone:{actions:"setUser",target:"idle"},onError:{target:"#authenticator.signOut"}}}},on:{SIGN_OUT:"signOut"}},signOut:{initial:"spawnActor",states:{spawnActor:{always:{actions:"spawnSignOutActor",target:"runActor"}},runActor:{entry:"clearActorDoneData",exit:lt("signOutActor")}},on:{"done.invoke.signOutActor":{actions:"clearUser",target:"setup.getConfig"}}}},on:{SIGN_IN_WITH_REDIRECT:{target:"#authenticator.getCurrentUser"},CHANGE:{actions:"forwardToActor"},BLUR:{actions:"forwardToActor"},SUBMIT:{actions:"forwardToActor"},FEDERATED_SIGN_IN:{actions:"forwardToActor"},RESEND:{actions:"forwardToActor"},SIGN_IN:{actions:"forwardToActor"},SKIP:{actions:"forwardToActor"}}},{actions:{...Et,forwardToActor:US([{cond:"hasActor",actions:ll(({actorRef:i})=>i)}]),setActorDoneData:_e({actorDoneData:(i,a)=>({challengeName:a.data.challengeName,codeDeliveryDetails:a.data.codeDeliveryDetails,missingAttributes:a.data.missingAttributes,remoteError:a.data.remoteError,username:a.data.username,step:a.data.step,totpSecretCode:a.data.totpSecretCode,unverifiedUserAttributes:a.data.unverifiedUserAttributes})}),applyAmplifyConfig:_e({config(i,{data:a}){const{loginMechanisms:s=a.loginMechanisms??[],signUpAttributes:c=a.signUpAttributes??[],socialProviders:l=a.socialProviders??[],initialState:u,formFields:d,passwordSettings:m=a.passwordFormat??{}}=i.config;return s.length===0&&s.push("username"),{formFields:FS(d)??{},initialState:u,loginMechanisms:s,passwordSettings:m,signUpAttributes:c,socialProviders:l}}}),spawnSignInActor:_e({actorRef:(i,a)=>{const{services:s}=i,c=ES({services:s}).withContext(Rt(i,"SIGN_IN"));return at(c,{name:"signInActor"})}}),spawnSignUpActor:_e({actorRef:(i,a)=>{const{services:s}=i,c=PS({services:s}).withContext(Rt(i,"SIGN_UP"));return at(c,{name:"signUpActor"})}}),spawnForgotPasswordActor:_e({actorRef:(i,a)=>{const{services:s}=i,c=bS({services:s}).withContext(Rt(i,"FORGOT_PASSWORD"));return at(c,{name:"forgotPasswordActor"})}}),spawnVerifyUserAttributesActor:_e({actorRef:i=>{const a=xS().withContext(Rt(i));return at(a,{name:"verifyUserAttributesActor"})}}),spawnSignOutActor:_e({actorRef:i=>{const a=kS().withContext({user:i==null?void 0:i.user});return at(a,{name:"signOutActor"})}}),configure:_e((i,a)=>{const{services:s,...c}=ja(n)?a.data??{}:n;return{services:{...ke,...s},config:c}}),setHasSetup:_e({hasSetup:!0})},guards:{..._n,hasActor:({actorRef:i})=>!!i,isInitialStateSignUp:({config:i})=>i.initialState==="signUp",isInitialStateResetPassword:({config:i})=>i.initialState==="forgotPassword",shouldSetup:({hasSetup:i})=>!i,hasUser:({user:i})=>!!i},services:{getAmplifyConfig:({services:i})=>i.getAmplifyConfig(),handleGetCurrentUser:({services:i})=>i.getCurrentUser()}})}function FS(e){return e&&Object.keys(e).forEach(t=>{Object.keys(e[t]).forEach(n=>{let o=e[t][n];o.required=o.isRequired})}),e}const Q={Accordion:"amplify-accordion",AccordionItem:"amplify-accordion__item",AccordionItemTrigger:"amplify-accordion__item__trigger",AccordionItemContent:"amplify-accordion__item__content",AccordionItemIcon:"amplify-accordion__item__icon",Alert:"amplify-alert",AlertIcon:"amplify-alert__icon",AlertHeading:"amplify-alert__heading",AlertBody:"amplify-alert__body",AlertDismiss:"amplify-alert__dismiss",Autocomplete:"amplify-autocomplete",AutocompleteMenu:"amplify-autocomplete__menu",AutocompleteMenuEmpty:"amplify-autocomplete__menu--empty",AutocompleteMenuFooter:"amplify-autocomplete__menu__footer",AutocompleteMenuHeader:"amplify-autocomplete__menu__header",AutocompleteMenuLoading:"amplify-autocomplete__menu--loading",AutocompleteMenuOption:"amplify-autocomplete__menu__option",AutocompleteMenuOptions:"amplify-autocomplete__menu__options",Badge:"amplify-badge",Breadcrumbs:"amplify-breadcrumbs",BreadcrumbsList:"amplify-breadcrumbs__list",BreadcrumbsItem:"amplify-breadcrumbs__item",BreadcrumbsSeparator:"amplify-breadcrumbs__separator",BreadcrumbsLink:"amplify-breadcrumbs__link",Button:"amplify-button",ButtonGroup:"amplify-buttongroup",ButtonLoaderWrapper:"amplify-button__loader-wrapper",Card:"amplify-card",Checkbox:"amplify-checkbox",CheckboxButton:"amplify-checkbox__button",CheckboxIcon:"amplify-checkbox__icon",CheckboxInput:"amplify-checkbox__input",CheckboxLabel:"amplify-checkbox__label",CheckboxField:"amplify-checkboxfield",Collection:"amplify-collection",CollectionItems:"amplify-collection-items",CollectionSearch:"amplify-collection-search",CollectionPagination:"amplify-collection-pagination",CountryCodeSelect:"amplify-countrycodeselect",DialCodeSelect:"amplify-dialcodeselect",Divider:"amplify-divider",DividerLabel:"amplify-divider--label",DropZone:"amplify-dropzone",Field:"amplify-field",FieldDescription:"amplify-field__description",FieldErrorMessage:"amplify-field__error-message",FieldGroup:"amplify-field-group",FieldGroupControl:"amplify-field-group__control",FieldGroupOuterEnd:"amplify-field-group__outer-end",FieldGroupOuterStart:"amplify-field-group__outer-start",FieldGroupInnerEnd:"amplify-field-group__inner-end",FieldGroupInnerStart:"amplify-field-group__inner-start",FieldGroupIcon:"amplify-field-group__icon",FieldGroupIconButton:"amplify-field-group__icon-button",FieldGroupHasInnerEnd:"amplify-field-group--has-inner-end",FieldGroupHasInnerStart:"amplify-field-group--has-inner-start",FieldShowPassword:"amplify-field__show-password",FieldGroupFieldWrapper:"amplify-field-group__field-wrapper",Fieldset:"amplify-fieldset",FieldsetLegend:"amplify-fieldset__legend",Flex:"amplify-flex",Grid:"amplify-grid",Heading:"amplify-heading",HighlightMatch:"amplify-highlightmatch",HighlightMatchHighlighted:"amplify-highlightmatch__highlighted",Icon:"amplify-icon",Image:"amplify-image",Input:"amplify-input",Label:"amplify-label",Link:"amplify-link",Loader:"amplify-loader",LoaderLabel:"amplify-loader__label",MenuContent:"amplify-menu__content",MenuItem:"amplify-menu__content__item",MenuTrigger:"amplify-menu__trigger",MenuWrapper:"amplify-menu__wrapper",Message:"amplify-message",MessageIcon:"amplify-message__icon",MessageHeading:"amplify-message__heading",MessageBody:"amplify-message__body",MessageContent:"amplify-message__content",MessageDismiss:"amplify-message__dismiss",Pagination:"amplify-pagination",PaginationItem:"amplify-pagination__item",PasswordField:"amplify-passwordfield",PhoneNumberField:"amplify-phonenumberfield",Placeholder:"amplify-placeholder",Radio:"amplify-radio",RadioButton:"amplify-radio__button",RadioInput:"amplify-radio__input",RadioLabel:"amplify-radio__label",RadioGroupField:"amplify-radiogroupfield",RadioGroup:"amplify-radiogroup",Rating:"amplify-rating",RatingItem:"amplify-rating__item",RatingIcon:"amplify-rating__icon",RatingLabel:"amplify-rating__label",ScrollView:"amplify-scrollview",SearchField:"amplify-searchfield",SearchFieldClear:"amplify-searchfield__clear",SearchFieldSearch:"amplify-searchfield__search",Select:"amplify-select",SelectField:"amplify-selectfield",SelectWrapper:"amplify-select__wrapper",SelectIcon:"amplify-select__icon",SliderField:"amplify-sliderfield",SliderFieldGroup:"amplify-sliderfield__group",SliderFieldLabel:"amplify-sliderfield__label",SliderFieldRange:"amplify-sliderfield__range",SliderFieldRoot:"amplify-sliderfield__root",SliderFieldThumb:"amplify-sliderfield__thumb",SliderFieldTrack:"amplify-sliderfield__track",StepperField:"amplify-stepperfield",StepperFieldButtonDecrease:"amplify-stepperfield__button--decrease",StepperFieldButtonIncrease:"amplify-stepperfield__button--increase",StepperFieldInput:"amplify-stepperfield__input",StorageImage:"amplify-storageimage",StorageManager:"amplify-storagemanager",StorageManagerDropZone:"amplify-storagemanager__dropzone",StorageManagerDropZoneIcon:"amplify-storagemanager__dropzone__icon",StorageManagerDropZoneText:"amplify-storagemanager__dropzone__text",StorageManagerFilePicker:"amplify-storagemanager__file__picker",StorageManagerFile:"amplify-storagemanager__file",StorageManagerFileWrapper:"amplify-storagemanager__file__wrapper",StorageManagerFileList:"amplify-storagemanager__file__list",StorageManagerFileName:"amplify-storagemanager__file__name",StorageManagerFileSize:"amplify-storagemanager__file__size",StorageManagerFileInfo:"amplify-storagemanager__file__info",StorageManagerFileImage:"amplify-storagemanager__file__image",StorageManagerFileMain:"amplify-storagemanager__file__main",StorageManagerFileStatus:"amplify-storagemanager__file__status",StorageManagerLoader:"amplify-storagemanager__loader",StorageManagerPreviewer:"amplify-storagemanager__previewer",StorageManagerPreviewerText:"amplify-storagemanager__previewer__text",StorageManagerPreviewerActions:"amplify-storagemanager__previewer__actions",StorageManagerPreviewerFooter:"amplify-storagemanager__previewer__footer",SwitchField:"amplify-switchfield",SwitchLabel:"amplify-switch__label",SwitchThumb:"amplify-switch__thumb",SwitchTrack:"amplify-switch__track",SwitchWrapper:"amplify-switch__wrapper",Table:"amplify-table",TableCaption:"amplify-table__caption",TableBody:"amplify-table__body",TableTd:"amplify-table__td",TableTh:"amplify-table__th",TableFoot:"amplify-table__foot",TableHead:"amplify-table__head",TableRow:"amplify-table__row",Tabs:"amplify-tabs",TabsList:"amplify-tabs__list",TabsItem:"amplify-tabs__item",TabsPanel:"amplify-tabs__panel",Text:"amplify-text",Textarea:"amplify-textarea",TextAreaField:"amplify-textareafield",TextField:"amplify-textfield",ToggleButton:"amplify-togglebutton",ToggleButtonGroup:"amplify-togglebuttongroup",VisuallyHidden:"amplify-visually-hidden"},MS=({componentName:e,packageName:t,version:n})=>{const o=[`ui-${t}`,n];switch(e){case"Authenticator":{L.setCustomUserAgent({...Fa,additionalDetails:[[e],o]});break}case"ChangePassword":case"DeleteUser":{L.setCustomUserAgent({...Da,additionalDetails:[["AccountSettings"],o]});break}case"InAppMessaging":{L.setCustomUserAgent({...Ma,additionalDetails:[[e],o]});break}case"LocationSearch":{L.setCustomUserAgent({...Ba,additionalDetails:[[e],o]});break}case"MapView":{L.setCustomUserAgent({...Va,additionalDetails:[[e],o]});break}case"StorageManager":{L.setCustomUserAgent({...La,additionalDetails:[[e],o]});break}}return Ha},BS={key:0,class:"amplify-flex amplify-alert amplify-alert--error amplify-authenticator__base","data-variation":"error",role:"alert"},VS={class:"amplify-flex amplify-authenticator__icon-wrapper"},LS=r.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",class:"amplify-icon","aria-hidden":"true",viewBox:"0 0 24 24",fill:"currentColor"},[r.createElementVNode("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"})],-1),GS=r.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",class:"amplify-icon","aria-hidden":"true",viewBox:"0 0 24 24",fill:"currentColor"},[r.createElementVNode("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"})],-1),he=r.defineComponent({__name:"base-alert",setup(e){const t=r.ref(!0),n=T("Dismiss alert");function o(){t.value=!1}return(i,a)=>{const s=ne;return t.value?(r.openBlock(),r.createElementBlock("div",BS,[r.createElementVNode("div",VS,[LS,r.createElementVNode("div",null,[r.renderSlot(i.$slots,"default")])]),r.createVNode(s,{class:"amplify-field-group__control amplify-alert__dismiss","aria-label":r.unref(n),fullwidth:!1,variation:"link",type:"button",onClick:o},{default:r.withCtx(()=>[GS]),_:1},8,["aria-label"])])):r.createCommentVNode("",!0)}}}),ye=r.defineComponent({__name:"base-field-set",setup(e){const t=r.useSlots();return(n,o)=>r.renderSlot(n.$slots,"fieldSetI",r.mergeProps(n.$attrs,{slotData:r.unref(t).default&&r.unref(t).default()}),()=>[r.createElementVNode("fieldset",r.mergeProps(n.$attrs,{"data-amplify-fieldset":""}),[r.renderSlot(n.$slots,"default")],16)])}});function zS(e){return r.getCurrentScope()?(r.onScopeDispose(e),!0):!1}function aa(e){let t=0,n,o;const i=()=>{t-=1,o&&t<=0&&(o.stop(),n=void 0,o=void 0)};return(...a)=>(t+=1,n||(o=r.effectScope(!0),n=o.run(()=>e(...a))),zS(i),n)}function jS(e){return"state"in e}var Ho=function(){};function WS(e){return"getSnapshot"in e?e.getSnapshot():jS(e)?e.state:void 0}function HS(e,t){t===void 0&&(t=WS);var n=r.isRef(e)?e:r.shallowRef(e),o=r.shallowRef(t(n.value)),i=function(a){n.value.send(a)};return r.watch(n,function(a,s,c){o.value=t(a);var l=a.subscribe({next:function(u){return o.value=u},error:Ho,complete:Ho}).unsubscribe;c(function(){return l()})},{immediate:!0}),{state:o,send:i}}const YS=e=>{var t,n,o;return{...(o=(n=(t=or(e))==null?void 0:t.formFields)==null?void 0:n.setupTotp)==null?void 0:o.QR}},kr=aa(()=>{const e=DS(),t=ki(e).start(),n=r.ref("configuring"),{state:o,send:i}=HS(t),a=()=>{n.value="authenticated"},s=()=>{n.value="unauthenticated"},c=Ya(t,(l,u)=>Qo(l,u,{onSignIn:a,onSignOut:s}));return H.getCurrentUser().then(()=>{n.value="authenticated"}).catch(()=>{n.value="unauthenticated"}),r.onScopeDispose(()=>{c()}),{authStatus:n,service:t,send:i,state:o}}),ee=aa(()=>{const{authStatus:e,state:t,send:n}=kr(),o=r.reactive({});return r.watchEffect(()=>{const i=Xa({send:n,state:t.value});for(const s of Object.keys(i))o[s]=i[s];const a=i.route==="setupTotp"?YS(t.value):null;o.QRFields=a,o.authStatus=e.value,o.send=n,o.state=t}),o});let KS=(e=21)=>{let t="",n=crypto.getRandomValues(new Uint8Array(e));for(;e--;){let o=n[e]&63;o<36?t+=o.toString(36):o<62?t+=(o-26).toString(36).toUpperCase():o<63?t+="_":t+="-"}return t};const Cn=r.defineComponent({__name:"base-input",emits:["update:modelValue"],setup(e,{emit:t}){const n=o=>{t("update:modelValue",o.target.value)};return(o,i)=>(r.openBlock(),r.createElementBlock("input",{onChange:i[0]||(i[0]=a=>n(a)),"data-amplify-input":""},null,32))}}),qS={},JS={"data-amplify-label":""};function ZS(e,t){return r.openBlock(),r.createElementBlock("label",JS,[r.renderSlot(e.$slots,"default")])}const bn=tn(qS,[["render",ZS]]),QS=["aria-label","aria-checked"],XS=r.createElementVNode("path",{d:"M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"},null,-1),eC=[XS],tC=r.createElementVNode("path",{d:"M0 0h24v24H0zm0 0h24v24H0zm0 0h24v24H0zm0 0h24v24H0z",fill:"none"},null,-1),nC=r.createElementVNode("path",{d:"M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2zm4.31-.78l3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"},null,-1),rC=[tC,nC],oC={inheritAttrs:!1},xr=r.defineComponent({...oC,__name:"password-control",props:{name:null,label:null,autocomplete:{default:"new-password"},hasError:{type:Boolean,default:!1},labelHidden:{type:Boolean},placeholder:null,required:{type:Boolean,default:!0},describedBy:null},setup(e){const t=e,n=T("Show password"),o=T("Hide password"),i=r.ref("password"),a=r.ref(n),s=Math.floor(Math.random()*999999),{name:c,label:l,autocomplete:u,hasError:d,labelHidden:m,placeholder:f,required:p}=r.toRefs(t),h=r.ref("");function v(){a.value=a.value===n?o:n,i.value=i.value==="password"?"text":"password"}const S=T((f==null?void 0:f.value)??l.value),g=T(l.value);return(w,y)=>{const _=bn,b=Cn,A=X;return r.openBlock(),r.createBlock(A,{class:r.normalizeClass([r.unref(Q).Flex,r.unref(Q).Field,r.unref(Q).TextField,r.unref(Q).PasswordField])},{default:r.withCtx(()=>[r.createVNode(_,{class:r.normalizeClass(["amplify-label",{"amplify-visually-hidden":r.unref(m)}]),for:"amplify-field-"+r.unref(s)},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(g)),1)]),_:1},8,["class","for"]),r.createVNode(A,{class:r.normalizeClass([r.unref(Q).Flex,r.unref(Q).FieldGroup])},{default:r.withCtx(()=>[r.createVNode(A,{class:r.normalizeClass(r.unref(Q).FieldGroupFieldWrapper)},{default:r.withCtx(()=>[r.createVNode(b,r.mergeProps(w.$attrs,{modelValue:h.value,"onUpdate:modelValue":y[0]||(y[0]=E=>h.value=E),class:[r.unref(Q).Input,r.unref(Q).FieldGroupControl],id:"amplify-field-"+r.unref(s),"data-amplify-password":"true",name:r.unref(c),autocomplete:r.unref(u),required:r.unref(p)??!0,placeholder:r.unref(S),type:i.value,"aria-invalid":r.unref(d),"aria-describedBy":e.describedBy,autocapitalize:"off"}),null,16,["modelValue","class","id","name","autocomplete","required","placeholder","type","aria-invalid","aria-describedBy"])]),_:1},8,["class"]),r.createVNode(A,{class:r.normalizeClass(r.unref(Q).FieldGroupOuterEnd)},{default:r.withCtx(()=>[r.createElementVNode("button",{"aria-label":a.value,"aria-checked":i.value!=="password",class:r.normalizeClass([r.unref(Q).Button,r.unref(Q).FieldGroupControl,r.unref(Q).FieldShowPassword]),"data-fullwidth":"false",type:"button",role:"switch",onClick:v},[i.value==="password"?(r.openBlock(),r.createElementBlock("svg",{key:0,xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24",class:r.normalizeClass(r.unref(Q).Icon)},eC,2)):(r.openBlock(),r.createElementBlock("svg",{key:1,xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24",class:r.normalizeClass(r.unref(Q).Icon)},rC,2))],10,QS)]),_:1},8,["class"])]),_:1},8,["class"])]),_:1},8,["class"])}}}),iC=["value","selected"],aC=r.defineComponent({__name:"base-select",props:{selectValue:{default:""},options:null},emits:["update:selectValue"],setup(e,{emit:t}){const n=e,{options:o,selectValue:i}=r.toRefs(n),a=s=>{t("update:selectValue",s.target.value)};return(s,c)=>(r.openBlock(),r.createElementBlock("select",{onChange:c[0]||(c[0]=l=>a(l))},[(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(r.unref(o),(l,u)=>(r.openBlock(),r.createElementBlock("option",{key:u,value:l,selected:l==r.unref(i)?!0:void 0},r.toDisplayString(l),9,iC))),128))],32))}}),sC=r.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24",class:"amplify-icon"},[r.createElementVNode("path",{d:"M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"})],-1),cC=r.defineComponent({__name:"alias-control",props:{label:{default:"Username"},name:{default:"username"},placeholder:{default:""},autocomplete:{default:""},labelHidden:{type:Boolean},required:{type:Boolean,default:!0},dialCode:null,dialCodeList:null,type:{default:"text"},hasError:{type:Boolean},describedBy:null},setup(e){const t=e,{label:n,name:o,placeholder:i,autocomplete:a,labelHidden:s,required:c,dialCode:l,dialCodeList:u}=r.toRefs(t),d=Math.floor(Math.random()*999999),m=Math.floor(Math.random()*999999);return(f,p)=>{const h=bn,v=aC,S=X,g=Cn;return r.openBlock(),r.createBlock(S,{class:"amplify-flex amplify-field amplify-textfield amplify-phonenumberfield"},{default:r.withCtx(()=>[r.createVNode(h,r.mergeProps({for:"amplify-field-"+r.unref(d),class:["amplify-label",{"amplify-visually-hidden":r.unref(s)}]},f.$attrs),{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(n)),1)]),_:1},16,["for","class"]),r.createVNode(S,{class:"amplify-flex amplify-field-group"},{default:r.withCtx(()=>[r.createVNode(S,{class:"amplify-field-group__outer-start"},{default:r.withCtx(()=>[e.type==="tel"?(r.openBlock(),r.createBlock(S,{key:0,class:"amplify-flex amplify-field amplify-selectfield amplify-countrycodeselect amplify-dialcodeselect amplify-authenticator__column"},{default:r.withCtx(()=>[r.createVNode(h,r.mergeProps({for:"amplify-field-"+r.unref(m),class:"amplify-label amplify-visually-hidden"},f.$attrs),{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString("Country Code"))]),_:1},16,["for"]),r.createVNode(S,{class:"amplify-select__wrapper"},{default:r.withCtx(()=>[r.createVNode(v,{class:"amplify-select amplify-field-group__control",id:"amplify-field-"+r.unref(m),autocomplete:"tel-country-code","aria-label":"country code",name:"country_code",options:r.unref(u),"select-value":r.unref(l)},null,8,["id","options","select-value"]),r.createVNode(S,{class:"amplify-flex amplify-select__icon"},{default:r.withCtx(()=>[sC]),_:1})]),_:1})]),_:1})):r.createCommentVNode("",!0)]),_:1}),r.createVNode(S,{class:"amplify-field-group__field-wrapper"},{default:r.withCtx(()=>[r.createVNode(g,{class:"amplify-input amplify-field-group__control",id:"amplify-field-"+r.unref(d),autocomplete:r.unref(a),name:r.unref(o),required:r.unref(c)??!0,type:e.type,placeholder:r.unref(i),"aria-invalid":e.hasError,"aria-describedBy":e.describedBy,autocapitalize:"off"},null,8,["id","autocomplete","name","required","type","placeholder","aria-invalid","aria-describedBy"])]),_:1})]),_:1})]),_:1})}}}),lC=["id"],sa=r.defineComponent({__name:"base-form-field",props:{name:{default:""},formField:{default:()=>({})}},setup(e){const t=e,{name:n,formField:o}=r.toRefs(t),{validationErrors:i}=r.toRefs(ee()),{type:a}=o.value,s=a==="password",c=KS(12),l=r.computed(()=>os(i.value[n.value])),u=r.computed(()=>{var m;return((m=l.value)==null?void 0:m.length)>0}),d=r.computed(()=>u.value?c:void 0);return(m,f)=>(r.openBlock(),r.createElementBlock(r.Fragment,null,[s?(r.openBlock(),r.createBlock(xr,{key:0,name:r.unref(n),label:r.unref(o).label,placeholder:r.unref(o).placeholder,required:r.unref(o).isRequired,"label-hidden":r.unref(o).labelHidden,autocomplete:r.unref(o).autocomplete,hasError:r.unref(u),describedBy:r.unref(d)},null,8,["name","label","placeholder","required","label-hidden","autocomplete","hasError","describedBy"])):(r.openBlock(),r.createBlock(cC,{key:1,name:r.unref(n),label:r.unref(o).label,placeholder:r.unref(o).placeholder,required:r.unref(o).isRequired,"label-hidden":r.unref(o).labelHidden,autocomplete:r.unref(o).autocomplete,"dial-code":r.unref(o).dialCode,"dial-code-list":r.unref(o).dialCodeList,type:r.unref(o).type,hasError:r.unref(u),describedBy:r.unref(d)},null,8,["name","label","placeholder","required","label-hidden","autocomplete","dial-code","dial-code-list","type","hasError","describedBy"])),r.unref(u)?(r.openBlock(),r.createElementBlock("div",{key:2,id:r.unref(d)},[(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(r.unref(l),(p,h)=>(r.openBlock(),r.createElementBlock("p",{key:h,role:"alert","data-variation":"error",class:"amplify-text amplify-text--error"},r.toDisplayString(r.unref(T)(p)),1))),128))],8,lC)):r.createCommentVNode("",!0)],64))}}),ve=r.defineComponent({__name:"base-form-fields",props:{route:null},setup(e){const t=e,{route:n}=r.toRefs(t),{state:o}=kr();let i=[];return r.onBeforeMount(()=>{i=uc(n.value,o.value)}),(a,s)=>(r.openBlock(!0),r.createElementBlock(r.Fragment,null,r.renderList(r.unref(i),([c,l])=>(r.openBlock(),r.createBlock(sa,{name:c,key:c,formField:l},null,8,["name","formField"]))),128))}}),Ot=r.defineComponent({__name:"federated-sign-in-button",props:{provider:null},setup(e){const t=e,{provider:n}=r.toRefs(t),{toFederatedSignIn:o}=ee(),i=()=>{o({provider:n.value})};return(a,s)=>{const c=ne;return r.openBlock(),r.createBlock(c,{class:"amplify-authenticator__federated-button",type:"button",onClick:i},{default:r.withCtx(()=>[r.renderSlot(a.$slots,"default")]),_:3})}}}),uC=r.createElementVNode("svg",{"aria-label":"Amazon icon",class:"amplify-icon",viewBox:"0 0 248 268"},[r.createElementVNode("path",{d:"M139.056521,147.024612 C133.548808,156.744524 124.782731,162.726926 115.087401,162.726926 C101.790721,162.726926 93.9937779,152.612964 93.9937779,137.68681 C93.9937779,108.224571 120.447551,102.879017 145.533369,102.879017 L145.533369,110.365976 C145.533369,123.831358 145.876354,135.063787 139.056521,147.024612 M207.206992,162.579655 C209.400505,165.692256 209.887066,169.437725 207.063416,171.770186 C199.996315,177.653081 187.429476,188.590967 180.513926,194.716661 L180.46208,194.621133 C178.176838,196.663031 174.862638,196.810303 172.27828,195.445057 C160.780281,185.9162 158.686473,181.494078 152.405048,172.403055 C133.405233,191.751331 119.909143,197.534719 95.309886,197.534719 C66.1281801,197.534719 43.4791563,179.599451 43.4791563,143.669212 C43.4791563,115.616003 58.6782107,96.5105248 80.4019706,87.1727225 C99.2063636,78.9096034 125.464714,77.4528107 145.533369,75.1641337 L145.533369,70.694248 C145.533369,62.4749122 146.167493,52.7510201 141.297893,45.6541312 C137.110277,39.2856386 129.018206,36.6586354 121.859376,36.6586354 C108.658413,36.6586354 96.9171331,43.4171982 94.0416364,57.4199213 C93.4593582,60.532522 91.1701278,63.5933787 88.003492,63.7406501 L54.4387473,60.1424518 C51.6150972,59.5095829 48.4484614,57.2248862 49.2740201,52.8982915 C56.9712583,12.2553679 93.7983558,0 126.732964,0 C143.587124,0 165.606011,4.47386604 178.902691,17.2148315 C195.760839,32.917146 194.149604,53.8694866 194.149604,76.6726704 L194.149604,130.542157 C194.149604,146.734049 200.87372,153.830938 207.206992,162.579655 Z M233.826346,208.038962 C230.467669,203.683255 211.550709,205.9821 203.056405,206.998432 C200.470662,207.321077 200.076227,205.042397 202.406981,203.404973 C217.475208,192.664928 242.201125,195.766353 245.081698,199.363845 C247.966255,202.981502 244.336653,228.071183 230.172839,240.049379 C228.001452,241.888455 225.929671,240.904388 226.89783,238.468418 C230.077218,230.430525 237.204944,212.418868 233.826346,208.038962 Z M126.768855,264 C74.0234043,264 42.0764048,241.955028 17.7852554,217.541992 C12.9733903,212.705982 6.71799208,206.295994 3.31151296,200.690918 C1.90227474,198.372135 5.59096074,195.021875 8.0442063,196.84375 C38.2390146,219.267578 82.1011654,239.538304 125.529506,239.538304 C154.819967,239.538304 191.046475,227.469543 220.66851,214.867659 C225.146771,212.966167 225.146771,219.180222 224.511585,221.060516 C224.183264,222.03242 209.514625,236.221149 189.247207,247.047411 C170.304273,257.166172 146.397132,264 126.768855,264 Z",fill:"#FF9900"})],-1),dC={class:"amplify-text"},fC=r.createElementVNode("svg",{"aria-label":"Apple icon",class:"amplify-icon",fill:"#000",preserveAspectRatio:"xMidYMid",stroke:"#000",strokeWidth:"0",viewBox:"0 0 1024 1024",xmlns:"http://www.w3.org/2000/svg"},[r.createElementVNode("path",{d:"M747.4 535.7c-.4-68.2 30.5-119.6 92.9-157.5-34.9-50-87.7-77.5-157.3-82.8-65.9-5.2-138 38.4-164.4 38.4-27.9 0-91.7-36.6-141.9-36.6C273.1 298.8 163 379.8 163 544.6c0 48.7 8.9 99 26.7 150.8 23.8 68.2 109.6 235.3 199.1 232.6 46.8-1.1 79.9-33.2 140.8-33.2 59.1 0 89.7 33.2 141.9 33.2 90.3-1.3 167.9-153.2 190.5-221.6-121.1-57.1-114.6-167.2-114.6-170.7zm-105.1-305c50.7-60.2 46.1-115 44.6-134.7-44.8 2.6-96.6 30.5-126.1 64.8-32.5 36.8-51.6 82.3-47.5 133.6 48.4 3.7 92.6-21.2 129-63.7z"})],-1),pC={class:"amplify-text"},mC=r.createElementVNode("svg",{"aria-label":"Facebook icon",class:"amplify-icon",viewBox:"0 0 279 538"},[r.createElementVNode("path",{d:"M82.3409742,538 L82.3409742,292.936652 L0,292.936652 L0,196.990154 L82.2410458,196.990154 L82.2410458,126.4295 C82.2410458,44.575144 132.205229,0 205.252865,0 C240.227794,0 270.306232,2.59855099 279,3.79788222 L279,89.2502322 L228.536175,89.2502322 C188.964542,89.2502322 181.270057,108.139699 181.270057,135.824262 L181.270057,196.89021 L276.202006,196.89021 L263.810888,292.836708 L181.16913,292.836708 L181.16913,538 L82.3409742,538 Z",fill:"#1877F2"})],-1),gC={class:"amplify-text"},hC=r.createElementVNode("svg",{"aria-label":"Google icon",class:"amplify-icon",viewBox:"0 0 256 262",xmlns:"http://www.w3.org/2000/svg",preserveAspectRatio:"xMidYMid"},[r.createElementVNode("path",{d:"M255.878 133.451c0-10.734-.871-18.567-2.756-26.69H130.55v48.448h71.947c-1.45 12.04-9.283 30.172-26.69 42.356l-.244 1.622 38.755 30.023 2.685.268c24.659-22.774 38.875-56.282 38.875-96.027",fill:"#4285F4"}),r.createElementVNode("path",{d:"M130.55 261.1c35.248 0 64.839-11.605 86.453-31.622l-41.196-31.913c-11.024 7.688-25.82 13.055-45.257 13.055-34.523 0-63.824-22.773-74.269-54.25l-1.531.13-40.298 31.187-.527 1.465C35.393 231.798 79.49 261.1 130.55 261.1",fill:"#34A853"}),r.createElementVNode("path",{d:"M56.281 156.37c-2.756-8.123-4.351-16.827-4.351-25.82 0-8.994 1.595-17.697 4.206-25.82l-.073-1.73L15.26 71.312l-1.335.635C5.077 89.644 0 109.517 0 130.55s5.077 40.905 13.925 58.602l42.356-32.782",fill:"#FBBC05"}),r.createElementVNode("path",{d:"M130.55 50.479c24.514 0 41.05 10.589 50.479 19.438l36.844-35.974C195.245 12.91 165.798 0 130.55 0 79.49 0 35.393 29.301 13.925 71.947l42.211 32.783c10.59-31.477 39.891-54.251 74.414-54.251",fill:"#EB4335"})],-1),yC={class:"amplify-text"},vC=["data-label"],An=r.defineComponent({__name:"federated-sign-in",setup(e){const t=ee(),{route:n,socialProviders:o}=t,i=o==null?void 0:o.includes("amazon"),a=o==null?void 0:o.includes("apple"),s=o==null?void 0:o.includes("facebook"),c=o==null?void 0:o.includes("google"),l=s||c||i||a,{getSignInWithFederationText:u,getOrText:d}=ce,m=r.computed(()=>Bn),f=r.computed(()=>u(n,"amazon")),p=r.computed(()=>u(n,"apple")),h=r.computed(()=>u(n,"facebook")),v=r.computed(()=>u(n,"google")),S=r.computed(()=>d());return(g,w)=>{const y=X;return r.unref(l)?(r.openBlock(),r.createBlock(y,{key:0,class:"amplify-flex amplify-authenticator__federated-buttons"},{default:r.withCtx(()=>[r.unref(i)?(r.openBlock(),r.createBlock(Ot,{key:0,provider:r.unref(m).Amazon},{default:r.withCtx(()=>[uC,r.createElementVNode("span",dC,r.toDisplayString(r.unref(f)),1)]),_:1},8,["provider"])):r.createCommentVNode("",!0),r.unref(a)?(r.openBlock(),r.createBlock(Ot,{key:1,provider:r.unref(m).Apple},{default:r.withCtx(()=>[fC,r.createElementVNode("span",pC,r.toDisplayString(r.unref(p)),1)]),_:1},8,["provider"])):r.createCommentVNode("",!0),r.unref(s)?(r.openBlock(),r.createBlock(Ot,{key:2,provider:r.unref(m).Facebook},{default:r.withCtx(()=>[mC,r.createElementVNode("span",gC,r.toDisplayString(r.unref(h)),1)]),_:1},8,["provider"])):r.createCommentVNode("",!0),r.unref(c)?(r.openBlock(),r.createBlock(Ot,{key:3,provider:r.unref(m).Google},{default:r.withCtx(()=>[hC,r.createElementVNode("span",yC,r.toDisplayString(r.unref(v)),1)]),_:1},8,["provider"])):r.createCommentVNode("",!0),r.createElementVNode("hr",{class:"amplify-divider amplify-divider--horizontal amplify-divider--small","aria-orientation":"horizontal","data-label":r.unref(S)},null,8,vC)]),_:1})):r.createCommentVNode("",!0)}}}),wC=r.createElementVNode("legend",{class:"amplify-visually-hidden"},"Sign in",-1),_C={"data-amplify-footer":""},Ur=r.defineComponent({__name:"sign-in",setup(e){const t=ee(),{submitForm:n,updateForm:o,toForgotPassword:i}=t,{error:a,isPending:s}=r.toRefs(t),{getForgotPasswordText:c,getSignInText:l,getSigningInText:u}=ce,d=r.computed(()=>c()),m=r.computed(()=>l()),f=r.computed(()=>u()),p=S=>{const{name:g,value:w}=S.target;o({name:g,value:w})},h=S=>{n(me(S))},v=()=>{i()};return(S,g)=>{const w=ye,y=he,_=ne,b=X,A=pe,E=fe;return r.renderSlot(S.$slots,"signInSlotI",r.normalizeProps(r.guardReactiveProps(S.$attrs)),()=>[r.renderSlot(S.$slots,"header"),r.createVNode(b,r.normalizeProps(r.guardReactiveProps(S.$attrs)),{default:r.withCtx(()=>[r.createVNode(A,{"data-amplify-authenticator-signin":"",onInput:p,onSubmit:r.withModifiers(h,["prevent"]),method:"post"},{formt:r.withCtx(({slotData:I})=>[r.renderSlot(S.$slots,"form",{info:I,onSignInSubmit:h,onInput:p,onForgotPasswordClicked:v})]),default:r.withCtx(()=>[r.createVNode(An),r.createVNode(b,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.createVNode(w,{disabled:r.unref(s),class:"amplify-flex amplify-authenticator__column"},{fieldSetI:r.withCtx(({slotData:I})=>[r.renderSlot(S.$slots,"signin-fields",{info:I})]),default:r.withCtx(()=>[wC,r.createVNode(ve,{route:"signIn"})]),_:3},8,["disabled"]),r.unref(a)?(r.openBlock(),r.createBlock(y,{key:0},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(T)(r.unref(a))),1)]),_:1})):r.createCommentVNode("",!0),r.createVNode(_,{disabled:r.unref(s),class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!0,loading:!1,variation:"primary"},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(s)?r.unref(f):r.unref(m)),1)]),_:1},8,["disabled"])]),_:3})]),_:3},8,["onSubmit"])]),_:3},16),r.createVNode(E,null,{default:r.withCtx(()=>[r.renderSlot(S.$slots,"footer",{},()=>[r.createElementVNode("div",_C,[r.createVNode(_,{onClick:v,class:"amplify-field-group__control amplify-authenticator__font",variation:"link",fullwidth:!0,size:"small",style:{"font-weight":"normal"},type:"button"},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(d)),1)]),_:1})])])]),_:3})])}}}),$r=r.defineComponent({__name:"authenticator-sign-up-form-fields",setup(e){return(t,n)=>(r.openBlock(),r.createBlock(ve,{route:"signUp"}))}}),Rr=r.defineComponent({__name:"sign-up",setup(e){const t=ee(),{submitForm:n,updateBlur:o,updateForm:i}=t,{error:a,hasValidationErrors:s,isPending:c}=r.toRefs(t),{getCreateAccountText:l}=ce,u=r.computed(()=>l()),d=p=>{const{checked:h,name:v,type:S,value:g}=p.target;i({name:v,value:S==="checkbox"&&!h?void 0:g})};function m(p){const{name:h}=p.target;o({name:h})}const f=p=>{n(me(p))};return(p,h)=>{const v=ye,S=he,g=ne,w=X,y=pe,_=fe;return r.renderSlot(p.$slots,"signUpSlotI",r.normalizeProps(r.guardReactiveProps(p.$attrs)),()=>[r.renderSlot(p.$slots,"header"),r.createVNode(w,r.normalizeProps(r.guardReactiveProps(p.$attrs)),{default:r.withCtx(()=>[r.createVNode(y,{onInput:d,onBlurCapture:m,onSubmit:r.withModifiers(f,["prevent"])},{default:r.withCtx(()=>[r.createVNode(An),r.createVNode(w,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.createVNode(v,{class:"amplify-flex amplify-authenticator__column",disabled:r.unref(c)},{fieldSetI:r.withCtx(({slotData:b})=>[r.renderSlot(p.$slots,"signup-fields",{info:b})]),default:r.withCtx(()=>[r.createVNode($r)]),_:3},8,["disabled"]),r.unref(a)?(r.openBlock(),r.createBlock(S,{key:0},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(T)(r.unref(a))),1)]),_:1})):r.createCommentVNode("",!0),r.createVNode(g,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!0,loading:!1,variation:"primary",style:{"border-radius":"0px","font-weight":"normal"},disabled:r.unref(c)||r.unref(s)},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(u)),1)]),_:1},8,["disabled"])]),_:3})]),_:3},8,["onSubmit"])]),_:3},16),r.createVNode(_,null,{default:r.withCtx(()=>[r.renderSlot(p.$slots,"footer")]),_:3})])}}}),SC={};function CC(e,t){const n=X;return r.openBlock(),r.createBlock(n,{tabindex:"0","aria-orientation":"horizontal","data-orientation":"horizontal",class:"amplify-authenticator__tabs amplify-tabs"},{default:r.withCtx(()=>[r.createVNode(n,{class:"amplify-tabs__list amplify-tabs__list--top amplify-tabs__list--equal amplify-authenticator__tabs-wrapper",role:"tablist"},{default:r.withCtx(()=>[r.renderSlot(e.$slots,"default")]),_:3})]),_:3})}const bC=tn(SC,[["render",CC]]),AC=["tabindex","aria-selected","id","aria-controls"],EC=r.defineComponent({__name:"base-two-tab-item",props:{label:null,id:null,active:{type:Boolean,default:!1}},setup(e){const t=e,{active:n,id:o,label:i}=r.toRefs(t);return(a,s)=>(r.openBlock(),r.createElementBlock("button",{tabindex:r.unref(n)?0:-1,"aria-selected":r.unref(n)?"true":"false",class:r.normalizeClass([{"amplify-tabs__item--active":r.unref(n)},"amplify-tabs__item"]),id:`${r.unref(o)}-tab`,"aria-controls":`${r.unref(o)}-panel`,role:"tab"},r.toDisplayString(r.unref(i)),11,AC))}}),IC="4.2.6",TC={};function NC(e,t){return r.renderSlot(e.$slots,"textI",r.normalizeProps(r.guardReactiveProps(e.$attrs)),()=>[r.createElementVNode("span",r.mergeProps(e.$attrs,{"data-amplify-text":""}),[r.renderSlot(e.$slots,"default")],16)])}const ca=tn(TC,[["render",NC]]),xe=r.defineComponent({props:{level:{type:Number,default:1}},inheritAttrs:!1,setup(e,{slots:t,attrs:n}){var s,c;const o=t.default?t.default():[],i=t.headingI?t.headingI():[],a=`${n.class||""} amplify-heading--${e.level}`;if(((c=(s=i[0])==null?void 0:s.children)==null?void 0:c.length)===0)i[0].children=[r.h(`h${e.level}`,{...n,class:a},[o])];else return()=>r.h(`h${e.level}`,{"data-amplify-heading":"",...n,class:a},[i[0]?r.h(i[0].children[0]):r.h(o[0])]);return()=>i}}),Or=r.defineComponent({__name:"confirm-sign-up",setup(e){const t=ee(),{codeDeliveryDetails:n,error:o,isPending:i}=r.toRefs(t),{resendCode:a,submitForm:s,updateForm:c}=t,{getDeliveryMethodText:l,getDeliveryMessageText:u,getResendCodeText:d,getConfirmText:m}=ce,f=r.computed(()=>l(n.value)),p=r.computed(()=>d()),h=r.computed(()=>m()),v=r.computed(()=>u(n.value)),S=_=>{const{name:b,value:A}=_.target;c({name:b,value:A})},g=_=>{w(_)},w=_=>{s(me(_))},y=()=>{a()};return(_,b)=>{const A=xe,E=ca,I=ye,N=he,P=ne,k=fe,x=X,$=pe;return r.renderSlot(_.$slots,"confirmSignUpSlotI",r.normalizeProps(r.guardReactiveProps(_.$attrs)),()=>[r.createVNode(x,r.normalizeProps(r.guardReactiveProps(_.$attrs)),{default:r.withCtx(()=>[r.createVNode($,{onInput:S,onSubmit:r.withModifiers(g,["prevent"])},{default:r.withCtx(()=>[r.createVNode(x,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.renderSlot(_.$slots,"header",{},()=>[r.createVNode(A,{class:"amplify-heading amplify-authenticator__heading",level:3},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(f)),1)]),_:1})]),r.createVNode(E,{class:"amplify-authenticator__subtitle"},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(v)),1)]),_:1}),r.createVNode(I,{class:"amplify-flex amplify-authenticator__column",disabled:r.unref(i)},{default:r.withCtx(()=>[r.createVNode(ve,{route:"confirmSignUp"})]),_:1},8,["disabled"]),r.createVNode(k,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.unref(o)?(r.openBlock(),r.createBlock(N,{key:0},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(T)(r.unref(o))),1)]),_:1})):r.createCommentVNode("",!0),r.createVNode(P,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!1,loading:!1,variation:"primary",type:"submit",disabled:r.unref(i)},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(h)),1)]),_:1},8,["disabled"]),r.createVNode(P,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!1,variation:"default",style:{"font-weight":"normal"},type:"button",onClick:r.withModifiers(y,["prevent"])},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(p)),1)]),_:1},8,["onClick"]),r.renderSlot(_.$slots,"footer")]),_:3})]),_:3})]),_:3},8,["onSubmit"])]),_:3},16)])}}}),Dr=r.defineComponent({__name:"confirm-sign-in",setup(e){const t=ee(),{submitForm:n,toSignIn:o,updateForm:i}=t,{error:a,isPending:s,challengeName:c}=r.toRefs(t),l=r.computed(()=>c.value),{getBackToSignInText:u,getConfirmText:d,getChallengeText:m}=ce,f=r.computed(()=>m(l.value)),p=r.computed(()=>u()),h=r.computed(()=>d()),v=w=>{const{name:y,value:_}=w.target;i({name:y,value:_})},S=w=>{n(me(w))},g=()=>{o()};return(w,y)=>{const _=xe,b=X,A=he,E=ne,I=fe,N=ye,P=pe;return r.renderSlot(w.$slots,"confirmSignInSlotI",r.normalizeProps(r.guardReactiveProps(w.$attrs)),()=>[r.createVNode(b,r.normalizeProps(r.guardReactiveProps(w.$attrs)),{default:r.withCtx(()=>[r.createVNode(P,{"data-amplify-authenticator-confirmsignin":"",onInput:v,onSubmit:r.withModifiers(S,["prevent"])},{default:r.withCtx(()=>[r.createVNode(N,{class:"amplify-flex amplify-authenticator__column",disabled:r.unref(s)},{default:r.withCtx(()=>[r.renderSlot(w.$slots,"header",{},()=>[r.createVNode(_,{level:3,class:"amplify-heading"},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(f)),1)]),_:1})]),r.createVNode(b,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.createVNode(ve,{route:"confirmSignIn"})]),_:1}),r.createVNode(I,{class:"amplify-flex amplify-authenticator__column"},{default:r.withCtx(()=>[r.unref(a)?(r.openBlock(),r.createBlock(A,{key:0},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(T)(r.unref(a))),1)]),_:1})):r.createCommentVNode("",!0),r.createVNode(E,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!1,loading:!1,variation:"primary",style:{"font-weight":"normal"},disabled:r.unref(s)},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(h)),1)]),_:1},8,["disabled"]),r.createVNode(E,{class:"amplify-field-group__control amplify-authenticator__font",fullwidth:!1,size:"small",variation:"link",style:{"font-weight":"normal"},type:"button",onClick:r.withModifiers(g,["prevent"])},{default:r.withCtx(()=>[r.createTextVNode(r.toDisplayString(r.unref(p)),1)]),_:1},8,["onClick"]),r.renderSlot(w.$slots,"footer")]),_:3})]),_:3},8,["disabled"])]),_:3},8,["onSubmit"])]),_:3},16)])}}});var It={},PC=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then},la={},ie={};let Fr;const kC=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];ie.getSymbolSize=function(t){if(!t)throw new Error('"version" cannot be null or undefined');if(t<1||t>40)throw new Error('"version" should be in range from 1 to 40');return t*4+17};ie.getSymbolTotalCodewords=function(t){return kC[t]};ie.getBCHDigit=function(e){let t=0;for(;e!==0;)t++,e>>>=1;return t};ie.setToSJISFunction=function(t){if(typeof t!="function")throw new Error('"toSJISFunc" is not a valid function.');Fr=t};ie.isKanjiModeEnabled=function(){return typeof Fr<"u"};ie.toSJIS=function(t){return Fr(t)};var En={};(function(e){e.L={bit:1},e.M={bit:0},e.Q={bit:3},e.H={bit:2};function t(n){if(typeof n!="string")throw new Error("Param is not a string");switch(n.toLowerCase()){case"l":case"low":return e.L;case"m":case"medium":return e.M;case"q":case"quartile":return e.Q;case"h":case"high":return e.H;default:throw new Error("Unknown EC Level: "+n)}}e.isValid=function(o){return o&&typeof o.bit<"u"&&o.bit>=0&&o.bit<4},e.from=function(o,i){if(e.isValid(o))return o;try{return t(o)}catch{return i}}})(En);function ua(){this.buffer=[],this.length=0}ua.prototype={get:function(e){const t=Math.floor(e/8);return(this.buffer[t]>>>7-e%8&1)===1},put:function(e,t){for(let n=0;n<t;n++)this.putBit((e>>>t-n-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(e){const t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}};var xC=ua;function Tt(e){if(!e||e<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=e,this.data=new Uint8Array(e*e),this.reservedBit=new Uint8Array(e*e)}Tt.prototype.set=function(e,t,n,o){const i=e*this.size+t;this.data[i]=n,o&&(this.reservedBit[i]=!0)};Tt.prototype.get=function(e,t){return this.data[e*this.size+t]};Tt.prototype.xor=function(e,t,n){this.data[e*this.size+t]^=n};Tt.prototype.isReserved=function(e,t){return this.reservedBit[e*this.size+t]};var UC=Tt,da={};(function(e){const t=ie.getSymbolSize;e.getRowColCoords=function(o){if(o===1)return[];const i=Math.floor(o/7)+2,a=t(o),s=a===145?26:Math.ceil((a-13)/(2*i-2))*2,c=[a-7];for(let l=1;l<i-1;l++)c[l]=c[l-1]-s;return c.push(6),c.reverse()},e.getPositions=function(o){const i=[],a=e.getRowColCoords(o),s=a.length;for(let c=0;c<s;c++)for(let l=0;l<s;l++)c===0&&l===0||c===0&&l===s-1||c===s-1&&l===0||i.push([a[c],a[l]]);return i}})(da);var fa={};const $C=ie.getSymbolSize,Yo=7;fa.getPositions=function(t){const n=$C(t);return[[0,0],[n-Yo,0],[0,n-Yo]]};var pa={};(function(e){e.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};const t={N1:3,N2:3,N3:40,N4:10};e.isValid=function(i){return i!=null&&i!==""&&!isNaN(i)&&i>=0&&i<=7},e.from=function(i){return e.isValid(i)?parseInt(i,10):void 0},e.getPenaltyN1=function(i){const a=i.size;let s=0,c=0,l=0,u=null,d=null;for(let m=0;m<a;m++){c=l=0,u=d=null;for(let f=0;f<a;f++){let p=i.get(m,f);p===u?c++:(c>=5&&(s+=t.N1+(c-5)),u=p,c=1),p=i.get(f,m),p===d?l++:(l>=5&&(s+=t.N1+(l-5)),d=p,l=1)}c>=5&&(s+=t.N1+(c-5)),l>=5&&(s+=t.N1+(l-5))}return s},e.getPenaltyN2=function(i){const a=i.size;let s=0;for(let c=0;c<a-1;c++)for(let l=0;l<a-1;l++){const u=i.get(c,l)+i.get(c,l+1)+i.get(c+1,l)+i.get(c+1,l+1);(u===4||u===0)&&s++}return s*t.N2},e.getPenaltyN3=function(i){const a=i.size;let s=0,c=0,l=0;for(let u=0;u<a;u++){c=l=0;for(let d=0;d<a;d++)c=c<<1&2047|i.get(u,d),d>=10&&(c===1488||c===93)&&s++,l=l<<1&2047|i.get(d,u),d>=10&&(l===1488||l===93)&&s++}return s*t.N3},e.getPenaltyN4=function(i){let a=0;const s=i.data.length;for(let l=0;l<s;l++)a+=i.data[l];return Math.abs(Math.ceil(a*100/s/5)-10)*t.N4};function n(o,i,a){switch(o){case e.Patterns.PATTERN000:return(i+a)%2===0;case e.Patterns.PATTERN001:return i%2===0;case e.Patterns.PATTERN010:return a%3===0;case e.Patterns.PATTERN011:return(i+a)%3===0;case e.Patterns.PATTERN100:return(Math.floor(i/2)+Math.floor(a/3))%2===0;case e.Patterns.PATTERN101:return i*a%2+i*a%3===0;case e.Patterns.PATTERN110:return(i*a%2+i*a%3)%2===0;case e.Patterns.PATTERN111:return(i*a%3+(i+a)%2)%2===0;default:throw new Error("bad maskPattern:"+o)}}e.applyMask=function(i,a){const s=a.size;for(let c=0;c<s;c++)for(let l=0;l<s;l++)a.isReserved(l,c)||a.xor(l,c,n(i,l,c))},e.getBestMask=function(i,a){const s=Object.keys(e.Patterns).length;let c=0,l=1/0;for(let u=0;u<s;u++){a(u),e.applyMask(u,i);const d=e.getPenaltyN1(i)+e.getPenaltyN2(i)+e.getPenaltyN3(i)+e.getPenaltyN4(i);e.applyMask(u,i),d<l&&(l=d,c=u)}return c}})(pa);var In={};const Te=En,Dt=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],Ft=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];In.getBlocksCount=function(t,n){switch(n){case Te.L:return Dt[(t-1)*4+0];case Te.M:return Dt[(t-1)*4+1];case Te.Q:return Dt[(t-1)*4+2];case Te.H:return Dt[(t-1)*4+3];default:return}};In.getTotalCodewordsCount=function(t,n){switch(n){case Te.L:return Ft[(t-1)*4+0];case Te.M:return Ft[(t-1)*4+1];case Te.Q:return Ft[(t-1)*4+2];case Te.H:return Ft[(t-1)*4+3];default:return}};var ma={},Tn={};const ht=new Uint8Array(512),Xt=new Uint8Array(256);(function(){let t=1;for(let n=0;n<255;n++)ht[n]=t,Xt[t]=n,t<<=1,t&256&&(t^=285);for(let n=255;n<512;n++)ht[n]=ht[n-255]})();Tn.log=function(t){if(t<1)throw new Error("log("+t+")");return Xt[t]};Tn.exp=function(t){return ht[t]};Tn.mul=function(t,n){return t===0||n===0?0:ht[Xt[t]+Xt[n]]};(function(e){const t=Tn;e.mul=function(o,i){const a=new Uint8Array(o.length+i.length-1);for(let s=0;s<o.length;s++)for(let c=0;c<i.length;c++)a[s+c]^=t.mul(o[s],i[c]);return a},e.mod=function(o,i){let a=new Uint8Array(o);for(;a.length-i.length>=0;){const s=a[0];for(let l=0;l<i.length;l++)a[l]^=t.mul(i[l],s);let c=0;for(;c<a.length&&a[c]===0;)c++;a=a.slice(c)}return a},e.generateECPolynomial=function(o){let i=new Uint8Array([1]);for(let a=0;a<o;a++)i=e.mul(i,new Uint8Array([1,t.exp(a)]));return i}})(ma);const ga=ma;function Mr(e){this.genPoly=void 0,this.degree=e,this.degree&&this.initialize(this.degree)}Mr.prototype.initialize=function(t){this.degree=t,this.genPoly=ga.generateECPolynomial(this.degree)};Mr.prototype.encode=function(t){if(!this.genPoly)throw new Error("Encoder not initialized");const n=new Uint8Array(t.length+this.degree);n.set(t);const o=ga.mod(n,this.genPoly),i=this.degree-o.length;if(i>0){const a=new Uint8Array(this.degree);return a.set(o,i),a}return o};var RC=Mr,ha={},Ue={},Br={};Br.isValid=function(t){return!isNaN(t)&&t>=1&&t<=40};var we={};const ya="[0-9]+",OC="[A-Z $%*+\\-./:]+";let St="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";St=St.replace(/u/g,"\\u");const DC="(?:(?![A-Z0-9 $%*+\\-./:]|"+St+`)(?:.|[\r
|
|
21
21
|
]))+`;we.KANJI=new RegExp(St,"g");we.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g");we.BYTE=new RegExp(DC,"g");we.NUMERIC=new RegExp(ya,"g");we.ALPHANUMERIC=new RegExp(OC,"g");const FC=new RegExp("^"+St+"$"),MC=new RegExp("^"+ya+"$"),BC=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");we.testKanji=function(t){return FC.test(t)};we.testNumeric=function(t){return MC.test(t)};we.testAlphanumeric=function(t){return BC.test(t)};(function(e){const t=Br,n=we;e.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},e.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},e.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},e.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},e.MIXED={bit:-1},e.getCharCountIndicator=function(a,s){if(!a.ccBits)throw new Error("Invalid mode: "+a);if(!t.isValid(s))throw new Error("Invalid version: "+s);return s>=1&&s<10?a.ccBits[0]:s<27?a.ccBits[1]:a.ccBits[2]},e.getBestModeForData=function(a){return n.testNumeric(a)?e.NUMERIC:n.testAlphanumeric(a)?e.ALPHANUMERIC:n.testKanji(a)?e.KANJI:e.BYTE},e.toString=function(a){if(a&&a.id)return a.id;throw new Error("Invalid mode")},e.isValid=function(a){return a&&a.bit&&a.ccBits};function o(i){if(typeof i!="string")throw new Error("Param is not a string");switch(i.toLowerCase()){case"numeric":return e.NUMERIC;case"alphanumeric":return e.ALPHANUMERIC;case"kanji":return e.KANJI;case"byte":return e.BYTE;default:throw new Error("Unknown mode: "+i)}}e.from=function(a,s){if(e.isValid(a))return a;try{return o(a)}catch{return s}}})(Ue);(function(e){const t=ie,n=In,o=En,i=Ue,a=Br,s=7973,c=t.getBCHDigit(s);function l(f,p,h){for(let v=1;v<=40;v++)if(p<=e.getCapacity(v,h,f))return v}function u(f,p){return i.getCharCountIndicator(f,p)+4}function d(f,p){let h=0;return f.forEach(function(v){const S=u(v.mode,p);h+=S+v.getBitsLength()}),h}function m(f,p){for(let h=1;h<=40;h++)if(d(f,h)<=e.getCapacity(h,p,i.MIXED))return h}e.from=function(p,h){return a.isValid(p)?parseInt(p,10):h},e.getCapacity=function(p,h,v){if(!a.isValid(p))throw new Error("Invalid QR Code version");typeof v>"u"&&(v=i.BYTE);const S=t.getSymbolTotalCodewords(p),g=n.getTotalCodewordsCount(p,h),w=(S-g)*8;if(v===i.MIXED)return w;const y=w-u(v,p);switch(v){case i.NUMERIC:return Math.floor(y/10*3);case i.ALPHANUMERIC:return Math.floor(y/11*2);case i.KANJI:return Math.floor(y/13);case i.BYTE:default:return Math.floor(y/8)}},e.getBestVersionForData=function(p,h){let v;const S=o.from(h,o.M);if(Array.isArray(p)){if(p.length>1)return m(p,S);if(p.length===0)return 1;v=p[0]}else v=p;return l(v.mode,v.getLength(),S)},e.getEncodedBits=function(p){if(!a.isValid(p)||p<7)throw new Error("Invalid QR Code version");let h=p<<12;for(;t.getBCHDigit(h)-c>=0;)h^=s<<t.getBCHDigit(h)-c;return p<<12|h}})(ha);var va={};const Qn=ie,wa=1335,VC=21522,Ko=Qn.getBCHDigit(wa);va.getEncodedBits=function(t,n){const o=t.bit<<3|n;let i=o<<10;for(;Qn.getBCHDigit(i)-Ko>=0;)i^=wa<<Qn.getBCHDigit(i)-Ko;return(o<<10|i)^VC};var _a={};const LC=Ue;function We(e){this.mode=LC.NUMERIC,this.data=e.toString()}We.getBitsLength=function(t){return 10*Math.floor(t/3)+(t%3?t%3*3+1:0)};We.prototype.getLength=function(){return this.data.length};We.prototype.getBitsLength=function(){return We.getBitsLength(this.data.length)};We.prototype.write=function(t){let n,o,i;for(n=0;n+3<=this.data.length;n+=3)o=this.data.substr(n,3),i=parseInt(o,10),t.put(i,10);const a=this.data.length-n;a>0&&(o=this.data.substr(n),i=parseInt(o,10),t.put(i,a*3+1))};var GC=We;const zC=Ue,Rn=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function He(e){this.mode=zC.ALPHANUMERIC,this.data=e}He.getBitsLength=function(t){return 11*Math.floor(t/2)+6*(t%2)};He.prototype.getLength=function(){return this.data.length};He.prototype.getBitsLength=function(){return He.getBitsLength(this.data.length)};He.prototype.write=function(t){let n;for(n=0;n+2<=this.data.length;n+=2){let o=Rn.indexOf(this.data[n])*45;o+=Rn.indexOf(this.data[n+1]),t.put(o,11)}this.data.length%2&&t.put(Rn.indexOf(this.data[n]),6)};var jC=He,WC=function(t){for(var n=[],o=t.length,i=0;i<o;i++){var a=t.charCodeAt(i);if(a>=55296&&a<=56319&&o>i+1){var s=t.charCodeAt(i+1);s>=56320&&s<=57343&&(a=(a-55296)*1024+s-56320+65536,i+=1)}if(a<128){n.push(a);continue}if(a<2048){n.push(a>>6|192),n.push(a&63|128);continue}if(a<55296||a>=57344&&a<65536){n.push(a>>12|224),n.push(a>>6&63|128),n.push(a&63|128);continue}if(a>=65536&&a<=1114111){n.push(a>>18|240),n.push(a>>12&63|128),n.push(a>>6&63|128),n.push(a&63|128);continue}n.push(239,191,189)}return new Uint8Array(n).buffer};const HC=WC,YC=Ue;function Ye(e){this.mode=YC.BYTE,this.data=new Uint8Array(HC(e))}Ye.getBitsLength=function(t){return t*8};Ye.prototype.getLength=function(){return this.data.length};Ye.prototype.getBitsLength=function(){return Ye.getBitsLength(this.data.length)};Ye.prototype.write=function(e){for(let t=0,n=this.data.length;t<n;t++)e.put(this.data[t],8)};var KC=Ye;const qC=Ue,JC=ie;function Ke(e){this.mode=qC.KANJI,this.data=e}Ke.getBitsLength=function(t){return t*13};Ke.prototype.getLength=function(){return this.data.length};Ke.prototype.getBitsLength=function(){return Ke.getBitsLength(this.data.length)};Ke.prototype.write=function(e){let t;for(t=0;t<this.data.length;t++){let n=JC.toSJIS(this.data[t]);if(n>=33088&&n<=40956)n-=33088;else if(n>=57408&&n<=60351)n-=49472;else throw new Error("Invalid SJIS character: "+this.data[t]+`
|
|
22
22
|
Make sure your charset is UTF-8`);n=(n>>>8&255)*192+(n&255),e.put(n,13)}};var ZC=Ke,Sa={exports:{}};(function(e){var t={single_source_shortest_paths:function(n,o,i){var a={},s={};s[o]=0;var c=t.PriorityQueue.make();c.push(o,0);for(var l,u,d,m,f,p,h,v,S;!c.empty();){l=c.pop(),u=l.value,m=l.cost,f=n[u]||{};for(d in f)f.hasOwnProperty(d)&&(p=f[d],h=m+p,v=s[d],S=typeof s[d]>"u",(S||v>h)&&(s[d]=h,c.push(d,h),a[d]=u))}if(typeof i<"u"&&typeof s[i]>"u"){var g=["Could not find a path from ",o," to ",i,"."].join("");throw new Error(g)}return a},extract_shortest_path_from_predecessor_list:function(n,o){for(var i=[],a=o;a;)i.push(a),n[a],a=n[a];return i.reverse(),i},find_path:function(n,o,i){var a=t.single_source_shortest_paths(n,o,i);return t.extract_shortest_path_from_predecessor_list(a,i)},PriorityQueue:{make:function(n){var o=t.PriorityQueue,i={},a;n=n||{};for(a in o)o.hasOwnProperty(a)&&(i[a]=o[a]);return i.queue=[],i.sorter=n.sorter||o.default_sorter,i},default_sorter:function(n,o){return n.cost-o.cost},push:function(n,o){var i={value:n,cost:o};this.queue.push(i),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return this.queue.length===0}}};e.exports=t})(Sa);var QC=Sa.exports;(function(e){const t=Ue,n=GC,o=jC,i=KC,a=ZC,s=we,c=ie,l=QC;function u(g){return unescape(encodeURIComponent(g)).length}function d(g,w,y){const _=[];let b;for(;(b=g.exec(y))!==null;)_.push({data:b[0],index:b.index,mode:w,length:b[0].length});return _}function m(g){const w=d(s.NUMERIC,t.NUMERIC,g),y=d(s.ALPHANUMERIC,t.ALPHANUMERIC,g);let _,b;return c.isKanjiModeEnabled()?(_=d(s.BYTE,t.BYTE,g),b=d(s.KANJI,t.KANJI,g)):(_=d(s.BYTE_KANJI,t.BYTE,g),b=[]),w.concat(y,_,b).sort(function(E,I){return E.index-I.index}).map(function(E){return{data:E.data,mode:E.mode,length:E.length}})}function f(g,w){switch(w){case t.NUMERIC:return n.getBitsLength(g);case t.ALPHANUMERIC:return o.getBitsLength(g);case t.KANJI:return a.getBitsLength(g);case t.BYTE:return i.getBitsLength(g)}}function p(g){return g.reduce(function(w,y){const _=w.length-1>=0?w[w.length-1]:null;return _&&_.mode===y.mode?(w[w.length-1].data+=y.data,w):(w.push(y),w)},[])}function h(g){const w=[];for(let y=0;y<g.length;y++){const _=g[y];switch(_.mode){case t.NUMERIC:w.push([_,{data:_.data,mode:t.ALPHANUMERIC,length:_.length},{data:_.data,mode:t.BYTE,length:_.length}]);break;case t.ALPHANUMERIC:w.push([_,{data:_.data,mode:t.BYTE,length:_.length}]);break;case t.KANJI:w.push([_,{data:_.data,mode:t.BYTE,length:u(_.data)}]);break;case t.BYTE:w.push([{data:_.data,mode:t.BYTE,length:u(_.data)}])}}return w}function v(g,w){const y={},_={start:{}};let b=["start"];for(let A=0;A<g.length;A++){const E=g[A],I=[];for(let N=0;N<E.length;N++){const P=E[N],k=""+A+N;I.push(k),y[k]={node:P,lastCount:0},_[k]={};for(let x=0;x<b.length;x++){const $=b[x];y[$]&&y[$].node.mode===P.mode?(_[$][k]=f(y[$].lastCount+P.length,P.mode)-f(y[$].lastCount,P.mode),y[$].lastCount+=P.length):(y[$]&&(y[$].lastCount=P.length),_[$][k]=f(P.length,P.mode)+4+t.getCharCountIndicator(P.mode,w))}}b=I}for(let A=0;A<b.length;A++)_[b[A]].end=0;return{map:_,table:y}}function S(g,w){let y;const _=t.getBestModeForData(g);if(y=t.from(w,_),y!==t.BYTE&&y.bit<_.bit)throw new Error('"'+g+'" cannot be encoded with mode '+t.toString(y)+`.
|
|
23
23
|
Suggested mode is: `+t.toString(_));switch(y===t.KANJI&&!c.isKanjiModeEnabled()&&(y=t.BYTE),y){case t.NUMERIC:return new n(g);case t.ALPHANUMERIC:return new o(g);case t.KANJI:return new a(g);case t.BYTE:return new i(g)}}e.fromArray=function(w){return w.reduce(function(y,_){return typeof _=="string"?y.push(S(_,null)):_.data&&y.push(S(_.data,_.mode)),y},[])},e.fromString=function(w,y){const _=m(w,c.isKanjiModeEnabled()),b=h(_),A=v(b,y),E=l.find_path(A.map,"start","end"),I=[];for(let N=1;N<E.length-1;N++)I.push(A.table[E[N]].node);return e.fromArray(p(I))},e.rawSplit=function(w){return e.fromArray(m(w,c.isKanjiModeEnabled()))}})(_a);const Nn=ie,On=En,XC=xC,eb=UC,tb=da,nb=fa,Xn=pa,er=In,rb=RC,en=ha,ob=va,ib=Ue,Dn=_a;function ab(e,t){const n=e.size,o=nb.getPositions(t);for(let i=0;i<o.length;i++){const a=o[i][0],s=o[i][1];for(let c=-1;c<=7;c++)if(!(a+c<=-1||n<=a+c))for(let l=-1;l<=7;l++)s+l<=-1||n<=s+l||(c>=0&&c<=6&&(l===0||l===6)||l>=0&&l<=6&&(c===0||c===6)||c>=2&&c<=4&&l>=2&&l<=4?e.set(a+c,s+l,!0,!0):e.set(a+c,s+l,!1,!0))}}function sb(e){const t=e.size;for(let n=8;n<t-8;n++){const o=n%2===0;e.set(n,6,o,!0),e.set(6,n,o,!0)}}function cb(e,t){const n=tb.getPositions(t);for(let o=0;o<n.length;o++){const i=n[o][0],a=n[o][1];for(let s=-2;s<=2;s++)for(let c=-2;c<=2;c++)s===-2||s===2||c===-2||c===2||s===0&&c===0?e.set(i+s,a+c,!0,!0):e.set(i+s,a+c,!1,!0)}}function lb(e,t){const n=e.size,o=en.getEncodedBits(t);let i,a,s;for(let c=0;c<18;c++)i=Math.floor(c/3),a=c%3+n-8-3,s=(o>>c&1)===1,e.set(i,a,s,!0),e.set(a,i,s,!0)}function Fn(e,t,n){const o=e.size,i=ob.getEncodedBits(t,n);let a,s;for(a=0;a<15;a++)s=(i>>a&1)===1,a<6?e.set(a,8,s,!0):a<8?e.set(a+1,8,s,!0):e.set(o-15+a,8,s,!0),a<8?e.set(8,o-a-1,s,!0):a<9?e.set(8,15-a-1+1,s,!0):e.set(8,15-a-1,s,!0);e.set(o-8,8,1,!0)}function ub(e,t){const n=e.size;let o=-1,i=n-1,a=7,s=0;for(let c=n-1;c>0;c-=2)for(c===6&&c--;;){for(let l=0;l<2;l++)if(!e.isReserved(i,c-l)){let u=!1;s<t.length&&(u=(t[s]>>>a&1)===1),e.set(i,c-l,u),a--,a===-1&&(s++,a=7)}if(i+=o,i<0||n<=i){i-=o,o=-o;break}}}function db(e,t,n){const o=new XC;n.forEach(function(l){o.put(l.mode.bit,4),o.put(l.getLength(),ib.getCharCountIndicator(l.mode,e)),l.write(o)});const i=Nn.getSymbolTotalCodewords(e),a=er.getTotalCodewordsCount(e,t),s=(i-a)*8;for(o.getLengthInBits()+4<=s&&o.put(0,4);o.getLengthInBits()%8!==0;)o.putBit(0);const c=(s-o.getLengthInBits())/8;for(let l=0;l<c;l++)o.put(l%2?17:236,8);return fb(o,e,t)}function fb(e,t,n){const o=Nn.getSymbolTotalCodewords(t),i=er.getTotalCodewordsCount(t,n),a=o-i,s=er.getBlocksCount(t,n),c=o%s,l=s-c,u=Math.floor(o/s),d=Math.floor(a/s),m=d+1,f=u-d,p=new rb(f);let h=0;const v=new Array(s),S=new Array(s);let g=0;const w=new Uint8Array(e.buffer);for(let E=0;E<s;E++){const I=E<l?d:m;v[E]=w.slice(h,h+I),S[E]=p.encode(v[E]),h+=I,g=Math.max(g,I)}const y=new Uint8Array(o);let _=0,b,A;for(b=0;b<g;b++)for(A=0;A<s;A++)b<v[A].length&&(y[_++]=v[A][b]);for(b=0;b<f;b++)for(A=0;A<s;A++)y[_++]=S[A][b];return y}function pb(e,t,n,o){let i;if(Array.isArray(e))i=Dn.fromArray(e);else if(typeof e=="string"){let u=t;if(!u){const d=Dn.rawSplit(e);u=en.getBestVersionForData(d,n)}i=Dn.fromString(e,u||40)}else throw new Error("Invalid data");const a=en.getBestVersionForData(i,n);if(!a)throw new Error("The amount of data is too big to be stored in a QR Code");if(!t)t=a;else if(t<a)throw new Error(`
|
package/dist/index.js
CHANGED
|
@@ -8971,7 +8971,7 @@ const v1 = /* @__PURE__ */ In(h1, [["render", y1]]), _1 = ["tabindex", "aria-sel
|
|
|
8971
8971
|
role: "tab"
|
|
8972
8972
|
}, F(d(o)), 11, _1));
|
|
8973
8973
|
}
|
|
8974
|
-
}), S1 = "4.2.
|
|
8974
|
+
}), S1 = "4.2.6", b1 = {};
|
|
8975
8975
|
function C1(e, t) {
|
|
8976
8976
|
return E(e.$slots, "textI", oe(ie(e.$attrs)), () => [
|
|
8977
8977
|
x("span", Ie(e.$attrs, { "data-amplify-text": "" }), [
|
package/dist/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "4.2.
|
|
1
|
+
export declare const VERSION = "4.2.6";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-amplify/ui-vue",
|
|
3
|
-
"version": "4.2.
|
|
3
|
+
"version": "4.2.6",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.js",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"typecheck": "vue-tsc --noEmit"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"@aws-amplify/ui": "6.0.
|
|
41
|
+
"@aws-amplify/ui": "6.0.14",
|
|
42
42
|
"@vueuse/core": "7.5.5",
|
|
43
43
|
"@xstate/vue": "0.8.1",
|
|
44
44
|
"nanoid": "3.1.31",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"vite-jest": "^0.1.4"
|
|
66
66
|
},
|
|
67
67
|
"peerDependencies": {
|
|
68
|
-
"aws-amplify": "^6.0
|
|
68
|
+
"aws-amplify": "^6.2.0",
|
|
69
69
|
"vue": "^3.0"
|
|
70
70
|
}
|
|
71
71
|
}
|