// ==UserScript== // @name remove the jump link in BAIDU (typescript) // @author axetroy // @collaborator axetroy // @description 去除百度搜索跳转链接 // @version 2016.11.10 // @grant GM_xmlhttpRequest // @include *www.baidu.com* // @connect * // @compatible chrome 完美运行 // @compatible firefox 完美运行 // @supportURL http://www.burningall.com // @run-at document-start // @contributionURL troy450409405@gmail.com|alipay.com // @namespace https://greasyfork.org/zh-CN/users/3400-axetroy // @license The MIT License (MIT); http://opensource.org/licenses/MIT // @downloadURL none // ==/UserScript== // Github源码:https://github.com/axetroy/bd-fuck !function(t){function e(n){if(r[n])return r[n].exports;var i=r[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,e),i.l=!0,i.exports}var r={};return e.m=t,e.c=r,e.i=function(t){return t},e.d=function(t,e,r){Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(r,"a",r),r},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=347)}([function(t,e,r){"use strict";var n=r(7),i=r(344),o=r(22),s=function(){function t(t){this._isScalar=!1,t&&(this._subscribe=t)}return t.prototype.lift=function(e){var r=new t;return r.source=this,r.operator=e,r},t.prototype.subscribe=function(t,e,r){var n=this.operator,o=i.toSubscriber(t,e,r);if(n?n.call(o,this):o.add(this._subscribe(o)),o.syncErrorThrowable&&(o.syncErrorThrowable=!1,o.syncErrorThrown))throw o.syncErrorValue;return o},t.prototype.forEach=function(t,e){var r=this;if(e||(n.root.Rx&&n.root.Rx.config&&n.root.Rx.config.Promise?e=n.root.Rx.config.Promise:n.root.Promise&&(e=n.root.Promise)),!e)throw new Error("no Promise impl found");return new e(function(e,n){var i=r.subscribe(function(e){if(i)try{t(e)}catch(t){n(t),i.unsubscribe()}else t(e)},n,e)})},t.prototype._subscribe=function(t){return this.source.subscribe(t)},t.prototype[o.$$observable]=function(){return this},t.create=function(e){return new t(e)},t}();e.Observable=s},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(36),o=r(4),s=r(40),c=r(23),u=function(t){function e(r,n,i){switch(t.call(this),this.syncErrorValue=null,this.syncErrorThrown=!1,this.syncErrorThrowable=!1,this.isStopped=!1,arguments.length){case 0:this.destination=s.empty;break;case 1:if(!r){this.destination=s.empty;break}if("object"==typeof r){r instanceof e?(this.destination=r,this.destination.add(this)):(this.syncErrorThrowable=!0,this.destination=new a(this,r));break}default:this.syncErrorThrowable=!0,this.destination=new a(this,r,n,i)}}return n(e,t),e.prototype[c.$$rxSubscriber]=function(){return this},e.create=function(t,r,n){var i=new e(t,r,n);return i.syncErrorThrowable=!1,i},e.prototype.next=function(t){this.isStopped||this._next(t)},e.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},e.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},e.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,t.prototype.unsubscribe.call(this))},e.prototype._next=function(t){this.destination.next(t)},e.prototype._error=function(t){this.destination.error(t),this.unsubscribe()},e.prototype._complete=function(){this.destination.complete(),this.unsubscribe()},e}(o.Subscription);e.Subscriber=u;var a=function(t){function e(e,r,n,o){t.call(this),this._parent=e;var s,c=this;i.isFunction(r)?s=r:r&&(c=r,s=r.next,n=r.error,o=r.complete,i.isFunction(c.unsubscribe)&&this.add(c.unsubscribe.bind(c)),c.unsubscribe=this.unsubscribe.bind(this)),this._context=c,this._next=s,this._error=n,this._complete=o}return n(e,t),e.prototype.next=function(t){if(!this.isStopped&&this._next){var e=this._parent;e.syncErrorThrowable?this.__tryOrSetError(e,this._next,t)&&this.unsubscribe():this.__tryOrUnsub(this._next,t)}},e.prototype.error=function(t){if(!this.isStopped){var e=this._parent;if(this._error)e.syncErrorThrowable?(this.__tryOrSetError(e,this._error,t),this.unsubscribe()):(this.__tryOrUnsub(this._error,t),this.unsubscribe());else{if(!e.syncErrorThrowable)throw this.unsubscribe(),t;e.syncErrorValue=t,e.syncErrorThrown=!0,this.unsubscribe()}}},e.prototype.complete=function(){if(!this.isStopped){var t=this._parent;this._complete?t.syncErrorThrowable?(this.__tryOrSetError(t,this._complete),this.unsubscribe()):(this.__tryOrUnsub(this._complete),this.unsubscribe()):this.unsubscribe()}},e.prototype.__tryOrUnsub=function(t,e){try{t.call(this._context,e)}catch(t){throw this.unsubscribe(),t}},e.prototype.__tryOrSetError=function(t,e,r){try{e.call(this._context,r)}catch(e){return t.syncErrorValue=e,t.syncErrorThrown=!0,!0}return!1},e.prototype._unsubscribe=function(){var t=this._parent;this._context=null,this._parent=null,t.unsubscribe()},e}(u)},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(1),o=function(t){function e(){t.apply(this,arguments)}return n(e,t),e.prototype.notifyNext=function(t,e,r,n,i){this.destination.next(e)},e.prototype.notifyError=function(t,e){this.destination.error(t)},e.prototype.notifyComplete=function(t){this.destination.complete()},e}(i.Subscriber);e.OuterSubscriber=o},function(t,e,r){"use strict";function n(t,e,r,n){var l=new a.InnerSubscriber(t,r,n);if(l.closed)return null;if(e instanceof c.Observable)return e._isScalar?(l.next(e.value),l.complete(),null):e.subscribe(l);if(o.isArray(e)){for(var p=0,f=e.length;p1?new e(t,n):1===i?new o.ScalarObservable(t[0],n):new s.EmptyObservable(n)},e.dispatch=function(t){var e=t.array,r=t.index,n=t.count,i=t.subscriber;return r>=n?void i.complete():(i.next(e[r]),void(i.closed||(t.index=r+1,this.schedule(t))))},e.prototype._subscribe=function(t){var r=0,n=this.array,i=n.length,o=this.scheduler;if(o)return o.schedule(e.dispatch,0,{array:n,index:r,count:i,subscriber:t});for(var s=0;s=0&&(t._idleTimeoutId=setTimeout(function(){t._onTimeout&&t._onTimeout()},e))},e.setImmediate="function"==typeof t?t:function(t){var r=a++,n=!(arguments.length<2)&&c.call(arguments,1);return u[r]=!0,o(function(){u[r]&&(n?t.apply(null,n):t.call(null),e.clearImmediate(r))}),r},e.clearImmediate="function"==typeof n?n:function(t){delete u[t]}}).call(e,r(19).setImmediate,r(19).clearImmediate)},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(5),o=r(4),s=function(t){function e(){t.apply(this,arguments),this.value=null,this.hasNext=!1,this.hasCompleted=!1}return n(e,t),e.prototype._subscribe=function(e){return this.hasCompleted&&this.hasNext?(e.next(this.value),e.complete(),o.Subscription.EMPTY):this.hasError?(e.error(this.thrownError),o.Subscription.EMPTY):t.prototype._subscribe.call(this,e)},e.prototype.next=function(t){this.hasCompleted||(this.value=t,this.hasNext=!0)},e.prototype.complete=function(){this.hasCompleted=!0,this.hasNext&&t.prototype.next.call(this,this.value),t.prototype.complete.call(this)},e}(i.Subject);e.AsyncSubject=s},function(t,e,r){"use strict";function n(t){return void 0===t&&(t=Number.POSITIVE_INFINITY),this.lift(new c(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.mergeAll=n;var c=function(){function t(t){this.concurrent=t}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.concurrent))},t}();e.MergeAllOperator=c;var u=function(t){function e(e,r){t.call(this,e),this.concurrent=r,this.hasCompleted=!1,this.buffer=[],this.active=0}return i(e,t),e.prototype._next=function(t){this.active0?this._next(e.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()},e}(o.OuterSubscriber);e.MergeAllSubscriber=u},function(t,e,r){"use strict";function n(t){var e,r=t.Symbol;return"function"==typeof r?r.observable?e=r.observable:(e=r("observable"),r.observable=e):e="@@observable",e}var i=r(7);e.getSymbolObservable=n,e.$$observable=n(i.root)},function(t,e,r){"use strict";var n=r(7),i=n.root.Symbol;e.$$rxSubscriber="function"==typeof i&&"function"==typeof i.for?i.for("rxSubscriber"):"@@rxSubscriber"},function(t,e){"use strict";var r=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},n=function(t){function e(){var e=t.call(this,"argument out of range");this.name=e.name="ArgumentOutOfRangeError",this.stack=e.stack,this.message=e.message}return r(e,t),e}(Error);e.ArgumentOutOfRangeError=n},function(t,e){"use strict";var r=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},n=function(t){function e(){var e=t.call(this,"no elements in sequence");this.name=e.name="EmptyError",this.stack=e.stack,this.message=e.message}return r(e,t),e}(Error);e.EmptyError=n},function(t,e){"use strict";var r=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},n=function(t){function e(){var e=t.call(this,"object unsubscribed");this.name=e.name="ObjectUnsubscribedError",this.stack=e.stack,this.message=e.message}return r(e,t),e}(Error);e.ObjectUnsubscribedError=n},function(t,e){"use strict";function r(t){return t instanceof Date&&!isNaN(+t)}e.isDate=r},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(5),o=r(58),s=r(4),c=r(33),u=r(26),a=r(41),h=function(t){function e(e,r,n){void 0===e&&(e=Number.POSITIVE_INFINITY),void 0===r&&(r=Number.POSITIVE_INFINITY),t.call(this),this.scheduler=n,this._events=[],this._bufferSize=e<1?1:e,this._windowTime=r<1?1:r}return n(e,t),e.prototype.next=function(e){var r=this._getNow();this._events.push(new l(r,e)),this._trimBufferThenGetEvents(),t.prototype.next.call(this,e)},e.prototype._subscribe=function(t){var e,r=this._trimBufferThenGetEvents(),n=this.scheduler;if(this.closed)throw new u.ObjectUnsubscribedError;this.hasError?e=s.Subscription.EMPTY:this.isStopped?e=s.Subscription.EMPTY:(this.observers.push(t),e=new a.SubjectSubscription(this,t)),n&&t.add(t=new c.ObserveOnSubscriber(t,n));for(var i=r.length,o=0;oe&&(o=Math.max(o,i-e)),o>0&&n.splice(0,o),n},e}(i.Subject);e.ReplaySubject=h;var l=function(){function t(t,e){this.time=t,this.value=e}return t}()},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(0),o=function(t){function e(e,r){t.call(this),this.value=e,this.scheduler=r,this._isScalar=!0,r&&(this._isScalar=!1)}return n(e,t),e.create=function(t,r){return new e(t,r)},e.dispatch=function(t){var e=t.done,r=t.value,n=t.subscriber;return e?void n.complete():(n.next(r),void(n.closed||(t.done=!0,this.schedule(t))))},e.prototype._subscribe=function(t){var r=this.value,n=this.scheduler;return n?n.schedule(e.dispatch,0,{done:!1,value:r,subscriber:t}):(t.next(r),void(t.closed||t.complete()))},e}(i.Observable);e.ScalarObservable=o},function(t,e,r){"use strict";function n(){for(var t=[],e=0;e=2&&(r=!0),this.lift(new s(t,e,r))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.reduce=n;var s=function(){function t(t,e,r){void 0===r&&(r=!1),this.accumulator=t,this.seed=e,this.hasSeed=r}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.accumulator,this.seed,this.hasSeed))},t}();e.ReduceOperator=s;var c=function(t){function e(e,r,n,i){t.call(this,e),this.accumulator=r,this.hasSeed=i,this.hasValue=!1,this.acc=n}return i(e,t),e.prototype._next=function(t){this.hasValue||(this.hasValue=this.hasSeed)?this._tryReduce(t):(this.acc=t,this.hasValue=!0)},e.prototype._tryReduce=function(t){var e;try{e=this.accumulator(this.acc,t)}catch(t){return void this.destination.error(t)}this.acc=e},e.prototype._complete=function(){(this.hasValue||this.hasSeed)&&this.destination.next(this.acc),this.destination.complete()},e}(o.Subscriber);e.ReduceSubscriber=c},function(t,e,r){"use strict";function n(){for(var t=[],e=0;ethis.index},t.prototype.hasCompleted=function(){return this.array.length===this.index},t}(),y=function(t){function e(e,r,n){t.call(this,e),this.parent=r,this.observable=n,this.stillUnsubscribed=!0,this.buffer=[],this.isComplete=!1}return o(e,t),e.prototype[l.$$iterator]=function(){return this},e.prototype.next=function(){var t=this.buffer;return 0===t.length&&this.isComplete?{value:null,done:!0}:{value:t.shift(),done:!1}},e.prototype.hasValue=function(){return this.buffer.length>0},e.prototype.hasCompleted=function(){return 0===this.buffer.length&&this.isComplete},e.prototype.notifyComplete=function(){this.buffer.length>0?(this.isComplete=!0,this.parent.notifyInactive()):this.destination.complete()},e.prototype.notifyNext=function(t,e,r,n,i){this.buffer.push(e),this.parent.checkIterators()},e.prototype.subscribe=function(t,e){return h.subscribeToResult(this,this.observable,this,e)},e}(a.OuterSubscriber)},function(t,e){"use strict";function r(t){return"function"==typeof t}e.isFunction=r},function(t,e,r){ "use strict";function n(t){return!i.isArray(t)&&t-parseFloat(t)+1>=0}var i=r(10);e.isNumeric=n},function(t,e){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function i(t){if(h===setTimeout)return setTimeout(t,0);if((h===r||!h)&&setTimeout)return h=setTimeout,setTimeout(t,0);try{return h(t,0)}catch(e){try{return h.call(null,t,0)}catch(e){return h.call(this,t,0)}}}function o(t){if(l===clearTimeout)return clearTimeout(t);if((l===n||!l)&&clearTimeout)return l=clearTimeout,clearTimeout(t);try{return l(t)}catch(e){try{return l.call(null,t)}catch(e){return l.call(this,t)}}}function s(){d&&f&&(d=!1,f.length?b=f.concat(b):y=-1,b.length&&c())}function c(){if(!d){var t=i(s);d=!0;for(var e=b.length;e;){for(f=b,b=[];++y1)for(var r=1;r1)return void(this.connection=null);var r=this.connection,n=t._connection;this.connection=null,!n||r&&n!==r||n.unsubscribe()},e}(s.Subscriber)},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(10),o=r(64),s=r(44),c=r(210),u=r(11),a=r(199),h=r(18),l=r(0),p=r(33),f=r(22),b=function(t){return t&&"number"==typeof t.length},d=function(t){function e(e,r){t.call(this,null),this.ish=e,this.scheduler=r}return n(e,t),e.create=function(t,r){if(null!=t){if("function"==typeof t[f.$$observable])return t instanceof l.Observable&&!r?t:new e(t,r);if(i.isArray(t))return new u.ArrayObservable(t,r);if(o.isPromise(t))return new s.PromiseObservable(t,r);if("function"==typeof t[h.$$iterator]||"string"==typeof t)return new c.IteratorObservable(t,r);if(b(t))return new a.ArrayLikeObservable(t,r)}throw new TypeError((null!==t&&typeof t||t)+" is not observable")},e.prototype._subscribe=function(t){var e=this.ish,r=this.scheduler;return null==r?e[f.$$observable]().subscribe(t):e[f.$$observable]().subscribe(new p.ObserveOnSubscriber(t,r,0))},e}(l.Observable);e.FromObservable=d},function(t,e,r){"use strict";function n(t){var e=t.value,r=t.subscriber;r.closed||(r.next(e),r.complete())}function i(t){var e=t.err,r=t.subscriber;r.closed||r.error(e)}var o=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},s=r(7),c=r(0),u=function(t){function e(e,r){t.call(this),this.promise=e,this.scheduler=r}return o(e,t),e.create=function(t,r){return new e(t,r)},e.prototype._subscribe=function(t){var e=this,r=this.promise,o=this.scheduler;if(null==o)this._isScalar?t.closed||(t.next(this.value),t.complete()):r.then(function(r){e.value=r,e._isScalar=!0,t.closed||(t.next(r),t.complete())},function(e){t.closed||t.error(e)}).then(null,function(t){s.root.setTimeout(function(){throw t})});else if(this._isScalar){if(!t.closed)return o.schedule(n,0,{value:this.value,subscriber:t})}else r.then(function(r){e.value=r,e._isScalar=!0,t.closed||t.add(o.schedule(n,0,{value:r,subscriber:t}))},function(e){t.closed||t.add(o.schedule(i,0,{err:e,subscriber:t}))}).then(null,function(t){s.root.setTimeout(function(){throw t})})},e}(c.Observable);e.PromiseObservable=u},function(t,e,r){"use strict";function n(){if(l.root.XMLHttpRequest){var t=new l.root.XMLHttpRequest;return"withCredentials"in t&&(t.withCredentials=!!this.withCredentials),t}if(l.root.XDomainRequest)return new l.root.XDomainRequest;throw new Error("CORS is not supported by your browser")}function i(){if(l.root.XMLHttpRequest)return new l.root.XMLHttpRequest;var t=void 0;try{for(var e=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"],r=0;r<3;r++)try{if(t=e[r],new l.root.ActiveXObject(t))break}catch(t){}return new l.root.ActiveXObject(t)}catch(t){throw new Error("XMLHttpRequest is not supported by your browser")}}function o(t,e){return void 0===e&&(e=null),new v({method:"GET",url:t,headers:e})}function s(t,e,r){return new v({method:"POST",url:t,body:e,headers:r})}function c(t,e){return new v({method:"DELETE",url:t,headers:e})}function u(t,e,r){return new v({method:"PUT",url:t,body:e,headers:r})}function a(t,e){return new v({method:"GET",url:t,responseType:"json",headers:e}).lift(new y.MapOperator(function(t,e){return t.response},null))}var h=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},l=r(7),p=r(8),f=r(6),b=r(0),d=r(1),y=r(32);e.ajaxGet=o,e.ajaxPost=s,e.ajaxDelete=c,e.ajaxPut=u,e.ajaxGetJSON=a;var v=function(t){function e(e){t.call(this);var r={async:!0,createXHR:function(){return this.crossDomain?n.call(this):i()},crossDomain:!1,withCredentials:!1,headers:{},method:"GET",responseType:"json",timeout:0};if("string"==typeof e)r.url=e;else for(var o in e)e.hasOwnProperty(o)&&(r[o]=e[o]);this.request=r}return h(e,t),e.prototype._subscribe=function(t){return new m(t,this.request)},e.create=function(){var t=function(t){return new e(t)};return t.get=o,t.post=s,t.delete=c,t.put=u,t.getJSON=a,t}(),e}(b.Observable);e.AjaxObservable=v;var m=function(t){function e(e,r){t.call(this,e),this.request=r,this.done=!1;var n=r.headers=r.headers||{};r.crossDomain||n["X-Requested-With"]||(n["X-Requested-With"]="XMLHttpRequest"),"Content-Type"in n||l.root.FormData&&r.body instanceof l.root.FormData||"undefined"==typeof r.body||(n["Content-Type"]="application/x-www-form-urlencoded; charset=UTF-8"),r.body=this.serializeBody(r.body,r.headers["Content-Type"]),this.send()}return h(e,t),e.prototype.next=function(t){this.done=!0;var e=this,r=e.xhr,n=e.request,i=e.destination,o=new w(t,r,n);i.next(o)},e.prototype.send=function(){var t=this,e=t.request,r=t.request,n=r.user,i=r.method,o=r.url,s=r.async,c=r.password,u=r.headers,a=r.body,h=e.createXHR,l=p.tryCatch(h).call(e);if(l===f.errorObject)this.error(f.errorObject.e);else{this.xhr=l;var b=void 0;if(b=n?p.tryCatch(l.open).call(l,i,o,s,n,c):p.tryCatch(l.open).call(l,i,o,s),b===f.errorObject)return this.error(f.errorObject.e),null;l.timeout=e.timeout,l.responseType=e.responseType,this.setHeaders(l,u),this.setupEvents(l,e),a?l.send(a):l.send()}return l},e.prototype.serializeBody=function(t,e){if(!t||"string"==typeof t)return t;if(l.root.FormData&&t instanceof l.root.FormData)return t;if(e){var r=e.indexOf(";");r!==-1&&(e=e.substring(0,r))}switch(e){case"application/x-www-form-urlencoded":return Object.keys(t).map(function(e){return encodeURI(e)+"="+encodeURI(t[e])}).join("&");case"application/json":return JSON.stringify(t);default:return t}},e.prototype.setHeaders=function(t,e){for(var r in e)e.hasOwnProperty(r)&&t.setRequestHeader(r,e[r])},e.prototype.setupEvents=function(t,e){function r(t){var e=r,n=e.subscriber,i=e.progressSubscriber,o=e.request;i&&i.error(t),n.error(new x(this,o))}function n(t){var e=n,r=e.subscriber,i=e.progressSubscriber,o=e.request;if(4===this.readyState){var s=1223===this.status?204:this.status,c="text"===this.responseType?this.response||this.responseText:this.response;0===s&&(s=c?200:0),200<=s&&s<300?(i&&i.complete(),r.next(t),r.complete()):(i&&i.error(t),r.error(new _("ajax error "+s,this,o)))}}var i=e.progressSubscriber;if(t.ontimeout=r,r.request=e,r.subscriber=this,r.progressSubscriber=i,t.upload&&"withCredentials"in t&&l.root.XDomainRequest){if(i){var o;o=function(t){var e=o.progressSubscriber;e.next(t)},t.onprogress=o,o.progressSubscriber=i}var s;s=function(t){var e=s,r=e.progressSubscriber,n=e.subscriber,i=e.request;r&&r.error(t),n.error(new _("ajax error",this,i))},t.onerror=s,s.request=e,s.subscriber=this,s.progressSubscriber=i}t.onreadystatechange=n,n.subscriber=this,n.progressSubscriber=i,n.request=e},e.prototype.unsubscribe=function(){var e=this,r=e.done,n=e.xhr;!r&&n&&4!==n.readyState&&"function"==typeof n.abort&&n.abort(),t.prototype.unsubscribe.call(this)},e}(d.Subscriber);e.AjaxSubscriber=m;var w=function(){function t(t,e,r){switch(this.originalEvent=t,this.xhr=e,this.request=r,this.status=e.status,this.responseType=e.responseType||r.responseType,this.responseType){case"json":"response"in e?this.response=e.responseType?e.response:JSON.parse(e.response||e.responseText||"null"):this.response=JSON.parse(e.responseText||"null");break;case"xml":this.response=e.responseXML;break;case"text":default:this.response="response"in e?e.response:e.responseText}}return t}();e.AjaxResponse=w;var _=function(t){function e(e,r,n){t.call(this,e),this.message=e,this.xhr=r,this.request=n,this.status=r.status}return h(e,t),e}(Error);e.AjaxError=_;var x=function(t){function e(e,r){t.call(this,"ajax timeout",e,r)}return h(e,t),e}(_);e.AjaxTimeoutError=x},function(t,e,r){"use strict";function n(t,e){return this.lift(new u(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(8),c=r(6);e.distinctUntilChanged=n;var u=function(){function t(t,e){this.compare=t,this.keySelector=e}return t.prototype.call=function(t,e){return e._subscribe(new a(t,this.compare,this.keySelector))},t}(),a=function(t){function e(e,r,n){t.call(this,e),this.keySelector=n,this.hasKey=!1,"function"==typeof r&&(this.compare=r)}return i(e,t),e.prototype.compare=function(t,e){return t===e},e.prototype._next=function(t){var e=this.keySelector,r=t;if(e&&(r=s.tryCatch(this.keySelector)(t),r===c.errorObject))return this.destination.error(c.errorObject.e);var n=!1;if(this.hasKey){if(n=s.tryCatch(this.compare)(this.key,r),n===c.errorObject)return this.destination.error(c.errorObject.e)}else this.hasKey=!0;Boolean(n)===!1&&(this.key=r,this.destination.next(t))},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new s(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.filter=n;var s=function(){function t(t,e){this.predicate=t,this.thisArg=e}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.predicate,this.thisArg))},t}(),c=function(t){function e(e,r,n){t.call(this,e),this.predicate=r,this.thisArg=n,this.count=0,this.predicate=r}return i(e,t),e.prototype._next=function(t){var e;try{e=this.predicate.call(this.thisArg,t,this.count++)}catch(t){return void this.destination.error(t)}e&&this.destination.next(t)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e){if("function"!=typeof t)throw new TypeError("predicate is not a function");return this.lift(new s(t,this,!1,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.find=n;var s=function(){function t(t,e,r,n){this.predicate=t,this.source=e,this.yieldIndex=r,this.thisArg=n}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.predicate,this.source,this.yieldIndex,this.thisArg))},t}();e.FindValueOperator=s;var c=function(t){function e(e,r,n,i,o){t.call(this,e),this.predicate=r,this.source=n,this.yieldIndex=i,this.thisArg=o,this.index=0}return i(e,t),e.prototype.notifyComplete=function(t){var e=this.destination;e.next(t),e.complete()},e.prototype._next=function(t){var e=this,r=e.predicate,n=e.thisArg,i=this.index++;try{var o=r.call(n||this,t,i,this.source);o&&this.notifyComplete(this.yieldIndex?i:t)}catch(t){this.destination.error(t)}},e.prototype._complete=function(){this.notifyComplete(this.yieldIndex?-1:void 0)},e}(o.Subscriber);e.FindValueSubscriber=c},function(t,e,r){"use strict";function n(){for(var t=[],e=0;e1&&"number"==typeof t[t.length-1]&&(r=t.pop())):"number"==typeof i&&(r=t.pop()),null===n&&1===t.length?t[0]:new o.ArrayObservable(t,n).lift(new s.MergeAllOperator(r))}var o=r(11),s=r(21),c=r(13);e.merge=n,e.mergeStatic=i},function(t,e,r){"use strict";function n(t,e,r){return void 0===r&&(r=Number.POSITIVE_INFINITY),"number"==typeof e&&(r=e,e=null),this.lift(new c(t,e,r))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(3),s=r(2);e.mergeMap=n;var c=function(){function t(t,e,r){void 0===r&&(r=Number.POSITIVE_INFINITY),this.project=t,this.resultSelector=e,this.concurrent=r}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.project,this.resultSelector,this.concurrent))},t}();e.MergeMapOperator=c;var u=function(t){function e(e,r,n,i){void 0===i&&(i=Number.POSITIVE_INFINITY),t.call(this,e),this.project=r,this.resultSelector=n,this.concurrent=i,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}return i(e,t),e.prototype._next=function(t){this.active0?this._next(e.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()},e}(s.OuterSubscriber);e.MergeMapSubscriber=u},function(t,e,r){"use strict";function n(t,e,r){return void 0===r&&(r=Number.POSITIVE_INFINITY),"number"==typeof e&&(r=e,e=null),this.lift(new c(t,e,r))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.mergeMapTo=n;var c=function(){function t(t,e,r){void 0===r&&(r=Number.POSITIVE_INFINITY),this.ish=t,this.resultSelector=e,this.concurrent=r}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.ish,this.resultSelector,this.concurrent))},t}();e.MergeMapToOperator=c;var u=function(t){function e(e,r,n,i){void 0===i&&(i=Number.POSITIVE_INFINITY),t.call(this,e),this.ish=r,this.resultSelector=n,this.concurrent=i,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}return i(e,t),e.prototype._next=function(t){if(this.active0?this._next(e.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()},e}(o.OuterSubscriber);e.MergeMapToSubscriber=u},function(t,e,r){"use strict";function n(){for(var t=[],e=0;ee.index?1:-1:t.delay>e.delay?1:-1},e}(i.AsyncAction);e.VirtualAction=c},function(t,e,r){"use strict";var n=r(327),i=r(328);e.asap=new i.AsapScheduler(n.AsapAction)},function(t,e,r){"use strict";var n=r(329),i=r(330);e.queue=new i.QueueScheduler(n.QueueAction)},function(t,e){"use strict";var r=function(){function t(t,e){void 0===e&&(e=Number.POSITIVE_INFINITY),this.subscribedFrame=t,this.unsubscribedFrame=e}return t}();e.SubscriptionLog=r},function(t,e,r){"use strict";var n=r(59),i=function(){function t(){this.subscriptions=[]}return t.prototype.logSubscribedFrame=function(){return this.subscriptions.push(new n.SubscriptionLog(this.scheduler.now())),this.subscriptions.length-1},t.prototype.logUnsubscribedFrame=function(t){var e=this.subscriptions,r=e[t];e[t]=new n.SubscriptionLog(r.subscribedFrame,this.scheduler.now())},t}();e.SubscriptionLoggable=i},function(t,e){"use strict";var r=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},n=function(t){function e(){var e=t.call(this,"Timeout has occurred");this.name=e.name="TimeoutError",this.stack=e.stack,this.message=e.message}return r(e,t),e}(Error);e.TimeoutError=n},function(t,e){"use strict";var r=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},n=function(t){function e(e){t.call(this),this.errors=e;var r=Error.call(this,e?e.length+" errors occurred during unsubscription:\n "+e.map(function(t,e){return e+1+") "+t.toString()}).join("\n "):"");this.name=r.name="UnsubscriptionError",this.stack=r.stack,this.message=r.message}return r(e,t),e}(Error);e.UnsubscriptionError=n},function(t,e){"use strict";function r(t,e){for(var r=0,n=e.length;r - https://camwiegert.github.io/in-view * License: MIT */ !function(e,r){t.exports=r()}(this,function(){return function(t){function e(n){if(r[n])return r[n].exports;var i=r[n]={exports:{},id:n,loaded:!1};return t[n].call(i.exports,i,i.exports,e),i.loaded=!0,i.exports}var r={};return e.m=t,e.c=r,e.p="",e(0)}([function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}var i=r(2),o=n(i);t.exports=o.default},function(t,e){function r(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}t.exports=r},function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var i=r(9),o=n(i),s=r(3),c=n(s),u=r(4),a=function(){if("undefined"!=typeof window){var t=100,e=["scroll","resize","load"],r={history:[]},n={offset:{},threshold:0,test:u.inViewport},i=(0,o.default)(function(){r.history.forEach(function(t){r[t].check()})},t);e.forEach(function(t){return addEventListener(t,i)}),window.MutationObserver&&new MutationObserver(i).observe(document.body,{attributes:!0,childList:!0,subtree:!0});var s=function(t){if("string"==typeof t){var e=[].slice.call(document.querySelectorAll(t));return r.history.indexOf(t)>-1?r[t].elements=e:(r[t]=(0,c.default)(e,n),r.history.push(t)),r[t]}};return s.offset=function(t){if(void 0===t)return n.offset;var e=function(t){return"number"==typeof t};return["top","right","bottom","left"].forEach(e(t)?function(e){return n.offset[e]=t}:function(r){return e(t[r])?n.offset[r]=t[r]:null}),n.offset},s.threshold=function(t){return"number"==typeof t&&t>=0&&t<=1?n.threshold=t:n.threshold},s.test=function(t){return"function"==typeof t?n.test=t:n.test},s.is=function(t){return n.test(t,n)},s.offset(0),s}};e.default=a()},function(t,e){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var n=function(){function t(t,e){for(var r=0;r-1,o=r&&!i,s=!r&&i;o&&(t.current.push(e),t.emit("enter",e)),s&&(t.current.splice(n,1),t.emit("exit",e))}),this}},{key:"on",value:function(t,e){return this.handlers[t].push(e),this}},{key:"once",value:function(t,e){return this.singles[t].unshift(e),this}},{key:"emit",value:function(t,e){for(;this.singles[t].length;)this.singles[t].pop()(e);for(var r=this.handlers[t].length;--r>-1;)this.handlers[t][r](e);return this}}]),t}();e.default=function(t,e){return new i(t,e)}},function(t,e){"use strict";function r(t,e){var r=t.getBoundingClientRect(),n=r.top,i=r.right,o=r.bottom,s=r.left,c=r.width,u=r.height,a={t:o,r:window.innerWidth-s,b:window.innerHeight-n,l:i},h={x:e.threshold*c,y:e.threshold*u};return a.t>e.offset.top+h.y&&a.r>e.offset.right+h.x&&a.b>e.offset.bottom+h.y&&a.l>e.offset.left+h.x}Object.defineProperty(e,"__esModule",{value:!0}),e.inViewport=r},function(t,e){(function(e){var r="object"==typeof e&&e&&e.Object===Object&&e;t.exports=r}).call(e,function(){return this}())},function(t,e,r){var n=r(5),i="object"==typeof self&&self&&self.Object===Object&&self,o=n||i||Function("return this")();t.exports=o},function(t,e,r){function n(t,e,r){function n(e){var r=m,n=w;return m=w=void 0,g=e,x=t.apply(n,r)}function h(t){return g=t,O=setTimeout(f,e),j?n(t):x}function l(t){var r=t-S,n=t-g,i=e-r;return T?a(i,_-n):i}function p(t){var r=t-S,n=t-g;return void 0===S||r>=e||r<0||T&&n>=_}function f(){var t=o();return p(t)?b(t):void(O=setTimeout(f,l(t)))}function b(t){return O=void 0,E&&m?n(t):(m=w=void 0,x)}function d(){void 0!==O&&clearTimeout(O),g=0,m=S=w=O=void 0}function y(){return void 0===O?x:b(o())}function v(){var t=o(),r=p(t);if(m=arguments,w=this,S=t,r){if(void 0===O)return h(S);if(T)return O=setTimeout(f,e),n(S)}return void 0===O&&(O=setTimeout(f,e)),x}var m,w,_,x,O,S,g=0,j=!1,T=!1,E=!0;if("function"!=typeof t)throw new TypeError(c);return e=s(e)||0,i(r)&&(j=!!r.leading,T="maxWait"in r,_=T?u(s(r.maxWait)||0,e):_,E="trailing"in r?!!r.trailing:E),v.cancel=d,v.flush=y,v}var i=r(1),o=r(8),s=r(10),c="Expected a function",u=Math.max,a=Math.min;t.exports=n},function(t,e,r){var n=r(6),i=function(){return n.Date.now()};t.exports=i},function(t,e,r){function n(t,e,r){var n=!0,c=!0;if("function"!=typeof t)throw new TypeError(s);return o(r)&&(n="leading"in r?!!r.leading:n,c="trailing"in r?!!r.trailing:c),i(t,e,{leading:n,maxWait:e,trailing:c})}var i=r(7),o=r(1),s="Expected a function";t.exports=n},function(t,e){function r(t){return t}t.exports=r}])})},function(t,e,r){"use strict";var n=r(5);e.Subject=n.Subject,e.AnonymousSubject=n.AnonymousSubject;var i=r(0);e.Observable=i.Observable,r(72),r(73),r(74),r(75),r(76),r(79),r(80),r(81),r(82),r(83),r(84),r(85),r(86),r(87),r(88),r(93),r(89),r(90),r(91),r(92),r(94),r(97),r(95),r(96),r(98),r(77),r(78),r(101),r(102),r(103),r(104),r(105),r(106),r(107),r(108),r(109),r(110),r(111),r(112),r(113),r(119),r(114),r(115),r(116),r(117),r(118),r(120),r(121),r(122),r(123),r(126),r(127),r(128),r(124),r(129),r(130),r(131),r(132),r(133),r(134),r(135),r(136),r(99),r(100),r(137),r(138),r(125),r(139),r(140),r(141),r(142),r(143),r(144),r(145),r(146),r(147),r(148),r(149),r(150),r(151),r(152),r(153),r(154),r(155),r(156),r(158),r(157),r(159),r(160),r(161),r(162),r(163),r(164),r(165),r(166),r(167),r(168),r(169),r(170),r(171),r(172),r(173),r(174),r(175),r(176),r(177),r(178),r(179),r(180),r(181),r(182),r(183),r(184),r(185),r(186),r(187),r(188),r(189),r(190),r(191),r(192),r(193),r(194),r(195),r(196),r(197),r(198);var o=r(4);e.Subscription=o.Subscription;var s=r(1);e.Subscriber=s.Subscriber;var c=r(20);e.AsyncSubject=c.AsyncSubject;var u=r(28);e.ReplaySubject=u.ReplaySubject;var a=r(39);e.BehaviorSubject=a.BehaviorSubject;var h=r(42);e.ConnectableObservable=h.ConnectableObservable;var l=r(15);e.Notification=l.Notification;var p=r(25);e.EmptyError=p.EmptyError;var f=r(24);e.ArgumentOutOfRangeError=f.ArgumentOutOfRangeError;var b=r(26);e.ObjectUnsubscribedError=b.ObjectUnsubscribedError;var d=r(61);e.TimeoutError=d.TimeoutError;var y=r(62);e.UnsubscriptionError=y.UnsubscriptionError;var v=r(54);e.TimeInterval=v.TimeInterval;var m=r(55);e.Timestamp=m.Timestamp;var w=r(334);e.TestScheduler=w.TestScheduler;var _=r(56);e.VirtualTimeScheduler=_.VirtualTimeScheduler;var x=r(45);e.AjaxResponse=x.AjaxResponse,e.AjaxError=x.AjaxError,e.AjaxTimeoutError=x.AjaxTimeoutError;var O=r(57),S=r(9),g=r(58),j=r(331),T=r(23),E=r(18),k=r(22),I={asap:O.asap,queue:g.queue,animationFrame:j.animationFrame,async:S.async};e.Scheduler=I;var A={rxSubscriber:T.$$rxSubscriber,observable:k.$$observable,iterator:E.$$iterator};e.Symbol=A},function(t,e,r){"use strict";var n=r(345),i=r(69),o=function(){function t(t){this.options=t}return t.prototype.request=function(t){var e=n.extend({},this.options,t),r=i.defer(),o=e.onreadystatechange,s=e.onerror,c=e.onabort,u=e.ontimeout;e.synchronous=!0,e.onreadystatechange=function(t){n.isFunction(o)&&o.call(this,t),4===t.readyState&&(/^(2|3)/.test(t.status+"")||t.finalUrl?r.resolve(t):r.reject(t))},e.onerror=function(t){n.isFunction(s)&&s.call(this,t),r.reject(t)},e.onabort=function(t){n.isFunction(c)&&c.call(this,t),r.reject(t)},e.ontimeout=function(t){n.isFunction(u)&&u.call(this,t),r.reject(t)};var a=n.extend({},e);return GM_xmlhttpRequest(a),r.promise},t.prototype.get=function(t,e){var r=n.extend(e||{},{url:t,method:"GET"});return this.request(r)},t.prototype.post=function(t,e,r){return this.request(n.extend(r||{},{url:t,method:"POST",data:e}))},t.prototype.head=function(t,e){return this.request(n.extend(e||{},{url:t,method:"HEAD"}))},t}();Object.defineProperty(e,"__esModule",{value:!0}),e.default=o},function(t,e,r){(function(e,r){/*! * * Copyright 2009-2012 Kris Kowal under the terms of the MIT * license found at http://github.com/kriskowal/q/raw/master/LICENSE * * With parts by Tyler Close * Copyright 2007-2009 Tyler Close under the terms of the MIT X license found * at http://www.opensource.org/licenses/mit-license.html * Forked at ref_send.js version: 2009-05-11 * * With parts by Mark Miller * Copyright (C) 2011 Google Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ !function(e){"use strict";if("function"==typeof bootstrap)bootstrap("promise",e);else{t.exports=e()}}(function(){"use strict";function t(t){return function(){return G.apply(t,arguments)}}function n(t){return t===Object(t)}function i(t){return"[object StopIteration]"===nt(t)||t instanceof z}function o(t,e){if(W&&e.stack&&"object"==typeof t&&null!==t&&t.stack&&t.stack.indexOf(it)===-1){for(var r=[],n=e;n;n=n.source)n.stack&&r.unshift(n.stack);r.unshift(t.stack);var i=r.join("\n"+it+"\n");t.stack=s(i)}}function s(t){for(var e=t.split("\n"),r=[],n=0;n=Y&&n<=at}function h(){if(W)try{throw new Error}catch(n){var t=n.stack.split("\n"),e=t[0].indexOf("@")>0?t[1]:t[2],r=u(e);if(!r)return;return $=r[0],r[1]}}function l(t,e,r){return function(){return"undefined"!=typeof console&&"function"==typeof console.warn&&console.warn(e+" is deprecated, use "+r+" instead.",new Error("").stack),t.apply(t,arguments)}}function p(t){return t instanceof y?t:_(t)?I(t):k(t)}function f(){function t(t){e=t,o.source=t,K(r,function(e,r){p.nextTick(function(){t.promiseDispatch.apply(t,r)})},void 0),r=void 0,n=void 0}var e,r=[],n=[],i=tt(f.prototype),o=tt(y.prototype);if(o.promiseDispatch=function(t,i,o){var s=J(arguments);r?(r.push(s),"when"===i&&o[1]&&n.push(o[1])):p.nextTick(function(){e.promiseDispatch.apply(e,s)})},o.valueOf=function(){if(r)return o;var t=m(e);return w(t)&&(e=t),t},o.inspect=function(){return e?e.inspect():{state:"pending"}},p.longStackSupport&&W)try{throw new Error}catch(t){o.stack=t.stack.substring(t.stack.indexOf("\n")+1)}return i.promise=o,i.resolve=function(r){e||t(p(r))},i.fulfill=function(r){e||t(k(r))},i.reject=function(r){e||t(E(r))},i.notify=function(t){e||K(n,function(e,r){p.nextTick(function(){r(t)})},void 0)},i}function b(t){if("function"!=typeof t)throw new TypeError("resolver must be a function.");var e=f();try{t(e.resolve,e.reject,e.notify)}catch(t){e.reject(t)}return e.promise}function d(t){return b(function(e,r){for(var n=0,i=t.length;n=n)throw new TypeError}for(;r2?t.resolve(J(arguments,1)):t.resolve(r)}},p.Promise=b,p.promise=b,b.race=d,b.all=V,b.reject=E,b.resolve=p,p.passByCopy=function(t){return t},y.prototype.passByCopy=function(){return this},p.join=function(t,e){return p(t).join(e)},y.prototype.join=function(t){return p([this,t]).spread(function(t,e){if(t===e)return t;throw new Error("Can't join: not the same: "+t+" "+e)})},p.race=d,y.prototype.race=function(){return this.then(p.race)},p.makePromise=y,y.prototype.toString=function(){return"[object Promise]"},y.prototype.then=function(t,e,r){function n(e){try{return"function"==typeof t?t(e):e}catch(t){return E(t)}}function i(t){if("function"==typeof e){o(t,c);try{return e(t)}catch(t){return E(t)}}return E(t)}function s(t){return"function"==typeof r?r(t):t}var c=this,u=f(),a=!1;return p.nextTick(function(){c.promiseDispatch(function(t){a||(a=!0,u.resolve(n(t)))},"when",[function(t){a||(a=!0,u.resolve(i(t)))}])}),c.promiseDispatch(void 0,"when",[void 0,function(t){var e,r=!1;try{e=s(t)}catch(t){if(r=!0,!p.onerror)throw t;p.onerror(t)}r||u.notify(e)}]),u.promise},p.tap=function(t,e){return p(t).tap(e)},y.prototype.tap=function(t){return t=p(t),this.then(function(e){return t.fcall(e).thenResolve(e)})},p.when=v,y.prototype.thenResolve=function(t){return this.then(function(){return t})},p.thenResolve=function(t,e){return p(t).thenResolve(e)},y.prototype.thenReject=function(t){return this.then(function(){throw t})},p.thenReject=function(t,e){return p(t).thenReject(e)},p.nearer=m,p.isPromise=w,p.isPromiseAlike=_,p.isPending=x,y.prototype.isPending=function(){return"pending"===this.inspect().state},p.isFulfilled=O,y.prototype.isFulfilled=function(){return"fulfilled"===this.inspect().state},p.isRejected=S,y.prototype.isRejected=function(){return"rejected"===this.inspect().state};var ot=[],st=[],ct=[],ut=!0;p.resetUnhandledRejections=g,p.getUnhandledReasons=function(){return ot.slice()},p.stopUnhandledRejectionTracking=function(){g(),ut=!1},g(),p.reject=E,p.fulfill=k,p.master=A,p.spread=P,y.prototype.spread=function(t,e){return this.all().then(function(e){return t.apply(void 0,e)},e)},p.async=N,p.spawn=C,p.return=F,p.promised=R,p.dispatch=M,y.prototype.dispatch=function(t,e){var r=this,n=f();return p.nextTick(function(){r.promiseDispatch(n.resolve,t,e)}),n.promise},p.get=function(t,e){return p(t).dispatch("get",[e])},y.prototype.get=function(t){return this.dispatch("get",[t])},p.set=function(t,e,r){return p(t).dispatch("set",[e,r])},y.prototype.set=function(t,e){return this.dispatch("set",[t,e])},p.del=p.delete=function(t,e){return p(t).dispatch("delete",[e])},y.prototype.del=y.prototype.delete=function(t){return this.dispatch("delete",[t])},p.mapply=p.post=function(t,e,r){return p(t).dispatch("post",[e,r])},y.prototype.mapply=y.prototype.post=function(t,e){return this.dispatch("post",[t,e])},p.send=p.mcall=p.invoke=function(t,e){return p(t).dispatch("post",[e,J(arguments,2)])},y.prototype.send=y.prototype.mcall=y.prototype.invoke=function(t){return this.dispatch("post",[t,J(arguments,1)])},p.fapply=function(t,e){return p(t).dispatch("apply",[void 0,e])},y.prototype.fapply=function(t){return this.dispatch("apply",[void 0,t])},p.try=p.fcall=function(t){return p(t).dispatch("apply",[void 0,J(arguments,1)])},y.prototype.fcall=function(){return this.dispatch("apply",[void 0,J(arguments)])},p.fbind=function(t){var e=p(t),r=J(arguments,1);return function(){return e.dispatch("apply",[this,r.concat(J(arguments))])}},y.prototype.fbind=function(){var t=this,e=J(arguments);return function(){return t.dispatch("apply",[this,e.concat(J(arguments))])}},p.keys=function(t){return p(t).dispatch("keys",[])},y.prototype.keys=function(){return this.dispatch("keys",[])},p.all=V,y.prototype.all=function(){return V(this)},p.any=q,y.prototype.any=function(){return q(this)},p.allResolved=l(B,"allResolved","allSettled"),y.prototype.allResolved=function(){return B(this)},p.allSettled=L,y.prototype.allSettled=function(){return this.then(function(t){return V(Z(t,function(t){function e(){return t.inspect()}return t=p(t),t.then(e,e)}))})},p.fail=p.catch=function(t,e){return p(t).then(void 0,e)},y.prototype.fail=y.prototype.catch=function(t){return this.then(void 0,t)},p.progress=U,y.prototype.progress=function(t){return this.then(void 0,void 0,t)},p.fin=p.finally=function(t,e){return p(t).finally(e)},y.prototype.fin=y.prototype.finally=function(t){return t=p(t),this.then(function(e){return t.fcall().then(function(){return e})},function(e){return t.fcall().then(function(){throw e})})},p.done=function(t,e,r,n){return p(t).done(e,r,n)},y.prototype.done=function(t,r,n){var i=function(t){p.nextTick(function(){if(o(t,s),!p.onerror)throw t;p.onerror(t)})},s=t||r||n?this.then(t,r,n):this;"object"==typeof e&&e&&e.domain&&(i=e.domain.bind(i)),s.then(void 0,i)},p.timeout=function(t,e,r){return p(t).timeout(e,r)},y.prototype.timeout=function(t,e){var r=f(),n=setTimeout(function(){e&&"string"!=typeof e||(e=new Error(e||"Timed out after "+t+" ms"),e.code="ETIMEDOUT"),r.reject(e)},t);return this.then(function(t){clearTimeout(n),r.resolve(t)},function(t){clearTimeout(n),r.reject(t)},r.notify),r.promise},p.delay=function(t,e){return void 0===e&&(e=t,t=void 0),p(t).delay(e)},y.prototype.delay=function(t){return this.then(function(e){var r=f();return setTimeout(function(){r.resolve(e)},t),r.promise})},p.nfapply=function(t,e){return p(t).nfapply(e)},y.prototype.nfapply=function(t){var e=f(),r=J(t);return r.push(e.makeNodeResolver()),this.fapply(r).fail(e.reject),e.promise},p.nfcall=function(t){var e=J(arguments,1);return p(t).nfapply(e)},y.prototype.nfcall=function(){var t=J(arguments),e=f();return t.push(e.makeNodeResolver()),this.fapply(t).fail(e.reject),e.promise},p.nfbind=p.denodeify=function(t){var e=J(arguments,1);return function(){var r=e.concat(J(arguments)),n=f();return r.push(n.makeNodeResolver()),p(t).fapply(r).fail(n.reject),n.promise}},y.prototype.nfbind=y.prototype.denodeify=function(){var t=J(arguments);return t.unshift(this),p.denodeify.apply(void 0,t)},p.nbind=function(t,e){var r=J(arguments,2);return function(){function n(){return t.apply(e,arguments)}var i=r.concat(J(arguments)),o=f();return i.push(o.makeNodeResolver()),p(n).fapply(i).fail(o.reject),o.promise}},y.prototype.nbind=function(){var t=J(arguments,0);return t.unshift(this),p.nbind.apply(void 0,t)},p.nmapply=p.npost=function(t,e,r){return p(t).npost(e,r)},y.prototype.nmapply=y.prototype.npost=function(t,e){var r=J(e||[]),n=f();return r.push(n.makeNodeResolver()),this.dispatch("post",[t,r]).fail(n.reject),n.promise},p.nsend=p.nmcall=p.ninvoke=function(t,e){var r=J(arguments,2),n=f();return r.push(n.makeNodeResolver()),p(t).dispatch("post",[e,r]).fail(n.reject),n.promise},y.prototype.nsend=y.prototype.nmcall=y.prototype.ninvoke=function(t){var e=J(arguments,1),r=f();return e.push(r.makeNodeResolver()),this.dispatch("post",[t,e]).fail(r.reject),r.promise},p.nodeify=D,y.prototype.nodeify=function(t){return t?void this.then(function(e){p.nextTick(function(){t(null,e)})},function(e){p.nextTick(function(){t(e)})}):this},p.noConflict=function(){throw new Error("Q.noConflict only works when Q is used as a global")};var at=h();return p})}).call(e,r(38),r(19).setImmediate)},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(1),o=function(t){function e(e,r,n){t.call(this),this.parent=e,this.outerValue=r,this.outerIndex=n,this.index=0}return n(e,t),e.prototype._next=function(t){this.parent.notifyNext(this.outerValue,t,this.outerIndex,this.index++,this)},e.prototype._error=function(t){this.parent.notifyError(t,this),this.unsubscribe()},e.prototype._complete=function(){this.parent.notifyComplete(this),this.unsubscribe()},e}(i.Subscriber);e.InnerSubscriber=o},function(t,e){"use strict";var r=function(){function t(e,r){void 0===r&&(r=t.now),this.SchedulerAction=e,this.now=r}return t.prototype.schedule=function(t,e,r){return void 0===e&&(e=0),new this.SchedulerAction(this,t).schedule(r,e)},t.now=Date.now?Date.now:function(){return+new Date},t}();e.Scheduler=r},function(t,e,r){"use strict";var n=r(0),i=r(217);n.Observable.bindCallback=i.bindCallback},function(t,e,r){"use strict";var n=r(0),i=r(218);n.Observable.bindNodeCallback=i.bindNodeCallback},function(t,e,r){"use strict";var n=r(0),i=r(219);n.Observable.combineLatest=i.combineLatest},function(t,e,r){"use strict";var n=r(0),i=r(220);n.Observable.concat=i.concat},function(t,e,r){"use strict";var n=r(0),i=r(221);n.Observable.defer=i.defer},function(t,e,r){"use strict";var n=r(0),i=r(223);n.Observable.ajax=i.ajax},function(t,e,r){"use strict";var n=r(0),i=r(224);n.Observable.webSocket=i.webSocket},function(t,e,r){"use strict";var n=r(0),i=r(225);n.Observable.empty=i.empty},function(t,e,r){"use strict";var n=r(0),i=r(226);n.Observable.forkJoin=i.forkJoin},function(t,e,r){"use strict";var n=r(0),i=r(227);n.Observable.from=i.from},function(t,e,r){"use strict";var n=r(0),i=r(228);n.Observable.fromEvent=i.fromEvent},function(t,e,r){"use strict";var n=r(0),i=r(229);n.Observable.fromEventPattern=i.fromEventPattern},function(t,e,r){"use strict";var n=r(0),i=r(230);n.Observable.fromPromise=i.fromPromise},function(t,e,r){"use strict";var n=r(0),i=r(207);n.Observable.generate=i.GenerateObservable.create},function(t,e,r){"use strict";var n=r(0),i=r(231);n.Observable.if=i._if},function(t,e,r){"use strict";var n=r(0),i=r(232);n.Observable.interval=i.interval},function(t,e,r){"use strict";var n=r(0),i=r(233);n.Observable.merge=i.merge},function(t,e,r){"use strict";var n=r(0),i=r(234);n.Observable.never=i.never},function(t,e,r){"use strict";var n=r(0),i=r(235);n.Observable.of=i.of},function(t,e,r){"use strict";var n=r(0),i=r(52);n.Observable.onErrorResumeNext=i.onErrorResumeNextStatic},function(t,e,r){"use strict";var n=r(0),i=r(236);n.Observable.pairs=i.pairs},function(t,e,r){"use strict";var n=r(0),i=r(53);n.Observable.race=i.raceStatic},function(t,e,r){"use strict";var n=r(0),i=r(237);n.Observable.range=i.range},function(t,e,r){"use strict";var n=r(0),i=r(238);n.Observable.throw=i._throw},function(t,e,r){"use strict";var n=r(0),i=r(239);n.Observable.timer=i.timer},function(t,e,r){"use strict";var n=r(0),i=r(240);n.Observable.using=i.using},function(t,e,r){"use strict";var n=r(0),i=r(241);n.Observable.zip=i.zip},function(t,e,r){"use strict";var n=r(0),i=r(242);n.Observable.prototype.audit=i.audit},function(t,e,r){"use strict";var n=r(0),i=r(243);n.Observable.prototype.auditTime=i.auditTime},function(t,e,r){"use strict";var n=r(0),i=r(244);n.Observable.prototype.buffer=i.buffer},function(t,e,r){"use strict";var n=r(0),i=r(245);n.Observable.prototype.bufferCount=i.bufferCount},function(t,e,r){"use strict";var n=r(0),i=r(246);n.Observable.prototype.bufferTime=i.bufferTime},function(t,e,r){"use strict";var n=r(0),i=r(247);n.Observable.prototype.bufferToggle=i.bufferToggle},function(t,e,r){"use strict";var n=r(0),i=r(248);n.Observable.prototype.bufferWhen=i.bufferWhen},function(t,e,r){"use strict";var n=r(0),i=r(249);n.Observable.prototype.catch=i._catch,n.Observable.prototype._catch=i._catch},function(t,e,r){"use strict";var n=r(0),i=r(250);n.Observable.prototype.combineAll=i.combineAll},function(t,e,r){"use strict";var n=r(0),i=r(30);n.Observable.prototype.combineLatest=i.combineLatest},function(t,e,r){"use strict";var n=r(0),i=r(31);n.Observable.prototype.concat=i.concat},function(t,e,r){"use strict";var n=r(0),i=r(251);n.Observable.prototype.concatAll=i.concatAll},function(t,e,r){"use strict";var n=r(0),i=r(252);n.Observable.prototype.concatMap=i.concatMap},function(t,e,r){"use strict";var n=r(0),i=r(253);n.Observable.prototype.concatMapTo=i.concatMapTo},function(t,e,r){"use strict";var n=r(0),i=r(254);n.Observable.prototype.count=i.count},function(t,e,r){"use strict";var n=r(0),i=r(255);n.Observable.prototype.debounce=i.debounce},function(t,e,r){"use strict";var n=r(0),i=r(256);n.Observable.prototype.debounceTime=i.debounceTime},function(t,e,r){"use strict";var n=r(0),i=r(257);n.Observable.prototype.defaultIfEmpty=i.defaultIfEmpty},function(t,e,r){"use strict";var n=r(0),i=r(258);n.Observable.prototype.delay=i.delay},function(t,e,r){"use strict";var n=r(0),i=r(259);n.Observable.prototype.delayWhen=i.delayWhen},function(t,e,r){"use strict";var n=r(0),i=r(260);n.Observable.prototype.dematerialize=i.dematerialize},function(t,e,r){"use strict";var n=r(0),i=r(261);n.Observable.prototype.distinct=i.distinct},function(t,e,r){"use strict";var n=r(0),i=r(46);n.Observable.prototype.distinctUntilChanged=i.distinctUntilChanged},function(t,e,r){"use strict";var n=r(0),i=r(262);n.Observable.prototype.distinctUntilKeyChanged=i.distinctUntilKeyChanged},function(t,e,r){"use strict";var n=r(0),i=r(263);n.Observable.prototype.do=i._do,n.Observable.prototype._do=i._do},function(t,e,r){"use strict";var n=r(0),i=r(264);n.Observable.prototype.elementAt=i.elementAt},function(t,e,r){"use strict";var n=r(0),i=r(265);n.Observable.prototype.every=i.every},function(t,e,r){"use strict";var n=r(0),i=r(266);n.Observable.prototype.exhaust=i.exhaust},function(t,e,r){"use strict";var n=r(0),i=r(267);n.Observable.prototype.exhaustMap=i.exhaustMap},function(t,e,r){"use strict";var n=r(0),i=r(268);n.Observable.prototype.expand=i.expand},function(t,e,r){"use strict";var n=r(0),i=r(47);n.Observable.prototype.filter=i.filter},function(t,e,r){"use strict";var n=r(0),i=r(269);n.Observable.prototype.finally=i._finally,n.Observable.prototype._finally=i._finally},function(t,e,r){"use strict";var n=r(0),i=r(48);n.Observable.prototype.find=i.find},function(t,e,r){"use strict";var n=r(0),i=r(270);n.Observable.prototype.findIndex=i.findIndex},function(t,e,r){"use strict";var n=r(0),i=r(271);n.Observable.prototype.first=i.first},function(t,e,r){"use strict";var n=r(0),i=r(272);n.Observable.prototype.groupBy=i.groupBy},function(t,e,r){"use strict";var n=r(0),i=r(273);n.Observable.prototype.ignoreElements=i.ignoreElements},function(t,e,r){"use strict";var n=r(0),i=r(274);n.Observable.prototype.isEmpty=i.isEmpty},function(t,e,r){"use strict";var n=r(0),i=r(275);n.Observable.prototype.last=i.last},function(t,e,r){"use strict";var n=r(0),i=r(276);n.Observable.prototype.let=i.letProto,n.Observable.prototype.letBind=i.letProto},function(t,e,r){"use strict";var n=r(0),i=r(32);n.Observable.prototype.map=i.map},function(t,e,r){"use strict";var n=r(0),i=r(277);n.Observable.prototype.mapTo=i.mapTo},function(t,e,r){"use strict";var n=r(0),i=r(278);n.Observable.prototype.materialize=i.materialize},function(t,e,r){"use strict";var n=r(0),i=r(279);n.Observable.prototype.max=i.max},function(t,e,r){"use strict";var n=r(0),i=r(49);n.Observable.prototype.merge=i.merge},function(t,e,r){"use strict";var n=r(0),i=r(21);n.Observable.prototype.mergeAll=i.mergeAll},function(t,e,r){"use strict";var n=r(0),i=r(50);n.Observable.prototype.mergeMap=i.mergeMap,n.Observable.prototype.flatMap=i.mergeMap},function(t,e,r){"use strict";var n=r(0),i=r(51);n.Observable.prototype.flatMapTo=i.mergeMapTo,n.Observable.prototype.mergeMapTo=i.mergeMapTo},function(t,e,r){"use strict";var n=r(0),i=r(280);n.Observable.prototype.mergeScan=i.mergeScan},function(t,e,r){"use strict";var n=r(0),i=r(281);n.Observable.prototype.min=i.min},function(t,e,r){"use strict";var n=r(0),i=r(14);n.Observable.prototype.multicast=i.multicast},function(t,e,r){"use strict";var n=r(0),i=r(33);n.Observable.prototype.observeOn=i.observeOn},function(t,e,r){"use strict";var n=r(0),i=r(52);n.Observable.prototype.onErrorResumeNext=i.onErrorResumeNext},function(t,e,r){"use strict";var n=r(0),i=r(282);n.Observable.prototype.pairwise=i.pairwise},function(t,e,r){"use strict";var n=r(0),i=r(283);n.Observable.prototype.partition=i.partition},function(t,e,r){"use strict";var n=r(0),i=r(284);n.Observable.prototype.pluck=i.pluck},function(t,e,r){"use strict";var n=r(0),i=r(285);n.Observable.prototype.publish=i.publish},function(t,e,r){"use strict";var n=r(0),i=r(286);n.Observable.prototype.publishBehavior=i.publishBehavior},function(t,e,r){"use strict";var n=r(0),i=r(287);n.Observable.prototype.publishLast=i.publishLast},function(t,e,r){"use strict";var n=r(0),i=r(288);n.Observable.prototype.publishReplay=i.publishReplay},function(t,e,r){"use strict";var n=r(0),i=r(53);n.Observable.prototype.race=i.race},function(t,e,r){"use strict";var n=r(0),i=r(34);n.Observable.prototype.reduce=i.reduce},function(t,e,r){"use strict";var n=r(0),i=r(289);n.Observable.prototype.repeat=i.repeat},function(t,e,r){"use strict";var n=r(0),i=r(290);n.Observable.prototype.repeatWhen=i.repeatWhen},function(t,e,r){"use strict";var n=r(0),i=r(291);n.Observable.prototype.retry=i.retry},function(t,e,r){"use strict";var n=r(0),i=r(292);n.Observable.prototype.retryWhen=i.retryWhen},function(t,e,r){"use strict";var n=r(0),i=r(293);n.Observable.prototype.sample=i.sample},function(t,e,r){"use strict";var n=r(0),i=r(294);n.Observable.prototype.sampleTime=i.sampleTime},function(t,e,r){"use strict";var n=r(0),i=r(295);n.Observable.prototype.scan=i.scan},function(t,e,r){"use strict";var n=r(0),i=r(296);n.Observable.prototype.sequenceEqual=i.sequenceEqual},function(t,e,r){"use strict";var n=r(0),i=r(297);n.Observable.prototype.share=i.share},function(t,e,r){"use strict";var n=r(0),i=r(298);n.Observable.prototype.single=i.single},function(t,e,r){"use strict";var n=r(0),i=r(299);n.Observable.prototype.skip=i.skip},function(t,e,r){"use strict";var n=r(0),i=r(300);n.Observable.prototype.skipUntil=i.skipUntil},function(t,e,r){"use strict";var n=r(0),i=r(301);n.Observable.prototype.skipWhile=i.skipWhile},function(t,e,r){"use strict";var n=r(0),i=r(302);n.Observable.prototype.startWith=i.startWith},function(t,e,r){"use strict";var n=r(0),i=r(303);n.Observable.prototype.subscribeOn=i.subscribeOn},function(t,e,r){"use strict";var n=r(0),i=r(304);n.Observable.prototype.switch=i._switch,n.Observable.prototype._switch=i._switch},function(t,e,r){"use strict";var n=r(0),i=r(305);n.Observable.prototype.switchMap=i.switchMap},function(t,e,r){"use strict";var n=r(0),i=r(306);n.Observable.prototype.switchMapTo=i.switchMapTo},function(t,e,r){"use strict";var n=r(0),i=r(307);n.Observable.prototype.take=i.take},function(t,e,r){"use strict";var n=r(0),i=r(308);n.Observable.prototype.takeLast=i.takeLast},function(t,e,r){"use strict";var n=r(0),i=r(309);n.Observable.prototype.takeUntil=i.takeUntil},function(t,e,r){"use strict";var n=r(0),i=r(310);n.Observable.prototype.takeWhile=i.takeWhile},function(t,e,r){"use strict";var n=r(0),i=r(311);n.Observable.prototype.throttle=i.throttle},function(t,e,r){"use strict";var n=r(0),i=r(312);n.Observable.prototype.throttleTime=i.throttleTime},function(t,e,r){"use strict";var n=r(0),i=r(54);n.Observable.prototype.timeInterval=i.timeInterval},function(t,e,r){"use strict";var n=r(0),i=r(313);n.Observable.prototype.timeout=i.timeout},function(t,e,r){"use strict";var n=r(0),i=r(314);n.Observable.prototype.timeoutWith=i.timeoutWith},function(t,e,r){"use strict";var n=r(0),i=r(55);n.Observable.prototype.timestamp=i.timestamp},function(t,e,r){"use strict";var n=r(0),i=r(315);n.Observable.prototype.toArray=i.toArray},function(t,e,r){"use strict";var n=r(0),i=r(316);n.Observable.prototype.toPromise=i.toPromise},function(t,e,r){"use strict";var n=r(0),i=r(317);n.Observable.prototype.window=i.window},function(t,e,r){"use strict";var n=r(0),i=r(318);n.Observable.prototype.windowCount=i.windowCount},function(t,e,r){"use strict";var n=r(0),i=r(319);n.Observable.prototype.windowTime=i.windowTime},function(t,e,r){"use strict";var n=r(0),i=r(320);n.Observable.prototype.windowToggle=i.windowToggle},function(t,e,r){"use strict";var n=r(0),i=r(321);n.Observable.prototype.windowWhen=i.windowWhen},function(t,e,r){"use strict";var n=r(0),i=r(322);n.Observable.prototype.withLatestFrom=i.withLatestFrom},function(t,e,r){"use strict";var n=r(0),i=r(35);n.Observable.prototype.zip=i.zipProto},function(t,e,r){"use strict";var n=r(0),i=r(323);n.Observable.prototype.zipAll=i.zipAll},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(0),o=r(29),s=r(12),c=function(t){function e(e,r){t.call(this),this.arrayLike=e,this.scheduler=r,r||1!==e.length||(this._isScalar=!0,this.value=e[0])}return n(e,t),e.create=function(t,r){var n=t.length;return 0===n?new s.EmptyObservable:1===n?new o.ScalarObservable(t[0],r):new e(t,r)},e.dispatch=function(t){var e=t.arrayLike,r=t.index,n=t.length,i=t.subscriber;if(!i.closed){if(r>=n)return void i.complete();i.next(e[r]),t.index=r+1,this.schedule(t)}},e.prototype._subscribe=function(t){var r=0,n=this,i=n.arrayLike,o=n.scheduler,s=i.length;if(o)return o.schedule(e.dispatch,0,{arrayLike:i,index:r,length:s,subscriber:t});for(var c=0;cb?b:e):e}function o(t){return"number"==typeof t&&u.root.isFinite(t)}function s(t){var e=+t;return 0===e?e:isNaN(e)?e:e<0?-1:1}var c=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},u=r(7),a=r(0),h=r(18),l=function(t){function e(e,r){if(t.call(this),this.scheduler=r,null==e)throw new Error("iterator cannot be null.");this.iterator=n(e)}return c(e,t),e.create=function(t,r){return new e(t,r)},e.dispatch=function(t){var e=t.index,r=t.hasError,n=t.iterator,i=t.subscriber;if(r)return void i.error(t.error);var o=n.next();return o.done?void i.complete():(i.next(o.value),t.index=e+1,i.closed?void("function"==typeof n.return&&n.return()):void this.schedule(t))},e.prototype._subscribe=function(t){var r=0,n=this,i=n.iterator,o=n.scheduler;if(o)return o.schedule(e.dispatch,0,{index:r,iterator:i,subscriber:t});for(;;){var s=i.next();if(s.done){t.complete();break}if(t.next(s.value),t.closed){"function"==typeof i.return&&i.return();break}}},e}(a.Observable);e.IteratorObservable=l;var p=function(){function t(t,e,r){void 0===e&&(e=0),void 0===r&&(r=t.length),this.str=t,this.idx=e,this.len=r}return t.prototype[h.$$iterator]=function(){return this},t.prototype.next=function(){return this.idx=n?void i.complete():(i.next(e),void(i.closed||(t.index=r+1,t.start=e+1,this.schedule(t))))},e.prototype._subscribe=function(t){var r=0,n=this.start,i=this._count,o=this.scheduler;if(o)return o.schedule(e.dispatch,0,{index:r,count:i,start:n,subscriber:t});for(;;){if(r++>=i){t.complete();break}if(t.next(n++),t.closed)break}},e}(i.Observable);e.RangeObservable=o},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(0),o=r(57),s=r(37),c=function(t){function e(e,r,n){void 0===r&&(r=0),void 0===n&&(n=o.asap),t.call(this),this.source=e,this.delayTime=r,this.scheduler=n,(!s.isNumeric(r)||r<0)&&(this.delayTime=0),n&&"function"==typeof n.schedule||(this.scheduler=o.asap)}return n(e,t),e.create=function(t,r,n){return void 0===r&&(r=0),void 0===n&&(n=o.asap),new e(t,r,n)},e.dispatch=function(t){var e=t.source,r=t.subscriber;return e.subscribe(r)},e.prototype._subscribe=function(t){var r=this.delayTime,n=this.source,i=this.scheduler;return i.schedule(e.dispatch,r,{source:n,subscriber:t})},e}(i.Observable);e.SubscribeOnObservable=c},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(37),o=r(0),s=r(9),c=r(13),u=r(27),a=function(t){function e(e,r,n){void 0===e&&(e=0),t.call(this),this.period=-1,this.dueTime=0,i.isNumeric(r)?this.period=Number(r)<1&&1||Number(r):c.isScheduler(r)&&(n=r),c.isScheduler(n)||(n=s.async),this.scheduler=n,this.dueTime=u.isDate(e)?+e-this.scheduler.now():e}return n(e,t),e.create=function(t,r,n){return void 0===t&&(t=0),new e(t,r,n)},e.dispatch=function(t){var e=t.index,r=t.period,n=t.subscriber,i=this;if(n.next(e),!n.closed){if(r===-1)return n.complete();t.index=e+1,i.schedule(t,r)}},e.prototype._subscribe=function(t){var r=0,n=this,i=n.period,o=n.dueTime,s=n.scheduler;return s.schedule(e.dispatch,o,{index:r,period:i,subscriber:t})},e}(o.Observable);e.TimerObservable=a},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(0),o=r(3),s=r(2),c=function(t){function e(e,r){t.call(this),this.resourceFactory=e,this.observableFactory=r}return n(e,t),e.create=function(t,r){return new e(t,r)},e.prototype._subscribe=function(t){var e,r=this,n=r.resourceFactory,i=r.observableFactory;try{return e=n(),new u(t,e,i)}catch(e){t.error(e)}},e}(i.Observable);e.UsingObservable=c;var u=function(t){function e(e,r,n){t.call(this,e),this.resource=r,this.observableFactory=n,e.add(r),this.tryUse()}return n(e,t),e.prototype.tryUse=function(){try{var t=this.observableFactory.call(this,this.resource);t&&this.add(o.subscribeToResult(this,t))}catch(t){this._error(t)}},e}(s.OuterSubscriber)},function(t,e,r){"use strict";var n=r(200);e.bindCallback=n.BoundCallbackObservable.create},function(t,e,r){"use strict";var n=r(201);e.bindNodeCallback=n.BoundNodeCallbackObservable.create},function(t,e,r){"use strict";function n(){for(var t=[],e=0;e0;){var n=r.shift();n.length>0&&e.next(n)}t.prototype._complete.call(this)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t){var e=arguments.length,r=u.async;h.isScheduler(arguments[arguments.length-1])&&(r=arguments[arguments.length-1],e--);var n=null;e>=2&&(n=arguments[1]);var i=Number.POSITIVE_INFINITY;return e>=3&&(i=arguments[2]),this.lift(new l(t,n,i,r))}function i(t){var e=t.subscriber,r=t.context;r&&e.closeContext(r),e.closed||(t.context=e.openContext(),t.context.closeAction=this.schedule(t,t.bufferTimeSpan))}function o(t){var e=t.bufferCreationInterval,r=t.bufferTimeSpan,n=t.subscriber,i=t.scheduler,o=n.openContext(),c=this;n.closed||(n.add(o.closeAction=i.schedule(s,r,{subscriber:n,context:o})),c.schedule(t,e))}function s(t){var e=t.subscriber,r=t.context;e.closeContext(r)}var c=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},u=r(9),a=r(1),h=r(13);e.bufferTime=n;var l=function(){function t(t,e,r,n){this.bufferTimeSpan=t,this.bufferCreationInterval=e,this.maxBufferSize=r,this.scheduler=n}return t.prototype.call=function(t,e){return e._subscribe(new f(t,this.bufferTimeSpan,this.bufferCreationInterval,this.maxBufferSize,this.scheduler))},t}(),p=function(){function t(){this.buffer=[]}return t}(),f=function(t){function e(e,r,n,c,u){t.call(this,e),this.bufferTimeSpan=r,this.bufferCreationInterval=n,this.maxBufferSize=c,this.scheduler=u,this.contexts=[];var a=this.openContext();if(this.timespanOnly=null==n||n<0,this.timespanOnly){var h={subscriber:this,context:a,bufferTimeSpan:r};this.add(a.closeAction=u.schedule(i,r,h))}else{var l={subscriber:this,context:a},p={bufferTimeSpan:r,bufferCreationInterval:n,subscriber:this,scheduler:u};this.add(a.closeAction=u.schedule(s,r,l)),this.add(u.schedule(o,n,p))}}return c(e,t),e.prototype._next=function(t){for(var e,r=this.contexts,n=r.length,i=0;i0;){var i=r.shift();n.next(i.buffer)}t.prototype._complete.call(this)},e.prototype._unsubscribe=function(){this.contexts=null},e.prototype.onBufferFull=function(t){this.closeContext(t);var e=t.closeAction;if(e.unsubscribe(),this.remove(e),!this.closed&&this.timespanOnly){t=this.openContext();var r=this.bufferTimeSpan,n={subscriber:this,context:t,bufferTimeSpan:r};this.add(t.closeAction=this.scheduler.schedule(i,r,n))}},e.prototype.openContext=function(){var t=new p;return this.contexts.push(t),t},e.prototype.closeContext=function(t){this.destination.next(t.buffer);var e=this.contexts,r=e?e.indexOf(t):-1;r>=0&&e.splice(e.indexOf(t),1)},e}(a.Subscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new u(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(4),s=r(3),c=r(2);e.bufferToggle=n;var u=function(){function t(t,e){this.openings=t,this.closingSelector=e}return t.prototype.call=function(t,e){return e._subscribe(new a(t,this.openings,this.closingSelector))},t}(),a=function(t){function e(e,r,n){t.call(this,e),this.openings=r,this.closingSelector=n,this.contexts=[],this.add(s.subscribeToResult(this,r))}return i(e,t),e.prototype._next=function(t){for(var e=this.contexts,r=e.length,n=0;n0;){var n=r.shift();n.subscription.unsubscribe(),n.buffer=null,n.subscription=null}this.contexts=null,t.prototype._error.call(this,e)},e.prototype._complete=function(){for(var e=this.contexts;e.length>0;){var r=e.shift();this.destination.next(r.buffer),r.subscription.unsubscribe(),r.buffer=null,r.subscription=null}this.contexts=null,t.prototype._complete.call(this)},e.prototype.notifyNext=function(t,e,r,n,i){t?this.closeBuffer(t):this.openBuffer(e)},e.prototype.notifyComplete=function(t){this.closeBuffer(t.context)},e.prototype.openBuffer=function(t){try{var e=this.closingSelector,r=e.call(this,t);r&&this.trySubscribe(r)}catch(t){this._error(t)}},e.prototype.closeBuffer=function(t){var e=this.contexts;if(e&&t){var r=t.buffer,n=t.subscription;this.destination.next(r),e.splice(e.indexOf(t),1),this.remove(n),n.unsubscribe()}},e.prototype.trySubscribe=function(t){var e=this.contexts,r=[],n=new o.Subscription,i={buffer:r,subscription:n};e.push(i);var c=s.subscribeToResult(this,t,i);!c||c.closed?this.closeBuffer(i):(c.context=i,this.add(c),n.add(c))},e}(c.OuterSubscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new h(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(4),s=r(8),c=r(6),u=r(2),a=r(3);e.bufferWhen=n;var h=function(){function t(t){this.closingSelector=t}return t.prototype.call=function(t,e){return e._subscribe(new l(t,this.closingSelector))},t}(),l=function(t){function e(e,r){t.call(this,e),this.closingSelector=r,this.subscribing=!1,this.openBuffer()}return i(e,t),e.prototype._next=function(t){this.buffer.push(t)},e.prototype._complete=function(){var e=this.buffer;e&&this.destination.next(e),t.prototype._complete.call(this)},e.prototype._unsubscribe=function(){this.buffer=null,this.subscribing=!1},e.prototype.notifyNext=function(t,e,r,n,i){this.openBuffer()},e.prototype.notifyComplete=function(){this.subscribing?this.complete():this.openBuffer()},e.prototype.openBuffer=function(){var t=this.closingSubscription;t&&(this.remove(t),t.unsubscribe());var e=this.buffer;this.buffer&&this.destination.next(e),this.buffer=[];var r=s.tryCatch(this.closingSelector)();r===c.errorObject?this.error(c.errorObject.e):(t=new o.Subscription,this.closingSubscription=t,this.add(t),this.subscribing=!0,t.add(a.subscribeToResult(this,r)),this.subscribing=!1)},e}(u.OuterSubscriber)},function(t,e,r){"use strict";function n(t){var e=new c(t),r=this.lift(e);return e.caught=r}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype, new r)},o=r(2),s=r(3);e._catch=n;var c=function(){function t(t){this.selector=t}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.selector,this.caught))},t}(),u=function(t){function e(e,r,n){t.call(this,e),this.selector=r,this.caught=n}return i(e,t),e.prototype.error=function(t){if(!this.isStopped){var e=void 0;try{e=this.selector(t,this.caught)}catch(t){return void this.destination.error(t)}this.unsubscribe(),this.destination.remove(this),s.subscribeToResult(this,e)}},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new i.CombineLatestOperator(t))}var i=r(30);e.combineAll=n},function(t,e,r){"use strict";function n(){return this.lift(new i.MergeAllOperator(1))}var i=r(21);e.concatAll=n},function(t,e,r){"use strict";function n(t,e){return this.lift(new i.MergeMapOperator(t,e,1))}var i=r(50);e.concatMap=n},function(t,e,r){"use strict";function n(t,e){return this.lift(new i.MergeMapToOperator(t,e,1))}var i=r(51);e.concatMapTo=n},function(t,e,r){"use strict";function n(t){return this.lift(new s(t,this))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.count=n;var s=function(){function t(t,e){this.predicate=t,this.source=e}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.predicate,this.source))},t}(),c=function(t){function e(e,r,n){t.call(this,e),this.predicate=r,this.source=n,this.count=0,this.index=0}return i(e,t),e.prototype._next=function(t){this.predicate?this._tryPredicate(t):this.count++},e.prototype._tryPredicate=function(t){var e;try{e=this.predicate(t,this.index++,this.source)}catch(t){return void this.destination.error(t)}e&&this.count++},e.prototype._complete=function(){this.destination.next(this.count),this.destination.complete()},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new c(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.debounce=n;var c=function(){function t(t){this.durationSelector=t}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.durationSelector))},t}(),u=function(t){function e(e,r){t.call(this,e),this.durationSelector=r,this.hasValue=!1,this.durationSubscription=null}return i(e,t),e.prototype._next=function(t){try{var e=this.durationSelector.call(this,t);e&&this._tryNext(t,e)}catch(t){this.destination.error(t)}},e.prototype._complete=function(){this.emitValue(),this.destination.complete()},e.prototype._tryNext=function(t,e){var r=this.durationSubscription;this.value=t,this.hasValue=!0,r&&(r.unsubscribe(),this.remove(r)),r=s.subscribeToResult(this,e),r.closed||this.add(this.durationSubscription=r)},e.prototype.notifyNext=function(t,e,r,n,i){this.emitValue()},e.prototype.notifyComplete=function(){this.emitValue()},e.prototype.emitValue=function(){if(this.hasValue){var e=this.value,r=this.durationSubscription;r&&(this.durationSubscription=null,r.unsubscribe(),this.remove(r)),this.value=null,this.hasValue=!1,t.prototype._next.call(this,e)}},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t,e){return void 0===e&&(e=c.async),this.lift(new u(t,e))}function i(t){t.debouncedNext()}var o=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},s=r(1),c=r(9);e.debounceTime=n;var u=function(){function t(t,e){this.dueTime=t,this.scheduler=e}return t.prototype.call=function(t,e){return e._subscribe(new a(t,this.dueTime,this.scheduler))},t}(),a=function(t){function e(e,r,n){t.call(this,e),this.dueTime=r,this.scheduler=n,this.debouncedSubscription=null,this.lastValue=null,this.hasValue=!1}return o(e,t),e.prototype._next=function(t){this.clearDebounce(),this.lastValue=t,this.hasValue=!0,this.add(this.debouncedSubscription=this.scheduler.schedule(i,this.dueTime,this))},e.prototype._complete=function(){this.debouncedNext(),this.destination.complete()},e.prototype.debouncedNext=function(){this.clearDebounce(),this.hasValue&&(this.destination.next(this.lastValue),this.lastValue=null,this.hasValue=!1)},e.prototype.clearDebounce=function(){var t=this.debouncedSubscription;null!==t&&(this.remove(t),t.unsubscribe(),this.debouncedSubscription=null)},e}(s.Subscriber)},function(t,e,r){"use strict";function n(t){return void 0===t&&(t=null),this.lift(new s(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.defaultIfEmpty=n;var s=function(){function t(t){this.defaultValue=t}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.defaultValue))},t}(),c=function(t){function e(e,r){t.call(this,e),this.defaultValue=r,this.isEmpty=!0}return i(e,t),e.prototype._next=function(t){this.isEmpty=!1,this.destination.next(t)},e.prototype._complete=function(){this.isEmpty&&this.destination.next(this.defaultValue),this.destination.complete()},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e){void 0===e&&(e=o.async);var r=s.isDate(t),n=r?+t-e.now():Math.abs(t);return this.lift(new a(n,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(9),s=r(27),c=r(1),u=r(15);e.delay=n;var a=function(){function t(t,e){this.delay=t,this.scheduler=e}return t.prototype.call=function(t,e){return e._subscribe(new h(t,this.delay,this.scheduler))},t}(),h=function(t){function e(e,r,n){t.call(this,e),this.delay=r,this.scheduler=n,this.queue=[],this.active=!1,this.errored=!1}return i(e,t),e.dispatch=function(t){for(var e=t.source,r=e.queue,n=t.scheduler,i=t.destination;r.length>0&&r[0].time-n.now()<=0;)r.shift().notification.observe(i);if(r.length>0){var o=Math.max(0,r[0].time-n.now());this.schedule(t,o)}else e.active=!1},e.prototype._schedule=function(t){this.active=!0,this.add(t.schedule(e.dispatch,this.delay,{source:this,destination:this.destination,scheduler:t}))},e.prototype.scheduleNotification=function(t){if(this.errored!==!0){var e=this.scheduler,r=new l(e.now()+this.delay,t);this.queue.push(r),this.active===!1&&this._schedule(e)}},e.prototype._next=function(t){this.scheduleNotification(u.Notification.createNext(t))},e.prototype._error=function(t){this.errored=!0,this.queue=[],this.destination.error(t)},e.prototype._complete=function(){this.scheduleNotification(u.Notification.createComplete())},e}(c.Subscriber),l=function(){function t(t,e){this.time=t,this.notification=e}return t}()},function(t,e,r){"use strict";function n(t,e){return e?new l(this,e).lift(new a(t)):this.lift(new a(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(0),c=r(2),u=r(3);e.delayWhen=n;var a=function(){function t(t){this.delayDurationSelector=t}return t.prototype.call=function(t,e){return e._subscribe(new h(t,this.delayDurationSelector))},t}(),h=function(t){function e(e,r){t.call(this,e),this.delayDurationSelector=r,this.completed=!1,this.delayNotifierSubscriptions=[],this.values=[]}return i(e,t),e.prototype.notifyNext=function(t,e,r,n,i){this.destination.next(t),this.removeSubscription(i),this.tryComplete()},e.prototype.notifyError=function(t,e){this._error(t)},e.prototype.notifyComplete=function(t){var e=this.removeSubscription(t);e&&this.destination.next(e),this.tryComplete()},e.prototype._next=function(t){try{var e=this.delayDurationSelector(t);e&&this.tryDelay(e,t)}catch(t){this.destination.error(t)}},e.prototype._complete=function(){this.completed=!0,this.tryComplete()},e.prototype.removeSubscription=function(t){t.unsubscribe();var e=this.delayNotifierSubscriptions.indexOf(t),r=null;return e!==-1&&(r=this.values[e],this.delayNotifierSubscriptions.splice(e,1),this.values.splice(e,1)),r},e.prototype.tryDelay=function(t,e){var r=u.subscribeToResult(this,t,e);this.add(r),this.delayNotifierSubscriptions.push(r),this.values.push(e)},e.prototype.tryComplete=function(){this.completed&&0===this.delayNotifierSubscriptions.length&&this.destination.complete()},e}(c.OuterSubscriber),l=function(t){function e(e,r){t.call(this),this.source=e,this.subscriptionDelay=r}return i(e,t),e.prototype._subscribe=function(t){this.subscriptionDelay.subscribe(new p(t,this.source))},e}(s.Observable),p=function(t){function e(e,r){t.call(this),this.parent=e,this.source=r,this.sourceSubscribed=!1}return i(e,t),e.prototype._next=function(t){this.subscribeToSource()},e.prototype._error=function(t){this.unsubscribe(),this.parent.error(t)},e.prototype._complete=function(){this.subscribeToSource()},e.prototype.subscribeToSource=function(){this.sourceSubscribed||(this.sourceSubscribed=!0,this.unsubscribe(),this.source.subscribe(this.parent))},e}(o.Subscriber)},function(t,e,r){"use strict";function n(){return this.lift(new s)}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.dematerialize=n;var s=function(){function t(){}return t.prototype.call=function(t,e){return e._subscribe(new c(t))},t}(),c=function(t){function e(e){t.call(this,e)}return i(e,t),e.prototype._next=function(t){t.observe(this.destination)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new u(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3),c=r(340);e.distinct=n;var u=function(){function t(t,e){this.keySelector=t,this.flushes=e}return t.prototype.call=function(t,e){return e._subscribe(new a(t,this.keySelector,this.flushes))},t}(),a=function(t){function e(e,r,n){t.call(this,e),this.keySelector=r,this.values=new c.Set,n&&this.add(s.subscribeToResult(this,n))}return i(e,t),e.prototype.notifyNext=function(t,e,r,n,i){this.values.clear()},e.prototype.notifyError=function(t,e){this._error(t)},e.prototype._next=function(t){this.keySelector?this._useKeySelector(t):this._finalizeNext(t,t)},e.prototype._useKeySelector=function(t){var e,r=this.destination;try{e=this.keySelector(t)}catch(t){return void r.error(t)}this._finalizeNext(e,t)},e.prototype._finalizeNext=function(t,e){var r=this.values;r.has(t)||(r.add(t),this.destination.next(e))},e}(o.OuterSubscriber);e.DistinctSubscriber=a},function(t,e,r){"use strict";function n(t,e){return i.distinctUntilChanged.call(this,function(r,n){return e?e(r[t],n[t]):r[t]===n[t]})}var i=r(46);e.distinctUntilKeyChanged=n},function(t,e,r){"use strict";function n(t,e,r){return this.lift(new s(t,e,r))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e._do=n;var s=function(){function t(t,e,r){this.nextOrObserver=t,this.error=e,this.complete=r}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.nextOrObserver,this.error,this.complete))},t}(),c=function(t){function e(e,r,n,i){t.call(this,e);var s=new o.Subscriber(r,n,i);s.syncErrorThrowable=!0,this.add(s),this.safeSubscriber=s}return i(e,t),e.prototype._next=function(t){var e=this.safeSubscriber;e.next(t),e.syncErrorThrown?this.destination.error(e.syncErrorValue):this.destination.next(t)},e.prototype._error=function(t){var e=this.safeSubscriber;e.error(t),e.syncErrorThrown?this.destination.error(e.syncErrorValue):this.destination.error(t)},e.prototype._complete=function(){var t=this.safeSubscriber;t.complete(),t.syncErrorThrown?this.destination.error(t.syncErrorValue):this.destination.complete()},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new c(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(24);e.elementAt=n;var c=function(){function t(t,e){if(this.index=t,this.defaultValue=e,t<0)throw new s.ArgumentOutOfRangeError}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.index,this.defaultValue))},t}(),u=function(t){function e(e,r,n){t.call(this,e),this.index=r,this.defaultValue=n}return i(e,t),e.prototype._next=function(t){0===this.index--&&(this.destination.next(t),this.destination.complete())},e.prototype._complete=function(){var t=this.destination;this.index>=0&&("undefined"!=typeof this.defaultValue?t.next(this.defaultValue):t.error(new s.ArgumentOutOfRangeError)),t.complete()},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new s(t,e,this))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.every=n;var s=function(){function t(t,e,r){this.predicate=t,this.thisArg=e,this.source=r}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.predicate,this.thisArg,this.source))},t}(),c=function(t){function e(e,r,n,i){t.call(this,e),this.predicate=r,this.thisArg=n,this.source=i,this.index=0,this.thisArg=n||this}return i(e,t),e.prototype.notifyComplete=function(t){this.destination.next(t),this.destination.complete()},e.prototype._next=function(t){var e=!1;try{e=this.predicate.call(this.thisArg,t,this.index++,this.source)}catch(t){return void this.destination.error(t)}e||this.notifyComplete(!1)},e.prototype._complete=function(){this.notifyComplete(!0)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(){return this.lift(new c)}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.exhaust=n;var c=function(){function t(){}return t.prototype.call=function(t,e){return e._subscribe(new u(t))},t}(),u=function(t){function e(e){t.call(this,e),this.hasCompleted=!1,this.hasSubscription=!1}return i(e,t),e.prototype._next=function(t){this.hasSubscription||(this.hasSubscription=!0,this.add(s.subscribeToResult(this,t)))},e.prototype._complete=function(){this.hasCompleted=!0,this.hasSubscription||this.destination.complete()},e.prototype.notifyComplete=function(t){this.remove(t),this.hasSubscription=!1,this.hasCompleted&&this.destination.complete()},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new c(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.exhaustMap=n;var c=function(){function t(t,e){this.project=t,this.resultSelector=e}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.project,this.resultSelector))},t}(),u=function(t){function e(e,r,n){t.call(this,e),this.project=r,this.resultSelector=n,this.hasSubscription=!1,this.hasCompleted=!1,this.index=0}return i(e,t),e.prototype._next=function(t){this.hasSubscription||this.tryNext(t)},e.prototype.tryNext=function(t){var e=this.index++,r=this.destination;try{var n=this.project(t,e);this.hasSubscription=!0,this.add(s.subscribeToResult(this,n,t,e))}catch(t){r.error(t)}},e.prototype._complete=function(){this.hasCompleted=!0,this.hasSubscription||this.destination.complete()},e.prototype.notifyNext=function(t,e,r,n,i){var o=this,s=o.resultSelector,c=o.destination;s?this.trySelectResult(t,e,r,n):c.next(e)},e.prototype.trySelectResult=function(t,e,r,n){var i=this,o=i.resultSelector,s=i.destination;try{var c=o(t,e,r,n);s.next(c)}catch(t){s.error(t)}},e.prototype.notifyError=function(t){this.destination.error(t)},e.prototype.notifyComplete=function(t){this.remove(t),this.hasSubscription=!1,this.hasCompleted&&this.destination.complete()},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t,e,r){return void 0===e&&(e=Number.POSITIVE_INFINITY),void 0===r&&(r=void 0),e=(e||0)<1?Number.POSITIVE_INFINITY:e,this.lift(new a(t,e,r))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(8),s=r(6),c=r(2),u=r(3);e.expand=n;var a=function(){function t(t,e,r){this.project=t,this.concurrent=e,this.scheduler=r}return t.prototype.call=function(t,e){return e._subscribe(new h(t,this.project,this.concurrent,this.scheduler))},t}();e.ExpandOperator=a;var h=function(t){function e(e,r,n,i){t.call(this,e),this.project=r,this.concurrent=n,this.scheduler=i,this.index=0,this.active=0,this.hasCompleted=!1,n0&&this._next(e.shift()),this.hasCompleted&&0===this.active&&this.destination.complete()},e}(c.OuterSubscriber);e.ExpandSubscriber=h},function(t,e,r){"use strict";function n(t){return this.lift(new c(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(4);e._finally=n;var c=function(){function t(t){this.callback=t}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.callback))},t}(),u=function(t){function e(e,r){t.call(this,e),this.add(new s.Subscription(r))}return i(e,t),e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new i.FindValueOperator(t,this,!0,e))}var i=r(48);e.findIndex=n},function(t,e,r){"use strict";function n(t,e,r){return this.lift(new c(t,e,r,this))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(25);e.first=n;var c=function(){function t(t,e,r,n){this.predicate=t,this.resultSelector=e,this.defaultValue=r,this.source=n}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.predicate,this.resultSelector,this.defaultValue,this.source))},t}(),u=function(t){function e(e,r,n,i,o){t.call(this,e),this.predicate=r,this.resultSelector=n,this.defaultValue=i,this.source=o,this.index=0,this.hasCompleted=!1,this._emitted=!1}return i(e,t),e.prototype._next=function(t){var e=this.index++;this.predicate?this._tryPredicate(t,e):this._emit(t,e)},e.prototype._tryPredicate=function(t,e){var r;try{r=this.predicate(t,e,this.source)}catch(t){return void this.destination.error(t)}r&&this._emit(t,e)},e.prototype._emit=function(t,e){return this.resultSelector?void this._tryResultSelector(t,e):void this._emitFinal(t)},e.prototype._tryResultSelector=function(t,e){var r;try{r=this.resultSelector(t,e)}catch(t){return void this.destination.error(t)}this._emitFinal(r)},e.prototype._emitFinal=function(t){var e=this.destination;this._emitted||(this._emitted=!0,e.next(t),e.complete(),this.hasCompleted=!0)},e.prototype._complete=function(){var t=this.destination;this.hasCompleted||"undefined"==typeof this.defaultValue?this.hasCompleted||t.error(new s.EmptyError):(t.next(this.defaultValue),t.complete())},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e,r,n){return this.lift(new l(t,e,r,n))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(4),c=r(0),u=r(5),a=r(338),h=r(336);e.groupBy=n;var l=function(){function t(t,e,r,n){this.keySelector=t,this.elementSelector=e,this.durationSelector=r,this.subjectSelector=n}return t.prototype.call=function(t,e){return e._subscribe(new p(t,this.keySelector,this.elementSelector,this.durationSelector,this.subjectSelector))},t}(),p=function(t){function e(e,r,n,i,o){t.call(this,e),this.keySelector=r,this.elementSelector=n,this.durationSelector=i,this.subjectSelector=o,this.groups=null,this.attemptedToUnsubscribe=!1,this.count=0}return i(e,t),e.prototype._next=function(t){var e;try{e=this.keySelector(t)}catch(t){return void this.error(t)}this._group(t,e)},e.prototype._group=function(t,e){var r=this.groups;r||(r=this.groups="string"==typeof e?new h.FastMap:new a.Map);var n,i=r.get(e);if(this.elementSelector)try{n=this.elementSelector(t)}catch(t){this.error(t)}else n=t;if(!i){i=this.subjectSelector?this.subjectSelector():new u.Subject,r.set(e,i);var o=new b(e,i,this);if(this.destination.next(o),this.durationSelector){var s=void 0;try{s=this.durationSelector(new b(e,i))}catch(t){return void this.error(t)}this.add(s.subscribe(new f(e,i,this)))}}i.closed||i.next(n)},e.prototype._error=function(t){var e=this.groups;e&&(e.forEach(function(e,r){e.error(t)}),e.clear()),this.destination.error(t)},e.prototype._complete=function(){var t=this.groups;t&&(t.forEach(function(t,e){t.complete()}),t.clear()),this.destination.complete()},e.prototype.removeGroup=function(t){this.groups.delete(t)},e.prototype.unsubscribe=function(){this.closed||this.attemptedToUnsubscribe||(this.attemptedToUnsubscribe=!0,0===this.count&&t.prototype.unsubscribe.call(this))},e}(o.Subscriber),f=function(t){function e(e,r,n){t.call(this),this.key=e,this.group=r,this.parent=n}return i(e,t),e.prototype._next=function(t){this._complete()},e.prototype._error=function(t){var e=this.group;e.closed||e.error(t),this.parent.removeGroup(this.key)},e.prototype._complete=function(){var t=this.group;t.closed||t.complete(),this.parent.removeGroup(this.key)},e}(o.Subscriber),b=function(t){function e(e,r,n){t.call(this),this.key=e,this.groupSubject=r,this.refCountSubscription=n}return i(e,t),e.prototype._subscribe=function(t){var e=new s.Subscription,r=this,n=r.refCountSubscription,i=r.groupSubject;return n&&!n.closed&&e.add(new d(n)),e.add(i.subscribe(t)),e},e}(c.Observable);e.GroupedObservable=b;var d=function(t){function e(e){t.call(this),this.parent=e,e.count++}return i(e,t),e.prototype.unsubscribe=function(){var e=this.parent;e.closed||this.closed||(t.prototype.unsubscribe.call(this),e.count-=1,0===e.count&&e.attemptedToUnsubscribe&&e.unsubscribe())},e}(s.Subscription)},function(t,e,r){"use strict";function n(){return this.lift(new c)}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(65);e.ignoreElements=n;var c=function(){function t(){}return t.prototype.call=function(t,e){return e._subscribe(new u(t))},t}(),u=function(t){function e(){t.apply(this,arguments)}return i(e,t),e.prototype._next=function(t){s.noop()},e}(o.Subscriber)},function(t,e,r){"use strict";function n(){return this.lift(new s)}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.isEmpty=n;var s=function(){function t(){}return t.prototype.call=function(t,e){return e._subscribe(new c(t))},t}(),c=function(t){function e(e){t.call(this,e)}return i(e,t),e.prototype.notifyComplete=function(t){var e=this.destination;e.next(t),e.complete()},e.prototype._next=function(t){this.notifyComplete(!1)},e.prototype._complete=function(){this.notifyComplete(!0)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e,r){return this.lift(new c(t,e,r,this))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(25);e.last=n;var c=function(){function t(t,e,r,n){this.predicate=t,this.resultSelector=e,this.defaultValue=r,this.source=n}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.predicate,this.resultSelector,this.defaultValue,this.source))},t}(),u=function(t){function e(e,r,n,i,o){t.call(this,e),this.predicate=r,this.resultSelector=n,this.defaultValue=i,this.source=o,this.hasValue=!1,this.index=0,"undefined"!=typeof i&&(this.lastValue=i,this.hasValue=!0)}return i(e,t),e.prototype._next=function(t){var e=this.index++;if(this.predicate)this._tryPredicate(t,e);else{if(this.resultSelector)return void this._tryResultSelector(t,e);this.lastValue=t,this.hasValue=!0}},e.prototype._tryPredicate=function(t,e){var r;try{r=this.predicate(t,e,this.source)}catch(t){return void this.destination.error(t)}if(r){if(this.resultSelector)return void this._tryResultSelector(t,e);this.lastValue=t,this.hasValue=!0}},e.prototype._tryResultSelector=function(t,e){var r;try{r=this.resultSelector(t,e)}catch(t){return void this.destination.error(t)}this.lastValue=r,this.hasValue=!0},e.prototype._complete=function(){var t=this.destination;this.hasValue?(t.next(this.lastValue),t.complete()):t.error(new s.EmptyError)},e}(o.Subscriber)},function(t,e){"use strict";function r(t){return t(this)}e.letProto=r},function(t,e,r){"use strict";function n(t){return this.lift(new s(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.mapTo=n;var s=function(){function t(t){this.value=t}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.value))},t}(),c=function(t){function e(e,r){t.call(this,e),this.value=r}return i(e,t),e.prototype._next=function(t){this.destination.next(this.value)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(){return this.lift(new c)}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(15);e.materialize=n;var c=function(){function t(){}return t.prototype.call=function(t,e){return e._subscribe(new u(t))},t}(),u=function(t){function e(e){t.call(this,e)}return i(e,t),e.prototype._next=function(t){this.destination.next(s.Notification.createNext(t))},e.prototype._error=function(t){var e=this.destination;e.next(s.Notification.createError(t)),e.complete()},e.prototype._complete=function(){var t=this.destination;t.next(s.Notification.createComplete()),t.complete()},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t){var e="function"==typeof t?function(e,r){return t(e,r)>0?e:r}:function(t,e){return t>e?t:e};return this.lift(new i.ReduceOperator(e))}var i=r(34);e.max=n},function(t,e,r){"use strict";function n(t,e,r){return void 0===r&&(r=Number.POSITIVE_INFINITY),this.lift(new a(t,e,r))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(8),s=r(6),c=r(3),u=r(2);e.mergeScan=n;var a=function(){function t(t,e,r){this.project=t,this.seed=e,this.concurrent=r}return t.prototype.call=function(t,e){return e._subscribe(new h(t,this.project,this.seed,this.concurrent))},t}();e.MergeScanOperator=a;var h=function(t){function e(e,r,n,i){t.call(this,e),this.project=r,this.acc=n,this.concurrent=i,this.hasValue=!1,this.hasCompleted=!1,this.buffer=[],this.active=0,this.index=0}return i(e,t),e.prototype._next=function(t){if(this.active0?this._next(e.shift()):0===this.active&&this.hasCompleted&&(this.hasValue===!1&&this.destination.next(this.acc),this.destination.complete())},e}(u.OuterSubscriber);e.MergeScanSubscriber=h},function(t,e,r){"use strict";function n(t){var e="function"==typeof t?function(e,r){return t(e,r)<0?e:r}:function(t,e){return t-1&&(this.count=n-1),this.unsubscribe(),this.isStopped=!1,this.closed=!1,r.subscribe(this)}},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new h(t,this))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(5),s=r(8),c=r(6),u=r(2),a=r(3);e.repeatWhen=n;var h=function(){function t(t,e){this.notifier=t,this.source=e}return t.prototype.call=function(t,e){return e._subscribe(new l(t,this.notifier,this.source))},t}(),l=function(t){function e(e,r,n){t.call(this,e),this.notifier=r,this.source=n}return i(e,t),e.prototype.complete=function(){if(!this.isStopped){var e=this.notifications,r=this.retries,n=this.retriesSubscription;if(r)this.notifications=null,this.retriesSubscription=null;else{if(e=new o.Subject,r=s.tryCatch(this.notifier)(e),r===c.errorObject)return t.prototype.complete.call(this);n=a.subscribeToResult(this,r)}this.unsubscribe(),this.closed=!1,this.notifications=e,this.retries=r,this.retriesSubscription=n,e.next()}},e.prototype._unsubscribe=function(){var t=this,e=t.notifications,r=t.retriesSubscription;e&&(e.unsubscribe(),this.notifications=null),r&&(r.unsubscribe(),this.retriesSubscription=null),this.retries=null},e.prototype.notifyNext=function(t,e,r,n,i){var o=this,s=o.notifications,c=o.retries,u=o.retriesSubscription;this.notifications=null,this.retries=null,this.retriesSubscription=null,this.unsubscribe(),this.isStopped=!1,this.closed=!1,this.notifications=s,this.retries=c,this.retriesSubscription=u,this.source.subscribe(this)},e}(u.OuterSubscriber)},function(t,e,r){"use strict";function n(t){return void 0===t&&(t=-1),this.lift(new s(t,this))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.retry=n;var s=function(){function t(t,e){this.count=t,this.source=e}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.count,this.source))},t}(),c=function(t){function e(e,r,n){t.call(this,e),this.count=r,this.source=n}return i(e,t),e.prototype.error=function(e){if(!this.isStopped){var r=this,n=r.source,i=r.count;if(0===i)return t.prototype.error.call(this,e);i>-1&&(this.count=i-1),this.unsubscribe(),this.isStopped=!1,this.closed=!1,n.subscribe(this)}},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new h(t,this))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(5),s=r(8),c=r(6),u=r(2),a=r(3);e.retryWhen=n;var h=function(){function t(t,e){this.notifier=t,this.source=e}return t.prototype.call=function(t,e){return e._subscribe(new l(t,this.notifier,this.source))},t}(),l=function(t){function e(e,r,n){t.call(this,e),this.notifier=r,this.source=n}return i(e,t),e.prototype.error=function(e){if(!this.isStopped){var r=this.errors,n=this.retries,i=this.retriesSubscription;if(n)this.errors=null,this.retriesSubscription=null;else{if(r=new o.Subject,n=s.tryCatch(this.notifier)(r),n===c.errorObject)return t.prototype.error.call(this,c.errorObject.e);i=a.subscribeToResult(this,n)}this.unsubscribe(),this.closed=!1,this.errors=r,this.retries=n,this.retriesSubscription=i,r.next(e)}},e.prototype._unsubscribe=function(){var t=this,e=t.errors,r=t.retriesSubscription;e&&(e.unsubscribe(),this.errors=null),r&&(r.unsubscribe(),this.retriesSubscription=null),this.retries=null},e.prototype.notifyNext=function(t,e,r,n,i){var o=this,s=o.errors,c=o.retries,u=o.retriesSubscription;this.errors=null,this.retries=null,this.retriesSubscription=null,this.unsubscribe(),this.isStopped=!1,this.closed=!1,this.errors=s,this.retries=c,this.retriesSubscription=u,this.source.subscribe(this)},e}(u.OuterSubscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new c(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.sample=n;var c=function(){function t(t){this.notifier=t}return t.prototype.call=function(t,e){var r=new u(t),n=e._subscribe(r);return n.add(s.subscribeToResult(r,this.notifier)),n},t}(),u=function(t){function e(){t.apply(this,arguments),this.hasValue=!1}return i(e,t),e.prototype._next=function(t){this.value=t,this.hasValue=!0},e.prototype.notifyNext=function(t,e,r,n,i){this.emitValue()},e.prototype.notifyComplete=function(){this.emitValue()},e.prototype.emitValue=function(){this.hasValue&&(this.hasValue=!1,this.destination.next(this.value))},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t,e){return void 0===e&&(e=c.async),this.lift(new u(t,e))}function i(t){var e=t.subscriber,r=t.period;e.notifyNext(),this.schedule(t,r)}var o=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},s=r(1),c=r(9);e.sampleTime=n;var u=function(){function t(t,e){this.period=t,this.scheduler=e}return t.prototype.call=function(t,e){return e._subscribe(new a(t,this.period,this.scheduler))},t}(),a=function(t){function e(e,r,n){t.call(this,e),this.period=r,this.scheduler=n,this.hasValue=!1,this.add(n.schedule(i,r,{subscriber:this,period:r}))}return o(e,t),e.prototype._next=function(t){this.lastValue=t,this.hasValue=!0},e.prototype.notifyNext=function(){this.hasValue&&(this.hasValue=!1,this.destination.next(this.lastValue))},e}(s.Subscriber)},function(t,e,r){"use strict";function n(t,e){var r=!1;return arguments.length>=2&&(r=!0),this.lift(new s(t,e,r))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.scan=n;var s=function(){function t(t,e,r){void 0===r&&(r=!1),this.accumulator=t,this.seed=e,this.hasSeed=r}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.accumulator,this.seed,this.hasSeed))},t}(),c=function(t){function e(e,r,n,i){t.call(this,e),this.accumulator=r,this._seed=n,this.hasSeed=i,this.index=0}return i(e,t),Object.defineProperty(e.prototype,"seed",{get:function(){return this._seed},set:function(t){this.hasSeed=!0,this._seed=t},enumerable:!0,configurable:!0}),e.prototype._next=function(t){return this.hasSeed?this._tryNext(t):(this.seed=t,void this.destination.next(t))},e.prototype._tryNext=function(t){var e,r=this.index++;try{e=this.accumulator(this.seed,t,r)}catch(t){this.destination.error(t)}this.seed=e,this.destination.next(e)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new u(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(8),c=r(6);e.sequenceEqual=n;var u=function(){function t(t,e){this.compareTo=t,this.comparor=e}return t.prototype.call=function(t,e){return e._subscribe(new a(t,this.compareTo,this.comparor))},t}();e.SequenceEqualOperator=u;var a=function(t){function e(e,r,n){t.call(this,e),this.compareTo=r,this.comparor=n,this._a=[],this._b=[],this._oneComplete=!1,this.add(r.subscribe(new h(e,this)))}return i(e,t),e.prototype._next=function(t){this._oneComplete&&0===this._b.length?this.emit(!1):(this._a.push(t),this.checkValues())},e.prototype._complete=function(){this._oneComplete?this.emit(0===this._a.length&&0===this._b.length):this._oneComplete=!0},e.prototype.checkValues=function(){for(var t=this,e=t._a,r=t._b,n=t.comparor;e.length>0&&r.length>0;){var i=e.shift(),o=r.shift(),u=!1;n?(u=s.tryCatch(n)(i,o),u===c.errorObject&&this.destination.error(c.errorObject.e)):u=i===o,u||this.emit(!1)}},e.prototype.emit=function(t){var e=this.destination;e.next(t),e.complete()},e.prototype.nextB=function(t){this._oneComplete&&0===this._a.length?this.emit(!1):(this._b.push(t),this.checkValues())},e}(o.Subscriber);e.SequenceEqualSubscriber=a;var h=function(t){function e(e,r){t.call(this,e),this.parent=r}return i(e,t),e.prototype._next=function(t){this.parent.nextB(t)},e.prototype._error=function(t){this.parent.error(t)},e.prototype._complete=function(){this.parent._complete()},e}(o.Subscriber)},function(t,e,r){"use strict";function n(){return new s.Subject}function i(){return o.multicast.call(this,n).refCount()}var o=r(14),s=r(5);e.share=i},function(t,e,r){"use strict";function n(t){return this.lift(new c(t,this))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(25);e.single=n;var c=function(){function t(t,e){this.predicate=t,this.source=e}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.predicate,this.source))},t}(),u=function(t){function e(e,r,n){t.call(this,e),this.predicate=r,this.source=n,this.seenValue=!1,this.index=0}return i(e,t),e.prototype.applySingleValue=function(t){this.seenValue?this.destination.error("Sequence contains more than one element"):(this.seenValue=!0,this.singleValue=t)},e.prototype._next=function(t){var e=this.predicate;this.index++,e?this.tryNext(t):this.applySingleValue(t)},e.prototype.tryNext=function(t){try{var e=this.predicate(t,this.index,this.source);e&&this.applySingleValue(t)}catch(t){this.destination.error(t)}},e.prototype._complete=function(){var t=this.destination;this.index>0?(t.next(this.seenValue?this.singleValue:void 0),t.complete()):t.error(new s.EmptyError)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new s(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.skip=n;var s=function(){function t(t){this.total=t}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.total))},t}(),c=function(t){function e(e,r){t.call(this,e),this.total=r,this.count=0}return i(e,t),e.prototype._next=function(t){++this.count>this.total&&this.destination.next(t)},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new c(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.skipUntil=n;var c=function(){function t(t){this.notifier=t}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.notifier))},t}(),u=function(t){function e(e,r){t.call(this,e),this.hasValue=!1,this.isInnerStopped=!1,this.add(s.subscribeToResult(this,r))}return i(e,t),e.prototype._next=function(e){this.hasValue&&t.prototype._next.call(this,e)},e.prototype._complete=function(){this.isInnerStopped?t.prototype._complete.call(this):this.unsubscribe()},e.prototype.notifyNext=function(t,e,r,n,i){this.hasValue=!0},e.prototype.notifyComplete=function(){this.isInnerStopped=!0,this.isStopped&&t.prototype._complete.call(this)},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new s(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1);e.skipWhile=n;var s=function(){function t(t){this.predicate=t}return t.prototype.call=function(t,e){return e._subscribe(new c(t,this.predicate))},t}(),c=function(t){function e(e,r){t.call(this,e),this.predicate=r,this.skipping=!0,this.index=0}return i(e,t),e.prototype._next=function(t){var e=this.destination;this.skipping&&this.tryCallPredicate(t),this.skipping||e.next(t)},e.prototype.tryCallPredicate=function(t){try{var e=this.predicate(t,this.index++);this.skipping=Boolean(e)}catch(t){this.destination.error(t)}},e}(o.Subscriber)},function(t,e,r){"use strict";function n(){for(var t=[],e=0;e1?c.concatStatic(new i.ArrayObservable(t,r),this):c.concatStatic(new s.EmptyObservable(r),this)}var i=r(11),o=r(29),s=r(12),c=r(31),u=r(13);e.startWith=n},function(t,e,r){"use strict";function n(t,e){return void 0===e&&(e=0),new i.SubscribeOnObservable(this,e,t)}var i=r(214);e.subscribeOn=n},function(t,e,r){"use strict";function n(){return this.lift(new c)}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e._switch=n;var c=function(){function t(){}return t.prototype.call=function(t,e){return e._subscribe(new u(t))},t}(),u=function(t){function e(e){t.call(this,e),this.active=0,this.hasCompleted=!1}return i(e,t),e.prototype._next=function(t){this.unsubscribeInner(),this.active++,this.add(this.innerSubscription=s.subscribeToResult(this,t))},e.prototype._complete=function(){this.hasCompleted=!0,0===this.active&&this.destination.complete()},e.prototype.unsubscribeInner=function(){this.active=this.active>0?this.active-1:0;var t=this.innerSubscription;t&&(t.unsubscribe(),this.remove(t))},e.prototype.notifyNext=function(t,e,r,n,i){this.destination.next(e)},e.prototype.notifyError=function(t){this.destination.error(t)},e.prototype.notifyComplete=function(){this.unsubscribeInner(),this.hasCompleted&&0===this.active&&this.destination.complete()},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new c(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.switchMap=n;var c=function(){function t(t,e){this.project=t,this.resultSelector=e}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.project,this.resultSelector))},t}(),u=function(t){function e(e,r,n){t.call(this,e),this.project=r,this.resultSelector=n,this.index=0}return i(e,t),e.prototype._next=function(t){var e,r=this.index++;try{e=this.project(t,r)}catch(t){return void this.destination.error(t)}this._innerSub(e,t,r)},e.prototype._innerSub=function(t,e,r){var n=this.innerSubscription;n&&n.unsubscribe(),this.add(this.innerSubscription=s.subscribeToResult(this,t,e,r))},e.prototype._complete=function(){var e=this.innerSubscription;e&&!e.closed||t.prototype._complete.call(this)},e.prototype._unsubscribe=function(){this.innerSubscription=null},e.prototype.notifyComplete=function(e){this.remove(e),this.innerSubscription=null,this.isStopped&&t.prototype._complete.call(this)},e.prototype.notifyNext=function(t,e,r,n,i){this.resultSelector?this._tryNotifyNext(t,e,r,n):this.destination.next(e)},e.prototype._tryNotifyNext=function(t,e,r,n){var i;try{i=this.resultSelector(t,e,r,n)}catch(t){return void this.destination.error(t)}this.destination.next(i)},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new c(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(2),s=r(3);e.switchMapTo=n;var c=function(){function t(t,e){this.observable=t,this.resultSelector=e}return t.prototype.call=function(t,e){return e._subscribe(new u(t,this.observable,this.resultSelector))},t}(),u=function(t){function e(e,r,n){t.call(this,e),this.inner=r,this.resultSelector=n,this.index=0}return i(e,t),e.prototype._next=function(t){var e=this.innerSubscription;e&&e.unsubscribe(),this.add(this.innerSubscription=s.subscribeToResult(this,this.inner,t,this.index++))},e.prototype._complete=function(){var e=this.innerSubscription;e&&!e.closed||t.prototype._complete.call(this)},e.prototype._unsubscribe=function(){this.innerSubscription=null},e.prototype.notifyComplete=function(e){this.remove(e),this.innerSubscription=null,this.isStopped&&t.prototype._complete.call(this)},e.prototype.notifyNext=function(t,e,r,n,i){var o=this,s=o.resultSelector,c=o.destination;s?this.tryResultSelector(t,e,r,n):c.next(e)},e.prototype.tryResultSelector=function(t,e,r,n){var i,o=this,s=o.resultSelector,c=o.destination;try{i=s(t,e,r,n)}catch(t){return void c.error(t)}c.next(i)},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t){return 0===t?new c.EmptyObservable:this.lift(new u(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(24),c=r(12);e.take=n;var u=function(){function t(t){if(this.total=t,this.total<0)throw new s.ArgumentOutOfRangeError}return t.prototype.call=function(t,e){return e._subscribe(new a(t,this.total))},t}(),a=function(t){function e(e,r){t.call(this,e),this.total=r,this.count=0}return i(e,t),e.prototype._next=function(t){var e=this.total,r=++this.count;r<=e&&(this.destination.next(t),r===e&&(this.destination.complete(),this.unsubscribe()))},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t){return 0===t?new c.EmptyObservable:this.lift(new u(t))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(1),s=r(24),c=r(12);e.takeLast=n;var u=function(){function t(t){if(this.total=t,this.total<0)throw new s.ArgumentOutOfRangeError}return t.prototype.call=function(t,e){return e._subscribe(new a(t,this.total))},t}(),a=function(t){function e(e,r){t.call(this,e),this.total=r,this.ring=new Array,this.count=0}return i(e,t),e.prototype._next=function(t){var e=this.ring,r=this.total,n=this.count++;if(e.length0)for(var r=this.count>=this.total?this.total:this.count,n=this.ring,i=0;i0?this.startWindowEvery:this.windowSize,r=this.destination,n=this.windowSize,i=this.windows,o=i.length,c=0;c=0&&u%e===0&&!this.closed&&i.shift().complete(),++this.count%e===0&&!this.closed){var a=new s.Subject;i.push(a),r.next(a)}},e.prototype._error=function(t){var e=this.windows;if(e)for(;e.length>0&&!this.closed;)e.shift().error(t);this.destination.error(t)},e.prototype._complete=function(){var t=this.windows;if(t)for(;t.length>0&&!this.closed;)t.shift().complete();this.destination.complete()},e.prototype._unsubscribe=function(){this.count=0,this.windows=null},e}(o.Subscriber)},function(t,e,r){"use strict";function n(t,e,r){return void 0===e&&(e=null),void 0===r&&(r=a.async),this.lift(new l(t,e,r))}function i(t){var e=t.subscriber,r=t.windowTimeSpan,n=t.window;n&&n.complete(),t.window=e.openWindow(),this.schedule(t,r)}function o(t){var e=t.windowTimeSpan,r=t.subscriber,n=t.scheduler,i=t.windowCreationInterval,o=r.openWindow(),c=this,u={action:c,subscription:null},a={subscriber:r,window:o,context:u};u.subscription=n.schedule(s,e,a),c.add(u.subscription),c.schedule(t,i)}function s(t){var e=t.subscriber,r=t.window,n=t.context;n&&n.action&&n.subscription&&n.action.remove(n.subscription),e.closeWindow(r)}var c=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},u=r(5),a=r(9),h=r(1);e.windowTime=n;var l=function(){function t(t,e,r){this.windowTimeSpan=t,this.windowCreationInterval=e,this.scheduler=r}return t.prototype.call=function(t,e){return e._subscribe(new p(t,this.windowTimeSpan,this.windowCreationInterval,this.scheduler))},t}(),p=function(t){function e(e,r,n,c){if(t.call(this,e),this.destination=e,this.windowTimeSpan=r,this.windowCreationInterval=n,this.scheduler=c,this.windows=[],null!==n&&n>=0){var u=this.openWindow(),a={subscriber:this,window:u,context:null},h={windowTimeSpan:r,windowCreationInterval:n,subscriber:this,scheduler:c};this.add(c.schedule(s,r,a)),this.add(c.schedule(o,n,h))}else{var l=this.openWindow(),p={subscriber:this,window:l,windowTimeSpan:r};this.add(c.schedule(i,r,p))}}return c(e,t),e.prototype._next=function(t){for(var e=this.windows,r=e.length,n=0;n0;)e.shift().error(t);this.destination.error(t)},e.prototype._complete=function(){for(var t=this.windows;t.length>0;){var e=t.shift();e.closed||e.complete()}this.destination.complete()},e.prototype.openWindow=function(){var t=new u.Subject;this.windows.push(t);var e=this.destination;return e.next(t),t},e.prototype.closeWindow=function(t){t.complete();var e=this.windows;e.splice(e.indexOf(t),1)},e}(h.Subscriber)},function(t,e,r){"use strict";function n(t,e){return this.lift(new l(t,e))}var i=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},o=r(5),s=r(4),c=r(8),u=r(6),a=r(2),h=r(3);e.windowToggle=n;var l=function(){function t(t,e){this.openings=t,this.closingSelector=e}return t.prototype.call=function(t,e){ return e._subscribe(new p(t,this.openings,this.closingSelector))},t}(),p=function(t){function e(e,r,n){t.call(this,e),this.openings=r,this.closingSelector=n,this.contexts=[],this.add(this.openSubscription=h.subscribeToResult(this,r,r))}return i(e,t),e.prototype._next=function(t){var e=this.contexts;if(e)for(var r=e.length,n=0;n0){var s=o.indexOf(r);s!==-1&&o.splice(s,1)}},e.prototype.notifyComplete=function(){},e.prototype._next=function(t){if(0===this.toRespond.length){var e=[t].concat(this.values);this.project?this._tryProject(e):this.destination.next(e)}},e.prototype._tryProject=function(t){var e;try{e=this.project.apply(this,t)}catch(t){return void this.destination.error(t)}this.destination.next(e)},e}(o.OuterSubscriber)},function(t,e,r){"use strict";function n(t){return this.lift(new i.ZipOperator(t))}var i=r(35);e.zipAll=n},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(4),o=function(t){function e(e,r){t.call(this)}return n(e,t),e.prototype.schedule=function(t,e){return void 0===e&&(e=0),this},e}(i.Subscription);e.Action=o},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(16),o=r(335),s=function(t){function e(e,r){t.call(this,e,r),this.scheduler=e,this.work=r}return n(e,t),e.prototype.requestAsyncId=function(e,r,n){return void 0===n&&(n=0),null!==n&&n>0?t.prototype.requestAsyncId.call(this,e,r,n):(e.actions.push(this),e.scheduled||(e.scheduled=o.AnimationFrame.requestAnimationFrame(e.flush.bind(e,null))))},e.prototype.recycleAsyncId=function(e,r,n){return void 0===n&&(n=0),null!==n&&n>0||null===n&&this.delay>0?t.prototype.recycleAsyncId.call(this,e,r,n):void(0===e.actions.length&&(o.AnimationFrame.cancelAnimationFrame(r),e.scheduled=void 0))},e}(i.AsyncAction);e.AnimationFrameAction=s},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(17),o=function(t){function e(){t.apply(this,arguments)}return n(e,t),e.prototype.flush=function(t){this.active=!0,this.scheduled=void 0;var e,r=this.actions,n=-1,i=r.length;t=t||r.shift();do if(e=t.execute(t.state,t.delay))break;while(++n0?t.prototype.requestAsyncId.call(this,e,r,n):(e.actions.push(this),e.scheduled||(e.scheduled=i.Immediate.setImmediate(e.flush.bind(e,null))))},e.prototype.recycleAsyncId=function(e,r,n){return void 0===n&&(n=0),null!==n&&n>0||null===n&&this.delay>0?t.prototype.recycleAsyncId.call(this,e,r,n):void(0===e.actions.length&&(i.Immediate.clearImmediate(r),e.scheduled=void 0))},e}(o.AsyncAction);e.AsapAction=s},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(17),o=function(t){function e(){t.apply(this,arguments)}return n(e,t),e.prototype.flush=function(t){this.active=!0,this.scheduled=void 0;var e,r=this.actions,n=-1,i=r.length;t=t||r.shift();do if(e=t.execute(t.state,t.delay))break;while(++n0?t.prototype.schedule.call(this,e,r):(this.delay=r,this.state=e,this.scheduler.flush(this),this)},e.prototype.execute=function(e,r){return r>0||this.closed?t.prototype.execute.call(this,e,r):this._execute(e,r)},e.prototype.requestAsyncId=function(e,r,n){return void 0===n&&(n=0),null!==n&&n>0||null===n&&this.delay>0?t.prototype.requestAsyncId.call(this,e,r,n):e.flush(this)},e}(i.AsyncAction);e.QueueAction=o},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(17),o=function(t){function e(){t.apply(this,arguments)}return n(e,t),e}(i.AsyncScheduler);e.QueueScheduler=o},function(t,e,r){"use strict";var n=r(325),i=r(326);e.animationFrame=new i.AnimationFrameScheduler(n.AnimationFrameAction)},function(t,e,r){"use strict";var n=this&&this.__extends||function(t,e){function r(){this.constructor=t}for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)},i=r(0),o=r(4),s=r(60),c=r(63),u=function(t){function e(e,r){t.call(this,function(t){var e=this,r=e.logSubscribedFrame();return t.add(new o.Subscription(function(){e.logUnsubscribedFrame(r)})),e.scheduleMessages(t),t}),this.messages=e,this.subscriptions=[],this.scheduler=r}return n(e,t),e.prototype.scheduleMessages=function(t){for(var e=this.messages.length,r=0;r0;)e.shift().setup();t.prototype.flush.call(this);for(var r=this.flushTests.filter(function(t){return t.ready});r.length>0;){var n=r.shift();this.assertDeepEqual(n.actual,n.expected)}},e.parseMarblesAsSubscriptions=function(t){if("string"!=typeof t)return new u.SubscriptionLog(Number.POSITIVE_INFINITY);for(var e=t.length,r=-1,n=Number.POSITIVE_INFINITY,i=Number.POSITIVE_INFINITY,o=0;o-1?r:s;break;case"!":if(i!==Number.POSITIVE_INFINITY)throw new Error("found a second subscription point '^' in a subscription marble diagram. There can only be one.");i=r>-1?r:s;break;default:throw new Error("there can only be '^' and '!' markers in a subscription marble diagram. Found instead '"+c+"'.")}}return i<0?new u.SubscriptionLog(n):new u.SubscriptionLog(n,i)},e.parseMarbles=function(t,e,r,n){if(void 0===n&&(n=!1),t.indexOf("!")!==-1)throw new Error('conventional marble diagrams cannot have the unsubscription marker "!"');for(var i=t.length,c=[],u=t.indexOf("^"),a=u===-1?0:u*-this.frameTimeFactor,h="object"!=typeof e?function(t){return t}:function(t){return n&&e[t]instanceof s.ColdObservable?e[t].messages:e[t]},l=-1,p=0;p-1?l:f,notification:b})}return c},e}(a.VirtualTimeScheduler);e.TestScheduler=l},function(t,e,r){"use strict";var n=r(7),i=function(){function t(t){t.requestAnimationFrame?(this.cancelAnimationFrame=t.cancelAnimationFrame.bind(t),this.requestAnimationFrame=t.requestAnimationFrame.bind(t)):t.mozRequestAnimationFrame?(this.cancelAnimationFrame=t.mozCancelAnimationFrame.bind(t),this.requestAnimationFrame=t.mozRequestAnimationFrame.bind(t)):t.webkitRequestAnimationFrame?(this.cancelAnimationFrame=t.webkitCancelAnimationFrame.bind(t),this.requestAnimationFrame=t.webkitRequestAnimationFrame.bind(t)):t.msRequestAnimationFrame?(this.cancelAnimationFrame=t.msCancelAnimationFrame.bind(t),this.requestAnimationFrame=t.msRequestAnimationFrame.bind(t)):t.oRequestAnimationFrame?(this.cancelAnimationFrame=t.oCancelAnimationFrame.bind(t),this.requestAnimationFrame=t.oRequestAnimationFrame.bind(t)):(this.cancelAnimationFrame=t.clearTimeout.bind(t),this.requestAnimationFrame=function(e){return t.setTimeout(e,1e3/60)})}return t}();e.RequestAnimationFrameDefinition=i,e.AnimationFrame=new i(n.root)},function(t,e){"use strict";var r=function(){function t(){this.values={}}return t.prototype.delete=function(t){return this.values[t]=null,!0},t.prototype.set=function(t,e){return this.values[t]=e,this},t.prototype.get=function(t){return this.values[t]},t.prototype.forEach=function(t,e){var r=this.values;for(var n in r)r.hasOwnProperty(n)&&null!==r[n]&&t.call(e,r[n],n)},t.prototype.clear=function(){this.values={}},t}();e.FastMap=r},function(t,e,r){"use strict";(function(t,n){var i=r(7),o=function(){function t(t){if(this.root=t,t.setImmediate&&"function"==typeof t.setImmediate)this.setImmediate=t.setImmediate.bind(t),this.clearImmediate=t.clearImmediate.bind(t);else{this.nextHandle=1,this.tasksByHandle={},this.currentlyRunningATask=!1,this.canUseProcessNextTick()?this.setImmediate=this.createProcessNextTickSetImmediate():this.canUsePostMessage()?this.setImmediate=this.createPostMessageSetImmediate():this.canUseMessageChannel()?this.setImmediate=this.createMessageChannelSetImmediate():this.canUseReadyStateChange()?this.setImmediate=this.createReadyStateChangeSetImmediate():this.setImmediate=this.createSetTimeoutSetImmediate();var e=function t(e){delete t.instance.tasksByHandle[e]};e.instance=this,this.clearImmediate=e}}return t.prototype.identify=function(t){return this.root.Object.prototype.toString.call(t)},t.prototype.canUseProcessNextTick=function(){return"[object process]"===this.identify(this.root.process)},t.prototype.canUseMessageChannel=function(){return Boolean(this.root.MessageChannel)},t.prototype.canUseReadyStateChange=function(){var t=this.root.document;return Boolean(t&&"onreadystatechange"in t.createElement("script"))},t.prototype.canUsePostMessage=function(){var t=this.root;if(t.postMessage&&!t.importScripts){var e=!0,r=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=r,e}return!1},t.prototype.partiallyApplied=function(t){for(var e=[],r=1;r=0&&o0?0:c-1;return arguments.length<3&&(i=r[s?s[u]:u],u+=t),e(r,n,i,s,u,c)}}function o(t){return function(e,r,n){r=g(r,n);for(var i=I(e),o=t>0?0:i-1;o>=0&&o0?s=o>=0?o:Math.max(o+c,s):c=o>=0?Math.min(o+1,c):o+c+1;else if(r&&o&&c)return o=r(n,i),n[o]===i?o:-1;if(i!==i)return o=e(b.call(n,s,c),O.isNaN),o>=0?o+s:-1;for(o=t>0?s:c-1;o>=0&&o=0&&e<=k};O.each=O.forEach=function(t,e,r){e=S(e,r);var n,i;if(A(t))for(n=0,i=t.length;n=0},O.invoke=function(t,e){var r=b.call(arguments,2),n=O.isFunction(e);return O.map(t,function(t){var i=n?e:t[e];return null==i?i:i.apply(t,r)})},O.pluck=function(t,e){return O.map(t,O.property(e))},O.where=function(t,e){return O.filter(t,O.matcher(e))},O.findWhere=function(t,e){return O.find(t,O.matcher(e))},O.max=function(t,e,r){var n,i,o=-(1/0),s=-(1/0);if(null==e&&null!=t){t=A(t)?t:O.values(t);for(var c=0,u=t.length;co&&(o=n)}else e=g(e,r),O.each(t,function(t,r,n){i=e(t,r,n),(i>s||i===-(1/0)&&o===-(1/0))&&(o=t,s=i)});return o},O.min=function(t,e,r){var n,i,o=1/0,s=1/0;if(null==e&&null!=t){t=A(t)?t:O.values(t);for(var c=0,u=t.length;cn||void 0===r)return 1;if(re?(s&&(clearTimeout(s),s=null),c=a,o=t.apply(n,i),s||(n=i=null)):s||r.trailing===!1||(s=setTimeout(u,h)),o}},O.debounce=function(t,e,r){var n,i,o,s,c,u=function(){var a=O.now()-s;a=0?n=setTimeout(u,e-a):(n=null,r||(c=t.apply(o,i),n||(o=i=null)))};return function(){o=this,i=arguments,s=O.now();var a=r&&!n;return n||(n=setTimeout(u,e)),a&&(c=t.apply(o,i),o=i=null),c}},O.wrap=function(t,e){return O.partial(e,t)},O.negate=function(t){return function(){return!t.apply(this,arguments)}},O.compose=function(){var t=arguments,e=t.length-1;return function(){for(var r=e,n=t[e].apply(this,arguments);r--;)n=t[r].call(this,n);return n}},O.after=function(t,e){return function(){if(--t<1)return e.apply(this,arguments)}},O.before=function(t,e){var r;return function(){return--t>0&&(r=e.apply(this,arguments)),t<=1&&(e=null),r}},O.once=O.partial(O.before,2);var F=!{toString:null}.propertyIsEnumerable("toString"),R=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"]; O.keys=function(t){if(!O.isObject(t))return[];if(m)return m(t);var e=[];for(var r in t)O.has(t,r)&&e.push(r);return F&&c(t,e),e},O.allKeys=function(t){if(!O.isObject(t))return[];var e=[];for(var r in t)e.push(r);return F&&c(t,e),e},O.values=function(t){for(var e=O.keys(t),r=e.length,n=Array(r),i=0;i":">",'"':""","'":"'","`":"`"},q=O.invert(V),B=function(t){var e=function(e){return t[e]},r="(?:"+O.keys(t).join("|")+")",n=RegExp(r),i=RegExp(r,"g");return function(t){return t=null==t?"":""+t,n.test(t)?t.replace(i,e):t}};O.escape=B(V),O.unescape=B(q),O.result=function(t,e,r){var n=null==t?void 0:t[e];return void 0===n&&(n=r),O.isFunction(n)?n.call(t):n};var L=0;O.uniqueId=function(t){var e=++L+"";return t?t+e:e},O.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var U=/(.)^/,D={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},W=/\\|'|\r|\n|\u2028|\u2029/g,$=function(t){return"\\"+D[t]};O.template=function(t,e,r){!e&&r&&(e=r),e=O.defaults({},e,O.templateSettings);var n=RegExp([(e.escape||U).source,(e.interpolate||U).source,(e.evaluate||U).source].join("|")+"|$","g"),i=0,o="__p+='";t.replace(n,function(e,r,n,s,c){return o+=t.slice(i,c).replace(W,$),i=c+e.length,r?o+="'+\n((__t=("+r+"))==null?'':_.escape(__t))+\n'":n?o+="'+\n((__t=("+n+"))==null?'':__t)+\n'":s&&(o+="';\n"+s+"\n__p+='"),e}),o+="';\n",e.variable||(o="with(obj||{}){\n"+o+"}\n"),o="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+o+"return __p;\n";try{var s=new Function(e.variable||"obj","_",o)}catch(t){throw t.source=o,t}var c=function(t){return s.call(this,t,O)},u=e.variable||"obj";return c.source="function("+u+"){\n"+o+"}",c},O.chain=function(t){var e=O(t);return e._chain=!0,e};var z=function(t,e){return t._chain?O(e).chain():e};O.mixin=function(t){O.each(O.functions(t),function(e){var r=O[e]=t[e];O.prototype[e]=function(){var t=[this._wrapped];return f.apply(t,arguments),z(this,r.apply(O,t))}})},O.mixin(O),O.each(["pop","push","reverse","shift","sort","splice","unshift"],function(t){var e=h[t];O.prototype[t]=function(){var r=this._wrapped;return e.apply(r,arguments),"shift"!==t&&"splice"!==t||0!==r.length||delete r[0],z(this,r)}}),O.each(["concat","join","slice"],function(t){var e=h[t];O.prototype[t]=function(){return z(this,e.apply(this._wrapped,arguments))}}),O.prototype.value=function(){return this._wrapped},O.prototype.valueOf=O.prototype.toJSON=O.prototype.value,O.prototype.toString=function(){return""+this._wrapped},n=[],i=function(){return O}.apply(e,n),!(void 0!==i&&(t.exports=i))}).call(this)},function(t,e){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(r=window)}t.exports=r},function(t,e,r){"use strict";function n(t){if(/baidu\.com\/link\?url=/.test(t.href)&&!t.getAttribute(f.ing)&&!t.getAttribute(f.done)){t.setAttribute(f.ing,1);var e=t.href.replace(/^https?/,"https");e+="×tamp="+(new Date).getTime(),u.Observable.fromPromise(p.head(e)).retry(2).timeout(h).subscribe(function(e){t.href=e.finalUrl,t.removeAttribute(f.ing),t.setAttribute(f.done,1),l&&(t.style.backgroundColor="green")},function(){t.removeAttribute(f.ing)},function(){t.removeAttribute(f.ing)})}}function i(){u.Observable.from([].slice.call(document.querySelectorAll("#content_left a"))).subscribe(function(t){c&&c.is(t)&&n(t)})}function o(t){var e=t.responseText;e=e.replace(/(src=[^>]*|link=[^>])/g,"");var r=document.createElement("html");r.innerHTML=e,u.Observable.of(r.querySelectorAll(".f>a")).timeout(100).map(function(t){return[].slice.call(t).map(function(t){var e=[].slice.call(document.querySelectorAll(".t>a")).find(function(e){return(e.innerText||e.textContent)===(t.innerText||t.textContent)});return e?{local:e,remote:t}:void 0}).filter(function(t){return!!t})}).subscribe(function(t){t.forEach(function(t){t.local.href=t.remote.href,t.local.setAttribute(f.done,1),l&&(t.local.style.backgroundColor="red")})})}function s(){var t=location.search.match(/pn=(\d+)/)||[""],e=2===t.length?+t[1]:0,r=window.top.location.href.replace(/(\&)(tn=\w+)(\&)/gim,"$1tn=baidulocal$3");r+="×tamp="+(new Date).getTime(),u.Observable.forkJoin(u.Observable.fromPromise(p.get(r)),u.Observable.fromPromise(p.get(r.replace(/pn=(\d+)/,"pn="+(e+10))))).retry(2).timeout(h).subscribe(function(t){t&&t.length&&t.forEach(function(t){o(t)})})}var c,u=r(67),a=r(68),h=2e3,l=!1,p=new a.default({timeout:h}),f={ing:"redirect-ing",done:"redirect-done"};u.Observable.fromEvent(document,"mousemove").throttle(function(){return u.Observable.timer(100)}).map(function(t){var e=t.toElement;return"A"===e.nodeName?e:"A"===e.parentNode.nodeName?e.parentNode:e}).filter(function(t){return"A"===t.nodeName}).subscribe(n),u.Observable.fromEvent(window,"scroll").debounce(function(){return u.Observable.timer(300)}).subscribe(i),u.Observable.fromEvent(document,"DOMContentLoaded").do(function(){c=r(66),c("#content_left a").on("enter",function(t){n(t)})}).do(s).flatMap(function(){return u.Observable.create(function(t){new MutationObserver(function(e){void 0===e&&(e=[]),e.length&&t.next()}).observe(document.body,{childList:!0})}).debounce(function(){return u.Observable.timer(500)})}).subscribe(function(){s(),i()})}]);