monocart-coverage-reports 2.10.1 → 2.10.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -4
- package/README.zh-Hans.md +6 -4
- package/lib/converter/ast-visitor.js +39 -1
- package/lib/converter/ast.js +3 -1
- package/lib/packages/monocart-coverage-vendor.js +10 -10
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -42,6 +42,7 @@
|
|
|
42
42
|
- [Playwright](#playwright)
|
|
43
43
|
- [c8](#c8)
|
|
44
44
|
- [CodeceptJS](#codeceptjs)
|
|
45
|
+
- [VSCode](#vscode)
|
|
45
46
|
- [Jest](#jest)
|
|
46
47
|
- [Vitest](#vitest)
|
|
47
48
|
- [Puppeteer](#puppeteer)
|
|
@@ -117,7 +118,7 @@ For more information, see [Command Line](#command-line)
|
|
|
117
118
|
|
|
118
119
|
- `v8-json`
|
|
119
120
|
- Save `CoverageResults` to a json file (defaults to [`coverage-report.json`](https://cenfun.github.io/monocart-coverage-reports/v8-and-istanbul/coverage-report.json)).
|
|
120
|
-
- Shows native V8 code coverage with VSCode extension [
|
|
121
|
+
- Shows native V8 code coverage with VSCode extension: [Monocart Coverage for VSCode](https://github.com/cenfun/monocart-coverage-vscode)
|
|
121
122
|
|
|
122
123
|

|
|
123
124
|
|
|
@@ -975,6 +976,9 @@ c8 --experimental-monocart --reporter=v8 --reporter=console-details node foo.js
|
|
|
975
976
|
### [CodeceptJS](https://github.com/codeceptjs/CodeceptJS)
|
|
976
977
|
- CodeceptJS is a [BDD](https://codecept.io/bdd/) + [AI](https://codecept.io/ai/) testing framework for e2e testing, it has integrated `MCR` since [v3.5.15](https://github.com/codeceptjs/CodeceptJS/releases/tag/3.5.15), see [plugins/coverage](https://codecept.io/plugins/#coverage)
|
|
977
978
|
|
|
979
|
+
### [VSCode](https://github.com/microsoft/vscode)
|
|
980
|
+
- [Monocart Coverage for VSCode](https://github.com/cenfun/monocart-coverage-vscode) - Shows native V8 code coverage in VSCode
|
|
981
|
+
|
|
978
982
|
### [Jest](https://github.com/jestjs/jest/)
|
|
979
983
|
- [jest-monocart-coverage](https://github.com/cenfun/jest-monocart-coverage) - Jest custom reporter for coverage reports
|
|
980
984
|
- [merge-code-coverage](https://github.com/cenfun/merge-code-coverage) - Example for merging code coverage (Jest unit + Playwright e2e sharding)
|
|
@@ -1121,9 +1125,6 @@ git commit -m "Saving files before refreshing line endings"
|
|
|
1121
1125
|
npm run eol
|
|
1122
1126
|
```
|
|
1123
1127
|
|
|
1124
|
-
### VSCode Extension
|
|
1125
|
-
- [Coverage Gutters](https://github.com/ryanluker/vscode-coverage-gutters) - Display test coverage generated by lcov or xml in VSCode editor.
|
|
1126
|
-
|
|
1127
1128
|
## Thanks
|
|
1128
1129
|
- [@bcoe](https://github.com/bcoe)
|
|
1129
1130
|
- [@edumserrano](https://github.com/edumserrano)
|
package/README.zh-Hans.md
CHANGED
|
@@ -42,6 +42,7 @@
|
|
|
42
42
|
- [Playwright](#playwright)
|
|
43
43
|
- [c8](#c8)
|
|
44
44
|
- [CodeceptJS](#codeceptjs)
|
|
45
|
+
- [VSCode](#vscode)
|
|
45
46
|
- [Jest](#jest)
|
|
46
47
|
- [Vitest](#vitest)
|
|
47
48
|
- [Puppeteer](#puppeteer)
|
|
@@ -117,7 +118,8 @@ mcr node my-app.js -r v8,console-details
|
|
|
117
118
|
|
|
118
119
|
- `v8-json`
|
|
119
120
|
- 保存 `CoverageResults` 到一个json文件
|
|
120
|
-
-
|
|
121
|
+
- 保存 `CoverageResults` 到一个json文件 (默认是 [`coverage-report.json`](https://cenfun.github.io/monocart-coverage-reports/v8-and-istanbul/coverage-report.json))
|
|
122
|
+
- 用于VSCode扩展来显示原生V8代码覆盖率: [Monocart Coverage for VSCode](https://github.com/cenfun/monocart-coverage-vscode)
|
|
121
123
|
|
|
122
124
|
> 内置Istanbul报告 (V8和Istanbul格式数据都支持):
|
|
123
125
|
|
|
@@ -977,6 +979,9 @@ c8 --experimental-monocart --reporter=v8 --reporter=console-details node foo.js
|
|
|
977
979
|
### [CodeceptJS](https://github.com/codeceptjs/CodeceptJS)
|
|
978
980
|
- CodeceptJS is a [BDD](https://codecept.io/bdd/) + [AI](https://codecept.io/ai/) testing framework for e2e testing, it has integrated `MCR` since [v3.5.15](https://github.com/codeceptjs/CodeceptJS/releases/tag/3.5.15), see [plugins/coverage](https://codecept.io/plugins/#coverage)
|
|
979
981
|
|
|
982
|
+
### [VSCode](https://github.com/microsoft/vscode)
|
|
983
|
+
- [Monocart Coverage for VSCode](https://github.com/cenfun/monocart-coverage-vscode) - Shows native V8 code coverage in VSCode
|
|
984
|
+
|
|
980
985
|
### [Jest](https://github.com/jestjs/jest/)
|
|
981
986
|
- [jest-monocart-coverage](https://github.com/cenfun/jest-monocart-coverage) - Jest custom reporter for coverage reports
|
|
982
987
|
- [merge-code-coverage](https://github.com/cenfun/merge-code-coverage) - Example for merging code coverage (Jest unit + Playwright e2e sharding)
|
|
@@ -1123,9 +1128,6 @@ git commit -m "Saving files before refreshing line endings"
|
|
|
1123
1128
|
npm run eol
|
|
1124
1129
|
```
|
|
1125
1130
|
|
|
1126
|
-
### VSCode Extension
|
|
1127
|
-
- [Coverage Gutters](https://github.com/ryanluker/vscode-coverage-gutters) - Display test coverage generated by lcov or xml in VSCode editor.
|
|
1128
|
-
|
|
1129
1131
|
## Thanks
|
|
1130
1132
|
- [@bcoe](https://github.com/bcoe)
|
|
1131
1133
|
- [@edumserrano](https://github.com/edumserrano)
|
|
@@ -632,6 +632,7 @@ const getRootFunctionState = (ast, coverageInfo) => {
|
|
|
632
632
|
return rootState;
|
|
633
633
|
};
|
|
634
634
|
|
|
635
|
+
// eslint-disable-next-line complexity
|
|
635
636
|
const findFunctionRange = (item, coverageInfo) => {
|
|
636
637
|
|
|
637
638
|
const { node, reverseParents } = item;
|
|
@@ -645,13 +646,49 @@ const findFunctionRange = (item, coverageInfo) => {
|
|
|
645
646
|
return functionRange;
|
|
646
647
|
}
|
|
647
648
|
|
|
649
|
+
// `static async` case:
|
|
650
|
+
// [1]static [2]async [3]covered(active) {
|
|
651
|
+
// v8 start: 2
|
|
652
|
+
// ast start: 1,3
|
|
653
|
+
|
|
654
|
+
// fixed by async or static
|
|
655
|
+
|
|
656
|
+
// handle for static async
|
|
657
|
+
if (node.async) {
|
|
658
|
+
// 'async '.length
|
|
659
|
+
const asyncLen = 6;
|
|
660
|
+
const asyncStart = start - asyncLen;
|
|
661
|
+
// console.log(asyncStart, 'asyncStart ===============================================');
|
|
662
|
+
const asyncRange = getFunctionRange(asyncStart, end, type, coverageInfo);
|
|
663
|
+
if (asyncRange) {
|
|
664
|
+
return asyncRange;
|
|
665
|
+
}
|
|
666
|
+
}
|
|
667
|
+
|
|
648
668
|
// try if class MethodDefinition
|
|
649
669
|
// 0 is function self
|
|
650
670
|
const parent = reverseParents[1];
|
|
651
671
|
if (parent && parent.type === 'MethodDefinition') {
|
|
652
|
-
|
|
672
|
+
|
|
673
|
+
const parentRange = getFunctionRange(parent.start, parent.end, parent.type, coverageInfo);
|
|
674
|
+
if (parentRange) {
|
|
675
|
+
return parentRange;
|
|
676
|
+
}
|
|
677
|
+
|
|
678
|
+
if (parent.static) {
|
|
679
|
+
// 'static '.length
|
|
680
|
+
const staticLen = 7;
|
|
681
|
+
const staticStart = parent.start + staticLen;
|
|
682
|
+
// console.log(staticStart, ' staticStart ============================================');
|
|
683
|
+
const staticRange = getFunctionRange(staticStart, parent.end, parent.type, coverageInfo);
|
|
684
|
+
if (staticRange) {
|
|
685
|
+
return staticRange;
|
|
686
|
+
}
|
|
687
|
+
}
|
|
688
|
+
|
|
653
689
|
}
|
|
654
690
|
|
|
691
|
+
|
|
655
692
|
};
|
|
656
693
|
|
|
657
694
|
const collectAstInfo = (ast, coverageInfo) => {
|
|
@@ -669,6 +706,7 @@ const collectAstInfo = (ast, coverageInfo) => {
|
|
|
669
706
|
const {
|
|
670
707
|
start, end, id
|
|
671
708
|
} = node;
|
|
709
|
+
|
|
672
710
|
const bodyStart = node.body.start;
|
|
673
711
|
const bodyEnd = node.body.end;
|
|
674
712
|
const functionName = id && id.name;
|
package/lib/converter/ast.js
CHANGED
|
@@ -58,7 +58,9 @@ const getCoverageInfo = (coverageList) => {
|
|
|
58
58
|
|
|
59
59
|
functionMap.set(functionRange.startOffset, functionRange);
|
|
60
60
|
if (functionName) {
|
|
61
|
-
|
|
61
|
+
// can not handle `async functionName`
|
|
62
|
+
const possibleNameOffset = functionRange.startOffset + functionName.length;
|
|
63
|
+
functionNameMap.set(possibleNameOffset, functionRange);
|
|
62
64
|
}
|
|
63
65
|
|
|
64
66
|
if (functionName === '<static_initializer>') {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
var Co=Object.create;var ft=Object.defineProperty;var Oo=Object.getOwnPropertyDescriptor;var Lo=Object.getOwnPropertyNames;var To=Object.getPrototypeOf,Ao=Object.prototype.hasOwnProperty;var S=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports),No=(n,e)=>{for(var t in e)ft(n,t,{get:e[t],enumerable:!0})},tn=(n,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of Lo(e))!Ao.call(n,s)&&s!==t&&ft(n,s,{get:()=>e[s],enumerable:!(r=Oo(e,s))||r.enumerable});return n};var U=(n,e,t)=>(t=n!=null?Co(To(n)):{},tn(e||!n||!n.__esModule?ft(t,"default",{value:n,enumerable:!0}):t,n)),
|
|
2
|
-
`+i.stack)}}function D(n,e){e=e||{},e.hasComment&&(n=Io(n)),e.encoding==="base64"?n=ct(n):e.encoding==="uri"&&(n=decodeURIComponent(n)),(e.isJSON||e.encoding)&&(n=JSON.parse(n)),this.sourcemap=n}D.prototype.toJSON=function(n){return JSON.stringify(this.sourcemap,null,n)};typeof Buffer<"u"?typeof Buffer.from=="function"?D.prototype.toBase64=Fo:D.prototype.toBase64=Uo:D.prototype.toBase64=Do;function Fo(){var n=this.toJSON();return Buffer.from(n,"utf8").toString("base64")}function Uo(){var n=this.toJSON();if(typeof n=="number")throw new TypeError("The json to encode must not be of type number.");return new Buffer(n,"utf8").toString("base64")}function Do(){var n=this.toJSON();return btoa(unescape(encodeURIComponent(n)))}D.prototype.toURI=function(){var n=this.toJSON();return encodeURIComponent(n)};D.prototype.toComment=function(n){var e,t,r;return n!=null&&n.encoding==="uri"?(e="",t=this.toURI()):(e=";base64",t=this.toBase64()),r="sourceMappingURL=data:application/json;charset=utf-8"+e+","+t,n!=null&&n.multiline?"/*# "+r+" */":"//# "+r};D.prototype.toObject=function(){return JSON.parse(this.toJSON())};D.prototype.addProperty=function(n,e){if(this.sourcemap.hasOwnProperty(n))throw new Error('property "'+n+'" already exists on the sourcemap, use set property instead');return this.setProperty(n,e)};D.prototype.setProperty=function(n,e){return this.sourcemap[n]=e,this};D.prototype.getProperty=function(n){return this.sourcemap[n]};A.fromObject=function(n){return new D(n)};A.fromJSON=function(n){return new D(n,{isJSON:!0})};A.fromURI=function(n){return new D(n,{encoding:"uri"})};A.fromBase64=function(n){return new D(n,{encoding:"base64"})};A.fromComment=function(n){var e,t;return n=n.replace(/^\/\*/g,"//").replace(/\*\/$/g,""),e=A.commentRegex.exec(n),t=e&&e[4]||"uri",new D(n,{encoding:t,hasComment:!0})};function rn(n){return new D(n,{isJSON:!0})}A.fromMapFileComment=function(n,e){if(typeof e=="string")throw new Error("String directory paths are no longer supported with `fromMapFileComment`\nPlease review the Upgrading documentation at https://github.com/thlorenz/convert-source-map#upgrading");var t=Bo(n,e);return t!=null&&typeof t.then=="function"?t.then(rn):rn(t)};A.fromSource=function(n){var e=n.match(A.commentRegex);return e?A.fromComment(e.pop()):null};A.fromMapFileSource=function(n,e){if(typeof e=="string")throw new Error("String directory paths are no longer supported with `fromMapFileSource`\nPlease review the Upgrading documentation at https://github.com/thlorenz/convert-source-map#upgrading");var t=n.match(A.mapFileCommentRegex);return t?A.fromMapFileComment(t.pop(),e):null};A.removeComments=function(n){return n.replace(A.commentRegex,"")};A.removeMapFileComments=function(n){return n.replace(A.mapFileCommentRegex,"")};A.generateMapFileComment=function(n,e){var t="sourceMappingURL="+n;return e&&e.multiline?"/*# "+t+" */":"//# "+t}});var qt=S((Ef,$t)=>{"use strict";$t.exports.isClean=Symbol("isClean");$t.exports.my=Symbol("my")});var zt=S((Cf,Gt)=>{var sn=process.argv||[],ht=process.env,Wo=!("NO_COLOR"in ht||sn.includes("--no-color"))&&("FORCE_COLOR"in ht||sn.includes("--color")||process.platform==="win32"||require!=null&&require("tty").isatty(1)&&ht.TERM!=="dumb"||"CI"in ht),jo=(n,e,t=n)=>r=>{let s=""+r,i=s.indexOf(e,n.length);return~i?n+$o(s,e,t,i)+e:n+s+e},$o=(n,e,t,r)=>{let s="",i=0;do s+=n.substring(i,r)+t,i=r+e.length,r=n.indexOf(e,i);while(~r);return s+n.substring(i)},on=(n=Wo)=>{let e=n?jo:()=>String;return{isColorSupported:n,reset:e("\x1B[0m","\x1B[0m"),bold:e("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:e("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:e("\x1B[3m","\x1B[23m"),underline:e("\x1B[4m","\x1B[24m"),inverse:e("\x1B[7m","\x1B[27m"),hidden:e("\x1B[8m","\x1B[28m"),strikethrough:e("\x1B[9m","\x1B[29m"),black:e("\x1B[30m","\x1B[39m"),red:e("\x1B[31m","\x1B[39m"),green:e("\x1B[32m","\x1B[39m"),yellow:e("\x1B[33m","\x1B[39m"),blue:e("\x1B[34m","\x1B[39m"),magenta:e("\x1B[35m","\x1B[39m"),cyan:e("\x1B[36m","\x1B[39m"),white:e("\x1B[37m","\x1B[39m"),gray:e("\x1B[90m","\x1B[39m"),bgBlack:e("\x1B[40m","\x1B[49m"),bgRed:e("\x1B[41m","\x1B[49m"),bgGreen:e("\x1B[42m","\x1B[49m"),bgYellow:e("\x1B[43m","\x1B[49m"),bgBlue:e("\x1B[44m","\x1B[49m"),bgMagenta:e("\x1B[45m","\x1B[49m"),bgCyan:e("\x1B[46m","\x1B[49m"),bgWhite:e("\x1B[47m","\x1B[49m")}};Gt.exports=on();Gt.exports.createColors=on});var Vt=S((Of,an)=>{"use strict";var pt=/[\t\n\f\r "#'()/;[\\\]{}]/g,dt=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,qo=/.[\r\n"'(/\\]/,ln=/[\da-f]/i;an.exports=function(e,t={}){let r=e.css.valueOf(),s=t.ignoreErrors,i,o,l,u,a,f,h,c,p,m,d=r.length,g=0,y=[],w=[];function b(){return g}function v(N){throw e.error("Unclosed "+N,g)}function E(){return w.length===0&&g>=d}function x(N){if(w.length)return w.pop();if(g>=d)return;let C=N?N.ignoreUnclosed:!1;switch(i=r.charCodeAt(g),i){case 10:case 32:case 9:case 13:case 12:{o=g;do o+=1,i=r.charCodeAt(o);while(i===32||i===10||i===9||i===13||i===12);m=["space",r.slice(g,o)],g=o-1;break}case 91:case 93:case 123:case 125:case 58:case 59:case 41:{let P=String.fromCharCode(i);m=[P,P,g];break}case 40:{if(c=y.length?y.pop()[1]:"",p=r.charCodeAt(g+1),c==="url"&&p!==39&&p!==34&&p!==32&&p!==10&&p!==9&&p!==12&&p!==13){o=g;do{if(f=!1,o=r.indexOf(")",o+1),o===-1)if(s||C){o=g;break}else v("bracket");for(h=o;r.charCodeAt(h-1)===92;)h-=1,f=!f}while(f);m=["brackets",r.slice(g,o+1),g,o],g=o}else o=r.indexOf(")",g+1),u=r.slice(g,o+1),o===-1||qo.test(u)?m=["(","(",g]:(m=["brackets",u,g,o],g=o);break}case 39:case 34:{l=i===39?"'":'"',o=g;do{if(f=!1,o=r.indexOf(l,o+1),o===-1)if(s||C){o=g+1;break}else v("string");for(h=o;r.charCodeAt(h-1)===92;)h-=1,f=!f}while(f);m=["string",r.slice(g,o+1),g,o],g=o;break}case 64:{pt.lastIndex=g+1,pt.test(r),pt.lastIndex===0?o=r.length-1:o=pt.lastIndex-2,m=["at-word",r.slice(g,o+1),g,o],g=o;break}case 92:{for(o=g,a=!0;r.charCodeAt(o+1)===92;)o+=1,a=!a;if(i=r.charCodeAt(o+1),a&&i!==47&&i!==32&&i!==10&&i!==9&&i!==13&&i!==12&&(o+=1,ln.test(r.charAt(o)))){for(;ln.test(r.charAt(o+1));)o+=1;r.charCodeAt(o+1)===32&&(o+=1)}m=["word",r.slice(g,o+1),g,o],g=o;break}default:{i===47&&r.charCodeAt(g+1)===42?(o=r.indexOf("*/",g+2)+1,o===0&&(s||C?o=r.length:v("comment")),m=["comment",r.slice(g,o+1),g,o],g=o):(dt.lastIndex=g+1,dt.test(r),dt.lastIndex===0?o=r.length-1:o=dt.lastIndex-2,m=["word",r.slice(g,o+1),g,o],y.push(m),g=o);break}}return g++,m}function
|
|
1
|
+
var Co=Object.create;var ft=Object.defineProperty;var Oo=Object.getOwnPropertyDescriptor;var Lo=Object.getOwnPropertyNames;var To=Object.getPrototypeOf,Ao=Object.prototype.hasOwnProperty;var S=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports),No=(n,e)=>{for(var t in e)ft(n,t,{get:e[t],enumerable:!0})},tn=(n,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of Lo(e))!Ao.call(n,s)&&s!==t&&ft(n,s,{get:()=>e[s],enumerable:!(r=Oo(e,s))||r.enumerable});return n};var U=(n,e,t)=>(t=n!=null?Co(To(n)):{},tn(e||!n||!n.__esModule?ft(t,"default",{value:n,enumerable:!0}):t,n)),Mo=n=>tn(ft({},"__esModule",{value:!0}),n);var nn=S(A=>{"use strict";Object.defineProperty(A,"commentRegex",{get:function(){return/^\s*?\/[\/\*][@#]\s+?sourceMappingURL=data:(((?:application|text)\/json)(?:;charset=([^;,]+?)?)?)?(?:;(base64))?,(.*?)$/mg}});Object.defineProperty(A,"mapFileCommentRegex",{get:function(){return/(?:\/\/[@#][ \t]+?sourceMappingURL=([^\s'"`]+?)[ \t]*?$)|(?:\/\*[@#][ \t]+sourceMappingURL=([^*]+?)[ \t]*?(?:\*\/){1}[ \t]*?$)/mg}});var ct;typeof Buffer<"u"?typeof Buffer.from=="function"?ct=Ro:ct=Po:ct=ko;function Ro(n){return Buffer.from(n,"base64").toString()}function Po(n){if(typeof value=="number")throw new TypeError("The value to decode must not be of type number.");return new Buffer(n,"base64").toString()}function ko(n){return decodeURIComponent(escape(atob(n)))}function Io(n){return n.split(",").pop()}function Bo(n,e){var t=A.mapFileCommentRegex.exec(n),r=t[1]||t[2];try{var n=e(r);return n!=null&&typeof n.catch=="function"?n.catch(s):n}catch(i){s(i)}function s(i){throw new Error("An error occurred while trying to read the map file at "+r+`
|
|
2
|
+
`+i.stack)}}function D(n,e){e=e||{},e.hasComment&&(n=Io(n)),e.encoding==="base64"?n=ct(n):e.encoding==="uri"&&(n=decodeURIComponent(n)),(e.isJSON||e.encoding)&&(n=JSON.parse(n)),this.sourcemap=n}D.prototype.toJSON=function(n){return JSON.stringify(this.sourcemap,null,n)};typeof Buffer<"u"?typeof Buffer.from=="function"?D.prototype.toBase64=Fo:D.prototype.toBase64=Uo:D.prototype.toBase64=Do;function Fo(){var n=this.toJSON();return Buffer.from(n,"utf8").toString("base64")}function Uo(){var n=this.toJSON();if(typeof n=="number")throw new TypeError("The json to encode must not be of type number.");return new Buffer(n,"utf8").toString("base64")}function Do(){var n=this.toJSON();return btoa(unescape(encodeURIComponent(n)))}D.prototype.toURI=function(){var n=this.toJSON();return encodeURIComponent(n)};D.prototype.toComment=function(n){var e,t,r;return n!=null&&n.encoding==="uri"?(e="",t=this.toURI()):(e=";base64",t=this.toBase64()),r="sourceMappingURL=data:application/json;charset=utf-8"+e+","+t,n!=null&&n.multiline?"/*# "+r+" */":"//# "+r};D.prototype.toObject=function(){return JSON.parse(this.toJSON())};D.prototype.addProperty=function(n,e){if(this.sourcemap.hasOwnProperty(n))throw new Error('property "'+n+'" already exists on the sourcemap, use set property instead');return this.setProperty(n,e)};D.prototype.setProperty=function(n,e){return this.sourcemap[n]=e,this};D.prototype.getProperty=function(n){return this.sourcemap[n]};A.fromObject=function(n){return new D(n)};A.fromJSON=function(n){return new D(n,{isJSON:!0})};A.fromURI=function(n){return new D(n,{encoding:"uri"})};A.fromBase64=function(n){return new D(n,{encoding:"base64"})};A.fromComment=function(n){var e,t;return n=n.replace(/^\/\*/g,"//").replace(/\*\/$/g,""),e=A.commentRegex.exec(n),t=e&&e[4]||"uri",new D(n,{encoding:t,hasComment:!0})};function rn(n){return new D(n,{isJSON:!0})}A.fromMapFileComment=function(n,e){if(typeof e=="string")throw new Error("String directory paths are no longer supported with `fromMapFileComment`\nPlease review the Upgrading documentation at https://github.com/thlorenz/convert-source-map#upgrading");var t=Bo(n,e);return t!=null&&typeof t.then=="function"?t.then(rn):rn(t)};A.fromSource=function(n){var e=n.match(A.commentRegex);return e?A.fromComment(e.pop()):null};A.fromMapFileSource=function(n,e){if(typeof e=="string")throw new Error("String directory paths are no longer supported with `fromMapFileSource`\nPlease review the Upgrading documentation at https://github.com/thlorenz/convert-source-map#upgrading");var t=n.match(A.mapFileCommentRegex);return t?A.fromMapFileComment(t.pop(),e):null};A.removeComments=function(n){return n.replace(A.commentRegex,"")};A.removeMapFileComments=function(n){return n.replace(A.mapFileCommentRegex,"")};A.generateMapFileComment=function(n,e){var t="sourceMappingURL="+n;return e&&e.multiline?"/*# "+t+" */":"//# "+t}});var qt=S((Ef,$t)=>{"use strict";$t.exports.isClean=Symbol("isClean");$t.exports.my=Symbol("my")});var zt=S((Cf,Gt)=>{var sn=process.argv||[],ht=process.env,Wo=!("NO_COLOR"in ht||sn.includes("--no-color"))&&("FORCE_COLOR"in ht||sn.includes("--color")||process.platform==="win32"||require!=null&&require("tty").isatty(1)&&ht.TERM!=="dumb"||"CI"in ht),jo=(n,e,t=n)=>r=>{let s=""+r,i=s.indexOf(e,n.length);return~i?n+$o(s,e,t,i)+e:n+s+e},$o=(n,e,t,r)=>{let s="",i=0;do s+=n.substring(i,r)+t,i=r+e.length,r=n.indexOf(e,i);while(~r);return s+n.substring(i)},on=(n=Wo)=>{let e=n?jo:()=>String;return{isColorSupported:n,reset:e("\x1B[0m","\x1B[0m"),bold:e("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:e("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:e("\x1B[3m","\x1B[23m"),underline:e("\x1B[4m","\x1B[24m"),inverse:e("\x1B[7m","\x1B[27m"),hidden:e("\x1B[8m","\x1B[28m"),strikethrough:e("\x1B[9m","\x1B[29m"),black:e("\x1B[30m","\x1B[39m"),red:e("\x1B[31m","\x1B[39m"),green:e("\x1B[32m","\x1B[39m"),yellow:e("\x1B[33m","\x1B[39m"),blue:e("\x1B[34m","\x1B[39m"),magenta:e("\x1B[35m","\x1B[39m"),cyan:e("\x1B[36m","\x1B[39m"),white:e("\x1B[37m","\x1B[39m"),gray:e("\x1B[90m","\x1B[39m"),bgBlack:e("\x1B[40m","\x1B[49m"),bgRed:e("\x1B[41m","\x1B[49m"),bgGreen:e("\x1B[42m","\x1B[49m"),bgYellow:e("\x1B[43m","\x1B[49m"),bgBlue:e("\x1B[44m","\x1B[49m"),bgMagenta:e("\x1B[45m","\x1B[49m"),bgCyan:e("\x1B[46m","\x1B[49m"),bgWhite:e("\x1B[47m","\x1B[49m")}};Gt.exports=on();Gt.exports.createColors=on});var Vt=S((Of,an)=>{"use strict";var pt=/[\t\n\f\r "#'()/;[\\\]{}]/g,dt=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,qo=/.[\r\n"'(/\\]/,ln=/[\da-f]/i;an.exports=function(e,t={}){let r=e.css.valueOf(),s=t.ignoreErrors,i,o,l,u,a,f,h,c,p,m,d=r.length,g=0,y=[],w=[];function b(){return g}function v(N){throw e.error("Unclosed "+N,g)}function E(){return w.length===0&&g>=d}function x(N){if(w.length)return w.pop();if(g>=d)return;let C=N?N.ignoreUnclosed:!1;switch(i=r.charCodeAt(g),i){case 10:case 32:case 9:case 13:case 12:{o=g;do o+=1,i=r.charCodeAt(o);while(i===32||i===10||i===9||i===13||i===12);m=["space",r.slice(g,o)],g=o-1;break}case 91:case 93:case 123:case 125:case 58:case 59:case 41:{let P=String.fromCharCode(i);m=[P,P,g];break}case 40:{if(c=y.length?y.pop()[1]:"",p=r.charCodeAt(g+1),c==="url"&&p!==39&&p!==34&&p!==32&&p!==10&&p!==9&&p!==12&&p!==13){o=g;do{if(f=!1,o=r.indexOf(")",o+1),o===-1)if(s||C){o=g;break}else v("bracket");for(h=o;r.charCodeAt(h-1)===92;)h-=1,f=!f}while(f);m=["brackets",r.slice(g,o+1),g,o],g=o}else o=r.indexOf(")",g+1),u=r.slice(g,o+1),o===-1||qo.test(u)?m=["(","(",g]:(m=["brackets",u,g,o],g=o);break}case 39:case 34:{l=i===39?"'":'"',o=g;do{if(f=!1,o=r.indexOf(l,o+1),o===-1)if(s||C){o=g+1;break}else v("string");for(h=o;r.charCodeAt(h-1)===92;)h-=1,f=!f}while(f);m=["string",r.slice(g,o+1),g,o],g=o;break}case 64:{pt.lastIndex=g+1,pt.test(r),pt.lastIndex===0?o=r.length-1:o=pt.lastIndex-2,m=["at-word",r.slice(g,o+1),g,o],g=o;break}case 92:{for(o=g,a=!0;r.charCodeAt(o+1)===92;)o+=1,a=!a;if(i=r.charCodeAt(o+1),a&&i!==47&&i!==32&&i!==10&&i!==9&&i!==13&&i!==12&&(o+=1,ln.test(r.charAt(o)))){for(;ln.test(r.charAt(o+1));)o+=1;r.charCodeAt(o+1)===32&&(o+=1)}m=["word",r.slice(g,o+1),g,o],g=o;break}default:{i===47&&r.charCodeAt(g+1)===42?(o=r.indexOf("*/",g+2)+1,o===0&&(s||C?o=r.length:v("comment")),m=["comment",r.slice(g,o+1),g,o],g=o):(dt.lastIndex=g+1,dt.test(r),dt.lastIndex===0?o=r.length-1:o=dt.lastIndex-2,m=["word",r.slice(g,o+1),g,o],y.push(m),g=o);break}}return g++,m}function R(N){w.push(N)}return{back:R,endOfFile:E,nextToken:x,position:b}}});var Ht=S((Lf,cn)=>{"use strict";var j=zt(),Go=Vt(),un;function zo(n){un=n}var Vo={";":j.yellow,":":j.yellow,"(":j.cyan,")":j.cyan,"[":j.yellow,"]":j.yellow,"{":j.yellow,"}":j.yellow,"at-word":j.cyan,brackets:j.cyan,call:j.cyan,class:j.yellow,comment:j.gray,hash:j.magenta,string:j.green};function Ho([n,e],t){if(n==="word"){if(e[0]===".")return"class";if(e[0]==="#")return"hash"}if(!t.endOfFile()){let r=t.nextToken();if(t.back(r),r[0]==="brackets"||r[0]==="(")return"call"}return n}function fn(n){let e=Go(new un(n),{ignoreErrors:!0}),t="";for(;!e.endOfFile();){let r=e.nextToken(),s=Vo[Ho(r,e)];s?t+=r[1].split(/\r?\n/).map(i=>s(i)).join(`
|
|
3
3
|
`):t+=r[1]}return t}fn.registerInput=zo;cn.exports=fn});var Yt=S((Tf,dn)=>{"use strict";var hn=zt(),pn=Ht(),Fe=class n extends Error{constructor(e,t,r,s,i,o){super(e),this.name="CssSyntaxError",this.reason=e,i&&(this.file=i),s&&(this.source=s),o&&(this.plugin=o),typeof t<"u"&&typeof r<"u"&&(typeof t=="number"?(this.line=t,this.column=r):(this.line=t.line,this.column=t.column,this.endLine=r.line,this.endColumn=r.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,n)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(e){if(!this.source)return"";let t=this.source;e==null&&(e=hn.isColorSupported),pn&&e&&(t=pn(t));let r=t.split(/\r?\n/),s=Math.max(this.line-3,0),i=Math.min(this.line+2,r.length),o=String(i).length,l,u;if(e){let{bold:a,gray:f,red:h}=hn.createColors(!0);l=c=>a(h(c)),u=c=>f(c)}else l=u=a=>a;return r.slice(s,i).map((a,f)=>{let h=s+1+f,c=" "+(" "+h).slice(-o)+" | ";if(h===this.line){let p=u(c.replace(/\d/g," "))+a.slice(0,this.column-1).replace(/[^\t]/g," ");return l(">")+u(c)+a+`
|
|
4
4
|
`+p+l("^")}return" "+u(c)+a}).join(`
|
|
5
5
|
`)}toString(){let e=this.showSourceCode();return e&&(e=`
|
|
@@ -16,18 +16,18 @@ var Co=Object.create;var ft=Object.defineProperty;var Oo=Object.getOwnPropertyDe
|
|
|
16
16
|
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),typeof r>"u"?r=this.raw(t,null,"beforeDecl"):r&&(r=r.replace(/\S/g,"")),r}rawBeforeDecl(e,t){let r;return e.walkDecls(s=>{if(typeof s.raws.before<"u")return r=s.raws.before,r.includes(`
|
|
17
17
|
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),typeof r>"u"?r=this.raw(t,null,"beforeRule"):r&&(r=r.replace(/\S/g,"")),r}rawBeforeOpen(e){let t;return e.walk(r=>{if(r.type!=="decl"&&(t=r.raws.between,typeof t<"u"))return!1}),t}rawBeforeRule(e){let t;return e.walk(r=>{if(r.nodes&&(r.parent!==e||e.first!==r)&&typeof r.raws.before<"u")return t=r.raws.before,t.includes(`
|
|
18
18
|
`)&&(t=t.replace(/[^\n]+$/,"")),!1}),t&&(t=t.replace(/\S/g,"")),t}rawColon(e){let t;return e.walkDecls(r=>{if(typeof r.raws.between<"u")return t=r.raws.between.replace(/[^\s:]/g,""),!1}),t}rawEmptyBody(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length===0&&(t=r.raws.after,typeof t<"u"))return!1}),t}rawIndent(e){if(e.raws.indent)return e.raws.indent;let t;return e.walk(r=>{let s=r.parent;if(s&&s!==e&&s.parent&&s.parent===e&&typeof r.raws.before<"u"){let i=r.raws.before.split(`
|
|
19
|
-
`);return t=i[i.length-1],t=t.replace(/\S/g,""),!1}}),t}rawSemicolon(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length&&r.last.type==="decl"&&(t=r.raws.semicolon,typeof t<"u"))return!1}),t}rawValue(e,t){let r=e[t],s=e.raws[t];return s&&s.value===r?s.raw:r}root(e){this.body(e),e.raws.after&&this.builder(e.raws.after)}rule(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")}stringify(e,t){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,t)}};gn.exports=Ue;Ue.default=Ue});var yn=S((Nf,_n)=>{"use strict";var Jo=Jt();function Qt(n,e){new Jo(e).stringify(n)}_n.exports=Qt;Qt.default=Qt});var gt=S((
|
|
20
|
-
`?(s=1,i+=1):s+=1;return{column:s,line:i}}prev(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e-1]}rangeBy(e){let t={column:this.source.start.column,line:this.source.start.line},r=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:t.column+1,line:t.line};if(e.word){let s=this.toString(),i=s.indexOf(e.word);i!==-1&&(t=this.positionInside(i,s),r=this.positionInside(i+e.word.length,s))}else e.start?t={column:e.start.column,line:e.start.line}:e.index&&(t=this.positionInside(e.index)),e.end?r={column:e.end.column,line:e.end.line}:typeof e.endIndex=="number"?r=this.positionInside(e.endIndex):e.index&&(r=this.positionInside(e.index+1));return(r.line<t.line||r.line===t.line&&r.column<=t.column)&&(r={column:t.column+1,line:t.line}),{end:r,start:t}}raw(e,t){return new Zo().raw(this,e,t)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...e){if(this.parent){let t=this,r=!1;for(let s of e)s===this?r=!0:r?(this.parent.insertAfter(t,s),t=s):this.parent.insertBefore(t,s);r||this.remove()}return this}root(){let e=this;for(;e.parent&&e.parent.type!=="document";)e=e.parent;return e}toJSON(e,t){let r={},s=t==null;t=t||new Map;let i=0;for(let o in this){if(!Object.prototype.hasOwnProperty.call(this,o)||o==="parent"||o==="proxyCache")continue;let l=this[o];if(Array.isArray(l))r[o]=l.map(u=>typeof u=="object"&&u.toJSON?u.toJSON(null,t):u);else if(typeof l=="object"&&l.toJSON)r[o]=l.toJSON(null,t);else if(o==="source"){let u=t.get(l.input);u==null&&(u=i,t.set(l.input,i),i++),r[o]={end:l.end,inputId:u,start:l.start}}else r[o]=l}return s&&(r.inputs=[...t.keys()].map(o=>o.toJSON())),r}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(e=Xo){e.stringify&&(e=e.stringify);let t="";return e(this,r=>{t+=r}),t}warn(e,t,r){let s={node:this};for(let i in r)s[i]=r[i];return e.warn(t,s)}get proxyOf(){return this}};wn.exports=De;De.default=De});var Zt=S((
|
|
21
|
-
`," "];return qe.split(n,e)},split(n,e,t){let r=[],s="",i=!1,o=0,l=!1,u="",a=!1;for(let f of n)a?a=!1:f==="\\"?a=!0:l?f===u&&(l=!1):f==='"'||f==="'"?(l=!0,u=f):f==="("?o+=1:f===")"?o>0&&(o-=1):o===0&&e.includes(f)&&(i=!0),i?(s!==""&&r.push(s.trim()),s="",i=!1):s+=f;return(t||s!=="")&&r.push(s.trim()),r}};Dn.exports=qe;qe.default=qe});var qn=S((Uf,$n)=>{"use strict";var jn=$e(),nl=Wn(),be=class extends jn{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return nl.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,r=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(r)}};$n.exports=be;be.default=be;jn.registerRule(be)});var Hn=S((Df,Vn)=>{"use strict";var sl=Zt(),il=Vt(),ol=Xt(),ll=Pn(),al=Un(),Gn=qn(),zn={empty:!0,space:!0};function ul(n){for(let e=n.length-1;e>=0;e--){let t=n[e],r=t[3]||t[2];if(r)return r}}var rr=class{constructor(e){this.input=e,this.root=new al,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new ll;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let r,s,i,o=!1,l=!1,u=[],a=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),r=e[0],r==="("||r==="["?a.push(r==="("?")":"]"):r==="{"&&a.length>0?a.push("}"):r===a[a.length-1]&&a.pop(),a.length===0)if(r===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(r==="{"){l=!0;break}else if(r==="}"){if(u.length>0){for(i=u.length-1,s=u[i];s&&s[0]==="space";)s=u[--i];s&&(t.source.end=this.getPosition(s[3]||s[2]),t.source.end.offset++)}this.end(e);break}else u.push(e);else u.push(e);if(this.tokenizer.endOfFile()){o=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(u),u.length?(t.raws.afterName=this.spacesAndCommentsFromStart(u),this.raw(t,"params",u),o&&(e=u[u.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),l&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let r=0,s;for(let i=t-1;i>=0&&(s=e[i],!(s[0]!=="space"&&(r+=1,r===2)));i--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}colon(e){let t=0,r,s,i;for(let[o,l]of e.entries()){if(r=l,s=r[0],s==="("&&(t+=1),s===")"&&(t-=1),t===0&&s===":")if(!i)this.doubleColon(r);else{if(i[0]==="word"&&i[1]==="progid")continue;return o}i=r}return!1}comment(e){let t=new ol;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let r=e[1].slice(2,-2);if(/^\s*$/.test(r))t.text="",t.raws.left=r,t.raws.right="";else{let s=r.match(/^(\s*)([^]*\S)(\s*)$/);t.text=s[2],t.raws.left=s[1],t.raws.right=s[3]}}createTokenizer(){this.tokenizer=il(this.input)}decl(e,t){let r=new sl;this.init(r,e[0][2]);let s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),r.source.end=this.getPosition(s[3]||s[2]||ul(e)),r.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),r.raws.before+=e.shift()[1];for(r.source.start=this.getPosition(e[0][2]),r.prop="";e.length;){let a=e[0][0];if(a===":"||a==="space"||a==="comment")break;r.prop+=e.shift()[1]}r.raws.between="";let i;for(;e.length;)if(i=e.shift(),i[0]===":"){r.raws.between+=i[1];break}else i[0]==="word"&&/\w/.test(i[1])&&this.unknownWord([i]),r.raws.between+=i[1];(r.prop[0]==="_"||r.prop[0]==="*")&&(r.raws.before+=r.prop[0],r.prop=r.prop.slice(1));let o=[],l;for(;e.length&&(l=e[0][0],!(l!=="space"&&l!=="comment"));)o.push(e.shift());this.precheckMissedSemicolon(e);for(let a=e.length-1;a>=0;a--){if(i=e[a],i[1].toLowerCase()==="!important"){r.important=!0;let f=this.stringFrom(e,a);f=this.spacesFromEnd(e)+f,f!==" !important"&&(r.raws.important=f);break}else if(i[1].toLowerCase()==="important"){let f=e.slice(0),h="";for(let c=a;c>0;c--){let p=f[c][0];if(h.trim().indexOf("!")===0&&p!=="space")break;h=f.pop()[1]+h}h.trim().indexOf("!")===0&&(r.important=!0,r.raws.important=h,e=f)}if(i[0]!=="space"&&i[0]!=="comment")break}e.some(a=>a[0]!=="space"&&a[0]!=="comment")&&(r.raws.between+=o.map(a=>a[1]).join(""),o=[]),this.raw(r,"value",o.concat(e),t),r.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new Gn;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,r=null,s=!1,i=null,o=[],l=e[1].startsWith("--"),u=[],a=e;for(;a;){if(r=a[0],u.push(a),r==="("||r==="[")i||(i=a),o.push(r==="("?")":"]");else if(l&&s&&r==="{")i||(i=a),o.push("}");else if(o.length===0)if(r===";")if(s){this.decl(u,l);return}else break;else if(r==="{"){this.rule(u);return}else if(r==="}"){this.tokenizer.back(u.pop()),t=!0;break}else r===":"&&(s=!0);else r===o[o.length-1]&&(o.pop(),o.length===0&&(i=null));a=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),o.length>0&&this.unclosedBracket(i),t&&s){if(!l)for(;u.length&&(a=u[u.length-1][0],!(a!=="space"&&a!=="comment"));)this.tokenizer.back(u.pop());this.decl(u,l)}else this.unknownWord(u)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,r,s){let i,o,l=r.length,u="",a=!0,f,h;for(let c=0;c<l;c+=1)i=r[c],o=i[0],o==="space"&&c===l-1&&!s?a=!1:o==="comment"?(h=r[c-1]?r[c-1][0]:"empty",f=r[c+1]?r[c+1][0]:"empty",!zn[h]&&!zn[f]?u.slice(-1)===","?a=!1:u+=i[1]:a=!1):u+=i[1];if(!a){let c=r.reduce((p,m)=>p+m[1],"");e.raws[t]={raw:c,value:u}}e[t]=u}rule(e){e.pop();let t=new Gn;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)r=e.pop()[1]+r;return r}spacesAndCommentsFromStart(e){let t,r="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)r+=e.shift()[1];return r}spacesFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],t==="space");)r=e.pop()[1]+r;return r}stringFrom(e,t){let r="";for(let s=t;s<e.length;s++)r+=e[s][1];return e.splice(t,e.length-t),r}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}};Vn.exports=rr});var Jn=S(nr=>{var Yn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");nr.encode=function(n){if(0<=n&&n<Yn.length)return Yn[n];throw new TypeError("Must be between 0 and 63: "+n)};nr.decode=function(n){var e=65,t=90,r=97,s=122,i=48,o=57,l=43,u=47,a=26,f=52;return e<=n&&n<=t?n-e:r<=n&&n<=s?n-r+a:i<=n&&n<=o?n-i+f:n==l?62:n==u?63:-1}});var or=S(ir=>{var Qn=Jn(),sr=5,Kn=1<<sr,Zn=Kn-1,Xn=Kn;function fl(n){return n<0?(-n<<1)+1:(n<<1)+0}function cl(n){var e=(n&1)===1,t=n>>1;return e?-t:t}ir.encode=function(e){var t="",r,s=fl(e);do r=s&Zn,s>>>=sr,s>0&&(r|=Xn),t+=Qn.encode(r);while(s>0);return t};ir.decode=function(e,t,r){var s=e.length,i=0,o=0,l,u;do{if(t>=s)throw new Error("Expected more digits in base 64 VLQ value.");if(u=Qn.decode(e.charCodeAt(t++)),u===-1)throw new Error("Invalid base64 digit: "+e.charAt(t-1));l=!!(u&Xn),u&=Zn,i=i+(u<<o),o+=sr}while(l);r.value=cl(i),r.rest=t}});var Ce=S(k=>{function hl(n,e,t){if(e in n)return n[e];if(arguments.length===3)return t;throw new Error('"'+e+'" is a required argument.')}k.getArg=hl;var es=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,pl=/^data:.+\,.+$/;function Ge(n){var e=n.match(es);return e?{scheme:e[1],auth:e[2],host:e[3],port:e[4],path:e[5]}:null}k.urlParse=Ge;function Ee(n){var e="";return n.scheme&&(e+=n.scheme+":"),e+="//",n.auth&&(e+=n.auth+"@"),n.host&&(e+=n.host),n.port&&(e+=":"+n.port),n.path&&(e+=n.path),e}k.urlGenerate=Ee;var dl=32;function ml(n){var e=[];return function(t){for(var r=0;r<e.length;r++)if(e[r].input===t){var s=e[0];return e[0]=e[r],e[r]=s,e[0].result}var i=n(t);return e.unshift({input:t,result:i}),e.length>dl&&e.pop(),i}}var lr=ml(function(e){var t=e,r=Ge(e);if(r){if(!r.path)return e;t=r.path}for(var s=k.isAbsolute(t),i=[],o=0,l=0;;)if(o=l,l=t.indexOf("/",o),l===-1){i.push(t.slice(o));break}else for(i.push(t.slice(o,l));l<t.length&&t[l]==="/";)l++;for(var u,a=0,l=i.length-1;l>=0;l--)u=i[l],u==="."?i.splice(l,1):u===".."?a++:a>0&&(u===""?(i.splice(l+1,a),a=0):(i.splice(l,2),a--));return t=i.join("/"),t===""&&(t=s?"/":"."),r?(r.path=t,Ee(r)):t});k.normalize=lr;function ts(n,e){n===""&&(n="."),e===""&&(e=".");var t=Ge(e),r=Ge(n);if(r&&(n=r.path||"/"),t&&!t.scheme)return r&&(t.scheme=r.scheme),Ee(t);if(t||e.match(pl))return e;if(r&&!r.host&&!r.path)return r.host=e,Ee(r);var s=e.charAt(0)==="/"?e:lr(n.replace(/\/+$/,"")+"/"+e);return r?(r.path=s,Ee(r)):s}k.join=ts;k.isAbsolute=function(n){return n.charAt(0)==="/"||es.test(n)};function gl(n,e){n===""&&(n="."),n=n.replace(/\/$/,"");for(var t=0;e.indexOf(n+"/")!==0;){var r=n.lastIndexOf("/");if(r<0||(n=n.slice(0,r),n.match(/^([^\/]+:\/)?\/*$/)))return e;++t}return Array(t+1).join("../")+e.substr(n.length+1)}k.relative=gl;var rs=function(){var n=Object.create(null);return!("__proto__"in n)}();function ns(n){return n}function _l(n){return ss(n)?"$"+n:n}k.toSetString=rs?ns:_l;function yl(n){return ss(n)?n.slice(1):n}k.fromSetString=rs?ns:yl;function ss(n){if(!n)return!1;var e=n.length;if(e<9||n.charCodeAt(e-1)!==95||n.charCodeAt(e-2)!==95||n.charCodeAt(e-3)!==111||n.charCodeAt(e-4)!==116||n.charCodeAt(e-5)!==111||n.charCodeAt(e-6)!==114||n.charCodeAt(e-7)!==112||n.charCodeAt(e-8)!==95||n.charCodeAt(e-9)!==95)return!1;for(var t=e-10;t>=0;t--)if(n.charCodeAt(t)!==36)return!1;return!0}function wl(n,e,t){var r=re(n.source,e.source);return r!==0||(r=n.originalLine-e.originalLine,r!==0)||(r=n.originalColumn-e.originalColumn,r!==0||t)||(r=n.generatedColumn-e.generatedColumn,r!==0)||(r=n.generatedLine-e.generatedLine,r!==0)?r:re(n.name,e.name)}k.compareByOriginalPositions=wl;function Sl(n,e,t){var r;return r=n.originalLine-e.originalLine,r!==0||(r=n.originalColumn-e.originalColumn,r!==0||t)||(r=n.generatedColumn-e.generatedColumn,r!==0)||(r=n.generatedLine-e.generatedLine,r!==0)?r:re(n.name,e.name)}k.compareByOriginalPositionsNoSource=Sl;function vl(n,e,t){var r=n.generatedLine-e.generatedLine;return r!==0||(r=n.generatedColumn-e.generatedColumn,r!==0||t)||(r=re(n.source,e.source),r!==0)||(r=n.originalLine-e.originalLine,r!==0)||(r=n.originalColumn-e.originalColumn,r!==0)?r:re(n.name,e.name)}k.compareByGeneratedPositionsDeflated=vl;function xl(n,e,t){var r=n.generatedColumn-e.generatedColumn;return r!==0||t||(r=re(n.source,e.source),r!==0)||(r=n.originalLine-e.originalLine,r!==0)||(r=n.originalColumn-e.originalColumn,r!==0)?r:re(n.name,e.name)}k.compareByGeneratedPositionsDeflatedNoLine=xl;function re(n,e){return n===e?0:n===null?1:e===null?-1:n>e?1:-1}function bl(n,e){var t=n.generatedLine-e.generatedLine;return t!==0||(t=n.generatedColumn-e.generatedColumn,t!==0)||(t=re(n.source,e.source),t!==0)||(t=n.originalLine-e.originalLine,t!==0)||(t=n.originalColumn-e.originalColumn,t!==0)?t:re(n.name,e.name)}k.compareByGeneratedPositionsInflated=bl;function El(n){return JSON.parse(n.replace(/^\)]}'[^\n]*\n/,""))}k.parseSourceMapInput=El;function Cl(n,e,t){if(e=e||"",n&&(n[n.length-1]!=="/"&&e[0]!=="/"&&(n+="/"),e=n+e),t){var r=Ge(t);if(!r)throw new Error("sourceMapURL could not be parsed");if(r.path){var s=r.path.lastIndexOf("/");s>=0&&(r.path=r.path.substring(0,s+1))}e=ts(Ee(r),e)}return lr(e)}k.computeSourceURL=Cl});var fr=S(is=>{var ar=Ce(),ur=Object.prototype.hasOwnProperty,de=typeof Map<"u";function ne(){this._array=[],this._set=de?new Map:Object.create(null)}ne.fromArray=function(e,t){for(var r=new ne,s=0,i=e.length;s<i;s++)r.add(e[s],t);return r};ne.prototype.size=function(){return de?this._set.size:Object.getOwnPropertyNames(this._set).length};ne.prototype.add=function(e,t){var r=de?e:ar.toSetString(e),s=de?this.has(e):ur.call(this._set,r),i=this._array.length;(!s||t)&&this._array.push(e),s||(de?this._set.set(e,i):this._set[r]=i)};ne.prototype.has=function(e){if(de)return this._set.has(e);var t=ar.toSetString(e);return ur.call(this._set,t)};ne.prototype.indexOf=function(e){if(de){var t=this._set.get(e);if(t>=0)return t}else{var r=ar.toSetString(e);if(ur.call(this._set,r))return this._set[r]}throw new Error('"'+e+'" is not in the set.')};ne.prototype.at=function(e){if(e>=0&&e<this._array.length)return this._array[e];throw new Error("No element indexed by "+e)};ne.prototype.toArray=function(){return this._array.slice()};is.ArraySet=ne});var as=S(ls=>{var os=Ce();function Ol(n,e){var t=n.generatedLine,r=e.generatedLine,s=n.generatedColumn,i=e.generatedColumn;return r>t||r==t&&i>=s||os.compareByGeneratedPositionsInflated(n,e)<=0}function _t(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}_t.prototype.unsortedForEach=function(e,t){this._array.forEach(e,t)};_t.prototype.add=function(e){Ol(this._last,e)?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))};_t.prototype.toArray=function(){return this._sorted||(this._array.sort(os.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};ls.MappingList=_t});var cr=S(us=>{var ze=or(),R=Ce(),yt=fr().ArraySet,Ll=as().MappingList;function z(n){n||(n={}),this._file=R.getArg(n,"file",null),this._sourceRoot=R.getArg(n,"sourceRoot",null),this._skipValidation=R.getArg(n,"skipValidation",!1),this._ignoreInvalidMapping=R.getArg(n,"ignoreInvalidMapping",!1),this._sources=new yt,this._names=new yt,this._mappings=new Ll,this._sourcesContents=null}z.prototype._version=3;z.fromSourceMap=function(e,t){var r=e.sourceRoot,s=new z(Object.assign(t||{},{file:e.file,sourceRoot:r}));return e.eachMapping(function(i){var o={generated:{line:i.generatedLine,column:i.generatedColumn}};i.source!=null&&(o.source=i.source,r!=null&&(o.source=R.relative(r,o.source)),o.original={line:i.originalLine,column:i.originalColumn},i.name!=null&&(o.name=i.name)),s.addMapping(o)}),e.sources.forEach(function(i){var o=i;r!==null&&(o=R.relative(r,i)),s._sources.has(o)||s._sources.add(o);var l=e.sourceContentFor(i);l!=null&&s.setSourceContent(i,l)}),s};z.prototype.addMapping=function(e){var t=R.getArg(e,"generated"),r=R.getArg(e,"original",null),s=R.getArg(e,"source",null),i=R.getArg(e,"name",null);!this._skipValidation&&this._validateMapping(t,r,s,i)===!1||(s!=null&&(s=String(s),this._sources.has(s)||this._sources.add(s)),i!=null&&(i=String(i),this._names.has(i)||this._names.add(i)),this._mappings.add({generatedLine:t.line,generatedColumn:t.column,originalLine:r!=null&&r.line,originalColumn:r!=null&&r.column,source:s,name:i}))};z.prototype.setSourceContent=function(e,t){var r=e;this._sourceRoot!=null&&(r=R.relative(this._sourceRoot,r)),t!=null?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[R.toSetString(r)]=t):this._sourcesContents&&(delete this._sourcesContents[R.toSetString(r)],Object.keys(this._sourcesContents).length===0&&(this._sourcesContents=null))};z.prototype.applySourceMap=function(e,t,r){var s=t;if(t==null){if(e.file==null)throw new Error(`SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map's "file" property. Both were omitted.`);s=e.file}var i=this._sourceRoot;i!=null&&(s=R.relative(i,s));var o=new yt,l=new yt;this._mappings.unsortedForEach(function(u){if(u.source===s&&u.originalLine!=null){var a=e.originalPositionFor({line:u.originalLine,column:u.originalColumn});a.source!=null&&(u.source=a.source,r!=null&&(u.source=R.join(r,u.source)),i!=null&&(u.source=R.relative(i,u.source)),u.originalLine=a.line,u.originalColumn=a.column,a.name!=null&&(u.name=a.name))}var f=u.source;f!=null&&!o.has(f)&&o.add(f);var h=u.name;h!=null&&!l.has(h)&&l.add(h)},this),this._sources=o,this._names=l,e.sources.forEach(function(u){var a=e.sourceContentFor(u);a!=null&&(r!=null&&(u=R.join(r,u)),i!=null&&(u=R.relative(i,u)),this.setSourceContent(u,a))},this)};z.prototype._validateMapping=function(e,t,r,s){if(t&&typeof t.line!="number"&&typeof t.column!="number"){var i="original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.";if(this._ignoreInvalidMapping)return typeof console<"u"&&console.warn&&console.warn(i),!1;throw new Error(i)}if(!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0&&!t&&!r&&!s)){if(e&&"line"in e&&"column"in e&&t&&"line"in t&&"column"in t&&e.line>0&&e.column>=0&&t.line>0&&t.column>=0&&r)return;var i="Invalid mapping: "+JSON.stringify({generated:e,source:r,original:t,name:s});if(this._ignoreInvalidMapping)return typeof console<"u"&&console.warn&&console.warn(i),!1;throw new Error(i)}};z.prototype._serializeMappings=function(){for(var e=0,t=1,r=0,s=0,i=0,o=0,l="",u,a,f,h,c=this._mappings.toArray(),p=0,m=c.length;p<m;p++){if(a=c[p],u="",a.generatedLine!==t)for(e=0;a.generatedLine!==t;)u+=";",t++;else if(p>0){if(!R.compareByGeneratedPositionsInflated(a,c[p-1]))continue;u+=","}u+=ze.encode(a.generatedColumn-e),e=a.generatedColumn,a.source!=null&&(h=this._sources.indexOf(a.source),u+=ze.encode(h-o),o=h,u+=ze.encode(a.originalLine-1-s),s=a.originalLine-1,u+=ze.encode(a.originalColumn-r),r=a.originalColumn,a.name!=null&&(f=this._names.indexOf(a.name),u+=ze.encode(f-i),i=f)),l+=u}return l};z.prototype._generateSourcesContent=function(e,t){return e.map(function(r){if(!this._sourcesContents)return null;t!=null&&(r=R.relative(t,r));var s=R.toSetString(r);return Object.prototype.hasOwnProperty.call(this._sourcesContents,s)?this._sourcesContents[s]:null},this)};z.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(e.file=this._file),this._sourceRoot!=null&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e};z.prototype.toString=function(){return JSON.stringify(this.toJSON())};us.SourceMapGenerator=z});var fs=S(me=>{me.GREATEST_LOWER_BOUND=1;me.LEAST_UPPER_BOUND=2;function hr(n,e,t,r,s,i){var o=Math.floor((e-n)/2)+n,l=s(t,r[o],!0);return l===0?o:l>0?e-o>1?hr(o,e,t,r,s,i):i==me.LEAST_UPPER_BOUND?e<r.length?e:-1:o:o-n>1?hr(n,o,t,r,s,i):i==me.LEAST_UPPER_BOUND?o:n<0?-1:n}me.search=function(e,t,r,s){if(t.length===0)return-1;var i=hr(-1,t.length,e,t,r,s||me.GREATEST_LOWER_BOUND);if(i<0)return-1;for(;i-1>=0&&r(t[i],t[i-1],!0)===0;)--i;return i}});var ps=S(hs=>{function Tl(n){function e(s,i,o){var l=s[i];s[i]=s[o],s[o]=l}function t(s,i){return Math.round(s+Math.random()*(i-s))}function r(s,i,o,l){if(o<l){var u=t(o,l),a=o-1;e(s,u,l);for(var f=s[l],h=o;h<l;h++)i(s[h],f,!1)<=0&&(a+=1,e(s,a,h));e(s,a+1,h);var c=a+1;r(s,i,o,c-1),r(s,i,c+1,l)}}return r}function Al(n){let e=Tl.toString();return new Function(`return ${e}`)()(n)}var cs=new WeakMap;hs.quickSort=function(n,e,t=0){let r=cs.get(e);r===void 0&&(r=Al(e),cs.set(e,r)),r(n,e,t,n.length-1)}});var gs=S(wt=>{var _=Ce(),dr=fs(),Oe=fr().ArraySet,Nl=or(),Ve=ps().quickSort;function O(n,e){var t=n;return typeof n=="string"&&(t=_.parseSourceMapInput(n)),t.sections!=null?new Z(t,e):new B(t,e)}O.fromSourceMap=function(n,e){return B.fromSourceMap(n,e)};O.prototype._version=3;O.prototype.__generatedMappings=null;Object.defineProperty(O.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}});O.prototype.__originalMappings=null;Object.defineProperty(O.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}});O.prototype._charIsMappingSeparator=function(e,t){var r=e.charAt(t);return r===";"||r===","};O.prototype._parseMappings=function(e,t){throw new Error("Subclasses must implement _parseMappings")};O.GENERATED_ORDER=1;O.ORIGINAL_ORDER=2;O.GREATEST_LOWER_BOUND=1;O.LEAST_UPPER_BOUND=2;O.prototype.eachMapping=function(e,t,r){var s=t||null,i=r||O.GENERATED_ORDER,o;switch(i){case O.GENERATED_ORDER:o=this._generatedMappings;break;case O.ORIGINAL_ORDER:o=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}for(var l=this.sourceRoot,u=e.bind(s),a=this._names,f=this._sources,h=this._sourceMapURL,c=0,p=o.length;c<p;c++){var m=o[c],d=m.source===null?null:f.at(m.source);d=_.computeSourceURL(l,d,h),u({source:d,generatedLine:m.generatedLine,generatedColumn:m.generatedColumn,originalLine:m.originalLine,originalColumn:m.originalColumn,name:m.name===null?null:a.at(m.name)})}};O.prototype.allGeneratedPositionsFor=function(e){var t=_.getArg(e,"line"),r={source:_.getArg(e,"source"),originalLine:t,originalColumn:_.getArg(e,"column",0)};if(r.source=this._findSourceIndex(r.source),r.source<0)return[];var s=[],i=this._findMapping(r,this._originalMappings,"originalLine","originalColumn",_.compareByOriginalPositions,dr.LEAST_UPPER_BOUND);if(i>=0){var o=this._originalMappings[i];if(e.column===void 0)for(var l=o.originalLine;o&&o.originalLine===l;)s.push({line:_.getArg(o,"generatedLine",null),column:_.getArg(o,"generatedColumn",null),lastColumn:_.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++i];else for(var u=o.originalColumn;o&&o.originalLine===t&&o.originalColumn==u;)s.push({line:_.getArg(o,"generatedLine",null),column:_.getArg(o,"generatedColumn",null),lastColumn:_.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++i]}return s};wt.SourceMapConsumer=O;function B(n,e){var t=n;typeof n=="string"&&(t=_.parseSourceMapInput(n));var r=_.getArg(t,"version"),s=_.getArg(t,"sources"),i=_.getArg(t,"names",[]),o=_.getArg(t,"sourceRoot",null),l=_.getArg(t,"sourcesContent",null),u=_.getArg(t,"mappings"),a=_.getArg(t,"file",null);if(r!=this._version)throw new Error("Unsupported version: "+r);o&&(o=_.normalize(o)),s=s.map(String).map(_.normalize).map(function(f){return o&&_.isAbsolute(o)&&_.isAbsolute(f)?_.relative(o,f):f}),this._names=Oe.fromArray(i.map(String),!0),this._sources=Oe.fromArray(s,!0),this._absoluteSources=this._sources.toArray().map(function(f){return _.computeSourceURL(o,f,e)}),this.sourceRoot=o,this.sourcesContent=l,this._mappings=u,this._sourceMapURL=e,this.file=a}B.prototype=Object.create(O.prototype);B.prototype.consumer=O;B.prototype._findSourceIndex=function(n){var e=n;if(this.sourceRoot!=null&&(e=_.relative(this.sourceRoot,e)),this._sources.has(e))return this._sources.indexOf(e);var t;for(t=0;t<this._absoluteSources.length;++t)if(this._absoluteSources[t]==n)return t;return-1};B.fromSourceMap=function(e,t){var r=Object.create(B.prototype),s=r._names=Oe.fromArray(e._names.toArray(),!0),i=r._sources=Oe.fromArray(e._sources.toArray(),!0);r.sourceRoot=e._sourceRoot,r.sourcesContent=e._generateSourcesContent(r._sources.toArray(),r.sourceRoot),r.file=e._file,r._sourceMapURL=t,r._absoluteSources=r._sources.toArray().map(function(p){return _.computeSourceURL(r.sourceRoot,p,t)});for(var o=e._mappings.toArray().slice(),l=r.__generatedMappings=[],u=r.__originalMappings=[],a=0,f=o.length;a<f;a++){var h=o[a],c=new ms;c.generatedLine=h.generatedLine,c.generatedColumn=h.generatedColumn,h.source&&(c.source=i.indexOf(h.source),c.originalLine=h.originalLine,c.originalColumn=h.originalColumn,h.name&&(c.name=s.indexOf(h.name)),u.push(c)),l.push(c)}return Ve(r.__originalMappings,_.compareByOriginalPositions),r};B.prototype._version=3;Object.defineProperty(B.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});function ms(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}var pr=_.compareByGeneratedPositionsDeflatedNoLine;function ds(n,e){let t=n.length,r=n.length-e;if(!(r<=1))if(r==2){let s=n[e],i=n[e+1];pr(s,i)>0&&(n[e]=i,n[e+1]=s)}else if(r<20)for(let s=e;s<t;s++)for(let i=s;i>e;i--){let o=n[i-1],l=n[i];if(pr(o,l)<=0)break;n[i-1]=l,n[i]=o}else Ve(n,pr,e)}B.prototype._parseMappings=function(e,t){var r=1,s=0,i=0,o=0,l=0,u=0,a=e.length,f=0,h={},c={},p=[],m=[],d,g,y,w,b;let v=0;for(;f<a;)if(e.charAt(f)===";")r++,f++,s=0,ds(m,v),v=m.length;else if(e.charAt(f)===",")f++;else{for(d=new ms,d.generatedLine=r,w=f;w<a&&!this._charIsMappingSeparator(e,w);w++);for(g=e.slice(f,w),y=[];f<w;)Nl.decode(e,f,c),b=c.value,f=c.rest,y.push(b);if(y.length===2)throw new Error("Found a source, but no line and column");if(y.length===3)throw new Error("Found a source and line, but no column");if(d.generatedColumn=s+y[0],s=d.generatedColumn,y.length>1&&(d.source=l+y[1],l+=y[1],d.originalLine=i+y[2],i=d.originalLine,d.originalLine+=1,d.originalColumn=o+y[3],o=d.originalColumn,y.length>4&&(d.name=u+y[4],u+=y[4])),m.push(d),typeof d.originalLine=="number"){let x=d.source;for(;p.length<=x;)p.push(null);p[x]===null&&(p[x]=[]),p[x].push(d)}}ds(m,v),this.__generatedMappings=m;for(var E=0;E<p.length;E++)p[E]!=null&&Ve(p[E],_.compareByOriginalPositionsNoSource);this.__originalMappings=[].concat(...p)};B.prototype._findMapping=function(e,t,r,s,i,o){if(e[r]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[r]);if(e[s]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[s]);return dr.search(e,t,i,o)};B.prototype.computeColumnSpans=function(){for(var e=0;e<this._generatedMappings.length;++e){var t=this._generatedMappings[e];if(e+1<this._generatedMappings.length){var r=this._generatedMappings[e+1];if(t.generatedLine===r.generatedLine){t.lastGeneratedColumn=r.generatedColumn-1;continue}}t.lastGeneratedColumn=1/0}};B.prototype.originalPositionFor=function(e){var t={generatedLine:_.getArg(e,"line"),generatedColumn:_.getArg(e,"column")},r=this._findMapping(t,this._generatedMappings,"generatedLine","generatedColumn",_.compareByGeneratedPositionsDeflated,_.getArg(e,"bias",O.GREATEST_LOWER_BOUND));if(r>=0){var s=this._generatedMappings[r];if(s.generatedLine===t.generatedLine){var i=_.getArg(s,"source",null);i!==null&&(i=this._sources.at(i),i=_.computeSourceURL(this.sourceRoot,i,this._sourceMapURL));var o=_.getArg(s,"name",null);return o!==null&&(o=this._names.at(o)),{source:i,line:_.getArg(s,"originalLine",null),column:_.getArg(s,"originalColumn",null),name:o}}}return{source:null,line:null,column:null,name:null}};B.prototype.hasContentsOfAllSources=function(){return this.sourcesContent?this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(e){return e==null}):!1};B.prototype.sourceContentFor=function(e,t){if(!this.sourcesContent)return null;var r=this._findSourceIndex(e);if(r>=0)return this.sourcesContent[r];var s=e;this.sourceRoot!=null&&(s=_.relative(this.sourceRoot,s));var i;if(this.sourceRoot!=null&&(i=_.urlParse(this.sourceRoot))){var o=s.replace(/^file:\/\//,"");if(i.scheme=="file"&&this._sources.has(o))return this.sourcesContent[this._sources.indexOf(o)];if((!i.path||i.path=="/")&&this._sources.has("/"+s))return this.sourcesContent[this._sources.indexOf("/"+s)]}if(t)return null;throw new Error('"'+s+'" is not in the SourceMap.')};B.prototype.generatedPositionFor=function(e){var t=_.getArg(e,"source");if(t=this._findSourceIndex(t),t<0)return{line:null,column:null,lastColumn:null};var r={source:t,originalLine:_.getArg(e,"line"),originalColumn:_.getArg(e,"column")},s=this._findMapping(r,this._originalMappings,"originalLine","originalColumn",_.compareByOriginalPositions,_.getArg(e,"bias",O.GREATEST_LOWER_BOUND));if(s>=0){var i=this._originalMappings[s];if(i.source===r.source)return{line:_.getArg(i,"generatedLine",null),column:_.getArg(i,"generatedColumn",null),lastColumn:_.getArg(i,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}};wt.BasicSourceMapConsumer=B;function Z(n,e){var t=n;typeof n=="string"&&(t=_.parseSourceMapInput(n));var r=_.getArg(t,"version"),s=_.getArg(t,"sections");if(r!=this._version)throw new Error("Unsupported version: "+r);this._sources=new Oe,this._names=new Oe;var i={line:-1,column:0};this._sections=s.map(function(o){if(o.url)throw new Error("Support for url field in sections not implemented.");var l=_.getArg(o,"offset"),u=_.getArg(l,"line"),a=_.getArg(l,"column");if(u<i.line||u===i.line&&a<i.column)throw new Error("Section offsets must be ordered and non-overlapping.");return i=l,{generatedOffset:{generatedLine:u+1,generatedColumn:a+1},consumer:new O(_.getArg(o,"map"),e)}})}Z.prototype=Object.create(O.prototype);Z.prototype.constructor=O;Z.prototype._version=3;Object.defineProperty(Z.prototype,"sources",{get:function(){for(var n=[],e=0;e<this._sections.length;e++)for(var t=0;t<this._sections[e].consumer.sources.length;t++)n.push(this._sections[e].consumer.sources[t]);return n}});Z.prototype.originalPositionFor=function(e){var t={generatedLine:_.getArg(e,"line"),generatedColumn:_.getArg(e,"column")},r=dr.search(t,this._sections,function(i,o){var l=i.generatedLine-o.generatedOffset.generatedLine;return l||i.generatedColumn-o.generatedOffset.generatedColumn}),s=this._sections[r];return s?s.consumer.originalPositionFor({line:t.generatedLine-(s.generatedOffset.generatedLine-1),column:t.generatedColumn-(s.generatedOffset.generatedLine===t.generatedLine?s.generatedOffset.generatedColumn-1:0),bias:e.bias}):{source:null,line:null,column:null,name:null}};Z.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(e){return e.consumer.hasContentsOfAllSources()})};Z.prototype.sourceContentFor=function(e,t){for(var r=0;r<this._sections.length;r++){var s=this._sections[r],i=s.consumer.sourceContentFor(e,!0);if(i||i==="")return i}if(t)return null;throw new Error('"'+e+'" is not in the SourceMap.')};Z.prototype.generatedPositionFor=function(e){for(var t=0;t<this._sections.length;t++){var r=this._sections[t];if(r.consumer._findSourceIndex(_.getArg(e,"source"))!==-1){var s=r.consumer.generatedPositionFor(e);if(s){var i={line:s.line+(r.generatedOffset.generatedLine-1),column:s.column+(r.generatedOffset.generatedLine===s.line?r.generatedOffset.generatedColumn-1:0)};return i}}}return{line:null,column:null}};Z.prototype._parseMappings=function(e,t){this.__generatedMappings=[],this.__originalMappings=[];for(var r=0;r<this._sections.length;r++)for(var s=this._sections[r],i=s.consumer._generatedMappings,o=0;o<i.length;o++){var l=i[o],u=s.consumer._sources.at(l.source);u=_.computeSourceURL(s.consumer.sourceRoot,u,this._sourceMapURL),this._sources.add(u),u=this._sources.indexOf(u);var a=null;l.name&&(a=s.consumer._names.at(l.name),this._names.add(a),a=this._names.indexOf(a));var f={source:u,generatedLine:l.generatedLine+(s.generatedOffset.generatedLine-1),generatedColumn:l.generatedColumn+(s.generatedOffset.generatedLine===l.generatedLine?s.generatedOffset.generatedColumn-1:0),originalLine:l.originalLine,originalColumn:l.originalColumn,name:a};this.__generatedMappings.push(f),typeof f.originalLine=="number"&&this.__originalMappings.push(f)}Ve(this.__generatedMappings,_.compareByGeneratedPositionsDeflated),Ve(this.__originalMappings,_.compareByOriginalPositions)};wt.IndexedSourceMapConsumer=Z});var ys=S(_s=>{var Rl=cr().SourceMapGenerator,St=Ce(),Ml=/(\r?\n)/,Pl=10,Le="$$$isSourceNode$$$";function $(n,e,t,r,s){this.children=[],this.sourceContents={},this.line=n??null,this.column=e??null,this.source=t??null,this.name=s??null,this[Le]=!0,r!=null&&this.add(r)}$.fromStringWithSourceMap=function(e,t,r){var s=new $,i=e.split(Ml),o=0,l=function(){var c=m(),p=m()||"";return c+p;function m(){return o<i.length?i[o++]:void 0}},u=1,a=0,f=null;return t.eachMapping(function(c){if(f!==null)if(u<c.generatedLine)h(f,l()),u++,a=0;else{var p=i[o]||"",m=p.substr(0,c.generatedColumn-a);i[o]=p.substr(c.generatedColumn-a),a=c.generatedColumn,h(f,m),f=c;return}for(;u<c.generatedLine;)s.add(l()),u++;if(a<c.generatedColumn){var p=i[o]||"";s.add(p.substr(0,c.generatedColumn)),i[o]=p.substr(c.generatedColumn),a=c.generatedColumn}f=c},this),o<i.length&&(f&&h(f,l()),s.add(i.splice(o).join(""))),t.sources.forEach(function(c){var p=t.sourceContentFor(c);p!=null&&(r!=null&&(c=St.join(r,c)),s.setSourceContent(c,p))}),s;function h(c,p){if(c===null||c.source===void 0)s.add(p);else{var m=r?St.join(r,c.source):c.source;s.add(new $(c.originalLine,c.originalColumn,m,p,c.name))}}};$.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(t){this.add(t)},this);else if(e[Le]||typeof e=="string")e&&this.children.push(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};$.prototype.prepend=function(e){if(Array.isArray(e))for(var t=e.length-1;t>=0;t--)this.prepend(e[t]);else if(e[Le]||typeof e=="string")this.children.unshift(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};$.prototype.walk=function(e){for(var t,r=0,s=this.children.length;r<s;r++)t=this.children[r],t[Le]?t.walk(e):t!==""&&e(t,{source:this.source,line:this.line,column:this.column,name:this.name})};$.prototype.join=function(e){var t,r,s=this.children.length;if(s>0){for(t=[],r=0;r<s-1;r++)t.push(this.children[r]),t.push(e);t.push(this.children[r]),this.children=t}return this};$.prototype.replaceRight=function(e,t){var r=this.children[this.children.length-1];return r[Le]?r.replaceRight(e,t):typeof r=="string"?this.children[this.children.length-1]=r.replace(e,t):this.children.push("".replace(e,t)),this};$.prototype.setSourceContent=function(e,t){this.sourceContents[St.toSetString(e)]=t};$.prototype.walkSourceContents=function(e){for(var t=0,r=this.children.length;t<r;t++)this.children[t][Le]&&this.children[t].walkSourceContents(e);for(var s=Object.keys(this.sourceContents),t=0,r=s.length;t<r;t++)e(St.fromSetString(s[t]),this.sourceContents[s[t]])};$.prototype.toString=function(){var e="";return this.walk(function(t){e+=t}),e};$.prototype.toStringWithSourceMap=function(e){var t={code:"",line:1,column:0},r=new Rl(e),s=!1,i=null,o=null,l=null,u=null;return this.walk(function(a,f){t.code+=a,f.source!==null&&f.line!==null&&f.column!==null?((i!==f.source||o!==f.line||l!==f.column||u!==f.name)&&r.addMapping({source:f.source,original:{line:f.line,column:f.column},generated:{line:t.line,column:t.column},name:f.name}),i=f.source,o=f.line,l=f.column,u=f.name,s=!0):s&&(r.addMapping({generated:{line:t.line,column:t.column}}),i=null,s=!1);for(var h=0,c=a.length;h<c;h++)a.charCodeAt(h)===Pl?(t.line++,t.column=0,h+1===c?(i=null,s=!1):s&&r.addMapping({source:f.source,original:{line:f.line,column:f.column},generated:{line:t.line,column:t.column},name:f.name})):t.column++}),this.walkSourceContents(function(a,f){r.setSourceContent(a,f)}),{code:t.code,map:r}};_s.SourceNode=$});var mr=S(vt=>{vt.SourceMapGenerator=cr().SourceMapGenerator;vt.SourceMapConsumer=gs().SourceMapConsumer;vt.SourceNode=ys().SourceNode});var Ss=S((Kf,ws)=>{var kl="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",Il=(n,e=21)=>(t=e)=>{let r="",s=t;for(;s--;)r+=n[Math.random()*n.length|0];return r},Bl=(n=21)=>{let e="",t=n;for(;t--;)e+=kl[Math.random()*64|0];return e};ws.exports={nanoid:Bl,customAlphabet:Il}});var Es=S((Zf,bs)=>{"use strict";var{SourceMapConsumer:vs,SourceMapGenerator:xs}=mr(),{existsSync:Fl,readFileSync:Ul}=require("fs"),{dirname:gr,join:Dl}=require("path");function Wl(n){return Buffer?Buffer.from(n,"base64").toString():window.atob(n)}var He=class{constructor(e,t){if(t.map===!1)return;this.loadAnnotation(e),this.inline=this.startWith(this.annotation,"data:");let r=t.map?t.map.prev:void 0,s=this.loadMap(t.from,r);!this.mapFile&&t.from&&(this.mapFile=t.from),this.mapFile&&(this.root=gr(this.mapFile)),s&&(this.text=s)}consumer(){return this.consumerCache||(this.consumerCache=new vs(this.text)),this.consumerCache}decodeInline(e){let t=/^data:application\/json;charset=utf-?8;base64,/,r=/^data:application\/json;base64,/,s=/^data:application\/json;charset=utf-?8,/,i=/^data:application\/json,/;if(s.test(e)||i.test(e))return decodeURIComponent(e.substr(RegExp.lastMatch.length));if(t.test(e)||r.test(e))return Wl(e.substr(RegExp.lastMatch.length));let o=e.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+o)}getAnnotationURL(e){return e.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(e){return typeof e!="object"?!1:typeof e.mappings=="string"||typeof e._mappings=="string"||Array.isArray(e.sections)}loadAnnotation(e){let t=e.match(/\/\*\s*# sourceMappingURL=/gm);if(!t)return;let r=e.lastIndexOf(t.pop()),s=e.indexOf("*/",r);r>-1&&s>-1&&(this.annotation=this.getAnnotationURL(e.substring(r,s)))}loadFile(e){if(this.root=gr(e),Fl(e))return this.mapFile=e,Ul(e,"utf-8").toString().trim()}loadMap(e,t){if(t===!1)return!1;if(t){if(typeof t=="string")return t;if(typeof t=="function"){let r=t(e);if(r){let s=this.loadFile(r);if(!s)throw new Error("Unable to load previous source map: "+r.toString());return s}}else{if(t instanceof vs)return xs.fromSourceMap(t).toString();if(t instanceof xs)return t.toString();if(this.isMap(t))return JSON.stringify(t);throw new Error("Unsupported previous source map format: "+t.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let r=this.annotation;return e&&(r=Dl(gr(e),r)),this.loadFile(r)}}}startWith(e,t){return e?e.substr(0,t.length)===t:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}};bs.exports=He;He.default=He});var As=S((Xf,Ts)=>{"use strict";var{SourceMapConsumer:jl,SourceMapGenerator:$l}=mr(),{fileURLToPath:Cs,pathToFileURL:xt}=require("url"),{isAbsolute:wr,resolve:Sr}=require("path"),{nanoid:ql}=Ss(),_r=Ht(),Os=Yt(),Gl=Es(),yr=Symbol("fromOffsetCache"),zl=!!(jl&&$l),Ls=!!(Sr&&wr),Te=class{constructor(e,t={}){if(e===null||typeof e>"u"||typeof e=="object"&&!e.toString)throw new Error(`PostCSS received ${e} instead of CSS string`);if(this.css=e.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,t.from&&(!Ls||/^\w+:\/\//.test(t.from)||wr(t.from)?this.file=t.from:this.file=Sr(t.from)),Ls&&zl){let r=new Gl(this.css,t);if(r.text){this.map=r;let s=r.consumer().file;!this.file&&s&&(this.file=this.mapResolve(s))}}this.file||(this.id="<input css "+ql(6)+">"),this.map&&(this.map.file=this.from)}error(e,t,r,s={}){let i,o,l;if(t&&typeof t=="object"){let a=t,f=r;if(typeof a.offset=="number"){let h=this.fromOffset(a.offset);t=h.line,r=h.col}else t=a.line,r=a.column;if(typeof f.offset=="number"){let h=this.fromOffset(f.offset);o=h.line,l=h.col}else o=f.line,l=f.column}else if(!r){let a=this.fromOffset(t);t=a.line,r=a.col}let u=this.origin(t,r,o,l);return u?i=new Os(e,u.endLine===void 0?u.line:{column:u.column,line:u.line},u.endLine===void 0?u.column:{column:u.endColumn,line:u.endLine},u.source,u.file,s.plugin):i=new Os(e,o===void 0?t:{column:r,line:t},o===void 0?r:{column:l,line:o},this.css,this.file,s.plugin),i.input={column:r,endColumn:l,endLine:o,line:t,source:this.css},this.file&&(xt&&(i.input.url=xt(this.file).toString()),i.input.file=this.file),i}fromOffset(e){let t,r;if(this[yr])r=this[yr];else{let i=this.css.split(`
|
|
22
|
-
`);r=new Array(i.length);let o=0;for(let l=0,u=i.length;l<u;l++)r[l]=o,o+=i[l].length+1;this[yr]=r}t=r[r.length-1];let s=0;if(e>=t)s=r.length-1;else{let i=r.length-2,o;for(;s<i;)if(o=s+(i-s>>1),e<r[o])i=o-1;else if(e>=r[o+1])s=o+1;else{s=o;break}}return{col:e-r[s]+1,line:s+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:Sr(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,r,s){if(!this.map)return!1;let i=this.map.consumer(),o=i.originalPositionFor({column:t,line:e});if(!o.source)return!1;let l;typeof r=="number"&&(l=i.originalPositionFor({column:s,line:r}));let u;wr(o.source)?u=xt(o.source):u=new URL(o.source,this.map.consumer().sourceRoot||xt(this.map.mapFile));let a={column:o.column,endColumn:l&&l.column,endLine:l&&l.line,line:o.line,url:u.toString()};if(u.protocol==="file:")if(Cs)a.file=Cs(u);else throw new Error("file: protocol is not available in this PostCSS build");let f=i.sourceContentFor(o.source);return f&&(a.source=f),a}toJSON(){let e={};for(let t of["hasBOM","css","file","id"])this[t]!=null&&(e[t]=this[t]);return this.map&&(e.map={...this.map},e.map.consumerCache&&(e.map.consumerCache=void 0)),e}get from(){return this.file||this.id}};Ts.exports=Te;Te.default=Te;_r&&_r.registerInput&&_r.registerInput(Te)});var
|
|
19
|
+
`);return t=i[i.length-1],t=t.replace(/\S/g,""),!1}}),t}rawSemicolon(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length&&r.last.type==="decl"&&(t=r.raws.semicolon,typeof t<"u"))return!1}),t}rawValue(e,t){let r=e[t],s=e.raws[t];return s&&s.value===r?s.raw:r}root(e){this.body(e),e.raws.after&&this.builder(e.raws.after)}rule(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")}stringify(e,t){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,t)}};gn.exports=Ue;Ue.default=Ue});var yn=S((Nf,_n)=>{"use strict";var Jo=Jt();function Qt(n,e){new Jo(e).stringify(n)}_n.exports=Qt;Qt.default=Qt});var gt=S((Mf,wn)=>{"use strict";var{isClean:mt,my:Qo}=qt(),Ko=Yt(),Zo=Jt(),Xo=yn();function Kt(n,e){let t=new n.constructor;for(let r in n){if(!Object.prototype.hasOwnProperty.call(n,r)||r==="proxyCache")continue;let s=n[r],i=typeof s;r==="parent"&&i==="object"?e&&(t[r]=e):r==="source"?t[r]=s:Array.isArray(s)?t[r]=s.map(o=>Kt(o,t)):(i==="object"&&s!==null&&(s=Kt(s)),t[r]=s)}return t}var De=class{constructor(e={}){this.raws={},this[mt]=!1,this[Qo]=!0;for(let t in e)if(t==="nodes"){this.nodes=[];for(let r of e[t])typeof r.clone=="function"?this.append(r.clone()):this.append(r)}else this[t]=e[t]}addToError(e){if(e.postcssNode=this,e.stack&&this.source&&/\n\s{4}at /.test(e.stack)){let t=this.source;e.stack=e.stack.replace(/\n\s{4}at /,`$&${t.input.from}:${t.start.line}:${t.start.column}$&`)}return e}after(e){return this.parent.insertAfter(this,e),this}assign(e={}){for(let t in e)this[t]=e[t];return this}before(e){return this.parent.insertBefore(this,e),this}cleanRaws(e){delete this.raws.before,delete this.raws.after,e||delete this.raws.between}clone(e={}){let t=Kt(this);for(let r in e)t[r]=e[r];return t}cloneAfter(e={}){let t=this.clone(e);return this.parent.insertAfter(this,t),t}cloneBefore(e={}){let t=this.clone(e);return this.parent.insertBefore(this,t),t}error(e,t={}){if(this.source){let{end:r,start:s}=this.rangeBy(t);return this.source.input.error(e,{column:s.column,line:s.line},{column:r.column,line:r.line},t)}return new Ko(e)}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:t==="root"?()=>e.root().toProxy():e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="prop"||t==="value"||t==="name"||t==="params"||t==="important"||t==="text")&&e.markDirty()),!0}}}markDirty(){if(this[mt]){this[mt]=!1;let e=this;for(;e=e.parent;)e[mt]=!1}}next(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e+1]}positionBy(e,t){let r=this.source.start;if(e.index)r=this.positionInside(e.index,t);else if(e.word){t=this.toString();let s=t.indexOf(e.word);s!==-1&&(r=this.positionInside(s,t))}return r}positionInside(e,t){let r=t||this.toString(),s=this.source.start.column,i=this.source.start.line;for(let o=0;o<e;o++)r[o]===`
|
|
20
|
+
`?(s=1,i+=1):s+=1;return{column:s,line:i}}prev(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e-1]}rangeBy(e){let t={column:this.source.start.column,line:this.source.start.line},r=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:t.column+1,line:t.line};if(e.word){let s=this.toString(),i=s.indexOf(e.word);i!==-1&&(t=this.positionInside(i,s),r=this.positionInside(i+e.word.length,s))}else e.start?t={column:e.start.column,line:e.start.line}:e.index&&(t=this.positionInside(e.index)),e.end?r={column:e.end.column,line:e.end.line}:typeof e.endIndex=="number"?r=this.positionInside(e.endIndex):e.index&&(r=this.positionInside(e.index+1));return(r.line<t.line||r.line===t.line&&r.column<=t.column)&&(r={column:t.column+1,line:t.line}),{end:r,start:t}}raw(e,t){return new Zo().raw(this,e,t)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...e){if(this.parent){let t=this,r=!1;for(let s of e)s===this?r=!0:r?(this.parent.insertAfter(t,s),t=s):this.parent.insertBefore(t,s);r||this.remove()}return this}root(){let e=this;for(;e.parent&&e.parent.type!=="document";)e=e.parent;return e}toJSON(e,t){let r={},s=t==null;t=t||new Map;let i=0;for(let o in this){if(!Object.prototype.hasOwnProperty.call(this,o)||o==="parent"||o==="proxyCache")continue;let l=this[o];if(Array.isArray(l))r[o]=l.map(u=>typeof u=="object"&&u.toJSON?u.toJSON(null,t):u);else if(typeof l=="object"&&l.toJSON)r[o]=l.toJSON(null,t);else if(o==="source"){let u=t.get(l.input);u==null&&(u=i,t.set(l.input,i),i++),r[o]={end:l.end,inputId:u,start:l.start}}else r[o]=l}return s&&(r.inputs=[...t.keys()].map(o=>o.toJSON())),r}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(e=Xo){e.stringify&&(e=e.stringify);let t="";return e(this,r=>{t+=r}),t}warn(e,t,r){let s={node:this};for(let i in r)s[i]=r[i];return e.warn(t,s)}get proxyOf(){return this}};wn.exports=De;De.default=De});var Zt=S((Rf,Sn)=>{"use strict";var el=gt(),We=class extends el{constructor(e){e&&typeof e.value<"u"&&typeof e.value!="string"&&(e={...e,value:String(e.value)}),super(e),this.type="decl"}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}};Sn.exports=We;We.default=We});var Xt=S((Pf,vn)=>{"use strict";var tl=gt(),je=class extends tl{constructor(e){super(e),this.type="comment"}};vn.exports=je;je.default=je});var $e=S((kf,Nn)=>{"use strict";var{isClean:xn,my:bn}=qt(),En=Zt(),Cn=Xt(),rl=gt(),On,er,tr,Ln;function Tn(n){return n.map(e=>(e.nodes&&(e.nodes=Tn(e.nodes)),delete e.source,e))}function An(n){if(n[xn]=!1,n.proxyOf.nodes)for(let e of n.proxyOf.nodes)An(e)}var K=class n extends rl{append(...e){for(let t of e){let r=this.normalize(t,this.last);for(let s of r)this.proxyOf.nodes.push(s)}return this.markDirty(),this}cleanRaws(e){if(super.cleanRaws(e),this.nodes)for(let t of this.nodes)t.cleanRaws(e)}each(e){if(!this.proxyOf.nodes)return;let t=this.getIterator(),r,s;for(;this.indexes[t]<this.proxyOf.nodes.length&&(r=this.indexes[t],s=e(this.proxyOf.nodes[r],r),s!==!1);)this.indexes[t]+=1;return delete this.indexes[t],s}every(e){return this.nodes.every(e)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let e=this.lastEach;return this.indexes[e]=0,e}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:e[t]?t==="each"||typeof t=="string"&&t.startsWith("walk")?(...r)=>e[t](...r.map(s=>typeof s=="function"?(i,o)=>s(i.toProxy(),o):s)):t==="every"||t==="some"?r=>e[t]((s,...i)=>r(s.toProxy(),...i)):t==="root"?()=>e.root().toProxy():t==="nodes"?e.nodes.map(r=>r.toProxy()):t==="first"||t==="last"?e[t].toProxy():e[t]:e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="name"||t==="params"||t==="selector")&&e.markDirty()),!0}}}index(e){return typeof e=="number"?e:(e.proxyOf&&(e=e.proxyOf),this.proxyOf.nodes.indexOf(e))}insertAfter(e,t){let r=this.index(e),s=this.normalize(t,this.proxyOf.nodes[r]).reverse();r=this.index(e);for(let o of s)this.proxyOf.nodes.splice(r+1,0,o);let i;for(let o in this.indexes)i=this.indexes[o],r<i&&(this.indexes[o]=i+s.length);return this.markDirty(),this}insertBefore(e,t){let r=this.index(e),s=r===0?"prepend":!1,i=this.normalize(t,this.proxyOf.nodes[r],s).reverse();r=this.index(e);for(let l of i)this.proxyOf.nodes.splice(r,0,l);let o;for(let l in this.indexes)o=this.indexes[l],r<=o&&(this.indexes[l]=o+i.length);return this.markDirty(),this}normalize(e,t){if(typeof e=="string")e=Tn(On(e).nodes);else if(typeof e>"u")e=[];else if(Array.isArray(e)){e=e.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type)e=[e];else if(e.prop){if(typeof e.value>"u")throw new Error("Value field is missed in node creation");typeof e.value!="string"&&(e.value=String(e.value)),e=[new En(e)]}else if(e.selector||e.selectors)e=[new er(e)];else if(e.name)e=[new tr(e)];else if(e.text)e=[new Cn(e)];else throw new Error("Unknown node type in node creation");return e.map(s=>(s[bn]||n.rebuild(s),s=s.proxyOf,s.parent&&s.parent.removeChild(s),s[xn]&&An(s),typeof s.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(s.raws.before=t.raws.before.replace(/\S/g,"")),s.parent=this.proxyOf,s))}prepend(...e){e=e.reverse();for(let t of e){let r=this.normalize(t,this.first,"prepend").reverse();for(let s of r)this.proxyOf.nodes.unshift(s);for(let s in this.indexes)this.indexes[s]=this.indexes[s]+r.length}return this.markDirty(),this}push(e){return e.parent=this,this.proxyOf.nodes.push(e),this}removeAll(){for(let e of this.proxyOf.nodes)e.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(e){e=this.index(e),this.proxyOf.nodes[e].parent=void 0,this.proxyOf.nodes.splice(e,1);let t;for(let r in this.indexes)t=this.indexes[r],t>=e&&(this.indexes[r]=t-1);return this.markDirty(),this}replaceValues(e,t,r){return r||(r=t,t={}),this.walkDecls(s=>{t.props&&!t.props.includes(s.prop)||t.fast&&!s.value.includes(t.fast)||(s.value=s.value.replace(e,r))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,r)=>{let s;try{s=e(t,r)}catch(i){throw t.addToError(i)}return s!==!1&&t.walk&&(s=t.walk(e)),s})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="atrule"&&e.test(r.name))return t(r,s)}):this.walk((r,s)=>{if(r.type==="atrule"&&r.name===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="atrule")return t(r,s)}))}walkComments(e){return this.walk((t,r)=>{if(t.type==="comment")return e(t,r)})}walkDecls(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="decl"&&e.test(r.prop))return t(r,s)}):this.walk((r,s)=>{if(r.type==="decl"&&r.prop===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="decl")return t(r,s)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="rule"&&e.test(r.selector))return t(r,s)}):this.walk((r,s)=>{if(r.type==="rule"&&r.selector===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="rule")return t(r,s)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}};K.registerParse=n=>{On=n};K.registerRule=n=>{er=n};K.registerAtRule=n=>{tr=n};K.registerRoot=n=>{Ln=n};Nn.exports=K;K.default=K;K.rebuild=n=>{n.type==="atrule"?Object.setPrototypeOf(n,tr.prototype):n.type==="rule"?Object.setPrototypeOf(n,er.prototype):n.type==="decl"?Object.setPrototypeOf(n,En.prototype):n.type==="comment"?Object.setPrototypeOf(n,Cn.prototype):n.type==="root"&&Object.setPrototypeOf(n,Ln.prototype),n[bn]=!0,n.nodes&&n.nodes.forEach(e=>{K.rebuild(e)})}});var Pn=S((If,Rn)=>{"use strict";var Mn=$e(),xe=class extends Mn{constructor(e){super(e),this.type="atrule"}append(...e){return this.proxyOf.nodes||(this.nodes=[]),super.append(...e)}prepend(...e){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...e)}};Rn.exports=xe;xe.default=xe;Mn.registerAtRule(xe)});var Un=S((Bf,Fn)=>{"use strict";var kn=$e(),In,Bn,ue=class extends kn{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,r){let s=super.normalize(e);if(t){if(r==="prepend")this.nodes.length>1?t.raws.before=this.nodes[1].raws.before:delete t.raws.before;else if(this.first!==t)for(let i of s)i.raws.before=t.raws.before}return s}removeChild(e,t){let r=this.index(e);return!t&&r===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[r].raws.before),super.removeChild(e)}toResult(e={}){return new In(new Bn,this,e).stringify()}};ue.registerLazyResult=n=>{In=n};ue.registerProcessor=n=>{Bn=n};Fn.exports=ue;ue.default=ue;kn.registerRoot(ue)});var Wn=S((Ff,Dn)=>{"use strict";var qe={comma(n){return qe.split(n,[","],!0)},space(n){let e=[" ",`
|
|
21
|
+
`," "];return qe.split(n,e)},split(n,e,t){let r=[],s="",i=!1,o=0,l=!1,u="",a=!1;for(let f of n)a?a=!1:f==="\\"?a=!0:l?f===u&&(l=!1):f==='"'||f==="'"?(l=!0,u=f):f==="("?o+=1:f===")"?o>0&&(o-=1):o===0&&e.includes(f)&&(i=!0),i?(s!==""&&r.push(s.trim()),s="",i=!1):s+=f;return(t||s!=="")&&r.push(s.trim()),r}};Dn.exports=qe;qe.default=qe});var qn=S((Uf,$n)=>{"use strict";var jn=$e(),nl=Wn(),be=class extends jn{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return nl.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,r=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(r)}};$n.exports=be;be.default=be;jn.registerRule(be)});var Hn=S((Df,Vn)=>{"use strict";var sl=Zt(),il=Vt(),ol=Xt(),ll=Pn(),al=Un(),Gn=qn(),zn={empty:!0,space:!0};function ul(n){for(let e=n.length-1;e>=0;e--){let t=n[e],r=t[3]||t[2];if(r)return r}}var rr=class{constructor(e){this.input=e,this.root=new al,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new ll;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let r,s,i,o=!1,l=!1,u=[],a=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),r=e[0],r==="("||r==="["?a.push(r==="("?")":"]"):r==="{"&&a.length>0?a.push("}"):r===a[a.length-1]&&a.pop(),a.length===0)if(r===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(r==="{"){l=!0;break}else if(r==="}"){if(u.length>0){for(i=u.length-1,s=u[i];s&&s[0]==="space";)s=u[--i];s&&(t.source.end=this.getPosition(s[3]||s[2]),t.source.end.offset++)}this.end(e);break}else u.push(e);else u.push(e);if(this.tokenizer.endOfFile()){o=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(u),u.length?(t.raws.afterName=this.spacesAndCommentsFromStart(u),this.raw(t,"params",u),o&&(e=u[u.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),l&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let r=0,s;for(let i=t-1;i>=0&&(s=e[i],!(s[0]!=="space"&&(r+=1,r===2)));i--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}colon(e){let t=0,r,s,i;for(let[o,l]of e.entries()){if(r=l,s=r[0],s==="("&&(t+=1),s===")"&&(t-=1),t===0&&s===":")if(!i)this.doubleColon(r);else{if(i[0]==="word"&&i[1]==="progid")continue;return o}i=r}return!1}comment(e){let t=new ol;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let r=e[1].slice(2,-2);if(/^\s*$/.test(r))t.text="",t.raws.left=r,t.raws.right="";else{let s=r.match(/^(\s*)([^]*\S)(\s*)$/);t.text=s[2],t.raws.left=s[1],t.raws.right=s[3]}}createTokenizer(){this.tokenizer=il(this.input)}decl(e,t){let r=new sl;this.init(r,e[0][2]);let s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),r.source.end=this.getPosition(s[3]||s[2]||ul(e)),r.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),r.raws.before+=e.shift()[1];for(r.source.start=this.getPosition(e[0][2]),r.prop="";e.length;){let a=e[0][0];if(a===":"||a==="space"||a==="comment")break;r.prop+=e.shift()[1]}r.raws.between="";let i;for(;e.length;)if(i=e.shift(),i[0]===":"){r.raws.between+=i[1];break}else i[0]==="word"&&/\w/.test(i[1])&&this.unknownWord([i]),r.raws.between+=i[1];(r.prop[0]==="_"||r.prop[0]==="*")&&(r.raws.before+=r.prop[0],r.prop=r.prop.slice(1));let o=[],l;for(;e.length&&(l=e[0][0],!(l!=="space"&&l!=="comment"));)o.push(e.shift());this.precheckMissedSemicolon(e);for(let a=e.length-1;a>=0;a--){if(i=e[a],i[1].toLowerCase()==="!important"){r.important=!0;let f=this.stringFrom(e,a);f=this.spacesFromEnd(e)+f,f!==" !important"&&(r.raws.important=f);break}else if(i[1].toLowerCase()==="important"){let f=e.slice(0),h="";for(let c=a;c>0;c--){let p=f[c][0];if(h.trim().indexOf("!")===0&&p!=="space")break;h=f.pop()[1]+h}h.trim().indexOf("!")===0&&(r.important=!0,r.raws.important=h,e=f)}if(i[0]!=="space"&&i[0]!=="comment")break}e.some(a=>a[0]!=="space"&&a[0]!=="comment")&&(r.raws.between+=o.map(a=>a[1]).join(""),o=[]),this.raw(r,"value",o.concat(e),t),r.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new Gn;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,r=null,s=!1,i=null,o=[],l=e[1].startsWith("--"),u=[],a=e;for(;a;){if(r=a[0],u.push(a),r==="("||r==="[")i||(i=a),o.push(r==="("?")":"]");else if(l&&s&&r==="{")i||(i=a),o.push("}");else if(o.length===0)if(r===";")if(s){this.decl(u,l);return}else break;else if(r==="{"){this.rule(u);return}else if(r==="}"){this.tokenizer.back(u.pop()),t=!0;break}else r===":"&&(s=!0);else r===o[o.length-1]&&(o.pop(),o.length===0&&(i=null));a=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),o.length>0&&this.unclosedBracket(i),t&&s){if(!l)for(;u.length&&(a=u[u.length-1][0],!(a!=="space"&&a!=="comment"));)this.tokenizer.back(u.pop());this.decl(u,l)}else this.unknownWord(u)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,r,s){let i,o,l=r.length,u="",a=!0,f,h;for(let c=0;c<l;c+=1)i=r[c],o=i[0],o==="space"&&c===l-1&&!s?a=!1:o==="comment"?(h=r[c-1]?r[c-1][0]:"empty",f=r[c+1]?r[c+1][0]:"empty",!zn[h]&&!zn[f]?u.slice(-1)===","?a=!1:u+=i[1]:a=!1):u+=i[1];if(!a){let c=r.reduce((p,m)=>p+m[1],"");e.raws[t]={raw:c,value:u}}e[t]=u}rule(e){e.pop();let t=new Gn;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)r=e.pop()[1]+r;return r}spacesAndCommentsFromStart(e){let t,r="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)r+=e.shift()[1];return r}spacesFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],t==="space");)r=e.pop()[1]+r;return r}stringFrom(e,t){let r="";for(let s=t;s<e.length;s++)r+=e[s][1];return e.splice(t,e.length-t),r}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}};Vn.exports=rr});var Jn=S(nr=>{var Yn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");nr.encode=function(n){if(0<=n&&n<Yn.length)return Yn[n];throw new TypeError("Must be between 0 and 63: "+n)};nr.decode=function(n){var e=65,t=90,r=97,s=122,i=48,o=57,l=43,u=47,a=26,f=52;return e<=n&&n<=t?n-e:r<=n&&n<=s?n-r+a:i<=n&&n<=o?n-i+f:n==l?62:n==u?63:-1}});var or=S(ir=>{var Qn=Jn(),sr=5,Kn=1<<sr,Zn=Kn-1,Xn=Kn;function fl(n){return n<0?(-n<<1)+1:(n<<1)+0}function cl(n){var e=(n&1)===1,t=n>>1;return e?-t:t}ir.encode=function(e){var t="",r,s=fl(e);do r=s&Zn,s>>>=sr,s>0&&(r|=Xn),t+=Qn.encode(r);while(s>0);return t};ir.decode=function(e,t,r){var s=e.length,i=0,o=0,l,u;do{if(t>=s)throw new Error("Expected more digits in base 64 VLQ value.");if(u=Qn.decode(e.charCodeAt(t++)),u===-1)throw new Error("Invalid base64 digit: "+e.charAt(t-1));l=!!(u&Xn),u&=Zn,i=i+(u<<o),o+=sr}while(l);r.value=cl(i),r.rest=t}});var Ce=S(k=>{function hl(n,e,t){if(e in n)return n[e];if(arguments.length===3)return t;throw new Error('"'+e+'" is a required argument.')}k.getArg=hl;var es=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,pl=/^data:.+\,.+$/;function Ge(n){var e=n.match(es);return e?{scheme:e[1],auth:e[2],host:e[3],port:e[4],path:e[5]}:null}k.urlParse=Ge;function Ee(n){var e="";return n.scheme&&(e+=n.scheme+":"),e+="//",n.auth&&(e+=n.auth+"@"),n.host&&(e+=n.host),n.port&&(e+=":"+n.port),n.path&&(e+=n.path),e}k.urlGenerate=Ee;var dl=32;function ml(n){var e=[];return function(t){for(var r=0;r<e.length;r++)if(e[r].input===t){var s=e[0];return e[0]=e[r],e[r]=s,e[0].result}var i=n(t);return e.unshift({input:t,result:i}),e.length>dl&&e.pop(),i}}var lr=ml(function(e){var t=e,r=Ge(e);if(r){if(!r.path)return e;t=r.path}for(var s=k.isAbsolute(t),i=[],o=0,l=0;;)if(o=l,l=t.indexOf("/",o),l===-1){i.push(t.slice(o));break}else for(i.push(t.slice(o,l));l<t.length&&t[l]==="/";)l++;for(var u,a=0,l=i.length-1;l>=0;l--)u=i[l],u==="."?i.splice(l,1):u===".."?a++:a>0&&(u===""?(i.splice(l+1,a),a=0):(i.splice(l,2),a--));return t=i.join("/"),t===""&&(t=s?"/":"."),r?(r.path=t,Ee(r)):t});k.normalize=lr;function ts(n,e){n===""&&(n="."),e===""&&(e=".");var t=Ge(e),r=Ge(n);if(r&&(n=r.path||"/"),t&&!t.scheme)return r&&(t.scheme=r.scheme),Ee(t);if(t||e.match(pl))return e;if(r&&!r.host&&!r.path)return r.host=e,Ee(r);var s=e.charAt(0)==="/"?e:lr(n.replace(/\/+$/,"")+"/"+e);return r?(r.path=s,Ee(r)):s}k.join=ts;k.isAbsolute=function(n){return n.charAt(0)==="/"||es.test(n)};function gl(n,e){n===""&&(n="."),n=n.replace(/\/$/,"");for(var t=0;e.indexOf(n+"/")!==0;){var r=n.lastIndexOf("/");if(r<0||(n=n.slice(0,r),n.match(/^([^\/]+:\/)?\/*$/)))return e;++t}return Array(t+1).join("../")+e.substr(n.length+1)}k.relative=gl;var rs=function(){var n=Object.create(null);return!("__proto__"in n)}();function ns(n){return n}function _l(n){return ss(n)?"$"+n:n}k.toSetString=rs?ns:_l;function yl(n){return ss(n)?n.slice(1):n}k.fromSetString=rs?ns:yl;function ss(n){if(!n)return!1;var e=n.length;if(e<9||n.charCodeAt(e-1)!==95||n.charCodeAt(e-2)!==95||n.charCodeAt(e-3)!==111||n.charCodeAt(e-4)!==116||n.charCodeAt(e-5)!==111||n.charCodeAt(e-6)!==114||n.charCodeAt(e-7)!==112||n.charCodeAt(e-8)!==95||n.charCodeAt(e-9)!==95)return!1;for(var t=e-10;t>=0;t--)if(n.charCodeAt(t)!==36)return!1;return!0}function wl(n,e,t){var r=re(n.source,e.source);return r!==0||(r=n.originalLine-e.originalLine,r!==0)||(r=n.originalColumn-e.originalColumn,r!==0||t)||(r=n.generatedColumn-e.generatedColumn,r!==0)||(r=n.generatedLine-e.generatedLine,r!==0)?r:re(n.name,e.name)}k.compareByOriginalPositions=wl;function Sl(n,e,t){var r;return r=n.originalLine-e.originalLine,r!==0||(r=n.originalColumn-e.originalColumn,r!==0||t)||(r=n.generatedColumn-e.generatedColumn,r!==0)||(r=n.generatedLine-e.generatedLine,r!==0)?r:re(n.name,e.name)}k.compareByOriginalPositionsNoSource=Sl;function vl(n,e,t){var r=n.generatedLine-e.generatedLine;return r!==0||(r=n.generatedColumn-e.generatedColumn,r!==0||t)||(r=re(n.source,e.source),r!==0)||(r=n.originalLine-e.originalLine,r!==0)||(r=n.originalColumn-e.originalColumn,r!==0)?r:re(n.name,e.name)}k.compareByGeneratedPositionsDeflated=vl;function xl(n,e,t){var r=n.generatedColumn-e.generatedColumn;return r!==0||t||(r=re(n.source,e.source),r!==0)||(r=n.originalLine-e.originalLine,r!==0)||(r=n.originalColumn-e.originalColumn,r!==0)?r:re(n.name,e.name)}k.compareByGeneratedPositionsDeflatedNoLine=xl;function re(n,e){return n===e?0:n===null?1:e===null?-1:n>e?1:-1}function bl(n,e){var t=n.generatedLine-e.generatedLine;return t!==0||(t=n.generatedColumn-e.generatedColumn,t!==0)||(t=re(n.source,e.source),t!==0)||(t=n.originalLine-e.originalLine,t!==0)||(t=n.originalColumn-e.originalColumn,t!==0)?t:re(n.name,e.name)}k.compareByGeneratedPositionsInflated=bl;function El(n){return JSON.parse(n.replace(/^\)]}'[^\n]*\n/,""))}k.parseSourceMapInput=El;function Cl(n,e,t){if(e=e||"",n&&(n[n.length-1]!=="/"&&e[0]!=="/"&&(n+="/"),e=n+e),t){var r=Ge(t);if(!r)throw new Error("sourceMapURL could not be parsed");if(r.path){var s=r.path.lastIndexOf("/");s>=0&&(r.path=r.path.substring(0,s+1))}e=ts(Ee(r),e)}return lr(e)}k.computeSourceURL=Cl});var fr=S(is=>{var ar=Ce(),ur=Object.prototype.hasOwnProperty,de=typeof Map<"u";function ne(){this._array=[],this._set=de?new Map:Object.create(null)}ne.fromArray=function(e,t){for(var r=new ne,s=0,i=e.length;s<i;s++)r.add(e[s],t);return r};ne.prototype.size=function(){return de?this._set.size:Object.getOwnPropertyNames(this._set).length};ne.prototype.add=function(e,t){var r=de?e:ar.toSetString(e),s=de?this.has(e):ur.call(this._set,r),i=this._array.length;(!s||t)&&this._array.push(e),s||(de?this._set.set(e,i):this._set[r]=i)};ne.prototype.has=function(e){if(de)return this._set.has(e);var t=ar.toSetString(e);return ur.call(this._set,t)};ne.prototype.indexOf=function(e){if(de){var t=this._set.get(e);if(t>=0)return t}else{var r=ar.toSetString(e);if(ur.call(this._set,r))return this._set[r]}throw new Error('"'+e+'" is not in the set.')};ne.prototype.at=function(e){if(e>=0&&e<this._array.length)return this._array[e];throw new Error("No element indexed by "+e)};ne.prototype.toArray=function(){return this._array.slice()};is.ArraySet=ne});var as=S(ls=>{var os=Ce();function Ol(n,e){var t=n.generatedLine,r=e.generatedLine,s=n.generatedColumn,i=e.generatedColumn;return r>t||r==t&&i>=s||os.compareByGeneratedPositionsInflated(n,e)<=0}function _t(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}_t.prototype.unsortedForEach=function(e,t){this._array.forEach(e,t)};_t.prototype.add=function(e){Ol(this._last,e)?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))};_t.prototype.toArray=function(){return this._sorted||(this._array.sort(os.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};ls.MappingList=_t});var cr=S(us=>{var ze=or(),M=Ce(),yt=fr().ArraySet,Ll=as().MappingList;function z(n){n||(n={}),this._file=M.getArg(n,"file",null),this._sourceRoot=M.getArg(n,"sourceRoot",null),this._skipValidation=M.getArg(n,"skipValidation",!1),this._ignoreInvalidMapping=M.getArg(n,"ignoreInvalidMapping",!1),this._sources=new yt,this._names=new yt,this._mappings=new Ll,this._sourcesContents=null}z.prototype._version=3;z.fromSourceMap=function(e,t){var r=e.sourceRoot,s=new z(Object.assign(t||{},{file:e.file,sourceRoot:r}));return e.eachMapping(function(i){var o={generated:{line:i.generatedLine,column:i.generatedColumn}};i.source!=null&&(o.source=i.source,r!=null&&(o.source=M.relative(r,o.source)),o.original={line:i.originalLine,column:i.originalColumn},i.name!=null&&(o.name=i.name)),s.addMapping(o)}),e.sources.forEach(function(i){var o=i;r!==null&&(o=M.relative(r,i)),s._sources.has(o)||s._sources.add(o);var l=e.sourceContentFor(i);l!=null&&s.setSourceContent(i,l)}),s};z.prototype.addMapping=function(e){var t=M.getArg(e,"generated"),r=M.getArg(e,"original",null),s=M.getArg(e,"source",null),i=M.getArg(e,"name",null);!this._skipValidation&&this._validateMapping(t,r,s,i)===!1||(s!=null&&(s=String(s),this._sources.has(s)||this._sources.add(s)),i!=null&&(i=String(i),this._names.has(i)||this._names.add(i)),this._mappings.add({generatedLine:t.line,generatedColumn:t.column,originalLine:r!=null&&r.line,originalColumn:r!=null&&r.column,source:s,name:i}))};z.prototype.setSourceContent=function(e,t){var r=e;this._sourceRoot!=null&&(r=M.relative(this._sourceRoot,r)),t!=null?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[M.toSetString(r)]=t):this._sourcesContents&&(delete this._sourcesContents[M.toSetString(r)],Object.keys(this._sourcesContents).length===0&&(this._sourcesContents=null))};z.prototype.applySourceMap=function(e,t,r){var s=t;if(t==null){if(e.file==null)throw new Error(`SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map's "file" property. Both were omitted.`);s=e.file}var i=this._sourceRoot;i!=null&&(s=M.relative(i,s));var o=new yt,l=new yt;this._mappings.unsortedForEach(function(u){if(u.source===s&&u.originalLine!=null){var a=e.originalPositionFor({line:u.originalLine,column:u.originalColumn});a.source!=null&&(u.source=a.source,r!=null&&(u.source=M.join(r,u.source)),i!=null&&(u.source=M.relative(i,u.source)),u.originalLine=a.line,u.originalColumn=a.column,a.name!=null&&(u.name=a.name))}var f=u.source;f!=null&&!o.has(f)&&o.add(f);var h=u.name;h!=null&&!l.has(h)&&l.add(h)},this),this._sources=o,this._names=l,e.sources.forEach(function(u){var a=e.sourceContentFor(u);a!=null&&(r!=null&&(u=M.join(r,u)),i!=null&&(u=M.relative(i,u)),this.setSourceContent(u,a))},this)};z.prototype._validateMapping=function(e,t,r,s){if(t&&typeof t.line!="number"&&typeof t.column!="number"){var i="original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.";if(this._ignoreInvalidMapping)return typeof console<"u"&&console.warn&&console.warn(i),!1;throw new Error(i)}if(!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0&&!t&&!r&&!s)){if(e&&"line"in e&&"column"in e&&t&&"line"in t&&"column"in t&&e.line>0&&e.column>=0&&t.line>0&&t.column>=0&&r)return;var i="Invalid mapping: "+JSON.stringify({generated:e,source:r,original:t,name:s});if(this._ignoreInvalidMapping)return typeof console<"u"&&console.warn&&console.warn(i),!1;throw new Error(i)}};z.prototype._serializeMappings=function(){for(var e=0,t=1,r=0,s=0,i=0,o=0,l="",u,a,f,h,c=this._mappings.toArray(),p=0,m=c.length;p<m;p++){if(a=c[p],u="",a.generatedLine!==t)for(e=0;a.generatedLine!==t;)u+=";",t++;else if(p>0){if(!M.compareByGeneratedPositionsInflated(a,c[p-1]))continue;u+=","}u+=ze.encode(a.generatedColumn-e),e=a.generatedColumn,a.source!=null&&(h=this._sources.indexOf(a.source),u+=ze.encode(h-o),o=h,u+=ze.encode(a.originalLine-1-s),s=a.originalLine-1,u+=ze.encode(a.originalColumn-r),r=a.originalColumn,a.name!=null&&(f=this._names.indexOf(a.name),u+=ze.encode(f-i),i=f)),l+=u}return l};z.prototype._generateSourcesContent=function(e,t){return e.map(function(r){if(!this._sourcesContents)return null;t!=null&&(r=M.relative(t,r));var s=M.toSetString(r);return Object.prototype.hasOwnProperty.call(this._sourcesContents,s)?this._sourcesContents[s]:null},this)};z.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(e.file=this._file),this._sourceRoot!=null&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e};z.prototype.toString=function(){return JSON.stringify(this.toJSON())};us.SourceMapGenerator=z});var fs=S(me=>{me.GREATEST_LOWER_BOUND=1;me.LEAST_UPPER_BOUND=2;function hr(n,e,t,r,s,i){var o=Math.floor((e-n)/2)+n,l=s(t,r[o],!0);return l===0?o:l>0?e-o>1?hr(o,e,t,r,s,i):i==me.LEAST_UPPER_BOUND?e<r.length?e:-1:o:o-n>1?hr(n,o,t,r,s,i):i==me.LEAST_UPPER_BOUND?o:n<0?-1:n}me.search=function(e,t,r,s){if(t.length===0)return-1;var i=hr(-1,t.length,e,t,r,s||me.GREATEST_LOWER_BOUND);if(i<0)return-1;for(;i-1>=0&&r(t[i],t[i-1],!0)===0;)--i;return i}});var ps=S(hs=>{function Tl(n){function e(s,i,o){var l=s[i];s[i]=s[o],s[o]=l}function t(s,i){return Math.round(s+Math.random()*(i-s))}function r(s,i,o,l){if(o<l){var u=t(o,l),a=o-1;e(s,u,l);for(var f=s[l],h=o;h<l;h++)i(s[h],f,!1)<=0&&(a+=1,e(s,a,h));e(s,a+1,h);var c=a+1;r(s,i,o,c-1),r(s,i,c+1,l)}}return r}function Al(n){let e=Tl.toString();return new Function(`return ${e}`)()(n)}var cs=new WeakMap;hs.quickSort=function(n,e,t=0){let r=cs.get(e);r===void 0&&(r=Al(e),cs.set(e,r)),r(n,e,t,n.length-1)}});var gs=S(wt=>{var _=Ce(),dr=fs(),Oe=fr().ArraySet,Nl=or(),Ve=ps().quickSort;function O(n,e){var t=n;return typeof n=="string"&&(t=_.parseSourceMapInput(n)),t.sections!=null?new Z(t,e):new B(t,e)}O.fromSourceMap=function(n,e){return B.fromSourceMap(n,e)};O.prototype._version=3;O.prototype.__generatedMappings=null;Object.defineProperty(O.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}});O.prototype.__originalMappings=null;Object.defineProperty(O.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}});O.prototype._charIsMappingSeparator=function(e,t){var r=e.charAt(t);return r===";"||r===","};O.prototype._parseMappings=function(e,t){throw new Error("Subclasses must implement _parseMappings")};O.GENERATED_ORDER=1;O.ORIGINAL_ORDER=2;O.GREATEST_LOWER_BOUND=1;O.LEAST_UPPER_BOUND=2;O.prototype.eachMapping=function(e,t,r){var s=t||null,i=r||O.GENERATED_ORDER,o;switch(i){case O.GENERATED_ORDER:o=this._generatedMappings;break;case O.ORIGINAL_ORDER:o=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}for(var l=this.sourceRoot,u=e.bind(s),a=this._names,f=this._sources,h=this._sourceMapURL,c=0,p=o.length;c<p;c++){var m=o[c],d=m.source===null?null:f.at(m.source);d=_.computeSourceURL(l,d,h),u({source:d,generatedLine:m.generatedLine,generatedColumn:m.generatedColumn,originalLine:m.originalLine,originalColumn:m.originalColumn,name:m.name===null?null:a.at(m.name)})}};O.prototype.allGeneratedPositionsFor=function(e){var t=_.getArg(e,"line"),r={source:_.getArg(e,"source"),originalLine:t,originalColumn:_.getArg(e,"column",0)};if(r.source=this._findSourceIndex(r.source),r.source<0)return[];var s=[],i=this._findMapping(r,this._originalMappings,"originalLine","originalColumn",_.compareByOriginalPositions,dr.LEAST_UPPER_BOUND);if(i>=0){var o=this._originalMappings[i];if(e.column===void 0)for(var l=o.originalLine;o&&o.originalLine===l;)s.push({line:_.getArg(o,"generatedLine",null),column:_.getArg(o,"generatedColumn",null),lastColumn:_.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++i];else for(var u=o.originalColumn;o&&o.originalLine===t&&o.originalColumn==u;)s.push({line:_.getArg(o,"generatedLine",null),column:_.getArg(o,"generatedColumn",null),lastColumn:_.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++i]}return s};wt.SourceMapConsumer=O;function B(n,e){var t=n;typeof n=="string"&&(t=_.parseSourceMapInput(n));var r=_.getArg(t,"version"),s=_.getArg(t,"sources"),i=_.getArg(t,"names",[]),o=_.getArg(t,"sourceRoot",null),l=_.getArg(t,"sourcesContent",null),u=_.getArg(t,"mappings"),a=_.getArg(t,"file",null);if(r!=this._version)throw new Error("Unsupported version: "+r);o&&(o=_.normalize(o)),s=s.map(String).map(_.normalize).map(function(f){return o&&_.isAbsolute(o)&&_.isAbsolute(f)?_.relative(o,f):f}),this._names=Oe.fromArray(i.map(String),!0),this._sources=Oe.fromArray(s,!0),this._absoluteSources=this._sources.toArray().map(function(f){return _.computeSourceURL(o,f,e)}),this.sourceRoot=o,this.sourcesContent=l,this._mappings=u,this._sourceMapURL=e,this.file=a}B.prototype=Object.create(O.prototype);B.prototype.consumer=O;B.prototype._findSourceIndex=function(n){var e=n;if(this.sourceRoot!=null&&(e=_.relative(this.sourceRoot,e)),this._sources.has(e))return this._sources.indexOf(e);var t;for(t=0;t<this._absoluteSources.length;++t)if(this._absoluteSources[t]==n)return t;return-1};B.fromSourceMap=function(e,t){var r=Object.create(B.prototype),s=r._names=Oe.fromArray(e._names.toArray(),!0),i=r._sources=Oe.fromArray(e._sources.toArray(),!0);r.sourceRoot=e._sourceRoot,r.sourcesContent=e._generateSourcesContent(r._sources.toArray(),r.sourceRoot),r.file=e._file,r._sourceMapURL=t,r._absoluteSources=r._sources.toArray().map(function(p){return _.computeSourceURL(r.sourceRoot,p,t)});for(var o=e._mappings.toArray().slice(),l=r.__generatedMappings=[],u=r.__originalMappings=[],a=0,f=o.length;a<f;a++){var h=o[a],c=new ms;c.generatedLine=h.generatedLine,c.generatedColumn=h.generatedColumn,h.source&&(c.source=i.indexOf(h.source),c.originalLine=h.originalLine,c.originalColumn=h.originalColumn,h.name&&(c.name=s.indexOf(h.name)),u.push(c)),l.push(c)}return Ve(r.__originalMappings,_.compareByOriginalPositions),r};B.prototype._version=3;Object.defineProperty(B.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});function ms(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}var pr=_.compareByGeneratedPositionsDeflatedNoLine;function ds(n,e){let t=n.length,r=n.length-e;if(!(r<=1))if(r==2){let s=n[e],i=n[e+1];pr(s,i)>0&&(n[e]=i,n[e+1]=s)}else if(r<20)for(let s=e;s<t;s++)for(let i=s;i>e;i--){let o=n[i-1],l=n[i];if(pr(o,l)<=0)break;n[i-1]=l,n[i]=o}else Ve(n,pr,e)}B.prototype._parseMappings=function(e,t){var r=1,s=0,i=0,o=0,l=0,u=0,a=e.length,f=0,h={},c={},p=[],m=[],d,g,y,w,b;let v=0;for(;f<a;)if(e.charAt(f)===";")r++,f++,s=0,ds(m,v),v=m.length;else if(e.charAt(f)===",")f++;else{for(d=new ms,d.generatedLine=r,w=f;w<a&&!this._charIsMappingSeparator(e,w);w++);for(g=e.slice(f,w),y=[];f<w;)Nl.decode(e,f,c),b=c.value,f=c.rest,y.push(b);if(y.length===2)throw new Error("Found a source, but no line and column");if(y.length===3)throw new Error("Found a source and line, but no column");if(d.generatedColumn=s+y[0],s=d.generatedColumn,y.length>1&&(d.source=l+y[1],l+=y[1],d.originalLine=i+y[2],i=d.originalLine,d.originalLine+=1,d.originalColumn=o+y[3],o=d.originalColumn,y.length>4&&(d.name=u+y[4],u+=y[4])),m.push(d),typeof d.originalLine=="number"){let x=d.source;for(;p.length<=x;)p.push(null);p[x]===null&&(p[x]=[]),p[x].push(d)}}ds(m,v),this.__generatedMappings=m;for(var E=0;E<p.length;E++)p[E]!=null&&Ve(p[E],_.compareByOriginalPositionsNoSource);this.__originalMappings=[].concat(...p)};B.prototype._findMapping=function(e,t,r,s,i,o){if(e[r]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[r]);if(e[s]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[s]);return dr.search(e,t,i,o)};B.prototype.computeColumnSpans=function(){for(var e=0;e<this._generatedMappings.length;++e){var t=this._generatedMappings[e];if(e+1<this._generatedMappings.length){var r=this._generatedMappings[e+1];if(t.generatedLine===r.generatedLine){t.lastGeneratedColumn=r.generatedColumn-1;continue}}t.lastGeneratedColumn=1/0}};B.prototype.originalPositionFor=function(e){var t={generatedLine:_.getArg(e,"line"),generatedColumn:_.getArg(e,"column")},r=this._findMapping(t,this._generatedMappings,"generatedLine","generatedColumn",_.compareByGeneratedPositionsDeflated,_.getArg(e,"bias",O.GREATEST_LOWER_BOUND));if(r>=0){var s=this._generatedMappings[r];if(s.generatedLine===t.generatedLine){var i=_.getArg(s,"source",null);i!==null&&(i=this._sources.at(i),i=_.computeSourceURL(this.sourceRoot,i,this._sourceMapURL));var o=_.getArg(s,"name",null);return o!==null&&(o=this._names.at(o)),{source:i,line:_.getArg(s,"originalLine",null),column:_.getArg(s,"originalColumn",null),name:o}}}return{source:null,line:null,column:null,name:null}};B.prototype.hasContentsOfAllSources=function(){return this.sourcesContent?this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(e){return e==null}):!1};B.prototype.sourceContentFor=function(e,t){if(!this.sourcesContent)return null;var r=this._findSourceIndex(e);if(r>=0)return this.sourcesContent[r];var s=e;this.sourceRoot!=null&&(s=_.relative(this.sourceRoot,s));var i;if(this.sourceRoot!=null&&(i=_.urlParse(this.sourceRoot))){var o=s.replace(/^file:\/\//,"");if(i.scheme=="file"&&this._sources.has(o))return this.sourcesContent[this._sources.indexOf(o)];if((!i.path||i.path=="/")&&this._sources.has("/"+s))return this.sourcesContent[this._sources.indexOf("/"+s)]}if(t)return null;throw new Error('"'+s+'" is not in the SourceMap.')};B.prototype.generatedPositionFor=function(e){var t=_.getArg(e,"source");if(t=this._findSourceIndex(t),t<0)return{line:null,column:null,lastColumn:null};var r={source:t,originalLine:_.getArg(e,"line"),originalColumn:_.getArg(e,"column")},s=this._findMapping(r,this._originalMappings,"originalLine","originalColumn",_.compareByOriginalPositions,_.getArg(e,"bias",O.GREATEST_LOWER_BOUND));if(s>=0){var i=this._originalMappings[s];if(i.source===r.source)return{line:_.getArg(i,"generatedLine",null),column:_.getArg(i,"generatedColumn",null),lastColumn:_.getArg(i,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}};wt.BasicSourceMapConsumer=B;function Z(n,e){var t=n;typeof n=="string"&&(t=_.parseSourceMapInput(n));var r=_.getArg(t,"version"),s=_.getArg(t,"sections");if(r!=this._version)throw new Error("Unsupported version: "+r);this._sources=new Oe,this._names=new Oe;var i={line:-1,column:0};this._sections=s.map(function(o){if(o.url)throw new Error("Support for url field in sections not implemented.");var l=_.getArg(o,"offset"),u=_.getArg(l,"line"),a=_.getArg(l,"column");if(u<i.line||u===i.line&&a<i.column)throw new Error("Section offsets must be ordered and non-overlapping.");return i=l,{generatedOffset:{generatedLine:u+1,generatedColumn:a+1},consumer:new O(_.getArg(o,"map"),e)}})}Z.prototype=Object.create(O.prototype);Z.prototype.constructor=O;Z.prototype._version=3;Object.defineProperty(Z.prototype,"sources",{get:function(){for(var n=[],e=0;e<this._sections.length;e++)for(var t=0;t<this._sections[e].consumer.sources.length;t++)n.push(this._sections[e].consumer.sources[t]);return n}});Z.prototype.originalPositionFor=function(e){var t={generatedLine:_.getArg(e,"line"),generatedColumn:_.getArg(e,"column")},r=dr.search(t,this._sections,function(i,o){var l=i.generatedLine-o.generatedOffset.generatedLine;return l||i.generatedColumn-o.generatedOffset.generatedColumn}),s=this._sections[r];return s?s.consumer.originalPositionFor({line:t.generatedLine-(s.generatedOffset.generatedLine-1),column:t.generatedColumn-(s.generatedOffset.generatedLine===t.generatedLine?s.generatedOffset.generatedColumn-1:0),bias:e.bias}):{source:null,line:null,column:null,name:null}};Z.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(e){return e.consumer.hasContentsOfAllSources()})};Z.prototype.sourceContentFor=function(e,t){for(var r=0;r<this._sections.length;r++){var s=this._sections[r],i=s.consumer.sourceContentFor(e,!0);if(i||i==="")return i}if(t)return null;throw new Error('"'+e+'" is not in the SourceMap.')};Z.prototype.generatedPositionFor=function(e){for(var t=0;t<this._sections.length;t++){var r=this._sections[t];if(r.consumer._findSourceIndex(_.getArg(e,"source"))!==-1){var s=r.consumer.generatedPositionFor(e);if(s){var i={line:s.line+(r.generatedOffset.generatedLine-1),column:s.column+(r.generatedOffset.generatedLine===s.line?r.generatedOffset.generatedColumn-1:0)};return i}}}return{line:null,column:null}};Z.prototype._parseMappings=function(e,t){this.__generatedMappings=[],this.__originalMappings=[];for(var r=0;r<this._sections.length;r++)for(var s=this._sections[r],i=s.consumer._generatedMappings,o=0;o<i.length;o++){var l=i[o],u=s.consumer._sources.at(l.source);u=_.computeSourceURL(s.consumer.sourceRoot,u,this._sourceMapURL),this._sources.add(u),u=this._sources.indexOf(u);var a=null;l.name&&(a=s.consumer._names.at(l.name),this._names.add(a),a=this._names.indexOf(a));var f={source:u,generatedLine:l.generatedLine+(s.generatedOffset.generatedLine-1),generatedColumn:l.generatedColumn+(s.generatedOffset.generatedLine===l.generatedLine?s.generatedOffset.generatedColumn-1:0),originalLine:l.originalLine,originalColumn:l.originalColumn,name:a};this.__generatedMappings.push(f),typeof f.originalLine=="number"&&this.__originalMappings.push(f)}Ve(this.__generatedMappings,_.compareByGeneratedPositionsDeflated),Ve(this.__originalMappings,_.compareByOriginalPositions)};wt.IndexedSourceMapConsumer=Z});var ys=S(_s=>{var Ml=cr().SourceMapGenerator,St=Ce(),Rl=/(\r?\n)/,Pl=10,Le="$$$isSourceNode$$$";function $(n,e,t,r,s){this.children=[],this.sourceContents={},this.line=n??null,this.column=e??null,this.source=t??null,this.name=s??null,this[Le]=!0,r!=null&&this.add(r)}$.fromStringWithSourceMap=function(e,t,r){var s=new $,i=e.split(Rl),o=0,l=function(){var c=m(),p=m()||"";return c+p;function m(){return o<i.length?i[o++]:void 0}},u=1,a=0,f=null;return t.eachMapping(function(c){if(f!==null)if(u<c.generatedLine)h(f,l()),u++,a=0;else{var p=i[o]||"",m=p.substr(0,c.generatedColumn-a);i[o]=p.substr(c.generatedColumn-a),a=c.generatedColumn,h(f,m),f=c;return}for(;u<c.generatedLine;)s.add(l()),u++;if(a<c.generatedColumn){var p=i[o]||"";s.add(p.substr(0,c.generatedColumn)),i[o]=p.substr(c.generatedColumn),a=c.generatedColumn}f=c},this),o<i.length&&(f&&h(f,l()),s.add(i.splice(o).join(""))),t.sources.forEach(function(c){var p=t.sourceContentFor(c);p!=null&&(r!=null&&(c=St.join(r,c)),s.setSourceContent(c,p))}),s;function h(c,p){if(c===null||c.source===void 0)s.add(p);else{var m=r?St.join(r,c.source):c.source;s.add(new $(c.originalLine,c.originalColumn,m,p,c.name))}}};$.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(t){this.add(t)},this);else if(e[Le]||typeof e=="string")e&&this.children.push(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};$.prototype.prepend=function(e){if(Array.isArray(e))for(var t=e.length-1;t>=0;t--)this.prepend(e[t]);else if(e[Le]||typeof e=="string")this.children.unshift(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};$.prototype.walk=function(e){for(var t,r=0,s=this.children.length;r<s;r++)t=this.children[r],t[Le]?t.walk(e):t!==""&&e(t,{source:this.source,line:this.line,column:this.column,name:this.name})};$.prototype.join=function(e){var t,r,s=this.children.length;if(s>0){for(t=[],r=0;r<s-1;r++)t.push(this.children[r]),t.push(e);t.push(this.children[r]),this.children=t}return this};$.prototype.replaceRight=function(e,t){var r=this.children[this.children.length-1];return r[Le]?r.replaceRight(e,t):typeof r=="string"?this.children[this.children.length-1]=r.replace(e,t):this.children.push("".replace(e,t)),this};$.prototype.setSourceContent=function(e,t){this.sourceContents[St.toSetString(e)]=t};$.prototype.walkSourceContents=function(e){for(var t=0,r=this.children.length;t<r;t++)this.children[t][Le]&&this.children[t].walkSourceContents(e);for(var s=Object.keys(this.sourceContents),t=0,r=s.length;t<r;t++)e(St.fromSetString(s[t]),this.sourceContents[s[t]])};$.prototype.toString=function(){var e="";return this.walk(function(t){e+=t}),e};$.prototype.toStringWithSourceMap=function(e){var t={code:"",line:1,column:0},r=new Ml(e),s=!1,i=null,o=null,l=null,u=null;return this.walk(function(a,f){t.code+=a,f.source!==null&&f.line!==null&&f.column!==null?((i!==f.source||o!==f.line||l!==f.column||u!==f.name)&&r.addMapping({source:f.source,original:{line:f.line,column:f.column},generated:{line:t.line,column:t.column},name:f.name}),i=f.source,o=f.line,l=f.column,u=f.name,s=!0):s&&(r.addMapping({generated:{line:t.line,column:t.column}}),i=null,s=!1);for(var h=0,c=a.length;h<c;h++)a.charCodeAt(h)===Pl?(t.line++,t.column=0,h+1===c?(i=null,s=!1):s&&r.addMapping({source:f.source,original:{line:f.line,column:f.column},generated:{line:t.line,column:t.column},name:f.name})):t.column++}),this.walkSourceContents(function(a,f){r.setSourceContent(a,f)}),{code:t.code,map:r}};_s.SourceNode=$});var mr=S(vt=>{vt.SourceMapGenerator=cr().SourceMapGenerator;vt.SourceMapConsumer=gs().SourceMapConsumer;vt.SourceNode=ys().SourceNode});var Ss=S((Kf,ws)=>{var kl="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",Il=(n,e=21)=>(t=e)=>{let r="",s=t;for(;s--;)r+=n[Math.random()*n.length|0];return r},Bl=(n=21)=>{let e="",t=n;for(;t--;)e+=kl[Math.random()*64|0];return e};ws.exports={nanoid:Bl,customAlphabet:Il}});var Es=S((Zf,bs)=>{"use strict";var{SourceMapConsumer:vs,SourceMapGenerator:xs}=mr(),{existsSync:Fl,readFileSync:Ul}=require("fs"),{dirname:gr,join:Dl}=require("path");function Wl(n){return Buffer?Buffer.from(n,"base64").toString():window.atob(n)}var He=class{constructor(e,t){if(t.map===!1)return;this.loadAnnotation(e),this.inline=this.startWith(this.annotation,"data:");let r=t.map?t.map.prev:void 0,s=this.loadMap(t.from,r);!this.mapFile&&t.from&&(this.mapFile=t.from),this.mapFile&&(this.root=gr(this.mapFile)),s&&(this.text=s)}consumer(){return this.consumerCache||(this.consumerCache=new vs(this.text)),this.consumerCache}decodeInline(e){let t=/^data:application\/json;charset=utf-?8;base64,/,r=/^data:application\/json;base64,/,s=/^data:application\/json;charset=utf-?8,/,i=/^data:application\/json,/,o=e.match(s)||e.match(i);if(o)return decodeURIComponent(e.substr(o[0].length));let l=e.match(t)||e.match(r);if(l)return Wl(e.substr(l[0].length));let u=e.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+u)}getAnnotationURL(e){return e.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(e){return typeof e!="object"?!1:typeof e.mappings=="string"||typeof e._mappings=="string"||Array.isArray(e.sections)}loadAnnotation(e){let t=e.match(/\/\*\s*# sourceMappingURL=/g);if(!t)return;let r=e.lastIndexOf(t.pop()),s=e.indexOf("*/",r);r>-1&&s>-1&&(this.annotation=this.getAnnotationURL(e.substring(r,s)))}loadFile(e){if(this.root=gr(e),Fl(e))return this.mapFile=e,Ul(e,"utf-8").toString().trim()}loadMap(e,t){if(t===!1)return!1;if(t){if(typeof t=="string")return t;if(typeof t=="function"){let r=t(e);if(r){let s=this.loadFile(r);if(!s)throw new Error("Unable to load previous source map: "+r.toString());return s}}else{if(t instanceof vs)return xs.fromSourceMap(t).toString();if(t instanceof xs)return t.toString();if(this.isMap(t))return JSON.stringify(t);throw new Error("Unsupported previous source map format: "+t.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let r=this.annotation;return e&&(r=Dl(gr(e),r)),this.loadFile(r)}}}startWith(e,t){return e?e.substr(0,t.length)===t:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}};bs.exports=He;He.default=He});var As=S((Xf,Ts)=>{"use strict";var{SourceMapConsumer:jl,SourceMapGenerator:$l}=mr(),{fileURLToPath:Cs,pathToFileURL:xt}=require("url"),{isAbsolute:wr,resolve:Sr}=require("path"),{nanoid:ql}=Ss(),_r=Ht(),Os=Yt(),Gl=Es(),yr=Symbol("fromOffsetCache"),zl=!!(jl&&$l),Ls=!!(Sr&&wr),Te=class{constructor(e,t={}){if(e===null||typeof e>"u"||typeof e=="object"&&!e.toString)throw new Error(`PostCSS received ${e} instead of CSS string`);if(this.css=e.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,t.from&&(!Ls||/^\w+:\/\//.test(t.from)||wr(t.from)?this.file=t.from:this.file=Sr(t.from)),Ls&&zl){let r=new Gl(this.css,t);if(r.text){this.map=r;let s=r.consumer().file;!this.file&&s&&(this.file=this.mapResolve(s))}}this.file||(this.id="<input css "+ql(6)+">"),this.map&&(this.map.file=this.from)}error(e,t,r,s={}){let i,o,l;if(t&&typeof t=="object"){let a=t,f=r;if(typeof a.offset=="number"){let h=this.fromOffset(a.offset);t=h.line,r=h.col}else t=a.line,r=a.column;if(typeof f.offset=="number"){let h=this.fromOffset(f.offset);o=h.line,l=h.col}else o=f.line,l=f.column}else if(!r){let a=this.fromOffset(t);t=a.line,r=a.col}let u=this.origin(t,r,o,l);return u?i=new Os(e,u.endLine===void 0?u.line:{column:u.column,line:u.line},u.endLine===void 0?u.column:{column:u.endColumn,line:u.endLine},u.source,u.file,s.plugin):i=new Os(e,o===void 0?t:{column:r,line:t},o===void 0?r:{column:l,line:o},this.css,this.file,s.plugin),i.input={column:r,endColumn:l,endLine:o,line:t,source:this.css},this.file&&(xt&&(i.input.url=xt(this.file).toString()),i.input.file=this.file),i}fromOffset(e){let t,r;if(this[yr])r=this[yr];else{let i=this.css.split(`
|
|
22
|
+
`);r=new Array(i.length);let o=0;for(let l=0,u=i.length;l<u;l++)r[l]=o,o+=i[l].length+1;this[yr]=r}t=r[r.length-1];let s=0;if(e>=t)s=r.length-1;else{let i=r.length-2,o;for(;s<i;)if(o=s+(i-s>>1),e<r[o])i=o-1;else if(e>=r[o+1])s=o+1;else{s=o;break}}return{col:e-r[s]+1,line:s+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:Sr(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,r,s){if(!this.map)return!1;let i=this.map.consumer(),o=i.originalPositionFor({column:t,line:e});if(!o.source)return!1;let l;typeof r=="number"&&(l=i.originalPositionFor({column:s,line:r}));let u;wr(o.source)?u=xt(o.source):u=new URL(o.source,this.map.consumer().sourceRoot||xt(this.map.mapFile));let a={column:o.column,endColumn:l&&l.column,endLine:l&&l.line,line:o.line,url:u.toString()};if(u.protocol==="file:")if(Cs)a.file=Cs(u);else throw new Error("file: protocol is not available in this PostCSS build");let f=i.sourceContentFor(o.source);return f&&(a.source=f),a}toJSON(){let e={};for(let t of["hasBOM","css","file","id"])this[t]!=null&&(e[t]=this[t]);return this.map&&(e.map={...this.map},e.map.consumerCache&&(e.map.consumerCache=void 0)),e}get from(){return this.file||this.id}};Ts.exports=Te;Te.default=Te;_r&&_r.registerInput&&_r.registerInput(Te)});var Ms=S((ec,Ns)=>{"use strict";var Vl=$e(),Hl=Hn(),Yl=As();function bt(n,e){let t=new Yl(n,e),r=new Hl(t);try{r.parse()}catch(s){throw process.env.NODE_ENV!=="production"&&s.name==="CssSyntaxError"&&e&&e.from&&(/\.scss$/i.test(e.from)?s.message+=`
|
|
23
23
|
You tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser`:/\.sass/i.test(e.from)?s.message+=`
|
|
24
24
|
You tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser`:/\.less$/i.test(e.from)&&(s.message+=`
|
|
25
|
-
You tried to parse Less with the standard CSS parser; try again with the postcss-less parser`)),s}return r.root}Ns.exports=bt;bt.default=bt;Vl.registerParse(bt)});var Is=S((tc,ks)=>{"use strict";var{Duplex:Jl}=require("stream");function Ms(n){n.emit("close")}function Ql(){!this.destroyed&&this._writableState.finished&&this.destroy()}function Ps(n){this.removeListener("error",Ps),this.destroy(),this.listenerCount("error")===0&&this.emit("error",n)}function Kl(n,e){let t=!0,r=new Jl({...e,autoDestroy:!1,emitClose:!1,objectMode:!1,writableObjectMode:!1});return n.on("message",function(i,o){let l=!o&&r._readableState.objectMode?i.toString():i;r.push(l)||n.pause()}),n.once("error",function(i){r.destroyed||(t=!1,r.destroy(i))}),n.once("close",function(){r.destroyed||r.push(null)}),r._destroy=function(s,i){if(n.readyState===n.CLOSED){i(s),process.nextTick(Ms,r);return}let o=!1;n.once("error",function(u){o=!0,i(u)}),n.once("close",function(){o||i(s),process.nextTick(Ms,r)}),t&&n.terminate()},r._final=function(s){if(n.readyState===n.CONNECTING){n.once("open",function(){r._final(s)});return}n._socket!==null&&(n._socket._writableState.finished?(s(),r._readableState.endEmitted&&r.destroy()):(n._socket.once("finish",function(){s()}),n.close()))},r._read=function(){n.isPaused&&n.resume()},r._write=function(s,i,o){if(n.readyState===n.CONNECTING){n.once("open",function(){r._write(s,i,o)});return}n.send(s,o)},r.on("end",Ql),r.on("error",Ps),r}ks.exports=Kl});var se=S((rc,Us)=>{"use strict";var Bs=["nodebuffer","arraybuffer","fragments"],Fs=typeof Blob<"u";Fs&&Bs.push("blob");Us.exports={BINARY_TYPES:Bs,EMPTY_BUFFER:Buffer.alloc(0),GUID:"258EAFA5-E914-47DA-95CA-C5AB0DC85B11",hasBlob:Fs,kForOnEventAttribute:Symbol("kIsForOnEventAttribute"),kListener:Symbol("kListener"),kStatusCode:Symbol("status-code"),kWebSocket:Symbol("websocket"),NOOP:()=>{}}});var Ye=S((nc,Et)=>{"use strict";var{EMPTY_BUFFER:Zl}=se(),vr=Buffer[Symbol.species];function Xl(n,e){if(n.length===0)return Zl;if(n.length===1)return n[0];let t=Buffer.allocUnsafe(e),r=0;for(let s=0;s<n.length;s++){let i=n[s];t.set(i,r),r+=i.length}return r<e?new vr(t.buffer,t.byteOffset,r):t}function Ds(n,e,t,r,s){for(let i=0;i<s;i++)t[r+i]=n[i]^e[i&3]}function Ws(n,e){for(let t=0;t<n.length;t++)n[t]^=e[t&3]}function ea(n){return n.length===n.buffer.byteLength?n.buffer:n.buffer.slice(n.byteOffset,n.byteOffset+n.length)}function xr(n){if(xr.readOnly=!0,Buffer.isBuffer(n))return n;let e;return n instanceof ArrayBuffer?e=new vr(n):ArrayBuffer.isView(n)?e=new vr(n.buffer,n.byteOffset,n.byteLength):(e=Buffer.from(n),xr.readOnly=!1),e}Et.exports={concat:Xl,mask:Ds,toArrayBuffer:ea,toBuffer:xr,unmask:Ws};if(!process.env.WS_NO_BUFFER_UTIL)try{let n=require("bufferutil");Et.exports.mask=function(e,t,r,s,i){i<48?Ds(e,t,r,s,i):n.mask(e,t,r,s,i)},Et.exports.unmask=function(e,t){e.length<32?Ws(e,t):n.unmask(e,t)}}catch{}});var qs=S((sc,$s)=>{"use strict";var js=Symbol("kDone"),br=Symbol("kRun"),Er=class{constructor(e){this[js]=()=>{this.pending--,this[br]()},this.concurrency=e||1/0,this.jobs=[],this.pending=0}add(e){this.jobs.push(e),this[br]()}[br](){if(this.pending!==this.concurrency&&this.jobs.length){let e=this.jobs.shift();this.pending++,e(this[js])}}};$s.exports=Er});var Ke=S((ic,Hs)=>{"use strict";var Je=require("zlib"),Gs=Ye(),ta=qs(),{kStatusCode:zs}=se(),ra=Buffer[Symbol.species],na=Buffer.from([0,0,255,255]),Lt=Symbol("permessage-deflate"),ie=Symbol("total-length"),Qe=Symbol("callback"),fe=Symbol("buffers"),Ot=Symbol("error"),Ct,Cr=class{constructor(e,t,r){if(this._maxPayload=r|0,this._options=e||{},this._threshold=this._options.threshold!==void 0?this._options.threshold:1024,this._isServer=!!t,this._deflate=null,this._inflate=null,this.params=null,!Ct){let s=this._options.concurrencyLimit!==void 0?this._options.concurrencyLimit:10;Ct=new ta(s)}}static get extensionName(){return"permessage-deflate"}offer(){let e={};return this._options.serverNoContextTakeover&&(e.server_no_context_takeover=!0),this._options.clientNoContextTakeover&&(e.client_no_context_takeover=!0),this._options.serverMaxWindowBits&&(e.server_max_window_bits=this._options.serverMaxWindowBits),this._options.clientMaxWindowBits?e.client_max_window_bits=this._options.clientMaxWindowBits:this._options.clientMaxWindowBits==null&&(e.client_max_window_bits=!0),e}accept(e){return e=this.normalizeParams(e),this.params=this._isServer?this.acceptAsServer(e):this.acceptAsClient(e),this.params}cleanup(){if(this._inflate&&(this._inflate.close(),this._inflate=null),this._deflate){let e=this._deflate[Qe];this._deflate.close(),this._deflate=null,e&&e(new Error("The deflate stream was closed while data was being processed"))}}acceptAsServer(e){let t=this._options,r=e.find(s=>!(t.serverNoContextTakeover===!1&&s.server_no_context_takeover||s.server_max_window_bits&&(t.serverMaxWindowBits===!1||typeof t.serverMaxWindowBits=="number"&&t.serverMaxWindowBits>s.server_max_window_bits)||typeof t.clientMaxWindowBits=="number"&&!s.client_max_window_bits));if(!r)throw new Error("None of the extension offers can be accepted");return t.serverNoContextTakeover&&(r.server_no_context_takeover=!0),t.clientNoContextTakeover&&(r.client_no_context_takeover=!0),typeof t.serverMaxWindowBits=="number"&&(r.server_max_window_bits=t.serverMaxWindowBits),typeof t.clientMaxWindowBits=="number"?r.client_max_window_bits=t.clientMaxWindowBits:(r.client_max_window_bits===!0||t.clientMaxWindowBits===!1)&&delete r.client_max_window_bits,r}acceptAsClient(e){let t=e[0];if(this._options.clientNoContextTakeover===!1&&t.client_no_context_takeover)throw new Error('Unexpected parameter "client_no_context_takeover"');if(!t.client_max_window_bits)typeof this._options.clientMaxWindowBits=="number"&&(t.client_max_window_bits=this._options.clientMaxWindowBits);else if(this._options.clientMaxWindowBits===!1||typeof this._options.clientMaxWindowBits=="number"&&t.client_max_window_bits>this._options.clientMaxWindowBits)throw new Error('Unexpected or invalid parameter "client_max_window_bits"');return t}normalizeParams(e){return e.forEach(t=>{Object.keys(t).forEach(r=>{let s=t[r];if(s.length>1)throw new Error(`Parameter "${r}" must have only a single value`);if(s=s[0],r==="client_max_window_bits"){if(s!==!0){let i=+s;if(!Number.isInteger(i)||i<8||i>15)throw new TypeError(`Invalid value for parameter "${r}": ${s}`);s=i}else if(!this._isServer)throw new TypeError(`Invalid value for parameter "${r}": ${s}`)}else if(r==="server_max_window_bits"){let i=+s;if(!Number.isInteger(i)||i<8||i>15)throw new TypeError(`Invalid value for parameter "${r}": ${s}`);s=i}else if(r==="client_no_context_takeover"||r==="server_no_context_takeover"){if(s!==!0)throw new TypeError(`Invalid value for parameter "${r}": ${s}`)}else throw new Error(`Unknown parameter "${r}"`);t[r]=s})}),e}decompress(e,t,r){Ct.add(s=>{this._decompress(e,t,(i,o)=>{s(),r(i,o)})})}compress(e,t,r){Ct.add(s=>{this._compress(e,t,(i,o)=>{s(),r(i,o)})})}_decompress(e,t,r){let s=this._isServer?"client":"server";if(!this._inflate){let i=`${s}_max_window_bits`,o=typeof this.params[i]!="number"?Je.Z_DEFAULT_WINDOWBITS:this.params[i];this._inflate=Je.createInflateRaw({...this._options.zlibInflateOptions,windowBits:o}),this._inflate[Lt]=this,this._inflate[ie]=0,this._inflate[fe]=[],this._inflate.on("error",ia),this._inflate.on("data",Vs)}this._inflate[Qe]=r,this._inflate.write(e),t&&this._inflate.write(na),this._inflate.flush(()=>{let i=this._inflate[Ot];if(i){this._inflate.close(),this._inflate=null,r(i);return}let o=Gs.concat(this._inflate[fe],this._inflate[ie]);this._inflate._readableState.endEmitted?(this._inflate.close(),this._inflate=null):(this._inflate[ie]=0,this._inflate[fe]=[],t&&this.params[`${s}_no_context_takeover`]&&this._inflate.reset()),r(null,o)})}_compress(e,t,r){let s=this._isServer?"server":"client";if(!this._deflate){let i=`${s}_max_window_bits`,o=typeof this.params[i]!="number"?Je.Z_DEFAULT_WINDOWBITS:this.params[i];this._deflate=Je.createDeflateRaw({...this._options.zlibDeflateOptions,windowBits:o}),this._deflate[ie]=0,this._deflate[fe]=[],this._deflate.on("data",sa)}this._deflate[Qe]=r,this._deflate.write(e),this._deflate.flush(Je.Z_SYNC_FLUSH,()=>{if(!this._deflate)return;let i=Gs.concat(this._deflate[fe],this._deflate[ie]);t&&(i=new ra(i.buffer,i.byteOffset,i.length-4)),this._deflate[Qe]=null,this._deflate[ie]=0,this._deflate[fe]=[],t&&this.params[`${s}_no_context_takeover`]&&this._deflate.reset(),r(null,i)})}};Hs.exports=Cr;function sa(n){this[fe].push(n),this[ie]+=n.length}function Vs(n){if(this[ie]+=n.length,this[Lt]._maxPayload<1||this[ie]<=this[Lt]._maxPayload){this[fe].push(n);return}this[Ot]=new RangeError("Max payload size exceeded"),this[Ot].code="WS_ERR_UNSUPPORTED_MESSAGE_LENGTH",this[Ot][zs]=1009,this.removeListener("data",Vs),this.reset()}function ia(n){this[Lt]._inflate=null,n[zs]=1007,this[Qe](n)}});var Ae=S((oc,Tt)=>{"use strict";var{isUtf8:Ys}=require("buffer"),{hasBlob:oa}=se(),la=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,0,0,1,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,0];function aa(n){return n>=1e3&&n<=1014&&n!==1004&&n!==1005&&n!==1006||n>=3e3&&n<=4999}function Or(n){let e=n.length,t=0;for(;t<e;)if(!(n[t]&128))t++;else if((n[t]&224)===192){if(t+1===e||(n[t+1]&192)!==128||(n[t]&254)===192)return!1;t+=2}else if((n[t]&240)===224){if(t+2>=e||(n[t+1]&192)!==128||(n[t+2]&192)!==128||n[t]===224&&(n[t+1]&224)===128||n[t]===237&&(n[t+1]&224)===160)return!1;t+=3}else if((n[t]&248)===240){if(t+3>=e||(n[t+1]&192)!==128||(n[t+2]&192)!==128||(n[t+3]&192)!==128||n[t]===240&&(n[t+1]&240)===128||n[t]===244&&n[t+1]>143||n[t]>244)return!1;t+=4}else return!1;return!0}function ua(n){return oa&&typeof n=="object"&&typeof n.arrayBuffer=="function"&&typeof n.type=="string"&&typeof n.stream=="function"&&(n[Symbol.toStringTag]==="Blob"||n[Symbol.toStringTag]==="File")}Tt.exports={isBlob:ua,isValidStatusCode:aa,isValidUTF8:Or,tokenChars:la};if(Ys)Tt.exports.isValidUTF8=function(n){return n.length<24?Or(n):Ys(n)};else if(!process.env.WS_NO_UTF_8_VALIDATE)try{let n=require("utf-8-validate");Tt.exports.isValidUTF8=function(e){return e.length<32?Or(e):n(e)}}catch{}});var Rr=S((lc,ti)=>{"use strict";var{Writable:fa}=require("stream"),Js=Ke(),{BINARY_TYPES:ca,EMPTY_BUFFER:Qs,kStatusCode:ha,kWebSocket:pa}=se(),{concat:Lr,toArrayBuffer:da,unmask:ma}=Ye(),{isValidStatusCode:ga,isValidUTF8:Ks}=Ae(),At=Buffer[Symbol.species],V=0,Zs=1,Xs=2,ei=3,Tr=4,Ar=5,Nt=6,Nr=class extends fa{constructor(e={}){super(),this._allowSynchronousEvents=e.allowSynchronousEvents!==void 0?e.allowSynchronousEvents:!0,this._binaryType=e.binaryType||ca[0],this._extensions=e.extensions||{},this._isServer=!!e.isServer,this._maxPayload=e.maxPayload|0,this._skipUTF8Validation=!!e.skipUTF8Validation,this[pa]=void 0,this._bufferedBytes=0,this._buffers=[],this._compressed=!1,this._payloadLength=0,this._mask=void 0,this._fragmented=0,this._masked=!1,this._fin=!1,this._opcode=0,this._totalPayloadLength=0,this._messageLength=0,this._fragments=[],this._errored=!1,this._loop=!1,this._state=V}_write(e,t,r){if(this._opcode===8&&this._state==V)return r();this._bufferedBytes+=e.length,this._buffers.push(e),this.startLoop(r)}consume(e){if(this._bufferedBytes-=e,e===this._buffers[0].length)return this._buffers.shift();if(e<this._buffers[0].length){let r=this._buffers[0];return this._buffers[0]=new At(r.buffer,r.byteOffset+e,r.length-e),new At(r.buffer,r.byteOffset,e)}let t=Buffer.allocUnsafe(e);do{let r=this._buffers[0],s=t.length-e;e>=r.length?t.set(this._buffers.shift(),s):(t.set(new Uint8Array(r.buffer,r.byteOffset,e),s),this._buffers[0]=new At(r.buffer,r.byteOffset+e,r.length-e)),e-=r.length}while(e>0);return t}startLoop(e){this._loop=!0;do switch(this._state){case V:this.getInfo(e);break;case Zs:this.getPayloadLength16(e);break;case Xs:this.getPayloadLength64(e);break;case ei:this.getMask();break;case Tr:this.getData(e);break;case Ar:case Nt:this._loop=!1;return}while(this._loop);this._errored||e()}getInfo(e){if(this._bufferedBytes<2){this._loop=!1;return}let t=this.consume(2);if(t[0]&48){let s=this.createError(RangeError,"RSV2 and RSV3 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_2_3");e(s);return}let r=(t[0]&64)===64;if(r&&!this._extensions[Js.extensionName]){let s=this.createError(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");e(s);return}if(this._fin=(t[0]&128)===128,this._opcode=t[0]&15,this._payloadLength=t[1]&127,this._opcode===0){if(r){let s=this.createError(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");e(s);return}if(!this._fragmented){let s=this.createError(RangeError,"invalid opcode 0",!0,1002,"WS_ERR_INVALID_OPCODE");e(s);return}this._opcode=this._fragmented}else if(this._opcode===1||this._opcode===2){if(this._fragmented){let s=this.createError(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");e(s);return}this._compressed=r}else if(this._opcode>7&&this._opcode<11){if(!this._fin){let s=this.createError(RangeError,"FIN must be set",!0,1002,"WS_ERR_EXPECTED_FIN");e(s);return}if(r){let s=this.createError(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");e(s);return}if(this._payloadLength>125||this._opcode===8&&this._payloadLength===1){let s=this.createError(RangeError,`invalid payload length ${this._payloadLength}`,!0,1002,"WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH");e(s);return}}else{let s=this.createError(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");e(s);return}if(!this._fin&&!this._fragmented&&(this._fragmented=this._opcode),this._masked=(t[1]&128)===128,this._isServer){if(!this._masked){let s=this.createError(RangeError,"MASK must be set",!0,1002,"WS_ERR_EXPECTED_MASK");e(s);return}}else if(this._masked){let s=this.createError(RangeError,"MASK must be clear",!0,1002,"WS_ERR_UNEXPECTED_MASK");e(s);return}this._payloadLength===126?this._state=Zs:this._payloadLength===127?this._state=Xs:this.haveLength(e)}getPayloadLength16(e){if(this._bufferedBytes<2){this._loop=!1;return}this._payloadLength=this.consume(2).readUInt16BE(0),this.haveLength(e)}getPayloadLength64(e){if(this._bufferedBytes<8){this._loop=!1;return}let t=this.consume(8),r=t.readUInt32BE(0);if(r>Math.pow(2,21)-1){let s=this.createError(RangeError,"Unsupported WebSocket frame: payload length > 2^53 - 1",!1,1009,"WS_ERR_UNSUPPORTED_DATA_PAYLOAD_LENGTH");e(s);return}this._payloadLength=r*Math.pow(2,32)+t.readUInt32BE(4),this.haveLength(e)}haveLength(e){if(this._payloadLength&&this._opcode<8&&(this._totalPayloadLength+=this._payloadLength,this._totalPayloadLength>this._maxPayload&&this._maxPayload>0)){let t=this.createError(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH");e(t);return}this._masked?this._state=ei:this._state=Tr}getMask(){if(this._bufferedBytes<4){this._loop=!1;return}this._mask=this.consume(4),this._state=Tr}getData(e){let t=Qs;if(this._payloadLength){if(this._bufferedBytes<this._payloadLength){this._loop=!1;return}t=this.consume(this._payloadLength),this._masked&&this._mask[0]|this._mask[1]|this._mask[2]|this._mask[3]&&ma(t,this._mask)}if(this._opcode>7){this.controlMessage(t,e);return}if(this._compressed){this._state=Ar,this.decompress(t,e);return}t.length&&(this._messageLength=this._totalPayloadLength,this._fragments.push(t)),this.dataMessage(e)}decompress(e,t){this._extensions[Js.extensionName].decompress(e,this._fin,(s,i)=>{if(s)return t(s);if(i.length){if(this._messageLength+=i.length,this._messageLength>this._maxPayload&&this._maxPayload>0){let o=this.createError(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH");t(o);return}this._fragments.push(i)}this.dataMessage(t),this._state===V&&this.startLoop(t)})}dataMessage(e){if(!this._fin){this._state=V;return}let t=this._messageLength,r=this._fragments;if(this._totalPayloadLength=0,this._messageLength=0,this._fragmented=0,this._fragments=[],this._opcode===2){let s;this._binaryType==="nodebuffer"?s=Lr(r,t):this._binaryType==="arraybuffer"?s=da(Lr(r,t)):this._binaryType==="blob"?s=new Blob(r):s=r,this._allowSynchronousEvents?(this.emit("message",s,!0),this._state=V):(this._state=Nt,setImmediate(()=>{this.emit("message",s,!0),this._state=V,this.startLoop(e)}))}else{let s=Lr(r,t);if(!this._skipUTF8Validation&&!Ks(s)){let i=this.createError(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");e(i);return}this._state===Ar||this._allowSynchronousEvents?(this.emit("message",s,!1),this._state=V):(this._state=Nt,setImmediate(()=>{this.emit("message",s,!1),this._state=V,this.startLoop(e)}))}}controlMessage(e,t){if(this._opcode===8){if(e.length===0)this._loop=!1,this.emit("conclude",1005,Qs),this.end();else{let r=e.readUInt16BE(0);if(!ga(r)){let i=this.createError(RangeError,`invalid status code ${r}`,!0,1002,"WS_ERR_INVALID_CLOSE_CODE");t(i);return}let s=new At(e.buffer,e.byteOffset+2,e.length-2);if(!this._skipUTF8Validation&&!Ks(s)){let i=this.createError(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");t(i);return}this._loop=!1,this.emit("conclude",r,s),this.end()}this._state=V;return}this._allowSynchronousEvents?(this.emit(this._opcode===9?"ping":"pong",e),this._state=V):(this._state=Nt,setImmediate(()=>{this.emit(this._opcode===9?"ping":"pong",e),this._state=V,this.startLoop(t)}))}createError(e,t,r,s,i){this._loop=!1,this._errored=!0;let o=new e(r?`Invalid WebSocket frame: ${t}`:t);return Error.captureStackTrace(o,this.createError),o.code=i,o[ha]=s,o}};ti.exports=Nr});var kr=S((uc,si)=>{"use strict";var{Duplex:ac}=require("stream"),{randomFillSync:_a}=require("crypto"),ri=Ke(),{EMPTY_BUFFER:ya,kWebSocket:wa,NOOP:Sa}=se(),{isBlob:Ne,isValidStatusCode:va}=Ae(),{mask:ni,toBuffer:ge}=Ye(),H=Symbol("kByteLength"),xa=Buffer.alloc(4),Rt=8*1024,_e,Re=Rt,X=0,ba=1,Ea=2,Mr=class n{constructor(e,t,r){this._extensions=t||{},r&&(this._generateMask=r,this._maskBuffer=Buffer.alloc(4)),this._socket=e,this._firstFragment=!0,this._compress=!1,this._bufferedBytes=0,this._queue=[],this._state=X,this.onerror=Sa,this[wa]=void 0}static frame(e,t){let r,s=!1,i=2,o=!1;t.mask&&(r=t.maskBuffer||xa,t.generateMask?t.generateMask(r):(Re===Rt&&(_e===void 0&&(_e=Buffer.alloc(Rt)),_a(_e,0,Rt),Re=0),r[0]=_e[Re++],r[1]=_e[Re++],r[2]=_e[Re++],r[3]=_e[Re++]),o=(r[0]|r[1]|r[2]|r[3])===0,i=6);let l;typeof e=="string"?(!t.mask||o)&&t[H]!==void 0?l=t[H]:(e=Buffer.from(e),l=e.length):(l=e.length,s=t.mask&&t.readOnly&&!o);let u=l;l>=65536?(i+=8,u=127):l>125&&(i+=2,u=126);let a=Buffer.allocUnsafe(s?l+i:i);return a[0]=t.fin?t.opcode|128:t.opcode,t.rsv1&&(a[0]|=64),a[1]=u,u===126?a.writeUInt16BE(l,2):u===127&&(a[2]=a[3]=0,a.writeUIntBE(l,4,6)),t.mask?(a[1]|=128,a[i-4]=r[0],a[i-3]=r[1],a[i-2]=r[2],a[i-1]=r[3],o?[a,e]:s?(ni(e,r,a,i,l),[a]):(ni(e,r,e,0,l),[a,e])):[a,e]}close(e,t,r,s){let i;if(e===void 0)i=ya;else{if(typeof e!="number"||!va(e))throw new TypeError("First argument must be a valid error code number");if(t===void 0||!t.length)i=Buffer.allocUnsafe(2),i.writeUInt16BE(e,0);else{let l=Buffer.byteLength(t);if(l>123)throw new RangeError("The message must not be greater than 123 bytes");i=Buffer.allocUnsafe(2+l),i.writeUInt16BE(e,0),typeof t=="string"?i.write(t,2):i.set(t,2)}}let o={[H]:i.length,fin:!0,generateMask:this._generateMask,mask:r,maskBuffer:this._maskBuffer,opcode:8,readOnly:!1,rsv1:!1};this._state!==X?this.enqueue([this.dispatch,i,!1,o,s]):this.sendFrame(n.frame(i,o),s)}ping(e,t,r){let s,i;if(typeof e=="string"?(s=Buffer.byteLength(e),i=!1):Ne(e)?(s=e.size,i=!1):(e=ge(e),s=e.length,i=ge.readOnly),s>125)throw new RangeError("The data size must not be greater than 125 bytes");let o={[H]:s,fin:!0,generateMask:this._generateMask,mask:t,maskBuffer:this._maskBuffer,opcode:9,readOnly:i,rsv1:!1};Ne(e)?this._state!==X?this.enqueue([this.getBlobData,e,!1,o,r]):this.getBlobData(e,!1,o,r):this._state!==X?this.enqueue([this.dispatch,e,!1,o,r]):this.sendFrame(n.frame(e,o),r)}pong(e,t,r){let s,i;if(typeof e=="string"?(s=Buffer.byteLength(e),i=!1):Ne(e)?(s=e.size,i=!1):(e=ge(e),s=e.length,i=ge.readOnly),s>125)throw new RangeError("The data size must not be greater than 125 bytes");let o={[H]:s,fin:!0,generateMask:this._generateMask,mask:t,maskBuffer:this._maskBuffer,opcode:10,readOnly:i,rsv1:!1};Ne(e)?this._state!==X?this.enqueue([this.getBlobData,e,!1,o,r]):this.getBlobData(e,!1,o,r):this._state!==X?this.enqueue([this.dispatch,e,!1,o,r]):this.sendFrame(n.frame(e,o),r)}send(e,t,r){let s=this._extensions[ri.extensionName],i=t.binary?2:1,o=t.compress,l,u;typeof e=="string"?(l=Buffer.byteLength(e),u=!1):Ne(e)?(l=e.size,u=!1):(e=ge(e),l=e.length,u=ge.readOnly),this._firstFragment?(this._firstFragment=!1,o&&s&&s.params[s._isServer?"server_no_context_takeover":"client_no_context_takeover"]&&(o=l>=s._threshold),this._compress=o):(o=!1,i=0),t.fin&&(this._firstFragment=!0);let a={[H]:l,fin:t.fin,generateMask:this._generateMask,mask:t.mask,maskBuffer:this._maskBuffer,opcode:i,readOnly:u,rsv1:o};Ne(e)?this._state!==X?this.enqueue([this.getBlobData,e,this._compress,a,r]):this.getBlobData(e,this._compress,a,r):this._state!==X?this.enqueue([this.dispatch,e,this._compress,a,r]):this.dispatch(e,this._compress,a,r)}getBlobData(e,t,r,s){this._bufferedBytes+=r[H],this._state=Ea,e.arrayBuffer().then(i=>{if(this._socket.destroyed){let l=new Error("The socket was closed while the blob was being read");process.nextTick(Pr,this,l,s);return}this._bufferedBytes-=r[H];let o=ge(i);t?this.dispatch(o,t,r,s):(this._state=X,this.sendFrame(n.frame(o,r),s),this.dequeue())}).catch(i=>{process.nextTick(Ca,this,i,s)})}dispatch(e,t,r,s){if(!t){this.sendFrame(n.frame(e,r),s);return}let i=this._extensions[ri.extensionName];this._bufferedBytes+=r[H],this._state=ba,i.compress(e,r.fin,(o,l)=>{if(this._socket.destroyed){let u=new Error("The socket was closed while data was being compressed");Pr(this,u,s);return}this._bufferedBytes-=r[H],this._state=X,r.readOnly=!1,this.sendFrame(n.frame(l,r),s),this.dequeue()})}dequeue(){for(;this._state===X&&this._queue.length;){let e=this._queue.shift();this._bufferedBytes-=e[3][H],Reflect.apply(e[0],this,e.slice(1))}}enqueue(e){this._bufferedBytes+=e[3][H],this._queue.push(e)}sendFrame(e,t){e.length===2?(this._socket.cork(),this._socket.write(e[0]),this._socket.write(e[1],t),this._socket.uncork()):this._socket.write(e[0],t)}};si.exports=Mr;function Pr(n,e,t){typeof t=="function"&&t(e);for(let r=0;r<n._queue.length;r++){let s=n._queue[r],i=s[s.length-1];typeof i=="function"&&i(e)}}function Ca(n,e,t){Pr(n,e,t),n.onerror(e)}});var pi=S((fc,hi)=>{"use strict";var{kForOnEventAttribute:Ze,kListener:Ir}=se(),ii=Symbol("kCode"),oi=Symbol("kData"),li=Symbol("kError"),ai=Symbol("kMessage"),ui=Symbol("kReason"),Me=Symbol("kTarget"),fi=Symbol("kType"),ci=Symbol("kWasClean"),oe=class{constructor(e){this[Me]=null,this[fi]=e}get target(){return this[Me]}get type(){return this[fi]}};Object.defineProperty(oe.prototype,"target",{enumerable:!0});Object.defineProperty(oe.prototype,"type",{enumerable:!0});var ye=class extends oe{constructor(e,t={}){super(e),this[ii]=t.code===void 0?0:t.code,this[ui]=t.reason===void 0?"":t.reason,this[ci]=t.wasClean===void 0?!1:t.wasClean}get code(){return this[ii]}get reason(){return this[ui]}get wasClean(){return this[ci]}};Object.defineProperty(ye.prototype,"code",{enumerable:!0});Object.defineProperty(ye.prototype,"reason",{enumerable:!0});Object.defineProperty(ye.prototype,"wasClean",{enumerable:!0});var Pe=class extends oe{constructor(e,t={}){super(e),this[li]=t.error===void 0?null:t.error,this[ai]=t.message===void 0?"":t.message}get error(){return this[li]}get message(){return this[ai]}};Object.defineProperty(Pe.prototype,"error",{enumerable:!0});Object.defineProperty(Pe.prototype,"message",{enumerable:!0});var Xe=class extends oe{constructor(e,t={}){super(e),this[oi]=t.data===void 0?null:t.data}get data(){return this[oi]}};Object.defineProperty(Xe.prototype,"data",{enumerable:!0});var Oa={addEventListener(n,e,t={}){for(let s of this.listeners(n))if(!t[Ze]&&s[Ir]===e&&!s[Ze])return;let r;if(n==="message")r=function(i,o){let l=new Xe("message",{data:o?i:i.toString()});l[Me]=this,Mt(e,this,l)};else if(n==="close")r=function(i,o){let l=new ye("close",{code:i,reason:o.toString(),wasClean:this._closeFrameReceived&&this._closeFrameSent});l[Me]=this,Mt(e,this,l)};else if(n==="error")r=function(i){let o=new Pe("error",{error:i,message:i.message});o[Me]=this,Mt(e,this,o)};else if(n==="open")r=function(){let i=new oe("open");i[Me]=this,Mt(e,this,i)};else return;r[Ze]=!!t[Ze],r[Ir]=e,t.once?this.once(n,r):this.on(n,r)},removeEventListener(n,e){for(let t of this.listeners(n))if(t[Ir]===e&&!t[Ze]){this.removeListener(n,t);break}}};hi.exports={CloseEvent:ye,ErrorEvent:Pe,Event:oe,EventTarget:Oa,MessageEvent:Xe};function Mt(n,e,t){typeof n=="object"&&n.handleEvent?n.handleEvent.call(n,t):n.call(e,t)}});var Br=S((cc,di)=>{"use strict";var{tokenChars:et}=Ae();function te(n,e,t){n[e]===void 0?n[e]=[t]:n[e].push(t)}function La(n){let e=Object.create(null),t=Object.create(null),r=!1,s=!1,i=!1,o,l,u=-1,a=-1,f=-1,h=0;for(;h<n.length;h++)if(a=n.charCodeAt(h),o===void 0)if(f===-1&&et[a]===1)u===-1&&(u=h);else if(h!==0&&(a===32||a===9))f===-1&&u!==-1&&(f=h);else if(a===59||a===44){if(u===-1)throw new SyntaxError(`Unexpected character at index ${h}`);f===-1&&(f=h);let p=n.slice(u,f);a===44?(te(e,p,t),t=Object.create(null)):o=p,u=f=-1}else throw new SyntaxError(`Unexpected character at index ${h}`);else if(l===void 0)if(f===-1&&et[a]===1)u===-1&&(u=h);else if(a===32||a===9)f===-1&&u!==-1&&(f=h);else if(a===59||a===44){if(u===-1)throw new SyntaxError(`Unexpected character at index ${h}`);f===-1&&(f=h),te(t,n.slice(u,f),!0),a===44&&(te(e,o,t),t=Object.create(null),o=void 0),u=f=-1}else if(a===61&&u!==-1&&f===-1)l=n.slice(u,h),u=f=-1;else throw new SyntaxError(`Unexpected character at index ${h}`);else if(s){if(et[a]!==1)throw new SyntaxError(`Unexpected character at index ${h}`);u===-1?u=h:r||(r=!0),s=!1}else if(i)if(et[a]===1)u===-1&&(u=h);else if(a===34&&u!==-1)i=!1,f=h;else if(a===92)s=!0;else throw new SyntaxError(`Unexpected character at index ${h}`);else if(a===34&&n.charCodeAt(h-1)===61)i=!0;else if(f===-1&&et[a]===1)u===-1&&(u=h);else if(u!==-1&&(a===32||a===9))f===-1&&(f=h);else if(a===59||a===44){if(u===-1)throw new SyntaxError(`Unexpected character at index ${h}`);f===-1&&(f=h);let p=n.slice(u,f);r&&(p=p.replace(/\\/g,""),r=!1),te(t,l,p),a===44&&(te(e,o,t),t=Object.create(null),o=void 0),l=void 0,u=f=-1}else throw new SyntaxError(`Unexpected character at index ${h}`);if(u===-1||i||a===32||a===9)throw new SyntaxError("Unexpected end of input");f===-1&&(f=h);let c=n.slice(u,f);return o===void 0?te(e,c,t):(l===void 0?te(t,c,!0):r?te(t,l,c.replace(/\\/g,"")):te(t,l,c),te(e,o,t)),e}function Ta(n){return Object.keys(n).map(e=>{let t=n[e];return Array.isArray(t)||(t=[t]),t.map(r=>[e].concat(Object.keys(r).map(s=>{let i=r[s];return Array.isArray(i)||(i=[i]),i.map(o=>o===!0?s:`${s}=${o}`).join("; ")})).join("; ")).join(", ")}).join(", ")}di.exports={format:Ta,parse:La}});var jr=S((dc,Oi)=>{"use strict";var Aa=require("events"),Na=require("https"),Ra=require("http"),_i=require("net"),Ma=require("tls"),{randomBytes:Pa,createHash:ka}=require("crypto"),{Duplex:hc,Readable:pc}=require("stream"),{URL:Fr}=require("url"),ce=Ke(),Ia=Rr(),Ba=kr(),{isBlob:Fa}=Ae(),{BINARY_TYPES:mi,EMPTY_BUFFER:Pt,GUID:Ua,kForOnEventAttribute:Ur,kListener:Da,kStatusCode:Wa,kWebSocket:I,NOOP:yi}=se(),{EventTarget:{addEventListener:ja,removeEventListener:$a}}=pi(),{format:qa,parse:Ga}=Br(),{toBuffer:za}=Ye(),Va=30*1e3,wi=Symbol("kAborted"),Dr=[8,13],le=["CONNECTING","OPEN","CLOSING","CLOSED"],Ha=/^[!#$%&'*+\-.0-9A-Z^_`|a-z~]+$/,L=class n extends Aa{constructor(e,t,r){super(),this._binaryType=mi[0],this._closeCode=1006,this._closeFrameReceived=!1,this._closeFrameSent=!1,this._closeMessage=Pt,this._closeTimer=null,this._errorEmitted=!1,this._extensions={},this._paused=!1,this._protocol="",this._readyState=n.CONNECTING,this._receiver=null,this._sender=null,this._socket=null,e!==null?(this._bufferedAmount=0,this._isServer=!1,this._redirects=0,t===void 0?t=[]:Array.isArray(t)||(typeof t=="object"&&t!==null?(r=t,t=[]):t=[t]),Si(this,e,t,r)):(this._autoPong=r.autoPong,this._isServer=!0)}get binaryType(){return this._binaryType}set binaryType(e){mi.includes(e)&&(this._binaryType=e,this._receiver&&(this._receiver._binaryType=e))}get bufferedAmount(){return this._socket?this._socket._writableState.length+this._sender._bufferedBytes:this._bufferedAmount}get extensions(){return Object.keys(this._extensions).join()}get isPaused(){return this._paused}get onclose(){return null}get onerror(){return null}get onopen(){return null}get onmessage(){return null}get protocol(){return this._protocol}get readyState(){return this._readyState}get url(){return this._url}setSocket(e,t,r){let s=new Ia({allowSynchronousEvents:r.allowSynchronousEvents,binaryType:this.binaryType,extensions:this._extensions,isServer:this._isServer,maxPayload:r.maxPayload,skipUTF8Validation:r.skipUTF8Validation}),i=new Ba(e,this._extensions,r.generateMask);this._receiver=s,this._sender=i,this._socket=e,s[I]=this,i[I]=this,e[I]=this,s.on("conclude",Qa),s.on("drain",Ka),s.on("error",Za),s.on("message",Xa),s.on("ping",eu),s.on("pong",tu),i.onerror=ru,e.setTimeout&&e.setTimeout(0),e.setNoDelay&&e.setNoDelay(),t.length>0&&e.unshift(t),e.on("close",bi),e.on("data",It),e.on("end",Ei),e.on("error",Ci),this._readyState=n.OPEN,this.emit("open")}emitClose(){if(!this._socket){this._readyState=n.CLOSED,this.emit("close",this._closeCode,this._closeMessage);return}this._extensions[ce.extensionName]&&this._extensions[ce.extensionName].cleanup(),this._receiver.removeAllListeners(),this._readyState=n.CLOSED,this.emit("close",this._closeCode,this._closeMessage)}close(e,t){if(this.readyState!==n.CLOSED){if(this.readyState===n.CONNECTING){q(this,this._req,"WebSocket was closed before the connection was established");return}if(this.readyState===n.CLOSING){this._closeFrameSent&&(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end();return}this._readyState=n.CLOSING,this._sender.close(e,t,!this._isServer,r=>{r||(this._closeFrameSent=!0,(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end())}),xi(this)}}pause(){this.readyState===n.CONNECTING||this.readyState===n.CLOSED||(this._paused=!0,this._socket.pause())}ping(e,t,r){if(this.readyState===n.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if(typeof e=="function"?(r=e,e=t=void 0):typeof t=="function"&&(r=t,t=void 0),typeof e=="number"&&(e=e.toString()),this.readyState!==n.OPEN){Wr(this,e,r);return}t===void 0&&(t=!this._isServer),this._sender.ping(e||Pt,t,r)}pong(e,t,r){if(this.readyState===n.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if(typeof e=="function"?(r=e,e=t=void 0):typeof t=="function"&&(r=t,t=void 0),typeof e=="number"&&(e=e.toString()),this.readyState!==n.OPEN){Wr(this,e,r);return}t===void 0&&(t=!this._isServer),this._sender.pong(e||Pt,t,r)}resume(){this.readyState===n.CONNECTING||this.readyState===n.CLOSED||(this._paused=!1,this._receiver._writableState.needDrain||this._socket.resume())}send(e,t,r){if(this.readyState===n.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if(typeof t=="function"&&(r=t,t={}),typeof e=="number"&&(e=e.toString()),this.readyState!==n.OPEN){Wr(this,e,r);return}let s={binary:typeof e!="string",mask:!this._isServer,compress:!0,fin:!0,...t};this._extensions[ce.extensionName]||(s.compress=!1),this._sender.send(e||Pt,s,r)}terminate(){if(this.readyState!==n.CLOSED){if(this.readyState===n.CONNECTING){q(this,this._req,"WebSocket was closed before the connection was established");return}this._socket&&(this._readyState=n.CLOSING,this._socket.destroy())}}};Object.defineProperty(L,"CONNECTING",{enumerable:!0,value:le.indexOf("CONNECTING")});Object.defineProperty(L.prototype,"CONNECTING",{enumerable:!0,value:le.indexOf("CONNECTING")});Object.defineProperty(L,"OPEN",{enumerable:!0,value:le.indexOf("OPEN")});Object.defineProperty(L.prototype,"OPEN",{enumerable:!0,value:le.indexOf("OPEN")});Object.defineProperty(L,"CLOSING",{enumerable:!0,value:le.indexOf("CLOSING")});Object.defineProperty(L.prototype,"CLOSING",{enumerable:!0,value:le.indexOf("CLOSING")});Object.defineProperty(L,"CLOSED",{enumerable:!0,value:le.indexOf("CLOSED")});Object.defineProperty(L.prototype,"CLOSED",{enumerable:!0,value:le.indexOf("CLOSED")});["binaryType","bufferedAmount","extensions","isPaused","protocol","readyState","url"].forEach(n=>{Object.defineProperty(L.prototype,n,{enumerable:!0})});["open","error","close","message"].forEach(n=>{Object.defineProperty(L.prototype,`on${n}`,{enumerable:!0,get(){for(let e of this.listeners(n))if(e[Ur])return e[Da];return null},set(e){for(let t of this.listeners(n))if(t[Ur]){this.removeListener(n,t);break}typeof e=="function"&&this.addEventListener(n,e,{[Ur]:!0})}})});L.prototype.addEventListener=ja;L.prototype.removeEventListener=$a;Oi.exports=L;function Si(n,e,t,r){let s={allowSynchronousEvents:!0,autoPong:!0,protocolVersion:Dr[1],maxPayload:104857600,skipUTF8Validation:!1,perMessageDeflate:!0,followRedirects:!1,maxRedirects:10,...r,socketPath:void 0,hostname:void 0,protocol:void 0,timeout:void 0,method:"GET",host:void 0,path:void 0,port:void 0};if(n._autoPong=s.autoPong,!Dr.includes(s.protocolVersion))throw new RangeError(`Unsupported protocol version: ${s.protocolVersion} (supported versions: ${Dr.join(", ")})`);let i;if(e instanceof Fr)i=e;else try{i=new Fr(e)}catch{throw new SyntaxError(`Invalid URL: ${e}`)}i.protocol==="http:"?i.protocol="ws:":i.protocol==="https:"&&(i.protocol="wss:"),n._url=i.href;let o=i.protocol==="wss:",l=i.protocol==="ws+unix:",u;if(i.protocol!=="ws:"&&!o&&!l?u=`The URL's protocol must be one of "ws:", "wss:", "http:", "https", or "ws+unix:"`:l&&!i.pathname?u="The URL's pathname is empty":i.hash&&(u="The URL contains a fragment identifier"),u){let d=new SyntaxError(u);if(n._redirects===0)throw d;kt(n,d);return}let a=o?443:80,f=Pa(16).toString("base64"),h=o?Na.request:Ra.request,c=new Set,p;if(s.createConnection=s.createConnection||(o?Ja:Ya),s.defaultPort=s.defaultPort||a,s.port=i.port||a,s.host=i.hostname.startsWith("[")?i.hostname.slice(1,-1):i.hostname,s.headers={...s.headers,"Sec-WebSocket-Version":s.protocolVersion,"Sec-WebSocket-Key":f,Connection:"Upgrade",Upgrade:"websocket"},s.path=i.pathname+i.search,s.timeout=s.handshakeTimeout,s.perMessageDeflate&&(p=new ce(s.perMessageDeflate!==!0?s.perMessageDeflate:{},!1,s.maxPayload),s.headers["Sec-WebSocket-Extensions"]=qa({[ce.extensionName]:p.offer()})),t.length){for(let d of t){if(typeof d!="string"||!Ha.test(d)||c.has(d))throw new SyntaxError("An invalid or duplicated subprotocol was specified");c.add(d)}s.headers["Sec-WebSocket-Protocol"]=t.join(",")}if(s.origin&&(s.protocolVersion<13?s.headers["Sec-WebSocket-Origin"]=s.origin:s.headers.Origin=s.origin),(i.username||i.password)&&(s.auth=`${i.username}:${i.password}`),l){let d=s.path.split(":");s.socketPath=d[0],s.path=d[1]}let m;if(s.followRedirects){if(n._redirects===0){n._originalIpc=l,n._originalSecure=o,n._originalHostOrSocketPath=l?s.socketPath:i.host;let d=r&&r.headers;if(r={...r,headers:{}},d)for(let[g,y]of Object.entries(d))r.headers[g.toLowerCase()]=y}else if(n.listenerCount("redirect")===0){let d=l?n._originalIpc?s.socketPath===n._originalHostOrSocketPath:!1:n._originalIpc?!1:i.host===n._originalHostOrSocketPath;(!d||n._originalSecure&&!o)&&(delete s.headers.authorization,delete s.headers.cookie,d||delete s.headers.host,s.auth=void 0)}s.auth&&!r.headers.authorization&&(r.headers.authorization="Basic "+Buffer.from(s.auth).toString("base64")),m=n._req=h(s),n._redirects&&n.emit("redirect",n.url,m)}else m=n._req=h(s);s.timeout&&m.on("timeout",()=>{q(n,m,"Opening handshake has timed out")}),m.on("error",d=>{m===null||m[wi]||(m=n._req=null,kt(n,d))}),m.on("response",d=>{let g=d.headers.location,y=d.statusCode;if(g&&s.followRedirects&&y>=300&&y<400){if(++n._redirects>s.maxRedirects){q(n,m,"Maximum redirects exceeded");return}m.abort();let w;try{w=new Fr(g,e)}catch{let v=new SyntaxError(`Invalid URL: ${g}`);kt(n,v);return}Si(n,w,t,r)}else n.emit("unexpected-response",m,d)||q(n,m,`Unexpected server response: ${d.statusCode}`)}),m.on("upgrade",(d,g,y)=>{if(n.emit("upgrade",d),n.readyState!==L.CONNECTING)return;m=n._req=null;let w=d.headers.upgrade;if(w===void 0||w.toLowerCase()!=="websocket"){q(n,g,"Invalid Upgrade header");return}let b=ka("sha1").update(f+Ua).digest("base64");if(d.headers["sec-websocket-accept"]!==b){q(n,g,"Invalid Sec-WebSocket-Accept header");return}let v=d.headers["sec-websocket-protocol"],E;if(v!==void 0?c.size?c.has(v)||(E="Server sent an invalid subprotocol"):E="Server sent a subprotocol but none was requested":c.size&&(E="Server sent no subprotocol"),E){q(n,g,E);return}v&&(n._protocol=v);let x=d.headers["sec-websocket-extensions"];if(x!==void 0){if(!p){q(n,g,"Server sent a Sec-WebSocket-Extensions header but no extension was requested");return}let M;try{M=Ga(x)}catch{q(n,g,"Invalid Sec-WebSocket-Extensions header");return}let N=Object.keys(M);if(N.length!==1||N[0]!==ce.extensionName){q(n,g,"Server indicated an extension that was not requested");return}try{p.accept(M[ce.extensionName])}catch{q(n,g,"Invalid Sec-WebSocket-Extensions header");return}n._extensions[ce.extensionName]=p}n.setSocket(g,y,{allowSynchronousEvents:s.allowSynchronousEvents,generateMask:s.generateMask,maxPayload:s.maxPayload,skipUTF8Validation:s.skipUTF8Validation})}),s.finishRequest?s.finishRequest(m,n):m.end()}function kt(n,e){n._readyState=L.CLOSING,n._errorEmitted=!0,n.emit("error",e),n.emitClose()}function Ya(n){return n.path=n.socketPath,_i.connect(n)}function Ja(n){return n.path=void 0,!n.servername&&n.servername!==""&&(n.servername=_i.isIP(n.host)?"":n.host),Ma.connect(n)}function q(n,e,t){n._readyState=L.CLOSING;let r=new Error(t);Error.captureStackTrace(r,q),e.setHeader?(e[wi]=!0,e.abort(),e.socket&&!e.socket.destroyed&&e.socket.destroy(),process.nextTick(kt,n,r)):(e.destroy(r),e.once("error",n.emit.bind(n,"error")),e.once("close",n.emitClose.bind(n)))}function Wr(n,e,t){if(e){let r=Fa(e)?e.size:za(e).length;n._socket?n._sender._bufferedBytes+=r:n._bufferedAmount+=r}if(t){let r=new Error(`WebSocket is not open: readyState ${n.readyState} (${le[n.readyState]})`);process.nextTick(t,r)}}function Qa(n,e){let t=this[I];t._closeFrameReceived=!0,t._closeMessage=e,t._closeCode=n,t._socket[I]!==void 0&&(t._socket.removeListener("data",It),process.nextTick(vi,t._socket),n===1005?t.close():t.close(n,e))}function Ka(){let n=this[I];n.isPaused||n._socket.resume()}function Za(n){let e=this[I];e._socket[I]!==void 0&&(e._socket.removeListener("data",It),process.nextTick(vi,e._socket),e.close(n[Wa])),e._errorEmitted||(e._errorEmitted=!0,e.emit("error",n))}function gi(){this[I].emitClose()}function Xa(n,e){this[I].emit("message",n,e)}function eu(n){let e=this[I];e._autoPong&&e.pong(n,!this._isServer,yi),e.emit("ping",n)}function tu(n){this[I].emit("pong",n)}function vi(n){n.resume()}function ru(n){let e=this[I];e.readyState!==L.CLOSED&&(e.readyState===L.OPEN&&(e._readyState=L.CLOSING,xi(e)),this._socket.end(),e._errorEmitted||(e._errorEmitted=!0,e.emit("error",n)))}function xi(n){n._closeTimer=setTimeout(n._socket.destroy.bind(n._socket),Va)}function bi(){let n=this[I];this.removeListener("close",bi),this.removeListener("data",It),this.removeListener("end",Ei),n._readyState=L.CLOSING;let e;!this._readableState.endEmitted&&!n._closeFrameReceived&&!n._receiver._writableState.errorEmitted&&(e=n._socket.read())!==null&&n._receiver.write(e),n._receiver.end(),this[I]=void 0,clearTimeout(n._closeTimer),n._receiver._writableState.finished||n._receiver._writableState.errorEmitted?n.emitClose():(n._receiver.on("error",gi),n._receiver.on("finish",gi))}function It(n){this[I]._receiver.write(n)||this.pause()}function Ei(){let n=this[I];n._readyState=L.CLOSING,n._receiver.end(),this.end()}function Ci(){let n=this[I];this.removeListener("error",Ci),this.on("error",yi),n&&(n._readyState=L.CLOSING,this.destroy())}});var Ti=S((mc,Li)=>{"use strict";var{tokenChars:nu}=Ae();function su(n){let e=new Set,t=-1,r=-1,s=0;for(s;s<n.length;s++){let o=n.charCodeAt(s);if(r===-1&&nu[o]===1)t===-1&&(t=s);else if(s!==0&&(o===32||o===9))r===-1&&t!==-1&&(r=s);else if(o===44){if(t===-1)throw new SyntaxError(`Unexpected character at index ${s}`);r===-1&&(r=s);let l=n.slice(t,r);if(e.has(l))throw new SyntaxError(`The "${l}" subprotocol is duplicated`);e.add(l),t=r=-1}else throw new SyntaxError(`Unexpected character at index ${s}`)}if(t===-1||r!==-1)throw new SyntaxError("Unexpected end of input");let i=n.slice(t,s);if(e.has(i))throw new SyntaxError(`The "${i}" subprotocol is duplicated`);return e.add(i),e}Li.exports={parse:su}});var Ii=S((_c,ki)=>{"use strict";var iu=require("events"),Bt=require("http"),{Duplex:gc}=require("stream"),{createHash:ou}=require("crypto"),Ai=Br(),we=Ke(),lu=Ti(),au=jr(),{GUID:uu,kWebSocket:fu}=se(),cu=/^[+/0-9A-Za-z]{22}==$/,Ni=0,Ri=1,Pi=2,$r=class extends iu{constructor(e,t){if(super(),e={allowSynchronousEvents:!0,autoPong:!0,maxPayload:100*1024*1024,skipUTF8Validation:!1,perMessageDeflate:!1,handleProtocols:null,clientTracking:!0,verifyClient:null,noServer:!1,backlog:null,server:null,host:null,path:null,port:null,WebSocket:au,...e},e.port==null&&!e.server&&!e.noServer||e.port!=null&&(e.server||e.noServer)||e.server&&e.noServer)throw new TypeError('One and only one of the "port", "server", or "noServer" options must be specified');if(e.port!=null?(this._server=Bt.createServer((r,s)=>{let i=Bt.STATUS_CODES[426];s.writeHead(426,{"Content-Length":i.length,"Content-Type":"text/plain"}),s.end(i)}),this._server.listen(e.port,e.host,e.backlog,t)):e.server&&(this._server=e.server),this._server){let r=this.emit.bind(this,"connection");this._removeListeners=hu(this._server,{listening:this.emit.bind(this,"listening"),error:this.emit.bind(this,"error"),upgrade:(s,i,o)=>{this.handleUpgrade(s,i,o,r)}})}e.perMessageDeflate===!0&&(e.perMessageDeflate={}),e.clientTracking&&(this.clients=new Set,this._shouldEmitClose=!1),this.options=e,this._state=Ni}address(){if(this.options.noServer)throw new Error('The server is operating in "noServer" mode');return this._server?this._server.address():null}close(e){if(this._state===Pi){e&&this.once("close",()=>{e(new Error("The server is not running"))}),process.nextTick(tt,this);return}if(e&&this.once("close",e),this._state!==Ri)if(this._state=Ri,this.options.noServer||this.options.server)this._server&&(this._removeListeners(),this._removeListeners=this._server=null),this.clients?this.clients.size?this._shouldEmitClose=!0:process.nextTick(tt,this):process.nextTick(tt,this);else{let t=this._server;this._removeListeners(),this._removeListeners=this._server=null,t.close(()=>{tt(this)})}}shouldHandle(e){if(this.options.path){let t=e.url.indexOf("?");if((t!==-1?e.url.slice(0,t):e.url)!==this.options.path)return!1}return!0}handleUpgrade(e,t,r,s){t.on("error",Mi);let i=e.headers["sec-websocket-key"],o=e.headers.upgrade,l=+e.headers["sec-websocket-version"];if(e.method!=="GET"){Se(this,e,t,405,"Invalid HTTP method");return}if(o===void 0||o.toLowerCase()!=="websocket"){Se(this,e,t,400,"Invalid Upgrade header");return}if(i===void 0||!cu.test(i)){Se(this,e,t,400,"Missing or invalid Sec-WebSocket-Key header");return}if(l!==8&&l!==13){Se(this,e,t,400,"Missing or invalid Sec-WebSocket-Version header");return}if(!this.shouldHandle(e)){rt(t,400);return}let u=e.headers["sec-websocket-protocol"],a=new Set;if(u!==void 0)try{a=lu.parse(u)}catch{Se(this,e,t,400,"Invalid Sec-WebSocket-Protocol header");return}let f=e.headers["sec-websocket-extensions"],h={};if(this.options.perMessageDeflate&&f!==void 0){let c=new we(this.options.perMessageDeflate,!0,this.options.maxPayload);try{let p=Ai.parse(f);p[we.extensionName]&&(c.accept(p[we.extensionName]),h[we.extensionName]=c)}catch{Se(this,e,t,400,"Invalid or unacceptable Sec-WebSocket-Extensions header");return}}if(this.options.verifyClient){let c={origin:e.headers[`${l===8?"sec-websocket-origin":"origin"}`],secure:!!(e.socket.authorized||e.socket.encrypted),req:e};if(this.options.verifyClient.length===2){this.options.verifyClient(c,(p,m,d,g)=>{if(!p)return rt(t,m||401,d,g);this.completeUpgrade(h,i,a,e,t,r,s)});return}if(!this.options.verifyClient(c))return rt(t,401)}this.completeUpgrade(h,i,a,e,t,r,s)}completeUpgrade(e,t,r,s,i,o,l){if(!i.readable||!i.writable)return i.destroy();if(i[fu])throw new Error("server.handleUpgrade() was called more than once with the same socket, possibly due to a misconfiguration");if(this._state>Ni)return rt(i,503);let a=["HTTP/1.1 101 Switching Protocols","Upgrade: websocket","Connection: Upgrade",`Sec-WebSocket-Accept: ${ou("sha1").update(t+uu).digest("base64")}`],f=new this.options.WebSocket(null,void 0,this.options);if(r.size){let h=this.options.handleProtocols?this.options.handleProtocols(r,s):r.values().next().value;h&&(a.push(`Sec-WebSocket-Protocol: ${h}`),f._protocol=h)}if(e[we.extensionName]){let h=e[we.extensionName].params,c=Ai.format({[we.extensionName]:[h]});a.push(`Sec-WebSocket-Extensions: ${c}`),f._extensions=e}this.emit("headers",a,s),i.write(a.concat(`\r
|
|
25
|
+
You tried to parse Less with the standard CSS parser; try again with the postcss-less parser`)),s}return r.root}Ns.exports=bt;bt.default=bt;Vl.registerParse(bt)});var Is=S((tc,ks)=>{"use strict";var{Duplex:Jl}=require("stream");function Rs(n){n.emit("close")}function Ql(){!this.destroyed&&this._writableState.finished&&this.destroy()}function Ps(n){this.removeListener("error",Ps),this.destroy(),this.listenerCount("error")===0&&this.emit("error",n)}function Kl(n,e){let t=!0,r=new Jl({...e,autoDestroy:!1,emitClose:!1,objectMode:!1,writableObjectMode:!1});return n.on("message",function(i,o){let l=!o&&r._readableState.objectMode?i.toString():i;r.push(l)||n.pause()}),n.once("error",function(i){r.destroyed||(t=!1,r.destroy(i))}),n.once("close",function(){r.destroyed||r.push(null)}),r._destroy=function(s,i){if(n.readyState===n.CLOSED){i(s),process.nextTick(Rs,r);return}let o=!1;n.once("error",function(u){o=!0,i(u)}),n.once("close",function(){o||i(s),process.nextTick(Rs,r)}),t&&n.terminate()},r._final=function(s){if(n.readyState===n.CONNECTING){n.once("open",function(){r._final(s)});return}n._socket!==null&&(n._socket._writableState.finished?(s(),r._readableState.endEmitted&&r.destroy()):(n._socket.once("finish",function(){s()}),n.close()))},r._read=function(){n.isPaused&&n.resume()},r._write=function(s,i,o){if(n.readyState===n.CONNECTING){n.once("open",function(){r._write(s,i,o)});return}n.send(s,o)},r.on("end",Ql),r.on("error",Ps),r}ks.exports=Kl});var se=S((rc,Us)=>{"use strict";var Bs=["nodebuffer","arraybuffer","fragments"],Fs=typeof Blob<"u";Fs&&Bs.push("blob");Us.exports={BINARY_TYPES:Bs,EMPTY_BUFFER:Buffer.alloc(0),GUID:"258EAFA5-E914-47DA-95CA-C5AB0DC85B11",hasBlob:Fs,kForOnEventAttribute:Symbol("kIsForOnEventAttribute"),kListener:Symbol("kListener"),kStatusCode:Symbol("status-code"),kWebSocket:Symbol("websocket"),NOOP:()=>{}}});var Ye=S((nc,Et)=>{"use strict";var{EMPTY_BUFFER:Zl}=se(),vr=Buffer[Symbol.species];function Xl(n,e){if(n.length===0)return Zl;if(n.length===1)return n[0];let t=Buffer.allocUnsafe(e),r=0;for(let s=0;s<n.length;s++){let i=n[s];t.set(i,r),r+=i.length}return r<e?new vr(t.buffer,t.byteOffset,r):t}function Ds(n,e,t,r,s){for(let i=0;i<s;i++)t[r+i]=n[i]^e[i&3]}function Ws(n,e){for(let t=0;t<n.length;t++)n[t]^=e[t&3]}function ea(n){return n.length===n.buffer.byteLength?n.buffer:n.buffer.slice(n.byteOffset,n.byteOffset+n.length)}function xr(n){if(xr.readOnly=!0,Buffer.isBuffer(n))return n;let e;return n instanceof ArrayBuffer?e=new vr(n):ArrayBuffer.isView(n)?e=new vr(n.buffer,n.byteOffset,n.byteLength):(e=Buffer.from(n),xr.readOnly=!1),e}Et.exports={concat:Xl,mask:Ds,toArrayBuffer:ea,toBuffer:xr,unmask:Ws};if(!process.env.WS_NO_BUFFER_UTIL)try{let n=require("bufferutil");Et.exports.mask=function(e,t,r,s,i){i<48?Ds(e,t,r,s,i):n.mask(e,t,r,s,i)},Et.exports.unmask=function(e,t){e.length<32?Ws(e,t):n.unmask(e,t)}}catch{}});var qs=S((sc,$s)=>{"use strict";var js=Symbol("kDone"),br=Symbol("kRun"),Er=class{constructor(e){this[js]=()=>{this.pending--,this[br]()},this.concurrency=e||1/0,this.jobs=[],this.pending=0}add(e){this.jobs.push(e),this[br]()}[br](){if(this.pending!==this.concurrency&&this.jobs.length){let e=this.jobs.shift();this.pending++,e(this[js])}}};$s.exports=Er});var Ke=S((ic,Hs)=>{"use strict";var Je=require("zlib"),Gs=Ye(),ta=qs(),{kStatusCode:zs}=se(),ra=Buffer[Symbol.species],na=Buffer.from([0,0,255,255]),Lt=Symbol("permessage-deflate"),ie=Symbol("total-length"),Qe=Symbol("callback"),fe=Symbol("buffers"),Ot=Symbol("error"),Ct,Cr=class{constructor(e,t,r){if(this._maxPayload=r|0,this._options=e||{},this._threshold=this._options.threshold!==void 0?this._options.threshold:1024,this._isServer=!!t,this._deflate=null,this._inflate=null,this.params=null,!Ct){let s=this._options.concurrencyLimit!==void 0?this._options.concurrencyLimit:10;Ct=new ta(s)}}static get extensionName(){return"permessage-deflate"}offer(){let e={};return this._options.serverNoContextTakeover&&(e.server_no_context_takeover=!0),this._options.clientNoContextTakeover&&(e.client_no_context_takeover=!0),this._options.serverMaxWindowBits&&(e.server_max_window_bits=this._options.serverMaxWindowBits),this._options.clientMaxWindowBits?e.client_max_window_bits=this._options.clientMaxWindowBits:this._options.clientMaxWindowBits==null&&(e.client_max_window_bits=!0),e}accept(e){return e=this.normalizeParams(e),this.params=this._isServer?this.acceptAsServer(e):this.acceptAsClient(e),this.params}cleanup(){if(this._inflate&&(this._inflate.close(),this._inflate=null),this._deflate){let e=this._deflate[Qe];this._deflate.close(),this._deflate=null,e&&e(new Error("The deflate stream was closed while data was being processed"))}}acceptAsServer(e){let t=this._options,r=e.find(s=>!(t.serverNoContextTakeover===!1&&s.server_no_context_takeover||s.server_max_window_bits&&(t.serverMaxWindowBits===!1||typeof t.serverMaxWindowBits=="number"&&t.serverMaxWindowBits>s.server_max_window_bits)||typeof t.clientMaxWindowBits=="number"&&!s.client_max_window_bits));if(!r)throw new Error("None of the extension offers can be accepted");return t.serverNoContextTakeover&&(r.server_no_context_takeover=!0),t.clientNoContextTakeover&&(r.client_no_context_takeover=!0),typeof t.serverMaxWindowBits=="number"&&(r.server_max_window_bits=t.serverMaxWindowBits),typeof t.clientMaxWindowBits=="number"?r.client_max_window_bits=t.clientMaxWindowBits:(r.client_max_window_bits===!0||t.clientMaxWindowBits===!1)&&delete r.client_max_window_bits,r}acceptAsClient(e){let t=e[0];if(this._options.clientNoContextTakeover===!1&&t.client_no_context_takeover)throw new Error('Unexpected parameter "client_no_context_takeover"');if(!t.client_max_window_bits)typeof this._options.clientMaxWindowBits=="number"&&(t.client_max_window_bits=this._options.clientMaxWindowBits);else if(this._options.clientMaxWindowBits===!1||typeof this._options.clientMaxWindowBits=="number"&&t.client_max_window_bits>this._options.clientMaxWindowBits)throw new Error('Unexpected or invalid parameter "client_max_window_bits"');return t}normalizeParams(e){return e.forEach(t=>{Object.keys(t).forEach(r=>{let s=t[r];if(s.length>1)throw new Error(`Parameter "${r}" must have only a single value`);if(s=s[0],r==="client_max_window_bits"){if(s!==!0){let i=+s;if(!Number.isInteger(i)||i<8||i>15)throw new TypeError(`Invalid value for parameter "${r}": ${s}`);s=i}else if(!this._isServer)throw new TypeError(`Invalid value for parameter "${r}": ${s}`)}else if(r==="server_max_window_bits"){let i=+s;if(!Number.isInteger(i)||i<8||i>15)throw new TypeError(`Invalid value for parameter "${r}": ${s}`);s=i}else if(r==="client_no_context_takeover"||r==="server_no_context_takeover"){if(s!==!0)throw new TypeError(`Invalid value for parameter "${r}": ${s}`)}else throw new Error(`Unknown parameter "${r}"`);t[r]=s})}),e}decompress(e,t,r){Ct.add(s=>{this._decompress(e,t,(i,o)=>{s(),r(i,o)})})}compress(e,t,r){Ct.add(s=>{this._compress(e,t,(i,o)=>{s(),r(i,o)})})}_decompress(e,t,r){let s=this._isServer?"client":"server";if(!this._inflate){let i=`${s}_max_window_bits`,o=typeof this.params[i]!="number"?Je.Z_DEFAULT_WINDOWBITS:this.params[i];this._inflate=Je.createInflateRaw({...this._options.zlibInflateOptions,windowBits:o}),this._inflate[Lt]=this,this._inflate[ie]=0,this._inflate[fe]=[],this._inflate.on("error",ia),this._inflate.on("data",Vs)}this._inflate[Qe]=r,this._inflate.write(e),t&&this._inflate.write(na),this._inflate.flush(()=>{let i=this._inflate[Ot];if(i){this._inflate.close(),this._inflate=null,r(i);return}let o=Gs.concat(this._inflate[fe],this._inflate[ie]);this._inflate._readableState.endEmitted?(this._inflate.close(),this._inflate=null):(this._inflate[ie]=0,this._inflate[fe]=[],t&&this.params[`${s}_no_context_takeover`]&&this._inflate.reset()),r(null,o)})}_compress(e,t,r){let s=this._isServer?"server":"client";if(!this._deflate){let i=`${s}_max_window_bits`,o=typeof this.params[i]!="number"?Je.Z_DEFAULT_WINDOWBITS:this.params[i];this._deflate=Je.createDeflateRaw({...this._options.zlibDeflateOptions,windowBits:o}),this._deflate[ie]=0,this._deflate[fe]=[],this._deflate.on("data",sa)}this._deflate[Qe]=r,this._deflate.write(e),this._deflate.flush(Je.Z_SYNC_FLUSH,()=>{if(!this._deflate)return;let i=Gs.concat(this._deflate[fe],this._deflate[ie]);t&&(i=new ra(i.buffer,i.byteOffset,i.length-4)),this._deflate[Qe]=null,this._deflate[ie]=0,this._deflate[fe]=[],t&&this.params[`${s}_no_context_takeover`]&&this._deflate.reset(),r(null,i)})}};Hs.exports=Cr;function sa(n){this[fe].push(n),this[ie]+=n.length}function Vs(n){if(this[ie]+=n.length,this[Lt]._maxPayload<1||this[ie]<=this[Lt]._maxPayload){this[fe].push(n);return}this[Ot]=new RangeError("Max payload size exceeded"),this[Ot].code="WS_ERR_UNSUPPORTED_MESSAGE_LENGTH",this[Ot][zs]=1009,this.removeListener("data",Vs),this.reset()}function ia(n){this[Lt]._inflate=null,n[zs]=1007,this[Qe](n)}});var Ae=S((oc,Tt)=>{"use strict";var{isUtf8:Ys}=require("buffer"),{hasBlob:oa}=se(),la=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,0,0,1,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,0];function aa(n){return n>=1e3&&n<=1014&&n!==1004&&n!==1005&&n!==1006||n>=3e3&&n<=4999}function Or(n){let e=n.length,t=0;for(;t<e;)if(!(n[t]&128))t++;else if((n[t]&224)===192){if(t+1===e||(n[t+1]&192)!==128||(n[t]&254)===192)return!1;t+=2}else if((n[t]&240)===224){if(t+2>=e||(n[t+1]&192)!==128||(n[t+2]&192)!==128||n[t]===224&&(n[t+1]&224)===128||n[t]===237&&(n[t+1]&224)===160)return!1;t+=3}else if((n[t]&248)===240){if(t+3>=e||(n[t+1]&192)!==128||(n[t+2]&192)!==128||(n[t+3]&192)!==128||n[t]===240&&(n[t+1]&240)===128||n[t]===244&&n[t+1]>143||n[t]>244)return!1;t+=4}else return!1;return!0}function ua(n){return oa&&typeof n=="object"&&typeof n.arrayBuffer=="function"&&typeof n.type=="string"&&typeof n.stream=="function"&&(n[Symbol.toStringTag]==="Blob"||n[Symbol.toStringTag]==="File")}Tt.exports={isBlob:ua,isValidStatusCode:aa,isValidUTF8:Or,tokenChars:la};if(Ys)Tt.exports.isValidUTF8=function(n){return n.length<24?Or(n):Ys(n)};else if(!process.env.WS_NO_UTF_8_VALIDATE)try{let n=require("utf-8-validate");Tt.exports.isValidUTF8=function(e){return e.length<32?Or(e):n(e)}}catch{}});var Mr=S((lc,ti)=>{"use strict";var{Writable:fa}=require("stream"),Js=Ke(),{BINARY_TYPES:ca,EMPTY_BUFFER:Qs,kStatusCode:ha,kWebSocket:pa}=se(),{concat:Lr,toArrayBuffer:da,unmask:ma}=Ye(),{isValidStatusCode:ga,isValidUTF8:Ks}=Ae(),At=Buffer[Symbol.species],V=0,Zs=1,Xs=2,ei=3,Tr=4,Ar=5,Nt=6,Nr=class extends fa{constructor(e={}){super(),this._allowSynchronousEvents=e.allowSynchronousEvents!==void 0?e.allowSynchronousEvents:!0,this._binaryType=e.binaryType||ca[0],this._extensions=e.extensions||{},this._isServer=!!e.isServer,this._maxPayload=e.maxPayload|0,this._skipUTF8Validation=!!e.skipUTF8Validation,this[pa]=void 0,this._bufferedBytes=0,this._buffers=[],this._compressed=!1,this._payloadLength=0,this._mask=void 0,this._fragmented=0,this._masked=!1,this._fin=!1,this._opcode=0,this._totalPayloadLength=0,this._messageLength=0,this._fragments=[],this._errored=!1,this._loop=!1,this._state=V}_write(e,t,r){if(this._opcode===8&&this._state==V)return r();this._bufferedBytes+=e.length,this._buffers.push(e),this.startLoop(r)}consume(e){if(this._bufferedBytes-=e,e===this._buffers[0].length)return this._buffers.shift();if(e<this._buffers[0].length){let r=this._buffers[0];return this._buffers[0]=new At(r.buffer,r.byteOffset+e,r.length-e),new At(r.buffer,r.byteOffset,e)}let t=Buffer.allocUnsafe(e);do{let r=this._buffers[0],s=t.length-e;e>=r.length?t.set(this._buffers.shift(),s):(t.set(new Uint8Array(r.buffer,r.byteOffset,e),s),this._buffers[0]=new At(r.buffer,r.byteOffset+e,r.length-e)),e-=r.length}while(e>0);return t}startLoop(e){this._loop=!0;do switch(this._state){case V:this.getInfo(e);break;case Zs:this.getPayloadLength16(e);break;case Xs:this.getPayloadLength64(e);break;case ei:this.getMask();break;case Tr:this.getData(e);break;case Ar:case Nt:this._loop=!1;return}while(this._loop);this._errored||e()}getInfo(e){if(this._bufferedBytes<2){this._loop=!1;return}let t=this.consume(2);if(t[0]&48){let s=this.createError(RangeError,"RSV2 and RSV3 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_2_3");e(s);return}let r=(t[0]&64)===64;if(r&&!this._extensions[Js.extensionName]){let s=this.createError(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");e(s);return}if(this._fin=(t[0]&128)===128,this._opcode=t[0]&15,this._payloadLength=t[1]&127,this._opcode===0){if(r){let s=this.createError(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");e(s);return}if(!this._fragmented){let s=this.createError(RangeError,"invalid opcode 0",!0,1002,"WS_ERR_INVALID_OPCODE");e(s);return}this._opcode=this._fragmented}else if(this._opcode===1||this._opcode===2){if(this._fragmented){let s=this.createError(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");e(s);return}this._compressed=r}else if(this._opcode>7&&this._opcode<11){if(!this._fin){let s=this.createError(RangeError,"FIN must be set",!0,1002,"WS_ERR_EXPECTED_FIN");e(s);return}if(r){let s=this.createError(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");e(s);return}if(this._payloadLength>125||this._opcode===8&&this._payloadLength===1){let s=this.createError(RangeError,`invalid payload length ${this._payloadLength}`,!0,1002,"WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH");e(s);return}}else{let s=this.createError(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");e(s);return}if(!this._fin&&!this._fragmented&&(this._fragmented=this._opcode),this._masked=(t[1]&128)===128,this._isServer){if(!this._masked){let s=this.createError(RangeError,"MASK must be set",!0,1002,"WS_ERR_EXPECTED_MASK");e(s);return}}else if(this._masked){let s=this.createError(RangeError,"MASK must be clear",!0,1002,"WS_ERR_UNEXPECTED_MASK");e(s);return}this._payloadLength===126?this._state=Zs:this._payloadLength===127?this._state=Xs:this.haveLength(e)}getPayloadLength16(e){if(this._bufferedBytes<2){this._loop=!1;return}this._payloadLength=this.consume(2).readUInt16BE(0),this.haveLength(e)}getPayloadLength64(e){if(this._bufferedBytes<8){this._loop=!1;return}let t=this.consume(8),r=t.readUInt32BE(0);if(r>Math.pow(2,21)-1){let s=this.createError(RangeError,"Unsupported WebSocket frame: payload length > 2^53 - 1",!1,1009,"WS_ERR_UNSUPPORTED_DATA_PAYLOAD_LENGTH");e(s);return}this._payloadLength=r*Math.pow(2,32)+t.readUInt32BE(4),this.haveLength(e)}haveLength(e){if(this._payloadLength&&this._opcode<8&&(this._totalPayloadLength+=this._payloadLength,this._totalPayloadLength>this._maxPayload&&this._maxPayload>0)){let t=this.createError(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH");e(t);return}this._masked?this._state=ei:this._state=Tr}getMask(){if(this._bufferedBytes<4){this._loop=!1;return}this._mask=this.consume(4),this._state=Tr}getData(e){let t=Qs;if(this._payloadLength){if(this._bufferedBytes<this._payloadLength){this._loop=!1;return}t=this.consume(this._payloadLength),this._masked&&this._mask[0]|this._mask[1]|this._mask[2]|this._mask[3]&&ma(t,this._mask)}if(this._opcode>7){this.controlMessage(t,e);return}if(this._compressed){this._state=Ar,this.decompress(t,e);return}t.length&&(this._messageLength=this._totalPayloadLength,this._fragments.push(t)),this.dataMessage(e)}decompress(e,t){this._extensions[Js.extensionName].decompress(e,this._fin,(s,i)=>{if(s)return t(s);if(i.length){if(this._messageLength+=i.length,this._messageLength>this._maxPayload&&this._maxPayload>0){let o=this.createError(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH");t(o);return}this._fragments.push(i)}this.dataMessage(t),this._state===V&&this.startLoop(t)})}dataMessage(e){if(!this._fin){this._state=V;return}let t=this._messageLength,r=this._fragments;if(this._totalPayloadLength=0,this._messageLength=0,this._fragmented=0,this._fragments=[],this._opcode===2){let s;this._binaryType==="nodebuffer"?s=Lr(r,t):this._binaryType==="arraybuffer"?s=da(Lr(r,t)):this._binaryType==="blob"?s=new Blob(r):s=r,this._allowSynchronousEvents?(this.emit("message",s,!0),this._state=V):(this._state=Nt,setImmediate(()=>{this.emit("message",s,!0),this._state=V,this.startLoop(e)}))}else{let s=Lr(r,t);if(!this._skipUTF8Validation&&!Ks(s)){let i=this.createError(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");e(i);return}this._state===Ar||this._allowSynchronousEvents?(this.emit("message",s,!1),this._state=V):(this._state=Nt,setImmediate(()=>{this.emit("message",s,!1),this._state=V,this.startLoop(e)}))}}controlMessage(e,t){if(this._opcode===8){if(e.length===0)this._loop=!1,this.emit("conclude",1005,Qs),this.end();else{let r=e.readUInt16BE(0);if(!ga(r)){let i=this.createError(RangeError,`invalid status code ${r}`,!0,1002,"WS_ERR_INVALID_CLOSE_CODE");t(i);return}let s=new At(e.buffer,e.byteOffset+2,e.length-2);if(!this._skipUTF8Validation&&!Ks(s)){let i=this.createError(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");t(i);return}this._loop=!1,this.emit("conclude",r,s),this.end()}this._state=V;return}this._allowSynchronousEvents?(this.emit(this._opcode===9?"ping":"pong",e),this._state=V):(this._state=Nt,setImmediate(()=>{this.emit(this._opcode===9?"ping":"pong",e),this._state=V,this.startLoop(t)}))}createError(e,t,r,s,i){this._loop=!1,this._errored=!0;let o=new e(r?`Invalid WebSocket frame: ${t}`:t);return Error.captureStackTrace(o,this.createError),o.code=i,o[ha]=s,o}};ti.exports=Nr});var kr=S((uc,si)=>{"use strict";var{Duplex:ac}=require("stream"),{randomFillSync:_a}=require("crypto"),ri=Ke(),{EMPTY_BUFFER:ya,kWebSocket:wa,NOOP:Sa}=se(),{isBlob:Ne,isValidStatusCode:va}=Ae(),{mask:ni,toBuffer:ge}=Ye(),H=Symbol("kByteLength"),xa=Buffer.alloc(4),Mt=8*1024,_e,Me=Mt,X=0,ba=1,Ea=2,Rr=class n{constructor(e,t,r){this._extensions=t||{},r&&(this._generateMask=r,this._maskBuffer=Buffer.alloc(4)),this._socket=e,this._firstFragment=!0,this._compress=!1,this._bufferedBytes=0,this._queue=[],this._state=X,this.onerror=Sa,this[wa]=void 0}static frame(e,t){let r,s=!1,i=2,o=!1;t.mask&&(r=t.maskBuffer||xa,t.generateMask?t.generateMask(r):(Me===Mt&&(_e===void 0&&(_e=Buffer.alloc(Mt)),_a(_e,0,Mt),Me=0),r[0]=_e[Me++],r[1]=_e[Me++],r[2]=_e[Me++],r[3]=_e[Me++]),o=(r[0]|r[1]|r[2]|r[3])===0,i=6);let l;typeof e=="string"?(!t.mask||o)&&t[H]!==void 0?l=t[H]:(e=Buffer.from(e),l=e.length):(l=e.length,s=t.mask&&t.readOnly&&!o);let u=l;l>=65536?(i+=8,u=127):l>125&&(i+=2,u=126);let a=Buffer.allocUnsafe(s?l+i:i);return a[0]=t.fin?t.opcode|128:t.opcode,t.rsv1&&(a[0]|=64),a[1]=u,u===126?a.writeUInt16BE(l,2):u===127&&(a[2]=a[3]=0,a.writeUIntBE(l,4,6)),t.mask?(a[1]|=128,a[i-4]=r[0],a[i-3]=r[1],a[i-2]=r[2],a[i-1]=r[3],o?[a,e]:s?(ni(e,r,a,i,l),[a]):(ni(e,r,e,0,l),[a,e])):[a,e]}close(e,t,r,s){let i;if(e===void 0)i=ya;else{if(typeof e!="number"||!va(e))throw new TypeError("First argument must be a valid error code number");if(t===void 0||!t.length)i=Buffer.allocUnsafe(2),i.writeUInt16BE(e,0);else{let l=Buffer.byteLength(t);if(l>123)throw new RangeError("The message must not be greater than 123 bytes");i=Buffer.allocUnsafe(2+l),i.writeUInt16BE(e,0),typeof t=="string"?i.write(t,2):i.set(t,2)}}let o={[H]:i.length,fin:!0,generateMask:this._generateMask,mask:r,maskBuffer:this._maskBuffer,opcode:8,readOnly:!1,rsv1:!1};this._state!==X?this.enqueue([this.dispatch,i,!1,o,s]):this.sendFrame(n.frame(i,o),s)}ping(e,t,r){let s,i;if(typeof e=="string"?(s=Buffer.byteLength(e),i=!1):Ne(e)?(s=e.size,i=!1):(e=ge(e),s=e.length,i=ge.readOnly),s>125)throw new RangeError("The data size must not be greater than 125 bytes");let o={[H]:s,fin:!0,generateMask:this._generateMask,mask:t,maskBuffer:this._maskBuffer,opcode:9,readOnly:i,rsv1:!1};Ne(e)?this._state!==X?this.enqueue([this.getBlobData,e,!1,o,r]):this.getBlobData(e,!1,o,r):this._state!==X?this.enqueue([this.dispatch,e,!1,o,r]):this.sendFrame(n.frame(e,o),r)}pong(e,t,r){let s,i;if(typeof e=="string"?(s=Buffer.byteLength(e),i=!1):Ne(e)?(s=e.size,i=!1):(e=ge(e),s=e.length,i=ge.readOnly),s>125)throw new RangeError("The data size must not be greater than 125 bytes");let o={[H]:s,fin:!0,generateMask:this._generateMask,mask:t,maskBuffer:this._maskBuffer,opcode:10,readOnly:i,rsv1:!1};Ne(e)?this._state!==X?this.enqueue([this.getBlobData,e,!1,o,r]):this.getBlobData(e,!1,o,r):this._state!==X?this.enqueue([this.dispatch,e,!1,o,r]):this.sendFrame(n.frame(e,o),r)}send(e,t,r){let s=this._extensions[ri.extensionName],i=t.binary?2:1,o=t.compress,l,u;typeof e=="string"?(l=Buffer.byteLength(e),u=!1):Ne(e)?(l=e.size,u=!1):(e=ge(e),l=e.length,u=ge.readOnly),this._firstFragment?(this._firstFragment=!1,o&&s&&s.params[s._isServer?"server_no_context_takeover":"client_no_context_takeover"]&&(o=l>=s._threshold),this._compress=o):(o=!1,i=0),t.fin&&(this._firstFragment=!0);let a={[H]:l,fin:t.fin,generateMask:this._generateMask,mask:t.mask,maskBuffer:this._maskBuffer,opcode:i,readOnly:u,rsv1:o};Ne(e)?this._state!==X?this.enqueue([this.getBlobData,e,this._compress,a,r]):this.getBlobData(e,this._compress,a,r):this._state!==X?this.enqueue([this.dispatch,e,this._compress,a,r]):this.dispatch(e,this._compress,a,r)}getBlobData(e,t,r,s){this._bufferedBytes+=r[H],this._state=Ea,e.arrayBuffer().then(i=>{if(this._socket.destroyed){let l=new Error("The socket was closed while the blob was being read");process.nextTick(Pr,this,l,s);return}this._bufferedBytes-=r[H];let o=ge(i);t?this.dispatch(o,t,r,s):(this._state=X,this.sendFrame(n.frame(o,r),s),this.dequeue())}).catch(i=>{process.nextTick(Ca,this,i,s)})}dispatch(e,t,r,s){if(!t){this.sendFrame(n.frame(e,r),s);return}let i=this._extensions[ri.extensionName];this._bufferedBytes+=r[H],this._state=ba,i.compress(e,r.fin,(o,l)=>{if(this._socket.destroyed){let u=new Error("The socket was closed while data was being compressed");Pr(this,u,s);return}this._bufferedBytes-=r[H],this._state=X,r.readOnly=!1,this.sendFrame(n.frame(l,r),s),this.dequeue()})}dequeue(){for(;this._state===X&&this._queue.length;){let e=this._queue.shift();this._bufferedBytes-=e[3][H],Reflect.apply(e[0],this,e.slice(1))}}enqueue(e){this._bufferedBytes+=e[3][H],this._queue.push(e)}sendFrame(e,t){e.length===2?(this._socket.cork(),this._socket.write(e[0]),this._socket.write(e[1],t),this._socket.uncork()):this._socket.write(e[0],t)}};si.exports=Rr;function Pr(n,e,t){typeof t=="function"&&t(e);for(let r=0;r<n._queue.length;r++){let s=n._queue[r],i=s[s.length-1];typeof i=="function"&&i(e)}}function Ca(n,e,t){Pr(n,e,t),n.onerror(e)}});var pi=S((fc,hi)=>{"use strict";var{kForOnEventAttribute:Ze,kListener:Ir}=se(),ii=Symbol("kCode"),oi=Symbol("kData"),li=Symbol("kError"),ai=Symbol("kMessage"),ui=Symbol("kReason"),Re=Symbol("kTarget"),fi=Symbol("kType"),ci=Symbol("kWasClean"),oe=class{constructor(e){this[Re]=null,this[fi]=e}get target(){return this[Re]}get type(){return this[fi]}};Object.defineProperty(oe.prototype,"target",{enumerable:!0});Object.defineProperty(oe.prototype,"type",{enumerable:!0});var ye=class extends oe{constructor(e,t={}){super(e),this[ii]=t.code===void 0?0:t.code,this[ui]=t.reason===void 0?"":t.reason,this[ci]=t.wasClean===void 0?!1:t.wasClean}get code(){return this[ii]}get reason(){return this[ui]}get wasClean(){return this[ci]}};Object.defineProperty(ye.prototype,"code",{enumerable:!0});Object.defineProperty(ye.prototype,"reason",{enumerable:!0});Object.defineProperty(ye.prototype,"wasClean",{enumerable:!0});var Pe=class extends oe{constructor(e,t={}){super(e),this[li]=t.error===void 0?null:t.error,this[ai]=t.message===void 0?"":t.message}get error(){return this[li]}get message(){return this[ai]}};Object.defineProperty(Pe.prototype,"error",{enumerable:!0});Object.defineProperty(Pe.prototype,"message",{enumerable:!0});var Xe=class extends oe{constructor(e,t={}){super(e),this[oi]=t.data===void 0?null:t.data}get data(){return this[oi]}};Object.defineProperty(Xe.prototype,"data",{enumerable:!0});var Oa={addEventListener(n,e,t={}){for(let s of this.listeners(n))if(!t[Ze]&&s[Ir]===e&&!s[Ze])return;let r;if(n==="message")r=function(i,o){let l=new Xe("message",{data:o?i:i.toString()});l[Re]=this,Rt(e,this,l)};else if(n==="close")r=function(i,o){let l=new ye("close",{code:i,reason:o.toString(),wasClean:this._closeFrameReceived&&this._closeFrameSent});l[Re]=this,Rt(e,this,l)};else if(n==="error")r=function(i){let o=new Pe("error",{error:i,message:i.message});o[Re]=this,Rt(e,this,o)};else if(n==="open")r=function(){let i=new oe("open");i[Re]=this,Rt(e,this,i)};else return;r[Ze]=!!t[Ze],r[Ir]=e,t.once?this.once(n,r):this.on(n,r)},removeEventListener(n,e){for(let t of this.listeners(n))if(t[Ir]===e&&!t[Ze]){this.removeListener(n,t);break}}};hi.exports={CloseEvent:ye,ErrorEvent:Pe,Event:oe,EventTarget:Oa,MessageEvent:Xe};function Rt(n,e,t){typeof n=="object"&&n.handleEvent?n.handleEvent.call(n,t):n.call(e,t)}});var Br=S((cc,di)=>{"use strict";var{tokenChars:et}=Ae();function te(n,e,t){n[e]===void 0?n[e]=[t]:n[e].push(t)}function La(n){let e=Object.create(null),t=Object.create(null),r=!1,s=!1,i=!1,o,l,u=-1,a=-1,f=-1,h=0;for(;h<n.length;h++)if(a=n.charCodeAt(h),o===void 0)if(f===-1&&et[a]===1)u===-1&&(u=h);else if(h!==0&&(a===32||a===9))f===-1&&u!==-1&&(f=h);else if(a===59||a===44){if(u===-1)throw new SyntaxError(`Unexpected character at index ${h}`);f===-1&&(f=h);let p=n.slice(u,f);a===44?(te(e,p,t),t=Object.create(null)):o=p,u=f=-1}else throw new SyntaxError(`Unexpected character at index ${h}`);else if(l===void 0)if(f===-1&&et[a]===1)u===-1&&(u=h);else if(a===32||a===9)f===-1&&u!==-1&&(f=h);else if(a===59||a===44){if(u===-1)throw new SyntaxError(`Unexpected character at index ${h}`);f===-1&&(f=h),te(t,n.slice(u,f),!0),a===44&&(te(e,o,t),t=Object.create(null),o=void 0),u=f=-1}else if(a===61&&u!==-1&&f===-1)l=n.slice(u,h),u=f=-1;else throw new SyntaxError(`Unexpected character at index ${h}`);else if(s){if(et[a]!==1)throw new SyntaxError(`Unexpected character at index ${h}`);u===-1?u=h:r||(r=!0),s=!1}else if(i)if(et[a]===1)u===-1&&(u=h);else if(a===34&&u!==-1)i=!1,f=h;else if(a===92)s=!0;else throw new SyntaxError(`Unexpected character at index ${h}`);else if(a===34&&n.charCodeAt(h-1)===61)i=!0;else if(f===-1&&et[a]===1)u===-1&&(u=h);else if(u!==-1&&(a===32||a===9))f===-1&&(f=h);else if(a===59||a===44){if(u===-1)throw new SyntaxError(`Unexpected character at index ${h}`);f===-1&&(f=h);let p=n.slice(u,f);r&&(p=p.replace(/\\/g,""),r=!1),te(t,l,p),a===44&&(te(e,o,t),t=Object.create(null),o=void 0),l=void 0,u=f=-1}else throw new SyntaxError(`Unexpected character at index ${h}`);if(u===-1||i||a===32||a===9)throw new SyntaxError("Unexpected end of input");f===-1&&(f=h);let c=n.slice(u,f);return o===void 0?te(e,c,t):(l===void 0?te(t,c,!0):r?te(t,l,c.replace(/\\/g,"")):te(t,l,c),te(e,o,t)),e}function Ta(n){return Object.keys(n).map(e=>{let t=n[e];return Array.isArray(t)||(t=[t]),t.map(r=>[e].concat(Object.keys(r).map(s=>{let i=r[s];return Array.isArray(i)||(i=[i]),i.map(o=>o===!0?s:`${s}=${o}`).join("; ")})).join("; ")).join(", ")}).join(", ")}di.exports={format:Ta,parse:La}});var jr=S((dc,Oi)=>{"use strict";var Aa=require("events"),Na=require("https"),Ma=require("http"),_i=require("net"),Ra=require("tls"),{randomBytes:Pa,createHash:ka}=require("crypto"),{Duplex:hc,Readable:pc}=require("stream"),{URL:Fr}=require("url"),ce=Ke(),Ia=Mr(),Ba=kr(),{isBlob:Fa}=Ae(),{BINARY_TYPES:mi,EMPTY_BUFFER:Pt,GUID:Ua,kForOnEventAttribute:Ur,kListener:Da,kStatusCode:Wa,kWebSocket:I,NOOP:yi}=se(),{EventTarget:{addEventListener:ja,removeEventListener:$a}}=pi(),{format:qa,parse:Ga}=Br(),{toBuffer:za}=Ye(),Va=30*1e3,wi=Symbol("kAborted"),Dr=[8,13],le=["CONNECTING","OPEN","CLOSING","CLOSED"],Ha=/^[!#$%&'*+\-.0-9A-Z^_`|a-z~]+$/,L=class n extends Aa{constructor(e,t,r){super(),this._binaryType=mi[0],this._closeCode=1006,this._closeFrameReceived=!1,this._closeFrameSent=!1,this._closeMessage=Pt,this._closeTimer=null,this._errorEmitted=!1,this._extensions={},this._paused=!1,this._protocol="",this._readyState=n.CONNECTING,this._receiver=null,this._sender=null,this._socket=null,e!==null?(this._bufferedAmount=0,this._isServer=!1,this._redirects=0,t===void 0?t=[]:Array.isArray(t)||(typeof t=="object"&&t!==null?(r=t,t=[]):t=[t]),Si(this,e,t,r)):(this._autoPong=r.autoPong,this._isServer=!0)}get binaryType(){return this._binaryType}set binaryType(e){mi.includes(e)&&(this._binaryType=e,this._receiver&&(this._receiver._binaryType=e))}get bufferedAmount(){return this._socket?this._socket._writableState.length+this._sender._bufferedBytes:this._bufferedAmount}get extensions(){return Object.keys(this._extensions).join()}get isPaused(){return this._paused}get onclose(){return null}get onerror(){return null}get onopen(){return null}get onmessage(){return null}get protocol(){return this._protocol}get readyState(){return this._readyState}get url(){return this._url}setSocket(e,t,r){let s=new Ia({allowSynchronousEvents:r.allowSynchronousEvents,binaryType:this.binaryType,extensions:this._extensions,isServer:this._isServer,maxPayload:r.maxPayload,skipUTF8Validation:r.skipUTF8Validation}),i=new Ba(e,this._extensions,r.generateMask);this._receiver=s,this._sender=i,this._socket=e,s[I]=this,i[I]=this,e[I]=this,s.on("conclude",Qa),s.on("drain",Ka),s.on("error",Za),s.on("message",Xa),s.on("ping",eu),s.on("pong",tu),i.onerror=ru,e.setTimeout&&e.setTimeout(0),e.setNoDelay&&e.setNoDelay(),t.length>0&&e.unshift(t),e.on("close",bi),e.on("data",It),e.on("end",Ei),e.on("error",Ci),this._readyState=n.OPEN,this.emit("open")}emitClose(){if(!this._socket){this._readyState=n.CLOSED,this.emit("close",this._closeCode,this._closeMessage);return}this._extensions[ce.extensionName]&&this._extensions[ce.extensionName].cleanup(),this._receiver.removeAllListeners(),this._readyState=n.CLOSED,this.emit("close",this._closeCode,this._closeMessage)}close(e,t){if(this.readyState!==n.CLOSED){if(this.readyState===n.CONNECTING){q(this,this._req,"WebSocket was closed before the connection was established");return}if(this.readyState===n.CLOSING){this._closeFrameSent&&(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end();return}this._readyState=n.CLOSING,this._sender.close(e,t,!this._isServer,r=>{r||(this._closeFrameSent=!0,(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end())}),xi(this)}}pause(){this.readyState===n.CONNECTING||this.readyState===n.CLOSED||(this._paused=!0,this._socket.pause())}ping(e,t,r){if(this.readyState===n.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if(typeof e=="function"?(r=e,e=t=void 0):typeof t=="function"&&(r=t,t=void 0),typeof e=="number"&&(e=e.toString()),this.readyState!==n.OPEN){Wr(this,e,r);return}t===void 0&&(t=!this._isServer),this._sender.ping(e||Pt,t,r)}pong(e,t,r){if(this.readyState===n.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if(typeof e=="function"?(r=e,e=t=void 0):typeof t=="function"&&(r=t,t=void 0),typeof e=="number"&&(e=e.toString()),this.readyState!==n.OPEN){Wr(this,e,r);return}t===void 0&&(t=!this._isServer),this._sender.pong(e||Pt,t,r)}resume(){this.readyState===n.CONNECTING||this.readyState===n.CLOSED||(this._paused=!1,this._receiver._writableState.needDrain||this._socket.resume())}send(e,t,r){if(this.readyState===n.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if(typeof t=="function"&&(r=t,t={}),typeof e=="number"&&(e=e.toString()),this.readyState!==n.OPEN){Wr(this,e,r);return}let s={binary:typeof e!="string",mask:!this._isServer,compress:!0,fin:!0,...t};this._extensions[ce.extensionName]||(s.compress=!1),this._sender.send(e||Pt,s,r)}terminate(){if(this.readyState!==n.CLOSED){if(this.readyState===n.CONNECTING){q(this,this._req,"WebSocket was closed before the connection was established");return}this._socket&&(this._readyState=n.CLOSING,this._socket.destroy())}}};Object.defineProperty(L,"CONNECTING",{enumerable:!0,value:le.indexOf("CONNECTING")});Object.defineProperty(L.prototype,"CONNECTING",{enumerable:!0,value:le.indexOf("CONNECTING")});Object.defineProperty(L,"OPEN",{enumerable:!0,value:le.indexOf("OPEN")});Object.defineProperty(L.prototype,"OPEN",{enumerable:!0,value:le.indexOf("OPEN")});Object.defineProperty(L,"CLOSING",{enumerable:!0,value:le.indexOf("CLOSING")});Object.defineProperty(L.prototype,"CLOSING",{enumerable:!0,value:le.indexOf("CLOSING")});Object.defineProperty(L,"CLOSED",{enumerable:!0,value:le.indexOf("CLOSED")});Object.defineProperty(L.prototype,"CLOSED",{enumerable:!0,value:le.indexOf("CLOSED")});["binaryType","bufferedAmount","extensions","isPaused","protocol","readyState","url"].forEach(n=>{Object.defineProperty(L.prototype,n,{enumerable:!0})});["open","error","close","message"].forEach(n=>{Object.defineProperty(L.prototype,`on${n}`,{enumerable:!0,get(){for(let e of this.listeners(n))if(e[Ur])return e[Da];return null},set(e){for(let t of this.listeners(n))if(t[Ur]){this.removeListener(n,t);break}typeof e=="function"&&this.addEventListener(n,e,{[Ur]:!0})}})});L.prototype.addEventListener=ja;L.prototype.removeEventListener=$a;Oi.exports=L;function Si(n,e,t,r){let s={allowSynchronousEvents:!0,autoPong:!0,protocolVersion:Dr[1],maxPayload:104857600,skipUTF8Validation:!1,perMessageDeflate:!0,followRedirects:!1,maxRedirects:10,...r,socketPath:void 0,hostname:void 0,protocol:void 0,timeout:void 0,method:"GET",host:void 0,path:void 0,port:void 0};if(n._autoPong=s.autoPong,!Dr.includes(s.protocolVersion))throw new RangeError(`Unsupported protocol version: ${s.protocolVersion} (supported versions: ${Dr.join(", ")})`);let i;if(e instanceof Fr)i=e;else try{i=new Fr(e)}catch{throw new SyntaxError(`Invalid URL: ${e}`)}i.protocol==="http:"?i.protocol="ws:":i.protocol==="https:"&&(i.protocol="wss:"),n._url=i.href;let o=i.protocol==="wss:",l=i.protocol==="ws+unix:",u;if(i.protocol!=="ws:"&&!o&&!l?u=`The URL's protocol must be one of "ws:", "wss:", "http:", "https", or "ws+unix:"`:l&&!i.pathname?u="The URL's pathname is empty":i.hash&&(u="The URL contains a fragment identifier"),u){let d=new SyntaxError(u);if(n._redirects===0)throw d;kt(n,d);return}let a=o?443:80,f=Pa(16).toString("base64"),h=o?Na.request:Ma.request,c=new Set,p;if(s.createConnection=s.createConnection||(o?Ja:Ya),s.defaultPort=s.defaultPort||a,s.port=i.port||a,s.host=i.hostname.startsWith("[")?i.hostname.slice(1,-1):i.hostname,s.headers={...s.headers,"Sec-WebSocket-Version":s.protocolVersion,"Sec-WebSocket-Key":f,Connection:"Upgrade",Upgrade:"websocket"},s.path=i.pathname+i.search,s.timeout=s.handshakeTimeout,s.perMessageDeflate&&(p=new ce(s.perMessageDeflate!==!0?s.perMessageDeflate:{},!1,s.maxPayload),s.headers["Sec-WebSocket-Extensions"]=qa({[ce.extensionName]:p.offer()})),t.length){for(let d of t){if(typeof d!="string"||!Ha.test(d)||c.has(d))throw new SyntaxError("An invalid or duplicated subprotocol was specified");c.add(d)}s.headers["Sec-WebSocket-Protocol"]=t.join(",")}if(s.origin&&(s.protocolVersion<13?s.headers["Sec-WebSocket-Origin"]=s.origin:s.headers.Origin=s.origin),(i.username||i.password)&&(s.auth=`${i.username}:${i.password}`),l){let d=s.path.split(":");s.socketPath=d[0],s.path=d[1]}let m;if(s.followRedirects){if(n._redirects===0){n._originalIpc=l,n._originalSecure=o,n._originalHostOrSocketPath=l?s.socketPath:i.host;let d=r&&r.headers;if(r={...r,headers:{}},d)for(let[g,y]of Object.entries(d))r.headers[g.toLowerCase()]=y}else if(n.listenerCount("redirect")===0){let d=l?n._originalIpc?s.socketPath===n._originalHostOrSocketPath:!1:n._originalIpc?!1:i.host===n._originalHostOrSocketPath;(!d||n._originalSecure&&!o)&&(delete s.headers.authorization,delete s.headers.cookie,d||delete s.headers.host,s.auth=void 0)}s.auth&&!r.headers.authorization&&(r.headers.authorization="Basic "+Buffer.from(s.auth).toString("base64")),m=n._req=h(s),n._redirects&&n.emit("redirect",n.url,m)}else m=n._req=h(s);s.timeout&&m.on("timeout",()=>{q(n,m,"Opening handshake has timed out")}),m.on("error",d=>{m===null||m[wi]||(m=n._req=null,kt(n,d))}),m.on("response",d=>{let g=d.headers.location,y=d.statusCode;if(g&&s.followRedirects&&y>=300&&y<400){if(++n._redirects>s.maxRedirects){q(n,m,"Maximum redirects exceeded");return}m.abort();let w;try{w=new Fr(g,e)}catch{let v=new SyntaxError(`Invalid URL: ${g}`);kt(n,v);return}Si(n,w,t,r)}else n.emit("unexpected-response",m,d)||q(n,m,`Unexpected server response: ${d.statusCode}`)}),m.on("upgrade",(d,g,y)=>{if(n.emit("upgrade",d),n.readyState!==L.CONNECTING)return;m=n._req=null;let w=d.headers.upgrade;if(w===void 0||w.toLowerCase()!=="websocket"){q(n,g,"Invalid Upgrade header");return}let b=ka("sha1").update(f+Ua).digest("base64");if(d.headers["sec-websocket-accept"]!==b){q(n,g,"Invalid Sec-WebSocket-Accept header");return}let v=d.headers["sec-websocket-protocol"],E;if(v!==void 0?c.size?c.has(v)||(E="Server sent an invalid subprotocol"):E="Server sent a subprotocol but none was requested":c.size&&(E="Server sent no subprotocol"),E){q(n,g,E);return}v&&(n._protocol=v);let x=d.headers["sec-websocket-extensions"];if(x!==void 0){if(!p){q(n,g,"Server sent a Sec-WebSocket-Extensions header but no extension was requested");return}let R;try{R=Ga(x)}catch{q(n,g,"Invalid Sec-WebSocket-Extensions header");return}let N=Object.keys(R);if(N.length!==1||N[0]!==ce.extensionName){q(n,g,"Server indicated an extension that was not requested");return}try{p.accept(R[ce.extensionName])}catch{q(n,g,"Invalid Sec-WebSocket-Extensions header");return}n._extensions[ce.extensionName]=p}n.setSocket(g,y,{allowSynchronousEvents:s.allowSynchronousEvents,generateMask:s.generateMask,maxPayload:s.maxPayload,skipUTF8Validation:s.skipUTF8Validation})}),s.finishRequest?s.finishRequest(m,n):m.end()}function kt(n,e){n._readyState=L.CLOSING,n._errorEmitted=!0,n.emit("error",e),n.emitClose()}function Ya(n){return n.path=n.socketPath,_i.connect(n)}function Ja(n){return n.path=void 0,!n.servername&&n.servername!==""&&(n.servername=_i.isIP(n.host)?"":n.host),Ra.connect(n)}function q(n,e,t){n._readyState=L.CLOSING;let r=new Error(t);Error.captureStackTrace(r,q),e.setHeader?(e[wi]=!0,e.abort(),e.socket&&!e.socket.destroyed&&e.socket.destroy(),process.nextTick(kt,n,r)):(e.destroy(r),e.once("error",n.emit.bind(n,"error")),e.once("close",n.emitClose.bind(n)))}function Wr(n,e,t){if(e){let r=Fa(e)?e.size:za(e).length;n._socket?n._sender._bufferedBytes+=r:n._bufferedAmount+=r}if(t){let r=new Error(`WebSocket is not open: readyState ${n.readyState} (${le[n.readyState]})`);process.nextTick(t,r)}}function Qa(n,e){let t=this[I];t._closeFrameReceived=!0,t._closeMessage=e,t._closeCode=n,t._socket[I]!==void 0&&(t._socket.removeListener("data",It),process.nextTick(vi,t._socket),n===1005?t.close():t.close(n,e))}function Ka(){let n=this[I];n.isPaused||n._socket.resume()}function Za(n){let e=this[I];e._socket[I]!==void 0&&(e._socket.removeListener("data",It),process.nextTick(vi,e._socket),e.close(n[Wa])),e._errorEmitted||(e._errorEmitted=!0,e.emit("error",n))}function gi(){this[I].emitClose()}function Xa(n,e){this[I].emit("message",n,e)}function eu(n){let e=this[I];e._autoPong&&e.pong(n,!this._isServer,yi),e.emit("ping",n)}function tu(n){this[I].emit("pong",n)}function vi(n){n.resume()}function ru(n){let e=this[I];e.readyState!==L.CLOSED&&(e.readyState===L.OPEN&&(e._readyState=L.CLOSING,xi(e)),this._socket.end(),e._errorEmitted||(e._errorEmitted=!0,e.emit("error",n)))}function xi(n){n._closeTimer=setTimeout(n._socket.destroy.bind(n._socket),Va)}function bi(){let n=this[I];this.removeListener("close",bi),this.removeListener("data",It),this.removeListener("end",Ei),n._readyState=L.CLOSING;let e;!this._readableState.endEmitted&&!n._closeFrameReceived&&!n._receiver._writableState.errorEmitted&&(e=n._socket.read())!==null&&n._receiver.write(e),n._receiver.end(),this[I]=void 0,clearTimeout(n._closeTimer),n._receiver._writableState.finished||n._receiver._writableState.errorEmitted?n.emitClose():(n._receiver.on("error",gi),n._receiver.on("finish",gi))}function It(n){this[I]._receiver.write(n)||this.pause()}function Ei(){let n=this[I];n._readyState=L.CLOSING,n._receiver.end(),this.end()}function Ci(){let n=this[I];this.removeListener("error",Ci),this.on("error",yi),n&&(n._readyState=L.CLOSING,this.destroy())}});var Ti=S((mc,Li)=>{"use strict";var{tokenChars:nu}=Ae();function su(n){let e=new Set,t=-1,r=-1,s=0;for(s;s<n.length;s++){let o=n.charCodeAt(s);if(r===-1&&nu[o]===1)t===-1&&(t=s);else if(s!==0&&(o===32||o===9))r===-1&&t!==-1&&(r=s);else if(o===44){if(t===-1)throw new SyntaxError(`Unexpected character at index ${s}`);r===-1&&(r=s);let l=n.slice(t,r);if(e.has(l))throw new SyntaxError(`The "${l}" subprotocol is duplicated`);e.add(l),t=r=-1}else throw new SyntaxError(`Unexpected character at index ${s}`)}if(t===-1||r!==-1)throw new SyntaxError("Unexpected end of input");let i=n.slice(t,s);if(e.has(i))throw new SyntaxError(`The "${i}" subprotocol is duplicated`);return e.add(i),e}Li.exports={parse:su}});var Ii=S((_c,ki)=>{"use strict";var iu=require("events"),Bt=require("http"),{Duplex:gc}=require("stream"),{createHash:ou}=require("crypto"),Ai=Br(),we=Ke(),lu=Ti(),au=jr(),{GUID:uu,kWebSocket:fu}=se(),cu=/^[+/0-9A-Za-z]{22}==$/,Ni=0,Mi=1,Pi=2,$r=class extends iu{constructor(e,t){if(super(),e={allowSynchronousEvents:!0,autoPong:!0,maxPayload:100*1024*1024,skipUTF8Validation:!1,perMessageDeflate:!1,handleProtocols:null,clientTracking:!0,verifyClient:null,noServer:!1,backlog:null,server:null,host:null,path:null,port:null,WebSocket:au,...e},e.port==null&&!e.server&&!e.noServer||e.port!=null&&(e.server||e.noServer)||e.server&&e.noServer)throw new TypeError('One and only one of the "port", "server", or "noServer" options must be specified');if(e.port!=null?(this._server=Bt.createServer((r,s)=>{let i=Bt.STATUS_CODES[426];s.writeHead(426,{"Content-Length":i.length,"Content-Type":"text/plain"}),s.end(i)}),this._server.listen(e.port,e.host,e.backlog,t)):e.server&&(this._server=e.server),this._server){let r=this.emit.bind(this,"connection");this._removeListeners=hu(this._server,{listening:this.emit.bind(this,"listening"),error:this.emit.bind(this,"error"),upgrade:(s,i,o)=>{this.handleUpgrade(s,i,o,r)}})}e.perMessageDeflate===!0&&(e.perMessageDeflate={}),e.clientTracking&&(this.clients=new Set,this._shouldEmitClose=!1),this.options=e,this._state=Ni}address(){if(this.options.noServer)throw new Error('The server is operating in "noServer" mode');return this._server?this._server.address():null}close(e){if(this._state===Pi){e&&this.once("close",()=>{e(new Error("The server is not running"))}),process.nextTick(tt,this);return}if(e&&this.once("close",e),this._state!==Mi)if(this._state=Mi,this.options.noServer||this.options.server)this._server&&(this._removeListeners(),this._removeListeners=this._server=null),this.clients?this.clients.size?this._shouldEmitClose=!0:process.nextTick(tt,this):process.nextTick(tt,this);else{let t=this._server;this._removeListeners(),this._removeListeners=this._server=null,t.close(()=>{tt(this)})}}shouldHandle(e){if(this.options.path){let t=e.url.indexOf("?");if((t!==-1?e.url.slice(0,t):e.url)!==this.options.path)return!1}return!0}handleUpgrade(e,t,r,s){t.on("error",Ri);let i=e.headers["sec-websocket-key"],o=e.headers.upgrade,l=+e.headers["sec-websocket-version"];if(e.method!=="GET"){Se(this,e,t,405,"Invalid HTTP method");return}if(o===void 0||o.toLowerCase()!=="websocket"){Se(this,e,t,400,"Invalid Upgrade header");return}if(i===void 0||!cu.test(i)){Se(this,e,t,400,"Missing or invalid Sec-WebSocket-Key header");return}if(l!==8&&l!==13){Se(this,e,t,400,"Missing or invalid Sec-WebSocket-Version header");return}if(!this.shouldHandle(e)){rt(t,400);return}let u=e.headers["sec-websocket-protocol"],a=new Set;if(u!==void 0)try{a=lu.parse(u)}catch{Se(this,e,t,400,"Invalid Sec-WebSocket-Protocol header");return}let f=e.headers["sec-websocket-extensions"],h={};if(this.options.perMessageDeflate&&f!==void 0){let c=new we(this.options.perMessageDeflate,!0,this.options.maxPayload);try{let p=Ai.parse(f);p[we.extensionName]&&(c.accept(p[we.extensionName]),h[we.extensionName]=c)}catch{Se(this,e,t,400,"Invalid or unacceptable Sec-WebSocket-Extensions header");return}}if(this.options.verifyClient){let c={origin:e.headers[`${l===8?"sec-websocket-origin":"origin"}`],secure:!!(e.socket.authorized||e.socket.encrypted),req:e};if(this.options.verifyClient.length===2){this.options.verifyClient(c,(p,m,d,g)=>{if(!p)return rt(t,m||401,d,g);this.completeUpgrade(h,i,a,e,t,r,s)});return}if(!this.options.verifyClient(c))return rt(t,401)}this.completeUpgrade(h,i,a,e,t,r,s)}completeUpgrade(e,t,r,s,i,o,l){if(!i.readable||!i.writable)return i.destroy();if(i[fu])throw new Error("server.handleUpgrade() was called more than once with the same socket, possibly due to a misconfiguration");if(this._state>Ni)return rt(i,503);let a=["HTTP/1.1 101 Switching Protocols","Upgrade: websocket","Connection: Upgrade",`Sec-WebSocket-Accept: ${ou("sha1").update(t+uu).digest("base64")}`],f=new this.options.WebSocket(null,void 0,this.options);if(r.size){let h=this.options.handleProtocols?this.options.handleProtocols(r,s):r.values().next().value;h&&(a.push(`Sec-WebSocket-Protocol: ${h}`),f._protocol=h)}if(e[we.extensionName]){let h=e[we.extensionName].params,c=Ai.format({[we.extensionName]:[h]});a.push(`Sec-WebSocket-Extensions: ${c}`),f._extensions=e}this.emit("headers",a,s),i.write(a.concat(`\r
|
|
26
26
|
`).join(`\r
|
|
27
|
-
`)),i.removeListener("error",
|
|
27
|
+
`)),i.removeListener("error",Ri),f.setSocket(i,o,{allowSynchronousEvents:this.options.allowSynchronousEvents,maxPayload:this.options.maxPayload,skipUTF8Validation:this.options.skipUTF8Validation}),this.clients&&(this.clients.add(f),f.on("close",()=>{this.clients.delete(f),this._shouldEmitClose&&!this.clients.size&&process.nextTick(tt,this)})),l(f,s)}};ki.exports=$r;function hu(n,e){for(let t of Object.keys(e))n.on(t,e[t]);return function(){for(let r of Object.keys(e))n.removeListener(r,e[r])}}function tt(n){n._state=Pi,n.emit("close")}function Ri(){this.destroy()}function rt(n,e,t,r){t=t||Bt.STATUS_CODES[e],r={Connection:"close","Content-Type":"text/html","Content-Length":Buffer.byteLength(t),...r},n.once("finish",n.destroy),n.end(`HTTP/1.1 ${e} ${Bt.STATUS_CODES[e]}\r
|
|
28
28
|
`+Object.keys(r).map(s=>`${s}: ${r[s]}`).join(`\r
|
|
29
29
|
`)+`\r
|
|
30
30
|
\r
|
|
31
|
-
`+t)}function Se(n,e,t,r,s){if(n.listenerCount("wsClientError")){let i=new Error(s);Error.captureStackTrace(i,Se),n.emit("wsClientError",i,t,e)}else rt(t,r,s)}});var $i=S((wc,ji)=>{"use strict";ji.exports=Di;function Di(n,e,t){n instanceof RegExp&&(n=Ui(n,t)),e instanceof RegExp&&(e=Ui(e,t));var r=Wi(n,e,t);return r&&{start:r[0],end:r[1],pre:t.slice(0,r[0]),body:t.slice(r[0]+n.length,r[1]),post:t.slice(r[1]+e.length)}}function Ui(n,e){var t=e.match(n);return t?t[0]:null}Di.range=Wi;function Wi(n,e,t){var r,s,i,o,l,u=t.indexOf(n),a=t.indexOf(e,u+1),f=u;if(u>=0&&a>0){if(n===e)return[u,a];for(r=[],i=t.length;f>=0&&!l;)f==u?(r.push(f),u=t.indexOf(n,f+1)):r.length==1?l=[r.pop(),a]:(s=r.pop(),s<i&&(i=s,o=a),a=t.indexOf(e,f+1)),f=u<a&&u>=0?u:a;r.length&&(l=[i,o])}return l}});var Qi=S((Sc,Ji)=>{var qi=$i();Ji.exports=wu;var Gi="\0SLASH"+Math.random()+"\0",zi="\0OPEN"+Math.random()+"\0",Gr="\0CLOSE"+Math.random()+"\0",Vi="\0COMMA"+Math.random()+"\0",Hi="\0PERIOD"+Math.random()+"\0";function qr(n){return parseInt(n,10)==n?parseInt(n,10):n.charCodeAt(0)}function _u(n){return n.split("\\\\").join(Gi).split("\\{").join(zi).split("\\}").join(Gr).split("\\,").join(Vi).split("\\.").join(Hi)}function yu(n){return n.split(Gi).join("\\").split(zi).join("{").split(Gr).join("}").split(Vi).join(",").split(Hi).join(".")}function Yi(n){if(!n)return[""];var e=[],t=qi("{","}",n);if(!t)return n.split(",");var r=t.pre,s=t.body,i=t.post,o=r.split(",");o[o.length-1]+="{"+s+"}";var l=Yi(i);return i.length&&(o[o.length-1]+=l.shift(),o.push.apply(o,l)),e.push.apply(e,o),e}function wu(n){return n?(n.substr(0,2)==="{}"&&(n="\\{\\}"+n.substr(2)),nt(_u(n),!0).map(yu)):[]}function Su(n){return"{"+n+"}"}function vu(n){return/^-?0\d/.test(n)}function xu(n,e){return n<=e}function bu(n,e){return n>=e}function nt(n,e){var t=[],r=qi("{","}",n);if(!r)return[n];var s=r.pre,i=r.post.length?nt(r.post,!1):[""];if(/\$$/.test(r.pre))for(var o=0;o<i.length;o++){var l=s+"{"+r.body+"}"+i[o];t.push(l)}else{var u=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(r.body),a=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(r.body),f=u||a,h=r.body.indexOf(",")>=0;if(!f&&!h)return r.post.match(/,.*\}/)?(n=r.pre+"{"+r.body+Gr+r.post,nt(n)):[n];var c;if(f)c=r.body.split(/\.\./);else if(c=Yi(r.body),c.length===1&&(c=nt(c[0],!1).map(Su),c.length===1))return i.map(function(P){return r.pre+c[0]+P});var p;if(f){var m=qr(c[0]),d=qr(c[1]),g=Math.max(c[0].length,c[1].length),y=c.length==3?Math.abs(qr(c[2])):1,w=xu,b=d<m;b&&(y*=-1,w=bu);var v=c.some(vu);p=[];for(var E=m;w(E,d);E+=y){var x;if(a)x=String.fromCharCode(E),x==="\\"&&(x="");else if(x=String(E),v){var M=g-x.length;if(M>0){var N=new Array(M+1).join("0");E<0?x="-"+N+x.slice(1):x=N+x}}p.push(x)}}else{p=[];for(var C=0;C<c.length;C++)p.push.apply(p,nt(c[C],!1))}for(var C=0;C<p.length;C++)for(var o=0;o<i.length;o++){var l=s+p[C]+i[o];(!e||f||l)&&t.push(l)}}return t}});var ho=S(Jr=>{"use strict";Object.defineProperty(Jr,"__esModule",{value:!0});Jr.default=ff;var ot="diff-sequences",W=0,lt=(n,e,t,r,s)=>{let i=0;for(;n<e&&t<r&&s(n,t);)n+=1,t+=1,i+=1;return i},at=(n,e,t,r,s)=>{let i=0;for(;n<=e&&t<=r&&s(e,r);)e-=1,r-=1,i+=1;return i},Hr=(n,e,t,r,s,i,o)=>{let l=0,u=-n,a=i[l],f=a;i[l]+=lt(a+1,e,r+a-u+1,t,s);let h=n<o?n:o;for(l+=1,u+=2;l<=h;l+=1,u+=2){if(l!==n&&f<i[l])a=i[l];else if(a=f+1,e<=a)return l-1;f=i[l],i[l]=a+lt(a+1,e,r+a-u+1,t,s)}return o},uo=(n,e,t,r,s,i,o)=>{let l=0,u=n,a=i[l],f=a;i[l]-=at(e,a-1,t,r+a-u-1,s);let h=n<o?n:o;for(l+=1,u-=2;l<=h;l+=1,u-=2){if(l!==n&&i[l]<f)a=i[l];else if(a=f-1,a<e)return l-1;f=i[l],i[l]=a-at(e,a-1,t,r+a-u-1,s)}return o},lf=(n,e,t,r,s,i,o,l,u,a,f)=>{let h=r-e,c=t-e,m=s-r-c,d=-m-(n-1),g=-m+(n-1),y=W,w=n<l?n:l;for(let b=0,v=-n;b<=w;b+=1,v+=2){let E=b===0||b!==n&&y<o[b],x=E?o[b]:y,M=E?x:x+1,N=h+M-v,C=lt(M+1,t,N+1,s,i),P=M+C;if(y=o[b],o[b]=P,d<=v&&v<=g){let pe=(n-1-(v+m))/2;if(pe<=a&&u[pe]-1<=P){let ee=h+x-(E?v+1:v-1),G=at(e,x,r,ee,i),ae=x-G,ut=ee-G,ve=ae+1,jt=ut+1;f.nChangePreceding=n-1,n-1===ve+jt-e-r?(f.aEndPreceding=e,f.bEndPreceding=r):(f.aEndPreceding=ve,f.bEndPreceding=jt),f.nCommonPreceding=G,G!==0&&(f.aCommonPreceding=ve,f.bCommonPreceding=jt),f.nCommonFollowing=C,C!==0&&(f.aCommonFollowing=M+1,f.bCommonFollowing=N+1);let Xr=P+1,en=N+C+1;return f.nChangeFollowing=n-1,n-1===t+s-Xr-en?(f.aStartFollowing=t,f.bStartFollowing=s):(f.aStartFollowing=Xr,f.bStartFollowing=en),!0}}}return!1},af=(n,e,t,r,s,i,o,l,u,a,f)=>{let h=s-t,c=t-e,m=s-r-c,d=m-n,g=m+n,y=W,w=n<a?n:a;for(let b=0,v=n;b<=w;b+=1,v-=2){let E=b===0||b!==n&&u[b]<y,x=E?u[b]:y,M=E?x:x-1,N=h+M-v,C=at(e,M-1,r,N-1,i),P=M-C;if(y=u[b],u[b]=P,d<=v&&v<=g){let pe=(n+(v-m))/2;if(pe<=l&&P-1<=o[pe]){let ee=N-C;if(f.nChangePreceding=n,n===P+ee-e-r?(f.aEndPreceding=e,f.bEndPreceding=r):(f.aEndPreceding=P,f.bEndPreceding=ee),f.nCommonPreceding=C,C!==0&&(f.aCommonPreceding=P,f.bCommonPreceding=ee),f.nChangeFollowing=n-1,n===1)f.nCommonFollowing=0,f.aStartFollowing=t,f.bStartFollowing=s;else{let G=h+x-(E?v-1:v+1),ae=lt(x,t,G,s,i);f.nCommonFollowing=ae,ae!==0&&(f.aCommonFollowing=x,f.bCommonFollowing=G);let ut=x+ae,ve=G+ae;n-1===t+s-ut-ve?(f.aStartFollowing=t,f.bStartFollowing=s):(f.aStartFollowing=ut,f.bStartFollowing=ve)}return!0}}}return!1},uf=(n,e,t,r,s,i,o,l,u)=>{let a=r-e,f=s-t,h=t-e,c=s-r,p=c-h,m=h,d=h;if(o[0]=e-1,l[0]=t,p%2===0){let g=(n||p)/2,y=(h+c)/2;for(let w=1;w<=y;w+=1)if(m=Hr(w,t,s,a,i,o,m),w<g)d=uo(w,e,r,f,i,l,d);else if(af(w,e,t,r,s,i,o,m,l,d,u))return}else{let g=((n||p)+1)/2,y=(h+c+1)/2,w=1;for(m=Hr(w,t,s,a,i,o,m),w+=1;w<=y;w+=1)if(d=uo(w-1,e,r,f,i,l,d),w<g)m=Hr(w,t,s,a,i,o,m);else if(lf(w,e,t,r,s,i,o,m,l,d,u))return}throw new Error(`${ot}: no overlap aStart=${e} aEnd=${t} bStart=${r} bEnd=${s}`)},Yr=(n,e,t,r,s,i,o,l,u,a)=>{if(s-r<t-e){if(i=!i,i&&o.length===1){let{foundSubsequence:P,isCommon:pe}=o[0];o[1]={foundSubsequence:(ee,G,ae)=>{P(ee,ae,G)},isCommon:(ee,G)=>pe(G,ee)}}let N=e,C=t;e=r,t=s,r=N,s=C}let{foundSubsequence:f,isCommon:h}=o[i?1:0];uf(n,e,t,r,s,h,l,u,a);let{nChangePreceding:c,aEndPreceding:p,bEndPreceding:m,nCommonPreceding:d,aCommonPreceding:g,bCommonPreceding:y,nCommonFollowing:w,aCommonFollowing:b,bCommonFollowing:v,nChangeFollowing:E,aStartFollowing:x,bStartFollowing:M}=a;e<p&&r<m&&Yr(c,e,p,r,m,i,o,l,u,a),d!==0&&f(d,g,y),w!==0&&f(w,b,v),x<t&&M<s&&Yr(E,x,t,M,s,i,o,l,u,a)},fo=(n,e)=>{if(typeof e!="number")throw new TypeError(`${ot}: ${n} typeof ${typeof e} is not a number`);if(!Number.isSafeInteger(e))throw new RangeError(`${ot}: ${n} value ${e} is not a safe integer`);if(e<0)throw new RangeError(`${ot}: ${n} value ${e} is a negative integer`)},co=(n,e)=>{let t=typeof e;if(t!=="function")throw new TypeError(`${ot}: ${n} typeof ${t} is not a function`)};function ff(n,e,t,r){fo("aLength",n),fo("bLength",e),co("isCommon",t),co("foundSubsequence",r);let s=lt(0,n,0,e,t);if(s!==0&&r(s,0,0),n!==s||e!==s){let i=s,o=s,l=at(i,n-1,o,e-1,t),u=n-l,a=e-l,f=s+l;n!==f&&e!==f&&Yr(0,i,u,o,a,!1,[{foundSubsequence:r,isCommon:t}],[W],[W],{aCommonFollowing:W,aCommonPreceding:W,aEndPreceding:W,aStartFollowing:W,bCommonFollowing:W,bCommonPreceding:W,bEndPreceding:W,bStartFollowing:W,nChangeFollowing:W,nChangePreceding:W,nCommonFollowing:W,nCommonPreceding:W}),l!==0&&r(l,u,a)}}});var vf={};No(vf,{WebSocket:()=>Fi,convertSourceMap:()=>Sf,diffSequence:()=>Eo.default,findUpSync:()=>wo,minimatch:()=>F,parseCss:()=>bo.default,supportsColor:()=>xo});module.exports=Ro(vf);var Sf=U(nn()),bo=U(Rs());var pu=U(Is(),1),du=U(Rr(),1),mu=U(kr(),1),Bi=U(jr(),1),gu=U(Ii(),1);var Fi=Bi.default;var so=U(Qi(),1);var st=n=>{if(typeof n!="string")throw new TypeError("invalid pattern");if(n.length>65536)throw new TypeError("pattern is too long")};var Eu={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},it=n=>n.replace(/[[\]\\-]/g,"\\$&"),Cu=n=>n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),Ki=n=>n.join(""),Zi=(n,e)=>{let t=e;if(n.charAt(t)!=="[")throw new Error("not in a brace expression");let r=[],s=[],i=t+1,o=!1,l=!1,u=!1,a=!1,f=t,h="";e:for(;i<n.length;){let d=n.charAt(i);if((d==="!"||d==="^")&&i===t+1){a=!0,i++;continue}if(d==="]"&&o&&!u){f=i+1;break}if(o=!0,d==="\\"&&!u){u=!0,i++;continue}if(d==="["&&!u){for(let[g,[y,w,b]]of Object.entries(Eu))if(n.startsWith(g,i)){if(h)return["$.",!1,n.length-t,!0];i+=g.length,b?s.push(y):r.push(y),l=l||w;continue e}}if(u=!1,h){d>h?r.push(it(h)+"-"+it(d)):d===h&&r.push(it(d)),h="",i++;continue}if(n.startsWith("-]",i+1)){r.push(it(d+"-")),i+=2;continue}if(n.startsWith("-",i+1)){h=d,i+=2;continue}r.push(it(d)),i++}if(f<i)return["",!1,0,!1];if(!r.length&&!s.length)return["$.",!1,n.length-t,!0];if(s.length===0&&r.length===1&&/^\\?.$/.test(r[0])&&!a){let d=r[0].length===2?r[0].slice(-1):r[0];return[Cu(d),!1,f-t,!1]}let c="["+(a?"^":"")+Ki(r)+"]",p="["+(a?"":"^")+Ki(s)+"]";return[r.length&&s.length?"("+c+"|"+p+")":r.length?c:p,l,f-t,!0]};var he=(n,{windowsPathsNoEscape:e=!1}={})=>e?n.replace(/\[([^\/\\])\]/g,"$1"):n.replace(/((?!\\).|^)\[([^\/\\])\]/g,"$1$2").replace(/\\([^\/])/g,"$1");var Ou=new Set(["!","?","+","*","@"]),Xi=n=>Ou.has(n),Lu="(?!(?:^|/)\\.\\.?(?:$|/))",Ft="(?!\\.)",Tu=new Set(["[","."]),Au=new Set(["..","."]),Nu=new Set("().*{}+?[]^$\\!"),Ru=n=>n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),zr="[^/]",eo=zr+"*?",to=zr+"+?",ke=class n{type;#r;#n;#i=!1;#e=[];#t;#o;#a;#l=!1;#s;#u;#c=!1;constructor(e,t,r={}){this.type=e,e&&(this.#n=!0),this.#t=t,this.#r=this.#t?this.#t.#r:this,this.#s=this.#r===this?r:this.#r.#s,this.#a=this.#r===this?[]:this.#r.#a,e==="!"&&!this.#r.#l&&this.#a.push(this),this.#o=this.#t?this.#t.#e.length:0}get hasMagic(){if(this.#n!==void 0)return this.#n;for(let e of this.#e)if(typeof e!="string"&&(e.type||e.hasMagic))return this.#n=!0;return this.#n}toString(){return this.#u!==void 0?this.#u:this.type?this.#u=this.type+"("+this.#e.map(e=>String(e)).join("|")+")":this.#u=this.#e.map(e=>String(e)).join("")}#p(){if(this!==this.#r)throw new Error("should only call on root");if(this.#l)return this;this.toString(),this.#l=!0;let e;for(;e=this.#a.pop();){if(e.type!=="!")continue;let t=e,r=t.#t;for(;r;){for(let s=t.#o+1;!r.type&&s<r.#e.length;s++)for(let i of e.#e){if(typeof i=="string")throw new Error("string part in extglob AST??");i.copyIn(r.#e[s])}t=r,r=t.#t}}return this}push(...e){for(let t of e)if(t!==""){if(typeof t!="string"&&!(t instanceof n&&t.#t===this))throw new Error("invalid part: "+t);this.#e.push(t)}}toJSON(){var t;let e=this.type===null?this.#e.slice().map(r=>typeof r=="string"?r:r.toJSON()):[this.type,...this.#e.map(r=>r.toJSON())];return this.isStart()&&!this.type&&e.unshift([]),this.isEnd()&&(this===this.#r||this.#r.#l&&((t=this.#t)==null?void 0:t.type)==="!")&&e.push({}),e}isStart(){var t;if(this.#r===this)return!0;if(!((t=this.#t)!=null&&t.isStart()))return!1;if(this.#o===0)return!0;let e=this.#t;for(let r=0;r<this.#o;r++){let s=e.#e[r];if(!(s instanceof n&&s.type==="!"))return!1}return!0}isEnd(){var t,r,s;if(this.#r===this||((t=this.#t)==null?void 0:t.type)==="!")return!0;if(!((r=this.#t)!=null&&r.isEnd()))return!1;if(!this.type)return(s=this.#t)==null?void 0:s.isEnd();let e=this.#t?this.#t.#e.length:0;return this.#o===e-1}copyIn(e){typeof e=="string"?this.push(e):this.push(e.clone(this))}clone(e){let t=new n(this.type,e);for(let r of this.#e)t.copyIn(r);return t}static#f(e,t,r,s){let i=!1,o=!1,l=-1,u=!1;if(t.type===null){let p=r,m="";for(;p<e.length;){let d=e.charAt(p++);if(i||d==="\\"){i=!i,m+=d;continue}if(o){p===l+1?(d==="^"||d==="!")&&(u=!0):d==="]"&&!(p===l+2&&u)&&(o=!1),m+=d;continue}else if(d==="["){o=!0,l=p,u=!1,m+=d;continue}if(!s.noext&&Xi(d)&&e.charAt(p)==="("){t.push(m),m="";let g=new n(d,t);p=n.#f(e,g,p,s),t.push(g);continue}m+=d}return t.push(m),p}let a=r+1,f=new n(null,t),h=[],c="";for(;a<e.length;){let p=e.charAt(a++);if(i||p==="\\"){i=!i,c+=p;continue}if(o){a===l+1?(p==="^"||p==="!")&&(u=!0):p==="]"&&!(a===l+2&&u)&&(o=!1),c+=p;continue}else if(p==="["){o=!0,l=a,u=!1,c+=p;continue}if(Xi(p)&&e.charAt(a)==="("){f.push(c),c="";let m=new n(p,f);f.push(m),a=n.#f(e,m,a,s);continue}if(p==="|"){f.push(c),c="",h.push(f),f=new n(null,t);continue}if(p===")")return c===""&&t.#e.length===0&&(t.#c=!0),f.push(c),c="",t.push(...h,f),a;c+=p}return t.type=null,t.#n=void 0,t.#e=[e.substring(r-1)],a}static fromGlob(e,t={}){let r=new n(null,void 0,t);return n.#f(e,r,0,t),r}toMMPattern(){if(this!==this.#r)return this.#r.toMMPattern();let e=this.toString(),[t,r,s,i]=this.toRegExpSource();if(!(s||this.#n||this.#s.nocase&&!this.#s.nocaseMagicOnly&&e.toUpperCase()!==e.toLowerCase()))return r;let l=(this.#s.nocase?"i":"")+(i?"u":"");return Object.assign(new RegExp(`^${t}$`,l),{_src:t,_glob:e})}get options(){return this.#s}toRegExpSource(e){var u;let t=e??!!this.#s.dot;if(this.#r===this&&this.#p(),!this.type){let a=this.isStart()&&this.isEnd(),f=this.#e.map(m=>{let[d,g,y,w]=typeof m=="string"?n.#d(m,this.#n,a):m.toRegExpSource(e);return this.#n=this.#n||y,this.#i=this.#i||w,d}).join(""),h="";if(this.isStart()&&typeof this.#e[0]=="string"&&!(this.#e.length===1&&Au.has(this.#e[0]))){let d=Tu,g=t&&d.has(f.charAt(0))||f.startsWith("\\.")&&d.has(f.charAt(2))||f.startsWith("\\.\\.")&&d.has(f.charAt(4)),y=!t&&!e&&d.has(f.charAt(0));h=g?Lu:y?Ft:""}let c="";return this.isEnd()&&this.#r.#l&&((u=this.#t)==null?void 0:u.type)==="!"&&(c="(?:$|\\/)"),[h+f+c,he(f),this.#n=!!this.#n,this.#i]}let r=this.type==="*"||this.type==="+",s=this.type==="!"?"(?:(?!(?:":"(?:",i=this.#h(t);if(this.isStart()&&this.isEnd()&&!i&&this.type!=="!"){let a=this.toString();return this.#e=[a],this.type=null,this.#n=void 0,[a,he(this.toString()),!1,!1]}let o=!r||e||t||!Ft?"":this.#h(!0);o===i&&(o=""),o&&(i=`(?:${i})(?:${o})*?`);let l="";if(this.type==="!"&&this.#c)l=(this.isStart()&&!t?Ft:"")+to;else{let a=this.type==="!"?"))"+(this.isStart()&&!t&&!e?Ft:"")+eo+")":this.type==="@"?")":this.type==="?"?")?":this.type==="+"&&o?")":this.type==="*"&&o?")?":`)${this.type}`;l=s+i+a}return[l,he(i),this.#n=!!this.#n,this.#i]}#h(e){return this.#e.map(t=>{if(typeof t=="string")throw new Error("string type in extglob ast??");let[r,s,i,o]=t.toRegExpSource(e);return this.#i=this.#i||o,r}).filter(t=>!(this.isStart()&&this.isEnd())||!!t).join("|")}static#d(e,t,r=!1){let s=!1,i="",o=!1;for(let l=0;l<e.length;l++){let u=e.charAt(l);if(s){s=!1,i+=(Nu.has(u)?"\\":"")+u;continue}if(u==="\\"){l===e.length-1?i+="\\\\":s=!0;continue}if(u==="["){let[a,f,h,c]=Zi(e,l);if(h){i+=a,o=o||f,l+=h-1,t=t||c;continue}}if(u==="*"){r&&e==="*"?i+=to:i+=eo,t=!0;continue}if(u==="?"){i+=zr,t=!0;continue}i+=Ru(u)}return[i,he(e),!!t,o]}};var Vr=(n,{windowsPathsNoEscape:e=!1}={})=>e?n.replace(/[?*()[\]]/g,"[$&]"):n.replace(/[?*()[\]\\]/g,"\\$&");var F=(n,e,t={})=>(st(e),!t.nocomment&&e.charAt(0)==="#"?!1:new Ie(e,t).match(n)),Mu=/^\*+([^+@!?\*\[\(]*)$/,Pu=n=>e=>!e.startsWith(".")&&e.endsWith(n),ku=n=>e=>e.endsWith(n),Iu=n=>(n=n.toLowerCase(),e=>!e.startsWith(".")&&e.toLowerCase().endsWith(n)),Bu=n=>(n=n.toLowerCase(),e=>e.toLowerCase().endsWith(n)),Fu=/^\*+\.\*+$/,Uu=n=>!n.startsWith(".")&&n.includes("."),Du=n=>n!=="."&&n!==".."&&n.includes("."),Wu=/^\.\*+$/,ju=n=>n!=="."&&n!==".."&&n.startsWith("."),$u=/^\*+$/,qu=n=>n.length!==0&&!n.startsWith("."),Gu=n=>n.length!==0&&n!=="."&&n!=="..",zu=/^\?+([^+@!?\*\[\(]*)?$/,Vu=([n,e=""])=>{let t=io([n]);return e?(e=e.toLowerCase(),r=>t(r)&&r.toLowerCase().endsWith(e)):t},Hu=([n,e=""])=>{let t=oo([n]);return e?(e=e.toLowerCase(),r=>t(r)&&r.toLowerCase().endsWith(e)):t},Yu=([n,e=""])=>{let t=oo([n]);return e?r=>t(r)&&r.endsWith(e):t},Ju=([n,e=""])=>{let t=io([n]);return e?r=>t(r)&&r.endsWith(e):t},io=([n])=>{let e=n.length;return t=>t.length===e&&!t.startsWith(".")},oo=([n])=>{let e=n.length;return t=>t.length===e&&t!=="."&&t!==".."},lo=typeof process=="object"&&process?typeof process.env=="object"&&process.env&&process.env.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix",ro={win32:{sep:"\\"},posix:{sep:"/"}},Qu=lo==="win32"?ro.win32.sep:ro.posix.sep;F.sep=Qu;var J=Symbol("globstar **");F.GLOBSTAR=J;var Ku="[^/]",Zu=Ku+"*?",Xu="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?",ef="(?:(?!(?:\\/|^)\\.).)*?",tf=(n,e={})=>t=>F(t,n,e);F.filter=tf;var Y=(n,e={})=>Object.assign({},n,e),rf=n=>{if(!n||typeof n!="object"||!Object.keys(n).length)return F;let e=F;return Object.assign((r,s,i={})=>e(r,s,Y(n,i)),{Minimatch:class extends e.Minimatch{constructor(s,i={}){super(s,Y(n,i))}static defaults(s){return e.defaults(Y(n,s)).Minimatch}},AST:class extends e.AST{constructor(s,i,o={}){super(s,i,Y(n,o))}static fromGlob(s,i={}){return e.AST.fromGlob(s,Y(n,i))}},unescape:(r,s={})=>e.unescape(r,Y(n,s)),escape:(r,s={})=>e.escape(r,Y(n,s)),filter:(r,s={})=>e.filter(r,Y(n,s)),defaults:r=>e.defaults(Y(n,r)),makeRe:(r,s={})=>e.makeRe(r,Y(n,s)),braceExpand:(r,s={})=>e.braceExpand(r,Y(n,s)),match:(r,s,i={})=>e.match(r,s,Y(n,i)),sep:e.sep,GLOBSTAR:J})};F.defaults=rf;var ao=(n,e={})=>(st(n),e.nobrace||!/\{(?:(?!\{).)*\}/.test(n)?[n]:(0,so.default)(n));F.braceExpand=ao;var nf=(n,e={})=>new Ie(n,e).makeRe();F.makeRe=nf;var sf=(n,e,t={})=>{let r=new Ie(e,t);return n=n.filter(s=>r.match(s)),r.options.nonull&&!n.length&&n.push(e),n};F.match=sf;var no=/[?*]|[+@!]\(.*?\)|\[|\]/,of=n=>n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),Ie=class{options;set;pattern;windowsPathsNoEscape;nonegate;negate;comment;empty;preserveMultipleSlashes;partial;globSet;globParts;nocase;isWindows;platform;windowsNoMagicRoot;regexp;constructor(e,t={}){st(e),t=t||{},this.options=t,this.pattern=e,this.platform=t.platform||lo,this.isWindows=this.platform==="win32",this.windowsPathsNoEscape=!!t.windowsPathsNoEscape||t.allowWindowsEscape===!1,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!t.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!t.nonegate,this.comment=!1,this.empty=!1,this.partial=!!t.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=t.windowsNoMagicRoot!==void 0?t.windowsNoMagicRoot:!!(this.isWindows&&this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(let e of this.set)for(let t of e)if(typeof t!="string")return!0;return!1}debug(...e){}make(){let e=this.pattern,t=this.options;if(!t.nocomment&&e.charAt(0)==="#"){this.comment=!0;return}if(!e){this.empty=!0;return}this.parseNegate(),this.globSet=[...new Set(this.braceExpand())],t.debug&&(this.debug=(...i)=>console.error(...i)),this.debug(this.pattern,this.globSet);let r=this.globSet.map(i=>this.slashSplit(i));this.globParts=this.preprocess(r),this.debug(this.pattern,this.globParts);let s=this.globParts.map((i,o,l)=>{if(this.isWindows&&this.windowsNoMagicRoot){let u=i[0]===""&&i[1]===""&&(i[2]==="?"||!no.test(i[2]))&&!no.test(i[3]),a=/^[a-z]:/i.test(i[0]);if(u)return[...i.slice(0,4),...i.slice(4).map(f=>this.parse(f))];if(a)return[i[0],...i.slice(1).map(f=>this.parse(f))]}return i.map(u=>this.parse(u))});if(this.debug(this.pattern,s),this.set=s.filter(i=>i.indexOf(!1)===-1),this.isWindows)for(let i=0;i<this.set.length;i++){let o=this.set[i];o[0]===""&&o[1]===""&&this.globParts[i][2]==="?"&&typeof o[3]=="string"&&/^[a-z]:$/i.test(o[3])&&(o[2]="?")}this.debug(this.pattern,this.set)}preprocess(e){if(this.options.noglobstar)for(let r=0;r<e.length;r++)for(let s=0;s<e[r].length;s++)e[r][s]==="**"&&(e[r][s]="*");let{optimizationLevel:t=1}=this.options;return t>=2?(e=this.firstPhasePreProcess(e),e=this.secondPhasePreProcess(e)):t>=1?e=this.levelOneOptimize(e):e=this.adjascentGlobstarOptimize(e),e}adjascentGlobstarOptimize(e){return e.map(t=>{let r=-1;for(;(r=t.indexOf("**",r+1))!==-1;){let s=r;for(;t[s+1]==="**";)s++;s!==r&&t.splice(r,s-r)}return t})}levelOneOptimize(e){return e.map(t=>(t=t.reduce((r,s)=>{let i=r[r.length-1];return s==="**"&&i==="**"?r:s===".."&&i&&i!==".."&&i!=="."&&i!=="**"?(r.pop(),r):(r.push(s),r)},[]),t.length===0?[""]:t))}levelTwoFileOptimize(e){Array.isArray(e)||(e=this.slashSplit(e));let t=!1;do{if(t=!1,!this.preserveMultipleSlashes){for(let s=1;s<e.length-1;s++){let i=e[s];s===1&&i===""&&e[0]===""||(i==="."||i==="")&&(t=!0,e.splice(s,1),s--)}e[0]==="."&&e.length===2&&(e[1]==="."||e[1]==="")&&(t=!0,e.pop())}let r=0;for(;(r=e.indexOf("..",r+1))!==-1;){let s=e[r-1];s&&s!=="."&&s!==".."&&s!=="**"&&(t=!0,e.splice(r-1,2),r-=2)}}while(t);return e.length===0?[""]:e}firstPhasePreProcess(e){let t=!1;do{t=!1;for(let r of e){let s=-1;for(;(s=r.indexOf("**",s+1))!==-1;){let o=s;for(;r[o+1]==="**";)o++;o>s&&r.splice(s+1,o-s);let l=r[s+1],u=r[s+2],a=r[s+3];if(l!==".."||!u||u==="."||u===".."||!a||a==="."||a==="..")continue;t=!0,r.splice(s,1);let f=r.slice(0);f[s]="**",e.push(f),s--}if(!this.preserveMultipleSlashes){for(let o=1;o<r.length-1;o++){let l=r[o];o===1&&l===""&&r[0]===""||(l==="."||l==="")&&(t=!0,r.splice(o,1),o--)}r[0]==="."&&r.length===2&&(r[1]==="."||r[1]==="")&&(t=!0,r.pop())}let i=0;for(;(i=r.indexOf("..",i+1))!==-1;){let o=r[i-1];if(o&&o!=="."&&o!==".."&&o!=="**"){t=!0;let u=i===1&&r[i+1]==="**"?["."]:[];r.splice(i-1,2,...u),r.length===0&&r.push(""),i-=2}}}}while(t);return e}secondPhasePreProcess(e){for(let t=0;t<e.length-1;t++)for(let r=t+1;r<e.length;r++){let s=this.partsMatch(e[t],e[r],!this.preserveMultipleSlashes);if(s){e[t]=[],e[r]=s;break}}return e.filter(t=>t.length)}partsMatch(e,t,r=!1){let s=0,i=0,o=[],l="";for(;s<e.length&&i<t.length;)if(e[s]===t[i])o.push(l==="b"?t[i]:e[s]),s++,i++;else if(r&&e[s]==="**"&&t[i]===e[s+1])o.push(e[s]),s++;else if(r&&t[i]==="**"&&e[s]===t[i+1])o.push(t[i]),i++;else if(e[s]==="*"&&t[i]&&(this.options.dot||!t[i].startsWith("."))&&t[i]!=="**"){if(l==="b")return!1;l="a",o.push(e[s]),s++,i++}else if(t[i]==="*"&&e[s]&&(this.options.dot||!e[s].startsWith("."))&&e[s]!=="**"){if(l==="a")return!1;l="b",o.push(t[i]),s++,i++}else return!1;return e.length===t.length&&o}parseNegate(){if(this.nonegate)return;let e=this.pattern,t=!1,r=0;for(let s=0;s<e.length&&e.charAt(s)==="!";s++)t=!t,r++;r&&(this.pattern=e.slice(r)),this.negate=t}matchOne(e,t,r=!1){let s=this.options;if(this.isWindows){let d=typeof e[0]=="string"&&/^[a-z]:$/i.test(e[0]),g=!d&&e[0]===""&&e[1]===""&&e[2]==="?"&&/^[a-z]:$/i.test(e[3]),y=typeof t[0]=="string"&&/^[a-z]:$/i.test(t[0]),w=!y&&t[0]===""&&t[1]===""&&t[2]==="?"&&typeof t[3]=="string"&&/^[a-z]:$/i.test(t[3]),b=g?3:d?0:void 0,v=w?3:y?0:void 0;if(typeof b=="number"&&typeof v=="number"){let[E,x]=[e[b],t[v]];E.toLowerCase()===x.toLowerCase()&&(t[v]=E,v>b?t=t.slice(v):b>v&&(e=e.slice(b)))}}let{optimizationLevel:i=1}=this.options;i>=2&&(e=this.levelTwoFileOptimize(e)),this.debug("matchOne",this,{file:e,pattern:t}),this.debug("matchOne",e.length,t.length);for(var o=0,l=0,u=e.length,a=t.length;o<u&&l<a;o++,l++){this.debug("matchOne loop");var f=t[l],h=e[o];if(this.debug(t,f,h),f===!1)return!1;if(f===J){this.debug("GLOBSTAR",[t,f,h]);var c=o,p=l+1;if(p===a){for(this.debug("** at the end");o<u;o++)if(e[o]==="."||e[o]===".."||!s.dot&&e[o].charAt(0)===".")return!1;return!0}for(;c<u;){var m=e[c];if(this.debug(`
|
|
31
|
+
`+t)}function Se(n,e,t,r,s){if(n.listenerCount("wsClientError")){let i=new Error(s);Error.captureStackTrace(i,Se),n.emit("wsClientError",i,t,e)}else rt(t,r,s)}});var $i=S((wc,ji)=>{"use strict";ji.exports=Di;function Di(n,e,t){n instanceof RegExp&&(n=Ui(n,t)),e instanceof RegExp&&(e=Ui(e,t));var r=Wi(n,e,t);return r&&{start:r[0],end:r[1],pre:t.slice(0,r[0]),body:t.slice(r[0]+n.length,r[1]),post:t.slice(r[1]+e.length)}}function Ui(n,e){var t=e.match(n);return t?t[0]:null}Di.range=Wi;function Wi(n,e,t){var r,s,i,o,l,u=t.indexOf(n),a=t.indexOf(e,u+1),f=u;if(u>=0&&a>0){if(n===e)return[u,a];for(r=[],i=t.length;f>=0&&!l;)f==u?(r.push(f),u=t.indexOf(n,f+1)):r.length==1?l=[r.pop(),a]:(s=r.pop(),s<i&&(i=s,o=a),a=t.indexOf(e,f+1)),f=u<a&&u>=0?u:a;r.length&&(l=[i,o])}return l}});var Qi=S((Sc,Ji)=>{var qi=$i();Ji.exports=wu;var Gi="\0SLASH"+Math.random()+"\0",zi="\0OPEN"+Math.random()+"\0",Gr="\0CLOSE"+Math.random()+"\0",Vi="\0COMMA"+Math.random()+"\0",Hi="\0PERIOD"+Math.random()+"\0";function qr(n){return parseInt(n,10)==n?parseInt(n,10):n.charCodeAt(0)}function _u(n){return n.split("\\\\").join(Gi).split("\\{").join(zi).split("\\}").join(Gr).split("\\,").join(Vi).split("\\.").join(Hi)}function yu(n){return n.split(Gi).join("\\").split(zi).join("{").split(Gr).join("}").split(Vi).join(",").split(Hi).join(".")}function Yi(n){if(!n)return[""];var e=[],t=qi("{","}",n);if(!t)return n.split(",");var r=t.pre,s=t.body,i=t.post,o=r.split(",");o[o.length-1]+="{"+s+"}";var l=Yi(i);return i.length&&(o[o.length-1]+=l.shift(),o.push.apply(o,l)),e.push.apply(e,o),e}function wu(n){return n?(n.substr(0,2)==="{}"&&(n="\\{\\}"+n.substr(2)),nt(_u(n),!0).map(yu)):[]}function Su(n){return"{"+n+"}"}function vu(n){return/^-?0\d/.test(n)}function xu(n,e){return n<=e}function bu(n,e){return n>=e}function nt(n,e){var t=[],r=qi("{","}",n);if(!r)return[n];var s=r.pre,i=r.post.length?nt(r.post,!1):[""];if(/\$$/.test(r.pre))for(var o=0;o<i.length;o++){var l=s+"{"+r.body+"}"+i[o];t.push(l)}else{var u=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(r.body),a=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(r.body),f=u||a,h=r.body.indexOf(",")>=0;if(!f&&!h)return r.post.match(/,.*\}/)?(n=r.pre+"{"+r.body+Gr+r.post,nt(n)):[n];var c;if(f)c=r.body.split(/\.\./);else if(c=Yi(r.body),c.length===1&&(c=nt(c[0],!1).map(Su),c.length===1))return i.map(function(P){return r.pre+c[0]+P});var p;if(f){var m=qr(c[0]),d=qr(c[1]),g=Math.max(c[0].length,c[1].length),y=c.length==3?Math.abs(qr(c[2])):1,w=xu,b=d<m;b&&(y*=-1,w=bu);var v=c.some(vu);p=[];for(var E=m;w(E,d);E+=y){var x;if(a)x=String.fromCharCode(E),x==="\\"&&(x="");else if(x=String(E),v){var R=g-x.length;if(R>0){var N=new Array(R+1).join("0");E<0?x="-"+N+x.slice(1):x=N+x}}p.push(x)}}else{p=[];for(var C=0;C<c.length;C++)p.push.apply(p,nt(c[C],!1))}for(var C=0;C<p.length;C++)for(var o=0;o<i.length;o++){var l=s+p[C]+i[o];(!e||f||l)&&t.push(l)}}return t}});var ho=S(Jr=>{"use strict";Object.defineProperty(Jr,"__esModule",{value:!0});Jr.default=ff;var ot="diff-sequences",W=0,lt=(n,e,t,r,s)=>{let i=0;for(;n<e&&t<r&&s(n,t);)n+=1,t+=1,i+=1;return i},at=(n,e,t,r,s)=>{let i=0;for(;n<=e&&t<=r&&s(e,r);)e-=1,r-=1,i+=1;return i},Hr=(n,e,t,r,s,i,o)=>{let l=0,u=-n,a=i[l],f=a;i[l]+=lt(a+1,e,r+a-u+1,t,s);let h=n<o?n:o;for(l+=1,u+=2;l<=h;l+=1,u+=2){if(l!==n&&f<i[l])a=i[l];else if(a=f+1,e<=a)return l-1;f=i[l],i[l]=a+lt(a+1,e,r+a-u+1,t,s)}return o},uo=(n,e,t,r,s,i,o)=>{let l=0,u=n,a=i[l],f=a;i[l]-=at(e,a-1,t,r+a-u-1,s);let h=n<o?n:o;for(l+=1,u-=2;l<=h;l+=1,u-=2){if(l!==n&&i[l]<f)a=i[l];else if(a=f-1,a<e)return l-1;f=i[l],i[l]=a-at(e,a-1,t,r+a-u-1,s)}return o},lf=(n,e,t,r,s,i,o,l,u,a,f)=>{let h=r-e,c=t-e,m=s-r-c,d=-m-(n-1),g=-m+(n-1),y=W,w=n<l?n:l;for(let b=0,v=-n;b<=w;b+=1,v+=2){let E=b===0||b!==n&&y<o[b],x=E?o[b]:y,R=E?x:x+1,N=h+R-v,C=lt(R+1,t,N+1,s,i),P=R+C;if(y=o[b],o[b]=P,d<=v&&v<=g){let pe=(n-1-(v+m))/2;if(pe<=a&&u[pe]-1<=P){let ee=h+x-(E?v+1:v-1),G=at(e,x,r,ee,i),ae=x-G,ut=ee-G,ve=ae+1,jt=ut+1;f.nChangePreceding=n-1,n-1===ve+jt-e-r?(f.aEndPreceding=e,f.bEndPreceding=r):(f.aEndPreceding=ve,f.bEndPreceding=jt),f.nCommonPreceding=G,G!==0&&(f.aCommonPreceding=ve,f.bCommonPreceding=jt),f.nCommonFollowing=C,C!==0&&(f.aCommonFollowing=R+1,f.bCommonFollowing=N+1);let Xr=P+1,en=N+C+1;return f.nChangeFollowing=n-1,n-1===t+s-Xr-en?(f.aStartFollowing=t,f.bStartFollowing=s):(f.aStartFollowing=Xr,f.bStartFollowing=en),!0}}}return!1},af=(n,e,t,r,s,i,o,l,u,a,f)=>{let h=s-t,c=t-e,m=s-r-c,d=m-n,g=m+n,y=W,w=n<a?n:a;for(let b=0,v=n;b<=w;b+=1,v-=2){let E=b===0||b!==n&&u[b]<y,x=E?u[b]:y,R=E?x:x-1,N=h+R-v,C=at(e,R-1,r,N-1,i),P=R-C;if(y=u[b],u[b]=P,d<=v&&v<=g){let pe=(n+(v-m))/2;if(pe<=l&&P-1<=o[pe]){let ee=N-C;if(f.nChangePreceding=n,n===P+ee-e-r?(f.aEndPreceding=e,f.bEndPreceding=r):(f.aEndPreceding=P,f.bEndPreceding=ee),f.nCommonPreceding=C,C!==0&&(f.aCommonPreceding=P,f.bCommonPreceding=ee),f.nChangeFollowing=n-1,n===1)f.nCommonFollowing=0,f.aStartFollowing=t,f.bStartFollowing=s;else{let G=h+x-(E?v-1:v+1),ae=lt(x,t,G,s,i);f.nCommonFollowing=ae,ae!==0&&(f.aCommonFollowing=x,f.bCommonFollowing=G);let ut=x+ae,ve=G+ae;n-1===t+s-ut-ve?(f.aStartFollowing=t,f.bStartFollowing=s):(f.aStartFollowing=ut,f.bStartFollowing=ve)}return!0}}}return!1},uf=(n,e,t,r,s,i,o,l,u)=>{let a=r-e,f=s-t,h=t-e,c=s-r,p=c-h,m=h,d=h;if(o[0]=e-1,l[0]=t,p%2===0){let g=(n||p)/2,y=(h+c)/2;for(let w=1;w<=y;w+=1)if(m=Hr(w,t,s,a,i,o,m),w<g)d=uo(w,e,r,f,i,l,d);else if(af(w,e,t,r,s,i,o,m,l,d,u))return}else{let g=((n||p)+1)/2,y=(h+c+1)/2,w=1;for(m=Hr(w,t,s,a,i,o,m),w+=1;w<=y;w+=1)if(d=uo(w-1,e,r,f,i,l,d),w<g)m=Hr(w,t,s,a,i,o,m);else if(lf(w,e,t,r,s,i,o,m,l,d,u))return}throw new Error(`${ot}: no overlap aStart=${e} aEnd=${t} bStart=${r} bEnd=${s}`)},Yr=(n,e,t,r,s,i,o,l,u,a)=>{if(s-r<t-e){if(i=!i,i&&o.length===1){let{foundSubsequence:P,isCommon:pe}=o[0];o[1]={foundSubsequence:(ee,G,ae)=>{P(ee,ae,G)},isCommon:(ee,G)=>pe(G,ee)}}let N=e,C=t;e=r,t=s,r=N,s=C}let{foundSubsequence:f,isCommon:h}=o[i?1:0];uf(n,e,t,r,s,h,l,u,a);let{nChangePreceding:c,aEndPreceding:p,bEndPreceding:m,nCommonPreceding:d,aCommonPreceding:g,bCommonPreceding:y,nCommonFollowing:w,aCommonFollowing:b,bCommonFollowing:v,nChangeFollowing:E,aStartFollowing:x,bStartFollowing:R}=a;e<p&&r<m&&Yr(c,e,p,r,m,i,o,l,u,a),d!==0&&f(d,g,y),w!==0&&f(w,b,v),x<t&&R<s&&Yr(E,x,t,R,s,i,o,l,u,a)},fo=(n,e)=>{if(typeof e!="number")throw new TypeError(`${ot}: ${n} typeof ${typeof e} is not a number`);if(!Number.isSafeInteger(e))throw new RangeError(`${ot}: ${n} value ${e} is not a safe integer`);if(e<0)throw new RangeError(`${ot}: ${n} value ${e} is a negative integer`)},co=(n,e)=>{let t=typeof e;if(t!=="function")throw new TypeError(`${ot}: ${n} typeof ${t} is not a function`)};function ff(n,e,t,r){fo("aLength",n),fo("bLength",e),co("isCommon",t),co("foundSubsequence",r);let s=lt(0,n,0,e,t);if(s!==0&&r(s,0,0),n!==s||e!==s){let i=s,o=s,l=at(i,n-1,o,e-1,t),u=n-l,a=e-l,f=s+l;n!==f&&e!==f&&Yr(0,i,u,o,a,!1,[{foundSubsequence:r,isCommon:t}],[W],[W],{aCommonFollowing:W,aCommonPreceding:W,aEndPreceding:W,aStartFollowing:W,bCommonFollowing:W,bCommonPreceding:W,bEndPreceding:W,bStartFollowing:W,nChangeFollowing:W,nChangePreceding:W,nCommonFollowing:W,nCommonPreceding:W}),l!==0&&r(l,u,a)}}});var vf={};No(vf,{WebSocket:()=>Fi,convertSourceMap:()=>Sf,diffSequence:()=>Eo.default,findUpSync:()=>wo,minimatch:()=>F,parseCss:()=>bo.default,supportsColor:()=>xo});module.exports=Mo(vf);var Sf=U(nn()),bo=U(Ms());var pu=U(Is(),1),du=U(Mr(),1),mu=U(kr(),1),Bi=U(jr(),1),gu=U(Ii(),1);var Fi=Bi.default;var so=U(Qi(),1);var st=n=>{if(typeof n!="string")throw new TypeError("invalid pattern");if(n.length>65536)throw new TypeError("pattern is too long")};var Eu={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},it=n=>n.replace(/[[\]\\-]/g,"\\$&"),Cu=n=>n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),Ki=n=>n.join(""),Zi=(n,e)=>{let t=e;if(n.charAt(t)!=="[")throw new Error("not in a brace expression");let r=[],s=[],i=t+1,o=!1,l=!1,u=!1,a=!1,f=t,h="";e:for(;i<n.length;){let d=n.charAt(i);if((d==="!"||d==="^")&&i===t+1){a=!0,i++;continue}if(d==="]"&&o&&!u){f=i+1;break}if(o=!0,d==="\\"&&!u){u=!0,i++;continue}if(d==="["&&!u){for(let[g,[y,w,b]]of Object.entries(Eu))if(n.startsWith(g,i)){if(h)return["$.",!1,n.length-t,!0];i+=g.length,b?s.push(y):r.push(y),l=l||w;continue e}}if(u=!1,h){d>h?r.push(it(h)+"-"+it(d)):d===h&&r.push(it(d)),h="",i++;continue}if(n.startsWith("-]",i+1)){r.push(it(d+"-")),i+=2;continue}if(n.startsWith("-",i+1)){h=d,i+=2;continue}r.push(it(d)),i++}if(f<i)return["",!1,0,!1];if(!r.length&&!s.length)return["$.",!1,n.length-t,!0];if(s.length===0&&r.length===1&&/^\\?.$/.test(r[0])&&!a){let d=r[0].length===2?r[0].slice(-1):r[0];return[Cu(d),!1,f-t,!1]}let c="["+(a?"^":"")+Ki(r)+"]",p="["+(a?"":"^")+Ki(s)+"]";return[r.length&&s.length?"("+c+"|"+p+")":r.length?c:p,l,f-t,!0]};var he=(n,{windowsPathsNoEscape:e=!1}={})=>e?n.replace(/\[([^\/\\])\]/g,"$1"):n.replace(/((?!\\).|^)\[([^\/\\])\]/g,"$1$2").replace(/\\([^\/])/g,"$1");var Ou=new Set(["!","?","+","*","@"]),Xi=n=>Ou.has(n),Lu="(?!(?:^|/)\\.\\.?(?:$|/))",Ft="(?!\\.)",Tu=new Set(["[","."]),Au=new Set(["..","."]),Nu=new Set("().*{}+?[]^$\\!"),Mu=n=>n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),zr="[^/]",eo=zr+"*?",to=zr+"+?",ke=class n{type;#r;#n;#i=!1;#e=[];#t;#o;#a;#l=!1;#s;#u;#c=!1;constructor(e,t,r={}){this.type=e,e&&(this.#n=!0),this.#t=t,this.#r=this.#t?this.#t.#r:this,this.#s=this.#r===this?r:this.#r.#s,this.#a=this.#r===this?[]:this.#r.#a,e==="!"&&!this.#r.#l&&this.#a.push(this),this.#o=this.#t?this.#t.#e.length:0}get hasMagic(){if(this.#n!==void 0)return this.#n;for(let e of this.#e)if(typeof e!="string"&&(e.type||e.hasMagic))return this.#n=!0;return this.#n}toString(){return this.#u!==void 0?this.#u:this.type?this.#u=this.type+"("+this.#e.map(e=>String(e)).join("|")+")":this.#u=this.#e.map(e=>String(e)).join("")}#p(){if(this!==this.#r)throw new Error("should only call on root");if(this.#l)return this;this.toString(),this.#l=!0;let e;for(;e=this.#a.pop();){if(e.type!=="!")continue;let t=e,r=t.#t;for(;r;){for(let s=t.#o+1;!r.type&&s<r.#e.length;s++)for(let i of e.#e){if(typeof i=="string")throw new Error("string part in extglob AST??");i.copyIn(r.#e[s])}t=r,r=t.#t}}return this}push(...e){for(let t of e)if(t!==""){if(typeof t!="string"&&!(t instanceof n&&t.#t===this))throw new Error("invalid part: "+t);this.#e.push(t)}}toJSON(){var t;let e=this.type===null?this.#e.slice().map(r=>typeof r=="string"?r:r.toJSON()):[this.type,...this.#e.map(r=>r.toJSON())];return this.isStart()&&!this.type&&e.unshift([]),this.isEnd()&&(this===this.#r||this.#r.#l&&((t=this.#t)==null?void 0:t.type)==="!")&&e.push({}),e}isStart(){var t;if(this.#r===this)return!0;if(!((t=this.#t)!=null&&t.isStart()))return!1;if(this.#o===0)return!0;let e=this.#t;for(let r=0;r<this.#o;r++){let s=e.#e[r];if(!(s instanceof n&&s.type==="!"))return!1}return!0}isEnd(){var t,r,s;if(this.#r===this||((t=this.#t)==null?void 0:t.type)==="!")return!0;if(!((r=this.#t)!=null&&r.isEnd()))return!1;if(!this.type)return(s=this.#t)==null?void 0:s.isEnd();let e=this.#t?this.#t.#e.length:0;return this.#o===e-1}copyIn(e){typeof e=="string"?this.push(e):this.push(e.clone(this))}clone(e){let t=new n(this.type,e);for(let r of this.#e)t.copyIn(r);return t}static#f(e,t,r,s){let i=!1,o=!1,l=-1,u=!1;if(t.type===null){let p=r,m="";for(;p<e.length;){let d=e.charAt(p++);if(i||d==="\\"){i=!i,m+=d;continue}if(o){p===l+1?(d==="^"||d==="!")&&(u=!0):d==="]"&&!(p===l+2&&u)&&(o=!1),m+=d;continue}else if(d==="["){o=!0,l=p,u=!1,m+=d;continue}if(!s.noext&&Xi(d)&&e.charAt(p)==="("){t.push(m),m="";let g=new n(d,t);p=n.#f(e,g,p,s),t.push(g);continue}m+=d}return t.push(m),p}let a=r+1,f=new n(null,t),h=[],c="";for(;a<e.length;){let p=e.charAt(a++);if(i||p==="\\"){i=!i,c+=p;continue}if(o){a===l+1?(p==="^"||p==="!")&&(u=!0):p==="]"&&!(a===l+2&&u)&&(o=!1),c+=p;continue}else if(p==="["){o=!0,l=a,u=!1,c+=p;continue}if(Xi(p)&&e.charAt(a)==="("){f.push(c),c="";let m=new n(p,f);f.push(m),a=n.#f(e,m,a,s);continue}if(p==="|"){f.push(c),c="",h.push(f),f=new n(null,t);continue}if(p===")")return c===""&&t.#e.length===0&&(t.#c=!0),f.push(c),c="",t.push(...h,f),a;c+=p}return t.type=null,t.#n=void 0,t.#e=[e.substring(r-1)],a}static fromGlob(e,t={}){let r=new n(null,void 0,t);return n.#f(e,r,0,t),r}toMMPattern(){if(this!==this.#r)return this.#r.toMMPattern();let e=this.toString(),[t,r,s,i]=this.toRegExpSource();if(!(s||this.#n||this.#s.nocase&&!this.#s.nocaseMagicOnly&&e.toUpperCase()!==e.toLowerCase()))return r;let l=(this.#s.nocase?"i":"")+(i?"u":"");return Object.assign(new RegExp(`^${t}$`,l),{_src:t,_glob:e})}get options(){return this.#s}toRegExpSource(e){var u;let t=e??!!this.#s.dot;if(this.#r===this&&this.#p(),!this.type){let a=this.isStart()&&this.isEnd(),f=this.#e.map(m=>{let[d,g,y,w]=typeof m=="string"?n.#d(m,this.#n,a):m.toRegExpSource(e);return this.#n=this.#n||y,this.#i=this.#i||w,d}).join(""),h="";if(this.isStart()&&typeof this.#e[0]=="string"&&!(this.#e.length===1&&Au.has(this.#e[0]))){let d=Tu,g=t&&d.has(f.charAt(0))||f.startsWith("\\.")&&d.has(f.charAt(2))||f.startsWith("\\.\\.")&&d.has(f.charAt(4)),y=!t&&!e&&d.has(f.charAt(0));h=g?Lu:y?Ft:""}let c="";return this.isEnd()&&this.#r.#l&&((u=this.#t)==null?void 0:u.type)==="!"&&(c="(?:$|\\/)"),[h+f+c,he(f),this.#n=!!this.#n,this.#i]}let r=this.type==="*"||this.type==="+",s=this.type==="!"?"(?:(?!(?:":"(?:",i=this.#h(t);if(this.isStart()&&this.isEnd()&&!i&&this.type!=="!"){let a=this.toString();return this.#e=[a],this.type=null,this.#n=void 0,[a,he(this.toString()),!1,!1]}let o=!r||e||t||!Ft?"":this.#h(!0);o===i&&(o=""),o&&(i=`(?:${i})(?:${o})*?`);let l="";if(this.type==="!"&&this.#c)l=(this.isStart()&&!t?Ft:"")+to;else{let a=this.type==="!"?"))"+(this.isStart()&&!t&&!e?Ft:"")+eo+")":this.type==="@"?")":this.type==="?"?")?":this.type==="+"&&o?")":this.type==="*"&&o?")?":`)${this.type}`;l=s+i+a}return[l,he(i),this.#n=!!this.#n,this.#i]}#h(e){return this.#e.map(t=>{if(typeof t=="string")throw new Error("string type in extglob ast??");let[r,s,i,o]=t.toRegExpSource(e);return this.#i=this.#i||o,r}).filter(t=>!(this.isStart()&&this.isEnd())||!!t).join("|")}static#d(e,t,r=!1){let s=!1,i="",o=!1;for(let l=0;l<e.length;l++){let u=e.charAt(l);if(s){s=!1,i+=(Nu.has(u)?"\\":"")+u;continue}if(u==="\\"){l===e.length-1?i+="\\\\":s=!0;continue}if(u==="["){let[a,f,h,c]=Zi(e,l);if(h){i+=a,o=o||f,l+=h-1,t=t||c;continue}}if(u==="*"){r&&e==="*"?i+=to:i+=eo,t=!0;continue}if(u==="?"){i+=zr,t=!0;continue}i+=Mu(u)}return[i,he(e),!!t,o]}};var Vr=(n,{windowsPathsNoEscape:e=!1}={})=>e?n.replace(/[?*()[\]]/g,"[$&]"):n.replace(/[?*()[\]\\]/g,"\\$&");var F=(n,e,t={})=>(st(e),!t.nocomment&&e.charAt(0)==="#"?!1:new Ie(e,t).match(n)),Ru=/^\*+([^+@!?\*\[\(]*)$/,Pu=n=>e=>!e.startsWith(".")&&e.endsWith(n),ku=n=>e=>e.endsWith(n),Iu=n=>(n=n.toLowerCase(),e=>!e.startsWith(".")&&e.toLowerCase().endsWith(n)),Bu=n=>(n=n.toLowerCase(),e=>e.toLowerCase().endsWith(n)),Fu=/^\*+\.\*+$/,Uu=n=>!n.startsWith(".")&&n.includes("."),Du=n=>n!=="."&&n!==".."&&n.includes("."),Wu=/^\.\*+$/,ju=n=>n!=="."&&n!==".."&&n.startsWith("."),$u=/^\*+$/,qu=n=>n.length!==0&&!n.startsWith("."),Gu=n=>n.length!==0&&n!=="."&&n!=="..",zu=/^\?+([^+@!?\*\[\(]*)?$/,Vu=([n,e=""])=>{let t=io([n]);return e?(e=e.toLowerCase(),r=>t(r)&&r.toLowerCase().endsWith(e)):t},Hu=([n,e=""])=>{let t=oo([n]);return e?(e=e.toLowerCase(),r=>t(r)&&r.toLowerCase().endsWith(e)):t},Yu=([n,e=""])=>{let t=oo([n]);return e?r=>t(r)&&r.endsWith(e):t},Ju=([n,e=""])=>{let t=io([n]);return e?r=>t(r)&&r.endsWith(e):t},io=([n])=>{let e=n.length;return t=>t.length===e&&!t.startsWith(".")},oo=([n])=>{let e=n.length;return t=>t.length===e&&t!=="."&&t!==".."},lo=typeof process=="object"&&process?typeof process.env=="object"&&process.env&&process.env.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix",ro={win32:{sep:"\\"},posix:{sep:"/"}},Qu=lo==="win32"?ro.win32.sep:ro.posix.sep;F.sep=Qu;var J=Symbol("globstar **");F.GLOBSTAR=J;var Ku="[^/]",Zu=Ku+"*?",Xu="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?",ef="(?:(?!(?:\\/|^)\\.).)*?",tf=(n,e={})=>t=>F(t,n,e);F.filter=tf;var Y=(n,e={})=>Object.assign({},n,e),rf=n=>{if(!n||typeof n!="object"||!Object.keys(n).length)return F;let e=F;return Object.assign((r,s,i={})=>e(r,s,Y(n,i)),{Minimatch:class extends e.Minimatch{constructor(s,i={}){super(s,Y(n,i))}static defaults(s){return e.defaults(Y(n,s)).Minimatch}},AST:class extends e.AST{constructor(s,i,o={}){super(s,i,Y(n,o))}static fromGlob(s,i={}){return e.AST.fromGlob(s,Y(n,i))}},unescape:(r,s={})=>e.unescape(r,Y(n,s)),escape:(r,s={})=>e.escape(r,Y(n,s)),filter:(r,s={})=>e.filter(r,Y(n,s)),defaults:r=>e.defaults(Y(n,r)),makeRe:(r,s={})=>e.makeRe(r,Y(n,s)),braceExpand:(r,s={})=>e.braceExpand(r,Y(n,s)),match:(r,s,i={})=>e.match(r,s,Y(n,i)),sep:e.sep,GLOBSTAR:J})};F.defaults=rf;var ao=(n,e={})=>(st(n),e.nobrace||!/\{(?:(?!\{).)*\}/.test(n)?[n]:(0,so.default)(n));F.braceExpand=ao;var nf=(n,e={})=>new Ie(n,e).makeRe();F.makeRe=nf;var sf=(n,e,t={})=>{let r=new Ie(e,t);return n=n.filter(s=>r.match(s)),r.options.nonull&&!n.length&&n.push(e),n};F.match=sf;var no=/[?*]|[+@!]\(.*?\)|\[|\]/,of=n=>n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),Ie=class{options;set;pattern;windowsPathsNoEscape;nonegate;negate;comment;empty;preserveMultipleSlashes;partial;globSet;globParts;nocase;isWindows;platform;windowsNoMagicRoot;regexp;constructor(e,t={}){st(e),t=t||{},this.options=t,this.pattern=e,this.platform=t.platform||lo,this.isWindows=this.platform==="win32",this.windowsPathsNoEscape=!!t.windowsPathsNoEscape||t.allowWindowsEscape===!1,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!t.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!t.nonegate,this.comment=!1,this.empty=!1,this.partial=!!t.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=t.windowsNoMagicRoot!==void 0?t.windowsNoMagicRoot:!!(this.isWindows&&this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(let e of this.set)for(let t of e)if(typeof t!="string")return!0;return!1}debug(...e){}make(){let e=this.pattern,t=this.options;if(!t.nocomment&&e.charAt(0)==="#"){this.comment=!0;return}if(!e){this.empty=!0;return}this.parseNegate(),this.globSet=[...new Set(this.braceExpand())],t.debug&&(this.debug=(...i)=>console.error(...i)),this.debug(this.pattern,this.globSet);let r=this.globSet.map(i=>this.slashSplit(i));this.globParts=this.preprocess(r),this.debug(this.pattern,this.globParts);let s=this.globParts.map((i,o,l)=>{if(this.isWindows&&this.windowsNoMagicRoot){let u=i[0]===""&&i[1]===""&&(i[2]==="?"||!no.test(i[2]))&&!no.test(i[3]),a=/^[a-z]:/i.test(i[0]);if(u)return[...i.slice(0,4),...i.slice(4).map(f=>this.parse(f))];if(a)return[i[0],...i.slice(1).map(f=>this.parse(f))]}return i.map(u=>this.parse(u))});if(this.debug(this.pattern,s),this.set=s.filter(i=>i.indexOf(!1)===-1),this.isWindows)for(let i=0;i<this.set.length;i++){let o=this.set[i];o[0]===""&&o[1]===""&&this.globParts[i][2]==="?"&&typeof o[3]=="string"&&/^[a-z]:$/i.test(o[3])&&(o[2]="?")}this.debug(this.pattern,this.set)}preprocess(e){if(this.options.noglobstar)for(let r=0;r<e.length;r++)for(let s=0;s<e[r].length;s++)e[r][s]==="**"&&(e[r][s]="*");let{optimizationLevel:t=1}=this.options;return t>=2?(e=this.firstPhasePreProcess(e),e=this.secondPhasePreProcess(e)):t>=1?e=this.levelOneOptimize(e):e=this.adjascentGlobstarOptimize(e),e}adjascentGlobstarOptimize(e){return e.map(t=>{let r=-1;for(;(r=t.indexOf("**",r+1))!==-1;){let s=r;for(;t[s+1]==="**";)s++;s!==r&&t.splice(r,s-r)}return t})}levelOneOptimize(e){return e.map(t=>(t=t.reduce((r,s)=>{let i=r[r.length-1];return s==="**"&&i==="**"?r:s===".."&&i&&i!==".."&&i!=="."&&i!=="**"?(r.pop(),r):(r.push(s),r)},[]),t.length===0?[""]:t))}levelTwoFileOptimize(e){Array.isArray(e)||(e=this.slashSplit(e));let t=!1;do{if(t=!1,!this.preserveMultipleSlashes){for(let s=1;s<e.length-1;s++){let i=e[s];s===1&&i===""&&e[0]===""||(i==="."||i==="")&&(t=!0,e.splice(s,1),s--)}e[0]==="."&&e.length===2&&(e[1]==="."||e[1]==="")&&(t=!0,e.pop())}let r=0;for(;(r=e.indexOf("..",r+1))!==-1;){let s=e[r-1];s&&s!=="."&&s!==".."&&s!=="**"&&(t=!0,e.splice(r-1,2),r-=2)}}while(t);return e.length===0?[""]:e}firstPhasePreProcess(e){let t=!1;do{t=!1;for(let r of e){let s=-1;for(;(s=r.indexOf("**",s+1))!==-1;){let o=s;for(;r[o+1]==="**";)o++;o>s&&r.splice(s+1,o-s);let l=r[s+1],u=r[s+2],a=r[s+3];if(l!==".."||!u||u==="."||u===".."||!a||a==="."||a==="..")continue;t=!0,r.splice(s,1);let f=r.slice(0);f[s]="**",e.push(f),s--}if(!this.preserveMultipleSlashes){for(let o=1;o<r.length-1;o++){let l=r[o];o===1&&l===""&&r[0]===""||(l==="."||l==="")&&(t=!0,r.splice(o,1),o--)}r[0]==="."&&r.length===2&&(r[1]==="."||r[1]==="")&&(t=!0,r.pop())}let i=0;for(;(i=r.indexOf("..",i+1))!==-1;){let o=r[i-1];if(o&&o!=="."&&o!==".."&&o!=="**"){t=!0;let u=i===1&&r[i+1]==="**"?["."]:[];r.splice(i-1,2,...u),r.length===0&&r.push(""),i-=2}}}}while(t);return e}secondPhasePreProcess(e){for(let t=0;t<e.length-1;t++)for(let r=t+1;r<e.length;r++){let s=this.partsMatch(e[t],e[r],!this.preserveMultipleSlashes);if(s){e[t]=[],e[r]=s;break}}return e.filter(t=>t.length)}partsMatch(e,t,r=!1){let s=0,i=0,o=[],l="";for(;s<e.length&&i<t.length;)if(e[s]===t[i])o.push(l==="b"?t[i]:e[s]),s++,i++;else if(r&&e[s]==="**"&&t[i]===e[s+1])o.push(e[s]),s++;else if(r&&t[i]==="**"&&e[s]===t[i+1])o.push(t[i]),i++;else if(e[s]==="*"&&t[i]&&(this.options.dot||!t[i].startsWith("."))&&t[i]!=="**"){if(l==="b")return!1;l="a",o.push(e[s]),s++,i++}else if(t[i]==="*"&&e[s]&&(this.options.dot||!e[s].startsWith("."))&&e[s]!=="**"){if(l==="a")return!1;l="b",o.push(t[i]),s++,i++}else return!1;return e.length===t.length&&o}parseNegate(){if(this.nonegate)return;let e=this.pattern,t=!1,r=0;for(let s=0;s<e.length&&e.charAt(s)==="!";s++)t=!t,r++;r&&(this.pattern=e.slice(r)),this.negate=t}matchOne(e,t,r=!1){let s=this.options;if(this.isWindows){let d=typeof e[0]=="string"&&/^[a-z]:$/i.test(e[0]),g=!d&&e[0]===""&&e[1]===""&&e[2]==="?"&&/^[a-z]:$/i.test(e[3]),y=typeof t[0]=="string"&&/^[a-z]:$/i.test(t[0]),w=!y&&t[0]===""&&t[1]===""&&t[2]==="?"&&typeof t[3]=="string"&&/^[a-z]:$/i.test(t[3]),b=g?3:d?0:void 0,v=w?3:y?0:void 0;if(typeof b=="number"&&typeof v=="number"){let[E,x]=[e[b],t[v]];E.toLowerCase()===x.toLowerCase()&&(t[v]=E,v>b?t=t.slice(v):b>v&&(e=e.slice(b)))}}let{optimizationLevel:i=1}=this.options;i>=2&&(e=this.levelTwoFileOptimize(e)),this.debug("matchOne",this,{file:e,pattern:t}),this.debug("matchOne",e.length,t.length);for(var o=0,l=0,u=e.length,a=t.length;o<u&&l<a;o++,l++){this.debug("matchOne loop");var f=t[l],h=e[o];if(this.debug(t,f,h),f===!1)return!1;if(f===J){this.debug("GLOBSTAR",[t,f,h]);var c=o,p=l+1;if(p===a){for(this.debug("** at the end");o<u;o++)if(e[o]==="."||e[o]===".."||!s.dot&&e[o].charAt(0)===".")return!1;return!0}for(;c<u;){var m=e[c];if(this.debug(`
|
|
32
32
|
globstar while`,e,c,t,p,m),this.matchOne(e.slice(c),t.slice(p),r))return this.debug("globstar found match!",c,u,m),!0;if(m==="."||m===".."||!s.dot&&m.charAt(0)==="."){this.debug("dot detected!",e,c,t,p);break}this.debug("globstar swallow a segment, and continue"),c++}return!!(r&&(this.debug(`
|
|
33
|
-
>>> no match, partial?`,e,c,t,p),c===u))}let d;if(typeof f=="string"?(d=h===f,this.debug("string match",f,h,d)):(d=f.test(h),this.debug("pattern match",f,h,d)),!d)return!1}if(o===u&&l===a)return!0;if(o===u)return r;if(l===a)return o===u-1&&e[o]==="";throw new Error("wtf?")}braceExpand(){return ao(this.pattern,this.options)}parse(e){st(e);let t=this.options;if(e==="**")return J;if(e==="")return"";let r,s=null;(r=e.match($u))?s=t.dot?Gu:qu:(r=e.match(
|
|
33
|
+
>>> no match, partial?`,e,c,t,p),c===u))}let d;if(typeof f=="string"?(d=h===f,this.debug("string match",f,h,d)):(d=f.test(h),this.debug("pattern match",f,h,d)),!d)return!1}if(o===u&&l===a)return!0;if(o===u)return r;if(l===a)return o===u-1&&e[o]==="";throw new Error("wtf?")}braceExpand(){return ao(this.pattern,this.options)}parse(e){st(e);let t=this.options;if(e==="**")return J;if(e==="")return"";let r,s=null;(r=e.match($u))?s=t.dot?Gu:qu:(r=e.match(Ru))?s=(t.nocase?t.dot?Bu:Iu:t.dot?ku:Pu)(r[1]):(r=e.match(zu))?s=(t.nocase?t.dot?Hu:Vu:t.dot?Yu:Ju)(r):(r=e.match(Fu))?s=t.dot?Du:Uu:(r=e.match(Wu))&&(s=ju);let i=ke.fromGlob(e,this.options).toMMPattern();return s&&typeof i=="object"&&Reflect.defineProperty(i,"test",{value:s}),i}makeRe(){if(this.regexp||this.regexp===!1)return this.regexp;let e=this.set;if(!e.length)return this.regexp=!1,this.regexp;let t=this.options,r=t.noglobstar?Zu:t.dot?Xu:ef,s=new Set(t.nocase?["i"]:[]),i=e.map(u=>{let a=u.map(f=>{if(f instanceof RegExp)for(let h of f.flags.split(""))s.add(h);return typeof f=="string"?of(f):f===J?J:f._src});return a.forEach((f,h)=>{let c=a[h+1],p=a[h-1];f!==J||p===J||(p===void 0?c!==void 0&&c!==J?a[h+1]="(?:\\/|"+r+"\\/)?"+c:a[h]=r:c===void 0?a[h-1]=p+"(?:\\/|"+r+")?":c!==J&&(a[h-1]=p+"(?:\\/|\\/"+r+"\\/)"+c,a[h+1]=J))}),a.filter(f=>f!==J).join("/")}).join("|"),[o,l]=e.length>1?["(?:",")"]:["",""];i="^"+o+i+l+"$",this.negate&&(i="^(?!"+i+").+$");try{this.regexp=new RegExp(i,[...s].join(""))}catch{this.regexp=!1}return this.regexp}slashSplit(e){return this.preserveMultipleSlashes?e.split("/"):this.isWindows&&/^\/\/[^\/]+/.test(e)?["",...e.split(/\/+/)]:e.split(/\/+/)}match(e,t=this.partial){if(this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return e==="";if(e==="/"&&t)return!0;let r=this.options;this.isWindows&&(e=e.split("\\").join("/"));let s=this.slashSplit(e);this.debug(this.pattern,"split",s);let i=this.set;this.debug(this.pattern,"set",i);let o=s[s.length-1];if(!o)for(let l=s.length-2;!o&&l>=0;l--)o=s[l];for(let l=0;l<i.length;l++){let u=i[l],a=s;if(r.matchBase&&u.length===1&&(a=[o]),this.matchOne(a,u,t))return r.flipNegate?!0:!this.negate}return r.flipNegate?!1:this.negate}static defaults(e){return F.defaults(e).Minimatch}};F.AST=ke;F.Minimatch=Ie;F.escape=Vr;F.unescape=he;var Eo=U(ho());var Be=U(require("node:path"),1);var po=U(require("node:process"),1),mo=U(require("node:path"),1),Ut=U(require("node:fs"),1),go=require("node:url");var _o={directory:"isDirectory",file:"isFile"};function cf(n){if(!Object.hasOwnProperty.call(_o,n))throw new Error(`Invalid type specified: ${n}`)}var hf=(n,e)=>e[_o[n]](),pf=n=>n instanceof URL?(0,go.fileURLToPath)(n):n;function Qr(n,{cwd:e=po.default.cwd(),type:t="file",allowSymlinks:r=!0}={}){cf(t),e=pf(e);let s=r?Ut.default.statSync:Ut.default.lstatSync;for(let i of n)try{let o=s(mo.default.resolve(e,i),{throwIfNoEntry:!1});if(!o)continue;if(hf(t,o))return i}catch{}}var yo=require("node:url");function Kr(n){return n instanceof URL?(0,yo.fileURLToPath)(n):n}var df=Symbol("findUpStop");function mf(n,e={}){let t=Be.default.resolve(Kr(e.cwd)??""),{root:r}=Be.default.parse(t),s=Be.default.resolve(t,Kr(e.stopAt)??r),i=e.limit??Number.POSITIVE_INFINITY,o=[n].flat(),l=a=>{if(typeof n!="function")return Qr(o,a);let f=n(a.cwd);return typeof f=="string"?Qr([f],a):f},u=[];for(;;){let a=l({...e,cwd:t});if(a===df||(a&&u.push(Be.default.resolve(t,a)),t===s||u.length>=i))break;t=Be.default.dirname(t)}return u}function wo(n,e={}){return mf(n,{...e,limit:1})[0]}var Wt=U(require("node:process"),1),vo=U(require("node:os"),1),Zr=U(require("node:tty"),1);function Q(n,e=globalThis.Deno?globalThis.Deno.args:Wt.default.argv){let t=n.startsWith("-")?"":n.length===1?"-":"--",r=e.indexOf(t+n),s=e.indexOf("--");return r!==-1&&(s===-1||r<s)}var{env:T}=Wt.default,Dt;Q("no-color")||Q("no-colors")||Q("color=false")||Q("color=never")?Dt=0:(Q("color")||Q("colors")||Q("color=true")||Q("color=always"))&&(Dt=1);function gf(){if("FORCE_COLOR"in T)return T.FORCE_COLOR==="true"?1:T.FORCE_COLOR==="false"?0:T.FORCE_COLOR.length===0?1:Math.min(Number.parseInt(T.FORCE_COLOR,10),3)}function _f(n){return n===0?!1:{level:n,hasBasic:!0,has256:n>=2,has16m:n>=3}}function yf(n,{streamIsTTY:e,sniffFlags:t=!0}={}){let r=gf();r!==void 0&&(Dt=r);let s=t?Dt:r;if(s===0)return 0;if(t){if(Q("color=16m")||Q("color=full")||Q("color=truecolor"))return 3;if(Q("color=256"))return 2}if("TF_BUILD"in T&&"AGENT_NAME"in T)return 1;if(n&&!e&&s===void 0)return 0;let i=s||0;if(T.TERM==="dumb")return i;if(Wt.default.platform==="win32"){let o=vo.default.release().split(".");return Number(o[0])>=10&&Number(o[2])>=10586?Number(o[2])>=14931?3:2:1}if("CI"in T)return"GITHUB_ACTIONS"in T||"GITEA_ACTIONS"in T?3:["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","BUILDKITE","DRONE"].some(o=>o in T)||T.CI_NAME==="codeship"?1:i;if("TEAMCITY_VERSION"in T)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(T.TEAMCITY_VERSION)?1:0;if(T.COLORTERM==="truecolor"||T.TERM==="xterm-kitty")return 3;if("TERM_PROGRAM"in T){let o=Number.parseInt((T.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(T.TERM_PROGRAM){case"iTerm.app":return o>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(T.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(T.TERM)||"COLORTERM"in T?1:i}function So(n,e={}){let t=yf(n,{streamIsTTY:n&&n.isTTY,...e});return _f(t)}var wf={stdout:So({isTTY:Zr.default.isatty(1)}),stderr:So({isTTY:Zr.default.isatty(2)})},xo=wf;0&&(module.exports={WebSocket,convertSourceMap,diffSequence,findUpSync,minimatch,parseCss,supportsColor});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "monocart-coverage-reports",
|
|
3
|
-
"version": "2.10.
|
|
3
|
+
"version": "2.10.2",
|
|
4
4
|
"description": "A code coverage tool to generate native V8 reports or Istanbul reports.",
|
|
5
5
|
"main": "./lib/index.js",
|
|
6
6
|
"bin": {
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
"minimatch": "^9.0.5",
|
|
104
104
|
"monocart-code-viewer": "^1.1.4",
|
|
105
105
|
"monocart-formatter": "^3.0.0",
|
|
106
|
-
"postcss": "^8.4.
|
|
106
|
+
"postcss": "^8.4.41",
|
|
107
107
|
"starfall-cli": "^2.0.20",
|
|
108
108
|
"stylelint": "^16.8.1",
|
|
109
109
|
"stylelint-config-plus": "^1.1.2",
|