@blackglory/structures 0.10.3 → 0.10.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12,5 +12,5 @@ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
12
12
  LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
13
13
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14
14
  PERFORMANCE OF THIS SOFTWARE.
15
- ***************************************************************************** */var ox=function(t,n){return(ox=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var e in n)Object.prototype.hasOwnProperty.call(n,e)&&(t[e]=n[e])})(t,n)};function ix(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function e(){this.constructor=t}ox(t,n),t.prototype=null===n?Object.create(n):(e.prototype=n.prototype,new e)}function ax(t){var n="function"==typeof Symbol&&Symbol.iterator,e=n&&t[n],r=0;if(e)return e.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function sx(t,n){var e="function"==typeof Symbol&&t[Symbol.iterator];if(!e)return t;var r,o,i=e.call(t),a=[];try{for(;(void 0===n||n-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(t){o={error:t}}finally{try{r&&!r.done&&(e=i.return)&&e.call(i)}finally{if(o)throw o.error}}return a}function cx(t,n,e){if(e||2===arguments.length)for(var r,o=0,i=n.length;o<i;o++)!r&&o in n||(r||(r=Array.prototype.slice.call(n,0,o)),r[o]=n[o]);return t.concat(r||Array.prototype.slice.call(n))}function ux(t){return"function"==typeof t}function lx(t){var n=t((function(t){Error.call(t),t.stack=(new Error).stack}));return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}var fx=lx((function(t){return function(n){t(this),this.message=n?n.length+" errors occurred during unsubscription:\n"+n.map((function(t,n){return n+1+") "+t.toString()})).join("\n "):"",this.name="UnsubscriptionError",this.errors=n}}));function yx(t,n){if(t){var e=t.indexOf(n);0<=e&&t.splice(e,1)}}var dx=function(){function t(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}var n;return t.prototype.unsubscribe=function(){var t,n,e,r,o;if(!this.closed){this.closed=!0;var i=this._parentage;if(i)if(this._parentage=null,Array.isArray(i))try{for(var a=ax(i),s=a.next();!s.done;s=a.next()){s.value.remove(this)}}catch(n){t={error:n}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}else i.remove(this);var c=this.initialTeardown;if(ux(c))try{c()}catch(t){o=t instanceof fx?t.errors:[t]}var u=this._finalizers;if(u){this._finalizers=null;try{for(var l=ax(u),f=l.next();!f.done;f=l.next()){var y=f.value;try{px(y)}catch(t){o=null!=o?o:[],t instanceof fx?o=cx(cx([],sx(o)),sx(t.errors)):o.push(t)}}}catch(t){e={error:t}}finally{try{f&&!f.done&&(r=l.return)&&r.call(l)}finally{if(e)throw e.error}}}if(o)throw new fx(o)}},t.prototype.add=function(n){var e;if(n&&n!==this)if(this.closed)px(n);else{if(n instanceof t){if(n.closed||n._hasParent(this))return;n._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(n)}},t.prototype._hasParent=function(t){var n=this._parentage;return n===t||Array.isArray(n)&&n.includes(t)},t.prototype._addParent=function(t){var n=this._parentage;this._parentage=Array.isArray(n)?(n.push(t),n):n?[n,t]:t},t.prototype._removeParent=function(t){var n=this._parentage;n===t?this._parentage=null:Array.isArray(n)&&yx(n,t)},t.prototype.remove=function(n){var e=this._finalizers;e&&yx(e,n),n instanceof t&&n._removeParent(this)},t.EMPTY=((n=new t).closed=!0,n),t}(),vx=dx.EMPTY;function hx(t){return t instanceof dx||t&&"closed"in t&&ux(t.remove)&&ux(t.add)&&ux(t.unsubscribe)}function px(t){ux(t)?t():t.unsubscribe()}var mx={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},bx=function(t,n){for(var e=[],r=2;r<arguments.length;r++)e[r-2]=arguments[r];return setTimeout.apply(void 0,cx([t,n],sx(e)))};function gx(){}function wx(t){t()}var Ax=function(t){function n(n){var e=t.call(this)||this;return e.isStopped=!1,n?(e.destination=n,hx(n)&&n.add(e)):e.destination=Ox,e}return ix(n,t),n.create=function(t,n,e){return new Tx(t,n,e)},n.prototype.next=function(t){this.isStopped||this._next(t)},n.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},n.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},n.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,t.prototype.unsubscribe.call(this),this.destination=null)},n.prototype._next=function(t){this.destination.next(t)},n.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},n.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},n}(dx),Ix=Function.prototype.bind;function Sx(t,n){return Ix.call(t,n)}var xx=function(){function t(t){this.partialObserver=t}return t.prototype.next=function(t){var n=this.partialObserver;if(n.next)try{n.next(t)}catch(t){_x(t)}},t.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(t){_x(t)}else _x(t)},t.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(t){_x(t)}},t}(),Tx=function(t){function n(n,e,r){var o,i,a=t.call(this)||this;ux(n)||!n?o={next:null!=n?n:void 0,error:null!=e?e:void 0,complete:null!=r?r:void 0}:a&&mx.useDeprecatedNextContext?((i=Object.create(n)).unsubscribe=function(){return a.unsubscribe()},o={next:n.next&&Sx(n.next,i),error:n.error&&Sx(n.error,i),complete:n.complete&&Sx(n.complete,i)}):o=n;return a.destination=new xx(o),a}return ix(n,t),n}(Ax);function _x(t){var n;n=t,bx((function(){throw n}))}var Ox={closed:!0,next:gx,error:function(t){throw t},complete:gx},Ex="function"==typeof Symbol&&Symbol.observable||"@@observable";function jx(t){return t}function Nx(t){return 0===t.length?jx:1===t.length?t[0]:function(n){return t.reduce((function(t,n){return n(t)}),n)}}var kx=function(){function t(t){t&&(this._subscribe=t)}return t.prototype.lift=function(n){var e=new t;return e.source=this,e.operator=n,e},t.prototype.subscribe=function(t,n,e){var r,o=this,i=(r=t)&&r instanceof Ax||function(t){return t&&ux(t.next)&&ux(t.error)&&ux(t.complete)}(r)&&hx(r)?t:new Tx(t,n,e);return wx((function(){var t=o,n=t.operator,e=t.source;i.add(n?n.call(i,e):e?o._subscribe(i):o._trySubscribe(i))})),i},t.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(n){t.error(n)}},t.prototype.forEach=function(t,n){var e=this;return new(n=Bx(n))((function(n,r){var o=new Tx({next:function(n){try{t(n)}catch(t){r(t),o.unsubscribe()}},error:r,complete:n});e.subscribe(o)}))},t.prototype._subscribe=function(t){var n;return null===(n=this.source)||void 0===n?void 0:n.subscribe(t)},t.prototype[Ex]=function(){return this},t.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return Nx(t)(this)},t.prototype.toPromise=function(t){var n=this;return new(t=Bx(t))((function(t,e){var r;n.subscribe((function(t){return r=t}),(function(t){return e(t)}),(function(){return t(r)}))}))},t.create=function(n){return new t(n)},t}();function Bx(t){var n;return null!==(n=null!=t?t:mx.Promise)&&void 0!==n?n:Promise}function Px(t){return ux(null==t?void 0:t.lift)}function qx(t,n,e,r,o){return new Cx(t,n,e,r,o)}var Cx=function(t){function n(n,e,r,o,i,a){var s=t.call(this,n)||this;return s.onFinalize=i,s.shouldUnsubscribe=a,s._next=e?function(t){try{e(t)}catch(t){n.error(t)}}:t.prototype._next,s._error=o?function(t){try{o(t)}catch(t){n.error(t)}finally{this.unsubscribe()}}:t.prototype._error,s._complete=r?function(){try{r()}catch(t){n.error(t)}finally{this.unsubscribe()}}:t.prototype._complete,s}return ix(n,t),n.prototype.unsubscribe=function(){var n;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var e=this.closed;t.prototype.unsubscribe.call(this),!e&&(null===(n=this.onFinalize)||void 0===n||n.call(this))}},n}(Ax);function Rx(){return t=function(t,n){var e=null;t._refCount++;var r=qx(n,void 0,void 0,void 0,(function(){if(!t||t._refCount<=0||0<--t._refCount)e=null;else{var r=t._connection,o=e;e=null,!r||o&&r!==o||r.unsubscribe(),n.unsubscribe()}}));t.subscribe(r),r.closed||(e=t.connect())},function(n){if(Px(n))return n.lift((function(n){try{return t(n,this)}catch(t){this.error(t)}}));throw new TypeError("Unable to lift unknown Observable type")};var t}!function(t){function n(n,e){var r=t.call(this)||this;return r.source=n,r.subjectFactory=e,r._subject=null,r._refCount=0,r._connection=null,Px(n)&&(r.lift=n.lift),r}ix(n,t),n.prototype._subscribe=function(t){return this.getSubject().subscribe(t)},n.prototype.getSubject=function(){var t=this._subject;return t&&!t.isStopped||(this._subject=this.subjectFactory()),this._subject},n.prototype._teardown=function(){this._refCount=0;var t=this._connection;this._subject=this._connection=null,null==t||t.unsubscribe()},n.prototype.connect=function(){var t=this,n=this._connection;if(!n){n=this._connection=new dx;var e=this.getSubject();n.add(this.source.subscribe(qx(e,void 0,(function(){t._teardown(),e.complete()}),(function(n){t._teardown(),e.error(n)}),(function(){return t._teardown()})))),n.closed&&(this._connection=null,n=dx.EMPTY)}return n},n.prototype.refCount=function(){return Rx()(this)}}(kx);var Ux,zx,Dx={now:function(){return(Dx.delegate||performance).now()},delegate:void 0},Mx={schedule:function(t){var n=requestAnimationFrame,e=cancelAnimationFrame,r=n((function(n){e=void 0,t(n)}));return new dx((function(){return null==e?void 0:e(r)}))},requestAnimationFrame:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var e=Mx.delegate;return((null==e?void 0:e.requestAnimationFrame)||requestAnimationFrame).apply(void 0,cx([],sx(t)))},cancelAnimationFrame:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return cancelAnimationFrame.apply(void 0,cx([],sx(t)))},delegate:void 0};zx=Mx.schedule,new kx((function(t){var n=new dx,e=Ux||Dx,r=e.now(),o=function(i){var a=e.now();t.next({timestamp:Ux?a:i,elapsed:a-r}),t.closed||n.add(zx(o))};return n.add(zx(o)),n}));var Fx=lx((function(t){return function(){t(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}})),Jx=function(t){function n(){var n=t.call(this)||this;return n.closed=!1,n.currentObservers=null,n.observers=[],n.isStopped=!1,n.hasError=!1,n.thrownError=null,n}return ix(n,t),n.prototype.lift=function(t){var n=new Vx(this,this);return n.operator=t,n},n.prototype._throwIfClosed=function(){if(this.closed)throw new Fx},n.prototype.next=function(t){var n=this;wx((function(){var e,r;if(n._throwIfClosed(),!n.isStopped){n.currentObservers||(n.currentObservers=Array.from(n.observers));try{for(var o=ax(n.currentObservers),i=o.next();!i.done;i=o.next()){i.value.next(t)}}catch(t){e={error:t}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(e)throw e.error}}}}))},n.prototype.error=function(t){var n=this;wx((function(){if(n._throwIfClosed(),!n.isStopped){n.hasError=n.isStopped=!0,n.thrownError=t;for(var e=n.observers;e.length;)e.shift().error(t)}}))},n.prototype.complete=function(){var t=this;wx((function(){if(t._throwIfClosed(),!t.isStopped){t.isStopped=!0;for(var n=t.observers;n.length;)n.shift().complete()}}))},n.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(n.prototype,"observed",{get:function(){var t;return(null===(t=this.observers)||void 0===t?void 0:t.length)>0},enumerable:!1,configurable:!0}),n.prototype._trySubscribe=function(n){return this._throwIfClosed(),t.prototype._trySubscribe.call(this,n)},n.prototype._subscribe=function(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)},n.prototype._innerSubscribe=function(t){var n=this,e=this,r=e.hasError,o=e.isStopped,i=e.observers;return r||o?vx:(this.currentObservers=null,i.push(t),new dx((function(){n.currentObservers=null,yx(i,t)})))},n.prototype._checkFinalizedStatuses=function(t){var n=this,e=n.hasError,r=n.thrownError,o=n.isStopped;e?t.error(r):o&&t.complete()},n.prototype.asObservable=function(){var t=new kx;return t.source=this,t},n.create=function(t,n){return new Vx(t,n)},n}(kx),Vx=function(t){function n(n,e){var r=t.call(this)||this;return r.destination=n,r.source=e,r}return ix(n,t),n.prototype.next=function(t){var n,e;null===(e=null===(n=this.destination)||void 0===n?void 0:n.next)||void 0===e||e.call(n,t)},n.prototype.error=function(t){var n,e;null===(e=null===(n=this.destination)||void 0===n?void 0:n.error)||void 0===e||e.call(n,t)},n.prototype.complete=function(){var t,n;null===(n=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===n||n.call(t)},n.prototype._subscribe=function(t){var n,e;return null!==(e=null===(n=this.source)||void 0===n?void 0:n.subscribe(t))&&void 0!==e?e:vx},n}(Jx);!function(t){function n(n){var e=t.call(this)||this;return e._value=n,e}ix(n,t),Object.defineProperty(n.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),n.prototype._subscribe=function(n){var e=t.prototype._subscribe.call(this,n);return!e.closed&&n.next(this._value),e},n.prototype.getValue=function(){var t=this,n=t.hasError,e=t.thrownError,r=t._value;if(n)throw e;return this._throwIfClosed(),r},n.prototype.next=function(n){t.prototype.next.call(this,this._value=n)}}(Jx);var Lx={now:function(){return(Lx.delegate||Date).now()},delegate:void 0};!function(t){function n(n,e,r){void 0===n&&(n=1/0),void 0===e&&(e=1/0),void 0===r&&(r=Lx);var o=t.call(this)||this;return o._bufferSize=n,o._windowTime=e,o._timestampProvider=r,o._buffer=[],o._infiniteTimeWindow=!0,o._infiniteTimeWindow=e===1/0,o._bufferSize=Math.max(1,n),o._windowTime=Math.max(1,e),o}ix(n,t),n.prototype.next=function(n){var e=this,r=e.isStopped,o=e._buffer,i=e._infiniteTimeWindow,a=e._timestampProvider,s=e._windowTime;r||(o.push(n),!i&&o.push(a.now()+s)),this._trimBuffer(),t.prototype.next.call(this,n)},n.prototype._subscribe=function(t){this._throwIfClosed(),this._trimBuffer();for(var n=this._innerSubscribe(t),e=this._infiniteTimeWindow,r=this._buffer.slice(),o=0;o<r.length&&!t.closed;o+=e?1:2)t.next(r[o]);return this._checkFinalizedStatuses(t),n},n.prototype._trimBuffer=function(){var t=this,n=t._bufferSize,e=t._timestampProvider,r=t._buffer,o=t._infiniteTimeWindow,i=(o?1:2)*n;if(n<1/0&&i<r.length&&r.splice(0,r.length-i),!o){for(var a=e.now(),s=0,c=1;c<r.length&&r[c]<=a;c+=2)s=c;s&&r.splice(0,s+1)}}}(Jx),function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n._value=null,n._hasValue=!1,n._isComplete=!1,n}ix(n,t),n.prototype._checkFinalizedStatuses=function(t){var n=this,e=n.hasError,r=n._hasValue,o=n._value,i=n.thrownError,a=n.isStopped,s=n._isComplete;e?t.error(i):(a||s)&&(r&&t.next(o),t.complete())},n.prototype.next=function(t){this.isStopped||(this._value=t,this._hasValue=!0)},n.prototype.complete=function(){var n=this,e=n._hasValue,r=n._value;n._isComplete||(this._isComplete=!0,e&&t.prototype.next.call(this,r),t.prototype.complete.call(this))}}(Jx);var Kx,Wx=function(t){function n(n,e){return t.call(this)||this}return ix(n,t),n.prototype.schedule=function(t,n){return this},n}(dx),Yx=function(t,n){for(var e=[],r=2;r<arguments.length;r++)e[r-2]=arguments[r];return setInterval.apply(void 0,cx([t,n],sx(e)))},$x=function(t){return clearInterval(t)},Hx=function(t){function n(n,e){var r=t.call(this,n,e)||this;return r.scheduler=n,r.work=e,r.pending=!1,r}return ix(n,t),n.prototype.schedule=function(t,n){if(void 0===n&&(n=0),this.closed)return this;this.state=t;var e=this.id,r=this.scheduler;return null!=e&&(this.id=this.recycleAsyncId(r,e,n)),this.pending=!0,this.delay=n,this.id=this.id||this.requestAsyncId(r,this.id,n),this},n.prototype.requestAsyncId=function(t,n,e){return void 0===e&&(e=0),Yx(t.flush.bind(t,this),e)},n.prototype.recycleAsyncId=function(t,n,e){if(void 0===e&&(e=0),null!=e&&this.delay===e&&!1===this.pending)return n;$x(n)},n.prototype.execute=function(t,n){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;var e=this._execute(t,n);if(e)return e;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},n.prototype._execute=function(t,n){var e,r=!1;try{this.work(t)}catch(t){r=!0,e=t||new Error("Scheduled action threw falsy error")}if(r)return this.unsubscribe(),e},n.prototype.unsubscribe=function(){if(!this.closed){var n=this.id,e=this.scheduler,r=e.actions;this.work=this.state=this.scheduler=null,this.pending=!1,yx(r,this),null!=n&&(this.id=this.recycleAsyncId(e,n,null)),this.delay=null,t.prototype.unsubscribe.call(this)}},n}(Wx),Xx=1,Gx={};function Qx(t){return t in Gx&&(delete Gx[t],!0)}var Zx=function(t){var n=Xx++;return Gx[n]=!0,Kx||(Kx=Promise.resolve()),Kx.then((function(){return Qx(n)&&t()})),n},tT=function(t){Qx(t)},nT={setImmediate:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var e=nT.delegate;return((null==e?void 0:e.setImmediate)||Zx).apply(void 0,cx([],sx(t)))},clearImmediate:function(t){return tT(t)},delegate:void 0},eT=function(t){function n(n,e){var r=t.call(this,n,e)||this;return r.scheduler=n,r.work=e,r}return ix(n,t),n.prototype.requestAsyncId=function(n,e,r){return void 0===r&&(r=0),null!==r&&r>0?t.prototype.requestAsyncId.call(this,n,e,r):(n.actions.push(this),n._scheduled||(n._scheduled=nT.setImmediate(n.flush.bind(n,void 0))))},n.prototype.recycleAsyncId=function(n,e,r){if(void 0===r&&(r=0),null!=r&&r>0||null==r&&this.delay>0)return t.prototype.recycleAsyncId.call(this,n,e,r);n.actions.some((function(t){return t.id===e}))||(nT.clearImmediate(e),n._scheduled=void 0)},n}(Hx),rT=function(){function t(n,e){void 0===e&&(e=t.now),this.schedulerActionCtor=n,this.now=e}return t.prototype.schedule=function(t,n,e){return void 0===n&&(n=0),new this.schedulerActionCtor(this,t).schedule(e,n)},t.now=Lx.now,t}(),oT=function(t){function n(n,e){void 0===e&&(e=rT.now);var r=t.call(this,n,e)||this;return r.actions=[],r._active=!1,r._scheduled=void 0,r}return ix(n,t),n.prototype.flush=function(t){var n=this.actions;if(this._active)n.push(t);else{var e;this._active=!0;do{if(e=t.execute(t.state,t.delay))break}while(t=n.shift());if(this._active=!1,e){for(;t=n.shift();)t.unsubscribe();throw e}}},n}(rT);new(function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return ix(n,t),n.prototype.flush=function(t){this._active=!0;var n=this._scheduled;this._scheduled=void 0;var e,r=this.actions;t=t||r.shift();do{if(e=t.execute(t.state,t.delay))break}while((t=r[0])&&t.id===n&&r.shift());if(this._active=!1,e){for(;(t=r[0])&&t.id===n&&r.shift();)t.unsubscribe();throw e}},n}(oT))(eT),new oT(Hx);var iT=function(t){function n(n,e){var r=t.call(this,n,e)||this;return r.scheduler=n,r.work=e,r}return ix(n,t),n.prototype.schedule=function(n,e){return void 0===e&&(e=0),e>0?t.prototype.schedule.call(this,n,e):(this.delay=e,this.state=n,this.scheduler.flush(this),this)},n.prototype.execute=function(n,e){return e>0||this.closed?t.prototype.execute.call(this,n,e):this._execute(n,e)},n.prototype.requestAsyncId=function(n,e,r){return void 0===r&&(r=0),null!=r&&r>0||null==r&&this.delay>0?t.prototype.requestAsyncId.call(this,n,e,r):n.flush(this)},n}(Hx);new(function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return ix(n,t),n}(oT))(iT);var aT=function(t){function n(n,e){var r=t.call(this,n,e)||this;return r.scheduler=n,r.work=e,r}return ix(n,t),n.prototype.requestAsyncId=function(n,e,r){return void 0===r&&(r=0),null!==r&&r>0?t.prototype.requestAsyncId.call(this,n,e,r):(n.actions.push(this),n._scheduled||(n._scheduled=Mx.requestAnimationFrame((function(){return n.flush(void 0)}))))},n.prototype.recycleAsyncId=function(n,e,r){if(void 0===r&&(r=0),null!=r&&r>0||null==r&&this.delay>0)return t.prototype.recycleAsyncId.call(this,n,e,r);n.actions.some((function(t){return t.id===e}))||(Mx.cancelAnimationFrame(e),n._scheduled=void 0)},n}(Hx);new(function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return ix(n,t),n.prototype.flush=function(t){this._active=!0;var n=this._scheduled;this._scheduled=void 0;var e,r=this.actions;t=t||r.shift();do{if(e=t.execute(t.state,t.delay))break}while((t=r[0])&&t.id===n&&r.shift());if(this._active=!1,e){for(;(t=r[0])&&t.id===n&&r.shift();)t.unsubscribe();throw e}},n}(oT))(aT),function(t){function n(n,e){void 0===n&&(n=cT),void 0===e&&(e=1/0);var r=t.call(this,n,(function(){return r.frame}))||this;return r.maxFrames=e,r.frame=0,r.index=-1,r}ix(n,t),n.prototype.flush=function(){for(var t,n,e=this.actions,r=this.maxFrames;(n=e[0])&&n.delay<=r&&(e.shift(),this.frame=n.delay,!(t=n.execute(n.state,n.delay))););if(t){for(;n=e.shift();)n.unsubscribe();throw t}},n.frameTimeFactor=10}(oT);var sT,cT=function(t){function n(n,e,r){void 0===r&&(r=n.index+=1);var o=t.call(this,n,e)||this;return o.scheduler=n,o.work=e,o.index=r,o.active=!0,o.index=n.index=r,o}return ix(n,t),n.prototype.schedule=function(e,r){if(void 0===r&&(r=0),Number.isFinite(r)){if(!this.id)return t.prototype.schedule.call(this,e,r);this.active=!1;var o=new n(this.scheduler,this.work);return this.add(o),o.schedule(e,r)}return dx.EMPTY},n.prototype.requestAsyncId=function(t,e,r){void 0===r&&(r=0),this.delay=t.frame+r;var o=t.actions;return o.push(this),o.sort(n.sortActions),!0},n.prototype.recycleAsyncId=function(t,n,e){},n.prototype._execute=function(n,e){if(!0===this.active)return t.prototype._execute.call(this,n,e)},n.sortActions=function(t,n){return t.delay===n.delay?t.index===n.index?0:t.index>n.index?1:-1:t.delay>n.delay?1:-1},n}(Hx);new kx((function(t){return t.complete()})),function(t){t.NEXT="N",t.ERROR="E",t.COMPLETE="C"}(sT||(sT={})),lx((function(t){return function(){t(this),this.name="EmptyError",this.message="no elements in sequence"}})),lx((function(t){return function(){t(this),this.name="ArgumentOutOfRangeError",this.message="argument out of range"}})),lx((function(t){return function(n){t(this),this.name="NotFoundError",this.message=n}})),lx((function(t){return function(n){t(this),this.name="SequenceError",this.message=n}})),lx((function(t){return function(n){void 0===n&&(n=null),t(this),this.message="Timeout has occurred",this.name="TimeoutError",this.info=n}})),new kx(gx);class uT extends ex{constructor(){super(...arguments),this.stateChanges=new Jx}get[Symbol.toStringTag](){return this.constructor.name}observeStateChanges(){return this.stateChanges}send(t){const n=this.state;super.send(t);const r=this.state;this.stateChanges.next({event:t,oldState:n,newState:r}),e.isEmptyObject(this.schema[r])&&this.stateChanges.complete()}}class lT{constructor(t=[]){this.indexToValue=[];const n=[];if(t.length>0)for(const[e,r]of t.entries())n[r]=e;this.valueToIndex=n}get[Symbol.toStringTag](){return this.constructor.name}[Symbol.iterator](){return this.indexToValue[Symbol.iterator]()}values(){return this.indexToValue[Symbol.iterator]()}has(t){return t in this.valueToIndex}add(t){if(!this.has(t)){const n=this.indexToValue.length;this.indexToValue.push(t),this.valueToIndex[t]=n}}delete(t){if(this.has(t)){const n=this.indexToValue.pop();if(t===n)delete this.valueToIndex[t];else{const e=this.valueToIndex[t];this.indexToValue[e]=n,this.valueToIndex[n]=e,delete this.valueToIndex[t]}}}}class fT{constructor(){this.keyToIndex=[],this.indexToKey=[],this.indexToValue=[]}get[Symbol.toStringTag](){return this.constructor.name}*entries(){for(let t=0;t<this.indexToKey.length;t++)yield[this.indexToKey[t],this.indexToValue[t]]}keys(){return this.indexToKey.values()}values(){return this.indexToValue.values()}has(t){return t in this.keyToIndex}get(t){if(this.has(t)){const n=this.keyToIndex[t];return this.indexToValue[n]}}set(t,n){if(this.has(t)){const e=this.keyToIndex[t];this.indexToValue[e]=n}else{const e=this.indexToKey.length;this.indexToKey.push(t),this.indexToValue.push(n),this.keyToIndex[t]=e}}delete(t){if(this.has(t)){const n=this.indexToKey.pop(),e=this.indexToValue.pop();if(t===n)delete this.keyToIndex[t];else{const r=this.keyToIndex[t];this.indexToKey[r]=n,this.indexToValue[r]=e,this.keyToIndex[t]=r,delete this.keyToIndex[t]}}}}class yT{constructor(t){this.keyToIndex=[],this.indexToKey=[],Mt.assert(0===t.length,"array should be empty"),this.indexToValue=t}get[Symbol.toStringTag](){return this.constructor.name}*entries(){for(let t=0;t<this.indexToKey.length;t++)yield[this.indexToKey[t],this.indexToValue.internalTypedArray[t]]}keys(){return this.indexToKey.values()}*values(){for(let t=0;t<this.indexToKey.length;t++)yield this.indexToValue.internalTypedArray[t]}has(t){const n=this.keyToIndex[t];return this.indexToKey[n]===t}get(t){const n=this.keyToIndex[t];return this.indexToKey[n]===t?this.indexToValue.internalTypedArray[n]:void 0}set(t,n){const e=this.keyToIndex[t];if(this.indexToKey[e]===t)this.indexToValue.internalTypedArray[e]=n;else{const e=this.indexToKey.length;this.indexToKey.push(t),this.indexToValue.push(n),this.keyToIndex[t]=e}}delete(t){const n=this.keyToIndex[t];if(this.indexToKey[n]===t){const e=this.indexToKey.pop(),r=this.indexToValue.pop();t!==e&&(this.indexToKey[n]=e,this.indexToValue.internalTypedArray[n]=r,this.keyToIndex[e]=n)}}}class dT{constructor(t){const n=[];if(t.length>0)for(const[e,r]of t.internalTypedArray.entries())n[r]=e;this.indexToValue=t,this.valueToIndex=n}get[Symbol.toStringTag](){return this.constructor.name}[Symbol.iterator](){return this.values()}*values(){for(let t=0;t<this.indexToValue.length;t++)yield this.indexToValue.internalTypedArray[t]}has(t){const n=this.valueToIndex[t];return this.indexToValue.internalTypedArray[n]===t}add(t){if(!this.has(t)){const n=this.indexToValue.length;this.indexToValue.push(t),this.valueToIndex[t]=n}}delete(t){const n=this.valueToIndex[t];if(this.indexToValue.internalTypedArray[n]===t){const e=this.indexToValue.pop();t!==e&&(this.indexToValue.internalTypedArray[n]=e,this.valueToIndex[e]=n)}}}class vT{constructor(t,{capacity:n=0,growthFactor:e=1.5}={}){this.typedArrayConstructor=t,this._length=0,Mt.assert(Number.isInteger(n),"capacity must be an integer"),Mt.assert(n>=0,"capacity must be greater than or equal to 0"),Mt.assert(e>=1,"growthFactory must be greater than or equal to 1"),this.array=new t(n),this.growthFactor=e}get internalTypedArray(){return this.array}get[Symbol.toStringTag](){return this.constructor.name}get capacity(){return this.array.length}get length(){return this._length}set(t,n){if(t>=this.capacity){const n=hT(this.capacity,t+1,this.growthFactor);this.resize(n)}t>=this._length&&(this._length=t+1),this.array[t]=n}get(t){return t<this._length?this.array[t]:void 0}push(...t){const n=this._length+t.length;if(n>this.capacity){const t=hT(this.capacity,n,this.growthFactor);this.resize(t)}for(const n of t)this.array[this._length++]=n}pop(){if(this._length>0){const t=this.array[this._length-1];this._length--;const n=hT(this.capacity,this.length,this.growthFactor);return this.resize(n),t}}resize(t){if(this.array.length!==t)if(this.array.length<t){const n=new this.typedArrayConstructor(t);n.set(this.array),this.array=n}else if(this.array.length>t){const n=new this.typedArrayConstructor(t);for(let e=t;e--;)n[e]=this.array[e];this.array=n}}}function hT(t,n,e){if(1===e)return n;if(t===n)return n;if(t<n){let r=Math.max(t,1);for(;r<n;)r*=e;return Math.floor(r)}if(0===n)return 0;{let r=t;for(;;){const t=r/e;if(t<n)break;r=t}return Math.floor(r)}}class pT{constructor(t){this.value=t,this.previous=null,this.next=null,this.up=null,this.down=null}}class mT{constructor(t){this.compare=t,this.head=new pT(null),this.tail=new pT(null),this.height=0,this._size=0,this.head.next=this.tail,this.tail.previous=this.head}get size(){return this._size}*elements(){let t=this.head;for(;t.down;)t=t.down;for(;t.next&&e.isntNull(t.next.value);)t=t.next,yield t}dumpList(){const t=[];let n=this.head;do{t.push([]);let e=n;do{t[t.length-1].push(e.value),e=e.next}while(e)}while(n=n.down);return t}delete(t){let n=this.findNode(t);for(;n;)n.previous.next=n.next,n.next.previous=n.previous,n=n.down;this._size--}has(t){return e.isntNull(this.findNode(t))}findNode(t){let n=this.head;for(;;){for(;n.next&&e.isntNull(n.next.value);){const e=this.compare(n.next.value,t);if(0===e)return n.next;if(!(e<0))break;n=n.next}if(!n.down)return null;n=n.down}}add(t){let n=this.findPreviousNode(t);if(n.next&&e.isntNull(n.next.value)&&0===this.compare(n.next.value,t))return;let r=new pT(t);n.next&&(r.next=n.next,n.next.previous=r),n.next=r,r.previous=n;let o=0;for(;Math.random()<.5;){if(o===this.height){const t=new pT(null),n=new pT(null);t.next=n,t.down=this.head,n.previous=t,n.down=this.tail,this.head.up=t,this.tail.up=n,this.head=t,this.tail=n,this.height++}for(;!n.up;)n=n.previous;n=n.up;const e=new pT(t);n.next&&(e.next=n.next,n.next.previous=e),n.next=e,e.previous=n,e.down=r,r.up=e,r=e,o++}this._size++}findPreviousNode(t){let n=this.head;for(;;){for(;n.next&&e.isntNull(n.next.value);){if(this.compare(n.next.value,t)>=0)break;n=n.next}if(!n.down)return n;n=n.down}}}class bT{constructor(t){this.skipList=new mT(t)}get[Symbol.toStringTag](){return this.constructor.name}[Symbol.iterator](){return this.values()}values(){return pc.map(this.skipList.elements(),(t=>t.value))}has(t){return this.skipList.has(t)}add(t){this.skipList.add(t)}delete(t){this.skipList.delete(t)}}class gT{constructor(){this.length=0,this.array=new vT(Uint8Array)}get[Symbol.toStringTag](){return this.constructor.name}get size(){return this.length}has(t){var n;const{index:e,mask:r}=this.getPosition(t);return((null!==(n=this.array.get(e))&&void 0!==n?n:0)&r)===r}add(t){var n;Mt.assert(t>=0,"value must be greater than or equal to 0"),t>=this.length&&(this.length=t+1);const{index:e,mask:r}=this.getPosition(t);this.array.set(e,(null!==(n=this.array.get(e))&&void 0!==n?n:0)|r)}delete(t){var n;const{index:e,mask:r}=this.getPosition(t);this.array.set(e,(null!==(n=this.array.get(e))&&void 0!==n?n:0)&~r)}clear(){for(let t=this.array.length;t--;)this.array.set(t,0)}getPosition(t){const n=8*Uint8Array.BYTES_PER_ELEMENT,e=(t-t%n)/n;return{index:Math.max(0,e-1),mask:this.getMask(t)}}getMask(t){return 2**t}}export{rx as BadEventError,gT as BitSet,t as Box,vT as DynamicTypedArray,Rt as Emitter,QS as ExpirableMap,ex as FiniteStateMachine,Ut as HashMap,zt as HashSet,GS as LRUMap,uT as ObservableFiniteStateMachine,Dt as Queue,bT as SortedSet,fT as SparseMap,lT as SparseSet,ZS as TLRUMap,nx as TrieMap,yT as TypedSparseMap,dT as TypedSparseSet,Ct as convertArrayToCons,qt as convertConsToArray};
15
+ ***************************************************************************** */var ox=function(t,n){return(ox=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var e in n)Object.prototype.hasOwnProperty.call(n,e)&&(t[e]=n[e])})(t,n)};function ix(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function e(){this.constructor=t}ox(t,n),t.prototype=null===n?Object.create(n):(e.prototype=n.prototype,new e)}function ax(t){var n="function"==typeof Symbol&&Symbol.iterator,e=n&&t[n],r=0;if(e)return e.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function sx(t,n){var e="function"==typeof Symbol&&t[Symbol.iterator];if(!e)return t;var r,o,i=e.call(t),a=[];try{for(;(void 0===n||n-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(t){o={error:t}}finally{try{r&&!r.done&&(e=i.return)&&e.call(i)}finally{if(o)throw o.error}}return a}function cx(t,n,e){if(e||2===arguments.length)for(var r,o=0,i=n.length;o<i;o++)!r&&o in n||(r||(r=Array.prototype.slice.call(n,0,o)),r[o]=n[o]);return t.concat(r||Array.prototype.slice.call(n))}function ux(t){return"function"==typeof t}function lx(t){var n=t((function(t){Error.call(t),t.stack=(new Error).stack}));return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}var fx=lx((function(t){return function(n){t(this),this.message=n?n.length+" errors occurred during unsubscription:\n"+n.map((function(t,n){return n+1+") "+t.toString()})).join("\n "):"",this.name="UnsubscriptionError",this.errors=n}}));function yx(t,n){if(t){var e=t.indexOf(n);0<=e&&t.splice(e,1)}}var dx=function(){function t(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}var n;return t.prototype.unsubscribe=function(){var t,n,e,r,o;if(!this.closed){this.closed=!0;var i=this._parentage;if(i)if(this._parentage=null,Array.isArray(i))try{for(var a=ax(i),s=a.next();!s.done;s=a.next()){s.value.remove(this)}}catch(n){t={error:n}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}else i.remove(this);var c=this.initialTeardown;if(ux(c))try{c()}catch(t){o=t instanceof fx?t.errors:[t]}var u=this._finalizers;if(u){this._finalizers=null;try{for(var l=ax(u),f=l.next();!f.done;f=l.next()){var y=f.value;try{px(y)}catch(t){o=null!=o?o:[],t instanceof fx?o=cx(cx([],sx(o)),sx(t.errors)):o.push(t)}}}catch(t){e={error:t}}finally{try{f&&!f.done&&(r=l.return)&&r.call(l)}finally{if(e)throw e.error}}}if(o)throw new fx(o)}},t.prototype.add=function(n){var e;if(n&&n!==this)if(this.closed)px(n);else{if(n instanceof t){if(n.closed||n._hasParent(this))return;n._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(n)}},t.prototype._hasParent=function(t){var n=this._parentage;return n===t||Array.isArray(n)&&n.includes(t)},t.prototype._addParent=function(t){var n=this._parentage;this._parentage=Array.isArray(n)?(n.push(t),n):n?[n,t]:t},t.prototype._removeParent=function(t){var n=this._parentage;n===t?this._parentage=null:Array.isArray(n)&&yx(n,t)},t.prototype.remove=function(n){var e=this._finalizers;e&&yx(e,n),n instanceof t&&n._removeParent(this)},t.EMPTY=((n=new t).closed=!0,n),t}(),vx=dx.EMPTY;function hx(t){return t instanceof dx||t&&"closed"in t&&ux(t.remove)&&ux(t.add)&&ux(t.unsubscribe)}function px(t){ux(t)?t():t.unsubscribe()}var mx={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},bx=function(t,n){for(var e=[],r=2;r<arguments.length;r++)e[r-2]=arguments[r];return setTimeout.apply(void 0,cx([t,n],sx(e)))};function gx(){}function wx(t){t()}var Ax=function(t){function n(n){var e=t.call(this)||this;return e.isStopped=!1,n?(e.destination=n,hx(n)&&n.add(e)):e.destination=Ox,e}return ix(n,t),n.create=function(t,n,e){return new Tx(t,n,e)},n.prototype.next=function(t){this.isStopped||this._next(t)},n.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},n.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},n.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,t.prototype.unsubscribe.call(this),this.destination=null)},n.prototype._next=function(t){this.destination.next(t)},n.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},n.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},n}(dx),Ix=Function.prototype.bind;function Sx(t,n){return Ix.call(t,n)}var xx=function(){function t(t){this.partialObserver=t}return t.prototype.next=function(t){var n=this.partialObserver;if(n.next)try{n.next(t)}catch(t){_x(t)}},t.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(t){_x(t)}else _x(t)},t.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(t){_x(t)}},t}(),Tx=function(t){function n(n,e,r){var o,i,a=t.call(this)||this;ux(n)||!n?o={next:null!=n?n:void 0,error:null!=e?e:void 0,complete:null!=r?r:void 0}:a&&mx.useDeprecatedNextContext?((i=Object.create(n)).unsubscribe=function(){return a.unsubscribe()},o={next:n.next&&Sx(n.next,i),error:n.error&&Sx(n.error,i),complete:n.complete&&Sx(n.complete,i)}):o=n;return a.destination=new xx(o),a}return ix(n,t),n}(Ax);function _x(t){var n;n=t,bx((function(){throw n}))}var Ox={closed:!0,next:gx,error:function(t){throw t},complete:gx},Ex="function"==typeof Symbol&&Symbol.observable||"@@observable";function jx(t){return t}function Nx(t){return 0===t.length?jx:1===t.length?t[0]:function(n){return t.reduce((function(t,n){return n(t)}),n)}}var kx=function(){function t(t){t&&(this._subscribe=t)}return t.prototype.lift=function(n){var e=new t;return e.source=this,e.operator=n,e},t.prototype.subscribe=function(t,n,e){var r,o=this,i=(r=t)&&r instanceof Ax||function(t){return t&&ux(t.next)&&ux(t.error)&&ux(t.complete)}(r)&&hx(r)?t:new Tx(t,n,e);return wx((function(){var t=o,n=t.operator,e=t.source;i.add(n?n.call(i,e):e?o._subscribe(i):o._trySubscribe(i))})),i},t.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(n){t.error(n)}},t.prototype.forEach=function(t,n){var e=this;return new(n=Bx(n))((function(n,r){var o=new Tx({next:function(n){try{t(n)}catch(t){r(t),o.unsubscribe()}},error:r,complete:n});e.subscribe(o)}))},t.prototype._subscribe=function(t){var n;return null===(n=this.source)||void 0===n?void 0:n.subscribe(t)},t.prototype[Ex]=function(){return this},t.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return Nx(t)(this)},t.prototype.toPromise=function(t){var n=this;return new(t=Bx(t))((function(t,e){var r;n.subscribe((function(t){return r=t}),(function(t){return e(t)}),(function(){return t(r)}))}))},t.create=function(n){return new t(n)},t}();function Bx(t){var n;return null!==(n=null!=t?t:mx.Promise)&&void 0!==n?n:Promise}function Px(t){return ux(null==t?void 0:t.lift)}function qx(t,n,e,r,o){return new Cx(t,n,e,r,o)}var Cx=function(t){function n(n,e,r,o,i,a){var s=t.call(this,n)||this;return s.onFinalize=i,s.shouldUnsubscribe=a,s._next=e?function(t){try{e(t)}catch(t){n.error(t)}}:t.prototype._next,s._error=o?function(t){try{o(t)}catch(t){n.error(t)}finally{this.unsubscribe()}}:t.prototype._error,s._complete=r?function(){try{r()}catch(t){n.error(t)}finally{this.unsubscribe()}}:t.prototype._complete,s}return ix(n,t),n.prototype.unsubscribe=function(){var n;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var e=this.closed;t.prototype.unsubscribe.call(this),!e&&(null===(n=this.onFinalize)||void 0===n||n.call(this))}},n}(Ax);function Rx(){return t=function(t,n){var e=null;t._refCount++;var r=qx(n,void 0,void 0,void 0,(function(){if(!t||t._refCount<=0||0<--t._refCount)e=null;else{var r=t._connection,o=e;e=null,!r||o&&r!==o||r.unsubscribe(),n.unsubscribe()}}));t.subscribe(r),r.closed||(e=t.connect())},function(n){if(Px(n))return n.lift((function(n){try{return t(n,this)}catch(t){this.error(t)}}));throw new TypeError("Unable to lift unknown Observable type")};var t}!function(t){function n(n,e){var r=t.call(this)||this;return r.source=n,r.subjectFactory=e,r._subject=null,r._refCount=0,r._connection=null,Px(n)&&(r.lift=n.lift),r}ix(n,t),n.prototype._subscribe=function(t){return this.getSubject().subscribe(t)},n.prototype.getSubject=function(){var t=this._subject;return t&&!t.isStopped||(this._subject=this.subjectFactory()),this._subject},n.prototype._teardown=function(){this._refCount=0;var t=this._connection;this._subject=this._connection=null,null==t||t.unsubscribe()},n.prototype.connect=function(){var t=this,n=this._connection;if(!n){n=this._connection=new dx;var e=this.getSubject();n.add(this.source.subscribe(qx(e,void 0,(function(){t._teardown(),e.complete()}),(function(n){t._teardown(),e.error(n)}),(function(){return t._teardown()})))),n.closed&&(this._connection=null,n=dx.EMPTY)}return n},n.prototype.refCount=function(){return Rx()(this)}}(kx);var Ux,zx,Dx={now:function(){return(Dx.delegate||performance).now()},delegate:void 0},Mx={schedule:function(t){var n=requestAnimationFrame,e=cancelAnimationFrame,r=n((function(n){e=void 0,t(n)}));return new dx((function(){return null==e?void 0:e(r)}))},requestAnimationFrame:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var e=Mx.delegate;return((null==e?void 0:e.requestAnimationFrame)||requestAnimationFrame).apply(void 0,cx([],sx(t)))},cancelAnimationFrame:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return cancelAnimationFrame.apply(void 0,cx([],sx(t)))},delegate:void 0};zx=Mx.schedule,new kx((function(t){var n=new dx,e=Ux||Dx,r=e.now(),o=function(i){var a=e.now();t.next({timestamp:Ux?a:i,elapsed:a-r}),t.closed||n.add(zx(o))};return n.add(zx(o)),n}));var Fx=lx((function(t){return function(){t(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}})),Jx=function(t){function n(){var n=t.call(this)||this;return n.closed=!1,n.currentObservers=null,n.observers=[],n.isStopped=!1,n.hasError=!1,n.thrownError=null,n}return ix(n,t),n.prototype.lift=function(t){var n=new Vx(this,this);return n.operator=t,n},n.prototype._throwIfClosed=function(){if(this.closed)throw new Fx},n.prototype.next=function(t){var n=this;wx((function(){var e,r;if(n._throwIfClosed(),!n.isStopped){n.currentObservers||(n.currentObservers=Array.from(n.observers));try{for(var o=ax(n.currentObservers),i=o.next();!i.done;i=o.next()){i.value.next(t)}}catch(t){e={error:t}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(e)throw e.error}}}}))},n.prototype.error=function(t){var n=this;wx((function(){if(n._throwIfClosed(),!n.isStopped){n.hasError=n.isStopped=!0,n.thrownError=t;for(var e=n.observers;e.length;)e.shift().error(t)}}))},n.prototype.complete=function(){var t=this;wx((function(){if(t._throwIfClosed(),!t.isStopped){t.isStopped=!0;for(var n=t.observers;n.length;)n.shift().complete()}}))},n.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(n.prototype,"observed",{get:function(){var t;return(null===(t=this.observers)||void 0===t?void 0:t.length)>0},enumerable:!1,configurable:!0}),n.prototype._trySubscribe=function(n){return this._throwIfClosed(),t.prototype._trySubscribe.call(this,n)},n.prototype._subscribe=function(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)},n.prototype._innerSubscribe=function(t){var n=this,e=this,r=e.hasError,o=e.isStopped,i=e.observers;return r||o?vx:(this.currentObservers=null,i.push(t),new dx((function(){n.currentObservers=null,yx(i,t)})))},n.prototype._checkFinalizedStatuses=function(t){var n=this,e=n.hasError,r=n.thrownError,o=n.isStopped;e?t.error(r):o&&t.complete()},n.prototype.asObservable=function(){var t=new kx;return t.source=this,t},n.create=function(t,n){return new Vx(t,n)},n}(kx),Vx=function(t){function n(n,e){var r=t.call(this)||this;return r.destination=n,r.source=e,r}return ix(n,t),n.prototype.next=function(t){var n,e;null===(e=null===(n=this.destination)||void 0===n?void 0:n.next)||void 0===e||e.call(n,t)},n.prototype.error=function(t){var n,e;null===(e=null===(n=this.destination)||void 0===n?void 0:n.error)||void 0===e||e.call(n,t)},n.prototype.complete=function(){var t,n;null===(n=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===n||n.call(t)},n.prototype._subscribe=function(t){var n,e;return null!==(e=null===(n=this.source)||void 0===n?void 0:n.subscribe(t))&&void 0!==e?e:vx},n}(Jx);!function(t){function n(n){var e=t.call(this)||this;return e._value=n,e}ix(n,t),Object.defineProperty(n.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),n.prototype._subscribe=function(n){var e=t.prototype._subscribe.call(this,n);return!e.closed&&n.next(this._value),e},n.prototype.getValue=function(){var t=this,n=t.hasError,e=t.thrownError,r=t._value;if(n)throw e;return this._throwIfClosed(),r},n.prototype.next=function(n){t.prototype.next.call(this,this._value=n)}}(Jx);var Lx={now:function(){return(Lx.delegate||Date).now()},delegate:void 0};!function(t){function n(n,e,r){void 0===n&&(n=1/0),void 0===e&&(e=1/0),void 0===r&&(r=Lx);var o=t.call(this)||this;return o._bufferSize=n,o._windowTime=e,o._timestampProvider=r,o._buffer=[],o._infiniteTimeWindow=!0,o._infiniteTimeWindow=e===1/0,o._bufferSize=Math.max(1,n),o._windowTime=Math.max(1,e),o}ix(n,t),n.prototype.next=function(n){var e=this,r=e.isStopped,o=e._buffer,i=e._infiniteTimeWindow,a=e._timestampProvider,s=e._windowTime;r||(o.push(n),!i&&o.push(a.now()+s)),this._trimBuffer(),t.prototype.next.call(this,n)},n.prototype._subscribe=function(t){this._throwIfClosed(),this._trimBuffer();for(var n=this._innerSubscribe(t),e=this._infiniteTimeWindow,r=this._buffer.slice(),o=0;o<r.length&&!t.closed;o+=e?1:2)t.next(r[o]);return this._checkFinalizedStatuses(t),n},n.prototype._trimBuffer=function(){var t=this,n=t._bufferSize,e=t._timestampProvider,r=t._buffer,o=t._infiniteTimeWindow,i=(o?1:2)*n;if(n<1/0&&i<r.length&&r.splice(0,r.length-i),!o){for(var a=e.now(),s=0,c=1;c<r.length&&r[c]<=a;c+=2)s=c;s&&r.splice(0,s+1)}}}(Jx),function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n._value=null,n._hasValue=!1,n._isComplete=!1,n}ix(n,t),n.prototype._checkFinalizedStatuses=function(t){var n=this,e=n.hasError,r=n._hasValue,o=n._value,i=n.thrownError,a=n.isStopped,s=n._isComplete;e?t.error(i):(a||s)&&(r&&t.next(o),t.complete())},n.prototype.next=function(t){this.isStopped||(this._value=t,this._hasValue=!0)},n.prototype.complete=function(){var n=this,e=n._hasValue,r=n._value;n._isComplete||(this._isComplete=!0,e&&t.prototype.next.call(this,r),t.prototype.complete.call(this))}}(Jx);var Kx,Wx=function(t){function n(n,e){return t.call(this)||this}return ix(n,t),n.prototype.schedule=function(t,n){return this},n}(dx),Yx=function(t,n){for(var e=[],r=2;r<arguments.length;r++)e[r-2]=arguments[r];return setInterval.apply(void 0,cx([t,n],sx(e)))},$x=function(t){return clearInterval(t)},Hx=function(t){function n(n,e){var r=t.call(this,n,e)||this;return r.scheduler=n,r.work=e,r.pending=!1,r}return ix(n,t),n.prototype.schedule=function(t,n){if(void 0===n&&(n=0),this.closed)return this;this.state=t;var e=this.id,r=this.scheduler;return null!=e&&(this.id=this.recycleAsyncId(r,e,n)),this.pending=!0,this.delay=n,this.id=this.id||this.requestAsyncId(r,this.id,n),this},n.prototype.requestAsyncId=function(t,n,e){return void 0===e&&(e=0),Yx(t.flush.bind(t,this),e)},n.prototype.recycleAsyncId=function(t,n,e){if(void 0===e&&(e=0),null!=e&&this.delay===e&&!1===this.pending)return n;$x(n)},n.prototype.execute=function(t,n){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;var e=this._execute(t,n);if(e)return e;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},n.prototype._execute=function(t,n){var e,r=!1;try{this.work(t)}catch(t){r=!0,e=t||new Error("Scheduled action threw falsy error")}if(r)return this.unsubscribe(),e},n.prototype.unsubscribe=function(){if(!this.closed){var n=this.id,e=this.scheduler,r=e.actions;this.work=this.state=this.scheduler=null,this.pending=!1,yx(r,this),null!=n&&(this.id=this.recycleAsyncId(e,n,null)),this.delay=null,t.prototype.unsubscribe.call(this)}},n}(Wx),Xx=1,Gx={};function Qx(t){return t in Gx&&(delete Gx[t],!0)}var Zx=function(t){var n=Xx++;return Gx[n]=!0,Kx||(Kx=Promise.resolve()),Kx.then((function(){return Qx(n)&&t()})),n},tT=function(t){Qx(t)},nT={setImmediate:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var e=nT.delegate;return((null==e?void 0:e.setImmediate)||Zx).apply(void 0,cx([],sx(t)))},clearImmediate:function(t){return tT(t)},delegate:void 0},eT=function(t){function n(n,e){var r=t.call(this,n,e)||this;return r.scheduler=n,r.work=e,r}return ix(n,t),n.prototype.requestAsyncId=function(n,e,r){return void 0===r&&(r=0),null!==r&&r>0?t.prototype.requestAsyncId.call(this,n,e,r):(n.actions.push(this),n._scheduled||(n._scheduled=nT.setImmediate(n.flush.bind(n,void 0))))},n.prototype.recycleAsyncId=function(n,e,r){if(void 0===r&&(r=0),null!=r&&r>0||null==r&&this.delay>0)return t.prototype.recycleAsyncId.call(this,n,e,r);n.actions.some((function(t){return t.id===e}))||(nT.clearImmediate(e),n._scheduled=void 0)},n}(Hx),rT=function(){function t(n,e){void 0===e&&(e=t.now),this.schedulerActionCtor=n,this.now=e}return t.prototype.schedule=function(t,n,e){return void 0===n&&(n=0),new this.schedulerActionCtor(this,t).schedule(e,n)},t.now=Lx.now,t}(),oT=function(t){function n(n,e){void 0===e&&(e=rT.now);var r=t.call(this,n,e)||this;return r.actions=[],r._active=!1,r._scheduled=void 0,r}return ix(n,t),n.prototype.flush=function(t){var n=this.actions;if(this._active)n.push(t);else{var e;this._active=!0;do{if(e=t.execute(t.state,t.delay))break}while(t=n.shift());if(this._active=!1,e){for(;t=n.shift();)t.unsubscribe();throw e}}},n}(rT);new(function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return ix(n,t),n.prototype.flush=function(t){this._active=!0;var n=this._scheduled;this._scheduled=void 0;var e,r=this.actions;t=t||r.shift();do{if(e=t.execute(t.state,t.delay))break}while((t=r[0])&&t.id===n&&r.shift());if(this._active=!1,e){for(;(t=r[0])&&t.id===n&&r.shift();)t.unsubscribe();throw e}},n}(oT))(eT),new oT(Hx);var iT=function(t){function n(n,e){var r=t.call(this,n,e)||this;return r.scheduler=n,r.work=e,r}return ix(n,t),n.prototype.schedule=function(n,e){return void 0===e&&(e=0),e>0?t.prototype.schedule.call(this,n,e):(this.delay=e,this.state=n,this.scheduler.flush(this),this)},n.prototype.execute=function(n,e){return e>0||this.closed?t.prototype.execute.call(this,n,e):this._execute(n,e)},n.prototype.requestAsyncId=function(n,e,r){return void 0===r&&(r=0),null!=r&&r>0||null==r&&this.delay>0?t.prototype.requestAsyncId.call(this,n,e,r):n.flush(this)},n}(Hx);new(function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return ix(n,t),n}(oT))(iT);var aT=function(t){function n(n,e){var r=t.call(this,n,e)||this;return r.scheduler=n,r.work=e,r}return ix(n,t),n.prototype.requestAsyncId=function(n,e,r){return void 0===r&&(r=0),null!==r&&r>0?t.prototype.requestAsyncId.call(this,n,e,r):(n.actions.push(this),n._scheduled||(n._scheduled=Mx.requestAnimationFrame((function(){return n.flush(void 0)}))))},n.prototype.recycleAsyncId=function(n,e,r){if(void 0===r&&(r=0),null!=r&&r>0||null==r&&this.delay>0)return t.prototype.recycleAsyncId.call(this,n,e,r);n.actions.some((function(t){return t.id===e}))||(Mx.cancelAnimationFrame(e),n._scheduled=void 0)},n}(Hx);new(function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return ix(n,t),n.prototype.flush=function(t){this._active=!0;var n=this._scheduled;this._scheduled=void 0;var e,r=this.actions;t=t||r.shift();do{if(e=t.execute(t.state,t.delay))break}while((t=r[0])&&t.id===n&&r.shift());if(this._active=!1,e){for(;(t=r[0])&&t.id===n&&r.shift();)t.unsubscribe();throw e}},n}(oT))(aT),function(t){function n(n,e){void 0===n&&(n=cT),void 0===e&&(e=1/0);var r=t.call(this,n,(function(){return r.frame}))||this;return r.maxFrames=e,r.frame=0,r.index=-1,r}ix(n,t),n.prototype.flush=function(){for(var t,n,e=this.actions,r=this.maxFrames;(n=e[0])&&n.delay<=r&&(e.shift(),this.frame=n.delay,!(t=n.execute(n.state,n.delay))););if(t){for(;n=e.shift();)n.unsubscribe();throw t}},n.frameTimeFactor=10}(oT);var sT,cT=function(t){function n(n,e,r){void 0===r&&(r=n.index+=1);var o=t.call(this,n,e)||this;return o.scheduler=n,o.work=e,o.index=r,o.active=!0,o.index=n.index=r,o}return ix(n,t),n.prototype.schedule=function(e,r){if(void 0===r&&(r=0),Number.isFinite(r)){if(!this.id)return t.prototype.schedule.call(this,e,r);this.active=!1;var o=new n(this.scheduler,this.work);return this.add(o),o.schedule(e,r)}return dx.EMPTY},n.prototype.requestAsyncId=function(t,e,r){void 0===r&&(r=0),this.delay=t.frame+r;var o=t.actions;return o.push(this),o.sort(n.sortActions),!0},n.prototype.recycleAsyncId=function(t,n,e){},n.prototype._execute=function(n,e){if(!0===this.active)return t.prototype._execute.call(this,n,e)},n.sortActions=function(t,n){return t.delay===n.delay?t.index===n.index?0:t.index>n.index?1:-1:t.delay>n.delay?1:-1},n}(Hx);new kx((function(t){return t.complete()})),function(t){t.NEXT="N",t.ERROR="E",t.COMPLETE="C"}(sT||(sT={})),lx((function(t){return function(){t(this),this.name="EmptyError",this.message="no elements in sequence"}})),lx((function(t){return function(){t(this),this.name="ArgumentOutOfRangeError",this.message="argument out of range"}})),lx((function(t){return function(n){t(this),this.name="NotFoundError",this.message=n}})),lx((function(t){return function(n){t(this),this.name="SequenceError",this.message=n}})),lx((function(t){return function(n){void 0===n&&(n=null),t(this),this.message="Timeout has occurred",this.name="TimeoutError",this.info=n}})),new kx(gx);class uT extends ex{constructor(){super(...arguments),this.stateChanges=new Jx}get[Symbol.toStringTag](){return this.constructor.name}observeStateChanges(){return this.stateChanges}send(t){const n=this.state;super.send(t);const r=this.state;this.stateChanges.next({event:t,oldState:n,newState:r}),e.isEmptyObject(this.schema[r])&&this.stateChanges.complete()}}class lT{constructor(t=[]){this.indexToValue=[];const n=[];if(t.length>0)for(const[e,r]of t.entries())n[r]=e;this.valueToIndex=n}get[Symbol.toStringTag](){return this.constructor.name}[Symbol.iterator](){return this.indexToValue[Symbol.iterator]()}values(){return this.indexToValue[Symbol.iterator]()}has(t){return t in this.valueToIndex}add(t){if(!this.has(t)){const n=this.indexToValue.length;this.indexToValue.push(t),this.valueToIndex[t]=n}}delete(t){if(this.has(t)){const n=this.indexToValue.pop();if(t===n)delete this.valueToIndex[t];else{const e=this.valueToIndex[t];this.indexToValue[e]=n,this.valueToIndex[n]=e,delete this.valueToIndex[t]}}}}class fT{constructor(){this.keyToIndex=[],this.indexToKey=[],this.indexToValue=[]}get[Symbol.toStringTag](){return this.constructor.name}*entries(){for(let t=0;t<this.indexToKey.length;t++)yield[this.indexToKey[t],this.indexToValue[t]]}keys(){return this.indexToKey.values()}values(){return this.indexToValue.values()}has(t){return t in this.keyToIndex}get(t){if(this.has(t)){const n=this.keyToIndex[t];return this.indexToValue[n]}}set(t,n){if(this.has(t)){const e=this.keyToIndex[t];this.indexToValue[e]=n}else{const e=this.indexToKey.length;this.indexToKey.push(t),this.indexToValue.push(n),this.keyToIndex[t]=e}}delete(t){if(this.has(t)){const n=this.indexToKey.pop(),e=this.indexToValue.pop();if(t===n)delete this.keyToIndex[t];else{const r=this.keyToIndex[t];this.indexToKey[r]=n,this.indexToValue[r]=e,this.keyToIndex[t]=r,delete this.keyToIndex[t]}}}}class yT{constructor(t){this.keyToIndex=[],this.indexToKey=[],Mt.assert(0===t.length,"array should be empty"),this.indexToValue=t}get[Symbol.toStringTag](){return this.constructor.name}*entries(){for(let t=0;t<this.indexToKey.length;t++)yield[this.indexToKey[t],this.indexToValue.internalTypedArray[t]]}keys(){return this.indexToKey.values()}*values(){for(let t=0;t<this.indexToKey.length;t++)yield this.indexToValue.internalTypedArray[t]}has(t){const n=this.keyToIndex[t];return this.indexToKey[n]===t}get(t){const n=this.keyToIndex[t];return this.indexToKey[n]===t?this.indexToValue.internalTypedArray[n]:void 0}set(t,n){const e=this.keyToIndex[t];if(this.indexToKey[e]===t)this.indexToValue.internalTypedArray[e]=n;else{const e=this.indexToKey.length;this.indexToKey.push(t),this.indexToValue.push(n),this.keyToIndex[t]=e}}delete(t){const n=this.keyToIndex[t];if(this.indexToKey[n]===t){const e=this.indexToKey.pop(),r=this.indexToValue.pop();t!==e&&(this.indexToKey[n]=e,this.indexToValue.internalTypedArray[n]=r,this.keyToIndex[e]=n)}}}class dT{constructor(t){const n=[];if(t.length>0)for(const[e,r]of t.internalTypedArray.entries())n[r]=e;this.indexToValue=t,this.valueToIndex=n}get[Symbol.toStringTag](){return this.constructor.name}[Symbol.iterator](){return this.values()}*values(){for(let t=0;t<this.indexToValue.length;t++)yield this.indexToValue.internalTypedArray[t]}has(t){const n=this.valueToIndex[t];return this.indexToValue.internalTypedArray[n]===t}add(t){if(!this.has(t)){const n=this.indexToValue.length;this.indexToValue.push(t),this.valueToIndex[t]=n}}delete(t){const n=this.valueToIndex[t];if(this.indexToValue.internalTypedArray[n]===t){const e=this.indexToValue.pop();t!==e&&(this.indexToValue.internalTypedArray[n]=e,this.valueToIndex[e]=n)}}}class vT{constructor(t,{capacity:n=0,growthFactor:e=1.5}={}){this.typedArrayConstructor=t,this._length=0,Mt.assert(Number.isInteger(n),"capacity must be an integer"),Mt.assert(n>=0,"capacity must be greater than or equal to 0"),Mt.assert(e>=1,"growthFactory must be greater than or equal to 1"),this.array=new t(n),this.growthFactor=e}get internalTypedArray(){return this.array}get[Symbol.toStringTag](){return this.constructor.name}get capacity(){return this.array.length}get length(){return this._length}set(t,n){if(t>=this.capacity){const n=hT(this.capacity,t+1,this.growthFactor);this.resize(n)}t>=this._length&&(this._length=t+1),this.array[t]=n}get(t){return t<this._length?this.array[t]:void 0}push(...t){const n=this._length+t.length;if(n>this.capacity){const t=hT(this.capacity,n,this.growthFactor);this.resize(t)}for(const n of t)this.array[this._length++]=n}pop(){if(this._length>0){const t=this.array[this._length-1];this._length--;const n=hT(this.capacity,this.length,this.growthFactor);return this.resize(n),t}}resize(t){if(this.array.length!==t)if(this.array.length<t){const n=new this.typedArrayConstructor(t);n.set(this.array),this.array=n}else if(this.array.length>t){const n=new this.typedArrayConstructor(t);for(let e=t;e--;)n[e]=this.array[e];this.array=n}}}function hT(t,n,e){if(1===e)return n;if(t===n)return n;if(t<n){let r=Math.max(t,1);for(;r<n;)r*=e;return Math.floor(r)}if(0===n)return 0;{let r=t;for(;;){const t=r/e;if(t<n)break;r=t}return Math.floor(r)}}class pT{constructor(t){this.value=t,this.previous=null,this.next=null,this.up=null,this.down=null}}class mT{constructor(t){this.compare=t,this.head=new pT(null),this.tail=new pT(null),this.height=0,this._size=0,this.head.next=this.tail,this.tail.previous=this.head}get size(){return this._size}*elements(){let t=this.head;for(;t.down;)t=t.down;for(;t.next&&e.isntNull(t.next.value);)t=t.next,yield t}dumpList(){const t=[];let n=this.head;do{t.push([]);let e=n;do{t[t.length-1].push(e.value),e=e.next}while(e)}while(n=n.down);return t}delete(t){let n=this.findNode(t);for(;n;)n.previous.next=n.next,n.next.previous=n.previous,n=n.down;this._size--}has(t){return e.isntNull(this.findNode(t))}findNode(t){let n=this.head;for(;;){for(;n.next&&e.isntNull(n.next.value);){const e=this.compare(n.next.value,t);if(0===e)return n.next;if(!(e<0))break;n=n.next}if(!n.down)return null;n=n.down}}add(t){let n=this.findPreviousNode(t);if(n.next&&e.isntNull(n.next.value)&&0===this.compare(n.next.value,t))return;let r=new pT(t);n.next&&(r.next=n.next,n.next.previous=r),n.next=r,r.previous=n;let o=0;for(;Math.random()<.5;){if(o===this.height){const t=new pT(null),n=new pT(null);t.next=n,t.down=this.head,n.previous=t,n.down=this.tail,this.head.up=t,this.tail.up=n,this.head=t,this.tail=n,this.height++}for(;!n.up;)n=n.previous;n=n.up;const e=new pT(t);n.next&&(e.next=n.next,n.next.previous=e),n.next=e,e.previous=n,e.down=r,r.up=e,r=e,o++}this._size++}findPreviousNode(t){let n=this.head;for(;;){for(;n.next&&e.isntNull(n.next.value);){if(this.compare(n.next.value,t)>=0)break;n=n.next}if(!n.down)return n;n=n.down}}}class bT{constructor(t){this.skipList=new mT(t)}get[Symbol.toStringTag](){return this.constructor.name}[Symbol.iterator](){return this.values()}values(){return pc.map(this.skipList.elements(),(t=>t.value))}has(t){return this.skipList.has(t)}add(t){this.skipList.add(t)}delete(t){this.skipList.delete(t)}}class gT{constructor(){this.length=0,this.array=new vT(Uint8Array)}get[Symbol.toStringTag](){return this.constructor.name}get size(){return this.length}[Symbol.iterator](){return this.values()}*values(){for(let t=0;t<this.length;t++)this.has(t)&&(yield t)}has(t){var n;const{index:e,mask:r}=this.getPosition(t);return((null!==(n=this.array.get(e))&&void 0!==n?n:0)&r)===r}add(t){var n;Mt.assert(t>=0,"value must be greater than or equal to 0"),t>=this.length&&(this.length=t+1);const{index:e,mask:r}=this.getPosition(t);this.array.set(e,(null!==(n=this.array.get(e))&&void 0!==n?n:0)|r)}delete(t){var n;const{index:e,mask:r}=this.getPosition(t);this.array.set(e,(null!==(n=this.array.get(e))&&void 0!==n?n:0)&~r)}clear(){for(let t=this.array.length;t--;)this.array.set(t,0)}getPosition(t){const n=8*Uint8Array.BYTES_PER_ELEMENT,e=(t-t%n)/n;return{index:Math.max(0,e-1),mask:this.getMask(t)}}getMask(t){return 2**t}}export{rx as BadEventError,gT as BitSet,t as Box,vT as DynamicTypedArray,Rt as Emitter,QS as ExpirableMap,ex as FiniteStateMachine,Ut as HashMap,zt as HashSet,GS as LRUMap,uT as ObservableFiniteStateMachine,Dt as Queue,bT as SortedSet,fT as SparseMap,lT as SparseSet,ZS as TLRUMap,nx as TrieMap,yT as TypedSparseMap,dT as TypedSparseSet,Ct as convertArrayToCons,qt as convertConsToArray};
16
16
  //# sourceMappingURL=index.min.mjs.map