@prantlf/jsonlint 11.7.2 → 13.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/web/ajv.min.js CHANGED
@@ -1,4 +1,2 @@
1
- (function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Ajv=f()}})((function(){var define,module,exports;return function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,(function(r){var n=e[i][1][r];return o(n||r)}),p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i<t.length;i++)o(t[i]);return o}return r}()({1:[function(require,module,exports){"use strict";var Cache=module.exports=function Cache(){this._cache={}};Cache.prototype.put=function Cache_put(key,value){this._cache[key]=value};Cache.prototype.get=function Cache_get(key){return this._cache[key]};Cache.prototype.del=function Cache_del(key){delete this._cache[key]};Cache.prototype.clear=function Cache_clear(){this._cache={}}},{}],2:[function(require,module,exports){"use strict";var MissingRefError=require("./error_classes").MissingRef;module.exports=compileAsync;function compileAsync(schema,meta,callback){var self=this;if(typeof this._opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");if(typeof meta=="function"){callback=meta;meta=undefined}var p=loadMetaSchemaOf(schema).then((function(){var schemaObj=self._addSchema(schema,undefined,meta);return schemaObj.validate||_compileAsync(schemaObj)}));if(callback){p.then((function(v){callback(null,v)}),callback)}return p;function loadMetaSchemaOf(sch){var $schema=sch.$schema;return $schema&&!self.getSchema($schema)?compileAsync.call(self,{$ref:$schema},true):Promise.resolve()}function _compileAsync(schemaObj){try{return self._compile(schemaObj)}catch(e){if(e instanceof MissingRefError)return loadMissingSchema(e);throw e}function loadMissingSchema(e){var ref=e.missingSchema;if(added(ref))throw new Error("Schema "+ref+" is loaded but "+e.missingRef+" cannot be resolved");var schemaPromise=self._loadingSchemas[ref];if(!schemaPromise){schemaPromise=self._loadingSchemas[ref]=self._opts.loadSchema(ref);schemaPromise.then(removePromise,removePromise)}return schemaPromise.then((function(sch){if(!added(ref)){return loadMetaSchemaOf(sch).then((function(){if(!added(ref))self.addSchema(sch,ref,undefined,meta)}))}})).then((function(){return _compileAsync(schemaObj)}));function removePromise(){delete self._loadingSchemas[ref]}function added(ref){return self._refs[ref]||self._schemas[ref]}}}}},{"./error_classes":3}],3:[function(require,module,exports){"use strict";var resolve=require("./resolve");module.exports={Validation:errorSubclass(ValidationError),MissingRef:errorSubclass(MissingRefError)};function ValidationError(errors){this.message="validation failed";this.errors=errors;this.ajv=this.validation=true}MissingRefError.message=function(baseId,ref){return"can't resolve reference "+ref+" from id "+baseId};function MissingRefError(baseId,ref,message){this.message=message||MissingRefError.message(baseId,ref);this.missingRef=resolve.url(baseId,ref);this.missingSchema=resolve.normalizeId(resolve.fullPath(this.missingRef))}function errorSubclass(Subclass){Subclass.prototype=Object.create(Error.prototype);Subclass.prototype.constructor=Subclass;return Subclass}},{"./resolve":6}],4:[function(require,module,exports){"use strict";var util=require("./util");var DATE=/^(\d\d\d\d)-(\d\d)-(\d\d)$/;var DAYS=[0,31,28,31,30,31,30,31,31,30,31,30,31];var TIME=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i;var HOSTNAME=/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i;var URI=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;var URIREF=/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;var URITEMPLATE=/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i;var URL=/^(?:(?:http[s\u017F]?|ftp):\/\/)(?:(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+(?::(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?@)?(?:(?!10(?:\.[0-9]{1,3}){3})(?!127(?:\.[0-9]{1,3}){3})(?!169\.254(?:\.[0-9]{1,3}){2})(?!192\.168(?:\.[0-9]{1,3}){2})(?!172\.(?:1[6-9]|2[0-9]|3[01])(?:\.[0-9]{1,3}){2})(?:[1-9][0-9]?|1[0-9][0-9]|2[01][0-9]|22[0-3])(?:\.(?:1?[0-9]{1,2}|2[0-4][0-9]|25[0-5])){2}(?:\.(?:[1-9][0-9]?|1[0-9][0-9]|2[0-4][0-9]|25[0-4]))|(?:(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)(?:\.(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)*(?:\.(?:(?:[a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]){2,})))(?::[0-9]{2,5})?(?:\/(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?$/i;var UUID=/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i;var JSON_POINTER=/^(?:\/(?:[^~/]|~0|~1)*)*$/;var JSON_POINTER_URI_FRAGMENT=/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i;var RELATIVE_JSON_POINTER=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;module.exports=formats;function formats(mode){mode=mode=="full"?"full":"fast";return util.copy(formats[mode])}formats.fast={date:/^\d\d\d\d-[0-1]\d-[0-3]\d$/,time:/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,"date-time":/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,"uri-template":URITEMPLATE,url:URL,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i,hostname:HOSTNAME,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:regex,uuid:UUID,"json-pointer":JSON_POINTER,"json-pointer-uri-fragment":JSON_POINTER_URI_FRAGMENT,"relative-json-pointer":RELATIVE_JSON_POINTER};formats.full={date:date,time:time,"date-time":date_time,uri:uri,"uri-reference":URIREF,"uri-template":URITEMPLATE,url:URL,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:HOSTNAME,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:regex,uuid:UUID,"json-pointer":JSON_POINTER,"json-pointer-uri-fragment":JSON_POINTER_URI_FRAGMENT,"relative-json-pointer":RELATIVE_JSON_POINTER};function isLeapYear(year){return year%4===0&&(year%100!==0||year%400===0)}function date(str){var matches=str.match(DATE);if(!matches)return false;var year=+matches[1];var month=+matches[2];var day=+matches[3];return month>=1&&month<=12&&day>=1&&day<=(month==2&&isLeapYear(year)?29:DAYS[month])}function time(str,full){var matches=str.match(TIME);if(!matches)return false;var hour=matches[1];var minute=matches[2];var second=matches[3];var timeZone=matches[5];return(hour<=23&&minute<=59&&second<=59||hour==23&&minute==59&&second==60)&&(!full||timeZone)}var DATE_TIME_SEPARATOR=/t|\s/i;function date_time(str){var dateTime=str.split(DATE_TIME_SEPARATOR);return dateTime.length==2&&date(dateTime[0])&&time(dateTime[1],true)}var NOT_URI_FRAGMENT=/\/|:/;function uri(str){return NOT_URI_FRAGMENT.test(str)&&URI.test(str)}var Z_ANCHOR=/[^\\]\\Z/;function regex(str){if(Z_ANCHOR.test(str))return false;try{new RegExp(str);return true}catch(e){return false}}},{"./util":10}],5:[function(require,module,exports){"use strict";var resolve=require("./resolve"),util=require("./util"),errorClasses=require("./error_classes"),stableStringify=require("fast-json-stable-stringify");var validateGenerator=require("../dotjs/validate");var ucs2length=util.ucs2length;var equal=require("fast-deep-equal");var ValidationError=errorClasses.Validation;module.exports=compile;function compile(schema,root,localRefs,baseId){var self=this,opts=this._opts,refVal=[undefined],refs={},patterns=[],patternsHash={},defaults=[],defaultsHash={},customRules=[];root=root||{schema:schema,refVal:refVal,refs:refs};var c=checkCompiling.call(this,schema,root,baseId);var compilation=this._compilations[c.index];if(c.compiling)return compilation.callValidate=callValidate;var formats=this._formats;var RULES=this.RULES;try{var v=localCompile(schema,root,localRefs,baseId);compilation.validate=v;var cv=compilation.callValidate;if(cv){cv.schema=v.schema;cv.errors=null;cv.refs=v.refs;cv.refVal=v.refVal;cv.root=v.root;cv.$async=v.$async;if(opts.sourceCode)cv.source=v.source}return v}finally{endCompiling.call(this,schema,root,baseId)}function callValidate(){var validate=compilation.validate;var result=validate.apply(this,arguments);callValidate.errors=validate.errors;return result}function localCompile(_schema,_root,localRefs,baseId){var isRoot=!_root||_root&&_root.schema==_schema;if(_root.schema!=root.schema)return compile.call(self,_schema,_root,localRefs,baseId);var $async=_schema.$async===true;var sourceCode=validateGenerator({isTop:true,schema:_schema,isRoot:isRoot,baseId:baseId,root:_root,schemaPath:"",errSchemaPath:"#",errorPath:'""',MissingRefError:errorClasses.MissingRef,RULES:RULES,validate:validateGenerator,util:util,resolve:resolve,resolveRef:resolveRef,usePattern:usePattern,useDefault:useDefault,useCustomRule:useCustomRule,opts:opts,formats:formats,logger:self.logger,self:self});sourceCode=vars(refVal,refValCode)+vars(patterns,patternCode)+vars(defaults,defaultCode)+vars(customRules,customRuleCode)+sourceCode;if(opts.processCode)sourceCode=opts.processCode(sourceCode,_schema);var validate;try{var makeValidate=new Function("self","RULES","formats","root","refVal","defaults","customRules","equal","ucs2length","ValidationError",sourceCode);validate=makeValidate(self,RULES,formats,root,refVal,defaults,customRules,equal,ucs2length,ValidationError);refVal[0]=validate}catch(e){self.logger.error("Error compiling schema, function code:",sourceCode);throw e}validate.schema=_schema;validate.errors=null;validate.refs=refs;validate.refVal=refVal;validate.root=isRoot?validate:_root;if($async)validate.$async=true;if(opts.sourceCode===true){validate.source={code:sourceCode,patterns:patterns,defaults:defaults}}return validate}function resolveRef(baseId,ref,isRoot){ref=resolve.url(baseId,ref);var refIndex=refs[ref];var _refVal,refCode;if(refIndex!==undefined){_refVal=refVal[refIndex];refCode="refVal["+refIndex+"]";return resolvedRef(_refVal,refCode)}if(!isRoot&&root.refs){var rootRefId=root.refs[ref];if(rootRefId!==undefined){_refVal=root.refVal[rootRefId];refCode=addLocalRef(ref,_refVal);return resolvedRef(_refVal,refCode)}}refCode=addLocalRef(ref);var v=resolve.call(self,localCompile,root,ref);if(v===undefined){var localSchema=localRefs&&localRefs[ref];if(localSchema){v=resolve.inlineRef(localSchema,opts.inlineRefs)?localSchema:compile.call(self,localSchema,root,localRefs,baseId)}}if(v===undefined){removeLocalRef(ref)}else{replaceLocalRef(ref,v);return resolvedRef(v,refCode)}}function addLocalRef(ref,v){var refId=refVal.length;refVal[refId]=v;refs[ref]=refId;return"refVal"+refId}function removeLocalRef(ref){delete refs[ref]}function replaceLocalRef(ref,v){var refId=refs[ref];refVal[refId]=v}function resolvedRef(refVal,code){return typeof refVal=="object"||typeof refVal=="boolean"?{code:code,schema:refVal,inline:true}:{code:code,$async:refVal&&!!refVal.$async}}function usePattern(regexStr){var index=patternsHash[regexStr];if(index===undefined){index=patternsHash[regexStr]=patterns.length;patterns[index]=regexStr}return"pattern"+index}function useDefault(value){switch(typeof value){case"boolean":case"number":return""+value;case"string":return util.toQuotedString(value);case"object":if(value===null)return"null";var valueStr=stableStringify(value);var index=defaultsHash[valueStr];if(index===undefined){index=defaultsHash[valueStr]=defaults.length;defaults[index]=value}return"default"+index}}function useCustomRule(rule,schema,parentSchema,it){if(self._opts.validateSchema!==false){var deps=rule.definition.dependencies;if(deps&&!deps.every((function(keyword){return Object.prototype.hasOwnProperty.call(parentSchema,keyword)})))throw new Error("parent schema must have all required keywords: "+deps.join(","));var validateSchema=rule.definition.validateSchema;if(validateSchema){var valid=validateSchema(schema);if(!valid){var message="keyword schema is invalid: "+self.errorsText(validateSchema.errors);if(self._opts.validateSchema=="log")self.logger.error(message);else throw new Error(message)}}}var compile=rule.definition.compile,inline=rule.definition.inline,macro=rule.definition.macro;var validate;if(compile){validate=compile.call(self,schema,parentSchema,it)}else if(macro){validate=macro.call(self,schema,parentSchema,it);if(opts.validateSchema!==false)self.validateSchema(validate,true)}else if(inline){validate=inline.call(self,it,rule.keyword,schema,parentSchema)}else{validate=rule.definition.validate;if(!validate)return}if(validate===undefined)throw new Error('custom keyword "'+rule.keyword+'"failed to compile');var index=customRules.length;customRules[index]=validate;return{code:"customRule"+index,validate:validate}}}function checkCompiling(schema,root,baseId){var index=compIndex.call(this,schema,root,baseId);if(index>=0)return{index:index,compiling:true};index=this._compilations.length;this._compilations[index]={schema:schema,root:root,baseId:baseId};return{index:index,compiling:false}}function endCompiling(schema,root,baseId){var i=compIndex.call(this,schema,root,baseId);if(i>=0)this._compilations.splice(i,1)}function compIndex(schema,root,baseId){for(var i=0;i<this._compilations.length;i++){var c=this._compilations[i];if(c.schema==schema&&c.root==root&&c.baseId==baseId)return i}return-1}function patternCode(i,patterns){return"var pattern"+i+" = new RegExp("+util.toQuotedString(patterns[i])+");"}function defaultCode(i){return"var default"+i+" = defaults["+i+"];"}function refValCode(i,refVal){return refVal[i]===undefined?"":"var refVal"+i+" = refVal["+i+"];"}function customRuleCode(i){return"var customRule"+i+" = customRules["+i+"];"}function vars(arr,statement){if(!arr.length)return"";var code="";for(var i=0;i<arr.length;i++)code+=statement(i,arr);return code}},{"../dotjs/validate":38,"./error_classes":3,"./resolve":6,"./util":10,"fast-deep-equal":42,"fast-json-stable-stringify":43}],6:[function(require,module,exports){"use strict";var URI=require("uri-js"),equal=require("fast-deep-equal"),util=require("./util"),SchemaObject=require("./schema_obj"),traverse=require("json-schema-traverse");module.exports=resolve;resolve.normalizeId=normalizeId;resolve.fullPath=getFullPath;resolve.url=resolveUrl;resolve.ids=resolveIds;resolve.inlineRef=inlineRef;resolve.schema=resolveSchema;function resolve(compile,root,ref){var refVal=this._refs[ref];if(typeof refVal=="string"){if(this._refs[refVal])refVal=this._refs[refVal];else return resolve.call(this,compile,root,refVal)}refVal=refVal||this._schemas[ref];if(refVal instanceof SchemaObject){return inlineRef(refVal.schema,this._opts.inlineRefs)?refVal.schema:refVal.validate||this._compile(refVal)}var res=resolveSchema.call(this,root,ref);var schema,v,baseId;if(res){schema=res.schema;root=res.root;baseId=res.baseId}if(schema instanceof SchemaObject){v=schema.validate||compile.call(this,schema.schema,root,undefined,baseId)}else if(schema!==undefined){v=inlineRef(schema,this._opts.inlineRefs)?schema:compile.call(this,schema,root,undefined,baseId)}return v}function resolveSchema(root,ref){var p=URI.parse(ref),refPath=_getFullPath(p),baseId=getFullPath(this._getId(root.schema));if(Object.keys(root.schema).length===0||refPath!==baseId){var id=normalizeId(refPath);var refVal=this._refs[id];if(typeof refVal=="string"){return resolveRecursive.call(this,root,refVal,p)}else if(refVal instanceof SchemaObject){if(!refVal.validate)this._compile(refVal);root=refVal}else{refVal=this._schemas[id];if(refVal instanceof SchemaObject){if(!refVal.validate)this._compile(refVal);if(id==normalizeId(ref))return{schema:refVal,root:root,baseId:baseId};root=refVal}else{return}}if(!root.schema)return;baseId=getFullPath(this._getId(root.schema))}return getJsonPointer.call(this,p,baseId,root.schema,root)}function resolveRecursive(root,ref,parsedRef){var res=resolveSchema.call(this,root,ref);if(res){var schema=res.schema;var baseId=res.baseId;root=res.root;var id=this._getId(schema);if(id)baseId=resolveUrl(baseId,id);return getJsonPointer.call(this,parsedRef,baseId,schema,root)}}var PREVENT_SCOPE_CHANGE=util.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function getJsonPointer(parsedRef,baseId,schema,root){parsedRef.fragment=parsedRef.fragment||"";if(parsedRef.fragment.slice(0,1)!="/")return;var parts=parsedRef.fragment.split("/");for(var i=1;i<parts.length;i++){var part=parts[i];if(part){part=util.unescapeFragment(part);schema=schema[part];if(schema===undefined)break;var id;if(!PREVENT_SCOPE_CHANGE[part]){id=this._getId(schema);if(id)baseId=resolveUrl(baseId,id);if(schema.$ref){var $ref=resolveUrl(baseId,schema.$ref);var res=resolveSchema.call(this,root,$ref);if(res){schema=res.schema;root=res.root;baseId=res.baseId}}}}}if(schema!==undefined&&schema!==root.schema)return{schema:schema,root:root,baseId:baseId}}var SIMPLE_INLINED=util.toHash(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum"]);function inlineRef(schema,limit){if(limit===false)return false;if(limit===undefined||limit===true)return checkNoRef(schema);else if(limit)return countKeys(schema)<=limit}function checkNoRef(schema){var item;if(Array.isArray(schema)){for(var i=0;i<schema.length;i++){item=schema[i];if(typeof item=="object"&&!checkNoRef(item))return false}}else{for(var key in schema){if(key=="$ref")return false;item=schema[key];if(typeof item=="object"&&!checkNoRef(item))return false}}return true}function countKeys(schema){var count=0,item;if(Array.isArray(schema)){for(var i=0;i<schema.length;i++){item=schema[i];if(typeof item=="object")count+=countKeys(item);if(count==Infinity)return Infinity}}else{for(var key in schema){if(key=="$ref")return Infinity;if(SIMPLE_INLINED[key]){count++}else{item=schema[key];if(typeof item=="object")count+=countKeys(item)+1;if(count==Infinity)return Infinity}}}return count}function getFullPath(id,normalize){if(normalize!==false)id=normalizeId(id);var p=URI.parse(id);return _getFullPath(p)}function _getFullPath(p){return URI.serialize(p).split("#")[0]+"#"}var TRAILING_SLASH_HASH=/#\/?$/;function normalizeId(id){return id?id.replace(TRAILING_SLASH_HASH,""):""}function resolveUrl(baseId,id){id=normalizeId(id);return URI.resolve(baseId,id)}function resolveIds(schema){var schemaId=normalizeId(this._getId(schema));var baseIds={"":schemaId};var fullPaths={"":getFullPath(schemaId,false)};var localRefs={};var self=this;traverse(schema,{allKeys:true},(function(sch,jsonPtr,rootSchema,parentJsonPtr,parentKeyword,parentSchema,keyIndex){if(jsonPtr==="")return;var id=self._getId(sch);var baseId=baseIds[parentJsonPtr];var fullPath=fullPaths[parentJsonPtr]+"/"+parentKeyword;if(keyIndex!==undefined)fullPath+="/"+(typeof keyIndex=="number"?keyIndex:util.escapeFragment(keyIndex));if(typeof id=="string"){id=baseId=normalizeId(baseId?URI.resolve(baseId,id):id);var refVal=self._refs[id];if(typeof refVal=="string")refVal=self._refs[refVal];if(refVal&&refVal.schema){if(!equal(sch,refVal.schema))throw new Error('id "'+id+'" resolves to more than one schema')}else if(id!=normalizeId(fullPath)){if(id[0]=="#"){if(localRefs[id]&&!equal(sch,localRefs[id]))throw new Error('id "'+id+'" resolves to more than one schema');localRefs[id]=sch}else{self._refs[id]=fullPath}}}baseIds[jsonPtr]=baseId;fullPaths[jsonPtr]=fullPath}));return localRefs}},{"./schema_obj":8,"./util":10,"fast-deep-equal":42,"json-schema-traverse":44,"uri-js":45}],7:[function(require,module,exports){"use strict";var ruleModules=require("../dotjs"),toHash=require("./util").toHash;module.exports=function rules(){var RULES=[{type:"number",rules:[{maximum:["exclusiveMaximum"]},{minimum:["exclusiveMinimum"]},"multipleOf","format"]},{type:"string",rules:["maxLength","minLength","pattern","format"]},{type:"array",rules:["maxItems","minItems","items","contains","uniqueItems"]},{type:"object",rules:["maxProperties","minProperties","required","dependencies","propertyNames",{properties:["additionalProperties","patternProperties"]}]},{rules:["$ref","const","enum","not","anyOf","oneOf","allOf","if"]}];var ALL=["type","$comment"];var KEYWORDS=["$schema","$id","id","$data","$async","title","description","default","definitions","examples","readOnly","writeOnly","contentMediaType","contentEncoding","additionalItems","then","else"];var TYPES=["number","integer","string","array","object","boolean","null"];RULES.all=toHash(ALL);RULES.types=toHash(TYPES);RULES.forEach((function(group){group.rules=group.rules.map((function(keyword){var implKeywords;if(typeof keyword=="object"){var key=Object.keys(keyword)[0];implKeywords=keyword[key];keyword=key;implKeywords.forEach((function(k){ALL.push(k);RULES.all[k]=true}))}ALL.push(keyword);var rule=RULES.all[keyword]={keyword:keyword,code:ruleModules[keyword],implements:implKeywords};return rule}));RULES.all.$comment={keyword:"$comment",code:ruleModules.$comment};if(group.type)RULES.types[group.type]=group}));RULES.keywords=toHash(ALL.concat(KEYWORDS));RULES.custom={};return RULES}},{"../dotjs":27,"./util":10}],8:[function(require,module,exports){"use strict";var util=require("./util");module.exports=SchemaObject;function SchemaObject(obj){util.copy(obj,this)}},{"./util":10}],9:[function(require,module,exports){"use strict";module.exports=function ucs2length(str){var length=0,len=str.length,pos=0,value;while(pos<len){length++;value=str.charCodeAt(pos++);if(value>=55296&&value<=56319&&pos<len){value=str.charCodeAt(pos);if((value&64512)==56320)pos++}}return length}},{}],10:[function(require,module,exports){"use strict";module.exports={copy:copy,checkDataType:checkDataType,checkDataTypes:checkDataTypes,coerceToTypes:coerceToTypes,toHash:toHash,getProperty:getProperty,escapeQuotes:escapeQuotes,equal:require("fast-deep-equal"),ucs2length:require("./ucs2length"),varOccurences:varOccurences,varReplace:varReplace,schemaHasRules:schemaHasRules,schemaHasRulesExcept:schemaHasRulesExcept,schemaUnknownRules:schemaUnknownRules,toQuotedString:toQuotedString,getPathExpr:getPathExpr,getPath:getPath,getData:getData,unescapeFragment:unescapeFragment,unescapeJsonPointer:unescapeJsonPointer,escapeFragment:escapeFragment,escapeJsonPointer:escapeJsonPointer};function copy(o,to){to=to||{};for(var key in o)to[key]=o[key];return to}function checkDataType(dataType,data,strictNumbers,negate){var EQUAL=negate?" !== ":" === ",AND=negate?" || ":" && ",OK=negate?"!":"",NOT=negate?"":"!";switch(dataType){case"null":return data+EQUAL+"null";case"array":return OK+"Array.isArray("+data+")";case"object":return"("+OK+data+AND+"typeof "+data+EQUAL+'"object"'+AND+NOT+"Array.isArray("+data+"))";case"integer":return"(typeof "+data+EQUAL+'"number"'+AND+NOT+"("+data+" % 1)"+AND+data+EQUAL+data+(strictNumbers?AND+OK+"isFinite("+data+")":"")+")";case"number":return"(typeof "+data+EQUAL+'"'+dataType+'"'+(strictNumbers?AND+OK+"isFinite("+data+")":"")+")";default:return"typeof "+data+EQUAL+'"'+dataType+'"'}}function checkDataTypes(dataTypes,data,strictNumbers){switch(dataTypes.length){case 1:return checkDataType(dataTypes[0],data,strictNumbers,true);default:var code="";var types=toHash(dataTypes);if(types.array&&types.object){code=types.null?"(":"(!"+data+" || ";code+="typeof "+data+' !== "object")';delete types.null;delete types.array;delete types.object}if(types.number)delete types.integer;for(var t in types)code+=(code?" && ":"")+checkDataType(t,data,strictNumbers,true);return code}}var COERCE_TO_TYPES=toHash(["string","number","integer","boolean","null"]);function coerceToTypes(optionCoerceTypes,dataTypes){if(Array.isArray(dataTypes)){var types=[];for(var i=0;i<dataTypes.length;i++){var t=dataTypes[i];if(COERCE_TO_TYPES[t])types[types.length]=t;else if(optionCoerceTypes==="array"&&t==="array")types[types.length]=t}if(types.length)return types}else if(COERCE_TO_TYPES[dataTypes]){return[dataTypes]}else if(optionCoerceTypes==="array"&&dataTypes==="array"){return["array"]}}function toHash(arr){var hash={};for(var i=0;i<arr.length;i++)hash[arr[i]]=true;return hash}var IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var SINGLE_QUOTE=/'|\\/g;function getProperty(key){return typeof key=="number"?"["+key+"]":IDENTIFIER.test(key)?"."+key:"['"+escapeQuotes(key)+"']"}function escapeQuotes(str){return str.replace(SINGLE_QUOTE,"\\$&").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\f/g,"\\f").replace(/\t/g,"\\t")}function varOccurences(str,dataVar){dataVar+="[^0-9]";var matches=str.match(new RegExp(dataVar,"g"));return matches?matches.length:0}function varReplace(str,dataVar,expr){dataVar+="([^0-9])";expr=expr.replace(/\$/g,"$$$$");return str.replace(new RegExp(dataVar,"g"),expr+"$1")}function schemaHasRules(schema,rules){if(typeof schema=="boolean")return!schema;for(var key in schema)if(rules[key])return true}function schemaHasRulesExcept(schema,rules,exceptKeyword){if(typeof schema=="boolean")return!schema&&exceptKeyword!="not";for(var key in schema)if(key!=exceptKeyword&&rules[key])return true}function schemaUnknownRules(schema,rules){if(typeof schema=="boolean")return;for(var key in schema)if(!rules[key])return key}function toQuotedString(str){return"'"+escapeQuotes(str)+"'"}function getPathExpr(currentPath,expr,jsonPointers,isNumber){var path=jsonPointers?"'/' + "+expr+(isNumber?"":".replace(/~/g, '~0').replace(/\\//g, '~1')"):isNumber?"'[' + "+expr+" + ']'":"'[\\'' + "+expr+" + '\\']'";return joinPaths(currentPath,path)}function getPath(currentPath,prop,jsonPointers){var path=jsonPointers?toQuotedString("/"+escapeJsonPointer(prop)):toQuotedString(getProperty(prop));return joinPaths(currentPath,path)}var JSON_POINTER=/^\/(?:[^~]|~0|~1)*$/;var RELATIVE_JSON_POINTER=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function getData($data,lvl,paths){var up,jsonPointer,data,matches;if($data==="")return"rootData";if($data[0]=="/"){if(!JSON_POINTER.test($data))throw new Error("Invalid JSON-pointer: "+$data);jsonPointer=$data;data="rootData"}else{matches=$data.match(RELATIVE_JSON_POINTER);if(!matches)throw new Error("Invalid JSON-pointer: "+$data);up=+matches[1];jsonPointer=matches[2];if(jsonPointer=="#"){if(up>=lvl)throw new Error("Cannot access property/index "+up+" levels up, current level is "+lvl);return paths[lvl-up]}if(up>lvl)throw new Error("Cannot access data "+up+" levels up, current level is "+lvl);data="data"+(lvl-up||"");if(!jsonPointer)return data}var expr=data;var segments=jsonPointer.split("/");for(var i=0;i<segments.length;i++){var segment=segments[i];if(segment){data+=getProperty(unescapeJsonPointer(segment));expr+=" && "+data}}return expr}function joinPaths(a,b){if(a=='""')return b;return(a+" + "+b).replace(/([^\\])' \+ '/g,"$1")}function unescapeFragment(str){return unescapeJsonPointer(decodeURIComponent(str))}function escapeFragment(str){return encodeURIComponent(escapeJsonPointer(str))}function escapeJsonPointer(str){return str.replace(/~/g,"~0").replace(/\//g,"~1")}function unescapeJsonPointer(str){return str.replace(/~1/g,"/").replace(/~0/g,"~")}},{"./ucs2length":9,"fast-deep-equal":42}],11:[function(require,module,exports){"use strict";var KEYWORDS=["multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","additionalItems","maxItems","minItems","uniqueItems","maxProperties","minProperties","required","additionalProperties","enum","format","const"];module.exports=function(metaSchema,keywordsJsonPointers){for(var i=0;i<keywordsJsonPointers.length;i++){metaSchema=JSON.parse(JSON.stringify(metaSchema));var segments=keywordsJsonPointers[i].split("/");var keywords=metaSchema;var j;for(j=1;j<segments.length;j++)keywords=keywords[segments[j]];for(j=0;j<KEYWORDS.length;j++){var key=KEYWORDS[j];var schema=keywords[key];if(schema){keywords[key]={anyOf:[schema,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]}}}}return metaSchema}},{}],12:[function(require,module,exports){"use strict";var metaSchema=require("./refs/json-schema-draft-07.json");module.exports={$id:"https://github.com/ajv-validator/ajv/blob/master/lib/definition_schema.js",definitions:{simpleTypes:metaSchema.definitions.simpleTypes},type:"object",dependencies:{schema:["validate"],$data:["validate"],statements:["inline"],valid:{not:{required:["macro"]}}},properties:{type:metaSchema.properties.type,schema:{type:"boolean"},statements:{type:"boolean"},dependencies:{type:"array",items:{type:"string"}},metaSchema:{type:"object"},modifying:{type:"boolean"},valid:{type:"boolean"},$data:{type:"boolean"},async:{type:"boolean"},errors:{anyOf:[{type:"boolean"},{const:"full"}]}}}},{"./refs/json-schema-draft-07.json":41}],13:[function(require,module,exports){"use strict";module.exports=function generate__limit(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $errorKeyword;var $data="data"+($dataLvl||"");var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}var $isMax=$keyword=="maximum",$exclusiveKeyword=$isMax?"exclusiveMaximum":"exclusiveMinimum",$schemaExcl=it.schema[$exclusiveKeyword],$isDataExcl=it.opts.$data&&$schemaExcl&&$schemaExcl.$data,$op=$isMax?"<":">",$notOp=$isMax?">":"<",$errorKeyword=undefined;if(!($isData||typeof $schema=="number"||$schema===undefined)){throw new Error($keyword+" must be number")}if(!($isDataExcl||$schemaExcl===undefined||typeof $schemaExcl=="number"||typeof $schemaExcl=="boolean")){throw new Error($exclusiveKeyword+" must be number or boolean")}if($isDataExcl){var $schemaValueExcl=it.util.getData($schemaExcl.$data,$dataLvl,it.dataPathArr),$exclusive="exclusive"+$lvl,$exclType="exclType"+$lvl,$exclIsNumber="exclIsNumber"+$lvl,$opExpr="op"+$lvl,$opStr="' + "+$opExpr+" + '";out+=" var schemaExcl"+$lvl+" = "+$schemaValueExcl+"; ";$schemaValueExcl="schemaExcl"+$lvl;out+=" var "+$exclusive+"; var "+$exclType+" = typeof "+$schemaValueExcl+"; if ("+$exclType+" != 'boolean' && "+$exclType+" != 'undefined' && "+$exclType+" != 'number') { ";var $errorKeyword=$exclusiveKeyword;var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: {} ";if(it.opts.messages!==false){out+=" , message: '"+$exclusiveKeyword+" should be boolean' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } else if ( ";if($isData){out+=" ("+$schemaValue+" !== undefined && typeof "+$schemaValue+" != 'number') || "}out+=" "+$exclType+" == 'number' ? ( ("+$exclusive+" = "+$schemaValue+" === undefined || "+$schemaValueExcl+" "+$op+"= "+$schemaValue+") ? "+$data+" "+$notOp+"= "+$schemaValueExcl+" : "+$data+" "+$notOp+" "+$schemaValue+" ) : ( ("+$exclusive+" = "+$schemaValueExcl+" === true) ? "+$data+" "+$notOp+"= "+$schemaValue+" : "+$data+" "+$notOp+" "+$schemaValue+" ) || "+$data+" !== "+$data+") { var op"+$lvl+" = "+$exclusive+" ? '"+$op+"' : '"+$op+"='; ";if($schema===undefined){$errorKeyword=$exclusiveKeyword;$errSchemaPath=it.errSchemaPath+"/"+$exclusiveKeyword;$schemaValue=$schemaValueExcl;$isData=$isDataExcl}}else{var $exclIsNumber=typeof $schemaExcl=="number",$opStr=$op;if($exclIsNumber&&$isData){var $opExpr="'"+$opStr+"'";out+=" if ( ";if($isData){out+=" ("+$schemaValue+" !== undefined && typeof "+$schemaValue+" != 'number') || "}out+=" ( "+$schemaValue+" === undefined || "+$schemaExcl+" "+$op+"= "+$schemaValue+" ? "+$data+" "+$notOp+"= "+$schemaExcl+" : "+$data+" "+$notOp+" "+$schemaValue+" ) || "+$data+" !== "+$data+") { "}else{if($exclIsNumber&&$schema===undefined){$exclusive=true;$errorKeyword=$exclusiveKeyword;$errSchemaPath=it.errSchemaPath+"/"+$exclusiveKeyword;$schemaValue=$schemaExcl;$notOp+="="}else{if($exclIsNumber)$schemaValue=Math[$isMax?"min":"max"]($schemaExcl,$schema);if($schemaExcl===($exclIsNumber?$schemaValue:true)){$exclusive=true;$errorKeyword=$exclusiveKeyword;$errSchemaPath=it.errSchemaPath+"/"+$exclusiveKeyword;$notOp+="="}else{$exclusive=false;$opStr+="="}}var $opExpr="'"+$opStr+"'";out+=" if ( ";if($isData){out+=" ("+$schemaValue+" !== undefined && typeof "+$schemaValue+" != 'number') || "}out+=" "+$data+" "+$notOp+" "+$schemaValue+" || "+$data+" !== "+$data+") { "}}$errorKeyword=$errorKeyword||$keyword;var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"_limit")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { comparison: "+$opExpr+", limit: "+$schemaValue+", exclusive: "+$exclusive+" } ";if(it.opts.messages!==false){out+=" , message: 'should be "+$opStr+" ";if($isData){out+="' + "+$schemaValue}else{out+=""+$schemaValue+"'"}}if(it.opts.verbose){out+=" , schema: ";if($isData){out+="validate.schema"+$schemaPath}else{out+=""+$schema}out+=" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } ";if($breakOnError){out+=" else { "}return out}},{}],14:[function(require,module,exports){"use strict";module.exports=function generate__limitItems(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $errorKeyword;var $data="data"+($dataLvl||"");var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}if(!($isData||typeof $schema=="number")){throw new Error($keyword+" must be number")}var $op=$keyword=="maxItems"?">":"<";out+="if ( ";if($isData){out+=" ("+$schemaValue+" !== undefined && typeof "+$schemaValue+" != 'number') || "}out+=" "+$data+".length "+$op+" "+$schemaValue+") { ";var $errorKeyword=$keyword;var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"_limitItems")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { limit: "+$schemaValue+" } ";if(it.opts.messages!==false){out+=" , message: 'should NOT have ";if($keyword=="maxItems"){out+="more"}else{out+="fewer"}out+=" than ";if($isData){out+="' + "+$schemaValue+" + '"}else{out+=""+$schema}out+=" items' "}if(it.opts.verbose){out+=" , schema: ";if($isData){out+="validate.schema"+$schemaPath}else{out+=""+$schema}out+=" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+="} ";if($breakOnError){out+=" else { "}return out}},{}],15:[function(require,module,exports){"use strict";module.exports=function generate__limitLength(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $errorKeyword;var $data="data"+($dataLvl||"");var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}if(!($isData||typeof $schema=="number")){throw new Error($keyword+" must be number")}var $op=$keyword=="maxLength"?">":"<";out+="if ( ";if($isData){out+=" ("+$schemaValue+" !== undefined && typeof "+$schemaValue+" != 'number') || "}if(it.opts.unicode===false){out+=" "+$data+".length "}else{out+=" ucs2length("+$data+") "}out+=" "+$op+" "+$schemaValue+") { ";var $errorKeyword=$keyword;var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"_limitLength")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { limit: "+$schemaValue+" } ";if(it.opts.messages!==false){out+=" , message: 'should NOT be ";if($keyword=="maxLength"){out+="longer"}else{out+="shorter"}out+=" than ";if($isData){out+="' + "+$schemaValue+" + '"}else{out+=""+$schema}out+=" characters' "}if(it.opts.verbose){out+=" , schema: ";if($isData){out+="validate.schema"+$schemaPath}else{out+=""+$schema}out+=" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+="} ";if($breakOnError){out+=" else { "}return out}},{}],16:[function(require,module,exports){"use strict";module.exports=function generate__limitProperties(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $errorKeyword;var $data="data"+($dataLvl||"");var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}if(!($isData||typeof $schema=="number")){throw new Error($keyword+" must be number")}var $op=$keyword=="maxProperties"?">":"<";out+="if ( ";if($isData){out+=" ("+$schemaValue+" !== undefined && typeof "+$schemaValue+" != 'number') || "}out+=" Object.keys("+$data+").length "+$op+" "+$schemaValue+") { ";var $errorKeyword=$keyword;var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"_limitProperties")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { limit: "+$schemaValue+" } ";if(it.opts.messages!==false){out+=" , message: 'should NOT have ";if($keyword=="maxProperties"){out+="more"}else{out+="fewer"}out+=" than ";if($isData){out+="' + "+$schemaValue+" + '"}else{out+=""+$schema}out+=" properties' "}if(it.opts.verbose){out+=" , schema: ";if($isData){out+="validate.schema"+$schemaPath}else{out+=""+$schema}out+=" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+="} ";if($breakOnError){out+=" else { "}return out}},{}],17:[function(require,module,exports){"use strict";module.exports=function generate_allOf(it,$keyword,$ruleType){var out=" ";var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;var $currentBaseId=$it.baseId,$allSchemasEmpty=true;var arr1=$schema;if(arr1){var $sch,$i=-1,l1=arr1.length-1;while($i<l1){$sch=arr1[$i+=1];if(it.opts.strictKeywords?typeof $sch=="object"&&Object.keys($sch).length>0||$sch===false:it.util.schemaHasRules($sch,it.RULES.all)){$allSchemasEmpty=false;$it.schema=$sch;$it.schemaPath=$schemaPath+"["+$i+"]";$it.errSchemaPath=$errSchemaPath+"/"+$i;out+=" "+it.validate($it)+" ";$it.baseId=$currentBaseId;if($breakOnError){out+=" if ("+$nextValid+") { ";$closingBraces+="}"}}}}if($breakOnError){if($allSchemasEmpty){out+=" if (true) { "}else{out+=" "+$closingBraces.slice(0,-1)+" "}}return out}},{}],18:[function(require,module,exports){"use strict";module.exports=function generate_anyOf(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $errs="errs__"+$lvl;var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;var $noEmptySchema=$schema.every((function($sch){return it.opts.strictKeywords?typeof $sch=="object"&&Object.keys($sch).length>0||$sch===false:it.util.schemaHasRules($sch,it.RULES.all)}));if($noEmptySchema){var $currentBaseId=$it.baseId;out+=" var "+$errs+" = errors; var "+$valid+" = false; ";var $wasComposite=it.compositeRule;it.compositeRule=$it.compositeRule=true;var arr1=$schema;if(arr1){var $sch,$i=-1,l1=arr1.length-1;while($i<l1){$sch=arr1[$i+=1];$it.schema=$sch;$it.schemaPath=$schemaPath+"["+$i+"]";$it.errSchemaPath=$errSchemaPath+"/"+$i;out+=" "+it.validate($it)+" ";$it.baseId=$currentBaseId;out+=" "+$valid+" = "+$valid+" || "+$nextValid+"; if (!"+$valid+") { ";$closingBraces+="}"}}it.compositeRule=$it.compositeRule=$wasComposite;out+=" "+$closingBraces+" if (!"+$valid+") { var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"anyOf"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: {} ";if(it.opts.messages!==false){out+=" , message: 'should match some schema in anyOf' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(vErrors); "}else{out+=" validate.errors = vErrors; return false; "}}out+=" } else { errors = "+$errs+"; if (vErrors !== null) { if ("+$errs+") vErrors.length = "+$errs+"; else vErrors = null; } ";if(it.opts.allErrors){out+=" } "}}else{if($breakOnError){out+=" if (true) { "}}return out}},{}],19:[function(require,module,exports){"use strict";module.exports=function generate_comment(it,$keyword,$ruleType){var out=" ";var $schema=it.schema[$keyword];var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $comment=it.util.toQuotedString($schema);if(it.opts.$comment===true){out+=" console.log("+$comment+");"}else if(typeof it.opts.$comment=="function"){out+=" self._opts.$comment("+$comment+", "+it.util.toQuotedString($errSchemaPath)+", validate.root.schema);"}return out}},{}],20:[function(require,module,exports){"use strict";module.exports=function generate_const(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}if(!$isData){out+=" var schema"+$lvl+" = validate.schema"+$schemaPath+";"}out+="var "+$valid+" = equal("+$data+", schema"+$lvl+"); if (!"+$valid+") { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"const"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { allowedValue: schema"+$lvl+" } ";if(it.opts.messages!==false){out+=" , message: 'should be equal to constant' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" }";if($breakOnError){out+=" else { "}return out}},{}],21:[function(require,module,exports){"use strict";module.exports=function generate_contains(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $errs="errs__"+$lvl;var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;var $idx="i"+$lvl,$dataNxt=$it.dataLevel=it.dataLevel+1,$nextData="data"+$dataNxt,$currentBaseId=it.baseId,$nonEmptySchema=it.opts.strictKeywords?typeof $schema=="object"&&Object.keys($schema).length>0||$schema===false:it.util.schemaHasRules($schema,it.RULES.all);out+="var "+$errs+" = errors;var "+$valid+";";if($nonEmptySchema){var $wasComposite=it.compositeRule;it.compositeRule=$it.compositeRule=true;$it.schema=$schema;$it.schemaPath=$schemaPath;$it.errSchemaPath=$errSchemaPath;out+=" var "+$nextValid+" = false; for (var "+$idx+" = 0; "+$idx+" < "+$data+".length; "+$idx+"++) { ";$it.errorPath=it.util.getPathExpr(it.errorPath,$idx,it.opts.jsonPointers,true);var $passData=$data+"["+$idx+"]";$it.dataPathArr[$dataNxt]=$idx;var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){out+=" "+it.util.varReplace($code,$nextData,$passData)+" "}else{out+=" var "+$nextData+" = "+$passData+"; "+$code+" "}out+=" if ("+$nextValid+") break; } ";it.compositeRule=$it.compositeRule=$wasComposite;out+=" "+$closingBraces+" if (!"+$nextValid+") {"}else{out+=" if ("+$data+".length == 0) {"}var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"contains"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: {} ";if(it.opts.messages!==false){out+=" , message: 'should contain a valid item' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } else { ";if($nonEmptySchema){out+=" errors = "+$errs+"; if (vErrors !== null) { if ("+$errs+") vErrors.length = "+$errs+"; else vErrors = null; } "}if(it.opts.allErrors){out+=" } "}return out}},{}],22:[function(require,module,exports){"use strict";module.exports=function generate_custom(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $errorKeyword;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $errs="errs__"+$lvl;var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}var $rule=this,$definition="definition"+$lvl,$rDef=$rule.definition,$closingBraces="";var $compile,$inline,$macro,$ruleValidate,$validateCode;if($isData&&$rDef.$data){$validateCode="keywordValidate"+$lvl;var $validateSchema=$rDef.validateSchema;out+=" var "+$definition+" = RULES.custom['"+$keyword+"'].definition; var "+$validateCode+" = "+$definition+".validate;"}else{$ruleValidate=it.useCustomRule($rule,$schema,it.schema,it);if(!$ruleValidate)return;$schemaValue="validate.schema"+$schemaPath;$validateCode=$ruleValidate.code;$compile=$rDef.compile;$inline=$rDef.inline;$macro=$rDef.macro}var $ruleErrs=$validateCode+".errors",$i="i"+$lvl,$ruleErr="ruleErr"+$lvl,$asyncKeyword=$rDef.async;if($asyncKeyword&&!it.async)throw new Error("async keyword in sync schema");if(!($inline||$macro)){out+=""+$ruleErrs+" = null;"}out+="var "+$errs+" = errors;var "+$valid+";";if($isData&&$rDef.$data){$closingBraces+="}";out+=" if ("+$schemaValue+" === undefined) { "+$valid+" = true; } else { ";if($validateSchema){$closingBraces+="}";out+=" "+$valid+" = "+$definition+".validateSchema("+$schemaValue+"); if ("+$valid+") { "}}if($inline){if($rDef.statements){out+=" "+$ruleValidate.validate+" "}else{out+=" "+$valid+" = "+$ruleValidate.validate+"; "}}else if($macro){var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;$it.schema=$ruleValidate.validate;$it.schemaPath="";var $wasComposite=it.compositeRule;it.compositeRule=$it.compositeRule=true;var $code=it.validate($it).replace(/validate\.schema/g,$validateCode);it.compositeRule=$it.compositeRule=$wasComposite;out+=" "+$code}else{var $$outStack=$$outStack||[];$$outStack.push(out);out="";out+=" "+$validateCode+".call( ";if(it.opts.passContext){out+="this"}else{out+="self"}if($compile||$rDef.schema===false){out+=" , "+$data+" "}else{out+=" , "+$schemaValue+" , "+$data+" , validate.schema"+it.schemaPath+" "}out+=" , (dataPath || '')";if(it.errorPath!='""'){out+=" + "+it.errorPath}var $parentData=$dataLvl?"data"+($dataLvl-1||""):"parentData",$parentDataProperty=$dataLvl?it.dataPathArr[$dataLvl]:"parentDataProperty";out+=" , "+$parentData+" , "+$parentDataProperty+" , rootData ) ";var def_callRuleValidate=out;out=$$outStack.pop();if($rDef.errors===false){out+=" "+$valid+" = ";if($asyncKeyword){out+="await "}out+=""+def_callRuleValidate+"; "}else{if($asyncKeyword){$ruleErrs="customErrors"+$lvl;out+=" var "+$ruleErrs+" = null; try { "+$valid+" = await "+def_callRuleValidate+"; } catch (e) { "+$valid+" = false; if (e instanceof ValidationError) "+$ruleErrs+" = e.errors; else throw e; } "}else{out+=" "+$ruleErrs+" = null; "+$valid+" = "+def_callRuleValidate+"; "}}}if($rDef.modifying){out+=" if ("+$parentData+") "+$data+" = "+$parentData+"["+$parentDataProperty+"];"}out+=""+$closingBraces;if($rDef.valid){if($breakOnError){out+=" if (true) { "}}else{out+=" if ( ";if($rDef.valid===undefined){out+=" !";if($macro){out+=""+$nextValid}else{out+=""+$valid}}else{out+=" "+!$rDef.valid+" "}out+=") { ";$errorKeyword=$rule.keyword;var $$outStack=$$outStack||[];$$outStack.push(out);out="";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"custom")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { keyword: '"+$rule.keyword+"' } ";if(it.opts.messages!==false){out+=" , message: 'should pass \""+$rule.keyword+"\" keyword validation' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}var def_customError=out;out=$$outStack.pop();if($inline){if($rDef.errors){if($rDef.errors!="full"){out+=" for (var "+$i+"="+$errs+"; "+$i+"<errors; "+$i+"++) { var "+$ruleErr+" = vErrors["+$i+"]; if ("+$ruleErr+".dataPath === undefined) "+$ruleErr+".dataPath = (dataPath || '') + "+it.errorPath+"; if ("+$ruleErr+".schemaPath === undefined) { "+$ruleErr+'.schemaPath = "'+$errSchemaPath+'"; } ';if(it.opts.verbose){out+=" "+$ruleErr+".schema = "+$schemaValue+"; "+$ruleErr+".data = "+$data+"; "}out+=" } "}}else{if($rDef.errors===false){out+=" "+def_customError+" "}else{out+=" if ("+$errs+" == errors) { "+def_customError+" } else { for (var "+$i+"="+$errs+"; "+$i+"<errors; "+$i+"++) { var "+$ruleErr+" = vErrors["+$i+"]; if ("+$ruleErr+".dataPath === undefined) "+$ruleErr+".dataPath = (dataPath || '') + "+it.errorPath+"; if ("+$ruleErr+".schemaPath === undefined) { "+$ruleErr+'.schemaPath = "'+$errSchemaPath+'"; } ';if(it.opts.verbose){out+=" "+$ruleErr+".schema = "+$schemaValue+"; "+$ruleErr+".data = "+$data+"; "}out+=" } } "}}}else if($macro){out+=" var err = ";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"custom")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { keyword: '"+$rule.keyword+"' } ";if(it.opts.messages!==false){out+=" , message: 'should pass \""+$rule.keyword+"\" keyword validation' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(vErrors); "}else{out+=" validate.errors = vErrors; return false; "}}}else{if($rDef.errors===false){out+=" "+def_customError+" "}else{out+=" if (Array.isArray("+$ruleErrs+")) { if (vErrors === null) vErrors = "+$ruleErrs+"; else vErrors = vErrors.concat("+$ruleErrs+"); errors = vErrors.length; for (var "+$i+"="+$errs+"; "+$i+"<errors; "+$i+"++) { var "+$ruleErr+" = vErrors["+$i+"]; if ("+$ruleErr+".dataPath === undefined) "+$ruleErr+".dataPath = (dataPath || '') + "+it.errorPath+"; "+$ruleErr+'.schemaPath = "'+$errSchemaPath+'"; ';if(it.opts.verbose){out+=" "+$ruleErr+".schema = "+$schemaValue+"; "+$ruleErr+".data = "+$data+"; "}out+=" } } else { "+def_customError+" } "}}out+=" } ";if($breakOnError){out+=" else { "}}return out}},{}],23:[function(require,module,exports){"use strict";module.exports=function generate_dependencies(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $errs="errs__"+$lvl;var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;var $schemaDeps={},$propertyDeps={},$ownProperties=it.opts.ownProperties;for($property in $schema){if($property=="__proto__")continue;var $sch=$schema[$property];var $deps=Array.isArray($sch)?$propertyDeps:$schemaDeps;$deps[$property]=$sch}out+="var "+$errs+" = errors;";var $currentErrorPath=it.errorPath;out+="var missing"+$lvl+";";for(var $property in $propertyDeps){$deps=$propertyDeps[$property];if($deps.length){out+=" if ( "+$data+it.util.getProperty($property)+" !== undefined ";if($ownProperties){out+=" && Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($property)+"') "}if($breakOnError){out+=" && ( ";var arr1=$deps;if(arr1){var $propertyKey,$i=-1,l1=arr1.length-1;while($i<l1){$propertyKey=arr1[$i+=1];if($i){out+=" || "}var $prop=it.util.getProperty($propertyKey),$useData=$data+$prop;out+=" ( ( "+$useData+" === undefined ";if($ownProperties){out+=" || ! Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($propertyKey)+"') "}out+=") && (missing"+$lvl+" = "+it.util.toQuotedString(it.opts.jsonPointers?$propertyKey:$prop)+") ) "}}out+=")) { ";var $propertyPath="missing"+$lvl,$missingProperty="' + "+$propertyPath+" + '";if(it.opts._errorDataPathProperty){it.errorPath=it.opts.jsonPointers?it.util.getPathExpr($currentErrorPath,$propertyPath,true):$currentErrorPath+" + "+$propertyPath}var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"dependencies"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { property: '"+it.util.escapeQuotes($property)+"', missingProperty: '"+$missingProperty+"', depsCount: "+$deps.length+", deps: '"+it.util.escapeQuotes($deps.length==1?$deps[0]:$deps.join(", "))+"' } ";if(it.opts.messages!==false){out+=" , message: 'should have ";if($deps.length==1){out+="property "+it.util.escapeQuotes($deps[0])}else{out+="properties "+it.util.escapeQuotes($deps.join(", "))}out+=" when property "+it.util.escapeQuotes($property)+" is present' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}}else{out+=" ) { ";var arr2=$deps;if(arr2){var $propertyKey,i2=-1,l2=arr2.length-1;while(i2<l2){$propertyKey=arr2[i2+=1];var $prop=it.util.getProperty($propertyKey),$missingProperty=it.util.escapeQuotes($propertyKey),$useData=$data+$prop;if(it.opts._errorDataPathProperty){it.errorPath=it.util.getPath($currentErrorPath,$propertyKey,it.opts.jsonPointers)}out+=" if ( "+$useData+" === undefined ";if($ownProperties){out+=" || ! Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($propertyKey)+"') "}out+=") { var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"dependencies"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { property: '"+it.util.escapeQuotes($property)+"', missingProperty: '"+$missingProperty+"', depsCount: "+$deps.length+", deps: '"+it.util.escapeQuotes($deps.length==1?$deps[0]:$deps.join(", "))+"' } ";if(it.opts.messages!==false){out+=" , message: 'should have ";if($deps.length==1){out+="property "+it.util.escapeQuotes($deps[0])}else{out+="properties "+it.util.escapeQuotes($deps.join(", "))}out+=" when property "+it.util.escapeQuotes($property)+" is present' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}}out+=" } ";if($breakOnError){$closingBraces+="}";out+=" else { "}}}it.errorPath=$currentErrorPath;var $currentBaseId=$it.baseId;for(var $property in $schemaDeps){var $sch=$schemaDeps[$property];if(it.opts.strictKeywords?typeof $sch=="object"&&Object.keys($sch).length>0||$sch===false:it.util.schemaHasRules($sch,it.RULES.all)){out+=" "+$nextValid+" = true; if ( "+$data+it.util.getProperty($property)+" !== undefined ";if($ownProperties){out+=" && Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($property)+"') "}out+=") { ";$it.schema=$sch;$it.schemaPath=$schemaPath+it.util.getProperty($property);$it.errSchemaPath=$errSchemaPath+"/"+it.util.escapeFragment($property);out+=" "+it.validate($it)+" ";$it.baseId=$currentBaseId;out+=" } ";if($breakOnError){out+=" if ("+$nextValid+") { ";$closingBraces+="}"}}}if($breakOnError){out+=" "+$closingBraces+" if ("+$errs+" == errors) {"}return out}},{}],24:[function(require,module,exports){"use strict";module.exports=function generate_enum(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}var $i="i"+$lvl,$vSchema="schema"+$lvl;if(!$isData){out+=" var "+$vSchema+" = validate.schema"+$schemaPath+";"}out+="var "+$valid+";";if($isData){out+=" if (schema"+$lvl+" === undefined) "+$valid+" = true; else if (!Array.isArray(schema"+$lvl+")) "+$valid+" = false; else {"}out+=""+$valid+" = false;for (var "+$i+"=0; "+$i+"<"+$vSchema+".length; "+$i+"++) if (equal("+$data+", "+$vSchema+"["+$i+"])) { "+$valid+" = true; break; }";if($isData){out+=" } "}out+=" if (!"+$valid+") { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"enum"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { allowedValues: schema"+$lvl+" } ";if(it.opts.messages!==false){out+=" , message: 'should be equal to one of the allowed values' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" }";if($breakOnError){out+=" else { "}return out}},{}],25:[function(require,module,exports){"use strict";module.exports=function generate_format(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");if(it.opts.format===false){if($breakOnError){out+=" if (true) { "}return out}var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}var $unknownFormats=it.opts.unknownFormats,$allowUnknown=Array.isArray($unknownFormats);if($isData){var $format="format"+$lvl,$isObject="isObject"+$lvl,$formatType="formatType"+$lvl;out+=" var "+$format+" = formats["+$schemaValue+"]; var "+$isObject+" = typeof "+$format+" == 'object' && !("+$format+" instanceof RegExp) && "+$format+".validate; var "+$formatType+" = "+$isObject+" && "+$format+".type || 'string'; if ("+$isObject+") { ";if(it.async){out+=" var async"+$lvl+" = "+$format+".async; "}out+=" "+$format+" = "+$format+".validate; } if ( ";if($isData){out+=" ("+$schemaValue+" !== undefined && typeof "+$schemaValue+" != 'string') || "}out+=" (";if($unknownFormats!="ignore"){out+=" ("+$schemaValue+" && !"+$format+" ";if($allowUnknown){out+=" && self._opts.unknownFormats.indexOf("+$schemaValue+") == -1 "}out+=") || "}out+=" ("+$format+" && "+$formatType+" == '"+$ruleType+"' && !(typeof "+$format+" == 'function' ? ";if(it.async){out+=" (async"+$lvl+" ? await "+$format+"("+$data+") : "+$format+"("+$data+")) "}else{out+=" "+$format+"("+$data+") "}out+=" : "+$format+".test("+$data+"))))) {"}else{var $format=it.formats[$schema];if(!$format){if($unknownFormats=="ignore"){it.logger.warn('unknown format "'+$schema+'" ignored in schema at path "'+it.errSchemaPath+'"');if($breakOnError){out+=" if (true) { "}return out}else if($allowUnknown&&$unknownFormats.indexOf($schema)>=0){if($breakOnError){out+=" if (true) { "}return out}else{throw new Error('unknown format "'+$schema+'" is used in schema at path "'+it.errSchemaPath+'"')}}var $isObject=typeof $format=="object"&&!($format instanceof RegExp)&&$format.validate;var $formatType=$isObject&&$format.type||"string";if($isObject){var $async=$format.async===true;$format=$format.validate}if($formatType!=$ruleType){if($breakOnError){out+=" if (true) { "}return out}if($async){if(!it.async)throw new Error("async format in sync schema");var $formatRef="formats"+it.util.getProperty($schema)+".validate";out+=" if (!(await "+$formatRef+"("+$data+"))) { "}else{out+=" if (! ";var $formatRef="formats"+it.util.getProperty($schema);if($isObject)$formatRef+=".validate";if(typeof $format=="function"){out+=" "+$formatRef+"("+$data+") "}else{out+=" "+$formatRef+".test("+$data+") "}out+=") { "}}var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"format"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { format: ";if($isData){out+=""+$schemaValue}else{out+=""+it.util.toQuotedString($schema)}out+=" } ";if(it.opts.messages!==false){out+=" , message: 'should match format \"";if($isData){out+="' + "+$schemaValue+" + '"}else{out+=""+it.util.escapeQuotes($schema)}out+="\"' "}if(it.opts.verbose){out+=" , schema: ";if($isData){out+="validate.schema"+$schemaPath}else{out+=""+it.util.toQuotedString($schema)}out+=" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } ";if($breakOnError){out+=" else { "}return out}},{}],26:[function(require,module,exports){"use strict";module.exports=function generate_if(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $errs="errs__"+$lvl;var $it=it.util.copy(it);$it.level++;var $nextValid="valid"+$it.level;var $thenSch=it.schema["then"],$elseSch=it.schema["else"],$thenPresent=$thenSch!==undefined&&(it.opts.strictKeywords?typeof $thenSch=="object"&&Object.keys($thenSch).length>0||$thenSch===false:it.util.schemaHasRules($thenSch,it.RULES.all)),$elsePresent=$elseSch!==undefined&&(it.opts.strictKeywords?typeof $elseSch=="object"&&Object.keys($elseSch).length>0||$elseSch===false:it.util.schemaHasRules($elseSch,it.RULES.all)),$currentBaseId=$it.baseId;if($thenPresent||$elsePresent){var $ifClause;$it.createErrors=false;$it.schema=$schema;$it.schemaPath=$schemaPath;$it.errSchemaPath=$errSchemaPath;out+=" var "+$errs+" = errors; var "+$valid+" = true; ";var $wasComposite=it.compositeRule;it.compositeRule=$it.compositeRule=true;out+=" "+it.validate($it)+" ";$it.baseId=$currentBaseId;$it.createErrors=true;out+=" errors = "+$errs+"; if (vErrors !== null) { if ("+$errs+") vErrors.length = "+$errs+"; else vErrors = null; } ";it.compositeRule=$it.compositeRule=$wasComposite;if($thenPresent){out+=" if ("+$nextValid+") { ";$it.schema=it.schema["then"];$it.schemaPath=it.schemaPath+".then";$it.errSchemaPath=it.errSchemaPath+"/then";out+=" "+it.validate($it)+" ";$it.baseId=$currentBaseId;out+=" "+$valid+" = "+$nextValid+"; ";if($thenPresent&&$elsePresent){$ifClause="ifClause"+$lvl;out+=" var "+$ifClause+" = 'then'; "}else{$ifClause="'then'"}out+=" } ";if($elsePresent){out+=" else { "}}else{out+=" if (!"+$nextValid+") { "}if($elsePresent){$it.schema=it.schema["else"];$it.schemaPath=it.schemaPath+".else";$it.errSchemaPath=it.errSchemaPath+"/else";out+=" "+it.validate($it)+" ";$it.baseId=$currentBaseId;out+=" "+$valid+" = "+$nextValid+"; ";if($thenPresent&&$elsePresent){$ifClause="ifClause"+$lvl;out+=" var "+$ifClause+" = 'else'; "}else{$ifClause="'else'"}out+=" } "}out+=" if (!"+$valid+") { var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"if"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { failingKeyword: "+$ifClause+" } ";if(it.opts.messages!==false){out+=" , message: 'should match \"' + "+$ifClause+" + '\" schema' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(vErrors); "}else{out+=" validate.errors = vErrors; return false; "}}out+=" } ";if($breakOnError){out+=" else { "}}else{if($breakOnError){out+=" if (true) { "}}return out}},{}],27:[function(require,module,exports){"use strict";module.exports={$ref:require("./ref"),allOf:require("./allOf"),anyOf:require("./anyOf"),$comment:require("./comment"),const:require("./const"),contains:require("./contains"),dependencies:require("./dependencies"),enum:require("./enum"),format:require("./format"),if:require("./if"),items:require("./items"),maximum:require("./_limit"),minimum:require("./_limit"),maxItems:require("./_limitItems"),minItems:require("./_limitItems"),maxLength:require("./_limitLength"),minLength:require("./_limitLength"),maxProperties:require("./_limitProperties"),minProperties:require("./_limitProperties"),multipleOf:require("./multipleOf"),not:require("./not"),oneOf:require("./oneOf"),pattern:require("./pattern"),properties:require("./properties"),propertyNames:require("./propertyNames"),required:require("./required"),uniqueItems:require("./uniqueItems"),validate:require("./validate")}},{"./_limit":13,"./_limitItems":14,"./_limitLength":15,"./_limitProperties":16,"./allOf":17,"./anyOf":18,"./comment":19,"./const":20,"./contains":21,"./dependencies":23,"./enum":24,"./format":25,"./if":26,"./items":28,"./multipleOf":29,"./not":30,"./oneOf":31,"./pattern":32,"./properties":33,"./propertyNames":34,"./ref":35,"./required":36,"./uniqueItems":37,"./validate":38}],28:[function(require,module,exports){"use strict";module.exports=function generate_items(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $errs="errs__"+$lvl;var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;var $idx="i"+$lvl,$dataNxt=$it.dataLevel=it.dataLevel+1,$nextData="data"+$dataNxt,$currentBaseId=it.baseId;out+="var "+$errs+" = errors;var "+$valid+";";if(Array.isArray($schema)){var $additionalItems=it.schema.additionalItems;if($additionalItems===false){out+=" "+$valid+" = "+$data+".length <= "+$schema.length+"; ";var $currErrSchemaPath=$errSchemaPath;$errSchemaPath=it.errSchemaPath+"/additionalItems";out+=" if (!"+$valid+") { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"additionalItems"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { limit: "+$schema.length+" } ";if(it.opts.messages!==false){out+=" , message: 'should NOT have more than "+$schema.length+" items' "}if(it.opts.verbose){out+=" , schema: false , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } ";$errSchemaPath=$currErrSchemaPath;if($breakOnError){$closingBraces+="}";out+=" else { "}}var arr1=$schema;if(arr1){var $sch,$i=-1,l1=arr1.length-1;while($i<l1){$sch=arr1[$i+=1];if(it.opts.strictKeywords?typeof $sch=="object"&&Object.keys($sch).length>0||$sch===false:it.util.schemaHasRules($sch,it.RULES.all)){out+=" "+$nextValid+" = true; if ("+$data+".length > "+$i+") { ";var $passData=$data+"["+$i+"]";$it.schema=$sch;$it.schemaPath=$schemaPath+"["+$i+"]";$it.errSchemaPath=$errSchemaPath+"/"+$i;$it.errorPath=it.util.getPathExpr(it.errorPath,$i,it.opts.jsonPointers,true);$it.dataPathArr[$dataNxt]=$i;var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){out+=" "+it.util.varReplace($code,$nextData,$passData)+" "}else{out+=" var "+$nextData+" = "+$passData+"; "+$code+" "}out+=" } ";if($breakOnError){out+=" if ("+$nextValid+") { ";$closingBraces+="}"}}}}if(typeof $additionalItems=="object"&&(it.opts.strictKeywords?typeof $additionalItems=="object"&&Object.keys($additionalItems).length>0||$additionalItems===false:it.util.schemaHasRules($additionalItems,it.RULES.all))){$it.schema=$additionalItems;$it.schemaPath=it.schemaPath+".additionalItems";$it.errSchemaPath=it.errSchemaPath+"/additionalItems";out+=" "+$nextValid+" = true; if ("+$data+".length > "+$schema.length+") { for (var "+$idx+" = "+$schema.length+"; "+$idx+" < "+$data+".length; "+$idx+"++) { ";$it.errorPath=it.util.getPathExpr(it.errorPath,$idx,it.opts.jsonPointers,true);var $passData=$data+"["+$idx+"]";$it.dataPathArr[$dataNxt]=$idx;var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){out+=" "+it.util.varReplace($code,$nextData,$passData)+" "}else{out+=" var "+$nextData+" = "+$passData+"; "+$code+" "}if($breakOnError){out+=" if (!"+$nextValid+") break; "}out+=" } } ";if($breakOnError){out+=" if ("+$nextValid+") { ";$closingBraces+="}"}}}else if(it.opts.strictKeywords?typeof $schema=="object"&&Object.keys($schema).length>0||$schema===false:it.util.schemaHasRules($schema,it.RULES.all)){$it.schema=$schema;$it.schemaPath=$schemaPath;$it.errSchemaPath=$errSchemaPath;out+=" for (var "+$idx+" = "+0+"; "+$idx+" < "+$data+".length; "+$idx+"++) { ";$it.errorPath=it.util.getPathExpr(it.errorPath,$idx,it.opts.jsonPointers,true);var $passData=$data+"["+$idx+"]";$it.dataPathArr[$dataNxt]=$idx;var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){out+=" "+it.util.varReplace($code,$nextData,$passData)+" "}else{out+=" var "+$nextData+" = "+$passData+"; "+$code+" "}if($breakOnError){out+=" if (!"+$nextValid+") break; "}out+=" }"}if($breakOnError){out+=" "+$closingBraces+" if ("+$errs+" == errors) {"}return out}},{}],29:[function(require,module,exports){"use strict";module.exports=function generate_multipleOf(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}if(!($isData||typeof $schema=="number")){throw new Error($keyword+" must be number")}out+="var division"+$lvl+";if (";if($isData){out+=" "+$schemaValue+" !== undefined && ( typeof "+$schemaValue+" != 'number' || "}out+=" (division"+$lvl+" = "+$data+" / "+$schemaValue+", ";if(it.opts.multipleOfPrecision){out+=" Math.abs(Math.round(division"+$lvl+") - division"+$lvl+") > 1e-"+it.opts.multipleOfPrecision+" "}else{out+=" division"+$lvl+" !== parseInt(division"+$lvl+") "}out+=" ) ";if($isData){out+=" ) "}out+=" ) { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"multipleOf"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { multipleOf: "+$schemaValue+" } ";if(it.opts.messages!==false){out+=" , message: 'should be multiple of ";if($isData){out+="' + "+$schemaValue}else{out+=""+$schemaValue+"'"}}if(it.opts.verbose){out+=" , schema: ";if($isData){out+="validate.schema"+$schemaPath}else{out+=""+$schema}out+=" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+="} ";if($breakOnError){out+=" else { "}return out}},{}],30:[function(require,module,exports){"use strict";module.exports=function generate_not(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $errs="errs__"+$lvl;var $it=it.util.copy(it);$it.level++;var $nextValid="valid"+$it.level;if(it.opts.strictKeywords?typeof $schema=="object"&&Object.keys($schema).length>0||$schema===false:it.util.schemaHasRules($schema,it.RULES.all)){$it.schema=$schema;$it.schemaPath=$schemaPath;$it.errSchemaPath=$errSchemaPath;out+=" var "+$errs+" = errors; ";var $wasComposite=it.compositeRule;it.compositeRule=$it.compositeRule=true;$it.createErrors=false;var $allErrorsOption;if($it.opts.allErrors){$allErrorsOption=$it.opts.allErrors;$it.opts.allErrors=false}out+=" "+it.validate($it)+" ";$it.createErrors=true;if($allErrorsOption)$it.opts.allErrors=$allErrorsOption;it.compositeRule=$it.compositeRule=$wasComposite;out+=" if ("+$nextValid+") { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"not"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: {} ";if(it.opts.messages!==false){out+=" , message: 'should NOT be valid' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } else { errors = "+$errs+"; if (vErrors !== null) { if ("+$errs+") vErrors.length = "+$errs+"; else vErrors = null; } ";if(it.opts.allErrors){out+=" } "}}else{out+=" var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"not"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: {} ";if(it.opts.messages!==false){out+=" , message: 'should NOT be valid' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if($breakOnError){out+=" if (false) { "}}return out}},{}],31:[function(require,module,exports){"use strict";module.exports=function generate_oneOf(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $errs="errs__"+$lvl;var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;var $currentBaseId=$it.baseId,$prevValid="prevValid"+$lvl,$passingSchemas="passingSchemas"+$lvl;out+="var "+$errs+" = errors , "+$prevValid+" = false , "+$valid+" = false , "+$passingSchemas+" = null; ";var $wasComposite=it.compositeRule;it.compositeRule=$it.compositeRule=true;var arr1=$schema;if(arr1){var $sch,$i=-1,l1=arr1.length-1;while($i<l1){$sch=arr1[$i+=1];if(it.opts.strictKeywords?typeof $sch=="object"&&Object.keys($sch).length>0||$sch===false:it.util.schemaHasRules($sch,it.RULES.all)){$it.schema=$sch;$it.schemaPath=$schemaPath+"["+$i+"]";$it.errSchemaPath=$errSchemaPath+"/"+$i;out+=" "+it.validate($it)+" ";$it.baseId=$currentBaseId}else{out+=" var "+$nextValid+" = true; "}if($i){out+=" if ("+$nextValid+" && "+$prevValid+") { "+$valid+" = false; "+$passingSchemas+" = ["+$passingSchemas+", "+$i+"]; } else { ";$closingBraces+="}"}out+=" if ("+$nextValid+") { "+$valid+" = "+$prevValid+" = true; "+$passingSchemas+" = "+$i+"; }"}}it.compositeRule=$it.compositeRule=$wasComposite;out+=""+$closingBraces+"if (!"+$valid+") { var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"oneOf"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { passingSchemas: "+$passingSchemas+" } ";if(it.opts.messages!==false){out+=" , message: 'should match exactly one schema in oneOf' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(vErrors); "}else{out+=" validate.errors = vErrors; return false; "}}out+="} else { errors = "+$errs+"; if (vErrors !== null) { if ("+$errs+") vErrors.length = "+$errs+"; else vErrors = null; }";if(it.opts.allErrors){out+=" } "}return out}},{}],32:[function(require,module,exports){"use strict";module.exports=function generate_pattern(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}var $regexp=$isData?"(new RegExp("+$schemaValue+"))":it.usePattern($schema);out+="if ( ";if($isData){out+=" ("+$schemaValue+" !== undefined && typeof "+$schemaValue+" != 'string') || "}out+=" !"+$regexp+".test("+$data+") ) { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"pattern"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { pattern: ";if($isData){out+=""+$schemaValue}else{out+=""+it.util.toQuotedString($schema)}out+=" } ";if(it.opts.messages!==false){out+=" , message: 'should match pattern \"";if($isData){out+="' + "+$schemaValue+" + '"}else{out+=""+it.util.escapeQuotes($schema)}out+="\"' "}if(it.opts.verbose){out+=" , schema: ";if($isData){out+="validate.schema"+$schemaPath}else{out+=""+it.util.toQuotedString($schema)}out+=" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+="} ";if($breakOnError){out+=" else { "}return out}},{}],33:[function(require,module,exports){"use strict";module.exports=function generate_properties(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $errs="errs__"+$lvl;var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;var $key="key"+$lvl,$idx="idx"+$lvl,$dataNxt=$it.dataLevel=it.dataLevel+1,$nextData="data"+$dataNxt,$dataProperties="dataProperties"+$lvl;var $schemaKeys=Object.keys($schema||{}).filter(notProto),$pProperties=it.schema.patternProperties||{},$pPropertyKeys=Object.keys($pProperties).filter(notProto),$aProperties=it.schema.additionalProperties,$someProperties=$schemaKeys.length||$pPropertyKeys.length,$noAdditional=$aProperties===false,$additionalIsSchema=typeof $aProperties=="object"&&Object.keys($aProperties).length,$removeAdditional=it.opts.removeAdditional,$checkAdditional=$noAdditional||$additionalIsSchema||$removeAdditional,$ownProperties=it.opts.ownProperties,$currentBaseId=it.baseId;var $required=it.schema.required;if($required&&!(it.opts.$data&&$required.$data)&&$required.length<it.opts.loopRequired){var $requiredHash=it.util.toHash($required)}function notProto(p){return p!=="__proto__"}out+="var "+$errs+" = errors;var "+$nextValid+" = true;";if($ownProperties){out+=" var "+$dataProperties+" = undefined;"}if($checkAdditional){if($ownProperties){out+=" "+$dataProperties+" = "+$dataProperties+" || Object.keys("+$data+"); for (var "+$idx+"=0; "+$idx+"<"+$dataProperties+".length; "+$idx+"++) { var "+$key+" = "+$dataProperties+"["+$idx+"]; "}else{out+=" for (var "+$key+" in "+$data+") { "}if($someProperties){out+=" var isAdditional"+$lvl+" = !(false ";if($schemaKeys.length){if($schemaKeys.length>8){out+=" || validate.schema"+$schemaPath+".hasOwnProperty("+$key+") "}else{var arr1=$schemaKeys;if(arr1){var $propertyKey,i1=-1,l1=arr1.length-1;while(i1<l1){$propertyKey=arr1[i1+=1];out+=" || "+$key+" == "+it.util.toQuotedString($propertyKey)+" "}}}}if($pPropertyKeys.length){var arr2=$pPropertyKeys;if(arr2){var $pProperty,$i=-1,l2=arr2.length-1;while($i<l2){$pProperty=arr2[$i+=1];out+=" || "+it.usePattern($pProperty)+".test("+$key+") "}}}out+=" ); if (isAdditional"+$lvl+") { "}if($removeAdditional=="all"){out+=" delete "+$data+"["+$key+"]; "}else{var $currentErrorPath=it.errorPath;var $additionalProperty="' + "+$key+" + '";if(it.opts._errorDataPathProperty){it.errorPath=it.util.getPathExpr(it.errorPath,$key,it.opts.jsonPointers)}if($noAdditional){if($removeAdditional){out+=" delete "+$data+"["+$key+"]; "}else{out+=" "+$nextValid+" = false; ";var $currErrSchemaPath=$errSchemaPath;$errSchemaPath=it.errSchemaPath+"/additionalProperties";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"additionalProperties"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { additionalProperty: '"+$additionalProperty+"' } ";if(it.opts.messages!==false){out+=" , message: '";if(it.opts._errorDataPathProperty){out+="is an invalid additional property"}else{out+="should NOT have additional properties"}out+="' "}if(it.opts.verbose){out+=" , schema: false , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}$errSchemaPath=$currErrSchemaPath;if($breakOnError){out+=" break; "}}}else if($additionalIsSchema){if($removeAdditional=="failing"){out+=" var "+$errs+" = errors; ";var $wasComposite=it.compositeRule;it.compositeRule=$it.compositeRule=true;$it.schema=$aProperties;$it.schemaPath=it.schemaPath+".additionalProperties";$it.errSchemaPath=it.errSchemaPath+"/additionalProperties";$it.errorPath=it.opts._errorDataPathProperty?it.errorPath:it.util.getPathExpr(it.errorPath,$key,it.opts.jsonPointers);var $passData=$data+"["+$key+"]";$it.dataPathArr[$dataNxt]=$key;var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){out+=" "+it.util.varReplace($code,$nextData,$passData)+" "}else{out+=" var "+$nextData+" = "+$passData+"; "+$code+" "}out+=" if (!"+$nextValid+") { errors = "+$errs+"; if (validate.errors !== null) { if (errors) validate.errors.length = errors; else validate.errors = null; } delete "+$data+"["+$key+"]; } ";it.compositeRule=$it.compositeRule=$wasComposite}else{$it.schema=$aProperties;$it.schemaPath=it.schemaPath+".additionalProperties";$it.errSchemaPath=it.errSchemaPath+"/additionalProperties";$it.errorPath=it.opts._errorDataPathProperty?it.errorPath:it.util.getPathExpr(it.errorPath,$key,it.opts.jsonPointers);var $passData=$data+"["+$key+"]";$it.dataPathArr[$dataNxt]=$key;var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){out+=" "+it.util.varReplace($code,$nextData,$passData)+" "}else{out+=" var "+$nextData+" = "+$passData+"; "+$code+" "}if($breakOnError){out+=" if (!"+$nextValid+") break; "}}}it.errorPath=$currentErrorPath}if($someProperties){out+=" } "}out+=" } ";if($breakOnError){out+=" if ("+$nextValid+") { ";$closingBraces+="}"}}var $useDefaults=it.opts.useDefaults&&!it.compositeRule;if($schemaKeys.length){var arr3=$schemaKeys;if(arr3){var $propertyKey,i3=-1,l3=arr3.length-1;while(i3<l3){$propertyKey=arr3[i3+=1];var $sch=$schema[$propertyKey];if(it.opts.strictKeywords?typeof $sch=="object"&&Object.keys($sch).length>0||$sch===false:it.util.schemaHasRules($sch,it.RULES.all)){var $prop=it.util.getProperty($propertyKey),$passData=$data+$prop,$hasDefault=$useDefaults&&$sch.default!==undefined;$it.schema=$sch;$it.schemaPath=$schemaPath+$prop;$it.errSchemaPath=$errSchemaPath+"/"+it.util.escapeFragment($propertyKey);$it.errorPath=it.util.getPath(it.errorPath,$propertyKey,it.opts.jsonPointers);$it.dataPathArr[$dataNxt]=it.util.toQuotedString($propertyKey);var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){$code=it.util.varReplace($code,$nextData,$passData);var $useData=$passData}else{var $useData=$nextData;out+=" var "+$nextData+" = "+$passData+"; "}if($hasDefault){out+=" "+$code+" "}else{if($requiredHash&&$requiredHash[$propertyKey]){out+=" if ( "+$useData+" === undefined ";if($ownProperties){out+=" || ! Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($propertyKey)+"') "}out+=") { "+$nextValid+" = false; ";var $currentErrorPath=it.errorPath,$currErrSchemaPath=$errSchemaPath,$missingProperty=it.util.escapeQuotes($propertyKey);if(it.opts._errorDataPathProperty){it.errorPath=it.util.getPath($currentErrorPath,$propertyKey,it.opts.jsonPointers)}$errSchemaPath=it.errSchemaPath+"/required";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { missingProperty: '"+$missingProperty+"' } ";if(it.opts.messages!==false){out+=" , message: '";if(it.opts._errorDataPathProperty){out+="is a required property"}else{out+="should have required property \\'"+$missingProperty+"\\'"}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}$errSchemaPath=$currErrSchemaPath;it.errorPath=$currentErrorPath;out+=" } else { "}else{if($breakOnError){out+=" if ( "+$useData+" === undefined ";if($ownProperties){out+=" || ! Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($propertyKey)+"') "}out+=") { "+$nextValid+" = true; } else { "}else{out+=" if ("+$useData+" !== undefined ";if($ownProperties){out+=" && Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($propertyKey)+"') "}out+=" ) { "}}out+=" "+$code+" } "}}if($breakOnError){out+=" if ("+$nextValid+") { ";$closingBraces+="}"}}}}if($pPropertyKeys.length){var arr4=$pPropertyKeys;if(arr4){var $pProperty,i4=-1,l4=arr4.length-1;while(i4<l4){$pProperty=arr4[i4+=1];var $sch=$pProperties[$pProperty];if(it.opts.strictKeywords?typeof $sch=="object"&&Object.keys($sch).length>0||$sch===false:it.util.schemaHasRules($sch,it.RULES.all)){$it.schema=$sch;$it.schemaPath=it.schemaPath+".patternProperties"+it.util.getProperty($pProperty);$it.errSchemaPath=it.errSchemaPath+"/patternProperties/"+it.util.escapeFragment($pProperty);if($ownProperties){out+=" "+$dataProperties+" = "+$dataProperties+" || Object.keys("+$data+"); for (var "+$idx+"=0; "+$idx+"<"+$dataProperties+".length; "+$idx+"++) { var "+$key+" = "+$dataProperties+"["+$idx+"]; "}else{out+=" for (var "+$key+" in "+$data+") { "}out+=" if ("+it.usePattern($pProperty)+".test("+$key+")) { ";$it.errorPath=it.util.getPathExpr(it.errorPath,$key,it.opts.jsonPointers);var $passData=$data+"["+$key+"]";$it.dataPathArr[$dataNxt]=$key;var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){out+=" "+it.util.varReplace($code,$nextData,$passData)+" "}else{out+=" var "+$nextData+" = "+$passData+"; "+$code+" "}if($breakOnError){out+=" if (!"+$nextValid+") break; "}out+=" } ";if($breakOnError){out+=" else "+$nextValid+" = true; "}out+=" } ";if($breakOnError){out+=" if ("+$nextValid+") { ";$closingBraces+="}"}}}}}if($breakOnError){out+=" "+$closingBraces+" if ("+$errs+" == errors) {"}return out}},{}],34:[function(require,module,exports){"use strict";module.exports=function generate_propertyNames(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $errs="errs__"+$lvl;var $it=it.util.copy(it);var $closingBraces="";$it.level++;var $nextValid="valid"+$it.level;out+="var "+$errs+" = errors;";if(it.opts.strictKeywords?typeof $schema=="object"&&Object.keys($schema).length>0||$schema===false:it.util.schemaHasRules($schema,it.RULES.all)){$it.schema=$schema;$it.schemaPath=$schemaPath;$it.errSchemaPath=$errSchemaPath;var $key="key"+$lvl,$idx="idx"+$lvl,$i="i"+$lvl,$invalidName="' + "+$key+" + '",$dataNxt=$it.dataLevel=it.dataLevel+1,$nextData="data"+$dataNxt,$dataProperties="dataProperties"+$lvl,$ownProperties=it.opts.ownProperties,$currentBaseId=it.baseId;if($ownProperties){out+=" var "+$dataProperties+" = undefined; "}if($ownProperties){out+=" "+$dataProperties+" = "+$dataProperties+" || Object.keys("+$data+"); for (var "+$idx+"=0; "+$idx+"<"+$dataProperties+".length; "+$idx+"++) { var "+$key+" = "+$dataProperties+"["+$idx+"]; "}else{out+=" for (var "+$key+" in "+$data+") { "}out+=" var startErrs"+$lvl+" = errors; ";var $passData=$key;var $wasComposite=it.compositeRule;it.compositeRule=$it.compositeRule=true;var $code=it.validate($it);$it.baseId=$currentBaseId;if(it.util.varOccurences($code,$nextData)<2){out+=" "+it.util.varReplace($code,$nextData,$passData)+" "}else{out+=" var "+$nextData+" = "+$passData+"; "+$code+" "}it.compositeRule=$it.compositeRule=$wasComposite;out+=" if (!"+$nextValid+") { for (var "+$i+"=startErrs"+$lvl+"; "+$i+"<errors; "+$i+"++) { vErrors["+$i+"].propertyName = "+$key+"; } var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"propertyNames"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { propertyName: '"+$invalidName+"' } ";if(it.opts.messages!==false){out+=" , message: 'property name \\'"+$invalidName+"\\' is invalid' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(vErrors); "}else{out+=" validate.errors = vErrors; return false; "}}if($breakOnError){out+=" break; "}out+=" } }"}if($breakOnError){out+=" "+$closingBraces+" if ("+$errs+" == errors) {"}return out}},{}],35:[function(require,module,exports){"use strict";module.exports=function generate_ref(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $async,$refCode;if($schema=="#"||$schema=="#/"){if(it.isRoot){$async=it.async;$refCode="validate"}else{$async=it.root.schema.$async===true;$refCode="root.refVal[0]"}}else{var $refVal=it.resolveRef(it.baseId,$schema,it.isRoot);if($refVal===undefined){var $message=it.MissingRefError.message(it.baseId,$schema);if(it.opts.missingRefs=="fail"){it.logger.error($message);var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"$ref"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { ref: '"+it.util.escapeQuotes($schema)+"' } ";if(it.opts.messages!==false){out+=" , message: 'can\\'t resolve reference "+it.util.escapeQuotes($schema)+"' "}if(it.opts.verbose){out+=" , schema: "+it.util.toQuotedString($schema)+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}if($breakOnError){out+=" if (false) { "}}else if(it.opts.missingRefs=="ignore"){it.logger.warn($message);if($breakOnError){out+=" if (true) { "}}else{throw new it.MissingRefError(it.baseId,$schema,$message)}}else if($refVal.inline){var $it=it.util.copy(it);$it.level++;var $nextValid="valid"+$it.level;$it.schema=$refVal.schema;$it.schemaPath="";$it.errSchemaPath=$schema;var $code=it.validate($it).replace(/validate\.schema/g,$refVal.code);out+=" "+$code+" ";if($breakOnError){out+=" if ("+$nextValid+") { "}}else{$async=$refVal.$async===true||it.async&&$refVal.$async!==false;$refCode=$refVal.code}}if($refCode){var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.opts.passContext){out+=" "+$refCode+".call(this, "}else{out+=" "+$refCode+"( "}out+=" "+$data+", (dataPath || '')";if(it.errorPath!='""'){out+=" + "+it.errorPath}var $parentData=$dataLvl?"data"+($dataLvl-1||""):"parentData",$parentDataProperty=$dataLvl?it.dataPathArr[$dataLvl]:"parentDataProperty";out+=" , "+$parentData+" , "+$parentDataProperty+", rootData) ";var __callValidate=out;out=$$outStack.pop();if($async){if(!it.async)throw new Error("async schema referenced by sync schema");if($breakOnError){out+=" var "+$valid+"; "}out+=" try { await "+__callValidate+"; ";if($breakOnError){out+=" "+$valid+" = true; "}out+=" } catch (e) { if (!(e instanceof ValidationError)) throw e; if (vErrors === null) vErrors = e.errors; else vErrors = vErrors.concat(e.errors); errors = vErrors.length; ";if($breakOnError){out+=" "+$valid+" = false; "}out+=" } ";if($breakOnError){out+=" if ("+$valid+") { "}}else{out+=" if (!"+__callValidate+") { if (vErrors === null) vErrors = "+$refCode+".errors; else vErrors = vErrors.concat("+$refCode+".errors); errors = vErrors.length; } ";if($breakOnError){out+=" else { "}}}return out}},{}],36:[function(require,module,exports){"use strict";module.exports=function generate_required(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}var $vSchema="schema"+$lvl;if(!$isData){if($schema.length<it.opts.loopRequired&&it.schema.properties&&Object.keys(it.schema.properties).length){var $required=[];var arr1=$schema;if(arr1){var $property,i1=-1,l1=arr1.length-1;while(i1<l1){$property=arr1[i1+=1];var $propertySch=it.schema.properties[$property];if(!($propertySch&&(it.opts.strictKeywords?typeof $propertySch=="object"&&Object.keys($propertySch).length>0||$propertySch===false:it.util.schemaHasRules($propertySch,it.RULES.all)))){$required[$required.length]=$property}}}}else{var $required=$schema}}if($isData||$required.length){var $currentErrorPath=it.errorPath,$loopRequired=$isData||$required.length>=it.opts.loopRequired,$ownProperties=it.opts.ownProperties;if($breakOnError){out+=" var missing"+$lvl+"; ";if($loopRequired){if(!$isData){out+=" var "+$vSchema+" = validate.schema"+$schemaPath+"; "}var $i="i"+$lvl,$propertyPath="schema"+$lvl+"["+$i+"]",$missingProperty="' + "+$propertyPath+" + '";if(it.opts._errorDataPathProperty){it.errorPath=it.util.getPathExpr($currentErrorPath,$propertyPath,it.opts.jsonPointers)}out+=" var "+$valid+" = true; ";if($isData){out+=" if (schema"+$lvl+" === undefined) "+$valid+" = true; else if (!Array.isArray(schema"+$lvl+")) "+$valid+" = false; else {"}out+=" for (var "+$i+" = 0; "+$i+" < "+$vSchema+".length; "+$i+"++) { "+$valid+" = "+$data+"["+$vSchema+"["+$i+"]] !== undefined ";if($ownProperties){out+=" && Object.prototype.hasOwnProperty.call("+$data+", "+$vSchema+"["+$i+"]) "}out+="; if (!"+$valid+") break; } ";if($isData){out+=" } "}out+=" if (!"+$valid+") { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { missingProperty: '"+$missingProperty+"' } ";if(it.opts.messages!==false){out+=" , message: '";if(it.opts._errorDataPathProperty){out+="is a required property"}else{out+="should have required property \\'"+$missingProperty+"\\'"}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } else { "}else{out+=" if ( ";var arr2=$required;if(arr2){var $propertyKey,$i=-1,l2=arr2.length-1;while($i<l2){$propertyKey=arr2[$i+=1];if($i){out+=" || "}var $prop=it.util.getProperty($propertyKey),$useData=$data+$prop;out+=" ( ( "+$useData+" === undefined ";if($ownProperties){out+=" || ! Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($propertyKey)+"') "}out+=") && (missing"+$lvl+" = "+it.util.toQuotedString(it.opts.jsonPointers?$propertyKey:$prop)+") ) "}}out+=") { ";var $propertyPath="missing"+$lvl,$missingProperty="' + "+$propertyPath+" + '";if(it.opts._errorDataPathProperty){it.errorPath=it.opts.jsonPointers?it.util.getPathExpr($currentErrorPath,$propertyPath,true):$currentErrorPath+" + "+$propertyPath}var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { missingProperty: '"+$missingProperty+"' } ";if(it.opts.messages!==false){out+=" , message: '";if(it.opts._errorDataPathProperty){out+="is a required property"}else{out+="should have required property \\'"+$missingProperty+"\\'"}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } else { "}}else{if($loopRequired){if(!$isData){out+=" var "+$vSchema+" = validate.schema"+$schemaPath+"; "}var $i="i"+$lvl,$propertyPath="schema"+$lvl+"["+$i+"]",$missingProperty="' + "+$propertyPath+" + '";if(it.opts._errorDataPathProperty){it.errorPath=it.util.getPathExpr($currentErrorPath,$propertyPath,it.opts.jsonPointers)}if($isData){out+=" if ("+$vSchema+" && !Array.isArray("+$vSchema+")) { var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { missingProperty: '"+$missingProperty+"' } ";if(it.opts.messages!==false){out+=" , message: '";if(it.opts._errorDataPathProperty){out+="is a required property"}else{out+="should have required property \\'"+$missingProperty+"\\'"}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } else if ("+$vSchema+" !== undefined) { "}out+=" for (var "+$i+" = 0; "+$i+" < "+$vSchema+".length; "+$i+"++) { if ("+$data+"["+$vSchema+"["+$i+"]] === undefined ";if($ownProperties){out+=" || ! Object.prototype.hasOwnProperty.call("+$data+", "+$vSchema+"["+$i+"]) "}out+=") { var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { missingProperty: '"+$missingProperty+"' } ";if(it.opts.messages!==false){out+=" , message: '";if(it.opts._errorDataPathProperty){out+="is a required property"}else{out+="should have required property \\'"+$missingProperty+"\\'"}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } } ";if($isData){out+=" } "}}else{var arr3=$required;if(arr3){var $propertyKey,i3=-1,l3=arr3.length-1;while(i3<l3){$propertyKey=arr3[i3+=1];var $prop=it.util.getProperty($propertyKey),$missingProperty=it.util.escapeQuotes($propertyKey),$useData=$data+$prop;if(it.opts._errorDataPathProperty){it.errorPath=it.util.getPath($currentErrorPath,$propertyKey,it.opts.jsonPointers)}out+=" if ( "+$useData+" === undefined ";if($ownProperties){out+=" || ! Object.prototype.hasOwnProperty.call("+$data+", '"+it.util.escapeQuotes($propertyKey)+"') "}out+=") { var err = ";if(it.createErrors!==false){out+=" { keyword: '"+"required"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { missingProperty: '"+$missingProperty+"' } ";if(it.opts.messages!==false){out+=" , message: '";if(it.opts._errorDataPathProperty){out+="is a required property"}else{out+="should have required property \\'"+$missingProperty+"\\'"}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}out+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}}}it.errorPath=$currentErrorPath}else if($breakOnError){out+=" if (true) {"}return out}},{}],37:[function(require,module,exports){"use strict";module.exports=function generate_uniqueItems(it,$keyword,$ruleType){var out=" ";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;var $isData=it.opts.$data&&$schema&&$schema.$data,$schemaValue;if($isData){out+=" var schema"+$lvl+" = "+it.util.getData($schema.$data,$dataLvl,it.dataPathArr)+"; ";$schemaValue="schema"+$lvl}else{$schemaValue=$schema}if(($schema||$isData)&&it.opts.uniqueItems!==false){if($isData){out+=" var "+$valid+"; if ("+$schemaValue+" === false || "+$schemaValue+" === undefined) "+$valid+" = true; else if (typeof "+$schemaValue+" != 'boolean') "+$valid+" = false; else { "}out+=" var i = "+$data+".length , "+$valid+" = true , j; if (i > 1) { ";var $itemType=it.schema.items&&it.schema.items.type,$typeIsArray=Array.isArray($itemType);if(!$itemType||$itemType=="object"||$itemType=="array"||$typeIsArray&&($itemType.indexOf("object")>=0||$itemType.indexOf("array")>=0)){out+=" outer: for (;i--;) { for (j = i; j--;) { if (equal("+$data+"[i], "+$data+"[j])) { "+$valid+" = false; break outer; } } } "}else{out+=" var itemIndices = {}, item; for (;i--;) { var item = "+$data+"[i]; ";var $method="checkDataType"+($typeIsArray?"s":"");out+=" if ("+it.util[$method]($itemType,"item",it.opts.strictNumbers,true)+") continue; ";if($typeIsArray){out+=" if (typeof item == 'string') item = '\"' + item; "}out+=" if (typeof itemIndices[item] == 'number') { "+$valid+" = false; j = itemIndices[item]; break; } itemIndices[item] = i; } "}out+=" } ";if($isData){out+=" } "}out+=" if (!"+$valid+") { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+"uniqueItems"+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { i: i, j: j } ";if(it.opts.messages!==false){out+=" , message: 'should NOT have duplicate items (items ## ' + j + ' and ' + i + ' are identical)' "}if(it.opts.verbose){out+=" , schema: ";if($isData){out+="validate.schema"+$schemaPath}else{out+=""+$schema}out+=" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } ";if($breakOnError){out+=" else { "}}else{if($breakOnError){out+=" if (true) { "}}return out}},{}],38:[function(require,module,exports){"use strict";module.exports=function generate_validate(it,$keyword,$ruleType){var out="";var $async=it.schema.$async===true,$refKeywords=it.util.schemaHasRulesExcept(it.schema,it.RULES.all,"$ref"),$id=it.self._getId(it.schema);if(it.opts.strictKeywords){var $unknownKwd=it.util.schemaUnknownRules(it.schema,it.RULES.keywords);if($unknownKwd){var $keywordsMsg="unknown keyword: "+$unknownKwd;if(it.opts.strictKeywords==="log")it.logger.warn($keywordsMsg);else throw new Error($keywordsMsg)}}if(it.isTop){out+=" var validate = ";if($async){it.async=true;out+="async "}out+="function(data, dataPath, parentData, parentDataProperty, rootData) { 'use strict'; ";if($id&&(it.opts.sourceCode||it.opts.processCode)){out+=" "+("/*# sourceURL="+$id+" */")+" "}}if(typeof it.schema=="boolean"||!($refKeywords||it.schema.$ref)){var $keyword="false schema";var $lvl=it.level;var $dataLvl=it.dataLevel;var $schema=it.schema[$keyword];var $schemaPath=it.schemaPath+it.util.getProperty($keyword);var $errSchemaPath=it.errSchemaPath+"/"+$keyword;var $breakOnError=!it.opts.allErrors;var $errorKeyword;var $data="data"+($dataLvl||"");var $valid="valid"+$lvl;if(it.schema===false){if(it.isTop){$breakOnError=true}else{out+=" var "+$valid+" = false; "}var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"false schema")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: {} ";if(it.opts.messages!==false){out+=" , message: 'boolean schema is false' "}if(it.opts.verbose){out+=" , schema: false , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}}else{if(it.isTop){if($async){out+=" return data; "}else{out+=" validate.errors = null; return true; "}}else{out+=" var "+$valid+" = true; "}}if(it.isTop){out+=" }; return validate; "}return out}if(it.isTop){var $top=it.isTop,$lvl=it.level=0,$dataLvl=it.dataLevel=0,$data="data";it.rootId=it.resolve.fullPath(it.self._getId(it.root.schema));it.baseId=it.baseId||it.rootId;delete it.isTop;it.dataPathArr=[""];if(it.schema.default!==undefined&&it.opts.useDefaults&&it.opts.strictDefaults){var $defaultMsg="default is ignored in the schema root";if(it.opts.strictDefaults==="log")it.logger.warn($defaultMsg);else throw new Error($defaultMsg)}out+=" var vErrors = null; ";out+=" var errors = 0; ";out+=" if (rootData === undefined) rootData = data; "}else{var $lvl=it.level,$dataLvl=it.dataLevel,$data="data"+($dataLvl||"");if($id)it.baseId=it.resolve.url(it.baseId,$id);if($async&&!it.async)throw new Error("async schema in sync schema");out+=" var errs_"+$lvl+" = errors;"}var $valid="valid"+$lvl,$breakOnError=!it.opts.allErrors,$closingBraces1="",$closingBraces2="";var $errorKeyword;var $typeSchema=it.schema.type,$typeIsArray=Array.isArray($typeSchema);if($typeSchema&&it.opts.nullable&&it.schema.nullable===true){if($typeIsArray){if($typeSchema.indexOf("null")==-1)$typeSchema=$typeSchema.concat("null")}else if($typeSchema!="null"){$typeSchema=[$typeSchema,"null"];$typeIsArray=true}}if($typeIsArray&&$typeSchema.length==1){$typeSchema=$typeSchema[0];$typeIsArray=false}if(it.schema.$ref&&$refKeywords){if(it.opts.extendRefs=="fail"){throw new Error('$ref: validation keywords used in schema at path "'+it.errSchemaPath+'" (see option extendRefs)')}else if(it.opts.extendRefs!==true){$refKeywords=false;it.logger.warn('$ref: keywords ignored in schema at path "'+it.errSchemaPath+'"')}}if(it.schema.$comment&&it.opts.$comment){out+=" "+it.RULES.all.$comment.code(it,"$comment")}if($typeSchema){if(it.opts.coerceTypes){var $coerceToTypes=it.util.coerceToTypes(it.opts.coerceTypes,$typeSchema)}var $rulesGroup=it.RULES.types[$typeSchema];if($coerceToTypes||$typeIsArray||$rulesGroup===true||$rulesGroup&&!$shouldUseGroup($rulesGroup)){var $schemaPath=it.schemaPath+".type",$errSchemaPath=it.errSchemaPath+"/type";var $schemaPath=it.schemaPath+".type",$errSchemaPath=it.errSchemaPath+"/type",$method=$typeIsArray?"checkDataTypes":"checkDataType";out+=" if ("+it.util[$method]($typeSchema,$data,it.opts.strictNumbers,true)+") { ";if($coerceToTypes){var $dataType="dataType"+$lvl,$coerced="coerced"+$lvl;out+=" var "+$dataType+" = typeof "+$data+"; var "+$coerced+" = undefined; ";if(it.opts.coerceTypes=="array"){out+=" if ("+$dataType+" == 'object' && Array.isArray("+$data+") && "+$data+".length == 1) { "+$data+" = "+$data+"[0]; "+$dataType+" = typeof "+$data+"; if ("+it.util.checkDataType(it.schema.type,$data,it.opts.strictNumbers)+") "+$coerced+" = "+$data+"; } "}out+=" if ("+$coerced+" !== undefined) ; ";var arr1=$coerceToTypes;if(arr1){var $type,$i=-1,l1=arr1.length-1;while($i<l1){$type=arr1[$i+=1];if($type=="string"){out+=" else if ("+$dataType+" == 'number' || "+$dataType+" == 'boolean') "+$coerced+" = '' + "+$data+"; else if ("+$data+" === null) "+$coerced+" = ''; "}else if($type=="number"||$type=="integer"){out+=" else if ("+$dataType+" == 'boolean' || "+$data+" === null || ("+$dataType+" == 'string' && "+$data+" && "+$data+" == +"+$data+" ";if($type=="integer"){out+=" && !("+$data+" % 1)"}out+=")) "+$coerced+" = +"+$data+"; "}else if($type=="boolean"){out+=" else if ("+$data+" === 'false' || "+$data+" === 0 || "+$data+" === null) "+$coerced+" = false; else if ("+$data+" === 'true' || "+$data+" === 1) "+$coerced+" = true; "}else if($type=="null"){out+=" else if ("+$data+" === '' || "+$data+" === 0 || "+$data+" === false) "+$coerced+" = null; "}else if(it.opts.coerceTypes=="array"&&$type=="array"){out+=" else if ("+$dataType+" == 'string' || "+$dataType+" == 'number' || "+$dataType+" == 'boolean' || "+$data+" == null) "+$coerced+" = ["+$data+"]; "}}}out+=" else { ";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"type")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { type: '";if($typeIsArray){out+=""+$typeSchema.join(",")}else{out+=""+$typeSchema}out+="' } ";if(it.opts.messages!==false){out+=" , message: 'should be ";if($typeIsArray){out+=""+$typeSchema.join(",")}else{out+=""+$typeSchema}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } if ("+$coerced+" !== undefined) { ";var $parentData=$dataLvl?"data"+($dataLvl-1||""):"parentData",$parentDataProperty=$dataLvl?it.dataPathArr[$dataLvl]:"parentDataProperty";out+=" "+$data+" = "+$coerced+"; ";if(!$dataLvl){out+="if ("+$parentData+" !== undefined)"}out+=" "+$parentData+"["+$parentDataProperty+"] = "+$coerced+"; } "}else{var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"type")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { type: '";if($typeIsArray){out+=""+$typeSchema.join(",")}else{out+=""+$typeSchema}out+="' } ";if(it.opts.messages!==false){out+=" , message: 'should be ";if($typeIsArray){out+=""+$typeSchema.join(",")}else{out+=""+$typeSchema}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}}out+=" } "}}if(it.schema.$ref&&!$refKeywords){out+=" "+it.RULES.all.$ref.code(it,"$ref")+" ";if($breakOnError){out+=" } if (errors === ";if($top){out+="0"}else{out+="errs_"+$lvl}out+=") { ";$closingBraces2+="}"}}else{var arr2=it.RULES;if(arr2){var $rulesGroup,i2=-1,l2=arr2.length-1;while(i2<l2){$rulesGroup=arr2[i2+=1];if($shouldUseGroup($rulesGroup)){if($rulesGroup.type){out+=" if ("+it.util.checkDataType($rulesGroup.type,$data,it.opts.strictNumbers)+") { "}if(it.opts.useDefaults){if($rulesGroup.type=="object"&&it.schema.properties){var $schema=it.schema.properties,$schemaKeys=Object.keys($schema);var arr3=$schemaKeys;if(arr3){var $propertyKey,i3=-1,l3=arr3.length-1;while(i3<l3){$propertyKey=arr3[i3+=1];var $sch=$schema[$propertyKey];if($sch.default!==undefined){var $passData=$data+it.util.getProperty($propertyKey);if(it.compositeRule){if(it.opts.strictDefaults){var $defaultMsg="default is ignored for: "+$passData;if(it.opts.strictDefaults==="log")it.logger.warn($defaultMsg);else throw new Error($defaultMsg)}}else{out+=" if ("+$passData+" === undefined ";if(it.opts.useDefaults=="empty"){out+=" || "+$passData+" === null || "+$passData+" === '' "}out+=" ) "+$passData+" = ";if(it.opts.useDefaults=="shared"){out+=" "+it.useDefault($sch.default)+" "}else{out+=" "+JSON.stringify($sch.default)+" "}out+="; "}}}}}else if($rulesGroup.type=="array"&&Array.isArray(it.schema.items)){var arr4=it.schema.items;if(arr4){var $sch,$i=-1,l4=arr4.length-1;while($i<l4){$sch=arr4[$i+=1];if($sch.default!==undefined){var $passData=$data+"["+$i+"]";if(it.compositeRule){if(it.opts.strictDefaults){var $defaultMsg="default is ignored for: "+$passData;if(it.opts.strictDefaults==="log")it.logger.warn($defaultMsg);else throw new Error($defaultMsg)}}else{out+=" if ("+$passData+" === undefined ";if(it.opts.useDefaults=="empty"){out+=" || "+$passData+" === null || "+$passData+" === '' "}out+=" ) "+$passData+" = ";if(it.opts.useDefaults=="shared"){out+=" "+it.useDefault($sch.default)+" "}else{out+=" "+JSON.stringify($sch.default)+" "}out+="; "}}}}}}var arr5=$rulesGroup.rules;if(arr5){var $rule,i5=-1,l5=arr5.length-1;while(i5<l5){$rule=arr5[i5+=1];if($shouldUseRule($rule)){var $code=$rule.code(it,$rule.keyword,$rulesGroup.type);if($code){out+=" "+$code+" ";if($breakOnError){$closingBraces1+="}"}}}}}if($breakOnError){out+=" "+$closingBraces1+" ";$closingBraces1=""}if($rulesGroup.type){out+=" } ";if($typeSchema&&$typeSchema===$rulesGroup.type&&!$coerceToTypes){out+=" else { ";var $schemaPath=it.schemaPath+".type",$errSchemaPath=it.errSchemaPath+"/type";var $$outStack=$$outStack||[];$$outStack.push(out);out="";if(it.createErrors!==false){out+=" { keyword: '"+($errorKeyword||"type")+"' , dataPath: (dataPath || '') + "+it.errorPath+" , schemaPath: "+it.util.toQuotedString($errSchemaPath)+" , params: { type: '";if($typeIsArray){out+=""+$typeSchema.join(",")}else{out+=""+$typeSchema}out+="' } ";if(it.opts.messages!==false){out+=" , message: 'should be ";if($typeIsArray){out+=""+$typeSchema.join(",")}else{out+=""+$typeSchema}out+="' "}if(it.opts.verbose){out+=" , schema: validate.schema"+$schemaPath+" , parentSchema: validate.schema"+it.schemaPath+" , data: "+$data+" "}out+=" } "}else{out+=" {} "}var __err=out;out=$$outStack.pop();if(!it.compositeRule&&$breakOnError){if(it.async){out+=" throw new ValidationError(["+__err+"]); "}else{out+=" validate.errors = ["+__err+"]; return false; "}}else{out+=" var err = "+__err+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}out+=" } "}}if($breakOnError){out+=" if (errors === ";if($top){out+="0"}else{out+="errs_"+$lvl}out+=") { ";$closingBraces2+="}"}}}}}if($breakOnError){out+=" "+$closingBraces2+" "}if($top){if($async){out+=" if (errors === 0) return data; ";out+=" else throw new ValidationError(vErrors); "}else{out+=" validate.errors = vErrors; ";out+=" return errors === 0; "}out+=" }; return validate;"}else{out+=" var "+$valid+" = errors === errs_"+$lvl+";"}function $shouldUseGroup($rulesGroup){var rules=$rulesGroup.rules;for(var i=0;i<rules.length;i++)if($shouldUseRule(rules[i]))return true}function $shouldUseRule($rule){return it.schema[$rule.keyword]!==undefined||$rule.implements&&$ruleImplementsSomeKeyword($rule)}function $ruleImplementsSomeKeyword($rule){var impl=$rule.implements;for(var i=0;i<impl.length;i++)if(it.schema[impl[i]]!==undefined)return true}return out}},{}],39:[function(require,module,exports){"use strict";var IDENTIFIER=/^[a-z_$][a-z0-9_$-]*$/i;var customRuleCode=require("./dotjs/custom");var definitionSchema=require("./definition_schema");module.exports={add:addKeyword,get:getKeyword,remove:removeKeyword,validate:validateKeyword};function addKeyword(keyword,definition){var RULES=this.RULES;if(RULES.keywords[keyword])throw new Error("Keyword "+keyword+" is already defined");if(!IDENTIFIER.test(keyword))throw new Error("Keyword "+keyword+" is not a valid identifier");if(definition){this.validateKeyword(definition,true);var dataType=definition.type;if(Array.isArray(dataType)){for(var i=0;i<dataType.length;i++)_addRule(keyword,dataType[i],definition)}else{_addRule(keyword,dataType,definition)}var metaSchema=definition.metaSchema;if(metaSchema){if(definition.$data&&this._opts.$data){metaSchema={anyOf:[metaSchema,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]}}definition.validateSchema=this.compile(metaSchema,true)}}RULES.keywords[keyword]=RULES.all[keyword]=true;function _addRule(keyword,dataType,definition){var ruleGroup;for(var i=0;i<RULES.length;i++){var rg=RULES[i];if(rg.type==dataType){ruleGroup=rg;break}}if(!ruleGroup){ruleGroup={type:dataType,rules:[]};RULES.push(ruleGroup)}var rule={keyword:keyword,definition:definition,custom:true,code:customRuleCode,implements:definition.implements};ruleGroup.rules.push(rule);RULES.custom[keyword]=rule}return this}function getKeyword(keyword){var rule=this.RULES.custom[keyword];return rule?rule.definition:this.RULES.keywords[keyword]||false}function removeKeyword(keyword){var RULES=this.RULES;delete RULES.keywords[keyword];delete RULES.all[keyword];delete RULES.custom[keyword];for(var i=0;i<RULES.length;i++){var rules=RULES[i].rules;for(var j=0;j<rules.length;j++){if(rules[j].keyword==keyword){rules.splice(j,1);break}}}return this}function validateKeyword(definition,throwError){validateKeyword.errors=null;var v=this._validateKeyword=this._validateKeyword||this.compile(definitionSchema,true);if(v(definition))return true;validateKeyword.errors=v.errors;if(throwError)throw new Error("custom keyword definition is invalid: "+this.errorsText(v.errors));else return false}},{"./definition_schema":12,"./dotjs/custom":22}],40:[function(require,module,exports){module.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON Schema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:false}},{}],41:[function(require,module,exports){module.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:true,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:true,readOnly:{type:"boolean",default:false},examples:{type:"array",items:true},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:true},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:false},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:true,enum:{type:"array",items:true,minItems:1,uniqueItems:true},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:true}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:true}},{}],42:[function(require,module,exports){"use strict";module.exports=function equal(a,b){if(a===b)return true;if(a&&b&&typeof a=="object"&&typeof b=="object"){if(a.constructor!==b.constructor)return false;var length,i,keys;if(Array.isArray(a)){length=a.length;if(length!=b.length)return false;for(i=length;i--!==0;)if(!equal(a[i],b[i]))return false;return true}if(a.constructor===RegExp)return a.source===b.source&&a.flags===b.flags;if(a.valueOf!==Object.prototype.valueOf)return a.valueOf()===b.valueOf();if(a.toString!==Object.prototype.toString)return a.toString()===b.toString();keys=Object.keys(a);length=keys.length;if(length!==Object.keys(b).length)return false;for(i=length;i--!==0;)if(!Object.prototype.hasOwnProperty.call(b,keys[i]))return false;for(i=length;i--!==0;){var key=keys[i];if(!equal(a[key],b[key]))return false}return true}return a!==a&&b!==b}},{}],43:[function(require,module,exports){"use strict";module.exports=function(data,opts){if(!opts)opts={};if(typeof opts==="function")opts={cmp:opts};var cycles=typeof opts.cycles==="boolean"?opts.cycles:false;var cmp=opts.cmp&&function(f){return function(node){return function(a,b){var aobj={key:a,value:node[a]};var bobj={key:b,value:node[b]};return f(aobj,bobj)}}}(opts.cmp);var seen=[];return function stringify(node){if(node&&node.toJSON&&typeof node.toJSON==="function"){node=node.toJSON()}if(node===undefined)return;if(typeof node=="number")return isFinite(node)?""+node:"null";if(typeof node!=="object")return JSON.stringify(node);var i,out;if(Array.isArray(node)){out="[";for(i=0;i<node.length;i++){if(i)out+=",";out+=stringify(node[i])||"null"}return out+"]"}if(node===null)return"null";if(seen.indexOf(node)!==-1){if(cycles)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var seenIndex=seen.push(node)-1;var keys=Object.keys(node).sort(cmp&&cmp(node));out="";for(i=0;i<keys.length;i++){var key=keys[i];var value=stringify(node[key]);if(!value)continue;if(out)out+=",";out+=JSON.stringify(key)+":"+value}seen.splice(seenIndex,1);return"{"+out+"}"}(data)}},{}],44:[function(require,module,exports){"use strict";var traverse=module.exports=function(schema,opts,cb){if(typeof opts=="function"){cb=opts;opts={}}cb=opts.cb||cb;var pre=typeof cb=="function"?cb:cb.pre||function(){};var post=cb.post||function(){};_traverse(opts,pre,post,schema,"",schema)};traverse.keywords={additionalItems:true,items:true,contains:true,additionalProperties:true,propertyNames:true,not:true};traverse.arrayKeywords={items:true,allOf:true,anyOf:true,oneOf:true};traverse.propsKeywords={definitions:true,properties:true,patternProperties:true,dependencies:true};traverse.skipKeywords={default:true,enum:true,const:true,required:true,maximum:true,minimum:true,exclusiveMaximum:true,exclusiveMinimum:true,multipleOf:true,maxLength:true,minLength:true,pattern:true,format:true,maxItems:true,minItems:true,uniqueItems:true,maxProperties:true,minProperties:true};function _traverse(opts,pre,post,schema,jsonPtr,rootSchema,parentJsonPtr,parentKeyword,parentSchema,keyIndex){if(schema&&typeof schema=="object"&&!Array.isArray(schema)){pre(schema,jsonPtr,rootSchema,parentJsonPtr,parentKeyword,parentSchema,keyIndex);for(var key in schema){var sch=schema[key];if(Array.isArray(sch)){if(key in traverse.arrayKeywords){for(var i=0;i<sch.length;i++)_traverse(opts,pre,post,sch[i],jsonPtr+"/"+key+"/"+i,rootSchema,jsonPtr,key,schema,i)}}else if(key in traverse.propsKeywords){if(sch&&typeof sch=="object"){for(var prop in sch)_traverse(opts,pre,post,sch[prop],jsonPtr+"/"+key+"/"+escapeJsonPtr(prop),rootSchema,jsonPtr,key,schema,prop)}}else if(key in traverse.keywords||opts.allKeys&&!(key in traverse.skipKeywords)){_traverse(opts,pre,post,sch,jsonPtr+"/"+key,rootSchema,jsonPtr,key,schema)}}post(schema,jsonPtr,rootSchema,parentJsonPtr,parentKeyword,parentSchema,keyIndex)}}function escapeJsonPtr(str){return str.replace(/~/g,"~0").replace(/\//g,"~1")}},{}],45:[function(require,module,exports){
2
- /** @license URI.js v4.4.0 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */
3
- (function(global,factory){typeof exports==="object"&&typeof module!=="undefined"?factory(exports):typeof define==="function"&&define.amd?define(["exports"],factory):factory(global.URI=global.URI||{})})(this,(function(exports){"use strict";function merge(){for(var _len=arguments.length,sets=Array(_len),_key=0;_key<_len;_key++){sets[_key]=arguments[_key]}if(sets.length>1){sets[0]=sets[0].slice(0,-1);var xl=sets.length-1;for(var x=1;x<xl;++x){sets[x]=sets[x].slice(1,-1)}sets[xl]=sets[xl].slice(1);return sets.join("")}else{return sets[0]}}function subexp(str){return"(?:"+str+")"}function typeOf(o){return o===undefined?"undefined":o===null?"null":Object.prototype.toString.call(o).split(" ").pop().split("]").shift().toLowerCase()}function toUpperCase(str){return str.toUpperCase()}function toArray(obj){return obj!==undefined&&obj!==null?obj instanceof Array?obj:typeof obj.length!=="number"||obj.split||obj.setInterval||obj.call?[obj]:Array.prototype.slice.call(obj):[]}function assign(target,source){var obj=target;if(source){for(var key in source){obj[key]=source[key]}}return obj}function buildExps(isIRI){var ALPHA$$="[A-Za-z]",CR$="[\\x0D]",DIGIT$$="[0-9]",DQUOTE$$="[\\x22]",HEXDIG$$=merge(DIGIT$$,"[A-Fa-f]"),LF$$="[\\x0A]",SP$$="[\\x20]",PCT_ENCODED$=subexp(subexp("%[EFef]"+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$)+"|"+subexp("%[89A-Fa-f]"+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$)+"|"+subexp("%"+HEXDIG$$+HEXDIG$$)),GEN_DELIMS$$="[\\:\\/\\?\\#\\[\\]\\@]",SUB_DELIMS$$="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",RESERVED$$=merge(GEN_DELIMS$$,SUB_DELIMS$$),UCSCHAR$$=isIRI?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",IPRIVATE$$=isIRI?"[\\uE000-\\uF8FF]":"[]",UNRESERVED$$=merge(ALPHA$$,DIGIT$$,"[\\-\\.\\_\\~]",UCSCHAR$$),SCHEME$=subexp(ALPHA$$+merge(ALPHA$$,DIGIT$$,"[\\+\\-\\.]")+"*"),USERINFO$=subexp(subexp(PCT_ENCODED$+"|"+merge(UNRESERVED$$,SUB_DELIMS$$,"[\\:]"))+"*"),DEC_OCTET$=subexp(subexp("25[0-5]")+"|"+subexp("2[0-4]"+DIGIT$$)+"|"+subexp("1"+DIGIT$$+DIGIT$$)+"|"+subexp("[1-9]"+DIGIT$$)+"|"+DIGIT$$),DEC_OCTET_RELAXED$=subexp(subexp("25[0-5]")+"|"+subexp("2[0-4]"+DIGIT$$)+"|"+subexp("1"+DIGIT$$+DIGIT$$)+"|"+subexp("0?[1-9]"+DIGIT$$)+"|0?0?"+DIGIT$$),IPV4ADDRESS$=subexp(DEC_OCTET_RELAXED$+"\\."+DEC_OCTET_RELAXED$+"\\."+DEC_OCTET_RELAXED$+"\\."+DEC_OCTET_RELAXED$),H16$=subexp(HEXDIG$$+"{1,4}"),LS32$=subexp(subexp(H16$+"\\:"+H16$)+"|"+IPV4ADDRESS$),IPV6ADDRESS1$=subexp(subexp(H16$+"\\:")+"{6}"+LS32$),IPV6ADDRESS2$=subexp("\\:\\:"+subexp(H16$+"\\:")+"{5}"+LS32$),IPV6ADDRESS3$=subexp(subexp(H16$)+"?\\:\\:"+subexp(H16$+"\\:")+"{4}"+LS32$),IPV6ADDRESS4$=subexp(subexp(subexp(H16$+"\\:")+"{0,1}"+H16$)+"?\\:\\:"+subexp(H16$+"\\:")+"{3}"+LS32$),IPV6ADDRESS5$=subexp(subexp(subexp(H16$+"\\:")+"{0,2}"+H16$)+"?\\:\\:"+subexp(H16$+"\\:")+"{2}"+LS32$),IPV6ADDRESS6$=subexp(subexp(subexp(H16$+"\\:")+"{0,3}"+H16$)+"?\\:\\:"+H16$+"\\:"+LS32$),IPV6ADDRESS7$=subexp(subexp(subexp(H16$+"\\:")+"{0,4}"+H16$)+"?\\:\\:"+LS32$),IPV6ADDRESS8$=subexp(subexp(subexp(H16$+"\\:")+"{0,5}"+H16$)+"?\\:\\:"+H16$),IPV6ADDRESS9$=subexp(subexp(subexp(H16$+"\\:")+"{0,6}"+H16$)+"?\\:\\:"),IPV6ADDRESS$=subexp([IPV6ADDRESS1$,IPV6ADDRESS2$,IPV6ADDRESS3$,IPV6ADDRESS4$,IPV6ADDRESS5$,IPV6ADDRESS6$,IPV6ADDRESS7$,IPV6ADDRESS8$,IPV6ADDRESS9$].join("|")),ZONEID$=subexp(subexp(UNRESERVED$$+"|"+PCT_ENCODED$)+"+"),IPV6ADDRZ$=subexp(IPV6ADDRESS$+"\\%25"+ZONEID$),IPV6ADDRZ_RELAXED$=subexp(IPV6ADDRESS$+subexp("\\%25|\\%(?!"+HEXDIG$$+"{2})")+ZONEID$),IPVFUTURE$=subexp("[vV]"+HEXDIG$$+"+\\."+merge(UNRESERVED$$,SUB_DELIMS$$,"[\\:]")+"+"),IP_LITERAL$=subexp("\\["+subexp(IPV6ADDRZ_RELAXED$+"|"+IPV6ADDRESS$+"|"+IPVFUTURE$)+"\\]"),REG_NAME$=subexp(subexp(PCT_ENCODED$+"|"+merge(UNRESERVED$$,SUB_DELIMS$$))+"*"),HOST$=subexp(IP_LITERAL$+"|"+IPV4ADDRESS$+"(?!"+REG_NAME$+")"+"|"+REG_NAME$),PORT$=subexp(DIGIT$$+"*"),AUTHORITY$=subexp(subexp(USERINFO$+"@")+"?"+HOST$+subexp("\\:"+PORT$)+"?"),PCHAR$=subexp(PCT_ENCODED$+"|"+merge(UNRESERVED$$,SUB_DELIMS$$,"[\\:\\@]")),SEGMENT$=subexp(PCHAR$+"*"),SEGMENT_NZ$=subexp(PCHAR$+"+"),SEGMENT_NZ_NC$=subexp(subexp(PCT_ENCODED$+"|"+merge(UNRESERVED$$,SUB_DELIMS$$,"[\\@]"))+"+"),PATH_ABEMPTY$=subexp(subexp("\\/"+SEGMENT$)+"*"),PATH_ABSOLUTE$=subexp("\\/"+subexp(SEGMENT_NZ$+PATH_ABEMPTY$)+"?"),PATH_NOSCHEME$=subexp(SEGMENT_NZ_NC$+PATH_ABEMPTY$),PATH_ROOTLESS$=subexp(SEGMENT_NZ$+PATH_ABEMPTY$),PATH_EMPTY$="(?!"+PCHAR$+")",PATH$=subexp(PATH_ABEMPTY$+"|"+PATH_ABSOLUTE$+"|"+PATH_NOSCHEME$+"|"+PATH_ROOTLESS$+"|"+PATH_EMPTY$),QUERY$=subexp(subexp(PCHAR$+"|"+merge("[\\/\\?]",IPRIVATE$$))+"*"),FRAGMENT$=subexp(subexp(PCHAR$+"|[\\/\\?]")+"*"),HIER_PART$=subexp(subexp("\\/\\/"+AUTHORITY$+PATH_ABEMPTY$)+"|"+PATH_ABSOLUTE$+"|"+PATH_ROOTLESS$+"|"+PATH_EMPTY$),URI$=subexp(SCHEME$+"\\:"+HIER_PART$+subexp("\\?"+QUERY$)+"?"+subexp("\\#"+FRAGMENT$)+"?"),RELATIVE_PART$=subexp(subexp("\\/\\/"+AUTHORITY$+PATH_ABEMPTY$)+"|"+PATH_ABSOLUTE$+"|"+PATH_NOSCHEME$+"|"+PATH_EMPTY$),RELATIVE$=subexp(RELATIVE_PART$+subexp("\\?"+QUERY$)+"?"+subexp("\\#"+FRAGMENT$)+"?"),URI_REFERENCE$=subexp(URI$+"|"+RELATIVE$),ABSOLUTE_URI$=subexp(SCHEME$+"\\:"+HIER_PART$+subexp("\\?"+QUERY$)+"?"),GENERIC_REF$="^("+SCHEME$+")\\:"+subexp(subexp("\\/\\/("+subexp("("+USERINFO$+")@")+"?("+HOST$+")"+subexp("\\:("+PORT$+")")+"?)")+"?("+PATH_ABEMPTY$+"|"+PATH_ABSOLUTE$+"|"+PATH_ROOTLESS$+"|"+PATH_EMPTY$+")")+subexp("\\?("+QUERY$+")")+"?"+subexp("\\#("+FRAGMENT$+")")+"?$",RELATIVE_REF$="^(){0}"+subexp(subexp("\\/\\/("+subexp("("+USERINFO$+")@")+"?("+HOST$+")"+subexp("\\:("+PORT$+")")+"?)")+"?("+PATH_ABEMPTY$+"|"+PATH_ABSOLUTE$+"|"+PATH_NOSCHEME$+"|"+PATH_EMPTY$+")")+subexp("\\?("+QUERY$+")")+"?"+subexp("\\#("+FRAGMENT$+")")+"?$",ABSOLUTE_REF$="^("+SCHEME$+")\\:"+subexp(subexp("\\/\\/("+subexp("("+USERINFO$+")@")+"?("+HOST$+")"+subexp("\\:("+PORT$+")")+"?)")+"?("+PATH_ABEMPTY$+"|"+PATH_ABSOLUTE$+"|"+PATH_ROOTLESS$+"|"+PATH_EMPTY$+")")+subexp("\\?("+QUERY$+")")+"?$",SAMEDOC_REF$="^"+subexp("\\#("+FRAGMENT$+")")+"?$",AUTHORITY_REF$="^"+subexp("("+USERINFO$+")@")+"?("+HOST$+")"+subexp("\\:("+PORT$+")")+"?$";return{NOT_SCHEME:new RegExp(merge("[^]",ALPHA$$,DIGIT$$,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(merge("[^\\%\\:]",UNRESERVED$$,SUB_DELIMS$$),"g"),NOT_HOST:new RegExp(merge("[^\\%\\[\\]\\:]",UNRESERVED$$,SUB_DELIMS$$),"g"),NOT_PATH:new RegExp(merge("[^\\%\\/\\:\\@]",UNRESERVED$$,SUB_DELIMS$$),"g"),NOT_PATH_NOSCHEME:new RegExp(merge("[^\\%\\/\\@]",UNRESERVED$$,SUB_DELIMS$$),"g"),NOT_QUERY:new RegExp(merge("[^\\%]",UNRESERVED$$,SUB_DELIMS$$,"[\\:\\@\\/\\?]",IPRIVATE$$),"g"),NOT_FRAGMENT:new RegExp(merge("[^\\%]",UNRESERVED$$,SUB_DELIMS$$,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(merge("[^]",UNRESERVED$$,SUB_DELIMS$$),"g"),UNRESERVED:new RegExp(UNRESERVED$$,"g"),OTHER_CHARS:new RegExp(merge("[^\\%]",UNRESERVED$$,RESERVED$$),"g"),PCT_ENCODED:new RegExp(PCT_ENCODED$,"g"),IPV4ADDRESS:new RegExp("^("+IPV4ADDRESS$+")$"),IPV6ADDRESS:new RegExp("^\\[?("+IPV6ADDRESS$+")"+subexp(subexp("\\%25|\\%(?!"+HEXDIG$$+"{2})")+"("+ZONEID$+")")+"?\\]?$")}}var URI_PROTOCOL=buildExps(false);var IRI_PROTOCOL=buildExps(true);var slicedToArray=function(){function sliceIterator(arr,i){var _arr=[];var _n=true;var _d=false;var _e=undefined;try{for(var _i=arr[Symbol.iterator](),_s;!(_n=(_s=_i.next()).done);_n=true){_arr.push(_s.value);if(i&&_arr.length===i)break}}catch(err){_d=true;_e=err}finally{try{if(!_n&&_i["return"])_i["return"]()}finally{if(_d)throw _e}}return _arr}return function(arr,i){if(Array.isArray(arr)){return arr}else if(Symbol.iterator in Object(arr)){return sliceIterator(arr,i)}else{throw new TypeError("Invalid attempt to destructure non-iterable instance")}}}();var toConsumableArray=function(arr){if(Array.isArray(arr)){for(var i=0,arr2=Array(arr.length);i<arr.length;i++)arr2[i]=arr[i];return arr2}else{return Array.from(arr)}};var maxInt=2147483647;var base=36;var tMin=1;var tMax=26;var skew=38;var damp=700;var initialBias=72;var initialN=128;var delimiter="-";var regexPunycode=/^xn--/;var regexNonASCII=/[^\0-\x7E]/;var regexSeparators=/[\x2E\u3002\uFF0E\uFF61]/g;var errors={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"};var baseMinusTMin=base-tMin;var floor=Math.floor;var stringFromCharCode=String.fromCharCode;function error$1(type){throw new RangeError(errors[type])}function map(array,fn){var result=[];var length=array.length;while(length--){result[length]=fn(array[length])}return result}function mapDomain(string,fn){var parts=string.split("@");var result="";if(parts.length>1){result=parts[0]+"@";string=parts[1]}string=string.replace(regexSeparators,".");var labels=string.split(".");var encoded=map(labels,fn).join(".");return result+encoded}function ucs2decode(string){var output=[];var counter=0;var length=string.length;while(counter<length){var value=string.charCodeAt(counter++);if(value>=55296&&value<=56319&&counter<length){var extra=string.charCodeAt(counter++);if((extra&64512)==56320){output.push(((value&1023)<<10)+(extra&1023)+65536)}else{output.push(value);counter--}}else{output.push(value)}}return output}var ucs2encode=function ucs2encode(array){return String.fromCodePoint.apply(String,toConsumableArray(array))};var basicToDigit=function basicToDigit(codePoint){if(codePoint-48<10){return codePoint-22}if(codePoint-65<26){return codePoint-65}if(codePoint-97<26){return codePoint-97}return base};var digitToBasic=function digitToBasic(digit,flag){return digit+22+75*(digit<26)-((flag!=0)<<5)};var adapt=function adapt(delta,numPoints,firstTime){var k=0;delta=firstTime?floor(delta/damp):delta>>1;delta+=floor(delta/numPoints);for(;delta>baseMinusTMin*tMax>>1;k+=base){delta=floor(delta/baseMinusTMin)}return floor(k+(baseMinusTMin+1)*delta/(delta+skew))};var decode=function decode(input){var output=[];var inputLength=input.length;var i=0;var n=initialN;var bias=initialBias;var basic=input.lastIndexOf(delimiter);if(basic<0){basic=0}for(var j=0;j<basic;++j){if(input.charCodeAt(j)>=128){error$1("not-basic")}output.push(input.charCodeAt(j))}for(var index=basic>0?basic+1:0;index<inputLength;){var oldi=i;for(var w=1,k=base;;k+=base){if(index>=inputLength){error$1("invalid-input")}var digit=basicToDigit(input.charCodeAt(index++));if(digit>=base||digit>floor((maxInt-i)/w)){error$1("overflow")}i+=digit*w;var t=k<=bias?tMin:k>=bias+tMax?tMax:k-bias;if(digit<t){break}var baseMinusT=base-t;if(w>floor(maxInt/baseMinusT)){error$1("overflow")}w*=baseMinusT}var out=output.length+1;bias=adapt(i-oldi,out,oldi==0);if(floor(i/out)>maxInt-n){error$1("overflow")}n+=floor(i/out);i%=out;output.splice(i++,0,n)}return String.fromCodePoint.apply(String,output)};var encode=function encode(input){var output=[];input=ucs2decode(input);var inputLength=input.length;var n=initialN;var delta=0;var bias=initialBias;var _iteratorNormalCompletion=true;var _didIteratorError=false;var _iteratorError=undefined;try{for(var _iterator=input[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var _currentValue2=_step.value;if(_currentValue2<128){output.push(stringFromCharCode(_currentValue2))}}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}var basicLength=output.length;var handledCPCount=basicLength;if(basicLength){output.push(delimiter)}while(handledCPCount<inputLength){var m=maxInt;var _iteratorNormalCompletion2=true;var _didIteratorError2=false;var _iteratorError2=undefined;try{for(var _iterator2=input[Symbol.iterator](),_step2;!(_iteratorNormalCompletion2=(_step2=_iterator2.next()).done);_iteratorNormalCompletion2=true){var currentValue=_step2.value;if(currentValue>=n&&currentValue<m){m=currentValue}}}catch(err){_didIteratorError2=true;_iteratorError2=err}finally{try{if(!_iteratorNormalCompletion2&&_iterator2.return){_iterator2.return()}}finally{if(_didIteratorError2){throw _iteratorError2}}}var handledCPCountPlusOne=handledCPCount+1;if(m-n>floor((maxInt-delta)/handledCPCountPlusOne)){error$1("overflow")}delta+=(m-n)*handledCPCountPlusOne;n=m;var _iteratorNormalCompletion3=true;var _didIteratorError3=false;var _iteratorError3=undefined;try{for(var _iterator3=input[Symbol.iterator](),_step3;!(_iteratorNormalCompletion3=(_step3=_iterator3.next()).done);_iteratorNormalCompletion3=true){var _currentValue=_step3.value;if(_currentValue<n&&++delta>maxInt){error$1("overflow")}if(_currentValue==n){var q=delta;for(var k=base;;k+=base){var t=k<=bias?tMin:k>=bias+tMax?tMax:k-bias;if(q<t){break}var qMinusT=q-t;var baseMinusT=base-t;output.push(stringFromCharCode(digitToBasic(t+qMinusT%baseMinusT,0)));q=floor(qMinusT/baseMinusT)}output.push(stringFromCharCode(digitToBasic(q,0)));bias=adapt(delta,handledCPCountPlusOne,handledCPCount==basicLength);delta=0;++handledCPCount}}}catch(err){_didIteratorError3=true;_iteratorError3=err}finally{try{if(!_iteratorNormalCompletion3&&_iterator3.return){_iterator3.return()}}finally{if(_didIteratorError3){throw _iteratorError3}}}++delta;++n}return output.join("")};var toUnicode=function toUnicode(input){return mapDomain(input,(function(string){return regexPunycode.test(string)?decode(string.slice(4).toLowerCase()):string}))};var toASCII=function toASCII(input){return mapDomain(input,(function(string){return regexNonASCII.test(string)?"xn--"+encode(string):string}))};var punycode={version:"2.1.0",ucs2:{decode:ucs2decode,encode:ucs2encode},decode:decode,encode:encode,toASCII:toASCII,toUnicode:toUnicode};var SCHEMES={};function pctEncChar(chr){var c=chr.charCodeAt(0);var e=void 0;if(c<16)e="%0"+c.toString(16).toUpperCase();else if(c<128)e="%"+c.toString(16).toUpperCase();else if(c<2048)e="%"+(c>>6|192).toString(16).toUpperCase()+"%"+(c&63|128).toString(16).toUpperCase();else e="%"+(c>>12|224).toString(16).toUpperCase()+"%"+(c>>6&63|128).toString(16).toUpperCase()+"%"+(c&63|128).toString(16).toUpperCase();return e}function pctDecChars(str){var newStr="";var i=0;var il=str.length;while(i<il){var c=parseInt(str.substr(i+1,2),16);if(c<128){newStr+=String.fromCharCode(c);i+=3}else if(c>=194&&c<224){if(il-i>=6){var c2=parseInt(str.substr(i+4,2),16);newStr+=String.fromCharCode((c&31)<<6|c2&63)}else{newStr+=str.substr(i,6)}i+=6}else if(c>=224){if(il-i>=9){var _c=parseInt(str.substr(i+4,2),16);var c3=parseInt(str.substr(i+7,2),16);newStr+=String.fromCharCode((c&15)<<12|(_c&63)<<6|c3&63)}else{newStr+=str.substr(i,9)}i+=9}else{newStr+=str.substr(i,3);i+=3}}return newStr}function _normalizeComponentEncoding(components,protocol){function decodeUnreserved(str){var decStr=pctDecChars(str);return!decStr.match(protocol.UNRESERVED)?str:decStr}if(components.scheme)components.scheme=String(components.scheme).replace(protocol.PCT_ENCODED,decodeUnreserved).toLowerCase().replace(protocol.NOT_SCHEME,"");if(components.userinfo!==undefined)components.userinfo=String(components.userinfo).replace(protocol.PCT_ENCODED,decodeUnreserved).replace(protocol.NOT_USERINFO,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);if(components.host!==undefined)components.host=String(components.host).replace(protocol.PCT_ENCODED,decodeUnreserved).toLowerCase().replace(protocol.NOT_HOST,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);if(components.path!==undefined)components.path=String(components.path).replace(protocol.PCT_ENCODED,decodeUnreserved).replace(components.scheme?protocol.NOT_PATH:protocol.NOT_PATH_NOSCHEME,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);if(components.query!==undefined)components.query=String(components.query).replace(protocol.PCT_ENCODED,decodeUnreserved).replace(protocol.NOT_QUERY,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);if(components.fragment!==undefined)components.fragment=String(components.fragment).replace(protocol.PCT_ENCODED,decodeUnreserved).replace(protocol.NOT_FRAGMENT,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);return components}function _stripLeadingZeros(str){return str.replace(/^0*(.*)/,"$1")||"0"}function _normalizeIPv4(host,protocol){var matches=host.match(protocol.IPV4ADDRESS)||[];var _matches=slicedToArray(matches,2),address=_matches[1];if(address){return address.split(".").map(_stripLeadingZeros).join(".")}else{return host}}function _normalizeIPv6(host,protocol){var matches=host.match(protocol.IPV6ADDRESS)||[];var _matches2=slicedToArray(matches,3),address=_matches2[1],zone=_matches2[2];if(address){var _address$toLowerCase$=address.toLowerCase().split("::").reverse(),_address$toLowerCase$2=slicedToArray(_address$toLowerCase$,2),last=_address$toLowerCase$2[0],first=_address$toLowerCase$2[1];var firstFields=first?first.split(":").map(_stripLeadingZeros):[];var lastFields=last.split(":").map(_stripLeadingZeros);var isLastFieldIPv4Address=protocol.IPV4ADDRESS.test(lastFields[lastFields.length-1]);var fieldCount=isLastFieldIPv4Address?7:8;var lastFieldsStart=lastFields.length-fieldCount;var fields=Array(fieldCount);for(var x=0;x<fieldCount;++x){fields[x]=firstFields[x]||lastFields[lastFieldsStart+x]||""}if(isLastFieldIPv4Address){fields[fieldCount-1]=_normalizeIPv4(fields[fieldCount-1],protocol)}var allZeroFields=fields.reduce((function(acc,field,index){if(!field||field==="0"){var lastLongest=acc[acc.length-1];if(lastLongest&&lastLongest.index+lastLongest.length===index){lastLongest.length++}else{acc.push({index:index,length:1})}}return acc}),[]);var longestZeroFields=allZeroFields.sort((function(a,b){return b.length-a.length}))[0];var newHost=void 0;if(longestZeroFields&&longestZeroFields.length>1){var newFirst=fields.slice(0,longestZeroFields.index);var newLast=fields.slice(longestZeroFields.index+longestZeroFields.length);newHost=newFirst.join(":")+"::"+newLast.join(":")}else{newHost=fields.join(":")}if(zone){newHost+="%"+zone}return newHost}else{return host}}var URI_PARSE=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i;var NO_MATCH_IS_UNDEFINED="".match(/(){0}/)[1]===undefined;function parse(uriString){var options=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};var components={};var protocol=options.iri!==false?IRI_PROTOCOL:URI_PROTOCOL;if(options.reference==="suffix")uriString=(options.scheme?options.scheme+":":"")+"//"+uriString;var matches=uriString.match(URI_PARSE);if(matches){if(NO_MATCH_IS_UNDEFINED){components.scheme=matches[1];components.userinfo=matches[3];components.host=matches[4];components.port=parseInt(matches[5],10);components.path=matches[6]||"";components.query=matches[7];components.fragment=matches[8];if(isNaN(components.port)){components.port=matches[5]}}else{components.scheme=matches[1]||undefined;components.userinfo=uriString.indexOf("@")!==-1?matches[3]:undefined;components.host=uriString.indexOf("//")!==-1?matches[4]:undefined;components.port=parseInt(matches[5],10);components.path=matches[6]||"";components.query=uriString.indexOf("?")!==-1?matches[7]:undefined;components.fragment=uriString.indexOf("#")!==-1?matches[8]:undefined;if(isNaN(components.port)){components.port=uriString.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?matches[4]:undefined}}if(components.host){components.host=_normalizeIPv6(_normalizeIPv4(components.host,protocol),protocol)}if(components.scheme===undefined&&components.userinfo===undefined&&components.host===undefined&&components.port===undefined&&!components.path&&components.query===undefined){components.reference="same-document"}else if(components.scheme===undefined){components.reference="relative"}else if(components.fragment===undefined){components.reference="absolute"}else{components.reference="uri"}if(options.reference&&options.reference!=="suffix"&&options.reference!==components.reference){components.error=components.error||"URI is not a "+options.reference+" reference."}var schemeHandler=SCHEMES[(options.scheme||components.scheme||"").toLowerCase()];if(!options.unicodeSupport&&(!schemeHandler||!schemeHandler.unicodeSupport)){if(components.host&&(options.domainHost||schemeHandler&&schemeHandler.domainHost)){try{components.host=punycode.toASCII(components.host.replace(protocol.PCT_ENCODED,pctDecChars).toLowerCase())}catch(e){components.error=components.error||"Host's domain name can not be converted to ASCII via punycode: "+e}}_normalizeComponentEncoding(components,URI_PROTOCOL)}else{_normalizeComponentEncoding(components,protocol)}if(schemeHandler&&schemeHandler.parse){schemeHandler.parse(components,options)}}else{components.error=components.error||"URI can not be parsed."}return components}function _recomposeAuthority(components,options){var protocol=options.iri!==false?IRI_PROTOCOL:URI_PROTOCOL;var uriTokens=[];if(components.userinfo!==undefined){uriTokens.push(components.userinfo);uriTokens.push("@")}if(components.host!==undefined){uriTokens.push(_normalizeIPv6(_normalizeIPv4(String(components.host),protocol),protocol).replace(protocol.IPV6ADDRESS,(function(_,$1,$2){return"["+$1+($2?"%25"+$2:"")+"]"})))}if(typeof components.port==="number"||typeof components.port==="string"){uriTokens.push(":");uriTokens.push(String(components.port))}return uriTokens.length?uriTokens.join(""):undefined}var RDS1=/^\.\.?\//;var RDS2=/^\/\.(\/|$)/;var RDS3=/^\/\.\.(\/|$)/;var RDS5=/^\/?(?:.|\n)*?(?=\/|$)/;function removeDotSegments(input){var output=[];while(input.length){if(input.match(RDS1)){input=input.replace(RDS1,"")}else if(input.match(RDS2)){input=input.replace(RDS2,"/")}else if(input.match(RDS3)){input=input.replace(RDS3,"/");output.pop()}else if(input==="."||input===".."){input=""}else{var im=input.match(RDS5);if(im){var s=im[0];input=input.slice(s.length);output.push(s)}else{throw new Error("Unexpected dot segment condition")}}}return output.join("")}function serialize(components){var options=arguments.length>1&&arguments[1]!==undefined?arguments[1]:{};var protocol=options.iri?IRI_PROTOCOL:URI_PROTOCOL;var uriTokens=[];var schemeHandler=SCHEMES[(options.scheme||components.scheme||"").toLowerCase()];if(schemeHandler&&schemeHandler.serialize)schemeHandler.serialize(components,options);if(components.host){if(protocol.IPV6ADDRESS.test(components.host)){}else if(options.domainHost||schemeHandler&&schemeHandler.domainHost){try{components.host=!options.iri?punycode.toASCII(components.host.replace(protocol.PCT_ENCODED,pctDecChars).toLowerCase()):punycode.toUnicode(components.host)}catch(e){components.error=components.error||"Host's domain name can not be converted to "+(!options.iri?"ASCII":"Unicode")+" via punycode: "+e}}}_normalizeComponentEncoding(components,protocol);if(options.reference!=="suffix"&&components.scheme){uriTokens.push(components.scheme);uriTokens.push(":")}var authority=_recomposeAuthority(components,options);if(authority!==undefined){if(options.reference!=="suffix"){uriTokens.push("//")}uriTokens.push(authority);if(components.path&&components.path.charAt(0)!=="/"){uriTokens.push("/")}}if(components.path!==undefined){var s=components.path;if(!options.absolutePath&&(!schemeHandler||!schemeHandler.absolutePath)){s=removeDotSegments(s)}if(authority===undefined){s=s.replace(/^\/\//,"/%2F")}uriTokens.push(s)}if(components.query!==undefined){uriTokens.push("?");uriTokens.push(components.query)}if(components.fragment!==undefined){uriTokens.push("#");uriTokens.push(components.fragment)}return uriTokens.join("")}function resolveComponents(base,relative){var options=arguments.length>2&&arguments[2]!==undefined?arguments[2]:{};var skipNormalization=arguments[3];var target={};if(!skipNormalization){base=parse(serialize(base,options),options);relative=parse(serialize(relative,options),options)}options=options||{};if(!options.tolerant&&relative.scheme){target.scheme=relative.scheme;target.userinfo=relative.userinfo;target.host=relative.host;target.port=relative.port;target.path=removeDotSegments(relative.path||"");target.query=relative.query}else{if(relative.userinfo!==undefined||relative.host!==undefined||relative.port!==undefined){target.userinfo=relative.userinfo;target.host=relative.host;target.port=relative.port;target.path=removeDotSegments(relative.path||"");target.query=relative.query}else{if(!relative.path){target.path=base.path;if(relative.query!==undefined){target.query=relative.query}else{target.query=base.query}}else{if(relative.path.charAt(0)==="/"){target.path=removeDotSegments(relative.path)}else{if((base.userinfo!==undefined||base.host!==undefined||base.port!==undefined)&&!base.path){target.path="/"+relative.path}else if(!base.path){target.path=relative.path}else{target.path=base.path.slice(0,base.path.lastIndexOf("/")+1)+relative.path}target.path=removeDotSegments(target.path)}target.query=relative.query}target.userinfo=base.userinfo;target.host=base.host;target.port=base.port}target.scheme=base.scheme}target.fragment=relative.fragment;return target}function resolve(baseURI,relativeURI,options){var schemelessOptions=assign({scheme:"null"},options);return serialize(resolveComponents(parse(baseURI,schemelessOptions),parse(relativeURI,schemelessOptions),schemelessOptions,true),schemelessOptions)}function normalize(uri,options){if(typeof uri==="string"){uri=serialize(parse(uri,options),options)}else if(typeOf(uri)==="object"){uri=parse(serialize(uri,options),options)}return uri}function equal(uriA,uriB,options){if(typeof uriA==="string"){uriA=serialize(parse(uriA,options),options)}else if(typeOf(uriA)==="object"){uriA=serialize(uriA,options)}if(typeof uriB==="string"){uriB=serialize(parse(uriB,options),options)}else if(typeOf(uriB)==="object"){uriB=serialize(uriB,options)}return uriA===uriB}function escapeComponent(str,options){return str&&str.toString().replace(!options||!options.iri?URI_PROTOCOL.ESCAPE:IRI_PROTOCOL.ESCAPE,pctEncChar)}function unescapeComponent(str,options){return str&&str.toString().replace(!options||!options.iri?URI_PROTOCOL.PCT_ENCODED:IRI_PROTOCOL.PCT_ENCODED,pctDecChars)}var handler={scheme:"http",domainHost:true,parse:function parse(components,options){if(!components.host){components.error=components.error||"HTTP URIs must have a host."}return components},serialize:function serialize(components,options){var secure=String(components.scheme).toLowerCase()==="https";if(components.port===(secure?443:80)||components.port===""){components.port=undefined}if(!components.path){components.path="/"}return components}};var handler$1={scheme:"https",domainHost:handler.domainHost,parse:handler.parse,serialize:handler.serialize};function isSecure(wsComponents){return typeof wsComponents.secure==="boolean"?wsComponents.secure:String(wsComponents.scheme).toLowerCase()==="wss"}var handler$2={scheme:"ws",domainHost:true,parse:function parse(components,options){var wsComponents=components;wsComponents.secure=isSecure(wsComponents);wsComponents.resourceName=(wsComponents.path||"/")+(wsComponents.query?"?"+wsComponents.query:"");wsComponents.path=undefined;wsComponents.query=undefined;return wsComponents},serialize:function serialize(wsComponents,options){if(wsComponents.port===(isSecure(wsComponents)?443:80)||wsComponents.port===""){wsComponents.port=undefined}if(typeof wsComponents.secure==="boolean"){wsComponents.scheme=wsComponents.secure?"wss":"ws";wsComponents.secure=undefined}if(wsComponents.resourceName){var _wsComponents$resourc=wsComponents.resourceName.split("?"),_wsComponents$resourc2=slicedToArray(_wsComponents$resourc,2),path=_wsComponents$resourc2[0],query=_wsComponents$resourc2[1];wsComponents.path=path&&path!=="/"?path:undefined;wsComponents.query=query;wsComponents.resourceName=undefined}wsComponents.fragment=undefined;return wsComponents}};var handler$3={scheme:"wss",domainHost:handler$2.domainHost,parse:handler$2.parse,serialize:handler$2.serialize};var O={};var isIRI=true;var UNRESERVED$$="[A-Za-z0-9\\-\\.\\_\\~"+(isIRI?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]";var HEXDIG$$="[0-9A-Fa-f]";var PCT_ENCODED$=subexp(subexp("%[EFef]"+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$)+"|"+subexp("%[89A-Fa-f]"+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$)+"|"+subexp("%"+HEXDIG$$+HEXDIG$$));var ATEXT$$="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]";var QTEXT$$="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]";var VCHAR$$=merge(QTEXT$$,'[\\"\\\\]');var SOME_DELIMS$$="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]";var UNRESERVED=new RegExp(UNRESERVED$$,"g");var PCT_ENCODED=new RegExp(PCT_ENCODED$,"g");var NOT_LOCAL_PART=new RegExp(merge("[^]",ATEXT$$,"[\\.]",'[\\"]',VCHAR$$),"g");var NOT_HFNAME=new RegExp(merge("[^]",UNRESERVED$$,SOME_DELIMS$$),"g");var NOT_HFVALUE=NOT_HFNAME;function decodeUnreserved(str){var decStr=pctDecChars(str);return!decStr.match(UNRESERVED)?str:decStr}var handler$4={scheme:"mailto",parse:function parse$$1(components,options){var mailtoComponents=components;var to=mailtoComponents.to=mailtoComponents.path?mailtoComponents.path.split(","):[];mailtoComponents.path=undefined;if(mailtoComponents.query){var unknownHeaders=false;var headers={};var hfields=mailtoComponents.query.split("&");for(var x=0,xl=hfields.length;x<xl;++x){var hfield=hfields[x].split("=");switch(hfield[0]){case"to":var toAddrs=hfield[1].split(",");for(var _x=0,_xl=toAddrs.length;_x<_xl;++_x){to.push(toAddrs[_x])}break;case"subject":mailtoComponents.subject=unescapeComponent(hfield[1],options);break;case"body":mailtoComponents.body=unescapeComponent(hfield[1],options);break;default:unknownHeaders=true;headers[unescapeComponent(hfield[0],options)]=unescapeComponent(hfield[1],options);break}}if(unknownHeaders)mailtoComponents.headers=headers}mailtoComponents.query=undefined;for(var _x2=0,_xl2=to.length;_x2<_xl2;++_x2){var addr=to[_x2].split("@");addr[0]=unescapeComponent(addr[0]);if(!options.unicodeSupport){try{addr[1]=punycode.toASCII(unescapeComponent(addr[1],options).toLowerCase())}catch(e){mailtoComponents.error=mailtoComponents.error||"Email address's domain name can not be converted to ASCII via punycode: "+e}}else{addr[1]=unescapeComponent(addr[1],options).toLowerCase()}to[_x2]=addr.join("@")}return mailtoComponents},serialize:function serialize$$1(mailtoComponents,options){var components=mailtoComponents;var to=toArray(mailtoComponents.to);if(to){for(var x=0,xl=to.length;x<xl;++x){var toAddr=String(to[x]);var atIdx=toAddr.lastIndexOf("@");var localPart=toAddr.slice(0,atIdx).replace(PCT_ENCODED,decodeUnreserved).replace(PCT_ENCODED,toUpperCase).replace(NOT_LOCAL_PART,pctEncChar);var domain=toAddr.slice(atIdx+1);try{domain=!options.iri?punycode.toASCII(unescapeComponent(domain,options).toLowerCase()):punycode.toUnicode(domain)}catch(e){components.error=components.error||"Email address's domain name can not be converted to "+(!options.iri?"ASCII":"Unicode")+" via punycode: "+e}to[x]=localPart+"@"+domain}components.path=to.join(",")}var headers=mailtoComponents.headers=mailtoComponents.headers||{};if(mailtoComponents.subject)headers["subject"]=mailtoComponents.subject;if(mailtoComponents.body)headers["body"]=mailtoComponents.body;var fields=[];for(var name in headers){if(headers[name]!==O[name]){fields.push(name.replace(PCT_ENCODED,decodeUnreserved).replace(PCT_ENCODED,toUpperCase).replace(NOT_HFNAME,pctEncChar)+"="+headers[name].replace(PCT_ENCODED,decodeUnreserved).replace(PCT_ENCODED,toUpperCase).replace(NOT_HFVALUE,pctEncChar))}}if(fields.length){components.query=fields.join("&")}return components}};var URN_PARSE=/^([^\:]+)\:(.*)/;var handler$5={scheme:"urn",parse:function parse$$1(components,options){var matches=components.path&&components.path.match(URN_PARSE);var urnComponents=components;if(matches){var scheme=options.scheme||urnComponents.scheme||"urn";var nid=matches[1].toLowerCase();var nss=matches[2];var urnScheme=scheme+":"+(options.nid||nid);var schemeHandler=SCHEMES[urnScheme];urnComponents.nid=nid;urnComponents.nss=nss;urnComponents.path=undefined;if(schemeHandler){urnComponents=schemeHandler.parse(urnComponents,options)}}else{urnComponents.error=urnComponents.error||"URN can not be parsed."}return urnComponents},serialize:function serialize$$1(urnComponents,options){var scheme=options.scheme||urnComponents.scheme||"urn";var nid=urnComponents.nid;var urnScheme=scheme+":"+(options.nid||nid);var schemeHandler=SCHEMES[urnScheme];if(schemeHandler){urnComponents=schemeHandler.serialize(urnComponents,options)}var uriComponents=urnComponents;var nss=urnComponents.nss;uriComponents.path=(nid||options.nid)+":"+nss;return uriComponents}};var UUID=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;var handler$6={scheme:"urn:uuid",parse:function parse(urnComponents,options){var uuidComponents=urnComponents;uuidComponents.uuid=uuidComponents.nss;uuidComponents.nss=undefined;if(!options.tolerant&&(!uuidComponents.uuid||!uuidComponents.uuid.match(UUID))){uuidComponents.error=uuidComponents.error||"UUID is not valid."}return uuidComponents},serialize:function serialize(uuidComponents,options){var urnComponents=uuidComponents;urnComponents.nss=(uuidComponents.uuid||"").toLowerCase();return urnComponents}};SCHEMES[handler.scheme]=handler;SCHEMES[handler$1.scheme]=handler$1;SCHEMES[handler$2.scheme]=handler$2;SCHEMES[handler$3.scheme]=handler$3;SCHEMES[handler$4.scheme]=handler$4;SCHEMES[handler$5.scheme]=handler$5;SCHEMES[handler$6.scheme]=handler$6;exports.SCHEMES=SCHEMES;exports.pctEncChar=pctEncChar;exports.pctDecChars=pctDecChars;exports.parse=parse;exports.removeDotSegments=removeDotSegments;exports.serialize=serialize;exports.resolveComponents=resolveComponents;exports.resolve=resolve;exports.normalize=normalize;exports.equal=equal;exports.escapeComponent=escapeComponent;exports.unescapeComponent=unescapeComponent;Object.defineProperty(exports,"__esModule",{value:true})}))},{}],ajv:[function(require,module,exports){"use strict";var compileSchema=require("./compile"),resolve=require("./compile/resolve"),Cache=require("./cache"),SchemaObject=require("./compile/schema_obj"),stableStringify=require("fast-json-stable-stringify"),formats=require("./compile/formats"),rules=require("./compile/rules"),$dataMetaSchema=require("./data"),util=require("./compile/util");module.exports=Ajv;Ajv.prototype.validate=validate;Ajv.prototype.compile=compile;Ajv.prototype.addSchema=addSchema;Ajv.prototype.addMetaSchema=addMetaSchema;Ajv.prototype.validateSchema=validateSchema;Ajv.prototype.getSchema=getSchema;Ajv.prototype.removeSchema=removeSchema;Ajv.prototype.addFormat=addFormat;Ajv.prototype.errorsText=errorsText;Ajv.prototype._addSchema=_addSchema;Ajv.prototype._compile=_compile;Ajv.prototype.compileAsync=require("./compile/async");var customKeyword=require("./keyword");Ajv.prototype.addKeyword=customKeyword.add;Ajv.prototype.getKeyword=customKeyword.get;Ajv.prototype.removeKeyword=customKeyword.remove;Ajv.prototype.validateKeyword=customKeyword.validate;var errorClasses=require("./compile/error_classes");Ajv.ValidationError=errorClasses.Validation;Ajv.MissingRefError=errorClasses.MissingRef;Ajv.$dataMetaSchema=$dataMetaSchema;var META_SCHEMA_ID="http://json-schema.org/draft-07/schema";var META_IGNORE_OPTIONS=["removeAdditional","useDefaults","coerceTypes","strictDefaults"];var META_SUPPORT_DATA=["/properties"];function Ajv(opts){if(!(this instanceof Ajv))return new Ajv(opts);opts=this._opts=util.copy(opts)||{};setLogger(this);this._schemas={};this._refs={};this._fragments={};this._formats=formats(opts.format);this._cache=opts.cache||new Cache;this._loadingSchemas={};this._compilations=[];this.RULES=rules();this._getId=chooseGetId(opts);opts.loopRequired=opts.loopRequired||Infinity;if(opts.errorDataPath=="property")opts._errorDataPathProperty=true;if(opts.serialize===undefined)opts.serialize=stableStringify;this._metaOpts=getMetaSchemaOptions(this);if(opts.formats)addInitialFormats(this);if(opts.keywords)addInitialKeywords(this);addDefaultMetaSchema(this);if(typeof opts.meta=="object")this.addMetaSchema(opts.meta);if(opts.nullable)this.addKeyword("nullable",{metaSchema:{type:"boolean"}});addInitialSchemas(this)}function validate(schemaKeyRef,data){var v;if(typeof schemaKeyRef=="string"){v=this.getSchema(schemaKeyRef);if(!v)throw new Error('no schema with key or ref "'+schemaKeyRef+'"')}else{var schemaObj=this._addSchema(schemaKeyRef);v=schemaObj.validate||this._compile(schemaObj)}var valid=v(data);if(v.$async!==true)this.errors=v.errors;return valid}function compile(schema,_meta){var schemaObj=this._addSchema(schema,undefined,_meta);return schemaObj.validate||this._compile(schemaObj)}function addSchema(schema,key,_skipValidation,_meta){if(Array.isArray(schema)){for(var i=0;i<schema.length;i++)this.addSchema(schema[i],undefined,_skipValidation,_meta);return this}var id=this._getId(schema);if(id!==undefined&&typeof id!="string")throw new Error("schema id must be string");key=resolve.normalizeId(key||id);checkUnique(this,key);this._schemas[key]=this._addSchema(schema,_skipValidation,_meta,true);return this}function addMetaSchema(schema,key,skipValidation){this.addSchema(schema,key,skipValidation,true);return this}function validateSchema(schema,throwOrLogError){var $schema=schema.$schema;if($schema!==undefined&&typeof $schema!="string")throw new Error("$schema must be a string");$schema=$schema||this._opts.defaultMeta||defaultMeta(this);if(!$schema){this.logger.warn("meta-schema not available");this.errors=null;return true}var valid=this.validate($schema,schema);if(!valid&&throwOrLogError){var message="schema is invalid: "+this.errorsText();if(this._opts.validateSchema=="log")this.logger.error(message);else throw new Error(message)}return valid}function defaultMeta(self){var meta=self._opts.meta;self._opts.defaultMeta=typeof meta=="object"?self._getId(meta)||meta:self.getSchema(META_SCHEMA_ID)?META_SCHEMA_ID:undefined;return self._opts.defaultMeta}function getSchema(keyRef){var schemaObj=_getSchemaObj(this,keyRef);switch(typeof schemaObj){case"object":return schemaObj.validate||this._compile(schemaObj);case"string":return this.getSchema(schemaObj);case"undefined":return _getSchemaFragment(this,keyRef)}}function _getSchemaFragment(self,ref){var res=resolve.schema.call(self,{schema:{}},ref);if(res){var schema=res.schema,root=res.root,baseId=res.baseId;var v=compileSchema.call(self,schema,root,undefined,baseId);self._fragments[ref]=new SchemaObject({ref:ref,fragment:true,schema:schema,root:root,baseId:baseId,validate:v});return v}}function _getSchemaObj(self,keyRef){keyRef=resolve.normalizeId(keyRef);return self._schemas[keyRef]||self._refs[keyRef]||self._fragments[keyRef]}function removeSchema(schemaKeyRef){if(schemaKeyRef instanceof RegExp){_removeAllSchemas(this,this._schemas,schemaKeyRef);_removeAllSchemas(this,this._refs,schemaKeyRef);return this}switch(typeof schemaKeyRef){case"undefined":_removeAllSchemas(this,this._schemas);_removeAllSchemas(this,this._refs);this._cache.clear();return this;case"string":var schemaObj=_getSchemaObj(this,schemaKeyRef);if(schemaObj)this._cache.del(schemaObj.cacheKey);delete this._schemas[schemaKeyRef];delete this._refs[schemaKeyRef];return this;case"object":var serialize=this._opts.serialize;var cacheKey=serialize?serialize(schemaKeyRef):schemaKeyRef;this._cache.del(cacheKey);var id=this._getId(schemaKeyRef);if(id){id=resolve.normalizeId(id);delete this._schemas[id];delete this._refs[id]}}return this}function _removeAllSchemas(self,schemas,regex){for(var keyRef in schemas){var schemaObj=schemas[keyRef];if(!schemaObj.meta&&(!regex||regex.test(keyRef))){self._cache.del(schemaObj.cacheKey);delete schemas[keyRef]}}}function _addSchema(schema,skipValidation,meta,shouldAddSchema){if(typeof schema!="object"&&typeof schema!="boolean")throw new Error("schema should be object or boolean");var serialize=this._opts.serialize;var cacheKey=serialize?serialize(schema):schema;var cached=this._cache.get(cacheKey);if(cached)return cached;shouldAddSchema=shouldAddSchema||this._opts.addUsedSchema!==false;var id=resolve.normalizeId(this._getId(schema));if(id&&shouldAddSchema)checkUnique(this,id);var willValidate=this._opts.validateSchema!==false&&!skipValidation;var recursiveMeta;if(willValidate&&!(recursiveMeta=id&&id==resolve.normalizeId(schema.$schema)))this.validateSchema(schema,true);var localRefs=resolve.ids.call(this,schema);var schemaObj=new SchemaObject({id:id,schema:schema,localRefs:localRefs,cacheKey:cacheKey,meta:meta});if(id[0]!="#"&&shouldAddSchema)this._refs[id]=schemaObj;this._cache.put(cacheKey,schemaObj);if(willValidate&&recursiveMeta)this.validateSchema(schema,true);return schemaObj}function _compile(schemaObj,root){if(schemaObj.compiling){schemaObj.validate=callValidate;callValidate.schema=schemaObj.schema;callValidate.errors=null;callValidate.root=root?root:callValidate;if(schemaObj.schema.$async===true)callValidate.$async=true;return callValidate}schemaObj.compiling=true;var currentOpts;if(schemaObj.meta){currentOpts=this._opts;this._opts=this._metaOpts}var v;try{v=compileSchema.call(this,schemaObj.schema,root,schemaObj.localRefs)}catch(e){delete schemaObj.validate;throw e}finally{schemaObj.compiling=false;if(schemaObj.meta)this._opts=currentOpts}schemaObj.validate=v;schemaObj.refs=v.refs;schemaObj.refVal=v.refVal;schemaObj.root=v.root;return v;function callValidate(){var _validate=schemaObj.validate;var result=_validate.apply(this,arguments);callValidate.errors=_validate.errors;return result}}function chooseGetId(opts){switch(opts.schemaId){case"auto":return _get$IdOrId;case"id":return _getId;default:return _get$Id}}function _getId(schema){if(schema.$id)this.logger.warn("schema $id ignored",schema.$id);return schema.id}function _get$Id(schema){if(schema.id)this.logger.warn("schema id ignored",schema.id);return schema.$id}function _get$IdOrId(schema){if(schema.$id&&schema.id&&schema.$id!=schema.id)throw new Error("schema $id is different from id");return schema.$id||schema.id}function errorsText(errors,options){errors=errors||this.errors;if(!errors)return"No errors";options=options||{};var separator=options.separator===undefined?", ":options.separator;var dataVar=options.dataVar===undefined?"data":options.dataVar;var text="";for(var i=0;i<errors.length;i++){var e=errors[i];if(e)text+=dataVar+e.dataPath+" "+e.message+separator}return text.slice(0,-separator.length)}function addFormat(name,format){if(typeof format=="string")format=new RegExp(format);this._formats[name]=format;return this}function addDefaultMetaSchema(self){var $dataSchema;if(self._opts.$data){$dataSchema=require("./refs/data.json");self.addMetaSchema($dataSchema,$dataSchema.$id,true)}if(self._opts.meta===false)return;var metaSchema=require("./refs/json-schema-draft-07.json");if(self._opts.$data)metaSchema=$dataMetaSchema(metaSchema,META_SUPPORT_DATA);self.addMetaSchema(metaSchema,META_SCHEMA_ID,true);self._refs["http://json-schema.org/schema"]=META_SCHEMA_ID}function addInitialSchemas(self){var optsSchemas=self._opts.schemas;if(!optsSchemas)return;if(Array.isArray(optsSchemas))self.addSchema(optsSchemas);else for(var key in optsSchemas)self.addSchema(optsSchemas[key],key)}function addInitialFormats(self){for(var name in self._opts.formats){var format=self._opts.formats[name];self.addFormat(name,format)}}function addInitialKeywords(self){for(var name in self._opts.keywords){var keyword=self._opts.keywords[name];self.addKeyword(name,keyword)}}function checkUnique(self,id){if(self._schemas[id]||self._refs[id])throw new Error('schema with key or id "'+id+'" already exists')}function getMetaSchemaOptions(self){var metaOpts=util.copy(self._opts);for(var i=0;i<META_IGNORE_OPTIONS.length;i++)delete metaOpts[META_IGNORE_OPTIONS[i]];return metaOpts}function setLogger(self){var logger=self._opts.logger;if(logger===false){self.logger={log:noop,warn:noop,error:noop}}else{if(logger===undefined)logger=console;if(!(typeof logger=="object"&&logger.log&&logger.warn&&logger.error))throw new Error("logger must implement log, warn and error methods");self.logger=logger}}function noop(){}},{"./cache":1,"./compile":5,"./compile/async":2,"./compile/error_classes":3,"./compile/formats":4,"./compile/resolve":6,"./compile/rules":7,"./compile/schema_obj":8,"./compile/util":10,"./data":11,"./keyword":39,"./refs/data.json":40,"./refs/json-schema-draft-07.json":41,"fast-json-stable-stringify":43}]},{},[])("ajv")}));
4
- //# sourceMappingURL=ajv.min.js.map
1
+ (function(Ue){if(typeof exports=="object"&&typeof module<"u")module.exports=Ue();else if(typeof define=="function"&&define.amd)define([],Ue);else{var Me;typeof window<"u"?Me=window:typeof global<"u"?Me=global:typeof self<"u"?Me=self:Me=this,Me.Ajv=Ue()}})(function(){var Ue,Me,Mr;return function(){function A(U,K,T){function e(r,n){if(!K[r]){if(!U[r]){var S=typeof require=="function"&&require;if(!n&&S)return S(r,!0);if(a)return a(r,!0);var o=new Error("Cannot find module '"+r+"'");throw o.code="MODULE_NOT_FOUND",o}var E=K[r]={exports:{}};U[r][0].call(E.exports,function(P){var $=U[r][1][P];return e($||P)},E,E.exports,A,U,K,T)}return K[r].exports}for(var a=typeof require=="function"&&require,L=0;L<T.length;L++)e(T[L]);return e}return A}()({1:[function(A,U,K){"use strict";var T=U.exports=function(){this._cache={}};T.prototype.put=function(a,L){this._cache[a]=L},T.prototype.get=function(a){return this._cache[a]},T.prototype.del=function(a){delete this._cache[a]},T.prototype.clear=function(){this._cache={}}},{}],2:[function(A,U,K){"use strict";var T=A("./error_classes").MissingRef;U.exports=e;function e(a,L,r){var n=this;if(typeof this._opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");typeof L=="function"&&(r=L,L=void 0);var S=o(a).then(function(){var P=n._addSchema(a,void 0,L);return P.validate||E(P)});return r&&S.then(function(P){r(null,P)},r),S;function o(P){var $=P.$schema;return $&&!n.getSchema($)?e.call(n,{$ref:$},!0):Promise.resolve()}function E(P){try{return n._compile(P)}catch(h){if(h instanceof T)return $(h);throw h}function $(h){var v=h.missingSchema;if(c(v))throw new Error("Schema "+v+" is loaded but "+h.missingRef+" cannot be resolved");var t=n._loadingSchemas[v];return t||(t=n._loadingSchemas[v]=n._opts.loadSchema(v),t.then(l,l)),t.then(function(f){if(!c(v))return o(f).then(function(){c(v)||n.addSchema(f,v,void 0,L)})}).then(function(){return E(P)});function l(){delete n._loadingSchemas[v]}function c(f){return n._refs[f]||n._schemas[f]}}}}},{"./error_classes":3}],3:[function(A,U,K){"use strict";var T=A("./resolve");U.exports={Validation:L(e),MissingRef:L(a)};function e(r){this.message="validation failed",this.errors=r,this.ajv=this.validation=!0}a.message=function(r,n){return"can't resolve reference "+n+" from id "+r};function a(r,n,S){this.message=S||a.message(r,n),this.missingRef=T.url(r,n),this.missingSchema=T.normalizeId(T.fullPath(this.missingRef))}function L(r){return r.prototype=Object.create(Error.prototype),r.prototype.constructor=r,r}},{"./resolve":6}],4:[function(A,U,K){"use strict";var T=A("./util"),e=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,a=[0,31,28,31,30,31,30,31,31,30,31,30,31],L=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i,r=/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,n=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,S=/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,o=/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,E=/^(?:(?:http[s\u017F]?|ftp):\/\/)(?:(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+(?::(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?@)?(?:(?!10(?:\.[0-9]{1,3}){3})(?!127(?:\.[0-9]{1,3}){3})(?!169\.254(?:\.[0-9]{1,3}){2})(?!192\.168(?:\.[0-9]{1,3}){2})(?!172\.(?:1[6-9]|2[0-9]|3[01])(?:\.[0-9]{1,3}){2})(?:[1-9][0-9]?|1[0-9][0-9]|2[01][0-9]|22[0-3])(?:\.(?:1?[0-9]{1,2}|2[0-4][0-9]|25[0-5])){2}(?:\.(?:[1-9][0-9]?|1[0-9][0-9]|2[0-4][0-9]|25[0-4]))|(?:(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)(?:\.(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)*(?:\.(?:(?:[a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]){2,})))(?::[0-9]{2,5})?(?:\/(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?$/i,P=/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,$=/^(?:\/(?:[^~/]|~0|~1)*)*$/,h=/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,v=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;U.exports=t;function t(x){return x=x=="full"?"full":"fast",T.copy(t[x])}t.fast={date:/^\d\d\d\d-[0-1]\d-[0-3]\d$/,time:/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,"date-time":/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,"uri-template":o,url:E,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i,hostname:r,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:D,uuid:P,"json-pointer":$,"json-pointer-uri-fragment":h,"relative-json-pointer":v},t.full={date:c,time:f,"date-time":F,uri:g,"uri-reference":S,"uri-template":o,url:E,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:r,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:D,uuid:P,"json-pointer":$,"json-pointer-uri-fragment":h,"relative-json-pointer":v};function l(x){return x%4===0&&(x%100!==0||x%400===0)}function c(x){var j=x.match(e);if(!j)return!1;var O=+j[1],d=+j[2],b=+j[3];return d>=1&&d<=12&&b>=1&&b<=(d==2&&l(O)?29:a[d])}function f(x,j){var O=x.match(L);if(!O)return!1;var d=O[1],b=O[2],I=O[3],z=O[5];return(d<=23&&b<=59&&I<=59||d==23&&b==59&&I==60)&&(!j||z)}var p=/t|\s/i;function F(x){var j=x.split(p);return j.length==2&&c(j[0])&&f(j[1],!0)}var R=/\/|:/;function g(x){return R.test(x)&&n.test(x)}var y=/[^\\]\\Z/;function D(x){if(y.test(x))return!1;try{return new RegExp(x),!0}catch{return!1}}},{"./util":10}],5:[function(A,U,K){"use strict";var T=A("./resolve"),e=A("./util"),a=A("./error_classes"),L=A("fast-json-stable-stringify"),r=A("../dotjs/validate"),n=e.ucs2length,S=A("fast-deep-equal"),o=a.Validation;U.exports=E;function E(p,F,R,g){var y=this,D=this._opts,x=[void 0],j={},O=[],d={},b=[],I={},z=[];F=F||{schema:p,refVal:x,refs:j};var Q=P.call(this,p,F,g),H=this._compilations[Q.index];if(Q.compiling)return H.callValidate=G;var ee=this._formats,B=this.RULES;try{var X=Se(p,F,R,g);H.validate=X;var J=H.callValidate;return J&&(J.schema=X.schema,J.errors=null,J.refs=X.refs,J.refVal=X.refVal,J.root=X.root,J.$async=X.$async,D.sourceCode&&(J.source=X.source)),X}finally{$.call(this,p,F,g)}function G(){var N=H.validate,V=N.apply(this,arguments);return G.errors=N.errors,V}function Se(N,V,W,re){var k=!V||V&&V.schema==N;if(V.schema!=F.schema)return E.call(y,N,V,W,re);var ue=N.$async===!0,he=r({isTop:!0,schema:N,isRoot:k,baseId:re,root:V,schemaPath:"",errSchemaPath:"#",errorPath:'""',MissingRefError:a.MissingRef,RULES:B,validate:r,util:e,resolve:T,resolveRef:_e,usePattern:C,useDefault:q,useCustomRule:Y,opts:D,formats:ee,logger:y.logger,self:y});he=f(x,l)+f(O,v)+f(b,t)+f(z,c)+he,D.processCode&&(he=D.processCode(he,N));var se;try{var be=new Function("self","RULES","formats","root","refVal","defaults","customRules","equal","ucs2length","ValidationError",he);se=be(y,B,ee,F,x,b,z,S,n,o),x[0]=se}catch(ge){throw y.logger.error("Error compiling schema, function code:",he),ge}return se.schema=N,se.errors=null,se.refs=j,se.refVal=x,se.root=k?se:V,ue&&(se.$async=!0),D.sourceCode===!0&&(se.source={code:he,patterns:O,defaults:b}),se}function _e(N,V,W){V=T.url(N,V);var re=j[V],k,ue;if(re!==void 0)return k=x[re],ue="refVal["+re+"]",m(k,ue);if(!W&&F.refs){var he=F.refs[V];if(he!==void 0)return k=F.refVal[he],ue=$e(V,k),m(k,ue)}ue=$e(V);var se=T.call(y,Se,F,V);if(se===void 0){var be=R&&R[V];be&&(se=T.inlineRef(be,D.inlineRefs)?be:E.call(y,be,F,R,N))}if(se===void 0)fe(V);else return de(V,se),m(se,ue)}function $e(N,V){var W=x.length;return x[W]=V,j[N]=W,"refVal"+W}function fe(N){delete j[N]}function de(N,V){var W=j[N];x[W]=V}function m(N,V){return typeof N=="object"||typeof N=="boolean"?{code:V,schema:N,inline:!0}:{code:V,$async:N&&!!N.$async}}function C(N){var V=d[N];return V===void 0&&(V=d[N]=O.length,O[V]=N),"pattern"+V}function q(N){switch(typeof N){case"boolean":case"number":return""+N;case"string":return e.toQuotedString(N);case"object":if(N===null)return"null";var V=L(N),W=I[V];return W===void 0&&(W=I[V]=b.length,b[W]=N),"default"+W}}function Y(N,V,W,re){if(y._opts.validateSchema!==!1){var k=N.definition.dependencies;if(k&&!k.every(function(xe){return Object.prototype.hasOwnProperty.call(W,xe)}))throw new Error("parent schema must have all required keywords: "+k.join(","));var ue=N.definition.validateSchema;if(ue){var he=ue(V);if(!he){var se="keyword schema is invalid: "+y.errorsText(ue.errors);if(y._opts.validateSchema=="log")y.logger.error(se);else throw new Error(se)}}}var be=N.definition.compile,ge=N.definition.inline,we=N.definition.macro,ce;if(be)ce=be.call(y,V,W,re);else if(we)ce=we.call(y,V,W,re),D.validateSchema!==!1&&y.validateSchema(ce,!0);else if(ge)ce=ge.call(y,re,N.keyword,V,W);else if(ce=N.definition.validate,!ce)return;if(ce===void 0)throw new Error('custom keyword "'+N.keyword+'"failed to compile');var ye=z.length;return z[ye]=ce,{code:"customRule"+ye,validate:ce}}}function P(p,F,R){var g=h.call(this,p,F,R);return g>=0?{index:g,compiling:!0}:(g=this._compilations.length,this._compilations[g]={schema:p,root:F,baseId:R},{index:g,compiling:!1})}function $(p,F,R){var g=h.call(this,p,F,R);g>=0&&this._compilations.splice(g,1)}function h(p,F,R){for(var g=0;g<this._compilations.length;g++){var y=this._compilations[g];if(y.schema==p&&y.root==F&&y.baseId==R)return g}return-1}function v(p,F){return"var pattern"+p+" = new RegExp("+e.toQuotedString(F[p])+");"}function t(p){return"var default"+p+" = defaults["+p+"];"}function l(p,F){return F[p]===void 0?"":"var refVal"+p+" = refVal["+p+"];"}function c(p){return"var customRule"+p+" = customRules["+p+"];"}function f(p,F){if(!p.length)return"";for(var R="",g=0;g<p.length;g++)R+=F(g,p);return R}},{"../dotjs/validate":38,"./error_classes":3,"./resolve":6,"./util":10,"fast-deep-equal":42,"fast-json-stable-stringify":43}],6:[function(A,U,K){"use strict";var T=A("uri-js"),e=A("fast-deep-equal"),a=A("./util"),L=A("./schema_obj"),r=A("json-schema-traverse");U.exports=n,n.normalizeId=p,n.fullPath=l,n.url=F,n.ids=R,n.inlineRef=h,n.schema=S;function n(g,y,D){var x=this._refs[D];if(typeof x=="string")if(this._refs[x])x=this._refs[x];else return n.call(this,g,y,x);if(x=x||this._schemas[D],x instanceof L)return h(x.schema,this._opts.inlineRefs)?x.schema:x.validate||this._compile(x);var j=S.call(this,y,D),O,d,b;return j&&(O=j.schema,y=j.root,b=j.baseId),O instanceof L?d=O.validate||g.call(this,O.schema,y,void 0,b):O!==void 0&&(d=h(O,this._opts.inlineRefs)?O:g.call(this,O,y,void 0,b)),d}function S(g,y){var D=T.parse(y),x=c(D),j=l(this._getId(g.schema));if(Object.keys(g.schema).length===0||x!==j){var O=p(x),d=this._refs[O];if(typeof d=="string")return o.call(this,g,d,D);if(d instanceof L)d.validate||this._compile(d),g=d;else if(d=this._schemas[O],d instanceof L){if(d.validate||this._compile(d),O==p(y))return{schema:d,root:g,baseId:j};g=d}else return;if(!g.schema)return;j=l(this._getId(g.schema))}return P.call(this,D,j,g.schema,g)}function o(g,y,D){var x=S.call(this,g,y);if(x){var j=x.schema,O=x.baseId;g=x.root;var d=this._getId(j);return d&&(O=F(O,d)),P.call(this,D,O,j,g)}}var E=a.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function P(g,y,D,x){if(g.fragment=g.fragment||"",g.fragment.slice(0,1)=="/"){for(var j=g.fragment.split("/"),O=1;O<j.length;O++){var d=j[O];if(d){if(d=a.unescapeFragment(d),D=D[d],D===void 0)break;var b;if(!E[d]&&(b=this._getId(D),b&&(y=F(y,b)),D.$ref)){var I=F(y,D.$ref),z=S.call(this,x,I);z&&(D=z.schema,x=z.root,y=z.baseId)}}}if(D!==void 0&&D!==x.schema)return{schema:D,root:x,baseId:y}}}var $=a.toHash(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum"]);function h(g,y){if(y===!1)return!1;if(y===void 0||y===!0)return v(g);if(y)return t(g)<=y}function v(g){var y;if(Array.isArray(g)){for(var D=0;D<g.length;D++)if(y=g[D],typeof y=="object"&&!v(y))return!1}else for(var x in g)if(x=="$ref"||(y=g[x],typeof y=="object"&&!v(y)))return!1;return!0}function t(g){var y=0,D;if(Array.isArray(g)){for(var x=0;x<g.length;x++)if(D=g[x],typeof D=="object"&&(y+=t(D)),y==1/0)return 1/0}else for(var j in g){if(j=="$ref")return 1/0;if($[j])y++;else if(D=g[j],typeof D=="object"&&(y+=t(D)+1),y==1/0)return 1/0}return y}function l(g,y){y!==!1&&(g=p(g));var D=T.parse(g);return c(D)}function c(g){return T.serialize(g).split("#")[0]+"#"}var f=/#\/?$/;function p(g){return g?g.replace(f,""):""}function F(g,y){return y=p(y),T.resolve(g,y)}function R(g){var y=p(this._getId(g)),D={"":y},x={"":l(y,!1)},j={},O=this;return r(g,{allKeys:!0},function(d,b,I,z,Q,H,ee){if(b!==""){var B=O._getId(d),X=D[z],J=x[z]+"/"+Q;if(ee!==void 0&&(J+="/"+(typeof ee=="number"?ee:a.escapeFragment(ee))),typeof B=="string"){B=X=p(X?T.resolve(X,B):B);var G=O._refs[B];if(typeof G=="string"&&(G=O._refs[G]),G&&G.schema){if(!e(d,G.schema))throw new Error('id "'+B+'" resolves to more than one schema')}else if(B!=p(J))if(B[0]=="#"){if(j[B]&&!e(d,j[B]))throw new Error('id "'+B+'" resolves to more than one schema');j[B]=d}else O._refs[B]=J}D[b]=X,x[b]=J}}),j}},{"./schema_obj":8,"./util":10,"fast-deep-equal":42,"json-schema-traverse":44,"uri-js":45}],7:[function(A,U,K){"use strict";var T=A("../dotjs"),e=A("./util").toHash;U.exports=function(){var L=[{type:"number",rules:[{maximum:["exclusiveMaximum"]},{minimum:["exclusiveMinimum"]},"multipleOf","format"]},{type:"string",rules:["maxLength","minLength","pattern","format"]},{type:"array",rules:["maxItems","minItems","items","contains","uniqueItems"]},{type:"object",rules:["maxProperties","minProperties","required","dependencies","propertyNames",{properties:["additionalProperties","patternProperties"]}]},{rules:["$ref","const","enum","not","anyOf","oneOf","allOf","if"]}],r=["type","$comment"],n=["$schema","$id","id","$data","$async","title","description","default","definitions","examples","readOnly","writeOnly","contentMediaType","contentEncoding","additionalItems","then","else"],S=["number","integer","string","array","object","boolean","null"];return L.all=e(r),L.types=e(S),L.forEach(function(o){o.rules=o.rules.map(function(E){var P;if(typeof E=="object"){var $=Object.keys(E)[0];P=E[$],E=$,P.forEach(function(v){r.push(v),L.all[v]=!0})}r.push(E);var h=L.all[E]={keyword:E,code:T[E],implements:P};return h}),L.all.$comment={keyword:"$comment",code:T.$comment},o.type&&(L.types[o.type]=o)}),L.keywords=e(r.concat(n)),L.custom={},L}},{"../dotjs":27,"./util":10}],8:[function(A,U,K){"use strict";var T=A("./util");U.exports=e;function e(a){T.copy(a,this)}},{"./util":10}],9:[function(A,U,K){"use strict";U.exports=function(e){for(var a=0,L=e.length,r=0,n;r<L;)a++,n=e.charCodeAt(r++),n>=55296&&n<=56319&&r<L&&(n=e.charCodeAt(r),(n&64512)==56320&&r++);return a}},{}],10:[function(A,U,K){"use strict";U.exports={copy:T,checkDataType:e,checkDataTypes:a,coerceToTypes:r,toHash:n,getProperty:E,escapeQuotes:P,equal:A("fast-deep-equal"),ucs2length:A("./ucs2length"),varOccurences:$,varReplace:h,schemaHasRules:v,schemaHasRulesExcept:t,schemaUnknownRules:l,toQuotedString:c,getPathExpr:f,getPath:p,getData:g,unescapeFragment:D,unescapeJsonPointer:O,escapeFragment:x,escapeJsonPointer:j};function T(d,b){b=b||{};for(var I in d)b[I]=d[I];return b}function e(d,b,I,z){var Q=z?" !== ":" === ",H=z?" || ":" && ",ee=z?"!":"",B=z?"":"!";switch(d){case"null":return b+Q+"null";case"array":return ee+"Array.isArray("+b+")";case"object":return"("+ee+b+H+"typeof "+b+Q+'"object"'+H+B+"Array.isArray("+b+"))";case"integer":return"(typeof "+b+Q+'"number"'+H+B+"("+b+" % 1)"+H+b+Q+b+(I?H+ee+"isFinite("+b+")":"")+")";case"number":return"(typeof "+b+Q+'"'+d+'"'+(I?H+ee+"isFinite("+b+")":"")+")";default:return"typeof "+b+Q+'"'+d+'"'}}function a(d,b,I){switch(d.length){case 1:return e(d[0],b,I,!0);default:var z="",Q=n(d);Q.array&&Q.object&&(z=Q.null?"(":"(!"+b+" || ",z+="typeof "+b+' !== "object")',delete Q.null,delete Q.array,delete Q.object),Q.number&&delete Q.integer;for(var H in Q)z+=(z?" && ":"")+e(H,b,I,!0);return z}}var L=n(["string","number","integer","boolean","null"]);function r(d,b){if(Array.isArray(b)){for(var I=[],z=0;z<b.length;z++){var Q=b[z];(L[Q]||d==="array"&&Q==="array")&&(I[I.length]=Q)}if(I.length)return I}else{if(L[b])return[b];if(d==="array"&&b==="array")return["array"]}}function n(d){for(var b={},I=0;I<d.length;I++)b[d[I]]=!0;return b}var S=/^[a-z$_][a-z$_0-9]*$/i,o=/'|\\/g;function E(d){return typeof d=="number"?"["+d+"]":S.test(d)?"."+d:"['"+P(d)+"']"}function P(d){return d.replace(o,"\\$&").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\f/g,"\\f").replace(/\t/g,"\\t")}function $(d,b){b+="[^0-9]";var I=d.match(new RegExp(b,"g"));return I?I.length:0}function h(d,b,I){return b+="([^0-9])",I=I.replace(/\$/g,"$$$$"),d.replace(new RegExp(b,"g"),I+"$1")}function v(d,b){if(typeof d=="boolean")return!d;for(var I in d)if(b[I])return!0}function t(d,b,I){if(typeof d=="boolean")return!d&&I!="not";for(var z in d)if(z!=I&&b[z])return!0}function l(d,b){if(typeof d!="boolean"){for(var I in d)if(!b[I])return I}}function c(d){return"'"+P(d)+"'"}function f(d,b,I,z){var Q=I?"'/' + "+b+(z?"":".replace(/~/g, '~0').replace(/\\//g, '~1')"):z?"'[' + "+b+" + ']'":"'[\\'' + "+b+" + '\\']'";return y(d,Q)}function p(d,b,I){var z=c(I?"/"+j(b):E(b));return y(d,z)}var F=/^\/(?:[^~]|~0|~1)*$/,R=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function g(d,b,I){var z,Q,H,ee;if(d==="")return"rootData";if(d[0]=="/"){if(!F.test(d))throw new Error("Invalid JSON-pointer: "+d);Q=d,H="rootData"}else{if(ee=d.match(R),!ee)throw new Error("Invalid JSON-pointer: "+d);if(z=+ee[1],Q=ee[2],Q=="#"){if(z>=b)throw new Error("Cannot access property/index "+z+" levels up, current level is "+b);return I[b-z]}if(z>b)throw new Error("Cannot access data "+z+" levels up, current level is "+b);if(H="data"+(b-z||""),!Q)return H}for(var B=H,X=Q.split("/"),J=0;J<X.length;J++){var G=X[J];G&&(H+=E(O(G)),B+=" && "+H)}return B}function y(d,b){return d=='""'?b:(d+" + "+b).replace(/([^\\])' \+ '/g,"$1")}function D(d){return O(decodeURIComponent(d))}function x(d){return encodeURIComponent(j(d))}function j(d){return d.replace(/~/g,"~0").replace(/\//g,"~1")}function O(d){return d.replace(/~1/g,"/").replace(/~0/g,"~")}},{"./ucs2length":9,"fast-deep-equal":42}],11:[function(A,U,K){"use strict";var T=["multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","additionalItems","maxItems","minItems","uniqueItems","maxProperties","minProperties","required","additionalProperties","enum","format","const"];U.exports=function(e,a){for(var L=0;L<a.length;L++){e=JSON.parse(JSON.stringify(e));var r=a[L].split("/"),n=e,S;for(S=1;S<r.length;S++)n=n[r[S]];for(S=0;S<T.length;S++){var o=T[S],E=n[o];E&&(n[o]={anyOf:[E,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]})}}return e}},{}],12:[function(A,U,K){"use strict";var T=A("./refs/json-schema-draft-07.json");U.exports={$id:"https://github.com/ajv-validator/ajv/blob/master/lib/definition_schema.js",definitions:{simpleTypes:T.definitions.simpleTypes},type:"object",dependencies:{schema:["validate"],$data:["validate"],statements:["inline"],valid:{not:{required:["macro"]}}},properties:{type:T.properties.type,schema:{type:"boolean"},statements:{type:"boolean"},dependencies:{type:"array",items:{type:"string"}},metaSchema:{type:"object"},modifying:{type:"boolean"},valid:{type:"boolean"},$data:{type:"boolean"},async:{type:"boolean"},errors:{anyOf:[{type:"boolean"},{const:"full"}]}}}},{"./refs/json-schema-draft-07.json":41}],13:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,g,h="data"+(S||""),v=e.opts.$data&&o&&o.$data,t;v?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",t="schema"+n):t=o;var l=a=="maximum",c=l?"exclusiveMaximum":"exclusiveMinimum",f=e.schema[c],p=e.opts.$data&&f&&f.$data,F=l?"<":">",R=l?">":"<",g=void 0;if(!(v||typeof o=="number"||o===void 0))throw new Error(a+" must be number");if(!(p||f===void 0||typeof f=="number"||typeof f=="boolean"))throw new Error(c+" must be number or boolean");if(p){var y=e.util.getData(f.$data,S,e.dataPathArr),D="exclusive"+n,x="exclType"+n,j="exclIsNumber"+n,O="op"+n,d="' + "+O+" + '";r+=" var schemaExcl"+n+" = "+y+"; ",y="schemaExcl"+n,r+=" var "+D+"; var "+x+" = typeof "+y+"; if ("+x+" != 'boolean' && "+x+" != 'undefined' && "+x+" != 'number') { ";var g=c,b=b||[];b.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(g||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: {} ",e.opts.messages!==!1&&(r+=" , message: '"+c+" should be boolean' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var I=r;r=b.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+I+"]); ":r+=" validate.errors = ["+I+"]; return false; ":r+=" var err = "+I+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } else if ( ",v&&(r+=" ("+t+" !== undefined && typeof "+t+" != 'number') || "),r+=" "+x+" == 'number' ? ( ("+D+" = "+t+" === undefined || "+y+" "+F+"= "+t+") ? "+h+" "+R+"= "+y+" : "+h+" "+R+" "+t+" ) : ( ("+D+" = "+y+" === true) ? "+h+" "+R+"= "+t+" : "+h+" "+R+" "+t+" ) || "+h+" !== "+h+") { var op"+n+" = "+D+" ? '"+F+"' : '"+F+"='; ",o===void 0&&(g=c,P=e.errSchemaPath+"/"+c,t=y,v=p)}else{var j=typeof f=="number",d=F;if(j&&v){var O="'"+d+"'";r+=" if ( ",v&&(r+=" ("+t+" !== undefined && typeof "+t+" != 'number') || "),r+=" ( "+t+" === undefined || "+f+" "+F+"= "+t+" ? "+h+" "+R+"= "+f+" : "+h+" "+R+" "+t+" ) || "+h+" !== "+h+") { "}else{j&&o===void 0?(D=!0,g=c,P=e.errSchemaPath+"/"+c,t=f,R+="="):(j&&(t=Math[l?"min":"max"](f,o)),f===(j?t:!0)?(D=!0,g=c,P=e.errSchemaPath+"/"+c,R+="="):(D=!1,d+="="));var O="'"+d+"'";r+=" if ( ",v&&(r+=" ("+t+" !== undefined && typeof "+t+" != 'number') || "),r+=" "+h+" "+R+" "+t+" || "+h+" !== "+h+") { "}}g=g||a;var b=b||[];b.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(g||"_limit")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { comparison: "+O+", limit: "+t+", exclusive: "+D+" } ",e.opts.messages!==!1&&(r+=" , message: 'should be "+d+" ",v?r+="' + "+t:r+=""+t+"'"),e.opts.verbose&&(r+=" , schema: ",v?r+="validate.schema"+E:r+=""+o,r+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var I=r;return r=b.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+I+"]); ":r+=" validate.errors = ["+I+"]; return false; ":r+=" var err = "+I+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } ",$&&(r+=" else { "),r}},{}],14:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,c,h="data"+(S||""),v=e.opts.$data&&o&&o.$data,t;if(v?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",t="schema"+n):t=o,!(v||typeof o=="number"))throw new Error(a+" must be number");var l=a=="maxItems"?">":"<";r+="if ( ",v&&(r+=" ("+t+" !== undefined && typeof "+t+" != 'number') || "),r+=" "+h+".length "+l+" "+t+") { ";var c=a,f=f||[];f.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(c||"_limitItems")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { limit: "+t+" } ",e.opts.messages!==!1&&(r+=" , message: 'should NOT have ",a=="maxItems"?r+="more":r+="fewer",r+=" than ",v?r+="' + "+t+" + '":r+=""+o,r+=" items' "),e.opts.verbose&&(r+=" , schema: ",v?r+="validate.schema"+E:r+=""+o,r+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var p=r;return r=f.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+p+"]); ":r+=" validate.errors = ["+p+"]; return false; ":r+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+="} ",$&&(r+=" else { "),r}},{}],15:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,c,h="data"+(S||""),v=e.opts.$data&&o&&o.$data,t;if(v?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",t="schema"+n):t=o,!(v||typeof o=="number"))throw new Error(a+" must be number");var l=a=="maxLength"?">":"<";r+="if ( ",v&&(r+=" ("+t+" !== undefined && typeof "+t+" != 'number') || "),e.opts.unicode===!1?r+=" "+h+".length ":r+=" ucs2length("+h+") ",r+=" "+l+" "+t+") { ";var c=a,f=f||[];f.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(c||"_limitLength")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { limit: "+t+" } ",e.opts.messages!==!1&&(r+=" , message: 'should NOT be ",a=="maxLength"?r+="longer":r+="shorter",r+=" than ",v?r+="' + "+t+" + '":r+=""+o,r+=" characters' "),e.opts.verbose&&(r+=" , schema: ",v?r+="validate.schema"+E:r+=""+o,r+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var p=r;return r=f.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+p+"]); ":r+=" validate.errors = ["+p+"]; return false; ":r+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+="} ",$&&(r+=" else { "),r}},{}],16:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,c,h="data"+(S||""),v=e.opts.$data&&o&&o.$data,t;if(v?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",t="schema"+n):t=o,!(v||typeof o=="number"))throw new Error(a+" must be number");var l=a=="maxProperties"?">":"<";r+="if ( ",v&&(r+=" ("+t+" !== undefined && typeof "+t+" != 'number') || "),r+=" Object.keys("+h+").length "+l+" "+t+") { ";var c=a,f=f||[];f.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(c||"_limitProperties")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { limit: "+t+" } ",e.opts.messages!==!1&&(r+=" , message: 'should NOT have ",a=="maxProperties"?r+="more":r+="fewer",r+=" than ",v?r+="' + "+t+" + '":r+=""+o,r+=" properties' "),e.opts.verbose&&(r+=" , schema: ",v?r+="validate.schema"+E:r+=""+o,r+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var p=r;return r=f.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+p+"]); ":r+=" validate.errors = ["+p+"]; return false; ":r+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+="} ",$&&(r+=" else { "),r}},{}],17:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.schema[a],S=e.schemaPath+e.util.getProperty(a),o=e.errSchemaPath+"/"+a,E=!e.opts.allErrors,P=e.util.copy(e),$="";P.level++;var h="valid"+P.level,v=P.baseId,t=!0,l=n;if(l)for(var c,f=-1,p=l.length-1;f<p;)c=l[f+=1],(e.opts.strictKeywords?typeof c=="object"&&Object.keys(c).length>0||c===!1:e.util.schemaHasRules(c,e.RULES.all))&&(t=!1,P.schema=c,P.schemaPath=S+"["+f+"]",P.errSchemaPath=o+"/"+f,r+=" "+e.validate(P)+" ",P.baseId=v,E&&(r+=" if ("+h+") { ",$+="}"));return E&&(t?r+=" if (true) { ":r+=" "+$.slice(0,-1)+" "),r}},{}],18:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t="errs__"+n,l=e.util.copy(e),c="";l.level++;var f="valid"+l.level,p=o.every(function(j){return e.opts.strictKeywords?typeof j=="object"&&Object.keys(j).length>0||j===!1:e.util.schemaHasRules(j,e.RULES.all)});if(p){var F=l.baseId;r+=" var "+t+" = errors; var "+v+" = false; ";var R=e.compositeRule;e.compositeRule=l.compositeRule=!0;var g=o;if(g)for(var y,D=-1,x=g.length-1;D<x;)y=g[D+=1],l.schema=y,l.schemaPath=E+"["+D+"]",l.errSchemaPath=P+"/"+D,r+=" "+e.validate(l)+" ",l.baseId=F,r+=" "+v+" = "+v+" || "+f+"; if (!"+v+") { ",c+="}";e.compositeRule=l.compositeRule=R,r+=" "+c+" if (!"+v+") { var err = ",e.createErrors!==!1?(r+=" { keyword: 'anyOf' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: {} ",e.opts.messages!==!1&&(r+=" , message: 'should match some schema in anyOf' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&$&&(e.async?r+=" throw new ValidationError(vErrors); ":r+=" validate.errors = vErrors; return false; "),r+=" } else { errors = "+t+"; if (vErrors !== null) { if ("+t+") vErrors.length = "+t+"; else vErrors = null; } ",e.opts.allErrors&&(r+=" } ")}else $&&(r+=" if (true) { ");return r}},{}],19:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.schema[a],S=e.errSchemaPath+"/"+a,o=!e.opts.allErrors,E=e.util.toQuotedString(n);return e.opts.$comment===!0?r+=" console.log("+E+");":typeof e.opts.$comment=="function"&&(r+=" self._opts.$comment("+E+", "+e.util.toQuotedString(S)+", validate.root.schema);"),r}},{}],20:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t=e.opts.$data&&o&&o.$data,l;t?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",l="schema"+n):l=o,t||(r+=" var schema"+n+" = validate.schema"+E+";"),r+="var "+v+" = equal("+h+", schema"+n+"); if (!"+v+") { ";var c=c||[];c.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'const' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { allowedValue: schema"+n+" } ",e.opts.messages!==!1&&(r+=" , message: 'should be equal to constant' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var f=r;return r=c.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+f+"]); ":r+=" validate.errors = ["+f+"]; return false; ":r+=" var err = "+f+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" }",$&&(r+=" else { "),r}},{}],21:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t="errs__"+n,l=e.util.copy(e),c="";l.level++;var f="valid"+l.level,p="i"+n,F=l.dataLevel=e.dataLevel+1,R="data"+F,g=e.baseId,y=e.opts.strictKeywords?typeof o=="object"&&Object.keys(o).length>0||o===!1:e.util.schemaHasRules(o,e.RULES.all);if(r+="var "+t+" = errors;var "+v+";",y){var D=e.compositeRule;e.compositeRule=l.compositeRule=!0,l.schema=o,l.schemaPath=E,l.errSchemaPath=P,r+=" var "+f+" = false; for (var "+p+" = 0; "+p+" < "+h+".length; "+p+"++) { ",l.errorPath=e.util.getPathExpr(e.errorPath,p,e.opts.jsonPointers,!0);var x=h+"["+p+"]";l.dataPathArr[F]=p;var j=e.validate(l);l.baseId=g,e.util.varOccurences(j,R)<2?r+=" "+e.util.varReplace(j,R,x)+" ":r+=" var "+R+" = "+x+"; "+j+" ",r+=" if ("+f+") break; } ",e.compositeRule=l.compositeRule=D,r+=" "+c+" if (!"+f+") {"}else r+=" if ("+h+".length == 0) {";var O=O||[];O.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'contains' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: {} ",e.opts.messages!==!1&&(r+=" , message: 'should contain a valid item' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var d=r;return r=O.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+d+"]); ":r+=" validate.errors = ["+d+"]; return false; ":r+=" var err = "+d+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } else { ",y&&(r+=" errors = "+t+"; if (vErrors !== null) { if ("+t+") vErrors.length = "+t+"; else vErrors = null; } "),e.opts.allErrors&&(r+=" } "),r}},{}],22:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h,v="data"+(S||""),t="valid"+n,l="errs__"+n,c=e.opts.$data&&o&&o.$data,f;c?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",f="schema"+n):f=o;var p=this,F="definition"+n,R=p.definition,g="",y,D,x,j,O;if(c&&R.$data){O="keywordValidate"+n;var d=R.validateSchema;r+=" var "+F+" = RULES.custom['"+a+"'].definition; var "+O+" = "+F+".validate;"}else{if(j=e.useCustomRule(p,o,e.schema,e),!j)return;f="validate.schema"+E,O=j.code,y=R.compile,D=R.inline,x=R.macro}var b=O+".errors",I="i"+n,z="ruleErr"+n,Q=R.async;if(Q&&!e.async)throw new Error("async keyword in sync schema");if(D||x||(r+=""+b+" = null;"),r+="var "+l+" = errors;var "+t+";",c&&R.$data&&(g+="}",r+=" if ("+f+" === undefined) { "+t+" = true; } else { ",d&&(g+="}",r+=" "+t+" = "+F+".validateSchema("+f+"); if ("+t+") { ")),D)R.statements?r+=" "+j.validate+" ":r+=" "+t+" = "+j.validate+"; ";else if(x){var H=e.util.copy(e),g="";H.level++;var ee="valid"+H.level;H.schema=j.validate,H.schemaPath="";var B=e.compositeRule;e.compositeRule=H.compositeRule=!0;var X=e.validate(H).replace(/validate\.schema/g,O);e.compositeRule=H.compositeRule=B,r+=" "+X}else{var J=J||[];J.push(r),r="",r+=" "+O+".call( ",e.opts.passContext?r+="this":r+="self",y||R.schema===!1?r+=" , "+v+" ":r+=" , "+f+" , "+v+" , validate.schema"+e.schemaPath+" ",r+=" , (dataPath || '')",e.errorPath!='""'&&(r+=" + "+e.errorPath);var G=S?"data"+(S-1||""):"parentData",Se=S?e.dataPathArr[S]:"parentDataProperty";r+=" , "+G+" , "+Se+" , rootData ) ";var _e=r;r=J.pop(),R.errors===!1?(r+=" "+t+" = ",Q&&(r+="await "),r+=""+_e+"; "):Q?(b="customErrors"+n,r+=" var "+b+" = null; try { "+t+" = await "+_e+"; } catch (e) { "+t+" = false; if (e instanceof ValidationError) "+b+" = e.errors; else throw e; } "):r+=" "+b+" = null; "+t+" = "+_e+"; "}if(R.modifying&&(r+=" if ("+G+") "+v+" = "+G+"["+Se+"];"),r+=""+g,R.valid)$&&(r+=" if (true) { ");else{r+=" if ( ",R.valid===void 0?(r+=" !",x?r+=""+ee:r+=""+t):r+=" "+!R.valid+" ",r+=") { ",h=p.keyword;var J=J||[];J.push(r),r="";var J=J||[];J.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(h||"custom")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { keyword: '"+p.keyword+"' } ",e.opts.messages!==!1&&(r+=` , message: 'should pass "`+p.keyword+`" keyword validation' `),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+v+" "),r+=" } "):r+=" {} ";var $e=r;r=J.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+$e+"]); ":r+=" validate.errors = ["+$e+"]; return false; ":r+=" var err = "+$e+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";var fe=r;r=J.pop(),D?R.errors?R.errors!="full"&&(r+=" for (var "+I+"="+l+"; "+I+"<errors; "+I+"++) { var "+z+" = vErrors["+I+"]; if ("+z+".dataPath === undefined) "+z+".dataPath = (dataPath || '') + "+e.errorPath+"; if ("+z+".schemaPath === undefined) { "+z+'.schemaPath = "'+P+'"; } ',e.opts.verbose&&(r+=" "+z+".schema = "+f+"; "+z+".data = "+v+"; "),r+=" } "):R.errors===!1?r+=" "+fe+" ":(r+=" if ("+l+" == errors) { "+fe+" } else { for (var "+I+"="+l+"; "+I+"<errors; "+I+"++) { var "+z+" = vErrors["+I+"]; if ("+z+".dataPath === undefined) "+z+".dataPath = (dataPath || '') + "+e.errorPath+"; if ("+z+".schemaPath === undefined) { "+z+'.schemaPath = "'+P+'"; } ',e.opts.verbose&&(r+=" "+z+".schema = "+f+"; "+z+".data = "+v+"; "),r+=" } } "):x?(r+=" var err = ",e.createErrors!==!1?(r+=" { keyword: '"+(h||"custom")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { keyword: '"+p.keyword+"' } ",e.opts.messages!==!1&&(r+=` , message: 'should pass "`+p.keyword+`" keyword validation' `),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+v+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&$&&(e.async?r+=" throw new ValidationError(vErrors); ":r+=" validate.errors = vErrors; return false; ")):R.errors===!1?r+=" "+fe+" ":(r+=" if (Array.isArray("+b+")) { if (vErrors === null) vErrors = "+b+"; else vErrors = vErrors.concat("+b+"); errors = vErrors.length; for (var "+I+"="+l+"; "+I+"<errors; "+I+"++) { var "+z+" = vErrors["+I+"]; if ("+z+".dataPath === undefined) "+z+".dataPath = (dataPath || '') + "+e.errorPath+"; "+z+'.schemaPath = "'+P+'"; ',e.opts.verbose&&(r+=" "+z+".schema = "+f+"; "+z+".data = "+v+"; "),r+=" } } else { "+fe+" } "),r+=" } ",$&&(r+=" else { ")}return r}},{}],23:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="errs__"+n,t=e.util.copy(e),l="";t.level++;var c="valid"+t.level,f={},p={},F=e.opts.ownProperties;for(D in o)if(D!="__proto__"){var R=o[D],g=Array.isArray(R)?p:f;g[D]=R}r+="var "+v+" = errors;";var y=e.errorPath;r+="var missing"+n+";";for(var D in p)if(g=p[D],g.length){if(r+=" if ( "+h+e.util.getProperty(D)+" !== undefined ",F&&(r+=" && Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(D)+"') "),$){r+=" && ( ";var x=g;if(x)for(var j,O=-1,d=x.length-1;O<d;){j=x[O+=1],O&&(r+=" || ");var b=e.util.getProperty(j),I=h+b;r+=" ( ( "+I+" === undefined ",F&&(r+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(j)+"') "),r+=") && (missing"+n+" = "+e.util.toQuotedString(e.opts.jsonPointers?j:b)+") ) "}r+=")) { ";var z="missing"+n,Q="' + "+z+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.opts.jsonPointers?e.util.getPathExpr(y,z,!0):y+" + "+z);var H=H||[];H.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { property: '"+e.util.escapeQuotes(D)+"', missingProperty: '"+Q+"', depsCount: "+g.length+", deps: '"+e.util.escapeQuotes(g.length==1?g[0]:g.join(", "))+"' } ",e.opts.messages!==!1&&(r+=" , message: 'should have ",g.length==1?r+="property "+e.util.escapeQuotes(g[0]):r+="properties "+e.util.escapeQuotes(g.join(", ")),r+=" when property "+e.util.escapeQuotes(D)+" is present' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var ee=r;r=H.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+ee+"]); ":r+=" validate.errors = ["+ee+"]; return false; ":r+=" var err = "+ee+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else{r+=" ) { ";var B=g;if(B)for(var j,X=-1,J=B.length-1;X<J;){j=B[X+=1];var b=e.util.getProperty(j),Q=e.util.escapeQuotes(j),I=h+b;e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPath(y,j,e.opts.jsonPointers)),r+=" if ( "+I+" === undefined ",F&&(r+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(j)+"') "),r+=") { var err = ",e.createErrors!==!1?(r+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { property: '"+e.util.escapeQuotes(D)+"', missingProperty: '"+Q+"', depsCount: "+g.length+", deps: '"+e.util.escapeQuotes(g.length==1?g[0]:g.join(", "))+"' } ",e.opts.messages!==!1&&(r+=" , message: 'should have ",g.length==1?r+="property "+e.util.escapeQuotes(g[0]):r+="properties "+e.util.escapeQuotes(g.join(", ")),r+=" when property "+e.util.escapeQuotes(D)+" is present' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}r+=" } ",$&&(l+="}",r+=" else { ")}e.errorPath=y;var G=t.baseId;for(var D in f){var R=f[D];(e.opts.strictKeywords?typeof R=="object"&&Object.keys(R).length>0||R===!1:e.util.schemaHasRules(R,e.RULES.all))&&(r+=" "+c+" = true; if ( "+h+e.util.getProperty(D)+" !== undefined ",F&&(r+=" && Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(D)+"') "),r+=") { ",t.schema=R,t.schemaPath=E+e.util.getProperty(D),t.errSchemaPath=P+"/"+e.util.escapeFragment(D),r+=" "+e.validate(t)+" ",t.baseId=G,r+=" } ",$&&(r+=" if ("+c+") { ",l+="}"))}return $&&(r+=" "+l+" if ("+v+" == errors) {"),r}},{}],24:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t=e.opts.$data&&o&&o.$data,l;t?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",l="schema"+n):l=o;var c="i"+n,f="schema"+n;t||(r+=" var "+f+" = validate.schema"+E+";"),r+="var "+v+";",t&&(r+=" if (schema"+n+" === undefined) "+v+" = true; else if (!Array.isArray(schema"+n+")) "+v+" = false; else {"),r+=""+v+" = false;for (var "+c+"=0; "+c+"<"+f+".length; "+c+"++) if (equal("+h+", "+f+"["+c+"])) { "+v+" = true; break; }",t&&(r+=" } "),r+=" if (!"+v+") { ";var p=p||[];p.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'enum' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { allowedValues: schema"+n+" } ",e.opts.messages!==!1&&(r+=" , message: 'should be equal to one of the allowed values' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var F=r;return r=p.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+F+"]); ":r+=" validate.errors = ["+F+"]; return false; ":r+=" var err = "+F+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" }",$&&(r+=" else { "),r}},{}],25:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||"");if(e.opts.format===!1)return $&&(r+=" if (true) { "),r;var v=e.opts.$data&&o&&o.$data,t;v?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",t="schema"+n):t=o;var l=e.opts.unknownFormats,c=Array.isArray(l);if(v){var f="format"+n,p="isObject"+n,F="formatType"+n;r+=" var "+f+" = formats["+t+"]; var "+p+" = typeof "+f+" == 'object' && !("+f+" instanceof RegExp) && "+f+".validate; var "+F+" = "+p+" && "+f+".type || 'string'; if ("+p+") { ",e.async&&(r+=" var async"+n+" = "+f+".async; "),r+=" "+f+" = "+f+".validate; } if ( ",v&&(r+=" ("+t+" !== undefined && typeof "+t+" != 'string') || "),r+=" (",l!="ignore"&&(r+=" ("+t+" && !"+f+" ",c&&(r+=" && self._opts.unknownFormats.indexOf("+t+") == -1 "),r+=") || "),r+=" ("+f+" && "+F+" == '"+L+"' && !(typeof "+f+" == 'function' ? ",e.async?r+=" (async"+n+" ? await "+f+"("+h+") : "+f+"("+h+")) ":r+=" "+f+"("+h+") ",r+=" : "+f+".test("+h+"))))) {"}else{var f=e.formats[o];if(!f){if(l=="ignore")return e.logger.warn('unknown format "'+o+'" ignored in schema at path "'+e.errSchemaPath+'"'),$&&(r+=" if (true) { "),r;if(c&&l.indexOf(o)>=0)return $&&(r+=" if (true) { "),r;throw new Error('unknown format "'+o+'" is used in schema at path "'+e.errSchemaPath+'"')}var p=typeof f=="object"&&!(f instanceof RegExp)&&f.validate,F=p&&f.type||"string";if(p){var R=f.async===!0;f=f.validate}if(F!=L)return $&&(r+=" if (true) { "),r;if(R){if(!e.async)throw new Error("async format in sync schema");var g="formats"+e.util.getProperty(o)+".validate";r+=" if (!(await "+g+"("+h+"))) { "}else{r+=" if (! ";var g="formats"+e.util.getProperty(o);p&&(g+=".validate"),typeof f=="function"?r+=" "+g+"("+h+") ":r+=" "+g+".test("+h+") ",r+=") { "}}var y=y||[];y.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'format' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { format: ",v?r+=""+t:r+=""+e.util.toQuotedString(o),r+=" } ",e.opts.messages!==!1&&(r+=` , message: 'should match format "`,v?r+="' + "+t+" + '":r+=""+e.util.escapeQuotes(o),r+=`"' `),e.opts.verbose&&(r+=" , schema: ",v?r+="validate.schema"+E:r+=""+e.util.toQuotedString(o),r+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var D=r;return r=y.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+D+"]); ":r+=" validate.errors = ["+D+"]; return false; ":r+=" var err = "+D+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } ",$&&(r+=" else { "),r}},{}],26:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t="errs__"+n,l=e.util.copy(e);l.level++;var c="valid"+l.level,f=e.schema.then,p=e.schema.else,F=f!==void 0&&(e.opts.strictKeywords?typeof f=="object"&&Object.keys(f).length>0||f===!1:e.util.schemaHasRules(f,e.RULES.all)),R=p!==void 0&&(e.opts.strictKeywords?typeof p=="object"&&Object.keys(p).length>0||p===!1:e.util.schemaHasRules(p,e.RULES.all)),g=l.baseId;if(F||R){var y;l.createErrors=!1,l.schema=o,l.schemaPath=E,l.errSchemaPath=P,r+=" var "+t+" = errors; var "+v+" = true; ";var D=e.compositeRule;e.compositeRule=l.compositeRule=!0,r+=" "+e.validate(l)+" ",l.baseId=g,l.createErrors=!0,r+=" errors = "+t+"; if (vErrors !== null) { if ("+t+") vErrors.length = "+t+"; else vErrors = null; } ",e.compositeRule=l.compositeRule=D,F?(r+=" if ("+c+") { ",l.schema=e.schema.then,l.schemaPath=e.schemaPath+".then",l.errSchemaPath=e.errSchemaPath+"/then",r+=" "+e.validate(l)+" ",l.baseId=g,r+=" "+v+" = "+c+"; ",F&&R?(y="ifClause"+n,r+=" var "+y+" = 'then'; "):y="'then'",r+=" } ",R&&(r+=" else { ")):r+=" if (!"+c+") { ",R&&(l.schema=e.schema.else,l.schemaPath=e.schemaPath+".else",l.errSchemaPath=e.errSchemaPath+"/else",r+=" "+e.validate(l)+" ",l.baseId=g,r+=" "+v+" = "+c+"; ",F&&R?(y="ifClause"+n,r+=" var "+y+" = 'else'; "):y="'else'",r+=" } "),r+=" if (!"+v+") { var err = ",e.createErrors!==!1?(r+=" { keyword: 'if' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { failingKeyword: "+y+" } ",e.opts.messages!==!1&&(r+=` , message: 'should match "' + `+y+` + '" schema' `),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&$&&(e.async?r+=" throw new ValidationError(vErrors); ":r+=" validate.errors = vErrors; return false; "),r+=" } ",$&&(r+=" else { ")}else $&&(r+=" if (true) { ");return r}},{}],27:[function(A,U,K){"use strict";U.exports={$ref:A("./ref"),allOf:A("./allOf"),anyOf:A("./anyOf"),$comment:A("./comment"),const:A("./const"),contains:A("./contains"),dependencies:A("./dependencies"),enum:A("./enum"),format:A("./format"),if:A("./if"),items:A("./items"),maximum:A("./_limit"),minimum:A("./_limit"),maxItems:A("./_limitItems"),minItems:A("./_limitItems"),maxLength:A("./_limitLength"),minLength:A("./_limitLength"),maxProperties:A("./_limitProperties"),minProperties:A("./_limitProperties"),multipleOf:A("./multipleOf"),not:A("./not"),oneOf:A("./oneOf"),pattern:A("./pattern"),properties:A("./properties"),propertyNames:A("./propertyNames"),required:A("./required"),uniqueItems:A("./uniqueItems"),validate:A("./validate")}},{"./_limit":13,"./_limitItems":14,"./_limitLength":15,"./_limitProperties":16,"./allOf":17,"./anyOf":18,"./comment":19,"./const":20,"./contains":21,"./dependencies":23,"./enum":24,"./format":25,"./if":26,"./items":28,"./multipleOf":29,"./not":30,"./oneOf":31,"./pattern":32,"./properties":33,"./propertyNames":34,"./ref":35,"./required":36,"./uniqueItems":37,"./validate":38}],28:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t="errs__"+n,l=e.util.copy(e),c="";l.level++;var f="valid"+l.level,p="i"+n,F=l.dataLevel=e.dataLevel+1,R="data"+F,g=e.baseId;if(r+="var "+t+" = errors;var "+v+";",Array.isArray(o)){var y=e.schema.additionalItems;if(y===!1){r+=" "+v+" = "+h+".length <= "+o.length+"; ";var D=P;P=e.errSchemaPath+"/additionalItems",r+=" if (!"+v+") { ";var x=x||[];x.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'additionalItems' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { limit: "+o.length+" } ",e.opts.messages!==!1&&(r+=" , message: 'should NOT have more than "+o.length+" items' "),e.opts.verbose&&(r+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var j=r;r=x.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+j+"]); ":r+=" validate.errors = ["+j+"]; return false; ":r+=" var err = "+j+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } ",P=D,$&&(c+="}",r+=" else { ")}var O=o;if(O){for(var d,b=-1,I=O.length-1;b<I;)if(d=O[b+=1],e.opts.strictKeywords?typeof d=="object"&&Object.keys(d).length>0||d===!1:e.util.schemaHasRules(d,e.RULES.all)){r+=" "+f+" = true; if ("+h+".length > "+b+") { ";var z=h+"["+b+"]";l.schema=d,l.schemaPath=E+"["+b+"]",l.errSchemaPath=P+"/"+b,l.errorPath=e.util.getPathExpr(e.errorPath,b,e.opts.jsonPointers,!0),l.dataPathArr[F]=b;var Q=e.validate(l);l.baseId=g,e.util.varOccurences(Q,R)<2?r+=" "+e.util.varReplace(Q,R,z)+" ":r+=" var "+R+" = "+z+"; "+Q+" ",r+=" } ",$&&(r+=" if ("+f+") { ",c+="}")}}if(typeof y=="object"&&(e.opts.strictKeywords?typeof y=="object"&&Object.keys(y).length>0||y===!1:e.util.schemaHasRules(y,e.RULES.all))){l.schema=y,l.schemaPath=e.schemaPath+".additionalItems",l.errSchemaPath=e.errSchemaPath+"/additionalItems",r+=" "+f+" = true; if ("+h+".length > "+o.length+") { for (var "+p+" = "+o.length+"; "+p+" < "+h+".length; "+p+"++) { ",l.errorPath=e.util.getPathExpr(e.errorPath,p,e.opts.jsonPointers,!0);var z=h+"["+p+"]";l.dataPathArr[F]=p;var Q=e.validate(l);l.baseId=g,e.util.varOccurences(Q,R)<2?r+=" "+e.util.varReplace(Q,R,z)+" ":r+=" var "+R+" = "+z+"; "+Q+" ",$&&(r+=" if (!"+f+") break; "),r+=" } } ",$&&(r+=" if ("+f+") { ",c+="}")}}else if(e.opts.strictKeywords?typeof o=="object"&&Object.keys(o).length>0||o===!1:e.util.schemaHasRules(o,e.RULES.all)){l.schema=o,l.schemaPath=E,l.errSchemaPath=P,r+=" for (var "+p+" = 0; "+p+" < "+h+".length; "+p+"++) { ",l.errorPath=e.util.getPathExpr(e.errorPath,p,e.opts.jsonPointers,!0);var z=h+"["+p+"]";l.dataPathArr[F]=p;var Q=e.validate(l);l.baseId=g,e.util.varOccurences(Q,R)<2?r+=" "+e.util.varReplace(Q,R,z)+" ":r+=" var "+R+" = "+z+"; "+Q+" ",$&&(r+=" if (!"+f+") break; "),r+=" }"}return $&&(r+=" "+c+" if ("+t+" == errors) {"),r}},{}],29:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v=e.opts.$data&&o&&o.$data,t;if(v?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",t="schema"+n):t=o,!(v||typeof o=="number"))throw new Error(a+" must be number");r+="var division"+n+";if (",v&&(r+=" "+t+" !== undefined && ( typeof "+t+" != 'number' || "),r+=" (division"+n+" = "+h+" / "+t+", ",e.opts.multipleOfPrecision?r+=" Math.abs(Math.round(division"+n+") - division"+n+") > 1e-"+e.opts.multipleOfPrecision+" ":r+=" division"+n+" !== parseInt(division"+n+") ",r+=" ) ",v&&(r+=" ) "),r+=" ) { ";var l=l||[];l.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'multipleOf' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { multipleOf: "+t+" } ",e.opts.messages!==!1&&(r+=" , message: 'should be multiple of ",v?r+="' + "+t:r+=""+t+"'"),e.opts.verbose&&(r+=" , schema: ",v?r+="validate.schema"+E:r+=""+o,r+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var c=r;return r=l.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+c+"]); ":r+=" validate.errors = ["+c+"]; return false; ":r+=" var err = "+c+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+="} ",$&&(r+=" else { "),r}},{}],30:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="errs__"+n,t=e.util.copy(e);t.level++;var l="valid"+t.level;if(e.opts.strictKeywords?typeof o=="object"&&Object.keys(o).length>0||o===!1:e.util.schemaHasRules(o,e.RULES.all)){t.schema=o,t.schemaPath=E,t.errSchemaPath=P,r+=" var "+v+" = errors; ";var c=e.compositeRule;e.compositeRule=t.compositeRule=!0,t.createErrors=!1;var f;t.opts.allErrors&&(f=t.opts.allErrors,t.opts.allErrors=!1),r+=" "+e.validate(t)+" ",t.createErrors=!0,f&&(t.opts.allErrors=f),e.compositeRule=t.compositeRule=c,r+=" if ("+l+") { ";var p=p||[];p.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'not' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: {} ",e.opts.messages!==!1&&(r+=" , message: 'should NOT be valid' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var F=r;r=p.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+F+"]); ":r+=" validate.errors = ["+F+"]; return false; ":r+=" var err = "+F+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } else { errors = "+v+"; if (vErrors !== null) { if ("+v+") vErrors.length = "+v+"; else vErrors = null; } ",e.opts.allErrors&&(r+=" } ")}else r+=" var err = ",e.createErrors!==!1?(r+=" { keyword: 'not' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: {} ",e.opts.messages!==!1&&(r+=" , message: 'should NOT be valid' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",$&&(r+=" if (false) { ");return r}},{}],31:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t="errs__"+n,l=e.util.copy(e),c="";l.level++;var f="valid"+l.level,p=l.baseId,F="prevValid"+n,R="passingSchemas"+n;r+="var "+t+" = errors , "+F+" = false , "+v+" = false , "+R+" = null; ";var g=e.compositeRule;e.compositeRule=l.compositeRule=!0;var y=o;if(y)for(var D,x=-1,j=y.length-1;x<j;)D=y[x+=1],(e.opts.strictKeywords?typeof D=="object"&&Object.keys(D).length>0||D===!1:e.util.schemaHasRules(D,e.RULES.all))?(l.schema=D,l.schemaPath=E+"["+x+"]",l.errSchemaPath=P+"/"+x,r+=" "+e.validate(l)+" ",l.baseId=p):r+=" var "+f+" = true; ",x&&(r+=" if ("+f+" && "+F+") { "+v+" = false; "+R+" = ["+R+", "+x+"]; } else { ",c+="}"),r+=" if ("+f+") { "+v+" = "+F+" = true; "+R+" = "+x+"; }";return e.compositeRule=l.compositeRule=g,r+=""+c+"if (!"+v+") { var err = ",e.createErrors!==!1?(r+=" { keyword: 'oneOf' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { passingSchemas: "+R+" } ",e.opts.messages!==!1&&(r+=" , message: 'should match exactly one schema in oneOf' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&$&&(e.async?r+=" throw new ValidationError(vErrors); ":r+=" validate.errors = vErrors; return false; "),r+="} else { errors = "+t+"; if (vErrors !== null) { if ("+t+") vErrors.length = "+t+"; else vErrors = null; }",e.opts.allErrors&&(r+=" } "),r}},{}],32:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v=e.opts.$data&&o&&o.$data,t;v?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",t="schema"+n):t=o;var l=v?"(new RegExp("+t+"))":e.usePattern(o);r+="if ( ",v&&(r+=" ("+t+" !== undefined && typeof "+t+" != 'string') || "),r+=" !"+l+".test("+h+") ) { ";var c=c||[];c.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'pattern' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { pattern: ",v?r+=""+t:r+=""+e.util.toQuotedString(o),r+=" } ",e.opts.messages!==!1&&(r+=` , message: 'should match pattern "`,v?r+="' + "+t+" + '":r+=""+e.util.escapeQuotes(o),r+=`"' `),e.opts.verbose&&(r+=" , schema: ",v?r+="validate.schema"+E:r+=""+e.util.toQuotedString(o),r+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var f=r;return r=c.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+f+"]); ":r+=" validate.errors = ["+f+"]; return false; ":r+=" var err = "+f+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+="} ",$&&(r+=" else { "),r}},{}],33:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="errs__"+n,t=e.util.copy(e),l="";t.level++;var c="valid"+t.level,f="key"+n,p="idx"+n,F=t.dataLevel=e.dataLevel+1,R="data"+F,g="dataProperties"+n,y=Object.keys(o||{}).filter(X),D=e.schema.patternProperties||{},x=Object.keys(D).filter(X),j=e.schema.additionalProperties,O=y.length||x.length,d=j===!1,b=typeof j=="object"&&Object.keys(j).length,I=e.opts.removeAdditional,z=d||b||I,Q=e.opts.ownProperties,H=e.baseId,ee=e.schema.required;if(ee&&!(e.opts.$data&&ee.$data)&&ee.length<e.opts.loopRequired)var B=e.util.toHash(ee);function X(Ae){return Ae!=="__proto__"}if(r+="var "+v+" = errors;var "+c+" = true;",Q&&(r+=" var "+g+" = undefined;"),z){if(Q?r+=" "+g+" = "+g+" || Object.keys("+h+"); for (var "+p+"=0; "+p+"<"+g+".length; "+p+"++) { var "+f+" = "+g+"["+p+"]; ":r+=" for (var "+f+" in "+h+") { ",O){if(r+=" var isAdditional"+n+" = !(false ",y.length)if(y.length>8)r+=" || validate.schema"+E+".hasOwnProperty("+f+") ";else{var J=y;if(J)for(var G,Se=-1,_e=J.length-1;Se<_e;)G=J[Se+=1],r+=" || "+f+" == "+e.util.toQuotedString(G)+" "}if(x.length){var $e=x;if($e)for(var fe,de=-1,m=$e.length-1;de<m;)fe=$e[de+=1],r+=" || "+e.usePattern(fe)+".test("+f+") "}r+=" ); if (isAdditional"+n+") { "}if(I=="all")r+=" delete "+h+"["+f+"]; ";else{var C=e.errorPath,q="' + "+f+" + '";if(e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPathExpr(e.errorPath,f,e.opts.jsonPointers)),d)if(I)r+=" delete "+h+"["+f+"]; ";else{r+=" "+c+" = false; ";var Y=P;P=e.errSchemaPath+"/additionalProperties";var N=N||[];N.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'additionalProperties' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { additionalProperty: '"+q+"' } ",e.opts.messages!==!1&&(r+=" , message: '",e.opts._errorDataPathProperty?r+="is an invalid additional property":r+="should NOT have additional properties",r+="' "),e.opts.verbose&&(r+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var V=r;r=N.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+V+"]); ":r+=" validate.errors = ["+V+"]; return false; ":r+=" var err = "+V+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",P=Y,$&&(r+=" break; ")}else if(b)if(I=="failing"){r+=" var "+v+" = errors; ";var W=e.compositeRule;e.compositeRule=t.compositeRule=!0,t.schema=j,t.schemaPath=e.schemaPath+".additionalProperties",t.errSchemaPath=e.errSchemaPath+"/additionalProperties",t.errorPath=e.opts._errorDataPathProperty?e.errorPath:e.util.getPathExpr(e.errorPath,f,e.opts.jsonPointers);var re=h+"["+f+"]";t.dataPathArr[F]=f;var k=e.validate(t);t.baseId=H,e.util.varOccurences(k,R)<2?r+=" "+e.util.varReplace(k,R,re)+" ":r+=" var "+R+" = "+re+"; "+k+" ",r+=" if (!"+c+") { errors = "+v+"; if (validate.errors !== null) { if (errors) validate.errors.length = errors; else validate.errors = null; } delete "+h+"["+f+"]; } ",e.compositeRule=t.compositeRule=W}else{t.schema=j,t.schemaPath=e.schemaPath+".additionalProperties",t.errSchemaPath=e.errSchemaPath+"/additionalProperties",t.errorPath=e.opts._errorDataPathProperty?e.errorPath:e.util.getPathExpr(e.errorPath,f,e.opts.jsonPointers);var re=h+"["+f+"]";t.dataPathArr[F]=f;var k=e.validate(t);t.baseId=H,e.util.varOccurences(k,R)<2?r+=" "+e.util.varReplace(k,R,re)+" ":r+=" var "+R+" = "+re+"; "+k+" ",$&&(r+=" if (!"+c+") break; ")}e.errorPath=C}O&&(r+=" } "),r+=" } ",$&&(r+=" if ("+c+") { ",l+="}")}var ue=e.opts.useDefaults&&!e.compositeRule;if(y.length){var he=y;if(he)for(var G,se=-1,be=he.length-1;se<be;){G=he[se+=1];var ge=o[G];if(e.opts.strictKeywords?typeof ge=="object"&&Object.keys(ge).length>0||ge===!1:e.util.schemaHasRules(ge,e.RULES.all)){var we=e.util.getProperty(G),re=h+we,ce=ue&&ge.default!==void 0;t.schema=ge,t.schemaPath=E+we,t.errSchemaPath=P+"/"+e.util.escapeFragment(G),t.errorPath=e.util.getPath(e.errorPath,G,e.opts.jsonPointers),t.dataPathArr[F]=e.util.toQuotedString(G);var k=e.validate(t);if(t.baseId=H,e.util.varOccurences(k,R)<2){k=e.util.varReplace(k,R,re);var ye=re}else{var ye=R;r+=" var "+R+" = "+re+"; "}if(ce)r+=" "+k+" ";else{if(B&&B[G]){r+=" if ( "+ye+" === undefined ",Q&&(r+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(G)+"') "),r+=") { "+c+" = false; ";var C=e.errorPath,Y=P,xe=e.util.escapeQuotes(G);e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPath(C,G,e.opts.jsonPointers)),P=e.errSchemaPath+"/required";var N=N||[];N.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { missingProperty: '"+xe+"' } ",e.opts.messages!==!1&&(r+=" , message: '",e.opts._errorDataPathProperty?r+="is a required property":r+="should have required property \\'"+xe+"\\'",r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var V=r;r=N.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+V+"]); ":r+=" validate.errors = ["+V+"]; return false; ":r+=" var err = "+V+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",P=Y,e.errorPath=C,r+=" } else { "}else $?(r+=" if ( "+ye+" === undefined ",Q&&(r+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(G)+"') "),r+=") { "+c+" = true; } else { "):(r+=" if ("+ye+" !== undefined ",Q&&(r+=" && Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(G)+"') "),r+=" ) { ");r+=" "+k+" } "}}$&&(r+=" if ("+c+") { ",l+="}")}}if(x.length){var Re=x;if(Re)for(var fe,tr=-1,lr=Re.length-1;tr<lr;){fe=Re[tr+=1];var ge=D[fe];if(e.opts.strictKeywords?typeof ge=="object"&&Object.keys(ge).length>0||ge===!1:e.util.schemaHasRules(ge,e.RULES.all)){t.schema=ge,t.schemaPath=e.schemaPath+".patternProperties"+e.util.getProperty(fe),t.errSchemaPath=e.errSchemaPath+"/patternProperties/"+e.util.escapeFragment(fe),Q?r+=" "+g+" = "+g+" || Object.keys("+h+"); for (var "+p+"=0; "+p+"<"+g+".length; "+p+"++) { var "+f+" = "+g+"["+p+"]; ":r+=" for (var "+f+" in "+h+") { ",r+=" if ("+e.usePattern(fe)+".test("+f+")) { ",t.errorPath=e.util.getPathExpr(e.errorPath,f,e.opts.jsonPointers);var re=h+"["+f+"]";t.dataPathArr[F]=f;var k=e.validate(t);t.baseId=H,e.util.varOccurences(k,R)<2?r+=" "+e.util.varReplace(k,R,re)+" ":r+=" var "+R+" = "+re+"; "+k+" ",$&&(r+=" if (!"+c+") break; "),r+=" } ",$&&(r+=" else "+c+" = true; "),r+=" } ",$&&(r+=" if ("+c+") { ",l+="}")}}}return $&&(r+=" "+l+" if ("+v+" == errors) {"),r}},{}],34:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="errs__"+n,t=e.util.copy(e),l="";t.level++;var c="valid"+t.level;if(r+="var "+v+" = errors;",e.opts.strictKeywords?typeof o=="object"&&Object.keys(o).length>0||o===!1:e.util.schemaHasRules(o,e.RULES.all)){t.schema=o,t.schemaPath=E,t.errSchemaPath=P;var f="key"+n,p="idx"+n,F="i"+n,R="' + "+f+" + '",g=t.dataLevel=e.dataLevel+1,y="data"+g,D="dataProperties"+n,x=e.opts.ownProperties,j=e.baseId;x&&(r+=" var "+D+" = undefined; "),x?r+=" "+D+" = "+D+" || Object.keys("+h+"); for (var "+p+"=0; "+p+"<"+D+".length; "+p+"++) { var "+f+" = "+D+"["+p+"]; ":r+=" for (var "+f+" in "+h+") { ",r+=" var startErrs"+n+" = errors; ";var O=f,d=e.compositeRule;e.compositeRule=t.compositeRule=!0;var b=e.validate(t);t.baseId=j,e.util.varOccurences(b,y)<2?r+=" "+e.util.varReplace(b,y,O)+" ":r+=" var "+y+" = "+O+"; "+b+" ",e.compositeRule=t.compositeRule=d,r+=" if (!"+c+") { for (var "+F+"=startErrs"+n+"; "+F+"<errors; "+F+"++) { vErrors["+F+"].propertyName = "+f+"; } var err = ",e.createErrors!==!1?(r+=" { keyword: 'propertyNames' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { propertyName: '"+R+"' } ",e.opts.messages!==!1&&(r+=" , message: 'property name \\'"+R+"\\' is invalid' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!e.compositeRule&&$&&(e.async?r+=" throw new ValidationError(vErrors); ":r+=" validate.errors = vErrors; return false; "),$&&(r+=" break; "),r+=" } }"}return $&&(r+=" "+l+" if ("+v+" == errors) {"),r}},{}],35:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.errSchemaPath+"/"+a,P=!e.opts.allErrors,$="data"+(S||""),h="valid"+n,v,t;if(o=="#"||o=="#/")e.isRoot?(v=e.async,t="validate"):(v=e.root.schema.$async===!0,t="root.refVal[0]");else{var l=e.resolveRef(e.baseId,o,e.isRoot);if(l===void 0){var c=e.MissingRefError.message(e.baseId,o);if(e.opts.missingRefs=="fail"){e.logger.error(c);var f=f||[];f.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '$ref' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(E)+" , params: { ref: '"+e.util.escapeQuotes(o)+"' } ",e.opts.messages!==!1&&(r+=" , message: 'can\\'t resolve reference "+e.util.escapeQuotes(o)+"' "),e.opts.verbose&&(r+=" , schema: "+e.util.toQuotedString(o)+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+$+" "),r+=" } "):r+=" {} ";var p=r;r=f.pop(),!e.compositeRule&&P?e.async?r+=" throw new ValidationError(["+p+"]); ":r+=" validate.errors = ["+p+"]; return false; ":r+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",P&&(r+=" if (false) { ")}else if(e.opts.missingRefs=="ignore")e.logger.warn(c),P&&(r+=" if (true) { ");else throw new e.MissingRefError(e.baseId,o,c)}else if(l.inline){var F=e.util.copy(e);F.level++;var R="valid"+F.level;F.schema=l.schema,F.schemaPath="",F.errSchemaPath=o;var g=e.validate(F).replace(/validate\.schema/g,l.code);r+=" "+g+" ",P&&(r+=" if ("+R+") { ")}else v=l.$async===!0||e.async&&l.$async!==!1,t=l.code}if(t){var f=f||[];f.push(r),r="",e.opts.passContext?r+=" "+t+".call(this, ":r+=" "+t+"( ",r+=" "+$+", (dataPath || '')",e.errorPath!='""'&&(r+=" + "+e.errorPath);var y=S?"data"+(S-1||""):"parentData",D=S?e.dataPathArr[S]:"parentDataProperty";r+=" , "+y+" , "+D+", rootData) ";var x=r;if(r=f.pop(),v){if(!e.async)throw new Error("async schema referenced by sync schema");P&&(r+=" var "+h+"; "),r+=" try { await "+x+"; ",P&&(r+=" "+h+" = true; "),r+=" } catch (e) { if (!(e instanceof ValidationError)) throw e; if (vErrors === null) vErrors = e.errors; else vErrors = vErrors.concat(e.errors); errors = vErrors.length; ",P&&(r+=" "+h+" = false; "),r+=" } ",P&&(r+=" if ("+h+") { ")}else r+=" if (!"+x+") { if (vErrors === null) vErrors = "+t+".errors; else vErrors = vErrors.concat("+t+".errors); errors = vErrors.length; } ",P&&(r+=" else { ")}return r}},{}],36:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t=e.opts.$data&&o&&o.$data,l;t?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",l="schema"+n):l=o;var c="schema"+n;if(!t)if(o.length<e.opts.loopRequired&&e.schema.properties&&Object.keys(e.schema.properties).length){var f=[],p=o;if(p)for(var F,R=-1,g=p.length-1;R<g;){F=p[R+=1];var y=e.schema.properties[F];y&&(e.opts.strictKeywords?typeof y=="object"&&Object.keys(y).length>0||y===!1:e.util.schemaHasRules(y,e.RULES.all))||(f[f.length]=F)}}else var f=o;if(t||f.length){var D=e.errorPath,x=t||f.length>=e.opts.loopRequired,j=e.opts.ownProperties;if($)if(r+=" var missing"+n+"; ",x){t||(r+=" var "+c+" = validate.schema"+E+"; ");var O="i"+n,d="schema"+n+"["+O+"]",b="' + "+d+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPathExpr(D,d,e.opts.jsonPointers)),r+=" var "+v+" = true; ",t&&(r+=" if (schema"+n+" === undefined) "+v+" = true; else if (!Array.isArray(schema"+n+")) "+v+" = false; else {"),r+=" for (var "+O+" = 0; "+O+" < "+c+".length; "+O+"++) { "+v+" = "+h+"["+c+"["+O+"]] !== undefined ",j&&(r+=" && Object.prototype.hasOwnProperty.call("+h+", "+c+"["+O+"]) "),r+="; if (!"+v+") break; } ",t&&(r+=" } "),r+=" if (!"+v+") { ";var I=I||[];I.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { missingProperty: '"+b+"' } ",e.opts.messages!==!1&&(r+=" , message: '",e.opts._errorDataPathProperty?r+="is a required property":r+="should have required property \\'"+b+"\\'",r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var z=r;r=I.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+z+"]); ":r+=" validate.errors = ["+z+"]; return false; ":r+=" var err = "+z+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } else { "}else{r+=" if ( ";var Q=f;if(Q)for(var H,O=-1,ee=Q.length-1;O<ee;){H=Q[O+=1],O&&(r+=" || ");var B=e.util.getProperty(H),X=h+B;r+=" ( ( "+X+" === undefined ",j&&(r+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(H)+"') "),r+=") && (missing"+n+" = "+e.util.toQuotedString(e.opts.jsonPointers?H:B)+") ) "}r+=") { ";var d="missing"+n,b="' + "+d+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.opts.jsonPointers?e.util.getPathExpr(D,d,!0):D+" + "+d);var I=I||[];I.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { missingProperty: '"+b+"' } ",e.opts.messages!==!1&&(r+=" , message: '",e.opts._errorDataPathProperty?r+="is a required property":r+="should have required property \\'"+b+"\\'",r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var z=r;r=I.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+z+"]); ":r+=" validate.errors = ["+z+"]; return false; ":r+=" var err = "+z+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } else { "}else if(x){t||(r+=" var "+c+" = validate.schema"+E+"; ");var O="i"+n,d="schema"+n+"["+O+"]",b="' + "+d+" + '";e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPathExpr(D,d,e.opts.jsonPointers)),t&&(r+=" if ("+c+" && !Array.isArray("+c+")) { var err = ",e.createErrors!==!1?(r+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { missingProperty: '"+b+"' } ",e.opts.messages!==!1&&(r+=" , message: '",e.opts._errorDataPathProperty?r+="is a required property":r+="should have required property \\'"+b+"\\'",r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } else if ("+c+" !== undefined) { "),r+=" for (var "+O+" = 0; "+O+" < "+c+".length; "+O+"++) { if ("+h+"["+c+"["+O+"]] === undefined ",j&&(r+=" || ! Object.prototype.hasOwnProperty.call("+h+", "+c+"["+O+"]) "),r+=") { var err = ",e.createErrors!==!1?(r+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { missingProperty: '"+b+"' } ",e.opts.messages!==!1&&(r+=" , message: '",e.opts._errorDataPathProperty?r+="is a required property":r+="should have required property \\'"+b+"\\'",r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } } ",t&&(r+=" } ")}else{var J=f;if(J)for(var H,G=-1,Se=J.length-1;G<Se;){H=J[G+=1];var B=e.util.getProperty(H),b=e.util.escapeQuotes(H),X=h+B;e.opts._errorDataPathProperty&&(e.errorPath=e.util.getPath(D,H,e.opts.jsonPointers)),r+=" if ( "+X+" === undefined ",j&&(r+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+e.util.escapeQuotes(H)+"') "),r+=") { var err = ",e.createErrors!==!1?(r+=" { keyword: 'required' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { missingProperty: '"+b+"' } ",e.opts.messages!==!1&&(r+=" , message: '",e.opts._errorDataPathProperty?r+="is a required property":r+="should have required property \\'"+b+"\\'",r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+E+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ",r+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}e.errorPath=D}else $&&(r+=" if (true) {");return r}},{}],37:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r=" ",n=e.level,S=e.dataLevel,o=e.schema[a],E=e.schemaPath+e.util.getProperty(a),P=e.errSchemaPath+"/"+a,$=!e.opts.allErrors,h="data"+(S||""),v="valid"+n,t=e.opts.$data&&o&&o.$data,l;if(t?(r+=" var schema"+n+" = "+e.util.getData(o.$data,S,e.dataPathArr)+"; ",l="schema"+n):l=o,(o||t)&&e.opts.uniqueItems!==!1){t&&(r+=" var "+v+"; if ("+l+" === false || "+l+" === undefined) "+v+" = true; else if (typeof "+l+" != 'boolean') "+v+" = false; else { "),r+=" var i = "+h+".length , "+v+" = true , j; if (i > 1) { ";var c=e.schema.items&&e.schema.items.type,f=Array.isArray(c);if(!c||c=="object"||c=="array"||f&&(c.indexOf("object")>=0||c.indexOf("array")>=0))r+=" outer: for (;i--;) { for (j = i; j--;) { if (equal("+h+"[i], "+h+"[j])) { "+v+" = false; break outer; } } } ";else{r+=" var itemIndices = {}, item; for (;i--;) { var item = "+h+"[i]; ";var p="checkDataType"+(f?"s":"");r+=" if ("+e.util[p](c,"item",e.opts.strictNumbers,!0)+") continue; ",f&&(r+=` if (typeof item == 'string') item = '"' + item; `),r+=" if (typeof itemIndices[item] == 'number') { "+v+" = false; j = itemIndices[item]; break; } itemIndices[item] = i; } "}r+=" } ",t&&(r+=" } "),r+=" if (!"+v+") { ";var F=F||[];F.push(r),r="",e.createErrors!==!1?(r+=" { keyword: 'uniqueItems' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(P)+" , params: { i: i, j: j } ",e.opts.messages!==!1&&(r+=" , message: 'should NOT have duplicate items (items ## ' + j + ' and ' + i + ' are identical)' "),e.opts.verbose&&(r+=" , schema: ",t?r+="validate.schema"+E:r+=""+o,r+=" , parentSchema: validate.schema"+e.schemaPath+" , data: "+h+" "),r+=" } "):r+=" {} ";var R=r;r=F.pop(),!e.compositeRule&&$?e.async?r+=" throw new ValidationError(["+R+"]); ":r+=" validate.errors = ["+R+"]; return false; ":r+=" var err = "+R+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } ",$&&(r+=" else { ")}else $&&(r+=" if (true) { ");return r}},{}],38:[function(A,U,K){"use strict";U.exports=function(e,a,L){var r="",n=e.schema.$async===!0,S=e.util.schemaHasRulesExcept(e.schema,e.RULES.all,"$ref"),o=e.self._getId(e.schema);if(e.opts.strictKeywords){var E=e.util.schemaUnknownRules(e.schema,e.RULES.keywords);if(E){var P="unknown keyword: "+E;if(e.opts.strictKeywords==="log")e.logger.warn(P);else throw new Error(P)}}if(e.isTop&&(r+=" var validate = ",n&&(e.async=!0,r+="async "),r+="function(data, dataPath, parentData, parentDataProperty, rootData) { 'use strict'; ",o&&(e.opts.sourceCode||e.opts.processCode)&&(r+=" "+("/*# sourceURL="+o+" */")+" ")),typeof e.schema=="boolean"||!(S||e.schema.$ref)){var a="false schema",$=e.level,h=e.dataLevel,v=e.schema[a],t=e.schemaPath+e.util.getProperty(a),l=e.errSchemaPath+"/"+a,y=!e.opts.allErrors,j,c="data"+(h||""),g="valid"+$;if(e.schema===!1){e.isTop?y=!0:r+=" var "+g+" = false; ";var f=f||[];f.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(j||"false schema")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(l)+" , params: {} ",e.opts.messages!==!1&&(r+=" , message: 'boolean schema is false' "),e.opts.verbose&&(r+=" , schema: false , parentSchema: validate.schema"+e.schemaPath+" , data: "+c+" "),r+=" } "):r+=" {} ";var p=r;r=f.pop(),!e.compositeRule&&y?e.async?r+=" throw new ValidationError(["+p+"]); ":r+=" validate.errors = ["+p+"]; return false; ":r+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else e.isTop?n?r+=" return data; ":r+=" validate.errors = null; return true; ":r+=" var "+g+" = true; ";return e.isTop&&(r+=" }; return validate; "),r}if(e.isTop){var F=e.isTop,$=e.level=0,h=e.dataLevel=0,c="data";if(e.rootId=e.resolve.fullPath(e.self._getId(e.root.schema)),e.baseId=e.baseId||e.rootId,delete e.isTop,e.dataPathArr=[""],e.schema.default!==void 0&&e.opts.useDefaults&&e.opts.strictDefaults){var R="default is ignored in the schema root";if(e.opts.strictDefaults==="log")e.logger.warn(R);else throw new Error(R)}r+=" var vErrors = null; ",r+=" var errors = 0; ",r+=" if (rootData === undefined) rootData = data; "}else{var $=e.level,h=e.dataLevel,c="data"+(h||"");if(o&&(e.baseId=e.resolve.url(e.baseId,o)),n&&!e.async)throw new Error("async schema in sync schema");r+=" var errs_"+$+" = errors;"}var g="valid"+$,y=!e.opts.allErrors,D="",x="",j,O=e.schema.type,d=Array.isArray(O);if(O&&e.opts.nullable&&e.schema.nullable===!0&&(d?O.indexOf("null")==-1&&(O=O.concat("null")):O!="null"&&(O=[O,"null"],d=!0)),d&&O.length==1&&(O=O[0],d=!1),e.schema.$ref&&S){if(e.opts.extendRefs=="fail")throw new Error('$ref: validation keywords used in schema at path "'+e.errSchemaPath+'" (see option extendRefs)');e.opts.extendRefs!==!0&&(S=!1,e.logger.warn('$ref: keywords ignored in schema at path "'+e.errSchemaPath+'"'))}if(e.schema.$comment&&e.opts.$comment&&(r+=" "+e.RULES.all.$comment.code(e,"$comment")),O){if(e.opts.coerceTypes)var b=e.util.coerceToTypes(e.opts.coerceTypes,O);var I=e.RULES.types[O];if(b||d||I===!0||I&&!ge(I)){var t=e.schemaPath+".type",l=e.errSchemaPath+"/type",t=e.schemaPath+".type",l=e.errSchemaPath+"/type",z=d?"checkDataTypes":"checkDataType";if(r+=" if ("+e.util[z](O,c,e.opts.strictNumbers,!0)+") { ",b){var Q="dataType"+$,H="coerced"+$;r+=" var "+Q+" = typeof "+c+"; var "+H+" = undefined; ",e.opts.coerceTypes=="array"&&(r+=" if ("+Q+" == 'object' && Array.isArray("+c+") && "+c+".length == 1) { "+c+" = "+c+"[0]; "+Q+" = typeof "+c+"; if ("+e.util.checkDataType(e.schema.type,c,e.opts.strictNumbers)+") "+H+" = "+c+"; } "),r+=" if ("+H+" !== undefined) ; ";var ee=b;if(ee)for(var B,X=-1,J=ee.length-1;X<J;)B=ee[X+=1],B=="string"?r+=" else if ("+Q+" == 'number' || "+Q+" == 'boolean') "+H+" = '' + "+c+"; else if ("+c+" === null) "+H+" = ''; ":B=="number"||B=="integer"?(r+=" else if ("+Q+" == 'boolean' || "+c+" === null || ("+Q+" == 'string' && "+c+" && "+c+" == +"+c+" ",B=="integer"&&(r+=" && !("+c+" % 1)"),r+=")) "+H+" = +"+c+"; "):B=="boolean"?r+=" else if ("+c+" === 'false' || "+c+" === 0 || "+c+" === null) "+H+" = false; else if ("+c+" === 'true' || "+c+" === 1) "+H+" = true; ":B=="null"?r+=" else if ("+c+" === '' || "+c+" === 0 || "+c+" === false) "+H+" = null; ":e.opts.coerceTypes=="array"&&B=="array"&&(r+=" else if ("+Q+" == 'string' || "+Q+" == 'number' || "+Q+" == 'boolean' || "+c+" == null) "+H+" = ["+c+"]; ");r+=" else { ";var f=f||[];f.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(j||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(l)+" , params: { type: '",d?r+=""+O.join(","):r+=""+O,r+="' } ",e.opts.messages!==!1&&(r+=" , message: 'should be ",d?r+=""+O.join(","):r+=""+O,r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+c+" "),r+=" } "):r+=" {} ";var p=r;r=f.pop(),!e.compositeRule&&y?e.async?r+=" throw new ValidationError(["+p+"]); ":r+=" validate.errors = ["+p+"]; return false; ":r+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } if ("+H+" !== undefined) { ";var G=h?"data"+(h-1||""):"parentData",Se=h?e.dataPathArr[h]:"parentDataProperty";r+=" "+c+" = "+H+"; ",h||(r+="if ("+G+" !== undefined)"),r+=" "+G+"["+Se+"] = "+H+"; } "}else{var f=f||[];f.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(j||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(l)+" , params: { type: '",d?r+=""+O.join(","):r+=""+O,r+="' } ",e.opts.messages!==!1&&(r+=" , message: 'should be ",d?r+=""+O.join(","):r+=""+O,r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+c+" "),r+=" } "):r+=" {} ";var p=r;r=f.pop(),!e.compositeRule&&y?e.async?r+=" throw new ValidationError(["+p+"]); ":r+=" validate.errors = ["+p+"]; return false; ":r+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}r+=" } "}}if(e.schema.$ref&&!S)r+=" "+e.RULES.all.$ref.code(e,"$ref")+" ",y&&(r+=" } if (errors === ",F?r+="0":r+="errs_"+$,r+=") { ",x+="}");else{var _e=e.RULES;if(_e){for(var I,$e=-1,fe=_e.length-1;$e<fe;)if(I=_e[$e+=1],ge(I)){if(I.type&&(r+=" if ("+e.util.checkDataType(I.type,c,e.opts.strictNumbers)+") { "),e.opts.useDefaults){if(I.type=="object"&&e.schema.properties){var v=e.schema.properties,de=Object.keys(v),m=de;if(m)for(var C,q=-1,Y=m.length-1;q<Y;){C=m[q+=1];var N=v[C];if(N.default!==void 0){var V=c+e.util.getProperty(C);if(e.compositeRule){if(e.opts.strictDefaults){var R="default is ignored for: "+V;if(e.opts.strictDefaults==="log")e.logger.warn(R);else throw new Error(R)}}else r+=" if ("+V+" === undefined ",e.opts.useDefaults=="empty"&&(r+=" || "+V+" === null || "+V+" === '' "),r+=" ) "+V+" = ",e.opts.useDefaults=="shared"?r+=" "+e.useDefault(N.default)+" ":r+=" "+JSON.stringify(N.default)+" ",r+="; "}}}else if(I.type=="array"&&Array.isArray(e.schema.items)){var W=e.schema.items;if(W){for(var N,X=-1,re=W.length-1;X<re;)if(N=W[X+=1],N.default!==void 0){var V=c+"["+X+"]";if(e.compositeRule){if(e.opts.strictDefaults){var R="default is ignored for: "+V;if(e.opts.strictDefaults==="log")e.logger.warn(R);else throw new Error(R)}}else r+=" if ("+V+" === undefined ",e.opts.useDefaults=="empty"&&(r+=" || "+V+" === null || "+V+" === '' "),r+=" ) "+V+" = ",e.opts.useDefaults=="shared"?r+=" "+e.useDefault(N.default)+" ":r+=" "+JSON.stringify(N.default)+" ",r+="; "}}}}var k=I.rules;if(k){for(var ue,he=-1,se=k.length-1;he<se;)if(ue=k[he+=1],we(ue)){var be=ue.code(e,ue.keyword,I.type);be&&(r+=" "+be+" ",y&&(D+="}"))}}if(y&&(r+=" "+D+" ",D=""),I.type&&(r+=" } ",O&&O===I.type&&!b)){r+=" else { ";var t=e.schemaPath+".type",l=e.errSchemaPath+"/type",f=f||[];f.push(r),r="",e.createErrors!==!1?(r+=" { keyword: '"+(j||"type")+"' , dataPath: (dataPath || '') + "+e.errorPath+" , schemaPath: "+e.util.toQuotedString(l)+" , params: { type: '",d?r+=""+O.join(","):r+=""+O,r+="' } ",e.opts.messages!==!1&&(r+=" , message: 'should be ",d?r+=""+O.join(","):r+=""+O,r+="' "),e.opts.verbose&&(r+=" , schema: validate.schema"+t+" , parentSchema: validate.schema"+e.schemaPath+" , data: "+c+" "),r+=" } "):r+=" {} ";var p=r;r=f.pop(),!e.compositeRule&&y?e.async?r+=" throw new ValidationError(["+p+"]); ":r+=" validate.errors = ["+p+"]; return false; ":r+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",r+=" } "}y&&(r+=" if (errors === ",F?r+="0":r+="errs_"+$,r+=") { ",x+="}")}}}y&&(r+=" "+x+" "),F?(n?(r+=" if (errors === 0) return data; ",r+=" else throw new ValidationError(vErrors); "):(r+=" validate.errors = vErrors; ",r+=" return errors === 0; "),r+=" }; return validate;"):r+=" var "+g+" = errors === errs_"+$+";";function ge(ye){for(var xe=ye.rules,Re=0;Re<xe.length;Re++)if(we(xe[Re]))return!0}function we(ye){return e.schema[ye.keyword]!==void 0||ye.implements&&ce(ye)}function ce(ye){for(var xe=ye.implements,Re=0;Re<xe.length;Re++)if(e.schema[xe[Re]]!==void 0)return!0}return r}},{}],39:[function(A,U,K){"use strict";var T=/^[a-z_$][a-z0-9_$-]*$/i,e=A("./dotjs/custom"),a=A("./definition_schema");U.exports={add:L,get:r,remove:n,validate:S};function L(o,E){var P=this.RULES;if(P.keywords[o])throw new Error("Keyword "+o+" is already defined");if(!T.test(o))throw new Error("Keyword "+o+" is not a valid identifier");if(E){this.validateKeyword(E,!0);var $=E.type;if(Array.isArray($))for(var h=0;h<$.length;h++)t(o,$[h],E);else t(o,$,E);var v=E.metaSchema;v&&(E.$data&&this._opts.$data&&(v={anyOf:[v,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]}),E.validateSchema=this.compile(v,!0))}P.keywords[o]=P.all[o]=!0;function t(l,c,f){for(var p,F=0;F<P.length;F++){var R=P[F];if(R.type==c){p=R;break}}p||(p={type:c,rules:[]},P.push(p));var g={keyword:l,definition:f,custom:!0,code:e,implements:f.implements};p.rules.push(g),P.custom[l]=g}return this}function r(o){var E=this.RULES.custom[o];return E?E.definition:this.RULES.keywords[o]||!1}function n(o){var E=this.RULES;delete E.keywords[o],delete E.all[o],delete E.custom[o];for(var P=0;P<E.length;P++)for(var $=E[P].rules,h=0;h<$.length;h++)if($[h].keyword==o){$.splice(h,1);break}return this}function S(o,E){S.errors=null;var P=this._validateKeyword=this._validateKeyword||this.compile(a,!0);if(P(o))return!0;if(S.errors=P.errors,E)throw new Error("custom keyword definition is invalid: "+this.errorsText(P.errors));return!1}},{"./definition_schema":12,"./dotjs/custom":22}],40:[function(A,U,K){U.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON Schema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}},{}],41:[function(A,U,K){U.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}},{}],42:[function(A,U,K){"use strict";U.exports=function T(e,a){if(e===a)return!0;if(e&&a&&typeof e=="object"&&typeof a=="object"){if(e.constructor!==a.constructor)return!1;var L,r,n;if(Array.isArray(e)){if(L=e.length,L!=a.length)return!1;for(r=L;r--!==0;)if(!T(e[r],a[r]))return!1;return!0}if(e.constructor===RegExp)return e.source===a.source&&e.flags===a.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===a.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===a.toString();if(n=Object.keys(e),L=n.length,L!==Object.keys(a).length)return!1;for(r=L;r--!==0;)if(!Object.prototype.hasOwnProperty.call(a,n[r]))return!1;for(r=L;r--!==0;){var S=n[r];if(!T(e[S],a[S]))return!1}return!0}return e!==e&&a!==a}},{}],43:[function(A,U,K){"use strict";U.exports=function(T,e){e||(e={}),typeof e=="function"&&(e={cmp:e});var a=typeof e.cycles=="boolean"?e.cycles:!1,L=e.cmp&&function(n){return function(S){return function(o,E){var P={key:o,value:S[o]},$={key:E,value:S[E]};return n(P,$)}}}(e.cmp),r=[];return function n(S){if(S&&S.toJSON&&typeof S.toJSON=="function"&&(S=S.toJSON()),S!==void 0){if(typeof S=="number")return isFinite(S)?""+S:"null";if(typeof S!="object")return JSON.stringify(S);var o,E;if(Array.isArray(S)){for(E="[",o=0;o<S.length;o++)o&&(E+=","),E+=n(S[o])||"null";return E+"]"}if(S===null)return"null";if(r.indexOf(S)!==-1){if(a)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var P=r.push(S)-1,$=Object.keys(S).sort(L&&L(S));for(E="",o=0;o<$.length;o++){var h=$[o],v=n(S[h]);v&&(E&&(E+=","),E+=JSON.stringify(h)+":"+v)}return r.splice(P,1),"{"+E+"}"}}(T)}},{}],44:[function(A,U,K){"use strict";var T=U.exports=function(L,r,n){typeof r=="function"&&(n=r,r={}),n=r.cb||n;var S=typeof n=="function"?n:n.pre||function(){},o=n.post||function(){};e(r,S,o,L,"",L)};T.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0},T.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},T.propsKeywords={definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},T.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function e(L,r,n,S,o,E,P,$,h,v){if(S&&typeof S=="object"&&!Array.isArray(S)){r(S,o,E,P,$,h,v);for(var t in S){var l=S[t];if(Array.isArray(l)){if(t in T.arrayKeywords)for(var c=0;c<l.length;c++)e(L,r,n,l[c],o+"/"+t+"/"+c,E,o,t,S,c)}else if(t in T.propsKeywords){if(l&&typeof l=="object")for(var f in l)e(L,r,n,l[f],o+"/"+t+"/"+a(f),E,o,t,S,f)}else(t in T.keywords||L.allKeys&&!(t in T.skipKeywords))&&e(L,r,n,l,o+"/"+t,E,o,t,S)}n(S,o,E,P,$,h,v)}}function a(L){return L.replace(/~/g,"~0").replace(/\//g,"~1")}},{}],45:[function(A,U,K){/** @license URI.js v4.4.0 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */(function(T,e){typeof K=="object"&&typeof U<"u"?e(K):typeof Ue=="function"&&Ue.amd?Ue(["exports"],e):e(T.URI=T.URI||{})})(this,function(T){"use strict";function e(){for(var i=arguments.length,s=Array(i),u=0;u<i;u++)s[u]=arguments[u];if(s.length>1){s[0]=s[0].slice(0,-1);for(var _=s.length-1,w=1;w<_;++w)s[w]=s[w].slice(1,-1);return s[_]=s[_].slice(1),s.join("")}else return s[0]}function a(i){return"(?:"+i+")"}function L(i){return i===void 0?"undefined":i===null?"null":Object.prototype.toString.call(i).split(" ").pop().split("]").shift().toLowerCase()}function r(i){return i.toUpperCase()}function n(i){return i!=null?i instanceof Array?i:typeof i.length!="number"||i.split||i.setInterval||i.call?[i]:Array.prototype.slice.call(i):[]}function S(i,s){var u=i;if(s)for(var _ in s)u[_]=s[_];return u}function o(i){var s="[A-Za-z]",u="[\\x0D]",_="[0-9]",w="[\\x22]",M=e(_,"[A-Fa-f]"),Z="[\\x0A]",te="[\\x20]",ne=a(a("%[EFef]"+M+"%"+M+M+"%"+M+M)+"|"+a("%[89A-Fa-f]"+M+"%"+M+M)+"|"+a("%"+M+M)),Pe="[\\:\\/\\?\\#\\[\\]\\@]",ae="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",pe=e(Pe,ae),Ee=i?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",ve=i?"[\\uE000-\\uF8FF]":"[]",oe=e(s,_,"[\\-\\.\\_\\~]",Ee),me=a(s+e(s,_,"[\\+\\-\\.]")+"*"),le=a(a(ne+"|"+e(oe,ae,"[\\:]"))+"*"),ze=a(a("25[0-5]")+"|"+a("2[0-4]"+_)+"|"+a("1"+_+_)+"|"+a("[1-9]"+_)+"|"+_),De=a(a("25[0-5]")+"|"+a("2[0-4]"+_)+"|"+a("1"+_+_)+"|"+a("0?[1-9]"+_)+"|0?0?"+_),Fe=a(De+"\\."+De+"\\."+De+"\\."+De),ie=a(M+"{1,4}"),Oe=a(a(ie+"\\:"+ie)+"|"+Fe),Ie=a(a(ie+"\\:")+"{6}"+Oe),Ce=a("\\:\\:"+a(ie+"\\:")+"{5}"+Oe),Ve=a(a(ie)+"?\\:\\:"+a(ie+"\\:")+"{4}"+Oe),Te=a(a(a(ie+"\\:")+"{0,1}"+ie)+"?\\:\\:"+a(ie+"\\:")+"{3}"+Oe),Xe=a(a(a(ie+"\\:")+"{0,2}"+ie)+"?\\:\\:"+a(ie+"\\:")+"{2}"+Oe),sr=a(a(a(ie+"\\:")+"{0,3}"+ie)+"?\\:\\:"+ie+"\\:"+Oe),or=a(a(a(ie+"\\:")+"{0,4}"+ie)+"?\\:\\:"+Oe),qe=a(a(a(ie+"\\:")+"{0,5}"+ie)+"?\\:\\:"+ie),Ke=a(a(a(ie+"\\:")+"{0,6}"+ie)+"?\\:\\:"),Le=a([Ie,Ce,Ve,Te,Xe,sr,or,qe,Ke].join("|")),Be=a(a(oe+"|"+ne)+"+"),fr=a(Le+"\\%25"+Be),Qe=a(Le+a("\\%25|\\%(?!"+M+"{2})")+Be),Tr=a("[vV]"+M+"+\\."+e(oe,ae,"[\\:]")+"+"),Lr=a("\\["+a(Qe+"|"+Le+"|"+Tr)+"\\]"),Er=a(a(ne+"|"+e(oe,ae))+"*"),We=a(Lr+"|"+Fe+"(?!"+Er+")|"+Er),er=a(_+"*"),yr=a(a(le+"@")+"?"+We+a("\\:"+er)+"?"),rr=a(ne+"|"+e(oe,ae,"[\\:\\@]")),Nr=a(rr+"*"),Sr=a(rr+"+"),Ur=a(a(ne+"|"+e(oe,ae,"[\\@]"))+"+"),Ne=a(a("\\/"+Nr)+"*"),ke=a("\\/"+a(Sr+Ne)+"?"),ur=a(Ur+Ne),nr=a(Sr+Ne),Je="(?!"+rr+")",Hr=a(Ne+"|"+ke+"|"+ur+"|"+nr+"|"+Je),Ge=a(a(rr+"|"+e("[\\/\\?]",ve))+"*"),ar=a(a(rr+"|[\\/\\?]")+"*"),$r=a(a("\\/\\/"+yr+Ne)+"|"+ke+"|"+nr+"|"+Je),zr=a(me+"\\:"+$r+a("\\?"+Ge)+"?"+a("\\#"+ar)+"?"),Vr=a(a("\\/\\/"+yr+Ne)+"|"+ke+"|"+ur+"|"+Je),Qr=a(Vr+a("\\?"+Ge)+"?"+a("\\#"+ar)+"?"),qr=a(zr+"|"+Qr),Kr=a(me+"\\:"+$r+a("\\?"+Ge)+"?"),Br="^("+me+")\\:"+a(a("\\/\\/("+a("("+le+")@")+"?("+We+")"+a("\\:("+er+")")+"?)")+"?("+Ne+"|"+ke+"|"+nr+"|"+Je+")")+a("\\?("+Ge+")")+"?"+a("\\#("+ar+")")+"?$",kr="^(){0}"+a(a("\\/\\/("+a("("+le+")@")+"?("+We+")"+a("\\:("+er+")")+"?)")+"?("+Ne+"|"+ke+"|"+ur+"|"+Je+")")+a("\\?("+Ge+")")+"?"+a("\\#("+ar+")")+"?$",Jr="^("+me+")\\:"+a(a("\\/\\/("+a("("+le+")@")+"?("+We+")"+a("\\:("+er+")")+"?)")+"?("+Ne+"|"+ke+"|"+nr+"|"+Je+")")+a("\\?("+Ge+")")+"?$",Gr="^"+a("\\#("+ar+")")+"?$",Yr="^"+a("("+le+")@")+"?("+We+")"+a("\\:("+er+")")+"?$";return{NOT_SCHEME:new RegExp(e("[^]",s,_,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",oe,ae),"g"),NOT_HOST:new RegExp(e("[^\\%\\[\\]\\:]",oe,ae),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",oe,ae),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",oe,ae),"g"),NOT_QUERY:new RegExp(e("[^\\%]",oe,ae,"[\\:\\@\\/\\?]",ve),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",oe,ae,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",oe,ae),"g"),UNRESERVED:new RegExp(oe,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",oe,pe),"g"),PCT_ENCODED:new RegExp(ne,"g"),IPV4ADDRESS:new RegExp("^("+Fe+")$"),IPV6ADDRESS:new RegExp("^\\[?("+Le+")"+a(a("\\%25|\\%(?!"+M+"{2})")+"("+Be+")")+"?\\]?$")}}var E=o(!1),P=o(!0),$=function(){function i(s,u){var _=[],w=!0,M=!1,Z=void 0;try{for(var te=s[Symbol.iterator](),ne;!(w=(ne=te.next()).done)&&(_.push(ne.value),!(u&&_.length===u));w=!0);}catch(Pe){M=!0,Z=Pe}finally{try{!w&&te.return&&te.return()}finally{if(M)throw Z}}return _}return function(s,u){if(Array.isArray(s))return s;if(Symbol.iterator in Object(s))return i(s,u);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(i){if(Array.isArray(i)){for(var s=0,u=Array(i.length);s<i.length;s++)u[s]=i[s];return u}else return Array.from(i)},v=2147483647,t=36,l=1,c=26,f=38,p=700,F=72,R=128,g="-",y=/^xn--/,D=/[^\0-\x7E]/,x=/[\x2E\u3002\uFF0E\uFF61]/g,j={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},O=t-l,d=Math.floor,b=String.fromCharCode;function I(i){throw new RangeError(j[i])}function z(i,s){for(var u=[],_=i.length;_--;)u[_]=s(i[_]);return u}function Q(i,s){var u=i.split("@"),_="";u.length>1&&(_=u[0]+"@",i=u[1]),i=i.replace(x,".");var w=i.split("."),M=z(w,s).join(".");return _+M}function H(i){for(var s=[],u=0,_=i.length;u<_;){var w=i.charCodeAt(u++);if(w>=55296&&w<=56319&&u<_){var M=i.charCodeAt(u++);(M&64512)==56320?s.push(((w&1023)<<10)+(M&1023)+65536):(s.push(w),u--)}else s.push(w)}return s}var ee=function(s){return String.fromCodePoint.apply(String,h(s))},B=function(s){return s-48<10?s-22:s-65<26?s-65:s-97<26?s-97:t},X=function(s,u){return s+22+75*(s<26)-((u!=0)<<5)},J=function(s,u,_){var w=0;for(s=_?d(s/p):s>>1,s+=d(s/u);s>O*c>>1;w+=t)s=d(s/O);return d(w+(O+1)*s/(s+f))},G=function(s){var u=[],_=s.length,w=0,M=R,Z=F,te=s.lastIndexOf(g);te<0&&(te=0);for(var ne=0;ne<te;++ne)s.charCodeAt(ne)>=128&&I("not-basic"),u.push(s.charCodeAt(ne));for(var Pe=te>0?te+1:0;Pe<_;){for(var ae=w,pe=1,Ee=t;;Ee+=t){Pe>=_&&I("invalid-input");var ve=B(s.charCodeAt(Pe++));(ve>=t||ve>d((v-w)/pe))&&I("overflow"),w+=ve*pe;var oe=Ee<=Z?l:Ee>=Z+c?c:Ee-Z;if(ve<oe)break;var me=t-oe;pe>d(v/me)&&I("overflow"),pe*=me}var le=u.length+1;Z=J(w-ae,le,ae==0),d(w/le)>v-M&&I("overflow"),M+=d(w/le),w%=le,u.splice(w++,0,M)}return String.fromCodePoint.apply(String,u)},Se=function(s){var u=[];s=H(s);var _=s.length,w=R,M=0,Z=F,te=!0,ne=!1,Pe=void 0;try{for(var ae=s[Symbol.iterator](),pe;!(te=(pe=ae.next()).done);te=!0){var Ee=pe.value;Ee<128&&u.push(b(Ee))}}catch(Qe){ne=!0,Pe=Qe}finally{try{!te&&ae.return&&ae.return()}finally{if(ne)throw Pe}}var ve=u.length,oe=ve;for(ve&&u.push(g);oe<_;){var me=v,le=!0,ze=!1,De=void 0;try{for(var Fe=s[Symbol.iterator](),ie;!(le=(ie=Fe.next()).done);le=!0){var Oe=ie.value;Oe>=w&&Oe<me&&(me=Oe)}}catch(Qe){ze=!0,De=Qe}finally{try{!le&&Fe.return&&Fe.return()}finally{if(ze)throw De}}var Ie=oe+1;me-w>d((v-M)/Ie)&&I("overflow"),M+=(me-w)*Ie,w=me;var Ce=!0,Ve=!1,Te=void 0;try{for(var Xe=s[Symbol.iterator](),sr;!(Ce=(sr=Xe.next()).done);Ce=!0){var or=sr.value;if(or<w&&++M>v&&I("overflow"),or==w){for(var qe=M,Ke=t;;Ke+=t){var Le=Ke<=Z?l:Ke>=Z+c?c:Ke-Z;if(qe<Le)break;var Be=qe-Le,fr=t-Le;u.push(b(X(Le+Be%fr,0))),qe=d(Be/fr)}u.push(b(X(qe,0))),Z=J(M,Ie,oe==ve),M=0,++oe}}}catch(Qe){Ve=!0,Te=Qe}finally{try{!Ce&&Xe.return&&Xe.return()}finally{if(Ve)throw Te}}++M,++w}return u.join("")},_e=function(s){return Q(s,function(u){return y.test(u)?G(u.slice(4).toLowerCase()):u})},$e=function(s){return Q(s,function(u){return D.test(u)?"xn--"+Se(u):u})},fe={version:"2.1.0",ucs2:{decode:H,encode:ee},decode:G,encode:Se,toASCII:$e,toUnicode:_e},de={};function m(i){var s=i.charCodeAt(0),u=void 0;return s<16?u="%0"+s.toString(16).toUpperCase():s<128?u="%"+s.toString(16).toUpperCase():s<2048?u="%"+(s>>6|192).toString(16).toUpperCase()+"%"+(s&63|128).toString(16).toUpperCase():u="%"+(s>>12|224).toString(16).toUpperCase()+"%"+(s>>6&63|128).toString(16).toUpperCase()+"%"+(s&63|128).toString(16).toUpperCase(),u}function C(i){for(var s="",u=0,_=i.length;u<_;){var w=parseInt(i.substr(u+1,2),16);if(w<128)s+=String.fromCharCode(w),u+=3;else if(w>=194&&w<224){if(_-u>=6){var M=parseInt(i.substr(u+4,2),16);s+=String.fromCharCode((w&31)<<6|M&63)}else s+=i.substr(u,6);u+=6}else if(w>=224){if(_-u>=9){var Z=parseInt(i.substr(u+4,2),16),te=parseInt(i.substr(u+7,2),16);s+=String.fromCharCode((w&15)<<12|(Z&63)<<6|te&63)}else s+=i.substr(u,9);u+=9}else s+=i.substr(u,3),u+=3}return s}function q(i,s){function u(_){var w=C(_);return w.match(s.UNRESERVED)?w:_}return i.scheme&&(i.scheme=String(i.scheme).replace(s.PCT_ENCODED,u).toLowerCase().replace(s.NOT_SCHEME,"")),i.userinfo!==void 0&&(i.userinfo=String(i.userinfo).replace(s.PCT_ENCODED,u).replace(s.NOT_USERINFO,m).replace(s.PCT_ENCODED,r)),i.host!==void 0&&(i.host=String(i.host).replace(s.PCT_ENCODED,u).toLowerCase().replace(s.NOT_HOST,m).replace(s.PCT_ENCODED,r)),i.path!==void 0&&(i.path=String(i.path).replace(s.PCT_ENCODED,u).replace(i.scheme?s.NOT_PATH:s.NOT_PATH_NOSCHEME,m).replace(s.PCT_ENCODED,r)),i.query!==void 0&&(i.query=String(i.query).replace(s.PCT_ENCODED,u).replace(s.NOT_QUERY,m).replace(s.PCT_ENCODED,r)),i.fragment!==void 0&&(i.fragment=String(i.fragment).replace(s.PCT_ENCODED,u).replace(s.NOT_FRAGMENT,m).replace(s.PCT_ENCODED,r)),i}function Y(i){return i.replace(/^0*(.*)/,"$1")||"0"}function N(i,s){var u=i.match(s.IPV4ADDRESS)||[],_=$(u,2),w=_[1];return w?w.split(".").map(Y).join("."):i}function V(i,s){var u=i.match(s.IPV6ADDRESS)||[],_=$(u,3),w=_[1],M=_[2];if(w){for(var Z=w.toLowerCase().split("::").reverse(),te=$(Z,2),ne=te[0],Pe=te[1],ae=Pe?Pe.split(":").map(Y):[],pe=ne.split(":").map(Y),Ee=s.IPV4ADDRESS.test(pe[pe.length-1]),ve=Ee?7:8,oe=pe.length-ve,me=Array(ve),le=0;le<ve;++le)me[le]=ae[le]||pe[oe+le]||"";Ee&&(me[ve-1]=N(me[ve-1],s));var ze=me.reduce(function(Ie,Ce,Ve){if(!Ce||Ce==="0"){var Te=Ie[Ie.length-1];Te&&Te.index+Te.length===Ve?Te.length++:Ie.push({index:Ve,length:1})}return Ie},[]),De=ze.sort(function(Ie,Ce){return Ce.length-Ie.length})[0],Fe=void 0;if(De&&De.length>1){var ie=me.slice(0,De.index),Oe=me.slice(De.index+De.length);Fe=ie.join(":")+"::"+Oe.join(":")}else Fe=me.join(":");return M&&(Fe+="%"+M),Fe}else return i}var W=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,re="".match(/(){0}/)[1]===void 0;function k(i){var s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},u={},_=s.iri!==!1?P:E;s.reference==="suffix"&&(i=(s.scheme?s.scheme+":":"")+"//"+i);var w=i.match(W);if(w){re?(u.scheme=w[1],u.userinfo=w[3],u.host=w[4],u.port=parseInt(w[5],10),u.path=w[6]||"",u.query=w[7],u.fragment=w[8],isNaN(u.port)&&(u.port=w[5])):(u.scheme=w[1]||void 0,u.userinfo=i.indexOf("@")!==-1?w[3]:void 0,u.host=i.indexOf("//")!==-1?w[4]:void 0,u.port=parseInt(w[5],10),u.path=w[6]||"",u.query=i.indexOf("?")!==-1?w[7]:void 0,u.fragment=i.indexOf("#")!==-1?w[8]:void 0,isNaN(u.port)&&(u.port=i.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?w[4]:void 0)),u.host&&(u.host=V(N(u.host,_),_)),u.scheme===void 0&&u.userinfo===void 0&&u.host===void 0&&u.port===void 0&&!u.path&&u.query===void 0?u.reference="same-document":u.scheme===void 0?u.reference="relative":u.fragment===void 0?u.reference="absolute":u.reference="uri",s.reference&&s.reference!=="suffix"&&s.reference!==u.reference&&(u.error=u.error||"URI is not a "+s.reference+" reference.");var M=de[(s.scheme||u.scheme||"").toLowerCase()];if(!s.unicodeSupport&&(!M||!M.unicodeSupport)){if(u.host&&(s.domainHost||M&&M.domainHost))try{u.host=fe.toASCII(u.host.replace(_.PCT_ENCODED,C).toLowerCase())}catch(Z){u.error=u.error||"Host's domain name can not be converted to ASCII via punycode: "+Z}q(u,E)}else q(u,_);M&&M.parse&&M.parse(u,s)}else u.error=u.error||"URI can not be parsed.";return u}function ue(i,s){var u=s.iri!==!1?P:E,_=[];return i.userinfo!==void 0&&(_.push(i.userinfo),_.push("@")),i.host!==void 0&&_.push(V(N(String(i.host),u),u).replace(u.IPV6ADDRESS,function(w,M,Z){return"["+M+(Z?"%25"+Z:"")+"]"})),(typeof i.port=="number"||typeof i.port=="string")&&(_.push(":"),_.push(String(i.port))),_.length?_.join(""):void 0}var he=/^\.\.?\//,se=/^\/\.(\/|$)/,be=/^\/\.\.(\/|$)/,ge=/^\/?(?:.|\n)*?(?=\/|$)/;function we(i){for(var s=[];i.length;)if(i.match(he))i=i.replace(he,"");else if(i.match(se))i=i.replace(se,"/");else if(i.match(be))i=i.replace(be,"/"),s.pop();else if(i==="."||i==="..")i="";else{var u=i.match(ge);if(u){var _=u[0];i=i.slice(_.length),s.push(_)}else throw new Error("Unexpected dot segment condition")}return s.join("")}function ce(i){var s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},u=s.iri?P:E,_=[],w=de[(s.scheme||i.scheme||"").toLowerCase()];if(w&&w.serialize&&w.serialize(i,s),i.host&&!u.IPV6ADDRESS.test(i.host)){if(s.domainHost||w&&w.domainHost)try{i.host=s.iri?fe.toUnicode(i.host):fe.toASCII(i.host.replace(u.PCT_ENCODED,C).toLowerCase())}catch(te){i.error=i.error||"Host's domain name can not be converted to "+(s.iri?"Unicode":"ASCII")+" via punycode: "+te}}q(i,u),s.reference!=="suffix"&&i.scheme&&(_.push(i.scheme),_.push(":"));var M=ue(i,s);if(M!==void 0&&(s.reference!=="suffix"&&_.push("//"),_.push(M),i.path&&i.path.charAt(0)!=="/"&&_.push("/")),i.path!==void 0){var Z=i.path;!s.absolutePath&&(!w||!w.absolutePath)&&(Z=we(Z)),M===void 0&&(Z=Z.replace(/^\/\//,"/%2F")),_.push(Z)}return i.query!==void 0&&(_.push("?"),_.push(i.query)),i.fragment!==void 0&&(_.push("#"),_.push(i.fragment)),_.join("")}function ye(i,s){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},_=arguments[3],w={};return _||(i=k(ce(i,u),u),s=k(ce(s,u),u)),u=u||{},!u.tolerant&&s.scheme?(w.scheme=s.scheme,w.userinfo=s.userinfo,w.host=s.host,w.port=s.port,w.path=we(s.path||""),w.query=s.query):(s.userinfo!==void 0||s.host!==void 0||s.port!==void 0?(w.userinfo=s.userinfo,w.host=s.host,w.port=s.port,w.path=we(s.path||""),w.query=s.query):(s.path?(s.path.charAt(0)==="/"?w.path=we(s.path):((i.userinfo!==void 0||i.host!==void 0||i.port!==void 0)&&!i.path?w.path="/"+s.path:i.path?w.path=i.path.slice(0,i.path.lastIndexOf("/")+1)+s.path:w.path=s.path,w.path=we(w.path)),w.query=s.query):(w.path=i.path,s.query!==void 0?w.query=s.query:w.query=i.query),w.userinfo=i.userinfo,w.host=i.host,w.port=i.port),w.scheme=i.scheme),w.fragment=s.fragment,w}function xe(i,s,u){var _=S({scheme:"null"},u);return ce(ye(k(i,_),k(s,_),_,!0),_)}function Re(i,s){return typeof i=="string"?i=ce(k(i,s),s):L(i)==="object"&&(i=k(ce(i,s),s)),i}function tr(i,s,u){return typeof i=="string"?i=ce(k(i,u),u):L(i)==="object"&&(i=ce(i,u)),typeof s=="string"?s=ce(k(s,u),u):L(s)==="object"&&(s=ce(s,u)),i===s}function lr(i,s){return i&&i.toString().replace(!s||!s.iri?E.ESCAPE:P.ESCAPE,m)}function Ae(i,s){return i&&i.toString().replace(!s||!s.iri?E.PCT_ENCODED:P.PCT_ENCODED,C)}var Ye={scheme:"http",domainHost:!0,parse:function(s,u){return s.host||(s.error=s.error||"HTTP URIs must have a host."),s},serialize:function(s,u){var _=String(s.scheme).toLowerCase()==="https";return(s.port===(_?443:80)||s.port==="")&&(s.port=void 0),s.path||(s.path="/"),s}},hr={scheme:"https",domainHost:Ye.domainHost,parse:Ye.parse,serialize:Ye.serialize};function cr(i){return typeof i.secure=="boolean"?i.secure:String(i.scheme).toLowerCase()==="wss"}var Ze={scheme:"ws",domainHost:!0,parse:function(s,u){var _=s;return _.secure=cr(_),_.resourceName=(_.path||"/")+(_.query?"?"+_.query:""),_.path=void 0,_.query=void 0,_},serialize:function(s,u){if((s.port===(cr(s)?443:80)||s.port==="")&&(s.port=void 0),typeof s.secure=="boolean"&&(s.scheme=s.secure?"wss":"ws",s.secure=void 0),s.resourceName){var _=s.resourceName.split("?"),w=$(_,2),M=w[0],Z=w[1];s.path=M&&M!=="/"?M:void 0,s.query=Z,s.resourceName=void 0}return s.fragment=void 0,s}},vr={scheme:"wss",domainHost:Ze.domainHost,parse:Ze.parse,serialize:Ze.serialize},br={},_r=!0,dr="[A-Za-z0-9\\-\\.\\_\\~"+(_r?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",je="[0-9A-Fa-f]",wr=a(a("%[EFef]"+je+"%"+je+je+"%"+je+je)+"|"+a("%[89A-Fa-f]"+je+"%"+je+je)+"|"+a("%"+je+je)),Rr="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",Dr="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",Or=e(Dr,'[\\"\\\\]'),xr="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",Fr=new RegExp(dr,"g"),He=new RegExp(wr,"g"),Ir=new RegExp(e("[^]",Rr,"[\\.]",'[\\"]',Or),"g"),pr=new RegExp(e("[^]",dr,xr),"g"),Ar=pr;function ir(i){var s=C(i);return s.match(Fr)?s:i}var mr={scheme:"mailto",parse:function(s,u){var _=s,w=_.to=_.path?_.path.split(","):[];if(_.path=void 0,_.query){for(var M=!1,Z={},te=_.query.split("&"),ne=0,Pe=te.length;ne<Pe;++ne){var ae=te[ne].split("=");switch(ae[0]){case"to":for(var pe=ae[1].split(","),Ee=0,ve=pe.length;Ee<ve;++Ee)w.push(pe[Ee]);break;case"subject":_.subject=Ae(ae[1],u);break;case"body":_.body=Ae(ae[1],u);break;default:M=!0,Z[Ae(ae[0],u)]=Ae(ae[1],u);break}}M&&(_.headers=Z)}_.query=void 0;for(var oe=0,me=w.length;oe<me;++oe){var le=w[oe].split("@");if(le[0]=Ae(le[0]),u.unicodeSupport)le[1]=Ae(le[1],u).toLowerCase();else try{le[1]=fe.toASCII(Ae(le[1],u).toLowerCase())}catch(ze){_.error=_.error||"Email address's domain name can not be converted to ASCII via punycode: "+ze}w[oe]=le.join("@")}return _},serialize:function(s,u){var _=s,w=n(s.to);if(w){for(var M=0,Z=w.length;M<Z;++M){var te=String(w[M]),ne=te.lastIndexOf("@"),Pe=te.slice(0,ne).replace(He,ir).replace(He,r).replace(Ir,m),ae=te.slice(ne+1);try{ae=u.iri?fe.toUnicode(ae):fe.toASCII(Ae(ae,u).toLowerCase())}catch(oe){_.error=_.error||"Email address's domain name can not be converted to "+(u.iri?"Unicode":"ASCII")+" via punycode: "+oe}w[M]=Pe+"@"+ae}_.path=w.join(",")}var pe=s.headers=s.headers||{};s.subject&&(pe.subject=s.subject),s.body&&(pe.body=s.body);var Ee=[];for(var ve in pe)pe[ve]!==br[ve]&&Ee.push(ve.replace(He,ir).replace(He,r).replace(pr,m)+"="+pe[ve].replace(He,ir).replace(He,r).replace(Ar,m));return Ee.length&&(_.query=Ee.join("&")),_}},jr=/^([^\:]+)\:(.*)/,gr={scheme:"urn",parse:function(s,u){var _=s.path&&s.path.match(jr),w=s;if(_){var M=u.scheme||w.scheme||"urn",Z=_[1].toLowerCase(),te=_[2],ne=M+":"+(u.nid||Z),Pe=de[ne];w.nid=Z,w.nss=te,w.path=void 0,Pe&&(w=Pe.parse(w,u))}else w.error=w.error||"URN can not be parsed.";return w},serialize:function(s,u){var _=u.scheme||s.scheme||"urn",w=s.nid,M=_+":"+(u.nid||w),Z=de[M];Z&&(s=Z.serialize(s,u));var te=s,ne=s.nss;return te.path=(w||u.nid)+":"+ne,te}},Cr=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,Pr={scheme:"urn:uuid",parse:function(s,u){var _=s;return _.uuid=_.nss,_.nss=void 0,!u.tolerant&&(!_.uuid||!_.uuid.match(Cr))&&(_.error=_.error||"UUID is not valid."),_},serialize:function(s,u){var _=s;return _.nss=(s.uuid||"").toLowerCase(),_}};de[Ye.scheme]=Ye,de[hr.scheme]=hr,de[Ze.scheme]=Ze,de[vr.scheme]=vr,de[mr.scheme]=mr,de[gr.scheme]=gr,de[Pr.scheme]=Pr,T.SCHEMES=de,T.pctEncChar=m,T.pctDecChars=C,T.parse=k,T.removeDotSegments=we,T.serialize=ce,T.resolveComponents=ye,T.resolve=xe,T.normalize=Re,T.equal=tr,T.escapeComponent=lr,T.unescapeComponent=Ae,Object.defineProperty(T,"__esModule",{value:!0})})},{}],ajv:[function(A,U,K){"use strict";var T=A("./compile"),e=A("./compile/resolve"),a=A("./cache"),L=A("./compile/schema_obj"),r=A("fast-json-stable-stringify"),n=A("./compile/formats"),S=A("./compile/rules"),o=A("./data"),E=A("./compile/util");U.exports=l,l.prototype.validate=c,l.prototype.compile=f,l.prototype.addSchema=p,l.prototype.addMetaSchema=F,l.prototype.validateSchema=R,l.prototype.getSchema=y,l.prototype.removeSchema=j,l.prototype.addFormat=B,l.prototype.errorsText=ee,l.prototype._addSchema=d,l.prototype._compile=b,l.prototype.compileAsync=A("./compile/async");var P=A("./keyword");l.prototype.addKeyword=P.add,l.prototype.getKeyword=P.get,l.prototype.removeKeyword=P.remove,l.prototype.validateKeyword=P.validate;var $=A("./compile/error_classes");l.ValidationError=$.Validation,l.MissingRefError=$.MissingRef,l.$dataMetaSchema=o;var h="http://json-schema.org/draft-07/schema",v=["removeAdditional","useDefaults","coerceTypes","strictDefaults"],t=["/properties"];function l(m){if(!(this instanceof l))return new l(m);m=this._opts=E.copy(m)||{},fe(this),this._schemas={},this._refs={},this._fragments={},this._formats=n(m.format),this._cache=m.cache||new a,this._loadingSchemas={},this._compilations=[],this.RULES=S(),this._getId=I(m),m.loopRequired=m.loopRequired||1/0,m.errorDataPath=="property"&&(m._errorDataPathProperty=!0),m.serialize===void 0&&(m.serialize=r),this._metaOpts=$e(this),m.formats&&G(this),m.keywords&&Se(this),X(this),typeof m.meta=="object"&&this.addMetaSchema(m.meta),m.nullable&&this.addKeyword("nullable",{metaSchema:{type:"boolean"}}),J(this)}function c(m,C){var q;if(typeof m=="string"){if(q=this.getSchema(m),!q)throw new Error('no schema with key or ref "'+m+'"')}else{var Y=this._addSchema(m);q=Y.validate||this._compile(Y)}var N=q(C);return q.$async!==!0&&(this.errors=q.errors),N}function f(m,C){var q=this._addSchema(m,void 0,C);return q.validate||this._compile(q)}function p(m,C,q,Y){if(Array.isArray(m)){for(var N=0;N<m.length;N++)this.addSchema(m[N],void 0,q,Y);return this}var V=this._getId(m);if(V!==void 0&&typeof V!="string")throw new Error("schema id must be string");return C=e.normalizeId(C||V),_e(this,C),this._schemas[C]=this._addSchema(m,q,Y,!0),this}function F(m,C,q){return this.addSchema(m,C,q,!0),this}function R(m,C){var q=m.$schema;if(q!==void 0&&typeof q!="string")throw new Error("$schema must be a string");if(q=q||this._opts.defaultMeta||g(this),!q)return this.logger.warn("meta-schema not available"),this.errors=null,!0;var Y=this.validate(q,m);if(!Y&&C){var N="schema is invalid: "+this.errorsText();if(this._opts.validateSchema=="log")this.logger.error(N);else throw new Error(N)}return Y}function g(m){var C=m._opts.meta;return m._opts.defaultMeta=typeof C=="object"?m._getId(C)||C:m.getSchema(h)?h:void 0,m._opts.defaultMeta}function y(m){var C=x(this,m);switch(typeof C){case"object":return C.validate||this._compile(C);case"string":return this.getSchema(C);case"undefined":return D(this,m)}}function D(m,C){var q=e.schema.call(m,{schema:{}},C);if(q){var Y=q.schema,N=q.root,V=q.baseId,W=T.call(m,Y,N,void 0,V);return m._fragments[C]=new L({ref:C,fragment:!0,schema:Y,root:N,baseId:V,validate:W}),W}}function x(m,C){return C=e.normalizeId(C),m._schemas[C]||m._refs[C]||m._fragments[C]}function j(m){if(m instanceof RegExp)return O(this,this._schemas,m),O(this,this._refs,m),this;switch(typeof m){case"undefined":return O(this,this._schemas),O(this,this._refs),this._cache.clear(),this;case"string":var C=x(this,m);return C&&this._cache.del(C.cacheKey),delete this._schemas[m],delete this._refs[m],this;case"object":var q=this._opts.serialize,Y=q?q(m):m;this._cache.del(Y);var N=this._getId(m);N&&(N=e.normalizeId(N),delete this._schemas[N],delete this._refs[N])}return this}function O(m,C,q){for(var Y in C){var N=C[Y];!N.meta&&(!q||q.test(Y))&&(m._cache.del(N.cacheKey),delete C[Y])}}function d(m,C,q,Y){if(typeof m!="object"&&typeof m!="boolean")throw new Error("schema should be object or boolean");var N=this._opts.serialize,V=N?N(m):m,W=this._cache.get(V);if(W)return W;Y=Y||this._opts.addUsedSchema!==!1;var re=e.normalizeId(this._getId(m));re&&Y&&_e(this,re);var k=this._opts.validateSchema!==!1&&!C,ue;k&&!(ue=re&&re==e.normalizeId(m.$schema))&&this.validateSchema(m,!0);var he=e.ids.call(this,m),se=new L({id:re,schema:m,localRefs:he,cacheKey:V,meta:q});return re[0]!="#"&&Y&&(this._refs[re]=se),this._cache.put(V,se),k&&ue&&this.validateSchema(m,!0),se}function b(m,C){if(m.compiling)return m.validate=N,N.schema=m.schema,N.errors=null,N.root=C||N,m.schema.$async===!0&&(N.$async=!0),N;m.compiling=!0;var q;m.meta&&(q=this._opts,this._opts=this._metaOpts);var Y;try{Y=T.call(this,m.schema,C,m.localRefs)}catch(V){throw delete m.validate,V}finally{m.compiling=!1,m.meta&&(this._opts=q)}return m.validate=Y,m.refs=Y.refs,m.refVal=Y.refVal,m.root=Y.root,Y;function N(){var V=m.validate,W=V.apply(this,arguments);return N.errors=V.errors,W}}function I(m){switch(m.schemaId){case"auto":return H;case"id":return z;default:return Q}}function z(m){return m.$id&&this.logger.warn("schema $id ignored",m.$id),m.id}function Q(m){return m.id&&this.logger.warn("schema id ignored",m.id),m.$id}function H(m){if(m.$id&&m.id&&m.$id!=m.id)throw new Error("schema $id is different from id");return m.$id||m.id}function ee(m,C){if(m=m||this.errors,!m)return"No errors";C=C||{};for(var q=C.separator===void 0?", ":C.separator,Y=C.dataVar===void 0?"data":C.dataVar,N="",V=0;V<m.length;V++){var W=m[V];W&&(N+=Y+W.dataPath+" "+W.message+q)}return N.slice(0,-q.length)}function B(m,C){return typeof C=="string"&&(C=new RegExp(C)),this._formats[m]=C,this}function X(m){var C;if(m._opts.$data&&(C=A("./refs/data.json"),m.addMetaSchema(C,C.$id,!0)),m._opts.meta!==!1){var q=A("./refs/json-schema-draft-07.json");m._opts.$data&&(q=o(q,t)),m.addMetaSchema(q,h,!0),m._refs["http://json-schema.org/schema"]=h}}function J(m){var C=m._opts.schemas;if(C)if(Array.isArray(C))m.addSchema(C);else for(var q in C)m.addSchema(C[q],q)}function G(m){for(var C in m._opts.formats){var q=m._opts.formats[C];m.addFormat(C,q)}}function Se(m){for(var C in m._opts.keywords){var q=m._opts.keywords[C];m.addKeyword(C,q)}}function _e(m,C){if(m._schemas[C]||m._refs[C])throw new Error('schema with key or id "'+C+'" already exists')}function $e(m){for(var C=E.copy(m._opts),q=0;q<v.length;q++)delete C[v[q]];return C}function fe(m){var C=m._opts.logger;if(C===!1)m.logger={log:de,warn:de,error:de};else{if(C===void 0&&(C=console),!(typeof C=="object"&&C.log&&C.warn&&C.error))throw new Error("logger must implement log, warn and error methods");m.logger=C}}function de(){}},{"./cache":1,"./compile":5,"./compile/async":2,"./compile/error_classes":3,"./compile/formats":4,"./compile/resolve":6,"./compile/rules":7,"./compile/schema_obj":8,"./compile/util":10,"./data":11,"./keyword":39,"./refs/data.json":40,"./refs/json-schema-draft-07.json":41,"fast-json-stable-stringify":43}]},{},[])("ajv")});
2
+ //# sourceMappingURL=ajv.min.js.map