UNPKG

doormen

Version:

Validate, sanitize and assert: the silver bullet of data!

1 lines 138 kB
(function(e){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=e()}else if(typeof define==="function"&&define.amd){define([],e)}else{var t;if(typeof window!=="undefined"){t=window}else if(typeof global!=="undefined"){t=global}else if(typeof self!=="undefined"){t=self}else{t=this}t.doormen=e()}})(function(){var e,t,r;return function(){function u(i,a,s){function l(r,e){if(!a[r]){if(!i[r]){var t="function"==typeof require&&require;if(!e&&t)return t(r,!0);if(f)return f(r,!0);var n=new Error("Cannot find module '"+r+"'");throw n.code="MODULE_NOT_FOUND",n}var o=a[r]={exports:{}};i[r][0].call(o.exports,function(e){var t=i[r][1][e];return l(t||e)},o,o.exports,u,i,a,s)}return a[r].exports}for(var f="function"==typeof require&&require,e=0;e<s.length;e++)l(s[e]);return l}return u}()({1:[function(e,t,r){"use strict";function u(e,t,r={}){this.message=e;t=t||u;this.actual=r.actual;this.expected=r.expected;this.expectationPath=r.expectationPath;this.expectationType=r.expectationType;this.showDiff=!!r.showDiff;this.showPathDiff=!!r.showPathDiff;this.from=r.fromError;if(t instanceof Error){this.stack=t.stack}else if(Error.captureStackTrace){Error.captureStackTrace(this,t)}else{this.stack=Error().stack}}t.exports=u;u.prototype=Object.create(TypeError.prototype);u.prototype.constructor=u;u.prototype.name="AssertionError";const c=e("./assert.js");u.create=(e,t,r,n,...o)=>{var i,a;var s={inspect:false,glue:" and ",showDiff:false,showPathDiff:false,none:false};if(n&&typeof n==="object"){i=n.middleMessage||" to <insert here your expectation> ";n=n.expectationType}else{i=n}if(c[n]){Object.assign(s,c[n])}var l="";if(t!==c.NONE){a=h(t,o.length>=2);if(a.length>80){l+="Expected\n\t"+a+"\n"}else{l+="Expected "+a+" "}}else if(!s.none){l+="Expected nothing "}l+=i;if(o.length){if(s.inspect){l+=" "+o.map(e=>{a=h(e);if(a.length>80){return"\n\t"+a+"\n"}return a}).join(s.glue)}else{l+=" "+o.map(e=>{try{return""+e}catch(e){return"<cant-convert-to-string>"}}).join(s.glue)}}if(typeof r==="string"){if(r){l+=" (offending path: "+r+")"}if(r[0]==="."){r=r.slice(1)}}var f={actual:t,expectationPath:r,expectationType:n};if(o.length===1){f.expected=o[0];f.showDiff=s.showDiff;if(typeof r==="string"){f.showPathDiff=s.showPathDiff}}if(t instanceof Error){f.fromError=t}else if(t instanceof c.FunctionCall&&t.hasThrown){f.fromError=t.error}return new u(l,e,f)};const n=e("string-kit/lib/inspect.js").inspect;const o={style:"inline",depth:2,maxLength:80,outputMaxLength:400,noDescriptor:true,noType:true,noArrayProperty:true};function h(t,e){var r;if(typeof t==="function"){return(t.name||"(anonymous)")+"()"}if(t instanceof Error){r=""+t;if(e){let e=Object.assign({},t);delete e.message;delete e.safeMessage;delete e.stack;delete e.at;delete e.constructor;r+=" having "+n(o,e)}return r}if(t instanceof c.FunctionCall){r=t.function.name||"(anonymous)";if(t.args.length){let e="( "+t.args.map(e=>h(e)).join(", ")+" )";if(e.length>o.maxLength){e=e.slice(0,o.maxLength-1)+"…"}r+=e}else{r+="()"}if(t.hasThrown){r+=", which has thrown "+h(t.error,e)+","}return r}return n(o,t)}},{"./assert.js":4,"string-kit/lib/inspect.js":19}],2:[function(e,t,r){"use strict";function n(e){this.message=e;if(Error.captureStackTrace){Error.captureStackTrace(this,n)}else{Object.defineProperty(this,"stack",{value:Error().stack,enumerable:true,configurable:true})}}t.exports=n;n.prototype=Object.create(TypeError.prototype);n.prototype.constructor=n;n.prototype.name="SchemaError"},{}],3:[function(e,t,r){"use strict";function n(e,t){this.message=e;if(t){this.at=this.path=t.path}if(Error.captureStackTrace){Error.captureStackTrace(this,n)}else{Object.defineProperty(this,"stack",{value:Error().stack,enumerable:true,configurable:true})}}t.exports=n;n.prototype=Object.create(TypeError.prototype);n.prototype.constructor=n;n.prototype.name="ValidatorError"},{}],4:[function(e,t,r){"use strict";const a={};t.exports=a;const o=e("./typeCheckers.js");const s=e("./isEqual.js");const n={unordered:true};const i={around:true};const l={like:true};const f={like:true,unordered:true};const u={like:true,around:true};const c={like:true,oneWay:true};const h={like:true,oneWay:true,around:true};const p={oneWay:true};const d={oneWay:true,around:true};const y=new Set(["a","e","i","o","u","y","A","E","I","O","U","Y"]);const g=e("./AssertionError.js");a.NONE={};function b(e,t,r,...n){this.function=e;this.isAsync=t;this.this=r;this.args=n;this.hasThrown=false;this.error=undefined;this.return=undefined;try{this.return=this.function.call(this.this||null,...this.args)}catch(e){this.hasThrown=true;this.error=e}if(this.isAsync){if(this.hasThrown){this.promise=Promise.resolve()}else{this.promise=Promise.resolve(this.return).then(e=>this.return=e,e=>{this.hasThrown=true;this.error=e})}}}a.FunctionCall=b;function m(e){return!e||typeof e!=="object"?[e]:Array.isArray(e)?e:typeof e.values==="function"?[...e.values()]:Object.values(e)}a._toArrayOfValues=m;function w(e){return!e||typeof e!=="object"?new Set([e]):e instanceof Set?e:Array.isArray(e)?new Set(e):typeof e.values==="function"?new Set(e.values()):new Set(Object.values(e))}a._toSetOfValues=w;a["to be defined"]=a.defined=a.isDefined=(e,t)=>{if(t===undefined){throw g.create(e,t,null,"to be defined")}};a["to be not defined"]=a["to not be defined"]=a["not to be defined"]=a["to be undefined"]=a.undefined=a.isUndefined=(e,t)=>{if(t!==undefined){throw g.create(e,t,null,"to be undefined")}};a["to be ok"]=a["to be truthy"]=a.ok=a.isOk=a.truthy=a.isTruthy=(e,t)=>{if(!t){throw g.create(e,t,null,"to be truthy")}};a["to be not ok"]=a["to not be ok"]=a["not to be ok"]=a["to be not truthy"]=a["to not be truthy"]=a["not to be truthy"]=a["to be falsy"]=a.nok=a.ko=a.isNotOk=a.falsy=a.isFalsy=(e,t)=>{if(t){throw g.create(e,t,null,"to be falsy")}};a["to be true"]=a.true=a.isTrue=(e,t)=>{if(t!==true){throw g.create(e,t,null,"to be true")}};a["to be not true"]=a["to not be true"]=a["not to be true"]=a.notTrue=a.isNotTrue=(e,t)=>{if(t===true){throw g.create(e,t,null,"not to be true")}};a["to be false"]=a.false=a.isFalse=(e,t)=>{if(t!==false){throw g.create(e,t,null,"to be false")}};a["to be not false"]=a["to not be false"]=a["not to be false"]=a.notFalse=a.isNotFalse=(e,t)=>{if(t===false){throw g.create(e,t,null,"not to be false")}};a["to be null"]=a.null=a.isNull=(e,t)=>{if(t!==null){throw g.create(e,t,null,"to be null")}};a["to be not null"]=a["to not be null"]=a["not to be null"]=a.notNull=a.isNotNull=(e,t)=>{if(t===null){throw g.create(e,t,null,"not to be null")}};a["to be NaN"]=a["to be nan"]=a.NaN=a.isNaN=(e,t)=>{if(!Number.isNaN(t)){throw g.create(e,t,null,"to be NaN")}};a["to be not NaN"]=a["to not be NaN"]=a["not to be NaN"]=a["to be not nan"]=a["to not be nan"]=a["not to be nan"]=a.notNaN=a.isNotNaN=(e,t)=>{if(Number.isNaN(t)){throw g.create(e,t,null,"not to be NaN")}};a["to be finite"]=a.finite=(e,t)=>{if(typeof t!=="number"){throw g.create(e,t,null,"to be a number")}if(Number.isNaN(t)||t===Infinity||t===-Infinity){throw g.create(e,t,null,"to be finite")}};a["to be not finite"]=a["to not be finite"]=a["not to be finite"]=a.notFinite=(e,t)=>{if(typeof t!=="number"){throw g.create(e,t,null,"to be a number")}if(!Number.isNaN(t)&&t!==Infinity&&t!==-Infinity){throw g.create(e,t,null,"to be finite")}};a["to be"]=a.strictEqual=(e,t,r)=>{if(t!==r&&!(Number.isNaN(t)&&Number.isNaN(r))){throw g.create(e,t,null,"to be",r)}};a.strictEqual.showDiff=true;a.strictEqual.inspect=true;a["to be not"]=a["to not be"]=a["not to be"]=a.notStrictEqual=(e,t,r)=>{if(t===r||Number.isNaN(t)&&Number.isNaN(r)){throw g.create(e,t,null,"not to be",r)}};a.notStrictEqual.inspect=true;a["to be equal to"]=a["to equal"]=a["to eql"]=a.equal=(e,t,r)=>{if(!s(t,r)){throw g.create(e,t,s.getLastPath(),"to equal",r)}};a.equal.showDiff=true;a.equal.inspect=true;a["to be not equal to"]=a["to not be equal to"]=a["not to be equal to"]=a["to not equal"]=a["not to equal"]=a["to not eql"]=a["not to eql"]=a.notEqual=(e,t,r)=>{if(s(t,r)){throw g.create(e,t,null,"not to equal",r)}};a.notEqual.inspect=true;a["to be equal to unordered"]=a["to equal unordered"]=a.unorderedEqual=(e,t,r)=>{if(!s(t,r,n)){throw g.create(e,t,s.getLastPath(),"to equal unordered",r)}};a.unorderedEqual.inspect=true;a["to be not equal to unordered"]=a["to not be equal to unordered"]=a["not to be equal to unordered"]=a["to not equal unordered"]=a["not to equal unordered"]=a.notUnorderedEqual=(e,t,r)=>{if(s(t,r,n)){throw g.create(e,t,null,"not to equal unordered",r)}};a.notUnorderedEqual.inspect=true;a["to equal around"]=a.equalAround=(e,t,r)=>{if(!s(t,r,i)){throw g.create(e,t,s.getLastPath(),"to equal around",r)}};a.equalAround.showDiff=true;a.equalAround.inspect=true;a["to not equal around"]=a["not to equal around"]=a.notEqualAround=(e,t,r)=>{if(s(t,r,i)){throw g.create(e,t,null,"not to equal around",r)}};a.notEqualAround.inspect=true;a["to be like"]=a["to be alike"]=a["to be alike to"]=a.like=(e,t,r)=>{if(!s(t,r,l)){throw g.create(e,t,s.getLastPath(),"to be like",r)}};a.like.showDiff=true;a.like.inspect=true;a["to be not like"]=a["to not be like"]=a["not to be like"]=a["to be not alike"]=a["to not be alike"]=a["not to be alike"]=a["to be not alike to"]=a["to not be alike to"]=a["not to be alike to"]=a.notLike=(e,t,r)=>{if(s(t,r,l)){throw g.create(e,t,null,"not to be like",r)}};a.notLike.inspect=true;a["to be like unordered"]=a["to be alike unordered"]=a["to be alike to unordered"]=a.unorderedLike=(e,t,r)=>{if(!s(t,r,f)){throw g.create(e,t,s.getLastPath(),"to be like unordered",r)}};a.unorderedLike.inspect=true;a["to be not like unordered"]=a["to not be like unordered"]=a["not to be like unordered"]=a["to be not alike unordered"]=a["to not be alike unordered"]=a["not to be alike unordered"]=a["to be not alike to unordered"]=a["to not be alike to unordered"]=a["not to be alike to unordered"]=a.notUnorderedLike=(e,t,r)=>{if(s(t,r,f)){throw g.create(e,t,null,"not to be like unordered",r)}};a.notUnorderedLike.inspect=true;a["to be like around"]=a["to be alike around"]=a.likeAround=(e,t,r)=>{if(!s(t,r,u)){throw g.create(e,t,s.getLastPath(),"to be like around",r)}};a.likeAround.showDiff=true;a.likeAround.inspect=true;a["to be not like around"]=a["to not be like around"]=a["not to be like around"]=a["to be not alike around"]=a["to not be alike around"]=a["not to be alike around"]=a.notLikeAround=(e,t,r)=>{if(s(t,r,u)){throw g.create(e,t,null,"not to be like around",r)}};a.notLikeAround.inspect=true;a["to be partially equal to"]=a["to be partial equal to"]=a["to be equal to partial"]=a["to partially equal"]=a["to partial equal"]=a["to equal partial"]=a.partialEqual=a.partiallyEqual=(e,t,r)=>{if(!s(r,t,p)){throw g.create(e,t,s.getLastPath(),"to partially equal",r)}};a.partiallyEqual.showPathDiff=true;a.partiallyEqual.inspect=true;a["to be not partially equal to"]=a["to not be partially equal to"]=a["not to be partially equal to"]=a["to be not partial equal to"]=a["to not be partial equal to"]=a["not to be partial equal to"]=a["to be not equal to partial"]=a["to not be equal to partial"]=a["not to be equal to partial"]=a["to not partially equal"]=a["not to partially equal"]=a["to not partial equal"]=a["not to partial equal"]=a["to not equal partial"]=a["not to equal partial"]=a.notPartialEqual=a.notPartiallyEqual=(e,t,r)=>{if(s(r,t,p)){throw g.create(e,t,null,"not to partially equal",r)}};a.notPartiallyEqual.inspect=true;a["to partially equal around"]=a.partiallyEqualAround=(e,t,r)=>{if(!s(r,t,d)){throw g.create(e,t,s.getLastPath(),"to partially equal around",r)}};a.partiallyEqualAround.showPathDiff=true;a.partiallyEqualAround.inspect=true;a["to not partially equal around"]=a["not to partially equal around"]=a.notPartiallyEqualAround=(e,t,r)=>{if(s(r,t,d)){throw g.create(e,t,null,"not to partially equal around",r)}};a.notPartiallyEqualAround.inspect=true;a["to be partially like"]=a["to be like partial"]=a.partialLike=a.partiallyLike=(e,t,r)=>{if(!s(r,t,c)){throw g.create(e,t,s.getLastPath(),"to be partially like",r)}};a.partiallyLike.showPathDiff=true;a.partiallyLike.inspect=true;a["to be not partially like"]=a["to not be partially like"]=a["not to be partially like"]=a["to be not like partial"]=a["to not be like partial"]=a["not to be like partial"]=a.notPartialLike=a.notPartiallyLike=(e,t,r)=>{if(s(r,t,c)){throw g.create(e,t,null,"not to be partially like",r)}};a.notPartiallyLike.inspect=true;a["to be partially like around"]=a.partiallyLikeAround=(e,t,r)=>{if(!s(r,t,h)){throw g.create(e,t,s.getLastPath(),"to be partially like around",r)}};a.partiallyLikeAround.showPathDiff=true;a.partiallyLikeAround.inspect=true;a["to be not partially like around"]=a["to not be partially like around"]=a["not to be partially like around"]=a.notPartiallyLikeAround=(e,t,r)=>{if(s(r,t,h)){throw g.create(e,t,null,"not to be partially like around",r)}};a.notPartiallyLikeAround.inspect=true;a["to map"]=a.map=(n,o,i)=>{if(!o||typeof o!=="object"||typeof o.get!=="function"||typeof o.keys!=="function"){throw g.create(n,o,null,"to be be a mappable object")}if(!Array.isArray(i)){throw new g("Expectation are not map entries",n)}var a=[...o.keys()];if(a.length!==i.length){throw g.create(n,o,null,"to map",i)}i.forEach(t=>{var e,r;if(!Array.isArray(t)){throw new g("Expectation are not map entries",n)}r=a.findIndex(e=>s(t[0],e));if((r=a.indexOf(t[0]))!==-1||(r=a.findIndex(e=>s(t[0],e)))!==-1){e=a.splice(r,1)[0];if(!s(t[1],o.get(e))){throw g.create(n,o,null,"to map",i)}}else{throw g.create(n,o,null,"to map",i)}})};a.map.inspect=true;a["to be shallow clone"]=a["to be shallow clone of"]=a["to be a shallow clone of"]=a.shallowCloneOf=(r,n,o)=>{if(typeof n!=="function"&&(!n||typeof n!=="object")){throw g.create(r,n,null,"to be be an object or a function")}if(n===o){return}if(Array.isArray(n)){if(!Array.isArray(o)||n.length!==o.length){throw g.create(r,n,null,"to be a shallow clone of",o)}n.forEach((e,t)=>{if(e!==o[t]){throw g.create(r,n,null,"to be a shallow clone of",o)}})}else{if(Array.isArray(o)){throw g.create(r,n,null,"to be a shallow clone of",o)}let e=Object.keys(n);let t=Object.keys(o);if(e.length!==t.length){throw g.create(r,n,null,"to be a shallow clone of",o)}t.forEach(e=>{if(!Object.prototype.hasOwnProperty.call(n,e)||n[e]!==o[e]){throw g.create(r,n,null,"to be a shallow clone of",o)}})}};a.shallowCloneOf.inspect=true;a["to be not shallow clone"]=a["to not be shallow clone"]=a["not to be shallow clone"]=a["to be not shallow clone of"]=a["to not be shallow clone of"]=a["not to be shallow clone of"]=a["to be not a shallow clone of"]=a["to not be a shallow clone of"]=a["not to be a shallow clone of"]=a.notShallowCloneOf=(e,t,r)=>{if(typeof t!=="function"&&(!t||typeof t!=="object")){throw g.create(e,t,null,"to be be an object or a function")}try{a.shallowCloneOf(e,t,r)}catch(e){return}throw g.create(e,t,null,"not to be a shallow clone of",r)};a.notShallowCloneOf.inspect=true;const k=1+4*Number.EPSILON;const S=4*Number.MIN_VALUE;a["to be close to"]=a["to be around"]=a.around=(r,n,o,e)=>{if(typeof n!=="number"){throw g.create(r,n,null,"to be a number")}if(Number.isNaN(n)||Number.isNaN(o)){throw g.create(r,n,null,"to be around",o)}if(!e){let e=Math.abs(n),t=Math.abs(o);if(e<=S||t<=S){if(n>o+S||o>n+S){throw g.create(r,n,null,"to be around",o)}}else if(n*o<0){throw g.create(r,n,null,"to be around",o)}else if(e>t*k||t>e*k){throw g.create(r,n,null,"to be around",o)}return}if(n<o-e||n>o+e){throw g.create(r,n,null,"to be around",o)}};a["to be not close to"]=a["to not be close to"]=a["not to be close to"]=a["to be not around"]=a["to not be around"]=a["not to be around"]=a.notAround=(r,n,o,e)=>{if(typeof n!=="number"){throw g.create(r,n,null,"to be a number")}if(Number.isNaN(n)||Number.isNaN(o)){return}if(!e){let e=Math.abs(n),t=Math.abs(o);if(e<=S||t<=S){if(n<=o+S&&o<=n+S){throw g.create(r,n,null,"not to be around",o)}}else if(n*o<0){return}else if(e<=t*k&&t<=e*k){throw g.create(r,n,null,"not to be around",o)}return}if(n>=o-e&&n<=o+e||Number.isNaN(n)){throw g.create(r,n,null,"not to be around",o)}};a["to be above"]=a["to be greater"]=a["to be greater than"]=a.above=a.gt=a.greater=a.greaterThan=(e,t,r)=>{if(typeof t!=="number"&&!(t instanceof Date)){throw g.create(e,t,null,"to be a number or a Date")}if(t<=r||Number.isNaN(t)){throw g.create(e,t,null,"to be above",r)}};a["to be at least"]=a["to be greater than or equal to"]=a.least=a.gte=a.greaterThanOrEqualTo=(e,t,r)=>{if(typeof t!=="number"&&!(t instanceof Date)){throw g.create(e,t,null,"to be a number or a Date")}if(t<r||Number.isNaN(t)){throw g.create(e,t,null,"to be at least",r)}};a["to be below"]=a["to be lesser"]=a["to be lesser than"]=a.below=a.lt=a.lesser=a.lesserThan=(e,t,r)=>{if(typeof t!=="number"&&!(t instanceof Date)){throw g.create(e,t,null,"to be a number or a Date")}if(t>=r||Number.isNaN(t)){throw g.create(e,t,null,"to be below",r)}};a["to be at most"]=a["to be lesser than or equal to"]=a.most=a.lte=a.lesserThanOrEqualTo=(e,t,r)=>{if(typeof t!=="number"&&!(t instanceof Date)){throw g.create(e,t,null,"to be a number or a Date")}if(t>r||Number.isNaN(t)){throw g.create(e,t,null,"to be at most",r)}};a["to be within"]=a.within=(e,t,r,n)=>{if(typeof t!=="number"&&!(t instanceof Date)){throw g.create(e,t,null,"to be a number or a Date")}if(t<r||t>n||Number.isNaN(t)){throw g.create(e,t,null,"to be within",r,n)}};a["to be not within"]=a["to not be within"]=a["not to be within"]=a.notWithin=(e,t,r,n)=>{if(typeof t!=="number"&&!(t instanceof Date)){throw g.create(e,t,null,"to be a number or a Date")}if(t>=r&&t<=n||Number.isNaN(t)){throw g.create(e,t,null,"not to be within",r,n)}};a["to start with"]=a.startsWith=a.startWith=(e,t,r)=>{if(typeof t!=="string"){throw g.create(e,t,null,"to be a string")}if(!t.startsWith(r)){throw g.create(e,t,null,"to start with",r)}};a.startWith.inspect=true;a["to not start with"]=a["not to start with"]=a.notStartWith=(e,t,r)=>{if(typeof t!=="string"){throw g.create(e,t,null,"to be a string")}if(t.startsWith(r)){throw g.create(e,t,null,"not to start with",r)}};a.notStartWith.inspect=true;a["to end with"]=a.endsWith=a.endWith=(e,t,r)=>{if(typeof t!=="string"){throw g.create(e,t,null,"to be a string")}if(!t.endsWith(r)){throw g.create(e,t,null,"to end with",r)}};a.endWith.inspect=true;a["to not end with"]=a["not to end with"]=a.notEndWith=(e,t,r)=>{if(typeof t!=="string"){throw g.create(e,t,null,"to be a string")}if(t.endsWith(r)){throw g.create(e,t,null,"not to end with",r)}};a.notEndWith.inspect=true;a["to match"]=a.match=(e,t,r)=>{if(typeof t!=="string"){throw g.create(e,t,null,"to be a string")}if(!t.match(r)){throw g.create(e,t,null,"to match",r)}};a["to not match"]=a["not to match"]=a.notMatch=(e,t,r)=>{if(typeof t!=="string"){throw g.create(e,t,null,"to be a string")}if(t.match(r)){throw g.create(e,t,null,"not to match",r)}};a["to have length"]=a["to have length of"]=a["to have a length of"]=a.lengthOf=(e,t,r)=>{if(typeof t!=="string"&&(!t||typeof t!=="object")){throw g.create(e,t,null,"to have some length")}if(t.length!==r){throw g.create(e,t,null,"to have a length of",r)}};a["to have not length"]=a["to not have length"]=a["not to have length"]=a["to have length not of"]=a["to have not length of"]=a["to not have length of"]=a["not to have length of"]=a["to have a length not of"]=a["to have not a length of"]=a["to not have a length of"]=a["not to have a length of"]=a.notLengthOf=(e,t,r)=>{if(typeof t!=="string"&&(!t||typeof t!=="object")){throw g.create(e,t,null,"to have some length")}if(t.length===r){throw g.create(e,t,null,"not to have a length of",r)}};a["to contain"]=a["to include"]=a.includes=a.include=a.contains=a.contain=(e,r,...n)=>{var o=false;if(r&&typeof r==="object"){let t=m(r);o=n.every(e=>t.includes(e))}else if(typeof r==="string"){o=n.every(e=>r.includes(e))}if(!o){throw g.create(e,r,null,"to contain",n)}};a.contain.inspect=true;a["to contain not"]=a["to not contain"]=a["not to contain"]=a["to include not"]=a["to not include"]=a["not to include"]=a.notInclude=a.notContain=(e,r,...n)=>{var o=false;if(r&&typeof r==="object"){let t=m(r);o=n.some(e=>t.includes(e))}else if(typeof r==="string"){o=n.some(e=>r.includes(e))}if(o){throw g.create(e,r,null,"not to contain",n)}};a.notContain.inspect=true;a["to have"]=a.has=(e,t,...r)=>{if(t&&typeof t==="object"){if(typeof t.has==="function"){if(!r.every(e=>t.has(e))){throw g.create(e,t,null,"to have",r)}return}}a.contain(e,t,...r)};a.has.inspect=true;a["to have not"]=a["to not have"]=a["not to have"]=a.hasNot=(e,t,...r)=>{if(t&&typeof t==="object"){if(typeof t.has==="function"){if(r.some(e=>t.has(e))){throw g.create(e,t,null,"not to have",r)}return}}a.notContain(e,t,...r)};a.hasNot.inspect=true;a["to only contain"]=a["to contain only"]=a["to only include"]=a["to include only"]=a.includeOnly=a.includesOnly=a.containOnly=a.containsOnly=(e,r,...n)=>{var o=false;if(r&&typeof r==="object"){let t=w(r);let e=w(n);o=t.size===e.size&&[...e].every(e=>t.has(e))}else if(typeof r==="string"){o=n.every(e=>r===e)}if(!o){throw g.create(e,r,null,"to contain only",n)}};a.containOnly.inspect=true;a.containOnly.glue=", ";a["not to only contain"]=a["to not only contain"]=a["not to contain only"]=a["to not contain only"]=a["to contain not only"]=a["not to only include"]=a["to not only include"]=a["not to include only"]=a["to not include only"]=a["to include not only"]=a.notIncludeOnly=a.notContainOnly=e=>{throw new g("Ambigous assertion type 'not to contain only'",e)};a["to only have"]=a["to have only"]=a.hasOnly=(r,n,...o)=>{if(n&&typeof n==="object"){if(typeof n.has==="function"){let e=w(n);let t=w(o);if(e.size!==t.size||![...t].every(e=>n.has(e))){throw g.create(r,n,null,"to have only",o)}return}}a.containOnly(r,n,...o)};a.hasOnly.inspect=true;a.hasOnly.glue=", ";a["not to only have"]=a["to not only have"]=a["not to have only"]=a["to not have only"]=a["to have not only"]=a.hasNotOnly=e=>{throw new g("Ambigous assertion type 'not to have only'",e)};a["to only have unique values"]=a["to have only unique values"]=a["to only contain unique values"]=a["to contain only unique values"]=a["to only include unique values"]=a["to include only unique values"]=a.onlyUniqueValues=(r,n)=>{if(!n||typeof n!=="object"){throw g.create(r,n,null,"to only contain unique values")}var o=m(n);for(let t=0;t<o.length;t++){for(let e=t+1;e<o.length;e++){if(o[t]===o[e]){throw g.create(r,n,null,"to only contain unique values")}}}};a.onlyUniqueValues.inspect=true;a["not to only have unique values"]=a["to not only have unique values"]=a["not to have only unique values"]=a["to not have only unique values"]=a["to have not only unique values"]=a["not to only contain unique values"]=a["to not only contain unique values"]=a["not to contain only unique values"]=a["to not contain only unique values"]=a["to contain not only unique values"]=a["not to only include unique values"]=a["to not only include unique values"]=a["not to include only unique values"]=a["to not include only unique values"]=a["to include not only unique values"]=a.notOnlyUniqueValues=e=>{throw new g("Ambigous assertion type 'not to contain only unique values'",e)};a["to be empty"]=a.empty=(e,t)=>{var r=true;if(t){if(typeof t==="object"){if(Array.isArray(t)){if(t.length){r=false}}else if(t instanceof Map||t instanceof Set){if(t.size){r=false}}else if(t.length!==undefined){if(t.length){r=false}}else if(Object.keys(t).length){r=false}}else if(typeof t==="string"){r=false}}if(!r){throw g.create(e,t,null,"to be empty")}};a["to be not empty"]=a["to not be empty"]=a["not to be empty"]=a.notEmpty=(e,t)=>{var r=true;if(t){if(typeof t==="object"){if(Array.isArray(t)){if(t.length){r=false}}else if(t instanceof Map||t instanceof Set){if(t.size){r=false}}else if(t.length!==undefined){if(t.length){r=false}}else if(Object.keys(t).length){r=false}}else if(typeof t==="string"){r=false}}if(r){throw g.create(e,t,null,"to be empty")}};a["to have key"]=a["to have keys"]=a.key=a.keys=(t,r,...n)=>{if(!o.looseObject(r)){throw g.create(t,r,null,"to be an object or a function")}n.forEach(e=>{if(!(e in r)){throw g.create(t,r,null,"to have key"+(n.length>1?"s":""),...n)}})};a.keys.inspect=true;a.keys.glue=", ";a["to have not key"]=a["to not have key"]=a["not to have key"]=a["to have not keys"]=a["to not have keys"]=a["not to have keys"]=a["to have no key"]=a.noKey=a.notKey=a.notKeys=(t,r,...n)=>{if(!o.looseObject(r)){throw g.create(t,r,null,"to be an object or a function")}n.forEach(e=>{if(e in r){throw g.create(t,r,null,"not to have key"+(n.length>1?"s":""),...n)}})};a.notKeys.inspect=true;a.notKeys.glue=", ";a["to have own key"]=a["to have own keys"]=a.ownKey=a.ownKeys=(t,r,...n)=>{if(!o.looseObject(r)){throw g.create(t,r,null,"to be an object or a function")}n.forEach(e=>{if(!Object.prototype.hasOwnProperty.call(r,e)){throw g.create(t,r,null,"to have own key"+(n.length>1?"s":""),...n)}})};a.ownKeys.inspect=true;a.ownKeys.glue=", ";a["to only have key"]=a["to have only key"]=a["to have only key"]=a["to only have keys"]=a["to have only keys"]=a["to have only keys"]=a.onlyKey=a.onlyKeys=e=>{throw new g("Instead of using assertion 'onlyKeys', you should use assertion 'onlyOwnKeys'.",e)};a["to only have own key"]=a["to have only own key"]=a["to have own only key"]=a["to only have own keys"]=a["to have only own keys"]=a["to have own only keys"]=a.onlyOwnKey=a.onlyOwnKeys=(t,r,...n)=>{if(!o.looseObject(r)){throw g.create(t,r,null,"to be an object or a function")}if(Object.getOwnPropertyNames(r).length!==n.length){throw g.create(t,r,null,"to only have own key"+(n.length>1?"s":""),...n)}n.forEach(e=>{if(!Object.prototype.hasOwnProperty.call(r,e)){throw g.create(t,r,null,"to only have own key"+(n.length>1?"s":""),...n)}})};a.onlyOwnKeys.inspect=true;a.onlyOwnKeys.glue=", ";a["to have not own key"]=a["to not have own key"]=a["not to have own key"]=a["to have not own keys"]=a["to not have own keys"]=a["not to have own keys"]=a["to have no own key"]=a.noOwnKey=a.notOwnKey=a.notOwnKeys=(t,r,...n)=>{if(!o.looseObject(r)){throw g.create(t,r,null,"to be an object or a function")}n.forEach(e=>{if(Object.prototype.hasOwnProperty.call(r,e)){throw g.create(t,r,null,"not to have own key"+(n.length>1?"s":""),...n)}})};a.notOwnKeys.inspect=true;a.notOwnKeys.glue=", ";a["to have property"]=a.property=function(e,t,r,n){a.key(e,t,r);if(arguments.length>=4){a.equal(e,t[r],n)}};a["to have not property"]=a["to not have property"]=a["not to have property"]=a["to have no property"]=a.notProperty=function(e,t,r,n){if(arguments.length>=4){if(r in t){a.notEqual(e,t[r],n)}}else{a.notKey(e,t,r)}};a["to have own property"]=a.ownProperty=function(e,t,r,n){a.ownKey(e,t,r);if(arguments.length>=4){a.equal(e,t[r],n)}};a["to have not own property"]=a["to not have own property"]=a["not to have own property"]=a["to have no own property"]=a.notOwnProperty=function(e,t,r,n){if(arguments.length>=4){if(Object.prototype.hasOwnProperty.call(t,r)){a.notEqual(e,t[r],n)}}else{a.notOwnKey(e,t,r)}};a["to throw"]=a["to throw a"]=a["to throw an"]=a.throw=(t,e,r,n,o)=>{if(typeof e!=="function"){throw g.create(t,e,null,"to be a function")}if(!Array.isArray(r)){r=[]}var i=new b(e,false,...r);if(n){if(!i.hasThrown||!(i.error instanceof n)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,i,null,"to throw "+e,n)}if(o&&!s(o,i.error,c)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,i,s.getLastPath(),"to throw "+e,n,o)}}else if(!i.hasThrown){throw g.create(t,i,null,"to throw")}};a.throw.fnParams=true;a.throw.inspect=true;a.throw.glue=" having ";a["to not throw"]=a["not to throw"]=a["to throw not a"]=a["to not throw a"]=a["not to throw a"]=a["to throw not an"]=a["to not throw an"]=a["not to throw an"]=a.notThrow=(t,e,r,n,o)=>{if(typeof e!=="function"){throw g.create(t,e,null,"to be a function")}if(!Array.isArray(r)){r=[]}var i=new b(e,false,...r);if(n){if(i.hasThrown&&i.error instanceof n){if(o){if(s(o,i.error,c)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,i,null,"not to throw "+e,n,o)}}else{let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,i,null,"not to throw "+e,n)}}}else if(i.hasThrown){throw g.create(t,i,null,"not to throw")}};a.notThrow.fnParams=true;a.notThrow.inspect=true;a.notThrow.glue=" having ";a["to reject"]=a["to reject with"]=a["to reject with a"]=a["to reject with an"]=a["to not fulfill"]=a["not to fulfill"]=a.notFulfill=a.reject=async(t,e,r,n,o)=>{if(typeof e!=="function"){return a.rejected(t,e,n,o)}if(!Array.isArray(r)){r=[]}var i=new b(e,true,...r);await i.promise;if(n){if(!i.hasThrown||!(i.error instanceof n)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,i,null,"to reject with "+e,n)}if(o&&!s(o,i.error,c)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,i,s.getLastPath(),"to reject with "+e,n,o)}}else if(!i.hasThrown){throw g.create(t,i,null,"to reject")}};a.throw.promise=a.reject;a.reject.fnParams=true;a.reject.async=true;a.reject.inspect=true;a.reject.glue=" having ";a["to not reject"]=a["not to reject"]=a["to reject not with"]=a["to not reject with"]=a["not to reject with"]=a["to reject not with a"]=a["to not reject with a"]=a["not to reject with a"]=a["to reject not with an"]=a["to not reject with an"]=a["not to reject with an"]=a["to fulfill"]=a.notReject=a.fulfill=async(t,e,r,n,o)=>{if(typeof e!=="function"){return a.fulfilled(t,e,n,o)}if(!Array.isArray(r)){r=[]}var i=new b(e,true,...r);await i.promise;if(n){if(i.hasThrown&&i.error instanceof n){if(o){if(s(o,i.error,c)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,i,null,"not to reject with "+e,n,o)}}else{let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,i,null,"not to reject with "+e,n)}}}else if(i.hasThrown){throw g.create(t,i,null,"not to reject")}};a.notThrow.promise=a.fulfill;a.fulfill.fnParams=true;a.fulfill.async=true;a.fulfill.inspect=true;a.fulfill.glue=" having ";a["to be rejected"]=a["to be rejected with"]=a["to be rejected with a"]=a["to be rejected with an"]=a["not to be fulfilled"]=a["to not be fulfilled"]=a["to be not fulfilled"]=a.notFulfilled=a.rejected=async(t,r,n,o)=>{var i,a=false;try{await r}catch(e){a=true;i=e}if(n){if(!a||!(i instanceof n)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,r,null,"to be rejected with "+e,n)}if(o&&!s(o,i,c)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,r,s.getLastPath(),"to be rejected with "+e,n,o)}}else if(!a){throw g.create(t,r,null,"to be rejected")}};a.rejected.promise=true;a.rejected.async=true;a.rejected.inspect=true;a["not to be rejected"]=a["to not be rejected"]=a["to be not rejected"]=a["not to be rejected with"]=a["to not be rejected with"]=a["to be not rejected with"]=a["not to be rejected with a"]=a["to not be rejected with a"]=a["to be not rejected with a"]=a["not to be rejected with an"]=a["to not be rejected with an"]=a["to be not rejected with an"]=a["to be fulfilled"]=a.fulfilled=a.notRejected=async(t,r,n,o)=>{var i,a=false;try{await r}catch(e){a=true;i=e}if(n){if(a&&i instanceof n){if(o){if(s(o,i,c)){let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,r,null,"not to be rejected with "+e,n,o)}}else{let e=y.has((""+(n.name||"(anonymous)"))[0])?"an":"a";throw g.create(t,r,null,"not to be rejected with "+e,n)}}}else if(a){throw g.create(t,r,null,"not to be rejected")}};a.fulfilled.promise=true;a.fulfilled.async=true;a.fulfilled.inspect=true;a["to be a"]=a["to be an"]=a.typeOrInstanceOf=(e,t,r)=>{if(typeof r==="string"){return a.typeOf(e,t,r)}return a.instanceOf(e,t,r)};a["to be not a"]=a["to not be a"]=a["not to be a"]=a["to be not an"]=a["to not be an"]=a["not to be an"]=a.notTypeOrInstanceOf=(e,t,r)=>{if(typeof r==="string"){return a.notTypeOf(e,t,r)}return a.notInstanceOf(e,t,r)};a["to be of type"]=a.typeOf=(t,r,n)=>{if(!o[n]){throw new Error("Unknown type '"+n+"'.")}if(!o[n](r)){let e=y.has(n[0])?"an":"a";throw g.create(t,r,null,"to be "+e,n)}};a["to be not of type"]=a["to not be of type"]=a["not to be of type"]=a.notTypeOf=(t,r,n)=>{if(!o[n]){throw new Error("Unknown type '"+n+"'.")}if(o[n](r)){let e=y.has(n[0])?"an":"a";throw g.create(t,r,null,"not to be "+e,n)}};a["to be an instance of"]=a.instanceOf=(e,t,r)=>{if(!(t instanceof r)){throw g.create(e,t,null,"to be an instance of",r)}};a.instanceOf.inspect=true;a["to be not an instance of"]=a["to not be an instance of"]=a["not to be an instance of"]=a.notInstanceOf=(e,t,r)=>{if(t instanceof r){throw g.create(e,t,null,"not to be an instance of",r)}};a.notInstanceOf.inspect=true;a.fail=(e,t,r,...n)=>{throw g.create(e,t,null,{expectationType:"fail",middleMessage:r},...n)};a.fail.inspect=true;a.fail.none=true},{"./AssertionError.js":1,"./isEqual.js":10,"./typeCheckers.js":14}],5:[function(e,t,r){"use strict";t.exports=e("./core.js");t.exports.isBrowser=true},{"./core.js":7}],6:[function(r,n,e){(function(t){(function(){"use strict";if(!t){t=window}if(!t.DOORMEN_GLOBAL_EXTENSIONS){t.DOORMEN_GLOBAL_EXTENSIONS={}}if(!t.DOORMEN_GLOBAL_EXTENSIONS.constraints){t.DOORMEN_GLOBAL_EXTENSIONS.constraints={}}const e=Object.create(t.DOORMEN_GLOBAL_EXTENSIONS.constraints);n.exports=e;const c=r("./core.js");const h=r("tree-kit/lib/dotPath.js");const s=r("string-kit/lib/format.js").format;e.condition=function(t,e,r,n){var o=t,i=t;if(e.source){o=h.get(t,e.source)}if(e.target){i=h.get(t,e.target)}if(e.if){try{c(e.if,o)}catch(e){return t}}if(e.then){i=this.check(e.then,i,r)}if(e.target){h.set(t,e.target,i)}else{t=i}return t};e.switch=function(e,t,r,n){var o=e,i=e;if(t.source){o=h.get(e,t.source)}if(t.target){i=h.get(e,t.target)}if(t.case&&typeof t.case==="object"&&o in t.case){i=this.check(t.case[o],i,r)}else if(t.otherCases){i=this.check(t.otherCases,i,r)}else{return e}if(t.target){h.set(e,t.target,i)}else{e=i}return e};e.unique=function(e,t,r,n){var o,i,a,s,l,f=new Set;if(t.convert&&!c.sanitizers[t.convert]){if(c.clientMode){return e}throw new c.SchemaError("Bad schema (at "+r.displayPath+"), unexistant sanitizer '"+t.convert+"' (used as 'convert').")}if(!Array.isArray(e)){this.validatorError(r.displayPath+" should be an array to satisfy the 'unique' constraint.",r);return}for(o=0,i=e.length;o<i;o++){s=a=e[o];if(t.path){s=h.get(a,t.path)}if(t.noEmpty&&!s||t.noNull&&(s===null||s===undefined)){if(!t.resolve){this.validatorError(r.displayPath+" does not satisfy the 'unique' constraint (has null/empty value).",r);return}if(!l){l=e.slice(0,o)}continue}if(t.convert){s=c.sanitizers[t.convert].call(this,s,t,true)}if(f.has(s)){if(!t.resolve){this.validatorError(r.displayPath+" does not satisfy the 'unique' constraint.",r);return}if(!l){l=e.slice(0,o)}continue}if(l){l.push(a)}f.add(s)}return l||e};e.compound=function(t,e,r,n){var o,i,a;if(!Array.isArray(e.sources)||typeof e.target!=="string"||typeof e.format!=="string"){throw new c.SchemaError("Bad schema (at "+r.displayPath+"), the 'compound' constraint needs a 'sources' array, a 'target' and a 'format' string.")}o=h.get(t,e.target);if(o&&e.ifEmpty){return t}i=e.sources.map(e=>h.get(t,e)),a=s(e.format,...i);if(a===o){return t}if(!e.resolve){this.validatorError(r.displayPath+" does not satisfy the 'compound' constraint.",r);return}h.set(t,e.target,a);return t};e.extraction=function(e,t,r,n){var o,i,a,s,l,f,u;if(!Array.isArray(t.targets)||typeof t.source!=="string"||typeof t.match!=="string"&&!(t.match instanceof RegExp)){throw new c.SchemaError("Bad schema (at "+r.displayPath+"), the 'extraction' constraint needs a 'targets' array, a 'source' string, and a 'match' string or RegExp.")}s=h.get(e,t.source);if(typeof s!=="string"){this.validatorError(r.displayPath+" should have a string as its '"+t.source+"' child to satisfy the 'extraction' constraint.",r);return}u=t.match instanceof RegExp?t.match:new RegExp(t.match,t.flags||"");l=s.match(u);if(!l){this.validatorError(r.displayPath+" 's child '"+t.source+"' does not match the regular expression, hence do not to satisfy the 'extraction' constraint.",r);return}for(o=0,i=t.targets.length;o<i;o++){a=h.get(e,t.targets[o]);f=l[o+1];if(a&&t.ifEmpty){continue}if(f===a){continue}if(!t.resolve){this.validatorError(r.displayPath+" does not satisfy the 'extraction' constraint.",r);return}h.set(e,t.targets[o],f)}return e}}).call(this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"./core.js":7,"string-kit/lib/format.js":18,"tree-kit/lib/dotPath.js":27}],7:[function(s,l,e){(function(a){(function(){"use strict";const c=s("tree-kit/lib/dotPath.js");const t=s("tree-kit/lib/clone.js");function y(...e){var t,r,n,o,i;if(e.length<2||e.length>3){throw new Error("doormen() needs at least 2 and at most 3 arguments")}if(e.length===2){n=e[0];r=e[1]}else{t=e[0];n=e[1];r=e[2]}if(!n||typeof n!=="object"){throw new y.SchemaError("Bad schema, it should be an object or an array of object!")}if(!t||typeof t!=="object"){t={}}if(!t.patch||typeof t.patch!=="object"||Array.isArray(t.patch)){t.patch=false}o={userContext:t.userContext,validate:true,onlyConstraints:!!t.onlyConstraints,errors:[],patch:t.patch,check:h,validatorError:w,fake:!!t.fake,report:!!t.report,export:!!t.export};i=o.check(n,r,{path:"",displayPath:r===null?"null":Array.isArray(r)?"array":typeof r,key:""},false);if(o.report){return{validate:o.validate,sanitized:i,errors:o.errors}}return i}l.exports=y;y.report=y.bind(y,{report:true});y.export=y.bind(y,{export:true});y.checkConstraints=y.bind(y,{onlyConstraints:true});y.ValidatorError=s("./ValidatorError.js");y.SchemaError=s("./SchemaError.js");y.AssertionError=s("./AssertionError.js");var e=s("./mask.js");y.tierMask=e.tierMask;y.tagMask=e.tagMask;y.getAllSchemaTags=e.getAllSchemaTags;y.isEqual=s("./isEqual.js");y.schemaSchema=s("./schemaSchema.js");y.validateSchema=function(e){return y(y.schemaSchema,e)};y.purifySchema=function(e){return y.export(y.schemaSchema,e)};if(!a){a=window}if(!a.DOORMEN_GLOBAL_EXTENSIONS){a.DOORMEN_GLOBAL_EXTENSIONS={}}if(!a.DOORMEN_GLOBAL_EXTENSIONS.typeCheckers){a.DOORMEN_GLOBAL_EXTENSIONS.typeCheckers={}}if(!a.DOORMEN_GLOBAL_EXTENSIONS.sanitizers){a.DOORMEN_GLOBAL_EXTENSIONS.sanitizers={}}if(!a.DOORMEN_GLOBAL_EXTENSIONS.filters){a.DOORMEN_GLOBAL_EXTENSIONS.filters={}}if(!a.DOORMEN_GLOBAL_EXTENSIONS.constraints){a.DOORMEN_GLOBAL_EXTENSIONS.constraints={}}if(!a.DOORMEN_GLOBAL_EXTENSIONS.defaultFunctions){a.DOORMEN_GLOBAL_EXTENSIONS.defaultFunctions={}}y.typeCheckers=s("./typeCheckers.js");y.sanitizers=s("./sanitizers.js");y.filters=s("./filters.js");y.constraints=s("./constraints.js");y.defaultFunctions=s("./defaultFunctions.js");y.topLevelFilters=["instanceOf","min","max","length","minLength","maxLength","match","in","notIn","eq"];function h(e,t,r,n){var o,i,a,s,l,f=t,u,c,h,p,d;if(!e||typeof e!=="object"){throw new y.SchemaError(r.displayPath+" is not a schema (not an object or an array of object).")}if(Array.isArray(e)){h=[];for(o=0;o<e.length;o++){try{f=y.export(e[o],t)}catch(e){h.push(e.message.replace(/\.$/,""));continue}return f}this.validatorError(r.displayPath+" does not validate any schema alternatives: ( "+h.join(" ; ")+" ).",r);return}if(!this.onlyConstraints){if(e.value!==undefined){return e.value}if(f===null){if(e.nullIsUndefined){f=undefined}else if(!e.nullIsValue){if(this.fake&&typeof e.fakeFn==="function"){return e.fakeFn(e)}else if(e.defaultFn){if(typeof e.defaultFn==="function"){return e.defaultFn(e)}if(y.defaultFunctions[e.defaultFn]){return y.defaultFunctions[e.defaultFn](e)}else if(!y.clientMode){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), unexistant default function '"+e.defaultFn+"'.")}}if("default"in e){return g(e.default)}if(e.optional){return f}}}if(f===undefined){if(this.fake&&typeof e.fakeFn==="function"){return e.fakeFn(e)}else if(e.defaultFn){if(typeof e.defaultFn==="function"){return e.defaultFn(e)}if(y.defaultFunctions[e.defaultFn]){return y.defaultFunctions[e.defaultFn](e)}else if(!y.clientMode){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), unexistant default function '"+e.defaultFn+"'.")}}if("default"in e){return g(e.default)}if(e.optional){return f}}if(e.sanitize){s=Array.isArray(e.sanitize)?e.sanitize:[e.sanitize];d=f;for(o=0;o<s.length;o++){if(!y.sanitizers[s[o]]){if(y.clientMode){continue}throw new y.SchemaError("Bad schema (at "+r.displayPath+"), unexistant sanitizer '"+s[o]+"'.")}f=y.sanitizers[s[o]].call(this,f,e,this.export&&f===t)}if(this.patch&&d!==f&&!(Number.isNaN(d)&&Number.isNaN(f))){b(this.patch,r.path,f)}}if(e.type){if(!y.typeCheckers[e.type]){if(!y.clientMode){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), unexistant type '"+e.type+"'.")}}else if(!y.typeCheckers[e.type].call(this,f,e)){this.validatorError(r.displayPath+" is not a "+e.type+".",r)}}for(o=0;o<y.topLevelFilters.length;o++){i=y.topLevelFilters[o];if(e[i]!==undefined){y.filters[i].call(this,f,e[i],r)}}if(e.filter){if(typeof e.filter!=="object"){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), 'filter' should be an object.")}for(i in e.filter){if(!y.filters[i]){if(y.clientMode){continue}throw new y.SchemaError("Bad schema (at "+r.displayPath+"), unexistant filter '"+i+"'.")}y.filters[i].call(this,f,e.filter[i],r)}}if(e.keys!==undefined&&(f&&(typeof f==="object"||typeof f==="function"))){if(!e.keys||typeof e.keys!=="object"){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), 'keys' should contain a schema object.")}if(this.export&&f===t){f={};u=t}else{u=f}for(i in u){a=this.check(e.keys,i,{path:r.path?r.path+"."+i:i,displayPath:r.displayPath+":"+i,key:i},n);if(a in f&&a!==i){this.validatorError("'keys' cannot overwrite another existing key: "+r.displayPath+" want to rename '"+i+"' to '"+a+"' but it already exists.",r)}f[a]=u[i];if(a!==i){delete f[i]}}}}if(e.of!==undefined&&(f&&(typeof f==="object"||typeof f==="function"))){if(!e.of||typeof e.of!=="object"){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), 'of' should contain a schema object.")}if(Array.isArray(f)){if(this.export&&f===t){f=[];u=t}else{u=f}for(o=0;o<u.length;o++){f[o]=this.check(e.of,u[o],{path:r.path?r.path+"."+o:""+o,displayPath:r.displayPath+"["+o+"]",key:o},n)}}else{if(this.export&&f===t){f={};u=t}else{u=f}for(i in u){f[i]=this.check(e.of,u[i],{path:r.path?r.path+"."+i:i,displayPath:r.displayPath+"."+i,key:i},n)}}}if(e.properties!==undefined&&(f&&(typeof f==="object"||typeof f==="function"))){if(!e.properties||typeof e.properties!=="object"){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), 'properties' should be an object.")}if(this.export&&f===t){f={};u=t}else{u=f}l=new Set;if(Array.isArray(e.properties)){for(o=0;o<e.properties.length;o++){i=e.properties[o];if(!(i in u)){this.validatorError(r.displayPath+" does not have all required properties ("+JSON.stringify(e.properties)+").",r)}f[i]=u[i];l.add(i)}}else{for(i in e.properties){if(!e.properties[i]||typeof e.properties[i]!=="object"){throw new y.SchemaError(r.displayPath+"."+i+" is not a schema (not an object or an array of object).")}l.add(i);c=this.check(e.properties[i],u[i],{path:r.path?r.path+"."+i:i,displayPath:r.displayPath+"."+i,key:i},n);if(c!==undefined||i in u){f[i]=c}}}if(!this.onlyConstraints&&!e.extraProperties){for(i in u){if(!l.has(i)){this.validatorError(r.displayPath+" has extra properties ('"+i+"' is not in "+JSON.stringify([...l])+").",r)}}}}if(e.elements!==undefined&&Array.isArray(f)){if(!Array.isArray(e.elements)){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), 'elements' should be an array.")}if(this.export&&f===t){f=[];u=t}else{u=f}for(o=0;o<e.elements.length;o++){f[o]=this.check(e.elements[o],u[o],{path:r.path?r.path+"."+o:""+o,displayPath:r.displayPath+"["+o+"]",key:o},n)}if(!e.extraElements&&u.length>e.elements.length){this.validatorError(r.displayPath+" has extra elements ("+u.length+" instead of "+e.elements.length+").",r)}}if(e.constraints&&!n){if(!Array.isArray(e.constraints)){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), 'constraints' should be an object.")}if(!f||typeof f!=="object"){this.validatorError(r.displayPath+" has a constraints but is not an object.",r)}d=f;for(o=0;o<e.constraints.length;o++){p=e.constraints[o];if(!p||typeof p!=="object"){throw new y.SchemaError("Bad schema (at "+r.displayPath+"), constraints #"+o+" should be an object.")}if(!y.constraints[p.enforce]){if(y.clientMode){continue}throw new y.SchemaError("Bad schema (at "+r.displayPath+"), unexistant constraints '"+p.enforce+"'.")}f=y.constraints[p.enforce].call(this,f,p,r,this.export&&f===t)}if(this.patch&&d!==f&&!(Number.isNaN(d)&&Number.isNaN(f))){b(this.patch,r.path,f)}}return f}function g(e){if(e&&typeof e==="object"){return t(e)}return e}function b(e,t,r){var n,o;e[t]=r;o=t+".";for(n in e){if(n.startsWith(o)){delete e[n]}}}y.mergePatch=function(o,i){for(let n in i){let r=false;for(let t in o){if(n.startsWith(t+".")){let e=n.slice(t.length+1);c.set(o[t],e,i[n]);r=true}else if(t.startsWith(n+".")){delete o[t]}}if(!r){o[n]=i[n]}}return o};y.path=y.subSchema=(e,t,r=false,n=false)=>{var o,i;if(!Array.isArray(t)){if(typeof t!=="string"){throw new Error("Argument #1 'path' should be a string or an array")}t=t.split(".").filter(e=>e)}try{for(o=0,i=t.length;o<i&&e;o++){e=y.directSubSchema(e,t[o],r,n)}}catch(e){e.message+=" (at: "+t.slice(0,o+1).join(".")+")";throw e}return e};const o={};Object.freeze(o);y.directSubSchema=(e,t,r,n)=>{if(!e||typeof e!=="object"){throw new y.SchemaError("Not a schema (not an object or an array of object).")}if(n&&e.opaque){throw new y.ValidatorError("Path leading inside an opaque object.")}if(r&&e.noSubmasking){return null}if(Array.isArray(e)){throw new Error("Schema alternatives are not supported for subSchema ATM.")}if(e.properties!==undefined){if(!e.properties||typeof e.properties!=="object"){throw new y.SchemaError("Bad schema: 'properties' should be an object.")}if(e.properties[t]){return e.properties[t]}else if(!e.extraProperties){throw new y.SchemaError("Bad path: property '"+t+"' not found and the schema does not allow extra properties.")}}if(e.elements!==undefined){if(!Array.isArray(e.elements)){throw new y.SchemaError("Bad schema: 'elements' should be an array.")}t=+t;if(e.elements[t]){return e.elements[t]}else if(!e.extraElements){throw new y.SchemaError("Bad path: element #"+t+" not found and the schema does not allow extra elements.")}}if(e.of!==undefined){if(!e.of||typeof e.of!=="object"){throw new y.SchemaError("Bad schema: 'of' should contain a schema object.")}return e.of}return o};y.schemaWalker=function(e,t){var r,n,o,i,a=e.schema;if(Array.isArray(a)){o=i=0;for(r=0;r<a.length;r++){o++;n=y.schemaWalker({schema:e.schema[r],schemaPath:e.schemaPath.concat(r),options:e.options});if(n!==e.schema[r]){if(a===e.schema){a=Array.from(e.schema)}a[r]=n;if(n===undefined){i++}}}if(i&&o===i){a=undefined}return a}if(e.schema.properties&&typeof e.schema.properties==="object"){o=i=0;for(r in e.schema.properties){o++;n=t({schema:e.schema.properties[r],schemaPath:e.schemaPath.concat("properties",r),options:e.options});if(n!==e.schema.properties[r]){if(a===e.schema){a=Object.assign({},e.schema)}if(a.properties===e.schema.properties){a.properties=Object.assign({},e.schema.properties)}if(n===undefined){delete a.properties[r];i++;if(e.options&&e.options.extraProperties){a.extraProperties=true}}else{a.properties[r]=n}}}if(i&&o===i){delete a.properties}if(i&&e.options&&e.options.extraProperties){a.extraProperties=true}}if(a.of&&typeof a.of==="object"){n=t({schema:e.schema.of,schemaPath:e.schemaPath.concat("of"),options:e.options});if(n!==e.schema.of){if(a===e.schema){a=Object.assign({},e.schema)}if(n===undefined){delete a.of}else{a.of=n}}}if(a.elements&&Array.isArray(a.elements)){o=i=0;for(r=0;r<a.elements.length;r++){o++;n=t({schema:e.schema.elements[r],schemaPath:e.schemaPath.concat("elements",r),options:e.options});if(n!==e.schema.elements[r]){if(a===e.schema){a=Object.assign({},e.schema)}if(a.elements===e.schema.elements){a.elements=Array.from(e.schema.elements)}a.elements[r]=n;if(n===undefined){i++}}}if(i&&o===i){delete a.elements}}return a};y.constraintSchema=function(e){return r({schema:e,schemaPath:[],options:{extraProperties:true}})};function r(e){var t=y.schemaWalker(e,r);if(Array.isArray(t)){return t}if(t===e.schema){if(!t.constraints){return}t=Object.assign({},e.schema)}delete t.type;delete t.sanitize;delete t.filter;return t}y.patchTier=function(e,t){var r,n,o,i=1,a=Object.keys(t);for(r=0,n=a.length;r<n;r++){o=a[r].split(".");while(o.length){i=Math.max(i,y.subSchema(e,o).tier||1);o.pop()}}return i};y.checkPatchByTags=function(e,t,r){var n;if(!(r instanceof Set)){if(Array.isArray(r)){r=new Set(r)}else{r=new Set([r])}}for(n in t){p(e,n,r,t[n])}};function p(e,t,r,n){var o,i,a;t=t.split(".");while(t.length){o=y.subSchema(e,t);if(o.tags){a=false;for(i of o.tags){if(r.has(i)){a=true;break}}if(!a){if(this&&this.validatorError){this.validatorError("Not allowed by tags",n)}else{throw new y.ValidatorError("Not allowed by tags",n)}}}t.pop()}}y.patch=function(...e){var t,r,n,o,i,a,s,l,f,u;if(e.length<2||e.length>4){throw new Error("doormen.patch() needs at least 2 and at most 4 arguments")}if(e.length===2){r=e[0];n=e[1]}else if(e.length===3){t=e[0];r=e[1];n=e[2]}else{t=e[0];r=e[1];n=e[2];o=e[3]}if(!r||typeof r!=="object"){throw new y.SchemaError("Bad schema, it should be an object or an array of object!")}if(!t||typeof t!=="object"){t={}}if(!n||typeof n!=="object"){throw new Error("The patch should be an object")}l=t.export?{}:n;f={userContext:t.userContext,validate:true,errors:[],check:h,checkAllowed:t.allowedTags?p:null,allowedTags:t.allowedTags?new Set(Array.isArray(t.allowedTags)?t.allowedTags:[t.allowedTags]):null,validatorError:w,report:!!t.report,export:!!t.export};for(i in n){a=n[i];if(f.checkAllowed){f.checkAllowed(r,i,f.allowedTags,a)}let e={displayPath:"patch."+i,path:i,key:i};if(u=d(a)){a=a[u];if(m[u].getValue){a=m[u].getValue(a)}if(m[u].applyToChildren){s=y.subSchema(r,i,undefined,true).of||{}}else{s=y.subSchema(r,i,undefined,true)}if(s?.immutable&&o&&c.get(o,i)!==undefined){throw new y.ValidatorError("Cannot patch an immutable property.",e)}if(m[u].sanitize){l[i][u]=m[u].sanitize(a);f.check(s,a,e,true)}else{l[i][u]=f.check(s,a,e,true)}}else{s=y.subSchema(r,i,undefined,true);if(s?.immutable&&o&&c.get(o,i)!==undefined){throw new y.ValidatorError("Cannot patch an immutable property.",e)}l[i]=f.check(s,a,e,true)}}if(f.report){return{validate:f.validate,sanitized:l,errors:f.errors}}return l};y.patch.report=y.patch.bind(y,{report:true});y.patch.export=y.patch.bind(y,{export:true});y.applyPatch=function(n,o){for(let r in o){let e=o[r];let t=d(e);if(t){m[t](n,r,e[t])}else{c.set(n,r,e)}}return n};function d(e){var t;if(!e||typeof e!=="object"){return false}for(t in e){if(t[0]!=="$"){return false}if(!m[t]){throw new Error("Bad command '"+t+"'")}return t}}const m={};m.$set=(e,t,r)=>c.set(e,t,r);m.$delete=m.$unset=(e,t)=>c.delete(e,t);m.$delete.getValue=()=>undefined;m.$delete.sanitize=()=>true;m.$push=(e,t,r)=>c.append(e,t,r);m.$push.applyToChildren=true;function w(e,t){var r=new y.ValidatorError(e,t);this.validate=false;if(this.report){this.errors.push(r)}else{throw r}}function n(e,t,r){var n;if(!t||typeof t!=="object"||Array.isArray(t)){throw new TypeError("[doormen] .extend*(): Argument #0 should be a plain object")}for(n in t){if(n in e&&!r||typeof t[n]!=="function"){continue}e[n]=t[n]}}y.extendTypeCheckers=function(e,t){n(a.DOORMEN_GLOBAL_EXTENSIONS.typeCheckers,e,t)};y.extendSanitizers=function(e,t){n(a.DOORMEN_GLOBAL_EXTENSIONS.sanitizers,e,t)};y.extendFilters=function(e,t){n(a.DOORMEN_GLOBAL_EXTENSIONS.filters,e,t)};y.extendConstraints=function(e,t){n(a.DOORMEN_GLOBAL_EXTENSIONS.constraints,e,t)};y.extendDefaultFunctions=function(e,t){n(a.DOORMEN_GLOBAL_EXTENSIONS.defaultFunctions,e,t)};y.clientMode=false;y.setClientMode=function(e){y.clientMode=!!e};y.shouldThrow=function e(t,r){var n=false;r=r||e;try{t()}catch(e){n=true}if(!n){throw new y.AssertionError("Function '"+(t.name||"(anonymous)")+"' should have thrown.",r)}};y.shouldReject=async function e(t,r){var n=false;r=r||e;try{await t()}catch(e){n=true}if(!n){throw new y.AssertionError("Function '"+(t.name||"(anonymous)")+"' should have rejected.",r)}};y.shouldThrowAssertion=function e(t,r){var n,o=false;r=r||e;try{t()}catch(e){o=true;n=e}if(!o){throw new y.AssertionError("Function '"+(t.name||"(anonymous)")+"' should have thrown.",r)}if(!(n instanceof y.AssertionError)){n.message="Function '"+(t.name||"(anonymous)")+"' should have thrown an AssertionError, instead it had thrown: "+n.message;throw n}return n};y.shouldRejectAssertion=async function e(t,r){var n,o=false;r=r||e;try{await t()}catch(e){o=true;n=e}if(!o){throw new y.AssertionError("Function '"+(t.name||"(anonymous)")+"' should have rejected.",r)}if(!(n instanceof y.AssertionError)){n.message="Function '"+(t.name||"(anonymous)")+"' should have rejected with an AssertionError, instead it had rejected with: "+n.message;throw n}return n};y.not=function e(...t){y.shouldThrow(()=>{y(...t)},e)};y.checkConstraints.not=function e(...t){y.shouldThrow(()=>{y.constraints(...t)},e)};y.patch.not=function e(...t){y.shouldThrow(()=>{y.patch(...t)},e)};y.equals=function e(t,r){if(!y.isEqual(t,r)){throw new y.AssertionError("should have been equal",e,{actual:t,expected:r,showDiff:true})}};y.not.equals=function e(t,r){if(y.isEqual(t,r)){throw new y.AssertionError("should not have been equal",e,{actual:t,expected:r,showDiff:true})}};const i={like:true};y.alike=function e(t,r){if(!y.isEqual(t,r,i)){throw new y.AssertionError("should have been alike",e,{actual:t,expected:r,showDiff:true})}};y.not.alike=function e(t,r){if(y.isEqual(t,r,i)){throw new y.AssertionError("should not have been alike",e,{actual:t,expected:r,showDiff:true})}}}).call(this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"./AssertionError.js":1,"./SchemaError.js":2,"./ValidatorError.js":3,"./constraints.js":6,"./defaultFunctions.js":8,"./filters.js":9,"./isEqual.js":10,"./mask.js":11,"./sanitizers.js":12,"./schemaSchema.js":13,"./typeCheckers.js":14,"tree-kit/lib/clone.js":26,"tree-kit/lib/dotPath.js":27}],8:[function(e,r,t){(function(t){(function(){"use strict";if(!t){t=window}if(!t.DOORMEN_GLOBAL_EXTENSIONS){t.DOORMEN_GLOBAL_EXTENSIONS={}}if(!t.DOORMEN_GLOBAL_EXTENSIONS.defaultFunctions){t.DOORMEN_GLOBAL_EXTENSIONS.defaultFunctions={}}const e=Object.create(t.DOORMEN_GLOBAL_EXTENSIONS.defaultFunctions);r.exports=e;e.now=()=>new Date}).call(this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{}],9:[function(t,r,e){(function(n){(function(){"use strict";if(!n){n=window}if(!n.DOORMEN_GLOBAL_EXTENSIONS){n.DOORMEN_GLOBAL_EXTENSIONS={}}if(!n.DOORMEN_GLOBAL_EXTENSIONS.filters){n.DOORMEN_GLOBAL_EXTENSIONS.filters={}}const e=Object.create(n.DOORMEN_GLOBAL_EXTENSIONS.filters);r.exports=e;const i=t("./core.js");e.instanceOf=function(e,t,r){if(typeof t==="string"){t=i.isBrowser?window[t]:n[t]}if(typeof t!=="function"){throw new i.SchemaError("Bad schema (at "+r.path+"), 'instanceOf' should be a function or a global function's name.")}if(!(e instanceof t)){this.validatorError(r.path+" is not an instance of "+t+".",r)}};e.eq=e["==="]=function(e,t,r){if(e!==t){this.validatorError(r.path+" is not stricly equal to "+t+".",r)}};e.min=e.gte=e.greaterThanOrEqual=e[">="]=function(e,t,r){if(typeof t!=="number"){throw new i.SchemaError("Bad schema (at "+r.path+"), 'min' should be a number.")}if(typeof e!=="number"||!(e>=t)){this.validatorError(r.path+" is not greater than or equal to "+t+".",r)}};e.max=e.lte=e.lesserThanOrEqual=e["<="]=function(e,t,r){if(typeof t!=="number"){throw new i.SchemaError("Bad schema (at "+r.path+"), 'max' should be a number.")}if(typeof e!=="number"||!(e<=t)){this.validatorError(r.path+" is not lesser than or equal to "+t+".",r)}};e.gt=e.greaterThan=e[">"]=function(e,t,r){if(typeof t!=="number"){throw new i.SchemaError("Bad schema (at "+r.path+"), 'greaterThan' should be a number.")}if(typeof e!=="number"||!(e>t)){this.validatorError(r.path+" is not greater than "+t+".",r)}};e.lt=e.lesserThan=e["<"]=function(e,t,r){if(typeof t!=="number"){throw new i.SchemaError("Bad schema (at "+r.path+"), 'lesserThan' should be a number.")}if(typeof e!=="number"||!(e<t)){this.validatorError(r.path+" is not lesser than "+t+".",r)}};e.length=function(e,t,r){if(typeof t!=="number"){throw new i.SchemaError("Bad schema (at "+r.path+"), 'length' should be a number.")}try{if(!(e.length===t)){throw true}}catch(e){this.validatorError(r.path+" has not a length equal to "+t+".",r)}};e.minLength=function(e,t,r){if(typeof t!=="number"){throw new i.SchemaError("Bad schema (at "+r.path+"), 'minLength' should be a number.")}try{if(!(e.length>=t)){throw true}}catch(e){this.validatorError(r.path+" has not a length greater than or equal to "+t+".",r)}};e.maxLength=function(e,t,r){if(typeof t!=="number"){throw new i.SchemaError("Bad schema (at "+r.path+"), 'maxLength' should be a number.")}try{if(!(e.length<=t)){throw true}}catch(e){this.validatorError(r.path+" has not a length lesser than or equal to "+t+".",r)}};e.match=function(e,t,r){if(typeof t!=="string"&&!(t instanceof RegExp)){throw new i.SchemaError("Bad schema (at "+r.path+"), 'match' should be a RegExp or a string.")}if(t instanceof RegExp){if(typeof e!=="string"||!e.match(t)){this.validatorError(r.path+" does not match "+t+" .",r)}}else if(typeof e!=="string"||!e.match(new RegExp(t))){this.validatorError(r.path+" does not match /"+t+"/ .",r)}};e.in=function(e,t,r){var n,o=false;if(!Array.isArray(t)){throw new i.SchemaError("Bad schema (at "+r.path+"), 'in' should be an array.")}for(n=0;n<t.length;n++){if(i.isEqual(e,t[n])){o=true;break}}if(!o){this.validatorError(r.path+" should be in "+JSON.stringify(t)+".",r)}};e.notIn=function(e,t,r){var n;if(!Array.isArray(t)){throw new i.SchemaError("Bad schema (at "+r.path+"), 'not-in' should be an array.")}for(n=0;n<t.length;n++){if(i.isEqual(e,t[n])){this.validatorError(r.path+" should not be in "+JSON.stringify(t)+".",r)}}}}).call(this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"./core.js":7}],10:[function(e,t,r){(function(i){(function(){"use strict";const o={};const r=1+4*Number.EPSILON;const n=4*Number.MIN_VALUE;function e(e,t,r=o){var n={leftStack:[],rightStack:[],like:!!r.like,oneWay:!!r.oneWay,around:!!r.around,unordered:!!r.unordered};u=null;return c(n,e,t,"")}t.exports=e;var u="";e.getLastPath=()=>u;function c(a,s,l,f){if(s===l){return true}if(typeof s!==typeof l){u=f;return false}if(typeof s==="number"){if(Number.isNaN(s)&&Number.isNaN(l)){return true}if(a.around){let e=Math.abs(s),t=Math.abs(l);if(e<=n||t<=n){if(s<=l+n&&l<=s+n){return true}}else if(s*l<0){u=f;return false}else if(e<=t*r&&t<=e*r){return true}}u=f;return false}if(!s!==!l){u=f;return false}if(!s){u=f;return false}if(typeof s==="object"){let e=a.leftStack.indexOf(s);let t=a.rightStack.indexOf(l);if(e>=0){a.leftCircular=true}if(t>=0){a.rightCircular=true}if(a.leftCircular&&a.rightCircular){return true}if(!a.like&&Object.getPrototypeOf(s)!==Object.getPrototypeOf(l)){u=f;return false}if(Array.isArray(s)){if(!Array.isArray(l)){u=f;return false}if(s.length!==l.length){u=f+"."+Math.min(s.length,l.length);return false}if(a.unordered){let o=new Array(s.length);let e=s.length;let i=l.length;for(let n=0;n<e;n++){if(!o[n]){if(s[n]===l[n]){continue}a.leftStack.push(s);a.rightStack.push(l);let e=c(a,s[n],l[n],f+"."+n);a.leftStack.pop();a.rightStack.pop();if(e){o[n]=true;continue}}let r=false;for(let t=0;t<i;t++){if(n===t||o[t]){continue}if(s[n]===l[t]){r=true;o[t]=true;break}a.leftStack.push(s);a.rightStack.push(l);let e=c(a,s[n],l[t],f+"."+n);a.leftStack.pop();a.rightStack.pop();if(e){r=true;o[t]=true;break}}if(!r){u=f;return false}}}else{for(let t=0,e=s.length;t<e;t++){if(s[t]===l[t]){continue}a.leftStack.push(s);a.rightStack.push(l);let e=c(a,s[t],l[t],f+"."+t);a.leftStack.pop();a.rightStack.pop();if(!e){return false}}}}else if(i.isBuffer(s)){return i.isBuffer(l)&&s.equals(l)}else{if(Array.isArray(l)){u=f;return false}if(typeof s.valueOf==="function"&&typeof l.valueOf==="function"){let o=s.valueOf();let i=l.valueOf();if(o!==s&&i!==l){let e=Object.getPrototypeOf(s);let t=e&&e.constructor;let r=Object.getPrototypeOf(l);let n=r&&r.constructor;if(t&&n&&(t===n||s instanceof n||l instanceof t)){a.leftStack.push(s);a.rightStack.push(l);let e=c(a,o,i,f);a.leftStack.pop();a.rightStack.pop();if(!e){return false}}}}let n=Object.getOwnPropertyDescriptors(s);for(let t of Reflect.ownKeys(n)){if(!n[t].enumerable){continue}if(s[t]===undefined){continue}if(l[t]===undefined){u=f+"."+t.toString();return false}if(s[t]===l[t]){continue}a.leftStack.push(s);a.rightStack.push(l);let e=c(a,s[t],l[t],f+"."+t.toString());a.leftStack.pop();a.rightStack.pop();if(!e){return false}}if(!a.oneWay){let r=Object.getOwnPropertyDescriptors(l);for(let t of Reflect.ownKeys(r)){if(!r[t].enumerable){continue}if(l[t]===undefined){continue}if(s[t]===undefined){u=f+"."+t.toString();return false}if(l[t]===s[t]||n[t].enumerable){continue}a.leftStack.push(s);a.rightStack.push(l);let e=c(a,s[t],l[t],f+"."+t.toString());a.leftStack.pop();a.rightStack.pop();if(!e){return false}}}}return true}u=f;return false}}).call(this)}).call(this,{isBuffer:e("../../../../../../opt/node-v22.16.0/lib/node_modules/browserify/node_modules/is-buffer/index.js")})},{"../../../../../../opt/node-v22.16.0/lib/node_modules/browserify/node_modules/is-buffer/index.js":29}],11:[function(e,t,i){"use strict";i.tierMask=function(e,t,r=0,n=Infinity){if(!e||typeof e!=="object"){throw new TypeError("Bad schema, it should be an object or an array of object!")}var o={mask:i.tierMask,tier:r,iterate:a,check:s,depth:0,depthLimit:n};return o.iterate(e,t)};i.tagMask=function(e,t,r,n=Infinity){if(!e||typeof e!=="object"){throw new TypeError("Bad schema, it should be an object or an array of object!")}if(!(r instanceof Set)){if(Array.isArray(r)){r=new Set(r)}else{r=new Set([r])}}var o={mask:i.tagMask,tags:r,iterate:a,check:l,depth:0,depthLimit:n};return o.iterate(e,t)};function a(e,t){var r,n,o=t,i,a,s;if(!e||typeof e!=="object"){return}if(Array.isArray(e)){for(r=0;r<e.length;r++){try{o=this.mask(e[r],t,this.tier||this.tags,this.depthLimit-this.depth)}catch(e){continue}return o}return}s=this.check(e);if(s===false){return}else if(s===true&&e.noSubmasking){return o}if(this.depth>=this.depthLimit){return o}if(e.of&&typeof e.of==="object"){if(!o||typeof o!=="object"&&typeof o!=="function"){return o}if(Array.isArray(o)){if(o===t){o=[];i=t}else{i=o}for(r=0;r<i.length;r++){this.depth++;o[r]=this.iterate(e.of,i[r]);this.depth--}}else{if(o===t){o={};i=t}else{i=o}for(n in i){this.depth++;o[n]=this.iterate(e.of,i[n]);this.depth--}}}if(e.properties&&typeof e.properties==="object"){if(!o||typeof o!=="object"&&typeof o!=="function"){return o}if(o===t){o={};i=t}else{i=o}if(Array.isArray(e.properties)){for(r=0;r<e.properties.length;r++){n=e.properties[r];o[n]=i[n]}}else{for(n in e.properties){if(!e.properties[n]||typeof e.properties[n]!=="object"){continue}this.depth++;a=this.iterate(e.properties[n],i[n]);this.depth--;if(a!==undefined){o[n]=a}}if(e.extraProperties){for(n in i){if(!e.properties[n]){o[n]=i[n]}}}}}if(Array.isArray(e.elements)){if(!Array.isArray(o)){return o}if(o===t){o=[];i=t}else{i=o}for(r=0;r<e.elements.length;r++){this.depth++;o[r]=this.iterate(e.elements[r],i[r]);this.depth--}}return o}function s(e){if(e.tier===undefined){return}if(this.tier<e.tier){return false}return true}function l(e){var t,r;if(!Array.isArray(e.tags)||!e.tags.length){return}r=e.tags.length;for(t=0;t<r;t++){if(this.tags.has(e.tags[t])){return true}}return false}i.getAllSchemaTags=function(e,t=new Set,r=10){var n,o;if(!e||typeof e!=="object"||r<=0){return t}if(Array.isArray(e)){for(n=0;n<e.length;n++){this.getAllSchemaTags(e[n],t,r-1)}return t}if(e.tags){e.tags.forEach(e=>t.add(e))}if(e.noSubmasking){return t}if(e.of&&typeof e.of==="object"){this.getAllSchemaTags(e.of,t,r-1)}if(e.properties&&typeof e.properties==="object"&&!Array.isArray(e.properties)){for(o in e.properties){if(e.properties[o]||typeof e.properties[o]==="object"){this.getAllSchemaTags(e.properties[o],t,r-1)}}}if(Array.isArray(e.elements)){for(n=0;n<e.elements.length;n++){this.getAllSchemaTags(e.elements[n],t,r-1)}}return t}},{}],12:[function(s,l,e){(function(e){(function(){"use strict";const t=s("string-kit/lib/latinize.js");const r=s("string-kit/lib/toTitleCase.js");if(!e){e=window}if(!e.DOORMEN_GLOBAL_EXTENSIONS){e.DOORMEN_GLOBAL_EXTENSIONS={}}if(!e.DOORMEN_GLOBAL_EXTENSIONS.sanitizers){e.DOORMEN_GLOBAL_EXTENSIONS.sanitizers={}}const n=Object.create(e.DOORMEN_GLOBAL_EXTENSIONS.sanitizers);l.exports=n;const o=s("./core.js");n.toString=t=>{if(typeof t==="string"){return t}try{return""+t}catch(e){return t}};n.toStringEmpty=e=>{if(e===undefined||e===null){return""}return n.toString(e)};n.numberToString=e=>{if(typeof e==="number"){return""+e}return e};n.toNumber=e=>{if(typeof e==="number"){return e}else if(!e){return NaN}else if(typeof e==="string"){return parseFloat(e)}return NaN};n.toFloat=n.toReal=n.toNumber;n.toInteger=e=>{if(typeof e==="number"){return Math.round(e)}else if(!e){return NaN}else if(typeof e==="string"){return Math.round(parseFloat(e))}return NaN};n.toBoolean=e=>{if(typeof e==="boolean"){return e}switch(e){case 1:case"1":case"on":case"On":case"ON":case"true":case"True":case"TRUE":case"yes":case"Yes":case"YES":return true;case 0:case"0":case"off":case"Off":case"OFF":case"false":case"False":case"FALSE":case"no":case"No":case"NO":return false;default:return!!e}};n.toArray=e=>{if(Array.isArray(e)){return e}if(e===undefined){return[]}if(e&&typeof e==="object"&&o.typeCheckers.arguments(e)){return Array.prototype.slice.call(e)}return[e]};n.toDate=e=>{var t;if(e instanceof Date){return e}if(typeof e==="number"||typeof e==="string"||e&&typeof e==="object"&&e.constructor.name==="Date"){t=new Date(e);return isNaN(t)?e:t}return e};n.removeExtraProperties=(e,t,r)=>{var n,o,i;if(!e||typeof e!=="object"&&typeof e!=="function"||!t.properties||typeof t.properties!=="object"){return e}if(r){i=Array.isArray(e)?e.slice():{};if(Array.isArray(t.properties)){for(n=0;n<t.properties.length;n++){o=t.properties[n];if(o in e){i[o]=e[o]}}}else{for(o in t.properties){if(o in e){i[o]=e[o]}}}return i}if(Array.isArray(t.properties)){for(o in e){if(t.properties.indexOf(o)===-1){delete e[o]}}}else{for(o in e){if(!(o in t.properties)){delete e[o]}}}return e};n.trim=e=>typeof e==="string"?e.trim():e;n.toUpperCase=e=>typeof e==="string"?e.toUpperCase():e;n.toLowerCase=e=>typeof e==="string"?e.toLowerCase():e;n.capitalize=e=>typeof e==="string"?r(e,n.capitalize.toTitleCaseOptions):e;n.capitalize.toTitleCaseOptions={};n.titleCase=e=>typeof e==="string"?r(e,n.titleCase.toTitleCaseOptions):e;n.titleCase.toTitleCaseOptions={zealous:1,preserveAllCaps:true};n.latinize=e=>typeof e==="string"?t(e):e;n.dashToCamelCase=e=>typeof e==="string"?e.replace(/-(.)/g,(e,t)=>t.toUpperCase()):e;function i(e,t,r){if(t.leftPadding){return t.leftPadding[0].repeat(r)+e}if(t.rightPadding){return e+t.rightPadding[0].repeat(r)}return e+" ".repeat(r)}n.resize=(e,t)=>{if(typeof e!=="string"){return e}if(t.length){if(e.length>t.length){return e.slice(0,t.length)}if(e.length<t.length){return i(e,t,t.length-e.length)}return e}if(t.maxLength&&e.length>t.maxLength){return e.slice(0,t.maxLength)}if(t.minLength&&e.length<t.minLength){return i(e,t,t.minLength-e.length)}return e};n.nullToUndefined=e=>e===null?undefined:e;const a=e=>s(e);n.mongoId=t=>{if(typeof t!=="string"){return t}if(o.isBrowser){return t}try{let e=a("mongodb");return e.ObjectId?new e.ObjectId(t):new e.ObjectID(t)}catch(e){return t}}}).call(this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"./core.js":7,"string-kit/lib/latinize.js":22,"string-kit/lib/toTitleCase.js":24}],13:[function(e,t,r){"use strict";const n={optional:true,type:"strictObject",extraProperties:true,properties:{type:{optional:true,type:"string"},optional:{optional:true,type:"boolean"},extraProperties:{optional:true,type:"boolean"},default:{optional:true},value:{optional:true},immutable:{optional:true,type:"boolean"},sanitize:{optional:true,sanitize:"toArray",type:"array",of:{type:"string"}},filter:{optional:true,type:"strictObject"},constraints:{optional:true,type:"array",of:{type:"strictObject",extraProperties:true,properties:{enforce:{type:"string"},resolve:{type:"boolean",default:false},ifEmtpy:{type:"boolean",default:false}}}},tier:{optional:true,type:"integer"},tags:{optional:true,sanitize:"toArray",type:"array",of:{type:"string"}},instanceOf:{optional:true,type:"classId"},min:{optional:true,type:"integer"},max:{optional:true,type:"integer"},length:{optional:true,type:"integer"},minLength:{optional:true,type:"integer"},maxLength:{optional:true,type:"integer"},match:{optional:true,type:"regexp"},in:{optional:true,type:"array"},notIn:{optional:true,type:"array"},hooks:{optional:true,type:"strictObject",of:{type:"array",sanitize:"toArray",of:{type:"function"}}}}};const o=[n,{type:"array",of:n}];n.properties.of=o;n.properties.properties=[{optional:true,type:"strictObject",of:o},{optional:true,type:"array",of:{type:"string"}}];n.properties.elements={optional:true,type:"array",of:o};t.exports=o},{}],14:[function(n,o,e){(function(e,r){(function(){"use strict";if(!e){e=window}if(!e.DOORMEN_GLOBAL_EXTENSIONS){e.DOORMEN_GLOBAL_EXTENSIONS={}}if(!e.DOORMEN_GLOBAL_EXTENSIONS.typeCheckers){e.DOORMEN_GLOBAL_EXTENSIONS.typeCheckers={}}const i=Object.create(e.DOORMEN_GLOBAL_EXTENSIONS.typeCheckers);o.exports=i;const t=n("./core.js");i.undefined=e=>e===undefined;i.null=e=>e===null;i.boolean=e=>typeof e==="boolean";i.number=e=>typeof e==="number";i.string=e=>typeof e==="string";i.object=e=>e&&typeof e==="object";i.function=e=>typeof e==="function";i.array=e=>Array.isArray(e);i.error=e=>e instanceof Error;i.date=i.datetime=e=>e instanceof Date&&!Number.isNaN(+e);i.arguments=e=>Object.prototype.toString.call(e)==="[object Arguments]";i.buffer=e=>{try{return e instanceof r}catch(e){return false}};i.strictObject=e=>e&&typeof e==="object"&&!Array.isArray(e);i.looseObject=e=>e&&typeof e==="object"||typeof e==="function";i.classId=e=>typeof e==="function"||typeof e==="string"&&e.length;i.unset=e=>e===undefined||e===null;i.regexp=e=>{if(e instanceof RegExp){return true}if(typeof e!=="string"){return false}try{new RegExp(e);return true}catch(e){return false}};i.schema=e=>{try{t.validateSchema(e)}catch(e){return false}return true};i.float=i.real=e=>typeof e==="number"&&Number.isFinite(e);i.integer=e=>typeof e==="number"&&Number.isFinite(e)&&e===Math.round(e);i.hex=e=>typeof e==="string"&&/^[0-9a-fA-F]+$/.test(e);i.ip=(e,t)=>i.ipv4(e,t)||i.ipv6(e,t);i.ipv4=(e,t,r)=>{var n,o,i;if(typeof e!=="string"){return false}if(!r&&!/^[0-9.]+$/.test(e)){return false}o=e.split(".");if(o.length!==4){return false}for(n=0;n<o.length;n++){if(!o[n].length||o[n].length>3){return false}i=parseInt(o[n],10);if(!(i>=0&&i<=255)){return false}}return true};i.ipv6=(e,t,r)=>{var n,o,i=false,a=false,s=false;if(typeof e!=="string"){return false}if(!r&&!/^[0-9a-f:]+$/.test(e)){return false}o=e.split(":");if(o.length>9&&o.length<3){return false}for(n=0;n<o.length;n++){if(!o[n].length){if(n===0){a=true;if(o[1].length){return false}}else if(n===o.length-1){s=true;if(o[n-1].length){return false}}else{if(i){return false}i=true}}else if(o[n].length>4){return false}}if(o.length<8&&!i){return false}if(o.length-(a?1:0)-(s?1:0)>8){return false}return true};i.hostname=(e,t,r)=>{var n,o;if(typeof e!=="string"){return false}if(!r&&!/^[^\s/$?#@:]+$/.test(e)){return false}o=e.split(".");for(n=0;n<o.length;n++){if(!o[n].length&&n!==o.length-1){return false}if(o[n].length>63){return false}}return true};i.host=(e,t)=>i.ip(e,t)||i.hostname(e,t);i.url=(e,t,r)=>{if(typeof e!=="string"){return false}var n=e.match(/^([a-z+.-]+):\/\/((?:([^\s@/:]+)(?::([^\s@/:]+))?@)?(([0-9.]+)|([0-9a-f:]+)|([^\s/$?#@:]+))(:[0-9]+)?)?(\/[^\s]*)?$/);if(!n){return false}if(r&&n[1]!=="http"&&n[1]!=="https"&&n[1]!=="ftp"){return false}if(!n[2]&&n[1]!=="file"){return false}if(n[6]){if(!i.ipv4(n[6],t,true)){return false}}if(n[7]){if(!i.ipv6(n[7],t,true)){return false}}if(n[8]){if(!i.hostname(n[8],t,true)){return false}}return true};i.weburl=(e,t)=>i.url(e,t,true);i.email=(e,t)=>{var r,n,o;if(typeof e!=="string"){return false}if(e.length>254){return false}r=e.match(/^([a-zA-Z0-9._#~!$&*+=,;:\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF-]+)@([^\s/$?#@:]+)$/);if(!r){return false}if(r[1].length>64){return false}o=r[1].split(".");for(n=0;n<o.length;n++){if(!o[n].length){return false}}if(!i.hostname(r[2],t,true)){return false}return true};i.mongoId=e=>{if(e&&typeof e==="object"&&(e.constructor.name==="ObjectId"||e.constructor.name==="ObjectID")&&e.id&&typeof e.toString==="function"){e=e.toString()}return typeof e==="string"&&e.length===24&&/^[0-9a-f]{24}$/.test(e)}}).call(this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{},n("buffer").Buffer)},{"./core.js":7,buffer:28}],15:[function(e,t,r){"use strict";const n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"];function o(e,t={}){this.sign=1;this.digits=[];this.exposant=0;this.special=null;this.decimalSeparator=t.decimalSeparator??".";this.forceDecimalSeparator=!!t.forceDecimalSeparator;this.groupSeparator=t.groupSeparator??"";this.numerals=t.numerals??n;this.numeralZero=t.numeralZero??null;this.placeNumerals=t.placeNumerals??null;this.set(e)}t.exports=o;o.prototype.set=function(e){var t,r,n,o,i,a,s;e=+e;this.sign=1;this.digits.length=0;this.exposant=0;this.special=null;if(!Number.isFinite(e)){this.special=e;return null}e=""+e;t=e.match(/(-)?([0-9]+)(?:.([0-9]+))?(?:e([+-][0-9]+))?/);if(!t){throw new Error("Unexpected error")}this.sign=t[1]?-1:1;this.exposant=t[2].length+(parseInt(t[4],10)||0);i=0;a=false;s=0;for(n=0,o=t[2].length;n<o;n++){r=+t[2][n];if(r!==0){a=true;this.digits[i]=r;i++;s=i}else if(a){this.digits[i]=r;i++}else{this.exposant--}}if(t[3]){for(n=0,o=t[3].length;n<o;n++){r=+t[3][n];if(r!==0){a=true;this.digits[i]=r;i++;s=i}else if(a){this.digits[i]=r;i++}else{this.exposant--}}}if(s!==i){this.digits.length=s}};o.prototype.toNumber=function(){if(this.special!==null){return this.special}return parseFloat((this.sign<0?"-":"")+"0."+this.digits.join("")+"e"+this.exposant)};o.prototype.toString=function(...e){if(this.special!==null){return""+this.special}if(this.exposant>20||this.exposant<-20){return this.toScientificString(...e)}return this.toNoExpString(...e)};o.prototype.toExponential=o.prototype.toExponentialString=function(){if(this.special!==null){return""+this.special}var e=this.sign<0?"-":"";if(!this.digits.length){return e+"0"}e+=this.digits[0];if(this.digits.length>1){e+=this.decimalSeparator+this.digits.join("").slice(1)}e+="e"+(this.exposant>0?"+":"")+(this.exposant-1);return e};const i=["⁰","¹","²","³","⁴","⁵","⁶","⁷","⁸","⁹"];const a="⁺";const s="⁻";const l="0".charCodeAt(0);o.prototype.toScientific=o.prototype.toScientificString=function(){if(this.special!==null){return""+this.special}var e=this.sign<0?"-":"";if(!this.digits.length){return e+"0"}e+=this.digits[0];if(this.digits.length>1){e+=this.decimalSeparator+this.digits.join("").slice(1)}var t=(this.exposant<=0?s:"")+(""+Math.abs(this.exposant-1)).split("").map(e=>i[e.charCodeAt(0)-l]).join("");e+=" × 10"+t;return e};o.prototype.toNoExp=o.prototype.toNoExpString=function(e=1,t=0,r=false,n=false,o=this.exposant){if(this.special!==null){return""+this.special}var i=[],a=[],s=this.sign<0?"-":n?"+":"";if(!this.digits.length){if(e>1){this.fillZeroes(i,e-1,e)}i.push(this.numeralZero??this.placeNumerals?.[0]?.[0]??this.numerals[0]);if(t&&!r){this.fillZeroes(a,t)}}else if(o<=0){this.fillZeroes(i,e);this.fillZeroes(a,-o,t-this.digits.length);this.appendNumerals(a,this.digits,undefined,undefined,-o-1);if(t&&this.digits.length-o<t){this.fillZeroes(a,t-this.digits.length+o)}}else if(o>=this.digits.length){if(o<e){this.fillZeroes(i,e-o,o-1)}this.appendNumerals(i,this.digits,undefined,undefined,o-1);this.fillZeroes(i,o-this.digits.length);if(t&&!r){this.fillZeroes(a,t)}}else{if(o<e){this.fillZeroes(i,e-o)}this.appendNumerals(i,this.digits,0,o,o-1);this.appendNumerals(a,this.digits,o,undefined,this.digits.length-o);if(t&&this.digits.length-o<t&&(!r||this.digits.length-o>0)){this.fillZeroes(a,t-this.digits.length+o)}}s+=this.groupSeparator?this.groupDigits(i,this.groupSeparator):i.join("");if(a.length){s+=this.decimalSeparator+(this.decimalGroupSeparator?this.groupDigits(a,this.decimalGroupSeparator):a.join(""))}else if(this.forceDecimalSeparator){s+=this.decimalSeparator}return s};const f=["","k","M","G","T","P","E","Z","Y"];const u=["","m","µ","n","p","f","a","z","y"];o.prototype.toMetric=o.prototype.toMetricString=function(e=1,t=0,r=false,n=false){if(this.special!==null){return""+this.special}if(!this.digits.length){return this.sign>0?"0":"-0"}var o="",i;if(this.exposant>0){i=1+(this.exposant-1)%3;o=f[Math.floor((this.exposant-1)/3)];if(o===undefined){return this.toScientificString()}}else{i=3- -this.exposant%3;o=u[1+Math.floor(-this.exposant/3)];if(o===undefined){return this.toScientificString()}}return this.toNoExpString(e,t,r,n,i)+o};o.prototype.precision=function(r,e=0){var t;if(this.special!==null||r>=this.digits.length){return this}if(r<0){this.digits.length=0;return this}e*=this.sign;if(e<0){t=this.digits.length>r+4&&this.digits[r]===9&&this.digits[r+1]===9&&this.digits[r+2]===9&&this.digits[r+3]===9&&this.digits[r+4]===9}else if(e>0){t=this.digits[r]>0||this.digits[r+1]>0||this.digits[r+2]>0||this.digits[r+3]>0||this.digits[r+4]>0}else{t=this.digits[r]>=5}if(t){let e=r-1,t=false;for(;e>=0;e--){if(this.digits[e]<9){this.digits[e]++;t=true;break}else{this.digits[e]=0}}if(!t){this.exposant++;this.digits[0]=1;this.digits.length=1}else{this.digits.length=e+1}}else{this.digits.length=r;this.removeTrailingZero()}return this};o.prototype.round=function(e=0,t=0){var r=this.exposant+e;return this.precision(r,t)};o.prototype.floor=function(e=0){var t=this.exposant+e;return this.precision(t,-1)};o.prototype.ceil=function(e=0){var t=this.exposant+e;return this.precision(t,1)};o.prototype.removeTrailingZero=function(){var e=this.digits.length-1;while(e>=0&&this.digits[e]===0){e--}this.digits.length=e+1};const c=3;o.prototype.groupDigits=function(e,t,r=false){var n="",o=r?0:c-e.length%c,i=0,a=e.length;for(;i<a;i++){n+=i&&(i+o)%c===0?t+e[i]:e[i]}return n};o.prototype.appendNumerals=function(n,o,e=0,i=o.length,a=i){for(let t=e,r=a;t<i;t++,r--){let e=this.placeNumerals?.[r]??this.numerals;n.push(e[o[t]]??o[t])}return n};o.prototype.fillZeroes=function(r,n,o=n-1){for(let e=0,t=o;e<n;e++,t--){let e=this.placeNumerals?.[t]??this.numerals;r.push(e[0]??0)}return r};const h={numeralZero:"N",placeNumerals:[["","I","II","III","IV","V","VI","VII","VIII","IX"],["","X","XX","XXX","XL","L","LX","LXX","LXXX","XC"],["","C","CC","CCC","CD","D","DC","DCC","DCCC","CM"],["","M","MM","MMM","MMMM","ↁ","ↁↀ","ↁↀↀ","ↁↀↀↀ","ↁↀↀↀↀ"]]};const p={numeralZero:"N",placeNumerals:[["","I","II","III","IIII","V","VI","VII","VIII","VIIII"],["","X","XX","XXX","XXXX","L","LX","LXX","LXXX","LXXXX"],["","C","CC","CCC","CCCC","D","DC","DCC","DCCC","DCCCC"],["","M","MM","MMM","MMMM","ↁ","ↁↀ","ↁↀↀ","ↁↀↀↀ","ↁↀↀↀↀ"]]};const d={numeralZero:"N",placeNumerals:[["","I","II","III","IV","V","VI","VII","VIII","IX"],["","X","XX","XXX","XL","L","LX","LXX","LXXX","XC"],["","C","CC","CCC","CD","D","DC","DCC","DCCC","CM"],["","M","MM","MMM","MMMM","IↃↃ","IↃↃCIↃ","IↃↃCIↃCIↃ","IↃↃCIↃCIↃCIↃ","IↃↃCIↃCIↃCIↃCIↃ"],["","CCIↃↃ","CCIↃↃCCIↃↃ","CCIↃↃCCIↃↃCCIↃↃ","CCIↃↃCCIↃↃCCIↃↃCCIↃↃ","IↃↃↃ","IↃↃↃCCIↃↃ","IↃↃↃCCIↃↃCCIↃↃ","IↃↃↃCCIↃↃCCIↃↃCCIↃↃ","IↃↃↃCCIↃↃCCIↃↃCCIↃↃCCIↃↃ"],["","CCCIↃↃↃ","CCCIↃↃↃCCCIↃↃↃ","CCCIↃↃↃCCCIↃↃↃCCCIↃↃↃ","CCCIↃↃↃCCCIↃↃↃCCCIↃↃↃCCCIↃↃↃ","IↃↃↃↃ","IↃↃↃↃCCCIↃↃↃ","IↃↃↃↃCCCIↃↃↃCCCIↃↃↃ","IↃↃↃↃCCCIↃↃↃCCCIↃↃↃCCCIↃↃↃ","IↃↃↃↃCCCIↃↃↃCCCIↃↃↃCCCIↃↃↃCCCIↃↃↃ"]]};o.roman=(e,t)=>{t=t?Object.assign({},t,h):h;return new o(e,t)};o.additiveRoman=(e,t)=>{t=t?Object.assign({},t,p):p;return new o(e,t)}},{}],16:[function(e,t,r){"use strict";const n={reset:"",bold:"",dim:"",italic:"",underline:"",inverse:"",defaultColor:"",black:"",red:"",green:"",yellow:"",blue:"",magenta:"",cyan:"",white:"",grey:"",gray:"",brightBlack:"",brightRed:"",brightGreen:"",brightYellow:"",brightBlue:"",brightMagenta:"",brightCyan:"",brightWhite:"",defaultBgColor:"",bgBlack:"",bgRed:"",bgGreen:"",bgYellow:"",bgBlue:"",bgMagenta:"",bgCyan:"",bgWhite:"",bgGrey:"",bgGray:"",bgBrightBlack:"",bgBrightRed:"",bgBrightGreen:"",bgBrightYellow:"",bgBrightBlue:"",bgBrightMagenta:"",bgBrightCyan:"",bgBrightWhite:""};t.exports=n;n.fgColor={defaultColor:n.defaultColor,black:n.black,red:n.red,green:n.green,yellow:n.yellow,blue:n.blue,magenta:n.magenta,cyan:n.cyan,white:n.white,grey:n.grey,gray:n.gray,brightBlack:n.brightBlack,brightRed:n.brightRed,brightGreen:n.brightGreen,brightYellow:n.brightYellow,brightBlue:n.brightBlue,brightMagenta:n.brightMagenta,brightCyan:n.brightCyan,brightWhite:n.brightWhite};n.bgColor={defaultColor:n.defaultBgColor,black:n.bgBlack,red:n.bgRed,green:n.bgGreen,yellow:n.bgYellow,blue:n.bgBlue,magenta:n.bgMagenta,cyan:n.bgCyan,white:n.bgWhite,grey:n.bgGrey,gray:n.bgGray,brightBlack:n.bgBrightBlack,brightRed:n.bgBrightRed,brightGreen:n.bgBrightGreen,brightYellow:n.bgBrightYellow,brightBlue:n.bgBrightBlue,brightMagenta:n.bgBrightMagenta,brightCyan:n.bgBrightCyan,brightWhite:n.bgBrightWhite};n.trueColor=(t,r,n)=>{if(r===undefined&&typeof t==="string"){let e=t;if(e[0]==="#"){e=e.slice(1)}if(e.length===3){e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]}t=parseInt(e.slice(0,2),16)||0;r=parseInt(e.slice(2,4),16)||0;n=parseInt(e.slice(4,6),16)||0}return"[38;2;"+t+";"+r+";"+n+"m"};n.bgTrueColor=(t,r,n)=>{if(r===undefined&&typeof t==="string"){let e=t;if(e[0]==="#"){e=e.slice(1)}if(e.length===3){e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]}t=parseInt(e.slice(0,2),16)||0;r=parseInt(e.slice(2,4),16)||0;n=parseInt(e.slice(4,6),16)||0}return"[48;2;"+t+";"+r+";"+n+"m"};const a={0:null,1:{bold:true},2:{dim:true},22:{bold:false,dim:false},3:{italic:true},23:{italic:false},4:{underline:true},24:{underline:false},5:{blink:true},25:{blink:false},7:{inverse:true},27:{inverse:false},8:{hidden:true},28:{hidden:false},9:{strike:true},29:{strike:false},30:{color:0},31:{color:1},32:{color:2},33:{color:3},34:{color:4},35:{color:5},36:{color:6},37:{color:7},39:{color:"default"},90:{color:8},91:{color:9},92:{color:10},93:{color:11},94:{color:12},95:{color:13},96:{color:14},97:{color:15},40:{bgColor:0},41:{bgColor:1},42:{bgColor:2},43:{bgColor:3},44:{bgColor:4},45:{bgColor:5},46:{bgColor:6},47:{bgColor:7},49:{bgColor:"default"},100:{bgColor:8},101:{bgColor:9},102:{bgColor:10},103:{bgColor:11},104:{bgColor:12},105:{bgColor:13},106:{bgColor:14},107:{bgColor:15}};n.parse=e=>{var t,r,n,o,i=[];for([,t,r]of e.matchAll(/\x1b\[([0-9;]+)m|(.[^\x1b]*)/g)){if(r){if(i.length){i[i.length-1].text+=r}else{i.push({text:r})}}else{t.split(";").forEach(e=>{o=a[e];if(o===undefined){return}if(!i.length||i[i.length-1].text){if(!o){n={text:""}}else{n=Object.assign({},n,o);n.text=""}i.push(n)}else{if(!o){i[i.length-1]={text:""}}else{Object.assign(n,o)}}})}}return i}},{}],17:[function(e,t,r){"use strict";r.regExp=r.regExpPattern=e=>e.replace(/([.*+?^${}()|[\]/\\])/g,"\\$1");r.regExpReplacement=e=>e.replace(/\$/g,"$$$$");r.format=e=>e.replace(/%/g,"%%");r.jsSingleQuote=e=>r.control(e).replace(/'/g,"\\'");r.jsDoubleQuote=e=>r.control(e).replace(/"/g,'\\"');r.shellArg=e=>"'"+e.replace(/'/g,"'\\''")+"'";var n={"\r":"\\r","\n":"\\n","\t":"\\t","":"\\x7f"};r.control=(e,r=false)=>e.replace(/[\x00-\x1f\x7f]/g,e=>{if(r&&(e==="\n"||e==="\t")){return e}if(n[e]!==undefined){return n[e]}var t=e.charCodeAt(0).toString(16);if(t.length%2){t="0"+t}return"\\x"+t});var o={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#039;"};r.html=e=>e.replace(/[&<>]/g,e=>o[e]);r.htmlAttr=e=>e.replace(/[&<>"]/g,e=>o[e]);r.htmlSpecialChars=e=>e.replace(/[&<>"']/g,e=>o[e]);r.unicodePercentEncode=e=>e.replace(/[\x00-\x1f\u0100-\uffff\x7f%]/g,e=>{try{return encodeURI(e)}catch(e){return""}});r.httpHeaderValue=e=>r.unicodePercentEncode(e)},{}],18:[function(D,e,B){(function(T){(function(){"use strict";const f=D("./inspect.js").inspect;const u=D("./inspect.js").inspectError;const t=D("./escape.js");const o=D("./ansi.js");const i=D("./unicode.js");const a=D("./naturalSort.js");const d=D("./StringNumber.js");B.formatMethod=function(...y){var g,e=y[0],b=1,m=y.length;if(typeof e!=="string"){if(!e){e=""}else if(typeof e.toString==="function"){e=e.toString()}else{e=""}}var w={hasMarkup:false,shift:null,markupStack:[]};if(this.markupReset&&this.startingMarkupReset){e=(typeof this.markupReset==="function"?this.markupReset(w.markupStack):this.markupReset)+e}e=e.replace(/\^\[([^\]]*)]?|\^(.)|(%%)|%([+-]?)([0-9]*)(?:\[([^\]]*)\])?([a-zA-Z])/g,(e,t,r,n,o,i,a,s)=>{var l,f,u,c,h,p,d=[];if(n){return"%"}if(t){r=t}if(r){if(this.noMarkup){return"^"+r}return k.call(this,w,e,r)}if(i){i=parseInt(i,10);if(o){if(o==="+"){i=b+i}else if(o==="-"){i=b-i}}}else{i=b}b++;if(i>=m||i<1){g=undefined}else{g=y[i]}if(S[s]){l=S[s](g,a,this);if(this.argumentSanitizer&&!S[s].noSanitize){l=this.argumentSanitizer(l)}if(this.escapeMarkup&&!S[s].noEscapeMarkup){l=B.escapeMarkup(l)}if(a&&!S[s].noCommonModeArg){l=v(l,a)}return l}if(s==="F"){b--;if(a===undefined){return""}u=a.split(":");c=u[0];h=u[1];if(!c){return""}if(h&&(p=h.match(/%([+-]?)([0-9]*)[a-zA-Z]/g))){for(f=0;f<p.length;f++){o=p[f][1];i=p[f][2];if(i){i=parseInt(i,10);if(o){if(o==="+"){i=b+i}else if(o==="-"){i=b-i}}}else{i=b}b++;if(i>=m||i<1){d[f]=undefined}else{d[f]=y[i]}}}if(!this||!this.fn||typeof this.fn[c]!=="function"){return""}return this.fn[c].apply(this,d)}return""});if(w.hasMarkup&&this.markupReset&&this.endingMarkupReset){e+=typeof this.markupReset==="function"?this.markupReset(w.markupStack):this.markupReset}if(this.extraArguments){for(;b<m;b++){g=y[b];if(g===null||g===undefined){continue}else if(typeof g==="string"){e+=g}else if(typeof g==="number"){e+=g}else if(typeof g.toString==="function"){e+=g.toString()}}}return e};B.markupMethod=function(l){if(typeof l!=="string"){if(!l){l=""}else if(typeof l.toString==="function"){l=l.toString()}else{l=""}}var f={hasMarkup:false,shift:null,markupStack:[]};if(this.parse){let e,t,r,n,o,i,a,s=[];for([r,n,o,i]of l.matchAll(/\^\[([^\]]*)]?|\^(.)|([^^]+)/g)){if(i){if(s.length){s[s.length-1].text+=i}else{s.push({text:i})}continue}if(n){o=n}e=k.call(this,f,r,o);if(!Array.isArray(e)){e=[e]}for(t of e){a=s.length?s[s.length-1]:null;if(typeof t==="string"){if(a){a.text+=t}else{s.push({text:t})}}else if(!t){if(a&&a.text.length&&Object.keys(a).length>1){s.push({text:""})}}else{if(a&&a.text.length){s.push(Object.assign({text:""},...f.markupStack))}else{if(a){Object.assign(a,t)}else{s.push(Object.assign({text:""},t))}}}}}return s}if(this.markupReset&&this.startingMarkupReset){l=(typeof this.markupReset==="function"?this.markupReset(f.markupStack):this.markupReset)+l}l=l.replace(/\^\[([^\]]*)]?|\^(.)/g,(e,t,r)=>k.call(this,f,e,t||r));if(f.hasMarkup&&this.markupReset&&this.endingMarkupReset){l+=typeof this.markupReset==="function"?this.markupReset(f.markupStack):this.markupReset}return l};function k(e,t,r){var n,o,i,a,s;if(r==="^"){return"^"}if(this.shiftMarkup&&this.shiftMarkup[r]){e.shift=this.shiftMarkup[r];return""}if(r.length>1&&this.dataMarkup&&(s=r.indexOf(":"))!==-1){o=r.slice(0,s);n=this.dataMarkup[o];if(n===undefined){if(this.markupCatchAll===undefined){return""}n=this.markupCatchAll}e.hasMarkup=true;i=r.slice(s+1);if(typeof n==="function"){a=n(e.markupStack,o,i)}else{a={[n]:i};l(e,a)}return a}if(e.shift){n=this.shiftedMarkup?.[e.shift]?.[r];e.shift=null}else{n=this.markup?.[r]}if(n===undefined){if(this.markupCatchAll===undefined){return""}n=this.markupCatchAll}e.hasMarkup=true;if(typeof n==="function"){a=n(e.markupStack,r)}else{a=n;l(e,a)}return a}function l(t,r){if(Array.isArray(r)){for(let e of r){if(e===null){t.markupStack.length=0}else{t.markupStack.push(e)}}}else{if(r===null){t.markupStack.length=0}else{t.markupStack.push(r)}}}B.stripMarkup=e=>e.replace(/\^\[[^\]]*]?|\^./g,e=>e==="^^"?"^":e==="^ "?" ":"");B.escapeMarkup=e=>e.replace(/\^/g,"^^");const r={argumentSanitizer:e=>t.control(e,true),extraArguments:true,color:false,noMarkup:false,escapeMarkup:false,endingMarkupReset:true,startingMarkupReset:false,markupReset:o.reset,shiftMarkup:{"#":"background"},markup:{":":o.reset," ":o.reset+" ","-":o.dim,"+":o.bold,_:o.underline,"/":o.italic,"!":o.inverse,b:o.blue,B:o.brightBlue,c:o.cyan,C:o.brightCyan,g:o.green,G:o.brightGreen,k:o.black,K:o.brightBlack,m:o.magenta,M:o.brightMagenta,r:o.red,R:o.brightRed,w:o.white,W:o.brightWhite,y:o.yellow,Y:o.brightYellow},shiftedMarkup:{background:{":":o.reset," ":o.reset+" ",b:o.bgBlue,B:o.bgBrightBlue,c:o.bgCyan,C:o.bgBrightCyan,g:o.bgGreen,G:o.bgBrightGreen,k:o.bgBlack,K:o.bgBrightBlack,m:o.bgMagenta,M:o.bgBrightMagenta,r:o.bgRed,R:o.bgBrightRed,w:o.bgWhite,W:o.bgBrightWhite,y:o.bgYellow,Y:o.bgBrightYellow}},dataMarkup:{fg:(e,t,r)=>{var n=o.fgColor[r]||o.trueColor(r);e.push(n);return n},bg:(e,t,r)=>{var n=o.bgColor[r]||o.bgTrueColor(r);e.push(n);return n}},markupCatchAll:(e,t,r)=>{var n="";if(r===undefined){if(t[0]==="#"){n=o.trueColor(t)}else if(typeof o[t]==="string"){n=o[t]}}e.push(n);return n}};r.dataMarkup.color=r.dataMarkup.c=r.dataMarkup.fgColor=r.dataMarkup.fg;r.dataMarkup.bgColor=r.dataMarkup.bg;B.createFormatter=e=>B.formatMethod.bind(Object.assign({},r,e));B.format=B.formatMethod.bind(r);B.format.default=r;B.formatNoMarkup=B.formatMethod.bind(Object.assign({},r,{noMarkup:true}));B.formatThirdPartyMarkup=B.formatMethod.bind(Object.assign({},r,{noMarkup:true,escapeMarkup:true}));B.createMarkup=e=>B.markupMethod.bind(Object.assign({},r,e));B.markup=B.markupMethod.bind(r);B.format.count=function(e,t=false){var r,n,o,i=1,a=0;if(typeof e!=="string"){return 0}var s=t?/%([+-]?)([0-9]*)(?:\[[^\]]*\])?[a-zA-EG-Z]/g:/%([+-]?)([0-9]*)(?:\[[^\]]*\])?[a-zA-EG-Z]|(\^\[[^\]]*]?|\^.)/g;for([,o,n,r]of e.matchAll(s)){if(r){continue}if(n){n=parseInt(n,10);if(o){if(o==="+"){n=i+n}else if(o==="-"){n=i-n}}}else{n=i}i++;if(a<n){a=n}}return a};B.format.hasFormatting=function(e){if(e.search(/\^(.?)|(%%)|%([+-]?)([0-9]*)(?:\[([^\]]*)\])?([a-zA-Z])/)!==-1){return true}return false};const S={};B.format.modes=S;S.s=(e,t)=>{var r=w(t);if(typeof e==="string"){return e}if(e===null||e===undefined||e===false){return r.empty?"":"("+e+")"}if(e===true){return"("+e+")"}if(typeof e==="number"){return""+e}if(typeof e.toString==="function"){return e.toString()}return"("+e+")"};S.r=e=>S.s(e);S.r.noSanitize=true;S.S=(e,t,r)=>{var n=w(t);var o=r.escapeMarkup?e=>r.argumentSanitizer?r.argumentSanitizer(e):e:e=>B.markupMethod.call(r,r.argumentSanitizer?r.argumentSanitizer(e):e);if(typeof e==="string"){return o(e)}if(e===null||e===undefined||e===false){return n.empty?"":"("+e+")"}if(e===true){return"("+e+")"}if(typeof e==="number"){return""+e}if(typeof e.toString==="function"){return o(e.toString())}return o("("+e+")")};S.S.noSanitize=true;S.S.noEscapeMarkup=true;S.S.noCommonModeArg=true;S.N=(e,t)=>C(e,t,false);S.n=(e,t)=>C(e,t,true);S.f=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){e=0}var r=b(t),n=new d(e,{decimalSeparator:".",groupSeparator:r.groupSeparator});if(r.rounding!==null){n.round(r.rounding)}if(r.precision){n.precision(r.precision)}return n.toString(r.leftPadding,r.rightPadding,r.rightPaddingOnlyIfDecimal)};S.f.noSanitize=true;S.v=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){e=0}var r=b(t),n=d.additiveRoman(e,{decimalSeparator:".",groupSeparator:r.groupSeparator});if(r.rounding!==null){n.round(r.rounding)}if(r.precision){n.precision(r.precision)}return n.toString(r.leftPadding,r.rightPadding,r.rightPaddingOnlyIfDecimal)};S.v.noSanitize=true;S.V=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){e=0}var r=b(t),n=d.roman(e,{decimalSeparator:".",groupSeparator:r.groupSeparator});if(r.rounding!==null){n.round(r.rounding)}if(r.precision){n.precision(r.precision)}return n.toString(r.leftPadding,r.rightPadding,r.rightPaddingOnlyIfDecimal)};S.V.noSanitize=true;S.P=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){e=0}e*=100;var r=b(t),n=new d(e,{decimalSeparator:".",groupSeparator:r.groupSeparator});if(r.rounding!==null||!r.precision){n.round(r.rounding||0)}if(r.precision){n.precision(r.precision)}return n.toNoExpString(r.leftPadding,r.rightPadding,r.rightPaddingOnlyIfDecimal)+"%"};S.P.noSanitize=true;S.p=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){e=0}e=(e-1)*100;var r=b(t),n=new d(e,{decimalSeparator:".",groupSeparator:r.groupSeparator});if(r.rounding!==null||!r.precision){n.round(r.rounding||0)}if(r.precision){n.precision(r.precision)}return n.toNoExpString(r.leftPadding,r.rightPadding,r.rightPaddingOnlyIfDecimal,true)+"%"};S.p.noSanitize=true;S.k=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){return"0"}var r=b(t),n=new d(e,{decimalSeparator:".",groupSeparator:r.groupSeparator});if(r.rounding!==null){n.round(r.rounding)}if(r.precision||r.rounding===null){n.precision(r.precision||3)}return n.toMetricString(r.leftPadding,r.rightPadding,r.rightPaddingOnlyIfDecimal)};S.k.noSanitize=true;S.e=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){e=0}var r=b(t),n=new d(e,{decimalSeparator:".",groupSeparator:r.groupSeparator});if(r.rounding!==null){n.round(r.rounding)}if(r.precision){n.precision(r.precision)}return n.toExponential()};S.e.noSanitize=true;S.K=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){e=0}var r=b(t),n=new d(e,{decimalSeparator:".",groupSeparator:r.groupSeparator});if(r.rounding!==null){n.round(r.rounding)}if(r.precision){n.precision(r.precision)}return n.toScientific()};S.K.noSanitize=true;S.d=S.i=e=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e==="number"){return""+Math.floor(e)}return"0"};S.i.noSanitize=true;S.u=e=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e==="number"){return""+Math.max(Math.floor(e),0)}return"0"};S.u.noSanitize=true;S.U=e=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e==="number"){return""+Math.max(Math.floor(e),1)}return"1"};S.U.noSanitize=true;S.m=e=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){return"(NaN)"}var t="";if(e<0){t="-";e=-e}var r=L(e),n=e-r;if(!n){return t+r+"°"}var o=L(n*60),i=L(n*3600-o*60);if(i){return t+r+"°"+(""+o).padStart(2,"0")+"′"+(""+i).padStart(2,"0")+"″"}return t+r+"°"+(""+o).padStart(2,"0")+"′"};S.m.noSanitize=true;S.T=(e,t)=>{try{e=new Date(e)}catch(e){return"(invalid)"}if(Number.isNaN(e.getTime())){return"(invalid)"}var r="",n="",o="",i=E(t),a=i.roundingType,s=i.useAbbreviation;if(i.years){if(r){r+="-"}r+=e.getFullYear()}if(i.months){if(r){r+="-"}r+=(""+(e.getMonth()+1)).padStart(2,"0")}if(i.days){if(r){r+="-"}r+=(""+e.getDate()).padStart(2,"0")}if(i.hours){if(n&&!i.useAbbreviation){n+=":"}n+=(""+e.getHours()).padStart(2,"0");if(i.useAbbreviation){n+="h"}}if(i.minutes){if(n&&!i.useAbbreviation){n+=":"}n+=(""+e.getMinutes()).padStart(2,"0");if(i.useAbbreviation){n+="min"}}if(i.seconds){if(n&&!i.useAbbreviation){n+=":"}n+=(""+e.getSeconds()).padStart(2,"0");if(i.useAbbreviation){n+="s"}}if(r){if(o){o+=" "}o+=r}if(n){if(o){o+=" "}o+=n}return o};S.T.noSanitize=true;S.t=(e,t)=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){return"(NaN)"}var r,n,o,i,a,s="",l=A(t),f=l.roundingType,u=l.useAbbreviation?"h":":",c=l.useAbbreviation?"min":":",h=l.useAbbreviation?"s":".",p=l.useAbbreviation;o=e/1e3;if(o<0){o=-o;f*=-1;s="-"}if(o<60&&!l.forceMinutes){i=new d(o,{decimalSeparator:h,forceDecimalSeparator:p});i.round(l.rounding,f);if(i.toNumber()<60){a=i.toString(1,l.rightPadding,l.rightPaddingOnlyIfDecimal);return s+a}o=60}n=Math.floor(o/60);o=o%60;i=new d(o,{decimalSeparator:h,forceDecimalSeparator:p});i.round(l.rounding,f);if(i.toNumber()<60){a=i.toString(2,l.rightPadding,l.rightPaddingOnlyIfDecimal)}else{n++;o=0;i.set(o);a=i.toString(2,l.rightPadding,l.rightPaddingOnlyIfDecimal)}if(n<60&&!l.forceHours){return s+n+c+a}r=Math.floor(n/60);n=n%60;return s+r+u+(""+n).padStart(2,"0")+c+a};S.t.noSanitize=true;S.h=e=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e==="number"){return""+Math.max(Math.floor(e),0).toString(16)}return"0"};S.h.noSanitize=true;S.x=e=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e!=="number"){return"00"}var t=""+Math.max(Math.floor(e),0).toString(16);if(t.length%2){t="0"+t}return t};S.x.noSanitize=true;S.o=e=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e==="number"){return""+Math.max(Math.floor(e),0).toString(8)}return"0"};S.o.noSanitize=true;S.b=e=>{if(typeof e==="string"){e=parseFloat(e)}if(typeof e==="number"){return""+Math.max(Math.floor(e),0).toString(2)}return"0"};S.b.noSanitize=true;S.X=e=>{if(typeof e==="string"){e=T.from(e)}else if(!T.isBuffer(e)){return""}return e.toString("hex")};S.X.noSanitize=true;S.z=e=>{if(typeof e==="string"){e=T.from(e)}else if(!T.isBuffer(e)){return""}return e.toString("base64")};S.Z=e=>{if(typeof e==="string"){e=T.from(e)}else if(!T.isBuffer(e)){return""}return e.toString("base64").replace(/\+/g,"-").replace(/\//g,"_").replace(/[=]{1,2}$/g,"")};const n={};S.I=(e,t,r)=>P(e,t,r,n);S.I.noSanitize=true;const s={noFunc:true,enumOnly:true,noDescriptor:true,useInspect:true,useInspectPropertyBlackList:true};S.Y=(e,t,r)=>P(e,t,r,s);S.Y.noSanitize=true;const c={minimal:true,bulletIndex:true,noMarkup:true};S.O=(e,t,r)=>P(e,t,r,c);S.O.noSanitize=true;const h={};S.E=(e,t,r)=>P(e,t,r,h,true);S.E.noSanitize=true;S.J=e=>e===undefined?"null":JSON.stringify(e);S.D=()=>"";S.D.noSanitize=true;const p=/([a-zA-Z])(.[^a-zA-Z]*)/g;const y=/([a-zA-Z]|^)([^a-zA-Z]*)/g;function v(r,n){for(let[,e,t]of n.matchAll(p)){if(e==="L"){let e=i.width(r);t=+t||1;if(e>t){r=i.truncateWidth(r,t-1).trim()+"…";e=i.width(r)}if(e<t){r=" ".repeat(t-e)+r}}else if(e==="R"){let e=i.width(r);t=+t||1;if(e>t){r=i.truncateWidth(r,t-1).trim()+"…";e=i.width(r)}if(e<t){r=r+" ".repeat(t-e)}}}return r}const g={leftPadding:1,rightPadding:0,rightPaddingOnlyIfDecimal:false,rounding:null,precision:null,groupSeparator:""};function b(r){g.leftPadding=1;g.rightPadding=0;g.rightPaddingOnlyIfDecimal=false;g.rounding=null;g.precision=null;g.groupSeparator="";if(r){for(let[,e,t]of r.matchAll(y)){if(e==="z"){g.leftPadding=+t}else if(e==="g"){g.groupSeparator=t||" "}else if(!e){if(t[0]==="."){let e=t[t.length-1];if(e==="!"){g.rounding=g.rightPadding=parseInt(t.slice(1,-1),10)||0}else if(e==="?"){g.rounding=g.rightPadding=parseInt(t.slice(1,-1),10)||0;g.rightPaddingOnlyIfDecimal=true}else{g.rounding=parseInt(t.slice(1),10)||0}}else if(t[t.length-1]==="."){g.rounding=-parseInt(t.slice(0,-1),10)||0}else{g.precision=parseInt(t,10)||null}}}}return g}const m={empty:false};function w(r){m.empty=false;if(r){for(let[,e,t]of r.matchAll(y)){if(e==="e"){m.empty=true}}}return m}const O={useAbbreviation:false,rightPadding:0,rightPaddingOnlyIfDecimal:false,years:true,months:true,days:true,hours:true,minutes:true,seconds:true};function E(r){O.rightPadding=0;O.rightPaddingOnlyIfDecimal=false;O.rounding=0;O.roundingType=-1;O.years=O.months=O.days=false;O.hours=O.minutes=O.seconds=false;O.useAbbreviation=false;var n=false;if(r){for(let[,e,t]of r.matchAll(y)){if(e==="T"){O.years=O.months=O.days=false;O.hours=O.minutes=O.seconds=true;n=true}else if(e==="D"){O.years=O.months=O.days=true;O.hours=O.minutes=O.seconds=false;n=true}else if(e==="Y"){O.years=true;n=true}else if(e==="M"){O.months=true;n=true}else if(e==="d"){O.days=true;n=true}else if(e==="h"){O.hours=true;n=true}else if(e==="m"){O.minutes=true;n=true}else if(e==="s"){O.seconds=true;n=true}else if(e==="r"){O.roundingType=0}else if(e==="f"){O.roundingType=-1}else if(e==="c"){O.roundingType=1}else if(e==="a"){O.useAbbreviation=true}else if(!e){if(t[0]==="."){let e=t[t.length-1];if(e==="!"){O.rounding=O.rightPadding=parseInt(t.slice(1,-1),10)||0}else if(e==="?"){O.rounding=O.rightPadding=parseInt(t.slice(1,-1),10)||0;O.rightPaddingOnlyIfDecimal=true}else{O.rounding=parseInt(t.slice(1),10)||0}}}}}if(!n){O.years=O.months=O.days=true;O.hours=O.minutes=O.seconds=true}return O}const j={useAbbreviation:false,rightPadding:0,rightPaddingOnlyIfDecimal:false,rounding:0,roundingType:-1,forceHours:false,forceMinutes:false};function A(r){j.rightPadding=0;j.rightPaddingOnlyIfDecimal=false;j.rounding=0;j.roundingType=-1;j.useAbbreviation=j.forceHours=j.forceMinutes=false;if(r){for(let[,e,t]of r.matchAll(y)){if(e==="h"){j.forceHours=j.forceMinutes=true}else if(e==="m"){j.forceMinutes=true}else if(e==="r"){j.roundingType=0}else if(e==="f"){j.roundingType=-1}else if(e==="c"){j.roundingType=1}else if(e==="a"){j.useAbbreviation=true}else if(!e){if(t[0]==="."){let e=t[t.length-1];if(e==="!"){j.rounding=j.rightPadding=parseInt(t.slice(1,-1),10)||0}else if(e==="?"){j.rounding=j.rightPadding=parseInt(t.slice(1,-1),10)||0;j.rightPaddingOnlyIfDecimal=true}else{j.rounding=parseInt(t.slice(1),10)||0}}}}}return j}function C(e,r,t){var n=2;if(r){for(let[,e,t]of r.matchAll(y)){if(!e){n=parseInt(t,10)||1}}}return N(e,t,n,0)}function N(e,t,r,n){if(typeof e==="string"){return e}if(e===null||e===undefined||e===true||e===false){return""+e}if(typeof e==="number"){return S.f(e,".3g ")}if(e instanceof Set){e=[...e]}if(Array.isArray(e)){if(n>=r){return"[...]"}e=e.map(e=>N(e,true,r,n+1));if(t){return"["+e.join(",")+"]"}return e.join(", ")}if(T.isBuffer(e)){e=[...e].map(e=>{e=e.toString(16);if(e.length===1){e="0"+e}return e});return"<"+e.join(" ")+">"}var o=Object.getPrototypeOf(e);if(o===null||o===Object.prototype){if(n>=r){return"{...}"}e=Object.entries(e).sort(a).map(e=>e[0]+": "+N(e[1],true,r,n+1));if(t){return"{"+e.join(", ")+"}"}return e.join(", ")}if(typeof e.inspect==="function"){return e.inspect()}if(typeof e.toString==="function"){return e.toString()}return"("+e+")"}function P(e,r,t,n,o=false){var i,a,s=3,l=t&&t.color?"color":"none";if(r){for(let[,e,t]of r.matchAll(y)){if(e==="c"){if(t==="+"){l="color"}else if(t==="-"){l="none"}}else if(e==="i"){l="inline"}else if(e==="l"){i=parseInt(t,10)||undefined}else if(e==="s"){a=parseInt(t,10)||undefined}else if(!e){s=parseInt(t,10)||1}}}if(o){return u(Object.assign({depth:s,style:l,outputMaxLength:i,maxLength:a},n),e)}return f(Object.assign({depth:s,style:l,outputMaxLength:i,maxLength:a},n),e)}const I=1e-10;const M=Math.round(1/I);function x(e){return Math.round(e*M)/M}function L(e){return Math.floor(e+I)}function e(e,t){return x(t*Math.round(e*(1/t)))}}).call(this)}).call(this,D("buffer").Buffer)},{"./StringNumber.js":15,"./ansi.js":16,"./escape.js":17,"./inspect.js":19,"./naturalSort.js":23,"./unicode.js":25,buffer:28}],19:[function(t,e,r){(function(N,c){(function(){"use strict";const v=t("./escape.js");const o=t("./ansi.js");const O={};const E=new Set([Object,Array]);function a(e,t){if(arguments.length<2){t=e;e={}}else if(!e||typeof e!=="object"){e={}}var r={depth:0,ancestors:[]};if(!e.style){e.style=u.none}else if(typeof e.style==="string"){e.style=u[e.style]}if(e.depth===undefined){e.depth=3}if(e.maxLength===undefined){e.maxLength=250}if(e.outputMaxLength===undefined){e.outputMaxLength=5e3}if(e.nofunc){e.noFunc=true}if(e.minimal){e.noFunc=true;e.noDescriptor=true;e.noType=true;e.noArrayProperty=true;e.enumOnly=true;e.proto=false;e.funcDetails=false}if(e.minimalPlusConstructor){e.noFunc=true;e.noDescriptor=true;e.noTypeButConstructor=true;e.noArrayProperty=true;e.enumOnly=true;e.proto=false;e.funcDetails=false}var n=j(r,e,t);if(n.length>e.outputMaxLength){n=e.style.truncate(n,e.outputMaxLength)}return n}r.inspect=a;function j(t,r,e){var n,o,i,a,s,l,f,u,c,h,p,d,y,g="",b="",m="",w="",k,S;c=typeof e;if(t.depth){w=(r.tab??r.style.tab).repeat(r.noMarkup?t.depth-1:t.depth)}if(c==="function"&&r.noFunc){return""}if(t.key!==undefined){if(t.descriptor){m=[];if(t.descriptor.error){m="["+t.descriptor.error+"]"}else{if(!t.descriptor.configurable){m.push("-conf")}if(!t.descriptor.enumerable){m.push("-enum")}if(!t.descriptor.writable){m.push("-w")}if(m.length){m=m.join(" ")}else{m=""}}}if(t.keyIsProperty){if(!r.noMarkup&&A(t.key)){b='"'+r.style.key(t.key)+'": '}else{b=r.style.key(t.key)+": "}}else if(r.bulletIndex){b=(typeof r.bulletIndex==="string"?r.bulletIndex:"*")+" "}else if(!r.noIndex){b=r.style.index(t.key)}if(m){m=" "+r.style.type(m)}}h=t.noPre?"":w+b;if(e===undefined){g+=h+r.style.constant("undefined")+m+r.style.newline}else if(e===O){g+=h+r.style.constant("[empty]")+m+r.style.newline}else if(e===null){g+=h+r.style.constant("null")+m+r.style.newline}else if(e===false){g+=h+r.style.constant("false")+m+r.style.newline}else if(e===true){g+=h+r.style.constant("true")+m+r.style.newline}else if(c==="number"){g+=h+r.style.number(e.toString())+(r.noType||r.noTypeButConstructor?"":" "+r.style.type("number"))+m+r.style.newline}else if(c==="string"){if(e.length>r.maxLength){g+=h+(r.noMarkup?"":'"')+r.style.string(v.control(e.slice(0,r.maxLength-1)))+"…"+(r.noMarkup?"":'"')+(r.noType||r.noTypeButConstructor?"":" "+r.style.type("string")+r.style.length("("+e.length+" - TRUNCATED)"))+m+r.style.newline}else{g+=h+(r.noMarkup?"":'"')+r.style.string(v.control(e))+(r.noMarkup?"":'"')+(r.noType||r.noTypeButConstructor?"":" "+r.style.type("string")+r.style.length("("+e.length+")"))+m+r.style.newline}}else if(N.isBuffer(e)){g+=h+r.style.inspect(e.inspect())+(r.noType?"":" "+r.style.type("Buffer")+r.style.length("("+e.length+")"))+m+r.style.newline}else if(c==="object"||c==="function"){o=i="";d=false;if(c==="function"){d=true;o=" "+r.style.funcName(e.name?e.name:"(anonymous)");i=r.style.length("("+e.length+")")}p=false;if(Array.isArray(e)){p=true;i=r.style.length("("+e.length+")")}if(!e.constructor){f="(no constructor)"}else if(!e.constructor.name){f="(anonymous)"}else{f=e.constructor.name}l=!e.constructor||E.has(e.constructor);f=r.style.constructorName(f);a=Object.getPrototypeOf(e);g+=h;if(!r.noType&&(!r.noTypeButConstructor||!l)){if(t.forceType&&!r.noType&&!r.noTypeButConstructor){g+=r.style.type(t.forceType)}else if(r.noTypeButConstructor){g+=f}else{g+=f+o+i+" "+r.style.type(c)+m}if(!d||r.funcDetails){g+=" "}}if(p&&r.noArrayProperty){s=[...Array(e.length).keys()]}else{s=Object.getOwnPropertyNames(e)}if(r.sort){s.sort()}y=C(e,t,r);if(r.protoBlackList&&r.protoBlackList.has(a)){g+=r.style.limit("[skip]")+r.style.newline}else if(y!==undefined){if(typeof y==="string"){g+="=> "+y+r.style.newline}else{g+="=> "+j({depth:t.depth,ancestors:t.ancestors,noPre:true},r,y)}}else if(d&&!r.funcDetails){g+=r.style.newline}else if(!s.length&&!r.proto){g+=(r.noMarkup?"":p?"[]":"{}")+r.style.newline}else if(t.depth>=r.depth){g+=r.style.limit("[depth limit]")+r.style.newline}else if(t.ancestors.indexOf(e)!==-1){g+=r.style.limit("[circular]")+r.style.newline}else{g+=(r.noMarkup?"":p?"[":"{")+r.style.newline;S=t.ancestors.slice();S.push(e);for(n=0;n<s.length&&g.length<r.outputMaxLength;n++){if(!p&&(r.propertyBlackList&&r.propertyBlackList.has(s[n])||r.useInspectPropertyBlackList&&e.inspectPropertyBlackList instanceof Set&&e.inspectPropertyBlackList.has(s[n]))){continue}if(p&&r.noArrayProperty&&!(s[n]in e)){g+=j({depth:t.depth+1,ancestors:S,key:s[n],keyIsProperty:false},r,O)}else{try{k=Object.getOwnPropertyDescriptor(e,s[n]);if(k&&!k.enumerable&&r.enumOnly){continue}u=!p||!k.enumerable||isNaN(s[n]);if(!r.noDescriptor&&k&&(k.get||k.set)){g+=j({depth:t.depth+1,ancestors:S,key:s[n],keyIsProperty:u,descriptor:k,forceType:"getter/setter"},r,{get:k.get,set:k.set})}else{g+=j({depth:t.depth+1,ancestors:S,key:s[n],keyIsProperty:u,descriptor:r.noDescriptor?undefined:k||{error:"Bad Proxy Descriptor"}},r,e[s[n]])}}catch(e){g+=j({depth:t.depth+1,ancestors:S,key:s[n],keyIsProperty:u,descriptor:r.noDescriptor?undefined:k},r,e)}}if(n<s.length-1){g+=r.style.comma}}if(r.proto){g+=j({depth:t.depth+1,ancestors:S,key:"__proto__",keyIsProperty:true},r,a)}g+=r.noMarkup?"":w+(p?"]":"}")+r.style.newline}}if(t.depth===0){if(r.style.trim){g=g.trim()}if(r.style==="html"){g=v.html(g)}}return g}function A(e){if(!e.length){return true}return false}var s=["pending","fulfilled","rejected"];function C(n,o,i){if(typeof n.constructor!=="function"){return}if(n instanceof String){return n.toString()}if(n instanceof RegExp){return n.toString()}if(n instanceof Date){return n.toString()+" ["+n.getTime()+"]"}if(typeof Set==="function"&&n instanceof Set){return Array.from(n)}if(typeof Map==="function"&&n instanceof Map){return Array.from(n)}if(n instanceof Promise){if(c&&c.binding&&c.binding("util")&&c.binding("util").getPromiseDetails){let e=c.binding("util").getPromiseDetails(n);let t=s[e[0]];let r="Promise <"+t+">";if(t==="fulfilled"){r+=" "+j({depth:o.depth,ancestors:o.ancestors,noPre:true},i,e[1])}else if(t==="rejected"){if(e[1]instanceof Error){r+=" "+l({style:i.style,noErrorStack:true},e[1])}else{r+=" "+j({depth:o.depth,ancestors:o.ancestors,noPre:true},i,e[1])}}return r}}if(n._bsontype){return n.toString()}if(i.useInspect&&typeof n.inspect==="function"){return n.inspect()}return}function l(t,r){var n="",e,o,i;if(arguments.length<2){r=t;t={}}else if(!t||typeof t!=="object"){t={}}if(!t.style){t.style=u.none}else if(typeof t.style==="string"){t.style=u[t.style]}if(!(r instanceof Error)){n+="[not an Error] ";if(typeof r==="string"){let e=5e3;if(r.length>e){n+=t.style.errorMessage(v.control(r.slice(0,e-1),true))+"…"+t.style.length("("+r.length+" - TRUNCATED)")+t.style.newline}else{n+=t.style.errorMessage(v.control(r,true))+t.style.newline}return n}else if(!r||typeof r!=="object"||!r.name||typeof r.name!=="string"||!r.message||typeof r.message!=="string"){n+=a(t,r);return n}}if(r.stack&&!t.noErrorStack){e=f(t,r.stack)}o=r.type||r.constructor.name;i=r.code||r.name||r.errno||r.number;n+=t.style.errorType(o)+(i?" ["+t.style.errorType(i)+"]":"")+": ";n+=t.style.errorMessage(r.message)+"\n";if(e){n+=t.style.errorStack(e)+"\n"}if(r.from){n+=t.style.newline+t.style.errorFromMessage("From error:")+t.style.newline+l(t,r.from)}return n}r.inspectError=l;function f(l,e){if(arguments.length<2){e=l;l={}}else if(!l||typeof l!=="object"){l={}}if(!l.style){l.style=u.none}else if(typeof l.style==="string"){l.style=u[l.style]}if(!e){return}if((l.browser||c.browser)&&e.indexOf("@")!==-1){e=e.replace(/[</]*(?=@)/g,"").replace(/^\s*([^@]*)\s*@\s*([^\n]*)(?::([0-9]+):([0-9]+))?$/gm,(e,t,r,n,o)=>{return l.style.errorStack("    at ")+(t?l.style.errorStackMethod(t)+" ":"")+l.style.errorStack("(")+(r?l.style.errorStackFile(r):l.style.errorStack("unknown"))+(n?l.style.errorStack(":")+l.style.errorStackLine(n):"")+(o?l.style.errorStack(":")+l.style.errorStackColumn(o):"")+l.style.errorStack(")")})}else{e=e.replace(/^[^\n]*\n/,"");e=e.replace(/^\s*(at)\s+(?:(?:(async|new)\s+)?([^\s:()[\]\n]+(?:\([^)]+\))?)\s)?(?:\[as ([^\s:()[\]\n]+)\]\s)?(?:\(?([^:()[\]\n]+):([0-9]+):([0-9]+)\)?)?$/gm,(e,t,r,n,o,i,a,s)=>{return l.style.errorStack("    at ")+(r?l.style.errorStackKeyword(r)+" ":"")+(n?l.style.errorStackMethod(n)+" ":"")+(o?l.style.errorStack("[as ")+l.style.errorStackMethodAs(o)+l.style.errorStack("] "):"")+l.style.errorStack("(")+(i?l.style.errorStackFile(i):l.style.errorStack("unknown"))+(a?l.style.errorStack(":")+l.style.errorStackLine(a):"")+(s?l.style.errorStack(":")+l.style.errorStackColumn(s):"")+l.style.errorStack(")")})}return e}r.inspectStack=f;var u={};var e=e=>e;u.none={trim:false,tab:"    ",newline:"\n",comma:"",limit:e,type:e=>"<"+e+">",constant:e,funcName:e,constructorName:e=>"<"+e+">",length:e,key:e,index:e=>"["+e+"] ",number:e,inspect:e,string:e,errorType:e,errorMessage:e,errorStack:e,errorStackKeyword:e,errorStackMethod:e,errorStackMethodAs:e,errorStackFile:e,errorStackLine:e,errorStackColumn:e,errorFromMessage:e,truncate:(e,t)=>e.slice(0,t-1)+"…"};u.inline=Object.assign({},u.none,{trim:true,tab:"",newline:" ",comma:", ",length:()=>"",index:()=>""});u.color=Object.assign({},u.none,{limit:e=>o.bold+o.brightRed+e+o.reset,type:e=>o.italic+o.brightBlack+e+o.reset,constant:e=>o.cyan+e+o.reset,funcName:e=>o.italic+o.magenta+e+o.reset,constructorName:e=>o.magenta+e+o.reset,length:e=>o.italic+o.brightBlack+e+o.reset,key:e=>o.green+e+o.reset,index:e=>o.blue+"["+e+"]"+o.reset+" ",number:e=>o.cyan+e+o.reset,inspect:e=>o.cyan+e+o.reset,string:e=>o.blue+e+o.reset,errorType:e=>o.red+o.bold+e+o.reset,errorMessage:e=>o.red+o.italic+e+o.reset,errorStack:e=>o.brightBlack+e+o.reset,errorStackKeyword:e=>o.italic+o.bold+e+o.reset,errorStackMethod:e=>o.brightYellow+e+o.reset,errorStackMethodAs:e=>o.yellow+e+o.reset,errorStackFile:e=>o.brightCyan+e+o.reset,errorStackLine:e=>o.blue+e+o.reset,errorStackColumn:e=>o.magenta+e+o.reset,errorFromMessage:e=>o.yellow+o.underline+e+o.reset,truncate:(e,t)=>{var r=o.gray+"…"+o.reset;e=e.slice(0,t-r.length);var n=e.lastIndexOf("");if(n>=e.length-6){e=e.slice(0,n)}return e+r}});u.html=Object.assign({},u.none,{tab:"&nbsp;&nbsp;&nbsp;&nbsp;",newline:"<br />",limit:e=>'<span style="color:red">'+e+"</span>",type:e=>'<i style="color:gray">'+e+"</i>",constant:e=>'<span style="color:cyan">'+e+"</span>",funcName:e=>'<i style="color:magenta">'+e+"</i>",constructorName:e=>'<span style="color:magenta">'+e+"</span>",length:e=>'<i style="color:gray">'+e+"</i>",key:e=>'<span style="color:green">'+e+"</span>",index:e=>'<span style="color:blue">['+e+"]</span> ",number:e=>'<span style="color:cyan">'+e+"</span>",inspect:e=>'<span style="color:cyan">'+e+"</span>",string:e=>'<span style="color:blue">'+e+"</span>",errorType:e=>'<span style="color:red">'+e+"</span>",errorMessage:e=>'<span style="color:red">'+e+"</span>",errorStack:e=>'<span style="color:gray">'+e+"</span>",errorStackKeyword:e=>"<i>"+e+"</i>",errorStackMethod:e=>'<span style="color:yellow">'+e+"</span>",errorStackMethodAs:e=>'<span style="color:yellow">'+e+"</span>",errorStackFile:e=>'<span style="color:cyan">'+e+"</span>",errorStackLine:e=>'<span style="color:blue">'+e+"</span>",errorStackColumn:e=>'<span style="color:gray">'+e+"</span>",errorFromMessage:e=>'<span style="color:yellow">'+e+"</span>"})}).call(this)}).call(this,{isBuffer:t("../../../../../../../../opt/node-v22.16.0/lib/node_modules/browserify/node_modules/is-buffer/index.js")},t("_process"))},{"../../../../../../../../opt/node-v22.16.0/lib/node_modules/browserify/node_modules/is-buffer/index.js":29,"./ansi.js":16,"./escape.js":17,_process:30}],20:[function(e,t,r){t.exports={"߀":"0","́":""," ":" ","Ⓐ":"A","A":"A","À":"A","Á":"A","Â":"A","Ầ":"A","Ấ":"A","Ẫ":"A","Ẩ":"A","Ã":"A","Ā":"A","Ă":"A","Ằ":"A","Ắ":"A","Ẵ":"A","Ẳ":"A","Ȧ":"A","Ǡ":"A","Ä":"A","Ǟ":"A","Ả":"A","Å":"A","Ǻ":"A","Ǎ":"A","Ȁ":"A","Ȃ":"A","Ạ":"A","Ậ":"A","Ặ":"A","Ḁ":"A","Ą":"A","Ⱥ":"A","Ɐ":"A","Ꜳ":"AA","Æ":"AE","Ǽ":"AE","Ǣ":"AE","Ꜵ":"AO","Ꜷ":"AU","Ꜹ":"AV","Ꜻ":"AV","Ꜽ":"AY","Ⓑ":"B","B":"B","Ḃ":"B","Ḅ":"B","Ḇ":"B","Ƀ":"B","Ɓ":"B","c":"C","Ⓒ":"C","C":"C","Ꜿ":"C","Ḉ":"C","Ç":"C","Ⓓ":"D","D":"D","Ḋ":"D","Ď":"D","Ḍ":"D","Ḑ":"D","Ḓ":"D","Ḏ":"D","Đ":"D","Ɗ":"D","Ɖ":"D","ᴅ":"D","Ꝺ":"D","Ð":"Dh","DZ":"DZ","DŽ":"DZ","Dz":"Dz","Dž":"Dz","ɛ":"E","Ⓔ":"E","E":"E","È":"E","É":"E","Ê":"E","Ề":"E","Ế":"E","Ễ":"E","Ể":"E","Ẽ":"E","Ē":"E","Ḕ":"E","Ḗ":"E","Ĕ":"E","Ė":"E","Ë":"E","Ẻ":"E","Ě":"E","Ȅ":"E","Ȇ":"E","Ẹ":"E","Ệ":"E","Ȩ":"E","Ḝ":"E","Ę":"E","Ḙ":"E","Ḛ":"E","Ɛ":"E","Ǝ":"E","ᴇ":"E","ꝼ":"F","Ⓕ":"F","F":"F","Ḟ":"F","Ƒ":"F","Ꝼ":"F","Ⓖ":"G","G":"G","Ǵ":"G","Ĝ":"G","Ḡ":"G","Ğ":"G","Ġ":"G","Ǧ":"G","Ģ":"G","Ǥ":"G","Ɠ":"G","Ꞡ":"G","Ᵹ":"G","Ꝿ":"G","ɢ":"G","Ⓗ":"H","H":"H","Ĥ":"H","Ḣ":"H","Ḧ":"H","Ȟ":"H","Ḥ":"H","Ḩ":"H","Ḫ":"H","Ħ":"H","Ⱨ":"H","Ⱶ":"H","Ɥ":"H","Ⓘ":"I","I":"I","Ì":"I","Í":"I","Î":"I","Ĩ":"I","Ī":"I","Ĭ":"I","İ":"I","Ï":"I","Ḯ":"I","Ỉ":"I","Ǐ":"I","Ȉ":"I","Ȋ":"I","Ị":"I","Į":"I","Ḭ":"I","Ɨ":"I","Ⓙ":"J","J":"J","Ĵ":"J","Ɉ":"J","ȷ":"J","Ⓚ":"K","K":"K","Ḱ":"K","Ǩ":"K","Ḳ":"K","Ķ":"K","Ḵ":"K","Ƙ":"K","Ⱪ":"K","Ꝁ":"K","Ꝃ":"K","Ꝅ":"K","Ꞣ":"K","Ⓛ":"L","L":"L","Ŀ":"L","Ĺ":"L","Ľ":"L","Ḷ":"L","Ḹ":"L","Ļ":"L","Ḽ":"L","Ḻ":"L","Ł":"L","Ƚ":"L","Ɫ":"L","Ⱡ":"L","Ꝉ":"L","Ꝇ":"L","Ꞁ":"L","LJ":"LJ","Lj":"Lj","Ⓜ":"M","M":"M","Ḿ":"M","Ṁ":"M","Ṃ":"M","Ɱ":"M","Ɯ":"M","ϻ":"M","Ꞥ":"N","Ƞ":"N","Ⓝ":"N","N":"N","Ǹ":"N","Ń":"N","Ñ":"N","Ṅ":"N","Ň":"N","Ṇ":"N","Ņ":"N","Ṋ":"N","Ṉ":"N","Ɲ":"N","Ꞑ":"N","ᴎ":"N","NJ":"NJ","Nj":"Nj","Ⓞ":"O","O":"O","Ò":"O","Ó":"O","Ô":"O","Ồ":"O","Ố":"O","Ỗ":"O","Ổ":"O","Õ":"O","Ṍ":"O","Ȭ":"O","Ṏ":"O","Ō":"O","Ṑ":"O","Ṓ":"O","Ŏ":"O","Ȯ":"O","Ȱ":"O","Ö":"O","Ȫ":"O","Ỏ":"O","Ő":"O","Ǒ":"O","Ȍ":"O","Ȏ":"O","Ơ":"O","Ờ":"O","Ớ":"O","Ỡ":"O","Ở":"O","Ợ":"O","Ọ":"O","Ộ":"O","Ǫ":"O","Ǭ":"O","Ø":"O","Ǿ":"O","Ɔ":"O","Ɵ":"O","Ꝋ":"O","Ꝍ":"O","Œ":"OE","Ƣ":"OI","Ꝏ":"OO","Ȣ":"OU","Ⓟ":"P","P":"P","Ṕ":"P","Ṗ":"P","Ƥ":"P","Ᵽ":"P","Ꝑ":"P","Ꝓ":"P","Ꝕ":"P","Ⓠ":"Q","Q":"Q","Ꝗ":"Q","Ꝙ":"Q","Ɋ":"Q","Ⓡ":"R","R":"R","Ŕ":"R","Ṙ":"R","Ř":"R","Ȑ":"R","Ȓ":"R","Ṛ":"R","Ṝ":"R","Ŗ":"R","Ṟ":"R","Ɍ":"R","Ɽ":"R","Ꝛ":"R","Ꞧ":"R","Ꞃ":"R","Ⓢ":"S","S":"S","ẞ":"S","Ś":"S","Ṥ":"S","Ŝ":"S","Ṡ":"S","Š":"S","Ṧ":"S","Ṣ":"S","Ṩ":"S","Ș":"S","Ş":"S","Ȿ":"S","Ꞩ":"S","Ꞅ":"S","Ⓣ":"T","T":"T","Ṫ":"T","Ť":"T","Ṭ":"T","Ț":"T","Ţ":"T","Ṱ":"T","Ṯ":"T","Ŧ":"T","Ƭ":"T","Ʈ":"T","Ⱦ":"T","Ꞇ":"T","Þ":"Th","Ꜩ":"TZ","Ⓤ":"U","U":"U","Ù":"U","Ú":"U","Û":"U","Ũ":"U","Ṹ":"U","Ū":"U","Ṻ":"U","Ŭ":"U","Ü":"U","Ǜ":"U","Ǘ":"U","Ǖ":"U","Ǚ":"U","Ủ":"U","Ů":"U","Ű":"U","Ǔ":"U","Ȕ":"U","Ȗ":"U","Ư":"U","Ừ":"U","Ứ":"U","Ữ":"U","Ử":"U","Ự":"U","Ụ":"U","Ṳ":"U","Ų":"U","Ṷ":"U","Ṵ":"U","Ʉ":"U","Ⓥ":"V","V":"V","Ṽ":"V","Ṿ":"V","Ʋ":"V","Ꝟ":"V","Ʌ":"V","Ꝡ":"VY","Ⓦ":"W","W":"W","Ẁ":"W","Ẃ":"W","Ŵ":"W","Ẇ":"W","Ẅ":"W","Ẉ":"W","Ⱳ":"W","Ⓧ":"X","X":"X","Ẋ":"X","Ẍ":"X","Ⓨ":"Y","Y":"Y","Ỳ":"Y","Ý":"Y","Ŷ":"Y","Ỹ":"Y","Ȳ":"Y","Ẏ":"Y","Ÿ":"Y","Ỷ":"Y","Ỵ":"Y","Ƴ":"Y","Ɏ":"Y","Ỿ":"Y","Ⓩ":"Z","Z":"Z","Ź":"Z","Ẑ":"Z","Ż":"Z","Ž":"Z","Ẓ":"Z","Ẕ":"Z","Ƶ":"Z","Ȥ":"Z","Ɀ":"Z","Ⱬ":"Z","Ꝣ":"Z","ⓐ":"a","a":"a","ẚ":"a","à":"a","á":"a","â":"a","ầ":"a","ấ":"a","ẫ":"a","ẩ":"a","ã":"a","ā":"a","ă":"a","ằ":"a","ắ":"a","ẵ":"a","ẳ":"a","ȧ":"a","ǡ":"a","ä":"a","ǟ":"a","ả":"a","å":"a","ǻ":"a","ǎ":"a","ȁ":"a","ȃ":"a","ạ":"a","ậ":"a","ặ":"a","ḁ":"a","ą":"a","ⱥ":"a","ɐ":"a","ɑ":"a","ꜳ":"aa","æ":"ae","ǽ":"ae","ǣ":"ae","ꜵ":"ao","ꜷ":"au","ꜹ":"av","ꜻ":"av","ꜽ":"ay","ⓑ":"b","b":"b","ḃ":"b","ḅ":"b","ḇ":"b","ƀ":"b","ƃ":"b","ɓ":"b","Ƃ":"b","ⓒ":"c","ć":"c","ĉ":"c","ċ":"c","č":"c","ç":"c","ḉ":"c","ƈ":"c","ȼ":"c","ꜿ":"c","ↄ":"c",C:"c","Ć":"c","Ĉ":"c","Ċ":"c","Č":"c","Ƈ":"c","Ȼ":"c","ⓓ":"d","d":"d","ḋ":"d","ď":"d","ḍ":"d","ḑ":"d","ḓ":"d","ḏ":"d","đ":"d","ƌ":"d","ɖ":"d","ɗ":"d","Ƌ":"d","Ꮷ":"d","ԁ":"d","Ɦ":"d","ð":"dh","dz":"dz","dž":"dz","ⓔ":"e","e":"e","è":"e","é":"e","ê":"e","ề":"e","ế":"e","ễ":"e","ể":"e","ẽ":"e","ē":"e","ḕ":"e","ḗ":"e","ĕ":"e","ė":"e","ë":"e","ẻ":"e","ě":"e","ȅ":"e","ȇ":"e","ẹ":"e","ệ":"e","ȩ":"e","ḝ":"e","ę":"e","ḙ":"e","ḛ":"e","ɇ":"e","ǝ":"e","ⓕ":"f","f":"f","ḟ":"f","ƒ":"f","ff":"ff","fi":"fi","fl":"fl","ffi":"ffi","ffl":"ffl","ⓖ":"g","g":"g","ǵ":"g","ĝ":"g","ḡ":"g","ğ":"g","ġ":"g","ǧ":"g","ģ":"g","ǥ":"g","ɠ":"g","ꞡ":"g","ꝿ":"g","ᵹ":"g","ⓗ":"h","h":"h","ĥ":"h","ḣ":"h","ḧ":"h","ȟ":"h","ḥ":"h","ḩ":"h","ḫ":"h","ẖ":"h","ħ":"h","ⱨ":"h","ⱶ":"h","ɥ":"h","ƕ":"hv","ⓘ":"i","i":"i","ì":"i","í":"i","î":"i","ĩ":"i","ī":"i","ĭ":"i","ï":"i","ḯ":"i","ỉ":"i","ǐ":"i","ȉ":"i","ȋ":"i","ị":"i","į":"i","ḭ":"i","ɨ":"i","ı":"i","ⓙ":"j","j":"j","ĵ":"j","ǰ":"j","ɉ":"j","ⓚ":"k","k":"k","ḱ":"k","ǩ":"k","ḳ":"k","ķ":"k","ḵ":"k","ƙ":"k","ⱪ":"k","ꝁ":"k","ꝃ":"k","ꝅ":"k","ꞣ":"k","ⓛ":"l","l":"l","ŀ":"l","ĺ":"l","ľ":"l","ḷ":"l","ḹ":"l","ļ":"l","ḽ":"l","ḻ":"l","ſ":"l","ł":"l","ƚ":"l","ɫ":"l","ⱡ":"l","ꝉ":"l","ꞁ":"l","ꝇ":"l","ɭ":"l","lj":"lj","ⓜ":"m","m":"m","ḿ":"m","ṁ":"m","ṃ":"m","ɱ":"m","ɯ":"m","ⓝ":"n","n":"n","ǹ":"n","ń":"n","ñ":"n","ṅ":"n","ň":"n","ṇ":"n","ņ":"n","ṋ":"n","ṉ":"n","ƞ":"n","ɲ":"n","ʼn":"n","ꞑ":"n","ꞥ":"n","ԉ":"n","nj":"nj","ⓞ":"o","o":"o","ò":"o","ó":"o","ô":"o","ồ":"o","ố":"o","ỗ":"o","ổ":"o","õ":"o","ṍ":"o","ȭ":"o","ṏ":"o","ō":"o","ṑ":"o","ṓ":"o","ŏ":"o","ȯ":"o","ȱ":"o","ö":"o","ȫ":"o","ỏ":"o","ő":"o","ǒ":"o","ȍ":"o","ȏ":"o","ơ":"o","ờ":"o","ớ":"o","ỡ":"o","ở":"o","ợ":"o","ọ":"o","ộ":"o","ǫ":"o","ǭ":"o","ø":"o","ǿ":"o","ꝋ":"o","ꝍ":"o","ɵ":"o","ɔ":"o","ᴑ":"o","œ":"oe","ƣ":"oi","ꝏ":"oo","ȣ":"ou","ⓟ":"p","p":"p","ṕ":"p","ṗ":"p","ƥ":"p","ᵽ":"p","ꝑ":"p","ꝓ":"p","ꝕ":"p","ρ":"p","ⓠ":"q","q":"q","ɋ":"q","ꝗ":"q","ꝙ":"q","ⓡ":"r","r":"r","ŕ":"r","ṙ":"r","ř":"r","ȑ":"r","ȓ":"r","ṛ":"r","ṝ":"r","ŗ":"r","ṟ":"r","ɍ":"r","ɽ":"r","ꝛ":"r","ꞧ":"r","ꞃ":"r","ⓢ":"s","s":"s","ś":"s","ṥ":"s","ŝ":"s","ṡ":"s","š":"s","ṧ":"s","ṣ":"s","ṩ":"s","ș":"s","ş":"s","ȿ":"s","ꞩ":"s","ꞅ":"s","ẛ":"s","ʂ":"s","ß":"ss","ⓣ":"t","t":"t","ṫ":"t","ẗ":"t","ť":"t","ṭ":"t","ț":"t","ţ":"t","ṱ":"t","ṯ":"t","ŧ":"t","ƭ":"t","ʈ":"t","ⱦ":"t","ꞇ":"t","þ":"th","ꜩ":"tz","ⓤ":"u","u":"u","ù":"u","ú":"u","û":"u","ũ":"u","ṹ":"u","ū":"u","ṻ":"u","ŭ":"u","ü":"u","ǜ":"u","ǘ":"u","ǖ":"u","ǚ":"u","ủ":"u","ů":"u","ű":"u","ǔ":"u","ȕ":"u","ȗ":"u","ư":"u","ừ":"u","ứ":"u","ữ":"u","ử":"u","ự":"u","ụ":"u","ṳ":"u","ų":"u","ṷ":"u","ṵ":"u","ʉ":"u","ⓥ":"v","v":"v","ṽ":"v","ṿ":"v","ʋ":"v","ꝟ":"v","ʌ":"v","ꝡ":"vy","ⓦ":"w","w":"w","ẁ":"w","ẃ":"w","ŵ":"w","ẇ":"w","ẅ":"w","ẘ":"w","ẉ":"w","ⱳ":"w","ⓧ":"x","x":"x","ẋ":"x","ẍ":"x","ⓨ":"y","y":"y","ỳ":"y","ý":"y","ŷ":"y","ỹ":"y","ȳ":"y","ẏ":"y","ÿ":"y","ỷ":"y","ẙ":"y","ỵ":"y","ƴ":"y","ɏ":"y","ỿ":"y","ⓩ":"z","z":"z","ź":"z","ẑ":"z","ż":"z","ž":"z","ẓ":"z","ẕ":"z","ƶ":"z","ȥ":"z","ɀ":"z","ⱬ":"z","ꝣ":"z"}},{}],21:[function(e,t,r){t.exports=[{s:9728,e:9747,w:1},{s:9748,e:9749,w:2},{s:9750,e:9799,w:1},{s:9800,e:9811,w:2},{s:9812,e:9854,w:1},{s:9855,e:9855,w:2},{s:9856,e:9874,w:1},{s:9875,e:9875,w:2},{s:9876,e:9888,w:1},{s:9889,e:9889,w:2},{s:9890,e:9897,w:1},{s:9898,e:9899,w:2},{s:9900,e:9916,w:1},{s:9917,e:9918,w:2},{s:9919,e:9923,w:1},{s:9924,e:9925,w:2},{s:9926,e:9933,w:1},{s:9934,e:9934,w:2},{s:9935,e:9939,w:1},{s:9940,e:9940,w:2},{s:9941,e:9961,w:1},{s:9962,e:9962,w:2},{s:9963,e:9969,w:1},{s:9970,e:9971,w:2},{s:9972,e:9972,w:1},{s:9973,e:9973,w:2},{s:9974,e:9977,w:1},{s:9978,e:9978,w:2},{s:9979,e:9980,w:1},{s:9981,e:9981,w:2},{s:9982,e:9983,w:1},{s:9984,e:9988,w:1},{s:9989,e:9989,w:2},{s:9990,e:9993,w:1},{s:9994,e:9995,w:2},{s:9996,e:10023,w:1},{s:10024,e:10024,w:2},{s:10025,e:10059,w:1},{s:10060,e:10060,w:2},{s:10061,e:10061,w:1},{s:10062,e:10062,w:2},{s:10063,e:10066,w:1},{s:10067,e:10069,w:2},{s:10070,e:10070,w:1},{s:10071,e:10071,w:2},{s:10072,e:10132,w:1},{s:10133,e:10135,w:2},{s:10136,e:10159,w:1},{s:10160,e:10160,w:2},{s:10161,e:10174,w:1},{s:10175,e:10175,w:2},{s:126976,e:126979,w:1},{s:126980,e:126980,w:2},{s:126981,e:127182,w:1},{s:127183,e:127183,w:2},{s:127184,e:127373,w:1},{s:127374,e:127374,w:2},{s:127375,e:127376,w:1},{s:127377,e:127386,w:2},{s:127387,e:127487,w:1},{s:127744,e:127776,w:2},{s:127777,e:127788,w:1},{s:127789,e:127797,w:2},{s:127798,e:127798,w:1},{s:127799,e:127868,w:2},{s:127869,e:127869,w:1},{s:127870,e:127891,w:2},{s:127892,e:127903,w:1},{s:127904,e:127946,w:2},{s:127947,e:127950,w:1},{s:127951,e:127955,w:2},{s:127956,e:127967,w:1},{s:127968,e:127984,w:2},{s:127985,e:127987,w:1},{s:127988,e:127988,w:2},{s:127989,e:127991,w:1},{s:127992,e:127994,w:2},{s:128e3,e:128062,w:2},{s:128063,e:128063,w:1},{s:128064,e:128064,w:2},{s:128065,e:128065,w:1},{s:128066,e:128252,w:2},{s:128253,e:128254,w:1},{s:128255,e:128317,w:2},{s:128318,e:128330,w:1},{s:128331,e:128334,w:2},{s:128335,e:128335,w:1},{s:128336,e:128359,w:2},{s:128360,e:128377,w:1},{s:128378,e:128378,w:2},{s:128379,e:128404,w:1},{s:128405,e:128406,w:2},{s:128407,e:128419,w:1},{s:128420,e:128420,w:2},{s:128421,e:128506,w:1},{s:128507,e:128591,w:2},{s:128592,e:128639,w:1},{s:128640,e:128709,w:2},{s:128710,e:128715,w:1},{s:128716,e:128716,w:2},{s:128717,e:128719,w:1},{s:128720,e:128722,w:2},{s:128723,e:128724,w:1},{s:128725,e:128727,w:2},{s:128728,e:128746,w:1},{s:128747,e:128748,w:2},{s:128749,e:128755,w:1},{s:128756,e:128764,w:2},{s:128765,e:128991,w:1},{s:128992,e:129003,w:2},{s:129004,e:129291,w:1},{s:129292,e:129338,w:2},{s:129339,e:129339,w:1},{s:129340,e:129349,w:2},{s:129350,e:129350,w:1},{s:129351,e:129400,w:2},{s:129401,e:129401,w:1},{s:129402,e:129483,w:2},{s:129484,e:129484,w:1},{s:129485,e:129535,w:2},{s:129536,e:129647,w:1},{s:129648,e:129652,w:2},{s:129653,e:129655,w:1},{s:129656,e:129658,w:2},{s:129659,e:129663,w:1},{s:129664,e:129670,w:2},{s:129671,e:129679,w:1},{s:129680,e:129704,w:2},{s:129705,e:129711,w:1},{s:129712,e:129718,w:2},{s:129719,e:129727,w:1},{s:129728,e:129730,w:2},{s:129731,e:129743,w:1},{s:129744,e:129750,w:2},{s:129751,e:129791,w:1}]},{}],22:[function(e,t,r){"use strict";const n=e("./json-data/latinize-map.json");t.exports=function(e){return e.replace(/[^\u0000-\u007e]/g,e=>{return n[e]||e})}},{"./json-data/latinize-map.json":20}],23:[function(e,t,r){"use strict";const S=1;const v=2;const O=3;const E=4;const j=5;function A(e,t){if(C(t)){return v}if(t<=31||t===127){return S}if(N(t)){return E}if(e.toUpperCase()!==e.toLowerCase()){return O}return j}function C(e){if(e===32||e===9||e===160||e===45||e===95){return true}return false}function N(e){if(e>=48&&e<=57){return true}return false}function n(e,t){e=""+e;t=""+t;var r,n,o,i,a,s,l,f=e.trim(),u=f.length,c,h,p,d,y,g,b,m=t.trim(),w=m.length,k=0;for(r=c=0;r<u&&c<w;r++,c++){o=f[r];p=m[c];i=f.charCodeAt(r);d=m.charCodeAt(c);a=A(o,i);y=A(p,d);if(a!==y){return a-y}switch(a){case v:while(C(f.charCodeAt(r+1))){r++}while(C(m.charCodeAt(c+1))){c++}break;case S:case j:if(i!==d){return i-d}break;case O:s=o.toLowerCase();g=p.toLowerCase();if(s!==g){return s>g?1:-1}if(!k&&o!==p){k=o!==s?-1:1}break;case E:n=r+1;while(N(f.charCodeAt(n))){n++}l=parseFloat(f.slice(r,n));h=c+1;while(N(m.charCodeAt(h))){h++}b=parseFloat(m.slice(c,h));if(l!==b){return l-b}if(!k&&n-r!==h-c){k=n-r-(h-c)}r=n-1;c=h-1;break}}if(k){return k}return u-r-(w-c)||u-w||e.length-t.length}t.exports=n},{}],24:[function(e,t,r){"use strict";const s={underscoreToSpace:true,lowerCaseWords:new Set(["a","an","the","for","and","nor","but","or","yet","so","of","on","off","in","into","by","with","to","at","up","down","as"])};t.exports=(r,e=s)=>{if(!r||typeof r!=="string"){return""}var t=e.dashToSpace??s.dashToSpace,n=e.underscoreToSpace??s.underscoreToSpace,o=e.zealous??s.zealous,i=e.preserveAllCaps??s.preserveAllCaps,a=e.lowerCaseWords??s.lowerCaseWords;a=a instanceof Set?a:Array.isArray(a)?new Set(a):null;if(t){r=r.replace(/-+/g," ")}if(n){r=r.replace(/_+/g," ")}r=r.replace(/ +/g," ").trim();return r.replace(/[^\s_-]+/g,(t,e)=>{if(a&&e&&e+t.length<r.length){let e=t.toLowerCase();if(a.has(e)){return e}}if(o){if(i&&t===t.toUpperCase()){return t}return t[0].toUpperCase()+t.slice(1).toLowerCase()}return t[0].toUpperCase()+t.slice(1)})}},{}],25:[function(t,e,r){"use strict";const u={};e.exports=u;u.encode=e=>String.fromCodePoint(...e);u.decode=e=>Array.from(e,e=>e.codePointAt(0));u.firstCodePoint=e=>e.codePointAt(0);u.firstChar=e=>e.length?String.fromCodePoint(e.codePointAt(0)):undefined;u.toArray=e=>Array.from(e);u.toCells=(e,t,r=4,n=0,...o)=>{var i,a,s,l,f=[];for(i of t){a=i.codePointAt(0);if(a===10){n=0}else if(a===9){s=r-n%r-1;f.push(new e("\t",1,...o));n+=1+s;while(s--){f.push(new e(" ",-2,...o))}}else{l=u.codePointWidth(a),f.push(new e(i,l,...o));n+=l;while(--l>0){f.push(new e(" ",-1,...o))}}}return f};u.fromCells=e=>{var t,r="";for(t of e){if(!t.filler){r+=t.char}}return r};u.length=e=>{var t,r=0;for(t of e){r++}return r};u.truncateLength=u.truncate=(t,r)=>{var n=0,o=0;for(let e of t){if(o===r){return t.slice(0,n)}o++;n+=e.length}return t};u.width=e=>{var t,r=0;for(t of e){r+=u.codePointWidth(t.codePointAt(0))}return r};u.arrayWidth=(e,t)=>{var r,n=0;if(t===undefined){t=e.length}for(r=0;r<t;r++){n+=u.isFullWidth(e[r])?2:1}return n};var i=0;u.getLastTruncateWidth=()=>i;u.widthLimit=u.truncateWidth=(e,t)=>{var r,n,o=0;i=0;for(r of e){n=u.codePointWidth(r.codePointAt(0));if(i+n>t){return e.slice(0,o)}i+=n;o+=r.length}return e};u.surrogatePair=e=>{var t=e.charCodeAt(0);if(t<55296||t>=57344){return 0}else if(t<56320){return 1}return-1};u.isFullWidth=e=>u.isFullWidthCodePoint(e.codePointAt(0));u.charWidth=e=>u.codePointWidth(e.codePointAt(0));const n=new Map;(function(){var e=t("./json-data/unicode-emoji-width-ranges.json");for(let t of e){for(let e=t.s;e<=t.e;e++){n.set(e,t.w)}}})();u.codePointWidth=e=>{if(u.isEmojiCodePoint(e)){return n.get(e)??2}if(e>=4352&&(e<=4447||e===9001||e===9002||11904<=e&&e<=12871&&e!==12351||12880<=e&&e<=19903||19968<=e&&e<=42182||43360<=e&&e<=43388||44032<=e&&e<=55203||63744<=e&&e<=64255||65040<=e&&e<=65049||65072<=e&&e<=65131||65281<=e&&e<=65376||65504<=e&&e<=65510||110592<=e&&e<=110593||127488<=e&&e<=127569||131072<=e&&e<=262141)){return 2}if(u.isEmojiModifierCodePoint(e)||u.isZeroWidthDiacriticCodePoint(e)){return 0}return 1};u.isFullWidthCodePoint=e=>u.codePointWidth(e)===2;u.toFullWidth=e=>{return String.fromCodePoint(...Array.from(e,e=>{var t=e.codePointAt(0);return t>=33&&t<=126?65280+t-32:t}))};u.isZeroWidthDiacritic=e=>u.isZeroWidthDiacriticCodePoint(e.codePointAt(0));u.isZeroWidthDiacriticCodePoint=e=>768<=e&&e<=879||6832<=e&&e<=6911||7616<=e&&e<=7679||8400<=e&&e<=8447||65056<=e&&e<=65071||e===12441||e===12442||2304<=e&&e<=2307||2362<=e&&e<=2391&&e!==2365&&e!==2384||e===2402||e===2403||e===3633||3636<=e&&e<=3642||3655<=e&&e<=3662;u.isEmoji=e=>u.isEmojiCodePoint(e.codePointAt(0));u.isEmojiCodePoint=e=>9728<=e&&e<=9983||9984<=e&&e<=10175||126976<=e&&e<=127487||127744<=e&&e<=127994||128e3<=e&&e<=129791;u.isEmojiModifier=e=>u.isEmojiModifierCodePoint(e.codePointAt(0));u.isEmojiModifierCodePoint=e=>127995<=e&&e<=127999||e===65039},{"./json-data/unicode-emoji-width-ranges.json":21}],26:[function(e,t,r){"use strict";function h(e,t){var r=Object.getPrototypeOf(e);if(h.opaque.has(r)){return h.opaque.get(r)(e)}var n,o,i,a,s,l,f=[{source:e,target:Array.isArray(e)?[]:Object.create(r)}],u=f[0].target,c=new Map;c.set(e,u);while(a=f.shift()){i=Object.getOwnPropertyNames(a.source);for(n=0;n<i.length;n++){o=Object.getOwnPropertyDescriptor(a.source,i[n]);if(!o.value||typeof o.value!=="object"){Object.defineProperty(a.target,i[n],o);continue}s=o.value;if(t){if(c.has(s)){o.value=c.get(s);Object.defineProperty(a.target,i[n],o);continue}}l=Object.getPrototypeOf(o.value);if(h.opaque.has(l)){o.value=h.opaque.get(l)(o.value);Object.defineProperty(a.target,i[n],o);continue}o.value=Array.isArray(s)?[]:Object.create(l);if(t){c.set(s,o.value)}Object.defineProperty(a.target,i[n],o);f.push({source:s,target:o.value})}}return u}t.exports=h;h.opaque=new Map;h.opaque.set(Date.prototype,e=>new Date(e))},{}],27:[function(e,t,r){"use strict";const n={};t.exports=n;const o=[];const s="This would cause prototype pollution";function a(e){if(Array.isArray(e)){return e}if(!e){return o}if(typeof e==="string"){return e[e.length-1]==="."?e.slice(0,-1).split("."):e.split(".")}throw new TypeError("[tree.dotPath]: the path argument should be a string or an array")}n.toPathArray=a;function i(e,t,r=0){var n,o,i,a=e;for(n=0,o=t.length+r;n<o;n++){i=t[n];if(typeof i==="object"||i==="__proto__"||typeof a==="function"){throw new Error(s)}if(!a||typeof a!=="object"){return undefined}a=a[i]}return a}function l(e,t){var r,n,o,i=e;for(r=0,n=t.length-1;r<n;r++){o=t[r];if(typeof o==="object"||o==="__proto__"||typeof i[o]==="function"){throw new Error(s)}if(!i[o]||typeof i[o]!=="object"){i[o]={}}i=i[o]}return i}n.get=(e,t)=>i(e,a(t));n.set=(e,t,r)=>{if(!e||typeof e!=="object"){return}var n=a(t),o=n[n.length-1];if(typeof o==="object"||o==="__proto__"){throw new Error(s)}var i=l(e,n);i[o]=r;return r};n.define=(e,t,r)=>{if(!e||typeof e!=="object"){return}var n=a(t),o=n[n.length-1];if(typeof o==="object"||o==="__proto__"){throw new Error(s)}var i=l(e,n);if(!(o in i)){i[o]=r}return i[o]};n.inc=(e,t)=>{if(!e||typeof e!=="object"){return}var r=a(t),n=r[r.length-1];if(typeof n==="object"||n==="__proto__"){throw new Error(s)}var o=l(e,r);if(typeof o[n]==="number"){o[n]++}else if(!o[n]||typeof o[n]!=="object"){o[n]=1}return o[n]};n.dec=(e,t)=>{if(!e||typeof e!=="object"){return}var r=a(t),n=r[r.length-1];if(typeof n==="object"||n==="__proto__"){throw new Error(s)}var o=l(e,r);if(typeof o[n]==="number"){o[n]--}else if(!o[n]||typeof o[n]!=="object"){o[n]=-1}return o[n]};n.concat=(e,t,r)=>{if(!e||typeof e!=="object"){return}var n=a(t),o=n[n.length-1];if(typeof o==="object"||o==="__proto__"){throw new Error(s)}var i=l(e,n);if(!i[o]){i[o]=r}else if(Array.isArray(i[o])&&Array.isArray(r)){i[o]=i[o].concat(r)}return i[o]};n.insert=(e,t,r)=>{if(!e||typeof e!=="object"){return}var n=a(t),o=n[n.length-1];if(typeof o==="object"||o==="__proto__"){throw new Error(s)}var i=l(e,n);if(!i[o]){i[o]=r}else if(Array.isArray(i[o])&&Array.isArray(r)){i[o]=r.concat(i[o])}return i[o]};n.delete=(e,t)=>{var r=a(t),n=r[r.length-1];if(typeof n==="object"||n==="__proto__"){throw new Error(s)}var o=i(e,r,-1);if(!o||typeof o!=="object"||!Object.hasOwn(o,n)){return false}delete o[n];return true};n.autoPush=(e,t,r)=>{if(!e||typeof e!=="object"){return}var n=a(t),o=n[n.length-1];if(typeof o==="object"||o==="__proto__"){throw new Error(s)}var i=l(e,n);if(i[o]===undefined){i[o]=r}else if(Array.isArray(i[o])){i[o].push(r)}else{i[o]=[i[o],r]}return i[o]};n.append=(e,t,r)=>{if(!e||typeof e!=="object"){return}var n=a(t),o=n[n.length-1];if(typeof o==="object"||o==="__proto__"){throw new Error(s)}var i=l(e,n);if(!i[o]){i[o]=[r]}else if(Array.isArray(i[o])){i[o].push(r)}return i[o]};n.prepend=(e,t,r)=>{if(!e||typeof e!=="object"){return}var n=a(t),o=n[n.length-1];if(typeof o==="object"||o==="__proto__"){throw new Error(s)}var i=l(e,n);if(!i[o]){i[o]=[r]}else if(Array.isArray(i[o])){i[o].unshift(r)}return i[o]}},{}],28:[function(e,t,r){},{}],29:[function(e,t,r){t.exports=function(e){return e!=null&&(n(e)||o(e)||!!e._isBuffer)};function n(e){return!!e.constructor&&typeof e.constructor.isBuffer==="function"&&e.constructor.isBuffer(e)}function o(e){return typeof e.readFloatLE==="function"&&typeof e.slice==="function"&&n(e.slice(0,0))}},{}],30:[function(e,t,r){var n=t.exports={};var o;var i;function a(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}(function(){try{if(typeof setTimeout==="function"){o=setTimeout}else{o=a}}catch(e){o=a}try{if(typeof clearTimeout==="function"){i=clearTimeout}else{i=s}}catch(e){i=s}})();function l(t){if(o===setTimeout){return setTimeout(t,0)}if((o===a||!o)&&setTimeout){o=setTimeout;return setTimeout(t,0)}try{return o(t,0)}catch(e){try{return o.call(null,t,0)}catch(e){return o.call(this,t,0)}}}function f(t){if(i===clearTimeout){return clearTimeout(t)}if((i===s||!i)&&clearTimeout){i=clearTimeout;return clearTimeout(t)}try{return i(t)}catch(e){try{return i.call(null,t)}catch(e){return i.call(this,t)}}}var u=[];var c=false;var h;var p=-1;function d(){if(!c||!h){return}c=false;if(h.length){u=h.concat(u)}else{p=-1}if(u.length){y()}}function y(){if(c){return}var e=l(d);c=true;var t=u.length;while(t){h=u;u=[];while(++p<t){if(h){h[p].run()}}p=-1;t=u.length}h=null;c=false;f(e)}n.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1){for(var r=1;r<arguments.length;r++){t[r-1]=arguments[r]}}u.push(new g(e,t));if(u.length===1&&!c){l(y)}};function g(e,t){this.fun=e;this.array=t}g.prototype.run=function(){this.fun.apply(null,this.array)};n.title="browser";n.browser=true;n.env={};n.argv=[];n.version="";n.versions={};function b(){}n.on=b;n.addListener=b;n.once=b;n.off=b;n.removeListener=b;n.removeAllListeners=b;n.emit=b;n.prependListener=b;n.prependOnceListener=b;n.listeners=function(e){return[]};n.binding=function(e){throw new Error("process.binding is not supported")};n.cwd=function(){return"/"};n.chdir=function(e){throw new Error("process.chdir is not supported")};n.umask=function(){return 0}},{}]},{},[5])(5)});