!function t(e,r,n){function i(s,a){if(!r[s]){if(!e[s]){var u="function"==typeof require&&require;if(!a&&u)return u(s,!0);if(o)return o(s,!0);var f=new Error("Cannot find module '"+s+"'");throw f.code="MODULE_NOT_FOUND",f}var l=r[s]={exports:{}};e[s][0].call(l.exports,function(t){var r=e[s][1][t];return i(r||t)},l,l.exports,t,e,r,n)}return r[s].exports}for(var o="function"==typeof require&&require,s=0;s0;for(var i in b)(!b[i]&&e.mods.indexOf(+i)>-1||b[i]&&-1===e.mods.indexOf(+i))&&(n=!1);(0!==e.mods.length||b[16]||b[18]||b[17]||b[91])&&!n&&"*"!==e.shortcut||!1===e.method(t,e)&&(t.preventDefault?t.preventDefault():t.returnValue=!1,t.stopPropagation&&t.stopPropagation(),t.cancelBubble&&(t.cancelBubble=!0))}}function o(t,e){if(t.length!==e.length)return!1;for(var r=0;r=0&&g.splice(n,1),93!==r&&224!==r||(r=91),r in b){b[r]=!1;for(var i in d)d[i]===r&&(f[i]=!1)}}function f(t,e,r){var n=a(t),i=[],o=0;for(void 0===r&&(r=e,e="all");o1&&(i=s(t),t=[t[t.length-1]]),(t="*"===(t=t[0])?"*":m(t))in v||(v[t]=[]),v[t].push({shortcut:n[o],scope:e,method:r,key:n[o],mods:i})}Array.prototype.indexOf||(Array.prototype.indexOf=function(t){for(var e=0;e0,h={backspace:8,tab:9,clear:12,enter:13,return:13,esc:27,escape:27,space:32,left:37,up:38,right:39,down:40,del:46,delete:46,home:36,end:35,pageup:33,pagedown:34,"⇪":20,CapsLock:20,",":188,".":190,"/":191,"`":192,"-":c?173:189,"=":c?61:187,";":c?59:186,"'":222,"[":219,"]":221,"\\":220},p="all",d={"⇧":16,shift:16,"⌥":18,alt:18,option:18,"⌃":17,ctrl:17,control:17,"⌘":c?224:91,command:c?224:91},g=[],y={16:"shiftKey",18:"altKey",17:"ctrlKey"},b={16:!1,18:!1,17:!1},m=function(t){return h[t]||t.toUpperCase().charCodeAt(0)},v={},w=1;w<20;w++)h["f"+w]=111+w;y[c?224:91]="metaKey",b[c?224:91]=!1,r(document,"keydown",function(t){n(t)}),r(document,"keyup",function(t){u(t)}),l={setScope:function(t){p=t||"all"},getScope:t,deleteScope:function(t){var e,r,n;for(e in v)for(r=v[e],n=0;n1&&(f=s(n)),e=n[n.length-1],e=m(e),void 0===r&&(r=t()),!v[e])return;for(var c=0;c0)throw new Error("Invalid string. Length must be a multiple of 4");return"="===t[e-2]?2:"="===t[e-1]?1:0}function i(t){return s[t>>18&63]+s[t>>12&63]+s[t>>6&63]+s[63&t]}function o(t,e,r){for(var n,o=[],s=e;s0?f-4:f;var l=0;for(e=0;e>16&255,s[l++]=i>>8&255,s[l++]=255&i;return 2===o?(i=a[t.charCodeAt(e)]<<2|a[t.charCodeAt(e+1)]>>4,s[l++]=255&i):1===o&&(i=a[t.charCodeAt(e)]<<10|a[t.charCodeAt(e+1)]<<4|a[t.charCodeAt(e+2)]>>2,s[l++]=i>>8&255,s[l++]=255&i),s},r.fromByteArray=function(t){for(var e,r=t.length,n=r%3,i="",a=[],u=0,f=r-n;uf?f:u+16383));return 1===n?(e=t[r-1],i+=s[e>>2],i+=s[e<<4&63],i+="=="):2===n&&(e=(t[r-2]<<8)+t[r-1],i+=s[e>>10],i+=s[e>>4&63],i+=s[e<<2&63],i+="="),a.push(i),a.join("")};for(var s=[],a=[],u="undefined"!=typeof Uint8Array?Uint8Array:Array,f="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",l=0,c=f.length;lG)throw new RangeError("Invalid typed array length");var e=new Uint8Array(t);return e.__proto__=i.prototype,e}function i(t,e,r){if("number"==typeof t){if("string"==typeof e)throw new Error("If encoding is specified then the first argument must be a string");return u(t)}return o(t,e,r)}function o(t,e,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return $(t)?c(t,e,r):"string"==typeof t?f(t,e):h(t)}function s(t){if("number"!=typeof t)throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function a(t,e,r){return s(t),t<=0?n(t):void 0!==e?"string"==typeof r?n(t).fill(e,r):n(t).fill(e):n(t)}function u(t){return s(t),n(t<0?0:0|p(t))}function f(t,e){if("string"==typeof e&&""!==e||(e="utf8"),!i.isEncoding(e))throw new TypeError('"encoding" must be a valid string encoding');var r=0|d(t,e),o=n(r),s=o.write(t,e);return s!==r&&(o=o.slice(0,s)),o}function l(t){for(var e=t.length<0?0:0|p(t.length),r=n(e),i=0;i=G)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+G.toString(16)+" bytes");return 0|t}function d(t,e){if(i.isBuffer(t))return t.length;if(V(t)||$(t))return t.byteLength;"string"!=typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var n=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return R(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return W(t).length;default:if(n)return R(t).length;e=(""+e).toLowerCase(),n=!0}}function g(t,e,r){var n=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if(r>>>=0,e>>>=0,r<=e)return"";for(t||(t="utf8");;)switch(t){case"hex":return T(this,e,r);case"utf8":case"utf-8":return C(this,e,r);case"ascii":return A(this,e,r);case"latin1":case"binary":return M(this,e,r);case"base64":return S(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function y(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function b(t,e,r,n,o){if(0===t.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,z(r)&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(o)return-1;r=t.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof e&&(e=i.from(e,n)),i.isBuffer(e))return 0===e.length?-1:m(t,e,r,n,o);if("number"==typeof e)return e&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):m(t,[e],r,n,o);throw new TypeError("val must be string, number or Buffer")}function m(t,e,r,n,i){function o(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}var s=1,a=t.length,u=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return-1;s=2,a/=2,u/=2,r/=2}var f;if(i){var l=-1;for(f=r;fa&&(r=a-u),f=r;f>=0;f--){for(var c=!0,h=0;hi&&(n=i):n=i;var o=e.length;if(o%2!=0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var s=0;s239?4:o>223?3:o>191?2:1;if(i+a<=r){var u,f,l,c;switch(a){case 1:o<128&&(s=o);break;case 2:128==(192&(u=t[i+1]))&&(c=(31&o)<<6|63&u)>127&&(s=c);break;case 3:u=t[i+1],f=t[i+2],128==(192&u)&&128==(192&f)&&(c=(15&o)<<12|(63&u)<<6|63&f)>2047&&(c<55296||c>57343)&&(s=c);break;case 4:u=t[i+1],f=t[i+2],l=t[i+3],128==(192&u)&&128==(192&f)&&128==(192&l)&&(c=(15&o)<<18|(63&u)<<12|(63&f)<<6|63&l)>65535&&c<1114112&&(s=c)}}null===s?(s=65533,a=1):s>65535&&(s-=65536,n.push(s>>>10&1023|55296),s=56320|1023&s),n.push(s),i+=a}return j(n)}function j(t){var e=t.length;if(e<=X)return String.fromCharCode.apply(String,t);for(var r="",n=0;nn)&&(r=n);for(var i="",o=e;or)throw new RangeError("Trying to access beyond buffer length")}function L(t,e,r,n,o,s){if(!i.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>o||et.length)throw new RangeError("Index out of range")}function D(t,e,r,n,i,o){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function B(t,e,r,n,i){return e=+e,r>>>=0,i||D(t,e,r,4,3.4028234663852886e38,-3.4028234663852886e38),Y.write(t,e,r,n,23,4),r+4}function N(t,e,r,n,i){return e=+e,r>>>=0,i||D(t,e,r,8,1.7976931348623157e308,-1.7976931348623157e308),Y.write(t,e,r,n,52,8),r+8}function I(t){if((t=t.trim().replace(Z,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}function P(t){return t<16?"0"+t.toString(16):t.toString(16)}function R(t,e){e=e||1/0;for(var r,n=t.length,i=null,o=[],s=0;s55295&&r<57344){if(!i){if(r>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(s+1===n){(e-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(e-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(e-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((e-=1)<0)break;o.push(r)}else if(r<2048){if((e-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function U(t){for(var e=[],r=0;r>8,i=r%256,o.push(i),o.push(n);return o}function W(t){return H.toByteArray(I(t))}function K(t,e,r,n){for(var i=0;i=e.length||i>=t.length);++i)e[i+r]=t[i];return i}function $(t){return t instanceof ArrayBuffer||null!=t&&null!=t.constructor&&"ArrayBuffer"===t.constructor.name&&"number"==typeof t.byteLength}function V(t){return"function"==typeof ArrayBuffer.isView&&ArrayBuffer.isView(t)}function z(t){return t!==t}var H=t("base64-js"),Y=t("ieee754");r.Buffer=i,r.SlowBuffer=function(t){return+t!=t&&(t=0),i.alloc(+t)},r.INSPECT_MAX_BYTES=50;var G=2147483647;r.kMaxLength=G,i.TYPED_ARRAY_SUPPORT=function(){try{var t=new Uint8Array(1);return t.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===t.foo()}catch(t){return!1}}(),i.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),"undefined"!=typeof Symbol&&Symbol.species&&i[Symbol.species]===i&&Object.defineProperty(i,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),i.poolSize=8192,i.from=function(t,e,r){return o(t,e,r)},i.prototype.__proto__=Uint8Array.prototype,i.__proto__=Uint8Array,i.alloc=function(t,e,r){return a(t,e,r)},i.allocUnsafe=function(t){return u(t)},i.allocUnsafeSlow=function(t){return u(t)},i.isBuffer=function(t){return null!=t&&!0===t._isBuffer},i.compare=function(t,e){if(!i.isBuffer(t)||!i.isBuffer(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var r=t.length,n=e.length,o=0,s=Math.min(r,n);o0&&(t=this.toString("hex",0,e).match(/.{2}/g).join(" "),this.length>e&&(t+=" ... ")),""},i.prototype.compare=function(t,e,r,n,o){if(!i.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),e<0||r>t.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&e>=r)return 0;if(n>=o)return-1;if(e>=r)return 1;if(e>>>=0,r>>>=0,n>>>=0,o>>>=0,this===t)return 0;for(var s=o-n,a=r-e,u=Math.min(s,a),f=this.slice(n,o),l=t.slice(e,r),c=0;c>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-e;if((void 0===r||r>i)&&(r=i),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return v(this,t,e,r);case"utf8":case"utf-8":return w(this,t,e,r);case"ascii":return _(this,t,e,r);case"latin1":case"binary":return x(this,t,e,r);case"base64":return k(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,t,e,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},i.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var X=4096;i.prototype.slice=function(t,e){var r=this.length;t=~~t,e=void 0===e?r:~~e,t<0?(t+=r)<0&&(t=0):t>r&&(t=r),e<0?(e+=r)<0&&(e=0):e>r&&(e=r),e>>=0,e>>>=0,r||q(t,e,this.length);for(var n=this[t],i=1,o=0;++o>>=0,e>>>=0,r||q(t,e,this.length);for(var n=this[t+--e],i=1;e>0&&(i*=256);)n+=this[t+--e]*i;return n},i.prototype.readUInt8=function(t,e){return t>>>=0,e||q(t,1,this.length),this[t]},i.prototype.readUInt16LE=function(t,e){return t>>>=0,e||q(t,2,this.length),this[t]|this[t+1]<<8},i.prototype.readUInt16BE=function(t,e){return t>>>=0,e||q(t,2,this.length),this[t]<<8|this[t+1]},i.prototype.readUInt32LE=function(t,e){return t>>>=0,e||q(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},i.prototype.readUInt32BE=function(t,e){return t>>>=0,e||q(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},i.prototype.readIntLE=function(t,e,r){t>>>=0,e>>>=0,r||q(t,e,this.length);for(var n=this[t],i=1,o=0;++o=i&&(n-=Math.pow(2,8*e)),n},i.prototype.readIntBE=function(t,e,r){t>>>=0,e>>>=0,r||q(t,e,this.length);for(var n=e,i=1,o=this[t+--n];n>0&&(i*=256);)o+=this[t+--n]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*e)),o},i.prototype.readInt8=function(t,e){return t>>>=0,e||q(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},i.prototype.readInt16LE=function(t,e){t>>>=0,e||q(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},i.prototype.readInt16BE=function(t,e){t>>>=0,e||q(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},i.prototype.readInt32LE=function(t,e){return t>>>=0,e||q(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},i.prototype.readInt32BE=function(t,e){return t>>>=0,e||q(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},i.prototype.readFloatLE=function(t,e){return t>>>=0,e||q(t,4,this.length),Y.read(this,t,!0,23,4)},i.prototype.readFloatBE=function(t,e){return t>>>=0,e||q(t,4,this.length),Y.read(this,t,!1,23,4)},i.prototype.readDoubleLE=function(t,e){return t>>>=0,e||q(t,8,this.length),Y.read(this,t,!0,52,8)},i.prototype.readDoubleBE=function(t,e){return t>>>=0,e||q(t,8,this.length),Y.read(this,t,!1,52,8)},i.prototype.writeUIntLE=function(t,e,r,n){t=+t,e>>>=0,r>>>=0,n||L(this,t,e,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[e]=255&t;++o>>=0,r>>>=0,n||L(this,t,e,r,Math.pow(2,8*r)-1,0);var i=r-1,o=1;for(this[e+i]=255&t;--i>=0&&(o*=256);)this[e+i]=t/o&255;return e+r},i.prototype.writeUInt8=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,1,255,0),this[e]=255&t,e+1},i.prototype.writeUInt16LE=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,2,65535,0),this[e]=255&t,this[e+1]=t>>>8,e+2},i.prototype.writeUInt16BE=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,2,65535,0),this[e]=t>>>8,this[e+1]=255&t,e+2},i.prototype.writeUInt32LE=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,4,4294967295,0),this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t,e+4},i.prototype.writeUInt32BE=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,4,4294967295,0),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},i.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e>>>=0,!n){var i=Math.pow(2,8*r-1);L(this,t,e,r,i-1,-i)}var o=0,s=1,a=0;for(this[e]=255&t;++o>0)-a&255;return e+r},i.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e>>>=0,!n){var i=Math.pow(2,8*r-1);L(this,t,e,r,i-1,-i)}var o=r-1,s=1,a=0;for(this[e+o]=255&t;--o>=0&&(s*=256);)t<0&&0===a&&0!==this[e+o+1]&&(a=1),this[e+o]=(t/s>>0)-a&255;return e+r},i.prototype.writeInt8=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,1,127,-128),t<0&&(t=255+t+1),this[e]=255&t,e+1},i.prototype.writeInt16LE=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,2,32767,-32768),this[e]=255&t,this[e+1]=t>>>8,e+2},i.prototype.writeInt16BE=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,2,32767,-32768),this[e]=t>>>8,this[e+1]=255&t,e+2},i.prototype.writeInt32LE=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,4,2147483647,-2147483648),this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24,e+4},i.prototype.writeInt32BE=function(t,e,r){return t=+t,e>>>=0,r||L(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},i.prototype.writeFloatLE=function(t,e,r){return B(this,t,e,!0,r)},i.prototype.writeFloatBE=function(t,e,r){return B(this,t,e,!1,r)},i.prototype.writeDoubleLE=function(t,e,r){return N(this,t,e,!0,r)},i.prototype.writeDoubleBE=function(t,e,r){return N(this,t,e,!1,r)},i.prototype.copy=function(t,e,r,n){if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=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),t.length-e=0;--i)t[i+e]=this[i+r];else if(o<1e3)for(i=0;i>>=0,r=void 0===r?this.length:r>>>0,t||(t=0);var s;if("number"==typeof t)for(s=e;s0&&"number"!=typeof t[0]))}function o(t,e,r){var o,l;if(n(t)||n(e))return!1;if(t.prototype!==e.prototype)return!1;if(u(t))return!!u(e)&&(t=s.call(t),e=s.call(e),f(t,e,r));if(i(t)){if(!i(e))return!1;if(t.length!==e.length)return!1;for(o=0;o=0;o--)if(c[o]!=h[o])return!1;for(o=c.length-1;o>=0;o--)if(l=c[o],!f(t[l],e[l],r))return!1;return typeof t==typeof e}var s=Array.prototype.slice,a=t("./lib/keys.js"),u=t("./lib/is_arguments.js"),f=e.exports=function(t,e,r){return r||(r={}),t===e||(t instanceof Date&&e instanceof Date?t.getTime()===e.getTime():!t||!e||"object"!=typeof t&&"object"!=typeof e?r.strict?t===e:t==e:o(t,e,r))}},{"./lib/is_arguments.js":8,"./lib/keys.js":9}],8:[function(t,e,r){function n(t){return"[object Arguments]"==Object.prototype.toString.call(t)}function i(t){return t&&"object"==typeof t&&"number"==typeof t.length&&Object.prototype.hasOwnProperty.call(t,"callee")&&!Object.prototype.propertyIsEnumerable.call(t,"callee")||!1}var o="[object Arguments]"==function(){return Object.prototype.toString.call(arguments)}();(r=e.exports=o?n:i).supported=n,r.unsupported=i},{}],9:[function(t,e,r){function n(t){var e=[];for(var r in t)e.push(r);return e}(e.exports="function"==typeof Object.keys?Object.keys:n).shim=n},{}],10:[function(t,e,r){"use strict";var n=t("object-keys"),i=t("foreach"),o="function"==typeof Symbol&&"symbol"==typeof Symbol(),s=Object.prototype.toString,a=function(t){return"function"==typeof t&&"[object Function]"===s.call(t)},u=Object.defineProperty&&function(){var t={};try{Object.defineProperty(t,"x",{enumerable:!1,value:t});for(var e in t)return!1;return t.x===t}catch(t){return!1}}(),f=function(t,e,r,n){(!(e in t)||a(n)&&n())&&(u?Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value:r,writable:!0}):t[e]=r)},l=function(t,e){var r=arguments.length>2?arguments[2]:{},s=n(e);o&&(s=s.concat(Object.getOwnPropertySymbols(e))),i(s,function(n){f(t,n,e[n],r[n])})};l.supportsDescriptors=!!u,e.exports=l},{foreach:21,"object-keys":34}],11:[function(t,e,r){e.exports=function(){for(var t=0;t>0},ToUint32:function(t){return this.ToNumber(t)>>>0},ToUint16:function(t){var e=this.ToNumber(t);if(n(e)||0===e||!i(e))return 0;var r=o(e)*Math.floor(Math.abs(e));return s(r,65536)},ToString:function(t){return String(t)},ToObject:function(t){return this.CheckObjectCoercible(t),Object(t)},CheckObjectCoercible:function(t,e){if(null==t)throw new TypeError(e||"Cannot call method on "+t);return t},IsCallable:a,SameValue:function(t,e){return t===e?0!==t||1/t==1/e:n(t)&&n(e)},Type:function(t){return null===t?"Null":void 0===t?"Undefined":"function"==typeof t||"object"==typeof t?"Object":"number"==typeof t?"Number":"boolean"==typeof t?"Boolean":"string"==typeof t?"String":void 0},IsPropertyDescriptor:function(t){if("Object"!==this.Type(t))return!1;var e={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var r in t)if(f(t,r)&&!e[r])return!1;var n=f(t,"[[Value]]"),i=f(t,"[[Get]]")||f(t,"[[Set]]");if(n&&i)throw new TypeError("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){if(void 0===t)return!1;if(!this.IsPropertyDescriptor(t))throw new TypeError("Desc must be a Property Descriptor");return!(!f(t,"[[Get]]")&&!f(t,"[[Set]]"))},IsDataDescriptor:function(t){if(void 0===t)return!1;if(!this.IsPropertyDescriptor(t))throw new TypeError("Desc must be a Property Descriptor");return!(!f(t,"[[Value]]")&&!f(t,"[[Writable]]"))},IsGenericDescriptor:function(t){if(void 0===t)return!1;if(!this.IsPropertyDescriptor(t))throw new TypeError("Desc must be a Property Descriptor");return!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t)},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(!this.IsPropertyDescriptor(t))throw new TypeError("Desc must be a Property Descriptor");if(this.IsDataDescriptor(t))return{value:t["[[Value]]"],writable:!!t["[[Writable]]"],enumerable:!!t["[[Enumerable]]"],configurable:!!t["[[Configurable]]"]};if(this.IsAccessorDescriptor(t))return{get:t["[[Get]]"],set:t["[[Set]]"],enumerable:!!t["[[Enumerable]]"],configurable:!!t["[[Configurable]]"]};throw new TypeError("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new TypeError("ToPropertyDescriptor requires an object");var e={};if(f(t,"enumerable")&&(e["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),f(t,"configurable")&&(e["[[Configurable]]"]=this.ToBoolean(t.configurable)),f(t,"value")&&(e["[[Value]]"]=t.value),f(t,"writable")&&(e["[[Writable]]"]=this.ToBoolean(t.writable)),f(t,"get")){var r=t.get;if(void 0!==r&&!this.IsCallable(r))throw new TypeError("getter must be a function");e["[[Get]]"]=r}if(f(t,"set")){var n=t.set;if(void 0!==n&&!this.IsCallable(n))throw new TypeError("setter must be a function");e["[[Set]]"]=n}if((f(e,"[[Get]]")||f(e,"[[Set]]"))&&(f(e,"[[Value]]")||f(e,"[[Writable]]")))throw new TypeError("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return e}};e.exports=l},{"./helpers/isFinite":13,"./helpers/isNaN":14,"./helpers/mod":15,"./helpers/sign":16,"es-to-primitive/es5":17,has:26,"is-callable":30}],13:[function(t,e,r){var n=Number.isNaN||function(t){return t!==t};e.exports=Number.isFinite||function(t){return"number"==typeof t&&!n(t)&&t!==1/0&&t!==-1/0}},{}],14:[function(t,e,r){e.exports=Number.isNaN||function(t){return t!==t}},{}],15:[function(t,e,r){e.exports=function(t,e){var r=t%e;return Math.floor(r>=0?r:r+e)}},{}],16:[function(t,e,r){e.exports=function(t){return t>=0?1:-1}},{}],17:[function(t,e,r){"use strict";var n=Object.prototype.toString,i=t("./helpers/isPrimitive"),o=t("is-callable"),s={"[[DefaultValue]]":function(t,e){var r=e||("[object Date]"===n.call(t)?String:Number);if(r===String||r===Number){var s,a,u=r===String?["toString","valueOf"]:["valueOf","toString"];for(a=0;a0&&this._events[t].length>r&&(this._events[t].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[t].length),"function"==typeof console.trace&&console.trace()),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(t,e){function r(){this.removeListener(t,r),n||(n=!0,e.apply(this,arguments))}if(!i(e))throw TypeError("listener must be a function");var n=!1;return r.listener=e,this.on(t,r),this},n.prototype.removeListener=function(t,e){var r,n,o,a;if(!i(e))throw TypeError("listener must be a function");if(!this._events||!this._events[t])return this;if(r=this._events[t],o=r.length,n=-1,r===e||i(r.listener)&&r.listener===e)delete this._events[t],this._events.removeListener&&this.emit("removeListener",t,e);else if(s(r)){for(a=o;a-- >0;)if(r[a]===e||r[a].listener&&r[a].listener===e){n=a;break}if(n<0)return this;1===r.length?(r.length=0,delete this._events[t]):r.splice(n,1),this._events.removeListener&&this.emit("removeListener",t,e)}return this},n.prototype.removeAllListeners=function(t){var e,r;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[t]&&delete this._events[t],this;if(0===arguments.length){for(e in this._events)"removeListener"!==e&&this.removeAllListeners(e);return this.removeAllListeners("removeListener"),this._events={},this}if(r=this._events[t],i(r))this.removeListener(t,r);else if(r)for(;r.length;)this.removeListener(t,r[r.length-1]);return delete this._events[t],this},n.prototype.listeners=function(t){return this._events&&this._events[t]?i(this._events[t])?[this._events[t]]:this._events[t].slice():[]},n.prototype.listenerCount=function(t){if(this._events){var e=this._events[t];if(i(e))return 1;if(e)return e.length}return 0},n.listenerCount=function(t,e){return t.listenerCount(e)}},{}],20:[function(t,e,r){function n(t,e,r){for(var n=0,i=t.length;ne.length?t:e,s=t.length>e.length?e:t,a=o.indexOf(s);if(-1!=a)return i=[[1,o.substring(0,a)],[0,s],[1,o.substring(a+s.length)]],t.length>e.length&&(i[0][0]=i[2][0]=-1),i;if(1==s.length)return[[-1,t],[1,e]];var u=this.diff_halfMatch_(t,e);if(u){var f=u[0],l=u[1],c=u[2],h=u[3],p=u[4],d=this.diff_main(f,c,r,n),g=this.diff_main(l,h,r,n);return d.concat([[0,p]],g)}return r&&t.length>100&&e.length>100?this.diff_lineMode_(t,e,n):this.diff_bisect_(t,e,n)},n.prototype.diff_lineMode_=function(t,e,r){var n=this.diff_linesToChars_(t,e);t=n.chars1,e=n.chars2;var i=n.lineArray,o=this.diff_main(t,e,!1,r);this.diff_charsToLines_(o,i),this.diff_cleanupSemantic(o),o.push([0,""]);for(var s=0,a=0,u=0,f="",l="";s=1&&u>=1){o.splice(s-a-u,a+u),s=s-a-u;for(var c=(n=this.diff_main(f,l,!1,r)).length-1;c>=0;c--)o.splice(s,0,n[c]);s+=n.length}u=0,a=0,f="",l=""}s++}return o.pop(),o},n.prototype.diff_bisect_=function(t,e,r){for(var n=t.length,i=e.length,o=Math.ceil((n+i)/2),s=o,a=2*o,u=new Array(a),f=new Array(a),l=0;lr);b++){for(var m=-b+p;m<=b-d;m+=2){for(var v,w=s+m,_=(v=m==-b||m!=b&&u[w-1]n)d+=2;else if(_>i)p+=2;else if(h&&(E=s+c-m)>=0&&E=(k=n-f[E]))return this.diff_bisectSplit_(t,e,v,_,r)}for(var x=-b+g;x<=b-y;x+=2){for(var k,E=s+x,S=(k=x==-b||x!=b&&f[E-1]n)y+=2;else if(S>i)g+=2;else if(!h&&(w=s+c-x)>=0&&w=k)return this.diff_bisectSplit_(t,e,v,_,r)}}}return[[-1,t],[1,e]]},n.prototype.diff_bisectSplit_=function(t,e,r,n,i){var o=t.substring(0,r),s=e.substring(0,n),a=t.substring(r),u=e.substring(n),f=this.diff_main(o,s,!1,i),l=this.diff_main(a,u,!1,i);return f.concat(l)},n.prototype.diff_linesToChars_=function(t,e){function r(t){for(var e="",r=0,o=-1,s=n.length;on?t=t.substring(r-n):r=t.length?[n,i,o,a,l]:null}if(this.Diff_Timeout<=0)return null;var n=t.length>e.length?t:e,i=t.length>e.length?e:t;if(n.length<4||2*i.lengthu[4].length?a:u:a;var f,l,c,h;return t.length>e.length?(f=o[0],l=o[1],c=o[2],h=o[3]):(c=o[0],h=o[1],f=o[2],l=o[3]),[f,l,c,h,o[4]]},n.prototype.diff_cleanupSemantic=function(t){for(var e=!1,r=[],n=0,i=null,o=0,s=0,a=0,u=0,f=0;o0?r[n-1]:-1,s=0,a=0,u=0,f=0,i=null,e=!0)),o++;for(e&&this.diff_cleanupMerge(t),this.diff_cleanupSemanticLossless(t),o=1;o=p?(h>=l.length/2||h>=c.length/2)&&(t.splice(o,0,[0,c.substring(0,h)]),t[o-1][1]=l.substring(0,l.length-h),t[o+1][1]=c.substring(h),o++):(p>=l.length/2||p>=c.length/2)&&(t.splice(o,0,[0,l.substring(0,p)]),t[o-1][0]=1,t[o-1][1]=c.substring(0,c.length-p),t[o+1][0]=-1,t[o+1][1]=l.substring(p),o++),o++}o++}},n.prototype.diff_cleanupSemanticLossless=function(t){function e(t,e){if(!t||!e)return 6;var r=t.charAt(t.length-1),i=e.charAt(0),o=r.match(n.nonAlphaNumericRegex_),s=i.match(n.nonAlphaNumericRegex_),a=o&&r.match(n.whitespaceRegex_),u=s&&i.match(n.whitespaceRegex_),f=a&&r.match(n.linebreakRegex_),l=u&&i.match(n.linebreakRegex_),c=f&&t.match(n.blanklineEndRegex_),h=l&&e.match(n.blanklineStartRegex_);return c||h?5:f||l?4:o&&!a&&u?3:a||u?2:o||s?1:0}for(var r=1;r=h&&(h=p,f=i,l=o,c=s)}t[r-1][1]!=f&&(f?t[r-1][1]=f:(t.splice(r-1,1),r--),t[r][1]=l,c?t[r+1][1]=c:(t.splice(r+1,1),r--))}r++}},n.nonAlphaNumericRegex_=/[^a-zA-Z0-9]/,n.whitespaceRegex_=/\s/,n.linebreakRegex_=/[\r\n]/,n.blanklineEndRegex_=/\n\r?\n$/,n.blanklineStartRegex_=/^\r?\n\r?\n/,n.prototype.diff_cleanupEfficiency=function(t){for(var e=!1,r=[],n=0,i=null,o=0,s=!1,a=!1,u=!1,f=!1;o0?r[n-1]:-1,u=f=!1),e=!0)),o++;e&&this.diff_cleanupMerge(t)},n.prototype.diff_cleanupMerge=function(t){t.push([0,""]);for(var e,r=0,n=0,i=0,o="",s="";r1?(0!==n&&0!==i&&(0!==(e=this.diff_commonPrefix(s,o))&&(r-n-i>0&&0==t[r-n-i-1][0]?t[r-n-i-1][1]+=s.substring(0,e):(t.splice(0,0,[0,s.substring(0,e)]),r++),s=s.substring(e),o=o.substring(e)),0!==(e=this.diff_commonSuffix(s,o))&&(t[r][1]=s.substring(s.length-e)+t[r][1],s=s.substring(0,s.length-e),o=o.substring(0,o.length-e))),0===n?t.splice(r-i,n+i,[1,s]):0===i?t.splice(r-n,n+i,[-1,o]):t.splice(r-n-i,n+i,[-1,o],[1,s]),r=r-n-i+(n?1:0)+(i?1:0)+1):0!==r&&0==t[r-1][0]?(t[r-1][1]+=t[r][1],t.splice(r,1)):r++,i=0,n=0,o="",s=""}""===t[t.length-1][1]&&t.pop();var a=!1;for(r=1;re));r++)o=n,s=i;return t.length!=r&&-1===t[r][0]?s:s+(e-o)},n.prototype.diff_prettyHtml=function(t){for(var e=[],r=/&/g,n=//g,o=/\n/g,s=0;s");switch(a){case 1:e[s]=''+u+"";break;case-1:e[s]=''+u+"";break;case 0:e[s]=""+u+""}}return e.join("")},n.prototype.diff_text1=function(t){for(var e=[],r=0;rthis.Match_MaxBits)throw new Error("Pattern too long for this browser.");var i=this.match_alphabet_(e),o=this,s=this.Match_Threshold,a=t.indexOf(e,r);-1!=a&&(s=Math.min(n(0,a),s),-1!=(a=t.lastIndexOf(e,r+e.length))&&(s=Math.min(n(0,a),s)));var u=1<=d;b--){var m=i[t.charAt(b-1)];if(y[b]=0===p?(y[b+1]<<1|1)&m:(y[b+1]<<1|1)&m|(c[b+1]|c[b])<<1|1|c[b+1],y[b]&u){var v=n(p,b-1);if(v<=s){if(s=v,!((a=b-1)>r))break;d=Math.max(1,2*r-a)}}}if(n(p+1,r)>s)break;c=y}return a},n.prototype.match_alphabet_=function(t){for(var e={},r=0;r2&&(this.diff_cleanupSemantic(o),this.diff_cleanupEfficiency(o));else if(t&&"object"==typeof t&&void 0===e&&void 0===r)o=t,i=this.diff_text1(o);else if("string"==typeof t&&e&&"object"==typeof e&&void 0===r)i=t,o=e;else{if("string"!=typeof t||"string"!=typeof e||!r||"object"!=typeof r)throw new Error("Unknown call format to patch_make.");i=t,o=r}if(0===o.length)return[];for(var s=[],a=new n.patch_obj,u=0,f=0,l=0,c=i,h=i,p=0;p=2*this.Patch_Margin&&u&&(this.patch_addContext_(a,c),s.push(a),a=new n.patch_obj,u=0,c=h,f=l)}1!==d&&(f+=g.length),-1!==d&&(l+=g.length)}return u&&(this.patch_addContext_(a,c),s.push(a)),s},n.prototype.patch_deepCopy=function(t){for(var e=[],r=0;rthis.Match_MaxBits?-1!=(s=this.match_main(e,u.substring(0,this.Match_MaxBits),a))&&(-1==(f=this.match_main(e,u.substring(u.length-this.Match_MaxBits),a+u.length-this.Match_MaxBits))||s>=f)&&(s=-1):s=this.match_main(e,u,a),-1==s)i[o]=!1,n-=t[o].length2-t[o].length1;else{i[o]=!0,n=s-a;var l;if(l=-1==f?e.substring(s,s+u.length):e.substring(s,f+this.Match_MaxBits),u==l)e=e.substring(0,s)+this.diff_text2(t[o].diffs)+e.substring(s+u.length);else{var c=this.diff_main(u,l,!1);if(u.length>this.Match_MaxBits&&this.diff_levenshtein(c)/u.length>this.Patch_DeleteThreshold)i[o]=!1;else{this.diff_cleanupSemanticLossless(c);for(var h,p=0,d=0;do[0][1].length){s=e-o[0][1].length;o[0][1]=r.substring(o[0][1].length)+o[0][1],i.start1-=s,i.start2-=s,i.length1+=s,i.length2+=s}if(i=t[t.length-1],0==(o=i.diffs).length||0!=o[o.length-1][0])o.push([0,r]),i.length1+=e,i.length2+=e;else if(e>o[o.length-1][1].length){var s=e-o[o.length-1][1].length;o[o.length-1][1]+=r.substring(0,s),i.length1+=s,i.length2+=s}return r},n.prototype.patch_splitMax=function(t){for(var e=this.Match_MaxBits,r=0;r2*e?(u.length1+=c.length,o+=c.length,f=!1,u.diffs.push([l,c]),i.diffs.shift()):(c=c.substring(0,e-u.length1-this.Patch_Margin),u.length1+=c.length,o+=c.length,0===l?(u.length2+=c.length,s+=c.length):f=!1,u.diffs.push([l,c]),c==i.diffs[0][1]?i.diffs.shift():i.diffs[0][1]=i.diffs[0][1].substring(c.length))}a=(a=this.diff_text2(u.diffs)).substring(a.length-this.Patch_Margin);var h=this.diff_text1(i.diffs).substring(0,this.Patch_Margin);""!==h&&(u.length1+=h.length,u.length2+=h.length,0!==u.diffs.length&&0===u.diffs[u.diffs.length-1][0]?u.diffs[u.diffs.length-1][1]+=h:u.diffs.push([0,h])),f||t.splice(++r,0,u)}}},n.prototype.patch_toText=function(t){for(var e=[],r=0;r>1,l=-7,c=r?i-1:0,h=r?-1:1,p=t[e+c];for(c+=h,o=p&(1<<-l)-1,p>>=-l,l+=a;l>0;o=256*o+t[e+c],c+=h,l-=8);for(s=o&(1<<-l)-1,o>>=-l,l+=n;l>0;s=256*s+t[e+c],c+=h,l-=8);if(0===o)o=1-f;else{if(o===u)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,n),o-=f}return(p?-1:1)*s*Math.pow(2,o-n)},r.write=function(t,e,r,n,i,o){var s,a,u,f=8*o-i-1,l=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=n?0:o-1,d=n?1:-1,g=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=l):(s=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-s))<1&&(s--,u*=2),(e+=s+c>=1?h/u:h*Math.pow(2,1-c))*u>=2&&(s++,u/=2),s+c>=l?(a=0,s=l):s+c>=1?(a=(e*u-1)*Math.pow(2,i),s+=c):(a=e*Math.pow(2,c-1)*Math.pow(2,i),s=0));i>=8;t[r+p]=255&a,p+=d,a/=256,i-=8);for(s=s<0;t[r+p]=255&s,p+=d,s/=256,f-=8);t[r+p-d]|=128*g}},{}],28:[function(t,e,r){"function"==typeof Object.create?e.exports=function(t,e){t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}},{}],29:[function(t,e,r){function n(t){return!!t.constructor&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)}function i(t){return"function"==typeof t.readFloatLE&&"function"==typeof t.slice&&n(t.slice(0,0))}e.exports=function(t){return null!=t&&(n(t)||i(t)||!!t._isBuffer)}},{}],30:[function(t,e,r){"use strict";var n=Function.prototype.toString,i=/^\s*class /,o=function(t){try{var e=n.call(t).replace(/\/\/.*\n/g,"").replace(/\/\*[.\s\S]*\*\//g,"").replace(/\n/gm," ").replace(/ {2}/g," ");return i.test(e)}catch(t){return!1}},s=function(t){try{return!o(t)&&(n.call(t),!0)}catch(t){return!1}},a=Object.prototype.toString,u="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag;e.exports=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if(u)return s(t);if(o(t))return!1;var e=a.call(t);return"[object Function]"===e||"[object GeneratorFunction]"===e}},{}],31:[function(t,e,r){e.exports=function(t){var e=n.call(t);return"[object Function]"===e||"function"==typeof t&&"[object RegExp]"!==e||"undefined"!=typeof window&&(t===window.setTimeout||t===window.alert||t===window.confirm||t===window.prompt)};var n=Object.prototype.toString},{}],32:[function(t,e,r){var n={}.toString;e.exports=Array.isArray||function(t){return"[object Array]"==n.call(t)}},{}],33:[function(t,e,r){function n(t){return String(t).replace(/"/g,""")}function i(t){return"[object Array]"===p(t)}function o(t){return"[object Date]"===p(t)}function s(t){return"[object RegExp]"===p(t)}function a(t){return"[object Error]"===p(t)}function u(t){return"[object Symbol]"===p(t)}function f(t){return"[object String]"===p(t)}function l(t){return"[object Number]"===p(t)}function c(t){return"[object Boolean]"===p(t)}function h(t,e){return D.call(t,e)}function p(t){return L.call(t)}function d(t){if(t.name)return t.name;var e=String(t).match(/^function\s*([\w$]+)/);return e?e[1]:void 0}function g(t,e){if(t.indexOf)return t.indexOf(e);for(var r=0,n=t.length;r0?"0":"-0":String(e);r||(r={});var E=void 0===r.depth?5:r.depth;if(void 0===h&&(h=0),h>=E&&E>0&&"object"==typeof e)return"[Object]";if(void 0===p)p=[];else if(g(p,e)>=0)return"[Circular]";if("function"==typeof e){var S=d(e);return"[Function"+(S?": "+S:"")+"]"}if(u(e)){var A=Symbol.prototype.toString.call(e);return"object"==typeof e?_(A):A}if(m(e)){for(var M="<"+String(e.nodeName).toLowerCase(),L=e.attributes||[],D=0;D"}if(i(e))return 0===e.length?"[]":"[ "+k(e,w).join(", ")+" ]";if(a(e))return 0===(B=k(e,w)).length?"["+String(e)+"]":"{ ["+String(e)+"] "+B.join(", ")+" }";if("object"==typeof e&&"function"==typeof e.inspect)return e.inspect();if(y(e)){B=[];return j.call(e,function(t,r){B.push(w(r,e)+" => "+w(t,e))}),x("Map",C.call(e),B)}if(b(e)){var B=[];return O.call(e,function(t){B.push(w(t,e))}),x("Set",T.call(e),B)}if(l(e))return _(Number(e));if(c(e))return _(q.call(e));if(f(e))return _(w(String(e)));if(!o(e)&&!s(e)){var N=k(e,w);return 0===N.length?"{}":"{ "+N.join(", ")+" }"}return String(e)};var D=Object.prototype.hasOwnProperty||function(t){return t in this}},{}],34:[function(t,e,r){"use strict";var n=Object.prototype.hasOwnProperty,i=Object.prototype.toString,o=Array.prototype.slice,s=t("./isArguments"),a=Object.prototype.propertyIsEnumerable,u=!a.call({toString:null},"toString"),f=a.call(function(){},"prototype"),l=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],c=function(t){var e=t.constructor;return e&&e.prototype===t},h={$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},p=function(){if("undefined"==typeof window)return!1;for(var t in window)try{if(!h["$"+t]&&n.call(window,t)&&null!==window[t]&&"object"==typeof window[t])try{c(window[t])}catch(t){return!0}}catch(t){return!0}return!1}(),d=function(t){if("undefined"==typeof window||!p)return c(t);try{return c(t)}catch(t){return!1}},g=function(t){var e=null!==t&&"object"==typeof t,r="[object Function]"===i.call(t),o=s(t),a=e&&"[object String]"===i.call(t),c=[];if(!e&&!r&&!o)throw new TypeError("Object.keys called on a non-object");var h=f&&r;if(a&&t.length>0&&!n.call(t,0))for(var p=0;p0)for(var g=0;g=0&&"[object Function]"===n.call(t.callee)),r}},{}],36:[function(t,e,r){(function(t){function e(t,e){for(var r=0,n=t.length-1;n>=0;n--){var i=t[n];"."===i?t.splice(n,1):".."===i?(t.splice(n,1),r++):r&&(t.splice(n,1),r--)}if(e)for(;r--;r)t.unshift("..");return t}function n(t,e){if(t.filter)return t.filter(e);for(var r=[],n=0;n=-1&&!i;o--){var s=o>=0?arguments[o]:t.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(r=s+"/"+r,i="/"===s.charAt(0))}return r=e(n(r.split("/"),function(t){return!!t}),!i).join("/"),(i?"/":"")+r||"."},r.normalize=function(t){var i=r.isAbsolute(t),o="/"===s(t,-1);return(t=e(n(t.split("/"),function(t){return!!t}),!i).join("/"))||i||(t="."),t&&o&&(t+="/"),(i?"/":"")+t},r.isAbsolute=function(t){return"/"===t.charAt(0)},r.join=function(){var t=Array.prototype.slice.call(arguments,0);return r.normalize(n(t,function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},r.relative=function(t,e){function n(t){for(var e=0;e=0&&""===t[r];r--);return e>r?[]:t.slice(e,r-e+1)}t=r.resolve(t).substr(1),e=r.resolve(e).substr(1);for(var i=n(t.split("/")),o=n(e.split("/")),s=Math.min(i.length,o.length),a=s,u=0;u1)for(var r=1;r0?("string"==typeof e||s.objectMode||Object.getPrototypeOf(e)===I.prototype||(e=i(e)),n?s.endEmitted?t.emit("error",new Error("stream.unshift() after end event")):l(t,s,e,!0):s.ended?t.emit("error",new Error("stream.push() after EOF")):(s.reading=!1,s.decoder&&!r?(e=s.decoder.write(e),s.objectMode||0!==e.length?l(t,s,e,!1):m(t,s)):l(t,s,e,!1))):n||(s.reading=!1)}return h(s)}function l(t,e,r,n){e.flowing&&0===e.length&&!e.sync?(t.emit("data",r),t.read(0)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),e.needReadable&&y(t)),m(t,e)}function c(t,e){var r;return o(e)||"string"==typeof e||void 0===e||t.objectMode||(r=new TypeError("Invalid non-string/buffer chunk")),r}function h(t){return!t.ended&&(t.needReadable||t.length=z?t=z:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function d(t,e){return t<=0||0===e.length&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=p(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function g(t,e){if(!e.ended){if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,y(t)}}function y(t){var e=t._readableState;e.needReadable=!1,e.emittedReadable||(F("emitReadable",e.flowing),e.emittedReadable=!0,e.sync?q(b,t):b(t))}function b(t){F("emit readable"),t.emit("readable"),E(t)}function m(t,e){e.readingMore||(e.readingMore=!0,q(v,t,e))}function v(t,e){for(var r=e.length;!e.reading&&!e.flowing&&!e.ended&&e.length=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.head.data:e.buffer.concat(e.length),e.buffer.clear()):r=C(t,e.buffer,e.decoder),r}function C(t,e,r){var n;return to.length?o.length:t;if(s===o.length?i+=o:i+=o.slice(0,t),0===(t-=s)){s===o.length?(++n,r.next?e.head=r.next:e.head=e.tail=null):(e.head=r,r.data=o.slice(s));break}++n}return e.length-=n,i}function A(t,e){var r=I.allocUnsafe(t),n=e.head,i=1;for(n.data.copy(r),t-=n.data.length;n=n.next;){var o=n.data,s=t>o.length?o.length:t;if(o.copy(r,r.length-t,0,s),0===(t-=s)){s===o.length?(++i,n.next?e.head=n.next:e.head=e.tail=null):(e.head=n,n.data=o.slice(s));break}++i}return e.length-=i,r}function M(t){var e=t._readableState;if(e.length>0)throw new Error('"endReadable()" called on non-empty stream');e.endEmitted||(e.ended=!0,q(T,e,t))}function T(t,e){t.endEmitted||0!==t.length||(t.endEmitted=!0,e.readable=!1,e.emit("end"))}function O(t,e){for(var r=0,n=t.length;r=e.highWaterMark||e.ended))return F("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?M(this):y(this),null;if(0===(t=d(t,e))&&e.ended)return 0===e.length&&M(this),null;var n=e.needReadable;F("need readable",n),(0===e.length||e.length-t0?S(t,e):null)?(e.needReadable=!0,t=0):e.length-=t,0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&M(this)),null!==i&&this.emit("data",i),i},u.prototype._read=function(t){this.emit("error",new Error("_read() is not implemented"))},u.prototype.pipe=function(t,e){function n(t,e){F("onunpipe"),t===h&&e&&!1===e.hasUnpiped&&(e.hasUnpiped=!0,o())}function i(){F("onend"),t.end()}function o(){F("cleanup"),t.removeListener("close",f),t.removeListener("finish",l),t.removeListener("drain",g),t.removeListener("error",u),t.removeListener("unpipe",n),h.removeListener("end",i),h.removeListener("end",c),h.removeListener("data",a),y=!0,!p.awaitDrain||t._writableState&&!t._writableState.needDrain||g()}function a(e){F("ondata"),b=!1,!1!==t.write(e)||b||((1===p.pipesCount&&p.pipes===t||p.pipesCount>1&&-1!==O(p.pipes,t))&&!y&&(F("false write response, pause",h._readableState.awaitDrain),h._readableState.awaitDrain++,b=!0),h.pause())}function u(e){F("onerror",e),c(),t.removeListener("error",u),0===B(t,"error")&&t.emit("error",e)}function f(){t.removeListener("finish",l),c()}function l(){F("onfinish"),t.removeListener("close",f),c()}function c(){F("unpipe"),h.unpipe(t)}var h=this,p=this._readableState;switch(p.pipesCount){case 0:p.pipes=t;break;case 1:p.pipes=[p.pipes,t];break;default:p.pipes.push(t)}p.pipesCount+=1,F("pipe count=%d opts=%j",p.pipesCount,e);var d=(!e||!1!==e.end)&&t!==r.stdout&&t!==r.stderr?i:c;p.endEmitted?q(d):h.once("end",d),t.on("unpipe",n);var g=w(h);t.on("drain",g);var y=!1,b=!1;return h.on("data",a),s(t,"error",u),t.once("close",f),t.once("finish",l),t.emit("pipe",h),p.flowing||(F("pipe resume"),h.resume()),t},u.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var n=e.pipes,i=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o-1?setImmediate:j;f.WritableState=u;var T=t("core-util-is");T.inherits=t("inherits");var O={deprecate:t("util-deprecate")},q=t("./internal/streams/stream"),L=t("safe-buffer").Buffer,D=n.Uint8Array||function(){},B=t("./internal/streams/destroy");T.inherits(f,q),u.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(u.prototype,"buffer",{get:O.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}();var N;"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(N=Function.prototype[Symbol.hasInstance],Object.defineProperty(f,Symbol.hasInstance,{value:function(t){return!!N.call(this,t)||t&&t._writableState instanceof u}})):N=function(t){return t instanceof this},f.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},f.prototype.write=function(t,e,r){var n=this._writableState,i=!1,u=s(t)&&!n.objectMode;return u&&!L.isBuffer(t)&&(t=o(t)),"function"==typeof e&&(r=e,e=null),u?e="buffer":e||(e=n.defaultEncoding),"function"!=typeof r&&(r=a),n.ended?l(this,r):(u||c(this,n,t,r))&&(n.pendingcb++,i=p(this,n,u,t,e,r)),i},f.prototype.cork=function(){this._writableState.corked++},f.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,t.writing||t.corked||t.finished||t.bufferProcessing||!t.bufferedRequest||w(this,t))},f.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},f.prototype._write=function(t,e,r){r(new Error("_write() is not implemented"))},f.prototype._writev=null,f.prototype.end=function(t,e,r){var n=this._writableState;"function"==typeof t?(r=t,t=null,e=null):"function"==typeof e&&(r=e,e=null),null!==t&&void 0!==t&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||n.finished||S(this,n,r)},Object.defineProperty(f.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),f.prototype.destroy=B.destroy,f.prototype._undestroy=B.undestroy,f.prototype._destroy=function(t,e){this.end(),e(t)}}).call(this,t("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./_stream_duplex":40,"./internal/streams/destroy":46,"./internal/streams/stream":47,_process:38,"core-util-is":6,inherits:28,"process-nextick-args":37,"safe-buffer":53,"util-deprecate":67}],45:[function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e,r){t.copy(e,r)}var o=t("safe-buffer").Buffer;e.exports=function(){function t(){n(this,t),this.head=null,this.tail=null,this.length=0}return t.prototype.push=function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length},t.prototype.unshift=function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length},t.prototype.shift=function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},t.prototype.clear=function(){this.head=this.tail=null,this.length=0},t.prototype.join=function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r},t.prototype.concat=function(t){if(0===this.length)return o.alloc(0);if(1===this.length)return this.head.data;for(var e=o.allocUnsafe(t>>>0),r=this.head,n=0;r;)i(r.data,e,n),n+=r.data.length,r=r.next;return e},t}()},{"safe-buffer":53}],46:[function(t,e,r){"use strict";function n(t,e){t.emit("error",e)}var i=t("process-nextick-args");e.exports={destroy:function(t,e){var r=this,o=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;o||s?e?e(t):!t||this._writableState&&this._writableState.errorEmitted||i(n,this,t):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(t){!e&&t?(i(n,r,t),r._writableState&&(r._writableState.errorEmitted=!0)):e&&e(t)}))},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},{"process-nextick-args":37}],47:[function(t,e,r){e.exports=t("events").EventEmitter},{events:19}],48:[function(t,e,r){e.exports=t("./readable").PassThrough},{"./readable":49}],49:[function(t,e,r){(r=e.exports=t("./lib/_stream_readable.js")).Stream=r,r.Readable=r,r.Writable=t("./lib/_stream_writable.js"),r.Duplex=t("./lib/_stream_duplex.js"),r.Transform=t("./lib/_stream_transform.js"),r.PassThrough=t("./lib/_stream_passthrough.js")},{"./lib/_stream_duplex.js":40,"./lib/_stream_passthrough.js":41,"./lib/_stream_readable.js":42,"./lib/_stream_transform.js":43,"./lib/_stream_writable.js":44}],50:[function(t,e,r){e.exports=t("./readable").Transform},{"./readable":49}],51:[function(t,e,r){e.exports=t("./lib/_stream_writable.js")},{"./lib/_stream_writable.js":44}],52:[function(t,e,r){(function(r){var n=t("through"),i="undefined"!=typeof setImmediate?setImmediate:r.nextTick;e.exports=function(t,e){var r=n(t,e);r.pause();var o=r.resume,s=r.pause,a=!1;return r.pause=function(){return a=!0,s.apply(this,arguments)},r.resume=function(){return a=!1,o.apply(this,arguments)},i(function(){a||r.resume()}),r}}).call(this,t("_process"))},{_process:38,through:66}],53:[function(t,e,r){function n(t,e){for(var r in t)e[r]=t[r]}function i(t,e,r){return s(t,e,r)}var o=t("buffer"),s=o.Buffer;s.from&&s.alloc&&s.allocUnsafe&&s.allocUnsafeSlow?e.exports=o:(n(o,r),r.Buffer=i),n(s,i),i.from=function(t,e,r){if("number"==typeof t)throw new TypeError("Argument must not be a number");return s(t,e,r)},i.alloc=function(t,e,r){if("number"!=typeof t)throw new TypeError("Argument must be a number");var n=s(t);return void 0!==e?"string"==typeof r?n.fill(e,r):n.fill(e):n.fill(0),n},i.allocUnsafe=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return s(t)},i.allocUnsafeSlow=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return o.SlowBuffer(t)}},{buffer:5}],54:[function(t,e,r){function n(){i.call(this)}e.exports=n;var i=t("events").EventEmitter;t("inherits")(n,i),n.Readable=t("readable-stream/readable.js"),n.Writable=t("readable-stream/writable.js"),n.Duplex=t("readable-stream/duplex.js"),n.Transform=t("readable-stream/transform.js"),n.PassThrough=t("readable-stream/passthrough.js"),n.Stream=n,n.prototype.pipe=function(t,e){function r(e){t.writable&&!1===t.write(e)&&f.pause&&f.pause()}function n(){f.readable&&f.resume&&f.resume()}function o(){l||(l=!0,t.end())}function s(){l||(l=!0,"function"==typeof t.destroy&&t.destroy())}function a(t){if(u(),0===i.listenerCount(this,"error"))throw t}function u(){f.removeListener("data",r),t.removeListener("drain",n),f.removeListener("end",o),f.removeListener("close",s),f.removeListener("error",a),t.removeListener("error",a),f.removeListener("end",u),f.removeListener("close",u),t.removeListener("close",u)}var f=this;f.on("data",r),t.on("drain",n),t._isStdio||e&&!1===e.end||(f.on("end",o),f.on("close",s));var l=!1;return f.on("error",a),t.on("error",a),f.on("end",u),f.on("close",u),t.on("close",u),t.emit("pipe",f),t}},{events:19,inherits:28,"readable-stream/duplex.js":39,"readable-stream/passthrough.js":48,"readable-stream/readable.js":49,"readable-stream/transform.js":50,"readable-stream/writable.js":51}],55:[function(t,e,r){"use strict";var n=t("function-bind"),i=t("es-abstract/es5"),o=n.call(Function.call,String.prototype.replace),s=/^[\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF]+/,a=/[\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF]+$/;e.exports=function(){var t=i.ToString(i.CheckObjectCoercible(this));return o(o(t,s,""),a,"")}},{"es-abstract/es5":12,"function-bind":23}],56:[function(t,e,r){"use strict";var n=t("function-bind"),i=t("define-properties"),o=t("./implementation"),s=t("./polyfill"),a=t("./shim"),u=n.call(Function.call,s());i(u,{getPolyfill:s,implementation:o,shim:a}),e.exports=u},{"./implementation":55,"./polyfill":57,"./shim":58,"define-properties":10,"function-bind":23}],57:[function(t,e,r){"use strict";var n=t("./implementation");e.exports=function(){return String.prototype.trim&&"​"==="​".trim()?String.prototype.trim:n}},{"./implementation":55}],58:[function(t,e,r){"use strict";var n=t("define-properties"),i=t("./polyfill");e.exports=function(){var t=i();return n(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t}},{"./polyfill":57,"define-properties":10}],59:[function(t,e,r){"use strict";function n(t){if(!t)return"utf8";for(var e;;)switch(t){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function i(t){var e=n(t);if("string"!=typeof e&&(y.isEncoding===b||!b(t)))throw new Error("Unknown encoding: "+t);return e||t}function o(t){this.encoding=i(t);var e;switch(this.encoding){case"utf16le":this.text=l,this.end=c,e=4;break;case"utf8":this.fillLast=f,e=4;break;case"base64":this.text=h,this.end=p,e=3;break;default:return this.write=d,void(this.end=g)}this.lastNeed=0,this.lastTotal=0,this.lastChar=y.allocUnsafe(e)}function s(t){return t<=127?0:t>>5==6?2:t>>4==14?3:t>>3==30?4:-1}function a(t,e,r){var n=e.length-1;if(n=0?(i>0&&(t.lastNeed=i-1),i):--n=0?(i>0&&(t.lastNeed=i-2),i):--n=0?(i>0&&(2===i?i=0:t.lastNeed=i-3),i):0}function u(t,e,r){if(128!=(192&e[0]))return t.lastNeed=0,"�".repeat(r);if(t.lastNeed>1&&e.length>1){if(128!=(192&e[1]))return t.lastNeed=1,"�".repeat(r+1);if(t.lastNeed>2&&e.length>2&&128!=(192&e[2]))return t.lastNeed=2,"�".repeat(r+2)}}function f(t){var e=this.lastTotal-this.lastNeed,r=u(this,t,e);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(t.copy(this.lastChar,e,0,t.length),void(this.lastNeed-=t.length))}function l(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function c(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function h(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function p(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function d(t){return t.toString(this.encoding)}function g(t){return t&&t.length?this.write(t):""}var y=t("safe-buffer").Buffer,b=y.isEncoding||function(t){switch((t=""+t)&&t.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};r.StringDecoder=o,o.prototype.write=function(t){if(0===t.length)return"";var e,r;if(this.lastNeed){if(void 0===(e=this.fillLast(t)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r"+t[1]+""}),i}function i(t){var e=document.createElement("DIV");e.id=t.id,e.setAttribute("class","test");var r=document.createElement("P");return r.setAttribute("class","name"),r.appendChild(document.createTextNode(t.name)),e.appendChild(r),d=e,p.appendChild(e),e}function o(t,e){var r=document.createElement("P");r.setAttribute("class","assert "+(t.ok?"ok":"fail"));var n=document.createElement("SPAN");if(n.setAttribute("class","ok"),n.appendChild(document.createTextNode(t.ok?"OK":"FAIL")),r.appendChild(n),t.name){var i=document.createElement("SPAN");i.setAttribute("class","name"),i.appendChild(document.createTextNode(t.name)),r.appendChild(i)}return e.appendChild(r),r.scrollIntoView({block:"end",behavior:"smooth"}),r}function s(t,e){var r=document.createElement("P");return r.setAttribute("class","comment"),r.appendChild(document.createTextNode(t)),e.appendChild(r),r}function a(t,e){var r=document.createElement("P");return r.setAttribute("class","end"),e.appendChild(r),r}function u(t,e){var r=t.actual,i=t.expected;r&&i&&"object"==typeof r&&"object"==typeof i&&(r=JSON.stringify(r),i=JSON.stringify(i));var o=document.createElement("SPAN");o.setAttribute("class","actual"),o.appendChild(document.createTextNode(r)),e.appendChild(o);var s=document.createElement("SPAN");if(s.setAttribute("class","expected"),s.appendChild(document.createTextNode(i)),e.appendChild(s),t.file){var a=document.createElement("SPAN");a.setAttribute("class","line");var u=/\/([^\/]+)$/.exec(t.file)[1];a.appendChild(document.createTextNode(u)),e.appendChild(a),console.warn(t.error.stack)}if(r&&i&&r.constructor==String&&i.constructor==String){var f=document.createElement("P");f.setAttribute("class","diff"),f.innerHTML=n(r,i),e.appendChild(f)}}function f(t){if("test"===t.type)d=i(t,d);else if("assert"===t.type){var e=o(t,d);t.ok||u(t,e)}else"end"===t.type?(a(t,d),d=d.parentNode):t.constructor===String?s(t,d):console.warn("tape-dom row",t.type,t)}function l(t){t.createStream({objectMode:!0}).on("data",f)}function c(){var t=document.createElement("style");t.setAttribute("type","text/css");var e=document.createTextNode(y);t.appendChild(e),document.head.appendChild(t)}function h(t){return"object"==typeof window&&(c(),l(t)),h}var p,d,g=new(t("googlediff")),y=t("./tape_css");"object"==typeof document&&((p=document.getElementById("tests"))||((p=document.createElement("div")).setAttribute("id","tests"),document.body.appendChild(p)),d=p),h.installCSS=c,h.stream=l,e.exports=h},{"./tape_css":61,googlediff:24}],61:[function(t,e,r){"use strict";e.exports="div.test{width:100%;border-top:1px dotted grey;margin-top:1em;background:#eef;font-weight:700;margin-bottom:1em}div#tests{margin-bottom:5em}p.assert{margin-top:0;margin-bottom:0;font-weight:400;width:100%}p.assert.ok{background:#efe;color:grey}p.assert.fail{background:#faa}p.comment{background:#eef;color:grey;font-style:italic;margin-top:.2em;margin-bottom:.2em;padding-left:2.4em}p.end{border-bottom:1px dotted grey;margin-top:1em;background:#eef;margin-top:.2em;margin-bottom:.2em}p.diff{background:#ffe;margin-top:0;margin-bottom:0;padding-top:.25em;padding-bottom:.25em;padding-left:4em;font-weight:400;white-space:pre-wrap}ins{background:#afa}del{background:#faa;text-decoration:strike}span.ok{font-weight:700}span.actual,span.expected,span.name{padding-left:1em;font-style:italic;max-width:25em;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:inline-block}p.assert.fail span.name{color:#555}span.expected:before{content:'!=';padding-right:1em}span.line{padding-left:1em;float:right;text-align:right;overflow:hidden;text-overflow:ellipsis;font-family:monospace;color:#888}"},{}],62:[function(t,e,r){(function(n){function i(t){t||(t={});var e=o({autoclose:s(t.autoclose,!1)}),r=e.createStream({objectMode:t.objectMode}),i=r.pipe(t.stream||a());c&&i.on("error",function(t){e._exitCode=1});var u=!1;if(r.on("end",function(){u=!0}),!1===t.exit)return e;if(!c||!h)return e;return n.on("exit",function(t){if(0===t){if(!u)for(var r=e._results._only,i=0;i65||s(n)||s(i)?(r+=" expected: |-\n "+n+"\n",r+=" actual: |-\n "+i+"\n"):(r+=" expected: "+n+"\n",r+=" actual: "+i+"\n")}t.at&&(r+=" at: "+t.at+"\n");var o=t.actual&&t.actual.stack,u=t.error&&t.error.stack,f=a(o,u);if(f){var l=String(f).split("\n");r+=" stack: |-\n";for(var c=0;c=1&&t&&this.ifError(t),this.calledEnd&&this.fail(".end() called twice"),this.calledEnd=!0,this._end()},i.prototype._end=function(t){var e=this;if(this._progeny.length){var r=this._progeny.shift();return r.on("end",function(){e._end()}),void r.run()}this.ended||this.emit("end");var n=this._pendingAsserts();!this._planError&&void 0!==this._plan&&n&&(this._planError=!0,this.fail("plan != count",{expected:this._plan,actual:this.assertCount})),this.ended=!0},i.prototype._exit=function(){void 0===this._plan||this._planError||this.assertCount===this._plan?this.ended||this.fail("test exited without ending",{exiting:!0}):(this._planError=!0,this.fail("plan != count",{expected:this._plan,actual:this.assertCount,exiting:!0}))},i.prototype._pendingAsserts=function(){return void 0===this._plan?1:this._plan-(this._progeny.length+this.assertCount)},i.prototype._assert=function(t,e){var r=this,i=e.extra||{},o={id:r.assertCount++,ok:Boolean(t),skip:s(i.skip,e.skip),name:s(i.message,e.message,"(unnamed assert)"),operator:s(i.operator,e.operator),objectPrintDepth:r._objectPrintDepth};if((l(e,"actual")||l(i,"actual"))&&(o.actual=s(i.actual,e.actual)),(l(e,"expected")||l(i,"expected"))&&(o.expected=s(i.expected,e.expected)),this._ok=Boolean(this._ok&&t),t||(o.error=s(i.error,e.error,new Error(o.name))),!t)for(var u=(new Error("exception").stack||"").split("\n"),f=a.dirname(n)+a.sep,c=0;c0;i("hotkeys 单元测试",function(t){o("w",function(e){t.equal(e.keyCode,87,"单个按键 w keyCode == 87")}),n(document.body,87),o("enter",function(e){t.equal(e.keyCode,13,"单个特殊键按键 enter,enter验证 keyCode == 13")}),o("return",function(e){t.equal(e.keyCode,13,"单个特殊键按键 return,return验证 keyCode == 13")}),n(document.body,13),o("space",function(e){t.equal(e.keyCode,32,"单个特殊键按键 space,space验证 keyCode == 32")}),n(document.body,32),o("backspace",function(e){t.equal(e.keyCode,8,"单个特殊键按键 backspace,backspace 验证 keyCode == 8")}),n(document.body,8),o("tab",function(e){t.equal(e.keyCode,9,"单个特殊键按键 tab,tab 验证 keyCode == 9")}),n(document.body,9),o("clear",function(e){t.equal(e.keyCode,12,"单个特殊键按键 clear,clear 验证 keyCode == 12")}),n(document.body,12),o(",",function(e){t.equal(e.keyCode,188,"单个特殊键按键 , ,, 验证 keyCode == 188")}),n(document.body,188),o(".",function(e){t.equal(e.keyCode,190,"单个特殊键按键 . ,. 验证 keyCode == 190")}),n(document.body,190),o(".",function(e){t.equal(e.keyCode,190,"单个特殊键按键 . ,. 验证 keyCode == 190")}),n(document.body,190),o("/",function(e){t.equal(e.keyCode,191,"单个特殊键按键 / ,/ 验证 keyCode == 191")}),n(document.body,191),o("`",function(e){t.equal(e.keyCode,192,"单个特殊键按键 ` ,` 验证 keyCode == 192")}),n(document.body,192),o("-",function(e){t.equal(e.keyCode,s?173:189,"单个特殊键按键 -,- 验证 keyCode == 火狐?173:189")}),n(document.body,s?173:189),o("=",function(e){t.equal(e.keyCode,s?61:187,"单个特殊键按键 =,= 验证 keyCode == 火狐?61:187")}),n(document.body,s?61:187),o(";",function(e){t.equal(e.keyCode,s?59:186,"单个特殊键按键 ; ,; 验证 keyCode == 火狐?59:186")}),n(document.body,s?59:186),o("'".toString(),function(e){t.equal(e.keyCode,222,"单个特殊键按键 ' ,' 验证 keyCode == 222 ")}),n(document.body,222),o("\\".toString(),function(e){t.equal(e.keyCode,220,"单个特殊键按键 \\ ,\\ 验证 keyCode == 220 ")}),n(document.body,220),o("[".toString(),function(e){t.equal(e.keyCode,219,"单个特殊键按键 [ ,[ 验证 keyCode == 219 ")}),n(document.body,219),o("]".toString(),function(e){t.equal(e.keyCode,221,"单个特殊键按键 ] ,] 验证 keyCode == 221 ")}),n(document.body,221),o("left",function(e){t.equal(e.keyCode,37,"单个特殊键按键 left,left 验证 keyCode == 37")}),n(document.body,37),o("up",function(e){t.equal(e.keyCode,38,"单个特殊键按键 up,up 验证 keyCode == 38")}),n(document.body,38),o("del",function(e){t.equal(e.keyCode,46,"单个特殊键按键 del,del 验证 keyCode == 46")}),o("delete",function(e){t.equal(e.keyCode,46,"单个特殊键按键 delete,delete 验证 keyCode == 46")}),n(document.body,46),o("home",function(e){t.equal(e.keyCode,36,"单个特殊键按键 home,home 验证 keyCode == 36")}),n(document.body,36),o("pageup",function(e){t.equal(e.keyCode,33,"单个特殊键按键 pageup,pageup 验证 keyCode == 33")}),n(document.body,33),o("pagedown",function(e){t.equal(e.keyCode,34,"单个特殊键按键 pagedown,pagedown 验证 keyCode == 34")}),n(document.body,34),o("end",function(e){t.equal(e.keyCode,35,"单个特殊键按键 end,end 验证 keyCode == 35")}),n(document.body,35),o("right",function(e){t.equal(e.keyCode,39,"单个特殊键按键 right,right 验证 keyCode == 39")}),n(document.body,39),o("down",function(e){t.equal(e.keyCode,40,"单个特殊键按键 down,down 验证 keyCode == 40")}),n(document.body,40),o("esc",function(e){t.equal(e.keyCode,27,"单个特殊键按键 esc,esc 验证 keyCode == 27")}),o("escape",function(e){t.equal(e.keyCode,27,"单个特殊键按键 escape,escape 验证 keyCode == 27")}),n(document.body,27),o("CapsLock",function(e){t.equal(e.keyCode,20,"单个特殊键按键 CapsLock,CapsLock验证 keyCode == 20")}),o("⇪",function(e){t.equal(e.keyCode,20,"单个特殊键按键 ⇪,⇪验证 keyCode == 20")}),n(document.body,20),o("⌘+r",function(e){return t.equal(e.keyCode,82,"组合键 ⌘+d,d验证 keyCode == 82"),t.equal(e.metaKey,!0,"组合键 ⌘+d,alt验证 metaKey == true"),!1}),n(document.body,82,{metaKey:!0}),o("alt+d",function(e){t.equal(e.keyCode,68,"组合键 alt+d,d验证 keyCode == 68"),t.equal(e.altKey,!0,"组合键 alt+d,alt验证 altKey == true")}),n(document.body,68,{altKey:!0}),o("shift+a",function(e){t.equal(e.keyCode,65,"组合键 shift+a,a验证 keyCode == 65"),t.equal(e.shiftKey,!0,"组合键 shift+a,shift验证 shiftKey == true")}),n(document.body,65,{shiftKey:!0}),o("⇧+a",function(e){t.equal(e.keyCode,65,"组合键 ⇧+a,a验证 keyCode == 65"),t.equal(e.shiftKey,!0,"组合键 ⇧+a,⇧验证 shiftKey == true")}),n(document.body,65,{shiftKey:!0}),o("⌘+a",function(e){t.equal(e.keyCode,65,"组合键 ⌘+a,a验证 keyCode == 65"),t.equal(e.metaKey,!0,"组合键 ⌘+a,⌘验证 metaKey == true")}),n(document.body,65,{metaKey:!0}),o("⌃+a",function(e){t.equal(e.keyCode,65,"组合键 ⌃+a,a验证 keyCode == 65"),t.equal(e.ctrlKey,!0,"组合键 ⌃+a,⌃验证 ctrlKey == true")}),n(document.body,65,{ctrlKey:!0}),o("⌥+a",function(e){t.equal(e.keyCode,65,"组合键 ⌥+a,a验证 keyCode == 65"),t.equal(e.altKey,!0,"组合键 ⌥+a,⌥验证 altKey == true")}),n(document.body,65,{altKey:!0})})},{"../dist/hotkeys.js":1,tape:62,"tape-dom":60}]},{},[68]);