UNPKG

photoeditorsdk

Version:

The most comprehensive photo editor SDK for HTML5

1 lines 1.48 MB
var PhotoEditorSDK=(()=>{var oJ=Object.create;var Pu=Object.defineProperty;var DD=Object.getOwnPropertyDescriptor;var nJ=Object.getOwnPropertyNames;var sJ=Object.getPrototypeOf;var aJ=Object.prototype.hasOwnProperty;var lJ=(i,t,e)=>t in i?Pu(i,t,{enumerable:true,configurable:true,writable:true,value:e}):i[t]=e;var ED=i=>Pu(i,"__esModule",{value:true});var _=(i=>typeof require!=="undefined"?require:typeof Proxy!=="undefined"?new Proxy(i,{get:(t,e)=>(typeof require!=="undefined"?require:t)[e]}):i)(function(i){if(typeof require!=="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+i+'" is not supported')});var d=(i,t)=>()=>(i&&(t=i(i=0)),t);var Gt=(i,t)=>()=>(t||i((t={exports:{}}).exports,t),t.exports);var de=(i,t)=>{for(var e in t)Pu(i,e,{get:t[e],enumerable:true})};var FD=(i,t,e,r)=>{if(t&&typeof t==="object"||typeof t==="function"){for(let o of nJ(t))if(!aJ.call(i,o)&&(e||o!=="default"))Pu(i,o,{get:()=>t[o],enumerable:!(r=DD(t,o))||r.enumerable})}return i};var y=(i,t)=>{return FD(ED(Pu(i!=null?oJ(sJ(i)):{},"default",!t&&i&&i.__esModule?{get:()=>i.default,enumerable:true}:{value:i,enumerable:true})),i)};var Li=(i=>{return(t,e)=>{return i&&i.get(t)||(e=FD(ED({}),t,1),i&&i.set(t,e),e)}})(typeof WeakMap!=="undefined"?new WeakMap:0);var f=(i,t,e,r)=>{var o=r>1?void 0:r?DD(t,e):t;for(var n=i.length-1,s;n>=0;n--)if(s=i[n])o=(r?s(t,e,o):s(o))||o;if(r&&o)Pu(t,e,o);return o};var q=(i,t,e)=>{lJ(i,typeof t!=="symbol"?t+"":t,e);return e};function Wm(){if(typeof window!=="undefined"){return window}if(typeof global!=="undefined"){return global}if(typeof self!=="undefined"){return self}return uJ}function Cr(){return++lt.mobxGuid}function me(i){ma(false,i);throw"X"}function ma(i,t){if(!i)throw new Error("[mobx] "+(t||cJ))}function is(i,t){if(true)return false;if(t){return is("'"+i+"', use '"+t+"' instead.")}if(OD.indexOf(i)!==-1)return false;OD.push(i);console.error("[mobx] Deprecated: "+i);return true}function Iv(i){var t=false;return function(){if(t)return;t=true;return i.apply(this,arguments)}}function dJ(i){var t=[];i.forEach(function(e){if(t.indexOf(e)===-1)t.push(e)});return t}function Dv(i){return i!==null&&typeof i==="object"}function Uu(i){if(i===null||typeof i!=="object")return false;var t=Object.getPrototypeOf(i);return t===Object.prototype||t===null}function mJ(i){if(Nu(i)||sn(i)){return i}else if(Array.isArray(i)){return new Map(i)}else if(Uu(i)){var t=new Map;for(var e in i){t.set(e,i[e])}return t}else{return me("Cannot convert to map from '"+i+"'")}}function pJ(i,t){for(var e=0;e<t.length;e++){as(i,t[e],i[t[e]])}}function as(i,t,e){Object.defineProperty(i,t,{enumerable:false,writable:true,configurable:true,value:e})}function Vm(i,t,e){Object.defineProperty(i,t,{enumerable:false,writable:false,configurable:true,value:e})}function hJ(i,t){if(false)me("Cannot make property '"+t+"' observable, it is not configurable and writable in the target object")}function ya(i,t){var e="isMobX"+i;t.prototype[e]=true;return function(r){return Dv(r)&&r[e]===true}}function fJ(i,t){return typeof i==="number"&&typeof t==="number"&&isNaN(i)&&isNaN(t)}function Nu(i){if(Wm().Map!==void 0&&i instanceof Wm().Map)return true;return false}function jm(i){return i instanceof Set}function rs(i){var t=[];while(true){var e=i.next();if(e.done)break;t.push(e.value)}return t}function jD(){return typeof Symbol==="function"&&Symbol.toPrimitive||"@@toPrimitive"}function $D(i){return i===null?null:typeof i==="object"?""+i:i}function BD(i,t){var e=i.next();while(!e.done){t(e.value);e=i.next()}}function KD(){return typeof Symbol==="function"&&Symbol.iterator||"@@iterator"}function Ev(i,t){Vm(i,KD(),t)}function Gm(i){i[KD()]=gJ;return i}function Fv(){return typeof Symbol==="function"&&Symbol.toStringTag||"@@toStringTag"}function gJ(){return this}function vg(i,t,e){if(t===void 0){t=AD}if(e===void 0){e=AD}var r=new xg(i);ZJ(r,t);uE(r,e);return r}function XD(i,t){return i===t}function bJ(i,t){return Uv(i,t)}function yJ(i,t){return Uv(i,t,1)}function _J(i,t){return fJ(i,t)||XD(i,t)}function qD(i,t){_v(i,t);function e(){this.constructor=i}i.prototype=t===null?Object.create(t):(e.prototype=t.prototype,new e)}function xv(i,t){var e=typeof Symbol==="function"&&i[Symbol.iterator];if(!e)return i;var r=e.call(i),o,n=[],s;try{while((t===void 0||t-- >0)&&!(o=r.next()).done)n.push(o.value)}catch(a){s={error:a}}finally{try{if(o&&!o.done&&(e=r["return"]))e.call(r)}finally{if(s)throw s.error}}return n}function vv(){for(var i=[],t=0;t<arguments.length;t++)i=i.concat(xv(arguments[t]));return i}function CJ(i,t){var e=t?xJ:vJ;return e[i]||(e[i]={configurable:true,enumerable:t,get:function(){Al(this);return this[i]},set:function(r){Al(this);this[i]=r}})}function Al(i){if(i.__mobxDidRunLazyInitializers===true)return;var t=i.__mobxDecorators;if(t){as(i,"__mobxDidRunLazyInitializers",true);for(var e in t){var r=t[e];r.propertyCreator(i,r.prop,r.descriptor,r.decoratorTarget,r.decoratorArguments)}}}function YD(i,t){return function e(){var r;var o=function n(s,a,l,c){if(c===true){t(s,a,l,s,r);return null}if(false)me("This function is a decorator, but it wasn't invoked like a decorator");if(!Object.prototype.hasOwnProperty.call(s,"__mobxDecorators")){var u=s.__mobxDecorators;as(s,"__mobxDecorators",Fe({},u))}s.__mobxDecorators[a]={prop:a,propertyCreator:t,descriptor:l,decoratorTarget:s,decoratorArguments:r};return CJ(a,i)};if(SJ(arguments)){r=pg;return o.apply(null,arguments)}else{r=Array.prototype.slice.call(arguments);return o}}}function SJ(i){return(i.length===2||i.length===3)&&typeof i[1]==="string"||i.length===4&&i[3]===true}function $m(i,t,e){if(_g(i))return i;if(Array.isArray(i))return Q.array(i,{name:e});if(Uu(i))return Q.object(i,void 0,{name:e});if(Nu(i))return Q.map(i,{name:e});if(jm(i))return Q.set(i,{name:e});return i}function wJ(i,t,e){if(i===void 0||i===null)return i;if(Pl(i)||Ll(i)||sn(i)||_a(i))return i;if(Array.isArray(i))return Q.array(i,{name:e,deep:false});if(Uu(i))return Q.object(i,void 0,{name:e,deep:false});if(Nu(i))return Q.map(i,{name:e,deep:false});if(jm(i))return Q.set(i,{name:e,deep:false});return me(false)}function Cg(i){return i}function TJ(i,t,e){if(false)throw"observable.struct should not be used with observable values";if(Uv(i,t))return t;return i}function Sg(i){ma(i);var t=YD(true,function(r,o,n,s,a){if(false){ma(!n||!n.get,'@observable cannot be used on getter (property "'+o+'"), use @computed instead.')}var l=n?n.initializer?n.initializer.call(r):n.value:void 0;hZ(r,o,l,i)});var e=typeof process!=="undefined"&&process.env&&false?function r(){if(arguments.length<2)return me("Incorrect decorator invocation. @observable decorator doesn't expect any arguments");return t.apply(null,arguments)}:t;e.enhancer=i;return e}function Lu(i){if(i===null||i===void 0)return JD;if(typeof i==="string")return{name:i,deep:true};if(false){if(typeof i!=="object")return me("expected options object");Object.keys(i).forEach(assertValidOption)}return i}function cg(i){return i.defaultDecorator?i.defaultDecorator.enhancer:i.deep===false?Cg:$m}function EJ(i,t,e){if(typeof arguments[1]==="string"){return Ov.apply(null,arguments)}if(_g(i))return i;var r=Uu(i)?Q.object(i,t,e):Array.isArray(i)?Q.array(i,t):Nu(i)?Q.map(i,t):jm(i)?Q.set(i,t):i;if(r!==i)return r;me(false)}function es(i){me("Expected one or two arguments to observable."+i+". Did you accidentally try to use observable."+i+" as decorator?")}function Hm(i){return i instanceof gg}function Cv(i){switch(i.dependenciesState){case Yt.UP_TO_DATE:return false;case Yt.NOT_TRACKING:case Yt.STALE:return true;case Yt.POSSIBLY_STALE:{var t=Ml(true);var e=Hu();var r=i.observing,o=r.length;for(var n=0;n<o;n++){var s=r[n];if(wg(s)){if(lt.disableErrorBoundaries){s.get()}else{try{s.get()}catch(a){pa(e);os(t);return true}}if(i.dependenciesState===Yt.STALE){pa(e);os(t);return true}}}tE(i);pa(e);os(t);return false}}}function zu(i){var t=i.observers.length>0;if(lt.computationDepth>0&&t)me(false);if(!lt.allowStateChanges&&(t||lt.enforceActions==="strict"))me(false)}function RJ(i){if(false){console.warn("[mobx] Observable "+i.name+" being read outside a reactive context")}}function QD(i,t,e){var r=Ml(true);tE(i);i.newObserving=new Array(i.observing.length+100);i.unboundDepsCount=0;i.runId=++lt.runId;var o=lt.trackingDerivation;lt.trackingDerivation=i;var n;if(lt.disableErrorBoundaries===true){n=t.call(e)}else{try{n=t.call(e)}catch(s){n=new gg(s)}}lt.trackingDerivation=o;AJ(i);if(i.observing.length===0){OJ(i)}os(r);return n}function OJ(i){if(true)return;if(lt.reactionRequiresObservable||i.requiresObservable){console.warn("[mobx] Derivation "+i.name+" is created/updated without reading any observable value")}}function AJ(i){var t=i.observing;var e=i.observing=i.newObserving;var r=Yt.UP_TO_DATE;var o=0,n=i.unboundDepsCount;for(var s=0;s<n;s++){var a=e[s];if(a.diffValue===0){a.diffValue=1;if(o!==s)e[o]=a;o++}if(a.dependenciesState>r){r=a.dependenciesState}}e.length=o;i.newObserving=null;n=t.length;while(n--){var a=t[n];if(a.diffValue===0){oE(a,i)}a.diffValue=0}while(o--){var a=e[o];if(a.diffValue===1){a.diffValue=0;UJ(a,i)}}if(r!==Yt.UP_TO_DATE){i.dependenciesState=r;i.onBecomeStale()}}function Sv(i){var t=i.observing;i.observing=[];var e=t.length;while(e--)oE(t[e],i);i.dependenciesState=Yt.NOT_TRACKING}function Av(i){var t=Hu();var e=i();pa(t);return e}function Hu(){var i=lt.trackingDerivation;lt.trackingDerivation=null;return i}function pa(i){lt.trackingDerivation=i}function Ml(i){var t=lt.allowStateReads;lt.allowStateReads=i;return t}function os(i){lt.allowStateReads=i}function tE(i){if(i.dependenciesState===Yt.UP_TO_DATE)return;i.dependenciesState=Yt.UP_TO_DATE;var t=i.observing;var e=t.length;while(e--)t[e].lowestObserverState=Yt.UP_TO_DATE}function Ol(i,t){if(false){ma(typeof t==="function","`action` can only be invoked on functions");if(typeof i!=="string"||!i)me("actions should have valid names, got: '"+i+"'")}var e=function(){return eE(i,t,this,arguments)};if(false){if(vpt){Object.defineProperty(e,"name",{value:i})}}e.isMobxAction=true;return e}function eE(i,t,e,r){var o=PJ(i,e,r);try{return t.apply(e,r)}catch(n){o.error=n;throw n}finally{MJ(o)}}function PJ(i,t,e){var r=bi()&&!!i;var o=0;if(r){o=Date.now();var n=e&&e.length||0;var s=new Array(n);if(n>0)for(var a=0;a<n;a++)s[a]=e[a];vo({type:"action",name:i,object:t,arguments:s})}var l=Hu();ns();var c=Km(true);var u=Ml(true);var m={prevDerivation:l,prevAllowStateChanges:c,prevAllowStateReads:u,notifySpy:r,startTime:o,actionId:BJ++,parentActionId:bg};bg=m.actionId;return m}function MJ(i){if(bg!==i.actionId){me("invalid action stack. did you forget to finish an action?")}bg=i.parentActionId;if(i.error!==void 0){lt.suppressReactionErrors=true}Xm(i.prevAllowStateChanges);os(i.prevAllowStateReads);ss();pa(i.prevDerivation);if(i.notifySpy){Co({time:Date.now()-i.startTime})}lt.suppressReactionErrors=false}function iE(i,t){var e=Km(i);var r;try{r=t()}finally{Xm(e)}return r}function Km(i){var t=lt.allowStateChanges;lt.allowStateChanges=i;return t}function Xm(i){lt.allowStateChanges=i}function zJ(){if(lt.pendingReactions.length||lt.inBatch||lt.isRunningReactions)me("isolateGlobalState should be called before MobX is running any reactions");rE=true;if(mg){if(--Wm().__mobxInstanceCount===0)Wm().__mobxGlobals=void 0;lt=new dg}}function UJ(i,t){var e=i.observers.length;if(e){i.observersIndexes[t.__mapid]=e}i.observers[e]=t;if(i.lowestObserverState>t.dependenciesState)i.lowestObserverState=t.dependenciesState}function oE(i,t){if(i.observers.length===1){i.observers.length=0;nE(i)}else{var e=i.observers;var r=i.observersIndexes;var o=e.pop();if(o!==t){var n=r[t.__mapid]||0;if(n){r[o.__mapid]=n}else{delete r[o.__mapid]}e[n]=o}delete r[t.__mapid]}}function nE(i){if(i.isPendingUnobservation===false){i.isPendingUnobservation=true;lt.pendingUnobservations.push(i)}}function ns(){lt.inBatch++}function ss(){if(--lt.inBatch===0){cE();var i=lt.pendingUnobservations;for(var t=0;t<i.length;t++){var e=i[t];e.isPendingUnobservation=false;if(e.observers.length===0){if(e.isBeingObserved){e.isBeingObserved=false;e.onBecomeUnobserved()}if(e instanceof fa){e.suspend()}}}lt.pendingUnobservations=[]}}function sE(i){RJ(i);var t=lt.trackingDerivation;if(t!==null){if(t.runId!==i.lastAccessedBy){i.lastAccessedBy=t.runId;t.newObserving[t.unboundDepsCount++]=i;if(!i.isBeingObserved){i.isBeingObserved=true;i.onBecomeObserved()}}return true}else if(i.observers.length===0&&lt.inBatch>0){nE(i)}return false}function NJ(i){if(i.lowestObserverState===Yt.STALE)return;i.lowestObserverState=Yt.STALE;var t=i.observers;var e=t.length;while(e--){var r=t[e];if(r.dependenciesState===Yt.UP_TO_DATE){if(r.isTracing!==xo.NONE){aE(r,i)}r.onBecomeStale()}r.dependenciesState=Yt.STALE}}function HJ(i){if(i.lowestObserverState===Yt.STALE)return;i.lowestObserverState=Yt.STALE;var t=i.observers;var e=t.length;while(e--){var r=t[e];if(r.dependenciesState===Yt.POSSIBLY_STALE)r.dependenciesState=Yt.STALE;else if(r.dependenciesState===Yt.UP_TO_DATE)i.lowestObserverState=Yt.UP_TO_DATE}}function WJ(i){if(i.lowestObserverState!==Yt.UP_TO_DATE)return;i.lowestObserverState=Yt.POSSIBLY_STALE;var t=i.observers;var e=t.length;while(e--){var r=t[e];if(r.dependenciesState===Yt.UP_TO_DATE){r.dependenciesState=Yt.POSSIBLY_STALE;if(r.isTracing!==xo.NONE){aE(r,i)}r.onBecomeStale()}}}function aE(i,t){console.log("[mobx.trace] '"+i.name+"' is invalidated due to a change in: '"+t.name+"'");if(i.isTracing===xo.BREAK){var e=[];lE(Pv(i),e,1);new Function("debugger;\n/*\nTracing '"+i.name+"'\n\nYou are entering this break point because derivation '"+i.name+"' is being traced and '"+t.name+"' is now forcing it to update.\nJust follow the stacktrace you should now see in the devtools to see precisely what piece of your code is causing this update\nThe stackframe you are looking for is at least ~6-8 stack-frames up.\n\n"+(i instanceof fa?i.derivation.toString().replace(/[*]\//g,"/"):"")+"\n\nThe dependencies for this derivation are:\n\n"+e.join("\n")+"\n*/\n ")()}}function lE(i,t,e){if(t.length>=1e3){t.push("(and many more)");return}t.push(""+new Array(e).join(" ")+i.name);if(i.dependencies)i.dependencies.forEach(function(r){return lE(r,t,e+1)})}function cE(){if(lt.inBatch>0||lt.isRunningReactions)return;wv(GJ)}function GJ(){lt.isRunningReactions=true;var i=lt.pendingReactions;var t=0;while(i.length>0){if(++t===LD){console.error("Reaction doesn't converge to a stable state after "+LD+" iterations."+(" Probably there is a cycle in the reactive function: "+i[0]));i.splice(0)}var e=i.splice(0);for(var r=0,o=e.length;r<o;r++)e[r].runReaction()}lt.isRunningReactions=false}function VJ(i){var t=wv;wv=function(e){return i(function(){return t(e)})}}function bi(){return!!lt.spyListeners.length}function Bl(i){if(!lt.spyListeners.length)return;var t=lt.spyListeners;for(var e=0,r=t.length;e<r;e++)t[e](i)}function vo(i){var t=Fe(Fe({},i),{spyReportStart:true});Bl(t)}function Co(i){if(i)Bl(Fe(Fe({},i),{spyReportEnd:true}));else Bl(jJ)}function Bv(i){lt.spyListeners.push(i);return Iv(function(){lt.spyListeners=lt.spyListeners.filter(function(t){return t!==i})})}function $J(){me(false)}function zD(i){return function(t,e,r){if(r){if(false){return me("@action cannot be used with getters")}if(r.value){return{value:Ol(i,r.value),enumerable:false,configurable:true,writable:true}}var o=r.initializer;return{enumerable:false,configurable:true,writable:true,initializer:function(){return Ol(i,o.call(this))}}}return KJ(i).apply(this,arguments)}}function KJ(i){return function(t,e,r){Object.defineProperty(t,e,{configurable:true,enumerable:false,get:function(){return void 0},set:function(o){as(this,e,C(i,o))}})}}function XJ(i,t,e,r){if(r===true){yv(i,t,e.value);return null}if(e){return{configurable:true,enumerable:false,get:function(){yv(this,t,e.value||e.initializer.call(this));return this[t]},set:$J}}return{enumerable:false,configurable:true,set:function(o){yv(this,t,o)},get:function(){return void 0}}}function Ve(i,t){var e=typeof i==="string"?i:i.name||"<unnamed action>";var r=typeof i==="function"?i:t;if(false){ma(typeof r==="function"&&r.length===0,"`runInAction` expects a function without arguments");if(typeof e!=="string"||!e)me("actions should have valid names, got: '"+e+"'")}return eE(e,r,this,void 0)}function yv(i,t,e){as(i,t,Ol(t,e.bind(i)))}function qJ(i,t){if(t===void 0){t=VD}if(false){ma(typeof i==="function","Autorun expects a function as first argument");ma(isAction(i)===false,"Autorun does not accept actions since actions are untrackable")}var e=t&&t.name||i.name||"Autorun@"+Cr();var r=!t.scheduler&&!t.delay;var o;if(r){o=new ga(e,function(){this.track(a)},t.onError,t.requiresObservable)}else{var n=JJ(t);var s=false;o=new ga(e,function(){if(!s){s=true;n(function(){s=false;if(!o.isDisposed)o.track(a)})}},t.onError,t.requiresObservable)}function a(){i(o)}o.schedule();return o.getDisposer()}function JJ(i){return i.scheduler?i.scheduler:i.delay?function(t){return setTimeout(t,i.delay)}:YJ}function ZJ(i,t,e){return dE("onBecomeObserved",i,t,e)}function uE(i,t,e){return dE("onBecomeUnobserved",i,t,e)}function dE(i,t,e,r){var o=typeof r==="function"?ba(t,e):ba(t);var n=typeof r==="function"?r:e;var s=o[i];if(typeof s!=="function")return me(false);o[i]=function(){s.call(this);n.call(this)};return function(){o[i]=s}}function Tg(i){var t=i.enforceActions,e=i.computedRequiresReaction,r=i.computedConfigurable,o=i.disableErrorBoundaries,n=i.arrayBuffer,s=i.reactionScheduler,a=i.reactionRequiresObservable,l=i.observableRequiresReaction;if(i.isolateGlobalState===true){zJ()}if(t!==void 0){if(typeof t==="boolean"||t==="strict")is(`Deprecated value for 'enforceActions', use 'false' => '"never"', 'true' => '"observed"', '"strict"' => "'always'" instead`);var c=void 0;switch(t){case true:case"observed":c=true;break;case false:case"never":c=false;break;case"strict":case"always":c="strict";break;default:me("Invalid value for 'enforceActions': '"+t+"', expected 'never', 'always' or 'observed'")}lt.enforceActions=c;lt.allowStateChanges=c===true||c==="strict"?false:true}if(e!==void 0){lt.computedRequiresReaction=!!e}if(a!==void 0){lt.reactionRequiresObservable=!!a}if(l!==void 0){lt.observableRequiresReaction=!!l;lt.allowStateReads=!lt.observableRequiresReaction}if(r!==void 0){lt.computedConfigurable=!!r}if(o!==void 0){if(o===true)console.warn("WARNING: Debug feature only. MobX will NOT recover from errors if this is on.");lt.disableErrorBoundaries=!!o}if(typeof n==="number"){Lv(n)}if(s){VJ(s)}}function QJ(i,t,e,r){if(false){ma(arguments.length>=2&&arguments.length<=4,"'extendObservable' expected 2-4 arguments");ma(typeof i==="object","'extendObservable' expects an object as first argument");ma(!sn(i),"'extendObservable' should not be used on maps, use map.merge instead");ma(!_g(t),"Extending an object with another observable (object) is not supported. Please construct an explicit propertymap, using `toJS` if need. See issue #540");if(e){for(var o in e)if(!(o in t))me("Trying to declare a decorator for unspecified property '"+o+"'")}}r=Lu(r);var n=r.defaultDecorator||(r.deep===false?ZD:Ov);Al(i);zv(i,r.name,n.enhancer);ns();try{var s=Object.getOwnPropertyNames(t);for(var a=0,l=s.length;a<l;a++){var o=s[a];var c=Object.getOwnPropertyDescriptor(t,o);if(false){if(isComputed(c.value))me("Passing a 'computed' as initial property value is no longer supported by extendObservable. Use a getter or decorator instead")}var u=e&&o in e?e[o]:c.get?fg:n;if(false)return me("Not a valid decorator for '"+o+"', got: "+u);var m=u(i,o,c,true);if(m)Object.defineProperty(i,o,m)}}finally{ss()}return i}function Pv(i,t){return mE(ba(i,t))}function mE(i){var t={name:i.name};if(i.observing&&i.observing.length>0)t.dependencies=dJ(i.observing).map(mE);return t}function tZ(){this.message="FLOW_CANCELLED"}function eZ(i,t){if(i===null||i===void 0)return false;if(t!==void 0){if(false)return me("isObservable(object, propertyName) is not supported for arrays and maps. Use map.has or array.length instead.");if(Pl(i)){var e=i.$mobx;return e.values&&!!e.values[t]}return false}return Pl(i)||!!i.$mobx||Rv(i)||yg(i)||wg(i)}function _g(i){if(arguments.length!==1)me(false);return eZ(i)}function iZ(i){if(Pl(i)){return i.$mobx.getKeys()}if(sn(i)){return rs(i.keys())}if(_a(i)){return rs(i.keys())}if(Ll(i)){return i.map(function(t,e){return e})}return me(false)}function Mu(i,t,e,r){if(r.detectCycles)i.set(t,e);return e}function da(i,t,e){if(!t.recurseEverything&&!_g(i))return i;if(typeof i!=="object")return i;if(i===null)return null;if(i instanceof Date)return i;if(LJ(i))return da(i.get(),t,e);if(_g(i))iZ(i);var r=t.detectCycles===true;if(r&&i!==null&&e.has(i)){return e.get(i)}if(Ll(i)||Array.isArray(i)){var o=Mu(e,i,[],t);var n=i.map(function(g){return da(g,t,e)});o.length=n.length;for(var s=0,a=n.length;s<a;s++)o[s]=n[s];return o}if(_a(i)||Object.getPrototypeOf(i)===Set.prototype){if(t.exportMapsAsObjects===false){var l=Mu(e,i,new Set,t);i.forEach(function(g){l.add(da(g,t,e))});return l}else{var c=Mu(e,i,[],t);i.forEach(function(g){c.push(da(g,t,e))});return c}}if(sn(i)||Object.getPrototypeOf(i)===Map.prototype){if(t.exportMapsAsObjects===false){var u=Mu(e,i,new Map,t);i.forEach(function(g,x){u.set(x,da(g,t,e))});return u}else{var m=Mu(e,i,{},t);i.forEach(function(g,x){m[x]=da(g,t,e)});return m}}var p=Mu(e,i,{},t);for(var h in i){p[h]=da(i[h],t,e)}return p}function ct(i,t){if(typeof t==="boolean")t={detectCycles:t};if(!t)t=rZ;t.detectCycles=t.detectCycles===void 0?t.recurseEverything===true:t.detectCycles===true;var e;if(t.detectCycles)e=new Map;return da(i,t,e)}function oZ(){var i=[];for(var t=0;t<arguments.length;t++){i[t]=arguments[t]}var e=false;if(typeof i[i.length-1]==="boolean")e=i.pop();var r=nZ(i);if(!r){return me(false)}if(r.isTracing===xo.NONE){console.log("[mobx.trace] '"+r.name+"' tracing enabled")}r.isTracing=e?xo.BREAK:xo.LOG}function nZ(i){switch(i.length){case 0:return lt.trackingDerivation;case 1:return ba(i[0]);case 2:return ba(i[0],i[1])}}function en(i,t){if(t===void 0){t=void 0}ns();try{return i.apply(t)}finally{ss()}}function rn(i){return i.interceptors!==void 0&&i.interceptors.length>0}function qm(i,t){var e=i.interceptors||(i.interceptors=[]);e.push(t);return Iv(function(){var r=e.indexOf(t);if(r!==-1)e.splice(r,1)})}function on(i,t){var e=Hu();try{var r=i.interceptors;if(r)for(var o=0,n=r.length;o<n;o++){t=r[o](t);ma(!t||t.type,"Intercept handlers should return nothing or a change object");if(!t)break}return t}finally{pa(e)}}function So(i){return i.changeListeners!==void 0&&i.changeListeners.length>0}function Ym(i,t){var e=i.changeListeners||(i.changeListeners=[]);e.push(t);return Iv(function(){var r=e.indexOf(t);if(r!==-1)e.splice(r,1)})}function wo(i,t){var e=Hu();var r=i.changeListeners;if(!r)return;r=r.slice();for(var o=0,n=r.length;o<n;o++){r[o](t)}pa(e)}function lZ(i,t){if(typeof Object["setPrototypeOf"]!=="undefined"){Object["setPrototypeOf"](i.prototype,t)}else if(typeof i.prototype.__proto__!=="undefined"){i.prototype.__proto__=t}else{i["prototype"]=t}}function hE(i){return{enumerable:false,configurable:false,get:function(){return this.get(i)},set:function(t){this.set(i,t)}}}function uZ(i){Object.defineProperty(nn.prototype,""+i,hE(i))}function Lv(i){for(var t=Tv;t<i;t++)uZ(t);Tv=i}function Ll(i){return Dv(i)&&dZ(i.$mobx)}function ug(i){if(i&&i.toString)return i.toString();else return new String(i).toString()}function zv(i,t,e){if(t===void 0){t=""}if(e===void 0){e=$m}var r=i.$mobx;if(r)return r;if(!Uu(i))t=(i.constructor.name||"ObservableObject")+"@"+Cr();if(!t)t="ObservableObject@"+Cr();r=new fE(i,t,e);Vm(i,"$mobx",r);return r}function hZ(i,t,e,r){var o=zv(i);hJ(i,t);if(rn(o)){var n=on(o,{object:i,name:t,type:"add",newValue:e});if(!n)return;e=n.newValue}var s=o.values[t]=new ha(e,r,o.name+"."+t,false);e=s.value;Object.defineProperty(i,t,gZ(t));if(o.keys)o.keys.push(t);yZ(o,i,t,e)}function fZ(i,t,e){var r=zv(i);e.name=r.name+"."+t;e.context=i;r.values[t]=new fa(e);Object.defineProperty(i,t,bZ(t))}function gZ(i){return UD[i]||(UD[i]={configurable:true,enumerable:true,get:function(){return this.$mobx.read(this,i)},set:function(t){this.$mobx.write(this,i,t)}})}function HD(i){var t=i.$mobx;if(!t){Al(i);return i.$mobx}return t}function bZ(i){return ND[i]||(ND[i]={configurable:lt.computedConfigurable,enumerable:false,get:function(){return HD(this).read(this,i)},set:function(t){HD(this).write(this,i,t)}})}function yZ(i,t,e,r){var o=So(i);var n=bi();var s=o||n?{type:"add",object:t,name:e,newValue:r}:null;if(n)vo(Fe(Fe({},s),{name:i.name,key:e}));if(o)wo(i,s);if(n)Co()}function Pl(i){if(Dv(i)){Al(i);return _Z(i.$mobx)}return false}function ba(i,t){if(typeof i==="object"&&i!==null){if(Ll(i)){if(t!==void 0)me(false);return i.$mobx.atom}if(_a(i)){return i.$mobx}if(sn(i)){var e=i;if(t===void 0)return e._keysAtom;var r=e._data.get(t)||e._hasMap.get(t);if(!r)me(false);return r}Al(i);if(t&&!i.$mobx)i[t];if(Pl(i)){if(!t)return me(false);var r=i.$mobx.values[t];if(!r)me(false);return r}if(Rv(i)||wg(i)||yg(i)){return i}}else if(typeof i==="function"){if(yg(i.$mobx)){return i.$mobx}}return me(false)}function gE(i,t){if(!i)me("Expecting some object");if(t!==void 0)return gE(ba(i,t));if(Rv(i)||wg(i)||yg(i))return i;if(sn(i)||_a(i))return i;Al(i);if(i.$mobx)return i.$mobx;me(false)}function xZ(i,t){var e;if(t!==void 0)e=ba(i,t);else if(Pl(i)||sn(i)||_a(i))e=gE(i);else e=ba(i);return e.name}function Uv(i,t,e){if(e===void 0){e=-1}return kv(i,t,e)}function kv(i,t,e,r,o){if(i===t)return i!==0||1/i===1/t;if(i==null||t==null)return false;if(i!==i)return t!==t;var n=typeof i;if(n!=="function"&&n!=="object"&&typeof t!="object")return false;i=GD(i);t=GD(t);var s=WD.call(i);if(s!==WD.call(t))return false;switch(s){case"[object RegExp]":case"[object String]":return""+i===""+t;case"[object Number]":if(+i!==+i)return+t!==+t;return+i===0?1/+i===1/t:+i===+t;case"[object Date]":case"[object Boolean]":return+i===+t;case"[object Symbol]":return typeof Symbol!=="undefined"&&Symbol.valueOf.call(i)===Symbol.valueOf.call(t)}var a=s==="[object Array]";if(!a){if(typeof i!="object"||typeof t!="object")return false;var l=i.constructor,c=t.constructor;if(l!==c&&!(typeof l==="function"&&l instanceof l&&typeof c==="function"&&c instanceof c)&&("constructor"in i&&"constructor"in t)){return false}}if(e===0){return false}else if(e<0){e=-1}r=r||[];o=o||[];var u=r.length;while(u--){if(r[u]===i)return o[u]===t}r.push(i);o.push(t);if(a){u=i.length;if(u!==t.length)return false;while(u--){if(!kv(i[u],t[u],e-1,r,o))return false}}else{var m=Object.keys(i);var p=void 0;u=m.length;if(Object.keys(t).length!==u)return false;while(u--){p=m[u];if(!(vZ(t,p)&&kv(i[p],t[p],e-1,r,o)))return false}}r.pop();o.pop();return true}function GD(i){if(Ll(i))return i.peek();if(Nu(i)||sn(i))return rs(i.entries());if(jm(i)||_a(i))return rs(i.entries());return i}function vZ(i,t){return Object.prototype.hasOwnProperty.call(i,t)}var cJ,pg,VD,uJ,OD,AD,xg,Rv,hg,_v,Fe,xJ,vJ,JD,kJ,Ov,IJ,ZD,DJ,PD,Q,fg,FJ,S,Yt,xo,gg,bg,BJ,MD,vpt,ha,LJ,fa,wg,dg,mg,rE,lt,ga,LD,wv,yg,jJ,C,YJ,rZ,sZ,aZ,Tv,Mv,pE,nn,cZ,dZ,mZ,kg,sn,pZ,Ig,_a,fE,UD,ND,_Z,WD,Nv,Cpt;var Tt=d(()=>{cJ="An invariant failed, however the error is obfuscated because this is an production build.";pg=[];Object.freeze(pg);VD={};Object.freeze(VD);uJ={};OD=[];AD=function(){};xg=function(){function i(t){if(t===void 0){t="Atom@"+Cr()}this.name=t;this.isPendingUnobservation=false;this.isBeingObserved=false;this.observers=[];this.observersIndexes={};this.diffValue=0;this.lastAccessedBy=0;this.lowestObserverState=Yt.NOT_TRACKING}i.prototype.onBecomeUnobserved=function(){};i.prototype.onBecomeObserved=function(){};i.prototype.reportObserved=function(){return sE(this)};i.prototype.reportChanged=function(){ns();NJ(this);ss()};i.prototype.toString=function(){return this.name};return i}();Rv=ya("Atom",xg);hg={identity:XD,structural:bJ,default:_J,shallow:yJ};_v=function(i,t){_v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,r){e.__proto__=r}||function(e,r){for(var o in r)if(r.hasOwnProperty(o))e[o]=r[o]};return _v(i,t)};Fe=function(){Fe=Object.assign||function i(t){for(var e,r=1,o=arguments.length;r<o;r++){e=arguments[r];for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n))t[n]=e[n]}return t};return Fe.apply(this,arguments)};xJ={};vJ={};JD={deep:true,name:void 0,defaultDecorator:void 0};kJ={deep:false,name:void 0,defaultDecorator:void 0};Object.freeze(JD);Object.freeze(kJ);Ov=Sg($m);IJ=Sg(wJ);ZD=Sg(Cg);DJ=Sg(TJ);PD={box:function(i,t){if(arguments.length>2)es("box");var e=Lu(t);return new ha(i,cg(e),e.name,true,e.equals)},shallowBox:function(i,t){if(arguments.length>2)es("shallowBox");is("observable.shallowBox","observable.box(value, { deep: false })");return Q.box(i,{name:t,deep:false})},array:function(i,t){if(arguments.length>2)es("array");var e=Lu(t);return new nn(i,cg(e),e.name)},shallowArray:function(i,t){if(arguments.length>2)es("shallowArray");is("observable.shallowArray","observable.array(values, { deep: false })");return Q.array(i,{name:t,deep:false})},map:function(i,t){if(arguments.length>2)es("map");var e=Lu(t);return new kg(i,cg(e),e.name)},shallowMap:function(i,t){if(arguments.length>2)es("shallowMap");is("observable.shallowMap","observable.map(values, { deep: false })");return Q.map(i,{name:t,deep:false})},set:function(i,t){if(arguments.length>2)es("set");var e=Lu(t);return new Ig(i,cg(e),e.name)},object:function(i,t,e){if(typeof arguments[1]==="string")es("object");var r=Lu(e);return QJ({},i,t,r)},shallowObject:function(i,t){if(typeof arguments[1]==="string")es("shallowObject");is("observable.shallowObject","observable.object(values, {}, { deep: false })");return Q.object(i,{},{name:t,deep:false})},ref:ZD,shallow:IJ,deep:Ov,struct:DJ};Q=EJ;Object.keys(PD).forEach(function(i){return Q[i]=PD[i]});fg=YD(false,function(i,t,e,r,o){if(false){ma(e&&e.get,"Trying to declare a computed value for unspecified getter '"+t+"'")}var n=e.get,s=e.set;var a=o[0]||{};fZ(i,t,Fe({get:n,set:s},a))});FJ=fg({equals:hg.structural});S=function i(t,e,r){if(typeof e==="string"){return fg.apply(null,arguments)}if(t!==null&&typeof t==="object"&&arguments.length===1){return fg.apply(null,arguments)}if(false){ma(typeof t==="function","First argument to `computed` should be an expression.");ma(arguments.length<3,"Computed takes one or two arguments if used as function")}var o=typeof e==="object"?e:{};o.get=t;o.set=typeof e==="function"?e:o.set;o.name=o.name||t.name||"";return new fa(o)};S.struct=FJ;(function(i){i[i["NOT_TRACKING"]=-1]="NOT_TRACKING";i[i["UP_TO_DATE"]=0]="UP_TO_DATE";i[i["POSSIBLY_STALE"]=1]="POSSIBLY_STALE";i[i["STALE"]=2]="STALE"})(Yt||(Yt={}));(function(i){i[i["NONE"]=0]="NONE";i[i["LOG"]=1]="LOG";i[i["BREAK"]=2]="BREAK"})(xo||(xo={}));gg=function(){function i(t){this.cause=t}return i}();bg=0;BJ=1;MD=Object.getOwnPropertyDescriptor(function(){},"name");vpt=MD&&MD.configurable;ha=function(i){qD(t,i);function t(e,r,o,n,s){if(o===void 0){o="ObservableValue@"+Cr()}if(n===void 0){n=true}if(s===void 0){s=hg.default}var a=i.call(this,o)||this;a.enhancer=r;a.name=o;a.equals=s;a.hasUnreportedChange=false;a.value=r(e,void 0,o);if(n&&bi()){Bl({type:"create",name:a.name,newValue:""+a.value})}return a}t.prototype.dehanceValue=function(e){if(this.dehancer!==void 0)return this.dehancer(e);return e};t.prototype.set=function(e){var r=this.value;e=this.prepareNewValue(e);if(e!==lt.UNCHANGED){var o=bi();if(o){vo({type:"update",name:this.name,newValue:e,oldValue:r})}this.setNewValue(e);if(o)Co()}};t.prototype.prepareNewValue=function(e){zu(this);if(rn(this)){var r=on(this,{object:this,type:"update",newValue:e});if(!r)return lt.UNCHANGED;e=r.newValue}e=this.enhancer(e,this.value,this.name);return this.equals(this.value,e)?lt.UNCHANGED:e};t.prototype.setNewValue=function(e){var r=this.value;this.value=e;this.reportChanged();if(So(this)){wo(this,{type:"update",object:this,newValue:e,oldValue:r})}};t.prototype.get=function(){this.reportObserved();return this.dehanceValue(this.value)};t.prototype.intercept=function(e){return qm(this,e)};t.prototype.observe=function(e,r){if(r)e({object:this,type:"update",newValue:this.value,oldValue:void 0});return Ym(this,e)};t.prototype.toJSON=function(){return this.get()};t.prototype.toString=function(){return this.name+"["+this.value+"]"};t.prototype.valueOf=function(){return $D(this.get())};return t}(xg);ha.prototype[jD()]=ha.prototype.valueOf;LJ=ya("ObservableValue",ha);fa=function(){function i(t){this.dependenciesState=Yt.NOT_TRACKING;this.observing=[];this.newObserving=null;this.isBeingObserved=false;this.isPendingUnobservation=false;this.observers=[];this.observersIndexes={};this.diffValue=0;this.runId=0;this.lastAccessedBy=0;this.lowestObserverState=Yt.UP_TO_DATE;this.unboundDepsCount=0;this.__mapid="#"+Cr();this.value=new gg(null);this.isComputing=false;this.isRunningSetter=false;this.isTracing=xo.NONE;ma(t.get,"missing option for computed: get");this.derivation=t.get;this.name=t.name||"ComputedValue@"+Cr();if(t.set)this.setter=Ol(this.name+"-setter",t.set);this.equals=t.equals||(t.compareStructural||t.struct?hg.structural:hg.default);this.scope=t.context;this.requiresReaction=!!t.requiresReaction;this.keepAlive=!!t.keepAlive}i.prototype.onBecomeStale=function(){WJ(this)};i.prototype.onBecomeUnobserved=function(){};i.prototype.onBecomeObserved=function(){};i.prototype.get=function(){if(this.isComputing)me("Cycle detected in computation "+this.name+": "+this.derivation);if(lt.inBatch===0&&this.observers.length===0&&!this.keepAlive){if(Cv(this)){this.warnAboutUntrackedRead();ns();this.value=this.computeValue(false);ss()}}else{sE(this);if(Cv(this)){if(this.trackAndCompute())HJ(this)}}var t=this.value;if(Hm(t))throw t.cause;return t};i.prototype.peek=function(){var t=this.computeValue(false);if(Hm(t))throw t.cause;return t};i.prototype.set=function(t){if(this.setter){ma(!this.isRunningSetter,"The setter of computed value '"+this.name+"' is trying to update itself. Did you intend to update an _observable_ value, instead of the computed property?");this.isRunningSetter=true;try{this.setter.call(this.scope,t)}finally{this.isRunningSetter=false}}else ma(false,false)};i.prototype.trackAndCompute=function(){if(bi()){Bl({object:this.scope,type:"compute",name:this.name})}var t=this.value;var e=this.dependenciesState===Yt.NOT_TRACKING;var r=this.computeValue(true);var o=e||Hm(t)||Hm(r)||!this.equals(t,r);if(o){this.value=r}return o};i.prototype.computeValue=function(t){this.isComputing=true;lt.computationDepth++;var e;if(t){e=QD(this,this.derivation,this.scope)}else{if(lt.disableErrorBoundaries===true){e=this.derivation.call(this.scope)}else{try{e=this.derivation.call(this.scope)}catch(r){e=new gg(r)}}}lt.computationDepth--;this.isComputing=false;return e};i.prototype.suspend=function(){if(!this.keepAlive){Sv(this);this.value=void 0}};i.prototype.observe=function(t,e){var r=this;var o=true;var n=void 0;return qJ(function(){var s=r.get();if(!o||e){var a=Hu();t({type:"update",object:r,newValue:s,oldValue:n});pa(a)}o=false;n=s})};i.prototype.warnAboutUntrackedRead=function(){if(true)return;if(this.requiresReaction===true){me("[mobx] Computed value "+this.name+" is read outside a reactive context")}if(this.isTracing!==xo.NONE){console.log("[mobx.trace] '"+this.name+"' is being read outside a reactive context. Doing a full recompute")}if(lt.computedRequiresReaction){console.warn("[mobx] Computed value "+this.name+" is being read outside a reactive context. Doing a full recompute")}};i.prototype.toJSON=function(){return this.get()};i.prototype.toString=function(){return this.name+"["+this.derivation.toString()+"]"};i.prototype.valueOf=function(){return $D(this.get())};return i}();fa.prototype[jD()]=fa.prototype.valueOf;wg=ya("ComputedValue",fa);dg=function(){function i(){this.version=5;this.UNCHANGED={};this.trackingDerivation=null;this.computationDepth=0;this.runId=0;this.mobxGuid=0;this.inBatch=0;this.pendingUnobservations=[];this.pendingReactions=[];this.isRunningReactions=false;this.allowStateChanges=true;this.allowStateReads=true;this.enforceActions=false;this.spyListeners=[];this.globalReactionErrorHandlers=[];this.computedRequiresReaction=false;this.reactionRequiresObservable=false;this.observableRequiresReaction=false;this.computedConfigurable=false;this.disableErrorBoundaries=false;this.suppressReactionErrors=false}return i}();mg=true;rE=false;lt=function(){var i=Wm();if(i.__mobxInstanceCount>0&&!i.__mobxGlobals)mg=false;if(i.__mobxGlobals&&i.__mobxGlobals.version!==new dg().version)mg=false;if(!mg){setTimeout(function(){if(!rE){me("There are multiple, different versions of MobX active. Make sure MobX is loaded only once or use `configure({ isolateGlobalState: true })`")}},1);return new dg}else if(i.__mobxGlobals){i.__mobxInstanceCount+=1;if(!i.__mobxGlobals.UNCHANGED)i.__mobxGlobals.UNCHANGED={};return i.__mobxGlobals}else{i.__mobxInstanceCount=1;return i.__mobxGlobals=new dg}}();ga=function(){function i(t,e,r,o){if(t===void 0){t="Reaction@"+Cr()}if(o===void 0){o=false}this.name=t;this.onInvalidate=e;this.errorHandler=r;this.requiresObservable=o;this.observing=[];this.newObserving=[];this.dependenciesState=Yt.NOT_TRACKING;this.diffValue=0;this.runId=0;this.unboundDepsCount=0;this.__mapid="#"+Cr();this.isDisposed=false;this._isScheduled=false;this._isTrackPending=false;this._isRunning=false;this.isTracing=xo.NONE}i.prototype.onBecomeStale=function(){this.schedule()};i.prototype.schedule=function(){if(!this._isScheduled){this._isScheduled=true;lt.pendingReactions.push(this);cE()}};i.prototype.isScheduled=function(){return this._isScheduled};i.prototype.runReaction=function(){if(!this.isDisposed){ns();this._isScheduled=false;if(Cv(this)){this._isTrackPending=true;try{this.onInvalidate();if(this._isTrackPending&&bi()){Bl({name:this.name,type:"scheduled-reaction"})}}catch(t){this.reportExceptionInDerivation(t)}}ss()}};i.prototype.track=function(t){ns();var e=bi();var r;if(e){r=Date.now();vo({name:this.name,type:"reaction"})}this._isRunning=true;var o=QD(this,t,void 0);this._isRunning=false;this._isTrackPending=false;if(this.isDisposed){Sv(this)}if(Hm(o))this.reportExceptionInDerivation(o.cause);if(e){Co({time:Date.now()-r})}ss()};i.prototype.reportExceptionInDerivation=function(t){var e=this;if(this.errorHandler){this.errorHandler(t,this);return}if(lt.disableErrorBoundaries)throw t;var r="[mobx] Encountered an uncaught exception that was thrown by a reaction or observer component, in: '"+this+"'";if(lt.suppressReactionErrors){console.warn("[mobx] (error in reaction '"+this.name+"' suppressed, fix error of causing action below)")}else{console.error(r,t)}if(bi()){Bl({type:"error",name:this.name,message:r,error:""+t})}lt.globalReactionErrorHandlers.forEach(function(o){return o(t,e)})};i.prototype.dispose=function(){if(!this.isDisposed){this.isDisposed=true;if(!this._isRunning){ns();Sv(this);ss()}}};i.prototype.getDisposer=function(){var t=this.dispose.bind(this);t.$mobx=this;return t};i.prototype.toString=function(){return"Reaction["+this.name+"]"};i.prototype.trace=function(t){if(t===void 0){t=false}oZ(this,t)};return i}();LD=100;wv=function(i){return i()};yg=ya("Reaction",ga);jJ={spyReportEnd:true};C=function i(t,e,r,o){if(arguments.length===1&&typeof t==="function")return Ol(t.name||"<unnamed action>",t);if(arguments.length===2&&typeof e==="function")return Ol(t,e);if(arguments.length===1&&typeof t==="string")return zD(t);if(o===true){t[e]=Ol(t.name||e,r.value)}else{return zD(e).apply(null,arguments)}};C.bound=XJ;YJ=function(i){return i()};tZ.prototype=Object.create(Error.prototype);rZ={detectCycles:true,exportMapsAsObjects:true,recurseEverything:false};sZ=1e4;aZ=function(){var i=false;var t={};Object.defineProperty(t,"0",{set:function(){i=true}});Object.create(t)["0"]=1;return i===false}();Tv=0;Mv=function(){function i(){}return i}();lZ(Mv,Array.prototype);if(Object.isFrozen(Array)){["constructor","push","shift","concat","pop","unshift","replace","find","findIndex","splice","reverse","sort"].forEach(function(i){Object.defineProperty(Mv.prototype,i,{configurable:true,writable:true,value:Array.prototype[i]})})}pE=function(){function i(t,e,r,o){this.array=r;this.owned=o;this.values=[];this.lastKnownLength=0;this.atom=new xg(t||"ObservableArray@"+Cr());this.enhancer=function(n,s){return e(n,s,t+"[..]")}}i.prototype.dehanceValue=function(t){if(this.dehancer!==void 0)return this.dehancer(t);return t};i.prototype.dehanceValues=function(t){if(this.dehancer!==void 0&&t.length>0)return t.map(this.dehancer);return t};i.prototype.intercept=function(t){return qm(this,t)};i.prototype.observe=function(t,e){if(e===void 0){e=false}if(e){t({object:this.array,type:"splice",index:0,added:this.values.slice(),addedCount:this.values.length,removed:[],removedCount:0})}return Ym(this,t)};i.prototype.getArrayLength=function(){this.atom.reportObserved();return this.values.length};i.prototype.setArrayLength=function(t){if(typeof t!=="number"||t<0)throw new Error("[mobx.array] Out of range: "+t);var e=this.values.length;if(t===e)return;else if(t>e){var r=new Array(t-e);for(var o=0;o<t-e;o++)r[o]=void 0;this.spliceWithArray(e,0,r)}else this.spliceWithArray(t,e-t)};i.prototype.updateArrayLength=function(t,e){if(t!==this.lastKnownLength)throw new Error("[mobx] Modification exception: the internal structure of an observable array was changed. Did you use peek() to change it?");this.lastKnownLength+=e;if(e>0&&t+e+1>Tv)Lv(t+e+1)};i.prototype.spliceWithArray=function(t,e,r){var o=this;zu(this.atom);var n=this.values.length;if(t===void 0)t=0;else if(t>n)t=n;else if(t<0)t=Math.max(0,n+t);if(arguments.length===1)e=n-t;else if(e===void 0||e===null)e=0;else e=Math.max(0,Math.min(e,n-t));if(r===void 0)r=pg;if(rn(this)){var s=on(this,{object:this.array,type:"splice",index:t,removedCount:e,added:r});if(!s)return pg;e=s.removedCount;r=s.added}r=r.length===0?r:r.map(function(c){return o.enhancer(c,void 0)});var a=r.length-e;this.updateArrayLength(n,a);var l=this.spliceItemsIntoValues(t,e,r);if(e!==0||r.length!==0)this.notifyArraySplice(t,r,l);return this.dehanceValues(l)};i.prototype.spliceItemsIntoValues=function(t,e,r){var o;if(r.length<sZ){return(o=this.values).splice.apply(o,vv([t,e],r))}else{var n=this.values.slice(t,t+e);this.values=this.values.slice(0,t).concat(r,this.values.slice(t+e));return n}};i.prototype.notifyArrayChildUpdate=function(t,e,r){var o=!this.owned&&bi();var n=So(this);var s=n||o?{object:this.array,type:"update",index:t,newValue:e,oldValue:r}:null;if(o)vo(Fe(Fe({},s),{name:this.atom.name}));this.atom.reportChanged();if(n)wo(this,s);if(o)Co()};i.prototype.notifyArraySplice=function(t,e,r){var o=!this.owned&&bi();var n=So(this);var s=n||o?{object:this.array,type:"splice",index:t,removed:r,added:e,removedCount:r.length,addedCount:e.length}:null;if(o)vo(Fe(Fe({},s),{name:this.atom.name}));this.atom.reportChanged();if(n)wo(this,s);if(o)Co()};return i}();nn=function(i){qD(t,i);function t(e,r,o,n){if(o===void 0){o="ObservableArray@"+Cr()}if(n===void 0){n=false}var s=i.call(this)||this;var a=new pE(o,r,s,n);Vm(s,"$mobx",a);if(e&&e.length){var l=Km(true);s.spliceWithArray(0,0,e);Xm(l)}if(aZ){Object.defineProperty(a.array,"0",cZ)}return s}t.prototype.intercept=function(e){return this.$mobx.intercept(e)};t.prototype.observe=function(e,r){if(r===void 0){r=false}return this.$mobx.observe(e,r)};t.prototype.clear=function(){return this.splice(0)};t.prototype.concat=function(){var e=[];for(var r=0;r<arguments.length;r++){e[r]=arguments[r]}this.$mobx.atom.reportObserved();return Array.prototype.concat.apply(this.peek(),e.map(function(o){return Ll(o)?o.peek():o}))};t.prototype.replace=function(e){return this.$mobx.spliceWithArray(0,this.$mobx.values.length,e)};t.prototype.toJS=function(){return this.slice()};t.prototype.toJSON=function(){return this.toJS()};t.prototype.peek=function(){this.$mobx.atom.reportObserved();return this.$mobx.dehanceValues(this.$mobx.values)};t.prototype.find=function(e,r,o){if(o===void 0){o=0}if(arguments.length===3)is("The array.find fromIndex argument to find will not be supported anymore in the next major");var n=this.findIndex.apply(this,arguments);return n===-1?void 0:this.get(n)};t.prototype.findIndex=function(e,r,o){if(o===void 0){o=0}if(arguments.length===3)is("The array.findIndex fromIndex argument to find will not be supported anymore in the next major");var n=this.peek(),s=n.length;for(var a=o;a<s;a++)if(e.call(r,n[a],a,this))return a;return-1};t.prototype.splice=function(e,r){var o=[];for(var n=2;n<arguments.length;n++){o[n-2]=arguments[n]}switch(arguments.length){case 0:return[];case 1:return this.$mobx.spliceWithArray(e);case 2:return this.$mobx.spliceWithArray(e,r)}return this.$mobx.spliceWithArray(e,r,o)};t.prototype.spliceWithArray=function(e,r,o){return this.$mobx.spliceWithArray(e,r,o)};t.prototype.push=function(){var e=[];for(var r=0;r<arguments.length;r++){e[r]=arguments[r]}var o=this.$mobx;o.spliceWithArray(o.values.length,0,e);return o.values.length};t.prototype.pop=function(){return this.splice(Math.max(this.$mobx.values.length-1,0),1)[0]};t.prototype.shift=function(){return this.splice(0,1)[0]};t.prototype.unshift=function(){var e=[];for(var r=0;r<arguments.length;r++){e[r]=arguments[r]}var o=this.$mobx;o.spliceWithArray(0,0,e);return o.values.length};t.prototype.reverse=function(){var e=this.slice();return e.reverse.apply(e,arguments)};t.prototype.sort=function(e){var r=this.slice();return r.sort.apply(r,arguments)};t.prototype.remove=function(e){var r=this.$mobx.dehanceValues(this.$mobx.values).indexOf(e);if(r>-1){this.splice(r,1);return true}return false};t.prototype.move=function(e,r){is("observableArray.move is deprecated, use .slice() & .replace() instead");function o(a){if(a<0){throw new Error("[mobx.array] Index out of bounds: "+a+" is negative")}var l=this.$mobx.values.length;if(a>=l){throw new Error("[mobx.array] Index out of bounds: "+a+" is not smaller than "+l)}}o.call(this,e);o.call(this,r);if(e===r){return}var n=this.$mobx.values;var s;if(e<r){s=vv(n.slice(0,e),n.slice(e+1,r+1),[n[e]],n.slice(r+1))}else{s=vv(n.slice(0,r),[n[e]],n.slice(r,e),n.slice(e+1))}this.replace(s)};t.prototype.get=function(e){var r=this.$mobx;if(r){if(e<r.values.length){r.atom.reportObserved();return r.dehanceValue(r.values[e])}console.warn("[mobx.array] Attempt to read an array index ("+e+") that is out of bounds ("+r.values.length+"). Please check length first. Out of bound indices will not be tracked by MobX")}return void 0};t.prototype.set=function(e,r){var o=this.$mobx;var n=o.values;if(e<n.length){zu(o.atom);var s=n[e];if(rn(o)){var a=on(o,{type:"update",object:this,index:e,newValue:r});if(!a)return;r=a.newValue}r=o.enhancer(r,s);var l=r!==s;if(l){n[e]=r;o.notifyArrayChildUpdate(e,r,s)}}else if(e===n.length){o.spliceWithArray(e,0,[r])}else{throw new Error("[mobx.array] Index out of bounds, "+e+" is larger than "+n.length)}};return t}(Mv);Ev(nn.prototype,function(){this.$mobx.atom.reportObserved();var i=this;var t=0;return Gm({next:function(){return t<i.length?{value:i[t++],done:false}:{done:true,value:void 0}}})});Object.defineProperty(nn.prototype,"length",{enumerable:false,configurable:true,get:function(){return this.$mobx.getArrayLength()},set:function(i){this.$mobx.setArrayLength(i)}});as(nn.prototype,Fv(),"Array");["indexOf","join","lastIndexOf","slice","toString","toLocaleString"].forEach(function(i){var t=Array.prototype[i];ma(typeof t==="function","Base function not defined on Array prototype: '"+i+"'");as(nn.prototype,i,function(){return t.apply(this.peek(),arguments)})});["every","filter","forEach","map","some"].forEach(function(i){var t=Array.prototype[i];ma(typeof t==="function","Base function not defined on Array prototype: '"+i+"'");as(nn.prototype,i,function(e,r){var o=this;var n=this.$mobx;n.atom.reportObserved();var s=n.dehanceValues(n.values);return s[i](function(a,l){return e.call(r,a,l,o)},r)})});["reduce","reduceRight"].forEach(function(i){as(nn.prototype,i,function(){var t=this;var e=this.$mobx;e.atom.reportObserved();var r=arguments[0];arguments[0]=function(o,n,s){n=e.dehanceValue(n);return r(o,n,s,t)};return e.values[i].apply(e.values,arguments)})});pJ(nn.prototype,["constructor","intercept","observe","clear","concat","get","replace","toJS","toJSON","peek","find","findIndex","splice","spliceWithArray","push","pop","set","shift","unshift","reverse","sort","remove","move","toString","toLocaleString"]);cZ=hE(0);Lv(1e3);dZ=ya("ObservableArrayAdministration",pE);mZ={};kg=function(){function i(t,e,r){if(e===void 0){e=$m}if(r===void 0){r="ObservableMap@"+Cr()}this.enhancer=e;this.name=r;this.$mobx=mZ;this._keysAtom=vg(this.name+".keys()");if(typeof Map!=="function"){throw new Error("mobx.map requires Map polyfill for the current browser. Check babel-polyfill or core-js/es6/map.js")}this._data=new Map;this._hasMap=new Map;this.merge(t)}i.prototype._has=function(t){return this._data.has(t)};i.prototype.has=function(t){var e=this;if(!lt.trackingDerivation)return this._has(t);var r=this._hasMap.get(t);if(!r){var o=r=new ha(this._has(t),Cg,this.name+"."+ug(t)+"?",false);this._hasMap.set(t,o);uE(o,function(){return e._hasMap.delete(t)})}return r.get()};i.prototype.set=function(t,e){var r=this._has(t);if(rn(this)){var o=on(this,{type:r?"update":"add",object:this,newValue:e,name:t});if(!o)return this;e=o.newValue}if(r){this._updateValue(t,e)}else{this._addValue(t,e)}return this};i.prototype.delete=function(t){var e=this;zu(this._keysAtom);if(rn(this)){var r=on(this,{type:"delete",object:this,name:t});if(!r)return false}if(this._has(t)){var o=bi();var n=So(this);var r=n||o?{type:"delete",object:this,oldValue:this._data.get(t).value,name:t}:null;if(o)vo(Fe(Fe({},r),{name:this.name,key:t}));en(function(){e._keysAtom.reportChanged();e._updateHasMapEntry(t,false);var a=e._data.get(t);a.setNewValue(void 0);e._data.delete(t)});if(n)wo(this,r);if(o)Co();return true}return false};i.prototype._updateHasMapEntry=function(t,e){var r=this._hasMap.get(t);if(r){r.setNewValue(e)}};i.prototype._updateValue=function(t,e){var r=this._data.get(