1import{c as ao,g as uo}from"./react-CydE4nCL.js";(function(){try{var pe=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};pe.SENTRY_RELEASE={id:"a156a80817bcc286d094871909811f8803ba8360"};var Vn=new pe.Error().stack;Vn&&(pe._sentryDebugIds=pe._sentryDebugIds||{},pe._sentryDebugIds[Vn]="495b74e2-0218-4bff-80f3-7be9fcdfc265",pe._sentryDebugIdIdentifier="sentry-dbid-495b74e2-0218-4bff-80f3-7be9fcdfc265")}catch(fn){}})();var Un={exports:{}},so=Un.exports,wr;function co(){return wr||(wr=1,(function(pe,Vn){((fn,T)=>{pe.exports=T()})(so,function(){var fn=function(e,n){return(fn=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,r){t.__proto__=r}:function(t,r){for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(t[o]=r[o])}))(e,n)},T=function(){return(T=Object.assign||function(e){for(var n,t=1,r=arguments.length;t<r;t++)for(var o in n=arguments[t])Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o]);return e}).apply(this,arguments)};function hn(e,n,t){for(var r,o=0,i=n.length;o<i;o++)!r&&o in n||((r=r||Array.prototype.slice.call(n,0,o))[o]=n[o]);return e.concat(r||Array.prototype.slice.call(n))}var Q=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:ao,W=Object.keys,U=Array.isArray;function ee(e,n){return typeof n=="object"&&W(n).forEach(function(t){e[t]=n[t]}),e}typeof Promise>"u"||Q.Promise||(Q.Promise=Promise);var Ie=Object.getPrototypeOf,xr={}.hasOwnProperty;function ne(e,n){return xr.call(e,n)}function qe(e,n){typeof n=="function"&&(n=n(Ie(e))),(typeof Reflect>"u"?W:Reflect.ownKeys)(n).forEach(function(t){ye(e,t,n[t])})}var Ct=Object.defineProperty;function ye(e,n,t,r){Ct(e,n,ee(t&&ne(t,"get")&&typeof t.get=="function"?{get:t.get,set:t.set,configurable:!0}:{value:t,configurable:!0,writable:!0},r))}function Re(e){return{from:function(n){return e.prototype=Object.create(n.prototype),ye(e.prototype,"constructor",e),{extend:qe.bind(null,e.prototype)}}}}var kr=Object.getOwnPropertyDescriptor,Or=[].slice;function dn(e,n,t){return Or.call(e,n,t)}function Dt(e,n){return n(e)}function Qe(e){if(!e)throw new Error("Assertion Failed")}function Tt(e){Q.setImmediate?setImmediate(e):setTimeout(e,0)}function se(e,n){if(typeof n=="string"&&ne(e,n))return e[n];if(!n)return e;if(typeof n!="string"){for(var t=[],r=0,o=n.length;r<o;++r){var i=se(e,n[r]);t.push(i)}return t}var a,u=n.indexOf(".");return u===-1||(a=e[n.substr(0,u)])==null?void 0:se(a,n.substr(u+1))}function Z(e,n,t){if(e&&n!==void 0&&!("isFrozen"in Object&&Object.isFrozen(e)))if(typeof n!="string"&&"length"in n){Qe(typeof t!="string"&&"length"in t);for(var r=0,o=n.length;r<o;++r)Z(e,n[r],t[r])}else{var i=n.indexOf(".");if(i!==-1){var a=n.substr(0,i),i=n.substr(i+1);if(i==="")t===void 0?U(e)&&!isNaN(parseInt(a))?e.splice(a,1):delete e[a]:e[a]=t;else{var u=e[a];if(!u||!ne(e,a)){if(t===void 0)return;u=e[a]={}}Z(u,i,t)}}else t===void 0?U(e)&&!isNaN(parseInt(n))?e.splice(n,1):delete e[n]:e[n]=t}}function It(e){var n,t={};for(n in e)ne(e,n)&&(t[n]=e[n]);return t}var Pr=[].concat;function qt(e){return Pr.apply([],e)}var le="BigUint64Array,BigInt64Array,Array,Boolean,String,Date,RegExp,Blob,File,FileList,FileSystemFileHandle,FileSystemDirectoryHandle,ArrayBuffer,DataView,Uint8ClampedArray,ImageBitmap,ImageData,Map,Set,CryptoKey".split(",").concat(qt([8,16,32,64].map(function(e){return["Int","Uint","Float"].map(function(n){return n+e+"Array"})}))).filter(function(e){return Q[e]}),Rt=new Set(le.map(function(e){return Q[e]})),Ge=null;function xe(e){return Ge=new WeakMap,e=(function n(t){if(!t||typeof t!="object")return t;var r=Ge.get(t);if(r)return r;if(U(t)){r=[],Ge.set(t,r);for(var o=0,i=t.length;o<i;++o)r.push(n(t[o]))}else if(Rt.has(t.constructor))r=t;else{var a,u=Ie(t);for(a in r=u===Object.prototype?{}:Object.create(u),Ge.set(t,r),t)ne(t,a)&&(r[a]=n(t[a]))}return r})(e),Ge=null,e}var Er={}.toString;function zn(e){return Er.call(e).slice(8,-1)}var Wn=typeof Symbol<"u"?Symbol.iterator:"@@iterator",Kr=typeof Wn=="symbol"?function(e){var n;return e!=null&&(n=e[Wn])&&n.apply(e)}:function(){return null};function ke(e,n){n=e.indexOf(n),0<=n&&e.splice(n,1)}var Be={};function ce(e){var n,t,r,o;if(arguments.length===1){if(U(e))return e.slice();if(this===Be&&typeof e=="string")return[e];if(o=Kr(e))for(t=[];!(r=o.next()).done;)t.push(r.value);else{if(e==null)return[e];if(typeof(n=e.length)!="number")return[e];for(t=new Array(n);n--;)t[n]=e[n]}}else for(n=arguments.length,t=new Array(n);n--;)t[n]=arguments[n];return t}var Yn=typeof Symbol<"u"?function(e){return e[Symbol.toStringTag]==="AsyncFunction"}:function(){return!1}
1,le=["Unknown","Constraint","Data","TransactionInactive","ReadOnly","Version","NotFound","InvalidState","InvalidAccess","Abort","Timeout","QuotaExceeded","Syntax","DataClone"],te=["Modify","Bulk","OpenFailed","VersionChange","Schema","Upgrade","InvalidTable","MissingAPI","NoSuchDatabase","InvalidArgument","SubTransaction","Unsupported","Internal","DatabaseClosed","PrematureCommit","ForeignAwait"].concat(le),Sr={VersionChanged:"Database version changed by other database connection",DatabaseClosed:"Database has been closed",Abort:"Transaction aborted",TransactionInactive:"Transaction has already completed or failed",MissingAPI:"IndexedDB API missing. Please visit https://tinyurl.com/y2uuvskb"};function Fe(e,n){this.name=e,this.message=n}function Bt(e,n){return e+". Errors: "+Object.keys(n).map(function(t){return n[t].toString()}).filter(function(t,r,o){return o.indexOf(t)===r}).join("\n")}function pn(e,n,t,r){this.failures=n,this.failedKeys=r,this.successCount=t,this.message=Bt(e,n)}function Ne(e,n){this.name="BulkError",this.failures=Object.keys(n).map(function(t){return n[t]}),this.failuresByPos=n,this.message=Bt(e,this.failures)}Re(Fe).from(Error).extend({toString:function(){return this.name+": "+this.message}}),Re(pn).from(Fe),Re(Ne).from(Fe);var $n=te.reduce(function(e,n){return e[n]=n+"Error",e},{}),Ar=Fe,j=te.reduce(function(e,n){var t=n+"Error";function r(o,i){this.name=t,o?typeof o=="string"?(this.message="".concat(o).concat(i?"\n "+i:""),this.inner=i||null):typeof o=="object"&&(this.message="".concat(o.name," ").concat(o.message),this.inner=o):(this.message=Sr[n]||t,this.inner=null)}return Re(r).from(Ar),e[n]=r,e},{}),Ft=(j.Syntax=SyntaxError,j.Type=TypeError,j.Range=RangeError,le.reduce(function(e,n){return e[n+"Error"]=j[n],e},{}));le=te.reduce(function(e,n){return["Syntax","Type","Range"].indexOf(n)===-1&&(e[n+"Error"]=j[n]),e},{});function N(){}function Xe(e){return e}function jr(e,n){return e==null||e===Xe?n:function(t){return n(e(t))}}function Oe(e,n){return function(){e.apply(this,arguments),n.apply(this,arguments)}}function Cr(e,n){return e===N?n:function(){var t=e.apply(this,arguments),r=(t!==void 0&&(arguments[0]=t),this.onsuccess),o=this.onerror,i=(this.onsuccess=null,this.onerror=null,n.apply(this,arguments));return r&&(this.onsuccess=this.onsuccess?Oe(r,this.onsuccess):r),o&&(this.onerror=this.onerror?Oe(o,this.onerror):o),i!==void 0?i:t}}function Dr(e,n){return e===N?n:function(){e.apply(this,arguments);var t=this.onsuccess,r=this.onerror;this.onsuccess=this.onerror=null,n.apply(this,arguments),t&&(this.onsuccess=this.onsuccess?Oe(t,this.onsuccess):t),r&&(this.onerror=this.onerror?Oe(r,this.onerror):r)}}function Tr(e,n){return e===N?n:function(o){var r=e.apply(this,arguments),o=(ee(o,r),this.onsuccess),i=this.onerror,a=(this.onsuccess=null,this.onerror=null,n.apply(this,arguments));return o&&(this.onsuccess=this.onsuccess?Oe(o,this.onsuccess):o),i&&(this.onerror=this.onerror?Oe(i,this.onerror):i),r===void 0?a===void 0?void 0:a:ee(r,a)}}function Ir(e,n){return e===N?n:function(){return n.apply(this,arguments)!==!1&&e.apply(this,arguments)}}function Qn(e,n){return e===N?n:function(){var t=e.apply(this,arguments);if(t&&typeof t.then=="function"){for(var r=this,o=arguments.length,i=new Array(o);o--;)i[o]=arguments[o];return t.then(function(){return n.apply(r,i)})}return n.apply(this,arguments)}}le.ModifyError=pn,le.DexieError=Fe,le.BulkError=Ne;var ae=typeof location<"u"&&/^(http|https):\/\/(localhost|127\.0\.0\.1)/.test(location.href);function Nt(e){ae=e}var He={},Mt=100,Je=typeof Promise>"u"?[]:(te=Promise.resolve(),typeof crypto<"u"&&crypto.subtle?[Je=crypto.subtle.digest("SHA-512",new Uint8Array([0])),Ie(Je),te]:[te,Ie(te),te]),te=Je[0],Ye=Je[1],Ye=Ye&&Ye.then,Pe=te&&te.constructor,Gn=!!Je[2],Ze=function(e,n){en.push([e,n]),yn&&(queueMicrotask(Rr),yn=!1)},Xn=!0,yn=!0,Ee=[],mn=[],Hn=Xe,fe={id:"global",global:!0,ref:0,unhandleds:[],onunhandled:N,pgp:!1,env:{},finalize:N},A=fe,en=[],Ke=0,vn=[];function E(e){if(typeof this!="object")throw new TypeError("Promises must be constructed via new");this._listeners=[],this._lib=!1;var n=this._PSD=A;if(typeof e!="function"){if(e!==He)throw new TypeError("Not a function");this._state=arguments[1],this._value=arguments[2],this._state===!1&&Zn(this,this._value)}else this._state=null,this._value=null,++n.ref,(function t(r,o){try{o(function(i){if(r._state===null){if(i===r)throw new TypeError("A promise cannot be resolved with itself.");var a=r._lib&&Me();i&&typeof i.then=="function"?t(r,function(u,c){i instanceof E?i._then(u,c):i.then(u,c)}):(r._state=!0,r._value=i,Ut(r)),a&&Le()}},Zn.bind(null,r))}catch(i){Zn(r,i)}})(this,e)}var Jn={get:function(){var e=A,n=_n;function t(r,o){var i=this,a=!e.global&&(e!==A||n!==_n),u=a&&!ve(),c=new E(function(m,f){et(i,new Lt(zt(r,e,a,u),zt(o,e,a,u),m,f,e))});return this._consoleTask&&(c._consoleTask=this._consoleTask),c}return t.prototype=He,t},set:function(e){ye(this,"then",e&&e.prototype===He?Jn:{get:function(){return e},set:Jn.set})}};function Lt(e,n,t,r,o){this.onFulfilled=typeof e=="function"?e:null,this.onRejected=typeof n=="function"?n:null,this.resolve=t,this.reject=r,this.psd=o}function Zn(e,n){var t,r;mn.push(n),e._state===null&&(t=e._lib&&Me(),n=Hn(n),e._state=!1,e._value=n,r=e,Ee.some(function(o){return o._value===r._value})||Ee.push(r),Ut(e),t)&&Le()}function Ut(e){var n=e._listeners;e._listeners=[];for(var t=0,r=n.length;t<r;++t)et(e,n[t]);var o=e._PSD;--o.ref||o.finalize(),Ke===0&&(++Ke,Ze(function(){--Ke==0&&nt()},[]))}function et(e,n){if(e._state===null)e._listeners.push(n);else{var t=e._state?n.onFulfilled:n.onRejected;if(t===null)return(e._state?n.resolve:n.reject)(e._value);++n.psd.ref,++Ke,Ze(qr,[t,e,n])}}function qr(e,n,t){try{var r,o=n._value;!n._state&&mn.length&&(mn=[]),r=ae&&n._consoleTask?n._consoleTask.run(function(){return e(o)}):e(o),n._state||mn.indexOf(o)!==-1||(i=>{for(var a=Ee.length;a;)if(Ee[--a]._value===i._value)return Ee.splice(a,1)})(n),t.resolve(r)}catch(i){t.reject(i)}finally{--Ke==0&&nt(),--t.psd.ref||t.psd.finalize()}}function Rr(){Se(fe,function(){Me()&&Le()})}function Me(){var e=Xn;return yn=Xn=!1,e}function Le(){var e,n,t;do for(;0<en.length;)for(e=en,en=[],t=e.length,n=0;n<t;++n){var r=e[n];r[0].apply(null,r[1])}while(0<en.length);yn=Xn=!0}function nt(){for(var e=Ee,n=(Ee=[],e.forEach(function(r){r._PSD.onunhandled.call(null,r._value,r)}),vn.slice(0)),t=n.length;t;)n[--t]()}function gn(e){return new E(He,!1,e)}function L(e,n){var t=A;return function(){var r=Me(),o=A;try{return ge(t,!0),e.apply(this,arguments)}catch(i){n&&n(i)}finally{ge(o,!1),r&&Le()}}}
1qe(E.prototype,{then:Jn,_then:function(e,n){et(this,new Lt(null,null,e,n,A))},catch:function(e){var n,t;return arguments.length===1?this.then(null,e):(n=e,t=arguments[1],typeof n=="function"?this.then(null,function(r){return(r instanceof n?t:gn)(r)}):this.then(null,function(r){return(r&&r.name===n?t:gn)(r)}))},finally:function(e){return this.then(function(n){return E.resolve(e()).then(function(){return n})},function(n){return E.resolve(e()).then(function(){return gn(n)})})},timeout:function(e,n){var t=this;return e<1/0?new E(function(r,o){var i=setTimeout(function(){return o(new j.Timeout(n))},e);t.then(r,o).finally(clearTimeout.bind(null,i))}):this}}),typeof Symbol<"u"&&Symbol.toStringTag&&ye(E.prototype,Symbol.toStringTag,"Dexie.Promise"),fe.env=Vt(),qe(E,{all:function(){var e=ce.apply(null,arguments).map(xn);return new E(function(n,t){e.length===0&&n([]);var r=e.length;e.forEach(function(o,i){return E.resolve(o).then(function(a){e[i]=a,--r||n(e)},t)})})},resolve:function(e){return e instanceof E?e:e&&typeof e.then=="function"?new E(function(n,t){e.then(n,t)}):new E(He,!0,e)},reject:gn,race:function(){var e=ce.apply(null,arguments).map(xn);return new E(function(n,t){e.map(function(r){return E.resolve(r).then(n,t)})})},PSD:{get:function(){return A},set:function(e){return A=e}},totalEchoes:{get:function(){return _n}},newPSD:me,usePSD:Se,scheduler:{get:function(){return Ze},set:function(e){Ze=e}},rejectionMapper:{get:function(){return Hn}
1,set:function(e){Hn=e}},follow:function(e,n){return new E(function(t,r){return me(function(o,i){var a=A;a.unhandleds=[],a.onunhandled=i,a.finalize=Oe(function(){var u,c=this;u=function(){c.unhandleds.length===0?o():i(c.unhandleds[0])},vn.push(function m(){u(),vn.splice(vn.indexOf(m),1)}),++Ke,Ze(function(){--Ke==0&&nt()},[])},a.finalize),e()},n,t,r)})}}),Pe&&(Pe.allSettled&&ye(E,"allSettled",function(){var e=ce.apply(null,arguments).map(xn);return new E(function(n){e.length===0&&n([]);var t=e.length,r=new Array(t);e.forEach(function(o,i){return E.resolve(o).then(function(a){return r[i]={status:"fulfilled",value:a}},function(a){return r[i]={status:"rejected",reason:a}}).then(function(){return--t||n(r)})})})}),Pe.any&&typeof AggregateError<"u"&&ye(E,"any",function(){var e=ce.apply(null,arguments).map(xn);return new E(function(n,t){e.length===0&&t(new AggregateError([]));var r=e.length,o=new Array(r);e.forEach(function(i,a){return E.resolve(i).then(function(u){return n(u)},function(u){o[a]=u,--r||t(new AggregateError(o))})})})}),Pe.withResolvers)&&(E.withResolvers=Pe.withResolvers);var Y={awaits:0,echoes:0,id:0},Br=0,bn=[],wn=0,_n=0,Fr=0;function me(e,a,t,r){var o=A,i=Object.create(o),a=(i.parent=o,i.ref=0,i.global=!1,i.id=++Fr,fe.env,i.env=Gn?{Promise:E,PromiseProp:{value:E,configurable:!0,writable:!0},all:E.all,race:E.race,allSettled:E.allSettled,any:E.any,resolve:E.resolve,reject:E.reject}:{},a&&ee(i,a),++o.ref,i.finalize=function(){--this.parent.ref||this.parent.finalize()},Se(i,e,t,r));return i.ref===0&&i.finalize(),a}function Ue(){return Y.id||(Y.id=++Br),++Y.awaits,Y.echoes+=Mt,Y.id}function ve(){return!!Y.awaits&&(--Y.awaits==0&&(Y.id=0),Y.echoes=Y.awaits*Mt,!0)}function xn(e){return Y.echoes&&e&&e.constructor===Pe?(Ue(),e.then(function(n){return ve(),n},function(n){return ve(),V(n)})):e}function Nr(){var e=bn[bn.length-1];bn.pop(),ge(e,!1)}function ge(e,n){var t,r,o=A;(n?!Y.echoes||wn++&&e===A:!wn||--wn&&e===A)||queueMicrotask(n?(function(i){++_n,Y.echoes&&--Y.echoes!=0||(Y.echoes=Y.awaits=Y.id=0),bn.push(A),ge(i,!0)}).bind(null,e):Nr),e!==A&&(A=e,o===fe&&(fe.env=Vt()),Gn)&&(t=fe.env.Promise,r=e.env,o.global||e.global)&&(Object.defineProperty(Q,"Promise",r.PromiseProp),t.all=r.all,t.race=r.race,t.resolve=r.resolve,t.reject=r.reject,r.allSettled&&(t.allSettled=r.allSettled),r.any)&&(t.any=r.any)}function Vt(){var e=Q.Promise;return Gn?{Promise:e,PromiseProp:Object.getOwnPropertyDescriptor(Q,"Promise"),all:e.all,race:e.race,allSettled:e.allSettled,any:e.any,resolve:e.resolve,reject:e.reject}:{}}function Se(e,n,t,r,o){var i=A;try{return ge(e,!0),n(t,r,o)}finally{ge(i,!1)}}function zt(e,n,t,r){return typeof e!="function"?e:function(){var o=A;t&&Ue(),ge(n,!0);try{return e.apply(this,arguments)}finally{ge(o,!1),r&&queueMicrotask(ve)}}}function tt(e){Promise===Pe&&Y.echoes===0?wn===0?e():enqueueNativeMicroTask(e):setTimeout(e,0)}(""+Ye).indexOf("[native code]")===-1&&(Ue=ve=N);var V=E.reject,Ae="ï¿¿",he="Invalid key provided. Keys must be of type string, number, Date or Array<string | number | Date>.",Wt="String expected.",kn="__dbnames",rt="readonly",ot="readwrite";function je(e,n){return e?n?function(){return e.apply(this,arguments)&&n.apply(this,arguments)}:e:n}var Yt={type:3,lower:-1/0,lowerOpen:!1,upper:[[]],upperOpen:!1};function On(e){return typeof e!="string"||/\./.test(e)?function(n){return n}:function(n){return n[e]===void 0&&e in n&&delete(n=xe(n))[e],n}}function $t(){throw j.Type("Entity instances must never be new:ed. Instances are generated by the framework bypassing the constructor.")}function B(e,n){try{var t=Qt(e),r=Qt(n);if(t!==r)return t==="Array"?1:r==="Array"?-1:t==="binary"?1:r==="binary"?-1:t==="string"?1:r==="string"?-1:t==="Date"?1:r!=="Date"?NaN:-1;switch(t){case"number":case"Date":case"string":return n<e?1:e<n?-1:0;case"binary":for(var o=Gt(e),i=Gt(n),a=o.length,u=i.length,c=a<u?a:u,m=0;m<c;++m)if(o[m]!==i[m])return o[m]<i[m]?-1:1;return a===u?0:a<u?-1:1;case"Array":for(var f=e,s=n,l=f.length,y=s.length,d=l<y?l:y,h=0;h<d;++h){var p=B(f[h],s[h]);if(p!==0)return p}return l===y?0:l<y?-1:1}}catch(g){}return NaN}function Qt(e){var n=typeof e;return n=="object"&&(ArrayBuffer.isView(e)||(n=zn(e))==="ArrayBuffer")?"binary":n}function Gt(e){return e instanceof Uint8Array?e:ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e)}function Pn(e,n,t){var r=e.schema.yProps;return r?(n&&0<t.numFailures&&(n=n.filter(function(o,i){return!t.failures[i]})),Promise.all(r.map(function(o){return o=o.updatesTable,n?e.db.table(o).where("k").anyOf(n).delete():e.db.table(o).clear()}
1)).then(function(){return t})):t}Xt.prototype.execute=function(e){var n=this["@@propmod"];if(n.add!==void 0){var t=n.add;if(U(t))return hn(hn([],U(e)?e:[],!0),t).sort();if(typeof t=="number")return(Number(e)||0)+t;if(typeof t=="bigint")try{return BigInt(e)+t}catch(o){return BigInt(0)+t}throw new TypeError("Invalid term ".concat(t))}if(n.remove!==void 0){var r=n.remove;if(U(r))return U(e)?e.filter(function(o){return!r.includes(o)}).sort():[];if(typeof r=="number")return Number(e)-r;if(typeof r=="bigint")try{return BigInt(e)-r}catch(o){return BigInt(0)-r}throw new TypeError("Invalid subtrahend ".concat(r))}return t=(t=n.replacePrefix)==null?void 0:t[0],t&&typeof e=="string"&&e.startsWith(t)?n.replacePrefix[1]+e.substring(t.length):e};var nn=Xt;function Xt(e){this["@@propmod"]=e}function Ht(e,n){for(var t=W(n),r=t.length,o=!1,i=0;i<r;++i){var a=t[i],u=n[a],c=se(e,a);u instanceof nn?(Z(e,a,u.execute(c)),o=!0):c!==u&&(Z(e,a,u),o=!0)}return o}M.prototype._trans=function(e,n,t){var r=this._tx||A.trans,o=this.name,i=ae&&typeof console<"u"&&console.createTask&&console.createTask("Dexie: ".concat(e==="readonly"?"read":"write"," ").concat(this.name));function a(m,f,s){if(s.schema[o])return n(s.idbtrans,s);throw new j.NotFound("Table "+o+" not part of transaction")}var u=Me();try{var c=r&&r.db._novip===this.db._novip?r===A.trans?r._promise(e,a,t):me(function(){return r._promise(e,a,t)},{trans:r,transless:A.transless||A}):(function m(f,s,l,y){if(f.idbdb&&(f._state.openComplete||A.letThrough||f._vip)){var d=f._createTransaction(s,l,f._dbSchema);try{d.create(),f._state.PR1398_maxLoop=3}catch(h){return h.name===$n.InvalidState&&f.isOpen()&&0<--f._state.PR1398_maxLoop?(console.warn("Dexie: Need to reopen db"),f.close({disableAutoOpen:!1}),f.open().then(function(){return m(f,s,l,y)})):V(h)}return d._promise(s,function(h,p){return me(function(){return A.trans=d,y(h,p,d)})}).then(function(h){if(s==="readwrite")try{d.idbtrans.commit()}catch(p){}return s==="readonly"?h:d._completion.then(function(){return h})})}if(f._state.openComplete)return V(new j.DatabaseClosed(f._state.dbOpenError));if(!f._state.isBeingOpened){if(!f._state.autoOpen)return V(new j.DatabaseClosed);f.open().catch(N)}return f._state.dbReadyPromise.then(function(){return m(f,s,l,y)})})(this.db,e,[this.name],a);return i&&(c._consoleTask=i,c=c.catch(function(m){return console.trace(m),V(m)})),c}finally{u&&Le()}},M.prototype.get=function(e,n){var t=this;return e&&e.constructor===Object?this.where(e).first(n):e==null?V(new j.Type("Invalid argument to Table.get()")):this._trans("readonly",function(r){return t.core.get({trans:r,key:e}).then(function(o){return t.hook.reading.fire(o)})}).then(n)},M.prototype.where=function(e){if(typeof e=="string")return new this.db.WhereClause(this,e);if(U(e))return new this.db.WhereClause(this,"[".concat(e.join("+"),"]"));var n=W(e);if(n.length===1)return this.where(n[0]).equals(e[n[0]]);var t=this.schema.indexes.concat(this.schema.primKey).filter(function(u){if(u.compound&&n.every(function(m){return 0<=u.keyPath.indexOf(m)})){for(var c=0;c<n.length;++c)if(n.indexOf(u.keyPath[c])===-1)return!1;return!0}return!1}).sort(function(u,c){return u.keyPath.length-c.keyPath.length})[0];if(t&&this.db._maxKey!==Ae)return a=t.keyPath.slice(0,n.length),this.where(a).equals(a.map(function(u){return e[u]}));!t&&ae&&console.warn("The query ".concat(JSON.stringify(e)," on ").concat(this.name," would benefit from a ")+"compound index [".concat(n.join("+"),"]"));var r=this.schema.idxByName;function o(u,c){return B(u,c)===0}var a=n.reduce(function(f,c){var m=f[0],f=f[1],s=r[c],l=e[c];return[m||s,m||!s?je(f,s&&s.multi?function(y){return y=se(y,c),U(y)&&y.some(function(d){return o(l,d)})}:function(y){return o(l,se(y,c))}):f]},[null,null]),i=a[0],a=a[1];return i?this.where(i.name).equals(e[i.keyPath]).filter(a):t?this.filter(a):this.where(n).equals("")},M.prototype.filter=function(e){return this.toCollection().and(e)},M.prototype.count=function(e){return this.toCollection().count(e)},M.prototype.offset=function(e){return this.toCollection().offset(e)},M.prototype.limit=function(e){return this.toCollection().limit(e)},M.prototype.each=function(e){return this.toCollection().each(e)},M.prototype.toArray=function(e){return this.toCollection().toArray(e)},M.prototype.toCollection=function(){return new this.db.Collection(new this.db.WhereClause(this))},M.prototype.orderBy=function(e){return new this.db.Collection(new this.db.WhereClause(this,U(e)?"[".concat(e.join("+"),"]"):e))},M.prototype.reverse=function(){return this.toCollection().reverse()},M.prototype.mapToClass=function(e){for(var n=this.db,t=this.name,r=((this.schema.mappedClass=e).prototype instanceof $t&&(e=(a=>{var u=f,c=a;if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");function m(){this.constructor=u}function f(){return a!==null&&a.apply(this,arguments)||this}
1return fn(u,c),u.prototype=c===null?Object.create(c):(m.prototype=c.prototype,new m),Object.defineProperty(f.prototype,"db",{get:function(){return n},enumerable:!1,configurable:!0}),f.prototype.table=function(){return t},f})(e)),new Set),o=e.prototype;o;o=Ie(o))Object.getOwnPropertyNames(o).forEach(function(a){return r.add(a)});function i(a){if(!a)return a;var u,c=Object.create(e.prototype);for(u in a)if(!r.has(u))try{c[u]=a[u]}catch(m){}return c}return this.schema.readHook&&this.hook.reading.unsubscribe(this.schema.readHook),this.schema.readHook=i,this.hook("reading",i),e},M.prototype.defineClass=function(){return this.mapToClass(function(e){ee(this,e)})},M.prototype.add=function(e,n){var t=this,r=this.schema.primKey,o=r.auto,i=r.keyPath,a=e;return i&&o&&(a=On(i)(e)),this._trans("readwrite",function(u){return t.core.mutate({trans:u,type:"add",keys:n!=null?[n]:null,values:[a]})}).then(function(u){return u.numFailures?E.reject(u.failures[0]):u.lastResult}).then(function(u){if(i)try{Z(e,i,u)}catch(c){}return u})},M.prototype.upsert=function(e,n){var t=this,r=this.schema.primKey.keyPath;return this._trans("readwrite",function(o){return t.core.get({trans:o,key:e}).then(function(i){var a=i!=null?i:{};return Ht(a,n),r&&Z(a,r,e),t.core.mutate({trans:o,type:"put",values:[a],keys:[e],upsert:!0,updates:{keys:[e],changeSpecs:[n]}}).then(function(u){return u.numFailures?E.reject(u.failures[0]):!!i})})})},M.prototype.update=function(e,n){return typeof e!="object"||U(e)?this.where(":id").equals(e).modify(n):(e=se(e,this.schema.primKey.keyPath))===void 0?V(new j.InvalidArgument("Given object does not contain its primary key")):this.where(":id").equals(e).modify(n)},M.prototype.put=function(e,n){var t=this,r=this.schema.primKey,o=r.auto,i=r.keyPath,a=e;return i&&o&&(a=On(i)(e)),this._trans("readwrite",function(u){return t.core.mutate({trans:u,type:"put",values:[a],keys:n!=null?[n]:null})}).then(function(u){return u.numFailures?E.reject(u.failures[0]):u.lastResult}).then(function(u){if(i)try{Z(e,i,u)}catch(c){}return u})},M.prototype.delete=function(e){var n=this;return this._trans("readwrite",function(t){return n.core.mutate({trans:t,type:"delete",keys:[e]}).then(function(r){return Pn(n,[e],r)}).then(function(r){return r.numFailures?E.reject(r.failures[0]):void 0})})},M.prototype.clear=function(){var e=this;return this._trans("readwrite",function(n){return e.core.mutate({trans:n,type:"deleteRange",range:Yt}).then(function(t){return Pn(e,null,t)})}).then(function(n){return n.numFailures?E.reject(n.failures[0]):void 0})},M.prototype.bulkGet=function(e){var n=this;return this._trans("readonly",function(t){return n.core.getMany({keys:e,trans:t}).then(function(r){return r.map(function(o){return n.hook.reading.fire(o)})})})},M.prototype.bulkAdd=function(e,n,t){var r=this,o=Array.isArray(n)?n:void 0,i=(t=t||(o?void 0:n))?t.allKeys:void 0;return this._trans("readwrite",function(a){var u=r.schema.primKey,m=u.auto,u=u.keyPath;if(u&&o)throw new j.InvalidArgument("bulkAdd(): keys argument invalid on tables with inbound keys");if(o&&o.length!==e.length)throw new j.InvalidArgument("Arguments objects and keys must have the same length");var c=e.length,m=u&&m?e.map(On(u)):e;return r.core.mutate({trans:a,type:"add",keys:o,values:m,wantResults:i}).then(function(f){var s=f.numFailures,l=f.failures;if(s===0)return i?f.results:f.lastResult;throw new Ne("".concat(r.name,".bulkAdd(): ").concat(s," of ").concat(c," operations failed"),l)})})},M.prototype.bulkPut=function(e,n,t){var r=this,o=Array.isArray(n)?n:void 0,i=(t=t||(o?void 0:n))?t.allKeys:void 0;return this._trans("readwrite",function(a){var u=r.schema.primKey,m=u.auto,u=u.keyPath;if(u&&o)throw new j.InvalidArgument("bulkPut(): keys argument invalid on tables with inbound keys");if(o&&o.length!==e.length)throw new j.InvalidArgument("Arguments objects and keys must have the same length");var c=e.length,m=u&&m?e.map(On(u)):e;return r.core.mutate({trans:a,type:"put",keys:o,values:m,wantResults:i}).then(function(f){var s=f.numFailures,l=f.failures;if(s===0)return i?f.results:f.lastResult;throw new Ne("".concat(r.name,".bulkPut(): ").concat(s," of ").concat(c," operations failed"),l)})})},M.prototype.bulkUpdate=function(e){var n=this,t=this.core,r=e.map(function(a){return a.key}),o=e.map(function(a){return a.changes}),i=[];return this._trans("readwrite",function(a){return t.getMany({trans:a,keys:r,cache:"clone"}).then(function(u){var c=[],m=[],f=(e.forEach(function(s,l){var y=s.key,d=s.changes,h=u[l];
vendor: 7,845 bytes, line 1
1if(h){for(var p=0,g=Object.keys(d);p<g.length;p++){var v=g[p],b=d[v];if(v===n.schema.primKey.keyPath){if(B(b,y)!==0)throw new j.Constraint("Cannot update primary key in bulkUpdate()")}else Z(h,v,b)}i.push(l),c.push(y),m.push(h)}}),c.length);return t.mutate({trans:a,type:"put",keys:c,values:m,updates:{keys:r,changeSpecs:o}}).then(function(s){var l=s.numFailures,y=s.failures;if(l===0)return f;for(var d=0,h=Object.keys(y);d<h.length;d++){var p,g=h[d],v=i[Number(g)];v!=null&&(p=y[g],delete y[g],y[v]=p)}throw new Ne("".concat(n.name,".bulkUpdate(): ").concat(l," of ").concat(f," operations failed"),y)})})})},M.prototype.bulkDelete=function(e){var n=this,t=e.length;return this._trans("readwrite",function(r){return n.core.mutate({trans:r,type:"delete",keys:e}).then(function(o){return Pn(n,e,o)})}).then(function(r){var o=r.numFailures,i=r.failures;if(o===0)return r.lastResult;throw new Ne("".concat(n.name,".bulkDelete(): ").concat(o," of ").concat(t," operations failed"),i)})};var Jt=M;function M(){}function tn(e){function n(a,u){if(u){for(var c=arguments.length,m=new Array(c-1);--c;)m[c-1]=arguments[c];return t[a].subscribe.apply(null,m),e}if(typeof a=="string")return t[a]}var t={};n.addEventType=i;for(var r=1,o=arguments.length;r<o;++r)i(arguments[r]);return n;function i(a,u,c){var m,f;if(typeof a!="object")return u=u||Ir,f={subscribers:[],fire:c=c||N,subscribe:function(s){f.subscribers.indexOf(s)===-1&&(f.subscribers.push(s),f.fire=u(f.fire,s))},unsubscribe:function(s){f.subscribers=f.subscribers.filter(function(l){return l!==s}),f.fire=f.subscribers.reduce(u,c)}},t[a]=n[a]=f;W(m=a).forEach(function(s){var l=m[s];if(U(l))i(s,m[s][0],m[s][1]);else{if(l!=="asap")throw new j.InvalidArgument("Invalid event config");var y=i(s,Xe,function(){for(var d=arguments.length,h=new Array(d);d--;)h[d]=arguments[d];y.subscribers.forEach(function(p){Tt(function(){p.apply(null,h)})})})}})}}function rn(e,n){return Re(n).from({prototype:e}),n}function Ve(e,n){return!(e.filter||e.algorithm||e.or)&&(n?e.justLimit:!e.replayFilter)}function it(e,n){e.filter=je(e.filter,n)}function at(e,n,t){var r=e.replayFilter;e.replayFilter=r?function(){return je(r(),n())}:n,e.justLimit=t&&!r}function En(e,n){if(e.isPrimKey)return n.primaryKey;var t=n.getIndexByKeyPath(e.index);if(t)return t;throw new j.Schema("KeyPath "+e.index+" on object store "+n.name+" is not indexed")}function Zt(e,n,t){var r=En(e,n.schema);return n.openCursor({trans:t,values:!e.keysOnly,reverse:e.dir==="prev",unique:!!e.unique,query:{index:r,range:e.range}})}function Kn(e,n,t,r){var o,i,a=e.replayFilter?je(e.filter,e.replayFilter()):e.filter;return e.or?(o={},i=function(u,c,m){var f,s;a&&!a(c,m,function(l){return c.stop(l)},function(l){return c.fail(l)})||((s=""+(f=c.primaryKey))=="[object ArrayBuffer]"&&(s=""+new Uint8Array(f)),ne(o,s))||(o[s]=!0,n(u,c,m))},Promise.all([e.or._iterate(i,t),er(Zt(e,r,t),e.algorithm,i,!e.keysOnly&&e.valueMapper)])):er(Zt(e,r,t),je(e.algorithm,a),n,!e.keysOnly&&e.valueMapper)}function er(e,n,t,r){var o=L(r?function(i,a,u){return t(r(i),a,u)}:t);return e.then(function(i){if(i)return i.start(function(){var a=function(){return i.continue()};n&&!n(i,function(u){return a=u},function(u){i.stop(u),a=N},function(u){i.fail(u),a=N})||o(i.value,i,function(u){return a=u}),a()})})}F.prototype._read=function(e,n){var t=this._ctx;return t.error?t.table._trans(null,V.bind(null,t.error)):t.table._trans("readonly",e).then(n)},F.prototype._write=function(e){var n=this._ctx;return n.error?n.table._trans(null,V.bind(null,n.error)):n.table._trans("readwrite",e,"locked")},F.prototype._addAlgorithm=function(e){var n=this._ctx;n.algorithm=je(n.algorithm,e)},F.prototype._iterate=function(e,n){return Kn(this._ctx,e,n,this._ctx.table.core)},F.prototype.clone=function(e){var n=Object.create(this.constructor.prototype),t=Object.create(this._ctx);return e&&ee(t,e),n._ctx=t,n},F.prototype.raw=function(){return this._ctx.valueMapper=null,this},F.prototype.each=function(e){var n=this._ctx;return this._read(function(t){return Kn(n,e,t,n.table.core)})},F.prototype.count=function(e){var n=this;return this._read(function(t){var r,o=n._ctx,i=o.table.core;return Ve(o,!0)?i.count({trans:t,query:{index:En(o,i.schema),range:o.range}}).then(function(a){return Math.min(a,o.limit)}):(r=0,Kn(o,function(){return++r,!1},t,i).then(function(){return r}))}).then(e)},F.prototype.sortBy=function(e,n){var t=e.split(".").reverse(),r=t[0],o=t.length-1;function i(c,m){return m?i(c[t[m]],m-1):c[r]}var a=this._ctx.dir==="next"?1:-1;function u(c,m){return B(i(c,o),i(m,o))*a}return this.toArray(function(c){return c.slice().sort(u)}).then(n)},F.prototype.toArray=function(e){var n=this;return this._read(function(t){var r,o,i,a=n._ctx;return Ve(a,!0)&&0<a.limit?(r=a.valueMapper,o=En(a,a.table.core.schema),a.table.core.query({trans:t,limit:a.limit,values:!0,direction:a.dir==="prev"?"prev":void 0,query:{index:o,range:a.range}}).then(function(u){return u=u.result,r?u.map(r):u})):(i=[],Kn(a,function(u){return i.push(u)},t,a.table.core).then(function(){return i}))},e)},F.prototype.offset=function(e){var n=this._ctx;return e<=0||(n.offset+=e,Ve(n)?at(n,function(){var t=e;return function(r,o){return t===0||(t===1?--t:o(function(){r.advance(t),t=0}),!1)}}):at(n,function(){var t=e;return function(){return--t<0}})),this},F.prototype.limit=function(e){return this._ctx.limit=Math.min(this._ctx.limit,e),at(this._ctx,function(){var n=e;return function(t,r,o){return--n<=0&&r(o),0<=n}},!0),this},F.prototype.until=function(e,n){return it(this._ctx,function(t,r,o){return!e(t.value)||(r(o),n)}),this},F.prototype.first=function(e){return this.limit(1).toArray(function(n){return n[0]}).then(e)},F.prototype.last=function(e){return this.reverse().first(e)},F.prototype.filter=function(e){var n;return it(this._ctx,function(t){return e(t.value)}),(n=this._ctx).isMatch=je(n.isMatch,e),this},F.prototype.and=function(e){return this.filter(e)},F.prototype.or=function(e){return new this.db.WhereClause(this._ctx.table,e,this)},F.prototype.reverse=function(){return this._ctx.dir=this._ctx.dir==="prev"?"next":"prev",this._ondirectionchange&&this._ondirectionchange(this._ctx.dir),this},F.prototype.desc=function(){return this.reverse()},F.prototype.eachKey=function(e){var n=this._ctx;return n.keysOnly=!n.isMatch,this.each(function(t,r){e(r.key,r)})},F.prototype.eachUniqueKey=function(e){return this._ctx.unique="unique",this.eachKey(e)},F.prototype.eachPrimaryKey=function(e){var n=this._ctx;return n.keysOnly=!n.isMatch,this.each(function(t,r){e(r.primaryKey,r)})},F.prototype.keys=function(e){var n=this._ctx,t=(n.keysOnly=!n.isMatch,[]);return this.each(function(r,o){t.push(o.key)}).then(function(){return t}).then(e)},F.prototype.primaryKeys=function(e){var n=this._ctx;if(Ve(n,!0)&&0<n.limit)return this._read(function(r){var o=En(n,n.table.core.schema);return n.table.core.query({trans:r,values:!1,limit:n.limit,direction:n.dir==="prev"?"prev":void 0,query:{index:o,range:n.range}})}).then(function(r){return r.result}).then(e);n.keysOnly=!n.isMatch;var t=[];return this.each(function(r,o){t.push(o.primaryKey)}).then(function(){return t}).then(e)},F.prototype.uniqueKeys=function(e){return this._ctx.unique="unique",this.keys(e)},F.prototype.firstKey=function(e){return this.limit(1).keys(function(n){return n[0]}).then(e)},F.prototype.lastKey=function(e){return this.reverse().firstKey(e)},F.prototype.distinct=function(){var e,n=this._ctx,n=n.index&&n.table.schema.idxByName[n.index];return n&&n.multi&&(e={},it(this._ctx,function(r){var r=r.primaryKey.toString(),o=ne(e,r);return e[r]=!0,!o})),this},F.prototype.modify=function(e){var n=this,t=this._ctx;return this._write(function(r){function o(h,p){var g=p.failures;l+=h-p.numFailures;for(var v=0,b=W(g);v<b.length;v++){var w=b[v];s.push(g[w])}}var i=typeof e=="function"?e:function(h){return Ht(h,e)}
1,a=t.table.core,f=a.schema.primaryKey,u=f.outbound,c=f.extractKey,m=200,f=n.db._options.modifyChunkSize,s=(f&&(m=typeof f=="object"?f[a.name]||f["*"]||200:f),[]),l=0,y=[],d=e===nr;return n.clone().primaryKeys().then(function(h){function p(v){var b=Math.min(m,h.length-v),w=h.slice(v,v+b);return(d?Promise.resolve([]):a.getMany({trans:r,keys:w,cache:"immutable"})).then(function(x){var P=[],k=[],K=u?[]:null,O=d?w:[];if(!d)for(var S=0;S<b;++S){var _=x[S],C={value:xe(_),primKey:h[v+S]};i.call(C,C.value,C)!==!1&&(C.value==null?O.push(h[v+S]):u||B(c(_),c(C.value))===0?(k.push(C.value),u&&K.push(h[v+S])):(O.push(h[v+S]),P.push(C.value)))}return Promise.resolve(0<P.length&&a.mutate({trans:r,type:"add",values:P}).then(function(D){for(var q in D.failures)O.splice(parseInt(q),1);o(P.length,D)})).then(function(){return(0<k.length||g&&typeof e=="object")&&a.mutate({trans:r,type:"put",keys:K,values:k,criteria:g,changeSpec:typeof e!="function"&&e,isAdditionalChunk:0<v}).then(function(D){return o(k.length,D)})}).then(function(){return(0<O.length||g&&d)&&a.mutate({trans:r,type:"delete",keys:O,criteria:g,isAdditionalChunk:0<v}).then(function(D){return Pn(t.table,O,D)}).then(function(D){return o(O.length,D)})}).then(function(){return h.length>v+b&&p(v+m)})})}var g=Ve(t)&&t.limit===1/0&&(typeof e!="function"||d)&&{index:t.index,range:t.range};return p(0).then(function(){if(0<s.length)throw new pn("Error modifying one or more objects",s,l,y);return h.length})})})},F.prototype.delete=function(){var e=this._ctx,n=e.range;return!Ve(e)||e.table.schema.yProps||!e.isPrimKey&&n.type!==3?this.modify(nr):this._write(function(t){var r=e.table.core.schema.primaryKey,o=n;return e.table.core.count({trans:t,query:{index:r,range:o}}).then(function(i){return e.table.core.mutate({trans:t,type:"deleteRange",range:o}).then(function(c){var u=c.failures,c=c.numFailures;if(c)throw new pn("Could not delete some values",Object.keys(u).map(function(m){return u[m]}),i-c);return i-c})})})};var Mr=F;function F(){}var nr=function(e,n){return n.value=null};function Lr(e,n){return e<n?-1:e===n?0:1}function Ur(e,n){return n<e?-1:e===n?0:1}function re(e,n,t){return e=e instanceof rr?new e.Collection(e):e,e._ctx.error=new(t||TypeError)(n),e}function ze(e){return new e.Collection(e,function(){return tr("")}).limit(0)}function Sn(y,n,t,r){var o,i,a,u,c,m,f,s=t.length;if(!t.every(function(h){return typeof h=="string"}))return re(y,Wt);function l(h){o=h==="next"?function(g){return g.toUpperCase()}:function(g){return g.toLowerCase()},i=h==="next"?function(g){return g.toLowerCase()}:function(g){return g.toUpperCase()},a=h==="next"?Lr:Ur;var p=t.map(function(g){return{lower:i(g),upper:o(g)}}).sort(function(g,v){return a(g.lower,v.lower)});u=p.map(function(g){return g.upper}),c=p.map(function(g){return g.lower}),f=(m=h)==="next"?"":r}l("next");var y=new y.Collection(y,function(){return be(u[0],c[s-1]+r)}),d=(y._ondirectionchange=function(h){l(h)}
1,0);return y._addAlgorithm(function(h,p,g){var v=h.key;if(typeof v=="string"){var b=i(v);if(n(b,c,d))return!0;for(var w=null,x=d;x<s;++x){var P=((k,K,O,S,_,C)=>{for(var D=Math.min(k.length,S.length),q=-1,R=0;R<D;++R){var oe=K[R];if(oe!==S[R])return _(k[R],O[R])<0?k.substr(0,R)+O[R]+O.substr(R+1):_(k[R],S[R])<0?k.substr(0,R)+S[R]+O.substr(R+1):0<=q?k.substr(0,q)+K[q]+O.substr(q+1):null;_(k[R],oe)<0&&(q=R)}return D<S.length&&C==="next"?k+O.substr(k.length):D<k.length&&C==="prev"?k.substr(0,O.length):q<0?null:k.substr(0,q)+S[q]+O.substr(q+1)})(v,b,u[x],c[x],a,m);P===null&&w===null?d=x+1:(w===null||0<a(w,P))&&(w=P)}p(w!==null?function(){h.continue(w+f)}:g)}return!1}),y}function be(e,n,t,r){return{type:2,lower:e,upper:n,lowerOpen:t,upperOpen:r}}function tr(e){return{type:1,lower:e,upper:e}}Object.defineProperty($.prototype,"Collection",{get:function(){return this._ctx.table.db.Collection},enumerable:!1,configurable:!0}),$.prototype.between=function(e,n,t,r){t=t!==!1,r=r===!0;try{return 0<this._cmp(e,n)||this._cmp(e,n)===0&&(t||r)&&(!t||!r)?ze(this):new this.Collection(this,function(){return be(e,n,!t,!r)})}catch(o){return re(this,he)}},$.prototype.equals=function(e){return e==null?re(this,he):new this.Collection(this,function(){return tr(e)})},$.prototype.above=function(e){return e==null?re(this,he):new this.Collection(this,function(){return be(e,void 0,!0)})},$.prototype.aboveOrEqual=function(e){return e==null?re(this,he):new this.Collection(this,function(){return be(e,void 0,!1)})},$.prototype.below=function(e){return e==null?re(this,he):new this.Collection(this,function(){return be(void 0,e,!1,!0)})},$.prototype.belowOrEqual=function(e){return e==null?re(this,he):new this.Collection(this,function(){return be(void 0,e)})},$.prototype.startsWith=function(e){return typeof e!="string"?re(this,Wt):this.between(e,e+Ae,!0,!0)},$.prototype.startsWithIgnoreCase=function(e){return e===""?this.startsWith(e):Sn(this,function(n,t){return n.indexOf(t[0])===0},[e],Ae)},$.prototype.equalsIgnoreCase=function(e){return Sn(this,function(n,t){return n===t[0]},[e],"")},$.prototype.anyOfIgnoreCase=function(){var e=ce.apply(Be,arguments);return e.length===0?ze(this):Sn(this,function(n,t){return t.indexOf(n)!==-1},e,"")},$.prototype.startsWithAnyOfIgnoreCase=function(){var e=ce.apply(Be,arguments);return e.length===0?ze(this):Sn(this,function(n,t){return t.some(function(r){return n.indexOf(r)===0})},e,Ae)},$.prototype.anyOf=function(){var e,n,t=this,r=ce.apply(Be,arguments),o=this._cmp;try{r.sort(o)}catch(i){return re(this,he)}return r.length===0?ze(this):((e=new this.Collection(this,function(){return be(r[0],r[r.length-1])}))._ondirectionchange=function(i){o=i==="next"?t._ascending:t._descending,r.sort(o)},n=0,e._addAlgorithm(function(i,a,u){for(var c=i.key;0<o(c,r[n]);)if(++n===r.length)return a(u),!1;return o(c,r[n])===0||(a(function(){i.continue(r[n])}),!1)}),e)},$.prototype.notEqual=function(e){return this.inAnyRange([[-1/0,e],[e,this.db._maxKey]],{includeLowers:!1,includeUppers:!1})},$.prototype.noneOf=function(){var e=ce.apply(Be,arguments);if(e.length===0)return new this.Collection(this);try{e.sort(this._ascending)}catch(t){return re(this,he)}var n=e.reduce(function(t,r){return t?t.concat([[t[t.length-1][1],r]]):[[-1/0,r]]},null);return n.push([e[e.length-1],this.db._maxKey]),this.inAnyRange(n,{includeLowers:!1,includeUppers:!1})},$.prototype.inAnyRange=function(e,g){var t=this,r=this._cmp,o=this._ascending,i=this._descending,a=this._min,u=this._max;if(e.length===0)return ze(this);if(!e.every(function(v){return v[0]!==void 0&&v[1]!==void 0&&o(v[0],v[1])<=0}))return re(this,"First argument to inAnyRange() must be an Array of two-value Arrays [lower,upper] where upper must not be lower than lower",j.InvalidArgument);var c=!g||g.includeLowers!==!1,m=g&&g.includeUppers===!0,f,s=o;function l(v,b){return s(v[0],b[0])}try{(f=e.reduce(function(v,b){for(var w=0,x=v.length;w<x;++w){var P=v[w];if(r(b[0],P[1])<0&&0<r(b[1],P[0])){P[0]=a(P[0],b[0]),P[1]=u(P[1],b[1]);break}}return w===x&&v.push(b),v},[])).sort(l)}catch(v){return re(this,he)}var y=0,d=m?function(v){return 0<o(v,f[y][1])}:function(v){return 0<=o(v,f[y][1])},h=c?function(v){return 0<i(v,f[y][0])}:function(v){return 0<=i(v,f[y][0])},p=d,g=new this.Collection(this,function(){return be(f[0][0],f[f.length-1][1],!c,!m)});return g._ondirectionchange=function(v){s=v==="next"?(p=d,o):(p=h,i),f.sort(l)},g._addAlgorithm(function(v,b,w){for(var x,P=v.key;p(P);)if(++y===f.length)return b(w),!1;return!d(x=P)&&!h(x)||(t._cmp(P,f[y][1])===0||t._cmp(P,f[y][0])===0||b(function(){s===o?v.continue(f[y][0]):v.continue(f[y][1])}),!1)}),g},$.prototype.startsWithAnyOf=function(){var e=ce.apply(Be,arguments);return e.every(function(n){return typeof n=="string"})?e.length===0?ze(this):this.inAnyRange(e.map(function(n){return[n,n+Ae]}
1)):re(this,"startsWithAnyOf() only works with strings")};var rr=$;function $(){}function ie(e){return L(function(n){return on(n),e(n.target.error),!1})}function on(e){e.stopPropagation&&e.stopPropagation(),e.preventDefault&&e.preventDefault()}var An="storagemutated",ut="x-storagemutated-1",we=tn(null,An),Vr=(ue.prototype._lock=function(){return Qe(!A.global),++this._reculock,this._reculock!==1||A.global||(A.lockOwnerFor=this),this},ue.prototype._unlock=function(){if(Qe(!A.global),--this._reculock==0)for(A.global||(A.lockOwnerFor=null);0<this._blockedFuncs.length&&!this._locked();){var e=this._blockedFuncs.shift();try{Se(e[1],e[0])}catch(n){}}return this},ue.prototype._locked=function(){return this._reculock&&A.lockOwnerFor!==this},ue.prototype.create=function(e){var n=this;if(this.mode){var t=this.db.idbdb,r=this.db._state.dbOpenError;if(Qe(!this.idbtrans),!e&&!t)switch(r&&r.name){case"DatabaseClosedError":throw new j.DatabaseClosed(r);case"MissingAPIError":throw new j.MissingAPI(r.message,r);default:throw new j.OpenFailed(r)}if(!this.active)throw new j.TransactionInactive;Qe(this._completion._state===null),(e=this.idbtrans=e||(this.db.core||t).transaction(this.storeNames,this.mode,{durability:this.chromeTransactionDurability})).onerror=L(function(o){on(o),n._reject(e.error)}),e.onabort=L(function(o){on(o),n.active&&n._reject(new j.Abort(e.error)),n.active=!1,n.on("abort").fire(o)}),e.oncomplete=L(function(){n.active=!1,n._resolve(),"mutatedParts"in e&&we.storagemutated.fire(e.mutatedParts)})}return this},ue.prototype._promise=function(e,n,t){var r,o=this;return e==="readwrite"&&this.mode!=="readwrite"?V(new j.ReadOnly("Transaction is readonly")):this.active?this._locked()?new E(function(i,a){o._blockedFuncs.push([function(){o._promise(e,n,t).then(i,a)},A])}):t?me(function(){var i=new E(function(a,u){o._lock();var c=n(a,u,o);c&&c.then&&c.then(a,u)});return i.finally(function(){return o._unlock()}),i._lib=!0,i}):((r=new E(function(i,a){var u=n(i,a,o);u&&u.then&&u.then(i,a)}))._lib=!0,r):V(new j.TransactionInactive)}
1,ue.prototype._root=function(){return this.parent?this.parent._root():this},ue.prototype.waitFor=function(e){var n,t=this._root(),r=E.resolve(e),o=(t._waitingFor?t._waitingFor=t._waitingFor.then(function(){return r}):(t._waitingFor=r,t._waitingQueue=[],n=t.idbtrans.objectStore(t.storeNames[0]),(function i(){for(++t._spinCount;t._waitingQueue.length;)t._waitingQueue.shift()();t._waitingFor&&(n.get(-1/0).onsuccess=i)})()),t._waitingFor);return new E(function(i,a){r.then(function(u){return t._waitingQueue.push(L(i.bind(null,u)))},function(u){return t._waitingQueue.push(L(a.bind(null,u)))}).finally(function(){t._waitingFor===o&&(t._waitingFor=null)})})},ue.prototype.abort=function(){this.active&&(this.active=!1,this.idbtrans&&this.idbtrans.abort(),this._reject(new j.Abort))},ue.prototype.table=function(e){var n=this._memoizedTables||(this._memoizedTables={});if(ne(n,e))return n[e];var t=this.schema[e];if(t)return(t=new this.db.Table(e,t,this)).core=this.db.core.table(e),n[e]=t;throw new j.NotFound("Table "+e+" not part of transaction")},ue);function ue(){}function st(e,n,t,r,o,i,a,u){return{name:e,keyPath:n,unique:t,multi:r,auto:o,compound:i,src:(t&&!a?"&":"")+(r?"*":"")+(o?"++":"")+or(n),type:u}}function or(e){return typeof e=="string"?e:e?"["+[].join.call(e,"+")+"]":""}function ct(e,n,t){return{name:e,primKey:n,indexes:t,mappedClass:null,idxByName:(r=function(o){return[o.name,o]},t.reduce(function(o,i,a){return i=r(i,a),i&&(o[i[0]]=i[1]),o},{}))};var r}var an=function(e){try{return e.only([[]]),an=function(){return[[]]},[[]]}catch(n){return an=function(){return Ae},Ae}};function lt(e){return e==null?function(){}:typeof e=="string"?(n=e).split(".").length===1?function(t){return t[n]}:function(t){return se(t,n)}:function(t){return se(t,e)};var n}function ir(e){return[].slice.call(e)}var zr=0;function un(e){return e==null?":id":typeof e=="string"?e:"[".concat(e.join("+"),"]")}function Wr(e,n,a){function r(p){if(p.type===3)return null;if(p.type===4)throw new Error("Cannot convert never type to IDBKeyRange");var y=p.lower,d=p.upper,h=p.lowerOpen,p=p.upperOpen;return y===void 0?d===void 0?null:n.upperBound(d,!!p):d===void 0?n.lowerBound(y,!!h):n.bound(y,d,!!h,!!p)}function o(l){var y,d,h=l.name;return{name:h,schema:l,mutate:function(p){var g=p.trans,v=p.type,b=p.keys,w=p.values,x=p.range;return new Promise(function(P,k){P=L(P);var K=g.objectStore(h),O=K.keyPath==null,S=v==="put"||v==="add";if(!S&&v!=="delete"&&v!=="deleteRange")throw new Error("Invalid operation type: "+v);var _,C=(b||w||{length:1}).length;if(b&&w&&b.length!==w.length)throw new Error("Given keys array must have same length as given values array.");if(C===0)return P({numFailures:0,failures:{},results:[],lastResult:void 0});function D(J){++oe,on(J)}var q=[],R=[],oe=0;if(v==="deleteRange"){if(x.type===4)return P({numFailures:oe,failures:R,results:[],lastResult:void 0});x.type===3?q.push(_=K.clear()):q.push(_=K.delete(r(x)))}else{var O=S?O?[w,b]:[w,null]:[b,null],I=O[0],X=O[1];if(S)for(var H=0;H<C;++H)q.push(_=X&&X[H]!==void 0?K[v](I[H],X[H]):K[v](I[H])),_.onerror=D;else for(H=0;H<C;++H)q.push(_=K[v](I[H])),_.onerror=D}function Ln(J){J=J.target.result,q.forEach(function(Te,St){return Te.error!=null&&(R[St]=Te.error)}),P({numFailures:oe,failures:R,results:v==="delete"?b:q.map(function(Te){return Te.result}),lastResult:J})}_.onerror=function(J){D(J),Ln(J)},_.onsuccess=Ln})},getMany:function(p){var g=p.trans,v=p.keys;return new Promise(function(b,w){b=L(b);for(var x,P=g.objectStore(h),k=v.length,K=new Array(k),O=0,S=0,_=function(q){q=q.target,K[q._pos]=q.result,++S===O&&b(K)},C=ie(w),D=0;D<k;++D)v[D]!=null&&((x=P.get(v[D]))._pos=D,x.onsuccess=_,x.onerror=C,++O);O===0&&b(K)})},get:function(p){var g=p.trans,v=p.key;return new Promise(function(b,w){b=L(b);var x=g.objectStore(h).get(v);x.onsuccess=function(P){return b(P.target.result)},x.onerror=ie(w)})},query:(y=c,d=m,function(p){return new Promise(function(g,v){g=L(g);var b,w,x,P,C=p.trans,k=p.values,K=p.limit,_=p.query,O=(O=p.direction)!=null?O:"next",S=K===1/0?void 0:K,D=_.index,_=_.range,C=C.objectStore(h),C=D.isPrimaryKey?C:C.index(D.name),D=r(_);
vendor: 9,689 bytes, line 1
1if(K===0)return g({result:[]});d?(_={query:D,count:S,direction:O},(b=k?C.getAll(_):C.getAllKeys(_)).onsuccess=function(q){return g({result:q.target.result})},b.onerror=ie(v)):y&&O==="next"?((b=k?C.getAll(D,S):C.getAllKeys(D,S)).onsuccess=function(q){return g({result:q.target.result})},b.onerror=ie(v)):(w=0,x=!k&&"openKeyCursor"in C?C.openKeyCursor(D,O):C.openCursor(D,O),P=[],x.onsuccess=function(){var q=x.result;return!q||(P.push(k?q.value:q.primaryKey),++w===K)?g({result:P}):void q.continue()},x.onerror=ie(v))})}),openCursor:function(p){var g=p.trans,v=p.values,b=p.query,w=p.reverse,x=p.unique;return new Promise(function(P,k){P=L(P);var S=b.index,K=b.range,O=g.objectStore(h),O=S.isPrimaryKey?O:O.index(S.name),S=w?x?"prevunique":"prev":x?"nextunique":"next",_=!v&&"openKeyCursor"in O?O.openKeyCursor(r(K),S):O.openCursor(r(K),S);_.onerror=ie(k),_.onsuccess=L(function(C){var D,q,R,oe,I=_.result;I?(I.___id=++zr,I.done=!1,D=I.continue.bind(I),q=(q=I.continuePrimaryKey)&&q.bind(I),R=I.advance.bind(I),oe=function(){throw new Error("Cursor not stopped")},I.trans=g,I.stop=I.continue=I.continuePrimaryKey=I.advance=function(){throw new Error("Cursor not started")},I.fail=L(k),I.next=function(){var X=this,H=1;return this.start(function(){return H--?X.continue():X.stop()}).then(function(){return X})},I.start=function(X){function H(){if(_.result)try{X()}catch(J){I.fail(J)}else I.done=!0,I.start=function(){throw new Error("Cursor behind last entry")},I.stop()}var Ln=new Promise(function(J,Te){J=L(J),_.onerror=ie(Te),I.fail=Te,I.stop=function(St){I.stop=I.continue=I.continuePrimaryKey=I.advance=oe,J(St)}});return _.onsuccess=L(function(J){_.onsuccess=H,H()}),I.continue=D,I.continuePrimaryKey=q,I.advance=R,H(),Ln},P(I)):P(null)},k)})},count:function(p){var g=p.query,v=p.trans,b=g.index,w=g.range;return new Promise(function(x,P){var k=v.objectStore(h),k=b.isPrimaryKey?k:k.index(b.name),K=r(w),K=K?k.count(K):k.count();K.onsuccess=L(function(O){return x(O.target.result)}),K.onerror=ie(P)})}}}i=a,u=ir((a=e).objectStoreNames),f=0<u.length?i.objectStore(u[0]):{};var i,a={schema:{name:a.name,tables:u.map(function(l){return i.objectStore(l)}).map(function(l){var y=l.keyPath,d=l.autoIncrement,p=U(y),h={},p={name:l.name,primaryKey:{name:null,isPrimaryKey:!0,outbound:y==null,compound:p,keyPath:y,autoIncrement:d,unique:!0,extractKey:lt(y)},indexes:ir(l.indexNames).map(function(g){return l.index(g)}).map(function(w){var x=w.name,v=w.unique,b=w.multiEntry,w=w.keyPath,x={name:x,compound:U(w),keyPath:w,unique:v,multiEntry:b,extractKey:lt(w)};return h[un(w)]=x}),getIndexByKeyPath:function(g){return h[un(g)]}};return h[":id"]=p.primaryKey,y!=null&&(h[un(y)]=p.primaryKey),p})},hasGetAll:0<u.length&&"getAll"in f&&!(typeof navigator<"u"&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604),hasIdb3Features:"getAllRecords"in f},u=a.schema,c=a.hasGetAll,m=a.hasIdb3Features,f=u.tables.map(o),s={};return f.forEach(function(l){return s[l.name]=l}),{stack:"dbcore",transaction:e.transaction.bind(e),table:function(l){if(s[l])return s[l];throw new Error("Table '".concat(l,"' not found"))},MIN_KEY:-1/0,MAX_KEY:an(n),schema:u}}function Yr(e,n,t,r){return t=t.IDBKeyRange,n=Wr(n,t,r),{dbcore:e.dbcore.reduce(function(o,i){return i=i.create,T(T({},o),i(o))},n)}}function jn(e,n){var t=n.db,t=Yr(e._middlewares,t,e._deps,n);e.core=t.dbcore,e.tables.forEach(function(r){var o=r.name;e.core.schema.tables.some(function(i){return i.name===o})&&(r.core=e.core.table(o),e[o]instanceof e.Table)&&(e[o].core=r.core)})}function Cn(e,n,t,r){t.forEach(function(o){var i=r[o];n.forEach(function(a){var u=(function c(m,f){return kr(m,f)||(m=Ie(m))&&c(m,f)})(a,o);(!u||"value"in u&&u.value===void 0)&&(a===e.Transaction.prototype||a instanceof e.Transaction?ye(a,o,{get:function(){return this.table(o)},set:function(c){Ct(this,o,{value:c,writable:!0,configurable:!0,enumerable:!0})}}):a[o]=new e.Table(o,i))})})}function ft(e,n){n.forEach(function(t){for(var r in t)t[r]instanceof e.Table&&delete t[r]})}function $r(e,n){return e._cfg.version-n._cfg.version}function Qr(e,n,t,r){var o=e._dbSchema,i=(t.objectStoreNames.contains("$meta")&&!o.$meta&&(o.$meta=ct("$meta",ur("")[0],[]),e._storeNames.push("$meta")),e._createTransaction("readwrite",e._storeNames,o)),a=(i.create(t),i._completion.catch(r),i._reject.bind(i)),u=A.transless||A;me(function(){if(A.trans=i,A.transless=u,n!==0)return jn(e,t),m=n,((c=i).storeNames.includes("$meta")?c.table("$meta").get("version").then(function(f){return f!=null?f:m}):E.resolve(m)).then(function(p){var s=e,l=p,y=i,d=t,h=[],p=s._versions,g=s._dbSchema=Tn(0,s.idbdb,d);return(p=p.filter(function(v){return v._cfg.version>=l})).length===0?E.resolve():(p.forEach(function(v){h.push(function(){var b,w,x,P=g,k=v._cfg.dbschema,K=(In(s,P,d),In(s,k,d),g=s._dbSchema=k,ht(P,k)),O=(K.add.forEach(function(S){dt(d,S[0],S[1].primKey,S[1].indexes)}),K.change.forEach(function(S){if(S.recreate)throw new j.Upgrade("Not yet support for changing primary key");var _=d.objectStore(S.name);S.add.forEach(function(C){return Dn(_,C)}),S.change.forEach(function(C){_.deleteIndex(C.name),Dn(_,C)}),S.del.forEach(function(C){return _.deleteIndex(C)})}),v._cfg.contentUpgrade);if(O&&v._cfg.version>l)return jn(s,d),y._memoizedTables={},b=It(k),K.del.forEach(function(S){b[S]=P[S]}),ft(s,[s.Transaction.prototype]),Cn(s,[s.Transaction.prototype],W(b),b),y.schema=b,(w=Yn(O))&&Ue(),k=E.follow(function(){var S;(x=O(y))&&w&&(S=ve.bind(null,null),x.then(S,S))}),x&&typeof x.then=="function"?E.resolve(x):k.then(function(){return x})}),h.push(function(b){var w,x,P=v._cfg.dbschema;w=P,x=b,[].slice.call(x.db.objectStoreNames).forEach(function(k){return w[k]==null&&x.db.deleteObjectStore(k)}),ft(s,[s.Transaction.prototype]),Cn(s,[s.Transaction.prototype],s._storeNames,s._dbSchema),y.schema=s._dbSchema}),h.push(function(b){s.idbdb.objectStoreNames.contains("$meta")&&(Math.ceil(s.idbdb.version/10)===v._cfg.version?(s.idbdb.deleteObjectStore("$meta"),delete s._dbSchema.$meta,s._storeNames=s._storeNames.filter(function(w){return w!=="$meta"})):b.objectStore("$meta").put(v._cfg.version,"version"))})}),(function v(){return h.length?E.resolve(h.shift()(y.idbtrans)).then(v):E.resolve()})().then(function(){ar(g,d)}))}).catch(a);var c,m;W(o).forEach(function(f){dt(t,f,o[f].primKey,o[f].indexes)}),jn(e,t),E.follow(function(){return e.on.populate.fire(i)}).catch(a)})}function Gr(e,n){ar(e._dbSchema,n),n.db.version%10!=0||n.objectStoreNames.contains("$meta")||n.db.createObjectStore("$meta").add(Math.ceil(n.db.version/10-1),"version");var t=Tn(0,e.idbdb,n);In(e,e._dbSchema,n);for(var r=0,o=ht(t,e._dbSchema).change;r<o.length;r++){var i=(a=>{if(a.change.length||a.recreate)return console.warn("Unable to patch indexes of table ".concat(a.name," because it has changes on the type of index or primary key.")),{value:void 0};var u=n.objectStore(a.name);a.add.forEach(function(c){ae&&console.debug("Dexie upgrade patch: Creating missing index ".concat(a.name,".").concat(c.src)),Dn(u,c)})})(o[r]);if(typeof i=="object")return i.value}}function ht(e,n){var t,r={del:[],add:[],change:[]};for(t in e)n[t]||r.del.push(t);for(t in n){var o=e[t],i=n[t];if(o){var a={name:t,def:i,recreate:!1,del:[],add:[],change:[]};if(""+(o.primKey.keyPath||"")!=""+(i.primKey.keyPath||"")||o.primKey.auto!==i.primKey.auto)a.recreate=!0,r.change.push(a);else{var u=o.idxByName,c=i.idxByName,m=void 0;for(m in u)c[m]||a.del.push(m);for(m in c){var f=u[m],s=c[m];f?f.src!==s.src&&a.change.push(s):a.add.push(s)}(0<a.del.length||0<a.add.length||0<a.change.length)&&r.change.push(a)}}else r.add.push([t,i])}return r}function dt(e,n,t,r){var o=e.db.createObjectStore(n,t.keyPath?{keyPath:t.keyPath,autoIncrement:t.auto}:{autoIncrement:t.auto});r.forEach(function(i){return Dn(o,i)})}function ar(e,n){W(e).forEach(function(t){n.db.objectStoreNames.contains(t)||(ae&&console.debug("Dexie: Creating missing table",t),dt(n,t,e[t].primKey,e[t].indexes))})}function Dn(e,n){e.createIndex(n.name,n.keyPath,{unique:n.unique,multiEntry:n.multi})}function Tn(e,n,t){var r={};return dn(n.objectStoreNames,0).forEach(function(o){for(var i=t.objectStore(o),a=st(or(m=i.keyPath),m||"",!0,!1,!!i.autoIncrement,m&&typeof m!="string",!0),u=[],c=0;c<i.indexNames.length;++c){var f=i.index(i.indexNames[c]),m=f.keyPath,f=st(f.name,m,!!f.unique,!!f.multiEntry,!1,m&&typeof m!="string",!1);u.push(f)}r[o]=ct(o,a,u)}),r}function In(e,n,t){for(var r=t.db.objectStoreNames,o=0;o<r.length;++o){var i=r[o],a=t.objectStore(i);e._hasGetAll="getAll"in a;for(var u=0;u<a.indexNames.length;++u){var c,m=a.indexNames[u],f=a.index(m).keyPath,f=typeof f=="string"?f:"["+dn(f).join("+")+"]";n[i]&&(c=n[i].idxByName[f])&&(c.name=m,delete n[i].idxByName[f],n[i].idxByName[m]=c)}}typeof navigator<"u"&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&Q.WorkerGlobalScope&&Q instanceof Q.WorkerGlobalScope&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604&&(e._hasGetAll=!1)}function ur(e){return e.split(",").map(function(n,t){var o=n.split(":"),r=(r=o[1])==null?void 0:r.trim(),o=(n=o[0].trim()).replace(/([&*]|\+\+)/g,""),i=/^\[/.test(o)?o.match(/^\[(.*)\]$/)[1].split("+"):o;return st(o,i||null,/\&/.test(n),/\*/.test(n),/\+\+/.test(n),U(i),t===0,r)})}We.prototype._createTableSchema=ct,We.prototype._parseIndexSyntax=ur,We.prototype._parseStoresSpec=function(e,n){var t=this;W(e).forEach(function(r){if(e[r]!==null){var o=t._parseIndexSyntax(e[r]),i=o.shift();if(!i)throw new j.Schema("Invalid schema for table "+r+": "+e[r]);if(i.unique=!0,i.multi)throw new j.Schema("Primary key cannot be multiEntry*");
1o.forEach(function(a){if(a.auto)throw new j.Schema("Only primary key can be marked as autoIncrement (++)");if(!a.keyPath)throw new j.Schema("Index must have a name and cannot be an empty string")}),i=t._createTableSchema(r,i,o),n[r]=i}})},We.prototype.stores=function(t){var n=this.db,t=(this._cfg.storesSource=this._cfg.storesSource?ee(this._cfg.storesSource,t):t,n._versions),r={},o={};return t.forEach(function(i){ee(r,i._cfg.storesSource),o=i._cfg.dbschema={},i._parseStoresSpec(r,o)}),n._dbSchema=o,ft(n,[n._allTables,n,n.Transaction.prototype]),Cn(n,[n._allTables,n,n.Transaction.prototype,this._cfg.tables],W(o),o),n._storeNames=W(o),this},We.prototype.upgrade=function(e){return this._cfg.contentUpgrade=Qn(this._cfg.contentUpgrade||N,e),this};var Xr=We;function We(){}var sn=(()=>{var e,n,t;return typeof FinalizationRegistry<"u"&&typeof WeakRef<"u"?(e=new Set,n=new FinalizationRegistry(function(r){e.delete(r)}),{toArray:function(){return Array.from(e).map(function(r){return r.deref()}).filter(function(r){return r!==void 0})},add:function(r){var o=new WeakRef(r._novip);e.add(o),n.register(r._novip,o,o),e.size>r._options.maxConnections&&(o=e.values().next().value,e.delete(o),n.unregister(o))},remove:function(r){if(r)for(var o=e.values(),i=o.next();!i.done;){var a=i.value;if(a.deref()===r._novip)return e.delete(a),void n.unregister(a);i=o.next()}}}):(t=[],{toArray:function(){return t},add:function(r){t.push(r._novip)},remove:function(r){r&&(r=t.indexOf(r._novip))!==-1&&t.splice(r,1)}})})();function pt(e,n){var t=e._dbNamesDB;return t||(t=e._dbNamesDB=new de(kn,{addons:[],indexedDB:e,IDBKeyRange:n})).version(1).stores({dbnames:"name"}),t.table("dbnames")}function yt(e){return e&&typeof e.databases=="function"}function mt(e){return me(function(){return A.letThrough=!0,e()})}function vt(e){return!("from"in e)}var G=function(e,n){var t;if(!this)return t=new G,e&&"d"in e&&ee(t,e),t;ee(this,arguments.length?{d:1,from:e,to:1<arguments.length?n:e}:{d:0})};function cn(e,n,t){var r=B(n,t);if(!isNaN(r)){if(0<r)throw RangeError();if(vt(e))return ee(e,{from:n,to:t,d:1});var r=e.l,o=e.r;if(B(t,e.from)<0)return r?cn(r,n,t):e.l={from:n,to:t,d:1,l:null,r:null},cr(e);if(0<B(n,e.to))return o?cn(o,n,t):e.r={from:n,to:t,d:1,l:null,r:null},cr(e);B(n,e.from)<0&&(e.from=n,e.l=null,e.d=o?o.d+1:1),0<B(t,e.to)&&(e.to=t,e.r=null,e.d=e.l?e.l.d+1:1),n=!e.r,r&&!e.l&&ln(e,r),o&&n&&ln(e,o)}}function ln(e,n){vt(n)||(function t(r,o){var i=o.from,a=o.l,u=o.r;cn(r,i,o.to),a&&t(r,a),u&&t(r,u)})(e,n)}function sr(e,n){var t=qn(n),r=t.next();if(!r.done)for(var o=r.value,i=qn(e),a=i.next(o.from),u=a.value;!r.done&&!a.done;){if(B(u.from,o.to)<=0&&0<=B(u.to,o.from))return!0;B(o.from,u.from)<0?o=(r=t.next(u.from)).value:u=(a=i.next(o.from)).value}return!1}function qn(e){var n=vt(e)?null:{s:0,n:e};return{next:function(t){for(var r=0<arguments.length;n;)switch(n.s){case 0:if(n.s=1,r)for(;n.n.l&&B(t,n.n.from)<0;)n={up:n,n:n.n.l,s:1};else for(;n.n.l;)n={up:n,n:n.n.l,s:1};case 1:if(n.s=2,!r||B(t,n.n.to)<=0)return{value:n.n,done:!1};case 2:if(n.n.r){n.s=3,n={up:n,n:n.n.r,s:0};continue}case 3:n=n.up}return{done:!0}}}}function cr(e){var n,t,r,o=(((o=e.r)==null?void 0:o.d)||0)-(((o=e.l)==null?void 0:o.d)||0),o=1<o?"r":o<-1?"l":"";o&&(n=o=="r"?"l":"r",t=T({},e),r=e[o],e.from=r.from,e.to=r.to,e[o]=r[o],t[o]=r[n],(e[n]=t).d=lr(t)),e.d=lr(e)}function lr(t){var n=t.r,t=t.l;return(n?t?Math.max(n.d,t.d):n.d:t?t.d:0)+1}function Rn(e,n){return W(n).forEach(function(t){e[t]?ln(e[t],n[t]):e[t]=(function r(o){var i,a,u={};for(i in o)ne(o,i)&&(a=o[i],u[i]=!a||typeof a!="object"||Rt.has(a.constructor)?a:r(a));return u})(n[t])}),e}function gt(e,n){return e.all||n.all||Object.keys(e).some(function(t){return n[t]&&sr(n[t],e[t])})}qe(G.prototype,((te={add:function(e){return ln(this,e),this},addKey:function(e){return cn(this,e,e),this},addKeys:function(e){var n=this;return e.forEach(function(t){return cn(n,t,t)}),this},hasKey:function(e){var n=qn(this).next(e).value;return n&&B(n.from,e)<=0&&0<=B(n.to,e)}})[Wn]=function(){return qn(this)},te));var Ce={},bt={},wt=!1;function Bn(e){Rn(bt,e),wt||(wt=!0,setTimeout(function(){wt=!1,_t(bt,!(bt={}))}
vendor: 4,382 bytes, line 1
1,0))}function _t(e,n){n===void 0&&(n=!1);var t=new Set;if(e.all)for(var r=0,o=Object.values(Ce);r<o.length;r++)fr(u=o[r],e,t,n);else for(var i in e){var a,u,i=/^idb\:\/\/(.*)\/(.*)\//.exec(i);i&&(a=i[1],i=i[2],u=Ce["idb://".concat(a,"/").concat(i)])&&fr(u,e,t,n)}t.forEach(function(c){return c()})}function fr(e,n,t,r){for(var o=[],i=0,a=Object.entries(e.queries.query);i<a.length;i++){for(var u=a[i],c=u[0],m=[],f=0,s=u[1];f<s.length;f++){var l=s[f];gt(n,l.obsSet)?l.subscribers.forEach(function(p){return t.add(p)}):r&&m.push(l)}r&&o.push([c,m])}if(r)for(var y=0,d=o;y<d.length;y++){var h=d[y],c=h[0],m=h[1];e.queries.query[c]=m}}function Hr(e){var n=e._state,t=e._deps.indexedDB;if(n.isBeingOpened||e.idbdb)return n.dbReadyPromise.then(function(){return n.dbOpenError?V(n.dbOpenError):e});n.isBeingOpened=!0,n.dbOpenError=null,n.openComplete=!1;var r=n.openCanceller,o=Math.round(10*e.verno),i=!1;function a(){if(n.openCanceller!==r)throw new j.DatabaseClosed("db.open() was cancelled")}function u(){return new E(function(l,y){if(a(),!t)throw new j.MissingAPI;var d=e.name,h=n.autoSchema||!o?t.open(d):t.open(d,o);if(!h)throw new j.MissingAPI;h.onerror=ie(y),h.onblocked=L(e._fireOnBlocked),h.onupgradeneeded=L(function(p){var g;f=h.transaction,n.autoSchema&&!e._options.allowEmptyDB?(h.onerror=on,f.abort(),h.result.close(),(g=t.deleteDatabase(d)).onsuccess=g.onerror=L(function(){y(new j.NoSuchDatabase("Database ".concat(d," doesnt exist")))})):(f.onerror=ie(y),g=p.oldVersion>Math.pow(2,62)?0:p.oldVersion,s=g<1,e.idbdb=h.result,i&&Gr(e,f),Qr(e,g/10,f,y))},y),h.onsuccess=L(function(){f=null;var p,g,v,b,w,x,P=e.idbdb=h.result,k=dn(P.objectStoreNames);if(0<k.length)try{var K=P.transaction((w=k).length===1?w[0]:w,"readonly");if(n.autoSchema)x=P,b=K,(v=e).verno=x.version/10,b=v._dbSchema=Tn(0,x,b),v._storeNames=dn(x.objectStoreNames,0),Cn(v,[v._allTables],W(b),b);else if(In(e,e._dbSchema,K),g=K,((g=ht(Tn(0,(p=e).idbdb,g),p._dbSchema)).add.length||g.change.some(function(O){return O.add.length||O.change.length}))&&!i)return console.warn("Dexie SchemaDiff: Schema was extended without increasing the number passed to db.version(). Dexie will add missing parts and increment native version number to workaround this."),P.close(),o=P.version+1,i=!0,l(u());jn(e,K)}catch(O){}sn.add(e),P.onversionchange=L(function(O){n.vcFired=!0,e.on("versionchange").fire(O)}),P.onclose=L(function(){e.close({disableAutoOpen:!1})}),s&&(k=e._deps,w=d,yt(x=k.indexedDB)||w===kn||pt(x,k.IDBKeyRange).put({name:w}).catch(N)),l()},y)}).catch(function(l){switch(l==null?void 0:l.name){case"UnknownError":if(0<n.PR1398_maxLoop)return n.PR1398_maxLoop--,console.warn("Dexie: Workaround for Chrome UnknownError on open()"),u();break;case"VersionError":if(0<o)return o=0,u()}return E.reject(l)})}var c,m=n.dbReadyResolve,f=null,s=!1;return E.race([r,(typeof navigator>"u"?E.resolve():!navigator.userAgentData&&/Safari\//.test(navigator.userAgent)&&!/Chrom(e|ium)\//.test(navigator.userAgent)&&indexedDB.databases?new Promise(function(l){function y(){return indexedDB.databases().finally(l)}c=setInterval(y,100),y()}).finally(function(){return clearInterval(c)}):Promise.resolve()).then(u)]).then(function(){return a(),n.onReadyBeingFired=[],E.resolve(mt(function(){return e.on.ready.fire(e.vip)})).then(function l(){var y;if(0<n.onReadyBeingFired.length)return y=n.onReadyBeingFired.reduce(Qn,N),n.onReadyBeingFired=[],E.resolve(mt(function(){return y(e.vip)})).then(l)})}).finally(function(){n.openCanceller===r&&(n.onReadyBeingFired=null,n.isBeingOpened=!1)}).catch(function(l){n.dbOpenError=l;try{f&&f.abort()}catch(y){}return r===n.openCanceller&&e._close(),V(l)}).finally(function(){n.openComplete=!0,m()}).then(function(){var l;return s&&(l={},e.tables.forEach(function(y){y.schema.indexes.forEach(function(d){d.name&&(l["idb://".concat(e.name,"/").concat(y.name,"/").concat(d.name)]=new G(-1/0,[[[]]]))}),l["idb://".concat(e.name,"/").concat(y.name,"/")]=l["idb://".concat(e.name,"/").concat(y.name,"/:dels")]=new G(-1/0,[[[]]])}),we(An).fire(l),_t(l,!0)),e})}function xt(e){function n(i){return e.next(i)}var t=o(n),r=o(function(i){return e.throw(i)});function o(i){return function(u){var u=i(u),c=u.value;return u.done?c:c&&typeof c.then=="function"?c.then(t,r):U(c)?Promise.all(c).then(t,r):t(c)}}return o(n)()}function Fn(e,n,t){for(var r=U(e)?e.slice():[e],o=0;o<t;++o)r.push(n);return r}
1var Jr={stack:"dbcore",name:"VirtualIndexMiddleware",level:1,create:function(e){return T(T({},e),{table:function(r){var t=e.table(r),r=t.schema,o=Object.create(null),i=[];function a(l,y,d){var v=un(l),h=o[v]=o[v]||[],p=l==null?0:typeof l=="string"?1:l.length,g=0<y,v=T(T({},d),{name:g?"".concat(v,"(virtual-from:").concat(d.name,")"):d.name,lowLevelIndex:d,isVirtual:g,keyTail:y,keyLength:p,extractKey:lt(l),unique:!g&&d.unique});return h.push(v),v.isPrimaryKey||i.push(v),1<p&&a(p===2?l[0]:l.slice(0,p-1),y+1,d),h.sort(function(b,w){return b.keyTail-w.keyTail}),v}var u=a(r.primaryKey.keyPath,0,r.primaryKey);o[":id"]=[u];for(var c=0,m=r.indexes;c<m.length;c++){var f=m[c];a(f.keyPath,0,f)}function s(l){var y,d=l.query.index;return d.isVirtual?T(T({},l),{query:{index:d.lowLevelIndex,range:(y=l.query.range,d=d.keyTail,{type:y.type===1?2:y.type,lower:Fn(y.lower,y.lowerOpen?e.MAX_KEY:e.MIN_KEY,d),lowerOpen:!0,upper:Fn(y.upper,y.upperOpen?e.MIN_KEY:e.MAX_KEY,d),upperOpen:!0})}}):l}return T(T({},t),{schema:T(T({},r),{primaryKey:u,indexes:i,getIndexByKeyPath:function(l){return(l=o[un(l)])&&l[0]}}),count:function(l){return t.count(s(l))},query:function(l){return t.query(s(l))},openCursor:function(l){var y=l.query.index,d=y.keyTail,h=y.keyLength;return y.isVirtual?t.openCursor(s(l)).then(function(g){return g&&p(g)}):t.openCursor(l);function p(g){return Object.create(g,{continue:{value:function(v){v!=null?g.continue(Fn(v,l.reverse?e.MAX_KEY:e.MIN_KEY,d)):l.unique?g.continue(g.key.slice(0,h).concat(l.reverse?e.MIN_KEY:e.MAX_KEY,d)):g.continue()}},continuePrimaryKey:{value:function(v,b){g.continuePrimaryKey(Fn(v,e.MAX_KEY,d),b)}},primaryKey:{get:function(){return g.primaryKey}},key:{get:function(){var v=g.key;return h===1?v[0]:v.slice(0,h)}},value:{get:function(){return g.value}}})}}})}})}};function kt(e,n,t,r){return t=t||{},r=r||"",W(e).forEach(function(o){var i,a,u;ne(n,o)?(i=e[o],a=n[o],typeof i=="object"&&typeof a=="object"&&i&&a?(u=zn(i))!==zn(a)?t[r+o]=n[o]:u==="Object"?kt(i,a,t,r+o+"."):i!==a&&(t[r+o]=n[o]):i!==a&&(t[r+o]=n[o])):t[r+o]=void 0}),W(n).forEach(function(o){ne(e,o)||(t[r+o]=n[o])}),t}function Ot(e,n){return n.type==="delete"?n.keys:n.keys||n.values.map(e.extractKey)}var Zr={stack:"dbcore",name:"HooksMiddleware",level:2,create:function(e){return T(T({},e),{table:function(n){var t=e.table(n),r=t.schema.primaryKey;return T(T({},t),{mutate:function(o){var i=A.trans,a=i.table(n).hook,u=a.deleting,c=a.creating,m=a.updating;switch(o.type){case"add":if(c.fire===N)break;return i._promise("readwrite",function(){return f(o)},!0);case"put":if(c.fire===N&&m.fire===N)break;return i._promise("readwrite",function(){return f(o)},!0);case"delete":if(u.fire===N)break;return i._promise("readwrite",function(){return f(o)},!0);case"deleteRange":if(u.fire===N)break;return i._promise("readwrite",function(){return(function s(l,y,d){return t.query({trans:l,values:!1,query:{index:r,range:y},limit:d}).then(function(h){var p=h.result;return f({type:"delete",keys:p,trans:l}).then(function(g){return 0<g.numFailures?Promise.reject(g.failures[0]):p.length<d?{failures:[],numFailures:0,lastResult:void 0}:s(l,T(T({},y),{lower:p[p.length-1],lowerOpen:!0}),d)})})})(o.trans,o.range,1e4)},!0)}return t.mutate(o);function f(s){var l,y,d,h=A.trans,p=s.keys||Ot(r,s);if(p)return(s=s.type==="add"||s.type==="put"?T(T({},s),{keys:p}):T({},s)).type!=="delete"&&(s.values=hn([],s.values)),s.keys&&(s.keys=hn([],s.keys)),l=t,d=p,((y=s).type==="add"?Promise.resolve([]):l.getMany({trans:y.trans,keys:d,cache:"immutable"})).then(function(g){var v=p.map(function(b,w){var x,P,k,K=g[w],O={onerror:null,onsuccess:null};return s.type==="delete"?u.fire.call(O,b,K,h):s.type==="add"||K===void 0?(x=c.fire.call(O,b,s.values[w],h),b==null&&x!=null&&(s.keys[w]=b=x,r.outbound||Z(s.values[w],r.keyPath,b))):(x=kt(K,s.values[w]),(P=m.fire.call(O,x,b,K,h))&&(k=s.values[w],Object.keys(P).forEach(function(S){ne(k,S)?k[S]=P[S]:Z(k,S,P[S])}))),O});return t.mutate(s).then(function(b){for(var w=b.failures,x=b.results,P=b.numFailures,b=b.lastResult,k=0;k<p.length;++k){var K=(x||p)[k],O=v[k];K==null?O.onerror&&O.onerror(w[k]):O.onsuccess&&O.onsuccess(s.type==="put"&&g[k]?s.values[k]:K)}return{failures:w,results:x,numFailures:P,lastResult:b}}).catch(function(b){return v.forEach(function(w){return w.onerror&&w.onerror
1(b)}),Promise.reject(b)})});throw new Error("Keys missing")}}})}})}};function hr(e,n,t){try{if(!n||n.keys.length<e.length)return null;for(var r=[],o=0,i=0;o<n.keys.length&&i<e.length;++o)B(n.keys[o],e[i])===0&&(r.push(t?xe(n.values[o]):n.values[o]),++i);return r.length===e.length?r:null}catch(a){return null}}var eo={stack:"dbcore",level:-1,create:function(e){return{table:function(n){var t=e.table(n);return T(T({},t),{getMany:function(r){var o;return r.cache?(o=hr(r.keys,r.trans._cache,r.cache==="clone"))?E.resolve(o):t.getMany(r).then(function(i){return r.trans._cache={keys:r.keys,values:r.cache==="clone"?xe(i):i},i}):t.getMany(r)},mutate:function(r){return r.type!=="add"&&(r.trans._cache=null),t.mutate(r)}})}}}};function dr(e,n){return e.trans.mode==="readonly"&&!!e.subscr&&!e.trans.explicit&&e.trans.db._options.cache!=="disabled"&&!n.schema.primaryKey.outbound}function pr(e,n){switch(e){case"query":return n.values&&!n.unique;case"get":case"getMany":case"count":case"openCursor":return!1}}var no={stack:"dbcore",level:0,name:"Observability",create:function(e){var n=e.schema.name,t=new G(e.MIN_KEY,e.MAX_KEY);return T(T({}
1,e),{transaction:function(r,o,i){if(A.subscr&&o!=="readonly")throw new j.ReadOnly("Readwrite transaction in liveQuery context. Querier source: ".concat(A.querier));return e.transaction(r,o,i)},table:function(r){function o(p){var h,p=p.query;return[h=p.index,new G((h=(p=p.range).lower)!=null?h:e.MIN_KEY,(h=p.upper)!=null?h:e.MAX_KEY)]}var i=e.table(r),a=i.schema,u=a.primaryKey,c=a.indexes,m=u.extractKey,f=u.outbound,s=u.autoIncrement&&c.filter(function(d){return d.compound&&d.keyPath.includes(u.keyPath)}),l=T(T({},i),{mutate:function(d){function h(_){return _="idb://".concat(n,"/").concat(r,"/").concat(_),w[_]||(w[_]=new G)}var p,g,v,b=d.trans,w=d.mutatedParts||(d.mutatedParts={}),x=h(""),P=h(":dels"),k=d.type,O=d.type==="deleteRange"?[d.range]:d.type==="delete"?[d.keys]:d.values.length<50?[Ot(u,d).filter(function(_){return _}),d.values]:[],K=O[0],O=O[1],S=d.trans._cache;return U(K)?(x.addKeys(K),(k=k==="delete"||K.length===O.length?hr(K,S):null)||P.addKeys(K),(k||O)&&(p=h,g=k,v=O,a.indexes.forEach(function(_){var C=p(_.name||"");function D(R){return R!=null?_.extractKey(R):null}function q(R){_.multiEntry&&U(R)?R.forEach(function(oe){return C.addKey(oe)}):C.addKey(R)}(g||v).forEach(function(R,X){var I=g&&D(g[X]),X=v&&D(v[X]);B(I,X)!==0&&(I!=null&&q(I),X!=null)&&q(X)})}))):K?(O={from:(S=K.lower)!=null?S:e.MIN_KEY,to:(k=K.upper)!=null?k:e.MAX_KEY},P.add(O),x.add(O)):(x.add(t),P.add(t),a.indexes.forEach(function(_){return h(_.name).add(t)})),i.mutate(d).then(function(_){return!K||d.type!=="add"&&d.type!=="put"||(x.addKeys(_.results),s&&s.forEach(function(C){for(var D=d.values.map(function(I){return C.extractKey(I)}),q=C.keyPath.findIndex(function(I){return I===u.keyPath}),R=0,oe=_.results.length;R<oe;++R)D[R][q]=_.results[R];h(C.name).addKeys(D)})),b.mutatedParts=Rn(b.mutatedParts||{},w),_})}}),y={get:function(d){return[u,new G(d.key)]},getMany:function(d){return[u,new G().addKeys(d.keys)]},count:o,query:o,openCursor:o};return W(y).forEach(function(d){l[d]=function(h){var p=A.subscr,g=!!p,v=dr(A,i)&&pr(d,h)?h.obsSet={}:p;if(g){var b,p=function(O){return O="idb://".concat(n,"/").concat(r,"/").concat(O),v[O]||(v[O]=new G)},w=p(""),x=p(":dels"),g=y[d](h),P=g[0],g=g[1];if((d==="query"&&P.isPrimaryKey&&!h.values?x:p(P.name||"")).add(g),!P.isPrimaryKey){if(d!=="count")return b=d==="query"&&f&&h.values&&i.query(T(T({},h),{values:!1})),i[d].apply(this,arguments).then(function(O){if(d==="query"){if(f&&h.values)return b.then(function(D){return D=D.result,w.addKeys(D),O});var S=h.values?O.result.map(m):O.result;(h.values?w:x).addKeys(S)}else{var _,C;if(d==="openCursor")return C=h.values,(_=O)&&Object.create(_,{key:{get:function(){return x.addKey(_.primaryKey),_.key}},primaryKey:{get:function(){var D=_.primaryKey;return x.addKey(D),D}},value:{get:function(){return C&&w.addKey(_.primaryKey),_.value}}})}return O});x.add(t)}}return i[d].apply(this,arguments)}}),l}})}};function yr(e,n,t){var r;return t.numFailures===0?n:n.type==="deleteRange"||(r=n.keys?n.keys.length:"values"in n&&n.values?n.values.length:1,t.numFailures===r)?null:(r=T({},n),U(r.keys)&&(r.keys=r.keys.filter(function(o,i){return!(i in t.failures)})),"values"in r&&U(r.values)&&(r.values=r.values.filter(function(o,i){return!(i in t.failures)})),r)}function Pt(e,n){return t=e,((r=n).lower===void 0||(r.lowerOpen?0<B(t,r.lower):0<=B(t,r.lower)))&&(t=e,(r=n).upper===void 0||(r.upperOpen?B(t,r.upper)<0:B(t,r.upper)<=0));var t,r}function mr(e,n,t,r,o,i){var a,u,c,m,f,s,l;return!t||t.length===0||(a=n.query.index,u=a.multiEntry,c=n.query.range,m=r.schema.primaryKey.extractKey,f=a.extractKey,s=(a.lowLevelIndex||a).extractKey,(r=t.reduce(function(y,d){var h=y,p=[];if(d.type==="add"||d.type==="put")for(var g=new G,v=d.values.length-1;0<=v;--v){var b,w=d.values[v],x=m(w);!g.hasKey(x)&&(b=f(w),u&&U(b)?b.some(function(S){return Pt(S,c)}):Pt(b,c))&&(g.addKey(x),p.push(w))}switch(d.type){case"add":var P=new G().addKeys(n.values?y.map(function(_){return m(_)}):y),h=y.concat(n.values?p.filter(function(_){return _=m(_),!P.hasKey(_)&&(P.addKey(_),!0)}):p.map(function(_){return m(_)}
1).filter(function(_){return!P.hasKey(_)&&(P.addKey(_),!0)}));break;case"put":var k=new G().addKeys(d.values.map(function(_){return m(_)}));h=y.filter(function(_){return!k.hasKey(n.values?m(_):_)}).concat(n.values?p:p.map(function(_){return m(_)}));break;case"delete":var K=new G().addKeys(d.keys);h=y.filter(function(_){return!K.hasKey(n.values?m(_):_)});break;case"deleteRange":var O=d.range;h=y.filter(function(_){return!Pt(m(_),O)})}return h},e))===e)?e:(l=function(y,d){return B(s(y),s(d))||B(m(y),m(d))},r.sort(n.direction==="prev"||n.direction==="prevunique"?function(y,d){return l(d,y)}:l),n.limit&&n.limit<1/0&&(r.length>n.limit?r.length=n.limit:e.length===n.limit&&r.length<n.limit&&(o.dirty=!0)),i?Object.freeze(r):r)}function vr(e,n){return B(e.lower,n.lower)===0&&B(e.upper,n.upper)===0&&!!e.lowerOpen==!!n.lowerOpen&&!!e.upperOpen==!!n.upperOpen}function to(e,n){return((t,r,o,i)=>{if(t===void 0)return r!==void 0?-1:0;if(r===void 0)return 1;if((t=B(t,r))===0){if(o&&i)return 0;if(o)return 1;if(i)return-1}return t})(e.lower,n.lower,e.lowerOpen,n.lowerOpen)<=0&&0<=((t,r,o,i)=>{if(t===void 0)return r!==void 0?1:0;if(r===void 0)return-1;if((t=B(t,r))===0){if(o&&i)return 0;if(o)return-1;if(i)return 1}return t})(e.upper,n.upper,e.upperOpen,n.upperOpen)}function ro(e,n,t,r){e.subscribers.add(t),r.addEventListener("abort",function(){var o,i;e.subscribers.delete(t),e.subscribers.size===0&&(o=e,i=n,setTimeout(function(){o.subscribers.size===0&&ke(i,o)},3e3))})}var oo={stack:"dbcore",level:0,name:"Cache",create:function(e){var n=e.schema.name;return T(T({},e),{transaction:function(t,r,o){var i,a,u=e.transaction(t,r,o);return r==="readwrite"&&(o=(i=new AbortController).signal,u.addEventListener("abort",(a=function(c){return function(){if(i.abort(),r==="readwrite"){for(var m=new Set,f=0,s=t;f<s.length;f++){var l=s[f],y=Ce["idb://".concat(n,"/").concat(l)];if(y){var d=e.table(l),h=y.optimisticOps.filter(function(_){return _.trans===u});if(u._explicit&&c&&u.mutatedParts)for(var p=0,g=Object.values(y.queries.query);p<g.length;p++)for(var v=0,b=(P=g[p]).slice();v<b.length;v++)gt((k=b[v]).obsSet,u.mutatedParts)&&(ke(P,k),k.subscribers.forEach(function(_){return m.add(_)}));else if(0<h.length){y.optimisticOps=y.optimisticOps.filter(function(_){return _.trans!==u});for(var w=0,x=Object.values(y.queries.query);w<x.length;w++)for(var P,k,K,O=0,S=(P=x[w]).slice();O<S.length;O++)(k=S[O]).res!=null&&u.mutatedParts&&(c&&!k.dirty?(K=Object.isFrozen(k.res),K=mr(k.res,k.req,h,d,k,K),k.dirty?(ke(P,k),k.subscribers.forEach(function(_){return m.add(_)})):K!==k.res&&(k.res=K,k.promise=E.resolve({result:K}))):(k.dirty&&ke(P,k),k.subscribers.forEach(function(_){return m.add(_)})))}}}m.forEach(function(_){return _()})}}})(!1),{signal:o}),u.addEventListener("error",a(!1),{signal:o}),u.addEventListener("complete",a(!0),{signal:o})),u},table:function(t){var r=e.table(t),o=r.schema.primaryKey;return T(T({},r),{mutate:function(i){var a,u=A.trans;return!o.outbound&&u.db._options.cache!=="disabled"&&!u.explicit&&u.idbtrans.mode==="readwrite"&&(a=Ce["idb://".concat(n,"/").concat(t)])?(u=r.mutate(i),i.type!=="add"&&i.type!=="put"||!(50<=i.values.length||Ot(o,i).some(function(c){return c==null}))?(a.optimisticOps.push(i),i.mutatedParts&&Bn(i.mutatedParts),u.then(function(c){0<c.numFailures&&(ke(a.optimisticOps,i),(c=yr(0,i,c))&&a.optimisticOps.push(c),i.mutatedParts)&&Bn(i.mutatedParts)}),u.catch(function(){ke(a.optimisticOps,i),i.mutatedParts&&Bn(i.mutatedParts)})):u.then(function(c){var m=yr(0,T(T({},i),{values:i.values.map(function(f,s){var l;return c.failures[s]?f:(Z(l=(l=o.keyPath)!=null&&l.includes(".")?xe(f):T({},f),o.keyPath,c.results[s]),l)})}),c);a.optimisticOps.push(m),queueMicrotask(function(){return i.mutatedParts&&Bn(i.mutatedParts)})}),u):r.mutate(i)},query:function(i){var a,u,c,m,f,s,l;return dr(A,r)&&pr("query",i)?(a=((c=A.trans)==null?void 0:c.db._options.cache)==="immutable",u=(c=A).requery,c=c.signal,s=((y,d,h,p)=>{var g=Ce["idb://".concat(y,"/").concat(d)];if(!g)return[];if(!(y=g.queries[h]))return[null,!1,g,null];var v=y[(p.query?p.query.index.name:null)||""];if(!v)return[null,!1,g,null];switch(h){case"query":var b=(w=p.direction)!=null?w:"next",w=v.find(function(x){var P;return x.req.limit===p.limit&&x.req.values===p.values&&((P=x.req.direction)!=null?P:"next")===b&&vr(x.req.query.range,p.query.range)});return w?[w,!0,g,v]:[v.find(function(x){var P;return("limit"in x.req?x.req.limit:1/0)>=p.limit&&((P=x.req.direction)!=null?P:"next")===b&&(!p.values||x.req.values)&&to(x.req.query.range,p.query.range)}),!1,g,v];case"count":return w=v.find(function(x){return vr(x.req.query.range,p.query.range)}),[w,!!w,g,v]}})(n,t,"query",i),l=s[0],m=s[2],f=s[3],l&&s[1]?l.obsSet=i.obsSet:(s=r.query(i).then(function(y){var d=y.result;if(l&&(l.res=d),a){for(var h=0,p=d.length;h<p;++h)Object.freeze(d[h]);Object.freeze(d)}return y}).catch(function(y){return f&&l&&ke(f,l),Promise.reject(y)}),l={obsSet:i.obsSet,promise:s,subscribers:new Set,type:"query",req:i,dirty:!1},f?f.push(l):(f=[l],(m=m||(Ce["idb://".concat(n,"/").concat(t)]={queries:{query:{},count:{}},objs:new Map,optimisticOps:[],unsignaledParts:{}})).queries.query[i.query.index.name||""]=f)),ro(l,f,u,c),l.promise.then(function(y){return y=mr(y.result,i,m==null?void 0:m.optimisticOps,r,l,a),{result:a?y:xe(y)}})):r.query(i)}})}})}};function Nn(e,n){return new Proxy(e,{get:function(t,r,o){return r==="db"?n:Reflect.get(t,r,o)}})}z.prototype.version=function(e){if(isNaN(e)||e<.1)throw new j.Type("Given version is not a positive number");if(e=Math.round(10*e)/10,this.idbdb||this._state.isBeingOpened)throw new j.Schema("Cannot add version when database is open");this.verno=Math.max(this.verno,e);var n=this._versions,t=n.filter(function(r){return r._cfg.version===e})[0];return t||(t=new this.Version(e),n.push(t),n.sort($r),t.stores({}),this._state.autoSchema=!1),t},z.prototype._whenReady=function(e){var n=this;return this.idbdb&&(this._state.openComplete||A.letThrough||this._vip)?e():new E(function(t,r){if(n._state.openComplete)return r(new j.DatabaseClosed(n._state.dbOpenError));if(!n._state.isBeingOpened){if(!n._state.autoOpen)return void r(new j.DatabaseClosed);n.open().catch(N)}n._state.dbReadyPromise.then(t,r)}
1).then(e)},z.prototype.use=function(o){var n=o.stack,t=o.create,r=o.level,o=o.name,i=(o&&this.unuse({stack:n,name:o}),this._middlewares[n]||(this._middlewares[n]=[]));return i.push({stack:n,create:t,level:r==null?10:r,name:o}),i.sort(function(a,u){return a.level-u.level}),this},z.prototype.unuse=function(e){var n=e.stack,t=e.name,r=e.create;return n&&this._middlewares[n]&&(this._middlewares[n]=this._middlewares[n].filter(function(o){return r?o.create!==r:!!t&&o.name!==t})),this},z.prototype.open=function(){var e=this;return Se(fe,function(){return Hr(e)})},z.prototype._close=function(){this.on.close.fire(new CustomEvent("close"));var e=this._state;if(sn.remove(this),this.idbdb){try{this.idbdb.close()}catch(n){}this.idbdb=null}e.isBeingOpened||(e.dbReadyPromise=new E(function(n){e.dbReadyResolve=n}),e.openCanceller=new E(function(n,t){e.cancelOpen=t}))},z.prototype.close=function(n){var n=(n===void 0?{disableAutoOpen:!0}:n).disableAutoOpen,t=this._state;n?(t.isBeingOpened&&t.cancelOpen(new j.DatabaseClosed),this._close(),t.autoOpen=!1,t.dbOpenError=new j.DatabaseClosed):(this._close(),t.autoOpen=this._options.autoOpen||t.isBeingOpened,t.openComplete=!1,t.dbOpenError=null)},z.prototype.delete=function(e){var n=this,t=(e===void 0&&(e={disableAutoOpen:!0}),0<arguments.length&&typeof arguments[0]!="object"),r=this._state;return new E(function(o,i){function a(){n.close(e);var u=n._deps.indexedDB.deleteDatabase(n.name);u.onsuccess=L(function(){var c,m,f;c=n._deps,m=n.name,yt(f=c.indexedDB)||m===kn||pt(f,c.IDBKeyRange).delete(m).catch(N),o()}),u.onerror=ie(i),u.onblocked=n._fireOnBlocked}if(t)throw new j.InvalidArgument("Invalid closeOptions argument to db.delete()");r.isBeingOpened?r.dbReadyPromise.then(a):a()})},z.prototype.backendDB=function(){return this.idbdb},z.prototype.isOpen=function(){return this.idbdb!==null},z.prototype.hasBeenClosed=function(){var e=this._state.dbOpenError;return e&&e.name==="DatabaseClosed"},z.prototype.hasFailed=function(){return this._state.dbOpenError!==null},z.prototype.dynamicallyOpened=function(){return this._state.autoSchema},Object.defineProperty(z.prototype,"tables",{get:function(){var e=this;return W(this._allTables).map(function(n){return e._allTables[n]})},enumerable:!1,configurable:!0}),z.prototype.transaction=function(){var e=(function(n,t,r){var o=arguments.length;if(o<2)throw new j.InvalidArgument("Too few arguments");for(var i=new Array(o-1);--o;)i[o-1]=arguments[o];return r=i.pop(),[n,qt(i),r]}).apply(this,arguments);return this._transaction.apply(this,e)},z.prototype._transaction=function(e,n,t){var r,o,i=this,a=A.trans,u=(a&&a.db===this&&e.indexOf("!")===-1||(a=null),e.indexOf("?")!==-1);e=e.replace("!","").replace("?","");try{if(o=n.map(function(m){if(m=m instanceof i.Table?m.name:m,typeof m!="string")throw new TypeError("Invalid table argument to Dexie.transaction(). Only Table or String are allowed");return m}),e=="r"||e===rt)r=rt;else{if(e!="rw"&&e!=ot)throw new j.InvalidArgument("Invalid transaction mode: "+e);r=ot}if(a){if(a.mode===rt&&r===ot){if(!u)throw new j.SubTransaction("Cannot enter a sub-transaction with READWRITE mode when parent transaction is READONLY");a=null}a&&o.forEach(function(m){if(a&&a.storeNames.indexOf(m)===-1){if(!u)throw new j.SubTransaction("Table "+m+" not included in parent transaction.");a=null}}),u&&a&&!a.active&&(a=null)}}catch(m){return a?a._promise(null,function(f,s){s(m)}):V(m)}var c=(function m(f,s,l,y,d){return E.resolve().then(function(){var v=A.transless||A,h=f._createTransaction(s,l,f._dbSchema,y),v=(h.explicit=!0,{trans:h,transless:v});if(y)h.idbtrans=y.idbtrans;else try{h.create(),h.idbtrans._explicit=!0,f._state.PR1398_maxLoop=3}catch(b){return b.name===$n.InvalidState&&f.isOpen()&&0<--f._state.PR1398_maxLoop?(console.warn("Dexie: Need to reopen db"),f.close({disableAutoOpen:!1}),f.open().then(function(){return m(f,s,l,null,d)})):V(b)}var p,g=Yn(d),v=(g&&Ue(),E.follow(function(){var b;(p=d.call(h,h))&&(g?(b=ve.bind(null,null),p.then(b,b)):typeof p.next=="function"&&typeof p.throw=="function"&&(p=xt(p)))},v));return(p&&typeof p.then=="function"?E.resolve(p).then(function(b){return h.active?b:V(new j.PrematureCommit("Transaction committed too early. See http://bit.ly/2kdckMn"))}):v.then(function(){return p})).then(function(b){return y&&h._resolve(),h._completion.then(function(){return b})}).catch(function(b){return h._reject(b),V(b)})})}).bind(null,this,r,o,a,t);return a?a._promise(r,c,"lock"):A.trans?Se(A.transless,function(){return i._whenReady(c)}):this._whenReady(c)},z.prototype.table=function(e){if(ne(this._allTables,e))return this._allTables[e];throw new j.InvalidTable("Table ".concat(e," does not exist"))};var de=z;function z(e,n){var t,r,o,i,a,u=this,c=(this._middlewares={}
vendor: 4,482 bytes, line 1
1,this.verno=0,z.dependencies),c=(this._options=n=T({addons:z.addons,autoOpen:!0,indexedDB:c.indexedDB,IDBKeyRange:c.IDBKeyRange,cache:"cloned",maxConnections:1e3},n),this._deps={indexedDB:n.indexedDB,IDBKeyRange:n.IDBKeyRange},n.addons),m=(this._dbSchema={},this._versions=[],this._storeNames=[],this._allTables={},this.idbdb=null,this._novip=this,{dbOpenError:null,isBeingOpened:!1,onReadyBeingFired:null,openComplete:!1,dbReadyResolve:N,dbReadyPromise:null,cancelOpen:N,openCanceller:null,autoSchema:!0,PR1398_maxLoop:3,autoOpen:n.autoOpen}),f=(m.dbReadyPromise=new E(function(s){m.dbReadyResolve=s}),m.openCanceller=new E(function(s,l){m.cancelOpen=l}),this._state=m,this.name=e,this.on=tn(this,"populate","blocked","versionchange","close",{ready:[Qn,N]}),this.once=function(s,l){var y=function(){for(var d=[],h=0;h<arguments.length;h++)d[h]=arguments[h];u.on(s).unsubscribe(y),l.apply(u,d)};return u.on(s,y)},this.on.ready.subscribe=Dt(this.on.ready.subscribe,function(s){return function(l,y){z.vip(function(){var d,h=u._state;h.openComplete?(h.dbOpenError||E.resolve().then(l),y&&s(l)):h.onReadyBeingFired?(h.onReadyBeingFired.push(l),y&&s(l)):(s(l),d=u,y||s(function p(){d.on.ready.unsubscribe(l),d.on.ready.unsubscribe(p)}))})}}),this.Collection=(t=this,rn(Mr.prototype,function(p,h){this.db=t;var y=Yt,d=null;if(h)try{y=h()}catch(v){d=v}var h=p._ctx,p=h.table,g=p.hook.reading.fire;this._ctx={table:p,index:h.index,isPrimKey:!h.index||p.schema.primKey.keyPath&&h.index===p.schema.primKey.name,range:y,keysOnly:!1,dir:"next",unique:"",algorithm:null,filter:null,replayFilter:null,justLimit:!0,isMatch:null,offset:0,limit:1/0,error:d,or:h.or,valueMapper:g!==Xe?g:null}})),this.Table=(r=this,rn(Jt.prototype,function(s,l,y){this.db=r,this._tx=y,this.name=s,this.schema=l,this.hook=r._allTables[s]?r._allTables[s].hook:tn(null,{creating:[Cr,N],reading:[jr,Xe],updating:[Tr,N],deleting:[Dr,N]})})),this.Transaction=(o=this,rn(Vr.prototype,function(s,l,y,d,h){var p=this;s!=="readonly"&&l.forEach(function(g){g=(g=y[g])==null?void 0:g.yProps,g&&(l=l.concat(g.map(function(v){return v.updatesTable})))}),this.db=o,this.mode=s,this.storeNames=l,this.schema=y,this.chromeTransactionDurability=d,this.idbtrans=null,this.on=tn(this,"complete","error","abort"),this.parent=h||null,this.active=!0,this._reculock=0,this._blockedFuncs=[],this._resolve=null,this._reject=null,this._waitingFor=null,this._waitingQueue=null,this._spinCount=0,this._completion=new E(function(g,v){p._resolve=g,p._reject=v}),this._completion.then(function(){p.active=!1,p.on.complete.fire()},function(g){var v=p.active;return p.active=!1,p.on.error.fire(g),p.parent?p.parent._reject(g):v&&p.idbtrans&&p.idbtrans.abort(),V(g)})})),this.Version=(i=this,rn(Xr.prototype,function(s){this.db=i,this._cfg={version:s,storesSource:null,dbschema:{},tables:{},contentUpgrade:null}})),this.WhereClause=(a=this,rn(rr.prototype,function(s,l,y){if(this.db=a,this._ctx={table:s,index:l===":id"?null:l,or:y},this._cmp=this._ascending=B,this._descending=function(d,h){return B(h,d)},this._max=function(d,h){return 0<B(d,h)?d:h},this._min=function(d,h){return B(d,h)<0?d:h},this._IDBKeyRange=a._deps.IDBKeyRange,!this._IDBKeyRange)throw new j.MissingAPI})),this.on("versionchange",function(s){0<s.newVersion?console.warn("Another connection wants to upgrade database '".concat(u.name,"'. Closing db now to resume the upgrade.")):console.warn("Another connection wants to delete database '".concat(u.name,"'. Closing db now to resume the delete request.")),u.close({disableAutoOpen:!1})}),this.on("blocked",function(s){!s.newVersion||s.newVersion<s.oldVersion?console.warn("Dexie.delete('".concat(u.name,"') was blocked")):console.warn("Upgrade '".concat(u.name,"' blocked by other connection holding version ").concat(s.oldVersion/10))}),this._maxKey=an(n.IDBKeyRange),this._createTransaction=function(s,l,y,d){return new u.Transaction(s,l,y,u._options.chromeTransactionDurability,d)},this._fireOnBlocked=function(s){u.on("blocked").fire(s),sn.toArray().filter(function(l){return l.name===u.name&&l!==u&&!l._state.vcFired}).map(function(l){return l.on("versionchange").fire(s)})},this.use(eo),this.use(oo),this.use(no),this.use(Jr),this.use(Zr),new Proxy(this,{get:function(s,l,y){var d;return l==="_vip"||(l==="table"?function(h){return Nn(u.table(h),f)}:(d=Reflect.get(s,l,y))instanceof Jt?Nn(d,f):l==="tables"?d.map(function(h){return Nn(h,f)}):l==="_createTransaction"?function(){return Nn(d.apply(this,arguments),f)}:d)}}));
1this.vip=f,c.forEach(function(s){return s(u)})}var Mn,Ye=typeof Symbol<"u"&&"observable"in Symbol?Symbol.observable:"@@observable",io=(Et.prototype.subscribe=function(e,n,t){return this._subscribe(e&&typeof e!="function"?e:{next:e,error:n,complete:t})},Et.prototype[Ye]=function(){return this},Et);function Et(e){this._subscribe=e}try{Mn={indexedDB:Q.indexedDB||Q.mozIndexedDB||Q.webkitIndexedDB||Q.msIndexedDB,IDBKeyRange:Q.IDBKeyRange||Q.webkitIDBKeyRange}}catch(e){Mn={indexedDB:null,IDBKeyRange:null}}function gr(e){var n,t=!1,r=new io(function(o){var i=Yn(e),a,u=!1,c={},m={},f={get closed(){return u},unsubscribe:function(){u||(u=!0,a&&a.abort(),s&&we.storagemutated.unsubscribe(d))}},s=(o.start&&o.start(f),!1),l=function(){return tt(h)};function y(){return gt(m,c)}var d=function(p){Rn(c,p),y()&&l()},h=function(){var p,g,v;!u&&Mn.indexedDB&&(c={},p={},a&&a.abort(),a=new AbortController,v=(b=>{var w=Me();try{i&&Ue();var x=me(e,b);return x=i?x.finally(ve):x}finally{w&&Le()}})(g={subscr:p,signal:a.signal,requery:l,querier:e,trans:null}),s||(we.storagemutated.subscribe(d),s=!0),Promise.resolve(v).then(function(b){t=!0,n=b,u||g.signal.aborted||(y()||(m=p,y())?l():(c={},tt(function(){return!u&&o.next&&o.next(b)})))},function(b){t=!1,["DatabaseClosedError","AbortError"].includes(b==null?void 0:b.name)||u||tt(function(){u||o.error&&o.error(b)})}))};return setTimeout(l,0),f});return r.hasValue=function(){return t},r.getValue=function(){return n},r}var De=de;function Kt(e){var n=_e;try{_e=!0,we.storagemutated.fire(e),_t(e,!0)}finally{_e=n}}qe(De,T(T({},le),{delete:function(e){return new De(e,{addons:[]}).delete()},exists:function(e){return new De(e,{addons:[]}).open().then(function(n){return n.close(),!0}).catch("NoSuchDatabaseError",function(){return!1})},getDatabaseNames:function(e){try{return n=De.dependencies,t=n.indexedDB,n=n.IDBKeyRange,(yt(t)?Promise.resolve(t.databases()).then(function(r){return r.map(function(o){return o.name}).filter(function(o){return o!==kn})}):pt(t,n).toCollection().primaryKeys()).then(e)}catch(r){return V(new j.MissingAPI)}var n,t},defineClass:function(){return function(e){ee(this,e)}},ignoreTransaction:function(e){return A.trans?Se(A.transless||fe,e):e()},vip:mt,async:function(e){return function(){try{var n=xt(e.apply(this,arguments));return n&&typeof n.then=="function"?n:E.resolve(n)}catch(t){return V(t)}}},spawn:function(e,n,t){try{var r=xt(e.apply(t,n||[]));return r&&typeof r.then=="function"?r:E.resolve(r)}catch(o){return V(o)}},currentTransaction:{get:function(){return A.trans||null}},waitFor:function(e,n){return e=E.resolve(typeof e=="function"?De.ignoreTransaction(e):e).timeout(n||6e4),A.trans?A.trans.waitFor(e):e},Promise:E,debug:{get:function(){return ae},set:function(e){Nt(e)}},derive:Re,extend:ee,props:qe,override:Dt,Events:tn,on:we,liveQuery:gr,extendObservabilitySet:Rn,getByKeyPath:se,setByKeyPath:Z,delByKeyPath:function(e,n){typeof n=="string"?Z(e,n,void 0):"length"in n&&[].map.call(n,function(t){Z(e,t,void 0)})},shallowClone:It,deepClone:xe,getObjectDiff:kt,cmp:B,asap:Tt,minKey:-1/0,addons:[],connections:{get:sn.toArray},errnames:$n,dependencies:Mn,cache:Ce,semVer:"4.4.5",version:"4.4.5".split(".").map(function(e){return parseInt(e)}).reduce(function(e,n,t){return e+n/Math.pow(10,2*t)})})),De.maxKey=an(De.dependencies.IDBKeyRange),typeof dispatchEvent<"u"&&typeof addEventListener<"u"&&(we(An,function(e){_e||(e=new CustomEvent(ut,{detail:e}),_e=!0,dispatchEvent(e),_e=!1)}),addEventListener(ut,function(e){e=e.detail,_e||Kt(e)}));var $e,_e=!1,br=function(){};return typeof BroadcastChannel<"u"&&((br=function(){($e=new BroadcastChannel(ut)).onmessage=function(e){return e.data&&Kt(e.data)}})(),typeof $e.unref=="function"&&$e.unref(),we(An,function(e){_e||$e.postMessage(e)})),typeof addEventListener<"u"&&(addEventListener("pagehide",function(e){if(!de.disableBfCache&&e.persisted){ae&&console.debug("Dexie: handling persisted pagehide"),$e!=null&&$e.close();for(var n=0,t=sn.toArray();n<t.length;n++)t[n].close({disableAutoOpen:!1})}}),addEventListener("pageshow",function(e){!de.disableBfCache&&e.persisted&&(ae&&console.debug("Dexie: handling persisted pageshow"),br(),Kt({all:new G(-1/0,[[]])}))})),E.rejectionMapper=function(e,n){return!e||e instanceof Fe||e instanceof TypeError||e instanceof SyntaxError||!e.name||!Ft[e.name]?e:(n=new Ft[e.name](n||e.message,e),"stack"in e&&ye(n,"stack",{get:function(){return this.inner.stack}}),n)},Nt(ae),T(de,Object.freeze({__proto__:null,DEFAULT_MAX_CONNECTIONS:1e3,Dexie:de,Entity:$t,PropModification:nn,RangeSet:G,add:function(e){return new nn({add:e})},cmp:B,default:de,liveQuery:gr,mergeRanges:ln,rangesOverlap:sr,remove:function(e){return new nn({remove:e})},replacePrefix:function(e,n){return new nn({replacePrefix:[e,n]})}}),{default:de}),de})})(Un)),Un.exports}var lo=co();const At=uo(lo),_r=Symbol.for("Dexie"),jt=globalThis[_r]||(globalThis[_r]=At);if(At.semVer!==jt.semVer)throw new Error("Two different versions of Dexie loaded in the same app: ".concat(At.semVer," and ").concat(jt.semVer));const{liveQuery:ho,mergeRanges:po,rangesOverlap:yo,RangeSet:mo,cmp:vo,Entity:go,PropModification:bo,replacePrefix:wo,add:_o,remove:xo,DexieYProvider:ko}=jt;export{jt as Dexie,ko as DexieYProvider,go as Entity,bo as PropModification,mo as RangeSet,_o as add,vo as cmp,jt as default,ho as liveQuery,po as mergeRanges,yo as rangesOverlap,xo as remove,wo as replacePrefix}; 2//# sourceMappingURL=import-wrapper-prod-4PiBRD_P.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.