check-types-mini 8.0.7 → 8.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2010-2022 Roy Revelt and other contributors
3
+ Copyright (c) 2010-2023 Roy Revelt and other contributors
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining
6
6
  a copy of this software and associated documentation files (the
package/README.md CHANGED
@@ -72,6 +72,6 @@ To report bugs or request features or assistance, [raise an issue](https://githu
72
72
 
73
73
  MIT License.
74
74
 
75
- Copyright © 2010-2022 Roy Revelt and other contributors.
75
+ Copyright © 2010-2023 Roy Revelt and other contributors.
76
76
 
77
77
  <p align="center"><img src="https://codsen.com/images/png-codsen-ok.png" width="98" alt="ok" align="center"> <img src="https://codsen.com/images/png-codsen-1.png" width="148" alt="codsen" align="center"> <img src="https://codsen.com/images/png-codsen-star-small.png" width="32" alt="star" align="center"></p>
@@ -1,13 +1,13 @@
1
1
  /**
2
2
  * @name check-types-mini
3
3
  * @fileoverview Validate options object
4
- * @version 8.0.7
4
+ * @version 8.0.9
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/check-types-mini/}
8
8
  */
9
9
 
10
- import i from"type-detect";import h from"lodash.pullall";import{traverse as w}from"ast-monkey-traverse";import k from"lodash.intersection";import{arrayiffy as N}from"arrayiffy-if-string";import E from"object-path";import{isMatch as S}from"matcher";import{isPlainObject as m}from"codsen-utils";var j="8.0.7";var F=j,v={ignoreKeys:[],ignorePaths:[],acceptArrays:!1,acceptArraysIgnore:[],enforceStrictKeyset:!0,schema:{},msg:"check-types-mini",optsVarName:"opts"};function T(a,r,p){function y(s){return s!=null}function b(s,l){return typeof l=="string"&&(l=N(l)),Array.from(s).filter(n=>!l.some(t=>S(n,t,{caseSensitive:!0})))}let V=Object.prototype.hasOwnProperty,D=["any","anything","every","everything","all","whatever","whatevs"];if(!y(a))throw new Error("check-types-mini: [THROW_ID_01] First argument is missing!");let e={...v,...p};if(typeof e.ignoreKeys=="string"&&(e.ignoreKeys=[e.ignoreKeys]),typeof e.ignorePaths=="string"&&(e.ignorePaths=[e.ignorePaths]),typeof e.acceptArraysIgnore=="string"&&(e.acceptArraysIgnore=[e.acceptArraysIgnore]),e.msg=`${e.msg}`.trim(),e.msg[e.msg.length-1]===":"&&(e.msg=e.msg.slice(0,e.msg.length-1).trim()),m(e.schema))Object.keys(e.schema).forEach(s=>{if(m(e.schema[s])){let l={};w(e.schema[s],(n,t,$)=>{let u=t!==void 0?t:n;return!Array.isArray(u)&&!m(u)&&(l[`${s}.${$.path}`]=u),u}),delete e.schema[s],e.schema={...e.schema,...l}}}),Object.keys(e.schema).forEach(s=>{Array.isArray(e.schema[s])||(e.schema[s]=[e.schema[s]]),e.schema[s]=e.schema[s].map(l=>`${l}`.toLowerCase().trim())});else if(e.schema!=null)throw new Error(`check-types-mini: opts.schema was customised to ${JSON.stringify(e.schema,null,0)} which is not object but ${typeof e.schema}`);if(y(r)||(r={}),e.enforceStrictKeyset)if(y(e.schema)&&Object.keys(e.schema).length){if(r&&b(h(Object.keys(a),Object.keys(r).concat(Object.keys(e.schema))),e.ignoreKeys).length){let s=h(Object.keys(a),Object.keys(r).concat(Object.keys(e.schema)));throw new TypeError(`${e.msg}: ${e.optsVarName}.enforceStrictKeyset is on and the following key${s.length>1?"s":""} ${s.length>1?"are":"is"} not covered by schema and/or reference objects: ${s.join(", ")}`)}}else if(m(r)&&Object.keys(r).length){if(b(h(Object.keys(a),Object.keys(r)),e.ignoreKeys).length!==0){let s=h(Object.keys(a),Object.keys(r));throw new TypeError(`${e.msg}: The input object has key${s.length>1?"s":""} which ${s.length>1?"are":"is"} not covered by the reference object: ${s.join(", ")}`)}else if(b(h(Object.keys(r),Object.keys(a)),e.ignoreKeys).length!==0){let s=h(Object.keys(r),Object.keys(a));throw new TypeError(`${e.msg}: The reference object has key${s.length>1?"s":""} which ${s.length>1?"are":"is"} not present in the input object: ${s.join(", ")}`)}}else throw new TypeError(`${e.msg}: Both ${e.optsVarName}.schema and reference objects are missing! We don't have anything to match the keys as you requested via resolvedOpts.enforceStrictKeyset!`);let g=[];w(a,(s,l,n)=>{let t=l,$=s;if(n.parentType==="array"&&($=void 0,t=s),Array.isArray(g)&&g.length&&g.some(o=>n.path.startsWith(o))||$&&e.ignoreKeys.some(o=>$&&S($,o))||e.ignorePaths.some(o=>S(n.path,o)))return t;let u=!(!m(t)&&!Array.isArray(t)&&Array.isArray(n.parent)),f=!1;m(e.schema)&&V.call(e.schema,n.path)&&(f=!0);let d=!1;if(m(r)&&E.has(r,n.path)&&(d=!0),e.enforceStrictKeyset&&u&&!f&&!d)throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path} is neither covered by reference object (second input argument), nor ${e.optsVarName}.schema! To stop this error, turn off ${e.optsVarName}.enforceStrictKeyset or provide some type reference (2nd argument or ${e.optsVarName}.schema).
10
+ import i from"type-detect";import{traverse as w}from"ast-monkey-traverse";import k from"lodash.intersection";import{arrayiffy as N}from"arrayiffy-if-string";import E from"object-path";import{isMatch as S}from"matcher";import{isPlainObject as m,pullAll as h}from"codsen-utils";var j="8.0.9";var M=j,v={ignoreKeys:[],ignorePaths:[],acceptArrays:!1,acceptArraysIgnore:[],enforceStrictKeyset:!0,schema:{},msg:"check-types-mini",optsVarName:"opts"};function T(a,r,p){function y(s){return s!=null}function b(s,l){return typeof l=="string"&&(l=N(l)),Array.from(s).filter(n=>!l.some(t=>S(n,t,{caseSensitive:!0})))}let V=Object.prototype.hasOwnProperty,D=["any","anything","every","everything","all","whatever","whatevs"];if(!y(a))throw new Error("check-types-mini: [THROW_ID_01] First argument is missing!");let e={...v,...p};if(typeof e.ignoreKeys=="string"&&(e.ignoreKeys=[e.ignoreKeys]),typeof e.ignorePaths=="string"&&(e.ignorePaths=[e.ignorePaths]),typeof e.acceptArraysIgnore=="string"&&(e.acceptArraysIgnore=[e.acceptArraysIgnore]),e.msg=`${e.msg}`.trim(),e.msg[e.msg.length-1]===":"&&(e.msg=e.msg.slice(0,e.msg.length-1).trim()),m(e.schema))Object.keys(e.schema).forEach(s=>{if(m(e.schema[s])){let l={};w(e.schema[s],(n,t,$)=>{let u=t!==void 0?t:n;return!Array.isArray(u)&&!m(u)&&(l[`${s}.${$.path}`]=u),u}),delete e.schema[s],e.schema={...e.schema,...l}}}),Object.keys(e.schema).forEach(s=>{Array.isArray(e.schema[s])||(e.schema[s]=[e.schema[s]]),e.schema[s]=e.schema[s].map(l=>`${l}`.toLowerCase().trim())});else if(e.schema!=null)throw new Error(`check-types-mini: opts.schema was customised to ${JSON.stringify(e.schema,null,0)} which is not object but ${typeof e.schema}`);if(y(r)||(r={}),e.enforceStrictKeyset)if(y(e.schema)&&Object.keys(e.schema).length){if(r&&b(h(Object.keys(a),Object.keys(r).concat(Object.keys(e.schema))),e.ignoreKeys).length){let s=h(Object.keys(a),Object.keys(r).concat(Object.keys(e.schema)));throw new TypeError(`${e.msg}: ${e.optsVarName}.enforceStrictKeyset is on and the following key${s.length>1?"s":""} ${s.length>1?"are":"is"} not covered by schema and/or reference objects: ${s.join(", ")}`)}}else if(m(r)&&Object.keys(r).length){if(b(h(Object.keys(a),Object.keys(r)),e.ignoreKeys).length!==0){let s=h(Object.keys(a),Object.keys(r));throw new TypeError(`${e.msg}: The input object has key${s.length>1?"s":""} which ${s.length>1?"are":"is"} not covered by the reference object: ${s.join(", ")}`)}else if(b(h(Object.keys(r),Object.keys(a)),e.ignoreKeys).length!==0){let s=h(Object.keys(r),Object.keys(a));throw new TypeError(`${e.msg}: The reference object has key${s.length>1?"s":""} which ${s.length>1?"are":"is"} not present in the input object: ${s.join(", ")}`)}}else throw new TypeError(`${e.msg}: Both ${e.optsVarName}.schema and reference objects are missing! We don't have anything to match the keys as you requested via resolvedOpts.enforceStrictKeyset!`);let g=[];w(a,(s,l,n)=>{let t=l,$=s;if(n.parentType==="array"&&($=void 0,t=s),Array.isArray(g)&&g.length&&g.some(o=>n.path.startsWith(o))||$&&e.ignoreKeys.some(o=>$&&S($,o))||e.ignorePaths.some(o=>S(n.path,o)))return t;let u=!(!m(t)&&!Array.isArray(t)&&Array.isArray(n.parent)),f=!1;m(e.schema)&&V.call(e.schema,n.path)&&(f=!0);let d=!1;if(m(r)&&E.has(r,n.path)&&(d=!0),e.enforceStrictKeyset&&u&&!f&&!d)throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path} is neither covered by reference object (second input argument), nor ${e.optsVarName}.schema! To stop this error, turn off ${e.optsVarName}.enforceStrictKeyset or provide some type reference (2nd argument or ${e.optsVarName}.schema).
11
11
 
12
12
  Debug info:
13
13
 
@@ -21,4 +21,4 @@ resolvedOpts = ${JSON.stringify(e,null,4)}
21
21
 
22
22
  current = ${JSON.stringify(t,null,4)}
23
23
 
24
- `);if(f){let o=N(e.schema[n.path]).map(c=>`${c}`.toLowerCase());if(E.set(e.schema,n.path,o),k(o,D).length)g.push(n.path);else if(t!==!0&&t!==!1&&!o.includes(i(t).toLowerCase())||(t===!0||t===!1)&&!o.includes(String(t))&&!o.includes("boolean"))if(Array.isArray(t)&&e.acceptArrays){for(let c=0,O=t.length;c<O;c++)if(!o.includes(i(t[c]).toLowerCase()))throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path}.${c}, the ${c}th element (equal to ${JSON.stringify(t[c],null,0)}) is of a type ${i(t[c]).toLowerCase()}, but only the following are allowed by the ${e.optsVarName}.schema: ${o.join(", ")}`)}else throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path} was customised to ${i(t)!=="string"?'"':""}${JSON.stringify(t,null,0)}${i(t)!=="string"?'"':""} (type: ${i(t).toLowerCase()}) which is not among the allowed types in schema (which is equal to ${JSON.stringify(o,null,0)})`)}else if(r&&m(r)&&d){let o=E.get(r,n.path);if(e.acceptArrays&&Array.isArray(t)&&!e.acceptArraysIgnore.includes(s)){if(!t.every(O=>i(O).toLowerCase()===i(r[s]).toLowerCase()))throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path} was customised to be array, but not all of its elements are ${i(r[s]).toLowerCase()}-type`)}else if(i(t)!==i(o))throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path} was customised to ${i(t).toLowerCase()==="string"?"":'"'}${JSON.stringify(t,null,0)}${i(t).toLowerCase()==="string"?"":'"'} which is not ${i(o).toLowerCase()} but ${i(t).toLowerCase()}`)}return t})}function G(a,r,p){T(a,r,p)}export{G as checkTypesMini,v as defaults,F as version};
24
+ `);if(f){let o=N(e.schema[n.path]).map(c=>`${c}`.toLowerCase());if(E.set(e.schema,n.path,o),k(o,D).length)g.push(n.path);else if(t!==!0&&t!==!1&&!o.includes(i(t).toLowerCase())||(t===!0||t===!1)&&!o.includes(String(t))&&!o.includes("boolean"))if(Array.isArray(t)&&e.acceptArrays){for(let c=0,O=t.length;c<O;c++)if(!o.includes(i(t[c]).toLowerCase()))throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path}.${c}, the ${c}th element (equal to ${JSON.stringify(t[c],null,0)}) is of a type ${i(t[c]).toLowerCase()}, but only the following are allowed by the ${e.optsVarName}.schema: ${o.join(", ")}`)}else throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path} was customised to ${i(t)!=="string"?'"':""}${JSON.stringify(t,null,0)}${i(t)!=="string"?'"':""} (type: ${i(t).toLowerCase()}) which is not among the allowed types in schema (which is equal to ${JSON.stringify(o,null,0)})`)}else if(r&&m(r)&&d){let o=E.get(r,n.path);if(e.acceptArrays&&Array.isArray(t)&&!e.acceptArraysIgnore.includes(s)){if(!t.every(O=>i(O).toLowerCase()===i(r[s]).toLowerCase()))throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path} was customised to be array, but not all of its elements are ${i(r[s]).toLowerCase()}-type`)}else if(i(t)!==i(o))throw new TypeError(`${e.msg}: ${e.optsVarName}.${n.path} was customised to ${i(t).toLowerCase()==="string"?"":'"'}${JSON.stringify(t,null,0)}${i(t).toLowerCase()==="string"?"":'"'} which is not ${i(o).toLowerCase()} but ${i(t).toLowerCase()}`)}return t})}function F(a,r,p){T(a,r,p)}export{F as checkTypesMini,v as defaults,M as version};
@@ -1,13 +1,13 @@
1
1
  /**
2
2
  * @name check-types-mini
3
3
  * @fileoverview Validate options object
4
- * @version 8.0.7
4
+ * @version 8.0.9
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/check-types-mini/}
8
8
  */
9
9
 
10
- "use strict";var checkTypesMini=(()=>{var Yt=Object.create;var J=Object.defineProperty,Zt=Object.defineProperties,Xt=Object.getOwnPropertyDescriptor,zt=Object.getOwnPropertyDescriptors,er=Object.getOwnPropertyNames,ke=Object.getOwnPropertySymbols,tr=Object.getPrototypeOf,Le=Object.prototype.hasOwnProperty,rr=Object.prototype.propertyIsEnumerable;var Me=(e,t,r)=>t in e?J(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,A=(e,t)=>{for(var r in t||(t={}))Le.call(t,r)&&Me(e,r,t[r]);if(ke)for(var r of ke(t))rr.call(t,r)&&Me(e,r,t[r]);return e},R=(e,t)=>Zt(e,zt(t));var F=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),nr=(e,t)=>{for(var r in t)J(e,r,{get:t[r],enumerable:!0})},Ke=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let c of er(t))!Le.call(e,c)&&c!==r&&J(e,c,{get:()=>t[c],enumerable:!(n=Xt(t,c))||n.enumerable});return e};var B=(e,t,r)=>(r=e!=null?Yt(tr(e)):{},Ke(t||!e||!e.__esModule?J(r,"default",{value:e,enumerable:!0}):r,e)),ir=e=>Ke(J({},"__esModule",{value:!0}),e);var He=F((le,fe)=>{(function(e,t){typeof le=="object"&&typeof fe<"u"?fe.exports=t():typeof define=="function"&&define.amd?define(t):e.typeDetect=t()})(le,function(){"use strict";var e=typeof Promise=="function",t=typeof self=="object"?self:global,r=typeof Symbol<"u",n=typeof Map<"u",c=typeof Set<"u",p=typeof WeakMap<"u",y=typeof WeakSet<"u",i=typeof DataView<"u",g=r&&typeof Symbol.iterator<"u",l=r&&typeof Symbol.toStringTag<"u",a=c&&typeof Set.prototype.entries=="function",s=n&&typeof Map.prototype.entries=="function",h=a&&Object.getPrototypeOf(new Set().entries()),m=s&&Object.getPrototypeOf(new Map().entries()),b=g&&typeof Array.prototype[Symbol.iterator]=="function",v=b&&Object.getPrototypeOf([][Symbol.iterator]()),f=g&&typeof String.prototype[Symbol.iterator]=="function",o=f&&Object.getPrototypeOf(""[Symbol.iterator]()),u=8,d=-1;function O(w){var Ie=typeof w;if(Ie!=="object")return Ie;if(w===null)return"null";if(w===t)return"global";if(Array.isArray(w)&&(l===!1||!(Symbol.toStringTag in w)))return"Array";if(typeof window=="object"&&window!==null){if(typeof window.location=="object"&&w===window.location)return"Location";if(typeof window.document=="object"&&w===window.document)return"Document";if(typeof window.navigator=="object"){if(typeof window.navigator.mimeTypes=="object"&&w===window.navigator.mimeTypes)return"MimeTypeArray";if(typeof window.navigator.plugins=="object"&&w===window.navigator.plugins)return"PluginArray"}if((typeof window.HTMLElement=="function"||typeof window.HTMLElement=="object")&&w instanceof window.HTMLElement){if(w.tagName==="BLOCKQUOTE")return"HTMLQuoteElement";if(w.tagName==="TD")return"HTMLTableDataCellElement";if(w.tagName==="TH")return"HTMLTableHeaderCellElement"}}var Ve=l&&w[Symbol.toStringTag];if(typeof Ve=="string")return Ve;var _=Object.getPrototypeOf(w);return _===RegExp.prototype?"RegExp":_===Date.prototype?"Date":e&&_===Promise.prototype?"Promise":c&&_===Set.prototype?"Set":n&&_===Map.prototype?"Map":y&&_===WeakSet.prototype?"WeakSet":p&&_===WeakMap.prototype?"WeakMap":i&&_===DataView.prototype?"DataView":n&&_===m?"Map Iterator":c&&_===h?"Set Iterator":b&&_===v?"Array Iterator":f&&_===o?"String Iterator":_===null?"Object":Object.prototype.toString.call(w).slice(u,d)}return O})});var Fe=F((Zi,Re)=>{function or(e,t){for(var r=-1,n=e?e.length:0,c=Array(n);++r<n;)c[r]=t(e[r],r,e);return c}function sr(e,t,r,n){for(var c=e.length,p=r+(n?1:-1);n?p--:++p<c;)if(t(e[p],p,e))return p;return-1}function ar(e,t,r){if(t!==t)return sr(e,ur,r);for(var n=r-1,c=e.length;++n<c;)if(e[n]===t)return n;return-1}function cr(e,t,r,n){for(var c=r-1,p=e.length;++c<p;)if(n(e[c],t))return c;return-1}function ur(e){return e!==e}function lr(e){return function(t){return e(t)}}var fr=Array.prototype,Je=fr.splice;function pr(e,t,r,n){var c=n?cr:ar,p=-1,y=t.length,i=e;for(e===t&&(t=hr(t)),r&&(i=or(e,lr(r)));++p<y;)for(var g=0,l=t[p],a=r?r(l):l;(g=c(i,a,g,n))>-1;)i!==e&&Je.call(i,g,1),Je.call(e,g,1);return e}function hr(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}function gr(e,t){return e&&e.length&&t&&t.length?pr(e,t):e}Re.exports=gr});var Dt=F((G,V)=>{var yr=200,tt="__lodash_hash_undefined__",rt=9007199254740991,$e="[object Arguments]",dr="[object Array]",nt="[object Boolean]",it="[object Date]",mr="[object Error]",we="[object Function]",ot="[object GeneratorFunction]",q="[object Map]",st="[object Number]",Oe="[object Object]",Be="[object Promise]",at="[object RegExp]",Y="[object Set]",ct="[object String]",ut="[object Symbol]",he="[object WeakMap]",lt="[object ArrayBuffer]",Z="[object DataView]",ft="[object Float32Array]",pt="[object Float64Array]",ht="[object Int8Array]",gt="[object Int16Array]",yt="[object Int32Array]",dt="[object Uint8Array]",mt="[object Uint8ClampedArray]",bt="[object Uint16Array]",$t="[object Uint32Array]",br=/[\\^$.*+?()[\]{}|]/g,$r=/\w*$/,wr=/^\[object .+?Constructor\]$/,Or=/^(?:0|[1-9]\d*)$/,$={};$[$e]=$[dr]=$[lt]=$[Z]=$[nt]=$[it]=$[ft]=$[pt]=$[ht]=$[gt]=$[yt]=$[q]=$[st]=$[Oe]=$[at]=$[Y]=$[ct]=$[ut]=$[dt]=$[mt]=$[bt]=$[$t]=!0;$[mr]=$[we]=$[he]=!1;var Sr=typeof global=="object"&&global&&global.Object===Object&&global,vr=typeof self=="object"&&self&&self.Object===Object&&self,x=Sr||vr||Function("return this")(),wt=typeof G=="object"&&G&&!G.nodeType&&G,Ge=wt&&typeof V=="object"&&V&&!V.nodeType&&V,_r=Ge&&Ge.exports===wt;function Ar(e,t){return e.set(t[0],t[1]),e}function Er(e,t){return e.add(t),e}function xr(e,t){for(var r=-1,n=e?e.length:0;++r<n&&t(e[r],r,e)!==!1;);return e}function Tr(e,t){for(var r=-1,n=t.length,c=e.length;++r<n;)e[c+r]=t[r];return e}function Ot(e,t,r,n){var c=-1,p=e?e.length:0;for(n&&p&&(r=e[++c]);++c<p;)r=t(r,e[c],c,e);return r}function Cr(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}function jr(e,t){return e==null?void 0:e[t]}function St(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch(r){}return t}function Ue(e){var t=-1,r=Array(e.size);return e.forEach(function(n,c){r[++t]=[c,n]}),r}function Se(e,t){return function(r){return e(t(r))}}function We(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var Dr=Array.prototype,Nr=Function.prototype,X=Object.prototype,pe=x["__core-js_shared__"],Qe=function(){var e=/[^.]+$/.exec(pe&&pe.keys&&pe.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),vt=Nr.toString,C=X.hasOwnProperty,z=X.toString,Pr=RegExp("^"+vt.call(C).replace(br,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),qe=_r?x.Buffer:void 0,Ye=x.Symbol,Ze=x.Uint8Array,Ir=Se(Object.getPrototypeOf,Object),Vr=Object.create,kr=X.propertyIsEnumerable,Mr=Dr.splice,Xe=Object.getOwnPropertySymbols,Lr=qe?qe.isBuffer:void 0,Kr=Se(Object.keys,Object),ge=L(x,"DataView"),U=L(x,"Map"),ye=L(x,"Promise"),de=L(x,"Set"),me=L(x,"WeakMap"),W=L(Object,"create"),Hr=N(ge),Jr=N(U),Rr=N(ye),Fr=N(de),Br=N(me),ze=Ye?Ye.prototype:void 0,et=ze?ze.valueOf:void 0;function D(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Gr(){this.__data__=W?W(null):{}}function Ur(e){return this.has(e)&&delete this.__data__[e]}function Wr(e){var t=this.__data__;if(W){var r=t[e];return r===tt?void 0:r}return C.call(t,e)?t[e]:void 0}function Qr(e){var t=this.__data__;return W?t[e]!==void 0:C.call(t,e)}function qr(e,t){var r=this.__data__;return r[e]=W&&t===void 0?tt:t,this}D.prototype.clear=Gr;D.prototype.delete=Ur;D.prototype.get=Wr;D.prototype.has=Qr;D.prototype.set=qr;function T(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Yr(){this.__data__=[]}function Zr(e){var t=this.__data__,r=ee(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():Mr.call(t,r,1),!0}function Xr(e){var t=this.__data__,r=ee(t,e);return r<0?void 0:t[r][1]}function zr(e){return ee(this.__data__,e)>-1}function en(e,t){var r=this.__data__,n=ee(r,e);return n<0?r.push([e,t]):r[n][1]=t,this}T.prototype.clear=Yr;T.prototype.delete=Zr;T.prototype.get=Xr;T.prototype.has=zr;T.prototype.set=en;function k(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function tn(){this.__data__={hash:new D,map:new(U||T),string:new D}}function rn(e){return te(this,e).delete(e)}function nn(e){return te(this,e).get(e)}function on(e){return te(this,e).has(e)}function sn(e,t){return te(this,e).set(e,t),this}k.prototype.clear=tn;k.prototype.delete=rn;k.prototype.get=nn;k.prototype.has=on;k.prototype.set=sn;function M(e){this.__data__=new T(e)}function an(){this.__data__=new T}function cn(e){return this.__data__.delete(e)}function un(e){return this.__data__.get(e)}function ln(e){return this.__data__.has(e)}function fn(e,t){var r=this.__data__;if(r instanceof T){var n=r.__data__;if(!U||n.length<yr-1)return n.push([e,t]),this;r=this.__data__=new k(n)}return r.set(e,t),this}M.prototype.clear=an;M.prototype.delete=cn;M.prototype.get=un;M.prototype.has=ln;M.prototype.set=fn;function pn(e,t){var r=_e(e)||kn(e)?Cr(e.length,String):[],n=r.length,c=!!n;for(var p in e)(t||C.call(e,p))&&!(c&&(p=="length"||Nn(p,n)))&&r.push(p);return r}function _t(e,t,r){var n=e[t];(!(C.call(e,t)&&Tt(n,r))||r===void 0&&!(t in e))&&(e[t]=r)}function ee(e,t){for(var r=e.length;r--;)if(Tt(e[r][0],t))return r;return-1}function hn(e,t){return e&&At(t,Ae(t),e)}function be(e,t,r,n,c,p,y){var i;if(n&&(i=p?n(e,c,p,y):n(e)),i!==void 0)return i;if(!re(e))return e;var g=_e(e);if(g){if(i=Cn(e),!t)return En(e,i)}else{var l=j(e),a=l==we||l==ot;if(Ln(e))return $n(e,t);if(l==Oe||l==$e||a&&!p){if(St(e))return p?e:{};if(i=jn(a?{}:e),!t)return xn(e,hn(i,e))}else{if(!$[l])return p?e:{};i=Dn(e,l,be,t)}}y||(y=new M);var s=y.get(e);if(s)return s;if(y.set(e,i),!g)var h=r?Tn(e):Ae(e);return xr(h||e,function(m,b){h&&(b=m,m=e[b]),_t(i,b,be(m,t,r,n,b,e,y))}),i}function gn(e){return re(e)?Vr(e):{}}function yn(e,t,r){var n=t(e);return _e(e)?n:Tr(n,r(e))}function dn(e){return z.call(e)}function mn(e){if(!re(e)||In(e))return!1;var t=jt(e)||St(e)?Pr:wr;return t.test(N(e))}function bn(e){if(!xt(e))return Kr(e);var t=[];for(var r in Object(e))C.call(e,r)&&r!="constructor"&&t.push(r);return t}function $n(e,t){if(t)return e.slice();var r=new e.constructor(e.length);return e.copy(r),r}function ve(e){var t=new e.constructor(e.byteLength);return new Ze(t).set(new Ze(e)),t}function wn(e,t){var r=t?ve(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}function On(e,t,r){var n=t?r(Ue(e),!0):Ue(e);return Ot(n,Ar,new e.constructor)}function Sn(e){var t=new e.constructor(e.source,$r.exec(e));return t.lastIndex=e.lastIndex,t}function vn(e,t,r){var n=t?r(We(e),!0):We(e);return Ot(n,Er,new e.constructor)}function _n(e){return et?Object(et.call(e)):{}}function An(e,t){var r=t?ve(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}function En(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}function At(e,t,r,n){r||(r={});for(var c=-1,p=t.length;++c<p;){var y=t[c],i=n?n(r[y],e[y],y,r,e):void 0;_t(r,y,i===void 0?e[y]:i)}return r}function xn(e,t){return At(e,Et(e),t)}function Tn(e){return yn(e,Ae,Et)}function te(e,t){var r=e.__data__;return Pn(t)?r[typeof t=="string"?"string":"hash"]:r.map}function L(e,t){var r=jr(e,t);return mn(r)?r:void 0}var Et=Xe?Se(Xe,Object):Jn,j=dn;(ge&&j(new ge(new ArrayBuffer(1)))!=Z||U&&j(new U)!=q||ye&&j(ye.resolve())!=Be||de&&j(new de)!=Y||me&&j(new me)!=he)&&(j=function(e){var t=z.call(e),r=t==Oe?e.constructor:void 0,n=r?N(r):void 0;if(n)switch(n){case Hr:return Z;case Jr:return q;case Rr:return Be;case Fr:return Y;case Br:return he}return t});function Cn(e){var t=e.length,r=e.constructor(t);return t&&typeof e[0]=="string"&&C.call(e,"index")&&(r.index=e.index,r.input=e.input),r}function jn(e){return typeof e.constructor=="function"&&!xt(e)?gn(Ir(e)):{}}function Dn(e,t,r,n){var c=e.constructor;switch(t){case lt:return ve(e);case nt:case it:return new c(+e);case Z:return wn(e,n);case ft:case pt:case ht:case gt:case yt:case dt:case mt:case bt:case $t:return An(e,n);case q:return On(e,n,r);case st:case ct:return new c(e);case at:return Sn(e);case Y:return vn(e,n,r);case ut:return _n(e)}}function Nn(e,t){return t=t==null?rt:t,!!t&&(typeof e=="number"||Or.test(e))&&e>-1&&e%1==0&&e<t}function Pn(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function In(e){return!!Qe&&Qe in e}function xt(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||X;return e===r}function N(e){if(e!=null){try{return vt.call(e)}catch(t){}try{return e+""}catch(t){}}return""}function Vn(e){return be(e,!0,!0)}function Tt(e,t){return e===t||e!==e&&t!==t}function kn(e){return Mn(e)&&C.call(e,"callee")&&(!kr.call(e,"callee")||z.call(e)==$e)}var _e=Array.isArray;function Ct(e){return e!=null&&Kn(e.length)&&!jt(e)}function Mn(e){return Hn(e)&&Ct(e)}var Ln=Lr||Rn;function jt(e){var t=re(e)?z.call(e):"";return t==we||t==ot}function Kn(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=rt}function re(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function Hn(e){return!!e&&typeof e=="object"}function Ae(e){return Ct(e)?pn(e):bn(e)}function Jn(){return[]}function Rn(){return!1}V.exports=Vn});var Ft=F((io,Rt)=>{var Ce="__lodash_hash_undefined__",Bn=9007199254740991,Gn="[object Function]",Un="[object GeneratorFunction]",Wn=/[\\^$.*+?()[\]{}|]/g,Qn=/^\[object .+?Constructor\]$/,qn=typeof global=="object"&&global&&global.Object===Object&&global,Yn=typeof self=="object"&&self&&self.Object===Object&&self,Vt=qn||Yn||Function("return this")();function Zn(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function Xn(e,t){var r=e?e.length:0;return!!r&&ti(e,t,0)>-1}function zn(e,t,r){for(var n=-1,c=e?e.length:0;++n<c;)if(r(t,e[n]))return!0;return!1}function kt(e,t){for(var r=-1,n=e?e.length:0,c=Array(n);++r<n;)c[r]=t(e[r],r,e);return c}function ei(e,t,r,n){for(var c=e.length,p=r+(n?1:-1);n?p--:++p<c;)if(t(e[p],p,e))return p;return-1}function ti(e,t,r){if(t!==t)return ei(e,ri,r);for(var n=r-1,c=e.length;++n<c;)if(e[n]===t)return n;return-1}function ri(e){return e!==e}function ni(e){return function(t){return e(t)}}function Nt(e,t){return e.has(t)}function ii(e,t){return e==null?void 0:e[t]}function oi(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch(r){}return t}var si=Array.prototype,ai=Function.prototype,Mt=Object.prototype,Te=Vt["__core-js_shared__"],Pt=function(){var e=/[^.]+$/.exec(Te&&Te.keys&&Te.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),Lt=ai.toString,je=Mt.hasOwnProperty,ci=Mt.toString,ui=RegExp("^"+Lt.call(je).replace(Wn,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),li=si.splice,It=Math.max,fi=Math.min,pi=Kt(Vt,"Map"),Q=Kt(Object,"create");function P(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function hi(){this.__data__=Q?Q(null):{}}function gi(e){return this.has(e)&&delete this.__data__[e]}function yi(e){var t=this.__data__;if(Q){var r=t[e];return r===Ce?void 0:r}return je.call(t,e)?t[e]:void 0}function di(e){var t=this.__data__;return Q?t[e]!==void 0:je.call(t,e)}function mi(e,t){var r=this.__data__;return r[e]=Q&&t===void 0?Ce:t,this}P.prototype.clear=hi;P.prototype.delete=gi;P.prototype.get=yi;P.prototype.has=di;P.prototype.set=mi;function K(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function bi(){this.__data__=[]}function $i(e){var t=this.__data__,r=oe(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():li.call(t,r,1),!0}function wi(e){var t=this.__data__,r=oe(t,e);return r<0?void 0:t[r][1]}function Oi(e){return oe(this.__data__,e)>-1}function Si(e,t){var r=this.__data__,n=oe(r,e);return n<0?r.push([e,t]):r[n][1]=t,this}K.prototype.clear=bi;K.prototype.delete=$i;K.prototype.get=wi;K.prototype.has=Oi;K.prototype.set=Si;function H(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function vi(){this.__data__={hash:new P,map:new(pi||K),string:new P}}function _i(e){return se(this,e).delete(e)}function Ai(e){return se(this,e).get(e)}function Ei(e){return se(this,e).has(e)}function xi(e,t){return se(this,e).set(e,t),this}H.prototype.clear=vi;H.prototype.delete=_i;H.prototype.get=Ai;H.prototype.has=Ei;H.prototype.set=xi;function ie(e){var t=-1,r=e?e.length:0;for(this.__data__=new H;++t<r;)this.add(e[t])}function Ti(e){return this.__data__.set(e,Ce),this}function Ci(e){return this.__data__.has(e)}ie.prototype.add=ie.prototype.push=Ti;ie.prototype.has=Ci;function oe(e,t){for(var r=e.length;r--;)if(Li(e[r][0],t))return r;return-1}function ji(e,t,r){for(var n=r?zn:Xn,c=e[0].length,p=e.length,y=p,i=Array(p),g=1/0,l=[];y--;){var a=e[y];y&&t&&(a=kt(a,ni(t))),g=fi(a.length,g),i[y]=!r&&(t||c>=120&&a.length>=120)?new ie(y&&a):void 0}a=e[0];var s=-1,h=i[0];e:for(;++s<c&&l.length<g;){var m=a[s],b=t?t(m):m;if(m=r||m!==0?m:0,!(h?Nt(h,b):n(l,b,r))){for(y=p;--y;){var v=i[y];if(!(v?Nt(v,b):n(e[y],b,r)))continue e}h&&h.push(b),l.push(m)}}return l}function Di(e){if(!Jt(e)||Vi(e))return!1;var t=Ht(e)||oi(e)?ui:Qn;return t.test(ki(e))}function Ni(e,t){return t=It(t===void 0?e.length-1:t,0),function(){for(var r=arguments,n=-1,c=It(r.length-t,0),p=Array(c);++n<c;)p[n]=r[t+n];n=-1;for(var y=Array(t+1);++n<t;)y[n]=r[n];return y[t]=p,Zn(e,this,y)}}function Pi(e){return Hi(e)?e:[]}function se(e,t){var r=e.__data__;return Ii(t)?r[typeof t=="string"?"string":"hash"]:r.map}function Kt(e,t){var r=ii(e,t);return Di(r)?r:void 0}function Ii(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Vi(e){return!!Pt&&Pt in e}function ki(e){if(e!=null){try{return Lt.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var Mi=Ni(function(e){var t=kt(e,Pi);return t.length&&t[0]===e[0]?ji(t):[]});function Li(e,t){return e===t||e!==e&&t!==t}function Ki(e){return e!=null&&Ji(e.length)&&!Ht(e)}function Hi(e){return Ri(e)&&Ki(e)}function Ht(e){var t=Jt(e)?ci.call(e):"";return t==Gn||t==Un}function Ji(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Bn}function Jt(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function Ri(e){return!!e&&typeof e=="object"}Rt.exports=Mi});var Gt=F((Bt,ae)=>{(function(e,t){"use strict";typeof ae=="object"&&typeof ae.exports=="object"?ae.exports=t():typeof define=="function"&&define.amd?define([],t):e.objectPath=t()})(Bt,function(){"use strict";var e=Object.prototype.toString;function t(a,s){return a==null?!1:Object.prototype.hasOwnProperty.call(a,s)}function r(a){if(!a||p(a)&&a.length===0)return!0;if(typeof a!="string"){for(var s in a)if(t(a,s))return!1;return!0}return!1}function n(a){return e.call(a)}function c(a){return typeof a=="object"&&n(a)==="[object Object]"}var p=Array.isArray||function(a){return e.call(a)==="[object Array]"};function y(a){return typeof a=="boolean"||n(a)==="[object Boolean]"}function i(a){var s=parseInt(a);return s.toString()===a?s:a}function g(a){a=a||{};var s=function(f){return Object.keys(s).reduce(function(o,u){return u==="create"||typeof s[u]=="function"&&(o[u]=s[u].bind(s,f)),o},{})},h;a.includeInheritedProps?h=function(){return!0}:h=function(f,o){return typeof o=="number"&&Array.isArray(f)||t(f,o)};function m(f,o){if(h(f,o))return f[o]}var b;a.includeInheritedProps?b=function(f,o){typeof o!="string"&&typeof o!="number"&&(o=String(o));var u=m(f,o);if(o==="__proto__"||o==="prototype"||o==="constructor"&&typeof u=="function")throw new Error("For security reasons, object's magic properties cannot be set");return u}:b=function(f,o){return m(f,o)};function v(f,o,u,d){if(typeof o=="number"&&(o=[o]),!o||o.length===0)return f;if(typeof o=="string")return v(f,o.split(".").map(i),u,d);var O=o[0],w=b(f,O);return o.length===1?((w===void 0||!d)&&(f[O]=u),w):(w===void 0&&(typeof o[1]=="number"?f[O]=[]:f[O]={}),v(f[O],o.slice(1),u,d))}return s.has=function(f,o){if(typeof o=="number"?o=[o]:typeof o=="string"&&(o=o.split(".")),!o||o.length===0)return!!f;for(var u=0;u<o.length;u++){var d=i(o[u]);if(typeof d=="number"&&p(f)&&d<f.length||(a.includeInheritedProps?d in Object(f):t(f,d)))f=f[d];else return!1}return!0},s.ensureExists=function(f,o,u){return v(f,o,u,!0)},s.set=function(f,o,u,d){return v(f,o,u,d)},s.insert=function(f,o,u,d){var O=s.get(f,o);d=~~d,p(O)||(O=[],s.set(f,o,O)),O.splice(d,0,u)},s.empty=function(f,o){if(!r(o)&&f!=null){var u,d;if(u=s.get(f,o)){if(typeof u=="string")return s.set(f,o,"");if(y(u))return s.set(f,o,!1);if(typeof u=="number")return s.set(f,o,0);if(p(u))u.length=0;else if(c(u))for(d in u)h(u,d)&&delete u[d];else return s.set(f,o,null)}}},s.push=function(f,o){var u=s.get(f,o);p(u)||(u=[],s.set(f,o,u)),u.push.apply(u,Array.prototype.slice.call(arguments,2))},s.coalesce=function(f,o,u){for(var d,O=0,w=o.length;O<w;O++)if((d=s.get(f,o[O]))!==void 0)return d;return u},s.get=function(f,o,u){if(typeof o=="number"&&(o=[o]),!o||o.length===0)return f;if(f==null)return u;if(typeof o=="string")return s.get(f,o.split("."),u);var d=i(o[0]),O=b(f,d);return O===void 0?u:o.length===1?O:s.get(f[d],o.slice(1),u)},s.del=function(o,u){if(typeof u=="number"&&(u=[u]),o==null||r(u))return o;if(typeof u=="string")return s.del(o,u.split("."));var d=i(u[0]);if(b(o,d),!h(o,d))return o;if(u.length===1)p(o)?o.splice(d,1):delete o[d];else return s.del(o[d],u.slice(1));return o},s}var l=g();return l.create=g,l.withInheritedProps=g({includeInheritedProps:!0}),l})});var qi={};nr(qi,{checkTypesMini:()=>Qi,defaults:()=>qt,version:()=>Ui});var S=B(He(),1),I=B(Fe(),1);var ne=B(Dt(),1);function E(e){if(e==null||typeof e!="object")return!1;let t=Object.getPrototypeOf(e);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null?!1:!(Symbol.iterator in e)&&!(Symbol.toStringTag in e)}function Fn(e){if(e.includes(".")){let t=e.lastIndexOf(".");if(!e.slice(0,t).includes("."))return e.slice(0,t);for(let r=t-1;r--;)if(e[r]===".")return e.slice(r+1,t)}return null}var Ee=Fn;function xe(e,t){let r={now:!1};function n(c,p,y,i){let g=(0,ne.default)(c),l,a=A({depth:-1,path:""},y);if(a.depth+=1,Array.isArray(g))for(let s=0,h=g.length;s<h&&!i.now;s++){let m=a.path?`${a.path}.${s}`:`${s}`;g[s]!==void 0?(a.parent=(0,ne.default)(g),a.parentType="array",a.parentKey=Ee(m),l=n(p(g[s],void 0,R(A({},a),{path:m}),i),p,R(A({},a),{path:m}),i),Number.isNaN(l)&&s<g.length?(g.splice(s,1),s-=1):g[s]=l):g.splice(s,1)}else if(E(g))for(let s in g){if(i.now&&s!=null)break;let h=a.path?`${a.path}.${s}`:s;a.depth===0&&s!=null&&(a.topmostKey=s),a.parent=(0,ne.default)(g),a.parentType="object",a.parentKey=Ee(h),l=n(p(s,g[s],R(A({},a),{path:h}),i),p,R(A({},a),{path:h}),i),Number.isNaN(l)?delete g[s]:g[s]=l}return g}return n(e,t,{},r)}var Qt=B(Ft(),1);function De(e){return typeof e!="string"?e:e.length?[e]:[]}var ue=B(Gt(),1);function Ne(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}var Pe=new Map,Ut=(e,t)=>{if(!Array.isArray(e))switch(typeof e){case"string":e=[e];break;case"undefined":e=[];break;default:throw new TypeError(`Expected '${t}' to be a string or an array, but got a type of '${typeof e}'`)}return e.filter(r=>{if(typeof r!="string"){if(typeof r>"u")return!1;throw new TypeError(`Expected '${t}' to be an array of strings, but found a type of '${typeof r}' in the array`)}return!0})},Fi=(e,t)=>{t=A({caseSensitive:!1},t);let r=e+JSON.stringify(t);if(Pe.has(r))return Pe.get(r);let n=e[0]==="!";n&&(e=e.slice(1)),e=Ne(e).replace(/\\\*/g,"[\\s\\S]*");let c=new RegExp(`^${e}$`,t.caseSensitive?"":"i");return c.negated=n,Pe.set(r,c),c},Bi=(e,t,r,n)=>{if(e=Ut(e,"inputs"),t=Ut(t,"patterns"),t.length===0)return[];t=t.map(y=>Fi(y,r));let{allPatterns:c}=r||{},p=[];for(let y of e){let i,g=[...t].fill(!1);for(let[l,a]of t.entries())if(a.test(y)&&(g[l]=!0,i=!a.negated,!i))break;if(!(i===!1||i===void 0&&t.some(l=>!l.negated)||c&&g.some((l,a)=>!l&&!t[a].negated))&&(p.push(y),n))break}return p};function ce(e,t,r){return Bi(e,t,r,!0).length>0}var Wt="8.0.7";var Ui=Wt,qt={ignoreKeys:[],ignorePaths:[],acceptArrays:!1,acceptArraysIgnore:[],enforceStrictKeyset:!0,schema:{},msg:"check-types-mini",optsVarName:"opts"};function Wi(e,t,r){function n(l){return l!=null}function c(l,a){return typeof a=="string"&&(a=De(a)),Array.from(l).filter(s=>!a.some(h=>ce(s,h,{caseSensitive:!0})))}let p=Object.prototype.hasOwnProperty,y=["any","anything","every","everything","all","whatever","whatevs"];if(!n(e))throw new Error("check-types-mini: [THROW_ID_01] First argument is missing!");let i=A(A({},qt),r);if(typeof i.ignoreKeys=="string"&&(i.ignoreKeys=[i.ignoreKeys]),typeof i.ignorePaths=="string"&&(i.ignorePaths=[i.ignorePaths]),typeof i.acceptArraysIgnore=="string"&&(i.acceptArraysIgnore=[i.acceptArraysIgnore]),i.msg=`${i.msg}`.trim(),i.msg[i.msg.length-1]===":"&&(i.msg=i.msg.slice(0,i.msg.length-1).trim()),E(i.schema))Object.keys(i.schema).forEach(l=>{if(E(i.schema[l])){let a={};xe(i.schema[l],(s,h,m)=>{let b=h!==void 0?h:s;return!Array.isArray(b)&&!E(b)&&(a[`${l}.${m.path}`]=b),b}),delete i.schema[l],i.schema=A(A({},i.schema),a)}}),Object.keys(i.schema).forEach(l=>{Array.isArray(i.schema[l])||(i.schema[l]=[i.schema[l]]),i.schema[l]=i.schema[l].map(a=>`${a}`.toLowerCase().trim())});else if(i.schema!=null)throw new Error(`check-types-mini: opts.schema was customised to ${JSON.stringify(i.schema,null,0)} which is not object but ${typeof i.schema}`);if(n(t)||(t={}),i.enforceStrictKeyset)if(n(i.schema)&&Object.keys(i.schema).length){if(t&&c((0,I.default)(Object.keys(e),Object.keys(t).concat(Object.keys(i.schema))),i.ignoreKeys).length){let l=(0,I.default)(Object.keys(e),Object.keys(t).concat(Object.keys(i.schema)));throw new TypeError(`${i.msg}: ${i.optsVarName}.enforceStrictKeyset is on and the following key${l.length>1?"s":""} ${l.length>1?"are":"is"} not covered by schema and/or reference objects: ${l.join(", ")}`)}}else if(E(t)&&Object.keys(t).length){if(c((0,I.default)(Object.keys(e),Object.keys(t)),i.ignoreKeys).length!==0){let l=(0,I.default)(Object.keys(e),Object.keys(t));throw new TypeError(`${i.msg}: The input object has key${l.length>1?"s":""} which ${l.length>1?"are":"is"} not covered by the reference object: ${l.join(", ")}`)}else if(c((0,I.default)(Object.keys(t),Object.keys(e)),i.ignoreKeys).length!==0){let l=(0,I.default)(Object.keys(t),Object.keys(e));throw new TypeError(`${i.msg}: The reference object has key${l.length>1?"s":""} which ${l.length>1?"are":"is"} not present in the input object: ${l.join(", ")}`)}}else throw new TypeError(`${i.msg}: Both ${i.optsVarName}.schema and reference objects are missing! We don't have anything to match the keys as you requested via resolvedOpts.enforceStrictKeyset!`);let g=[];xe(e,(l,a,s)=>{let h=a,m=l;if(s.parentType==="array"&&(m=void 0,h=l),Array.isArray(g)&&g.length&&g.some(o=>s.path.startsWith(o))||m&&i.ignoreKeys.some(o=>m&&ce(m,o))||i.ignorePaths.some(o=>ce(s.path,o)))return h;let b=!(!E(h)&&!Array.isArray(h)&&Array.isArray(s.parent)),v=!1;E(i.schema)&&p.call(i.schema,s.path)&&(v=!0);let f=!1;if(E(t)&&ue.default.has(t,s.path)&&(f=!0),i.enforceStrictKeyset&&b&&!v&&!f)throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path} is neither covered by reference object (second input argument), nor ${i.optsVarName}.schema! To stop this error, turn off ${i.optsVarName}.enforceStrictKeyset or provide some type reference (2nd argument or ${i.optsVarName}.schema).
10
+ "use strict";var checkTypesMini=(()=>{var Wt=Object.create;var J=Object.defineProperty,qt=Object.defineProperties,Qt=Object.getOwnPropertyDescriptor,Yt=Object.getOwnPropertyDescriptors,Zt=Object.getOwnPropertyNames,ke=Object.getOwnPropertySymbols,Xt=Object.getPrototypeOf,Me=Object.prototype.hasOwnProperty,zt=Object.prototype.propertyIsEnumerable;var Le=(e,t,r)=>t in e?J(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,A=(e,t)=>{for(var r in t||(t={}))Me.call(t,r)&&Le(e,r,t[r]);if(ke)for(var r of ke(t))zt.call(t,r)&&Le(e,r,t[r]);return e},R=(e,t)=>qt(e,Yt(t));var W=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),er=(e,t)=>{for(var r in t)J(e,r,{get:t[r],enumerable:!0})},Ke=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let f of Zt(t))!Me.call(e,f)&&f!==r&&J(e,f,{get:()=>t[f],enumerable:!(n=Qt(t,f))||n.enumerable});return e};var q=(e,t,r)=>(r=e!=null?Wt(Xt(e)):{},Ke(t||!e||!e.__esModule?J(r,"default",{value:e,enumerable:!0}):r,e)),tr=e=>Ke(J({},"__esModule",{value:!0}),e);var He=W((le,fe)=>{(function(e,t){typeof le=="object"&&typeof fe<"u"?fe.exports=t():typeof define=="function"&&define.amd?define(t):e.typeDetect=t()})(le,function(){"use strict";var e=typeof Promise=="function",t=typeof self=="object"?self:global,r=typeof Symbol<"u",n=typeof Map<"u",f=typeof Set<"u",h=typeof WeakMap<"u",g=typeof WeakSet<"u",i=typeof DataView<"u",y=r&&typeof Symbol.iterator<"u",u=r&&typeof Symbol.toStringTag<"u",a=f&&typeof Set.prototype.entries=="function",s=n&&typeof Map.prototype.entries=="function",p=a&&Object.getPrototypeOf(new Set().entries()),m=s&&Object.getPrototypeOf(new Map().entries()),b=y&&typeof Array.prototype[Symbol.iterator]=="function",v=b&&Object.getPrototypeOf([][Symbol.iterator]()),l=y&&typeof String.prototype[Symbol.iterator]=="function",o=l&&Object.getPrototypeOf(""[Symbol.iterator]()),c=8,d=-1;function O(w){var Ie=typeof w;if(Ie!=="object")return Ie;if(w===null)return"null";if(w===t)return"global";if(Array.isArray(w)&&(u===!1||!(Symbol.toStringTag in w)))return"Array";if(typeof window=="object"&&window!==null){if(typeof window.location=="object"&&w===window.location)return"Location";if(typeof window.document=="object"&&w===window.document)return"Document";if(typeof window.navigator=="object"){if(typeof window.navigator.mimeTypes=="object"&&w===window.navigator.mimeTypes)return"MimeTypeArray";if(typeof window.navigator.plugins=="object"&&w===window.navigator.plugins)return"PluginArray"}if((typeof window.HTMLElement=="function"||typeof window.HTMLElement=="object")&&w instanceof window.HTMLElement){if(w.tagName==="BLOCKQUOTE")return"HTMLQuoteElement";if(w.tagName==="TD")return"HTMLTableDataCellElement";if(w.tagName==="TH")return"HTMLTableHeaderCellElement"}}var Ve=u&&w[Symbol.toStringTag];if(typeof Ve=="string")return Ve;var _=Object.getPrototypeOf(w);return _===RegExp.prototype?"RegExp":_===Date.prototype?"Date":e&&_===Promise.prototype?"Promise":f&&_===Set.prototype?"Set":n&&_===Map.prototype?"Map":g&&_===WeakSet.prototype?"WeakSet":h&&_===WeakMap.prototype?"WeakMap":i&&_===DataView.prototype?"DataView":n&&_===m?"Map Iterator":f&&_===p?"Set Iterator":b&&_===v?"Array Iterator":l&&_===o?"String Iterator":_===null?"Object":Object.prototype.toString.call(w).slice(c,d)}return O})});var Tt=W((F,V)=>{var rr=200,Xe="__lodash_hash_undefined__",ze=9007199254740991,$e="[object Arguments]",nr="[object Array]",et="[object Boolean]",tt="[object Date]",ir="[object Error]",we="[object Function]",rt="[object GeneratorFunction]",Q="[object Map]",nt="[object Number]",Oe="[object Object]",Je="[object Promise]",it="[object RegExp]",Y="[object Set]",ot="[object String]",st="[object Symbol]",he="[object WeakMap]",at="[object ArrayBuffer]",Z="[object DataView]",ct="[object Float32Array]",ut="[object Float64Array]",lt="[object Int8Array]",ft="[object Int16Array]",pt="[object Int32Array]",ht="[object Uint8Array]",gt="[object Uint8ClampedArray]",yt="[object Uint16Array]",dt="[object Uint32Array]",or=/[\\^$.*+?()[\]{}|]/g,sr=/\w*$/,ar=/^\[object .+?Constructor\]$/,cr=/^(?:0|[1-9]\d*)$/,$={};$[$e]=$[nr]=$[at]=$[Z]=$[et]=$[tt]=$[ct]=$[ut]=$[lt]=$[ft]=$[pt]=$[Q]=$[nt]=$[Oe]=$[it]=$[Y]=$[ot]=$[st]=$[ht]=$[gt]=$[yt]=$[dt]=!0;$[ir]=$[we]=$[he]=!1;var ur=typeof global=="object"&&global&&global.Object===Object&&global,lr=typeof self=="object"&&self&&self.Object===Object&&self,x=ur||lr||Function("return this")(),mt=typeof F=="object"&&F&&!F.nodeType&&F,Re=mt&&typeof V=="object"&&V&&!V.nodeType&&V,fr=Re&&Re.exports===mt;function pr(e,t){return e.set(t[0],t[1]),e}function hr(e,t){return e.add(t),e}function gr(e,t){for(var r=-1,n=e?e.length:0;++r<n&&t(e[r],r,e)!==!1;);return e}function yr(e,t){for(var r=-1,n=t.length,f=e.length;++r<n;)e[f+r]=t[r];return e}function bt(e,t,r,n){var f=-1,h=e?e.length:0;for(n&&h&&(r=e[++f]);++f<h;)r=t(r,e[f],f,e);return r}function dr(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}function mr(e,t){return e==null?void 0:e[t]}function $t(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch(r){}return t}function Fe(e){var t=-1,r=Array(e.size);return e.forEach(function(n,f){r[++t]=[f,n]}),r}function Se(e,t){return function(r){return e(t(r))}}function Be(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var br=Array.prototype,$r=Function.prototype,X=Object.prototype,pe=x["__core-js_shared__"],Ge=function(){var e=/[^.]+$/.exec(pe&&pe.keys&&pe.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),wt=$r.toString,C=X.hasOwnProperty,z=X.toString,wr=RegExp("^"+wt.call(C).replace(or,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ue=fr?x.Buffer:void 0,We=x.Symbol,qe=x.Uint8Array,Or=Se(Object.getPrototypeOf,Object),Sr=Object.create,vr=X.propertyIsEnumerable,_r=br.splice,Qe=Object.getOwnPropertySymbols,Ar=Ue?Ue.isBuffer:void 0,Er=Se(Object.keys,Object),ge=M(x,"DataView"),B=M(x,"Map"),ye=M(x,"Promise"),de=M(x,"Set"),me=M(x,"WeakMap"),G=M(Object,"create"),xr=N(ge),Tr=N(B),Cr=N(ye),jr=N(de),Dr=N(me),Ye=We?We.prototype:void 0,Ze=Ye?Ye.valueOf:void 0;function D(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Nr(){this.__data__=G?G(null):{}}function Pr(e){return this.has(e)&&delete this.__data__[e]}function Ir(e){var t=this.__data__;if(G){var r=t[e];return r===Xe?void 0:r}return C.call(t,e)?t[e]:void 0}function Vr(e){var t=this.__data__;return G?t[e]!==void 0:C.call(t,e)}function kr(e,t){var r=this.__data__;return r[e]=G&&t===void 0?Xe:t,this}D.prototype.clear=Nr;D.prototype.delete=Pr;D.prototype.get=Ir;D.prototype.has=Vr;D.prototype.set=kr;function T(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Lr(){this.__data__=[]}function Mr(e){var t=this.__data__,r=ee(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():_r.call(t,r,1),!0}function Kr(e){var t=this.__data__,r=ee(t,e);return r<0?void 0:t[r][1]}function Hr(e){return ee(this.__data__,e)>-1}function Jr(e,t){var r=this.__data__,n=ee(r,e);return n<0?r.push([e,t]):r[n][1]=t,this}T.prototype.clear=Lr;T.prototype.delete=Mr;T.prototype.get=Kr;T.prototype.has=Hr;T.prototype.set=Jr;function k(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Rr(){this.__data__={hash:new D,map:new(B||T),string:new D}}function Fr(e){return te(this,e).delete(e)}function Br(e){return te(this,e).get(e)}function Gr(e){return te(this,e).has(e)}function Ur(e,t){return te(this,e).set(e,t),this}k.prototype.clear=Rr;k.prototype.delete=Fr;k.prototype.get=Br;k.prototype.has=Gr;k.prototype.set=Ur;function L(e){this.__data__=new T(e)}function Wr(){this.__data__=new T}function qr(e){return this.__data__.delete(e)}function Qr(e){return this.__data__.get(e)}function Yr(e){return this.__data__.has(e)}function Zr(e,t){var r=this.__data__;if(r instanceof T){var n=r.__data__;if(!B||n.length<rr-1)return n.push([e,t]),this;r=this.__data__=new k(n)}return r.set(e,t),this}L.prototype.clear=Wr;L.prototype.delete=qr;L.prototype.get=Qr;L.prototype.has=Yr;L.prototype.set=Zr;function Xr(e,t){var r=_e(e)||vn(e)?dr(e.length,String):[],n=r.length,f=!!n;for(var h in e)(t||C.call(e,h))&&!(f&&(h=="length"||$n(h,n)))&&r.push(h);return r}function Ot(e,t,r){var n=e[t];(!(C.call(e,t)&&At(n,r))||r===void 0&&!(t in e))&&(e[t]=r)}function ee(e,t){for(var r=e.length;r--;)if(At(e[r][0],t))return r;return-1}function zr(e,t){return e&&St(t,Ae(t),e)}function be(e,t,r,n,f,h,g){var i;if(n&&(i=h?n(e,f,h,g):n(e)),i!==void 0)return i;if(!re(e))return e;var y=_e(e);if(y){if(i=dn(e),!t)return hn(e,i)}else{var u=j(e),a=u==we||u==rt;if(An(e))return sn(e,t);if(u==Oe||u==$e||a&&!h){if($t(e))return h?e:{};if(i=mn(a?{}:e),!t)return gn(e,zr(i,e))}else{if(!$[u])return h?e:{};i=bn(e,u,be,t)}}g||(g=new L);var s=g.get(e);if(s)return s;if(g.set(e,i),!y)var p=r?yn(e):Ae(e);return gr(p||e,function(m,b){p&&(b=m,m=e[b]),Ot(i,b,be(m,t,r,n,b,e,g))}),i}function en(e){return re(e)?Sr(e):{}}function tn(e,t,r){var n=t(e);return _e(e)?n:yr(n,r(e))}function rn(e){return z.call(e)}function nn(e){if(!re(e)||On(e))return!1;var t=xt(e)||$t(e)?wr:ar;return t.test(N(e))}function on(e){if(!_t(e))return Er(e);var t=[];for(var r in Object(e))C.call(e,r)&&r!="constructor"&&t.push(r);return t}function sn(e,t){if(t)return e.slice();var r=new e.constructor(e.length);return e.copy(r),r}function ve(e){var t=new e.constructor(e.byteLength);return new qe(t).set(new qe(e)),t}function an(e,t){var r=t?ve(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}function cn(e,t,r){var n=t?r(Fe(e),!0):Fe(e);return bt(n,pr,new e.constructor)}function un(e){var t=new e.constructor(e.source,sr.exec(e));return t.lastIndex=e.lastIndex,t}function ln(e,t,r){var n=t?r(Be(e),!0):Be(e);return bt(n,hr,new e.constructor)}function fn(e){return Ze?Object(Ze.call(e)):{}}function pn(e,t){var r=t?ve(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}function hn(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}function St(e,t,r,n){r||(r={});for(var f=-1,h=t.length;++f<h;){var g=t[f],i=n?n(r[g],e[g],g,r,e):void 0;Ot(r,g,i===void 0?e[g]:i)}return r}function gn(e,t){return St(e,vt(e),t)}function yn(e){return tn(e,Ae,vt)}function te(e,t){var r=e.__data__;return wn(t)?r[typeof t=="string"?"string":"hash"]:r.map}function M(e,t){var r=mr(e,t);return nn(r)?r:void 0}var vt=Qe?Se(Qe,Object):Tn,j=rn;(ge&&j(new ge(new ArrayBuffer(1)))!=Z||B&&j(new B)!=Q||ye&&j(ye.resolve())!=Je||de&&j(new de)!=Y||me&&j(new me)!=he)&&(j=function(e){var t=z.call(e),r=t==Oe?e.constructor:void 0,n=r?N(r):void 0;if(n)switch(n){case xr:return Z;case Tr:return Q;case Cr:return Je;case jr:return Y;case Dr:return he}return t});function dn(e){var t=e.length,r=e.constructor(t);return t&&typeof e[0]=="string"&&C.call(e,"index")&&(r.index=e.index,r.input=e.input),r}function mn(e){return typeof e.constructor=="function"&&!_t(e)?en(Or(e)):{}}function bn(e,t,r,n){var f=e.constructor;switch(t){case at:return ve(e);case et:case tt:return new f(+e);case Z:return an(e,n);case ct:case ut:case lt:case ft:case pt:case ht:case gt:case yt:case dt:return pn(e,n);case Q:return cn(e,n,r);case nt:case ot:return new f(e);case it:return un(e);case Y:return ln(e,n,r);case st:return fn(e)}}function $n(e,t){return t=t==null?ze:t,!!t&&(typeof e=="number"||cr.test(e))&&e>-1&&e%1==0&&e<t}function wn(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function On(e){return!!Ge&&Ge in e}function _t(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||X;return e===r}function N(e){if(e!=null){try{return wt.call(e)}catch(t){}try{return e+""}catch(t){}}return""}function Sn(e){return be(e,!0,!0)}function At(e,t){return e===t||e!==e&&t!==t}function vn(e){return _n(e)&&C.call(e,"callee")&&(!vr.call(e,"callee")||z.call(e)==$e)}var _e=Array.isArray;function Et(e){return e!=null&&En(e.length)&&!xt(e)}function _n(e){return xn(e)&&Et(e)}var An=Ar||Cn;function xt(e){var t=re(e)?z.call(e):"";return t==we||t==rt}function En(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=ze}function re(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function xn(e){return!!e&&typeof e=="object"}function Ae(e){return Et(e)?Xr(e):on(e)}function Tn(){return[]}function Cn(){return!1}V.exports=Sn});var Ht=W((Bi,Kt)=>{var Ce="__lodash_hash_undefined__",Dn=9007199254740991,Nn="[object Function]",Pn="[object GeneratorFunction]",In=/[\\^$.*+?()[\]{}|]/g,Vn=/^\[object .+?Constructor\]$/,kn=typeof global=="object"&&global&&global.Object===Object&&global,Ln=typeof self=="object"&&self&&self.Object===Object&&self,Nt=kn||Ln||Function("return this")();function Mn(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function Kn(e,t){var r=e?e.length:0;return!!r&&Rn(e,t,0)>-1}function Hn(e,t,r){for(var n=-1,f=e?e.length:0;++n<f;)if(r(t,e[n]))return!0;return!1}function Pt(e,t){for(var r=-1,n=e?e.length:0,f=Array(n);++r<n;)f[r]=t(e[r],r,e);return f}function Jn(e,t,r,n){for(var f=e.length,h=r+(n?1:-1);n?h--:++h<f;)if(t(e[h],h,e))return h;return-1}function Rn(e,t,r){if(t!==t)return Jn(e,Fn,r);for(var n=r-1,f=e.length;++n<f;)if(e[n]===t)return n;return-1}function Fn(e){return e!==e}function Bn(e){return function(t){return e(t)}}function Ct(e,t){return e.has(t)}function Gn(e,t){return e==null?void 0:e[t]}function Un(e){var t=!1;if(e!=null&&typeof e.toString!="function")try{t=!!(e+"")}catch(r){}return t}var Wn=Array.prototype,qn=Function.prototype,It=Object.prototype,Te=Nt["__core-js_shared__"],jt=function(){var e=/[^.]+$/.exec(Te&&Te.keys&&Te.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),Vt=qn.toString,je=It.hasOwnProperty,Qn=It.toString,Yn=RegExp("^"+Vt.call(je).replace(In,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Zn=Wn.splice,Dt=Math.max,Xn=Math.min,zn=kt(Nt,"Map"),U=kt(Object,"create");function I(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function ei(){this.__data__=U?U(null):{}}function ti(e){return this.has(e)&&delete this.__data__[e]}function ri(e){var t=this.__data__;if(U){var r=t[e];return r===Ce?void 0:r}return je.call(t,e)?t[e]:void 0}function ni(e){var t=this.__data__;return U?t[e]!==void 0:je.call(t,e)}function ii(e,t){var r=this.__data__;return r[e]=U&&t===void 0?Ce:t,this}I.prototype.clear=ei;I.prototype.delete=ti;I.prototype.get=ri;I.prototype.has=ni;I.prototype.set=ii;function K(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function oi(){this.__data__=[]}function si(e){var t=this.__data__,r=oe(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():Zn.call(t,r,1),!0}function ai(e){var t=this.__data__,r=oe(t,e);return r<0?void 0:t[r][1]}function ci(e){return oe(this.__data__,e)>-1}function ui(e,t){var r=this.__data__,n=oe(r,e);return n<0?r.push([e,t]):r[n][1]=t,this}K.prototype.clear=oi;K.prototype.delete=si;K.prototype.get=ai;K.prototype.has=ci;K.prototype.set=ui;function H(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function li(){this.__data__={hash:new I,map:new(zn||K),string:new I}}function fi(e){return se(this,e).delete(e)}function pi(e){return se(this,e).get(e)}function hi(e){return se(this,e).has(e)}function gi(e,t){return se(this,e).set(e,t),this}H.prototype.clear=li;H.prototype.delete=fi;H.prototype.get=pi;H.prototype.has=hi;H.prototype.set=gi;function ie(e){var t=-1,r=e?e.length:0;for(this.__data__=new H;++t<r;)this.add(e[t])}function yi(e){return this.__data__.set(e,Ce),this}function di(e){return this.__data__.has(e)}ie.prototype.add=ie.prototype.push=yi;ie.prototype.has=di;function oe(e,t){for(var r=e.length;r--;)if(Ai(e[r][0],t))return r;return-1}function mi(e,t,r){for(var n=r?Hn:Kn,f=e[0].length,h=e.length,g=h,i=Array(h),y=1/0,u=[];g--;){var a=e[g];g&&t&&(a=Pt(a,Bn(t))),y=Xn(a.length,y),i[g]=!r&&(t||f>=120&&a.length>=120)?new ie(g&&a):void 0}a=e[0];var s=-1,p=i[0];e:for(;++s<f&&u.length<y;){var m=a[s],b=t?t(m):m;if(m=r||m!==0?m:0,!(p?Ct(p,b):n(u,b,r))){for(g=h;--g;){var v=i[g];if(!(v?Ct(v,b):n(e[g],b,r)))continue e}p&&p.push(b),u.push(m)}}return u}function bi(e){if(!Mt(e)||Si(e))return!1;var t=Lt(e)||Un(e)?Yn:Vn;return t.test(vi(e))}function $i(e,t){return t=Dt(t===void 0?e.length-1:t,0),function(){for(var r=arguments,n=-1,f=Dt(r.length-t,0),h=Array(f);++n<f;)h[n]=r[t+n];n=-1;for(var g=Array(t+1);++n<t;)g[n]=r[n];return g[t]=h,Mn(e,this,g)}}function wi(e){return xi(e)?e:[]}function se(e,t){var r=e.__data__;return Oi(t)?r[typeof t=="string"?"string":"hash"]:r.map}function kt(e,t){var r=Gn(e,t);return bi(r)?r:void 0}function Oi(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Si(e){return!!jt&&jt in e}function vi(e){if(e!=null){try{return Vt.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var _i=$i(function(e){var t=Pt(e,wi);return t.length&&t[0]===e[0]?mi(t):[]});function Ai(e,t){return e===t||e!==e&&t!==t}function Ei(e){return e!=null&&Ti(e.length)&&!Lt(e)}function xi(e){return Ci(e)&&Ei(e)}function Lt(e){var t=Mt(e)?Qn.call(e):"";return t==Nn||t==Pn}function Ti(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Dn}function Mt(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function Ci(e){return!!e&&typeof e=="object"}Kt.exports=_i});var Rt=W((Jt,ae)=>{(function(e,t){"use strict";typeof ae=="object"&&typeof ae.exports=="object"?ae.exports=t():typeof define=="function"&&define.amd?define([],t):e.objectPath=t()})(Jt,function(){"use strict";var e=Object.prototype.toString;function t(a,s){return a==null?!1:Object.prototype.hasOwnProperty.call(a,s)}function r(a){if(!a||h(a)&&a.length===0)return!0;if(typeof a!="string"){for(var s in a)if(t(a,s))return!1;return!0}return!1}function n(a){return e.call(a)}function f(a){return typeof a=="object"&&n(a)==="[object Object]"}var h=Array.isArray||function(a){return e.call(a)==="[object Array]"};function g(a){return typeof a=="boolean"||n(a)==="[object Boolean]"}function i(a){var s=parseInt(a);return s.toString()===a?s:a}function y(a){a=a||{};var s=function(l){return Object.keys(s).reduce(function(o,c){return c==="create"||typeof s[c]=="function"&&(o[c]=s[c].bind(s,l)),o},{})},p;a.includeInheritedProps?p=function(){return!0}:p=function(l,o){return typeof o=="number"&&Array.isArray(l)||t(l,o)};function m(l,o){if(p(l,o))return l[o]}var b;a.includeInheritedProps?b=function(l,o){typeof o!="string"&&typeof o!="number"&&(o=String(o));var c=m(l,o);if(o==="__proto__"||o==="prototype"||o==="constructor"&&typeof c=="function")throw new Error("For security reasons, object's magic properties cannot be set");return c}:b=function(l,o){return m(l,o)};function v(l,o,c,d){if(typeof o=="number"&&(o=[o]),!o||o.length===0)return l;if(typeof o=="string")return v(l,o.split(".").map(i),c,d);var O=o[0],w=b(l,O);return o.length===1?((w===void 0||!d)&&(l[O]=c),w):(w===void 0&&(typeof o[1]=="number"?l[O]=[]:l[O]={}),v(l[O],o.slice(1),c,d))}return s.has=function(l,o){if(typeof o=="number"?o=[o]:typeof o=="string"&&(o=o.split(".")),!o||o.length===0)return!!l;for(var c=0;c<o.length;c++){var d=i(o[c]);if(typeof d=="number"&&h(l)&&d<l.length||(a.includeInheritedProps?d in Object(l):t(l,d)))l=l[d];else return!1}return!0},s.ensureExists=function(l,o,c){return v(l,o,c,!0)},s.set=function(l,o,c,d){return v(l,o,c,d)},s.insert=function(l,o,c,d){var O=s.get(l,o);d=~~d,h(O)||(O=[],s.set(l,o,O)),O.splice(d,0,c)},s.empty=function(l,o){if(!r(o)&&l!=null){var c,d;if(c=s.get(l,o)){if(typeof c=="string")return s.set(l,o,"");if(g(c))return s.set(l,o,!1);if(typeof c=="number")return s.set(l,o,0);if(h(c))c.length=0;else if(f(c))for(d in c)p(c,d)&&delete c[d];else return s.set(l,o,null)}}},s.push=function(l,o){var c=s.get(l,o);h(c)||(c=[],s.set(l,o,c)),c.push.apply(c,Array.prototype.slice.call(arguments,2))},s.coalesce=function(l,o,c){for(var d,O=0,w=o.length;O<w;O++)if((d=s.get(l,o[O]))!==void 0)return d;return c},s.get=function(l,o,c){if(typeof o=="number"&&(o=[o]),!o||o.length===0)return l;if(l==null)return c;if(typeof o=="string")return s.get(l,o.split("."),c);var d=i(o[0]),O=b(l,d);return O===void 0?c:o.length===1?O:s.get(l[d],o.slice(1),c)},s.del=function(o,c){if(typeof c=="number"&&(c=[c]),o==null||r(c))return o;if(typeof c=="string")return s.del(o,c.split("."));var d=i(c[0]);if(b(o,d),!p(o,d))return o;if(c.length===1)h(o)?o.splice(d,1):delete o[d];else return s.del(o[d],c.slice(1));return o},s}var u=y();return u.create=y,u.withInheritedProps=y({includeInheritedProps:!0}),u})});var ki={};er(ki,{checkTypesMini:()=>Vi,defaults:()=>Ut,version:()=>Pi});var S=q(He(),1);var ne=q(Tt(),1);function E(e){if(e==null||typeof e!="object")return!1;let t=Object.getPrototypeOf(e);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null?!1:!(Symbol.iterator in e)&&!(Symbol.toStringTag in e)}function P(e=[],t=[]){return!e||!Array.isArray(e)||!e.length?[]:!t||!Array.isArray(t)||!t.length?e:e.filter(r=>!t.includes(r))}function jn(e){if(e.includes(".")){let t=e.lastIndexOf(".");if(!e.slice(0,t).includes("."))return e.slice(0,t);for(let r=t-1;r--;)if(e[r]===".")return e.slice(r+1,t)}return null}var Ee=jn;function xe(e,t){let r={now:!1};function n(f,h,g,i){let y=(0,ne.default)(f),u,a=A({depth:-1,path:""},g);if(a.depth+=1,Array.isArray(y))for(let s=0,p=y.length;s<p&&!i.now;s++){let m=a.path?`${a.path}.${s}`:`${s}`;y[s]!==void 0?(a.parent=(0,ne.default)(y),a.parentType="array",a.parentKey=Ee(m),u=n(h(y[s],void 0,R(A({},a),{path:m}),i),h,R(A({},a),{path:m}),i),Number.isNaN(u)&&s<y.length?(y.splice(s,1),s-=1):y[s]=u):y.splice(s,1)}else if(E(y))for(let s in y){if(i.now&&s!=null)break;let p=a.path?`${a.path}.${s}`:s;a.depth===0&&s!=null&&(a.topmostKey=s),a.parent=(0,ne.default)(y),a.parentType="object",a.parentKey=Ee(p),u=n(h(s,y[s],R(A({},a),{path:p}),i),h,R(A({},a),{path:p}),i),Number.isNaN(u)?delete y[s]:y[s]=u}return y}return n(e,t,{},r)}var Gt=q(Ht(),1);function De(e){return typeof e!="string"?e:e.length?[e]:[]}var ue=q(Rt(),1);function Ne(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}var Pe=new Map,Ft=(e,t)=>{if(!Array.isArray(e))switch(typeof e){case"string":e=[e];break;case"undefined":e=[];break;default:throw new TypeError(`Expected '${t}' to be a string or an array, but got a type of '${typeof e}'`)}return e.filter(r=>{if(typeof r!="string"){if(typeof r>"u")return!1;throw new TypeError(`Expected '${t}' to be an array of strings, but found a type of '${typeof r}' in the array`)}return!0})},ji=(e,t)=>{t=A({caseSensitive:!1},t);let r=e+JSON.stringify(t);if(Pe.has(r))return Pe.get(r);let n=e[0]==="!";n&&(e=e.slice(1)),e=Ne(e).replace(/\\\*/g,"[\\s\\S]*");let f=new RegExp(`^${e}$`,t.caseSensitive?"":"i");return f.negated=n,Pe.set(r,f),f},Di=(e,t,r,n)=>{if(e=Ft(e,"inputs"),t=Ft(t,"patterns"),t.length===0)return[];t=t.map(g=>ji(g,r));let{allPatterns:f}=r||{},h=[];for(let g of e){let i,y=[...t].fill(!1);for(let[u,a]of t.entries())if(a.test(g)&&(y[u]=!0,i=!a.negated,!i))break;if(!(i===!1||i===void 0&&t.some(u=>!u.negated)||f&&y.some((u,a)=>!u&&!t[a].negated))&&(h.push(g),n))break}return h};function ce(e,t,r){return Di(e,t,r,!0).length>0}var Bt="8.0.9";var Pi=Bt,Ut={ignoreKeys:[],ignorePaths:[],acceptArrays:!1,acceptArraysIgnore:[],enforceStrictKeyset:!0,schema:{},msg:"check-types-mini",optsVarName:"opts"};function Ii(e,t,r){function n(u){return u!=null}function f(u,a){return typeof a=="string"&&(a=De(a)),Array.from(u).filter(s=>!a.some(p=>ce(s,p,{caseSensitive:!0})))}let h=Object.prototype.hasOwnProperty,g=["any","anything","every","everything","all","whatever","whatevs"];if(!n(e))throw new Error("check-types-mini: [THROW_ID_01] First argument is missing!");let i=A(A({},Ut),r);if(typeof i.ignoreKeys=="string"&&(i.ignoreKeys=[i.ignoreKeys]),typeof i.ignorePaths=="string"&&(i.ignorePaths=[i.ignorePaths]),typeof i.acceptArraysIgnore=="string"&&(i.acceptArraysIgnore=[i.acceptArraysIgnore]),i.msg=`${i.msg}`.trim(),i.msg[i.msg.length-1]===":"&&(i.msg=i.msg.slice(0,i.msg.length-1).trim()),E(i.schema))Object.keys(i.schema).forEach(u=>{if(E(i.schema[u])){let a={};xe(i.schema[u],(s,p,m)=>{let b=p!==void 0?p:s;return!Array.isArray(b)&&!E(b)&&(a[`${u}.${m.path}`]=b),b}),delete i.schema[u],i.schema=A(A({},i.schema),a)}}),Object.keys(i.schema).forEach(u=>{Array.isArray(i.schema[u])||(i.schema[u]=[i.schema[u]]),i.schema[u]=i.schema[u].map(a=>`${a}`.toLowerCase().trim())});else if(i.schema!=null)throw new Error(`check-types-mini: opts.schema was customised to ${JSON.stringify(i.schema,null,0)} which is not object but ${typeof i.schema}`);if(n(t)||(t={}),i.enforceStrictKeyset)if(n(i.schema)&&Object.keys(i.schema).length){if(t&&f(P(Object.keys(e),Object.keys(t).concat(Object.keys(i.schema))),i.ignoreKeys).length){let u=P(Object.keys(e),Object.keys(t).concat(Object.keys(i.schema)));throw new TypeError(`${i.msg}: ${i.optsVarName}.enforceStrictKeyset is on and the following key${u.length>1?"s":""} ${u.length>1?"are":"is"} not covered by schema and/or reference objects: ${u.join(", ")}`)}}else if(E(t)&&Object.keys(t).length){if(f(P(Object.keys(e),Object.keys(t)),i.ignoreKeys).length!==0){let u=P(Object.keys(e),Object.keys(t));throw new TypeError(`${i.msg}: The input object has key${u.length>1?"s":""} which ${u.length>1?"are":"is"} not covered by the reference object: ${u.join(", ")}`)}else if(f(P(Object.keys(t),Object.keys(e)),i.ignoreKeys).length!==0){let u=P(Object.keys(t),Object.keys(e));throw new TypeError(`${i.msg}: The reference object has key${u.length>1?"s":""} which ${u.length>1?"are":"is"} not present in the input object: ${u.join(", ")}`)}}else throw new TypeError(`${i.msg}: Both ${i.optsVarName}.schema and reference objects are missing! We don't have anything to match the keys as you requested via resolvedOpts.enforceStrictKeyset!`);let y=[];xe(e,(u,a,s)=>{let p=a,m=u;if(s.parentType==="array"&&(m=void 0,p=u),Array.isArray(y)&&y.length&&y.some(o=>s.path.startsWith(o))||m&&i.ignoreKeys.some(o=>m&&ce(m,o))||i.ignorePaths.some(o=>ce(s.path,o)))return p;let b=!(!E(p)&&!Array.isArray(p)&&Array.isArray(s.parent)),v=!1;E(i.schema)&&h.call(i.schema,s.path)&&(v=!0);let l=!1;if(E(t)&&ue.default.has(t,s.path)&&(l=!0),i.enforceStrictKeyset&&b&&!v&&!l)throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path} is neither covered by reference object (second input argument), nor ${i.optsVarName}.schema! To stop this error, turn off ${i.optsVarName}.enforceStrictKeyset or provide some type reference (2nd argument or ${i.optsVarName}.schema).
11
11
 
12
12
  Debug info:
13
13
 
@@ -19,13 +19,13 @@ innerObj = ${JSON.stringify(s,null,4)}
19
19
 
20
20
  resolvedOpts = ${JSON.stringify(i,null,4)}
21
21
 
22
- current = ${JSON.stringify(h,null,4)}
22
+ current = ${JSON.stringify(p,null,4)}
23
23
 
24
- `);if(v){let o=De(i.schema[s.path]).map(u=>`${u}`.toLowerCase());if(ue.default.set(i.schema,s.path,o),(0,Qt.default)(o,y).length)g.push(s.path);else if(h!==!0&&h!==!1&&!o.includes((0,S.default)(h).toLowerCase())||(h===!0||h===!1)&&!o.includes(String(h))&&!o.includes("boolean"))if(Array.isArray(h)&&i.acceptArrays){for(let u=0,d=h.length;u<d;u++)if(!o.includes((0,S.default)(h[u]).toLowerCase()))throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path}.${u}, the ${u}th element (equal to ${JSON.stringify(h[u],null,0)}) is of a type ${(0,S.default)(h[u]).toLowerCase()}, but only the following are allowed by the ${i.optsVarName}.schema: ${o.join(", ")}`)}else throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path} was customised to ${(0,S.default)(h)!=="string"?'"':""}${JSON.stringify(h,null,0)}${(0,S.default)(h)!=="string"?'"':""} (type: ${(0,S.default)(h).toLowerCase()}) which is not among the allowed types in schema (which is equal to ${JSON.stringify(o,null,0)})`)}else if(t&&E(t)&&f){let o=ue.default.get(t,s.path);if(i.acceptArrays&&Array.isArray(h)&&!i.acceptArraysIgnore.includes(l)){if(!h.every(d=>(0,S.default)(d).toLowerCase()===(0,S.default)(t[l]).toLowerCase()))throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path} was customised to be array, but not all of its elements are ${(0,S.default)(t[l]).toLowerCase()}-type`)}else if((0,S.default)(h)!==(0,S.default)(o))throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path} was customised to ${(0,S.default)(h).toLowerCase()==="string"?"":'"'}${JSON.stringify(h,null,0)}${(0,S.default)(h).toLowerCase()==="string"?"":'"'} which is not ${(0,S.default)(o).toLowerCase()} but ${(0,S.default)(h).toLowerCase()}`)}return h})}function Qi(e,t,r){Wi(e,t,r)}return ir(qi);})();
24
+ `);if(v){let o=De(i.schema[s.path]).map(c=>`${c}`.toLowerCase());if(ue.default.set(i.schema,s.path,o),(0,Gt.default)(o,g).length)y.push(s.path);else if(p!==!0&&p!==!1&&!o.includes((0,S.default)(p).toLowerCase())||(p===!0||p===!1)&&!o.includes(String(p))&&!o.includes("boolean"))if(Array.isArray(p)&&i.acceptArrays){for(let c=0,d=p.length;c<d;c++)if(!o.includes((0,S.default)(p[c]).toLowerCase()))throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path}.${c}, the ${c}th element (equal to ${JSON.stringify(p[c],null,0)}) is of a type ${(0,S.default)(p[c]).toLowerCase()}, but only the following are allowed by the ${i.optsVarName}.schema: ${o.join(", ")}`)}else throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path} was customised to ${(0,S.default)(p)!=="string"?'"':""}${JSON.stringify(p,null,0)}${(0,S.default)(p)!=="string"?'"':""} (type: ${(0,S.default)(p).toLowerCase()}) which is not among the allowed types in schema (which is equal to ${JSON.stringify(o,null,0)})`)}else if(t&&E(t)&&l){let o=ue.default.get(t,s.path);if(i.acceptArrays&&Array.isArray(p)&&!i.acceptArraysIgnore.includes(u)){if(!p.every(d=>(0,S.default)(d).toLowerCase()===(0,S.default)(t[u]).toLowerCase()))throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path} was customised to be array, but not all of its elements are ${(0,S.default)(t[u]).toLowerCase()}-type`)}else if((0,S.default)(p)!==(0,S.default)(o))throw new TypeError(`${i.msg}: ${i.optsVarName}.${s.path} was customised to ${(0,S.default)(p).toLowerCase()==="string"?"":'"'}${JSON.stringify(p,null,0)}${(0,S.default)(p).toLowerCase()==="string"?"":'"'} which is not ${(0,S.default)(o).toLowerCase()} but ${(0,S.default)(p).toLowerCase()}`)}return p})}function Vi(e,t,r){Ii(e,t,r)}return tr(ki);})();
25
25
  /**
26
26
  * @name codsen-utils
27
27
  * @fileoverview Various utility functions
28
- * @version 1.2.0
28
+ * @version 1.3.0
29
29
  * @author Roy Revelt, Codsen Ltd
30
30
  * @license MIT
31
31
  * {@link https://codsen.com/os/codsen-utils/}
@@ -33,7 +33,7 @@ current = ${JSON.stringify(h,null,4)}
33
33
  /**
34
34
  * @name ast-monkey-util
35
35
  * @fileoverview Utility library of AST helper functions
36
- * @version 3.0.3
36
+ * @version 3.0.4
37
37
  * @author Roy Revelt, Codsen Ltd
38
38
  * @license MIT
39
39
  * {@link https://codsen.com/os/ast-monkey-util/}
@@ -41,7 +41,7 @@ current = ${JSON.stringify(h,null,4)}
41
41
  /**
42
42
  * @name ast-monkey-traverse
43
43
  * @fileoverview Utility library to traverse AST
44
- * @version 4.0.6
44
+ * @version 4.0.7
45
45
  * @author Roy Revelt, Codsen Ltd
46
46
  * @license MIT
47
47
  * {@link https://codsen.com/os/ast-monkey-traverse/}
@@ -49,7 +49,7 @@ current = ${JSON.stringify(h,null,4)}
49
49
  /**
50
50
  * @name arrayiffy-if-string
51
51
  * @fileoverview Put non-empty strings into arrays, turn empty-ones into empty arrays. Bypass everything else.
52
- * @version 5.0.3
52
+ * @version 5.0.4
53
53
  * @author Roy Revelt, Codsen Ltd
54
54
  * @license MIT
55
55
  * {@link https://codsen.com/os/arrayiffy-if-string/}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "check-types-mini",
3
- "version": "8.0.7",
3
+ "version": "8.0.9",
4
4
  "description": "Validate options object",
5
5
  "keywords": [
6
6
  "compare",
@@ -72,17 +72,15 @@
72
72
  }
73
73
  },
74
74
  "dependencies": {
75
- "arrayiffy-if-string": "^5.0.3",
76
- "ast-monkey-traverse": "^4.0.6",
77
- "codsen-utils": "^1.2.0",
75
+ "arrayiffy-if-string": "^5.0.4",
76
+ "ast-monkey-traverse": "^4.0.7",
77
+ "codsen-utils": "^1.3.0",
78
78
  "lodash.intersection": "^4.4.0",
79
- "lodash.pullall": "^4.2.0",
80
79
  "matcher": "^5.0.0",
81
80
  "object-path": "^0.11.8",
82
81
  "type-detect": "^4.0.8"
83
82
  },
84
83
  "devDependencies": {
85
- "@types/lodash.intersection": "^4.4.7",
86
- "@types/lodash.pullall": "^4.2.7"
84
+ "@types/lodash.intersection": "^4.4.7"
87
85
  }
88
86
  }