* Can be extended to provide event functionality in other classes.
*
* @class EventEmitter Manages event registering and emitting.
*/
functionEventEmitter(){}
// Shortcuts to improve speed and size
varproto=EventEmitter.prototype;
varexports=this;
varoriginalGlobalValue=exports.EventEmitter;
/**
* Finds the index of the listener for the event in its storage array.
*
* @param {Function[]} listeners Array of listeners to search through.
* @param {Function} listener Method to look for.
* @return {Number} Index of the specified listener, -1 if not found
* @api private
*/
functionindexOfListener(listeners,listener){
vari=listeners.length;
while(i--){
if(listeners[i].listener===listener){
returni;
}
}
return-1;
}
/**
* Alias a method while keeping the context correct, to allow for overwriting of target method.
*
* @param {String} name The name of the target method.
* @return {Function} The aliased method
* @api private
*/
functionalias(name){
returnfunctionaliasClosure(){
returnthis[name].apply(this,arguments);
};
}
/**
* Returns the listener array for the specified event.
* Will initialise the event object and listener arrays if required.
* Will return an object if you use a regex search. The object contains keys for each matched event. So /ba[rz]/ might return an object containing bar and baz. But only if you have either defined them with defineEvent or added some listeners to them.
* Each property in the object response is an array of listener functions.
*
* @param {String|RegExp} evt Name of the event to return the listeners from.
* @return {Function[]|Object} All listener functions for the event.
*/
proto.getListeners=functiongetListeners(evt){
varevents=this._getEvents();
varresponse;
varkey;
// Return a concatenated array of all matching events if
// the selector is a regular expression.
if(evtinstanceofRegExp){
response={};
for(keyinevents){
if(events.hasOwnProperty(key)&&evt.test(key)){
response[key]=events[key];
}
}
}
else{
response=events[evt]||(events[evt]=[]);
}
returnresponse;
};
/**
* Takes a list of listener objects and flattens it into a list of listener functions.
*
* @param {Object[]} listeners Raw listener objects.
* @return {Function[]} Just the listener functions.
* Fetches the requested listeners via getListeners but will always return the results inside an object. This is mainly for internal use but others may find it useful.
*
* @param {String|RegExp} evt Name of the event to return the listeners from.
* @return {Object} All listener functions for an event in an object.
* Defines an event name. This is required if you want to use a regex to add a listener to multiple events at once. If you don't do this then how do you expect it to know what event to add to? Should it just add to every possible match for a regex? No. That is scary and bad.
* You need to tell it what event names should be matched by a regex.
*
* @param {String} evt Name of the event to create.
* @return {Object} Current instance of EventEmitter for chaining.
*/
proto.defineEvent=functiondefineEvent(evt){
this.getListeners(evt);
returnthis;
};
/**
* Uses defineEvent to define multiple events.
*
* @param {String[]} evts An array of event names to define.
* @return {Object} Current instance of EventEmitter for chaining.
*/
proto.defineEvents=functiondefineEvents(evts){
for(vari=0;i<evts.length;i+=1){
this.defineEvent(evts[i]);
}
returnthis;
};
/**
* Removes a listener function from the specified event.
* When passed a regular expression as the event name, it will remove the listener from all events that match it.
*
* @param {String|RegExp} evt Name of the event to remove the listener from.
* @param {Function} listener Method to remove from the event.
* @return {Object} Current instance of EventEmitter for chaining.
* Adds listeners in bulk using the manipulateListeners method.
* If you pass an object as the second argument you can add to multiple events at once. The object should contain key value pairs of events and listeners or listener arrays. You can also pass it an event name and an array of listeners to be added.
* You can also pass it a regular expression to add the array of listeners to all events that match it.
* Yeah, this function does quite a bit. That's probably a bad thing.
*
* @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add to multiple events at once.
* @param {Function[]} [listeners] An optional array of listener functions to add.
* @return {Object} Current instance of EventEmitter for chaining.
* Removes listeners in bulk using the manipulateListeners method.
* If you pass an object as the second argument you can remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.
* You can also pass it an event name and an array of listeners to be removed.
* You can also pass it a regular expression to remove the listeners from all events that match it.
*
* @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to remove from multiple events at once.
* @param {Function[]} [listeners] An optional array of listener functions to remove.
* @return {Object} Current instance of EventEmitter for chaining.
* Edits listeners in bulk. The addListeners and removeListeners methods both use this to do their job. You should really use those instead, this is a little lower level.
* The first argument will determine if the listeners are removed (true) or added (false).
* If you pass an object as the second argument you can add/remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.
* You can also pass it an event name and an array of listeners to be added/removed.
* You can also pass it a regular expression to manipulate the listeners of all events that match it.
*
* @param {Boolean} remove True if you want to remove listeners, false if you want to add.
* @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add/remove from multiple events at once.
* @param {Function[]} [listeners] An optional array of listener functions to add/remove.
* @return {Object} Current instance of EventEmitter for chaining.
* Fetches the events object and creates one if required.
*
* @return {Object} The events storage object.
* @api private
*/
proto._getEvents=function_getEvents(){
returnthis._events||(this._events={});
};
/**
* Reverts the global {@link EventEmitter} to its previous value and returns a reference to this version.
*
* @return {Function} Non conflicting EventEmitter class.
*/
EventEmitter.noConflict=functionnoConflict(){
exports.EventEmitter=originalGlobalValue;
returnEventEmitter;
};
// Expose the class either via AMD, CommonJS or the global object
if(typeofdefine==='function'&&define.amd){
define(function(){
returnEventEmitter;
});
}
elseif(typeofmodule==='object'&&module.exports){
module.exports=EventEmitter;
}
else{
exports.EventEmitter=EventEmitter;
}
}.call(this));
/*!
* EventEmitter v4.2.11 - git.io/ee
* Unlicense - http://unlicense.org/
* Oliver Caldwell - http://oli.me.uk/
* @preserve
*/
;(function(){
'use strict';
/**
* Class for managing events.
* Can be extended to provide event functionality in other classes.
*
* @class EventEmitter Manages event registering and emitting.
*/
functionEventEmitter(){}
// Shortcuts to improve speed and size
varproto=EventEmitter.prototype;
varexports=this;
varoriginalGlobalValue=exports.EventEmitter;
/**
* Finds the index of the listener for the event in its storage array.
*
* @param {Function[]} listeners Array of listeners to search through.
* @param {Function} listener Method to look for.
* @return {Number} Index of the specified listener, -1 if not found
* @api private
*/
functionindexOfListener(listeners,listener){
vari=listeners.length;
while(i--){
if(listeners[i].listener===listener){
returni;
}
}
return-1;
}
/**
* Alias a method while keeping the context correct, to allow for overwriting of target method.
*
* @param {String} name The name of the target method.
* @return {Function} The aliased method
* @api private
*/
functionalias(name){
returnfunctionaliasClosure(){
returnthis[name].apply(this,arguments);
};
}
/**
* Returns the listener array for the specified event.
* Will initialise the event object and listener arrays if required.
* Will return an object if you use a regex search. The object contains keys for each matched event. So /ba[rz]/ might return an object containing bar and baz. But only if you have either defined them with defineEvent or added some listeners to them.
* Each property in the object response is an array of listener functions.
*
* @param {String|RegExp} evt Name of the event to return the listeners from.
* @return {Function[]|Object} All listener functions for the event.
*/
proto.getListeners=functiongetListeners(evt){
varevents=this._getEvents();
varresponse;
varkey;
// Return a concatenated array of all matching events if
// the selector is a regular expression.
if(evtinstanceofRegExp){
response={};
for(keyinevents){
if(events.hasOwnProperty(key)&&evt.test(key)){
response[key]=events[key];
}
}
}
else{
response=events[evt]||(events[evt]=[]);
}
returnresponse;
};
/**
* Takes a list of listener objects and flattens it into a list of listener functions.
*
* @param {Object[]} listeners Raw listener objects.
* @return {Function[]} Just the listener functions.
* Fetches the requested listeners via getListeners but will always return the results inside an object. This is mainly for internal use but others may find it useful.
*
* @param {String|RegExp} evt Name of the event to return the listeners from.
* @return {Object} All listener functions for an event in an object.
* Defines an event name. This is required if you want to use a regex to add a listener to multiple events at once. If you don't do this then how do you expect it to know what event to add to? Should it just add to every possible match for a regex? No. That is scary and bad.
* You need to tell it what event names should be matched by a regex.
*
* @param {String} evt Name of the event to create.
* @return {Object} Current instance of EventEmitter for chaining.
*/
proto.defineEvent=functiondefineEvent(evt){
this.getListeners(evt);
returnthis;
};
/**
* Uses defineEvent to define multiple events.
*
* @param {String[]} evts An array of event names to define.
* @return {Object} Current instance of EventEmitter for chaining.
*/
proto.defineEvents=functiondefineEvents(evts){
for(vari=0;i<evts.length;i+=1){
this.defineEvent(evts[i]);
}
returnthis;
};
/**
* Removes a listener function from the specified event.
* When passed a regular expression as the event name, it will remove the listener from all events that match it.
*
* @param {String|RegExp} evt Name of the event to remove the listener from.
* @param {Function} listener Method to remove from the event.
* @return {Object} Current instance of EventEmitter for chaining.
* Adds listeners in bulk using the manipulateListeners method.
* If you pass an object as the second argument you can add to multiple events at once. The object should contain key value pairs of events and listeners or listener arrays. You can also pass it an event name and an array of listeners to be added.
* You can also pass it a regular expression to add the array of listeners to all events that match it.
* Yeah, this function does quite a bit. That's probably a bad thing.
*
* @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add to multiple events at once.
* @param {Function[]} [listeners] An optional array of listener functions to add.
* @return {Object} Current instance of EventEmitter for chaining.
* Removes listeners in bulk using the manipulateListeners method.
* If you pass an object as the second argument you can remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.
* You can also pass it an event name and an array of listeners to be removed.
* You can also pass it a regular expression to remove the listeners from all events that match it.
*
* @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to remove from multiple events at once.
* @param {Function[]} [listeners] An optional array of listener functions to remove.
* @return {Object} Current instance of EventEmitter for chaining.
* Edits listeners in bulk. The addListeners and removeListeners methods both use this to do their job. You should really use those instead, this is a little lower level.
* The first argument will determine if the listeners are removed (true) or added (false).
* If you pass an object as the second argument you can add/remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.
* You can also pass it an event name and an array of listeners to be added/removed.
* You can also pass it a regular expression to manipulate the listeners of all events that match it.
*
* @param {Boolean} remove True if you want to remove listeners, false if you want to add.
* @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add/remove from multiple events at once.
* @param {Function[]} [listeners] An optional array of listener functions to add/remove.
* @return {Object} Current instance of EventEmitter for chaining.
- [Tests] Add some conditionals to avoid impossible-to-fix test failures in IE 6-8, due to it being unable to distinguish between `undefined` and an absent index (#114)
- [Tests] Fix false negatives in IE 6-8 with jasmine comparing arrays to arraylikes (#114)
- [Tests] Add some conditionals to avoid impossible-to-fix test failures in IE 6-8, due to it being unable to distinguish between `undefined` and an absent index (#114)
- [Tests] Fix false negatives in IE 6-8 with jasmine comparing arrays to arraylikes (#114)
# The files that need updating when incrementing the version number.
VERSIONED_FILES:=*.js *.json *.map README*
# Add the local npm packages' bin folder to the PATH, so that `make` can find them, when invoked directly.
# Note that rather than using `$(npm bin)` the 'node_modules/.bin' path component is hard-coded, so that invocation works even from an environment
# where npm is (temporarily) unavailable due to having deactivated an nvm instance loaded into the calling shell in order to avoid interference with tests.
# Make sure that all required utilities can be located.
UTIL_CHECK:=$(or $(shellPATH="$(PATH)" which $(UTILS) >/dev/null &&echo'ok'),$(error Did you forget to run `npm install` after cloning the repo? At least one of the required supporting utilities not found: $(UTILS)))
# Default target (by virtue of being the first non '.'-prefixed in the file).
.PHONY:_no-target-specified
_no-target-specified:
$(error Please specify the target to make - `make list` shows targets. Alternatively, use `npm test` to run the default tests; `npm run` shows all tests)
# All-tests target: invokes the specified test suites for ALL shells defined in $(SHELLS).
.PHONY:test
test:
@npm test
.PHONY:_ensure-tag
_ensure-tag:
ifndefTAG
$(errorPleaseinvokewith`makeTAG=<new-version> release`, where <new-version> is either an increment specifier (patch, minor, major, prepatch, preminor, premajor, prerelease), or an explicit major.minor.patch version number)
endif
CHANGELOG_ERROR=$(error No CHANGES specified)
.PHONY:_ensure-changelog
_ensure-changelog:
@(git status -sb --porcelain | command grep -E '^( M|[MA] ) CHANGES' > /dev/null)||(echo no CHANGES specified &&exit 2)
# Ensures that the git workspace is clean.
.PHONY:_ensure-clean
_ensure-clean:
@[ -z "$$((git status --porcelain --untracked-files=no || echo err) | command grep -v 'CHANGES')"]||{echo"Workspace is not clean; please commit changes first." >&2; exit 2; }
# Makes a release; invoke with `make TAG=<versionOrIncrementSpec> release`.
printf"=== Bumping version **$$old_ver** to **$$new_ver** before committing and tagging:\n=== TYPE 'proceed' TO PROCEED, anything else to abort: "&&read response &&["$$response"='proceed']||{echo'Aborted.' >&2; exit 2; }; \
# The files that need updating when incrementing the version number.
VERSIONED_FILES:=*.js *.json *.map README*
# Add the local npm packages' bin folder to the PATH, so that `make` can find them, when invoked directly.
# Note that rather than using `$(npm bin)` the 'node_modules/.bin' path component is hard-coded, so that invocation works even from an environment
# where npm is (temporarily) unavailable due to having deactivated an nvm instance loaded into the calling shell in order to avoid interference with tests.
# Make sure that all required utilities can be located.
UTIL_CHECK:=$(or $(shellPATH="$(PATH)" which $(UTILS) >/dev/null &&echo'ok'),$(error Did you forget to run `npm install` after cloning the repo? At least one of the required supporting utilities not found: $(UTILS)))
# Default target (by virtue of being the first non '.'-prefixed in the file).
.PHONY:_no-target-specified
_no-target-specified:
$(error Please specify the target to make - `make list` shows targets. Alternatively, use `npm test` to run the default tests; `npm run` shows all tests)
# All-tests target: invokes the specified test suites for ALL shells defined in $(SHELLS).
.PHONY:test
test:
@npm test
.PHONY:_ensure-tag
_ensure-tag:
ifndefTAG
$(errorPleaseinvokewith`makeTAG=<new-version> release`, where <new-version> is either an increment specifier (patch, minor, major, prepatch, preminor, premajor, prerelease), or an explicit major.minor.patch version number)
endif
CHANGELOG_ERROR=$(error No CHANGES specified)
.PHONY:_ensure-changelog
_ensure-changelog:
@(git status -sb --porcelain | command grep -E '^( M|[MA] ) CHANGES' > /dev/null)||(echo no CHANGES specified &&exit 2)
# Ensures that the git workspace is clean.
.PHONY:_ensure-clean
_ensure-clean:
@[ -z "$$((git status --porcelain --untracked-files=no || echo err) | command grep -v 'CHANGES')"]||{echo"Workspace is not clean; please commit changes first." >&2; exit 2; }
# Makes a release; invoke with `make TAG=<versionOrIncrementSpec> release`.
printf"=== Bumping version **$$old_ver** to **$$new_ver** before committing and tagging:\n=== TYPE 'proceed' TO PROCEED, anything else to abort: "&&read response &&["$$response"='proceed']||{echo'Aborted.' >&2; exit 2; }; \
* @license es5-shim Copyright 2009-2015 by contributors, MIT License
* see https://github.com/es-shims/es5-shim/blob/v4.5.7/LICENSE
*/
(function(e,t){"use strict";if(typeofdefine==="function"&&define.amd){define(t)}elseif(typeofexports==="object"){module.exports=t()}else{e.returnExports=t()}})(this,function(){vare=Function.call;vart=Object.prototype;varr=e.bind(t.hasOwnProperty);varn=e.bind(t.propertyIsEnumerable);varo=e.bind(t.toString);vari;varc;varf;vara;varl=r(t,"__defineGetter__");if(l){i=e.bind(t.__defineGetter__);c=e.bind(t.__defineSetter__);f=e.bind(t.__lookupGetter__);a=e.bind(t.__lookupSetter__)}if(!Object.getPrototypeOf){Object.getPrototypeOf=functiongetPrototypeOf(e){varr=e.__proto__;if(r||r===null){returnr}elseif(o(e.constructor)==="[object Function]"){returne.constructor.prototype}elseif(einstanceofObject){returnt}else{returnnull}}}varu=functiondoesGetOwnPropertyDescriptorWork(e){try{e.sentinel=0;returnObject.getOwnPropertyDescriptor(e,"sentinel").value===0}catch(t){returnfalse}};if(Object.defineProperty){varp=u({});vars=typeofdocument==="undefined"||u(document.createElement("div"));if(!s||!p){varb=Object.getOwnPropertyDescriptor}}if(!Object.getOwnPropertyDescriptor||b){varO="Object.getOwnPropertyDescriptor called on a non-object: ";Object.getOwnPropertyDescriptor=functiongetOwnPropertyDescriptor(e,o){if(typeofe!=="object"&&typeofe!=="function"||e===null){thrownewTypeError(O+e)}if(b){try{returnb.call(Object,e,o)}catch(i){}}varc;if(!r(e,o)){returnc}c={enumerable:n(e,o),configurable:true};if(l){varu=e.__proto__;varp=e!==t;if(p){e.__proto__=t}vars=f(e,o);vary=a(e,o);if(p){e.__proto__=u}if(s||y){if(s){c.get=s}if(y){c.set=y}returnc}}c.value=e[o];c.writable=true;returnc}}if(!Object.getOwnPropertyNames){Object.getOwnPropertyNames=functiongetOwnPropertyNames(e){returnObject.keys(e)}}if(!Object.create){vary;vard=!({__proto__:null}instanceofObject);varj=functionshouldUseActiveX(){if(!document.domain){returnfalse}try{return!!newActiveXObject("htmlfile")}catch(e){returnfalse}};varv=functiongetEmptyViaActiveX(){vare;vart;t=newActiveXObject("htmlfile");t.write("<script></script>");t.close();e=t.parentWindow.Object.prototype;t=null;returne};var_=functiongetEmptyViaIFrame(){vare=document.createElement("iframe");vart=document.body||document.documentElement;varr;e.style.display="none";t.appendChild(e);e.src="javascript:";r=e.contentWindow.Object.prototype;t.removeChild(e);e=null;returnr};if(d||typeofdocument==="undefined"){y=function(){return{__proto__:null}}}else{y=function(){vare=j()?v():_();deletee.constructor;deletee.hasOwnProperty;deletee.propertyIsEnumerable;deletee.isPrototypeOf;deletee.toLocaleString;deletee.toString;deletee.valueOf;vart=functionEmpty(){};t.prototype=e;y=function(){returnnewt};returnnewt}}Object.create=functioncreate(e,t){varr;varn=functionType(){};if(e===null){r=y()}else{if(typeofe!=="object"&&typeofe!=="function"){thrownewTypeError("Object prototype may only be an Object or null")}n.prototype=e;r=newn;r.__proto__=e}if(t!==void0){Object.defineProperties(r,t)}returnr}}varw=functiondoesDefinePropertyWork(e){try{Object.defineProperty(e,"sentinel",{});return"sentinel"ine}catch(t){returnfalse}};if(Object.defineProperty){varm=w({});varP=typeofdocument==="undefined"||w(document.createElement("div"));if(!m||!P){varE=Object.defineProperty,h=Object.defineProperties}}if(!Object.defineProperty||E){varg="Property description must be an object: ";varz="Object.defineProperty called on non-object: ";varT="getters & setters can not be defined on this javascript engine";Object.defineProperty=functiondefineProperty(e,r,n){if(typeofe!=="object"&&typeofe!=="function"||e===null){thrownewTypeError(z+e)}if(typeofn!=="object"&&typeofn!=="function"||n===null){thrownewTypeError(g+n)}if(E){try{returnE.call(Object,e,r,n)}catch(o){}}if("value"inn){if(l&&(f(e,r)||a(e,r))){varu=e.__proto__;e.__proto__=t;deletee[r];e[r]=n.value;e.__proto__=u}else{e[r]=n.value}}else{if(!l&&("get"inn||"set"inn)){thrownewTypeError(T)}if("get"inn){i(e,r,n.get)}if("set"inn){c(e,r,n.set)}}returne}}if(!Object.defineProperties||h){Object.defineProperties=functiondefineProperties(e,t){if(h){try{returnh.call(Object,e,t)}catch(r){}}Object.keys(t).forEach(function(r){if(r!=="__proto__"){Object.defineProperty(e,r,t[r])}});returne}}if(!Object.seal){Object.seal=functionseal(e){if(Object(e)!==e){thrownewTypeError("Object.seal can only be called on Objects.")}returne}}if(!Object.freeze){Object.freeze=functionfreeze(e){if(Object(e)!==e){thrownewTypeError("Object.freeze can only be called on Objects.")}returne}}try{Object.freeze(function(){})}catch(x){Object.freeze=function(e){returnfunctionfreeze(t){if(typeoft==="function"){returnt}else{returne(t)}}}(Object.freeze)}if(!Object.preventExtensions){Object.preventExtensions=functionpreventExtensions(e){if(Object(e)!==e){thrownewTypeError("Object.preventExtensions can only be called on Objects.")}returne}}if(!Object.isSealed){Object.isSealed=functionisSealed(e){if(Object(e)!==e){thrownewTypeError("Object.isSealed can only be called on Objects.")}returnfalse}}if(!Object.isFrozen){Object.isFrozen=functionisFrozen(e){if(Object(e)!==e){thrownewTypeError("Object.isFrozen can only be called on Objects.")}returnfalse}}if(!Object.isExtensible){Object.isExtensible=functionisExtensible(e){if(Object(e)!==e){thrownewTypeError("Object.isExtensible can only be called on Objects.")}vart="";while(r(e,t)){t+="?"}e[t]=true;varn=r(e,t);deletee[t];returnn}}});
//# sourceMappingURL=es5-sham.map
/*!
* https://github.com/es-shims/es5-shim
* @license es5-shim Copyright 2009-2015 by contributors, MIT License
* see https://github.com/es-shims/es5-shim/blob/v4.5.7/LICENSE
*/
(function(e,t){"use strict";if(typeofdefine==="function"&&define.amd){define(t)}elseif(typeofexports==="object"){module.exports=t()}else{e.returnExports=t()}})(this,function(){vare=Function.call;vart=Object.prototype;varr=e.bind(t.hasOwnProperty);varn=e.bind(t.propertyIsEnumerable);varo=e.bind(t.toString);vari;varc;varf;vara;varl=r(t,"__defineGetter__");if(l){i=e.bind(t.__defineGetter__);c=e.bind(t.__defineSetter__);f=e.bind(t.__lookupGetter__);a=e.bind(t.__lookupSetter__)}if(!Object.getPrototypeOf){Object.getPrototypeOf=functiongetPrototypeOf(e){varr=e.__proto__;if(r||r===null){returnr}elseif(o(e.constructor)==="[object Function]"){returne.constructor.prototype}elseif(einstanceofObject){returnt}else{returnnull}}}varu=functiondoesGetOwnPropertyDescriptorWork(e){try{e.sentinel=0;returnObject.getOwnPropertyDescriptor(e,"sentinel").value===0}catch(t){returnfalse}};if(Object.defineProperty){varp=u({});vars=typeofdocument==="undefined"||u(document.createElement("div"));if(!s||!p){varb=Object.getOwnPropertyDescriptor}}if(!Object.getOwnPropertyDescriptor||b){varO="Object.getOwnPropertyDescriptor called on a non-object: ";Object.getOwnPropertyDescriptor=functiongetOwnPropertyDescriptor(e,o){if(typeofe!=="object"&&typeofe!=="function"||e===null){thrownewTypeError(O+e)}if(b){try{returnb.call(Object,e,o)}catch(i){}}varc;if(!r(e,o)){returnc}c={enumerable:n(e,o),configurable:true};if(l){varu=e.__proto__;varp=e!==t;if(p){e.__proto__=t}vars=f(e,o);vary=a(e,o);if(p){e.__proto__=u}if(s||y){if(s){c.get=s}if(y){c.set=y}returnc}}c.value=e[o];c.writable=true;returnc}}if(!Object.getOwnPropertyNames){Object.getOwnPropertyNames=functiongetOwnPropertyNames(e){returnObject.keys(e)}}if(!Object.create){vary;vard=!({__proto__:null}instanceofObject);varj=functionshouldUseActiveX(){if(!document.domain){returnfalse}try{return!!newActiveXObject("htmlfile")}catch(e){returnfalse}};varv=functiongetEmptyViaActiveX(){vare;vart;t=newActiveXObject("htmlfile");t.write("<script></script>");t.close();e=t.parentWindow.Object.prototype;t=null;returne};var_=functiongetEmptyViaIFrame(){vare=document.createElement("iframe");vart=document.body||document.documentElement;varr;e.style.display="none";t.appendChild(e);e.src="javascript:";r=e.contentWindow.Object.prototype;t.removeChild(e);e=null;returnr};if(d||typeofdocument==="undefined"){y=function(){return{__proto__:null}}}else{y=function(){vare=j()?v():_();deletee.constructor;deletee.hasOwnProperty;deletee.propertyIsEnumerable;deletee.isPrototypeOf;deletee.toLocaleString;deletee.toString;deletee.valueOf;vart=functionEmpty(){};t.prototype=e;y=function(){returnnewt};returnnewt}}Object.create=functioncreate(e,t){varr;varn=functionType(){};if(e===null){r=y()}else{if(typeofe!=="object"&&typeofe!=="function"){thrownewTypeError("Object prototype may only be an Object or null")}n.prototype=e;r=newn;r.__proto__=e}if(t!==void0){Object.defineProperties(r,t)}returnr}}varw=functiondoesDefinePropertyWork(e){try{Object.defineProperty(e,"sentinel",{});return"sentinel"ine}catch(t){returnfalse}};if(Object.defineProperty){varm=w({});varP=typeofdocument==="undefined"||w(document.createElement("div"));if(!m||!P){varE=Object.defineProperty,h=Object.defineProperties}}if(!Object.defineProperty||E){varg="Property description must be an object: ";varz="Object.defineProperty called on non-object: ";varT="getters & setters can not be defined on this javascript engine";Object.defineProperty=functiondefineProperty(e,r,n){if(typeofe!=="object"&&typeofe!=="function"||e===null){thrownewTypeError(z+e)}if(typeofn!=="object"&&typeofn!=="function"||n===null){thrownewTypeError(g+n)}if(E){try{returnE.call(Object,e,r,n)}catch(o){}}if("value"inn){if(l&&(f(e,r)||a(e,r))){varu=e.__proto__;e.__proto__=t;deletee[r];e[r]=n.value;e.__proto__=u}else{e[r]=n.value}}else{if(!l&&("get"inn||"set"inn)){thrownewTypeError(T)}if("get"inn){i(e,r,n.get)}if("set"inn){c(e,r,n.set)}}returne}}if(!Object.defineProperties||h){Object.defineProperties=functiondefineProperties(e,t){if(h){try{returnh.call(Object,e,t)}catch(r){}}Object.keys(t).forEach(function(r){if(r!=="__proto__"){Object.defineProperty(e,r,t[r])}});returne}}if(!Object.seal){Object.seal=functionseal(e){if(Object(e)!==e){thrownewTypeError("Object.seal can only be called on Objects.")}returne}}if(!Object.freeze){Object.freeze=functionfreeze(e){if(Object(e)!==e){thrownewTypeError("Object.freeze can only be called on Objects.")}returne}}try{Object.freeze(function(){})}catch(x){Object.freeze=function(e){returnfunctionfreeze(t){if(typeoft==="function"){returnt}else{returne(t)}}}(Object.freeze)}if(!Object.preventExtensions){Object.preventExtensions=functionpreventExtensions(e){if(Object(e)!==e){thrownewTypeError("Object.preventExtensions can only be called on Objects.")}returne}}if(!Object.isSealed){Object.isSealed=functionisSealed(e){if(Object(e)!==e){thrownewTypeError("Object.isSealed can only be called on Objects.")}returnfalse}}if(!Object.isFrozen){Object.isFrozen=functionisFrozen(e){if(Object(e)!==e){thrownewTypeError("Object.isFrozen can only be called on Objects.")}returnfalse}}if(!Object.isExtensible){Object.isExtensible=functionisExtensible(e){if(Object(e)!==e){thrownewTypeError("Object.isExtensible can only be called on Objects.")}vart="";while(r(e,t)){t+="?"}e[t]=true;varn=r(e,t);deletee[t];returnn}}});
* @license es5-shim Copyright 2009-2015 by contributors, MIT License
* see https://github.com/es-shims/es5-shim/blob/v4.5.7/LICENSE
*/
(function(t,r){"use strict";if(typeofdefine==="function"&&define.amd){define(r)}elseif(typeofexports==="object"){module.exports=r()}else{t.returnExports=r()}})(this,function(){vart=Array;varr=t.prototype;vare=Object;varn=e.prototype;vari=Function;vara=i.prototype;varo=String;varf=o.prototype;varu=Number;varl=u.prototype;vars=r.slice;varc=r.splice;varv=r.push;varh=r.unshift;varp=r.concat;vary=r.join;vard=a.call;varg=a.apply;varw=Math.max;varb=Math.min;varT=n.toString;varm=typeofSymbol==="function"&&typeofSymbol.toStringTag==="symbol";varD;varx=Function.prototype.toString,S=/^\s*class /,O=functionisES6ClassFn(t){try{varr=x.call(t);vare=r.replace(/\/\/.*\n/g,"");varn=e.replace(/\/\*[.\s\S]*\*\//g,"");vari=n.replace(/\n/gm," ").replace(/ {2}/g," ");returnS.test(i)}catch(a){returnfalse}},E=functiontryFunctionObject(t){try{if(O(t)){returnfalse}x.call(t);returntrue}catch(r){returnfalse}},j="[object Function]",I="[object GeneratorFunction]",D=functionisCallable(t){if(!t){returnfalse}if(typeoft!=="function"&&typeoft!=="object"){returnfalse}if(m){returnE(t)}if(O(t)){returnfalse}varr=T.call(t);returnr===j||r===I};varM;varU=RegExp.prototype.exec,F=functiontryRegexExec(t){try{U.call(t);returntrue}catch(r){returnfalse}},N="[object RegExp]";M=functionisRegex(t){if(typeoft!=="object"){returnfalse}returnm?F(t):T.call(t)===N};varC;vark=String.prototype.valueOf,R=functiontryStringObject(t){try{k.call(t);returntrue}catch(r){returnfalse}},A="[object String]";C=functionisString(t){if(typeoft==="string"){returntrue}if(typeoft!=="object"){returnfalse}returnm?R(t):T.call(t)===A};varP=e.defineProperty&&function(){try{vart={};e.defineProperty(t,"x",{enumerable:false,value:t});for(varrint){returnfalse}returnt.x===t}catch(n){returnfalse}}();var$=function(t){varr;if(P){r=function(t,r,n,i){if(!i&&rint){return}e.defineProperty(t,r,{configurable:true,enumerable:false,writable:true,value:n})}}else{r=function(t,r,e,n){if(!n&&rint){return}t[r]=e}}returnfunctiondefineProperties(e,n,i){for(varainn){if(t.call(n,a)){r(e,a,n[a],i)}}}}(n.hasOwnProperty);varJ=functionisPrimitive(t){varr=typeoft;returnt===null||r!=="object"&&r!=="function"};varY=u.isNaN||function(t){returnt!==t};varZ={ToInteger:functionToInteger(t){varr=+t;if(Y(r)){r=0}elseif(r!==0&&r!==1/0&&r!==-(1/0)){r=(r>0||-1)*Math.floor(Math.abs(r))}returnr},ToPrimitive:functionToPrimitive(t){varr,e,n;if(J(t)){returnt}e=t.valueOf;if(D(e)){r=e.call(t);if(J(r)){returnr}}n=t.toString;if(D(n)){r=n.call(t);if(J(r)){returnr}}thrownewTypeError},ToObject:function(t){if(t==null){thrownewTypeError("can't convert "+t+" to object")}returne(t)},ToUint32:functionToUint32(t){returnt>>>0}};varz=functionEmpty(){};$(a,{bind:functionbind(t){varr=this;if(!D(r)){thrownewTypeError("Function.prototype.bind called on incompatible "+r)}varn=s.call(arguments,1);vara;varo=function(){if(thisinstanceofa){vari=g.call(r,this,p.call(n,s.call(arguments)));if(e(i)===i){returni}returnthis}else{returng.call(r,t,p.call(n,s.call(arguments)))}};varf=w(0,r.length-n.length);varu=[];for(varl=0;l<f;l++){v.call(u,"$"+l)}a=i("binder","return function ("+y.call(u,",")+"){ return binder.apply(this, arguments); }")(o);if(r.prototype){z.prototype=r.prototype;a.prototype=newz;z.prototype=null}returna}});varG=d.bind(n.hasOwnProperty);varB=d.bind(n.toString);varH=d.bind(s);varW=g.bind(s);varL=d.bind(f.slice);varX=d.bind(f.split);varq=d.bind(f.indexOf);varK=d.bind(v);varQ=d.bind(n.propertyIsEnumerable);varV=d.bind(r.sort);var_=t.isArray||functionisArray(t){returnB(t)==="[object Array]"};vartt=[].unshift(0)!==1;$(r,{unshift:function(){h.apply(this,arguments);returnthis.length}},tt);$(t,{isArray:_});varrt=e("a");varet=rt[0]!=="a"||!(0inrt);varnt=functionproperlyBoxed(t){varr=true;vare=true;varn=false;if(t){try{t.call("foo",function(t,e,n){if(typeofn!=="object"){r=false}});t.call([1],function(){"use strict";e=typeofthis==="string"},"x")}catch(i){n=true}}return!!t&&!n&&r&&e};$(r,{forEach:functionforEach(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=-1;vari=Z.ToUint32(e.length);vara;if(arguments.length>1){a=arguments[1]}if(!D(t)){thrownewTypeError("Array.prototype.forEach callback must be a function")}while(++n<i){if(nine){if(typeofa==="undefined"){t(e[n],n,r)}else{t.call(a,e[n],n,r)}}}}},!nt(r.forEach));$(r,{map:functionmap(r){vare=Z.ToObject(this);varn=et&&C(this)?X(this,""):e;vari=Z.ToUint32(n.length);vara=t(i);varo;if(arguments.length>1){o=arguments[1]}if(!D(r)){thrownewTypeError("Array.prototype.map callback must be a function")}for(varf=0;f<i;f++){if(finn){if(typeofo==="undefined"){a[f]=r(n[f],f,e)}else{a[f]=r.call(o,n[f],f,e)}}}returna}},!nt(r.map));$(r,{filter:functionfilter(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);vari=[];vara;varo;if(arguments.length>1){o=arguments[1]}if(!D(t)){thrownewTypeError("Array.prototype.filter callback must be a function")}for(varf=0;f<n;f++){if(fine){a=e[f];if(typeofo==="undefined"?t(a,f,r):t.call(o,a,f,r)){K(i,a)}}}returni}},!nt(r.filter));$(r,{every:functionevery(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);vari;if(arguments.length>1){i=arguments[1]}if(!D(t)){thrownewTypeError("Array.prototype.every callback must be a function")}for(vara=0;a<n;a++){if(aine&&!(typeofi==="undefined"?t(e[a],a,r):t.call(i,e[a],a,r))){returnfalse}}returntrue}},!nt(r.every));$(r,{some:functionsome(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);vari;if(arguments.length>1){i=arguments[1]}if(!D(t)){thrownewTypeError("Array.prototype.some callback must be a function")}for(vara=0;a<n;a++){if(aine&&(typeofi==="undefined"?t(e[a],a,r):t.call(i,e[a],a,r))){returntrue}}returnfalse}},!nt(r.some));varit=false;if(r.reduce){it=typeofr.reduce.call("es5",function(t,r,e,n){returnn})==="object"}$(r,{reduce:functionreduce(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);if(!D(t)){thrownewTypeError("Array.prototype.reduce callback must be a function")}if(n===0&&arguments.length===1){thrownewTypeError("reduce of empty array with no initial value")}vari=0;vara;if(arguments.length>=2){a=arguments[1]}else{do{if(iine){a=e[i++];break}if(++i>=n){thrownewTypeError("reduce of empty array with no initial value")}}while(true)}for(;i<n;i++){if(iine){a=t(a,e[i],i,r)}}returna}},!it);varat=false;if(r.reduceRight){at=typeofr.reduceRight.call("es5",function(t,r,e,n){returnn})==="object"}$(r,{reduceRight:functionreduceRight(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);if(!D(t)){thrownewTypeError("Array.prototype.reduceRight callback must be a function")}if(n===0&&arguments.length===1){thrownewTypeError("reduceRight of empty array with no initial value")}vari;vara=n-1;if(arguments.length>=2){i=arguments[1]}else{do{if(aine){i=e[a--];break}if(--a<0){thrownewTypeError("reduceRight of empty array with no initial value")}}while(true)}if(a<0){returni}do{if(aine){i=t(i,e[a],a,r)}}while(a--);returni}},!at);varot=r.indexOf&&[0,1].indexOf(1,2)!==-1;$(r,{indexOf:functionindexOf(t){varr=et&&C(this)?X(this,""):Z.ToObject(this);vare=Z.ToUint32(r.length);if(e===0){return-1}varn=0;if(arguments.length>1){n=Z.ToInteger(arguments[1])}n=n>=0?n:w(0,e+n);for(;n<e;n++){if(ninr&&r[n]===t){returnn}}return-1}},ot);varft=r.lastIndexOf&&[0,1].lastIndexOf(0,-3)!==-1;$(r,{lastIndexOf:functionlastIndexOf(t){varr=et&&C(this)?X(this,""):Z.ToObject(this);vare=Z.ToUint32(r.length);if(e===0){return-1}varn=e-1;if(arguments.length>1){n=b(n,Z.ToInteger(arguments[1]))}n=n>=0?n:e-Math.abs(n);for(;n>=0;n--){if(ninr&&t===r[n]){returnn}}return-1}},ft);varut=function(){vart=[1,2];varr=t.splice();returnt.length===2&&_(r)&&r.length===0}();$(r,{splice:functionsplice(t,r){if(arguments.length===0){return[]}else{returnc.apply(this,arguments)}}},!ut);varlt=function(){vart={};r.splice.call(t,0,0,1);returnt.length===1}();$(r,{splice:functionsplice(t,r){if(arguments.length===0){return[]}vare=arguments;this.length=w(Z.ToInteger(this.length),0);if(arguments.length>0&&typeofr!=="number"){e=H(arguments);if(e.length<2){K(e,this.length-t)}else{e[1]=Z.ToInteger(r)}}returnc.apply(this,e)}},!lt);varst=function(){varr=newt(1e5);r[8]="x";r.splice(1,1);returnr.indexOf("x")===7}();varct=function(){vart=256;varr=[];r[t]="a";r.splice(t+1,0,"b");returnr[t]==="a"}();$(r,{splice:functionsplice(t,r){vare=Z.ToObject(this);varn=[];vari=Z.ToUint32(e.length);vara=Z.ToInteger(t);varf=a<0?w(i+a,0):b(a,i);varu=b(w(Z.ToInteger(r),0),i-f);varl=0;vars;while(l<u){s=o(f+l);if(G(e,s)){n[l]=e[s]}l+=1}varc=H(arguments,2);varv=c.length;varh;if(v<u){l=f;varp=i-u;while(l<p){s=o(l+u);h=o(l+v);if(G(e,s)){e[h]=e[s]}else{deletee[h]}l+=1}l=i;vary=i-u+v;while(l>y){deletee[l-1];l-=1}}elseif(v>u){l=i-u;while(l>f){s=o(l+u-1);h=o(l+v-1);if(G(e,s)){e[h]=e[s]}else{deletee[h]}l-=1}}l=f;for(vard=0;d<c.length;++d){e[l]=c[d];l+=1}e.length=i-u+v;returnn}},!st||!ct);varvt=r.join;varht;try{ht=Array.prototype.join.call("123",",")!=="1,2,3"}catch(pt){ht=true}if(ht){$(r,{join:functionjoin(t){varr=typeoft==="undefined"?",":t;returnvt.call(C(this)?X(this,""):this,r)}},ht)}varyt=[1,2].join(undefined)!=="1,2";if(yt){$(r,{join:functionjoin(t){varr=typeoft==="undefined"?",":t;returnvt.call(this,r)}},yt)}vardt=functionpush(t){varr=Z.ToObject(this);vare=Z.ToUint32(r.length);varn=0;while(n<arguments.length){r[e+n]=arguments[n];n+=1}r.length=e+n;returne+n};vargt=function(){vart={};varr=Array.prototype.push.call(t,undefined);returnr!==1||t.length!==1||typeoft[0]!=="undefined"||!G(t,0)}();$(r,{push:functionpush(t){if(_(this)){returnv.apply(this,arguments)}returndt.apply(this,arguments)}},gt);varwt=function(){vart=[];varr=t.push(undefined);returnr!==1||t.length!==1||typeoft[0]!=="undefined"||!G(t,0)}();$(r,{push:dt},wt);$(r,{slice:function(t,r){vare=C(this)?X(this,""):this;returnW(e,arguments)}},et);varbt=function(){try{[1,2].sort(null);[1,2].sort({});returntrue}catch(t){}returnfalse}();varTt=function(){try{[1,2].sort(/a/);returnfalse}catch(t){}returntrue}();varmt=function(){try{[1,2].sort(undefined);returntrue}catch(t){}returnfalse}();$(r,{sort:functionsort(t){if(typeoft==="undefined"){returnV(this)}if(!D(t)){thrownewTypeError("Array.prototype.sort callback must be a function")}returnV(this,t)}},bt||!mt||!Tt);varDt=!{toString:null}.propertyIsEnumerable("toString");varxt=function(){}.propertyIsEnumerable("prototype");varSt=!G("x","0");varOt=function(t){varr=t.constructor;returnr&&r.prototype===t};varEt={$window:true,$console:true,$parent:true,$self:true,$frame:true,$frames:true,$frameElement:true,$webkitIndexedDB:true,$webkitStorageInfo:true,$external:true};varjt=function(){if(typeofwindow==="undefined"){returnfalse}for(vartinwindow){try{if(!Et["$"+t]&&G(window,t)&&window[t]!==null&&typeofwindow[t]==="object"){Ot(window[t])}}catch(r){returntrue}}returnfalse}();varIt=function(t){if(typeofwindow==="undefined"||!jt){returnOt(t)}try{returnOt(t)}catch(r){returnfalse}};varMt=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];varUt=Mt.length;varFt=functionisArguments(t){returnB(t)==="[object Arguments]"};varNt=functionisArguments(t){returnt!==null&&typeoft==="object"&&typeoft.length==="number"&&t.length>=0&&!_(t)&&D(t.callee)};varCt=Ft(arguments)?Ft:Nt;$(e,{keys:functionkeys(t){varr=D(t);vare=Ct(t);varn=t!==null&&typeoft==="object";vari=n&&C(t);if(!n&&!r&&!e){thrownewTypeError("Object.keys called on a non-object")}vara=[];varf=xt&&r;if(i&&St||e){for(varu=0;u<t.length;++u){K(a,o(u))}}if(!e){for(varlint){if(!(f&&l==="prototype")&&G(t,l)){K(a,o(l))}}}if(Dt){vars=It(t);for(varc=0;c<Ut;c++){varv=Mt[c];if(!(s&&v==="constructor")&&G(t,v)){K(a,v)}}}returna}});varkt=e.keys&&function(){returne.keys(arguments).length===2}(1,2);varRt=e.keys&&function(){vart=e.keys(arguments);returnarguments.length!==1||t.length!==1||t[0]!==1}(1);varAt=e.keys;$(e,{keys:functionkeys(t){if(Ct(t)){returnAt(H(t))}else{returnAt(t)}}},!kt||Rt);varPt=newDate(-0xc782b5b342b24).getUTCMonth()!==0;var$t=newDate(-0x55d318d56a724);varJt=newDate(14496624e5);varYt=$t.toUTCString()!=="Mon, 01 Jan -45875 11:59:59 GMT";varZt;varzt;varGt=$t.getTimezoneOffset();if(Gt<-720){Zt=$t.toDateString()!=="Tue Jan 02 -45875";zt=!/^Thu Dec 10 2015 \d\d:\d\d:\d\d GMT[-\+]\d\d\d\d(?: |$)/.test(Jt.toString())}else{Zt=$t.toDateString()!=="Mon Jan 01 -45875";zt=!/^Wed Dec 09 2015 \d\d:\d\d:\d\d GMT[-\+]\d\d\d\d(?: |$)/.test(Jt.toString())}varBt=d.bind(Date.prototype.getFullYear);varHt=d.bind(Date.prototype.getMonth);varWt=d.bind(Date.prototype.getDate);varLt=d.bind(Date.prototype.getUTCFullYear);varXt=d.bind(Date.prototype.getUTCMonth);varqt=d.bind(Date.prototype.getUTCDate);varKt=d.bind(Date.prototype.getUTCDay);varQt=d.bind(Date.prototype.getUTCHours);varVt=d.bind(Date.prototype.getUTCMinutes);var_t=d.bind(Date.prototype.getUTCSeconds);vartr=d.bind(Date.prototype.getUTCMilliseconds);varrr=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"];varer=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];varnr=functiondaysInMonth(t,r){returnWt(newDate(r,t,0))};$(Date.prototype,{getFullYear:functiongetFullYear(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Bt(this);if(t<0&&Ht(this)>11){returnt+1}returnt},getMonth:functiongetMonth(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Bt(this);varr=Ht(this);if(t<0&&r>11){return0}returnr},getDate:functiongetDate(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Bt(this);varr=Ht(this);vare=Wt(this);if(t<0&&r>11){if(r===12){returne}varn=nr(0,t+1);returnn-e+1}returne},getUTCFullYear:functiongetUTCFullYear(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Lt(this);if(t<0&&Xt(this)>11){returnt+1}returnt},getUTCMonth:functiongetUTCMonth(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Lt(this);varr=Xt(this);if(t<0&&r>11){return0}returnr},getUTCDate:functiongetUTCDate(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Lt(this);varr=Xt(this);vare=qt(this);if(t<0&&r>11){if(r===12){returne}varn=nr(0,t+1);returnn-e+1}returne}},Pt);$(Date.prototype,{toUTCString:functiontoUTCString(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Kt(this);varr=qt(this);vare=Xt(this);varn=Lt(this);vari=Qt(this);vara=Vt(this);varo=_t(this);returnrr[t]+", "+(r<10?"0"+r:r)+" "+er[e]+" "+n+" "+(i<10?"0"+i:i)+":"+(a<10?"0"+a:a)+":"+(o<10?"0"+o:o)+" GMT"}},Pt||Yt);$(Date.prototype,{toDateString:functiontoDateString(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=this.getDay();varr=this.getDate();vare=this.getMonth();varn=this.getFullYear();returnrr[t]+" "+er[e]+" "+(r<10?"0"+r:r)+" "+n}},Pt||Zt);if(Pt||zt){Date.prototype.toString=functiontoString(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=this.getDay();varr=this.getDate();vare=this.getMonth();varn=this.getFullYear();vari=this.getHours();vara=this.getMinutes();varo=this.getSeconds();varf=this.getTimezoneOffset();varu=Math.floor(Math.abs(f)/60);varl=Math.floor(Math.abs(f)%60);returnrr[t]+" "+er[e]+" "+(r<10?"0"+r:r)+" "+n+" "+(i<10?"0"+i:i)+":"+(a<10?"0"+a:a)+":"+(o<10?"0"+o:o)+" GMT"+(f>0?"-":"+")+(u<10?"0"+u:u)+(l<10?"0"+l:l)};if(P){e.defineProperty(Date.prototype,"toString",{configurable:true,enumerable:false,writable:true})}}varir=-621987552e5;varar="-000001";varor=Date.prototype.toISOString&&newDate(ir).toISOString().indexOf(ar)===-1;varfr=Date.prototype.toISOString&&newDate(-1).toISOString()!=="1969-12-31T23:59:59.999Z";varur=d.bind(Date.prototype.getTime);$(Date.prototype,{toISOString:functiontoISOString(){if(!isFinite(this)||!isFinite(ur(this))){thrownewRangeError("Date.prototype.toISOString called on non-finite value.")}vart=Lt(this);varr=Xt(this);t+=Math.floor(r/12);r=(r%12+12)%12;vare=[r+1,qt(this),Qt(this),Vt(this),_t(this)];t=(t<0?"-":t>9999?"+":"")+L("00000"+Math.abs(t),0<=t&&t<=9999?-4:-6);for(varn=0;n<e.length;++n){e[n]=L("00"+e[n],-2)}returnt+"-"+H(e,0,2).join("-")+"T"+H(e,2).join(":")+"."+L("000"+tr(this),-3)+"Z"}},or||fr);varlr=function(){try{returnDate.prototype.toJSON&&newDate(NaN).toJSON()===null&&newDate(ir).toJSON().indexOf(ar)!==-1&&Date.prototype.toJSON.call({toISOString:function(){returntrue}})}catch(t){returnfalse}}();if(!lr){Date.prototype.toJSON=functiontoJSON(t){varr=e(this);varn=Z.ToPrimitive(r);if(typeofn==="number"&&!isFinite(n)){returnnull}vari=r.toISOString;if(!D(i)){thrownewTypeError("toISOString property is not callable")}returni.call(r)}}varsr=Date.parse("+033658-09-27T01:46:40.000Z")===1e15;varcr=!isNaN(Date.parse("2012-04-04T24:00:00.500Z"))||!isNaN(Date.parse("2012-11-31T23:59:59.000Z"))||!isNaN(Date.parse("2012-12-31T23:59:60.000Z"));varvr=isNaN(Date.parse("2000-01-01T00:00:00.000Z"));if(vr||cr||!sr){varhr=Math.pow(2,31)-1;varpr=Y(newDate(1970,0,1,0,0,0,hr+1).getTime());Date=function(t){varr=functionDate(e,n,i,a,f,u,l){vars=arguments.length;varc;if(thisinstanceoft){varv=u;varh=l;if(pr&&s>=7&&l>hr){varp=Math.floor(l/hr)*hr;vary=Math.floor(p/1e3);v+=y;h-=y*1e3}c=s===1&&o(e)===e?newt(r.parse(e)):s>=7?newt(e,n,i,a,f,v,h):s>=6?newt(e,n,i,a,f,v):s>=5?newt(e,n,i,a,f):s>=4?newt(e,n,i,a):s>=3?newt(e,n,i):s>=2?newt(e,n):s>=1?newt(einstanceoft?+e:e):newt}else{c=t.apply(this,arguments)}if(!J(c)){$(c,{constructor:r},true)}returnc};vare=newRegExp("^"+"(\\d{4}|[+-]\\d{6})"+"(?:-(\\d{2})"+"(?:-(\\d{2})"+"(?:"+"T(\\d{2})"+":(\\d{2})"+"(?:"+":(\\d{2})"+"(?:(\\.\\d{1,}))?"+")?"+"("+"Z|"+"(?:"+"([-+])"+"(\\d{2})"+":(\\d{2})"+")"+")?)?)?)?"+"$");varn=[0,31,59,90,120,151,181,212,243,273,304,334,365];vari=functiondayFromMonth(t,r){vare=r>1?1:0;returnn[r]+Math.floor((t-1969+e)/4)-Math.floor((t-1901+e)/100)+Math.floor((t-1601+e)/400)+365*(t-1970)};vara=functiontoUTC(r){vare=0;varn=r;if(pr&&n>hr){vari=Math.floor(n/hr)*hr;vara=Math.floor(i/1e3);e+=a;n-=a*1e3}returnu(newt(1970,0,1,0,0,e,n))};for(varfint){if(G(t,f)){r[f]=t[f]}}$(r,{now:t.now,UTC:t.UTC},true);r.prototype=t.prototype;$(r.prototype,{constructor:r},true);varl=functionparse(r){varn=e.exec(r);if(n){varo=u(n[1]),f=u(n[2]||1)-1,l=u(n[3]||1)-1,s=u(n[4]||0),c=u(n[5]||0),v=u(n[6]||0),h=Math.floor(u(n[7]||0)*1e3),p=Boolean(n[4]&&!n[8]),y=n[9]==="-"?1:-1,d=u(n[10]||0),g=u(n[11]||0),w;varb=c>0||v>0||h>0;if(s<(b?24:25)&&c<60&&v<60&&h<1e3&&f>-1&&f<12&&d<24&&g<60&&l>-1&&l<i(o,f+1)-i(o,f)){w=((i(o,f)+l)*24+s+d*y)*60;w=((w+c+g*y)*60+v)*1e3+h;if(p){w=a(w)}if(-864e13<=w&&w<=864e13){returnw}}returnNaN}returnt.parse.apply(this,arguments)};$(r,{parse:l});returnr}(Date)}if(!Date.now){Date.now=functionnow(){return(newDate).getTime()}}varyr=l.toFixed&&(8e-5.toFixed(3)!=="0.000"||.9.toFixed(0)!=="1"||1.255.toFixed(2)!=="1.25"||0xde0b6b3a7640080.toFixed(0)!=="1000000000000000128");vardr={base:1e7,size:6,data:[0,0,0,0,0,0],multiply:functionmultiply(t,r){vare=-1;varn=r;while(++e<dr.size){n+=t*dr.data[e];dr.data[e]=n%dr.base;n=Math.floor(n/dr.base)}},divide:functiondivide(t){varr=dr.size;vare=0;while(--r>=0){e+=dr.data[r];dr.data[r]=Math.floor(e/t);e=e%t*dr.base}},numToString:functionnumToString(){vart=dr.size;varr="";while(--t>=0){if(r!==""||t===0||dr.data[t]!==0){vare=o(dr.data[t]);if(r===""){r=e}else{r+=L("0000000",0,7-e.length)+e}}}returnr},pow:functionpow(t,r,e){returnr===0?e:r%2===1?pow(t,r-1,e*t):pow(t*t,r/2,e)},log:functionlog(t){varr=0;vare=t;while(e>=4096){r+=12;e/=4096}while(e>=2){r+=1;e/=2}returnr}};vargr=functiontoFixed(t){varr,e,n,i,a,f,l,s;r=u(t);r=Y(r)?0:Math.floor(r);if(r<0||r>20){thrownewRangeError("Number.toFixed called with invalid number of decimals")}e=u(this);if(Y(e)){return"NaN"}if(e<=-1e21||e>=1e21){returno(e)}n="";if(e<0){n="-";e=-e}i="0";if(e>1e-21){a=dr.log(e*dr.pow(2,69,1))-69;f=a<0?e*dr.pow(2,-a,1):e/dr.pow(2,a,1);f*=4503599627370496;a=52-a;if(a>0){dr.multiply(0,f);l=r;while(l>=7){dr.multiply(1e7,0);l-=7}dr.multiply(dr.pow(10,l,1),0);l=a-1;while(l>=23){dr.divide(1<<23);l-=23}dr.divide(1<<l);dr.multiply(1,1);dr.divide(2);i=dr.numToString()}else{dr.multiply(0,f);dr.multiply(1<<-a,0);i=dr.numToString()+L("0.00000000000000000000",2,2+r)}}if(r>0){s=i.length;if(s<=r){i=n+L("0.0000000000000000000",0,r-s+2)+i}else{i=n+L(i,0,s-r)+"."+L(i,s-r)}}else{i=n+i}returni};$(l,{toFixed:gr},yr);varwr=function(){try{return1..toPrecision(undefined)==="1"}catch(t){returntrue}}();varbr=l.toPrecision;$(l,{toPrecision:functiontoPrecision(t){returntypeoft==="undefined"?br.call(this):br.call(this,t)}},wr);if("ab".split(/(?:ab)*/).length!==2||".".split(/(.?)(.?)/).length!==4||"tesst".split(/(s)*/)[1]==="t"||"test".split(/(?:)/,-1).length!==4||"".split(/.?/).length||".".split(/()()/).length>1){(function(){vart=typeof/()??/.exec("")[1]==="undefined";varr=Math.pow(2,32)-1;f.split=function(e,n){vari=String(this);if(typeofe==="undefined"&&n===0){return[]}if(!M(e)){returnX(this,e,n)}vara=[];varo=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),f=0,u,l,s,c;varh=newRegExp(e.source,o+"g");if(!t){u=newRegExp("^"+h.source+"$(?!\\s)",o)}varp=typeofn==="undefined"?r:Z.ToUint32(n);l=h.exec(i);while(l){s=l.index+l[0].length;if(s>f){K(a,L(i,f,l.index));if(!t&&l.length>1){l[0].replace(u,function(){for(vart=1;t<arguments.length-2;t++){if(typeofarguments[t]==="undefined"){l[t]=void0}}})}if(l.length>1&&l.index<i.length){v.apply(a,H(l,1))}c=l[0].length;f=s;if(a.length>=p){break}}if(h.lastIndex===l.index){h.lastIndex++}l=h.exec(i)}if(f===i.length){if(c||!h.test("")){K(a,"")}}else{K(a,L(i,f))}returna.length>p?H(a,0,p):a}})()}elseif("0".split(void0,0).length){f.split=functionsplit(t,r){if(typeoft==="undefined"&&r===0){return[]}returnX(this,t,r)}}varTr=f.replace;varmr=function(){vart=[];"x".replace(/x(.)?/g,function(r,e){K(t,e)});returnt.length===1&&typeoft[0]==="undefined"}();if(!mr){f.replace=functionreplace(t,r){vare=D(r);varn=M(t)&&/\)[*?]/.test(t.source);if(!e||!n){returnTr.call(this,t,r)}else{vari=function(e){varn=arguments.length;vari=t.lastIndex;t.lastIndex=0;vara=t.exec(e)||[];t.lastIndex=i;K(a,arguments[n-2],arguments[n-1]);returnr.apply(this,a)};returnTr.call(this,t,i)}}}varDr=f.substr;varxr="".substr&&"0b".substr(-1)!=="b";$(f,{substr:functionsubstr(t,r){vare=t;if(t<0){e=w(this.length+t,0)}returnDr.call(this,e,r)}},xr);varSr=" \n\x0B\f\r \xa0\u1680\u180e\u2000\u2001\u2002\u2003"+"\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028"+"\u2029\ufeff";varOr="\u200b";varEr="["+Sr+"]";varjr=newRegExp("^"+Er+Er+"*");varIr=newRegExp(Er+Er+"*$");varMr=f.trim&&(Sr.trim()||!Or.trim());$(f,{trim:functiontrim(){if(typeofthis==="undefined"||this===null){thrownewTypeError("can't convert "+this+" to object")}returno(this).replace(jr,"").replace(Ir,"")}},Mr);varUr=d.bind(String.prototype.trim);varFr=f.lastIndexOf&&"abc\u3042\u3044".lastIndexOf("\u3042\u3044",2)!==-1;$(f,{lastIndexOf:functionlastIndexOf(t){if(typeofthis==="undefined"||this===null){thrownewTypeError("can't convert "+this+" to object")}varr=o(this);vare=o(t);varn=arguments.length>1?u(arguments[1]):NaN;vari=Y(n)?Infinity:Z.ToInteger(n);vara=b(w(i,0),r.length);varf=e.length;varl=a+f;while(l>0){l=w(0,l-f);vars=q(L(r,l,a+f),e);if(s!==-1){returnl+s}}return-1}},Fr);varNr=f.lastIndexOf;$(f,{lastIndexOf:functionlastIndexOf(t){returnNr.apply(this,arguments)}},f.lastIndexOf.length!==1);if(parseInt(Sr+"08")!==8||parseInt(Sr+"0x16")!==22){parseInt=function(t){varr=/^[\-+]?0[xX]/;returnfunctionparseInt(e,n){vari=Ur(e);vara=u(n)||(r.test(i)?16:10);returnt(i,a)}}(parseInt)}if(1/parseFloat("-0")!==-Infinity){parseFloat=function(t){returnfunctionparseFloat(r){vare=Ur(r);varn=t(e);returnn===0&&L(e,0,1)==="-"?-0:n}}(parseFloat)}if(String(newRangeError("test"))!=="RangeError: test"){varCr=functiontoString(){if(typeofthis==="undefined"||this===null){thrownewTypeError("can't convert "+this+" to object")}vart=this.name;if(typeoft==="undefined"){t="Error"}elseif(typeoft!=="string"){t=o(t)}varr=this.message;if(typeofr==="undefined"){r=""}elseif(typeofr!=="string"){r=o(r)}if(!t){returnr}if(!r){returnt}returnt+": "+r};Error.prototype.toString=Cr}if(P){varkr=function(t,r){if(Q(t,r)){vare=Object.getOwnPropertyDescriptor(t,r);e.enumerable=false;Object.defineProperty(t,r,e)}};kr(Error.prototype,"message");if(Error.prototype.message!==""){Error.prototype.message=""}kr(Error.prototype,"name")}if(String(/a/gim)!=="/a/gim"){varRr=functiontoString(){vart="/"+this.source+"/";if(this.global){t+="g"}if(this.ignoreCase){t+="i"}if(this.multiline){t+="m"}returnt};RegExp.prototype.toString=Rr}});
//# sourceMappingURL=es5-shim.map
/*!
* https://github.com/es-shims/es5-shim
* @license es5-shim Copyright 2009-2015 by contributors, MIT License
* see https://github.com/es-shims/es5-shim/blob/v4.5.7/LICENSE
*/
(function(t,r){"use strict";if(typeofdefine==="function"&&define.amd){define(r)}elseif(typeofexports==="object"){module.exports=r()}else{t.returnExports=r()}})(this,function(){vart=Array;varr=t.prototype;vare=Object;varn=e.prototype;vari=Function;vara=i.prototype;varo=String;varf=o.prototype;varu=Number;varl=u.prototype;vars=r.slice;varc=r.splice;varv=r.push;varh=r.unshift;varp=r.concat;vary=r.join;vard=a.call;varg=a.apply;varw=Math.max;varb=Math.min;varT=n.toString;varm=typeofSymbol==="function"&&typeofSymbol.toStringTag==="symbol";varD;varx=Function.prototype.toString,S=/^\s*class /,O=functionisES6ClassFn(t){try{varr=x.call(t);vare=r.replace(/\/\/.*\n/g,"");varn=e.replace(/\/\*[.\s\S]*\*\//g,"");vari=n.replace(/\n/gm," ").replace(/ {2}/g," ");returnS.test(i)}catch(a){returnfalse}},E=functiontryFunctionObject(t){try{if(O(t)){returnfalse}x.call(t);returntrue}catch(r){returnfalse}},j="[object Function]",I="[object GeneratorFunction]",D=functionisCallable(t){if(!t){returnfalse}if(typeoft!=="function"&&typeoft!=="object"){returnfalse}if(m){returnE(t)}if(O(t)){returnfalse}varr=T.call(t);returnr===j||r===I};varM;varU=RegExp.prototype.exec,F=functiontryRegexExec(t){try{U.call(t);returntrue}catch(r){returnfalse}},N="[object RegExp]";M=functionisRegex(t){if(typeoft!=="object"){returnfalse}returnm?F(t):T.call(t)===N};varC;vark=String.prototype.valueOf,R=functiontryStringObject(t){try{k.call(t);returntrue}catch(r){returnfalse}},A="[object String]";C=functionisString(t){if(typeoft==="string"){returntrue}if(typeoft!=="object"){returnfalse}returnm?R(t):T.call(t)===A};varP=e.defineProperty&&function(){try{vart={};e.defineProperty(t,"x",{enumerable:false,value:t});for(varrint){returnfalse}returnt.x===t}catch(n){returnfalse}}();var$=function(t){varr;if(P){r=function(t,r,n,i){if(!i&&rint){return}e.defineProperty(t,r,{configurable:true,enumerable:false,writable:true,value:n})}}else{r=function(t,r,e,n){if(!n&&rint){return}t[r]=e}}returnfunctiondefineProperties(e,n,i){for(varainn){if(t.call(n,a)){r(e,a,n[a],i)}}}}(n.hasOwnProperty);varJ=functionisPrimitive(t){varr=typeoft;returnt===null||r!=="object"&&r!=="function"};varY=u.isNaN||function(t){returnt!==t};varZ={ToInteger:functionToInteger(t){varr=+t;if(Y(r)){r=0}elseif(r!==0&&r!==1/0&&r!==-(1/0)){r=(r>0||-1)*Math.floor(Math.abs(r))}returnr},ToPrimitive:functionToPrimitive(t){varr,e,n;if(J(t)){returnt}e=t.valueOf;if(D(e)){r=e.call(t);if(J(r)){returnr}}n=t.toString;if(D(n)){r=n.call(t);if(J(r)){returnr}}thrownewTypeError},ToObject:function(t){if(t==null){thrownewTypeError("can't convert "+t+" to object")}returne(t)},ToUint32:functionToUint32(t){returnt>>>0}};varz=functionEmpty(){};$(a,{bind:functionbind(t){varr=this;if(!D(r)){thrownewTypeError("Function.prototype.bind called on incompatible "+r)}varn=s.call(arguments,1);vara;varo=function(){if(thisinstanceofa){vari=g.call(r,this,p.call(n,s.call(arguments)));if(e(i)===i){returni}returnthis}else{returng.call(r,t,p.call(n,s.call(arguments)))}};varf=w(0,r.length-n.length);varu=[];for(varl=0;l<f;l++){v.call(u,"$"+l)}a=i("binder","return function ("+y.call(u,",")+"){ return binder.apply(this, arguments); }")(o);if(r.prototype){z.prototype=r.prototype;a.prototype=newz;z.prototype=null}returna}});varG=d.bind(n.hasOwnProperty);varB=d.bind(n.toString);varH=d.bind(s);varW=g.bind(s);varL=d.bind(f.slice);varX=d.bind(f.split);varq=d.bind(f.indexOf);varK=d.bind(v);varQ=d.bind(n.propertyIsEnumerable);varV=d.bind(r.sort);var_=t.isArray||functionisArray(t){returnB(t)==="[object Array]"};vartt=[].unshift(0)!==1;$(r,{unshift:function(){h.apply(this,arguments);returnthis.length}},tt);$(t,{isArray:_});varrt=e("a");varet=rt[0]!=="a"||!(0inrt);varnt=functionproperlyBoxed(t){varr=true;vare=true;varn=false;if(t){try{t.call("foo",function(t,e,n){if(typeofn!=="object"){r=false}});t.call([1],function(){"use strict";e=typeofthis==="string"},"x")}catch(i){n=true}}return!!t&&!n&&r&&e};$(r,{forEach:functionforEach(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=-1;vari=Z.ToUint32(e.length);vara;if(arguments.length>1){a=arguments[1]}if(!D(t)){thrownewTypeError("Array.prototype.forEach callback must be a function")}while(++n<i){if(nine){if(typeofa==="undefined"){t(e[n],n,r)}else{t.call(a,e[n],n,r)}}}}},!nt(r.forEach));$(r,{map:functionmap(r){vare=Z.ToObject(this);varn=et&&C(this)?X(this,""):e;vari=Z.ToUint32(n.length);vara=t(i);varo;if(arguments.length>1){o=arguments[1]}if(!D(r)){thrownewTypeError("Array.prototype.map callback must be a function")}for(varf=0;f<i;f++){if(finn){if(typeofo==="undefined"){a[f]=r(n[f],f,e)}else{a[f]=r.call(o,n[f],f,e)}}}returna}},!nt(r.map));$(r,{filter:functionfilter(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);vari=[];vara;varo;if(arguments.length>1){o=arguments[1]}if(!D(t)){thrownewTypeError("Array.prototype.filter callback must be a function")}for(varf=0;f<n;f++){if(fine){a=e[f];if(typeofo==="undefined"?t(a,f,r):t.call(o,a,f,r)){K(i,a)}}}returni}},!nt(r.filter));$(r,{every:functionevery(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);vari;if(arguments.length>1){i=arguments[1]}if(!D(t)){thrownewTypeError("Array.prototype.every callback must be a function")}for(vara=0;a<n;a++){if(aine&&!(typeofi==="undefined"?t(e[a],a,r):t.call(i,e[a],a,r))){returnfalse}}returntrue}},!nt(r.every));$(r,{some:functionsome(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);vari;if(arguments.length>1){i=arguments[1]}if(!D(t)){thrownewTypeError("Array.prototype.some callback must be a function")}for(vara=0;a<n;a++){if(aine&&(typeofi==="undefined"?t(e[a],a,r):t.call(i,e[a],a,r))){returntrue}}returnfalse}},!nt(r.some));varit=false;if(r.reduce){it=typeofr.reduce.call("es5",function(t,r,e,n){returnn})==="object"}$(r,{reduce:functionreduce(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);if(!D(t)){thrownewTypeError("Array.prototype.reduce callback must be a function")}if(n===0&&arguments.length===1){thrownewTypeError("reduce of empty array with no initial value")}vari=0;vara;if(arguments.length>=2){a=arguments[1]}else{do{if(iine){a=e[i++];break}if(++i>=n){thrownewTypeError("reduce of empty array with no initial value")}}while(true)}for(;i<n;i++){if(iine){a=t(a,e[i],i,r)}}returna}},!it);varat=false;if(r.reduceRight){at=typeofr.reduceRight.call("es5",function(t,r,e,n){returnn})==="object"}$(r,{reduceRight:functionreduceRight(t){varr=Z.ToObject(this);vare=et&&C(this)?X(this,""):r;varn=Z.ToUint32(e.length);if(!D(t)){thrownewTypeError("Array.prototype.reduceRight callback must be a function")}if(n===0&&arguments.length===1){thrownewTypeError("reduceRight of empty array with no initial value")}vari;vara=n-1;if(arguments.length>=2){i=arguments[1]}else{do{if(aine){i=e[a--];break}if(--a<0){thrownewTypeError("reduceRight of empty array with no initial value")}}while(true)}if(a<0){returni}do{if(aine){i=t(i,e[a],a,r)}}while(a--);returni}},!at);varot=r.indexOf&&[0,1].indexOf(1,2)!==-1;$(r,{indexOf:functionindexOf(t){varr=et&&C(this)?X(this,""):Z.ToObject(this);vare=Z.ToUint32(r.length);if(e===0){return-1}varn=0;if(arguments.length>1){n=Z.ToInteger(arguments[1])}n=n>=0?n:w(0,e+n);for(;n<e;n++){if(ninr&&r[n]===t){returnn}}return-1}},ot);varft=r.lastIndexOf&&[0,1].lastIndexOf(0,-3)!==-1;$(r,{lastIndexOf:functionlastIndexOf(t){varr=et&&C(this)?X(this,""):Z.ToObject(this);vare=Z.ToUint32(r.length);if(e===0){return-1}varn=e-1;if(arguments.length>1){n=b(n,Z.ToInteger(arguments[1]))}n=n>=0?n:e-Math.abs(n);for(;n>=0;n--){if(ninr&&t===r[n]){returnn}}return-1}},ft);varut=function(){vart=[1,2];varr=t.splice();returnt.length===2&&_(r)&&r.length===0}();$(r,{splice:functionsplice(t,r){if(arguments.length===0){return[]}else{returnc.apply(this,arguments)}}},!ut);varlt=function(){vart={};r.splice.call(t,0,0,1);returnt.length===1}();$(r,{splice:functionsplice(t,r){if(arguments.length===0){return[]}vare=arguments;this.length=w(Z.ToInteger(this.length),0);if(arguments.length>0&&typeofr!=="number"){e=H(arguments);if(e.length<2){K(e,this.length-t)}else{e[1]=Z.ToInteger(r)}}returnc.apply(this,e)}},!lt);varst=function(){varr=newt(1e5);r[8]="x";r.splice(1,1);returnr.indexOf("x")===7}();varct=function(){vart=256;varr=[];r[t]="a";r.splice(t+1,0,"b");returnr[t]==="a"}();$(r,{splice:functionsplice(t,r){vare=Z.ToObject(this);varn=[];vari=Z.ToUint32(e.length);vara=Z.ToInteger(t);varf=a<0?w(i+a,0):b(a,i);varu=b(w(Z.ToInteger(r),0),i-f);varl=0;vars;while(l<u){s=o(f+l);if(G(e,s)){n[l]=e[s]}l+=1}varc=H(arguments,2);varv=c.length;varh;if(v<u){l=f;varp=i-u;while(l<p){s=o(l+u);h=o(l+v);if(G(e,s)){e[h]=e[s]}else{deletee[h]}l+=1}l=i;vary=i-u+v;while(l>y){deletee[l-1];l-=1}}elseif(v>u){l=i-u;while(l>f){s=o(l+u-1);h=o(l+v-1);if(G(e,s)){e[h]=e[s]}else{deletee[h]}l-=1}}l=f;for(vard=0;d<c.length;++d){e[l]=c[d];l+=1}e.length=i-u+v;returnn}},!st||!ct);varvt=r.join;varht;try{ht=Array.prototype.join.call("123",",")!=="1,2,3"}catch(pt){ht=true}if(ht){$(r,{join:functionjoin(t){varr=typeoft==="undefined"?",":t;returnvt.call(C(this)?X(this,""):this,r)}},ht)}varyt=[1,2].join(undefined)!=="1,2";if(yt){$(r,{join:functionjoin(t){varr=typeoft==="undefined"?",":t;returnvt.call(this,r)}},yt)}vardt=functionpush(t){varr=Z.ToObject(this);vare=Z.ToUint32(r.length);varn=0;while(n<arguments.length){r[e+n]=arguments[n];n+=1}r.length=e+n;returne+n};vargt=function(){vart={};varr=Array.prototype.push.call(t,undefined);returnr!==1||t.length!==1||typeoft[0]!=="undefined"||!G(t,0)}();$(r,{push:functionpush(t){if(_(this)){returnv.apply(this,arguments)}returndt.apply(this,arguments)}},gt);varwt=function(){vart=[];varr=t.push(undefined);returnr!==1||t.length!==1||typeoft[0]!=="undefined"||!G(t,0)}();$(r,{push:dt},wt);$(r,{slice:function(t,r){vare=C(this)?X(this,""):this;returnW(e,arguments)}},et);varbt=function(){try{[1,2].sort(null);[1,2].sort({});returntrue}catch(t){}returnfalse}();varTt=function(){try{[1,2].sort(/a/);returnfalse}catch(t){}returntrue}();varmt=function(){try{[1,2].sort(undefined);returntrue}catch(t){}returnfalse}();$(r,{sort:functionsort(t){if(typeoft==="undefined"){returnV(this)}if(!D(t)){thrownewTypeError("Array.prototype.sort callback must be a function")}returnV(this,t)}},bt||!mt||!Tt);varDt=!{toString:null}.propertyIsEnumerable("toString");varxt=function(){}.propertyIsEnumerable("prototype");varSt=!G("x","0");varOt=function(t){varr=t.constructor;returnr&&r.prototype===t};varEt={$window:true,$console:true,$parent:true,$self:true,$frame:true,$frames:true,$frameElement:true,$webkitIndexedDB:true,$webkitStorageInfo:true,$external:true};varjt=function(){if(typeofwindow==="undefined"){returnfalse}for(vartinwindow){try{if(!Et["$"+t]&&G(window,t)&&window[t]!==null&&typeofwindow[t]==="object"){Ot(window[t])}}catch(r){returntrue}}returnfalse}();varIt=function(t){if(typeofwindow==="undefined"||!jt){returnOt(t)}try{returnOt(t)}catch(r){returnfalse}};varMt=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];varUt=Mt.length;varFt=functionisArguments(t){returnB(t)==="[object Arguments]"};varNt=functionisArguments(t){returnt!==null&&typeoft==="object"&&typeoft.length==="number"&&t.length>=0&&!_(t)&&D(t.callee)};varCt=Ft(arguments)?Ft:Nt;$(e,{keys:functionkeys(t){varr=D(t);vare=Ct(t);varn=t!==null&&typeoft==="object";vari=n&&C(t);if(!n&&!r&&!e){thrownewTypeError("Object.keys called on a non-object")}vara=[];varf=xt&&r;if(i&&St||e){for(varu=0;u<t.length;++u){K(a,o(u))}}if(!e){for(varlint){if(!(f&&l==="prototype")&&G(t,l)){K(a,o(l))}}}if(Dt){vars=It(t);for(varc=0;c<Ut;c++){varv=Mt[c];if(!(s&&v==="constructor")&&G(t,v)){K(a,v)}}}returna}});varkt=e.keys&&function(){returne.keys(arguments).length===2}(1,2);varRt=e.keys&&function(){vart=e.keys(arguments);returnarguments.length!==1||t.length!==1||t[0]!==1}(1);varAt=e.keys;$(e,{keys:functionkeys(t){if(Ct(t)){returnAt(H(t))}else{returnAt(t)}}},!kt||Rt);varPt=newDate(-0xc782b5b342b24).getUTCMonth()!==0;var$t=newDate(-0x55d318d56a724);varJt=newDate(14496624e5);varYt=$t.toUTCString()!=="Mon, 01 Jan -45875 11:59:59 GMT";varZt;varzt;varGt=$t.getTimezoneOffset();if(Gt<-720){Zt=$t.toDateString()!=="Tue Jan 02 -45875";zt=!/^Thu Dec 10 2015 \d\d:\d\d:\d\d GMT[-\+]\d\d\d\d(?: |$)/.test(Jt.toString())}else{Zt=$t.toDateString()!=="Mon Jan 01 -45875";zt=!/^Wed Dec 09 2015 \d\d:\d\d:\d\d GMT[-\+]\d\d\d\d(?: |$)/.test(Jt.toString())}varBt=d.bind(Date.prototype.getFullYear);varHt=d.bind(Date.prototype.getMonth);varWt=d.bind(Date.prototype.getDate);varLt=d.bind(Date.prototype.getUTCFullYear);varXt=d.bind(Date.prototype.getUTCMonth);varqt=d.bind(Date.prototype.getUTCDate);varKt=d.bind(Date.prototype.getUTCDay);varQt=d.bind(Date.prototype.getUTCHours);varVt=d.bind(Date.prototype.getUTCMinutes);var_t=d.bind(Date.prototype.getUTCSeconds);vartr=d.bind(Date.prototype.getUTCMilliseconds);varrr=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"];varer=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];varnr=functiondaysInMonth(t,r){returnWt(newDate(r,t,0))};$(Date.prototype,{getFullYear:functiongetFullYear(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Bt(this);if(t<0&&Ht(this)>11){returnt+1}returnt},getMonth:functiongetMonth(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Bt(this);varr=Ht(this);if(t<0&&r>11){return0}returnr},getDate:functiongetDate(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Bt(this);varr=Ht(this);vare=Wt(this);if(t<0&&r>11){if(r===12){returne}varn=nr(0,t+1);returnn-e+1}returne},getUTCFullYear:functiongetUTCFullYear(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Lt(this);if(t<0&&Xt(this)>11){returnt+1}returnt},getUTCMonth:functiongetUTCMonth(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Lt(this);varr=Xt(this);if(t<0&&r>11){return0}returnr},getUTCDate:functiongetUTCDate(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Lt(this);varr=Xt(this);vare=qt(this);if(t<0&&r>11){if(r===12){returne}varn=nr(0,t+1);returnn-e+1}returne}},Pt);$(Date.prototype,{toUTCString:functiontoUTCString(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=Kt(this);varr=qt(this);vare=Xt(this);varn=Lt(this);vari=Qt(this);vara=Vt(this);varo=_t(this);returnrr[t]+", "+(r<10?"0"+r:r)+" "+er[e]+" "+n+" "+(i<10?"0"+i:i)+":"+(a<10?"0"+a:a)+":"+(o<10?"0"+o:o)+" GMT"}},Pt||Yt);$(Date.prototype,{toDateString:functiontoDateString(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=this.getDay();varr=this.getDate();vare=this.getMonth();varn=this.getFullYear();returnrr[t]+" "+er[e]+" "+(r<10?"0"+r:r)+" "+n}},Pt||Zt);if(Pt||zt){Date.prototype.toString=functiontoString(){if(!this||!(thisinstanceofDate)){thrownewTypeError("this is not a Date object.")}vart=this.getDay();varr=this.getDate();vare=this.getMonth();varn=this.getFullYear();vari=this.getHours();vara=this.getMinutes();varo=this.getSeconds();varf=this.getTimezoneOffset();varu=Math.floor(Math.abs(f)/60);varl=Math.floor(Math.abs(f)%60);returnrr[t]+" "+er[e]+" "+(r<10?"0"+r:r)+" "+n+" "+(i<10?"0"+i:i)+":"+(a<10?"0"+a:a)+":"+(o<10?"0"+o:o)+" GMT"+(f>0?"-":"+")+(u<10?"0"+u:u)+(l<10?"0"+l:l)};if(P){e.defineProperty(Date.prototype,"toString",{configurable:true,enumerable:false,writable:true})}}varir=-621987552e5;varar="-000001";varor=Date.prototype.toISOString&&newDate(ir).toISOString().indexOf(ar)===-1;varfr=Date.prototype.toISOString&&newDate(-1).toISOString()!=="1969-12-31T23:59:59.999Z";varur=d.bind(Date.prototype.getTime);$(Date.prototype,{toISOString:functiontoISOString(){if(!isFinite(this)||!isFinite(ur(this))){thrownewRangeError("Date.prototype.toISOString called on non-finite value.")}vart=Lt(this);varr=Xt(this);t+=Math.floor(r/12);r=(r%12+12)%12;vare=[r+1,qt(this),Qt(this),Vt(this),_t(this)];t=(t<0?"-":t>9999?"+":"")+L("00000"+Math.abs(t),0<=t&&t<=9999?-4:-6);for(varn=0;n<e.length;++n){e[n]=L("00"+e[n],-2)}returnt+"-"+H(e,0,2).join("-")+"T"+H(e,2).join(":")+"."+L("000"+tr(this),-3)+"Z"}},or||fr);varlr=function(){try{returnDate.prototype.toJSON&&newDate(NaN).toJSON()===null&&newDate(ir).toJSON().indexOf(ar)!==-1&&Date.prototype.toJSON.call({toISOString:function(){returntrue}})}catch(t){returnfalse}}();if(!lr){Date.prototype.toJSON=functiontoJSON(t){varr=e(this);varn=Z.ToPrimitive(r);if(typeofn==="number"&&!isFinite(n)){returnnull}vari=r.toISOString;if(!D(i)){thrownewTypeError("toISOString property is not callable")}returni.call(r)}}varsr=Date.parse("+033658-09-27T01:46:40.000Z")===1e15;varcr=!isNaN(Date.parse("2012-04-04T24:00:00.500Z"))||!isNaN(Date.parse("2012-11-31T23:59:59.000Z"))||!isNaN(Date.parse("2012-12-31T23:59:60.000Z"));varvr=isNaN(Date.parse("2000-01-01T00:00:00.000Z"));if(vr||cr||!sr){varhr=Math.pow(2,31)-1;varpr=Y(newDate(1970,0,1,0,0,0,hr+1).getTime());Date=function(t){varr=functionDate(e,n,i,a,f,u,l){vars=arguments.length;varc;if(thisinstanceoft){varv=u;varh=l;if(pr&&s>=7&&l>hr){varp=Math.floor(l/hr)*hr;vary=Math.floor(p/1e3);v+=y;h-=y*1e3}c=s===1&&o(e)===e?newt(r.parse(e)):s>=7?newt(e,n,i,a,f,v,h):s>=6?newt(e,n,i,a,f,v):s>=5?newt(e,n,i,a,f):s>=4?newt(e,n,i,a):s>=3?newt(e,n,i):s>=2?newt(e,n):s>=1?newt(einstanceoft?+e:e):newt}else{c=t.apply(this,arguments)}if(!J(c)){$(c,{constructor:r},true)}returnc};vare=newRegExp("^"+"(\\d{4}|[+-]\\d{6})"+"(?:-(\\d{2})"+"(?:-(\\d{2})"+"(?:"+"T(\\d{2})"+":(\\d{2})"+"(?:"+":(\\d{2})"+"(?:(\\.\\d{1,}))?"+")?"+"("+"Z|"+"(?:"+"([-+])"+"(\\d{2})"+":(\\d{2})"+")"+")?)?)?)?"+"$");varn=[0,31,59,90,120,151,181,212,243,273,304,334,365];vari=functiondayFromMonth(t,r){vare=r>1?1:0;returnn[r]+Math.floor((t-1969+e)/4)-Math.floor((t-1901+e)/100)+Math.floor((t-1601+e)/400)+365*(t-1970)};vara=functiontoUTC(r){vare=0;varn=r;if(pr&&n>hr){vari=Math.floor(n/hr)*hr;vara=Math.floor(i/1e3);e+=a;n-=a*1e3}returnu(newt(1970,0,1,0,0,e,n))};for(varfint){if(G(t,f)){r[f]=t[f]}}$(r,{now:t.now,UTC:t.UTC},true);r.prototype=t.prototype;$(r.prototype,{constructor:r},true);varl=functionparse(r){varn=e.exec(r);if(n){varo=u(n[1]),f=u(n[2]||1)-1,l=u(n[3]||1)-1,s=u(n[4]||0),c=u(n[5]||0),v=u(n[6]||0),h=Math.floor(u(n[7]||0)*1e3),p=Boolean(n[4]&&!n[8]),y=n[9]==="-"?1:-1,d=u(n[10]||0),g=u(n[11]||0),w;varb=c>0||v>0||h>0;if(s<(b?24:25)&&c<60&&v<60&&h<1e3&&f>-1&&f<12&&d<24&&g<60&&l>-1&&l<i(o,f+1)-i(o,f)){w=((i(o,f)+l)*24+s+d*y)*60;w=((w+c+g*y)*60+v)*1e3+h;if(p){w=a(w)}if(-864e13<=w&&w<=864e13){returnw}}returnNaN}returnt.parse.apply(this,arguments)};$(r,{parse:l});returnr}(Date)}if(!Date.now){Date.now=functionnow(){return(newDate).getTime()}}varyr=l.toFixed&&(8e-5.toFixed(3)!=="0.000"||.9.toFixed(0)!=="1"||1.255.toFixed(2)!=="1.25"||0xde0b6b3a7640080.toFixed(0)!=="1000000000000000128");vardr={base:1e7,size:6,data:[0,0,0,0,0,0],multiply:functionmultiply(t,r){vare=-1;varn=r;while(++e<dr.size){n+=t*dr.data[e];dr.data[e]=n%dr.base;n=Math.floor(n/dr.base)}},divide:functiondivide(t){varr=dr.size;vare=0;while(--r>=0){e+=dr.data[r];dr.data[r]=Math.floor(e/t);e=e%t*dr.base}},numToString:functionnumToString(){vart=dr.size;varr="";while(--t>=0){if(r!==""||t===0||dr.data[t]!==0){vare=o(dr.data[t]);if(r===""){r=e}else{r+=L("0000000",0,7-e.length)+e}}}returnr},pow:functionpow(t,r,e){returnr===0?e:r%2===1?pow(t,r-1,e*t):pow(t*t,r/2,e)},log:functionlog(t){varr=0;vare=t;while(e>=4096){r+=12;e/=4096}while(e>=2){r+=1;e/=2}returnr}};vargr=functiontoFixed(t){varr,e,n,i,a,f,l,s;r=u(t);r=Y(r)?0:Math.floor(r);if(r<0||r>20){thrownewRangeError("Number.toFixed called with invalid number of decimals")}e=u(this);if(Y(e)){return"NaN"}if(e<=-1e21||e>=1e21){returno(e)}n="";if(e<0){n="-";e=-e}i="0";if(e>1e-21){a=dr.log(e*dr.pow(2,69,1))-69;f=a<0?e*dr.pow(2,-a,1):e/dr.pow(2,a,1);f*=4503599627370496;a=52-a;if(a>0){dr.multiply(0,f);l=r;while(l>=7){dr.multiply(1e7,0);l-=7}dr.multiply(dr.pow(10,l,1),0);l=a-1;while(l>=23){dr.divide(1<<23);l-=23}dr.divide(1<<l);dr.multiply(1,1);dr.divide(2);i=dr.numToString()}else{dr.multiply(0,f);dr.multiply(1<<-a,0);i=dr.numToString()+L("0.00000000000000000000",2,2+r)}}if(r>0){s=i.length;if(s<=r){i=n+L("0.0000000000000000000",0,r-s+2)+i}else{i=n+L(i,0,s-r)+"."+L(i,s-r)}}else{i=n+i}returni};$(l,{toFixed:gr},yr);varwr=function(){try{return1..toPrecision(undefined)==="1"}catch(t){returntrue}}();varbr=l.toPrecision;$(l,{toPrecision:functiontoPrecision(t){returntypeoft==="undefined"?br.call(this):br.call(this,t)}},wr);if("ab".split(/(?:ab)*/).length!==2||".".split(/(.?)(.?)/).length!==4||"tesst".split(/(s)*/)[1]==="t"||"test".split(/(?:)/,-1).length!==4||"".split(/.?/).length||".".split(/()()/).length>1){(function(){vart=typeof/()??/.exec("")[1]==="undefined";varr=Math.pow(2,32)-1;f.split=function(e,n){vari=String(this);if(typeofe==="undefined"&&n===0){return[]}if(!M(e)){returnX(this,e,n)}vara=[];varo=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),f=0,u,l,s,c;varh=newRegExp(e.source,o+"g");if(!t){u=newRegExp("^"+h.source+"$(?!\\s)",o)}varp=typeofn==="undefined"?r:Z.ToUint32(n);l=h.exec(i);while(l){s=l.index+l[0].length;if(s>f){K(a,L(i,f,l.index));if(!t&&l.length>1){l[0].replace(u,function(){for(vart=1;t<arguments.length-2;t++){if(typeofarguments[t]==="undefined"){l[t]=void0}}})}if(l.length>1&&l.index<i.length){v.apply(a,H(l,1))}c=l[0].length;f=s;if(a.length>=p){break}}if(h.lastIndex===l.index){h.lastIndex++}l=h.exec(i)}if(f===i.length){if(c||!h.test("")){K(a,"")}}else{K(a,L(i,f))}returna.length>p?H(a,0,p):a}})()}elseif("0".split(void0,0).length){f.split=functionsplit(t,r){if(typeoft==="undefined"&&r===0){return[]}returnX(this,t,r)}}varTr=f.replace;varmr=function(){vart=[];"x".replace(/x(.)?/g,function(r,e){K(t,e)});returnt.length===1&&typeoft[0]==="undefined"}();if(!mr){f.replace=functionreplace(t,r){vare=D(r);varn=M(t)&&/\)[*?]/.test(t.source);if(!e||!n){returnTr.call(this,t,r)}else{vari=function(e){varn=arguments.length;vari=t.lastIndex;t.lastIndex=0;vara=t.exec(e)||[];t.lastIndex=i;K(a,arguments[n-2],arguments[n-1]);returnr.apply(this,a)};returnTr.call(this,t,i)}}}varDr=f.substr;varxr="".substr&&"0b".substr(-1)!=="b";$(f,{substr:functionsubstr(t,r){vare=t;if(t<0){e=w(this.length+t,0)}returnDr.call(this,e,r)}},xr);varSr=" \n\x0B\f\r \xa0\u1680\u180e\u2000\u2001\u2002\u2003"+"\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028"+"\u2029\ufeff";varOr="\u200b";varEr="["+Sr+"]";varjr=newRegExp("^"+Er+Er+"*");varIr=newRegExp(Er+Er+"*$");varMr=f.trim&&(Sr.trim()||!Or.trim());$(f,{trim:functiontrim(){if(typeofthis==="undefined"||this===null){thrownewTypeError("can't convert "+this+" to object")}returno(this).replace(jr,"").replace(Ir,"")}},Mr);varUr=d.bind(String.prototype.trim);varFr=f.lastIndexOf&&"abc\u3042\u3044".lastIndexOf("\u3042\u3044",2)!==-1;$(f,{lastIndexOf:functionlastIndexOf(t){if(typeofthis==="undefined"||this===null){thrownewTypeError("can't convert "+this+" to object")}varr=o(this);vare=o(t);varn=arguments.length>1?u(arguments[1]):NaN;vari=Y(n)?Infinity:Z.ToInteger(n);vara=b(w(i,0),r.length);varf=e.length;varl=a+f;while(l>0){l=w(0,l-f);vars=q(L(r,l,a+f),e);if(s!==-1){returnl+s}}return-1}},Fr);varNr=f.lastIndexOf;$(f,{lastIndexOf:functionlastIndexOf(t){returnNr.apply(this,arguments)}},f.lastIndexOf.length!==1);if(parseInt(Sr+"08")!==8||parseInt(Sr+"0x16")!==22){parseInt=function(t){varr=/^[\-+]?0[xX]/;returnfunctionparseInt(e,n){vari=Ur(e);vara=u(n)||(r.test(i)?16:10);returnt(i,a)}}(parseInt)}if(1/parseFloat("-0")!==-Infinity){parseFloat=function(t){returnfunctionparseFloat(r){vare=Ur(r);varn=t(e);returnn===0&&L(e,0,1)==="-"?-0:n}}(parseFloat)}if(String(newRangeError("test"))!=="RangeError: test"){varCr=functiontoString(){if(typeofthis==="undefined"||this===null){thrownewTypeError("can't convert "+this+" to object")}vart=this.name;if(typeoft==="undefined"){t="Error"}elseif(typeoft!=="string"){t=o(t)}varr=this.message;if(typeofr==="undefined"){r=""}elseif(typeofr!=="string"){r=o(r)}if(!t){returnr}if(!r){returnt}returnt+": "+r};Error.prototype.toString=Cr}if(P){varkr=function(t,r){if(Q(t,r)){vare=Object.getOwnPropertyDescriptor(t,r);e.enumerable=false;Object.defineProperty(t,r,e)}};kr(Error.prototype,"message");if(Error.prototype.message!==""){Error.prototype.message=""}kr(Error.prototype,"name")}if(String(/a/gim)!=="/a/gim"){varRr=functiontoString(){vart="/"+this.source+"/";if(this.global){t+="g"}if(this.ignoreCase){t+="i"}if(this.multiline){t+="m"}returnt};RegExp.prototype.toString=Rr}});