From c95686db2ca485d208c053750e4df85a64b419f5 Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Fri, 23 Oct 2015 22:02:48 +0200 Subject: [PATCH] Refactor browserify system Instead of opting to replace when compiling to the distribution files, this refactoring uses the `package.json`s `browser` field. This ensures other tools adhering to that `browser` field work. Related to GH-1. --- package.json | 5 ++++- unified.js | 53 ++++++++++++++++++++++++++++++++++++++++++++++++-- unified.min.js | 2 +- 3 files changed, 56 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 730d119d..e505422a 100644 --- a/package.json +++ b/package.json @@ -21,6 +21,9 @@ "vfile": "^1.0.0", "ware": "^1.3.0" }, + "browser": { + "node-extend": "extend" + }, "repository": { "type": "git", "url": "https://github.com/wooorm/unified.git" @@ -56,7 +59,7 @@ "lint": "npm run lint-api && npm run lint-style", "make": "npm run lint && npm run test-coverage", "build-md": "mdast . --quiet", - "build-bundle": "browserify index.js -s AttachWare -u node-extend > unified.js", + "build-bundle": "browserify index.js -s AttachWare > unified.js", "postbuild-bundle": "esmangle unified.js > unified.min.js", "build": "npm run build-md && npm run build-bundle" } diff --git a/unified.js b/unified.js index d3731339..f0e46f40 100644 --- a/unified.js +++ b/unified.js @@ -292,7 +292,7 @@ function unified(options) { module.exports = unified; -},{"attach-ware":2,"bail":3,"extend":8,"node-extend":undefined,"unherit":12,"vfile":13,"ware":14}],2:[function(require,module,exports){ +},{"attach-ware":2,"bail":3,"extend":8,"node-extend":8,"unherit":12,"vfile":13,"ware":14}],2:[function(require,module,exports){ /** * @author Titus Wormer * @copyright 2015 Titus Wormer @@ -2983,6 +2983,55 @@ try { SEPARATOR = require('pa' + 'th').sep; } catch (e) { /* empty */ } +/** + * Construct a new file message. + * + * Note: We cannot invoke `Error` on the created context, + * as that adds readonly `line` and `column` attributes on + * Safari 9, thus throwing and failing the data. + * + * @example + * var message = new VFileMessage('Whoops!'); + * + * message instanceof Error // true + * + * @constructor + * @class {VFileMessage} + * @param {string} reason - Reason for messaging. + * @property {boolean} [fatal=null] - Whether the message + * is fatal. + * @property {string} [name=''] - File-name and positional + * information. + * @property {string} [file=''] - File-path. + * @property {string} [reason=''] - Reason for messaging. + * @property {number} [line=null] - Start of message. + * @property {number} [column=null] - Start of message. + * @property {Position|Location} [location=null] - Place of + * message. + * @property {string} [stack] - Stack-trace of warning. + */ +function VFileMessage(reason) { + this.message = reason; +} + +/** + * Inherit from `Error#`. + */ +function VFileMessagePrototype() {} + +VFileMessagePrototype.prototype = Error.prototype; + +var proto = new VFileMessagePrototype(); + +VFileMessage.prototype = proto; + +/* + * Expose defaults. + */ + +proto.file = proto.name = proto.reason = proto.message = proto.stack = ''; +proto.fatal = proto.column = proto.line = null; + /** * File-related message with location information. * @@ -3310,7 +3359,7 @@ function message(reason, position) { } } - err = new Error(reason.message || reason); + err = new VFileMessage(reason.message || reason); err.name = (filePath ? filePath + ':' : '') + range; err.file = filePath; diff --git a/unified.min.js b/unified.min.js index 50be2a0f..b209a565 100644 --- a/unified.min.js +++ b/unified.min.js @@ -1 +1 @@ -!function(b,a){typeof exports==='object'&&typeof module!=='undefined'?module.exports=b():typeof define==='function'&&define.amd?define([],b):(typeof window!=='undefined'?a=window:typeof global!=='undefined'?a=global:typeof self!=='undefined'?a=self:a=this,a.AttachWare=b())}(function(){return function a(b,c,e){function f(d,k){if(!c[d]){if(!b[d]){var i=typeof require=='function'&&require;if(!k&&i)return i(d,!0);if(g)return g(d,!0);var j=new Error("Cannot find module '"+d+"'");throw j.code='MODULE_NOT_FOUND',j}var h=c[d]={exports:{}};b[d][0].call(h.exports,function(c){var a=b[d][1][c];return f(a?a:c)},h,h.exports,a,b,c,e)}return c[d].exports}var g=typeof require=='function'&&require;for(var d=0;d0)throw new Error('Invalid string. Length must be a multiple of 4');var i=b.length;g='='===b.charAt(i-2)?2:'='===b.charAt(i-1)?1:0,h=new f(b.length*3/4-g),j=g>0?b.length-4:b.length;var l=0;for(c=0,k=0;c>16),e((d&65280)>>8),e(d&255);return g===2?(d=a(b.charAt(c))<<2|a(b.charAt(c+1))>>4,e(d&255)):g===1&&(d=a(b.charAt(c))<<10|a(b.charAt(c+1))<<4|a(b.charAt(c+2))>>2,e(d>>8&255),e(d&255)),h}function l(a){function d(a){return b.charAt(a)}function i(a){return d(a>>18&63)+d(a>>12&63)+d(a>>6&63)+d(a&63)}var f,g=a.length%3,c='',e,h;for(f=0,h=a.length-g;f>2);c+=d(e<<4&63);c+='==';break;case 2:e=(a[a.length-2]<<8)+a[a.length-1];c+=d(e>>10);c+=d(e>>4&63);c+=d(e<<2&63);c+='=';break}return c}f=typeof Uint8Array!=='undefined'?Uint8Array:Array,g='+'.charCodeAt(0),h='/'.charCodeAt(0),c='0'.charCodeAt(0),d='a'.charCodeAt(0),e='A'.charCodeAt(0),j='-'.charCodeAt(0),k='_'.charCodeAt(0),i.toByteArray=m,i.fromByteArray=l}(a===void 0?this.base64js={}:a)},{}],5:[function(b,c,a){(function(w){function L(){function b(){}try{var a=new Uint8Array(1);return a.foo=function(){return 42},a.constructor=b,a.foo()===42&&a.constructor===b&&typeof a.subarray==='function'&&a.subarray(1,1).byteLength===0}catch(a){return!1}}function y(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function c(a){return this instanceof c?(this.length=0,this.parent=undefined,typeof a==='number'?M(this,a):typeof a==='string'?N(this,a,arguments.length>1?arguments[1]:'utf8'):O(this,a)):arguments.length>1?new c(a,arguments[1]):new c(a)}function M(a,d){if(a=g(a,d<0?0:i(d)|0),!c.TYPED_ARRAY_SUPPORT)for(var b=0;b>>1;return d&&(a.parent=A),a}function i(a){if(a>=y())throw new RangeError('Attempt to allocate Buffer larger than maximum size: 0x'+y().toString(16)+' bytes');return a|0}function p(b,d){if(!(this instanceof p))return new p(b,d);var a=new c(b,d);return delete a.parent,a}function x(a,c){typeof a!=='string'&&(a=''+a);var b=a.length;if(b===0)return 0;var d=!1;for(;;)switch(c){case'ascii':case'binary':case'raw':case'raws':return b;case'utf8':case'utf-8':return l(a).length;case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return b*2;case'hex':return b>>>1;case'base64':return v(a).length;default:if(d)return l(a).length;c=(''+c).toLowerCase();d=!0}}function S(c,b,a){var d=!1;if(b|=0,a=a===undefined||a===Infinity?this.length:a|0,c||(c='utf8'),b<0&&(b=0),a>this.length&&(a=this.length),a<=b)return'';while(!0)switch(c){case'hex':return G(this,b,a);case'utf8':case'utf-8':return u(this,b,a);case'ascii':return E(this,b,a);case'binary':return F(this,b,a);case'base64':return $(this,b,a);case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return H(this,b,a);default:if(d)throw new TypeError('Unknown encoding: '+c);c=(c+'').toLowerCase();d=!0}}function V(g,h,c,a){c=Number(c)||0;var d=g.length-c;a?(a=Number(a),a>d&&(a=d)):a=d;var e=h.length;if(e%2!==0)throw new Error('Invalid hex string');a>e/2&&(a=e/2);for(var b=0;b239?4:d>223?3:d>191?2:1;if(c+h<=j){var e,g,k,b;switch(h){case 1:d<128&&(a=d);break;case 2:e=f[c+1];(e&192)===128&&(b=(d&31)<<6|e&63,b>127&&(a=b));break;case 3:e=f[c+1];g=f[c+2];(e&192)===128&&(g&192)===128&&(b=(d&15)<<12|(e&63)<<6|g&63,b>2047&&(b<55296||b>57343)&&(a=b));break;case 4:e=f[c+1];g=f[c+2];k=f[c+3];(e&192)===128&&(g&192)===128&&(k&192)===128&&(b=(d&15)<<18|(e&63)<<12|(g&63)<<6|k&63,b>65535&&b<1114112&&(a=b))}}a===null?(a=65533,h=1):a>65535&&(a-=65536,i.push(a>>>10&1023|55296),a=56320|a&1023),i.push(a),c+=h}return D(i)}function D(b){var c=b.length;if(c<=q)return String.fromCharCode.apply(String,b);var d='',a=0;while(ad)&&(a=d);var e='';for(var c=b;cc)throw new RangeError('Trying to access beyond buffer length')}function f(a,b,d,e,f,g){if(!c.isBuffer(a))throw new TypeError('buffer must be a Buffer instance');if(b>f||ba.length)throw new RangeError('index out of range')}function o(c,b,d,e){b<0&&(b=65535+b+1);for(var a=0,f=Math.min(c.length-d,2);a>>(e?a:1-a)*8}function m(c,b,d,f){b<0&&(b=4294967295+b+1);for(var a=0,e=Math.min(c.length-d,4);a>>(f?a:3-a)*8&255}function B(c,a,b,d,e,f){if(a>e||ac.length)throw new RangeError('index out of range');if(b<0)throw new RangeError('index out of range')}function s(b,c,a,d,e){return e||B(b,c,a,4,3.4028234663852886e38,-3.4028234663852886e38),h.write(b,c,a,d,23,4),a+4}function t(b,c,a,d,e){return e||B(b,c,a,8,1.7976931348623157e308,-1.7976931348623157e308),h.write(b,c,a,d,52,8),a+8}function P(a){if(a=Q(a).replace(C,''),a.length<2)return'';while(a.length%4!==0)a+='=';return a}function Q(a){return a.trim?a.trim():a.replace(/^\s+|\s+$/g,'')}function R(a){return a<16?'0'+a.toString(16):a.toString(16)}function l(g,b){b=b||Infinity;var a,f=g.length,d=null,c=[];for(var e=0;e55295&&a<57344){if(!d){if(a>56319){(b-=3)>-1&&c.push(239,191,189);continue}if(e+1===f){(b-=3)>-1&&c.push(239,191,189);continue}d=a;continue}if(a<56320){(b-=3)>-1&&c.push(239,191,189),d=a;continue}a=d-55296<<10|a-56320|65536}else d&&(b-=3)>-1&&c.push(239,191,189);if(d=null,a<128){if((b-=1)<0)break;c.push(a)}else if(a<2048){if((b-=2)<0)break;c.push(a>>6|192,a&63|128)}else if(a<65536){if((b-=3)<0)break;c.push(a>>12|224,a>>6&63|128,a&63|128)}else if(a<1114112){if((b-=4)<0)break;c.push(a>>18|240,a>>12&63|128,a>>6&63|128,a&63|128)}else throw new Error('Invalid code point')}return c}function T(c){var b=[];for(var a=0;a>8,f=c%256,a.push(f),a.push(e)}return a}function v(a){return j.toByteArray(P(a))}function k(b,c,d,e){for(var a=0;a=c.length||a>=b.length)break;c[a+d]=b[a]}return a}var j=b('base64-js'),h=b('ieee754'),n=b('is-array');a.Buffer=c,a.SlowBuffer=p,a.INSPECT_MAX_BYTES=50,c.poolSize=8192;var A={};c.TYPED_ARRAY_SUPPORT=w.TYPED_ARRAY_SUPPORT!==undefined?w.TYPED_ARRAY_SUPPORT:L(),c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array),c.isBuffer=function a(b){return!!(b!=null&&b._isBuffer)},c.compare=function a(d,e){if(!(c.isBuffer(d)&&c.isBuffer(e)))throw new TypeError('Arguments must be Buffers');if(d===e)return 0;var f=d.length,g=e.length,b=0,h=Math.min(f,g);while(b0&&(c=this.toString('hex',0,d).match(/.{2}/g).join(' '),this.length>d&&(c+=' ... ')),''},c.prototype.compare=function a(b){if(!c.isBuffer(b))throw new TypeError('Argument must be a Buffer');return this===b?0:c.compare(this,b)},c.prototype.indexOf=function a(d,b){function e(d,e,c){var a=-1;for(var b=0;c+b2147483647?b=2147483647:b<-2147483648&&(b=-2147483648),b>>=0,this.length===0)return-1;if(b>=this.length)return-1;if(b<0&&(b=Math.max(this.length+b,0)),typeof d==='string')return d.length===0?-1:String.prototype.indexOf.call(this,d,b);if(c.isBuffer(d))return e(this,d,b);if(typeof d==='number')return c.TYPED_ARRAY_SUPPORT&&Uint8Array.prototype.indexOf==='function'?Uint8Array.prototype.indexOf.call(this,d,b):e(this,[d],b);throw new TypeError('val must be string, number or Buffer')},c.prototype.get=function a(b){return console.log('.get() is deprecated. Access using array indexes instead.'),this.readUInt8(b)},c.prototype.set=function a(b,c){return console.log('.set() is deprecated. Access using array indexes instead.'),this.writeUInt8(b,c)},c.prototype.write=function a(e,c,b,d){if(c===undefined)d='utf8',b=this.length,c=0;else if(b===undefined&&typeof c==='string')d=c,b=this.length,c=0;else if(isFinite(c))c|=0,isFinite(b)?(b|=0,d===undefined&&(d='utf8')):(d=b,b=undefined);else{var h=d;d=c,c=b|0,b=h}var f=this.length-c;if((b===undefined||b>f)&&(b=f),e.length>0&&(b<0||c<0)||c>this.length)throw new RangeError('attempt to write outside buffer bounds');d||(d='utf8');var g=!1;for(;;)switch(d){case'hex':return V(this,e,c,b);case'utf8':case'utf-8':return W(this,e,c,b);case'ascii':return r(this,e,c,b);case'binary':return Y(this,e,c,b);case'base64':return Z(this,e,c,b);case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return _(this,e,c,b);default:if(g)throw new TypeError('Unknown encoding: '+d);d=(''+d).toLowerCase();g=!0}},c.prototype.toJSON=function a(){return{type:'Buffer',data:Array.prototype.slice.call(this._arr||this,0)}};var q=4096;c.prototype.slice=function a(b,d){var e=this.length;b=~~b,d=d===undefined?e:~~d,b<0?(b+=e,b<0&&(b=0)):b>e&&(b=e),d<0?(d+=e,d<0&&(d=0)):d>e&&(d=e),d0&&(f*=256))d+=this[c+--b]*f;return d},c.prototype.readUInt8=function a(b,c){return c||e(b,1,this.length),this[b]},c.prototype.readUInt16LE=function a(b,c){return c||e(b,2,this.length),this[b]|this[b+1]<<8},c.prototype.readUInt16BE=function a(b,c){return c||e(b,2,this.length),this[b]<<8|this[b+1]},c.prototype.readUInt32LE=function a(b,c){return c||e(b,4,this.length),(this[b]|this[b+1]<<8|this[b+2]<<16)+this[b+3]*16777216},c.prototype.readUInt32BE=function a(b,c){return c||e(b,4,this.length),this[b]*16777216+(this[b+1]<<16|this[b+2]<<8|this[b+3])},c.prototype.readIntLE=function a(d,f,h){d|=0,f|=0,h||e(d,f,this.length);var b=this[d],c=1,g=0;while(++g=c&&(b-=Math.pow(2,8*f)),b},c.prototype.readIntBE=function a(d,f,h){d|=0,f|=0,h||e(d,f,this.length);var g=f,b=1,c=this[d+--g];while(g>0&&(b*=256))c+=this[d+--g]*b;return b*=128,c>=b&&(c-=Math.pow(2,8*f)),c},c.prototype.readInt8=function a(b,c){return c||e(b,1,this.length),this[b]&128?(255-this[b]+1)*-1:this[b]},c.prototype.readInt16LE=function a(c,d){d||e(c,2,this.length);var b=this[c]|this[c+1]<<8;return b&32768?b|4294901760:b},c.prototype.readInt16BE=function a(c,d){d||e(c,2,this.length);var b=this[c+1]|this[c]<<8;return b&32768?b|4294901760:b},c.prototype.readInt32LE=function a(b,c){return c||e(b,4,this.length),this[b]|this[b+1]<<8|this[b+2]<<16|this[b+3]<<24},c.prototype.readInt32BE=function a(b,c){return c||e(b,4,this.length),this[b]<<24|this[b+1]<<16|this[b+2]<<8|this[b+3]},c.prototype.readFloatLE=function a(b,c){return c||e(b,4,this.length),h.read(this,b,!0,23,4)},c.prototype.readFloatBE=function a(b,c){return c||e(b,4,this.length),h.read(this,b,!1,23,4)},c.prototype.readDoubleLE=function a(b,c){return c||e(b,8,this.length),h.read(this,b,!0,52,8)},c.prototype.readDoubleBE=function a(b,c){return c||e(b,8,this.length),h.read(this,b,!1,52,8)},c.prototype.writeUIntLE=function a(b,c,d,h){b=+b,c|=0,d|=0,h||f(this,b,c,d,Math.pow(2,8*d),0);var e=1,g=0;this[c]=b&255;while(++g=0&&(g*=256))this[c+e]=b/g&255;return c+d},c.prototype.writeUInt8=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,1,255,0),c.TYPED_ARRAY_SUPPORT||(b=Math.floor(b)),this[d]=b&255,d+1},c.prototype.writeUInt16LE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[d]=b&255,this[d+1]=b>>>8):o(this,b,d,!0),d+2},c.prototype.writeUInt16BE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[d]=b>>>8,this[d+1]=b&255):o(this,b,d,!1),d+2},c.prototype.writeUInt32LE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[d+3]=b>>>24,this[d+2]=b>>>16,this[d+1]=b>>>8,this[d]=b&255):m(this,b,d,!0),d+4},c.prototype.writeUInt32BE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[d]=b>>>24,this[d+1]=b>>>16,this[d+2]=b>>>8,this[d+3]=b&255):m(this,b,d,!1),d+4},c.prototype.writeIntLE=function a(b,c,d,j){if(b=+b,c|=0,!j){var e=Math.pow(2,8*d-1);f(this,b,c,d,e-1,-e)}var g=0,h=1,i=b<0?1:0;this[c]=b&255;while(++g>0)-i&255;return c+d},c.prototype.writeIntBE=function a(b,c,d,j){if(b=+b,c|=0,!j){var g=Math.pow(2,8*d-1);f(this,b,c,d,g-1,-g)}var e=d-1,h=1,i=b<0?1:0;this[c+e]=b&255;while(--e>=0&&(h*=256))this[c+e]=(b/h>>0)-i&255;return c+d},c.prototype.writeInt8=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,1,127,-128),c.TYPED_ARRAY_SUPPORT||(b=Math.floor(b)),b<0&&(b=255+b+1),this[d]=b&255,d+1},c.prototype.writeInt16LE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[d]=b&255,this[d+1]=b>>>8):o(this,b,d,!0),d+2},c.prototype.writeInt16BE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[d]=b>>>8,this[d+1]=b&255):o(this,b,d,!1),d+2},c.prototype.writeInt32LE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[d]=b&255,this[d+1]=b>>>8,this[d+2]=b>>>16,this[d+3]=b>>>24):m(this,b,d,!0),d+4},c.prototype.writeInt32BE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,4,2147483647,-2147483648),b<0&&(b=4294967295+b+1),c.TYPED_ARRAY_SUPPORT?(this[d]=b>>>24,this[d+1]=b>>>16,this[d+2]=b>>>8,this[d+3]=b&255):m(this,b,d,!1),d+4},c.prototype.writeFloatLE=function a(b,c,d){return s(this,b,c,!0,d)},c.prototype.writeFloatBE=function a(b,c,d){return s(this,b,c,!1,d)},c.prototype.writeDoubleLE=function a(b,c,d){return t(this,b,c,!0,d)},c.prototype.writeDoubleBE=function a(b,c,d){return t(this,b,c,!1,d)},c.prototype.copy=function a(g,e,b,d){if(b||(b=0),!d&&d!==0&&(d=this.length),e>=g.length&&(e=g.length),e||(e=0),d>0&&d=this.length)throw new RangeError('sourceStart out of bounds');if(d<0)throw new RangeError('sourceEnd out of bounds');d>this.length&&(d=this.length),g.length-e=0;f--)g[f+e]=this[f+b];else if(h<1e3||!c.TYPED_ARRAY_SUPPORT)for(f=0;f=this.length)throw new RangeError('start out of bounds');if(d<0||d>this.length)throw new RangeError('end out of bounds');var b;if(typeof e==='number')for(b=c;b2&&(g=a.call(arguments,1)),f)try{b=j.throw(f)}catch(a){return k(a)}if(!f)try{b=j.next(g)}catch(a){return k(a)}if(b.done)return k(null,b.value);if(b.value=d(b.value,e),'function'==typeof b.value){var c=!1;try{b.value.call(e,function(){if(c)return;c=!0,i.apply(e,arguments)})}catch(a){setImmediate(function(){if(c)return;c=!0,i(a)})}return}i(new TypeError('You may only yield a function, promise, generator, array, or object, but the following was passed: "'+String(b.value)+'"'))}var e=this,j=b;if(f){var g=a.call(arguments),l=g.length,m=l&&'function'==typeof g[l-1];h=m?g.pop():c,j=b.apply(this,g)}else h=h||c;i()}}function d(a,c){return e(a)?b(a.call(c)):j(a)?b(a):i(a)?f(a):'function'==typeof a?a:h(a)||Array.isArray(a)?g.call(c,a):a}function g(a){var b=this,c=Array.isArray(a);return function(i){function k(a,c){if(j)return;try{if(a=d(a,b),'function'!=typeof a)return f[c]=a,--h||i(null,f);a.call(b,function(a,b){if(j)return;if(a)return j=!0,i(a);f[c]=b,--h||i(null,f)})}catch(a){j=!0,i(a)}}var g=Object.keys(a),h=g.length,f=c?new Array(h):new a.constructor,j;if(!h){setImmediate(function(){i(null,f)});return}if(!c)for(var e=0;e>1,a=-7,c=n?m-1:0,g=n?-1:1,e=h[l+c];for(c+=g,b=e&(1<<-a)-1,e>>=-a,a+=i;a>0;b=b*256+h[l+c],c+=g,a-=8);for(d=b&(1<<-a)-1,b>>=-a,a+=f;a>0;d=d*256+h[l+c],c+=g,a-=8);if(b===0)b=1-k;else if(b===j)return d?NaN:(e?-1:1)*Infinity;else d+=Math.pow(2,f),b-=k;return(e?-1:1)*d*Math.pow(2,b-f)},a.write=function(k,b,m,n,c,p){var a,d,f,h=p*8-c-1,i=(1<>1,l=c===23?Math.pow(2,-24)-Math.pow(2,-77):0,g=n?0:p-1,j=n?1:-1,o=b<0||b===0&&1/b<0?1:0;for(b=Math.abs(b),isNaN(b)||b===Infinity?(d=isNaN(b)?1:0,a=i):(a=Math.floor(Math.log(b)/Math.LN2),b*(f=Math.pow(2,-a))<1&&(a--,f*=2),a+e>=1?b+=l/f:b+=l*Math.pow(2,1-e),b*f>=2&&(a++,f/=2),a+e>=i?(d=0,a=i):a+e>=1?(d=(b*f-1)*Math.pow(2,c),a+=e):(d=b*Math.pow(2,e-1)*Math.pow(2,c),a=0));c>=8;k[m+g]=d&255,g+=j,d/=256,c-=8);for(a=a<0;k[m+g]=a&255,g+=j,a/=256,h-=8);k[m+g-j]|=o*128}},{}],10:[function(b,a,c){typeof Object.create==='function'?a.exports=function a(b,c){b.super_=c,b.prototype=Object.create(c.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}})}:a.exports=function a(b,d){b.super_=d;var c=function(){};c.prototype=d.prototype,b.prototype=new c,b.prototype.constructor=b}},{}],11:[function(d,c,e){var a=Array.isArray,b=Object.prototype.toString;c.exports=a||function(a){return!!a&&'[object Array]'==b.call(a)}},{}],12:[function(b,d,f){'use strict';function e(d){function g(a){return d.apply(this,a)}function b(){return this instanceof b?d.apply(this,arguments):new g(arguments)}var e=c(d.prototype),h,f;a(b,d),a(g,b),h=b.prototype;for(f in e)h[f]=e[f];return b}var c=b('clone'),a=b('inherits');d.exports=e},{clone:6,inherits:10}],13:[function(i,e,o){'use strict';function d(a){return a||(a={}),(a.line||1)+':'+(a.column||1)}function f(a){function b(){var b=a.directory,d;return a.filename||a.extension?(d=b.charAt(b.length-1),(d==='/'||d==='\\')&&(b=b.slice(0,-1)),b==='.'&&(b=''),(b?b+c:'')+a.filename+(a.extension?'.'+a.extension:'')):''}return b.toString=b,b}function b(a){var c=this;if(!(c instanceof b))return new b(a);if(a&&typeof a.message==='function'&&typeof a.hasFailed==='function')return a;a?typeof a==='string'&&(a={contents:a}):a={},c.contents=a.contents||'',c.messages=[],c.filePath=f(c),c.history=[],c.move({filename:a.filename,directory:a.directory,extension:a.extension})}function h(){return this.contents}function g(b){var a=this,d=a.filePath(),c;return b||(b={}),a.directory=b.directory||a.directory||'',a.filename=b.filename||a.filename||'',a.extension=b.extension||a.extension||'',c=a.filePath(),c&&d!==c&&a.history.push(c),a}function j(c,a){var f=this.filePath(),g,b,e={start:{line:null,column:null},end:{line:null,column:null}};return a&&a.position&&(a=a.position),a&&a.start?(g=d(a.start)+'-'+d(a.end),e=a,a=a.start):(g=d(a),a&&(e.start=a,e.end.line=null,e.end.column=null)),b=new Error(c.message||c),b.name=(f?f+':':'')+g,b.file=f,b.reason=c.message||c,b.line=a?a.line:null,b.column=a?a.column:null,b.location=e,c.stack&&(b.stack=c.stack),b}function k(){var a=this.message.apply(this,arguments);return a.fatal=!1,this.messages.push(a),a}function l(b,c){var a=this.message(b,c);if(a.fatal=!0,this.messages.push(a),!this.quiet)throw a;return a}function m(){var a=this.messages,b=-1,c=a.length;while(++ba.length)try{return e.apply(h,a.concat(c))}catch(a){return c(a)}return g(e)?b(e).apply(h,a.concat(c)):d(e,c).apply(h,a)}}function d(b,a){return function(){var c;try{c=b.apply(this,arguments)}catch(b){return a(b)}h(c)?c.then(function(b){a(null,b)},a):c instanceof Error?a(c):a(null,c)}}function g(a){return a&&a.constructor&&'GeneratorFunction'==a.constructor.name}function h(a){return a&&'function'==typeof a.then}function i(b){return function(){var c=b.apply(this,arguments);return b=a,c}}var a=function(){},b=f('co');c.exports=e},{co:7}]},{},[1])(1)}) +!function(b,a){typeof exports==='object'&&typeof module!=='undefined'?module.exports=b():typeof define==='function'&&define.amd?define([],b):(typeof window!=='undefined'?a=window:typeof global!=='undefined'?a=global:typeof self!=='undefined'?a=self:a=this,a.AttachWare=b())}(function(){return function a(b,c,e){function f(d,k){if(!c[d]){if(!b[d]){var i=typeof require=='function'&&require;if(!k&&i)return i(d,!0);if(g)return g(d,!0);var j=new Error("Cannot find module '"+d+"'");throw j.code='MODULE_NOT_FOUND',j}var h=c[d]={exports:{}};b[d][0].call(h.exports,function(c){var a=b[d][1][c];return f(a?a:c)},h,h.exports,a,b,c,e)}return c[d].exports}var g=typeof require=='function'&&require;for(var d=0;d0)throw new Error('Invalid string. Length must be a multiple of 4');var i=b.length;g='='===b.charAt(i-2)?2:'='===b.charAt(i-1)?1:0,h=new f(b.length*3/4-g),j=g>0?b.length-4:b.length;var l=0;for(c=0,k=0;c>16),e((d&65280)>>8),e(d&255);return g===2?(d=a(b.charAt(c))<<2|a(b.charAt(c+1))>>4,e(d&255)):g===1&&(d=a(b.charAt(c))<<10|a(b.charAt(c+1))<<4|a(b.charAt(c+2))>>2,e(d>>8&255),e(d&255)),h}function l(a){function d(a){return b.charAt(a)}function i(a){return d(a>>18&63)+d(a>>12&63)+d(a>>6&63)+d(a&63)}var f,g=a.length%3,c='',e,h;for(f=0,h=a.length-g;f>2);c+=d(e<<4&63);c+='==';break;case 2:e=(a[a.length-2]<<8)+a[a.length-1];c+=d(e>>10);c+=d(e>>4&63);c+=d(e<<2&63);c+='=';break}return c}f=typeof Uint8Array!=='undefined'?Uint8Array:Array,g='+'.charCodeAt(0),h='/'.charCodeAt(0),c='0'.charCodeAt(0),d='a'.charCodeAt(0),e='A'.charCodeAt(0),j='-'.charCodeAt(0),k='_'.charCodeAt(0),i.toByteArray=m,i.fromByteArray=l}(a===void 0?this.base64js={}:a)},{}],5:[function(b,c,a){(function(w){function L(){function b(){}try{var a=new Uint8Array(1);return a.foo=function(){return 42},a.constructor=b,a.foo()===42&&a.constructor===b&&typeof a.subarray==='function'&&a.subarray(1,1).byteLength===0}catch(a){return!1}}function y(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function c(a){return this instanceof c?(this.length=0,this.parent=undefined,typeof a==='number'?M(this,a):typeof a==='string'?N(this,a,arguments.length>1?arguments[1]:'utf8'):O(this,a)):arguments.length>1?new c(a,arguments[1]):new c(a)}function M(a,d){if(a=g(a,d<0?0:i(d)|0),!c.TYPED_ARRAY_SUPPORT)for(var b=0;b>>1;return d&&(a.parent=A),a}function i(a){if(a>=y())throw new RangeError('Attempt to allocate Buffer larger than maximum size: 0x'+y().toString(16)+' bytes');return a|0}function p(b,d){if(!(this instanceof p))return new p(b,d);var a=new c(b,d);return delete a.parent,a}function x(a,c){typeof a!=='string'&&(a=''+a);var b=a.length;if(b===0)return 0;var d=!1;for(;;)switch(c){case'ascii':case'binary':case'raw':case'raws':return b;case'utf8':case'utf-8':return l(a).length;case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return b*2;case'hex':return b>>>1;case'base64':return v(a).length;default:if(d)return l(a).length;c=(''+c).toLowerCase();d=!0}}function S(c,b,a){var d=!1;if(b|=0,a=a===undefined||a===Infinity?this.length:a|0,c||(c='utf8'),b<0&&(b=0),a>this.length&&(a=this.length),a<=b)return'';while(!0)switch(c){case'hex':return G(this,b,a);case'utf8':case'utf-8':return u(this,b,a);case'ascii':return E(this,b,a);case'binary':return F(this,b,a);case'base64':return $(this,b,a);case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return H(this,b,a);default:if(d)throw new TypeError('Unknown encoding: '+c);c=(c+'').toLowerCase();d=!0}}function V(g,h,c,a){c=Number(c)||0;var d=g.length-c;a?(a=Number(a),a>d&&(a=d)):a=d;var e=h.length;if(e%2!==0)throw new Error('Invalid hex string');a>e/2&&(a=e/2);for(var b=0;b239?4:d>223?3:d>191?2:1;if(c+h<=j){var e,g,k,b;switch(h){case 1:d<128&&(a=d);break;case 2:e=f[c+1];(e&192)===128&&(b=(d&31)<<6|e&63,b>127&&(a=b));break;case 3:e=f[c+1];g=f[c+2];(e&192)===128&&(g&192)===128&&(b=(d&15)<<12|(e&63)<<6|g&63,b>2047&&(b<55296||b>57343)&&(a=b));break;case 4:e=f[c+1];g=f[c+2];k=f[c+3];(e&192)===128&&(g&192)===128&&(k&192)===128&&(b=(d&15)<<18|(e&63)<<12|(g&63)<<6|k&63,b>65535&&b<1114112&&(a=b))}}a===null?(a=65533,h=1):a>65535&&(a-=65536,i.push(a>>>10&1023|55296),a=56320|a&1023),i.push(a),c+=h}return D(i)}function D(b){var c=b.length;if(c<=q)return String.fromCharCode.apply(String,b);var d='',a=0;while(ad)&&(a=d);var e='';for(var c=b;cc)throw new RangeError('Trying to access beyond buffer length')}function f(a,b,d,e,f,g){if(!c.isBuffer(a))throw new TypeError('buffer must be a Buffer instance');if(b>f||ba.length)throw new RangeError('index out of range')}function o(c,b,d,e){b<0&&(b=65535+b+1);for(var a=0,f=Math.min(c.length-d,2);a>>(e?a:1-a)*8}function m(c,b,d,f){b<0&&(b=4294967295+b+1);for(var a=0,e=Math.min(c.length-d,4);a>>(f?a:3-a)*8&255}function B(c,a,b,d,e,f){if(a>e||ac.length)throw new RangeError('index out of range');if(b<0)throw new RangeError('index out of range')}function s(b,c,a,d,e){return e||B(b,c,a,4,3.4028234663852886e38,-3.4028234663852886e38),h.write(b,c,a,d,23,4),a+4}function t(b,c,a,d,e){return e||B(b,c,a,8,1.7976931348623157e308,-1.7976931348623157e308),h.write(b,c,a,d,52,8),a+8}function P(a){if(a=Q(a).replace(C,''),a.length<2)return'';while(a.length%4!==0)a+='=';return a}function Q(a){return a.trim?a.trim():a.replace(/^\s+|\s+$/g,'')}function R(a){return a<16?'0'+a.toString(16):a.toString(16)}function l(g,b){b=b||Infinity;var a,f=g.length,d=null,c=[];for(var e=0;e55295&&a<57344){if(!d){if(a>56319){(b-=3)>-1&&c.push(239,191,189);continue}if(e+1===f){(b-=3)>-1&&c.push(239,191,189);continue}d=a;continue}if(a<56320){(b-=3)>-1&&c.push(239,191,189),d=a;continue}a=d-55296<<10|a-56320|65536}else d&&(b-=3)>-1&&c.push(239,191,189);if(d=null,a<128){if((b-=1)<0)break;c.push(a)}else if(a<2048){if((b-=2)<0)break;c.push(a>>6|192,a&63|128)}else if(a<65536){if((b-=3)<0)break;c.push(a>>12|224,a>>6&63|128,a&63|128)}else if(a<1114112){if((b-=4)<0)break;c.push(a>>18|240,a>>12&63|128,a>>6&63|128,a&63|128)}else throw new Error('Invalid code point')}return c}function T(c){var b=[];for(var a=0;a>8,f=c%256,a.push(f),a.push(e)}return a}function v(a){return j.toByteArray(P(a))}function k(b,c,d,e){for(var a=0;a=c.length||a>=b.length)break;c[a+d]=b[a]}return a}var j=b('base64-js'),h=b('ieee754'),n=b('is-array');a.Buffer=c,a.SlowBuffer=p,a.INSPECT_MAX_BYTES=50,c.poolSize=8192;var A={};c.TYPED_ARRAY_SUPPORT=w.TYPED_ARRAY_SUPPORT!==undefined?w.TYPED_ARRAY_SUPPORT:L(),c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array),c.isBuffer=function a(b){return!!(b!=null&&b._isBuffer)},c.compare=function a(d,e){if(!(c.isBuffer(d)&&c.isBuffer(e)))throw new TypeError('Arguments must be Buffers');if(d===e)return 0;var f=d.length,g=e.length,b=0,h=Math.min(f,g);while(b0&&(c=this.toString('hex',0,d).match(/.{2}/g).join(' '),this.length>d&&(c+=' ... ')),''},c.prototype.compare=function a(b){if(!c.isBuffer(b))throw new TypeError('Argument must be a Buffer');return this===b?0:c.compare(this,b)},c.prototype.indexOf=function a(d,b){function e(d,e,c){var a=-1;for(var b=0;c+b2147483647?b=2147483647:b<-2147483648&&(b=-2147483648),b>>=0,this.length===0)return-1;if(b>=this.length)return-1;if(b<0&&(b=Math.max(this.length+b,0)),typeof d==='string')return d.length===0?-1:String.prototype.indexOf.call(this,d,b);if(c.isBuffer(d))return e(this,d,b);if(typeof d==='number')return c.TYPED_ARRAY_SUPPORT&&Uint8Array.prototype.indexOf==='function'?Uint8Array.prototype.indexOf.call(this,d,b):e(this,[d],b);throw new TypeError('val must be string, number or Buffer')},c.prototype.get=function a(b){return console.log('.get() is deprecated. Access using array indexes instead.'),this.readUInt8(b)},c.prototype.set=function a(b,c){return console.log('.set() is deprecated. Access using array indexes instead.'),this.writeUInt8(b,c)},c.prototype.write=function a(e,c,b,d){if(c===undefined)d='utf8',b=this.length,c=0;else if(b===undefined&&typeof c==='string')d=c,b=this.length,c=0;else if(isFinite(c))c|=0,isFinite(b)?(b|=0,d===undefined&&(d='utf8')):(d=b,b=undefined);else{var h=d;d=c,c=b|0,b=h}var f=this.length-c;if((b===undefined||b>f)&&(b=f),e.length>0&&(b<0||c<0)||c>this.length)throw new RangeError('attempt to write outside buffer bounds');d||(d='utf8');var g=!1;for(;;)switch(d){case'hex':return V(this,e,c,b);case'utf8':case'utf-8':return W(this,e,c,b);case'ascii':return r(this,e,c,b);case'binary':return Y(this,e,c,b);case'base64':return Z(this,e,c,b);case'ucs2':case'ucs-2':case'utf16le':case'utf-16le':return _(this,e,c,b);default:if(g)throw new TypeError('Unknown encoding: '+d);d=(''+d).toLowerCase();g=!0}},c.prototype.toJSON=function a(){return{type:'Buffer',data:Array.prototype.slice.call(this._arr||this,0)}};var q=4096;c.prototype.slice=function a(b,d){var e=this.length;b=~~b,d=d===undefined?e:~~d,b<0?(b+=e,b<0&&(b=0)):b>e&&(b=e),d<0?(d+=e,d<0&&(d=0)):d>e&&(d=e),d0&&(f*=256))d+=this[c+--b]*f;return d},c.prototype.readUInt8=function a(b,c){return c||e(b,1,this.length),this[b]},c.prototype.readUInt16LE=function a(b,c){return c||e(b,2,this.length),this[b]|this[b+1]<<8},c.prototype.readUInt16BE=function a(b,c){return c||e(b,2,this.length),this[b]<<8|this[b+1]},c.prototype.readUInt32LE=function a(b,c){return c||e(b,4,this.length),(this[b]|this[b+1]<<8|this[b+2]<<16)+this[b+3]*16777216},c.prototype.readUInt32BE=function a(b,c){return c||e(b,4,this.length),this[b]*16777216+(this[b+1]<<16|this[b+2]<<8|this[b+3])},c.prototype.readIntLE=function a(d,f,h){d|=0,f|=0,h||e(d,f,this.length);var b=this[d],c=1,g=0;while(++g=c&&(b-=Math.pow(2,8*f)),b},c.prototype.readIntBE=function a(d,f,h){d|=0,f|=0,h||e(d,f,this.length);var g=f,b=1,c=this[d+--g];while(g>0&&(b*=256))c+=this[d+--g]*b;return b*=128,c>=b&&(c-=Math.pow(2,8*f)),c},c.prototype.readInt8=function a(b,c){return c||e(b,1,this.length),this[b]&128?(255-this[b]+1)*-1:this[b]},c.prototype.readInt16LE=function a(c,d){d||e(c,2,this.length);var b=this[c]|this[c+1]<<8;return b&32768?b|4294901760:b},c.prototype.readInt16BE=function a(c,d){d||e(c,2,this.length);var b=this[c+1]|this[c]<<8;return b&32768?b|4294901760:b},c.prototype.readInt32LE=function a(b,c){return c||e(b,4,this.length),this[b]|this[b+1]<<8|this[b+2]<<16|this[b+3]<<24},c.prototype.readInt32BE=function a(b,c){return c||e(b,4,this.length),this[b]<<24|this[b+1]<<16|this[b+2]<<8|this[b+3]},c.prototype.readFloatLE=function a(b,c){return c||e(b,4,this.length),h.read(this,b,!0,23,4)},c.prototype.readFloatBE=function a(b,c){return c||e(b,4,this.length),h.read(this,b,!1,23,4)},c.prototype.readDoubleLE=function a(b,c){return c||e(b,8,this.length),h.read(this,b,!0,52,8)},c.prototype.readDoubleBE=function a(b,c){return c||e(b,8,this.length),h.read(this,b,!1,52,8)},c.prototype.writeUIntLE=function a(b,c,d,h){b=+b,c|=0,d|=0,h||f(this,b,c,d,Math.pow(2,8*d),0);var e=1,g=0;this[c]=b&255;while(++g=0&&(g*=256))this[c+e]=b/g&255;return c+d},c.prototype.writeUInt8=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,1,255,0),c.TYPED_ARRAY_SUPPORT||(b=Math.floor(b)),this[d]=b&255,d+1},c.prototype.writeUInt16LE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[d]=b&255,this[d+1]=b>>>8):o(this,b,d,!0),d+2},c.prototype.writeUInt16BE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[d]=b>>>8,this[d+1]=b&255):o(this,b,d,!1),d+2},c.prototype.writeUInt32LE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[d+3]=b>>>24,this[d+2]=b>>>16,this[d+1]=b>>>8,this[d]=b&255):m(this,b,d,!0),d+4},c.prototype.writeUInt32BE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[d]=b>>>24,this[d+1]=b>>>16,this[d+2]=b>>>8,this[d+3]=b&255):m(this,b,d,!1),d+4},c.prototype.writeIntLE=function a(b,c,d,j){if(b=+b,c|=0,!j){var e=Math.pow(2,8*d-1);f(this,b,c,d,e-1,-e)}var g=0,h=1,i=b<0?1:0;this[c]=b&255;while(++g>0)-i&255;return c+d},c.prototype.writeIntBE=function a(b,c,d,j){if(b=+b,c|=0,!j){var g=Math.pow(2,8*d-1);f(this,b,c,d,g-1,-g)}var e=d-1,h=1,i=b<0?1:0;this[c+e]=b&255;while(--e>=0&&(h*=256))this[c+e]=(b/h>>0)-i&255;return c+d},c.prototype.writeInt8=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,1,127,-128),c.TYPED_ARRAY_SUPPORT||(b=Math.floor(b)),b<0&&(b=255+b+1),this[d]=b&255,d+1},c.prototype.writeInt16LE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[d]=b&255,this[d+1]=b>>>8):o(this,b,d,!0),d+2},c.prototype.writeInt16BE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[d]=b>>>8,this[d+1]=b&255):o(this,b,d,!1),d+2},c.prototype.writeInt32LE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[d]=b&255,this[d+1]=b>>>8,this[d+2]=b>>>16,this[d+3]=b>>>24):m(this,b,d,!0),d+4},c.prototype.writeInt32BE=function a(b,d,e){return b=+b,d|=0,e||f(this,b,d,4,2147483647,-2147483648),b<0&&(b=4294967295+b+1),c.TYPED_ARRAY_SUPPORT?(this[d]=b>>>24,this[d+1]=b>>>16,this[d+2]=b>>>8,this[d+3]=b&255):m(this,b,d,!1),d+4},c.prototype.writeFloatLE=function a(b,c,d){return s(this,b,c,!0,d)},c.prototype.writeFloatBE=function a(b,c,d){return s(this,b,c,!1,d)},c.prototype.writeDoubleLE=function a(b,c,d){return t(this,b,c,!0,d)},c.prototype.writeDoubleBE=function a(b,c,d){return t(this,b,c,!1,d)},c.prototype.copy=function a(g,e,b,d){if(b||(b=0),!d&&d!==0&&(d=this.length),e>=g.length&&(e=g.length),e||(e=0),d>0&&d=this.length)throw new RangeError('sourceStart out of bounds');if(d<0)throw new RangeError('sourceEnd out of bounds');d>this.length&&(d=this.length),g.length-e=0;f--)g[f+e]=this[f+b];else if(h<1e3||!c.TYPED_ARRAY_SUPPORT)for(f=0;f=this.length)throw new RangeError('start out of bounds');if(d<0||d>this.length)throw new RangeError('end out of bounds');var b;if(typeof e==='number')for(b=c;b2&&(g=a.call(arguments,1)),f)try{b=j.throw(f)}catch(a){return k(a)}if(!f)try{b=j.next(g)}catch(a){return k(a)}if(b.done)return k(null,b.value);if(b.value=d(b.value,e),'function'==typeof b.value){var c=!1;try{b.value.call(e,function(){if(c)return;c=!0,i.apply(e,arguments)})}catch(a){setImmediate(function(){if(c)return;c=!0,i(a)})}return}i(new TypeError('You may only yield a function, promise, generator, array, or object, but the following was passed: "'+String(b.value)+'"'))}var e=this,j=b;if(f){var g=a.call(arguments),l=g.length,m=l&&'function'==typeof g[l-1];h=m?g.pop():c,j=b.apply(this,g)}else h=h||c;i()}}function d(a,c){return e(a)?b(a.call(c)):j(a)?b(a):i(a)?f(a):'function'==typeof a?a:h(a)||Array.isArray(a)?g.call(c,a):a}function g(a){var b=this,c=Array.isArray(a);return function(i){function k(a,c){if(j)return;try{if(a=d(a,b),'function'!=typeof a)return f[c]=a,--h||i(null,f);a.call(b,function(a,b){if(j)return;if(a)return j=!0,i(a);f[c]=b,--h||i(null,f)})}catch(a){j=!0,i(a)}}var g=Object.keys(a),h=g.length,f=c?new Array(h):new a.constructor,j;if(!h){setImmediate(function(){i(null,f)});return}if(!c)for(var e=0;e>1,a=-7,c=n?m-1:0,g=n?-1:1,e=h[l+c];for(c+=g,b=e&(1<<-a)-1,e>>=-a,a+=i;a>0;b=b*256+h[l+c],c+=g,a-=8);for(d=b&(1<<-a)-1,b>>=-a,a+=f;a>0;d=d*256+h[l+c],c+=g,a-=8);if(b===0)b=1-k;else if(b===j)return d?NaN:(e?-1:1)*Infinity;else d+=Math.pow(2,f),b-=k;return(e?-1:1)*d*Math.pow(2,b-f)},a.write=function(k,b,m,n,c,p){var a,d,f,h=p*8-c-1,i=(1<>1,l=c===23?Math.pow(2,-24)-Math.pow(2,-77):0,g=n?0:p-1,j=n?1:-1,o=b<0||b===0&&1/b<0?1:0;for(b=Math.abs(b),isNaN(b)||b===Infinity?(d=isNaN(b)?1:0,a=i):(a=Math.floor(Math.log(b)/Math.LN2),b*(f=Math.pow(2,-a))<1&&(a--,f*=2),a+e>=1?b+=l/f:b+=l*Math.pow(2,1-e),b*f>=2&&(a++,f/=2),a+e>=i?(d=0,a=i):a+e>=1?(d=(b*f-1)*Math.pow(2,c),a+=e):(d=b*Math.pow(2,e-1)*Math.pow(2,c),a=0));c>=8;k[m+g]=d&255,g+=j,d/=256,c-=8);for(a=a<0;k[m+g]=a&255,g+=j,a/=256,h-=8);k[m+g-j]|=o*128}},{}],10:[function(b,a,c){typeof Object.create==='function'?a.exports=function a(b,c){b.super_=c,b.prototype=Object.create(c.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}})}:a.exports=function a(b,d){b.super_=d;var c=function(){};c.prototype=d.prototype,b.prototype=new c,b.prototype.constructor=b}},{}],11:[function(d,c,e){var a=Array.isArray,b=Object.prototype.toString;c.exports=a||function(a){return!!a&&'[object Array]'==b.call(a)}},{}],12:[function(b,d,f){'use strict';function e(d){function g(a){return d.apply(this,a)}function b(){return this instanceof b?d.apply(this,arguments):new g(arguments)}var e=c(d.prototype),h,f;a(b,d),a(g,b),h=b.prototype;for(f in e)h[f]=e[f];return b}var c=b('clone'),a=b('inherits');d.exports=e},{clone:6,inherits:10}],13:[function(j,q,r){'use strict';function f(a){this.message=a}function g(){}function d(a){return a||(a={}),(a.line||1)+':'+(a.column||1)}function h(a){function b(){var b=a.directory,c;return a.filename||a.extension?(c=b.charAt(b.length-1),(c==='/'||c==='\\')&&(b=b.slice(0,-1)),b==='.'&&(b=''),(b?b+e:'')+a.filename+(a.extension?'.'+a.extension:'')):''}return b.toString=b,b}function c(a){var b=this;if(!(b instanceof c))return new c(a);if(a&&typeof a.message==='function'&&typeof a.hasFailed==='function')return a;a?typeof a==='string'&&(a={contents:a}):a={},b.contents=a.contents||'',b.messages=[],b.filePath=h(b),b.history=[],b.move({filename:a.filename,directory:a.directory,extension:a.extension})}function i(){return this.contents}function k(b){var a=this,d=a.filePath(),c;return b||(b={}),a.directory=b.directory||a.directory||'',a.filename=b.filename||a.filename||'',a.extension=b.extension||a.extension||'',c=a.filePath(),c&&d!==c&&a.history.push(c),a}function l(c,a){var g=this.filePath(),h,b,e={start:{line:null,column:null},end:{line:null,column:null}};return a&&a.position&&(a=a.position),a&&a.start?(h=d(a.start)+'-'+d(a.end),e=a,a=a.start):(h=d(a),a&&(e.start=a,e.end.line=null,e.end.column=null)),b=new f(c.message||c),b.name=(g?g+':':'')+h,b.file=g,b.reason=c.message||c,b.line=a?a.line:null,b.column=a?a.column:null,b.location=e,c.stack&&(b.stack=c.stack),b}function m(){var a=this.message.apply(this,arguments);return a.fatal=!1,this.messages.push(a),a}function n(b,c){var a=this.message(b,c);if(a.fatal=!0,this.messages.push(a),!this.quiet)throw a;return a}function o(){var a=this.messages,b=-1,c=a.length;while(++ba.length)try{return e.apply(h,a.concat(c))}catch(a){return c(a)}return g(e)?b(e).apply(h,a.concat(c)):d(e,c).apply(h,a)}}function d(b,a){return function(){var c;try{c=b.apply(this,arguments)}catch(b){return a(b)}h(c)?c.then(function(b){a(null,b)},a):c instanceof Error?a(c):a(null,c)}}function g(a){return a&&a.constructor&&'GeneratorFunction'==a.constructor.name}function h(a){return a&&'function'==typeof a.then}function i(b){return function(){var c=b.apply(this,arguments);return b=a,c}}var a=function(){},b=f('co');c.exports=e},{co:7}]},{},[1])(1)})