@redocly/cli 2.56.0 → 2.56.1

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.
Files changed (132) hide show
  1. package/THIRD_PARTY_NOTICES +14 -30
  2. package/lib/chunks/{7MISZQY2.js → 25UBBA3J.js} +1 -1
  3. package/lib/chunks/{LGQZK7NR.js → 2KLHD2U7.js} +1 -1
  4. package/lib/chunks/{N2D5LLBV.js → 2M6C5LHI.js} +1 -1
  5. package/lib/chunks/{P43DKA2E.js → 2UTQDU6B.js} +1 -1
  6. package/lib/chunks/{BDCNFVGZ.js → 35XUUJLG.js} +1 -1
  7. package/lib/chunks/{DXEOF3IX.js → 3W3OLLTF.js} +1 -1
  8. package/lib/chunks/4PTNG4EI.js +7 -0
  9. package/lib/chunks/{3L35HFJG.js → 5CEXCXYZ.js} +1 -1
  10. package/lib/chunks/{MWNK3IKD.js → 5TJ3WQMW.js} +1 -1
  11. package/lib/chunks/64G5RPLP.js +7 -0
  12. package/lib/chunks/{YJ2CV2FV.js → 6BC7FVBU.js} +1 -1
  13. package/lib/chunks/{RDLDTF4L.js → 7ARFLNUA.js} +1 -1
  14. package/lib/chunks/{5KSMVZSO.js → 7QLACFLT.js} +1 -1
  15. package/lib/chunks/{XKNG65W6.js → A5VZWAMI.js} +1 -1
  16. package/lib/chunks/{ZQHPJPJ2.js → ALAAZCRE.js} +1 -1
  17. package/lib/chunks/{BH4SKQ6M.js → BNT5BXON.js} +1 -1
  18. package/lib/chunks/CXUJFJ3V.js +11 -0
  19. package/lib/chunks/{UQHIGGP6.js → D7OG7544.js} +1 -1
  20. package/lib/chunks/{E2KKD73B.js → DCVTFQBO.js} +1 -1
  21. package/lib/chunks/{LPB2X45H.js → DJ2P263F.js} +1 -1
  22. package/lib/chunks/DLPIGJ4V.js +14 -0
  23. package/lib/chunks/{N2FNYVCN.js → E5XZY3Q2.js} +1 -1
  24. package/lib/chunks/{EJXJAU3Z.js → FUETBXGV.js} +1 -1
  25. package/lib/chunks/{QKT4AI5U.js → FX2A3GCS.js} +1 -1
  26. package/lib/chunks/{FTARAJQN.js → G47ZYA3C.js} +1 -1
  27. package/lib/chunks/GHSNC2OX.js +9 -0
  28. package/lib/chunks/HBUZKWXC.js +7 -0
  29. package/lib/chunks/HDOITPQ3.js +20 -0
  30. package/lib/chunks/{3R32Y5ZJ.js → HJZMPHXS.js} +1 -1
  31. package/lib/chunks/{AOFLS3JM.js → HSBHQBL2.js} +2 -2
  32. package/lib/chunks/I6CD22RU.js +10 -0
  33. package/lib/chunks/{DSD57XD4.js → I7GIWE3P.js} +1 -1
  34. package/lib/chunks/IGD6TJGQ.js +34 -0
  35. package/lib/chunks/{UTZVN6YA.js → IRZBI5PN.js} +1 -1
  36. package/lib/chunks/ISV7E3WY.js +29 -0
  37. package/lib/chunks/IXUAYOCK.js +18 -0
  38. package/lib/chunks/{6WNK6ZW5.js → JO2R43LS.js} +1 -1
  39. package/lib/chunks/{O64VVDHW.js → M3P4YXWZ.js} +1 -1
  40. package/lib/chunks/{NPBKCM7B.js → MB5P3K2R.js} +1 -1
  41. package/lib/chunks/MGBZEDQJ.js +45 -0
  42. package/lib/chunks/{FKC3B2RN.js → MRVYTOFX.js} +1 -1
  43. package/lib/chunks/{RZ6XOBIA.js → MS356BQ6.js} +1 -1
  44. package/lib/chunks/{NHMYQF3F.js → MTHNGTMB.js} +1 -1
  45. package/lib/chunks/{MGMNYFOR.js → MU74CSJJ.js} +2 -2
  46. package/lib/chunks/{VM6OOWSF.js → NV7DJMMF.js} +1 -1
  47. package/lib/chunks/{JADJJP6R.js → OGD5QBKV.js} +1 -1
  48. package/lib/chunks/{SH75MWAC.js → OKP4XLDY.js} +1 -1
  49. package/lib/chunks/{ARIBTVNO.js → P6LCRZC4.js} +1 -1
  50. package/lib/chunks/PIMM4UUT.js +9 -0
  51. package/lib/chunks/{TC3EIKUK.js → PJRRECUU.js} +1 -1
  52. package/lib/chunks/QAC4XUNG.js +14 -0
  53. package/lib/chunks/{7BAI3GZ5.js → R5EOHC5A.js} +4 -4
  54. package/lib/chunks/{QXIVVOOR.js → RAZQQ2DW.js} +1 -1
  55. package/lib/chunks/SJHPKWSD.js +9 -0
  56. package/lib/chunks/{JDBGRKTP.js → SRIYNICE.js} +1 -1
  57. package/lib/chunks/{HOUAVEH6.js → T3LLCSAJ.js} +1 -1
  58. package/lib/chunks/TWIJOWYT.js +7 -0
  59. package/lib/chunks/U5DIFWGH.js +7 -0
  60. package/lib/chunks/{7IULUVWX.js → UF2ZCH7W.js} +1 -1
  61. package/lib/chunks/{UNHSYVDZ.js → UVP374Z3.js} +1 -1
  62. package/lib/chunks/{DOJW7C4M.js → VCODEISK.js} +2 -2
  63. package/lib/chunks/VD6XNXNY.js +7 -0
  64. package/lib/chunks/VMGZLFL4.js +11 -0
  65. package/lib/chunks/{ZHK7GAOT.js → VTGQPPGI.js} +1 -1
  66. package/lib/chunks/VUKQLVFA.js +10 -0
  67. package/lib/chunks/W5WXQVTO.js +13 -0
  68. package/lib/chunks/{TVL6DMBV.js → XACYMDME.js} +3 -3
  69. package/lib/chunks/{WUXDP2A3.js → XJ7LVK2B.js} +1 -1
  70. package/lib/chunks/XJSNA6VQ.js +119 -0
  71. package/lib/chunks/{ICOYFJR4.js → XXP75TZV.js} +1 -1
  72. package/lib/chunks/YW2GBLJX.js +7 -0
  73. package/lib/chunks/{GORWWTSA.js → Z22TFV6U.js} +1 -1
  74. package/lib/chunks/{ISBVQBNS.js → ZCIVIBWW.js} +1 -1
  75. package/lib/chunks/ZOVYQ36P.js +193 -0
  76. package/lib/eject-assets/generators/cli/docs.ts +1 -1
  77. package/lib/eject-assets/generators/cli/engine-source.ts +1 -1
  78. package/lib/eject-assets/generators/cli/index.ts +2 -2
  79. package/lib/eject-assets/generators/cli/render.ts +1 -1
  80. package/lib/eject-assets/generators/go/client.ts +1 -1
  81. package/lib/eject-assets/generators/go/descriptor.ts +1 -1
  82. package/lib/eject-assets/generators/go/index.ts +2 -2
  83. package/lib/eject-assets/generators/go/models.ts +1 -1
  84. package/lib/eject-assets/generators/go/naming.ts +1 -1
  85. package/lib/eject-assets/generators/go/operations.ts +1 -1
  86. package/lib/eject-assets/generators/go/pagination.ts +1 -1
  87. package/lib/eject-assets/generators/go/types.ts +1 -1
  88. package/lib/eject-assets/generators/mock/faker.ts +1 -1
  89. package/lib/eject-assets/generators/mock/index.ts +2 -2
  90. package/lib/eject-assets/generators/mock/render.ts +1 -1
  91. package/lib/eject-assets/generators/mock/sample.ts +1 -1
  92. package/lib/eject-assets/generators/mock/values.ts +1 -1
  93. package/lib/eject-assets/generators/php/client.ts +1 -1
  94. package/lib/eject-assets/generators/php/descriptor.ts +1 -1
  95. package/lib/eject-assets/generators/php/index.ts +2 -2
  96. package/lib/eject-assets/generators/php/models.ts +1 -1
  97. package/lib/eject-assets/generators/php/naming.ts +1 -1
  98. package/lib/eject-assets/generators/php/operations.ts +1 -1
  99. package/lib/eject-assets/generators/php/pagination.ts +1 -1
  100. package/lib/eject-assets/generators/php/types.ts +1 -1
  101. package/lib/eject-assets/generators/python/client.ts +1 -1
  102. package/lib/eject-assets/generators/python/descriptor.ts +1 -1
  103. package/lib/eject-assets/generators/python/index.ts +2 -2
  104. package/lib/eject-assets/generators/python/models.ts +1 -1
  105. package/lib/eject-assets/generators/python/naming.ts +1 -1
  106. package/lib/eject-assets/generators/python/operations.ts +1 -1
  107. package/lib/eject-assets/generators/python/pagination.ts +1 -1
  108. package/lib/eject-assets/generators/python/types.ts +1 -1
  109. package/lib/eject-assets/generators/swr/index.ts +2 -2
  110. package/lib/eject-assets/generators/swr/render.ts +1 -1
  111. package/lib/eject-assets/generators/tanstack-query/index.ts +2 -2
  112. package/lib/eject-assets/generators/tanstack-query/render.ts +1 -1
  113. package/lib/eject-assets/generators/transformers/index.ts +2 -2
  114. package/lib/eject-assets/generators/transformers/render.ts +1 -1
  115. package/lib/eject-assets/generators/typescript/banner.ts +1 -1
  116. package/lib/eject-assets/generators/typescript/client.ts +1 -1
  117. package/lib/eject-assets/generators/typescript/descriptor.ts +1 -1
  118. package/lib/eject-assets/generators/typescript/index.ts +2 -2
  119. package/lib/eject-assets/generators/typescript/inline-runtime.ts +1 -1
  120. package/lib/eject-assets/generators/typescript/operation-signature.ts +1 -1
  121. package/lib/eject-assets/generators/typescript/operation-types.ts +1 -1
  122. package/lib/eject-assets/generators/typescript/operations.ts +1 -1
  123. package/lib/eject-assets/generators/typescript/response-headers.ts +1 -1
  124. package/lib/eject-assets/generators/typescript/type-guards.ts +1 -1
  125. package/lib/eject-assets/generators/typescript/types.ts +1 -1
  126. package/lib/eject-assets/generators/zod/index.ts +2 -2
  127. package/lib/eject-assets/generators/zod/schemas.ts +1 -1
  128. package/lib/index.js +78 -293
  129. package/package.json +1 -1
  130. package/lib/chunks/EVTLV6L3.js +0 -13
  131. package/lib/chunks/M4FV4I2Z.js +0 -47
  132. package/lib/chunks/UVKEIQXW.js +0 -193
@@ -0,0 +1,9 @@
1
+ import { createRequire as __createRequire } from 'node:module';
2
+ import { fileURLToPath as __fileURLToPath } from 'node:url';
3
+ import { dirname as __pathDirname } from 'node:path';
4
+ const require = __createRequire(import.meta.url);
5
+ var __filename = __fileURLToPath(import.meta.url);
6
+ var __dirname = __pathDirname(__filename);
7
+ import"./RFWIIJFG.js";import{fileURLToPath as es}from"node:url";import{posix as hs,win32 as _t}from"node:path";import{fileURLToPath as ns}from"node:url";import{lstatSync as os,readdir as ls,readdirSync as as,readlinkSync as cs,realpathSync as us}from"fs";import*as ps from"node:fs";import{lstat as fs,readdir as ds,readlink as gs,realpath as ws}from"node:fs/promises";import{EventEmitter as Bt}from"node:events";import Re from"node:stream";import{StringDecoder as ms}from"node:string_decoder";var fe=(t,e,i)=>{let s=t instanceof RegExp?It(t,i):t,r=e instanceof RegExp?It(e,i):e,h=s!==null&&r!=null&&Qe(s,r,i);return h&&{start:h[0],end:h[1],pre:i.slice(0,h[0]),body:i.slice(h[0]+s.length,h[1]),post:i.slice(h[1]+r.length)}},It=(t,e)=>{let i=e.match(t);return i?i[0]:null},Qe=(t,e,i)=>{let s,r,h,n,o,l=i.indexOf(t),a=i.indexOf(e,l+1),u=l;if(l>=0&&a>0){if(t===e)return[l,a];for(s=[],h=i.length;u>=0&&!o;){if(u===l)s.push(u),l=i.indexOf(t,u+1);else if(s.length===1){let c=s.pop();c!==void 0&&(o=[c,a])}else r=s.pop(),r!==void 0&&r<h&&(h=r,n=a),a=i.indexOf(e,u+1);u=l<a&&l>=0?l:a}s.length&&n!==void 0&&(o=[h,n])}return o},de="\0SLASH"+Math.random()+"\0",ge="\0OPEN"+Math.random()+"\0",Nt="\0CLOSE"+Math.random()+"\0",we="\0COMMA"+Math.random()+"\0",me="\0PERIOD"+Math.random()+"\0",ti=new RegExp(de,"g"),ei=new RegExp(ge,"g"),ii=new RegExp(Nt,"g"),si=new RegExp(we,"g"),ri=new RegExp(me,"g"),hi=/\\\\/g,ni=/\\{/g,oi=/\\}/g,li=/\\,/g,ai=/\\./g,ci=1e5;function Rt(t){return isNaN(t)?t.charCodeAt(0):parseInt(t,10)}function ui(t){return t.replace(hi,de).replace(ni,ge).replace(oi,Nt).replace(li,we).replace(ai,me)}function pi(t){return t.replace(ti,"\\").replace(ei,"{").replace(ii,"}").replace(si,",").replace(ri,".")}function ye(t){if(!t)return[""];let e=[],i=fe("{","}",t);if(!i)return t.split(",");let{pre:s,body:r,post:h}=i,n=s.split(",");n[n.length-1]+="{"+r+"}";let o=ye(h);return h.length&&(n[n.length-1]+=o.shift(),n.push.apply(n,o)),e.push.apply(e,n),e}function fi(t,e={}){if(!t)return[];let{max:i=ci}=e;return t.slice(0,2)==="{}"&&(t="\\{\\}"+t.slice(2)),ot(ui(t),i,!0).map(pi)}function di(t){return"{"+t+"}"}function gi(t){return/^-?0\d/.test(t)}function wi(t,e){return t<=e}function mi(t,e){return t>=e}function ot(t,e,i){let s=[],r=fe("{","}",t);if(!r)return[t];let h=r.pre,n=r.post.length?ot(r.post,e,!1):[""];if(/\$$/.test(r.pre))for(let o=0;o<n.length&&o<e;o++){let l=h+"{"+r.body+"}"+n[o];s.push(l)}else{let o=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(r.body),l=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(r.body),a=o||l,u=r.body.indexOf(",")>=0;if(!a&&!u)return r.post.match(/,(?!,).*\}/)?(t=r.pre+"{"+r.body+Nt+r.post,ot(t,e,!0)):[t];let c;if(a)c=r.body.split(/\.\./);else if(c=ye(r.body),c.length===1&&c[0]!==void 0&&(c=ot(c[0],e,!1).map(di),c.length===1))return n.map(p=>r.pre+c[0]+p);let f;if(a&&c[0]!==void 0&&c[1]!==void 0){let p=Rt(c[0]),d=Rt(c[1]),g=Math.max(c[0].length,c[1].length),m=c.length===3&&c[2]!==void 0?Math.abs(Rt(c[2])):1,w=wi;d<p&&(m*=-1,w=mi);let y=c.some(gi);f=[];for(let b=p;w(b,d);b+=m){let S;if(l)S=String.fromCharCode(b),S==="\\"&&(S="");else if(S=String(b),y){let v=g-S.length;if(v>0){let U=new Array(v+1).join("0");b<0?S="-"+U+S.slice(1):S=U+S}}f.push(S)}}else{f=[];for(let p=0;p<c.length;p++)f.push.apply(f,ot(c[p],e,!1))}for(let p=0;p<f.length;p++)for(let d=0;d<n.length&&s.length<e;d++){let g=h+f[p]+n[d];(!i||a||g)&&s.push(g)}}return s}var Et=t=>{if(typeof t!="string")throw new TypeError("invalid pattern");if(t.length>65536)throw new TypeError("pattern is too long")},yi={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},et=t=>t.replace(/[[\]\\-]/g,"\\$&"),bi=t=>t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),Ht=t=>t.join(""),Si=(t,e)=>{let i=e;if(t.charAt(i)!=="[")throw new Error("not in a brace expression");let s=[],r=[],h=i+1,n=!1,o=!1,l=!1,a=!1,u=i,c="";t:for(;h<t.length;){let d=t.charAt(h);if((d==="!"||d==="^")&&h===i+1){a=!0,h++;continue}if(d==="]"&&n&&!l){u=h+1;break}if(n=!0,d==="\\"&&!l){l=!0,h++;continue}if(d==="["&&!l){for(let[g,[m,w,y]]of Object.entries(yi))if(t.startsWith(g,h)){if(c)return["$.",!1,t.length-i,!0];h+=g.length,y?r.push(m):s.push(m),o=o||w;continue t}}if(l=!1,c){d>c?s.push(et(c)+"-"+et(d)):d===c&&s.push(et(d)),c="",h++;continue}if(t.startsWith("-]",h+1)){s.push(et(d+"-")),h+=2;continue}if(t.startsWith("-",h+1)){c=d,h+=2;continue}s.push(et(d)),h++}if(u<h)return["",!1,0,!1];if(!s.length&&!r.length)return["$.",!1,t.length-i,!0];if(r.length===0&&s.length===1&&/^\\?.$/.test(s[0])&&!a){let d=s[0].length===2?s[0].slice(-1):s[0];return[bi(d),!1,u-i,!1]}let f="["+(a?"^":"")+Ht(s)+"]",p="["+(a?"":"^")+Ht(r)+"]";return[s.length&&r.length?"("+f+"|"+p+")":s.length?f:p,o,u-i,!0]},tt=(t,{windowsPathsNoEscape:e=!1,magicalBraces:i=!0}={})=>i?e?t.replace(/\[([^\/\\])\]/g,"$1"):t.replace(/((?!\\).|^)\[([^\/\\])\]/g,"$1$2").replace(/\\([^\/])/g,"$1"):e?t.replace(/\[([^\/\\{}])\]/g,"$1"):t.replace(/((?!\\).|^)\[([^\/\\{}])\]/g,"$1$2").replace(/\\([^\/{}])/g,"$1"),vi=new Set(["!","?","+","*","@"]),qt=t=>vi.has(t),Ei="(?!(?:^|/)\\.\\.?(?:$|/))",pt="(?!\\.)",xi=new Set(["[","."]),ki=new Set(["..","."]),Ci=new Set("().*{}+?[]^$\\!"),Oi=t=>t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),$t="[^/]",Zt=$t+"*?",Jt=$t+"+?",be=class W{type;#t;#i;#h=!1;#r=[];#n;#S;#m;#c=!1;#o;#p;#u=!1;constructor(e,i,s={}){this.type=e,e&&(this.#i=!0),this.#n=i,this.#t=this.#n?this.#n.#t:this,this.#o=this.#t===this?s:this.#t.#o,this.#m=this.#t===this?[]:this.#t.#m,e==="!"&&!this.#t.#c&&this.#m.push(this),this.#S=this.#n?this.#n.#r.length:0}get hasMagic(){if(this.#i!==void 0)return this.#i;for(let e of this.#r)if(typeof e!="string"&&(e.type||e.hasMagic))return this.#i=!0;return this.#i}toString(){return this.#p!==void 0?this.#p:this.type?this.#p=this.type+"("+this.#r.map(e=>String(e)).join("|")+")":this.#p=this.#r.map(e=>String(e)).join("")}#l(){if(this!==this.#t)throw new Error("should only call on root");if(this.#c)return this;this.toString(),this.#c=!0;let e;for(;e=this.#m.pop();){if(e.type!=="!")continue;let i=e,s=i.#n;for(;s;){for(let r=i.#S+1;!s.type&&r<s.#r.length;r++)for(let h of e.#r){if(typeof h=="string")throw new Error("string part in extglob AST??");h.copyIn(s.#r[r])}i=s,s=i.#n}}return this}push(...e){for(let i of e)if(i!==""){if(typeof i!="string"&&!(i instanceof W&&i.#n===this))throw new Error("invalid part: "+i);this.#r.push(i)}}toJSON(){let e=this.type===null?this.#r.slice().map(i=>typeof i=="string"?i:i.toJSON()):[this.type,...this.#r.map(i=>i.toJSON())];return this.isStart()&&!this.type&&e.unshift([]),this.isEnd()&&(this===this.#t||this.#t.#c&&this.#n?.type==="!")&&e.push({}),e}isStart(){if(this.#t===this)return!0;if(!this.#n?.isStart())return!1;if(this.#S===0)return!0;let e=this.#n;for(let i=0;i<this.#S;i++){let s=e.#r[i];if(!(s instanceof W&&s.type==="!"))return!1}return!0}isEnd(){if(this.#t===this||this.#n?.type==="!")return!0;if(!this.#n?.isEnd())return!1;if(!this.type)return this.#n?.isEnd();let e=this.#n?this.#n.#r.length:0;return this.#S===e-1}copyIn(e){typeof e=="string"?this.push(e):this.push(e.clone(this))}clone(e){let i=new W(this.type,e);for(let s of this.#r)i.copyIn(s);return i}static#s(e,i,s,r){let h=!1,n=!1,o=-1,l=!1;if(i.type===null){let p=s,d="";for(;p<e.length;){let g=e.charAt(p++);if(h||g==="\\"){h=!h,d+=g;continue}if(n){p===o+1?(g==="^"||g==="!")&&(l=!0):g==="]"&&!(p===o+2&&l)&&(n=!1),d+=g;continue}else if(g==="["){n=!0,o=p,l=!1,d+=g;continue}if(!r.noext&&qt(g)&&e.charAt(p)==="("){i.push(d),d="";let m=new W(g,i);p=W.#s(e,m,p,r),i.push(m);continue}d+=g}return i.push(d),p}let a=s+1,u=new W(null,i),c=[],f="";for(;a<e.length;){let p=e.charAt(a++);if(h||p==="\\"){h=!h,f+=p;continue}if(n){a===o+1?(p==="^"||p==="!")&&(l=!0):p==="]"&&!(a===o+2&&l)&&(n=!1),f+=p;continue}else if(p==="["){n=!0,o=a,l=!1,f+=p;continue}if(qt(p)&&e.charAt(a)==="("){u.push(f),f="";let d=new W(p,u);u.push(d),a=W.#s(e,d,a,r);continue}if(p==="|"){u.push(f),f="",c.push(u),u=new W(null,i);continue}if(p===")")return f===""&&i.#r.length===0&&(i.#u=!0),u.push(f),f="",i.push(...c,u),a;f+=p}return i.type=null,i.#i=void 0,i.#r=[e.substring(s-1)],a}static fromGlob(e,i={}){let s=new W(null,void 0,i);return W.#s(e,s,0,i),s}toMMPattern(){if(this!==this.#t)return this.#t.toMMPattern();let e=this.toString(),[i,s,r,h]=this.toRegExpSource();if(!(r||this.#i||this.#o.nocase&&!this.#o.nocaseMagicOnly&&e.toUpperCase()!==e.toLowerCase()))return s;let n=(this.#o.nocase?"i":"")+(h?"u":"");return Object.assign(new RegExp(`^${i}$`,n),{_src:i,_glob:e})}get options(){return this.#o}toRegExpSource(e){let i=e??!!this.#o.dot;if(this.#t===this&&this.#l(),!this.type){let l=this.isStart()&&this.isEnd()&&!this.#r.some(f=>typeof f!="string"),a=this.#r.map(f=>{let[p,d,g,m]=typeof f=="string"?W.#v(f,this.#i,l):f.toRegExpSource(e);return this.#i=this.#i||g,this.#h=this.#h||m,p}).join(""),u="";if(this.isStart()&&typeof this.#r[0]=="string"&&!(this.#r.length===1&&ki.has(this.#r[0]))){let f=xi,p=i&&f.has(a.charAt(0))||a.startsWith("\\.")&&f.has(a.charAt(2))||a.startsWith("\\.\\.")&&f.has(a.charAt(4)),d=!i&&!e&&f.has(a.charAt(0));u=p?Ei:d?pt:""}let c="";return this.isEnd()&&this.#t.#c&&this.#n?.type==="!"&&(c="(?:$|\\/)"),[u+a+c,tt(a),this.#i=!!this.#i,this.#h]}let s=this.type==="*"||this.type==="+",r=this.type==="!"?"(?:(?!(?:":"(?:",h=this.#f(i);if(this.isStart()&&this.isEnd()&&!h&&this.type!=="!"){let l=this.toString();return this.#r=[l],this.type=null,this.#i=void 0,[l,tt(this.toString()),!1,!1]}let n=!s||e||i||!pt?"":this.#f(!0);n===h&&(n=""),n&&(h=`(?:${h})(?:${n})*?`);let o="";if(this.type==="!"&&this.#u)o=(this.isStart()&&!i?pt:"")+Jt;else{let l=this.type==="!"?"))"+(this.isStart()&&!i&&!e?pt:"")+Zt+")":this.type==="@"?")":this.type==="?"?")?":this.type==="+"&&n?")":this.type==="*"&&n?")?":`)${this.type}`;o=r+h+l}return[o,tt(h),this.#i=!!this.#i,this.#h]}#f(e){return this.#r.map(i=>{if(typeof i=="string")throw new Error("string type in extglob ast??");let[s,r,h,n]=i.toRegExpSource(e);return this.#h=this.#h||n,s}).filter(i=>!(this.isStart()&&this.isEnd())||!!i).join("|")}static#v(e,i,s=!1){let r=!1,h="",n=!1,o=!1;for(let l=0;l<e.length;l++){let a=e.charAt(l);if(r){r=!1,h+=(Ci.has(a)?"\\":"")+a;continue}if(a==="*"){if(o)continue;o=!0,h+=s&&/^[*]+$/.test(e)?Jt:Zt,i=!0;continue}else o=!1;if(a==="\\"){l===e.length-1?h+="\\\\":r=!0;continue}if(a==="["){let[u,c,f,p]=Si(e,l);if(f){h+=u,n=n||c,l+=f-1,i=i||p;continue}}if(a==="?"){h+=$t,i=!0;continue}h+=Oi(a)}return[h,tt(e),!!i,n]}},Se=(t,{windowsPathsNoEscape:e=!1,magicalBraces:i=!1}={})=>i?e?t.replace(/[?*()[\]{}]/g,"[$&]"):t.replace(/[?*()[\]\\{}]/g,"\\$&"):e?t.replace(/[?*()[\]]/g,"[$&]"):t.replace(/[?*()[\]\\]/g,"\\$&"),R=(t,e,i={})=>(Et(e),!i.nocomment&&e.charAt(0)==="#"?!1:new H(e,i).match(t)),Ai=/^\*+([^+@!?\*\[\(]*)$/,Ti=t=>e=>!e.startsWith(".")&&e.endsWith(t),Ri=t=>e=>e.endsWith(t),Fi=t=>(t=t.toLowerCase(),e=>!e.startsWith(".")&&e.toLowerCase().endsWith(t)),Mi=t=>(t=t.toLowerCase(),e=>e.toLowerCase().endsWith(t)),Wi=/^\*+\.\*+$/,Pi=t=>!t.startsWith(".")&&t.includes("."),Li=t=>t!=="."&&t!==".."&&t.includes("."),Di=/^\.\*+$/,ji=t=>t!=="."&&t!==".."&&t.startsWith("."),zi=/^\*+$/,_i=t=>t.length!==0&&!t.startsWith("."),Ni=t=>t.length!==0&&t!=="."&&t!=="..",$i=/^\?+([^+@!?\*\[\(]*)?$/,Bi=([t,e=""])=>{let i=ve([t]);return e?(e=e.toLowerCase(),s=>i(s)&&s.toLowerCase().endsWith(e)):i},Ui=([t,e=""])=>{let i=Ee([t]);return e?(e=e.toLowerCase(),s=>i(s)&&s.toLowerCase().endsWith(e)):i},Gi=([t,e=""])=>{let i=Ee([t]);return e?s=>i(s)&&s.endsWith(e):i},Ii=([t,e=""])=>{let i=ve([t]);return e?s=>i(s)&&s.endsWith(e):i},ve=([t])=>{let e=t.length;return i=>i.length===e&&!i.startsWith(".")},Ee=([t])=>{let e=t.length;return i=>i.length===e&&i!=="."&&i!==".."},xe=typeof process=="object"&&process?typeof process.env=="object"&&process.env&&process.env.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix",Vt={win32:{sep:"\\"},posix:{sep:"/"}},Hi=xe==="win32"?Vt.win32.sep:Vt.posix.sep;R.sep=Hi;var T=Symbol("globstar **");R.GLOBSTAR=T;var qi="[^/]",Zi=qi+"*?",Ji="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?",Vi="(?:(?!(?:\\/|^)\\.).)*?",Ki=(t,e={})=>i=>R(i,t,e);R.filter=Ki;var P=(t,e={})=>Object.assign({},t,e),Yi=t=>{if(!t||typeof t!="object"||!Object.keys(t).length)return R;let e=R;return Object.assign((i,s,r={})=>e(i,s,P(t,r)),{Minimatch:class extends e.Minimatch{constructor(i,s={}){super(i,P(t,s))}static defaults(i){return e.defaults(P(t,i)).Minimatch}},AST:class extends e.AST{constructor(i,s,r={}){super(i,s,P(t,r))}static fromGlob(i,s={}){return e.AST.fromGlob(i,P(t,s))}},unescape:(i,s={})=>e.unescape(i,P(t,s)),escape:(i,s={})=>e.escape(i,P(t,s)),filter:(i,s={})=>e.filter(i,P(t,s)),defaults:i=>e.defaults(P(t,i)),makeRe:(i,s={})=>e.makeRe(i,P(t,s)),braceExpand:(i,s={})=>e.braceExpand(i,P(t,s)),match:(i,s,r={})=>e.match(i,s,P(t,r)),sep:e.sep,GLOBSTAR:T})};R.defaults=Yi;var ke=(t,e={})=>(Et(t),e.nobrace||!/\{(?:(?!\{).)*\}/.test(t)?[t]:fi(t,{max:e.braceExpandMax}));R.braceExpand=ke;var Xi=(t,e={})=>new H(t,e).makeRe();R.makeRe=Xi;var Qi=(t,e,i={})=>{let s=new H(e,i);return t=t.filter(r=>s.match(r)),s.options.nonull&&!t.length&&t.push(e),t};R.match=Qi;var Kt=/[?*]|[+@!]\(.*?\)|\[|\]/,ts=t=>t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),H=class{options;set;pattern;windowsPathsNoEscape;nonegate;negate;comment;empty;preserveMultipleSlashes;partial;globSet;globParts;nocase;isWindows;platform;windowsNoMagicRoot;regexp;constructor(t,e={}){Et(t),e=e||{},this.options=e,this.pattern=t,this.platform=e.platform||xe,this.isWindows=this.platform==="win32";let i="allowWindowsEscape";this.windowsPathsNoEscape=!!e.windowsPathsNoEscape||e[i]===!1,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!e.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!e.nonegate,this.comment=!1,this.empty=!1,this.partial=!!e.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=e.windowsNoMagicRoot!==void 0?e.windowsNoMagicRoot:!!(this.isWindows&&this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(let t of this.set)for(let e of t)if(typeof e!="string")return!0;return!1}debug(...t){}make(){let t=this.pattern,e=this.options;if(!e.nocomment&&t.charAt(0)==="#"){this.comment=!0;return}if(!t){this.empty=!0;return}this.parseNegate(),this.globSet=[...new Set(this.braceExpand())],e.debug&&(this.debug=(...r)=>console.error(...r)),this.debug(this.pattern,this.globSet);let i=this.globSet.map(r=>this.slashSplit(r));this.globParts=this.preprocess(i),this.debug(this.pattern,this.globParts);let s=this.globParts.map((r,h,n)=>{if(this.isWindows&&this.windowsNoMagicRoot){let o=r[0]===""&&r[1]===""&&(r[2]==="?"||!Kt.test(r[2]))&&!Kt.test(r[3]),l=/^[a-z]:/i.test(r[0]);if(o)return[...r.slice(0,4),...r.slice(4).map(a=>this.parse(a))];if(l)return[r[0],...r.slice(1).map(a=>this.parse(a))]}return r.map(o=>this.parse(o))});if(this.debug(this.pattern,s),this.set=s.filter(r=>r.indexOf(!1)===-1),this.isWindows)for(let r=0;r<this.set.length;r++){let h=this.set[r];h[0]===""&&h[1]===""&&this.globParts[r][2]==="?"&&typeof h[3]=="string"&&/^[a-z]:$/i.test(h[3])&&(h[2]="?")}this.debug(this.pattern,this.set)}preprocess(t){if(this.options.noglobstar)for(let i=0;i<t.length;i++)for(let s=0;s<t[i].length;s++)t[i][s]==="**"&&(t[i][s]="*");let{optimizationLevel:e=1}=this.options;return e>=2?(t=this.firstPhasePreProcess(t),t=this.secondPhasePreProcess(t)):e>=1?t=this.levelOneOptimize(t):t=this.adjascentGlobstarOptimize(t),t}adjascentGlobstarOptimize(t){return t.map(e=>{let i=-1;for(;(i=e.indexOf("**",i+1))!==-1;){let s=i;for(;e[s+1]==="**";)s++;s!==i&&e.splice(i,s-i)}return e})}levelOneOptimize(t){return t.map(e=>(e=e.reduce((i,s)=>{let r=i[i.length-1];return s==="**"&&r==="**"?i:s===".."&&r&&r!==".."&&r!=="."&&r!=="**"?(i.pop(),i):(i.push(s),i)},[]),e.length===0?[""]:e))}levelTwoFileOptimize(t){Array.isArray(t)||(t=this.slashSplit(t));let e=!1;do{if(e=!1,!this.preserveMultipleSlashes){for(let s=1;s<t.length-1;s++){let r=t[s];s===1&&r===""&&t[0]===""||(r==="."||r==="")&&(e=!0,t.splice(s,1),s--)}t[0]==="."&&t.length===2&&(t[1]==="."||t[1]==="")&&(e=!0,t.pop())}let i=0;for(;(i=t.indexOf("..",i+1))!==-1;){let s=t[i-1];s&&s!=="."&&s!==".."&&s!=="**"&&(e=!0,t.splice(i-1,2),i-=2)}}while(e);return t.length===0?[""]:t}firstPhasePreProcess(t){let e=!1;do{e=!1;for(let i of t){let s=-1;for(;(s=i.indexOf("**",s+1))!==-1;){let h=s;for(;i[h+1]==="**";)h++;h>s&&i.splice(s+1,h-s);let n=i[s+1],o=i[s+2],l=i[s+3];if(n!==".."||!o||o==="."||o===".."||!l||l==="."||l==="..")continue;e=!0,i.splice(s,1);let a=i.slice(0);a[s]="**",t.push(a),s--}if(!this.preserveMultipleSlashes){for(let h=1;h<i.length-1;h++){let n=i[h];h===1&&n===""&&i[0]===""||(n==="."||n==="")&&(e=!0,i.splice(h,1),h--)}i[0]==="."&&i.length===2&&(i[1]==="."||i[1]==="")&&(e=!0,i.pop())}let r=0;for(;(r=i.indexOf("..",r+1))!==-1;){let h=i[r-1];if(h&&h!=="."&&h!==".."&&h!=="**"){e=!0;let n=r===1&&i[r+1]==="**"?["."]:[];i.splice(r-1,2,...n),i.length===0&&i.push(""),r-=2}}}}while(e);return t}secondPhasePreProcess(t){for(let e=0;e<t.length-1;e++)for(let i=e+1;i<t.length;i++){let s=this.partsMatch(t[e],t[i],!this.preserveMultipleSlashes);if(s){t[e]=[],t[i]=s;break}}return t.filter(e=>e.length)}partsMatch(t,e,i=!1){let s=0,r=0,h=[],n="";for(;s<t.length&&r<e.length;)if(t[s]===e[r])h.push(n==="b"?e[r]:t[s]),s++,r++;else if(i&&t[s]==="**"&&e[r]===t[s+1])h.push(t[s]),s++;else if(i&&e[r]==="**"&&t[s]===e[r+1])h.push(e[r]),r++;else if(t[s]==="*"&&e[r]&&(this.options.dot||!e[r].startsWith("."))&&e[r]!=="**"){if(n==="b")return!1;n="a",h.push(t[s]),s++,r++}else if(e[r]==="*"&&t[s]&&(this.options.dot||!t[s].startsWith("."))&&t[s]!=="**"){if(n==="a")return!1;n="b",h.push(e[r]),s++,r++}else return!1;return t.length===e.length&&h}parseNegate(){if(this.nonegate)return;let t=this.pattern,e=!1,i=0;for(let s=0;s<t.length&&t.charAt(s)==="!";s++)e=!e,i++;i&&(this.pattern=t.slice(i)),this.negate=e}matchOne(t,e,i=!1){let s=this.options;if(this.isWindows){let d=typeof t[0]=="string"&&/^[a-z]:$/i.test(t[0]),g=!d&&t[0]===""&&t[1]===""&&t[2]==="?"&&/^[a-z]:$/i.test(t[3]),m=typeof e[0]=="string"&&/^[a-z]:$/i.test(e[0]),w=!m&&e[0]===""&&e[1]===""&&e[2]==="?"&&typeof e[3]=="string"&&/^[a-z]:$/i.test(e[3]),y=g?3:d?0:void 0,b=w?3:m?0:void 0;if(typeof y=="number"&&typeof b=="number"){let[S,v]=[t[y],e[b]];S.toLowerCase()===v.toLowerCase()&&(e[b]=S,b>y?e=e.slice(b):y>b&&(t=t.slice(y)))}}let{optimizationLevel:r=1}=this.options;r>=2&&(t=this.levelTwoFileOptimize(t)),this.debug("matchOne",this,{file:t,pattern:e}),this.debug("matchOne",t.length,e.length);for(var h=0,n=0,o=t.length,l=e.length;h<o&&n<l;h++,n++){this.debug("matchOne loop");var a=e[n],u=t[h];if(this.debug(e,a,u),a===!1)return!1;if(a===T){this.debug("GLOBSTAR",[e,a,u]);var c=h,f=n+1;if(f===l){for(this.debug("** at the end");h<o;h++)if(t[h]==="."||t[h]===".."||!s.dot&&t[h].charAt(0)===".")return!1;return!0}for(;c<o;){var p=t[c];if(this.debug(`
8
+ globstar while`,t,c,e,f,p),this.matchOne(t.slice(c),e.slice(f),i))return this.debug("globstar found match!",c,o,p),!0;if(p==="."||p===".."||!s.dot&&p.charAt(0)==="."){this.debug("dot detected!",t,c,e,f);break}this.debug("globstar swallow a segment, and continue"),c++}return!!(i&&(this.debug(`
9
+ >>> no match, partial?`,t,c,e,f),c===o))}let d;if(typeof a=="string"?(d=u===a,this.debug("string match",a,u,d)):(d=a.test(u),this.debug("pattern match",a,u,d)),!d)return!1}if(h===o&&n===l)return!0;if(h===o)return i;if(n===l)return h===o-1&&t[h]==="";throw new Error("wtf?")}braceExpand(){return ke(this.pattern,this.options)}parse(t){Et(t);let e=this.options;if(t==="**")return T;if(t==="")return"";let i,s=null;(i=t.match(zi))?s=e.dot?Ni:_i:(i=t.match(Ai))?s=(e.nocase?e.dot?Mi:Fi:e.dot?Ri:Ti)(i[1]):(i=t.match($i))?s=(e.nocase?e.dot?Ui:Bi:e.dot?Gi:Ii)(i):(i=t.match(Wi))?s=e.dot?Li:Pi:(i=t.match(Di))&&(s=ji);let r=be.fromGlob(t,this.options).toMMPattern();return s&&typeof r=="object"&&Reflect.defineProperty(r,"test",{value:s}),r}makeRe(){if(this.regexp||this.regexp===!1)return this.regexp;let t=this.set;if(!t.length)return this.regexp=!1,this.regexp;let e=this.options,i=e.noglobstar?Zi:e.dot?Ji:Vi,s=new Set(e.nocase?["i"]:[]),r=t.map(o=>{let l=o.map(u=>{if(u instanceof RegExp)for(let c of u.flags.split(""))s.add(c);return typeof u=="string"?ts(u):u===T?T:u._src});l.forEach((u,c)=>{let f=l[c+1],p=l[c-1];u!==T||p===T||(p===void 0?f!==void 0&&f!==T?l[c+1]="(?:\\/|"+i+"\\/)?"+f:l[c]=i:f===void 0?l[c-1]=p+"(?:\\/|\\/"+i+")?":f!==T&&(l[c-1]=p+"(?:\\/|\\/"+i+"\\/)"+f,l[c+1]=T))});let a=l.filter(u=>u!==T);if(this.partial&&a.length>=1){let u=[];for(let c=1;c<=a.length;c++)u.push(a.slice(0,c).join("/"));return"(?:"+u.join("|")+")"}return a.join("/")}).join("|"),[h,n]=t.length>1?["(?:",")"]:["",""];r="^"+h+r+n+"$",this.partial&&(r="^(?:\\/|"+h+r.slice(1,-1)+n+")$"),this.negate&&(r="^(?!"+r+").+$");try{this.regexp=new RegExp(r,[...s].join(""))}catch{this.regexp=!1}return this.regexp}slashSplit(t){return this.preserveMultipleSlashes?t.split("/"):this.isWindows&&/^\/\/[^\/]+/.test(t)?["",...t.split(/\/+/)]:t.split(/\/+/)}match(t,e=this.partial){if(this.debug("match",t,this.pattern),this.comment)return!1;if(this.empty)return t==="";if(t==="/"&&e)return!0;let i=this.options;this.isWindows&&(t=t.split("\\").join("/"));let s=this.slashSplit(t);this.debug(this.pattern,"split",s);let r=this.set;this.debug(this.pattern,"set",r);let h=s[s.length-1];if(!h)for(let n=s.length-2;!h&&n>=0;n--)h=s[n];for(let n=0;n<r.length;n++){let o=r[n],l=s;if(i.matchBase&&o.length===1&&(l=[h]),this.matchOne(l,o,e))return i.flipNegate?!0:!this.negate}return i.flipNegate?!1:this.negate}static defaults(t){return R.defaults(t).Minimatch}};R.AST=be;R.Minimatch=H;R.escape=Se;R.unescape=tt;var is=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,Ce=new Set,zt=typeof process=="object"&&process?process:{},Oe=(t,e,i,s)=>{typeof zt.emitWarning=="function"?zt.emitWarning(t,e,i,s):console.error(`[${i}] ${e}: ${t}`)},xt=globalThis.AbortController,Yt=globalThis.AbortSignal;if(typeof xt>"u"){Yt=class{onabort;_onabort=[];reason;aborted=!1;addEventListener(i,s){this._onabort.push(s)}},xt=class{constructor(){e()}signal=new Yt;abort(i){if(!this.signal.aborted){this.signal.reason=i,this.signal.aborted=!0;for(let s of this.signal._onabort)s(i);this.signal.onabort?.(i)}}};let t=zt.env?.LRU_CACHE_IGNORE_AC_WARNING!=="1",e=()=>{t&&(t=!1,Oe("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",e))}}var ss=t=>!Ce.has(t),I=t=>t&&t===Math.floor(t)&&t>0&&isFinite(t),Ae=t=>I(t)?t<=Math.pow(2,8)?Uint8Array:t<=Math.pow(2,16)?Uint16Array:t<=Math.pow(2,32)?Uint32Array:t<=Number.MAX_SAFE_INTEGER?St:null:null,St=class extends Array{constructor(t){super(t),this.fill(0)}},rs=class lt{heap;length;static#t=!1;static create(e){let i=Ae(e);if(!i)return[];lt.#t=!0;let s=new lt(e,i);return lt.#t=!1,s}constructor(e,i){if(!lt.#t)throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new i(e),this.length=0}push(e){this.heap[this.length++]=e}pop(){return this.heap[--this.length]}},Ct=class Te{#t;#i;#h;#r;#n;#S;#m;#c;get perf(){return this.#c}ttl;ttlResolution;ttlAutopurge;updateAgeOnGet;updateAgeOnHas;allowStale;noDisposeOnSet;noUpdateTTL;maxEntrySize;sizeCalculation;noDeleteOnFetchRejection;noDeleteOnStaleGet;allowStaleOnFetchAbort;allowStaleOnFetchRejection;ignoreFetchAbort;#o;#p;#u;#l;#s;#f;#v;#b;#d;#T;#g;#k;#C;#w;#y;#E;#O;#e;#L;static unsafeExposeInternals(e){return{starts:e.#C,ttls:e.#w,autopurgeTimers:e.#y,sizes:e.#k,keyMap:e.#u,keyList:e.#l,valList:e.#s,next:e.#f,prev:e.#v,get head(){return e.#b},get tail(){return e.#d},free:e.#T,isBackgroundFetch:i=>e.#a(i),backgroundFetch:(i,s,r,h)=>e.#U(i,s,r,h),moveToTail:i=>e.#j(i),indexes:i=>e.#F(i),rindexes:i=>e.#M(i),isStale:i=>e.#x(i)}}get max(){return this.#t}get maxSize(){return this.#i}get calculatedSize(){return this.#p}get size(){return this.#o}get fetchMethod(){return this.#S}get memoMethod(){return this.#m}get dispose(){return this.#h}get onInsert(){return this.#r}get disposeAfter(){return this.#n}constructor(e){let{max:i=0,ttl:s,ttlResolution:r=1,ttlAutopurge:h,updateAgeOnGet:n,updateAgeOnHas:o,allowStale:l,dispose:a,onInsert:u,disposeAfter:c,noDisposeOnSet:f,noUpdateTTL:p,maxSize:d=0,maxEntrySize:g=0,sizeCalculation:m,fetchMethod:w,memoMethod:y,noDeleteOnFetchRejection:b,noDeleteOnStaleGet:S,allowStaleOnFetchRejection:v,allowStaleOnFetchAbort:U,ignoreFetchAbort:V,perf:K}=e;if(K!==void 0&&typeof K?.now!="function")throw new TypeError("perf option must have a now() method if specified");if(this.#c=K??is,i!==0&&!I(i))throw new TypeError("max option must be a nonnegative integer");let Y=i?Ae(i):Array;if(!Y)throw new Error("invalid max value: "+i);if(this.#t=i,this.#i=d,this.maxEntrySize=g||this.#i,this.sizeCalculation=m,this.sizeCalculation){if(!this.#i&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(y!==void 0&&typeof y!="function")throw new TypeError("memoMethod must be a function if defined");if(this.#m=y,w!==void 0&&typeof w!="function")throw new TypeError("fetchMethod must be a function if specified");if(this.#S=w,this.#O=!!w,this.#u=new Map,this.#l=new Array(i).fill(void 0),this.#s=new Array(i).fill(void 0),this.#f=new Y(i),this.#v=new Y(i),this.#b=0,this.#d=0,this.#T=rs.create(i),this.#o=0,this.#p=0,typeof a=="function"&&(this.#h=a),typeof u=="function"&&(this.#r=u),typeof c=="function"?(this.#n=c,this.#g=[]):(this.#n=void 0,this.#g=void 0),this.#E=!!this.#h,this.#L=!!this.#r,this.#e=!!this.#n,this.noDisposeOnSet=!!f,this.noUpdateTTL=!!p,this.noDeleteOnFetchRejection=!!b,this.allowStaleOnFetchRejection=!!v,this.allowStaleOnFetchAbort=!!U,this.ignoreFetchAbort=!!V,this.maxEntrySize!==0){if(this.#i!==0&&!I(this.#i))throw new TypeError("maxSize must be a positive integer if specified");if(!I(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");this.#I()}if(this.allowStale=!!l,this.noDeleteOnStaleGet=!!S,this.updateAgeOnGet=!!n,this.updateAgeOnHas=!!o,this.ttlResolution=I(r)||r===0?r:1,this.ttlAutopurge=!!h,this.ttl=s||0,this.ttl){if(!I(this.ttl))throw new TypeError("ttl must be a positive integer if specified");this.#W()}if(this.#t===0&&this.ttl===0&&this.#i===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.#t&&!this.#i){let Tt="LRU_CACHE_UNBOUNDED";ss(Tt)&&(Ce.add(Tt),Oe("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",Tt,Te))}}getRemainingTTL(e){return this.#u.has(e)?1/0:0}#W(){let e=new St(this.#t),i=new St(this.#t);this.#w=e,this.#C=i;let s=this.ttlAutopurge?new Array(this.#t):void 0;this.#y=s,this.#_=(n,o,l=this.#c.now())=>{if(i[n]=o!==0?l:0,e[n]=o,s?.[n]&&(clearTimeout(s[n]),s[n]=void 0),o!==0&&s){let a=setTimeout(()=>{this.#x(n)&&this.#R(this.#l[n],"expire")},o+1);a.unref&&a.unref(),s[n]=a}},this.#A=n=>{i[n]=e[n]!==0?this.#c.now():0},this.#P=(n,o)=>{if(e[o]){let l=e[o],a=i[o];if(!l||!a)return;n.ttl=l,n.start=a,n.now=r||h();let u=n.now-a;n.remainingTTL=l-u}};let r=0,h=()=>{let n=this.#c.now();if(this.ttlResolution>0){r=n;let o=setTimeout(()=>r=0,this.ttlResolution);o.unref&&o.unref()}return n};this.getRemainingTTL=n=>{let o=this.#u.get(n);if(o===void 0)return 0;let l=e[o],a=i[o];if(!l||!a)return 1/0;let u=(r||h())-a;return l-u},this.#x=n=>{let o=i[n],l=e[n];return!!l&&!!o&&(r||h())-o>l}}#A=()=>{};#P=()=>{};#_=()=>{};#x=()=>!1;#I(){let e=new St(this.#t);this.#p=0,this.#k=e,this.#z=i=>{this.#p-=e[i],e[i]=0},this.#N=(i,s,r,h)=>{if(this.#a(s))return 0;if(!I(r))if(h){if(typeof h!="function")throw new TypeError("sizeCalculation must be a function");if(r=h(s,i),!I(r))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");return r},this.#D=(i,s,r)=>{if(e[i]=s,this.#i){let h=this.#i-e[i];for(;this.#p>h;)this.#B(!0)}this.#p+=e[i],r&&(r.entrySize=s,r.totalCalculatedSize=this.#p)}}#z=e=>{};#D=(e,i,s)=>{};#N=(e,i,s,r)=>{if(s||r)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0};*#F({allowStale:e=this.allowStale}={}){if(this.#o)for(let i=this.#d;!(!this.#$(i)||((e||!this.#x(i))&&(yield i),i===this.#b));)i=this.#v[i]}*#M({allowStale:e=this.allowStale}={}){if(this.#o)for(let i=this.#b;!(!this.#$(i)||((e||!this.#x(i))&&(yield i),i===this.#d));)i=this.#f[i]}#$(e){return e!==void 0&&this.#u.get(this.#l[e])===e}*entries(){for(let e of this.#F())this.#s[e]!==void 0&&this.#l[e]!==void 0&&!this.#a(this.#s[e])&&(yield[this.#l[e],this.#s[e]])}*rentries(){for(let e of this.#M())this.#s[e]!==void 0&&this.#l[e]!==void 0&&!this.#a(this.#s[e])&&(yield[this.#l[e],this.#s[e]])}*keys(){for(let e of this.#F()){let i=this.#l[e];i!==void 0&&!this.#a(this.#s[e])&&(yield i)}}*rkeys(){for(let e of this.#M()){let i=this.#l[e];i!==void 0&&!this.#a(this.#s[e])&&(yield i)}}*values(){for(let e of this.#F())this.#s[e]!==void 0&&!this.#a(this.#s[e])&&(yield this.#s[e])}*rvalues(){for(let e of this.#M())this.#s[e]!==void 0&&!this.#a(this.#s[e])&&(yield this.#s[e])}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="LRUCache";find(e,i={}){for(let s of this.#F()){let r=this.#s[s],h=this.#a(r)?r.__staleWhileFetching:r;if(h!==void 0&&e(h,this.#l[s],this))return this.get(this.#l[s],i)}}forEach(e,i=this){for(let s of this.#F()){let r=this.#s[s],h=this.#a(r)?r.__staleWhileFetching:r;h!==void 0&&e.call(i,h,this.#l[s],this)}}rforEach(e,i=this){for(let s of this.#M()){let r=this.#s[s],h=this.#a(r)?r.__staleWhileFetching:r;h!==void 0&&e.call(i,h,this.#l[s],this)}}purgeStale(){let e=!1;for(let i of this.#M({allowStale:!0}))this.#x(i)&&(this.#R(this.#l[i],"expire"),e=!0);return e}info(e){let i=this.#u.get(e);if(i===void 0)return;let s=this.#s[i],r=this.#a(s)?s.__staleWhileFetching:s;if(r===void 0)return;let h={value:r};if(this.#w&&this.#C){let n=this.#w[i],o=this.#C[i];if(n&&o){let l=n-(this.#c.now()-o);h.ttl=l,h.start=Date.now()}}return this.#k&&(h.size=this.#k[i]),h}dump(){let e=[];for(let i of this.#F({allowStale:!0})){let s=this.#l[i],r=this.#s[i],h=this.#a(r)?r.__staleWhileFetching:r;if(h===void 0||s===void 0)continue;let n={value:h};if(this.#w&&this.#C){n.ttl=this.#w[i];let o=this.#c.now()-this.#C[i];n.start=Math.floor(Date.now()-o)}this.#k&&(n.size=this.#k[i]),e.unshift([s,n])}return e}load(e){this.clear();for(let[i,s]of e){if(s.start){let r=Date.now()-s.start;s.start=this.#c.now()-r}this.set(i,s.value,s)}}set(e,i,s={}){if(i===void 0)return this.delete(e),this;let{ttl:r=this.ttl,start:h,noDisposeOnSet:n=this.noDisposeOnSet,sizeCalculation:o=this.sizeCalculation,status:l}=s,{noUpdateTTL:a=this.noUpdateTTL}=s,u=this.#N(e,i,s.size||0,o);if(this.maxEntrySize&&u>this.maxEntrySize)return l&&(l.set="miss",l.maxEntrySizeExceeded=!0),this.#R(e,"set"),this;let c=this.#o===0?void 0:this.#u.get(e);if(c===void 0)c=this.#o===0?this.#d:this.#T.length!==0?this.#T.pop():this.#o===this.#t?this.#B(!1):this.#o,this.#l[c]=e,this.#s[c]=i,this.#u.set(e,c),this.#f[this.#d]=c,this.#v[c]=this.#d,this.#d=c,this.#o++,this.#D(c,u,l),l&&(l.set="add"),a=!1,this.#L&&this.#r?.(i,e,"add");else{this.#j(c);let f=this.#s[c];if(i!==f){if(this.#O&&this.#a(f)){f.__abortController.abort(new Error("replaced"));let{__staleWhileFetching:p}=f;p!==void 0&&!n&&(this.#E&&this.#h?.(p,e,"set"),this.#e&&this.#g?.push([p,e,"set"]))}else n||(this.#E&&this.#h?.(f,e,"set"),this.#e&&this.#g?.push([f,e,"set"]));if(this.#z(c),this.#D(c,u,l),this.#s[c]=i,l){l.set="replace";let p=f&&this.#a(f)?f.__staleWhileFetching:f;p!==void 0&&(l.oldValue=p)}}else l&&(l.set="update");this.#L&&this.onInsert?.(i,e,i===f?"update":"replace")}if(r!==0&&!this.#w&&this.#W(),this.#w&&(a||this.#_(c,r,h),l&&this.#P(l,c)),!n&&this.#e&&this.#g){let f=this.#g,p;for(;p=f?.shift();)this.#n?.(...p)}return this}pop(){try{for(;this.#o;){let e=this.#s[this.#b];if(this.#B(!0),this.#a(e)){if(e.__staleWhileFetching)return e.__staleWhileFetching}else if(e!==void 0)return e}}finally{if(this.#e&&this.#g){let e=this.#g,i;for(;i=e?.shift();)this.#n?.(...i)}}}#B(e){let i=this.#b,s=this.#l[i],r=this.#s[i];return this.#O&&this.#a(r)?r.__abortController.abort(new Error("evicted")):(this.#E||this.#e)&&(this.#E&&this.#h?.(r,s,"evict"),this.#e&&this.#g?.push([r,s,"evict"])),this.#z(i),this.#y?.[i]&&(clearTimeout(this.#y[i]),this.#y[i]=void 0),e&&(this.#l[i]=void 0,this.#s[i]=void 0,this.#T.push(i)),this.#o===1?(this.#b=this.#d=0,this.#T.length=0):this.#b=this.#f[i],this.#u.delete(s),this.#o--,i}has(e,i={}){let{updateAgeOnHas:s=this.updateAgeOnHas,status:r}=i,h=this.#u.get(e);if(h!==void 0){let n=this.#s[h];if(this.#a(n)&&n.__staleWhileFetching===void 0)return!1;if(this.#x(h))r&&(r.has="stale",this.#P(r,h));else return s&&this.#A(h),r&&(r.has="hit",this.#P(r,h)),!0}else r&&(r.has="miss");return!1}peek(e,i={}){let{allowStale:s=this.allowStale}=i,r=this.#u.get(e);if(r===void 0||!s&&this.#x(r))return;let h=this.#s[r];return this.#a(h)?h.__staleWhileFetching:h}#U(e,i,s,r){let h=i===void 0?void 0:this.#s[i];if(this.#a(h))return h;let n=new xt,{signal:o}=s;o?.addEventListener("abort",()=>n.abort(o.reason),{signal:n.signal});let l={signal:n.signal,options:s,context:r},a=(g,m=!1)=>{let{aborted:w}=n.signal,y=s.ignoreFetchAbort&&g!==void 0,b=s.ignoreFetchAbort||!!(s.allowStaleOnFetchAbort&&g!==void 0);if(s.status&&(w&&!m?(s.status.fetchAborted=!0,s.status.fetchError=n.signal.reason,y&&(s.status.fetchAbortIgnored=!0)):s.status.fetchResolved=!0),w&&!y&&!m)return c(n.signal.reason,b);let S=p,v=this.#s[i];return(v===p||y&&m&&v===void 0)&&(g===void 0?S.__staleWhileFetching!==void 0?this.#s[i]=S.__staleWhileFetching:this.#R(e,"fetch"):(s.status&&(s.status.fetchUpdated=!0),this.set(e,g,l.options))),g},u=g=>(s.status&&(s.status.fetchRejected=!0,s.status.fetchError=g),c(g,!1)),c=(g,m)=>{let{aborted:w}=n.signal,y=w&&s.allowStaleOnFetchAbort,b=y||s.allowStaleOnFetchRejection,S=b||s.noDeleteOnFetchRejection,v=p;if(this.#s[i]===p&&(!S||!m&&v.__staleWhileFetching===void 0?this.#R(e,"fetch"):y||(this.#s[i]=v.__staleWhileFetching)),b)return s.status&&v.__staleWhileFetching!==void 0&&(s.status.returnedStale=!0),v.__staleWhileFetching;if(v.__returned===v)throw g},f=(g,m)=>{let w=this.#S?.(e,h,l);w&&w instanceof Promise&&w.then(y=>g(y===void 0?void 0:y),m),n.signal.addEventListener("abort",()=>{(!s.ignoreFetchAbort||s.allowStaleOnFetchAbort)&&(g(void 0),s.allowStaleOnFetchAbort&&(g=y=>a(y,!0)))})};s.status&&(s.status.fetchDispatched=!0);let p=new Promise(f).then(a,u),d=Object.assign(p,{__abortController:n,__staleWhileFetching:h,__returned:void 0});return i===void 0?(this.set(e,d,{...l.options,status:void 0}),i=this.#u.get(e)):this.#s[i]=d,d}#a(e){if(!this.#O)return!1;let i=e;return!!i&&i instanceof Promise&&i.hasOwnProperty("__staleWhileFetching")&&i.__abortController instanceof xt}async fetch(e,i={}){let{allowStale:s=this.allowStale,updateAgeOnGet:r=this.updateAgeOnGet,noDeleteOnStaleGet:h=this.noDeleteOnStaleGet,ttl:n=this.ttl,noDisposeOnSet:o=this.noDisposeOnSet,size:l=0,sizeCalculation:a=this.sizeCalculation,noUpdateTTL:u=this.noUpdateTTL,noDeleteOnFetchRejection:c=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:f=this.allowStaleOnFetchRejection,ignoreFetchAbort:p=this.ignoreFetchAbort,allowStaleOnFetchAbort:d=this.allowStaleOnFetchAbort,context:g,forceRefresh:m=!1,status:w,signal:y}=i;if(!this.#O)return w&&(w.fetch="get"),this.get(e,{allowStale:s,updateAgeOnGet:r,noDeleteOnStaleGet:h,status:w});let b={allowStale:s,updateAgeOnGet:r,noDeleteOnStaleGet:h,ttl:n,noDisposeOnSet:o,size:l,sizeCalculation:a,noUpdateTTL:u,noDeleteOnFetchRejection:c,allowStaleOnFetchRejection:f,allowStaleOnFetchAbort:d,ignoreFetchAbort:p,status:w,signal:y},S=this.#u.get(e);if(S===void 0){w&&(w.fetch="miss");let v=this.#U(e,S,b,g);return v.__returned=v}else{let v=this.#s[S];if(this.#a(v)){let Y=s&&v.__staleWhileFetching!==void 0;return w&&(w.fetch="inflight",Y&&(w.returnedStale=!0)),Y?v.__staleWhileFetching:v.__returned=v}let U=this.#x(S);if(!m&&!U)return w&&(w.fetch="hit"),this.#j(S),r&&this.#A(S),w&&this.#P(w,S),v;let V=this.#U(e,S,b,g),K=V.__staleWhileFetching!==void 0&&s;return w&&(w.fetch=U?"stale":"refresh",K&&U&&(w.returnedStale=!0)),K?V.__staleWhileFetching:V.__returned=V}}async forceFetch(e,i={}){let s=await this.fetch(e,i);if(s===void 0)throw new Error("fetch() returned undefined");return s}memo(e,i={}){let s=this.#m;if(!s)throw new Error("no memoMethod provided to constructor");let{context:r,forceRefresh:h,...n}=i,o=this.get(e,n);if(!h&&o!==void 0)return o;let l=s(e,o,{options:n,context:r});return this.set(e,l,n),l}get(e,i={}){let{allowStale:s=this.allowStale,updateAgeOnGet:r=this.updateAgeOnGet,noDeleteOnStaleGet:h=this.noDeleteOnStaleGet,status:n}=i,o=this.#u.get(e);if(o!==void 0){let l=this.#s[o],a=this.#a(l);return n&&this.#P(n,o),this.#x(o)?(n&&(n.get="stale"),a?(n&&s&&l.__staleWhileFetching!==void 0&&(n.returnedStale=!0),s?l.__staleWhileFetching:void 0):(h||this.#R(e,"expire"),n&&s&&(n.returnedStale=!0),s?l:void 0)):(n&&(n.get="hit"),a?l.__staleWhileFetching:(this.#j(o),r&&this.#A(o),l))}else n&&(n.get="miss")}#G(e,i){this.#v[i]=e,this.#f[e]=i}#j(e){e!==this.#d&&(e===this.#b?this.#b=this.#f[e]:this.#G(this.#v[e],this.#f[e]),this.#G(this.#d,e),this.#d=e)}delete(e){return this.#R(e,"delete")}#R(e,i){let s=!1;if(this.#o!==0){let r=this.#u.get(e);if(r!==void 0)if(this.#y?.[r]&&(clearTimeout(this.#y?.[r]),this.#y[r]=void 0),s=!0,this.#o===1)this.#H(i);else{this.#z(r);let h=this.#s[r];if(this.#a(h)?h.__abortController.abort(new Error("deleted")):(this.#E||this.#e)&&(this.#E&&this.#h?.(h,e,i),this.#e&&this.#g?.push([h,e,i])),this.#u.delete(e),this.#l[r]=void 0,this.#s[r]=void 0,r===this.#d)this.#d=this.#v[r];else if(r===this.#b)this.#b=this.#f[r];else{let n=this.#v[r];this.#f[n]=this.#f[r];let o=this.#f[r];this.#v[o]=this.#v[r]}this.#o--,this.#T.push(r)}}if(this.#e&&this.#g?.length){let r=this.#g,h;for(;h=r?.shift();)this.#n?.(...h)}return s}clear(){return this.#H("delete")}#H(e){for(let i of this.#M({allowStale:!0})){let s=this.#s[i];if(this.#a(s))s.__abortController.abort(new Error("deleted"));else{let r=this.#l[i];this.#E&&this.#h?.(s,r,e),this.#e&&this.#g?.push([s,r,e])}}if(this.#u.clear(),this.#s.fill(void 0),this.#l.fill(void 0),this.#w&&this.#C){this.#w.fill(0),this.#C.fill(0);for(let i of this.#y??[])i!==void 0&&clearTimeout(i);this.#y?.fill(void 0)}if(this.#k&&this.#k.fill(0),this.#b=0,this.#d=0,this.#T.length=0,this.#p=0,this.#o=0,this.#e&&this.#g){let i=this.#g,s;for(;s=i?.shift();)this.#n?.(...s)}}},Xt=typeof process=="object"&&process?process:{stdout:null,stderr:null},ys=t=>!!t&&typeof t=="object"&&(t instanceof kt||t instanceof Re||bs(t)||Ss(t)),bs=t=>!!t&&typeof t=="object"&&t instanceof Bt&&typeof t.pipe=="function"&&t.pipe!==Re.Writable.prototype.pipe,Ss=t=>!!t&&typeof t=="object"&&t instanceof Bt&&typeof t.write=="function"&&typeof t.end=="function",$=Symbol("EOF"),B=Symbol("maybeEmitEnd"),G=Symbol("emittedEnd"),ft=Symbol("emittingEnd"),it=Symbol("emittedError"),dt=Symbol("closed"),Qt=Symbol("read"),gt=Symbol("flush"),te=Symbol("flushChunk"),j=Symbol("encoding"),X=Symbol("decoder"),x=Symbol("flowing"),st=Symbol("paused"),Q=Symbol("resume"),k=Symbol("buffer"),A=Symbol("pipes"),C=Symbol("bufferLength"),Ft=Symbol("bufferPush"),wt=Symbol("bufferShift"),O=Symbol("objectMode"),E=Symbol("destroyed"),Mt=Symbol("error"),Wt=Symbol("emitData"),ee=Symbol("emitEnd"),Pt=Symbol("emitEnd2"),_=Symbol("async"),Lt=Symbol("abort"),mt=Symbol("aborted"),rt=Symbol("signal"),q=Symbol("dataListeners"),M=Symbol("discarded"),ht=t=>Promise.resolve().then(t),vs=t=>t(),Es=t=>t==="end"||t==="finish"||t==="prefinish",xs=t=>t instanceof ArrayBuffer||!!t&&typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,ks=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t),Fe=class{src;dest;opts;ondrain;constructor(t,e,i){this.src=t,this.dest=e,this.opts=i,this.ondrain=()=>t[Q](),this.dest.on("drain",this.ondrain)}unpipe(){this.dest.removeListener("drain",this.ondrain)}proxyErrors(t){}end(){this.unpipe(),this.opts.end&&this.dest.end()}},Cs=class extends Fe{unpipe(){this.src.removeListener("error",this.proxyErrors),super.unpipe()}constructor(t,e,i){super(t,e,i),this.proxyErrors=s=>e.emit("error",s),t.on("error",this.proxyErrors)}},Os=t=>!!t.objectMode,As=t=>!t.objectMode&&!!t.encoding&&t.encoding!=="buffer",kt=class extends Bt{[x]=!1;[st]=!1;[A]=[];[k]=[];[O];[j];[_];[X];[$]=!1;[G]=!1;[ft]=!1;[dt]=!1;[it]=null;[C]=0;[E]=!1;[rt];[mt]=!1;[q]=0;[M]=!1;writable=!0;readable=!0;constructor(...t){let e=t[0]||{};if(super(),e.objectMode&&typeof e.encoding=="string")throw new TypeError("Encoding and objectMode may not be used together");Os(e)?(this[O]=!0,this[j]=null):As(e)?(this[j]=e.encoding,this[O]=!1):(this[O]=!1,this[j]=null),this[_]=!!e.async,this[X]=this[j]?new ms(this[j]):null,e&&e.debugExposeBuffer===!0&&Object.defineProperty(this,"buffer",{get:()=>this[k]}),e&&e.debugExposePipes===!0&&Object.defineProperty(this,"pipes",{get:()=>this[A]});let{signal:i}=e;i&&(this[rt]=i,i.aborted?this[Lt]():i.addEventListener("abort",()=>this[Lt]()))}get bufferLength(){return this[C]}get encoding(){return this[j]}set encoding(t){throw new Error("Encoding must be set at instantiation time")}setEncoding(t){throw new Error("Encoding must be set at instantiation time")}get objectMode(){return this[O]}set objectMode(t){throw new Error("objectMode must be set at instantiation time")}get async(){return this[_]}set async(t){this[_]=this[_]||!!t}[Lt](){this[mt]=!0,this.emit("abort",this[rt]?.reason),this.destroy(this[rt]?.reason)}get aborted(){return this[mt]}set aborted(t){}write(t,e,i){if(this[mt])return!1;if(this[$])throw new Error("write after end");if(this[E])return this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0;typeof e=="function"&&(i=e,e="utf8"),e||(e="utf8");let s=this[_]?ht:vs;if(!this[O]&&!Buffer.isBuffer(t)){if(ks(t))t=Buffer.from(t.buffer,t.byteOffset,t.byteLength);else if(xs(t))t=Buffer.from(t);else if(typeof t!="string")throw new Error("Non-contiguous data written to non-objectMode stream")}return this[O]?(this[x]&&this[C]!==0&&this[gt](!0),this[x]?this.emit("data",t):this[Ft](t),this[C]!==0&&this.emit("readable"),i&&s(i),this[x]):t.length?(typeof t=="string"&&!(e===this[j]&&!this[X]?.lastNeed)&&(t=Buffer.from(t,e)),Buffer.isBuffer(t)&&this[j]&&(t=this[X].write(t)),this[x]&&this[C]!==0&&this[gt](!0),this[x]?this.emit("data",t):this[Ft](t),this[C]!==0&&this.emit("readable"),i&&s(i),this[x]):(this[C]!==0&&this.emit("readable"),i&&s(i),this[x])}read(t){if(this[E])return null;if(this[M]=!1,this[C]===0||t===0||t&&t>this[C])return this[B](),null;this[O]&&(t=null),this[k].length>1&&!this[O]&&(this[k]=[this[j]?this[k].join(""):Buffer.concat(this[k],this[C])]);let e=this[Qt](t||null,this[k][0]);return this[B](),e}[Qt](t,e){if(this[O])this[wt]();else{let i=e;t===i.length||t===null?this[wt]():typeof i=="string"?(this[k][0]=i.slice(t),e=i.slice(0,t),this[C]-=t):(this[k][0]=i.subarray(t),e=i.subarray(0,t),this[C]-=t)}return this.emit("data",e),!this[k].length&&!this[$]&&this.emit("drain"),e}end(t,e,i){return typeof t=="function"&&(i=t,t=void 0),typeof e=="function"&&(i=e,e="utf8"),t!==void 0&&this.write(t,e),i&&this.once("end",i),this[$]=!0,this.writable=!1,(this[x]||!this[st])&&this[B](),this}[Q](){this[E]||(!this[q]&&!this[A].length&&(this[M]=!0),this[st]=!1,this[x]=!0,this.emit("resume"),this[k].length?this[gt]():this[$]?this[B]():this.emit("drain"))}resume(){return this[Q]()}pause(){this[x]=!1,this[st]=!0,this[M]=!1}get destroyed(){return this[E]}get flowing(){return this[x]}get paused(){return this[st]}[Ft](t){this[O]?this[C]+=1:this[C]+=t.length,this[k].push(t)}[wt](){return this[O]?this[C]-=1:this[C]-=this[k][0].length,this[k].shift()}[gt](t=!1){do;while(this[te](this[wt]())&&this[k].length);!t&&!this[k].length&&!this[$]&&this.emit("drain")}[te](t){return this.emit("data",t),this[x]}pipe(t,e){if(this[E])return t;this[M]=!1;let i=this[G];return e=e||{},t===Xt.stdout||t===Xt.stderr?e.end=!1:e.end=e.end!==!1,e.proxyErrors=!!e.proxyErrors,i?e.end&&t.end():(this[A].push(e.proxyErrors?new Cs(this,t,e):new Fe(this,t,e)),this[_]?ht(()=>this[Q]()):this[Q]()),t}unpipe(t){let e=this[A].find(i=>i.dest===t);e&&(this[A].length===1?(this[x]&&this[q]===0&&(this[x]=!1),this[A]=[]):this[A].splice(this[A].indexOf(e),1),e.unpipe())}addListener(t,e){return this.on(t,e)}on(t,e){let i=super.on(t,e);if(t==="data")this[M]=!1,this[q]++,!this[A].length&&!this[x]&&this[Q]();else if(t==="readable"&&this[C]!==0)super.emit("readable");else if(Es(t)&&this[G])super.emit(t),this.removeAllListeners(t);else if(t==="error"&&this[it]){let s=e;this[_]?ht(()=>s.call(this,this[it])):s.call(this,this[it])}return i}removeListener(t,e){return this.off(t,e)}off(t,e){let i=super.off(t,e);return t==="data"&&(this[q]=this.listeners("data").length,this[q]===0&&!this[M]&&!this[A].length&&(this[x]=!1)),i}removeAllListeners(t){let e=super.removeAllListeners(t);return(t==="data"||t===void 0)&&(this[q]=0,!this[M]&&!this[A].length&&(this[x]=!1)),e}get emittedEnd(){return this[G]}[B](){!this[ft]&&!this[G]&&!this[E]&&this[k].length===0&&this[$]&&(this[ft]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[dt]&&this.emit("close"),this[ft]=!1)}emit(t,...e){let i=e[0];if(t!=="error"&&t!=="close"&&t!==E&&this[E])return!1;if(t==="data")return!this[O]&&!i?!1:this[_]?(ht(()=>this[Wt](i)),!0):this[Wt](i);if(t==="end")return this[ee]();if(t==="close"){if(this[dt]=!0,!this[G]&&!this[E])return!1;let r=super.emit("close");return this.removeAllListeners("close"),r}else if(t==="error"){this[it]=i,super.emit(Mt,i);let r=!this[rt]||this.listeners("error").length?super.emit("error",i):!1;return this[B](),r}else if(t==="resume"){let r=super.emit("resume");return this[B](),r}else if(t==="finish"||t==="prefinish"){let r=super.emit(t);return this.removeAllListeners(t),r}let s=super.emit(t,...e);return this[B](),s}[Wt](t){for(let i of this[A])i.dest.write(t)===!1&&this.pause();let e=this[M]?!1:super.emit("data",t);return this[B](),e}[ee](){return this[G]?!1:(this[G]=!0,this.readable=!1,this[_]?(ht(()=>this[Pt]()),!0):this[Pt]())}[Pt](){if(this[X]){let e=this[X].end();if(e){for(let i of this[A])i.dest.write(e);this[M]||super.emit("data",e)}}for(let e of this[A])e.end();let t=super.emit("end");return this.removeAllListeners("end"),t}async collect(){let t=Object.assign([],{dataLength:0});this[O]||(t.dataLength=0);let e=this.promise();return this.on("data",i=>{t.push(i),this[O]||(t.dataLength+=i.length)}),await e,t}async concat(){if(this[O])throw new Error("cannot concat in objectMode");let t=await this.collect();return this[j]?t.join(""):Buffer.concat(t,t.dataLength)}async promise(){return new Promise((t,e)=>{this.on(E,()=>e(new Error("stream destroyed"))),this.on("error",i=>e(i)),this.on("end",()=>t())})}[Symbol.asyncIterator](){this[M]=!1;let t=!1,e=async()=>(this.pause(),t=!0,{value:void 0,done:!0});return{next:()=>{if(t)return e();let i=this.read();if(i!==null)return Promise.resolve({done:!1,value:i});if(this[$])return e();let s,r,h=a=>{this.off("data",n),this.off("end",o),this.off(E,l),e(),r(a)},n=a=>{this.off("error",h),this.off("end",o),this.off(E,l),this.pause(),s({value:a,done:!!this[$]})},o=()=>{this.off("error",h),this.off("data",n),this.off(E,l),e(),s({done:!0,value:void 0})},l=()=>h(new Error("stream destroyed"));return new Promise((a,u)=>{r=u,s=a,this.once(E,l),this.once("error",h),this.once("end",o),this.once("data",n)})},throw:e,return:e,[Symbol.asyncIterator](){return this}}}[Symbol.iterator](){this[M]=!1;let t=!1,e=()=>(this.pause(),this.off(Mt,e),this.off(E,e),this.off("end",e),t=!0,{done:!0,value:void 0}),i=()=>{if(t)return e();let s=this.read();return s===null?e():{done:!1,value:s}};return this.once("end",e),this.once(Mt,e),this.once(E,e),{next:i,throw:e,return:e,[Symbol.iterator](){return this}}}destroy(t){if(this[E])return t?this.emit("error",t):this.emit(E),this;this[E]=!0,this[M]=!0,this[k].length=0,this[C]=0;let e=this;return typeof e.close=="function"&&!this[dt]&&e.close(),t?this.emit("error",t):this.emit(E),this}static get isStream(){return ys}},Ts=us.native,at={lstatSync:os,readdir:ls,readdirSync:as,readlinkSync:cs,realpathSync:Ts,promises:{lstat:fs,readdir:ds,readlink:gs,realpath:ws}},Me=t=>!t||t===at||t===ps?at:{...at,...t,promises:{...at.promises,...t.promises||{}}},We=/^\\\\\?\\([a-z]:)\\?$/i,Rs=t=>t.replace(/\//g,"\\").replace(We,"$1\\"),Fs=/[\\\/]/,D=0,Pe=1,Le=2,N=4,De=6,je=8,Z=10,ze=12,L=15,nt=~L,Dt=16,ie=32,ct=64,z=128,yt=256,vt=512,se=ct|z|vt,Ms=1023,jt=t=>t.isFile()?je:t.isDirectory()?N:t.isSymbolicLink()?Z:t.isCharacterDevice()?Le:t.isBlockDevice()?De:t.isSocket()?ze:t.isFIFO()?Pe:D,re=new Ct({max:2**12}),ut=t=>{let e=re.get(t);if(e)return e;let i=t.normalize("NFKD");return re.set(t,i),i},he=new Ct({max:2**12}),bt=t=>{let e=he.get(t);if(e)return e;let i=ut(t.toLowerCase());return he.set(t,i),i},ne=class extends Ct{constructor(){super({max:256})}},Ws=class extends Ct{constructor(t=16*1024){super({maxSize:t,sizeCalculation:e=>e.length+1})}},_e=Symbol("PathScurry setAsCwd"),F=class{name;root;roots;parent;nocase;isCWD=!1;#t;#i;get dev(){return this.#i}#h;get mode(){return this.#h}#r;get nlink(){return this.#r}#n;get uid(){return this.#n}#S;get gid(){return this.#S}#m;get rdev(){return this.#m}#c;get blksize(){return this.#c}#o;get ino(){return this.#o}#p;get size(){return this.#p}#u;get blocks(){return this.#u}#l;get atimeMs(){return this.#l}#s;get mtimeMs(){return this.#s}#f;get ctimeMs(){return this.#f}#v;get birthtimeMs(){return this.#v}#b;get atime(){return this.#b}#d;get mtime(){return this.#d}#T;get ctime(){return this.#T}#g;get birthtime(){return this.#g}#k;#C;#w;#y;#E;#O;#e;#L;#W;#A;get parentPath(){return(this.parent||this).fullpath()}get path(){return this.parentPath}constructor(t,e=D,i,s,r,h,n){this.name=t,this.#k=r?bt(t):ut(t),this.#e=e&Ms,this.nocase=r,this.roots=s,this.root=i||this,this.#L=h,this.#w=n.fullpath,this.#E=n.relative,this.#O=n.relativePosix,this.parent=n.parent,this.parent?this.#t=this.parent.#t:this.#t=Me(n.fs)}depth(){return this.#C!==void 0?this.#C:this.parent?this.#C=this.parent.depth()+1:this.#C=0}childrenCache(){return this.#L}resolve(t){if(!t)return this;let e=this.getRootString(t),i=t.substring(e.length).split(this.splitSep);return e?this.getRoot(e).#P(i):this.#P(i)}#P(t){let e=this;for(let i of t)e=e.child(i);return e}children(){let t=this.#L.get(this);if(t)return t;let e=Object.assign([],{provisional:0});return this.#L.set(this,e),this.#e&=~Dt,e}child(t,e){if(t===""||t===".")return this;if(t==="..")return this.parent||this;let i=this.children(),s=this.nocase?bt(t):ut(t);for(let o of i)if(o.#k===s)return o;let r=this.parent?this.sep:"",h=this.#w?this.#w+r+t:void 0,n=this.newChild(t,D,{...e,parent:this,fullpath:h});return this.canReaddir()||(n.#e|=z),i.push(n),n}relative(){if(this.isCWD)return"";if(this.#E!==void 0)return this.#E;let t=this.name,e=this.parent;if(!e)return this.#E=this.name;let i=e.relative();return i+(!i||!e.parent?"":this.sep)+t}relativePosix(){if(this.sep==="/")return this.relative();if(this.isCWD)return"";if(this.#O!==void 0)return this.#O;let t=this.name,e=this.parent;if(!e)return this.#O=this.fullpathPosix();let i=e.relativePosix();return i+(!i||!e.parent?"":"/")+t}fullpath(){if(this.#w!==void 0)return this.#w;let t=this.name,e=this.parent;if(!e)return this.#w=this.name;let i=e.fullpath()+(e.parent?this.sep:"")+t;return this.#w=i}fullpathPosix(){if(this.#y!==void 0)return this.#y;if(this.sep==="/")return this.#y=this.fullpath();if(!this.parent){let s=this.fullpath().replace(/\\/g,"/");return/^[a-z]:\//i.test(s)?this.#y=`//?/${s}`:this.#y=s}let t=this.parent,e=t.fullpathPosix(),i=e+(!e||!t.parent?"":"/")+this.name;return this.#y=i}isUnknown(){return(this.#e&L)===D}isType(t){return this[`is${t}`]()}getType(){return this.isUnknown()?"Unknown":this.isDirectory()?"Directory":this.isFile()?"File":this.isSymbolicLink()?"SymbolicLink":this.isFIFO()?"FIFO":this.isCharacterDevice()?"CharacterDevice":this.isBlockDevice()?"BlockDevice":this.isSocket()?"Socket":"Unknown"}isFile(){return(this.#e&L)===je}isDirectory(){return(this.#e&L)===N}isCharacterDevice(){return(this.#e&L)===Le}isBlockDevice(){return(this.#e&L)===De}isFIFO(){return(this.#e&L)===Pe}isSocket(){return(this.#e&L)===ze}isSymbolicLink(){return(this.#e&Z)===Z}lstatCached(){return this.#e&ie?this:void 0}readlinkCached(){return this.#W}realpathCached(){return this.#A}readdirCached(){let t=this.children();return t.slice(0,t.provisional)}canReadlink(){if(this.#W)return!0;if(!this.parent)return!1;let t=this.#e&L;return!(t!==D&&t!==Z||this.#e&yt||this.#e&z)}calledReaddir(){return!!(this.#e&Dt)}isENOENT(){return!!(this.#e&z)}isNamed(t){return this.nocase?this.#k===bt(t):this.#k===ut(t)}async readlink(){let t=this.#W;if(t)return t;if(this.canReadlink()&&this.parent)try{let e=await this.#t.promises.readlink(this.fullpath()),i=(await this.parent.realpath())?.resolve(e);if(i)return this.#W=i}catch(e){this.#M(e.code);return}}readlinkSync(){let t=this.#W;if(t)return t;if(this.canReadlink()&&this.parent)try{let e=this.#t.readlinkSync(this.fullpath()),i=this.parent.realpathSync()?.resolve(e);if(i)return this.#W=i}catch(e){this.#M(e.code);return}}#_(t){this.#e|=Dt;for(let e=t.provisional;e<t.length;e++){let i=t[e];i&&i.#x()}}#x(){this.#e&z||(this.#e=(this.#e|z)&nt,this.#I())}#I(){let t=this.children();t.provisional=0;for(let e of t)e.#x()}#z(){this.#e|=vt,this.#D()}#D(){if(this.#e&ct)return;let t=this.#e;(t&L)===N&&(t&=nt),this.#e=t|ct,this.#I()}#N(t=""){t==="ENOTDIR"||t==="EPERM"?this.#D():t==="ENOENT"?this.#x():this.children().provisional=0}#F(t=""){t==="ENOTDIR"?this.parent.#D():t==="ENOENT"&&this.#x()}#M(t=""){let e=this.#e;e|=yt,t==="ENOENT"&&(e|=z),(t==="EINVAL"||t==="UNKNOWN")&&(e&=nt),this.#e=e,t==="ENOTDIR"&&this.parent&&this.parent.#D()}#$(t,e){return this.#U(t,e)||this.#B(t,e)}#B(t,e){let i=jt(t),s=this.newChild(t.name,i,{parent:this}),r=s.#e&L;return r!==N&&r!==Z&&r!==D&&(s.#e|=ct),e.unshift(s),e.provisional++,s}#U(t,e){for(let i=e.provisional;i<e.length;i++){let s=e[i];if((this.nocase?bt(t.name):ut(t.name))===s.#k)return this.#a(t,s,i,e)}}#a(t,e,i,s){let r=e.name;return e.#e=e.#e&nt|jt(t),r!==t.name&&(e.name=t.name),i!==s.provisional&&(i===s.length-1?s.pop():s.splice(i,1),s.unshift(e)),s.provisional++,e}async lstat(){if((this.#e&z)===0)try{return this.#G(await this.#t.promises.lstat(this.fullpath())),this}catch(t){this.#F(t.code)}}lstatSync(){if((this.#e&z)===0)try{return this.#G(this.#t.lstatSync(this.fullpath())),this}catch(t){this.#F(t.code)}}#G(t){let{atime:e,atimeMs:i,birthtime:s,birthtimeMs:r,blksize:h,blocks:n,ctime:o,ctimeMs:l,dev:a,gid:u,ino:c,mode:f,mtime:p,mtimeMs:d,nlink:g,rdev:m,size:w,uid:y}=t;this.#b=e,this.#l=i,this.#g=s,this.#v=r,this.#c=h,this.#u=n,this.#T=o,this.#f=l,this.#i=a,this.#S=u,this.#o=c,this.#h=f,this.#d=p,this.#s=d,this.#r=g,this.#m=m,this.#p=w,this.#n=y;let b=jt(t);this.#e=this.#e&nt|b|ie,b!==D&&b!==N&&b!==Z&&(this.#e|=ct)}#j=[];#R=!1;#H(t){this.#R=!1;let e=this.#j.slice();this.#j.length=0,e.forEach(i=>i(null,t))}readdirCB(t,e=!1){if(!this.canReaddir()){e?t(null,[]):queueMicrotask(()=>t(null,[]));return}let i=this.children();if(this.calledReaddir()){let r=i.slice(0,i.provisional);e?t(null,r):queueMicrotask(()=>t(null,r));return}if(this.#j.push(t),this.#R)return;this.#R=!0;let s=this.fullpath();this.#t.readdir(s,{withFileTypes:!0},(r,h)=>{if(r)this.#N(r.code),i.provisional=0;else{for(let n of h)this.#$(n,i);this.#_(i)}this.#H(i.slice(0,i.provisional))})}#q;async readdir(){if(!this.canReaddir())return[];let t=this.children();if(this.calledReaddir())return t.slice(0,t.provisional);let e=this.fullpath();if(this.#q)await this.#q;else{let i=()=>{};this.#q=new Promise(s=>i=s);try{for(let s of await this.#t.promises.readdir(e,{withFileTypes:!0}))this.#$(s,t);this.#_(t)}catch(s){this.#N(s.code),t.provisional=0}this.#q=void 0,i()}return t.slice(0,t.provisional)}readdirSync(){if(!this.canReaddir())return[];let t=this.children();if(this.calledReaddir())return t.slice(0,t.provisional);let e=this.fullpath();try{for(let i of this.#t.readdirSync(e,{withFileTypes:!0}))this.#$(i,t);this.#_(t)}catch(i){this.#N(i.code),t.provisional=0}return t.slice(0,t.provisional)}canReaddir(){if(this.#e&se)return!1;let t=L&this.#e;return t===D||t===N||t===Z}shouldWalk(t,e){return(this.#e&N)===N&&!(this.#e&se)&&!t.has(this)&&(!e||e(this))}async realpath(){if(this.#A)return this.#A;if(!((vt|yt|z)&this.#e))try{let t=await this.#t.promises.realpath(this.fullpath());return this.#A=this.resolve(t)}catch{this.#z()}}realpathSync(){if(this.#A)return this.#A;if(!((vt|yt|z)&this.#e))try{let t=this.#t.realpathSync(this.fullpath());return this.#A=this.resolve(t)}catch{this.#z()}}[_e](t){if(t===this)return;t.isCWD=!1,this.isCWD=!0;let e=new Set([]),i=[],s=this;for(;s&&s.parent;)e.add(s),s.#E=i.join(this.sep),s.#O=i.join("/"),s=s.parent,i.push("..");for(s=t;s&&s.parent&&!e.has(s);)s.#E=void 0,s.#O=void 0,s=s.parent}},Ne=class $e extends F{sep="\\";splitSep=Fs;constructor(e,i=D,s,r,h,n,o){super(e,i,s,r,h,n,o)}newChild(e,i=D,s={}){return new $e(e,i,this.root,this.roots,this.nocase,this.childrenCache(),s)}getRootString(e){return _t.parse(e).root}getRoot(e){if(e=Rs(e.toUpperCase()),e===this.root.name)return this.root;for(let[i,s]of Object.entries(this.roots))if(this.sameRoot(e,i))return this.roots[e]=s;return this.roots[e]=new Ut(e,this).root}sameRoot(e,i=this.root.name){return e=e.toUpperCase().replace(/\//g,"\\").replace(We,"$1\\"),e===i}},Be=class Ue extends F{splitSep="/";sep="/";constructor(e,i=D,s,r,h,n,o){super(e,i,s,r,h,n,o)}getRootString(e){return e.startsWith("/")?"/":""}getRoot(e){return this.root}newChild(e,i=D,s={}){return new Ue(e,i,this.root,this.roots,this.nocase,this.childrenCache(),s)}},Ge=class{root;rootPath;roots;cwd;#t;#i;#h;nocase;#r;constructor(t=process.cwd(),e,i,{nocase:s,childrenCacheSize:r=16*1024,fs:h=at}={}){this.#r=Me(h),(t instanceof URL||t.startsWith("file://"))&&(t=ns(t));let n=e.resolve(t);this.roots=Object.create(null),this.rootPath=this.parseRootPath(n),this.#t=new ne,this.#i=new ne,this.#h=new Ws(r);let o=n.substring(this.rootPath.length).split(i);if(o.length===1&&!o[0]&&o.pop(),s===void 0)throw new TypeError("must provide nocase setting to PathScurryBase ctor");this.nocase=s,this.root=this.newRoot(this.#r),this.roots[this.rootPath]=this.root;let l=this.root,a=o.length-1,u=e.sep,c=this.rootPath,f=!1;for(let p of o){let d=a--;l=l.child(p,{relative:new Array(d).fill("..").join(u),relativePosix:new Array(d).fill("..").join("/"),fullpath:c+=(f?"":u)+p}),f=!0}this.cwd=l}depth(t=this.cwd){return typeof t=="string"&&(t=this.cwd.resolve(t)),t.depth()}childrenCache(){return this.#h}resolve(...t){let e="";for(let r=t.length-1;r>=0;r--){let h=t[r];if(!(!h||h===".")&&(e=e?`${h}/${e}`:h,this.isAbsolute(h)))break}let i=this.#t.get(e);if(i!==void 0)return i;let s=this.cwd.resolve(e).fullpath();return this.#t.set(e,s),s}resolvePosix(...t){let e="";for(let r=t.length-1;r>=0;r--){let h=t[r];if(!(!h||h===".")&&(e=e?`${h}/${e}`:h,this.isAbsolute(h)))break}let i=this.#i.get(e);if(i!==void 0)return i;let s=this.cwd.resolve(e).fullpathPosix();return this.#i.set(e,s),s}relative(t=this.cwd){return typeof t=="string"&&(t=this.cwd.resolve(t)),t.relative()}relativePosix(t=this.cwd){return typeof t=="string"&&(t=this.cwd.resolve(t)),t.relativePosix()}basename(t=this.cwd){return typeof t=="string"&&(t=this.cwd.resolve(t)),t.name}dirname(t=this.cwd){return typeof t=="string"&&(t=this.cwd.resolve(t)),(t.parent||t).fullpath()}async readdir(t=this.cwd,e={withFileTypes:!0}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t,t=this.cwd);let{withFileTypes:i}=e;if(t.canReaddir()){let s=await t.readdir();return i?s:s.map(r=>r.name)}else return[]}readdirSync(t=this.cwd,e={withFileTypes:!0}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t,t=this.cwd);let{withFileTypes:i=!0}=e;return t.canReaddir()?i?t.readdirSync():t.readdirSync().map(s=>s.name):[]}async lstat(t=this.cwd){return typeof t=="string"&&(t=this.cwd.resolve(t)),t.lstat()}lstatSync(t=this.cwd){return typeof t=="string"&&(t=this.cwd.resolve(t)),t.lstatSync()}async readlink(t=this.cwd,{withFileTypes:e}={withFileTypes:!1}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t.withFileTypes,t=this.cwd);let i=await t.readlink();return e?i:i?.fullpath()}readlinkSync(t=this.cwd,{withFileTypes:e}={withFileTypes:!1}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t.withFileTypes,t=this.cwd);let i=t.readlinkSync();return e?i:i?.fullpath()}async realpath(t=this.cwd,{withFileTypes:e}={withFileTypes:!1}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t.withFileTypes,t=this.cwd);let i=await t.realpath();return e?i:i?.fullpath()}realpathSync(t=this.cwd,{withFileTypes:e}={withFileTypes:!1}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t.withFileTypes,t=this.cwd);let i=t.realpathSync();return e?i:i?.fullpath()}async walk(t=this.cwd,e={}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t,t=this.cwd);let{withFileTypes:i=!0,follow:s=!1,filter:r,walkFilter:h}=e,n=[];(!r||r(t))&&n.push(i?t:t.fullpath());let o=new Set,l=(u,c)=>{o.add(u),u.readdirCB((f,p)=>{if(f)return c(f);let d=p.length;if(!d)return c();let g=()=>{--d===0&&c()};for(let m of p)(!r||r(m))&&n.push(i?m:m.fullpath()),s&&m.isSymbolicLink()?m.realpath().then(w=>w?.isUnknown()?w.lstat():w).then(w=>w?.shouldWalk(o,h)?l(w,g):g()):m.shouldWalk(o,h)?l(m,g):g()},!0)},a=t;return new Promise((u,c)=>{l(a,f=>{if(f)return c(f);u(n)})})}walkSync(t=this.cwd,e={}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t,t=this.cwd);let{withFileTypes:i=!0,follow:s=!1,filter:r,walkFilter:h}=e,n=[];(!r||r(t))&&n.push(i?t:t.fullpath());let o=new Set([t]);for(let l of o){let a=l.readdirSync();for(let u of a){(!r||r(u))&&n.push(i?u:u.fullpath());let c=u;if(u.isSymbolicLink()){if(!(s&&(c=u.realpathSync())))continue;c.isUnknown()&&c.lstatSync()}c.shouldWalk(o,h)&&o.add(c)}}return n}[Symbol.asyncIterator](){return this.iterate()}iterate(t=this.cwd,e={}){return typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t,t=this.cwd),this.stream(t,e)[Symbol.asyncIterator]()}[Symbol.iterator](){return this.iterateSync()}*iterateSync(t=this.cwd,e={}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t,t=this.cwd);let{withFileTypes:i=!0,follow:s=!1,filter:r,walkFilter:h}=e;(!r||r(t))&&(yield i?t:t.fullpath());let n=new Set([t]);for(let o of n){let l=o.readdirSync();for(let a of l){(!r||r(a))&&(yield i?a:a.fullpath());let u=a;if(a.isSymbolicLink()){if(!(s&&(u=a.realpathSync())))continue;u.isUnknown()&&u.lstatSync()}u.shouldWalk(n,h)&&n.add(u)}}}stream(t=this.cwd,e={}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t,t=this.cwd);let{withFileTypes:i=!0,follow:s=!1,filter:r,walkFilter:h}=e,n=new kt({objectMode:!0});(!r||r(t))&&n.write(i?t:t.fullpath());let o=new Set,l=[t],a=0,u=()=>{let c=!1;for(;!c;){let f=l.shift();if(!f){a===0&&n.end();return}a++,o.add(f);let p=(g,m,w=!1)=>{if(g)return n.emit("error",g);if(s&&!w){let y=[];for(let b of m)b.isSymbolicLink()&&y.push(b.realpath().then(S=>S?.isUnknown()?S.lstat():S));if(y.length){Promise.all(y).then(()=>p(null,m,!0));return}}for(let y of m)y&&(!r||r(y))&&(n.write(i?y:y.fullpath())||(c=!0));a--;for(let y of m){let b=y.realpathCached()||y;b.shouldWalk(o,h)&&l.push(b)}c&&!n.flowing?n.once("drain",u):d||u()},d=!0;f.readdirCB(p,!0),d=!1}};return u(),n}streamSync(t=this.cwd,e={}){typeof t=="string"?t=this.cwd.resolve(t):t instanceof F||(e=t,t=this.cwd);let{withFileTypes:i=!0,follow:s=!1,filter:r,walkFilter:h}=e,n=new kt({objectMode:!0}),o=new Set;(!r||r(t))&&n.write(i?t:t.fullpath());let l=[t],a=0,u=()=>{let c=!1;for(;!c;){let f=l.shift();if(!f){a===0&&n.end();return}a++,o.add(f);let p=f.readdirSync();for(let d of p)(!r||r(d))&&(n.write(i?d:d.fullpath())||(c=!0));a--;for(let d of p){let g=d;if(d.isSymbolicLink()){if(!(s&&(g=d.realpathSync())))continue;g.isUnknown()&&g.lstatSync()}g.shouldWalk(o,h)&&l.push(g)}}c&&!n.flowing&&n.once("drain",u)};return u(),n}chdir(t=this.cwd){let e=this.cwd;this.cwd=typeof t=="string"?this.cwd.resolve(t):t,this.cwd[_e](e)}},Ut=class extends Ge{sep="\\";constructor(t=process.cwd(),e={}){let{nocase:i=!0}=e;super(t,_t,"\\",{...e,nocase:i}),this.nocase=i;for(let s=this.cwd;s;s=s.parent)s.nocase=this.nocase}parseRootPath(t){return _t.parse(t).root.toUpperCase()}newRoot(t){return new Ne(this.rootPath,N,void 0,this.roots,this.nocase,this.childrenCache(),{fs:t})}isAbsolute(t){return t.startsWith("/")||t.startsWith("\\")||/^[a-z]:(\/|\\)/i.test(t)}},Gt=class extends Ge{sep="/";constructor(t=process.cwd(),e={}){let{nocase:i=!1}=e;super(t,hs,"/",{...e,nocase:i}),this.nocase=i}parseRootPath(t){return"/"}newRoot(t){return new Be(this.rootPath,N,void 0,this.roots,this.nocase,this.childrenCache(),{fs:t})}isAbsolute(t){return t.startsWith("/")}},Ie=class extends Gt{constructor(t=process.cwd(),e={}){let{nocase:i=!0}=e;super(t,{...e,nocase:i})}},sr=process.platform==="win32"?Ne:Be,Ps=process.platform==="win32"?Ut:process.platform==="darwin"?Ie:Gt,Ls=t=>t.length>=1,Ds=t=>t.length>=1,js=Symbol.for("nodejs.util.inspect.custom"),He=class qe{#t;#i;#h;length;#r;#n;#S;#m;#c;#o;#p=!0;constructor(e,i,s,r){if(!Ls(e))throw new TypeError("empty pattern list");if(!Ds(i))throw new TypeError("empty glob list");if(i.length!==e.length)throw new TypeError("mismatched pattern list and glob list lengths");if(this.length=e.length,s<0||s>=this.length)throw new TypeError("index out of range");if(this.#t=e,this.#i=i,this.#h=s,this.#r=r,this.#h===0){if(this.isUNC()){let[h,n,o,l,...a]=this.#t,[u,c,f,p,...d]=this.#i;a[0]===""&&(a.shift(),d.shift());let g=[h,n,o,l,""].join("/"),m=[u,c,f,p,""].join("/");this.#t=[g,...a],this.#i=[m,...d],this.length=this.#t.length}else if(this.isDrive()||this.isAbsolute()){let[h,...n]=this.#t,[o,...l]=this.#i;n[0]===""&&(n.shift(),l.shift());let a=h+"/",u=o+"/";this.#t=[a,...n],this.#i=[u,...l],this.length=this.#t.length}}}[js](){return"Pattern <"+this.#i.slice(this.#h).join("/")+">"}pattern(){return this.#t[this.#h]}isString(){return typeof this.#t[this.#h]=="string"}isGlobstar(){return this.#t[this.#h]===T}isRegExp(){return this.#t[this.#h]instanceof RegExp}globString(){return this.#S=this.#S||(this.#h===0?this.isAbsolute()?this.#i[0]+this.#i.slice(1).join("/"):this.#i.join("/"):this.#i.slice(this.#h).join("/"))}hasMore(){return this.length>this.#h+1}rest(){return this.#n!==void 0?this.#n:this.hasMore()?(this.#n=new qe(this.#t,this.#i,this.#h+1,this.#r),this.#n.#o=this.#o,this.#n.#c=this.#c,this.#n.#m=this.#m,this.#n):this.#n=null}isUNC(){let e=this.#t;return this.#c!==void 0?this.#c:this.#c=this.#r==="win32"&&this.#h===0&&e[0]===""&&e[1]===""&&typeof e[2]=="string"&&!!e[2]&&typeof e[3]=="string"&&!!e[3]}isDrive(){let e=this.#t;return this.#m!==void 0?this.#m:this.#m=this.#r==="win32"&&this.#h===0&&this.length>1&&typeof e[0]=="string"&&/^[a-z]:$/i.test(e[0])}isAbsolute(){let e=this.#t;return this.#o!==void 0?this.#o:this.#o=e[0]===""&&e.length>1||this.isDrive()||this.isUNC()}root(){let e=this.#t[0];return typeof e=="string"&&this.isAbsolute()&&this.#h===0?e:""}checkFollowGlobstar(){return!(this.#h===0||!this.isGlobstar()||!this.#p)}markFollowGlobstar(){return this.#h===0||!this.isGlobstar()||!this.#p?!1:(this.#p=!1,!0)}},zs=typeof process=="object"&&process&&typeof process.platform=="string"?process.platform:"linux",oe=class{relative;relativeChildren;absolute;absoluteChildren;platform;mmopts;constructor(t,{nobrace:e,nocase:i,noext:s,noglobstar:r,platform:h=zs}){this.relative=[],this.absolute=[],this.relativeChildren=[],this.absoluteChildren=[],this.platform=h,this.mmopts={dot:!0,nobrace:e,nocase:i,noext:s,noglobstar:r,optimizationLevel:2,platform:h,nocomment:!0,nonegate:!0};for(let n of t)this.add(n)}add(t){let e=new H(t,this.mmopts);for(let i=0;i<e.set.length;i++){let s=e.set[i],r=e.globParts[i];if(!s||!r)throw new Error("invalid pattern object");for(;s[0]==="."&&r[0]===".";)s.shift(),r.shift();let h=new He(s,r,0,this.platform),n=new H(h.globString(),this.mmopts),o=r[r.length-1]==="**",l=h.isAbsolute();l?this.absolute.push(n):this.relative.push(n),o&&(l?this.absoluteChildren.push(n):this.relativeChildren.push(n))}}ignored(t){let e=t.fullpath(),i=`${e}/`,s=t.relative()||".",r=`${s}/`;for(let h of this.relative)if(h.match(s)||h.match(r))return!0;for(let h of this.absolute)if(h.match(e)||h.match(i))return!0;return!1}childrenIgnored(t){let e=t.fullpath()+"/",i=(t.relative()||".")+"/";for(let s of this.relativeChildren)if(s.match(i))return!0;for(let s of this.absoluteChildren)if(s.match(e))return!0;return!1}},_s=class Ze{store;constructor(e=new Map){this.store=e}copy(){return new Ze(new Map(this.store))}hasWalked(e,i){return this.store.get(e.fullpath())?.has(i.globString())}storeWalked(e,i){let s=e.fullpath(),r=this.store.get(s);r?r.add(i.globString()):this.store.set(s,new Set([i.globString()]))}},Ns=class{store=new Map;add(t,e,i){let s=(e?2:0)|(i?1:0),r=this.store.get(t);this.store.set(t,r===void 0?s:s&r)}entries(){return[...this.store.entries()].map(([t,e])=>[t,!!(e&2),!!(e&1)])}},$s=class{store=new Map;add(t,e){if(!t.canReaddir())return;let i=this.store.get(t);i?i.find(s=>s.globString()===e.globString())||i.push(e):this.store.set(t,[e])}get(t){let e=this.store.get(t);if(!e)throw new Error("attempting to walk unknown path");return e}entries(){return this.keys().map(t=>[t,this.store.get(t)])}keys(){return[...this.store.keys()].filter(t=>t.canReaddir())}},le=class Je{hasWalkedCache;matches=new Ns;subwalks=new $s;patterns;follow;dot;opts;constructor(e,i){this.opts=e,this.follow=!!e.follow,this.dot=!!e.dot,this.hasWalkedCache=i?i.copy():new _s}processPatterns(e,i){this.patterns=i;let s=i.map(r=>[e,r]);for(let[r,h]of s){this.hasWalkedCache.storeWalked(r,h);let n=h.root(),o=h.isAbsolute()&&this.opts.absolute!==!1;if(n){r=r.resolve(n==="/"&&this.opts.root!==void 0?this.opts.root:n);let c=h.rest();if(c)h=c;else{this.matches.add(r,!0,!1);continue}}if(r.isENOENT())continue;let l,a,u=!1;for(;typeof(l=h.pattern())=="string"&&(a=h.rest());)r=r.resolve(l),h=a,u=!0;if(l=h.pattern(),a=h.rest(),u){if(this.hasWalkedCache.hasWalked(r,h))continue;this.hasWalkedCache.storeWalked(r,h)}if(typeof l=="string"){let c=l===".."||l===""||l===".";this.matches.add(r.resolve(l),o,c);continue}else if(l===T){(!r.isSymbolicLink()||this.follow||h.checkFollowGlobstar())&&this.subwalks.add(r,h);let c=a?.pattern(),f=a?.rest();if(!a||(c===""||c===".")&&!f)this.matches.add(r,o,c===""||c===".");else if(c===".."){let p=r.parent||r;f?this.hasWalkedCache.hasWalked(p,f)||this.subwalks.add(p,f):this.matches.add(p,o,!0)}}else l instanceof RegExp&&this.subwalks.add(r,h)}return this}subwalkTargets(){return this.subwalks.keys()}child(){return new Je(this.opts,this.hasWalkedCache)}filterEntries(e,i){let s=this.subwalks.get(e),r=this.child();for(let h of i)for(let n of s){let o=n.isAbsolute(),l=n.pattern(),a=n.rest();l===T?r.testGlobstar(h,n,a,o):l instanceof RegExp?r.testRegExp(h,l,a,o):r.testString(h,l,a,o)}return r}testGlobstar(e,i,s,r){if((this.dot||!e.name.startsWith("."))&&(i.hasMore()||this.matches.add(e,r,!1),e.canReaddir()&&(this.follow||!e.isSymbolicLink()?this.subwalks.add(e,i):e.isSymbolicLink()&&(s&&i.checkFollowGlobstar()?this.subwalks.add(e,s):i.markFollowGlobstar()&&this.subwalks.add(e,i)))),s){let h=s.pattern();if(typeof h=="string"&&h!==".."&&h!==""&&h!==".")this.testString(e,h,s.rest(),r);else if(h===".."){let n=e.parent||e;this.subwalks.add(n,s)}else h instanceof RegExp&&this.testRegExp(e,h,s.rest(),r)}}testRegExp(e,i,s,r){i.test(e.name)&&(s?this.subwalks.add(e,s):this.matches.add(e,r,!1))}testString(e,i,s,r){e.isNamed(i)&&(s?this.subwalks.add(e,s):this.matches.add(e,r,!1))}},Bs=(t,e)=>typeof t=="string"?new oe([t],e):Array.isArray(t)?new oe(t,e):t,Ve=class{path;patterns;opts;seen=new Set;paused=!1;aborted=!1;#t=[];#i;#h;signal;maxDepth;includeChildMatches;constructor(t,e,i){if(this.patterns=t,this.path=e,this.opts=i,this.#h=!i.posix&&i.platform==="win32"?"\\":"/",this.includeChildMatches=i.includeChildMatches!==!1,(i.ignore||!this.includeChildMatches)&&(this.#i=Bs(i.ignore??[],i),!this.includeChildMatches&&typeof this.#i.add!="function")){let s="cannot ignore child matches, ignore lacks add() method.";throw new Error(s)}this.maxDepth=i.maxDepth||1/0,i.signal&&(this.signal=i.signal,this.signal.addEventListener("abort",()=>{this.#t.length=0}))}#r(t){return this.seen.has(t)||!!this.#i?.ignored?.(t)}#n(t){return!!this.#i?.childrenIgnored?.(t)}pause(){this.paused=!0}resume(){if(this.signal?.aborted)return;this.paused=!1;let t;for(;!this.paused&&(t=this.#t.shift());)t()}onResume(t){this.signal?.aborted||(this.paused?this.#t.push(t):t())}async matchCheck(t,e){if(e&&this.opts.nodir)return;let i;if(this.opts.realpath){if(i=t.realpathCached()||await t.realpath(),!i)return;t=i}let s=t.isUnknown()||this.opts.stat?await t.lstat():t;if(this.opts.follow&&this.opts.nodir&&s?.isSymbolicLink()){let r=await s.realpath();r&&(r.isUnknown()||this.opts.stat)&&await r.lstat()}return this.matchCheckTest(s,e)}matchCheckTest(t,e){return t&&(this.maxDepth===1/0||t.depth()<=this.maxDepth)&&(!e||t.canReaddir())&&(!this.opts.nodir||!t.isDirectory())&&(!this.opts.nodir||!this.opts.follow||!t.isSymbolicLink()||!t.realpathCached()?.isDirectory())&&!this.#r(t)?t:void 0}matchCheckSync(t,e){if(e&&this.opts.nodir)return;let i;if(this.opts.realpath){if(i=t.realpathCached()||t.realpathSync(),!i)return;t=i}let s=t.isUnknown()||this.opts.stat?t.lstatSync():t;if(this.opts.follow&&this.opts.nodir&&s?.isSymbolicLink()){let r=s.realpathSync();r&&(r?.isUnknown()||this.opts.stat)&&r.lstatSync()}return this.matchCheckTest(s,e)}matchFinish(t,e){if(this.#r(t))return;if(!this.includeChildMatches&&this.#i?.add){let r=`${t.relativePosix()}/**`;this.#i.add(r)}let i=this.opts.absolute===void 0?e:this.opts.absolute;this.seen.add(t);let s=this.opts.mark&&t.isDirectory()?this.#h:"";if(this.opts.withFileTypes)this.matchEmit(t);else if(i){let r=this.opts.posix?t.fullpathPosix():t.fullpath();this.matchEmit(r+s)}else{let r=this.opts.posix?t.relativePosix():t.relative(),h=this.opts.dotRelative&&!r.startsWith(".."+this.#h)?"."+this.#h:"";this.matchEmit(r?h+r+s:"."+s)}}async match(t,e,i){let s=await this.matchCheck(t,i);s&&this.matchFinish(s,e)}matchSync(t,e,i){let s=this.matchCheckSync(t,i);s&&this.matchFinish(s,e)}walkCB(t,e,i){this.signal?.aborted&&i(),this.walkCB2(t,e,new le(this.opts),i)}walkCB2(t,e,i,s){if(this.#n(t))return s();if(this.signal?.aborted&&s(),this.paused){this.onResume(()=>this.walkCB2(t,e,i,s));return}i.processPatterns(t,e);let r=1,h=()=>{--r===0&&s()};for(let[n,o,l]of i.matches.entries())this.#r(n)||(r++,this.match(n,o,l).then(()=>h()));for(let n of i.subwalkTargets()){if(this.maxDepth!==1/0&&n.depth()>=this.maxDepth)continue;r++;let o=n.readdirCached();n.calledReaddir()?this.walkCB3(n,o,i,h):n.readdirCB((l,a)=>this.walkCB3(n,a,i,h),!0)}h()}walkCB3(t,e,i,s){i=i.filterEntries(t,e);let r=1,h=()=>{--r===0&&s()};for(let[n,o,l]of i.matches.entries())this.#r(n)||(r++,this.match(n,o,l).then(()=>h()));for(let[n,o]of i.subwalks.entries())r++,this.walkCB2(n,o,i.child(),h);h()}walkCBSync(t,e,i){this.signal?.aborted&&i(),this.walkCB2Sync(t,e,new le(this.opts),i)}walkCB2Sync(t,e,i,s){if(this.#n(t))return s();if(this.signal?.aborted&&s(),this.paused){this.onResume(()=>this.walkCB2Sync(t,e,i,s));return}i.processPatterns(t,e);let r=1,h=()=>{--r===0&&s()};for(let[n,o,l]of i.matches.entries())this.#r(n)||this.matchSync(n,o,l);for(let n of i.subwalkTargets()){if(this.maxDepth!==1/0&&n.depth()>=this.maxDepth)continue;r++;let o=n.readdirSync();this.walkCB3Sync(n,o,i,h)}h()}walkCB3Sync(t,e,i,s){i=i.filterEntries(t,e);let r=1,h=()=>{--r===0&&s()};for(let[n,o,l]of i.matches.entries())this.#r(n)||this.matchSync(n,o,l);for(let[n,o]of i.subwalks.entries())r++,this.walkCB2Sync(n,o,i.child(),h);h()}},ae=class extends Ve{matches=new Set;constructor(t,e,i){super(t,e,i)}matchEmit(t){this.matches.add(t)}async walk(){if(this.signal?.aborted)throw this.signal.reason;return this.path.isUnknown()&&await this.path.lstat(),await new Promise((t,e)=>{this.walkCB(this.path,this.patterns,()=>{this.signal?.aborted?e(this.signal.reason):t(this.matches)})}),this.matches}walkSync(){if(this.signal?.aborted)throw this.signal.reason;return this.path.isUnknown()&&this.path.lstatSync(),this.walkCBSync(this.path,this.patterns,()=>{if(this.signal?.aborted)throw this.signal.reason}),this.matches}},ce=class extends Ve{results;constructor(t,e,i){super(t,e,i),this.results=new kt({signal:this.signal,objectMode:!0}),this.results.on("drain",()=>this.resume()),this.results.on("resume",()=>this.resume())}matchEmit(t){this.results.write(t),this.results.flowing||this.pause()}stream(){let t=this.path;return t.isUnknown()?t.lstat().then(()=>{this.walkCB(t,this.patterns,()=>this.results.end())}):this.walkCB(t,this.patterns,()=>this.results.end()),this.results}streamSync(){return this.path.isUnknown()&&this.path.lstatSync(),this.walkCBSync(this.path,this.patterns,()=>this.results.end()),this.results}},Us=typeof process=="object"&&process&&typeof process.platform=="string"?process.platform:"linux",J=class{absolute;cwd;root;dot;dotRelative;follow;ignore;magicalBraces;mark;matchBase;maxDepth;nobrace;nocase;nodir;noext;noglobstar;pattern;platform;realpath;scurry;stat;signal;windowsPathsNoEscape;withFileTypes;includeChildMatches;opts;patterns;constructor(t,e){if(!e)throw new TypeError("glob options required");if(this.withFileTypes=!!e.withFileTypes,this.signal=e.signal,this.follow=!!e.follow,this.dot=!!e.dot,this.dotRelative=!!e.dotRelative,this.nodir=!!e.nodir,this.mark=!!e.mark,e.cwd?(e.cwd instanceof URL||e.cwd.startsWith("file://"))&&(e.cwd=es(e.cwd)):this.cwd="",this.cwd=e.cwd||"",this.root=e.root,this.magicalBraces=!!e.magicalBraces,this.nobrace=!!e.nobrace,this.noext=!!e.noext,this.realpath=!!e.realpath,this.absolute=e.absolute,this.includeChildMatches=e.includeChildMatches!==!1,this.noglobstar=!!e.noglobstar,this.matchBase=!!e.matchBase,this.maxDepth=typeof e.maxDepth=="number"?e.maxDepth:1/0,this.stat=!!e.stat,this.ignore=e.ignore,this.withFileTypes&&this.absolute!==void 0)throw new Error("cannot set absolute and withFileTypes:true");if(typeof t=="string"&&(t=[t]),this.windowsPathsNoEscape=!!e.windowsPathsNoEscape||e.allowWindowsEscape===!1,this.windowsPathsNoEscape&&(t=t.map(o=>o.replace(/\\/g,"/"))),this.matchBase){if(e.noglobstar)throw new TypeError("base matching requires globstar");t=t.map(o=>o.includes("/")?o:`./**/${o}`)}if(this.pattern=t,this.platform=e.platform||Us,this.opts={...e,platform:this.platform},e.scurry){if(this.scurry=e.scurry,e.nocase!==void 0&&e.nocase!==e.scurry.nocase)throw new Error("nocase option contradicts provided scurry option")}else{let o=e.platform==="win32"?Ut:e.platform==="darwin"?Ie:e.platform?Gt:Ps;this.scurry=new o(this.cwd,{nocase:e.nocase,fs:e.fs})}this.nocase=this.scurry.nocase;let i=this.platform==="darwin"||this.platform==="win32",s={braceExpandMax:1e4,...e,dot:this.dot,matchBase:this.matchBase,nobrace:this.nobrace,nocase:this.nocase,nocaseMagicOnly:i,nocomment:!0,noext:this.noext,nonegate:!0,optimizationLevel:2,platform:this.platform,windowsPathsNoEscape:this.windowsPathsNoEscape,debug:!!this.opts.debug},r=this.pattern.map(o=>new H(o,s)),[h,n]=r.reduce((o,l)=>(o[0].push(...l.set),o[1].push(...l.globParts),o),[[],[]]);this.patterns=h.map((o,l)=>{let a=n[l];if(!a)throw new Error("invalid pattern object");return new He(o,a,0,this.platform)})}async walk(){return[...await new ae(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).walk()]}walkSync(){return[...new ae(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).walkSync()]}stream(){return new ce(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).stream()}streamSync(){return new ce(this.patterns,this.scurry.cwd,{...this.opts,maxDepth:this.maxDepth!==1/0?this.maxDepth+this.scurry.cwd.depth():1/0,platform:this.platform,nocase:this.nocase,includeChildMatches:this.includeChildMatches}).streamSync()}iterateSync(){return this.streamSync()[Symbol.iterator]()}[Symbol.iterator](){return this.iterateSync()}iterate(){return this.stream()[Symbol.asyncIterator]()}[Symbol.asyncIterator](){return this.iterate()}},Gs=(t,e={})=>{Array.isArray(t)||(t=[t]);for(let i of t)if(new H(i,e).hasMagic())return!0;return!1};function Ot(t,e={}){return new J(t,e).streamSync()}function Ke(t,e={}){return new J(t,e).stream()}function Ye(t,e={}){return new J(t,e).walkSync()}async function ue(t,e={}){return new J(t,e).walk()}function At(t,e={}){return new J(t,e).iterateSync()}function Xe(t,e={}){return new J(t,e).iterate()}var Is=Ot,Hs=Object.assign(Ke,{sync:Ot}),qs=At,Zs=Object.assign(Xe,{sync:At}),Js=Object.assign(Ye,{stream:Ot,iterate:At}),pe=Object.assign(ue,{glob:ue,globSync:Ye,sync:Js,globStream:Ke,stream:Hs,globStreamSync:Ot,streamSync:Is,globIterate:Xe,iterate:Zs,globIterateSync:At,iterateSync:qs,Glob:J,hasMagic:Gs,escape:Se,unescape:tt});pe.glob=pe;export{J as Glob,oe as Ignore,Se as escape,pe as glob,Xe as globIterate,At as globIterateSync,Ke as globStream,Ot as globStreamSync,Ye as globSync,Gs as hasMagic,Zs as iterate,qs as iterateSync,Hs as stream,Is as streamSync,Js as sync,tt as unescape};
@@ -4,7 +4,7 @@ import { dirname as __pathDirname } from 'node:path';
4
4
  const require = __createRequire(import.meta.url);
5
5
  var __filename = __fileURLToPath(import.meta.url);
6
6
  var __dirname = __pathDirname(__filename);
7
- import{a as x,b as f,c as m,d}from"./TC3EIKUK.js";import{b as y,d as h,e as l}from"./LD5MEXEL.js";import{m as P}from"./UW4UC7ZI.js";import{join as E}from"node:path";function q(e,t){let n=x(e,"tanstack-query");if(n.length===0)return"";let r=t.pagination??new Map;return[j(n,t,r),...n.filter(f).map(i=>K(i,t.queryKeyPrefix)),Q(e,n,r,t.queryKeyPrefix,t.argsStyle),...R(n,r)].join(`
7
+ import{a as x,b as f,c as m,d}from"./PJRRECUU.js";import{b as y,d as h,e as l}from"./LD5MEXEL.js";import{m as P}from"./UW4UC7ZI.js";import{join as E}from"node:path";function q(e,t){let n=x(e,"tanstack-query");if(n.length===0)return"";let r=t.pagination??new Map;return[j(n,t,r),...n.filter(f).map(i=>K(i,t.queryKeyPrefix)),Q(e,n,r,t.queryKeyPrefix,t.argsStyle),...R(n,r)].join(`
8
8
  `)}function b(e,t){if(!f(e))return!1;let n=t.get(e.name);return n!==void 0&&n.spec.style!=="link"}function j(e,t,n){let r=[...e.some(a=>b(a,n))?["infiniteQueryOptions"]:[],...e.some(f)?["queryOptions"]:[]],s=[...e.filter(m).map(d),"RequestOptions"].sort().map(a=>`type ${a}`),i=[];return r.length>0&&i.push(`import { ${r.join(", ")} } from "@tanstack/${t.framework}-query";`),i.push(`import { client, ${s.join(", ")} } from "${t.sdkModule}";`),i.join(`
9
9
  `)}function K(e,t){let n=M(e,t);return m(e)?`export const ${e.name}QueryKey = (vars?: ${d(e)}) =>
10
10
  vars === undefined ? ([${n}] as const) : ([${n}, vars] as const);`:`export const ${e.name}QueryKey = () => [${n}] as const;`}function M(e,t){return t===void 0?`"${e.name}"`:`${h(t)}, "${e.name}"`}function Q(e,t,n,r,s){return`/**
@@ -4,5 +4,5 @@ import { dirname as __pathDirname } from 'node:path';
4
4
  const require = __createRequire(import.meta.url);
5
5
  var __filename = __fileURLToPath(import.meta.url);
6
6
  var __dirname = __pathDirname(__filename);
7
- import{X as t}from"./UVKEIQXW.js";import*as e from"node:process";var o=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],n=class{frames;currentFrame;intervalId;message;constructor(){this.frames=o,this.currentFrame=0,this.intervalId=null,this.message=""}showFrame(){t.info("\r"+this.frames[this.currentFrame]+" "+this.message),this.currentFrame=(this.currentFrame+1)%this.frames.length}start(r){if(this.message!==r){if(this.message=r,!e.stderr.isTTY){t.info(`${r}...
7
+ import{X as t}from"./ZOVYQ36P.js";import*as e from"node:process";var o=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],n=class{frames;currentFrame;intervalId;message;constructor(){this.frames=o,this.currentFrame=0,this.intervalId=null,this.message=""}showFrame(){t.info("\r"+this.frames[this.currentFrame]+" "+this.message),this.currentFrame=(this.currentFrame+1)%this.frames.length}start(r){if(this.message!==r){if(this.message=r,!e.stderr.isTTY){t.info(`${r}...
8
8
  `);return}this.intervalId===null&&(this.intervalId=setInterval(()=>{this.showFrame()},100))}}stop(){this.intervalId!==null&&(clearInterval(this.intervalId),this.intervalId=null,t.info("\r")),this.message=""}};function h(i){i.stop(),e.stderr.isTTY&&t.info("\x1B[2K")}function m(i,r){let[s]=r.inFlight;if(!s)return;let a=r.inFlight.size>1?` (+${r.inFlight.size-1} more)`:"";i.start(`[${r.position}/${r.total}] ${r.action} ${s}${a}`)}export{n as a,h as b,m as c};
@@ -0,0 +1,7 @@
1
+ import { createRequire as __createRequire } from 'node:module';
2
+ import { fileURLToPath as __fileURLToPath } from 'node:url';
3
+ import { dirname as __pathDirname } from 'node:path';
4
+ const require = __createRequire(import.meta.url);
5
+ var __filename = __fileURLToPath(import.meta.url);
6
+ var __dirname = __pathDirname(__filename);
7
+ import{a,b}from"./QAC4XUNG.js";import"./MGBZEDQJ.js";import"./ZOVYQ36P.js";import"./NEWT5A6S.js";import"./RFWIIJFG.js";export{a as bundleTelemetry,b as handleBundle};
@@ -0,0 +1,7 @@
1
+ import { createRequire as __createRequire } from 'node:module';
2
+ import { fileURLToPath as __fileURLToPath } from 'node:url';
3
+ import { dirname as __pathDirname } from 'node:path';
4
+ const require = __createRequire(import.meta.url);
5
+ var __filename = __fileURLToPath(import.meta.url);
6
+ var __dirname = __pathDirname(__filename);
7
+ var l={},c=new Set(["typescript","zod","tanstack-query","tanstack-query-vue","tanstack-query-svelte","tanstack-query-solid","swr","transformers","mock","cli","python","go","php"]),s=/import\s*(?:type\s*)?\{([^}]*)\}\s*from\s*['"]@redocly\/client-generator(?:\/generate)?['"]/g;function _(e,t){let o=new Set(t),r=new Set;for(let i of e.matchAll(s))for(let a of i[1].split(",")){let n=a.trim().replace(/^type\s+/,"").split(/\s+as\s+/)[0].trim();o.has(n)&&r.add(n)}return[...r]}var g=/^\/\/ Ejected from @redocly\/client-generator@([\w.-]+) — the built-in "([a-z-]+)" generator\./;function u(e){let t=e.match(g);if(!(!t||!c.has(t[2])))return{name:t[2],version:t[1]}}function p(e){return e.includes("Invalid pagination configuration")?"pagination":e.includes("Could not load generator")?"generator-load":/^Generator "[^"]+" failed:/.test(e)?"generator-run":e.includes("Unknown generator")||e.includes("does not support")?"not-supported":"other"}var d={};export{l as a,c as b,_ as c,u as d,p as e,d as f};
@@ -10,4 +10,4 @@ import{a as bt,c as Nt}from"./RFWIIJFG.js";var Xt=Nt((Xe,Wt)=>{var Re=Object.pro
10
10
  `);let t=new tt("!xml"),e=t,i="";this.matcher.reset(),this.entityDecoder.reset(),this.entityExpansionCount=0,this.currentExpandedLength=0;let n=this.options,o=new Z(n.processEntities),u=r.length;for(let s=0;s<u;s++)if(r[s]==="<"){let d=r.charCodeAt(s+1);if(d===47){let p=xt(r,">",s,"Closing Tag is not closed."),g=r.substring(s+2,p).trim();if(n.removeNSPrefix){let M=g.indexOf(":");M!==-1&&(g=g.substr(M+1))}g=Pt(n.transformTagName,g,"",n).tagName,e&&(i=this.saveTextToParentTag(i,e,this.readonlyMatcher));let O=this.matcher.getCurrentTag();if(g&&n.unpairedTagsSet.has(g))throw new Error(`Unpaired tag can not be used as closing tag: </${g}>`);O&&n.unpairedTagsSet.has(O)&&(this.matcher.pop(),this.tagsNodeStack.pop()),this.matcher.pop(),this.isCurrentNodeStopNode=!1,e=this.tagsNodeStack.pop(),i="",s=p}else if(d===63){let p=_t(r,s,!1,"?>");if(!p)throw new Error("Pi Tag is not closed.");i=this.saveTextToParentTag(i,e,this.readonlyMatcher);let g=this.buildAttributesMap(p.tagExp,this.matcher,p.tagName,!0);if(g){let O=g[this.options.attributeNamePrefix+"version"];this.entityDecoder.setXmlVersion(Number(O)||1)}if(!(n.ignoreDeclaration&&p.tagName==="?xml"||n.ignorePiTags)){let O=new tt(p.tagName);O.add(n.textNodeName,""),p.tagName!==p.tagExp&&p.attrExpPresent&&n.ignoreAttributes!==!0&&(O[":@"]=g),this.addChild(e,O,this.readonlyMatcher,s)}s=p.closeIndex+1}else if(d===33&&r.charCodeAt(s+2)===45&&r.charCodeAt(s+3)===45){let p=xt(r,"-->",s+4,"Comment is not closed.");if(n.commentPropName){let g=r.substring(s+4,p-2);i=this.saveTextToParentTag(i,e,this.readonlyMatcher),e.add(n.commentPropName,[{[n.textNodeName]:g}])}s=p}else if(d===33&&r.charCodeAt(s+2)===68){let p=o.readDocType(r,s);this.entityDecoder.addInputEntities(p.entities),s=p.i}else if(d===33&&r.charCodeAt(s+2)===91){let p=xt(r,"]]>",s,"CDATA is not closed.")-2,g=r.substring(s+9,p);i=this.saveTextToParentTag(i,e,this.readonlyMatcher);let O=this.parseTextData(g,e.tagname,this.readonlyMatcher,!0,!1,!0,!0);O==null&&(O=""),n.cdataPropName?e.add(n.cdataPropName,[{[n.textNodeName]:g}]):e.add(n.textNodeName,O),s=p+2}else{let p=_t(r,s,n.removeNSPrefix);if(!p){let at=r.substring(Math.max(0,s-50),Math.min(u,s+50));throw new Error(`readTagExp returned undefined at position ${s}. Context: "${at}"`)}let g=p.tagName,O=p.rawTagName,M=p.tagExp,L=p.attrExpPresent,k=p.closeIndex;if({tagName:g,tagExp:M}=Pt(n.transformTagName,g,M,n),n.strictReservedNames&&(g===n.commentPropName||g===n.cdataPropName||g===n.textNodeName||g===n.attributesGroupName))throw new Error(`Invalid tag name: ${g}`);e&&i&&e.tagname!=="!xml"&&(i=this.saveTextToParentTag(i,e,this.readonlyMatcher,!1));let V=e;V&&n.unpairedTagsSet.has(V.tagname)&&(e=this.tagsNodeStack.pop(),this.matcher.pop());let rt=!1;M.length>0&&M.lastIndexOf("/")===M.length-1&&(rt=!0,g[g.length-1]==="/"?(g=g.substr(0,g.length-1),M=g):M=M.substr(0,M.length-1),L=g!==M);let ot,st=null,dt={};ot=le(O),g!==t.tagname&&this.matcher.push(g,{},ot),g!==M&&L&&(st=this.buildAttributesMap(M,this.matcher,g),st&&(dt=ae(st,n))),g!==t.tagname&&(this.isCurrentNodeStopNode=this.isItStopNode());let ct=s;if(this.isCurrentNodeStopNode){let at="";if(rt)s=p.closeIndex;else if(n.unpairedTagsSet.has(g))s=p.closeIndex;else{let jt=this.readStopNodeData(r,O,k+1);if(!jt)throw new Error(`Unexpected end of ${O}`);s=jt.i,at=jt.tagContent}let Ct=new tt(g);st&&(Ct[":@"]=st),Ct.add(n.textNodeName,at),this.matcher.pop(),this.isCurrentNodeStopNode=!1,this.addChild(e,Ct,this.readonlyMatcher,ct)}else{if(rt){({tagName:g,tagExp:M}=Pt(n.transformTagName,g,M,n));let at=new tt(g);st&&(at[":@"]=st),this.addChild(e,at,this.readonlyMatcher,ct),this.matcher.pop(),this.isCurrentNodeStopNode=!1}else{if(n.unpairedTagsSet.has(g)){let at=new tt(g);st&&(at[":@"]=st),this.addChild(e,at,this.readonlyMatcher,ct),this.matcher.pop(),this.isCurrentNodeStopNode=!1,s=p.closeIndex;continue}{let at=new tt(g);if(this.tagsNodeStack.length>n.maxNestedTags)throw new Error("Maximum nested tags exceeded");this.tagsNodeStack.push(e),st&&(at[":@"]=st),this.addChild(e,at,this.readonlyMatcher,ct),e=at}}i="",s=k}}}else i+=r[s];return t.child};function me(r,t,e,i){this.options.captureMetaData||(i=void 0);let n=this.options.jPath?e.toString():e,o=this.options.updateTag(t.tagname,n,t[":@"]);o===!1||(typeof o=="string"&&(t.tagname=o),r.addChild(t,i))}function ge(r,t,e){let i=this.options.processEntities;if(!i||!i.enabled)return r;if(i.allowedTags){let n=this.options.jPath?e.toString():e;if(!(Array.isArray(i.allowedTags)?i.allowedTags.includes(t):i.allowedTags(t,n)))return r}if(i.tagFilter){let n=this.options.jPath?e.toString():e;if(!i.tagFilter(t,n))return r}return this.entityDecoder.decode(r)}function ye(r,t,e,i){return r&&(i===void 0&&(i=t.child.length===0),(r=this.parseTextData(r,t.tagname,e,!1,!!t[":@"]&&Object.keys(t[":@"]).length!==0,i))!==void 0&&r!==""&&t.add(this.options.textNodeName,r),r=""),r}function be(){return this.stopNodeExpressionsSet.size!==0&&this.matcher.matchesAny(this.stopNodeExpressionsSet)}function xt(r,t,e,i){let n=r.indexOf(t,e);if(n===-1)throw new Error(i);return n+t.length-1}function ve(r,t,e,i){let n=r.indexOf(t,e);if(n===-1)throw new Error(i);return n}function _t(r,t,e,i=">"){let n=(function(O,M,L=">"){let k=0,V=[],rt=O.length,ot=L.charCodeAt(0),st=L.length>1?L.charCodeAt(1):-1;for(let dt=M;dt<rt;dt++){let ct=O.charCodeAt(dt);if(k)ct===k&&(k=0);else if(ct===34||ct===39)k=ct;else if(ct===ot){if(st===-1)return{data:String.fromCharCode(...V),index:dt};if(O.charCodeAt(dt+1)===st)return{data:String.fromCharCode(...V),index:dt}}else if(ct===9){V.push(32);continue}V.push(ct)}})(r,t+1,i);if(!n)return;let o=n.data,u=n.index,s=o.search(/\s/),d=o,p=!0;s!==-1&&(d=o.substring(0,s),o=o.substring(s+1).trimStart());let g=d;if(e){let O=d.indexOf(":");O!==-1&&(d=d.substr(O+1),p=d!==n.data.substr(O+1))}return{tagName:d,tagExp:o,closeIndex:u,attrExpPresent:p,rawTagName:g}}function xe(r,t,e){let i=e,n=1,o=r.length;for(;e<o;e++)if(r[e]==="<"){let u=r.charCodeAt(e+1);if(u===47){let s=ve(r,">",e,`${t} is not closed`);if(r.substring(e+2,s).trim()===t&&(n--,n===0))return{tagContent:r.substring(i,e),i:s};e=s}else if(u===63)e=xt(r,"?>",e+1,"StopNode is not closed.");else if(u===33&&r.charCodeAt(e+2)===45&&r.charCodeAt(e+3)===45)e=xt(r,"-->",e+3,"StopNode is not closed.");else if(u===33&&r.charCodeAt(e+2)===91)e=xt(r,"]]>",e,"StopNode is not closed.")-2;else{let s=_t(r,e,">");s&&((s&&s.tagName)===t&&s.tagExp[s.tagExp.length-1]!=="/"&&n++,e=s.closeIndex)}}}function Rt(r,t,e){if(t&&typeof r=="string"){let i=r.trim();return i==="true"||i!=="false"&&(function(n,o={}){if(o=Object.assign({},Ht,o),!n||typeof n!="string")return n;let u=n.trim();if(u.length===0||o.skipLike!==void 0&&o.skipLike.test(u))return n;if(u==="0")return 0;if(o.hex&&gt.test(u))return(function(d){if(parseInt)return parseInt(d,16);if(Number.parseInt)return Number.parseInt(d,16);if(window&&window.parseInt)return window.parseInt(d,16);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")})(u);if(isFinite(u)){if(u.includes("e")||u.includes("E"))return(function(d,p,g){if(!g.eNotation)return d;let O=p.match(Qt);if(O){let M=O[1]||"",L=O[3].indexOf("e")===-1?"E":"e",k=O[2],V=M?d[k.length+1]===L:d[k.length]===L;return k.length>1&&V?d:(k.length!==1||!O[3].startsWith(`.${L}`)&&O[3][0]!==L)&&k.length>0?g.leadingZeros&&!V?(p=(O[1]||"")+O[3],Number(p)):d:Number(p)}return d})(n,u,o);{let d=ht.exec(u);if(d){let p=d[1]||"",g=d[2],O=((s=d[3])&&s.indexOf(".")!==-1&&((s=s.replace(/0+$/,""))==="."?s="0":s[0]==="."?s="0"+s:s[s.length-1]==="."&&(s=s.substring(0,s.length-1))),s),M=p?n[g.length+1]===".":n[g.length]===".";if(!o.leadingZeros&&(g.length>1||g.length===1&&!M))return n;{let L=Number(u),k=String(L);if(L===0)return L;if(k.search(/[eE]/)!==-1)return o.eNotation?L:n;if(u.indexOf(".")!==-1)return k==="0"||k===O||k===`${p}${O}`?L:n;let V=g?O:u;return g?V===k||p+V===k?L:n:V===k||V===p+k?L:n}}return n}}var s;return(function(d,p,g){let O=p===1/0;switch(g.infinity.toLowerCase()){case"null":return null;case"infinity":return p;case"string":return O?"Infinity":"-Infinity";default:return d}})(n,Number(u),o)})(r,e)}return r!==void 0?r:""}function Pt(r,t,e,i){if(r){let n=r(t);e===t&&(e=n),t=n}return{tagName:t=kt(t,i),tagExp:e}}function kt(r,t){if($.includes(r))throw new Error(`[SECURITY] Invalid name: "${r}" is a reserved JavaScript keyword that could cause prototype pollution`);return j.includes(r)?t.onDangerousProperty(r):r}let At=tt.getMetaDataSymbol();function Ne(r,t){if(!r||typeof r!="object")return{};if(!t)return r;let e={};for(let i in r)i.startsWith(t)?e[i.substring(t.length)]=r[i]:e[i]=r[i];return e}function we(r,t,e,i){return Vt(r,t,e,i)}function Vt(r,t,e,i){let n,o={};for(let u=0;u<r.length;u++){let s=r[u],d=Oe(s);if(d!==void 0&&d!==t.textNodeName){let p=Ne(s[":@"]||{},t.attributeNamePrefix);e.push(d,p)}if(d===t.textNodeName)n===void 0?n=s[d]:n+=""+s[d];else{if(d===void 0)continue;if(s[d]){let p=Vt(s[d],t,e,i),g=Se(p,t);if(s[":@"]?Ee(p,s[":@"],i,t):Object.keys(p).length!==1||p[t.textNodeName]===void 0||t.alwaysCreateTextNode?Object.keys(p).length===0&&(t.alwaysCreateTextNode?p[t.textNodeName]="":p=""):p=p[t.textNodeName],s[At]!==void 0&&typeof p=="object"&&p!==null&&(p[At]=s[At]),o[d]!==void 0&&Object.prototype.hasOwnProperty.call(o,d))Array.isArray(o[d])||(o[d]=[o[d]]),o[d].push(p);else{let O=t.jPath?i.toString():i;t.isArray(d,O,g)?o[d]=[p]:o[d]=p}d!==void 0&&d!==t.textNodeName&&e.pop()}}}return typeof n=="string"?n.length>0&&(o[t.textNodeName]=n):n!==void 0&&(o[t.textNodeName]=n),o}function Oe(r){let t=Object.keys(r);for(let e=0;e<t.length;e++){let i=t[e];if(i!==":@")return i}}function Ee(r,t,e,i){if(t){let n=Object.keys(t),o=n.length;for(let u=0;u<o;u++){let s=n[u],d=s.startsWith(i.attributeNamePrefix)?s.substring(i.attributeNamePrefix.length):s,p=i.jPath?e.toString()+"."+d:e;i.isArray(s,p,!0,!0)?r[s]=[t[s]]:r[s]=t[s]}}}function Se(r,t){let{textNodeName:e}=t,i=Object.keys(r).length;return i===0||!(i!==1||!r[e]&&typeof r[e]!="boolean"&&r[e]!==0)}class _e{constructor(t){this.externalEntities={},this.options=G(t)}parse(t,e){if(typeof t!="string"&&t.toString)t=t.toString();else if(typeof t!="string")throw new Error("XML data is accepted in String or Bytes[] form.");if(e){e===!0&&(e={});let o=c(t,e);if(o!==!0)throw Error(`${o.err.msg}:${o.err.line}:${o.err.col}`)}let i=new ue(this.options);i.entityDecoder.setExternalEntities(this.externalEntities);let n=i.parseXml(t);return this.options.preserveOrder||n===void 0?n:we(n,this.options,i.matcher,i.readonlyMatcher)}addEntity(t,e){if(e.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(t.indexOf("&")!==-1||t.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '&#xD;'");if(e==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[t]=e}static getMetaDataSymbol(){return tt.getMetaDataSymbol()}}function Pe(r,t){let e="";t.format&&t.indentBy.length>0&&(e=`
11
11
  `);let i=[];if(t.stopNodes&&Array.isArray(t.stopNodes))for(let n=0;n<t.stopNodes.length;n++){let o=t.stopNodes[n];typeof o=="string"?i.push(new vt(o)):o instanceof vt&&i.push(o)}return Ft(r,t,e,new Ot,i)}function Ft(r,t,e,i,n){let o="",u=!1;if(t.maxNestedTags&&i.getDepth()>t.maxNestedTags)throw new Error("Maximum nested tags exceeded");if(!Array.isArray(r)){if(r!=null){let s=r.toString();return s=Tt(s,t),s}return""}for(let s=0;s<r.length;s++){let d=r[s],p=Gt(d);if(p===void 0)continue;let g=Ae(d[":@"],t);i.push(p,g);let O=Ce(i,n);if(p===t.textNodeName){let V=d[p];O||(V=t.tagValueProcessor(p,V),V=Tt(V,t)),u&&(o+=e),o+=V,u=!1,i.pop();continue}if(p===t.cdataPropName){u&&(o+=e);let V=d[p][0][t.textNodeName];o+=`<![CDATA[${String(V).replace(/\]\]>/g,"]]]]><![CDATA[>")}]]>`,u=!1,i.pop();continue}if(p===t.commentPropName){let V=d[p][0][t.textNodeName];o+=e+`<!--${String(V).replace(/--/g,"- -").replace(/-$/,"- ")}-->`,u=!0,i.pop();continue}if(p[0]==="?"){let V=Bt(d[":@"],t,O),rt=p==="?xml"?"":e,ot=d[p][0][t.textNodeName];ot=ot.length!==0?" "+ot:"",o+=rt+`<${p}${ot}${V}?>`,u=!0,i.pop();continue}let M=e;M!==""&&(M+=t.indentBy);let L=e+`<${p}${Bt(d[":@"],t,O)}`,k;k=O?Ut(d[p],t):Ft(d[p],t,M,i,n),t.unpairedTags.indexOf(p)!==-1?t.suppressUnpairedNode?o+=L+">":o+=L+"/>":k&&k.length!==0||!t.suppressEmptyNode?k&&k.endsWith(">")?o+=L+`>${k}${e}</${p}>`:(o+=L+">",k&&e!==""&&(k.includes("/>")||k.includes("</"))?o+=e+t.indentBy+k+e:o+=k,o+=`</${p}>`):o+=L+"/>",u=!0,i.pop()}return o}function Ae(r,t){if(!r||t.ignoreAttributes)return null;let e={},i=!1;for(let n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n.startsWith(t.attributeNamePrefix)?n.substr(t.attributeNamePrefix.length):n]=r[n],i=!0);return i?e:null}function Ut(r,t){if(!Array.isArray(r))return r!=null?r.toString():"";let e="";for(let i=0;i<r.length;i++){let n=r[i],o=Gt(n);if(o===t.textNodeName)e+=n[o];else if(o===t.cdataPropName)e+=n[o][0][t.textNodeName];else if(o===t.commentPropName)e+=n[o][0][t.textNodeName];else{if(o&&o[0]==="?")continue;if(o){let u=Te(n[":@"],t),s=Ut(n[o],t);s&&s.length!==0?e+=`<${o}${u}>${s}</${o}>`:e+=`<${o}${u}/>`}}}return e}function Te(r,t){let e="";if(r&&!t.ignoreAttributes)for(let i in r){if(!Object.prototype.hasOwnProperty.call(r,i))continue;let n=r[i];n===!0&&t.suppressBooleanAttributes?e+=` ${i.substr(t.attributeNamePrefix.length)}`:e+=` ${i.substr(t.attributeNamePrefix.length)}="${n}"`}return e}function Gt(r){let t=Object.keys(r);for(let e=0;e<t.length;e++){let i=t[e];if(Object.prototype.hasOwnProperty.call(r,i)&&i!==":@")return i}}function Bt(r,t,e){let i="";if(r&&!t.ignoreAttributes)for(let n in r){if(!Object.prototype.hasOwnProperty.call(r,n))continue;let o;e?o=r[n]:(o=t.attributeValueProcessor(n,r[n]),o=Tt(o,t)),o===!0&&t.suppressBooleanAttributes?i+=` ${n.substr(t.attributeNamePrefix.length)}`:i+=` ${n.substr(t.attributeNamePrefix.length)}="${o}"`}return i}function Ce(r,t){if(!t||t.length===0)return!1;for(let e=0;e<t.length;e++)if(r.matches(t[e]))return!0;return!1}function Tt(r,t){if(r&&r.length>0&&t.processEntities)for(let e=0;e<t.entities.length;e++){let i=t.entities[e];r=r.replace(i.regex,i.val)}return r}let je={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(r,t){return t},attributeValueProcessor:function(r,t){return t},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&amp;"},{regex:new RegExp(">","g"),val:"&gt;"},{regex:new RegExp("<","g"),val:"&lt;"},{regex:new RegExp("'","g"),val:"&apos;"},{regex:new RegExp('"',"g"),val:"&quot;"}],processEntities:!0,stopNodes:[],oneListGroup:!1,maxNestedTags:100,jPath:!0};function pt(r){if(this.options=Object.assign({},je,r),this.options.stopNodes&&Array.isArray(this.options.stopNodes)&&(this.options.stopNodes=this.options.stopNodes.map(e=>typeof e=="string"&&e.startsWith("*.")?".."+e.substring(2):e)),this.stopNodeExpressions=[],this.options.stopNodes&&Array.isArray(this.options.stopNodes))for(let e=0;e<this.options.stopNodes.length;e++){let i=this.options.stopNodes[e];typeof i=="string"?this.stopNodeExpressions.push(new vt(i)):i instanceof vt&&this.stopNodeExpressions.push(i)}var t;this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=typeof(t=this.options.ignoreAttributes)=="function"?t:Array.isArray(t)?e=>{for(let i of t)if(typeof i=="string"&&e===i||i instanceof RegExp&&i.test(e))return!0}:()=>!1,this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=De),this.processTextOrObjNode=Me,this.options.format?(this.indentate=Ie,this.tagEndChar=`>
12
12
  `,this.newLine=`
13
- `):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function Me(r,t,e,i){let n=this.extractAttributes(r);if(i.push(t,n),this.checkStopNode(i)){let u=this.buildRawContent(r),s=this.buildAttributesForStopNode(r);return i.pop(),this.buildObjectNode(u,t,s,e)}let o=this.j2x(r,e+1,i);return i.pop(),r[this.options.textNodeName]!==void 0&&Object.keys(r).length===1?this.buildTextValNode(r[this.options.textNodeName],t,o.attrStr,e,i):this.buildObjectNode(o.val,t,o.attrStr,e)}function Ie(r){return this.options.indentBy.repeat(r)}function De(r){return!(!r.startsWith(this.options.attributeNamePrefix)||r===this.options.textNodeName)&&r.substr(this.attrPrefixLen)}pt.prototype.build=function(r){if(this.options.preserveOrder)return Pe(r,this.options);{Array.isArray(r)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(r={[this.options.arrayNodeName]:r});let t=new Ot;return this.j2x(r,0,t).val}},pt.prototype.j2x=function(r,t,e){let i="",n="";if(this.options.maxNestedTags&&e.getDepth()>=this.options.maxNestedTags)throw new Error("Maximum nested tags exceeded");let o=this.options.jPath?e.toString():e,u=this.checkStopNode(e);for(let s in r)if(Object.prototype.hasOwnProperty.call(r,s))if(r[s]===void 0)this.isAttribute(s)&&(n+="");else if(r[s]===null)this.isAttribute(s)||s===this.options.cdataPropName?n+="":s[0]==="?"?n+=this.indentate(t)+"<"+s+"?"+this.tagEndChar:n+=this.indentate(t)+"<"+s+"/"+this.tagEndChar;else if(r[s]instanceof Date)n+=this.buildTextValNode(r[s],s,"",t,e);else if(typeof r[s]!="object"){let d=this.isAttribute(s);if(d&&!this.ignoreAttributesFn(d,o))i+=this.buildAttrPairStr(d,""+r[s],u);else if(!d)if(s===this.options.textNodeName){let p=this.options.tagValueProcessor(s,""+r[s]);n+=this.replaceEntitiesValue(p)}else{e.push(s);let p=this.checkStopNode(e);if(e.pop(),p){let g=""+r[s];n+=g===""?this.indentate(t)+"<"+s+this.closeTag(s)+this.tagEndChar:this.indentate(t)+"<"+s+">"+g+"</"+s+this.tagEndChar}else n+=this.buildTextValNode(r[s],s,"",t,e)}}else if(Array.isArray(r[s])){let d=r[s].length,p="",g="";for(let O=0;O<d;O++){let M=r[s][O];if(M!==void 0)if(M===null)s[0]==="?"?n+=this.indentate(t)+"<"+s+"?"+this.tagEndChar:n+=this.indentate(t)+"<"+s+"/"+this.tagEndChar;else if(typeof M=="object")if(this.options.oneListGroup){e.push(s);let L=this.j2x(M,t+1,e);e.pop(),p+=L.val,this.options.attributesGroupName&&M.hasOwnProperty(this.options.attributesGroupName)&&(g+=L.attrStr)}else p+=this.processTextOrObjNode(M,s,t,e);else if(this.options.oneListGroup){let L=this.options.tagValueProcessor(s,M);L=this.replaceEntitiesValue(L),p+=L}else{e.push(s);let L=this.checkStopNode(e);if(e.pop(),L){let k=""+M;p+=k===""?this.indentate(t)+"<"+s+this.closeTag(s)+this.tagEndChar:this.indentate(t)+"<"+s+">"+k+"</"+s+this.tagEndChar}else p+=this.buildTextValNode(M,s,"",t,e)}}this.options.oneListGroup&&(p=this.buildObjectNode(p,s,g,t)),n+=p}else if(this.options.attributesGroupName&&s===this.options.attributesGroupName){let d=Object.keys(r[s]),p=d.length;for(let g=0;g<p;g++)i+=this.buildAttrPairStr(d[g],""+r[s][d[g]],u)}else n+=this.processTextOrObjNode(r[s],s,t,e);return{attrStr:i,val:n}},pt.prototype.buildAttrPairStr=function(r,t,e){return e||(t=this.options.attributeValueProcessor(r,""+t),t=this.replaceEntitiesValue(t)),this.options.suppressBooleanAttributes&&t==="true"?" "+r:" "+r+'="'+t+'"'},pt.prototype.extractAttributes=function(r){if(!r||typeof r!="object")return null;let t={},e=!1;if(this.options.attributesGroupName&&r[this.options.attributesGroupName]){let i=r[this.options.attributesGroupName];for(let n in i)Object.prototype.hasOwnProperty.call(i,n)&&(t[n.startsWith(this.options.attributeNamePrefix)?n.substring(this.options.attributeNamePrefix.length):n]=i[n],e=!0)}else for(let i in r){if(!Object.prototype.hasOwnProperty.call(r,i))continue;let n=this.isAttribute(i);n&&(t[n]=r[i],e=!0)}return e?t:null},pt.prototype.buildRawContent=function(r){if(typeof r=="string")return r;if(typeof r!="object"||r===null)return String(r);if(r[this.options.textNodeName]!==void 0)return r[this.options.textNodeName];let t="";for(let e in r){if(!Object.prototype.hasOwnProperty.call(r,e)||this.isAttribute(e)||this.options.attributesGroupName&&e===this.options.attributesGroupName)continue;let i=r[e];if(e===this.options.textNodeName)t+=i;else if(Array.isArray(i)){for(let n of i)if(typeof n=="string"||typeof n=="number")t+=`<${e}>${n}</${e}>`;else if(typeof n=="object"&&n!==null){let o=this.buildRawContent(n),u=this.buildAttributesForStopNode(n);t+=o===""?`<${e}${u}/>`:`<${e}${u}>${o}</${e}>`}}else if(typeof i=="object"&&i!==null){let n=this.buildRawContent(i),o=this.buildAttributesForStopNode(i);t+=n===""?`<${e}${o}/>`:`<${e}${o}>${n}</${e}>`}else t+=`<${e}>${i}</${e}>`}return t},pt.prototype.buildAttributesForStopNode=function(r){if(!r||typeof r!="object")return"";let t="";if(this.options.attributesGroupName&&r[this.options.attributesGroupName]){let e=r[this.options.attributesGroupName];for(let i in e){if(!Object.prototype.hasOwnProperty.call(e,i))continue;let n=i.startsWith(this.options.attributeNamePrefix)?i.substring(this.options.attributeNamePrefix.length):i,o=e[i];o===!0&&this.options.suppressBooleanAttributes?t+=" "+n:t+=" "+n+'="'+o+'"'}}else for(let e in r){if(!Object.prototype.hasOwnProperty.call(r,e))continue;let i=this.isAttribute(e);if(i){let n=r[e];n===!0&&this.options.suppressBooleanAttributes?t+=" "+i:t+=" "+i+'="'+n+'"'}}return t},pt.prototype.buildObjectNode=function(r,t,e,i){if(r==="")return t[0]==="?"?this.indentate(i)+"<"+t+e+"?"+this.tagEndChar:this.indentate(i)+"<"+t+e+this.closeTag(t)+this.tagEndChar;{let n="</"+t+this.tagEndChar,o="";return t[0]==="?"&&(o="?",n=""),!e&&e!==""||r.indexOf("<")!==-1?this.options.commentPropName!==!1&&t===this.options.commentPropName&&o.length===0?this.indentate(i)+`<!--${r}-->`+this.newLine:this.indentate(i)+"<"+t+e+o+this.tagEndChar+r+this.indentate(i)+n:this.indentate(i)+"<"+t+e+o+">"+r+n}},pt.prototype.closeTag=function(r){let t="";return this.options.unpairedTags.indexOf(r)!==-1?this.options.suppressUnpairedNode||(t="/"):t=this.options.suppressEmptyNode?"/":`></${r}`,t},pt.prototype.checkStopNode=function(r){if(!this.stopNodeExpressions||this.stopNodeExpressions.length===0)return!1;for(let t=0;t<this.stopNodeExpressions.length;t++)if(r.matches(this.stopNodeExpressions[t]))return!0;return!1},pt.prototype.buildTextValNode=function(r,t,e,i,n){if(this.options.cdataPropName!==!1&&t===this.options.cdataPropName){let o=String(r).replace(/\]\]>/g,"]]]]><![CDATA[>");return this.indentate(i)+`<![CDATA[${o}]]>`+this.newLine}if(this.options.commentPropName!==!1&&t===this.options.commentPropName){let o=String(r).replace(/--/g,"- -").replace(/-$/,"- ");return this.indentate(i)+`<!--${o}-->`+this.newLine}if(t[0]==="?")return this.indentate(i)+"<"+t+e+"?"+this.tagEndChar;{let o=this.options.tagValueProcessor(t,r);return o=this.replaceEntitiesValue(o),o===""?this.indentate(i)+"<"+t+e+this.closeTag(t)+this.tagEndChar:this.indentate(i)+"<"+t+e+">"+o+"</"+t+this.tagEndChar}},pt.prototype.replaceEntitiesValue=function(r){if(r&&r.length>0&&this.options.processEntities)for(let t=0;t<this.options.entities.length;t++){let e=this.options.entities[t];r=r.replace(e.regex,e.val)}return r};let $e=pt,Le={validate:c};R.exports=h})()},{}],2:[function(_,R,w){var I=Object.prototype.hasOwnProperty,h=Object.prototype.toString;R.exports=function(y,N,D){if(h.call(N)!=="[object Function]")throw new TypeError("iterator must be a function");var j=y.length;if(j===+j)for(var $=0;$<j;$++)N.call(D,y[$],$,y);else for(var l in y)I.call(y,l)&&N.call(D,y[l],l,y)}},{}],3:[function(_,R,w){"use strict";var I=_("foreach");R.exports=h;function h(A,y,N){if(arguments.length===3)return h.set(A,y,N);if(arguments.length===2)return h.get(A,y);var D=h.bind(h,A);for(var j in h)h.hasOwnProperty(j)&&(D[j]=h[j].bind(D,A));return D}h.get=function(y,N){for(var D=Array.isArray(N)?N:h.parse(N),j=0;j<D.length;++j){var $=D[j];if(!(typeof y=="object"&&$ in y))throw new Error("Invalid reference token: "+$);y=y[$]}return y},h.set=function(y,N,D){var j=Array.isArray(N)?N:h.parse(N),$=j[0];if(j.length===0)throw Error("Can not set the root object");for(var l=0;l<j.length-1;++l){var c=j[l];typeof c!="string"&&typeof c!="number"&&(c=String(c)),!(c==="__proto__"||c==="constructor"||c==="prototype")&&(c==="-"&&Array.isArray(y)&&(c=y.length),$=j[l+1],c in y||($.match(/^(\d+|-)$/)?y[c]=[]:y[c]={}),y=y[c])}return $==="-"&&Array.isArray(y)&&($=y.length),y[$]=D,this},h.remove=function(A,y){var N=Array.isArray(y)?y:h.parse(y),D=N[N.length-1];if(D===void 0)throw new Error('Invalid JSON pointer for remove: "'+y+'"');var j=h.get(A,N.slice(0,-1));if(Array.isArray(j)){var $=+D;if(D===""&&isNaN($))throw new Error('Invalid array index: "'+D+'"');Array.prototype.splice.call(j,$,1)}else delete j[D]},h.dict=function(y,N){var D={};return h.walk(y,function(j,$){D[$]=j},N),D},h.walk=function(y,N,D){var j=[];D=D||function($){var l=Object.prototype.toString.call($);return l==="[object Object]"||l==="[object Array]"},(function $(l){I(l,function(c,v){j.push(String(v)),D(c)?$(c):N(c,h.compile(j)),j.pop()})})(y)},h.has=function(y,N){try{h.get(y,N)}catch{return!1}return!0},h.escape=function(y){return y.toString().replace(/~/g,"~0").replace(/\//g,"~1")},h.unescape=function(y){return y.replace(/~1/g,"/").replace(/~0/g,"~")},h.parse=function(y){if(y==="")return[];if(y.charAt(0)!=="/")throw new Error("Invalid JSON pointer: "+y);return y.substring(1).split(/\//).map(h.unescape)},h.compile=function(y){return y.length===0?"":"/"+y.map(h.escape).join("/")}},{foreach:2}],4:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.allOfSample=$;var I=_("./traverse"),h=_("./utils");function A(l,c){var v=Object.keys(l);if(Object.getOwnPropertySymbols){var P=Object.getOwnPropertySymbols(l);c&&(P=P.filter(function(E){return Object.getOwnPropertyDescriptor(l,E).enumerable})),v.push.apply(v,P)}return v}function y(l){for(var c=1;c<arguments.length;c++){var v=arguments[c]!=null?arguments[c]:{};c%2?A(Object(v),!0).forEach(function(P){N(l,P,v[P])}):Object.getOwnPropertyDescriptors?Object.defineProperties(l,Object.getOwnPropertyDescriptors(v)):A(Object(v)).forEach(function(P){Object.defineProperty(l,P,Object.getOwnPropertyDescriptor(v,P))})}return l}function N(l,c,v){return(c=D(c))in l?Object.defineProperty(l,c,{value:v,enumerable:!0,configurable:!0,writable:!0}):l[c]=v,l}function D(l){var c=j(l,"string");return typeof c=="symbol"?c:c+""}function j(l,c){if(typeof l!="object"||!l)return l;var v=l[Symbol.toPrimitive];if(v!==void 0){var P=v.call(l,c||"default");if(typeof P!="object")return P;throw new TypeError("@@toPrimitive must return a primitive value.")}return(c==="string"?String:Number)(l)}function $(l,c,v,P,E){let F=(0,I.traverse)(l,v,P),q=[];for(let W of c){let{type:U,readOnly:K,writeOnly:f,value:m}=(0,I.traverse)(y({type:F.type},W),v,P,y(y({},E),{},{isAllOfChild:!0}));F.type&&U&&U!==F.type&&(console.warn("allOf: schemas with different types can't be merged"),F.type=U),F.type=F.type||U,F.readOnly=F.readOnly||K,F.writeOnly=F.writeOnly||f,m!=null&&q.push(m)}if(F.type==="object"){F.value=(0,h.mergeDeep)(F.value||{},...q.filter(W=>typeof W=="object"));for(let W in F.value)F.value[W]===h.SKIP_SYMBOL&&delete F.value[W];return F}else{F.type==="array"&&(v.quiet||console.warn('OpenAPI Sampler: found allOf with "array" type. Result may be incorrect'));let W=q[q.length-1];return F.value=W??F.value,F}}},{"./traverse":14,"./utils":15}],5:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.inferType=h;let I={multipleOf:"number",maximum:"number",exclusiveMaximum:"number",minimum:"number",exclusiveMinimum:"number",maxLength:"string",minLength:"string",pattern:"string",items:"array",maxItems:"array",minItems:"array",uniqueItems:"array",additionalItems:"array",maxProperties:"object",minProperties:"object",required:"object",additionalProperties:"object",properties:"object",patternProperties:"object",dependencies:"object"};function h(A){if(A.type!==void 0)return Array.isArray(A.type)?A.type.length===0?null:A.type[0]:A.type;let y=Object.keys(I);for(var N=0;N<y.length;N++){let D=y[N],j=I[D];if(A[D]!==void 0)return j}return null}},{}],6:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w._registerSampler=l,w._samplers=void 0,Object.defineProperty(w,"inferType",{enumerable:!0,get:function(){return y.inferType}}),w.sample=$;var I=_("./traverse"),h=_("./samplers/index"),A=_("fast-xml-parser"),y=_("./infer"),N=w._samplers={};let D={skipReadOnly:!1,maxSampleDepth:15};function j(c,v){if(!c)throw new Error("Unknown format output for building XML.");if(Array.isArray(c)||Object.keys(c).length>1){var P;c={[(v==null||(P=v.xml)===null||P===void 0?void 0:P.name)||"root"]:c}}return new A.XMLBuilder({ignoreAttributes:!1,format:!0,attributeNamePrefix:"$",textNodeName:"#text",cdataPropName:"#cdata"}).build(c)}function $(c,v,P){let E=Object.assign({},D,v);(0,I.clearCache)();let F=(0,I.traverse)(c,E,P).value;return E?.format==="xml"?j(F,c):F}function l(c,v){N[c]=v}l("array",h.sampleArray),l("boolean",h.sampleBoolean),l("integer",h.sampleNumber),l("number",h.sampleNumber),l("object",h.sampleObject),l("string",h.sampleString)},{"./infer":5,"./samplers/index":9,"./traverse":14,"fast-xml-parser":1}],7:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleArray=$;var I=_("../traverse"),h=_("../utils");function A(l,c){var v=Object.keys(l);if(Object.getOwnPropertySymbols){var P=Object.getOwnPropertySymbols(l);c&&(P=P.filter(function(E){return Object.getOwnPropertyDescriptor(l,E).enumerable})),v.push.apply(v,P)}return v}function y(l){for(var c=1;c<arguments.length;c++){var v=arguments[c]!=null?arguments[c]:{};c%2?A(Object(v),!0).forEach(function(P){N(l,P,v[P])}):Object.getOwnPropertyDescriptors?Object.defineProperties(l,Object.getOwnPropertyDescriptors(v)):A(Object(v)).forEach(function(P){Object.defineProperty(l,P,Object.getOwnPropertyDescriptor(v,P))})}return l}function N(l,c,v){return(c=D(c))in l?Object.defineProperty(l,c,{value:v,enumerable:!0,configurable:!0,writable:!0}):l[c]=v,l}function D(l){var c=j(l,"string");return typeof c=="symbol"?c:c+""}function j(l,c){if(typeof l!="object"||!l)return l;var v=l[Symbol.toPrimitive];if(v!==void 0){var P=v.call(l,c||"default");if(typeof P!="object")return P;throw new TypeError("@@toPrimitive must return a primitive value.")}return(c==="string"?String:Number)(l)}function $(l){let c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},v=arguments.length>2?arguments[2]:void 0,P=arguments.length>3?arguments[3]:void 0,E=P&&P.depth||1,F=Math.min(l.maxItems!=null?l.maxItems:1/0,l.minItems||1),q=l.prefixItems||l.items||l.contains;Array.isArray(q)&&(F=Math.max(F,q.length));let W=f=>Array.isArray(q)?q[f]||{}:q||{},U=[];if(!q)return U;for(let f=0;f<F;f++){let m=W(f),{value:a}=(0,I.traverse)(m,c,v,{depth:E+1});if(c?.format==="xml"){let{value:x,propertyName:b}=(0,h.applyXMLAttributes)({value:a},m,P);if(b){var K;(K=U)!==null&&K!==void 0&&K[b]||(U=y(y({},U),{},{[b]:[]})),U[b].push(x)}else U=y(y({},U),x)}else U.push(a)}if(c?.format==="xml"&&E===1){let{value:f,propertyName:m}=(0,h.applyXMLAttributes)({value:null},l,P);m&&(f?U=Array.isArray(U)?{[m]:y(y({},f),U.map(a=>({"#text":y({},a)})))}:{[m]:y(y({},U),f)}:U={[m]:U})}return U}},{"../traverse":14,"../utils":15}],8:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleBoolean=I;function I(h){return!0}},{}],9:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),Object.defineProperty(w,"sampleArray",{enumerable:!0,get:function(){return I.sampleArray}}),Object.defineProperty(w,"sampleBoolean",{enumerable:!0,get:function(){return h.sampleBoolean}}),Object.defineProperty(w,"sampleNumber",{enumerable:!0,get:function(){return A.sampleNumber}}),Object.defineProperty(w,"sampleObject",{enumerable:!0,get:function(){return y.sampleObject}}),Object.defineProperty(w,"sampleString",{enumerable:!0,get:function(){return N.sampleString}});var I=_("./array"),h=_("./boolean"),A=_("./number"),y=_("./object"),N=_("./string")},{"./array":7,"./boolean":8,"./number":10,"./object":11,"./string":13}],10:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleNumber=I;function I(h){let A=0;if(h.type==="number"&&(h.format==="float"||h.format==="double")&&(A=.1),typeof h.exclusiveMinimum=="boolean"||typeof h.exclusiveMaximum=="boolean"){if(Number.isFinite(h.maximum)&&Number.isFinite(h.minimum))return A=h.exclusiveMinimum?Math.floor(h.minimum)+1:h.minimum,(h.exclusiveMaximum&&A>=h.maximum||!h.exclusiveMaximum&&A>h.maximum)&&(A=(h.maximum+h.minimum)/2),A;if(Number.isFinite(h.minimum))return h.exclusiveMinimum?Math.floor(h.minimum)+1:h.minimum;if(Number.isFinite(h.maximum))return h.exclusiveMaximum?h.maximum>0?0:Math.floor(h.maximum)-1:h.maximum>0?0:h.maximum}else{if(Number.isFinite(h.minimum))return h.minimum;Number.isFinite(h.exclusiveMinimum)?(A=Math.floor(h.exclusiveMinimum)+1,A===h.exclusiveMaximum&&(A=(A+Math.floor(h.exclusiveMaximum)-1)/2)):Number.isFinite(h.exclusiveMaximum)?A=Math.floor(h.exclusiveMaximum)-1:Number.isFinite(h.maximum)&&(A=h.maximum)}return A}},{}],11:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleObject=$;var I=_("../traverse"),h=_("../utils");function A(l,c){var v=Object.keys(l);if(Object.getOwnPropertySymbols){var P=Object.getOwnPropertySymbols(l);c&&(P=P.filter(function(E){return Object.getOwnPropertyDescriptor(l,E).enumerable})),v.push.apply(v,P)}return v}function y(l){for(var c=1;c<arguments.length;c++){var v=arguments[c]!=null?arguments[c]:{};c%2?A(Object(v),!0).forEach(function(P){N(l,P,v[P])}):Object.getOwnPropertyDescriptors?Object.defineProperties(l,Object.getOwnPropertyDescriptors(v)):A(Object(v)).forEach(function(P){Object.defineProperty(l,P,Object.getOwnPropertyDescriptor(v,P))})}return l}function N(l,c,v){return(c=D(c))in l?Object.defineProperty(l,c,{value:v,enumerable:!0,configurable:!0,writable:!0}):l[c]=v,l}function D(l){var c=j(l,"string");return typeof c=="symbol"?c:c+""}function j(l,c){if(typeof l!="object"||!l)return l;var v=l[Symbol.toPrimitive];if(v!==void 0){var P=v.call(l,c||"default");if(typeof P!="object")return P;throw new TypeError("@@toPrimitive must return a primitive value.")}return(c==="string"?String:Number)(l)}function $(l){let c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},v=arguments.length>2?arguments[2]:void 0,P=arguments.length>3?arguments[3]:void 0,E={},F=P&&P.depth||1;if(l&&typeof l.properties=="object"){let q=Array.isArray(l.required)?l.required:[],W={};for(let U of q)W[U]=!0;Object.keys(l.properties).forEach(U=>{if(c.skipNonRequired&&!W.hasOwnProperty(U))return;let K=(0,I.traverse)(l.properties[U],c,v,{propertyName:U,depth:F+1});if(c.skipReadOnly&&K.readOnly){P!=null&&P.isAllOfChild&&(E[U]=h.SKIP_SYMBOL);return}if(c.skipWriteOnly&&K.writeOnly){P!=null&&P.isAllOfChild&&(E[U]=h.SKIP_SYMBOL);return}if(c?.format==="xml"){let{propertyName:f,value:m}=(0,h.applyXMLAttributes)(K,l.properties[U],{propertyName:U});f?E[f]=m:m!==null&&typeof m=="object"&&(E=y(y({},E),m))}else E[U]=K.value})}if(l&&typeof l.additionalProperties=="object"){let q=l.additionalProperties["x-additionalPropertiesName"]||"property";E["".concat(String(q),"1")]=(0,I.traverse)(l.additionalProperties,c,v,{depth:F+1}).value,E["".concat(String(q),"2")]=(0,I.traverse)(l.additionalProperties,c,v,{depth:F+1}).value}if(l&&typeof l.properties=="object"&&l.maxProperties!==void 0&&Object.keys(E).length>l.maxProperties){let q={},W=0;(Array.isArray(l.required)?l.required:[]).forEach(K=>{E[K]!==void 0&&(q[K]=E[K],W++)}),Object.keys(E).forEach(K=>{W<l.maxProperties&&!q.hasOwnProperty(K)&&(q[K]=E[K],W++)}),E=q}return E}},{"../traverse":14,"../utils":15}],12:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.regexSample=y;function I(){return!0}function h(N,D){return N}function A(N,D,j){let $=1;if(N)switch(N){case"?":{$=I()?0:1;break}case"*":{$=h(0,8);break}case"+":{$=h(1,8);break}default:throw new Error("Unknown quantifier symbol provided.")}else D!=null&&j!=null?$=h(parseInt(D),parseInt(j)):D!=null&&j==null&&($=parseInt(D));return $}function y(N){let D=!1;if(N instanceof RegExp){var j,$;D=N.flags.includes("i"),N=N.toString(),N=(j=($=N.match(/\/(.+?)\//))===null||$===void 0?void 0:$[1])!==null&&j!==void 0?j:""}N=N.replace(/^(\^)?(.*?)(\$)?$/,"$2");let l,c,v,P=/([.A-Za-z0-9])(?:\{(\d+)(?:\,(\d+)|)\}|(\?|\*|\+))(?![^[]*]|[^{]*})/,E=N.match(P);for(;E!=null;){let K=E[2],f=E[3],m=E[4];v=A(m,K,f),N=N.slice(0,E.index)+E[1].repeat(v)+N.slice(E.index+E[0].length),E=N.match(P)}let F=/(\d-\d|\w-\w|\d|\w|[-!@#$&()`.+,/"])/,q=/\[(\^|)(-|)(.+?)\](?:\{(\d+)(?:\,(\d+)|)\}|(\?|\*|\+)|)/;for(E=N.match(q);E!=null;){let K=E[1]==="^",f=E[2]==="-",m=E[4],a=E[5],x=E[6],b=[],T=E[3],B=T.match(F);for(f&&b.push(45);B!=null;){if(B[0].indexOf("-")===-1)D&&isNaN(Number(B[0]))?(b.push(B[0].toUpperCase().charCodeAt(0)),b.push(B[0].toLowerCase().charCodeAt(0))):b.push(B[0].charCodeAt(0));else{let H=B[0].split("-").map(S=>S.charCodeAt(0));if(l=H[0],c=H[1],l>c)throw new Error("Character range provided is out of order.");for(let S=l;S<=c;S++)if(D&&isNaN(Number(String.fromCharCode(S)))){let G=String.fromCharCode(S);b.push(G.toUpperCase().charCodeAt(0)),b.push(G.toLowerCase().charCodeAt(0))}else b.push(S)}T=T.substring(B[0].length),B=T.match(F)}if(v=A(x,m,a),K){let H=-1;for(let S=48;S<=57;S++){if(H=b.indexOf(S),H>-1){b.splice(H,1);continue}b.push(S)}for(let S=65;S<=90;S++){if(H=b.indexOf(S),H>-1){b.splice(H,1);continue}b.push(S)}for(let S=97;S<=122;S++){if(H=b.indexOf(S),H>-1){b.splice(H,1);continue}b.push(S)}}let Q=Array.from({length:v},()=>String.fromCharCode(b[h(0,b.length-1)])).join("");N=N.slice(0,E.index)+Q+N.slice(E.index+E[0].length),E=N.match(q)}let W=/(.)\{(\d+)\,(\d+)\}/;for(E=N.match(W);E!=null;){if(l=parseInt(E[2]),c=parseInt(E[3]),l>c)throw new Error("Numbers out of order in {} quantifier.");v=h(l,c),N=N.slice(0,E.index)+E[1].repeat(v)+N.slice(E.index+E[0].length),E=N.match(W)}let U=/(.)\{(\d+)\}/;for(E=N.match(U);E!=null;)v=parseInt(E[2]),N=N.slice(0,E.index)+E[1].repeat(v)+N.slice(E.index+E[0].length),E=N.match(U);return N}},{}],13:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleString=H;var I=_("../utils"),h=A(_("./string-regex"));function A(S,G){if(typeof WeakMap=="function")var X=new WeakMap,tt=new WeakMap;return(A=function(Z,z){if(!z&&Z&&Z.__esModule)return Z;var nt,ut,gt={__proto__:null,default:Z};if(Z===null||typeof Z!="object"&&typeof Z!="function")return gt;if(nt=z?tt:X){if(nt.has(Z))return nt.get(Z);nt.set(Z,gt)}for(let ht in Z)ht!=="default"&&{}.hasOwnProperty.call(Z,ht)&&((ut=(nt=Object.defineProperty)&&Object.getOwnPropertyDescriptor(Z,ht))&&(ut.get||ut.set)?nt(gt,ht,ut):gt[ht]=Z[ht]);return gt})(S,G)}let y="qwerty!@#$%^123456";function N(){return"user@example.com"}function D(){return"\u043F\u043E\u0448\u0442\u0430@\u0443\u043A\u0440.\u043D\u0435\u0442"}function j(S,G){let X="pa$$word";return S>X.length&&(X+="_",X+=(0,I.ensureMinLength)(y,S-X.length).substring(0,S-X.length)),X}function $(S){let{min:G,max:X,omitTime:tt,omitDate:Z}=S,z=(0,I.toRFCDateTime)(new Date("2019-08-24T14:15:22.123Z"),tt,Z,!1);return z.length<G&&console.warn("Using minLength = ".concat(G,' is incorrect with format "date-time"')),X&&z.length>X&&console.warn("Using maxLength = ".concat(X,' is incorrect with format "date-time"')),z}function l(S,G){return $({min:S,max:G,omitTime:!1,omitDate:!1})}function c(S,G){return $({min:S,max:G,omitTime:!0,omitDate:!1})}function v(S,G){return $({min:S,max:G,omitTime:!1,omitDate:!0}).slice(1)}function P(S,G,X,tt){let Z=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(tt&&Z)return h.regexSample(tt);let z=(0,I.ensureMinLength)("string",S);return G&&z.length>G&&(z=z.substring(0,G)),z}function E(){return"192.168.0.1"}function F(){return"2001:0db8:85a3:0000:0000:8a2e:0370:7334"}function q(){return"example.com"}function W(){return"\u043F\u0440\u0438\u043A\u043B\u0430\u0434.\u0443\u043A\u0440"}function U(){return"http://example.com"}function K(){return"../dictionary"}function f(){return"http://example.com/{endpoint}"}function m(){return"http://example.com/entity/1"}function a(){return"/entity/1"}function x(S,G,X){return(0,I.uuid)(X||"id")}function b(){return"/json/pointer"}function T(){return"1/relative/json/pointer"}function B(){return"/regex/"}let Q={email:N,"idn-email":D,password:j,"date-time":l,date:c,time:v,ipv4:E,ipv6:F,hostname:q,"idn-hostname":W,iri:m,"iri-reference":a,uri:U,"uri-reference":K,"uri-template":f,uuid:x,default:P,"json-pointer":b,"relative-json-pointer":T,regex:B};function H(S,G,X,tt){let Z=S.format||"default",z=Q[Z]||P,nt=tt&&tt.propertyName;return z(S.minLength||0,S.maxLength,nt,S.pattern,G?.enablePatterns)}},{"../utils":15,"./string-regex":12}],14:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.clearCache=U,w.traverse=m;var I=_("./openapi-sampler"),h=_("./allOf"),A=_("./infer"),y=_("./utils"),N=j(_("json-pointer"));let D=["if","then"];function j(a){return a&&a.__esModule?a:{default:a}}function $(a,x){if(a==null)return{};var b,T,B=l(a,x);if(Object.getOwnPropertySymbols){var Q=Object.getOwnPropertySymbols(a);for(T=0;T<Q.length;T++)b=Q[T],x.indexOf(b)===-1&&{}.propertyIsEnumerable.call(a,b)&&(B[b]=a[b])}return B}function l(a,x){if(a==null)return{};var b={};for(var T in a)if({}.hasOwnProperty.call(a,T)){if(x.indexOf(T)!==-1)continue;b[T]=a[T]}return b}function c(a,x){var b=Object.keys(a);if(Object.getOwnPropertySymbols){var T=Object.getOwnPropertySymbols(a);x&&(T=T.filter(function(B){return Object.getOwnPropertyDescriptor(a,B).enumerable})),b.push.apply(b,T)}return b}function v(a){for(var x=1;x<arguments.length;x++){var b=arguments[x]!=null?arguments[x]:{};x%2?c(Object(b),!0).forEach(function(T){P(a,T,b[T])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):c(Object(b)).forEach(function(T){Object.defineProperty(a,T,Object.getOwnPropertyDescriptor(b,T))})}return a}function P(a,x,b){return(x=E(x))in a?Object.defineProperty(a,x,{value:b,enumerable:!0,configurable:!0,writable:!0}):a[x]=b,a}function E(a){var x=F(a,"string");return typeof x=="symbol"?x:x+""}function F(a,x){if(typeof a!="object"||!a)return a;var b=a[Symbol.toPrimitive];if(b!==void 0){var T=b.call(a,x||"default");if(typeof T!="object")return T;throw new TypeError("@@toPrimitive must return a primitive value.")}return(x==="string"?String:Number)(a)}let q={},W=[];function U(){q={},W=[]}function K(a){let x;return a.const!==void 0?x=a.const:a.examples!==void 0&&a.examples.length?x=a.examples[0]:a.enum!==void 0&&a.enum.length?x=a.enum[0]:a.default!==void 0&&(x=a.default),x}function f(a){let x=K(a);if(x!==void 0)return{value:x,readOnly:a.readOnly,writeOnly:a.writeOnly,type:null}}function m(a,x,b,T){if(T){if(W.includes(a))return(0,y.getResultForCircular)((0,A.inferType)(a));W.push(a)}if(T&&T.depth>x.maxSampleDepth)return(0,y.popSchemaStack)(W,T),(0,y.getResultForCircular)((0,A.inferType)(a));if(a.$ref){if(!b)throw new Error("Your schema contains $ref. You must provide full specification in the third parameter.");let S=decodeURIComponent(a.$ref);S.startsWith("#")&&(S=S.substring(1));let G=N.default.get(b,S),X;if(q[S]!==!0){q[S]=!0;let tt=m(G,x,b,T);if(x.format==="xml"){let Z=S.split("/").pop(),z=v(v({},T),{},{propertyName:T?.propertyName||Z}),{propertyName:nt,value:ut}=(0,y.applyXMLAttributes)(tt,G,z);X=v(v({},tt),{},{value:{[nt||"root"]:ut}})}else X=tt;q[S]=!1}else{let tt=(0,A.inferType)(G);X=(0,y.getResultForCircular)(tt)}return(0,y.popSchemaStack)(W,T),X}if(a.example!==void 0)return(0,y.popSchemaStack)(W,T),{value:a.example,readOnly:a.readOnly,writeOnly:a.writeOnly,type:a.type};if(a.allOf!==void 0)return(0,y.popSchemaStack)(W,T),f(a)||(0,h.allOfSample)(v(v({},a),{},{allOf:void 0}),a.allOf,x,b,T);if(a.oneOf&&a.oneOf.length){a.anyOf&&(x.quiet||console.warn("oneOf and anyOf are not supported on the same level. Skipping anyOf")),(0,y.popSchemaStack)(W,T);let S=Object.assign({readOnly:a.readOnly,writeOnly:a.writeOnly},a.oneOf[0]);return H(a,S)}if(a.anyOf&&a.anyOf.length){(0,y.popSchemaStack)(W,T);let S=Object.assign({readOnly:a.readOnly,writeOnly:a.writeOnly},a.anyOf[0]);return H(a,S)}if(a.if&&a.then){(0,y.popSchemaStack)(W,T);let{if:S,then:G}=a,X=$(a,D);return m((0,y.mergeDeep)(X,S,G),x,b,T)}let B=K(a),Q=null;if(B===void 0){B=null,Q=a.type,Array.isArray(Q)&&a.type.length>0&&(Q=a.type[0]),Q||(Q=(0,A.inferType)(a));let S=I._samplers[Q];S&&(B=S(a,x,b,T))}return(0,y.popSchemaStack)(W,T),{value:B,readOnly:a.readOnly,writeOnly:a.writeOnly,type:Q};function H(S,G){let X=f(S);if(X!==void 0)return X;let tt=m(v(v({},S),{},{oneOf:void 0,anyOf:void 0}),x,b,T),Z=m(G,x,b,T);if(typeof tt.value=="object"&&typeof Z.value=="object"){let z=(0,y.mergeDeep)(tt.value,Z.value);return v(v({},Z),{},{value:z})}return Z}}},{"./allOf":4,"./infer":5,"./openapi-sampler":6,"./utils":15,"json-pointer":3}],15:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.SKIP_SYMBOL=void 0,w.applyXMLAttributes=W,w.ensureMinLength=l,w.getResultForCircular=P,w.getXMLAttributes=F,w.mergeDeep=c,w.popSchemaStack=E,w.toRFCDateTime=$,w.uuid=v;function I(f,m){var a=Object.keys(f);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(f);m&&(x=x.filter(function(b){return Object.getOwnPropertyDescriptor(f,b).enumerable})),a.push.apply(a,x)}return a}function h(f){for(var m=1;m<arguments.length;m++){var a=arguments[m]!=null?arguments[m]:{};m%2?I(Object(a),!0).forEach(function(x){A(f,x,a[x])}):Object.getOwnPropertyDescriptors?Object.defineProperties(f,Object.getOwnPropertyDescriptors(a)):I(Object(a)).forEach(function(x){Object.defineProperty(f,x,Object.getOwnPropertyDescriptor(a,x))})}return f}function A(f,m,a){return(m=y(m))in f?Object.defineProperty(f,m,{value:a,enumerable:!0,configurable:!0,writable:!0}):f[m]=a,f}function y(f){var m=N(f,"string");return typeof m=="symbol"?m:m+""}function N(f,m){if(typeof f!="object"||!f)return f;var a=f[Symbol.toPrimitive];if(a!==void 0){var x=a.call(f,m||"default");if(typeof x!="object")return x;throw new TypeError("@@toPrimitive must return a primitive value.")}return(m==="string"?String:Number)(f)}let D=w.SKIP_SYMBOL=Symbol("skip");function j(f){return f<10?"0"+f:f}function $(f,m,a,x){var b=a?"":f.getUTCFullYear()+"-"+j(f.getUTCMonth()+1)+"-"+j(f.getUTCDate());return m||(b+="T"+j(f.getUTCHours())+":"+j(f.getUTCMinutes())+":"+j(f.getUTCSeconds())+(x?"."+(f.getUTCMilliseconds()/1e3).toFixed(3).slice(2,5):"")+"Z"),b}function l(f,m){return m>f.length?f.repeat(Math.trunc(m/f.length)+1).substring(0,m):f}function c(){let f=b=>b&&typeof b=="object";for(var m=arguments.length,a=new Array(m),x=0;x<m;x++)a[x]=arguments[x];return a.reduce((b,T)=>(Object.keys(T||{}).forEach(B=>{let Q=b[B],H=T[B];f(Q)&&f(H)?b[B]=c(Q,H):b[B]=H}),b),Array.isArray(a[a.length-1])?[]:{})}function v(f){var m=U(f),a=K(m,m,m,m),x="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,b=>{var T=a()*16%16|0;return(b=="x"?T:T&3|8).toString(16)});return x}function P(f){return{value:f==="object"?{}:f==="array"?[]:void 0}}function E(f,m){m&&f.pop()}function F(f){var m,a,x,b,T,B,Q;return{name:(f==null||(m=f.xml)===null||m===void 0?void 0:m.name)||"",prefix:(f==null||(a=f.xml)===null||a===void 0?void 0:a.prefix)||"",namespace:(f==null||(x=f.xml)===null||x===void 0?void 0:x.namespace)||null,attribute:(b=f==null||(T=f.xml)===null||T===void 0?void 0:T.attribute)!==null&&b!==void 0?b:!1,wrapped:(B=f==null||(Q=f.xml)===null||Q===void 0?void 0:Q.wrapped)!==null&&B!==void 0?B:!1}}function q(f){let m=f?.xml;return m!=null&&m.nodeType?m.nodeType:m?.attribute===!0?"attribute":m?.wrapped===!0&&f?.type==="array"?"element":f!=null&&f.$ref||f!=null&&f.$dynamicRef||f?.type==="array"||f!=null&&f.oneOf||f!=null&&f.anyOf||f!=null&&f.allOf?"none":"element"}function W(f){let m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{value:x}=f,{propertyName:b}=a,{name:T,prefix:B,namespace:Q}=F(m),H=q(m),S=T||b?"".concat(B?B+":":"").concat(T||b):null,G=typeof x=="object"?Array.isArray(x)?[...x]:h({},x):x;switch(H){case"attribute":S&&(S="$".concat(S));break;case"text":S="#text";break;case"cdata":S="#cdata";break;case"none":if(m.type==="array"){if(S=null,m.example!==void 0){var X;S=((X=m.items)===null||X===void 0||(X=X.xml)===null||X===void 0?void 0:X.name)||S}}else S=null;break;default:m.type==="array"&&Array.isArray(G)&&(G={[S]:[...G]});break}return Q&&H!=="text"&&H!=="cdata"&&H!=="none"&&(typeof G=="object"?G["$xmlns".concat(B?":"+B:"")]=Q:G={["$xmlns".concat(B?":"+B:"")]:Q,"#text":G}),{propertyName:S,value:G}}function U(f){var m=0;if(f.length==0)return m;for(var a=0;a<f.length;a++){var x=f.charCodeAt(a);m=(m<<5)-m+x,m=m&m}return m}function K(f,m,a,x){return function(){f|=0,m|=0,a|=0,x|=0;var b=f-(m<<27|m>>>5)|0;return f=m^(a<<17|a>>>15),m=a+x|0,a=x+b|0,x=f+b|0,(x>>>0)/4294967296}}},{}]},{},[6])(6)})});var zt=Nt((Ke,Kt)=>{"use strict";Kt.exports=(Y,C=process.argv)=>{let J=Y.startsWith("-")?"":Y.length===1?"-":"--",_=C.indexOf(J+Y),R=C.indexOf("--");return _!==-1&&(R===-1||_<R)}});var We=Nt((ze,Zt)=>{"use strict";var Ge=bt("os"),Jt=bt("tty"),ft=zt(),{env:it}=process,mt;ft("no-color")||ft("no-colors")||ft("color=false")||ft("color=never")?mt=0:(ft("color")||ft("colors")||ft("color=true")||ft("color=always"))&&(mt=1);"FORCE_COLOR"in it&&(it.FORCE_COLOR==="true"?mt=1:it.FORCE_COLOR==="false"?mt=0:mt=it.FORCE_COLOR.length===0?1:Math.min(parseInt(it.FORCE_COLOR,10),3));function It(Y){return Y===0?!1:{level:Y,hasBasic:!0,has256:Y>=2,has16m:Y>=3}}function Dt(Y,C){if(mt===0)return 0;if(ft("color=16m")||ft("color=full")||ft("color=truecolor"))return 3;if(ft("color=256"))return 2;if(Y&&!C&&mt===void 0)return 0;let J=mt||0;if(it.TERM==="dumb")return J;if(process.platform==="win32"){let _=Ge.release().split(".");return Number(_[0])>=10&&Number(_[2])>=10586?Number(_[2])>=14931?3:2:1}if("CI"in it)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some(_=>_ in it)||it.CI_NAME==="codeship"?1:J;if("TEAMCITY_VERSION"in it)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(it.TEAMCITY_VERSION)?1:0;if(it.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in it){let _=parseInt((it.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(it.TERM_PROGRAM){case"iTerm.app":return _>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(it.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(it.TERM)||"COLORTERM"in it?1:J}function Be(Y){let C=Dt(Y,Y&&Y.isTTY);return It(C)}Zt.exports={supportsColor:Be,stdout:It(Dt(!0,Jt.isatty(1))),stderr:It(Dt(!0,Jt.isatty(2)))}});export{Fe as a,Ue as b,We as c};
13
+ `):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function Me(r,t,e,i){let n=this.extractAttributes(r);if(i.push(t,n),this.checkStopNode(i)){let u=this.buildRawContent(r),s=this.buildAttributesForStopNode(r);return i.pop(),this.buildObjectNode(u,t,s,e)}let o=this.j2x(r,e+1,i);return i.pop(),r[this.options.textNodeName]!==void 0&&Object.keys(r).length===1?this.buildTextValNode(r[this.options.textNodeName],t,o.attrStr,e,i):this.buildObjectNode(o.val,t,o.attrStr,e)}function Ie(r){return this.options.indentBy.repeat(r)}function De(r){return!(!r.startsWith(this.options.attributeNamePrefix)||r===this.options.textNodeName)&&r.substr(this.attrPrefixLen)}pt.prototype.build=function(r){if(this.options.preserveOrder)return Pe(r,this.options);{Array.isArray(r)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(r={[this.options.arrayNodeName]:r});let t=new Ot;return this.j2x(r,0,t).val}},pt.prototype.j2x=function(r,t,e){let i="",n="";if(this.options.maxNestedTags&&e.getDepth()>=this.options.maxNestedTags)throw new Error("Maximum nested tags exceeded");let o=this.options.jPath?e.toString():e,u=this.checkStopNode(e);for(let s in r)if(Object.prototype.hasOwnProperty.call(r,s))if(r[s]===void 0)this.isAttribute(s)&&(n+="");else if(r[s]===null)this.isAttribute(s)||s===this.options.cdataPropName?n+="":s[0]==="?"?n+=this.indentate(t)+"<"+s+"?"+this.tagEndChar:n+=this.indentate(t)+"<"+s+"/"+this.tagEndChar;else if(r[s]instanceof Date)n+=this.buildTextValNode(r[s],s,"",t,e);else if(typeof r[s]!="object"){let d=this.isAttribute(s);if(d&&!this.ignoreAttributesFn(d,o))i+=this.buildAttrPairStr(d,""+r[s],u);else if(!d)if(s===this.options.textNodeName){let p=this.options.tagValueProcessor(s,""+r[s]);n+=this.replaceEntitiesValue(p)}else{e.push(s);let p=this.checkStopNode(e);if(e.pop(),p){let g=""+r[s];n+=g===""?this.indentate(t)+"<"+s+this.closeTag(s)+this.tagEndChar:this.indentate(t)+"<"+s+">"+g+"</"+s+this.tagEndChar}else n+=this.buildTextValNode(r[s],s,"",t,e)}}else if(Array.isArray(r[s])){let d=r[s].length,p="",g="";for(let O=0;O<d;O++){let M=r[s][O];if(M!==void 0)if(M===null)s[0]==="?"?n+=this.indentate(t)+"<"+s+"?"+this.tagEndChar:n+=this.indentate(t)+"<"+s+"/"+this.tagEndChar;else if(typeof M=="object")if(this.options.oneListGroup){e.push(s);let L=this.j2x(M,t+1,e);e.pop(),p+=L.val,this.options.attributesGroupName&&M.hasOwnProperty(this.options.attributesGroupName)&&(g+=L.attrStr)}else p+=this.processTextOrObjNode(M,s,t,e);else if(this.options.oneListGroup){let L=this.options.tagValueProcessor(s,M);L=this.replaceEntitiesValue(L),p+=L}else{e.push(s);let L=this.checkStopNode(e);if(e.pop(),L){let k=""+M;p+=k===""?this.indentate(t)+"<"+s+this.closeTag(s)+this.tagEndChar:this.indentate(t)+"<"+s+">"+k+"</"+s+this.tagEndChar}else p+=this.buildTextValNode(M,s,"",t,e)}}this.options.oneListGroup&&(p=this.buildObjectNode(p,s,g,t)),n+=p}else if(this.options.attributesGroupName&&s===this.options.attributesGroupName){let d=Object.keys(r[s]),p=d.length;for(let g=0;g<p;g++)i+=this.buildAttrPairStr(d[g],""+r[s][d[g]],u)}else n+=this.processTextOrObjNode(r[s],s,t,e);return{attrStr:i,val:n}},pt.prototype.buildAttrPairStr=function(r,t,e){return e||(t=this.options.attributeValueProcessor(r,""+t),t=this.replaceEntitiesValue(t)),this.options.suppressBooleanAttributes&&t==="true"?" "+r:" "+r+'="'+t+'"'},pt.prototype.extractAttributes=function(r){if(!r||typeof r!="object")return null;let t={},e=!1;if(this.options.attributesGroupName&&r[this.options.attributesGroupName]){let i=r[this.options.attributesGroupName];for(let n in i)Object.prototype.hasOwnProperty.call(i,n)&&(t[n.startsWith(this.options.attributeNamePrefix)?n.substring(this.options.attributeNamePrefix.length):n]=i[n],e=!0)}else for(let i in r){if(!Object.prototype.hasOwnProperty.call(r,i))continue;let n=this.isAttribute(i);n&&(t[n]=r[i],e=!0)}return e?t:null},pt.prototype.buildRawContent=function(r){if(typeof r=="string")return r;if(typeof r!="object"||r===null)return String(r);if(r[this.options.textNodeName]!==void 0)return r[this.options.textNodeName];let t="";for(let e in r){if(!Object.prototype.hasOwnProperty.call(r,e)||this.isAttribute(e)||this.options.attributesGroupName&&e===this.options.attributesGroupName)continue;let i=r[e];if(e===this.options.textNodeName)t+=i;else if(Array.isArray(i)){for(let n of i)if(typeof n=="string"||typeof n=="number")t+=`<${e}>${n}</${e}>`;else if(typeof n=="object"&&n!==null){let o=this.buildRawContent(n),u=this.buildAttributesForStopNode(n);t+=o===""?`<${e}${u}/>`:`<${e}${u}>${o}</${e}>`}}else if(typeof i=="object"&&i!==null){let n=this.buildRawContent(i),o=this.buildAttributesForStopNode(i);t+=n===""?`<${e}${o}/>`:`<${e}${o}>${n}</${e}>`}else t+=`<${e}>${i}</${e}>`}return t},pt.prototype.buildAttributesForStopNode=function(r){if(!r||typeof r!="object")return"";let t="";if(this.options.attributesGroupName&&r[this.options.attributesGroupName]){let e=r[this.options.attributesGroupName];for(let i in e){if(!Object.prototype.hasOwnProperty.call(e,i))continue;let n=i.startsWith(this.options.attributeNamePrefix)?i.substring(this.options.attributeNamePrefix.length):i,o=e[i];o===!0&&this.options.suppressBooleanAttributes?t+=" "+n:t+=" "+n+'="'+o+'"'}}else for(let e in r){if(!Object.prototype.hasOwnProperty.call(r,e))continue;let i=this.isAttribute(e);if(i){let n=r[e];n===!0&&this.options.suppressBooleanAttributes?t+=" "+i:t+=" "+i+'="'+n+'"'}}return t},pt.prototype.buildObjectNode=function(r,t,e,i){if(r==="")return t[0]==="?"?this.indentate(i)+"<"+t+e+"?"+this.tagEndChar:this.indentate(i)+"<"+t+e+this.closeTag(t)+this.tagEndChar;{let n="</"+t+this.tagEndChar,o="";return t[0]==="?"&&(o="?",n=""),!e&&e!==""||r.indexOf("<")!==-1?this.options.commentPropName!==!1&&t===this.options.commentPropName&&o.length===0?this.indentate(i)+`<!--${r}-->`+this.newLine:this.indentate(i)+"<"+t+e+o+this.tagEndChar+r+this.indentate(i)+n:this.indentate(i)+"<"+t+e+o+">"+r+n}},pt.prototype.closeTag=function(r){let t="";return this.options.unpairedTags.indexOf(r)!==-1?this.options.suppressUnpairedNode||(t="/"):t=this.options.suppressEmptyNode?"/":`></${r}`,t},pt.prototype.checkStopNode=function(r){if(!this.stopNodeExpressions||this.stopNodeExpressions.length===0)return!1;for(let t=0;t<this.stopNodeExpressions.length;t++)if(r.matches(this.stopNodeExpressions[t]))return!0;return!1},pt.prototype.buildTextValNode=function(r,t,e,i,n){if(this.options.cdataPropName!==!1&&t===this.options.cdataPropName){let o=String(r).replace(/\]\]>/g,"]]]]><![CDATA[>");return this.indentate(i)+`<![CDATA[${o}]]>`+this.newLine}if(this.options.commentPropName!==!1&&t===this.options.commentPropName){let o=String(r).replace(/--/g,"- -").replace(/-$/,"- ");return this.indentate(i)+`<!--${o}-->`+this.newLine}if(t[0]==="?")return this.indentate(i)+"<"+t+e+"?"+this.tagEndChar;{let o=this.options.tagValueProcessor(t,r);return o=this.replaceEntitiesValue(o),o===""?this.indentate(i)+"<"+t+e+this.closeTag(t)+this.tagEndChar:this.indentate(i)+"<"+t+e+">"+o+"</"+t+this.tagEndChar}},pt.prototype.replaceEntitiesValue=function(r){if(r&&r.length>0&&this.options.processEntities)for(let t=0;t<this.options.entities.length;t++){let e=this.options.entities[t];r=r.replace(e.regex,e.val)}return r};let $e=pt,Le={validate:c};R.exports=h})()},{}],2:[function(_,R,w){var I=Object.prototype.hasOwnProperty,h=Object.prototype.toString;R.exports=function(y,N,D){if(h.call(N)!=="[object Function]")throw new TypeError("iterator must be a function");var j=y.length;if(j===+j)for(var $=0;$<j;$++)N.call(D,y[$],$,y);else for(var l in y)I.call(y,l)&&N.call(D,y[l],l,y)}},{}],3:[function(_,R,w){"use strict";var I=_("foreach");R.exports=h;function h(A,y,N){if(arguments.length===3)return h.set(A,y,N);if(arguments.length===2)return h.get(A,y);var D=h.bind(h,A);for(var j in h)h.hasOwnProperty(j)&&(D[j]=h[j].bind(D,A));return D}h.get=function(y,N){for(var D=Array.isArray(N)?N:h.parse(N),j=0;j<D.length;++j){var $=D[j];if(!(typeof y=="object"&&$ in y))throw new Error("Invalid reference token: "+$);y=y[$]}return y},h.set=function(y,N,D){var j=Array.isArray(N)?N:h.parse(N),$=j[0];if(j.length===0)throw Error("Can not set the root object");for(var l=0;l<j.length-1;++l){var c=j[l];typeof c!="string"&&typeof c!="number"&&(c=String(c)),!(c==="__proto__"||c==="constructor"||c==="prototype")&&(c==="-"&&Array.isArray(y)&&(c=y.length),$=j[l+1],c in y||($.match(/^(\d+|-)$/)?y[c]=[]:y[c]={}),y=y[c])}return $==="-"&&Array.isArray(y)&&($=y.length),y[$]=D,this},h.remove=function(A,y){var N=Array.isArray(y)?y:h.parse(y),D=N[N.length-1];if(D===void 0)throw new Error('Invalid JSON pointer for remove: "'+y+'"');var j=h.get(A,N.slice(0,-1));if(Array.isArray(j)){var $=+D;if(D===""&&isNaN($))throw new Error('Invalid array index: "'+D+'"');Array.prototype.splice.call(j,$,1)}else delete j[D]},h.dict=function(y,N){var D={};return h.walk(y,function(j,$){D[$]=j},N),D},h.walk=function(y,N,D){var j=[];D=D||function($){var l=Object.prototype.toString.call($);return l==="[object Object]"||l==="[object Array]"},(function $(l){I(l,function(c,v){j.push(String(v)),D(c)?$(c):N(c,h.compile(j)),j.pop()})})(y)},h.has=function(y,N){try{h.get(y,N)}catch{return!1}return!0},h.escape=function(y){return y.toString().replace(/~/g,"~0").replace(/\//g,"~1")},h.unescape=function(y){return y.replace(/~1/g,"/").replace(/~0/g,"~")},h.parse=function(y){if(y==="")return[];if(y.charAt(0)!=="/")throw new Error("Invalid JSON pointer: "+y);return y.substring(1).split(/\//).map(h.unescape)},h.compile=function(y){return y.length===0?"":"/"+y.map(h.escape).join("/")}},{foreach:2}],4:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.allOfSample=$;var I=_("./traverse"),h=_("./utils");function A(l,c){var v=Object.keys(l);if(Object.getOwnPropertySymbols){var P=Object.getOwnPropertySymbols(l);c&&(P=P.filter(function(E){return Object.getOwnPropertyDescriptor(l,E).enumerable})),v.push.apply(v,P)}return v}function y(l){for(var c=1;c<arguments.length;c++){var v=arguments[c]!=null?arguments[c]:{};c%2?A(Object(v),!0).forEach(function(P){N(l,P,v[P])}):Object.getOwnPropertyDescriptors?Object.defineProperties(l,Object.getOwnPropertyDescriptors(v)):A(Object(v)).forEach(function(P){Object.defineProperty(l,P,Object.getOwnPropertyDescriptor(v,P))})}return l}function N(l,c,v){return(c=D(c))in l?Object.defineProperty(l,c,{value:v,enumerable:!0,configurable:!0,writable:!0}):l[c]=v,l}function D(l){var c=j(l,"string");return typeof c=="symbol"?c:c+""}function j(l,c){if(typeof l!="object"||!l)return l;var v=l[Symbol.toPrimitive];if(v!==void 0){var P=v.call(l,c||"default");if(typeof P!="object")return P;throw new TypeError("@@toPrimitive must return a primitive value.")}return(c==="string"?String:Number)(l)}function $(l,c,v,P,E){let F=(0,I.traverse)(l,v,P),q=[];for(let W of c){let{type:U,readOnly:K,writeOnly:f,value:m}=(0,I.traverse)(y({type:F.type},W),v,P,y(y({},E),{},{isAllOfChild:!0}));F.type&&U&&U!==F.type&&(console.warn("allOf: schemas with different types can't be merged"),F.type=U),F.type=F.type||U,F.readOnly=F.readOnly||K,F.writeOnly=F.writeOnly||f,m!=null&&q.push(m)}if(F.type==="object"){F.value=(0,h.mergeDeep)(F.value||{},...q.filter(W=>typeof W=="object"));for(let W in F.value)F.value[W]===h.SKIP_SYMBOL&&delete F.value[W];return F}else{F.type==="array"&&(v.quiet||console.warn('OpenAPI Sampler: found allOf with "array" type. Result may be incorrect'));let W=q[q.length-1];return F.value=W??F.value,F}}},{"./traverse":14,"./utils":15}],5:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.inferType=h;let I={multipleOf:"number",maximum:"number",exclusiveMaximum:"number",minimum:"number",exclusiveMinimum:"number",maxLength:"string",minLength:"string",pattern:"string",items:"array",maxItems:"array",minItems:"array",uniqueItems:"array",additionalItems:"array",maxProperties:"object",minProperties:"object",required:"object",additionalProperties:"object",properties:"object",patternProperties:"object",dependencies:"object"};function h(A){if(A.type!==void 0)return Array.isArray(A.type)?A.type.length===0?null:A.type[0]:A.type;let y=Object.keys(I);for(var N=0;N<y.length;N++){let D=y[N],j=I[D];if(A[D]!==void 0)return j}return null}},{}],6:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w._registerSampler=l,w._samplers=void 0,Object.defineProperty(w,"inferType",{enumerable:!0,get:function(){return y.inferType}}),w.sample=$;var I=_("./traverse"),h=_("./samplers/index"),A=_("fast-xml-parser"),y=_("./infer"),N=w._samplers={};let D={skipReadOnly:!1,maxSampleDepth:15};function j(c,v){if(!c)throw new Error("Unknown format output for building XML.");if(Array.isArray(c)||Object.keys(c).length>1){var P;c={[(v==null||(P=v.xml)===null||P===void 0?void 0:P.name)||"root"]:c}}return new A.XMLBuilder({ignoreAttributes:!1,format:!0,attributeNamePrefix:"$",textNodeName:"#text",cdataPropName:"#cdata"}).build(c)}function $(c,v,P){let E=Object.assign({},D,v);(0,I.clearCache)();let F=(0,I.traverse)(c,E,P).value;return E?.format==="xml"?j(F,c):F}function l(c,v){N[c]=v}l("array",h.sampleArray),l("boolean",h.sampleBoolean),l("integer",h.sampleNumber),l("number",h.sampleNumber),l("object",h.sampleObject),l("string",h.sampleString)},{"./infer":5,"./samplers/index":9,"./traverse":14,"fast-xml-parser":1}],7:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleArray=$;var I=_("../traverse"),h=_("../utils");function A(l,c){var v=Object.keys(l);if(Object.getOwnPropertySymbols){var P=Object.getOwnPropertySymbols(l);c&&(P=P.filter(function(E){return Object.getOwnPropertyDescriptor(l,E).enumerable})),v.push.apply(v,P)}return v}function y(l){for(var c=1;c<arguments.length;c++){var v=arguments[c]!=null?arguments[c]:{};c%2?A(Object(v),!0).forEach(function(P){N(l,P,v[P])}):Object.getOwnPropertyDescriptors?Object.defineProperties(l,Object.getOwnPropertyDescriptors(v)):A(Object(v)).forEach(function(P){Object.defineProperty(l,P,Object.getOwnPropertyDescriptor(v,P))})}return l}function N(l,c,v){return(c=D(c))in l?Object.defineProperty(l,c,{value:v,enumerable:!0,configurable:!0,writable:!0}):l[c]=v,l}function D(l){var c=j(l,"string");return typeof c=="symbol"?c:c+""}function j(l,c){if(typeof l!="object"||!l)return l;var v=l[Symbol.toPrimitive];if(v!==void 0){var P=v.call(l,c||"default");if(typeof P!="object")return P;throw new TypeError("@@toPrimitive must return a primitive value.")}return(c==="string"?String:Number)(l)}function $(l){let c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},v=arguments.length>2?arguments[2]:void 0,P=arguments.length>3?arguments[3]:void 0,E=P&&P.depth||1,F=Math.min(l.maxItems!=null?l.maxItems:1/0,l.minItems||1),q=l.prefixItems||l.items||l.contains;Array.isArray(q)&&(F=Math.max(F,q.length));let W=f=>Array.isArray(q)?q[f]||{}:q||{},U=[];if(!q)return U;for(let f=0;f<F;f++){let m=W(f),{value:a}=(0,I.traverse)(m,c,v,{depth:E+1});if(c?.format==="xml"){let{value:x,propertyName:b}=(0,h.applyXMLAttributes)({value:a},m,P);if(b){var K;(K=U)!==null&&K!==void 0&&K[b]||(U=y(y({},U),{},{[b]:[]})),U[b].push(x)}else U=y(y({},U),x)}else U.push(a)}if(c?.format==="xml"&&E===1){let{value:f,propertyName:m}=(0,h.applyXMLAttributes)({value:null},l,P);m&&(f?U=Array.isArray(U)?{[m]:y(y({},f),U.map(a=>({"#text":y({},a)})))}:{[m]:y(y({},U),f)}:U={[m]:U})}return U}},{"../traverse":14,"../utils":15}],8:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleBoolean=I;function I(h){return!0}},{}],9:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),Object.defineProperty(w,"sampleArray",{enumerable:!0,get:function(){return I.sampleArray}}),Object.defineProperty(w,"sampleBoolean",{enumerable:!0,get:function(){return h.sampleBoolean}}),Object.defineProperty(w,"sampleNumber",{enumerable:!0,get:function(){return A.sampleNumber}}),Object.defineProperty(w,"sampleObject",{enumerable:!0,get:function(){return y.sampleObject}}),Object.defineProperty(w,"sampleString",{enumerable:!0,get:function(){return N.sampleString}});var I=_("./array"),h=_("./boolean"),A=_("./number"),y=_("./object"),N=_("./string")},{"./array":7,"./boolean":8,"./number":10,"./object":11,"./string":13}],10:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleNumber=I;function I(h){let A=0;if(h.type==="number"&&(h.format==="float"||h.format==="double")&&(A=.1),typeof h.exclusiveMinimum=="boolean"||typeof h.exclusiveMaximum=="boolean"){if(Number.isFinite(h.maximum)&&Number.isFinite(h.minimum))return A=h.exclusiveMinimum?Math.floor(h.minimum)+1:h.minimum,(h.exclusiveMaximum&&A>=h.maximum||!h.exclusiveMaximum&&A>h.maximum)&&(A=(h.maximum+h.minimum)/2),A;if(Number.isFinite(h.minimum))return h.exclusiveMinimum?Math.floor(h.minimum)+1:h.minimum;if(Number.isFinite(h.maximum))return h.exclusiveMaximum?h.maximum>0?0:Math.floor(h.maximum)-1:h.maximum>0?0:h.maximum}else{if(Number.isFinite(h.minimum))return h.minimum;Number.isFinite(h.exclusiveMinimum)?(A=Math.floor(h.exclusiveMinimum)+1,A===h.exclusiveMaximum&&(A=(A+Math.floor(h.exclusiveMaximum)-1)/2)):Number.isFinite(h.exclusiveMaximum)?A=Math.floor(h.exclusiveMaximum)-1:Number.isFinite(h.maximum)&&(A=h.maximum)}return A}},{}],11:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleObject=$;var I=_("../traverse"),h=_("../utils");function A(l,c){var v=Object.keys(l);if(Object.getOwnPropertySymbols){var P=Object.getOwnPropertySymbols(l);c&&(P=P.filter(function(E){return Object.getOwnPropertyDescriptor(l,E).enumerable})),v.push.apply(v,P)}return v}function y(l){for(var c=1;c<arguments.length;c++){var v=arguments[c]!=null?arguments[c]:{};c%2?A(Object(v),!0).forEach(function(P){N(l,P,v[P])}):Object.getOwnPropertyDescriptors?Object.defineProperties(l,Object.getOwnPropertyDescriptors(v)):A(Object(v)).forEach(function(P){Object.defineProperty(l,P,Object.getOwnPropertyDescriptor(v,P))})}return l}function N(l,c,v){return(c=D(c))in l?Object.defineProperty(l,c,{value:v,enumerable:!0,configurable:!0,writable:!0}):l[c]=v,l}function D(l){var c=j(l,"string");return typeof c=="symbol"?c:c+""}function j(l,c){if(typeof l!="object"||!l)return l;var v=l[Symbol.toPrimitive];if(v!==void 0){var P=v.call(l,c||"default");if(typeof P!="object")return P;throw new TypeError("@@toPrimitive must return a primitive value.")}return(c==="string"?String:Number)(l)}function $(l){let c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},v=arguments.length>2?arguments[2]:void 0,P=arguments.length>3?arguments[3]:void 0,E={},F=P&&P.depth||1;if(l&&typeof l.properties=="object"){let q=Array.isArray(l.required)?l.required:[],W={};for(let U of q)W[U]=!0;Object.keys(l.properties).forEach(U=>{if(c.skipNonRequired&&!W.hasOwnProperty(U))return;let K=(0,I.traverse)(l.properties[U],c,v,{propertyName:U,depth:F+1});if(c.skipReadOnly&&K.readOnly){P!=null&&P.isAllOfChild&&(E[U]=h.SKIP_SYMBOL);return}if(c.skipWriteOnly&&K.writeOnly){P!=null&&P.isAllOfChild&&(E[U]=h.SKIP_SYMBOL);return}if(c?.format==="xml"){let{propertyName:f,value:m}=(0,h.applyXMLAttributes)(K,l.properties[U],{propertyName:U});f?E[f]=m:m!==null&&typeof m=="object"&&(E=y(y({},E),m))}else E[U]=K.value})}if(l&&typeof l.additionalProperties=="object"){let q=l.additionalProperties["x-additionalPropertiesName"]||"property";E["".concat(String(q),"1")]=(0,I.traverse)(l.additionalProperties,c,v,{depth:F+1}).value,E["".concat(String(q),"2")]=(0,I.traverse)(l.additionalProperties,c,v,{depth:F+1}).value}if(l&&typeof l.properties=="object"&&l.maxProperties!==void 0&&Object.keys(E).length>l.maxProperties){let q={},W=0;(Array.isArray(l.required)?l.required:[]).forEach(K=>{E[K]!==void 0&&(q[K]=E[K],W++)}),Object.keys(E).forEach(K=>{W<l.maxProperties&&!q.hasOwnProperty(K)&&(q[K]=E[K],W++)}),E=q}return E}},{"../traverse":14,"../utils":15}],12:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.regexSample=y;function I(){return!0}function h(N,D){return N}function A(N,D,j){let $=1;if(N)switch(N){case"?":{$=I()?0:1;break}case"*":{$=h(0,8);break}case"+":{$=h(1,8);break}default:throw new Error("Unknown quantifier symbol provided.")}else D!=null&&j!=null?$=h(parseInt(D),parseInt(j)):D!=null&&j==null&&($=parseInt(D));return $}function y(N){let D=!1;if(N instanceof RegExp){var j,$;D=N.flags.includes("i"),N=N.toString(),N=(j=($=N.match(/\/(.+?)\//))===null||$===void 0?void 0:$[1])!==null&&j!==void 0?j:""}N=N.replace(/^(\^)?(.*?)(\$)?$/,"$2");let l,c,v,P=/([.A-Za-z0-9])(?:\{(\d+)(?:\,(\d+)|)\}|(\?|\*|\+))(?![^[]*]|[^{]*})/,E=N.match(P);for(;E!=null;){let K=E[2],f=E[3],m=E[4];v=A(m,K,f),N=N.slice(0,E.index)+E[1].repeat(v)+N.slice(E.index+E[0].length),E=N.match(P)}let F=/(\d-\d|\w-\w|\d|\w|[-!@#$&()`.+,/"])/,q=/\[(\^|)(-|)(.+?)\](?:\{(\d+)(?:\,(\d+)|)\}|(\?|\*|\+)|)/;for(E=N.match(q);E!=null;){let K=E[1]==="^",f=E[2]==="-",m=E[4],a=E[5],x=E[6],b=[],T=E[3],B=T.match(F);for(f&&b.push(45);B!=null;){if(B[0].indexOf("-")===-1)D&&isNaN(Number(B[0]))?(b.push(B[0].toUpperCase().charCodeAt(0)),b.push(B[0].toLowerCase().charCodeAt(0))):b.push(B[0].charCodeAt(0));else{let H=B[0].split("-").map(S=>S.charCodeAt(0));if(l=H[0],c=H[1],l>c)throw new Error("Character range provided is out of order.");for(let S=l;S<=c;S++)if(D&&isNaN(Number(String.fromCharCode(S)))){let G=String.fromCharCode(S);b.push(G.toUpperCase().charCodeAt(0)),b.push(G.toLowerCase().charCodeAt(0))}else b.push(S)}T=T.substring(B[0].length),B=T.match(F)}if(v=A(x,m,a),K){let H=-1;for(let S=48;S<=57;S++){if(H=b.indexOf(S),H>-1){b.splice(H,1);continue}b.push(S)}for(let S=65;S<=90;S++){if(H=b.indexOf(S),H>-1){b.splice(H,1);continue}b.push(S)}for(let S=97;S<=122;S++){if(H=b.indexOf(S),H>-1){b.splice(H,1);continue}b.push(S)}}let Q=Array.from({length:v},()=>String.fromCharCode(b[h(0,b.length-1)])).join("");N=N.slice(0,E.index)+Q+N.slice(E.index+E[0].length),E=N.match(q)}let W=/(.)\{(\d+)\,(\d+)\}/;for(E=N.match(W);E!=null;){if(l=parseInt(E[2]),c=parseInt(E[3]),l>c)throw new Error("Numbers out of order in {} quantifier.");v=h(l,c),N=N.slice(0,E.index)+E[1].repeat(v)+N.slice(E.index+E[0].length),E=N.match(W)}let U=/(.)\{(\d+)\}/;for(E=N.match(U);E!=null;)v=parseInt(E[2]),N=N.slice(0,E.index)+E[1].repeat(v)+N.slice(E.index+E[0].length),E=N.match(U);return N}},{}],13:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.sampleString=H;var I=_("../utils"),h=A(_("./string-regex"));function A(S,G){if(typeof WeakMap=="function")var X=new WeakMap,tt=new WeakMap;return(A=function(Z,z){if(!z&&Z&&Z.__esModule)return Z;var nt,ut,gt={__proto__:null,default:Z};if(Z===null||typeof Z!="object"&&typeof Z!="function")return gt;if(nt=z?tt:X){if(nt.has(Z))return nt.get(Z);nt.set(Z,gt)}for(let ht in Z)ht!=="default"&&{}.hasOwnProperty.call(Z,ht)&&((ut=(nt=Object.defineProperty)&&Object.getOwnPropertyDescriptor(Z,ht))&&(ut.get||ut.set)?nt(gt,ht,ut):gt[ht]=Z[ht]);return gt})(S,G)}let y="qwerty!@#$%^123456";function N(){return"user@example.com"}function D(){return"\u043F\u043E\u0448\u0442\u0430@\u0443\u043A\u0440.\u043D\u0435\u0442"}function j(S,G){let X="pa$$word";return S>X.length&&(X+="_",X+=(0,I.ensureMinLength)(y,S-X.length).substring(0,S-X.length)),X}function $(S){let{min:G,max:X,omitTime:tt,omitDate:Z}=S,z=(0,I.toRFCDateTime)(new Date("2019-08-24T14:15:22.123Z"),tt,Z,!1);return z.length<G&&console.warn("Using minLength = ".concat(G,' is incorrect with format "date-time"')),X&&z.length>X&&console.warn("Using maxLength = ".concat(X,' is incorrect with format "date-time"')),z}function l(S,G){return $({min:S,max:G,omitTime:!1,omitDate:!1})}function c(S,G){return $({min:S,max:G,omitTime:!0,omitDate:!1})}function v(S,G){return $({min:S,max:G,omitTime:!1,omitDate:!0}).slice(1)}function P(S,G,X,tt){let Z=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(tt&&Z)return h.regexSample(tt);let z=(0,I.ensureMinLength)("string",S);return G&&z.length>G&&(z=z.substring(0,G)),z}function E(){return"192.168.0.1"}function F(){return"2001:0db8:85a3:0000:0000:8a2e:0370:7334"}function q(){return"example.com"}function W(){return"\u043F\u0440\u0438\u043A\u043B\u0430\u0434.\u0443\u043A\u0440"}function U(){return"http://example.com"}function K(){return"../dictionary"}function f(){return"http://example.com/{endpoint}"}function m(){return"http://example.com/entity/1"}function a(){return"/entity/1"}function x(S,G,X){return(0,I.uuid)(X||"id")}function b(){return"/json/pointer"}function T(){return"1/relative/json/pointer"}function B(){return"/regex/"}let Q={email:N,"idn-email":D,password:j,"date-time":l,date:c,time:v,ipv4:E,ipv6:F,hostname:q,"idn-hostname":W,iri:m,"iri-reference":a,uri:U,"uri-reference":K,"uri-template":f,uuid:x,default:P,"json-pointer":b,"relative-json-pointer":T,regex:B};function H(S,G,X,tt){let Z=S.format||"default",z=Q[Z]||P,nt=tt&&tt.propertyName;return z(S.minLength||0,S.maxLength,nt,S.pattern,G?.enablePatterns)}},{"../utils":15,"./string-regex":12}],14:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.clearCache=U,w.traverse=m;var I=_("./openapi-sampler"),h=_("./allOf"),A=_("./infer"),y=_("./utils"),N=j(_("json-pointer"));let D=["if","then"];function j(a){return a&&a.__esModule?a:{default:a}}function $(a,x){if(a==null)return{};var b,T,B=l(a,x);if(Object.getOwnPropertySymbols){var Q=Object.getOwnPropertySymbols(a);for(T=0;T<Q.length;T++)b=Q[T],x.indexOf(b)===-1&&{}.propertyIsEnumerable.call(a,b)&&(B[b]=a[b])}return B}function l(a,x){if(a==null)return{};var b={};for(var T in a)if({}.hasOwnProperty.call(a,T)){if(x.indexOf(T)!==-1)continue;b[T]=a[T]}return b}function c(a,x){var b=Object.keys(a);if(Object.getOwnPropertySymbols){var T=Object.getOwnPropertySymbols(a);x&&(T=T.filter(function(B){return Object.getOwnPropertyDescriptor(a,B).enumerable})),b.push.apply(b,T)}return b}function v(a){for(var x=1;x<arguments.length;x++){var b=arguments[x]!=null?arguments[x]:{};x%2?c(Object(b),!0).forEach(function(T){P(a,T,b[T])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):c(Object(b)).forEach(function(T){Object.defineProperty(a,T,Object.getOwnPropertyDescriptor(b,T))})}return a}function P(a,x,b){return(x=E(x))in a?Object.defineProperty(a,x,{value:b,enumerable:!0,configurable:!0,writable:!0}):a[x]=b,a}function E(a){var x=F(a,"string");return typeof x=="symbol"?x:x+""}function F(a,x){if(typeof a!="object"||!a)return a;var b=a[Symbol.toPrimitive];if(b!==void 0){var T=b.call(a,x||"default");if(typeof T!="object")return T;throw new TypeError("@@toPrimitive must return a primitive value.")}return(x==="string"?String:Number)(a)}let q={},W=[];function U(){q={},W=[]}function K(a){let x;return a.const!==void 0?x=a.const:a.examples!==void 0&&a.examples.length?x=a.examples[0]:a.enum!==void 0&&a.enum.length?x=a.enum[0]:a.default!==void 0&&(x=a.default),x}function f(a){let x=K(a);if(x!==void 0)return{value:x,readOnly:a.readOnly,writeOnly:a.writeOnly,type:null}}function m(a,x,b,T){if(T){if(W.includes(a))return(0,y.getResultForCircular)((0,A.inferType)(a));W.push(a)}if(T&&T.depth>x.maxSampleDepth)return(0,y.popSchemaStack)(W,T),(0,y.getResultForCircular)((0,A.inferType)(a));if(a.$ref){if(!b)throw new Error("Your schema contains $ref. You must provide full specification in the third parameter.");let S=decodeURIComponent(a.$ref);S.startsWith("#")&&(S=S.substring(1));let G=N.default.get(b,S),X;if(q[S]!==!0){q[S]=!0;let tt=m(G,x,b,T);if(x.format==="xml"){let Z=S.split("/").pop(),z=v(v({},T),{},{propertyName:T?.propertyName||Z}),{propertyName:nt,value:ut}=(0,y.applyXMLAttributes)(tt,G,z);X=v(v({},tt),{},{value:{[nt||"root"]:ut}})}else X=tt;q[S]=!1}else{let tt=(0,A.inferType)(G);X=(0,y.getResultForCircular)(tt)}return(0,y.popSchemaStack)(W,T),X}if(a.example!==void 0)return(0,y.popSchemaStack)(W,T),{value:a.example,readOnly:a.readOnly,writeOnly:a.writeOnly,type:a.type};if(a.allOf!==void 0)return(0,y.popSchemaStack)(W,T),f(a)||(0,h.allOfSample)(v(v({},a),{},{allOf:void 0}),a.allOf,x,b,T);if(a.oneOf&&a.oneOf.length){a.anyOf&&(x.quiet||console.warn("oneOf and anyOf are not supported on the same level. Skipping anyOf")),(0,y.popSchemaStack)(W,T);let S=Object.assign({readOnly:a.readOnly,writeOnly:a.writeOnly},a.oneOf[0]);return H(a,S)}if(a.anyOf&&a.anyOf.length){(0,y.popSchemaStack)(W,T);let S=Object.assign({readOnly:a.readOnly,writeOnly:a.writeOnly},a.anyOf[0]);return H(a,S)}if(a.if&&a.then){(0,y.popSchemaStack)(W,T);let{if:S,then:G}=a,X=$(a,D);return m((0,y.mergeDeep)(X,S,G),x,b,T)}let B=K(a),Q=null;if(B===void 0){B=null,Q=a.type,Array.isArray(Q)&&a.type.length>0&&(Q=a.type[0]),Q||(Q=(0,A.inferType)(a));let S=I._samplers[Q];S&&(B=S(a,x,b,T))}return(0,y.popSchemaStack)(W,T),{value:B,readOnly:a.readOnly,writeOnly:a.writeOnly,type:Q};function H(S,G){let X=f(S);if(X!==void 0)return X;let tt=m(v(v({},S),{},{oneOf:void 0,anyOf:void 0}),x,b,T),Z=m(G,x,b,T);if(typeof tt.value=="object"&&typeof Z.value=="object"){let z=(0,y.mergeDeep)(tt.value,Z.value);return v(v({},Z),{},{value:z})}return Z}}},{"./allOf":4,"./infer":5,"./openapi-sampler":6,"./utils":15,"json-pointer":3}],15:[function(_,R,w){"use strict";Object.defineProperty(w,"__esModule",{value:!0}),w.SKIP_SYMBOL=void 0,w.applyXMLAttributes=W,w.ensureMinLength=l,w.getResultForCircular=P,w.getXMLAttributes=F,w.mergeDeep=c,w.popSchemaStack=E,w.toRFCDateTime=$,w.uuid=v;function I(f,m){var a=Object.keys(f);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(f);m&&(x=x.filter(function(b){return Object.getOwnPropertyDescriptor(f,b).enumerable})),a.push.apply(a,x)}return a}function h(f){for(var m=1;m<arguments.length;m++){var a=arguments[m]!=null?arguments[m]:{};m%2?I(Object(a),!0).forEach(function(x){A(f,x,a[x])}):Object.getOwnPropertyDescriptors?Object.defineProperties(f,Object.getOwnPropertyDescriptors(a)):I(Object(a)).forEach(function(x){Object.defineProperty(f,x,Object.getOwnPropertyDescriptor(a,x))})}return f}function A(f,m,a){return(m=y(m))in f?Object.defineProperty(f,m,{value:a,enumerable:!0,configurable:!0,writable:!0}):f[m]=a,f}function y(f){var m=N(f,"string");return typeof m=="symbol"?m:m+""}function N(f,m){if(typeof f!="object"||!f)return f;var a=f[Symbol.toPrimitive];if(a!==void 0){var x=a.call(f,m||"default");if(typeof x!="object")return x;throw new TypeError("@@toPrimitive must return a primitive value.")}return(m==="string"?String:Number)(f)}let D=w.SKIP_SYMBOL=Symbol("skip");function j(f){return f<10?"0"+f:f}function $(f,m,a,x){var b=a?"":f.getUTCFullYear()+"-"+j(f.getUTCMonth()+1)+"-"+j(f.getUTCDate());return m||(b+="T"+j(f.getUTCHours())+":"+j(f.getUTCMinutes())+":"+j(f.getUTCSeconds())+(x?"."+(f.getUTCMilliseconds()/1e3).toFixed(3).slice(2,5):"")+"Z"),b}function l(f,m){return m>f.length?f.repeat(Math.trunc(m/f.length)+1).substring(0,m):f}function c(){let f=b=>b&&typeof b=="object";for(var m=arguments.length,a=new Array(m),x=0;x<m;x++)a[x]=arguments[x];return a.reduce((b,T)=>(Object.keys(T||{}).forEach(B=>{let Q=b[B],H=T[B];f(Q)&&f(H)?b[B]=c(Q,H):b[B]=H}),b),Array.isArray(a[a.length-1])?[]:{})}function v(f){var m=U(f),a=K(m,m,m,m),x="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,b=>{var T=a()*16%16|0;return(b=="x"?T:T&3|8).toString(16)});return x}function P(f){return{value:f==="object"?{}:f==="array"?[]:void 0}}function E(f,m){m&&f.pop()}function F(f){var m,a,x,b,T,B,Q;return{name:(f==null||(m=f.xml)===null||m===void 0?void 0:m.name)||"",prefix:(f==null||(a=f.xml)===null||a===void 0?void 0:a.prefix)||"",namespace:(f==null||(x=f.xml)===null||x===void 0?void 0:x.namespace)||null,attribute:(b=f==null||(T=f.xml)===null||T===void 0?void 0:T.attribute)!==null&&b!==void 0?b:!1,wrapped:(B=f==null||(Q=f.xml)===null||Q===void 0?void 0:Q.wrapped)!==null&&B!==void 0?B:!1}}function q(f){let m=f?.xml;return m!=null&&m.nodeType?m.nodeType:m?.attribute===!0?"attribute":m?.wrapped===!0&&f?.type==="array"?"element":f!=null&&f.$ref||f!=null&&f.$dynamicRef||f?.type==="array"||f!=null&&f.oneOf||f!=null&&f.anyOf||f!=null&&f.allOf?"none":"element"}function W(f){let m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{value:x}=f,{propertyName:b}=a,{name:T,prefix:B,namespace:Q}=F(m),H=q(m),S=T||b?"".concat(B?B+":":"").concat(T||b):null,G=typeof x=="object"?Array.isArray(x)?[...x]:h({},x):x;switch(H){case"attribute":S&&(S="$".concat(S));break;case"text":S="#text";break;case"cdata":S="#cdata";break;case"none":if(m.type==="array"){if(S=null,m.example!==void 0){var X;S=((X=m.items)===null||X===void 0||(X=X.xml)===null||X===void 0?void 0:X.name)||S}}else S=null;break;default:m.type==="array"&&Array.isArray(G)&&(G={[S]:[...G]});break}return Q&&H!=="text"&&H!=="cdata"&&H!=="none"&&(typeof G=="object"?G["$xmlns".concat(B?":"+B:"")]=Q:G={["$xmlns".concat(B?":"+B:"")]:Q,"#text":G}),{propertyName:S,value:G}}function U(f){var m=0;if(f.length==0)return m;for(var a=0;a<f.length;a++){var x=f.charCodeAt(a);m=(m<<5)-m+x,m=m&m}return m}function K(f,m,a,x){return function(){f|=0,m|=0,a|=0,x|=0;var b=f-(m<<27|m>>>5)|0;return f=m^(a<<17|a>>>15),m=a+x|0,a=x+b|0,x=f+b|0,(x>>>0)/4294967296}}},{}]},{},[6])(6)})});var zt=Nt((Ke,Kt)=>{"use strict";Kt.exports=(Y,C=process.argv)=>{let J=Y.startsWith("-")?"":Y.length===1?"-":"--",_=C.indexOf(J+Y),R=C.indexOf("--");return _!==-1&&(R===-1||_<R)}});var We=Nt((ze,Zt)=>{"use strict";var Ge=bt("os"),Jt=bt("tty"),ft=zt(),{env:it}=process,mt;ft("no-color")||ft("no-colors")||ft("color=false")||ft("color=never")?mt=0:(ft("color")||ft("colors")||ft("color=true")||ft("color=always"))&&(mt=1);"FORCE_COLOR"in it&&(it.FORCE_COLOR==="true"?mt=1:it.FORCE_COLOR==="false"?mt=0:mt=it.FORCE_COLOR.length===0?1:Math.min(parseInt(it.FORCE_COLOR,10),3));function It(Y){return Y===0?!1:{level:Y,hasBasic:!0,has256:Y>=2,has16m:Y>=3}}function Dt(Y,C){if(mt===0)return 0;if(ft("color=16m")||ft("color=full")||ft("color=truecolor"))return 3;if(ft("color=256"))return 2;if(Y&&!C&&mt===void 0)return 0;let J=mt||0;if(it.TERM==="dumb")return J;if(process.platform==="win32"){let _=Ge.release().split(".");return Number(_[0])>=10&&Number(_[2])>=10586?Number(_[2])>=14931?3:2:1}if("CI"in it)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some(_=>_ in it)||it.CI_NAME==="codeship"?1:J;if("TEAMCITY_VERSION"in it)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(it.TEAMCITY_VERSION)?1:0;if(it.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in it){let _=parseInt((it.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(it.TERM_PROGRAM){case"iTerm.app":return _>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(it.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(it.TERM)||"COLORTERM"in it?1:J}function Be(Y){let C=Dt(Y,Y&&Y.isTTY);return It(C)}Zt.exports={supportsColor:Be,stdout:It(Dt(!0,Jt.isatty(1))),stderr:It(Dt(!0,Jt.isatty(2)))}});export{We as a,Fe as b,Ue as c};
@@ -4,4 +4,4 @@ import { dirname as __pathDirname } from 'node:path';
4
4
  const require = __createRequire(import.meta.url);
5
5
  var __filename = __fileURLToPath(import.meta.url);
6
6
  var __dirname = __pathDirname(__filename);
7
- import{a}from"./UTZVN6YA.js";import"./VM6OOWSF.js";import"./MGMNYFOR.js";import"./WZXA5XPB.js";import"./UVKEIQXW.js";import"./NEWT5A6S.js";import"./LD5MEXEL.js";import"./UW4UC7ZI.js";import"./RFWIIJFG.js";export{a as mockGenerator};
7
+ import{a}from"./IRZBI5PN.js";import"./NV7DJMMF.js";import"./MU74CSJJ.js";import"./WZXA5XPB.js";import"./ZOVYQ36P.js";import"./NEWT5A6S.js";import"./LD5MEXEL.js";import"./UW4UC7ZI.js";import"./RFWIIJFG.js";export{a as mockGenerator};