@famibee/skynovel 1.28.4 → 1.29.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (129) hide show
  1. package/README.md +4 -6
  2. package/{core/lib → dist}/app.d.ts +0 -0
  3. package/dist/app.d.ts.map +1 -0
  4. package/dist/app.js +52059 -0
  5. package/dist/app.js.map +1 -0
  6. package/{core/lib → dist}/appMain.d.ts +0 -0
  7. package/dist/appMain.d.ts.map +1 -0
  8. package/dist/appMain.js +16 -0
  9. package/dist/appMain.js.map +1 -0
  10. package/{core/lib → dist}/index.d.ts +0 -0
  11. package/{core/lib → dist}/index.d.ts.map +0 -0
  12. package/{core/lib → dist}/preload.d.ts +2 -7
  13. package/dist/preload.d.ts.map +1 -0
  14. package/dist/preload.js +2 -0
  15. package/dist/preload.js.map +1 -0
  16. package/{core/lib → dist}/sn/AnalyzeTagArg.d.ts +0 -0
  17. package/dist/sn/AnalyzeTagArg.d.ts.map +1 -0
  18. package/{core/lib → dist}/sn/Areas.d.ts +0 -0
  19. package/dist/sn/Areas.d.ts.map +1 -0
  20. package/{core/lib → dist}/sn/Button.d.ts +0 -0
  21. package/dist/sn/Button.d.ts.map +1 -0
  22. package/{core/lib → dist}/sn/CallStack.d.ts +0 -0
  23. package/dist/sn/CallStack.d.ts.map +1 -0
  24. package/{core/lib → dist}/sn/CmnInterface.d.ts +0 -0
  25. package/dist/sn/CmnInterface.d.ts.map +1 -0
  26. package/{core/lib → dist}/sn/CmnLib.d.ts +0 -0
  27. package/dist/sn/CmnLib.d.ts.map +1 -0
  28. package/{core/lib → dist}/sn/CmnTween.d.ts +0 -0
  29. package/dist/sn/CmnTween.d.ts.map +1 -0
  30. package/{core/lib → dist}/sn/Config.d.ts +2 -2
  31. package/dist/sn/Config.d.ts.map +1 -0
  32. package/{core/lib → dist}/sn/DebugMng.d.ts +0 -0
  33. package/dist/sn/DebugMng.d.ts.map +1 -0
  34. package/{core/lib → dist}/sn/DesignCast.d.ts +0 -0
  35. package/dist/sn/DesignCast.d.ts.map +1 -0
  36. package/{core/lib → dist}/sn/EventListenerCtn.d.ts +0 -0
  37. package/dist/sn/EventListenerCtn.d.ts.map +1 -0
  38. package/{core/lib → dist}/sn/EventMng.d.ts +0 -0
  39. package/dist/sn/EventMng.d.ts.map +1 -0
  40. package/{core/lib → dist}/sn/FocusMng.d.ts +0 -0
  41. package/dist/sn/FocusMng.d.ts.map +1 -0
  42. package/{core/lib → dist}/sn/FrameMng.d.ts +0 -0
  43. package/dist/sn/FrameMng.d.ts.map +1 -0
  44. package/{core/lib → dist}/sn/Grammar.d.ts +1 -0
  45. package/dist/sn/Grammar.d.ts.map +1 -0
  46. package/{core/lib → dist}/sn/GrpLayer.d.ts +0 -0
  47. package/dist/sn/GrpLayer.d.ts.map +1 -0
  48. package/{core/lib → dist}/sn/Layer.d.ts +0 -0
  49. package/dist/sn/Layer.d.ts.map +1 -0
  50. package/{core/lib → dist}/sn/LayerMng.d.ts +0 -0
  51. package/dist/sn/LayerMng.d.ts.map +1 -0
  52. package/{core/lib → dist}/sn/Main.d.ts +0 -0
  53. package/dist/sn/Main.d.ts.map +1 -0
  54. package/{core/lib → dist}/sn/Pages.d.ts +0 -0
  55. package/dist/sn/Pages.d.ts.map +1 -0
  56. package/{core/lib → dist}/sn/PropParser.d.ts +0 -0
  57. package/dist/sn/PropParser.d.ts.map +1 -0
  58. package/{core/lib → dist}/sn/RubySpliter.d.ts +0 -0
  59. package/dist/sn/RubySpliter.d.ts.map +1 -0
  60. package/{core/lib → dist}/sn/ScriptIterator.d.ts +0 -0
  61. package/dist/sn/ScriptIterator.d.ts.map +1 -0
  62. package/{core/lib → dist}/sn/SoundMng.d.ts +0 -0
  63. package/dist/sn/SoundMng.d.ts.map +1 -0
  64. package/{core/lib → dist}/sn/SysApp.d.ts +5 -5
  65. package/dist/sn/SysApp.d.ts.map +1 -0
  66. package/{core/lib → dist}/sn/SysBase.d.ts +1 -1
  67. package/dist/sn/SysBase.d.ts.map +1 -0
  68. package/{core/lib → dist}/sn/SysNode.d.ts +0 -0
  69. package/dist/sn/SysNode.d.ts.map +1 -0
  70. package/{core/lib → dist}/sn/SysWeb.d.ts +0 -1
  71. package/dist/sn/SysWeb.d.ts.map +1 -0
  72. package/{core/lib → dist}/sn/TxtLayer.d.ts +0 -0
  73. package/dist/sn/TxtLayer.d.ts.map +1 -0
  74. package/{core/lib → dist}/sn/TxtStage.d.ts +0 -0
  75. package/dist/sn/TxtStage.d.ts.map +1 -0
  76. package/{core/lib → dist}/sn/Variable.d.ts +0 -0
  77. package/dist/sn/Variable.d.ts.map +1 -0
  78. package/{core/lib → dist}/web.d.ts +0 -0
  79. package/dist/web.d.ts.map +1 -0
  80. package/dist/web.js +52771 -0
  81. package/dist/web.js.map +1 -0
  82. package/package.json +34 -31
  83. package/.github/workflows/codeql-analysis.yml +0 -66
  84. package/.github/workflows/release.yml +0 -56
  85. package/.travis.yml +0 -14
  86. package/CHANGELOG.md +0 -2611
  87. package/app.js +0 -80864
  88. package/appMain.js +0 -25904
  89. package/core/lib/app.d.ts.map +0 -1
  90. package/core/lib/appMain.d.ts.map +0 -1
  91. package/core/lib/preload.d.ts.map +0 -1
  92. package/core/lib/preload.js +0 -105
  93. package/core/lib/sn/AnalyzeTagArg.d.ts.map +0 -1
  94. package/core/lib/sn/Areas.d.ts.map +0 -1
  95. package/core/lib/sn/Button.d.ts.map +0 -1
  96. package/core/lib/sn/CallStack.d.ts.map +0 -1
  97. package/core/lib/sn/CmnInterface.d.ts.map +0 -1
  98. package/core/lib/sn/CmnLib.d.ts.map +0 -1
  99. package/core/lib/sn/CmnTween.d.ts.map +0 -1
  100. package/core/lib/sn/Config.d.ts.map +0 -1
  101. package/core/lib/sn/DebugMng.d.ts.map +0 -1
  102. package/core/lib/sn/DesignCast.d.ts.map +0 -1
  103. package/core/lib/sn/EventListenerCtn.d.ts.map +0 -1
  104. package/core/lib/sn/EventMng.d.ts.map +0 -1
  105. package/core/lib/sn/FocusMng.d.ts.map +0 -1
  106. package/core/lib/sn/FrameMng.d.ts.map +0 -1
  107. package/core/lib/sn/Grammar.d.ts.map +0 -1
  108. package/core/lib/sn/GrpLayer.d.ts.map +0 -1
  109. package/core/lib/sn/Hyphenation.d.ts +0 -19
  110. package/core/lib/sn/Hyphenation.d.ts.map +0 -1
  111. package/core/lib/sn/Layer.d.ts.map +0 -1
  112. package/core/lib/sn/LayerMng.d.ts.map +0 -1
  113. package/core/lib/sn/Main.d.ts.map +0 -1
  114. package/core/lib/sn/Pages.d.ts.map +0 -1
  115. package/core/lib/sn/PropParser.d.ts.map +0 -1
  116. package/core/lib/sn/RubySpliter.d.ts.map +0 -1
  117. package/core/lib/sn/ScriptIterator.d.ts.map +0 -1
  118. package/core/lib/sn/SoundMng.d.ts.map +0 -1
  119. package/core/lib/sn/SysApp.d.ts.map +0 -1
  120. package/core/lib/sn/SysBase.d.ts.map +0 -1
  121. package/core/lib/sn/SysNode.d.ts.map +0 -1
  122. package/core/lib/sn/SysWeb.d.ts.map +0 -1
  123. package/core/lib/sn/TxtLayer.d.ts.map +0 -1
  124. package/core/lib/sn/TxtStage.d.ts.map +0 -1
  125. package/core/lib/sn/Variable.d.ts.map +0 -1
  126. package/core/lib/web.d.ts.map +0 -1
  127. package/core/webpack.config.js +0 -46
  128. package/tsconfig.json +0 -37
  129. package/web.js +0 -82148
@@ -0,0 +1,16 @@
1
+ "use strict";var ll=Object.defineProperty,dl=Object.defineProperties;var hl=Object.getOwnPropertyDescriptors;var _a=Object.getOwnPropertySymbols;var ml=Object.prototype.hasOwnProperty,pl=Object.prototype.propertyIsEnumerable;var Sa=(e,t,r)=>t in e?ll(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Q=(e,t)=>{for(var r in t||(t={}))ml.call(t,r)&&Sa(e,r,t[r]);if(_a)for(var r of _a(t))pl.call(t,r)&&Sa(e,r,t[r]);return e},vt=(e,t)=>dl(e,hl(t));var ds=(e,t,r)=>{if(!t.has(e))throw TypeError("Cannot "+r)};var oe=(e,t,r)=>(ds(e,t,"read from private field"),r?r.call(e):t.get(e)),ke=(e,t,r)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,r)},Be=(e,t,r,n)=>(ds(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r);var Ur=(e,t,r)=>(ds(e,t,"access private method"),r);Object.defineProperty(exports,"__esModule",{value:!0});exports[Symbol.toStringTag]="Module";var ce=require("electron"),yl=require("fs"),vl=require("constants"),El=require("stream"),gl=require("util"),$l=require("assert"),_l=require("path"),Sl=require("crypto"),wl=require("events"),Nl=require("os"),Il=require("zlib");function Dt(e){return e&&typeof e=="object"&&"default"in e?e:{default:e}}var Ol=Dt(ce),an=Dt(yl),Tl=Dt(vl),Dl=Dt(El),qi=Dt(gl),Hs=Dt($l),Ie=Dt(_l),Jc=Dt(Sl),Rl=Dt(wl),Cl=Dt(Nl),Yc=Dt(Il),ir=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{},Cr={},rt={};rt.fromCallback=function(e){return Object.defineProperty(function(...t){if(typeof t[t.length-1]=="function")e.apply(this,t);else return new Promise((r,n)=>{e.call(this,...t,(i,s)=>i!=null?n(i):r(s))})},"name",{value:e.name})};rt.fromPromise=function(e){return Object.defineProperty(function(...t){const r=t[t.length-1];if(typeof r!="function")return e.apply(this,t);e.apply(this,t.slice(0,-1)).then(n=>r(null,n),r)},"name",{value:e.name})};var Jt=Tl.default,Pl=process.cwd,gi=null,Al=process.platform;process.cwd=function(){return gi||(gi=Pl.call(process)),gi};try{process.cwd()}catch{}if(typeof process.chdir=="function"){var wa=process.chdir;process.chdir=function(e){gi=null,wa.call(process,e)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,wa)}var bl=Ll;function Ll(e){Jt.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&t(e),e.lutimes||r(e),e.chown=s(e.chown),e.fchown=s(e.fchown),e.lchown=s(e.lchown),e.chmod=n(e.chmod),e.fchmod=n(e.fchmod),e.lchmod=n(e.lchmod),e.chownSync=o(e.chownSync),e.fchownSync=o(e.fchownSync),e.lchownSync=o(e.lchownSync),e.chmodSync=i(e.chmodSync),e.fchmodSync=i(e.fchmodSync),e.lchmodSync=i(e.lchmodSync),e.stat=c(e.stat),e.fstat=c(e.fstat),e.lstat=c(e.lstat),e.statSync=u(e.statSync),e.fstatSync=u(e.fstatSync),e.lstatSync=u(e.lstatSync),e.lchmod||(e.lchmod=function(a,l,E){E&&process.nextTick(E)},e.lchmodSync=function(){}),e.lchown||(e.lchown=function(a,l,E,h){h&&process.nextTick(h)},e.lchownSync=function(){}),Al==="win32"&&(e.rename=function(a){return function(l,E,h){var d=Date.now(),y=0;a(l,E,function v(f){if(f&&(f.code==="EACCES"||f.code==="EPERM")&&Date.now()-d<6e4){setTimeout(function(){e.stat(E,function($,w){$&&$.code==="ENOENT"?a(l,E,v):h(f)})},y),y<100&&(y+=10);return}h&&h(f)})}}(e.rename)),e.read=function(a){function l(E,h,d,y,v,f){var $;if(f&&typeof f=="function"){var w=0;$=function(T,k,O){if(T&&T.code==="EAGAIN"&&w<10)return w++,a.call(e,E,h,d,y,v,$);f.apply(this,arguments)}}return a.call(e,E,h,d,y,v,$)}return Object.setPrototypeOf&&Object.setPrototypeOf(l,a),l}(e.read),e.readSync=function(a){return function(l,E,h,d,y){for(var v=0;;)try{return a.call(e,l,E,h,d,y)}catch(f){if(f.code==="EAGAIN"&&v<10){v++;continue}throw f}}}(e.readSync);function t(a){a.lchmod=function(l,E,h){a.open(l,Jt.O_WRONLY|Jt.O_SYMLINK,E,function(d,y){if(d){h&&h(d);return}a.fchmod(y,E,function(v){a.close(y,function(f){h&&h(v||f)})})})},a.lchmodSync=function(l,E){var h=a.openSync(l,Jt.O_WRONLY|Jt.O_SYMLINK,E),d=!0,y;try{y=a.fchmodSync(h,E),d=!1}finally{if(d)try{a.closeSync(h)}catch{}else a.closeSync(h)}return y}}function r(a){Jt.hasOwnProperty("O_SYMLINK")?(a.lutimes=function(l,E,h,d){a.open(l,Jt.O_SYMLINK,function(y,v){if(y){d&&d(y);return}a.futimes(v,E,h,function(f){a.close(v,function($){d&&d(f||$)})})})},a.lutimesSync=function(l,E,h){var d=a.openSync(l,Jt.O_SYMLINK),y,v=!0;try{y=a.futimesSync(d,E,h),v=!1}finally{if(v)try{a.closeSync(d)}catch{}else a.closeSync(d)}return y}):(a.lutimes=function(l,E,h,d){d&&process.nextTick(d)},a.lutimesSync=function(){})}function n(a){return a&&function(l,E,h){return a.call(e,l,E,function(d){m(d)&&(d=null),h&&h.apply(this,arguments)})}}function i(a){return a&&function(l,E){try{return a.call(e,l,E)}catch(h){if(!m(h))throw h}}}function s(a){return a&&function(l,E,h,d){return a.call(e,l,E,h,function(y){m(y)&&(y=null),d&&d.apply(this,arguments)})}}function o(a){return a&&function(l,E,h){try{return a.call(e,l,E,h)}catch(d){if(!m(d))throw d}}}function c(a){return a&&function(l,E,h){typeof E=="function"&&(h=E,E=null);function d(y,v){v&&(v.uid<0&&(v.uid+=4294967296),v.gid<0&&(v.gid+=4294967296)),h&&h.apply(this,arguments)}return E?a.call(e,l,E,d):a.call(e,l,d)}}function u(a){return a&&function(l,E){var h=E?a.call(e,l,E):a.call(e,l);return h&&(h.uid<0&&(h.uid+=4294967296),h.gid<0&&(h.gid+=4294967296)),h}}function m(a){if(!a||a.code==="ENOSYS")return!0;var l=!process.getuid||process.getuid()!==0;return!!(l&&(a.code==="EINVAL"||a.code==="EPERM"))}}var Na=Dl.default.Stream,Fl=jl;function jl(e){return{ReadStream:t,WriteStream:r};function t(n,i){if(!(this instanceof t))return new t(n,i);Na.call(this);var s=this;this.path=n,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=64*1024,i=i||{};for(var o=Object.keys(i),c=0,u=o.length;c<u;c++){var m=o[c];this[m]=i[m]}if(this.encoding&&this.setEncoding(this.encoding),this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(this.fd!==null){process.nextTick(function(){s._read()});return}e.open(this.path,this.flags,this.mode,function(a,l){if(a){s.emit("error",a),s.readable=!1;return}s.fd=l,s.emit("open",l),s._read()})}function r(n,i){if(!(this instanceof r))return new r(n,i);Na.call(this),this.path=n,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,i=i||{};for(var s=Object.keys(i),o=0,c=s.length;o<c;o++){var u=s[o];this[u]=i[u]}if(this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.start<0)throw new Error("start must be >= zero");this.pos=this.start}this.busy=!1,this._queue=[],this.fd===null&&(this._open=e.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}var Ml=Ul,kl=Object.getPrototypeOf||function(e){return e.__proto__};function Ul(e){if(e===null||typeof e!="object")return e;if(e instanceof Object)var t={__proto__:kl(e)};else var t=Object.create(null);return Object.getOwnPropertyNames(e).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}),t}var be=an.default,zl=bl,xl=Fl,Vl=Ml,si=qi.default,qe,Ri;typeof Symbol=="function"&&typeof Symbol.for=="function"?(qe=Symbol.for("graceful-fs.queue"),Ri=Symbol.for("graceful-fs.previous")):(qe="___graceful-fs.queue",Ri="___graceful-fs.previous");function ql(){}function Qc(e,t){Object.defineProperty(e,qe,{get:function(){return t}})}var Or=ql;si.debuglog?Or=si.debuglog("gfs4"):/\bgfs4\b/i.test("")&&(Or=function(){var e=si.format.apply(si,arguments);e="GFS4: "+e.split(/\n/).join(`
2
+ GFS4: `),console.error(e)});if(!be[qe]){var Gl=ir[qe]||[];Qc(be,Gl),be.close=function(e){function t(r,n){return e.call(be,r,function(i){i||Ia(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(t,Ri,{value:e}),t}(be.close),be.closeSync=function(e){function t(r){e.apply(be,arguments),Ia()}return Object.defineProperty(t,Ri,{value:e}),t}(be.closeSync),/\bgfs4\b/i.test("")&&process.on("exit",function(){Or(be[qe]),Hs.default.equal(be[qe].length,0)})}ir[qe]||Qc(ir,be[qe]);var ht=eu(Vl(be));function eu(e){zl(e),e.gracefulify=eu,e.createReadStream=T,e.createWriteStream=k;var t=e.readFile;e.readFile=r;function r(P,L,U){return typeof L=="function"&&(U=L,L=null),B(P,L,U);function B(z,J,Z,le){return t(z,J,function(te){te&&(te.code==="EMFILE"||te.code==="ENFILE")?zr([B,[z,J,Z],te,le||Date.now(),Date.now()]):typeof Z=="function"&&Z.apply(this,arguments)})}}var n=e.writeFile;e.writeFile=i;function i(P,L,U,B){return typeof U=="function"&&(B=U,U=null),z(P,L,U,B);function z(J,Z,le,te,ne){return n(J,Z,le,function(j){j&&(j.code==="EMFILE"||j.code==="ENFILE")?zr([z,[J,Z,le,te],j,ne||Date.now(),Date.now()]):typeof te=="function"&&te.apply(this,arguments)})}}var s=e.appendFile;s&&(e.appendFile=o);function o(P,L,U,B){return typeof U=="function"&&(B=U,U=null),z(P,L,U,B);function z(J,Z,le,te,ne){return s(J,Z,le,function(j){j&&(j.code==="EMFILE"||j.code==="ENFILE")?zr([z,[J,Z,le,te],j,ne||Date.now(),Date.now()]):typeof te=="function"&&te.apply(this,arguments)})}}var c=e.copyFile;c&&(e.copyFile=u);function u(P,L,U,B){return typeof U=="function"&&(B=U,U=0),z(P,L,U,B);function z(J,Z,le,te,ne){return c(J,Z,le,function(j){j&&(j.code==="EMFILE"||j.code==="ENFILE")?zr([z,[J,Z,le,te],j,ne||Date.now(),Date.now()]):typeof te=="function"&&te.apply(this,arguments)})}}var m=e.readdir;e.readdir=a;function a(P,L,U){return typeof L=="function"&&(U=L,L=null),B(P,L,U);function B(z,J,Z,le){return m(z,J,function(te,ne){te&&(te.code==="EMFILE"||te.code==="ENFILE")?zr([B,[z,J,Z],te,le||Date.now(),Date.now()]):(ne&&ne.sort&&ne.sort(),typeof Z=="function"&&Z.call(this,te,ne))})}}if(process.version.substr(0,4)==="v0.8"){var l=xl(e);v=l.ReadStream,$=l.WriteStream}var E=e.ReadStream;E&&(v.prototype=Object.create(E.prototype),v.prototype.open=f);var h=e.WriteStream;h&&($.prototype=Object.create(h.prototype),$.prototype.open=w),Object.defineProperty(e,"ReadStream",{get:function(){return v},set:function(P){v=P},enumerable:!0,configurable:!0}),Object.defineProperty(e,"WriteStream",{get:function(){return $},set:function(P){$=P},enumerable:!0,configurable:!0});var d=v;Object.defineProperty(e,"FileReadStream",{get:function(){return d},set:function(P){d=P},enumerable:!0,configurable:!0});var y=$;Object.defineProperty(e,"FileWriteStream",{get:function(){return y},set:function(P){y=P},enumerable:!0,configurable:!0});function v(P,L){return this instanceof v?(E.apply(this,arguments),this):v.apply(Object.create(v.prototype),arguments)}function f(){var P=this;D(P.path,P.flags,P.mode,function(L,U){L?(P.autoClose&&P.destroy(),P.emit("error",L)):(P.fd=U,P.emit("open",U),P.read())})}function $(P,L){return this instanceof $?(h.apply(this,arguments),this):$.apply(Object.create($.prototype),arguments)}function w(){var P=this;D(P.path,P.flags,P.mode,function(L,U){L?(P.destroy(),P.emit("error",L)):(P.fd=U,P.emit("open",U))})}function T(P,L){return new e.ReadStream(P,L)}function k(P,L){return new e.WriteStream(P,L)}var O=e.open;e.open=D;function D(P,L,U,B){return typeof U=="function"&&(B=U,U=null),z(P,L,U,B);function z(J,Z,le,te,ne){return O(J,Z,le,function(j,x){j&&(j.code==="EMFILE"||j.code==="ENFILE")?zr([z,[J,Z,le,te],j,ne||Date.now(),Date.now()]):typeof te=="function"&&te.apply(this,arguments)})}}return e}function zr(e){Or("ENQUEUE",e[0].name,e[1]),be[qe].push(e),Ks()}var oi;function Ia(){for(var e=Date.now(),t=0;t<be[qe].length;++t)be[qe][t].length>2&&(be[qe][t][3]=e,be[qe][t][4]=e);Ks()}function Ks(){if(clearTimeout(oi),oi=void 0,be[qe].length!==0){var e=be[qe].shift(),t=e[0],r=e[1],n=e[2],i=e[3],s=e[4];if(i===void 0)Or("RETRY",t.name,r),t.apply(null,r);else if(Date.now()-i>=6e4){Or("TIMEOUT",t.name,r);var o=r.pop();typeof o=="function"&&o.call(null,n)}else{var c=Date.now()-s,u=Math.max(s-i,1),m=Math.min(u*1.2,100);c>=m?(Or("RETRY",t.name,r),t.apply(null,r.concat([i]))):be[qe].push(e)}oi===void 0&&(oi=setTimeout(Ks,0))}}(function(e){const t=rt.fromCallback,r=ht,n=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter(i=>typeof r[i]=="function");Object.assign(e,r),n.forEach(i=>{e[i]=t(r[i])}),e.realpath.native=t(r.realpath.native),e.exists=function(i,s){return typeof s=="function"?r.exists(i,s):new Promise(o=>r.exists(i,o))},e.read=function(i,s,o,c,u,m){return typeof m=="function"?r.read(i,s,o,c,u,m):new Promise((a,l)=>{r.read(i,s,o,c,u,(E,h,d)=>{if(E)return l(E);a({bytesRead:h,buffer:d})})})},e.write=function(i,s,...o){return typeof o[o.length-1]=="function"?r.write(i,s,...o):new Promise((c,u)=>{r.write(i,s,...o,(m,a,l)=>{if(m)return u(m);c({bytesWritten:a,buffer:l})})})},typeof r.writev=="function"&&(e.writev=function(i,s,...o){return typeof o[o.length-1]=="function"?r.writev(i,s,...o):new Promise((c,u)=>{r.writev(i,s,...o,(m,a,l)=>{if(m)return u(m);c({bytesWritten:a,buffers:l})})})})})(Cr);var Xs={},tu={};const Bl=Ie.default;tu.checkPath=function(t){if(process.platform==="win32"&&/[<>:"|?*]/.test(t.replace(Bl.parse(t).root,""))){const n=new Error(`Path contains invalid characters: ${t}`);throw n.code="EINVAL",n}};const ru=Cr,{checkPath:nu}=tu,iu=e=>{const t={mode:511};return typeof e=="number"?e:Q(Q({},t),e).mode};Xs.makeDir=async(e,t)=>(nu(e),ru.mkdir(e,{mode:iu(t),recursive:!0}));Xs.makeDirSync=(e,t)=>(nu(e),ru.mkdirSync(e,{mode:iu(t),recursive:!0}));const Hl=rt.fromPromise,{makeDir:Kl,makeDirSync:hs}=Xs,ms=Hl(Kl);var xt={mkdirs:ms,mkdirsSync:hs,mkdirp:ms,mkdirpSync:hs,ensureDir:ms,ensureDirSync:hs};const Xl=rt.fromPromise,su=Cr;function Zl(e){return su.access(e).then(()=>!0).catch(()=>!1)}var Pr={pathExists:Xl(Zl),pathExistsSync:su.existsSync};const Kr=ht;function Wl(e,t,r,n){Kr.open(e,"r+",(i,s)=>{if(i)return n(i);Kr.futimes(s,t,r,o=>{Kr.close(s,c=>{n&&n(o||c)})})})}function Jl(e,t,r){const n=Kr.openSync(e,"r+");return Kr.futimesSync(n,t,r),Kr.closeSync(n)}var ou={utimesMillis:Wl,utimesMillisSync:Jl};const en=Cr,Me=Ie.default,Yl=qi.default;function Ql(e,t,r){const n=r.dereference?i=>en.stat(i,{bigint:!0}):i=>en.lstat(i,{bigint:!0});return Promise.all([n(e),n(t).catch(i=>{if(i.code==="ENOENT")return null;throw i})]).then(([i,s])=>({srcStat:i,destStat:s}))}function ed(e,t,r){let n;const i=r.dereference?o=>en.statSync(o,{bigint:!0}):o=>en.lstatSync(o,{bigint:!0}),s=i(e);try{n=i(t)}catch(o){if(o.code==="ENOENT")return{srcStat:s,destStat:null};throw o}return{srcStat:s,destStat:n}}function td(e,t,r,n,i){Yl.callbackify(Ql)(e,t,n,(s,o)=>{if(s)return i(s);const{srcStat:c,destStat:u}=o;if(u){if(Jn(c,u)){const m=Me.basename(e),a=Me.basename(t);return r==="move"&&m!==a&&m.toLowerCase()===a.toLowerCase()?i(null,{srcStat:c,destStat:u,isChangingCase:!0}):i(new Error("Source and destination must not be the same."))}if(c.isDirectory()&&!u.isDirectory())return i(new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`));if(!c.isDirectory()&&u.isDirectory())return i(new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`))}return c.isDirectory()&&Zs(e,t)?i(new Error(Gi(e,t,r))):i(null,{srcStat:c,destStat:u})})}function rd(e,t,r,n){const{srcStat:i,destStat:s}=ed(e,t,n);if(s){if(Jn(i,s)){const o=Me.basename(e),c=Me.basename(t);if(r==="move"&&o!==c&&o.toLowerCase()===c.toLowerCase())return{srcStat:i,destStat:s,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(i.isDirectory()&&!s.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!i.isDirectory()&&s.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(i.isDirectory()&&Zs(e,t))throw new Error(Gi(e,t,r));return{srcStat:i,destStat:s}}function au(e,t,r,n,i){const s=Me.resolve(Me.dirname(e)),o=Me.resolve(Me.dirname(r));if(o===s||o===Me.parse(o).root)return i();en.stat(o,{bigint:!0},(c,u)=>c?c.code==="ENOENT"?i():i(c):Jn(t,u)?i(new Error(Gi(e,r,n))):au(e,t,o,n,i))}function cu(e,t,r,n){const i=Me.resolve(Me.dirname(e)),s=Me.resolve(Me.dirname(r));if(s===i||s===Me.parse(s).root)return;let o;try{o=en.statSync(s,{bigint:!0})}catch(c){if(c.code==="ENOENT")return;throw c}if(Jn(t,o))throw new Error(Gi(e,r,n));return cu(e,t,s,n)}function Jn(e,t){return t.ino&&t.dev&&t.ino===e.ino&&t.dev===e.dev}function Zs(e,t){const r=Me.resolve(e).split(Me.sep).filter(i=>i),n=Me.resolve(t).split(Me.sep).filter(i=>i);return r.reduce((i,s,o)=>i&&n[o]===s,!0)}function Gi(e,t,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`}var cn={checkPaths:td,checkPathsSync:rd,checkParentPaths:au,checkParentPathsSync:cu,isSrcSubdir:Zs,areIdentical:Jn};const ct=ht,Un=Ie.default,nd=xt.mkdirs,id=Pr.pathExists,sd=ou.utimesMillis,zn=cn;function od(e,t,r,n){typeof r=="function"&&!n?(n=r,r={}):typeof r=="function"&&(r={filter:r}),n=n||function(){},r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;
3
+
4
+ see https://github.com/jprichardson/node-fs-extra/issues/269`),zn.checkPaths(e,t,"copy",r,(i,s)=>{if(i)return n(i);const{srcStat:o,destStat:c}=s;zn.checkParentPaths(e,o,t,"copy",u=>u?n(u):r.filter?uu(Oa,c,e,t,r,n):Oa(c,e,t,r,n))})}function Oa(e,t,r,n,i){const s=Un.dirname(r);id(s,(o,c)=>{if(o)return i(o);if(c)return Ci(e,t,r,n,i);nd(s,u=>u?i(u):Ci(e,t,r,n,i))})}function uu(e,t,r,n,i,s){Promise.resolve(i.filter(r,n)).then(o=>o?e(t,r,n,i,s):s(),o=>s(o))}function ad(e,t,r,n,i){return n.filter?uu(Ci,e,t,r,n,i):Ci(e,t,r,n,i)}function Ci(e,t,r,n,i){(n.dereference?ct.stat:ct.lstat)(t,(o,c)=>o?i(o):c.isDirectory()?md(c,e,t,r,n,i):c.isFile()||c.isCharacterDevice()||c.isBlockDevice()?cd(c,e,t,r,n,i):c.isSymbolicLink()?vd(e,t,r,n,i):c.isSocket()?i(new Error(`Cannot copy a socket file: ${t}`)):c.isFIFO()?i(new Error(`Cannot copy a FIFO pipe: ${t}`)):i(new Error(`Unknown file: ${t}`)))}function cd(e,t,r,n,i,s){return t?ud(e,r,n,i,s):fu(e,r,n,i,s)}function ud(e,t,r,n,i){if(n.overwrite)ct.unlink(r,s=>s?i(s):fu(e,t,r,n,i));else return n.errorOnExist?i(new Error(`'${r}' already exists`)):i()}function fu(e,t,r,n,i){ct.copyFile(t,r,s=>s?i(s):n.preserveTimestamps?fd(e.mode,t,r,i):Bi(r,e.mode,i))}function fd(e,t,r,n){return ld(e)?dd(r,e,i=>i?n(i):Ta(e,t,r,n)):Ta(e,t,r,n)}function ld(e){return(e&128)===0}function dd(e,t,r){return Bi(e,t|128,r)}function Ta(e,t,r,n){hd(t,r,i=>i?n(i):Bi(r,e,n))}function Bi(e,t,r){return ct.chmod(e,t,r)}function hd(e,t,r){ct.stat(e,(n,i)=>n?r(n):sd(t,i.atime,i.mtime,r))}function md(e,t,r,n,i,s){return t?lu(r,n,i,s):pd(e.mode,r,n,i,s)}function pd(e,t,r,n,i){ct.mkdir(r,s=>{if(s)return i(s);lu(t,r,n,o=>o?i(o):Bi(r,e,i))})}function lu(e,t,r,n){ct.readdir(e,(i,s)=>i?n(i):du(s,e,t,r,n))}function du(e,t,r,n,i){const s=e.pop();return s?yd(e,s,t,r,n,i):i()}function yd(e,t,r,n,i,s){const o=Un.join(r,t),c=Un.join(n,t);zn.checkPaths(o,c,"copy",i,(u,m)=>{if(u)return s(u);const{destStat:a}=m;ad(a,o,c,i,l=>l?s(l):du(e,r,n,i,s))})}function vd(e,t,r,n,i){ct.readlink(t,(s,o)=>{if(s)return i(s);if(n.dereference&&(o=Un.resolve(process.cwd(),o)),e)ct.readlink(r,(c,u)=>c?c.code==="EINVAL"||c.code==="UNKNOWN"?ct.symlink(o,r,i):i(c):(n.dereference&&(u=Un.resolve(process.cwd(),u)),zn.isSrcSubdir(o,u)?i(new Error(`Cannot copy '${o}' to a subdirectory of itself, '${u}'.`)):e.isDirectory()&&zn.isSrcSubdir(u,o)?i(new Error(`Cannot overwrite '${u}' with '${o}'.`)):Ed(o,r,i)));else return ct.symlink(o,r,i)})}function Ed(e,t,r){ct.unlink(t,n=>n?r(n):ct.symlink(e,t,r))}var gd=od;const Ze=ht,xn=Ie.default,$d=xt.mkdirsSync,_d=ou.utimesMillisSync,Vn=cn;function Sd(e,t,r){typeof r=="function"&&(r={filter:r}),r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;
5
+
6
+ see https://github.com/jprichardson/node-fs-extra/issues/269`);const{srcStat:n,destStat:i}=Vn.checkPathsSync(e,t,"copy",r);return Vn.checkParentPathsSync(e,n,t,"copy"),wd(i,e,t,r)}function wd(e,t,r,n){if(n.filter&&!n.filter(t,r))return;const i=xn.dirname(r);return Ze.existsSync(i)||$d(i),hu(e,t,r,n)}function Nd(e,t,r,n){if(!(n.filter&&!n.filter(t,r)))return hu(e,t,r,n)}function hu(e,t,r,n){const s=(n.dereference?Ze.statSync:Ze.lstatSync)(t);if(s.isDirectory())return Pd(s,e,t,r,n);if(s.isFile()||s.isCharacterDevice()||s.isBlockDevice())return Id(s,e,t,r,n);if(s.isSymbolicLink())return Ld(e,t,r,n);throw s.isSocket()?new Error(`Cannot copy a socket file: ${t}`):s.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}function Id(e,t,r,n,i){return t?Od(e,r,n,i):mu(e,r,n,i)}function Od(e,t,r,n){if(n.overwrite)return Ze.unlinkSync(r),mu(e,t,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function mu(e,t,r,n){return Ze.copyFileSync(t,r),n.preserveTimestamps&&Td(e.mode,t,r),Ws(r,e.mode)}function Td(e,t,r){return Dd(e)&&Rd(r,e),Cd(t,r)}function Dd(e){return(e&128)===0}function Rd(e,t){return Ws(e,t|128)}function Ws(e,t){return Ze.chmodSync(e,t)}function Cd(e,t){const r=Ze.statSync(e);return _d(t,r.atime,r.mtime)}function Pd(e,t,r,n,i){return t?pu(r,n,i):Ad(e.mode,r,n,i)}function Ad(e,t,r,n){return Ze.mkdirSync(r),pu(t,r,n),Ws(r,e)}function pu(e,t,r){Ze.readdirSync(e).forEach(n=>bd(n,e,t,r))}function bd(e,t,r,n){const i=xn.join(t,e),s=xn.join(r,e),{destStat:o}=Vn.checkPathsSync(i,s,"copy",n);return Nd(o,i,s,n)}function Ld(e,t,r,n){let i=Ze.readlinkSync(t);if(n.dereference&&(i=xn.resolve(process.cwd(),i)),e){let s;try{s=Ze.readlinkSync(r)}catch(o){if(o.code==="EINVAL"||o.code==="UNKNOWN")return Ze.symlinkSync(i,r);throw o}if(n.dereference&&(s=xn.resolve(process.cwd(),s)),Vn.isSrcSubdir(i,s))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${s}'.`);if(Ze.statSync(r).isDirectory()&&Vn.isSrcSubdir(s,i))throw new Error(`Cannot overwrite '${s}' with '${i}'.`);return Fd(i,r)}else return Ze.symlinkSync(i,r)}function Fd(e,t){return Ze.unlinkSync(t),Ze.symlinkSync(e,t)}var jd=Sd;const Md=rt.fromCallback;var Js={copy:Md(gd),copySync:jd};const Da=ht,yu=Ie.default,ye=Hs.default,qn=process.platform==="win32";function vu(e){["unlink","chmod","stat","lstat","rmdir","readdir"].forEach(r=>{e[r]=e[r]||Da[r],r=r+"Sync",e[r]=e[r]||Da[r]}),e.maxBusyTries=e.maxBusyTries||3}function Ys(e,t,r){let n=0;typeof t=="function"&&(r=t,t={}),ye(e,"rimraf: missing path"),ye.strictEqual(typeof e,"string","rimraf: path should be a string"),ye.strictEqual(typeof r,"function","rimraf: callback function required"),ye(t,"rimraf: invalid options argument provided"),ye.strictEqual(typeof t,"object","rimraf: options should be object"),vu(t),Ra(e,t,function i(s){if(s){if((s.code==="EBUSY"||s.code==="ENOTEMPTY"||s.code==="EPERM")&&n<t.maxBusyTries){n++;const o=n*100;return setTimeout(()=>Ra(e,t,i),o)}s.code==="ENOENT"&&(s=null)}r(s)})}function Ra(e,t,r){ye(e),ye(t),ye(typeof r=="function"),t.lstat(e,(n,i)=>{if(n&&n.code==="ENOENT")return r(null);if(n&&n.code==="EPERM"&&qn)return Ca(e,t,n,r);if(i&&i.isDirectory())return $i(e,t,n,r);t.unlink(e,s=>{if(s){if(s.code==="ENOENT")return r(null);if(s.code==="EPERM")return qn?Ca(e,t,s,r):$i(e,t,s,r);if(s.code==="EISDIR")return $i(e,t,s,r)}return r(s)})})}function Ca(e,t,r,n){ye(e),ye(t),ye(typeof n=="function"),t.chmod(e,438,i=>{i?n(i.code==="ENOENT"?null:r):t.stat(e,(s,o)=>{s?n(s.code==="ENOENT"?null:r):o.isDirectory()?$i(e,t,r,n):t.unlink(e,n)})})}function Pa(e,t,r){let n;ye(e),ye(t);try{t.chmodSync(e,438)}catch(i){if(i.code==="ENOENT")return;throw r}try{n=t.statSync(e)}catch(i){if(i.code==="ENOENT")return;throw r}n.isDirectory()?_i(e,t,r):t.unlinkSync(e)}function $i(e,t,r,n){ye(e),ye(t),ye(typeof n=="function"),t.rmdir(e,i=>{i&&(i.code==="ENOTEMPTY"||i.code==="EEXIST"||i.code==="EPERM")?kd(e,t,n):i&&i.code==="ENOTDIR"?n(r):n(i)})}function kd(e,t,r){ye(e),ye(t),ye(typeof r=="function"),t.readdir(e,(n,i)=>{if(n)return r(n);let s=i.length,o;if(s===0)return t.rmdir(e,r);i.forEach(c=>{Ys(yu.join(e,c),t,u=>{if(!o){if(u)return r(o=u);--s===0&&t.rmdir(e,r)}})})})}function Eu(e,t){let r;t=t||{},vu(t),ye(e,"rimraf: missing path"),ye.strictEqual(typeof e,"string","rimraf: path should be a string"),ye(t,"rimraf: missing options"),ye.strictEqual(typeof t,"object","rimraf: options should be object");try{r=t.lstatSync(e)}catch(n){if(n.code==="ENOENT")return;n.code==="EPERM"&&qn&&Pa(e,t,n)}try{r&&r.isDirectory()?_i(e,t,null):t.unlinkSync(e)}catch(n){if(n.code==="ENOENT")return;if(n.code==="EPERM")return qn?Pa(e,t,n):_i(e,t,n);if(n.code!=="EISDIR")throw n;_i(e,t,n)}}function _i(e,t,r){ye(e),ye(t);try{t.rmdirSync(e)}catch(n){if(n.code==="ENOTDIR")throw r;if(n.code==="ENOTEMPTY"||n.code==="EEXIST"||n.code==="EPERM")Ud(e,t);else if(n.code!=="ENOENT")throw n}}function Ud(e,t){if(ye(e),ye(t),t.readdirSync(e).forEach(r=>Eu(yu.join(e,r),t)),qn){const r=Date.now();do try{return t.rmdirSync(e,t)}catch{}while(Date.now()-r<500)}else return t.rmdirSync(e,t)}var zd=Ys;Ys.sync=Eu;const Pi=ht,xd=rt.fromCallback,gu=zd;function Vd(e,t){if(Pi.rm)return Pi.rm(e,{recursive:!0,force:!0},t);gu(e,t)}function qd(e){if(Pi.rmSync)return Pi.rmSync(e,{recursive:!0,force:!0});gu.sync(e)}var Hi={remove:xd(Vd),removeSync:qd};const Gd=rt.fromPromise,$u=Cr,_u=Ie.default,Su=xt,wu=Hi,Aa=Gd(async function(t){let r;try{r=await $u.readdir(t)}catch{return Su.mkdirs(t)}return Promise.all(r.map(n=>wu.remove(_u.join(t,n))))});function ba(e){let t;try{t=$u.readdirSync(e)}catch{return Su.mkdirsSync(e)}t.forEach(r=>{r=_u.join(e,r),wu.removeSync(r)})}var Bd={emptyDirSync:ba,emptydirSync:ba,emptyDir:Aa,emptydir:Aa};const Hd=rt.fromCallback,Nu=Ie.default,sr=ht,Iu=xt;function Kd(e,t){function r(){sr.writeFile(e,"",n=>{if(n)return t(n);t()})}sr.stat(e,(n,i)=>{if(!n&&i.isFile())return t();const s=Nu.dirname(e);sr.stat(s,(o,c)=>{if(o)return o.code==="ENOENT"?Iu.mkdirs(s,u=>{if(u)return t(u);r()}):t(o);c.isDirectory()?r():sr.readdir(s,u=>{if(u)return t(u)})})})}function Xd(e){let t;try{t=sr.statSync(e)}catch{}if(t&&t.isFile())return;const r=Nu.dirname(e);try{sr.statSync(r).isDirectory()||sr.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")Iu.mkdirsSync(r);else throw n}sr.writeFileSync(e,"")}var Zd={createFile:Hd(Kd),createFileSync:Xd};const Wd=rt.fromCallback,Ou=Ie.default,er=ht,Tu=xt,Jd=Pr.pathExists,{areIdentical:Du}=cn;function Yd(e,t,r){function n(i,s){er.link(i,s,o=>{if(o)return r(o);r(null)})}er.lstat(t,(i,s)=>{er.lstat(e,(o,c)=>{if(o)return o.message=o.message.replace("lstat","ensureLink"),r(o);if(s&&Du(c,s))return r(null);const u=Ou.dirname(t);Jd(u,(m,a)=>{if(m)return r(m);if(a)return n(e,t);Tu.mkdirs(u,l=>{if(l)return r(l);n(e,t)})})})})}function Qd(e,t){let r;try{r=er.lstatSync(t)}catch{}try{const s=er.lstatSync(e);if(r&&Du(s,r))return}catch(s){throw s.message=s.message.replace("lstat","ensureLink"),s}const n=Ou.dirname(t);return er.existsSync(n)||Tu.mkdirsSync(n),er.linkSync(e,t)}var eh={createLink:Wd(Yd),createLinkSync:Qd};const or=Ie.default,Rn=ht,th=Pr.pathExists;function rh(e,t,r){if(or.isAbsolute(e))return Rn.lstat(e,n=>n?(n.message=n.message.replace("lstat","ensureSymlink"),r(n)):r(null,{toCwd:e,toDst:e}));{const n=or.dirname(t),i=or.join(n,e);return th(i,(s,o)=>s?r(s):o?r(null,{toCwd:i,toDst:e}):Rn.lstat(e,c=>c?(c.message=c.message.replace("lstat","ensureSymlink"),r(c)):r(null,{toCwd:e,toDst:or.relative(n,e)})))}}function nh(e,t){let r;if(or.isAbsolute(e)){if(r=Rn.existsSync(e),!r)throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}else{const n=or.dirname(t),i=or.join(n,e);if(r=Rn.existsSync(i),r)return{toCwd:i,toDst:e};if(r=Rn.existsSync(e),!r)throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:or.relative(n,e)}}}var ih={symlinkPaths:rh,symlinkPathsSync:nh};const Ru=ht;function sh(e,t,r){if(r=typeof t=="function"?t:r,t=typeof t=="function"?!1:t,t)return r(null,t);Ru.lstat(e,(n,i)=>{if(n)return r(null,"file");t=i&&i.isDirectory()?"dir":"file",r(null,t)})}function oh(e,t){let r;if(t)return t;try{r=Ru.lstatSync(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}var ah={symlinkType:sh,symlinkTypeSync:oh};const ch=rt.fromCallback,Cu=Ie.default,It=Cr,Pu=xt,uh=Pu.mkdirs,fh=Pu.mkdirsSync,Au=ih,lh=Au.symlinkPaths,dh=Au.symlinkPathsSync,bu=ah,hh=bu.symlinkType,mh=bu.symlinkTypeSync,ph=Pr.pathExists,{areIdentical:Lu}=cn;function yh(e,t,r,n){n=typeof r=="function"?r:n,r=typeof r=="function"?!1:r,It.lstat(t,(i,s)=>{!i&&s.isSymbolicLink()?Promise.all([It.stat(e),It.stat(t)]).then(([o,c])=>{if(Lu(o,c))return n(null);La(e,t,r,n)}):La(e,t,r,n)})}function La(e,t,r,n){lh(e,t,(i,s)=>{if(i)return n(i);e=s.toDst,hh(s.toCwd,r,(o,c)=>{if(o)return n(o);const u=Cu.dirname(t);ph(u,(m,a)=>{if(m)return n(m);if(a)return It.symlink(e,t,c,n);uh(u,l=>{if(l)return n(l);It.symlink(e,t,c,n)})})})})}function vh(e,t,r){let n;try{n=It.lstatSync(t)}catch{}if(n&&n.isSymbolicLink()){const c=It.statSync(e),u=It.statSync(t);if(Lu(c,u))return}const i=dh(e,t);e=i.toDst,r=mh(i.toCwd,r);const s=Cu.dirname(t);return It.existsSync(s)||fh(s),It.symlinkSync(e,t,r)}var Eh={createSymlink:ch(yh),createSymlinkSync:vh};const{createFile:Fa,createFileSync:ja}=Zd,{createLink:Ma,createLinkSync:ka}=eh,{createSymlink:Ua,createSymlinkSync:za}=Eh;var gh={createFile:Fa,createFileSync:ja,ensureFile:Fa,ensureFileSync:ja,createLink:Ma,createLinkSync:ka,ensureLink:Ma,ensureLinkSync:ka,createSymlink:Ua,createSymlinkSync:za,ensureSymlink:Ua,ensureSymlinkSync:za};function $h(e,{EOL:t=`
7
+ `,finalEOL:r=!0,replacer:n=null,spaces:i}={}){const s=r?t:"";return JSON.stringify(e,n,i).replace(/\n/g,t)+s}function _h(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}var Qs={stringify:$h,stripBom:_h};let tn;try{tn=require("graceful-fs")}catch{tn=an.default}const Ki=rt,{stringify:Fu,stripBom:ju}=Qs;async function Sh(e,t={}){typeof t=="string"&&(t={encoding:t});const r=t.fs||tn,n="throws"in t?t.throws:!0;let i=await Ki.fromCallback(r.readFile)(e,t);i=ju(i);let s;try{s=JSON.parse(i,t?t.reviver:null)}catch(o){if(n)throw o.message=`${e}: ${o.message}`,o;return null}return s}const wh=Ki.fromPromise(Sh);function Nh(e,t={}){typeof t=="string"&&(t={encoding:t});const r=t.fs||tn,n="throws"in t?t.throws:!0;try{let i=r.readFileSync(e,t);return i=ju(i),JSON.parse(i,t.reviver)}catch(i){if(n)throw i.message=`${e}: ${i.message}`,i;return null}}async function Ih(e,t,r={}){const n=r.fs||tn,i=Fu(t,r);await Ki.fromCallback(n.writeFile)(e,i,r)}const Oh=Ki.fromPromise(Ih);function Th(e,t,r={}){const n=r.fs||tn,i=Fu(t,r);return n.writeFileSync(e,i,r)}const Dh={readFile:wh,readFileSync:Nh,writeFile:Oh,writeFileSync:Th};var Rh=Dh;const ai=Rh;var Ch={readJson:ai.readFile,readJsonSync:ai.readFileSync,writeJson:ai.writeFile,writeJsonSync:ai.writeFileSync};const Ph=rt.fromCallback,Cn=ht,Mu=Ie.default,ku=xt,Ah=Pr.pathExists;function bh(e,t,r,n){typeof r=="function"&&(n=r,r="utf8");const i=Mu.dirname(e);Ah(i,(s,o)=>{if(s)return n(s);if(o)return Cn.writeFile(e,t,r,n);ku.mkdirs(i,c=>{if(c)return n(c);Cn.writeFile(e,t,r,n)})})}function Lh(e,...t){const r=Mu.dirname(e);if(Cn.existsSync(r))return Cn.writeFileSync(e,...t);ku.mkdirsSync(r),Cn.writeFileSync(e,...t)}var eo={outputFile:Ph(bh),outputFileSync:Lh};const{stringify:Fh}=Qs,{outputFile:jh}=eo;async function Mh(e,t,r={}){const n=Fh(t,r);await jh(e,n,r)}var kh=Mh;const{stringify:Uh}=Qs,{outputFileSync:zh}=eo;function xh(e,t,r){const n=Uh(t,r);zh(e,n,r)}var Vh=xh;const qh=rt.fromPromise,tt=Ch;tt.outputJson=qh(kh);tt.outputJsonSync=Vh;tt.outputJSON=tt.outputJson;tt.outputJSONSync=tt.outputJsonSync;tt.writeJSON=tt.writeJson;tt.writeJSONSync=tt.writeJsonSync;tt.readJSON=tt.readJson;tt.readJSONSync=tt.readJsonSync;var Gh=tt;const Bh=ht,As=Ie.default,Hh=Js.copy,Uu=Hi.remove,Kh=xt.mkdirp,Xh=Pr.pathExists,xa=cn;function Zh(e,t,r,n){typeof r=="function"&&(n=r,r={});const i=r.overwrite||r.clobber||!1;xa.checkPaths(e,t,"move",r,(s,o)=>{if(s)return n(s);const{srcStat:c,isChangingCase:u=!1}=o;xa.checkParentPaths(e,c,t,"move",m=>{if(m)return n(m);if(Wh(t))return Va(e,t,i,u,n);Kh(As.dirname(t),a=>a?n(a):Va(e,t,i,u,n))})})}function Wh(e){const t=As.dirname(e);return As.parse(t).root===t}function Va(e,t,r,n,i){if(n)return ps(e,t,r,i);if(r)return Uu(t,s=>s?i(s):ps(e,t,r,i));Xh(t,(s,o)=>s?i(s):o?i(new Error("dest already exists.")):ps(e,t,r,i))}function ps(e,t,r,n){Bh.rename(e,t,i=>i?i.code!=="EXDEV"?n(i):Jh(e,t,r,n):n())}function Jh(e,t,r,n){Hh(e,t,{overwrite:r,errorOnExist:!0},s=>s?n(s):Uu(e,n))}var Yh=Zh;const zu=ht,bs=Ie.default,Qh=Js.copySync,xu=Hi.removeSync,em=xt.mkdirpSync,qa=cn;function tm(e,t,r){r=r||{};const n=r.overwrite||r.clobber||!1,{srcStat:i,isChangingCase:s=!1}=qa.checkPathsSync(e,t,"move",r);return qa.checkParentPathsSync(e,i,t,"move"),rm(t)||em(bs.dirname(t)),nm(e,t,n,s)}function rm(e){const t=bs.dirname(e);return bs.parse(t).root===t}function nm(e,t,r,n){if(n)return ys(e,t,r);if(r)return xu(t),ys(e,t,r);if(zu.existsSync(t))throw new Error("dest already exists.");return ys(e,t,r)}function ys(e,t,r){try{zu.renameSync(e,t)}catch(n){if(n.code!=="EXDEV")throw n;return im(e,t,r)}}function im(e,t,r){return Qh(e,t,{overwrite:r,errorOnExist:!0}),xu(e)}var sm=tm;const om=rt.fromCallback;var am={move:om(Yh),moveSync:sm},Et=Q(Q(Q(Q(Q(Q(Q(Q(Q(Q({},Cr),Js),Bd),gh),Gh),xt),am),eo),Pr),Hi),Ls={exports:{}},cm=e=>{const t=typeof e;return e!==null&&(t==="object"||t==="function")};const yr=cm,um=new Set(["__proto__","prototype","constructor"]),fm=e=>!e.some(t=>um.has(t));function ci(e){const t=e.split("."),r=[];for(let n=0;n<t.length;n++){let i=t[n];for(;i[i.length-1]==="\\"&&t[n+1]!==void 0;)i=i.slice(0,-1)+".",i+=t[++n];r.push(i)}return fm(r)?r:[]}var lm={get(e,t,r){if(!yr(e)||typeof t!="string")return r===void 0?e:r;const n=ci(t);if(n.length!==0){for(let i=0;i<n.length;i++)if(e=e[n[i]],e==null){if(i!==n.length-1)return r;break}return e===void 0?r:e}},set(e,t,r){if(!yr(e)||typeof t!="string")return e;const n=e,i=ci(t);for(let s=0;s<i.length;s++){const o=i[s];yr(e[o])||(e[o]={}),s===i.length-1&&(e[o]=r),e=e[o]}return n},delete(e,t){if(!yr(e)||typeof t!="string")return!1;const r=ci(t);for(let n=0;n<r.length;n++){const i=r[n];if(n===r.length-1)return delete e[i],!0;if(e=e[i],!yr(e))return!1}},has(e,t){if(!yr(e)||typeof t!="string")return!1;const r=ci(t);if(r.length===0)return!1;for(let n=0;n<r.length;n++)if(yr(e)){if(!(r[n]in e))return!1;e=e[r[n]]}else return!1;return!0}},to={exports:{}},ro={exports:{}},no={exports:{}},io={exports:{}};const Vu=an.default;io.exports=e=>new Promise(t=>{Vu.access(e,r=>{t(!r)})});io.exports.sync=e=>{try{return Vu.accessSync(e),!0}catch{return!1}};var so={exports:{}},oo={exports:{}};const qu=(e,...t)=>new Promise(r=>{r(e(...t))});oo.exports=qu;oo.exports.default=qu;const dm=oo.exports,Gu=e=>{if(!((Number.isInteger(e)||e===1/0)&&e>0))return Promise.reject(new TypeError("Expected `concurrency` to be a number from 1 and up"));const t=[];let r=0;const n=()=>{r--,t.length>0&&t.shift()()},i=(c,u,...m)=>{r++;const a=dm(c,...m);u(a),a.then(n,n)},s=(c,u,...m)=>{r<e?i(c,u,...m):t.push(i.bind(null,c,u,...m))},o=(c,...u)=>new Promise(m=>s(c,m,...u));return Object.defineProperties(o,{activeCount:{get:()=>r},pendingCount:{get:()=>t.length},clearQueue:{value:()=>{t.length=0}}}),o};so.exports=Gu;so.exports.default=Gu;const Ga=so.exports;class Bu extends Error{constructor(t){super();this.value=t}}const hm=(e,t)=>Promise.resolve(e).then(t),mm=e=>Promise.all(e).then(t=>t[1]===!0&&Promise.reject(new Bu(t[0])));var pm=(e,t,r)=>{r=Object.assign({concurrency:1/0,preserveOrder:!0},r);const n=Ga(r.concurrency),i=[...e].map(o=>[o,n(hm,o,t)]),s=Ga(r.preserveOrder?1:1/0);return Promise.all(i.map(o=>s(mm,o))).then(()=>{}).catch(o=>o instanceof Bu?o.value:Promise.reject(o))};const Hu=Ie.default,Ku=io.exports,ym=pm;no.exports=(e,t)=>(t=Object.assign({cwd:process.cwd()},t),ym(e,r=>Ku(Hu.resolve(t.cwd,r)),t));no.exports.sync=(e,t)=>{t=Object.assign({cwd:process.cwd()},t);for(const r of e)if(Ku.sync(Hu.resolve(t.cwd,r)))return r};const ar=Ie.default,Xu=no.exports;ro.exports=(e,t={})=>{const r=ar.resolve(t.cwd||""),{root:n}=ar.parse(r),i=[].concat(e);return new Promise(s=>{(function o(c){Xu(i,{cwd:c}).then(u=>{u?s(ar.join(c,u)):c===n?s(null):o(ar.dirname(c))})})(r)})};ro.exports.sync=(e,t={})=>{let r=ar.resolve(t.cwd||"");const{root:n}=ar.parse(r),i=[].concat(e);for(;;){const s=Xu.sync(i,{cwd:r});if(s)return ar.join(r,s);if(r===n)return null;r=ar.dirname(r)}};const Zu=ro.exports;to.exports=async({cwd:e}={})=>Zu("package.json",{cwd:e});to.exports.sync=({cwd:e}={})=>Zu.sync("package.json",{cwd:e});var ao={exports:{}};const Ne=Ie.default,Wu=Cl.default,tr=Wu.homedir(),co=Wu.tmpdir(),{env:Hr}=process,vm=e=>{const t=Ne.join(tr,"Library");return{data:Ne.join(t,"Application Support",e),config:Ne.join(t,"Preferences",e),cache:Ne.join(t,"Caches",e),log:Ne.join(t,"Logs",e),temp:Ne.join(co,e)}},Em=e=>{const t=Hr.APPDATA||Ne.join(tr,"AppData","Roaming"),r=Hr.LOCALAPPDATA||Ne.join(tr,"AppData","Local");return{data:Ne.join(r,e,"Data"),config:Ne.join(t,e,"Config"),cache:Ne.join(r,e,"Cache"),log:Ne.join(r,e,"Log"),temp:Ne.join(co,e)}},gm=e=>{const t=Ne.basename(tr);return{data:Ne.join(Hr.XDG_DATA_HOME||Ne.join(tr,".local","share"),e),config:Ne.join(Hr.XDG_CONFIG_HOME||Ne.join(tr,".config"),e),cache:Ne.join(Hr.XDG_CACHE_HOME||Ne.join(tr,".cache"),e),log:Ne.join(Hr.XDG_STATE_HOME||Ne.join(tr,".local","state"),e),temp:Ne.join(co,t,e)}},Ju=(e,t)=>{if(typeof e!="string")throw new TypeError(`Expected string, got ${typeof e}`);return t=Object.assign({suffix:"nodejs"},t),t.suffix&&(e+=`-${t.suffix}`),process.platform==="darwin"?vm(e):process.platform==="win32"?Em(e):gm(e)};ao.exports=Ju;ao.exports.default=Ju;var Ut={},me={};Object.defineProperty(me,"__esModule",{value:!0});me.NOOP=me.LIMIT_FILES_DESCRIPTORS=me.LIMIT_BASENAME_LENGTH=me.IS_USER_ROOT=me.IS_POSIX=me.DEFAULT_TIMEOUT_SYNC=me.DEFAULT_TIMEOUT_ASYNC=me.DEFAULT_WRITE_OPTIONS=me.DEFAULT_READ_OPTIONS=me.DEFAULT_FOLDER_MODE=me.DEFAULT_FILE_MODE=me.DEFAULT_ENCODING=void 0;const $m="utf8";me.DEFAULT_ENCODING=$m;const _m=438;me.DEFAULT_FILE_MODE=_m;const Sm=511;me.DEFAULT_FOLDER_MODE=Sm;const wm={};me.DEFAULT_READ_OPTIONS=wm;const Nm={};me.DEFAULT_WRITE_OPTIONS=Nm;const Im=5e3;me.DEFAULT_TIMEOUT_ASYNC=Im;const Om=100;me.DEFAULT_TIMEOUT_SYNC=Om;const Tm=!!process.getuid;me.IS_POSIX=Tm;const Dm=process.getuid?!process.getuid():!1;me.IS_USER_ROOT=Dm;const Rm=128;me.LIMIT_BASENAME_LENGTH=Rm;const Cm=1e4;me.LIMIT_FILES_DESCRIPTORS=Cm;const Pm=()=>{};me.NOOP=Pm;var Xi={},rn={};Object.defineProperty(rn,"__esModule",{value:!0});rn.attemptifySync=rn.attemptifyAsync=void 0;const Yu=me,Am=(e,t=Yu.NOOP)=>function(){return e.apply(void 0,arguments).catch(t)};rn.attemptifyAsync=Am;const bm=(e,t=Yu.NOOP)=>function(){try{return e.apply(void 0,arguments)}catch(r){return t(r)}};rn.attemptifySync=bm;var uo={};Object.defineProperty(uo,"__esModule",{value:!0});const Lm=me,Qu={isChangeErrorOk:e=>{const{code:t}=e;return t==="ENOSYS"||!Lm.IS_USER_ROOT&&(t==="EINVAL"||t==="EPERM")},isRetriableError:e=>{const{code:t}=e;return t==="EMFILE"||t==="ENFILE"||t==="EAGAIN"||t==="EBUSY"||t==="EACCESS"||t==="EACCS"||t==="EPERM"},onChangeError:e=>{if(!Qu.isChangeErrorOk(e))throw e}};uo.default=Qu;var nn={},fo={};Object.defineProperty(fo,"__esModule",{value:!0});const Fm=me,Ee={interval:25,intervalId:void 0,limit:Fm.LIMIT_FILES_DESCRIPTORS,queueActive:new Set,queueWaiting:new Set,init:()=>{Ee.intervalId||(Ee.intervalId=setInterval(Ee.tick,Ee.interval))},reset:()=>{!Ee.intervalId||(clearInterval(Ee.intervalId),delete Ee.intervalId)},add:e=>{Ee.queueWaiting.add(e),Ee.queueActive.size<Ee.limit/2?Ee.tick():Ee.init()},remove:e=>{Ee.queueWaiting.delete(e),Ee.queueActive.delete(e)},schedule:()=>new Promise(e=>{const t=()=>Ee.remove(r),r=()=>e(t);Ee.add(r)}),tick:()=>{if(!(Ee.queueActive.size>=Ee.limit)){if(!Ee.queueWaiting.size)return Ee.reset();for(const e of Ee.queueWaiting){if(Ee.queueActive.size>=Ee.limit)break;Ee.queueWaiting.delete(e),Ee.queueActive.add(e),e()}}}};fo.default=Ee;Object.defineProperty(nn,"__esModule",{value:!0});nn.retryifySync=nn.retryifyAsync=void 0;const jm=fo,Mm=(e,t)=>function(r){return function n(){return jm.default.schedule().then(i=>e.apply(void 0,arguments).then(s=>(i(),s),s=>{if(i(),Date.now()>=r)throw s;if(t(s)){const o=Math.round(100+400*Math.random());return new Promise(u=>setTimeout(u,o)).then(()=>n.apply(void 0,arguments))}throw s}))}};nn.retryifyAsync=Mm;const km=(e,t)=>function(r){return function n(){try{return e.apply(void 0,arguments)}catch(i){if(Date.now()>r)throw i;if(t(i))return n.apply(void 0,arguments);throw i}}};nn.retryifySync=km;Object.defineProperty(Xi,"__esModule",{value:!0});const pe=an.default,We=qi.default,Je=rn,Fe=uo,st=nn,Um={chmodAttempt:Je.attemptifyAsync(We.promisify(pe.chmod),Fe.default.onChangeError),chownAttempt:Je.attemptifyAsync(We.promisify(pe.chown),Fe.default.onChangeError),closeAttempt:Je.attemptifyAsync(We.promisify(pe.close)),fsyncAttempt:Je.attemptifyAsync(We.promisify(pe.fsync)),mkdirAttempt:Je.attemptifyAsync(We.promisify(pe.mkdir)),realpathAttempt:Je.attemptifyAsync(We.promisify(pe.realpath)),statAttempt:Je.attemptifyAsync(We.promisify(pe.stat)),unlinkAttempt:Je.attemptifyAsync(We.promisify(pe.unlink)),closeRetry:st.retryifyAsync(We.promisify(pe.close),Fe.default.isRetriableError),fsyncRetry:st.retryifyAsync(We.promisify(pe.fsync),Fe.default.isRetriableError),openRetry:st.retryifyAsync(We.promisify(pe.open),Fe.default.isRetriableError),readFileRetry:st.retryifyAsync(We.promisify(pe.readFile),Fe.default.isRetriableError),renameRetry:st.retryifyAsync(We.promisify(pe.rename),Fe.default.isRetriableError),statRetry:st.retryifyAsync(We.promisify(pe.stat),Fe.default.isRetriableError),writeRetry:st.retryifyAsync(We.promisify(pe.write),Fe.default.isRetriableError),chmodSyncAttempt:Je.attemptifySync(pe.chmodSync,Fe.default.onChangeError),chownSyncAttempt:Je.attemptifySync(pe.chownSync,Fe.default.onChangeError),closeSyncAttempt:Je.attemptifySync(pe.closeSync),mkdirSyncAttempt:Je.attemptifySync(pe.mkdirSync),realpathSyncAttempt:Je.attemptifySync(pe.realpathSync),statSyncAttempt:Je.attemptifySync(pe.statSync),unlinkSyncAttempt:Je.attemptifySync(pe.unlinkSync),closeSyncRetry:st.retryifySync(pe.closeSync,Fe.default.isRetriableError),fsyncSyncRetry:st.retryifySync(pe.fsyncSync,Fe.default.isRetriableError),openSyncRetry:st.retryifySync(pe.openSync,Fe.default.isRetriableError),readFileSyncRetry:st.retryifySync(pe.readFileSync,Fe.default.isRetriableError),renameSyncRetry:st.retryifySync(pe.renameSync,Fe.default.isRetriableError),statSyncRetry:st.retryifySync(pe.statSync,Fe.default.isRetriableError),writeSyncRetry:st.retryifySync(pe.writeSync,Fe.default.isRetriableError)};Xi.default=Um;var lo={};Object.defineProperty(lo,"__esModule",{value:!0});const zm={isFunction:e=>typeof e=="function",isString:e=>typeof e=="string",isUndefined:e=>typeof e=="undefined"};lo.default=zm;var ho={};Object.defineProperty(ho,"__esModule",{value:!0});const ui={},Fs={next:e=>{const t=ui[e];if(!t)return;t.shift();const r=t[0];r?r(()=>Fs.next(e)):delete ui[e]},schedule:e=>new Promise(t=>{let r=ui[e];r||(r=ui[e]=[]),r.push(t),!(r.length>1)&&t(()=>Fs.next(e))})};ho.default=Fs;var mo={};Object.defineProperty(mo,"__esModule",{value:!0});const xm=Ie.default,Ba=me,Ha=Xi,lt={store:{},create:e=>{const t=`000000${Math.floor(Math.random()*16777215).toString(16)}`.slice(-6),r=Date.now().toString().slice(-10),n="tmp-",i=`.${n}${r}${t}`;return`${e}${i}`},get:(e,t,r=!0)=>{const n=lt.truncate(t(e));return n in lt.store?lt.get(e,t,r):(lt.store[n]=r,[n,()=>delete lt.store[n]])},purge:e=>{!lt.store[e]||(delete lt.store[e],Ha.default.unlinkAttempt(e))},purgeSync:e=>{!lt.store[e]||(delete lt.store[e],Ha.default.unlinkSyncAttempt(e))},purgeSyncAll:()=>{for(const e in lt.store)lt.purgeSync(e)},truncate:e=>{const t=xm.basename(e);if(t.length<=Ba.LIMIT_BASENAME_LENGTH)return e;const r=/^(\.?)(.*?)((?:\.[^.]+)?(?:\.tmp-\d{10}[a-f0-9]{6})?)$/.exec(t);if(!r)return e;const n=t.length-Ba.LIMIT_BASENAME_LENGTH;return`${e.slice(0,-t.length)}${r[1]}${r[2].slice(0,-n)}${r[3]}`}};process.on("exit",lt.purgeSyncAll);mo.default=lt;Object.defineProperty(Ut,"__esModule",{value:!0});Ut.writeFileSync=Ut.writeFile=Ut.readFileSync=Ut.readFile=void 0;const ef=Ie.default,xe=me,he=Xi,dt=lo,Vm=ho,cr=mo;function tf(e,t=xe.DEFAULT_READ_OPTIONS){var r;if(dt.default.isString(t))return tf(e,{encoding:t});const n=Date.now()+((r=t.timeout)!==null&&r!==void 0?r:xe.DEFAULT_TIMEOUT_ASYNC);return he.default.readFileRetry(n)(e,t)}Ut.readFile=tf;function rf(e,t=xe.DEFAULT_READ_OPTIONS){var r;if(dt.default.isString(t))return rf(e,{encoding:t});const n=Date.now()+((r=t.timeout)!==null&&r!==void 0?r:xe.DEFAULT_TIMEOUT_SYNC);return he.default.readFileSyncRetry(n)(e,t)}Ut.readFileSync=rf;const nf=(e,t,r,n)=>{if(dt.default.isFunction(r))return nf(e,t,xe.DEFAULT_WRITE_OPTIONS,r);const i=sf(e,t,r);return n&&i.then(n,n),i};Ut.writeFile=nf;const sf=async(e,t,r=xe.DEFAULT_WRITE_OPTIONS)=>{var n;if(dt.default.isString(r))return sf(e,t,{encoding:r});const i=Date.now()+((n=r.timeout)!==null&&n!==void 0?n:xe.DEFAULT_TIMEOUT_ASYNC);let s=null,o=null,c=null,u=null,m=null;try{r.schedule&&(s=await r.schedule(e)),o=await Vm.default.schedule(e),e=await he.default.realpathAttempt(e)||e,[u,c]=cr.default.get(e,r.tmpCreate||cr.default.create,r.tmpPurge!==!1);const a=xe.IS_POSIX&&dt.default.isUndefined(r.chown),l=dt.default.isUndefined(r.mode);if(a||l){const h=await he.default.statAttempt(e);h&&(r=Q({},r),a&&(r.chown={uid:h.uid,gid:h.gid}),l&&(r.mode=h.mode))}const E=ef.dirname(e);await he.default.mkdirAttempt(E,{mode:xe.DEFAULT_FOLDER_MODE,recursive:!0}),m=await he.default.openRetry(i)(u,"w",r.mode||xe.DEFAULT_FILE_MODE),r.tmpCreated&&r.tmpCreated(u),dt.default.isString(t)?await he.default.writeRetry(i)(m,t,0,r.encoding||xe.DEFAULT_ENCODING):dt.default.isUndefined(t)||await he.default.writeRetry(i)(m,t,0,t.length,0),r.fsync!==!1&&(r.fsyncWait!==!1?await he.default.fsyncRetry(i)(m):he.default.fsyncAttempt(m)),await he.default.closeRetry(i)(m),m=null,r.chown&&await he.default.chownAttempt(u,r.chown.uid,r.chown.gid),r.mode&&await he.default.chmodAttempt(u,r.mode);try{await he.default.renameRetry(i)(u,e)}catch(h){if(h.code!=="ENAMETOOLONG")throw h;await he.default.renameRetry(i)(u,cr.default.truncate(e))}c(),u=null}finally{m&&await he.default.closeAttempt(m),u&&cr.default.purge(u),s&&s(),o&&o()}},of=(e,t,r=xe.DEFAULT_WRITE_OPTIONS)=>{var n;if(dt.default.isString(r))return of(e,t,{encoding:r});const i=Date.now()+((n=r.timeout)!==null&&n!==void 0?n:xe.DEFAULT_TIMEOUT_SYNC);let s=null,o=null,c=null;try{e=he.default.realpathSyncAttempt(e)||e,[o,s]=cr.default.get(e,r.tmpCreate||cr.default.create,r.tmpPurge!==!1);const u=xe.IS_POSIX&&dt.default.isUndefined(r.chown),m=dt.default.isUndefined(r.mode);if(u||m){const l=he.default.statSyncAttempt(e);l&&(r=Q({},r),u&&(r.chown={uid:l.uid,gid:l.gid}),m&&(r.mode=l.mode))}const a=ef.dirname(e);he.default.mkdirSyncAttempt(a,{mode:xe.DEFAULT_FOLDER_MODE,recursive:!0}),c=he.default.openSyncRetry(i)(o,"w",r.mode||xe.DEFAULT_FILE_MODE),r.tmpCreated&&r.tmpCreated(o),dt.default.isString(t)?he.default.writeSyncRetry(i)(c,t,0,r.encoding||xe.DEFAULT_ENCODING):dt.default.isUndefined(t)||he.default.writeSyncRetry(i)(c,t,0,t.length,0),r.fsync!==!1&&(r.fsyncWait!==!1?he.default.fsyncSyncRetry(i)(c):he.default.fsyncAttempt(c)),he.default.closeSyncRetry(i)(c),c=null,r.chown&&he.default.chownSyncAttempt(o,r.chown.uid,r.chown.gid),r.mode&&he.default.chmodSyncAttempt(o,r.mode);try{he.default.renameSyncRetry(i)(o,e)}catch(l){if(l.code!=="ENAMETOOLONG")throw l;he.default.renameSyncRetry(i)(o,cr.default.truncate(e))}s(),o=null}finally{c&&he.default.closeSyncAttempt(c),o&&cr.default.purge(o)}};Ut.writeFileSync=of;var Ai={exports:{}},af={},Tt={},sn={},Yn={},ee={},Gn={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.regexpCode=e.getEsmExportName=e.getProperty=e.safeStringify=e.stringify=e.strConcat=e.addCodeArg=e.str=e._=e.nil=e._Code=e.Name=e.IDENTIFIER=e._CodeOrName=void 0;class t{}e._CodeOrName=t,e.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class r extends t{constructor($){super();if(!e.IDENTIFIER.test($))throw new Error("CodeGen: name must be a valid identifier");this.str=$}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}e.Name=r;class n extends t{constructor($){super();this._items=typeof $=="string"?[$]:$}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const $=this._items[0];return $===""||$==='""'}get str(){var $;return($=this._str)!==null&&$!==void 0?$:this._str=this._items.reduce((w,T)=>`${w}${T}`,"")}get names(){var $;return($=this._names)!==null&&$!==void 0?$:this._names=this._items.reduce((w,T)=>(T instanceof r&&(w[T.str]=(w[T.str]||0)+1),w),{})}}e._Code=n,e.nil=new n("");function i(f,...$){const w=[f[0]];let T=0;for(;T<$.length;)c(w,$[T]),w.push(f[++T]);return new n(w)}e._=i;const s=new n("+");function o(f,...$){const w=[h(f[0])];let T=0;for(;T<$.length;)w.push(s),c(w,$[T]),w.push(s,h(f[++T]));return u(w),new n(w)}e.str=o;function c(f,$){$ instanceof n?f.push(...$._items):$ instanceof r?f.push($):f.push(l($))}e.addCodeArg=c;function u(f){let $=1;for(;$<f.length-1;){if(f[$]===s){const w=m(f[$-1],f[$+1]);if(w!==void 0){f.splice($-1,3,w);continue}f[$++]="+"}$++}}function m(f,$){if($==='""')return f;if(f==='""')return $;if(typeof f=="string")return $ instanceof r||f[f.length-1]!=='"'?void 0:typeof $!="string"?`${f.slice(0,-1)}${$}"`:$[0]==='"'?f.slice(0,-1)+$.slice(1):void 0;if(typeof $=="string"&&$[0]==='"'&&!(f instanceof r))return`"${f}${$.slice(1)}`}function a(f,$){return $.emptyStr()?f:f.emptyStr()?$:o`${f}${$}`}e.strConcat=a;function l(f){return typeof f=="number"||typeof f=="boolean"||f===null?f:h(Array.isArray(f)?f.join(","):f)}function E(f){return new n(h(f))}e.stringify=E;function h(f){return JSON.stringify(f).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}e.safeStringify=h;function d(f){return typeof f=="string"&&e.IDENTIFIER.test(f)?new n(`.${f}`):i`[${f}]`}e.getProperty=d;function y(f){if(typeof f=="string"&&e.IDENTIFIER.test(f))return new n(`${f}`);throw new Error(`CodeGen: invalid export name: ${f}, use explicit $id name mapping`)}e.getEsmExportName=y;function v(f){return new n(f.toString())}e.regexpCode=v})(Gn);var js={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ValueScope=e.ValueScopeName=e.Scope=e.varKinds=e.UsedValueState=void 0;const t=Gn;class r extends Error{constructor(m){super(`CodeGen: "code" for ${m} not defined`);this.value=m.value}}var n;(function(u){u[u.Started=0]="Started",u[u.Completed=1]="Completed"})(n=e.UsedValueState||(e.UsedValueState={})),e.varKinds={const:new t.Name("const"),let:new t.Name("let"),var:new t.Name("var")};class i{constructor({prefixes:m,parent:a}={}){this._names={},this._prefixes=m,this._parent=a}toName(m){return m instanceof t.Name?m:this.name(m)}name(m){return new t.Name(this._newName(m))}_newName(m){const a=this._names[m]||this._nameGroup(m);return`${m}${a.index++}`}_nameGroup(m){var a,l;if(((l=(a=this._parent)===null||a===void 0?void 0:a._prefixes)===null||l===void 0?void 0:l.has(m))||this._prefixes&&!this._prefixes.has(m))throw new Error(`CodeGen: prefix "${m}" is not allowed in this scope`);return this._names[m]={prefix:m,index:0}}}e.Scope=i;class s extends t.Name{constructor(m,a){super(a);this.prefix=m}setValue(m,{property:a,itemIndex:l}){this.value=m,this.scopePath=(0,t._)`.${new t.Name(a)}[${l}]`}}e.ValueScopeName=s;const o=(0,t._)`\n`;class c extends i{constructor(m){super(m);this._values={},this._scope=m.scope,this.opts=vt(Q({},m),{_n:m.lines?o:t.nil})}get(){return this._scope}name(m){return new s(m,this._newName(m))}value(m,a){var l;if(a.ref===void 0)throw new Error("CodeGen: ref must be passed in value");const E=this.toName(m),{prefix:h}=E,d=(l=a.key)!==null&&l!==void 0?l:a.ref;let y=this._values[h];if(y){const $=y.get(d);if($)return $}else y=this._values[h]=new Map;y.set(d,E);const v=this._scope[h]||(this._scope[h]=[]),f=v.length;return v[f]=a.ref,E.setValue(a,{property:h,itemIndex:f}),E}getValue(m,a){const l=this._values[m];if(!!l)return l.get(a)}scopeRefs(m,a=this._values){return this._reduceValues(a,l=>{if(l.scopePath===void 0)throw new Error(`CodeGen: name "${l}" has no value`);return(0,t._)`${m}${l.scopePath}`})}scopeCode(m=this._values,a,l){return this._reduceValues(m,E=>{if(E.value===void 0)throw new Error(`CodeGen: name "${E}" has no value`);return E.value.code},a,l)}_reduceValues(m,a,l={},E){let h=t.nil;for(const d in m){const y=m[d];if(!y)continue;const v=l[d]=l[d]||new Map;y.forEach(f=>{if(v.has(f))return;v.set(f,n.Started);let $=a(f);if($){const w=this.opts.es5?e.varKinds.var:e.varKinds.const;h=(0,t._)`${h}${w} ${f} = ${$};${this.opts._n}`}else if($=E==null?void 0:E(f))h=(0,t._)`${h}${$}${this.opts._n}`;else throw new r(f);v.set(f,n.Completed)})}return h}}e.ValueScope=c})(js);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.or=e.and=e.not=e.CodeGen=e.operators=e.varKinds=e.ValueScopeName=e.ValueScope=e.Scope=e.Name=e.regexpCode=e.stringify=e.getProperty=e.nil=e.strConcat=e.str=e._=void 0;const t=Gn,r=js;var n=Gn;Object.defineProperty(e,"_",{enumerable:!0,get:function(){return n._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return n.str}}),Object.defineProperty(e,"strConcat",{enumerable:!0,get:function(){return n.strConcat}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return n.nil}}),Object.defineProperty(e,"getProperty",{enumerable:!0,get:function(){return n.getProperty}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return n.stringify}}),Object.defineProperty(e,"regexpCode",{enumerable:!0,get:function(){return n.regexpCode}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return n.Name}});var i=js;Object.defineProperty(e,"Scope",{enumerable:!0,get:function(){return i.Scope}}),Object.defineProperty(e,"ValueScope",{enumerable:!0,get:function(){return i.ValueScope}}),Object.defineProperty(e,"ValueScopeName",{enumerable:!0,get:function(){return i.ValueScopeName}}),Object.defineProperty(e,"varKinds",{enumerable:!0,get:function(){return i.varKinds}}),e.operators={GT:new t._Code(">"),GTE:new t._Code(">="),LT:new t._Code("<"),LTE:new t._Code("<="),EQ:new t._Code("==="),NEQ:new t._Code("!=="),NOT:new t._Code("!"),OR:new t._Code("||"),AND:new t._Code("&&"),ADD:new t._Code("+")};class s{optimizeNodes(){return this}optimizeNames(p,_){return this}}class o extends s{constructor(p,_,F){super();this.varKind=p,this.name=_,this.rhs=F}render({es5:p,_n:_}){const F=p?r.varKinds.var:this.varKind,V=this.rhs===void 0?"":` = ${this.rhs}`;return`${F} ${this.name}${V};`+_}optimizeNames(p,_){if(!!p[this.name.str])return this.rhs&&(this.rhs=Z(this.rhs,p,_)),this}get names(){return this.rhs instanceof t._CodeOrName?this.rhs.names:{}}}class c extends s{constructor(p,_,F){super();this.lhs=p,this.rhs=_,this.sideEffects=F}render({_n:p}){return`${this.lhs} = ${this.rhs};`+p}optimizeNames(p,_){if(!(this.lhs instanceof t.Name&&!p[this.lhs.str]&&!this.sideEffects))return this.rhs=Z(this.rhs,p,_),this}get names(){const p=this.lhs instanceof t.Name?{}:Q({},this.lhs.names);return J(p,this.rhs)}}class u extends c{constructor(p,_,F,V){super(p,F,V);this.op=_}render({_n:p}){return`${this.lhs} ${this.op}= ${this.rhs};`+p}}class m extends s{constructor(p){super();this.label=p,this.names={}}render({_n:p}){return`${this.label}:`+p}}class a extends s{constructor(p){super();this.label=p,this.names={}}render({_n:p}){return`break${this.label?` ${this.label}`:""};`+p}}class l extends s{constructor(p){super();this.error=p}render({_n:p}){return`throw ${this.error};`+p}get names(){return this.error.names}}class E extends s{constructor(p){super();this.code=p}render({_n:p}){return`${this.code};`+p}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(p,_){return this.code=Z(this.code,p,_),this}get names(){return this.code instanceof t._CodeOrName?this.code.names:{}}}class h extends s{constructor(p=[]){super();this.nodes=p}render(p){return this.nodes.reduce((_,F)=>_+F.render(p),"")}optimizeNodes(){const{nodes:p}=this;let _=p.length;for(;_--;){const F=p[_].optimizeNodes();Array.isArray(F)?p.splice(_,1,...F):F?p[_]=F:p.splice(_,1)}return p.length>0?this:void 0}optimizeNames(p,_){const{nodes:F}=this;let V=F.length;for(;V--;){const q=F[V];q.optimizeNames(p,_)||(le(p,q.names),F.splice(V,1))}return F.length>0?this:void 0}get names(){return this.nodes.reduce((p,_)=>z(p,_.names),{})}}class d extends h{render(p){return"{"+p._n+super.render(p)+"}"+p._n}}class y extends h{}class v extends d{}v.kind="else";class f extends d{constructor(p,_){super(_);this.condition=p}render(p){let _=`if(${this.condition})`+super.render(p);return this.else&&(_+="else "+this.else.render(p)),_}optimizeNodes(){super.optimizeNodes();const p=this.condition;if(p===!0)return this.nodes;let _=this.else;if(_){const F=_.optimizeNodes();_=this.else=Array.isArray(F)?new v(F):F}if(_)return p===!1?_ instanceof f?_:_.nodes:this.nodes.length?this:new f(te(p),_ instanceof f?[_]:_.nodes);if(!(p===!1||!this.nodes.length))return this}optimizeNames(p,_){var F;if(this.else=(F=this.else)===null||F===void 0?void 0:F.optimizeNames(p,_),!!(super.optimizeNames(p,_)||this.else))return this.condition=Z(this.condition,p,_),this}get names(){const p=super.names;return J(p,this.condition),this.else&&z(p,this.else.names),p}}f.kind="if";class $ extends d{}$.kind="for";class w extends ${constructor(p){super();this.iteration=p}render(p){return`for(${this.iteration})`+super.render(p)}optimizeNames(p,_){if(!!super.optimizeNames(p,_))return this.iteration=Z(this.iteration,p,_),this}get names(){return z(super.names,this.iteration.names)}}class T extends ${constructor(p,_,F,V){super();this.varKind=p,this.name=_,this.from=F,this.to=V}render(p){const _=p.es5?r.varKinds.var:this.varKind,{name:F,from:V,to:q}=this;return`for(${_} ${F}=${V}; ${F}<${q}; ${F}++)`+super.render(p)}get names(){const p=J(super.names,this.from);return J(p,this.to)}}class k extends ${constructor(p,_,F,V){super();this.loop=p,this.varKind=_,this.name=F,this.iterable=V}render(p){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(p)}optimizeNames(p,_){if(!!super.optimizeNames(p,_))return this.iterable=Z(this.iterable,p,_),this}get names(){return z(super.names,this.iterable.names)}}class O extends d{constructor(p,_,F){super();this.name=p,this.args=_,this.async=F}render(p){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(p)}}O.kind="func";class D extends h{render(p){return"return "+super.render(p)}}D.kind="return";class P extends d{render(p){let _="try"+super.render(p);return this.catch&&(_+=this.catch.render(p)),this.finally&&(_+=this.finally.render(p)),_}optimizeNodes(){var p,_;return super.optimizeNodes(),(p=this.catch)===null||p===void 0||p.optimizeNodes(),(_=this.finally)===null||_===void 0||_.optimizeNodes(),this}optimizeNames(p,_){var F,V;return super.optimizeNames(p,_),(F=this.catch)===null||F===void 0||F.optimizeNames(p,_),(V=this.finally)===null||V===void 0||V.optimizeNames(p,_),this}get names(){const p=super.names;return this.catch&&z(p,this.catch.names),this.finally&&z(p,this.finally.names),p}}class L extends d{constructor(p){super();this.error=p}render(p){return`catch(${this.error})`+super.render(p)}}L.kind="catch";class U extends d{render(p){return"finally"+super.render(p)}}U.kind="finally";class B{constructor(p,_={}){this._values={},this._blockStarts=[],this._constants={},this.opts=vt(Q({},_),{_n:_.lines?`
8
+ `:""}),this._extScope=p,this._scope=new r.Scope({parent:p}),this._nodes=[new y]}toString(){return this._root.render(this.opts)}name(p){return this._scope.name(p)}scopeName(p){return this._extScope.name(p)}scopeValue(p,_){const F=this._extScope.value(p,_);return(this._values[F.prefix]||(this._values[F.prefix]=new Set)).add(F),F}getScopeValue(p,_){return this._extScope.getValue(p,_)}scopeRefs(p){return this._extScope.scopeRefs(p,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(p,_,F,V){const q=this._scope.toName(_);return F!==void 0&&V&&(this._constants[q.str]=F),this._leafNode(new o(p,q,F)),q}const(p,_,F){return this._def(r.varKinds.const,p,_,F)}let(p,_,F){return this._def(r.varKinds.let,p,_,F)}var(p,_,F){return this._def(r.varKinds.var,p,_,F)}assign(p,_,F){return this._leafNode(new c(p,_,F))}add(p,_){return this._leafNode(new u(p,e.operators.ADD,_))}code(p){return typeof p=="function"?p():p!==t.nil&&this._leafNode(new E(p)),this}object(...p){const _=["{"];for(const[F,V]of p)_.length>1&&_.push(","),_.push(F),(F!==V||this.opts.es5)&&(_.push(":"),(0,t.addCodeArg)(_,V));return _.push("}"),new t._Code(_)}if(p,_,F){if(this._blockNode(new f(p)),_&&F)this.code(_).else().code(F).endIf();else if(_)this.code(_).endIf();else if(F)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(p){return this._elseNode(new f(p))}else(){return this._elseNode(new v)}endIf(){return this._endBlockNode(f,v)}_for(p,_){return this._blockNode(p),_&&this.code(_).endFor(),this}for(p,_){return this._for(new w(p),_)}forRange(p,_,F,V,q=this.opts.es5?r.varKinds.var:r.varKinds.let){const ie=this._scope.toName(p);return this._for(new T(q,ie,_,F),()=>V(ie))}forOf(p,_,F,V=r.varKinds.const){const q=this._scope.toName(p);if(this.opts.es5){const ie=_ instanceof t.Name?_:this.var("_arr",_);return this.forRange("_i",0,(0,t._)`${ie}.length`,ae=>{this.var(q,(0,t._)`${ie}[${ae}]`),F(q)})}return this._for(new k("of",V,q,_),()=>F(q))}forIn(p,_,F,V=this.opts.es5?r.varKinds.var:r.varKinds.const){if(this.opts.ownProperties)return this.forOf(p,(0,t._)`Object.keys(${_})`,F);const q=this._scope.toName(p);return this._for(new k("in",V,q,_),()=>F(q))}endFor(){return this._endBlockNode($)}label(p){return this._leafNode(new m(p))}break(p){return this._leafNode(new a(p))}return(p){const _=new D;if(this._blockNode(_),this.code(p),_.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(D)}try(p,_,F){if(!_&&!F)throw new Error('CodeGen: "try" without "catch" and "finally"');const V=new P;if(this._blockNode(V),this.code(p),_){const q=this.name("e");this._currNode=V.catch=new L(q),_(q)}return F&&(this._currNode=V.finally=new U,this.code(F)),this._endBlockNode(L,U)}throw(p){return this._leafNode(new l(p))}block(p,_){return this._blockStarts.push(this._nodes.length),p&&this.code(p).endBlock(_),this}endBlock(p){const _=this._blockStarts.pop();if(_===void 0)throw new Error("CodeGen: not in self-balancing block");const F=this._nodes.length-_;if(F<0||p!==void 0&&F!==p)throw new Error(`CodeGen: wrong number of nodes: ${F} vs ${p} expected`);return this._nodes.length=_,this}func(p,_=t.nil,F,V){return this._blockNode(new O(p,_,F)),V&&this.code(V).endFunc(),this}endFunc(){return this._endBlockNode(O)}optimize(p=1){for(;p-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(p){return this._currNode.nodes.push(p),this}_blockNode(p){this._currNode.nodes.push(p),this._nodes.push(p)}_endBlockNode(p,_){const F=this._currNode;if(F instanceof p||_&&F instanceof _)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${_?`${p.kind}/${_.kind}`:p.kind}"`)}_elseNode(p){const _=this._currNode;if(!(_ instanceof f))throw new Error('CodeGen: "else" without "if"');return this._currNode=_.else=p,this}get _root(){return this._nodes[0]}get _currNode(){const p=this._nodes;return p[p.length-1]}set _currNode(p){const _=this._nodes;_[_.length-1]=p}}e.CodeGen=B;function z(R,p){for(const _ in p)R[_]=(R[_]||0)+(p[_]||0);return R}function J(R,p){return p instanceof t._CodeOrName?z(R,p.names):R}function Z(R,p,_){if(R instanceof t.Name)return F(R);if(!V(R))return R;return new t._Code(R._items.reduce((q,ie)=>(ie instanceof t.Name&&(ie=F(ie)),ie instanceof t._Code?q.push(...ie._items):q.push(ie),q),[]));function F(q){const ie=_[q.str];return ie===void 0||p[q.str]!==1?q:(delete p[q.str],ie)}function V(q){return q instanceof t._Code&&q._items.some(ie=>ie instanceof t.Name&&p[ie.str]===1&&_[ie.str]!==void 0)}}function le(R,p){for(const _ in p)R[_]=(R[_]||0)-(p[_]||0)}function te(R){return typeof R=="boolean"||typeof R=="number"||R===null?!R:(0,t._)`!${M(R)}`}e.not=te;const ne=I(e.operators.AND);function j(...R){return R.reduce(ne)}e.and=j;const x=I(e.operators.OR);function C(...R){return R.reduce(x)}e.or=C;function I(R){return(p,_)=>p===t.nil?_:_===t.nil?p:(0,t._)`${M(p)} ${R} ${M(_)}`}function M(R){return R instanceof t.Name?R:(0,t._)`(${R})`}})(ee);var fe={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.checkStrictMode=e.getErrorPath=e.Type=e.useFunc=e.setEvaluated=e.evaluatedPropsToName=e.mergeEvaluated=e.eachItem=e.unescapeJsonPointer=e.escapeJsonPointer=e.escapeFragment=e.unescapeFragment=e.schemaRefOrVal=e.schemaHasRulesButRef=e.schemaHasRules=e.checkUnknownRules=e.alwaysValidSchema=e.toHash=void 0;const t=ee,r=Gn;function n(O){const D={};for(const P of O)D[P]=!0;return D}e.toHash=n;function i(O,D){return typeof D=="boolean"?D:Object.keys(D).length===0?!0:(s(O,D),!o(D,O.self.RULES.all))}e.alwaysValidSchema=i;function s(O,D=O.schema){const{opts:P,self:L}=O;if(!P.strictSchema||typeof D=="boolean")return;const U=L.RULES.keywords;for(const B in D)U[B]||k(O,`unknown keyword: "${B}"`)}e.checkUnknownRules=s;function o(O,D){if(typeof O=="boolean")return!O;for(const P in O)if(D[P])return!0;return!1}e.schemaHasRules=o;function c(O,D){if(typeof O=="boolean")return!O;for(const P in O)if(P!=="$ref"&&D.all[P])return!0;return!1}e.schemaHasRulesButRef=c;function u({topSchemaRef:O,schemaPath:D},P,L,U){if(!U){if(typeof P=="number"||typeof P=="boolean")return P;if(typeof P=="string")return(0,t._)`${P}`}return(0,t._)`${O}${D}${(0,t.getProperty)(L)}`}e.schemaRefOrVal=u;function m(O){return E(decodeURIComponent(O))}e.unescapeFragment=m;function a(O){return encodeURIComponent(l(O))}e.escapeFragment=a;function l(O){return typeof O=="number"?`${O}`:O.replace(/~/g,"~0").replace(/\//g,"~1")}e.escapeJsonPointer=l;function E(O){return O.replace(/~1/g,"/").replace(/~0/g,"~")}e.unescapeJsonPointer=E;function h(O,D){if(Array.isArray(O))for(const P of O)D(P);else D(O)}e.eachItem=h;function d({mergeNames:O,mergeToName:D,mergeValues:P,resultToName:L}){return(U,B,z,J)=>{const Z=z===void 0?B:z instanceof t.Name?(B instanceof t.Name?O(U,B,z):D(U,B,z),z):B instanceof t.Name?(D(U,z,B),B):P(B,z);return J===t.Name&&!(Z instanceof t.Name)?L(U,Z):Z}}e.mergeEvaluated={props:d({mergeNames:(O,D,P)=>O.if((0,t._)`${P} !== true && ${D} !== undefined`,()=>{O.if((0,t._)`${D} === true`,()=>O.assign(P,!0),()=>O.assign(P,(0,t._)`${P} || {}`).code((0,t._)`Object.assign(${P}, ${D})`))}),mergeToName:(O,D,P)=>O.if((0,t._)`${P} !== true`,()=>{D===!0?O.assign(P,!0):(O.assign(P,(0,t._)`${P} || {}`),v(O,P,D))}),mergeValues:(O,D)=>O===!0?!0:Q(Q({},O),D),resultToName:y}),items:d({mergeNames:(O,D,P)=>O.if((0,t._)`${P} !== true && ${D} !== undefined`,()=>O.assign(P,(0,t._)`${D} === true ? true : ${P} > ${D} ? ${P} : ${D}`)),mergeToName:(O,D,P)=>O.if((0,t._)`${P} !== true`,()=>O.assign(P,D===!0?!0:(0,t._)`${P} > ${D} ? ${P} : ${D}`)),mergeValues:(O,D)=>O===!0?!0:Math.max(O,D),resultToName:(O,D)=>O.var("items",D)})};function y(O,D){if(D===!0)return O.var("props",!0);const P=O.var("props",(0,t._)`{}`);return D!==void 0&&v(O,P,D),P}e.evaluatedPropsToName=y;function v(O,D,P){Object.keys(P).forEach(L=>O.assign((0,t._)`${D}${(0,t.getProperty)(L)}`,!0))}e.setEvaluated=v;const f={};function $(O,D){return O.scopeValue("func",{ref:D,code:f[D.code]||(f[D.code]=new r._Code(D.code))})}e.useFunc=$;var w;(function(O){O[O.Num=0]="Num",O[O.Str=1]="Str"})(w=e.Type||(e.Type={}));function T(O,D,P){if(O instanceof t.Name){const L=D===w.Num;return P?L?(0,t._)`"[" + ${O} + "]"`:(0,t._)`"['" + ${O} + "']"`:L?(0,t._)`"/" + ${O}`:(0,t._)`"/" + ${O}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return P?(0,t.getProperty)(O).toString():"/"+l(O)}e.getErrorPath=T;function k(O,D,P=O.opts.strictSchema){if(!!P){if(D=`strict mode: ${D}`,P===!0)throw new Error(D);O.self.logger.warn(D)}}e.checkStrictMode=k})(fe);var Vt={};Object.defineProperty(Vt,"__esModule",{value:!0});const He=ee,qm={data:new He.Name("data"),valCxt:new He.Name("valCxt"),instancePath:new He.Name("instancePath"),parentData:new He.Name("parentData"),parentDataProperty:new He.Name("parentDataProperty"),rootData:new He.Name("rootData"),dynamicAnchors:new He.Name("dynamicAnchors"),vErrors:new He.Name("vErrors"),errors:new He.Name("errors"),this:new He.Name("this"),self:new He.Name("self"),scope:new He.Name("scope"),json:new He.Name("json"),jsonPos:new He.Name("jsonPos"),jsonLen:new He.Name("jsonLen"),jsonPart:new He.Name("jsonPart")};Vt.default=qm;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.extendErrors=e.resetErrorsCount=e.reportExtraError=e.reportError=e.keyword$DataError=e.keywordError=void 0;const t=ee,r=fe,n=Vt;e.keywordError={message:({keyword:v})=>(0,t.str)`must pass "${v}" keyword validation`},e.keyword$DataError={message:({keyword:v,schemaType:f})=>f?(0,t.str)`"${v}" keyword must be ${f} ($data)`:(0,t.str)`"${v}" keyword is invalid ($data)`};function i(v,f=e.keywordError,$,w){const{it:T}=v,{gen:k,compositeRule:O,allErrors:D}=T,P=l(v,f,$);(w!=null?w:O||D)?u(k,P):m(T,(0,t._)`[${P}]`)}e.reportError=i;function s(v,f=e.keywordError,$){const{it:w}=v,{gen:T,compositeRule:k,allErrors:O}=w,D=l(v,f,$);u(T,D),k||O||m(w,n.default.vErrors)}e.reportExtraError=s;function o(v,f){v.assign(n.default.errors,f),v.if((0,t._)`${n.default.vErrors} !== null`,()=>v.if(f,()=>v.assign((0,t._)`${n.default.vErrors}.length`,f),()=>v.assign(n.default.vErrors,null)))}e.resetErrorsCount=o;function c({gen:v,keyword:f,schemaValue:$,data:w,errsCount:T,it:k}){if(T===void 0)throw new Error("ajv implementation error");const O=v.name("err");v.forRange("i",T,n.default.errors,D=>{v.const(O,(0,t._)`${n.default.vErrors}[${D}]`),v.if((0,t._)`${O}.instancePath === undefined`,()=>v.assign((0,t._)`${O}.instancePath`,(0,t.strConcat)(n.default.instancePath,k.errorPath))),v.assign((0,t._)`${O}.schemaPath`,(0,t.str)`${k.errSchemaPath}/${f}`),k.opts.verbose&&(v.assign((0,t._)`${O}.schema`,$),v.assign((0,t._)`${O}.data`,w))})}e.extendErrors=c;function u(v,f){const $=v.const("err",f);v.if((0,t._)`${n.default.vErrors} === null`,()=>v.assign(n.default.vErrors,(0,t._)`[${$}]`),(0,t._)`${n.default.vErrors}.push(${$})`),v.code((0,t._)`${n.default.errors}++`)}function m(v,f){const{gen:$,validateName:w,schemaEnv:T}=v;T.$async?$.throw((0,t._)`new ${v.ValidationError}(${f})`):($.assign((0,t._)`${w}.errors`,f),$.return(!1))}const a={keyword:new t.Name("keyword"),schemaPath:new t.Name("schemaPath"),params:new t.Name("params"),propertyName:new t.Name("propertyName"),message:new t.Name("message"),schema:new t.Name("schema"),parentSchema:new t.Name("parentSchema")};function l(v,f,$){const{createErrors:w}=v.it;return w===!1?(0,t._)`{}`:E(v,f,$)}function E(v,f,$={}){const{gen:w,it:T}=v,k=[h(T,$),d(v,$)];return y(v,f,k),w.object(...k)}function h({errorPath:v},{instancePath:f}){const $=f?(0,t.str)`${v}${(0,r.getErrorPath)(f,r.Type.Str)}`:v;return[n.default.instancePath,(0,t.strConcat)(n.default.instancePath,$)]}function d({keyword:v,it:{errSchemaPath:f}},{schemaPath:$,parentSchema:w}){let T=w?f:(0,t.str)`${f}/${v}`;return $&&(T=(0,t.str)`${T}${(0,r.getErrorPath)($,r.Type.Str)}`),[a.schemaPath,T]}function y(v,{params:f,message:$},w){const{keyword:T,data:k,schemaValue:O,it:D}=v,{opts:P,propertyName:L,topSchemaRef:U,schemaPath:B}=D;w.push([a.keyword,T],[a.params,typeof f=="function"?f(v):f||(0,t._)`{}`]),P.messages&&w.push([a.message,typeof $=="function"?$(v):$]),P.verbose&&w.push([a.schema,O],[a.parentSchema,(0,t._)`${U}${B}`],[n.default.data,k]),L&&w.push([a.propertyName,L])}})(Yn);Object.defineProperty(sn,"__esModule",{value:!0});sn.boolOrEmptySchema=sn.topBoolOrEmptySchema=void 0;const Gm=Yn,Bm=ee,Hm=Vt,Km={message:"boolean schema is false"};function Xm(e){const{gen:t,schema:r,validateName:n}=e;r===!1?cf(e,!1):typeof r=="object"&&r.$async===!0?t.return(Hm.default.data):(t.assign((0,Bm._)`${n}.errors`,null),t.return(!0))}sn.topBoolOrEmptySchema=Xm;function Zm(e,t){const{gen:r,schema:n}=e;n===!1?(r.var(t,!1),cf(e)):r.var(t,!0)}sn.boolOrEmptySchema=Zm;function cf(e,t){const{gen:r,data:n}=e,i={gen:r,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,Gm.reportError)(i,Km,void 0,t)}var Qn={},Tr={};Object.defineProperty(Tr,"__esModule",{value:!0});Tr.getRules=Tr.isJSONType=void 0;const Wm=["string","number","integer","boolean","null","object","array"],Jm=new Set(Wm);function Ym(e){return typeof e=="string"&&Jm.has(e)}Tr.isJSONType=Ym;function Qm(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:vt(Q({},e),{integer:!0,boolean:!0,null:!0}),rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}Tr.getRules=Qm;var Kt={};Object.defineProperty(Kt,"__esModule",{value:!0});Kt.shouldUseRule=Kt.shouldUseGroup=Kt.schemaHasRulesForType=void 0;function ep({schema:e,self:t},r){const n=t.RULES.types[r];return n&&n!==!0&&uf(e,n)}Kt.schemaHasRulesForType=ep;function uf(e,t){return t.rules.some(r=>ff(e,r))}Kt.shouldUseGroup=uf;function ff(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some(n=>e[n]!==void 0))}Kt.shouldUseRule=ff;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.reportTypeError=e.checkDataTypes=e.checkDataType=e.coerceAndCheckDataType=e.getJSONTypes=e.getSchemaTypes=e.DataType=void 0;const t=Tr,r=Kt,n=Yn,i=ee,s=fe;var o;(function(w){w[w.Correct=0]="Correct",w[w.Wrong=1]="Wrong"})(o=e.DataType||(e.DataType={}));function c(w){const T=u(w.type);if(T.includes("null")){if(w.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!T.length&&w.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');w.nullable===!0&&T.push("null")}return T}e.getSchemaTypes=c;function u(w){const T=Array.isArray(w)?w:w?[w]:[];if(T.every(t.isJSONType))return T;throw new Error("type must be JSONType or JSONType[]: "+T.join(","))}e.getJSONTypes=u;function m(w,T){const{gen:k,data:O,opts:D}=w,P=l(T,D.coerceTypes),L=T.length>0&&!(P.length===0&&T.length===1&&(0,r.schemaHasRulesForType)(w,T[0]));if(L){const U=y(T,O,D.strictNumbers,o.Wrong);k.if(U,()=>{P.length?E(w,T,P):f(w)})}return L}e.coerceAndCheckDataType=m;const a=new Set(["string","number","integer","boolean","null"]);function l(w,T){return T?w.filter(k=>a.has(k)||T==="array"&&k==="array"):[]}function E(w,T,k){const{gen:O,data:D,opts:P}=w,L=O.let("dataType",(0,i._)`typeof ${D}`),U=O.let("coerced",(0,i._)`undefined`);P.coerceTypes==="array"&&O.if((0,i._)`${L} == 'object' && Array.isArray(${D}) && ${D}.length == 1`,()=>O.assign(D,(0,i._)`${D}[0]`).assign(L,(0,i._)`typeof ${D}`).if(y(T,D,P.strictNumbers),()=>O.assign(U,D))),O.if((0,i._)`${U} !== undefined`);for(const z of k)(a.has(z)||z==="array"&&P.coerceTypes==="array")&&B(z);O.else(),f(w),O.endIf(),O.if((0,i._)`${U} !== undefined`,()=>{O.assign(D,U),h(w,U)});function B(z){switch(z){case"string":O.elseIf((0,i._)`${L} == "number" || ${L} == "boolean"`).assign(U,(0,i._)`"" + ${D}`).elseIf((0,i._)`${D} === null`).assign(U,(0,i._)`""`);return;case"number":O.elseIf((0,i._)`${L} == "boolean" || ${D} === null
9
+ || (${L} == "string" && ${D} && ${D} == +${D})`).assign(U,(0,i._)`+${D}`);return;case"integer":O.elseIf((0,i._)`${L} === "boolean" || ${D} === null
10
+ || (${L} === "string" && ${D} && ${D} == +${D} && !(${D} % 1))`).assign(U,(0,i._)`+${D}`);return;case"boolean":O.elseIf((0,i._)`${D} === "false" || ${D} === 0 || ${D} === null`).assign(U,!1).elseIf((0,i._)`${D} === "true" || ${D} === 1`).assign(U,!0);return;case"null":O.elseIf((0,i._)`${D} === "" || ${D} === 0 || ${D} === false`),O.assign(U,null);return;case"array":O.elseIf((0,i._)`${L} === "string" || ${L} === "number"
11
+ || ${L} === "boolean" || ${D} === null`).assign(U,(0,i._)`[${D}]`)}}}function h({gen:w,parentData:T,parentDataProperty:k},O){w.if((0,i._)`${T} !== undefined`,()=>w.assign((0,i._)`${T}[${k}]`,O))}function d(w,T,k,O=o.Correct){const D=O===o.Correct?i.operators.EQ:i.operators.NEQ;let P;switch(w){case"null":return(0,i._)`${T} ${D} null`;case"array":P=(0,i._)`Array.isArray(${T})`;break;case"object":P=(0,i._)`${T} && typeof ${T} == "object" && !Array.isArray(${T})`;break;case"integer":P=L((0,i._)`!(${T} % 1) && !isNaN(${T})`);break;case"number":P=L();break;default:return(0,i._)`typeof ${T} ${D} ${w}`}return O===o.Correct?P:(0,i.not)(P);function L(U=i.nil){return(0,i.and)((0,i._)`typeof ${T} == "number"`,U,k?(0,i._)`isFinite(${T})`:i.nil)}}e.checkDataType=d;function y(w,T,k,O){if(w.length===1)return d(w[0],T,k,O);let D;const P=(0,s.toHash)(w);if(P.array&&P.object){const L=(0,i._)`typeof ${T} != "object"`;D=P.null?L:(0,i._)`!${T} || ${L}`,delete P.null,delete P.array,delete P.object}else D=i.nil;P.number&&delete P.integer;for(const L in P)D=(0,i.and)(D,d(L,T,k,O));return D}e.checkDataTypes=y;const v={message:({schema:w})=>`must be ${w}`,params:({schema:w,schemaValue:T})=>typeof w=="string"?(0,i._)`{type: ${w}}`:(0,i._)`{type: ${T}}`};function f(w){const T=$(w);(0,n.reportError)(T,v)}e.reportTypeError=f;function $(w){const{gen:T,data:k,schema:O}=w,D=(0,s.schemaRefOrVal)(w,O,"type");return{gen:T,keyword:"type",data:k,schema:O.type,schemaCode:D,schemaValue:D,parentSchema:O,params:{},it:w}}})(Qn);var Zi={};Object.defineProperty(Zi,"__esModule",{value:!0});Zi.assignDefaults=void 0;const xr=ee,tp=fe;function rp(e,t){const{properties:r,items:n}=e.schema;if(t==="object"&&r)for(const i in r)Ka(e,i,r[i].default);else t==="array"&&Array.isArray(n)&&n.forEach((i,s)=>Ka(e,s,i.default))}Zi.assignDefaults=rp;function Ka(e,t,r){const{gen:n,compositeRule:i,data:s,opts:o}=e;if(r===void 0)return;const c=(0,xr._)`${s}${(0,xr.getProperty)(t)}`;if(i){(0,tp.checkStrictMode)(e,`default is ignored for: ${c}`);return}let u=(0,xr._)`${c} === undefined`;o.useDefaults==="empty"&&(u=(0,xr._)`${u} || ${c} === null || ${c} === ""`),n.if(u,(0,xr._)`${c} = ${(0,xr.stringify)(r)}`)}var zt={},re={};Object.defineProperty(re,"__esModule",{value:!0});re.validateUnion=re.validateArray=re.usePattern=re.callValidateCode=re.schemaProperties=re.allSchemaProperties=re.noPropertyInData=re.propertyInData=re.isOwnProperty=re.hasPropFunc=re.reportMissingProp=re.checkMissingProp=re.checkReportMissingProp=void 0;const $e=ee,po=fe,Yt=Vt,np=fe;function ip(e,t){const{gen:r,data:n,it:i}=e;r.if(vo(r,n,t,i.opts.ownProperties),()=>{e.setParams({missingProperty:(0,$e._)`${t}`},!0),e.error()})}re.checkReportMissingProp=ip;function sp({gen:e,data:t,it:{opts:r}},n,i){return(0,$e.or)(...n.map(s=>(0,$e.and)(vo(e,t,s,r.ownProperties),(0,$e._)`${i} = ${s}`)))}re.checkMissingProp=sp;function op(e,t){e.setParams({missingProperty:t},!0),e.error()}re.reportMissingProp=op;function lf(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,$e._)`Object.prototype.hasOwnProperty`})}re.hasPropFunc=lf;function yo(e,t,r){return(0,$e._)`${lf(e)}.call(${t}, ${r})`}re.isOwnProperty=yo;function ap(e,t,r,n){const i=(0,$e._)`${t}${(0,$e.getProperty)(r)} !== undefined`;return n?(0,$e._)`${i} && ${yo(e,t,r)}`:i}re.propertyInData=ap;function vo(e,t,r,n){const i=(0,$e._)`${t}${(0,$e.getProperty)(r)} === undefined`;return n?(0,$e.or)(i,(0,$e.not)(yo(e,t,r))):i}re.noPropertyInData=vo;function df(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}re.allSchemaProperties=df;function cp(e,t){return df(t).filter(r=>!(0,po.alwaysValidSchema)(e,t[r]))}re.schemaProperties=cp;function up({schemaCode:e,data:t,it:{gen:r,topSchemaRef:n,schemaPath:i,errorPath:s},it:o},c,u,m){const a=m?(0,$e._)`${e}, ${t}, ${n}${i}`:t,l=[[Yt.default.instancePath,(0,$e.strConcat)(Yt.default.instancePath,s)],[Yt.default.parentData,o.parentData],[Yt.default.parentDataProperty,o.parentDataProperty],[Yt.default.rootData,Yt.default.rootData]];o.opts.dynamicRef&&l.push([Yt.default.dynamicAnchors,Yt.default.dynamicAnchors]);const E=(0,$e._)`${a}, ${r.object(...l)}`;return u!==$e.nil?(0,$e._)`${c}.call(${u}, ${E})`:(0,$e._)`${c}(${E})`}re.callValidateCode=up;const fp=(0,$e._)`new RegExp`;function lp({gen:e,it:{opts:t}},r){const n=t.unicodeRegExp?"u":"",{regExp:i}=t.code,s=i(r,n);return e.scopeValue("pattern",{key:s.toString(),ref:s,code:(0,$e._)`${i.code==="new RegExp"?fp:(0,np.useFunc)(e,i)}(${r}, ${n})`})}re.usePattern=lp;function dp(e){const{gen:t,data:r,keyword:n,it:i}=e,s=t.name("valid");if(i.allErrors){const c=t.let("valid",!0);return o(()=>t.assign(c,!1)),c}return t.var(s,!0),o(()=>t.break()),s;function o(c){const u=t.const("len",(0,$e._)`${r}.length`);t.forRange("i",0,u,m=>{e.subschema({keyword:n,dataProp:m,dataPropType:po.Type.Num},s),t.if((0,$e.not)(s),c)})}}re.validateArray=dp;function hp(e){const{gen:t,schema:r,keyword:n,it:i}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some(u=>(0,po.alwaysValidSchema)(i,u))&&!i.opts.unevaluated)return;const o=t.let("valid",!1),c=t.name("_valid");t.block(()=>r.forEach((u,m)=>{const a=e.subschema({keyword:n,schemaProp:m,compositeRule:!0},c);t.assign(o,(0,$e._)`${o} || ${c}`),e.mergeValidEvaluated(a,c)||t.if((0,$e.not)(o))})),e.result(o,()=>e.reset(),()=>e.error(!0))}re.validateUnion=hp;Object.defineProperty(zt,"__esModule",{value:!0});zt.validateKeywordUsage=zt.validSchemaType=zt.funcKeywordCode=zt.macroKeywordCode=void 0;const Ye=ee,gr=Vt,mp=re,pp=Yn;function yp(e,t){const{gen:r,keyword:n,schema:i,parentSchema:s,it:o}=e,c=t.macro.call(o.self,i,s,o),u=hf(r,n,c);o.opts.validateSchema!==!1&&o.self.validateSchema(c,!0);const m=r.name("valid");e.subschema({schema:c,schemaPath:Ye.nil,errSchemaPath:`${o.errSchemaPath}/${n}`,topSchemaRef:u,compositeRule:!0},m),e.pass(m,()=>e.error(!0))}zt.macroKeywordCode=yp;function vp(e,t){var r;const{gen:n,keyword:i,schema:s,parentSchema:o,$data:c,it:u}=e;gp(u,t);const m=!c&&t.compile?t.compile.call(u.self,s,o,u):t.validate,a=hf(n,i,m),l=n.let("valid");e.block$data(l,E),e.ok((r=t.valid)!==null&&r!==void 0?r:l);function E(){if(t.errors===!1)y(),t.modifying&&Xa(e),v(()=>e.error());else{const f=t.async?h():d();t.modifying&&Xa(e),v(()=>Ep(e,f))}}function h(){const f=n.let("ruleErrs",null);return n.try(()=>y((0,Ye._)`await `),$=>n.assign(l,!1).if((0,Ye._)`${$} instanceof ${u.ValidationError}`,()=>n.assign(f,(0,Ye._)`${$}.errors`),()=>n.throw($))),f}function d(){const f=(0,Ye._)`${a}.errors`;return n.assign(f,null),y(Ye.nil),f}function y(f=t.async?(0,Ye._)`await `:Ye.nil){const $=u.opts.passContext?gr.default.this:gr.default.self,w=!("compile"in t&&!c||t.schema===!1);n.assign(l,(0,Ye._)`${f}${(0,mp.callValidateCode)(e,a,$,w)}`,t.modifying)}function v(f){var $;n.if((0,Ye.not)(($=t.valid)!==null&&$!==void 0?$:l),f)}}zt.funcKeywordCode=vp;function Xa(e){const{gen:t,data:r,it:n}=e;t.if(n.parentData,()=>t.assign(r,(0,Ye._)`${n.parentData}[${n.parentDataProperty}]`))}function Ep(e,t){const{gen:r}=e;r.if((0,Ye._)`Array.isArray(${t})`,()=>{r.assign(gr.default.vErrors,(0,Ye._)`${gr.default.vErrors} === null ? ${t} : ${gr.default.vErrors}.concat(${t})`).assign(gr.default.errors,(0,Ye._)`${gr.default.vErrors}.length`),(0,pp.extendErrors)(e)},()=>e.error())}function gp({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function hf(e,t,r){if(r===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,Ye.stringify)(r)})}function $p(e,t,r=!1){return!t.length||t.some(n=>n==="array"?Array.isArray(e):n==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==n||r&&typeof e=="undefined")}zt.validSchemaType=$p;function _p({schema:e,opts:t,self:r,errSchemaPath:n},i,s){if(Array.isArray(i.keyword)?!i.keyword.includes(s):i.keyword!==s)throw new Error("ajv implementation error");const o=i.dependencies;if(o==null?void 0:o.some(c=>!Object.prototype.hasOwnProperty.call(e,c)))throw new Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`);if(i.validateSchema&&!i.validateSchema(e[s])){const u=`keyword "${s}" value is invalid at path "${n}": `+r.errorsText(i.validateSchema.errors);if(t.validateSchema==="log")r.logger.error(u);else throw new Error(u)}}zt.validateKeywordUsage=_p;var fr={};Object.defineProperty(fr,"__esModule",{value:!0});fr.extendSubschemaMode=fr.extendSubschemaData=fr.getSubschema=void 0;const kt=ee,mf=fe;function Sp(e,{keyword:t,schemaProp:r,schema:n,schemaPath:i,errSchemaPath:s,topSchemaRef:o}){if(t!==void 0&&n!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){const c=e.schema[t];return r===void 0?{schema:c,schemaPath:(0,kt._)`${e.schemaPath}${(0,kt.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:c[r],schemaPath:(0,kt._)`${e.schemaPath}${(0,kt.getProperty)(t)}${(0,kt.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,mf.escapeFragment)(r)}`}}if(n!==void 0){if(i===void 0||s===void 0||o===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:i,topSchemaRef:o,errSchemaPath:s}}throw new Error('either "keyword" or "schema" must be passed')}fr.getSubschema=Sp;function wp(e,t,{dataProp:r,dataPropType:n,data:i,dataTypes:s,propertyName:o}){if(i!==void 0&&r!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:c}=t;if(r!==void 0){const{errorPath:m,dataPathArr:a,opts:l}=t,E=c.let("data",(0,kt._)`${t.data}${(0,kt.getProperty)(r)}`,!0);u(E),e.errorPath=(0,kt.str)`${m}${(0,mf.getErrorPath)(r,n,l.jsPropertySyntax)}`,e.parentDataProperty=(0,kt._)`${r}`,e.dataPathArr=[...a,e.parentDataProperty]}if(i!==void 0){const m=i instanceof kt.Name?i:c.let("data",i,!0);u(m),o!==void 0&&(e.propertyName=o)}s&&(e.dataTypes=s);function u(m){e.data=m,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,m]}}fr.extendSubschemaData=wp;function Np(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:n,createErrors:i,allErrors:s}){n!==void 0&&(e.compositeRule=n),i!==void 0&&(e.createErrors=i),s!==void 0&&(e.allErrors=s),e.jtdDiscriminator=t,e.jtdMetadata=r}fr.extendSubschemaMode=Np;var Ve={},pf=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var n,i,s;if(Array.isArray(t)){if(n=t.length,n!=r.length)return!1;for(i=n;i--!==0;)if(!e(t[i],r[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(s=Object.keys(t),n=s.length,n!==Object.keys(r).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(r,s[i]))return!1;for(i=n;i--!==0;){var o=s[i];if(!e(t[o],r[o]))return!1}return!0}return t!==t&&r!==r},yf={exports:{}},ur=yf.exports=function(e,t,r){typeof t=="function"&&(r=t,t={}),r=t.cb||r;var n=typeof r=="function"?r:r.pre||function(){},i=r.post||function(){};Si(t,n,i,e,"",e)};ur.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};ur.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};ur.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};ur.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function Si(e,t,r,n,i,s,o,c,u,m){if(n&&typeof n=="object"&&!Array.isArray(n)){t(n,i,s,o,c,u,m);for(var a in n){var l=n[a];if(Array.isArray(l)){if(a in ur.arrayKeywords)for(var E=0;E<l.length;E++)Si(e,t,r,l[E],i+"/"+a+"/"+E,s,i,a,n,E)}else if(a in ur.propsKeywords){if(l&&typeof l=="object")for(var h in l)Si(e,t,r,l[h],i+"/"+a+"/"+Ip(h),s,i,a,n,h)}else(a in ur.keywords||e.allKeys&&!(a in ur.skipKeywords))&&Si(e,t,r,l,i+"/"+a,s,i,a,n)}r(n,i,s,o,c,u,m)}}function Ip(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}Object.defineProperty(Ve,"__esModule",{value:!0});Ve.getSchemaRefs=Ve.resolveUrl=Ve.normalizeId=Ve._getFullPath=Ve.getFullPath=Ve.inlineRef=void 0;const Op=fe,Tp=pf,Dp=yf.exports,Rp=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function Cp(e,t=!0){return typeof e=="boolean"?!0:t===!0?!Ms(e):t?vf(e)<=t:!1}Ve.inlineRef=Cp;const Pp=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Ms(e){for(const t in e){if(Pp.has(t))return!0;const r=e[t];if(Array.isArray(r)&&r.some(Ms)||typeof r=="object"&&Ms(r))return!0}return!1}function vf(e){let t=0;for(const r in e){if(r==="$ref")return 1/0;if(t++,!Rp.has(r)&&(typeof e[r]=="object"&&(0,Op.eachItem)(e[r],n=>t+=vf(n)),t===1/0))return 1/0}return t}function Ef(e,t="",r){r!==!1&&(t=Xr(t));const n=e.parse(t);return gf(e,n)}Ve.getFullPath=Ef;function gf(e,t){return e.serialize(t).split("#")[0]+"#"}Ve._getFullPath=gf;const Ap=/#\/?$/;function Xr(e){return e?e.replace(Ap,""):""}Ve.normalizeId=Xr;function bp(e,t,r){return r=Xr(r),e.resolve(t,r)}Ve.resolveUrl=bp;const Lp=/^[a-z_][-a-z0-9._]*$/i;function Fp(e,t){if(typeof e=="boolean")return{};const{schemaId:r,uriResolver:n}=this.opts,i=Xr(e[r]||t),s={"":i},o=Ef(n,i,!1),c={},u=new Set;return Dp(e,{allKeys:!0},(l,E,h,d)=>{if(d===void 0)return;const y=o+E;let v=s[d];typeof l[r]=="string"&&(v=f.call(this,l[r])),$.call(this,l.$anchor),$.call(this,l.$dynamicAnchor),s[E]=v;function f(w){const T=this.opts.uriResolver.resolve;if(w=Xr(v?T(v,w):w),u.has(w))throw a(w);u.add(w);let k=this.refs[w];return typeof k=="string"&&(k=this.refs[k]),typeof k=="object"?m(l,k.schema,w):w!==Xr(y)&&(w[0]==="#"?(m(l,c[w],w),c[w]=l):this.refs[w]=y),w}function $(w){if(typeof w=="string"){if(!Lp.test(w))throw new Error(`invalid anchor "${w}"`);f.call(this,`#${w}`)}}}),c;function m(l,E,h){if(E!==void 0&&!Tp(l,E))throw a(h)}function a(l){return new Error(`reference "${l}" resolves to more than one schema`)}}Ve.getSchemaRefs=Fp;Object.defineProperty(Tt,"__esModule",{value:!0});Tt.getData=Tt.KeywordCxt=Tt.validateFunctionCode=void 0;const $f=sn,Za=Qn,Eo=Kt,bi=Qn,jp=Zi,Pn=zt,vs=fr,H=ee,W=Vt,Mp=Ve,Xt=fe,_n=Yn;function kp(e){if(wf(e)&&(Nf(e),Sf(e))){xp(e);return}_f(e,()=>(0,$f.topBoolOrEmptySchema)(e))}Tt.validateFunctionCode=kp;function _f({gen:e,validateName:t,schema:r,schemaEnv:n,opts:i},s){i.code.es5?e.func(t,(0,H._)`${W.default.data}, ${W.default.valCxt}`,n.$async,()=>{e.code((0,H._)`"use strict"; ${Wa(r,i)}`),zp(e,i),e.code(s)}):e.func(t,(0,H._)`${W.default.data}, ${Up(i)}`,n.$async,()=>e.code(Wa(r,i)).code(s))}function Up(e){return(0,H._)`{${W.default.instancePath}="", ${W.default.parentData}, ${W.default.parentDataProperty}, ${W.default.rootData}=${W.default.data}${e.dynamicRef?(0,H._)`, ${W.default.dynamicAnchors}={}`:H.nil}}={}`}function zp(e,t){e.if(W.default.valCxt,()=>{e.var(W.default.instancePath,(0,H._)`${W.default.valCxt}.${W.default.instancePath}`),e.var(W.default.parentData,(0,H._)`${W.default.valCxt}.${W.default.parentData}`),e.var(W.default.parentDataProperty,(0,H._)`${W.default.valCxt}.${W.default.parentDataProperty}`),e.var(W.default.rootData,(0,H._)`${W.default.valCxt}.${W.default.rootData}`),t.dynamicRef&&e.var(W.default.dynamicAnchors,(0,H._)`${W.default.valCxt}.${W.default.dynamicAnchors}`)},()=>{e.var(W.default.instancePath,(0,H._)`""`),e.var(W.default.parentData,(0,H._)`undefined`),e.var(W.default.parentDataProperty,(0,H._)`undefined`),e.var(W.default.rootData,W.default.data),t.dynamicRef&&e.var(W.default.dynamicAnchors,(0,H._)`{}`)})}function xp(e){const{schema:t,opts:r,gen:n}=e;_f(e,()=>{r.$comment&&t.$comment&&Of(e),Hp(e),n.let(W.default.vErrors,null),n.let(W.default.errors,0),r.unevaluated&&Vp(e),If(e),Zp(e)})}function Vp(e){const{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",(0,H._)`${r}.evaluated`),t.if((0,H._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,H._)`${e.evaluated}.props`,(0,H._)`undefined`)),t.if((0,H._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,H._)`${e.evaluated}.items`,(0,H._)`undefined`))}function Wa(e,t){const r=typeof e=="object"&&e[t.schemaId];return r&&(t.code.source||t.code.process)?(0,H._)`/*# sourceURL=${r} */`:H.nil}function qp(e,t){if(wf(e)&&(Nf(e),Sf(e))){Gp(e,t);return}(0,$f.boolOrEmptySchema)(e,t)}function Sf({schema:e,self:t}){if(typeof e=="boolean")return!e;for(const r in e)if(t.RULES.all[r])return!0;return!1}function wf(e){return typeof e.schema!="boolean"}function Gp(e,t){const{schema:r,gen:n,opts:i}=e;i.$comment&&r.$comment&&Of(e),Kp(e),Xp(e);const s=n.const("_errs",W.default.errors);If(e,s),n.var(t,(0,H._)`${s} === ${W.default.errors}`)}function Nf(e){(0,Xt.checkUnknownRules)(e),Bp(e)}function If(e,t){if(e.opts.jtd)return Ja(e,[],!1,t);const r=(0,Za.getSchemaTypes)(e.schema),n=(0,Za.coerceAndCheckDataType)(e,r);Ja(e,r,!n,t)}function Bp(e){const{schema:t,errSchemaPath:r,opts:n,self:i}=e;t.$ref&&n.ignoreKeywordsWithRef&&(0,Xt.schemaHasRulesButRef)(t,i.RULES)&&i.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function Hp(e){const{schema:t,opts:r}=e;t.default!==void 0&&r.useDefaults&&r.strictSchema&&(0,Xt.checkStrictMode)(e,"default is ignored in the schema root")}function Kp(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,Mp.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function Xp(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function Of({gen:e,schemaEnv:t,schema:r,errSchemaPath:n,opts:i}){const s=r.$comment;if(i.$comment===!0)e.code((0,H._)`${W.default.self}.logger.log(${s})`);else if(typeof i.$comment=="function"){const o=(0,H.str)`${n}/$comment`,c=e.scopeValue("root",{ref:t.root});e.code((0,H._)`${W.default.self}.opts.$comment(${s}, ${o}, ${c}.schema)`)}}function Zp(e){const{gen:t,schemaEnv:r,validateName:n,ValidationError:i,opts:s}=e;r.$async?t.if((0,H._)`${W.default.errors} === 0`,()=>t.return(W.default.data),()=>t.throw((0,H._)`new ${i}(${W.default.vErrors})`)):(t.assign((0,H._)`${n}.errors`,W.default.vErrors),s.unevaluated&&Wp(e),t.return((0,H._)`${W.default.errors} === 0`))}function Wp({gen:e,evaluated:t,props:r,items:n}){r instanceof H.Name&&e.assign((0,H._)`${t}.props`,r),n instanceof H.Name&&e.assign((0,H._)`${t}.items`,n)}function Ja(e,t,r,n){const{gen:i,schema:s,data:o,allErrors:c,opts:u,self:m}=e,{RULES:a}=m;if(s.$ref&&(u.ignoreKeywordsWithRef||!(0,Xt.schemaHasRulesButRef)(s,a))){i.block(()=>Df(e,"$ref",a.all.$ref.definition));return}u.jtd||Jp(e,t),i.block(()=>{for(const E of a.rules)l(E);l(a.post)});function l(E){!(0,Eo.shouldUseGroup)(s,E)||(E.type?(i.if((0,bi.checkDataType)(E.type,o,u.strictNumbers)),Ya(e,E),t.length===1&&t[0]===E.type&&r&&(i.else(),(0,bi.reportTypeError)(e)),i.endIf()):Ya(e,E),c||i.if((0,H._)`${W.default.errors} === ${n||0}`))}}function Ya(e,t){const{gen:r,schema:n,opts:{useDefaults:i}}=e;i&&(0,jp.assignDefaults)(e,t.type),r.block(()=>{for(const s of t.rules)(0,Eo.shouldUseRule)(n,s)&&Df(e,s.keyword,s.definition,t.type)})}function Jp(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(Yp(e,t),e.opts.allowUnionTypes||Qp(e,t),ey(e,e.dataTypes))}function Yp(e,t){if(!!t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(r=>{Qa(e.dataTypes,r)||go(e,`type "${r}" not allowed by context "${e.dataTypes.join(",")}"`)}),e.dataTypes=e.dataTypes.filter(r=>Qa(t,r))}}function Qp(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&go(e,"use allowUnionTypes to allow union type keyword")}function ey(e,t){const r=e.self.RULES.all;for(const n in r){const i=r[n];if(typeof i=="object"&&(0,Eo.shouldUseRule)(e.schema,i)){const{type:s}=i.definition;s.length&&!s.some(o=>ty(t,o))&&go(e,`missing type "${s.join(",")}" for keyword "${n}"`)}}}function ty(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function Qa(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function go(e,t){t+=` at "${e.schemaEnv.baseId+e.errSchemaPath}" (strictTypes)`,(0,Xt.checkStrictMode)(e,t,e.opts.strictTypes)}class Tf{constructor(t,r,n){if((0,Pn.validateKeywordUsage)(t,r,n),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=n,this.data=t.data,this.schema=t.schema[n],this.$data=r.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,Xt.schemaRefOrVal)(t,this.schema,n,this.$data),this.schemaType=r.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=r,this.$data)this.schemaCode=t.gen.const("vSchema",Rf(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,Pn.validSchemaType)(this.schema,r.schemaType,r.allowUndefined))throw new Error(`${n} value must be ${JSON.stringify(r.schemaType)}`);("code"in r?r.trackErrors:r.errors!==!1)&&(this.errsCount=t.gen.const("_errs",W.default.errors))}result(t,r,n){this.failResult((0,H.not)(t),r,n)}failResult(t,r,n){this.gen.if(t),n?n():this.error(),r?(this.gen.else(),r(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,r){this.failResult((0,H.not)(t),void 0,r)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);const{schemaCode:r}=this;this.fail((0,H._)`${r} !== undefined && (${(0,H.or)(this.invalid$data(),t)})`)}error(t,r,n){if(r){this.setParams(r),this._error(t,n),this.setParams({});return}this._error(t,n)}_error(t,r){(t?_n.reportExtraError:_n.reportError)(this,this.def.error,r)}$dataError(){(0,_n.reportError)(this,this.def.$dataError||_n.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,_n.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,r){r?Object.assign(this.params,t):this.params=t}block$data(t,r,n=H.nil){this.gen.block(()=>{this.check$data(t,n),r()})}check$data(t=H.nil,r=H.nil){if(!this.$data)return;const{gen:n,schemaCode:i,schemaType:s,def:o}=this;n.if((0,H.or)((0,H._)`${i} === undefined`,r)),t!==H.nil&&n.assign(t,!0),(s.length||o.validateSchema)&&(n.elseIf(this.invalid$data()),this.$dataError(),t!==H.nil&&n.assign(t,!1)),n.else()}invalid$data(){const{gen:t,schemaCode:r,schemaType:n,def:i,it:s}=this;return(0,H.or)(o(),c());function o(){if(n.length){if(!(r instanceof H.Name))throw new Error("ajv implementation error");const u=Array.isArray(n)?n:[n];return(0,H._)`${(0,bi.checkDataTypes)(u,r,s.opts.strictNumbers,bi.DataType.Wrong)}`}return H.nil}function c(){if(i.validateSchema){const u=t.scopeValue("validate$data",{ref:i.validateSchema});return(0,H._)`!${u}(${r})`}return H.nil}}subschema(t,r){const n=(0,vs.getSubschema)(this.it,t);(0,vs.extendSubschemaData)(n,this.it,t),(0,vs.extendSubschemaMode)(n,t);const i=vt(Q(Q({},this.it),n),{items:void 0,props:void 0});return qp(i,r),i}mergeEvaluated(t,r){const{it:n,gen:i}=this;!n.opts.unevaluated||(n.props!==!0&&t.props!==void 0&&(n.props=Xt.mergeEvaluated.props(i,t.props,n.props,r)),n.items!==!0&&t.items!==void 0&&(n.items=Xt.mergeEvaluated.items(i,t.items,n.items,r)))}mergeValidEvaluated(t,r){const{it:n,gen:i}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return i.if(r,()=>this.mergeEvaluated(t,H.Name)),!0}}Tt.KeywordCxt=Tf;function Df(e,t,r,n){const i=new Tf(e,r,t);"code"in r?r.code(i,n):i.$data&&r.validate?(0,Pn.funcKeywordCode)(i,r):"macro"in r?(0,Pn.macroKeywordCode)(i,r):(r.compile||r.validate)&&(0,Pn.funcKeywordCode)(i,r)}const ry=/^\/(?:[^~]|~0|~1)*$/,ny=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Rf(e,{dataLevel:t,dataNames:r,dataPathArr:n}){let i,s;if(e==="")return W.default.rootData;if(e[0]==="/"){if(!ry.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);i=e,s=W.default.rootData}else{const m=ny.exec(e);if(!m)throw new Error(`Invalid JSON-pointer: ${e}`);const a=+m[1];if(i=m[2],i==="#"){if(a>=t)throw new Error(u("property/index",a));return n[t-a]}if(a>t)throw new Error(u("data",a));if(s=r[t-a],!i)return s}let o=s;const c=i.split("/");for(const m of c)m&&(s=(0,H._)`${s}${(0,H.getProperty)((0,Xt.unescapeJsonPointer)(m))}`,o=(0,H._)`${o} && ${s}`);return o;function u(m,a){return`Cannot access ${m} ${a} levels up, current level is ${t}`}}Tt.getData=Rf;var Wi={};Object.defineProperty(Wi,"__esModule",{value:!0});class iy extends Error{constructor(t){super("validation failed");this.errors=t,this.ajv=this.validation=!0}}Wi.default=iy;var Ji={};Object.defineProperty(Ji,"__esModule",{value:!0});const Es=Ve;class sy extends Error{constructor(t,r,n,i){super(i||`can't resolve reference ${n} from id ${r}`);this.missingRef=(0,Es.resolveUrl)(t,r,n),this.missingSchema=(0,Es.normalizeId)((0,Es.getFullPath)(t,this.missingRef))}}Ji.default=sy;var at={};Object.defineProperty(at,"__esModule",{value:!0});at.resolveSchema=at.getCompilingSchema=at.resolveRef=at.compileSchema=at.SchemaEnv=void 0;const gt=ee,oy=Wi,vr=Vt,Ot=Ve,ec=fe,ay=Tt;class Yi{constructor(t){var r;this.refs={},this.dynamicAnchors={};let n;typeof t.schema=="object"&&(n=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(r=t.baseId)!==null&&r!==void 0?r:(0,Ot.normalizeId)(n==null?void 0:n[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=n==null?void 0:n.$async,this.refs={}}}at.SchemaEnv=Yi;function $o(e){const t=Cf.call(this,e);if(t)return t;const r=(0,Ot.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:n,lines:i}=this.opts.code,{ownProperties:s}=this.opts,o=new gt.CodeGen(this.scope,{es5:n,lines:i,ownProperties:s});let c;e.$async&&(c=o.scopeValue("Error",{ref:oy.default,code:(0,gt._)`require("ajv/dist/runtime/validation_error").default`}));const u=o.scopeName("validate");e.validateName=u;const m={gen:o,allErrors:this.opts.allErrors,data:vr.default.data,parentData:vr.default.parentData,parentDataProperty:vr.default.parentDataProperty,dataNames:[vr.default.data],dataPathArr:[gt.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:o.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,gt.stringify)(e.schema)}:{ref:e.schema}),validateName:u,ValidationError:c,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:gt.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,gt._)`""`,opts:this.opts,self:this};let a;try{this._compilations.add(e),(0,ay.validateFunctionCode)(m),o.optimize(this.opts.code.optimize);const l=o.toString();a=`${o.scopeRefs(vr.default.scope)}return ${l}`,this.opts.code.process&&(a=this.opts.code.process(a,e));const h=new Function(`${vr.default.self}`,`${vr.default.scope}`,a)(this,this.scope.get());if(this.scope.value(u,{ref:h}),h.errors=null,h.schema=e.schema,h.schemaEnv=e,e.$async&&(h.$async=!0),this.opts.code.source===!0&&(h.source={validateName:u,validateCode:l,scopeValues:o._values}),this.opts.unevaluated){const{props:d,items:y}=m;h.evaluated={props:d instanceof gt.Name?void 0:d,items:y instanceof gt.Name?void 0:y,dynamicProps:d instanceof gt.Name,dynamicItems:y instanceof gt.Name},h.source&&(h.source.evaluated=(0,gt.stringify)(h.evaluated))}return e.validate=h,e}catch(l){throw delete e.validate,delete e.validateName,a&&this.logger.error("Error compiling schema, function code:",a),l}finally{this._compilations.delete(e)}}at.compileSchema=$o;function cy(e,t,r){var n;r=(0,Ot.resolveUrl)(this.opts.uriResolver,t,r);const i=e.refs[r];if(i)return i;let s=ly.call(this,e,r);if(s===void 0){const o=(n=e.localRefs)===null||n===void 0?void 0:n[r],{schemaId:c}=this.opts;o&&(s=new Yi({schema:o,schemaId:c,root:e,baseId:t}))}if(s!==void 0)return e.refs[r]=uy.call(this,s)}at.resolveRef=cy;function uy(e){return(0,Ot.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:$o.call(this,e)}function Cf(e){for(const t of this._compilations)if(fy(t,e))return t}at.getCompilingSchema=Cf;function fy(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function ly(e,t){let r;for(;typeof(r=this.refs[t])=="string";)t=r;return r||this.schemas[t]||Qi.call(this,e,t)}function Qi(e,t){const r=this.opts.uriResolver.parse(t),n=(0,Ot._getFullPath)(this.opts.uriResolver,r);let i=(0,Ot.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&n===i)return gs.call(this,r,e);const s=(0,Ot.normalizeId)(n),o=this.refs[s]||this.schemas[s];if(typeof o=="string"){const c=Qi.call(this,e,o);return typeof(c==null?void 0:c.schema)!="object"?void 0:gs.call(this,r,c)}if(typeof(o==null?void 0:o.schema)=="object"){if(o.validate||$o.call(this,o),s===(0,Ot.normalizeId)(t)){const{schema:c}=o,{schemaId:u}=this.opts,m=c[u];return m&&(i=(0,Ot.resolveUrl)(this.opts.uriResolver,i,m)),new Yi({schema:c,schemaId:u,root:e,baseId:i})}return gs.call(this,r,o)}}at.resolveSchema=Qi;const dy=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function gs(e,{baseId:t,schema:r,root:n}){var i;if(((i=e.fragment)===null||i===void 0?void 0:i[0])!=="/")return;for(const c of e.fragment.slice(1).split("/")){if(typeof r=="boolean")return;const u=r[(0,ec.unescapeFragment)(c)];if(u===void 0)return;r=u;const m=typeof r=="object"&&r[this.opts.schemaId];!dy.has(c)&&m&&(t=(0,Ot.resolveUrl)(this.opts.uriResolver,t,m))}let s;if(typeof r!="boolean"&&r.$ref&&!(0,ec.schemaHasRulesButRef)(r,this.RULES)){const c=(0,Ot.resolveUrl)(this.opts.uriResolver,t,r.$ref);s=Qi.call(this,n,c)}const{schemaId:o}=this.opts;if(s=s||new Yi({schema:r,schemaId:o,root:n,baseId:t}),s.schema!==s.root.schema)return s}const hy="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",my="Meta-schema for $data reference (JSON AnySchema extension proposal)",py="object",yy=["$data"],vy={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},Ey=!1;var gy={$id:hy,description:my,type:py,required:yy,properties:vy,additionalProperties:Ey},_o={},ks={exports:{}};/** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */(function(e,t){(function(r,n){n(t)})(ir,function(r){function n(){for(var S=arguments.length,g=Array(S),N=0;N<S;N++)g[N]=arguments[N];if(g.length>1){g[0]=g[0].slice(0,-1);for(var b=g.length-1,A=1;A<b;++A)g[A]=g[A].slice(1,-1);return g[b]=g[b].slice(1),g.join("")}else return g[0]}function i(S){return"(?:"+S+")"}function s(S){return S===void 0?"undefined":S===null?"null":Object.prototype.toString.call(S).split(" ").pop().split("]").shift().toLowerCase()}function o(S){return S.toUpperCase()}function c(S){return S!=null?S instanceof Array?S:typeof S.length!="number"||S.split||S.setInterval||S.call?[S]:Array.prototype.slice.call(S):[]}function u(S,g){var N=S;if(g)for(var b in g)N[b]=g[b];return N}function m(S){var g="[A-Za-z]",N="[0-9]",b=n(N,"[A-Fa-f]"),A=i(i("%[EFef]"+b+"%"+b+b+"%"+b+b)+"|"+i("%[89A-Fa-f]"+b+"%"+b+b)+"|"+i("%"+b+b)),K="[\\:\\/\\?\\#\\[\\]\\@]",X="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",ue=n(K,X),ge=S?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",Te=S?"[\\uE000-\\uF8FF]":"[]",se=n(g,N,"[\\-\\.\\_\\~]",ge);i(g+n(g,N,"[\\+\\-\\.]")+"*"),i(i(A+"|"+n(se,X,"[\\:]"))+"*");var ve=i(i("25[0-5]")+"|"+i("2[0-4]"+N)+"|"+i("1"+N+N)+"|"+i("0?[1-9]"+N)+"|0?0?"+N),De=i(ve+"\\."+ve+"\\."+ve+"\\."+ve),Y=i(b+"{1,4}"),_e=i(i(Y+"\\:"+Y)+"|"+De),Pe=i(i(Y+"\\:")+"{6}"+_e),Se=i("\\:\\:"+i(Y+"\\:")+"{5}"+_e),Wt=i(i(Y)+"?\\:\\:"+i(Y+"\\:")+"{4}"+_e),Lt=i(i(i(Y+"\\:")+"{0,1}"+Y)+"?\\:\\:"+i(Y+"\\:")+"{3}"+_e),Ft=i(i(i(Y+"\\:")+"{0,2}"+Y)+"?\\:\\:"+i(Y+"\\:")+"{2}"+_e),kr=i(i(i(Y+"\\:")+"{0,3}"+Y)+"?\\:\\:"+Y+"\\:"+_e),mr=i(i(i(Y+"\\:")+"{0,4}"+Y)+"?\\:\\:"+_e),pt=i(i(i(Y+"\\:")+"{0,5}"+Y)+"?\\:\\:"+Y),jt=i(i(i(Y+"\\:")+"{0,6}"+Y)+"?\\:\\:"),pr=i([Pe,Se,Wt,Lt,Ft,kr,mr,pt,jt].join("|")),qt=i(i(se+"|"+A)+"+");i("[vV]"+b+"+\\."+n(se,X,"[\\:]")+"+"),i(i(A+"|"+n(se,X))+"*");var gn=i(A+"|"+n(se,X,"[\\:\\@]"));return i(i(A+"|"+n(se,X,"[\\@]"))+"+"),i(i(gn+"|"+n("[\\/\\?]",Te))+"*"),{NOT_SCHEME:new RegExp(n("[^]",g,N,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(n("[^\\%\\:]",se,X),"g"),NOT_HOST:new RegExp(n("[^\\%\\[\\]\\:]",se,X),"g"),NOT_PATH:new RegExp(n("[^\\%\\/\\:\\@]",se,X),"g"),NOT_PATH_NOSCHEME:new RegExp(n("[^\\%\\/\\@]",se,X),"g"),NOT_QUERY:new RegExp(n("[^\\%]",se,X,"[\\:\\@\\/\\?]",Te),"g"),NOT_FRAGMENT:new RegExp(n("[^\\%]",se,X,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(n("[^]",se,X),"g"),UNRESERVED:new RegExp(se,"g"),OTHER_CHARS:new RegExp(n("[^\\%]",se,ue),"g"),PCT_ENCODED:new RegExp(A,"g"),IPV4ADDRESS:new RegExp("^("+De+")$"),IPV6ADDRESS:new RegExp("^\\[?("+pr+")"+i(i("\\%25|\\%(?!"+b+"{2})")+"("+qt+")")+"?\\]?$")}}var a=m(!1),l=m(!0),E=function(){function S(g,N){var b=[],A=!0,K=!1,X=void 0;try{for(var ue=g[Symbol.iterator](),ge;!(A=(ge=ue.next()).done)&&(b.push(ge.value),!(N&&b.length===N));A=!0);}catch(Te){K=!0,X=Te}finally{try{!A&&ue.return&&ue.return()}finally{if(K)throw X}}return b}return function(g,N){if(Array.isArray(g))return g;if(Symbol.iterator in Object(g))return S(g,N);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(S){if(Array.isArray(S)){for(var g=0,N=Array(S.length);g<S.length;g++)N[g]=S[g];return N}else return Array.from(S)},d=2147483647,y=36,v=1,f=26,$=38,w=700,T=72,k=128,O="-",D=/^xn--/,P=/[^\0-\x7E]/,L=/[\x2E\u3002\uFF0E\uFF61]/g,U={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},B=y-v,z=Math.floor,J=String.fromCharCode;function Z(S){throw new RangeError(U[S])}function le(S,g){for(var N=[],b=S.length;b--;)N[b]=g(S[b]);return N}function te(S,g){var N=S.split("@"),b="";N.length>1&&(b=N[0]+"@",S=N[1]),S=S.replace(L,".");var A=S.split("."),K=le(A,g).join(".");return b+K}function ne(S){for(var g=[],N=0,b=S.length;N<b;){var A=S.charCodeAt(N++);if(A>=55296&&A<=56319&&N<b){var K=S.charCodeAt(N++);(K&64512)==56320?g.push(((A&1023)<<10)+(K&1023)+65536):(g.push(A),N--)}else g.push(A)}return g}var j=function(g){return String.fromCodePoint.apply(String,h(g))},x=function(g){return g-48<10?g-22:g-65<26?g-65:g-97<26?g-97:y},C=function(g,N){return g+22+75*(g<26)-((N!=0)<<5)},I=function(g,N,b){var A=0;for(g=b?z(g/w):g>>1,g+=z(g/N);g>B*f>>1;A+=y)g=z(g/B);return z(A+(B+1)*g/(g+$))},M=function(g){var N=[],b=g.length,A=0,K=k,X=T,ue=g.lastIndexOf(O);ue<0&&(ue=0);for(var ge=0;ge<ue;++ge)g.charCodeAt(ge)>=128&&Z("not-basic"),N.push(g.charCodeAt(ge));for(var Te=ue>0?ue+1:0;Te<b;){for(var se=A,ve=1,De=y;;De+=y){Te>=b&&Z("invalid-input");var Y=x(g.charCodeAt(Te++));(Y>=y||Y>z((d-A)/ve))&&Z("overflow"),A+=Y*ve;var _e=De<=X?v:De>=X+f?f:De-X;if(Y<_e)break;var Pe=y-_e;ve>z(d/Pe)&&Z("overflow"),ve*=Pe}var Se=N.length+1;X=I(A-se,Se,se==0),z(A/Se)>d-K&&Z("overflow"),K+=z(A/Se),A%=Se,N.splice(A++,0,K)}return String.fromCodePoint.apply(String,N)},R=function(g){var N=[];g=ne(g);var b=g.length,A=k,K=0,X=T,ue=!0,ge=!1,Te=void 0;try{for(var se=g[Symbol.iterator](),ve;!(ue=(ve=se.next()).done);ue=!0){var De=ve.value;De<128&&N.push(J(De))}}catch($n){ge=!0,Te=$n}finally{try{!ue&&se.return&&se.return()}finally{if(ge)throw Te}}var Y=N.length,_e=Y;for(Y&&N.push(O);_e<b;){var Pe=d,Se=!0,Wt=!1,Lt=void 0;try{for(var Ft=g[Symbol.iterator](),kr;!(Se=(kr=Ft.next()).done);Se=!0){var mr=kr.value;mr>=A&&mr<Pe&&(Pe=mr)}}catch($n){Wt=!0,Lt=$n}finally{try{!Se&&Ft.return&&Ft.return()}finally{if(Wt)throw Lt}}var pt=_e+1;Pe-A>z((d-K)/pt)&&Z("overflow"),K+=(Pe-A)*pt,A=Pe;var jt=!0,pr=!1,qt=void 0;try{for(var gn=g[Symbol.iterator](),va;!(jt=(va=gn.next()).done);jt=!0){var Ea=va.value;if(Ea<A&&++K>d&&Z("overflow"),Ea==A){for(var ri=K,ni=y;;ni+=y){var ii=ni<=X?v:ni>=X+f?f:ni-X;if(ri<ii)break;var ga=ri-ii,$a=y-ii;N.push(J(C(ii+ga%$a,0))),ri=z(ga/$a)}N.push(J(C(ri,0))),X=I(K,pt,_e==Y),K=0,++_e}}}catch($n){pr=!0,qt=$n}finally{try{!jt&&gn.return&&gn.return()}finally{if(pr)throw qt}}++K,++A}return N.join("")},p=function(g){return te(g,function(N){return D.test(N)?M(N.slice(4).toLowerCase()):N})},_=function(g){return te(g,function(N){return P.test(N)?"xn--"+R(N):N})},F={version:"2.1.0",ucs2:{decode:ne,encode:j},decode:M,encode:R,toASCII:_,toUnicode:p},V={};function q(S){var g=S.charCodeAt(0),N=void 0;return g<16?N="%0"+g.toString(16).toUpperCase():g<128?N="%"+g.toString(16).toUpperCase():g<2048?N="%"+(g>>6|192).toString(16).toUpperCase()+"%"+(g&63|128).toString(16).toUpperCase():N="%"+(g>>12|224).toString(16).toUpperCase()+"%"+(g>>6&63|128).toString(16).toUpperCase()+"%"+(g&63|128).toString(16).toUpperCase(),N}function ie(S){for(var g="",N=0,b=S.length;N<b;){var A=parseInt(S.substr(N+1,2),16);if(A<128)g+=String.fromCharCode(A),N+=3;else if(A>=194&&A<224){if(b-N>=6){var K=parseInt(S.substr(N+4,2),16);g+=String.fromCharCode((A&31)<<6|K&63)}else g+=S.substr(N,6);N+=6}else if(A>=224){if(b-N>=9){var X=parseInt(S.substr(N+4,2),16),ue=parseInt(S.substr(N+7,2),16);g+=String.fromCharCode((A&15)<<12|(X&63)<<6|ue&63)}else g+=S.substr(N,9);N+=9}else g+=S.substr(N,3),N+=3}return g}function ae(S,g){function N(b){var A=ie(b);return A.match(g.UNRESERVED)?A:b}return S.scheme&&(S.scheme=String(S.scheme).replace(g.PCT_ENCODED,N).toLowerCase().replace(g.NOT_SCHEME,"")),S.userinfo!==void 0&&(S.userinfo=String(S.userinfo).replace(g.PCT_ENCODED,N).replace(g.NOT_USERINFO,q).replace(g.PCT_ENCODED,o)),S.host!==void 0&&(S.host=String(S.host).replace(g.PCT_ENCODED,N).toLowerCase().replace(g.NOT_HOST,q).replace(g.PCT_ENCODED,o)),S.path!==void 0&&(S.path=String(S.path).replace(g.PCT_ENCODED,N).replace(S.scheme?g.NOT_PATH:g.NOT_PATH_NOSCHEME,q).replace(g.PCT_ENCODED,o)),S.query!==void 0&&(S.query=String(S.query).replace(g.PCT_ENCODED,N).replace(g.NOT_QUERY,q).replace(g.PCT_ENCODED,o)),S.fragment!==void 0&&(S.fragment=String(S.fragment).replace(g.PCT_ENCODED,N).replace(g.NOT_FRAGMENT,q).replace(g.PCT_ENCODED,o)),S}function Oe(S){return S.replace(/^0*(.*)/,"$1")||"0"}function Pt(S,g){var N=S.match(g.IPV4ADDRESS)||[],b=E(N,2),A=b[1];return A?A.split(".").map(Oe).join("."):S}function Ar(S,g){var N=S.match(g.IPV6ADDRESS)||[],b=E(N,3),A=b[1],K=b[2];if(A){for(var X=A.toLowerCase().split("::").reverse(),ue=E(X,2),ge=ue[0],Te=ue[1],se=Te?Te.split(":").map(Oe):[],ve=ge.split(":").map(Oe),De=g.IPV4ADDRESS.test(ve[ve.length-1]),Y=De?7:8,_e=ve.length-Y,Pe=Array(Y),Se=0;Se<Y;++Se)Pe[Se]=se[Se]||ve[_e+Se]||"";De&&(Pe[Y-1]=Pt(Pe[Y-1],g));var Wt=Pe.reduce(function(pt,jt,pr){if(!jt||jt==="0"){var qt=pt[pt.length-1];qt&&qt.index+qt.length===pr?qt.length++:pt.push({index:pr,length:1})}return pt},[]),Lt=Wt.sort(function(pt,jt){return jt.length-pt.length})[0],Ft=void 0;if(Lt&&Lt.length>1){var kr=Pe.slice(0,Lt.index),mr=Pe.slice(Lt.index+Lt.length);Ft=kr.join(":")+"::"+mr.join(":")}else Ft=Pe.join(":");return K&&(Ft+="%"+K),Ft}else return S}var dn=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,hn="".match(/(){0}/)[1]===void 0;function ut(S){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},N={},b=g.iri!==!1?l:a;g.reference==="suffix"&&(S=(g.scheme?g.scheme+":":"")+"//"+S);var A=S.match(dn);if(A){hn?(N.scheme=A[1],N.userinfo=A[3],N.host=A[4],N.port=parseInt(A[5],10),N.path=A[6]||"",N.query=A[7],N.fragment=A[8],isNaN(N.port)&&(N.port=A[5])):(N.scheme=A[1]||void 0,N.userinfo=S.indexOf("@")!==-1?A[3]:void 0,N.host=S.indexOf("//")!==-1?A[4]:void 0,N.port=parseInt(A[5],10),N.path=A[6]||"",N.query=S.indexOf("?")!==-1?A[7]:void 0,N.fragment=S.indexOf("#")!==-1?A[8]:void 0,isNaN(N.port)&&(N.port=S.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?A[4]:void 0)),N.host&&(N.host=Ar(Pt(N.host,b),b)),N.scheme===void 0&&N.userinfo===void 0&&N.host===void 0&&N.port===void 0&&!N.path&&N.query===void 0?N.reference="same-document":N.scheme===void 0?N.reference="relative":N.fragment===void 0?N.reference="absolute":N.reference="uri",g.reference&&g.reference!=="suffix"&&g.reference!==N.reference&&(N.error=N.error||"URI is not a "+g.reference+" reference.");var K=V[(g.scheme||N.scheme||"").toLowerCase()];if(!g.unicodeSupport&&(!K||!K.unicodeSupport)){if(N.host&&(g.domainHost||K&&K.domainHost))try{N.host=F.toASCII(N.host.replace(b.PCT_ENCODED,ie).toLowerCase())}catch(X){N.error=N.error||"Host's domain name can not be converted to ASCII via punycode: "+X}ae(N,a)}else ae(N,b);K&&K.parse&&K.parse(N,g)}else N.error=N.error||"URI can not be parsed.";return N}function mn(S,g){var N=g.iri!==!1?l:a,b=[];return S.userinfo!==void 0&&(b.push(S.userinfo),b.push("@")),S.host!==void 0&&b.push(Ar(Pt(String(S.host),N),N).replace(N.IPV6ADDRESS,function(A,K,X){return"["+K+(X?"%25"+X:"")+"]"})),(typeof S.port=="number"||typeof S.port=="string")&&(b.push(":"),b.push(String(S.port))),b.length?b.join(""):void 0}var br=/^\.\.?\//,Lr=/^\/\.(\/|$)/,Fr=/^\/\.\.(\/|$)/,pn=/^\/?(?:.|\n)*?(?=\/|$)/;function At(S){for(var g=[];S.length;)if(S.match(br))S=S.replace(br,"");else if(S.match(Lr))S=S.replace(Lr,"/");else if(S.match(Fr))S=S.replace(Fr,"/"),g.pop();else if(S==="."||S==="..")S="";else{var N=S.match(pn);if(N){var b=N[0];S=S.slice(b.length),g.push(b)}else throw new Error("Unexpected dot segment condition")}return g.join("")}function it(S){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},N=g.iri?l:a,b=[],A=V[(g.scheme||S.scheme||"").toLowerCase()];if(A&&A.serialize&&A.serialize(S,g),S.host&&!N.IPV6ADDRESS.test(S.host)){if(g.domainHost||A&&A.domainHost)try{S.host=g.iri?F.toUnicode(S.host):F.toASCII(S.host.replace(N.PCT_ENCODED,ie).toLowerCase())}catch(ue){S.error=S.error||"Host's domain name can not be converted to "+(g.iri?"Unicode":"ASCII")+" via punycode: "+ue}}ae(S,N),g.reference!=="suffix"&&S.scheme&&(b.push(S.scheme),b.push(":"));var K=mn(S,g);if(K!==void 0&&(g.reference!=="suffix"&&b.push("//"),b.push(K),S.path&&S.path.charAt(0)!=="/"&&b.push("/")),S.path!==void 0){var X=S.path;!g.absolutePath&&(!A||!A.absolutePath)&&(X=At(X)),K===void 0&&(X=X.replace(/^\/\//,"/%2F")),b.push(X)}return S.query!==void 0&&(b.push("?"),b.push(S.query)),S.fragment!==void 0&&(b.push("#"),b.push(S.fragment)),b.join("")}function jr(S,g){var N=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},b=arguments[3],A={};return b||(S=ut(it(S,N),N),g=ut(it(g,N),N)),N=N||{},!N.tolerant&&g.scheme?(A.scheme=g.scheme,A.userinfo=g.userinfo,A.host=g.host,A.port=g.port,A.path=At(g.path||""),A.query=g.query):(g.userinfo!==void 0||g.host!==void 0||g.port!==void 0?(A.userinfo=g.userinfo,A.host=g.host,A.port=g.port,A.path=At(g.path||""),A.query=g.query):(g.path?(g.path.charAt(0)==="/"?A.path=At(g.path):((S.userinfo!==void 0||S.host!==void 0||S.port!==void 0)&&!S.path?A.path="/"+g.path:S.path?A.path=S.path.slice(0,S.path.lastIndexOf("/")+1)+g.path:A.path=g.path,A.path=At(A.path)),A.query=g.query):(A.path=S.path,g.query!==void 0?A.query=g.query:A.query=S.query),A.userinfo=S.userinfo,A.host=S.host,A.port=S.port),A.scheme=S.scheme),A.fragment=g.fragment,A}function yn(S,g,N){var b=u({scheme:"null"},N);return it(jr(ut(S,b),ut(g,b),b,!0),b)}function dr(S,g){return typeof S=="string"?S=it(ut(S,g),g):s(S)==="object"&&(S=ut(it(S,g),g)),S}function vn(S,g,N){return typeof S=="string"?S=it(ut(S,N),N):s(S)==="object"&&(S=it(S,N)),typeof g=="string"?g=it(ut(g,N),N):s(g)==="object"&&(g=it(g,N)),S===g}function ti(S,g){return S&&S.toString().replace(!g||!g.iri?a.ESCAPE:l.ESCAPE,q)}function mt(S,g){return S&&S.toString().replace(!g||!g.iri?a.PCT_ENCODED:l.PCT_ENCODED,ie)}var hr={scheme:"http",domainHost:!0,parse:function(g,N){return g.host||(g.error=g.error||"HTTP URIs must have a host."),g},serialize:function(g,N){var b=String(g.scheme).toLowerCase()==="https";return(g.port===(b?443:80)||g.port==="")&&(g.port=void 0),g.path||(g.path="/"),g}},ua={scheme:"https",domainHost:hr.domainHost,parse:hr.parse,serialize:hr.serialize};function fa(S){return typeof S.secure=="boolean"?S.secure:String(S.scheme).toLowerCase()==="wss"}var En={scheme:"ws",domainHost:!0,parse:function(g,N){var b=g;return b.secure=fa(b),b.resourceName=(b.path||"/")+(b.query?"?"+b.query:""),b.path=void 0,b.query=void 0,b},serialize:function(g,N){if((g.port===(fa(g)?443:80)||g.port==="")&&(g.port=void 0),typeof g.secure=="boolean"&&(g.scheme=g.secure?"wss":"ws",g.secure=void 0),g.resourceName){var b=g.resourceName.split("?"),A=E(b,2),K=A[0],X=A[1];g.path=K&&K!=="/"?K:void 0,g.query=X,g.resourceName=void 0}return g.fragment=void 0,g}},la={scheme:"wss",domainHost:En.domainHost,parse:En.parse,serialize:En.serialize},el={},da="[A-Za-z0-9\\-\\.\\_\\~\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]",bt="[0-9A-Fa-f]",tl=i(i("%[EFef]"+bt+"%"+bt+bt+"%"+bt+bt)+"|"+i("%[89A-Fa-f]"+bt+"%"+bt+bt)+"|"+i("%"+bt+bt)),rl="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",nl="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",il=n(nl,'[\\"\\\\]'),sl="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",ol=new RegExp(da,"g"),Mr=new RegExp(tl,"g"),al=new RegExp(n("[^]",rl,"[\\.]",'[\\"]',il),"g"),ha=new RegExp(n("[^]",da,sl),"g"),cl=ha;function ls(S){var g=ie(S);return g.match(ol)?g:S}var ma={scheme:"mailto",parse:function(g,N){var b=g,A=b.to=b.path?b.path.split(","):[];if(b.path=void 0,b.query){for(var K=!1,X={},ue=b.query.split("&"),ge=0,Te=ue.length;ge<Te;++ge){var se=ue[ge].split("=");switch(se[0]){case"to":for(var ve=se[1].split(","),De=0,Y=ve.length;De<Y;++De)A.push(ve[De]);break;case"subject":b.subject=mt(se[1],N);break;case"body":b.body=mt(se[1],N);break;default:K=!0,X[mt(se[0],N)]=mt(se[1],N);break}}K&&(b.headers=X)}b.query=void 0;for(var _e=0,Pe=A.length;_e<Pe;++_e){var Se=A[_e].split("@");if(Se[0]=mt(Se[0]),N.unicodeSupport)Se[1]=mt(Se[1],N).toLowerCase();else try{Se[1]=F.toASCII(mt(Se[1],N).toLowerCase())}catch(Wt){b.error=b.error||"Email address's domain name can not be converted to ASCII via punycode: "+Wt}A[_e]=Se.join("@")}return b},serialize:function(g,N){var b=g,A=c(g.to);if(A){for(var K=0,X=A.length;K<X;++K){var ue=String(A[K]),ge=ue.lastIndexOf("@"),Te=ue.slice(0,ge).replace(Mr,ls).replace(Mr,o).replace(al,q),se=ue.slice(ge+1);try{se=N.iri?F.toUnicode(se):F.toASCII(mt(se,N).toLowerCase())}catch(_e){b.error=b.error||"Email address's domain name can not be converted to "+(N.iri?"Unicode":"ASCII")+" via punycode: "+_e}A[K]=Te+"@"+se}b.path=A.join(",")}var ve=g.headers=g.headers||{};g.subject&&(ve.subject=g.subject),g.body&&(ve.body=g.body);var De=[];for(var Y in ve)ve[Y]!==el[Y]&&De.push(Y.replace(Mr,ls).replace(Mr,o).replace(ha,q)+"="+ve[Y].replace(Mr,ls).replace(Mr,o).replace(cl,q));return De.length&&(b.query=De.join("&")),b}},ul=/^([^\:]+)\:(.*)/,pa={scheme:"urn",parse:function(g,N){var b=g.path&&g.path.match(ul),A=g;if(b){var K=N.scheme||A.scheme||"urn",X=b[1].toLowerCase(),ue=b[2],ge=K+":"+(N.nid||X),Te=V[ge];A.nid=X,A.nss=ue,A.path=void 0,Te&&(A=Te.parse(A,N))}else A.error=A.error||"URN can not be parsed.";return A},serialize:function(g,N){var b=N.scheme||g.scheme||"urn",A=g.nid,K=b+":"+(N.nid||A),X=V[K];X&&(g=X.serialize(g,N));var ue=g,ge=g.nss;return ue.path=(A||N.nid)+":"+ge,ue}},fl=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,ya={scheme:"urn:uuid",parse:function(g,N){var b=g;return b.uuid=b.nss,b.nss=void 0,!N.tolerant&&(!b.uuid||!b.uuid.match(fl))&&(b.error=b.error||"UUID is not valid."),b},serialize:function(g,N){var b=g;return b.nss=(g.uuid||"").toLowerCase(),b}};V[hr.scheme]=hr,V[ua.scheme]=ua,V[En.scheme]=En,V[la.scheme]=la,V[ma.scheme]=ma,V[pa.scheme]=pa,V[ya.scheme]=ya,r.SCHEMES=V,r.pctEncChar=q,r.pctDecChars=ie,r.parse=ut,r.removeDotSegments=At,r.serialize=it,r.resolveComponents=jr,r.resolve=yn,r.normalize=dr,r.equal=vn,r.escapeComponent=ti,r.unescapeComponent=mt,Object.defineProperty(r,"__esModule",{value:!0})})})(ks,ks.exports);Object.defineProperty(_o,"__esModule",{value:!0});const Pf=ks.exports;Pf.code='require("ajv/dist/runtime/uri").default';_o.default=Pf;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=void 0;var t=Tt;Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return t.KeywordCxt}});var r=ee;Object.defineProperty(e,"_",{enumerable:!0,get:function(){return r._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return r.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return r.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return r.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return r.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return r.CodeGen}});const n=Wi,i=Ji,s=Tr,o=at,c=ee,u=Ve,m=Qn,a=fe,l=gy,E=_o,h=(C,I)=>new RegExp(C,I);h.code="new RegExp";const d=["removeAdditional","useDefaults","coerceTypes"],y=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),v={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},f={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},$=200;function w(C){var I,M,R,p,_,F,V,q,ie,ae,Oe,Pt,Ar,dn,hn,ut,mn,br,Lr,Fr,pn,At,it,jr,yn;const dr=C.strict,vn=(I=C.code)===null||I===void 0?void 0:I.optimize,ti=vn===!0||vn===void 0?1:vn||0,mt=(R=(M=C.code)===null||M===void 0?void 0:M.regExp)!==null&&R!==void 0?R:h,hr=(p=C.uriResolver)!==null&&p!==void 0?p:E.default;return{strictSchema:(F=(_=C.strictSchema)!==null&&_!==void 0?_:dr)!==null&&F!==void 0?F:!0,strictNumbers:(q=(V=C.strictNumbers)!==null&&V!==void 0?V:dr)!==null&&q!==void 0?q:!0,strictTypes:(ae=(ie=C.strictTypes)!==null&&ie!==void 0?ie:dr)!==null&&ae!==void 0?ae:"log",strictTuples:(Pt=(Oe=C.strictTuples)!==null&&Oe!==void 0?Oe:dr)!==null&&Pt!==void 0?Pt:"log",strictRequired:(dn=(Ar=C.strictRequired)!==null&&Ar!==void 0?Ar:dr)!==null&&dn!==void 0?dn:!1,code:C.code?vt(Q({},C.code),{optimize:ti,regExp:mt}):{optimize:ti,regExp:mt},loopRequired:(hn=C.loopRequired)!==null&&hn!==void 0?hn:$,loopEnum:(ut=C.loopEnum)!==null&&ut!==void 0?ut:$,meta:(mn=C.meta)!==null&&mn!==void 0?mn:!0,messages:(br=C.messages)!==null&&br!==void 0?br:!0,inlineRefs:(Lr=C.inlineRefs)!==null&&Lr!==void 0?Lr:!0,schemaId:(Fr=C.schemaId)!==null&&Fr!==void 0?Fr:"$id",addUsedSchema:(pn=C.addUsedSchema)!==null&&pn!==void 0?pn:!0,validateSchema:(At=C.validateSchema)!==null&&At!==void 0?At:!0,validateFormats:(it=C.validateFormats)!==null&&it!==void 0?it:!0,unicodeRegExp:(jr=C.unicodeRegExp)!==null&&jr!==void 0?jr:!0,int32range:(yn=C.int32range)!==null&&yn!==void 0?yn:!0,uriResolver:hr}}class T{constructor(I={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,I=this.opts=Q(Q({},I),w(I));const{es5:M,lines:R}=this.opts.code;this.scope=new c.ValueScope({scope:{},prefixes:y,es5:M,lines:R}),this.logger=z(I.logger);const p=I.validateFormats;I.validateFormats=!1,this.RULES=(0,s.getRules)(),k.call(this,v,I,"NOT SUPPORTED"),k.call(this,f,I,"DEPRECATED","warn"),this._metaOpts=U.call(this),I.formats&&P.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),I.keywords&&L.call(this,I.keywords),typeof I.meta=="object"&&this.addMetaSchema(I.meta),D.call(this),I.validateFormats=p}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:I,meta:M,schemaId:R}=this.opts;let p=l;R==="id"&&(p=Q({},l),p.id=p.$id,delete p.$id),M&&I&&this.addMetaSchema(p,p[R],!1)}defaultMeta(){const{meta:I,schemaId:M}=this.opts;return this.opts.defaultMeta=typeof I=="object"?I[M]||I:void 0}validate(I,M){let R;if(typeof I=="string"){if(R=this.getSchema(I),!R)throw new Error(`no schema with key or ref "${I}"`)}else R=this.compile(I);const p=R(M);return"$async"in R||(this.errors=R.errors),p}compile(I,M){const R=this._addSchema(I,M);return R.validate||this._compileSchemaEnv(R)}compileAsync(I,M){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:R}=this.opts;return p.call(this,I,M);async function p(ae,Oe){await _.call(this,ae.$schema);const Pt=this._addSchema(ae,Oe);return Pt.validate||F.call(this,Pt)}async function _(ae){ae&&!this.getSchema(ae)&&await p.call(this,{$ref:ae},!0)}async function F(ae){try{return this._compileSchemaEnv(ae)}catch(Oe){if(!(Oe instanceof i.default))throw Oe;return V.call(this,Oe),await q.call(this,Oe.missingSchema),F.call(this,ae)}}function V({missingSchema:ae,missingRef:Oe}){if(this.refs[ae])throw new Error(`AnySchema ${ae} is loaded but ${Oe} cannot be resolved`)}async function q(ae){const Oe=await ie.call(this,ae);this.refs[ae]||await _.call(this,Oe.$schema),this.refs[ae]||this.addSchema(Oe,ae,M)}async function ie(ae){const Oe=this._loading[ae];if(Oe)return Oe;try{return await(this._loading[ae]=R(ae))}finally{delete this._loading[ae]}}}addSchema(I,M,R,p=this.opts.validateSchema){if(Array.isArray(I)){for(const F of I)this.addSchema(F,void 0,R,p);return this}let _;if(typeof I=="object"){const{schemaId:F}=this.opts;if(_=I[F],_!==void 0&&typeof _!="string")throw new Error(`schema ${F} must be string`)}return M=(0,u.normalizeId)(M||_),this._checkUnique(M),this.schemas[M]=this._addSchema(I,R,M,p,!0),this}addMetaSchema(I,M,R=this.opts.validateSchema){return this.addSchema(I,M,!0,R),this}validateSchema(I,M){if(typeof I=="boolean")return!0;let R;if(R=I.$schema,R!==void 0&&typeof R!="string")throw new Error("$schema must be a string");if(R=R||this.opts.defaultMeta||this.defaultMeta(),!R)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const p=this.validate(R,I);if(!p&&M){const _="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(_);else throw new Error(_)}return p}getSchema(I){let M;for(;typeof(M=O.call(this,I))=="string";)I=M;if(M===void 0){const{schemaId:R}=this.opts,p=new o.SchemaEnv({schema:{},schemaId:R});if(M=o.resolveSchema.call(this,p,I),!M)return;this.refs[I]=M}return M.validate||this._compileSchemaEnv(M)}removeSchema(I){if(I instanceof RegExp)return this._removeAllSchemas(this.schemas,I),this._removeAllSchemas(this.refs,I),this;switch(typeof I){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const M=O.call(this,I);return typeof M=="object"&&this._cache.delete(M.schema),delete this.schemas[I],delete this.refs[I],this}case"object":{const M=I;this._cache.delete(M);let R=I[this.opts.schemaId];return R&&(R=(0,u.normalizeId)(R),delete this.schemas[R],delete this.refs[R]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(I){for(const M of I)this.addKeyword(M);return this}addKeyword(I,M){let R;if(typeof I=="string")R=I,typeof M=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),M.keyword=R);else if(typeof I=="object"&&M===void 0){if(M=I,R=M.keyword,Array.isArray(R)&&!R.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(Z.call(this,R,M),!M)return(0,a.eachItem)(R,_=>le.call(this,_)),this;ne.call(this,M);const p=vt(Q({},M),{type:(0,m.getJSONTypes)(M.type),schemaType:(0,m.getJSONTypes)(M.schemaType)});return(0,a.eachItem)(R,p.type.length===0?_=>le.call(this,_,p):_=>p.type.forEach(F=>le.call(this,_,p,F))),this}getKeyword(I){const M=this.RULES.all[I];return typeof M=="object"?M.definition:!!M}removeKeyword(I){const{RULES:M}=this;delete M.keywords[I],delete M.all[I];for(const R of M.rules){const p=R.rules.findIndex(_=>_.keyword===I);p>=0&&R.rules.splice(p,1)}return this}addFormat(I,M){return typeof M=="string"&&(M=new RegExp(M)),this.formats[I]=M,this}errorsText(I=this.errors,{separator:M=", ",dataVar:R="data"}={}){return!I||I.length===0?"No errors":I.map(p=>`${R}${p.instancePath} ${p.message}`).reduce((p,_)=>p+M+_)}$dataMetaSchema(I,M){const R=this.RULES.all;I=JSON.parse(JSON.stringify(I));for(const p of M){const _=p.split("/").slice(1);let F=I;for(const V of _)F=F[V];for(const V in R){const q=R[V];if(typeof q!="object")continue;const{$data:ie}=q.definition,ae=F[V];ie&&ae&&(F[V]=x(ae))}}return I}_removeAllSchemas(I,M){for(const R in I){const p=I[R];(!M||M.test(R))&&(typeof p=="string"?delete I[R]:p&&!p.meta&&(this._cache.delete(p.schema),delete I[R]))}}_addSchema(I,M,R,p=this.opts.validateSchema,_=this.opts.addUsedSchema){let F;const{schemaId:V}=this.opts;if(typeof I=="object")F=I[V];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof I!="boolean")throw new Error("schema must be object or boolean")}let q=this._cache.get(I);if(q!==void 0)return q;R=(0,u.normalizeId)(F||R);const ie=u.getSchemaRefs.call(this,I,R);return q=new o.SchemaEnv({schema:I,schemaId:V,meta:M,baseId:R,localRefs:ie}),this._cache.set(q.schema,q),_&&!R.startsWith("#")&&(R&&this._checkUnique(R),this.refs[R]=q),p&&this.validateSchema(I,!0),q}_checkUnique(I){if(this.schemas[I]||this.refs[I])throw new Error(`schema with key or id "${I}" already exists`)}_compileSchemaEnv(I){if(I.meta?this._compileMetaSchema(I):o.compileSchema.call(this,I),!I.validate)throw new Error("ajv implementation error");return I.validate}_compileMetaSchema(I){const M=this.opts;this.opts=this._metaOpts;try{o.compileSchema.call(this,I)}finally{this.opts=M}}}e.default=T,T.ValidationError=n.default,T.MissingRefError=i.default;function k(C,I,M,R="error"){for(const p in C){const _=p;_ in I&&this.logger[R](`${M}: option ${p}. ${C[_]}`)}}function O(C){return C=(0,u.normalizeId)(C),this.schemas[C]||this.refs[C]}function D(){const C=this.opts.schemas;if(!!C)if(Array.isArray(C))this.addSchema(C);else for(const I in C)this.addSchema(C[I],I)}function P(){for(const C in this.opts.formats){const I=this.opts.formats[C];I&&this.addFormat(C,I)}}function L(C){if(Array.isArray(C)){this.addVocabulary(C);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const I in C){const M=C[I];M.keyword||(M.keyword=I),this.addKeyword(M)}}function U(){const C=Q({},this.opts);for(const I of d)delete C[I];return C}const B={log(){},warn(){},error(){}};function z(C){if(C===!1)return B;if(C===void 0)return console;if(C.log&&C.warn&&C.error)return C;throw new Error("logger must implement log, warn and error methods")}const J=/^[a-z_$][a-z0-9_$:-]*$/i;function Z(C,I){const{RULES:M}=this;if((0,a.eachItem)(C,R=>{if(M.keywords[R])throw new Error(`Keyword ${R} is already defined`);if(!J.test(R))throw new Error(`Keyword ${R} has invalid name`)}),!!I&&I.$data&&!("code"in I||"validate"in I))throw new Error('$data keyword must have "code" or "validate" function')}function le(C,I,M){var R;const p=I==null?void 0:I.post;if(M&&p)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:_}=this;let F=p?_.post:_.rules.find(({type:q})=>q===M);if(F||(F={type:M,rules:[]},_.rules.push(F)),_.keywords[C]=!0,!I)return;const V={keyword:C,definition:vt(Q({},I),{type:(0,m.getJSONTypes)(I.type),schemaType:(0,m.getJSONTypes)(I.schemaType)})};I.before?te.call(this,F,V,I.before):F.rules.push(V),_.all[C]=V,(R=I.implements)===null||R===void 0||R.forEach(q=>this.addKeyword(q))}function te(C,I,M){const R=C.rules.findIndex(p=>p.keyword===M);R>=0?C.rules.splice(R,0,I):(C.rules.push(I),this.logger.warn(`rule ${M} is not defined`))}function ne(C){let{metaSchema:I}=C;I!==void 0&&(C.$data&&this.opts.$data&&(I=x(I)),C.validateSchema=this.compile(I,!0))}const j={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function x(C){return{anyOf:[C,j]}}})(af);var So={},wo={},No={};Object.defineProperty(No,"__esModule",{value:!0});const $y={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};No.default=$y;var Dr={};Object.defineProperty(Dr,"__esModule",{value:!0});Dr.callRef=Dr.getValidate=void 0;const _y=Ji,tc=re,ot=ee,Vr=Vt,rc=at,fi=fe,Sy={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:r,it:n}=e,{baseId:i,schemaEnv:s,validateName:o,opts:c,self:u}=n,{root:m}=s;if((r==="#"||r==="#/")&&i===m.baseId)return l();const a=rc.resolveRef.call(u,m,i,r);if(a===void 0)throw new _y.default(n.opts.uriResolver,i,r);if(a instanceof rc.SchemaEnv)return E(a);return h(a);function l(){if(s===m)return wi(e,o,s,s.$async);const d=t.scopeValue("root",{ref:m});return wi(e,(0,ot._)`${d}.validate`,m,m.$async)}function E(d){const y=Af(e,d);wi(e,y,d,d.$async)}function h(d){const y=t.scopeValue("schema",c.code.source===!0?{ref:d,code:(0,ot.stringify)(d)}:{ref:d}),v=t.name("valid"),f=e.subschema({schema:d,dataTypes:[],schemaPath:ot.nil,topSchemaRef:y,errSchemaPath:r},v);e.mergeEvaluated(f),e.ok(v)}}};function Af(e,t){const{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):(0,ot._)`${r.scopeValue("wrapper",{ref:t})}.validate`}Dr.getValidate=Af;function wi(e,t,r,n){const{gen:i,it:s}=e,{allErrors:o,schemaEnv:c,opts:u}=s,m=u.passContext?Vr.default.this:ot.nil;n?a():l();function a(){if(!c.$async)throw new Error("async schema referenced by sync schema");const d=i.let("valid");i.try(()=>{i.code((0,ot._)`await ${(0,tc.callValidateCode)(e,t,m)}`),h(t),o||i.assign(d,!0)},y=>{i.if((0,ot._)`!(${y} instanceof ${s.ValidationError})`,()=>i.throw(y)),E(y),o||i.assign(d,!1)}),e.ok(d)}function l(){e.result((0,tc.callValidateCode)(e,t,m),()=>h(t),()=>E(t))}function E(d){const y=(0,ot._)`${d}.errors`;i.assign(Vr.default.vErrors,(0,ot._)`${Vr.default.vErrors} === null ? ${y} : ${Vr.default.vErrors}.concat(${y})`),i.assign(Vr.default.errors,(0,ot._)`${Vr.default.vErrors}.length`)}function h(d){var y;if(!s.opts.unevaluated)return;const v=(y=r==null?void 0:r.validate)===null||y===void 0?void 0:y.evaluated;if(s.props!==!0)if(v&&!v.dynamicProps)v.props!==void 0&&(s.props=fi.mergeEvaluated.props(i,v.props,s.props));else{const f=i.var("props",(0,ot._)`${d}.evaluated.props`);s.props=fi.mergeEvaluated.props(i,f,s.props,ot.Name)}if(s.items!==!0)if(v&&!v.dynamicItems)v.items!==void 0&&(s.items=fi.mergeEvaluated.items(i,v.items,s.items));else{const f=i.var("items",(0,ot._)`${d}.evaluated.items`);s.items=fi.mergeEvaluated.items(i,f,s.items,ot.Name)}}}Dr.callRef=wi;Dr.default=Sy;Object.defineProperty(wo,"__esModule",{value:!0});const wy=No,Ny=Dr,Iy=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",wy.default,Ny.default];wo.default=Iy;var Io={},Oo={};Object.defineProperty(Oo,"__esModule",{value:!0});const Li=ee,Qt=Li.operators,Fi={maximum:{okStr:"<=",ok:Qt.LTE,fail:Qt.GT},minimum:{okStr:">=",ok:Qt.GTE,fail:Qt.LT},exclusiveMaximum:{okStr:"<",ok:Qt.LT,fail:Qt.GTE},exclusiveMinimum:{okStr:">",ok:Qt.GT,fail:Qt.LTE}},Oy={message:({keyword:e,schemaCode:t})=>(0,Li.str)`must be ${Fi[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,Li._)`{comparison: ${Fi[e].okStr}, limit: ${t}}`},Ty={keyword:Object.keys(Fi),type:"number",schemaType:"number",$data:!0,error:Oy,code(e){const{keyword:t,data:r,schemaCode:n}=e;e.fail$data((0,Li._)`${r} ${Fi[t].fail} ${n} || isNaN(${r})`)}};Oo.default=Ty;var To={};Object.defineProperty(To,"__esModule",{value:!0});const An=ee,Dy={message:({schemaCode:e})=>(0,An.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,An._)`{multipleOf: ${e}}`},Ry={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:Dy,code(e){const{gen:t,data:r,schemaCode:n,it:i}=e,s=i.opts.multipleOfPrecision,o=t.let("res"),c=s?(0,An._)`Math.abs(Math.round(${o}) - ${o}) > 1e-${s}`:(0,An._)`${o} !== parseInt(${o})`;e.fail$data((0,An._)`(${n} === 0 || (${o} = ${r}/${n}, ${c}))`)}};To.default=Ry;var Do={},Ro={};Object.defineProperty(Ro,"__esModule",{value:!0});function bf(e){const t=e.length;let r=0,n=0,i;for(;n<t;)r++,i=e.charCodeAt(n++),i>=55296&&i<=56319&&n<t&&(i=e.charCodeAt(n),(i&64512)===56320&&n++);return r}Ro.default=bf;bf.code='require("ajv/dist/runtime/ucs2length").default';Object.defineProperty(Do,"__esModule",{value:!0});const $r=ee,Cy=fe,Py=Ro,Ay={message({keyword:e,schemaCode:t}){const r=e==="maxLength"?"more":"fewer";return(0,$r.str)`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>(0,$r._)`{limit: ${e}}`},by={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:Ay,code(e){const{keyword:t,data:r,schemaCode:n,it:i}=e,s=t==="maxLength"?$r.operators.GT:$r.operators.LT,o=i.opts.unicode===!1?(0,$r._)`${r}.length`:(0,$r._)`${(0,Cy.useFunc)(e.gen,Py.default)}(${r})`;e.fail$data((0,$r._)`${o} ${s} ${n}`)}};Do.default=by;var Co={};Object.defineProperty(Co,"__esModule",{value:!0});const Ly=re,ji=ee,Fy={message:({schemaCode:e})=>(0,ji.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,ji._)`{pattern: ${e}}`},jy={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:Fy,code(e){const{data:t,$data:r,schema:n,schemaCode:i,it:s}=e,o=s.opts.unicodeRegExp?"u":"",c=r?(0,ji._)`(new RegExp(${i}, ${o}))`:(0,Ly.usePattern)(e,n);e.fail$data((0,ji._)`!${c}.test(${t})`)}};Co.default=jy;var Po={};Object.defineProperty(Po,"__esModule",{value:!0});const bn=ee,My={message({keyword:e,schemaCode:t}){const r=e==="maxProperties"?"more":"fewer";return(0,bn.str)`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>(0,bn._)`{limit: ${e}}`},ky={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:My,code(e){const{keyword:t,data:r,schemaCode:n}=e,i=t==="maxProperties"?bn.operators.GT:bn.operators.LT;e.fail$data((0,bn._)`Object.keys(${r}).length ${i} ${n}`)}};Po.default=ky;var Ao={};Object.defineProperty(Ao,"__esModule",{value:!0});const Sn=re,Ln=ee,Uy=fe,zy={message:({params:{missingProperty:e}})=>(0,Ln.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,Ln._)`{missingProperty: ${e}}`},xy={keyword:"required",type:"object",schemaType:"array",$data:!0,error:zy,code(e){const{gen:t,schema:r,schemaCode:n,data:i,$data:s,it:o}=e,{opts:c}=o;if(!s&&r.length===0)return;const u=r.length>=c.loopRequired;if(o.allErrors?m():a(),c.strictRequired){const h=e.parentSchema.properties,{definedProperties:d}=e.it;for(const y of r)if((h==null?void 0:h[y])===void 0&&!d.has(y)){const v=o.schemaEnv.baseId+o.errSchemaPath,f=`required property "${y}" is not defined at "${v}" (strictRequired)`;(0,Uy.checkStrictMode)(o,f,o.opts.strictRequired)}}function m(){if(u||s)e.block$data(Ln.nil,l);else for(const h of r)(0,Sn.checkReportMissingProp)(e,h)}function a(){const h=t.let("missing");if(u||s){const d=t.let("valid",!0);e.block$data(d,()=>E(h,d)),e.ok(d)}else t.if((0,Sn.checkMissingProp)(e,r,h)),(0,Sn.reportMissingProp)(e,h),t.else()}function l(){t.forOf("prop",n,h=>{e.setParams({missingProperty:h}),t.if((0,Sn.noPropertyInData)(t,i,h,c.ownProperties),()=>e.error())})}function E(h,d){e.setParams({missingProperty:h}),t.forOf(h,n,()=>{t.assign(d,(0,Sn.propertyInData)(t,i,h,c.ownProperties)),t.if((0,Ln.not)(d),()=>{e.error(),t.break()})},Ln.nil)}}};Ao.default=xy;var bo={};Object.defineProperty(bo,"__esModule",{value:!0});const Fn=ee,Vy={message({keyword:e,schemaCode:t}){const r=e==="maxItems"?"more":"fewer";return(0,Fn.str)`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>(0,Fn._)`{limit: ${e}}`},qy={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:Vy,code(e){const{keyword:t,data:r,schemaCode:n}=e,i=t==="maxItems"?Fn.operators.GT:Fn.operators.LT;e.fail$data((0,Fn._)`${r}.length ${i} ${n}`)}};bo.default=qy;var Lo={},ei={};Object.defineProperty(ei,"__esModule",{value:!0});const Lf=pf;Lf.code='require("ajv/dist/runtime/equal").default';ei.default=Lf;Object.defineProperty(Lo,"__esModule",{value:!0});const $s=Qn,Ue=ee,Gy=fe,By=ei,Hy={message:({params:{i:e,j:t}})=>(0,Ue.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Ue._)`{i: ${e}, j: ${t}}`},Ky={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:Hy,code(e){const{gen:t,data:r,$data:n,schema:i,parentSchema:s,schemaCode:o,it:c}=e;if(!n&&!i)return;const u=t.let("valid"),m=s.items?(0,$s.getSchemaTypes)(s.items):[];e.block$data(u,a,(0,Ue._)`${o} === false`),e.ok(u);function a(){const d=t.let("i",(0,Ue._)`${r}.length`),y=t.let("j");e.setParams({i:d,j:y}),t.assign(u,!0),t.if((0,Ue._)`${d} > 1`,()=>(l()?E:h)(d,y))}function l(){return m.length>0&&!m.some(d=>d==="object"||d==="array")}function E(d,y){const v=t.name("item"),f=(0,$s.checkDataTypes)(m,v,c.opts.strictNumbers,$s.DataType.Wrong),$=t.const("indices",(0,Ue._)`{}`);t.for((0,Ue._)`;${d}--;`,()=>{t.let(v,(0,Ue._)`${r}[${d}]`),t.if(f,(0,Ue._)`continue`),m.length>1&&t.if((0,Ue._)`typeof ${v} == "string"`,(0,Ue._)`${v} += "_"`),t.if((0,Ue._)`typeof ${$}[${v}] == "number"`,()=>{t.assign(y,(0,Ue._)`${$}[${v}]`),e.error(),t.assign(u,!1).break()}).code((0,Ue._)`${$}[${v}] = ${d}`)})}function h(d,y){const v=(0,Gy.useFunc)(t,By.default),f=t.name("outer");t.label(f).for((0,Ue._)`;${d}--;`,()=>t.for((0,Ue._)`${y} = ${d}; ${y}--;`,()=>t.if((0,Ue._)`${v}(${r}[${d}], ${r}[${y}])`,()=>{e.error(),t.assign(u,!1).break(f)})))}}};Lo.default=Ky;var Fo={};Object.defineProperty(Fo,"__esModule",{value:!0});const Us=ee,Xy=fe,Zy=ei,Wy={message:"must be equal to constant",params:({schemaCode:e})=>(0,Us._)`{allowedValue: ${e}}`},Jy={keyword:"const",$data:!0,error:Wy,code(e){const{gen:t,data:r,$data:n,schemaCode:i,schema:s}=e;n||s&&typeof s=="object"?e.fail$data((0,Us._)`!${(0,Xy.useFunc)(t,Zy.default)}(${r}, ${i})`):e.fail((0,Us._)`${s} !== ${r}`)}};Fo.default=Jy;var jo={};Object.defineProperty(jo,"__esModule",{value:!0});const Tn=ee,Yy=fe,Qy=ei,e0={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,Tn._)`{allowedValues: ${e}}`},t0={keyword:"enum",schemaType:"array",$data:!0,error:e0,code(e){const{gen:t,data:r,$data:n,schema:i,schemaCode:s,it:o}=e;if(!n&&i.length===0)throw new Error("enum must have non-empty array");const c=i.length>=o.opts.loopEnum,u=(0,Yy.useFunc)(t,Qy.default);let m;if(c||n)m=t.let("valid"),e.block$data(m,a);else{if(!Array.isArray(i))throw new Error("ajv implementation error");const E=t.const("vSchema",s);m=(0,Tn.or)(...i.map((h,d)=>l(E,d)))}e.pass(m);function a(){t.assign(m,!1),t.forOf("v",s,E=>t.if((0,Tn._)`${u}(${r}, ${E})`,()=>t.assign(m,!0).break()))}function l(E,h){const d=i[h];return typeof d=="object"&&d!==null?(0,Tn._)`${u}(${r}, ${E}[${h}])`:(0,Tn._)`${r} === ${d}`}}};jo.default=t0;Object.defineProperty(Io,"__esModule",{value:!0});const r0=Oo,n0=To,i0=Do,s0=Co,o0=Po,a0=Ao,c0=bo,u0=Lo,f0=Fo,l0=jo,d0=[r0.default,n0.default,i0.default,s0.default,o0.default,a0.default,c0.default,u0.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},f0.default,l0.default];Io.default=d0;var Mo={},un={};Object.defineProperty(un,"__esModule",{value:!0});un.validateAdditionalItems=void 0;const _r=ee,zs=fe,h0={message:({params:{len:e}})=>(0,_r.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,_r._)`{limit: ${e}}`},m0={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:h0,code(e){const{parentSchema:t,it:r}=e,{items:n}=t;if(!Array.isArray(n)){(0,zs.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}Ff(e,n)}};function Ff(e,t){const{gen:r,schema:n,data:i,keyword:s,it:o}=e;o.items=!0;const c=r.const("len",(0,_r._)`${i}.length`);if(n===!1)e.setParams({len:t.length}),e.pass((0,_r._)`${c} <= ${t.length}`);else if(typeof n=="object"&&!(0,zs.alwaysValidSchema)(o,n)){const m=r.var("valid",(0,_r._)`${c} <= ${t.length}`);r.if((0,_r.not)(m),()=>u(m)),e.ok(m)}function u(m){r.forRange("i",t.length,c,a=>{e.subschema({keyword:s,dataProp:a,dataPropType:zs.Type.Num},m),o.allErrors||r.if((0,_r.not)(m),()=>r.break())})}}un.validateAdditionalItems=Ff;un.default=m0;var ko={},fn={};Object.defineProperty(fn,"__esModule",{value:!0});fn.validateTuple=void 0;const nc=ee,Ni=fe,p0=re,y0={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:r}=e;if(Array.isArray(t))return jf(e,"additionalItems",t);r.items=!0,!(0,Ni.alwaysValidSchema)(r,t)&&e.ok((0,p0.validateArray)(e))}};function jf(e,t,r=e.schema){const{gen:n,parentSchema:i,data:s,keyword:o,it:c}=e;a(i),c.opts.unevaluated&&r.length&&c.items!==!0&&(c.items=Ni.mergeEvaluated.items(n,r.length,c.items));const u=n.name("valid"),m=n.const("len",(0,nc._)`${s}.length`);r.forEach((l,E)=>{(0,Ni.alwaysValidSchema)(c,l)||(n.if((0,nc._)`${m} > ${E}`,()=>e.subschema({keyword:o,schemaProp:E,dataProp:E},u)),e.ok(u))});function a(l){const{opts:E,errSchemaPath:h}=c,d=r.length,y=d===l.minItems&&(d===l.maxItems||l[t]===!1);if(E.strictTuples&&!y){const v=`"${o}" is ${d}-tuple, but minItems or maxItems/${t} are not specified or different at path "${h}"`;(0,Ni.checkStrictMode)(c,v,E.strictTuples)}}}fn.validateTuple=jf;fn.default=y0;Object.defineProperty(ko,"__esModule",{value:!0});const v0=fn,E0={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,v0.validateTuple)(e,"items")};ko.default=E0;var Uo={};Object.defineProperty(Uo,"__esModule",{value:!0});const ic=ee,g0=fe,$0=re,_0=un,S0={message:({params:{len:e}})=>(0,ic.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,ic._)`{limit: ${e}}`},w0={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:S0,code(e){const{schema:t,parentSchema:r,it:n}=e,{prefixItems:i}=r;n.items=!0,!(0,g0.alwaysValidSchema)(n,t)&&(i?(0,_0.validateAdditionalItems)(e,i):e.ok((0,$0.validateArray)(e)))}};Uo.default=w0;var zo={};Object.defineProperty(zo,"__esModule",{value:!0});const yt=ee,li=fe,N0={message:({params:{min:e,max:t}})=>t===void 0?(0,yt.str)`must contain at least ${e} valid item(s)`:(0,yt.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,yt._)`{minContains: ${e}}`:(0,yt._)`{minContains: ${e}, maxContains: ${t}}`},I0={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:N0,code(e){const{gen:t,schema:r,parentSchema:n,data:i,it:s}=e;let o,c;const{minContains:u,maxContains:m}=n;s.opts.next?(o=u===void 0?1:u,c=m):o=1;const a=t.const("len",(0,yt._)`${i}.length`);if(e.setParams({min:o,max:c}),c===void 0&&o===0){(0,li.checkStrictMode)(s,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(c!==void 0&&o>c){(0,li.checkStrictMode)(s,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,li.alwaysValidSchema)(s,r)){let y=(0,yt._)`${a} >= ${o}`;c!==void 0&&(y=(0,yt._)`${y} && ${a} <= ${c}`),e.pass(y);return}s.items=!0;const l=t.name("valid");c===void 0&&o===1?h(l,()=>t.if(l,()=>t.break())):o===0?(t.let(l,!0),c!==void 0&&t.if((0,yt._)`${i}.length > 0`,E)):(t.let(l,!1),E()),e.result(l,()=>e.reset());function E(){const y=t.name("_valid"),v=t.let("count",0);h(y,()=>t.if(y,()=>d(v)))}function h(y,v){t.forRange("i",0,a,f=>{e.subschema({keyword:"contains",dataProp:f,dataPropType:li.Type.Num,compositeRule:!0},y),v()})}function d(y){t.code((0,yt._)`${y}++`),c===void 0?t.if((0,yt._)`${y} >= ${o}`,()=>t.assign(l,!0).break()):(t.if((0,yt._)`${y} > ${c}`,()=>t.assign(l,!1).break()),o===1?t.assign(l,!0):t.if((0,yt._)`${y} >= ${o}`,()=>t.assign(l,!0)))}}};zo.default=I0;var Mf={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const t=ee,r=fe,n=re;e.error={message:({params:{property:u,depsCount:m,deps:a}})=>{const l=m===1?"property":"properties";return(0,t.str)`must have ${l} ${a} when property ${u} is present`},params:({params:{property:u,depsCount:m,deps:a,missingProperty:l}})=>(0,t._)`{property: ${u},
12
+ missingProperty: ${l},
13
+ depsCount: ${m},
14
+ deps: ${a}}`};const i={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(u){const[m,a]=s(u);o(u,m),c(u,a)}};function s({schema:u}){const m={},a={};for(const l in u){if(l==="__proto__")continue;const E=Array.isArray(u[l])?m:a;E[l]=u[l]}return[m,a]}function o(u,m=u.schema){const{gen:a,data:l,it:E}=u;if(Object.keys(m).length===0)return;const h=a.let("missing");for(const d in m){const y=m[d];if(y.length===0)continue;const v=(0,n.propertyInData)(a,l,d,E.opts.ownProperties);u.setParams({property:d,depsCount:y.length,deps:y.join(", ")}),E.allErrors?a.if(v,()=>{for(const f of y)(0,n.checkReportMissingProp)(u,f)}):(a.if((0,t._)`${v} && (${(0,n.checkMissingProp)(u,y,h)})`),(0,n.reportMissingProp)(u,h),a.else())}}e.validatePropertyDeps=o;function c(u,m=u.schema){const{gen:a,data:l,keyword:E,it:h}=u,d=a.name("valid");for(const y in m)(0,r.alwaysValidSchema)(h,m[y])||(a.if((0,n.propertyInData)(a,l,y,h.opts.ownProperties),()=>{const v=u.subschema({keyword:E,schemaProp:y},d);u.mergeValidEvaluated(v,d)},()=>a.var(d,!0)),u.ok(d))}e.validateSchemaDeps=c,e.default=i})(Mf);var xo={};Object.defineProperty(xo,"__esModule",{value:!0});const kf=ee,O0=fe,T0={message:"property name must be valid",params:({params:e})=>(0,kf._)`{propertyName: ${e.propertyName}}`},D0={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:T0,code(e){const{gen:t,schema:r,data:n,it:i}=e;if((0,O0.alwaysValidSchema)(i,r))return;const s=t.name("valid");t.forIn("key",n,o=>{e.setParams({propertyName:o}),e.subschema({keyword:"propertyNames",data:o,dataTypes:["string"],propertyName:o,compositeRule:!0},s),t.if((0,kf.not)(s),()=>{e.error(!0),i.allErrors||t.break()})}),e.ok(s)}};xo.default=D0;var es={};Object.defineProperty(es,"__esModule",{value:!0});const di=re,$t=ee,R0=Vt,hi=fe,C0={message:"must NOT have additional properties",params:({params:e})=>(0,$t._)`{additionalProperty: ${e.additionalProperty}}`},P0={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:C0,code(e){const{gen:t,schema:r,parentSchema:n,data:i,errsCount:s,it:o}=e;if(!s)throw new Error("ajv implementation error");const{allErrors:c,opts:u}=o;if(o.props=!0,u.removeAdditional!=="all"&&(0,hi.alwaysValidSchema)(o,r))return;const m=(0,di.allSchemaProperties)(n.properties),a=(0,di.allSchemaProperties)(n.patternProperties);l(),e.ok((0,$t._)`${s} === ${R0.default.errors}`);function l(){t.forIn("key",i,v=>{!m.length&&!a.length?d(v):t.if(E(v),()=>d(v))})}function E(v){let f;if(m.length>8){const $=(0,hi.schemaRefOrVal)(o,n.properties,"properties");f=(0,di.isOwnProperty)(t,$,v)}else m.length?f=(0,$t.or)(...m.map($=>(0,$t._)`${v} === ${$}`)):f=$t.nil;return a.length&&(f=(0,$t.or)(f,...a.map($=>(0,$t._)`${(0,di.usePattern)(e,$)}.test(${v})`))),(0,$t.not)(f)}function h(v){t.code((0,$t._)`delete ${i}[${v}]`)}function d(v){if(u.removeAdditional==="all"||u.removeAdditional&&r===!1){h(v);return}if(r===!1){e.setParams({additionalProperty:v}),e.error(),c||t.break();return}if(typeof r=="object"&&!(0,hi.alwaysValidSchema)(o,r)){const f=t.name("valid");u.removeAdditional==="failing"?(y(v,f,!1),t.if((0,$t.not)(f),()=>{e.reset(),h(v)})):(y(v,f),c||t.if((0,$t.not)(f),()=>t.break()))}}function y(v,f,$){const w={keyword:"additionalProperties",dataProp:v,dataPropType:hi.Type.Str};$===!1&&Object.assign(w,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(w,f)}}};es.default=P0;var Vo={};Object.defineProperty(Vo,"__esModule",{value:!0});const A0=Tt,sc=re,_s=fe,oc=es,b0={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:r,parentSchema:n,data:i,it:s}=e;s.opts.removeAdditional==="all"&&n.additionalProperties===void 0&&oc.default.code(new A0.KeywordCxt(s,oc.default,"additionalProperties"));const o=(0,sc.allSchemaProperties)(r);for(const l of o)s.definedProperties.add(l);s.opts.unevaluated&&o.length&&s.props!==!0&&(s.props=_s.mergeEvaluated.props(t,(0,_s.toHash)(o),s.props));const c=o.filter(l=>!(0,_s.alwaysValidSchema)(s,r[l]));if(c.length===0)return;const u=t.name("valid");for(const l of c)m(l)?a(l):(t.if((0,sc.propertyInData)(t,i,l,s.opts.ownProperties)),a(l),s.allErrors||t.else().var(u,!0),t.endIf()),e.it.definedProperties.add(l),e.ok(u);function m(l){return s.opts.useDefaults&&!s.compositeRule&&r[l].default!==void 0}function a(l){e.subschema({keyword:"properties",schemaProp:l,dataProp:l},u)}}};Vo.default=b0;var qo={};Object.defineProperty(qo,"__esModule",{value:!0});const ac=re,mi=ee,cc=fe,uc=fe,L0={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:r,data:n,parentSchema:i,it:s}=e,{opts:o}=s,c=(0,ac.allSchemaProperties)(r),u=c.filter(y=>(0,cc.alwaysValidSchema)(s,r[y]));if(c.length===0||u.length===c.length&&(!s.opts.unevaluated||s.props===!0))return;const m=o.strictSchema&&!o.allowMatchingProperties&&i.properties,a=t.name("valid");s.props!==!0&&!(s.props instanceof mi.Name)&&(s.props=(0,uc.evaluatedPropsToName)(t,s.props));const{props:l}=s;E();function E(){for(const y of c)m&&h(y),s.allErrors?d(y):(t.var(a,!0),d(y),t.if(a))}function h(y){for(const v in m)new RegExp(y).test(v)&&(0,cc.checkStrictMode)(s,`property ${v} matches pattern ${y} (use allowMatchingProperties)`)}function d(y){t.forIn("key",n,v=>{t.if((0,mi._)`${(0,ac.usePattern)(e,y)}.test(${v})`,()=>{const f=u.includes(y);f||e.subschema({keyword:"patternProperties",schemaProp:y,dataProp:v,dataPropType:uc.Type.Str},a),s.opts.unevaluated&&l!==!0?t.assign((0,mi._)`${l}[${v}]`,!0):!f&&!s.allErrors&&t.if((0,mi.not)(a),()=>t.break())})})}}};qo.default=L0;var Go={};Object.defineProperty(Go,"__esModule",{value:!0});const F0=fe,j0={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:r,it:n}=e;if((0,F0.alwaysValidSchema)(n,r)){e.fail();return}const i=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),e.failResult(i,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};Go.default=j0;var Bo={};Object.defineProperty(Bo,"__esModule",{value:!0});const M0=re,k0={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:M0.validateUnion,error:{message:"must match a schema in anyOf"}};Bo.default=k0;var Ho={};Object.defineProperty(Ho,"__esModule",{value:!0});const Ii=ee,U0=fe,z0={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Ii._)`{passingSchemas: ${e.passing}}`},x0={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:z0,code(e){const{gen:t,schema:r,parentSchema:n,it:i}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(i.opts.discriminator&&n.discriminator)return;const s=r,o=t.let("valid",!1),c=t.let("passing",null),u=t.name("_valid");e.setParams({passing:c}),t.block(m),e.result(o,()=>e.reset(),()=>e.error(!0));function m(){s.forEach((a,l)=>{let E;(0,U0.alwaysValidSchema)(i,a)?t.var(u,!0):E=e.subschema({keyword:"oneOf",schemaProp:l,compositeRule:!0},u),l>0&&t.if((0,Ii._)`${u} && ${o}`).assign(o,!1).assign(c,(0,Ii._)`[${c}, ${l}]`).else(),t.if(u,()=>{t.assign(o,!0),t.assign(c,l),E&&e.mergeEvaluated(E,Ii.Name)})})}}};Ho.default=x0;var Ko={};Object.defineProperty(Ko,"__esModule",{value:!0});const V0=fe,q0={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:r,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");const i=t.name("valid");r.forEach((s,o)=>{if((0,V0.alwaysValidSchema)(n,s))return;const c=e.subschema({keyword:"allOf",schemaProp:o},i);e.ok(i),e.mergeEvaluated(c)})}};Ko.default=q0;var Xo={};Object.defineProperty(Xo,"__esModule",{value:!0});const Mi=ee,Uf=fe,G0={message:({params:e})=>(0,Mi.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,Mi._)`{failingKeyword: ${e.ifClause}}`},B0={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:G0,code(e){const{gen:t,parentSchema:r,it:n}=e;r.then===void 0&&r.else===void 0&&(0,Uf.checkStrictMode)(n,'"if" without "then" and "else" is ignored');const i=fc(n,"then"),s=fc(n,"else");if(!i&&!s)return;const o=t.let("valid",!0),c=t.name("_valid");if(u(),e.reset(),i&&s){const a=t.let("ifClause");e.setParams({ifClause:a}),t.if(c,m("then",a),m("else",a))}else i?t.if(c,m("then")):t.if((0,Mi.not)(c),m("else"));e.pass(o,()=>e.error(!0));function u(){const a=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},c);e.mergeEvaluated(a)}function m(a,l){return()=>{const E=e.subschema({keyword:a},c);t.assign(o,c),e.mergeValidEvaluated(E,o),l?t.assign(l,(0,Mi._)`${a}`):e.setParams({ifClause:a})}}}};function fc(e,t){const r=e.schema[t];return r!==void 0&&!(0,Uf.alwaysValidSchema)(e,r)}Xo.default=B0;var Zo={};Object.defineProperty(Zo,"__esModule",{value:!0});const H0=fe,K0={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){t.if===void 0&&(0,H0.checkStrictMode)(r,`"${e}" without "if" is ignored`)}};Zo.default=K0;Object.defineProperty(Mo,"__esModule",{value:!0});const X0=un,Z0=ko,W0=fn,J0=Uo,Y0=zo,Q0=Mf,ev=xo,tv=es,rv=Vo,nv=qo,iv=Go,sv=Bo,ov=Ho,av=Ko,cv=Xo,uv=Zo;function fv(e=!1){const t=[iv.default,sv.default,ov.default,av.default,cv.default,uv.default,ev.default,tv.default,Q0.default,rv.default,nv.default];return e?t.push(Z0.default,J0.default):t.push(X0.default,W0.default),t.push(Y0.default),t}Mo.default=fv;var Wo={},Jo={};Object.defineProperty(Jo,"__esModule",{value:!0});const Re=ee,lv={message:({schemaCode:e})=>(0,Re.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,Re._)`{format: ${e}}`},dv={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:lv,code(e,t){const{gen:r,data:n,$data:i,schema:s,schemaCode:o,it:c}=e,{opts:u,errSchemaPath:m,schemaEnv:a,self:l}=c;if(!u.validateFormats)return;i?E():h();function E(){const d=r.scopeValue("formats",{ref:l.formats,code:u.code.formats}),y=r.const("fDef",(0,Re._)`${d}[${o}]`),v=r.let("fType"),f=r.let("format");r.if((0,Re._)`typeof ${y} == "object" && !(${y} instanceof RegExp)`,()=>r.assign(v,(0,Re._)`${y}.type || "string"`).assign(f,(0,Re._)`${y}.validate`),()=>r.assign(v,(0,Re._)`"string"`).assign(f,y)),e.fail$data((0,Re.or)($(),w()));function $(){return u.strictSchema===!1?Re.nil:(0,Re._)`${o} && !${f}`}function w(){const T=a.$async?(0,Re._)`(${y}.async ? await ${f}(${n}) : ${f}(${n}))`:(0,Re._)`${f}(${n})`,k=(0,Re._)`(typeof ${f} == "function" ? ${T} : ${f}.test(${n}))`;return(0,Re._)`${f} && ${f} !== true && ${v} === ${t} && !${k}`}}function h(){const d=l.formats[s];if(!d){$();return}if(d===!0)return;const[y,v,f]=w(d);y===t&&e.pass(T());function $(){if(u.strictSchema===!1){l.logger.warn(k());return}throw new Error(k());function k(){return`unknown format "${s}" ignored in schema at path "${m}"`}}function w(k){const O=k instanceof RegExp?(0,Re.regexpCode)(k):u.code.formats?(0,Re._)`${u.code.formats}${(0,Re.getProperty)(s)}`:void 0,D=r.scopeValue("formats",{key:s,ref:k,code:O});return typeof k=="object"&&!(k instanceof RegExp)?[k.type||"string",k.validate,(0,Re._)`${D}.validate`]:["string",k,D]}function T(){if(typeof d=="object"&&!(d instanceof RegExp)&&d.async){if(!a.$async)throw new Error("async format in sync schema");return(0,Re._)`await ${f}(${n})`}return typeof v=="function"?(0,Re._)`${f}(${n})`:(0,Re._)`${f}.test(${n})`}}}};Jo.default=dv;Object.defineProperty(Wo,"__esModule",{value:!0});const hv=Jo,mv=[hv.default];Wo.default=mv;var on={};Object.defineProperty(on,"__esModule",{value:!0});on.contentVocabulary=on.metadataVocabulary=void 0;on.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];on.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"];Object.defineProperty(So,"__esModule",{value:!0});const pv=wo,yv=Io,vv=Mo,Ev=Wo,lc=on,gv=[pv.default,yv.default,(0,vv.default)(),Ev.default,lc.metadataVocabulary,lc.contentVocabulary];So.default=gv;var Yo={},zf={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DiscrError=void 0,function(t){t.Tag="tag",t.Mapping="mapping"}(e.DiscrError||(e.DiscrError={}))})(zf);Object.defineProperty(Yo,"__esModule",{value:!0});const Gr=ee,xs=zf,dc=at,$v=fe,_v={message:({params:{discrError:e,tagName:t}})=>e===xs.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>(0,Gr._)`{error: ${e}, tag: ${r}, tagValue: ${t}}`},Sv={keyword:"discriminator",type:"object",schemaType:"object",error:_v,code(e){const{gen:t,data:r,schema:n,parentSchema:i,it:s}=e,{oneOf:o}=i;if(!s.opts.discriminator)throw new Error("discriminator: requires discriminator option");const c=n.propertyName;if(typeof c!="string")throw new Error("discriminator: requires propertyName");if(n.mapping)throw new Error("discriminator: mapping is not supported");if(!o)throw new Error("discriminator: requires oneOf keyword");const u=t.let("valid",!1),m=t.const("tag",(0,Gr._)`${r}${(0,Gr.getProperty)(c)}`);t.if((0,Gr._)`typeof ${m} == "string"`,()=>a(),()=>e.error(!1,{discrError:xs.DiscrError.Tag,tag:m,tagName:c})),e.ok(u);function a(){const h=E();t.if(!1);for(const d in h)t.elseIf((0,Gr._)`${m} === ${d}`),t.assign(u,l(h[d]));t.else(),e.error(!1,{discrError:xs.DiscrError.Mapping,tag:m,tagName:c}),t.endIf()}function l(h){const d=t.name("valid"),y=e.subschema({keyword:"oneOf",schemaProp:h},d);return e.mergeEvaluated(y,Gr.Name),d}function E(){var h;const d={},y=f(i);let v=!0;for(let T=0;T<o.length;T++){let k=o[T];(k==null?void 0:k.$ref)&&!(0,$v.schemaHasRulesButRef)(k,s.self.RULES)&&(k=dc.resolveRef.call(s.self,s.schemaEnv,s.baseId,k==null?void 0:k.$ref),k instanceof dc.SchemaEnv&&(k=k.schema));const O=(h=k==null?void 0:k.properties)===null||h===void 0?void 0:h[c];if(typeof O!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${c}"`);v=v&&(y||f(k)),$(O,T)}if(!v)throw new Error(`discriminator: "${c}" must be required`);return d;function f({required:T}){return Array.isArray(T)&&T.includes(c)}function $(T,k){if(T.const)w(T.const,k);else if(T.enum)for(const O of T.enum)w(O,k);else throw new Error(`discriminator: "properties/${c}" must have "const" or "enum"`)}function w(T,k){if(typeof T!="string"||T in d)throw new Error(`discriminator: "${c}" values must be unique strings`);d[T]=k}}}};Yo.default=Sv;const wv="http://json-schema.org/draft-07/schema#",Nv="http://json-schema.org/draft-07/schema#",Iv="Core schema meta-schema",Ov={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},Tv=["object","boolean"],Dv={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}};var Rv={$schema:wv,$id:Nv,title:Iv,definitions:Ov,type:Tv,properties:Dv,default:!0};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=void 0;const r=af,n=So,i=Yo,s=Rv,o=["/properties"],c="http://json-schema.org/draft-07/schema";class u extends r.default{_addVocabularies(){super._addVocabularies(),n.default.forEach(E=>this.addVocabulary(E)),this.opts.discriminator&&this.addKeyword(i.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const E=this.opts.$data?this.$dataMetaSchema(s,o):s;this.addMetaSchema(E,c,!1),this.refs["http://json-schema.org/schema"]=c}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(c)?c:void 0)}}e.exports=t=u,Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var m=Tt;Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return m.KeywordCxt}});var a=ee;Object.defineProperty(t,"_",{enumerable:!0,get:function(){return a._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return a.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return a.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return a.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return a.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return a.CodeGen}})})(Ai,Ai.exports);var Vs={exports:{}},xf={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatNames=e.fastFormats=e.fullFormats=void 0;function t(L,U){return{validate:L,compare:U}}e.fullFormats={date:t(s,o),time:t(u,m),"date-time":t(l,E),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:y,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:P,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:f,int32:{type:"number",validate:T},int64:{type:"number",validate:k},float:{type:"number",validate:O},double:{type:"number",validate:O},password:!0,binary:!0},e.fastFormats=vt(Q({},e.fullFormats),{date:t(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,o),time:t(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,m),"date-time":t(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,E),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i}),e.formatNames=Object.keys(e.fullFormats);function r(L){return L%4===0&&(L%100!==0||L%400===0)}const n=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,i=[0,31,28,31,30,31,30,31,31,30,31,30,31];function s(L){const U=n.exec(L);if(!U)return!1;const B=+U[1],z=+U[2],J=+U[3];return z>=1&&z<=12&&J>=1&&J<=(z===2&&r(B)?29:i[z])}function o(L,U){if(!!(L&&U))return L>U?1:L<U?-1:0}const c=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i;function u(L,U){const B=c.exec(L);if(!B)return!1;const z=+B[1],J=+B[2],Z=+B[3],le=B[5];return(z<=23&&J<=59&&Z<=59||z===23&&J===59&&Z===60)&&(!U||le!=="")}function m(L,U){if(!(L&&U))return;const B=c.exec(L),z=c.exec(U);if(!!(B&&z))return L=B[1]+B[2]+B[3]+(B[4]||""),U=z[1]+z[2]+z[3]+(z[4]||""),L>U?1:L<U?-1:0}const a=/t|\s/i;function l(L){const U=L.split(a);return U.length===2&&s(U[0])&&u(U[1],!0)}function E(L,U){if(!(L&&U))return;const[B,z]=L.split(a),[J,Z]=U.split(a),le=o(B,J);if(le!==void 0)return le||m(z,Z)}const h=/\/|:/,d=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function y(L){return h.test(L)&&d.test(L)}const v=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function f(L){return v.lastIndex=0,v.test(L)}const $=-(2**31),w=2**31-1;function T(L){return Number.isInteger(L)&&L<=w&&L>=$}function k(L){return Number.isInteger(L)}function O(){return!0}const D=/[^\\]\\Z/;function P(L){if(D.test(L))return!1;try{return new RegExp(L),!0}catch{return!1}}})(xf);var Vf={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatLimitDefinition=void 0;const t=Ai.exports,r=ee,n=r.operators,i={formatMaximum:{okStr:"<=",ok:n.LTE,fail:n.GT},formatMinimum:{okStr:">=",ok:n.GTE,fail:n.LT},formatExclusiveMaximum:{okStr:"<",ok:n.LT,fail:n.GTE},formatExclusiveMinimum:{okStr:">",ok:n.GT,fail:n.LTE}},s={message:({keyword:c,schemaCode:u})=>r.str`should be ${i[c].okStr} ${u}`,params:({keyword:c,schemaCode:u})=>r._`{comparison: ${i[c].okStr}, limit: ${u}}`};e.formatLimitDefinition={keyword:Object.keys(i),type:"string",schemaType:"string",$data:!0,error:s,code(c){const{gen:u,data:m,schemaCode:a,keyword:l,it:E}=c,{opts:h,self:d}=E;if(!h.validateFormats)return;const y=new t.KeywordCxt(E,d.RULES.all.format.definition,"format");y.$data?v():f();function v(){const w=u.scopeValue("formats",{ref:d.formats,code:h.code.formats}),T=u.const("fmt",r._`${w}[${y.schemaCode}]`);c.fail$data(r.or(r._`typeof ${T} != "object"`,r._`${T} instanceof RegExp`,r._`typeof ${T}.compare != "function"`,$(T)))}function f(){const w=y.schema,T=d.formats[w];if(!T||T===!0)return;if(typeof T!="object"||T instanceof RegExp||typeof T.compare!="function")throw new Error(`"${l}": format "${w}" does not define "compare" function`);const k=u.scopeValue("formats",{key:w,ref:T,code:h.code.formats?r._`${h.code.formats}${r.getProperty(w)}`:void 0});c.fail$data($(k))}function $(w){return r._`${w}.compare(${m}, ${a}) ${i[l].fail} 0`}},dependencies:["format"]};const o=c=>(c.addKeyword(e.formatLimitDefinition),c);e.default=o})(Vf);(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=xf,n=Vf,i=ee,s=new i.Name("fullFormats"),o=new i.Name("fastFormats"),c=(m,a={keywords:!0})=>{if(Array.isArray(a))return u(m,a,r.fullFormats,s),m;const[l,E]=a.mode==="fast"?[r.fastFormats,o]:[r.fullFormats,s],h=a.formats||r.formatNames;return u(m,h,l,E),a.keywords&&n.default(m),m};c.get=(m,a="full")=>{const E=(a==="fast"?r.fastFormats:r.fullFormats)[m];if(!E)throw new Error(`Unknown format "${m}"`);return E};function u(m,a,l,E){var h,d;(h=(d=m.opts.code).formats)!==null&&h!==void 0||(d.formats=i._`require("ajv-formats/dist/formats").${E}`);for(const y of a)m.addFormat(y,l[y])}e.exports=t=c,Object.defineProperty(t,"__esModule",{value:!0}),t.default=c})(Vs,Vs.exports);const Cv=(e,t,r,n)=>{if(r==="length"||r==="prototype"||r==="arguments"||r==="caller")return;const i=Object.getOwnPropertyDescriptor(e,r),s=Object.getOwnPropertyDescriptor(t,r);!Pv(i,s)&&n||Object.defineProperty(e,r,s)},Pv=function(e,t){return e===void 0||e.configurable||e.writable===t.writable&&e.enumerable===t.enumerable&&e.configurable===t.configurable&&(e.writable||e.value===t.value)},Av=(e,t)=>{const r=Object.getPrototypeOf(t);r!==Object.getPrototypeOf(e)&&Object.setPrototypeOf(e,r)},bv=(e,t)=>`/* Wrapped ${e}*/
15
+ ${t}`,Lv=Object.getOwnPropertyDescriptor(Function.prototype,"toString"),Fv=Object.getOwnPropertyDescriptor(Function.prototype.toString,"name"),jv=(e,t,r)=>{const n=r===""?"":`with ${r.trim()}() `,i=bv.bind(null,n,t.toString());Object.defineProperty(i,"name",Fv),Object.defineProperty(e,"toString",vt(Q({},Lv),{value:i}))},Mv=(e,t,{ignoreNonConfigurable:r=!1}={})=>{const{name:n}=e;for(const i of Reflect.ownKeys(t))Cv(e,t,i,r);return Av(e,t),jv(e,t,n),e};var kv=Mv;const Uv=kv;var zv=(e,t={})=>{if(typeof e!="function")throw new TypeError(`Expected the first argument to be a function, got \`${typeof e}\``);const{wait:r=0,before:n=!1,after:i=!0}=t;if(!n&&!i)throw new Error("Both `before` and `after` are false, function wouldn't be called.");let s,o;const c=function(...u){const m=this,a=()=>{s=void 0,i&&(o=e.apply(m,u))},l=n&&!s;return clearTimeout(s),s=setTimeout(a,r),l&&(o=e.apply(m,u)),o};return Uv(c,e),c.cancel=()=>{s&&(clearTimeout(s),s=void 0)},c},lr={exports:{}};const xv="2.0.0",Vv=256,qv=Number.MAX_SAFE_INTEGER||9007199254740991,Gv=16;var ts={SEMVER_SPEC_VERSION:xv,MAX_LENGTH:Vv,MAX_SAFE_INTEGER:qv,MAX_SAFE_COMPONENT_LENGTH:Gv};const Bv=typeof process=="object"&&process.env&&{}.NODE_DEBUG&&/\bsemver\b/i.test({}.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};var rs=Bv;(function(e,t){const{MAX_SAFE_COMPONENT_LENGTH:r}=ts,n=rs;t=e.exports={};const i=t.re=[],s=t.src=[],o=t.t={};let c=0;const u=(m,a,l)=>{const E=c++;n(E,a),o[m]=E,s[E]=a,i[E]=new RegExp(a,l?"g":void 0)};u("NUMERICIDENTIFIER","0|[1-9]\\d*"),u("NUMERICIDENTIFIERLOOSE","[0-9]+"),u("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*"),u("MAINVERSION",`(${s[o.NUMERICIDENTIFIER]})\\.(${s[o.NUMERICIDENTIFIER]})\\.(${s[o.NUMERICIDENTIFIER]})`),u("MAINVERSIONLOOSE",`(${s[o.NUMERICIDENTIFIERLOOSE]})\\.(${s[o.NUMERICIDENTIFIERLOOSE]})\\.(${s[o.NUMERICIDENTIFIERLOOSE]})`),u("PRERELEASEIDENTIFIER",`(?:${s[o.NUMERICIDENTIFIER]}|${s[o.NONNUMERICIDENTIFIER]})`),u("PRERELEASEIDENTIFIERLOOSE",`(?:${s[o.NUMERICIDENTIFIERLOOSE]}|${s[o.NONNUMERICIDENTIFIER]})`),u("PRERELEASE",`(?:-(${s[o.PRERELEASEIDENTIFIER]}(?:\\.${s[o.PRERELEASEIDENTIFIER]})*))`),u("PRERELEASELOOSE",`(?:-?(${s[o.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${s[o.PRERELEASEIDENTIFIERLOOSE]})*))`),u("BUILDIDENTIFIER","[0-9A-Za-z-]+"),u("BUILD",`(?:\\+(${s[o.BUILDIDENTIFIER]}(?:\\.${s[o.BUILDIDENTIFIER]})*))`),u("FULLPLAIN",`v?${s[o.MAINVERSION]}${s[o.PRERELEASE]}?${s[o.BUILD]}?`),u("FULL",`^${s[o.FULLPLAIN]}$`),u("LOOSEPLAIN",`[v=\\s]*${s[o.MAINVERSIONLOOSE]}${s[o.PRERELEASELOOSE]}?${s[o.BUILD]}?`),u("LOOSE",`^${s[o.LOOSEPLAIN]}$`),u("GTLT","((?:<|>)?=?)"),u("XRANGEIDENTIFIERLOOSE",`${s[o.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),u("XRANGEIDENTIFIER",`${s[o.NUMERICIDENTIFIER]}|x|X|\\*`),u("XRANGEPLAIN",`[v=\\s]*(${s[o.XRANGEIDENTIFIER]})(?:\\.(${s[o.XRANGEIDENTIFIER]})(?:\\.(${s[o.XRANGEIDENTIFIER]})(?:${s[o.PRERELEASE]})?${s[o.BUILD]}?)?)?`),u("XRANGEPLAINLOOSE",`[v=\\s]*(${s[o.XRANGEIDENTIFIERLOOSE]})(?:\\.(${s[o.XRANGEIDENTIFIERLOOSE]})(?:\\.(${s[o.XRANGEIDENTIFIERLOOSE]})(?:${s[o.PRERELEASELOOSE]})?${s[o.BUILD]}?)?)?`),u("XRANGE",`^${s[o.GTLT]}\\s*${s[o.XRANGEPLAIN]}$`),u("XRANGELOOSE",`^${s[o.GTLT]}\\s*${s[o.XRANGEPLAINLOOSE]}$`),u("COERCE",`(^|[^\\d])(\\d{1,${r}})(?:\\.(\\d{1,${r}}))?(?:\\.(\\d{1,${r}}))?(?:$|[^\\d])`),u("COERCERTL",s[o.COERCE],!0),u("LONETILDE","(?:~>?)"),u("TILDETRIM",`(\\s*)${s[o.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",u("TILDE",`^${s[o.LONETILDE]}${s[o.XRANGEPLAIN]}$`),u("TILDELOOSE",`^${s[o.LONETILDE]}${s[o.XRANGEPLAINLOOSE]}$`),u("LONECARET","(?:\\^)"),u("CARETTRIM",`(\\s*)${s[o.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",u("CARET",`^${s[o.LONECARET]}${s[o.XRANGEPLAIN]}$`),u("CARETLOOSE",`^${s[o.LONECARET]}${s[o.XRANGEPLAINLOOSE]}$`),u("COMPARATORLOOSE",`^${s[o.GTLT]}\\s*(${s[o.LOOSEPLAIN]})$|^$`),u("COMPARATOR",`^${s[o.GTLT]}\\s*(${s[o.FULLPLAIN]})$|^$`),u("COMPARATORTRIM",`(\\s*)${s[o.GTLT]}\\s*(${s[o.LOOSEPLAIN]}|${s[o.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",u("HYPHENRANGE",`^\\s*(${s[o.XRANGEPLAIN]})\\s+-\\s+(${s[o.XRANGEPLAIN]})\\s*$`),u("HYPHENRANGELOOSE",`^\\s*(${s[o.XRANGEPLAINLOOSE]})\\s+-\\s+(${s[o.XRANGEPLAINLOOSE]})\\s*$`),u("STAR","(<|>)?=?\\s*\\*"),u("GTE0","^\\s*>=\\s*0.0.0\\s*$"),u("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$")})(lr,lr.exports);const Hv=["includePrerelease","loose","rtl"],Kv=e=>e?typeof e!="object"?{loose:!0}:Hv.filter(t=>e[t]).reduce((t,r)=>(t[r]=!0,t),{}):{};var ns=Kv;const hc=/^[0-9]+$/,qf=(e,t)=>{const r=hc.test(e),n=hc.test(t);return r&&n&&(e=+e,t=+t),e===t?0:r&&!n?-1:n&&!r?1:e<t?-1:1},Xv=(e,t)=>qf(t,e);var qs={compareIdentifiers:qf,rcompareIdentifiers:Xv};const pi=rs,{MAX_LENGTH:mc,MAX_SAFE_INTEGER:yi}=ts,{re:pc,t:yc}=lr.exports,Zv=ns,{compareIdentifiers:wn}=qs;class _t{constructor(t,r){if(r=Zv(r),t instanceof _t){if(t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease)return t;t=t.version}else if(typeof t!="string")throw new TypeError(`Invalid Version: ${t}`);if(t.length>mc)throw new TypeError(`version is longer than ${mc} characters`);pi("SemVer",t,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;const n=t.trim().match(r.loose?pc[yc.LOOSE]:pc[yc.FULL]);if(!n)throw new TypeError(`Invalid Version: ${t}`);if(this.raw=t,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>yi||this.major<0)throw new TypeError("Invalid major version");if(this.minor>yi||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>yi||this.patch<0)throw new TypeError("Invalid patch version");n[4]?this.prerelease=n[4].split(".").map(i=>{if(/^[0-9]+$/.test(i)){const s=+i;if(s>=0&&s<yi)return s}return i}):this.prerelease=[],this.build=n[5]?n[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(t){if(pi("SemVer.compare",this.version,this.options,t),!(t instanceof _t)){if(typeof t=="string"&&t===this.version)return 0;t=new _t(t,this.options)}return t.version===this.version?0:this.compareMain(t)||this.comparePre(t)}compareMain(t){return t instanceof _t||(t=new _t(t,this.options)),wn(this.major,t.major)||wn(this.minor,t.minor)||wn(this.patch,t.patch)}comparePre(t){if(t instanceof _t||(t=new _t(t,this.options)),this.prerelease.length&&!t.prerelease.length)return-1;if(!this.prerelease.length&&t.prerelease.length)return 1;if(!this.prerelease.length&&!t.prerelease.length)return 0;let r=0;do{const n=this.prerelease[r],i=t.prerelease[r];if(pi("prerelease compare",r,n,i),n===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(n===void 0)return-1;if(n===i)continue;return wn(n,i)}while(++r)}compareBuild(t){t instanceof _t||(t=new _t(t,this.options));let r=0;do{const n=this.build[r],i=t.build[r];if(pi("prerelease compare",r,n,i),n===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(n===void 0)return-1;if(n===i)continue;return wn(n,i)}while(++r)}inc(t,r){switch(t){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r),this.inc("pre",r);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r),this.inc("pre",r);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let n=this.prerelease.length;for(;--n>=0;)typeof this.prerelease[n]=="number"&&(this.prerelease[n]++,n=-2);n===-1&&this.prerelease.push(0)}r&&(this.prerelease[0]===r?isNaN(this.prerelease[1])&&(this.prerelease=[r,0]):this.prerelease=[r,0]);break;default:throw new Error(`invalid increment argument: ${t}`)}return this.format(),this.raw=this.version,this}}var nt=_t;const{MAX_LENGTH:Wv}=ts,{re:vc,t:Ec}=lr.exports,gc=nt,Jv=ns,Yv=(e,t)=>{if(t=Jv(t),e instanceof gc)return e;if(typeof e!="string"||e.length>Wv||!(t.loose?vc[Ec.LOOSE]:vc[Ec.FULL]).test(e))return null;try{return new gc(e,t)}catch{return null}};var ln=Yv;const Qv=ln,eE=(e,t)=>{const r=Qv(e,t);return r?r.version:null};var tE=eE;const rE=ln,nE=(e,t)=>{const r=rE(e.trim().replace(/^[=v]+/,""),t);return r?r.version:null};var iE=nE;const sE=nt,oE=(e,t,r,n)=>{typeof r=="string"&&(n=r,r=void 0);try{return new sE(e,r).inc(t,n).version}catch{return null}};var aE=oE;const $c=nt,cE=(e,t,r)=>new $c(e,r).compare(new $c(t,r));var Rt=cE;const uE=Rt,fE=(e,t,r)=>uE(e,t,r)===0;var Qo=fE;const _c=ln,lE=Qo,dE=(e,t)=>{if(lE(e,t))return null;{const r=_c(e),n=_c(t),i=r.prerelease.length||n.prerelease.length,s=i?"pre":"",o=i?"prerelease":"";for(const c in r)if((c==="major"||c==="minor"||c==="patch")&&r[c]!==n[c])return s+c;return o}};var hE=dE;const mE=nt,pE=(e,t)=>new mE(e,t).major;var yE=pE;const vE=nt,EE=(e,t)=>new vE(e,t).minor;var gE=EE;const $E=nt,_E=(e,t)=>new $E(e,t).patch;var SE=_E;const wE=ln,NE=(e,t)=>{const r=wE(e,t);return r&&r.prerelease.length?r.prerelease:null};var IE=NE;const OE=Rt,TE=(e,t,r)=>OE(t,e,r);var DE=TE;const RE=Rt,CE=(e,t)=>RE(e,t,!0);var PE=CE;const Sc=nt,AE=(e,t,r)=>{const n=new Sc(e,r),i=new Sc(t,r);return n.compare(i)||n.compareBuild(i)};var ea=AE;const bE=ea,LE=(e,t)=>e.sort((r,n)=>bE(r,n,t));var FE=LE;const jE=ea,ME=(e,t)=>e.sort((r,n)=>jE(n,r,t));var kE=ME;const UE=Rt,zE=(e,t,r)=>UE(e,t,r)>0;var is=zE;const xE=Rt,VE=(e,t,r)=>xE(e,t,r)<0;var ta=VE;const qE=Rt,GE=(e,t,r)=>qE(e,t,r)!==0;var Gf=GE;const BE=Rt,HE=(e,t,r)=>BE(e,t,r)>=0;var ra=HE;const KE=Rt,XE=(e,t,r)=>KE(e,t,r)<=0;var na=XE;const ZE=Qo,WE=Gf,JE=is,YE=ra,QE=ta,eg=na,tg=(e,t,r,n)=>{switch(t){case"===":return typeof e=="object"&&(e=e.version),typeof r=="object"&&(r=r.version),e===r;case"!==":return typeof e=="object"&&(e=e.version),typeof r=="object"&&(r=r.version),e!==r;case"":case"=":case"==":return ZE(e,r,n);case"!=":return WE(e,r,n);case">":return JE(e,r,n);case">=":return YE(e,r,n);case"<":return QE(e,r,n);case"<=":return eg(e,r,n);default:throw new TypeError(`Invalid operator: ${t}`)}};var Bf=tg;const rg=nt,ng=ln,{re:vi,t:Ei}=lr.exports,ig=(e,t)=>{if(e instanceof rg)return e;if(typeof e=="number"&&(e=String(e)),typeof e!="string")return null;t=t||{};let r=null;if(!t.rtl)r=e.match(vi[Ei.COERCE]);else{let n;for(;(n=vi[Ei.COERCERTL].exec(e))&&(!r||r.index+r[0].length!==e.length);)(!r||n.index+n[0].length!==r.index+r[0].length)&&(r=n),vi[Ei.COERCERTL].lastIndex=n.index+n[1].length+n[2].length;vi[Ei.COERCERTL].lastIndex=-1}return r===null?null:ng(`${r[2]}.${r[3]||"0"}.${r[4]||"0"}`,t)};var sg=ig,og=de;de.Node=Rr;de.create=de;function de(e){var t=this;if(t instanceof de||(t=new de),t.tail=null,t.head=null,t.length=0,e&&typeof e.forEach=="function")e.forEach(function(i){t.push(i)});else if(arguments.length>0)for(var r=0,n=arguments.length;r<n;r++)t.push(arguments[r]);return t}de.prototype.removeNode=function(e){if(e.list!==this)throw new Error("removing node which does not belong to this list");var t=e.next,r=e.prev;return t&&(t.prev=r),r&&(r.next=t),e===this.head&&(this.head=t),e===this.tail&&(this.tail=r),e.list.length--,e.next=null,e.prev=null,e.list=null,t};de.prototype.unshiftNode=function(e){if(e!==this.head){e.list&&e.list.removeNode(e);var t=this.head;e.list=this,e.next=t,t&&(t.prev=e),this.head=e,this.tail||(this.tail=e),this.length++}};de.prototype.pushNode=function(e){if(e!==this.tail){e.list&&e.list.removeNode(e);var t=this.tail;e.list=this,e.prev=t,t&&(t.next=e),this.tail=e,this.head||(this.head=e),this.length++}};de.prototype.push=function(){for(var e=0,t=arguments.length;e<t;e++)cg(this,arguments[e]);return this.length};de.prototype.unshift=function(){for(var e=0,t=arguments.length;e<t;e++)ug(this,arguments[e]);return this.length};de.prototype.pop=function(){if(!!this.tail){var e=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,e}};de.prototype.shift=function(){if(!!this.head){var e=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,e}};de.prototype.forEach=function(e,t){t=t||this;for(var r=this.head,n=0;r!==null;n++)e.call(t,r.value,n,this),r=r.next};de.prototype.forEachReverse=function(e,t){t=t||this;for(var r=this.tail,n=this.length-1;r!==null;n--)e.call(t,r.value,n,this),r=r.prev};de.prototype.get=function(e){for(var t=0,r=this.head;r!==null&&t<e;t++)r=r.next;if(t===e&&r!==null)return r.value};de.prototype.getReverse=function(e){for(var t=0,r=this.tail;r!==null&&t<e;t++)r=r.prev;if(t===e&&r!==null)return r.value};de.prototype.map=function(e,t){t=t||this;for(var r=new de,n=this.head;n!==null;)r.push(e.call(t,n.value,this)),n=n.next;return r};de.prototype.mapReverse=function(e,t){t=t||this;for(var r=new de,n=this.tail;n!==null;)r.push(e.call(t,n.value,this)),n=n.prev;return r};de.prototype.reduce=function(e,t){var r,n=this.head;if(arguments.length>1)r=t;else if(this.head)n=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var i=0;n!==null;i++)r=e(r,n.value,i),n=n.next;return r};de.prototype.reduceReverse=function(e,t){var r,n=this.tail;if(arguments.length>1)r=t;else if(this.tail)n=this.tail.prev,r=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var i=this.length-1;n!==null;i--)r=e(r,n.value,i),n=n.prev;return r};de.prototype.toArray=function(){for(var e=new Array(this.length),t=0,r=this.head;r!==null;t++)e[t]=r.value,r=r.next;return e};de.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,r=this.tail;r!==null;t++)e[t]=r.value,r=r.prev;return e};de.prototype.slice=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var r=new de;if(t<e||t<0)return r;e<0&&(e=0),t>this.length&&(t=this.length);for(var n=0,i=this.head;i!==null&&n<e;n++)i=i.next;for(;i!==null&&n<t;n++,i=i.next)r.push(i.value);return r};de.prototype.sliceReverse=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var r=new de;if(t<e||t<0)return r;e<0&&(e=0),t>this.length&&(t=this.length);for(var n=this.length,i=this.tail;i!==null&&n>t;n--)i=i.prev;for(;i!==null&&n>e;n--,i=i.prev)r.push(i.value);return r};de.prototype.splice=function(e,t,...r){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var n=0,i=this.head;i!==null&&n<e;n++)i=i.next;for(var s=[],n=0;i&&n<t;n++)s.push(i.value),i=this.removeNode(i);i===null&&(i=this.tail),i!==this.head&&i!==this.tail&&(i=i.prev);for(var n=0;n<r.length;n++)i=ag(this,i,r[n]);return s};de.prototype.reverse=function(){for(var e=this.head,t=this.tail,r=e;r!==null;r=r.prev){var n=r.prev;r.prev=r.next,r.next=n}return this.head=t,this.tail=e,this};function ag(e,t,r){var n=t===e.head?new Rr(r,null,t,e):new Rr(r,t,t.next,e);return n.next===null&&(e.tail=n),n.prev===null&&(e.head=n),e.length++,n}function cg(e,t){e.tail=new Rr(t,e.tail,null,e),e.head||(e.head=e.tail),e.length++}function ug(e,t){e.head=new Rr(t,null,e.head,e),e.tail||(e.tail=e.head),e.length++}function Rr(e,t,r,n){if(!(this instanceof Rr))return new Rr(e,t,r,n);this.list=n,this.value=e,t?(t.next=this,this.prev=t):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}try{require("./iterator.js")(de)}catch{}const fg=og,Sr=Symbol("max"),Bt=Symbol("length"),qr=Symbol("lengthCalculator"),jn=Symbol("allowStale"),wr=Symbol("maxAge"),Gt=Symbol("dispose"),wc=Symbol("noDisposeOnSet"),je=Symbol("lruList"),St=Symbol("cache"),Hf=Symbol("updateAgeOnGet"),Ss=()=>1;class lg{constructor(t){if(typeof t=="number"&&(t={max:t}),t||(t={}),t.max&&(typeof t.max!="number"||t.max<0))throw new TypeError("max must be a non-negative number");this[Sr]=t.max||1/0;const r=t.length||Ss;if(this[qr]=typeof r!="function"?Ss:r,this[jn]=t.stale||!1,t.maxAge&&typeof t.maxAge!="number")throw new TypeError("maxAge must be a number");this[wr]=t.maxAge||0,this[Gt]=t.dispose,this[wc]=t.noDisposeOnSet||!1,this[Hf]=t.updateAgeOnGet||!1,this.reset()}set max(t){if(typeof t!="number"||t<0)throw new TypeError("max must be a non-negative number");this[Sr]=t||1/0,Nn(this)}get max(){return this[Sr]}set allowStale(t){this[jn]=!!t}get allowStale(){return this[jn]}set maxAge(t){if(typeof t!="number")throw new TypeError("maxAge must be a non-negative number");this[wr]=t,Nn(this)}get maxAge(){return this[wr]}set lengthCalculator(t){typeof t!="function"&&(t=Ss),t!==this[qr]&&(this[qr]=t,this[Bt]=0,this[je].forEach(r=>{r.length=this[qr](r.value,r.key),this[Bt]+=r.length})),Nn(this)}get lengthCalculator(){return this[qr]}get length(){return this[Bt]}get itemCount(){return this[je].length}rforEach(t,r){r=r||this;for(let n=this[je].tail;n!==null;){const i=n.prev;Nc(this,t,n,r),n=i}}forEach(t,r){r=r||this;for(let n=this[je].head;n!==null;){const i=n.next;Nc(this,t,n,r),n=i}}keys(){return this[je].toArray().map(t=>t.key)}values(){return this[je].toArray().map(t=>t.value)}reset(){this[Gt]&&this[je]&&this[je].length&&this[je].forEach(t=>this[Gt](t.key,t.value)),this[St]=new Map,this[je]=new fg,this[Bt]=0}dump(){return this[je].map(t=>ki(this,t)?!1:{k:t.key,v:t.value,e:t.now+(t.maxAge||0)}).toArray().filter(t=>t)}dumpLru(){return this[je]}set(t,r,n){if(n=n||this[wr],n&&typeof n!="number")throw new TypeError("maxAge must be a number");const i=n?Date.now():0,s=this[qr](r,t);if(this[St].has(t)){if(s>this[Sr])return Zr(this,this[St].get(t)),!1;const u=this[St].get(t).value;return this[Gt]&&(this[wc]||this[Gt](t,u.value)),u.now=i,u.maxAge=n,u.value=r,this[Bt]+=s-u.length,u.length=s,this.get(t),Nn(this),!0}const o=new dg(t,r,s,i,n);return o.length>this[Sr]?(this[Gt]&&this[Gt](t,r),!1):(this[Bt]+=o.length,this[je].unshift(o),this[St].set(t,this[je].head),Nn(this),!0)}has(t){if(!this[St].has(t))return!1;const r=this[St].get(t).value;return!ki(this,r)}get(t){return ws(this,t,!0)}peek(t){return ws(this,t,!1)}pop(){const t=this[je].tail;return t?(Zr(this,t),t.value):null}del(t){Zr(this,this[St].get(t))}load(t){this.reset();const r=Date.now();for(let n=t.length-1;n>=0;n--){const i=t[n],s=i.e||0;if(s===0)this.set(i.k,i.v);else{const o=s-r;o>0&&this.set(i.k,i.v,o)}}}prune(){this[St].forEach((t,r)=>ws(this,r,!1))}}const ws=(e,t,r)=>{const n=e[St].get(t);if(n){const i=n.value;if(ki(e,i)){if(Zr(e,n),!e[jn])return}else r&&(e[Hf]&&(n.value.now=Date.now()),e[je].unshiftNode(n));return i.value}},ki=(e,t)=>{if(!t||!t.maxAge&&!e[wr])return!1;const r=Date.now()-t.now;return t.maxAge?r>t.maxAge:e[wr]&&r>e[wr]},Nn=e=>{if(e[Bt]>e[Sr])for(let t=e[je].tail;e[Bt]>e[Sr]&&t!==null;){const r=t.prev;Zr(e,t),t=r}},Zr=(e,t)=>{if(t){const r=t.value;e[Gt]&&e[Gt](r.key,r.value),e[Bt]-=r.length,e[St].delete(r.key),e[je].removeNode(t)}};class dg{constructor(t,r,n,i,s){this.key=t,this.value=r,this.length=n,this.now=i,this.maxAge=s||0}}const Nc=(e,t,r,n)=>{let i=r.value;ki(e,i)&&(Zr(e,r),e[jn]||(i=void 0)),i&&t.call(n,i.value,i.key,e)};var hg=lg;class Mn{constructor(t,r){if(r=pg(r),t instanceof Mn)return t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease?t:new Mn(t.raw,r);if(t instanceof Gs)return this.raw=t.value,this.set=[[t]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=t,this.set=t.split(/\s*\|\|\s*/).map(n=>this.parseRange(n.trim())).filter(n=>n.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${t}`);if(this.set.length>1){const n=this.set[0];if(this.set=this.set.filter(i=>!Oc(i[0])),this.set.length===0)this.set=[n];else if(this.set.length>1){for(const i of this.set)if(i.length===1&&$g(i[0])){this.set=[i];break}}}this.format()}format(){return this.range=this.set.map(t=>t.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(t){t=t.trim();const n=`parseRange:${Object.keys(this.options).join(",")}:${t}`,i=Ic.get(n);if(i)return i;const s=this.options.loose,o=s?Xe[ze.HYPHENRANGELOOSE]:Xe[ze.HYPHENRANGE];t=t.replace(o,Cg(this.options.includePrerelease)),Ce("hyphen replace",t),t=t.replace(Xe[ze.COMPARATORTRIM],vg),Ce("comparator trim",t,Xe[ze.COMPARATORTRIM]),t=t.replace(Xe[ze.TILDETRIM],Eg),t=t.replace(Xe[ze.CARETTRIM],gg),t=t.split(/\s+/).join(" ");const c=s?Xe[ze.COMPARATORLOOSE]:Xe[ze.COMPARATOR],u=t.split(" ").map(l=>_g(l,this.options)).join(" ").split(/\s+/).map(l=>Rg(l,this.options)).filter(this.options.loose?l=>!!l.match(c):()=>!0).map(l=>new Gs(l,this.options));u.length;const m=new Map;for(const l of u){if(Oc(l))return[l];m.set(l.value,l)}m.size>1&&m.has("")&&m.delete("");const a=[...m.values()];return Ic.set(n,a),a}intersects(t,r){if(!(t instanceof Mn))throw new TypeError("a Range is required");return this.set.some(n=>Tc(n,r)&&t.set.some(i=>Tc(i,r)&&n.every(s=>i.every(o=>s.intersects(o,r)))))}test(t){if(!t)return!1;if(typeof t=="string")try{t=new yg(t,this.options)}catch{return!1}for(let r=0;r<this.set.length;r++)if(Pg(this.set[r],t,this.options))return!0;return!1}}var Ct=Mn;const mg=hg,Ic=new mg({max:1e3}),pg=ns,Gs=ss,Ce=rs,yg=nt,{re:Xe,t:ze,comparatorTrimReplace:vg,tildeTrimReplace:Eg,caretTrimReplace:gg}=lr.exports,Oc=e=>e.value==="<0.0.0-0",$g=e=>e.value==="",Tc=(e,t)=>{let r=!0;const n=e.slice();let i=n.pop();for(;r&&n.length;)r=n.every(s=>i.intersects(s,t)),i=n.pop();return r},_g=(e,t)=>(Ce("comp",e,t),e=Ng(e,t),Ce("caret",e),e=Sg(e,t),Ce("tildes",e),e=Og(e,t),Ce("xrange",e),e=Dg(e,t),Ce("stars",e),e),et=e=>!e||e.toLowerCase()==="x"||e==="*",Sg=(e,t)=>e.trim().split(/\s+/).map(r=>wg(r,t)).join(" "),wg=(e,t)=>{const r=t.loose?Xe[ze.TILDELOOSE]:Xe[ze.TILDE];return e.replace(r,(n,i,s,o,c)=>{Ce("tilde",e,n,i,s,o,c);let u;return et(i)?u="":et(s)?u=`>=${i}.0.0 <${+i+1}.0.0-0`:et(o)?u=`>=${i}.${s}.0 <${i}.${+s+1}.0-0`:c?(Ce("replaceTilde pr",c),u=`>=${i}.${s}.${o}-${c} <${i}.${+s+1}.0-0`):u=`>=${i}.${s}.${o} <${i}.${+s+1}.0-0`,Ce("tilde return",u),u})},Ng=(e,t)=>e.trim().split(/\s+/).map(r=>Ig(r,t)).join(" "),Ig=(e,t)=>{Ce("caret",e,t);const r=t.loose?Xe[ze.CARETLOOSE]:Xe[ze.CARET],n=t.includePrerelease?"-0":"";return e.replace(r,(i,s,o,c,u)=>{Ce("caret",e,i,s,o,c,u);let m;return et(s)?m="":et(o)?m=`>=${s}.0.0${n} <${+s+1}.0.0-0`:et(c)?s==="0"?m=`>=${s}.${o}.0${n} <${s}.${+o+1}.0-0`:m=`>=${s}.${o}.0${n} <${+s+1}.0.0-0`:u?(Ce("replaceCaret pr",u),s==="0"?o==="0"?m=`>=${s}.${o}.${c}-${u} <${s}.${o}.${+c+1}-0`:m=`>=${s}.${o}.${c}-${u} <${s}.${+o+1}.0-0`:m=`>=${s}.${o}.${c}-${u} <${+s+1}.0.0-0`):(Ce("no pr"),s==="0"?o==="0"?m=`>=${s}.${o}.${c}${n} <${s}.${o}.${+c+1}-0`:m=`>=${s}.${o}.${c}${n} <${s}.${+o+1}.0-0`:m=`>=${s}.${o}.${c} <${+s+1}.0.0-0`),Ce("caret return",m),m})},Og=(e,t)=>(Ce("replaceXRanges",e,t),e.split(/\s+/).map(r=>Tg(r,t)).join(" ")),Tg=(e,t)=>{e=e.trim();const r=t.loose?Xe[ze.XRANGELOOSE]:Xe[ze.XRANGE];return e.replace(r,(n,i,s,o,c,u)=>{Ce("xRange",e,n,i,s,o,c,u);const m=et(s),a=m||et(o),l=a||et(c),E=l;return i==="="&&E&&(i=""),u=t.includePrerelease?"-0":"",m?i===">"||i==="<"?n="<0.0.0-0":n="*":i&&E?(a&&(o=0),c=0,i===">"?(i=">=",a?(s=+s+1,o=0,c=0):(o=+o+1,c=0)):i==="<="&&(i="<",a?s=+s+1:o=+o+1),i==="<"&&(u="-0"),n=`${i+s}.${o}.${c}${u}`):a?n=`>=${s}.0.0${u} <${+s+1}.0.0-0`:l&&(n=`>=${s}.${o}.0${u} <${s}.${+o+1}.0-0`),Ce("xRange return",n),n})},Dg=(e,t)=>(Ce("replaceStars",e,t),e.trim().replace(Xe[ze.STAR],"")),Rg=(e,t)=>(Ce("replaceGTE0",e,t),e.trim().replace(Xe[t.includePrerelease?ze.GTE0PRE:ze.GTE0],"")),Cg=e=>(t,r,n,i,s,o,c,u,m,a,l,E,h)=>(et(n)?r="":et(i)?r=`>=${n}.0.0${e?"-0":""}`:et(s)?r=`>=${n}.${i}.0${e?"-0":""}`:o?r=`>=${r}`:r=`>=${r}${e?"-0":""}`,et(m)?u="":et(a)?u=`<${+m+1}.0.0-0`:et(l)?u=`<${m}.${+a+1}.0-0`:E?u=`<=${m}.${a}.${l}-${E}`:e?u=`<${m}.${a}.${+l+1}-0`:u=`<=${u}`,`${r} ${u}`.trim()),Pg=(e,t,r)=>{for(let n=0;n<e.length;n++)if(!e[n].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(let n=0;n<e.length;n++)if(Ce(e[n].semver),e[n].semver!==Gs.ANY&&e[n].semver.prerelease.length>0){const i=e[n].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}return!1}return!0},In=Symbol("SemVer ANY");class Ui{static get ANY(){return In}constructor(t,r){if(r=Ag(r),t instanceof Ui){if(t.loose===!!r.loose)return t;t=t.value}Is("comparator",t,r),this.options=r,this.loose=!!r.loose,this.parse(t),this.semver===In?this.value="":this.value=this.operator+this.semver.version,Is("comp",this)}parse(t){const r=this.options.loose?Dc[Rc.COMPARATORLOOSE]:Dc[Rc.COMPARATOR],n=t.match(r);if(!n)throw new TypeError(`Invalid comparator: ${t}`);this.operator=n[1]!==void 0?n[1]:"",this.operator==="="&&(this.operator=""),n[2]?this.semver=new Cc(n[2],this.options.loose):this.semver=In}toString(){return this.value}test(t){if(Is("Comparator.test",t,this.options.loose),this.semver===In||t===In)return!0;if(typeof t=="string")try{t=new Cc(t,this.options)}catch{return!1}return Ns(t,this.operator,this.semver,this.options)}intersects(t,r){if(!(t instanceof Ui))throw new TypeError("a Comparator is required");if((!r||typeof r!="object")&&(r={loose:!!r,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new Pc(t.value,r).test(this.value);if(t.operator==="")return t.value===""?!0:new Pc(this.value,r).test(t.semver);const n=(this.operator===">="||this.operator===">")&&(t.operator===">="||t.operator===">"),i=(this.operator==="<="||this.operator==="<")&&(t.operator==="<="||t.operator==="<"),s=this.semver.version===t.semver.version,o=(this.operator===">="||this.operator==="<=")&&(t.operator===">="||t.operator==="<="),c=Ns(this.semver,"<",t.semver,r)&&(this.operator===">="||this.operator===">")&&(t.operator==="<="||t.operator==="<"),u=Ns(this.semver,">",t.semver,r)&&(this.operator==="<="||this.operator==="<")&&(t.operator===">="||t.operator===">");return n||i||s&&o||c||u}}var ss=Ui;const Ag=ns,{re:Dc,t:Rc}=lr.exports,Ns=Bf,Is=rs,Cc=nt,Pc=Ct,bg=Ct,Lg=(e,t,r)=>{try{t=new bg(t,r)}catch{return!1}return t.test(e)};var os=Lg;const Fg=Ct,jg=(e,t)=>new Fg(e,t).set.map(r=>r.map(n=>n.value).join(" ").trim().split(" "));var Mg=jg;const kg=nt,Ug=Ct,zg=(e,t,r)=>{let n=null,i=null,s=null;try{s=new Ug(t,r)}catch{return null}return e.forEach(o=>{s.test(o)&&(!n||i.compare(o)===-1)&&(n=o,i=new kg(n,r))}),n};var xg=zg;const Vg=nt,qg=Ct,Gg=(e,t,r)=>{let n=null,i=null,s=null;try{s=new qg(t,r)}catch{return null}return e.forEach(o=>{s.test(o)&&(!n||i.compare(o)===1)&&(n=o,i=new Vg(n,r))}),n};var Bg=Gg;const Os=nt,Hg=Ct,Ac=is,Kg=(e,t)=>{e=new Hg(e,t);let r=new Os("0.0.0");if(e.test(r)||(r=new Os("0.0.0-0"),e.test(r)))return r;r=null;for(let n=0;n<e.set.length;++n){const i=e.set[n];let s=null;i.forEach(o=>{const c=new Os(o.semver.version);switch(o.operator){case">":c.prerelease.length===0?c.patch++:c.prerelease.push(0),c.raw=c.format();case"":case">=":(!s||Ac(c,s))&&(s=c);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),s&&(!r||Ac(r,s))&&(r=s)}return r&&e.test(r)?r:null};var Xg=Kg;const Zg=Ct,Wg=(e,t)=>{try{return new Zg(e,t).range||"*"}catch{return null}};var Jg=Wg;const Yg=nt,Kf=ss,{ANY:Qg}=Kf,e$=Ct,t$=os,bc=is,Lc=ta,r$=na,n$=ra,i$=(e,t,r,n)=>{e=new Yg(e,n),t=new e$(t,n);let i,s,o,c,u;switch(r){case">":i=bc,s=r$,o=Lc,c=">",u=">=";break;case"<":i=Lc,s=n$,o=bc,c="<",u="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(t$(e,t,n))return!1;for(let m=0;m<t.set.length;++m){const a=t.set[m];let l=null,E=null;if(a.forEach(h=>{h.semver===Qg&&(h=new Kf(">=0.0.0")),l=l||h,E=E||h,i(h.semver,l.semver,n)?l=h:o(h.semver,E.semver,n)&&(E=h)}),l.operator===c||l.operator===u||(!E.operator||E.operator===c)&&s(e,E.semver))return!1;if(E.operator===u&&o(e,E.semver))return!1}return!0};var ia=i$;const s$=ia,o$=(e,t,r)=>s$(e,t,">",r);var a$=o$;const c$=ia,u$=(e,t,r)=>c$(e,t,"<",r);var f$=u$;const Fc=Ct,l$=(e,t,r)=>(e=new Fc(e,r),t=new Fc(t,r),e.intersects(t));var d$=l$;const h$=os,m$=Rt;var p$=(e,t,r)=>{const n=[];let i=null,s=null;const o=e.sort((a,l)=>m$(a,l,r));for(const a of o)h$(a,t,r)?(s=a,i||(i=a)):(s&&n.push([i,s]),s=null,i=null);i&&n.push([i,null]);const c=[];for(const[a,l]of n)a===l?c.push(a):!l&&a===o[0]?c.push("*"):l?a===o[0]?c.push(`<=${l}`):c.push(`${a} - ${l}`):c.push(`>=${a}`);const u=c.join(" || "),m=typeof t.raw=="string"?t.raw:String(t);return u.length<m.length?u:t};const jc=Ct,Oi=ss,{ANY:Ts}=Oi,On=os,sa=Rt,y$=(e,t,r={})=>{if(e===t)return!0;e=new jc(e,r),t=new jc(t,r);let n=!1;e:for(const i of e.set){for(const s of t.set){const o=v$(i,s,r);if(n=n||o!==null,o)continue e}if(n)return!1}return!0},v$=(e,t,r)=>{if(e===t)return!0;if(e.length===1&&e[0].semver===Ts){if(t.length===1&&t[0].semver===Ts)return!0;r.includePrerelease?e=[new Oi(">=0.0.0-0")]:e=[new Oi(">=0.0.0")]}if(t.length===1&&t[0].semver===Ts){if(r.includePrerelease)return!0;t=[new Oi(">=0.0.0")]}const n=new Set;let i,s;for(const h of e)h.operator===">"||h.operator===">="?i=Mc(i,h,r):h.operator==="<"||h.operator==="<="?s=kc(s,h,r):n.add(h.semver);if(n.size>1)return null;let o;if(i&&s){if(o=sa(i.semver,s.semver,r),o>0)return null;if(o===0&&(i.operator!==">="||s.operator!=="<="))return null}for(const h of n){if(i&&!On(h,String(i),r)||s&&!On(h,String(s),r))return null;for(const d of t)if(!On(h,String(d),r))return!1;return!0}let c,u,m,a,l=s&&!r.includePrerelease&&s.semver.prerelease.length?s.semver:!1,E=i&&!r.includePrerelease&&i.semver.prerelease.length?i.semver:!1;l&&l.prerelease.length===1&&s.operator==="<"&&l.prerelease[0]===0&&(l=!1);for(const h of t){if(a=a||h.operator===">"||h.operator===">=",m=m||h.operator==="<"||h.operator==="<=",i){if(E&&h.semver.prerelease&&h.semver.prerelease.length&&h.semver.major===E.major&&h.semver.minor===E.minor&&h.semver.patch===E.patch&&(E=!1),h.operator===">"||h.operator===">="){if(c=Mc(i,h,r),c===h&&c!==i)return!1}else if(i.operator===">="&&!On(i.semver,String(h),r))return!1}if(s){if(l&&h.semver.prerelease&&h.semver.prerelease.length&&h.semver.major===l.major&&h.semver.minor===l.minor&&h.semver.patch===l.patch&&(l=!1),h.operator==="<"||h.operator==="<="){if(u=kc(s,h,r),u===h&&u!==s)return!1}else if(s.operator==="<="&&!On(s.semver,String(h),r))return!1}if(!h.operator&&(s||i)&&o!==0)return!1}return!(i&&m&&!s&&o!==0||s&&a&&!i&&o!==0||E||l)},Mc=(e,t,r)=>{if(!e)return t;const n=sa(e.semver,t.semver,r);return n>0?e:n<0||t.operator===">"&&e.operator===">="?t:e},kc=(e,t,r)=>{if(!e)return t;const n=sa(e.semver,t.semver,r);return n<0?e:n>0||t.operator==="<"&&e.operator==="<="?t:e};var E$=y$;const Ds=lr.exports;var g$={re:Ds.re,src:Ds.src,tokens:Ds.t,SEMVER_SPEC_VERSION:ts.SEMVER_SPEC_VERSION,SemVer:nt,compareIdentifiers:qs.compareIdentifiers,rcompareIdentifiers:qs.rcompareIdentifiers,parse:ln,valid:tE,clean:iE,inc:aE,diff:hE,major:yE,minor:gE,patch:SE,prerelease:IE,compare:Rt,rcompare:DE,compareLoose:PE,compareBuild:ea,sort:FE,rsort:kE,gt:is,lt:ta,eq:Qo,neq:Gf,gte:ra,lte:na,cmp:Bf,coerce:sg,Comparator:ss,Range:Ct,satisfies:os,toComparators:Mg,maxSatisfying:xg,minSatisfying:Bg,minVersion:Xg,validRange:Jg,outside:ia,gtr:a$,ltr:f$,intersects:d$,simplifyRange:p$,subset:E$},as={exports:{}},oa={exports:{}};const Xf=(e,t)=>{for(const r of Reflect.ownKeys(t))Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r));return e};oa.exports=Xf;oa.exports.default=Xf;const $$=oa.exports,zi=new WeakMap,Zf=(e,t={})=>{if(typeof e!="function")throw new TypeError("Expected a function");let r,n=0;const i=e.displayName||e.name||"<anonymous>",s=function(...o){if(zi.set(s,++n),n===1)r=e.apply(this,o),e=null;else if(t.throw===!0)throw new Error(`Function \`${i}\` can only be called once`);return r};return $$(s,e),zi.set(s,n),s};as.exports=Zf;as.exports.default=Zf;as.exports.callCount=e=>{if(!zi.has(e))throw new Error(`The given function \`${e.name}\` is not wrapped by the \`onetime\` package`);return zi.get(e)};(function(e,t){var r=ir&&ir.__classPrivateFieldSet||function(ne,j,x,C,I){if(C==="m")throw new TypeError("Private method is not writable");if(C==="a"&&!I)throw new TypeError("Private accessor was defined without a setter");if(typeof j=="function"?ne!==j||!I:!j.has(ne))throw new TypeError("Cannot write private member to an object whose class did not declare it");return C==="a"?I.call(ne,x):I?I.value=x:j.set(ne,x),x},n=ir&&ir.__classPrivateFieldGet||function(ne,j,x,C){if(x==="a"&&!C)throw new TypeError("Private accessor was defined without a getter");if(typeof j=="function"?ne!==j||!C:!j.has(ne))throw new TypeError("Cannot read private member from an object whose class did not declare it");return x==="m"?C:x==="a"?C.call(ne):C?C.value:j.get(ne)},i,s,o,c,u,m;Object.defineProperty(t,"__esModule",{value:!0});const a=qi.default,l=an.default,E=Ie.default,h=Jc.default,d=Hs.default,y=Rl.default,v=lm,f=to.exports,$=ao.exports,w=Ut,T=Ai.exports,k=Vs.exports,O=zv,D=g$,P=as.exports,L="aes-256-cbc",U=()=>Object.create(null),B=ne=>ne!=null;let z="";try{delete require.cache[__filename],z=E.dirname((s=(i=e.parent)===null||i===void 0?void 0:i.filename)!==null&&s!==void 0?s:".")}catch{}const J=(ne,j)=>{const x=new Set(["undefined","symbol","function"]),C=typeof j;if(x.has(C))throw new TypeError(`Setting a value of type \`${C}\` for key \`${ne}\` is not allowed as it's not supported by JSON`)},Z="__internal__",le=`${Z}.migrations.version`;class te{constructor(j={}){var x;o.set(this,void 0),c.set(this,void 0),u.set(this,void 0),m.set(this,{}),this._deserialize=_=>JSON.parse(_),this._serialize=_=>JSON.stringify(_,void 0," ");const C=Q({configName:"config",fileExtension:"json",projectSuffix:"nodejs",clearInvalidConfig:!1,accessPropertiesByDotNotation:!0,configFileMode:438},j),I=P(()=>{const _=f.sync({cwd:z}),F=_&&JSON.parse(l.readFileSync(_,"utf8"));return F!=null?F:{}});if(!C.cwd){if(C.projectName||(C.projectName=I().name),!C.projectName)throw new Error("Project name could not be inferred. Please specify the `projectName` option.");C.cwd=$(C.projectName,{suffix:C.projectSuffix}).config}if(r(this,u,C,"f"),C.schema){if(typeof C.schema!="object")throw new TypeError("The `schema` option must be an object.");const _=new T.default({allErrors:!0,useDefaults:!0});(0,k.default)(_);const F={type:"object",properties:C.schema};r(this,o,_.compile(F),"f");for(const[V,q]of Object.entries(C.schema))(q==null?void 0:q.default)&&(n(this,m,"f")[V]=q.default)}C.defaults&&r(this,m,Q(Q({},n(this,m,"f")),C.defaults),"f"),C.serialize&&(this._serialize=C.serialize),C.deserialize&&(this._deserialize=C.deserialize),this.events=new y.EventEmitter,r(this,c,C.encryptionKey,"f");const M=C.fileExtension?`.${C.fileExtension}`:"";this.path=E.resolve(C.cwd,`${(x=C.configName)!==null&&x!==void 0?x:"config"}${M}`);const R=this.store,p=Object.assign(U(),C.defaults,R);this._validate(p);try{d.deepEqual(R,p)}catch{this.store=p}if(C.watch&&this._watch(),C.migrations){if(C.projectVersion||(C.projectVersion=I().version),!C.projectVersion)throw new Error("Project version could not be inferred. Please specify the `projectVersion` option.");this._migrate(C.migrations,C.projectVersion)}}get(j,x){if(n(this,u,"f").accessPropertiesByDotNotation)return this._get(j,x);const{store:C}=this;return j in C?C[j]:x}set(j,x){if(typeof j!="string"&&typeof j!="object")throw new TypeError(`Expected \`key\` to be of type \`string\` or \`object\`, got ${typeof j}`);if(typeof j!="object"&&x===void 0)throw new TypeError("Use `delete()` to clear values");if(this._containsReservedKey(j))throw new TypeError(`Please don't use the ${Z} key, as it's used to manage this module internal operations.`);const{store:C}=this,I=(M,R)=>{J(M,R),n(this,u,"f").accessPropertiesByDotNotation?v.set(C,M,R):C[M]=R};if(typeof j=="object"){const M=j;for(const[R,p]of Object.entries(M))I(R,p)}else I(j,x);this.store=C}has(j){return n(this,u,"f").accessPropertiesByDotNotation?v.has(this.store,j):j in this.store}reset(...j){for(const x of j)B(n(this,m,"f")[x])&&this.set(x,n(this,m,"f")[x])}delete(j){const{store:x}=this;n(this,u,"f").accessPropertiesByDotNotation?v.delete(x,j):delete x[j],this.store=x}clear(){this.store=U();for(const j of Object.keys(n(this,m,"f")))this.reset(j)}onDidChange(j,x){if(typeof j!="string")throw new TypeError(`Expected \`key\` to be of type \`string\`, got ${typeof j}`);if(typeof x!="function")throw new TypeError(`Expected \`callback\` to be of type \`function\`, got ${typeof x}`);return this._handleChange(()=>this.get(j),x)}onDidAnyChange(j){if(typeof j!="function")throw new TypeError(`Expected \`callback\` to be of type \`function\`, got ${typeof j}`);return this._handleChange(()=>this.store,j)}get size(){return Object.keys(this.store).length}get store(){try{const j=l.readFileSync(this.path,n(this,c,"f")?null:"utf8"),x=this._encryptData(j),C=this._deserialize(x);return this._validate(C),Object.assign(U(),C)}catch(j){if((j==null?void 0:j.code)==="ENOENT")return this._ensureDirectory(),U();if(n(this,u,"f").clearInvalidConfig&&j.name==="SyntaxError")return U();throw j}}set store(j){this._ensureDirectory(),this._validate(j),this._write(j),this.events.emit("change")}*[(o=new WeakMap,c=new WeakMap,u=new WeakMap,m=new WeakMap,Symbol.iterator)](){for(const[j,x]of Object.entries(this.store))yield[j,x]}_encryptData(j){if(!n(this,c,"f"))return j.toString();try{if(n(this,c,"f"))try{if(j.slice(16,17).toString()===":"){const x=j.slice(0,16),C=h.pbkdf2Sync(n(this,c,"f"),x.toString(),1e4,32,"sha512"),I=h.createDecipheriv(L,C,x);j=Buffer.concat([I.update(Buffer.from(j.slice(17))),I.final()]).toString("utf8")}else{const x=h.createDecipher(L,n(this,c,"f"));j=Buffer.concat([x.update(Buffer.from(j)),x.final()]).toString("utf8")}}catch{}}catch{}return j.toString()}_handleChange(j,x){let C=j();const I=()=>{const M=C,R=j();(0,a.isDeepStrictEqual)(R,M)||(C=R,x.call(this,R,M))};return this.events.on("change",I),()=>this.events.removeListener("change",I)}_validate(j){if(!n(this,o,"f")||n(this,o,"f").call(this,j)||!n(this,o,"f").errors)return;const C=n(this,o,"f").errors.map(({instancePath:I,message:M=""})=>`\`${I.slice(1)}\` ${M}`);throw new Error("Config schema violation: "+C.join("; "))}_ensureDirectory(){l.mkdirSync(E.dirname(this.path),{recursive:!0})}_write(j){let x=this._serialize(j);if(n(this,c,"f")){const C=h.randomBytes(16),I=h.pbkdf2Sync(n(this,c,"f"),C.toString(),1e4,32,"sha512"),M=h.createCipheriv(L,I,C);x=Buffer.concat([C,Buffer.from(":"),M.update(Buffer.from(x)),M.final()])}try{w.writeFileSync(this.path,x,{mode:n(this,u,"f").configFileMode})}catch(C){if((C==null?void 0:C.code)==="EXDEV"){l.writeFileSync(this.path,x,{mode:n(this,u,"f").configFileMode});return}throw C}}_watch(){this._ensureDirectory(),l.existsSync(this.path)||this._write(U()),process.platform==="win32"?l.watch(this.path,{persistent:!1},O(()=>{this.events.emit("change")},{wait:100})):l.watchFile(this.path,{persistent:!1},O(()=>{this.events.emit("change")},{wait:5e3}))}_migrate(j,x){let C=this._get(le,"0.0.0");const I=Object.keys(j).filter(R=>this._shouldPerformMigration(R,C,x));let M=Q({},this.store);for(const R of I)try{j[R](this),this._set(le,R),C=R,M=Q({},this.store)}catch(p){throw this.store=M,new Error(`Something went wrong during the migration! Changes applied to the store until this failed migration will be restored. ${p}`)}(this._isVersionInRangeFormat(C)||!D.eq(C,x))&&this._set(le,x)}_containsReservedKey(j){return typeof j=="object"&&Object.keys(j)[0]===Z?!0:typeof j!="string"?!1:n(this,u,"f").accessPropertiesByDotNotation?!!j.startsWith(`${Z}.`):!1}_isVersionInRangeFormat(j){return D.clean(j)===null}_shouldPerformMigration(j,x,C){return this._isVersionInRangeFormat(j)?x!=="0.0.0"&&D.satisfies(x,j)?!1:D.satisfies(C,j):!(D.lte(j,x)||D.gt(j,C))}_get(j,x){return v.get(this.store,j,x)}_set(j,x){const{store:C}=this;v.set(C,j,x),this.store=C}}t.default=te,e.exports=te,e.exports.default=te})(Ls,Ls.exports);const Uc=Ie.default,{app:Ti,ipcMain:Bs,ipcRenderer:zc,shell:_$}=Ol.default,S$=Ls.exports;let xc=!1;const Vc=()=>{if(!Bs||!Ti)throw new Error("Electron Store: You need to call `.initRenderer()` from the main process.");const e={defaultCwd:Ti.getPath("userData"),appVersion:Ti.getVersion()};return xc||(Bs.on("electron-store-get-data",t=>{t.returnValue=e}),xc=!0),e};class w$ extends S${constructor(t){let r,n;if(zc){const i=zc.sendSync("electron-store-get-data");if(!i)throw new Error("Electron Store: You need to call `.initRenderer()` from the main process.");({defaultCwd:r,appVersion:n}=i)}else Bs&&Ti&&({defaultCwd:r,appVersion:n}=Vc());t=Q({name:"config"},t),t.projectVersion||(t.projectVersion=n),t.cwd?t.cwd=Uc.isAbsolute(t.cwd)?t.cwd:Uc.join(r,t.cwd):t.cwd=r,t.configName=t.name,delete t.name;super(t)}static initRenderer(){Vc()}openInEditor(){_$.openPath(this.path)}}var qc=w$,Zt={exports:{}},aa={},N$=aa.require=function(){if(typeof process=="object"&&process.versions&&process.versions.electron)try{const e=N$("original-fs");if(Object.keys(e).length>0)return e}catch{}return an.default},Wf={LOCHDR:30,LOCSIG:67324752,LOCVER:4,LOCFLG:6,LOCHOW:8,LOCTIM:10,LOCCRC:14,LOCSIZ:18,LOCLEN:22,LOCNAM:26,LOCEXT:28,EXTSIG:134695760,EXTHDR:16,EXTCRC:4,EXTSIZ:8,EXTLEN:12,CENHDR:46,CENSIG:33639248,CENVEM:4,CENVER:6,CENFLG:8,CENHOW:10,CENTIM:12,CENCRC:16,CENSIZ:20,CENLEN:24,CENNAM:28,CENEXT:30,CENCOM:32,CENDSK:34,CENATT:36,CENATX:38,CENOFF:42,ENDHDR:22,ENDSIG:101010256,ENDSUB:8,ENDTOT:10,ENDSIZ:12,ENDOFF:16,ENDCOM:20,END64HDR:20,END64SIG:117853008,END64START:4,END64OFF:8,END64NUMDISKS:16,ZIP64SIG:101075792,ZIP64HDR:56,ZIP64LEAD:12,ZIP64SIZE:4,ZIP64VEM:12,ZIP64VER:14,ZIP64DSK:16,ZIP64DSKDIR:20,ZIP64SUB:24,ZIP64TOT:32,ZIP64SIZB:40,ZIP64OFF:48,ZIP64EXTRA:56,STORED:0,SHRUNK:1,REDUCED1:2,REDUCED2:3,REDUCED3:4,REDUCED4:5,IMPLODED:6,DEFLATED:8,ENHANCED_DEFLATED:9,PKWARE:10,BZIP2:12,LZMA:14,IBM_TERSE:18,IBM_LZ77:19,AES_ENCRYPT:99,FLG_ENC:1,FLG_COMP1:2,FLG_COMP2:4,FLG_DESC:8,FLG_ENH:16,FLG_PATCH:32,FLG_STR:64,FLG_EFS:2048,FLG_MSK:4096,FILE:2,BUFFER:1,NONE:0,EF_ID:0,EF_SIZE:2,ID_ZIP64:1,ID_AVINFO:7,ID_PFS:8,ID_OS2:9,ID_NTFS:10,ID_OPENVMS:12,ID_UNIX:13,ID_FORK:14,ID_PATCH:15,ID_X509_PKCS7:20,ID_X509_CERTID_F:21,ID_X509_CERTID_C:22,ID_STRONGENC:23,ID_RECORD_MGT:24,ID_X509_PKCS7_RL:25,ID_IBM1:101,ID_IBM2:102,ID_POSZIP:18064,EF_ZIP64_OR_32:4294967295,EF_ZIP64_OR_16:65535,EF_ZIP64_SUNCOMP:0,EF_ZIP64_SCOMP:8,EF_ZIP64_RHO:16,EF_ZIP64_DSN:24};const I$=aa.require(),Qe=Ie.default,Gc=Wf,O$=typeof process=="object"&&process.platform==="win32",Bc=e=>e&&typeof e=="object",ca=new Uint32Array(256).map((e,t)=>{for(let r=0;r<8;r++)(t&1)!==0?t=3988292384^t>>>1:t>>>=1;return t>>>0});function Ge(e){this.sep=Qe.sep,this.fs=I$,Bc(e)&&Bc(e.fs)&&typeof e.fs.statSync=="function"&&(this.fs=e.fs)}var T$=Ge;Ge.prototype.makeDir=function(e){const t=this;function r(n){let i=n.split(t.sep)[0];n.split(t.sep).forEach(function(s){if(!(!s||s.substr(-1,1)===":")){i+=t.sep+s;var o;try{o=t.fs.statSync(i)}catch{t.fs.mkdirSync(i)}if(o&&o.isFile())throw Errors.FILE_IN_THE_WAY.replace("%s",i)}})}r(e)};Ge.prototype.writeFileTo=function(e,t,r,n){const i=this;if(i.fs.existsSync(e)){if(!r)return!1;var s=i.fs.statSync(e);if(s.isDirectory())return!1}var o=Qe.dirname(e);i.fs.existsSync(o)||i.makeDir(o);var c;try{c=i.fs.openSync(e,"w",438)}catch{i.fs.chmodSync(e,438),c=i.fs.openSync(e,"w",438)}if(c)try{i.fs.writeSync(c,t,0,t.length,0)}finally{i.fs.closeSync(c)}return i.fs.chmodSync(e,n||438),!0};Ge.prototype.writeFileToAsync=function(e,t,r,n,i){typeof n=="function"&&(i=n,n=void 0);const s=this;s.fs.exists(e,function(o){if(o&&!r)return i(!1);s.fs.stat(e,function(c,u){if(o&&u.isDirectory())return i(!1);var m=Qe.dirname(e);s.fs.exists(m,function(a){a||s.makeDir(m),s.fs.open(e,"w",438,function(l,E){l?s.fs.chmod(e,438,function(){s.fs.open(e,"w",438,function(h,d){s.fs.write(d,t,0,t.length,0,function(){s.fs.close(d,function(){s.fs.chmod(e,n||438,function(){i(!0)})})})})}):E?s.fs.write(E,t,0,t.length,0,function(){s.fs.close(E,function(){s.fs.chmod(e,n||438,function(){i(!0)})})}):s.fs.chmod(e,n||438,function(){i(!0)})})})})})};Ge.prototype.findFiles=function(e){const t=this;function r(n,i,s){typeof i=="boolean"&&(s=i,i=void 0);let o=[];return t.fs.readdirSync(n).forEach(function(c){var u=Qe.join(n,c);t.fs.statSync(u).isDirectory()&&s&&(o=o.concat(r(u,i,s))),(!i||i.test(u))&&o.push(Qe.normalize(u)+(t.fs.statSync(u).isDirectory()?t.sep:""))}),o}return r(e,void 0,!0)};Ge.prototype.getAttributes=function(){};Ge.prototype.setAttributes=function(){};Ge.crc32update=function(e,t){return ca[(e^t)&255]^e>>>8};Ge.crc32=function(e){typeof e=="string"&&(e=Buffer.from(e,"utf8")),ca.length||genCRCTable();let t=e.length,r=-1;for(let n=0;n<t;)r=Ge.crc32update(r,e[n++]);return~r>>>0};Ge.methodToString=function(e){switch(e){case Gc.STORED:return"STORED ("+e+")";case Gc.DEFLATED:return"DEFLATED ("+e+")";default:return"UNSUPPORTED ("+e+")"}};Ge.canonical=function(e){if(!e)return"";var t=Qe.posix.normalize("/"+e.split("\\").join("/"));return Qe.join(".",t)};Ge.sanitize=function(e,t){e=Qe.resolve(Qe.normalize(e));for(var r=t.split("/"),n=0,i=r.length;n<i;n++){var s=Qe.normalize(Qe.join(e,r.slice(n,i).join(Qe.sep)));if(s.indexOf(e)===0)return s}return Qe.normalize(Qe.join(e,Qe.basename(t)))};Ge.toBuffer=function(t){return Buffer.isBuffer(t)?t:t instanceof Uint8Array?Buffer.from(t):typeof t=="string"?Buffer.from(t,"utf8"):Buffer.alloc(0)};Ge.readBigUInt64LE=function(e,t){var r=Buffer.from(e.slice(t,t+8));return r.swap64(),parseInt(`0x${r.toString("hex")}`)};Ge.isWin=O$;Ge.crcTable=ca;var D$={INVALID_LOC:"Invalid LOC header (bad signature)",INVALID_CEN:"Invalid CEN header (bad signature)",INVALID_END:"Invalid END header (bad signature)",NO_DATA:"Nothing to decompress",BAD_CRC:"CRC32 checksum failed",FILE_IN_THE_WAY:"There is a file in the way: %s",UNKNOWN_METHOD:"Invalid/unsupported compression method",AVAIL_DATA:"inflate::Available inflate data did not terminate",INVALID_DISTANCE:"inflate::Invalid literal/length or distance code in fixed or dynamic block",TO_MANY_CODES:"inflate::Dynamic block code description: too many length or distance codes",INVALID_REPEAT_LEN:"inflate::Dynamic block code description: repeat more than specified lengths",INVALID_REPEAT_FIRST:"inflate::Dynamic block code description: repeat lengths with no first length",INCOMPLETE_CODES:"inflate::Dynamic block code description: code lengths codes incomplete",INVALID_DYN_DISTANCE:"inflate::Dynamic block code description: invalid distance code lengths",INVALID_CODES_LEN:"inflate::Dynamic block code description: invalid literal/length code lengths",INVALID_STORE_BLOCK:"inflate::Stored block length did not match one's complement",INVALID_BLOCK_TYPE:"inflate::Invalid block type (type == 3)",CANT_EXTRACT_FILE:"Could not extract the file",CANT_OVERRIDE:"Target file already exists",NO_ZIP:"No zip file was loaded",NO_ENTRY:"Entry doesn't exist",DIRECTORY_CONTENT_ERROR:"A directory cannot have content",FILE_NOT_FOUND:"File not found: %s",NOT_IMPLEMENTED:"Not implemented",INVALID_FILENAME:"Invalid filename",INVALID_FORMAT:"Invalid or unsupported zip format. No END header found"};const xi=aa.require(),Jf=Ie.default;xi.existsSync=xi.existsSync||Jf.existsSync;var R$=function(e){var t=e||"",r=i(),n=null;function i(){return{directory:!1,readonly:!1,hidden:!1,executable:!1,mtime:0,atime:0}}return t&&xi.existsSync(t)?(n=xi.statSync(t),r.directory=n.isDirectory(),r.mtime=n.mtime,r.atime=n.atime,r.executable=(73&n.mode)!==0,r.readonly=(128&n.mode)===0,r.hidden=Jf.basename(t)[0]==="."):console.warn("Invalid path: "+t),{get directory(){return r.directory},get readOnly(){return r.readonly},get hidden(){return r.hidden},get mtime(){return r.mtime},get atime(){return r.atime},get executable(){return r.executable},decodeAttributes:function(){},encodeAttributes:function(){},toJSON:function(){return{path:t,isDirectory:r.directory,isReadOnly:r.readonly,isHidden:r.hidden,isExecutable:r.executable,mTime:r.mtime,aTime:r.atime}},toString:function(){return JSON.stringify(this.toJSON(),null," ")}}};Zt.exports=T$;Zt.exports.Constants=Wf;Zt.exports.Errors=D$;Zt.exports.FileAttr=R$;var cs={},Dn=Zt.exports,G=Dn.Constants,C$=function(){var e=20,t=10,r=0,n=0,i=0,s=0,o=0,c=0,u=0,m=0,a=0,l=0,E=0,h=0,d=0;e|=Dn.isWin?2560:768,r|=G.FLG_EFS;var y={};function v(f){f=new Date(f),i=(f.getFullYear()-1980&127)<<25|f.getMonth()+1<<21|f.getDate()<<16|f.getHours()<<11|f.getMinutes()<<5|f.getSeconds()>>1}return v(+new Date),{get made(){return e},set made(f){e=f},get version(){return t},set version(f){t=f},get flags(){return r},set flags(f){r=f},get method(){return n},set method(f){switch(f){case G.STORED:this.version=10;case G.DEFLATED:default:this.version=20}n=f},get time(){return new Date((i>>25&127)+1980,(i>>21&15)-1,i>>16&31,i>>11&31,i>>5&63,(i&31)<<1)},set time(f){v(f)},get crc(){return s},set crc(f){s=Math.max(0,f)>>>0},get compressedSize(){return o},set compressedSize(f){o=Math.max(0,f)>>>0},get size(){return c},set size(f){c=Math.max(0,f)>>>0},get fileNameLength(){return u},set fileNameLength(f){u=f},get extraLength(){return m},set extraLength(f){m=f},get commentLength(){return a},set commentLength(f){a=f},get diskNumStart(){return l},set diskNumStart(f){l=Math.max(0,f)>>>0},get inAttr(){return E},set inAttr(f){E=Math.max(0,f)>>>0},get attr(){return h},set attr(f){h=Math.max(0,f)>>>0},get fileAttr(){return h?(h>>>0|0)>>16&4095:0},get offset(){return d},set offset(f){d=Math.max(0,f)>>>0},get encripted(){return(r&1)===1},get entryHeaderSize(){return G.CENHDR+u+m+a},get realDataOffset(){return d+G.LOCHDR+y.fnameLen+y.extraLen},get dataHeader(){return y},loadDataHeaderFromBinary:function(f){var $=f.slice(d,d+G.LOCHDR);if($.readUInt32LE(0)!==G.LOCSIG)throw new Error(Dn.Errors.INVALID_LOC);y={version:$.readUInt16LE(G.LOCVER),flags:$.readUInt16LE(G.LOCFLG),method:$.readUInt16LE(G.LOCHOW),time:$.readUInt32LE(G.LOCTIM),crc:$.readUInt32LE(G.LOCCRC),compressedSize:$.readUInt32LE(G.LOCSIZ),size:$.readUInt32LE(G.LOCLEN),fnameLen:$.readUInt16LE(G.LOCNAM),extraLen:$.readUInt16LE(G.LOCEXT)}},loadFromBinary:function(f){if(f.length!==G.CENHDR||f.readUInt32LE(0)!==G.CENSIG)throw new Error(Dn.Errors.INVALID_CEN);e=f.readUInt16LE(G.CENVEM),t=f.readUInt16LE(G.CENVER),r=f.readUInt16LE(G.CENFLG),n=f.readUInt16LE(G.CENHOW),i=f.readUInt32LE(G.CENTIM),s=f.readUInt32LE(G.CENCRC),o=f.readUInt32LE(G.CENSIZ),c=f.readUInt32LE(G.CENLEN),u=f.readUInt16LE(G.CENNAM),m=f.readUInt16LE(G.CENEXT),a=f.readUInt16LE(G.CENCOM),l=f.readUInt16LE(G.CENDSK),E=f.readUInt16LE(G.CENATT),h=f.readUInt32LE(G.CENATX),d=f.readUInt32LE(G.CENOFF)},dataHeaderToBinary:function(){var f=Buffer.alloc(G.LOCHDR);return f.writeUInt32LE(G.LOCSIG,0),f.writeUInt16LE(t,G.LOCVER),f.writeUInt16LE(r,G.LOCFLG),f.writeUInt16LE(n,G.LOCHOW),f.writeUInt32LE(i,G.LOCTIM),f.writeUInt32LE(s,G.LOCCRC),f.writeUInt32LE(o,G.LOCSIZ),f.writeUInt32LE(c,G.LOCLEN),f.writeUInt16LE(u,G.LOCNAM),f.writeUInt16LE(m,G.LOCEXT),f},entryHeaderToBinary:function(){var f=Buffer.alloc(G.CENHDR+u+m+a);return f.writeUInt32LE(G.CENSIG,0),f.writeUInt16LE(e,G.CENVEM),f.writeUInt16LE(t,G.CENVER),f.writeUInt16LE(r,G.CENFLG),f.writeUInt16LE(n,G.CENHOW),f.writeUInt32LE(i,G.CENTIM),f.writeUInt32LE(s,G.CENCRC),f.writeUInt32LE(o,G.CENSIZ),f.writeUInt32LE(c,G.CENLEN),f.writeUInt16LE(u,G.CENNAM),f.writeUInt16LE(m,G.CENEXT),f.writeUInt16LE(a,G.CENCOM),f.writeUInt16LE(l,G.CENDSK),f.writeUInt16LE(E,G.CENATT),f.writeUInt32LE(h,G.CENATX),f.writeUInt32LE(d,G.CENOFF),f.fill(0,G.CENHDR),f},toJSON:function(){const f=function($){return $+" bytes"};return{made:e,version:t,flags:r,method:Dn.methodToString(n),time:this.time,crc:"0x"+s.toString(16).toUpperCase(),compressedSize:f(o),size:f(c),fileNameLength:f(u),extraLength:f(m),commentLength:f(a),diskNumStart:l,inAttr:E,attr:h,offset:d,entryHeaderSize:f(G.CENHDR+u+m+a)}},toString:function(){return JSON.stringify(this.toJSON(),null," ")}}},Br=Zt.exports,we=Br.Constants,P$=function(){var e=0,t=0,r=0,n=0,i=0;return{get diskEntries(){return e},set diskEntries(s){e=t=s},get totalEntries(){return t},set totalEntries(s){t=e=s},get size(){return r},set size(s){r=s},get offset(){return n},set offset(s){n=s},get commentLength(){return i},set commentLength(s){i=s},get mainHeaderSize(){return we.ENDHDR+i},loadFromBinary:function(s){if((s.length!==we.ENDHDR||s.readUInt32LE(0)!==we.ENDSIG)&&(s.length<we.ZIP64HDR||s.readUInt32LE(0)!==we.ZIP64SIG))throw new Error(Br.Errors.INVALID_END);s.readUInt32LE(0)===we.ENDSIG?(e=s.readUInt16LE(we.ENDSUB),t=s.readUInt16LE(we.ENDTOT),r=s.readUInt32LE(we.ENDSIZ),n=s.readUInt32LE(we.ENDOFF),i=s.readUInt16LE(we.ENDCOM)):(e=Br.readBigUInt64LE(s,we.ZIP64SUB),t=Br.readBigUInt64LE(s,we.ZIP64TOT),r=Br.readBigUInt64LE(s,we.ZIP64SIZ),n=Br.readBigUInt64LE(s,we.ZIP64OFF),i=0)},toBinary:function(){var s=Buffer.alloc(we.ENDHDR+i);return s.writeUInt32LE(we.ENDSIG,0),s.writeUInt32LE(0,4),s.writeUInt16LE(e,we.ENDSUB),s.writeUInt16LE(t,we.ENDTOT),s.writeUInt32LE(r,we.ENDSIZ),s.writeUInt32LE(n,we.ENDOFF),s.writeUInt16LE(i,we.ENDCOM),s.fill(" ",we.ENDHDR),s},toJSON:function(){const s=function(o,c){let u=o.toString(16).toUpperCase();for(;u.length<c;)u="0"+u;return"0x"+u};return{diskEntries:e,totalEntries:t,size:r+" bytes",offset:s(n,4),commentLength:i}},toString:function(){return JSON.stringify(this.toJSON(),null," ")}}};cs.EntryHeader=C$;cs.MainHeader=P$;var us={},A$=function(e){var t=Yc.default,r={chunkSize:(parseInt(e.length/1024)+1)*1024};return{deflate:function(){return t.deflateRawSync(e,r)},deflateAsync:function(n){var i=t.createDeflateRaw(r),s=[],o=0;i.on("data",function(c){s.push(c),o+=c.length}),i.on("end",function(){var c=Buffer.alloc(o),u=0;c.fill(0);for(var m=0;m<s.length;m++){var a=s[m];a.copy(c,u),u+=a.length}n&&n(c)}),i.end(e)}}},b$=function(e){var t=Yc.default;return{inflate:function(){return t.inflateRawSync(e)},inflateAsync:function(r){var n=t.createInflateRaw(),i=[],s=0;n.on("data",function(o){i.push(o),s+=o.length}),n.on("end",function(){var o=Buffer.alloc(s),c=0;o.fill(0);for(var u=0;u<i.length;u++){var m=i[u];m.copy(o,c),c+=m.length}r&&r(o)}),n.end(e)}}};const{randomFillSync:Hc}=Jc.default,L$=new Uint32Array(256).map((e,t)=>{for(let r=0;r<8;r++)(t&1)!==0?t=t>>>1^3988292384:t>>>=1;return t>>>0}),Yf=(e,t)=>Math.imul(e,t)>>>0,Kc=(e,t)=>L$[(e^t)&255]^e>>>8,Bn=()=>typeof Hc=="function"?Hc(Buffer.alloc(12)):Bn.node();Bn.node=()=>{const e=Buffer.alloc(12),t=e.length;for(let r=0;r<t;r++)e[r]=Math.random()*256&255;return e};const Di={genSalt:Bn};function fs(e){const t=Buffer.isBuffer(e)?e:Buffer.from(e);this.keys=new Uint32Array([305419896,591751049,878082192]);for(let r=0;r<t.length;r++)this.updateKeys(t[r])}fs.prototype.updateKeys=function(e){const t=this.keys;return t[0]=Kc(t[0],e),t[1]+=t[0]&255,t[1]=Yf(t[1],134775813)+1,t[2]=Kc(t[2],t[1]>>>24),e};fs.prototype.next=function(){const e=(this.keys[2]|2)>>>0;return Yf(e,e^1)>>8&255};function F$(e){const t=new fs(e);return function(r){const n=Buffer.alloc(r.length);let i=0;for(let s of r)n[i++]=t.updateKeys(s^t.next());return n}}function j$(e){const t=new fs(e);return function(r,n,i=0){n||(n=Buffer.alloc(r.length));for(let s of r){const o=t.next();n[i++]=s^o,t.updateKeys(s)}return n}}function M$(e,t,r){if(!e||!Buffer.isBuffer(e)||e.length<12)return Buffer.alloc(0);const n=F$(r);if(n(e.slice(0,12))[11]!==t.crc>>>24)throw"ADM-ZIP: Wrong Password";return n(e.slice(12))}function k$(e){Buffer.isBuffer(e)&&e.length>=12?Di.genSalt=function(){return e.slice(0,12)}:e==="node"?Di.genSalt=Bn.node:Di.genSalt=Bn}function U$(e,t,r,n=!1){e==null&&(e=Buffer.alloc(0)),Buffer.isBuffer(e)||(e=Buffer.from(e.toString()));const i=j$(r),s=Di.genSalt();s[11]=t.crc>>>24&255,n&&(s[10]=t.crc>>>16&255);const o=Buffer.alloc(e.length+12);return i(s,o),i(e,o,12)}var z$={decrypt:M$,encrypt:U$,_salter:k$};us.Deflater=A$;us.Inflater=b$;us.ZipCrypto=z$;var Ae=Zt.exports,x$=cs,ft=Ae.Constants,Rs=us,Qf=function(e){var t=new x$.EntryHeader,r=Buffer.alloc(0),n=Buffer.alloc(0),i=!1,s=null,o=Buffer.alloc(0);function c(){return!e||!Buffer.isBuffer(e)?Buffer.alloc(0):(t.loadDataHeaderFromBinary(e),e.slice(t.realDataOffset,t.realDataOffset+t.compressedSize))}function u(d){return!((t.flags&8)!==8&&Ae.crc32(d)!==t.dataHeader.crc)}function m(d,y,v){if(typeof y=="undefined"&&typeof d=="string"&&(v=d,d=void 0),i)return d&&y&&y(Buffer.alloc(0),Ae.Errors.DIRECTORY_CONTENT_ERROR),Buffer.alloc(0);var f=c();if(f.length===0)return d&&y&&y(f),f;if(t.encripted){if(typeof v!="string"&&!Buffer.isBuffer(v))throw new Error("ADM-ZIP: Incompatible password parameter");f=Rs.ZipCrypto.decrypt(f,t,v)}var $=Buffer.alloc(t.size);switch(t.method){case Ae.Constants.STORED:if(f.copy($),u($))return d&&y&&y($),$;throw d&&y&&y($,Ae.Errors.BAD_CRC),new Error(Ae.Errors.BAD_CRC);case Ae.Constants.DEFLATED:var w=new Rs.Inflater(f);if(d)w.inflateAsync(function(T){T.copy(T,0),y&&(u(T)?y(T):y(T,Ae.Errors.BAD_CRC))});else{if(w.inflate($).copy($,0),!u($))throw new Error(Ae.Errors.BAD_CRC+" "+r.toString());return $}break;default:throw d&&y&&y(Buffer.alloc(0),Ae.Errors.UNKNOWN_METHOD),new Error(Ae.Errors.UNKNOWN_METHOD)}}function a(d,y){if((!s||!s.length)&&Buffer.isBuffer(e))return d&&y&&y(c()),c();if(s.length&&!i){var v;switch(t.method){case Ae.Constants.STORED:return t.compressedSize=t.size,v=Buffer.alloc(s.length),s.copy(v),d&&y&&y(v),v;default:case Ae.Constants.DEFLATED:var f=new Rs.Deflater(s);if(d)f.deflateAsync(function(w){v=Buffer.alloc(w.length),t.compressedSize=w.length,w.copy(v),y&&y(v)});else{var $=f.deflate();return t.compressedSize=$.length,$}f=null;break}}else if(d&&y)y(Buffer.alloc(0));else return Buffer.alloc(0)}function l(d,y){return(d.readUInt32LE(y+4)<<4)+d.readUInt32LE(y)}function E(d){for(var y=0,v,f,$;y<d.length;)v=d.readUInt16LE(y),y+=2,f=d.readUInt16LE(y),y+=2,$=d.slice(y,y+f),y+=f,ft.ID_ZIP64===v&&h($)}function h(d){var y,v,f,$;d.length>=ft.EF_ZIP64_SCOMP&&(y=l(d,ft.EF_ZIP64_SUNCOMP),t.size===ft.EF_ZIP64_OR_32&&(t.size=y)),d.length>=ft.EF_ZIP64_RHO&&(v=l(d,ft.EF_ZIP64_SCOMP),t.compressedSize===ft.EF_ZIP64_OR_32&&(t.compressedSize=v)),d.length>=ft.EF_ZIP64_DSN&&(f=l(d,ft.EF_ZIP64_RHO),t.offset===ft.EF_ZIP64_OR_32&&(t.offset=f)),d.length>=ft.EF_ZIP64_DSN+4&&($=d.readUInt32LE(ft.EF_ZIP64_DSN),t.diskNumStart===ft.EF_ZIP64_OR_16&&(t.diskNumStart=$))}return{get entryName(){return r.toString()},get rawEntryName(){return r},set entryName(d){r=Ae.toBuffer(d);var y=r[r.length-1];i=y===47||y===92,t.fileNameLength=r.length},get extra(){return o},set extra(d){o=d,t.extraLength=d.length,E(d)},get comment(){return n.toString()},set comment(d){n=Ae.toBuffer(d),t.commentLength=n.length},get name(){var d=r.toString();return i?d.substr(d.length-1).split("/").pop():d.split("/").pop()},get isDirectory(){return i},getCompressedData:function(){return a(!1,null)},getCompressedDataAsync:function(d){a(!0,d)},setData:function(d){s=Ae.toBuffer(d),!i&&s.length?(t.size=s.length,t.method=Ae.Constants.DEFLATED,t.crc=Ae.crc32(d),t.changed=!0):t.method=Ae.Constants.STORED},getData:function(d){return t.changed?s:m(!1,null,d)},getDataAsync:function(d,y){t.changed?d(s):m(!0,d,y)},set attr(d){t.attr=d},get attr(){return t.attr},set header(d){t.loadFromBinary(d)},get header(){return t},packHeader:function(){var d=t.entryHeaderToBinary(),y=Ae.Constants.CENHDR;return r.copy(d,y),y+=r.length,t.extraLength&&(o.copy(d,y),y+=t.extraLength),t.commentLength&&n.copy(d,y),d},toJSON:function(){const d=function(y){return"<"+(y&&y.length+" bytes buffer"||"null")+">"};return{entryName:this.entryName,name:this.name,comment:this.comment,isDirectory:this.isDirectory,header:t.toJSON(),compressedData:d(e),data:d(s)}},toString:function(){return JSON.stringify(this.toJSON(),null," ")}}};const Xc=Qf,V$=cs,Ke=Zt.exports;var q$=function(e,t){var r=[],n={},i=Buffer.alloc(0),s=new V$.MainHeader,o=!1;const c=Object.assign(Object.create(null),t),{noSort:u}=c;e?l(c.readEntries):o=!0;function m(h){const d=s.diskEntries;let y=s.offset;for(let v=0;v<d;v++){let f=y;const $=new Xc(e);$.header=e.slice(f,f+=Ke.Constants.CENHDR),$.entryName=e.slice(f,f+=$.header.fileNameLength),y+=$.header.entryHeaderSize,h($)}}function a(){o=!0,n={},r=new Array(s.diskEntries);for(var h=s.offset,d=0;d<r.length;d++){var y=h,v=new Xc(e);v.header=e.slice(y,y+=Ke.Constants.CENHDR),v.entryName=e.slice(y,y+=v.header.fileNameLength),v.header.extraLength&&(v.extra=e.slice(y,y+=v.header.extraLength)),v.header.commentLength&&(v.comment=e.slice(y,y+v.header.commentLength)),h+=v.header.entryHeaderSize,r[d]=v,n[v.entryName]=v}}function l(h){var d=e.length-Ke.Constants.ENDHDR,y=Math.max(0,d-65535),v=y,f=e.length,$=-1,w=0;for(d;d>=v;d--)if(e[d]===80){if(e.readUInt32LE(d)===Ke.Constants.ENDSIG){$=d,w=d,f=d+Ke.Constants.ENDHDR,v=d-Ke.Constants.END64HDR;continue}if(e.readUInt32LE(d)===Ke.Constants.END64SIG){v=y;continue}if(e.readUInt32LE(d)===Ke.Constants.ZIP64SIG){$=d,f=d+Ke.readBigUInt64LE(e,d+Ke.Constants.ZIP64SIZE)+Ke.Constants.ZIP64LEAD;break}}if(!~$)throw new Error(Ke.Errors.INVALID_FORMAT);s.loadFromBinary(e.slice($,f)),s.commentLength&&(i=e.slice(w+Ke.Constants.ENDHDR)),h&&a()}function E(){r.length>1&&!u&&r.sort((h,d)=>h.entryName.toLowerCase().localeCompare(d.entryName.toLowerCase()))}return{get entries(){return o||a(),r},get comment(){return i.toString()},set comment(h){i=Ke.toBuffer(h),s.commentLength=i.length},getEntryCount:function(){return o?r.length:s.diskEntries},forEach:function(h){if(!o){m(h);return}r.forEach(h)},getEntry:function(h){return o||a(),n[h]||null},setEntry:function(h){o||a(),r.push(h),n[h.entryName]=h,s.totalEntries=r.length},deleteEntry:function(h){o||a();var d=n[h];if(d&&d.isDirectory){var y=this;this.getEntryChildren(d).forEach(function(v){v.entryName!==h&&y.deleteEntry(v.entryName)})}r.splice(r.indexOf(d),1),delete n[h],s.totalEntries=r.length},getEntryChildren:function(h){if(o||a(),h&&h.isDirectory){const d=[],y=h.entryName,v=y.length;return r.forEach(function(f){f.entryName.substr(0,v)===y&&d.push(f)}),d}return[]},compressToBuffer:function(){o||a(),E();const h=[],d=[];let y=0,v=0;s.size=0,s.offset=0;for(const w of r){const T=w.getCompressedData();w.header.offset=v;const k=w.header.dataHeaderToBinary(),O=w.rawEntryName.length,D=Buffer.alloc(O+w.extra.length);w.rawEntryName.copy(D,0),D.copy(w.extra,O);const P=k.length+D.length+T.length;v+=P,h.push(k),h.push(D),h.push(T);const L=w.packHeader();d.push(L),s.size+=L.length,y+=P+L.length}y+=s.mainHeaderSize,s.offset=v,v=0;const f=Buffer.alloc(y);for(const w of h)w.copy(f,v),v+=w.length;for(const w of d)w.copy(f,v),v+=w.length;const $=s.toBinary();return i&&i.copy($,Ke.Constants.ENDHDR),$.copy(f,v),f},toAsyncBuffer:function(h,d,y,v){try{o||a(),E();const f=[],$=[];let w=0,T=0;s.size=0,s.offset=0;const k=function(O){if(O.length){const D=O.pop(),P=D.entryName+D.extra.toString();y&&y(P),D.getCompressedDataAsync(function(L){v&&v(P),D.header.offset=T;const U=D.header.dataHeaderToBinary(),B=Buffer.alloc(P.length,P),z=U.length+B.length+L.length;T+=z,f.push(U),f.push(B),f.push(L);const J=D.packHeader();$.push(J),s.size+=J.length,w+=z+J.length,k(O)})}else{w+=s.mainHeaderSize,s.offset=T,T=0;const D=Buffer.alloc(w);f.forEach(function(L){L.copy(D,T),T+=L.length}),$.forEach(function(L){L.copy(D,T),T+=L.length});const P=s.toBinary();i&&i.copy(P,Ke.Constants.ENDHDR),P.copy(D,T),h(D)}};k(r)}catch(f){d(f)}}}};const Le=Zt.exports,Mt=Ie.default,G$=Qf,B$=q$,Er=(e,t)=>typeof e=="boolean"?e:t,Cs=(e,t)=>typeof e=="string"?e:t,H$={noSort:!1,readEntries:!1,method:Le.Constants.NONE,fs:null};var Zc=function(e,t){let r=null;const n=Object.assign(Object.create(null),H$);e&&typeof e=="object"&&(e instanceof Uint8Array||(Object.assign(n,e),e=n.input?n.input:void 0,n.input&&delete n.input),Buffer.isBuffer(e)&&(r=e,n.method=Le.Constants.BUFFER,e=void 0)),Object.assign(n,t);const i=new Le(n);if(e&&typeof e=="string")if(i.fs.existsSync(e))n.method=Le.Constants.FILE,n.filename=e,r=i.fs.readFileSync(e);else throw new Error(Le.Errors.INVALID_FILENAME);const s=new B$(r,n),{canonical:o,sanitize:c}=Le;function u(a){if(a&&s){var l;if(typeof a=="string"&&(l=s.getEntry(a)),typeof a=="object"&&typeof a.entryName!="undefined"&&typeof a.header!="undefined"&&(l=s.getEntry(a.entryName)),l)return l}return null}function m(a){const{join:l,normalize:E,sep:h}=Mt.posix;return l(".",E(h+a.split("\\").join(h)+h))}return{readFile:function(a,l){var E=u(a);return E&&E.getData(l)||null},readFileAsync:function(a,l){var E=u(a);E?E.getDataAsync(l):l(null,"getEntry failed for:"+a)},readAsText:function(a,l){var E=u(a);if(E){var h=E.getData();if(h&&h.length)return h.toString(l||"utf8")}return""},readAsTextAsync:function(a,l,E){var h=u(a);h?h.getDataAsync(function(d,y){if(y){l(d,y);return}d&&d.length?l(d.toString(E||"utf8")):l("")}):l("")},deleteFile:function(a){var l=u(a);l&&s.deleteEntry(l.entryName)},addZipComment:function(a){s.comment=a},getZipComment:function(){return s.comment||""},addZipEntryComment:function(a,l){var E=u(a);E&&(E.comment=l)},getZipEntryComment:function(a){var l=u(a);return l&&l.comment||""},updateFile:function(a,l){var E=u(a);E&&E.setData(l)},addLocalFile:function(a,l,E,h){if(i.fs.existsSync(a)){l=l?m(l):"";var d=a.split("\\").join("/").split("/").pop();l+=E||d;const y=i.fs.statSync(a);this.addFile(l,i.fs.readFileSync(a),h,y)}else throw new Error(Le.Errors.FILE_NOT_FOUND.replace("%s",a))},addLocalFolder:function(a,l,E){if(E instanceof RegExp?E=function(h){return function(d){return h.test(d)}}(E):typeof E!="function"&&(E=function(){return!0}),l=l?m(l):"",a=Mt.normalize(a),i.fs.existsSync(a)){const h=i.findFiles(a),d=this;h.length&&h.forEach(function(y){var v=Mt.relative(a,y).split("\\").join("/");if(E(v)){var f=i.fs.statSync(y);f.isFile()?d.addFile(l+v,i.fs.readFileSync(y),"",f):d.addFile(l+v+"/",Buffer.alloc(0),"",f)}})}else throw new Error(Le.Errors.FILE_NOT_FOUND.replace("%s",a))},addLocalFolderAsync:function(a,l,E,h){h instanceof RegExp?h=function(y){return function(v){return y.test(v)}}(h):typeof h!="function"&&(h=function(){return!0}),E=E?m(E):"",a=Mt.normalize(a);var d=this;i.fs.open(a,"r",function(y){if(y&&y.code==="ENOENT")l(void 0,Le.Errors.FILE_NOT_FOUND.replace("%s",a));else if(y)l(void 0,y);else{var v=i.findFiles(a),f=-1,$=function(){if(f+=1,f<v.length){var w=v[f],T=Mt.relative(a,w).split("\\").join("/");T=T.normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/[^\x20-\x7E]/g,""),h(T)?i.fs.stat(w,function(k,O){k&&l(void 0,k),O.isFile()?i.fs.readFile(w,function(D,P){D?l(void 0,D):(d.addFile(E+T,P,"",O),$())}):(d.addFile(E+T+"/",Buffer.alloc(0),"",O),$())}):$()}else l(!0,void 0)};$()}})},addLocalFolderPromise:function(a,l){return new Promise((E,h)=>{const{filter:d,zipPath:y}=Object.assign({},l);this.addLocalFolderAsync(a,(v,f)=>{f&&h(f),v&&E(this)},y,d)})},addFile:function(a,l,E,h){let d=u(a);const y=d!=null;y||(d=new G$,d.entryName=a),d.comment=E||"";const v=typeof h=="object"&&h instanceof i.fs.Stats;v&&(d.header.time=h.mtime);var f=d.isDirectory?16:0;if(!Le.isWin){let $=d.isDirectory?16384:32768;v?$|=4095&h.mode:typeof h=="number"?$|=4095&h:$|=d.isDirectory?493:420,f=(f|$<<16)>>>0}d.attr=f,d.setData(l),y||s.setEntry(d)},getEntries:function(){return s?s.entries:[]},getEntry:function(a){return u(a)},getEntryCount:function(){return s.getEntryCount()},forEach:function(a){return s.forEach(a)},extractEntryTo:function(a,l,E,h,d,y){h=Er(h,!1),d=Er(d,!1),E=Er(E,!0),y=Cs(y,Cs(d,void 0));var v=u(a);if(!v)throw new Error(Le.Errors.NO_ENTRY);var f=o(v.entryName),$=c(l,y&&!v.isDirectory?y:E?f:Mt.basename(f));if(v.isDirectory){var w=s.getEntryChildren(v);return w.forEach(function(O){if(O.isDirectory)return;var D=O.getData();if(!D)throw new Error(Le.Errors.CANT_EXTRACT_FILE);var P=o(O.entryName),L=c(l,E?P:Mt.basename(P));const U=d?O.header.fileAttr:void 0;i.writeFileTo(L,D,h,U)}),!0}var T=v.getData();if(!T)throw new Error(Le.Errors.CANT_EXTRACT_FILE);if(i.fs.existsSync($)&&!h)throw new Error(Le.Errors.CANT_OVERRIDE);const k=d?a.header.fileAttr:void 0;return i.writeFileTo($,T,h,k),!0},test:function(a){if(!s)return!1;for(var l in s.entries)try{if(l.isDirectory)continue;var E=s.entries[l].getData(a);if(!E)return!1}catch{return!1}return!0},extractAllTo:function(a,l,E,h){if(l=Er(l,!1),h=Cs(E,h),E=Er(E,!1),!s)throw new Error(Le.Errors.NO_ZIP);s.entries.forEach(function(d){var y=c(a,o(d.entryName.toString()));if(d.isDirectory){i.makeDir(y);return}var v=d.getData(h);if(!v)throw new Error(Le.Errors.CANT_EXTRACT_FILE);const f=E?d.header.fileAttr:void 0;i.writeFileTo(y,v,l,f);try{i.fs.utimesSync(y,d.header.time,d.header.time)}catch{throw new Error(Le.Errors.CANT_EXTRACT_FILE)}})},extractAllToAsync:function(a,l,E,h){if(h||(h=function(){}),l=Er(l,!1),typeof E=="function"&&!h&&(h=E),E=Er(E,!1),!s){h(new Error(Le.Errors.NO_ZIP));return}a=Mt.resolve(a);const d=w=>c(a,Mt.normalize(o(w.entryName.toString()))),y=(w,T)=>new Error(w+': "'+T+'"'),v=[],f=new Set;s.entries.forEach(w=>{w.isDirectory?v.push(w):f.add(w)});for(const w of v){const T=d(w),k=E?w.header.fileAttr:void 0;try{i.makeDir(T),k&&i.fs.chmodSync(T,k),i.fs.utimesSync(T,w.header.time,w.header.time)}catch{h(y("Unable to create folder",T))}}const $=()=>{f.size===0&&h()};for(const w of f.values()){const T=Mt.normalize(o(w.entryName.toString())),k=c(a,T);w.getDataAsync(function(O,D){if(D){h(new Error(D));return}if(!O)h(new Error(Le.Errors.CANT_EXTRACT_FILE));else{const P=E?w.header.fileAttr:void 0;i.writeFileToAsync(k,O,l,P,function(L){if(!L){h(y("Unable to write file",k));return}i.fs.utimes(k,w.header.time,w.header.time,function(U){if(U){h(y("Unable to set times",k));return}f.delete(w),$()})})}})}$()},writeZip:function(a,l){if(arguments.length===1&&typeof a=="function"&&(l=a,a=""),!a&&n.filename&&(a=n.filename),!!a){var E=s.compressToBuffer();if(E){var h=i.writeFileTo(a,E,!0);typeof l=="function"&&l(h?null:new Error("failed"),"")}}},writeZipPromise:function(a,l){const{overwrite:E,perm:h}=Object.assign({overwrite:!0},l);return new Promise((d,y)=>{!a&&n.filename&&(a=n.filename),a||y("ADM-ZIP: ZIP File Name Missing"),this.toBufferPromise().then(v=>{const f=$=>$?d($):y("ADM-ZIP: Wasn't able to write zip file");i.writeFileToAsync(a,v,E,h,f)},y)})},toBufferPromise:function(){return new Promise((a,l)=>{s.toAsyncBuffer(a,l)})},toBuffer:function(a,l,E,h){return this.valueOf=2,typeof a=="function"?(s.toAsyncBuffer(a,l,E,h),null):s.compressToBuffer()}}},Hn,Wr,Jr,Kn,Nr,Ir,rr,nr,Vi,Yr,Xn,Wc,Zn,Nt,Qr,Ps,Wn,Ht;const wt=class{constructor(t,r){ke(this,Xn);ke(this,Qr);ke(this,Hn,ce.screen.getPrimaryDisplay().size);ke(this,Wr,oe(this,Hn).width);ke(this,Jr,oe(this,Hn).height);ke(this,Kn,{getAppPath:ce.app.getAppPath(),isPackaged:ce.app.isPackaged,downloads:ce.app.getPath("downloads"),userData:ce.app.getPath("userData"),getVersion:"",env:Q({},process.env),platform:process.platform,arch:process.arch});ke(this,Nr,0);ke(this,Ir,0);ke(this,rr,0);ke(this,nr,0);ke(this,Vi,process.platform==="win32");ke(this,Yr,void 0);ke(this,Zn,!1);ke(this,Nt,!1);this.bw=t,oe(this,Kn).getVersion=r,ce.ipcMain.handle("getInfo",()=>oe(this,Kn)),ce.ipcMain.handle("existsSync",(i,s)=>Et.existsSync(s)),ce.ipcMain.handle("copySync",(i,s,o)=>Et.copySync(s,o)),ce.ipcMain.handle("removeSync",(i,s)=>Et.removeSync(s)),ce.ipcMain.handle("ensureFileSync",(i,s)=>Et.ensureFileSync(s)),ce.ipcMain.handle("readFileSync",(i,s)=>Et.readFileSync(s,{encoding:"utf8"})),ce.ipcMain.handle("readFile",(i,s,o)=>Et.readFile(s,o)),ce.ipcMain.handle("writeFileSync",(i,s,o,c)=>Et.writeFileSync(s,o,c)),ce.ipcMain.handle("appendFile",(i,s,o,c)=>Et.appendFile(s,o,c)),ce.ipcMain.handle("win_close",()=>t.close()),ce.ipcMain.handle("win_setTitle",(i,s)=>t.setTitle(s)),ce.ipcMain.handle("showMessageBox",(i,s)=>ce.dialog.showMessageBox(s)),ce.ipcMain.handle("capturePage",(i,s)=>t.webContents.capturePage().then(o=>Et.writeFileSync(s,s.slice(-4)===".png"?o.toPNG():o.toJPEG(80)))),ce.ipcMain.handle("navigate_to",(i,s)=>ce.shell.openExternal(s)),ce.ipcMain.handle("openDevTools",()=>t.webContents.openDevTools()),ce.ipcMain.handle("win_ev_devtools_opened",(i,s)=>t.webContents.on("devtools-opened",s));let n;ce.ipcMain.handle("Store",(i,s)=>{n=new qc(s)}),ce.ipcMain.handle("flush",(i,s)=>{n.store=s}),ce.ipcMain.handle("Store_isEmpty",()=>n.size===0),ce.ipcMain.handle("Store_get",()=>n.store),ce.ipcMain.handle("zip",(i,s,o)=>{const c=new Zc;c.addLocalFolder(s),c.writeZip(o)}),ce.ipcMain.handle("unzip",(i,s,o)=>{Et.removeSync(o),Et.ensureDirSync(o),new Zc(s).extractAllTo(o,!0)}),ce.ipcMain.handle("isSimpleFullScreen",()=>t.simpleFullScreen),oe(this,Vi)?(ce.ipcMain.handle("setSimpleFullScreen",(i,s)=>{Be(this,Nt,!0),t.setSimpleFullScreen(s),s||(t.setPosition(oe(this,Nr),oe(this,Ir)),t.setContentSize(oe(this,rr),oe(this,nr)+oe(wt,Ht))),Be(this,Nt,!1)}),t.on("enter-full-screen",()=>{t.setContentSize(oe(this,Wr),oe(this,Jr)-oe(wt,Ht))}),t.on("leave-full-screen",()=>{Ur(this,Qr,Ps).call(this,!1,oe(this,Nr),oe(this,Ir),oe(this,rr),oe(this,nr)+oe(wt,Ht))})):ce.ipcMain.handle("setSimpleFullScreen",(i,s)=>{t.setSimpleFullScreen(s),s||t.setContentSize(oe(this,rr),oe(this,nr)+oe(wt,Ht))}),ce.ipcMain.handle("window",(i,s,o,c,u,m)=>Ur(this,Qr,Ps).call(this,s,o,c,u,m)),t.on("move",()=>Ur(this,Xn,Wc).call(this))}openDevTools(){this.bw.webContents.openDevTools()}static initRenderer(t,r,n){let i=()=>{},s;try{qc.initRenderer(),process.env.ELECTRON_DISABLE_SECURITY_WARNINGS="true",s=new ce.BrowserWindow(vt(Q({},n),{fullscreenable:!0,maximizable:!1,webPreferences:{nativeWindowOpen:!0,enableRemoteModule:!1,nodeIntegration:!1,contextIsolation:!0,preload:`${__dirname}/preload.js`}})),s.setMenuBarVisibility(!1);const o=s.getContentSize()[1];s.setMenuBarVisibility(!0);const c=s.getContentSize()[1];Be(wt,Ht,o-c),Be(wt,Wn,new wt(s,r)),i=()=>oe(wt,Wn).openDevTools(),s.loadFile(t)}catch(o){throw console.error(`ealy err:${o}`),i(),"initRenderer error"}return s}};let kn=wt;Hn=new WeakMap,Wr=new WeakMap,Jr=new WeakMap,Kn=new WeakMap,Nr=new WeakMap,Ir=new WeakMap,rr=new WeakMap,nr=new WeakMap,Vi=new WeakMap,Yr=new WeakMap,Xn=new WeakSet,Wc=function(){if(oe(this,Yr)||oe(this,Nt))return;Be(this,Nt,!0);const{x:t,y:r}=this.bw.getBounds();Be(this,Yr,setTimeout(()=>{if(Be(this,Yr,void 0),oe(this,Zn)){Be(this,Zn,!1);return}Be(this,Nt,!1);const n=this.bw.getBounds();if(t!==n.x||r!==n.y){Ur(this,Xn,Wc).call(this);return}Ur(this,Qr,Ps).call(this,!1,n.x,n.y,oe(this,rr),oe(this,nr))},1e3/60*10))},Zn=new WeakMap,Nt=new WeakMap,Qr=new WeakSet,Ps=function(t,r,n,i,s){oe(this,Nt)||(Be(this,Nt,!0),!this.bw.simpleFullScreen&&(t?([r,n]=this.bw.getPosition(),r=(oe(this,Wr)-r)*.5,n=(oe(this,Jr)-n)*.5):((r<0||r>oe(this,Wr))&&(r=0),(n<0||n>oe(this,Jr))&&(n=0)),(oe(this,Nr)!==r||oe(this,Ir)!==n)&&(Be(this,Nr,r),Be(this,Ir,n),this.bw.webContents.send("save_win_pos",r,n),this.bw.setPosition(r,n)),Be(this,rr,i),Be(this,nr,s),this.bw.setContentSize(i,s+oe(wt,Ht)),Be(this,Nt,!1)))},Wn=new WeakMap,Ht=new WeakMap,ke(kn,Wn,void 0),ke(kn,Ht,0);module.exports=kn;exports.appMain=kn;
16
+ //# sourceMappingURL=appMain.js.map