From fe0b00906cdf89b94d801114f48d1072beb78d46 Mon Sep 17 00:00:00 2001 From: pubkey <8926560+pubkey@users.noreply.github.com> Date: Sun, 26 Nov 2023 00:31:15 +0100 Subject: [PATCH] UPDATE playground --- docs/bundle.js | 18465 ++++++++++++++++++++++++++++++++++- docs/bundle.js.LICENSE.txt | 93 + 2 files changed, 18463 insertions(+), 95 deletions(-) create mode 100644 docs/bundle.js.LICENSE.txt diff --git a/docs/bundle.js b/docs/bundle.js index c8164a27..86603e2d 100644 --- a/docs/bundle.js +++ b/docs/bundle.js @@ -1,96 +1,18371 @@ -!function(e){var a={};function t(n){if(a[n])return a[n].exports;var r=a[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,t),r.l=!0,r.exports}t.m=e,t.c=a,t.d=function(e,a,n){t.o(e,a)||Object.defineProperty(e,a,{enumerable:!0,get:n})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,a){if(1&a&&(e=t(e)),8&a)return e;if(4&a&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(t.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&a&&"string"!=typeof e)for(var r in e)t.d(n,r,function(a){return e[a]}.bind(null,r));return n},t.n=function(e){var a=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(a,"a",a),a},t.o=function(e,a){return Object.prototype.hasOwnProperty.call(e,a)},t.p="",t(t.s=1224)}([function(e,a){"function"==typeof Object.create?e.exports=function(e,a){a&&(e.super_=a,e.prototype=Object.create(a.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,a){if(a){e.super_=a;var t=function(){};t.prototype=a.prototype,e.prototype=new t,e.prototype.constructor=e}}},function(e,a,t){"use strict";t.d(a,"a",(function(){return n})),t.d(a,"g",(function(){return r})),t.d(a,"b",(function(){return c})),t.d(a,"c",(function(){return s})),t.d(a,"d",(function(){return o})),t.d(a,"e",(function(){return d})),t.d(a,"f",(function(){return l})),t.d(a,"h",(function(){return p})),t.d(a,"i",(function(){return u}));var n=function(e){return atob(e)},r=function(e){return btoa(e)};function o(e,a){e=e||[],a=a||{};try{return new Blob(e,a)}catch(r){if("TypeError"!==r.name)throw r;for(var t=new("undefined"!=typeof BlobBuilder?BlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder?MozBlobBuilder:WebKitBlobBuilder),n=0;n1)for(var t=1;t0&&i.length>r&&!i.warned){i.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+i.length+" "+String(a)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=a,c.count=i.length,s=c,console&&console.warn&&console.warn(s)}return e}function p(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function f(e,a,t){var n={fired:!1,wrapFn:void 0,target:e,type:a,listener:t},r=p.bind(n);return r.listener=t,n.wrapFn=r,r}function m(e,a,t){var n=e._events;if(void 0===n)return[];var r=n[a];return void 0===r?[]:"function"==typeof r?t?[r.listener||r]:[r]:t?function(e){for(var a=new Array(e.length),t=0;t0&&(i=a[0]),i instanceof Error)throw i;var s=new Error("Unhandled error."+(i?" ("+i.message+")":""));throw s.context=i,s}var c=r[e];if(void 0===c)return!1;if("function"==typeof c)o(c,this,a);else{var u=c.length,l=v(c,u);for(t=0;t=0;o--)if(t[o]===a||t[o].listener===a){i=t[o].listener,r=o;break}if(r<0)return this;0===r?t.shift():function(e,a){for(;a+1=0;n--)this.removeListener(e,a[n]);return this},s.prototype.listeners=function(e){return m(this,e,!0)},s.prototype.rawListeners=function(e){return m(this,e,!1)},s.listenerCount=function(e,a){return"function"==typeof e.listenerCount?e.listenerCount(a):h.call(e,a)},s.prototype.listenerCount=h,s.prototype.eventNames=function(){return this._eventsCount>0?n(this._events):[]}},function(e,a){var t;t=function(){return this}();try{t=t||new Function("return this")()}catch(e){"object"==typeof window&&(t=window)}e.exports=t},function(e,a,t){"use strict";(function(e){ -/*! - * The buffer module from node.js, for the browser. - * - * @author Feross Aboukhadijeh - * @license MIT - */ -var n=t(116),r=t(117),o=t(52);function i(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,a){if(i()=i())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i().toString(16)+" bytes");return 0|e}function m(e,a){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var t=e.length;if(0===t)return 0;for(var n=!1;;)switch(a){case"ascii":case"latin1":case"binary":return t;case"utf8":case"utf-8":case void 0:return O(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*t;case"hex":return t>>>1;case"base64":return V(e).length;default:if(n)return O(e).length;a=(""+a).toLowerCase(),n=!0}}function h(e,a,t){var n=!1;if((void 0===a||a<0)&&(a=0),a>this.length)return"";if((void 0===t||t>this.length)&&(t=this.length),t<=0)return"";if((t>>>=0)<=(a>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return B(this,a,t);case"utf8":case"utf-8":return A(this,a,t);case"ascii":return M(this,a,t);case"latin1":case"binary":return j(this,a,t);case"base64":return z(this,a,t);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return K(this,a,t);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function v(e,a,t){var n=e[a];e[a]=e[t],e[t]=n}function k(e,a,t,n,r){if(0===e.length)return-1;if("string"==typeof t?(n=t,t=0):t>2147483647?t=2147483647:t<-2147483648&&(t=-2147483648),t=+t,isNaN(t)&&(t=r?0:e.length-1),t<0&&(t=e.length+t),t>=e.length){if(r)return-1;t=e.length-1}else if(t<0){if(!r)return-1;t=0}if("string"==typeof a&&(a=c.from(a,n)),c.isBuffer(a))return 0===a.length?-1:g(e,a,t,n,r);if("number"==typeof a)return a&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?r?Uint8Array.prototype.indexOf.call(e,a,t):Uint8Array.prototype.lastIndexOf.call(e,a,t):g(e,[a],t,n,r);throw new TypeError("val must be string, number or Buffer")}function g(e,a,t,n,r){var o,i=1,s=e.length,c=a.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||a.length<2)return-1;i=2,s/=2,c/=2,t/=2}function u(e,a){return 1===i?e[a]:e.readUInt16BE(a*i)}if(r){var l=-1;for(o=t;os&&(t=s-c),o=t;o>=0;o--){for(var d=!0,p=0;pr&&(n=r):n=r;var o=a.length;if(o%2!=0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var i=0;i>8,r=t%256,o.push(r),o.push(n);return o}(a,e.length-t),e,t,n)}function z(e,a,t){return 0===a&&t===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(a,t))}function A(e,a,t){t=Math.min(e.length,t);for(var n=[],r=a;r239?4:u>223?3:u>191?2:1;if(r+d<=t)switch(d){case 1:u<128&&(l=u);break;case 2:128==(192&(o=e[r+1]))&&(c=(31&u)<<6|63&o)>127&&(l=c);break;case 3:o=e[r+1],i=e[r+2],128==(192&o)&&128==(192&i)&&(c=(15&u)<<12|(63&o)<<6|63&i)>2047&&(c<55296||c>57343)&&(l=c);break;case 4:o=e[r+1],i=e[r+2],s=e[r+3],128==(192&o)&&128==(192&i)&&128==(192&s)&&(c=(15&u)<<18|(63&o)<<12|(63&i)<<6|63&s)>65535&&c<1114112&&(l=c)}null===l?(l=65533,d=1):l>65535&&(l-=65536,n.push(l>>>10&1023|55296),l=56320|1023&l),n.push(l),r+=d}return function(e){var a=e.length;if(a<=4096)return String.fromCharCode.apply(String,e);var t="",n=0;for(;n0&&(e=this.toString("hex",0,t).match(/.{2}/g).join(" "),this.length>t&&(e+=" ... ")),""},c.prototype.compare=function(e,a,t,n,r){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===a&&(a=0),void 0===t&&(t=e?e.length:0),void 0===n&&(n=0),void 0===r&&(r=this.length),a<0||t>e.length||n<0||r>this.length)throw new RangeError("out of range index");if(n>=r&&a>=t)return 0;if(n>=r)return-1;if(a>=t)return 1;if(this===e)return 0;for(var o=(r>>>=0)-(n>>>=0),i=(t>>>=0)-(a>>>=0),s=Math.min(o,i),u=this.slice(n,r),l=e.slice(a,t),d=0;dr)&&(t=r),e.length>0&&(t<0||a<0)||a>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return y(this,e,a,t);case"utf8":case"utf-8":return b(this,e,a,t);case"ascii":return w(this,e,a,t);case"latin1":case"binary":return S(this,e,a,t);case"base64":return x(this,e,a,t);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _(this,e,a,t);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function M(e,a,t){var n="";t=Math.min(e.length,t);for(var r=a;rn)&&(t=n);for(var r="",o=a;ot)throw new RangeError("Trying to access beyond buffer length")}function P(e,a,t,n,r,o){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(a>r||ae.length)throw new RangeError("Index out of range")}function E(e,a,t,n){a<0&&(a=65535+a+1);for(var r=0,o=Math.min(e.length-t,2);r>>8*(n?r:1-r)}function L(e,a,t,n){a<0&&(a=4294967295+a+1);for(var r=0,o=Math.min(e.length-t,4);r>>8*(n?r:3-r)&255}function R(e,a,t,n,r,o){if(t+n>e.length)throw new RangeError("Index out of range");if(t<0)throw new RangeError("Index out of range")}function C(e,a,t,n,o){return o||R(e,0,t,4),r.write(e,a,t,n,23,4),t+4}function D(e,a,t,n,o){return o||R(e,0,t,8),r.write(e,a,t,n,52,8),t+8}c.prototype.slice=function(e,a){var t,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(a=void 0===a?n:~~a)<0?(a+=n)<0&&(a=0):a>n&&(a=n),a0&&(r*=256);)n+=this[e+--a]*r;return n},c.prototype.readUInt8=function(e,a){return a||N(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,a){return a||N(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,a){return a||N(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,a){return a||N(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,a){return a||N(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,a,t){e|=0,a|=0,t||N(e,a,this.length);for(var n=this[e],r=1,o=0;++o=(r*=128)&&(n-=Math.pow(2,8*a)),n},c.prototype.readIntBE=function(e,a,t){e|=0,a|=0,t||N(e,a,this.length);for(var n=a,r=1,o=this[e+--n];n>0&&(r*=256);)o+=this[e+--n]*r;return o>=(r*=128)&&(o-=Math.pow(2,8*a)),o},c.prototype.readInt8=function(e,a){return a||N(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,a){a||N(e,2,this.length);var t=this[e]|this[e+1]<<8;return 32768&t?4294901760|t:t},c.prototype.readInt16BE=function(e,a){a||N(e,2,this.length);var t=this[e+1]|this[e]<<8;return 32768&t?4294901760|t:t},c.prototype.readInt32LE=function(e,a){return a||N(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,a){return a||N(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,a){return a||N(e,4,this.length),r.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,a){return a||N(e,4,this.length),r.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,a){return a||N(e,8,this.length),r.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,a){return a||N(e,8,this.length),r.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,a,t,n){(e=+e,a|=0,t|=0,n)||P(this,e,a,t,Math.pow(2,8*t)-1,0);var r=1,o=0;for(this[a]=255&e;++o=0&&(o*=256);)this[a+r]=e/o&255;return a+t},c.prototype.writeUInt8=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[a]=255&e,a+1},c.prototype.writeUInt16LE=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[a]=255&e,this[a+1]=e>>>8):E(this,e,a,!0),a+2},c.prototype.writeUInt16BE=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[a]=e>>>8,this[a+1]=255&e):E(this,e,a,!1),a+2},c.prototype.writeUInt32LE=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[a+3]=e>>>24,this[a+2]=e>>>16,this[a+1]=e>>>8,this[a]=255&e):L(this,e,a,!0),a+4},c.prototype.writeUInt32BE=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[a]=e>>>24,this[a+1]=e>>>16,this[a+2]=e>>>8,this[a+3]=255&e):L(this,e,a,!1),a+4},c.prototype.writeIntLE=function(e,a,t,n){if(e=+e,a|=0,!n){var r=Math.pow(2,8*t-1);P(this,e,a,t,r-1,-r)}var o=0,i=1,s=0;for(this[a]=255&e;++o>0)-s&255;return a+t},c.prototype.writeIntBE=function(e,a,t,n){if(e=+e,a|=0,!n){var r=Math.pow(2,8*t-1);P(this,e,a,t,r-1,-r)}var o=t-1,i=1,s=0;for(this[a+o]=255&e;--o>=0&&(i*=256);)e<0&&0===s&&0!==this[a+o+1]&&(s=1),this[a+o]=(e/i>>0)-s&255;return a+t},c.prototype.writeInt8=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[a]=255&e,a+1},c.prototype.writeInt16LE=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[a]=255&e,this[a+1]=e>>>8):E(this,e,a,!0),a+2},c.prototype.writeInt16BE=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[a]=e>>>8,this[a+1]=255&e):E(this,e,a,!1),a+2},c.prototype.writeInt32LE=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[a]=255&e,this[a+1]=e>>>8,this[a+2]=e>>>16,this[a+3]=e>>>24):L(this,e,a,!0),a+4},c.prototype.writeInt32BE=function(e,a,t){return e=+e,a|=0,t||P(this,e,a,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[a]=e>>>24,this[a+1]=e>>>16,this[a+2]=e>>>8,this[a+3]=255&e):L(this,e,a,!1),a+4},c.prototype.writeFloatLE=function(e,a,t){return C(this,e,a,!0,t)},c.prototype.writeFloatBE=function(e,a,t){return C(this,e,a,!1,t)},c.prototype.writeDoubleLE=function(e,a,t){return D(this,e,a,!0,t)},c.prototype.writeDoubleBE=function(e,a,t){return D(this,e,a,!1,t)},c.prototype.copy=function(e,a,t,n){if(t||(t=0),n||0===n||(n=this.length),a>=e.length&&(a=e.length),a||(a=0),n>0&&n=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-a=0;--r)e[r+a]=this[r+t];else if(o<1e3||!c.TYPED_ARRAY_SUPPORT)for(r=0;r>>=0,t=void 0===t?this.length:t>>>0,e||(e=0),"number"==typeof e)for(o=a;o55295&&t<57344){if(!r){if(t>56319){(a-=3)>-1&&o.push(239,191,189);continue}if(i+1===n){(a-=3)>-1&&o.push(239,191,189);continue}r=t;continue}if(t<56320){(a-=3)>-1&&o.push(239,191,189),r=t;continue}t=65536+(r-55296<<10|t-56320)}else r&&(a-=3)>-1&&o.push(239,191,189);if(r=null,t<128){if((a-=1)<0)break;o.push(t)}else if(t<2048){if((a-=2)<0)break;o.push(t>>6|192,63&t|128)}else if(t<65536){if((a-=3)<0)break;o.push(t>>12|224,t>>6&63|128,63&t|128)}else{if(!(t<1114112))throw new Error("Invalid code point");if((a-=4)<0)break;o.push(t>>18|240,t>>12&63|128,t>>6&63|128,63&t|128)}}return o}function V(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(T,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function J(e,a,t,n){for(var r=0;r=a.length||r>=e.length);++r)a[r+t]=e[r];return r}}).call(this,t(4))},function(e,a,t){(function(e,n){var r; -/** - * @license - * lodash 3.10.1 (Custom Build) - * Build: `lodash modern -d -o ./index.js` - * Copyright 2012-2015 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */(function(){var o,i,s="Expected a function",c="__lodash_placeholder__",u="[object Arguments]",l="[object Array]",d="[object Boolean]",p="[object Date]",f="[object Error]",m="[object Function]",h="[object Number]",v="[object Object]",k="[object RegExp]",g="[object String]",y="[object Float32Array]",b="[object Float64Array]",w="[object Int8Array]",S="[object Int16Array]",x="[object Int32Array]",_="[object Uint8Array]",z="[object Uint16Array]",A="[object Uint32Array]",M=/\b__p \+= '';/g,j=/\b(__p \+=) '' \+/g,B=/(__e\(.*?\)|\b__t\)) \+\n'';/g,K=/&(?:amp|lt|gt|quot|#39|#96);/g,N=/[&<>"'`]/g,P=RegExp(K.source),E=RegExp(N.source),L=/<%-([\s\S]+?)%>/g,R=/<%([\s\S]+?)%>/g,C=/<%=([\s\S]+?)%>/g,D=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\n\\]|\\.)*?\1)\]/,T=/^\w*$/,H=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g,O=/^[:!,]|[\\^$.*+?()[\]{}|\/]|(^[0-9a-fA-Fnrtuvx])|([\n\r\u2028\u2029])/g,V=RegExp(O.source),J=/[\u0300-\u036f\ufe20-\ufe23]/g,I=/\\(\\)?/g,G=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,F=/\w*$/,q=/^0[xX]/,U=/^\[object .+?Constructor\]$/,W=/^\d+$/,Z=/[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g,$=/($^)/,Y=/['\n\r\u2028\u2029\\]/g,X=(o="[A-Z\\xc0-\\xd6\\xd8-\\xde]",i="[a-z\\xdf-\\xf6\\xf8-\\xff]+",RegExp(o+"+(?="+o+i+")|"+o+"?"+i+"|"+o+"+|[0-9]+","g")),Q=["Array","ArrayBuffer","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Math","Number","Object","RegExp","Set","String","_","clearTimeout","isFinite","parseFloat","parseInt","setTimeout","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap"],ee=-1,ae={};ae[y]=ae[b]=ae[w]=ae[S]=ae[x]=ae[_]=ae["[object Uint8ClampedArray]"]=ae[z]=ae[A]=!0,ae[u]=ae[l]=ae["[object ArrayBuffer]"]=ae[d]=ae[p]=ae[f]=ae[m]=ae["[object Map]"]=ae[h]=ae[v]=ae[k]=ae["[object Set]"]=ae[g]=ae["[object WeakMap]"]=!1;var te={};te[u]=te[l]=te["[object ArrayBuffer]"]=te[d]=te[p]=te[y]=te[b]=te[w]=te[S]=te[x]=te[h]=te[v]=te[k]=te[g]=te[_]=te["[object Uint8ClampedArray]"]=te[z]=te[A]=!0,te[f]=te[m]=te["[object Map]"]=te["[object Set]"]=te["[object WeakMap]"]=!1;var ne={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss"},re={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},oe={"&":"&","<":"<",">":">",""":'"',"'":"'","`":"`"},ie={function:!0,object:!0},se={0:"x30",1:"x31",2:"x32",3:"x33",4:"x34",5:"x35",6:"x36",7:"x37",8:"x38",9:"x39",A:"x41",B:"x42",C:"x43",D:"x44",E:"x45",F:"x46",a:"x61",b:"x62",c:"x63",d:"x64",e:"x65",f:"x66",n:"x6e",r:"x72",t:"x74",u:"x75",v:"x76",x:"x78"},ce={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ue=ie[typeof a]&&a&&!a.nodeType&&a,le=ie[typeof e]&&e&&!e.nodeType&&e,de=ue&&le&&"object"==typeof n&&n&&n.Object&&n,pe=ie[typeof self]&&self&&self.Object&&self,fe=ie[typeof window]&&window&&window.Object&&window,me=(le&&le.exports,de||fe!==(this&&this.window)&&fe||pe||this);function he(e,a){if(e!==a){var t=null===e,n=void 0===e,r=e==e,o=null===a,i=void 0===a,s=a==a;if(e>a&&!o||!r||t&&!i&&s||n&&s)return 1;if(e-1;);return t}function we(e,a){for(var t=e.length;t--&&a.indexOf(e.charAt(t))>-1;);return t}function Se(e,a){return he(e.criteria,a.criteria)||e.index-a.index}function xe(e){return ne[e]}function _e(e){return re[e]}function ze(e,a,t){return a?e=se[e]:t&&(e=ce[e]),"\\"+e}function Ae(e){return"\\"+ce[e]}function Me(e,a,t){for(var n=e.length,r=a+(t?0:-1);t?r--:++r=9&&e<=13||32==e||160==e||5760==e||6158==e||e>=8192&&(e<=8202||8232==e||8233==e||8239==e||8287==e||12288==e||65279==e)}function Ke(e,a){for(var t=-1,n=e.length,r=-1,o=[];++t=200?bt(a):null,c=a.length;s&&(o=ma,i=!1,a=s);e:for(;++ro?0:o+a),(n=void 0===n||n>o?o:+n||0)<0&&(n+=o),o=a>n?0:n-a>>>0,a>>>=0;for(var i=t(o);++r=s)return c;var u=t[n];return c*("asc"===u||!0===u?1:-1)}}return e.index-a.index}(e,a,t)}))}function it(e,a){var t=-1,n=Wt(),r=e.length,o=n==ke,i=o&&r>=200,s=i?bt():null,c=[];s?(n=ma,o=!1):(i=!1,s=a?[]:c);e:for(;++t>>1,i=e[o];(t?i<=a:i2?t[r-2]:void 0,i=r>2?t[2]:void 0,s=r>1?t[r-1]:void 0;for("function"==typeof o?(o=pt(o,s,5),r-=2):r-=(o="function"==typeof s?s:void 0)?1:0,i&&an(t[0],t[1],i)&&(o=r<3?void 0:o,r=1);++n-1?t[o]:void 0}return Da(t,n,e)}}function Mt(e){return function(a,t,n){return a&&a.length?ve(a,t=Ft(t,n,3),e):-1}}function jt(e){return function(a,t,n){return Da(a,t=Ft(t,n,3),e,!0)}}function Bt(e){return function(){for(var a,n=arguments.length,r=e?n:-1,o=0,i=t(n);e?r--:++r=200)return a.plant(t).value();for(var r=0,o=n?i[r].apply(this,e):t;++r=(a=+a)||!Ye(a))return"";var r=a-n;return po(t=null==t?" ":t+"",Ue(r/t.length)).slice(0,r)}function Ht(e,a,n,r){var o=1&a,i=St(e);return function a(){for(var s=-1,c=arguments.length,u=-1,l=r.length,d=t(l+c);++uc))return!1;for(;++s-1&&e%1==0&&e-1&&e%1==0&&e<=9007199254740991}function on(e){return e==e&&!Nr(e)}function sn(e,a){e=hn(e);for(var t=-1,n=a.length,r={};++t0){if(++ln>=150)return e}else ln=0;return at(e,a)});function fn(e){for(var a=Qr(e),t=a.length,n=t&&e.length,r=!!n&&rn(n)&&(Mr(e)||Ar(e)),o=-1,i=[];++o=120?bt(n&&c):null}var u=e[0],l=-1,d=u?u.length:0,p=r[0];e:for(;++l2?e[a-2]:void 0,n=a>1?e[a-1]:void 0;return a>2&&"function"==typeof t?a-=2:(t=a>1&&"function"==typeof n?(--a,n):void 0,n=void 0),e.length=a,Ln(e,t,n)}));function Hn(e){var a=ca(e);return a.__chain__=!0,a}function On(e,a,t){return a.call(t,e)}var Vn=_r((function(e){return e=Ta(e),this.thru((function(a){return function(e,a){for(var n=-1,r=e.length,o=-1,i=a.length,s=t(r+i);++n-1:!!r&&Wt(e,a,t)>-1}var Xn=vt((function(e,a,t){e[t]=a})),Qn=_r((function(e,a,n){var r=-1,o="function"==typeof a,i=tn(a),s=Qt(e)?t(e.length):[];return Ea(e,(function(e){var t=o?a:i&&null!=e?e[a]:void 0;s[++r]=t?t.apply(e,n):Xt(e,a,n)})),s}));function er(e,a,t){return(Mr(e)?ya:Wa)(e,a=Ft(a,t,3))}var ar=vt((function(e,a,t){e[t?0:1].push(a)}),(function(){return[[],[]]})),tr=Ct(wa,Ea),nr=Ct((function(e,a,t,n){var r=e.length;for(n&&r&&(t=e[--r]);r--;)t=a(t,e[r],r,e);return t}),La);function rr(e,a,t){if(t?an(e,a,t):null==a)return(n=(e=mn(e)).length)>0?e[Qa(0,n-1)]:void 0;var n,r=-1,o=Hr(e),i=(n=o.length)-1;for(a=ea(a<0?0:+a||0,n);++r0&&(t=a.apply(this,arguments)),e<=1&&(a=void 0),t}}var ur=_r((function(e,a,t){var n=1;if(t.length){var r=Ke(t,ur.placeholder);n|=32}return Jt(e,n,a,t,r)})),lr=_r((function(e,a){for(var t=-1,n=(a=a.length?Ta(a):Yr(e)).length;++ta?h(l,r):u=Ie(v,e)}function k(){h(f,u)}function g(){if(n=arguments,i=sr(),c=this,l=f&&(u||!m),!1===p)var t=m&&!u;else{r||m||(d=i);var s=p-(i-d),h=s<=0||s>p;h?(r&&(r=Te(r)),d=i,o=e.apply(c,n)):r||(r=Ie(k,s))}return h&&u?u=Te(u):u||a===p||(u=Ie(v,a)),t&&(h=!0,o=e.apply(c,n)),!h||u||r||(n=c=void 0),o}return g.cancel=function(){u&&Te(u),r&&Te(r),d=0,r=u=l=void 0},g}var hr=_r((function(e,a){return Na(e,1,a)})),vr=_r((function(e,a,t){return Na(e,a,t)})),kr=Bt(),gr=Bt(!0);function yr(e,a){if("function"!=typeof e||a&&"function"!=typeof a)throw new se(s);var t=function(){var n=arguments,r=a?a.apply(this,n):n[0],o=t.cache;if(o.has(r))return o.get(r);var i=e.apply(this,n);return t.cache=o.set(r,i),i};return t.cache=new yr.Cache,t}var br=_r((function(e,a){if(a=Ta(a),"function"!=typeof e||!ka(a,ge))throw new se(s);var t=a.length;return _r((function(n){for(var r=ea(n.length,t);r--;)n[r]=a[r](n[r]);return e.apply(this,n)}))})),wr=Rt(32),Sr=Rt(64),xr=_r((function(e,a){return Jt(e,256,void 0,void 0,void 0,Ta(a))}));function _r(e,a){if("function"!=typeof e)throw new se(s);return a=Qe(void 0===a?e.length-1:+a||0,0),function(){for(var n=arguments,r=-1,o=Qe(n.length-a,0),i=t(o);++ra}function Ar(e){return je(e)&&Qt(e)&&pe.call(e,"callee")&&!Ve.call(e,"callee")}var Mr=$e||function(e){return je(e)&&rn(e.length)&&Be.call(e)==l};function jr(e,a,t,n){var r=(t="function"==typeof t?pt(t,n,3):void 0)?t(e,a):void 0;return void 0===r?qa(e,a,t):!!r}function Br(e){return je(e)&&"string"==typeof e.message&&Be.call(e)==f}function Kr(e){return Nr(e)&&Be.call(e)==m}function Nr(e){var a=typeof e;return!!e&&("object"==a||"function"==a)}function Pr(e){return null!=e&&(Kr(e)?Ce.test(de.call(e)):je(e)&&U.test(e))}function Er(e){return"number"==typeof e||je(e)&&Be.call(e)==h}function Lr(e){var a,t;return!(!je(e)||Be.call(e)!=v||Ar(e)||!(pe.call(e,"constructor")||"function"!=typeof(a=e.constructor)||a instanceof a))&&(Va(e,(function(e,a){t=a})),void 0===t||pe.call(e,t))}function Rr(e){return Nr(e)&&Be.call(e)==k}function Cr(e){return"string"==typeof e||je(e)&&Be.call(e)==g}function Dr(e){return je(e)&&rn(e.length)&&!!ae[Be.call(e)]}function Tr(e,a){return e0;++rr?0:r+t),(n=void 0===n||n>r?r:+n||0)<0&&(n+=r),r=t>n?0:n>>>0,t>>>=0;t-1;)Ge.call(a,o,1);return a},ca.pullAt=Mn,ca.range=function(e,a,n){n&&an(e,a,n)&&(a=n=void 0),e=+e||0,null==a?(a=e,e=0):a=+a||0;for(var r=-1,o=Qe(Ue((a-e)/((n=null==n?1:+n||0)||1)),0),i=t(o);++r=0&&e.indexOf(a,t)==t},ca.escape=function(e){return(e=ye(e))&&E.test(e)?e.replace(N,_e):e},ca.escapeRegExp=function(e){return(e=ye(e))&&V.test(e)?e.replace(O,ze):e||"(?:)"},ca.every=Gn,ca.find=qn,ca.findIndex=wn,ca.findKey=Fr,ca.findLast=Un,ca.findLastIndex=Sn,ca.findLastKey=qr,ca.findWhere=function(e,a){return qn(e,Za(a))},ca.first=xn,ca.floor=jo,ca.get=function(e,a,t){var n=null==e?void 0:Fa(e,vn(a),a+"");return void 0===n?t:n},ca.gt=zr,ca.gte=function(e,a){return e>=a},ca.has=function(e,a){if(null==e)return!1;var t=pe.call(e,a);if(!t&&!tn(a)){if(null==(e=1==(a=vn(a)).length?e:Fa(e,tt(a,0,-1))))return!1;a=An(a),t=pe.call(e,a)}return t||rn(e.length)&&en(a,e.length)&&(Mr(e)||Ar(e))},ca.identity=yo,ca.includes=Yn,ca.indexOf=_n,ca.inRange=function(e,a,t){return a=+a||0,void 0===t?(t=a,a=0):t=+t||0,e>=ea(a,t)&&e=a||!Ye(a))return e;var r=(a-n)/2,o=Ze(r);return(t=Tt("",Ue(r),t)).slice(0,o)+e+t},ca.padLeft=uo,ca.padRight=lo,ca.parseInt=function(e,a,t){return(t?an(e,a,t):null==a)?a=0:a&&(a=+a),e=ho(e),ta(e,a||(q.test(e)?16:10))},ca.random=function(e,a,t){t&&an(e,a,t)&&(a=t=void 0);var n=null==e,r=null==a;if(null==t&&(r&&"boolean"==typeof e?(t=e,e=1):"boolean"==typeof a&&(t=a,r=!0)),n&&r&&(a=1,r=!1),e=+e||0,r?(a=e,e=0):a=+a||0,t||e%1||a%1){var o=na();return ea(e+o*(a-e+He("1e-"+((o+"").length-1))),a)}return Qa(e,a)},ca.reduce=tr,ca.reduceRight=nr,ca.repeat=po,ca.result=function(e,a,t){var n=null==e?void 0:e[a];return void 0===n&&(null==e||tn(a,e)||(n=null==(e=1==(a=vn(a)).length?e:Fa(e,tt(a,0,-1)))?void 0:e[An(a)]),n=void 0===n?t:n),Kr(n)?n.call(e):n},ca.round=No,ca.runInContext=e,ca.size=function(e){var a=e?Zt(e):0;return rn(a)?a:Xr(e).length},ca.snakeCase=fo,ca.some=or,ca.sortedIndex=Bn,ca.sortedLastIndex=Kn,ca.startCase=mo,ca.startsWith=function(e,a,t){return e=ye(e),t=null==t?0:ea(t<0?0:+t||0,e.length),e.lastIndexOf(a,t)==t},ca.sum=function(e,a,t){return t&&an(e,a,t)&&(a=void 0),1==(a=Ft(a,t,3)).length?function(e,a){for(var t=e.length,n=0;t--;)n+=+a(e[t])||0;return n}(Mr(e)?e:mn(e),a):function(e,a){var t=0;return Ea(e,(function(e,n,r){t+=+a(e,n,r)||0})),t}(e,a)},ca.template=function(e,a,t){var n=ca.templateSettings;t&&an(e,a,t)&&(a=t=void 0),e=ye(e),a=_a(za({},t||a),n,xa);var r,i,s=_a(za({},a.imports),n.imports,xa),c=Xr(s),u=st(s,c),l=0,d=a.interpolate||$,p="__p += '",f=oe((a.escape||$).source+"|"+d.source+"|"+(d===C?G:$).source+"|"+(a.evaluate||$).source+"|$","g"),m="//# sourceURL="+("sourceURL"in a?a.sourceURL:"lodash.templateSources["+ ++ee+"]")+"\n";e.replace(f,(function(a,t,n,o,s,c){return n||(n=o),p+=e.slice(l,c).replace(Y,Ae),t&&(r=!0,p+="' +\n__e("+t+") +\n'"),s&&(i=!0,p+="';\n"+s+";\n__p += '"),n&&(p+="' +\n((__t = ("+n+")) == null ? '' : __t) +\n'"),l=c+a.length,a})),p+="';\n";var h=a.variable;h||(p="with (obj) {\n"+p+"\n}\n"),p=(i?p.replace(M,""):p).replace(j,"$1").replace(B,"$1;"),p="function("+(h||"obj")+") {\n"+(h?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(r?", __e = _.escape":"")+(i?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+p+"return __p\n}";var v=ko((function(){return o(c,m+"return "+p).apply(void 0,u)}));if(v.source=p,Br(v))throw v;return v},ca.trim=ho,ca.trimLeft=function(e,a,t){var n=e;return(e=ye(e))?(t?an(n,a,t):null==a)?e.slice(Ne(e)):e.slice(be(e,a+"")):e},ca.trimRight=function(e,a,t){var n=e;return(e=ye(e))?(t?an(n,a,t):null==a)?e.slice(0,Pe(e)+1):e.slice(0,we(e,a+"")+1):e},ca.trunc=function(e,a,t){t&&an(e,a,t)&&(a=void 0);var n=30,r="...";if(null!=a)if(Nr(a)){var o="separator"in a?a.separator:o;n="length"in a?+a.length||0:n,r="omission"in a?ye(a.omission):r}else n=+a||0;if(n>=(e=ye(e)).length)return e;var i=n-r.length;if(i<1)return r;var s=e.slice(0,i);if(null==o)return s+r;if(Rr(o)){if(e.slice(i).search(o)){var c,u,l=e.slice(0,i);for(o.global||(o=oe(o.source,(F.exec(o)||"")+"g")),o.lastIndex=0;c=o.exec(l);)u=c.index;s=s.slice(0,null==u?i:u)}}else if(e.indexOf(o,i)!=i){var d=s.lastIndexOf(o);d>-1&&(s=s.slice(0,d))}return s+r},ca.unescape=function(e){return(e=ye(e))&&P.test(e)?e.replace(K,Ee):e},ca.uniqueId=function(e){var a=++fe;return ye(e)+a},ca.words=vo,ca.all=Gn,ca.any=or,ca.contains=Yn,ca.eq=jr,ca.detect=qn,ca.foldl=tr,ca.foldr=nr,ca.head=xn,ca.include=Yn,ca.inject=tr,xo(ca,(Ao={},Ja(ca,(function(e,a){ca.prototype[a]||(Ao[a]=e)})),Ao),!1),ca.sample=rr,ca.prototype.sample=function(e){return this.__chain__||null!=e?this.thru((function(a){return rr(a,e)})):rr(this.value())},ca.VERSION="3.10.1",va(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){ca[e].placeholder=ca})),va(["drop","take"],(function(e,a){da.prototype[e]=function(t){var n=this.__filtered__;if(n&&!a)return new da(this);t=null==t?1:Qe(Ze(t)||0,0);var r=this.clone();return n?r.__takeCount__=ea(r.__takeCount__,t):r.__views__.push({size:t,type:e+(r.__dir__<0?"Right":"")}),r},da.prototype[e+"Right"]=function(a){return this.reverse()[e](a).reverse()}})),va(["filter","map","takeWhile"],(function(e,a){var t=a+1,n=2!=t;da.prototype[e]=function(e,a){var r=this.clone();return r.__iteratees__.push({iteratee:Ft(e,a,1),type:t}),r.__filtered__=r.__filtered__||n,r}})),va(["first","last"],(function(e,a){var t="take"+(a?"Right":"");da.prototype[e]=function(){return this[t](1).value()[0]}})),va(["initial","rest"],(function(e,a){var t="drop"+(a?"":"Right");da.prototype[e]=function(){return this.__filtered__?new da(this):this[t](1)}})),va(["pluck","where"],(function(e,a){var t=a?"filter":"map",n=a?Za:zo;da.prototype[e]=function(e){return this[t](n(e))}})),da.prototype.compact=function(){return this.filter(yo)},da.prototype.reject=function(e,a){return e=Ft(e,a,1),this.filter((function(a){return!e(a)}))},da.prototype.slice=function(e,a){e=null==e?0:+e||0;var t=this;return t.__filtered__&&(e>0||a<0)?new da(t):(e<0?t=t.takeRight(-e):e&&(t=t.drop(e)),void 0!==a&&(t=(a=+a||0)<0?t.dropRight(-a):t.take(a-e)),t)},da.prototype.takeRightWhile=function(e,a){return this.reverse().takeWhile(e,a).reverse()},da.prototype.toArray=function(){return this.take(oa)},Ja(da.prototype,(function(e,a){var t=/^(?:filter|map|reject)|While$/.test(a),n=/^(?:first|last)$/.test(a),r=ca[n?"take"+("last"==a?"Right":""):a];r&&(ca.prototype[a]=function(){var a=n?[1]:arguments,o=this.__chain__,i=this.__wrapped__,s=!!this.__actions__.length,c=i instanceof da,u=a[0],l=c||Mr(i);l&&t&&"function"==typeof u&&1!=u.length&&(c=l=!1);var d=function(e){return n&&o?r(e,1)[0]:r.apply(void 0,ba([e],a))},p={func:On,args:[d],thisArg:void 0},f=c&&!s;if(n&&!o)return f?((i=i.clone()).__actions__.push(p),e.call(i)):r.call(void 0,this.value())[0];if(!n&&l){i=f?i:new da(this);var m=e.apply(i,a);return m.__actions__.push(p),new la(m,o)}return this.thru(d)})})),va(["join","pop","push","replace","shift","sort","splice","split","unshift"],(function(e){var a=(/^(?:replace|split)$/.test(e)?le:ce)[e],t=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",n=/^(?:join|pop|replace|shift)$/.test(e);ca.prototype[e]=function(){var e=arguments;return n&&!this.__chain__?a.apply(this.value(),e):this[t]((function(t){return a.apply(t,e)}))}})),Ja(da.prototype,(function(e,a){var t=ca[a];if(t){var n=t.name;(sa[n]||(sa[n]=[])).push({name:a,func:t})}})),sa[Dt(void 0,2).name]=[{name:"wrapper",func:void 0}],da.prototype.clone=function(){var e=new da(this.__wrapped__);return e.__actions__=ha(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=ha(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=ha(this.__views__),e},da.prototype.reverse=function(){if(this.__filtered__){var e=new da(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},da.prototype.value=function(){var e=this.__wrapped__.value(),a=this.__dir__,t=Mr(e),n=a<0,r=t?e.length:0,o=function(e,a,t){var n=-1,r=t.length;for(;++n=16?(console.log("Selecting IndexedDb for browser"),new r(e,a,(function(t){return console.log("Failed to create IndexedDb: "+(t?t.message:void 0)),new i(e,a)}))):(console.log("Selecting LocalStorageDb for fallback"),new o(e,a,n)):new i(e,a)},a.migrateLocalDb=function(e,a,n,r){var o,i,s;for(i in o=new(t(49))(e,a),s=e.collections)s[i],a[i]&&o.addCollection(i);return o.upload(n,r)},a.cloneLocalDb=function(e,a,t,r){var o,i;for(o in i=e.collections)i[o],a[o]||a.addCollection(o);return n.each(g.values(e.collections),(function(e,t){var r;return r=a[e.name],e.find({}).fetch((function(a){return r.seed(a,(function(){return e.pendingUpserts((function(a){return r.upsert(g.pluck(a,"doc"),g.pluck(a,"base"),(function(){return e.pendingRemoves((function(e){return n.eachSeries(e,(function(e,a){return r.remove(e,(function(){return a()}),a)}),t)}),t)}),t)}),t)}),t)}),t)}),(function(e){return e?r(e):t()}))},a.cloneLocalCollection=function(e,a,t,r){return e.find({}).fetch((function(o){return a.seed(o,(function(){return e.pendingUpserts((function(o){return a.upsert(g.pluck(o,"doc"),g.pluck(o,"base"),(function(){return e.pendingRemoves((function(e){return n.eachSeries(e,(function(e,t){return a.remove(e,(function(){return t()}),t)}),(function(e){return e?r(e):t()}))}),r)}),r)}),r)}),r)}),r)},a.processFind=function(e,t,n){var r;return r=g.filter(e,c(t)),r=k(t,r),r=v(t,r),n&&n.sort&&r.sort(u(n.sort)),n&&n.skip&&(r=g.slice(r,n.skip)),n&&n.limit&&(r=g.take(r,n.limit)),n&&n.fields&&(r=a.filterFields(r,n.fields)),r},a.filterFields=function(e,a){return null==a&&(a={}),0===g.keys(a).length?e:g.map(e,(function(e){var t,n,r,o,i,s,c,u,l,d,p,f,m,h,v,k,y,b,w,S;if(n={},1===g.first(g.values(a))){for(c=0,p=(y=g.keys(a).concat(["_id"])).length;c=0})),t=g.sortBy(t,"distance"),o.$near.$maxDistance&&(t=g.filter(t,(function(e){return e.distance<=o.$near.$maxDistance}))),a=g.pluck(t,"doc")}return a},m=function(e,a){return o(e,a)},h=function(e,a){return null!=p(e,a)},d=function(e,a,t,n){var r,o,i;return 6370986,o=l(t-e),i=l(n-a),r=Math.sin(o/2)*Math.sin(o/2)+Math.cos(l(e))*Math.cos(l(t))*Math.sin(i/2)*Math.sin(i/2),6370986*(2*Math.atan2(Math.sqrt(r),Math.sqrt(1-r)))},l=function(e){return e*(Math.PI/180)},v=function(e,a){var t,n,o;for(n in e)if(null!=(o=e[n])&&o.$geoIntersects){if("Polygon"!==(t=o.$geoIntersects.$geometry).type)break;a=g.filter(a,(function(e){var a,o,s,c,u,l;if(!e[n])return!1;if("Point"===e[n].type)return m(e[n],t);if("Polygon"===(u=e[n].type)||"MultiPolygon"===u)return h(e[n],t);if("LineString"===e[n].type)return r(e[n],t)||i(e[n],t);if("MultiLineString"===e[n].type){for(s=0,c=(l=e[n].coordinates).length;s0||r0||n0}))}},$gte:function(e){return function(a){return o(a,(function(a){return LocalCollection._f._cmp(a,e)>=0}))}},$ne:function(e){return function(a){return!i(a,(function(a){return LocalCollection._f._equal(a,e)}))}},$nin:function(e){if(!r(e))throw new Error("Argument to $nin must be array");var a=u.$in(e);return function(e){return void 0===e||!a(e)}},$exists:function(e){return function(a){return e===(void 0!==a)}},$mod:function(e){var a=e[0],t=e[1];return function(e){return o(e,(function(e){return e%a===t}))}},$size:function(e){return function(a){return r(a)&&e===a.length}},$type:function(e){return function(a){return void 0!==a&&o(a,(function(a){return LocalCollection._f._type(a)===e}))}},$regex:function(e,a){if(void 0!==a){if(/[^gim]/.test(a))throw new Error("Only the i, m, and g regexp options are supported");var t=e instanceof RegExp?e.source:e;e=new RegExp(t,a)}else e instanceof RegExp||(e=new RegExp(e));return function(a){return void 0!==a&&o(a,(function(a){return e.test(a)}))}},$options:function(e){return function(e){return!0}},$elemMatch:function(e){var a=l(e);return function(e){return!!r(e)&&n.any(e,(function(e){return a(e)}))}},$not:function(e){var a=s(e);return function(e){return!a(e)}},$near:function(e){return function(e){return!0}},$geoIntersects:function(e){return function(e){return!0}}};LocalCollection._f={_type:function(e){return"number"==typeof e?1:"string"==typeof e?2:"boolean"==typeof e?8:r(e)?4:null===e?10:e instanceof RegExp?11:"function"==typeof e?13:e instanceof Date?9:EJSON.isBinary(e)?5:3},_equal:function(e,a){return EJSON.equals(e,a,{keyOrderSensitive:!0})},_typeorder:function(e){return[-1,1,2,3,4,5,-1,6,7,8,0,9,-1,100,2,100,1,8,1][e]},_cmp:function(e,a){if(void 0===e)return void 0===a?0:-1;if(void 0===a)return 1;var t=LocalCollection._f._type(e),n=LocalCollection._f._type(a),r=LocalCollection._f._typeorder(t),o=LocalCollection._f._typeorder(n);if(r!==o)return ra[s])return 1}return 0}if(8===t)return e?a?0:1:a?-1:0;if(10===t)return 0;if(11===t)throw Error("Sorting not supported on regular expression");if(13===t)throw Error("Sorting not supported on Javascript code");throw Error("Unknown type to sort")}},LocalCollection._matches=function(e,a){return LocalCollection._compileSelector(e)(a)},LocalCollection._makeLookupFunction=function(e){var a,t,o,i=e.indexOf(".");if(-1===i)a=e;else{a=e.substr(0,i);var s=e.substr(i+1);t=LocalCollection._makeLookupFunction(s),o=/^\d+(\.|$)/.test(s)}return function(e){if(null==e)return[void 0];var i=e[a];return t?r(i)&&0===i.length?[void 0]:(r(i)&&!o||(i=[i]),Array.prototype.concat.apply([],n.map(i,t))):[i]}};var l=function(e){var a=[];return n.each(e,(function(e,t){if("$"===t.substr(0,1)){if(!n.has(c,t))throw new Error("Unrecognized logical operator: "+t);a.push(c[t](e))}else{var r=LocalCollection._makeLookupFunction(t),o=s(e);a.push((function(e){var a=r(e);return n.any(a,o)}))}})),function(e){return n.all(a,(function(a){return a(e)}))}};LocalCollection._compileSelector=function(e){if(e instanceof Function)return function(a){return e.call(a)};if(LocalCollection._selectorIsId(e))return function(a){return EJSON.equals(a._id,e)};if(!e||"_id"in e&&!e._id)return function(e){return!1};if("boolean"==typeof e||r(e)||EJSON.isBinary(e))throw new Error("Invalid selector: "+e);return l(e)},LocalCollection._compileSort=function(e){var a=[];if(e instanceof Array)for(var t=0;t=0})}if(0===a.length)return function(){return 0};var i=function(e,a){var t,o=!0;return n.each(e,(function(e){r(e)||(e=[e]),r(e)&&0===e.length&&(e=[void 0]),n.each(e,(function(e){if(o)t=e,o=!1;else{var n=LocalCollection._f._cmp(t,e);(a&&n>0||!a&&n<0)&&(t=e)}}))})),t};return function(e,t){for(var n=0;n0}))}},$gte:function(e){return function(a){return o(a,(function(a){return LocalCollection._f._cmp(a,e)>=0}))}},$ne:function(e){return function(a){return!i(a,(function(a){return LocalCollection._f._equal(a,e)}))}},$nin:function(e){if(!r(e))throw new Error("Argument to $nin must be array");var a=u.$in(e);return function(e){return void 0===e||!a(e)}},$exists:function(e){return function(a){return e===(void 0!==a)}},$mod:function(e){var a=e[0],t=e[1];return function(e){return o(e,(function(e){return e%a===t}))}},$size:function(e){return function(a){return r(a)&&e===a.length}},$type:function(e){return function(a){return void 0!==a&&o(a,(function(a){return LocalCollection._f._type(a)===e}))}},$regex:function(e,a){if(void 0!==a){if(/[^gim]/.test(a))throw new Error("Only the i, m, and g regexp options are supported");var t=e instanceof RegExp?e.source:e;e=new RegExp(t,a)}else e instanceof RegExp||(e=new RegExp(e));return function(a){return void 0!==a&&o(a,(function(a){return e.test(a)}))}},$options:function(e){return function(e){return!0}},$elemMatch:function(e){var a=l(e);return function(e){return!!r(e)&&n.any(e,(function(e){return a(e)}))}},$not:function(e){var a=s(e);return function(e){return!a(e)}},$near:function(e){return function(e){return!0}},$geoIntersects:function(e){return function(e){return!0}}};LocalCollection._f={_type:function(e){return"number"==typeof e?1:"string"==typeof e?2:"boolean"==typeof e?8:r(e)?4:null===e?10:e instanceof RegExp?11:"function"==typeof e?13:e instanceof Date?9:EJSON.isBinary(e)?5:3},_equal:function(e,a){return EJSON.equals(e,a,{keyOrderSensitive:!0})},_typeorder:function(e){return[-1,1,2,3,4,5,-1,6,7,8,0,9,-1,100,2,100,1,8,1][e]},_cmp:function(e,a){if(void 0===e)return void 0===a?0:-1;if(void 0===a)return 1;var t=LocalCollection._f._type(e),n=LocalCollection._f._type(a),r=LocalCollection._f._typeorder(t),o=LocalCollection._f._typeorder(n);if(r!==o)return ra[s])return 1}return 0}if(8===t)return e?a?0:1:a?-1:0;if(10===t)return 0;if(11===t)throw Error("Sorting not supported on regular expression");if(13===t)throw Error("Sorting not supported on Javascript code");throw Error("Unknown type to sort")}},LocalCollection._matches=function(e,a){return LocalCollection._compileSelector(e)(a)},LocalCollection._makeLookupFunction=function(e){var a,t,o,i=e.indexOf(".");if(-1===i)a=e;else{a=e.substr(0,i);var s=e.substr(i+1);t=LocalCollection._makeLookupFunction(s),o=/^\d+(\.|$)/.test(s)}return function(e){if(null==e)return[void 0];var i=e[a];return t?r(i)&&0===i.length?[void 0]:(r(i)&&!o||(i=[i]),Array.prototype.concat.apply([],n.map(i,t))):[i]}};var l=function(e){var a=[];return n.each(e,(function(e,t){if("$"===t.substr(0,1)){if(!n.has(c,t))throw new Error("Unrecognized logical operator: "+t);a.push(c[t](e))}else{var r=LocalCollection._makeLookupFunction(t),o=s(e);a.push((function(e){var a=r(e);return n.any(a,o)}))}})),function(e){return n.all(a,(function(a){return a(e)}))}};LocalCollection._compileSelector=function(e){if(e instanceof Function)return function(a){return e.call(a)};if(LocalCollection._selectorIsId(e))return function(a){return EJSON.equals(a._id,e)};if(!e||"_id"in e&&!e._id)return function(e){return!1};if("boolean"==typeof e||r(e)||EJSON.isBinary(e))throw new Error("Invalid selector: "+e);return l(e)},LocalCollection._compileSort=function(e){var a=[];if(e instanceof Array)for(var t=0;t=0})}if(0===a.length)return function(){return 0};var i=function(e,a){var t,o=!0;return n.each(e,(function(e){r(e)||(e=[e]),r(e)&&0===e.length&&(e=[void 0]),n.each(e,(function(e){if(o)t=e,o=!1;else{var n=LocalCollection._f._cmp(t,e);(a&&n>0||!a&&n<0)&&(t=e)}}))})),t};return function(e,t){for(var n=0;n=2&&!Array.isArray(e[0])&&!Array.isArray(e[1]))return e;throw new Error("coord must be GeoJSON Point or an Array of numbers")},a.getCoords=function(e){if(Array.isArray(e))return e;if("Feature"===e.type){if(null!==e.geometry)return e.geometry.coordinates}else if(e.coordinates)return e.coordinates;throw new Error("coords must be GeoJSON Feature, Geometry Object or an Array")},a.containsNumber=function e(a){if(a.length>1&&n.isNumber(a[0])&&n.isNumber(a[1]))return!0;if(Array.isArray(a[0])&&a[0].length)return e(a[0]);throw new Error("coordinates must only contain numbers")},a.geojsonType=function(e,a,t){if(!a||!t)throw new Error("type and name required");if(!e||e.type!==a)throw new Error("Invalid input to "+t+": must be a "+a+", given "+e.type)},a.featureOf=function(e,a,t){if(!e)throw new Error("No feature passed");if(!t)throw new Error(".featureOf() requires a name");if(!e||"Feature"!==e.type||!e.geometry)throw new Error("Invalid input to "+t+", Feature with geometry required");if(!e.geometry||e.geometry.type!==a)throw new Error("Invalid input to "+t+": must be a "+a+", given "+e.geometry.type)},a.collectionOf=function(e,a,t){if(!e)throw new Error("No featureCollection passed");if(!t)throw new Error(".collectionOf() requires a name");if(!e||"FeatureCollection"!==e.type)throw new Error("Invalid input to "+t+", FeatureCollection required");for(var n=0,r=e.features;n=0))throw new Error("precision must be a positive number");var t=Math.pow(10,a||0);return Math.round(e*t)/t},a.radiansToLength=d,a.lengthToRadians=p,a.lengthToDegrees=function(e,a){return f(p(e,a))},a.bearingToAzimuth=function(e){var a=e%360;return a<0&&(a+=360),a},a.radiansToDegrees=f,a.degreesToRadians=function(e){return e%360*Math.PI/180},a.convertLength=function(e,a,t){if(void 0===a&&(a="kilometers"),void 0===t&&(t="kilometers"),!(e>=0))throw new Error("length must be a positive number");return d(p(e,a),t)},a.convertArea=function(e,t,n){if(void 0===t&&(t="meters"),void 0===n&&(n="kilometers"),!(e>=0))throw new Error("area must be a positive number");var r=a.areaFactors[t];if(!r)throw new Error("invalid original units");var o=a.areaFactors[n];if(!o)throw new Error("invalid final units");return e/r*o},a.isNumber=m,a.isObject=function(e){return!!e&&e.constructor===Object},a.validateBBox=function(e){if(!e)throw new Error("bbox is required");if(!Array.isArray(e))throw new Error("bbox must be an Array");if(4!==e.length&&6!==e.length)throw new Error("bbox must be an Array of 4 or 6 numbers");e.forEach((function(e){if(!m(e))throw new Error("bbox must only contain numbers")}))},a.validateId=function(e){if(!e)throw new Error("id is required");if(-1===["string","number"].indexOf(typeof e))throw new Error("id must be a number or a string")},a.radians2degrees=function(){throw new Error("method has been renamed to `radiansToDegrees`")},a.degrees2radians=function(){throw new Error("method has been renamed to `degreesToRadians`")},a.distanceToDegrees=function(){throw new Error("method has been renamed to `lengthToDegrees`")},a.distanceToRadians=function(){throw new Error("method has been renamed to `lengthToRadians`")},a.radiansToDistance=function(){throw new Error("method has been renamed to `radiansToLength`")},a.bearingToAngle=function(){throw new Error("method has been renamed to `bearingToAzimuth`")},a.convertDistance=function(){throw new Error("method has been renamed to `convertLength`")}},function(e,a,t){(function(e){var n=Object.getOwnPropertyDescriptors||function(e){for(var a=Object.keys(e),t={},n=0;n=o)return e;switch(e){case"%s":return String(n[t++]);case"%d":return Number(n[t++]);case"%j":try{return JSON.stringify(n[t++])}catch(e){return"[Circular]"}default:return e}})),c=n[t];t=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),m(t)?n.showHidden=t:t&&a._extend(n,t),g(n.showHidden)&&(n.showHidden=!1),g(n.depth)&&(n.depth=2),g(n.colors)&&(n.colors=!1),g(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=c),l(n,e,n.depth)}function c(e,a){var t=s.styles[a];return t?"["+s.colors[t][0]+"m"+e+"["+s.colors[t][1]+"m":e}function u(e,a){return e}function l(e,t,n){if(e.customInspect&&t&&x(t.inspect)&&t.inspect!==a.inspect&&(!t.constructor||t.constructor.prototype!==t)){var r=t.inspect(n,e);return k(r)||(r=l(e,r,n)),r}var o=function(e,a){if(g(a))return e.stylize("undefined","undefined");if(k(a)){var t="'"+JSON.stringify(a).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(t,"string")}if(v(a))return e.stylize(""+a,"number");if(m(a))return e.stylize(""+a,"boolean");if(h(a))return e.stylize("null","null")}(e,t);if(o)return o;var i=Object.keys(t),s=function(e){var a={};return e.forEach((function(e,t){a[e]=!0})),a}(i);if(e.showHidden&&(i=Object.getOwnPropertyNames(t)),S(t)&&(i.indexOf("message")>=0||i.indexOf("description")>=0))return d(t);if(0===i.length){if(x(t)){var c=t.name?": "+t.name:"";return e.stylize("[Function"+c+"]","special")}if(y(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");if(w(t))return e.stylize(Date.prototype.toString.call(t),"date");if(S(t))return d(t)}var u,b="",_=!1,z=["{","}"];(f(t)&&(_=!0,z=["[","]"]),x(t))&&(b=" [Function"+(t.name?": "+t.name:"")+"]");return y(t)&&(b=" "+RegExp.prototype.toString.call(t)),w(t)&&(b=" "+Date.prototype.toUTCString.call(t)),S(t)&&(b=" "+d(t)),0!==i.length||_&&0!=t.length?n<0?y(t)?e.stylize(RegExp.prototype.toString.call(t),"regexp"):e.stylize("[Object]","special"):(e.seen.push(t),u=_?function(e,a,t,n,r){for(var o=[],i=0,s=a.length;i=0&&0,e+a.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60)return t[0]+(""===a?"":a+"\n ")+" "+e.join(",\n ")+" "+t[1];return t[0]+a+" "+e.join(", ")+" "+t[1]}(u,b,z)):z[0]+b+z[1]}function d(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,a,t,n,r,o){var i,s,c;if((c=Object.getOwnPropertyDescriptor(a,r)||{value:a[r]}).get?s=c.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):c.set&&(s=e.stylize("[Setter]","special")),j(n,r)||(i="["+r+"]"),s||(e.seen.indexOf(c.value)<0?(s=h(t)?l(e,c.value,null):l(e,c.value,t-1)).indexOf("\n")>-1&&(s=o?s.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+s.split("\n").map((function(e){return" "+e})).join("\n")):s=e.stylize("[Circular]","special")),g(i)){if(o&&r.match(/^\d+$/))return s;(i=JSON.stringify(""+r)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(i=i.substr(1,i.length-2),i=e.stylize(i,"name")):(i=i.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),i=e.stylize(i,"string"))}return i+": "+s}function f(e){return Array.isArray(e)}function m(e){return"boolean"==typeof e}function h(e){return null===e}function v(e){return"number"==typeof e}function k(e){return"string"==typeof e}function g(e){return void 0===e}function y(e){return b(e)&&"[object RegExp]"===_(e)}function b(e){return"object"==typeof e&&null!==e}function w(e){return b(e)&&"[object Date]"===_(e)}function S(e){return b(e)&&("[object Error]"===_(e)||e instanceof Error)}function x(e){return"function"==typeof e}function _(e){return Object.prototype.toString.call(e)}function z(e){return e<10?"0"+e.toString(10):e.toString(10)}a.debuglog=function(t){if(g(o)&&(o=e.env.NODE_DEBUG||""),t=t.toUpperCase(),!i[t])if(new RegExp("\\b"+t+"\\b","i").test(o)){var n=e.pid;i[t]=function(){var e=a.format.apply(a,arguments);console.error("%s %d: %s",t,n,e)}}else i[t]=function(){};return i[t]},a.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},a.isArray=f,a.isBoolean=m,a.isNull=h,a.isNullOrUndefined=function(e){return null==e},a.isNumber=v,a.isString=k,a.isSymbol=function(e){return"symbol"==typeof e},a.isUndefined=g,a.isRegExp=y,a.isObject=b,a.isDate=w,a.isError=S,a.isFunction=x,a.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},a.isBuffer=t(122);var A=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function M(){var e=new Date,a=[z(e.getHours()),z(e.getMinutes()),z(e.getSeconds())].join(":");return[e.getDate(),A[e.getMonth()],a].join(" ")}function j(e,a){return Object.prototype.hasOwnProperty.call(e,a)}a.log=function(){console.log("%s - %s",M(),a.format.apply(a,arguments))},a.inherits=t(123),a._extend=function(e,a){if(!a||!b(a))return e;for(var t=Object.keys(a),n=t.length;n--;)e[t[n]]=a[t[n]];return e};var B="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function K(e,a){if(!e){var t=new Error("Promise was rejected with a falsy value");t.reason=e,e=t}return a(e)}a.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(B&&e[B]){var a;if("function"!=typeof(a=e[B]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(a,B,{value:a,enumerable:!1,writable:!1,configurable:!0}),a}function a(){for(var a,t,n=new Promise((function(e,n){a=e,t=n})),r=[],o=0;o=0&&e.length%1==0}function g(e,a){for(var t=-1,n=e.length;++t3?e(n,r,c,s):(i=o,o=r,e(n,c,s))}}function T(e,a){return a}function H(e,a,t){t=t||c;var n=k(a)?[]:{};e(a,(function(e,a,t){e(A((function(e,r){r.length<=1&&(r=r[0]),n[a]=r,t(e)})))}),(function(e){t(e,n)}))}function O(e,a,t,n){var r=[];e(a,(function(e,a,n){t(e,(function(e,a){r=r.concat(a||[]),n(e)}))}),(function(e){n(e,r)}))}function V(e,a,t){if(null==a)a=1;else if(0===a)throw new Error("Concurrency must not be zero");function n(e,a,t,n){if(null!=n&&"function"!=typeof n)throw new Error("task callback must be a function");if(e.started=!0,v(a)||(a=[a]),0===a.length&&e.idle())return s.setImmediate((function(){e.drain()}));g(a,(function(a){var r={data:a,callback:n||c};t?e.tasks.unshift(r):e.tasks.push(r),e.tasks.length===e.concurrency&&e.saturated()})),s.setImmediate(e.process)}function r(e,a){return function(){o-=1;var t=!1,n=arguments;g(a,(function(e){g(i,(function(a,n){a!==e||t||(i.splice(n,1),t=!0)})),e.callback.apply(e,n)})),e.tasks.length+o===0&&e.drain(),e.process()}}var o=0,i=[],u={tasks:[],concurrency:a,payload:t,saturated:c,empty:c,drain:c,started:!1,paused:!1,push:function(e,a){n(u,e,!1,a)},kill:function(){u.drain=c,u.tasks=[]},unshift:function(e,a){n(u,e,!0,a)},process:function(){for(;!u.paused&&on?1:0}s.map(e,(function(e,t){a(e,(function(a,n){a?t(a):t(null,{value:e,criteria:n})}))}),(function(e,a){if(e)return t(e);t(null,y(a.sort(n),(function(e){return e.value})))}))},s.auto=function(e,a,t){"function"==typeof arguments[1]&&(t=a,a=null),t=m(t||c);var n=_(e),r=n.length;if(!r)return t(null);a||(a=r);var o={},i=0,u=!1,l=[];function d(e){l.unshift(e)}function p(e){var a=x(l,e);a>=0&&l.splice(a,1)}function f(){r--,g(l.slice(0),(function(e){e()}))}d((function(){r||t(null,o)})),g(n,(function(n){if(!u){for(var r,c=v(e[n])?e[n]:[e[n]],l=A((function(e,a){if(i--,a.length<=1&&(a=a[0]),e){var r={};S(o,(function(e,a){r[a]=e})),r[n]=a,u=!0,t(e,r)}else o[n]=a,s.setImmediate(f)})),m=c.slice(0,c.length-1),h=m.length;h--;){if(!(r=e[m[h]]))throw new Error("Has nonexistent dependency in "+m.join(", "));if(v(r)&&x(r,n)>=0)throw new Error("Has cyclic dependencies")}k()?(i++,c[c.length-1](l,o)):d((function e(){k()&&(i++,p(e),c[c.length-1](l,o))}))}function k(){return i3)throw new Error("Invalid arguments - must be either (task), (task, callback), (times, task) or (times, task, callback)");function l(e,a){function t(e,t){return function(n){e((function(e,a){n(!e||t,{err:e,result:a})}),a)}}function n(e){return function(a){setTimeout((function(){a(null)}),e)}}for(;i.times;){var r=!(i.times-=1);o.push(t(i.task,r)),!r&&i.interval>0&&o.push(n(i.interval))}s.series(o,(function(a,t){t=t[t.length-1],(e||i.callback)(t.err,t.result)}))}return u<=2&&"function"==typeof e&&(t=a,a=e),"function"!=typeof e&&c(i,e),i.callback=t,i.task=a,i.callback?l():l},s.waterfall=function(e,a){if(a=m(a||c),!v(e)){var t=new Error("First argument to waterfall must be an array of functions");return a(t)}if(!e.length)return a();!function e(t){return A((function(n,r){if(n)a.apply(null,[n].concat(r));else{var o=t.next();o?r.push(e(o)):r.push(a),F(t).apply(null,r)}}))}(s.iterator(e))()},s.parallel=function(e,a){H(s.eachOf,e,a)},s.parallelLimit=function(e,a,t){H(K(a),e,t)},s.series=function(e,a){H(s.eachOfSeries,e,a)},s.iterator=function(e){return function a(t){function n(){return e.length&&e[t].apply(null,arguments),n.next()}return n.next=function(){return t>>1);t(a,e[o])>=0?n=o:r=o-1}return n}(e.tasks,o,t)+1,0,o),e.tasks.length===e.concurrency&&e.saturated(),s.setImmediate(e.process)}))}(n,e,a,r)},delete n.unshift,n},s.cargo=function(e,a){return V(e,1,a)},s.log=J("log"),s.dir=J("dir"),s.memoize=function(e,a){var t={},n={},r=Object.prototype.hasOwnProperty;a=a||u;var o=A((function(o){var i=o.pop(),c=a.apply(null,o);r.call(t,c)?s.setImmediate((function(){i.apply(null,t[c])})):r.call(n,c)?n[c].push(i):(n[c]=[i],e.apply(null,o.concat([A((function(e){t[c]=e;var a=n[c];delete n[c];for(var r=0,o=a.length;r2?"one of ".concat(a," ").concat(e.slice(0,t-1).join(", "),", or ")+e[t-1]:2===t?"one of ".concat(a," ").concat(e[0]," or ").concat(e[1]):"of ".concat(a," ").concat(e[0])}return"of ".concat(a," ").concat(String(e))}r("ERR_INVALID_OPT_VALUE",(function(e,a){return'The value "'+a+'" is invalid for option "'+e+'"'}),TypeError),r("ERR_INVALID_ARG_TYPE",(function(e,a,t){var n,r,i,s;if("string"==typeof a&&(r="not ",a.substr(!i||i<0?0:+i,r.length)===r)?(n="must not be",a=a.replace(/^not /,"")):n="must be",function(e,a,t){return(void 0===t||t>e.length)&&(t=e.length),e.substring(t-a.length,t)===a}(e," argument"))s="The ".concat(e," ").concat(n," ").concat(o(a,"type"));else{var c=function(e,a,t){return"number"!=typeof t&&(t=0),!(t+a.length>e.length)&&-1!==e.indexOf(a,t)}(e,".")?"property":"argument";s='The "'.concat(e,'" ').concat(c," ").concat(n," ").concat(o(a,"type"))}return s+=". Received type ".concat(typeof t)}),TypeError),r("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),r("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),r("ERR_STREAM_PREMATURE_CLOSE","Premature close"),r("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),r("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),r("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),r("ERR_STREAM_WRITE_AFTER_END","write after end"),r("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),r("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),r("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.codes=n},function(e,a,t){"use strict";(function(a){var n=Object.keys||function(e){var a=[];for(var t in e)a.push(t);return a};e.exports=u;var r=t(63),o=t(67);t(0)(u,r);for(var i=n(o.prototype),s=0;s>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e){var a=this.lastTotal-this.lastNeed,t=function(e,a,t){if(128!=(192&a[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&a.length>1){if(128!=(192&a[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&a.length>2&&128!=(192&a[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==t?t:this.lastNeed<=e.length?(e.copy(this.lastChar,a,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,a,0,e.length),void(this.lastNeed-=e.length))}function c(e,a){if((e.length-a)%2==0){var t=e.toString("utf16le",a);if(t){var n=t.charCodeAt(t.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],t.slice(0,-1)}return t}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",a,e.length-1)}function u(e){var a=e&&e.length?this.write(e):"";if(this.lastNeed){var t=this.lastTotal-this.lastNeed;return a+this.lastChar.toString("utf16le",0,t)}return a}function l(e,a){var t=(e.length-a)%3;return 0===t?e.toString("base64",a):(this.lastNeed=3-t,this.lastTotal=3,1===t?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",a,e.length-t))}function d(e){var a=e&&e.length?this.write(e):"";return this.lastNeed?a+this.lastChar.toString("base64",0,3-this.lastNeed):a}function p(e){return e.toString(this.encoding)}function f(e){return e&&e.length?this.write(e):""}a.StringDecoder=o,o.prototype.write=function(e){if(0===e.length)return"";var a,t;if(this.lastNeed){if(void 0===(a=this.fillLast(e)))return"";t=this.lastNeed,this.lastNeed=0}else t=0;return t=0)return r>0&&(e.lastNeed=r-1),r;if(--n=0)return r>0&&(e.lastNeed=r-2),r;if(--n=0)return r>0&&(2===r?r=0:e.lastNeed=r-3),r;return 0}(this,e,a);if(!this.lastNeed)return e.toString("utf8",a);this.lastTotal=t;var n=e.length-(t-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",a,n)},o.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},function(e,a,t){(function(){var t=this,n=t._,r={},o=Array.prototype,i=Object.prototype,s=Function.prototype,c=o.push,u=o.slice,l=o.concat,d=i.toString,p=i.hasOwnProperty,f=o.forEach,m=o.map,h=o.reduce,v=o.reduceRight,k=o.filter,g=o.every,y=o.some,b=o.indexOf,w=o.lastIndexOf,S=Array.isArray,x=Object.keys,_=s.bind,z=function(e){return e instanceof z?e:this instanceof z?void(this._wrapped=e):new z(e)};e.exports&&(a=e.exports=z),a._=z,z.VERSION="1.4.4";var A=z.each=z.forEach=function(e,a,t){if(null!=e)if(f&&e.forEach===f)e.forEach(a,t);else if(e.length===+e.length){for(var n=0,o=e.length;n2;if(null==e&&(e=[]),h&&e.reduce===h)return n&&(a=z.bind(a,n)),r?e.reduce(a,t):e.reduce(a);if(A(e,(function(e,o,i){r?t=a.call(n,t,e,o,i):(t=e,r=!0)})),!r)throw new TypeError(M);return t},z.reduceRight=z.foldr=function(e,a,t,n){var r=arguments.length>2;if(null==e&&(e=[]),v&&e.reduceRight===v)return n&&(a=z.bind(a,n)),r?e.reduceRight(a,t):e.reduceRight(a);var o=e.length;if(o!==+o){var i=z.keys(e);o=i.length}if(A(e,(function(s,c,u){c=i?i[--o]:--o,r?t=a.call(n,t,e[c],c,u):(t=e[c],r=!0)})),!r)throw new TypeError(M);return t},z.find=z.detect=function(e,a,t){var n;return j(e,(function(e,r,o){if(a.call(t,e,r,o))return n=e,!0})),n},z.filter=z.select=function(e,a,t){var n=[];return null==e?n:k&&e.filter===k?e.filter(a,t):(A(e,(function(e,r,o){a.call(t,e,r,o)&&(n[n.length]=e)})),n)},z.reject=function(e,a,t){return z.filter(e,(function(e,n,r){return!a.call(t,e,n,r)}),t)},z.every=z.all=function(e,a,t){a||(a=z.identity);var n=!0;return null==e?n:g&&e.every===g?e.every(a,t):(A(e,(function(e,o,i){if(!(n=n&&a.call(t,e,o,i)))return r})),!!n)};var j=z.some=z.any=function(e,a,t){a||(a=z.identity);var n=!1;return null==e?n:y&&e.some===y?e.some(a,t):(A(e,(function(e,o,i){if(n||(n=a.call(t,e,o,i)))return r})),!!n)};z.contains=z.include=function(e,a){return null!=e&&(b&&e.indexOf===b?-1!=e.indexOf(a):j(e,(function(e){return e===a})))},z.invoke=function(e,a){var t=u.call(arguments,2),n=z.isFunction(a);return z.map(e,(function(e){return(n?a:e[a]).apply(e,t)}))},z.pluck=function(e,a){return z.map(e,(function(e){return e[a]}))},z.where=function(e,a,t){return z.isEmpty(a)?t?null:[]:z[t?"find":"filter"](e,(function(e){for(var t in a)if(a[t]!==e[t])return!1;return!0}))},z.findWhere=function(e,a){return z.where(e,a,!0)},z.max=function(e,a,t){if(!a&&z.isArray(e)&&e[0]===+e[0]&&e.length<65535)return Math.max.apply(Math,e);if(!a&&z.isEmpty(e))return-1/0;var n={computed:-1/0,value:-1/0};return A(e,(function(e,r,o){var i=a?a.call(t,e,r,o):e;i>=n.computed&&(n={value:e,computed:i})})),n.value},z.min=function(e,a,t){if(!a&&z.isArray(e)&&e[0]===+e[0]&&e.length<65535)return Math.min.apply(Math,e);if(!a&&z.isEmpty(e))return 1/0;var n={computed:1/0,value:1/0};return A(e,(function(e,r,o){var i=a?a.call(t,e,r,o):e;in||void 0===t)return 1;if(t>>1;t.call(n,e[s])=0}))}))},z.difference=function(e){var a=l.apply(o,u.call(arguments,1));return z.filter(e,(function(e){return!z.contains(a,e)}))},z.zip=function(){for(var e=u.call(arguments),a=z.max(z.pluck(e,"length")),t=new Array(a),n=0;n=0;t--)a=[e[t].apply(this,a)];return a[0]}},z.after=function(e,a){return e<=0?a():function(){if(--e<1)return a.apply(this,arguments)}},z.keys=x||function(e){if(e!==Object(e))throw new TypeError("Invalid object");var a=[];for(var t in e)z.has(e,t)&&(a[a.length]=t);return a},z.values=function(e){var a=[];for(var t in e)z.has(e,t)&&a.push(e[t]);return a},z.pairs=function(e){var a=[];for(var t in e)z.has(e,t)&&a.push([t,e[t]]);return a},z.invert=function(e){var a={};for(var t in e)z.has(e,t)&&(a[e[t]]=t);return a},z.functions=z.methods=function(e){var a=[];for(var t in e)z.isFunction(e[t])&&a.push(t);return a.sort()},z.extend=function(e){return A(u.call(arguments,1),(function(a){if(a)for(var t in a)e[t]=a[t]})),e},z.pick=function(e){var a={},t=l.apply(o,u.call(arguments,1));return A(t,(function(t){t in e&&(a[t]=e[t])})),a},z.omit=function(e){var a={},t=l.apply(o,u.call(arguments,1));for(var n in e)z.contains(t,n)||(a[n]=e[n]);return a},z.defaults=function(e){return A(u.call(arguments,1),(function(a){if(a)for(var t in a)null==e[t]&&(e[t]=a[t])})),e},z.clone=function(e){return z.isObject(e)?z.isArray(e)?e.slice():z.extend({},e):e},z.tap=function(e,a){return a(e),e};var P=function(e,a,t,n){if(e===a)return 0!==e||1/e==1/a;if(null==e||null==a)return e===a;e instanceof z&&(e=e._wrapped),a instanceof z&&(a=a._wrapped);var r=d.call(e);if(r!=d.call(a))return!1;switch(r){case"[object String]":return e==String(a);case"[object Number]":return e!=+e?a!=+a:0==e?1/e==1/a:e==+a;case"[object Date]":case"[object Boolean]":return+e==+a;case"[object RegExp]":return e.source==a.source&&e.global==a.global&&e.multiline==a.multiline&&e.ignoreCase==a.ignoreCase}if("object"!=typeof e||"object"!=typeof a)return!1;for(var o=t.length;o--;)if(t[o]==e)return n[o]==a;t.push(e),n.push(a);var i=0,s=!0;if("[object Array]"==r){if(s=(i=e.length)==a.length)for(;i--&&(s=P(e[i],a[i],t,n)););}else{var c=e.constructor,u=a.constructor;if(c!==u&&!(z.isFunction(c)&&c instanceof c&&z.isFunction(u)&&u instanceof u))return!1;for(var l in e)if(z.has(e,l)&&(i++,!(s=z.has(a,l)&&P(e[l],a[l],t,n))))break;if(s){for(l in a)if(z.has(a,l)&&!i--)break;s=!i}}return t.pop(),n.pop(),s};z.isEqual=function(e,a){return P(e,a,[],[])},z.isEmpty=function(e){if(null==e)return!0;if(z.isArray(e)||z.isString(e))return 0===e.length;for(var a in e)if(z.has(e,a))return!1;return!0},z.isElement=function(e){return!(!e||1!==e.nodeType)},z.isArray=S||function(e){return"[object Array]"==d.call(e)},z.isObject=function(e){return e===Object(e)},A(["Arguments","Function","String","Number","Date","RegExp"],(function(e){z["is"+e]=function(a){return d.call(a)=="[object "+e+"]"}})),z.isArguments(arguments)||(z.isArguments=function(e){return!(!e||!z.has(e,"callee"))}),z.isFunction=function(e){return"function"==typeof e},z.isFinite=function(e){return isFinite(e)&&!isNaN(parseFloat(e))},z.isNaN=function(e){return z.isNumber(e)&&e!=+e},z.isBoolean=function(e){return!0===e||!1===e||"[object Boolean]"==d.call(e)},z.isNull=function(e){return null===e},z.isUndefined=function(e){return void 0===e},z.has=function(e,a){return p.call(e,a)},z.noConflict=function(){return t._=n,this},z.identity=function(e){return e},z.times=function(e,a,t){for(var n=Array(e),r=0;r":">",'"':""","'":"'","/":"/"}};E.unescape=z.invert(E.escape);var L={escape:new RegExp("["+z.keys(E.escape).join("")+"]","g"),unescape:new RegExp("("+z.keys(E.unescape).join("|")+")","g")};z.each(["escape","unescape"],(function(e){z[e]=function(a){return null==a?"":(""+a).replace(L[e],(function(a){return E[e][a]}))}})),z.result=function(e,a){if(null==e)return null;var t=e[a];return z.isFunction(t)?t.call(e):t},z.mixin=function(e){A(z.functions(e),(function(a){var t=z[a]=e[a];z.prototype[a]=function(){var e=[this._wrapped];return c.apply(e,arguments),H.call(this,t.apply(z,e))}}))};var R=0;z.uniqueId=function(e){var a=++R+"";return e?e+a:a},z.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var C=/(.)^/,D={"'":"'","\\":"\\","\r":"r","\n":"n","\t":"t","\u2028":"u2028","\u2029":"u2029"},T=/\\|'|\r|\n|\t|\u2028|\u2029/g;z.template=function(e,a,t){var n;t=z.defaults({},t,z.templateSettings);var r=new RegExp([(t.escape||C).source,(t.interpolate||C).source,(t.evaluate||C).source].join("|")+"|$","g"),o=0,i="__p+='";e.replace(r,(function(a,t,n,r,s){return i+=e.slice(o,s).replace(T,(function(e){return"\\"+D[e]})),t&&(i+="'+\n((__t=("+t+"))==null?'':_.escape(__t))+\n'"),n&&(i+="'+\n((__t=("+n+"))==null?'':__t)+\n'"),r&&(i+="';\n"+r+"\n__p+='"),o=s+a.length,a})),i+="';\n",t.variable||(i="with(obj||{}){\n"+i+"}\n"),i="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+i+"return __p;\n";try{n=new Function(t.variable||"obj","_",i)}catch(e){throw e.source=i,e}if(a)return n(a,z);var s=function(e){return n.call(this,e,z)};return s.source="function("+(t.variable||"obj")+"){\n"+i+"}",s},z.chain=function(e){return z(e).chain()};var H=function(e){return this._chain?z(e).chain():e};z.mixin(z),A(["pop","push","reverse","shift","sort","splice","unshift"],(function(e){var a=o[e];z.prototype[e]=function(){var t=this._wrapped;return a.apply(t,arguments),"shift"!=e&&"splice"!=e||0!==t.length||delete t[0],H.call(this,t)}})),A(["concat","join","slice"],(function(e){var a=o[e];z.prototype[e]=function(){return H.call(this,a.apply(this._wrapped,arguments))}})),z.extend(z.prototype,{chain:function(){return this._chain=!0,this},value:function(){return this._wrapped}})}).call(this)},function(e,a,t){(function(e){var n=void 0!==e&&e||"undefined"!=typeof self&&self||window,r=Function.prototype.apply;function o(e,a){this._id=e,this._clearFn=a}a.setTimeout=function(){return new o(r.call(setTimeout,n,arguments),clearTimeout)},a.setInterval=function(){return new o(r.call(setInterval,n,arguments),clearInterval)},a.clearTimeout=a.clearInterval=function(e){e&&e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(n,this._id)},a.enroll=function(e,a){clearTimeout(e._idleTimeoutId),e._idleTimeout=a},a.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},a._unrefActive=a.active=function(e){clearTimeout(e._idleTimeoutId);var a=e._idleTimeout;a>=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),a))},t(95),a.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,a.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,t(4))},function(e,a,t){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=t(15);function r(e,a,t){if(null!==e)for(var n,o,i,s,c,u,l,d,p=0,f=0,m=e.type,h="FeatureCollection"===m,v="Feature"===m,k=h?e.features.length:1,g=0;gu||f>l||m>d)return c=r,u=t,l=f,d=m,void(i=0);var h=n.lineString([c,r],e.properties);if(!1===a(h,t,o,m,i))return!1;i++,c=r}))&&void 0}}}))}function l(e,a){if(!e)throw new Error("geojson is required");c(e,(function(e,t,r){if(null!==e.geometry){var o=e.geometry.type,i=e.geometry.coordinates;switch(o){case"LineString":if(!1===a(e,t,r,0,0))return!1;break;case"Polygon":for(var s=0;sa?1:0}function h(e,a){var t,n;for(t=0;t0){for(i=0;i=3||2===Object.keys(t).length&&void 0===t.$slice)throw new Error("Can only use $slice in cunjunction with $each when $push to array");if(!n.isArray(t.$each))throw new Error("$each requires an array value");if(t.$each.forEach((function(t){e[a].push(t)})),void 0===t.$slice||"number"!=typeof t.$slice)return;if(0===t.$slice)e[a]=[];else{var r,o,i=e[a].length;t.$slice<0?(r=Math.max(0,i+t.$slice),o=i):t.$slice>0&&(r=0,o=Math.min(i,t.$slice)),e[a]=e[a].slice(r,o)}}else e[a].push(t)},i.$addToSet=function(e,a,t){var r=!0;if(e.hasOwnProperty(a)||(e[a]=[]),!n.isArray(e[a]))throw new Error("Can't $addToSet an element on non-array values");if(null!==t&&"object"==typeof t&&t.$each){if(Object.keys(t).length>1)throw new Error("Can't use another field in conjunction with $each");if(!n.isArray(t.$each))throw new Error("$each requires an array value");t.$each.forEach((function(t){i.$addToSet(e,a,t)}))}else e[a].forEach((function(e){0===v(e,t)&&(r=!1)})),r&&e[a].push(t)},i.$pop=function(e,a,t){if(!n.isArray(e[a]))throw new Error("Can't $pop an element from non-array values");if("number"!=typeof t)throw new Error(t+" isn't an integer, can't use it with $pop");0!==t&&(e[a]=t>0?e[a].slice(0,e[a].length-1):e[a].slice(1))},i.$pull=function(e,a,t){var r,o;if(!n.isArray(e[a]))throw new Error("Can't $pull an element from non-array values");for(o=(r=e[a]).length-1;o>=0;o-=1)b(r[o],t)&&r.splice(o,1)},i.$inc=function(e,a,t){if("number"!=typeof t)throw new Error(t+" must be a number");if("number"!=typeof e[a]){if(r.has(e,a))throw new Error("Don't use the $inc modifier on non-number fields");e[a]=t}else e[a]+=t},i.$max=function(e,a,t){(void 0===e[a]||t>e[a])&&(e[a]=t)},i.$min=function(e,a,t){(void 0===e[a]||ta},s.$gte=function(e,a){return y(e,a)&&e>=a},s.$ne=function(e,a){return void 0===e||!g(e,a)},s.$in=function(e,a){var t;if(!n.isArray(a))throw new Error("$in operator called with a non-array");for(t=0;t>>25)+n|0)&n|~t&r)+a[1]-389564586|0)<<12|o>>>20)+t|0)&t|~o&n)+a[2]+606105819|0)<<17|r>>>15)+o|0)&o|~r&t)+a[3]-1044525330|0)<<22|n>>>10)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n&r|~n&o)+a[4]-176418897|0)<<7|t>>>25)+n|0)&n|~t&r)+a[5]+1200080426|0)<<12|o>>>20)+t|0)&t|~o&n)+a[6]-1473231341|0)<<17|r>>>15)+o|0)&o|~r&t)+a[7]-45705983|0)<<22|n>>>10)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n&r|~n&o)+a[8]+1770035416|0)<<7|t>>>25)+n|0)&n|~t&r)+a[9]-1958414417|0)<<12|o>>>20)+t|0)&t|~o&n)+a[10]-42063|0)<<17|r>>>15)+o|0)&o|~r&t)+a[11]-1990404162|0)<<22|n>>>10)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n&r|~n&o)+a[12]+1804603682|0)<<7|t>>>25)+n|0)&n|~t&r)+a[13]-40341101|0)<<12|o>>>20)+t|0)&t|~o&n)+a[14]-1502002290|0)<<17|r>>>15)+o|0)&o|~r&t)+a[15]+1236535329|0)<<22|n>>>10)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n&o|r&~o)+a[1]-165796510|0)<<5|t>>>27)+n|0)&r|n&~r)+a[6]-1069501632|0)<<9|o>>>23)+t|0)&n|t&~n)+a[11]+643717713|0)<<14|r>>>18)+o|0)&t|o&~t)+a[0]-373897302|0)<<20|n>>>12)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n&o|r&~o)+a[5]-701558691|0)<<5|t>>>27)+n|0)&r|n&~r)+a[10]+38016083|0)<<9|o>>>23)+t|0)&n|t&~n)+a[15]-660478335|0)<<14|r>>>18)+o|0)&t|o&~t)+a[4]-405537848|0)<<20|n>>>12)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n&o|r&~o)+a[9]+568446438|0)<<5|t>>>27)+n|0)&r|n&~r)+a[14]-1019803690|0)<<9|o>>>23)+t|0)&n|t&~n)+a[3]-187363961|0)<<14|r>>>18)+o|0)&t|o&~t)+a[8]+1163531501|0)<<20|n>>>12)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n&o|r&~o)+a[13]-1444681467|0)<<5|t>>>27)+n|0)&r|n&~r)+a[2]-51403784|0)<<9|o>>>23)+t|0)&n|t&~n)+a[7]+1735328473|0)<<14|r>>>18)+o|0)&t|o&~t)+a[12]-1926607734|0)<<20|n>>>12)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n^r^o)+a[5]-378558|0)<<4|t>>>28)+n|0)^n^r)+a[8]-2022574463|0)<<11|o>>>21)+t|0)^t^n)+a[11]+1839030562|0)<<16|r>>>16)+o|0)^o^t)+a[14]-35309556|0)<<23|n>>>9)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n^r^o)+a[1]-1530992060|0)<<4|t>>>28)+n|0)^n^r)+a[4]+1272893353|0)<<11|o>>>21)+t|0)^t^n)+a[7]-155497632|0)<<16|r>>>16)+o|0)^o^t)+a[10]-1094730640|0)<<23|n>>>9)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n^r^o)+a[13]+681279174|0)<<4|t>>>28)+n|0)^n^r)+a[0]-358537222|0)<<11|o>>>21)+t|0)^t^n)+a[3]-722521979|0)<<16|r>>>16)+o|0)^o^t)+a[6]+76029189|0)<<23|n>>>9)+r|0,n=((n+=((r=((r+=((o=((o+=((t=((t+=(n^r^o)+a[9]-640364487|0)<<4|t>>>28)+n|0)^n^r)+a[12]-421815835|0)<<11|o>>>21)+t|0)^t^n)+a[15]+530742520|0)<<16|r>>>16)+o|0)^o^t)+a[2]-995338651|0)<<23|n>>>9)+r|0,n=((n+=((o=((o+=(n^((t=((t+=(r^(n|~o))+a[0]-198630844|0)<<6|t>>>26)+n|0)|~r))+a[7]+1126891415|0)<<10|o>>>22)+t|0)^((r=((r+=(t^(o|~n))+a[14]-1416354905|0)<<15|r>>>17)+o|0)|~t))+a[5]-57434055|0)<<21|n>>>11)+r|0,n=((n+=((o=((o+=(n^((t=((t+=(r^(n|~o))+a[12]+1700485571|0)<<6|t>>>26)+n|0)|~r))+a[3]-1894986606|0)<<10|o>>>22)+t|0)^((r=((r+=(t^(o|~n))+a[10]-1051523|0)<<15|r>>>17)+o|0)|~t))+a[1]-2054922799|0)<<21|n>>>11)+r|0,n=((n+=((o=((o+=(n^((t=((t+=(r^(n|~o))+a[8]+1873313359|0)<<6|t>>>26)+n|0)|~r))+a[15]-30611744|0)<<10|o>>>22)+t|0)^((r=((r+=(t^(o|~n))+a[6]-1560198380|0)<<15|r>>>17)+o|0)|~t))+a[13]+1309151649|0)<<21|n>>>11)+r|0,n=((n+=((o=((o+=(n^((t=((t+=(r^(n|~o))+a[4]-145523070|0)<<6|t>>>26)+n|0)|~r))+a[11]-1120210379|0)<<10|o>>>22)+t|0)^((r=((r+=(t^(o|~n))+a[2]+718787259|0)<<15|r>>>17)+o|0)|~t))+a[9]-343485551|0)<<21|n>>>11)+r|0,e[0]=t+e[0]|0,e[1]=n+e[1]|0,e[2]=r+e[2]|0,e[3]=o+e[3]|0}function n(e){var a,t=[];for(a=0;a<64;a+=4)t[a>>2]=e.charCodeAt(a)+(e.charCodeAt(a+1)<<8)+(e.charCodeAt(a+2)<<16)+(e.charCodeAt(a+3)<<24);return t}function r(e){var a,t=[];for(a=0;a<64;a+=4)t[a>>2]=e[a]+(e[a+1]<<8)+(e[a+2]<<16)+(e[a+3]<<24);return t}function o(e){var a,r,o,i,s,c,u=e.length,l=[1732584193,-271733879,-1732584194,271733878];for(a=64;a<=u;a+=64)t(l,n(e.substring(a-64,a)));for(r=(e=e.substring(a-64)).length,o=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],a=0;a>2]|=e.charCodeAt(a)<<(a%4<<3);if(o[a>>2]|=128<<(a%4<<3),a>55)for(t(l,o),a=0;a<16;a+=1)o[a]=0;return i=(i=8*u).toString(16).match(/(.*?)(.{0,8})$/),s=parseInt(i[2],16),c=parseInt(i[1],16)||0,o[14]=s,o[15]=c,t(l,o),l}function i(e){var t,n="";for(t=0;t<4;t+=1)n+=a[e>>8*t+4&15]+a[e>>8*t&15];return n}function s(e){var a;for(a=0;al?new ArrayBuffer(0):(r=l-u,o=new ArrayBuffer(r),i=new Uint8Array(o),s=new Uint8Array(this,u,r),i.set(s),o)}}(),l.prototype.append=function(e){return this.appendBinary(c(e)),this},l.prototype.appendBinary=function(e){this._buff+=e,this._length+=e.length;var a,r=this._buff.length;for(a=64;a<=r;a+=64)t(this._hash,n(this._buff.substring(a-64,a)));return this._buff=this._buff.substring(a-64),this},l.prototype.end=function(e){var a,t,n=this._buff,r=n.length,o=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(a=0;a>2]|=n.charCodeAt(a)<<(a%4<<3);return this._finish(o,r),t=s(this._hash),e&&(t=u(t)),this.reset(),t},l.prototype.reset=function(){return this._buff="",this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},l.prototype.getState=function(){return{buff:this._buff,length:this._length,hash:this._hash}},l.prototype.setState=function(e){return this._buff=e.buff,this._length=e.length,this._hash=e.hash,this},l.prototype.destroy=function(){delete this._hash,delete this._buff,delete this._length},l.prototype._finish=function(e,a){var n,r,o,i=a;if(e[i>>2]|=128<<(i%4<<3),i>55)for(t(this._hash,e),i=0;i<16;i+=1)e[i]=0;n=(n=8*this._length).toString(16).match(/(.*?)(.{0,8})$/),r=parseInt(n[2],16),o=parseInt(n[1],16)||0,e[14]=r,e[15]=o,t(this._hash,e)},l.hash=function(e,a){return l.hashBinary(c(e),a)},l.hashBinary=function(e,a){var t=s(o(e));return a?u(t):t},l.ArrayBuffer=function(){this.reset()},l.ArrayBuffer.prototype.append=function(e){var a,n,o,i,s,c=(n=this._buff.buffer,o=e,i=!0,(s=new Uint8Array(n.byteLength+o.byteLength)).set(new Uint8Array(n)),s.set(new Uint8Array(o),n.byteLength),i?s:s.buffer),u=c.length;for(this._length+=e.byteLength,a=64;a<=u;a+=64)t(this._hash,r(c.subarray(a-64,a)));return this._buff=a-64>2]|=n[a]<<(a%4<<3);return this._finish(o,r),t=s(this._hash),e&&(t=u(t)),this.reset(),t},l.ArrayBuffer.prototype.reset=function(){return this._buff=new Uint8Array(0),this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},l.ArrayBuffer.prototype.getState=function(){var e,a=l.prototype.getState.call(this);return a.buff=(e=a.buff,String.fromCharCode.apply(null,new Uint8Array(e))),a},l.ArrayBuffer.prototype.setState=function(e){return e.buff=function(e,a){var t,n=e.length,r=new ArrayBuffer(n),o=new Uint8Array(r);for(t=0;t>2]|=e[a]<<(a%4<<3);if(o[a>>2]|=128<<(a%4<<3),a>55)for(t(l,o),a=0;a<16;a+=1)o[a]=0;return i=(i=8*u).toString(16).match(/(.*?)(.{0,8})$/),s=parseInt(i[2],16),c=parseInt(i[1],16)||0,o[14]=s,o[15]=c,t(l,o),l}(new Uint8Array(e)));return a?u(n):n},l}()},function(e,a,t){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=t(14);function r(e,a,t){var n=!1;a[0][0]===a[a.length-1][0]&&a[0][1]===a[a.length-1][1]&&(a=a.slice(0,a.length-1));for(var r=0,o=a.length-1;re[1]!=u>e[1]&&e[0]<(c-i)*(e[1]-s)/(u-s)+i&&(n=!n)}return n}a.default=function(e,a,t){if(void 0===t&&(t={}),!e)throw new Error("point is required");if(!a)throw new Error("polygon is required");var o=n.getCoord(e),i=n.getGeom(a),s=i.type,c=a.bbox,u=i.coordinates;if(c&&!1===function(e,a){return a[0]<=e[0]&&a[1]<=e[1]&&a[2]>=e[0]&&a[3]>=e[1]}(o,c))return!1;"Polygon"===s&&(u=[u]);for(var l=!1,d=0;d=e.length&&t(null)})))}))},s.forEach=s.each,s.eachSeries=function(e,a,t){if(t=t||function(){},!e.length)return t();var n=0,r=function(){a(e[n],(function(a){a?(t(a),t=function(){}):(n+=1)>=e.length?t(null):r()}))};r()},s.forEachSeries=s.eachSeries,s.eachLimit=function(e,a,t,n){p(a).apply(null,[e,t,n])},s.forEachLimit=s.eachLimit;var p=function(e){return function(a,t,n){if(n=n||function(){},!a.length||e<=0)return n();var r=0,o=0,i=0;!function s(){if(r>=a.length)return n();for(;i=a.length?n():s())}))}()}},f=function(e){return function(){var a=Array.prototype.slice.call(arguments);return e.apply(null,[s.each].concat(a))}},m=function(e){return function(){var a=Array.prototype.slice.call(arguments);return e.apply(null,[s.eachSeries].concat(a))}},h=function(e,a,t,n){var r=[];e(a=l(a,(function(e,a){return{index:a,value:e}})),(function(e,a){t(e.value,(function(t,n){r[e.index]=n,a(t)}))}),(function(e){n(e,r)}))};s.map=f(h),s.mapSeries=m(h),s.mapLimit=function(e,a,t,n){return v(a)(e,t,n)};var v=function(e){return function(e,a){return function(){var t=Array.prototype.slice.call(arguments);return a.apply(null,[p(e)].concat(t))}}(e,h)};s.reduce=function(e,a,t,n){s.eachSeries(e,(function(e,n){t(a,e,(function(e,t){a=t,n(e)}))}),(function(e){n(e,a)}))},s.inject=s.reduce,s.foldl=s.reduce,s.reduceRight=function(e,a,t,n){var r=l(e,(function(e){return e})).reverse();s.reduce(r,a,t,n)},s.foldr=s.reduceRight;var k=function(e,a,t,n){var r=[];e(a=l(a,(function(e,a){return{index:a,value:e}})),(function(e,a){t(e.value,(function(t){t&&r.push(e),a()}))}),(function(e){n(l(r.sort((function(e,a){return e.index-a.index})),(function(e){return e.value})))}))};s.filter=f(k),s.filterSeries=m(k),s.select=s.filter,s.selectSeries=s.filterSeries;var g=function(e,a,t,n){var r=[];e(a=l(a,(function(e,a){return{index:a,value:e}})),(function(e,a){t(e.value,(function(t){t||r.push(e),a()}))}),(function(e){n(l(r.sort((function(e,a){return e.index-a.index})),(function(e){return e.value})))}))};s.reject=f(g),s.rejectSeries=m(g);var y=function(e,a,t,n){e(a,(function(e,a){t(e,(function(t){t?(n(e),n=function(){}):a()}))}),(function(e){n()}))};s.detect=f(y),s.detectSeries=m(y),s.some=function(e,a,t){s.each(e,(function(e,n){a(e,(function(e){e&&(t(!0),t=function(){}),n()}))}),(function(e){t(!1)}))},s.any=s.some,s.every=function(e,a,t){s.each(e,(function(e,n){a(e,(function(e){e||(t(!1),t=function(){}),n()}))}),(function(e){t(!0)}))},s.all=s.every,s.sortBy=function(e,a,t){s.map(e,(function(e,t){a(e,(function(a,n){a?t(a):t(null,{value:e,criteria:n})}))}),(function(e,a){if(e)return t(e);t(null,l(a.sort((function(e,a){var t=e.criteria,n=a.criteria;return tn?1:0})),(function(e){return e.value})))}))},s.auto=function(e,a){a=a||function(){};var t=d(e);if(!t.length)return a(null);var n={},r=[],o=function(e){r.unshift(e)},i=function(){u(r.slice(0),(function(e){e()}))};o((function(){d(n).length===t.length&&(a(null,n),a=function(){})})),u(t,(function(t){var c=e[t]instanceof Function?[e[t]]:e[t],l=function(e){var r=Array.prototype.slice.call(arguments,1);if(r.length<=1&&(r=r[0]),e){var o={};u(d(n),(function(e){o[e]=n[e]})),o[t]=r,a(e,o),a=function(){}}else n[t]=r,s.setImmediate(i)},p=c.slice(0,Math.abs(c.length-1))||[],f=function(){return a=function(e,a){return e&&n.hasOwnProperty(a)},r=!0,((e=p).reduce?e.reduce(a,r):(u(e,(function(e,t,n){r=a(r,e,t,n)})),r))&&!n.hasOwnProperty(t);var e,a,r};if(f())c[c.length-1](l,n);else{var m=function(){f()&&(!function(e){for(var a=0;a2){var n=Array.prototype.slice.call(arguments,2);return t.apply(this,n)}return t};s.applyEach=f(x),s.applyEachSeries=m(x),s.forever=function(e,a){!function t(n){if(n){if(a)return a(n);throw n}e(t)}()},void 0===(r=function(){return s}.apply(a,[]))||(e.exports=r)}()}).call(this,t(2),t(23).setImmediate)},function(e,a,t){"use strict";var n=t(19).codes.ERR_STREAM_PREMATURE_CLOSE;function r(){}e.exports=function e(a,t,o){if("function"==typeof t)return e(a,null,t);t||(t={}),o=function(e){var a=!1;return function(){if(!a){a=!0;for(var t=arguments.length,n=new Array(t),r=0;r-1?n:o.nextTick;g.WritableState=k;var u=Object.create(t(11));u.inherits=t(0);var l={deprecate:t(68)},d=t(73),p=t(35).Buffer,f=r.Uint8Array||function(){};var m,h=t(74);function v(){}function k(e,a){s=s||t(17),e=e||{};var n=a instanceof s;this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var r=e.highWaterMark,u=e.writableHighWaterMark,l=this.objectMode?16:16384;this.highWaterMark=r||0===r?r:n&&(u||0===u)?u:l,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var d=!1===e.decodeStrings;this.decodeStrings=!d,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,a){var t=e._writableState,n=t.sync,r=t.writecb;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(t),a)!function(e,a,t,n,r){--a.pendingcb,t?(o.nextTick(r,n),o.nextTick(_,e,a),e._writableState.errorEmitted=!0,e.emit("error",n)):(r(n),e._writableState.errorEmitted=!0,e.emit("error",n),_(e,a))}(e,t,n,a,r);else{var i=S(t);i||t.corked||t.bufferProcessing||!t.bufferedRequest||w(e,t),n?c(b,e,t,i,r):b(e,t,i,r)}}(a,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new i(this)}function g(e){if(s=s||t(17),!(m.call(g,this)||this instanceof s))return new g(e);this._writableState=new k(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),d.call(this)}function y(e,a,t,n,r,o,i){a.writelen=n,a.writecb=i,a.writing=!0,a.sync=!0,t?e._writev(r,a.onwrite):e._write(r,o,a.onwrite),a.sync=!1}function b(e,a,t,n){t||function(e,a){0===a.length&&a.needDrain&&(a.needDrain=!1,e.emit("drain"))}(e,a),a.pendingcb--,n(),_(e,a)}function w(e,a){a.bufferProcessing=!0;var t=a.bufferedRequest;if(e._writev&&t&&t.next){var n=a.bufferedRequestCount,r=new Array(n),o=a.corkedRequestsFree;o.entry=t;for(var s=0,c=!0;t;)r[s]=t,t.isBuf||(c=!1),t=t.next,s+=1;r.allBuffers=c,y(e,a,!0,a.length,r,"",o.finish),a.pendingcb++,a.lastBufferedRequest=null,o.next?(a.corkedRequestsFree=o.next,o.next=null):a.corkedRequestsFree=new i(a),a.bufferedRequestCount=0}else{for(;t;){var u=t.chunk,l=t.encoding,d=t.callback;if(y(e,a,!1,a.objectMode?1:u.length,u,l,d),t=t.next,a.bufferedRequestCount--,a.writing)break}null===t&&(a.lastBufferedRequest=null)}a.bufferedRequest=t,a.bufferProcessing=!1}function S(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function x(e,a){e._final((function(t){a.pendingcb--,t&&e.emit("error",t),a.prefinished=!0,e.emit("prefinish"),_(e,a)}))}function _(e,a){var t=S(a);return t&&(!function(e,a){a.prefinished||a.finalCalled||("function"==typeof e._final?(a.pendingcb++,a.finalCalled=!0,o.nextTick(x,e,a)):(a.prefinished=!0,e.emit("prefinish")))}(e,a),0===a.pendingcb&&(a.finished=!0,e.emit("finish"))),t}u.inherits(g,d),k.prototype.getBuffer=function(){for(var e=this.bufferedRequest,a=[];e;)a.push(e),e=e.next;return a},function(){try{Object.defineProperty(k.prototype,"buffer",{get:l.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(m=Function.prototype[Symbol.hasInstance],Object.defineProperty(g,Symbol.hasInstance,{value:function(e){return!!m.call(this,e)||this===g&&(e&&e._writableState instanceof k)}})):m=function(e){return e instanceof this},g.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},g.prototype.write=function(e,a,t){var n,r=this._writableState,i=!1,s=!r.objectMode&&(n=e,p.isBuffer(n)||n instanceof f);return s&&!p.isBuffer(e)&&(e=function(e){return p.from(e)}(e)),"function"==typeof a&&(t=a,a=null),s?a="buffer":a||(a=r.defaultEncoding),"function"!=typeof t&&(t=v),r.ended?function(e,a){var t=new Error("write after end");e.emit("error",t),o.nextTick(a,t)}(this,t):(s||function(e,a,t,n){var r=!0,i=!1;return null===t?i=new TypeError("May not write null values to stream"):"string"==typeof t||void 0===t||a.objectMode||(i=new TypeError("Invalid non-string/buffer chunk")),i&&(e.emit("error",i),o.nextTick(n,i),r=!1),r}(this,r,e,t))&&(r.pendingcb++,i=function(e,a,t,n,r,o){if(!t){var i=function(e,a,t){e.objectMode||!1===e.decodeStrings||"string"!=typeof a||(a=p.from(a,t));return a}(a,n,r);n!==i&&(t=!0,r="buffer",n=i)}var s=a.objectMode?1:n.length;a.length+=s;var c=a.length-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(g.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),g.prototype._write=function(e,a,t){t(new Error("_write() is not implemented"))},g.prototype._writev=null,g.prototype.end=function(e,a,t){var n=this._writableState;"function"==typeof e?(t=e,e=null,a=null):"function"==typeof a&&(t=a,a=null),null!=e&&this.write(e,a),n.corked&&(n.corked=1,this.uncork()),n.ending||n.finished||function(e,a,t){a.ending=!0,_(e,a),t&&(a.finished?o.nextTick(t):e.once("finish",t));a.ended=!0,e.writable=!1}(this,n,t)},Object.defineProperty(g.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),g.prototype.destroy=h.destroy,g.prototype._undestroy=h.undestroy,g.prototype._destroy=function(e,a){this.end(),a(e)}}).call(this,t(2),t(23).setImmediate,t(4))},function(e,a,t){(function(a){e.exports=s;var n=Object.keys||function(e){var a=[];for(var t in e)a.push(t);return a},r=t(11);r.inherits=t(0);var o=t(76),i=t(77);function s(e){if(!(this instanceof s))return new s(e);o.call(this,e),i.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",c)}function c(){this.allowHalfOpen||this._writableState.ended||a.nextTick(this.end.bind(this))}r.inherits(s,o),function(e,a){for(var t=0,n=e.length;t=0;o--)i=0===o?"":",",a.push({obj:n[o],prefix:i});a.push({val:"["})}else{for(c in s=[],n)n.hasOwnProperty(c)&&s.push(c);for(a.push({val:"}"}),o=s.length-1;o>=0;o--)l=n[u=s[o]],d=o>0?",":"",d+=JSON.stringify(u)+":",a.push({obj:l,prefix:d});a.push({val:"{"})}return p},a.parse=function(e){for(var a,t,r,o,i,s,c,u,l,d=[],p=[],f=0;;)if("}"!==(a=e[f++])&&"]"!==a&&void 0!==a)switch(a){case" ":case"\t":case"\n":case":":case",":break;case"n":f+=3,n(null,d,p);break;case"t":f+=3,n(!0,d,p);break;case"f":f+=4,n(!1,d,p);break;case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"-":for(t="",f--;;){if(r=e[f++],!/[\d\.\-e\+]/.test(r)){f--;break}t+=r}n(parseFloat(t),d,p);break;case'"':for(o="",i=void 0,s=0;'"'!==(c=e[f++])||"\\"===i&&s%2==1;)o+=c,"\\"===(i=c)?s++:s=0;n(JSON.parse('"'+o+'"'),d,p);break;case"[":u={element:[],index:d.length},d.push(u.element),p.push(u);break;case"{":l={element:{},index:d.length},d.push(l.element),p.push(l);break;default:throw new Error("unexpectedly reached end of input: "+a)}else{if(1===d.length)return d.pop();n(d.pop(),d,p)}}},function(e,a,t){(function(a){var n=t(28).Transform,r=t(16).inherits;function o(e){n.call(this,e),this._destroyed=!1}function i(e,a,t){t(null,e)}function s(e){return function(a,t,n){return"function"==typeof a&&(n=t,t=a,a={}),"function"!=typeof t&&(t=i),"function"!=typeof n&&(n=null),e(a,t,n)}}r(o,n),o.prototype.destroy=function(e){if(!this._destroyed){this._destroyed=!0;var t=this;a.nextTick((function(){e&&t.emit("error",e),t.emit("close")}))}},e.exports=s((function(e,a,t){var n=new o(e);return n._transform=a,t&&(n._flush=t),n})),e.exports.ctor=s((function(e,a,t){function n(a){if(!(this instanceof n))return new n(a);this.options=Object.assign({},e,a),o.call(this,this.options)}return r(n,o),n.prototype._transform=a,t&&(n.prototype._flush=t),n})),e.exports.obj=s((function(e,a,t){var n=new o(Object.assign({objectMode:!0,highWaterMark:16},e));return n._transform=a,t&&(n._flush=t),n}))}).call(this,t(2))},function(e,a,t){var n,r,o;!function(t,i){"use strict";"object"==typeof e.exports?e.exports=i():(r=[],void 0===(o="function"==typeof(n=i)?n.apply(a,r):n)||(e.exports=o))}(0,(function(){"use strict";var e=Object.prototype.toString;function a(e,a){return null!=e&&Object.prototype.hasOwnProperty.call(e,a)}function t(e){if(!e)return!0;if(r(e)&&0===e.length)return!0;if("string"!=typeof e){for(var t in e)if(a(e,t))return!1;return!0}return!1}function n(a){return e.call(a)}var r=Array.isArray||function(a){return"[object Array]"===e.call(a)};function o(e){var a=parseInt(e);return a.toString()===e?a:e}function i(e){e=e||{};var i=function(e){return Object.keys(i).reduce((function(a,t){return"create"===t||"function"==typeof i[t]&&(a[t]=i[t].bind(i,e)),a}),{})};function s(t,n){return e.includeInheritedProps||"number"==typeof n&&Array.isArray(t)||a(t,n)}function c(e,a){if(s(e,a))return e[a]}function u(e,a,t,n){if("number"==typeof a&&(a=[a]),!a||0===a.length)return e;if("string"==typeof a)return u(e,a.split(".").map(o),t,n);var r=a[0],i=c(e,r);return 1===a.length?(void 0!==i&&n||(e[r]=t),i):(void 0===i&&("number"==typeof a[1]?e[r]=[]:e[r]={}),u(e[r],a.slice(1),t,n))}return i.has=function(t,n){if("number"==typeof n?n=[n]:"string"==typeof n&&(n=n.split(".")),!n||0===n.length)return!!t;for(var i=0;i0?e[0]:null))}),n)},e.prototype._findFetch=function(e,a,t,n){return setTimeout((r=this,function(){var n,o;if(n=e&&e._id&&c.isString(e._id)?c.compact([r.items[e._id]]):c.values(r.items),o=i(n,e,a),null!=t)return t(r._applySafety(o))}),0);var r},e.prototype._applySafety=function(e){if(!e)return e;if(c.isArray(e))return c.map(e,this._applySafety);if("clone"===this.options.safety||!this.options.safety)return JSON.parse(JSON.stringify(e));if("freeze"===this.options.safety)return Object.freeze(e),e;throw new Error("Unsupported safety "+this.options.safety)},e.prototype.upsert=function(e,a,t,n){var r,o,i,u,l;for(o=(l=s.regularizeUpsert(e,a,t,n))[0],t=l[1],n=l[2],i=0,u=(o=JSON.parse(JSON.stringify(o))).length;i=0)||this.cacheOne(i);return s=c.object(c.pluck(e,"_id"),e),t.sort&&(l=o(t.sort)),this.find(a,t).fetch((m=this,function(a){var r,o,i,d;for(o=0,i=a.length;o=0)continue;if(!t.sort)continue}if(t&&t.exclude&&(d=r._id,u.call(t.exclude,d)>=0))continue;delete m.items[r._id]}if(null!=n)return n()}),r)},e.prototype.pendingUpserts=function(e){return e(c.values(this.upserts))},e.prototype.pendingRemoves=function(e){return e(c.pluck(this.removes,"_id"))},e.prototype.resolveUpserts=function(e,a){var t,n,r,o;for(r=0,o=e.length;rn._rev)||(this.items[t._id]=t);if(null!=a)return a()},e.prototype.uncache=function(e,a,t){var n,r,o;if(n=s.compileDocumentSelector(e),r=c.filter(c.values(this.items),(o=this,function(e){return null!=o.upserts[e._id]||!n(e)})),this.items=c.object(c.pluck(r,"_id"),r),null!=a)return a()},e.prototype.uncacheList=function(e,a,t){var n,r,o;if(n=c.indexBy(e),r=c.filter(c.values(this.items),(o=this,function(e){return null!=o.upserts[e._id]||!n[e._id]})),this.items=c.object(c.pluck(r,"_id"),r),null!=a)return a()},e}()},function(e,a,t){"use strict";Object.defineProperty(a,"__esModule",{value:!0});var n=t(24);a.default=function(e){var a=[1/0,1/0,-1/0,-1/0];return n.coordEach(e,(function(e){a[0]>e[0]&&(a[0]=e[0]),a[1]>e[1]&&(a[1]=e[1]),a[2]0?n.store.removeBatch(r,(function(){if(null!=a)return a()}),t):null!=a?a():void 0}),{index:"col",keyRange:this.store.makeKeyRange({only:e}),onError:t});var n},e.prototype.getCollectionNames=function(){return u.keys(this.collections)},e}(),n=function(){function e(e,a){this.name=e,this.store=a}return e.prototype.find=function(e,a){return{fetch:(t=this,function(n,r){return t._findFetch(e,a,n,r)})};var t},e.prototype.findOne=function(e,a,t,n){var r;return u.isFunction(a)&&(a=(r=[{},a,t])[0],t=r[1],n=r[2]),this.find(e,a).fetch((function(e){if(null!=t)return t(e.length>0?e[0]:null)}),n)},e.prototype._findFetch=function(e,a,t,n){return this.store.query((function(n){if(n=u.filter(n,(function(e){return"removed"!==e.state})),null!=t)return t(s(u.pluck(n,"doc"),e,a))}),{index:"col",keyRange:this.store.makeKeyRange({only:this.name}),onError:n})},e.prototype.upsert=function(e,a,t,n){var r,o,i,s;return i=c.regularizeUpsert(e,a,t,n),r=i[0],t=i[1],n=i[2],o=u.map(r,(s=this,function(e){return[s.name,e.doc._id]})),this.store.getBatch(o,function(a){return function(o){var i;return i=u.map(r,(function(e,t){var n;return n=void 0!==e.base?e.base:o[t]&&o[t].doc&&"cached"===o[t].state?o[t].doc:o[t]&&o[t].doc&&"upserted"===o[t].state?o[t].base:null,{col:a.name,state:"upserted",doc:e.doc,base:n}})),a.store.putBatch(i,(function(){if(t)return t(e)}),n)}}(this),n)},e.prototype.remove=function(e,a,t){var n;if(!u.isObject(e))return this.store.get([this.name,e],function(n){return function(r){return null==r&&(r={col:n.name,doc:{_id:e}}),r.state="removed",n.store.put(r,(function(){if(a)return a(e)}),t)}}(this));this.find(e).fetch((n=this,function(e){return o.each(e,(function(e,a){return n.remove(e._id,(function(){return a()}),a)}),(function(){return a()}))}),t)},e.prototype.cache=function(e,a,t,n,r){var o,s,c,d;return d=this,c=function(){var o,s;return o=u.object(u.pluck(e,"_id"),e),t.sort&&(s=i(t.sort)),d.find(a,t).fetch((function(a){var i,c;if(c=[],0!==(i=u.map(a,(function(e){return[d.name,e._id]}))).length)return d.store.getBatch(i,(function(i){var p,f,m,h,v,k;for(p=h=0,v=i.length;0<=v?hv;p=0<=v?++h:--h)if(f=i[p],m=a[p],!o[m._id]&&f&&"cached"===f.state){if(t.limit&&e.length===t.limit){if(t.sort&&s(m,u.last(e))>=0)continue;if(!t.sort)continue}if(t&&t.exclude&&(k=m._id,l.call(t.exclude,k)>=0))continue;c.push([d.name,m._id])}return c.length>0?d.store.removeBatch(c,(function(){if(null!=n)return n()}),r):null!=n?n():void 0}),r);null!=n&&n()}),r)},0===e.length?c():(o=u.map(e,function(e){return function(a){return[e.name,a._id]}}(this)),s=[],this.store.getBatch(o,function(a){return function(n){var o,i,u,d,p,f;for(i=d=0,p=n.length;0<=p?dp;i=0<=p?++d:--d)if(u=n[i],o=e[i],null==u||"cached"===u.state){if(t&&t.exclude&&(f=o._id,l.call(t.exclude,f)>=0))continue;u&&o._rev&&u.doc._rev&&!(o._rev>u.doc._rev)||s.push({col:a.name,state:"cached",doc:o})}return s.length>0?a.store.putBatch(s,c,r):c()}}(this),r))},e.prototype.pendingUpserts=function(e,a){return this.store.query((function(a){var t;if(t=u.map(a,(function(e){return{doc:e.doc,base:e.base||null}})),null!=e)return e(t)}),{index:"col-state",keyRange:this.store.makeKeyRange({only:[this.name,"upserted"]}),onError:a})},e.prototype.pendingRemoves=function(e,a){return this.store.query((function(a){if(null!=e)return e(u.pluck(u.pluck(a,"doc"),"_id"))}),{index:"col-state",keyRange:this.store.makeKeyRange({only:[this.name,"removed"]}),onError:a})},e.prototype.resolveUpserts=function(e,a,t){var n,r;return n=u.map(e,(r=this,function(e){return[r.name,e.doc._id]})),this.store.getBatch(n,function(n){return function(r){var o,i,s,c,l;for(i=[],o=c=0,l=e.length;0<=l?cl;o=0<=l?++c:--c)(s=r[o])&&"upserted"===s.state&&(u.isEqual(s.doc,e[o].doc)?(s.state="cached",i.push(s)):(s.base=e[o].doc,i.push(s)));return i.length>0?n.store.putBatch(i,(function(){if(a)return a()}),t):a?a():void 0}}(this),t)},e.prototype.resolveRemove=function(e,a,t){return this.store.get([this.name,e],(n=this,function(r){if(r)return"removed"===r.state?n.store.remove([n.name,e],(function(){if(null!=a)return a()}),t):void 0;null!=a&&a()}));var n},e.prototype.seed=function(e,a,t){var n,r,o;return u.isArray(e)||(e=[e]),n=u.map(e,(o=this,function(e){return[o.name,e._id]})),r=[],this.store.getBatch(n,function(n){return function(o){var i,s,c,u,l;for(s=u=0,l=o.length;0<=l?ul;s=0<=l?++u:--u)c=o[s],i=e[s],null==c&&r.push({col:n.name,state:"cached",doc:i});return r.length>0?n.store.putBatch(r,(function(){if(null!=a)return a()}),t):null!=a?a():void 0}}(this),t)},e.prototype.cacheOne=function(e,a,t){return this.cacheList([e],a,t)},e.prototype.cacheList=function(e,a,t){var n,r,o;return n=u.map(e,(o=this,function(e){return[o.name,e._id]})),r=[],this.store.getBatch(n,function(n){return function(o){var i,s,c,u,l;for(s=u=0,l=o.length;0<=l?ul;s=0<=l?++u:--u)c=o[s],i=e[s],c&&i._rev&&c.doc._rev&&i._rev<=c.doc._rev||(null==c&&(c={col:n.name,state:"cached",doc:i}),"cached"===c.state&&(c.doc=i,r.push(c)));return r.length>0?n.store.putBatch(r,(function(){if(null!=a)return a()}),t):null!=a?a():void 0}}(this),t)},e.prototype.uncache=function(e,a,t){var n,r;return n=c.compileDocumentSelector(e),this.store.query((r=this,function(e){var o;return e=u.filter(e,(function(e){return"cached"===e.state&&n(e.doc)})),(o=u.map(e,(function(e){return[r.name,e.doc._id]}))).length>0?r.store.removeBatch(o,(function(){if(null!=a)return a()}),t):null!=a?a():void 0}),{index:"col",keyRange:this.store.makeKeyRange({only:this.name}),onError:t})},e.prototype.uncacheList=function(e,a,t){var n,r;return n=u.indexBy(e),t=t||function(){},this.store.query((r=this,function(e){var o;return e=u.filter(e,(function(e){return"cached"===e.state&&n[e.doc._id]})),(o=u.map(e,(function(e){return[r.name,e.doc._id]}))).length>0?r.store.removeBatch(o,(function(){if(null!=a)return a()}),t):null!=a?a():void 0}),{index:"col",keyRange:this.store.makeKeyRange({only:this.name}),onError:t})},e}()},function(e,a,t){var n,r,o,i,s,c,u,l=[].indexOf||function(e){for(var a=0,t=this.length;a0?e[0]:null)}),n)},e.prototype._findFetch=function(e,a,t,n){return n=n||function(){},this.db.readTransaction((r=this,function(o){return o.executeSql("SELECT * FROM docs WHERE col = ?",[r.name],(function(n,r){var o,i,c,u,l;for(o=[],i=u=0,l=r.rows.length;0<=l?ul;i=0<=l?++u:--u)"removed"!==(c=r.rows.item(i)).state&&o.push(JSON.parse(c.doc));if(null!=t)return t(s(o,e,a))}),(function(e,a){return n(a)}))}),n);var r},e.prototype.upsert=function(e,a,t,n){var o,s,l;return s=c.regularizeUpsert(e,a,t,n),o=s[0],t=s[1],n=(n=s[2])||function(){},this.db.transaction((l=this,function(e){var t;return t=u.map(o,(function(e){return e.doc._id})),a={},r.eachSeries(t,(function(t,r){return e.executeSql("SELECT * FROM docs WHERE col = ? AND id = ?",[l.name,t],(function(t,n){var o;return e=t,n.rows.length>0&&("upserted"===(o=n.rows.item(0)).state?a[o.id]=o.base?JSON.parse(o.base):null:"cached"===o.state&&(a[o.id]=JSON.parse(o.doc))),r()}),(function(e,a){return n(a)}))}),(function(){var t,r,s,c,u,d;for(d=[],c=0,u=o.length;c0?r.executeSql('UPDATE docs SET state="removed" WHERE col = ? AND id = ?',[n.name,e],(function(){if(a)return a(e)}),(function(e,a){return t(a)})):r.executeSql("INSERT INTO docs (col, id, state, doc) VALUES (?, ?, ?, ?)",[n.name,e,"removed",JSON.stringify({_id:e})],(function(){if(a)return a(e)}),(function(e,a){return t(a)}))}),(function(e,a){return t(a)}))}}(this),t);this.find(e).fetch((n=this,function(e){return r.each(e,(function(e,a){return n.remove(e._id,(function(){return a()}),a)}),(function(){return a()}))}),t)},e.prototype.cache=function(e,a,t,n,i){return i=i||function(){},this.db.transaction((s=this,function(c){return r.eachSeries(e,(function(e,a){return c.executeSql("SELECT * FROM docs WHERE col = ? AND id = ?",[s.name,e._id],(function(n,r){var o,c;return 0===r.rows.length||"cached"===r.rows.item(0).state?(o=r.rows.length>0?JSON.parse(r.rows.item(0).doc):null,t&&t.exclude&&(c=e._id,l.call(t.exclude,c)>=0)?void a():!o||!e._rev||!o._rev||e._rev>o._rev?n.executeSql("INSERT OR REPLACE INTO docs (col, id, state, doc) VALUES (?, ?, ?, ?)",[s.name,e._id,"cached",JSON.stringify(e)],(function(){return a()}),(function(e,a){return i(a)})):a()):a()}),(function(e,a){return i(a)}))}),(function(c){var d,p;if(!c)return d=u.object(u.pluck(e,"_id"),e),t.sort&&(p=o(t.sort)),s.find(a,t).fetch((function(a){return s.db.transaction((function(o){return r.eachSeries(a,(function(a,n){return o.executeSql("SELECT * FROM docs WHERE col = ? AND id = ?",[s.name,a._id],(function(r,o){var c;if(!d[a._id]&&o.rows.length>0&&"cached"===o.rows.item(0).state){if(t&&t.exclude&&(c=a._id,l.call(t.exclude,c)>=0))return void n();if(t.limit&&e.length===t.limit){if(t.sort&&p(a,u.last(e))>=0)return n();if(!t.sort)return n()}return r.executeSql("DELETE FROM docs WHERE col = ? AND id = ?",[s.name,a._id],(function(){return n()}),(function(e,a){return i(a)}))}return n()}),(function(e,a){return i(a)}))}),(function(e){if(null==e)return null!=n?n():void 0;null!=i&&i(e)}))}),i)}),i);i&&i(c)}))}),i);var s},e.prototype.pendingUpserts=function(e,a){return a=a||function(){},this.db.readTransaction((t=this,function(n){return n.executeSql("SELECT * FROM docs WHERE col = ? AND state = ?",[t.name,"upserted"],(function(a,t){var n,r,o,i,s;for(n=[],r=i=0,s=t.rows.length;0<=s?is;r=0<=s?++i:--i)o=t.rows.item(r),n.push({doc:JSON.parse(o.doc),base:o.base?JSON.parse(o.base):null});if(null!=e)return e(n)}),(function(e,t){return a(t)}))}),a);var t},e.prototype.pendingRemoves=function(e,a){return a=a||function(){},this.db.readTransaction((t=this,function(n){return n.executeSql("SELECT * FROM docs WHERE col = ? AND state = ?",[t.name,"removed"],(function(a,t){var n,r,o,i,s;for(n=[],r=i=0,s=t.rows.length;0<=s?is;r=0<=s?++i:--i)o=t.rows.item(r),n.push(JSON.parse(o.doc)._id);if(null!=e)return e(n)}),(function(e,t){return a(t)}))}),a);var t},e.prototype.resolveUpserts=function(e,a,t){return t=t||function(){},this.db.transaction((n=this,function(o){return r.eachSeries(e,(function(e,a){return o.executeSql("SELECT * FROM docs WHERE col = ? AND id = ?",[n.name,e.doc._id],(function(r,o){return o.rows.length>0&&"upserted"===o.rows.item(0).state?u.isEqual(JSON.parse(o.rows.item(0).doc),e.doc)?(r.executeSql('UPDATE docs SET state="cached" WHERE col = ? AND id = ?',[n.name,e.doc._id],i,(function(e,a){return t(a)})),a()):(r.executeSql("UPDATE docs SET base=? WHERE col = ? AND id = ?",[JSON.stringify(e.doc),n.name,e.doc._id],i,(function(e,a){return t(a)})),a()):a()}),(function(e,a){return t(a)}))}),(function(e){return e?t(e):a?a():void 0}))}),t);var n},e.prototype.resolveRemove=function(e,a,t){return t=t||function(){},this.db.transaction((n=this,function(r){return r.executeSql('DELETE FROM docs WHERE state="removed" AND col = ? AND id = ?',[n.name,e],(function(){if(a)return a(e)}),(function(e,a){return t(a)}))}),t);var n},e.prototype.seed=function(e,a,t){return u.isArray(e)||(e=[e]),t=t||function(){},this.db.transaction((n=this,function(o){return r.eachSeries(e,(function(e,a){return o.executeSql("SELECT * FROM docs WHERE col = ? AND id = ?",[n.name,e._id],(function(r,o){return 0===o.rows.length?r.executeSql("INSERT OR REPLACE INTO docs (col, id, state, doc) VALUES (?, ?, ?, ?)",[n.name,e._id,"cached",JSON.stringify(e)],(function(){return a()}),(function(e,a){return t(a)})):a()}),(function(e,a){return t(a)}))}),(function(e){if(e){if(t)return t(e)}else if(a)return a()}))}),t);var n},e.prototype.cacheOne=function(e,a,t){return this.cacheList([e],a,t)},e.prototype.cacheList=function(e,a,t){return t=t||function(){},this.db.transaction((n=this,function(o){return r.eachSeries(e,(function(e,a){return o.executeSql("SELECT * FROM docs WHERE col = ? AND id = ?",[n.name,e._id],(function(t,r){var o;return 0!==r.rows.length&&"cached"!==r.rows.item(0).state||(o=r.rows.length>0?JSON.parse(r.rows.item(0).doc):null)&&e._rev&&o._rev&&!(e._rev>o._rev)?a():t.executeSql("INSERT OR REPLACE INTO docs (col, id, state, doc) VALUES (?, ?, ?, ?)",[n.name,e._id,"cached",JSON.stringify(e)],(function(){return a()}),(function(e,t){return a(t)}))}),(function(e,t){return a(t)}))}),(function(n){if(n){if(t)return t(n)}else if(a)return a(e)}))}),t);var n},e.prototype.uncache=function(e,a,t){var n,o;return n=c.compileDocumentSelector(e),t=t||function(){},this.db.transaction((o=this,function(e){return e.executeSql("SELECT * FROM docs WHERE col = ? AND state = ?",[o.name,"cached"],(function(e,i){var s,c,u,l,d,p;for(l=[],c=d=0,p=i.rows.length;0<=p?dp;c=0<=p?++d:--d)u=i.rows.item(c),s=JSON.parse(u.doc),n(s)&&l.push(s._id);return r.eachSeries(l,(function(a,n){return e.executeSql('DELETE FROM docs WHERE state="cached" AND col = ? AND id = ?',[o.name,a],(function(){return n()}),(function(e,a){return t(a)}))}),(function(e){if(e){if(t)return t(e)}else if(a)return a()}))}),(function(e,a){return t(a)}))}),t)},e.prototype.uncacheList=function(e,a,t){return t=t||function(){},this.db.transaction((n=this,function(o){return r.eachSeries(e,(function(e,a){return o.executeSql('DELETE FROM docs WHERE state="cached" AND col = ? AND id = ?',[n.name,e],(function(){return a()}),(function(e,a){return t(a)}))}),(function(e){if(e){if(t)return t(e)}else if(a)return a()}))}),t);var n},e}()},function(e,a,t){var n,r,o,i,s,c,u=[].indexOf||function(e){for(var a=0,t=this.length;al;n=0<=l?++s:--s)i.push(window.localStorage.key(n));for(c=0,u=i.length;cl;a=0<=l?++i:--i)(n=window.localStorage.key(a)).substring(0,this.itemNamespace.length)===this.itemNamespace&&(t=JSON.parse(window.localStorage[n]),this.items[t._id]=t);for(s=0,u=(o=window.localStorage[this.namespace+"upserts"]?JSON.parse(window.localStorage[this.namespace+"upserts"]):[]).length;s0?e[0]:null)}),n)},e.prototype._findFetch=function(e,a,t,n){if(null!=t)return t(i(c.cloneDeep(c.values(this.items)),e,a))},e.prototype.upsert=function(e,a,t,n){var r,o,i,u,l;for(o=(l=s.regularizeUpsert(e,a,t,n))[0],t=l[1],n=l[2],i=0,u=(o=JSON.parse(JSON.stringify(o))).length;i=0)||this.cacheOne(i);return s=c.object(c.pluck(e,"_id"),e),t.sort&&(l=o(t.sort)),this.find(a,t).fetch((m=this,function(a){var r,o,i,d;for(o=0,i=a.length;o=0))continue;if(t.limit&&e.length===t.limit){if(t.sort&&l(r,c.last(e))>=0)continue;if(!t.sort)continue}m._deleteItem(r._id)}if(null!=n)return n()}),r)},e.prototype.pendingUpserts=function(e){return e(c.values(this.upserts))},e.prototype.pendingRemoves=function(e){return e(c.pluck(this.removes,"_id"))},e.prototype.resolveUpserts=function(e,a){var t,n,r;for(n=0,r=e.length;nn._rev)||this._putItem(t);if(null!=a)return a()},e.prototype.uncache=function(e,a,t){var n,r,o,i,u;for(n=s.compileDocumentSelector(e),o=0,i=(u=c.values(this.items)).length;o0?i.isEqual(r,e[0])?void 0:t(e[0]):t(null)}),n)},a.interim||a.shortcut?this.localCol.findOne(e,a,(function(e){if(!e||(t(i.cloneDeep(e)),!a.shortcut))return r(e)}),n):r()},e.prototype._findFetch=function(e,a,t,n){return i.defaults(a,this.options),this.localCol.pendingUpserts((o=this,function(s){return o.localCol.pendingRemoves((function(c){var u,l;return l=function(u){var l,d,p,f,m;return d=i.cloneDeep(a),a.cacheFind&&delete d.fields,d.localData=u,m=null,f=!1,p=function(l){var d,p,h,v,k;if(m&&clearTimeout(m),!f)return a.cacheFind?(p=function(){var r;return r=function(e){if(!a.interim||!i.isEqual(u,e))return t(e)},o.localCol.find(e,a).fetch(r,n)},d=i.extend({},a,{exclude:c.concat(i.map(s,(function(e){return e.doc._id})))}),o.localCol.cache(l,e,d,p,n)):(h=l,c.length>0&&(v=i.object(i.map(c,(function(e){return[e,e]}))),h=i.filter(l,(function(e){return!i.has(v,e._id)}))),s.length>0&&(k=i.object(i.map(s,(function(e){return e.doc._id})),i.map(s,(function(e){return e.doc._id}))),h=(h=i.filter(h,(function(e){return!i.has(k,e._id)}))).concat(i.pluck(s,"doc")),h=r(h,e,a)),a.interim&&i.isEqual(u,h)?void 0:t(h));a.cacheFind&&o.localCol.cache(l,e,a,(function(){}),n)},l=function(e){if(m&&clearTimeout(m),!f&&!a.interim){if(a.useLocalOnRemoteError)return t(u);if(n)return n(e)}},a.timeout&&(m=setTimeout((function(){if(m=null,f=!0,!a.interim){if(a.useLocalOnRemoteError)return o.localCol.find(e,a).fetch(t,n);if(n)return n(new Error("Remote timed out"))}}),a.timeout)),o.remoteCol.find(e,d).fetch(p,l)},u=function(e){return a.interim&&t(e),l(e)},o.localCol.find(e,a).fetch(u,n)}),n)}),n);var o},e.prototype.upsert=function(e,a,t,n){var r,s;return r=(s=o.regularizeUpsert(e,a,t,n))[0],t=s[1],n=s[2],this.localCol.upsert(i.pluck(r,"doc"),i.pluck(r,"base"),(function(a){return"function"==typeof t?t(e):void 0}),n)},e.prototype.remove=function(e,a,t){return this.localCol.remove(e,(function(){if(null!=a)return a()}),t)},e.prototype.upload=function(e,a){var t,n,r;return r=this,n=function(e,a,t){var o;return(o=i.first(e))?r.remoteCol.upsert(o.doc,o.base,(function(s){return r.localCol.resolveUpserts([o],(function(){return s?r.localCol.cacheOne(s,(function(){return n(i.rest(e),a,t)}),t):r.localCol.remove(o.doc._id,(function(){return r.localCol.resolveRemove(o.doc._id,(function(){return n(i.rest(e),a,t)}),t)}),t)}),t)}),(function(s){return 410===s.status||403===s.status?r.localCol.remove(o.doc._id,(function(){return r.localCol.resolveRemove(o.doc._id,(function(){return 410===s.status?n(i.rest(e),a,t):t(s)}),t)}),t):t(s)})):a()},t=function(e){return function(a,n,r){var o;return(o=i.first(a))?e.remoteCol.remove(o,(function(){return e.localCol.resolveRemove(o,(function(){return t(i.rest(a),n,r)}),r)}),(function(s){return 410===s.status||403===s.status?e.localCol.resolveRemove(o,(function(){return 410===s.status?t(i.rest(a),n,r):r(s)}),r):r(s)}),r):n()}}(this),this.localCol.pendingUpserts(function(r){return function(o){return r.options.sortUpserts&&o.sort((function(e,a){return r.options.sortUpserts(e.doc,a.doc)})),n(o,(function(){return r.localCol.pendingRemoves((function(n){return t(n,e,a)}),a)}),a)}}(this),a)},e}()},function(e,a,t){var n; -/*! - * jQuery JavaScript Library v3.4.1 - * https://jquery.com/ - * - * Includes Sizzle.js - * https://sizzlejs.com/ - * - * Copyright JS Foundation and other contributors - * Released under the MIT license - * https://jquery.org/license - * - * Date: 2019-05-01T21:04Z - */!function(a,t){"use strict";"object"==typeof e.exports?e.exports=a.document?t(a,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(a)}("undefined"!=typeof window?window:this,(function(t,r){"use strict";var o=[],i=t.document,s=Object.getPrototypeOf,c=o.slice,u=o.concat,l=o.push,d=o.indexOf,p={},f=p.toString,m=p.hasOwnProperty,h=m.toString,v=h.call(Object),k={},g=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},y=function(e){return null!=e&&e===e.window},b={type:!0,src:!0,nonce:!0,noModule:!0};function w(e,a,t){var n,r,o=(t=t||i).createElement("script");if(o.text=e,a)for(n in b)(r=a[n]||a.getAttribute&&a.getAttribute(n))&&o.setAttribute(n,r);t.head.appendChild(o).parentNode.removeChild(o)}function S(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?p[f.call(e)]||"object":typeof e}var x=function(e,a){return new x.fn.init(e,a)},_=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function z(e){var a=!!e&&"length"in e&&e.length,t=S(e);return!g(e)&&!y(e)&&("array"===t||0===a||"number"==typeof a&&a>0&&a-1 in e)}x.fn=x.prototype={jquery:"3.4.1",constructor:x,length:0,toArray:function(){return c.call(this)},get:function(e){return null==e?c.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var a=x.merge(this.constructor(),e);return a.prevObject=this,a},each:function(e){return x.each(this,e)},map:function(e){return this.pushStack(x.map(this,(function(a,t){return e.call(a,t,a)})))},slice:function(){return this.pushStack(c.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var a=this.length,t=+e+(e<0?a:0);return this.pushStack(t>=0&&t+~]|"+D+")"+D+"*"),F=new RegExp(D+"|>"),q=new RegExp(O),U=new RegExp("^"+T+"$"),W={ID:new RegExp("^#("+T+")"),CLASS:new RegExp("^\\.("+T+")"),TAG:new RegExp("^("+T+"|[*])"),ATTR:new RegExp("^"+H),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+D+"*(even|odd|(([+-]|)(\\d*)n|)"+D+"*(?:([+-]|)"+D+"*(\\d+)|))"+D+"*\\)|)","i"),bool:new RegExp("^(?:"+C+")$","i"),needsContext:new RegExp("^"+D+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+D+"*((?:-\\d)?\\d*)"+D+"*\\)|)(?=[^-]|$)","i")},Z=/HTML$/i,$=/^(?:input|select|textarea|button)$/i,Y=/^h\d$/i,X=/^[^{]+\{\s*\[native \w/,Q=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,ae=new RegExp("\\\\([\\da-f]{1,6}"+D+"?|("+D+")|.)","ig"),te=function(e,a,t){var n="0x"+a-65536;return n!=n||t?a:n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320)},ne=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,re=function(e,a){return a?"\0"===e?"�":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){p()},ie=be((function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()}),{dir:"parentNode",next:"legend"});try{E.apply(K=L.call(w.childNodes),w.childNodes),K[w.childNodes.length].nodeType}catch(e){E={apply:K.length?function(e,a){P.apply(e,L.call(a))}:function(e,a){for(var t=e.length,n=0;e[t++]=a[n++];);e.length=t-1}}}function se(e,a,n,r){var o,s,u,l,d,m,k,g=a&&a.ownerDocument,S=a?a.nodeType:9;if(n=n||[],"string"!=typeof e||!e||1!==S&&9!==S&&11!==S)return n;if(!r&&((a?a.ownerDocument||a:w)!==f&&p(a),a=a||f,h)){if(11!==S&&(d=Q.exec(e)))if(o=d[1]){if(9===S){if(!(u=a.getElementById(o)))return n;if(u.id===o)return n.push(u),n}else if(g&&(u=g.getElementById(o))&&y(a,u)&&u.id===o)return n.push(u),n}else{if(d[2])return E.apply(n,a.getElementsByTagName(e)),n;if((o=d[3])&&t.getElementsByClassName&&a.getElementsByClassName)return E.apply(n,a.getElementsByClassName(o)),n}if(t.qsa&&!M[e+" "]&&(!v||!v.test(e))&&(1!==S||"object"!==a.nodeName.toLowerCase())){if(k=e,g=a,1===S&&F.test(e)){for((l=a.getAttribute("id"))?l=l.replace(ne,re):a.setAttribute("id",l=b),s=(m=i(e)).length;s--;)m[s]="#"+l+" "+ye(m[s]);k=m.join(","),g=ee.test(e)&&ke(a.parentNode)||a}try{return E.apply(n,g.querySelectorAll(k)),n}catch(a){M(e,!0)}finally{l===b&&a.removeAttribute("id")}}}return c(e.replace(J,"$1"),a,n,r)}function ce(){var e=[];return function a(t,r){return e.push(t+" ")>n.cacheLength&&delete a[e.shift()],a[t+" "]=r}}function ue(e){return e[b]=!0,e}function le(e){var a=f.createElement("fieldset");try{return!!e(a)}catch(e){return!1}finally{a.parentNode&&a.parentNode.removeChild(a),a=null}}function de(e,a){for(var t=e.split("|"),r=t.length;r--;)n.attrHandle[t[r]]=a}function pe(e,a){var t=a&&e,n=t&&1===e.nodeType&&1===a.nodeType&&e.sourceIndex-a.sourceIndex;if(n)return n;if(t)for(;t=t.nextSibling;)if(t===a)return-1;return e?1:-1}function fe(e){return function(a){return"input"===a.nodeName.toLowerCase()&&a.type===e}}function me(e){return function(a){var t=a.nodeName.toLowerCase();return("input"===t||"button"===t)&&a.type===e}}function he(e){return function(a){return"form"in a?a.parentNode&&!1===a.disabled?"label"in a?"label"in a.parentNode?a.parentNode.disabled===e:a.disabled===e:a.isDisabled===e||a.isDisabled!==!e&&ie(a)===e:a.disabled===e:"label"in a&&a.disabled===e}}function ve(e){return ue((function(a){return a=+a,ue((function(t,n){for(var r,o=e([],t.length,a),i=o.length;i--;)t[r=o[i]]&&(t[r]=!(n[r]=t[r]))}))}))}function ke(e){return e&&void 0!==e.getElementsByTagName&&e}for(a in t=se.support={},o=se.isXML=function(e){var a=e.namespaceURI,t=(e.ownerDocument||e).documentElement;return!Z.test(a||t&&t.nodeName||"HTML")},p=se.setDocument=function(e){var a,r,i=e?e.ownerDocument||e:w;return i!==f&&9===i.nodeType&&i.documentElement?(m=(f=i).documentElement,h=!o(f),w!==f&&(r=f.defaultView)&&r.top!==r&&(r.addEventListener?r.addEventListener("unload",oe,!1):r.attachEvent&&r.attachEvent("onunload",oe)),t.attributes=le((function(e){return e.className="i",!e.getAttribute("className")})),t.getElementsByTagName=le((function(e){return e.appendChild(f.createComment("")),!e.getElementsByTagName("*").length})),t.getElementsByClassName=X.test(f.getElementsByClassName),t.getById=le((function(e){return m.appendChild(e).id=b,!f.getElementsByName||!f.getElementsByName(b).length})),t.getById?(n.filter.ID=function(e){var a=e.replace(ae,te);return function(e){return e.getAttribute("id")===a}},n.find.ID=function(e,a){if(void 0!==a.getElementById&&h){var t=a.getElementById(e);return t?[t]:[]}}):(n.filter.ID=function(e){var a=e.replace(ae,te);return function(e){var t=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===a}},n.find.ID=function(e,a){if(void 0!==a.getElementById&&h){var t,n,r,o=a.getElementById(e);if(o){if((t=o.getAttributeNode("id"))&&t.value===e)return[o];for(r=a.getElementsByName(e),n=0;o=r[n++];)if((t=o.getAttributeNode("id"))&&t.value===e)return[o]}return[]}}),n.find.TAG=t.getElementsByTagName?function(e,a){return void 0!==a.getElementsByTagName?a.getElementsByTagName(e):t.qsa?a.querySelectorAll(e):void 0}:function(e,a){var t,n=[],r=0,o=a.getElementsByTagName(e);if("*"===e){for(;t=o[r++];)1===t.nodeType&&n.push(t);return n}return o},n.find.CLASS=t.getElementsByClassName&&function(e,a){if(void 0!==a.getElementsByClassName&&h)return a.getElementsByClassName(e)},k=[],v=[],(t.qsa=X.test(f.querySelectorAll))&&(le((function(e){m.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+D+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+D+"*(?:value|"+C+")"),e.querySelectorAll("[id~="+b+"-]").length||v.push("~="),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+b+"+*").length||v.push(".#.+[+~]")})),le((function(e){e.innerHTML="";var a=f.createElement("input");a.setAttribute("type","hidden"),e.appendChild(a).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+D+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),m.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")}))),(t.matchesSelector=X.test(g=m.matches||m.webkitMatchesSelector||m.mozMatchesSelector||m.oMatchesSelector||m.msMatchesSelector))&&le((function(e){t.disconnectedMatch=g.call(e,"*"),g.call(e,"[s!='']:x"),k.push("!=",O)})),v=v.length&&new RegExp(v.join("|")),k=k.length&&new RegExp(k.join("|")),a=X.test(m.compareDocumentPosition),y=a||X.test(m.contains)?function(e,a){var t=9===e.nodeType?e.documentElement:e,n=a&&a.parentNode;return e===n||!(!n||1!==n.nodeType||!(t.contains?t.contains(n):e.compareDocumentPosition&&16&e.compareDocumentPosition(n)))}:function(e,a){if(a)for(;a=a.parentNode;)if(a===e)return!0;return!1},j=a?function(e,a){if(e===a)return d=!0,0;var n=!e.compareDocumentPosition-!a.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)===(a.ownerDocument||a)?e.compareDocumentPosition(a):1)||!t.sortDetached&&a.compareDocumentPosition(e)===n?e===f||e.ownerDocument===w&&y(w,e)?-1:a===f||a.ownerDocument===w&&y(w,a)?1:l?R(l,e)-R(l,a):0:4&n?-1:1)}:function(e,a){if(e===a)return d=!0,0;var t,n=0,r=e.parentNode,o=a.parentNode,i=[e],s=[a];if(!r||!o)return e===f?-1:a===f?1:r?-1:o?1:l?R(l,e)-R(l,a):0;if(r===o)return pe(e,a);for(t=e;t=t.parentNode;)i.unshift(t);for(t=a;t=t.parentNode;)s.unshift(t);for(;i[n]===s[n];)n++;return n?pe(i[n],s[n]):i[n]===w?-1:s[n]===w?1:0},f):f},se.matches=function(e,a){return se(e,null,null,a)},se.matchesSelector=function(e,a){if((e.ownerDocument||e)!==f&&p(e),t.matchesSelector&&h&&!M[a+" "]&&(!k||!k.test(a))&&(!v||!v.test(a)))try{var n=g.call(e,a);if(n||t.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){M(a,!0)}return se(a,f,null,[e]).length>0},se.contains=function(e,a){return(e.ownerDocument||e)!==f&&p(e),y(e,a)},se.attr=function(e,a){(e.ownerDocument||e)!==f&&p(e);var r=n.attrHandle[a.toLowerCase()],o=r&&B.call(n.attrHandle,a.toLowerCase())?r(e,a,!h):void 0;return void 0!==o?o:t.attributes||!h?e.getAttribute(a):(o=e.getAttributeNode(a))&&o.specified?o.value:null},se.escape=function(e){return(e+"").replace(ne,re)},se.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},se.uniqueSort=function(e){var a,n=[],r=0,o=0;if(d=!t.detectDuplicates,l=!t.sortStable&&e.slice(0),e.sort(j),d){for(;a=e[o++];)a===e[o]&&(r=n.push(o));for(;r--;)e.splice(n[r],1)}return l=null,e},r=se.getText=function(e){var a,t="",n=0,o=e.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)t+=r(e)}else if(3===o||4===o)return e.nodeValue}else for(;a=e[n++];)t+=r(a);return t},(n=se.selectors={cacheLength:50,createPseudo:ue,match:W,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(ae,te),e[3]=(e[3]||e[4]||e[5]||"").replace(ae,te),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var a,t=!e[6]&&e[2];return W.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":t&&q.test(t)&&(a=i(t,!0))&&(a=t.indexOf(")",t.length-a)-t.length)&&(e[0]=e[0].slice(0,a),e[2]=t.slice(0,a)),e.slice(0,3))}},filter:{TAG:function(e){var a=e.replace(ae,te).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===a}},CLASS:function(e){var a=_[e+" "];return a||(a=new RegExp("(^|"+D+")"+e+"("+D+"|$)"))&&_(e,(function(e){return a.test("string"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute("class")||"")}))},ATTR:function(e,a,t){return function(n){var r=se.attr(n,e);return null==r?"!="===a:!a||(r+="","="===a?r===t:"!="===a?r!==t:"^="===a?t&&0===r.indexOf(t):"*="===a?t&&r.indexOf(t)>-1:"$="===a?t&&r.slice(-t.length)===t:"~="===a?(" "+r.replace(V," ")+" ").indexOf(t)>-1:"|="===a&&(r===t||r.slice(0,t.length+1)===t+"-"))}},CHILD:function(e,a,t,n,r){var o="nth"!==e.slice(0,3),i="last"!==e.slice(-4),s="of-type"===a;return 1===n&&0===r?function(e){return!!e.parentNode}:function(a,t,c){var u,l,d,p,f,m,h=o!==i?"nextSibling":"previousSibling",v=a.parentNode,k=s&&a.nodeName.toLowerCase(),g=!c&&!s,y=!1;if(v){if(o){for(;h;){for(p=a;p=p[h];)if(s?p.nodeName.toLowerCase()===k:1===p.nodeType)return!1;m=h="only"===e&&!m&&"nextSibling"}return!0}if(m=[i?v.firstChild:v.lastChild],i&&g){for(y=(f=(u=(l=(d=(p=v)[b]||(p[b]={}))[p.uniqueID]||(d[p.uniqueID]={}))[e]||[])[0]===S&&u[1])&&u[2],p=f&&v.childNodes[f];p=++f&&p&&p[h]||(y=f=0)||m.pop();)if(1===p.nodeType&&++y&&p===a){l[e]=[S,f,y];break}}else if(g&&(y=f=(u=(l=(d=(p=a)[b]||(p[b]={}))[p.uniqueID]||(d[p.uniqueID]={}))[e]||[])[0]===S&&u[1]),!1===y)for(;(p=++f&&p&&p[h]||(y=f=0)||m.pop())&&((s?p.nodeName.toLowerCase()!==k:1!==p.nodeType)||!++y||(g&&((l=(d=p[b]||(p[b]={}))[p.uniqueID]||(d[p.uniqueID]={}))[e]=[S,y]),p!==a)););return(y-=r)===n||y%n==0&&y/n>=0}}},PSEUDO:function(e,a){var t,r=n.pseudos[e]||n.setFilters[e.toLowerCase()]||se.error("unsupported pseudo: "+e);return r[b]?r(a):r.length>1?(t=[e,e,"",a],n.setFilters.hasOwnProperty(e.toLowerCase())?ue((function(e,t){for(var n,o=r(e,a),i=o.length;i--;)e[n=R(e,o[i])]=!(t[n]=o[i])})):function(e){return r(e,0,t)}):r}},pseudos:{not:ue((function(e){var a=[],t=[],n=s(e.replace(J,"$1"));return n[b]?ue((function(e,a,t,r){for(var o,i=n(e,null,r,[]),s=e.length;s--;)(o=i[s])&&(e[s]=!(a[s]=o))})):function(e,r,o){return a[0]=e,n(a,null,o,t),a[0]=null,!t.pop()}})),has:ue((function(e){return function(a){return se(e,a).length>0}})),contains:ue((function(e){return e=e.replace(ae,te),function(a){return(a.textContent||r(a)).indexOf(e)>-1}})),lang:ue((function(e){return U.test(e||"")||se.error("unsupported lang: "+e),e=e.replace(ae,te).toLowerCase(),function(a){var t;do{if(t=h?a.lang:a.getAttribute("xml:lang")||a.getAttribute("lang"))return(t=t.toLowerCase())===e||0===t.indexOf(e+"-")}while((a=a.parentNode)&&1===a.nodeType);return!1}})),target:function(a){var t=e.location&&e.location.hash;return t&&t.slice(1)===a.id},root:function(e){return e===m},focus:function(e){return e===f.activeElement&&(!f.hasFocus||f.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:he(!1),disabled:he(!0),checked:function(e){var a=e.nodeName.toLowerCase();return"input"===a&&!!e.checked||"option"===a&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!n.pseudos.empty(e)},header:function(e){return Y.test(e.nodeName)},input:function(e){return $.test(e.nodeName)},button:function(e){var a=e.nodeName.toLowerCase();return"input"===a&&"button"===e.type||"button"===a},text:function(e){var a;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(a=e.getAttribute("type"))||"text"===a.toLowerCase())},first:ve((function(){return[0]})),last:ve((function(e,a){return[a-1]})),eq:ve((function(e,a,t){return[t<0?t+a:t]})),even:ve((function(e,a){for(var t=0;ta?a:t;--n>=0;)e.push(n);return e})),gt:ve((function(e,a,t){for(var n=t<0?t+a:t;++n1?function(a,t,n){for(var r=e.length;r--;)if(!e[r](a,t,n))return!1;return!0}:e[0]}function Se(e,a,t,n,r){for(var o,i=[],s=0,c=e.length,u=null!=a;s-1&&(o[u]=!(i[u]=d))}}else k=Se(k===i?k.splice(m,k.length):k),r?r(null,i,k,c):E.apply(i,k)}))}function _e(e){for(var a,t,r,o=e.length,i=n.relative[e[0].type],s=i||n.relative[" "],c=i?1:0,l=be((function(e){return e===a}),s,!0),d=be((function(e){return R(a,e)>-1}),s,!0),p=[function(e,t,n){var r=!i&&(n||t!==u)||((a=t).nodeType?l(e,t,n):d(e,t,n));return a=null,r}];c1&&we(p),c>1&&ye(e.slice(0,c-1).concat({value:" "===e[c-2].type?"*":""})).replace(J,"$1"),t,c0,r=e.length>0,o=function(o,i,s,c,l){var d,m,v,k=0,g="0",y=o&&[],b=[],w=u,x=o||r&&n.find.TAG("*",l),_=S+=null==w?1:Math.random()||.1,z=x.length;for(l&&(u=i===f||i||l);g!==z&&null!=(d=x[g]);g++){if(r&&d){for(m=0,i||d.ownerDocument===f||(p(d),s=!h);v=e[m++];)if(v(d,i||f,s)){c.push(d);break}l&&(S=_)}t&&((d=!v&&d)&&k--,o&&y.push(d))}if(k+=g,t&&g!==k){for(m=0;v=a[m++];)v(y,b,i,s);if(o){if(k>0)for(;g--;)y[g]||b[g]||(b[g]=N.call(c));b=Se(b)}E.apply(c,b),l&&!o&&b.length>0&&k+a.length>1&&se.uniqueSort(c)}return l&&(S=_,u=w),y};return t?ue(o):o}(o,r))).selector=e}return s},c=se.select=function(e,a,t,r){var o,c,u,l,d,p="function"==typeof e&&e,f=!r&&i(e=p.selector||e);if(t=t||[],1===f.length){if((c=f[0]=f[0].slice(0)).length>2&&"ID"===(u=c[0]).type&&9===a.nodeType&&h&&n.relative[c[1].type]){if(!(a=(n.find.ID(u.matches[0].replace(ae,te),a)||[])[0]))return t;p&&(a=a.parentNode),e=e.slice(c.shift().value.length)}for(o=W.needsContext.test(e)?0:c.length;o--&&(u=c[o],!n.relative[l=u.type]);)if((d=n.find[l])&&(r=d(u.matches[0].replace(ae,te),ee.test(c[0].type)&&ke(a.parentNode)||a))){if(c.splice(o,1),!(e=r.length&&ye(c)))return E.apply(t,r),t;break}}return(p||s(e,f))(r,a,!h,t,!a||ee.test(e)&&ke(a.parentNode)||a),t},t.sortStable=b.split("").sort(j).join("")===b,t.detectDuplicates=!!d,p(),t.sortDetached=le((function(e){return 1&e.compareDocumentPosition(f.createElement("fieldset"))})),le((function(e){return e.innerHTML="","#"===e.firstChild.getAttribute("href")}))||de("type|href|height|width",(function(e,a,t){if(!t)return e.getAttribute(a,"type"===a.toLowerCase()?1:2)})),t.attributes&&le((function(e){return e.innerHTML="",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")}))||de("value",(function(e,a,t){if(!t&&"input"===e.nodeName.toLowerCase())return e.defaultValue})),le((function(e){return null==e.getAttribute("disabled")}))||de(C,(function(e,a,t){var n;if(!t)return!0===e[a]?a.toLowerCase():(n=e.getAttributeNode(a))&&n.specified?n.value:null})),se}(t);x.find=A,x.expr=A.selectors,x.expr[":"]=x.expr.pseudos,x.uniqueSort=x.unique=A.uniqueSort,x.text=A.getText,x.isXMLDoc=A.isXML,x.contains=A.contains,x.escapeSelector=A.escape;var M=function(e,a,t){for(var n=[],r=void 0!==t;(e=e[a])&&9!==e.nodeType;)if(1===e.nodeType){if(r&&x(e).is(t))break;n.push(e)}return n},j=function(e,a){for(var t=[];e;e=e.nextSibling)1===e.nodeType&&e!==a&&t.push(e);return t},B=x.expr.match.needsContext;function K(e,a){return e.nodeName&&e.nodeName.toLowerCase()===a.toLowerCase()}var N=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function P(e,a,t){return g(a)?x.grep(e,(function(e,n){return!!a.call(e,n,e)!==t})):a.nodeType?x.grep(e,(function(e){return e===a!==t})):"string"!=typeof a?x.grep(e,(function(e){return d.call(a,e)>-1!==t})):x.filter(a,e,t)}x.filter=function(e,a,t){var n=a[0];return t&&(e=":not("+e+")"),1===a.length&&1===n.nodeType?x.find.matchesSelector(n,e)?[n]:[]:x.find.matches(e,x.grep(a,(function(e){return 1===e.nodeType})))},x.fn.extend({find:function(e){var a,t,n=this.length,r=this;if("string"!=typeof e)return this.pushStack(x(e).filter((function(){for(a=0;a1?x.uniqueSort(t):t},filter:function(e){return this.pushStack(P(this,e||[],!1))},not:function(e){return this.pushStack(P(this,e||[],!0))},is:function(e){return!!P(this,"string"==typeof e&&B.test(e)?x(e):e||[],!1).length}});var E,L=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(x.fn.init=function(e,a,t){var n,r;if(!e)return this;if(t=t||E,"string"==typeof e){if(!(n="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:L.exec(e))||!n[1]&&a)return!a||a.jquery?(a||t).find(e):this.constructor(a).find(e);if(n[1]){if(a=a instanceof x?a[0]:a,x.merge(this,x.parseHTML(n[1],a&&a.nodeType?a.ownerDocument||a:i,!0)),N.test(n[1])&&x.isPlainObject(a))for(n in a)g(this[n])?this[n](a[n]):this.attr(n,a[n]);return this}return(r=i.getElementById(n[2]))&&(this[0]=r,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):g(e)?void 0!==t.ready?t.ready(e):e(x):x.makeArray(e,this)}).prototype=x.fn,E=x(i);var R=/^(?:parents|prev(?:Until|All))/,C={children:!0,contents:!0,next:!0,prev:!0};function D(e,a){for(;(e=e[a])&&1!==e.nodeType;);return e}x.fn.extend({has:function(e){var a=x(e,this),t=a.length;return this.filter((function(){for(var e=0;e-1:1===t.nodeType&&x.find.matchesSelector(t,e))){o.push(t);break}return this.pushStack(o.length>1?x.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?d.call(x(e),this[0]):d.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,a){return this.pushStack(x.uniqueSort(x.merge(this.get(),x(e,a))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),x.each({parent:function(e){var a=e.parentNode;return a&&11!==a.nodeType?a:null},parents:function(e){return M(e,"parentNode")},parentsUntil:function(e,a,t){return M(e,"parentNode",t)},next:function(e){return D(e,"nextSibling")},prev:function(e){return D(e,"previousSibling")},nextAll:function(e){return M(e,"nextSibling")},prevAll:function(e){return M(e,"previousSibling")},nextUntil:function(e,a,t){return M(e,"nextSibling",t)},prevUntil:function(e,a,t){return M(e,"previousSibling",t)},siblings:function(e){return j((e.parentNode||{}).firstChild,e)},children:function(e){return j(e.firstChild)},contents:function(e){return void 0!==e.contentDocument?e.contentDocument:(K(e,"template")&&(e=e.content||e),x.merge([],e.childNodes))}},(function(e,a){x.fn[e]=function(t,n){var r=x.map(this,a,t);return"Until"!==e.slice(-5)&&(n=t),n&&"string"==typeof n&&(r=x.filter(n,r)),this.length>1&&(C[e]||x.uniqueSort(r),R.test(e)&&r.reverse()),this.pushStack(r)}}));var T=/[^\x20\t\r\n\f]+/g;function H(e){return e}function O(e){throw e}function V(e,a,t,n){var r;try{e&&g(r=e.promise)?r.call(e).done(a).fail(t):e&&g(r=e.then)?r.call(e,a,t):a.apply(void 0,[e].slice(n))}catch(e){t.apply(void 0,[e])}}x.Callbacks=function(e){e="string"==typeof e?function(e){var a={};return x.each(e.match(T)||[],(function(e,t){a[t]=!0})),a}(e):x.extend({},e);var a,t,n,r,o=[],i=[],s=-1,c=function(){for(r=r||e.once,n=a=!0;i.length;s=-1)for(t=i.shift();++s-1;)o.splice(t,1),t<=s&&s--})),this},has:function(e){return e?x.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return r=i=[],o=t="",this},disabled:function(){return!o},lock:function(){return r=i=[],t||a||(o=t=""),this},locked:function(){return!!r},fireWith:function(e,t){return r||(t=[e,(t=t||[]).slice?t.slice():t],i.push(t),a||c()),this},fire:function(){return u.fireWith(this,arguments),this},fired:function(){return!!n}};return u},x.extend({Deferred:function(e){var a=[["notify","progress",x.Callbacks("memory"),x.Callbacks("memory"),2],["resolve","done",x.Callbacks("once memory"),x.Callbacks("once memory"),0,"resolved"],["reject","fail",x.Callbacks("once memory"),x.Callbacks("once memory"),1,"rejected"]],n="pending",r={state:function(){return n},always:function(){return o.done(arguments).fail(arguments),this},catch:function(e){return r.then(null,e)},pipe:function(){var e=arguments;return x.Deferred((function(t){x.each(a,(function(a,n){var r=g(e[n[4]])&&e[n[4]];o[n[1]]((function(){var e=r&&r.apply(this,arguments);e&&g(e.promise)?e.promise().progress(t.notify).done(t.resolve).fail(t.reject):t[n[0]+"With"](this,r?[e]:arguments)}))})),e=null})).promise()},then:function(e,n,r){var o=0;function i(e,a,n,r){return function(){var s=this,c=arguments,u=function(){var t,u;if(!(e=o&&(n!==O&&(s=void 0,c=[t]),a.rejectWith(s,c))}};e?l():(x.Deferred.getStackHook&&(l.stackTrace=x.Deferred.getStackHook()),t.setTimeout(l))}}return x.Deferred((function(t){a[0][3].add(i(0,t,g(r)?r:H,t.notifyWith)),a[1][3].add(i(0,t,g(e)?e:H)),a[2][3].add(i(0,t,g(n)?n:O))})).promise()},promise:function(e){return null!=e?x.extend(e,r):r}},o={};return x.each(a,(function(e,t){var i=t[2],s=t[5];r[t[1]]=i.add,s&&i.add((function(){n=s}),a[3-e][2].disable,a[3-e][3].disable,a[0][2].lock,a[0][3].lock),i.add(t[3].fire),o[t[0]]=function(){return o[t[0]+"With"](this===o?void 0:this,arguments),this},o[t[0]+"With"]=i.fireWith})),r.promise(o),e&&e.call(o,o),o},when:function(e){var a=arguments.length,t=a,n=Array(t),r=c.call(arguments),o=x.Deferred(),i=function(e){return function(t){n[e]=this,r[e]=arguments.length>1?c.call(arguments):t,--a||o.resolveWith(n,r)}};if(a<=1&&(V(e,o.done(i(t)).resolve,o.reject,!a),"pending"===o.state()||g(r[t]&&r[t].then)))return o.then();for(;t--;)V(r[t],i(t),o.reject);return o.promise()}});var J=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;x.Deferred.exceptionHook=function(e,a){t.console&&t.console.warn&&e&&J.test(e.name)&&t.console.warn("jQuery.Deferred exception: "+e.message,e.stack,a)},x.readyException=function(e){t.setTimeout((function(){throw e}))};var I=x.Deferred();function G(){i.removeEventListener("DOMContentLoaded",G),t.removeEventListener("load",G),x.ready()}x.fn.ready=function(e){return I.then(e).catch((function(e){x.readyException(e)})),this},x.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--x.readyWait:x.isReady)||(x.isReady=!0,!0!==e&&--x.readyWait>0||I.resolveWith(i,[x]))}}),x.ready.then=I.then,"complete"===i.readyState||"loading"!==i.readyState&&!i.documentElement.doScroll?t.setTimeout(x.ready):(i.addEventListener("DOMContentLoaded",G),t.addEventListener("load",G));var F=function(e,a,t,n,r,o,i){var s=0,c=e.length,u=null==t;if("object"===S(t))for(s in r=!0,t)F(e,a,s,t[s],!0,o,i);else if(void 0!==n&&(r=!0,g(n)||(i=!0),u&&(i?(a.call(e,n),a=null):(u=a,a=function(e,a,t){return u.call(x(e),t)})),a))for(;s1,null,!0)},removeData:function(e){return this.each((function(){Q.remove(this,e)}))}}),x.extend({queue:function(e,a,t){var n;if(e)return a=(a||"fx")+"queue",n=X.get(e,a),t&&(!n||Array.isArray(t)?n=X.access(e,a,x.makeArray(t)):n.push(t)),n||[]},dequeue:function(e,a){a=a||"fx";var t=x.queue(e,a),n=t.length,r=t.shift(),o=x._queueHooks(e,a);"inprogress"===r&&(r=t.shift(),n--),r&&("fx"===a&&t.unshift("inprogress"),delete o.stop,r.call(e,(function(){x.dequeue(e,a)}),o)),!n&&o&&o.empty.fire()},_queueHooks:function(e,a){var t=a+"queueHooks";return X.get(e,t)||X.access(e,t,{empty:x.Callbacks("once memory").add((function(){X.remove(e,[a+"queue",t])}))})}}),x.fn.extend({queue:function(e,a){var t=2;return"string"!=typeof e&&(a=e,e="fx",t--),arguments.length\x20\t\r\n\f]*)/i,ke=/^$|^module$|\/(?:java|ecma)script/i,ge={option:[1,""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ye(e,a){var t;return t=void 0!==e.getElementsByTagName?e.getElementsByTagName(a||"*"):void 0!==e.querySelectorAll?e.querySelectorAll(a||"*"):[],void 0===a||a&&K(e,a)?x.merge([e],t):t}function be(e,a){for(var t=0,n=e.length;t-1)r&&r.push(o);else if(u=se(o),i=ye(d.appendChild(o),"script"),u&&be(i),t)for(l=0;o=i[l++];)ke.test(o.type||"")&&t.push(o);return d}we=i.createDocumentFragment().appendChild(i.createElement("div")),(Se=i.createElement("input")).setAttribute("type","radio"),Se.setAttribute("checked","checked"),Se.setAttribute("name","t"),we.appendChild(Se),k.checkClone=we.cloneNode(!0).cloneNode(!0).lastChild.checked,we.innerHTML="",k.noCloneChecked=!!we.cloneNode(!0).lastChild.defaultValue;var ze=/^key/,Ae=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Me=/^([^.]*)(?:\.(.+)|)/;function je(){return!0}function Be(){return!1}function Ke(e,a){return e===function(){try{return i.activeElement}catch(e){}}()==("focus"===a)}function Ne(e,a,t,n,r,o){var i,s;if("object"==typeof a){for(s in"string"!=typeof t&&(n=n||t,t=void 0),a)Ne(e,s,t,n,a[s],o);return e}if(null==n&&null==r?(r=t,n=t=void 0):null==r&&("string"==typeof t?(r=n,n=void 0):(r=n,n=t,t=void 0)),!1===r)r=Be;else if(!r)return e;return 1===o&&(i=r,(r=function(e){return x().off(e),i.apply(this,arguments)}).guid=i.guid||(i.guid=x.guid++)),e.each((function(){x.event.add(this,a,r,n,t)}))}function Pe(e,a,t){t?(X.set(e,a,!1),x.event.add(e,a,{namespace:!1,handler:function(e){var n,r,o=X.get(this,a);if(1&e.isTrigger&&this[a]){if(o.length)(x.event.special[a]||{}).delegateType&&e.stopPropagation();else if(o=c.call(arguments),X.set(this,a,o),n=t(this,a),this[a](),o!==(r=X.get(this,a))||n?X.set(this,a,!1):r={},o!==r)return e.stopImmediatePropagation(),e.preventDefault(),r.value}else o.length&&(X.set(this,a,{value:x.event.trigger(x.extend(o[0],x.Event.prototype),o.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===X.get(e,a)&&x.event.add(e,a,je)}x.event={global:{},add:function(e,a,t,n,r){var o,i,s,c,u,l,d,p,f,m,h,v=X.get(e);if(v)for(t.handler&&(t=(o=t).handler,r=o.selector),r&&x.find.matchesSelector(ie,r),t.guid||(t.guid=x.guid++),(c=v.events)||(c=v.events={}),(i=v.handle)||(i=v.handle=function(a){return void 0!==x&&x.event.triggered!==a.type?x.event.dispatch.apply(e,arguments):void 0}),u=(a=(a||"").match(T)||[""]).length;u--;)f=h=(s=Me.exec(a[u])||[])[1],m=(s[2]||"").split(".").sort(),f&&(d=x.event.special[f]||{},f=(r?d.delegateType:d.bindType)||f,d=x.event.special[f]||{},l=x.extend({type:f,origType:h,data:n,handler:t,guid:t.guid,selector:r,needsContext:r&&x.expr.match.needsContext.test(r),namespace:m.join(".")},o),(p=c[f])||((p=c[f]=[]).delegateCount=0,d.setup&&!1!==d.setup.call(e,n,m,i)||e.addEventListener&&e.addEventListener(f,i)),d.add&&(d.add.call(e,l),l.handler.guid||(l.handler.guid=t.guid)),r?p.splice(p.delegateCount++,0,l):p.push(l),x.event.global[f]=!0)},remove:function(e,a,t,n,r){var o,i,s,c,u,l,d,p,f,m,h,v=X.hasData(e)&&X.get(e);if(v&&(c=v.events)){for(u=(a=(a||"").match(T)||[""]).length;u--;)if(f=h=(s=Me.exec(a[u])||[])[1],m=(s[2]||"").split(".").sort(),f){for(d=x.event.special[f]||{},p=c[f=(n?d.delegateType:d.bindType)||f]||[],s=s[2]&&new RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"),i=o=p.length;o--;)l=p[o],!r&&h!==l.origType||t&&t.guid!==l.guid||s&&!s.test(l.namespace)||n&&n!==l.selector&&("**"!==n||!l.selector)||(p.splice(o,1),l.selector&&p.delegateCount--,d.remove&&d.remove.call(e,l));i&&!p.length&&(d.teardown&&!1!==d.teardown.call(e,m,v.handle)||x.removeEvent(e,f,v.handle),delete c[f])}else for(f in c)x.event.remove(e,f+a[u],t,n,!0);x.isEmptyObject(c)&&X.remove(e,"handle events")}},dispatch:function(e){var a,t,n,r,o,i,s=x.event.fix(e),c=new Array(arguments.length),u=(X.get(this,"events")||{})[s.type]||[],l=x.event.special[s.type]||{};for(c[0]=s,a=1;a=1))for(;u!==this;u=u.parentNode||this)if(1===u.nodeType&&("click"!==e.type||!0!==u.disabled)){for(o=[],i={},t=0;t-1:x.find(r,this,null,[u]).length),i[r]&&o.push(n);o.length&&s.push({elem:u,handlers:o})}return u=this,c\x20\t\r\n\f]*)[^>]*)\/>/gi,Le=/\s*$/g;function De(e,a){return K(e,"table")&&K(11!==a.nodeType?a:a.firstChild,"tr")&&x(e).children("tbody")[0]||e}function Te(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,a){var t,n,r,o,i,s,c,u;if(1===a.nodeType){if(X.hasData(e)&&(o=X.access(e),i=X.set(a,o),u=o.events))for(r in delete i.handle,i.events={},u)for(t=0,n=u[r].length;t1&&"string"==typeof m&&!k.checkClone&&Re.test(m))return e.each((function(r){var o=e.eq(r);h&&(a[0]=m.call(this,r,o.html())),Je(o,a,t,n)}));if(p&&(o=(r=_e(a,e[0].ownerDocument,!1,e,n)).firstChild,1===r.childNodes.length&&(r=o),o||n)){for(s=(i=x.map(ye(r,"script"),Te)).length;d")},clone:function(e,a,t){var n,r,o,i,s=e.cloneNode(!0),c=se(e);if(!(k.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||x.isXMLDoc(e)))for(i=ye(s),n=0,r=(o=ye(e)).length;n0&&be(i,!c&&ye(e,"script")),s},cleanData:function(e){for(var a,t,n,r=x.event.special,o=0;void 0!==(t=e[o]);o++)if($(t)){if(a=t[X.expando]){if(a.events)for(n in a.events)r[n]?x.event.remove(t,n):x.removeEvent(t,n,a.handle);t[X.expando]=void 0}t[Q.expando]&&(t[Q.expando]=void 0)}}}),x.fn.extend({detach:function(e){return Ie(this,e,!0)},remove:function(e){return Ie(this,e)},text:function(e){return F(this,(function(e){return void 0===e?x.text(this):this.empty().each((function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)}))}),null,e,arguments.length)},append:function(){return Je(this,arguments,(function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||De(this,e).appendChild(e)}))},prepend:function(){return Je(this,arguments,(function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var a=De(this,e);a.insertBefore(e,a.firstChild)}}))},before:function(){return Je(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this)}))},after:function(){return Je(this,arguments,(function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)}))},empty:function(){for(var e,a=0;null!=(e=this[a]);a++)1===e.nodeType&&(x.cleanData(ye(e,!1)),e.textContent="");return this},clone:function(e,a){return e=null!=e&&e,a=null==a?e:a,this.map((function(){return x.clone(this,e,a)}))},html:function(e){return F(this,(function(e){var a=this[0]||{},t=0,n=this.length;if(void 0===e&&1===a.nodeType)return a.innerHTML;if("string"==typeof e&&!Le.test(e)&&!ge[(ve.exec(e)||["",""])[1].toLowerCase()]){e=x.htmlPrefilter(e);try{for(;t=0&&(c+=Math.max(0,Math.ceil(e["offset"+a[0].toUpperCase()+a.slice(1)]-o-c-s-.5))||0),c}function oa(e,a,t){var n=Fe(e),r=(!k.boxSizingReliable()||t)&&"border-box"===x.css(e,"boxSizing",!1,n),o=r,i=Ue(e,a,n),s="offset"+a[0].toUpperCase()+a.slice(1);if(Ge.test(i)){if(!t)return i;i="auto"}return(!k.boxSizingReliable()&&r||"auto"===i||!parseFloat(i)&&"inline"===x.css(e,"display",!1,n))&&e.getClientRects().length&&(r="border-box"===x.css(e,"boxSizing",!1,n),(o=s in e)&&(i=e[s])),(i=parseFloat(i)||0)+ra(e,a,t||(r?"border":"content"),o,n,i)+"px"}function ia(e,a,t,n,r){return new ia.prototype.init(e,a,t,n,r)}x.extend({cssHooks:{opacity:{get:function(e,a){if(a){var t=Ue(e,"opacity");return""===t?"1":t}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,a,t,n){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var r,o,i,s=Z(a),c=ea.test(a),u=e.style;if(c||(a=Xe(s)),i=x.cssHooks[a]||x.cssHooks[s],void 0===t)return i&&"get"in i&&void 0!==(r=i.get(e,!1,n))?r:u[a];"string"===(o=typeof t)&&(r=re.exec(t))&&r[1]&&(t=de(e,a,r),o="number"),null!=t&&t==t&&("number"!==o||c||(t+=r&&r[3]||(x.cssNumber[s]?"":"px")),k.clearCloneStyle||""!==t||0!==a.indexOf("background")||(u[a]="inherit"),i&&"set"in i&&void 0===(t=i.set(e,t,n))||(c?u.setProperty(a,t):u[a]=t))}},css:function(e,a,t,n){var r,o,i,s=Z(a);return ea.test(a)||(a=Xe(s)),(i=x.cssHooks[a]||x.cssHooks[s])&&"get"in i&&(r=i.get(e,!0,t)),void 0===r&&(r=Ue(e,a,n)),"normal"===r&&a in ta&&(r=ta[a]),""===t||t?(o=parseFloat(r),!0===t||isFinite(o)?o||0:r):r}}),x.each(["height","width"],(function(e,a){x.cssHooks[a]={get:function(e,t,n){if(t)return!Qe.test(x.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?oa(e,a,n):le(e,aa,(function(){return oa(e,a,n)}))},set:function(e,t,n){var r,o=Fe(e),i=!k.scrollboxSize()&&"absolute"===o.position,s=(i||n)&&"border-box"===x.css(e,"boxSizing",!1,o),c=n?ra(e,a,n,s,o):0;return s&&i&&(c-=Math.ceil(e["offset"+a[0].toUpperCase()+a.slice(1)]-parseFloat(o[a])-ra(e,a,"border",!1,o)-.5)),c&&(r=re.exec(t))&&"px"!==(r[3]||"px")&&(e.style[a]=t,t=x.css(e,a)),na(0,t,c)}}})),x.cssHooks.marginLeft=We(k.reliableMarginLeft,(function(e,a){if(a)return(parseFloat(Ue(e,"marginLeft"))||e.getBoundingClientRect().left-le(e,{marginLeft:0},(function(){return e.getBoundingClientRect().left})))+"px"})),x.each({margin:"",padding:"",border:"Width"},(function(e,a){x.cssHooks[e+a]={expand:function(t){for(var n=0,r={},o="string"==typeof t?t.split(" "):[t];n<4;n++)r[e+oe[n]+a]=o[n]||o[n-2]||o[0];return r}},"margin"!==e&&(x.cssHooks[e+a].set=na)})),x.fn.extend({css:function(e,a){return F(this,(function(e,a,t){var n,r,o={},i=0;if(Array.isArray(a)){for(n=Fe(e),r=a.length;i1)}}),x.Tween=ia,ia.prototype={constructor:ia,init:function(e,a,t,n,r,o){this.elem=e,this.prop=t,this.easing=r||x.easing._default,this.options=a,this.start=this.now=this.cur(),this.end=n,this.unit=o||(x.cssNumber[t]?"":"px")},cur:function(){var e=ia.propHooks[this.prop];return e&&e.get?e.get(this):ia.propHooks._default.get(this)},run:function(e){var a,t=ia.propHooks[this.prop];return this.options.duration?this.pos=a=x.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=a=e,this.now=(this.end-this.start)*a+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),t&&t.set?t.set(this):ia.propHooks._default.set(this),this}},ia.prototype.init.prototype=ia.prototype,ia.propHooks={_default:{get:function(e){var a;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(a=x.css(e.elem,e.prop,""))&&"auto"!==a?a:0},set:function(e){x.fx.step[e.prop]?x.fx.step[e.prop](e):1!==e.elem.nodeType||!x.cssHooks[e.prop]&&null==e.elem.style[Xe(e.prop)]?e.elem[e.prop]=e.now:x.style(e.elem,e.prop,e.now+e.unit)}}},ia.propHooks.scrollTop=ia.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},x.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},x.fx=ia.prototype.init,x.fx.step={};var sa,ca,ua=/^(?:toggle|show|hide)$/,la=/queueHooks$/;function da(){ca&&(!1===i.hidden&&t.requestAnimationFrame?t.requestAnimationFrame(da):t.setTimeout(da,x.fx.interval),x.fx.tick())}function pa(){return t.setTimeout((function(){sa=void 0})),sa=Date.now()}function fa(e,a){var t,n=0,r={height:e};for(a=a?1:0;n<4;n+=2-a)r["margin"+(t=oe[n])]=r["padding"+t]=e;return a&&(r.opacity=r.width=e),r}function ma(e,a,t){for(var n,r=(ha.tweeners[a]||[]).concat(ha.tweeners["*"]),o=0,i=r.length;o1)},removeAttr:function(e){return this.each((function(){x.removeAttr(this,e)}))}}),x.extend({attr:function(e,a,t){var n,r,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===e.getAttribute?x.prop(e,a,t):(1===o&&x.isXMLDoc(e)||(r=x.attrHooks[a.toLowerCase()]||(x.expr.match.bool.test(a)?va:void 0)),void 0!==t?null===t?void x.removeAttr(e,a):r&&"set"in r&&void 0!==(n=r.set(e,t,a))?n:(e.setAttribute(a,t+""),t):r&&"get"in r&&null!==(n=r.get(e,a))?n:null==(n=x.find.attr(e,a))?void 0:n)},attrHooks:{type:{set:function(e,a){if(!k.radioValue&&"radio"===a&&K(e,"input")){var t=e.value;return e.setAttribute("type",a),t&&(e.value=t),a}}}},removeAttr:function(e,a){var t,n=0,r=a&&a.match(T);if(r&&1===e.nodeType)for(;t=r[n++];)e.removeAttribute(t)}}),va={set:function(e,a,t){return!1===a?x.removeAttr(e,t):e.setAttribute(t,t),t}},x.each(x.expr.match.bool.source.match(/\w+/g),(function(e,a){var t=ka[a]||x.find.attr;ka[a]=function(e,a,n){var r,o,i=a.toLowerCase();return n||(o=ka[i],ka[i]=r,r=null!=t(e,a,n)?i:null,ka[i]=o),r}}));var ga=/^(?:input|select|textarea|button)$/i,ya=/^(?:a|area)$/i;function ba(e){return(e.match(T)||[]).join(" ")}function wa(e){return e.getAttribute&&e.getAttribute("class")||""}function Sa(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(T)||[]}x.fn.extend({prop:function(e,a){return F(this,x.prop,e,a,arguments.length>1)},removeProp:function(e){return this.each((function(){delete this[x.propFix[e]||e]}))}}),x.extend({prop:function(e,a,t){var n,r,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&x.isXMLDoc(e)||(a=x.propFix[a]||a,r=x.propHooks[a]),void 0!==t?r&&"set"in r&&void 0!==(n=r.set(e,t,a))?n:e[a]=t:r&&"get"in r&&null!==(n=r.get(e,a))?n:e[a]},propHooks:{tabIndex:{get:function(e){var a=x.find.attr(e,"tabindex");return a?parseInt(a,10):ga.test(e.nodeName)||ya.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),k.optSelected||(x.propHooks.selected={get:function(e){var a=e.parentNode;return a&&a.parentNode&&a.parentNode.selectedIndex,null},set:function(e){var a=e.parentNode;a&&(a.selectedIndex,a.parentNode&&a.parentNode.selectedIndex)}}),x.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],(function(){x.propFix[this.toLowerCase()]=this})),x.fn.extend({addClass:function(e){var a,t,n,r,o,i,s,c=0;if(g(e))return this.each((function(a){x(this).addClass(e.call(this,a,wa(this)))}));if((a=Sa(e)).length)for(;t=this[c++];)if(r=wa(t),n=1===t.nodeType&&" "+ba(r)+" "){for(i=0;o=a[i++];)n.indexOf(" "+o+" ")<0&&(n+=o+" ");r!==(s=ba(n))&&t.setAttribute("class",s)}return this},removeClass:function(e){var a,t,n,r,o,i,s,c=0;if(g(e))return this.each((function(a){x(this).removeClass(e.call(this,a,wa(this)))}));if(!arguments.length)return this.attr("class","");if((a=Sa(e)).length)for(;t=this[c++];)if(r=wa(t),n=1===t.nodeType&&" "+ba(r)+" "){for(i=0;o=a[i++];)for(;n.indexOf(" "+o+" ")>-1;)n=n.replace(" "+o+" "," ");r!==(s=ba(n))&&t.setAttribute("class",s)}return this},toggleClass:function(e,a){var t=typeof e,n="string"===t||Array.isArray(e);return"boolean"==typeof a&&n?a?this.addClass(e):this.removeClass(e):g(e)?this.each((function(t){x(this).toggleClass(e.call(this,t,wa(this),a),a)})):this.each((function(){var a,r,o,i;if(n)for(r=0,o=x(this),i=Sa(e);a=i[r++];)o.hasClass(a)?o.removeClass(a):o.addClass(a);else void 0!==e&&"boolean"!==t||((a=wa(this))&&X.set(this,"__className__",a),this.setAttribute&&this.setAttribute("class",a||!1===e?"":X.get(this,"__className__")||""))}))},hasClass:function(e){var a,t,n=0;for(a=" "+e+" ";t=this[n++];)if(1===t.nodeType&&(" "+ba(wa(t))+" ").indexOf(a)>-1)return!0;return!1}});var xa=/\r/g;x.fn.extend({val:function(e){var a,t,n,r=this[0];return arguments.length?(n=g(e),this.each((function(t){var r;1===this.nodeType&&(null==(r=n?e.call(this,t,x(this).val()):e)?r="":"number"==typeof r?r+="":Array.isArray(r)&&(r=x.map(r,(function(e){return null==e?"":e+""}))),(a=x.valHooks[this.type]||x.valHooks[this.nodeName.toLowerCase()])&&"set"in a&&void 0!==a.set(this,r,"value")||(this.value=r))}))):r?(a=x.valHooks[r.type]||x.valHooks[r.nodeName.toLowerCase()])&&"get"in a&&void 0!==(t=a.get(r,"value"))?t:"string"==typeof(t=r.value)?t.replace(xa,""):null==t?"":t:void 0}}),x.extend({valHooks:{option:{get:function(e){var a=x.find.attr(e,"value");return null!=a?a:ba(x.text(e))}},select:{get:function(e){var a,t,n,r=e.options,o=e.selectedIndex,i="select-one"===e.type,s=i?null:[],c=i?o+1:r.length;for(n=o<0?c:i?o:0;n-1)&&(t=!0);return t||(e.selectedIndex=-1),o}}}}),x.each(["radio","checkbox"],(function(){x.valHooks[this]={set:function(e,a){if(Array.isArray(a))return e.checked=x.inArray(x(e).val(),a)>-1}},k.checkOn||(x.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})})),k.focusin="onfocusin"in t;var _a=/^(?:focusinfocus|focusoutblur)$/,za=function(e){e.stopPropagation()};x.extend(x.event,{trigger:function(e,a,n,r){var o,s,c,u,l,d,p,f,h=[n||i],v=m.call(e,"type")?e.type:e,k=m.call(e,"namespace")?e.namespace.split("."):[];if(s=f=c=n=n||i,3!==n.nodeType&&8!==n.nodeType&&!_a.test(v+x.event.triggered)&&(v.indexOf(".")>-1&&(k=v.split("."),v=k.shift(),k.sort()),l=v.indexOf(":")<0&&"on"+v,(e=e[x.expando]?e:new x.Event(v,"object"==typeof e&&e)).isTrigger=r?2:3,e.namespace=k.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+k.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=n),a=null==a?[e]:x.makeArray(a,[e]),p=x.event.special[v]||{},r||!p.trigger||!1!==p.trigger.apply(n,a))){if(!r&&!p.noBubble&&!y(n)){for(u=p.delegateType||v,_a.test(u+v)||(s=s.parentNode);s;s=s.parentNode)h.push(s),c=s;c===(n.ownerDocument||i)&&h.push(c.defaultView||c.parentWindow||t)}for(o=0;(s=h[o++])&&!e.isPropagationStopped();)f=s,e.type=o>1?u:p.bindType||v,(d=(X.get(s,"events")||{})[e.type]&&X.get(s,"handle"))&&d.apply(s,a),(d=l&&s[l])&&d.apply&&$(s)&&(e.result=d.apply(s,a),!1===e.result&&e.preventDefault());return e.type=v,r||e.isDefaultPrevented()||p._default&&!1!==p._default.apply(h.pop(),a)||!$(n)||l&&g(n[v])&&!y(n)&&((c=n[l])&&(n[l]=null),x.event.triggered=v,e.isPropagationStopped()&&f.addEventListener(v,za),n[v](),e.isPropagationStopped()&&f.removeEventListener(v,za),x.event.triggered=void 0,c&&(n[l]=c)),e.result}},simulate:function(e,a,t){var n=x.extend(new x.Event,t,{type:e,isSimulated:!0});x.event.trigger(n,null,a)}}),x.fn.extend({trigger:function(e,a){return this.each((function(){x.event.trigger(e,a,this)}))},triggerHandler:function(e,a){var t=this[0];if(t)return x.event.trigger(e,a,t,!0)}}),k.focusin||x.each({focus:"focusin",blur:"focusout"},(function(e,a){var t=function(e){x.event.simulate(a,e.target,x.event.fix(e))};x.event.special[a]={setup:function(){var n=this.ownerDocument||this,r=X.access(n,a);r||n.addEventListener(e,t,!0),X.access(n,a,(r||0)+1)},teardown:function(){var n=this.ownerDocument||this,r=X.access(n,a)-1;r?X.access(n,a,r):(n.removeEventListener(e,t,!0),X.remove(n,a))}}}));var Aa=t.location,Ma=Date.now(),ja=/\?/;x.parseXML=function(e){var a;if(!e||"string"!=typeof e)return null;try{a=(new t.DOMParser).parseFromString(e,"text/xml")}catch(e){a=void 0}return a&&!a.getElementsByTagName("parsererror").length||x.error("Invalid XML: "+e),a};var Ba=/\[\]$/,Ka=/\r?\n/g,Na=/^(?:submit|button|image|reset|file)$/i,Pa=/^(?:input|select|textarea|keygen)/i;function Ea(e,a,t,n){var r;if(Array.isArray(a))x.each(a,(function(a,r){t||Ba.test(e)?n(e,r):Ea(e+"["+("object"==typeof r&&null!=r?a:"")+"]",r,t,n)}));else if(t||"object"!==S(a))n(e,a);else for(r in a)Ea(e+"["+r+"]",a[r],t,n)}x.param=function(e,a){var t,n=[],r=function(e,a){var t=g(a)?a():a;n[n.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==t?"":t)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!x.isPlainObject(e))x.each(e,(function(){r(this.name,this.value)}));else for(t in e)Ea(t,e[t],a,r);return n.join("&")},x.fn.extend({serialize:function(){return x.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var e=x.prop(this,"elements");return e?x.makeArray(e):this})).filter((function(){var e=this.type;return this.name&&!x(this).is(":disabled")&&Pa.test(this.nodeName)&&!Na.test(e)&&(this.checked||!he.test(e))})).map((function(e,a){var t=x(this).val();return null==t?null:Array.isArray(t)?x.map(t,(function(e){return{name:a.name,value:e.replace(Ka,"\r\n")}})):{name:a.name,value:t.replace(Ka,"\r\n")}})).get()}});var La=/%20/g,Ra=/#.*$/,Ca=/([?&])_=[^&]*/,Da=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ta=/^(?:GET|HEAD)$/,Ha=/^\/\//,Oa={},Va={},Ja="*/".concat("*"),Ia=i.createElement("a");function Ga(e){return function(a,t){"string"!=typeof a&&(t=a,a="*");var n,r=0,o=a.toLowerCase().match(T)||[];if(g(t))for(;n=o[r++];)"+"===n[0]?(n=n.slice(1)||"*",(e[n]=e[n]||[]).unshift(t)):(e[n]=e[n]||[]).push(t)}}function Fa(e,a,t,n){var r={},o=e===Va;function i(s){var c;return r[s]=!0,x.each(e[s]||[],(function(e,s){var u=s(a,t,n);return"string"!=typeof u||o||r[u]?o?!(c=u):void 0:(a.dataTypes.unshift(u),i(u),!1)})),c}return i(a.dataTypes[0])||!r["*"]&&i("*")}function qa(e,a){var t,n,r=x.ajaxSettings.flatOptions||{};for(t in a)void 0!==a[t]&&((r[t]?e:n||(n={}))[t]=a[t]);return n&&x.extend(!0,e,n),e}Ia.href=Aa.href,x.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Aa.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Aa.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Ja,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":x.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,a){return a?qa(qa(e,x.ajaxSettings),a):qa(x.ajaxSettings,e)},ajaxPrefilter:Ga(Oa),ajaxTransport:Ga(Va),ajax:function(e,a){"object"==typeof e&&(a=e,e=void 0),a=a||{};var n,r,o,s,c,u,l,d,p,f,m=x.ajaxSetup({},a),h=m.context||m,v=m.context&&(h.nodeType||h.jquery)?x(h):x.event,k=x.Deferred(),g=x.Callbacks("once memory"),y=m.statusCode||{},b={},w={},S="canceled",_={readyState:0,getResponseHeader:function(e){var a;if(l){if(!s)for(s={};a=Da.exec(o);)s[a[1].toLowerCase()+" "]=(s[a[1].toLowerCase()+" "]||[]).concat(a[2]);a=s[e.toLowerCase()+" "]}return null==a?null:a.join(", ")},getAllResponseHeaders:function(){return l?o:null},setRequestHeader:function(e,a){return null==l&&(e=w[e.toLowerCase()]=w[e.toLowerCase()]||e,b[e]=a),this},overrideMimeType:function(e){return null==l&&(m.mimeType=e),this},statusCode:function(e){var a;if(e)if(l)_.always(e[_.status]);else for(a in e)y[a]=[y[a],e[a]];return this},abort:function(e){var a=e||S;return n&&n.abort(a),z(0,a),this}};if(k.promise(_),m.url=((e||m.url||Aa.href)+"").replace(Ha,Aa.protocol+"//"),m.type=a.method||a.type||m.method||m.type,m.dataTypes=(m.dataType||"*").toLowerCase().match(T)||[""],null==m.crossDomain){u=i.createElement("a");try{u.href=m.url,u.href=u.href,m.crossDomain=Ia.protocol+"//"+Ia.host!=u.protocol+"//"+u.host}catch(e){m.crossDomain=!0}}if(m.data&&m.processData&&"string"!=typeof m.data&&(m.data=x.param(m.data,m.traditional)),Fa(Oa,m,a,_),l)return _;for(p in(d=x.event&&m.global)&&0==x.active++&&x.event.trigger("ajaxStart"),m.type=m.type.toUpperCase(),m.hasContent=!Ta.test(m.type),r=m.url.replace(Ra,""),m.hasContent?m.data&&m.processData&&0===(m.contentType||"").indexOf("application/x-www-form-urlencoded")&&(m.data=m.data.replace(La,"+")):(f=m.url.slice(r.length),m.data&&(m.processData||"string"==typeof m.data)&&(r+=(ja.test(r)?"&":"?")+m.data,delete m.data),!1===m.cache&&(r=r.replace(Ca,"$1"),f=(ja.test(r)?"&":"?")+"_="+Ma+++f),m.url=r+f),m.ifModified&&(x.lastModified[r]&&_.setRequestHeader("If-Modified-Since",x.lastModified[r]),x.etag[r]&&_.setRequestHeader("If-None-Match",x.etag[r])),(m.data&&m.hasContent&&!1!==m.contentType||a.contentType)&&_.setRequestHeader("Content-Type",m.contentType),_.setRequestHeader("Accept",m.dataTypes[0]&&m.accepts[m.dataTypes[0]]?m.accepts[m.dataTypes[0]]+("*"!==m.dataTypes[0]?", "+Ja+"; q=0.01":""):m.accepts["*"]),m.headers)_.setRequestHeader(p,m.headers[p]);if(m.beforeSend&&(!1===m.beforeSend.call(h,_,m)||l))return _.abort();if(S="abort",g.add(m.complete),_.done(m.success),_.fail(m.error),n=Fa(Va,m,a,_)){if(_.readyState=1,d&&v.trigger("ajaxSend",[_,m]),l)return _;m.async&&m.timeout>0&&(c=t.setTimeout((function(){_.abort("timeout")}),m.timeout));try{l=!1,n.send(b,z)}catch(e){if(l)throw e;z(-1,e)}}else z(-1,"No Transport");function z(e,a,i,s){var u,p,f,b,w,S=a;l||(l=!0,c&&t.clearTimeout(c),n=void 0,o=s||"",_.readyState=e>0?4:0,u=e>=200&&e<300||304===e,i&&(b=function(e,a,t){for(var n,r,o,i,s=e.contents,c=e.dataTypes;"*"===c[0];)c.shift(),void 0===n&&(n=e.mimeType||a.getResponseHeader("Content-Type"));if(n)for(r in s)if(s[r]&&s[r].test(n)){c.unshift(r);break}if(c[0]in t)o=c[0];else{for(r in t){if(!c[0]||e.converters[r+" "+c[0]]){o=r;break}i||(i=r)}o=o||i}if(o)return o!==c[0]&&c.unshift(o),t[o]}(m,_,i)),b=function(e,a,t,n){var r,o,i,s,c,u={},l=e.dataTypes.slice();if(l[1])for(i in e.converters)u[i.toLowerCase()]=e.converters[i];for(o=l.shift();o;)if(e.responseFields[o]&&(t[e.responseFields[o]]=a),!c&&n&&e.dataFilter&&(a=e.dataFilter(a,e.dataType)),c=o,o=l.shift())if("*"===o)o=c;else if("*"!==c&&c!==o){if(!(i=u[c+" "+o]||u["* "+o]))for(r in u)if((s=r.split(" "))[1]===o&&(i=u[c+" "+s[0]]||u["* "+s[0]])){!0===i?i=u[r]:!0!==u[r]&&(o=s[0],l.unshift(s[1]));break}if(!0!==i)if(i&&e.throws)a=i(a);else try{a=i(a)}catch(e){return{state:"parsererror",error:i?e:"No conversion from "+c+" to "+o}}}return{state:"success",data:a}}(m,b,_,u),u?(m.ifModified&&((w=_.getResponseHeader("Last-Modified"))&&(x.lastModified[r]=w),(w=_.getResponseHeader("etag"))&&(x.etag[r]=w)),204===e||"HEAD"===m.type?S="nocontent":304===e?S="notmodified":(S=b.state,p=b.data,u=!(f=b.error))):(f=S,!e&&S||(S="error",e<0&&(e=0))),_.status=e,_.statusText=(a||S)+"",u?k.resolveWith(h,[p,S,_]):k.rejectWith(h,[_,S,f]),_.statusCode(y),y=void 0,d&&v.trigger(u?"ajaxSuccess":"ajaxError",[_,m,u?p:f]),g.fireWith(h,[_,S]),d&&(v.trigger("ajaxComplete",[_,m]),--x.active||x.event.trigger("ajaxStop")))}return _},getJSON:function(e,a,t){return x.get(e,a,t,"json")},getScript:function(e,a){return x.get(e,void 0,a,"script")}}),x.each(["get","post"],(function(e,a){x[a]=function(e,t,n,r){return g(t)&&(r=r||n,n=t,t=void 0),x.ajax(x.extend({url:e,type:a,dataType:r,data:t,success:n},x.isPlainObject(e)&&e))}})),x._evalUrl=function(e,a){return x.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){x.globalEval(e,a)}})},x.fn.extend({wrapAll:function(e){var a;return this[0]&&(g(e)&&(e=e.call(this[0])),a=x(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&a.insertBefore(this[0]),a.map((function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e})).append(this)),this},wrapInner:function(e){return g(e)?this.each((function(a){x(this).wrapInner(e.call(this,a))})):this.each((function(){var a=x(this),t=a.contents();t.length?t.wrapAll(e):a.append(e)}))},wrap:function(e){var a=g(e);return this.each((function(t){x(this).wrapAll(a?e.call(this,t):e)}))},unwrap:function(e){return this.parent(e).not("body").each((function(){x(this).replaceWith(this.childNodes)})),this}}),x.expr.pseudos.hidden=function(e){return!x.expr.pseudos.visible(e)},x.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},x.ajaxSettings.xhr=function(){try{return new t.XMLHttpRequest}catch(e){}};var Ua={0:200,1223:204},Wa=x.ajaxSettings.xhr();k.cors=!!Wa&&"withCredentials"in Wa,k.ajax=Wa=!!Wa,x.ajaxTransport((function(e){var a,n;if(k.cors||Wa&&!e.crossDomain)return{send:function(r,o){var i,s=e.xhr();if(s.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(i in e.xhrFields)s[i]=e.xhrFields[i];for(i in e.mimeType&&s.overrideMimeType&&s.overrideMimeType(e.mimeType),e.crossDomain||r["X-Requested-With"]||(r["X-Requested-With"]="XMLHttpRequest"),r)s.setRequestHeader(i,r[i]);a=function(e){return function(){a&&(a=n=s.onload=s.onerror=s.onabort=s.ontimeout=s.onreadystatechange=null,"abort"===e?s.abort():"error"===e?"number"!=typeof s.status?o(0,"error"):o(s.status,s.statusText):o(Ua[s.status]||s.status,s.statusText,"text"!==(s.responseType||"text")||"string"!=typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=a(),n=s.onerror=s.ontimeout=a("error"),void 0!==s.onabort?s.onabort=n:s.onreadystatechange=function(){4===s.readyState&&t.setTimeout((function(){a&&n()}))},a=a("abort");try{s.send(e.hasContent&&e.data||null)}catch(e){if(a)throw e}},abort:function(){a&&a()}}})),x.ajaxPrefilter((function(e){e.crossDomain&&(e.contents.script=!1)})),x.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return x.globalEval(e),e}}}),x.ajaxPrefilter("script",(function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")})),x.ajaxTransport("script",(function(e){var a,t;if(e.crossDomain||e.scriptAttrs)return{send:function(n,r){a=x("