@griddo/cx 10.3.13 → 10.3.15

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 (61) hide show
  1. package/README.md +53 -30
  2. package/build/build-complete.js +24 -20
  3. package/build/download-data.js +53 -0
  4. package/build/index.js +35 -47
  5. package/build/reset-render.js +25 -21
  6. package/exporter/adapters/astro/index.ts +37 -0
  7. package/exporter/adapters/astro/utils.ts +29 -0
  8. package/exporter/adapters/gatsby/index.ts +86 -0
  9. package/exporter/adapters/gatsby/utils.ts +352 -0
  10. package/exporter/adapters/index.ts +5 -0
  11. package/{scripts → exporter}/build-complete.ts +16 -14
  12. package/exporter/download-data.ts +6 -0
  13. package/exporter/index-width-adapter.ts +25 -0
  14. package/exporter/index.ts +14 -0
  15. package/exporter/reset-render.ts +12 -0
  16. package/{src → exporter}/services/auth.ts +0 -2
  17. package/{src → exporter}/services/distributors.ts +10 -1
  18. package/{src → exporter}/services/robots.ts +9 -6
  19. package/exporter/services/store.ts +351 -0
  20. package/{src → exporter}/types/api.ts +6 -0
  21. package/{src → exporter}/types/pages.ts +18 -17
  22. package/{src → exporter}/types/sites.ts +1 -1
  23. package/{src → exporter}/utils/api.ts +10 -7
  24. package/{src → exporter}/utils/cache.ts +14 -8
  25. package/{src → exporter}/utils/domains.ts +3 -3
  26. package/exporter/utils/download-build-data.ts +22 -0
  27. package/exporter/utils/folders.ts +49 -0
  28. package/{src → exporter}/utils/health-checks.ts +8 -7
  29. package/{src → exporter}/utils/instance.ts +1 -1
  30. package/{src/utils/integrations.tsx → exporter/utils/integrations.ts} +6 -4
  31. package/{src → exporter}/utils/pages.ts +21 -24
  32. package/exporter/utils/runners.ts +53 -0
  33. package/{src → exporter}/utils/shared.ts +31 -29
  34. package/{src → exporter}/utils/sites.ts +7 -7
  35. package/exporter/utils/store.ts +56 -0
  36. package/gatsby-config.ts +1 -1
  37. package/gatsby-node.ts +38 -72
  38. package/index.js +4 -1
  39. package/package.json +13 -10
  40. package/src/README.md +7 -0
  41. package/src/components/Head.tsx +3 -3
  42. package/src/components/template.tsx +3 -4
  43. package/src/gatsby-node-utils.ts +154 -0
  44. package/src/html.tsx +1 -1
  45. package/src/types.ts +98 -0
  46. package/src/{components/utils.ts → utils.ts} +6 -8
  47. package/static/robots.txt +1 -0
  48. package/scripts/griddo-exporter.ts +0 -431
  49. package/scripts/reset-render.ts +0 -9
  50. package/src/components/types.ts +0 -40
  51. package/src/services/store.ts +0 -423
  52. package/src/utils/folders.ts +0 -125
  53. package/src/utils/gatsby.ts +0 -47
  54. /package/{src → exporter}/services/domains.ts +0 -0
  55. /package/{src → exporter}/services/navigation.ts +0 -0
  56. /package/{src → exporter}/services/settings.ts +0 -0
  57. /package/{src → exporter}/services/sites.ts +0 -0
  58. /package/{src → exporter}/types/global.ts +0 -0
  59. /package/{src → exporter}/types/navigation.ts +0 -0
  60. /package/{src → exporter}/types/templates.ts +0 -0
  61. /package/{src → exporter}/utils/searches.ts +0 -0
package/build/index.js CHANGED
@@ -1,75 +1,63 @@
1
1
  #!/usr/bin/env node
2
- "use strict";var hl=Object.create;var gi=Object.defineProperty;var dl=Object.getOwnPropertyDescriptor;var pl=Object.getOwnPropertyNames;var ml=Object.getPrototypeOf,yl=Object.prototype.hasOwnProperty;var v=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var gl=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of pl(t))!yl.call(e,i)&&i!==r&&gi(e,i,{get:()=>t[i],enumerable:!(n=dl(t,i))||n.enumerable});return e};var K=(e,t,r)=>(r=e!=null?hl(ml(e)):{},gl(t||!e||!e.__esModule?gi(r,"default",{value:e,enumerable:!0}):r,e));var bi=v(($p,vi)=>{"use strict";var vl=/[|\\{}()[\]^$+*?.]/g;vi.exports=function(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(vl,"\\$&")}});var _i=v((Bp,wi)=>{"use strict";wi.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}});var Br=v((Lp,ki)=>{var $e=_i(),Si={};for(jt in $e)$e.hasOwnProperty(jt)&&(Si[$e[jt]]=jt);var jt,E=ki.exports={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};for(oe in E)if(E.hasOwnProperty(oe)){if(!("channels"in E[oe]))throw new Error("missing channels property: "+oe);if(!("labels"in E[oe]))throw new Error("missing channel labels property: "+oe);if(E[oe].labels.length!==E[oe].channels)throw new Error("channel and label counts mismatch: "+oe);xi=E[oe].channels,Ei=E[oe].labels,delete E[oe].channels,delete E[oe].labels,Object.defineProperty(E[oe],"channels",{value:xi}),Object.defineProperty(E[oe],"labels",{value:Ei})}var xi,Ei,oe;E.rgb.hsl=function(e){var t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.min(t,r,n),s=Math.max(t,r,n),o=s-i,a,c,d;return s===i?a=0:t===s?a=(r-n)/o:r===s?a=2+(n-t)/o:n===s&&(a=4+(t-r)/o),a=Math.min(a*60,360),a<0&&(a+=360),d=(i+s)/2,s===i?c=0:d<=.5?c=o/(s+i):c=o/(2-s-i),[a,c*100,d*100]};E.rgb.hsv=function(e){var t,r,n,i,s,o=e[0]/255,a=e[1]/255,c=e[2]/255,d=Math.max(o,a,c),f=d-Math.min(o,a,c),p=function(y){return(d-y)/6/f+1/2};return f===0?i=s=0:(s=f/d,t=p(o),r=p(a),n=p(c),o===d?i=n-r:a===d?i=1/3+t-n:c===d&&(i=2/3+r-t),i<0?i+=1:i>1&&(i-=1)),[i*360,s*100,d*100]};E.rgb.hwb=function(e){var t=e[0],r=e[1],n=e[2],i=E.rgb.hsl(e)[0],s=1/255*Math.min(t,Math.min(r,n));return n=1-1/255*Math.max(t,Math.max(r,n)),[i,s*100,n*100]};E.rgb.cmyk=function(e){var t=e[0]/255,r=e[1]/255,n=e[2]/255,i,s,o,a;return a=Math.min(1-t,1-r,1-n),i=(1-t-a)/(1-a)||0,s=(1-r-a)/(1-a)||0,o=(1-n-a)/(1-a)||0,[i*100,s*100,o*100,a*100]};function bl(e,t){return Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)+Math.pow(e[2]-t[2],2)}E.rgb.keyword=function(e){var t=Si[e];if(t)return t;var r=1/0,n;for(var i in $e)if($e.hasOwnProperty(i)){var s=$e[i],o=bl(e,s);o<r&&(r=o,n=i)}return n};E.keyword.rgb=function(e){return $e[e]};E.rgb.xyz=function(e){var t=e[0]/255,r=e[1]/255,n=e[2]/255;t=t>.04045?Math.pow((t+.055)/1.055,2.4):t/12.92,r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92,n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92;var i=t*.4124+r*.3576+n*.1805,s=t*.2126+r*.7152+n*.0722,o=t*.0193+r*.1192+n*.9505;return[i*100,s*100,o*100]};E.rgb.lab=function(e){var t=E.rgb.xyz(e),r=t[0],n=t[1],i=t[2],s,o,a;return r/=95.047,n/=100,i/=108.883,r=r>.008856?Math.pow(r,1/3):7.787*r+16/116,n=n>.008856?Math.pow(n,1/3):7.787*n+16/116,i=i>.008856?Math.pow(i,1/3):7.787*i+16/116,s=116*n-16,o=500*(r-n),a=200*(n-i),[s,o,a]};E.hsl.rgb=function(e){var t=e[0]/360,r=e[1]/100,n=e[2]/100,i,s,o,a,c;if(r===0)return c=n*255,[c,c,c];n<.5?s=n*(1+r):s=n+r-n*r,i=2*n-s,a=[0,0,0];for(var d=0;d<3;d++)o=t+1/3*-(d-1),o<0&&o++,o>1&&o--,6*o<1?c=i+(s-i)*6*o:2*o<1?c=s:3*o<2?c=i+(s-i)*(2/3-o)*6:c=i,a[d]=c*255;return a};E.hsl.hsv=function(e){var t=e[0],r=e[1]/100,n=e[2]/100,i=r,s=Math.max(n,.01),o,a;return n*=2,r*=n<=1?n:2-n,i*=s<=1?s:2-s,a=(n+r)/2,o=n===0?2*i/(s+i):2*r/(n+r),[t,o*100,a*100]};E.hsv.rgb=function(e){var t=e[0]/60,r=e[1]/100,n=e[2]/100,i=Math.floor(t)%6,s=t-Math.floor(t),o=255*n*(1-r),a=255*n*(1-r*s),c=255*n*(1-r*(1-s));switch(n*=255,i){case 0:return[n,c,o];case 1:return[a,n,o];case 2:return[o,n,c];case 3:return[o,a,n];case 4:return[c,o,n];case 5:return[n,o,a]}};E.hsv.hsl=function(e){var t=e[0],r=e[1]/100,n=e[2]/100,i=Math.max(n,.01),s,o,a;return a=(2-r)*n,s=(2-r)*i,o=r*i,o/=s<=1?s:2-s,o=o||0,a/=2,[t,o*100,a*100]};E.hwb.rgb=function(e){var t=e[0]/360,r=e[1]/100,n=e[2]/100,i=r+n,s,o,a,c;i>1&&(r/=i,n/=i),s=Math.floor(6*t),o=1-n,a=6*t-s,s&1&&(a=1-a),c=r+a*(o-r);var d,f,p;switch(s){default:case 6:case 0:d=o,f=c,p=r;break;case 1:d=c,f=o,p=r;break;case 2:d=r,f=o,p=c;break;case 3:d=r,f=c,p=o;break;case 4:d=c,f=r,p=o;break;case 5:d=o,f=r,p=c;break}return[d*255,f*255,p*255]};E.cmyk.rgb=function(e){var t=e[0]/100,r=e[1]/100,n=e[2]/100,i=e[3]/100,s,o,a;return s=1-Math.min(1,t*(1-i)+i),o=1-Math.min(1,r*(1-i)+i),a=1-Math.min(1,n*(1-i)+i),[s*255,o*255,a*255]};E.xyz.rgb=function(e){var t=e[0]/100,r=e[1]/100,n=e[2]/100,i,s,o;return i=t*3.2406+r*-1.5372+n*-.4986,s=t*-.9689+r*1.8758+n*.0415,o=t*.0557+r*-.204+n*1.057,i=i>.0031308?1.055*Math.pow(i,1/2.4)-.055:i*12.92,s=s>.0031308?1.055*Math.pow(s,1/2.4)-.055:s*12.92,o=o>.0031308?1.055*Math.pow(o,1/2.4)-.055:o*12.92,i=Math.min(Math.max(0,i),1),s=Math.min(Math.max(0,s),1),o=Math.min(Math.max(0,o),1),[i*255,s*255,o*255]};E.xyz.lab=function(e){var t=e[0],r=e[1],n=e[2],i,s,o;return t/=95.047,r/=100,n/=108.883,t=t>.008856?Math.pow(t,1/3):7.787*t+16/116,r=r>.008856?Math.pow(r,1/3):7.787*r+16/116,n=n>.008856?Math.pow(n,1/3):7.787*n+16/116,i=116*r-16,s=500*(t-r),o=200*(r-n),[i,s,o]};E.lab.xyz=function(e){var t=e[0],r=e[1],n=e[2],i,s,o;s=(t+16)/116,i=r/500+s,o=s-n/200;var a=Math.pow(s,3),c=Math.pow(i,3),d=Math.pow(o,3);return s=a>.008856?a:(s-16/116)/7.787,i=c>.008856?c:(i-16/116)/7.787,o=d>.008856?d:(o-16/116)/7.787,i*=95.047,s*=100,o*=108.883,[i,s,o]};E.lab.lch=function(e){var t=e[0],r=e[1],n=e[2],i,s,o;return i=Math.atan2(n,r),s=i*360/2/Math.PI,s<0&&(s+=360),o=Math.sqrt(r*r+n*n),[t,o,s]};E.lch.lab=function(e){var t=e[0],r=e[1],n=e[2],i,s,o;return o=n/360*2*Math.PI,i=r*Math.cos(o),s=r*Math.sin(o),[t,i,s]};E.rgb.ansi16=function(e){var t=e[0],r=e[1],n=e[2],i=1 in arguments?arguments[1]:E.rgb.hsv(e)[2];if(i=Math.round(i/50),i===0)return 30;var s=30+(Math.round(n/255)<<2|Math.round(r/255)<<1|Math.round(t/255));return i===2&&(s+=60),s};E.hsv.ansi16=function(e){return E.rgb.ansi16(E.hsv.rgb(e),e[2])};E.rgb.ansi256=function(e){var t=e[0],r=e[1],n=e[2];if(t===r&&r===n)return t<8?16:t>248?231:Math.round((t-8)/247*24)+232;var i=16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5);return i};E.ansi16.rgb=function(e){var t=e%10;if(t===0||t===7)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];var r=(~~(e>50)+1)*.5,n=(t&1)*r*255,i=(t>>1&1)*r*255,s=(t>>2&1)*r*255;return[n,i,s]};E.ansi256.rgb=function(e){if(e>=232){var t=(e-232)*10+8;return[t,t,t]}e-=16;var r,n=Math.floor(e/36)/5*255,i=Math.floor((r=e%36)/6)/5*255,s=r%6/5*255;return[n,i,s]};E.rgb.hex=function(e){var t=((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255),r=t.toString(16).toUpperCase();return"000000".substring(r.length)+r};E.hex.rgb=function(e){var t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];var r=t[0];t[0].length===3&&(r=r.split("").map(function(a){return a+a}).join(""));var n=parseInt(r,16),i=n>>16&255,s=n>>8&255,o=n&255;return[i,s,o]};E.rgb.hcg=function(e){var t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.max(Math.max(t,r),n),s=Math.min(Math.min(t,r),n),o=i-s,a,c;return o<1?a=s/(1-o):a=0,o<=0?c=0:i===t?c=(r-n)/o%6:i===r?c=2+(n-t)/o:c=4+(t-r)/o+4,c/=6,c%=1,[c*360,o*100,a*100]};E.hsl.hcg=function(e){var t=e[1]/100,r=e[2]/100,n=1,i=0;return r<.5?n=2*t*r:n=2*t*(1-r),n<1&&(i=(r-.5*n)/(1-n)),[e[0],n*100,i*100]};E.hsv.hcg=function(e){var t=e[1]/100,r=e[2]/100,n=t*r,i=0;return n<1&&(i=(r-n)/(1-n)),[e[0],n*100,i*100]};E.hcg.rgb=function(e){var t=e[0]/360,r=e[1]/100,n=e[2]/100;if(r===0)return[n*255,n*255,n*255];var i=[0,0,0],s=t%1*6,o=s%1,a=1-o,c=0;switch(Math.floor(s)){case 0:i[0]=1,i[1]=o,i[2]=0;break;case 1:i[0]=a,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=o;break;case 3:i[0]=0,i[1]=a,i[2]=1;break;case 4:i[0]=o,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=a}return c=(1-r)*n,[(r*i[0]+c)*255,(r*i[1]+c)*255,(r*i[2]+c)*255]};E.hcg.hsv=function(e){var t=e[1]/100,r=e[2]/100,n=t+r*(1-t),i=0;return n>0&&(i=t/n),[e[0],i*100,n*100]};E.hcg.hsl=function(e){var t=e[1]/100,r=e[2]/100,n=r*(1-t)+.5*t,i=0;return n>0&&n<.5?i=t/(2*n):n>=.5&&n<1&&(i=t/(2*(1-n))),[e[0],i*100,n*100]};E.hcg.hwb=function(e){var t=e[1]/100,r=e[2]/100,n=t+r*(1-t);return[e[0],(n-t)*100,(1-n)*100]};E.hwb.hcg=function(e){var t=e[1]/100,r=e[2]/100,n=1-r,i=n-t,s=0;return i<1&&(s=(n-i)/(1-i)),[e[0],i*100,s*100]};E.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};E.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};E.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};E.gray.hsl=E.gray.hsv=function(e){return[0,0,e[0]]};E.gray.hwb=function(e){return[0,100,e[0]]};E.gray.cmyk=function(e){return[0,0,0,e[0]]};E.gray.lab=function(e){return[e[0],0,0]};E.gray.hex=function(e){var t=Math.round(e[0]/100*255)&255,r=(t<<16)+(t<<8)+t,n=r.toString(16).toUpperCase();return"000000".substring(n.length)+n};E.rgb.gray=function(e){var t=(e[0]+e[1]+e[2])/3;return[t/255*100]}});var Ri=v((Hp,Ci)=>{var $t=Br();function wl(){for(var e={},t=Object.keys($t),r=t.length,n=0;n<r;n++)e[t[n]]={distance:-1,parent:null};return e}function _l(e){var t=wl(),r=[e];for(t[e].distance=0;r.length;)for(var n=r.pop(),i=Object.keys($t[n]),s=i.length,o=0;o<s;o++){var a=i[o],c=t[a];c.distance===-1&&(c.distance=t[n].distance+1,c.parent=n,r.unshift(a))}return t}function xl(e,t){return function(r){return t(e(r))}}function El(e,t){for(var r=[t[e].parent,e],n=$t[t[e].parent][e],i=t[e].parent;t[i].parent;)r.unshift(t[i].parent),n=xl($t[t[i].parent][i],n),i=t[i].parent;return n.conversion=r,n}Ci.exports=function(e){for(var t=_l(e),r={},n=Object.keys(t),i=n.length,s=0;s<i;s++){var o=n[s],a=t[o];a.parent!==null&&(r[o]=El(o,t))}return r}});var Ai=v((Up,Oi)=>{var Lr=Br(),Sl=Ri(),We={},kl=Object.keys(Lr);function Cl(e){var t=function(r){return r==null?r:(arguments.length>1&&(r=Array.prototype.slice.call(arguments)),e(r))};return"conversion"in e&&(t.conversion=e.conversion),t}function Rl(e){var t=function(r){if(r==null)return r;arguments.length>1&&(r=Array.prototype.slice.call(arguments));var n=e(r);if(typeof n=="object")for(var i=n.length,s=0;s<i;s++)n[s]=Math.round(n[s]);return n};return"conversion"in e&&(t.conversion=e.conversion),t}kl.forEach(function(e){We[e]={},Object.defineProperty(We[e],"channels",{value:Lr[e].channels}),Object.defineProperty(We[e],"labels",{value:Lr[e].labels});var t=Sl(e),r=Object.keys(t);r.forEach(function(n){var i=t[n];We[e][n]=Rl(i),We[e][n].raw=Cl(i)})});Oi.exports=We});var qi=v((Gp,Pi)=>{"use strict";var Je=Ai(),Bt=(e,t)=>function(){return`\x1B[${e.apply(Je,arguments)+t}m`},Lt=(e,t)=>function(){let r=e.apply(Je,arguments);return`\x1B[${38+t};5;${r}m`},Ht=(e,t)=>function(){let r=e.apply(Je,arguments);return`\x1B[${38+t};2;${r[0]};${r[1]};${r[2]}m`};function Ol(){let e=new Map,t={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],gray:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};t.color.grey=t.color.gray;for(let i of Object.keys(t)){let s=t[i];for(let o of Object.keys(s)){let a=s[o];t[o]={open:`\x1B[${a[0]}m`,close:`\x1B[${a[1]}m`},s[o]=t[o],e.set(a[0],a[1])}Object.defineProperty(t,i,{value:s,enumerable:!1}),Object.defineProperty(t,"codes",{value:e,enumerable:!1})}let r=i=>i,n=(i,s,o)=>[i,s,o];t.color.close="\x1B[39m",t.bgColor.close="\x1B[49m",t.color.ansi={ansi:Bt(r,0)},t.color.ansi256={ansi256:Lt(r,0)},t.color.ansi16m={rgb:Ht(n,0)},t.bgColor.ansi={ansi:Bt(r,10)},t.bgColor.ansi256={ansi256:Lt(r,10)},t.bgColor.ansi16m={rgb:Ht(n,10)};for(let i of Object.keys(Je)){if(typeof Je[i]!="object")continue;let s=Je[i];i==="ansi16"&&(i="ansi"),"ansi16"in s&&(t.color.ansi[i]=Bt(s.ansi16,0),t.bgColor.ansi[i]=Bt(s.ansi16,10)),"ansi256"in s&&(t.color.ansi256[i]=Lt(s.ansi256,0),t.bgColor.ansi256[i]=Lt(s.ansi256,10)),"rgb"in s&&(t.color.ansi16m[i]=Ht(s.rgb,0),t.bgColor.ansi16m[i]=Ht(s.rgb,10))}return t}Object.defineProperty(Pi,"exports",{enumerable:!0,get:Ol})});var Fi=v((zp,Mi)=>{"use strict";Mi.exports=(e,t)=>{t=t||process.argv;let r=e.startsWith("-")?"":e.length===1?"-":"--",n=t.indexOf(r+e),i=t.indexOf("--");return n!==-1&&(i===-1?!0:n<i)}});var Ii=v((Wp,Ti)=>{"use strict";var Al=require("os"),Ee=Fi(),re=process.env,Ve;Ee("no-color")||Ee("no-colors")||Ee("color=false")?Ve=!1:(Ee("color")||Ee("colors")||Ee("color=true")||Ee("color=always"))&&(Ve=!0);"FORCE_COLOR"in re&&(Ve=re.FORCE_COLOR.length===0||parseInt(re.FORCE_COLOR,10)!==0);function Pl(e){return e===0?!1:{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function ql(e){if(Ve===!1)return 0;if(Ee("color=16m")||Ee("color=full")||Ee("color=truecolor"))return 3;if(Ee("color=256"))return 2;if(e&&!e.isTTY&&Ve!==!0)return 0;let t=Ve?1:0;if(process.platform==="win32"){let r=Al.release().split(".");return Number(process.versions.node.split(".")[0])>=8&&Number(r[0])>=10&&Number(r[2])>=10586?Number(r[2])>=14931?3:2:1}if("CI"in re)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI"].some(r=>r in re)||re.CI_NAME==="codeship"?1:t;if("TEAMCITY_VERSION"in re)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(re.TEAMCITY_VERSION)?1:0;if(re.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in re){let r=parseInt((re.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(re.TERM_PROGRAM){case"iTerm.app":return r>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(re.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(re.TERM)||"COLORTERM"in re?1:(re.TERM==="dumb",t)}function Hr(e){let t=ql(e);return Pl(t)}Ti.exports={supportsColor:Hr,stdout:Hr(process.stdout),stderr:Hr(process.stderr)}});var Bi=v((Jp,$i)=>{"use strict";var Ml=/(?:\\(u[a-f\d]{4}|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,Ni=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,Fl=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,Tl=/\\(u[a-f\d]{4}|x[a-f\d]{2}|.)|([^\\])/gi,Il=new Map([["n",`
3
- `],["r","\r"],["t"," "],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e","\x1B"],["a","\x07"]]);function ji(e){return e[0]==="u"&&e.length===5||e[0]==="x"&&e.length===3?String.fromCharCode(parseInt(e.slice(1),16)):Il.get(e)||e}function Nl(e,t){let r=[],n=t.trim().split(/\s*,\s*/g),i;for(let s of n)if(!isNaN(s))r.push(Number(s));else if(i=s.match(Fl))r.push(i[2].replace(Tl,(o,a,c)=>a?ji(a):c));else throw new Error(`Invalid Chalk template style argument: ${s} (in style '${e}')`);return r}function Dl(e){Ni.lastIndex=0;let t=[],r;for(;(r=Ni.exec(e))!==null;){let n=r[1];if(r[2]){let i=Nl(n,r[2]);t.push([n].concat(i))}else t.push([n])}return t}function Di(e,t){let r={};for(let i of t)for(let s of i.styles)r[s[0]]=i.inverse?null:s.slice(1);let n=e;for(let i of Object.keys(r))if(Array.isArray(r[i])){if(!(i in n))throw new Error(`Unknown Chalk style: ${i}`);r[i].length>0?n=n[i].apply(n,r[i]):n=n[i]}return n}$i.exports=(e,t)=>{let r=[],n=[],i=[];if(t.replace(Ml,(s,o,a,c,d,f)=>{if(o)i.push(ji(o));else if(c){let p=i.join("");i=[],n.push(r.length===0?p:Di(e,r)(p)),r.push({inverse:a,styles:Dl(c)})}else if(d){if(r.length===0)throw new Error("Found extraneous } in Chalk template literal");n.push(Di(e,r)(i.join(""))),i=[],r.pop()}else i.push(f)}),n.push(i.join("")),r.length>0){let s=`Chalk template literal is missing ${r.length} closing bracket${r.length===1?"":"s"} (\`}\`)`;throw new Error(s)}return n.join("")}});var gt=v((Vp,yt)=>{"use strict";var Gr=bi(),V=qi(),Ur=Ii().stdout,jl=Bi(),Hi=process.platform==="win32"&&!(process.env.TERM||"").toLowerCase().startsWith("xterm"),Ui=["ansi","ansi","ansi256","ansi16m"],Gi=new Set(["gray"]),Ye=Object.create(null);function Li(e,t){t=t||{};let r=Ur?Ur.level:0;e.level=t.level===void 0?r:t.level,e.enabled="enabled"in t?t.enabled:e.level>0}function mt(e){if(!this||!(this instanceof mt)||this.template){let t={};return Li(t,e),t.template=function(){let r=[].slice.call(arguments);return Ll.apply(null,[t.template].concat(r))},Object.setPrototypeOf(t,mt.prototype),Object.setPrototypeOf(t.template,t),t.template.constructor=mt,t.template}Li(this,e)}Hi&&(V.blue.open="\x1B[94m");for(let e of Object.keys(V))V[e].closeRe=new RegExp(Gr(V[e].close),"g"),Ye[e]={get(){let t=V[e];return Ut.call(this,this._styles?this._styles.concat(t):[t],this._empty,e)}};Ye.visible={get(){return Ut.call(this,this._styles||[],!0,"visible")}};V.color.closeRe=new RegExp(Gr(V.color.close),"g");for(let e of Object.keys(V.color.ansi))Gi.has(e)||(Ye[e]={get(){let t=this.level;return function(){let n={open:V.color[Ui[t]][e].apply(null,arguments),close:V.color.close,closeRe:V.color.closeRe};return Ut.call(this,this._styles?this._styles.concat(n):[n],this._empty,e)}}});V.bgColor.closeRe=new RegExp(Gr(V.bgColor.close),"g");for(let e of Object.keys(V.bgColor.ansi)){if(Gi.has(e))continue;let t="bg"+e[0].toUpperCase()+e.slice(1);Ye[t]={get(){let r=this.level;return function(){let i={open:V.bgColor[Ui[r]][e].apply(null,arguments),close:V.bgColor.close,closeRe:V.bgColor.closeRe};return Ut.call(this,this._styles?this._styles.concat(i):[i],this._empty,e)}}}}var $l=Object.defineProperties(()=>{},Ye);function Ut(e,t,r){let n=function(){return Bl.apply(n,arguments)};n._styles=e,n._empty=t;let i=this;return Object.defineProperty(n,"level",{enumerable:!0,get(){return i.level},set(s){i.level=s}}),Object.defineProperty(n,"enabled",{enumerable:!0,get(){return i.enabled},set(s){i.enabled=s}}),n.hasGrey=this.hasGrey||r==="gray"||r==="grey",n.__proto__=$l,n}function Bl(){let e=arguments,t=e.length,r=String(arguments[0]);if(t===0)return"";if(t>1)for(let i=1;i<t;i++)r+=" "+e[i];if(!this.enabled||this.level<=0||!r)return this._empty?"":r;let n=V.dim.open;Hi&&this.hasGrey&&(V.dim.open="");for(let i of this._styles.slice().reverse())r=i.open+r.replace(i.closeRe,i.open)+i.close,r=r.replace(/\r?\n/g,`${i.close}$&${i.open}`);return V.dim.open=n,r}function Ll(e,t){if(!Array.isArray(t))return[].slice.call(arguments,1).join(" ");let r=[].slice.call(arguments,2),n=[t.raw[0]];for(let i=1;i<t.length;i++)n.push(String(r[i-1]).replace(/[{}\\]/g,"\\$&")),n.push(String(t.raw[i]));return jl(e,n.join(""))}Object.defineProperties(mt.prototype,Ye);yt.exports=mt();yt.exports.supportsColor=Ur;yt.exports.default=yt.exports});var Gt=v((Yp,zr)=>{var Hl=require("fs"),Ul=require("path");function zi(e){console.log(`[dotenv][DEBUG] ${e}`)}var Gl=`
4
- `,zl=/^\s*([\w.-]+)\s*=\s*(.*)?\s*$/,Wl=/\\n/g,Jl=/\n|\r|\r\n/;function Wi(e,t){let r=!!(t&&t.debug),n={};return e.toString().split(Jl).forEach(function(i,s){let o=i.match(zl);if(o!=null){let a=o[1],c=o[2]||"",d=c.length-1,f=c[0]==='"'&&c[d]==='"';c[0]==="'"&&c[d]==="'"||f?(c=c.substring(1,d),f&&(c=c.replace(Wl,Gl))):c=c.trim(),n[a]=c}else r&&zi(`did not match key and value when parsing line ${s+1}: ${i}`)}),n}function Vl(e){let t=Ul.resolve(process.cwd(),".env"),r="utf8",n=!1;e&&(e.path!=null&&(t=e.path),e.encoding!=null&&(r=e.encoding),e.debug!=null&&(n=!0));try{let i=Wi(Hl.readFileSync(t,{encoding:r}),{debug:n});return Object.keys(i).forEach(function(s){Object.prototype.hasOwnProperty.call(process.env,s)?n&&zi(`"${s}" is already defined in \`process.env\` and will not be overwritten`):process.env[s]=i[s]}),{parsed:i}}catch(i){return{error:i}}}zr.exports.config=Vl;zr.exports.parse=Wi});var Vi=v((Kp,Ji)=>{var Wr=class{constructor(t){this.value=t,this.next=void 0}},Jr=class{constructor(){this.clear()}enqueue(t){let r=new Wr(t);this._head?(this._tail.next=r,this._tail=r):(this._head=r,this._tail=r),this._size++}dequeue(){let t=this._head;if(t)return this._head=this._head.next,this._size--,t.value}clear(){this._head=void 0,this._tail=void 0,this._size=0}get size(){return this._size}*[Symbol.iterator](){let t=this._head;for(;t;)yield t.value,t=t.next}};Ji.exports=Jr});var Ki=v((Xp,Yi)=>{"use strict";var Yl=Vi(),Kl=e=>{if(!((Number.isInteger(e)||e===1/0)&&e>0))throw new TypeError("Expected `concurrency` to be a number from 1 and up");let t=new Yl,r=0,n=()=>{r--,t.size>0&&t.dequeue()()},i=async(a,c,...d)=>{r++;let f=(async()=>a(...d))();c(f);try{await f}catch{}n()},s=(a,c,...d)=>{t.enqueue(i.bind(null,a,c,...d)),(async()=>(await Promise.resolve(),r<e&&t.size>0&&t.dequeue()()))()},o=(a,...c)=>new Promise(d=>{s(a,d,...c)});return Object.defineProperties(o,{activeCount:{get:()=>r},pendingCount:{get:()=>t.size},clearQueue:{value:()=>{t.clear()}}}),o};Yi.exports=Kl});var Zi=v((Qp,Qi)=>{"use strict";var Xi=Ki(),zt=class extends Error{constructor(t){super(),this.value=t}},Xl=async(e,t)=>t(await e),Ql=async e=>{let t=await Promise.all(e);if(t[1]===!0)throw new zt(t[0]);return!1},Zl=async(e,t,r)=>{r={concurrency:1/0,preserveOrder:!0,...r};let n=Xi(r.concurrency),i=[...e].map(o=>[o,n(Xl,o,t)]),s=Xi(r.preserveOrder?1:1/0);try{await Promise.all(i.map(o=>s(Ql,o)))}catch(o){if(o instanceof zt)return o.value;throw o}};Qi.exports=Zl});var ss=v((Zp,Vr)=>{"use strict";var es=require("path"),Wt=require("fs"),{promisify:ts}=require("util"),ef=Zi(),tf=ts(Wt.stat),rf=ts(Wt.lstat),rs={directory:"isDirectory",file:"isFile"};function ns({type:e}){if(!(e in rs))throw new Error(`Invalid type specified: ${e}`)}var is=(e,t)=>e===void 0||t[rs[e]]();Vr.exports=async(e,t)=>{t={cwd:process.cwd(),type:"file",allowSymlinks:!0,...t},ns(t);let r=t.allowSymlinks?tf:rf;return ef(e,async n=>{try{let i=await r(es.resolve(t.cwd,n));return is(t.type,i)}catch{return!1}},t)};Vr.exports.sync=(e,t)=>{t={cwd:process.cwd(),allowSymlinks:!0,type:"file",...t},ns(t);let r=t.allowSymlinks?Wt.statSync:Wt.lstatSync;for(let n of e)try{let i=r(es.resolve(t.cwd,n));if(is(t.type,i))return n}catch{}}});var as=v((e1,Yr)=>{"use strict";var os=require("fs"),{promisify:nf}=require("util"),sf=nf(os.access);Yr.exports=async e=>{try{return await sf(e),!0}catch{return!1}};Yr.exports.sync=e=>{try{return os.accessSync(e),!0}catch{return!1}}});var us=v((t1,Ke)=>{"use strict";var Ae=require("path"),Jt=ss(),cs=as(),Kr=Symbol("findUp.stop");Ke.exports=async(e,t={})=>{let r=Ae.resolve(t.cwd||""),{root:n}=Ae.parse(r),i=[].concat(e),s=async o=>{if(typeof e!="function")return Jt(i,o);let a=await e(o.cwd);return typeof a=="string"?Jt([a],o):a};for(;;){let o=await s({...t,cwd:r});if(o===Kr)return;if(o)return Ae.resolve(r,o);if(r===n)return;r=Ae.dirname(r)}};Ke.exports.sync=(e,t={})=>{let r=Ae.resolve(t.cwd||""),{root:n}=Ae.parse(r),i=[].concat(e),s=o=>{if(typeof e!="function")return Jt.sync(i,o);let a=e(o.cwd);return typeof a=="string"?Jt.sync([a],o):a};for(;;){let o=s({...t,cwd:r});if(o===Kr)return;if(o)return Ae.resolve(r,o);if(r===n)return;r=Ae.dirname(r)}};Ke.exports.exists=cs;Ke.exports.sync.exists=cs.sync;Ke.exports.stop=Kr});var hs=v((r1,Xr)=>{"use strict";var ls=require("path"),fs=us(),of=async e=>{let t=await fs("package.json",{cwd:e});return t&&ls.dirname(t)};Xr.exports=of;Xr.exports.sync=e=>{let t=fs.sync("package.json",{cwd:e});return t&&ls.dirname(t)}});var fe=v(Qr=>{"use strict";Qr.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})};Qr.fromPromise=function(e){return Object.defineProperty(function(...t){let 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 ps=v((i1,ds)=>{var Pe=require("constants"),af=process.cwd,Vt=null,cf=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return Vt||(Vt=af.call(process)),Vt};try{process.cwd()}catch{}typeof process.chdir=="function"&&(Zr=process.chdir,process.chdir=function(e){Vt=null,Zr.call(process,e)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,Zr));var Zr;ds.exports=uf;function uf(e){Pe.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=a(e.stat),e.fstat=a(e.fstat),e.lstat=a(e.lstat),e.statSync=c(e.statSync),e.fstatSync=c(e.fstatSync),e.lstatSync=c(e.lstatSync),e.chmod&&!e.lchmod&&(e.lchmod=function(f,p,y){y&&process.nextTick(y)},e.lchmodSync=function(){}),e.chown&&!e.lchown&&(e.lchown=function(f,p,y,m){m&&process.nextTick(m)},e.lchownSync=function(){}),cf==="win32"&&(e.rename=typeof e.rename!="function"?e.rename:function(f){function p(y,m,_){var A=Date.now(),P=0;f(y,m,function N(U){if(U&&(U.code==="EACCES"||U.code==="EPERM")&&Date.now()-A<6e4){setTimeout(function(){e.stat(m,function(W,x){W&&W.code==="ENOENT"?f(y,m,N):_(U)})},P),P<100&&(P+=10);return}_&&_(U)})}return Object.setPrototypeOf&&Object.setPrototypeOf(p,f),p}(e.rename)),e.read=typeof e.read!="function"?e.read:function(f){function p(y,m,_,A,P,N){var U;if(N&&typeof N=="function"){var W=0;U=function(x,k,M){if(x&&x.code==="EAGAIN"&&W<10)return W++,f.call(e,y,m,_,A,P,U);N.apply(this,arguments)}}return f.call(e,y,m,_,A,P,U)}return Object.setPrototypeOf&&Object.setPrototypeOf(p,f),p}(e.read),e.readSync=typeof e.readSync!="function"?e.readSync:function(f){return function(p,y,m,_,A){for(var P=0;;)try{return f.call(e,p,y,m,_,A)}catch(N){if(N.code==="EAGAIN"&&P<10){P++;continue}throw N}}}(e.readSync);function t(f){f.lchmod=function(p,y,m){f.open(p,Pe.O_WRONLY|Pe.O_SYMLINK,y,function(_,A){if(_){m&&m(_);return}f.fchmod(A,y,function(P){f.close(A,function(N){m&&m(P||N)})})})},f.lchmodSync=function(p,y){var m=f.openSync(p,Pe.O_WRONLY|Pe.O_SYMLINK,y),_=!0,A;try{A=f.fchmodSync(m,y),_=!1}finally{if(_)try{f.closeSync(m)}catch{}else f.closeSync(m)}return A}}function r(f){Pe.hasOwnProperty("O_SYMLINK")&&f.futimes?(f.lutimes=function(p,y,m,_){f.open(p,Pe.O_SYMLINK,function(A,P){if(A){_&&_(A);return}f.futimes(P,y,m,function(N){f.close(P,function(U){_&&_(N||U)})})})},f.lutimesSync=function(p,y,m){var _=f.openSync(p,Pe.O_SYMLINK),A,P=!0;try{A=f.futimesSync(_,y,m),P=!1}finally{if(P)try{f.closeSync(_)}catch{}else f.closeSync(_)}return A}):f.futimes&&(f.lutimes=function(p,y,m,_){_&&process.nextTick(_)},f.lutimesSync=function(){})}function n(f){return f&&function(p,y,m){return f.call(e,p,y,function(_){d(_)&&(_=null),m&&m.apply(this,arguments)})}}function i(f){return f&&function(p,y){try{return f.call(e,p,y)}catch(m){if(!d(m))throw m}}}function s(f){return f&&function(p,y,m,_){return f.call(e,p,y,m,function(A){d(A)&&(A=null),_&&_.apply(this,arguments)})}}function o(f){return f&&function(p,y,m){try{return f.call(e,p,y,m)}catch(_){if(!d(_))throw _}}}function a(f){return f&&function(p,y,m){typeof y=="function"&&(m=y,y=null);function _(A,P){P&&(P.uid<0&&(P.uid+=4294967296),P.gid<0&&(P.gid+=4294967296)),m&&m.apply(this,arguments)}return y?f.call(e,p,y,_):f.call(e,p,_)}}function c(f){return f&&function(p,y){var m=y?f.call(e,p,y):f.call(e,p);return m&&(m.uid<0&&(m.uid+=4294967296),m.gid<0&&(m.gid+=4294967296)),m}}function d(f){if(!f||f.code==="ENOSYS")return!0;var p=!process.getuid||process.getuid()!==0;return!!(p&&(f.code==="EINVAL"||f.code==="EPERM"))}}});var gs=v((s1,ys)=>{var ms=require("stream").Stream;ys.exports=lf;function lf(e){return{ReadStream:t,WriteStream:r};function t(n,i){if(!(this instanceof t))return new t(n,i);ms.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),a=0,c=o.length;a<c;a++){var d=o[a];this[d]=i[d]}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(f,p){if(f){s.emit("error",f),s.readable=!1;return}s.fd=p,s.emit("open",p),s._read()})}function r(n,i){if(!(this instanceof r))return new r(n,i);ms.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,a=s.length;o<a;o++){var c=s[o];this[c]=i[c]}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 bs=v((o1,vs)=>{"use strict";vs.exports=hf;var ff=Object.getPrototypeOf||function(e){return e.__proto__};function hf(e){if(e===null||typeof e!="object")return e;if(e instanceof Object)var t={__proto__:ff(e)};else var t=Object.create(null);return Object.getOwnPropertyNames(e).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}),t}});var ne=v((a1,rn)=>{var z=require("fs"),df=ps(),pf=gs(),mf=bs(),Yt=require("util"),Z,Xt;typeof Symbol=="function"&&typeof Symbol.for=="function"?(Z=Symbol.for("graceful-fs.queue"),Xt=Symbol.for("graceful-fs.previous")):(Z="___graceful-fs.queue",Xt="___graceful-fs.previous");function yf(){}function xs(e,t){Object.defineProperty(e,Z,{get:function(){return t}})}var Be=yf;Yt.debuglog?Be=Yt.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(Be=function(){var e=Yt.format.apply(Yt,arguments);e="GFS4: "+e.split(/\n/).join(`
5
- GFS4: `),console.error(e)});z[Z]||(ws=global[Z]||[],xs(z,ws),z.close=function(e){function t(r,n){return e.call(z,r,function(i){i||_s(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(t,Xt,{value:e}),t}(z.close),z.closeSync=function(e){function t(r){e.apply(z,arguments),_s()}return Object.defineProperty(t,Xt,{value:e}),t}(z.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){Be(z[Z]),require("assert").equal(z[Z].length,0)}));var ws;global[Z]||xs(global,z[Z]);rn.exports=en(mf(z));process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!z.__patched&&(rn.exports=en(z),z.__patched=!0);function en(e){df(e),e.gracefulify=en,e.createReadStream=k,e.createWriteStream=M;var t=e.readFile;e.readFile=r;function r(R,D,T){return typeof D=="function"&&(T=D,D=null),G(R,D,T);function G(q,H,O,$){return t(q,H,function(I){I&&(I.code==="EMFILE"||I.code==="ENFILE")?Xe([G,[q,H,O],I,$||Date.now(),Date.now()]):typeof O=="function"&&O.apply(this,arguments)})}}var n=e.writeFile;e.writeFile=i;function i(R,D,T,G){return typeof T=="function"&&(G=T,T=null),q(R,D,T,G);function q(H,O,$,I,C){return n(H,O,$,function(F){F&&(F.code==="EMFILE"||F.code==="ENFILE")?Xe([q,[H,O,$,I],F,C||Date.now(),Date.now()]):typeof I=="function"&&I.apply(this,arguments)})}}var s=e.appendFile;s&&(e.appendFile=o);function o(R,D,T,G){return typeof T=="function"&&(G=T,T=null),q(R,D,T,G);function q(H,O,$,I,C){return s(H,O,$,function(F){F&&(F.code==="EMFILE"||F.code==="ENFILE")?Xe([q,[H,O,$,I],F,C||Date.now(),Date.now()]):typeof I=="function"&&I.apply(this,arguments)})}}var a=e.copyFile;a&&(e.copyFile=c);function c(R,D,T,G){return typeof T=="function"&&(G=T,T=0),q(R,D,T,G);function q(H,O,$,I,C){return a(H,O,$,function(F){F&&(F.code==="EMFILE"||F.code==="ENFILE")?Xe([q,[H,O,$,I],F,C||Date.now(),Date.now()]):typeof I=="function"&&I.apply(this,arguments)})}}var d=e.readdir;e.readdir=p;var f=/^v[0-5]\./;function p(R,D,T){typeof D=="function"&&(T=D,D=null);var G=f.test(process.version)?function(O,$,I,C){return d(O,q(O,$,I,C))}:function(O,$,I,C){return d(O,$,q(O,$,I,C))};return G(R,D,T);function q(H,O,$,I){return function(C,F){C&&(C.code==="EMFILE"||C.code==="ENFILE")?Xe([G,[H,O,$],C,I||Date.now(),Date.now()]):(F&&F.sort&&F.sort(),typeof $=="function"&&$.call(this,C,F))}}}if(process.version.substr(0,4)==="v0.8"){var y=pf(e);N=y.ReadStream,W=y.WriteStream}var m=e.ReadStream;m&&(N.prototype=Object.create(m.prototype),N.prototype.open=U);var _=e.WriteStream;_&&(W.prototype=Object.create(_.prototype),W.prototype.open=x),Object.defineProperty(e,"ReadStream",{get:function(){return N},set:function(R){N=R},enumerable:!0,configurable:!0}),Object.defineProperty(e,"WriteStream",{get:function(){return W},set:function(R){W=R},enumerable:!0,configurable:!0});var A=N;Object.defineProperty(e,"FileReadStream",{get:function(){return A},set:function(R){A=R},enumerable:!0,configurable:!0});var P=W;Object.defineProperty(e,"FileWriteStream",{get:function(){return P},set:function(R){P=R},enumerable:!0,configurable:!0});function N(R,D){return this instanceof N?(m.apply(this,arguments),this):N.apply(Object.create(N.prototype),arguments)}function U(){var R=this;Q(R.path,R.flags,R.mode,function(D,T){D?(R.autoClose&&R.destroy(),R.emit("error",D)):(R.fd=T,R.emit("open",T),R.read())})}function W(R,D){return this instanceof W?(_.apply(this,arguments),this):W.apply(Object.create(W.prototype),arguments)}function x(){var R=this;Q(R.path,R.flags,R.mode,function(D,T){D?(R.destroy(),R.emit("error",D)):(R.fd=T,R.emit("open",T))})}function k(R,D){return new e.ReadStream(R,D)}function M(R,D){return new e.WriteStream(R,D)}var ye=e.open;e.open=Q;function Q(R,D,T,G){return typeof T=="function"&&(G=T,T=null),q(R,D,T,G);function q(H,O,$,I,C){return ye(H,O,$,function(F,Oe){F&&(F.code==="EMFILE"||F.code==="ENFILE")?Xe([q,[H,O,$,I],F,C||Date.now(),Date.now()]):typeof I=="function"&&I.apply(this,arguments)})}}return e}function Xe(e){Be("ENQUEUE",e[0].name,e[1]),z[Z].push(e),tn()}var Kt;function _s(){for(var e=Date.now(),t=0;t<z[Z].length;++t)z[Z][t].length>2&&(z[Z][t][3]=e,z[Z][t][4]=e);tn()}function tn(){if(clearTimeout(Kt),Kt=void 0,z[Z].length!==0){var e=z[Z].shift(),t=e[0],r=e[1],n=e[2],i=e[3],s=e[4];if(i===void 0)Be("RETRY",t.name,r),t.apply(null,r);else if(Date.now()-i>=6e4){Be("TIMEOUT",t.name,r);var o=r.pop();typeof o=="function"&&o.call(null,n)}else{var a=Date.now()-s,c=Math.max(s-i,1),d=Math.min(c*1.2,100);a>=d?(Be("RETRY",t.name,r),t.apply(null,r.concat([i]))):z[Z].push(e)}Kt===void 0&&(Kt=setTimeout(tn,0))}}});var vt=v(qe=>{"use strict";var Es=fe().fromCallback,ae=ne(),gf=["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(e=>typeof ae[e]=="function");Object.keys(ae).forEach(e=>{e!=="promises"&&(qe[e]=ae[e])});gf.forEach(e=>{qe[e]=Es(ae[e])});qe.exists=function(e,t){return typeof t=="function"?ae.exists(e,t):new Promise(r=>ae.exists(e,r))};qe.read=function(e,t,r,n,i,s){return typeof s=="function"?ae.read(e,t,r,n,i,s):new Promise((o,a)=>{ae.read(e,t,r,n,i,(c,d,f)=>{if(c)return a(c);o({bytesRead:d,buffer:f})})})};qe.write=function(e,t,...r){return typeof r[r.length-1]=="function"?ae.write(e,t,...r):new Promise((n,i)=>{ae.write(e,t,...r,(s,o,a)=>{if(s)return i(s);n({bytesWritten:o,buffer:a})})})};typeof ae.writev=="function"&&(qe.writev=function(e,t,...r){return typeof r[r.length-1]=="function"?ae.writev(e,t,...r):new Promise((n,i)=>{ae.writev(e,t,...r,(s,o,a)=>{if(s)return i(s);n({bytesWritten:o,buffers:a})})})});typeof ae.realpath.native=="function"&&(qe.realpath.native=Es(ae.realpath.native))});var nn=v((u1,Ss)=>{Ss.exports=e=>{let t=process.versions.node.split(".").map(r=>parseInt(r,10));return e=e.split(".").map(r=>parseInt(r,10)),t[0]>e[0]||t[0]===e[0]&&(t[1]>e[1]||t[1]===e[1]&&t[2]>=e[2])}});var As=v((l1,sn)=>{"use strict";var Qe=vt(),Re=require("path"),vf=nn(),ks=vf("10.12.0"),Cs=e=>{if(process.platform==="win32"&&/[<>:"|?*]/.test(e.replace(Re.parse(e).root,""))){let r=new Error(`Path contains invalid characters: ${e}`);throw r.code="EINVAL",r}},Rs=e=>{let t={mode:511};return typeof e=="number"&&(e={mode:e}),{...t,...e}},Os=e=>{let t=new Error(`operation not permitted, mkdir '${e}'`);return t.code="EPERM",t.errno=-4048,t.path=e,t.syscall="mkdir",t};sn.exports.makeDir=async(e,t)=>{if(Cs(e),t=Rs(t),ks){let n=Re.resolve(e);return Qe.mkdir(n,{mode:t.mode,recursive:!0})}let r=async n=>{try{await Qe.mkdir(n,t.mode)}catch(i){if(i.code==="EPERM")throw i;if(i.code==="ENOENT"){if(Re.dirname(n)===n)throw Os(n);if(i.message.includes("null bytes"))throw i;return await r(Re.dirname(n)),r(n)}try{if(!(await Qe.stat(n)).isDirectory())throw new Error("The path is not a directory")}catch{throw i}}};return r(Re.resolve(e))};sn.exports.makeDirSync=(e,t)=>{if(Cs(e),t=Rs(t),ks){let n=Re.resolve(e);return Qe.mkdirSync(n,{mode:t.mode,recursive:!0})}let r=n=>{try{Qe.mkdirSync(n,t.mode)}catch(i){if(i.code==="EPERM")throw i;if(i.code==="ENOENT"){if(Re.dirname(n)===n)throw Os(n);if(i.message.includes("null bytes"))throw i;return r(Re.dirname(n)),r(n)}try{if(!Qe.statSync(n).isDirectory())throw new Error("The path is not a directory")}catch{throw i}}};return r(Re.resolve(e))}});var Se=v((f1,Ps)=>{"use strict";var bf=fe().fromPromise,{makeDir:wf,makeDirSync:on}=As(),an=bf(wf);Ps.exports={mkdirs:an,mkdirsSync:on,mkdirp:an,mkdirpSync:on,ensureDir:an,ensureDirSync:on}});var cn=v((h1,qs)=>{"use strict";var Ze=ne();function _f(e,t,r,n){Ze.open(e,"r+",(i,s)=>{if(i)return n(i);Ze.futimes(s,t,r,o=>{Ze.close(s,a=>{n&&n(o||a)})})})}function xf(e,t,r){let n=Ze.openSync(e,"r+");return Ze.futimesSync(n,t,r),Ze.closeSync(n)}qs.exports={utimesMillis:_f,utimesMillisSync:xf}});var bt=v((d1,Is)=>{"use strict";var et=vt(),he=require("path"),Ef=require("util"),Sf=nn(),Qt=Sf("10.5.0"),Ms=e=>Qt?et.stat(e,{bigint:!0}):et.stat(e),un=e=>Qt?et.statSync(e,{bigint:!0}):et.statSync(e);function kf(e,t){return Promise.all([Ms(e),Ms(t).catch(r=>{if(r.code==="ENOENT")return null;throw r})]).then(([r,n])=>({srcStat:r,destStat:n}))}function Cf(e,t){let r,n=un(e);try{r=un(t)}catch(i){if(i.code==="ENOENT")return{srcStat:n,destStat:null};throw i}return{srcStat:n,destStat:r}}function Rf(e,t,r,n){Ef.callbackify(kf)(e,t,(i,s)=>{if(i)return n(i);let{srcStat:o,destStat:a}=s;return a&&Zt(o,a)?n(new Error("Source and destination must not be the same.")):o.isDirectory()&&ln(e,t)?n(new Error(er(e,t,r))):n(null,{srcStat:o,destStat:a})})}function Of(e,t,r){let{srcStat:n,destStat:i}=Cf(e,t);if(i&&Zt(n,i))throw new Error("Source and destination must not be the same.");if(n.isDirectory()&&ln(e,t))throw new Error(er(e,t,r));return{srcStat:n,destStat:i}}function Fs(e,t,r,n,i){let s=he.resolve(he.dirname(e)),o=he.resolve(he.dirname(r));if(o===s||o===he.parse(o).root)return i();let a=(c,d)=>c?c.code==="ENOENT"?i():i(c):Zt(t,d)?i(new Error(er(e,r,n))):Fs(e,t,o,n,i);Qt?et.stat(o,{bigint:!0},a):et.stat(o,a)}function Ts(e,t,r,n){let i=he.resolve(he.dirname(e)),s=he.resolve(he.dirname(r));if(s===i||s===he.parse(s).root)return;let o;try{o=un(s)}catch(a){if(a.code==="ENOENT")return;throw a}if(Zt(t,o))throw new Error(er(e,r,n));return Ts(e,t,s,n)}function Zt(e,t){return!!(t.ino&&t.dev&&t.ino===e.ino&&t.dev===e.dev&&(Qt||t.ino<Number.MAX_SAFE_INTEGER||t.size===e.size&&t.mode===e.mode&&t.nlink===e.nlink&&t.atimeMs===e.atimeMs&&t.mtimeMs===e.mtimeMs&&t.ctimeMs===e.ctimeMs&&t.birthtimeMs===e.birthtimeMs))}function ln(e,t){let r=he.resolve(e).split(he.sep).filter(i=>i),n=he.resolve(t).split(he.sep).filter(i=>i);return r.reduce((i,s,o)=>i&&n[o]===s,!0)}function er(e,t,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`}Is.exports={checkPaths:Rf,checkPathsSync:Of,checkParentPaths:Fs,checkParentPathsSync:Ts,isSrcSubdir:ln}});var Bs=v((p1,$s)=>{"use strict";var ie=ne(),wt=require("path"),Af=Se().mkdirsSync,Pf=cn().utimesMillisSync,_t=bt();function qf(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;
2
+ "use strict";var oh=Object.create;var So=Object.defineProperty;var ah=Object.getOwnPropertyDescriptor;var uh=Object.getOwnPropertyNames;var ch=Object.getPrototypeOf,lh=Object.prototype.hasOwnProperty;var y=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var fh=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of uh(e))!lh.call(t,i)&&i!==r&&So(t,i,{get:()=>e[i],enumerable:!(n=ah(e,i))||n.enumerable});return t};var T=(t,e,r)=>(r=t!=null?oh(ch(t)):{},fh(e||!t||!t.__esModule?So(r,"default",{value:t,enumerable:!0}):r,t));var zn=y((U1,Eo)=>{"use strict";Eo.exports=function(e,r){return function(){for(var i=new Array(arguments.length),s=0;s<i.length;s++)i[s]=arguments[s];return e.apply(r,i)}}});var he=y((X1,Do)=>{"use strict";var dh=zn(),it=Object.prototype.toString;function Kn(t){return it.call(t)==="[object Array]"}function Jn(t){return typeof t>"u"}function hh(t){return t!==null&&!Jn(t)&&t.constructor!==null&&!Jn(t.constructor)&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)}function ph(t){return it.call(t)==="[object ArrayBuffer]"}function mh(t){return typeof FormData<"u"&&t instanceof FormData}function gh(t){var e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&t.buffer instanceof ArrayBuffer,e}function yh(t){return typeof t=="string"}function vh(t){return typeof t=="number"}function Co(t){return t!==null&&typeof t=="object"}function Cr(t){if(it.call(t)!=="[object Object]")return!1;var e=Object.getPrototypeOf(t);return e===null||e===Object.prototype}function bh(t){return it.call(t)==="[object Date]"}function _h(t){return it.call(t)==="[object File]"}function wh(t){return it.call(t)==="[object Blob]"}function Po(t){return it.call(t)==="[object Function]"}function xh(t){return Co(t)&&Po(t.pipe)}function Sh(t){return typeof URLSearchParams<"u"&&t instanceof URLSearchParams}function Eh(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function Ch(){return typeof navigator<"u"&&(navigator.product==="ReactNative"||navigator.product==="NativeScript"||navigator.product==="NS")?!1:typeof window<"u"&&typeof document<"u"}function Yn(t,e){if(!(t===null||typeof t>"u"))if(typeof t!="object"&&(t=[t]),Kn(t))for(var r=0,n=t.length;r<n;r++)e.call(null,t[r],r,t);else for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.call(null,t[i],i,t)}function Vn(){var t={};function e(i,s){Cr(t[s])&&Cr(i)?t[s]=Vn(t[s],i):Cr(i)?t[s]=Vn({},i):Kn(i)?t[s]=i.slice():t[s]=i}for(var r=0,n=arguments.length;r<n;r++)Yn(arguments[r],e);return t}function Ph(t,e,r){return Yn(e,function(i,s){r&&typeof i=="function"?t[s]=dh(i,r):t[s]=i}),t}function Dh(t){return t.charCodeAt(0)===65279&&(t=t.slice(1)),t}Do.exports={isArray:Kn,isArrayBuffer:ph,isBuffer:hh,isFormData:mh,isArrayBufferView:gh,isString:yh,isNumber:vh,isObject:Co,isPlainObject:Cr,isUndefined:Jn,isDate:bh,isFile:_h,isBlob:wh,isFunction:Po,isStream:xh,isURLSearchParams:Sh,isStandardBrowserEnv:Ch,forEach:Yn,merge:Vn,extend:Ph,trim:Eh,stripBOM:Dh}});var Pr=y((H1,Ao)=>{"use strict";var gt=he();function Oo(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}Ao.exports=function(e,r,n){if(!r)return e;var i;if(n)i=n(r);else if(gt.isURLSearchParams(r))i=r.toString();else{var s=[];gt.forEach(r,function(u,h){u===null||typeof u>"u"||(gt.isArray(u)?h=h+"[]":u=[u],gt.forEach(u,function(p){gt.isDate(p)?p=p.toISOString():gt.isObject(p)&&(p=JSON.stringify(p)),s.push(Oo(h)+"="+Oo(p))}))}),i=s.join("&")}if(i){var o=e.indexOf("#");o!==-1&&(e=e.slice(0,o)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}});var Ro=y((G1,Io)=>{"use strict";var Oh=he();function Dr(){this.handlers=[]}Dr.prototype.use=function(e,r,n){return this.handlers.push({fulfilled:e,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1};Dr.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)};Dr.prototype.forEach=function(e){Oh.forEach(this.handlers,function(n){n!==null&&e(n)})};Io.exports=Dr});var ko=y((W1,Fo)=>{"use strict";var Ah=he();Fo.exports=function(e,r){Ah.forEach(e,function(i,s){s!==r&&s.toUpperCase()===r.toUpperCase()&&(e[r]=i,delete e[s])})}});var Or=y((z1,Mo)=>{"use strict";Mo.exports=function(e,r,n,i,s){return e.config=r,n&&(e.code=n),e.request=i,e.response=s,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},e}});var Ar=y((J1,qo)=>{"use strict";var Ih=Or();qo.exports=function(e,r,n,i,s){var o=new Error(e);return Ih(o,r,n,i,s)}});var Qn=y((V1,To)=>{"use strict";var Rh=Ar();To.exports=function(e,r,n){var i=n.config.validateStatus;!n.status||!i||i(n.status)?e(n):r(Rh("Request failed with status code "+n.status,n.config,null,n.request,n))}});var jo=y((K1,No)=>{"use strict";var Ir=he();No.exports=Ir.isStandardBrowserEnv()?function(){return{write:function(r,n,i,s,o,a){var u=[];u.push(r+"="+encodeURIComponent(n)),Ir.isNumber(i)&&u.push("expires="+new Date(i).toGMTString()),Ir.isString(s)&&u.push("path="+s),Ir.isString(o)&&u.push("domain="+o),a===!0&&u.push("secure"),document.cookie=u.join("; ")},read:function(r){var n=document.cookie.match(new RegExp("(^|;\\s*)("+r+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(r){this.write(r,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()});var $o=y((Y1,Lo)=>{"use strict";Lo.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}});var Uo=y((Q1,Bo)=>{"use strict";Bo.exports=function(e,r){return r?e.replace(/\/+$/,"")+"/"+r.replace(/^\/+/,""):e}});var Zn=y((Z1,Xo)=>{"use strict";var Fh=$o(),kh=Uo();Xo.exports=function(e,r){return e&&!Fh(r)?kh(e,r):r}});var Go=y((eb,Ho)=>{"use strict";var ei=he(),Mh=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];Ho.exports=function(e){var r={},n,i,s;return e&&ei.forEach(e.split(`
3
+ `),function(a){if(s=a.indexOf(":"),n=ei.trim(a.substr(0,s)).toLowerCase(),i=ei.trim(a.substr(s+1)),n){if(r[n]&&Mh.indexOf(n)>=0)return;n==="set-cookie"?r[n]=(r[n]?r[n]:[]).concat([i]):r[n]=r[n]?r[n]+", "+i:i}}),r}});var Jo=y((tb,zo)=>{"use strict";var Wo=he();zo.exports=Wo.isStandardBrowserEnv()?function(){var e=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a"),n;function i(s){var o=s;return e&&(r.setAttribute("href",o),o=r.href),r.setAttribute("href",o),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}return n=i(window.location.href),function(o){var a=Wo.isString(o)?i(o):o;return a.protocol===n.protocol&&a.host===n.host}}():function(){return function(){return!0}}()});var Ko=y((rb,Vo)=>{"use strict";var Rr=he(),qh=Qn(),Th=jo(),Nh=Pr(),jh=Zn(),Lh=Go(),$h=Jo(),ti=Ar();Vo.exports=function(e){return new Promise(function(n,i){var s=e.data,o=e.headers,a=e.responseType;Rr.isFormData(s)&&delete o["Content-Type"];var u=new XMLHttpRequest;if(e.auth){var h=e.auth.username||"",c=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";o.Authorization="Basic "+btoa(h+":"+c)}var p=jh(e.baseURL,e.url);u.open(e.method.toUpperCase(),Nh(p,e.params,e.paramsSerializer),!0),u.timeout=e.timeout;function g(){if(u){var _="getAllResponseHeaders"in u?Lh(u.getAllResponseHeaders()):null,C=!a||a==="text"||a==="json"?u.responseText:u.response,I={data:C,status:u.status,statusText:u.statusText,headers:_,config:e,request:u};qh(n,i,I),u=null}}if("onloadend"in u?u.onloadend=g:u.onreadystatechange=function(){!u||u.readyState!==4||u.status===0&&!(u.responseURL&&u.responseURL.indexOf("file:")===0)||setTimeout(g)},u.onabort=function(){u&&(i(ti("Request aborted",e,"ECONNABORTED",u)),u=null)},u.onerror=function(){i(ti("Network Error",e,null,u)),u=null},u.ontimeout=function(){var C="timeout of "+e.timeout+"ms exceeded";e.timeoutErrorMessage&&(C=e.timeoutErrorMessage),i(ti(C,e,e.transitional&&e.transitional.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",u)),u=null},Rr.isStandardBrowserEnv()){var m=(e.withCredentials||$h(p))&&e.xsrfCookieName?Th.read(e.xsrfCookieName):void 0;m&&(o[e.xsrfHeaderName]=m)}"setRequestHeader"in u&&Rr.forEach(o,function(C,I){typeof s>"u"&&I.toLowerCase()==="content-type"?delete o[I]:u.setRequestHeader(I,C)}),Rr.isUndefined(e.withCredentials)||(u.withCredentials=!!e.withCredentials),a&&a!=="json"&&(u.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&u.addEventListener("progress",e.onDownloadProgress),typeof e.onUploadProgress=="function"&&u.upload&&u.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then(function(C){u&&(u.abort(),i(C),u=null)}),s||(s=null),u.send(s)})}});var Qo=y((nb,Yo)=>{var yt=1e3,vt=yt*60,bt=vt*60,st=bt*24,Bh=st*7,Uh=st*365.25;Yo.exports=function(t,e){e=e||{};var r=typeof t;if(r==="string"&&t.length>0)return Xh(t);if(r==="number"&&isFinite(t))return e.long?Gh(t):Hh(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))};function Xh(t){if(t=String(t),!(t.length>100)){var e=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(e){var r=parseFloat(e[1]),n=(e[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*Uh;case"weeks":case"week":case"w":return r*Bh;case"days":case"day":case"d":return r*st;case"hours":case"hour":case"hrs":case"hr":case"h":return r*bt;case"minutes":case"minute":case"mins":case"min":case"m":return r*vt;case"seconds":case"second":case"secs":case"sec":case"s":return r*yt;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function Hh(t){var e=Math.abs(t);return e>=st?Math.round(t/st)+"d":e>=bt?Math.round(t/bt)+"h":e>=vt?Math.round(t/vt)+"m":e>=yt?Math.round(t/yt)+"s":t+"ms"}function Gh(t){var e=Math.abs(t);return e>=st?Fr(t,e,st,"day"):e>=bt?Fr(t,e,bt,"hour"):e>=vt?Fr(t,e,vt,"minute"):e>=yt?Fr(t,e,yt,"second"):t+" ms"}function Fr(t,e,r,n){var i=e>=r*1.5;return Math.round(t/r)+" "+n+(i?"s":"")}});var ri=y((ib,Zo)=>{function Wh(t){r.debug=r,r.default=r,r.coerce=u,r.disable=s,r.enable=i,r.enabled=o,r.humanize=Qo(),r.destroy=h,Object.keys(t).forEach(c=>{r[c]=t[c]}),r.names=[],r.skips=[],r.formatters={};function e(c){let p=0;for(let g=0;g<c.length;g++)p=(p<<5)-p+c.charCodeAt(g),p|=0;return r.colors[Math.abs(p)%r.colors.length]}r.selectColor=e;function r(c){let p,g=null,m,_;function C(...I){if(!C.enabled)return;let k=C,L=Number(new Date),U=L-(p||L);k.diff=U,k.prev=p,k.curr=L,p=L,I[0]=r.coerce(I[0]),typeof I[0]!="string"&&I.unshift("%O");let X=0;I[0]=I[0].replace(/%([a-zA-Z%])/g,(re,ve)=>{if(re==="%%")return"%";X++;let Q=r.formatters[ve];if(typeof Q=="function"){let b=I[X];re=Q.call(k,b),I.splice(X,1),X--}return re}),r.formatArgs.call(k,I),(k.log||r.log).apply(k,I)}return C.namespace=c,C.useColors=r.useColors(),C.color=r.selectColor(c),C.extend=n,C.destroy=r.destroy,Object.defineProperty(C,"enabled",{enumerable:!0,configurable:!1,get:()=>g!==null?g:(m!==r.namespaces&&(m=r.namespaces,_=r.enabled(c)),_),set:I=>{g=I}}),typeof r.init=="function"&&r.init(C),C}function n(c,p){let g=r(this.namespace+(typeof p>"u"?":":p)+c);return g.log=this.log,g}function i(c){r.save(c),r.namespaces=c,r.names=[],r.skips=[];let p,g=(typeof c=="string"?c:"").split(/[\s,]+/),m=g.length;for(p=0;p<m;p++)g[p]&&(c=g[p].replace(/\*/g,".*?"),c[0]==="-"?r.skips.push(new RegExp("^"+c.slice(1)+"$")):r.names.push(new RegExp("^"+c+"$")))}function s(){let c=[...r.names.map(a),...r.skips.map(a).map(p=>"-"+p)].join(",");return r.enable(""),c}function o(c){if(c[c.length-1]==="*")return!0;let p,g;for(p=0,g=r.skips.length;p<g;p++)if(r.skips[p].test(c))return!1;for(p=0,g=r.names.length;p<g;p++)if(r.names[p].test(c))return!0;return!1}function a(c){return c.toString().substring(2,c.toString().length-2).replace(/\.\*\?$/,"*")}function u(c){return c instanceof Error?c.stack||c.message:c}function h(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}Zo.exports=Wh});var ea=y((Oe,kr)=>{Oe.formatArgs=Jh;Oe.save=Vh;Oe.load=Kh;Oe.useColors=zh;Oe.storage=Yh();Oe.destroy=(()=>{let t=!1;return()=>{t||(t=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})();Oe.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function zh(){return typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)?!0:typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function Jh(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+kr.exports.humanize(this.diff),!this.useColors)return;let e="color: "+this.color;t.splice(1,0,e,"color: inherit");let r=0,n=0;t[0].replace(/%[a-zA-Z%]/g,i=>{i!=="%%"&&(r++,i==="%c"&&(n=r))}),t.splice(n,0,e)}Oe.log=console.debug||console.log||(()=>{});function Vh(t){try{t?Oe.storage.setItem("debug",t):Oe.storage.removeItem("debug")}catch{}}function Kh(){let t;try{t=Oe.storage.getItem("debug")}catch{}return!t&&typeof process<"u"&&"env"in process&&(t=process.env.DEBUG),t}function Yh(){try{return localStorage}catch{}}kr.exports=ri()(Oe);var{formatters:Qh}=kr.exports;Qh.j=function(t){try{return JSON.stringify(t)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}});var ra=y((sb,ta)=>{"use strict";ta.exports=(t,e=process.argv)=>{let r=t.startsWith("-")?"":t.length===1?"-":"--",n=e.indexOf(r+t),i=e.indexOf("--");return n!==-1&&(i===-1||n<i)}});var si=y((ob,ia)=>{"use strict";var Zh=require("os"),na=require("tty"),Re=ra(),{env:Z}=process,We;Re("no-color")||Re("no-colors")||Re("color=false")||Re("color=never")?We=0:(Re("color")||Re("colors")||Re("color=true")||Re("color=always"))&&(We=1);"FORCE_COLOR"in Z&&(Z.FORCE_COLOR==="true"?We=1:Z.FORCE_COLOR==="false"?We=0:We=Z.FORCE_COLOR.length===0?1:Math.min(parseInt(Z.FORCE_COLOR,10),3));function ni(t){return t===0?!1:{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3}}function ii(t,e){if(We===0)return 0;if(Re("color=16m")||Re("color=full")||Re("color=truecolor"))return 3;if(Re("color=256"))return 2;if(t&&!e&&We===void 0)return 0;let r=We||0;if(Z.TERM==="dumb")return r;if(process.platform==="win32"){let n=Zh.release().split(".");return Number(n[0])>=10&&Number(n[2])>=10586?Number(n[2])>=14931?3:2:1}if("CI"in Z)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some(n=>n in Z)||Z.CI_NAME==="codeship"?1:r;if("TEAMCITY_VERSION"in Z)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(Z.TEAMCITY_VERSION)?1:0;if(Z.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in Z){let n=parseInt((Z.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(Z.TERM_PROGRAM){case"iTerm.app":return n>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(Z.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(Z.TERM)||"COLORTERM"in Z?1:r}function ep(t){let e=ii(t,t&&t.isTTY);return ni(e)}ia.exports={supportsColor:ep,stdout:ni(ii(!0,na.isatty(1))),stderr:ni(ii(!0,na.isatty(2)))}});var oa=y((ie,qr)=>{var tp=require("tty"),Mr=require("util");ie.init=up;ie.log=sp;ie.formatArgs=np;ie.save=op;ie.load=ap;ie.useColors=rp;ie.destroy=Mr.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");ie.colors=[6,2,3,4,5,1];try{let t=si();t&&(t.stderr||t).level>=2&&(ie.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch{}ie.inspectOpts=Object.keys(process.env).filter(t=>/^debug_/i.test(t)).reduce((t,e)=>{let r=e.substring(6).toLowerCase().replace(/_([a-z])/g,(i,s)=>s.toUpperCase()),n=process.env[e];return/^(yes|on|true|enabled)$/i.test(n)?n=!0:/^(no|off|false|disabled)$/i.test(n)?n=!1:n==="null"?n=null:n=Number(n),t[r]=n,t},{});function rp(){return"colors"in ie.inspectOpts?!!ie.inspectOpts.colors:tp.isatty(process.stderr.fd)}function np(t){let{namespace:e,useColors:r}=this;if(r){let n=this.color,i="\x1B[3"+(n<8?n:"8;5;"+n),s=` ${i};1m${e} \x1B[0m`;t[0]=s+t[0].split(`
4
+ `).join(`
5
+ `+s),t.push(i+"m+"+qr.exports.humanize(this.diff)+"\x1B[0m")}else t[0]=ip()+e+" "+t[0]}function ip(){return ie.inspectOpts.hideDate?"":new Date().toISOString()+" "}function sp(...t){return process.stderr.write(Mr.format(...t)+`
6
+ `)}function op(t){t?process.env.DEBUG=t:delete process.env.DEBUG}function ap(){return process.env.DEBUG}function up(t){t.inspectOpts={};let e=Object.keys(ie.inspectOpts);for(let r=0;r<e.length;r++)t.inspectOpts[e[r]]=ie.inspectOpts[e[r]]}qr.exports=ri()(ie);var{formatters:sa}=qr.exports;sa.o=function(t){return this.inspectOpts.colors=this.useColors,Mr.inspect(t,this.inspectOpts).split(`
7
+ `).map(e=>e.trim()).join(" ")};sa.O=function(t){return this.inspectOpts.colors=this.useColors,Mr.inspect(t,this.inspectOpts)}});var aa=y((ab,oi)=>{typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?oi.exports=ea():oi.exports=oa()});var ca=y((ub,ua)=>{var Ht;ua.exports=function(){if(!Ht){try{Ht=aa()("follow-redirects")}catch{}typeof Ht!="function"&&(Ht=function(){})}Ht.apply(null,arguments)}});var di=y((cb,fi)=>{var ot=require("url"),ai=ot.URL,cp=require("http"),lp=require("https"),da=require("stream").Writable,ha=require("assert"),pa=ca(),ci=["abort","aborted","connect","error","socket","timeout"],li=Object.create(null);ci.forEach(function(t){li[t]=function(e,r,n){this._redirectable.emit(t,e,r,n)}});var fp=Wt("ERR_INVALID_URL","Invalid URL",TypeError),la=Wt("ERR_FR_REDIRECTION_FAILURE","Redirected request failed"),dp=Wt("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded"),hp=Wt("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit"),pp=Wt("ERR_STREAM_WRITE_AFTER_END","write after end");function Ae(t,e){da.call(this),this._sanitizeOptions(t),this._options=t,this._ended=!1,this._ending=!1,this._redirectCount=0,this._redirects=[],this._requestBodyLength=0,this._requestBodyBuffers=[],e&&this.on("response",e);var r=this;this._onNativeResponse=function(n){r._processResponse(n)},this._performRequest()}Ae.prototype=Object.create(da.prototype);Ae.prototype.abort=function(){ga(this._currentRequest),this.emit("abort")};Ae.prototype.write=function(t,e,r){if(this._ending)throw new pp;if(!at(t)&&!yp(t))throw new TypeError("data should be a string, Buffer or Uint8Array");if(Gt(e)&&(r=e,e=null),t.length===0){r&&r();return}this._requestBodyLength+t.length<=this._options.maxBodyLength?(this._requestBodyLength+=t.length,this._requestBodyBuffers.push({data:t,encoding:e}),this._currentRequest.write(t,e,r)):(this.emit("error",new hp),this.abort())};Ae.prototype.end=function(t,e,r){if(Gt(t)?(r=t,t=e=null):Gt(e)&&(r=e,e=null),!t)this._ended=this._ending=!0,this._currentRequest.end(null,null,r);else{var n=this,i=this._currentRequest;this.write(t,e,function(){n._ended=!0,i.end(null,null,r)}),this._ending=!0}};Ae.prototype.setHeader=function(t,e){this._options.headers[t]=e,this._currentRequest.setHeader(t,e)};Ae.prototype.removeHeader=function(t){delete this._options.headers[t],this._currentRequest.removeHeader(t)};Ae.prototype.setTimeout=function(t,e){var r=this;function n(o){o.setTimeout(t),o.removeListener("timeout",o.destroy),o.addListener("timeout",o.destroy)}function i(o){r._timeout&&clearTimeout(r._timeout),r._timeout=setTimeout(function(){r.emit("timeout"),s()},t),n(o)}function s(){r._timeout&&(clearTimeout(r._timeout),r._timeout=null),r.removeListener("abort",s),r.removeListener("error",s),r.removeListener("response",s),e&&r.removeListener("timeout",e),r.socket||r._currentRequest.removeListener("socket",i)}return e&&this.on("timeout",e),this.socket?i(this.socket):this._currentRequest.once("socket",i),this.on("socket",n),this.on("abort",s),this.on("error",s),this.on("response",s),this};["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach(function(t){Ae.prototype[t]=function(e,r){return this._currentRequest[t](e,r)}});["aborted","connection","socket"].forEach(function(t){Object.defineProperty(Ae.prototype,t,{get:function(){return this._currentRequest[t]}})});Ae.prototype._sanitizeOptions=function(t){if(t.headers||(t.headers={}),t.host&&(t.hostname||(t.hostname=t.host),delete t.host),!t.pathname&&t.path){var e=t.path.indexOf("?");e<0?t.pathname=t.path:(t.pathname=t.path.substring(0,e),t.search=t.path.substring(e))}};Ae.prototype._performRequest=function(){var t=this._options.protocol,e=this._options.nativeProtocols[t];if(!e){this.emit("error",new TypeError("Unsupported protocol "+t));return}if(this._options.agents){var r=t.slice(0,-1);this._options.agent=this._options.agents[r]}var n=this._currentRequest=e.request(this._options,this._onNativeResponse);n._redirectable=this;for(var i of ci)n.on(i,li[i]);if(this._currentUrl=/^\//.test(this._options.path)?ot.format(this._options):this._options.path,this._isRedirect){var s=0,o=this,a=this._requestBodyBuffers;(function u(h){if(n===o._currentRequest)if(h)o.emit("error",h);else if(s<a.length){var c=a[s++];n.finished||n.write(c.data,c.encoding,u)}else o._ended&&n.end()})()}};Ae.prototype._processResponse=function(t){var e=t.statusCode;this._options.trackRedirects&&this._redirects.push({url:this._currentUrl,headers:t.headers,statusCode:e});var r=t.headers.location;if(!r||this._options.followRedirects===!1||e<300||e>=400){t.responseUrl=this._currentUrl,t.redirects=this._redirects,this.emit("response",t),this._requestBodyBuffers=[];return}if(ga(this._currentRequest),t.destroy(),++this._redirectCount>this._options.maxRedirects){this.emit("error",new dp);return}var n,i=this._options.beforeRedirect;i&&(n=Object.assign({Host:t.req.getHeader("host")},this._options.headers));var s=this._options.method;((e===301||e===302)&&this._options.method==="POST"||e===303&&!/^(?:GET|HEAD)$/.test(this._options.method))&&(this._options.method="GET",this._requestBodyBuffers=[],ui(/^content-/i,this._options.headers));var o=ui(/^host$/i,this._options.headers),a=ot.parse(this._currentUrl),u=o||a.host,h=/^\w+:/.test(r)?this._currentUrl:ot.format(Object.assign(a,{host:u})),c;try{c=ot.resolve(h,r)}catch(_){this.emit("error",new la({cause:_}));return}pa("redirecting to",c),this._isRedirect=!0;var p=ot.parse(c);if(Object.assign(this._options,p),(p.protocol!==a.protocol&&p.protocol!=="https:"||p.host!==u&&!gp(p.host,u))&&ui(/^(?:authorization|cookie)$/i,this._options.headers),Gt(i)){var g={headers:t.headers,statusCode:e},m={url:h,method:s,headers:n};try{i(this._options,g,m)}catch(_){this.emit("error",_);return}this._sanitizeOptions(this._options)}try{this._performRequest()}catch(_){this.emit("error",new la({cause:_}))}};function ma(t){var e={maxRedirects:21,maxBodyLength:10485760},r={};return Object.keys(t).forEach(function(n){var i=n+":",s=r[i]=t[n],o=e[n]=Object.create(s);function a(h,c,p){if(at(h)){var g;try{g=fa(new ai(h))}catch{g=ot.parse(h)}if(!at(g.protocol))throw new fp({input:h});h=g}else ai&&h instanceof ai?h=fa(h):(p=c,c=h,h={protocol:i});return Gt(c)&&(p=c,c=null),c=Object.assign({maxRedirects:e.maxRedirects,maxBodyLength:e.maxBodyLength},h,c),c.nativeProtocols=r,!at(c.host)&&!at(c.hostname)&&(c.hostname="::1"),ha.equal(c.protocol,i,"protocol mismatch"),pa("options",c),new Ae(c,p)}function u(h,c,p){var g=o.request(h,c,p);return g.end(),g}Object.defineProperties(o,{request:{value:a,configurable:!0,enumerable:!0,writable:!0},get:{value:u,configurable:!0,enumerable:!0,writable:!0}})}),e}function mp(){}function fa(t){var e={protocol:t.protocol,hostname:t.hostname.startsWith("[")?t.hostname.slice(1,-1):t.hostname,hash:t.hash,search:t.search,pathname:t.pathname,path:t.pathname+t.search,href:t.href};return t.port!==""&&(e.port=Number(t.port)),e}function ui(t,e){var r;for(var n in e)t.test(n)&&(r=e[n],delete e[n]);return r===null||typeof r>"u"?void 0:String(r).trim()}function Wt(t,e,r){function n(i){Error.captureStackTrace(this,this.constructor),Object.assign(this,i||{}),this.code=t,this.message=this.cause?e+": "+this.cause.message:e}return n.prototype=new(r||Error),n.prototype.constructor=n,n.prototype.name="Error ["+t+"]",n}function ga(t){for(var e of ci)t.removeListener(e,li[e]);t.on("error",mp),t.abort()}function gp(t,e){ha(at(t)&&at(e));var r=t.length-e.length-1;return r>0&&t[r]==="."&&t.endsWith(e)}function at(t){return typeof t=="string"||t instanceof String}function Gt(t){return typeof t=="function"}function yp(t){return typeof t=="object"&&"length"in t}fi.exports=ma({http:cp,https:lp});fi.exports.wrap=ma});var hi=y((lb,vp)=>{vp.exports={name:"axios",version:"0.21.4",description:"Promise based HTTP client for the browser and node.js",main:"index.js",scripts:{test:"grunt test",start:"node ./sandbox/server.js",build:"NODE_ENV=production grunt build",preversion:"npm test",version:"npm run build && grunt version && git add -A dist && git add CHANGELOG.md bower.json package.json",postversion:"git push && git push --tags",examples:"node ./examples/server.js",coveralls:"cat coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js",fix:"eslint --fix lib/**/*.js"},repository:{type:"git",url:"https://github.com/axios/axios.git"},keywords:["xhr","http","ajax","promise","node"],author:"Matt Zabriskie",license:"MIT",bugs:{url:"https://github.com/axios/axios/issues"},homepage:"https://axios-http.com",devDependencies:{coveralls:"^3.0.0","es6-promise":"^4.2.4",grunt:"^1.3.0","grunt-banner":"^0.6.0","grunt-cli":"^1.2.0","grunt-contrib-clean":"^1.1.0","grunt-contrib-watch":"^1.0.0","grunt-eslint":"^23.0.0","grunt-karma":"^4.0.0","grunt-mocha-test":"^0.13.3","grunt-ts":"^6.0.0-beta.19","grunt-webpack":"^4.0.2","istanbul-instrumenter-loader":"^1.0.0","jasmine-core":"^2.4.1",karma:"^6.3.2","karma-chrome-launcher":"^3.1.0","karma-firefox-launcher":"^2.1.0","karma-jasmine":"^1.1.1","karma-jasmine-ajax":"^0.1.13","karma-safari-launcher":"^1.0.0","karma-sauce-launcher":"^4.3.6","karma-sinon":"^1.0.5","karma-sourcemap-loader":"^0.3.8","karma-webpack":"^4.0.2","load-grunt-tasks":"^3.5.2",minimist:"^1.2.0",mocha:"^8.2.1",sinon:"^4.5.0","terser-webpack-plugin":"^4.2.3",typescript:"^4.0.5","url-search-params":"^0.10.0",webpack:"^4.44.2","webpack-dev-server":"^3.11.0"},browser:{"./lib/adapters/http.js":"./lib/adapters/xhr.js"},jsdelivr:"dist/axios.min.js",unpkg:"dist/axios.min.js",typings:"./index.d.ts",dependencies:{"follow-redirects":"^1.14.0"},bundlesize:[{path:"./dist/axios.min.js",threshold:"5kB"}]}});var xa=y((fb,wa)=>{"use strict";var zt=he(),ya=Qn(),bp=Zn(),_p=Pr(),wp=require("http"),xp=require("https"),Sp=di().http,Ep=di().https,va=require("url"),Cp=require("zlib"),Pp=hi(),Tr=Ar(),pi=Or(),ba=/https:?/;function _a(t,e,r){if(t.hostname=e.host,t.host=e.host,t.port=e.port,t.path=r,e.auth){var n=Buffer.from(e.auth.username+":"+e.auth.password,"utf8").toString("base64");t.headers["Proxy-Authorization"]="Basic "+n}t.beforeRedirect=function(s){s.headers.host=s.host,_a(s,e,s.href)}}wa.exports=function(e){return new Promise(function(n,i){var s=function(P){n(P)},o=function(P){i(P)},a=e.data,u=e.headers;if("User-Agent"in u||"user-agent"in u?!u["User-Agent"]&&!u["user-agent"]&&(delete u["User-Agent"],delete u["user-agent"]):u["User-Agent"]="axios/"+Pp.version,a&&!zt.isStream(a)){if(!Buffer.isBuffer(a))if(zt.isArrayBuffer(a))a=Buffer.from(new Uint8Array(a));else if(zt.isString(a))a=Buffer.from(a,"utf-8");else return o(Tr("Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream",e));u["Content-Length"]=a.length}var h=void 0;if(e.auth){var c=e.auth.username||"",p=e.auth.password||"";h=c+":"+p}var g=bp(e.baseURL,e.url),m=va.parse(g),_=m.protocol||"http:";if(!h&&m.auth){var C=m.auth.split(":"),I=C[0]||"",k=C[1]||"";h=I+":"+k}h&&delete u.Authorization;var L=ba.test(_),U=L?e.httpsAgent:e.httpAgent,X={path:_p(m.path,e.params,e.paramsSerializer).replace(/^\?/,""),method:e.method.toUpperCase(),headers:u,agent:U,agents:{http:e.httpAgent,https:e.httpsAgent},auth:h};e.socketPath?X.socketPath=e.socketPath:(X.hostname=m.hostname,X.port=m.port);var z=e.proxy;if(!z&&z!==!1){var re=_.slice(0,-1)+"_proxy",ve=process.env[re]||process.env[re.toUpperCase()];if(ve){var Q=va.parse(ve),b=process.env.no_proxy||process.env.NO_PROXY,w=!0;if(b){var E=b.split(",").map(function(P){return P.trim()});w=!E.some(function(P){return P?P==="*"||P[0]==="."&&m.hostname.substr(m.hostname.length-P.length)===P?!0:m.hostname===P:!1})}if(w&&(z={host:Q.hostname,port:Q.port,protocol:Q.protocol},Q.auth)){var $=Q.auth.split(":");z.auth={username:$[0],password:$[1]}}}}z&&(X.headers.host=m.hostname+(m.port?":"+m.port:""),_a(X,z,_+"//"+m.hostname+(m.port?":"+m.port:"")+X.path));var R,j=L&&(z?ba.test(z.protocol):!0);e.transport?R=e.transport:e.maxRedirects===0?R=j?xp:wp:(e.maxRedirects&&(X.maxRedirects=e.maxRedirects),R=j?Ep:Sp),e.maxBodyLength>-1&&(X.maxBodyLength=e.maxBodyLength);var D=R.request(X,function(P){if(!D.aborted){var F=P,De=P.req||D;if(P.statusCode!==204&&De.method!=="HEAD"&&e.decompress!==!1)switch(P.headers["content-encoding"]){case"gzip":case"compress":case"deflate":F=F.pipe(Cp.createUnzip()),delete P.headers["content-encoding"];break}var be={status:P.statusCode,statusText:P.statusMessage,headers:P.headers,config:e,request:De};if(e.responseType==="stream")be.data=F,ya(s,o,be);else{var ne=[],ue=0;F.on("data",function(_e){ne.push(_e),ue+=_e.length,e.maxContentLength>-1&&ue>e.maxContentLength&&(F.destroy(),o(Tr("maxContentLength size of "+e.maxContentLength+" exceeded",e,null,De)))}),F.on("error",function(_e){D.aborted||o(pi(_e,e,null,De))}),F.on("end",function(){var _e=Buffer.concat(ne);e.responseType!=="arraybuffer"&&(_e=_e.toString(e.responseEncoding),(!e.responseEncoding||e.responseEncoding==="utf8")&&(_e=zt.stripBOM(_e))),be.data=_e,ya(s,o,be)})}}});if(D.on("error",function(P){D.aborted&&P.code!=="ERR_FR_TOO_MANY_REDIRECTS"||o(pi(P,e,null,D))}),e.timeout){var N=parseInt(e.timeout,10);if(isNaN(N)){o(Tr("error trying to parse `config.timeout` to int",e,"ERR_PARSE_TIMEOUT",D));return}D.setTimeout(N,function(){D.abort(),o(Tr("timeout of "+N+"ms exceeded",e,e.transitional&&e.transitional.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",D))})}e.cancelToken&&e.cancelToken.promise.then(function(P){D.aborted||(D.abort(),o(P))}),zt.isStream(a)?a.on("error",function(P){o(pi(P,e,null,D))}).pipe(D):D.end(a)})}});var jr=y((db,Ca)=>{"use strict";var se=he(),Sa=ko(),Dp=Or(),Op={"Content-Type":"application/x-www-form-urlencoded"};function Ea(t,e){!se.isUndefined(t)&&se.isUndefined(t["Content-Type"])&&(t["Content-Type"]=e)}function Ap(){var t;return typeof XMLHttpRequest<"u"?t=Ko():typeof process<"u"&&Object.prototype.toString.call(process)==="[object process]"&&(t=xa()),t}function Ip(t,e,r){if(se.isString(t))try{return(e||JSON.parse)(t),se.trim(t)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(t)}var Nr={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:Ap(),transformRequest:[function(e,r){return Sa(r,"Accept"),Sa(r,"Content-Type"),se.isFormData(e)||se.isArrayBuffer(e)||se.isBuffer(e)||se.isStream(e)||se.isFile(e)||se.isBlob(e)?e:se.isArrayBufferView(e)?e.buffer:se.isURLSearchParams(e)?(Ea(r,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):se.isObject(e)||r&&r["Content-Type"]==="application/json"?(Ea(r,"application/json"),Ip(e)):e}],transformResponse:[function(e){var r=this.transitional,n=r&&r.silentJSONParsing,i=r&&r.forcedJSONParsing,s=!n&&this.responseType==="json";if(s||i&&se.isString(e)&&e.length)try{return JSON.parse(e)}catch(o){if(s)throw o.name==="SyntaxError"?Dp(o,this,"E_JSON_PARSE"):o}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(e){return e>=200&&e<300}};Nr.headers={common:{Accept:"application/json, text/plain, */*"}};se.forEach(["delete","get","head"],function(e){Nr.headers[e]={}});se.forEach(["post","put","patch"],function(e){Nr.headers[e]=se.merge(Op)});Ca.exports=Nr});var Da=y((hb,Pa)=>{"use strict";var Rp=he(),Fp=jr();Pa.exports=function(e,r,n){var i=this||Fp;return Rp.forEach(n,function(o){e=o.call(i,e,r)}),e}});var mi=y((pb,Oa)=>{"use strict";Oa.exports=function(e){return!!(e&&e.__CANCEL__)}});var Ra=y((mb,Ia)=>{"use strict";var Aa=he(),gi=Da(),kp=mi(),Mp=jr();function yi(t){t.cancelToken&&t.cancelToken.throwIfRequested()}Ia.exports=function(e){yi(e),e.headers=e.headers||{},e.data=gi.call(e,e.data,e.headers,e.transformRequest),e.headers=Aa.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),Aa.forEach(["delete","get","head","post","put","patch","common"],function(i){delete e.headers[i]});var r=e.adapter||Mp.adapter;return r(e).then(function(i){return yi(e),i.data=gi.call(e,i.data,i.headers,e.transformResponse),i},function(i){return kp(i)||(yi(e),i&&i.response&&(i.response.data=gi.call(e,i.response.data,i.response.headers,e.transformResponse))),Promise.reject(i)})}});var vi=y((gb,Fa)=>{"use strict";var ce=he();Fa.exports=function(e,r){r=r||{};var n={},i=["url","method","data"],s=["headers","auth","proxy","params"],o=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],a=["validateStatus"];function u(g,m){return ce.isPlainObject(g)&&ce.isPlainObject(m)?ce.merge(g,m):ce.isPlainObject(m)?ce.merge({},m):ce.isArray(m)?m.slice():m}function h(g){ce.isUndefined(r[g])?ce.isUndefined(e[g])||(n[g]=u(void 0,e[g])):n[g]=u(e[g],r[g])}ce.forEach(i,function(m){ce.isUndefined(r[m])||(n[m]=u(void 0,r[m]))}),ce.forEach(s,h),ce.forEach(o,function(m){ce.isUndefined(r[m])?ce.isUndefined(e[m])||(n[m]=u(void 0,e[m])):n[m]=u(void 0,r[m])}),ce.forEach(a,function(m){m in r?n[m]=u(e[m],r[m]):m in e&&(n[m]=u(void 0,e[m]))});var c=i.concat(s).concat(o).concat(a),p=Object.keys(e).concat(Object.keys(r)).filter(function(m){return c.indexOf(m)===-1});return ce.forEach(p,h),n}});var Na=y((yb,Ta)=>{"use strict";var Ma=hi(),bi={};["object","boolean","number","function","string","symbol"].forEach(function(t,e){bi[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}});var ka={},qp=Ma.version.split(".");function qa(t,e){for(var r=e?e.split("."):qp,n=t.split("."),i=0;i<3;i++){if(r[i]>n[i])return!0;if(r[i]<n[i])return!1}return!1}bi.transitional=function(e,r,n){var i=r&&qa(r);function s(o,a){return"[Axios v"+Ma.version+"] Transitional option '"+o+"'"+a+(n?". "+n:"")}return function(o,a,u){if(e===!1)throw new Error(s(a," has been removed in "+r));return i&&!ka[a]&&(ka[a]=!0,console.warn(s(a," has been deprecated since v"+r+" and will be removed in the near future"))),e?e(o,a,u):!0}};function Tp(t,e,r){if(typeof t!="object")throw new TypeError("options must be an object");for(var n=Object.keys(t),i=n.length;i-- >0;){var s=n[i],o=e[s];if(o){var a=t[s],u=a===void 0||o(a,s,t);if(u!==!0)throw new TypeError("option "+s+" must be "+u);continue}if(r!==!0)throw Error("Unknown option "+s)}}Ta.exports={isOlderVersion:qa,assertOptions:Tp,validators:bi}});var Xa=y((vb,Ua)=>{"use strict";var $a=he(),Np=Pr(),ja=Ro(),La=Ra(),Lr=vi(),Ba=Na(),_t=Ba.validators;function Jt(t){this.defaults=t,this.interceptors={request:new ja,response:new ja}}Jt.prototype.request=function(e){typeof e=="string"?(e=arguments[1]||{},e.url=arguments[0]):e=e||{},e=Lr(this.defaults,e),e.method?e.method=e.method.toLowerCase():this.defaults.method?e.method=this.defaults.method.toLowerCase():e.method="get";var r=e.transitional;r!==void 0&&Ba.assertOptions(r,{silentJSONParsing:_t.transitional(_t.boolean,"1.0.0"),forcedJSONParsing:_t.transitional(_t.boolean,"1.0.0"),clarifyTimeoutError:_t.transitional(_t.boolean,"1.0.0")},!1);var n=[],i=!0;this.interceptors.request.forEach(function(g){typeof g.runWhen=="function"&&g.runWhen(e)===!1||(i=i&&g.synchronous,n.unshift(g.fulfilled,g.rejected))});var s=[];this.interceptors.response.forEach(function(g){s.push(g.fulfilled,g.rejected)});var o;if(!i){var a=[La,void 0];for(Array.prototype.unshift.apply(a,n),a=a.concat(s),o=Promise.resolve(e);a.length;)o=o.then(a.shift(),a.shift());return o}for(var u=e;n.length;){var h=n.shift(),c=n.shift();try{u=h(u)}catch(p){c(p);break}}try{o=La(u)}catch(p){return Promise.reject(p)}for(;s.length;)o=o.then(s.shift(),s.shift());return o};Jt.prototype.getUri=function(e){return e=Lr(this.defaults,e),Np(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")};$a.forEach(["delete","get","head","options"],function(e){Jt.prototype[e]=function(r,n){return this.request(Lr(n||{},{method:e,url:r,data:(n||{}).data}))}});$a.forEach(["post","put","patch"],function(e){Jt.prototype[e]=function(r,n,i){return this.request(Lr(i||{},{method:e,url:r,data:n}))}});Ua.exports=Jt});var wi=y((bb,Ha)=>{"use strict";function _i(t){this.message=t}_i.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")};_i.prototype.__CANCEL__=!0;Ha.exports=_i});var Wa=y((_b,Ga)=>{"use strict";var jp=wi();function $r(t){if(typeof t!="function")throw new TypeError("executor must be a function.");var e;this.promise=new Promise(function(i){e=i});var r=this;t(function(i){r.reason||(r.reason=new jp(i),e(r.reason))})}$r.prototype.throwIfRequested=function(){if(this.reason)throw this.reason};$r.source=function(){var e,r=new $r(function(i){e=i});return{token:r,cancel:e}};Ga.exports=$r});var Ja=y((wb,za)=>{"use strict";za.exports=function(e){return function(n){return e.apply(null,n)}}});var Ka=y((xb,Va)=>{"use strict";Va.exports=function(e){return typeof e=="object"&&e.isAxiosError===!0}});var Za=y((Sb,xi)=>{"use strict";var Ya=he(),Lp=zn(),Br=Xa(),$p=vi(),Bp=jr();function Qa(t){var e=new Br(t),r=Lp(Br.prototype.request,e);return Ya.extend(r,Br.prototype,e),Ya.extend(r,e),r}var qe=Qa(Bp);qe.Axios=Br;qe.create=function(e){return Qa($p(qe.defaults,e))};qe.Cancel=wi();qe.CancelToken=Wa();qe.isCancel=mi();qe.all=function(e){return Promise.all(e)};qe.spread=Ja();qe.isAxiosError=Ka();xi.exports=qe;xi.exports.default=qe});var Si=y((Eb,eu)=>{eu.exports=Za()});var ru=y((Cb,tu)=>{"use strict";var Up=/[|\\{}()[\]^$+*?.]/g;tu.exports=function(t){if(typeof t!="string")throw new TypeError("Expected a string");return t.replace(Up,"\\$&")}});var iu=y((Pb,nu)=>{"use strict";nu.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}});var Ei=y((Db,uu)=>{var ut=iu(),au={};for(Ur in ut)ut.hasOwnProperty(Ur)&&(au[ut[Ur]]=Ur);var Ur,O=uu.exports={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};for(pe in O)if(O.hasOwnProperty(pe)){if(!("channels"in O[pe]))throw new Error("missing channels property: "+pe);if(!("labels"in O[pe]))throw new Error("missing channel labels property: "+pe);if(O[pe].labels.length!==O[pe].channels)throw new Error("channel and label counts mismatch: "+pe);su=O[pe].channels,ou=O[pe].labels,delete O[pe].channels,delete O[pe].labels,Object.defineProperty(O[pe],"channels",{value:su}),Object.defineProperty(O[pe],"labels",{value:ou})}var su,ou,pe;O.rgb.hsl=function(t){var e=t[0]/255,r=t[1]/255,n=t[2]/255,i=Math.min(e,r,n),s=Math.max(e,r,n),o=s-i,a,u,h;return s===i?a=0:e===s?a=(r-n)/o:r===s?a=2+(n-e)/o:n===s&&(a=4+(e-r)/o),a=Math.min(a*60,360),a<0&&(a+=360),h=(i+s)/2,s===i?u=0:h<=.5?u=o/(s+i):u=o/(2-s-i),[a,u*100,h*100]};O.rgb.hsv=function(t){var e,r,n,i,s,o=t[0]/255,a=t[1]/255,u=t[2]/255,h=Math.max(o,a,u),c=h-Math.min(o,a,u),p=function(g){return(h-g)/6/c+1/2};return c===0?i=s=0:(s=c/h,e=p(o),r=p(a),n=p(u),o===h?i=n-r:a===h?i=1/3+e-n:u===h&&(i=2/3+r-e),i<0?i+=1:i>1&&(i-=1)),[i*360,s*100,h*100]};O.rgb.hwb=function(t){var e=t[0],r=t[1],n=t[2],i=O.rgb.hsl(t)[0],s=1/255*Math.min(e,Math.min(r,n));return n=1-1/255*Math.max(e,Math.max(r,n)),[i,s*100,n*100]};O.rgb.cmyk=function(t){var e=t[0]/255,r=t[1]/255,n=t[2]/255,i,s,o,a;return a=Math.min(1-e,1-r,1-n),i=(1-e-a)/(1-a)||0,s=(1-r-a)/(1-a)||0,o=(1-n-a)/(1-a)||0,[i*100,s*100,o*100,a*100]};function Xp(t,e){return Math.pow(t[0]-e[0],2)+Math.pow(t[1]-e[1],2)+Math.pow(t[2]-e[2],2)}O.rgb.keyword=function(t){var e=au[t];if(e)return e;var r=1/0,n;for(var i in ut)if(ut.hasOwnProperty(i)){var s=ut[i],o=Xp(t,s);o<r&&(r=o,n=i)}return n};O.keyword.rgb=function(t){return ut[t]};O.rgb.xyz=function(t){var e=t[0]/255,r=t[1]/255,n=t[2]/255;e=e>.04045?Math.pow((e+.055)/1.055,2.4):e/12.92,r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92,n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92;var i=e*.4124+r*.3576+n*.1805,s=e*.2126+r*.7152+n*.0722,o=e*.0193+r*.1192+n*.9505;return[i*100,s*100,o*100]};O.rgb.lab=function(t){var e=O.rgb.xyz(t),r=e[0],n=e[1],i=e[2],s,o,a;return r/=95.047,n/=100,i/=108.883,r=r>.008856?Math.pow(r,1/3):7.787*r+16/116,n=n>.008856?Math.pow(n,1/3):7.787*n+16/116,i=i>.008856?Math.pow(i,1/3):7.787*i+16/116,s=116*n-16,o=500*(r-n),a=200*(n-i),[s,o,a]};O.hsl.rgb=function(t){var e=t[0]/360,r=t[1]/100,n=t[2]/100,i,s,o,a,u;if(r===0)return u=n*255,[u,u,u];n<.5?s=n*(1+r):s=n+r-n*r,i=2*n-s,a=[0,0,0];for(var h=0;h<3;h++)o=e+1/3*-(h-1),o<0&&o++,o>1&&o--,6*o<1?u=i+(s-i)*6*o:2*o<1?u=s:3*o<2?u=i+(s-i)*(2/3-o)*6:u=i,a[h]=u*255;return a};O.hsl.hsv=function(t){var e=t[0],r=t[1]/100,n=t[2]/100,i=r,s=Math.max(n,.01),o,a;return n*=2,r*=n<=1?n:2-n,i*=s<=1?s:2-s,a=(n+r)/2,o=n===0?2*i/(s+i):2*r/(n+r),[e,o*100,a*100]};O.hsv.rgb=function(t){var e=t[0]/60,r=t[1]/100,n=t[2]/100,i=Math.floor(e)%6,s=e-Math.floor(e),o=255*n*(1-r),a=255*n*(1-r*s),u=255*n*(1-r*(1-s));switch(n*=255,i){case 0:return[n,u,o];case 1:return[a,n,o];case 2:return[o,n,u];case 3:return[o,a,n];case 4:return[u,o,n];case 5:return[n,o,a]}};O.hsv.hsl=function(t){var e=t[0],r=t[1]/100,n=t[2]/100,i=Math.max(n,.01),s,o,a;return a=(2-r)*n,s=(2-r)*i,o=r*i,o/=s<=1?s:2-s,o=o||0,a/=2,[e,o*100,a*100]};O.hwb.rgb=function(t){var e=t[0]/360,r=t[1]/100,n=t[2]/100,i=r+n,s,o,a,u;i>1&&(r/=i,n/=i),s=Math.floor(6*e),o=1-n,a=6*e-s,s&1&&(a=1-a),u=r+a*(o-r);var h,c,p;switch(s){default:case 6:case 0:h=o,c=u,p=r;break;case 1:h=u,c=o,p=r;break;case 2:h=r,c=o,p=u;break;case 3:h=r,c=u,p=o;break;case 4:h=u,c=r,p=o;break;case 5:h=o,c=r,p=u;break}return[h*255,c*255,p*255]};O.cmyk.rgb=function(t){var e=t[0]/100,r=t[1]/100,n=t[2]/100,i=t[3]/100,s,o,a;return s=1-Math.min(1,e*(1-i)+i),o=1-Math.min(1,r*(1-i)+i),a=1-Math.min(1,n*(1-i)+i),[s*255,o*255,a*255]};O.xyz.rgb=function(t){var e=t[0]/100,r=t[1]/100,n=t[2]/100,i,s,o;return i=e*3.2406+r*-1.5372+n*-.4986,s=e*-.9689+r*1.8758+n*.0415,o=e*.0557+r*-.204+n*1.057,i=i>.0031308?1.055*Math.pow(i,1/2.4)-.055:i*12.92,s=s>.0031308?1.055*Math.pow(s,1/2.4)-.055:s*12.92,o=o>.0031308?1.055*Math.pow(o,1/2.4)-.055:o*12.92,i=Math.min(Math.max(0,i),1),s=Math.min(Math.max(0,s),1),o=Math.min(Math.max(0,o),1),[i*255,s*255,o*255]};O.xyz.lab=function(t){var e=t[0],r=t[1],n=t[2],i,s,o;return e/=95.047,r/=100,n/=108.883,e=e>.008856?Math.pow(e,1/3):7.787*e+16/116,r=r>.008856?Math.pow(r,1/3):7.787*r+16/116,n=n>.008856?Math.pow(n,1/3):7.787*n+16/116,i=116*r-16,s=500*(e-r),o=200*(r-n),[i,s,o]};O.lab.xyz=function(t){var e=t[0],r=t[1],n=t[2],i,s,o;s=(e+16)/116,i=r/500+s,o=s-n/200;var a=Math.pow(s,3),u=Math.pow(i,3),h=Math.pow(o,3);return s=a>.008856?a:(s-16/116)/7.787,i=u>.008856?u:(i-16/116)/7.787,o=h>.008856?h:(o-16/116)/7.787,i*=95.047,s*=100,o*=108.883,[i,s,o]};O.lab.lch=function(t){var e=t[0],r=t[1],n=t[2],i,s,o;return i=Math.atan2(n,r),s=i*360/2/Math.PI,s<0&&(s+=360),o=Math.sqrt(r*r+n*n),[e,o,s]};O.lch.lab=function(t){var e=t[0],r=t[1],n=t[2],i,s,o;return o=n/360*2*Math.PI,i=r*Math.cos(o),s=r*Math.sin(o),[e,i,s]};O.rgb.ansi16=function(t){var e=t[0],r=t[1],n=t[2],i=1 in arguments?arguments[1]:O.rgb.hsv(t)[2];if(i=Math.round(i/50),i===0)return 30;var s=30+(Math.round(n/255)<<2|Math.round(r/255)<<1|Math.round(e/255));return i===2&&(s+=60),s};O.hsv.ansi16=function(t){return O.rgb.ansi16(O.hsv.rgb(t),t[2])};O.rgb.ansi256=function(t){var e=t[0],r=t[1],n=t[2];if(e===r&&r===n)return e<8?16:e>248?231:Math.round((e-8)/247*24)+232;var i=16+36*Math.round(e/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5);return i};O.ansi16.rgb=function(t){var e=t%10;if(e===0||e===7)return t>50&&(e+=3.5),e=e/10.5*255,[e,e,e];var r=(~~(t>50)+1)*.5,n=(e&1)*r*255,i=(e>>1&1)*r*255,s=(e>>2&1)*r*255;return[n,i,s]};O.ansi256.rgb=function(t){if(t>=232){var e=(t-232)*10+8;return[e,e,e]}t-=16;var r,n=Math.floor(t/36)/5*255,i=Math.floor((r=t%36)/6)/5*255,s=r%6/5*255;return[n,i,s]};O.rgb.hex=function(t){var e=((Math.round(t[0])&255)<<16)+((Math.round(t[1])&255)<<8)+(Math.round(t[2])&255),r=e.toString(16).toUpperCase();return"000000".substring(r.length)+r};O.hex.rgb=function(t){var e=t.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!e)return[0,0,0];var r=e[0];e[0].length===3&&(r=r.split("").map(function(a){return a+a}).join(""));var n=parseInt(r,16),i=n>>16&255,s=n>>8&255,o=n&255;return[i,s,o]};O.rgb.hcg=function(t){var e=t[0]/255,r=t[1]/255,n=t[2]/255,i=Math.max(Math.max(e,r),n),s=Math.min(Math.min(e,r),n),o=i-s,a,u;return o<1?a=s/(1-o):a=0,o<=0?u=0:i===e?u=(r-n)/o%6:i===r?u=2+(n-e)/o:u=4+(e-r)/o+4,u/=6,u%=1,[u*360,o*100,a*100]};O.hsl.hcg=function(t){var e=t[1]/100,r=t[2]/100,n=1,i=0;return r<.5?n=2*e*r:n=2*e*(1-r),n<1&&(i=(r-.5*n)/(1-n)),[t[0],n*100,i*100]};O.hsv.hcg=function(t){var e=t[1]/100,r=t[2]/100,n=e*r,i=0;return n<1&&(i=(r-n)/(1-n)),[t[0],n*100,i*100]};O.hcg.rgb=function(t){var e=t[0]/360,r=t[1]/100,n=t[2]/100;if(r===0)return[n*255,n*255,n*255];var i=[0,0,0],s=e%1*6,o=s%1,a=1-o,u=0;switch(Math.floor(s)){case 0:i[0]=1,i[1]=o,i[2]=0;break;case 1:i[0]=a,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=o;break;case 3:i[0]=0,i[1]=a,i[2]=1;break;case 4:i[0]=o,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=a}return u=(1-r)*n,[(r*i[0]+u)*255,(r*i[1]+u)*255,(r*i[2]+u)*255]};O.hcg.hsv=function(t){var e=t[1]/100,r=t[2]/100,n=e+r*(1-e),i=0;return n>0&&(i=e/n),[t[0],i*100,n*100]};O.hcg.hsl=function(t){var e=t[1]/100,r=t[2]/100,n=r*(1-e)+.5*e,i=0;return n>0&&n<.5?i=e/(2*n):n>=.5&&n<1&&(i=e/(2*(1-n))),[t[0],i*100,n*100]};O.hcg.hwb=function(t){var e=t[1]/100,r=t[2]/100,n=e+r*(1-e);return[t[0],(n-e)*100,(1-n)*100]};O.hwb.hcg=function(t){var e=t[1]/100,r=t[2]/100,n=1-r,i=n-e,s=0;return i<1&&(s=(n-i)/(1-i)),[t[0],i*100,s*100]};O.apple.rgb=function(t){return[t[0]/65535*255,t[1]/65535*255,t[2]/65535*255]};O.rgb.apple=function(t){return[t[0]/255*65535,t[1]/255*65535,t[2]/255*65535]};O.gray.rgb=function(t){return[t[0]/100*255,t[0]/100*255,t[0]/100*255]};O.gray.hsl=O.gray.hsv=function(t){return[0,0,t[0]]};O.gray.hwb=function(t){return[0,100,t[0]]};O.gray.cmyk=function(t){return[0,0,0,t[0]]};O.gray.lab=function(t){return[t[0],0,0]};O.gray.hex=function(t){var e=Math.round(t[0]/100*255)&255,r=(e<<16)+(e<<8)+e,n=r.toString(16).toUpperCase();return"000000".substring(n.length)+n};O.rgb.gray=function(t){var e=(t[0]+t[1]+t[2])/3;return[e/255*100]}});var lu=y((Ob,cu)=>{var Xr=Ei();function Hp(){for(var t={},e=Object.keys(Xr),r=e.length,n=0;n<r;n++)t[e[n]]={distance:-1,parent:null};return t}function Gp(t){var e=Hp(),r=[t];for(e[t].distance=0;r.length;)for(var n=r.pop(),i=Object.keys(Xr[n]),s=i.length,o=0;o<s;o++){var a=i[o],u=e[a];u.distance===-1&&(u.distance=e[n].distance+1,u.parent=n,r.unshift(a))}return e}function Wp(t,e){return function(r){return e(t(r))}}function zp(t,e){for(var r=[e[t].parent,t],n=Xr[e[t].parent][t],i=e[t].parent;e[i].parent;)r.unshift(e[i].parent),n=Wp(Xr[e[i].parent][i],n),i=e[i].parent;return n.conversion=r,n}cu.exports=function(t){for(var e=Gp(t),r={},n=Object.keys(e),i=n.length,s=0;s<i;s++){var o=n[s],a=e[o];a.parent!==null&&(r[o]=zp(o,e))}return r}});var du=y((Ab,fu)=>{var Ci=Ei(),Jp=lu(),wt={},Vp=Object.keys(Ci);function Kp(t){var e=function(r){return r==null?r:(arguments.length>1&&(r=Array.prototype.slice.call(arguments)),t(r))};return"conversion"in t&&(e.conversion=t.conversion),e}function Yp(t){var e=function(r){if(r==null)return r;arguments.length>1&&(r=Array.prototype.slice.call(arguments));var n=t(r);if(typeof n=="object")for(var i=n.length,s=0;s<i;s++)n[s]=Math.round(n[s]);return n};return"conversion"in t&&(e.conversion=t.conversion),e}Vp.forEach(function(t){wt[t]={},Object.defineProperty(wt[t],"channels",{value:Ci[t].channels}),Object.defineProperty(wt[t],"labels",{value:Ci[t].labels});var e=Jp(t),r=Object.keys(e);r.forEach(function(n){var i=e[n];wt[t][n]=Yp(i),wt[t][n].raw=Kp(i)})});fu.exports=wt});var pu=y((Ib,hu)=>{"use strict";var xt=du(),Hr=(t,e)=>function(){return`\x1B[${t.apply(xt,arguments)+e}m`},Gr=(t,e)=>function(){let r=t.apply(xt,arguments);return`\x1B[${38+e};5;${r}m`},Wr=(t,e)=>function(){let r=t.apply(xt,arguments);return`\x1B[${38+e};2;${r[0]};${r[1]};${r[2]}m`};function Qp(){let t=new Map,e={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],gray:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};e.color.grey=e.color.gray;for(let i of Object.keys(e)){let s=e[i];for(let o of Object.keys(s)){let a=s[o];e[o]={open:`\x1B[${a[0]}m`,close:`\x1B[${a[1]}m`},s[o]=e[o],t.set(a[0],a[1])}Object.defineProperty(e,i,{value:s,enumerable:!1}),Object.defineProperty(e,"codes",{value:t,enumerable:!1})}let r=i=>i,n=(i,s,o)=>[i,s,o];e.color.close="\x1B[39m",e.bgColor.close="\x1B[49m",e.color.ansi={ansi:Hr(r,0)},e.color.ansi256={ansi256:Gr(r,0)},e.color.ansi16m={rgb:Wr(n,0)},e.bgColor.ansi={ansi:Hr(r,10)},e.bgColor.ansi256={ansi256:Gr(r,10)},e.bgColor.ansi16m={rgb:Wr(n,10)};for(let i of Object.keys(xt)){if(typeof xt[i]!="object")continue;let s=xt[i];i==="ansi16"&&(i="ansi"),"ansi16"in s&&(e.color.ansi[i]=Hr(s.ansi16,0),e.bgColor.ansi[i]=Hr(s.ansi16,10)),"ansi256"in s&&(e.color.ansi256[i]=Gr(s.ansi256,0),e.bgColor.ansi256[i]=Gr(s.ansi256,10)),"rgb"in s&&(e.color.ansi16m[i]=Wr(s.rgb,0),e.bgColor.ansi16m[i]=Wr(s.rgb,10))}return e}Object.defineProperty(hu,"exports",{enumerable:!0,get:Qp})});var gu=y((Rb,mu)=>{"use strict";mu.exports=(t,e)=>{e=e||process.argv;let r=t.startsWith("-")?"":t.length===1?"-":"--",n=e.indexOf(r+t),i=e.indexOf("--");return n!==-1&&(i===-1?!0:n<i)}});var vu=y((Fb,yu)=>{"use strict";var Zp=require("os"),Te=gu(),le=process.env,St;Te("no-color")||Te("no-colors")||Te("color=false")?St=!1:(Te("color")||Te("colors")||Te("color=true")||Te("color=always"))&&(St=!0);"FORCE_COLOR"in le&&(St=le.FORCE_COLOR.length===0||parseInt(le.FORCE_COLOR,10)!==0);function e0(t){return t===0?!1:{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3}}function t0(t){if(St===!1)return 0;if(Te("color=16m")||Te("color=full")||Te("color=truecolor"))return 3;if(Te("color=256"))return 2;if(t&&!t.isTTY&&St!==!0)return 0;let e=St?1:0;if(process.platform==="win32"){let r=Zp.release().split(".");return Number(process.versions.node.split(".")[0])>=8&&Number(r[0])>=10&&Number(r[2])>=10586?Number(r[2])>=14931?3:2:1}if("CI"in le)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI"].some(r=>r in le)||le.CI_NAME==="codeship"?1:e;if("TEAMCITY_VERSION"in le)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(le.TEAMCITY_VERSION)?1:0;if(le.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in le){let r=parseInt((le.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(le.TERM_PROGRAM){case"iTerm.app":return r>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(le.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(le.TERM)||"COLORTERM"in le?1:(le.TERM==="dumb",e)}function Pi(t){let e=t0(t);return e0(e)}yu.exports={supportsColor:Pi,stdout:Pi(process.stdout),stderr:Pi(process.stderr)}});var Su=y((kb,xu)=>{"use strict";var r0=/(?:\\(u[a-f\d]{4}|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,bu=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,n0=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,i0=/\\(u[a-f\d]{4}|x[a-f\d]{2}|.)|([^\\])/gi,s0=new Map([["n",`
8
+ `],["r","\r"],["t"," "],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e","\x1B"],["a","\x07"]]);function wu(t){return t[0]==="u"&&t.length===5||t[0]==="x"&&t.length===3?String.fromCharCode(parseInt(t.slice(1),16)):s0.get(t)||t}function o0(t,e){let r=[],n=e.trim().split(/\s*,\s*/g),i;for(let s of n)if(!isNaN(s))r.push(Number(s));else if(i=s.match(n0))r.push(i[2].replace(i0,(o,a,u)=>a?wu(a):u));else throw new Error(`Invalid Chalk template style argument: ${s} (in style '${t}')`);return r}function a0(t){bu.lastIndex=0;let e=[],r;for(;(r=bu.exec(t))!==null;){let n=r[1];if(r[2]){let i=o0(n,r[2]);e.push([n].concat(i))}else e.push([n])}return e}function _u(t,e){let r={};for(let i of e)for(let s of i.styles)r[s[0]]=i.inverse?null:s.slice(1);let n=t;for(let i of Object.keys(r))if(Array.isArray(r[i])){if(!(i in n))throw new Error(`Unknown Chalk style: ${i}`);r[i].length>0?n=n[i].apply(n,r[i]):n=n[i]}return n}xu.exports=(t,e)=>{let r=[],n=[],i=[];if(e.replace(r0,(s,o,a,u,h,c)=>{if(o)i.push(wu(o));else if(u){let p=i.join("");i=[],n.push(r.length===0?p:_u(t,r)(p)),r.push({inverse:a,styles:a0(u)})}else if(h){if(r.length===0)throw new Error("Found extraneous } in Chalk template literal");n.push(_u(t,r)(i.join(""))),i=[],r.pop()}else i.push(c)}),n.push(i.join("")),r.length>0){let s=`Chalk template literal is missing ${r.length} closing bracket${r.length===1?"":"s"} (\`}\`)`;throw new Error(s)}return n.join("")}});var Yt=y((Mb,Kt)=>{"use strict";var Oi=ru(),K=pu(),Di=vu().stdout,u0=Su(),Cu=process.platform==="win32"&&!(process.env.TERM||"").toLowerCase().startsWith("xterm"),Pu=["ansi","ansi","ansi256","ansi16m"],Du=new Set(["gray"]),Et=Object.create(null);function Eu(t,e){e=e||{};let r=Di?Di.level:0;t.level=e.level===void 0?r:e.level,t.enabled="enabled"in e?e.enabled:t.level>0}function Vt(t){if(!this||!(this instanceof Vt)||this.template){let e={};return Eu(e,t),e.template=function(){let r=[].slice.call(arguments);return f0.apply(null,[e.template].concat(r))},Object.setPrototypeOf(e,Vt.prototype),Object.setPrototypeOf(e.template,e),e.template.constructor=Vt,e.template}Eu(this,t)}Cu&&(K.blue.open="\x1B[94m");for(let t of Object.keys(K))K[t].closeRe=new RegExp(Oi(K[t].close),"g"),Et[t]={get(){let e=K[t];return zr.call(this,this._styles?this._styles.concat(e):[e],this._empty,t)}};Et.visible={get(){return zr.call(this,this._styles||[],!0,"visible")}};K.color.closeRe=new RegExp(Oi(K.color.close),"g");for(let t of Object.keys(K.color.ansi))Du.has(t)||(Et[t]={get(){let e=this.level;return function(){let n={open:K.color[Pu[e]][t].apply(null,arguments),close:K.color.close,closeRe:K.color.closeRe};return zr.call(this,this._styles?this._styles.concat(n):[n],this._empty,t)}}});K.bgColor.closeRe=new RegExp(Oi(K.bgColor.close),"g");for(let t of Object.keys(K.bgColor.ansi)){if(Du.has(t))continue;let e="bg"+t[0].toUpperCase()+t.slice(1);Et[e]={get(){let r=this.level;return function(){let i={open:K.bgColor[Pu[r]][t].apply(null,arguments),close:K.bgColor.close,closeRe:K.bgColor.closeRe};return zr.call(this,this._styles?this._styles.concat(i):[i],this._empty,t)}}}}var c0=Object.defineProperties(()=>{},Et);function zr(t,e,r){let n=function(){return l0.apply(n,arguments)};n._styles=t,n._empty=e;let i=this;return Object.defineProperty(n,"level",{enumerable:!0,get(){return i.level},set(s){i.level=s}}),Object.defineProperty(n,"enabled",{enumerable:!0,get(){return i.enabled},set(s){i.enabled=s}}),n.hasGrey=this.hasGrey||r==="gray"||r==="grey",n.__proto__=c0,n}function l0(){let t=arguments,e=t.length,r=String(arguments[0]);if(e===0)return"";if(e>1)for(let i=1;i<e;i++)r+=" "+t[i];if(!this.enabled||this.level<=0||!r)return this._empty?"":r;let n=K.dim.open;Cu&&this.hasGrey&&(K.dim.open="");for(let i of this._styles.slice().reverse())r=i.open+r.replace(i.closeRe,i.open)+i.close,r=r.replace(/\r?\n/g,`${i.close}$&${i.open}`);return K.dim.open=n,r}function f0(t,e){if(!Array.isArray(e))return[].slice.call(arguments,1).join(" ");let r=[].slice.call(arguments,2),n=[e.raw[0]];for(let i=1;i<e.length;i++)n.push(String(r[i-1]).replace(/[{}\\]/g,"\\$&")),n.push(String(e.raw[i]));return u0(t,n.join(""))}Object.defineProperties(Vt.prototype,Et);Kt.exports=Vt();Kt.exports.supportsColor=Di;Kt.exports.default=Kt.exports});var Xe=y((Tb,Ii)=>{var d0=require("fs"),h0=require("path");function Iu(t){console.log(`[dotenv][DEBUG] ${t}`)}var p0=`
9
+ `,m0=/^\s*([\w.-]+)\s*=\s*(.*)?\s*$/,g0=/\\n/g,y0=/\n|\r|\r\n/;function Ru(t,e){let r=!!(e&&e.debug),n={};return t.toString().split(y0).forEach(function(i,s){let o=i.match(m0);if(o!=null){let a=o[1],u=o[2]||"",h=u.length-1,c=u[0]==='"'&&u[h]==='"';u[0]==="'"&&u[h]==="'"||c?(u=u.substring(1,h),c&&(u=u.replace(g0,p0))):u=u.trim(),n[a]=u}else r&&Iu(`did not match key and value when parsing line ${s+1}: ${i}`)}),n}function v0(t){let e=h0.resolve(process.cwd(),".env"),r="utf8",n=!1;t&&(t.path!=null&&(e=t.path),t.encoding!=null&&(r=t.encoding),t.debug!=null&&(n=!0));try{let i=Ru(d0.readFileSync(e,{encoding:r}),{debug:n});return Object.keys(i).forEach(function(s){Object.prototype.hasOwnProperty.call(process.env,s)?n&&Iu(`"${s}" is already defined in \`process.env\` and will not be overwritten`):process.env[s]=i[s]}),{parsed:i}}catch(i){return{error:i}}}Ii.exports.config=v0;Ii.exports.parse=Ru});var we=y(Ri=>{"use strict";Ri.fromCallback=function(t){return Object.defineProperty(function(...e){if(typeof e[e.length-1]=="function")t.apply(this,e);else return new Promise((r,n)=>{t.call(this,...e,(i,s)=>i!=null?n(i):r(s))})},"name",{value:t.name})};Ri.fromPromise=function(t){return Object.defineProperty(function(...e){let r=e[e.length-1];if(typeof r!="function")return t.apply(this,e);t.apply(this,e.slice(0,-1)).then(n=>r(null,n),r)},"name",{value:t.name})}});var ku=y((jb,Fu)=>{var ze=require("constants"),b0=process.cwd,Jr=null,_0=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return Jr||(Jr=b0.call(process)),Jr};try{process.cwd()}catch{}typeof process.chdir=="function"&&(Fi=process.chdir,process.chdir=function(t){Jr=null,Fi.call(process,t)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,Fi));var Fi;Fu.exports=w0;function w0(t){ze.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&e(t),t.lutimes||r(t),t.chown=s(t.chown),t.fchown=s(t.fchown),t.lchown=s(t.lchown),t.chmod=n(t.chmod),t.fchmod=n(t.fchmod),t.lchmod=n(t.lchmod),t.chownSync=o(t.chownSync),t.fchownSync=o(t.fchownSync),t.lchownSync=o(t.lchownSync),t.chmodSync=i(t.chmodSync),t.fchmodSync=i(t.fchmodSync),t.lchmodSync=i(t.lchmodSync),t.stat=a(t.stat),t.fstat=a(t.fstat),t.lstat=a(t.lstat),t.statSync=u(t.statSync),t.fstatSync=u(t.fstatSync),t.lstatSync=u(t.lstatSync),t.chmod&&!t.lchmod&&(t.lchmod=function(c,p,g){g&&process.nextTick(g)},t.lchmodSync=function(){}),t.chown&&!t.lchown&&(t.lchown=function(c,p,g,m){m&&process.nextTick(m)},t.lchownSync=function(){}),_0==="win32"&&(t.rename=typeof t.rename!="function"?t.rename:function(c){function p(g,m,_){var C=Date.now(),I=0;c(g,m,function k(L){if(L&&(L.code==="EACCES"||L.code==="EPERM")&&Date.now()-C<6e4){setTimeout(function(){t.stat(m,function(U,X){U&&U.code==="ENOENT"?c(g,m,k):_(L)})},I),I<100&&(I+=10);return}_&&_(L)})}return Object.setPrototypeOf&&Object.setPrototypeOf(p,c),p}(t.rename)),t.read=typeof t.read!="function"?t.read:function(c){function p(g,m,_,C,I,k){var L;if(k&&typeof k=="function"){var U=0;L=function(X,z,re){if(X&&X.code==="EAGAIN"&&U<10)return U++,c.call(t,g,m,_,C,I,L);k.apply(this,arguments)}}return c.call(t,g,m,_,C,I,L)}return Object.setPrototypeOf&&Object.setPrototypeOf(p,c),p}(t.read),t.readSync=typeof t.readSync!="function"?t.readSync:function(c){return function(p,g,m,_,C){for(var I=0;;)try{return c.call(t,p,g,m,_,C)}catch(k){if(k.code==="EAGAIN"&&I<10){I++;continue}throw k}}}(t.readSync);function e(c){c.lchmod=function(p,g,m){c.open(p,ze.O_WRONLY|ze.O_SYMLINK,g,function(_,C){if(_){m&&m(_);return}c.fchmod(C,g,function(I){c.close(C,function(k){m&&m(I||k)})})})},c.lchmodSync=function(p,g){var m=c.openSync(p,ze.O_WRONLY|ze.O_SYMLINK,g),_=!0,C;try{C=c.fchmodSync(m,g),_=!1}finally{if(_)try{c.closeSync(m)}catch{}else c.closeSync(m)}return C}}function r(c){ze.hasOwnProperty("O_SYMLINK")&&c.futimes?(c.lutimes=function(p,g,m,_){c.open(p,ze.O_SYMLINK,function(C,I){if(C){_&&_(C);return}c.futimes(I,g,m,function(k){c.close(I,function(L){_&&_(k||L)})})})},c.lutimesSync=function(p,g,m){var _=c.openSync(p,ze.O_SYMLINK),C,I=!0;try{C=c.futimesSync(_,g,m),I=!1}finally{if(I)try{c.closeSync(_)}catch{}else c.closeSync(_)}return C}):c.futimes&&(c.lutimes=function(p,g,m,_){_&&process.nextTick(_)},c.lutimesSync=function(){})}function n(c){return c&&function(p,g,m){return c.call(t,p,g,function(_){h(_)&&(_=null),m&&m.apply(this,arguments)})}}function i(c){return c&&function(p,g){try{return c.call(t,p,g)}catch(m){if(!h(m))throw m}}}function s(c){return c&&function(p,g,m,_){return c.call(t,p,g,m,function(C){h(C)&&(C=null),_&&_.apply(this,arguments)})}}function o(c){return c&&function(p,g,m){try{return c.call(t,p,g,m)}catch(_){if(!h(_))throw _}}}function a(c){return c&&function(p,g,m){typeof g=="function"&&(m=g,g=null);function _(C,I){I&&(I.uid<0&&(I.uid+=4294967296),I.gid<0&&(I.gid+=4294967296)),m&&m.apply(this,arguments)}return g?c.call(t,p,g,_):c.call(t,p,_)}}function u(c){return c&&function(p,g){var m=g?c.call(t,p,g):c.call(t,p);return m&&(m.uid<0&&(m.uid+=4294967296),m.gid<0&&(m.gid+=4294967296)),m}}function h(c){if(!c||c.code==="ENOSYS")return!0;var p=!process.getuid||process.getuid()!==0;return!!(p&&(c.code==="EINVAL"||c.code==="EPERM"))}}});var Tu=y((Lb,qu)=>{var Mu=require("stream").Stream;qu.exports=x0;function x0(t){return{ReadStream:e,WriteStream:r};function e(n,i){if(!(this instanceof e))return new e(n,i);Mu.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),a=0,u=o.length;a<u;a++){var h=o[a];this[h]=i[h]}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}t.open(this.path,this.flags,this.mode,function(c,p){if(c){s.emit("error",c),s.readable=!1;return}s.fd=p,s.emit("open",p),s._read()})}function r(n,i){if(!(this instanceof r))return new r(n,i);Mu.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,a=s.length;o<a;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=t.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}});var ju=y(($b,Nu)=>{"use strict";Nu.exports=E0;var S0=Object.getPrototypeOf||function(t){return t.__proto__};function E0(t){if(t===null||typeof t!="object")return t;if(t instanceof Object)var e={__proto__:S0(t)};else var e=Object.create(null);return Object.getOwnPropertyNames(t).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}});var fe=y((Bb,qi)=>{var W=require("fs"),C0=ku(),P0=Tu(),D0=ju(),Vr=require("util"),oe,Yr;typeof Symbol=="function"&&typeof Symbol.for=="function"?(oe=Symbol.for("graceful-fs.queue"),Yr=Symbol.for("graceful-fs.previous")):(oe="___graceful-fs.queue",Yr="___graceful-fs.previous");function O0(){}function Bu(t,e){Object.defineProperty(t,oe,{get:function(){return e}})}var ct=O0;Vr.debuglog?ct=Vr.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(ct=function(){var t=Vr.format.apply(Vr,arguments);t="GFS4: "+t.split(/\n/).join(`
10
+ GFS4: `),console.error(t)});W[oe]||(Lu=global[oe]||[],Bu(W,Lu),W.close=function(t){function e(r,n){return t.call(W,r,function(i){i||$u(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(e,Yr,{value:t}),e}(W.close),W.closeSync=function(t){function e(r){t.apply(W,arguments),$u()}return Object.defineProperty(e,Yr,{value:t}),e}(W.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){ct(W[oe]),require("assert").equal(W[oe].length,0)}));var Lu;global[oe]||Bu(global,W[oe]);qi.exports=ki(D0(W));process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!W.__patched&&(qi.exports=ki(W),W.__patched=!0);function ki(t){C0(t),t.gracefulify=ki,t.createReadStream=z,t.createWriteStream=re;var e=t.readFile;t.readFile=r;function r(b,w,E){return typeof w=="function"&&(E=w,w=null),$(b,w,E);function $(R,j,D,N){return e(R,j,function(M){M&&(M.code==="EMFILE"||M.code==="ENFILE")?Pt([$,[R,j,D],M,N||Date.now(),Date.now()]):typeof D=="function"&&D.apply(this,arguments)})}}var n=t.writeFile;t.writeFile=i;function i(b,w,E,$){return typeof E=="function"&&($=E,E=null),R(b,w,E,$);function R(j,D,N,M,P){return n(j,D,N,function(F){F&&(F.code==="EMFILE"||F.code==="ENFILE")?Pt([R,[j,D,N,M],F,P||Date.now(),Date.now()]):typeof M=="function"&&M.apply(this,arguments)})}}var s=t.appendFile;s&&(t.appendFile=o);function o(b,w,E,$){return typeof E=="function"&&($=E,E=null),R(b,w,E,$);function R(j,D,N,M,P){return s(j,D,N,function(F){F&&(F.code==="EMFILE"||F.code==="ENFILE")?Pt([R,[j,D,N,M],F,P||Date.now(),Date.now()]):typeof M=="function"&&M.apply(this,arguments)})}}var a=t.copyFile;a&&(t.copyFile=u);function u(b,w,E,$){return typeof E=="function"&&($=E,E=0),R(b,w,E,$);function R(j,D,N,M,P){return a(j,D,N,function(F){F&&(F.code==="EMFILE"||F.code==="ENFILE")?Pt([R,[j,D,N,M],F,P||Date.now(),Date.now()]):typeof M=="function"&&M.apply(this,arguments)})}}var h=t.readdir;t.readdir=p;var c=/^v[0-5]\./;function p(b,w,E){typeof w=="function"&&(E=w,w=null);var $=c.test(process.version)?function(D,N,M,P){return h(D,R(D,N,M,P))}:function(D,N,M,P){return h(D,N,R(D,N,M,P))};return $(b,w,E);function R(j,D,N,M){return function(P,F){P&&(P.code==="EMFILE"||P.code==="ENFILE")?Pt([$,[j,D,N],P,M||Date.now(),Date.now()]):(F&&F.sort&&F.sort(),typeof N=="function"&&N.call(this,P,F))}}}if(process.version.substr(0,4)==="v0.8"){var g=P0(t);k=g.ReadStream,U=g.WriteStream}var m=t.ReadStream;m&&(k.prototype=Object.create(m.prototype),k.prototype.open=L);var _=t.WriteStream;_&&(U.prototype=Object.create(_.prototype),U.prototype.open=X),Object.defineProperty(t,"ReadStream",{get:function(){return k},set:function(b){k=b},enumerable:!0,configurable:!0}),Object.defineProperty(t,"WriteStream",{get:function(){return U},set:function(b){U=b},enumerable:!0,configurable:!0});var C=k;Object.defineProperty(t,"FileReadStream",{get:function(){return C},set:function(b){C=b},enumerable:!0,configurable:!0});var I=U;Object.defineProperty(t,"FileWriteStream",{get:function(){return I},set:function(b){I=b},enumerable:!0,configurable:!0});function k(b,w){return this instanceof k?(m.apply(this,arguments),this):k.apply(Object.create(k.prototype),arguments)}function L(){var b=this;Q(b.path,b.flags,b.mode,function(w,E){w?(b.autoClose&&b.destroy(),b.emit("error",w)):(b.fd=E,b.emit("open",E),b.read())})}function U(b,w){return this instanceof U?(_.apply(this,arguments),this):U.apply(Object.create(U.prototype),arguments)}function X(){var b=this;Q(b.path,b.flags,b.mode,function(w,E){w?(b.destroy(),b.emit("error",w)):(b.fd=E,b.emit("open",E))})}function z(b,w){return new t.ReadStream(b,w)}function re(b,w){return new t.WriteStream(b,w)}var ve=t.open;t.open=Q;function Q(b,w,E,$){return typeof E=="function"&&($=E,E=null),R(b,w,E,$);function R(j,D,N,M,P){return ve(j,D,N,function(F,De){F&&(F.code==="EMFILE"||F.code==="ENFILE")?Pt([R,[j,D,N,M],F,P||Date.now(),Date.now()]):typeof M=="function"&&M.apply(this,arguments)})}}return t}function Pt(t){ct("ENQUEUE",t[0].name,t[1]),W[oe].push(t),Mi()}var Kr;function $u(){for(var t=Date.now(),e=0;e<W[oe].length;++e)W[oe][e].length>2&&(W[oe][e][3]=t,W[oe][e][4]=t);Mi()}function Mi(){if(clearTimeout(Kr),Kr=void 0,W[oe].length!==0){var t=W[oe].shift(),e=t[0],r=t[1],n=t[2],i=t[3],s=t[4];if(i===void 0)ct("RETRY",e.name,r),e.apply(null,r);else if(Date.now()-i>=6e4){ct("TIMEOUT",e.name,r);var o=r.pop();typeof o=="function"&&o.call(null,n)}else{var a=Date.now()-s,u=Math.max(s-i,1),h=Math.min(u*1.2,100);a>=h?(ct("RETRY",e.name,r),e.apply(null,r.concat([i]))):W[oe].push(t)}Kr===void 0&&(Kr=setTimeout(Mi,0))}}});var Qt=y(Je=>{"use strict";var Uu=we().fromCallback,me=fe(),A0=["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(t=>typeof me[t]=="function");Object.keys(me).forEach(t=>{t!=="promises"&&(Je[t]=me[t])});A0.forEach(t=>{Je[t]=Uu(me[t])});Je.exists=function(t,e){return typeof e=="function"?me.exists(t,e):new Promise(r=>me.exists(t,r))};Je.read=function(t,e,r,n,i,s){return typeof s=="function"?me.read(t,e,r,n,i,s):new Promise((o,a)=>{me.read(t,e,r,n,i,(u,h,c)=>{if(u)return a(u);o({bytesRead:h,buffer:c})})})};Je.write=function(t,e,...r){return typeof r[r.length-1]=="function"?me.write(t,e,...r):new Promise((n,i)=>{me.write(t,e,...r,(s,o,a)=>{if(s)return i(s);n({bytesWritten:o,buffer:a})})})};typeof me.writev=="function"&&(Je.writev=function(t,e,...r){return typeof r[r.length-1]=="function"?me.writev(t,e,...r):new Promise((n,i)=>{me.writev(t,e,...r,(s,o,a)=>{if(s)return i(s);n({bytesWritten:o,buffers:a})})})});typeof me.realpath.native=="function"&&(Je.realpath.native=Uu(me.realpath.native))});var Ti=y((Xb,Xu)=>{Xu.exports=t=>{let e=process.versions.node.split(".").map(r=>parseInt(r,10));return t=t.split(".").map(r=>parseInt(r,10)),e[0]>t[0]||e[0]===t[0]&&(e[1]>t[1]||e[1]===t[1]&&e[2]>=t[2])}});var Ju=y((Hb,Ni)=>{"use strict";var Dt=Qt(),He=require("path"),I0=Ti(),Hu=I0("10.12.0"),Gu=t=>{if(process.platform==="win32"&&/[<>:"|?*]/.test(t.replace(He.parse(t).root,""))){let r=new Error(`Path contains invalid characters: ${t}`);throw r.code="EINVAL",r}},Wu=t=>{let e={mode:511};return typeof t=="number"&&(t={mode:t}),{...e,...t}},zu=t=>{let e=new Error(`operation not permitted, mkdir '${t}'`);return e.code="EPERM",e.errno=-4048,e.path=t,e.syscall="mkdir",e};Ni.exports.makeDir=async(t,e)=>{if(Gu(t),e=Wu(e),Hu){let n=He.resolve(t);return Dt.mkdir(n,{mode:e.mode,recursive:!0})}let r=async n=>{try{await Dt.mkdir(n,e.mode)}catch(i){if(i.code==="EPERM")throw i;if(i.code==="ENOENT"){if(He.dirname(n)===n)throw zu(n);if(i.message.includes("null bytes"))throw i;return await r(He.dirname(n)),r(n)}try{if(!(await Dt.stat(n)).isDirectory())throw new Error("The path is not a directory")}catch{throw i}}};return r(He.resolve(t))};Ni.exports.makeDirSync=(t,e)=>{if(Gu(t),e=Wu(e),Hu){let n=He.resolve(t);return Dt.mkdirSync(n,{mode:e.mode,recursive:!0})}let r=n=>{try{Dt.mkdirSync(n,e.mode)}catch(i){if(i.code==="EPERM")throw i;if(i.code==="ENOENT"){if(He.dirname(n)===n)throw zu(n);if(i.message.includes("null bytes"))throw i;return r(He.dirname(n)),r(n)}try{if(!Dt.statSync(n).isDirectory())throw new Error("The path is not a directory")}catch{throw i}}};return r(He.resolve(t))}});var Ne=y((Gb,Vu)=>{"use strict";var R0=we().fromPromise,{makeDir:F0,makeDirSync:ji}=Ju(),Li=R0(F0);Vu.exports={mkdirs:Li,mkdirsSync:ji,mkdirp:Li,mkdirpSync:ji,ensureDir:Li,ensureDirSync:ji}});var $i=y((Wb,Ku)=>{"use strict";var Ot=fe();function k0(t,e,r,n){Ot.open(t,"r+",(i,s)=>{if(i)return n(i);Ot.futimes(s,e,r,o=>{Ot.close(s,a=>{n&&n(o||a)})})})}function M0(t,e,r){let n=Ot.openSync(t,"r+");return Ot.futimesSync(n,e,r),Ot.closeSync(n)}Ku.exports={utimesMillis:k0,utimesMillisSync:M0}});var Zt=y((zb,ec)=>{"use strict";var At=Qt(),xe=require("path"),q0=require("util"),T0=Ti(),Qr=T0("10.5.0"),Yu=t=>Qr?At.stat(t,{bigint:!0}):At.stat(t),Bi=t=>Qr?At.statSync(t,{bigint:!0}):At.statSync(t);function N0(t,e){return Promise.all([Yu(t),Yu(e).catch(r=>{if(r.code==="ENOENT")return null;throw r})]).then(([r,n])=>({srcStat:r,destStat:n}))}function j0(t,e){let r,n=Bi(t);try{r=Bi(e)}catch(i){if(i.code==="ENOENT")return{srcStat:n,destStat:null};throw i}return{srcStat:n,destStat:r}}function L0(t,e,r,n){q0.callbackify(N0)(t,e,(i,s)=>{if(i)return n(i);let{srcStat:o,destStat:a}=s;return a&&Zr(o,a)?n(new Error("Source and destination must not be the same.")):o.isDirectory()&&Ui(t,e)?n(new Error(en(t,e,r))):n(null,{srcStat:o,destStat:a})})}function $0(t,e,r){let{srcStat:n,destStat:i}=j0(t,e);if(i&&Zr(n,i))throw new Error("Source and destination must not be the same.");if(n.isDirectory()&&Ui(t,e))throw new Error(en(t,e,r));return{srcStat:n,destStat:i}}function Qu(t,e,r,n,i){let s=xe.resolve(xe.dirname(t)),o=xe.resolve(xe.dirname(r));if(o===s||o===xe.parse(o).root)return i();let a=(u,h)=>u?u.code==="ENOENT"?i():i(u):Zr(e,h)?i(new Error(en(t,r,n))):Qu(t,e,o,n,i);Qr?At.stat(o,{bigint:!0},a):At.stat(o,a)}function Zu(t,e,r,n){let i=xe.resolve(xe.dirname(t)),s=xe.resolve(xe.dirname(r));if(s===i||s===xe.parse(s).root)return;let o;try{o=Bi(s)}catch(a){if(a.code==="ENOENT")return;throw a}if(Zr(e,o))throw new Error(en(t,r,n));return Zu(t,e,s,n)}function Zr(t,e){return!!(e.ino&&e.dev&&e.ino===t.ino&&e.dev===t.dev&&(Qr||e.ino<Number.MAX_SAFE_INTEGER||e.size===t.size&&e.mode===t.mode&&e.nlink===t.nlink&&e.atimeMs===t.atimeMs&&e.mtimeMs===t.mtimeMs&&e.ctimeMs===t.ctimeMs&&e.birthtimeMs===t.birthtimeMs))}function Ui(t,e){let r=xe.resolve(t).split(xe.sep).filter(i=>i),n=xe.resolve(e).split(xe.sep).filter(i=>i);return r.reduce((i,s,o)=>i&&n[o]===s,!0)}function en(t,e,r){return`Cannot ${r} '${t}' to a subdirectory of itself, '${e}'.`}ec.exports={checkPaths:L0,checkPathsSync:$0,checkParentPaths:Qu,checkParentPathsSync:Zu,isSrcSubdir:Ui}});var sc=y((Jb,ic)=>{"use strict";var de=fe(),er=require("path"),B0=Ne().mkdirsSync,U0=$i().utimesMillisSync,tr=Zt();function X0(t,e,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;
6
11
 
7
- see https://github.com/jprichardson/node-fs-extra/issues/269`);let{srcStat:n,destStat:i}=_t.checkPathsSync(e,t,"copy");return _t.checkParentPathsSync(e,n,t,"copy"),Mf(i,e,t,r)}function Mf(e,t,r,n){if(n.filter&&!n.filter(t,r))return;let i=wt.dirname(r);return ie.existsSync(i)||Af(i),Ns(e,t,r,n)}function Ns(e,t,r,n){if(!(n.filter&&!n.filter(t,r)))return Ff(e,t,r,n)}function Ff(e,t,r,n){let s=(n.dereference?ie.statSync:ie.lstatSync)(t);if(s.isDirectory())return Bf(s,e,t,r,n);if(s.isFile()||s.isCharacterDevice()||s.isBlockDevice())return Tf(s,e,t,r,n);if(s.isSymbolicLink())return Uf(e,t,r,n)}function Tf(e,t,r,n,i){return t?If(e,r,n,i):Ds(e,r,n,i)}function If(e,t,r,n){if(n.overwrite)return ie.unlinkSync(r),Ds(e,t,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function Ds(e,t,r,n){return ie.copyFileSync(t,r),n.preserveTimestamps&&Nf(e.mode,t,r),fn(r,e.mode)}function Nf(e,t,r){return Df(e)&&jf(r,e),$f(t,r)}function Df(e){return(e&128)===0}function jf(e,t){return fn(e,t|128)}function fn(e,t){return ie.chmodSync(e,t)}function $f(e,t){let r=ie.statSync(e);return Pf(t,r.atime,r.mtime)}function Bf(e,t,r,n,i){if(!t)return Lf(e.mode,r,n,i);if(t&&!t.isDirectory())throw new Error(`Cannot overwrite non-directory '${n}' with directory '${r}'.`);return js(r,n,i)}function Lf(e,t,r,n){return ie.mkdirSync(r),js(t,r,n),fn(r,e)}function js(e,t,r){ie.readdirSync(e).forEach(n=>Hf(n,e,t,r))}function Hf(e,t,r,n){let i=wt.join(t,e),s=wt.join(r,e),{destStat:o}=_t.checkPathsSync(i,s,"copy");return Ns(o,i,s,n)}function Uf(e,t,r,n){let i=ie.readlinkSync(t);if(n.dereference&&(i=wt.resolve(process.cwd(),i)),e){let s;try{s=ie.readlinkSync(r)}catch(o){if(o.code==="EINVAL"||o.code==="UNKNOWN")return ie.symlinkSync(i,r);throw o}if(n.dereference&&(s=wt.resolve(process.cwd(),s)),_t.isSrcSubdir(i,s))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${s}'.`);if(ie.statSync(r).isDirectory()&&_t.isSrcSubdir(s,i))throw new Error(`Cannot overwrite '${s}' with '${i}'.`);return Gf(i,r)}else return ie.symlinkSync(i,r)}function Gf(e,t){return ie.unlinkSync(t),ie.symlinkSync(e,t)}$s.exports=qf});var hn=v((m1,Ls)=>{"use strict";Ls.exports={copySync:Bs()}});var Me=v((y1,Us)=>{"use strict";var zf=fe().fromPromise,Hs=vt();function Wf(e){return Hs.access(e).then(()=>!0).catch(()=>!1)}Us.exports={pathExists:zf(Wf),pathExistsSync:Hs.existsSync}});var Qs=v((g1,Xs)=>{"use strict";var de=ne(),xt=require("path"),Jf=Se().mkdirs,Vf=Me().pathExists,Yf=cn().utimesMillis,Et=bt();function Kf(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;
12
+ see https://github.com/jprichardson/node-fs-extra/issues/269`);let{srcStat:n,destStat:i}=tr.checkPathsSync(t,e,"copy");return tr.checkParentPathsSync(t,n,e,"copy"),H0(i,t,e,r)}function H0(t,e,r,n){if(n.filter&&!n.filter(e,r))return;let i=er.dirname(r);return de.existsSync(i)||B0(i),tc(t,e,r,n)}function tc(t,e,r,n){if(!(n.filter&&!n.filter(e,r)))return G0(t,e,r,n)}function G0(t,e,r,n){let s=(n.dereference?de.statSync:de.lstatSync)(e);if(s.isDirectory())return Q0(s,t,e,r,n);if(s.isFile()||s.isCharacterDevice()||s.isBlockDevice())return W0(s,t,e,r,n);if(s.isSymbolicLink())return tm(t,e,r,n)}function W0(t,e,r,n,i){return e?z0(t,r,n,i):rc(t,r,n,i)}function z0(t,e,r,n){if(n.overwrite)return de.unlinkSync(r),rc(t,e,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function rc(t,e,r,n){return de.copyFileSync(e,r),n.preserveTimestamps&&J0(t.mode,e,r),Xi(r,t.mode)}function J0(t,e,r){return V0(t)&&K0(r,t),Y0(e,r)}function V0(t){return(t&128)===0}function K0(t,e){return Xi(t,e|128)}function Xi(t,e){return de.chmodSync(t,e)}function Y0(t,e){let r=de.statSync(t);return U0(e,r.atime,r.mtime)}function Q0(t,e,r,n,i){if(!e)return Z0(t.mode,r,n,i);if(e&&!e.isDirectory())throw new Error(`Cannot overwrite non-directory '${n}' with directory '${r}'.`);return nc(r,n,i)}function Z0(t,e,r,n){return de.mkdirSync(r),nc(e,r,n),Xi(r,t)}function nc(t,e,r){de.readdirSync(t).forEach(n=>em(n,t,e,r))}function em(t,e,r,n){let i=er.join(e,t),s=er.join(r,t),{destStat:o}=tr.checkPathsSync(i,s,"copy");return tc(o,i,s,n)}function tm(t,e,r,n){let i=de.readlinkSync(e);if(n.dereference&&(i=er.resolve(process.cwd(),i)),t){let s;try{s=de.readlinkSync(r)}catch(o){if(o.code==="EINVAL"||o.code==="UNKNOWN")return de.symlinkSync(i,r);throw o}if(n.dereference&&(s=er.resolve(process.cwd(),s)),tr.isSrcSubdir(i,s))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${s}'.`);if(de.statSync(r).isDirectory()&&tr.isSrcSubdir(s,i))throw new Error(`Cannot overwrite '${s}' with '${i}'.`);return rm(i,r)}else return de.symlinkSync(i,r)}function rm(t,e){return de.unlinkSync(e),de.symlinkSync(t,e)}ic.exports=X0});var Hi=y((Vb,oc)=>{"use strict";oc.exports={copySync:sc()}});var Ve=y((Kb,uc)=>{"use strict";var nm=we().fromPromise,ac=Qt();function im(t){return ac.access(t).then(()=>!0).catch(()=>!1)}uc.exports={pathExists:nm(im),pathExistsSync:ac.existsSync}});var yc=y((Yb,gc)=>{"use strict";var Se=fe(),rr=require("path"),sm=Ne().mkdirs,om=Ve().pathExists,am=$i().utimesMillis,nr=Zt();function um(t,e,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;
8
13
 
9
- see https://github.com/jprichardson/node-fs-extra/issues/269`),Et.checkPaths(e,t,"copy",(i,s)=>{if(i)return n(i);let{srcStat:o,destStat:a}=s;Et.checkParentPaths(e,o,t,"copy",c=>c?n(c):r.filter?Js(Gs,a,e,t,r,n):Gs(a,e,t,r,n))})}function Gs(e,t,r,n,i){let s=xt.dirname(r);Vf(s,(o,a)=>{if(o)return i(o);if(a)return dn(e,t,r,n,i);Jf(s,c=>c?i(c):dn(e,t,r,n,i))})}function Js(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 dn(e,t,r,n,i){return n.filter?Js(zs,e,t,r,n,i):zs(e,t,r,n,i)}function zs(e,t,r,n,i){(n.dereference?de.stat:de.lstat)(t,(o,a)=>{if(o)return i(o);if(a.isDirectory())return nh(a,e,t,r,n,i);if(a.isFile()||a.isCharacterDevice()||a.isBlockDevice())return Xf(a,e,t,r,n,i);if(a.isSymbolicLink())return oh(e,t,r,n,i)})}function Xf(e,t,r,n,i,s){return t?Qf(e,r,n,i,s):Vs(e,r,n,i,s)}function Qf(e,t,r,n,i){if(n.overwrite)de.unlink(r,s=>s?i(s):Vs(e,t,r,n,i));else return n.errorOnExist?i(new Error(`'${r}' already exists`)):i()}function Vs(e,t,r,n,i){de.copyFile(t,r,s=>s?i(s):n.preserveTimestamps?Zf(e.mode,t,r,i):tr(r,e.mode,i))}function Zf(e,t,r,n){return eh(e)?th(r,e,i=>i?n(i):Ws(e,t,r,n)):Ws(e,t,r,n)}function eh(e){return(e&128)===0}function th(e,t,r){return tr(e,t|128,r)}function Ws(e,t,r,n){rh(t,r,i=>i?n(i):tr(r,e,n))}function tr(e,t,r){return de.chmod(e,t,r)}function rh(e,t,r){de.stat(e,(n,i)=>n?r(n):Yf(t,i.atime,i.mtime,r))}function nh(e,t,r,n,i,s){return t?t&&!t.isDirectory()?s(new Error(`Cannot overwrite non-directory '${n}' with directory '${r}'.`)):Ys(r,n,i,s):ih(e.mode,r,n,i,s)}function ih(e,t,r,n,i){de.mkdir(r,s=>{if(s)return i(s);Ys(t,r,n,o=>o?i(o):tr(r,e,i))})}function Ys(e,t,r,n){de.readdir(e,(i,s)=>i?n(i):Ks(s,e,t,r,n))}function Ks(e,t,r,n,i){let s=e.pop();return s?sh(e,s,t,r,n,i):i()}function sh(e,t,r,n,i,s){let o=xt.join(r,t),a=xt.join(n,t);Et.checkPaths(o,a,"copy",(c,d)=>{if(c)return s(c);let{destStat:f}=d;dn(f,o,a,i,p=>p?s(p):Ks(e,r,n,i,s))})}function oh(e,t,r,n,i){de.readlink(t,(s,o)=>{if(s)return i(s);if(n.dereference&&(o=xt.resolve(process.cwd(),o)),e)de.readlink(r,(a,c)=>a?a.code==="EINVAL"||a.code==="UNKNOWN"?de.symlink(o,r,i):i(a):(n.dereference&&(c=xt.resolve(process.cwd(),c)),Et.isSrcSubdir(o,c)?i(new Error(`Cannot copy '${o}' to a subdirectory of itself, '${c}'.`)):e.isDirectory()&&Et.isSrcSubdir(c,o)?i(new Error(`Cannot overwrite '${c}' with '${o}'.`)):ah(o,r,i)));else return de.symlink(o,r,i)})}function ah(e,t,r){de.unlink(t,n=>n?r(n):de.symlink(e,t,r))}Xs.exports=Kf});var pn=v((v1,Zs)=>{"use strict";var ch=fe().fromCallback;Zs.exports={copy:ch(Qs())}});var co=v((b1,ao)=>{"use strict";var eo=ne(),io=require("path"),L=require("assert"),St=process.platform==="win32";function so(e){["unlink","chmod","stat","lstat","rmdir","readdir"].forEach(r=>{e[r]=e[r]||eo[r],r=r+"Sync",e[r]=e[r]||eo[r]}),e.maxBusyTries=e.maxBusyTries||3}function mn(e,t,r){let n=0;typeof t=="function"&&(r=t,t={}),L(e,"rimraf: missing path"),L.strictEqual(typeof e,"string","rimraf: path should be a string"),L.strictEqual(typeof r,"function","rimraf: callback function required"),L(t,"rimraf: invalid options argument provided"),L.strictEqual(typeof t,"object","rimraf: options should be object"),so(t),to(e,t,function i(s){if(s){if((s.code==="EBUSY"||s.code==="ENOTEMPTY"||s.code==="EPERM")&&n<t.maxBusyTries){n++;let o=n*100;return setTimeout(()=>to(e,t,i),o)}s.code==="ENOENT"&&(s=null)}r(s)})}function to(e,t,r){L(e),L(t),L(typeof r=="function"),t.lstat(e,(n,i)=>{if(n&&n.code==="ENOENT")return r(null);if(n&&n.code==="EPERM"&&St)return ro(e,t,n,r);if(i&&i.isDirectory())return rr(e,t,n,r);t.unlink(e,s=>{if(s){if(s.code==="ENOENT")return r(null);if(s.code==="EPERM")return St?ro(e,t,s,r):rr(e,t,s,r);if(s.code==="EISDIR")return rr(e,t,s,r)}return r(s)})})}function ro(e,t,r,n){L(e),L(t),L(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()?rr(e,t,r,n):t.unlink(e,n)})})}function no(e,t,r){let n;L(e),L(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()?nr(e,t,r):t.unlinkSync(e)}function rr(e,t,r,n){L(e),L(t),L(typeof n=="function"),t.rmdir(e,i=>{i&&(i.code==="ENOTEMPTY"||i.code==="EEXIST"||i.code==="EPERM")?uh(e,t,n):i&&i.code==="ENOTDIR"?n(r):n(i)})}function uh(e,t,r){L(e),L(t),L(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(a=>{mn(io.join(e,a),t,c=>{if(!o){if(c)return r(o=c);--s===0&&t.rmdir(e,r)}})})})}function oo(e,t){let r;t=t||{},so(t),L(e,"rimraf: missing path"),L.strictEqual(typeof e,"string","rimraf: path should be a string"),L(t,"rimraf: missing options"),L.strictEqual(typeof t,"object","rimraf: options should be object");try{r=t.lstatSync(e)}catch(n){if(n.code==="ENOENT")return;n.code==="EPERM"&&St&&no(e,t,n)}try{r&&r.isDirectory()?nr(e,t,null):t.unlinkSync(e)}catch(n){if(n.code==="ENOENT")return;if(n.code==="EPERM")return St?no(e,t,n):nr(e,t,n);if(n.code!=="EISDIR")throw n;nr(e,t,n)}}function nr(e,t,r){L(e),L(t);try{t.rmdirSync(e)}catch(n){if(n.code==="ENOTDIR")throw r;if(n.code==="ENOTEMPTY"||n.code==="EEXIST"||n.code==="EPERM")lh(e,t);else if(n.code!=="ENOENT")throw n}}function lh(e,t){if(L(e),L(t),t.readdirSync(e).forEach(r=>oo(io.join(e,r),t)),St){let r=Date.now();do try{return t.rmdirSync(e,t)}catch{}while(Date.now()-r<500)}else return t.rmdirSync(e,t)}ao.exports=mn;mn.sync=oo});var kt=v((w1,lo)=>{"use strict";var fh=fe().fromCallback,uo=co();lo.exports={remove:fh(uo),removeSync:uo.sync}});var bo=v((_1,vo)=>{"use strict";var hh=fe().fromCallback,po=ne(),mo=require("path"),yo=Se(),go=kt(),fo=hh(function(t,r){r=r||function(){},po.readdir(t,(n,i)=>{if(n)return yo.mkdirs(t,r);i=i.map(o=>mo.join(t,o)),s();function s(){let o=i.pop();if(!o)return r();go.remove(o,a=>{if(a)return r(a);s()})}})});function ho(e){let t;try{t=po.readdirSync(e)}catch{return yo.mkdirsSync(e)}t.forEach(r=>{r=mo.join(e,r),go.removeSync(r)})}vo.exports={emptyDirSync:ho,emptydirSync:ho,emptyDir:fo,emptydir:fo}});var Eo=v((x1,xo)=>{"use strict";var dh=fe().fromCallback,wo=require("path"),Fe=ne(),_o=Se();function ph(e,t){function r(){Fe.writeFile(e,"",n=>{if(n)return t(n);t()})}Fe.stat(e,(n,i)=>{if(!n&&i.isFile())return t();let s=wo.dirname(e);Fe.stat(s,(o,a)=>{if(o)return o.code==="ENOENT"?_o.mkdirs(s,c=>{if(c)return t(c);r()}):t(o);a.isDirectory()?r():Fe.readdir(s,c=>{if(c)return t(c)})})})}function mh(e){let t;try{t=Fe.statSync(e)}catch{}if(t&&t.isFile())return;let r=wo.dirname(e);try{Fe.statSync(r).isDirectory()||Fe.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")_o.mkdirsSync(r);else throw n}Fe.writeFileSync(e,"")}xo.exports={createFile:dh(ph),createFileSync:mh}});var Oo=v((E1,Ro)=>{"use strict";var yh=fe().fromCallback,ko=require("path"),Le=ne(),Co=Se(),So=Me().pathExists;function gh(e,t,r){function n(i,s){Le.link(i,s,o=>{if(o)return r(o);r(null)})}So(t,(i,s)=>{if(i)return r(i);if(s)return r(null);Le.lstat(e,o=>{if(o)return o.message=o.message.replace("lstat","ensureLink"),r(o);let a=ko.dirname(t);So(a,(c,d)=>{if(c)return r(c);if(d)return n(e,t);Co.mkdirs(a,f=>{if(f)return r(f);n(e,t)})})})})}function vh(e,t){if(Le.existsSync(t))return;try{Le.lstatSync(e)}catch(s){throw s.message=s.message.replace("lstat","ensureLink"),s}let n=ko.dirname(t);return Le.existsSync(n)||Co.mkdirsSync(n),Le.linkSync(e,t)}Ro.exports={createLink:yh(gh),createLinkSync:vh}});var Po=v((S1,Ao)=>{"use strict";var Te=require("path"),Ct=ne(),bh=Me().pathExists;function wh(e,t,r){if(Te.isAbsolute(e))return Ct.lstat(e,n=>n?(n.message=n.message.replace("lstat","ensureSymlink"),r(n)):r(null,{toCwd:e,toDst:e}));{let n=Te.dirname(t),i=Te.join(n,e);return bh(i,(s,o)=>s?r(s):o?r(null,{toCwd:i,toDst:e}):Ct.lstat(e,a=>a?(a.message=a.message.replace("lstat","ensureSymlink"),r(a)):r(null,{toCwd:e,toDst:Te.relative(n,e)})))}}function _h(e,t){let r;if(Te.isAbsolute(e)){if(r=Ct.existsSync(e),!r)throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}else{let n=Te.dirname(t),i=Te.join(n,e);if(r=Ct.existsSync(i),r)return{toCwd:i,toDst:e};if(r=Ct.existsSync(e),!r)throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:Te.relative(n,e)}}}Ao.exports={symlinkPaths:wh,symlinkPathsSync:_h}});var Fo=v((k1,Mo)=>{"use strict";var qo=ne();function xh(e,t,r){if(r=typeof t=="function"?t:r,t=typeof t=="function"?!1:t,t)return r(null,t);qo.lstat(e,(n,i)=>{if(n)return r(null,"file");t=i&&i.isDirectory()?"dir":"file",r(null,t)})}function Eh(e,t){let r;if(t)return t;try{r=qo.lstatSync(e)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}Mo.exports={symlinkType:xh,symlinkTypeSync:Eh}});var Bo=v((C1,$o)=>{"use strict";var Sh=fe().fromCallback,Io=require("path"),tt=ne(),No=Se(),kh=No.mkdirs,Ch=No.mkdirsSync,Do=Po(),Rh=Do.symlinkPaths,Oh=Do.symlinkPathsSync,jo=Fo(),Ah=jo.symlinkType,Ph=jo.symlinkTypeSync,To=Me().pathExists;function qh(e,t,r,n){n=typeof r=="function"?r:n,r=typeof r=="function"?!1:r,To(t,(i,s)=>{if(i)return n(i);if(s)return n(null);Rh(e,t,(o,a)=>{if(o)return n(o);e=a.toDst,Ah(a.toCwd,r,(c,d)=>{if(c)return n(c);let f=Io.dirname(t);To(f,(p,y)=>{if(p)return n(p);if(y)return tt.symlink(e,t,d,n);kh(f,m=>{if(m)return n(m);tt.symlink(e,t,d,n)})})})})})}function Mh(e,t,r){if(tt.existsSync(t))return;let i=Oh(e,t);e=i.toDst,r=Ph(i.toCwd,r);let s=Io.dirname(t);return tt.existsSync(s)||Ch(s),tt.symlinkSync(e,t,r)}$o.exports={createSymlink:Sh(qh),createSymlinkSync:Mh}});var Ho=v((R1,Lo)=>{"use strict";var ir=Eo(),sr=Oo(),or=Bo();Lo.exports={createFile:ir.createFile,createFileSync:ir.createFileSync,ensureFile:ir.createFile,ensureFileSync:ir.createFileSync,createLink:sr.createLink,createLinkSync:sr.createLinkSync,ensureLink:sr.createLink,ensureLinkSync:sr.createLinkSync,createSymlink:or.createSymlink,createSymlinkSync:or.createSymlinkSync,ensureSymlink:or.createSymlink,ensureSymlinkSync:or.createSymlinkSync}});var ar=v((O1,Uo)=>{function Fh(e,{EOL:t=`
10
- `,finalEOL:r=!0,replacer:n=null,spaces:i}={}){let s=r?t:"";return JSON.stringify(e,n,i).replace(/\n/g,t)+s}function Th(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}Uo.exports={stringify:Fh,stripBom:Th}});var Jo=v((A1,Wo)=>{var rt;try{rt=ne()}catch{rt=require("fs")}var cr=fe(),{stringify:Go,stripBom:zo}=ar();async function Ih(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||rt,n="throws"in t?t.throws:!0,i=await cr.fromCallback(r.readFile)(e,t);i=zo(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}var Nh=cr.fromPromise(Ih);function Dh(e,t={}){typeof t=="string"&&(t={encoding:t});let r=t.fs||rt,n="throws"in t?t.throws:!0;try{let i=r.readFileSync(e,t);return i=zo(i),JSON.parse(i,t.reviver)}catch(i){if(n)throw i.message=`${e}: ${i.message}`,i;return null}}async function jh(e,t,r={}){let n=r.fs||rt,i=Go(t,r);await cr.fromCallback(n.writeFile)(e,i,r)}var $h=cr.fromPromise(jh);function Bh(e,t,r={}){let n=r.fs||rt,i=Go(t,r);return n.writeFileSync(e,i,r)}var Lh={readFile:Nh,readFileSync:Dh,writeFile:$h,writeFileSync:Bh};Wo.exports=Lh});var Yo=v((P1,Vo)=>{"use strict";var ur=Jo();Vo.exports={readJson:ur.readFile,readJsonSync:ur.readFileSync,writeJson:ur.writeFile,writeJsonSync:ur.writeFileSync}});var lr=v((q1,Qo)=>{"use strict";var Hh=fe().fromCallback,Rt=ne(),Ko=require("path"),Xo=Se(),Uh=Me().pathExists;function Gh(e,t,r,n){typeof r=="function"&&(n=r,r="utf8");let i=Ko.dirname(e);Uh(i,(s,o)=>{if(s)return n(s);if(o)return Rt.writeFile(e,t,r,n);Xo.mkdirs(i,a=>{if(a)return n(a);Rt.writeFile(e,t,r,n)})})}function zh(e,...t){let r=Ko.dirname(e);if(Rt.existsSync(r))return Rt.writeFileSync(e,...t);Xo.mkdirsSync(r),Rt.writeFileSync(e,...t)}Qo.exports={outputFile:Hh(Gh),outputFileSync:zh}});var ea=v((M1,Zo)=>{"use strict";var{stringify:Wh}=ar(),{outputFile:Jh}=lr();async function Vh(e,t,r={}){let n=Wh(t,r);await Jh(e,n,r)}Zo.exports=Vh});var ra=v((F1,ta)=>{"use strict";var{stringify:Yh}=ar(),{outputFileSync:Kh}=lr();function Xh(e,t,r){let n=Yh(t,r);Kh(e,n,r)}ta.exports=Xh});var ia=v((T1,na)=>{"use strict";var Qh=fe().fromPromise,ce=Yo();ce.outputJson=Qh(ea());ce.outputJsonSync=ra();ce.outputJSON=ce.outputJson;ce.outputJSONSync=ce.outputJsonSync;ce.writeJSON=ce.writeJson;ce.writeJSONSync=ce.writeJsonSync;ce.readJSON=ce.readJson;ce.readJSONSync=ce.readJsonSync;na.exports=ce});var la=v((I1,ua)=>{"use strict";var aa=ne(),Zh=require("path"),e0=hn().copySync,ca=kt().removeSync,t0=Se().mkdirpSync,sa=bt();function r0(e,t,r){r=r||{};let n=r.overwrite||r.clobber||!1,{srcStat:i}=sa.checkPathsSync(e,t,"move");return sa.checkParentPathsSync(e,i,t,"move"),t0(Zh.dirname(t)),n0(e,t,n)}function n0(e,t,r){if(r)return ca(t),oa(e,t,r);if(aa.existsSync(t))throw new Error("dest already exists.");return oa(e,t,r)}function oa(e,t,r){try{aa.renameSync(e,t)}catch(n){if(n.code!=="EXDEV")throw n;return i0(e,t,r)}}function i0(e,t,r){return e0(e,t,{overwrite:r,errorOnExist:!0}),ca(e)}ua.exports=r0});var ha=v((N1,fa)=>{"use strict";fa.exports={moveSync:la()}});var ga=v((D1,ya)=>{"use strict";var s0=ne(),o0=require("path"),a0=pn().copy,ma=kt().remove,c0=Se().mkdirp,u0=Me().pathExists,da=bt();function l0(e,t,r,n){typeof r=="function"&&(n=r,r={});let i=r.overwrite||r.clobber||!1;da.checkPaths(e,t,"move",(s,o)=>{if(s)return n(s);let{srcStat:a}=o;da.checkParentPaths(e,a,t,"move",c=>{if(c)return n(c);c0(o0.dirname(t),d=>d?n(d):f0(e,t,i,n))})})}function f0(e,t,r,n){if(r)return ma(t,i=>i?n(i):pa(e,t,r,n));u0(t,(i,s)=>i?n(i):s?n(new Error("dest already exists.")):pa(e,t,r,n))}function pa(e,t,r,n){s0.rename(e,t,i=>i?i.code!=="EXDEV"?n(i):h0(e,t,r,n):n())}function h0(e,t,r,n){a0(e,t,{overwrite:r,errorOnExist:!0},s=>s?n(s):ma(e,n))}ya.exports=l0});var ba=v((j1,va)=>{"use strict";var d0=fe().fromCallback;va.exports={move:d0(ga())}});var gn=v(($1,yn)=>{"use strict";yn.exports={...vt(),...hn(),...pn(),...bo(),...Ho(),...ia(),...Se(),...ha(),...ba(),...lr(),...Me(),...kt()};var wa=require("fs");Object.getOwnPropertyDescriptor(wa,"promises")&&Object.defineProperty(yn.exports,"promises",{get(){return wa.promises}})});var bn=v((H1,Ra)=>{"use strict";Ra.exports=function(t,r){return function(){for(var i=new Array(arguments.length),s=0;s<i.length;s++)i[s]=arguments[s];return t.apply(r,i)}}});var ue=v((U1,Pa)=>{"use strict";var p0=bn(),He=Object.prototype.toString;function xn(e){return He.call(e)==="[object Array]"}function wn(e){return typeof e>"u"}function m0(e){return e!==null&&!wn(e)&&e.constructor!==null&&!wn(e.constructor)&&typeof e.constructor.isBuffer=="function"&&e.constructor.isBuffer(e)}function y0(e){return He.call(e)==="[object ArrayBuffer]"}function g0(e){return typeof FormData<"u"&&e instanceof FormData}function v0(e){var t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&e.buffer instanceof ArrayBuffer,t}function b0(e){return typeof e=="string"}function w0(e){return typeof e=="number"}function Oa(e){return e!==null&&typeof e=="object"}function hr(e){if(He.call(e)!=="[object Object]")return!1;var t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function _0(e){return He.call(e)==="[object Date]"}function x0(e){return He.call(e)==="[object File]"}function E0(e){return He.call(e)==="[object Blob]"}function Aa(e){return He.call(e)==="[object Function]"}function S0(e){return Oa(e)&&Aa(e.pipe)}function k0(e){return typeof URLSearchParams<"u"&&e instanceof URLSearchParams}function C0(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function R0(){return typeof navigator<"u"&&(navigator.product==="ReactNative"||navigator.product==="NativeScript"||navigator.product==="NS")?!1:typeof window<"u"&&typeof document<"u"}function En(e,t){if(!(e===null||typeof e>"u"))if(typeof e!="object"&&(e=[e]),xn(e))for(var r=0,n=e.length;r<n;r++)t.call(null,e[r],r,e);else for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.call(null,e[i],i,e)}function _n(){var e={};function t(i,s){hr(e[s])&&hr(i)?e[s]=_n(e[s],i):hr(i)?e[s]=_n({},i):xn(i)?e[s]=i.slice():e[s]=i}for(var r=0,n=arguments.length;r<n;r++)En(arguments[r],t);return e}function O0(e,t,r){return En(t,function(i,s){r&&typeof i=="function"?e[s]=p0(i,r):e[s]=i}),e}function A0(e){return e.charCodeAt(0)===65279&&(e=e.slice(1)),e}Pa.exports={isArray:xn,isArrayBuffer:y0,isBuffer:m0,isFormData:g0,isArrayBufferView:v0,isString:b0,isNumber:w0,isObject:Oa,isPlainObject:hr,isUndefined:wn,isDate:_0,isFile:x0,isBlob:E0,isFunction:Aa,isStream:S0,isURLSearchParams:k0,isStandardBrowserEnv:R0,forEach:En,merge:_n,extend:O0,trim:C0,stripBOM:A0}});var dr=v((G1,Ma)=>{"use strict";var it=ue();function qa(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}Ma.exports=function(t,r,n){if(!r)return t;var i;if(n)i=n(r);else if(it.isURLSearchParams(r))i=r.toString();else{var s=[];it.forEach(r,function(c,d){c===null||typeof c>"u"||(it.isArray(c)?d=d+"[]":c=[c],it.forEach(c,function(p){it.isDate(p)?p=p.toISOString():it.isObject(p)&&(p=JSON.stringify(p)),s.push(qa(d)+"="+qa(p))}))}),i=s.join("&")}if(i){var o=t.indexOf("#");o!==-1&&(t=t.slice(0,o)),t+=(t.indexOf("?")===-1?"?":"&")+i}return t}});var Ta=v((z1,Fa)=>{"use strict";var P0=ue();function pr(){this.handlers=[]}pr.prototype.use=function(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1};pr.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)};pr.prototype.forEach=function(t){P0.forEach(this.handlers,function(n){n!==null&&t(n)})};Fa.exports=pr});var Na=v((W1,Ia)=>{"use strict";var q0=ue();Ia.exports=function(t,r){q0.forEach(t,function(i,s){s!==r&&s.toUpperCase()===r.toUpperCase()&&(t[r]=i,delete t[s])})}});var mr=v((J1,Da)=>{"use strict";Da.exports=function(t,r,n,i,s){return t.config=r,n&&(t.code=n),t.request=i,t.response=s,t.isAxiosError=!0,t.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},t}});var yr=v((V1,ja)=>{"use strict";var M0=mr();ja.exports=function(t,r,n,i,s){var o=new Error(t);return M0(o,r,n,i,s)}});var Sn=v((Y1,$a)=>{"use strict";var F0=yr();$a.exports=function(t,r,n){var i=n.config.validateStatus;!n.status||!i||i(n.status)?t(n):r(F0("Request failed with status code "+n.status,n.config,null,n.request,n))}});var La=v((K1,Ba)=>{"use strict";var gr=ue();Ba.exports=gr.isStandardBrowserEnv()?function(){return{write:function(r,n,i,s,o,a){var c=[];c.push(r+"="+encodeURIComponent(n)),gr.isNumber(i)&&c.push("expires="+new Date(i).toGMTString()),gr.isString(s)&&c.push("path="+s),gr.isString(o)&&c.push("domain="+o),a===!0&&c.push("secure"),document.cookie=c.join("; ")},read:function(r){var n=document.cookie.match(new RegExp("(^|;\\s*)("+r+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(r){this.write(r,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()});var Ua=v((X1,Ha)=>{"use strict";Ha.exports=function(t){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(t)}});var za=v((Q1,Ga)=>{"use strict";Ga.exports=function(t,r){return r?t.replace(/\/+$/,"")+"/"+r.replace(/^\/+/,""):t}});var kn=v((Z1,Wa)=>{"use strict";var T0=Ua(),I0=za();Wa.exports=function(t,r){return t&&!T0(r)?I0(t,r):r}});var Va=v((em,Ja)=>{"use strict";var Cn=ue(),N0=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];Ja.exports=function(t){var r={},n,i,s;return t&&Cn.forEach(t.split(`
11
- `),function(a){if(s=a.indexOf(":"),n=Cn.trim(a.substr(0,s)).toLowerCase(),i=Cn.trim(a.substr(s+1)),n){if(r[n]&&N0.indexOf(n)>=0)return;n==="set-cookie"?r[n]=(r[n]?r[n]:[]).concat([i]):r[n]=r[n]?r[n]+", "+i:i}}),r}});var Xa=v((tm,Ka)=>{"use strict";var Ya=ue();Ka.exports=Ya.isStandardBrowserEnv()?function(){var t=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a"),n;function i(s){var o=s;return t&&(r.setAttribute("href",o),o=r.href),r.setAttribute("href",o),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}return n=i(window.location.href),function(o){var a=Ya.isString(o)?i(o):o;return a.protocol===n.protocol&&a.host===n.host}}():function(){return function(){return!0}}()});var Za=v((rm,Qa)=>{"use strict";var vr=ue(),D0=Sn(),j0=La(),$0=dr(),B0=kn(),L0=Va(),H0=Xa(),Rn=yr();Qa.exports=function(t){return new Promise(function(n,i){var s=t.data,o=t.headers,a=t.responseType;vr.isFormData(s)&&delete o["Content-Type"];var c=new XMLHttpRequest;if(t.auth){var d=t.auth.username||"",f=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";o.Authorization="Basic "+btoa(d+":"+f)}var p=B0(t.baseURL,t.url);c.open(t.method.toUpperCase(),$0(p,t.params,t.paramsSerializer),!0),c.timeout=t.timeout;function y(){if(c){var _="getAllResponseHeaders"in c?L0(c.getAllResponseHeaders()):null,A=!a||a==="text"||a==="json"?c.responseText:c.response,P={data:A,status:c.status,statusText:c.statusText,headers:_,config:t,request:c};D0(n,i,P),c=null}}if("onloadend"in c?c.onloadend=y:c.onreadystatechange=function(){!c||c.readyState!==4||c.status===0&&!(c.responseURL&&c.responseURL.indexOf("file:")===0)||setTimeout(y)},c.onabort=function(){c&&(i(Rn("Request aborted",t,"ECONNABORTED",c)),c=null)},c.onerror=function(){i(Rn("Network Error",t,null,c)),c=null},c.ontimeout=function(){var A="timeout of "+t.timeout+"ms exceeded";t.timeoutErrorMessage&&(A=t.timeoutErrorMessage),i(Rn(A,t,t.transitional&&t.transitional.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",c)),c=null},vr.isStandardBrowserEnv()){var m=(t.withCredentials||H0(p))&&t.xsrfCookieName?j0.read(t.xsrfCookieName):void 0;m&&(o[t.xsrfHeaderName]=m)}"setRequestHeader"in c&&vr.forEach(o,function(A,P){typeof s>"u"&&P.toLowerCase()==="content-type"?delete o[P]:c.setRequestHeader(P,A)}),vr.isUndefined(t.withCredentials)||(c.withCredentials=!!t.withCredentials),a&&a!=="json"&&(c.responseType=t.responseType),typeof t.onDownloadProgress=="function"&&c.addEventListener("progress",t.onDownloadProgress),typeof t.onUploadProgress=="function"&&c.upload&&c.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then(function(A){c&&(c.abort(),i(A),c=null)}),s||(s=null),c.send(s)})}});var tc=v((nm,ec)=>{var st=1e3,ot=st*60,at=ot*60,Ue=at*24,U0=Ue*7,G0=Ue*365.25;ec.exports=function(e,t){t=t||{};var r=typeof e;if(r==="string"&&e.length>0)return z0(e);if(r==="number"&&isFinite(e))return t.long?J0(e):W0(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function z0(e){if(e=String(e),!(e.length>100)){var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(t){var r=parseFloat(t[1]),n=(t[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*G0;case"weeks":case"week":case"w":return r*U0;case"days":case"day":case"d":return r*Ue;case"hours":case"hour":case"hrs":case"hr":case"h":return r*at;case"minutes":case"minute":case"mins":case"min":case"m":return r*ot;case"seconds":case"second":case"secs":case"sec":case"s":return r*st;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function W0(e){var t=Math.abs(e);return t>=Ue?Math.round(e/Ue)+"d":t>=at?Math.round(e/at)+"h":t>=ot?Math.round(e/ot)+"m":t>=st?Math.round(e/st)+"s":e+"ms"}function J0(e){var t=Math.abs(e);return t>=Ue?br(e,t,Ue,"day"):t>=at?br(e,t,at,"hour"):t>=ot?br(e,t,ot,"minute"):t>=st?br(e,t,st,"second"):e+" ms"}function br(e,t,r,n){var i=t>=r*1.5;return Math.round(e/r)+" "+n+(i?"s":"")}});var On=v((im,rc)=>{function V0(e){r.debug=r,r.default=r,r.coerce=c,r.disable=s,r.enable=i,r.enabled=o,r.humanize=tc(),r.destroy=d,Object.keys(e).forEach(f=>{r[f]=e[f]}),r.names=[],r.skips=[],r.formatters={};function t(f){let p=0;for(let y=0;y<f.length;y++)p=(p<<5)-p+f.charCodeAt(y),p|=0;return r.colors[Math.abs(p)%r.colors.length]}r.selectColor=t;function r(f){let p,y=null,m,_;function A(...P){if(!A.enabled)return;let N=A,U=Number(new Date),W=U-(p||U);N.diff=W,N.prev=p,N.curr=U,p=U,P[0]=r.coerce(P[0]),typeof P[0]!="string"&&P.unshift("%O");let x=0;P[0]=P[0].replace(/%([a-zA-Z%])/g,(M,ye)=>{if(M==="%%")return"%";x++;let Q=r.formatters[ye];if(typeof Q=="function"){let R=P[x];M=Q.call(N,R),P.splice(x,1),x--}return M}),r.formatArgs.call(N,P),(N.log||r.log).apply(N,P)}return A.namespace=f,A.useColors=r.useColors(),A.color=r.selectColor(f),A.extend=n,A.destroy=r.destroy,Object.defineProperty(A,"enabled",{enumerable:!0,configurable:!1,get:()=>y!==null?y:(m!==r.namespaces&&(m=r.namespaces,_=r.enabled(f)),_),set:P=>{y=P}}),typeof r.init=="function"&&r.init(A),A}function n(f,p){let y=r(this.namespace+(typeof p>"u"?":":p)+f);return y.log=this.log,y}function i(f){r.save(f),r.namespaces=f,r.names=[],r.skips=[];let p,y=(typeof f=="string"?f:"").split(/[\s,]+/),m=y.length;for(p=0;p<m;p++)y[p]&&(f=y[p].replace(/\*/g,".*?"),f[0]==="-"?r.skips.push(new RegExp("^"+f.slice(1)+"$")):r.names.push(new RegExp("^"+f+"$")))}function s(){let f=[...r.names.map(a),...r.skips.map(a).map(p=>"-"+p)].join(",");return r.enable(""),f}function o(f){if(f[f.length-1]==="*")return!0;let p,y;for(p=0,y=r.skips.length;p<y;p++)if(r.skips[p].test(f))return!1;for(p=0,y=r.names.length;p<y;p++)if(r.names[p].test(f))return!0;return!1}function a(f){return f.toString().substring(2,f.toString().length-2).replace(/\.\*\?$/,"*")}function c(f){return f instanceof Error?f.stack||f.message:f}function d(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}rc.exports=V0});var nc=v((pe,wr)=>{pe.formatArgs=K0;pe.save=X0;pe.load=Q0;pe.useColors=Y0;pe.storage=Z0();pe.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})();pe.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function Y0(){return typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)?!0:typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function K0(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+wr.exports.humanize(this.diff),!this.useColors)return;let t="color: "+this.color;e.splice(1,0,t,"color: inherit");let r=0,n=0;e[0].replace(/%[a-zA-Z%]/g,i=>{i!=="%%"&&(r++,i==="%c"&&(n=r))}),e.splice(n,0,t)}pe.log=console.debug||console.log||(()=>{});function X0(e){try{e?pe.storage.setItem("debug",e):pe.storage.removeItem("debug")}catch{}}function Q0(){let e;try{e=pe.storage.getItem("debug")}catch{}return!e&&typeof process<"u"&&"env"in process&&(e=process.env.DEBUG),e}function Z0(){try{return localStorage}catch{}}wr.exports=On()(pe);var{formatters:ed}=wr.exports;ed.j=function(e){try{return JSON.stringify(e)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}}});var sc=v((sm,ic)=>{"use strict";ic.exports=(e,t=process.argv)=>{let r=e.startsWith("-")?"":e.length===1?"-":"--",n=t.indexOf(r+e),i=t.indexOf("--");return n!==-1&&(i===-1||n<i)}});var qn=v((om,ac)=>{"use strict";var td=require("os"),oc=require("tty"),we=sc(),{env:X}=process,Ie;we("no-color")||we("no-colors")||we("color=false")||we("color=never")?Ie=0:(we("color")||we("colors")||we("color=true")||we("color=always"))&&(Ie=1);"FORCE_COLOR"in X&&(X.FORCE_COLOR==="true"?Ie=1:X.FORCE_COLOR==="false"?Ie=0:Ie=X.FORCE_COLOR.length===0?1:Math.min(parseInt(X.FORCE_COLOR,10),3));function An(e){return e===0?!1:{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function Pn(e,t){if(Ie===0)return 0;if(we("color=16m")||we("color=full")||we("color=truecolor"))return 3;if(we("color=256"))return 2;if(e&&!t&&Ie===void 0)return 0;let r=Ie||0;if(X.TERM==="dumb")return r;if(process.platform==="win32"){let n=td.release().split(".");return Number(n[0])>=10&&Number(n[2])>=10586?Number(n[2])>=14931?3:2:1}if("CI"in X)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some(n=>n in X)||X.CI_NAME==="codeship"?1:r;if("TEAMCITY_VERSION"in X)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(X.TEAMCITY_VERSION)?1:0;if(X.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in X){let n=parseInt((X.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(X.TERM_PROGRAM){case"iTerm.app":return n>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(X.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(X.TERM)||"COLORTERM"in X?1:r}function rd(e){let t=Pn(e,e&&e.isTTY);return An(t)}ac.exports={supportsColor:rd,stdout:An(Pn(!0,oc.isatty(1))),stderr:An(Pn(!0,oc.isatty(2)))}});var uc=v((ee,xr)=>{var nd=require("tty"),_r=require("util");ee.init=ld;ee.log=ad;ee.formatArgs=sd;ee.save=cd;ee.load=ud;ee.useColors=id;ee.destroy=_r.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");ee.colors=[6,2,3,4,5,1];try{let e=qn();e&&(e.stderr||e).level>=2&&(ee.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch{}ee.inspectOpts=Object.keys(process.env).filter(e=>/^debug_/i.test(e)).reduce((e,t)=>{let r=t.substring(6).toLowerCase().replace(/_([a-z])/g,(i,s)=>s.toUpperCase()),n=process.env[t];return/^(yes|on|true|enabled)$/i.test(n)?n=!0:/^(no|off|false|disabled)$/i.test(n)?n=!1:n==="null"?n=null:n=Number(n),e[r]=n,e},{});function id(){return"colors"in ee.inspectOpts?!!ee.inspectOpts.colors:nd.isatty(process.stderr.fd)}function sd(e){let{namespace:t,useColors:r}=this;if(r){let n=this.color,i="\x1B[3"+(n<8?n:"8;5;"+n),s=` ${i};1m${t} \x1B[0m`;e[0]=s+e[0].split(`
12
- `).join(`
13
- `+s),e.push(i+"m+"+xr.exports.humanize(this.diff)+"\x1B[0m")}else e[0]=od()+t+" "+e[0]}function od(){return ee.inspectOpts.hideDate?"":new Date().toISOString()+" "}function ad(...e){return process.stderr.write(_r.format(...e)+`
14
- `)}function cd(e){e?process.env.DEBUG=e:delete process.env.DEBUG}function ud(){return process.env.DEBUG}function ld(e){e.inspectOpts={};let t=Object.keys(ee.inspectOpts);for(let r=0;r<t.length;r++)e.inspectOpts[t[r]]=ee.inspectOpts[t[r]]}xr.exports=On()(ee);var{formatters:cc}=xr.exports;cc.o=function(e){return this.inspectOpts.colors=this.useColors,_r.inspect(e,this.inspectOpts).split(`
15
- `).map(t=>t.trim()).join(" ")};cc.O=function(e){return this.inspectOpts.colors=this.useColors,_r.inspect(e,this.inspectOpts)}});var lc=v((am,Mn)=>{typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?Mn.exports=nc():Mn.exports=uc()});var hc=v((cm,fc)=>{var Ot;fc.exports=function(){if(!Ot){try{Ot=lc()("follow-redirects")}catch{}typeof Ot!="function"&&(Ot=function(){})}Ot.apply(null,arguments)}});var jn=v((um,Dn)=>{var Ge=require("url"),Fn=Ge.URL,fd=require("http"),hd=require("https"),mc=require("stream").Writable,yc=require("assert"),gc=hc(),In=["abort","aborted","connect","error","socket","timeout"],Nn=Object.create(null);In.forEach(function(e){Nn[e]=function(t,r,n){this._redirectable.emit(e,t,r,n)}});var dd=Pt("ERR_INVALID_URL","Invalid URL",TypeError),dc=Pt("ERR_FR_REDIRECTION_FAILURE","Redirected request failed"),pd=Pt("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded"),md=Pt("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit"),yd=Pt("ERR_STREAM_WRITE_AFTER_END","write after end");function me(e,t){mc.call(this),this._sanitizeOptions(e),this._options=e,this._ended=!1,this._ending=!1,this._redirectCount=0,this._redirects=[],this._requestBodyLength=0,this._requestBodyBuffers=[],t&&this.on("response",t);var r=this;this._onNativeResponse=function(n){r._processResponse(n)},this._performRequest()}me.prototype=Object.create(mc.prototype);me.prototype.abort=function(){bc(this._currentRequest),this.emit("abort")};me.prototype.write=function(e,t,r){if(this._ending)throw new yd;if(!ze(e)&&!bd(e))throw new TypeError("data should be a string, Buffer or Uint8Array");if(At(t)&&(r=t,t=null),e.length===0){r&&r();return}this._requestBodyLength+e.length<=this._options.maxBodyLength?(this._requestBodyLength+=e.length,this._requestBodyBuffers.push({data:e,encoding:t}),this._currentRequest.write(e,t,r)):(this.emit("error",new md),this.abort())};me.prototype.end=function(e,t,r){if(At(e)?(r=e,e=t=null):At(t)&&(r=t,t=null),!e)this._ended=this._ending=!0,this._currentRequest.end(null,null,r);else{var n=this,i=this._currentRequest;this.write(e,t,function(){n._ended=!0,i.end(null,null,r)}),this._ending=!0}};me.prototype.setHeader=function(e,t){this._options.headers[e]=t,this._currentRequest.setHeader(e,t)};me.prototype.removeHeader=function(e){delete this._options.headers[e],this._currentRequest.removeHeader(e)};me.prototype.setTimeout=function(e,t){var r=this;function n(o){o.setTimeout(e),o.removeListener("timeout",o.destroy),o.addListener("timeout",o.destroy)}function i(o){r._timeout&&clearTimeout(r._timeout),r._timeout=setTimeout(function(){r.emit("timeout"),s()},e),n(o)}function s(){r._timeout&&(clearTimeout(r._timeout),r._timeout=null),r.removeListener("abort",s),r.removeListener("error",s),r.removeListener("response",s),t&&r.removeListener("timeout",t),r.socket||r._currentRequest.removeListener("socket",i)}return t&&this.on("timeout",t),this.socket?i(this.socket):this._currentRequest.once("socket",i),this.on("socket",n),this.on("abort",s),this.on("error",s),this.on("response",s),this};["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach(function(e){me.prototype[e]=function(t,r){return this._currentRequest[e](t,r)}});["aborted","connection","socket"].forEach(function(e){Object.defineProperty(me.prototype,e,{get:function(){return this._currentRequest[e]}})});me.prototype._sanitizeOptions=function(e){if(e.headers||(e.headers={}),e.host&&(e.hostname||(e.hostname=e.host),delete e.host),!e.pathname&&e.path){var t=e.path.indexOf("?");t<0?e.pathname=e.path:(e.pathname=e.path.substring(0,t),e.search=e.path.substring(t))}};me.prototype._performRequest=function(){var e=this._options.protocol,t=this._options.nativeProtocols[e];if(!t){this.emit("error",new TypeError("Unsupported protocol "+e));return}if(this._options.agents){var r=e.slice(0,-1);this._options.agent=this._options.agents[r]}var n=this._currentRequest=t.request(this._options,this._onNativeResponse);n._redirectable=this;for(var i of In)n.on(i,Nn[i]);if(this._currentUrl=/^\//.test(this._options.path)?Ge.format(this._options):this._options.path,this._isRedirect){var s=0,o=this,a=this._requestBodyBuffers;(function c(d){if(n===o._currentRequest)if(d)o.emit("error",d);else if(s<a.length){var f=a[s++];n.finished||n.write(f.data,f.encoding,c)}else o._ended&&n.end()})()}};me.prototype._processResponse=function(e){var t=e.statusCode;this._options.trackRedirects&&this._redirects.push({url:this._currentUrl,headers:e.headers,statusCode:t});var r=e.headers.location;if(!r||this._options.followRedirects===!1||t<300||t>=400){e.responseUrl=this._currentUrl,e.redirects=this._redirects,this.emit("response",e),this._requestBodyBuffers=[];return}if(bc(this._currentRequest),e.destroy(),++this._redirectCount>this._options.maxRedirects){this.emit("error",new pd);return}var n,i=this._options.beforeRedirect;i&&(n=Object.assign({Host:e.req.getHeader("host")},this._options.headers));var s=this._options.method;((t===301||t===302)&&this._options.method==="POST"||t===303&&!/^(?:GET|HEAD)$/.test(this._options.method))&&(this._options.method="GET",this._requestBodyBuffers=[],Tn(/^content-/i,this._options.headers));var o=Tn(/^host$/i,this._options.headers),a=Ge.parse(this._currentUrl),c=o||a.host,d=/^\w+:/.test(r)?this._currentUrl:Ge.format(Object.assign(a,{host:c})),f;try{f=Ge.resolve(d,r)}catch(_){this.emit("error",new dc({cause:_}));return}gc("redirecting to",f),this._isRedirect=!0;var p=Ge.parse(f);if(Object.assign(this._options,p),(p.protocol!==a.protocol&&p.protocol!=="https:"||p.host!==c&&!vd(p.host,c))&&Tn(/^(?:authorization|cookie)$/i,this._options.headers),At(i)){var y={headers:e.headers,statusCode:t},m={url:d,method:s,headers:n};try{i(this._options,y,m)}catch(_){this.emit("error",_);return}this._sanitizeOptions(this._options)}try{this._performRequest()}catch(_){this.emit("error",new dc({cause:_}))}};function vc(e){var t={maxRedirects:21,maxBodyLength:10485760},r={};return Object.keys(e).forEach(function(n){var i=n+":",s=r[i]=e[n],o=t[n]=Object.create(s);function a(d,f,p){if(ze(d)){var y;try{y=pc(new Fn(d))}catch{y=Ge.parse(d)}if(!ze(y.protocol))throw new dd({input:d});d=y}else Fn&&d instanceof Fn?d=pc(d):(p=f,f=d,d={protocol:i});return At(f)&&(p=f,f=null),f=Object.assign({maxRedirects:t.maxRedirects,maxBodyLength:t.maxBodyLength},d,f),f.nativeProtocols=r,!ze(f.host)&&!ze(f.hostname)&&(f.hostname="::1"),yc.equal(f.protocol,i,"protocol mismatch"),gc("options",f),new me(f,p)}function c(d,f,p){var y=o.request(d,f,p);return y.end(),y}Object.defineProperties(o,{request:{value:a,configurable:!0,enumerable:!0,writable:!0},get:{value:c,configurable:!0,enumerable:!0,writable:!0}})}),t}function gd(){}function pc(e){var t={protocol:e.protocol,hostname:e.hostname.startsWith("[")?e.hostname.slice(1,-1):e.hostname,hash:e.hash,search:e.search,pathname:e.pathname,path:e.pathname+e.search,href:e.href};return e.port!==""&&(t.port=Number(e.port)),t}function Tn(e,t){var r;for(var n in t)e.test(n)&&(r=t[n],delete t[n]);return r===null||typeof r>"u"?void 0:String(r).trim()}function Pt(e,t,r){function n(i){Error.captureStackTrace(this,this.constructor),Object.assign(this,i||{}),this.code=e,this.message=this.cause?t+": "+this.cause.message:t}return n.prototype=new(r||Error),n.prototype.constructor=n,n.prototype.name="Error ["+e+"]",n}function bc(e){for(var t of In)e.removeListener(t,Nn[t]);e.on("error",gd),e.abort()}function vd(e,t){yc(ze(e)&&ze(t));var r=e.length-t.length-1;return r>0&&e[r]==="."&&e.endsWith(t)}function ze(e){return typeof e=="string"||e instanceof String}function At(e){return typeof e=="function"}function bd(e){return typeof e=="object"&&"length"in e}Dn.exports=vc({http:fd,https:hd});Dn.exports.wrap=vc});var $n=v((lm,wd)=>{wd.exports={name:"axios",version:"0.21.4",description:"Promise based HTTP client for the browser and node.js",main:"index.js",scripts:{test:"grunt test",start:"node ./sandbox/server.js",build:"NODE_ENV=production grunt build",preversion:"npm test",version:"npm run build && grunt version && git add -A dist && git add CHANGELOG.md bower.json package.json",postversion:"git push && git push --tags",examples:"node ./examples/server.js",coveralls:"cat coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js",fix:"eslint --fix lib/**/*.js"},repository:{type:"git",url:"https://github.com/axios/axios.git"},keywords:["xhr","http","ajax","promise","node"],author:"Matt Zabriskie",license:"MIT",bugs:{url:"https://github.com/axios/axios/issues"},homepage:"https://axios-http.com",devDependencies:{coveralls:"^3.0.0","es6-promise":"^4.2.4",grunt:"^1.3.0","grunt-banner":"^0.6.0","grunt-cli":"^1.2.0","grunt-contrib-clean":"^1.1.0","grunt-contrib-watch":"^1.0.0","grunt-eslint":"^23.0.0","grunt-karma":"^4.0.0","grunt-mocha-test":"^0.13.3","grunt-ts":"^6.0.0-beta.19","grunt-webpack":"^4.0.2","istanbul-instrumenter-loader":"^1.0.0","jasmine-core":"^2.4.1",karma:"^6.3.2","karma-chrome-launcher":"^3.1.0","karma-firefox-launcher":"^2.1.0","karma-jasmine":"^1.1.1","karma-jasmine-ajax":"^0.1.13","karma-safari-launcher":"^1.0.0","karma-sauce-launcher":"^4.3.6","karma-sinon":"^1.0.5","karma-sourcemap-loader":"^0.3.8","karma-webpack":"^4.0.2","load-grunt-tasks":"^3.5.2",minimist:"^1.2.0",mocha:"^8.2.1",sinon:"^4.5.0","terser-webpack-plugin":"^4.2.3",typescript:"^4.0.5","url-search-params":"^0.10.0",webpack:"^4.44.2","webpack-dev-server":"^3.11.0"},browser:{"./lib/adapters/http.js":"./lib/adapters/xhr.js"},jsdelivr:"dist/axios.min.js",unpkg:"dist/axios.min.js",typings:"./index.d.ts",dependencies:{"follow-redirects":"^1.14.0"},bundlesize:[{path:"./dist/axios.min.js",threshold:"5kB"}]}});var kc=v((fm,Sc)=>{"use strict";var qt=ue(),wc=Sn(),_d=kn(),xd=dr(),Ed=require("http"),Sd=require("https"),kd=jn().http,Cd=jn().https,_c=require("url"),Rd=require("zlib"),Od=$n(),Er=yr(),Bn=mr(),xc=/https:?/;function Ec(e,t,r){if(e.hostname=t.host,e.host=t.host,e.port=t.port,e.path=r,t.auth){var n=Buffer.from(t.auth.username+":"+t.auth.password,"utf8").toString("base64");e.headers["Proxy-Authorization"]="Basic "+n}e.beforeRedirect=function(s){s.headers.host=s.host,Ec(s,t,s.href)}}Sc.exports=function(t){return new Promise(function(n,i){var s=function(C){n(C)},o=function(C){i(C)},a=t.data,c=t.headers;if("User-Agent"in c||"user-agent"in c?!c["User-Agent"]&&!c["user-agent"]&&(delete c["User-Agent"],delete c["user-agent"]):c["User-Agent"]="axios/"+Od.version,a&&!qt.isStream(a)){if(!Buffer.isBuffer(a))if(qt.isArrayBuffer(a))a=Buffer.from(new Uint8Array(a));else if(qt.isString(a))a=Buffer.from(a,"utf-8");else return o(Er("Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream",t));c["Content-Length"]=a.length}var d=void 0;if(t.auth){var f=t.auth.username||"",p=t.auth.password||"";d=f+":"+p}var y=_d(t.baseURL,t.url),m=_c.parse(y),_=m.protocol||"http:";if(!d&&m.auth){var A=m.auth.split(":"),P=A[0]||"",N=A[1]||"";d=P+":"+N}d&&delete c.Authorization;var U=xc.test(_),W=U?t.httpsAgent:t.httpAgent,x={path:xd(m.path,t.params,t.paramsSerializer).replace(/^\?/,""),method:t.method.toUpperCase(),headers:c,agent:W,agents:{http:t.httpAgent,https:t.httpsAgent},auth:d};t.socketPath?x.socketPath=t.socketPath:(x.hostname=m.hostname,x.port=m.port);var k=t.proxy;if(!k&&k!==!1){var M=_.slice(0,-1)+"_proxy",ye=process.env[M]||process.env[M.toUpperCase()];if(ye){var Q=_c.parse(ye),R=process.env.no_proxy||process.env.NO_PROXY,D=!0;if(R){var T=R.split(",").map(function(C){return C.trim()});D=!T.some(function(C){return C?C==="*"||C[0]==="."&&m.hostname.substr(m.hostname.length-C.length)===C?!0:m.hostname===C:!1})}if(D&&(k={host:Q.hostname,port:Q.port,protocol:Q.protocol},Q.auth)){var G=Q.auth.split(":");k.auth={username:G[0],password:G[1]}}}}k&&(x.headers.host=m.hostname+(m.port?":"+m.port:""),Ec(x,k,_+"//"+m.hostname+(m.port?":"+m.port:"")+x.path));var q,H=U&&(k?xc.test(k.protocol):!0);t.transport?q=t.transport:t.maxRedirects===0?q=H?Sd:Ed:(t.maxRedirects&&(x.maxRedirects=t.maxRedirects),q=H?Cd:kd),t.maxBodyLength>-1&&(x.maxBodyLength=t.maxBodyLength);var O=q.request(x,function(C){if(!O.aborted){var F=C,Oe=C.req||O;if(C.statusCode!==204&&Oe.method!=="HEAD"&&t.decompress!==!1)switch(C.headers["content-encoding"]){case"gzip":case"compress":case"deflate":F=F.pipe(Rd.createUnzip()),delete C.headers["content-encoding"];break}var je={status:C.statusCode,statusText:C.statusMessage,headers:C.headers,config:t,request:Oe};if(t.responseType==="stream")je.data=F,wc(s,o,je);else{var le=[],ge=0;F.on("data",function(ve){le.push(ve),ge+=ve.length,t.maxContentLength>-1&&ge>t.maxContentLength&&(F.destroy(),o(Er("maxContentLength size of "+t.maxContentLength+" exceeded",t,null,Oe)))}),F.on("error",function(ve){O.aborted||o(Bn(ve,t,null,Oe))}),F.on("end",function(){var ve=Buffer.concat(le);t.responseType!=="arraybuffer"&&(ve=ve.toString(t.responseEncoding),(!t.responseEncoding||t.responseEncoding==="utf8")&&(ve=qt.stripBOM(ve))),je.data=ve,wc(s,o,je)})}}});if(O.on("error",function(C){O.aborted&&C.code!=="ERR_FR_TOO_MANY_REDIRECTS"||o(Bn(C,t,null,O))}),t.timeout){var $=parseInt(t.timeout,10);if(isNaN($)){o(Er("error trying to parse `config.timeout` to int",t,"ERR_PARSE_TIMEOUT",O));return}O.setTimeout($,function(){O.abort(),o(Er("timeout of "+$+"ms exceeded",t,t.transitional&&t.transitional.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",O))})}t.cancelToken&&t.cancelToken.promise.then(function(C){O.aborted||(O.abort(),o(C))}),qt.isStream(a)?a.on("error",function(C){o(Bn(C,t,null,O))}).pipe(O):O.end(a)})}});var kr=v((hm,Oc)=>{"use strict";var te=ue(),Cc=Na(),Ad=mr(),Pd={"Content-Type":"application/x-www-form-urlencoded"};function Rc(e,t){!te.isUndefined(e)&&te.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function qd(){var e;return typeof XMLHttpRequest<"u"?e=Za():typeof process<"u"&&Object.prototype.toString.call(process)==="[object process]"&&(e=kc()),e}function Md(e,t,r){if(te.isString(e))try{return(t||JSON.parse)(e),te.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}var Sr={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:qd(),transformRequest:[function(t,r){return Cc(r,"Accept"),Cc(r,"Content-Type"),te.isFormData(t)||te.isArrayBuffer(t)||te.isBuffer(t)||te.isStream(t)||te.isFile(t)||te.isBlob(t)?t:te.isArrayBufferView(t)?t.buffer:te.isURLSearchParams(t)?(Rc(r,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):te.isObject(t)||r&&r["Content-Type"]==="application/json"?(Rc(r,"application/json"),Md(t)):t}],transformResponse:[function(t){var r=this.transitional,n=r&&r.silentJSONParsing,i=r&&r.forcedJSONParsing,s=!n&&this.responseType==="json";if(s||i&&te.isString(t)&&t.length)try{return JSON.parse(t)}catch(o){if(s)throw o.name==="SyntaxError"?Ad(o,this,"E_JSON_PARSE"):o}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(t){return t>=200&&t<300}};Sr.headers={common:{Accept:"application/json, text/plain, */*"}};te.forEach(["delete","get","head"],function(t){Sr.headers[t]={}});te.forEach(["post","put","patch"],function(t){Sr.headers[t]=te.merge(Pd)});Oc.exports=Sr});var Pc=v((dm,Ac)=>{"use strict";var Fd=ue(),Td=kr();Ac.exports=function(t,r,n){var i=this||Td;return Fd.forEach(n,function(o){t=o.call(i,t,r)}),t}});var Ln=v((pm,qc)=>{"use strict";qc.exports=function(t){return!!(t&&t.__CANCEL__)}});var Tc=v((mm,Fc)=>{"use strict";var Mc=ue(),Hn=Pc(),Id=Ln(),Nd=kr();function Un(e){e.cancelToken&&e.cancelToken.throwIfRequested()}Fc.exports=function(t){Un(t),t.headers=t.headers||{},t.data=Hn.call(t,t.data,t.headers,t.transformRequest),t.headers=Mc.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),Mc.forEach(["delete","get","head","post","put","patch","common"],function(i){delete t.headers[i]});var r=t.adapter||Nd.adapter;return r(t).then(function(i){return Un(t),i.data=Hn.call(t,i.data,i.headers,t.transformResponse),i},function(i){return Id(i)||(Un(t),i&&i.response&&(i.response.data=Hn.call(t,i.response.data,i.response.headers,t.transformResponse))),Promise.reject(i)})}});var Gn=v((ym,Ic)=>{"use strict";var se=ue();Ic.exports=function(t,r){r=r||{};var n={},i=["url","method","data"],s=["headers","auth","proxy","params"],o=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],a=["validateStatus"];function c(y,m){return se.isPlainObject(y)&&se.isPlainObject(m)?se.merge(y,m):se.isPlainObject(m)?se.merge({},m):se.isArray(m)?m.slice():m}function d(y){se.isUndefined(r[y])?se.isUndefined(t[y])||(n[y]=c(void 0,t[y])):n[y]=c(t[y],r[y])}se.forEach(i,function(m){se.isUndefined(r[m])||(n[m]=c(void 0,r[m]))}),se.forEach(s,d),se.forEach(o,function(m){se.isUndefined(r[m])?se.isUndefined(t[m])||(n[m]=c(void 0,t[m])):n[m]=c(void 0,r[m])}),se.forEach(a,function(m){m in r?n[m]=c(t[m],r[m]):m in t&&(n[m]=c(void 0,t[m]))});var f=i.concat(s).concat(o).concat(a),p=Object.keys(t).concat(Object.keys(r)).filter(function(m){return f.indexOf(m)===-1});return se.forEach(p,d),n}});var Bc=v((gm,$c)=>{"use strict";var Dc=$n(),zn={};["object","boolean","number","function","string","symbol"].forEach(function(e,t){zn[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});var Nc={},Dd=Dc.version.split(".");function jc(e,t){for(var r=t?t.split("."):Dd,n=e.split("."),i=0;i<3;i++){if(r[i]>n[i])return!0;if(r[i]<n[i])return!1}return!1}zn.transitional=function(t,r,n){var i=r&&jc(r);function s(o,a){return"[Axios v"+Dc.version+"] Transitional option '"+o+"'"+a+(n?". "+n:"")}return function(o,a,c){if(t===!1)throw new Error(s(a," has been removed in "+r));return i&&!Nc[a]&&(Nc[a]=!0,console.warn(s(a," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(o,a,c):!0}};function jd(e,t,r){if(typeof e!="object")throw new TypeError("options must be an object");for(var n=Object.keys(e),i=n.length;i-- >0;){var s=n[i],o=t[s];if(o){var a=e[s],c=a===void 0||o(a,s,e);if(c!==!0)throw new TypeError("option "+s+" must be "+c);continue}if(r!==!0)throw Error("Unknown option "+s)}}$c.exports={isOlderVersion:jc,assertOptions:jd,validators:zn}});var Wc=v((vm,zc)=>{"use strict";var Uc=ue(),$d=dr(),Lc=Ta(),Hc=Tc(),Cr=Gn(),Gc=Bc(),ct=Gc.validators;function Mt(e){this.defaults=e,this.interceptors={request:new Lc,response:new Lc}}Mt.prototype.request=function(t){typeof t=="string"?(t=arguments[1]||{},t.url=arguments[0]):t=t||{},t=Cr(this.defaults,t),t.method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var r=t.transitional;r!==void 0&&Gc.assertOptions(r,{silentJSONParsing:ct.transitional(ct.boolean,"1.0.0"),forcedJSONParsing:ct.transitional(ct.boolean,"1.0.0"),clarifyTimeoutError:ct.transitional(ct.boolean,"1.0.0")},!1);var n=[],i=!0;this.interceptors.request.forEach(function(y){typeof y.runWhen=="function"&&y.runWhen(t)===!1||(i=i&&y.synchronous,n.unshift(y.fulfilled,y.rejected))});var s=[];this.interceptors.response.forEach(function(y){s.push(y.fulfilled,y.rejected)});var o;if(!i){var a=[Hc,void 0];for(Array.prototype.unshift.apply(a,n),a=a.concat(s),o=Promise.resolve(t);a.length;)o=o.then(a.shift(),a.shift());return o}for(var c=t;n.length;){var d=n.shift(),f=n.shift();try{c=d(c)}catch(p){f(p);break}}try{o=Hc(c)}catch(p){return Promise.reject(p)}for(;s.length;)o=o.then(s.shift(),s.shift());return o};Mt.prototype.getUri=function(t){return t=Cr(this.defaults,t),$d(t.url,t.params,t.paramsSerializer).replace(/^\?/,"")};Uc.forEach(["delete","get","head","options"],function(t){Mt.prototype[t]=function(r,n){return this.request(Cr(n||{},{method:t,url:r,data:(n||{}).data}))}});Uc.forEach(["post","put","patch"],function(t){Mt.prototype[t]=function(r,n,i){return this.request(Cr(i||{},{method:t,url:r,data:n}))}});zc.exports=Mt});var Jn=v((bm,Jc)=>{"use strict";function Wn(e){this.message=e}Wn.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")};Wn.prototype.__CANCEL__=!0;Jc.exports=Wn});var Yc=v((wm,Vc)=>{"use strict";var Bd=Jn();function Rr(e){if(typeof e!="function")throw new TypeError("executor must be a function.");var t;this.promise=new Promise(function(i){t=i});var r=this;e(function(i){r.reason||(r.reason=new Bd(i),t(r.reason))})}Rr.prototype.throwIfRequested=function(){if(this.reason)throw this.reason};Rr.source=function(){var t,r=new Rr(function(i){t=i});return{token:r,cancel:t}};Vc.exports=Rr});var Xc=v((_m,Kc)=>{"use strict";Kc.exports=function(t){return function(n){return t.apply(null,n)}}});var Zc=v((xm,Qc)=>{"use strict";Qc.exports=function(t){return typeof t=="object"&&t.isAxiosError===!0}});var ru=v((Em,Vn)=>{"use strict";var eu=ue(),Ld=bn(),Or=Wc(),Hd=Gn(),Ud=kr();function tu(e){var t=new Or(e),r=Ld(Or.prototype.request,t);return eu.extend(r,Or.prototype,t),eu.extend(r,t),r}var ke=tu(Ud);ke.Axios=Or;ke.create=function(t){return tu(Hd(ke.defaults,t))};ke.Cancel=Jn();ke.CancelToken=Yc();ke.isCancel=Ln();ke.all=function(t){return Promise.all(t)};ke.spread=Xc();ke.isAxiosError=Zc();Vn.exports=ke;Vn.exports.default=ke});var Yn=v((Sm,nu)=>{nu.exports=ru()});var au=v((Cm,ou)=>{"use strict";ou.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}});var Xn=v((Rm,uu)=>{var Ft=au(),cu={};for(let e of Object.keys(Ft))cu[Ft[e]]=e;var S={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};uu.exports=S;for(let e of Object.keys(S)){if(!("channels"in S[e]))throw new Error("missing channels property: "+e);if(!("labels"in S[e]))throw new Error("missing channel labels property: "+e);if(S[e].labels.length!==S[e].channels)throw new Error("channel and label counts mismatch: "+e);let{channels:t,labels:r}=S[e];delete S[e].channels,delete S[e].labels,Object.defineProperty(S[e],"channels",{value:t}),Object.defineProperty(S[e],"labels",{value:r})}S.rgb.hsl=function(e){let t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.min(t,r,n),s=Math.max(t,r,n),o=s-i,a,c;s===i?a=0:t===s?a=(r-n)/o:r===s?a=2+(n-t)/o:n===s&&(a=4+(t-r)/o),a=Math.min(a*60,360),a<0&&(a+=360);let d=(i+s)/2;return s===i?c=0:d<=.5?c=o/(s+i):c=o/(2-s-i),[a,c*100,d*100]};S.rgb.hsv=function(e){let t,r,n,i,s,o=e[0]/255,a=e[1]/255,c=e[2]/255,d=Math.max(o,a,c),f=d-Math.min(o,a,c),p=function(y){return(d-y)/6/f+1/2};return f===0?(i=0,s=0):(s=f/d,t=p(o),r=p(a),n=p(c),o===d?i=n-r:a===d?i=1/3+t-n:c===d&&(i=2/3+r-t),i<0?i+=1:i>1&&(i-=1)),[i*360,s*100,d*100]};S.rgb.hwb=function(e){let t=e[0],r=e[1],n=e[2],i=S.rgb.hsl(e)[0],s=1/255*Math.min(t,Math.min(r,n));return n=1-1/255*Math.max(t,Math.max(r,n)),[i,s*100,n*100]};S.rgb.cmyk=function(e){let t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.min(1-t,1-r,1-n),s=(1-t-i)/(1-i)||0,o=(1-r-i)/(1-i)||0,a=(1-n-i)/(1-i)||0;return[s*100,o*100,a*100,i*100]};function Gd(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}S.rgb.keyword=function(e){let t=cu[e];if(t)return t;let r=1/0,n;for(let i of Object.keys(Ft)){let s=Ft[i],o=Gd(e,s);o<r&&(r=o,n=i)}return n};S.keyword.rgb=function(e){return Ft[e]};S.rgb.xyz=function(e){let t=e[0]/255,r=e[1]/255,n=e[2]/255;t=t>.04045?((t+.055)/1.055)**2.4:t/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92;let i=t*.4124+r*.3576+n*.1805,s=t*.2126+r*.7152+n*.0722,o=t*.0193+r*.1192+n*.9505;return[i*100,s*100,o*100]};S.rgb.lab=function(e){let t=S.rgb.xyz(e),r=t[0],n=t[1],i=t[2];r/=95.047,n/=100,i/=108.883,r=r>.008856?r**(1/3):7.787*r+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,i=i>.008856?i**(1/3):7.787*i+16/116;let s=116*n-16,o=500*(r-n),a=200*(n-i);return[s,o,a]};S.hsl.rgb=function(e){let t=e[0]/360,r=e[1]/100,n=e[2]/100,i,s,o;if(r===0)return o=n*255,[o,o,o];n<.5?i=n*(1+r):i=n+r-n*r;let a=2*n-i,c=[0,0,0];for(let d=0;d<3;d++)s=t+1/3*-(d-1),s<0&&s++,s>1&&s--,6*s<1?o=a+(i-a)*6*s:2*s<1?o=i:3*s<2?o=a+(i-a)*(2/3-s)*6:o=a,c[d]=o*255;return c};S.hsl.hsv=function(e){let t=e[0],r=e[1]/100,n=e[2]/100,i=r,s=Math.max(n,.01);n*=2,r*=n<=1?n:2-n,i*=s<=1?s:2-s;let o=(n+r)/2,a=n===0?2*i/(s+i):2*r/(n+r);return[t,a*100,o*100]};S.hsv.rgb=function(e){let t=e[0]/60,r=e[1]/100,n=e[2]/100,i=Math.floor(t)%6,s=t-Math.floor(t),o=255*n*(1-r),a=255*n*(1-r*s),c=255*n*(1-r*(1-s));switch(n*=255,i){case 0:return[n,c,o];case 1:return[a,n,o];case 2:return[o,n,c];case 3:return[o,a,n];case 4:return[c,o,n];case 5:return[n,o,a]}};S.hsv.hsl=function(e){let t=e[0],r=e[1]/100,n=e[2]/100,i=Math.max(n,.01),s,o;o=(2-r)*n;let a=(2-r)*i;return s=r*i,s/=a<=1?a:2-a,s=s||0,o/=2,[t,s*100,o*100]};S.hwb.rgb=function(e){let t=e[0]/360,r=e[1]/100,n=e[2]/100,i=r+n,s;i>1&&(r/=i,n/=i);let o=Math.floor(6*t),a=1-n;s=6*t-o,o&1&&(s=1-s);let c=r+s*(a-r),d,f,p;switch(o){default:case 6:case 0:d=a,f=c,p=r;break;case 1:d=c,f=a,p=r;break;case 2:d=r,f=a,p=c;break;case 3:d=r,f=c,p=a;break;case 4:d=c,f=r,p=a;break;case 5:d=a,f=r,p=c;break}return[d*255,f*255,p*255]};S.cmyk.rgb=function(e){let t=e[0]/100,r=e[1]/100,n=e[2]/100,i=e[3]/100,s=1-Math.min(1,t*(1-i)+i),o=1-Math.min(1,r*(1-i)+i),a=1-Math.min(1,n*(1-i)+i);return[s*255,o*255,a*255]};S.xyz.rgb=function(e){let t=e[0]/100,r=e[1]/100,n=e[2]/100,i,s,o;return i=t*3.2406+r*-1.5372+n*-.4986,s=t*-.9689+r*1.8758+n*.0415,o=t*.0557+r*-.204+n*1.057,i=i>.0031308?1.055*i**(1/2.4)-.055:i*12.92,s=s>.0031308?1.055*s**(1/2.4)-.055:s*12.92,o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92,i=Math.min(Math.max(0,i),1),s=Math.min(Math.max(0,s),1),o=Math.min(Math.max(0,o),1),[i*255,s*255,o*255]};S.xyz.lab=function(e){let t=e[0],r=e[1],n=e[2];t/=95.047,r/=100,n/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,n=n>.008856?n**(1/3):7.787*n+16/116;let i=116*r-16,s=500*(t-r),o=200*(r-n);return[i,s,o]};S.lab.xyz=function(e){let t=e[0],r=e[1],n=e[2],i,s,o;s=(t+16)/116,i=r/500+s,o=s-n/200;let a=s**3,c=i**3,d=o**3;return s=a>.008856?a:(s-16/116)/7.787,i=c>.008856?c:(i-16/116)/7.787,o=d>.008856?d:(o-16/116)/7.787,i*=95.047,s*=100,o*=108.883,[i,s,o]};S.lab.lch=function(e){let t=e[0],r=e[1],n=e[2],i;i=Math.atan2(n,r)*360/2/Math.PI,i<0&&(i+=360);let o=Math.sqrt(r*r+n*n);return[t,o,i]};S.lch.lab=function(e){let t=e[0],r=e[1],i=e[2]/360*2*Math.PI,s=r*Math.cos(i),o=r*Math.sin(i);return[t,s,o]};S.rgb.ansi16=function(e,t=null){let[r,n,i]=e,s=t===null?S.rgb.hsv(e)[2]:t;if(s=Math.round(s/50),s===0)return 30;let o=30+(Math.round(i/255)<<2|Math.round(n/255)<<1|Math.round(r/255));return s===2&&(o+=60),o};S.hsv.ansi16=function(e){return S.rgb.ansi16(S.hsv.rgb(e),e[2])};S.rgb.ansi256=function(e){let t=e[0],r=e[1],n=e[2];return t===r&&r===n?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5)};S.ansi16.rgb=function(e){let t=e%10;if(t===0||t===7)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];let r=(~~(e>50)+1)*.5,n=(t&1)*r*255,i=(t>>1&1)*r*255,s=(t>>2&1)*r*255;return[n,i,s]};S.ansi256.rgb=function(e){if(e>=232){let s=(e-232)*10+8;return[s,s,s]}e-=16;let t,r=Math.floor(e/36)/5*255,n=Math.floor((t=e%36)/6)/5*255,i=t%6/5*255;return[r,n,i]};S.rgb.hex=function(e){let r=(((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255)).toString(16).toUpperCase();return"000000".substring(r.length)+r};S.hex.rgb=function(e){let t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let r=t[0];t[0].length===3&&(r=r.split("").map(a=>a+a).join(""));let n=parseInt(r,16),i=n>>16&255,s=n>>8&255,o=n&255;return[i,s,o]};S.rgb.hcg=function(e){let t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.max(Math.max(t,r),n),s=Math.min(Math.min(t,r),n),o=i-s,a,c;return o<1?a=s/(1-o):a=0,o<=0?c=0:i===t?c=(r-n)/o%6:i===r?c=2+(n-t)/o:c=4+(t-r)/o,c/=6,c%=1,[c*360,o*100,a*100]};S.hsl.hcg=function(e){let t=e[1]/100,r=e[2]/100,n=r<.5?2*t*r:2*t*(1-r),i=0;return n<1&&(i=(r-.5*n)/(1-n)),[e[0],n*100,i*100]};S.hsv.hcg=function(e){let t=e[1]/100,r=e[2]/100,n=t*r,i=0;return n<1&&(i=(r-n)/(1-n)),[e[0],n*100,i*100]};S.hcg.rgb=function(e){let t=e[0]/360,r=e[1]/100,n=e[2]/100;if(r===0)return[n*255,n*255,n*255];let i=[0,0,0],s=t%1*6,o=s%1,a=1-o,c=0;switch(Math.floor(s)){case 0:i[0]=1,i[1]=o,i[2]=0;break;case 1:i[0]=a,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=o;break;case 3:i[0]=0,i[1]=a,i[2]=1;break;case 4:i[0]=o,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=a}return c=(1-r)*n,[(r*i[0]+c)*255,(r*i[1]+c)*255,(r*i[2]+c)*255]};S.hcg.hsv=function(e){let t=e[1]/100,r=e[2]/100,n=t+r*(1-t),i=0;return n>0&&(i=t/n),[e[0],i*100,n*100]};S.hcg.hsl=function(e){let t=e[1]/100,n=e[2]/100*(1-t)+.5*t,i=0;return n>0&&n<.5?i=t/(2*n):n>=.5&&n<1&&(i=t/(2*(1-n))),[e[0],i*100,n*100]};S.hcg.hwb=function(e){let t=e[1]/100,r=e[2]/100,n=t+r*(1-t);return[e[0],(n-t)*100,(1-n)*100]};S.hwb.hcg=function(e){let t=e[1]/100,n=1-e[2]/100,i=n-t,s=0;return i<1&&(s=(n-i)/(1-i)),[e[0],i*100,s*100]};S.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};S.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};S.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};S.gray.hsl=function(e){return[0,0,e[0]]};S.gray.hsv=S.gray.hsl;S.gray.hwb=function(e){return[0,100,e[0]]};S.gray.cmyk=function(e){return[0,0,0,e[0]]};S.gray.lab=function(e){return[e[0],0,0]};S.gray.hex=function(e){let t=Math.round(e[0]/100*255)&255,n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(n.length)+n};S.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}});var fu=v((Om,lu)=>{var Pr=Xn();function zd(){let e={},t=Object.keys(Pr);for(let r=t.length,n=0;n<r;n++)e[t[n]]={distance:-1,parent:null};return e}function Wd(e){let t=zd(),r=[e];for(t[e].distance=0;r.length;){let n=r.pop(),i=Object.keys(Pr[n]);for(let s=i.length,o=0;o<s;o++){let a=i[o],c=t[a];c.distance===-1&&(c.distance=t[n].distance+1,c.parent=n,r.unshift(a))}}return t}function Jd(e,t){return function(r){return t(e(r))}}function Vd(e,t){let r=[t[e].parent,e],n=Pr[t[e].parent][e],i=t[e].parent;for(;t[i].parent;)r.unshift(t[i].parent),n=Jd(Pr[t[i].parent][i],n),i=t[i].parent;return n.conversion=r,n}lu.exports=function(e){let t=Wd(e),r={},n=Object.keys(t);for(let i=n.length,s=0;s<i;s++){let o=n[s];t[o].parent!==null&&(r[o]=Vd(o,t))}return r}});var du=v((Am,hu)=>{var Qn=Xn(),Yd=fu(),ut={},Kd=Object.keys(Qn);function Xd(e){let t=function(...r){let n=r[0];return n==null?n:(n.length>1&&(r=n),e(r))};return"conversion"in e&&(t.conversion=e.conversion),t}function Qd(e){let t=function(...r){let n=r[0];if(n==null)return n;n.length>1&&(r=n);let i=e(r);if(typeof i=="object")for(let s=i.length,o=0;o<s;o++)i[o]=Math.round(i[o]);return i};return"conversion"in e&&(t.conversion=e.conversion),t}Kd.forEach(e=>{ut[e]={},Object.defineProperty(ut[e],"channels",{value:Qn[e].channels}),Object.defineProperty(ut[e],"labels",{value:Qn[e].labels});let t=Yd(e);Object.keys(t).forEach(n=>{let i=t[n];ut[e][n]=Qd(i),ut[e][n].raw=Xd(i)})});hu.exports=ut});var bu=v((Pm,vu)=>{"use strict";var pu=(e,t)=>(...r)=>`\x1B[${e(...r)+t}m`,mu=(e,t)=>(...r)=>{let n=e(...r);return`\x1B[${38+t};5;${n}m`},yu=(e,t)=>(...r)=>{let n=e(...r);return`\x1B[${38+t};2;${n[0]};${n[1]};${n[2]}m`},qr=e=>e,gu=(e,t,r)=>[e,t,r],lt=(e,t,r)=>{Object.defineProperty(e,t,{get:()=>{let n=r();return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0}),n},enumerable:!0,configurable:!0})},Zn,ft=(e,t,r,n)=>{Zn===void 0&&(Zn=du());let i=n?10:0,s={};for(let[o,a]of Object.entries(Zn)){let c=o==="ansi16"?"ansi":o;o===t?s[c]=e(r,i):typeof a=="object"&&(s[c]=e(a[t],i))}return s};function Zd(){let e=new Map,t={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};t.color.gray=t.color.blackBright,t.bgColor.bgGray=t.bgColor.bgBlackBright,t.color.grey=t.color.blackBright,t.bgColor.bgGrey=t.bgColor.bgBlackBright;for(let[r,n]of Object.entries(t)){for(let[i,s]of Object.entries(n))t[i]={open:`\x1B[${s[0]}m`,close:`\x1B[${s[1]}m`},n[i]=t[i],e.set(s[0],s[1]);Object.defineProperty(t,r,{value:n,enumerable:!1})}return Object.defineProperty(t,"codes",{value:e,enumerable:!1}),t.color.close="\x1B[39m",t.bgColor.close="\x1B[49m",lt(t.color,"ansi",()=>ft(pu,"ansi16",qr,!1)),lt(t.color,"ansi256",()=>ft(mu,"ansi256",qr,!1)),lt(t.color,"ansi16m",()=>ft(yu,"rgb",gu,!1)),lt(t.bgColor,"ansi",()=>ft(pu,"ansi16",qr,!0)),lt(t.bgColor,"ansi256",()=>ft(mu,"ansi256",qr,!0)),lt(t.bgColor,"ansi16m",()=>ft(yu,"rgb",gu,!0)),t}Object.defineProperty(vu,"exports",{enumerable:!0,get:Zd})});var _u=v((qm,wu)=>{"use strict";var ep=(e,t,r)=>{let n=e.indexOf(t);if(n===-1)return e;let i=t.length,s=0,o="";do o+=e.substr(s,n-s)+t+r,s=n+i,n=e.indexOf(t,s);while(n!==-1);return o+=e.substr(s),o},tp=(e,t,r,n)=>{let i=0,s="";do{let o=e[n-1]==="\r";s+=e.substr(i,(o?n-1:n)-i)+t+(o?`\r
14
+ see https://github.com/jprichardson/node-fs-extra/issues/269`),nr.checkPaths(t,e,"copy",(i,s)=>{if(i)return n(i);let{srcStat:o,destStat:a}=s;nr.checkParentPaths(t,o,e,"copy",u=>u?n(u):r.filter?dc(cc,a,t,e,r,n):cc(a,t,e,r,n))})}function cc(t,e,r,n,i){let s=rr.dirname(r);om(s,(o,a)=>{if(o)return i(o);if(a)return Gi(t,e,r,n,i);sm(s,u=>u?i(u):Gi(t,e,r,n,i))})}function dc(t,e,r,n,i,s){Promise.resolve(i.filter(r,n)).then(o=>o?t(e,r,n,i,s):s(),o=>s(o))}function Gi(t,e,r,n,i){return n.filter?dc(lc,t,e,r,n,i):lc(t,e,r,n,i)}function lc(t,e,r,n,i){(n.dereference?Se.stat:Se.lstat)(e,(o,a)=>{if(o)return i(o);if(a.isDirectory())return mm(a,t,e,r,n,i);if(a.isFile()||a.isCharacterDevice()||a.isBlockDevice())return cm(a,t,e,r,n,i);if(a.isSymbolicLink())return vm(t,e,r,n,i)})}function cm(t,e,r,n,i,s){return e?lm(t,r,n,i,s):hc(t,r,n,i,s)}function lm(t,e,r,n,i){if(n.overwrite)Se.unlink(r,s=>s?i(s):hc(t,e,r,n,i));else return n.errorOnExist?i(new Error(`'${r}' already exists`)):i()}function hc(t,e,r,n,i){Se.copyFile(e,r,s=>s?i(s):n.preserveTimestamps?fm(t.mode,e,r,i):tn(r,t.mode,i))}function fm(t,e,r,n){return dm(t)?hm(r,t,i=>i?n(i):fc(t,e,r,n)):fc(t,e,r,n)}function dm(t){return(t&128)===0}function hm(t,e,r){return tn(t,e|128,r)}function fc(t,e,r,n){pm(e,r,i=>i?n(i):tn(r,t,n))}function tn(t,e,r){return Se.chmod(t,e,r)}function pm(t,e,r){Se.stat(t,(n,i)=>n?r(n):am(e,i.atime,i.mtime,r))}function mm(t,e,r,n,i,s){return e?e&&!e.isDirectory()?s(new Error(`Cannot overwrite non-directory '${n}' with directory '${r}'.`)):pc(r,n,i,s):gm(t.mode,r,n,i,s)}function gm(t,e,r,n,i){Se.mkdir(r,s=>{if(s)return i(s);pc(e,r,n,o=>o?i(o):tn(r,t,i))})}function pc(t,e,r,n){Se.readdir(t,(i,s)=>i?n(i):mc(s,t,e,r,n))}function mc(t,e,r,n,i){let s=t.pop();return s?ym(t,s,e,r,n,i):i()}function ym(t,e,r,n,i,s){let o=rr.join(r,e),a=rr.join(n,e);nr.checkPaths(o,a,"copy",(u,h)=>{if(u)return s(u);let{destStat:c}=h;Gi(c,o,a,i,p=>p?s(p):mc(t,r,n,i,s))})}function vm(t,e,r,n,i){Se.readlink(e,(s,o)=>{if(s)return i(s);if(n.dereference&&(o=rr.resolve(process.cwd(),o)),t)Se.readlink(r,(a,u)=>a?a.code==="EINVAL"||a.code==="UNKNOWN"?Se.symlink(o,r,i):i(a):(n.dereference&&(u=rr.resolve(process.cwd(),u)),nr.isSrcSubdir(o,u)?i(new Error(`Cannot copy '${o}' to a subdirectory of itself, '${u}'.`)):t.isDirectory()&&nr.isSrcSubdir(u,o)?i(new Error(`Cannot overwrite '${u}' with '${o}'.`)):bm(o,r,i)));else return Se.symlink(o,r,i)})}function bm(t,e,r){Se.unlink(e,n=>n?r(n):Se.symlink(t,e,r))}gc.exports=um});var Wi=y((Qb,vc)=>{"use strict";var _m=we().fromCallback;vc.exports={copy:_m(yc())}});var Dc=y((Zb,Pc)=>{"use strict";var bc=fe(),Sc=require("path"),G=require("assert"),ir=process.platform==="win32";function Ec(t){["unlink","chmod","stat","lstat","rmdir","readdir"].forEach(r=>{t[r]=t[r]||bc[r],r=r+"Sync",t[r]=t[r]||bc[r]}),t.maxBusyTries=t.maxBusyTries||3}function zi(t,e,r){let n=0;typeof e=="function"&&(r=e,e={}),G(t,"rimraf: missing path"),G.strictEqual(typeof t,"string","rimraf: path should be a string"),G.strictEqual(typeof r,"function","rimraf: callback function required"),G(e,"rimraf: invalid options argument provided"),G.strictEqual(typeof e,"object","rimraf: options should be object"),Ec(e),_c(t,e,function i(s){if(s){if((s.code==="EBUSY"||s.code==="ENOTEMPTY"||s.code==="EPERM")&&n<e.maxBusyTries){n++;let o=n*100;return setTimeout(()=>_c(t,e,i),o)}s.code==="ENOENT"&&(s=null)}r(s)})}function _c(t,e,r){G(t),G(e),G(typeof r=="function"),e.lstat(t,(n,i)=>{if(n&&n.code==="ENOENT")return r(null);if(n&&n.code==="EPERM"&&ir)return wc(t,e,n,r);if(i&&i.isDirectory())return rn(t,e,n,r);e.unlink(t,s=>{if(s){if(s.code==="ENOENT")return r(null);if(s.code==="EPERM")return ir?wc(t,e,s,r):rn(t,e,s,r);if(s.code==="EISDIR")return rn(t,e,s,r)}return r(s)})})}function wc(t,e,r,n){G(t),G(e),G(typeof n=="function"),e.chmod(t,438,i=>{i?n(i.code==="ENOENT"?null:r):e.stat(t,(s,o)=>{s?n(s.code==="ENOENT"?null:r):o.isDirectory()?rn(t,e,r,n):e.unlink(t,n)})})}function xc(t,e,r){let n;G(t),G(e);try{e.chmodSync(t,438)}catch(i){if(i.code==="ENOENT")return;throw r}try{n=e.statSync(t)}catch(i){if(i.code==="ENOENT")return;throw r}n.isDirectory()?nn(t,e,r):e.unlinkSync(t)}function rn(t,e,r,n){G(t),G(e),G(typeof n=="function"),e.rmdir(t,i=>{i&&(i.code==="ENOTEMPTY"||i.code==="EEXIST"||i.code==="EPERM")?wm(t,e,n):i&&i.code==="ENOTDIR"?n(r):n(i)})}function wm(t,e,r){G(t),G(e),G(typeof r=="function"),e.readdir(t,(n,i)=>{if(n)return r(n);let s=i.length,o;if(s===0)return e.rmdir(t,r);i.forEach(a=>{zi(Sc.join(t,a),e,u=>{if(!o){if(u)return r(o=u);--s===0&&e.rmdir(t,r)}})})})}function Cc(t,e){let r;e=e||{},Ec(e),G(t,"rimraf: missing path"),G.strictEqual(typeof t,"string","rimraf: path should be a string"),G(e,"rimraf: missing options"),G.strictEqual(typeof e,"object","rimraf: options should be object");try{r=e.lstatSync(t)}catch(n){if(n.code==="ENOENT")return;n.code==="EPERM"&&ir&&xc(t,e,n)}try{r&&r.isDirectory()?nn(t,e,null):e.unlinkSync(t)}catch(n){if(n.code==="ENOENT")return;if(n.code==="EPERM")return ir?xc(t,e,n):nn(t,e,n);if(n.code!=="EISDIR")throw n;nn(t,e,n)}}function nn(t,e,r){G(t),G(e);try{e.rmdirSync(t)}catch(n){if(n.code==="ENOTDIR")throw r;if(n.code==="ENOTEMPTY"||n.code==="EEXIST"||n.code==="EPERM")xm(t,e);else if(n.code!=="ENOENT")throw n}}function xm(t,e){if(G(t),G(e),e.readdirSync(t).forEach(r=>Cc(Sc.join(t,r),e)),ir){let r=Date.now();do try{return e.rmdirSync(t,e)}catch{}while(Date.now()-r<500)}else return e.rmdirSync(t,e)}Pc.exports=zi;zi.sync=Cc});var sr=y((e2,Ac)=>{"use strict";var Sm=we().fromCallback,Oc=Dc();Ac.exports={remove:Sm(Oc),removeSync:Oc.sync}});var Nc=y((t2,Tc)=>{"use strict";var Em=we().fromCallback,Fc=fe(),kc=require("path"),Mc=Ne(),qc=sr(),Ic=Em(function(e,r){r=r||function(){},Fc.readdir(e,(n,i)=>{if(n)return Mc.mkdirs(e,r);i=i.map(o=>kc.join(e,o)),s();function s(){let o=i.pop();if(!o)return r();qc.remove(o,a=>{if(a)return r(a);s()})}})});function Rc(t){let e;try{e=Fc.readdirSync(t)}catch{return Mc.mkdirsSync(t)}e.forEach(r=>{r=kc.join(t,r),qc.removeSync(r)})}Tc.exports={emptyDirSync:Rc,emptydirSync:Rc,emptyDir:Ic,emptydir:Ic}});var Bc=y((r2,$c)=>{"use strict";var Cm=we().fromCallback,jc=require("path"),Ke=fe(),Lc=Ne();function Pm(t,e){function r(){Ke.writeFile(t,"",n=>{if(n)return e(n);e()})}Ke.stat(t,(n,i)=>{if(!n&&i.isFile())return e();let s=jc.dirname(t);Ke.stat(s,(o,a)=>{if(o)return o.code==="ENOENT"?Lc.mkdirs(s,u=>{if(u)return e(u);r()}):e(o);a.isDirectory()?r():Ke.readdir(s,u=>{if(u)return e(u)})})})}function Dm(t){let e;try{e=Ke.statSync(t)}catch{}if(e&&e.isFile())return;let r=jc.dirname(t);try{Ke.statSync(r).isDirectory()||Ke.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")Lc.mkdirsSync(r);else throw n}Ke.writeFileSync(t,"")}$c.exports={createFile:Cm(Pm),createFileSync:Dm}});var Wc=y((n2,Gc)=>{"use strict";var Om=we().fromCallback,Xc=require("path"),lt=fe(),Hc=Ne(),Uc=Ve().pathExists;function Am(t,e,r){function n(i,s){lt.link(i,s,o=>{if(o)return r(o);r(null)})}Uc(e,(i,s)=>{if(i)return r(i);if(s)return r(null);lt.lstat(t,o=>{if(o)return o.message=o.message.replace("lstat","ensureLink"),r(o);let a=Xc.dirname(e);Uc(a,(u,h)=>{if(u)return r(u);if(h)return n(t,e);Hc.mkdirs(a,c=>{if(c)return r(c);n(t,e)})})})})}function Im(t,e){if(lt.existsSync(e))return;try{lt.lstatSync(t)}catch(s){throw s.message=s.message.replace("lstat","ensureLink"),s}let n=Xc.dirname(e);return lt.existsSync(n)||Hc.mkdirsSync(n),lt.linkSync(t,e)}Gc.exports={createLink:Om(Am),createLinkSync:Im}});var Jc=y((i2,zc)=>{"use strict";var Ye=require("path"),or=fe(),Rm=Ve().pathExists;function Fm(t,e,r){if(Ye.isAbsolute(t))return or.lstat(t,n=>n?(n.message=n.message.replace("lstat","ensureSymlink"),r(n)):r(null,{toCwd:t,toDst:t}));{let n=Ye.dirname(e),i=Ye.join(n,t);return Rm(i,(s,o)=>s?r(s):o?r(null,{toCwd:i,toDst:t}):or.lstat(t,a=>a?(a.message=a.message.replace("lstat","ensureSymlink"),r(a)):r(null,{toCwd:t,toDst:Ye.relative(n,t)})))}}function km(t,e){let r;if(Ye.isAbsolute(t)){if(r=or.existsSync(t),!r)throw new Error("absolute srcpath does not exist");return{toCwd:t,toDst:t}}else{let n=Ye.dirname(e),i=Ye.join(n,t);if(r=or.existsSync(i),r)return{toCwd:i,toDst:t};if(r=or.existsSync(t),!r)throw new Error("relative srcpath does not exist");return{toCwd:t,toDst:Ye.relative(n,t)}}}zc.exports={symlinkPaths:Fm,symlinkPathsSync:km}});var Yc=y((s2,Kc)=>{"use strict";var Vc=fe();function Mm(t,e,r){if(r=typeof e=="function"?e:r,e=typeof e=="function"?!1:e,e)return r(null,e);Vc.lstat(t,(n,i)=>{if(n)return r(null,"file");e=i&&i.isDirectory()?"dir":"file",r(null,e)})}function qm(t,e){let r;if(e)return e;try{r=Vc.lstatSync(t)}catch{return"file"}return r&&r.isDirectory()?"dir":"file"}Kc.exports={symlinkType:Mm,symlinkTypeSync:qm}});var il=y((o2,nl)=>{"use strict";var Tm=we().fromCallback,Zc=require("path"),It=fe(),el=Ne(),Nm=el.mkdirs,jm=el.mkdirsSync,tl=Jc(),Lm=tl.symlinkPaths,$m=tl.symlinkPathsSync,rl=Yc(),Bm=rl.symlinkType,Um=rl.symlinkTypeSync,Qc=Ve().pathExists;function Xm(t,e,r,n){n=typeof r=="function"?r:n,r=typeof r=="function"?!1:r,Qc(e,(i,s)=>{if(i)return n(i);if(s)return n(null);Lm(t,e,(o,a)=>{if(o)return n(o);t=a.toDst,Bm(a.toCwd,r,(u,h)=>{if(u)return n(u);let c=Zc.dirname(e);Qc(c,(p,g)=>{if(p)return n(p);if(g)return It.symlink(t,e,h,n);Nm(c,m=>{if(m)return n(m);It.symlink(t,e,h,n)})})})})})}function Hm(t,e,r){if(It.existsSync(e))return;let i=$m(t,e);t=i.toDst,r=Um(i.toCwd,r);let s=Zc.dirname(e);return It.existsSync(s)||jm(s),It.symlinkSync(t,e,r)}nl.exports={createSymlink:Tm(Xm),createSymlinkSync:Hm}});var ol=y((a2,sl)=>{"use strict";var sn=Bc(),on=Wc(),an=il();sl.exports={createFile:sn.createFile,createFileSync:sn.createFileSync,ensureFile:sn.createFile,ensureFileSync:sn.createFileSync,createLink:on.createLink,createLinkSync:on.createLinkSync,ensureLink:on.createLink,ensureLinkSync:on.createLinkSync,createSymlink:an.createSymlink,createSymlinkSync:an.createSymlinkSync,ensureSymlink:an.createSymlink,ensureSymlinkSync:an.createSymlinkSync}});var un=y((u2,al)=>{function Gm(t,{EOL:e=`
15
+ `,finalEOL:r=!0,replacer:n=null,spaces:i}={}){let s=r?e:"";return JSON.stringify(t,n,i).replace(/\n/g,e)+s}function Wm(t){return Buffer.isBuffer(t)&&(t=t.toString("utf8")),t.replace(/^\uFEFF/,"")}al.exports={stringify:Gm,stripBom:Wm}});var fl=y((c2,ll)=>{var Rt;try{Rt=fe()}catch{Rt=require("fs")}var cn=we(),{stringify:ul,stripBom:cl}=un();async function zm(t,e={}){typeof e=="string"&&(e={encoding:e});let r=e.fs||Rt,n="throws"in e?e.throws:!0,i=await cn.fromCallback(r.readFile)(t,e);i=cl(i);let s;try{s=JSON.parse(i,e?e.reviver:null)}catch(o){if(n)throw o.message=`${t}: ${o.message}`,o;return null}return s}var Jm=cn.fromPromise(zm);function Vm(t,e={}){typeof e=="string"&&(e={encoding:e});let r=e.fs||Rt,n="throws"in e?e.throws:!0;try{let i=r.readFileSync(t,e);return i=cl(i),JSON.parse(i,e.reviver)}catch(i){if(n)throw i.message=`${t}: ${i.message}`,i;return null}}async function Km(t,e,r={}){let n=r.fs||Rt,i=ul(e,r);await cn.fromCallback(n.writeFile)(t,i,r)}var Ym=cn.fromPromise(Km);function Qm(t,e,r={}){let n=r.fs||Rt,i=ul(e,r);return n.writeFileSync(t,i,r)}var Zm={readFile:Jm,readFileSync:Vm,writeFile:Ym,writeFileSync:Qm};ll.exports=Zm});var hl=y((l2,dl)=>{"use strict";var ln=fl();dl.exports={readJson:ln.readFile,readJsonSync:ln.readFileSync,writeJson:ln.writeFile,writeJsonSync:ln.writeFileSync}});var fn=y((f2,gl)=>{"use strict";var eg=we().fromCallback,ar=fe(),pl=require("path"),ml=Ne(),tg=Ve().pathExists;function rg(t,e,r,n){typeof r=="function"&&(n=r,r="utf8");let i=pl.dirname(t);tg(i,(s,o)=>{if(s)return n(s);if(o)return ar.writeFile(t,e,r,n);ml.mkdirs(i,a=>{if(a)return n(a);ar.writeFile(t,e,r,n)})})}function ng(t,...e){let r=pl.dirname(t);if(ar.existsSync(r))return ar.writeFileSync(t,...e);ml.mkdirsSync(r),ar.writeFileSync(t,...e)}gl.exports={outputFile:eg(rg),outputFileSync:ng}});var vl=y((d2,yl)=>{"use strict";var{stringify:ig}=un(),{outputFile:sg}=fn();async function og(t,e,r={}){let n=ig(e,r);await sg(t,n,r)}yl.exports=og});var _l=y((h2,bl)=>{"use strict";var{stringify:ag}=un(),{outputFileSync:ug}=fn();function cg(t,e,r){let n=ag(e,r);ug(t,n,r)}bl.exports=cg});var xl=y((p2,wl)=>{"use strict";var lg=we().fromPromise,ge=hl();ge.outputJson=lg(vl());ge.outputJsonSync=_l();ge.outputJSON=ge.outputJson;ge.outputJSONSync=ge.outputJsonSync;ge.writeJSON=ge.writeJson;ge.writeJSONSync=ge.writeJsonSync;ge.readJSON=ge.readJson;ge.readJSONSync=ge.readJsonSync;wl.exports=ge});var Ol=y((m2,Dl)=>{"use strict";var Cl=fe(),fg=require("path"),dg=Hi().copySync,Pl=sr().removeSync,hg=Ne().mkdirpSync,Sl=Zt();function pg(t,e,r){r=r||{};let n=r.overwrite||r.clobber||!1,{srcStat:i}=Sl.checkPathsSync(t,e,"move");return Sl.checkParentPathsSync(t,i,e,"move"),hg(fg.dirname(e)),mg(t,e,n)}function mg(t,e,r){if(r)return Pl(e),El(t,e,r);if(Cl.existsSync(e))throw new Error("dest already exists.");return El(t,e,r)}function El(t,e,r){try{Cl.renameSync(t,e)}catch(n){if(n.code!=="EXDEV")throw n;return gg(t,e,r)}}function gg(t,e,r){return dg(t,e,{overwrite:r,errorOnExist:!0}),Pl(t)}Dl.exports=pg});var Il=y((g2,Al)=>{"use strict";Al.exports={moveSync:Ol()}});var ql=y((y2,Ml)=>{"use strict";var yg=fe(),vg=require("path"),bg=Wi().copy,kl=sr().remove,_g=Ne().mkdirp,wg=Ve().pathExists,Rl=Zt();function xg(t,e,r,n){typeof r=="function"&&(n=r,r={});let i=r.overwrite||r.clobber||!1;Rl.checkPaths(t,e,"move",(s,o)=>{if(s)return n(s);let{srcStat:a}=o;Rl.checkParentPaths(t,a,e,"move",u=>{if(u)return n(u);_g(vg.dirname(e),h=>h?n(h):Sg(t,e,i,n))})})}function Sg(t,e,r,n){if(r)return kl(e,i=>i?n(i):Fl(t,e,r,n));wg(e,(i,s)=>i?n(i):s?n(new Error("dest already exists.")):Fl(t,e,r,n))}function Fl(t,e,r,n){yg.rename(t,e,i=>i?i.code!=="EXDEV"?n(i):Eg(t,e,r,n):n())}function Eg(t,e,r,n){bg(t,e,{overwrite:r,errorOnExist:!0},s=>s?n(s):kl(t,n))}Ml.exports=xg});var Nl=y((v2,Tl)=>{"use strict";var Cg=we().fromCallback;Tl.exports={move:Cg(ql())}});var Ft=y((b2,Ji)=>{"use strict";Ji.exports={...Qt(),...Hi(),...Wi(),...Nc(),...ol(),...xl(),...Ne(),...Il(),...Nl(),...fn(),...Ve(),...sr()};var jl=require("fs");Object.getOwnPropertyDescriptor(jl,"promises")&&Object.defineProperty(Ji.exports,"promises",{get(){return jl.promises}})});var zl=y((w2,Wl)=>{"use strict";Wl.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}});var Yi=y((x2,Vl)=>{var ur=zl(),Jl={};for(let t of Object.keys(ur))Jl[ur[t]]=t;var A={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};Vl.exports=A;for(let t of Object.keys(A)){if(!("channels"in A[t]))throw new Error("missing channels property: "+t);if(!("labels"in A[t]))throw new Error("missing channel labels property: "+t);if(A[t].labels.length!==A[t].channels)throw new Error("channel and label counts mismatch: "+t);let{channels:e,labels:r}=A[t];delete A[t].channels,delete A[t].labels,Object.defineProperty(A[t],"channels",{value:e}),Object.defineProperty(A[t],"labels",{value:r})}A.rgb.hsl=function(t){let e=t[0]/255,r=t[1]/255,n=t[2]/255,i=Math.min(e,r,n),s=Math.max(e,r,n),o=s-i,a,u;s===i?a=0:e===s?a=(r-n)/o:r===s?a=2+(n-e)/o:n===s&&(a=4+(e-r)/o),a=Math.min(a*60,360),a<0&&(a+=360);let h=(i+s)/2;return s===i?u=0:h<=.5?u=o/(s+i):u=o/(2-s-i),[a,u*100,h*100]};A.rgb.hsv=function(t){let e,r,n,i,s,o=t[0]/255,a=t[1]/255,u=t[2]/255,h=Math.max(o,a,u),c=h-Math.min(o,a,u),p=function(g){return(h-g)/6/c+1/2};return c===0?(i=0,s=0):(s=c/h,e=p(o),r=p(a),n=p(u),o===h?i=n-r:a===h?i=1/3+e-n:u===h&&(i=2/3+r-e),i<0?i+=1:i>1&&(i-=1)),[i*360,s*100,h*100]};A.rgb.hwb=function(t){let e=t[0],r=t[1],n=t[2],i=A.rgb.hsl(t)[0],s=1/255*Math.min(e,Math.min(r,n));return n=1-1/255*Math.max(e,Math.max(r,n)),[i,s*100,n*100]};A.rgb.cmyk=function(t){let e=t[0]/255,r=t[1]/255,n=t[2]/255,i=Math.min(1-e,1-r,1-n),s=(1-e-i)/(1-i)||0,o=(1-r-i)/(1-i)||0,a=(1-n-i)/(1-i)||0;return[s*100,o*100,a*100,i*100]};function Dg(t,e){return(t[0]-e[0])**2+(t[1]-e[1])**2+(t[2]-e[2])**2}A.rgb.keyword=function(t){let e=Jl[t];if(e)return e;let r=1/0,n;for(let i of Object.keys(ur)){let s=ur[i],o=Dg(t,s);o<r&&(r=o,n=i)}return n};A.keyword.rgb=function(t){return ur[t]};A.rgb.xyz=function(t){let e=t[0]/255,r=t[1]/255,n=t[2]/255;e=e>.04045?((e+.055)/1.055)**2.4:e/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92;let i=e*.4124+r*.3576+n*.1805,s=e*.2126+r*.7152+n*.0722,o=e*.0193+r*.1192+n*.9505;return[i*100,s*100,o*100]};A.rgb.lab=function(t){let e=A.rgb.xyz(t),r=e[0],n=e[1],i=e[2];r/=95.047,n/=100,i/=108.883,r=r>.008856?r**(1/3):7.787*r+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,i=i>.008856?i**(1/3):7.787*i+16/116;let s=116*n-16,o=500*(r-n),a=200*(n-i);return[s,o,a]};A.hsl.rgb=function(t){let e=t[0]/360,r=t[1]/100,n=t[2]/100,i,s,o;if(r===0)return o=n*255,[o,o,o];n<.5?i=n*(1+r):i=n+r-n*r;let a=2*n-i,u=[0,0,0];for(let h=0;h<3;h++)s=e+1/3*-(h-1),s<0&&s++,s>1&&s--,6*s<1?o=a+(i-a)*6*s:2*s<1?o=i:3*s<2?o=a+(i-a)*(2/3-s)*6:o=a,u[h]=o*255;return u};A.hsl.hsv=function(t){let e=t[0],r=t[1]/100,n=t[2]/100,i=r,s=Math.max(n,.01);n*=2,r*=n<=1?n:2-n,i*=s<=1?s:2-s;let o=(n+r)/2,a=n===0?2*i/(s+i):2*r/(n+r);return[e,a*100,o*100]};A.hsv.rgb=function(t){let e=t[0]/60,r=t[1]/100,n=t[2]/100,i=Math.floor(e)%6,s=e-Math.floor(e),o=255*n*(1-r),a=255*n*(1-r*s),u=255*n*(1-r*(1-s));switch(n*=255,i){case 0:return[n,u,o];case 1:return[a,n,o];case 2:return[o,n,u];case 3:return[o,a,n];case 4:return[u,o,n];case 5:return[n,o,a]}};A.hsv.hsl=function(t){let e=t[0],r=t[1]/100,n=t[2]/100,i=Math.max(n,.01),s,o;o=(2-r)*n;let a=(2-r)*i;return s=r*i,s/=a<=1?a:2-a,s=s||0,o/=2,[e,s*100,o*100]};A.hwb.rgb=function(t){let e=t[0]/360,r=t[1]/100,n=t[2]/100,i=r+n,s;i>1&&(r/=i,n/=i);let o=Math.floor(6*e),a=1-n;s=6*e-o,o&1&&(s=1-s);let u=r+s*(a-r),h,c,p;switch(o){default:case 6:case 0:h=a,c=u,p=r;break;case 1:h=u,c=a,p=r;break;case 2:h=r,c=a,p=u;break;case 3:h=r,c=u,p=a;break;case 4:h=u,c=r,p=a;break;case 5:h=a,c=r,p=u;break}return[h*255,c*255,p*255]};A.cmyk.rgb=function(t){let e=t[0]/100,r=t[1]/100,n=t[2]/100,i=t[3]/100,s=1-Math.min(1,e*(1-i)+i),o=1-Math.min(1,r*(1-i)+i),a=1-Math.min(1,n*(1-i)+i);return[s*255,o*255,a*255]};A.xyz.rgb=function(t){let e=t[0]/100,r=t[1]/100,n=t[2]/100,i,s,o;return i=e*3.2406+r*-1.5372+n*-.4986,s=e*-.9689+r*1.8758+n*.0415,o=e*.0557+r*-.204+n*1.057,i=i>.0031308?1.055*i**(1/2.4)-.055:i*12.92,s=s>.0031308?1.055*s**(1/2.4)-.055:s*12.92,o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92,i=Math.min(Math.max(0,i),1),s=Math.min(Math.max(0,s),1),o=Math.min(Math.max(0,o),1),[i*255,s*255,o*255]};A.xyz.lab=function(t){let e=t[0],r=t[1],n=t[2];e/=95.047,r/=100,n/=108.883,e=e>.008856?e**(1/3):7.787*e+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,n=n>.008856?n**(1/3):7.787*n+16/116;let i=116*r-16,s=500*(e-r),o=200*(r-n);return[i,s,o]};A.lab.xyz=function(t){let e=t[0],r=t[1],n=t[2],i,s,o;s=(e+16)/116,i=r/500+s,o=s-n/200;let a=s**3,u=i**3,h=o**3;return s=a>.008856?a:(s-16/116)/7.787,i=u>.008856?u:(i-16/116)/7.787,o=h>.008856?h:(o-16/116)/7.787,i*=95.047,s*=100,o*=108.883,[i,s,o]};A.lab.lch=function(t){let e=t[0],r=t[1],n=t[2],i;i=Math.atan2(n,r)*360/2/Math.PI,i<0&&(i+=360);let o=Math.sqrt(r*r+n*n);return[e,o,i]};A.lch.lab=function(t){let e=t[0],r=t[1],i=t[2]/360*2*Math.PI,s=r*Math.cos(i),o=r*Math.sin(i);return[e,s,o]};A.rgb.ansi16=function(t,e=null){let[r,n,i]=t,s=e===null?A.rgb.hsv(t)[2]:e;if(s=Math.round(s/50),s===0)return 30;let o=30+(Math.round(i/255)<<2|Math.round(n/255)<<1|Math.round(r/255));return s===2&&(o+=60),o};A.hsv.ansi16=function(t){return A.rgb.ansi16(A.hsv.rgb(t),t[2])};A.rgb.ansi256=function(t){let e=t[0],r=t[1],n=t[2];return e===r&&r===n?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5)};A.ansi16.rgb=function(t){let e=t%10;if(e===0||e===7)return t>50&&(e+=3.5),e=e/10.5*255,[e,e,e];let r=(~~(t>50)+1)*.5,n=(e&1)*r*255,i=(e>>1&1)*r*255,s=(e>>2&1)*r*255;return[n,i,s]};A.ansi256.rgb=function(t){if(t>=232){let s=(t-232)*10+8;return[s,s,s]}t-=16;let e,r=Math.floor(t/36)/5*255,n=Math.floor((e=t%36)/6)/5*255,i=e%6/5*255;return[r,n,i]};A.rgb.hex=function(t){let r=(((Math.round(t[0])&255)<<16)+((Math.round(t[1])&255)<<8)+(Math.round(t[2])&255)).toString(16).toUpperCase();return"000000".substring(r.length)+r};A.hex.rgb=function(t){let e=t.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!e)return[0,0,0];let r=e[0];e[0].length===3&&(r=r.split("").map(a=>a+a).join(""));let n=parseInt(r,16),i=n>>16&255,s=n>>8&255,o=n&255;return[i,s,o]};A.rgb.hcg=function(t){let e=t[0]/255,r=t[1]/255,n=t[2]/255,i=Math.max(Math.max(e,r),n),s=Math.min(Math.min(e,r),n),o=i-s,a,u;return o<1?a=s/(1-o):a=0,o<=0?u=0:i===e?u=(r-n)/o%6:i===r?u=2+(n-e)/o:u=4+(e-r)/o,u/=6,u%=1,[u*360,o*100,a*100]};A.hsl.hcg=function(t){let e=t[1]/100,r=t[2]/100,n=r<.5?2*e*r:2*e*(1-r),i=0;return n<1&&(i=(r-.5*n)/(1-n)),[t[0],n*100,i*100]};A.hsv.hcg=function(t){let e=t[1]/100,r=t[2]/100,n=e*r,i=0;return n<1&&(i=(r-n)/(1-n)),[t[0],n*100,i*100]};A.hcg.rgb=function(t){let e=t[0]/360,r=t[1]/100,n=t[2]/100;if(r===0)return[n*255,n*255,n*255];let i=[0,0,0],s=e%1*6,o=s%1,a=1-o,u=0;switch(Math.floor(s)){case 0:i[0]=1,i[1]=o,i[2]=0;break;case 1:i[0]=a,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=o;break;case 3:i[0]=0,i[1]=a,i[2]=1;break;case 4:i[0]=o,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=a}return u=(1-r)*n,[(r*i[0]+u)*255,(r*i[1]+u)*255,(r*i[2]+u)*255]};A.hcg.hsv=function(t){let e=t[1]/100,r=t[2]/100,n=e+r*(1-e),i=0;return n>0&&(i=e/n),[t[0],i*100,n*100]};A.hcg.hsl=function(t){let e=t[1]/100,n=t[2]/100*(1-e)+.5*e,i=0;return n>0&&n<.5?i=e/(2*n):n>=.5&&n<1&&(i=e/(2*(1-n))),[t[0],i*100,n*100]};A.hcg.hwb=function(t){let e=t[1]/100,r=t[2]/100,n=e+r*(1-e);return[t[0],(n-e)*100,(1-n)*100]};A.hwb.hcg=function(t){let e=t[1]/100,n=1-t[2]/100,i=n-e,s=0;return i<1&&(s=(n-i)/(1-i)),[t[0],i*100,s*100]};A.apple.rgb=function(t){return[t[0]/65535*255,t[1]/65535*255,t[2]/65535*255]};A.rgb.apple=function(t){return[t[0]/255*65535,t[1]/255*65535,t[2]/255*65535]};A.gray.rgb=function(t){return[t[0]/100*255,t[0]/100*255,t[0]/100*255]};A.gray.hsl=function(t){return[0,0,t[0]]};A.gray.hsv=A.gray.hsl;A.gray.hwb=function(t){return[0,100,t[0]]};A.gray.cmyk=function(t){return[0,0,0,t[0]]};A.gray.lab=function(t){return[t[0],0,0]};A.gray.hex=function(t){let e=Math.round(t[0]/100*255)&255,n=((e<<16)+(e<<8)+e).toString(16).toUpperCase();return"000000".substring(n.length)+n};A.rgb.gray=function(t){return[(t[0]+t[1]+t[2])/3/255*100]}});var Yl=y((S2,Kl)=>{var pn=Yi();function Og(){let t={},e=Object.keys(pn);for(let r=e.length,n=0;n<r;n++)t[e[n]]={distance:-1,parent:null};return t}function Ag(t){let e=Og(),r=[t];for(e[t].distance=0;r.length;){let n=r.pop(),i=Object.keys(pn[n]);for(let s=i.length,o=0;o<s;o++){let a=i[o],u=e[a];u.distance===-1&&(u.distance=e[n].distance+1,u.parent=n,r.unshift(a))}}return e}function Ig(t,e){return function(r){return e(t(r))}}function Rg(t,e){let r=[e[t].parent,t],n=pn[e[t].parent][t],i=e[t].parent;for(;e[i].parent;)r.unshift(e[i].parent),n=Ig(pn[e[i].parent][i],n),i=e[i].parent;return n.conversion=r,n}Kl.exports=function(t){let e=Ag(t),r={},n=Object.keys(e);for(let i=n.length,s=0;s<i;s++){let o=n[s];e[o].parent!==null&&(r[o]=Rg(o,e))}return r}});var Zl=y((E2,Ql)=>{var Qi=Yi(),Fg=Yl(),kt={},kg=Object.keys(Qi);function Mg(t){let e=function(...r){let n=r[0];return n==null?n:(n.length>1&&(r=n),t(r))};return"conversion"in t&&(e.conversion=t.conversion),e}function qg(t){let e=function(...r){let n=r[0];if(n==null)return n;n.length>1&&(r=n);let i=t(r);if(typeof i=="object")for(let s=i.length,o=0;o<s;o++)i[o]=Math.round(i[o]);return i};return"conversion"in t&&(e.conversion=t.conversion),e}kg.forEach(t=>{kt[t]={},Object.defineProperty(kt[t],"channels",{value:Qi[t].channels}),Object.defineProperty(kt[t],"labels",{value:Qi[t].labels});let e=Fg(t);Object.keys(e).forEach(n=>{let i=e[n];kt[t][n]=qg(i),kt[t][n].raw=Mg(i)})});Ql.exports=kt});var of=y((C2,sf)=>{"use strict";var ef=(t,e)=>(...r)=>`\x1B[${t(...r)+e}m`,tf=(t,e)=>(...r)=>{let n=t(...r);return`\x1B[${38+e};5;${n}m`},rf=(t,e)=>(...r)=>{let n=t(...r);return`\x1B[${38+e};2;${n[0]};${n[1]};${n[2]}m`},mn=t=>t,nf=(t,e,r)=>[t,e,r],Mt=(t,e,r)=>{Object.defineProperty(t,e,{get:()=>{let n=r();return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0}),n},enumerable:!0,configurable:!0})},Zi,qt=(t,e,r,n)=>{Zi===void 0&&(Zi=Zl());let i=n?10:0,s={};for(let[o,a]of Object.entries(Zi)){let u=o==="ansi16"?"ansi":o;o===e?s[u]=t(r,i):typeof a=="object"&&(s[u]=t(a[e],i))}return s};function Tg(){let t=new Map,e={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};e.color.gray=e.color.blackBright,e.bgColor.bgGray=e.bgColor.bgBlackBright,e.color.grey=e.color.blackBright,e.bgColor.bgGrey=e.bgColor.bgBlackBright;for(let[r,n]of Object.entries(e)){for(let[i,s]of Object.entries(n))e[i]={open:`\x1B[${s[0]}m`,close:`\x1B[${s[1]}m`},n[i]=e[i],t.set(s[0],s[1]);Object.defineProperty(e,r,{value:n,enumerable:!1})}return Object.defineProperty(e,"codes",{value:t,enumerable:!1}),e.color.close="\x1B[39m",e.bgColor.close="\x1B[49m",Mt(e.color,"ansi",()=>qt(ef,"ansi16",mn,!1)),Mt(e.color,"ansi256",()=>qt(tf,"ansi256",mn,!1)),Mt(e.color,"ansi16m",()=>qt(rf,"rgb",nf,!1)),Mt(e.bgColor,"ansi",()=>qt(ef,"ansi16",mn,!0)),Mt(e.bgColor,"ansi256",()=>qt(tf,"ansi256",mn,!0)),Mt(e.bgColor,"ansi16m",()=>qt(rf,"rgb",nf,!0)),e}Object.defineProperty(sf,"exports",{enumerable:!0,get:Tg})});var uf=y((P2,af)=>{"use strict";var Ng=(t,e,r)=>{let n=t.indexOf(e);if(n===-1)return t;let i=e.length,s=0,o="";do o+=t.substr(s,n-s)+e+r,s=n+i,n=t.indexOf(e,s);while(n!==-1);return o+=t.substr(s),o},jg=(t,e,r,n)=>{let i=0,s="";do{let o=t[n-1]==="\r";s+=t.substr(i,(o?n-1:n)-i)+e+(o?`\r
16
16
  `:`
17
- `)+r,i=n+1,n=e.indexOf(`
18
- `,i)}while(n!==-1);return s+=e.substr(i),s};wu.exports={stringReplaceAll:ep,stringEncaseCRLFWithFirstIndex:tp}});var Cu=v((Mm,ku)=>{"use strict";var rp=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,xu=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,np=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,ip=/\\(u(?:[a-f\d]{4}|{[a-f\d]{1,6}})|x[a-f\d]{2}|.)|([^\\])/gi,sp=new Map([["n",`
19
- `],["r","\r"],["t"," "],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e","\x1B"],["a","\x07"]]);function Su(e){let t=e[0]==="u",r=e[1]==="{";return t&&!r&&e.length===5||e[0]==="x"&&e.length===3?String.fromCharCode(parseInt(e.slice(1),16)):t&&r?String.fromCodePoint(parseInt(e.slice(2,-1),16)):sp.get(e)||e}function op(e,t){let r=[],n=t.trim().split(/\s*,\s*/g),i;for(let s of n){let o=Number(s);if(!Number.isNaN(o))r.push(o);else if(i=s.match(np))r.push(i[2].replace(ip,(a,c,d)=>c?Su(c):d));else throw new Error(`Invalid Chalk template style argument: ${s} (in style '${e}')`)}return r}function ap(e){xu.lastIndex=0;let t=[],r;for(;(r=xu.exec(e))!==null;){let n=r[1];if(r[2]){let i=op(n,r[2]);t.push([n].concat(i))}else t.push([n])}return t}function Eu(e,t){let r={};for(let i of t)for(let s of i.styles)r[s[0]]=i.inverse?null:s.slice(1);let n=e;for(let[i,s]of Object.entries(r))if(Array.isArray(s)){if(!(i in n))throw new Error(`Unknown Chalk style: ${i}`);n=s.length>0?n[i](...s):n[i]}return n}ku.exports=(e,t)=>{let r=[],n=[],i=[];if(t.replace(rp,(s,o,a,c,d,f)=>{if(o)i.push(Su(o));else if(c){let p=i.join("");i=[],n.push(r.length===0?p:Eu(e,r)(p)),r.push({inverse:a,styles:ap(c)})}else if(d){if(r.length===0)throw new Error("Found extraneous } in Chalk template literal");n.push(Eu(e,r)(i.join(""))),i=[],r.pop()}else i.push(f)}),n.push(i.join("")),r.length>0){let s=`Chalk template literal is missing ${r.length} closing bracket${r.length===1?"":"s"} (\`}\`)`;throw new Error(s)}return n.join("")}});var Fu=v((Fm,Mu)=>{"use strict";var Tt=bu(),{stdout:ti,stderr:ri}=qn(),{stringReplaceAll:cp,stringEncaseCRLFWithFirstIndex:up}=_u(),{isArray:Mr}=Array,Ou=["ansi","ansi","ansi256","ansi16m"],ht=Object.create(null),lp=(e,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");let r=ti?ti.level:0;e.level=t.level===void 0?r:t.level},ni=class{constructor(t){return Au(t)}},Au=e=>{let t={};return lp(t,e),t.template=(...r)=>qu(t.template,...r),Object.setPrototypeOf(t,Fr.prototype),Object.setPrototypeOf(t.template,t),t.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")},t.template.Instance=ni,t.template};function Fr(e){return Au(e)}for(let[e,t]of Object.entries(Tt))ht[e]={get(){let r=Tr(this,ii(t.open,t.close,this._styler),this._isEmpty);return Object.defineProperty(this,e,{value:r}),r}};ht.visible={get(){let e=Tr(this,this._styler,!0);return Object.defineProperty(this,"visible",{value:e}),e}};var Pu=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(let e of Pu)ht[e]={get(){let{level:t}=this;return function(...r){let n=ii(Tt.color[Ou[t]][e](...r),Tt.color.close,this._styler);return Tr(this,n,this._isEmpty)}}};for(let e of Pu){let t="bg"+e[0].toUpperCase()+e.slice(1);ht[t]={get(){let{level:r}=this;return function(...n){let i=ii(Tt.bgColor[Ou[r]][e](...n),Tt.bgColor.close,this._styler);return Tr(this,i,this._isEmpty)}}}}var fp=Object.defineProperties(()=>{},{...ht,level:{enumerable:!0,get(){return this._generator.level},set(e){this._generator.level=e}}}),ii=(e,t,r)=>{let n,i;return r===void 0?(n=e,i=t):(n=r.openAll+e,i=t+r.closeAll),{open:e,close:t,openAll:n,closeAll:i,parent:r}},Tr=(e,t,r)=>{let n=(...i)=>Mr(i[0])&&Mr(i[0].raw)?Ru(n,qu(n,...i)):Ru(n,i.length===1?""+i[0]:i.join(" "));return Object.setPrototypeOf(n,fp),n._generator=e,n._styler=t,n._isEmpty=r,n},Ru=(e,t)=>{if(e.level<=0||!t)return e._isEmpty?"":t;let r=e._styler;if(r===void 0)return t;let{openAll:n,closeAll:i}=r;if(t.indexOf("\x1B")!==-1)for(;r!==void 0;)t=cp(t,r.close,r.open),r=r.parent;let s=t.indexOf(`
20
- `);return s!==-1&&(t=up(t,i,n,s)),n+t+i},ei,qu=(e,...t)=>{let[r]=t;if(!Mr(r)||!Mr(r.raw))return t.join(" ");let n=t.slice(1),i=[r.raw[0]];for(let s=1;s<r.length;s++)i.push(String(n[s-1]).replace(/[{}\\]/g,"\\$&"),String(r.raw[s]));return ei===void 0&&(ei=Cu()),ei(e,i.join(""))};Object.defineProperties(Fr.prototype,ht);var Ir=Fr();Ir.supportsColor=ti;Ir.stderr=Fr({level:ri?ri.level:0});Ir.stderr.supportsColor=ri;Mu.exports=Ir});var Tu=v((si,oi)=>{(function(e,t){typeof si=="object"&&typeof oi<"u"?oi.exports=t():typeof define=="function"&&define.amd?define(t):(e=typeof globalThis<"u"?globalThis:e||self,e.tinycolor=t())})(si,function(){"use strict";function e(u){return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(h){return typeof h}:function(h){return h&&typeof Symbol=="function"&&h.constructor===Symbol&&h!==Symbol.prototype?"symbol":typeof h},e(u)}var t=/^\s+/,r=/\s+$/;function n(u,h){if(u=u||"",h=h||{},u instanceof n)return u;if(!(this instanceof n))return new n(u,h);var l=i(u);this._originalInput=u,this._r=l.r,this._g=l.g,this._b=l.b,this._a=l.a,this._roundA=Math.round(100*this._a)/100,this._format=h.format||l.format,this._gradientType=h.gradientType,this._r<1&&(this._r=Math.round(this._r)),this._g<1&&(this._g=Math.round(this._g)),this._b<1&&(this._b=Math.round(this._b)),this._ok=l.ok}n.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var h=this.toRgb();return(h.r*299+h.g*587+h.b*114)/1e3},getLuminance:function(){var h=this.toRgb(),l,g,w,b,j,B;return l=h.r/255,g=h.g/255,w=h.b/255,l<=.03928?b=l/12.92:b=Math.pow((l+.055)/1.055,2.4),g<=.03928?j=g/12.92:j=Math.pow((g+.055)/1.055,2.4),w<=.03928?B=w/12.92:B=Math.pow((w+.055)/1.055,2.4),.2126*b+.7152*j+.0722*B},setAlpha:function(h){return this._a=G(h),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var h=c(this._r,this._g,this._b);return{h:h.h*360,s:h.s,v:h.v,a:this._a}},toHsvString:function(){var h=c(this._r,this._g,this._b),l=Math.round(h.h*360),g=Math.round(h.s*100),w=Math.round(h.v*100);return this._a==1?"hsv("+l+", "+g+"%, "+w+"%)":"hsva("+l+", "+g+"%, "+w+"%, "+this._roundA+")"},toHsl:function(){var h=o(this._r,this._g,this._b);return{h:h.h*360,s:h.s,l:h.l,a:this._a}},toHslString:function(){var h=o(this._r,this._g,this._b),l=Math.round(h.h*360),g=Math.round(h.s*100),w=Math.round(h.l*100);return this._a==1?"hsl("+l+", "+g+"%, "+w+"%)":"hsla("+l+", "+g+"%, "+w+"%, "+this._roundA+")"},toHex:function(h){return f(this._r,this._g,this._b,h)},toHexString:function(h){return"#"+this.toHex(h)},toHex8:function(h){return p(this._r,this._g,this._b,this._a,h)},toHex8String:function(h){return"#"+this.toHex8(h)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(q(this._r,255)*100)+"%",g:Math.round(q(this._g,255)*100)+"%",b:Math.round(q(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(q(this._r,255)*100)+"%, "+Math.round(q(this._g,255)*100)+"%, "+Math.round(q(this._b,255)*100)+"%)":"rgba("+Math.round(q(this._r,255)*100)+"%, "+Math.round(q(this._g,255)*100)+"%, "+Math.round(q(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:D[f(this._r,this._g,this._b,!0)]||!1},toFilter:function(h){var l="#"+y(this._r,this._g,this._b,this._a),g=l,w=this._gradientType?"GradientType = 1, ":"";if(h){var b=n(h);g="#"+y(b._r,b._g,b._b,b._a)}return"progid:DXImageTransform.Microsoft.gradient("+w+"startColorstr="+l+",endColorstr="+g+")"},toString:function(h){var l=!!h;h=h||this._format;var g=!1,w=this._a<1&&this._a>=0,b=!l&&w&&(h==="hex"||h==="hex6"||h==="hex3"||h==="hex4"||h==="hex8"||h==="name");return b?h==="name"&&this._a===0?this.toName():this.toRgbString():(h==="rgb"&&(g=this.toRgbString()),h==="prgb"&&(g=this.toPercentageRgbString()),(h==="hex"||h==="hex6")&&(g=this.toHexString()),h==="hex3"&&(g=this.toHexString(!0)),h==="hex4"&&(g=this.toHex8String(!0)),h==="hex8"&&(g=this.toHex8String()),h==="name"&&(g=this.toName()),h==="hsl"&&(g=this.toHslString()),h==="hsv"&&(g=this.toHsvString()),g||this.toHexString())},clone:function(){return n(this.toString())},_applyModification:function(h,l){var g=h.apply(null,[this].concat([].slice.call(l)));return this._r=g._r,this._g=g._g,this._b=g._b,this.setAlpha(g._a),this},lighten:function(){return this._applyModification(P,arguments)},brighten:function(){return this._applyModification(N,arguments)},darken:function(){return this._applyModification(U,arguments)},desaturate:function(){return this._applyModification(m,arguments)},saturate:function(){return this._applyModification(_,arguments)},greyscale:function(){return this._applyModification(A,arguments)},spin:function(){return this._applyModification(W,arguments)},_applyCombination:function(h,l){return h.apply(null,[this].concat([].slice.call(l)))},analogous:function(){return this._applyCombination(ye,arguments)},complement:function(){return this._applyCombination(x,arguments)},monochromatic:function(){return this._applyCombination(Q,arguments)},splitcomplement:function(){return this._applyCombination(M,arguments)},triad:function(){return this._applyCombination(k,[3])},tetrad:function(){return this._applyCombination(k,[4])}},n.fromRatio=function(u,h){if(e(u)=="object"){var l={};for(var g in u)u.hasOwnProperty(g)&&(g==="a"?l[g]=u[g]:l[g]=F(u[g]));u=l}return n(u,h)};function i(u){var h={r:0,g:0,b:0},l=1,g=null,w=null,b=null,j=!1,B=!1;return typeof u=="string"&&(u=Dt(u)),e(u)=="object"&&(ge(u.r)&&ge(u.g)&&ge(u.b)?(h=s(u.r,u.g,u.b),j=!0,B=String(u.r).substr(-1)==="%"?"prgb":"rgb"):ge(u.h)&&ge(u.s)&&ge(u.v)?(g=F(u.s),w=F(u.v),h=d(u.h,g,w),j=!0,B="hsv"):ge(u.h)&&ge(u.s)&&ge(u.l)&&(g=F(u.s),b=F(u.l),h=a(u.h,g,b),j=!0,B="hsl"),u.hasOwnProperty("a")&&(l=u.a)),l=G(l),{ok:j,format:u.format||B,r:Math.min(255,Math.max(h.r,0)),g:Math.min(255,Math.max(h.g,0)),b:Math.min(255,Math.max(h.b,0)),a:l}}function s(u,h,l){return{r:q(u,255)*255,g:q(h,255)*255,b:q(l,255)*255}}function o(u,h,l){u=q(u,255),h=q(h,255),l=q(l,255);var g=Math.max(u,h,l),w=Math.min(u,h,l),b,j,B=(g+w)/2;if(g==w)b=j=0;else{var J=g-w;switch(j=B>.5?J/(2-g-w):J/(g+w),g){case u:b=(h-l)/J+(h<l?6:0);break;case h:b=(l-u)/J+2;break;case l:b=(u-h)/J+4;break}b/=6}return{h:b,s:j,l:B}}function a(u,h,l){var g,w,b;u=q(u,360),h=q(h,100),l=q(l,100);function j(be,pt,xe){return xe<0&&(xe+=1),xe>1&&(xe-=1),xe<1/6?be+(pt-be)*6*xe:xe<1/2?pt:xe<2/3?be+(pt-be)*(2/3-xe)*6:be}if(h===0)g=w=b=l;else{var B=l<.5?l*(1+h):l+h-l*h,J=2*l-B;g=j(J,B,u+1/3),w=j(J,B,u),b=j(J,B,u-1/3)}return{r:g*255,g:w*255,b:b*255}}function c(u,h,l){u=q(u,255),h=q(h,255),l=q(l,255);var g=Math.max(u,h,l),w=Math.min(u,h,l),b,j,B=g,J=g-w;if(j=g===0?0:J/g,g==w)b=0;else{switch(g){case u:b=(h-l)/J+(h<l?6:0);break;case h:b=(l-u)/J+2;break;case l:b=(u-h)/J+4;break}b/=6}return{h:b,s:j,v:B}}function d(u,h,l){u=q(u,360)*6,h=q(h,100),l=q(l,100);var g=Math.floor(u),w=u-g,b=l*(1-h),j=l*(1-w*h),B=l*(1-(1-w)*h),J=g%6,be=[l,j,b,b,B,l][J],pt=[B,l,l,j,b,b][J],xe=[b,b,B,l,l,j][J];return{r:be*255,g:pt*255,b:xe*255}}function f(u,h,l,g){var w=[C(Math.round(u).toString(16)),C(Math.round(h).toString(16)),C(Math.round(l).toString(16))];return g&&w[0].charAt(0)==w[0].charAt(1)&&w[1].charAt(0)==w[1].charAt(1)&&w[2].charAt(0)==w[2].charAt(1)?w[0].charAt(0)+w[1].charAt(0)+w[2].charAt(0):w.join("")}function p(u,h,l,g,w){var b=[C(Math.round(u).toString(16)),C(Math.round(h).toString(16)),C(Math.round(l).toString(16)),C(Oe(g))];return w&&b[0].charAt(0)==b[0].charAt(1)&&b[1].charAt(0)==b[1].charAt(1)&&b[2].charAt(0)==b[2].charAt(1)&&b[3].charAt(0)==b[3].charAt(1)?b[0].charAt(0)+b[1].charAt(0)+b[2].charAt(0)+b[3].charAt(0):b.join("")}function y(u,h,l,g){var w=[C(Oe(g)),C(Math.round(u).toString(16)),C(Math.round(h).toString(16)),C(Math.round(l).toString(16))];return w.join("")}n.equals=function(u,h){return!u||!h?!1:n(u).toRgbString()==n(h).toRgbString()},n.random=function(){return n.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function m(u,h){h=h===0?0:h||10;var l=n(u).toHsl();return l.s-=h/100,l.s=H(l.s),n(l)}function _(u,h){h=h===0?0:h||10;var l=n(u).toHsl();return l.s+=h/100,l.s=H(l.s),n(l)}function A(u){return n(u).desaturate(100)}function P(u,h){h=h===0?0:h||10;var l=n(u).toHsl();return l.l+=h/100,l.l=H(l.l),n(l)}function N(u,h){h=h===0?0:h||10;var l=n(u).toRgb();return l.r=Math.max(0,Math.min(255,l.r-Math.round(255*-(h/100)))),l.g=Math.max(0,Math.min(255,l.g-Math.round(255*-(h/100)))),l.b=Math.max(0,Math.min(255,l.b-Math.round(255*-(h/100)))),n(l)}function U(u,h){h=h===0?0:h||10;var l=n(u).toHsl();return l.l-=h/100,l.l=H(l.l),n(l)}function W(u,h){var l=n(u).toHsl(),g=(l.h+h)%360;return l.h=g<0?360+g:g,n(l)}function x(u){var h=n(u).toHsl();return h.h=(h.h+180)%360,n(h)}function k(u,h){if(isNaN(h)||h<=0)throw new Error("Argument to polyad must be a positive number");for(var l=n(u).toHsl(),g=[n(u)],w=360/h,b=1;b<h;b++)g.push(n({h:(l.h+b*w)%360,s:l.s,l:l.l}));return g}function M(u){var h=n(u).toHsl(),l=h.h;return[n(u),n({h:(l+72)%360,s:h.s,l:h.l}),n({h:(l+216)%360,s:h.s,l:h.l})]}function ye(u,h,l){h=h||6,l=l||30;var g=n(u).toHsl(),w=360/l,b=[n(u)];for(g.h=(g.h-(w*h>>1)+720)%360;--h;)g.h=(g.h+w)%360,b.push(n(g));return b}function Q(u,h){h=h||6;for(var l=n(u).toHsv(),g=l.h,w=l.s,b=l.v,j=[],B=1/h;h--;)j.push(n({h:g,s:w,v:b})),b=(b+B)%1;return j}n.mix=function(u,h,l){l=l===0?0:l||50;var g=n(u).toRgb(),w=n(h).toRgb(),b=l/100,j={r:(w.r-g.r)*b+g.r,g:(w.g-g.g)*b+g.g,b:(w.b-g.b)*b+g.b,a:(w.a-g.a)*b+g.a};return n(j)},n.readability=function(u,h){var l=n(u),g=n(h);return(Math.max(l.getLuminance(),g.getLuminance())+.05)/(Math.min(l.getLuminance(),g.getLuminance())+.05)},n.isReadable=function(u,h,l){var g=n.readability(u,h),w,b;switch(b=!1,w=ve(l),w.level+w.size){case"AAsmall":case"AAAlarge":b=g>=4.5;break;case"AAlarge":b=g>=3;break;case"AAAsmall":b=g>=7;break}return b},n.mostReadable=function(u,h,l){var g=null,w=0,b,j,B,J;l=l||{},j=l.includeFallbackColors,B=l.level,J=l.size;for(var be=0;be<h.length;be++)b=n.readability(u,h[be]),b>w&&(w=b,g=n(h[be]));return n.isReadable(u,g,{level:B,size:J})||!j?g:(l.includeFallbackColors=!1,n.mostReadable(u,["#fff","#000"],l))};var R=n.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},D=n.hexNames=T(R);function T(u){var h={};for(var l in u)u.hasOwnProperty(l)&&(h[u[l]]=l);return h}function G(u){return u=parseFloat(u),(isNaN(u)||u<0||u>1)&&(u=1),u}function q(u,h){$(u)&&(u="100%");var l=I(u);return u=Math.min(h,Math.max(0,parseFloat(u))),l&&(u=parseInt(u*h,10)/100),Math.abs(u-h)<1e-6?1:u%h/parseFloat(h)}function H(u){return Math.min(1,Math.max(0,u))}function O(u){return parseInt(u,16)}function $(u){return typeof u=="string"&&u.indexOf(".")!=-1&&parseFloat(u)===1}function I(u){return typeof u=="string"&&u.indexOf("%")!=-1}function C(u){return u.length==1?"0"+u:""+u}function F(u){return u<=1&&(u=u*100+"%"),u}function Oe(u){return Math.round(parseFloat(u)*255).toString(16)}function je(u){return O(u)/255}var le=function(){var u="[-\\+]?\\d+%?",h="[-\\+]?\\d*\\.\\d+%?",l="(?:"+h+")|(?:"+u+")",g="[\\s|\\(]+("+l+")[,|\\s]+("+l+")[,|\\s]+("+l+")\\s*\\)?",w="[\\s|\\(]+("+l+")[,|\\s]+("+l+")[,|\\s]+("+l+")[,|\\s]+("+l+")\\s*\\)?";return{CSS_UNIT:new RegExp(l),rgb:new RegExp("rgb"+g),rgba:new RegExp("rgba"+w),hsl:new RegExp("hsl"+g),hsla:new RegExp("hsla"+w),hsv:new RegExp("hsv"+g),hsva:new RegExp("hsva"+w),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function ge(u){return!!le.CSS_UNIT.exec(u)}function Dt(u){u=u.replace(t,"").replace(r,"").toLowerCase();var h=!1;if(R[u])u=R[u],h=!0;else if(u=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var l;return(l=le.rgb.exec(u))?{r:l[1],g:l[2],b:l[3]}:(l=le.rgba.exec(u))?{r:l[1],g:l[2],b:l[3],a:l[4]}:(l=le.hsl.exec(u))?{h:l[1],s:l[2],l:l[3]}:(l=le.hsla.exec(u))?{h:l[1],s:l[2],l:l[3],a:l[4]}:(l=le.hsv.exec(u))?{h:l[1],s:l[2],v:l[3]}:(l=le.hsva.exec(u))?{h:l[1],s:l[2],v:l[3],a:l[4]}:(l=le.hex8.exec(u))?{r:O(l[1]),g:O(l[2]),b:O(l[3]),a:je(l[4]),format:h?"name":"hex8"}:(l=le.hex6.exec(u))?{r:O(l[1]),g:O(l[2]),b:O(l[3]),format:h?"name":"hex"}:(l=le.hex4.exec(u))?{r:O(l[1]+""+l[1]),g:O(l[2]+""+l[2]),b:O(l[3]+""+l[3]),a:je(l[4]+""+l[4]),format:h?"name":"hex8"}:(l=le.hex3.exec(u))?{r:O(l[1]+""+l[1]),g:O(l[2]+""+l[2]),b:O(l[3]+""+l[3]),format:h?"name":"hex"}:!1}function ve(u){var h,l;return u=u||{level:"AA",size:"small"},h=(u.level||"AA").toUpperCase(),l=(u.size||"small").toLowerCase(),h!=="AA"&&h!=="AAA"&&(h="AA"),l!=="small"&&l!=="large"&&(l="small"),{level:h,size:l}}return n})});var Lu=v((Tm,Bu)=>{var It=Tu(),ju={r:256,g:256,b:256,a:1},$u={h:360,s:1,v:1,a:1};function ci(e,t,r){let n={};for(let i in e)e.hasOwnProperty(i)&&(n[i]=r===0?0:(t[i]-e[i])/r);return n}function ui(e,t,r,n){let i={};for(let s in t)t.hasOwnProperty(s)&&(i[s]=e[s]*r+t[s],i[s]=i[s]<0?i[s]+n[s]:n[s]!==1?i[s]%n[s]:i[s]);return i}function ai(e,t,r){let n=e.color.toRgb(),i=t.color.toRgb(),s=ci(n,i,r),o=[e.color];for(let a=1;a<r;a++){let c=ui(s,n,a,ju);o.push(It(c))}return o}function Iu(e,t,r,n){let i=e.color.toHsv(),s=t.color.toHsv();if(i.s===0||s.s===0)return ai(e,t,r);let o;if(typeof n=="boolean")o=n;else{let f=i.h<s.h&&s.h-i.h<180||i.h>s.h&&i.h-s.h>180;o=n==="long"&&f||n==="short"&&!f}let a=ci(i,s,r),c=[e.color],d;i.h<=s.h&&!o||i.h>=s.h&&o?d=s.h-i.h:o?d=360-s.h+i.h:d=360-i.h+s.h,a.h=Math.pow(-1,o?1:0)*Math.abs(d)/r;for(let f=1;f<r;f++){let p=ui(a,i,f,$u);c.push(It(p))}return c}function Nu(e,t){let r=e.length;if(t=parseInt(t,10),isNaN(t)||t<2)throw new Error("Invalid number of steps (< 2)");if(t<r)throw new Error("Number of steps cannot be inferior to number of stops");let n=[];for(let s=1;s<r;s++){let o=(t-1)*(e[s].pos-e[s-1].pos);n.push(Math.max(1,Math.round(o)))}let i=1;for(let s=r-1;s--;)i+=n[s];for(;i!==t;)if(i<t){let s=Math.min.apply(null,n);n[n.indexOf(s)]++,i++}else{let s=Math.max.apply(null,n);n[n.indexOf(s)]--,i--}return n}function Du(e,t,r,n){if(t<0||t>1)throw new Error("Position must be between 0 and 1");let i,s;for(let c=0,d=e.length;c<d-1;c++)if(t>=e[c].pos&&t<e[c+1].pos){i=e[c],s=e[c+1];break}i||(i=s=e[e.length-1]);let o=ci(i.color[r](),s.color[r](),(s.pos-i.pos)*100),a=ui(o,i.color[r](),(t-i.pos)*100,n);return It(a)}var dt=class{constructor(t){if(t.length<2)throw new Error("Invalid number of stops (< 2)");let r=t[0].pos!==void 0,n=t.length,i=-1,s=!1;this.stops=t.map((o,a)=>{let c=o.pos!==void 0;if(r^c)throw new Error("Cannot mix positionned and not posionned color stops");if(c){let d=o.color!==void 0;if(!d&&(s||a===0||a===n-1))throw new Error("Cannot define two consecutive position-only stops");if(s=!d,o={color:d?It(o.color):null,colorLess:!d,pos:o.pos},o.pos<0||o.pos>1)throw new Error("Color stops positions must be between 0 and 1");if(o.pos<i)throw new Error("Color stops positions are not ordered");i=o.pos}else o={color:It(o.color!==void 0?o.color:o),pos:a/(n-1)};return o}),this.stops[0].pos!==0&&(this.stops.unshift({color:this.stops[0].color,pos:0}),n++),this.stops[n-1].pos!==1&&this.stops.push({color:this.stops[n-1].color,pos:1})}reverse(){let t=[];return this.stops.forEach(function(r){t.push({color:r.color,pos:1-r.pos})}),new dt(t.reverse())}loop(){let t=[],r=[];return this.stops.forEach(n=>{t.push({color:n.color,pos:n.pos/2})}),this.stops.slice(0,-1).forEach(n=>{r.push({color:n.color,pos:1-n.pos/2})}),new dt(t.concat(r.reverse()))}rgb(t){let r=Nu(this.stops,t),n=[];this.stops.forEach((i,s)=>{i.colorLess&&(i.color=ai(this.stops[s-1],this.stops[s+1],2)[1])});for(let i=0,s=this.stops.length;i<s-1;i++){let o=ai(this.stops[i],this.stops[i+1],r[i]);n.splice(n.length,0,...o)}return n.push(this.stops[this.stops.length-1].color),n}hsv(t,r){let n=Nu(this.stops,t),i=[];this.stops.forEach((s,o)=>{s.colorLess&&(s.color=Iu(this.stops[o-1],this.stops[o+1],2,r)[1])});for(let s=0,o=this.stops.length;s<o-1;s++){let a=Iu(this.stops[s],this.stops[s+1],n[s],r);i.splice(i.length,0,...a)}return i.push(this.stops[this.stops.length-1].color),i}css(t,r){t=t||"linear",r=r||(t==="linear"?"to right":"ellipse at center");let n=t+"-gradient("+r;return this.stops.forEach(function(i){n+=", "+(i.colorLess?"":i.color.toRgbString()+" ")+i.pos*100+"%"}),n+=")",n}rgbAt(t){return Du(this.stops,t,"toRgb",ju)}hsvAt(t){return Du(this.stops,t,"toHsv",$u)}};Bu.exports=function(e){if(arguments.length===1){if(!Array.isArray(arguments[0]))throw new Error('"stops" is not an array');e=arguments[0]}else e=Array.prototype.slice.call(arguments);return new dt(e)}});var Wu=v((Im,Nr)=>{"use strict";var Uu=Fu(),hp=Lu(),Hu=/\s/g;function li(...e){let t=hp.apply(this,e),r=(n,i)=>dp(n?n.toString():"",t,i);return r.multiline=(n,i)=>pp(n?n.toString():"",t,i),r}var Gu=(e,t,r)=>t.interpolation.toLowerCase()==="hsv"?e.hsv(r,t.hsvSpin.toLowerCase()):e.rgb(r);function dp(e,t,r){let n=zu(r),i=Math.max(e.replace(Hu,"").length,t.stops.length),s=Gu(t,n,i),o="";for(let a of e)o+=a.match(Hu)?a:Uu.hex(s.shift().toHex())(a);return o}function pp(e,t,r){let n=zu(r),i=e.split(`
21
- `),s=Math.max.apply(null,i.map(c=>c.length).concat([t.stops.length])),o=Gu(t,n,s),a=[];for(let c of i){let d=o.slice(0),f="";for(let p of c)f+=Uu.hex(d.shift().toHex())(p);a.push(f)}return a.join(`
22
- `)}function zu(e){let t={interpolation:"rgb",hsvSpin:"short",...e};if(e!==void 0&&typeof e!="object")throw new TypeError(`Expected \`options\` to be an \`object\`, got \`${typeof e}\``);if(typeof t.interpolation!="string")throw new TypeError(`Expected \`options.interpolation\` to be a \`string\`, got \`${typeof t.interpolation}\``);if(t.interpolation.toLowerCase()==="hsv"&&typeof t.hsvSpin!="string")throw new TypeError(`Expected \`options.hsvSpin\` to be a \`string\`, got \`${typeof t.hsvSpin}\``);return t}var Nt={atlas:{colors:["#feac5e","#c779d0","#4bc0c8"],options:{}},cristal:{colors:["#bdfff3","#4ac29a"],options:{}},teen:{colors:["#77a1d3","#79cbca","#e684ae"],options:{}},mind:{colors:["#473b7b","#3584a7","#30d2be"],options:{}},morning:{colors:["#ff5f6d","#ffc371"],options:{interpolation:"hsv"}},vice:{colors:["#5ee7df","#b490ca"],options:{interpolation:"hsv"}},passion:{colors:["#f43b47","#453a94"],options:{}},fruit:{colors:["#ff4e50","#f9d423"],options:{}},instagram:{colors:["#833ab4","#fd1d1d","#fcb045"],options:{}},retro:{colors:["#3f51b1","#5a55ae","#7b5fac","#8f6aae","#a86aa4","#cc6b8e","#f18271","#f3a469","#f7c978"],options:{}},summer:{colors:["#fdbb2d","#22c1c3"],options:{}},rainbow:{colors:["#ff0000","#ff0100"],options:{interpolation:"hsv",hsvSpin:"long"}},pastel:{colors:["#74ebd5","#74ecd5"],options:{interpolation:"hsv",hsvSpin:"long"}}};Nr.exports=li;for(let e in Nt)Nr.exports[e]=t=>new li(Nt[e].colors)(t,Nt[e].options),Nr.exports[e].multiline=t=>new li(Nt[e].colors).multiline(t,Nt[e].options)});var cl=require("child_process"),_e=K(require("fs")),Ce=K(require("path")),Y=K(gt()),ul=K(Gt()),yi=K(hs());var _a=K(require("crypto")),nt=K(require("fs")),vn=K(require("path")),xa=K(gn()),fr=vn.default.resolve(__dirname,"./../../apiCache"),B1=`${fr}/siteHash.json`;function Ea(){nt.default.existsSync(fr)||nt.default.mkdirSync(fr),console.log(`
23
- \u{1FA84} Cache initialized`)}function Sa(e){let t=_a.default.createHash("sha256");return t.update(JSON.stringify(e)),`${fr}/${t.digest("hex")}`}function ka(e,t){let r=typeof t=="string"?t:JSON.stringify(t),n=Sa(e),i=vn.default.dirname(n);nt.default.existsSync(i)||nt.default.mkdirSync(i,{recursive:!0}),nt.default.writeFileSync(n,r,"utf8")}function Ca(e){try{let t=Sa(e);return xa.default.readJSONSync(t,{encoding:"utf-8"})}catch{return null}}var iu=K(Yn()),su=K(gt()),Kn=class{user;password;baseUrl;headers;constructor(){this.user=process.env.botEmail,this.password=process.env.botPassword,this.baseUrl=process.env.API_URL}async login(){try{let t=await(0,iu.default)({url:`${this.baseUrl}/login_check`,method:"POST",headers:{"Content-Type":"application/json"},data:{username:this.user,password:this.password}});if(t.status===200){let{data:{token:r}}=t;this.headers={Authorization:"bearer "+r,"Cache-Control":"no-store"}}return this.headers}catch{console.error(su.default.red(`
17
+ `)+r,i=n+1,n=t.indexOf(`
18
+ `,i)}while(n!==-1);return s+=t.substr(i),s};af.exports={stringReplaceAll:Ng,stringEncaseCRLFWithFirstIndex:jg}});var hf=y((D2,df)=>{"use strict";var Lg=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,cf=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,$g=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,Bg=/\\(u(?:[a-f\d]{4}|{[a-f\d]{1,6}})|x[a-f\d]{2}|.)|([^\\])/gi,Ug=new Map([["n",`
19
+ `],["r","\r"],["t"," "],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e","\x1B"],["a","\x07"]]);function ff(t){let e=t[0]==="u",r=t[1]==="{";return e&&!r&&t.length===5||t[0]==="x"&&t.length===3?String.fromCharCode(parseInt(t.slice(1),16)):e&&r?String.fromCodePoint(parseInt(t.slice(2,-1),16)):Ug.get(t)||t}function Xg(t,e){let r=[],n=e.trim().split(/\s*,\s*/g),i;for(let s of n){let o=Number(s);if(!Number.isNaN(o))r.push(o);else if(i=s.match($g))r.push(i[2].replace(Bg,(a,u,h)=>u?ff(u):h));else throw new Error(`Invalid Chalk template style argument: ${s} (in style '${t}')`)}return r}function Hg(t){cf.lastIndex=0;let e=[],r;for(;(r=cf.exec(t))!==null;){let n=r[1];if(r[2]){let i=Xg(n,r[2]);e.push([n].concat(i))}else e.push([n])}return e}function lf(t,e){let r={};for(let i of e)for(let s of i.styles)r[s[0]]=i.inverse?null:s.slice(1);let n=t;for(let[i,s]of Object.entries(r))if(Array.isArray(s)){if(!(i in n))throw new Error(`Unknown Chalk style: ${i}`);n=s.length>0?n[i](...s):n[i]}return n}df.exports=(t,e)=>{let r=[],n=[],i=[];if(e.replace(Lg,(s,o,a,u,h,c)=>{if(o)i.push(ff(o));else if(u){let p=i.join("");i=[],n.push(r.length===0?p:lf(t,r)(p)),r.push({inverse:a,styles:Hg(u)})}else if(h){if(r.length===0)throw new Error("Found extraneous } in Chalk template literal");n.push(lf(t,r)(i.join(""))),i=[],r.pop()}else i.push(c)}),n.push(i.join("")),r.length>0){let s=`Chalk template literal is missing ${r.length} closing bracket${r.length===1?"":"s"} (\`}\`)`;throw new Error(s)}return n.join("")}});var _f=y((O2,bf)=>{"use strict";var cr=of(),{stdout:ts,stderr:rs}=si(),{stringReplaceAll:Gg,stringEncaseCRLFWithFirstIndex:Wg}=uf(),{isArray:gn}=Array,mf=["ansi","ansi","ansi256","ansi16m"],Tt=Object.create(null),zg=(t,e={})=>{if(e.level&&!(Number.isInteger(e.level)&&e.level>=0&&e.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");let r=ts?ts.level:0;t.level=e.level===void 0?r:e.level},ns=class{constructor(e){return gf(e)}},gf=t=>{let e={};return zg(e,t),e.template=(...r)=>vf(e.template,...r),Object.setPrototypeOf(e,yn.prototype),Object.setPrototypeOf(e.template,e),e.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")},e.template.Instance=ns,e.template};function yn(t){return gf(t)}for(let[t,e]of Object.entries(cr))Tt[t]={get(){let r=vn(this,is(e.open,e.close,this._styler),this._isEmpty);return Object.defineProperty(this,t,{value:r}),r}};Tt.visible={get(){let t=vn(this,this._styler,!0);return Object.defineProperty(this,"visible",{value:t}),t}};var yf=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(let t of yf)Tt[t]={get(){let{level:e}=this;return function(...r){let n=is(cr.color[mf[e]][t](...r),cr.color.close,this._styler);return vn(this,n,this._isEmpty)}}};for(let t of yf){let e="bg"+t[0].toUpperCase()+t.slice(1);Tt[e]={get(){let{level:r}=this;return function(...n){let i=is(cr.bgColor[mf[r]][t](...n),cr.bgColor.close,this._styler);return vn(this,i,this._isEmpty)}}}}var Jg=Object.defineProperties(()=>{},{...Tt,level:{enumerable:!0,get(){return this._generator.level},set(t){this._generator.level=t}}}),is=(t,e,r)=>{let n,i;return r===void 0?(n=t,i=e):(n=r.openAll+t,i=e+r.closeAll),{open:t,close:e,openAll:n,closeAll:i,parent:r}},vn=(t,e,r)=>{let n=(...i)=>gn(i[0])&&gn(i[0].raw)?pf(n,vf(n,...i)):pf(n,i.length===1?""+i[0]:i.join(" "));return Object.setPrototypeOf(n,Jg),n._generator=t,n._styler=e,n._isEmpty=r,n},pf=(t,e)=>{if(t.level<=0||!e)return t._isEmpty?"":e;let r=t._styler;if(r===void 0)return e;let{openAll:n,closeAll:i}=r;if(e.indexOf("\x1B")!==-1)for(;r!==void 0;)e=Gg(e,r.close,r.open),r=r.parent;let s=e.indexOf(`
20
+ `);return s!==-1&&(e=Wg(e,i,n,s)),n+e+i},es,vf=(t,...e)=>{let[r]=e;if(!gn(r)||!gn(r.raw))return e.join(" ");let n=e.slice(1),i=[r.raw[0]];for(let s=1;s<r.length;s++)i.push(String(n[s-1]).replace(/[{}\\]/g,"\\$&"),String(r.raw[s]));return es===void 0&&(es=hf()),es(t,i.join(""))};Object.defineProperties(yn.prototype,Tt);var bn=yn();bn.supportsColor=ts;bn.stderr=yn({level:rs?rs.level:0});bn.stderr.supportsColor=rs;bf.exports=bn});var wf=y((ss,os)=>{(function(t,e){typeof ss=="object"&&typeof os<"u"?os.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self,t.tinycolor=e())})(ss,function(){"use strict";function t(l){return t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(d){return typeof d}:function(d){return d&&typeof Symbol=="function"&&d.constructor===Symbol&&d!==Symbol.prototype?"symbol":typeof d},t(l)}var e=/^\s+/,r=/\s+$/;function n(l,d){if(l=l||"",d=d||{},l instanceof n)return l;if(!(this instanceof n))return new n(l,d);var f=i(l);this._originalInput=l,this._r=f.r,this._g=f.g,this._b=f.b,this._a=f.a,this._roundA=Math.round(100*this._a)/100,this._format=d.format||f.format,this._gradientType=d.gradientType,this._r<1&&(this._r=Math.round(this._r)),this._g<1&&(this._g=Math.round(this._g)),this._b<1&&(this._b=Math.round(this._b)),this._ok=f.ok}n.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var d=this.toRgb();return(d.r*299+d.g*587+d.b*114)/1e3},getLuminance:function(){var d=this.toRgb(),f,v,S,x,B,H;return f=d.r/255,v=d.g/255,S=d.b/255,f<=.03928?x=f/12.92:x=Math.pow((f+.055)/1.055,2.4),v<=.03928?B=v/12.92:B=Math.pow((v+.055)/1.055,2.4),S<=.03928?H=S/12.92:H=Math.pow((S+.055)/1.055,2.4),.2126*x+.7152*B+.0722*H},setAlpha:function(d){return this._a=$(d),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var d=u(this._r,this._g,this._b);return{h:d.h*360,s:d.s,v:d.v,a:this._a}},toHsvString:function(){var d=u(this._r,this._g,this._b),f=Math.round(d.h*360),v=Math.round(d.s*100),S=Math.round(d.v*100);return this._a==1?"hsv("+f+", "+v+"%, "+S+"%)":"hsva("+f+", "+v+"%, "+S+"%, "+this._roundA+")"},toHsl:function(){var d=o(this._r,this._g,this._b);return{h:d.h*360,s:d.s,l:d.l,a:this._a}},toHslString:function(){var d=o(this._r,this._g,this._b),f=Math.round(d.h*360),v=Math.round(d.s*100),S=Math.round(d.l*100);return this._a==1?"hsl("+f+", "+v+"%, "+S+"%)":"hsla("+f+", "+v+"%, "+S+"%, "+this._roundA+")"},toHex:function(d){return c(this._r,this._g,this._b,d)},toHexString:function(d){return"#"+this.toHex(d)},toHex8:function(d){return p(this._r,this._g,this._b,this._a,d)},toHex8String:function(d){return"#"+this.toHex8(d)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(R(this._r,255)*100)+"%",g:Math.round(R(this._g,255)*100)+"%",b:Math.round(R(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(R(this._r,255)*100)+"%, "+Math.round(R(this._g,255)*100)+"%, "+Math.round(R(this._b,255)*100)+"%)":"rgba("+Math.round(R(this._r,255)*100)+"%, "+Math.round(R(this._g,255)*100)+"%, "+Math.round(R(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:w[c(this._r,this._g,this._b,!0)]||!1},toFilter:function(d){var f="#"+g(this._r,this._g,this._b,this._a),v=f,S=this._gradientType?"GradientType = 1, ":"";if(d){var x=n(d);v="#"+g(x._r,x._g,x._b,x._a)}return"progid:DXImageTransform.Microsoft.gradient("+S+"startColorstr="+f+",endColorstr="+v+")"},toString:function(d){var f=!!d;d=d||this._format;var v=!1,S=this._a<1&&this._a>=0,x=!f&&S&&(d==="hex"||d==="hex6"||d==="hex3"||d==="hex4"||d==="hex8"||d==="name");return x?d==="name"&&this._a===0?this.toName():this.toRgbString():(d==="rgb"&&(v=this.toRgbString()),d==="prgb"&&(v=this.toPercentageRgbString()),(d==="hex"||d==="hex6")&&(v=this.toHexString()),d==="hex3"&&(v=this.toHexString(!0)),d==="hex4"&&(v=this.toHex8String(!0)),d==="hex8"&&(v=this.toHex8String()),d==="name"&&(v=this.toName()),d==="hsl"&&(v=this.toHslString()),d==="hsv"&&(v=this.toHsvString()),v||this.toHexString())},clone:function(){return n(this.toString())},_applyModification:function(d,f){var v=d.apply(null,[this].concat([].slice.call(f)));return this._r=v._r,this._g=v._g,this._b=v._b,this.setAlpha(v._a),this},lighten:function(){return this._applyModification(I,arguments)},brighten:function(){return this._applyModification(k,arguments)},darken:function(){return this._applyModification(L,arguments)},desaturate:function(){return this._applyModification(m,arguments)},saturate:function(){return this._applyModification(_,arguments)},greyscale:function(){return this._applyModification(C,arguments)},spin:function(){return this._applyModification(U,arguments)},_applyCombination:function(d,f){return d.apply(null,[this].concat([].slice.call(f)))},analogous:function(){return this._applyCombination(ve,arguments)},complement:function(){return this._applyCombination(X,arguments)},monochromatic:function(){return this._applyCombination(Q,arguments)},splitcomplement:function(){return this._applyCombination(re,arguments)},triad:function(){return this._applyCombination(z,[3])},tetrad:function(){return this._applyCombination(z,[4])}},n.fromRatio=function(l,d){if(t(l)=="object"){var f={};for(var v in l)l.hasOwnProperty(v)&&(v==="a"?f[v]=l[v]:f[v]=F(l[v]));l=f}return n(l,d)};function i(l){var d={r:0,g:0,b:0},f=1,v=null,S=null,x=null,B=!1,H=!1;return typeof l=="string"&&(l=nt(l)),t(l)=="object"&&(ue(l.r)&&ue(l.g)&&ue(l.b)?(d=s(l.r,l.g,l.b),B=!0,H=String(l.r).substr(-1)==="%"?"prgb":"rgb"):ue(l.h)&&ue(l.s)&&ue(l.v)?(v=F(l.s),S=F(l.v),d=h(l.h,v,S),B=!0,H="hsv"):ue(l.h)&&ue(l.s)&&ue(l.l)&&(v=F(l.s),x=F(l.l),d=a(l.h,v,x),B=!0,H="hsl"),l.hasOwnProperty("a")&&(f=l.a)),f=$(f),{ok:B,format:l.format||H,r:Math.min(255,Math.max(d.r,0)),g:Math.min(255,Math.max(d.g,0)),b:Math.min(255,Math.max(d.b,0)),a:f}}function s(l,d,f){return{r:R(l,255)*255,g:R(d,255)*255,b:R(f,255)*255}}function o(l,d,f){l=R(l,255),d=R(d,255),f=R(f,255);var v=Math.max(l,d,f),S=Math.min(l,d,f),x,B,H=(v+S)/2;if(v==S)x=B=0;else{var J=v-S;switch(B=H>.5?J/(2-v-S):J/(v+S),v){case l:x=(d-f)/J+(d<f?6:0);break;case d:x=(f-l)/J+2;break;case f:x=(l-d)/J+4;break}x/=6}return{h:x,s:B,l:H}}function a(l,d,f){var v,S,x;l=R(l,360),d=R(d,100),f=R(f,100);function B(Ie,Xt,Me){return Me<0&&(Me+=1),Me>1&&(Me-=1),Me<1/6?Ie+(Xt-Ie)*6*Me:Me<1/2?Xt:Me<2/3?Ie+(Xt-Ie)*(2/3-Me)*6:Ie}if(d===0)v=S=x=f;else{var H=f<.5?f*(1+d):f+d-f*d,J=2*f-H;v=B(J,H,l+1/3),S=B(J,H,l),x=B(J,H,l-1/3)}return{r:v*255,g:S*255,b:x*255}}function u(l,d,f){l=R(l,255),d=R(d,255),f=R(f,255);var v=Math.max(l,d,f),S=Math.min(l,d,f),x,B,H=v,J=v-S;if(B=v===0?0:J/v,v==S)x=0;else{switch(v){case l:x=(d-f)/J+(d<f?6:0);break;case d:x=(f-l)/J+2;break;case f:x=(l-d)/J+4;break}x/=6}return{h:x,s:B,v:H}}function h(l,d,f){l=R(l,360)*6,d=R(d,100),f=R(f,100);var v=Math.floor(l),S=l-v,x=f*(1-d),B=f*(1-S*d),H=f*(1-(1-S)*d),J=v%6,Ie=[f,B,x,x,H,f][J],Xt=[H,f,f,B,x,x][J],Me=[x,x,H,f,f,B][J];return{r:Ie*255,g:Xt*255,b:Me*255}}function c(l,d,f,v){var S=[P(Math.round(l).toString(16)),P(Math.round(d).toString(16)),P(Math.round(f).toString(16))];return v&&S[0].charAt(0)==S[0].charAt(1)&&S[1].charAt(0)==S[1].charAt(1)&&S[2].charAt(0)==S[2].charAt(1)?S[0].charAt(0)+S[1].charAt(0)+S[2].charAt(0):S.join("")}function p(l,d,f,v,S){var x=[P(Math.round(l).toString(16)),P(Math.round(d).toString(16)),P(Math.round(f).toString(16)),P(De(v))];return S&&x[0].charAt(0)==x[0].charAt(1)&&x[1].charAt(0)==x[1].charAt(1)&&x[2].charAt(0)==x[2].charAt(1)&&x[3].charAt(0)==x[3].charAt(1)?x[0].charAt(0)+x[1].charAt(0)+x[2].charAt(0)+x[3].charAt(0):x.join("")}function g(l,d,f,v){var S=[P(De(v)),P(Math.round(l).toString(16)),P(Math.round(d).toString(16)),P(Math.round(f).toString(16))];return S.join("")}n.equals=function(l,d){return!l||!d?!1:n(l).toRgbString()==n(d).toRgbString()},n.random=function(){return n.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function m(l,d){d=d===0?0:d||10;var f=n(l).toHsl();return f.s-=d/100,f.s=j(f.s),n(f)}function _(l,d){d=d===0?0:d||10;var f=n(l).toHsl();return f.s+=d/100,f.s=j(f.s),n(f)}function C(l){return n(l).desaturate(100)}function I(l,d){d=d===0?0:d||10;var f=n(l).toHsl();return f.l+=d/100,f.l=j(f.l),n(f)}function k(l,d){d=d===0?0:d||10;var f=n(l).toRgb();return f.r=Math.max(0,Math.min(255,f.r-Math.round(255*-(d/100)))),f.g=Math.max(0,Math.min(255,f.g-Math.round(255*-(d/100)))),f.b=Math.max(0,Math.min(255,f.b-Math.round(255*-(d/100)))),n(f)}function L(l,d){d=d===0?0:d||10;var f=n(l).toHsl();return f.l-=d/100,f.l=j(f.l),n(f)}function U(l,d){var f=n(l).toHsl(),v=(f.h+d)%360;return f.h=v<0?360+v:v,n(f)}function X(l){var d=n(l).toHsl();return d.h=(d.h+180)%360,n(d)}function z(l,d){if(isNaN(d)||d<=0)throw new Error("Argument to polyad must be a positive number");for(var f=n(l).toHsl(),v=[n(l)],S=360/d,x=1;x<d;x++)v.push(n({h:(f.h+x*S)%360,s:f.s,l:f.l}));return v}function re(l){var d=n(l).toHsl(),f=d.h;return[n(l),n({h:(f+72)%360,s:d.s,l:d.l}),n({h:(f+216)%360,s:d.s,l:d.l})]}function ve(l,d,f){d=d||6,f=f||30;var v=n(l).toHsl(),S=360/f,x=[n(l)];for(v.h=(v.h-(S*d>>1)+720)%360;--d;)v.h=(v.h+S)%360,x.push(n(v));return x}function Q(l,d){d=d||6;for(var f=n(l).toHsv(),v=f.h,S=f.s,x=f.v,B=[],H=1/d;d--;)B.push(n({h:v,s:S,v:x})),x=(x+H)%1;return B}n.mix=function(l,d,f){f=f===0?0:f||50;var v=n(l).toRgb(),S=n(d).toRgb(),x=f/100,B={r:(S.r-v.r)*x+v.r,g:(S.g-v.g)*x+v.g,b:(S.b-v.b)*x+v.b,a:(S.a-v.a)*x+v.a};return n(B)},n.readability=function(l,d){var f=n(l),v=n(d);return(Math.max(f.getLuminance(),v.getLuminance())+.05)/(Math.min(f.getLuminance(),v.getLuminance())+.05)},n.isReadable=function(l,d,f){var v=n.readability(l,d),S,x;switch(x=!1,S=_e(f),S.level+S.size){case"AAsmall":case"AAAlarge":x=v>=4.5;break;case"AAlarge":x=v>=3;break;case"AAAsmall":x=v>=7;break}return x},n.mostReadable=function(l,d,f){var v=null,S=0,x,B,H,J;f=f||{},B=f.includeFallbackColors,H=f.level,J=f.size;for(var Ie=0;Ie<d.length;Ie++)x=n.readability(l,d[Ie]),x>S&&(S=x,v=n(d[Ie]));return n.isReadable(l,v,{level:H,size:J})||!B?v:(f.includeFallbackColors=!1,n.mostReadable(l,["#fff","#000"],f))};var b=n.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},w=n.hexNames=E(b);function E(l){var d={};for(var f in l)l.hasOwnProperty(f)&&(d[l[f]]=f);return d}function $(l){return l=parseFloat(l),(isNaN(l)||l<0||l>1)&&(l=1),l}function R(l,d){N(l)&&(l="100%");var f=M(l);return l=Math.min(d,Math.max(0,parseFloat(l))),f&&(l=parseInt(l*d,10)/100),Math.abs(l-d)<1e-6?1:l%d/parseFloat(d)}function j(l){return Math.min(1,Math.max(0,l))}function D(l){return parseInt(l,16)}function N(l){return typeof l=="string"&&l.indexOf(".")!=-1&&parseFloat(l)===1}function M(l){return typeof l=="string"&&l.indexOf("%")!=-1}function P(l){return l.length==1?"0"+l:""+l}function F(l){return l<=1&&(l=l*100+"%"),l}function De(l){return Math.round(parseFloat(l)*255).toString(16)}function be(l){return D(l)/255}var ne=function(){var l="[-\\+]?\\d+%?",d="[-\\+]?\\d*\\.\\d+%?",f="(?:"+d+")|(?:"+l+")",v="[\\s|\\(]+("+f+")[,|\\s]+("+f+")[,|\\s]+("+f+")\\s*\\)?",S="[\\s|\\(]+("+f+")[,|\\s]+("+f+")[,|\\s]+("+f+")[,|\\s]+("+f+")\\s*\\)?";return{CSS_UNIT:new RegExp(f),rgb:new RegExp("rgb"+v),rgba:new RegExp("rgba"+S),hsl:new RegExp("hsl"+v),hsla:new RegExp("hsla"+S),hsv:new RegExp("hsv"+v),hsva:new RegExp("hsva"+S),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function ue(l){return!!ne.CSS_UNIT.exec(l)}function nt(l){l=l.replace(e,"").replace(r,"").toLowerCase();var d=!1;if(b[l])l=b[l],d=!0;else if(l=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var f;return(f=ne.rgb.exec(l))?{r:f[1],g:f[2],b:f[3]}:(f=ne.rgba.exec(l))?{r:f[1],g:f[2],b:f[3],a:f[4]}:(f=ne.hsl.exec(l))?{h:f[1],s:f[2],l:f[3]}:(f=ne.hsla.exec(l))?{h:f[1],s:f[2],l:f[3],a:f[4]}:(f=ne.hsv.exec(l))?{h:f[1],s:f[2],v:f[3]}:(f=ne.hsva.exec(l))?{h:f[1],s:f[2],v:f[3],a:f[4]}:(f=ne.hex8.exec(l))?{r:D(f[1]),g:D(f[2]),b:D(f[3]),a:be(f[4]),format:d?"name":"hex8"}:(f=ne.hex6.exec(l))?{r:D(f[1]),g:D(f[2]),b:D(f[3]),format:d?"name":"hex"}:(f=ne.hex4.exec(l))?{r:D(f[1]+""+f[1]),g:D(f[2]+""+f[2]),b:D(f[3]+""+f[3]),a:be(f[4]+""+f[4]),format:d?"name":"hex8"}:(f=ne.hex3.exec(l))?{r:D(f[1]+""+f[1]),g:D(f[2]+""+f[2]),b:D(f[3]+""+f[3]),format:d?"name":"hex"}:!1}function _e(l){var d,f;return l=l||{level:"AA",size:"small"},d=(l.level||"AA").toUpperCase(),f=(l.size||"small").toLowerCase(),d!=="AA"&&d!=="AAA"&&(d="AA"),f!=="small"&&f!=="large"&&(f="small"),{level:d,size:f}}return n})});var Of=y((A2,Df)=>{var lr=wf(),Cf={r:256,g:256,b:256,a:1},Pf={h:360,s:1,v:1,a:1};function us(t,e,r){let n={};for(let i in t)t.hasOwnProperty(i)&&(n[i]=r===0?0:(e[i]-t[i])/r);return n}function cs(t,e,r,n){let i={};for(let s in e)e.hasOwnProperty(s)&&(i[s]=t[s]*r+e[s],i[s]=i[s]<0?i[s]+n[s]:n[s]!==1?i[s]%n[s]:i[s]);return i}function as(t,e,r){let n=t.color.toRgb(),i=e.color.toRgb(),s=us(n,i,r),o=[t.color];for(let a=1;a<r;a++){let u=cs(s,n,a,Cf);o.push(lr(u))}return o}function xf(t,e,r,n){let i=t.color.toHsv(),s=e.color.toHsv();if(i.s===0||s.s===0)return as(t,e,r);let o;if(typeof n=="boolean")o=n;else{let c=i.h<s.h&&s.h-i.h<180||i.h>s.h&&i.h-s.h>180;o=n==="long"&&c||n==="short"&&!c}let a=us(i,s,r),u=[t.color],h;i.h<=s.h&&!o||i.h>=s.h&&o?h=s.h-i.h:o?h=360-s.h+i.h:h=360-i.h+s.h,a.h=Math.pow(-1,o?1:0)*Math.abs(h)/r;for(let c=1;c<r;c++){let p=cs(a,i,c,Pf);u.push(lr(p))}return u}function Sf(t,e){let r=t.length;if(e=parseInt(e,10),isNaN(e)||e<2)throw new Error("Invalid number of steps (< 2)");if(e<r)throw new Error("Number of steps cannot be inferior to number of stops");let n=[];for(let s=1;s<r;s++){let o=(e-1)*(t[s].pos-t[s-1].pos);n.push(Math.max(1,Math.round(o)))}let i=1;for(let s=r-1;s--;)i+=n[s];for(;i!==e;)if(i<e){let s=Math.min.apply(null,n);n[n.indexOf(s)]++,i++}else{let s=Math.max.apply(null,n);n[n.indexOf(s)]--,i--}return n}function Ef(t,e,r,n){if(e<0||e>1)throw new Error("Position must be between 0 and 1");let i,s;for(let u=0,h=t.length;u<h-1;u++)if(e>=t[u].pos&&e<t[u+1].pos){i=t[u],s=t[u+1];break}i||(i=s=t[t.length-1]);let o=us(i.color[r](),s.color[r](),(s.pos-i.pos)*100),a=cs(o,i.color[r](),(e-i.pos)*100,n);return lr(a)}var Nt=class{constructor(e){if(e.length<2)throw new Error("Invalid number of stops (< 2)");let r=e[0].pos!==void 0,n=e.length,i=-1,s=!1;this.stops=e.map((o,a)=>{let u=o.pos!==void 0;if(r^u)throw new Error("Cannot mix positionned and not posionned color stops");if(u){let h=o.color!==void 0;if(!h&&(s||a===0||a===n-1))throw new Error("Cannot define two consecutive position-only stops");if(s=!h,o={color:h?lr(o.color):null,colorLess:!h,pos:o.pos},o.pos<0||o.pos>1)throw new Error("Color stops positions must be between 0 and 1");if(o.pos<i)throw new Error("Color stops positions are not ordered");i=o.pos}else o={color:lr(o.color!==void 0?o.color:o),pos:a/(n-1)};return o}),this.stops[0].pos!==0&&(this.stops.unshift({color:this.stops[0].color,pos:0}),n++),this.stops[n-1].pos!==1&&this.stops.push({color:this.stops[n-1].color,pos:1})}reverse(){let e=[];return this.stops.forEach(function(r){e.push({color:r.color,pos:1-r.pos})}),new Nt(e.reverse())}loop(){let e=[],r=[];return this.stops.forEach(n=>{e.push({color:n.color,pos:n.pos/2})}),this.stops.slice(0,-1).forEach(n=>{r.push({color:n.color,pos:1-n.pos/2})}),new Nt(e.concat(r.reverse()))}rgb(e){let r=Sf(this.stops,e),n=[];this.stops.forEach((i,s)=>{i.colorLess&&(i.color=as(this.stops[s-1],this.stops[s+1],2)[1])});for(let i=0,s=this.stops.length;i<s-1;i++){let o=as(this.stops[i],this.stops[i+1],r[i]);n.splice(n.length,0,...o)}return n.push(this.stops[this.stops.length-1].color),n}hsv(e,r){let n=Sf(this.stops,e),i=[];this.stops.forEach((s,o)=>{s.colorLess&&(s.color=xf(this.stops[o-1],this.stops[o+1],2,r)[1])});for(let s=0,o=this.stops.length;s<o-1;s++){let a=xf(this.stops[s],this.stops[s+1],n[s],r);i.splice(i.length,0,...a)}return i.push(this.stops[this.stops.length-1].color),i}css(e,r){e=e||"linear",r=r||(e==="linear"?"to right":"ellipse at center");let n=e+"-gradient("+r;return this.stops.forEach(function(i){n+=", "+(i.colorLess?"":i.color.toRgbString()+" ")+i.pos*100+"%"}),n+=")",n}rgbAt(e){return Ef(this.stops,e,"toRgb",Cf)}hsvAt(e){return Ef(this.stops,e,"toHsv",Pf)}};Df.exports=function(t){if(arguments.length===1){if(!Array.isArray(arguments[0]))throw new Error('"stops" is not an array');t=arguments[0]}else t=Array.prototype.slice.call(arguments);return new Nt(t)}});var kf=y((I2,_n)=>{"use strict";var If=_f(),Vg=Of(),Af=/\s/g;function ls(...t){let e=Vg.apply(this,t),r=(n,i)=>Kg(n?n.toString():"",e,i);return r.multiline=(n,i)=>Yg(n?n.toString():"",e,i),r}var Rf=(t,e,r)=>e.interpolation.toLowerCase()==="hsv"?t.hsv(r,e.hsvSpin.toLowerCase()):t.rgb(r);function Kg(t,e,r){let n=Ff(r),i=Math.max(t.replace(Af,"").length,e.stops.length),s=Rf(e,n,i),o="";for(let a of t)o+=a.match(Af)?a:If.hex(s.shift().toHex())(a);return o}function Yg(t,e,r){let n=Ff(r),i=t.split(`
21
+ `),s=Math.max.apply(null,i.map(u=>u.length).concat([e.stops.length])),o=Rf(e,n,s),a=[];for(let u of i){let h=o.slice(0),c="";for(let p of u)c+=If.hex(h.shift().toHex())(p);a.push(c)}return a.join(`
22
+ `)}function Ff(t){let e={interpolation:"rgb",hsvSpin:"short",...t};if(t!==void 0&&typeof t!="object")throw new TypeError(`Expected \`options\` to be an \`object\`, got \`${typeof t}\``);if(typeof e.interpolation!="string")throw new TypeError(`Expected \`options.interpolation\` to be a \`string\`, got \`${typeof e.interpolation}\``);if(e.interpolation.toLowerCase()==="hsv"&&typeof e.hsvSpin!="string")throw new TypeError(`Expected \`options.hsvSpin\` to be a \`string\`, got \`${typeof e.hsvSpin}\``);return e}var fr={atlas:{colors:["#feac5e","#c779d0","#4bc0c8"],options:{}},cristal:{colors:["#bdfff3","#4ac29a"],options:{}},teen:{colors:["#77a1d3","#79cbca","#e684ae"],options:{}},mind:{colors:["#473b7b","#3584a7","#30d2be"],options:{}},morning:{colors:["#ff5f6d","#ffc371"],options:{interpolation:"hsv"}},vice:{colors:["#5ee7df","#b490ca"],options:{interpolation:"hsv"}},passion:{colors:["#f43b47","#453a94"],options:{}},fruit:{colors:["#ff4e50","#f9d423"],options:{}},instagram:{colors:["#833ab4","#fd1d1d","#fcb045"],options:{}},retro:{colors:["#3f51b1","#5a55ae","#7b5fac","#8f6aae","#a86aa4","#cc6b8e","#f18271","#f3a469","#f7c978"],options:{}},summer:{colors:["#fdbb2d","#22c1c3"],options:{}},rainbow:{colors:["#ff0000","#ff0100"],options:{interpolation:"hsv",hsvSpin:"long"}},pastel:{colors:["#74ebd5","#74ecd5"],options:{interpolation:"hsv",hsvSpin:"long"}}};_n.exports=ls;for(let t in fr)_n.exports[t]=e=>new ls(fr[t].colors)(e,fr[t].options),_n.exports[t].multiline=e=>new ls(fr[t].colors).multiline(e,fr[t].options)});var qf=y((R2,Mf)=>{var fs=class{constructor(e){this.value=e,this.next=void 0}},ds=class{constructor(){this.clear()}enqueue(e){let r=new fs(e);this._head?(this._tail.next=r,this._tail=r):(this._head=r,this._tail=r),this._size++}dequeue(){let e=this._head;if(e)return this._head=this._head.next,this._size--,e.value}clear(){this._head=void 0,this._tail=void 0,this._size=0}get size(){return this._size}*[Symbol.iterator](){let e=this._head;for(;e;)yield e.value,e=e.next}};Mf.exports=ds});var hs=y((F2,Tf)=>{"use strict";var Qg=qf(),Zg=t=>{if(!((Number.isInteger(t)||t===1/0)&&t>0))throw new TypeError("Expected `concurrency` to be a number from 1 and up");let e=new Qg,r=0,n=()=>{r--,e.size>0&&e.dequeue()()},i=async(a,u,...h)=>{r++;let c=(async()=>a(...h))();u(c);try{await c}catch{}n()},s=(a,u,...h)=>{e.enqueue(i.bind(null,a,u,...h)),(async()=>(await Promise.resolve(),r<t&&e.size>0&&e.dequeue()()))()},o=(a,...u)=>new Promise(h=>{s(a,h,...u)});return Object.defineProperties(o,{activeCount:{get:()=>r},pendingCount:{get:()=>e.size},clearQueue:{value:()=>{e.clear()}}}),o};Tf.exports=Zg});var Lf=y((k2,jf)=>{"use strict";var Nf=hs(),wn=class extends Error{constructor(e){super(),this.value=e}},ey=async(t,e)=>e(await t),ty=async t=>{let e=await Promise.all(t);if(e[1]===!0)throw new wn(e[0]);return!1},ry=async(t,e,r)=>{r={concurrency:1/0,preserveOrder:!0,...r};let n=Nf(r.concurrency),i=[...t].map(o=>[o,n(ey,o,e)]),s=Nf(r.preserveOrder?1:1/0);try{await Promise.all(i.map(o=>s(ty,o)))}catch(o){if(o instanceof wn)return o.value;throw o}};jf.exports=ry});var Gf=y((M2,ps)=>{"use strict";var $f=require("path"),xn=require("fs"),{promisify:Bf}=require("util"),ny=Lf(),iy=Bf(xn.stat),sy=Bf(xn.lstat),Uf={directory:"isDirectory",file:"isFile"};function Xf({type:t}){if(!(t in Uf))throw new Error(`Invalid type specified: ${t}`)}var Hf=(t,e)=>t===void 0||e[Uf[t]]();ps.exports=async(t,e)=>{e={cwd:process.cwd(),type:"file",allowSymlinks:!0,...e},Xf(e);let r=e.allowSymlinks?iy:sy;return ny(t,async n=>{try{let i=await r($f.resolve(e.cwd,n));return Hf(e.type,i)}catch{return!1}},e)};ps.exports.sync=(t,e)=>{e={cwd:process.cwd(),allowSymlinks:!0,type:"file",...e},Xf(e);let r=e.allowSymlinks?xn.statSync:xn.lstatSync;for(let n of t)try{let i=r($f.resolve(e.cwd,n));if(Hf(e.type,i))return n}catch{}}});var zf=y((q2,ms)=>{"use strict";var Wf=require("fs"),{promisify:oy}=require("util"),ay=oy(Wf.access);ms.exports=async t=>{try{return await ay(t),!0}catch{return!1}};ms.exports.sync=t=>{try{return Wf.accessSync(t),!0}catch{return!1}}});var Vf=y((T2,jt)=>{"use strict";var Qe=require("path"),Sn=Gf(),Jf=zf(),gs=Symbol("findUp.stop");jt.exports=async(t,e={})=>{let r=Qe.resolve(e.cwd||""),{root:n}=Qe.parse(r),i=[].concat(t),s=async o=>{if(typeof t!="function")return Sn(i,o);let a=await t(o.cwd);return typeof a=="string"?Sn([a],o):a};for(;;){let o=await s({...e,cwd:r});if(o===gs)return;if(o)return Qe.resolve(r,o);if(r===n)return;r=Qe.dirname(r)}};jt.exports.sync=(t,e={})=>{let r=Qe.resolve(e.cwd||""),{root:n}=Qe.parse(r),i=[].concat(t),s=o=>{if(typeof t!="function")return Sn.sync(i,o);let a=t(o.cwd);return typeof a=="string"?Sn.sync([a],o):a};for(;;){let o=s({...e,cwd:r});if(o===gs)return;if(o)return Qe.resolve(r,o);if(r===n)return;r=Qe.dirname(r)}};jt.exports.exists=Jf;jt.exports.sync.exists=Jf.sync;jt.exports.stop=gs});var vs=y((N2,ys)=>{"use strict";var Kf=require("path"),Yf=Vf(),uy=async t=>{let e=await Yf("package.json",{cwd:t});return e&&Kf.dirname(e)};ys.exports=uy;ys.exports.sync=t=>{let e=Yf.sync("package.json",{cwd:t});return e&&Kf.dirname(e)}});var Y=y(Ee=>{"use strict";Object.defineProperty(Ee,"__esModule",{value:!0});Ee.isUndefined=Ee.fixName=Ee.validateName=Ee.validateSingleChar=Ee.fixChar=Ee.validateChar=void 0;function Ry(t){for(var e=0;e<t.length;e++){var r=t.charCodeAt(e);if(!(r===9||r===10||r===13||r>=32&&r<=55295||r>=57344&&r<=65533)){if(e+1===t.length)return!1;var n=t.charCodeAt(e+1);if(r>=55296&&r<=56319&&n>=56320&&n<=57343){e++;continue}return!1}}return!0}Ee.validateChar=Ry;function Fy(t){for(var e="",r=0;r<t.length;r++){var n=t.charCodeAt(r);if(n===9||n===10||n===13||n>=32&&n<=55295||n>=57344&&n<=65533){e+=t[r];continue}if(r+1===t.length)return e+="\uFFFD",e;var i=t.charCodeAt(r+1);if(n>=55296&&n<=56319&&i>=56320&&i<=57343){e+=t[r]+t[r+1],r++;continue}e+="\uFFFD"}return e}Ee.fixChar=Fy;function ky(t){if(t.length===0)return!1;var e=t.charCodeAt(0);if(t.length===1)return e===9||e===10||e===13||e>=32&&e<=55295||e>=57344&&e<=65533;if(t.length!==2)return!1;var r=t.charCodeAt(1);return e>=55296&&e<=56319&&r>=56320&&r<=57343}Ee.validateSingleChar=ky;function My(t){if(t.length===0)return!1;var e=t.charCodeAt(0),r=e===58||e===95||e>=65&&e<=90||e>=97&&e<=122||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=767||e>=880&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533;if(t.length===1)return r;var n=t.charCodeAt(1),i=e>=55296&&e<=56191&&n>=56320&&n<=57343;if(!r&&!i)return!1;for(var s=i?2:1,o=s;o<t.length;o++){var a=t.charCodeAt(o);if(!(a===58||a===95||a===45||a===46||a===183||a>=48&&a<=57||a>=65&&a<=90||a>=97&&a<=122||a>=192&&a<=214||a>=216&&a<=246||a>=248&&a<=767||a>=768&&a<=879||a>=880&&a<=893||a>=895&&a<=8191||a>=8204&&a<=8205||a>=8255&&a<=8256||a>=8304&&a<=8591||a>=11264&&a<=12271||a>=12289&&a<=55295||a>=63744&&a<=64975||a>=65008&&a<=65533)){if(o+1===t.length)return!1;var u=t.charCodeAt(o+1);if(a>=55296&&a<=56191&&u>=56320&&u<=57343){o++;continue}return!1}}return!0}Ee.validateName=My;function qy(t){var e="";if(t.length===0)return e;var r=t.charCodeAt(0),n=r===58||r===95||r>=65&&r<=90||r>=97&&r<=122||r>=192&&r<=214||r>=216&&r<=246||r>=248&&r<=767||r>=880&&r<=893||r>=895&&r<=8191||r>=8204&&r<=8205||r>=8304&&r<=8591||r>=11264&&r<=12271||r>=12289&&r<=55295||r>=63744&&r<=64975||r>=65008&&r<=65533;if(t.length===1)return n?e=t[0]:e="\uFFFD",e;var i=t.charCodeAt(1),s=r>=55296&&r<=56191&&i>=56320&&i<=57343;s?e=t[0]+t[1]:n?e=t[0]:e="\uFFFD";for(var o=s?2:1,a=o;a<t.length;a++){var u=t.charCodeAt(a);if(u===58||u===95||u===45||u===46||u===183||u>=48&&u<=57||u>=65&&u<=90||u>=97&&u<=122||u>=192&&u<=214||u>=216&&u<=246||u>=248&&u<=767||u>=768&&u<=879||u>=880&&u<=893||u>=895&&u<=8191||u>=8204&&u<=8205||u>=8255&&u<=8256||u>=8304&&u<=8591||u>=11264&&u<=12271||u>=12289&&u<=55295||u>=63744&&u<=64975||u>=65008&&u<=65533){e+=t[a];continue}if(a+1===t.length)return e+="\uFFFD",e;var h=t.charCodeAt(a+1);if(u>=55296&&u<=56191&&h>=56320&&h<=57343){e+=t[a]+t[a+1],a++;continue}e+="\uFFFD"}return e}Ee.fixName=qy;function Ty(t){return Object.prototype.toString.call(t)==="[object Undefined]"}Ee.isUndefined=Ty});var Lt=y(In=>{"use strict";Object.defineProperty(In,"__esModule",{value:!0});In.StringOptions=void 0;var An=Y(),Ny=function(){function t(e){this.doubleQuotes=!1,this.indent=" ",this.newline=`
23
+ `,this.pretty=!0,(0,An.isUndefined)(e.doubleQuotes)||(this.doubleQuotes=e.doubleQuotes),(0,An.isUndefined)(e.indent)||(this.indent=e.indent),(0,An.isUndefined)(e.newline)||(this.newline=e.newline),(0,An.isUndefined)(e.pretty)||(this.pretty=e.pretty)}return t}();In.StringOptions=Ny});var Rn=y(ke=>{"use strict";Object.defineProperty(ke,"__esModule",{value:!0});ke.escapeDoubleQuotes=ke.escapeSingleQuotes=ke.escapeRightAngleBracketsInCdataTerminator=ke.escapeLeftAngleBrackets=ke.escapeAmpersands=void 0;function jy(t){return t.replace(/&/g,"&amp;")}ke.escapeAmpersands=jy;function Ly(t){return t.replace(/</g,"&lt;")}ke.escapeLeftAngleBrackets=Ly;function $y(t){return t.replace(/]]>/g,"]]&gt;")}ke.escapeRightAngleBracketsInCdataTerminator=$y;function By(t){return t.replace(/'/g,"&apos;")}ke.escapeSingleQuotes=By;function Uy(t){return t.replace(/"/g,"&quot;")}ke.escapeDoubleQuotes=Uy});var js=y(Ns=>{"use strict";Object.defineProperty(Ns,"__esModule",{value:!0});var Xy=ae(),bd=Rn(),Ts=Y(),Hy=function(){function t(e,r,n){this._validation=r,(0,Ts.isUndefined)(n.replaceInvalidCharsInCharData)?this._replaceInvalidCharsInCharData=!1:this._replaceInvalidCharsInCharData=n.replaceInvalidCharsInCharData,this._parent=e,this.charData=n.charData}return Object.defineProperty(t.prototype,"charData",{get:function(){return this._charData},set:function(e){if(this._replaceInvalidCharsInCharData)e=(0,Ts.fixChar)(e);else if(this._validation&&!(0,Ts.validateChar)(e))throw new Error((0,Xy.getContext)(this.up())+": attribute text"+(' "'+e+'" should not contain characters not')+" allowed in XML");this._charData=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){var e=this._charData;return e=(0,bd.escapeAmpersands)(e),e=(0,bd.escapeLeftAngleBrackets)(e),e},t.prototype.up=function(){return this._parent},t}();Ns.default=Hy});var Fn=y(Ls=>{"use strict";Object.defineProperty(Ls,"__esModule",{value:!0});var _d=ae(),wd=Y(),Gy=function(){function t(e,r,n){this._hex=!1,this._validation=r,this._parent=e,this.char=n.char,(0,wd.isUndefined)(n.hex)||(this.hex=n.hex)}return Object.defineProperty(t.prototype,"char",{get:function(){return this._char},set:function(e){if(this._validation&&!(0,wd.validateSingleChar)(e))throw new Error((0,_d.getContext)(this.up())+": character reference"+(' "'+e+'" should reference a single character,')+" and this character should be allowed in XML");this._char=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hex",{get:function(){return this._hex},set:function(e){this._hex=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){var e;if(this._char.length===1)e=this._char.charCodeAt(0);else{var r=this._char.charCodeAt(0);if(r>=55296&&r<=56319&&this._char.length>1){var n=this._char.charCodeAt(1);if(n>=56320&&n<=57343)e=(r-55296)*1024+n-56320+65536;else throw new Error((0,_d.getContext)(this.up())+": character"+(' reference "'+this.char+'" should')+" reference a valid Unicode character")}else e=r}return this._hex?"&#x"+e.toString(16)+";":"&#"+e+";"},t.prototype.up=function(){return this._parent},t}();Ls.default=Gy});var kn=y($s=>{"use strict";Object.defineProperty($s,"__esModule",{value:!0});var Wy=ae(),zy=Y(),Jy=function(){function t(e,r,n){this._validation=r,this._parent=e,this.name=n.name}return Object.defineProperty(t.prototype,"name",{get:function(){return this._name},set:function(e){if(this._validation&&!(0,zy.validateName)(e))throw new Error((0,Wy.getContext)(this.up())+": entity reference name"+(' "'+e+'" should not contain characters not')+" allowed in XML names");this._name=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"&"+this._name+";"},t.prototype.up=function(){return this._parent},t}();$s.default=Jy});var Mn=y(pr=>{"use strict";var Xs=pr&&pr.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(pr,"__esModule",{value:!0});var Bs=ae(),xd=Rn(),Vy=Lt(),Us=Y(),Ky=Xs(js()),Yy=Xs(Fn()),Qy=Xs(kn()),Zy=function(){function t(e,r,n){this._validation=r,(0,Us.isUndefined)(n.replaceInvalidCharsInName)?this._replaceInvalidCharsInName=!1:this._replaceInvalidCharsInName=n.replaceInvalidCharsInName,this._children=[],this._parent=e,this.name=n.name}return Object.defineProperty(t.prototype,"name",{get:function(){return this._name},set:function(e){if(this._replaceInvalidCharsInName){if(e=(0,Us.fixName)(e),e.length===0)throw new Error((0,Bs.getContext)(this.up())+": attribute name should not be empty")}else if(this._validation&&!(0,Us.validateName)(e))throw e.length===0?new Error((0,Bs.getContext)(this.up())+": attribute name should not be empty"):new Error((0,Bs.getContext)(this.up())+": attribute name"+(' "'+e+'" should not contain characters not')+" allowed in XML names");this._name=e},enumerable:!1,configurable:!0}),t.prototype.charRef=function(e){var r=new Yy.default(this,this._validation,e);return this._children.push(r),r},t.prototype.entityRef=function(e){var r=new Qy.default(this,this._validation,e);return this._children.push(r),r},t.prototype.text=function(e){var r=new Ky.default(this,this._validation,e);return this._children.push(r),r},t.prototype.toString=function(e){e===void 0&&(e={});for(var r=new Vy.StringOptions(e),n=r.doubleQuotes?'"':"'",i=this._name+"="+n,s=0,o=this._children;s<o.length;s++){var a=o[s];r.doubleQuotes?i+=(0,xd.escapeDoubleQuotes)(a.toString()):i+=(0,xd.escapeSingleQuotes)(a.toString())}return i+=n,i},t.prototype.up=function(){return this._parent},t}();pr.default=Zy});var Gs=y(Hs=>{"use strict";Object.defineProperty(Hs,"__esModule",{value:!0});var ev=ae(),tv=Y(),rv=function(){function t(e,r,n){this._validation=r,this._parent=e,this.charData=n.charData}return Object.defineProperty(t.prototype,"charData",{get:function(){return this._charData},set:function(e){if(this._validation&&!(0,tv.validateChar)(e))throw new Error((0,ev.getContext)(this.up())+": attribute-list"+(' declaration "'+e+'" should not contain')+" characters not allowed in XML");this._charData=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"<!ATTLIST "+this._charData+">"},t.prototype.up=function(){return this._parent},t}();Hs.default=rv});var zs=y(Ws=>{"use strict";Object.defineProperty(Ws,"__esModule",{value:!0});var nv=ae(),iv=Y(),sv=function(){function t(e,r,n){this._validation=r,this._parent=e,this.charData=n.charData}return Object.defineProperty(t.prototype,"charData",{get:function(){return this._charData},set:function(e){if(this._validation&&!(0,iv.validateChar)(e))throw new Error((0,nv.getContext)(this.up())+": element declaration"+(' "'+e+'" should not contain characters')+" not allowed in XML");this._charData=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"<!ELEMENT "+this._charData+">"},t.prototype.up=function(){return this._parent},t}();Ws.default=sv});var Vs=y(Js=>{"use strict";Object.defineProperty(Js,"__esModule",{value:!0});var ov=ae(),av=Y(),uv=function(){function t(e,r,n){this._validation=r,this._parent=e,this.charData=n.charData}return Object.defineProperty(t.prototype,"charData",{get:function(){return this._charData},set:function(e){if(this._validation&&!(0,av.validateChar)(e))throw new Error((0,ov.getContext)(this.up())+": entity declaration"+(' "'+e+'" should not contain characters')+" not allowed in XML");this._charData=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"<!ENTITY "+this._charData+">"},t.prototype.up=function(){return this._parent},t}();Js.default=uv});var Ys=y(Ks=>{"use strict";Object.defineProperty(Ks,"__esModule",{value:!0});var cv=ae(),lv=Y(),fv=function(){function t(e,r,n){this._validation=r,this._parent=e,this.charData=n.charData}return Object.defineProperty(t.prototype,"charData",{get:function(){return this._charData},set:function(e){if(this._validation&&!(0,lv.validateChar)(e))throw new Error((0,cv.getContext)(this.up())+": notation declaration"+(' "'+e+'" should not contain characters')+" not allowed in XML");this._charData=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"<!NOTATION "+this._charData+">"},t.prototype.up=function(){return this._parent},t}();Ks.default=fv});var Zs=y(Qs=>{"use strict";Object.defineProperty(Qs,"__esModule",{value:!0});var dv=ae(),hv=Y(),pv=function(){function t(e,r,n){this._validation=r,this._parent=e,this.name=n.name}return Object.defineProperty(t.prototype,"name",{get:function(){return this._name},set:function(e){if(this._validation&&!(0,hv.validateName)(e))throw new Error((0,dv.getContext)(this.up())+": parameter entity"+(' reference name "'+e+'" should not contain')+" characters not allowed in XML names");this._name=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"%"+this._name+";"},t.prototype.up=function(){return this._parent},t}();Qs.default=pv});var mr=y(eo=>{"use strict";Object.defineProperty(eo,"__esModule",{value:!0});var qn=ae(),Tn=Y(),mv=function(){function t(e,r,n){this._validation=r,this._parent=e,this.content=n.content,this.target=n.target}return Object.defineProperty(t.prototype,"content",{get:function(){return this._content},set:function(e){if(!(0,Tn.isUndefined)(e)){if(this._validation&&!(0,Tn.validateChar)(e))throw new Error((0,qn.getContext)(this.up())+": processing"+(' instruction content "'+e+'" should')+" not contain characters not allowed in XML");if(this._validation&&e.indexOf("?>")!==-1)throw new Error((0,qn.getContext)(this.up())+": processing"+(' instruction content "'+e+'" should')+" not contain the string '?>'")}this._content=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"target",{get:function(){return this._target},set:function(e){if(this._validation&&!(0,Tn.validateName)(e))throw new Error((0,qn.getContext)(this.up())+": processing"+(' instruction target "'+e+'" should')+" not contain characters not allowed in XML names");if(this._validation&&e==="xml")throw new Error((0,qn.getContext)(this.up())+": processing"+(' instruction target "'+e+'" should')+" not be the string 'xml'");this._target=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return(0,Tn.isUndefined)(this._content)?"<?"+this._target+"?>":"<?"+this._target+" "+this._content+"?>"},t.prototype.up=function(){return this._parent},t}();eo.default=mv});var Nn=y(ht=>{"use strict";var pt=ht&&ht.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ht,"__esModule",{value:!0});ht.validatePubId=void 0;var tt=ae(),gv=Lt(),Be=Y(),yv=pt(gr()),vv=pt(Gs()),bv=pt(zs()),_v=pt(Vs()),wv=pt(Ys()),xv=pt(Zs()),Sv=pt(mr()),Ev=function(){function t(e,r,n){this._pubId=void 0,this._sysId=void 0,this._validation=r,this._children=[],this._parent=e,this.name=n.name,(0,Be.isUndefined)(n.sysId)||(this.sysId=n.sysId),(0,Be.isUndefined)(n.pubId)||(this.pubId=n.pubId)}return Object.defineProperty(t.prototype,"name",{get:function(){return this._name},set:function(e){if(this._validation&&!(0,Be.validateName)(e))throw new Error((0,tt.getContext)(this.up())+': DTD name "'+e+'" should not contain characters not allowed in XML names');this._name=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"pubId",{get:function(){return this._pubId},set:function(e){if(!(0,Be.isUndefined)(e)){if(this._validation&&!Sd(e))throw new Error((0,tt.getContext)(this.up())+": DTD public"+(' identifier "'+e+'" should not contain')+" characters not allowed in public identifiers");if(this._validation&&(0,Be.isUndefined)(this._sysId))throw new Error((0,tt.getContext)(this.up())+": DTD public"+(' identifier "'+e+'" should not be defined')+" if system identifier is undefined")}this._pubId=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"sysId",{get:function(){return this._sysId},set:function(e){if(!(0,Be.isUndefined)(e)){if(this._validation&&!(0,Be.validateChar)(e))throw new Error((0,tt.getContext)(this.up())+": DTD system"+(' identifier "'+e+'" should not contain')+" characters not allowed in XML");if(this._validation&&e.indexOf("'")!==-1&&e.indexOf('"')!==-1)throw new Error((0,tt.getContext)(this.up())+": DTD system"+(' identifier "'+e+'" should not contain')+" both single quotes and double quotes")}this._sysId=e},enumerable:!1,configurable:!0}),t.prototype.attlist=function(e){var r=new vv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.comment=function(e){var r=new yv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.element=function(e){var r=new bv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.entity=function(e){var r=new _v.default(this,this._validation,e);return this._children.push(r),r},t.prototype.notation=function(e){var r=new wv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.paramEntityRef=function(e){var r=new xv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.procInst=function(e){var r=new Sv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.toString=function(e){e===void 0&&(e={});var r=new gv.StringOptions(e),n="<!DOCTYPE "+this._name;if((0,Be.isUndefined)(this._pubId))(0,Be.isUndefined)(this._sysId)||(n+=" ",n=this.appendId("SYSTEM",this._sysId,n,r));else{if((0,Be.isUndefined)(this._sysId))throw new Error((0,tt.getContext)(this.up())+": DTD system identifier is not undefined");n+=" ",n=this.appendId("PUBLIC",this._pubId,n,r),n=this.appendId("",this._sysId,n,r)}if(this._children.length!==0){n+=" [";for(var i=0,s=this._children;i<s.length;i++){var o=s[i];r.pretty&&(n+=r.newline+r.indent),n+=o.toString()}r.pretty&&(n+=r.newline),n+="]>"}else n+=">";return n},t.prototype.up=function(){return this._parent},t.prototype.appendId=function(e,r,n,i){if(n+=e+" ",i.doubleQuotes){if(this._validation&&r.indexOf('"')!==-1)throw new Error((0,tt.getContext)(this.up())+": doubleQuotes option inconsistent with DTD system identifier or public identifier");n+='"'+r+'"'}else{if(this._validation&&r.indexOf("'")!==-1)throw new Error((0,tt.getContext)(this)+": doubleQuotes option inconsistent with DTD system identifier or public identifier");n+="'"+r+"'"}return n},t}();ht.default=Ev;function Sd(t){for(var e=0;e<t.length;e++){var r=t.charCodeAt(e);if(!(r===10||r===13||r===32||r===33||r>=35&&r<=37||r>=39&&r<=47||r>=48&&r<=57||r===58||r===59||r===61||r===63||r>=64&&r<=90||r===95||r>=97&&r<=122))return e+1===t.length,!1}return!0}ht.validatePubId=Sd});var no=y(ro=>{"use strict";Object.defineProperty(ro,"__esModule",{value:!0});var Ed=ae(),to=Y(),Cv=function(){function t(e,r,n){this._validation=r,(0,to.isUndefined)(n.replaceInvalidCharsInCharData)?this._replaceInvalidCharsInCharData=!1:this._replaceInvalidCharsInCharData=n.replaceInvalidCharsInCharData,this._parent=e,this.charData=n.charData}return Object.defineProperty(t.prototype,"charData",{get:function(){return this._charData},set:function(e){if(this._replaceInvalidCharsInCharData)e=(0,to.fixChar)(e);else if(this._validation&&!(0,to.validateChar)(e))throw new Error((0,Ed.getContext)(this.up())+": CDATA section"+(' "'+e+'" should not contain characters')+" not allowed in XML");if(this._replaceInvalidCharsInCharData)e=e.replace("]]>","\uFFFD\uFFFD\uFFFD");else if(this._validation&&e.indexOf("]]>")!==-1)throw new Error((0,Ed.getContext)(this.up())+": CDATA section"+(' "'+e+'" should not contain the string')+" ']]>'");this._charData=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"<![CDATA["+this._charData+"]]>"},t.prototype.up=function(){return this._parent},t}();ro.default=Cv});var ao=y(oo=>{"use strict";Object.defineProperty(oo,"__esModule",{value:!0});var Pv=ae(),io=Rn(),so=Y(),Dv=function(){function t(e,r,n){this._validation=r,(0,so.isUndefined)(n.replaceInvalidCharsInCharData)?this._replaceInvalidCharsInCharData=!1:this._replaceInvalidCharsInCharData=n.replaceInvalidCharsInCharData,this._parent=e,this.charData=n.charData}return Object.defineProperty(t.prototype,"charData",{get:function(){return this._charData},set:function(e){if(this._replaceInvalidCharsInCharData)e=(0,so.fixChar)(e);else if(this._validation&&!(0,so.validateChar)(e))throw new Error((0,Pv.getContext)(this.up())+": character data"+('"'+e+'" should not contain characters not')+" allowed in XML");this._charData=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){var e=this._charData;return e=(0,io.escapeAmpersands)(e),e=(0,io.escapeLeftAngleBrackets)(e),e=(0,io.escapeRightAngleBracketsInCdataTerminator)(e),e},t.prototype.up=function(){return this._parent},t}();oo.default=Dv});var Bn=y(br=>{"use strict";var mt=br&&br.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(br,"__esModule",{value:!0});var jn=ae(),Ov=Lt(),yr=Y(),Cd=mt(Mn()),Av=mt(no()),vr=mt(ao()),Ln=mt(Fn()),Iv=mt(gr()),$n=mt(kn()),Rv=mt(mr()),Fv=function(){function t(e,r,n){this._validation=r,(0,yr.isUndefined)(n.replaceInvalidCharsInName)?this._replaceInvalidCharsInName=!1:this._replaceInvalidCharsInName=n.replaceInvalidCharsInName,(0,yr.isUndefined)(n.useSelfClosingTagIfEmpty)?this._useSelfClosingTagIfEmpty=!0:this._useSelfClosingTagIfEmpty=n.useSelfClosingTagIfEmpty,this._children=[],this._attributeNames=[],this._parent=e,this.name=n.name}return Object.defineProperty(t.prototype,"name",{get:function(){return this._name},set:function(e){if(this._replaceInvalidCharsInName){if(e=(0,yr.fixName)(e),e.length===0)throw new Error((0,jn.getContext)(this.up())+": element name should not be empty")}else if(this._validation&&!(0,yr.validateName)(e))throw e.length===0?new Error((0,jn.getContext)(this.up())+": element name should not be empty"):new Error((0,jn.getContext)(this.up())+": element name"+(' "'+e+'" should not contain characters not')+" allowed in XML names");this._name=e},enumerable:!1,configurable:!0}),t.prototype.attribute=function(e){if(this._validation&&this._attributeNames.indexOf(e.name)!==-1)throw new Error((0,jn.getContext)(this.up())+': element "'+this.name+'" already contains an attribute with the'+(' name "'+e.name+'"'));var r=new Cd.default(this,this._validation,e);return this._children.push(r),this._attributeNames.push(e.name),r},t.prototype.cdata=function(e){var r=new Av.default(this,this._validation,e);return this._children.push(r),r},t.prototype.charData=function(e){var r=new vr.default(this,this._validation,e);return this._children.push(r),r},t.prototype.charRef=function(e){var r=new Ln.default(this,this._validation,e);return this._children.push(r),r},t.prototype.comment=function(e){var r=new Iv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.element=function(e){var r=new t(this,this._validation,e);return this._children.push(r),r},t.prototype.entityRef=function(e){var r=new $n.default(this,this._validation,e);return this._children.push(r),r},t.prototype.procInst=function(e){var r=new Rv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.toString=function(e){return e===void 0&&(e={}),this.toStringWithIndent(e,"")},t.prototype.up=function(){return this._parent},t.prototype.toStringWithIndent=function(e,r){for(var n=new Ov.StringOptions(e),i=r+n.indent,s="<"+this._name,o=[],a=0,u=this._children;a<u.length;a++){var h=u[a];h instanceof Cd.default?s+=" "+h.toString(e):o.push(h)}if(o.length>0){for(var c="",p=0;p<o.length;p++){var g=o[p],m="";g instanceof t?m+=g.toStringWithIndent(n,i):m+=g.toString();var _=p>0?o[p-1]:void 0;g instanceof vr.default&&g.toString()===""||(n.pretty&&(this.allSameLineNodes(o)||p>0&&this.onSameLine(g,_)||(m=n.newline+i+m)),c+=m)}n.pretty&&(this.allSameLineNodes(o)||(c+=n.newline+r)),c.length===0&&this._useSelfClosingTagIfEmpty?s+="/>":s+=">"+c+"</"+this._name+">"}else this._useSelfClosingTagIfEmpty?s+="/>":s+="></"+this._name+">";return s},t.prototype.allSameLineNodes=function(e){for(var r=0,n=e;r<n.length;r++){var i=n[r];if(!(i instanceof Ln.default||i instanceof $n.default||i instanceof vr.default))return!1}return!0},t.prototype.onSameLine=function(e,r){return(e instanceof Ln.default||e instanceof $n.default||e instanceof vr.default)&&!(0,yr.isUndefined)(r)&&(r instanceof Ln.default||r instanceof $n.default||r instanceof vr.default)},t}();br.default=Fv});var ae=y($t=>{"use strict";var Xn=$t&&$t.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty($t,"__esModule",{value:!0});$t.getContext=void 0;var kv=Xn(Mn()),Mv=Xn(Hn()),qv=Xn(Nn()),Tv=Xn(Bn());function Un(t){if(t instanceof kv.default)return Un(t.up())+(' > attribute "'+t.name+'"');if(t instanceof Mv.default)return"in XML document";if(t instanceof qv.default)return Un(t.up())+" > DTD";if(t instanceof Tv.default)return Un(t.up())+(' > element "'+t.name+'"');throw new Error("Unrecognized object of type "+Object.prototype.toString.call(t))}$t.getContext=Un});var gr=y(lo=>{"use strict";Object.defineProperty(lo,"__esModule",{value:!0});var uo=ae(),co=Y(),Nv=function(){function t(e,r,n){this._validation=r,(0,co.isUndefined)(n.replaceInvalidCharsInCharData)?this._replaceInvalidCharsInCharData=!1:this._replaceInvalidCharsInCharData=n.replaceInvalidCharsInCharData,this._parent=e,this.charData=n.charData}return Object.defineProperty(t.prototype,"charData",{get:function(){return this._charData},set:function(e){if(this._replaceInvalidCharsInCharData)e=(0,co.fixChar)(e);else if(this._validation&&!(0,co.validateChar)(e))throw new Error((0,uo.getContext)(this.up())+": comment content"+(' "'+e+'" should not contain characters')+" not allowed in XML");if(this._replaceInvalidCharsInCharData)e=e.replace("--","\uFFFD\uFFFD");else if(this._validation&&e.indexOf("--")!==-1)throw new Error((0,uo.getContext)(this.up())+": comment content"+(' "'+e+'" should not contain the string')+" '--'");if(this._replaceInvalidCharsInCharData)e.lastIndexOf("-")===e.length-1&&(e=e.substr(0,e.length-1)+"\uFFFD");else if(this._validation&&e.lastIndexOf("-")===e.length-1)throw new Error((0,uo.getContext)(this.up())+": comment content"+(' "'+e+'" should not end with the string')+" '-'");this._charData=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(){return"<!--"+this._charData+"-->"},t.prototype.up=function(){return this._parent},t}();lo.default=Nv});var po=y(ho=>{"use strict";Object.defineProperty(ho,"__esModule",{value:!0});var fo=ae(),jv=Lt(),_r=Y(),Lv=function(){function t(e,r,n){this._version="1.0",this._validation=r,this._parent=e,this.encoding=n.encoding,this.standalone=n.standalone,(0,_r.isUndefined)(n.version)||(this.version=n.version)}return Object.defineProperty(t.prototype,"encoding",{get:function(){return this._encoding},set:function(e){if(this._validation&&!(0,_r.isUndefined)(e)&&!$v(e))throw new Error((0,fo.getContext)(this.up())+": declaration"+(" encoding attribute "+e+" should be a")+" valid encoding");this._encoding=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"standalone",{get:function(){return this._standalone},set:function(e){if(this._validation&&!(0,_r.isUndefined)(e)&&e!=="yes"&&e!=="no")throw new Error((0,fo.getContext)(this.up())+": declaration"+(" standalone attribute "+e+" should")+" be the string 'yes' or the string 'no'");this._standalone=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"version",{get:function(){return this._version},set:function(e){if(this._validation&&!Bv(e))throw new Error((0,fo.getContext)(this.up())+": declaration version"+(" attribute "+e+" should be a valid XML")+" version");this._version=e},enumerable:!1,configurable:!0}),t.prototype.toString=function(e){e===void 0&&(e={});var r=new jv.StringOptions(e),n=r.doubleQuotes?'"':"'",i="<?xml version="+n+this._version+n;return(0,_r.isUndefined)(this._encoding)||(i+=" encoding="+n+this._encoding+n),(0,_r.isUndefined)(this._standalone)||(i+=" standalone="+n+this._standalone+n),i+="?>",i},t.prototype.up=function(){return this._parent},t}();ho.default=Lv;function $v(t){if(t.length===0)return!1;var e=t.charCodeAt(0);if(!(e>=65&&e<=90||e>=97&&e<=122))return!1;for(var r=1;r<t.length;r++){var n=t.charCodeAt(r);if(!(n===95||n===45||n===46||n>=48&&n<=57||n>=65&&n<=90||n>=97&&n<=122))return r+1===t.length,!1}return!0}function Bv(t){for(var e=0;e<=9;e++)if(t==="1."+e)return!0;return!1}});var Hn=y(xr=>{"use strict";var Sr=xr&&xr.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(xr,"__esModule",{value:!0});var Uv=Lt(),Xv=Y(),Hv=Sr(gr()),Pd=Sr(po()),Dd=Sr(Nn()),wr=Sr(Bn()),Gv=Sr(mr()),Wv=function(){function t(e){this._children=[],this._validation=(0,Xv.isUndefined)(e.validation)?!0:e.validation}return t.prototype.comment=function(e){var r=new Hv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.decl=function(e){if(e===void 0&&(e={}),this._validation&&this._children.length!==0)throw new Error("in XML document: declaration must be the first child");var r=new Pd.default(this,this._validation,e);return this._children.push(r),r},t.prototype.dtd=function(e){var r=this._children.filter(function(i){return i instanceof wr.default});if(this._validation&&r.length!==0)throw new Error("in XML document: DTD must precede the root element");var n=new Dd.default(this,this._validation,e);return this._children.push(n),n},t.prototype.element=function(e){var r=this._children.filter(function(i){return i instanceof wr.default});if(this._validation&&r.length!==0)throw new Error("in XML document: only one root element is permitted");var n=new wr.default(this,this._validation,e);return this._children.push(n),n},t.prototype.procInst=function(e){var r=new Gv.default(this,this._validation,e);return this._children.push(r),r},t.prototype.toString=function(e){e===void 0&&(e={});var r=this._children.filter(function(h){return h instanceof wr.default});if(this._validation&&r.length!==1)throw new Error("in XML document: no more than one root element is permitted");for(var n=new Uv.StringOptions(e),i="",s=0,o=this._children;s<o.length;s++){var a=o[s];a instanceof Pd.default||a instanceof Dd.default||a instanceof wr.default?i+=a.toString(e):i+=a.toString(),n.pretty&&(i+=n.newline)}var u=i.length-n.newline.length;return i.substr(u)===n.newline&&(i=i.substr(0,u)),i},t}();xr.default=Wv});var Od=y(q=>{"use strict";var ee=q&&q.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(q,"__esModule",{value:!0});q.document=q.XmlProcInst=q.XmlEntityRef=q.XmlElement=q.XmlDtdParamEntityRef=q.XmlDtdNotation=q.XmlDtdEntity=q.XmlDtdElement=q.XmlDtdAttlist=q.XmlDtd=q.XmlDocument=q.XmlDecl=q.XmlComment=q.XmlCharRef=q.XmlCharData=q.XmlCdata=q.XmlAttributeText=q.XmlAttribute=void 0;var zv=ee(Hn()),Jv=Mn();Object.defineProperty(q,"XmlAttribute",{enumerable:!0,get:function(){return ee(Jv).default}});var Vv=js();Object.defineProperty(q,"XmlAttributeText",{enumerable:!0,get:function(){return ee(Vv).default}});var Kv=no();Object.defineProperty(q,"XmlCdata",{enumerable:!0,get:function(){return ee(Kv).default}});var Yv=ao();Object.defineProperty(q,"XmlCharData",{enumerable:!0,get:function(){return ee(Yv).default}});var Qv=Fn();Object.defineProperty(q,"XmlCharRef",{enumerable:!0,get:function(){return ee(Qv).default}});var Zv=gr();Object.defineProperty(q,"XmlComment",{enumerable:!0,get:function(){return ee(Zv).default}});var e1=po();Object.defineProperty(q,"XmlDecl",{enumerable:!0,get:function(){return ee(e1).default}});var t1=Hn();Object.defineProperty(q,"XmlDocument",{enumerable:!0,get:function(){return ee(t1).default}});var r1=Nn();Object.defineProperty(q,"XmlDtd",{enumerable:!0,get:function(){return ee(r1).default}});var n1=Gs();Object.defineProperty(q,"XmlDtdAttlist",{enumerable:!0,get:function(){return ee(n1).default}});var i1=zs();Object.defineProperty(q,"XmlDtdElement",{enumerable:!0,get:function(){return ee(i1).default}});var s1=Vs();Object.defineProperty(q,"XmlDtdEntity",{enumerable:!0,get:function(){return ee(s1).default}});var o1=Ys();Object.defineProperty(q,"XmlDtdNotation",{enumerable:!0,get:function(){return ee(o1).default}});var a1=Zs();Object.defineProperty(q,"XmlDtdParamEntityRef",{enumerable:!0,get:function(){return ee(a1).default}});var u1=Bn();Object.defineProperty(q,"XmlElement",{enumerable:!0,get:function(){return ee(u1).default}});var c1=kn();Object.defineProperty(q,"XmlEntityRef",{enumerable:!0,get:function(){return ee(c1).default}});var l1=mr();Object.defineProperty(q,"XmlProcInst",{enumerable:!0,get:function(){return ee(l1).default}});function f1(t){return t===void 0&&(t={}),new zv.default(t)}q.document=f1});var mo=y(te=>{"use strict";Object.defineProperty(te,"__esModule",{value:!0});te.stringify=te.isMap=te.isSet=te.isFunction=te.isArray=te.isObject=te.isNull=te.isUndefined=void 0;function Ad(t){return Object.prototype.toString.call(t)==="[object Undefined]"}te.isUndefined=Ad;function Id(t){return Object.prototype.toString.call(t)==="[object Null]"}te.isNull=Id;function d1(t){return Object.prototype.toString.call(t)==="[object Object]"}te.isObject=d1;function h1(t){return Object.prototype.toString.call(t)==="[object Array]"}te.isArray=h1;function Rd(t){return Object.prototype.toString.call(t)==="[object Function]"}te.isFunction=Rd;function p1(t){return Object.prototype.toString.call(t)==="[object Set]"}te.isSet=p1;function m1(t){return Object.prototype.toString.call(t)==="[object Map]"}te.isMap=m1;function g1(t){return!Ad(t)&&!Id(t)&&Rd(t?.toString)&&(t=t.toString()),String(t)}te.stringify=g1});var Nd=y(Ce=>{"use strict";Object.defineProperty(Ce,"__esModule",{value:!0});Ce.WrapHandlers=Ce.TypeHandlers=Ce.FormatOptions=Ce.DtdOptions=Ce.DeclarationOptions=Ce.Options=void 0;var Le=mo(),y1=function(){function t(e){e===void 0&&(e={}),this.aliasString="=",this.attributeString="@",this.cdataInvalidChars=!1,this.cdataKeys=[],this.replaceInvalidChars=!1,this.useSelfClosingTagIfEmpty=!0,this.validation=!0,this.valueString="#",(0,Le.isUndefined)(e.validation)||(this.validation=e.validation),(0,Le.isUndefined)(e.aliasString)||(this.aliasString=e.aliasString),(0,Le.isUndefined)(e.attributeString)||(this.attributeString=e.attributeString),(0,Le.isUndefined)(e.cdataInvalidChars)||(this.cdataInvalidChars=e.cdataInvalidChars),(0,Le.isUndefined)(e.cdataKeys)||(this.cdataKeys=e.cdataKeys),this.declaration=new Fd(e.declaration),this.dtd=new kd(this.validation,e.dtd),this.format=new Md(e.format),(0,Le.isUndefined)(e.replaceInvalidChars)||(this.replaceInvalidChars=e.replaceInvalidChars),this.typeHandlers=new qd(e.typeHandlers),(0,Le.isUndefined)(e.useSelfClosingTagIfEmpty)||(this.useSelfClosingTagIfEmpty=e.useSelfClosingTagIfEmpty),(0,Le.isUndefined)(e.valueString)||(this.valueString=e.valueString),this.wrapHandlers=new Td(e.wrapHandlers)}return t}();Ce.Options=y1;var Fd=function(){function t(e){e===void 0&&(e={}),this.include=!0,(0,Le.isUndefined)(e.include)||(this.include=e.include),this.encoding=e.encoding,this.standalone=e.standalone,this.version=e.version}return t}();Ce.DeclarationOptions=Fd;var kd=function(){function t(e,r){if(r===void 0&&(r={}),this.include=!1,(0,Le.isUndefined)(r.include)||(this.include=r.include),e&&(0,Le.isUndefined)(r.name)&&this.include)throw new Error("options.dtd.name should be defined if options.dtd.include is true");this.name=r.name,this.sysId=r.sysId,this.pubId=r.pubId}return t}();Ce.DtdOptions=kd;var Md=function(){function t(e){e===void 0&&(e={}),this.doubleQuotes=e.doubleQuotes,this.indent=e.indent,this.newline=e.newline,this.pretty=e.pretty}return t}();Ce.FormatOptions=Md;var qd=function(){function t(e){e===void 0&&(e={});for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(this[r]=e[r])}return t}();Ce.TypeHandlers=qd;var Td=function(){function t(e){e===void 0&&(e={});for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(this[r]=e[r])}return t}();Ce.WrapHandlers=Td});var Xd=y(rt=>{"use strict";Object.defineProperty(rt,"__esModule",{value:!0});rt.parse=rt.parseToExistingElement=rt.Absent=void 0;var Ld=Od(),$d=Nd(),V=mo(),go=function(){function t(){}return Object.defineProperty(t,"instance",{get:function(){return t._instance},enumerable:!1,configurable:!0}),t._instance=new t,t}();rt.Absent=go;function yo(t,e){var r=Object.prototype.toString.call(t),n;return Object.prototype.hasOwnProperty.call(e.typeHandlers,"*")&&(n=e.typeHandlers["*"]),Object.prototype.hasOwnProperty.call(e.typeHandlers,r)&&(n=e.typeHandlers[r]),n}function Bd(t,e,r){var n=function(o){return r.cdataInvalidChars&&(o.indexOf("<")!==-1||o.indexOf("&")!==-1)||r.cdataKeys.indexOf(e.name)!==-1||r.cdataKeys.indexOf("*")!==-1};if(e instanceof Ld.XmlElement)if(n(t))for(var i=t.split("]]>"),s=0;s<i.length;s++)n(i[s])?e.cdata({charData:i[s],replaceInvalidCharsInCharData:r.replaceInvalidChars}):e.charData({charData:i[s],replaceInvalidCharsInCharData:r.replaceInvalidChars}),s<i.length-1&&e.charData({charData:"]]>",replaceInvalidCharsInCharData:r.replaceInvalidChars});else e.charData({charData:t,replaceInvalidCharsInCharData:r.replaceInvalidChars});else e.text({charData:t,replaceInvalidCharsInCharData:r.replaceInvalidChars})}function v1(t,e,r,n){var i=r.attribute({name:t,replaceInvalidCharsInName:n.replaceInvalidChars});Bd((0,V.stringify)(e),i,n)}function jd(t,e,r,n){if(t===n.aliasString){r.name=(0,V.stringify)(e);return}if(t.indexOf(n.attributeString)===0&&(0,V.isObject)(e)){for(var i=0,s=Object.keys(e);i<s.length;i++){var o=s[i];v1(o,(0,V.stringify)(e[o]),r,n)}return}if(t.indexOf(n.valueString)===0){Gn(t,(0,V.stringify)(e),r,n);return}var a=r;if(!(0,V.isArray)(e)&&!(0,V.isSet)(e)){var u=yo(e,n);if(!(0,V.isUndefined)(u)&&u(e)===go.instance)return;a=r.element({name:t,replaceInvalidCharsInName:n.replaceInvalidChars,useSelfClosingTagIfEmpty:n.useSelfClosingTagIfEmpty})}Gn(t,e,a,n)}function b1(t,e,r){if((0,V.isMap)(t))t.forEach(function(o,a){jd((0,V.stringify)(a),o,e,r)});else for(var n=0,i=Object.keys(t);n<i.length;n++){var s=i[n];jd(s,t[s],e,r)}}function _1(t,e,r,n){var i;Object.prototype.hasOwnProperty.call(n.wrapHandlers,"*")&&(i=n.wrapHandlers["*"]),Object.prototype.hasOwnProperty.call(n.wrapHandlers,t)&&(i=n.wrapHandlers[t]);var s=t,o=r;if(!(0,V.isUndefined)(i)){var a=i(s,e);(0,V.isNull)(a)||(s=a,o=r.element({name:t,replaceInvalidCharsInName:n.replaceInvalidChars,useSelfClosingTagIfEmpty:n.useSelfClosingTagIfEmpty}))}e.forEach(function(u){var h=o;if(!(0,V.isArray)(u)&&!(0,V.isSet)(u)){var c=yo(u,n);if(!(0,V.isUndefined)(c)&&c(u)===go.instance)return;h=o.element({name:s,replaceInvalidCharsInName:n.replaceInvalidChars,useSelfClosingTagIfEmpty:n.useSelfClosingTagIfEmpty})}Gn(s,u,h,n)})}function Gn(t,e,r,n){var i=yo(e,n);if((0,V.isUndefined)(i)||(e=i(e)),(0,V.isObject)(e)||(0,V.isMap)(e)){b1(e,r,n);return}if((0,V.isArray)(e)||(0,V.isSet)(e)){_1(t,e,r,n);return}Bd((0,V.stringify)(e),r,n)}function Ud(t,e,r){var n=new $d.Options(r);Gn(t.name,e,t,n)}rt.parseToExistingElement=Ud;function w1(t,e,r){var n=new $d.Options(r),i=new Ld.XmlDocument({validation:n.validation});n.declaration.include&&i.decl(n.declaration),n.dtd.include&&i.dtd({name:n.dtd.name,pubId:n.dtd.pubId,sysId:n.dtd.sysId});var s=i.element({name:t,replaceInvalidCharsInName:n.replaceInvalidChars,useSelfClosingTagIfEmpty:n.useSelfClosingTagIfEmpty});return Ud(s,e,r),i.toString(n.format)}rt.parse=w1});var Ou=T(Si()),Au=T(Yt()),Ai=class{user;password;baseUrl;headers;constructor(){this.user=process.env.botEmail,this.password=process.env.botPassword,this.baseUrl=process.env.API_URL}async login(){try{let e=await(0,Ou.default)({url:`${this.baseUrl}/login_check`,method:"POST",headers:{"Content-Type":"application/json"},data:{username:this.user,password:this.password}});if(e.status===200){let{data:{token:r}}=e;this.headers={Authorization:"bearer "+r,"Cache-Control":"no-store"}}return this.headers}catch{console.error(Au.default.red(`
24
24
  \u256D\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u256E
25
25
  \u2502 Access credentials failure \u2502
26
26
  \u2502 Check that the login details are correct in your .env file \u2502
27
27
  \u2570\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u256F
28
- `)),process.exit(1)}}},Ar=new Kn;var el=K(Yn()),tl=K(gt()),rl=K(Gt());var yp=K(gt()),Vu=K(Gt()),gp=K(gn()),Yu=K(Wu());var Ju="10.3.13";Vu.default.config();var vp=!!process.env.GRIDDO_BUILD_LOGS&&!!JSON.parse(process.env.GRIDDO_BUILD_LOGS)||!!process.env.LOGS&&!!JSON.parse(process.env.LOGS);function Ku(e){let t=e.length,r=e.length+2,n=" ".repeat(Math.floor((r-t)/2)),i=`\u256D${"\u2500".repeat(r)}\u256E
28
+ `)),process.exit(1)}}},Ct=new Ai;var sd=T(Si()),od=T(Yt()),ad=T(Xe());var dn=T(require("node:crypto")),ft=T(require("node:fs")),Vi=T(require("node:path")),Ki=T(Ft()),hn=Vi.default.resolve(__dirname,"./../apiCache"),Ll=`${hn}/siteHash.json`;function $l(){ft.default.existsSync(hn)||ft.default.mkdirSync(hn),console.info("Cache initialized")}function Bl(t){let e=dn.default.createHash("sha256");return e.update(JSON.stringify(t)),`${hn}/${e.digest("hex")}`}function Ul(t){let e=dn.default.randomBytes(16).toString("hex"),r=dn.default.createHash("sha256");return r.update(`${t}${e}`),r.digest("hex")}function Xl(t,e){let r=typeof e=="string"?e:JSON.stringify(e),n=Bl(t),i=Vi.default.dirname(n);ft.default.existsSync(i)||ft.default.mkdirSync(i,{recursive:!0}),ft.default.writeFileSync(n,r,"utf8")}function Hl(t){try{let e=Bl(t);return Ki.default.readJSONSync(e,{encoding:"utf-8"})}catch{return null}}function Pg(){try{return Ki.default.readJSONSync(Ll,{encoding:"utf-8"})||{}}catch{return{}}}function Gl(t,e){let r=Pg(),n=r[t],i=e||n||new Date().valueOf();return i!==n&&(r[t]=i,ft.default.writeFileSync(Ll,JSON.stringify(r),{encoding:"utf-8"})),i.toString()}var ly=T(Yt()),Qf=T(Xe()),Ze=T(Ft()),Zf=T(kf()),bs=T(vs());var En="10.3.15";Qf.default.config();var fy=!!process.env.GRIDDO_BUILD_LOGS&&!!JSON.parse(process.env.GRIDDO_BUILD_LOGS)||!!process.env.LOGS&&!!JSON.parse(process.env.LOGS),ed=bs.default.sync(__dirname),td=bs.default.sync();function _s(t){let e=t.length,r=t.length+2,n=" ".repeat(Math.floor((r-e)/2)),i=`\u256D${"\u2500".repeat(r)}\u256E
29
29
  `,s=`
30
- \u2570${"\u2500".repeat(r)}\u256F`,o=`\u2502${n}${e}${n}\u2502`;console.log(`${i}${o}${s}`)}function fi(e){vp&&console.info(e.replace(/(\s)\s+/g,"$1"))}function Xu(e){return new Promise(t=>setTimeout(t,e))}function Dr(e,t=3){return(e/1e3).toFixed(t)}function hi(e){return"site"in e&&e.site?e?.site:void 0}function di(...e){let t=performance.now();return e.forEach(r=>r()),Dr(performance.now()-t)}function Qu(){let e=`
31
- \xB7\xB7
32
- \xB7\xB7
30
+ \u2570${"\u2500".repeat(r)}\u256F`,o=`\u2502${n}${t}${n}\u2502`;console.log(`${i}${o}${s}`)}function je(t){fy&&console.info(t.replace(/(\s)\s+/g,"$1"))}function rd(t){return new Promise(e=>setTimeout(e,t))}function ws(t,e=3){return(t/1e3).toFixed(e)}function xs(t){return"site"in t&&t.site?t?.site:void 0}function Ss(t,e){for(let r in t)e.includes(r)?delete t[r]:typeof t[r]=="object"&&Ss(t[r],e)}function Es(t){return t.map(({name:e,id:r})=>`${e} (${r})`).join(", ")}function Cs(t){let e=`
33
31
  \xB7\xB7
34
- \xB7\xB7 ______ ______ _____ ______ ______ _____
35
- \xB7\xB7 | ____ |_____/ | | \\ | \\ | |
36
- \xB7\xB7 |_____| | \\_ __|__ |_____/ |_____/ |_____|
37
32
  \xB7\xB7 _______ _ _ _____ _____ ______ _______ _______ ______
38
33
  \xB7\xB7 |______ \\___/ |_____] | | |_____/ | |______ |_____/
39
34
  \xB7\xB7 |______ _/ \\_ | |_____| | \\_ | |______ | \\_
40
35
  \xB7\xB7
41
- \xB7\xB7 Griddo exporter orchestrator
42
- \xB7\xB7 ${Ju}
36
+ \xB7\xB7 Griddo Exporter ${En}
37
+ \xB7\xB7 Adapter: ${t}
43
38
  \xB7\xB7
44
- \xB7\xB7
45
- \xB7\xB7
46
- `;console.log(Yu.default.cristal(e))}rl.default.config();var{env:{RETRY_WAIT_SECONDS:bp="4",RETRY_ATTEMPTS:Zu="4"}}=process;async function nl(e,t,r=""){let{endpoint:n,body:i,cacheKey:s="",attempt:o=1,headers:a}=e,c={endpoint:n,body:i,headers:a,cacheKey:s};if(s){let d=new Date,f=Ca(c);if(f){let p=hi(f),y=p?`site: ${p}`:"",m=Dr(new Date().getTime()-d.getTime());return fi(`${t} (cache) ${y} ${n} - ${m}s ${r}`),f}}try{let d=new Date,{data:f}=await(0,el.default)({url:n,method:t,headers:Object.assign({},a,Ar.headers),data:i}),p=hi(f),y=p?`site: ${p}`:"",m=Dr(new Date().getTime()-d.getTime());return fi(`${t} (fetch) ${y} ${n} - ${m}s ${r}`),ka(c,f),f}catch(d){let f=d;return f.response?.status===404?null:(o>parseInt(Zu)&&(console.log(`Max attempts ${Zu} reached
47
- - ${t.toUpperCase()} ${n}
39
+ `;console.log(Zf.default.cristal(e))}function nd(t){let e=Ze.default.readdirSync(t),r={},n=e.filter(s=>{let o=`${t}/${s}`,a=Ze.default.readJSONSync(o,"utf-8"),{id:u,entity:h,fullUrl:c}=a;return!!(u&&h&&c)});for(let s of n){let o=`${t}/${s}`,a=Ze.default.readJSONSync(o,"utf-8"),u=Ze.default.statSync(o).mtimeMs,{id:h}=a;(!r[h]||u>Ze.default.statSync(`${t}/${r[h]}`).mtimeMs)&&(r[h]=s)}let i=0;for(let s of n){let o=`${t}/${s}`,a=Ze.default.readJSONSync(o,"utf-8"),{id:u}=a;s!==r[u]&&(Ze.default.unlinkSync(o),i++)}console.log(`Sanitize apiCache folder for ${i} files`)}async function dr(...t){let e=process.hrtime();for(let s of t)await s();let[r,n]=process.hrtime(e);return+(r+n/1e9).toFixed(3)}ad.default.config();var{env:{RETRY_WAIT_SECONDS:dy="4",RETRY_ATTEMPTS:id="4"}}=process;async function Ps(t,e,r=""){let{endpoint:n,body:i,cacheKey:s="",attempt:o=1,headers:a}=t,u={endpoint:n,body:i,headers:a,cacheKey:s};if(s){let h=new Date,c=Hl(u);if(c){let p=xs(c),g=p?`site: ${p}`:"",m=ws(new Date().getTime()-h.getTime());return je(`${e} (cache) ${g} ${n} - ${m}s ${r}`),c}}try{let h=new Date,{data:c}=await(0,sd.default)({url:n,method:e,headers:Object.assign({},a,Ct.headers),data:i}),p=xs(c),g=p?`site: ${p}`:"",m=ws(new Date().getTime()-h.getTime());return je(`${e} (fetch) ${g} ${n} - ${m}s ${r}`),Xl(u,c),c}catch(h){let c=h;return c.response?.status===404?null:(o>parseInt(id)&&(console.log(`
40
+ Max attempts ${id} reached
41
+ --------------------------------------
42
+ - ${e.toUpperCase()} ${n}
48
43
  - BODY: ${JSON.stringify(i)}
49
44
  - HEADERS: ${JSON.stringify(a)}
50
- - RESPONSE: ${f.response?.status,JSON.stringify(f.response?.data)}`),process.exit(1)),f.response||(console.log("Unknown error occurred"),console.log(JSON.stringify(f,null,2)),process.exit(1)),wp(f,{callInfo:{endpoint:n,body:i}}),console.warn(`Waiting for retry: ${t}`,n),await Xu(parseInt(bp)*1e3),nl({endpoint:n,body:i,headers:a,cacheKey:s,attempt:o+1},t,r))}}async function il(e){return await nl(e,"get")}function wp(e,t){let{response:r,message:n,stack:i}=e,{callInfo:s}=t,{status:o,statusText:a,data:c}=r||{},d=[];for(let m of Object.keys(s))d.push(`${m}: ${typeof s[m]=="object"?JSON.stringify(s[m]):s[m]}`);let f=d.join(`
45
+ - RESPONSE: ${c.response?.status,JSON.stringify(c.response?.data)}
46
+ --------------------------------------
47
+ `),process.exit(1)),c.response||(console.log("Unknown error occurred"),console.log(JSON.stringify(c,null,2)),process.exit(1)),hy(c,{callInfo:{endpoint:n,body:i}}),console.warn(`Waiting for retry: ${e}`,n),await rd(parseInt(dy)*1e3),Ps({endpoint:n,body:i,headers:a,cacheKey:s,attempt:o+1},e,r))}}async function Fe(t){return await Ps(t,"get")}async function dt(t){let{endpoint:e,body:r,headers:n}=t,i=e.endsWith("/distributor")&&`# Distributor body: ${JSON.stringify(r)} lang: ${JSON.stringify(n?.lang)}`;return await Ps(t,"post",i||"")}function hy(t,e){let{response:r,message:n,stack:i}=t,{callInfo:s}=e,{status:o,statusText:a,data:u}=r||{},h=[];for(let m of Object.keys(s))h.push(`${m}: ${typeof s[m]=="object"?JSON.stringify(s[m]):s[m]}`);let c=h.join(`
51
48
  `),p=r?`Code: ${o} - ${a}
52
- Response: ${JSON.stringify(c)}`:"",y=`${n}
53
- ${i}`;console.warn(tl.default.bold.red(`
49
+ Response: ${JSON.stringify(u)}`:"",g=`${n}
50
+ ${i}`;console.warn(od.default.bold.red(`
54
51
  =============
55
52
 
56
53
  { Call info }
57
- ${f}
54
+ ${c}
58
55
 
59
56
  { API Response }
60
57
  ${p}
61
58
 
62
59
  { Error details }
63
- ${y}
60
+ ${g}
64
61
 
65
62
  =============
66
- `))}var _p=process.env.API_URL,xp={GET_ALL:`${_p}/domains`},jr=class{static async getAll(){let{GET_ALL:t}=xp;return await il({endpoint:t})}};async function sl(){await Ar.login();let e=await jr.getAll();return Ep(e)}function Ep(e){let t=e.filter(({slug:r})=>!!r).map(({slug:r})=>r.replace("/",""));return[...new Set(t)]}var Sp=process.env.GRIDDO_SKIP_BUILD_CHECKS,kp=[];function ol(){if(Sp)return console.info("\u{1FAE5} Build health check skipped"),!0;if(Cp(kp))return console.info("\u2705 Build health check passed"),!0;Ku("Error. The environment is not suitable for a build."),process.exit(1)}function Cp(e){let t=e.filter(r=>!process.env[r]);if(t.length){let r=t.join(`
67
- `);return console.log(`ENV CHECK FAILED. These envs vars are missing:
68
-
69
- ${r}`),!1}return!0}ul.default.config();var pi=["dist","assets"],mi=["public",".store"],$r=["apiCache"],Rp=!!process.env.GRIDDO_EXPORT_STRIP_DOMAIN_FROM_PATH;Rp?$r.push(".cache"):mi.push(".cache");var Op=!!process.env.GRIDDO_INFRA_BUILD_COMPLETES,Ap=yi.default.sync(),Pp=Ce.default.resolve(Ap,"exports/sites"),qp=Ce.default.resolve(__dirname,"../caches"),ll=yi.default.sync(__dirname),fl=e=>t=>Mp(t,e),Mp=(e,t)=>{let[r,...n]=e.split(" "),{error:i,status:s}=(0,cl.spawnSync)(r,n,{cwd:ll,stdio:["ignore","inherit","ignore"],encoding:"utf8",shell:!0,env:Object.assign({GRIDDO_EXPORTER:"true"},process.env,t)});i&&(console.error(i),process.exit(1)),s!==0&&(console.error(`Command \`${e}\` exited with code ${s}`),process.exit(1))},Fp=e=>!(process.env.GRIDDO_ASSET_PREFIX||process.env.ASSET_PREFIX)||!e||!e.startsWith("pro-")?"":`${process.env.GRIDDO_ASSET_PREFIX||process.env.ASSET_PREFIX}/${e}`,al=(...e)=>console.log(...e),De=(...e)=>console.log(...e),Tp=(...e)=>console.log(...e),Ne=(...e)=>console.log(...e),Ip=async e=>{let t=Dp(e),r=di(t.init,t.restoreArtifacts,t.restoreCacheArtifacts);De(`
70
- \u231B\uFE0F Domain ${e} restored: ${r}s`),t.runExporter();let n=di(t.archiveArtifacts,t.archiveCacheArtifacts);De(`
71
- \u231B\uFE0F Domain ${e} archived: ${n}s`)},Np=async()=>{Qu(),ol(),Ea();let e=await sl();for(let t of e)De(`\uFE0F\u{1F6A2} Exporting domain ${Y.default.underline(t)}`),await Ip(t);Op||fl({cwd:__dirname})("node ./build/build-complete.js")},Dp=e=>{let t=Fp(e),r=fl({DOMAIN:e,GRIDDO_ASSET_PREFIX:t,NEEDS_ASSET_DOMAIN_PREFIX:t&&t!=="",GRIDDO_RENDERID:new Date().valueOf()}),n=()=>{De(`\u{1F680} Initializing ${Y.default.underline(e)} exporter`),s(),o()},i=(x="")=>{if(x==="/")throw new Error(`Artifact path cannot be root: ${x}`);let k=Ce.default.resolve(Pp,e),M=Ce.default.resolve(k,x),ye=Ce.default.resolve(M,e),Q=Ce.default.resolve(qp,e),R=Ce.default.resolve(Q,x),D=Ce.default.resolve(R,e),T=`${M}-BACKUP`,G=Ce.default.resolve(ll,x);return{domainExportArchiveBasePath:k,currentExportArchivePath:M,currentExportBackupPath:T,currentExportWorkingPath:G,currentExportArchivePathInDomain:ye,domainCacheArchiveBasePath:Q,currentExportArchiveCachePath:R,currentExportArchiveCachePathInDomain:D}},s=()=>{for(let x of[...pi,...mi,...$r]){let{currentExportWorkingPath:k}=i(x);_e.default.existsSync(k)&&(Ne(`\u{1F9F9} Cleanup dirty ${Y.default.gray(k)}`),r(`rm -rf ${k}`))}},o=()=>{let{domainExportArchiveBasePath:x,domainCacheArchiveBasePath:k}=i();for(let M of[x,k])_e.default.existsSync(M)||(De(`\u2728 Creating ${M}`),r(`mkdir -p ${M}`))},a=x=>{let{currentExportArchivePath:k,currentExportWorkingPath:M}=i(x);De(`\u{1F69A} Moving files from ${Y.default.gray(M)} to ${Y.default.gray(k)}`),r(`mv ${M} ${k}`)},c=()=>{for(let x of pi){let{currentExportWorkingPath:k,currentExportArchivePath:M}=i(x);if(!_e.default.existsSync(k)){al("\u{1F4C1} Source directory has not been created:",k);continue}try{f(x),a(x),y(x)}catch(ye){al(`\u{1F69A} Error moving files to ${M}`,ye.message),p(x);continue}}},d=()=>{for(let x of pi){let{currentExportArchivePath:k,currentExportWorkingPath:M}=i(x);_e.default.existsSync(k)&&(Ne(`\uFE0F\u267B\uFE0F Restoring ${Y.default.gray(k)}`),r(`cp -R ${k} ${M}`))}P()},f=x=>{let{currentExportArchivePath:k,currentExportBackupPath:M}=i(x);_e.default.existsSync(k)&&(De(`\u{1F4BF} Creating backup of ${Y.default.gray(k)}`),r(`mv ${k} ${M}`))},p=x=>{let{currentExportArchivePath:k,currentExportBackupPath:M}=i(x);_e.default.existsSync(M)&&(Ne(`\uFE0F\u267B\uFE0F Restoring backup ${Y.default.gray(k)}`),r(`mv ${M} ${k}`))},y=x=>{let{currentExportArchivePath:k,currentExportBackupPath:M}=i(x);Ne(`\uFE0F\u{1F5D1}\uFE0F Removing backup ${Y.default.gray(k)}`),r(`rm -rf ${M}`)},m=()=>{for(let x of $r){let{currentExportArchiveCachePath:k,currentExportWorkingPath:M}=i(x);if(_e.default.existsSync(M))De(`\u{1F69A} Moving files from ${Y.default.gray(M)} to ${Y.default.gray(k)}`),r(`mv ${M} ${k}`);else throw new Error(`\u{1F69A} Error moving files from ${M}: Path does not exist.`)}},_=()=>{for(let x of $r){let{currentExportArchiveCachePath:k,currentExportWorkingPath:M}=i(x);_e.default.existsSync(k)&&(Ne(`\uFE0F\u267B\uFE0F Restoring ${Y.default.gray(k)}`),r(`mv ${k} ${M}`))}},A=()=>{console.log(`
72
- ${Y.default.black(Y.default.bgGreen(" Gatsby (start) "))}
73
- `),r("yarn export"),Tp("Your sites have been exported correctly"),console.log(`
74
- ${Y.default.black(Y.default.bgGreen(" Gatsby (end) "))}
75
- `),U()},P=()=>{let{currentExportWorkingPath:x}=i("dist"),{currentExportWorkingPath:k}=i("public");_e.default.existsSync(x)&&(Ne(`\u{1F69A} Moving ${Y.default.gray(x)} to ${Y.default.gray(k)}`),r(`mv ${x} ${k}`))},N=()=>{let{currentExportWorkingPath:x}=i("public"),{currentExportWorkingPath:k}=i("dist");_e.default.existsSync(x)&&(Ne(`\u{1F69A} Moving ${x} to ${k}`),r(`mv ${x} ${k}`))},U=()=>{for(let x of mi){let{currentExportWorkingPath:k}=i(x);_e.default.existsSync(k)&&(Ne(`\u{1F5D1}\uFE0F Removing ${Y.default.gray(k)}`),r(`rm -rf ${k}`))}},W=()=>{s()};return{init:n,getArtifactPaths:i,archiveExportArtifact:a,archiveArtifacts:c,restoreArtifacts:d,createArtifactBackup:f,restoreArtifactBackup:p,deleteArtifactBackup:y,archiveCacheArtifacts:m,restoreCacheArtifacts:_,runExporter:A}};console.clear();Np().catch(e=>{console.error("\u26D4\uFE0F ERROR",e?.stdout?.toString()||e),process.exit(1)});
63
+ `))}var py=process.env.API_URL,my={GET_ALL:`${py}/domains`},Cn=class{static async getAll(){let{GET_ALL:e}=my;return await Fe({endpoint:e})}};async function Ds(){await Ct.login();let t=await Cn.getAll();return gy(t)}function gy(t){let e=t.filter(({slug:r})=>!!r).map(({slug:r})=>r.replace("/",""));return[...new Set(e)]}var bo=T(require("node:path"));var Er=T(require("node:fs")),Kd=T(require("node:fs/promises")),Ut=T(require("node:path")),Yd=T(Xe()),Wn=T(Ft()),Qd=T(hs());var ud=T(Xe());ud.default.config();var Os=process.env.API_URL,et=`${Os}/site/`,Ge={GET_ALL:`${Os}/sites/all`,GET_PAGE:[`${Os}/page/`,""],INFO:[`${et}`,"/all"],LANGUAGES:[`${et}`,"/languages"],BUILD_START:[`${et}`,"/build/start"],BUILD_END:[`${et}`,"/build/end"],GET_DISTRIBUTOR_DATA:[`${et}`,"/distributor"],GET_SITEMAP:[`${et}`,"/sitemap"],SOCIALS:[`${et}`,"/socials"],GET_PAGES:[`${et}`,"/pages?pagination=false"]},ye=class{static async getAll(){let{GET_ALL:e}=Ge;return await Fe({endpoint:e})}static async getPage(e,r){let{GET_PAGE:[n,i]}=Ge;return await Fe({endpoint:`${n}${e}${i}`,cacheKey:r})}static async getInfo(e,r=""){let{INFO:[n,i]}=Ge;return await Fe({endpoint:`${n}${e}${i}`,cacheKey:r})}static async getLanguages(e,r=""){let{LANGUAGES:[n,i]}=Ge;return await Fe({endpoint:`${n}${e}${i}`,cacheKey:r})}static async startSiteRender(e){let{BUILD_START:[r,n]}=Ge;return await Fe({endpoint:`${r}${e}${n}`})}static async endSiteRender(e,r){let{BUILD_END:[n,i]}=Ge;return await dt({endpoint:`${n}${e}${i}`,body:r})}static async getDistributorData(e,r,n,i,s){let{GET_DISTRIBUTOR_DATA:[o,a]}=Ge,u=i||e.site,h=s||e.language;return await dt({endpoint:`${o}${u}${a}`,body:r,headers:{lang:h},cacheKey:n})}static async getSitemap(e){let{GET_SITEMAP:[r,n]}=Ge;return await Fe({endpoint:`${r}${e}${n}`})}static async getSocials(e,r=""){let{SOCIALS:[n,i]}=Ge;return await Fe({endpoint:`${n}${e}${i}`,cacheKey:r})}};var Pn=class{static getBody(e,r){let{order:n,sources:i,quantity:s,mode:o,fixed:a,fullRelations:u=!1,allLanguages:h=!1,preferenceLanguage:c=!1,referenceId:p}=e;return o==="auto"?{mode:o,order:n,sources:i,quantity:s,fullRelations:u,allLanguages:h,preferenceLanguage:c}:o==="manual"?{mode:o,fixed:a,fullRelations:u}:o==="navigation"?{mode:o,order:n,quantity:s,fullRelations:u,referenceId:p||r?.structuredDataContent?.id}:(console.log(`Error: Distribuidor mode: ${o} is not recognized on page ${r?.id}.`),e)}static async fetchContentTypeData(e){let{page:r,component:{data:n},cacheKey:i}=e;if(!n)return _s(`Error: Page ${r.id} has \`hasDistributorData: true\` but it doesn't have a \`data\` prop`),[];if(Array.isArray(n.sources)&&n.sources.length<1)return _s(`Warning: Page with id: ${r.id} has a ReferenceField with empty \`data.sources\``),[];let{site:s,lang:o}=n,a=this.getBody(n,r);return await ye.getDistributorData(r,a,i,s,o)}static async getDistributorData({page:e,cacheKey:r=""}){try{let{template:n}=e,i=async(a,u=1)=>{if(!(!a||typeof a!="object")&&JSON.stringify(a).includes('"hasDistributorData":true'))for(let h in a){if(h==="queriedItems")continue;let p=a[h];!p||typeof p!="object"||(p.hasDistributorData&&(p.queriedItems=await this.fetchContentTypeData({page:e,cacheKey:r,component:p})),await i(p,u+1))}};return await(async a=>(await i([a]),a))(n)}catch(n){console.error(`Error en get distributor ${n}`),process.exit(1)}}};var Dn=class{_defaultHeaders;_defaultFooters;_navigations;constructor(){this._navigations={footers:[],headers:[]},this._defaultHeaders={},this._defaultFooters={}}set navigations(e){this._navigations=e,this._defaultFooters=this.getDefaultFooters(),this._defaultHeaders=this.getDefaultHeaders()}get navigations(){return this._navigations}getDefaultFooters(){return[...this.navigations.footers].filter(i=>!!i.setAsDefault).reduce((i,s)=>{let{language:o}=s;return{...i,[o]:s}},{})}getDefaultHeaders(){return[...this.navigations.headers].filter(i=>!!i.setAsDefault).reduce((i,s)=>{let{language:o}=s;return{...i,[o]:s}},{})}getRightLanguage(e,r,n){if(!e||!r)return null;let s=e.find(o=>o.language===n&&o.navigationLanguages?.find(a=>a.navigationId===r))||e.find(o=>o.id===r);return s?{...s}:null}getPageHeader(e,r){return this.getRightLanguage(this.navigations.headers,e,r)}getPageFooter(e,r){return this.getRightLanguage(this.navigations.footers,e,r)}getPageNavigations(e){let{header:r,footer:n,language:i,template:{templateType:s},templateConfig:{defaultHeader:o,defaultFooter:a,templates:u}}=e,h=_=>{let C=_.find(I=>typeof I=="number");return typeof C=="number"?C:null},c=h([r,u?.[s]?.defaultHeader,o]),p=h([n,u?.[s]?.defaultFooter,a]),g=c?this.getPageHeader(c,i):c===0?null:this._defaultHeaders[i],m=p?this.getPageFooter(p,i):p===0?null:this._defaultFooters[i];return{header:g,footer:m}}};var As=class{baseURL;settings;ENDPOINTS;constructor(){this.baseURL=process.env.API_URL,this.settings={cloudinaryName:"",useMetaTitle:!1,useMetaKeywords:!1,showBasicMetaRobots:!1,avoidHrefLangsOnCanonicals:!1,avoidSelfReferenceCanonicals:!1,avoidHrefLangXDefault:!1,avoidDebugMetas:!1},this.ENDPOINTS={settings:`${this.baseURL}/settings`,resetRender:`${this.baseURL}/debug/reset-render`}}async getAll(){let{settings:e}=this.ENDPOINTS,r=await Fe({endpoint:e});this.settings=r}async resetRender(){let{resetRender:e}=this.ENDPOINTS;await dt({endpoint:e})}},Is=new As;var Rs=T(require("node:path")),hr=T(Ft());async function On(t){for await(let e of t)for(let r of e.domains){let n=Object.values(r)[0],i=Rs.default.resolve(__dirname,`../../dist${n}`),s=Rs.default.resolve(__dirname,`../../assets/page-data${n}`);if(je(`Site dir ${i}`),je(`Page data dir ${s}`),!hr.default.existsSync(i))return;try{await hr.default.rm(i,{recursive:!0}),je(`${i} is deleted!`)}catch(o){console.log(o)}if(!hr.default.existsSync(s))return;try{await hr.default.rm(s,{recursive:!0}),console.info(`${s} is deleted!`)}catch(o){console.log(o)}}}var Ms=T(require("node:fs")),dd=T(require("node:path")),hd=T(Xe());var yy=process.env.API_URL;async function cd(t){let{title:e,description:r,image:n,pageId:i,languageId:s,siteId:o,url:a,content:u,template:h}=t;return await dt({endpoint:`${yy}/search`,body:{title:e,description:r,image:n,pageId:i,languageId:s,siteId:o,url:a,template:h,content:vy(u)}})}function vy(t){let e=by(["meta","link","style","script","noscript","nav","header","footer"],t),r=_y(e);return wy(r)}function by(t,e){let r=e;return t.forEach(n=>{r=r.replace(new RegExp(`<${n}.*?>.*?</${n}>`,"gis")," ").replace(new RegExp(`(<${n}([^>]+)>)`,"gis")," ")}),r}function _y(t){return t.replace(/(<([^>]+)>)/gis," ")}function wy(t){return t.replace(/\s+/g," ")}function Fs(t,e,r,n="jpg"){let i=typeof t=="string"?t:t?.url;return i?i.split("/")[2].includes("cloudinary.com")?Sy(i,`c_fill,w_${e},h_${r}`):xy(i,`f/${n}/w/${e}/h/${r}`):null}function xy(t,e){let r=t.split("/"),n=r.slice(0,-1).join("/"),i=r.slice(-1)[0];return`${n}/${e}/${i}`}function Sy(t,e){let r=t.replace("https://",""),n=r.split("/").slice(0,4).join("/"),i=r.replace(n,"");return`https://${n}/${e}${i}`}hd.default.config();var Ey=!!JSON.parse(process.env.GRIDDO_SEARCH_FEATURE||"false"),Cy=JSON.parse(process.env.GRIDDO_EXPORT_STRIP_DOMAIN_FROM_PATH||"false"),Py=25;function Dy({socialTitle:t,socialDescription:e,socialImage:r}){return{type:"website",title:t,description:e,image:r?Fs(r,1280,768):"",twitterImage:r?Fs(r,1280,768):""}}function Oy(t){let{title:e,metaTitle:r,metaDescription:n,canonicalURL:i,locale:s,url:o,isIndexed:a,follow:u,metasAdvanced:h,pageLanguages:c,fullUrl:p,metaKeywords:g}=t,m=h?.split(",").filter(Boolean).map(_=>_.trim().toLowerCase())||[];return{title:(r||e||"").trim(),description:n,canonical:i&&i.trim()&&i!==p?i.trim():a?p:void 0,locale:s,url:o,index:a?"index":"noindex",follow:u?"follow":"nofollow",translate:m.includes("notranslate")?"notranslate":"",metasAdvanced:m.filter(_=>_!=="notranslate").join(),pageLanguages:c,metaKeywords:g?.filter(Boolean).map(_=>_.replace(/"/g,"'")).join(", ")}}async function qs(t,e,r=!1){let{id:n,title:i,fullPath:s,language:o,breadcrumb:a,socialDescription:u,socialImage:h,socialTitle:c}=t,{baseUrl:p,BUILD_MODE:g,cloudinaryName:m,griddoVersion:_,siteLangs:C,siteMetadata:I,siteOptions:k,siteScript:L,siteSlug:U,socials:X,theme:z,navigations:{header:re,footer:ve}}=e;t.breadcrumb=a,t.siteSlug=U,t.apiUrl=p,t.publicApiUrl=e.publicBaseUrl,t.instance=e.instance;let b=C.find(({id:D})=>D===t?.language)?.locale.replace(/_/g,"-"),w=Oy(t),E=Dy({socialDescription:u,socialImage:h,socialTitle:c}),$=Cy?s.compose:`${s.domain}${s.compose}`,R=new Date().toString(),j={path:$,size:void 0,context:{id:n,title:i,fullPath:s,locale:b,languageId:o,theme:z,siteMetadata:I,pageMetadata:w,openGraph:E,socials:X,siteLangs:C,cloudinaryName:m,siteOptions:k,BUILD_MODE:g,griddoVersion:_,renderDate:R,siteScript:L,header:re,footer:ve,page:t}};if(Ey&&!r){let D=dd.default.resolve(__dirname,"../../dist/",`./${$}index.html`),N=Ms.default.existsSync(D)?Ms.default.readFileSync(D).toString():"";await cd({title:i,description:E.description||"",image:E.image||"",pageId:n,languageId:o,template:t?.template?.templateType||t?.templateId||null,siteId:t.site,url:t.fullUrl,content:N})}return j}async function pd(t,e){return await qs(t,e)}async function md({page:t,pages:e,isRoot:r=!1,defaultLang:n,template:i,totalQueriedItems:s},o){let a=e.map(async(u,h)=>{let c=h===0,p=h+1,{domainUrl:g,compose:m}=t.fullPath,_={...t,fullPath:{...t.fullPath,compose:ks(m,p,{addEndingSlash:!0})},fullUrl:ks(t.fullUrl,p,{addEndingSlash:!0}),slug:ks(t.slug,p),title:fd(t.title,p),metaTitle:fd(t.metaTitle||"",p),disableHrefLangs:p>1,template:{...i,isFirstPage:c,pageNumber:p,totalPages:e.length,baseLink:`${g}${m}`,queriedItems:u,totalQueriedItems:s?.length},isRoot:r,defaultLang:n};return await qs(_,o,!c)});return Promise.all(a)}function gd(t,e){let{multiPageElements:r,...n}=t,i=JSON.parse(JSON.stringify(r));i.find(({sectionSlug:o})=>o==="/")||i.push({});let s=i.map(async o=>{let a=JSON.parse(JSON.stringify(n)),{sectionSlug:u="/",title:h="",metaTitle:c="",metaDescription:p=""}=o,g=typeof h=="string"?h:h.content,m=a.fullPath.compose||"",_=a.fullUrl.endsWith("/")?a.fullUrl.slice(0,-1):a.fullUrl,C=u?.replace(/\//g,""),k=u==="/"?C:C+"/",L=m.endsWith("/")?"":"/",U=`${m}${L}${k}`;return g.trim()&&(a.title=g),p.trim()&&(a.metaDescription=p),a.fullUrl=`${_}/${k}`,a.fullPath.compose=U,a.slug=U,a.template.activeSectionSlug=u,a.template.activeSectionBase=_,a.metaTitle=c.trim()||g.trim()||a.metaTitle,await qs(a,e)});return Promise.all(s)}function yd(t){return new Promise(r=>{let n=(i,s=0)=>{if(!(!i||typeof i!="object")){for(let o in i){let a=i[o],u=a||typeof a=="object",h=JSON.stringify(a).includes('"hasGriddoMultiPage":true');if(!u||!h)continue;let{component:c,hasGriddoMultiPage:p,elements:g}=a;c&&p&&r(g||[]),n(a,s+1)}s||r(null)}};n([t])})}function Ay(t,e,r){return e?.slice(t*(r-1),t*r)}function Iy(t,e){let r=Math.ceil(e.length/t)||1;return Array.from({length:r},(i,s)=>s+1)?.map(i=>Ay(t,e,i))}function vd(t){let e=t.queriedItems||[],r=t?.itemsPerPage||Py;return Iy(r,e)}function ld(t){return t.replace(/\/+$/,"/")}function ks(t,e,r){let n=t.endsWith("/")?"":"/",i=r?.addEndingSlash?"/":"";return e<=1?ld(`${t}${i}`):ld(`${t}${n}${e}${i}`)}function fd(t,e){return!t||e<=1?t:`${t} - ${e}`}var x1=T(Ft()),S1=T(Xd());var E1=process.env.API_URL,C1=!!process.env.GRIDDO_RENDER_ALL_SITES||!!process.env.updateAllSites,Bt=process.env.GRIDDO_RENDER_SITE&&parseInt(process.env.GRIDDO_RENDER_SITE)||process.env.testSite&&parseInt(process.env.testSite),Hd=(process.env.GRIDDO_RENDER_PAGES||process.env.testPage||"").split(",").map(t=>parseInt(t)).filter(Boolean),B_=JSON.parse(process.env.GRIDDO_EXPORT_STRIP_DOMAIN_FROM_PATH||"false");async function Gd(){console.info(`API URL ${E1}`),await Ct.login();let t=await ye.getAll(),e=C1?t.filter(i=>!Bt||i.id===Bt):t.filter(i=>Bt?i.id===Bt:!!i.shouldBeUpdated);if(e.length){let i=e.map(async s=>{let o=await ye.getLanguages(s.id);return s.domains=o.items.filter(a=>a.domain&&(!process.env.DOMAIN||a.domain.slug.indexOf(process.env.DOMAIN)>0)).map(a=>({[a.id]:`${a.domain.slug}${a.path}`}))});await Promise.all(i)}let r=e.filter(i=>Bt?i.id===Bt:!!i.isPublished&&i.domains.length>0),n=e.filter(i=>!i.isPublished&&i.shouldBeUpdated);return{sitesToPublish:r,sitesToUnpublish:n}}async function Wd(t){for(let e of t){let r=await ye.startSiteRender(e.id),{siteHash:n}=r,i={siteHash:n,publishHashes:[],unpublishHashes:[]};je(`Unpublish site(s): ${r.publishIds}`),await ye.endSiteRender(e.id,i)}await On(t)}async function zd(t){let e=await ye.startSiteRender(t),r=await ye.getInfo(t),n=await ye.getLanguages(t),i=await ye.getSocials(t),s=n.items,o=s.find(_=>_.isDefault),{siteHash:a,unpublishHashes:u,publishIds:h}=e,{headers:c,footers:p}=r,g=Hd.length?Hd.filter(_=>h.includes(_)):h;return{siteInfo:r,validPagesIds:g,siteHash:a,unpublishHashes:u,siteLangs:s,defaultLang:o,headers:c,footers:p,socials:i}}Yd.default.config();var P1=process.env.API_URL,D1=process.env.CXBRANCH,O1=process.env.GRIDDO_REACT_APP_INSTANCE||process.env.REACT_APP_INSTANCE,Jd=parseInt(process.env.GRIDDO_API_CONCURRENCY_COUNT||"")||10,A1=process.env.PUBLIC_API_URL,I1=process.env.GRIDDO_RENDERID||new Date().valueOf().toString(),Vd=[],vo={};async function Zd(t){console.info(`API calls with ${Jd} threads`),Er.default.existsSync(t)&&Er.default.rmSync(t,{recursive:!0}),Er.default.mkdirSync(t),Er.default.mkdirSync(Ut.default.resolve(t,"metadata"));try{let{sitesToPublish:e,sitesToUnpublish:r}=await Gd();await Is.getAll(),e.length||r.length||(console.warn("There are no sites to update"),process.exit(0)),console.info(`Sites to publish: ${Es(e)}`),console.info(`Sites to unpublish: ${Es(r)}`),await Wd(r),await On([...e]);for(let n of e){let{id:i,slug:s,theme:o,favicon:a}=n,{siteInfo:u,validPagesIds:h,siteHash:c,unpublishHashes:p,siteLangs:g,defaultLang:m,headers:_,footers:C,socials:I}=await zd(i),{cloudinaryName:k,useMetaTitle:L,useMetaKeywords:U,showBasicMetaRobots:X,avoidHrefLangsOnCanonicals:z,avoidSelfReferenceCanonicals:re,avoidHrefLangXDefault:ve,avoidDebugMetas:Q}=Is.settings;vo[i]={siteHash:c,unpublishHashes:p,publishHashes:[]};let b=new Dn;b.navigations={headers:_,footers:C},n.languages=g;let w=Gl(i,c),E=u.siteScript,$={siteUrl:u.slug,title:u.name,favicon:a},R={baseUrl:P1,publicBaseUrl:A1,instance:O1,siteSlug:s,theme:o,siteMetadata:$,socials:I,siteLangs:g,cloudinaryName:k,griddoVersion:En,siteOptions:{useMetaTitle:L,useMetaKeywords:U,showBasicMetaRobots:X,avoidHrefLangsOnCanonicals:z,avoidSelfReferenceCanonicals:re,avoidHrefLangXDefault:ve,avoidDebugMetas:Q},BUILD_MODE:D1,siteScript:E};je(`${n.name} site`);let j=async M=>{let P=[],F=await ye.getPage(M,w);if(!F)return;Vd.push(M);let De=JSON.parse(JSON.stringify(R));De.navigations=b.getPageNavigations(F);let be=await Pn.getDistributorData({page:F,cacheKey:I1}),ne=await yd(be),ue=F?.mode==="list",nt=!ue&&ne,_e=!nt&&!ue;if(ue){let l={page:F,pages:vd(be),isRoot:!1,defaultLang:m,template:be,totalQueriedItems:be.queriedItems};P=await md(l,De)}if(nt){let l=F;l.template=be,l.multiPageElements=ne,l.defaultLang=m,P=await gd(l,De)}if(_e){let l=F;l.template=be,l.defaultLang=m,P=[await pd(l,De)]}vo[i].publishHashes.push(F.hash),await M1(t,P),k1(t,e),R1(t,vo),F1(t,Vd)},D=(0,Qd.default)(Jd),N=h.map(M=>D(()=>j(M)));await Promise.all(N)}}catch(e){console.error(e.message),process.exit(1)}}function R1(t,e){Wn.default.writeJSONSync(Ut.default.resolve(t,"metadata","buildProcessData.json"),e)}function F1(t,e){Wn.default.writeJSONSync(Ut.default.resolve(t,"metadata","createdPages.json"),e)}function k1(t,e){Wn.default.writeJSONSync(Ut.default.resolve(t,"metadata","sitesToPublish.json"),e)}async function M1(t,e){e.forEach(n=>Ss(n,["editorID","parentEditorID"]));let r=e.map(async n=>{let i=`${Ul(n.path)}.json`,s=JSON.stringify(n),o=Ut.default.resolve(t,i);await Kd.default.writeFile(o,s)});await Promise.all(r)}var q1=bo.default.resolve(__dirname,"../store/"),T1=bo.default.resolve(__dirname,"../apiCache");async function _o(){$l(),await Zd(q1),nd(T1)}var eh=require("node:child_process"),th=T(Xe()),rh=T(vs());th.default.config();var N1=rh.default.sync(__dirname);function wo(t){return e=>j1(e,t)}function j1(t,e){let[r,...n]=t.split(" "),{error:i,status:s}=(0,eh.spawnSync)(r,n,{cwd:N1,stdio:["ignore","inherit","ignore"],encoding:"utf8",shell:!0,env:Object.assign({GRIDDO_EXPORTER:"true"},process.env,e)});i&&(console.error(i),process.exit(1)),s!==0&&(console.error(`Command \`${t}\` exited with code ${s}`),process.exit(1))}var nh=T(Xe());nh.default.config();var $e=T(require("node:fs")),Ue=T(require("node:path"));var Pe=T(Yt()),ih=T(Xe());ih.default.config();function sh(t){let e=["dist","assets"],r=["public","store"],n=["apiCache"];JSON.parse(process.env.GRIDDO_EXPORT_STRIP_DOMAIN_FROM_PATH||"false")?n.push(".cache"):r.push(".cache");let s=Ue.default.resolve(td,"exports/sites"),o=Ue.default.resolve(__dirname,"../caches"),a=L1(t),u=wo({DOMAIN:t,GRIDDO_ASSET_PREFIX:a,NEEDS_ASSET_DOMAIN_PREFIX:a&&a!=="",GRIDDO_RENDERID:new Date().valueOf()}),h=()=>{console.info(`Initializing exporter for the domain ${t}`),g(),m()},c=()=>{for(let b of e){let{currentExportArchivePath:w,currentExportWorkingPath:E}=p(b);$e.default.existsSync(w)&&(console.log(`\uFE0FRestoring ${Pe.default.gray(w)}`),u(`cp -R ${w} ${E}`))}re()},p=(b="")=>{if(b==="/")throw new Error(`Artifact path cannot be root: ${b}`);let w=Ue.default.resolve(s,t),E=Ue.default.resolve(w,b),$=Ue.default.resolve(E,t),R=Ue.default.resolve(o,t),j=Ue.default.resolve(R,b),D=Ue.default.resolve(j,t),N=`${E}-BACKUP`,M=Ue.default.resolve(ed,b);return{domainExportArchiveBasePath:w,currentExportArchivePath:E,currentExportBackupPath:N,currentExportWorkingPath:M,currentExportArchivePathInDomain:$,domainCacheArchiveBasePath:R,currentExportArchiveCachePath:j,currentExportArchiveCachePathInDomain:D}},g=()=>{for(let b of[...e,...r,...n]){let{currentExportWorkingPath:w}=p(b);$e.default.existsSync(w)&&(console.log(`Cleanup dirty ${Pe.default.gray(w)}`),u(`rm -rf ${w}`))}},m=()=>{let{domainExportArchiveBasePath:b,domainCacheArchiveBasePath:w}=p();for(let E of[b,w])$e.default.existsSync(E)||(console.info(`Creating ${E}`),u(`mkdir -p ${E}`))},_=b=>{let{currentExportArchivePath:w,currentExportWorkingPath:E}=p(b);console.info(`Moving files from ${Pe.default.gray(E)} to ${Pe.default.gray(w)}`),u(`mv ${E} ${w}`)},C=()=>{for(let b of e){let{currentExportWorkingPath:w,currentExportArchivePath:E}=p(b);if(!$e.default.existsSync(w)){console.log("Source directory has not been created:",w);continue}try{I(b),_(b),L(b)}catch($){console.log(`Error moving files to ${E}`,$.message),k(b);continue}}},I=b=>{let{currentExportArchivePath:w,currentExportBackupPath:E}=p(b);$e.default.existsSync(w)&&(console.info(`Creating backup of ${Pe.default.gray(w)}`),u(`mv ${w} ${E}`))},k=b=>{let{currentExportArchivePath:w,currentExportBackupPath:E}=p(b);$e.default.existsSync(E)&&(console.log(`\uFE0FRestoring backup ${Pe.default.gray(w)}`),u(`mv ${E} ${w}`))},L=b=>{let{currentExportArchivePath:w,currentExportBackupPath:E}=p(b);console.log(`\uFE0FRemoving backup ${Pe.default.gray(w)}`),u(`rm -rf ${E}`)},U=()=>{for(let b of n){let{currentExportArchiveCachePath:w,currentExportWorkingPath:E}=p(b);if($e.default.existsSync(E))console.info(`Moving files from ${Pe.default.gray(E)} to ${Pe.default.gray(w)}`),u(`mv ${E} ${w}`);else throw new Error(`Error moving files from ${E}: Path does not exist.`)}},X=()=>{for(let b of n){let{currentExportArchiveCachePath:w,currentExportWorkingPath:E}=p(b);$e.default.existsSync(w)&&(console.log(`\uFE0FRestoring ${Pe.default.gray(w)}`),u(`mv ${w} ${E}`))}},z=()=>{u("yarn gatsby-build")},re=()=>{let{currentExportWorkingPath:b}=p("dist"),{currentExportWorkingPath:w}=p("public");$e.default.existsSync(b)&&(console.log(`Moving ${Pe.default.gray(b)} to ${Pe.default.gray(w)}`),u(`mv ${b} ${w}`))},ve=()=>{for(let b of r){let{currentExportWorkingPath:w}=p(b);$e.default.existsSync(w)&&(console.log(`\uFE0FRemoving ${Pe.default.gray(w)}`),u(`rm -rf ${w}`))}},Q=()=>{g()};return{init:h,getArtifactPaths:p,archiveExportArtifact:_,archiveArtifacts:C,restoreArtifacts:c,createArtifactBackup:I,restoreArtifactBackup:k,deleteArtifactBackup:L,archiveCacheArtifacts:U,restoreCacheArtifacts:X,runGatsbyBuild:z,removeDisposableArtifacts:ve}}function L1(t){let e=process.env.GRIDDO_ASSET_PREFIX||process.env.ASSET_PREFIX;return!e||!t||!t.startsWith("pro-")?"":`${e}/${t}`}async function xo(){Cs("gatsby");let t=0,e=await Ds();for(let r of e){let n=sh(r);t=await dr(n.init,n.restoreArtifacts,n.restoreCacheArtifacts).catch(i=>{console.error("Error in init() || restoreArtifacts() || restoreCacheArtifacts() :",i?.stdout?.toString()||i),process.exit(1)}),console.info(`success restore ${r} - ${t}s`),t=await dr(_o).catch(i=>{console.error("Error in downloadBuildData() :",i?.stdout?.toString()||i),process.exit(1)}),console.info(`success download ${r} - ${t}s`),t=await dr(n.runGatsbyBuild).catch(i=>{console.error("Error in runGatsbyBuild() :",i?.stdout?.toString()||i),process.exit(1)}),console.info(`success gatsby build command - ${t}s`),t=await dr(n.removeDisposableArtifacts,n.archiveArtifacts,n.archiveCacheArtifacts).catch(i=>{console.error("Error in removeDisposableArtifacts() || archiveArtifacts()|| archiveCacheArtifacts() :",i?.stdout?.toString()||i),process.exit(1)}),console.info(`success archive ${r} - ${t}s`)}}async function $1(){await xo()}$1().catch(t=>{console.error("Error in main():",t?.stdout?.toString()||t),process.exit(1)});