main
    1"use strict";
    2const {
    3  __spreadValues,
    4  __spreadProps,
    5  __esm,
    6  __commonJS,
    7  __export,
    8  __toESM,
    9  __toCommonJS,
   10  __privateGet,
   11  __privateAdd,
   12  __privateSet,
   13  __async,
   14  __await,
   15  __asyncGenerator,
   16  __yieldStar,
   17  __forAwait
   18} = require('./esblib.cjs');
   19
   20
   21// node_modules/fast-glob/out/utils/array.js
   22var require_array = __commonJS({
   23  "node_modules/fast-glob/out/utils/array.js"(exports2) {
   24    "use strict";
   25    Object.defineProperty(exports2, "__esModule", { value: true });
   26    exports2.splitWhen = exports2.flatten = void 0;
   27    function flatten(items) {
   28      return items.reduce((collection, item) => [].concat(collection, item), []);
   29    }
   30    exports2.flatten = flatten;
   31    function splitWhen(items, predicate) {
   32      const result = [[]];
   33      let groupIndex = 0;
   34      for (const item of items) {
   35        if (predicate(item)) {
   36          groupIndex++;
   37          result[groupIndex] = [];
   38        } else {
   39          result[groupIndex].push(item);
   40        }
   41      }
   42      return result;
   43    }
   44    exports2.splitWhen = splitWhen;
   45  }
   46});
   47
   48// node_modules/fast-glob/out/utils/errno.js
   49var require_errno = __commonJS({
   50  "node_modules/fast-glob/out/utils/errno.js"(exports2) {
   51    "use strict";
   52    Object.defineProperty(exports2, "__esModule", { value: true });
   53    exports2.isEnoentCodeError = void 0;
   54    function isEnoentCodeError(error) {
   55      return error.code === "ENOENT";
   56    }
   57    exports2.isEnoentCodeError = isEnoentCodeError;
   58  }
   59});
   60
   61// node_modules/fast-glob/out/utils/fs.js
   62var require_fs = __commonJS({
   63  "node_modules/fast-glob/out/utils/fs.js"(exports2) {
   64    "use strict";
   65    Object.defineProperty(exports2, "__esModule", { value: true });
   66    exports2.createDirentFromStats = void 0;
   67    var DirentFromStats = class {
   68      constructor(name, stats) {
   69        this.name = name;
   70        this.isBlockDevice = stats.isBlockDevice.bind(stats);
   71        this.isCharacterDevice = stats.isCharacterDevice.bind(stats);
   72        this.isDirectory = stats.isDirectory.bind(stats);
   73        this.isFIFO = stats.isFIFO.bind(stats);
   74        this.isFile = stats.isFile.bind(stats);
   75        this.isSocket = stats.isSocket.bind(stats);
   76        this.isSymbolicLink = stats.isSymbolicLink.bind(stats);
   77      }
   78    };
   79    function createDirentFromStats(name, stats) {
   80      return new DirentFromStats(name, stats);
   81    }
   82    exports2.createDirentFromStats = createDirentFromStats;
   83  }
   84});
   85
   86// node_modules/fast-glob/out/utils/path.js
   87var require_path = __commonJS({
   88  "node_modules/fast-glob/out/utils/path.js"(exports2) {
   89    "use strict";
   90    Object.defineProperty(exports2, "__esModule", { value: true });
   91    exports2.convertPosixPathToPattern = exports2.convertWindowsPathToPattern = exports2.convertPathToPattern = exports2.escapePosixPath = exports2.escapeWindowsPath = exports2.escape = exports2.removeLeadingDotSegment = exports2.makeAbsolute = exports2.unixify = void 0;
   92    var os = require("os");
   93    var path5 = require("path");
   94    var IS_WINDOWS_PLATFORM = os.platform() === "win32";
   95    var LEADING_DOT_SEGMENT_CHARACTERS_COUNT = 2;
   96    var POSIX_UNESCAPED_GLOB_SYMBOLS_RE = /(\\?)([()*?[\]{|}]|^!|[!+@](?=\()|\\(?![!()*+?@[\]{|}]))/g;
   97    var WINDOWS_UNESCAPED_GLOB_SYMBOLS_RE = /(\\?)([()[\]{}]|^!|[!+@](?=\())/g;
   98    var DOS_DEVICE_PATH_RE = /^\\\\([.?])/;
   99    var WINDOWS_BACKSLASHES_RE = /\\(?![!()+@[\]{}])/g;
  100    function unixify(filepath) {
  101      return filepath.replace(/\\/g, "/");
  102    }
  103    exports2.unixify = unixify;
  104    function makeAbsolute(cwd, filepath) {
  105      return path5.resolve(cwd, filepath);
  106    }
  107    exports2.makeAbsolute = makeAbsolute;
  108    function removeLeadingDotSegment(entry) {
  109      if (entry.charAt(0) === ".") {
  110        const secondCharactery = entry.charAt(1);
  111        if (secondCharactery === "/" || secondCharactery === "\\") {
  112          return entry.slice(LEADING_DOT_SEGMENT_CHARACTERS_COUNT);
  113        }
  114      }
  115      return entry;
  116    }
  117    exports2.removeLeadingDotSegment = removeLeadingDotSegment;
  118    exports2.escape = IS_WINDOWS_PLATFORM ? escapeWindowsPath : escapePosixPath;
  119    function escapeWindowsPath(pattern) {
  120      return pattern.replace(WINDOWS_UNESCAPED_GLOB_SYMBOLS_RE, "\\$2");
  121    }
  122    exports2.escapeWindowsPath = escapeWindowsPath;
  123    function escapePosixPath(pattern) {
  124      return pattern.replace(POSIX_UNESCAPED_GLOB_SYMBOLS_RE, "\\$2");
  125    }
  126    exports2.escapePosixPath = escapePosixPath;
  127    exports2.convertPathToPattern = IS_WINDOWS_PLATFORM ? convertWindowsPathToPattern : convertPosixPathToPattern;
  128    function convertWindowsPathToPattern(filepath) {
  129      return escapeWindowsPath(filepath).replace(DOS_DEVICE_PATH_RE, "//$1").replace(WINDOWS_BACKSLASHES_RE, "/");
  130    }
  131    exports2.convertWindowsPathToPattern = convertWindowsPathToPattern;
  132    function convertPosixPathToPattern(filepath) {
  133      return escapePosixPath(filepath);
  134    }
  135    exports2.convertPosixPathToPattern = convertPosixPathToPattern;
  136  }
  137});
  138
  139// node_modules/is-extglob/index.js
  140var require_is_extglob = __commonJS({
  141  "node_modules/is-extglob/index.js"(exports2, module2) {
  142    "use strict";
  143    module2.exports = function isExtglob(str) {
  144      if (typeof str !== "string" || str === "") {
  145        return false;
  146      }
  147      var match;
  148      while (match = /(\\).|([@?!+*]\(.*\))/g.exec(str)) {
  149        if (match[2]) return true;
  150        str = str.slice(match.index + match[0].length);
  151      }
  152      return false;
  153    };
  154  }
  155});
  156
  157// node_modules/is-glob/index.js
  158var require_is_glob = __commonJS({
  159  "node_modules/is-glob/index.js"(exports2, module2) {
  160    "use strict";
  161    var isExtglob = require_is_extglob();
  162    var chars = { "{": "}", "(": ")", "[": "]" };
  163    var strictCheck = function(str) {
  164      if (str[0] === "!") {
  165        return true;
  166      }
  167      var index = 0;
  168      var pipeIndex = -2;
  169      var closeSquareIndex = -2;
  170      var closeCurlyIndex = -2;
  171      var closeParenIndex = -2;
  172      var backSlashIndex = -2;
  173      while (index < str.length) {
  174        if (str[index] === "*") {
  175          return true;
  176        }
  177        if (str[index + 1] === "?" && /[\].+)]/.test(str[index])) {
  178          return true;
  179        }
  180        if (closeSquareIndex !== -1 && str[index] === "[" && str[index + 1] !== "]") {
  181          if (closeSquareIndex < index) {
  182            closeSquareIndex = str.indexOf("]", index);
  183          }
  184          if (closeSquareIndex > index) {
  185            if (backSlashIndex === -1 || backSlashIndex > closeSquareIndex) {
  186              return true;
  187            }
  188            backSlashIndex = str.indexOf("\\", index);
  189            if (backSlashIndex === -1 || backSlashIndex > closeSquareIndex) {
  190              return true;
  191            }
  192          }
  193        }
  194        if (closeCurlyIndex !== -1 && str[index] === "{" && str[index + 1] !== "}") {
  195          closeCurlyIndex = str.indexOf("}", index);
  196          if (closeCurlyIndex > index) {
  197            backSlashIndex = str.indexOf("\\", index);
  198            if (backSlashIndex === -1 || backSlashIndex > closeCurlyIndex) {
  199              return true;
  200            }
  201          }
  202        }
  203        if (closeParenIndex !== -1 && str[index] === "(" && str[index + 1] === "?" && /[:!=]/.test(str[index + 2]) && str[index + 3] !== ")") {
  204          closeParenIndex = str.indexOf(")", index);
  205          if (closeParenIndex > index) {
  206            backSlashIndex = str.indexOf("\\", index);
  207            if (backSlashIndex === -1 || backSlashIndex > closeParenIndex) {
  208              return true;
  209            }
  210          }
  211        }
  212        if (pipeIndex !== -1 && str[index] === "(" && str[index + 1] !== "|") {
  213          if (pipeIndex < index) {
  214            pipeIndex = str.indexOf("|", index);
  215          }
  216          if (pipeIndex !== -1 && str[pipeIndex + 1] !== ")") {
  217            closeParenIndex = str.indexOf(")", pipeIndex);
  218            if (closeParenIndex > pipeIndex) {
  219              backSlashIndex = str.indexOf("\\", pipeIndex);
  220              if (backSlashIndex === -1 || backSlashIndex > closeParenIndex) {
  221                return true;
  222              }
  223            }
  224          }
  225        }
  226        if (str[index] === "\\") {
  227          var open = str[index + 1];
  228          index += 2;
  229          var close = chars[open];
  230          if (close) {
  231            var n4 = str.indexOf(close, index);
  232            if (n4 !== -1) {
  233              index = n4 + 1;
  234            }
  235          }
  236          if (str[index] === "!") {
  237            return true;
  238          }
  239        } else {
  240          index++;
  241        }
  242      }
  243      return false;
  244    };
  245    var relaxedCheck = function(str) {
  246      if (str[0] === "!") {
  247        return true;
  248      }
  249      var index = 0;
  250      while (index < str.length) {
  251        if (/[*?{}()[\]]/.test(str[index])) {
  252          return true;
  253        }
  254        if (str[index] === "\\") {
  255          var open = str[index + 1];
  256          index += 2;
  257          var close = chars[open];
  258          if (close) {
  259            var n4 = str.indexOf(close, index);
  260            if (n4 !== -1) {
  261              index = n4 + 1;
  262            }
  263          }
  264          if (str[index] === "!") {
  265            return true;
  266          }
  267        } else {
  268          index++;
  269        }
  270      }
  271      return false;
  272    };
  273    module2.exports = function isGlob(str, options) {
  274      if (typeof str !== "string" || str === "") {
  275        return false;
  276      }
  277      if (isExtglob(str)) {
  278        return true;
  279      }
  280      var check = strictCheck;
  281      if (options && options.strict === false) {
  282        check = relaxedCheck;
  283      }
  284      return check(str);
  285    };
  286  }
  287});
  288
  289// node_modules/glob-parent/index.js
  290var require_glob_parent = __commonJS({
  291  "node_modules/glob-parent/index.js"(exports2, module2) {
  292    "use strict";
  293    var isGlob = require_is_glob();
  294    var pathPosixDirname = require("path").posix.dirname;
  295    var isWin32 = require("os").platform() === "win32";
  296    var slash2 = "/";
  297    var backslash = /\\/g;
  298    var enclosure = /[\{\[].*[\}\]]$/;
  299    var globby3 = /(^|[^\\])([\{\[]|\([^\)]+$)/;
  300    var escaped = /\\([\!\*\?\|\[\]\(\)\{\}])/g;
  301    module2.exports = function globParent(str, opts) {
  302      var options = Object.assign({ flipBackslashes: true }, opts);
  303      if (options.flipBackslashes && isWin32 && str.indexOf(slash2) < 0) {
  304        str = str.replace(backslash, slash2);
  305      }
  306      if (enclosure.test(str)) {
  307        str += slash2;
  308      }
  309      str += "a";
  310      do {
  311        str = pathPosixDirname(str);
  312      } while (isGlob(str) || globby3.test(str));
  313      return str.replace(escaped, "$1");
  314    };
  315  }
  316});
  317
  318// node_modules/braces/lib/utils.js
  319var require_utils = __commonJS({
  320  "node_modules/braces/lib/utils.js"(exports2) {
  321    "use strict";
  322    exports2.isInteger = (num) => {
  323      if (typeof num === "number") {
  324        return Number.isInteger(num);
  325      }
  326      if (typeof num === "string" && num.trim() !== "") {
  327        return Number.isInteger(Number(num));
  328      }
  329      return false;
  330    };
  331    exports2.find = (node, type) => node.nodes.find((node2) => node2.type === type);
  332    exports2.exceedsLimit = (min, max, step = 1, limit) => {
  333      if (limit === false) return false;
  334      if (!exports2.isInteger(min) || !exports2.isInteger(max)) return false;
  335      return (Number(max) - Number(min)) / Number(step) >= limit;
  336    };
  337    exports2.escapeNode = (block, n4 = 0, type) => {
  338      const node = block.nodes[n4];
  339      if (!node) return;
  340      if (type && node.type === type || node.type === "open" || node.type === "close") {
  341        if (node.escaped !== true) {
  342          node.value = "\\" + node.value;
  343          node.escaped = true;
  344        }
  345      }
  346    };
  347    exports2.encloseBrace = (node) => {
  348      if (node.type !== "brace") return false;
  349      if (node.commas >> 0 + node.ranges >> 0 === 0) {
  350        node.invalid = true;
  351        return true;
  352      }
  353      return false;
  354    };
  355    exports2.isInvalidBrace = (block) => {
  356      if (block.type !== "brace") return false;
  357      if (block.invalid === true || block.dollar) return true;
  358      if (block.commas >> 0 + block.ranges >> 0 === 0) {
  359        block.invalid = true;
  360        return true;
  361      }
  362      if (block.open !== true || block.close !== true) {
  363        block.invalid = true;
  364        return true;
  365      }
  366      return false;
  367    };
  368    exports2.isOpenOrClose = (node) => {
  369      if (node.type === "open" || node.type === "close") {
  370        return true;
  371      }
  372      return node.open === true || node.close === true;
  373    };
  374    exports2.reduce = (nodes) => nodes.reduce((acc, node) => {
  375      if (node.type === "text") acc.push(node.value);
  376      if (node.type === "range") node.type = "text";
  377      return acc;
  378    }, []);
  379    exports2.flatten = (...args) => {
  380      const result = [];
  381      const flat = (arr) => {
  382        for (let i = 0; i < arr.length; i++) {
  383          const ele = arr[i];
  384          if (Array.isArray(ele)) {
  385            flat(ele);
  386            continue;
  387          }
  388          if (ele !== void 0) {
  389            result.push(ele);
  390          }
  391        }
  392        return result;
  393      };
  394      flat(args);
  395      return result;
  396    };
  397  }
  398});
  399
  400// node_modules/braces/lib/stringify.js
  401var require_stringify = __commonJS({
  402  "node_modules/braces/lib/stringify.js"(exports2, module2) {
  403    "use strict";
  404    var utils = require_utils();
  405    module2.exports = (ast, options = {}) => {
  406      const stringify6 = (node, parent = {}) => {
  407        const invalidBlock = options.escapeInvalid && utils.isInvalidBrace(parent);
  408        const invalidNode = node.invalid === true && options.escapeInvalid === true;
  409        let output = "";
  410        if (node.value) {
  411          if ((invalidBlock || invalidNode) && utils.isOpenOrClose(node)) {
  412            return "\\" + node.value;
  413          }
  414          return node.value;
  415        }
  416        if (node.value) {
  417          return node.value;
  418        }
  419        if (node.nodes) {
  420          for (const child of node.nodes) {
  421            output += stringify6(child);
  422          }
  423        }
  424        return output;
  425      };
  426      return stringify6(ast);
  427    };
  428  }
  429});
  430
  431// node_modules/is-number/index.js
  432var require_is_number = __commonJS({
  433  "node_modules/is-number/index.js"(exports2, module2) {
  434    "use strict";
  435    module2.exports = function(num) {
  436      if (typeof num === "number") {
  437        return num - num === 0;
  438      }
  439      if (typeof num === "string" && num.trim() !== "") {
  440        return Number.isFinite ? Number.isFinite(+num) : isFinite(+num);
  441      }
  442      return false;
  443    };
  444  }
  445});
  446
  447// node_modules/to-regex-range/index.js
  448var require_to_regex_range = __commonJS({
  449  "node_modules/to-regex-range/index.js"(exports2, module2) {
  450    "use strict";
  451    var isNumber = require_is_number();
  452    var toRegexRange = (min, max, options) => {
  453      if (isNumber(min) === false) {
  454        throw new TypeError("toRegexRange: expected the first argument to be a number");
  455      }
  456      if (max === void 0 || min === max) {
  457        return String(min);
  458      }
  459      if (isNumber(max) === false) {
  460        throw new TypeError("toRegexRange: expected the second argument to be a number.");
  461      }
  462      let opts = __spreadValues({ relaxZeros: true }, options);
  463      if (typeof opts.strictZeros === "boolean") {
  464        opts.relaxZeros = opts.strictZeros === false;
  465      }
  466      let relax = String(opts.relaxZeros);
  467      let shorthand = String(opts.shorthand);
  468      let capture = String(opts.capture);
  469      let wrap2 = String(opts.wrap);
  470      let cacheKey = min + ":" + max + "=" + relax + shorthand + capture + wrap2;
  471      if (toRegexRange.cache.hasOwnProperty(cacheKey)) {
  472        return toRegexRange.cache[cacheKey].result;
  473      }
  474      let a = Math.min(min, max);
  475      let b = Math.max(min, max);
  476      if (Math.abs(a - b) === 1) {
  477        let result = min + "|" + max;
  478        if (opts.capture) {
  479          return `(${result})`;
  480        }
  481        if (opts.wrap === false) {
  482          return result;
  483        }
  484        return `(?:${result})`;
  485      }
  486      let isPadded = hasPadding(min) || hasPadding(max);
  487      let state = { min, max, a, b };
  488      let positives = [];
  489      let negatives = [];
  490      if (isPadded) {
  491        state.isPadded = isPadded;
  492        state.maxLen = String(state.max).length;
  493      }
  494      if (a < 0) {
  495        let newMin = b < 0 ? Math.abs(b) : 1;
  496        negatives = splitToPatterns(newMin, Math.abs(a), state, opts);
  497        a = state.a = 0;
  498      }
  499      if (b >= 0) {
  500        positives = splitToPatterns(a, b, state, opts);
  501      }
  502      state.negatives = negatives;
  503      state.positives = positives;
  504      state.result = collatePatterns(negatives, positives, opts);
  505      if (opts.capture === true) {
  506        state.result = `(${state.result})`;
  507      } else if (opts.wrap !== false && positives.length + negatives.length > 1) {
  508        state.result = `(?:${state.result})`;
  509      }
  510      toRegexRange.cache[cacheKey] = state;
  511      return state.result;
  512    };
  513    function collatePatterns(neg, pos, options) {
  514      let onlyNegative = filterPatterns(neg, pos, "-", false, options) || [];
  515      let onlyPositive = filterPatterns(pos, neg, "", false, options) || [];
  516      let intersected = filterPatterns(neg, pos, "-?", true, options) || [];
  517      let subpatterns = onlyNegative.concat(intersected).concat(onlyPositive);
  518      return subpatterns.join("|");
  519    }
  520    function splitToRanges(min, max) {
  521      let nines = 1;
  522      let zeros = 1;
  523      let stop = countNines(min, nines);
  524      let stops = /* @__PURE__ */ new Set([max]);
  525      while (min <= stop && stop <= max) {
  526        stops.add(stop);
  527        nines += 1;
  528        stop = countNines(min, nines);
  529      }
  530      stop = countZeros(max + 1, zeros) - 1;
  531      while (min < stop && stop <= max) {
  532        stops.add(stop);
  533        zeros += 1;
  534        stop = countZeros(max + 1, zeros) - 1;
  535      }
  536      stops = [...stops];
  537      stops.sort(compare);
  538      return stops;
  539    }
  540    function rangeToPattern(start, stop, options) {
  541      if (start === stop) {
  542        return { pattern: start, count: [], digits: 0 };
  543      }
  544      let zipped = zip(start, stop);
  545      let digits = zipped.length;
  546      let pattern = "";
  547      let count = 0;
  548      for (let i = 0; i < digits; i++) {
  549        let [startDigit, stopDigit] = zipped[i];
  550        if (startDigit === stopDigit) {
  551          pattern += startDigit;
  552        } else if (startDigit !== "0" || stopDigit !== "9") {
  553          pattern += toCharacterClass(startDigit, stopDigit, options);
  554        } else {
  555          count++;
  556        }
  557      }
  558      if (count) {
  559        pattern += options.shorthand === true ? "\\d" : "[0-9]";
  560      }
  561      return { pattern, count: [count], digits };
  562    }
  563    function splitToPatterns(min, max, tok, options) {
  564      let ranges = splitToRanges(min, max);
  565      let tokens = [];
  566      let start = min;
  567      let prev;
  568      for (let i = 0; i < ranges.length; i++) {
  569        let max2 = ranges[i];
  570        let obj = rangeToPattern(String(start), String(max2), options);
  571        let zeros = "";
  572        if (!tok.isPadded && prev && prev.pattern === obj.pattern) {
  573          if (prev.count.length > 1) {
  574            prev.count.pop();
  575          }
  576          prev.count.push(obj.count[0]);
  577          prev.string = prev.pattern + toQuantifier(prev.count);
  578          start = max2 + 1;
  579          continue;
  580        }
  581        if (tok.isPadded) {
  582          zeros = padZeros(max2, tok, options);
  583        }
  584        obj.string = zeros + obj.pattern + toQuantifier(obj.count);
  585        tokens.push(obj);
  586        start = max2 + 1;
  587        prev = obj;
  588      }
  589      return tokens;
  590    }
  591    function filterPatterns(arr, comparison, prefix, intersection, options) {
  592      let result = [];
  593      for (let ele of arr) {
  594        let { string: string2 } = ele;
  595        if (!intersection && !contains(comparison, "string", string2)) {
  596          result.push(prefix + string2);
  597        }
  598        if (intersection && contains(comparison, "string", string2)) {
  599          result.push(prefix + string2);
  600        }
  601      }
  602      return result;
  603    }
  604    function zip(a, b) {
  605      let arr = [];
  606      for (let i = 0; i < a.length; i++) arr.push([a[i], b[i]]);
  607      return arr;
  608    }
  609    function compare(a, b) {
  610      return a > b ? 1 : b > a ? -1 : 0;
  611    }
  612    function contains(arr, key, val) {
  613      return arr.some((ele) => ele[key] === val);
  614    }
  615    function countNines(min, len) {
  616      return Number(String(min).slice(0, -len) + "9".repeat(len));
  617    }
  618    function countZeros(integer, zeros) {
  619      return integer - integer % Math.pow(10, zeros);
  620    }
  621    function toQuantifier(digits) {
  622      let [start = 0, stop = ""] = digits;
  623      if (stop || start > 1) {
  624        return `{${start + (stop ? "," + stop : "")}}`;
  625      }
  626      return "";
  627    }
  628    function toCharacterClass(a, b, options) {
  629      return `[${a}${b - a === 1 ? "" : "-"}${b}]`;
  630    }
  631    function hasPadding(str) {
  632      return /^-?(0+)\d/.test(str);
  633    }
  634    function padZeros(value, tok, options) {
  635      if (!tok.isPadded) {
  636        return value;
  637      }
  638      let diff = Math.abs(tok.maxLen - String(value).length);
  639      let relax = options.relaxZeros !== false;
  640      switch (diff) {
  641        case 0:
  642          return "";
  643        case 1:
  644          return relax ? "0?" : "0";
  645        case 2:
  646          return relax ? "0{0,2}" : "00";
  647        default: {
  648          return relax ? `0{0,${diff}}` : `0{${diff}}`;
  649        }
  650      }
  651    }
  652    toRegexRange.cache = {};
  653    toRegexRange.clearCache = () => toRegexRange.cache = {};
  654    module2.exports = toRegexRange;
  655  }
  656});
  657
  658// node_modules/fill-range/index.js
  659var require_fill_range = __commonJS({
  660  "node_modules/fill-range/index.js"(exports2, module2) {
  661    "use strict";
  662    var util = require("util");
  663    var toRegexRange = require_to_regex_range();
  664    var isObject = (val) => val !== null && typeof val === "object" && !Array.isArray(val);
  665    var transform = (toNumber) => {
  666      return (value) => toNumber === true ? Number(value) : String(value);
  667    };
  668    var isValidValue = (value) => {
  669      return typeof value === "number" || typeof value === "string" && value !== "";
  670    };
  671    var isNumber = (num) => Number.isInteger(+num);
  672    var zeros = (input) => {
  673      let value = `${input}`;
  674      let index = -1;
  675      if (value[0] === "-") value = value.slice(1);
  676      if (value === "0") return false;
  677      while (value[++index] === "0") ;
  678      return index > 0;
  679    };
  680    var stringify6 = (start, end, options) => {
  681      if (typeof start === "string" || typeof end === "string") {
  682        return true;
  683      }
  684      return options.stringify === true;
  685    };
  686    var pad = (input, maxLength, toNumber) => {
  687      if (maxLength > 0) {
  688        let dash = input[0] === "-" ? "-" : "";
  689        if (dash) input = input.slice(1);
  690        input = dash + input.padStart(dash ? maxLength - 1 : maxLength, "0");
  691      }
  692      if (toNumber === false) {
  693        return String(input);
  694      }
  695      return input;
  696    };
  697    var toMaxLen = (input, maxLength) => {
  698      let negative = input[0] === "-" ? "-" : "";
  699      if (negative) {
  700        input = input.slice(1);
  701        maxLength--;
  702      }
  703      while (input.length < maxLength) input = "0" + input;
  704      return negative ? "-" + input : input;
  705    };
  706    var toSequence = (parts, options, maxLen) => {
  707      parts.negatives.sort((a, b) => a < b ? -1 : a > b ? 1 : 0);
  708      parts.positives.sort((a, b) => a < b ? -1 : a > b ? 1 : 0);
  709      let prefix = options.capture ? "" : "?:";
  710      let positives = "";
  711      let negatives = "";
  712      let result;
  713      if (parts.positives.length) {
  714        positives = parts.positives.map((v2) => toMaxLen(String(v2), maxLen)).join("|");
  715      }
  716      if (parts.negatives.length) {
  717        negatives = `-(${prefix}${parts.negatives.map((v2) => toMaxLen(String(v2), maxLen)).join("|")})`;
  718      }
  719      if (positives && negatives) {
  720        result = `${positives}|${negatives}`;
  721      } else {
  722        result = positives || negatives;
  723      }
  724      if (options.wrap) {
  725        return `(${prefix}${result})`;
  726      }
  727      return result;
  728    };
  729    var toRange = (a, b, isNumbers, options) => {
  730      if (isNumbers) {
  731        return toRegexRange(a, b, __spreadValues({ wrap: false }, options));
  732      }
  733      let start = String.fromCharCode(a);
  734      if (a === b) return start;
  735      let stop = String.fromCharCode(b);
  736      return `[${start}-${stop}]`;
  737    };
  738    var toRegex = (start, end, options) => {
  739      if (Array.isArray(start)) {
  740        let wrap2 = options.wrap === true;
  741        let prefix = options.capture ? "" : "?:";
  742        return wrap2 ? `(${prefix}${start.join("|")})` : start.join("|");
  743      }
  744      return toRegexRange(start, end, options);
  745    };
  746    var rangeError = (...args) => {
  747      return new RangeError("Invalid range arguments: " + util.inspect(...args));
  748    };
  749    var invalidRange = (start, end, options) => {
  750      if (options.strictRanges === true) throw rangeError([start, end]);
  751      return [];
  752    };
  753    var invalidStep = (step, options) => {
  754      if (options.strictRanges === true) {
  755        throw new TypeError(`Expected step "${step}" to be a number`);
  756      }
  757      return [];
  758    };
  759    var fillNumbers = (start, end, step = 1, options = {}) => {
  760      let a = Number(start);
  761      let b = Number(end);
  762      if (!Number.isInteger(a) || !Number.isInteger(b)) {
  763        if (options.strictRanges === true) throw rangeError([start, end]);
  764        return [];
  765      }
  766      if (a === 0) a = 0;
  767      if (b === 0) b = 0;
  768      let descending = a > b;
  769      let startString = String(start);
  770      let endString = String(end);
  771      let stepString = String(step);
  772      step = Math.max(Math.abs(step), 1);
  773      let padded = zeros(startString) || zeros(endString) || zeros(stepString);
  774      let maxLen = padded ? Math.max(startString.length, endString.length, stepString.length) : 0;
  775      let toNumber = padded === false && stringify6(start, end, options) === false;
  776      let format = options.transform || transform(toNumber);
  777      if (options.toRegex && step === 1) {
  778        return toRange(toMaxLen(start, maxLen), toMaxLen(end, maxLen), true, options);
  779      }
  780      let parts = { negatives: [], positives: [] };
  781      let push = (num) => parts[num < 0 ? "negatives" : "positives"].push(Math.abs(num));
  782      let range = [];
  783      let index = 0;
  784      while (descending ? a >= b : a <= b) {
  785        if (options.toRegex === true && step > 1) {
  786          push(a);
  787        } else {
  788          range.push(pad(format(a, index), maxLen, toNumber));
  789        }
  790        a = descending ? a - step : a + step;
  791        index++;
  792      }
  793      if (options.toRegex === true) {
  794        return step > 1 ? toSequence(parts, options, maxLen) : toRegex(range, null, __spreadValues({ wrap: false }, options));
  795      }
  796      return range;
  797    };
  798    var fillLetters = (start, end, step = 1, options = {}) => {
  799      if (!isNumber(start) && start.length > 1 || !isNumber(end) && end.length > 1) {
  800        return invalidRange(start, end, options);
  801      }
  802      let format = options.transform || ((val) => String.fromCharCode(val));
  803      let a = `${start}`.charCodeAt(0);
  804      let b = `${end}`.charCodeAt(0);
  805      let descending = a > b;
  806      let min = Math.min(a, b);
  807      let max = Math.max(a, b);
  808      if (options.toRegex && step === 1) {
  809        return toRange(min, max, false, options);
  810      }
  811      let range = [];
  812      let index = 0;
  813      while (descending ? a >= b : a <= b) {
  814        range.push(format(a, index));
  815        a = descending ? a - step : a + step;
  816        index++;
  817      }
  818      if (options.toRegex === true) {
  819        return toRegex(range, null, { wrap: false, options });
  820      }
  821      return range;
  822    };
  823    var fill = (start, end, step, options = {}) => {
  824      if (end == null && isValidValue(start)) {
  825        return [start];
  826      }
  827      if (!isValidValue(start) || !isValidValue(end)) {
  828        return invalidRange(start, end, options);
  829      }
  830      if (typeof step === "function") {
  831        return fill(start, end, 1, { transform: step });
  832      }
  833      if (isObject(step)) {
  834        return fill(start, end, 0, step);
  835      }
  836      let opts = __spreadValues({}, options);
  837      if (opts.capture === true) opts.wrap = true;
  838      step = step || opts.step || 1;
  839      if (!isNumber(step)) {
  840        if (step != null && !isObject(step)) return invalidStep(step, opts);
  841        return fill(start, end, 1, step);
  842      }
  843      if (isNumber(start) && isNumber(end)) {
  844        return fillNumbers(start, end, step, opts);
  845      }
  846      return fillLetters(start, end, Math.max(Math.abs(step), 1), opts);
  847    };
  848    module2.exports = fill;
  849  }
  850});
  851
  852// node_modules/braces/lib/compile.js
  853var require_compile = __commonJS({
  854  "node_modules/braces/lib/compile.js"(exports2, module2) {
  855    "use strict";
  856    var fill = require_fill_range();
  857    var utils = require_utils();
  858    var compile = (ast, options = {}) => {
  859      const walk = (node, parent = {}) => {
  860        const invalidBlock = utils.isInvalidBrace(parent);
  861        const invalidNode = node.invalid === true && options.escapeInvalid === true;
  862        const invalid = invalidBlock === true || invalidNode === true;
  863        const prefix = options.escapeInvalid === true ? "\\" : "";
  864        let output = "";
  865        if (node.isOpen === true) {
  866          return prefix + node.value;
  867        }
  868        if (node.isClose === true) {
  869          console.log("node.isClose", prefix, node.value);
  870          return prefix + node.value;
  871        }
  872        if (node.type === "open") {
  873          return invalid ? prefix + node.value : "(";
  874        }
  875        if (node.type === "close") {
  876          return invalid ? prefix + node.value : ")";
  877        }
  878        if (node.type === "comma") {
  879          return node.prev.type === "comma" ? "" : invalid ? node.value : "|";
  880        }
  881        if (node.value) {
  882          return node.value;
  883        }
  884        if (node.nodes && node.ranges > 0) {
  885          const args = utils.reduce(node.nodes);
  886          const range = fill(...args, __spreadProps(__spreadValues({}, options), { wrap: false, toRegex: true, strictZeros: true }));
  887          if (range.length !== 0) {
  888            return args.length > 1 && range.length > 1 ? `(${range})` : range;
  889          }
  890        }
  891        if (node.nodes) {
  892          for (const child of node.nodes) {
  893            output += walk(child, node);
  894          }
  895        }
  896        return output;
  897      };
  898      return walk(ast);
  899    };
  900    module2.exports = compile;
  901  }
  902});
  903
  904// node_modules/braces/lib/expand.js
  905var require_expand = __commonJS({
  906  "node_modules/braces/lib/expand.js"(exports2, module2) {
  907    "use strict";
  908    var fill = require_fill_range();
  909    var stringify6 = require_stringify();
  910    var utils = require_utils();
  911    var append = (queue = "", stash = "", enclose = false) => {
  912      const result = [];
  913      queue = [].concat(queue);
  914      stash = [].concat(stash);
  915      if (!stash.length) return queue;
  916      if (!queue.length) {
  917        return enclose ? utils.flatten(stash).map((ele) => `{${ele}}`) : stash;
  918      }
  919      for (const item of queue) {
  920        if (Array.isArray(item)) {
  921          for (const value of item) {
  922            result.push(append(value, stash, enclose));
  923          }
  924        } else {
  925          for (let ele of stash) {
  926            if (enclose === true && typeof ele === "string") ele = `{${ele}}`;
  927            result.push(Array.isArray(ele) ? append(item, ele, enclose) : item + ele);
  928          }
  929        }
  930      }
  931      return utils.flatten(result);
  932    };
  933    var expand = (ast, options = {}) => {
  934      const rangeLimit = options.rangeLimit === void 0 ? 1e3 : options.rangeLimit;
  935      const walk = (node, parent = {}) => {
  936        node.queue = [];
  937        let p2 = parent;
  938        let q = parent.queue;
  939        while (p2.type !== "brace" && p2.type !== "root" && p2.parent) {
  940          p2 = p2.parent;
  941          q = p2.queue;
  942        }
  943        if (node.invalid || node.dollar) {
  944          q.push(append(q.pop(), stringify6(node, options)));
  945          return;
  946        }
  947        if (node.type === "brace" && node.invalid !== true && node.nodes.length === 2) {
  948          q.push(append(q.pop(), ["{}"]));
  949          return;
  950        }
  951        if (node.nodes && node.ranges > 0) {
  952          const args = utils.reduce(node.nodes);
  953          if (utils.exceedsLimit(...args, options.step, rangeLimit)) {
  954            throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");
  955          }
  956          let range = fill(...args, options);
  957          if (range.length === 0) {
  958            range = stringify6(node, options);
  959          }
  960          q.push(append(q.pop(), range));
  961          node.nodes = [];
  962          return;
  963        }
  964        const enclose = utils.encloseBrace(node);
  965        let queue = node.queue;
  966        let block = node;
  967        while (block.type !== "brace" && block.type !== "root" && block.parent) {
  968          block = block.parent;
  969          queue = block.queue;
  970        }
  971        for (let i = 0; i < node.nodes.length; i++) {
  972          const child = node.nodes[i];
  973          if (child.type === "comma" && node.type === "brace") {
  974            if (i === 1) queue.push("");
  975            queue.push("");
  976            continue;
  977          }
  978          if (child.type === "close") {
  979            q.push(append(q.pop(), queue, enclose));
  980            continue;
  981          }
  982          if (child.value && child.type !== "open") {
  983            queue.push(append(queue.pop(), child.value));
  984            continue;
  985          }
  986          if (child.nodes) {
  987            walk(child, node);
  988          }
  989        }
  990        return queue;
  991      };
  992      return utils.flatten(walk(ast));
  993    };
  994    module2.exports = expand;
  995  }
  996});
  997
  998// node_modules/braces/lib/constants.js
  999var require_constants = __commonJS({
 1000  "node_modules/braces/lib/constants.js"(exports2, module2) {
 1001    "use strict";
 1002    module2.exports = {
 1003      MAX_LENGTH: 1e4,
 1004      // Digits
 1005      CHAR_0: "0",
 1006      /* 0 */
 1007      CHAR_9: "9",
 1008      /* 9 */
 1009      // Alphabet chars.
 1010      CHAR_UPPERCASE_A: "A",
 1011      /* A */
 1012      CHAR_LOWERCASE_A: "a",
 1013      /* a */
 1014      CHAR_UPPERCASE_Z: "Z",
 1015      /* Z */
 1016      CHAR_LOWERCASE_Z: "z",
 1017      /* z */
 1018      CHAR_LEFT_PARENTHESES: "(",
 1019      /* ( */
 1020      CHAR_RIGHT_PARENTHESES: ")",
 1021      /* ) */
 1022      CHAR_ASTERISK: "*",
 1023      /* * */
 1024      // Non-alphabetic chars.
 1025      CHAR_AMPERSAND: "&",
 1026      /* & */
 1027      CHAR_AT: "@",
 1028      /* @ */
 1029      CHAR_BACKSLASH: "\\",
 1030      /* \ */
 1031      CHAR_BACKTICK: "`",
 1032      /* ` */
 1033      CHAR_CARRIAGE_RETURN: "\r",
 1034      /* \r */
 1035      CHAR_CIRCUMFLEX_ACCENT: "^",
 1036      /* ^ */
 1037      CHAR_COLON: ":",
 1038      /* : */
 1039      CHAR_COMMA: ",",
 1040      /* , */
 1041      CHAR_DOLLAR: "$",
 1042      /* . */
 1043      CHAR_DOT: ".",
 1044      /* . */
 1045      CHAR_DOUBLE_QUOTE: '"',
 1046      /* " */
 1047      CHAR_EQUAL: "=",
 1048      /* = */
 1049      CHAR_EXCLAMATION_MARK: "!",
 1050      /* ! */
 1051      CHAR_FORM_FEED: "\f",
 1052      /* \f */
 1053      CHAR_FORWARD_SLASH: "/",
 1054      /* / */
 1055      CHAR_HASH: "#",
 1056      /* # */
 1057      CHAR_HYPHEN_MINUS: "-",
 1058      /* - */
 1059      CHAR_LEFT_ANGLE_BRACKET: "<",
 1060      /* < */
 1061      CHAR_LEFT_CURLY_BRACE: "{",
 1062      /* { */
 1063      CHAR_LEFT_SQUARE_BRACKET: "[",
 1064      /* [ */
 1065      CHAR_LINE_FEED: "\n",
 1066      /* \n */
 1067      CHAR_NO_BREAK_SPACE: "\xA0",
 1068      /* \u00A0 */
 1069      CHAR_PERCENT: "%",
 1070      /* % */
 1071      CHAR_PLUS: "+",
 1072      /* + */
 1073      CHAR_QUESTION_MARK: "?",
 1074      /* ? */
 1075      CHAR_RIGHT_ANGLE_BRACKET: ">",
 1076      /* > */
 1077      CHAR_RIGHT_CURLY_BRACE: "}",
 1078      /* } */
 1079      CHAR_RIGHT_SQUARE_BRACKET: "]",
 1080      /* ] */
 1081      CHAR_SEMICOLON: ";",
 1082      /* ; */
 1083      CHAR_SINGLE_QUOTE: "'",
 1084      /* ' */
 1085      CHAR_SPACE: " ",
 1086      /*   */
 1087      CHAR_TAB: "	",
 1088      /* \t */
 1089      CHAR_UNDERSCORE: "_",
 1090      /* _ */
 1091      CHAR_VERTICAL_LINE: "|",
 1092      /* | */
 1093      CHAR_ZERO_WIDTH_NOBREAK_SPACE: "\uFEFF"
 1094      /* \uFEFF */
 1095    };
 1096  }
 1097});
 1098
 1099// node_modules/braces/lib/parse.js
 1100var require_parse = __commonJS({
 1101  "node_modules/braces/lib/parse.js"(exports2, module2) {
 1102    "use strict";
 1103    var stringify6 = require_stringify();
 1104    var {
 1105      MAX_LENGTH,
 1106      CHAR_BACKSLASH,
 1107      /* \ */
 1108      CHAR_BACKTICK,
 1109      /* ` */
 1110      CHAR_COMMA,
 1111      /* , */
 1112      CHAR_DOT,
 1113      /* . */
 1114      CHAR_LEFT_PARENTHESES,
 1115      /* ( */
 1116      CHAR_RIGHT_PARENTHESES,
 1117      /* ) */
 1118      CHAR_LEFT_CURLY_BRACE,
 1119      /* { */
 1120      CHAR_RIGHT_CURLY_BRACE,
 1121      /* } */
 1122      CHAR_LEFT_SQUARE_BRACKET,
 1123      /* [ */
 1124      CHAR_RIGHT_SQUARE_BRACKET,
 1125      /* ] */
 1126      CHAR_DOUBLE_QUOTE,
 1127      /* " */
 1128      CHAR_SINGLE_QUOTE,
 1129      /* ' */
 1130      CHAR_NO_BREAK_SPACE,
 1131      CHAR_ZERO_WIDTH_NOBREAK_SPACE
 1132    } = require_constants();
 1133    var parse4 = (input, options = {}) => {
 1134      if (typeof input !== "string") {
 1135        throw new TypeError("Expected a string");
 1136      }
 1137      const opts = options || {};
 1138      const max = typeof opts.maxLength === "number" ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH;
 1139      if (input.length > max) {
 1140        throw new SyntaxError(`Input length (${input.length}), exceeds max characters (${max})`);
 1141      }
 1142      const ast = { type: "root", input, nodes: [] };
 1143      const stack = [ast];
 1144      let block = ast;
 1145      let prev = ast;
 1146      let brackets = 0;
 1147      const length = input.length;
 1148      let index = 0;
 1149      let depth = 0;
 1150      let value;
 1151      const advance = () => input[index++];
 1152      const push = (node) => {
 1153        if (node.type === "text" && prev.type === "dot") {
 1154          prev.type = "text";
 1155        }
 1156        if (prev && prev.type === "text" && node.type === "text") {
 1157          prev.value += node.value;
 1158          return;
 1159        }
 1160        block.nodes.push(node);
 1161        node.parent = block;
 1162        node.prev = prev;
 1163        prev = node;
 1164        return node;
 1165      };
 1166      push({ type: "bos" });
 1167      while (index < length) {
 1168        block = stack[stack.length - 1];
 1169        value = advance();
 1170        if (value === CHAR_ZERO_WIDTH_NOBREAK_SPACE || value === CHAR_NO_BREAK_SPACE) {
 1171          continue;
 1172        }
 1173        if (value === CHAR_BACKSLASH) {
 1174          push({ type: "text", value: (options.keepEscaping ? value : "") + advance() });
 1175          continue;
 1176        }
 1177        if (value === CHAR_RIGHT_SQUARE_BRACKET) {
 1178          push({ type: "text", value: "\\" + value });
 1179          continue;
 1180        }
 1181        if (value === CHAR_LEFT_SQUARE_BRACKET) {
 1182          brackets++;
 1183          let next;
 1184          while (index < length && (next = advance())) {
 1185            value += next;
 1186            if (next === CHAR_LEFT_SQUARE_BRACKET) {
 1187              brackets++;
 1188              continue;
 1189            }
 1190            if (next === CHAR_BACKSLASH) {
 1191              value += advance();
 1192              continue;
 1193            }
 1194            if (next === CHAR_RIGHT_SQUARE_BRACKET) {
 1195              brackets--;
 1196              if (brackets === 0) {
 1197                break;
 1198              }
 1199            }
 1200          }
 1201          push({ type: "text", value });
 1202          continue;
 1203        }
 1204        if (value === CHAR_LEFT_PARENTHESES) {
 1205          block = push({ type: "paren", nodes: [] });
 1206          stack.push(block);
 1207          push({ type: "text", value });
 1208          continue;
 1209        }
 1210        if (value === CHAR_RIGHT_PARENTHESES) {
 1211          if (block.type !== "paren") {
 1212            push({ type: "text", value });
 1213            continue;
 1214          }
 1215          block = stack.pop();
 1216          push({ type: "text", value });
 1217          block = stack[stack.length - 1];
 1218          continue;
 1219        }
 1220        if (value === CHAR_DOUBLE_QUOTE || value === CHAR_SINGLE_QUOTE || value === CHAR_BACKTICK) {
 1221          const open = value;
 1222          let next;
 1223          if (options.keepQuotes !== true) {
 1224            value = "";
 1225          }
 1226          while (index < length && (next = advance())) {
 1227            if (next === CHAR_BACKSLASH) {
 1228              value += next + advance();
 1229              continue;
 1230            }
 1231            if (next === open) {
 1232              if (options.keepQuotes === true) value += next;
 1233              break;
 1234            }
 1235            value += next;
 1236          }
 1237          push({ type: "text", value });
 1238          continue;
 1239        }
 1240        if (value === CHAR_LEFT_CURLY_BRACE) {
 1241          depth++;
 1242          const dollar = prev.value && prev.value.slice(-1) === "$" || block.dollar === true;
 1243          const brace = {
 1244            type: "brace",
 1245            open: true,
 1246            close: false,
 1247            dollar,
 1248            depth,
 1249            commas: 0,
 1250            ranges: 0,
 1251            nodes: []
 1252          };
 1253          block = push(brace);
 1254          stack.push(block);
 1255          push({ type: "open", value });
 1256          continue;
 1257        }
 1258        if (value === CHAR_RIGHT_CURLY_BRACE) {
 1259          if (block.type !== "brace") {
 1260            push({ type: "text", value });
 1261            continue;
 1262          }
 1263          const type = "close";
 1264          block = stack.pop();
 1265          block.close = true;
 1266          push({ type, value });
 1267          depth--;
 1268          block = stack[stack.length - 1];
 1269          continue;
 1270        }
 1271        if (value === CHAR_COMMA && depth > 0) {
 1272          if (block.ranges > 0) {
 1273            block.ranges = 0;
 1274            const open = block.nodes.shift();
 1275            block.nodes = [open, { type: "text", value: stringify6(block) }];
 1276          }
 1277          push({ type: "comma", value });
 1278          block.commas++;
 1279          continue;
 1280        }
 1281        if (value === CHAR_DOT && depth > 0 && block.commas === 0) {
 1282          const siblings = block.nodes;
 1283          if (depth === 0 || siblings.length === 0) {
 1284            push({ type: "text", value });
 1285            continue;
 1286          }
 1287          if (prev.type === "dot") {
 1288            block.range = [];
 1289            prev.value += value;
 1290            prev.type = "range";
 1291            if (block.nodes.length !== 3 && block.nodes.length !== 5) {
 1292              block.invalid = true;
 1293              block.ranges = 0;
 1294              prev.type = "text";
 1295              continue;
 1296            }
 1297            block.ranges++;
 1298            block.args = [];
 1299            continue;
 1300          }
 1301          if (prev.type === "range") {
 1302            siblings.pop();
 1303            const before = siblings[siblings.length - 1];
 1304            before.value += prev.value + value;
 1305            prev = before;
 1306            block.ranges--;
 1307            continue;
 1308          }
 1309          push({ type: "dot", value });
 1310          continue;
 1311        }
 1312        push({ type: "text", value });
 1313      }
 1314      do {
 1315        block = stack.pop();
 1316        if (block.type !== "root") {
 1317          block.nodes.forEach((node) => {
 1318            if (!node.nodes) {
 1319              if (node.type === "open") node.isOpen = true;
 1320              if (node.type === "close") node.isClose = true;
 1321              if (!node.nodes) node.type = "text";
 1322              node.invalid = true;
 1323            }
 1324          });
 1325          const parent = stack[stack.length - 1];
 1326          const index2 = parent.nodes.indexOf(block);
 1327          parent.nodes.splice(index2, 1, ...block.nodes);
 1328        }
 1329      } while (stack.length > 0);
 1330      push({ type: "eos" });
 1331      return ast;
 1332    };
 1333    module2.exports = parse4;
 1334  }
 1335});
 1336
 1337// node_modules/braces/index.js
 1338var require_braces = __commonJS({
 1339  "node_modules/braces/index.js"(exports2, module2) {
 1340    "use strict";
 1341    var stringify6 = require_stringify();
 1342    var compile = require_compile();
 1343    var expand = require_expand();
 1344    var parse4 = require_parse();
 1345    var braces = (input, options = {}) => {
 1346      let output = [];
 1347      if (Array.isArray(input)) {
 1348        for (const pattern of input) {
 1349          const result = braces.create(pattern, options);
 1350          if (Array.isArray(result)) {
 1351            output.push(...result);
 1352          } else {
 1353            output.push(result);
 1354          }
 1355        }
 1356      } else {
 1357        output = [].concat(braces.create(input, options));
 1358      }
 1359      if (options && options.expand === true && options.nodupes === true) {
 1360        output = [...new Set(output)];
 1361      }
 1362      return output;
 1363    };
 1364    braces.parse = (input, options = {}) => parse4(input, options);
 1365    braces.stringify = (input, options = {}) => {
 1366      if (typeof input === "string") {
 1367        return stringify6(braces.parse(input, options), options);
 1368      }
 1369      return stringify6(input, options);
 1370    };
 1371    braces.compile = (input, options = {}) => {
 1372      if (typeof input === "string") {
 1373        input = braces.parse(input, options);
 1374      }
 1375      return compile(input, options);
 1376    };
 1377    braces.expand = (input, options = {}) => {
 1378      if (typeof input === "string") {
 1379        input = braces.parse(input, options);
 1380      }
 1381      let result = expand(input, options);
 1382      if (options.noempty === true) {
 1383        result = result.filter(Boolean);
 1384      }
 1385      if (options.nodupes === true) {
 1386        result = [...new Set(result)];
 1387      }
 1388      return result;
 1389    };
 1390    braces.create = (input, options = {}) => {
 1391      if (input === "" || input.length < 3) {
 1392        return [input];
 1393      }
 1394      return options.expand !== true ? braces.compile(input, options) : braces.expand(input, options);
 1395    };
 1396    module2.exports = braces;
 1397  }
 1398});
 1399
 1400// node_modules/picomatch/lib/constants.js
 1401var require_constants2 = __commonJS({
 1402  "node_modules/picomatch/lib/constants.js"(exports2, module2) {
 1403    "use strict";
 1404    var path5 = require("path");
 1405    var WIN_SLASH = "\\\\/";
 1406    var WIN_NO_SLASH = `[^${WIN_SLASH}]`;
 1407    var DOT_LITERAL = "\\.";
 1408    var PLUS_LITERAL = "\\+";
 1409    var QMARK_LITERAL = "\\?";
 1410    var SLASH_LITERAL = "\\/";
 1411    var ONE_CHAR = "(?=.)";
 1412    var QMARK = "[^/]";
 1413    var END_ANCHOR = `(?:${SLASH_LITERAL}|$)`;
 1414    var START_ANCHOR = `(?:^|${SLASH_LITERAL})`;
 1415    var DOTS_SLASH = `${DOT_LITERAL}{1,2}${END_ANCHOR}`;
 1416    var NO_DOT = `(?!${DOT_LITERAL})`;
 1417    var NO_DOTS = `(?!${START_ANCHOR}${DOTS_SLASH})`;
 1418    var NO_DOT_SLASH = `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`;
 1419    var NO_DOTS_SLASH = `(?!${DOTS_SLASH})`;
 1420    var QMARK_NO_DOT = `[^.${SLASH_LITERAL}]`;
 1421    var STAR = `${QMARK}*?`;
 1422    var POSIX_CHARS = {
 1423      DOT_LITERAL,
 1424      PLUS_LITERAL,
 1425      QMARK_LITERAL,
 1426      SLASH_LITERAL,
 1427      ONE_CHAR,
 1428      QMARK,
 1429      END_ANCHOR,
 1430      DOTS_SLASH,
 1431      NO_DOT,
 1432      NO_DOTS,
 1433      NO_DOT_SLASH,
 1434      NO_DOTS_SLASH,
 1435      QMARK_NO_DOT,
 1436      STAR,
 1437      START_ANCHOR
 1438    };
 1439    var WINDOWS_CHARS = __spreadProps(__spreadValues({}, POSIX_CHARS), {
 1440      SLASH_LITERAL: `[${WIN_SLASH}]`,
 1441      QMARK: WIN_NO_SLASH,
 1442      STAR: `${WIN_NO_SLASH}*?`,
 1443      DOTS_SLASH: `${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$)`,
 1444      NO_DOT: `(?!${DOT_LITERAL})`,
 1445      NO_DOTS: `(?!(?:^|[${WIN_SLASH}])${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`,
 1446      NO_DOT_SLASH: `(?!${DOT_LITERAL}{0,1}(?:[${WIN_SLASH}]|$))`,
 1447      NO_DOTS_SLASH: `(?!${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`,
 1448      QMARK_NO_DOT: `[^.${WIN_SLASH}]`,
 1449      START_ANCHOR: `(?:^|[${WIN_SLASH}])`,
 1450      END_ANCHOR: `(?:[${WIN_SLASH}]|$)`
 1451    });
 1452    var POSIX_REGEX_SOURCE = {
 1453      alnum: "a-zA-Z0-9",
 1454      alpha: "a-zA-Z",
 1455      ascii: "\\x00-\\x7F",
 1456      blank: " \\t",
 1457      cntrl: "\\x00-\\x1F\\x7F",
 1458      digit: "0-9",
 1459      graph: "\\x21-\\x7E",
 1460      lower: "a-z",
 1461      print: "\\x20-\\x7E ",
 1462      punct: "\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",
 1463      space: " \\t\\r\\n\\v\\f",
 1464      upper: "A-Z",
 1465      word: "A-Za-z0-9_",
 1466      xdigit: "A-Fa-f0-9"
 1467    };
 1468    module2.exports = {
 1469      MAX_LENGTH: 1024 * 64,
 1470      POSIX_REGEX_SOURCE,
 1471      // regular expressions
 1472      REGEX_BACKSLASH: /\\(?![*+?^${}(|)[\]])/g,
 1473      REGEX_NON_SPECIAL_CHARS: /^[^@![\].,$*+?^{}()|\\/]+/,
 1474      REGEX_SPECIAL_CHARS: /[-*+?.^${}(|)[\]]/,
 1475      REGEX_SPECIAL_CHARS_BACKREF: /(\\?)((\W)(\3*))/g,
 1476      REGEX_SPECIAL_CHARS_GLOBAL: /([-*+?.^${}(|)[\]])/g,
 1477      REGEX_REMOVE_BACKSLASH: /(?:\[.*?[^\\]\]|\\(?=.))/g,
 1478      // Replace globs with equivalent patterns to reduce parsing time.
 1479      REPLACEMENTS: {
 1480        "***": "*",
 1481        "**/**": "**",
 1482        "**/**/**": "**"
 1483      },
 1484      // Digits
 1485      CHAR_0: 48,
 1486      /* 0 */
 1487      CHAR_9: 57,
 1488      /* 9 */
 1489      // Alphabet chars.
 1490      CHAR_UPPERCASE_A: 65,
 1491      /* A */
 1492      CHAR_LOWERCASE_A: 97,
 1493      /* a */
 1494      CHAR_UPPERCASE_Z: 90,
 1495      /* Z */
 1496      CHAR_LOWERCASE_Z: 122,
 1497      /* z */
 1498      CHAR_LEFT_PARENTHESES: 40,
 1499      /* ( */
 1500      CHAR_RIGHT_PARENTHESES: 41,
 1501      /* ) */
 1502      CHAR_ASTERISK: 42,
 1503      /* * */
 1504      // Non-alphabetic chars.
 1505      CHAR_AMPERSAND: 38,
 1506      /* & */
 1507      CHAR_AT: 64,
 1508      /* @ */
 1509      CHAR_BACKWARD_SLASH: 92,
 1510      /* \ */
 1511      CHAR_CARRIAGE_RETURN: 13,
 1512      /* \r */
 1513      CHAR_CIRCUMFLEX_ACCENT: 94,
 1514      /* ^ */
 1515      CHAR_COLON: 58,
 1516      /* : */
 1517      CHAR_COMMA: 44,
 1518      /* , */
 1519      CHAR_DOT: 46,
 1520      /* . */
 1521      CHAR_DOUBLE_QUOTE: 34,
 1522      /* " */
 1523      CHAR_EQUAL: 61,
 1524      /* = */
 1525      CHAR_EXCLAMATION_MARK: 33,
 1526      /* ! */
 1527      CHAR_FORM_FEED: 12,
 1528      /* \f */
 1529      CHAR_FORWARD_SLASH: 47,
 1530      /* / */
 1531      CHAR_GRAVE_ACCENT: 96,
 1532      /* ` */
 1533      CHAR_HASH: 35,
 1534      /* # */
 1535      CHAR_HYPHEN_MINUS: 45,
 1536      /* - */
 1537      CHAR_LEFT_ANGLE_BRACKET: 60,
 1538      /* < */
 1539      CHAR_LEFT_CURLY_BRACE: 123,
 1540      /* { */
 1541      CHAR_LEFT_SQUARE_BRACKET: 91,
 1542      /* [ */
 1543      CHAR_LINE_FEED: 10,
 1544      /* \n */
 1545      CHAR_NO_BREAK_SPACE: 160,
 1546      /* \u00A0 */
 1547      CHAR_PERCENT: 37,
 1548      /* % */
 1549      CHAR_PLUS: 43,
 1550      /* + */
 1551      CHAR_QUESTION_MARK: 63,
 1552      /* ? */
 1553      CHAR_RIGHT_ANGLE_BRACKET: 62,
 1554      /* > */
 1555      CHAR_RIGHT_CURLY_BRACE: 125,
 1556      /* } */
 1557      CHAR_RIGHT_SQUARE_BRACKET: 93,
 1558      /* ] */
 1559      CHAR_SEMICOLON: 59,
 1560      /* ; */
 1561      CHAR_SINGLE_QUOTE: 39,
 1562      /* ' */
 1563      CHAR_SPACE: 32,
 1564      /*   */
 1565      CHAR_TAB: 9,
 1566      /* \t */
 1567      CHAR_UNDERSCORE: 95,
 1568      /* _ */
 1569      CHAR_VERTICAL_LINE: 124,
 1570      /* | */
 1571      CHAR_ZERO_WIDTH_NOBREAK_SPACE: 65279,
 1572      /* \uFEFF */
 1573      SEP: path5.sep,
 1574      /**
 1575       * Create EXTGLOB_CHARS
 1576       */
 1577      extglobChars(chars) {
 1578        return {
 1579          "!": { type: "negate", open: "(?:(?!(?:", close: `))${chars.STAR})` },
 1580          "?": { type: "qmark", open: "(?:", close: ")?" },
 1581          "+": { type: "plus", open: "(?:", close: ")+" },
 1582          "*": { type: "star", open: "(?:", close: ")*" },
 1583          "@": { type: "at", open: "(?:", close: ")" }
 1584        };
 1585      },
 1586      /**
 1587       * Create GLOB_CHARS
 1588       */
 1589      globChars(win32) {
 1590        return win32 === true ? WINDOWS_CHARS : POSIX_CHARS;
 1591      }
 1592    };
 1593  }
 1594});
 1595
 1596// node_modules/picomatch/lib/utils.js
 1597var require_utils2 = __commonJS({
 1598  "node_modules/picomatch/lib/utils.js"(exports2) {
 1599    "use strict";
 1600    var path5 = require("path");
 1601    var win32 = process.platform === "win32";
 1602    var {
 1603      REGEX_BACKSLASH,
 1604      REGEX_REMOVE_BACKSLASH,
 1605      REGEX_SPECIAL_CHARS,
 1606      REGEX_SPECIAL_CHARS_GLOBAL
 1607    } = require_constants2();
 1608    exports2.isObject = (val) => val !== null && typeof val === "object" && !Array.isArray(val);
 1609    exports2.hasRegexChars = (str) => REGEX_SPECIAL_CHARS.test(str);
 1610    exports2.isRegexChar = (str) => str.length === 1 && exports2.hasRegexChars(str);
 1611    exports2.escapeRegex = (str) => str.replace(REGEX_SPECIAL_CHARS_GLOBAL, "\\$1");
 1612    exports2.toPosixSlashes = (str) => str.replace(REGEX_BACKSLASH, "/");
 1613    exports2.removeBackslashes = (str) => {
 1614      return str.replace(REGEX_REMOVE_BACKSLASH, (match) => {
 1615        return match === "\\" ? "" : match;
 1616      });
 1617    };
 1618    exports2.supportsLookbehinds = () => {
 1619      const segs = process.version.slice(1).split(".").map(Number);
 1620      if (segs.length === 3 && segs[0] >= 9 || segs[0] === 8 && segs[1] >= 10) {
 1621        return true;
 1622      }
 1623      return false;
 1624    };
 1625    exports2.isWindows = (options) => {
 1626      if (options && typeof options.windows === "boolean") {
 1627        return options.windows;
 1628      }
 1629      return win32 === true || path5.sep === "\\";
 1630    };
 1631    exports2.escapeLast = (input, char, lastIdx) => {
 1632      const idx = input.lastIndexOf(char, lastIdx);
 1633      if (idx === -1) return input;
 1634      if (input[idx - 1] === "\\") return exports2.escapeLast(input, char, idx - 1);
 1635      return `${input.slice(0, idx)}\\${input.slice(idx)}`;
 1636    };
 1637    exports2.removePrefix = (input, state = {}) => {
 1638      let output = input;
 1639      if (output.startsWith("./")) {
 1640        output = output.slice(2);
 1641        state.prefix = "./";
 1642      }
 1643      return output;
 1644    };
 1645    exports2.wrapOutput = (input, state = {}, options = {}) => {
 1646      const prepend = options.contains ? "" : "^";
 1647      const append = options.contains ? "" : "$";
 1648      let output = `${prepend}(?:${input})${append}`;
 1649      if (state.negated === true) {
 1650        output = `(?:^(?!${output}).*$)`;
 1651      }
 1652      return output;
 1653    };
 1654  }
 1655});
 1656
 1657// node_modules/picomatch/lib/scan.js
 1658var require_scan = __commonJS({
 1659  "node_modules/picomatch/lib/scan.js"(exports2, module2) {
 1660    "use strict";
 1661    var utils = require_utils2();
 1662    var {
 1663      CHAR_ASTERISK,
 1664      /* * */
 1665      CHAR_AT,
 1666      /* @ */
 1667      CHAR_BACKWARD_SLASH,
 1668      /* \ */
 1669      CHAR_COMMA,
 1670      /* , */
 1671      CHAR_DOT,
 1672      /* . */
 1673      CHAR_EXCLAMATION_MARK,
 1674      /* ! */
 1675      CHAR_FORWARD_SLASH,
 1676      /* / */
 1677      CHAR_LEFT_CURLY_BRACE,
 1678      /* { */
 1679      CHAR_LEFT_PARENTHESES,
 1680      /* ( */
 1681      CHAR_LEFT_SQUARE_BRACKET,
 1682      /* [ */
 1683      CHAR_PLUS,
 1684      /* + */
 1685      CHAR_QUESTION_MARK,
 1686      /* ? */
 1687      CHAR_RIGHT_CURLY_BRACE,
 1688      /* } */
 1689      CHAR_RIGHT_PARENTHESES,
 1690      /* ) */
 1691      CHAR_RIGHT_SQUARE_BRACKET
 1692      /* ] */
 1693    } = require_constants2();
 1694    var isPathSeparator = (code) => {
 1695      return code === CHAR_FORWARD_SLASH || code === CHAR_BACKWARD_SLASH;
 1696    };
 1697    var depth = (token) => {
 1698      if (token.isPrefix !== true) {
 1699        token.depth = token.isGlobstar ? Infinity : 1;
 1700      }
 1701    };
 1702    var scan = (input, options) => {
 1703      const opts = options || {};
 1704      const length = input.length - 1;
 1705      const scanToEnd = opts.parts === true || opts.scanToEnd === true;
 1706      const slashes = [];
 1707      const tokens = [];
 1708      const parts = [];
 1709      let str = input;
 1710      let index = -1;
 1711      let start = 0;
 1712      let lastIndex = 0;
 1713      let isBrace = false;
 1714      let isBracket = false;
 1715      let isGlob = false;
 1716      let isExtglob = false;
 1717      let isGlobstar = false;
 1718      let braceEscaped = false;
 1719      let backslashes = false;
 1720      let negated = false;
 1721      let negatedExtglob = false;
 1722      let finished2 = false;
 1723      let braces = 0;
 1724      let prev;
 1725      let code;
 1726      let token = { value: "", depth: 0, isGlob: false };
 1727      const eos = () => index >= length;
 1728      const peek = () => str.charCodeAt(index + 1);
 1729      const advance = () => {
 1730        prev = code;
 1731        return str.charCodeAt(++index);
 1732      };
 1733      while (index < length) {
 1734        code = advance();
 1735        let next;
 1736        if (code === CHAR_BACKWARD_SLASH) {
 1737          backslashes = token.backslashes = true;
 1738          code = advance();
 1739          if (code === CHAR_LEFT_CURLY_BRACE) {
 1740            braceEscaped = true;
 1741          }
 1742          continue;
 1743        }
 1744        if (braceEscaped === true || code === CHAR_LEFT_CURLY_BRACE) {
 1745          braces++;
 1746          while (eos() !== true && (code = advance())) {
 1747            if (code === CHAR_BACKWARD_SLASH) {
 1748              backslashes = token.backslashes = true;
 1749              advance();
 1750              continue;
 1751            }
 1752            if (code === CHAR_LEFT_CURLY_BRACE) {
 1753              braces++;
 1754              continue;
 1755            }
 1756            if (braceEscaped !== true && code === CHAR_DOT && (code = advance()) === CHAR_DOT) {
 1757              isBrace = token.isBrace = true;
 1758              isGlob = token.isGlob = true;
 1759              finished2 = true;
 1760              if (scanToEnd === true) {
 1761                continue;
 1762              }
 1763              break;
 1764            }
 1765            if (braceEscaped !== true && code === CHAR_COMMA) {
 1766              isBrace = token.isBrace = true;
 1767              isGlob = token.isGlob = true;
 1768              finished2 = true;
 1769              if (scanToEnd === true) {
 1770                continue;
 1771              }
 1772              break;
 1773            }
 1774            if (code === CHAR_RIGHT_CURLY_BRACE) {
 1775              braces--;
 1776              if (braces === 0) {
 1777                braceEscaped = false;
 1778                isBrace = token.isBrace = true;
 1779                finished2 = true;
 1780                break;
 1781              }
 1782            }
 1783          }
 1784          if (scanToEnd === true) {
 1785            continue;
 1786          }
 1787          break;
 1788        }
 1789        if (code === CHAR_FORWARD_SLASH) {
 1790          slashes.push(index);
 1791          tokens.push(token);
 1792          token = { value: "", depth: 0, isGlob: false };
 1793          if (finished2 === true) continue;
 1794          if (prev === CHAR_DOT && index === start + 1) {
 1795            start += 2;
 1796            continue;
 1797          }
 1798          lastIndex = index + 1;
 1799          continue;
 1800        }
 1801        if (opts.noext !== true) {
 1802          const isExtglobChar = code === CHAR_PLUS || code === CHAR_AT || code === CHAR_ASTERISK || code === CHAR_QUESTION_MARK || code === CHAR_EXCLAMATION_MARK;
 1803          if (isExtglobChar === true && peek() === CHAR_LEFT_PARENTHESES) {
 1804            isGlob = token.isGlob = true;
 1805            isExtglob = token.isExtglob = true;
 1806            finished2 = true;
 1807            if (code === CHAR_EXCLAMATION_MARK && index === start) {
 1808              negatedExtglob = true;
 1809            }
 1810            if (scanToEnd === true) {
 1811              while (eos() !== true && (code = advance())) {
 1812                if (code === CHAR_BACKWARD_SLASH) {
 1813                  backslashes = token.backslashes = true;
 1814                  code = advance();
 1815                  continue;
 1816                }
 1817                if (code === CHAR_RIGHT_PARENTHESES) {
 1818                  isGlob = token.isGlob = true;
 1819                  finished2 = true;
 1820                  break;
 1821                }
 1822              }
 1823              continue;
 1824            }
 1825            break;
 1826          }
 1827        }
 1828        if (code === CHAR_ASTERISK) {
 1829          if (prev === CHAR_ASTERISK) isGlobstar = token.isGlobstar = true;
 1830          isGlob = token.isGlob = true;
 1831          finished2 = true;
 1832          if (scanToEnd === true) {
 1833            continue;
 1834          }
 1835          break;
 1836        }
 1837        if (code === CHAR_QUESTION_MARK) {
 1838          isGlob = token.isGlob = true;
 1839          finished2 = true;
 1840          if (scanToEnd === true) {
 1841            continue;
 1842          }
 1843          break;
 1844        }
 1845        if (code === CHAR_LEFT_SQUARE_BRACKET) {
 1846          while (eos() !== true && (next = advance())) {
 1847            if (next === CHAR_BACKWARD_SLASH) {
 1848              backslashes = token.backslashes = true;
 1849              advance();
 1850              continue;
 1851            }
 1852            if (next === CHAR_RIGHT_SQUARE_BRACKET) {
 1853              isBracket = token.isBracket = true;
 1854              isGlob = token.isGlob = true;
 1855              finished2 = true;
 1856              break;
 1857            }
 1858          }
 1859          if (scanToEnd === true) {
 1860            continue;
 1861          }
 1862          break;
 1863        }
 1864        if (opts.nonegate !== true && code === CHAR_EXCLAMATION_MARK && index === start) {
 1865          negated = token.negated = true;
 1866          start++;
 1867          continue;
 1868        }
 1869        if (opts.noparen !== true && code === CHAR_LEFT_PARENTHESES) {
 1870          isGlob = token.isGlob = true;
 1871          if (scanToEnd === true) {
 1872            while (eos() !== true && (code = advance())) {
 1873              if (code === CHAR_LEFT_PARENTHESES) {
 1874                backslashes = token.backslashes = true;
 1875                code = advance();
 1876                continue;
 1877              }
 1878              if (code === CHAR_RIGHT_PARENTHESES) {
 1879                finished2 = true;
 1880                break;
 1881              }
 1882            }
 1883            continue;
 1884          }
 1885          break;
 1886        }
 1887        if (isGlob === true) {
 1888          finished2 = true;
 1889          if (scanToEnd === true) {
 1890            continue;
 1891          }
 1892          break;
 1893        }
 1894      }
 1895      if (opts.noext === true) {
 1896        isExtglob = false;
 1897        isGlob = false;
 1898      }
 1899      let base = str;
 1900      let prefix = "";
 1901      let glob2 = "";
 1902      if (start > 0) {
 1903        prefix = str.slice(0, start);
 1904        str = str.slice(start);
 1905        lastIndex -= start;
 1906      }
 1907      if (base && isGlob === true && lastIndex > 0) {
 1908        base = str.slice(0, lastIndex);
 1909        glob2 = str.slice(lastIndex);
 1910      } else if (isGlob === true) {
 1911        base = "";
 1912        glob2 = str;
 1913      } else {
 1914        base = str;
 1915      }
 1916      if (base && base !== "" && base !== "/" && base !== str) {
 1917        if (isPathSeparator(base.charCodeAt(base.length - 1))) {
 1918          base = base.slice(0, -1);
 1919        }
 1920      }
 1921      if (opts.unescape === true) {
 1922        if (glob2) glob2 = utils.removeBackslashes(glob2);
 1923        if (base && backslashes === true) {
 1924          base = utils.removeBackslashes(base);
 1925        }
 1926      }
 1927      const state = {
 1928        prefix,
 1929        input,
 1930        start,
 1931        base,
 1932        glob: glob2,
 1933        isBrace,
 1934        isBracket,
 1935        isGlob,
 1936        isExtglob,
 1937        isGlobstar,
 1938        negated,
 1939        negatedExtglob
 1940      };
 1941      if (opts.tokens === true) {
 1942        state.maxDepth = 0;
 1943        if (!isPathSeparator(code)) {
 1944          tokens.push(token);
 1945        }
 1946        state.tokens = tokens;
 1947      }
 1948      if (opts.parts === true || opts.tokens === true) {
 1949        let prevIndex;
 1950        for (let idx = 0; idx < slashes.length; idx++) {
 1951          const n4 = prevIndex ? prevIndex + 1 : start;
 1952          const i = slashes[idx];
 1953          const value = input.slice(n4, i);
 1954          if (opts.tokens) {
 1955            if (idx === 0 && start !== 0) {
 1956              tokens[idx].isPrefix = true;
 1957              tokens[idx].value = prefix;
 1958            } else {
 1959              tokens[idx].value = value;
 1960            }
 1961            depth(tokens[idx]);
 1962            state.maxDepth += tokens[idx].depth;
 1963          }
 1964          if (idx !== 0 || value !== "") {
 1965            parts.push(value);
 1966          }
 1967          prevIndex = i;
 1968        }
 1969        if (prevIndex && prevIndex + 1 < input.length) {
 1970          const value = input.slice(prevIndex + 1);
 1971          parts.push(value);
 1972          if (opts.tokens) {
 1973            tokens[tokens.length - 1].value = value;
 1974            depth(tokens[tokens.length - 1]);
 1975            state.maxDepth += tokens[tokens.length - 1].depth;
 1976          }
 1977        }
 1978        state.slashes = slashes;
 1979        state.parts = parts;
 1980      }
 1981      return state;
 1982    };
 1983    module2.exports = scan;
 1984  }
 1985});
 1986
 1987// node_modules/picomatch/lib/parse.js
 1988var require_parse2 = __commonJS({
 1989  "node_modules/picomatch/lib/parse.js"(exports2, module2) {
 1990    "use strict";
 1991    var constants = require_constants2();
 1992    var utils = require_utils2();
 1993    var {
 1994      MAX_LENGTH,
 1995      POSIX_REGEX_SOURCE,
 1996      REGEX_NON_SPECIAL_CHARS,
 1997      REGEX_SPECIAL_CHARS_BACKREF,
 1998      REPLACEMENTS
 1999    } = constants;
 2000    var expandRange = (args, options) => {
 2001      if (typeof options.expandRange === "function") {
 2002        return options.expandRange(...args, options);
 2003      }
 2004      args.sort();
 2005      const value = `[${args.join("-")}]`;
 2006      try {
 2007        new RegExp(value);
 2008      } catch (ex) {
 2009        return args.map((v2) => utils.escapeRegex(v2)).join("..");
 2010      }
 2011      return value;
 2012    };
 2013    var syntaxError = (type, char) => {
 2014      return `Missing ${type}: "${char}" - use "\\\\${char}" to match literal characters`;
 2015    };
 2016    var parse4 = (input, options) => {
 2017      if (typeof input !== "string") {
 2018        throw new TypeError("Expected a string");
 2019      }
 2020      input = REPLACEMENTS[input] || input;
 2021      const opts = __spreadValues({}, options);
 2022      const max = typeof opts.maxLength === "number" ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH;
 2023      let len = input.length;
 2024      if (len > max) {
 2025        throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`);
 2026      }
 2027      const bos = { type: "bos", value: "", output: opts.prepend || "" };
 2028      const tokens = [bos];
 2029      const capture = opts.capture ? "" : "?:";
 2030      const win32 = utils.isWindows(options);
 2031      const PLATFORM_CHARS = constants.globChars(win32);
 2032      const EXTGLOB_CHARS = constants.extglobChars(PLATFORM_CHARS);
 2033      const {
 2034        DOT_LITERAL,
 2035        PLUS_LITERAL,
 2036        SLASH_LITERAL,
 2037        ONE_CHAR,
 2038        DOTS_SLASH,
 2039        NO_DOT,
 2040        NO_DOT_SLASH,
 2041        NO_DOTS_SLASH,
 2042        QMARK,
 2043        QMARK_NO_DOT,
 2044        STAR,
 2045        START_ANCHOR
 2046      } = PLATFORM_CHARS;
 2047      const globstar = (opts2) => {
 2048        return `(${capture}(?:(?!${START_ANCHOR}${opts2.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`;
 2049      };
 2050      const nodot = opts.dot ? "" : NO_DOT;
 2051      const qmarkNoDot = opts.dot ? QMARK : QMARK_NO_DOT;
 2052      let star = opts.bash === true ? globstar(opts) : STAR;
 2053      if (opts.capture) {
 2054        star = `(${star})`;
 2055      }
 2056      if (typeof opts.noext === "boolean") {
 2057        opts.noextglob = opts.noext;
 2058      }
 2059      const state = {
 2060        input,
 2061        index: -1,
 2062        start: 0,
 2063        dot: opts.dot === true,
 2064        consumed: "",
 2065        output: "",
 2066        prefix: "",
 2067        backtrack: false,
 2068        negated: false,
 2069        brackets: 0,
 2070        braces: 0,
 2071        parens: 0,
 2072        quotes: 0,
 2073        globstar: false,
 2074        tokens
 2075      };
 2076      input = utils.removePrefix(input, state);
 2077      len = input.length;
 2078      const extglobs = [];
 2079      const braces = [];
 2080      const stack = [];
 2081      let prev = bos;
 2082      let value;
 2083      const eos = () => state.index === len - 1;
 2084      const peek = state.peek = (n4 = 1) => input[state.index + n4];
 2085      const advance = state.advance = () => input[++state.index] || "";
 2086      const remaining = () => input.slice(state.index + 1);
 2087      const consume = (value2 = "", num = 0) => {
 2088        state.consumed += value2;
 2089        state.index += num;
 2090      };
 2091      const append = (token) => {
 2092        state.output += token.output != null ? token.output : token.value;
 2093        consume(token.value);
 2094      };
 2095      const negate = () => {
 2096        let count = 1;
 2097        while (peek() === "!" && (peek(2) !== "(" || peek(3) === "?")) {
 2098          advance();
 2099          state.start++;
 2100          count++;
 2101        }
 2102        if (count % 2 === 0) {
 2103          return false;
 2104        }
 2105        state.negated = true;
 2106        state.start++;
 2107        return true;
 2108      };
 2109      const increment = (type) => {
 2110        state[type]++;
 2111        stack.push(type);
 2112      };
 2113      const decrement = (type) => {
 2114        state[type]--;
 2115        stack.pop();
 2116      };
 2117      const push = (tok) => {
 2118        if (prev.type === "globstar") {
 2119          const isBrace = state.braces > 0 && (tok.type === "comma" || tok.type === "brace");
 2120          const isExtglob = tok.extglob === true || extglobs.length && (tok.type === "pipe" || tok.type === "paren");
 2121          if (tok.type !== "slash" && tok.type !== "paren" && !isBrace && !isExtglob) {
 2122            state.output = state.output.slice(0, -prev.output.length);
 2123            prev.type = "star";
 2124            prev.value = "*";
 2125            prev.output = star;
 2126            state.output += prev.output;
 2127          }
 2128        }
 2129        if (extglobs.length && tok.type !== "paren") {
 2130          extglobs[extglobs.length - 1].inner += tok.value;
 2131        }
 2132        if (tok.value || tok.output) append(tok);
 2133        if (prev && prev.type === "text" && tok.type === "text") {
 2134          prev.value += tok.value;
 2135          prev.output = (prev.output || "") + tok.value;
 2136          return;
 2137        }
 2138        tok.prev = prev;
 2139        tokens.push(tok);
 2140        prev = tok;
 2141      };
 2142      const extglobOpen = (type, value2) => {
 2143        const token = __spreadProps(__spreadValues({}, EXTGLOB_CHARS[value2]), { conditions: 1, inner: "" });
 2144        token.prev = prev;
 2145        token.parens = state.parens;
 2146        token.output = state.output;
 2147        const output = (opts.capture ? "(" : "") + token.open;
 2148        increment("parens");
 2149        push({ type, value: value2, output: state.output ? "" : ONE_CHAR });
 2150        push({ type: "paren", extglob: true, value: advance(), output });
 2151        extglobs.push(token);
 2152      };
 2153      const extglobClose = (token) => {
 2154        let output = token.close + (opts.capture ? ")" : "");
 2155        let rest;
 2156        if (token.type === "negate") {
 2157          let extglobStar = star;
 2158          if (token.inner && token.inner.length > 1 && token.inner.includes("/")) {
 2159            extglobStar = globstar(opts);
 2160          }
 2161          if (extglobStar !== star || eos() || /^\)+$/.test(remaining())) {
 2162            output = token.close = `)$))${extglobStar}`;
 2163          }
 2164          if (token.inner.includes("*") && (rest = remaining()) && /^\.[^\\/.]+$/.test(rest)) {
 2165            const expression = parse4(rest, __spreadProps(__spreadValues({}, options), { fastpaths: false })).output;
 2166            output = token.close = `)${expression})${extglobStar})`;
 2167          }
 2168          if (token.prev.type === "bos") {
 2169            state.negatedExtglob = true;
 2170          }
 2171        }
 2172        push({ type: "paren", extglob: true, value, output });
 2173        decrement("parens");
 2174      };
 2175      if (opts.fastpaths !== false && !/(^[*!]|[/()[\]{}"])/.test(input)) {
 2176        let backslashes = false;
 2177        let output = input.replace(REGEX_SPECIAL_CHARS_BACKREF, (m2, esc, chars, first, rest, index) => {
 2178          if (first === "\\") {
 2179            backslashes = true;
 2180            return m2;
 2181          }
 2182          if (first === "?") {
 2183            if (esc) {
 2184              return esc + first + (rest ? QMARK.repeat(rest.length) : "");
 2185            }
 2186            if (index === 0) {
 2187              return qmarkNoDot + (rest ? QMARK.repeat(rest.length) : "");
 2188            }
 2189            return QMARK.repeat(chars.length);
 2190          }
 2191          if (first === ".") {
 2192            return DOT_LITERAL.repeat(chars.length);
 2193          }
 2194          if (first === "*") {
 2195            if (esc) {
 2196              return esc + first + (rest ? star : "");
 2197            }
 2198            return star;
 2199          }
 2200          return esc ? m2 : `\\${m2}`;
 2201        });
 2202        if (backslashes === true) {
 2203          if (opts.unescape === true) {
 2204            output = output.replace(/\\/g, "");
 2205          } else {
 2206            output = output.replace(/\\+/g, (m2) => {
 2207              return m2.length % 2 === 0 ? "\\\\" : m2 ? "\\" : "";
 2208            });
 2209          }
 2210        }
 2211        if (output === input && opts.contains === true) {
 2212          state.output = input;
 2213          return state;
 2214        }
 2215        state.output = utils.wrapOutput(output, state, options);
 2216        return state;
 2217      }
 2218      while (!eos()) {
 2219        value = advance();
 2220        if (value === "\0") {
 2221          continue;
 2222        }
 2223        if (value === "\\") {
 2224          const next = peek();
 2225          if (next === "/" && opts.bash !== true) {
 2226            continue;
 2227          }
 2228          if (next === "." || next === ";") {
 2229            continue;
 2230          }
 2231          if (!next) {
 2232            value += "\\";
 2233            push({ type: "text", value });
 2234            continue;
 2235          }
 2236          const match = /^\\+/.exec(remaining());
 2237          let slashes = 0;
 2238          if (match && match[0].length > 2) {
 2239            slashes = match[0].length;
 2240            state.index += slashes;
 2241            if (slashes % 2 !== 0) {
 2242              value += "\\";
 2243            }
 2244          }
 2245          if (opts.unescape === true) {
 2246            value = advance();
 2247          } else {
 2248            value += advance();
 2249          }
 2250          if (state.brackets === 0) {
 2251            push({ type: "text", value });
 2252            continue;
 2253          }
 2254        }
 2255        if (state.brackets > 0 && (value !== "]" || prev.value === "[" || prev.value === "[^")) {
 2256          if (opts.posix !== false && value === ":") {
 2257            const inner = prev.value.slice(1);
 2258            if (inner.includes("[")) {
 2259              prev.posix = true;
 2260              if (inner.includes(":")) {
 2261                const idx = prev.value.lastIndexOf("[");
 2262                const pre = prev.value.slice(0, idx);
 2263                const rest2 = prev.value.slice(idx + 2);
 2264                const posix = POSIX_REGEX_SOURCE[rest2];
 2265                if (posix) {
 2266                  prev.value = pre + posix;
 2267                  state.backtrack = true;
 2268                  advance();
 2269                  if (!bos.output && tokens.indexOf(prev) === 1) {
 2270                    bos.output = ONE_CHAR;
 2271                  }
 2272                  continue;
 2273                }
 2274              }
 2275            }
 2276          }
 2277          if (value === "[" && peek() !== ":" || value === "-" && peek() === "]") {
 2278            value = `\\${value}`;
 2279          }
 2280          if (value === "]" && (prev.value === "[" || prev.value === "[^")) {
 2281            value = `\\${value}`;
 2282          }
 2283          if (opts.posix === true && value === "!" && prev.value === "[") {
 2284            value = "^";
 2285          }
 2286          prev.value += value;
 2287          append({ value });
 2288          continue;
 2289        }
 2290        if (state.quotes === 1 && value !== '"') {
 2291          value = utils.escapeRegex(value);
 2292          prev.value += value;
 2293          append({ value });
 2294          continue;
 2295        }
 2296        if (value === '"') {
 2297          state.quotes = state.quotes === 1 ? 0 : 1;
 2298          if (opts.keepQuotes === true) {
 2299            push({ type: "text", value });
 2300          }
 2301          continue;
 2302        }
 2303        if (value === "(") {
 2304          increment("parens");
 2305          push({ type: "paren", value });
 2306          continue;
 2307        }
 2308        if (value === ")") {
 2309          if (state.parens === 0 && opts.strictBrackets === true) {
 2310            throw new SyntaxError(syntaxError("opening", "("));
 2311          }
 2312          const extglob = extglobs[extglobs.length - 1];
 2313          if (extglob && state.parens === extglob.parens + 1) {
 2314            extglobClose(extglobs.pop());
 2315            continue;
 2316          }
 2317          push({ type: "paren", value, output: state.parens ? ")" : "\\)" });
 2318          decrement("parens");
 2319          continue;
 2320        }
 2321        if (value === "[") {
 2322          if (opts.nobracket === true || !remaining().includes("]")) {
 2323            if (opts.nobracket !== true && opts.strictBrackets === true) {
 2324              throw new SyntaxError(syntaxError("closing", "]"));
 2325            }
 2326            value = `\\${value}`;
 2327          } else {
 2328            increment("brackets");
 2329          }
 2330          push({ type: "bracket", value });
 2331          continue;
 2332        }
 2333        if (value === "]") {
 2334          if (opts.nobracket === true || prev && prev.type === "bracket" && prev.value.length === 1) {
 2335            push({ type: "text", value, output: `\\${value}` });
 2336            continue;
 2337          }
 2338          if (state.brackets === 0) {
 2339            if (opts.strictBrackets === true) {
 2340              throw new SyntaxError(syntaxError("opening", "["));
 2341            }
 2342            push({ type: "text", value, output: `\\${value}` });
 2343            continue;
 2344          }
 2345          decrement("brackets");
 2346          const prevValue = prev.value.slice(1);
 2347          if (prev.posix !== true && prevValue[0] === "^" && !prevValue.includes("/")) {
 2348            value = `/${value}`;
 2349          }
 2350          prev.value += value;
 2351          append({ value });
 2352          if (opts.literalBrackets === false || utils.hasRegexChars(prevValue)) {
 2353            continue;
 2354          }
 2355          const escaped = utils.escapeRegex(prev.value);
 2356          state.output = state.output.slice(0, -prev.value.length);
 2357          if (opts.literalBrackets === true) {
 2358            state.output += escaped;
 2359            prev.value = escaped;
 2360            continue;
 2361          }
 2362          prev.value = `(${capture}${escaped}|${prev.value})`;
 2363          state.output += prev.value;
 2364          continue;
 2365        }
 2366        if (value === "{" && opts.nobrace !== true) {
 2367          increment("braces");
 2368          const open = {
 2369            type: "brace",
 2370            value,
 2371            output: "(",
 2372            outputIndex: state.output.length,
 2373            tokensIndex: state.tokens.length
 2374          };
 2375          braces.push(open);
 2376          push(open);
 2377          continue;
 2378        }
 2379        if (value === "}") {
 2380          const brace = braces[braces.length - 1];
 2381          if (opts.nobrace === true || !brace) {
 2382            push({ type: "text", value, output: value });
 2383            continue;
 2384          }
 2385          let output = ")";
 2386          if (brace.dots === true) {
 2387            const arr = tokens.slice();
 2388            const range = [];
 2389            for (let i = arr.length - 1; i >= 0; i--) {
 2390              tokens.pop();
 2391              if (arr[i].type === "brace") {
 2392                break;
 2393              }
 2394              if (arr[i].type !== "dots") {
 2395                range.unshift(arr[i].value);
 2396              }
 2397            }
 2398            output = expandRange(range, opts);
 2399            state.backtrack = true;
 2400          }
 2401          if (brace.comma !== true && brace.dots !== true) {
 2402            const out = state.output.slice(0, brace.outputIndex);
 2403            const toks = state.tokens.slice(brace.tokensIndex);
 2404            brace.value = brace.output = "\\{";
 2405            value = output = "\\}";
 2406            state.output = out;
 2407            for (const t3 of toks) {
 2408              state.output += t3.output || t3.value;
 2409            }
 2410          }
 2411          push({ type: "brace", value, output });
 2412          decrement("braces");
 2413          braces.pop();
 2414          continue;
 2415        }
 2416        if (value === "|") {
 2417          if (extglobs.length > 0) {
 2418            extglobs[extglobs.length - 1].conditions++;
 2419          }
 2420          push({ type: "text", value });
 2421          continue;
 2422        }
 2423        if (value === ",") {
 2424          let output = value;
 2425          const brace = braces[braces.length - 1];
 2426          if (brace && stack[stack.length - 1] === "braces") {
 2427            brace.comma = true;
 2428            output = "|";
 2429          }
 2430          push({ type: "comma", value, output });
 2431          continue;
 2432        }
 2433        if (value === "/") {
 2434          if (prev.type === "dot" && state.index === state.start + 1) {
 2435            state.start = state.index + 1;
 2436            state.consumed = "";
 2437            state.output = "";
 2438            tokens.pop();
 2439            prev = bos;
 2440            continue;
 2441          }
 2442          push({ type: "slash", value, output: SLASH_LITERAL });
 2443          continue;
 2444        }
 2445        if (value === ".") {
 2446          if (state.braces > 0 && prev.type === "dot") {
 2447            if (prev.value === ".") prev.output = DOT_LITERAL;
 2448            const brace = braces[braces.length - 1];
 2449            prev.type = "dots";
 2450            prev.output += value;
 2451            prev.value += value;
 2452            brace.dots = true;
 2453            continue;
 2454          }
 2455          if (state.braces + state.parens === 0 && prev.type !== "bos" && prev.type !== "slash") {
 2456            push({ type: "text", value, output: DOT_LITERAL });
 2457            continue;
 2458          }
 2459          push({ type: "dot", value, output: DOT_LITERAL });
 2460          continue;
 2461        }
 2462        if (value === "?") {
 2463          const isGroup = prev && prev.value === "(";
 2464          if (!isGroup && opts.noextglob !== true && peek() === "(" && peek(2) !== "?") {
 2465            extglobOpen("qmark", value);
 2466            continue;
 2467          }
 2468          if (prev && prev.type === "paren") {
 2469            const next = peek();
 2470            let output = value;
 2471            if (next === "<" && !utils.supportsLookbehinds()) {
 2472              throw new Error("Node.js v10 or higher is required for regex lookbehinds");
 2473            }
 2474            if (prev.value === "(" && !/[!=<:]/.test(next) || next === "<" && !/<([!=]|\w+>)/.test(remaining())) {
 2475              output = `\\${value}`;
 2476            }
 2477            push({ type: "text", value, output });
 2478            continue;
 2479          }
 2480          if (opts.dot !== true && (prev.type === "slash" || prev.type === "bos")) {
 2481            push({ type: "qmark", value, output: QMARK_NO_DOT });
 2482            continue;
 2483          }
 2484          push({ type: "qmark", value, output: QMARK });
 2485          continue;
 2486        }
 2487        if (value === "!") {
 2488          if (opts.noextglob !== true && peek() === "(") {
 2489            if (peek(2) !== "?" || !/[!=<:]/.test(peek(3))) {
 2490              extglobOpen("negate", value);
 2491              continue;
 2492            }
 2493          }
 2494          if (opts.nonegate !== true && state.index === 0) {
 2495            negate();
 2496            continue;
 2497          }
 2498        }
 2499        if (value === "+") {
 2500          if (opts.noextglob !== true && peek() === "(" && peek(2) !== "?") {
 2501            extglobOpen("plus", value);
 2502            continue;
 2503          }
 2504          if (prev && prev.value === "(" || opts.regex === false) {
 2505            push({ type: "plus", value, output: PLUS_LITERAL });
 2506            continue;
 2507          }
 2508          if (prev && (prev.type === "bracket" || prev.type === "paren" || prev.type === "brace") || state.parens > 0) {
 2509            push({ type: "plus", value });
 2510            continue;
 2511          }
 2512          push({ type: "plus", value: PLUS_LITERAL });
 2513          continue;
 2514        }
 2515        if (value === "@") {
 2516          if (opts.noextglob !== true && peek() === "(" && peek(2) !== "?") {
 2517            push({ type: "at", extglob: true, value, output: "" });
 2518            continue;
 2519          }
 2520          push({ type: "text", value });
 2521          continue;
 2522        }
 2523        if (value !== "*") {
 2524          if (value === "$" || value === "^") {
 2525            value = `\\${value}`;
 2526          }
 2527          const match = REGEX_NON_SPECIAL_CHARS.exec(remaining());
 2528          if (match) {
 2529            value += match[0];
 2530            state.index += match[0].length;
 2531          }
 2532          push({ type: "text", value });
 2533          continue;
 2534        }
 2535        if (prev && (prev.type === "globstar" || prev.star === true)) {
 2536          prev.type = "star";
 2537          prev.star = true;
 2538          prev.value += value;
 2539          prev.output = star;
 2540          state.backtrack = true;
 2541          state.globstar = true;
 2542          consume(value);
 2543          continue;
 2544        }
 2545        let rest = remaining();
 2546        if (opts.noextglob !== true && /^\([^?]/.test(rest)) {
 2547          extglobOpen("star", value);
 2548          continue;
 2549        }
 2550        if (prev.type === "star") {
 2551          if (opts.noglobstar === true) {
 2552            consume(value);
 2553            continue;
 2554          }
 2555          const prior = prev.prev;
 2556          const before = prior.prev;
 2557          const isStart = prior.type === "slash" || prior.type === "bos";
 2558          const afterStar = before && (before.type === "star" || before.type === "globstar");
 2559          if (opts.bash === true && (!isStart || rest[0] && rest[0] !== "/")) {
 2560            push({ type: "star", value, output: "" });
 2561            continue;
 2562          }
 2563          const isBrace = state.braces > 0 && (prior.type === "comma" || prior.type === "brace");
 2564          const isExtglob = extglobs.length && (prior.type === "pipe" || prior.type === "paren");
 2565          if (!isStart && prior.type !== "paren" && !isBrace && !isExtglob) {
 2566            push({ type: "star", value, output: "" });
 2567            continue;
 2568          }
 2569          while (rest.slice(0, 3) === "/**") {
 2570            const after = input[state.index + 4];
 2571            if (after && after !== "/") {
 2572              break;
 2573            }
 2574            rest = rest.slice(3);
 2575            consume("/**", 3);
 2576          }
 2577          if (prior.type === "bos" && eos()) {
 2578            prev.type = "globstar";
 2579            prev.value += value;
 2580            prev.output = globstar(opts);
 2581            state.output = prev.output;
 2582            state.globstar = true;
 2583            consume(value);
 2584            continue;
 2585          }
 2586          if (prior.type === "slash" && prior.prev.type !== "bos" && !afterStar && eos()) {
 2587            state.output = state.output.slice(0, -(prior.output + prev.output).length);
 2588            prior.output = `(?:${prior.output}`;
 2589            prev.type = "globstar";
 2590            prev.output = globstar(opts) + (opts.strictSlashes ? ")" : "|$)");
 2591            prev.value += value;
 2592            state.globstar = true;
 2593            state.output += prior.output + prev.output;
 2594            consume(value);
 2595            continue;
 2596          }
 2597          if (prior.type === "slash" && prior.prev.type !== "bos" && rest[0] === "/") {
 2598            const end = rest[1] !== void 0 ? "|$" : "";
 2599            state.output = state.output.slice(0, -(prior.output + prev.output).length);
 2600            prior.output = `(?:${prior.output}`;
 2601            prev.type = "globstar";
 2602            prev.output = `${globstar(opts)}${SLASH_LITERAL}|${SLASH_LITERAL}${end})`;
 2603            prev.value += value;
 2604            state.output += prior.output + prev.output;
 2605            state.globstar = true;
 2606            consume(value + advance());
 2607            push({ type: "slash", value: "/", output: "" });
 2608            continue;
 2609          }
 2610          if (prior.type === "bos" && rest[0] === "/") {
 2611            prev.type = "globstar";
 2612            prev.value += value;
 2613            prev.output = `(?:^|${SLASH_LITERAL}|${globstar(opts)}${SLASH_LITERAL})`;
 2614            state.output = prev.output;
 2615            state.globstar = true;
 2616            consume(value + advance());
 2617            push({ type: "slash", value: "/", output: "" });
 2618            continue;
 2619          }
 2620          state.output = state.output.slice(0, -prev.output.length);
 2621          prev.type = "globstar";
 2622          prev.output = globstar(opts);
 2623          prev.value += value;
 2624          state.output += prev.output;
 2625          state.globstar = true;
 2626          consume(value);
 2627          continue;
 2628        }
 2629        const token = { type: "star", value, output: star };
 2630        if (opts.bash === true) {
 2631          token.output = ".*?";
 2632          if (prev.type === "bos" || prev.type === "slash") {
 2633            token.output = nodot + token.output;
 2634          }
 2635          push(token);
 2636          continue;
 2637        }
 2638        if (prev && (prev.type === "bracket" || prev.type === "paren") && opts.regex === true) {
 2639          token.output = value;
 2640          push(token);
 2641          continue;
 2642        }
 2643        if (state.index === state.start || prev.type === "slash" || prev.type === "dot") {
 2644          if (prev.type === "dot") {
 2645            state.output += NO_DOT_SLASH;
 2646            prev.output += NO_DOT_SLASH;
 2647          } else if (opts.dot === true) {
 2648            state.output += NO_DOTS_SLASH;
 2649            prev.output += NO_DOTS_SLASH;
 2650          } else {
 2651            state.output += nodot;
 2652            prev.output += nodot;
 2653          }
 2654          if (peek() !== "*") {
 2655            state.output += ONE_CHAR;
 2656            prev.output += ONE_CHAR;
 2657          }
 2658        }
 2659        push(token);
 2660      }
 2661      while (state.brackets > 0) {
 2662        if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", "]"));
 2663        state.output = utils.escapeLast(state.output, "[");
 2664        decrement("brackets");
 2665      }
 2666      while (state.parens > 0) {
 2667        if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", ")"));
 2668        state.output = utils.escapeLast(state.output, "(");
 2669        decrement("parens");
 2670      }
 2671      while (state.braces > 0) {
 2672        if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", "}"));
 2673        state.output = utils.escapeLast(state.output, "{");
 2674        decrement("braces");
 2675      }
 2676      if (opts.strictSlashes !== true && (prev.type === "star" || prev.type === "bracket")) {
 2677        push({ type: "maybe_slash", value: "", output: `${SLASH_LITERAL}?` });
 2678      }
 2679      if (state.backtrack === true) {
 2680        state.output = "";
 2681        for (const token of state.tokens) {
 2682          state.output += token.output != null ? token.output : token.value;
 2683          if (token.suffix) {
 2684            state.output += token.suffix;
 2685          }
 2686        }
 2687      }
 2688      return state;
 2689    };
 2690    parse4.fastpaths = (input, options) => {
 2691      const opts = __spreadValues({}, options);
 2692      const max = typeof opts.maxLength === "number" ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH;
 2693      const len = input.length;
 2694      if (len > max) {
 2695        throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`);
 2696      }
 2697      input = REPLACEMENTS[input] || input;
 2698      const win32 = utils.isWindows(options);
 2699      const {
 2700        DOT_LITERAL,
 2701        SLASH_LITERAL,
 2702        ONE_CHAR,
 2703        DOTS_SLASH,
 2704        NO_DOT,
 2705        NO_DOTS,
 2706        NO_DOTS_SLASH,
 2707        STAR,
 2708        START_ANCHOR
 2709      } = constants.globChars(win32);
 2710      const nodot = opts.dot ? NO_DOTS : NO_DOT;
 2711      const slashDot = opts.dot ? NO_DOTS_SLASH : NO_DOT;
 2712      const capture = opts.capture ? "" : "?:";
 2713      const state = { negated: false, prefix: "" };
 2714      let star = opts.bash === true ? ".*?" : STAR;
 2715      if (opts.capture) {
 2716        star = `(${star})`;
 2717      }
 2718      const globstar = (opts2) => {
 2719        if (opts2.noglobstar === true) return star;
 2720        return `(${capture}(?:(?!${START_ANCHOR}${opts2.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`;
 2721      };
 2722      const create = (str) => {
 2723        switch (str) {
 2724          case "*":
 2725            return `${nodot}${ONE_CHAR}${star}`;
 2726          case ".*":
 2727            return `${DOT_LITERAL}${ONE_CHAR}${star}`;
 2728          case "*.*":
 2729            return `${nodot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`;
 2730          case "*/*":
 2731            return `${nodot}${star}${SLASH_LITERAL}${ONE_CHAR}${slashDot}${star}`;
 2732          case "**":
 2733            return nodot + globstar(opts);
 2734          case "**/*":
 2735            return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${ONE_CHAR}${star}`;
 2736          case "**/*.*":
 2737            return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`;
 2738          case "**/.*":
 2739            return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${DOT_LITERAL}${ONE_CHAR}${star}`;
 2740          default: {
 2741            const match = /^(.*?)\.(\w+)$/.exec(str);
 2742            if (!match) return;
 2743            const source2 = create(match[1]);
 2744            if (!source2) return;
 2745            return source2 + DOT_LITERAL + match[2];
 2746          }
 2747        }
 2748      };
 2749      const output = utils.removePrefix(input, state);
 2750      let source = create(output);
 2751      if (source && opts.strictSlashes !== true) {
 2752        source += `${SLASH_LITERAL}?`;
 2753      }
 2754      return source;
 2755    };
 2756    module2.exports = parse4;
 2757  }
 2758});
 2759
 2760// node_modules/picomatch/lib/picomatch.js
 2761var require_picomatch = __commonJS({
 2762  "node_modules/picomatch/lib/picomatch.js"(exports2, module2) {
 2763    "use strict";
 2764    var path5 = require("path");
 2765    var scan = require_scan();
 2766    var parse4 = require_parse2();
 2767    var utils = require_utils2();
 2768    var constants = require_constants2();
 2769    var isObject = (val) => val && typeof val === "object" && !Array.isArray(val);
 2770    var picomatch = (glob2, options, returnState = false) => {
 2771      if (Array.isArray(glob2)) {
 2772        const fns = glob2.map((input) => picomatch(input, options, returnState));
 2773        const arrayMatcher = (str) => {
 2774          for (const isMatch of fns) {
 2775            const state2 = isMatch(str);
 2776            if (state2) return state2;
 2777          }
 2778          return false;
 2779        };
 2780        return arrayMatcher;
 2781      }
 2782      const isState = isObject(glob2) && glob2.tokens && glob2.input;
 2783      if (glob2 === "" || typeof glob2 !== "string" && !isState) {
 2784        throw new TypeError("Expected pattern to be a non-empty string");
 2785      }
 2786      const opts = options || {};
 2787      const posix = utils.isWindows(options);
 2788      const regex = isState ? picomatch.compileRe(glob2, options) : picomatch.makeRe(glob2, options, false, true);
 2789      const state = regex.state;
 2790      delete regex.state;
 2791      let isIgnored = () => false;
 2792      if (opts.ignore) {
 2793        const ignoreOpts = __spreadProps(__spreadValues({}, options), { ignore: null, onMatch: null, onResult: null });
 2794        isIgnored = picomatch(opts.ignore, ignoreOpts, returnState);
 2795      }
 2796      const matcher = (input, returnObject = false) => {
 2797        const { isMatch, match, output } = picomatch.test(input, regex, options, { glob: glob2, posix });
 2798        const result = { glob: glob2, state, regex, posix, input, output, match, isMatch };
 2799        if (typeof opts.onResult === "function") {
 2800          opts.onResult(result);
 2801        }
 2802        if (isMatch === false) {
 2803          result.isMatch = false;
 2804          return returnObject ? result : false;
 2805        }
 2806        if (isIgnored(input)) {
 2807          if (typeof opts.onIgnore === "function") {
 2808            opts.onIgnore(result);
 2809          }
 2810          result.isMatch = false;
 2811          return returnObject ? result : false;
 2812        }
 2813        if (typeof opts.onMatch === "function") {
 2814          opts.onMatch(result);
 2815        }
 2816        return returnObject ? result : true;
 2817      };
 2818      if (returnState) {
 2819        matcher.state = state;
 2820      }
 2821      return matcher;
 2822    };
 2823    picomatch.test = (input, regex, options, { glob: glob2, posix } = {}) => {
 2824      if (typeof input !== "string") {
 2825        throw new TypeError("Expected input to be a string");
 2826      }
 2827      if (input === "") {
 2828        return { isMatch: false, output: "" };
 2829      }
 2830      const opts = options || {};
 2831      const format = opts.format || (posix ? utils.toPosixSlashes : null);
 2832      let match = input === glob2;
 2833      let output = match && format ? format(input) : input;
 2834      if (match === false) {
 2835        output = format ? format(input) : input;
 2836        match = output === glob2;
 2837      }
 2838      if (match === false || opts.capture === true) {
 2839        if (opts.matchBase === true || opts.basename === true) {
 2840          match = picomatch.matchBase(input, regex, options, posix);
 2841        } else {
 2842          match = regex.exec(output);
 2843        }
 2844      }
 2845      return { isMatch: Boolean(match), match, output };
 2846    };
 2847    picomatch.matchBase = (input, glob2, options, posix = utils.isWindows(options)) => {
 2848      const regex = glob2 instanceof RegExp ? glob2 : picomatch.makeRe(glob2, options);
 2849      return regex.test(path5.basename(input));
 2850    };
 2851    picomatch.isMatch = (str, patterns, options) => picomatch(patterns, options)(str);
 2852    picomatch.parse = (pattern, options) => {
 2853      if (Array.isArray(pattern)) return pattern.map((p2) => picomatch.parse(p2, options));
 2854      return parse4(pattern, __spreadProps(__spreadValues({}, options), { fastpaths: false }));
 2855    };
 2856    picomatch.scan = (input, options) => scan(input, options);
 2857    picomatch.compileRe = (state, options, returnOutput = false, returnState = false) => {
 2858      if (returnOutput === true) {
 2859        return state.output;
 2860      }
 2861      const opts = options || {};
 2862      const prepend = opts.contains ? "" : "^";
 2863      const append = opts.contains ? "" : "$";
 2864      let source = `${prepend}(?:${state.output})${append}`;
 2865      if (state && state.negated === true) {
 2866        source = `^(?!${source}).*$`;
 2867      }
 2868      const regex = picomatch.toRegex(source, options);
 2869      if (returnState === true) {
 2870        regex.state = state;
 2871      }
 2872      return regex;
 2873    };
 2874    picomatch.makeRe = (input, options = {}, returnOutput = false, returnState = false) => {
 2875      if (!input || typeof input !== "string") {
 2876        throw new TypeError("Expected a non-empty string");
 2877      }
 2878      let parsed = { negated: false, fastpaths: true };
 2879      if (options.fastpaths !== false && (input[0] === "." || input[0] === "*")) {
 2880        parsed.output = parse4.fastpaths(input, options);
 2881      }
 2882      if (!parsed.output) {
 2883        parsed = parse4(input, options);
 2884      }
 2885      return picomatch.compileRe(parsed, options, returnOutput, returnState);
 2886    };
 2887    picomatch.toRegex = (source, options) => {
 2888      try {
 2889        const opts = options || {};
 2890        return new RegExp(source, opts.flags || (opts.nocase ? "i" : ""));
 2891      } catch (err) {
 2892        if (options && options.debug === true) throw err;
 2893        return /$^/;
 2894      }
 2895    };
 2896    picomatch.constants = constants;
 2897    module2.exports = picomatch;
 2898  }
 2899});
 2900
 2901// node_modules/picomatch/index.js
 2902var require_picomatch2 = __commonJS({
 2903  "node_modules/picomatch/index.js"(exports2, module2) {
 2904    "use strict";
 2905    module2.exports = require_picomatch();
 2906  }
 2907});
 2908
 2909// node_modules/micromatch/index.js
 2910var require_micromatch = __commonJS({
 2911  "node_modules/micromatch/index.js"(exports2, module2) {
 2912    "use strict";
 2913    var util = require("util");
 2914    var braces = require_braces();
 2915    var picomatch = require_picomatch2();
 2916    var utils = require_utils2();
 2917    var isEmptyString = (v2) => v2 === "" || v2 === "./";
 2918    var hasBraces = (v2) => {
 2919      const index = v2.indexOf("{");
 2920      return index > -1 && v2.indexOf("}", index) > -1;
 2921    };
 2922    var micromatch = (list, patterns, options) => {
 2923      patterns = [].concat(patterns);
 2924      list = [].concat(list);
 2925      let omit = /* @__PURE__ */ new Set();
 2926      let keep = /* @__PURE__ */ new Set();
 2927      let items = /* @__PURE__ */ new Set();
 2928      let negatives = 0;
 2929      let onResult = (state) => {
 2930        items.add(state.output);
 2931        if (options && options.onResult) {
 2932          options.onResult(state);
 2933        }
 2934      };
 2935      for (let i = 0; i < patterns.length; i++) {
 2936        let isMatch = picomatch(String(patterns[i]), __spreadProps(__spreadValues({}, options), { onResult }), true);
 2937        let negated = isMatch.state.negated || isMatch.state.negatedExtglob;
 2938        if (negated) negatives++;
 2939        for (let item of list) {
 2940          let matched = isMatch(item, true);
 2941          let match = negated ? !matched.isMatch : matched.isMatch;
 2942          if (!match) continue;
 2943          if (negated) {
 2944            omit.add(matched.output);
 2945          } else {
 2946            omit.delete(matched.output);
 2947            keep.add(matched.output);
 2948          }
 2949        }
 2950      }
 2951      let result = negatives === patterns.length ? [...items] : [...keep];
 2952      let matches = result.filter((item) => !omit.has(item));
 2953      if (options && matches.length === 0) {
 2954        if (options.failglob === true) {
 2955          throw new Error(`No matches found for "${patterns.join(", ")}"`);
 2956        }
 2957        if (options.nonull === true || options.nullglob === true) {
 2958          return options.unescape ? patterns.map((p2) => p2.replace(/\\/g, "")) : patterns;
 2959        }
 2960      }
 2961      return matches;
 2962    };
 2963    micromatch.match = micromatch;
 2964    micromatch.matcher = (pattern, options) => picomatch(pattern, options);
 2965    micromatch.isMatch = (str, patterns, options) => picomatch(patterns, options)(str);
 2966    micromatch.any = micromatch.isMatch;
 2967    micromatch.not = (list, patterns, options = {}) => {
 2968      patterns = [].concat(patterns).map(String);
 2969      let result = /* @__PURE__ */ new Set();
 2970      let items = [];
 2971      let onResult = (state) => {
 2972        if (options.onResult) options.onResult(state);
 2973        items.push(state.output);
 2974      };
 2975      let matches = new Set(micromatch(list, patterns, __spreadProps(__spreadValues({}, options), { onResult })));
 2976      for (let item of items) {
 2977        if (!matches.has(item)) {
 2978          result.add(item);
 2979        }
 2980      }
 2981      return [...result];
 2982    };
 2983    micromatch.contains = (str, pattern, options) => {
 2984      if (typeof str !== "string") {
 2985        throw new TypeError(`Expected a string: "${util.inspect(str)}"`);
 2986      }
 2987      if (Array.isArray(pattern)) {
 2988        return pattern.some((p2) => micromatch.contains(str, p2, options));
 2989      }
 2990      if (typeof pattern === "string") {
 2991        if (isEmptyString(str) || isEmptyString(pattern)) {
 2992          return false;
 2993        }
 2994        if (str.includes(pattern) || str.startsWith("./") && str.slice(2).includes(pattern)) {
 2995          return true;
 2996        }
 2997      }
 2998      return micromatch.isMatch(str, pattern, __spreadProps(__spreadValues({}, options), { contains: true }));
 2999    };
 3000    micromatch.matchKeys = (obj, patterns, options) => {
 3001      if (!utils.isObject(obj)) {
 3002        throw new TypeError("Expected the first argument to be an object");
 3003      }
 3004      let keys = micromatch(Object.keys(obj), patterns, options);
 3005      let res = {};
 3006      for (let key of keys) res[key] = obj[key];
 3007      return res;
 3008    };
 3009    micromatch.some = (list, patterns, options) => {
 3010      let items = [].concat(list);
 3011      for (let pattern of [].concat(patterns)) {
 3012        let isMatch = picomatch(String(pattern), options);
 3013        if (items.some((item) => isMatch(item))) {
 3014          return true;
 3015        }
 3016      }
 3017      return false;
 3018    };
 3019    micromatch.every = (list, patterns, options) => {
 3020      let items = [].concat(list);
 3021      for (let pattern of [].concat(patterns)) {
 3022        let isMatch = picomatch(String(pattern), options);
 3023        if (!items.every((item) => isMatch(item))) {
 3024          return false;
 3025        }
 3026      }
 3027      return true;
 3028    };
 3029    micromatch.all = (str, patterns, options) => {
 3030      if (typeof str !== "string") {
 3031        throw new TypeError(`Expected a string: "${util.inspect(str)}"`);
 3032      }
 3033      return [].concat(patterns).every((p2) => picomatch(p2, options)(str));
 3034    };
 3035    micromatch.capture = (glob2, input, options) => {
 3036      let posix = utils.isWindows(options);
 3037      let regex = picomatch.makeRe(String(glob2), __spreadProps(__spreadValues({}, options), { capture: true }));
 3038      let match = regex.exec(posix ? utils.toPosixSlashes(input) : input);
 3039      if (match) {
 3040        return match.slice(1).map((v2) => v2 === void 0 ? "" : v2);
 3041      }
 3042    };
 3043    micromatch.makeRe = (...args) => picomatch.makeRe(...args);
 3044    micromatch.scan = (...args) => picomatch.scan(...args);
 3045    micromatch.parse = (patterns, options) => {
 3046      let res = [];
 3047      for (let pattern of [].concat(patterns || [])) {
 3048        for (let str of braces(String(pattern), options)) {
 3049          res.push(picomatch.parse(str, options));
 3050        }
 3051      }
 3052      return res;
 3053    };
 3054    micromatch.braces = (pattern, options) => {
 3055      if (typeof pattern !== "string") throw new TypeError("Expected a string");
 3056      if (options && options.nobrace === true || !hasBraces(pattern)) {
 3057        return [pattern];
 3058      }
 3059      return braces(pattern, options);
 3060    };
 3061    micromatch.braceExpand = (pattern, options) => {
 3062      if (typeof pattern !== "string") throw new TypeError("Expected a string");
 3063      return micromatch.braces(pattern, __spreadProps(__spreadValues({}, options), { expand: true }));
 3064    };
 3065    micromatch.hasBraces = hasBraces;
 3066    module2.exports = micromatch;
 3067  }
 3068});
 3069
 3070// node_modules/fast-glob/out/utils/pattern.js
 3071var require_pattern = __commonJS({
 3072  "node_modules/fast-glob/out/utils/pattern.js"(exports2) {
 3073    "use strict";
 3074    Object.defineProperty(exports2, "__esModule", { value: true });
 3075    exports2.isAbsolute = exports2.partitionAbsoluteAndRelative = exports2.removeDuplicateSlashes = exports2.matchAny = exports2.convertPatternsToRe = exports2.makeRe = exports2.getPatternParts = exports2.expandBraceExpansion = exports2.expandPatternsWithBraceExpansion = exports2.isAffectDepthOfReadingPattern = exports2.endsWithSlashGlobStar = exports2.hasGlobStar = exports2.getBaseDirectory = exports2.isPatternRelatedToParentDirectory = exports2.getPatternsOutsideCurrentDirectory = exports2.getPatternsInsideCurrentDirectory = exports2.getPositivePatterns = exports2.getNegativePatterns = exports2.isPositivePattern = exports2.isNegativePattern = exports2.convertToNegativePattern = exports2.convertToPositivePattern = exports2.isDynamicPattern = exports2.isStaticPattern = void 0;
 3076    var path5 = require("path");
 3077    var globParent = require_glob_parent();
 3078    var micromatch = require_micromatch();
 3079    var GLOBSTAR = "**";
 3080    var ESCAPE_SYMBOL = "\\";
 3081    var COMMON_GLOB_SYMBOLS_RE = /[*?]|^!/;
 3082    var REGEX_CHARACTER_CLASS_SYMBOLS_RE = /\[[^[]*]/;
 3083    var REGEX_GROUP_SYMBOLS_RE = /(?:^|[^!*+?@])\([^(]*\|[^|]*\)/;
 3084    var GLOB_EXTENSION_SYMBOLS_RE = /[!*+?@]\([^(]*\)/;
 3085    var BRACE_EXPANSION_SEPARATORS_RE = /,|\.\./;
 3086    var DOUBLE_SLASH_RE = /(?!^)\/{2,}/g;
 3087    function isStaticPattern(pattern, options = {}) {
 3088      return !isDynamicPattern2(pattern, options);
 3089    }
 3090    exports2.isStaticPattern = isStaticPattern;
 3091    function isDynamicPattern2(pattern, options = {}) {
 3092      if (pattern === "") {
 3093        return false;
 3094      }
 3095      if (options.caseSensitiveMatch === false || pattern.includes(ESCAPE_SYMBOL)) {
 3096        return true;
 3097      }
 3098      if (COMMON_GLOB_SYMBOLS_RE.test(pattern) || REGEX_CHARACTER_CLASS_SYMBOLS_RE.test(pattern) || REGEX_GROUP_SYMBOLS_RE.test(pattern)) {
 3099        return true;
 3100      }
 3101      if (options.extglob !== false && GLOB_EXTENSION_SYMBOLS_RE.test(pattern)) {
 3102        return true;
 3103      }
 3104      if (options.braceExpansion !== false && hasBraceExpansion(pattern)) {
 3105        return true;
 3106      }
 3107      return false;
 3108    }
 3109    exports2.isDynamicPattern = isDynamicPattern2;
 3110    function hasBraceExpansion(pattern) {
 3111      const openingBraceIndex = pattern.indexOf("{");
 3112      if (openingBraceIndex === -1) {
 3113        return false;
 3114      }
 3115      const closingBraceIndex = pattern.indexOf("}", openingBraceIndex + 1);
 3116      if (closingBraceIndex === -1) {
 3117        return false;
 3118      }
 3119      const braceContent = pattern.slice(openingBraceIndex, closingBraceIndex);
 3120      return BRACE_EXPANSION_SEPARATORS_RE.test(braceContent);
 3121    }
 3122    function convertToPositivePattern(pattern) {
 3123      return isNegativePattern2(pattern) ? pattern.slice(1) : pattern;
 3124    }
 3125    exports2.convertToPositivePattern = convertToPositivePattern;
 3126    function convertToNegativePattern(pattern) {
 3127      return "!" + pattern;
 3128    }
 3129    exports2.convertToNegativePattern = convertToNegativePattern;
 3130    function isNegativePattern2(pattern) {
 3131      return pattern.startsWith("!") && pattern[1] !== "(";
 3132    }
 3133    exports2.isNegativePattern = isNegativePattern2;
 3134    function isPositivePattern(pattern) {
 3135      return !isNegativePattern2(pattern);
 3136    }
 3137    exports2.isPositivePattern = isPositivePattern;
 3138    function getNegativePatterns(patterns) {
 3139      return patterns.filter(isNegativePattern2);
 3140    }
 3141    exports2.getNegativePatterns = getNegativePatterns;
 3142    function getPositivePatterns(patterns) {
 3143      return patterns.filter(isPositivePattern);
 3144    }
 3145    exports2.getPositivePatterns = getPositivePatterns;
 3146    function getPatternsInsideCurrentDirectory(patterns) {
 3147      return patterns.filter((pattern) => !isPatternRelatedToParentDirectory(pattern));
 3148    }
 3149    exports2.getPatternsInsideCurrentDirectory = getPatternsInsideCurrentDirectory;
 3150    function getPatternsOutsideCurrentDirectory(patterns) {
 3151      return patterns.filter(isPatternRelatedToParentDirectory);
 3152    }
 3153    exports2.getPatternsOutsideCurrentDirectory = getPatternsOutsideCurrentDirectory;
 3154    function isPatternRelatedToParentDirectory(pattern) {
 3155      return pattern.startsWith("..") || pattern.startsWith("./..");
 3156    }
 3157    exports2.isPatternRelatedToParentDirectory = isPatternRelatedToParentDirectory;
 3158    function getBaseDirectory(pattern) {
 3159      return globParent(pattern, { flipBackslashes: false });
 3160    }
 3161    exports2.getBaseDirectory = getBaseDirectory;
 3162    function hasGlobStar(pattern) {
 3163      return pattern.includes(GLOBSTAR);
 3164    }
 3165    exports2.hasGlobStar = hasGlobStar;
 3166    function endsWithSlashGlobStar(pattern) {
 3167      return pattern.endsWith("/" + GLOBSTAR);
 3168    }
 3169    exports2.endsWithSlashGlobStar = endsWithSlashGlobStar;
 3170    function isAffectDepthOfReadingPattern(pattern) {
 3171      const basename = path5.basename(pattern);
 3172      return endsWithSlashGlobStar(pattern) || isStaticPattern(basename);
 3173    }
 3174    exports2.isAffectDepthOfReadingPattern = isAffectDepthOfReadingPattern;
 3175    function expandPatternsWithBraceExpansion(patterns) {
 3176      return patterns.reduce((collection, pattern) => {
 3177        return collection.concat(expandBraceExpansion(pattern));
 3178      }, []);
 3179    }
 3180    exports2.expandPatternsWithBraceExpansion = expandPatternsWithBraceExpansion;
 3181    function expandBraceExpansion(pattern) {
 3182      const patterns = micromatch.braces(pattern, { expand: true, nodupes: true, keepEscaping: true });
 3183      patterns.sort((a, b) => a.length - b.length);
 3184      return patterns.filter((pattern2) => pattern2 !== "");
 3185    }
 3186    exports2.expandBraceExpansion = expandBraceExpansion;
 3187    function getPatternParts(pattern, options) {
 3188      let { parts } = micromatch.scan(pattern, Object.assign(Object.assign({}, options), { parts: true }));
 3189      if (parts.length === 0) {
 3190        parts = [pattern];
 3191      }
 3192      if (parts[0].startsWith("/")) {
 3193        parts[0] = parts[0].slice(1);
 3194        parts.unshift("");
 3195      }
 3196      return parts;
 3197    }
 3198    exports2.getPatternParts = getPatternParts;
 3199    function makeRe(pattern, options) {
 3200      return micromatch.makeRe(pattern, options);
 3201    }
 3202    exports2.makeRe = makeRe;
 3203    function convertPatternsToRe(patterns, options) {
 3204      return patterns.map((pattern) => makeRe(pattern, options));
 3205    }
 3206    exports2.convertPatternsToRe = convertPatternsToRe;
 3207    function matchAny(entry, patternsRe) {
 3208      return patternsRe.some((patternRe) => patternRe.test(entry));
 3209    }
 3210    exports2.matchAny = matchAny;
 3211    function removeDuplicateSlashes(pattern) {
 3212      return pattern.replace(DOUBLE_SLASH_RE, "/");
 3213    }
 3214    exports2.removeDuplicateSlashes = removeDuplicateSlashes;
 3215    function partitionAbsoluteAndRelative(patterns) {
 3216      const absolute = [];
 3217      const relative = [];
 3218      for (const pattern of patterns) {
 3219        if (isAbsolute(pattern)) {
 3220          absolute.push(pattern);
 3221        } else {
 3222          relative.push(pattern);
 3223        }
 3224      }
 3225      return [absolute, relative];
 3226    }
 3227    exports2.partitionAbsoluteAndRelative = partitionAbsoluteAndRelative;
 3228    function isAbsolute(pattern) {
 3229      return path5.isAbsolute(pattern);
 3230    }
 3231    exports2.isAbsolute = isAbsolute;
 3232  }
 3233});
 3234
 3235// node_modules/merge2/index.js
 3236var require_merge2 = __commonJS({
 3237  "node_modules/merge2/index.js"(exports2, module2) {
 3238    "use strict";
 3239    var Stream = require("stream");
 3240    var PassThrough = Stream.PassThrough;
 3241    var slice = Array.prototype.slice;
 3242    module2.exports = merge2;
 3243    function merge2() {
 3244      const streamsQueue = [];
 3245      const args = slice.call(arguments);
 3246      let merging = false;
 3247      let options = args[args.length - 1];
 3248      if (options && !Array.isArray(options) && options.pipe == null) {
 3249        args.pop();
 3250      } else {
 3251        options = {};
 3252      }
 3253      const doEnd = options.end !== false;
 3254      const doPipeError = options.pipeError === true;
 3255      if (options.objectMode == null) {
 3256        options.objectMode = true;
 3257      }
 3258      if (options.highWaterMark == null) {
 3259        options.highWaterMark = 64 * 1024;
 3260      }
 3261      const mergedStream = PassThrough(options);
 3262      function addStream() {
 3263        for (let i = 0, len = arguments.length; i < len; i++) {
 3264          streamsQueue.push(pauseStreams(arguments[i], options));
 3265        }
 3266        mergeStream();
 3267        return this;
 3268      }
 3269      function mergeStream() {
 3270        if (merging) {
 3271          return;
 3272        }
 3273        merging = true;
 3274        let streams = streamsQueue.shift();
 3275        if (!streams) {
 3276          process.nextTick(endStream2);
 3277          return;
 3278        }
 3279        if (!Array.isArray(streams)) {
 3280          streams = [streams];
 3281        }
 3282        let pipesCount = streams.length + 1;
 3283        function next() {
 3284          if (--pipesCount > 0) {
 3285            return;
 3286          }
 3287          merging = false;
 3288          mergeStream();
 3289        }
 3290        function pipe(stream) {
 3291          function onend() {
 3292            stream.removeListener("merge2UnpipeEnd", onend);
 3293            stream.removeListener("end", onend);
 3294            if (doPipeError) {
 3295              stream.removeListener("error", onerror);
 3296            }
 3297            next();
 3298          }
 3299          function onerror(err) {
 3300            mergedStream.emit("error", err);
 3301          }
 3302          if (stream._readableState.endEmitted) {
 3303            return next();
 3304          }
 3305          stream.on("merge2UnpipeEnd", onend);
 3306          stream.on("end", onend);
 3307          if (doPipeError) {
 3308            stream.on("error", onerror);
 3309          }
 3310          stream.pipe(mergedStream, { end: false });
 3311          stream.resume();
 3312        }
 3313        for (let i = 0; i < streams.length; i++) {
 3314          pipe(streams[i]);
 3315        }
 3316        next();
 3317      }
 3318      function endStream2() {
 3319        merging = false;
 3320        mergedStream.emit("queueDrain");
 3321        if (doEnd) {
 3322          mergedStream.end();
 3323        }
 3324      }
 3325      mergedStream.setMaxListeners(0);
 3326      mergedStream.add = addStream;
 3327      mergedStream.on("unpipe", function(stream) {
 3328        stream.emit("merge2UnpipeEnd");
 3329      });
 3330      if (args.length) {
 3331        addStream.apply(null, args);
 3332      }
 3333      return mergedStream;
 3334    }
 3335    function pauseStreams(streams, options) {
 3336      if (!Array.isArray(streams)) {
 3337        if (!streams._readableState && streams.pipe) {
 3338          streams = streams.pipe(PassThrough(options));
 3339        }
 3340        if (!streams._readableState || !streams.pause || !streams.pipe) {
 3341          throw new Error("Only readable stream can be merged.");
 3342        }
 3343        streams.pause();
 3344      } else {
 3345        for (let i = 0, len = streams.length; i < len; i++) {
 3346          streams[i] = pauseStreams(streams[i], options);
 3347        }
 3348      }
 3349      return streams;
 3350    }
 3351  }
 3352});
 3353
 3354// node_modules/fast-glob/out/utils/stream.js
 3355var require_stream = __commonJS({
 3356  "node_modules/fast-glob/out/utils/stream.js"(exports2) {
 3357    "use strict";
 3358    Object.defineProperty(exports2, "__esModule", { value: true });
 3359    exports2.merge = void 0;
 3360    var merge2 = require_merge2();
 3361    function merge3(streams) {
 3362      const mergedStream = merge2(streams);
 3363      streams.forEach((stream) => {
 3364        stream.once("error", (error) => mergedStream.emit("error", error));
 3365      });
 3366      mergedStream.once("close", () => propagateCloseEventToSources(streams));
 3367      mergedStream.once("end", () => propagateCloseEventToSources(streams));
 3368      return mergedStream;
 3369    }
 3370    exports2.merge = merge3;
 3371    function propagateCloseEventToSources(streams) {
 3372      streams.forEach((stream) => stream.emit("close"));
 3373    }
 3374  }
 3375});
 3376
 3377// node_modules/fast-glob/out/utils/string.js
 3378var require_string = __commonJS({
 3379  "node_modules/fast-glob/out/utils/string.js"(exports2) {
 3380    "use strict";
 3381    Object.defineProperty(exports2, "__esModule", { value: true });
 3382    exports2.isEmpty = exports2.isString = void 0;
 3383    function isString(input) {
 3384      return typeof input === "string";
 3385    }
 3386    exports2.isString = isString;
 3387    function isEmpty2(input) {
 3388      return input === "";
 3389    }
 3390    exports2.isEmpty = isEmpty2;
 3391  }
 3392});
 3393
 3394// node_modules/fast-glob/out/utils/index.js
 3395var require_utils3 = __commonJS({
 3396  "node_modules/fast-glob/out/utils/index.js"(exports2) {
 3397    "use strict";
 3398    Object.defineProperty(exports2, "__esModule", { value: true });
 3399    exports2.string = exports2.stream = exports2.pattern = exports2.path = exports2.fs = exports2.errno = exports2.array = void 0;
 3400    var array = require_array();
 3401    exports2.array = array;
 3402    var errno = require_errno();
 3403    exports2.errno = errno;
 3404    var fs6 = require_fs();
 3405    exports2.fs = fs6;
 3406    var path5 = require_path();
 3407    exports2.path = path5;
 3408    var pattern = require_pattern();
 3409    exports2.pattern = pattern;
 3410    var stream = require_stream();
 3411    exports2.stream = stream;
 3412    var string2 = require_string();
 3413    exports2.string = string2;
 3414  }
 3415});
 3416
 3417// node_modules/fast-glob/out/managers/tasks.js
 3418var require_tasks = __commonJS({
 3419  "node_modules/fast-glob/out/managers/tasks.js"(exports2) {
 3420    "use strict";
 3421    Object.defineProperty(exports2, "__esModule", { value: true });
 3422    exports2.convertPatternGroupToTask = exports2.convertPatternGroupsToTasks = exports2.groupPatternsByBaseDirectory = exports2.getNegativePatternsAsPositive = exports2.getPositivePatterns = exports2.convertPatternsToTasks = exports2.generate = void 0;
 3423    var utils = require_utils3();
 3424    function generate(input, settings) {
 3425      const patterns = processPatterns(input, settings);
 3426      const ignore = processPatterns(settings.ignore, settings);
 3427      const positivePatterns = getPositivePatterns(patterns);
 3428      const negativePatterns = getNegativePatternsAsPositive(patterns, ignore);
 3429      const staticPatterns = positivePatterns.filter((pattern) => utils.pattern.isStaticPattern(pattern, settings));
 3430      const dynamicPatterns = positivePatterns.filter((pattern) => utils.pattern.isDynamicPattern(pattern, settings));
 3431      const staticTasks = convertPatternsToTasks(
 3432        staticPatterns,
 3433        negativePatterns,
 3434        /* dynamic */
 3435        false
 3436      );
 3437      const dynamicTasks = convertPatternsToTasks(
 3438        dynamicPatterns,
 3439        negativePatterns,
 3440        /* dynamic */
 3441        true
 3442      );
 3443      return staticTasks.concat(dynamicTasks);
 3444    }
 3445    exports2.generate = generate;
 3446    function processPatterns(input, settings) {
 3447      let patterns = input;
 3448      if (settings.braceExpansion) {
 3449        patterns = utils.pattern.expandPatternsWithBraceExpansion(patterns);
 3450      }
 3451      if (settings.baseNameMatch) {
 3452        patterns = patterns.map((pattern) => pattern.includes("/") ? pattern : `**/${pattern}`);
 3453      }
 3454      return patterns.map((pattern) => utils.pattern.removeDuplicateSlashes(pattern));
 3455    }
 3456    function convertPatternsToTasks(positive, negative, dynamic) {
 3457      const tasks = [];
 3458      const patternsOutsideCurrentDirectory = utils.pattern.getPatternsOutsideCurrentDirectory(positive);
 3459      const patternsInsideCurrentDirectory = utils.pattern.getPatternsInsideCurrentDirectory(positive);
 3460      const outsideCurrentDirectoryGroup = groupPatternsByBaseDirectory(patternsOutsideCurrentDirectory);
 3461      const insideCurrentDirectoryGroup = groupPatternsByBaseDirectory(patternsInsideCurrentDirectory);
 3462      tasks.push(...convertPatternGroupsToTasks(outsideCurrentDirectoryGroup, negative, dynamic));
 3463      if ("." in insideCurrentDirectoryGroup) {
 3464        tasks.push(convertPatternGroupToTask(".", patternsInsideCurrentDirectory, negative, dynamic));
 3465      } else {
 3466        tasks.push(...convertPatternGroupsToTasks(insideCurrentDirectoryGroup, negative, dynamic));
 3467      }
 3468      return tasks;
 3469    }
 3470    exports2.convertPatternsToTasks = convertPatternsToTasks;
 3471    function getPositivePatterns(patterns) {
 3472      return utils.pattern.getPositivePatterns(patterns);
 3473    }
 3474    exports2.getPositivePatterns = getPositivePatterns;
 3475    function getNegativePatternsAsPositive(patterns, ignore) {
 3476      const negative = utils.pattern.getNegativePatterns(patterns).concat(ignore);
 3477      const positive = negative.map(utils.pattern.convertToPositivePattern);
 3478      return positive;
 3479    }
 3480    exports2.getNegativePatternsAsPositive = getNegativePatternsAsPositive;
 3481    function groupPatternsByBaseDirectory(patterns) {
 3482      const group = {};
 3483      return patterns.reduce((collection, pattern) => {
 3484        const base = utils.pattern.getBaseDirectory(pattern);
 3485        if (base in collection) {
 3486          collection[base].push(pattern);
 3487        } else {
 3488          collection[base] = [pattern];
 3489        }
 3490        return collection;
 3491      }, group);
 3492    }
 3493    exports2.groupPatternsByBaseDirectory = groupPatternsByBaseDirectory;
 3494    function convertPatternGroupsToTasks(positive, negative, dynamic) {
 3495      return Object.keys(positive).map((base) => {
 3496        return convertPatternGroupToTask(base, positive[base], negative, dynamic);
 3497      });
 3498    }
 3499    exports2.convertPatternGroupsToTasks = convertPatternGroupsToTasks;
 3500    function convertPatternGroupToTask(base, positive, negative, dynamic) {
 3501      return {
 3502        dynamic,
 3503        positive,
 3504        negative,
 3505        base,
 3506        patterns: [].concat(positive, negative.map(utils.pattern.convertToNegativePattern))
 3507      };
 3508    }
 3509    exports2.convertPatternGroupToTask = convertPatternGroupToTask;
 3510  }
 3511});
 3512
 3513// node_modules/@nodelib/fs.stat/out/providers/async.js
 3514var require_async = __commonJS({
 3515  "node_modules/@nodelib/fs.stat/out/providers/async.js"(exports2) {
 3516    "use strict";
 3517    Object.defineProperty(exports2, "__esModule", { value: true });
 3518    exports2.read = void 0;
 3519    function read(path5, settings, callback) {
 3520      settings.fs.lstat(path5, (lstatError, lstat) => {
 3521        if (lstatError !== null) {
 3522          callFailureCallback(callback, lstatError);
 3523          return;
 3524        }
 3525        if (!lstat.isSymbolicLink() || !settings.followSymbolicLink) {
 3526          callSuccessCallback(callback, lstat);
 3527          return;
 3528        }
 3529        settings.fs.stat(path5, (statError, stat) => {
 3530          if (statError !== null) {
 3531            if (settings.throwErrorOnBrokenSymbolicLink) {
 3532              callFailureCallback(callback, statError);
 3533              return;
 3534            }
 3535            callSuccessCallback(callback, lstat);
 3536            return;
 3537          }
 3538          if (settings.markSymbolicLink) {
 3539            stat.isSymbolicLink = () => true;
 3540          }
 3541          callSuccessCallback(callback, stat);
 3542        });
 3543      });
 3544    }
 3545    exports2.read = read;
 3546    function callFailureCallback(callback, error) {
 3547      callback(error);
 3548    }
 3549    function callSuccessCallback(callback, result) {
 3550      callback(null, result);
 3551    }
 3552  }
 3553});
 3554
 3555// node_modules/@nodelib/fs.stat/out/providers/sync.js
 3556var require_sync = __commonJS({
 3557  "node_modules/@nodelib/fs.stat/out/providers/sync.js"(exports2) {
 3558    "use strict";
 3559    Object.defineProperty(exports2, "__esModule", { value: true });
 3560    exports2.read = void 0;
 3561    function read(path5, settings) {
 3562      const lstat = settings.fs.lstatSync(path5);
 3563      if (!lstat.isSymbolicLink() || !settings.followSymbolicLink) {
 3564        return lstat;
 3565      }
 3566      try {
 3567        const stat = settings.fs.statSync(path5);
 3568        if (settings.markSymbolicLink) {
 3569          stat.isSymbolicLink = () => true;
 3570        }
 3571        return stat;
 3572      } catch (error) {
 3573        if (!settings.throwErrorOnBrokenSymbolicLink) {
 3574          return lstat;
 3575        }
 3576        throw error;
 3577      }
 3578    }
 3579    exports2.read = read;
 3580  }
 3581});
 3582
 3583// node_modules/@nodelib/fs.stat/out/adapters/fs.js
 3584var require_fs2 = __commonJS({
 3585  "node_modules/@nodelib/fs.stat/out/adapters/fs.js"(exports2) {
 3586    "use strict";
 3587    Object.defineProperty(exports2, "__esModule", { value: true });
 3588    exports2.createFileSystemAdapter = exports2.FILE_SYSTEM_ADAPTER = void 0;
 3589    var fs6 = require("fs");
 3590    exports2.FILE_SYSTEM_ADAPTER = {
 3591      lstat: fs6.lstat,
 3592      stat: fs6.stat,
 3593      lstatSync: fs6.lstatSync,
 3594      statSync: fs6.statSync
 3595    };
 3596    function createFileSystemAdapter(fsMethods) {
 3597      if (fsMethods === void 0) {
 3598        return exports2.FILE_SYSTEM_ADAPTER;
 3599      }
 3600      return Object.assign(Object.assign({}, exports2.FILE_SYSTEM_ADAPTER), fsMethods);
 3601    }
 3602    exports2.createFileSystemAdapter = createFileSystemAdapter;
 3603  }
 3604});
 3605
 3606// node_modules/@nodelib/fs.stat/out/settings.js
 3607var require_settings = __commonJS({
 3608  "node_modules/@nodelib/fs.stat/out/settings.js"(exports2) {
 3609    "use strict";
 3610    Object.defineProperty(exports2, "__esModule", { value: true });
 3611    var fs6 = require_fs2();
 3612    var Settings = class {
 3613      constructor(_options = {}) {
 3614        this._options = _options;
 3615        this.followSymbolicLink = this._getValue(this._options.followSymbolicLink, true);
 3616        this.fs = fs6.createFileSystemAdapter(this._options.fs);
 3617        this.markSymbolicLink = this._getValue(this._options.markSymbolicLink, false);
 3618        this.throwErrorOnBrokenSymbolicLink = this._getValue(this._options.throwErrorOnBrokenSymbolicLink, true);
 3619      }
 3620      _getValue(option, value) {
 3621        return option !== null && option !== void 0 ? option : value;
 3622      }
 3623    };
 3624    exports2.default = Settings;
 3625  }
 3626});
 3627
 3628// node_modules/@nodelib/fs.stat/out/index.js
 3629var require_out = __commonJS({
 3630  "node_modules/@nodelib/fs.stat/out/index.js"(exports2) {
 3631    "use strict";
 3632    Object.defineProperty(exports2, "__esModule", { value: true });
 3633    exports2.statSync = exports2.stat = exports2.Settings = void 0;
 3634    var async = require_async();
 3635    var sync = require_sync();
 3636    var settings_1 = require_settings();
 3637    exports2.Settings = settings_1.default;
 3638    function stat(path5, optionsOrSettingsOrCallback, callback) {
 3639      if (typeof optionsOrSettingsOrCallback === "function") {
 3640        async.read(path5, getSettings(), optionsOrSettingsOrCallback);
 3641        return;
 3642      }
 3643      async.read(path5, getSettings(optionsOrSettingsOrCallback), callback);
 3644    }
 3645    exports2.stat = stat;
 3646    function statSync(path5, optionsOrSettings) {
 3647      const settings = getSettings(optionsOrSettings);
 3648      return sync.read(path5, settings);
 3649    }
 3650    exports2.statSync = statSync;
 3651    function getSettings(settingsOrOptions = {}) {
 3652      if (settingsOrOptions instanceof settings_1.default) {
 3653        return settingsOrOptions;
 3654      }
 3655      return new settings_1.default(settingsOrOptions);
 3656    }
 3657  }
 3658});
 3659
 3660// node_modules/queue-microtask/index.js
 3661var require_queue_microtask = __commonJS({
 3662  "node_modules/queue-microtask/index.js"(exports2, module2) {
 3663    "use strict";
 3664    var promise;
 3665    module2.exports = typeof queueMicrotask === "function" ? queueMicrotask.bind(typeof window !== "undefined" ? window : global) : (cb) => (promise || (promise = Promise.resolve())).then(cb).catch((err) => setTimeout(() => {
 3666      throw err;
 3667    }, 0));
 3668  }
 3669});
 3670
 3671// node_modules/run-parallel/index.js
 3672var require_run_parallel = __commonJS({
 3673  "node_modules/run-parallel/index.js"(exports2, module2) {
 3674    "use strict";
 3675    module2.exports = runParallel;
 3676    var queueMicrotask2 = require_queue_microtask();
 3677    function runParallel(tasks, cb) {
 3678      let results, pending, keys;
 3679      let isSync = true;
 3680      if (Array.isArray(tasks)) {
 3681        results = [];
 3682        pending = tasks.length;
 3683      } else {
 3684        keys = Object.keys(tasks);
 3685        results = {};
 3686        pending = keys.length;
 3687      }
 3688      function done(err) {
 3689        function end() {
 3690          if (cb) cb(err, results);
 3691          cb = null;
 3692        }
 3693        if (isSync) queueMicrotask2(end);
 3694        else end();
 3695      }
 3696      function each(i, err, result) {
 3697        results[i] = result;
 3698        if (--pending === 0 || err) {
 3699          done(err);
 3700        }
 3701      }
 3702      if (!pending) {
 3703        done(null);
 3704      } else if (keys) {
 3705        keys.forEach(function(key) {
 3706          tasks[key](function(err, result) {
 3707            each(key, err, result);
 3708          });
 3709        });
 3710      } else {
 3711        tasks.forEach(function(task, i) {
 3712          task(function(err, result) {
 3713            each(i, err, result);
 3714          });
 3715        });
 3716      }
 3717      isSync = false;
 3718    }
 3719  }
 3720});
 3721
 3722// node_modules/@nodelib/fs.scandir/out/constants.js
 3723var require_constants3 = __commonJS({
 3724  "node_modules/@nodelib/fs.scandir/out/constants.js"(exports2) {
 3725    "use strict";
 3726    Object.defineProperty(exports2, "__esModule", { value: true });
 3727    exports2.IS_SUPPORT_READDIR_WITH_FILE_TYPES = void 0;
 3728    var NODE_PROCESS_VERSION_PARTS = process.versions.node.split(".");
 3729    if (NODE_PROCESS_VERSION_PARTS[0] === void 0 || NODE_PROCESS_VERSION_PARTS[1] === void 0) {
 3730      throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`);
 3731    }
 3732    var MAJOR_VERSION = Number.parseInt(NODE_PROCESS_VERSION_PARTS[0], 10);
 3733    var MINOR_VERSION = Number.parseInt(NODE_PROCESS_VERSION_PARTS[1], 10);
 3734    var SUPPORTED_MAJOR_VERSION = 10;
 3735    var SUPPORTED_MINOR_VERSION = 10;
 3736    var IS_MATCHED_BY_MAJOR = MAJOR_VERSION > SUPPORTED_MAJOR_VERSION;
 3737    var IS_MATCHED_BY_MAJOR_AND_MINOR = MAJOR_VERSION === SUPPORTED_MAJOR_VERSION && MINOR_VERSION >= SUPPORTED_MINOR_VERSION;
 3738    exports2.IS_SUPPORT_READDIR_WITH_FILE_TYPES = IS_MATCHED_BY_MAJOR || IS_MATCHED_BY_MAJOR_AND_MINOR;
 3739  }
 3740});
 3741
 3742// node_modules/@nodelib/fs.scandir/out/utils/fs.js
 3743var require_fs3 = __commonJS({
 3744  "node_modules/@nodelib/fs.scandir/out/utils/fs.js"(exports2) {
 3745    "use strict";
 3746    Object.defineProperty(exports2, "__esModule", { value: true });
 3747    exports2.createDirentFromStats = void 0;
 3748    var DirentFromStats = class {
 3749      constructor(name, stats) {
 3750        this.name = name;
 3751        this.isBlockDevice = stats.isBlockDevice.bind(stats);
 3752        this.isCharacterDevice = stats.isCharacterDevice.bind(stats);
 3753        this.isDirectory = stats.isDirectory.bind(stats);
 3754        this.isFIFO = stats.isFIFO.bind(stats);
 3755        this.isFile = stats.isFile.bind(stats);
 3756        this.isSocket = stats.isSocket.bind(stats);
 3757        this.isSymbolicLink = stats.isSymbolicLink.bind(stats);
 3758      }
 3759    };
 3760    function createDirentFromStats(name, stats) {
 3761      return new DirentFromStats(name, stats);
 3762    }
 3763    exports2.createDirentFromStats = createDirentFromStats;
 3764  }
 3765});
 3766
 3767// node_modules/@nodelib/fs.scandir/out/utils/index.js
 3768var require_utils4 = __commonJS({
 3769  "node_modules/@nodelib/fs.scandir/out/utils/index.js"(exports2) {
 3770    "use strict";
 3771    Object.defineProperty(exports2, "__esModule", { value: true });
 3772    exports2.fs = void 0;
 3773    var fs6 = require_fs3();
 3774    exports2.fs = fs6;
 3775  }
 3776});
 3777
 3778// node_modules/@nodelib/fs.scandir/out/providers/common.js
 3779var require_common = __commonJS({
 3780  "node_modules/@nodelib/fs.scandir/out/providers/common.js"(exports2) {
 3781    "use strict";
 3782    Object.defineProperty(exports2, "__esModule", { value: true });
 3783    exports2.joinPathSegments = void 0;
 3784    function joinPathSegments(a, b, separator) {
 3785      if (a.endsWith(separator)) {
 3786        return a + b;
 3787      }
 3788      return a + separator + b;
 3789    }
 3790    exports2.joinPathSegments = joinPathSegments;
 3791  }
 3792});
 3793
 3794// node_modules/@nodelib/fs.scandir/out/providers/async.js
 3795var require_async2 = __commonJS({
 3796  "node_modules/@nodelib/fs.scandir/out/providers/async.js"(exports2) {
 3797    "use strict";
 3798    Object.defineProperty(exports2, "__esModule", { value: true });
 3799    exports2.readdir = exports2.readdirWithFileTypes = exports2.read = void 0;
 3800    var fsStat = require_out();
 3801    var rpl = require_run_parallel();
 3802    var constants_1 = require_constants3();
 3803    var utils = require_utils4();
 3804    var common = require_common();
 3805    function read(directory, settings, callback) {
 3806      if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
 3807        readdirWithFileTypes(directory, settings, callback);
 3808        return;
 3809      }
 3810      readdir(directory, settings, callback);
 3811    }
 3812    exports2.read = read;
 3813    function readdirWithFileTypes(directory, settings, callback) {
 3814      settings.fs.readdir(directory, { withFileTypes: true }, (readdirError, dirents) => {
 3815        if (readdirError !== null) {
 3816          callFailureCallback(callback, readdirError);
 3817          return;
 3818        }
 3819        const entries = dirents.map((dirent) => ({
 3820          dirent,
 3821          name: dirent.name,
 3822          path: common.joinPathSegments(directory, dirent.name, settings.pathSegmentSeparator)
 3823        }));
 3824        if (!settings.followSymbolicLinks) {
 3825          callSuccessCallback(callback, entries);
 3826          return;
 3827        }
 3828        const tasks = entries.map((entry) => makeRplTaskEntry(entry, settings));
 3829        rpl(tasks, (rplError, rplEntries) => {
 3830          if (rplError !== null) {
 3831            callFailureCallback(callback, rplError);
 3832            return;
 3833          }
 3834          callSuccessCallback(callback, rplEntries);
 3835        });
 3836      });
 3837    }
 3838    exports2.readdirWithFileTypes = readdirWithFileTypes;
 3839    function makeRplTaskEntry(entry, settings) {
 3840      return (done) => {
 3841        if (!entry.dirent.isSymbolicLink()) {
 3842          done(null, entry);
 3843          return;
 3844        }
 3845        settings.fs.stat(entry.path, (statError, stats) => {
 3846          if (statError !== null) {
 3847            if (settings.throwErrorOnBrokenSymbolicLink) {
 3848              done(statError);
 3849              return;
 3850            }
 3851            done(null, entry);
 3852            return;
 3853          }
 3854          entry.dirent = utils.fs.createDirentFromStats(entry.name, stats);
 3855          done(null, entry);
 3856        });
 3857      };
 3858    }
 3859    function readdir(directory, settings, callback) {
 3860      settings.fs.readdir(directory, (readdirError, names) => {
 3861        if (readdirError !== null) {
 3862          callFailureCallback(callback, readdirError);
 3863          return;
 3864        }
 3865        const tasks = names.map((name) => {
 3866          const path5 = common.joinPathSegments(directory, name, settings.pathSegmentSeparator);
 3867          return (done) => {
 3868            fsStat.stat(path5, settings.fsStatSettings, (error, stats) => {
 3869              if (error !== null) {
 3870                done(error);
 3871                return;
 3872              }
 3873              const entry = {
 3874                name,
 3875                path: path5,
 3876                dirent: utils.fs.createDirentFromStats(name, stats)
 3877              };
 3878              if (settings.stats) {
 3879                entry.stats = stats;
 3880              }
 3881              done(null, entry);
 3882            });
 3883          };
 3884        });
 3885        rpl(tasks, (rplError, entries) => {
 3886          if (rplError !== null) {
 3887            callFailureCallback(callback, rplError);
 3888            return;
 3889          }
 3890          callSuccessCallback(callback, entries);
 3891        });
 3892      });
 3893    }
 3894    exports2.readdir = readdir;
 3895    function callFailureCallback(callback, error) {
 3896      callback(error);
 3897    }
 3898    function callSuccessCallback(callback, result) {
 3899      callback(null, result);
 3900    }
 3901  }
 3902});
 3903
 3904// node_modules/@nodelib/fs.scandir/out/providers/sync.js
 3905var require_sync2 = __commonJS({
 3906  "node_modules/@nodelib/fs.scandir/out/providers/sync.js"(exports2) {
 3907    "use strict";
 3908    Object.defineProperty(exports2, "__esModule", { value: true });
 3909    exports2.readdir = exports2.readdirWithFileTypes = exports2.read = void 0;
 3910    var fsStat = require_out();
 3911    var constants_1 = require_constants3();
 3912    var utils = require_utils4();
 3913    var common = require_common();
 3914    function read(directory, settings) {
 3915      if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
 3916        return readdirWithFileTypes(directory, settings);
 3917      }
 3918      return readdir(directory, settings);
 3919    }
 3920    exports2.read = read;
 3921    function readdirWithFileTypes(directory, settings) {
 3922      const dirents = settings.fs.readdirSync(directory, { withFileTypes: true });
 3923      return dirents.map((dirent) => {
 3924        const entry = {
 3925          dirent,
 3926          name: dirent.name,
 3927          path: common.joinPathSegments(directory, dirent.name, settings.pathSegmentSeparator)
 3928        };
 3929        if (entry.dirent.isSymbolicLink() && settings.followSymbolicLinks) {
 3930          try {
 3931            const stats = settings.fs.statSync(entry.path);
 3932            entry.dirent = utils.fs.createDirentFromStats(entry.name, stats);
 3933          } catch (error) {
 3934            if (settings.throwErrorOnBrokenSymbolicLink) {
 3935              throw error;
 3936            }
 3937          }
 3938        }
 3939        return entry;
 3940      });
 3941    }
 3942    exports2.readdirWithFileTypes = readdirWithFileTypes;
 3943    function readdir(directory, settings) {
 3944      const names = settings.fs.readdirSync(directory);
 3945      return names.map((name) => {
 3946        const entryPath = common.joinPathSegments(directory, name, settings.pathSegmentSeparator);
 3947        const stats = fsStat.statSync(entryPath, settings.fsStatSettings);
 3948        const entry = {
 3949          name,
 3950          path: entryPath,
 3951          dirent: utils.fs.createDirentFromStats(name, stats)
 3952        };
 3953        if (settings.stats) {
 3954          entry.stats = stats;
 3955        }
 3956        return entry;
 3957      });
 3958    }
 3959    exports2.readdir = readdir;
 3960  }
 3961});
 3962
 3963// node_modules/@nodelib/fs.scandir/out/adapters/fs.js
 3964var require_fs4 = __commonJS({
 3965  "node_modules/@nodelib/fs.scandir/out/adapters/fs.js"(exports2) {
 3966    "use strict";
 3967    Object.defineProperty(exports2, "__esModule", { value: true });
 3968    exports2.createFileSystemAdapter = exports2.FILE_SYSTEM_ADAPTER = void 0;
 3969    var fs6 = require("fs");
 3970    exports2.FILE_SYSTEM_ADAPTER = {
 3971      lstat: fs6.lstat,
 3972      stat: fs6.stat,
 3973      lstatSync: fs6.lstatSync,
 3974      statSync: fs6.statSync,
 3975      readdir: fs6.readdir,
 3976      readdirSync: fs6.readdirSync
 3977    };
 3978    function createFileSystemAdapter(fsMethods) {
 3979      if (fsMethods === void 0) {
 3980        return exports2.FILE_SYSTEM_ADAPTER;
 3981      }
 3982      return Object.assign(Object.assign({}, exports2.FILE_SYSTEM_ADAPTER), fsMethods);
 3983    }
 3984    exports2.createFileSystemAdapter = createFileSystemAdapter;
 3985  }
 3986});
 3987
 3988// node_modules/@nodelib/fs.scandir/out/settings.js
 3989var require_settings2 = __commonJS({
 3990  "node_modules/@nodelib/fs.scandir/out/settings.js"(exports2) {
 3991    "use strict";
 3992    Object.defineProperty(exports2, "__esModule", { value: true });
 3993    var path5 = require("path");
 3994    var fsStat = require_out();
 3995    var fs6 = require_fs4();
 3996    var Settings = class {
 3997      constructor(_options = {}) {
 3998        this._options = _options;
 3999        this.followSymbolicLinks = this._getValue(this._options.followSymbolicLinks, false);
 4000        this.fs = fs6.createFileSystemAdapter(this._options.fs);
 4001        this.pathSegmentSeparator = this._getValue(this._options.pathSegmentSeparator, path5.sep);
 4002        this.stats = this._getValue(this._options.stats, false);
 4003        this.throwErrorOnBrokenSymbolicLink = this._getValue(this._options.throwErrorOnBrokenSymbolicLink, true);
 4004        this.fsStatSettings = new fsStat.Settings({
 4005          followSymbolicLink: this.followSymbolicLinks,
 4006          fs: this.fs,
 4007          throwErrorOnBrokenSymbolicLink: this.throwErrorOnBrokenSymbolicLink
 4008        });
 4009      }
 4010      _getValue(option, value) {
 4011        return option !== null && option !== void 0 ? option : value;
 4012      }
 4013    };
 4014    exports2.default = Settings;
 4015  }
 4016});
 4017
 4018// node_modules/@nodelib/fs.scandir/out/index.js
 4019var require_out2 = __commonJS({
 4020  "node_modules/@nodelib/fs.scandir/out/index.js"(exports2) {
 4021    "use strict";
 4022    Object.defineProperty(exports2, "__esModule", { value: true });
 4023    exports2.Settings = exports2.scandirSync = exports2.scandir = void 0;
 4024    var async = require_async2();
 4025    var sync = require_sync2();
 4026    var settings_1 = require_settings2();
 4027    exports2.Settings = settings_1.default;
 4028    function scandir(path5, optionsOrSettingsOrCallback, callback) {
 4029      if (typeof optionsOrSettingsOrCallback === "function") {
 4030        async.read(path5, getSettings(), optionsOrSettingsOrCallback);
 4031        return;
 4032      }
 4033      async.read(path5, getSettings(optionsOrSettingsOrCallback), callback);
 4034    }
 4035    exports2.scandir = scandir;
 4036    function scandirSync(path5, optionsOrSettings) {
 4037      const settings = getSettings(optionsOrSettings);
 4038      return sync.read(path5, settings);
 4039    }
 4040    exports2.scandirSync = scandirSync;
 4041    function getSettings(settingsOrOptions = {}) {
 4042      if (settingsOrOptions instanceof settings_1.default) {
 4043        return settingsOrOptions;
 4044      }
 4045      return new settings_1.default(settingsOrOptions);
 4046    }
 4047  }
 4048});
 4049
 4050// node_modules/reusify/reusify.js
 4051var require_reusify = __commonJS({
 4052  "node_modules/reusify/reusify.js"(exports2, module2) {
 4053    "use strict";
 4054    function reusify(Constructor) {
 4055      var head = new Constructor();
 4056      var tail = head;
 4057      function get() {
 4058        var current = head;
 4059        if (current.next) {
 4060          head = current.next;
 4061        } else {
 4062          head = new Constructor();
 4063          tail = head;
 4064        }
 4065        current.next = null;
 4066        return current;
 4067      }
 4068      function release(obj) {
 4069        tail.next = obj;
 4070        tail = obj;
 4071      }
 4072      return {
 4073        get,
 4074        release
 4075      };
 4076    }
 4077    module2.exports = reusify;
 4078  }
 4079});
 4080
 4081// node_modules/fastq/queue.js
 4082var require_queue = __commonJS({
 4083  "node_modules/fastq/queue.js"(exports2, module2) {
 4084    "use strict";
 4085    var reusify = require_reusify();
 4086    function fastqueue(context, worker, _concurrency) {
 4087      if (typeof context === "function") {
 4088        _concurrency = worker;
 4089        worker = context;
 4090        context = null;
 4091      }
 4092      if (!(_concurrency >= 1)) {
 4093        throw new Error("fastqueue concurrency must be equal to or greater than 1");
 4094      }
 4095      var cache = reusify(Task);
 4096      var queueHead = null;
 4097      var queueTail = null;
 4098      var _running = 0;
 4099      var errorHandler = null;
 4100      var self2 = {
 4101        push,
 4102        drain: noop2,
 4103        saturated: noop2,
 4104        pause,
 4105        paused: false,
 4106        get concurrency() {
 4107          return _concurrency;
 4108        },
 4109        set concurrency(value) {
 4110          if (!(value >= 1)) {
 4111            throw new Error("fastqueue concurrency must be equal to or greater than 1");
 4112          }
 4113          _concurrency = value;
 4114          if (self2.paused) return;
 4115          for (; queueHead && _running < _concurrency; ) {
 4116            _running++;
 4117            release();
 4118          }
 4119        },
 4120        running,
 4121        resume,
 4122        idle,
 4123        length,
 4124        getQueue,
 4125        unshift,
 4126        empty: noop2,
 4127        kill,
 4128        killAndDrain,
 4129        error
 4130      };
 4131      return self2;
 4132      function running() {
 4133        return _running;
 4134      }
 4135      function pause() {
 4136        self2.paused = true;
 4137      }
 4138      function length() {
 4139        var current = queueHead;
 4140        var counter = 0;
 4141        while (current) {
 4142          current = current.next;
 4143          counter++;
 4144        }
 4145        return counter;
 4146      }
 4147      function getQueue() {
 4148        var current = queueHead;
 4149        var tasks = [];
 4150        while (current) {
 4151          tasks.push(current.value);
 4152          current = current.next;
 4153        }
 4154        return tasks;
 4155      }
 4156      function resume() {
 4157        if (!self2.paused) return;
 4158        self2.paused = false;
 4159        if (queueHead === null) {
 4160          _running++;
 4161          release();
 4162          return;
 4163        }
 4164        for (; queueHead && _running < _concurrency; ) {
 4165          _running++;
 4166          release();
 4167        }
 4168      }
 4169      function idle() {
 4170        return _running === 0 && self2.length() === 0;
 4171      }
 4172      function push(value, done) {
 4173        var current = cache.get();
 4174        current.context = context;
 4175        current.release = release;
 4176        current.value = value;
 4177        current.callback = done || noop2;
 4178        current.errorHandler = errorHandler;
 4179        if (_running >= _concurrency || self2.paused) {
 4180          if (queueTail) {
 4181            queueTail.next = current;
 4182            queueTail = current;
 4183          } else {
 4184            queueHead = current;
 4185            queueTail = current;
 4186            self2.saturated();
 4187          }
 4188        } else {
 4189          _running++;
 4190          worker.call(context, current.value, current.worked);
 4191        }
 4192      }
 4193      function unshift(value, done) {
 4194        var current = cache.get();
 4195        current.context = context;
 4196        current.release = release;
 4197        current.value = value;
 4198        current.callback = done || noop2;
 4199        current.errorHandler = errorHandler;
 4200        if (_running >= _concurrency || self2.paused) {
 4201          if (queueHead) {
 4202            current.next = queueHead;
 4203            queueHead = current;
 4204          } else {
 4205            queueHead = current;
 4206            queueTail = current;
 4207            self2.saturated();
 4208          }
 4209        } else {
 4210          _running++;
 4211          worker.call(context, current.value, current.worked);
 4212        }
 4213      }
 4214      function release(holder) {
 4215        if (holder) {
 4216          cache.release(holder);
 4217        }
 4218        var next = queueHead;
 4219        if (next && _running <= _concurrency) {
 4220          if (!self2.paused) {
 4221            if (queueTail === queueHead) {
 4222              queueTail = null;
 4223            }
 4224            queueHead = next.next;
 4225            next.next = null;
 4226            worker.call(context, next.value, next.worked);
 4227            if (queueTail === null) {
 4228              self2.empty();
 4229            }
 4230          } else {
 4231            _running--;
 4232          }
 4233        } else if (--_running === 0) {
 4234          self2.drain();
 4235        }
 4236      }
 4237      function kill() {
 4238        queueHead = null;
 4239        queueTail = null;
 4240        self2.drain = noop2;
 4241      }
 4242      function killAndDrain() {
 4243        queueHead = null;
 4244        queueTail = null;
 4245        self2.drain();
 4246        self2.drain = noop2;
 4247      }
 4248      function error(handler) {
 4249        errorHandler = handler;
 4250      }
 4251    }
 4252    function noop2() {
 4253    }
 4254    function Task() {
 4255      this.value = null;
 4256      this.callback = noop2;
 4257      this.next = null;
 4258      this.release = noop2;
 4259      this.context = null;
 4260      this.errorHandler = null;
 4261      var self2 = this;
 4262      this.worked = function worked(err, result) {
 4263        var callback = self2.callback;
 4264        var errorHandler = self2.errorHandler;
 4265        var val = self2.value;
 4266        self2.value = null;
 4267        self2.callback = noop2;
 4268        if (self2.errorHandler) {
 4269          errorHandler(err, val);
 4270        }
 4271        callback.call(self2.context, err, result);
 4272        self2.release(self2);
 4273      };
 4274    }
 4275    function queueAsPromised(context, worker, _concurrency) {
 4276      if (typeof context === "function") {
 4277        _concurrency = worker;
 4278        worker = context;
 4279        context = null;
 4280      }
 4281      function asyncWrapper(arg, cb) {
 4282        worker.call(this, arg).then(function(res) {
 4283          cb(null, res);
 4284        }, cb);
 4285      }
 4286      var queue = fastqueue(context, asyncWrapper, _concurrency);
 4287      var pushCb = queue.push;
 4288      var unshiftCb = queue.unshift;
 4289      queue.push = push;
 4290      queue.unshift = unshift;
 4291      queue.drained = drained;
 4292      return queue;
 4293      function push(value) {
 4294        var p2 = new Promise(function(resolve, reject) {
 4295          pushCb(value, function(err, result) {
 4296            if (err) {
 4297              reject(err);
 4298              return;
 4299            }
 4300            resolve(result);
 4301          });
 4302        });
 4303        p2.catch(noop2);
 4304        return p2;
 4305      }
 4306      function unshift(value) {
 4307        var p2 = new Promise(function(resolve, reject) {
 4308          unshiftCb(value, function(err, result) {
 4309            if (err) {
 4310              reject(err);
 4311              return;
 4312            }
 4313            resolve(result);
 4314          });
 4315        });
 4316        p2.catch(noop2);
 4317        return p2;
 4318      }
 4319      function drained() {
 4320        var p2 = new Promise(function(resolve) {
 4321          process.nextTick(function() {
 4322            if (queue.idle()) {
 4323              resolve();
 4324            } else {
 4325              var previousDrain = queue.drain;
 4326              queue.drain = function() {
 4327                if (typeof previousDrain === "function") previousDrain();
 4328                resolve();
 4329                queue.drain = previousDrain;
 4330              };
 4331            }
 4332          });
 4333        });
 4334        return p2;
 4335      }
 4336    }
 4337    module2.exports = fastqueue;
 4338    module2.exports.promise = queueAsPromised;
 4339  }
 4340});
 4341
 4342// node_modules/@nodelib/fs.walk/out/readers/common.js
 4343var require_common2 = __commonJS({
 4344  "node_modules/@nodelib/fs.walk/out/readers/common.js"(exports2) {
 4345    "use strict";
 4346    Object.defineProperty(exports2, "__esModule", { value: true });
 4347    exports2.joinPathSegments = exports2.replacePathSegmentSeparator = exports2.isAppliedFilter = exports2.isFatalError = void 0;
 4348    function isFatalError(settings, error) {
 4349      if (settings.errorFilter === null) {
 4350        return true;
 4351      }
 4352      return !settings.errorFilter(error);
 4353    }
 4354    exports2.isFatalError = isFatalError;
 4355    function isAppliedFilter(filter, value) {
 4356      return filter === null || filter(value);
 4357    }
 4358    exports2.isAppliedFilter = isAppliedFilter;
 4359    function replacePathSegmentSeparator(filepath, separator) {
 4360      return filepath.split(/[/\\]/).join(separator);
 4361    }
 4362    exports2.replacePathSegmentSeparator = replacePathSegmentSeparator;
 4363    function joinPathSegments(a, b, separator) {
 4364      if (a === "") {
 4365        return b;
 4366      }
 4367      if (a.endsWith(separator)) {
 4368        return a + b;
 4369      }
 4370      return a + separator + b;
 4371    }
 4372    exports2.joinPathSegments = joinPathSegments;
 4373  }
 4374});
 4375
 4376// node_modules/@nodelib/fs.walk/out/readers/reader.js
 4377var require_reader = __commonJS({
 4378  "node_modules/@nodelib/fs.walk/out/readers/reader.js"(exports2) {
 4379    "use strict";
 4380    Object.defineProperty(exports2, "__esModule", { value: true });
 4381    var common = require_common2();
 4382    var Reader = class {
 4383      constructor(_root, _settings) {
 4384        this._root = _root;
 4385        this._settings = _settings;
 4386        this._root = common.replacePathSegmentSeparator(_root, _settings.pathSegmentSeparator);
 4387      }
 4388    };
 4389    exports2.default = Reader;
 4390  }
 4391});
 4392
 4393// node_modules/@nodelib/fs.walk/out/readers/async.js
 4394var require_async3 = __commonJS({
 4395  "node_modules/@nodelib/fs.walk/out/readers/async.js"(exports2) {
 4396    "use strict";
 4397    Object.defineProperty(exports2, "__esModule", { value: true });
 4398    var events_1 = require("events");
 4399    var fsScandir = require_out2();
 4400    var fastq = require_queue();
 4401    var common = require_common2();
 4402    var reader_1 = require_reader();
 4403    var AsyncReader = class extends reader_1.default {
 4404      constructor(_root, _settings) {
 4405        super(_root, _settings);
 4406        this._settings = _settings;
 4407        this._scandir = fsScandir.scandir;
 4408        this._emitter = new events_1.EventEmitter();
 4409        this._queue = fastq(this._worker.bind(this), this._settings.concurrency);
 4410        this._isFatalError = false;
 4411        this._isDestroyed = false;
 4412        this._queue.drain = () => {
 4413          if (!this._isFatalError) {
 4414            this._emitter.emit("end");
 4415          }
 4416        };
 4417      }
 4418      read() {
 4419        this._isFatalError = false;
 4420        this._isDestroyed = false;
 4421        setImmediate(() => {
 4422          this._pushToQueue(this._root, this._settings.basePath);
 4423        });
 4424        return this._emitter;
 4425      }
 4426      get isDestroyed() {
 4427        return this._isDestroyed;
 4428      }
 4429      destroy() {
 4430        if (this._isDestroyed) {
 4431          throw new Error("The reader is already destroyed");
 4432        }
 4433        this._isDestroyed = true;
 4434        this._queue.killAndDrain();
 4435      }
 4436      onEntry(callback) {
 4437        this._emitter.on("entry", callback);
 4438      }
 4439      onError(callback) {
 4440        this._emitter.once("error", callback);
 4441      }
 4442      onEnd(callback) {
 4443        this._emitter.once("end", callback);
 4444      }
 4445      _pushToQueue(directory, base) {
 4446        const queueItem = { directory, base };
 4447        this._queue.push(queueItem, (error) => {
 4448          if (error !== null) {
 4449            this._handleError(error);
 4450          }
 4451        });
 4452      }
 4453      _worker(item, done) {
 4454        this._scandir(item.directory, this._settings.fsScandirSettings, (error, entries) => {
 4455          if (error !== null) {
 4456            done(error, void 0);
 4457            return;
 4458          }
 4459          for (const entry of entries) {
 4460            this._handleEntry(entry, item.base);
 4461          }
 4462          done(null, void 0);
 4463        });
 4464      }
 4465      _handleError(error) {
 4466        if (this._isDestroyed || !common.isFatalError(this._settings, error)) {
 4467          return;
 4468        }
 4469        this._isFatalError = true;
 4470        this._isDestroyed = true;
 4471        this._emitter.emit("error", error);
 4472      }
 4473      _handleEntry(entry, base) {
 4474        if (this._isDestroyed || this._isFatalError) {
 4475          return;
 4476        }
 4477        const fullpath = entry.path;
 4478        if (base !== void 0) {
 4479          entry.path = common.joinPathSegments(base, entry.name, this._settings.pathSegmentSeparator);
 4480        }
 4481        if (common.isAppliedFilter(this._settings.entryFilter, entry)) {
 4482          this._emitEntry(entry);
 4483        }
 4484        if (entry.dirent.isDirectory() && common.isAppliedFilter(this._settings.deepFilter, entry)) {
 4485          this._pushToQueue(fullpath, base === void 0 ? void 0 : entry.path);
 4486        }
 4487      }
 4488      _emitEntry(entry) {
 4489        this._emitter.emit("entry", entry);
 4490      }
 4491    };
 4492    exports2.default = AsyncReader;
 4493  }
 4494});
 4495
 4496// node_modules/@nodelib/fs.walk/out/providers/async.js
 4497var require_async4 = __commonJS({
 4498  "node_modules/@nodelib/fs.walk/out/providers/async.js"(exports2) {
 4499    "use strict";
 4500    Object.defineProperty(exports2, "__esModule", { value: true });
 4501    var async_1 = require_async3();
 4502    var AsyncProvider = class {
 4503      constructor(_root, _settings) {
 4504        this._root = _root;
 4505        this._settings = _settings;
 4506        this._reader = new async_1.default(this._root, this._settings);
 4507        this._storage = [];
 4508      }
 4509      read(callback) {
 4510        this._reader.onError((error) => {
 4511          callFailureCallback(callback, error);
 4512        });
 4513        this._reader.onEntry((entry) => {
 4514          this._storage.push(entry);
 4515        });
 4516        this._reader.onEnd(() => {
 4517          callSuccessCallback(callback, this._storage);
 4518        });
 4519        this._reader.read();
 4520      }
 4521    };
 4522    exports2.default = AsyncProvider;
 4523    function callFailureCallback(callback, error) {
 4524      callback(error);
 4525    }
 4526    function callSuccessCallback(callback, entries) {
 4527      callback(null, entries);
 4528    }
 4529  }
 4530});
 4531
 4532// node_modules/@nodelib/fs.walk/out/providers/stream.js
 4533var require_stream2 = __commonJS({
 4534  "node_modules/@nodelib/fs.walk/out/providers/stream.js"(exports2) {
 4535    "use strict";
 4536    Object.defineProperty(exports2, "__esModule", { value: true });
 4537    var stream_1 = require("stream");
 4538    var async_1 = require_async3();
 4539    var StreamProvider = class {
 4540      constructor(_root, _settings) {
 4541        this._root = _root;
 4542        this._settings = _settings;
 4543        this._reader = new async_1.default(this._root, this._settings);
 4544        this._stream = new stream_1.Readable({
 4545          objectMode: true,
 4546          read: () => {
 4547          },
 4548          destroy: () => {
 4549            if (!this._reader.isDestroyed) {
 4550              this._reader.destroy();
 4551            }
 4552          }
 4553        });
 4554      }
 4555      read() {
 4556        this._reader.onError((error) => {
 4557          this._stream.emit("error", error);
 4558        });
 4559        this._reader.onEntry((entry) => {
 4560          this._stream.push(entry);
 4561        });
 4562        this._reader.onEnd(() => {
 4563          this._stream.push(null);
 4564        });
 4565        this._reader.read();
 4566        return this._stream;
 4567      }
 4568    };
 4569    exports2.default = StreamProvider;
 4570  }
 4571});
 4572
 4573// node_modules/@nodelib/fs.walk/out/readers/sync.js
 4574var require_sync3 = __commonJS({
 4575  "node_modules/@nodelib/fs.walk/out/readers/sync.js"(exports2) {
 4576    "use strict";
 4577    Object.defineProperty(exports2, "__esModule", { value: true });
 4578    var fsScandir = require_out2();
 4579    var common = require_common2();
 4580    var reader_1 = require_reader();
 4581    var SyncReader = class extends reader_1.default {
 4582      constructor() {
 4583        super(...arguments);
 4584        this._scandir = fsScandir.scandirSync;
 4585        this._storage = [];
 4586        this._queue = /* @__PURE__ */ new Set();
 4587      }
 4588      read() {
 4589        this._pushToQueue(this._root, this._settings.basePath);
 4590        this._handleQueue();
 4591        return this._storage;
 4592      }
 4593      _pushToQueue(directory, base) {
 4594        this._queue.add({ directory, base });
 4595      }
 4596      _handleQueue() {
 4597        for (const item of this._queue.values()) {
 4598          this._handleDirectory(item.directory, item.base);
 4599        }
 4600      }
 4601      _handleDirectory(directory, base) {
 4602        try {
 4603          const entries = this._scandir(directory, this._settings.fsScandirSettings);
 4604          for (const entry of entries) {
 4605            this._handleEntry(entry, base);
 4606          }
 4607        } catch (error) {
 4608          this._handleError(error);
 4609        }
 4610      }
 4611      _handleError(error) {
 4612        if (!common.isFatalError(this._settings, error)) {
 4613          return;
 4614        }
 4615        throw error;
 4616      }
 4617      _handleEntry(entry, base) {
 4618        const fullpath = entry.path;
 4619        if (base !== void 0) {
 4620          entry.path = common.joinPathSegments(base, entry.name, this._settings.pathSegmentSeparator);
 4621        }
 4622        if (common.isAppliedFilter(this._settings.entryFilter, entry)) {
 4623          this._pushToStorage(entry);
 4624        }
 4625        if (entry.dirent.isDirectory() && common.isAppliedFilter(this._settings.deepFilter, entry)) {
 4626          this._pushToQueue(fullpath, base === void 0 ? void 0 : entry.path);
 4627        }
 4628      }
 4629      _pushToStorage(entry) {
 4630        this._storage.push(entry);
 4631      }
 4632    };
 4633    exports2.default = SyncReader;
 4634  }
 4635});
 4636
 4637// node_modules/@nodelib/fs.walk/out/providers/sync.js
 4638var require_sync4 = __commonJS({
 4639  "node_modules/@nodelib/fs.walk/out/providers/sync.js"(exports2) {
 4640    "use strict";
 4641    Object.defineProperty(exports2, "__esModule", { value: true });
 4642    var sync_1 = require_sync3();
 4643    var SyncProvider = class {
 4644      constructor(_root, _settings) {
 4645        this._root = _root;
 4646        this._settings = _settings;
 4647        this._reader = new sync_1.default(this._root, this._settings);
 4648      }
 4649      read() {
 4650        return this._reader.read();
 4651      }
 4652    };
 4653    exports2.default = SyncProvider;
 4654  }
 4655});
 4656
 4657// node_modules/@nodelib/fs.walk/out/settings.js
 4658var require_settings3 = __commonJS({
 4659  "node_modules/@nodelib/fs.walk/out/settings.js"(exports2) {
 4660    "use strict";
 4661    Object.defineProperty(exports2, "__esModule", { value: true });
 4662    var path5 = require("path");
 4663    var fsScandir = require_out2();
 4664    var Settings = class {
 4665      constructor(_options = {}) {
 4666        this._options = _options;
 4667        this.basePath = this._getValue(this._options.basePath, void 0);
 4668        this.concurrency = this._getValue(this._options.concurrency, Number.POSITIVE_INFINITY);
 4669        this.deepFilter = this._getValue(this._options.deepFilter, null);
 4670        this.entryFilter = this._getValue(this._options.entryFilter, null);
 4671        this.errorFilter = this._getValue(this._options.errorFilter, null);
 4672        this.pathSegmentSeparator = this._getValue(this._options.pathSegmentSeparator, path5.sep);
 4673        this.fsScandirSettings = new fsScandir.Settings({
 4674          followSymbolicLinks: this._options.followSymbolicLinks,
 4675          fs: this._options.fs,
 4676          pathSegmentSeparator: this._options.pathSegmentSeparator,
 4677          stats: this._options.stats,
 4678          throwErrorOnBrokenSymbolicLink: this._options.throwErrorOnBrokenSymbolicLink
 4679        });
 4680      }
 4681      _getValue(option, value) {
 4682        return option !== null && option !== void 0 ? option : value;
 4683      }
 4684    };
 4685    exports2.default = Settings;
 4686  }
 4687});
 4688
 4689// node_modules/@nodelib/fs.walk/out/index.js
 4690var require_out3 = __commonJS({
 4691  "node_modules/@nodelib/fs.walk/out/index.js"(exports2) {
 4692    "use strict";
 4693    Object.defineProperty(exports2, "__esModule", { value: true });
 4694    exports2.Settings = exports2.walkStream = exports2.walkSync = exports2.walk = void 0;
 4695    var async_1 = require_async4();
 4696    var stream_1 = require_stream2();
 4697    var sync_1 = require_sync4();
 4698    var settings_1 = require_settings3();
 4699    exports2.Settings = settings_1.default;
 4700    function walk(directory, optionsOrSettingsOrCallback, callback) {
 4701      if (typeof optionsOrSettingsOrCallback === "function") {
 4702        new async_1.default(directory, getSettings()).read(optionsOrSettingsOrCallback);
 4703        return;
 4704      }
 4705      new async_1.default(directory, getSettings(optionsOrSettingsOrCallback)).read(callback);
 4706    }
 4707    exports2.walk = walk;
 4708    function walkSync(directory, optionsOrSettings) {
 4709      const settings = getSettings(optionsOrSettings);
 4710      const provider = new sync_1.default(directory, settings);
 4711      return provider.read();
 4712    }
 4713    exports2.walkSync = walkSync;
 4714    function walkStream(directory, optionsOrSettings) {
 4715      const settings = getSettings(optionsOrSettings);
 4716      const provider = new stream_1.default(directory, settings);
 4717      return provider.read();
 4718    }
 4719    exports2.walkStream = walkStream;
 4720    function getSettings(settingsOrOptions = {}) {
 4721      if (settingsOrOptions instanceof settings_1.default) {
 4722        return settingsOrOptions;
 4723      }
 4724      return new settings_1.default(settingsOrOptions);
 4725    }
 4726  }
 4727});
 4728
 4729// node_modules/fast-glob/out/readers/reader.js
 4730var require_reader2 = __commonJS({
 4731  "node_modules/fast-glob/out/readers/reader.js"(exports2) {
 4732    "use strict";
 4733    Object.defineProperty(exports2, "__esModule", { value: true });
 4734    var path5 = require("path");
 4735    var fsStat = require_out();
 4736    var utils = require_utils3();
 4737    var Reader = class {
 4738      constructor(_settings) {
 4739        this._settings = _settings;
 4740        this._fsStatSettings = new fsStat.Settings({
 4741          followSymbolicLink: this._settings.followSymbolicLinks,
 4742          fs: this._settings.fs,
 4743          throwErrorOnBrokenSymbolicLink: this._settings.followSymbolicLinks
 4744        });
 4745      }
 4746      _getFullEntryPath(filepath) {
 4747        return path5.resolve(this._settings.cwd, filepath);
 4748      }
 4749      _makeEntry(stats, pattern) {
 4750        const entry = {
 4751          name: pattern,
 4752          path: pattern,
 4753          dirent: utils.fs.createDirentFromStats(pattern, stats)
 4754        };
 4755        if (this._settings.stats) {
 4756          entry.stats = stats;
 4757        }
 4758        return entry;
 4759      }
 4760      _isFatalError(error) {
 4761        return !utils.errno.isEnoentCodeError(error) && !this._settings.suppressErrors;
 4762      }
 4763    };
 4764    exports2.default = Reader;
 4765  }
 4766});
 4767
 4768// node_modules/fast-glob/out/readers/stream.js
 4769var require_stream3 = __commonJS({
 4770  "node_modules/fast-glob/out/readers/stream.js"(exports2) {
 4771    "use strict";
 4772    Object.defineProperty(exports2, "__esModule", { value: true });
 4773    var stream_1 = require("stream");
 4774    var fsStat = require_out();
 4775    var fsWalk = require_out3();
 4776    var reader_1 = require_reader2();
 4777    var ReaderStream = class extends reader_1.default {
 4778      constructor() {
 4779        super(...arguments);
 4780        this._walkStream = fsWalk.walkStream;
 4781        this._stat = fsStat.stat;
 4782      }
 4783      dynamic(root, options) {
 4784        return this._walkStream(root, options);
 4785      }
 4786      static(patterns, options) {
 4787        const filepaths = patterns.map(this._getFullEntryPath, this);
 4788        const stream = new stream_1.PassThrough({ objectMode: true });
 4789        stream._write = (index, _enc, done) => {
 4790          return this._getEntry(filepaths[index], patterns[index], options).then((entry) => {
 4791            if (entry !== null && options.entryFilter(entry)) {
 4792              stream.push(entry);
 4793            }
 4794            if (index === filepaths.length - 1) {
 4795              stream.end();
 4796            }
 4797            done();
 4798          }).catch(done);
 4799        };
 4800        for (let i = 0; i < filepaths.length; i++) {
 4801          stream.write(i);
 4802        }
 4803        return stream;
 4804      }
 4805      _getEntry(filepath, pattern, options) {
 4806        return this._getStat(filepath).then((stats) => this._makeEntry(stats, pattern)).catch((error) => {
 4807          if (options.errorFilter(error)) {
 4808            return null;
 4809          }
 4810          throw error;
 4811        });
 4812      }
 4813      _getStat(filepath) {
 4814        return new Promise((resolve, reject) => {
 4815          this._stat(filepath, this._fsStatSettings, (error, stats) => {
 4816            return error === null ? resolve(stats) : reject(error);
 4817          });
 4818        });
 4819      }
 4820    };
 4821    exports2.default = ReaderStream;
 4822  }
 4823});
 4824
 4825// node_modules/fast-glob/out/readers/async.js
 4826var require_async5 = __commonJS({
 4827  "node_modules/fast-glob/out/readers/async.js"(exports2) {
 4828    "use strict";
 4829    Object.defineProperty(exports2, "__esModule", { value: true });
 4830    var fsWalk = require_out3();
 4831    var reader_1 = require_reader2();
 4832    var stream_1 = require_stream3();
 4833    var ReaderAsync = class extends reader_1.default {
 4834      constructor() {
 4835        super(...arguments);
 4836        this._walkAsync = fsWalk.walk;
 4837        this._readerStream = new stream_1.default(this._settings);
 4838      }
 4839      dynamic(root, options) {
 4840        return new Promise((resolve, reject) => {
 4841          this._walkAsync(root, options, (error, entries) => {
 4842            if (error === null) {
 4843              resolve(entries);
 4844            } else {
 4845              reject(error);
 4846            }
 4847          });
 4848        });
 4849      }
 4850      static(patterns, options) {
 4851        return __async(this, null, function* () {
 4852          const entries = [];
 4853          const stream = this._readerStream.static(patterns, options);
 4854          return new Promise((resolve, reject) => {
 4855            stream.once("error", reject);
 4856            stream.on("data", (entry) => entries.push(entry));
 4857            stream.once("end", () => resolve(entries));
 4858          });
 4859        });
 4860      }
 4861    };
 4862    exports2.default = ReaderAsync;
 4863  }
 4864});
 4865
 4866// node_modules/fast-glob/out/providers/matchers/matcher.js
 4867var require_matcher = __commonJS({
 4868  "node_modules/fast-glob/out/providers/matchers/matcher.js"(exports2) {
 4869    "use strict";
 4870    Object.defineProperty(exports2, "__esModule", { value: true });
 4871    var utils = require_utils3();
 4872    var Matcher = class {
 4873      constructor(_patterns, _settings, _micromatchOptions) {
 4874        this._patterns = _patterns;
 4875        this._settings = _settings;
 4876        this._micromatchOptions = _micromatchOptions;
 4877        this._storage = [];
 4878        this._fillStorage();
 4879      }
 4880      _fillStorage() {
 4881        for (const pattern of this._patterns) {
 4882          const segments = this._getPatternSegments(pattern);
 4883          const sections = this._splitSegmentsIntoSections(segments);
 4884          this._storage.push({
 4885            complete: sections.length <= 1,
 4886            pattern,
 4887            segments,
 4888            sections
 4889          });
 4890        }
 4891      }
 4892      _getPatternSegments(pattern) {
 4893        const parts = utils.pattern.getPatternParts(pattern, this._micromatchOptions);
 4894        return parts.map((part) => {
 4895          const dynamic = utils.pattern.isDynamicPattern(part, this._settings);
 4896          if (!dynamic) {
 4897            return {
 4898              dynamic: false,
 4899              pattern: part
 4900            };
 4901          }
 4902          return {
 4903            dynamic: true,
 4904            pattern: part,
 4905            patternRe: utils.pattern.makeRe(part, this._micromatchOptions)
 4906          };
 4907        });
 4908      }
 4909      _splitSegmentsIntoSections(segments) {
 4910        return utils.array.splitWhen(segments, (segment) => segment.dynamic && utils.pattern.hasGlobStar(segment.pattern));
 4911      }
 4912    };
 4913    exports2.default = Matcher;
 4914  }
 4915});
 4916
 4917// node_modules/fast-glob/out/providers/matchers/partial.js
 4918var require_partial = __commonJS({
 4919  "node_modules/fast-glob/out/providers/matchers/partial.js"(exports2) {
 4920    "use strict";
 4921    Object.defineProperty(exports2, "__esModule", { value: true });
 4922    var matcher_1 = require_matcher();
 4923    var PartialMatcher = class extends matcher_1.default {
 4924      match(filepath) {
 4925        const parts = filepath.split("/");
 4926        const levels = parts.length;
 4927        const patterns = this._storage.filter((info) => !info.complete || info.segments.length > levels);
 4928        for (const pattern of patterns) {
 4929          const section = pattern.sections[0];
 4930          if (!pattern.complete && levels > section.length) {
 4931            return true;
 4932          }
 4933          const match = parts.every((part, index) => {
 4934            const segment = pattern.segments[index];
 4935            if (segment.dynamic && segment.patternRe.test(part)) {
 4936              return true;
 4937            }
 4938            if (!segment.dynamic && segment.pattern === part) {
 4939              return true;
 4940            }
 4941            return false;
 4942          });
 4943          if (match) {
 4944            return true;
 4945          }
 4946        }
 4947        return false;
 4948      }
 4949    };
 4950    exports2.default = PartialMatcher;
 4951  }
 4952});
 4953
 4954// node_modules/fast-glob/out/providers/filters/deep.js
 4955var require_deep = __commonJS({
 4956  "node_modules/fast-glob/out/providers/filters/deep.js"(exports2) {
 4957    "use strict";
 4958    Object.defineProperty(exports2, "__esModule", { value: true });
 4959    var utils = require_utils3();
 4960    var partial_1 = require_partial();
 4961    var DeepFilter = class {
 4962      constructor(_settings, _micromatchOptions) {
 4963        this._settings = _settings;
 4964        this._micromatchOptions = _micromatchOptions;
 4965      }
 4966      getFilter(basePath, positive, negative) {
 4967        const matcher = this._getMatcher(positive);
 4968        const negativeRe = this._getNegativePatternsRe(negative);
 4969        return (entry) => this._filter(basePath, entry, matcher, negativeRe);
 4970      }
 4971      _getMatcher(patterns) {
 4972        return new partial_1.default(patterns, this._settings, this._micromatchOptions);
 4973      }
 4974      _getNegativePatternsRe(patterns) {
 4975        const affectDepthOfReadingPatterns = patterns.filter(utils.pattern.isAffectDepthOfReadingPattern);
 4976        return utils.pattern.convertPatternsToRe(affectDepthOfReadingPatterns, this._micromatchOptions);
 4977      }
 4978      _filter(basePath, entry, matcher, negativeRe) {
 4979        if (this._isSkippedByDeep(basePath, entry.path)) {
 4980          return false;
 4981        }
 4982        if (this._isSkippedSymbolicLink(entry)) {
 4983          return false;
 4984        }
 4985        const filepath = utils.path.removeLeadingDotSegment(entry.path);
 4986        if (this._isSkippedByPositivePatterns(filepath, matcher)) {
 4987          return false;
 4988        }
 4989        return this._isSkippedByNegativePatterns(filepath, negativeRe);
 4990      }
 4991      _isSkippedByDeep(basePath, entryPath) {
 4992        if (this._settings.deep === Infinity) {
 4993          return false;
 4994        }
 4995        return this._getEntryLevel(basePath, entryPath) >= this._settings.deep;
 4996      }
 4997      _getEntryLevel(basePath, entryPath) {
 4998        const entryPathDepth = entryPath.split("/").length;
 4999        if (basePath === "") {
 5000          return entryPathDepth;
 5001        }
 5002        const basePathDepth = basePath.split("/").length;
 5003        return entryPathDepth - basePathDepth;
 5004      }
 5005      _isSkippedSymbolicLink(entry) {
 5006        return !this._settings.followSymbolicLinks && entry.dirent.isSymbolicLink();
 5007      }
 5008      _isSkippedByPositivePatterns(entryPath, matcher) {
 5009        return !this._settings.baseNameMatch && !matcher.match(entryPath);
 5010      }
 5011      _isSkippedByNegativePatterns(entryPath, patternsRe) {
 5012        return !utils.pattern.matchAny(entryPath, patternsRe);
 5013      }
 5014    };
 5015    exports2.default = DeepFilter;
 5016  }
 5017});
 5018
 5019// node_modules/fast-glob/out/providers/filters/entry.js
 5020var require_entry = __commonJS({
 5021  "node_modules/fast-glob/out/providers/filters/entry.js"(exports2) {
 5022    "use strict";
 5023    Object.defineProperty(exports2, "__esModule", { value: true });
 5024    var utils = require_utils3();
 5025    var EntryFilter = class {
 5026      constructor(_settings, _micromatchOptions) {
 5027        this._settings = _settings;
 5028        this._micromatchOptions = _micromatchOptions;
 5029        this.index = /* @__PURE__ */ new Map();
 5030      }
 5031      getFilter(positive, negative) {
 5032        const [absoluteNegative, relativeNegative] = utils.pattern.partitionAbsoluteAndRelative(negative);
 5033        const patterns = {
 5034          positive: {
 5035            all: utils.pattern.convertPatternsToRe(positive, this._micromatchOptions)
 5036          },
 5037          negative: {
 5038            absolute: utils.pattern.convertPatternsToRe(absoluteNegative, Object.assign(Object.assign({}, this._micromatchOptions), { dot: true })),
 5039            relative: utils.pattern.convertPatternsToRe(relativeNegative, Object.assign(Object.assign({}, this._micromatchOptions), { dot: true }))
 5040          }
 5041        };
 5042        return (entry) => this._filter(entry, patterns);
 5043      }
 5044      _filter(entry, patterns) {
 5045        const filepath = utils.path.removeLeadingDotSegment(entry.path);
 5046        if (this._settings.unique && this._isDuplicateEntry(filepath)) {
 5047          return false;
 5048        }
 5049        if (this._onlyFileFilter(entry) || this._onlyDirectoryFilter(entry)) {
 5050          return false;
 5051        }
 5052        const isMatched = this._isMatchToPatternsSet(filepath, patterns, entry.dirent.isDirectory());
 5053        if (this._settings.unique && isMatched) {
 5054          this._createIndexRecord(filepath);
 5055        }
 5056        return isMatched;
 5057      }
 5058      _isDuplicateEntry(filepath) {
 5059        return this.index.has(filepath);
 5060      }
 5061      _createIndexRecord(filepath) {
 5062        this.index.set(filepath, void 0);
 5063      }
 5064      _onlyFileFilter(entry) {
 5065        return this._settings.onlyFiles && !entry.dirent.isFile();
 5066      }
 5067      _onlyDirectoryFilter(entry) {
 5068        return this._settings.onlyDirectories && !entry.dirent.isDirectory();
 5069      }
 5070      _isMatchToPatternsSet(filepath, patterns, isDirectory2) {
 5071        const isMatched = this._isMatchToPatterns(filepath, patterns.positive.all, isDirectory2);
 5072        if (!isMatched) {
 5073          return false;
 5074        }
 5075        const isMatchedByRelativeNegative = this._isMatchToPatterns(filepath, patterns.negative.relative, isDirectory2);
 5076        if (isMatchedByRelativeNegative) {
 5077          return false;
 5078        }
 5079        const isMatchedByAbsoluteNegative = this._isMatchToAbsoluteNegative(filepath, patterns.negative.absolute, isDirectory2);
 5080        if (isMatchedByAbsoluteNegative) {
 5081          return false;
 5082        }
 5083        return true;
 5084      }
 5085      _isMatchToAbsoluteNegative(filepath, patternsRe, isDirectory2) {
 5086        if (patternsRe.length === 0) {
 5087          return false;
 5088        }
 5089        const fullpath = utils.path.makeAbsolute(this._settings.cwd, filepath);
 5090        return this._isMatchToPatterns(fullpath, patternsRe, isDirectory2);
 5091      }
 5092      _isMatchToPatterns(filepath, patternsRe, isDirectory2) {
 5093        if (patternsRe.length === 0) {
 5094          return false;
 5095        }
 5096        const isMatched = utils.pattern.matchAny(filepath, patternsRe);
 5097        if (!isMatched && isDirectory2) {
 5098          return utils.pattern.matchAny(filepath + "/", patternsRe);
 5099        }
 5100        return isMatched;
 5101      }
 5102    };
 5103    exports2.default = EntryFilter;
 5104  }
 5105});
 5106
 5107// node_modules/fast-glob/out/providers/filters/error.js
 5108var require_error = __commonJS({
 5109  "node_modules/fast-glob/out/providers/filters/error.js"(exports2) {
 5110    "use strict";
 5111    Object.defineProperty(exports2, "__esModule", { value: true });
 5112    var utils = require_utils3();
 5113    var ErrorFilter = class {
 5114      constructor(_settings) {
 5115        this._settings = _settings;
 5116      }
 5117      getFilter() {
 5118        return (error) => this._isNonFatalError(error);
 5119      }
 5120      _isNonFatalError(error) {
 5121        return utils.errno.isEnoentCodeError(error) || this._settings.suppressErrors;
 5122      }
 5123    };
 5124    exports2.default = ErrorFilter;
 5125  }
 5126});
 5127
 5128// node_modules/fast-glob/out/providers/transformers/entry.js
 5129var require_entry2 = __commonJS({
 5130  "node_modules/fast-glob/out/providers/transformers/entry.js"(exports2) {
 5131    "use strict";
 5132    Object.defineProperty(exports2, "__esModule", { value: true });
 5133    var utils = require_utils3();
 5134    var EntryTransformer = class {
 5135      constructor(_settings) {
 5136        this._settings = _settings;
 5137      }
 5138      getTransformer() {
 5139        return (entry) => this._transform(entry);
 5140      }
 5141      _transform(entry) {
 5142        let filepath = entry.path;
 5143        if (this._settings.absolute) {
 5144          filepath = utils.path.makeAbsolute(this._settings.cwd, filepath);
 5145          filepath = utils.path.unixify(filepath);
 5146        }
 5147        if (this._settings.markDirectories && entry.dirent.isDirectory()) {
 5148          filepath += "/";
 5149        }
 5150        if (!this._settings.objectMode) {
 5151          return filepath;
 5152        }
 5153        return Object.assign(Object.assign({}, entry), { path: filepath });
 5154      }
 5155    };
 5156    exports2.default = EntryTransformer;
 5157  }
 5158});
 5159
 5160// node_modules/fast-glob/out/providers/provider.js
 5161var require_provider = __commonJS({
 5162  "node_modules/fast-glob/out/providers/provider.js"(exports2) {
 5163    "use strict";
 5164    Object.defineProperty(exports2, "__esModule", { value: true });
 5165    var path5 = require("path");
 5166    var deep_1 = require_deep();
 5167    var entry_1 = require_entry();
 5168    var error_1 = require_error();
 5169    var entry_2 = require_entry2();
 5170    var Provider = class {
 5171      constructor(_settings) {
 5172        this._settings = _settings;
 5173        this.errorFilter = new error_1.default(this._settings);
 5174        this.entryFilter = new entry_1.default(this._settings, this._getMicromatchOptions());
 5175        this.deepFilter = new deep_1.default(this._settings, this._getMicromatchOptions());
 5176        this.entryTransformer = new entry_2.default(this._settings);
 5177      }
 5178      _getRootDirectory(task) {
 5179        return path5.resolve(this._settings.cwd, task.base);
 5180      }
 5181      _getReaderOptions(task) {
 5182        const basePath = task.base === "." ? "" : task.base;
 5183        return {
 5184          basePath,
 5185          pathSegmentSeparator: "/",
 5186          concurrency: this._settings.concurrency,
 5187          deepFilter: this.deepFilter.getFilter(basePath, task.positive, task.negative),
 5188          entryFilter: this.entryFilter.getFilter(task.positive, task.negative),
 5189          errorFilter: this.errorFilter.getFilter(),
 5190          followSymbolicLinks: this._settings.followSymbolicLinks,
 5191          fs: this._settings.fs,
 5192          stats: this._settings.stats,
 5193          throwErrorOnBrokenSymbolicLink: this._settings.throwErrorOnBrokenSymbolicLink,
 5194          transform: this.entryTransformer.getTransformer()
 5195        };
 5196      }
 5197      _getMicromatchOptions() {
 5198        return {
 5199          dot: this._settings.dot,
 5200          matchBase: this._settings.baseNameMatch,
 5201          nobrace: !this._settings.braceExpansion,
 5202          nocase: !this._settings.caseSensitiveMatch,
 5203          noext: !this._settings.extglob,
 5204          noglobstar: !this._settings.globstar,
 5205          posix: true,
 5206          strictSlashes: false
 5207        };
 5208      }
 5209    };
 5210    exports2.default = Provider;
 5211  }
 5212});
 5213
 5214// node_modules/fast-glob/out/providers/async.js
 5215var require_async6 = __commonJS({
 5216  "node_modules/fast-glob/out/providers/async.js"(exports2) {
 5217    "use strict";
 5218    Object.defineProperty(exports2, "__esModule", { value: true });
 5219    var async_1 = require_async5();
 5220    var provider_1 = require_provider();
 5221    var ProviderAsync = class extends provider_1.default {
 5222      constructor() {
 5223        super(...arguments);
 5224        this._reader = new async_1.default(this._settings);
 5225      }
 5226      read(task) {
 5227        return __async(this, null, function* () {
 5228          const root = this._getRootDirectory(task);
 5229          const options = this._getReaderOptions(task);
 5230          const entries = yield this.api(root, task, options);
 5231          return entries.map((entry) => options.transform(entry));
 5232        });
 5233      }
 5234      api(root, task, options) {
 5235        if (task.dynamic) {
 5236          return this._reader.dynamic(root, options);
 5237        }
 5238        return this._reader.static(task.patterns, options);
 5239      }
 5240    };
 5241    exports2.default = ProviderAsync;
 5242  }
 5243});
 5244
 5245// node_modules/fast-glob/out/providers/stream.js
 5246var require_stream4 = __commonJS({
 5247  "node_modules/fast-glob/out/providers/stream.js"(exports2) {
 5248    "use strict";
 5249    Object.defineProperty(exports2, "__esModule", { value: true });
 5250    var stream_1 = require("stream");
 5251    var stream_2 = require_stream3();
 5252    var provider_1 = require_provider();
 5253    var ProviderStream = class extends provider_1.default {
 5254      constructor() {
 5255        super(...arguments);
 5256        this._reader = new stream_2.default(this._settings);
 5257      }
 5258      read(task) {
 5259        const root = this._getRootDirectory(task);
 5260        const options = this._getReaderOptions(task);
 5261        const source = this.api(root, task, options);
 5262        const destination = new stream_1.Readable({ objectMode: true, read: () => {
 5263        } });
 5264        source.once("error", (error) => destination.emit("error", error)).on("data", (entry) => destination.emit("data", options.transform(entry))).once("end", () => destination.emit("end"));
 5265        destination.once("close", () => source.destroy());
 5266        return destination;
 5267      }
 5268      api(root, task, options) {
 5269        if (task.dynamic) {
 5270          return this._reader.dynamic(root, options);
 5271        }
 5272        return this._reader.static(task.patterns, options);
 5273      }
 5274    };
 5275    exports2.default = ProviderStream;
 5276  }
 5277});
 5278
 5279// node_modules/fast-glob/out/readers/sync.js
 5280var require_sync5 = __commonJS({
 5281  "node_modules/fast-glob/out/readers/sync.js"(exports2) {
 5282    "use strict";
 5283    Object.defineProperty(exports2, "__esModule", { value: true });
 5284    var fsStat = require_out();
 5285    var fsWalk = require_out3();
 5286    var reader_1 = require_reader2();
 5287    var ReaderSync = class extends reader_1.default {
 5288      constructor() {
 5289        super(...arguments);
 5290        this._walkSync = fsWalk.walkSync;
 5291        this._statSync = fsStat.statSync;
 5292      }
 5293      dynamic(root, options) {
 5294        return this._walkSync(root, options);
 5295      }
 5296      static(patterns, options) {
 5297        const entries = [];
 5298        for (const pattern of patterns) {
 5299          const filepath = this._getFullEntryPath(pattern);
 5300          const entry = this._getEntry(filepath, pattern, options);
 5301          if (entry === null || !options.entryFilter(entry)) {
 5302            continue;
 5303          }
 5304          entries.push(entry);
 5305        }
 5306        return entries;
 5307      }
 5308      _getEntry(filepath, pattern, options) {
 5309        try {
 5310          const stats = this._getStat(filepath);
 5311          return this._makeEntry(stats, pattern);
 5312        } catch (error) {
 5313          if (options.errorFilter(error)) {
 5314            return null;
 5315          }
 5316          throw error;
 5317        }
 5318      }
 5319      _getStat(filepath) {
 5320        return this._statSync(filepath, this._fsStatSettings);
 5321      }
 5322    };
 5323    exports2.default = ReaderSync;
 5324  }
 5325});
 5326
 5327// node_modules/fast-glob/out/providers/sync.js
 5328var require_sync6 = __commonJS({
 5329  "node_modules/fast-glob/out/providers/sync.js"(exports2) {
 5330    "use strict";
 5331    Object.defineProperty(exports2, "__esModule", { value: true });
 5332    var sync_1 = require_sync5();
 5333    var provider_1 = require_provider();
 5334    var ProviderSync = class extends provider_1.default {
 5335      constructor() {
 5336        super(...arguments);
 5337        this._reader = new sync_1.default(this._settings);
 5338      }
 5339      read(task) {
 5340        const root = this._getRootDirectory(task);
 5341        const options = this._getReaderOptions(task);
 5342        const entries = this.api(root, task, options);
 5343        return entries.map(options.transform);
 5344      }
 5345      api(root, task, options) {
 5346        if (task.dynamic) {
 5347          return this._reader.dynamic(root, options);
 5348        }
 5349        return this._reader.static(task.patterns, options);
 5350      }
 5351    };
 5352    exports2.default = ProviderSync;
 5353  }
 5354});
 5355
 5356// node_modules/fast-glob/out/settings.js
 5357var require_settings4 = __commonJS({
 5358  "node_modules/fast-glob/out/settings.js"(exports2) {
 5359    "use strict";
 5360    Object.defineProperty(exports2, "__esModule", { value: true });
 5361    exports2.DEFAULT_FILE_SYSTEM_ADAPTER = void 0;
 5362    var fs6 = require("fs");
 5363    var os = require("os");
 5364    var CPU_COUNT = Math.max(os.cpus().length, 1);
 5365    exports2.DEFAULT_FILE_SYSTEM_ADAPTER = {
 5366      lstat: fs6.lstat,
 5367      lstatSync: fs6.lstatSync,
 5368      stat: fs6.stat,
 5369      statSync: fs6.statSync,
 5370      readdir: fs6.readdir,
 5371      readdirSync: fs6.readdirSync
 5372    };
 5373    var Settings = class {
 5374      constructor(_options = {}) {
 5375        this._options = _options;
 5376        this.absolute = this._getValue(this._options.absolute, false);
 5377        this.baseNameMatch = this._getValue(this._options.baseNameMatch, false);
 5378        this.braceExpansion = this._getValue(this._options.braceExpansion, true);
 5379        this.caseSensitiveMatch = this._getValue(this._options.caseSensitiveMatch, true);
 5380        this.concurrency = this._getValue(this._options.concurrency, CPU_COUNT);
 5381        this.cwd = this._getValue(this._options.cwd, process.cwd());
 5382        this.deep = this._getValue(this._options.deep, Infinity);
 5383        this.dot = this._getValue(this._options.dot, false);
 5384        this.extglob = this._getValue(this._options.extglob, true);
 5385        this.followSymbolicLinks = this._getValue(this._options.followSymbolicLinks, true);
 5386        this.fs = this._getFileSystemMethods(this._options.fs);
 5387        this.globstar = this._getValue(this._options.globstar, true);
 5388        this.ignore = this._getValue(this._options.ignore, []);
 5389        this.markDirectories = this._getValue(this._options.markDirectories, false);
 5390        this.objectMode = this._getValue(this._options.objectMode, false);
 5391        this.onlyDirectories = this._getValue(this._options.onlyDirectories, false);
 5392        this.onlyFiles = this._getValue(this._options.onlyFiles, true);
 5393        this.stats = this._getValue(this._options.stats, false);
 5394        this.suppressErrors = this._getValue(this._options.suppressErrors, false);
 5395        this.throwErrorOnBrokenSymbolicLink = this._getValue(this._options.throwErrorOnBrokenSymbolicLink, false);
 5396        this.unique = this._getValue(this._options.unique, true);
 5397        if (this.onlyDirectories) {
 5398          this.onlyFiles = false;
 5399        }
 5400        if (this.stats) {
 5401          this.objectMode = true;
 5402        }
 5403        this.ignore = [].concat(this.ignore);
 5404      }
 5405      _getValue(option, value) {
 5406        return option === void 0 ? value : option;
 5407      }
 5408      _getFileSystemMethods(methods = {}) {
 5409        return Object.assign(Object.assign({}, exports2.DEFAULT_FILE_SYSTEM_ADAPTER), methods);
 5410      }
 5411    };
 5412    exports2.default = Settings;
 5413  }
 5414});
 5415
 5416// node_modules/fast-glob/out/index.js
 5417var require_out4 = __commonJS({
 5418  "node_modules/fast-glob/out/index.js"(exports2, module2) {
 5419    "use strict";
 5420    var taskManager = require_tasks();
 5421    var async_1 = require_async6();
 5422    var stream_1 = require_stream4();
 5423    var sync_1 = require_sync6();
 5424    var settings_1 = require_settings4();
 5425    var utils = require_utils3();
 5426    function FastGlob(source, options) {
 5427      return __async(this, null, function* () {
 5428        assertPatternsInput2(source);
 5429        const works = getWorks(source, async_1.default, options);
 5430        const result = yield Promise.all(works);
 5431        return utils.array.flatten(result);
 5432      });
 5433    }
 5434    (function(FastGlob2) {
 5435      FastGlob2.glob = FastGlob2;
 5436      FastGlob2.globSync = sync;
 5437      FastGlob2.globStream = stream;
 5438      FastGlob2.async = FastGlob2;
 5439      function sync(source, options) {
 5440        assertPatternsInput2(source);
 5441        const works = getWorks(source, sync_1.default, options);
 5442        return utils.array.flatten(works);
 5443      }
 5444      FastGlob2.sync = sync;
 5445      function stream(source, options) {
 5446        assertPatternsInput2(source);
 5447        const works = getWorks(source, stream_1.default, options);
 5448        return utils.stream.merge(works);
 5449      }
 5450      FastGlob2.stream = stream;
 5451      function generateTasks2(source, options) {
 5452        assertPatternsInput2(source);
 5453        const patterns = [].concat(source);
 5454        const settings = new settings_1.default(options);
 5455        return taskManager.generate(patterns, settings);
 5456      }
 5457      FastGlob2.generateTasks = generateTasks2;
 5458      function isDynamicPattern2(source, options) {
 5459        assertPatternsInput2(source);
 5460        const settings = new settings_1.default(options);
 5461        return utils.pattern.isDynamicPattern(source, settings);
 5462      }
 5463      FastGlob2.isDynamicPattern = isDynamicPattern2;
 5464      function escapePath(source) {
 5465        assertPatternsInput2(source);
 5466        return utils.path.escape(source);
 5467      }
 5468      FastGlob2.escapePath = escapePath;
 5469      function convertPathToPattern2(source) {
 5470        assertPatternsInput2(source);
 5471        return utils.path.convertPathToPattern(source);
 5472      }
 5473      FastGlob2.convertPathToPattern = convertPathToPattern2;
 5474      let posix;
 5475      (function(posix2) {
 5476        function escapePath2(source) {
 5477          assertPatternsInput2(source);
 5478          return utils.path.escapePosixPath(source);
 5479        }
 5480        posix2.escapePath = escapePath2;
 5481        function convertPathToPattern3(source) {
 5482          assertPatternsInput2(source);
 5483          return utils.path.convertPosixPathToPattern(source);
 5484        }
 5485        posix2.convertPathToPattern = convertPathToPattern3;
 5486      })(posix = FastGlob2.posix || (FastGlob2.posix = {}));
 5487      let win32;
 5488      (function(win322) {
 5489        function escapePath2(source) {
 5490          assertPatternsInput2(source);
 5491          return utils.path.escapeWindowsPath(source);
 5492        }
 5493        win322.escapePath = escapePath2;
 5494        function convertPathToPattern3(source) {
 5495          assertPatternsInput2(source);
 5496          return utils.path.convertWindowsPathToPattern(source);
 5497        }
 5498        win322.convertPathToPattern = convertPathToPattern3;
 5499      })(win32 = FastGlob2.win32 || (FastGlob2.win32 = {}));
 5500    })(FastGlob || (FastGlob = {}));
 5501    function getWorks(source, _Provider, options) {
 5502      const patterns = [].concat(source);
 5503      const settings = new settings_1.default(options);
 5504      const tasks = taskManager.generate(patterns, settings);
 5505      const provider = new _Provider(settings);
 5506      return tasks.map(provider.read, provider);
 5507    }
 5508    function assertPatternsInput2(input) {
 5509      const source = [].concat(input);
 5510      const isValidSource = source.every((item) => utils.string.isString(item) && !utils.string.isEmpty(item));
 5511      if (!isValidSource) {
 5512        throw new TypeError("Patterns must be a string (non empty) or an array of strings");
 5513      }
 5514    }
 5515    module2.exports = FastGlob;
 5516  }
 5517});
 5518
 5519// node_modules/ignore/index.js
 5520var require_ignore = __commonJS({
 5521  "node_modules/ignore/index.js"(exports2, module2) {
 5522    "use strict";
 5523    function makeArray(subject) {
 5524      return Array.isArray(subject) ? subject : [subject];
 5525    }
 5526    var UNDEFINED = void 0;
 5527    var EMPTY = "";
 5528    var SPACE = " ";
 5529    var ESCAPE = "\\";
 5530    var REGEX_TEST_BLANK_LINE = /^\s+$/;
 5531    var REGEX_INVALID_TRAILING_BACKSLASH = /(?:[^\\]|^)\\$/;
 5532    var REGEX_REPLACE_LEADING_EXCAPED_EXCLAMATION = /^\\!/;
 5533    var REGEX_REPLACE_LEADING_EXCAPED_HASH = /^\\#/;
 5534    var REGEX_SPLITALL_CRLF = /\r?\n/g;
 5535    var REGEX_TEST_INVALID_PATH = /^\.{0,2}\/|^\.{1,2}$/;
 5536    var REGEX_TEST_TRAILING_SLASH = /\/$/;
 5537    var SLASH = "/";
 5538    var TMP_KEY_IGNORE = "node-ignore";
 5539    if (typeof Symbol !== "undefined") {
 5540      TMP_KEY_IGNORE = Symbol.for("node-ignore");
 5541    }
 5542    var KEY_IGNORE = TMP_KEY_IGNORE;
 5543    var define = (object, key, value) => {
 5544      Object.defineProperty(object, key, { value });
 5545      return value;
 5546    };
 5547    var REGEX_REGEXP_RANGE = /([0-z])-([0-z])/g;
 5548    var RETURN_FALSE = () => false;
 5549    var sanitizeRange = (range) => range.replace(
 5550      REGEX_REGEXP_RANGE,
 5551      (match, from, to) => from.charCodeAt(0) <= to.charCodeAt(0) ? match : EMPTY
 5552    );
 5553    var cleanRangeBackSlash = (slashes) => {
 5554      const { length } = slashes;
 5555      return slashes.slice(0, length - length % 2);
 5556    };
 5557    var REPLACERS = [
 5558      [
 5559        // Remove BOM
 5560        // TODO:
 5561        // Other similar zero-width characters?
 5562        /^\uFEFF/,
 5563        () => EMPTY
 5564      ],
 5565      // > Trailing spaces are ignored unless they are quoted with backslash ("\")
 5566      [
 5567        // (a\ ) -> (a )
 5568        // (a  ) -> (a)
 5569        // (a ) -> (a)
 5570        // (a \ ) -> (a  )
 5571        /((?:\\\\)*?)(\\?\s+)$/,
 5572        (_, m1, m2) => m1 + (m2.indexOf("\\") === 0 ? SPACE : EMPTY)
 5573      ],
 5574      // Replace (\ ) with ' '
 5575      // (\ ) -> ' '
 5576      // (\\ ) -> '\\ '
 5577      // (\\\ ) -> '\\ '
 5578      [
 5579        /(\\+?)\s/g,
 5580        (_, m1) => {
 5581          const { length } = m1;
 5582          return m1.slice(0, length - length % 2) + SPACE;
 5583        }
 5584      ],
 5585      // Escape metacharacters
 5586      // which is written down by users but means special for regular expressions.
 5587      // > There are 12 characters with special meanings:
 5588      // > - the backslash \,
 5589      // > - the caret ^,
 5590      // > - the dollar sign $,
 5591      // > - the period or dot .,
 5592      // > - the vertical bar or pipe symbol |,
 5593      // > - the question mark ?,
 5594      // > - the asterisk or star *,
 5595      // > - the plus sign +,
 5596      // > - the opening parenthesis (,
 5597      // > - the closing parenthesis ),
 5598      // > - and the opening square bracket [,
 5599      // > - the opening curly brace {,
 5600      // > These special characters are often called "metacharacters".
 5601      [
 5602        /[\\$.|*+(){^]/g,
 5603        (match) => `\\${match}`
 5604      ],
 5605      [
 5606        // > a question mark (?) matches a single character
 5607        /(?!\\)\?/g,
 5608        () => "[^/]"
 5609      ],
 5610      // leading slash
 5611      [
 5612        // > A leading slash matches the beginning of the pathname.
 5613        // > For example, "/*.c" matches "cat-file.c" but not "mozilla-sha1/sha1.c".
 5614        // A leading slash matches the beginning of the pathname
 5615        /^\//,
 5616        () => "^"
 5617      ],
 5618      // replace special metacharacter slash after the leading slash
 5619      [
 5620        /\//g,
 5621        () => "\\/"
 5622      ],
 5623      [
 5624        // > A leading "**" followed by a slash means match in all directories.
 5625        // > For example, "**/foo" matches file or directory "foo" anywhere,
 5626        // > the same as pattern "foo".
 5627        // > "**/foo/bar" matches file or directory "bar" anywhere that is directly
 5628        // >   under directory "foo".
 5629        // Notice that the '*'s have been replaced as '\\*'
 5630        /^\^*\\\*\\\*\\\//,
 5631        // '**/foo' <-> 'foo'
 5632        () => "^(?:.*\\/)?"
 5633      ],
 5634      // starting
 5635      [
 5636        // there will be no leading '/'
 5637        //   (which has been replaced by section "leading slash")
 5638        // If starts with '**', adding a '^' to the regular expression also works
 5639        /^(?=[^^])/,
 5640        function startingReplacer() {
 5641          return !/\/(?!$)/.test(this) ? "(?:^|\\/)" : "^";
 5642        }
 5643      ],
 5644      // two globstars
 5645      [
 5646        // Use lookahead assertions so that we could match more than one `'/**'`
 5647        /\\\/\\\*\\\*(?=\\\/|$)/g,
 5648        // Zero, one or several directories
 5649        // should not use '*', or it will be replaced by the next replacer
 5650        // Check if it is not the last `'/**'`
 5651        (_, index, str) => index + 6 < str.length ? "(?:\\/[^\\/]+)*" : "\\/.+"
 5652      ],
 5653      // normal intermediate wildcards
 5654      [
 5655        // Never replace escaped '*'
 5656        // ignore rule '\*' will match the path '*'
 5657        // 'abc.*/' -> go
 5658        // 'abc.*'  -> skip this rule,
 5659        //    coz trailing single wildcard will be handed by [trailing wildcard]
 5660        /(^|[^\\]+)(\\\*)+(?=.+)/g,
 5661        // '*.js' matches '.js'
 5662        // '*.js' doesn't match 'abc'
 5663        (_, p1, p2) => {
 5664          const unescaped = p2.replace(/\\\*/g, "[^\\/]*");
 5665          return p1 + unescaped;
 5666        }
 5667      ],
 5668      [
 5669        // unescape, revert step 3 except for back slash
 5670        // For example, if a user escape a '\\*',
 5671        // after step 3, the result will be '\\\\\\*'
 5672        /\\\\\\(?=[$.|*+(){^])/g,
 5673        () => ESCAPE
 5674      ],
 5675      [
 5676        // '\\\\' -> '\\'
 5677        /\\\\/g,
 5678        () => ESCAPE
 5679      ],
 5680      [
 5681        // > The range notation, e.g. [a-zA-Z],
 5682        // > can be used to match one of the characters in a range.
 5683        // `\` is escaped by step 3
 5684        /(\\)?\[([^\]/]*?)(\\*)($|\])/g,
 5685        (match, leadEscape, range, endEscape, close) => leadEscape === ESCAPE ? `\\[${range}${cleanRangeBackSlash(endEscape)}${close}` : close === "]" ? endEscape.length % 2 === 0 ? `[${sanitizeRange(range)}${endEscape}]` : "[]" : "[]"
 5686      ],
 5687      // ending
 5688      [
 5689        // 'js' will not match 'js.'
 5690        // 'ab' will not match 'abc'
 5691        /(?:[^*])$/,
 5692        // WTF!
 5693        // https://git-scm.com/docs/gitignore
 5694        // changes in [2.22.1](https://git-scm.com/docs/gitignore/2.22.1)
 5695        // which re-fixes #24, #38
 5696        // > If there is a separator at the end of the pattern then the pattern
 5697        // > will only match directories, otherwise the pattern can match both
 5698        // > files and directories.
 5699        // 'js*' will not match 'a.js'
 5700        // 'js/' will not match 'a.js'
 5701        // 'js' will match 'a.js' and 'a.js/'
 5702        (match) => /\/$/.test(match) ? `${match}$` : `${match}(?=$|\\/$)`
 5703      ]
 5704    ];
 5705    var REGEX_REPLACE_TRAILING_WILDCARD = /(^|\\\/)?\\\*$/;
 5706    var MODE_IGNORE = "regex";
 5707    var MODE_CHECK_IGNORE = "checkRegex";
 5708    var UNDERSCORE = "_";
 5709    var TRAILING_WILD_CARD_REPLACERS = {
 5710      [MODE_IGNORE](_, p1) {
 5711        const prefix = p1 ? `${p1}[^/]+` : "[^/]*";
 5712        return `${prefix}(?=$|\\/$)`;
 5713      },
 5714      [MODE_CHECK_IGNORE](_, p1) {
 5715        const prefix = p1 ? `${p1}[^/]*` : "[^/]*";
 5716        return `${prefix}(?=$|\\/$)`;
 5717      }
 5718    };
 5719    var makeRegexPrefix = (pattern) => REPLACERS.reduce(
 5720      (prev, [matcher, replacer]) => prev.replace(matcher, replacer.bind(pattern)),
 5721      pattern
 5722    );
 5723    var isString = (subject) => typeof subject === "string";
 5724    var checkPattern = (pattern) => pattern && isString(pattern) && !REGEX_TEST_BLANK_LINE.test(pattern) && !REGEX_INVALID_TRAILING_BACKSLASH.test(pattern) && pattern.indexOf("#") !== 0;
 5725    var splitPattern = (pattern) => pattern.split(REGEX_SPLITALL_CRLF).filter(Boolean);
 5726    var IgnoreRule = class {
 5727      constructor(pattern, mark, body, ignoreCase, negative, prefix) {
 5728        this.pattern = pattern;
 5729        this.mark = mark;
 5730        this.negative = negative;
 5731        define(this, "body", body);
 5732        define(this, "ignoreCase", ignoreCase);
 5733        define(this, "regexPrefix", prefix);
 5734      }
 5735      get regex() {
 5736        const key = UNDERSCORE + MODE_IGNORE;
 5737        if (this[key]) {
 5738          return this[key];
 5739        }
 5740        return this._make(MODE_IGNORE, key);
 5741      }
 5742      get checkRegex() {
 5743        const key = UNDERSCORE + MODE_CHECK_IGNORE;
 5744        if (this[key]) {
 5745          return this[key];
 5746        }
 5747        return this._make(MODE_CHECK_IGNORE, key);
 5748      }
 5749      _make(mode, key) {
 5750        const str = this.regexPrefix.replace(
 5751          REGEX_REPLACE_TRAILING_WILDCARD,
 5752          // It does not need to bind pattern
 5753          TRAILING_WILD_CARD_REPLACERS[mode]
 5754        );
 5755        const regex = this.ignoreCase ? new RegExp(str, "i") : new RegExp(str);
 5756        return define(this, key, regex);
 5757      }
 5758    };
 5759    var createRule = ({
 5760      pattern,
 5761      mark
 5762    }, ignoreCase) => {
 5763      let negative = false;
 5764      let body = pattern;
 5765      if (body.indexOf("!") === 0) {
 5766        negative = true;
 5767        body = body.substr(1);
 5768      }
 5769      body = body.replace(REGEX_REPLACE_LEADING_EXCAPED_EXCLAMATION, "!").replace(REGEX_REPLACE_LEADING_EXCAPED_HASH, "#");
 5770      const regexPrefix = makeRegexPrefix(body);
 5771      return new IgnoreRule(
 5772        pattern,
 5773        mark,
 5774        body,
 5775        ignoreCase,
 5776        negative,
 5777        regexPrefix
 5778      );
 5779    };
 5780    var RuleManager = class {
 5781      constructor(ignoreCase) {
 5782        this._ignoreCase = ignoreCase;
 5783        this._rules = [];
 5784      }
 5785      _add(pattern) {
 5786        if (pattern && pattern[KEY_IGNORE]) {
 5787          this._rules = this._rules.concat(pattern._rules._rules);
 5788          this._added = true;
 5789          return;
 5790        }
 5791        if (isString(pattern)) {
 5792          pattern = {
 5793            pattern
 5794          };
 5795        }
 5796        if (checkPattern(pattern.pattern)) {
 5797          const rule = createRule(pattern, this._ignoreCase);
 5798          this._added = true;
 5799          this._rules.push(rule);
 5800        }
 5801      }
 5802      // @param {Array<string> | string | Ignore} pattern
 5803      add(pattern) {
 5804        this._added = false;
 5805        makeArray(
 5806          isString(pattern) ? splitPattern(pattern) : pattern
 5807        ).forEach(this._add, this);
 5808        return this._added;
 5809      }
 5810      // Test one single path without recursively checking parent directories
 5811      //
 5812      // - checkUnignored `boolean` whether should check if the path is unignored,
 5813      //   setting `checkUnignored` to `false` could reduce additional
 5814      //   path matching.
 5815      // - check `string` either `MODE_IGNORE` or `MODE_CHECK_IGNORE`
 5816      // @returns {TestResult} true if a file is ignored
 5817      test(path5, checkUnignored, mode) {
 5818        let ignored = false;
 5819        let unignored = false;
 5820        let matchedRule;
 5821        this._rules.forEach((rule) => {
 5822          const { negative } = rule;
 5823          if (unignored === negative && ignored !== unignored || negative && !ignored && !unignored && !checkUnignored) {
 5824            return;
 5825          }
 5826          const matched = rule[mode].test(path5);
 5827          if (!matched) {
 5828            return;
 5829          }
 5830          ignored = !negative;
 5831          unignored = negative;
 5832          matchedRule = negative ? UNDEFINED : rule;
 5833        });
 5834        const ret = {
 5835          ignored,
 5836          unignored
 5837        };
 5838        if (matchedRule) {
 5839          ret.rule = matchedRule;
 5840        }
 5841        return ret;
 5842      }
 5843    };
 5844    var throwError = (message, Ctor) => {
 5845      throw new Ctor(message);
 5846    };
 5847    var checkPath = (path5, originalPath, doThrow) => {
 5848      if (!isString(path5)) {
 5849        return doThrow(
 5850          `path must be a string, but got \`${originalPath}\``,
 5851          TypeError
 5852        );
 5853      }
 5854      if (!path5) {
 5855        return doThrow(`path must not be empty`, TypeError);
 5856      }
 5857      if (checkPath.isNotRelative(path5)) {
 5858        const r2 = "`path.relative()`d";
 5859        return doThrow(
 5860          `path should be a ${r2} string, but got "${originalPath}"`,
 5861          RangeError
 5862        );
 5863      }
 5864      return true;
 5865    };
 5866    var isNotRelative = (path5) => REGEX_TEST_INVALID_PATH.test(path5);
 5867    checkPath.isNotRelative = isNotRelative;
 5868    checkPath.convert = (p2) => p2;
 5869    var Ignore = class {
 5870      constructor({
 5871        ignorecase = true,
 5872        ignoreCase = ignorecase,
 5873        allowRelativePaths = false
 5874      } = {}) {
 5875        define(this, KEY_IGNORE, true);
 5876        this._rules = new RuleManager(ignoreCase);
 5877        this._strictPathCheck = !allowRelativePaths;
 5878        this._initCache();
 5879      }
 5880      _initCache() {
 5881        this._ignoreCache = /* @__PURE__ */ Object.create(null);
 5882        this._testCache = /* @__PURE__ */ Object.create(null);
 5883      }
 5884      add(pattern) {
 5885        if (this._rules.add(pattern)) {
 5886          this._initCache();
 5887        }
 5888        return this;
 5889      }
 5890      // legacy
 5891      addPattern(pattern) {
 5892        return this.add(pattern);
 5893      }
 5894      // @returns {TestResult}
 5895      _test(originalPath, cache, checkUnignored, slices) {
 5896        const path5 = originalPath && checkPath.convert(originalPath);
 5897        checkPath(
 5898          path5,
 5899          originalPath,
 5900          this._strictPathCheck ? throwError : RETURN_FALSE
 5901        );
 5902        return this._t(path5, cache, checkUnignored, slices);
 5903      }
 5904      checkIgnore(path5) {
 5905        if (!REGEX_TEST_TRAILING_SLASH.test(path5)) {
 5906          return this.test(path5);
 5907        }
 5908        const slices = path5.split(SLASH).filter(Boolean);
 5909        slices.pop();
 5910        if (slices.length) {
 5911          const parent = this._t(
 5912            slices.join(SLASH) + SLASH,
 5913            this._testCache,
 5914            true,
 5915            slices
 5916          );
 5917          if (parent.ignored) {
 5918            return parent;
 5919          }
 5920        }
 5921        return this._rules.test(path5, false, MODE_CHECK_IGNORE);
 5922      }
 5923      _t(path5, cache, checkUnignored, slices) {
 5924        if (path5 in cache) {
 5925          return cache[path5];
 5926        }
 5927        if (!slices) {
 5928          slices = path5.split(SLASH).filter(Boolean);
 5929        }
 5930        slices.pop();
 5931        if (!slices.length) {
 5932          return cache[path5] = this._rules.test(path5, checkUnignored, MODE_IGNORE);
 5933        }
 5934        const parent = this._t(
 5935          slices.join(SLASH) + SLASH,
 5936          cache,
 5937          checkUnignored,
 5938          slices
 5939        );
 5940        return cache[path5] = parent.ignored ? parent : this._rules.test(path5, checkUnignored, MODE_IGNORE);
 5941      }
 5942      ignores(path5) {
 5943        return this._test(path5, this._ignoreCache, false).ignored;
 5944      }
 5945      createFilter() {
 5946        return (path5) => !this.ignores(path5);
 5947      }
 5948      filter(paths) {
 5949        return makeArray(paths).filter(this.createFilter());
 5950      }
 5951      // @returns {TestResult}
 5952      test(path5) {
 5953        return this._test(path5, this._testCache, true);
 5954      }
 5955    };
 5956    var factory = (options) => new Ignore(options);
 5957    var isPathValid = (path5) => checkPath(path5 && checkPath.convert(path5), path5, RETURN_FALSE);
 5958    var setupWindows = () => {
 5959      const makePosix = (str) => /^\\\\\?\\/.test(str) || /["<>|\u0000-\u001F]+/u.test(str) ? str : str.replace(/\\/g, "/");
 5960      checkPath.convert = makePosix;
 5961      const REGEX_TEST_WINDOWS_PATH_ABSOLUTE = /^[a-z]:\//i;
 5962      checkPath.isNotRelative = (path5) => REGEX_TEST_WINDOWS_PATH_ABSOLUTE.test(path5) || isNotRelative(path5);
 5963    };
 5964    if (
 5965      // Detect `process` so that it can run in browsers.
 5966      typeof process !== "undefined" && process.platform === "win32"
 5967    ) {
 5968      setupWindows();
 5969    }
 5970    module2.exports = factory;
 5971    factory.default = factory;
 5972    module2.exports.isPathValid = isPathValid;
 5973    define(module2.exports, Symbol.for("setupWindows"), setupWindows);
 5974  }
 5975});
 5976
 5977// node_modules/universalify/index.js
 5978var require_universalify = __commonJS({
 5979  "node_modules/universalify/index.js"(exports2) {
 5980    "use strict";
 5981    exports2.fromCallback = function(fn) {
 5982      return Object.defineProperty(function(...args) {
 5983        if (typeof args[args.length - 1] === "function") fn.apply(this, args);
 5984        else {
 5985          return new Promise((resolve, reject) => {
 5986            args.push((err, res) => err != null ? reject(err) : resolve(res));
 5987            fn.apply(this, args);
 5988          });
 5989        }
 5990      }, "name", { value: fn.name });
 5991    };
 5992    exports2.fromPromise = function(fn) {
 5993      return Object.defineProperty(function(...args) {
 5994        const cb = args[args.length - 1];
 5995        if (typeof cb !== "function") return fn.apply(this, args);
 5996        else {
 5997          args.pop();
 5998          fn.apply(this, args).then((r2) => cb(null, r2), cb);
 5999        }
 6000      }, "name", { value: fn.name });
 6001    };
 6002  }
 6003});
 6004
 6005// node_modules/graceful-fs/polyfills.js
 6006var require_polyfills = __commonJS({
 6007  "node_modules/graceful-fs/polyfills.js"(exports2, module2) {
 6008    "use strict";
 6009    var constants = require("constants");
 6010    var origCwd = process.cwd;
 6011    var cwd = null;
 6012    var platform = process.env.GRACEFUL_FS_PLATFORM || process.platform;
 6013    process.cwd = function() {
 6014      if (!cwd)
 6015        cwd = origCwd.call(process);
 6016      return cwd;
 6017    };
 6018    try {
 6019      process.cwd();
 6020    } catch (er) {
 6021    }
 6022    if (typeof process.chdir === "function") {
 6023      chdir = process.chdir;
 6024      process.chdir = function(d) {
 6025        cwd = null;
 6026        chdir.call(process, d);
 6027      };
 6028      if (Object.setPrototypeOf) Object.setPrototypeOf(process.chdir, chdir);
 6029    }
 6030    var chdir;
 6031    module2.exports = patch;
 6032    function patch(fs6) {
 6033      if (constants.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)) {
 6034        patchLchmod(fs6);
 6035      }
 6036      if (!fs6.lutimes) {
 6037        patchLutimes(fs6);
 6038      }
 6039      fs6.chown = chownFix(fs6.chown);
 6040      fs6.fchown = chownFix(fs6.fchown);
 6041      fs6.lchown = chownFix(fs6.lchown);
 6042      fs6.chmod = chmodFix(fs6.chmod);
 6043      fs6.fchmod = chmodFix(fs6.fchmod);
 6044      fs6.lchmod = chmodFix(fs6.lchmod);
 6045      fs6.chownSync = chownFixSync(fs6.chownSync);
 6046      fs6.fchownSync = chownFixSync(fs6.fchownSync);
 6047      fs6.lchownSync = chownFixSync(fs6.lchownSync);
 6048      fs6.chmodSync = chmodFixSync(fs6.chmodSync);
 6049      fs6.fchmodSync = chmodFixSync(fs6.fchmodSync);
 6050      fs6.lchmodSync = chmodFixSync(fs6.lchmodSync);
 6051      fs6.stat = statFix(fs6.stat);
 6052      fs6.fstat = statFix(fs6.fstat);
 6053      fs6.lstat = statFix(fs6.lstat);
 6054      fs6.statSync = statFixSync(fs6.statSync);
 6055      fs6.fstatSync = statFixSync(fs6.fstatSync);
 6056      fs6.lstatSync = statFixSync(fs6.lstatSync);
 6057      if (fs6.chmod && !fs6.lchmod) {
 6058        fs6.lchmod = function(path5, mode, cb) {
 6059          if (cb) process.nextTick(cb);
 6060        };
 6061        fs6.lchmodSync = function() {
 6062        };
 6063      }
 6064      if (fs6.chown && !fs6.lchown) {
 6065        fs6.lchown = function(path5, uid, gid, cb) {
 6066          if (cb) process.nextTick(cb);
 6067        };
 6068        fs6.lchownSync = function() {
 6069        };
 6070      }
 6071      if (platform === "win32") {
 6072        fs6.rename = typeof fs6.rename !== "function" ? fs6.rename : (function(fs$rename) {
 6073          function rename(from, to, cb) {
 6074            var start = Date.now();
 6075            var backoff = 0;
 6076            fs$rename(from, to, function CB(er) {
 6077              if (er && (er.code === "EACCES" || er.code === "EPERM" || er.code === "EBUSY") && Date.now() - start < 6e4) {
 6078                setTimeout(function() {
 6079                  fs6.stat(to, function(stater, st2) {
 6080                    if (stater && stater.code === "ENOENT")
 6081                      fs$rename(from, to, CB);
 6082                    else
 6083                      cb(er);
 6084                  });
 6085                }, backoff);
 6086                if (backoff < 100)
 6087                  backoff += 10;
 6088                return;
 6089              }
 6090              if (cb) cb(er);
 6091            });
 6092          }
 6093          if (Object.setPrototypeOf) Object.setPrototypeOf(rename, fs$rename);
 6094          return rename;
 6095        })(fs6.rename);
 6096      }
 6097      fs6.read = typeof fs6.read !== "function" ? fs6.read : (function(fs$read) {
 6098        function read(fd, buffer, offset, length, position, callback_) {
 6099          var callback;
 6100          if (callback_ && typeof callback_ === "function") {
 6101            var eagCounter = 0;
 6102            callback = function(er, _, __) {
 6103              if (er && er.code === "EAGAIN" && eagCounter < 10) {
 6104                eagCounter++;
 6105                return fs$read.call(fs6, fd, buffer, offset, length, position, callback);
 6106              }
 6107              callback_.apply(this, arguments);
 6108            };
 6109          }
 6110          return fs$read.call(fs6, fd, buffer, offset, length, position, callback);
 6111        }
 6112        if (Object.setPrototypeOf) Object.setPrototypeOf(read, fs$read);
 6113        return read;
 6114      })(fs6.read);
 6115      fs6.readSync = typeof fs6.readSync !== "function" ? fs6.readSync : /* @__PURE__ */ (function(fs$readSync) {
 6116        return function(fd, buffer, offset, length, position) {
 6117          var eagCounter = 0;
 6118          while (true) {
 6119            try {
 6120              return fs$readSync.call(fs6, fd, buffer, offset, length, position);
 6121            } catch (er) {
 6122              if (er.code === "EAGAIN" && eagCounter < 10) {
 6123                eagCounter++;
 6124                continue;
 6125              }
 6126              throw er;
 6127            }
 6128          }
 6129        };
 6130      })(fs6.readSync);
 6131      function patchLchmod(fs7) {
 6132        fs7.lchmod = function(path5, mode, callback) {
 6133          fs7.open(
 6134            path5,
 6135            constants.O_WRONLY | constants.O_SYMLINK,
 6136            mode,
 6137            function(err, fd) {
 6138              if (err) {
 6139                if (callback) callback(err);
 6140                return;
 6141              }
 6142              fs7.fchmod(fd, mode, function(err2) {
 6143                fs7.close(fd, function(err22) {
 6144                  if (callback) callback(err2 || err22);
 6145                });
 6146              });
 6147            }
 6148          );
 6149        };
 6150        fs7.lchmodSync = function(path5, mode) {
 6151          var fd = fs7.openSync(path5, constants.O_WRONLY | constants.O_SYMLINK, mode);
 6152          var threw = true;
 6153          var ret;
 6154          try {
 6155            ret = fs7.fchmodSync(fd, mode);
 6156            threw = false;
 6157          } finally {
 6158            if (threw) {
 6159              try {
 6160                fs7.closeSync(fd);
 6161              } catch (er) {
 6162              }
 6163            } else {
 6164              fs7.closeSync(fd);
 6165            }
 6166          }
 6167          return ret;
 6168        };
 6169      }
 6170      function patchLutimes(fs7) {
 6171        if (constants.hasOwnProperty("O_SYMLINK") && fs7.futimes) {
 6172          fs7.lutimes = function(path5, at, mt2, cb) {
 6173            fs7.open(path5, constants.O_SYMLINK, function(er, fd) {
 6174              if (er) {
 6175                if (cb) cb(er);
 6176                return;
 6177              }
 6178              fs7.futimes(fd, at, mt2, function(er2) {
 6179                fs7.close(fd, function(er22) {
 6180                  if (cb) cb(er2 || er22);
 6181                });
 6182              });
 6183            });
 6184          };
 6185          fs7.lutimesSync = function(path5, at, mt2) {
 6186            var fd = fs7.openSync(path5, constants.O_SYMLINK);
 6187            var ret;
 6188            var threw = true;
 6189            try {
 6190              ret = fs7.futimesSync(fd, at, mt2);
 6191              threw = false;
 6192            } finally {
 6193              if (threw) {
 6194                try {
 6195                  fs7.closeSync(fd);
 6196                } catch (er) {
 6197                }
 6198              } else {
 6199                fs7.closeSync(fd);
 6200              }
 6201            }
 6202            return ret;
 6203          };
 6204        } else if (fs7.futimes) {
 6205          fs7.lutimes = function(_a2, _b2, _c, cb) {
 6206            if (cb) process.nextTick(cb);
 6207          };
 6208          fs7.lutimesSync = function() {
 6209          };
 6210        }
 6211      }
 6212      function chmodFix(orig) {
 6213        if (!orig) return orig;
 6214        return function(target, mode, cb) {
 6215          return orig.call(fs6, target, mode, function(er) {
 6216            if (chownErOk(er)) er = null;
 6217            if (cb) cb.apply(this, arguments);
 6218          });
 6219        };
 6220      }
 6221      function chmodFixSync(orig) {
 6222        if (!orig) return orig;
 6223        return function(target, mode) {
 6224          try {
 6225            return orig.call(fs6, target, mode);
 6226          } catch (er) {
 6227            if (!chownErOk(er)) throw er;
 6228          }
 6229        };
 6230      }
 6231      function chownFix(orig) {
 6232        if (!orig) return orig;
 6233        return function(target, uid, gid, cb) {
 6234          return orig.call(fs6, target, uid, gid, function(er) {
 6235            if (chownErOk(er)) er = null;
 6236            if (cb) cb.apply(this, arguments);
 6237          });
 6238        };
 6239      }
 6240      function chownFixSync(orig) {
 6241        if (!orig) return orig;
 6242        return function(target, uid, gid) {
 6243          try {
 6244            return orig.call(fs6, target, uid, gid);
 6245          } catch (er) {
 6246            if (!chownErOk(er)) throw er;
 6247          }
 6248        };
 6249      }
 6250      function statFix(orig) {
 6251        if (!orig) return orig;
 6252        return function(target, options, cb) {
 6253          if (typeof options === "function") {
 6254            cb = options;
 6255            options = null;
 6256          }
 6257          function callback(er, stats) {
 6258            if (stats) {
 6259              if (stats.uid < 0) stats.uid += 4294967296;
 6260              if (stats.gid < 0) stats.gid += 4294967296;
 6261            }
 6262            if (cb) cb.apply(this, arguments);
 6263          }
 6264          return options ? orig.call(fs6, target, options, callback) : orig.call(fs6, target, callback);
 6265        };
 6266      }
 6267      function statFixSync(orig) {
 6268        if (!orig) return orig;
 6269        return function(target, options) {
 6270          var stats = options ? orig.call(fs6, target, options) : orig.call(fs6, target);
 6271          if (stats) {
 6272            if (stats.uid < 0) stats.uid += 4294967296;
 6273            if (stats.gid < 0) stats.gid += 4294967296;
 6274          }
 6275          return stats;
 6276        };
 6277      }
 6278      function chownErOk(er) {
 6279        if (!er)
 6280          return true;
 6281        if (er.code === "ENOSYS")
 6282          return true;
 6283        var nonroot = !process.getuid || process.getuid() !== 0;
 6284        if (nonroot) {
 6285          if (er.code === "EINVAL" || er.code === "EPERM")
 6286            return true;
 6287        }
 6288        return false;
 6289      }
 6290    }
 6291  }
 6292});
 6293
 6294// node_modules/graceful-fs/legacy-streams.js
 6295var require_legacy_streams = __commonJS({
 6296  "node_modules/graceful-fs/legacy-streams.js"(exports2, module2) {
 6297    "use strict";
 6298    var Stream = require("stream").Stream;
 6299    module2.exports = legacy;
 6300    function legacy(fs6) {
 6301      return {
 6302        ReadStream,
 6303        WriteStream
 6304      };
 6305      function ReadStream(path5, options) {
 6306        if (!(this instanceof ReadStream)) return new ReadStream(path5, options);
 6307        Stream.call(this);
 6308        var self2 = this;
 6309        this.path = path5;
 6310        this.fd = null;
 6311        this.readable = true;
 6312        this.paused = false;
 6313        this.flags = "r";
 6314        this.mode = 438;
 6315        this.bufferSize = 64 * 1024;
 6316        options = options || {};
 6317        var keys = Object.keys(options);
 6318        for (var index = 0, length = keys.length; index < length; index++) {
 6319          var key = keys[index];
 6320          this[key] = options[key];
 6321        }
 6322        if (this.encoding) this.setEncoding(this.encoding);
 6323        if (this.start !== void 0) {
 6324          if ("number" !== typeof this.start) {
 6325            throw TypeError("start must be a Number");
 6326          }
 6327          if (this.end === void 0) {
 6328            this.end = Infinity;
 6329          } else if ("number" !== typeof this.end) {
 6330            throw TypeError("end must be a Number");
 6331          }
 6332          if (this.start > this.end) {
 6333            throw new Error("start must be <= end");
 6334          }
 6335          this.pos = this.start;
 6336        }
 6337        if (this.fd !== null) {
 6338          process.nextTick(function() {
 6339            self2._read();
 6340          });
 6341          return;
 6342        }
 6343        fs6.open(this.path, this.flags, this.mode, function(err, fd) {
 6344          if (err) {
 6345            self2.emit("error", err);
 6346            self2.readable = false;
 6347            return;
 6348          }
 6349          self2.fd = fd;
 6350          self2.emit("open", fd);
 6351          self2._read();
 6352        });
 6353      }
 6354      function WriteStream(path5, options) {
 6355        if (!(this instanceof WriteStream)) return new WriteStream(path5, options);
 6356        Stream.call(this);
 6357        this.path = path5;
 6358        this.fd = null;
 6359        this.writable = true;
 6360        this.flags = "w";
 6361        this.encoding = "binary";
 6362        this.mode = 438;
 6363        this.bytesWritten = 0;
 6364        options = options || {};
 6365        var keys = Object.keys(options);
 6366        for (var index = 0, length = keys.length; index < length; index++) {
 6367          var key = keys[index];
 6368          this[key] = options[key];
 6369        }
 6370        if (this.start !== void 0) {
 6371          if ("number" !== typeof this.start) {
 6372            throw TypeError("start must be a Number");
 6373          }
 6374          if (this.start < 0) {
 6375            throw new Error("start must be >= zero");
 6376          }
 6377          this.pos = this.start;
 6378        }
 6379        this.busy = false;
 6380        this._queue = [];
 6381        if (this.fd === null) {
 6382          this._open = fs6.open;
 6383          this._queue.push([this._open, this.path, this.flags, this.mode, void 0]);
 6384          this.flush();
 6385        }
 6386      }
 6387    }
 6388  }
 6389});
 6390
 6391// node_modules/graceful-fs/clone.js
 6392var require_clone = __commonJS({
 6393  "node_modules/graceful-fs/clone.js"(exports2, module2) {
 6394    "use strict";
 6395    module2.exports = clone;
 6396    var getPrototypeOf = Object.getPrototypeOf || function(obj) {
 6397      return obj.__proto__;
 6398    };
 6399    function clone(obj) {
 6400      if (obj === null || typeof obj !== "object")
 6401        return obj;
 6402      if (obj instanceof Object)
 6403        var copy = { __proto__: getPrototypeOf(obj) };
 6404      else
 6405        var copy = /* @__PURE__ */ Object.create(null);
 6406      Object.getOwnPropertyNames(obj).forEach(function(key) {
 6407        Object.defineProperty(copy, key, Object.getOwnPropertyDescriptor(obj, key));
 6408      });
 6409      return copy;
 6410    }
 6411  }
 6412});
 6413
 6414// node_modules/graceful-fs/graceful-fs.js
 6415var require_graceful_fs = __commonJS({
 6416  "node_modules/graceful-fs/graceful-fs.js"(exports2, module2) {
 6417    "use strict";
 6418    var fs6 = require("fs");
 6419    var polyfills = require_polyfills();
 6420    var legacy = require_legacy_streams();
 6421    var clone = require_clone();
 6422    var util = require("util");
 6423    var gracefulQueue;
 6424    var previousSymbol;
 6425    if (typeof Symbol === "function" && typeof Symbol.for === "function") {
 6426      gracefulQueue = Symbol.for("graceful-fs.queue");
 6427      previousSymbol = Symbol.for("graceful-fs.previous");
 6428    } else {
 6429      gracefulQueue = "___graceful-fs.queue";
 6430      previousSymbol = "___graceful-fs.previous";
 6431    }
 6432    function noop2() {
 6433    }
 6434    function publishQueue(context, queue2) {
 6435      Object.defineProperty(context, gracefulQueue, {
 6436        get: function() {
 6437          return queue2;
 6438        }
 6439      });
 6440    }
 6441    var debug = noop2;
 6442    if (util.debuglog)
 6443      debug = util.debuglog("gfs4");
 6444    else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || ""))
 6445      debug = function() {
 6446        var m2 = util.format.apply(util, arguments);
 6447        m2 = "GFS4: " + m2.split(/\n/).join("\nGFS4: ");
 6448        console.error(m2);
 6449      };
 6450    if (!fs6[gracefulQueue]) {
 6451      queue = global[gracefulQueue] || [];
 6452      publishQueue(fs6, queue);
 6453      fs6.close = (function(fs$close) {
 6454        function close(fd, cb) {
 6455          return fs$close.call(fs6, fd, function(err) {
 6456            if (!err) {
 6457              resetQueue();
 6458            }
 6459            if (typeof cb === "function")
 6460              cb.apply(this, arguments);
 6461          });
 6462        }
 6463        Object.defineProperty(close, previousSymbol, {
 6464          value: fs$close
 6465        });
 6466        return close;
 6467      })(fs6.close);
 6468      fs6.closeSync = (function(fs$closeSync) {
 6469        function closeSync(fd) {
 6470          fs$closeSync.apply(fs6, arguments);
 6471          resetQueue();
 6472        }
 6473        Object.defineProperty(closeSync, previousSymbol, {
 6474          value: fs$closeSync
 6475        });
 6476        return closeSync;
 6477      })(fs6.closeSync);
 6478      if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) {
 6479        process.on("exit", function() {
 6480          debug(fs6[gracefulQueue]);
 6481          require("assert").equal(fs6[gracefulQueue].length, 0);
 6482        });
 6483      }
 6484    }
 6485    var queue;
 6486    if (!global[gracefulQueue]) {
 6487      publishQueue(global, fs6[gracefulQueue]);
 6488    }
 6489    module2.exports = patch(clone(fs6));
 6490    if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs6.__patched) {
 6491      module2.exports = patch(fs6);
 6492      fs6.__patched = true;
 6493    }
 6494    function patch(fs7) {
 6495      polyfills(fs7);
 6496      fs7.gracefulify = patch;
 6497      fs7.createReadStream = createReadStream;
 6498      fs7.createWriteStream = createWriteStream;
 6499      var fs$readFile = fs7.readFile;
 6500      fs7.readFile = readFile;
 6501      function readFile(path5, options, cb) {
 6502        if (typeof options === "function")
 6503          cb = options, options = null;
 6504        return go$readFile(path5, options, cb);
 6505        function go$readFile(path6, options2, cb2, startTime) {
 6506          return fs$readFile(path6, options2, function(err) {
 6507            if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
 6508              enqueue([go$readFile, [path6, options2, cb2], err, startTime || Date.now(), Date.now()]);
 6509            else {
 6510              if (typeof cb2 === "function")
 6511                cb2.apply(this, arguments);
 6512            }
 6513          });
 6514        }
 6515      }
 6516      var fs$writeFile = fs7.writeFile;
 6517      fs7.writeFile = writeFile;
 6518      function writeFile(path5, data, options, cb) {
 6519        if (typeof options === "function")
 6520          cb = options, options = null;
 6521        return go$writeFile(path5, data, options, cb);
 6522        function go$writeFile(path6, data2, options2, cb2, startTime) {
 6523          return fs$writeFile(path6, data2, options2, function(err) {
 6524            if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
 6525              enqueue([go$writeFile, [path6, data2, options2, cb2], err, startTime || Date.now(), Date.now()]);
 6526            else {
 6527              if (typeof cb2 === "function")
 6528                cb2.apply(this, arguments);
 6529            }
 6530          });
 6531        }
 6532      }
 6533      var fs$appendFile = fs7.appendFile;
 6534      if (fs$appendFile)
 6535        fs7.appendFile = appendFile;
 6536      function appendFile(path5, data, options, cb) {
 6537        if (typeof options === "function")
 6538          cb = options, options = null;
 6539        return go$appendFile(path5, data, options, cb);
 6540        function go$appendFile(path6, data2, options2, cb2, startTime) {
 6541          return fs$appendFile(path6, data2, options2, function(err) {
 6542            if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
 6543              enqueue([go$appendFile, [path6, data2, options2, cb2], err, startTime || Date.now(), Date.now()]);
 6544            else {
 6545              if (typeof cb2 === "function")
 6546                cb2.apply(this, arguments);
 6547            }
 6548          });
 6549        }
 6550      }
 6551      var fs$copyFile = fs7.copyFile;
 6552      if (fs$copyFile)
 6553        fs7.copyFile = copyFile;
 6554      function copyFile(src, dest, flags, cb) {
 6555        if (typeof flags === "function") {
 6556          cb = flags;
 6557          flags = 0;
 6558        }
 6559        return go$copyFile(src, dest, flags, cb);
 6560        function go$copyFile(src2, dest2, flags2, cb2, startTime) {
 6561          return fs$copyFile(src2, dest2, flags2, function(err) {
 6562            if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
 6563              enqueue([go$copyFile, [src2, dest2, flags2, cb2], err, startTime || Date.now(), Date.now()]);
 6564            else {
 6565              if (typeof cb2 === "function")
 6566                cb2.apply(this, arguments);
 6567            }
 6568          });
 6569        }
 6570      }
 6571      var fs$readdir = fs7.readdir;
 6572      fs7.readdir = readdir;
 6573      var noReaddirOptionVersions = /^v[0-5]\./;
 6574      function readdir(path5, options, cb) {
 6575        if (typeof options === "function")
 6576          cb = options, options = null;
 6577        var go$readdir = noReaddirOptionVersions.test(process.version) ? function go$readdir2(path6, options2, cb2, startTime) {
 6578          return fs$readdir(path6, fs$readdirCallback(
 6579            path6,
 6580            options2,
 6581            cb2,
 6582            startTime
 6583          ));
 6584        } : function go$readdir2(path6, options2, cb2, startTime) {
 6585          return fs$readdir(path6, options2, fs$readdirCallback(
 6586            path6,
 6587            options2,
 6588            cb2,
 6589            startTime
 6590          ));
 6591        };
 6592        return go$readdir(path5, options, cb);
 6593        function fs$readdirCallback(path6, options2, cb2, startTime) {
 6594          return function(err, files) {
 6595            if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
 6596              enqueue([
 6597                go$readdir,
 6598                [path6, options2, cb2],
 6599                err,
 6600                startTime || Date.now(),
 6601                Date.now()
 6602              ]);
 6603            else {
 6604              if (files && files.sort)
 6605                files.sort();
 6606              if (typeof cb2 === "function")
 6607                cb2.call(this, err, files);
 6608            }
 6609          };
 6610        }
 6611      }
 6612      if (process.version.substr(0, 4) === "v0.8") {
 6613        var legStreams = legacy(fs7);
 6614        ReadStream = legStreams.ReadStream;
 6615        WriteStream = legStreams.WriteStream;
 6616      }
 6617      var fs$ReadStream = fs7.ReadStream;
 6618      if (fs$ReadStream) {
 6619        ReadStream.prototype = Object.create(fs$ReadStream.prototype);
 6620        ReadStream.prototype.open = ReadStream$open;
 6621      }
 6622      var fs$WriteStream = fs7.WriteStream;
 6623      if (fs$WriteStream) {
 6624        WriteStream.prototype = Object.create(fs$WriteStream.prototype);
 6625        WriteStream.prototype.open = WriteStream$open;
 6626      }
 6627      Object.defineProperty(fs7, "ReadStream", {
 6628        get: function() {
 6629          return ReadStream;
 6630        },
 6631        set: function(val) {
 6632          ReadStream = val;
 6633        },
 6634        enumerable: true,
 6635        configurable: true
 6636      });
 6637      Object.defineProperty(fs7, "WriteStream", {
 6638        get: function() {
 6639          return WriteStream;
 6640        },
 6641        set: function(val) {
 6642          WriteStream = val;
 6643        },
 6644        enumerable: true,
 6645        configurable: true
 6646      });
 6647      var FileReadStream = ReadStream;
 6648      Object.defineProperty(fs7, "FileReadStream", {
 6649        get: function() {
 6650          return FileReadStream;
 6651        },
 6652        set: function(val) {
 6653          FileReadStream = val;
 6654        },
 6655        enumerable: true,
 6656        configurable: true
 6657      });
 6658      var FileWriteStream = WriteStream;
 6659      Object.defineProperty(fs7, "FileWriteStream", {
 6660        get: function() {
 6661          return FileWriteStream;
 6662        },
 6663        set: function(val) {
 6664          FileWriteStream = val;
 6665        },
 6666        enumerable: true,
 6667        configurable: true
 6668      });
 6669      function ReadStream(path5, options) {
 6670        if (this instanceof ReadStream)
 6671          return fs$ReadStream.apply(this, arguments), this;
 6672        else
 6673          return ReadStream.apply(Object.create(ReadStream.prototype), arguments);
 6674      }
 6675      function ReadStream$open() {
 6676        var that = this;
 6677        open(that.path, that.flags, that.mode, function(err, fd) {
 6678          if (err) {
 6679            if (that.autoClose)
 6680              that.destroy();
 6681            that.emit("error", err);
 6682          } else {
 6683            that.fd = fd;
 6684            that.emit("open", fd);
 6685            that.read();
 6686          }
 6687        });
 6688      }
 6689      function WriteStream(path5, options) {
 6690        if (this instanceof WriteStream)
 6691          return fs$WriteStream.apply(this, arguments), this;
 6692        else
 6693          return WriteStream.apply(Object.create(WriteStream.prototype), arguments);
 6694      }
 6695      function WriteStream$open() {
 6696        var that = this;
 6697        open(that.path, that.flags, that.mode, function(err, fd) {
 6698          if (err) {
 6699            that.destroy();
 6700            that.emit("error", err);
 6701          } else {
 6702            that.fd = fd;
 6703            that.emit("open", fd);
 6704          }
 6705        });
 6706      }
 6707      function createReadStream(path5, options) {
 6708        return new fs7.ReadStream(path5, options);
 6709      }
 6710      function createWriteStream(path5, options) {
 6711        return new fs7.WriteStream(path5, options);
 6712      }
 6713      var fs$open = fs7.open;
 6714      fs7.open = open;
 6715      function open(path5, flags, mode, cb) {
 6716        if (typeof mode === "function")
 6717          cb = mode, mode = null;
 6718        return go$open(path5, flags, mode, cb);
 6719        function go$open(path6, flags2, mode2, cb2, startTime) {
 6720          return fs$open(path6, flags2, mode2, function(err, fd) {
 6721            if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
 6722              enqueue([go$open, [path6, flags2, mode2, cb2], err, startTime || Date.now(), Date.now()]);
 6723            else {
 6724              if (typeof cb2 === "function")
 6725                cb2.apply(this, arguments);
 6726            }
 6727          });
 6728        }
 6729      }
 6730      return fs7;
 6731    }
 6732    function enqueue(elem) {
 6733      debug("ENQUEUE", elem[0].name, elem[1]);
 6734      fs6[gracefulQueue].push(elem);
 6735      retry();
 6736    }
 6737    var retryTimer;
 6738    function resetQueue() {
 6739      var now = Date.now();
 6740      for (var i = 0; i < fs6[gracefulQueue].length; ++i) {
 6741        if (fs6[gracefulQueue][i].length > 2) {
 6742          fs6[gracefulQueue][i][3] = now;
 6743          fs6[gracefulQueue][i][4] = now;
 6744        }
 6745      }
 6746      retry();
 6747    }
 6748    function retry() {
 6749      clearTimeout(retryTimer);
 6750      retryTimer = void 0;
 6751      if (fs6[gracefulQueue].length === 0)
 6752        return;
 6753      var elem = fs6[gracefulQueue].shift();
 6754      var fn = elem[0];
 6755      var args = elem[1];
 6756      var err = elem[2];
 6757      var startTime = elem[3];
 6758      var lastTime = elem[4];
 6759      if (startTime === void 0) {
 6760        debug("RETRY", fn.name, args);
 6761        fn.apply(null, args);
 6762      } else if (Date.now() - startTime >= 6e4) {
 6763        debug("TIMEOUT", fn.name, args);
 6764        var cb = args.pop();
 6765        if (typeof cb === "function")
 6766          cb.call(null, err);
 6767      } else {
 6768        var sinceAttempt = Date.now() - lastTime;
 6769        var sinceStart = Math.max(lastTime - startTime, 1);
 6770        var desiredDelay = Math.min(sinceStart * 1.2, 100);
 6771        if (sinceAttempt >= desiredDelay) {
 6772          debug("RETRY", fn.name, args);
 6773          fn.apply(null, args.concat([startTime]));
 6774        } else {
 6775          fs6[gracefulQueue].push(elem);
 6776        }
 6777      }
 6778      if (retryTimer === void 0) {
 6779        retryTimer = setTimeout(retry, 0);
 6780      }
 6781    }
 6782  }
 6783});
 6784
 6785// node_modules/fs-extra/lib/fs/index.js
 6786var require_fs5 = __commonJS({
 6787  "node_modules/fs-extra/lib/fs/index.js"(exports2) {
 6788    "use strict";
 6789    var u = require_universalify().fromCallback;
 6790    var fs6 = require_graceful_fs();
 6791    var api = [
 6792      "access",
 6793      "appendFile",
 6794      "chmod",
 6795      "chown",
 6796      "close",
 6797      "copyFile",
 6798      "cp",
 6799      "fchmod",
 6800      "fchown",
 6801      "fdatasync",
 6802      "fstat",
 6803      "fsync",
 6804      "ftruncate",
 6805      "futimes",
 6806      "glob",
 6807      "lchmod",
 6808      "lchown",
 6809      "lutimes",
 6810      "link",
 6811      "lstat",
 6812      "mkdir",
 6813      "mkdtemp",
 6814      "open",
 6815      "opendir",
 6816      "readdir",
 6817      "readFile",
 6818      "readlink",
 6819      "realpath",
 6820      "rename",
 6821      "rm",
 6822      "rmdir",
 6823      "stat",
 6824      "statfs",
 6825      "symlink",
 6826      "truncate",
 6827      "unlink",
 6828      "utimes",
 6829      "writeFile"
 6830    ].filter((key) => {
 6831      return typeof fs6[key] === "function";
 6832    });
 6833    Object.assign(exports2, fs6);
 6834    api.forEach((method) => {
 6835      exports2[method] = u(fs6[method]);
 6836    });
 6837    exports2.exists = function(filename, callback) {
 6838      if (typeof callback === "function") {
 6839        return fs6.exists(filename, callback);
 6840      }
 6841      return new Promise((resolve) => {
 6842        return fs6.exists(filename, resolve);
 6843      });
 6844    };
 6845    exports2.read = function(fd, buffer, offset, length, position, callback) {
 6846      if (typeof callback === "function") {
 6847        return fs6.read(fd, buffer, offset, length, position, callback);
 6848      }
 6849      return new Promise((resolve, reject) => {
 6850        fs6.read(fd, buffer, offset, length, position, (err, bytesRead, buffer2) => {
 6851          if (err) return reject(err);
 6852          resolve({ bytesRead, buffer: buffer2 });
 6853        });
 6854      });
 6855    };
 6856    exports2.write = function(fd, buffer, ...args) {
 6857      if (typeof args[args.length - 1] === "function") {
 6858        return fs6.write(fd, buffer, ...args);
 6859      }
 6860      return new Promise((resolve, reject) => {
 6861        fs6.write(fd, buffer, ...args, (err, bytesWritten, buffer2) => {
 6862          if (err) return reject(err);
 6863          resolve({ bytesWritten, buffer: buffer2 });
 6864        });
 6865      });
 6866    };
 6867    exports2.readv = function(fd, buffers, ...args) {
 6868      if (typeof args[args.length - 1] === "function") {
 6869        return fs6.readv(fd, buffers, ...args);
 6870      }
 6871      return new Promise((resolve, reject) => {
 6872        fs6.readv(fd, buffers, ...args, (err, bytesRead, buffers2) => {
 6873          if (err) return reject(err);
 6874          resolve({ bytesRead, buffers: buffers2 });
 6875        });
 6876      });
 6877    };
 6878    exports2.writev = function(fd, buffers, ...args) {
 6879      if (typeof args[args.length - 1] === "function") {
 6880        return fs6.writev(fd, buffers, ...args);
 6881      }
 6882      return new Promise((resolve, reject) => {
 6883        fs6.writev(fd, buffers, ...args, (err, bytesWritten, buffers2) => {
 6884          if (err) return reject(err);
 6885          resolve({ bytesWritten, buffers: buffers2 });
 6886        });
 6887      });
 6888    };
 6889    if (typeof fs6.realpath.native === "function") {
 6890      exports2.realpath.native = u(fs6.realpath.native);
 6891    } else {
 6892      process.emitWarning(
 6893        "fs.realpath.native is not a function. Is fs being monkey-patched?",
 6894        "Warning",
 6895        "fs-extra-WARN0003"
 6896      );
 6897    }
 6898  }
 6899});
 6900
 6901// node_modules/fs-extra/lib/mkdirs/utils.js
 6902var require_utils5 = __commonJS({
 6903  "node_modules/fs-extra/lib/mkdirs/utils.js"(exports2, module2) {
 6904    "use strict";
 6905    var path5 = require("path");
 6906    module2.exports.checkPath = function checkPath(pth) {
 6907      if (process.platform === "win32") {
 6908        const pathHasInvalidWinCharacters = /[<>:"|?*]/.test(pth.replace(path5.parse(pth).root, ""));
 6909        if (pathHasInvalidWinCharacters) {
 6910          const error = new Error(`Path contains invalid characters: ${pth}`);
 6911          error.code = "EINVAL";
 6912          throw error;
 6913        }
 6914      }
 6915    };
 6916  }
 6917});
 6918
 6919// node_modules/fs-extra/lib/mkdirs/make-dir.js
 6920var require_make_dir = __commonJS({
 6921  "node_modules/fs-extra/lib/mkdirs/make-dir.js"(exports2, module2) {
 6922    "use strict";
 6923    var fs6 = require_fs5();
 6924    var { checkPath } = require_utils5();
 6925    var getMode = (options) => {
 6926      const defaults = { mode: 511 };
 6927      if (typeof options === "number") return options;
 6928      return __spreadValues(__spreadValues({}, defaults), options).mode;
 6929    };
 6930    module2.exports.makeDir = (dir, options) => __async(null, null, function* () {
 6931      checkPath(dir);
 6932      return fs6.mkdir(dir, {
 6933        mode: getMode(options),
 6934        recursive: true
 6935      });
 6936    });
 6937    module2.exports.makeDirSync = (dir, options) => {
 6938      checkPath(dir);
 6939      return fs6.mkdirSync(dir, {
 6940        mode: getMode(options),
 6941        recursive: true
 6942      });
 6943    };
 6944  }
 6945});
 6946
 6947// node_modules/fs-extra/lib/mkdirs/index.js
 6948var require_mkdirs = __commonJS({
 6949  "node_modules/fs-extra/lib/mkdirs/index.js"(exports2, module2) {
 6950    "use strict";
 6951    var u = require_universalify().fromPromise;
 6952    var { makeDir: _makeDir, makeDirSync } = require_make_dir();
 6953    var makeDir = u(_makeDir);
 6954    module2.exports = {
 6955      mkdirs: makeDir,
 6956      mkdirsSync: makeDirSync,
 6957      // alias
 6958      mkdirp: makeDir,
 6959      mkdirpSync: makeDirSync,
 6960      ensureDir: makeDir,
 6961      ensureDirSync: makeDirSync
 6962    };
 6963  }
 6964});
 6965
 6966// node_modules/fs-extra/lib/path-exists/index.js
 6967var require_path_exists = __commonJS({
 6968  "node_modules/fs-extra/lib/path-exists/index.js"(exports2, module2) {
 6969    "use strict";
 6970    var u = require_universalify().fromPromise;
 6971    var fs6 = require_fs5();
 6972    function pathExists(path5) {
 6973      return fs6.access(path5).then(() => true).catch(() => false);
 6974    }
 6975    module2.exports = {
 6976      pathExists: u(pathExists),
 6977      pathExistsSync: fs6.existsSync
 6978    };
 6979  }
 6980});
 6981
 6982// node_modules/fs-extra/lib/util/utimes.js
 6983var require_utimes = __commonJS({
 6984  "node_modules/fs-extra/lib/util/utimes.js"(exports2, module2) {
 6985    "use strict";
 6986    var fs6 = require_fs5();
 6987    var u = require_universalify().fromPromise;
 6988    function utimesMillis(path5, atime, mtime) {
 6989      return __async(this, null, function* () {
 6990        const fd = yield fs6.open(path5, "r+");
 6991        let closeErr = null;
 6992        try {
 6993          yield fs6.futimes(fd, atime, mtime);
 6994        } finally {
 6995          try {
 6996            yield fs6.close(fd);
 6997          } catch (e) {
 6998            closeErr = e;
 6999          }
 7000        }
 7001        if (closeErr) {
 7002          throw closeErr;
 7003        }
 7004      });
 7005    }
 7006    function utimesMillisSync(path5, atime, mtime) {
 7007      const fd = fs6.openSync(path5, "r+");
 7008      fs6.futimesSync(fd, atime, mtime);
 7009      return fs6.closeSync(fd);
 7010    }
 7011    module2.exports = {
 7012      utimesMillis: u(utimesMillis),
 7013      utimesMillisSync
 7014    };
 7015  }
 7016});
 7017
 7018// node_modules/fs-extra/lib/util/stat.js
 7019var require_stat = __commonJS({
 7020  "node_modules/fs-extra/lib/util/stat.js"(exports2, module2) {
 7021    "use strict";
 7022    var fs6 = require_fs5();
 7023    var path5 = require("path");
 7024    var u = require_universalify().fromPromise;
 7025    function getStats(src, dest, opts) {
 7026      const statFunc = opts.dereference ? (file) => fs6.stat(file, { bigint: true }) : (file) => fs6.lstat(file, { bigint: true });
 7027      return Promise.all([
 7028        statFunc(src),
 7029        statFunc(dest).catch((err) => {
 7030          if (err.code === "ENOENT") return null;
 7031          throw err;
 7032        })
 7033      ]).then(([srcStat, destStat]) => ({ srcStat, destStat }));
 7034    }
 7035    function getStatsSync(src, dest, opts) {
 7036      let destStat;
 7037      const statFunc = opts.dereference ? (file) => fs6.statSync(file, { bigint: true }) : (file) => fs6.lstatSync(file, { bigint: true });
 7038      const srcStat = statFunc(src);
 7039      try {
 7040        destStat = statFunc(dest);
 7041      } catch (err) {
 7042        if (err.code === "ENOENT") return { srcStat, destStat: null };
 7043        throw err;
 7044      }
 7045      return { srcStat, destStat };
 7046    }
 7047    function checkPaths(src, dest, funcName, opts) {
 7048      return __async(this, null, function* () {
 7049        const { srcStat, destStat } = yield getStats(src, dest, opts);
 7050        if (destStat) {
 7051          if (areIdentical(srcStat, destStat)) {
 7052            const srcBaseName = path5.basename(src);
 7053            const destBaseName = path5.basename(dest);
 7054            if (funcName === "move" && srcBaseName !== destBaseName && srcBaseName.toLowerCase() === destBaseName.toLowerCase()) {
 7055              return { srcStat, destStat, isChangingCase: true };
 7056            }
 7057            throw new Error("Source and destination must not be the same.");
 7058          }
 7059          if (srcStat.isDirectory() && !destStat.isDirectory()) {
 7060            throw new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`);
 7061          }
 7062          if (!srcStat.isDirectory() && destStat.isDirectory()) {
 7063            throw new Error(`Cannot overwrite directory '${dest}' with non-directory '${src}'.`);
 7064          }
 7065        }
 7066        if (srcStat.isDirectory() && isSrcSubdir(src, dest)) {
 7067          throw new Error(errMsg(src, dest, funcName));
 7068        }
 7069        return { srcStat, destStat };
 7070      });
 7071    }
 7072    function checkPathsSync(src, dest, funcName, opts) {
 7073      const { srcStat, destStat } = getStatsSync(src, dest, opts);
 7074      if (destStat) {
 7075        if (areIdentical(srcStat, destStat)) {
 7076          const srcBaseName = path5.basename(src);
 7077          const destBaseName = path5.basename(dest);
 7078          if (funcName === "move" && srcBaseName !== destBaseName && srcBaseName.toLowerCase() === destBaseName.toLowerCase()) {
 7079            return { srcStat, destStat, isChangingCase: true };
 7080          }
 7081          throw new Error("Source and destination must not be the same.");
 7082        }
 7083        if (srcStat.isDirectory() && !destStat.isDirectory()) {
 7084          throw new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`);
 7085        }
 7086        if (!srcStat.isDirectory() && destStat.isDirectory()) {
 7087          throw new Error(`Cannot overwrite directory '${dest}' with non-directory '${src}'.`);
 7088        }
 7089      }
 7090      if (srcStat.isDirectory() && isSrcSubdir(src, dest)) {
 7091        throw new Error(errMsg(src, dest, funcName));
 7092      }
 7093      return { srcStat, destStat };
 7094    }
 7095    function checkParentPaths(src, srcStat, dest, funcName) {
 7096      return __async(this, null, function* () {
 7097        const srcParent = path5.resolve(path5.dirname(src));
 7098        const destParent = path5.resolve(path5.dirname(dest));
 7099        if (destParent === srcParent || destParent === path5.parse(destParent).root) return;
 7100        let destStat;
 7101        try {
 7102          destStat = yield fs6.stat(destParent, { bigint: true });
 7103        } catch (err) {
 7104          if (err.code === "ENOENT") return;
 7105          throw err;
 7106        }
 7107        if (areIdentical(srcStat, destStat)) {
 7108          throw new Error(errMsg(src, dest, funcName));
 7109        }
 7110        return checkParentPaths(src, srcStat, destParent, funcName);
 7111      });
 7112    }
 7113    function checkParentPathsSync(src, srcStat, dest, funcName) {
 7114      const srcParent = path5.resolve(path5.dirname(src));
 7115      const destParent = path5.resolve(path5.dirname(dest));
 7116      if (destParent === srcParent || destParent === path5.parse(destParent).root) return;
 7117      let destStat;
 7118      try {
 7119        destStat = fs6.statSync(destParent, { bigint: true });
 7120      } catch (err) {
 7121        if (err.code === "ENOENT") return;
 7122        throw err;
 7123      }
 7124      if (areIdentical(srcStat, destStat)) {
 7125        throw new Error(errMsg(src, dest, funcName));
 7126      }
 7127      return checkParentPathsSync(src, srcStat, destParent, funcName);
 7128    }
 7129    function areIdentical(srcStat, destStat) {
 7130      return destStat.ino !== void 0 && destStat.dev !== void 0 && destStat.ino === srcStat.ino && destStat.dev === srcStat.dev;
 7131    }
 7132    function isSrcSubdir(src, dest) {
 7133      const srcArr = path5.resolve(src).split(path5.sep).filter((i) => i);
 7134      const destArr = path5.resolve(dest).split(path5.sep).filter((i) => i);
 7135      return srcArr.every((cur, i) => destArr[i] === cur);
 7136    }
 7137    function errMsg(src, dest, funcName) {
 7138      return `Cannot ${funcName} '${src}' to a subdirectory of itself, '${dest}'.`;
 7139    }
 7140    module2.exports = {
 7141      // checkPaths
 7142      checkPaths: u(checkPaths),
 7143      checkPathsSync,
 7144      // checkParent
 7145      checkParentPaths: u(checkParentPaths),
 7146      checkParentPathsSync,
 7147      // Misc
 7148      isSrcSubdir,
 7149      areIdentical
 7150    };
 7151  }
 7152});
 7153
 7154// node_modules/fs-extra/lib/util/async.js
 7155var require_async7 = __commonJS({
 7156  "node_modules/fs-extra/lib/util/async.js"(exports2, module2) {
 7157    "use strict";
 7158    function asyncIteratorConcurrentProcess(iterator, fn) {
 7159      return __async(this, null, function* () {
 7160        const promises = [];
 7161        try {
 7162          for (var iter = __forAwait(iterator), more, temp, error; more = !(temp = yield iter.next()).done; more = false) {
 7163            const item = temp.value;
 7164            promises.push(
 7165              fn(item).then(
 7166                () => null,
 7167                (err) => err != null ? err : new Error("unknown error")
 7168              )
 7169            );
 7170          }
 7171        } catch (temp) {
 7172          error = [temp];
 7173        } finally {
 7174          try {
 7175            more && (temp = iter.return) && (yield temp.call(iter));
 7176          } finally {
 7177            if (error)
 7178              throw error[0];
 7179          }
 7180        }
 7181        yield Promise.all(
 7182          promises.map(
 7183            (promise) => promise.then((possibleErr) => {
 7184              if (possibleErr !== null) throw possibleErr;
 7185            })
 7186          )
 7187        );
 7188      });
 7189    }
 7190    module2.exports = {
 7191      asyncIteratorConcurrentProcess
 7192    };
 7193  }
 7194});
 7195
 7196// node_modules/fs-extra/lib/copy/copy.js
 7197var require_copy = __commonJS({
 7198  "node_modules/fs-extra/lib/copy/copy.js"(exports2, module2) {
 7199    "use strict";
 7200    var fs6 = require_fs5();
 7201    var path5 = require("path");
 7202    var { mkdirs } = require_mkdirs();
 7203    var { pathExists } = require_path_exists();
 7204    var { utimesMillis } = require_utimes();
 7205    var stat = require_stat();
 7206    var { asyncIteratorConcurrentProcess } = require_async7();
 7207    function copy(_0, _1) {
 7208      return __async(this, arguments, function* (src, dest, opts = {}) {
 7209        if (typeof opts === "function") {
 7210          opts = { filter: opts };
 7211        }
 7212        opts.clobber = "clobber" in opts ? !!opts.clobber : true;
 7213        opts.overwrite = "overwrite" in opts ? !!opts.overwrite : opts.clobber;
 7214        if (opts.preserveTimestamps && process.arch === "ia32") {
 7215          process.emitWarning(
 7216            "Using the preserveTimestamps option in 32-bit node is not recommended;\n\n	see https://github.com/jprichardson/node-fs-extra/issues/269",
 7217            "Warning",
 7218            "fs-extra-WARN0001"
 7219          );
 7220        }
 7221        const { srcStat, destStat } = yield stat.checkPaths(src, dest, "copy", opts);
 7222        yield stat.checkParentPaths(src, srcStat, dest, "copy");
 7223        const include = yield runFilter(src, dest, opts);
 7224        if (!include) return;
 7225        const destParent = path5.dirname(dest);
 7226        const dirExists = yield pathExists(destParent);
 7227        if (!dirExists) {
 7228          yield mkdirs(destParent);
 7229        }
 7230        yield getStatsAndPerformCopy(destStat, src, dest, opts);
 7231      });
 7232    }
 7233    function runFilter(src, dest, opts) {
 7234      return __async(this, null, function* () {
 7235        if (!opts.filter) return true;
 7236        return opts.filter(src, dest);
 7237      });
 7238    }
 7239    function getStatsAndPerformCopy(destStat, src, dest, opts) {
 7240      return __async(this, null, function* () {
 7241        const statFn = opts.dereference ? fs6.stat : fs6.lstat;
 7242        const srcStat = yield statFn(src);
 7243        if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts);
 7244        if (srcStat.isFile() || srcStat.isCharacterDevice() || srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts);
 7245        if (srcStat.isSymbolicLink()) return onLink(destStat, src, dest, opts);
 7246        if (srcStat.isSocket()) throw new Error(`Cannot copy a socket file: ${src}`);
 7247        if (srcStat.isFIFO()) throw new Error(`Cannot copy a FIFO pipe: ${src}`);
 7248        throw new Error(`Unknown file: ${src}`);
 7249      });
 7250    }
 7251    function onFile(srcStat, destStat, src, dest, opts) {
 7252      return __async(this, null, function* () {
 7253        if (!destStat) return copyFile(srcStat, src, dest, opts);
 7254        if (opts.overwrite) {
 7255          yield fs6.unlink(dest);
 7256          return copyFile(srcStat, src, dest, opts);
 7257        }
 7258        if (opts.errorOnExist) {
 7259          throw new Error(`'${dest}' already exists`);
 7260        }
 7261      });
 7262    }
 7263    function copyFile(srcStat, src, dest, opts) {
 7264      return __async(this, null, function* () {
 7265        yield fs6.copyFile(src, dest);
 7266        if (opts.preserveTimestamps) {
 7267          if (fileIsNotWritable(srcStat.mode)) {
 7268            yield makeFileWritable(dest, srcStat.mode);
 7269          }
 7270          const updatedSrcStat = yield fs6.stat(src);
 7271          yield utimesMillis(dest, updatedSrcStat.atime, updatedSrcStat.mtime);
 7272        }
 7273        return fs6.chmod(dest, srcStat.mode);
 7274      });
 7275    }
 7276    function fileIsNotWritable(srcMode) {
 7277      return (srcMode & 128) === 0;
 7278    }
 7279    function makeFileWritable(dest, srcMode) {
 7280      return fs6.chmod(dest, srcMode | 128);
 7281    }
 7282    function onDir(srcStat, destStat, src, dest, opts) {
 7283      return __async(this, null, function* () {
 7284        if (!destStat) {
 7285          yield fs6.mkdir(dest);
 7286        }
 7287        yield asyncIteratorConcurrentProcess(yield fs6.opendir(src), (item) => __async(null, null, function* () {
 7288          const srcItem = path5.join(src, item.name);
 7289          const destItem = path5.join(dest, item.name);
 7290          const include = yield runFilter(srcItem, destItem, opts);
 7291          if (include) {
 7292            const { destStat: destStat2 } = yield stat.checkPaths(srcItem, destItem, "copy", opts);
 7293            yield getStatsAndPerformCopy(destStat2, srcItem, destItem, opts);
 7294          }
 7295        }));
 7296        if (!destStat) {
 7297          yield fs6.chmod(dest, srcStat.mode);
 7298        }
 7299      });
 7300    }
 7301    function onLink(destStat, src, dest, opts) {
 7302      return __async(this, null, function* () {
 7303        let resolvedSrc = yield fs6.readlink(src);
 7304        if (opts.dereference) {
 7305          resolvedSrc = path5.resolve(process.cwd(), resolvedSrc);
 7306        }
 7307        if (!destStat) {
 7308          return fs6.symlink(resolvedSrc, dest);
 7309        }
 7310        let resolvedDest = null;
 7311        try {
 7312          resolvedDest = yield fs6.readlink(dest);
 7313        } catch (e) {
 7314          if (e.code === "EINVAL" || e.code === "UNKNOWN") return fs6.symlink(resolvedSrc, dest);
 7315          throw e;
 7316        }
 7317        if (opts.dereference) {
 7318          resolvedDest = path5.resolve(process.cwd(), resolvedDest);
 7319        }
 7320        if (stat.isSrcSubdir(resolvedSrc, resolvedDest)) {
 7321          throw new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`);
 7322        }
 7323        if (stat.isSrcSubdir(resolvedDest, resolvedSrc)) {
 7324          throw new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`);
 7325        }
 7326        yield fs6.unlink(dest);
 7327        return fs6.symlink(resolvedSrc, dest);
 7328      });
 7329    }
 7330    module2.exports = copy;
 7331  }
 7332});
 7333
 7334// node_modules/fs-extra/lib/copy/copy-sync.js
 7335var require_copy_sync = __commonJS({
 7336  "node_modules/fs-extra/lib/copy/copy-sync.js"(exports2, module2) {
 7337    "use strict";
 7338    var fs6 = require_graceful_fs();
 7339    var path5 = require("path");
 7340    var mkdirsSync = require_mkdirs().mkdirsSync;
 7341    var utimesMillisSync = require_utimes().utimesMillisSync;
 7342    var stat = require_stat();
 7343    function copySync(src, dest, opts) {
 7344      if (typeof opts === "function") {
 7345        opts = { filter: opts };
 7346      }
 7347      opts = opts || {};
 7348      opts.clobber = "clobber" in opts ? !!opts.clobber : true;
 7349      opts.overwrite = "overwrite" in opts ? !!opts.overwrite : opts.clobber;
 7350      if (opts.preserveTimestamps && process.arch === "ia32") {
 7351        process.emitWarning(
 7352          "Using the preserveTimestamps option in 32-bit node is not recommended;\n\n	see https://github.com/jprichardson/node-fs-extra/issues/269",
 7353          "Warning",
 7354          "fs-extra-WARN0002"
 7355        );
 7356      }
 7357      const { srcStat, destStat } = stat.checkPathsSync(src, dest, "copy", opts);
 7358      stat.checkParentPathsSync(src, srcStat, dest, "copy");
 7359      if (opts.filter && !opts.filter(src, dest)) return;
 7360      const destParent = path5.dirname(dest);
 7361      if (!fs6.existsSync(destParent)) mkdirsSync(destParent);
 7362      return getStats(destStat, src, dest, opts);
 7363    }
 7364    function getStats(destStat, src, dest, opts) {
 7365      const statSync = opts.dereference ? fs6.statSync : fs6.lstatSync;
 7366      const srcStat = statSync(src);
 7367      if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts);
 7368      else if (srcStat.isFile() || srcStat.isCharacterDevice() || srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts);
 7369      else if (srcStat.isSymbolicLink()) return onLink(destStat, src, dest, opts);
 7370      else if (srcStat.isSocket()) throw new Error(`Cannot copy a socket file: ${src}`);
 7371      else if (srcStat.isFIFO()) throw new Error(`Cannot copy a FIFO pipe: ${src}`);
 7372      throw new Error(`Unknown file: ${src}`);
 7373    }
 7374    function onFile(srcStat, destStat, src, dest, opts) {
 7375      if (!destStat) return copyFile(srcStat, src, dest, opts);
 7376      return mayCopyFile(srcStat, src, dest, opts);
 7377    }
 7378    function mayCopyFile(srcStat, src, dest, opts) {
 7379      if (opts.overwrite) {
 7380        fs6.unlinkSync(dest);
 7381        return copyFile(srcStat, src, dest, opts);
 7382      } else if (opts.errorOnExist) {
 7383        throw new Error(`'${dest}' already exists`);
 7384      }
 7385    }
 7386    function copyFile(srcStat, src, dest, opts) {
 7387      fs6.copyFileSync(src, dest);
 7388      if (opts.preserveTimestamps) handleTimestamps(srcStat.mode, src, dest);
 7389      return setDestMode(dest, srcStat.mode);
 7390    }
 7391    function handleTimestamps(srcMode, src, dest) {
 7392      if (fileIsNotWritable(srcMode)) makeFileWritable(dest, srcMode);
 7393      return setDestTimestamps(src, dest);
 7394    }
 7395    function fileIsNotWritable(srcMode) {
 7396      return (srcMode & 128) === 0;
 7397    }
 7398    function makeFileWritable(dest, srcMode) {
 7399      return setDestMode(dest, srcMode | 128);
 7400    }
 7401    function setDestMode(dest, srcMode) {
 7402      return fs6.chmodSync(dest, srcMode);
 7403    }
 7404    function setDestTimestamps(src, dest) {
 7405      const updatedSrcStat = fs6.statSync(src);
 7406      return utimesMillisSync(dest, updatedSrcStat.atime, updatedSrcStat.mtime);
 7407    }
 7408    function onDir(srcStat, destStat, src, dest, opts) {
 7409      if (!destStat) return mkDirAndCopy(srcStat.mode, src, dest, opts);
 7410      return copyDir(src, dest, opts);
 7411    }
 7412    function mkDirAndCopy(srcMode, src, dest, opts) {
 7413      fs6.mkdirSync(dest);
 7414      copyDir(src, dest, opts);
 7415      return setDestMode(dest, srcMode);
 7416    }
 7417    function copyDir(src, dest, opts) {
 7418      const dir = fs6.opendirSync(src);
 7419      try {
 7420        let dirent;
 7421        while ((dirent = dir.readSync()) !== null) {
 7422          copyDirItem(dirent.name, src, dest, opts);
 7423        }
 7424      } finally {
 7425        dir.closeSync();
 7426      }
 7427    }
 7428    function copyDirItem(item, src, dest, opts) {
 7429      const srcItem = path5.join(src, item);
 7430      const destItem = path5.join(dest, item);
 7431      if (opts.filter && !opts.filter(srcItem, destItem)) return;
 7432      const { destStat } = stat.checkPathsSync(srcItem, destItem, "copy", opts);
 7433      return getStats(destStat, srcItem, destItem, opts);
 7434    }
 7435    function onLink(destStat, src, dest, opts) {
 7436      let resolvedSrc = fs6.readlinkSync(src);
 7437      if (opts.dereference) {
 7438        resolvedSrc = path5.resolve(process.cwd(), resolvedSrc);
 7439      }
 7440      if (!destStat) {
 7441        return fs6.symlinkSync(resolvedSrc, dest);
 7442      } else {
 7443        let resolvedDest;
 7444        try {
 7445          resolvedDest = fs6.readlinkSync(dest);
 7446        } catch (err) {
 7447          if (err.code === "EINVAL" || err.code === "UNKNOWN") return fs6.symlinkSync(resolvedSrc, dest);
 7448          throw err;
 7449        }
 7450        if (opts.dereference) {
 7451          resolvedDest = path5.resolve(process.cwd(), resolvedDest);
 7452        }
 7453        if (stat.isSrcSubdir(resolvedSrc, resolvedDest)) {
 7454          throw new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`);
 7455        }
 7456        if (stat.isSrcSubdir(resolvedDest, resolvedSrc)) {
 7457          throw new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`);
 7458        }
 7459        return copyLink(resolvedSrc, dest);
 7460      }
 7461    }
 7462    function copyLink(resolvedSrc, dest) {
 7463      fs6.unlinkSync(dest);
 7464      return fs6.symlinkSync(resolvedSrc, dest);
 7465    }
 7466    module2.exports = copySync;
 7467  }
 7468});
 7469
 7470// node_modules/fs-extra/lib/copy/index.js
 7471var require_copy2 = __commonJS({
 7472  "node_modules/fs-extra/lib/copy/index.js"(exports2, module2) {
 7473    "use strict";
 7474    var u = require_universalify().fromPromise;
 7475    module2.exports = {
 7476      copy: u(require_copy()),
 7477      copySync: require_copy_sync()
 7478    };
 7479  }
 7480});
 7481
 7482// node_modules/fs-extra/lib/remove/index.js
 7483var require_remove = __commonJS({
 7484  "node_modules/fs-extra/lib/remove/index.js"(exports2, module2) {
 7485    "use strict";
 7486    var fs6 = require_graceful_fs();
 7487    var u = require_universalify().fromCallback;
 7488    function remove(path5, callback) {
 7489      fs6.rm(path5, { recursive: true, force: true }, callback);
 7490    }
 7491    function removeSync(path5) {
 7492      fs6.rmSync(path5, { recursive: true, force: true });
 7493    }
 7494    module2.exports = {
 7495      remove: u(remove),
 7496      removeSync
 7497    };
 7498  }
 7499});
 7500
 7501// node_modules/fs-extra/lib/empty/index.js
 7502var require_empty = __commonJS({
 7503  "node_modules/fs-extra/lib/empty/index.js"(exports2, module2) {
 7504    "use strict";
 7505    var u = require_universalify().fromPromise;
 7506    var fs6 = require_fs5();
 7507    var path5 = require("path");
 7508    var mkdir = require_mkdirs();
 7509    var remove = require_remove();
 7510    var emptyDir = u(function emptyDir2(dir) {
 7511      return __async(this, null, function* () {
 7512        let items;
 7513        try {
 7514          items = yield fs6.readdir(dir);
 7515        } catch (e) {
 7516          return mkdir.mkdirs(dir);
 7517        }
 7518        return Promise.all(items.map((item) => remove.remove(path5.join(dir, item))));
 7519      });
 7520    });
 7521    function emptyDirSync(dir) {
 7522      let items;
 7523      try {
 7524        items = fs6.readdirSync(dir);
 7525      } catch (e) {
 7526        return mkdir.mkdirsSync(dir);
 7527      }
 7528      items.forEach((item) => {
 7529        item = path5.join(dir, item);
 7530        remove.removeSync(item);
 7531      });
 7532    }
 7533    module2.exports = {
 7534      emptyDirSync,
 7535      emptydirSync: emptyDirSync,
 7536      emptyDir,
 7537      emptydir: emptyDir
 7538    };
 7539  }
 7540});
 7541
 7542// node_modules/fs-extra/lib/ensure/file.js
 7543var require_file = __commonJS({
 7544  "node_modules/fs-extra/lib/ensure/file.js"(exports2, module2) {
 7545    "use strict";
 7546    var u = require_universalify().fromPromise;
 7547    var path5 = require("path");
 7548    var fs6 = require_fs5();
 7549    var mkdir = require_mkdirs();
 7550    function createFile(file) {
 7551      return __async(this, null, function* () {
 7552        let stats;
 7553        try {
 7554          stats = yield fs6.stat(file);
 7555        } catch (e) {
 7556        }
 7557        if (stats && stats.isFile()) return;
 7558        const dir = path5.dirname(file);
 7559        let dirStats = null;
 7560        try {
 7561          dirStats = yield fs6.stat(dir);
 7562        } catch (err) {
 7563          if (err.code === "ENOENT") {
 7564            yield mkdir.mkdirs(dir);
 7565            yield fs6.writeFile(file, "");
 7566            return;
 7567          } else {
 7568            throw err;
 7569          }
 7570        }
 7571        if (dirStats.isDirectory()) {
 7572          yield fs6.writeFile(file, "");
 7573        } else {
 7574          yield fs6.readdir(dir);
 7575        }
 7576      });
 7577    }
 7578    function createFileSync(file) {
 7579      let stats;
 7580      try {
 7581        stats = fs6.statSync(file);
 7582      } catch (e) {
 7583      }
 7584      if (stats && stats.isFile()) return;
 7585      const dir = path5.dirname(file);
 7586      try {
 7587        if (!fs6.statSync(dir).isDirectory()) {
 7588          fs6.readdirSync(dir);
 7589        }
 7590      } catch (err) {
 7591        if (err && err.code === "ENOENT") mkdir.mkdirsSync(dir);
 7592        else throw err;
 7593      }
 7594      fs6.writeFileSync(file, "");
 7595    }
 7596    module2.exports = {
 7597      createFile: u(createFile),
 7598      createFileSync
 7599    };
 7600  }
 7601});
 7602
 7603// node_modules/fs-extra/lib/ensure/link.js
 7604var require_link = __commonJS({
 7605  "node_modules/fs-extra/lib/ensure/link.js"(exports2, module2) {
 7606    "use strict";
 7607    var u = require_universalify().fromPromise;
 7608    var path5 = require("path");
 7609    var fs6 = require_fs5();
 7610    var mkdir = require_mkdirs();
 7611    var { pathExists } = require_path_exists();
 7612    var { areIdentical } = require_stat();
 7613    function createLink(srcpath, dstpath) {
 7614      return __async(this, null, function* () {
 7615        let dstStat;
 7616        try {
 7617          dstStat = yield fs6.lstat(dstpath);
 7618        } catch (e) {
 7619        }
 7620        let srcStat;
 7621        try {
 7622          srcStat = yield fs6.lstat(srcpath);
 7623        } catch (err) {
 7624          err.message = err.message.replace("lstat", "ensureLink");
 7625          throw err;
 7626        }
 7627        if (dstStat && areIdentical(srcStat, dstStat)) return;
 7628        const dir = path5.dirname(dstpath);
 7629        const dirExists = yield pathExists(dir);
 7630        if (!dirExists) {
 7631          yield mkdir.mkdirs(dir);
 7632        }
 7633        yield fs6.link(srcpath, dstpath);
 7634      });
 7635    }
 7636    function createLinkSync(srcpath, dstpath) {
 7637      let dstStat;
 7638      try {
 7639        dstStat = fs6.lstatSync(dstpath);
 7640      } catch (e) {
 7641      }
 7642      try {
 7643        const srcStat = fs6.lstatSync(srcpath);
 7644        if (dstStat && areIdentical(srcStat, dstStat)) return;
 7645      } catch (err) {
 7646        err.message = err.message.replace("lstat", "ensureLink");
 7647        throw err;
 7648      }
 7649      const dir = path5.dirname(dstpath);
 7650      const dirExists = fs6.existsSync(dir);
 7651      if (dirExists) return fs6.linkSync(srcpath, dstpath);
 7652      mkdir.mkdirsSync(dir);
 7653      return fs6.linkSync(srcpath, dstpath);
 7654    }
 7655    module2.exports = {
 7656      createLink: u(createLink),
 7657      createLinkSync
 7658    };
 7659  }
 7660});
 7661
 7662// node_modules/fs-extra/lib/ensure/symlink-paths.js
 7663var require_symlink_paths = __commonJS({
 7664  "node_modules/fs-extra/lib/ensure/symlink-paths.js"(exports2, module2) {
 7665    "use strict";
 7666    var path5 = require("path");
 7667    var fs6 = require_fs5();
 7668    var { pathExists } = require_path_exists();
 7669    var u = require_universalify().fromPromise;
 7670    function symlinkPaths(srcpath, dstpath) {
 7671      return __async(this, null, function* () {
 7672        if (path5.isAbsolute(srcpath)) {
 7673          try {
 7674            yield fs6.lstat(srcpath);
 7675          } catch (err) {
 7676            err.message = err.message.replace("lstat", "ensureSymlink");
 7677            throw err;
 7678          }
 7679          return {
 7680            toCwd: srcpath,
 7681            toDst: srcpath
 7682          };
 7683        }
 7684        const dstdir = path5.dirname(dstpath);
 7685        const relativeToDst = path5.join(dstdir, srcpath);
 7686        const exists = yield pathExists(relativeToDst);
 7687        if (exists) {
 7688          return {
 7689            toCwd: relativeToDst,
 7690            toDst: srcpath
 7691          };
 7692        }
 7693        try {
 7694          yield fs6.lstat(srcpath);
 7695        } catch (err) {
 7696          err.message = err.message.replace("lstat", "ensureSymlink");
 7697          throw err;
 7698        }
 7699        return {
 7700          toCwd: srcpath,
 7701          toDst: path5.relative(dstdir, srcpath)
 7702        };
 7703      });
 7704    }
 7705    function symlinkPathsSync(srcpath, dstpath) {
 7706      if (path5.isAbsolute(srcpath)) {
 7707        const exists2 = fs6.existsSync(srcpath);
 7708        if (!exists2) throw new Error("absolute srcpath does not exist");
 7709        return {
 7710          toCwd: srcpath,
 7711          toDst: srcpath
 7712        };
 7713      }
 7714      const dstdir = path5.dirname(dstpath);
 7715      const relativeToDst = path5.join(dstdir, srcpath);
 7716      const exists = fs6.existsSync(relativeToDst);
 7717      if (exists) {
 7718        return {
 7719          toCwd: relativeToDst,
 7720          toDst: srcpath
 7721        };
 7722      }
 7723      const srcExists = fs6.existsSync(srcpath);
 7724      if (!srcExists) throw new Error("relative srcpath does not exist");
 7725      return {
 7726        toCwd: srcpath,
 7727        toDst: path5.relative(dstdir, srcpath)
 7728      };
 7729    }
 7730    module2.exports = {
 7731      symlinkPaths: u(symlinkPaths),
 7732      symlinkPathsSync
 7733    };
 7734  }
 7735});
 7736
 7737// node_modules/fs-extra/lib/ensure/symlink-type.js
 7738var require_symlink_type = __commonJS({
 7739  "node_modules/fs-extra/lib/ensure/symlink-type.js"(exports2, module2) {
 7740    "use strict";
 7741    var fs6 = require_fs5();
 7742    var u = require_universalify().fromPromise;
 7743    function symlinkType(srcpath, type) {
 7744      return __async(this, null, function* () {
 7745        if (type) return type;
 7746        let stats;
 7747        try {
 7748          stats = yield fs6.lstat(srcpath);
 7749        } catch (e) {
 7750          return "file";
 7751        }
 7752        return stats && stats.isDirectory() ? "dir" : "file";
 7753      });
 7754    }
 7755    function symlinkTypeSync(srcpath, type) {
 7756      if (type) return type;
 7757      let stats;
 7758      try {
 7759        stats = fs6.lstatSync(srcpath);
 7760      } catch (e) {
 7761        return "file";
 7762      }
 7763      return stats && stats.isDirectory() ? "dir" : "file";
 7764    }
 7765    module2.exports = {
 7766      symlinkType: u(symlinkType),
 7767      symlinkTypeSync
 7768    };
 7769  }
 7770});
 7771
 7772// node_modules/fs-extra/lib/ensure/symlink.js
 7773var require_symlink = __commonJS({
 7774  "node_modules/fs-extra/lib/ensure/symlink.js"(exports2, module2) {
 7775    "use strict";
 7776    var u = require_universalify().fromPromise;
 7777    var path5 = require("path");
 7778    var fs6 = require_fs5();
 7779    var { mkdirs, mkdirsSync } = require_mkdirs();
 7780    var { symlinkPaths, symlinkPathsSync } = require_symlink_paths();
 7781    var { symlinkType, symlinkTypeSync } = require_symlink_type();
 7782    var { pathExists } = require_path_exists();
 7783    var { areIdentical } = require_stat();
 7784    function createSymlink(srcpath, dstpath, type) {
 7785      return __async(this, null, function* () {
 7786        let stats;
 7787        try {
 7788          stats = yield fs6.lstat(dstpath);
 7789        } catch (e) {
 7790        }
 7791        if (stats && stats.isSymbolicLink()) {
 7792          const [srcStat, dstStat] = yield Promise.all([
 7793            fs6.stat(srcpath),
 7794            fs6.stat(dstpath)
 7795          ]);
 7796          if (areIdentical(srcStat, dstStat)) return;
 7797        }
 7798        const relative = yield symlinkPaths(srcpath, dstpath);
 7799        srcpath = relative.toDst;
 7800        const toType = yield symlinkType(relative.toCwd, type);
 7801        const dir = path5.dirname(dstpath);
 7802        if (!(yield pathExists(dir))) {
 7803          yield mkdirs(dir);
 7804        }
 7805        return fs6.symlink(srcpath, dstpath, toType);
 7806      });
 7807    }
 7808    function createSymlinkSync(srcpath, dstpath, type) {
 7809      let stats;
 7810      try {
 7811        stats = fs6.lstatSync(dstpath);
 7812      } catch (e) {
 7813      }
 7814      if (stats && stats.isSymbolicLink()) {
 7815        const srcStat = fs6.statSync(srcpath);
 7816        const dstStat = fs6.statSync(dstpath);
 7817        if (areIdentical(srcStat, dstStat)) return;
 7818      }
 7819      const relative = symlinkPathsSync(srcpath, dstpath);
 7820      srcpath = relative.toDst;
 7821      type = symlinkTypeSync(relative.toCwd, type);
 7822      const dir = path5.dirname(dstpath);
 7823      const exists = fs6.existsSync(dir);
 7824      if (exists) return fs6.symlinkSync(srcpath, dstpath, type);
 7825      mkdirsSync(dir);
 7826      return fs6.symlinkSync(srcpath, dstpath, type);
 7827    }
 7828    module2.exports = {
 7829      createSymlink: u(createSymlink),
 7830      createSymlinkSync
 7831    };
 7832  }
 7833});
 7834
 7835// node_modules/fs-extra/lib/ensure/index.js
 7836var require_ensure = __commonJS({
 7837  "node_modules/fs-extra/lib/ensure/index.js"(exports2, module2) {
 7838    "use strict";
 7839    var { createFile, createFileSync } = require_file();
 7840    var { createLink, createLinkSync } = require_link();
 7841    var { createSymlink, createSymlinkSync } = require_symlink();
 7842    module2.exports = {
 7843      // file
 7844      createFile,
 7845      createFileSync,
 7846      ensureFile: createFile,
 7847      ensureFileSync: createFileSync,
 7848      // link
 7849      createLink,
 7850      createLinkSync,
 7851      ensureLink: createLink,
 7852      ensureLinkSync: createLinkSync,
 7853      // symlink
 7854      createSymlink,
 7855      createSymlinkSync,
 7856      ensureSymlink: createSymlink,
 7857      ensureSymlinkSync: createSymlinkSync
 7858    };
 7859  }
 7860});
 7861
 7862// node_modules/jsonfile/utils.js
 7863var require_utils6 = __commonJS({
 7864  "node_modules/jsonfile/utils.js"(exports2, module2) {
 7865    "use strict";
 7866    function stringify6(obj, { EOL = "\n", finalEOL = true, replacer = null, spaces } = {}) {
 7867      const EOF = finalEOL ? EOL : "";
 7868      const str = JSON.stringify(obj, replacer, spaces);
 7869      return str.replace(/\n/g, EOL) + EOF;
 7870    }
 7871    function stripBom(content) {
 7872      if (Buffer.isBuffer(content)) content = content.toString("utf8");
 7873      return content.replace(/^\uFEFF/, "");
 7874    }
 7875    module2.exports = { stringify: stringify6, stripBom };
 7876  }
 7877});
 7878
 7879// node_modules/jsonfile/index.js
 7880var require_jsonfile = __commonJS({
 7881  "node_modules/jsonfile/index.js"(exports2, module2) {
 7882    "use strict";
 7883    var _fs2;
 7884    try {
 7885      _fs2 = require_graceful_fs();
 7886    } catch (_) {
 7887      _fs2 = require("fs");
 7888    }
 7889    var universalify = require_universalify();
 7890    var { stringify: stringify6, stripBom } = require_utils6();
 7891    function _readFile(_0) {
 7892      return __async(this, arguments, function* (file, options = {}) {
 7893        if (typeof options === "string") {
 7894          options = { encoding: options };
 7895        }
 7896        const fs6 = options.fs || _fs2;
 7897        const shouldThrow = "throws" in options ? options.throws : true;
 7898        let data = yield universalify.fromCallback(fs6.readFile)(file, options);
 7899        data = stripBom(data);
 7900        let obj;
 7901        try {
 7902          obj = JSON.parse(data, options ? options.reviver : null);
 7903        } catch (err) {
 7904          if (shouldThrow) {
 7905            err.message = `${file}: ${err.message}`;
 7906            throw err;
 7907          } else {
 7908            return null;
 7909          }
 7910        }
 7911        return obj;
 7912      });
 7913    }
 7914    var readFile = universalify.fromPromise(_readFile);
 7915    function readFileSync(file, options = {}) {
 7916      if (typeof options === "string") {
 7917        options = { encoding: options };
 7918      }
 7919      const fs6 = options.fs || _fs2;
 7920      const shouldThrow = "throws" in options ? options.throws : true;
 7921      try {
 7922        let content = fs6.readFileSync(file, options);
 7923        content = stripBom(content);
 7924        return JSON.parse(content, options.reviver);
 7925      } catch (err) {
 7926        if (shouldThrow) {
 7927          err.message = `${file}: ${err.message}`;
 7928          throw err;
 7929        } else {
 7930          return null;
 7931        }
 7932      }
 7933    }
 7934    function _writeFile(_0, _1) {
 7935      return __async(this, arguments, function* (file, obj, options = {}) {
 7936        const fs6 = options.fs || _fs2;
 7937        const str = stringify6(obj, options);
 7938        yield universalify.fromCallback(fs6.writeFile)(file, str, options);
 7939      });
 7940    }
 7941    var writeFile = universalify.fromPromise(_writeFile);
 7942    function writeFileSync(file, obj, options = {}) {
 7943      const fs6 = options.fs || _fs2;
 7944      const str = stringify6(obj, options);
 7945      return fs6.writeFileSync(file, str, options);
 7946    }
 7947    var jsonfile = {
 7948      readFile,
 7949      readFileSync,
 7950      writeFile,
 7951      writeFileSync
 7952    };
 7953    module2.exports = jsonfile;
 7954  }
 7955});
 7956
 7957// node_modules/fs-extra/lib/json/jsonfile.js
 7958var require_jsonfile2 = __commonJS({
 7959  "node_modules/fs-extra/lib/json/jsonfile.js"(exports2, module2) {
 7960    "use strict";
 7961    var jsonFile = require_jsonfile();
 7962    module2.exports = {
 7963      // jsonfile exports
 7964      readJson: jsonFile.readFile,
 7965      readJsonSync: jsonFile.readFileSync,
 7966      writeJson: jsonFile.writeFile,
 7967      writeJsonSync: jsonFile.writeFileSync
 7968    };
 7969  }
 7970});
 7971
 7972// node_modules/fs-extra/lib/output-file/index.js
 7973var require_output_file = __commonJS({
 7974  "node_modules/fs-extra/lib/output-file/index.js"(exports2, module2) {
 7975    "use strict";
 7976    var u = require_universalify().fromPromise;
 7977    var fs6 = require_fs5();
 7978    var path5 = require("path");
 7979    var mkdir = require_mkdirs();
 7980    var pathExists = require_path_exists().pathExists;
 7981    function outputFile(file, data, encoding = "utf-8") {
 7982      return __async(this, null, function* () {
 7983        const dir = path5.dirname(file);
 7984        if (!(yield pathExists(dir))) {
 7985          yield mkdir.mkdirs(dir);
 7986        }
 7987        return fs6.writeFile(file, data, encoding);
 7988      });
 7989    }
 7990    function outputFileSync(file, ...args) {
 7991      const dir = path5.dirname(file);
 7992      if (!fs6.existsSync(dir)) {
 7993        mkdir.mkdirsSync(dir);
 7994      }
 7995      fs6.writeFileSync(file, ...args);
 7996    }
 7997    module2.exports = {
 7998      outputFile: u(outputFile),
 7999      outputFileSync
 8000    };
 8001  }
 8002});
 8003
 8004// node_modules/fs-extra/lib/json/output-json.js
 8005var require_output_json = __commonJS({
 8006  "node_modules/fs-extra/lib/json/output-json.js"(exports2, module2) {
 8007    "use strict";
 8008    var { stringify: stringify6 } = require_utils6();
 8009    var { outputFile } = require_output_file();
 8010    function outputJson(_0, _1) {
 8011      return __async(this, arguments, function* (file, data, options = {}) {
 8012        const str = stringify6(data, options);
 8013        yield outputFile(file, str, options);
 8014      });
 8015    }
 8016    module2.exports = outputJson;
 8017  }
 8018});
 8019
 8020// node_modules/fs-extra/lib/json/output-json-sync.js
 8021var require_output_json_sync = __commonJS({
 8022  "node_modules/fs-extra/lib/json/output-json-sync.js"(exports2, module2) {
 8023    "use strict";
 8024    var { stringify: stringify6 } = require_utils6();
 8025    var { outputFileSync } = require_output_file();
 8026    function outputJsonSync(file, data, options) {
 8027      const str = stringify6(data, options);
 8028      outputFileSync(file, str, options);
 8029    }
 8030    module2.exports = outputJsonSync;
 8031  }
 8032});
 8033
 8034// node_modules/fs-extra/lib/json/index.js
 8035var require_json = __commonJS({
 8036  "node_modules/fs-extra/lib/json/index.js"(exports2, module2) {
 8037    "use strict";
 8038    var u = require_universalify().fromPromise;
 8039    var jsonFile = require_jsonfile2();
 8040    jsonFile.outputJson = u(require_output_json());
 8041    jsonFile.outputJsonSync = require_output_json_sync();
 8042    jsonFile.outputJSON = jsonFile.outputJson;
 8043    jsonFile.outputJSONSync = jsonFile.outputJsonSync;
 8044    jsonFile.writeJSON = jsonFile.writeJson;
 8045    jsonFile.writeJSONSync = jsonFile.writeJsonSync;
 8046    jsonFile.readJSON = jsonFile.readJson;
 8047    jsonFile.readJSONSync = jsonFile.readJsonSync;
 8048    module2.exports = jsonFile;
 8049  }
 8050});
 8051
 8052// node_modules/fs-extra/lib/move/move.js
 8053var require_move = __commonJS({
 8054  "node_modules/fs-extra/lib/move/move.js"(exports2, module2) {
 8055    "use strict";
 8056    var fs6 = require_fs5();
 8057    var path5 = require("path");
 8058    var { copy } = require_copy2();
 8059    var { remove } = require_remove();
 8060    var { mkdirp } = require_mkdirs();
 8061    var { pathExists } = require_path_exists();
 8062    var stat = require_stat();
 8063    function move(_0, _1) {
 8064      return __async(this, arguments, function* (src, dest, opts = {}) {
 8065        const overwrite = opts.overwrite || opts.clobber || false;
 8066        const { srcStat, isChangingCase = false } = yield stat.checkPaths(src, dest, "move", opts);
 8067        yield stat.checkParentPaths(src, srcStat, dest, "move");
 8068        const destParent = path5.dirname(dest);
 8069        const parsedParentPath = path5.parse(destParent);
 8070        if (parsedParentPath.root !== destParent) {
 8071          yield mkdirp(destParent);
 8072        }
 8073        return doRename(src, dest, overwrite, isChangingCase);
 8074      });
 8075    }
 8076    function doRename(src, dest, overwrite, isChangingCase) {
 8077      return __async(this, null, function* () {
 8078        if (!isChangingCase) {
 8079          if (overwrite) {
 8080            yield remove(dest);
 8081          } else if (yield pathExists(dest)) {
 8082            throw new Error("dest already exists.");
 8083          }
 8084        }
 8085        try {
 8086          yield fs6.rename(src, dest);
 8087        } catch (err) {
 8088          if (err.code !== "EXDEV") {
 8089            throw err;
 8090          }
 8091          yield moveAcrossDevice(src, dest, overwrite);
 8092        }
 8093      });
 8094    }
 8095    function moveAcrossDevice(src, dest, overwrite) {
 8096      return __async(this, null, function* () {
 8097        const opts = {
 8098          overwrite,
 8099          errorOnExist: true,
 8100          preserveTimestamps: true
 8101        };
 8102        yield copy(src, dest, opts);
 8103        return remove(src);
 8104      });
 8105    }
 8106    module2.exports = move;
 8107  }
 8108});
 8109
 8110// node_modules/fs-extra/lib/move/move-sync.js
 8111var require_move_sync = __commonJS({
 8112  "node_modules/fs-extra/lib/move/move-sync.js"(exports2, module2) {
 8113    "use strict";
 8114    var fs6 = require_graceful_fs();
 8115    var path5 = require("path");
 8116    var copySync = require_copy2().copySync;
 8117    var removeSync = require_remove().removeSync;
 8118    var mkdirpSync = require_mkdirs().mkdirpSync;
 8119    var stat = require_stat();
 8120    function moveSync(src, dest, opts) {
 8121      opts = opts || {};
 8122      const overwrite = opts.overwrite || opts.clobber || false;
 8123      const { srcStat, isChangingCase = false } = stat.checkPathsSync(src, dest, "move", opts);
 8124      stat.checkParentPathsSync(src, srcStat, dest, "move");
 8125      if (!isParentRoot(dest)) mkdirpSync(path5.dirname(dest));
 8126      return doRename(src, dest, overwrite, isChangingCase);
 8127    }
 8128    function isParentRoot(dest) {
 8129      const parent = path5.dirname(dest);
 8130      const parsedPath = path5.parse(parent);
 8131      return parsedPath.root === parent;
 8132    }
 8133    function doRename(src, dest, overwrite, isChangingCase) {
 8134      if (isChangingCase) return rename(src, dest, overwrite);
 8135      if (overwrite) {
 8136        removeSync(dest);
 8137        return rename(src, dest, overwrite);
 8138      }
 8139      if (fs6.existsSync(dest)) throw new Error("dest already exists.");
 8140      return rename(src, dest, overwrite);
 8141    }
 8142    function rename(src, dest, overwrite) {
 8143      try {
 8144        fs6.renameSync(src, dest);
 8145      } catch (err) {
 8146        if (err.code !== "EXDEV") throw err;
 8147        return moveAcrossDevice(src, dest, overwrite);
 8148      }
 8149    }
 8150    function moveAcrossDevice(src, dest, overwrite) {
 8151      const opts = {
 8152        overwrite,
 8153        errorOnExist: true,
 8154        preserveTimestamps: true
 8155      };
 8156      copySync(src, dest, opts);
 8157      return removeSync(src);
 8158    }
 8159    module2.exports = moveSync;
 8160  }
 8161});
 8162
 8163// node_modules/fs-extra/lib/move/index.js
 8164var require_move2 = __commonJS({
 8165  "node_modules/fs-extra/lib/move/index.js"(exports2, module2) {
 8166    "use strict";
 8167    var u = require_universalify().fromPromise;
 8168    module2.exports = {
 8169      move: u(require_move()),
 8170      moveSync: require_move_sync()
 8171    };
 8172  }
 8173});
 8174
 8175// node_modules/fs-extra/lib/index.js
 8176var require_lib = __commonJS({
 8177  "node_modules/fs-extra/lib/index.js"(exports2, module2) {
 8178    "use strict";
 8179    module2.exports = __spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues(__spreadValues({}, require_fs5()), require_copy2()), require_empty()), require_ensure()), require_json()), require_mkdirs()), require_move2()), require_output_file()), require_path_exists()), require_remove());
 8180  }
 8181});
 8182
 8183// node_modules/create-require/create-require.js
 8184var require_create_require = __commonJS({
 8185  "node_modules/create-require/create-require.js"(exports2, module2) {
 8186    "use strict";
 8187    var nativeModule = require("module");
 8188    var path5 = require("path");
 8189    var fs6 = require("fs");
 8190    function createRequire2(filename) {
 8191      if (!filename) {
 8192        filename = process.cwd();
 8193      }
 8194      if (isDir(filename)) {
 8195        filename = path5.join(filename, "index.js");
 8196      }
 8197      if (nativeModule.createRequire) {
 8198        return nativeModule.createRequire(filename);
 8199      }
 8200      if (nativeModule.createRequireFromPath) {
 8201        return nativeModule.createRequireFromPath(filename);
 8202      }
 8203      return _createRequire2(filename);
 8204    }
 8205    function _createRequire2(filename) {
 8206      const mod = new nativeModule.Module(filename, null);
 8207      mod.filename = filename;
 8208      mod.paths = nativeModule.Module._nodeModulePaths(path5.dirname(filename));
 8209      mod._compile("module.exports = require;", filename);
 8210      return mod.exports;
 8211    }
 8212    function isDir(path6) {
 8213      try {
 8214        const stat = fs6.lstatSync(path6);
 8215        return stat.isDirectory();
 8216      } catch (e) {
 8217        return false;
 8218      }
 8219    }
 8220    module2.exports = createRequire2;
 8221  }
 8222});
 8223
 8224// node_modules/node-fetch-native/dist/shared/node-fetch-native.DfbY2q-x.mjs
 8225function f(e) {
 8226  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
 8227}
 8228var t, o, n;
 8229var init_node_fetch_native_DfbY2q_x = __esm({
 8230  "node_modules/node-fetch-native/dist/shared/node-fetch-native.DfbY2q-x.mjs"() {
 8231    "use strict";
 8232    t = Object.defineProperty;
 8233    o = (e, l) => t(e, "name", { value: l, configurable: true });
 8234    n = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
 8235    o(f, "getDefaultExportFromCjs");
 8236  }
 8237});
 8238
 8239// node_modules/node-fetch-native/dist/chunks/multipart-parser.mjs
 8240var multipart_parser_exports = {};
 8241__export(multipart_parser_exports, {
 8242  toFormData: () => Z
 8243});
 8244function v(u) {
 8245  const a = u.match(/\bfilename=("(.*?)"|([^()<>@,;:\\"/[\]?={}\s\t]+))($|;\s)/i);
 8246  if (!a) return;
 8247  const n4 = a[2] || a[3] || "";
 8248  let r2 = n4.slice(n4.lastIndexOf("\\") + 1);
 8249  return r2 = r2.replace(/%22/g, '"'), r2 = r2.replace(/&#(\d{4});/g, (d, l) => String.fromCharCode(l)), r2;
 8250}
 8251function Z(u, a) {
 8252  return __async(this, null, function* () {
 8253    if (!/multipart/i.test(a)) throw new TypeError("Failed to fetch");
 8254    const n4 = a.match(/boundary=(?:"([^"]+)"|([^;]+))/i);
 8255    if (!n4) throw new TypeError("no or bad content-type header, no multipart boundary");
 8256    const r2 = new k(n4[1] || n4[2]);
 8257    let d, l, c2, p2, e, i;
 8258    const A = [], H2 = new br(), O2 = E((s) => {
 8259      c2 += f2.decode(s, { stream: true });
 8260    }, "onPartData"), y = E((s) => {
 8261      A.push(s);
 8262    }, "appendToFile"), o3 = E(() => {
 8263      const s = new qn(A, i, { type: e });
 8264      H2.append(p2, s);
 8265    }, "appendFileToFormData"), L = E(() => {
 8266      H2.append(p2, c2);
 8267    }, "appendEntryToFormData"), f2 = new TextDecoder("utf-8");
 8268    f2.decode(), r2.onPartBegin = function() {
 8269      r2.onPartData = O2, r2.onPartEnd = L, d = "", l = "", c2 = "", p2 = "", e = "", i = null, A.length = 0;
 8270    }, r2.onHeaderField = function(s) {
 8271      d += f2.decode(s, { stream: true });
 8272    }, r2.onHeaderValue = function(s) {
 8273      l += f2.decode(s, { stream: true });
 8274    }, r2.onHeaderEnd = function() {
 8275      if (l += f2.decode(), d = d.toLowerCase(), d === "content-disposition") {
 8276        const s = l.match(/\bname=("([^"]*)"|([^()<>@,;:\\"/[\]?={}\s\t]+))/i);
 8277        s && (p2 = s[2] || s[3] || ""), i = v(l), i && (r2.onPartData = y, r2.onPartEnd = o3);
 8278      } else d === "content-type" && (e = l);
 8279      l = "", d = "";
 8280    };
 8281    try {
 8282      for (var iter = __forAwait(u), more, temp, error; more = !(temp = yield iter.next()).done; more = false) {
 8283        const s = temp.value;
 8284        r2.write(s);
 8285      }
 8286    } catch (temp) {
 8287      error = [temp];
 8288    } finally {
 8289      try {
 8290        more && (temp = iter.return) && (yield temp.call(iter));
 8291      } finally {
 8292        if (error)
 8293          throw error[0];
 8294      }
 8295    }
 8296    return r2.end(), H2;
 8297  });
 8298}
 8299var B, E, D, t2, w, R, g, N, x, P, C, I, M, $, m, F, k;
 8300var init_multipart_parser = __esm({
 8301  "node_modules/node-fetch-native/dist/chunks/multipart-parser.mjs"() {
 8302    "use strict";
 8303    init_node();
 8304    init_node_fetch_native_DfbY2q_x();
 8305    B = Object.defineProperty;
 8306    E = (u, a) => B(u, "name", { value: a, configurable: true });
 8307    D = 0;
 8308    t2 = { START_BOUNDARY: D++, HEADER_FIELD_START: D++, HEADER_FIELD: D++, HEADER_VALUE_START: D++, HEADER_VALUE: D++, HEADER_VALUE_ALMOST_DONE: D++, HEADERS_ALMOST_DONE: D++, PART_DATA_START: D++, PART_DATA: D++, END: D++ };
 8309    w = 1;
 8310    R = { PART_BOUNDARY: w, LAST_BOUNDARY: w *= 2 };
 8311    g = 10;
 8312    N = 13;
 8313    x = 32;
 8314    P = 45;
 8315    C = 58;
 8316    I = 97;
 8317    M = 122;
 8318    $ = E((u) => u | 32, "lower");
 8319    m = E(() => {
 8320    }, "noop");
 8321    F = class F2 {
 8322      constructor(a) {
 8323        this.index = 0, this.flags = 0, this.onHeaderEnd = m, this.onHeaderField = m, this.onHeadersEnd = m, this.onHeaderValue = m, this.onPartBegin = m, this.onPartData = m, this.onPartEnd = m, this.boundaryChars = {}, a = `\r
 8324--` + a;
 8325        const n4 = new Uint8Array(a.length);
 8326        for (let r2 = 0; r2 < a.length; r2++) n4[r2] = a.charCodeAt(r2), this.boundaryChars[n4[r2]] = true;
 8327        this.boundary = n4, this.lookbehind = new Uint8Array(this.boundary.length + 8), this.state = t2.START_BOUNDARY;
 8328      }
 8329      write(a) {
 8330        let n4 = 0;
 8331        const r2 = a.length;
 8332        let d = this.index, { lookbehind: l, boundary: c2, boundaryChars: p2, index: e, state: i, flags: A } = this;
 8333        const H2 = this.boundary.length, O2 = H2 - 1, y = a.length;
 8334        let o3, L;
 8335        const f2 = E((h2) => {
 8336          this[h2 + "Mark"] = n4;
 8337        }, "mark"), s = E((h2) => {
 8338          delete this[h2 + "Mark"];
 8339        }, "clear"), T2 = E((h2, S, _, U) => {
 8340          (S === void 0 || S !== _) && this[h2](U && U.subarray(S, _));
 8341        }, "callback"), b = E((h2, S) => {
 8342          const _ = h2 + "Mark";
 8343          _ in this && (S ? (T2(h2, this[_], n4, a), delete this[_]) : (T2(h2, this[_], a.length, a), this[_] = 0));
 8344        }, "dataCallback");
 8345        for (n4 = 0; n4 < r2; n4++) switch (o3 = a[n4], i) {
 8346          case t2.START_BOUNDARY:
 8347            if (e === c2.length - 2) {
 8348              if (o3 === P) A |= R.LAST_BOUNDARY;
 8349              else if (o3 !== N) return;
 8350              e++;
 8351              break;
 8352            } else if (e - 1 === c2.length - 2) {
 8353              if (A & R.LAST_BOUNDARY && o3 === P) i = t2.END, A = 0;
 8354              else if (!(A & R.LAST_BOUNDARY) && o3 === g) e = 0, T2("onPartBegin"), i = t2.HEADER_FIELD_START;
 8355              else return;
 8356              break;
 8357            }
 8358            o3 !== c2[e + 2] && (e = -2), o3 === c2[e + 2] && e++;
 8359            break;
 8360          case t2.HEADER_FIELD_START:
 8361            i = t2.HEADER_FIELD, f2("onHeaderField"), e = 0;
 8362          case t2.HEADER_FIELD:
 8363            if (o3 === N) {
 8364              s("onHeaderField"), i = t2.HEADERS_ALMOST_DONE;
 8365              break;
 8366            }
 8367            if (e++, o3 === P) break;
 8368            if (o3 === C) {
 8369              if (e === 1) return;
 8370              b("onHeaderField", true), i = t2.HEADER_VALUE_START;
 8371              break;
 8372            }
 8373            if (L = $(o3), L < I || L > M) return;
 8374            break;
 8375          case t2.HEADER_VALUE_START:
 8376            if (o3 === x) break;
 8377            f2("onHeaderValue"), i = t2.HEADER_VALUE;
 8378          case t2.HEADER_VALUE:
 8379            o3 === N && (b("onHeaderValue", true), T2("onHeaderEnd"), i = t2.HEADER_VALUE_ALMOST_DONE);
 8380            break;
 8381          case t2.HEADER_VALUE_ALMOST_DONE:
 8382            if (o3 !== g) return;
 8383            i = t2.HEADER_FIELD_START;
 8384            break;
 8385          case t2.HEADERS_ALMOST_DONE:
 8386            if (o3 !== g) return;
 8387            T2("onHeadersEnd"), i = t2.PART_DATA_START;
 8388            break;
 8389          case t2.PART_DATA_START:
 8390            i = t2.PART_DATA, f2("onPartData");
 8391          case t2.PART_DATA:
 8392            if (d = e, e === 0) {
 8393              for (n4 += O2; n4 < y && !(a[n4] in p2); ) n4 += H2;
 8394              n4 -= O2, o3 = a[n4];
 8395            }
 8396            if (e < c2.length) c2[e] === o3 ? (e === 0 && b("onPartData", true), e++) : e = 0;
 8397            else if (e === c2.length) e++, o3 === N ? A |= R.PART_BOUNDARY : o3 === P ? A |= R.LAST_BOUNDARY : e = 0;
 8398            else if (e - 1 === c2.length) if (A & R.PART_BOUNDARY) {
 8399              if (e = 0, o3 === g) {
 8400                A &= ~R.PART_BOUNDARY, T2("onPartEnd"), T2("onPartBegin"), i = t2.HEADER_FIELD_START;
 8401                break;
 8402              }
 8403            } else A & R.LAST_BOUNDARY && o3 === P ? (T2("onPartEnd"), i = t2.END, A = 0) : e = 0;
 8404            if (e > 0) l[e - 1] = o3;
 8405            else if (d > 0) {
 8406              const h2 = new Uint8Array(l.buffer, l.byteOffset, l.byteLength);
 8407              T2("onPartData", 0, d, h2), d = 0, f2("onPartData"), n4--;
 8408            }
 8409            break;
 8410          case t2.END:
 8411            break;
 8412          default:
 8413            throw new Error(`Unexpected state entered: ${i}`);
 8414        }
 8415        b("onHeaderField"), b("onHeaderValue"), b("onPartData"), this.index = e, this.state = i, this.flags = A;
 8416      }
 8417      end() {
 8418        if (this.state === t2.HEADER_FIELD_START && this.index === 0 || this.state === t2.PART_DATA && this.index === this.boundary.length) this.onPartEnd();
 8419        else if (this.state !== t2.END) throw new Error("MultipartParser.end(): stream ended unexpectedly");
 8420      }
 8421    };
 8422    E(F, "MultipartParser");
 8423    k = F;
 8424    E(v, "_fileName");
 8425    E(Z, "toFormData");
 8426  }
 8427});
 8428
 8429// node_modules/node-fetch-native/dist/node.mjs
 8430function Us(i) {
 8431  if (!/^data:/i.test(i)) throw new TypeError('`uri` does not appear to be a Data URI (must begin with "data:")');
 8432  i = i.replace(/\r?\n/g, "");
 8433  const o3 = i.indexOf(",");
 8434  if (o3 === -1 || o3 <= 4) throw new TypeError("malformed data: URI");
 8435  const a = i.substring(5, o3).split(";");
 8436  let f2 = "", l = false;
 8437  const p2 = a[0] || "text/plain";
 8438  let h2 = p2;
 8439  for (let A = 1; A < a.length; A++) a[A] === "base64" ? l = true : a[A] && (h2 += `;${a[A]}`, a[A].indexOf("charset=") === 0 && (f2 = a[A].substring(8)));
 8440  !a[0] && !f2.length && (h2 += ";charset=US-ASCII", f2 = "US-ASCII");
 8441  const S = l ? "base64" : "ascii", v2 = unescape(i.substring(o3 + 1)), w2 = Buffer.from(v2, S);
 8442  return w2.type = p2, w2.typeFull = h2, w2.charset = f2, w2;
 8443}
 8444function Ns() {
 8445  return bi || (bi = 1, (function(i, o3) {
 8446    (function(a, f2) {
 8447      f2(o3);
 8448    })(xs, function(a) {
 8449      function f2() {
 8450      }
 8451      n2(f2, "noop");
 8452      function l(e) {
 8453        return typeof e == "object" && e !== null || typeof e == "function";
 8454      }
 8455      n2(l, "typeIsObject");
 8456      const p2 = f2;
 8457      function h2(e, t3) {
 8458        try {
 8459          Object.defineProperty(e, "name", { value: t3, configurable: true });
 8460        } catch (e2) {
 8461        }
 8462      }
 8463      n2(h2, "setFunctionName");
 8464      const S = Promise, v2 = Promise.prototype.then, w2 = Promise.reject.bind(S);
 8465      function A(e) {
 8466        return new S(e);
 8467      }
 8468      n2(A, "newPromise");
 8469      function T2(e) {
 8470        return A((t3) => t3(e));
 8471      }
 8472      n2(T2, "promiseResolvedWith");
 8473      function b(e) {
 8474        return w2(e);
 8475      }
 8476      n2(b, "promiseRejectedWith");
 8477      function q(e, t3, r2) {
 8478        return v2.call(e, t3, r2);
 8479      }
 8480      n2(q, "PerformPromiseThen");
 8481      function g2(e, t3, r2) {
 8482        q(q(e, t3, r2), void 0, p2);
 8483      }
 8484      n2(g2, "uponPromise");
 8485      function V(e, t3) {
 8486        g2(e, t3);
 8487      }
 8488      n2(V, "uponFulfillment");
 8489      function I2(e, t3) {
 8490        g2(e, void 0, t3);
 8491      }
 8492      n2(I2, "uponRejection");
 8493      function F4(e, t3, r2) {
 8494        return q(e, t3, r2);
 8495      }
 8496      n2(F4, "transformPromiseWith");
 8497      function Q(e) {
 8498        q(e, void 0, p2);
 8499      }
 8500      n2(Q, "setPromiseIsHandledToTrue");
 8501      let ge = n2((e) => {
 8502        if (typeof queueMicrotask == "function") ge = queueMicrotask;
 8503        else {
 8504          const t3 = T2(void 0);
 8505          ge = n2((r2) => q(t3, r2), "_queueMicrotask");
 8506        }
 8507        return ge(e);
 8508      }, "_queueMicrotask");
 8509      function z(e, t3, r2) {
 8510        if (typeof e != "function") throw new TypeError("Argument is not a function");
 8511        return Function.prototype.apply.call(e, t3, r2);
 8512      }
 8513      n2(z, "reflectCall");
 8514      function j(e, t3, r2) {
 8515        try {
 8516          return T2(z(e, t3, r2));
 8517        } catch (s) {
 8518          return b(s);
 8519        }
 8520      }
 8521      n2(j, "promiseCall");
 8522      const U = 16384, bn = class bn {
 8523        constructor() {
 8524          this._cursor = 0, this._size = 0, this._front = { _elements: [], _next: void 0 }, this._back = this._front, this._cursor = 0, this._size = 0;
 8525        }
 8526        get length() {
 8527          return this._size;
 8528        }
 8529        push(t3) {
 8530          const r2 = this._back;
 8531          let s = r2;
 8532          r2._elements.length === U - 1 && (s = { _elements: [], _next: void 0 }), r2._elements.push(t3), s !== r2 && (this._back = s, r2._next = s), ++this._size;
 8533        }
 8534        shift() {
 8535          const t3 = this._front;
 8536          let r2 = t3;
 8537          const s = this._cursor;
 8538          let u = s + 1;
 8539          const c2 = t3._elements, d = c2[s];
 8540          return u === U && (r2 = t3._next, u = 0), --this._size, this._cursor = u, t3 !== r2 && (this._front = r2), c2[s] = void 0, d;
 8541        }
 8542        forEach(t3) {
 8543          let r2 = this._cursor, s = this._front, u = s._elements;
 8544          for (; (r2 !== u.length || s._next !== void 0) && !(r2 === u.length && (s = s._next, u = s._elements, r2 = 0, u.length === 0)); ) t3(u[r2]), ++r2;
 8545        }
 8546        peek() {
 8547          const t3 = this._front, r2 = this._cursor;
 8548          return t3._elements[r2];
 8549        }
 8550      };
 8551      n2(bn, "SimpleQueue");
 8552      let D2 = bn;
 8553      const jt = Symbol("[[AbortSteps]]"), Qn = Symbol("[[ErrorSteps]]"), Ar = Symbol("[[CancelSteps]]"), Br = Symbol("[[PullSteps]]"), kr = Symbol("[[ReleaseSteps]]");
 8554      function Yn(e, t3) {
 8555        e._ownerReadableStream = t3, t3._reader = e, t3._state === "readable" ? qr(e) : t3._state === "closed" ? xi(e) : Gn(e, t3._storedError);
 8556      }
 8557      n2(Yn, "ReadableStreamReaderGenericInitialize");
 8558      function Wr(e, t3) {
 8559        const r2 = e._ownerReadableStream;
 8560        return ie(r2, t3);
 8561      }
 8562      n2(Wr, "ReadableStreamReaderGenericCancel");
 8563      function _e(e) {
 8564        const t3 = e._ownerReadableStream;
 8565        t3._state === "readable" ? Or(e, new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")) : Ni(e, new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")), t3._readableStreamController[kr](), t3._reader = void 0, e._ownerReadableStream = void 0;
 8566      }
 8567      n2(_e, "ReadableStreamReaderGenericRelease");
 8568      function Lt(e) {
 8569        return new TypeError("Cannot " + e + " a stream using a released reader");
 8570      }
 8571      n2(Lt, "readerLockException");
 8572      function qr(e) {
 8573        e._closedPromise = A((t3, r2) => {
 8574          e._closedPromise_resolve = t3, e._closedPromise_reject = r2;
 8575        });
 8576      }
 8577      n2(qr, "defaultReaderClosedPromiseInitialize");
 8578      function Gn(e, t3) {
 8579        qr(e), Or(e, t3);
 8580      }
 8581      n2(Gn, "defaultReaderClosedPromiseInitializeAsRejected");
 8582      function xi(e) {
 8583        qr(e), Zn(e);
 8584      }
 8585      n2(xi, "defaultReaderClosedPromiseInitializeAsResolved");
 8586      function Or(e, t3) {
 8587        e._closedPromise_reject !== void 0 && (Q(e._closedPromise), e._closedPromise_reject(t3), e._closedPromise_resolve = void 0, e._closedPromise_reject = void 0);
 8588      }
 8589      n2(Or, "defaultReaderClosedPromiseReject");
 8590      function Ni(e, t3) {
 8591        Gn(e, t3);
 8592      }
 8593      n2(Ni, "defaultReaderClosedPromiseResetToRejected");
 8594      function Zn(e) {
 8595        e._closedPromise_resolve !== void 0 && (e._closedPromise_resolve(void 0), e._closedPromise_resolve = void 0, e._closedPromise_reject = void 0);
 8596      }
 8597      n2(Zn, "defaultReaderClosedPromiseResolve");
 8598      const Kn = Number.isFinite || function(e) {
 8599        return typeof e == "number" && isFinite(e);
 8600      }, Hi = Math.trunc || function(e) {
 8601        return e < 0 ? Math.ceil(e) : Math.floor(e);
 8602      };
 8603      function Vi(e) {
 8604        return typeof e == "object" || typeof e == "function";
 8605      }
 8606      n2(Vi, "isDictionary");
 8607      function ue(e, t3) {
 8608        if (e !== void 0 && !Vi(e)) throw new TypeError(`${t3} is not an object.`);
 8609      }
 8610      n2(ue, "assertDictionary");
 8611      function Z2(e, t3) {
 8612        if (typeof e != "function") throw new TypeError(`${t3} is not a function.`);
 8613      }
 8614      n2(Z2, "assertFunction");
 8615      function Qi(e) {
 8616        return typeof e == "object" && e !== null || typeof e == "function";
 8617      }
 8618      n2(Qi, "isObject");
 8619      function Jn(e, t3) {
 8620        if (!Qi(e)) throw new TypeError(`${t3} is not an object.`);
 8621      }
 8622      n2(Jn, "assertObject");
 8623      function Se(e, t3, r2) {
 8624        if (e === void 0) throw new TypeError(`Parameter ${t3} is required in '${r2}'.`);
 8625      }
 8626      n2(Se, "assertRequiredArgument");
 8627      function zr(e, t3, r2) {
 8628        if (e === void 0) throw new TypeError(`${t3} is required in '${r2}'.`);
 8629      }
 8630      n2(zr, "assertRequiredField");
 8631      function Ir(e) {
 8632        return Number(e);
 8633      }
 8634      n2(Ir, "convertUnrestrictedDouble");
 8635      function Xn(e) {
 8636        return e === 0 ? 0 : e;
 8637      }
 8638      n2(Xn, "censorNegativeZero");
 8639      function Yi(e) {
 8640        return Xn(Hi(e));
 8641      }
 8642      n2(Yi, "integerPart");
 8643      function Fr(e, t3) {
 8644        const s = Number.MAX_SAFE_INTEGER;
 8645        let u = Number(e);
 8646        if (u = Xn(u), !Kn(u)) throw new TypeError(`${t3} is not a finite number`);
 8647        if (u = Yi(u), u < 0 || u > s) throw new TypeError(`${t3} is outside the accepted range of 0 to ${s}, inclusive`);
 8648        return !Kn(u) || u === 0 ? 0 : u;
 8649      }
 8650      n2(Fr, "convertUnsignedLongLongWithEnforceRange");
 8651      function jr(e, t3) {
 8652        if (!We(e)) throw new TypeError(`${t3} is not a ReadableStream.`);
 8653      }
 8654      n2(jr, "assertReadableStream");
 8655      function Qe(e) {
 8656        return new fe(e);
 8657      }
 8658      n2(Qe, "AcquireReadableStreamDefaultReader");
 8659      function eo(e, t3) {
 8660        e._reader._readRequests.push(t3);
 8661      }
 8662      n2(eo, "ReadableStreamAddReadRequest");
 8663      function Lr(e, t3, r2) {
 8664        const u = e._reader._readRequests.shift();
 8665        r2 ? u._closeSteps() : u._chunkSteps(t3);
 8666      }
 8667      n2(Lr, "ReadableStreamFulfillReadRequest");
 8668      function $t(e) {
 8669        return e._reader._readRequests.length;
 8670      }
 8671      n2($t, "ReadableStreamGetNumReadRequests");
 8672      function to(e) {
 8673        const t3 = e._reader;
 8674        return !(t3 === void 0 || !Ee(t3));
 8675      }
 8676      n2(to, "ReadableStreamHasDefaultReader");
 8677      const mn = class mn {
 8678        constructor(t3) {
 8679          if (Se(t3, 1, "ReadableStreamDefaultReader"), jr(t3, "First parameter"), qe(t3)) throw new TypeError("This stream has already been locked for exclusive reading by another reader");
 8680          Yn(this, t3), this._readRequests = new D2();
 8681        }
 8682        get closed() {
 8683          return Ee(this) ? this._closedPromise : b(Dt("closed"));
 8684        }
 8685        cancel(t3 = void 0) {
 8686          return Ee(this) ? this._ownerReadableStream === void 0 ? b(Lt("cancel")) : Wr(this, t3) : b(Dt("cancel"));
 8687        }
 8688        read() {
 8689          if (!Ee(this)) return b(Dt("read"));
 8690          if (this._ownerReadableStream === void 0) return b(Lt("read from"));
 8691          let t3, r2;
 8692          const s = A((c2, d) => {
 8693            t3 = c2, r2 = d;
 8694          });
 8695          return _t(this, { _chunkSteps: n2((c2) => t3({ value: c2, done: false }), "_chunkSteps"), _closeSteps: n2(() => t3({ value: void 0, done: true }), "_closeSteps"), _errorSteps: n2((c2) => r2(c2), "_errorSteps") }), s;
 8696        }
 8697        releaseLock() {
 8698          if (!Ee(this)) throw Dt("releaseLock");
 8699          this._ownerReadableStream !== void 0 && Gi(this);
 8700        }
 8701      };
 8702      n2(mn, "ReadableStreamDefaultReader");
 8703      let fe = mn;
 8704      Object.defineProperties(fe.prototype, { cancel: { enumerable: true }, read: { enumerable: true }, releaseLock: { enumerable: true }, closed: { enumerable: true } }), h2(fe.prototype.cancel, "cancel"), h2(fe.prototype.read, "read"), h2(fe.prototype.releaseLock, "releaseLock"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(fe.prototype, Symbol.toStringTag, { value: "ReadableStreamDefaultReader", configurable: true });
 8705      function Ee(e) {
 8706        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_readRequests") ? false : e instanceof fe;
 8707      }
 8708      n2(Ee, "IsReadableStreamDefaultReader");
 8709      function _t(e, t3) {
 8710        const r2 = e._ownerReadableStream;
 8711        r2._disturbed = true, r2._state === "closed" ? t3._closeSteps() : r2._state === "errored" ? t3._errorSteps(r2._storedError) : r2._readableStreamController[Br](t3);
 8712      }
 8713      n2(_t, "ReadableStreamDefaultReaderRead");
 8714      function Gi(e) {
 8715        _e(e);
 8716        const t3 = new TypeError("Reader was released");
 8717        ro(e, t3);
 8718      }
 8719      n2(Gi, "ReadableStreamDefaultReaderRelease");
 8720      function ro(e, t3) {
 8721        const r2 = e._readRequests;
 8722        e._readRequests = new D2(), r2.forEach((s) => {
 8723          s._errorSteps(t3);
 8724        });
 8725      }
 8726      n2(ro, "ReadableStreamDefaultReaderErrorReadRequests");
 8727      function Dt(e) {
 8728        return new TypeError(`ReadableStreamDefaultReader.prototype.${e} can only be used on a ReadableStreamDefaultReader`);
 8729      }
 8730      n2(Dt, "defaultReaderBrandCheckException");
 8731      const Zi = Object.getPrototypeOf(Object.getPrototypeOf(function() {
 8732        return __asyncGenerator(this, null, function* () {
 8733        });
 8734      }).prototype || {}), yn = class yn {
 8735        constructor(t3, r2) {
 8736          this._ongoingPromise = void 0, this._isFinished = false, this._reader = t3, this._preventCancel = r2;
 8737        }
 8738        next() {
 8739          const t3 = n2(() => this._nextSteps(), "nextSteps");
 8740          return this._ongoingPromise = this._ongoingPromise ? F4(this._ongoingPromise, t3, t3) : t3(), this._ongoingPromise;
 8741        }
 8742        return(t3) {
 8743          const r2 = n2(() => this._returnSteps(t3), "returnSteps");
 8744          return this._ongoingPromise ? F4(this._ongoingPromise, r2, r2) : r2();
 8745        }
 8746        _nextSteps() {
 8747          if (this._isFinished) return Promise.resolve({ value: void 0, done: true });
 8748          const t3 = this._reader;
 8749          let r2, s;
 8750          const u = A((d, m2) => {
 8751            r2 = d, s = m2;
 8752          });
 8753          return _t(t3, { _chunkSteps: n2((d) => {
 8754            this._ongoingPromise = void 0, ge(() => r2({ value: d, done: false }));
 8755          }, "_chunkSteps"), _closeSteps: n2(() => {
 8756            this._ongoingPromise = void 0, this._isFinished = true, _e(t3), r2({ value: void 0, done: true });
 8757          }, "_closeSteps"), _errorSteps: n2((d) => {
 8758            this._ongoingPromise = void 0, this._isFinished = true, _e(t3), s(d);
 8759          }, "_errorSteps") }), u;
 8760        }
 8761        _returnSteps(t3) {
 8762          if (this._isFinished) return Promise.resolve({ value: t3, done: true });
 8763          this._isFinished = true;
 8764          const r2 = this._reader;
 8765          if (!this._preventCancel) {
 8766            const s = Wr(r2, t3);
 8767            return _e(r2), F4(s, () => ({ value: t3, done: true }));
 8768          }
 8769          return _e(r2), T2({ value: t3, done: true });
 8770        }
 8771      };
 8772      n2(yn, "ReadableStreamAsyncIteratorImpl");
 8773      let Mt = yn;
 8774      const no = { next() {
 8775        return oo(this) ? this._asyncIteratorImpl.next() : b(io("next"));
 8776      }, return(e) {
 8777        return oo(this) ? this._asyncIteratorImpl.return(e) : b(io("return"));
 8778      } };
 8779      Object.setPrototypeOf(no, Zi);
 8780      function Ki(e, t3) {
 8781        const r2 = Qe(e), s = new Mt(r2, t3), u = Object.create(no);
 8782        return u._asyncIteratorImpl = s, u;
 8783      }
 8784      n2(Ki, "AcquireReadableStreamAsyncIterator");
 8785      function oo(e) {
 8786        if (!l(e) || !Object.prototype.hasOwnProperty.call(e, "_asyncIteratorImpl")) return false;
 8787        try {
 8788          return e._asyncIteratorImpl instanceof Mt;
 8789        } catch (e2) {
 8790          return false;
 8791        }
 8792      }
 8793      n2(oo, "IsReadableStreamAsyncIterator");
 8794      function io(e) {
 8795        return new TypeError(`ReadableStreamAsyncIterator.${e} can only be used on a ReadableSteamAsyncIterator`);
 8796      }
 8797      n2(io, "streamAsyncIteratorBrandCheckException");
 8798      const ao = Number.isNaN || function(e) {
 8799        return e !== e;
 8800      };
 8801      var $r, Dr, Mr;
 8802      function St(e) {
 8803        return e.slice();
 8804      }
 8805      n2(St, "CreateArrayFromList");
 8806      function so(e, t3, r2, s, u) {
 8807        new Uint8Array(e).set(new Uint8Array(r2, s, u), t3);
 8808      }
 8809      n2(so, "CopyDataBlockBytes");
 8810      let we = n2((e) => (typeof e.transfer == "function" ? we = n2((t3) => t3.transfer(), "TransferArrayBuffer") : typeof structuredClone == "function" ? we = n2((t3) => structuredClone(t3, { transfer: [t3] }), "TransferArrayBuffer") : we = n2((t3) => t3, "TransferArrayBuffer"), we(e)), "TransferArrayBuffer"), Ae = n2((e) => (typeof e.detached == "boolean" ? Ae = n2((t3) => t3.detached, "IsDetachedBuffer") : Ae = n2((t3) => t3.byteLength === 0, "IsDetachedBuffer"), Ae(e)), "IsDetachedBuffer");
 8811      function lo(e, t3, r2) {
 8812        if (e.slice) return e.slice(t3, r2);
 8813        const s = r2 - t3, u = new ArrayBuffer(s);
 8814        return so(u, 0, e, t3, s), u;
 8815      }
 8816      n2(lo, "ArrayBufferSlice");
 8817      function Ut(e, t3) {
 8818        const r2 = e[t3];
 8819        if (r2 != null) {
 8820          if (typeof r2 != "function") throw new TypeError(`${String(t3)} is not a function`);
 8821          return r2;
 8822        }
 8823      }
 8824      n2(Ut, "GetMethod");
 8825      function Ji(e) {
 8826        const t3 = { [Symbol.iterator]: () => e.iterator }, r2 = (function() {
 8827          return __asyncGenerator(this, null, function* () {
 8828            return yield* __yieldStar(t3);
 8829          });
 8830        })(), s = r2.next;
 8831        return { iterator: r2, nextMethod: s, done: false };
 8832      }
 8833      n2(Ji, "CreateAsyncFromSyncIterator");
 8834      const Ur = (Mr = ($r = Symbol.asyncIterator) !== null && $r !== void 0 ? $r : (Dr = Symbol.for) === null || Dr === void 0 ? void 0 : Dr.call(Symbol, "Symbol.asyncIterator")) !== null && Mr !== void 0 ? Mr : "@@asyncIterator";
 8835      function uo(e, t3 = "sync", r2) {
 8836        if (r2 === void 0) if (t3 === "async") {
 8837          if (r2 = Ut(e, Ur), r2 === void 0) {
 8838            const c2 = Ut(e, Symbol.iterator), d = uo(e, "sync", c2);
 8839            return Ji(d);
 8840          }
 8841        } else r2 = Ut(e, Symbol.iterator);
 8842        if (r2 === void 0) throw new TypeError("The object is not iterable");
 8843        const s = z(r2, e, []);
 8844        if (!l(s)) throw new TypeError("The iterator method must return an object");
 8845        const u = s.next;
 8846        return { iterator: s, nextMethod: u, done: false };
 8847      }
 8848      n2(uo, "GetIterator");
 8849      function Xi(e) {
 8850        const t3 = z(e.nextMethod, e.iterator, []);
 8851        if (!l(t3)) throw new TypeError("The iterator.next() method must return an object");
 8852        return t3;
 8853      }
 8854      n2(Xi, "IteratorNext");
 8855      function ea(e) {
 8856        return !!e.done;
 8857      }
 8858      n2(ea, "IteratorComplete");
 8859      function ta(e) {
 8860        return e.value;
 8861      }
 8862      n2(ta, "IteratorValue");
 8863      function ra(e) {
 8864        return !(typeof e != "number" || ao(e) || e < 0);
 8865      }
 8866      n2(ra, "IsNonNegativeNumber");
 8867      function fo(e) {
 8868        const t3 = lo(e.buffer, e.byteOffset, e.byteOffset + e.byteLength);
 8869        return new Uint8Array(t3);
 8870      }
 8871      n2(fo, "CloneAsUint8Array");
 8872      function xr(e) {
 8873        const t3 = e._queue.shift();
 8874        return e._queueTotalSize -= t3.size, e._queueTotalSize < 0 && (e._queueTotalSize = 0), t3.value;
 8875      }
 8876      n2(xr, "DequeueValue");
 8877      function Nr(e, t3, r2) {
 8878        if (!ra(r2) || r2 === 1 / 0) throw new RangeError("Size must be a finite, non-NaN, non-negative number.");
 8879        e._queue.push({ value: t3, size: r2 }), e._queueTotalSize += r2;
 8880      }
 8881      n2(Nr, "EnqueueValueWithSize");
 8882      function na(e) {
 8883        return e._queue.peek().value;
 8884      }
 8885      n2(na, "PeekQueueValue");
 8886      function Be(e) {
 8887        e._queue = new D2(), e._queueTotalSize = 0;
 8888      }
 8889      n2(Be, "ResetQueue");
 8890      function co(e) {
 8891        return e === DataView;
 8892      }
 8893      n2(co, "isDataViewConstructor");
 8894      function oa(e) {
 8895        return co(e.constructor);
 8896      }
 8897      n2(oa, "isDataView");
 8898      function ia(e) {
 8899        return co(e) ? 1 : e.BYTES_PER_ELEMENT;
 8900      }
 8901      n2(ia, "arrayBufferViewElementSize");
 8902      const gn = class gn {
 8903        constructor() {
 8904          throw new TypeError("Illegal constructor");
 8905        }
 8906        get view() {
 8907          if (!Hr(this)) throw Zr("view");
 8908          return this._view;
 8909        }
 8910        respond(t3) {
 8911          if (!Hr(this)) throw Zr("respond");
 8912          if (Se(t3, 1, "respond"), t3 = Fr(t3, "First parameter"), this._associatedReadableByteStreamController === void 0) throw new TypeError("This BYOB request has been invalidated");
 8913          if (Ae(this._view.buffer)) throw new TypeError("The BYOB request's buffer has been detached and so cannot be used as a response");
 8914          Vt(this._associatedReadableByteStreamController, t3);
 8915        }
 8916        respondWithNewView(t3) {
 8917          if (!Hr(this)) throw Zr("respondWithNewView");
 8918          if (Se(t3, 1, "respondWithNewView"), !ArrayBuffer.isView(t3)) throw new TypeError("You can only respond with array buffer views");
 8919          if (this._associatedReadableByteStreamController === void 0) throw new TypeError("This BYOB request has been invalidated");
 8920          if (Ae(t3.buffer)) throw new TypeError("The given view's buffer has been detached and so cannot be used as a response");
 8921          Qt(this._associatedReadableByteStreamController, t3);
 8922        }
 8923      };
 8924      n2(gn, "ReadableStreamBYOBRequest");
 8925      let Re = gn;
 8926      Object.defineProperties(Re.prototype, { respond: { enumerable: true }, respondWithNewView: { enumerable: true }, view: { enumerable: true } }), h2(Re.prototype.respond, "respond"), h2(Re.prototype.respondWithNewView, "respondWithNewView"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(Re.prototype, Symbol.toStringTag, { value: "ReadableStreamBYOBRequest", configurable: true });
 8927      const _n = class _n {
 8928        constructor() {
 8929          throw new TypeError("Illegal constructor");
 8930        }
 8931        get byobRequest() {
 8932          if (!Ie(this)) throw Rt("byobRequest");
 8933          return Gr(this);
 8934        }
 8935        get desiredSize() {
 8936          if (!Ie(this)) throw Rt("desiredSize");
 8937          return Ro(this);
 8938        }
 8939        close() {
 8940          if (!Ie(this)) throw Rt("close");
 8941          if (this._closeRequested) throw new TypeError("The stream has already been closed; do not close it again!");
 8942          const t3 = this._controlledReadableByteStream._state;
 8943          if (t3 !== "readable") throw new TypeError(`The stream (in ${t3} state) is not in the readable state and cannot be closed`);
 8944          wt(this);
 8945        }
 8946        enqueue(t3) {
 8947          if (!Ie(this)) throw Rt("enqueue");
 8948          if (Se(t3, 1, "enqueue"), !ArrayBuffer.isView(t3)) throw new TypeError("chunk must be an array buffer view");
 8949          if (t3.byteLength === 0) throw new TypeError("chunk must have non-zero byteLength");
 8950          if (t3.buffer.byteLength === 0) throw new TypeError("chunk's buffer must have non-zero byteLength");
 8951          if (this._closeRequested) throw new TypeError("stream is closed or draining");
 8952          const r2 = this._controlledReadableByteStream._state;
 8953          if (r2 !== "readable") throw new TypeError(`The stream (in ${r2} state) is not in the readable state and cannot be enqueued to`);
 8954          Ht(this, t3);
 8955        }
 8956        error(t3 = void 0) {
 8957          if (!Ie(this)) throw Rt("error");
 8958          K(this, t3);
 8959        }
 8960        [Ar](t3) {
 8961          ho(this), Be(this);
 8962          const r2 = this._cancelAlgorithm(t3);
 8963          return Nt(this), r2;
 8964        }
 8965        [Br](t3) {
 8966          const r2 = this._controlledReadableByteStream;
 8967          if (this._queueTotalSize > 0) {
 8968            wo(this, t3);
 8969            return;
 8970          }
 8971          const s = this._autoAllocateChunkSize;
 8972          if (s !== void 0) {
 8973            let u;
 8974            try {
 8975              u = new ArrayBuffer(s);
 8976            } catch (d) {
 8977              t3._errorSteps(d);
 8978              return;
 8979            }
 8980            const c2 = { buffer: u, bufferByteLength: s, byteOffset: 0, byteLength: s, bytesFilled: 0, minimumFill: 1, elementSize: 1, viewConstructor: Uint8Array, readerType: "default" };
 8981            this._pendingPullIntos.push(c2);
 8982          }
 8983          eo(r2, t3), Fe(this);
 8984        }
 8985        [kr]() {
 8986          if (this._pendingPullIntos.length > 0) {
 8987            const t3 = this._pendingPullIntos.peek();
 8988            t3.readerType = "none", this._pendingPullIntos = new D2(), this._pendingPullIntos.push(t3);
 8989          }
 8990        }
 8991      };
 8992      n2(_n, "ReadableByteStreamController");
 8993      let te = _n;
 8994      Object.defineProperties(te.prototype, { close: { enumerable: true }, enqueue: { enumerable: true }, error: { enumerable: true }, byobRequest: { enumerable: true }, desiredSize: { enumerable: true } }), h2(te.prototype.close, "close"), h2(te.prototype.enqueue, "enqueue"), h2(te.prototype.error, "error"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(te.prototype, Symbol.toStringTag, { value: "ReadableByteStreamController", configurable: true });
 8995      function Ie(e) {
 8996        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_controlledReadableByteStream") ? false : e instanceof te;
 8997      }
 8998      n2(Ie, "IsReadableByteStreamController");
 8999      function Hr(e) {
 9000        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_associatedReadableByteStreamController") ? false : e instanceof Re;
 9001      }
 9002      n2(Hr, "IsReadableStreamBYOBRequest");
 9003      function Fe(e) {
 9004        if (!fa(e)) return;
 9005        if (e._pulling) {
 9006          e._pullAgain = true;
 9007          return;
 9008        }
 9009        e._pulling = true;
 9010        const r2 = e._pullAlgorithm();
 9011        g2(r2, () => (e._pulling = false, e._pullAgain && (e._pullAgain = false, Fe(e)), null), (s) => (K(e, s), null));
 9012      }
 9013      n2(Fe, "ReadableByteStreamControllerCallPullIfNeeded");
 9014      function ho(e) {
 9015        Qr(e), e._pendingPullIntos = new D2();
 9016      }
 9017      n2(ho, "ReadableByteStreamControllerClearPendingPullIntos");
 9018      function Vr(e, t3) {
 9019        let r2 = false;
 9020        e._state === "closed" && (r2 = true);
 9021        const s = po(t3);
 9022        t3.readerType === "default" ? Lr(e, s, r2) : ma(e, s, r2);
 9023      }
 9024      n2(Vr, "ReadableByteStreamControllerCommitPullIntoDescriptor");
 9025      function po(e) {
 9026        const t3 = e.bytesFilled, r2 = e.elementSize;
 9027        return new e.viewConstructor(e.buffer, e.byteOffset, t3 / r2);
 9028      }
 9029      n2(po, "ReadableByteStreamControllerConvertPullIntoDescriptor");
 9030      function xt(e, t3, r2, s) {
 9031        e._queue.push({ buffer: t3, byteOffset: r2, byteLength: s }), e._queueTotalSize += s;
 9032      }
 9033      n2(xt, "ReadableByteStreamControllerEnqueueChunkToQueue");
 9034      function bo(e, t3, r2, s) {
 9035        let u;
 9036        try {
 9037          u = lo(t3, r2, r2 + s);
 9038        } catch (c2) {
 9039          throw K(e, c2), c2;
 9040        }
 9041        xt(e, u, 0, s);
 9042      }
 9043      n2(bo, "ReadableByteStreamControllerEnqueueClonedChunkToQueue");
 9044      function mo(e, t3) {
 9045        t3.bytesFilled > 0 && bo(e, t3.buffer, t3.byteOffset, t3.bytesFilled), Ye(e);
 9046      }
 9047      n2(mo, "ReadableByteStreamControllerEnqueueDetachedPullIntoToQueue");
 9048      function yo(e, t3) {
 9049        const r2 = Math.min(e._queueTotalSize, t3.byteLength - t3.bytesFilled), s = t3.bytesFilled + r2;
 9050        let u = r2, c2 = false;
 9051        const d = s % t3.elementSize, m2 = s - d;
 9052        m2 >= t3.minimumFill && (u = m2 - t3.bytesFilled, c2 = true);
 9053        const R3 = e._queue;
 9054        for (; u > 0; ) {
 9055          const y = R3.peek(), C2 = Math.min(u, y.byteLength), P2 = t3.byteOffset + t3.bytesFilled;
 9056          so(t3.buffer, P2, y.buffer, y.byteOffset, C2), y.byteLength === C2 ? R3.shift() : (y.byteOffset += C2, y.byteLength -= C2), e._queueTotalSize -= C2, go(e, C2, t3), u -= C2;
 9057        }
 9058        return c2;
 9059      }
 9060      n2(yo, "ReadableByteStreamControllerFillPullIntoDescriptorFromQueue");
 9061      function go(e, t3, r2) {
 9062        r2.bytesFilled += t3;
 9063      }
 9064      n2(go, "ReadableByteStreamControllerFillHeadPullIntoDescriptor");
 9065      function _o(e) {
 9066        e._queueTotalSize === 0 && e._closeRequested ? (Nt(e), At(e._controlledReadableByteStream)) : Fe(e);
 9067      }
 9068      n2(_o, "ReadableByteStreamControllerHandleQueueDrain");
 9069      function Qr(e) {
 9070        e._byobRequest !== null && (e._byobRequest._associatedReadableByteStreamController = void 0, e._byobRequest._view = null, e._byobRequest = null);
 9071      }
 9072      n2(Qr, "ReadableByteStreamControllerInvalidateBYOBRequest");
 9073      function Yr(e) {
 9074        for (; e._pendingPullIntos.length > 0; ) {
 9075          if (e._queueTotalSize === 0) return;
 9076          const t3 = e._pendingPullIntos.peek();
 9077          yo(e, t3) && (Ye(e), Vr(e._controlledReadableByteStream, t3));
 9078        }
 9079      }
 9080      n2(Yr, "ReadableByteStreamControllerProcessPullIntoDescriptorsUsingQueue");
 9081      function aa(e) {
 9082        const t3 = e._controlledReadableByteStream._reader;
 9083        for (; t3._readRequests.length > 0; ) {
 9084          if (e._queueTotalSize === 0) return;
 9085          const r2 = t3._readRequests.shift();
 9086          wo(e, r2);
 9087        }
 9088      }
 9089      n2(aa, "ReadableByteStreamControllerProcessReadRequestsUsingQueue");
 9090      function sa(e, t3, r2, s) {
 9091        const u = e._controlledReadableByteStream, c2 = t3.constructor, d = ia(c2), { byteOffset: m2, byteLength: R3 } = t3, y = r2 * d;
 9092        let C2;
 9093        try {
 9094          C2 = we(t3.buffer);
 9095        } catch (B2) {
 9096          s._errorSteps(B2);
 9097          return;
 9098        }
 9099        const P2 = { buffer: C2, bufferByteLength: C2.byteLength, byteOffset: m2, byteLength: R3, bytesFilled: 0, minimumFill: y, elementSize: d, viewConstructor: c2, readerType: "byob" };
 9100        if (e._pendingPullIntos.length > 0) {
 9101          e._pendingPullIntos.push(P2), Po(u, s);
 9102          return;
 9103        }
 9104        if (u._state === "closed") {
 9105          const B2 = new c2(P2.buffer, P2.byteOffset, 0);
 9106          s._closeSteps(B2);
 9107          return;
 9108        }
 9109        if (e._queueTotalSize > 0) {
 9110          if (yo(e, P2)) {
 9111            const B2 = po(P2);
 9112            _o(e), s._chunkSteps(B2);
 9113            return;
 9114          }
 9115          if (e._closeRequested) {
 9116            const B2 = new TypeError("Insufficient bytes to fill elements in the given buffer");
 9117            K(e, B2), s._errorSteps(B2);
 9118            return;
 9119          }
 9120        }
 9121        e._pendingPullIntos.push(P2), Po(u, s), Fe(e);
 9122      }
 9123      n2(sa, "ReadableByteStreamControllerPullInto");
 9124      function la(e, t3) {
 9125        t3.readerType === "none" && Ye(e);
 9126        const r2 = e._controlledReadableByteStream;
 9127        if (Kr(r2)) for (; vo(r2) > 0; ) {
 9128          const s = Ye(e);
 9129          Vr(r2, s);
 9130        }
 9131      }
 9132      n2(la, "ReadableByteStreamControllerRespondInClosedState");
 9133      function ua(e, t3, r2) {
 9134        if (go(e, t3, r2), r2.readerType === "none") {
 9135          mo(e, r2), Yr(e);
 9136          return;
 9137        }
 9138        if (r2.bytesFilled < r2.minimumFill) return;
 9139        Ye(e);
 9140        const s = r2.bytesFilled % r2.elementSize;
 9141        if (s > 0) {
 9142          const u = r2.byteOffset + r2.bytesFilled;
 9143          bo(e, r2.buffer, u - s, s);
 9144        }
 9145        r2.bytesFilled -= s, Vr(e._controlledReadableByteStream, r2), Yr(e);
 9146      }
 9147      n2(ua, "ReadableByteStreamControllerRespondInReadableState");
 9148      function So(e, t3) {
 9149        const r2 = e._pendingPullIntos.peek();
 9150        Qr(e), e._controlledReadableByteStream._state === "closed" ? la(e, r2) : ua(e, t3, r2), Fe(e);
 9151      }
 9152      n2(So, "ReadableByteStreamControllerRespondInternal");
 9153      function Ye(e) {
 9154        return e._pendingPullIntos.shift();
 9155      }
 9156      n2(Ye, "ReadableByteStreamControllerShiftPendingPullInto");
 9157      function fa(e) {
 9158        const t3 = e._controlledReadableByteStream;
 9159        return t3._state !== "readable" || e._closeRequested || !e._started ? false : !!(to(t3) && $t(t3) > 0 || Kr(t3) && vo(t3) > 0 || Ro(e) > 0);
 9160      }
 9161      n2(fa, "ReadableByteStreamControllerShouldCallPull");
 9162      function Nt(e) {
 9163        e._pullAlgorithm = void 0, e._cancelAlgorithm = void 0;
 9164      }
 9165      n2(Nt, "ReadableByteStreamControllerClearAlgorithms");
 9166      function wt(e) {
 9167        const t3 = e._controlledReadableByteStream;
 9168        if (!(e._closeRequested || t3._state !== "readable")) {
 9169          if (e._queueTotalSize > 0) {
 9170            e._closeRequested = true;
 9171            return;
 9172          }
 9173          if (e._pendingPullIntos.length > 0) {
 9174            const r2 = e._pendingPullIntos.peek();
 9175            if (r2.bytesFilled % r2.elementSize !== 0) {
 9176              const s = new TypeError("Insufficient bytes to fill elements in the given buffer");
 9177              throw K(e, s), s;
 9178            }
 9179          }
 9180          Nt(e), At(t3);
 9181        }
 9182      }
 9183      n2(wt, "ReadableByteStreamControllerClose");
 9184      function Ht(e, t3) {
 9185        const r2 = e._controlledReadableByteStream;
 9186        if (e._closeRequested || r2._state !== "readable") return;
 9187        const { buffer: s, byteOffset: u, byteLength: c2 } = t3;
 9188        if (Ae(s)) throw new TypeError("chunk's buffer is detached and so cannot be enqueued");
 9189        const d = we(s);
 9190        if (e._pendingPullIntos.length > 0) {
 9191          const m2 = e._pendingPullIntos.peek();
 9192          if (Ae(m2.buffer)) throw new TypeError("The BYOB request's buffer has been detached and so cannot be filled with an enqueued chunk");
 9193          Qr(e), m2.buffer = we(m2.buffer), m2.readerType === "none" && mo(e, m2);
 9194        }
 9195        if (to(r2)) if (aa(e), $t(r2) === 0) xt(e, d, u, c2);
 9196        else {
 9197          e._pendingPullIntos.length > 0 && Ye(e);
 9198          const m2 = new Uint8Array(d, u, c2);
 9199          Lr(r2, m2, false);
 9200        }
 9201        else Kr(r2) ? (xt(e, d, u, c2), Yr(e)) : xt(e, d, u, c2);
 9202        Fe(e);
 9203      }
 9204      n2(Ht, "ReadableByteStreamControllerEnqueue");
 9205      function K(e, t3) {
 9206        const r2 = e._controlledReadableByteStream;
 9207        r2._state === "readable" && (ho(e), Be(e), Nt(e), Zo(r2, t3));
 9208      }
 9209      n2(K, "ReadableByteStreamControllerError");
 9210      function wo(e, t3) {
 9211        const r2 = e._queue.shift();
 9212        e._queueTotalSize -= r2.byteLength, _o(e);
 9213        const s = new Uint8Array(r2.buffer, r2.byteOffset, r2.byteLength);
 9214        t3._chunkSteps(s);
 9215      }
 9216      n2(wo, "ReadableByteStreamControllerFillReadRequestFromQueue");
 9217      function Gr(e) {
 9218        if (e._byobRequest === null && e._pendingPullIntos.length > 0) {
 9219          const t3 = e._pendingPullIntos.peek(), r2 = new Uint8Array(t3.buffer, t3.byteOffset + t3.bytesFilled, t3.byteLength - t3.bytesFilled), s = Object.create(Re.prototype);
 9220          da(s, e, r2), e._byobRequest = s;
 9221        }
 9222        return e._byobRequest;
 9223      }
 9224      n2(Gr, "ReadableByteStreamControllerGetBYOBRequest");
 9225      function Ro(e) {
 9226        const t3 = e._controlledReadableByteStream._state;
 9227        return t3 === "errored" ? null : t3 === "closed" ? 0 : e._strategyHWM - e._queueTotalSize;
 9228      }
 9229      n2(Ro, "ReadableByteStreamControllerGetDesiredSize");
 9230      function Vt(e, t3) {
 9231        const r2 = e._pendingPullIntos.peek();
 9232        if (e._controlledReadableByteStream._state === "closed") {
 9233          if (t3 !== 0) throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream");
 9234        } else {
 9235          if (t3 === 0) throw new TypeError("bytesWritten must be greater than 0 when calling respond() on a readable stream");
 9236          if (r2.bytesFilled + t3 > r2.byteLength) throw new RangeError("bytesWritten out of range");
 9237        }
 9238        r2.buffer = we(r2.buffer), So(e, t3);
 9239      }
 9240      n2(Vt, "ReadableByteStreamControllerRespond");
 9241      function Qt(e, t3) {
 9242        const r2 = e._pendingPullIntos.peek();
 9243        if (e._controlledReadableByteStream._state === "closed") {
 9244          if (t3.byteLength !== 0) throw new TypeError("The view's length must be 0 when calling respondWithNewView() on a closed stream");
 9245        } else if (t3.byteLength === 0) throw new TypeError("The view's length must be greater than 0 when calling respondWithNewView() on a readable stream");
 9246        if (r2.byteOffset + r2.bytesFilled !== t3.byteOffset) throw new RangeError("The region specified by view does not match byobRequest");
 9247        if (r2.bufferByteLength !== t3.buffer.byteLength) throw new RangeError("The buffer of view has different capacity than byobRequest");
 9248        if (r2.bytesFilled + t3.byteLength > r2.byteLength) throw new RangeError("The region specified by view is larger than byobRequest");
 9249        const u = t3.byteLength;
 9250        r2.buffer = we(t3.buffer), So(e, u);
 9251      }
 9252      n2(Qt, "ReadableByteStreamControllerRespondWithNewView");
 9253      function To(e, t3, r2, s, u, c2, d) {
 9254        t3._controlledReadableByteStream = e, t3._pullAgain = false, t3._pulling = false, t3._byobRequest = null, t3._queue = t3._queueTotalSize = void 0, Be(t3), t3._closeRequested = false, t3._started = false, t3._strategyHWM = c2, t3._pullAlgorithm = s, t3._cancelAlgorithm = u, t3._autoAllocateChunkSize = d, t3._pendingPullIntos = new D2(), e._readableStreamController = t3;
 9255        const m2 = r2();
 9256        g2(T2(m2), () => (t3._started = true, Fe(t3), null), (R3) => (K(t3, R3), null));
 9257      }
 9258      n2(To, "SetUpReadableByteStreamController");
 9259      function ca(e, t3, r2) {
 9260        const s = Object.create(te.prototype);
 9261        let u, c2, d;
 9262        t3.start !== void 0 ? u = n2(() => t3.start(s), "startAlgorithm") : u = n2(() => {
 9263        }, "startAlgorithm"), t3.pull !== void 0 ? c2 = n2(() => t3.pull(s), "pullAlgorithm") : c2 = n2(() => T2(void 0), "pullAlgorithm"), t3.cancel !== void 0 ? d = n2((R3) => t3.cancel(R3), "cancelAlgorithm") : d = n2(() => T2(void 0), "cancelAlgorithm");
 9264        const m2 = t3.autoAllocateChunkSize;
 9265        if (m2 === 0) throw new TypeError("autoAllocateChunkSize must be greater than 0");
 9266        To(e, s, u, c2, d, r2, m2);
 9267      }
 9268      n2(ca, "SetUpReadableByteStreamControllerFromUnderlyingSource");
 9269      function da(e, t3, r2) {
 9270        e._associatedReadableByteStreamController = t3, e._view = r2;
 9271      }
 9272      n2(da, "SetUpReadableStreamBYOBRequest");
 9273      function Zr(e) {
 9274        return new TypeError(`ReadableStreamBYOBRequest.prototype.${e} can only be used on a ReadableStreamBYOBRequest`);
 9275      }
 9276      n2(Zr, "byobRequestBrandCheckException");
 9277      function Rt(e) {
 9278        return new TypeError(`ReadableByteStreamController.prototype.${e} can only be used on a ReadableByteStreamController`);
 9279      }
 9280      n2(Rt, "byteStreamControllerBrandCheckException");
 9281      function ha(e, t3) {
 9282        ue(e, t3);
 9283        const r2 = e == null ? void 0 : e.mode;
 9284        return { mode: r2 === void 0 ? void 0 : pa(r2, `${t3} has member 'mode' that`) };
 9285      }
 9286      n2(ha, "convertReaderOptions");
 9287      function pa(e, t3) {
 9288        if (e = `${e}`, e !== "byob") throw new TypeError(`${t3} '${e}' is not a valid enumeration value for ReadableStreamReaderMode`);
 9289        return e;
 9290      }
 9291      n2(pa, "convertReadableStreamReaderMode");
 9292      function ba(e, t3) {
 9293        var r2;
 9294        ue(e, t3);
 9295        const s = (r2 = e == null ? void 0 : e.min) !== null && r2 !== void 0 ? r2 : 1;
 9296        return { min: Fr(s, `${t3} has member 'min' that`) };
 9297      }
 9298      n2(ba, "convertByobReadOptions");
 9299      function Co(e) {
 9300        return new ce(e);
 9301      }
 9302      n2(Co, "AcquireReadableStreamBYOBReader");
 9303      function Po(e, t3) {
 9304        e._reader._readIntoRequests.push(t3);
 9305      }
 9306      n2(Po, "ReadableStreamAddReadIntoRequest");
 9307      function ma(e, t3, r2) {
 9308        const u = e._reader._readIntoRequests.shift();
 9309        r2 ? u._closeSteps(t3) : u._chunkSteps(t3);
 9310      }
 9311      n2(ma, "ReadableStreamFulfillReadIntoRequest");
 9312      function vo(e) {
 9313        return e._reader._readIntoRequests.length;
 9314      }
 9315      n2(vo, "ReadableStreamGetNumReadIntoRequests");
 9316      function Kr(e) {
 9317        const t3 = e._reader;
 9318        return !(t3 === void 0 || !je(t3));
 9319      }
 9320      n2(Kr, "ReadableStreamHasBYOBReader");
 9321      const Sn = class Sn {
 9322        constructor(t3) {
 9323          if (Se(t3, 1, "ReadableStreamBYOBReader"), jr(t3, "First parameter"), qe(t3)) throw new TypeError("This stream has already been locked for exclusive reading by another reader");
 9324          if (!Ie(t3._readableStreamController)) throw new TypeError("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");
 9325          Yn(this, t3), this._readIntoRequests = new D2();
 9326        }
 9327        get closed() {
 9328          return je(this) ? this._closedPromise : b(Yt("closed"));
 9329        }
 9330        cancel(t3 = void 0) {
 9331          return je(this) ? this._ownerReadableStream === void 0 ? b(Lt("cancel")) : Wr(this, t3) : b(Yt("cancel"));
 9332        }
 9333        read(t3, r2 = {}) {
 9334          if (!je(this)) return b(Yt("read"));
 9335          if (!ArrayBuffer.isView(t3)) return b(new TypeError("view must be an array buffer view"));
 9336          if (t3.byteLength === 0) return b(new TypeError("view must have non-zero byteLength"));
 9337          if (t3.buffer.byteLength === 0) return b(new TypeError("view's buffer must have non-zero byteLength"));
 9338          if (Ae(t3.buffer)) return b(new TypeError("view's buffer has been detached"));
 9339          let s;
 9340          try {
 9341            s = ba(r2, "options");
 9342          } catch (y) {
 9343            return b(y);
 9344          }
 9345          const u = s.min;
 9346          if (u === 0) return b(new TypeError("options.min must be greater than 0"));
 9347          if (oa(t3)) {
 9348            if (u > t3.byteLength) return b(new RangeError("options.min must be less than or equal to view's byteLength"));
 9349          } else if (u > t3.length) return b(new RangeError("options.min must be less than or equal to view's length"));
 9350          if (this._ownerReadableStream === void 0) return b(Lt("read from"));
 9351          let c2, d;
 9352          const m2 = A((y, C2) => {
 9353            c2 = y, d = C2;
 9354          });
 9355          return Eo(this, t3, u, { _chunkSteps: n2((y) => c2({ value: y, done: false }), "_chunkSteps"), _closeSteps: n2((y) => c2({ value: y, done: true }), "_closeSteps"), _errorSteps: n2((y) => d(y), "_errorSteps") }), m2;
 9356        }
 9357        releaseLock() {
 9358          if (!je(this)) throw Yt("releaseLock");
 9359          this._ownerReadableStream !== void 0 && ya(this);
 9360        }
 9361      };
 9362      n2(Sn, "ReadableStreamBYOBReader");
 9363      let ce = Sn;
 9364      Object.defineProperties(ce.prototype, { cancel: { enumerable: true }, read: { enumerable: true }, releaseLock: { enumerable: true }, closed: { enumerable: true } }), h2(ce.prototype.cancel, "cancel"), h2(ce.prototype.read, "read"), h2(ce.prototype.releaseLock, "releaseLock"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(ce.prototype, Symbol.toStringTag, { value: "ReadableStreamBYOBReader", configurable: true });
 9365      function je(e) {
 9366        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_readIntoRequests") ? false : e instanceof ce;
 9367      }
 9368      n2(je, "IsReadableStreamBYOBReader");
 9369      function Eo(e, t3, r2, s) {
 9370        const u = e._ownerReadableStream;
 9371        u._disturbed = true, u._state === "errored" ? s._errorSteps(u._storedError) : sa(u._readableStreamController, t3, r2, s);
 9372      }
 9373      n2(Eo, "ReadableStreamBYOBReaderRead");
 9374      function ya(e) {
 9375        _e(e);
 9376        const t3 = new TypeError("Reader was released");
 9377        Ao(e, t3);
 9378      }
 9379      n2(ya, "ReadableStreamBYOBReaderRelease");
 9380      function Ao(e, t3) {
 9381        const r2 = e._readIntoRequests;
 9382        e._readIntoRequests = new D2(), r2.forEach((s) => {
 9383          s._errorSteps(t3);
 9384        });
 9385      }
 9386      n2(Ao, "ReadableStreamBYOBReaderErrorReadIntoRequests");
 9387      function Yt(e) {
 9388        return new TypeError(`ReadableStreamBYOBReader.prototype.${e} can only be used on a ReadableStreamBYOBReader`);
 9389      }
 9390      n2(Yt, "byobReaderBrandCheckException");
 9391      function Tt(e, t3) {
 9392        const { highWaterMark: r2 } = e;
 9393        if (r2 === void 0) return t3;
 9394        if (ao(r2) || r2 < 0) throw new RangeError("Invalid highWaterMark");
 9395        return r2;
 9396      }
 9397      n2(Tt, "ExtractHighWaterMark");
 9398      function Gt(e) {
 9399        const { size: t3 } = e;
 9400        return t3 || (() => 1);
 9401      }
 9402      n2(Gt, "ExtractSizeAlgorithm");
 9403      function Zt(e, t3) {
 9404        ue(e, t3);
 9405        const r2 = e == null ? void 0 : e.highWaterMark, s = e == null ? void 0 : e.size;
 9406        return { highWaterMark: r2 === void 0 ? void 0 : Ir(r2), size: s === void 0 ? void 0 : ga(s, `${t3} has member 'size' that`) };
 9407      }
 9408      n2(Zt, "convertQueuingStrategy");
 9409      function ga(e, t3) {
 9410        return Z2(e, t3), (r2) => Ir(e(r2));
 9411      }
 9412      n2(ga, "convertQueuingStrategySize");
 9413      function _a2(e, t3) {
 9414        ue(e, t3);
 9415        const r2 = e == null ? void 0 : e.abort, s = e == null ? void 0 : e.close, u = e == null ? void 0 : e.start, c2 = e == null ? void 0 : e.type, d = e == null ? void 0 : e.write;
 9416        return { abort: r2 === void 0 ? void 0 : Sa(r2, e, `${t3} has member 'abort' that`), close: s === void 0 ? void 0 : wa(s, e, `${t3} has member 'close' that`), start: u === void 0 ? void 0 : Ra(u, e, `${t3} has member 'start' that`), write: d === void 0 ? void 0 : Ta(d, e, `${t3} has member 'write' that`), type: c2 };
 9417      }
 9418      n2(_a2, "convertUnderlyingSink");
 9419      function Sa(e, t3, r2) {
 9420        return Z2(e, r2), (s) => j(e, t3, [s]);
 9421      }
 9422      n2(Sa, "convertUnderlyingSinkAbortCallback");
 9423      function wa(e, t3, r2) {
 9424        return Z2(e, r2), () => j(e, t3, []);
 9425      }
 9426      n2(wa, "convertUnderlyingSinkCloseCallback");
 9427      function Ra(e, t3, r2) {
 9428        return Z2(e, r2), (s) => z(e, t3, [s]);
 9429      }
 9430      n2(Ra, "convertUnderlyingSinkStartCallback");
 9431      function Ta(e, t3, r2) {
 9432        return Z2(e, r2), (s, u) => j(e, t3, [s, u]);
 9433      }
 9434      n2(Ta, "convertUnderlyingSinkWriteCallback");
 9435      function Bo(e, t3) {
 9436        if (!Ge(e)) throw new TypeError(`${t3} is not a WritableStream.`);
 9437      }
 9438      n2(Bo, "assertWritableStream");
 9439      function Ca(e) {
 9440        if (typeof e != "object" || e === null) return false;
 9441        try {
 9442          return typeof e.aborted == "boolean";
 9443        } catch (e2) {
 9444          return false;
 9445        }
 9446      }
 9447      n2(Ca, "isAbortSignal");
 9448      const Pa = typeof AbortController == "function";
 9449      function va() {
 9450        if (Pa) return new AbortController();
 9451      }
 9452      n2(va, "createAbortController");
 9453      const wn = class wn {
 9454        constructor(t3 = {}, r2 = {}) {
 9455          t3 === void 0 ? t3 = null : Jn(t3, "First parameter");
 9456          const s = Zt(r2, "Second parameter"), u = _a2(t3, "First parameter");
 9457          if (Wo(this), u.type !== void 0) throw new RangeError("Invalid type is specified");
 9458          const d = Gt(s), m2 = Tt(s, 1);
 9459          Da(this, u, m2, d);
 9460        }
 9461        get locked() {
 9462          if (!Ge(this)) throw tr("locked");
 9463          return Ze(this);
 9464        }
 9465        abort(t3 = void 0) {
 9466          return Ge(this) ? Ze(this) ? b(new TypeError("Cannot abort a stream that already has a writer")) : Kt(this, t3) : b(tr("abort"));
 9467        }
 9468        close() {
 9469          return Ge(this) ? Ze(this) ? b(new TypeError("Cannot close a stream that already has a writer")) : he(this) ? b(new TypeError("Cannot close an already-closing stream")) : qo(this) : b(tr("close"));
 9470        }
 9471        getWriter() {
 9472          if (!Ge(this)) throw tr("getWriter");
 9473          return ko(this);
 9474        }
 9475      };
 9476      n2(wn, "WritableStream");
 9477      let de = wn;
 9478      Object.defineProperties(de.prototype, { abort: { enumerable: true }, close: { enumerable: true }, getWriter: { enumerable: true }, locked: { enumerable: true } }), h2(de.prototype.abort, "abort"), h2(de.prototype.close, "close"), h2(de.prototype.getWriter, "getWriter"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(de.prototype, Symbol.toStringTag, { value: "WritableStream", configurable: true });
 9479      function ko(e) {
 9480        return new re(e);
 9481      }
 9482      n2(ko, "AcquireWritableStreamDefaultWriter");
 9483      function Ea(e, t3, r2, s, u = 1, c2 = () => 1) {
 9484        const d = Object.create(de.prototype);
 9485        Wo(d);
 9486        const m2 = Object.create(ke.prototype);
 9487        return Lo(d, m2, e, t3, r2, s, u, c2), d;
 9488      }
 9489      n2(Ea, "CreateWritableStream");
 9490      function Wo(e) {
 9491        e._state = "writable", e._storedError = void 0, e._writer = void 0, e._writableStreamController = void 0, e._writeRequests = new D2(), e._inFlightWriteRequest = void 0, e._closeRequest = void 0, e._inFlightCloseRequest = void 0, e._pendingAbortRequest = void 0, e._backpressure = false;
 9492      }
 9493      n2(Wo, "InitializeWritableStream");
 9494      function Ge(e) {
 9495        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_writableStreamController") ? false : e instanceof de;
 9496      }
 9497      n2(Ge, "IsWritableStream");
 9498      function Ze(e) {
 9499        return e._writer !== void 0;
 9500      }
 9501      n2(Ze, "IsWritableStreamLocked");
 9502      function Kt(e, t3) {
 9503        var r2;
 9504        if (e._state === "closed" || e._state === "errored") return T2(void 0);
 9505        e._writableStreamController._abortReason = t3, (r2 = e._writableStreamController._abortController) === null || r2 === void 0 || r2.abort(t3);
 9506        const s = e._state;
 9507        if (s === "closed" || s === "errored") return T2(void 0);
 9508        if (e._pendingAbortRequest !== void 0) return e._pendingAbortRequest._promise;
 9509        let u = false;
 9510        s === "erroring" && (u = true, t3 = void 0);
 9511        const c2 = A((d, m2) => {
 9512          e._pendingAbortRequest = { _promise: void 0, _resolve: d, _reject: m2, _reason: t3, _wasAlreadyErroring: u };
 9513        });
 9514        return e._pendingAbortRequest._promise = c2, u || Xr(e, t3), c2;
 9515      }
 9516      n2(Kt, "WritableStreamAbort");
 9517      function qo(e) {
 9518        const t3 = e._state;
 9519        if (t3 === "closed" || t3 === "errored") return b(new TypeError(`The stream (in ${t3} state) is not in the writable state and cannot be closed`));
 9520        const r2 = A((u, c2) => {
 9521          const d = { _resolve: u, _reject: c2 };
 9522          e._closeRequest = d;
 9523        }), s = e._writer;
 9524        return s !== void 0 && e._backpressure && t3 === "writable" && ln(s), Ma(e._writableStreamController), r2;
 9525      }
 9526      n2(qo, "WritableStreamClose");
 9527      function Aa(e) {
 9528        return A((r2, s) => {
 9529          const u = { _resolve: r2, _reject: s };
 9530          e._writeRequests.push(u);
 9531        });
 9532      }
 9533      n2(Aa, "WritableStreamAddWriteRequest");
 9534      function Jr(e, t3) {
 9535        if (e._state === "writable") {
 9536          Xr(e, t3);
 9537          return;
 9538        }
 9539        en(e);
 9540      }
 9541      n2(Jr, "WritableStreamDealWithRejection");
 9542      function Xr(e, t3) {
 9543        const r2 = e._writableStreamController;
 9544        e._state = "erroring", e._storedError = t3;
 9545        const s = e._writer;
 9546        s !== void 0 && zo(s, t3), !Oa(e) && r2._started && en(e);
 9547      }
 9548      n2(Xr, "WritableStreamStartErroring");
 9549      function en(e) {
 9550        e._state = "errored", e._writableStreamController[Qn]();
 9551        const t3 = e._storedError;
 9552        if (e._writeRequests.forEach((u) => {
 9553          u._reject(t3);
 9554        }), e._writeRequests = new D2(), e._pendingAbortRequest === void 0) {
 9555          Jt(e);
 9556          return;
 9557        }
 9558        const r2 = e._pendingAbortRequest;
 9559        if (e._pendingAbortRequest = void 0, r2._wasAlreadyErroring) {
 9560          r2._reject(t3), Jt(e);
 9561          return;
 9562        }
 9563        const s = e._writableStreamController[jt](r2._reason);
 9564        g2(s, () => (r2._resolve(), Jt(e), null), (u) => (r2._reject(u), Jt(e), null));
 9565      }
 9566      n2(en, "WritableStreamFinishErroring");
 9567      function Ba(e) {
 9568        e._inFlightWriteRequest._resolve(void 0), e._inFlightWriteRequest = void 0;
 9569      }
 9570      n2(Ba, "WritableStreamFinishInFlightWrite");
 9571      function ka(e, t3) {
 9572        e._inFlightWriteRequest._reject(t3), e._inFlightWriteRequest = void 0, Jr(e, t3);
 9573      }
 9574      n2(ka, "WritableStreamFinishInFlightWriteWithError");
 9575      function Wa(e) {
 9576        e._inFlightCloseRequest._resolve(void 0), e._inFlightCloseRequest = void 0, e._state === "erroring" && (e._storedError = void 0, e._pendingAbortRequest !== void 0 && (e._pendingAbortRequest._resolve(), e._pendingAbortRequest = void 0)), e._state = "closed";
 9577        const r2 = e._writer;
 9578        r2 !== void 0 && Uo(r2);
 9579      }
 9580      n2(Wa, "WritableStreamFinishInFlightClose");
 9581      function qa(e, t3) {
 9582        e._inFlightCloseRequest._reject(t3), e._inFlightCloseRequest = void 0, e._pendingAbortRequest !== void 0 && (e._pendingAbortRequest._reject(t3), e._pendingAbortRequest = void 0), Jr(e, t3);
 9583      }
 9584      n2(qa, "WritableStreamFinishInFlightCloseWithError");
 9585      function he(e) {
 9586        return !(e._closeRequest === void 0 && e._inFlightCloseRequest === void 0);
 9587      }
 9588      n2(he, "WritableStreamCloseQueuedOrInFlight");
 9589      function Oa(e) {
 9590        return !(e._inFlightWriteRequest === void 0 && e._inFlightCloseRequest === void 0);
 9591      }
 9592      n2(Oa, "WritableStreamHasOperationMarkedInFlight");
 9593      function za(e) {
 9594        e._inFlightCloseRequest = e._closeRequest, e._closeRequest = void 0;
 9595      }
 9596      n2(za, "WritableStreamMarkCloseRequestInFlight");
 9597      function Ia(e) {
 9598        e._inFlightWriteRequest = e._writeRequests.shift();
 9599      }
 9600      n2(Ia, "WritableStreamMarkFirstWriteRequestInFlight");
 9601      function Jt(e) {
 9602        e._closeRequest !== void 0 && (e._closeRequest._reject(e._storedError), e._closeRequest = void 0);
 9603        const t3 = e._writer;
 9604        t3 !== void 0 && an(t3, e._storedError);
 9605      }
 9606      n2(Jt, "WritableStreamRejectCloseAndClosedPromiseIfNeeded");
 9607      function tn(e, t3) {
 9608        const r2 = e._writer;
 9609        r2 !== void 0 && t3 !== e._backpressure && (t3 ? Ya(r2) : ln(r2)), e._backpressure = t3;
 9610      }
 9611      n2(tn, "WritableStreamUpdateBackpressure");
 9612      const Rn = class Rn {
 9613        constructor(t3) {
 9614          if (Se(t3, 1, "WritableStreamDefaultWriter"), Bo(t3, "First parameter"), Ze(t3)) throw new TypeError("This stream has already been locked for exclusive writing by another writer");
 9615          this._ownerWritableStream = t3, t3._writer = this;
 9616          const r2 = t3._state;
 9617          if (r2 === "writable") !he(t3) && t3._backpressure ? nr(this) : xo(this), rr(this);
 9618          else if (r2 === "erroring") sn(this, t3._storedError), rr(this);
 9619          else if (r2 === "closed") xo(this), Va(this);
 9620          else {
 9621            const s = t3._storedError;
 9622            sn(this, s), Mo(this, s);
 9623          }
 9624        }
 9625        get closed() {
 9626          return Le(this) ? this._closedPromise : b($e("closed"));
 9627        }
 9628        get desiredSize() {
 9629          if (!Le(this)) throw $e("desiredSize");
 9630          if (this._ownerWritableStream === void 0) throw Pt("desiredSize");
 9631          return $a(this);
 9632        }
 9633        get ready() {
 9634          return Le(this) ? this._readyPromise : b($e("ready"));
 9635        }
 9636        abort(t3 = void 0) {
 9637          return Le(this) ? this._ownerWritableStream === void 0 ? b(Pt("abort")) : Fa(this, t3) : b($e("abort"));
 9638        }
 9639        close() {
 9640          if (!Le(this)) return b($e("close"));
 9641          const t3 = this._ownerWritableStream;
 9642          return t3 === void 0 ? b(Pt("close")) : he(t3) ? b(new TypeError("Cannot close an already-closing stream")) : Oo(this);
 9643        }
 9644        releaseLock() {
 9645          if (!Le(this)) throw $e("releaseLock");
 9646          this._ownerWritableStream !== void 0 && Io(this);
 9647        }
 9648        write(t3 = void 0) {
 9649          return Le(this) ? this._ownerWritableStream === void 0 ? b(Pt("write to")) : Fo(this, t3) : b($e("write"));
 9650        }
 9651      };
 9652      n2(Rn, "WritableStreamDefaultWriter");
 9653      let re = Rn;
 9654      Object.defineProperties(re.prototype, { abort: { enumerable: true }, close: { enumerable: true }, releaseLock: { enumerable: true }, write: { enumerable: true }, closed: { enumerable: true }, desiredSize: { enumerable: true }, ready: { enumerable: true } }), h2(re.prototype.abort, "abort"), h2(re.prototype.close, "close"), h2(re.prototype.releaseLock, "releaseLock"), h2(re.prototype.write, "write"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(re.prototype, Symbol.toStringTag, { value: "WritableStreamDefaultWriter", configurable: true });
 9655      function Le(e) {
 9656        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_ownerWritableStream") ? false : e instanceof re;
 9657      }
 9658      n2(Le, "IsWritableStreamDefaultWriter");
 9659      function Fa(e, t3) {
 9660        const r2 = e._ownerWritableStream;
 9661        return Kt(r2, t3);
 9662      }
 9663      n2(Fa, "WritableStreamDefaultWriterAbort");
 9664      function Oo(e) {
 9665        const t3 = e._ownerWritableStream;
 9666        return qo(t3);
 9667      }
 9668      n2(Oo, "WritableStreamDefaultWriterClose");
 9669      function ja(e) {
 9670        const t3 = e._ownerWritableStream, r2 = t3._state;
 9671        return he(t3) || r2 === "closed" ? T2(void 0) : r2 === "errored" ? b(t3._storedError) : Oo(e);
 9672      }
 9673      n2(ja, "WritableStreamDefaultWriterCloseWithErrorPropagation");
 9674      function La(e, t3) {
 9675        e._closedPromiseState === "pending" ? an(e, t3) : Qa(e, t3);
 9676      }
 9677      n2(La, "WritableStreamDefaultWriterEnsureClosedPromiseRejected");
 9678      function zo(e, t3) {
 9679        e._readyPromiseState === "pending" ? No(e, t3) : Ga(e, t3);
 9680      }
 9681      n2(zo, "WritableStreamDefaultWriterEnsureReadyPromiseRejected");
 9682      function $a(e) {
 9683        const t3 = e._ownerWritableStream, r2 = t3._state;
 9684        return r2 === "errored" || r2 === "erroring" ? null : r2 === "closed" ? 0 : $o(t3._writableStreamController);
 9685      }
 9686      n2($a, "WritableStreamDefaultWriterGetDesiredSize");
 9687      function Io(e) {
 9688        const t3 = e._ownerWritableStream, r2 = new TypeError("Writer was released and can no longer be used to monitor the stream's closedness");
 9689        zo(e, r2), La(e, r2), t3._writer = void 0, e._ownerWritableStream = void 0;
 9690      }
 9691      n2(Io, "WritableStreamDefaultWriterRelease");
 9692      function Fo(e, t3) {
 9693        const r2 = e._ownerWritableStream, s = r2._writableStreamController, u = Ua(s, t3);
 9694        if (r2 !== e._ownerWritableStream) return b(Pt("write to"));
 9695        const c2 = r2._state;
 9696        if (c2 === "errored") return b(r2._storedError);
 9697        if (he(r2) || c2 === "closed") return b(new TypeError("The stream is closing or closed and cannot be written to"));
 9698        if (c2 === "erroring") return b(r2._storedError);
 9699        const d = Aa(r2);
 9700        return xa(s, t3, u), d;
 9701      }
 9702      n2(Fo, "WritableStreamDefaultWriterWrite");
 9703      const jo = {}, Tn = class Tn {
 9704        constructor() {
 9705          throw new TypeError("Illegal constructor");
 9706        }
 9707        get abortReason() {
 9708          if (!rn(this)) throw on2("abortReason");
 9709          return this._abortReason;
 9710        }
 9711        get signal() {
 9712          if (!rn(this)) throw on2("signal");
 9713          if (this._abortController === void 0) throw new TypeError("WritableStreamDefaultController.prototype.signal is not supported");
 9714          return this._abortController.signal;
 9715        }
 9716        error(t3 = void 0) {
 9717          if (!rn(this)) throw on2("error");
 9718          this._controlledWritableStream._state === "writable" && Do(this, t3);
 9719        }
 9720        [jt](t3) {
 9721          const r2 = this._abortAlgorithm(t3);
 9722          return Xt(this), r2;
 9723        }
 9724        [Qn]() {
 9725          Be(this);
 9726        }
 9727      };
 9728      n2(Tn, "WritableStreamDefaultController");
 9729      let ke = Tn;
 9730      Object.defineProperties(ke.prototype, { abortReason: { enumerable: true }, signal: { enumerable: true }, error: { enumerable: true } }), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(ke.prototype, Symbol.toStringTag, { value: "WritableStreamDefaultController", configurable: true });
 9731      function rn(e) {
 9732        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_controlledWritableStream") ? false : e instanceof ke;
 9733      }
 9734      n2(rn, "IsWritableStreamDefaultController");
 9735      function Lo(e, t3, r2, s, u, c2, d, m2) {
 9736        t3._controlledWritableStream = e, e._writableStreamController = t3, t3._queue = void 0, t3._queueTotalSize = void 0, Be(t3), t3._abortReason = void 0, t3._abortController = va(), t3._started = false, t3._strategySizeAlgorithm = m2, t3._strategyHWM = d, t3._writeAlgorithm = s, t3._closeAlgorithm = u, t3._abortAlgorithm = c2;
 9737        const R3 = nn(t3);
 9738        tn(e, R3);
 9739        const y = r2(), C2 = T2(y);
 9740        g2(C2, () => (t3._started = true, er(t3), null), (P2) => (t3._started = true, Jr(e, P2), null));
 9741      }
 9742      n2(Lo, "SetUpWritableStreamDefaultController");
 9743      function Da(e, t3, r2, s) {
 9744        const u = Object.create(ke.prototype);
 9745        let c2, d, m2, R3;
 9746        t3.start !== void 0 ? c2 = n2(() => t3.start(u), "startAlgorithm") : c2 = n2(() => {
 9747        }, "startAlgorithm"), t3.write !== void 0 ? d = n2((y) => t3.write(y, u), "writeAlgorithm") : d = n2(() => T2(void 0), "writeAlgorithm"), t3.close !== void 0 ? m2 = n2(() => t3.close(), "closeAlgorithm") : m2 = n2(() => T2(void 0), "closeAlgorithm"), t3.abort !== void 0 ? R3 = n2((y) => t3.abort(y), "abortAlgorithm") : R3 = n2(() => T2(void 0), "abortAlgorithm"), Lo(e, u, c2, d, m2, R3, r2, s);
 9748      }
 9749      n2(Da, "SetUpWritableStreamDefaultControllerFromUnderlyingSink");
 9750      function Xt(e) {
 9751        e._writeAlgorithm = void 0, e._closeAlgorithm = void 0, e._abortAlgorithm = void 0, e._strategySizeAlgorithm = void 0;
 9752      }
 9753      n2(Xt, "WritableStreamDefaultControllerClearAlgorithms");
 9754      function Ma(e) {
 9755        Nr(e, jo, 0), er(e);
 9756      }
 9757      n2(Ma, "WritableStreamDefaultControllerClose");
 9758      function Ua(e, t3) {
 9759        try {
 9760          return e._strategySizeAlgorithm(t3);
 9761        } catch (r2) {
 9762          return Ct(e, r2), 1;
 9763        }
 9764      }
 9765      n2(Ua, "WritableStreamDefaultControllerGetChunkSize");
 9766      function $o(e) {
 9767        return e._strategyHWM - e._queueTotalSize;
 9768      }
 9769      n2($o, "WritableStreamDefaultControllerGetDesiredSize");
 9770      function xa(e, t3, r2) {
 9771        try {
 9772          Nr(e, t3, r2);
 9773        } catch (u) {
 9774          Ct(e, u);
 9775          return;
 9776        }
 9777        const s = e._controlledWritableStream;
 9778        if (!he(s) && s._state === "writable") {
 9779          const u = nn(e);
 9780          tn(s, u);
 9781        }
 9782        er(e);
 9783      }
 9784      n2(xa, "WritableStreamDefaultControllerWrite");
 9785      function er(e) {
 9786        const t3 = e._controlledWritableStream;
 9787        if (!e._started || t3._inFlightWriteRequest !== void 0) return;
 9788        if (t3._state === "erroring") {
 9789          en(t3);
 9790          return;
 9791        }
 9792        if (e._queue.length === 0) return;
 9793        const s = na(e);
 9794        s === jo ? Na(e) : Ha(e, s);
 9795      }
 9796      n2(er, "WritableStreamDefaultControllerAdvanceQueueIfNeeded");
 9797      function Ct(e, t3) {
 9798        e._controlledWritableStream._state === "writable" && Do(e, t3);
 9799      }
 9800      n2(Ct, "WritableStreamDefaultControllerErrorIfNeeded");
 9801      function Na(e) {
 9802        const t3 = e._controlledWritableStream;
 9803        za(t3), xr(e);
 9804        const r2 = e._closeAlgorithm();
 9805        Xt(e), g2(r2, () => (Wa(t3), null), (s) => (qa(t3, s), null));
 9806      }
 9807      n2(Na, "WritableStreamDefaultControllerProcessClose");
 9808      function Ha(e, t3) {
 9809        const r2 = e._controlledWritableStream;
 9810        Ia(r2);
 9811        const s = e._writeAlgorithm(t3);
 9812        g2(s, () => {
 9813          Ba(r2);
 9814          const u = r2._state;
 9815          if (xr(e), !he(r2) && u === "writable") {
 9816            const c2 = nn(e);
 9817            tn(r2, c2);
 9818          }
 9819          return er(e), null;
 9820        }, (u) => (r2._state === "writable" && Xt(e), ka(r2, u), null));
 9821      }
 9822      n2(Ha, "WritableStreamDefaultControllerProcessWrite");
 9823      function nn(e) {
 9824        return $o(e) <= 0;
 9825      }
 9826      n2(nn, "WritableStreamDefaultControllerGetBackpressure");
 9827      function Do(e, t3) {
 9828        const r2 = e._controlledWritableStream;
 9829        Xt(e), Xr(r2, t3);
 9830      }
 9831      n2(Do, "WritableStreamDefaultControllerError");
 9832      function tr(e) {
 9833        return new TypeError(`WritableStream.prototype.${e} can only be used on a WritableStream`);
 9834      }
 9835      n2(tr, "streamBrandCheckException$2");
 9836      function on2(e) {
 9837        return new TypeError(`WritableStreamDefaultController.prototype.${e} can only be used on a WritableStreamDefaultController`);
 9838      }
 9839      n2(on2, "defaultControllerBrandCheckException$2");
 9840      function $e(e) {
 9841        return new TypeError(`WritableStreamDefaultWriter.prototype.${e} can only be used on a WritableStreamDefaultWriter`);
 9842      }
 9843      n2($e, "defaultWriterBrandCheckException");
 9844      function Pt(e) {
 9845        return new TypeError("Cannot " + e + " a stream using a released writer");
 9846      }
 9847      n2(Pt, "defaultWriterLockException");
 9848      function rr(e) {
 9849        e._closedPromise = A((t3, r2) => {
 9850          e._closedPromise_resolve = t3, e._closedPromise_reject = r2, e._closedPromiseState = "pending";
 9851        });
 9852      }
 9853      n2(rr, "defaultWriterClosedPromiseInitialize");
 9854      function Mo(e, t3) {
 9855        rr(e), an(e, t3);
 9856      }
 9857      n2(Mo, "defaultWriterClosedPromiseInitializeAsRejected");
 9858      function Va(e) {
 9859        rr(e), Uo(e);
 9860      }
 9861      n2(Va, "defaultWriterClosedPromiseInitializeAsResolved");
 9862      function an(e, t3) {
 9863        e._closedPromise_reject !== void 0 && (Q(e._closedPromise), e._closedPromise_reject(t3), e._closedPromise_resolve = void 0, e._closedPromise_reject = void 0, e._closedPromiseState = "rejected");
 9864      }
 9865      n2(an, "defaultWriterClosedPromiseReject");
 9866      function Qa(e, t3) {
 9867        Mo(e, t3);
 9868      }
 9869      n2(Qa, "defaultWriterClosedPromiseResetToRejected");
 9870      function Uo(e) {
 9871        e._closedPromise_resolve !== void 0 && (e._closedPromise_resolve(void 0), e._closedPromise_resolve = void 0, e._closedPromise_reject = void 0, e._closedPromiseState = "resolved");
 9872      }
 9873      n2(Uo, "defaultWriterClosedPromiseResolve");
 9874      function nr(e) {
 9875        e._readyPromise = A((t3, r2) => {
 9876          e._readyPromise_resolve = t3, e._readyPromise_reject = r2;
 9877        }), e._readyPromiseState = "pending";
 9878      }
 9879      n2(nr, "defaultWriterReadyPromiseInitialize");
 9880      function sn(e, t3) {
 9881        nr(e), No(e, t3);
 9882      }
 9883      n2(sn, "defaultWriterReadyPromiseInitializeAsRejected");
 9884      function xo(e) {
 9885        nr(e), ln(e);
 9886      }
 9887      n2(xo, "defaultWriterReadyPromiseInitializeAsResolved");
 9888      function No(e, t3) {
 9889        e._readyPromise_reject !== void 0 && (Q(e._readyPromise), e._readyPromise_reject(t3), e._readyPromise_resolve = void 0, e._readyPromise_reject = void 0, e._readyPromiseState = "rejected");
 9890      }
 9891      n2(No, "defaultWriterReadyPromiseReject");
 9892      function Ya(e) {
 9893        nr(e);
 9894      }
 9895      n2(Ya, "defaultWriterReadyPromiseReset");
 9896      function Ga(e, t3) {
 9897        sn(e, t3);
 9898      }
 9899      n2(Ga, "defaultWriterReadyPromiseResetToRejected");
 9900      function ln(e) {
 9901        e._readyPromise_resolve !== void 0 && (e._readyPromise_resolve(void 0), e._readyPromise_resolve = void 0, e._readyPromise_reject = void 0, e._readyPromiseState = "fulfilled");
 9902      }
 9903      n2(ln, "defaultWriterReadyPromiseResolve");
 9904      function Za() {
 9905        if (typeof globalThis < "u") return globalThis;
 9906        if (typeof self < "u") return self;
 9907        if (typeof n < "u") return n;
 9908      }
 9909      n2(Za, "getGlobals");
 9910      const un = Za();
 9911      function Ka(e) {
 9912        if (!(typeof e == "function" || typeof e == "object") || e.name !== "DOMException") return false;
 9913        try {
 9914          return new e(), true;
 9915        } catch (e2) {
 9916          return false;
 9917        }
 9918      }
 9919      n2(Ka, "isDOMExceptionConstructor");
 9920      function Ja() {
 9921        const e = un == null ? void 0 : un.DOMException;
 9922        return Ka(e) ? e : void 0;
 9923      }
 9924      n2(Ja, "getFromGlobal");
 9925      function Xa() {
 9926        const e = n2(function(r2, s) {
 9927          this.message = r2 || "", this.name = s || "Error", Error.captureStackTrace && Error.captureStackTrace(this, this.constructor);
 9928        }, "DOMException");
 9929        return h2(e, "DOMException"), e.prototype = Object.create(Error.prototype), Object.defineProperty(e.prototype, "constructor", { value: e, writable: true, configurable: true }), e;
 9930      }
 9931      n2(Xa, "createPolyfill");
 9932      const es = Ja() || Xa();
 9933      function Ho(e, t3, r2, s, u, c2) {
 9934        const d = Qe(e), m2 = ko(t3);
 9935        e._disturbed = true;
 9936        let R3 = false, y = T2(void 0);
 9937        return A((C2, P2) => {
 9938          let B2;
 9939          if (c2 !== void 0) {
 9940            if (B2 = n2(() => {
 9941              const _ = c2.reason !== void 0 ? c2.reason : new es("Aborted", "AbortError"), E2 = [];
 9942              s || E2.push(() => t3._state === "writable" ? Kt(t3, _) : T2(void 0)), u || E2.push(() => e._state === "readable" ? ie(e, _) : T2(void 0)), N2(() => Promise.all(E2.map((k2) => k2())), true, _);
 9943            }, "abortAlgorithm"), c2.aborted) {
 9944              B2();
 9945              return;
 9946            }
 9947            c2.addEventListener("abort", B2);
 9948          }
 9949          function ae() {
 9950            return A((_, E2) => {
 9951              function k2(Y) {
 9952                Y ? _() : q(nt(), k2, E2);
 9953              }
 9954              n2(k2, "next"), k2(false);
 9955            });
 9956          }
 9957          n2(ae, "pipeLoop");
 9958          function nt() {
 9959            return R3 ? T2(true) : q(m2._readyPromise, () => A((_, E2) => {
 9960              _t(d, { _chunkSteps: n2((k2) => {
 9961                y = q(Fo(m2, k2), void 0, f2), _(false);
 9962              }, "_chunkSteps"), _closeSteps: n2(() => _(true), "_closeSteps"), _errorSteps: E2 });
 9963            }));
 9964          }
 9965          if (n2(nt, "pipeStep"), Te(e, d._closedPromise, (_) => (s ? J(true, _) : N2(() => Kt(t3, _), true, _), null)), Te(t3, m2._closedPromise, (_) => (u ? J(true, _) : N2(() => ie(e, _), true, _), null)), x2(e, d._closedPromise, () => (r2 ? J() : N2(() => ja(m2)), null)), he(t3) || t3._state === "closed") {
 9966            const _ = new TypeError("the destination writable stream closed before all data could be piped to it");
 9967            u ? J(true, _) : N2(() => ie(e, _), true, _);
 9968          }
 9969          Q(ae());
 9970          function Oe() {
 9971            const _ = y;
 9972            return q(y, () => _ !== y ? Oe() : void 0);
 9973          }
 9974          n2(Oe, "waitForWritesToFinish");
 9975          function Te(_, E2, k2) {
 9976            _._state === "errored" ? k2(_._storedError) : I2(E2, k2);
 9977          }
 9978          n2(Te, "isOrBecomesErrored");
 9979          function x2(_, E2, k2) {
 9980            _._state === "closed" ? k2() : V(E2, k2);
 9981          }
 9982          n2(x2, "isOrBecomesClosed");
 9983          function N2(_, E2, k2) {
 9984            if (R3) return;
 9985            R3 = true, t3._state === "writable" && !he(t3) ? V(Oe(), Y) : Y();
 9986            function Y() {
 9987              return g2(_(), () => Ce(E2, k2), (ot) => Ce(true, ot)), null;
 9988            }
 9989            n2(Y, "doTheRest");
 9990          }
 9991          n2(N2, "shutdownWithAction");
 9992          function J(_, E2) {
 9993            R3 || (R3 = true, t3._state === "writable" && !he(t3) ? V(Oe(), () => Ce(_, E2)) : Ce(_, E2));
 9994          }
 9995          n2(J, "shutdown");
 9996          function Ce(_, E2) {
 9997            return Io(m2), _e(d), c2 !== void 0 && c2.removeEventListener("abort", B2), _ ? P2(E2) : C2(void 0), null;
 9998          }
 9999          n2(Ce, "finalize");
10000        });
10001      }
10002      n2(Ho, "ReadableStreamPipeTo");
10003      const Cn = class Cn {
10004        constructor() {
10005          throw new TypeError("Illegal constructor");
10006        }
10007        get desiredSize() {
10008          if (!or(this)) throw ar("desiredSize");
10009          return fn(this);
10010        }
10011        close() {
10012          if (!or(this)) throw ar("close");
10013          if (!Je(this)) throw new TypeError("The stream is not in a state that permits close");
10014          De(this);
10015        }
10016        enqueue(t3 = void 0) {
10017          if (!or(this)) throw ar("enqueue");
10018          if (!Je(this)) throw new TypeError("The stream is not in a state that permits enqueue");
10019          return Ke(this, t3);
10020        }
10021        error(t3 = void 0) {
10022          if (!or(this)) throw ar("error");
10023          oe(this, t3);
10024        }
10025        [Ar](t3) {
10026          Be(this);
10027          const r2 = this._cancelAlgorithm(t3);
10028          return ir(this), r2;
10029        }
10030        [Br](t3) {
10031          const r2 = this._controlledReadableStream;
10032          if (this._queue.length > 0) {
10033            const s = xr(this);
10034            this._closeRequested && this._queue.length === 0 ? (ir(this), At(r2)) : vt(this), t3._chunkSteps(s);
10035          } else eo(r2, t3), vt(this);
10036        }
10037        [kr]() {
10038        }
10039      };
10040      n2(Cn, "ReadableStreamDefaultController");
10041      let ne = Cn;
10042      Object.defineProperties(ne.prototype, { close: { enumerable: true }, enqueue: { enumerable: true }, error: { enumerable: true }, desiredSize: { enumerable: true } }), h2(ne.prototype.close, "close"), h2(ne.prototype.enqueue, "enqueue"), h2(ne.prototype.error, "error"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(ne.prototype, Symbol.toStringTag, { value: "ReadableStreamDefaultController", configurable: true });
10043      function or(e) {
10044        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_controlledReadableStream") ? false : e instanceof ne;
10045      }
10046      n2(or, "IsReadableStreamDefaultController");
10047      function vt(e) {
10048        if (!Vo(e)) return;
10049        if (e._pulling) {
10050          e._pullAgain = true;
10051          return;
10052        }
10053        e._pulling = true;
10054        const r2 = e._pullAlgorithm();
10055        g2(r2, () => (e._pulling = false, e._pullAgain && (e._pullAgain = false, vt(e)), null), (s) => (oe(e, s), null));
10056      }
10057      n2(vt, "ReadableStreamDefaultControllerCallPullIfNeeded");
10058      function Vo(e) {
10059        const t3 = e._controlledReadableStream;
10060        return !Je(e) || !e._started ? false : !!(qe(t3) && $t(t3) > 0 || fn(e) > 0);
10061      }
10062      n2(Vo, "ReadableStreamDefaultControllerShouldCallPull");
10063      function ir(e) {
10064        e._pullAlgorithm = void 0, e._cancelAlgorithm = void 0, e._strategySizeAlgorithm = void 0;
10065      }
10066      n2(ir, "ReadableStreamDefaultControllerClearAlgorithms");
10067      function De(e) {
10068        if (!Je(e)) return;
10069        const t3 = e._controlledReadableStream;
10070        e._closeRequested = true, e._queue.length === 0 && (ir(e), At(t3));
10071      }
10072      n2(De, "ReadableStreamDefaultControllerClose");
10073      function Ke(e, t3) {
10074        if (!Je(e)) return;
10075        const r2 = e._controlledReadableStream;
10076        if (qe(r2) && $t(r2) > 0) Lr(r2, t3, false);
10077        else {
10078          let s;
10079          try {
10080            s = e._strategySizeAlgorithm(t3);
10081          } catch (u) {
10082            throw oe(e, u), u;
10083          }
10084          try {
10085            Nr(e, t3, s);
10086          } catch (u) {
10087            throw oe(e, u), u;
10088          }
10089        }
10090        vt(e);
10091      }
10092      n2(Ke, "ReadableStreamDefaultControllerEnqueue");
10093      function oe(e, t3) {
10094        const r2 = e._controlledReadableStream;
10095        r2._state === "readable" && (Be(e), ir(e), Zo(r2, t3));
10096      }
10097      n2(oe, "ReadableStreamDefaultControllerError");
10098      function fn(e) {
10099        const t3 = e._controlledReadableStream._state;
10100        return t3 === "errored" ? null : t3 === "closed" ? 0 : e._strategyHWM - e._queueTotalSize;
10101      }
10102      n2(fn, "ReadableStreamDefaultControllerGetDesiredSize");
10103      function ts(e) {
10104        return !Vo(e);
10105      }
10106      n2(ts, "ReadableStreamDefaultControllerHasBackpressure");
10107      function Je(e) {
10108        const t3 = e._controlledReadableStream._state;
10109        return !e._closeRequested && t3 === "readable";
10110      }
10111      n2(Je, "ReadableStreamDefaultControllerCanCloseOrEnqueue");
10112      function Qo(e, t3, r2, s, u, c2, d) {
10113        t3._controlledReadableStream = e, t3._queue = void 0, t3._queueTotalSize = void 0, Be(t3), t3._started = false, t3._closeRequested = false, t3._pullAgain = false, t3._pulling = false, t3._strategySizeAlgorithm = d, t3._strategyHWM = c2, t3._pullAlgorithm = s, t3._cancelAlgorithm = u, e._readableStreamController = t3;
10114        const m2 = r2();
10115        g2(T2(m2), () => (t3._started = true, vt(t3), null), (R3) => (oe(t3, R3), null));
10116      }
10117      n2(Qo, "SetUpReadableStreamDefaultController");
10118      function rs(e, t3, r2, s) {
10119        const u = Object.create(ne.prototype);
10120        let c2, d, m2;
10121        t3.start !== void 0 ? c2 = n2(() => t3.start(u), "startAlgorithm") : c2 = n2(() => {
10122        }, "startAlgorithm"), t3.pull !== void 0 ? d = n2(() => t3.pull(u), "pullAlgorithm") : d = n2(() => T2(void 0), "pullAlgorithm"), t3.cancel !== void 0 ? m2 = n2((R3) => t3.cancel(R3), "cancelAlgorithm") : m2 = n2(() => T2(void 0), "cancelAlgorithm"), Qo(e, u, c2, d, m2, r2, s);
10123      }
10124      n2(rs, "SetUpReadableStreamDefaultControllerFromUnderlyingSource");
10125      function ar(e) {
10126        return new TypeError(`ReadableStreamDefaultController.prototype.${e} can only be used on a ReadableStreamDefaultController`);
10127      }
10128      n2(ar, "defaultControllerBrandCheckException$1");
10129      function ns(e, t3) {
10130        return Ie(e._readableStreamController) ? is(e) : os(e);
10131      }
10132      n2(ns, "ReadableStreamTee");
10133      function os(e, t3) {
10134        const r2 = Qe(e);
10135        let s = false, u = false, c2 = false, d = false, m2, R3, y, C2, P2;
10136        const B2 = A((x2) => {
10137          P2 = x2;
10138        });
10139        function ae() {
10140          return s ? (u = true, T2(void 0)) : (s = true, _t(r2, { _chunkSteps: n2((N2) => {
10141            ge(() => {
10142              u = false;
10143              const J = N2, Ce = N2;
10144              c2 || Ke(y._readableStreamController, J), d || Ke(C2._readableStreamController, Ce), s = false, u && ae();
10145            });
10146          }, "_chunkSteps"), _closeSteps: n2(() => {
10147            s = false, c2 || De(y._readableStreamController), d || De(C2._readableStreamController), (!c2 || !d) && P2(void 0);
10148          }, "_closeSteps"), _errorSteps: n2(() => {
10149            s = false;
10150          }, "_errorSteps") }), T2(void 0));
10151        }
10152        n2(ae, "pullAlgorithm");
10153        function nt(x2) {
10154          if (c2 = true, m2 = x2, d) {
10155            const N2 = St([m2, R3]), J = ie(e, N2);
10156            P2(J);
10157          }
10158          return B2;
10159        }
10160        n2(nt, "cancel1Algorithm");
10161        function Oe(x2) {
10162          if (d = true, R3 = x2, c2) {
10163            const N2 = St([m2, R3]), J = ie(e, N2);
10164            P2(J);
10165          }
10166          return B2;
10167        }
10168        n2(Oe, "cancel2Algorithm");
10169        function Te() {
10170        }
10171        return n2(Te, "startAlgorithm"), y = Et(Te, ae, nt), C2 = Et(Te, ae, Oe), I2(r2._closedPromise, (x2) => (oe(y._readableStreamController, x2), oe(C2._readableStreamController, x2), (!c2 || !d) && P2(void 0), null)), [y, C2];
10172      }
10173      n2(os, "ReadableStreamDefaultTee");
10174      function is(e) {
10175        let t3 = Qe(e), r2 = false, s = false, u = false, c2 = false, d = false, m2, R3, y, C2, P2;
10176        const B2 = A((_) => {
10177          P2 = _;
10178        });
10179        function ae(_) {
10180          I2(_._closedPromise, (E2) => (_ !== t3 || (K(y._readableStreamController, E2), K(C2._readableStreamController, E2), (!c2 || !d) && P2(void 0)), null));
10181        }
10182        n2(ae, "forwardReaderError");
10183        function nt() {
10184          je(t3) && (_e(t3), t3 = Qe(e), ae(t3)), _t(t3, { _chunkSteps: n2((E2) => {
10185            ge(() => {
10186              s = false, u = false;
10187              const k2 = E2;
10188              let Y = E2;
10189              if (!c2 && !d) try {
10190                Y = fo(E2);
10191              } catch (ot) {
10192                K(y._readableStreamController, ot), K(C2._readableStreamController, ot), P2(ie(e, ot));
10193                return;
10194              }
10195              c2 || Ht(y._readableStreamController, k2), d || Ht(C2._readableStreamController, Y), r2 = false, s ? Te() : u && x2();
10196            });
10197          }, "_chunkSteps"), _closeSteps: n2(() => {
10198            r2 = false, c2 || wt(y._readableStreamController), d || wt(C2._readableStreamController), y._readableStreamController._pendingPullIntos.length > 0 && Vt(y._readableStreamController, 0), C2._readableStreamController._pendingPullIntos.length > 0 && Vt(C2._readableStreamController, 0), (!c2 || !d) && P2(void 0);
10199          }, "_closeSteps"), _errorSteps: n2(() => {
10200            r2 = false;
10201          }, "_errorSteps") });
10202        }
10203        n2(nt, "pullWithDefaultReader");
10204        function Oe(_, E2) {
10205          Ee(t3) && (_e(t3), t3 = Co(e), ae(t3));
10206          const k2 = E2 ? C2 : y, Y = E2 ? y : C2;
10207          Eo(t3, _, 1, { _chunkSteps: n2((it) => {
10208            ge(() => {
10209              s = false, u = false;
10210              const at = E2 ? d : c2;
10211              if (E2 ? c2 : d) at || Qt(k2._readableStreamController, it);
10212              else {
10213                let ui;
10214                try {
10215                  ui = fo(it);
10216                } catch (kn) {
10217                  K(k2._readableStreamController, kn), K(Y._readableStreamController, kn), P2(ie(e, kn));
10218                  return;
10219                }
10220                at || Qt(k2._readableStreamController, it), Ht(Y._readableStreamController, ui);
10221              }
10222              r2 = false, s ? Te() : u && x2();
10223            });
10224          }, "_chunkSteps"), _closeSteps: n2((it) => {
10225            r2 = false;
10226            const at = E2 ? d : c2, cr = E2 ? c2 : d;
10227            at || wt(k2._readableStreamController), cr || wt(Y._readableStreamController), it !== void 0 && (at || Qt(k2._readableStreamController, it), !cr && Y._readableStreamController._pendingPullIntos.length > 0 && Vt(Y._readableStreamController, 0)), (!at || !cr) && P2(void 0);
10228          }, "_closeSteps"), _errorSteps: n2(() => {
10229            r2 = false;
10230          }, "_errorSteps") });
10231        }
10232        n2(Oe, "pullWithBYOBReader");
10233        function Te() {
10234          if (r2) return s = true, T2(void 0);
10235          r2 = true;
10236          const _ = Gr(y._readableStreamController);
10237          return _ === null ? nt() : Oe(_._view, false), T2(void 0);
10238        }
10239        n2(Te, "pull1Algorithm");
10240        function x2() {
10241          if (r2) return u = true, T2(void 0);
10242          r2 = true;
10243          const _ = Gr(C2._readableStreamController);
10244          return _ === null ? nt() : Oe(_._view, true), T2(void 0);
10245        }
10246        n2(x2, "pull2Algorithm");
10247        function N2(_) {
10248          if (c2 = true, m2 = _, d) {
10249            const E2 = St([m2, R3]), k2 = ie(e, E2);
10250            P2(k2);
10251          }
10252          return B2;
10253        }
10254        n2(N2, "cancel1Algorithm");
10255        function J(_) {
10256          if (d = true, R3 = _, c2) {
10257            const E2 = St([m2, R3]), k2 = ie(e, E2);
10258            P2(k2);
10259          }
10260          return B2;
10261        }
10262        n2(J, "cancel2Algorithm");
10263        function Ce() {
10264        }
10265        return n2(Ce, "startAlgorithm"), y = Go(Ce, Te, N2), C2 = Go(Ce, x2, J), ae(t3), [y, C2];
10266      }
10267      n2(is, "ReadableByteStreamTee");
10268      function as(e) {
10269        return l(e) && typeof e.getReader < "u";
10270      }
10271      n2(as, "isReadableStreamLike");
10272      function ss(e) {
10273        return as(e) ? us(e.getReader()) : ls(e);
10274      }
10275      n2(ss, "ReadableStreamFrom");
10276      function ls(e) {
10277        let t3;
10278        const r2 = uo(e, "async"), s = f2;
10279        function u() {
10280          let d;
10281          try {
10282            d = Xi(r2);
10283          } catch (R3) {
10284            return b(R3);
10285          }
10286          const m2 = T2(d);
10287          return F4(m2, (R3) => {
10288            if (!l(R3)) throw new TypeError("The promise returned by the iterator.next() method must fulfill with an object");
10289            if (ea(R3)) De(t3._readableStreamController);
10290            else {
10291              const C2 = ta(R3);
10292              Ke(t3._readableStreamController, C2);
10293            }
10294          });
10295        }
10296        n2(u, "pullAlgorithm");
10297        function c2(d) {
10298          const m2 = r2.iterator;
10299          let R3;
10300          try {
10301            R3 = Ut(m2, "return");
10302          } catch (P2) {
10303            return b(P2);
10304          }
10305          if (R3 === void 0) return T2(void 0);
10306          let y;
10307          try {
10308            y = z(R3, m2, [d]);
10309          } catch (P2) {
10310            return b(P2);
10311          }
10312          const C2 = T2(y);
10313          return F4(C2, (P2) => {
10314            if (!l(P2)) throw new TypeError("The promise returned by the iterator.return() method must fulfill with an object");
10315          });
10316        }
10317        return n2(c2, "cancelAlgorithm"), t3 = Et(s, u, c2, 0), t3;
10318      }
10319      n2(ls, "ReadableStreamFromIterable");
10320      function us(e) {
10321        let t3;
10322        const r2 = f2;
10323        function s() {
10324          let c2;
10325          try {
10326            c2 = e.read();
10327          } catch (d) {
10328            return b(d);
10329          }
10330          return F4(c2, (d) => {
10331            if (!l(d)) throw new TypeError("The promise returned by the reader.read() method must fulfill with an object");
10332            if (d.done) De(t3._readableStreamController);
10333            else {
10334              const m2 = d.value;
10335              Ke(t3._readableStreamController, m2);
10336            }
10337          });
10338        }
10339        n2(s, "pullAlgorithm");
10340        function u(c2) {
10341          try {
10342            return T2(e.cancel(c2));
10343          } catch (d) {
10344            return b(d);
10345          }
10346        }
10347        return n2(u, "cancelAlgorithm"), t3 = Et(r2, s, u, 0), t3;
10348      }
10349      n2(us, "ReadableStreamFromDefaultReader");
10350      function fs6(e, t3) {
10351        ue(e, t3);
10352        const r2 = e, s = r2 == null ? void 0 : r2.autoAllocateChunkSize, u = r2 == null ? void 0 : r2.cancel, c2 = r2 == null ? void 0 : r2.pull, d = r2 == null ? void 0 : r2.start, m2 = r2 == null ? void 0 : r2.type;
10353        return { autoAllocateChunkSize: s === void 0 ? void 0 : Fr(s, `${t3} has member 'autoAllocateChunkSize' that`), cancel: u === void 0 ? void 0 : cs(u, r2, `${t3} has member 'cancel' that`), pull: c2 === void 0 ? void 0 : ds(c2, r2, `${t3} has member 'pull' that`), start: d === void 0 ? void 0 : hs(d, r2, `${t3} has member 'start' that`), type: m2 === void 0 ? void 0 : ps(m2, `${t3} has member 'type' that`) };
10354      }
10355      n2(fs6, "convertUnderlyingDefaultOrByteSource");
10356      function cs(e, t3, r2) {
10357        return Z2(e, r2), (s) => j(e, t3, [s]);
10358      }
10359      n2(cs, "convertUnderlyingSourceCancelCallback");
10360      function ds(e, t3, r2) {
10361        return Z2(e, r2), (s) => j(e, t3, [s]);
10362      }
10363      n2(ds, "convertUnderlyingSourcePullCallback");
10364      function hs(e, t3, r2) {
10365        return Z2(e, r2), (s) => z(e, t3, [s]);
10366      }
10367      n2(hs, "convertUnderlyingSourceStartCallback");
10368      function ps(e, t3) {
10369        if (e = `${e}`, e !== "bytes") throw new TypeError(`${t3} '${e}' is not a valid enumeration value for ReadableStreamType`);
10370        return e;
10371      }
10372      n2(ps, "convertReadableStreamType");
10373      function bs(e, t3) {
10374        return ue(e, t3), { preventCancel: !!(e == null ? void 0 : e.preventCancel) };
10375      }
10376      n2(bs, "convertIteratorOptions");
10377      function Yo(e, t3) {
10378        ue(e, t3);
10379        const r2 = e == null ? void 0 : e.preventAbort, s = e == null ? void 0 : e.preventCancel, u = e == null ? void 0 : e.preventClose, c2 = e == null ? void 0 : e.signal;
10380        return c2 !== void 0 && ms(c2, `${t3} has member 'signal' that`), { preventAbort: !!r2, preventCancel: !!s, preventClose: !!u, signal: c2 };
10381      }
10382      n2(Yo, "convertPipeOptions");
10383      function ms(e, t3) {
10384        if (!Ca(e)) throw new TypeError(`${t3} is not an AbortSignal.`);
10385      }
10386      n2(ms, "assertAbortSignal");
10387      function ys(e, t3) {
10388        ue(e, t3);
10389        const r2 = e == null ? void 0 : e.readable;
10390        zr(r2, "readable", "ReadableWritablePair"), jr(r2, `${t3} has member 'readable' that`);
10391        const s = e == null ? void 0 : e.writable;
10392        return zr(s, "writable", "ReadableWritablePair"), Bo(s, `${t3} has member 'writable' that`), { readable: r2, writable: s };
10393      }
10394      n2(ys, "convertReadableWritablePair");
10395      const Pn = class Pn {
10396        constructor(t3 = {}, r2 = {}) {
10397          t3 === void 0 ? t3 = null : Jn(t3, "First parameter");
10398          const s = Zt(r2, "Second parameter"), u = fs6(t3, "First parameter");
10399          if (cn(this), u.type === "bytes") {
10400            if (s.size !== void 0) throw new RangeError("The strategy for a byte stream cannot have a size function");
10401            const c2 = Tt(s, 0);
10402            ca(this, u, c2);
10403          } else {
10404            const c2 = Gt(s), d = Tt(s, 1);
10405            rs(this, u, d, c2);
10406          }
10407        }
10408        get locked() {
10409          if (!We(this)) throw Me("locked");
10410          return qe(this);
10411        }
10412        cancel(t3 = void 0) {
10413          return We(this) ? qe(this) ? b(new TypeError("Cannot cancel a stream that already has a reader")) : ie(this, t3) : b(Me("cancel"));
10414        }
10415        getReader(t3 = void 0) {
10416          if (!We(this)) throw Me("getReader");
10417          return ha(t3, "First parameter").mode === void 0 ? Qe(this) : Co(this);
10418        }
10419        pipeThrough(t3, r2 = {}) {
10420          if (!We(this)) throw Me("pipeThrough");
10421          Se(t3, 1, "pipeThrough");
10422          const s = ys(t3, "First parameter"), u = Yo(r2, "Second parameter");
10423          if (qe(this)) throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked ReadableStream");
10424          if (Ze(s.writable)) throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked WritableStream");
10425          const c2 = Ho(this, s.writable, u.preventClose, u.preventAbort, u.preventCancel, u.signal);
10426          return Q(c2), s.readable;
10427        }
10428        pipeTo(t3, r2 = {}) {
10429          if (!We(this)) return b(Me("pipeTo"));
10430          if (t3 === void 0) return b("Parameter 1 is required in 'pipeTo'.");
10431          if (!Ge(t3)) return b(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream"));
10432          let s;
10433          try {
10434            s = Yo(r2, "Second parameter");
10435          } catch (u) {
10436            return b(u);
10437          }
10438          return qe(this) ? b(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream")) : Ze(t3) ? b(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream")) : Ho(this, t3, s.preventClose, s.preventAbort, s.preventCancel, s.signal);
10439        }
10440        tee() {
10441          if (!We(this)) throw Me("tee");
10442          const t3 = ns(this);
10443          return St(t3);
10444        }
10445        values(t3 = void 0) {
10446          if (!We(this)) throw Me("values");
10447          const r2 = bs(t3, "First parameter");
10448          return Ki(this, r2.preventCancel);
10449        }
10450        [Ur](t3) {
10451          return this.values(t3);
10452        }
10453        static from(t3) {
10454          return ss(t3);
10455        }
10456      };
10457      n2(Pn, "ReadableStream");
10458      let L = Pn;
10459      Object.defineProperties(L, { from: { enumerable: true } }), Object.defineProperties(L.prototype, { cancel: { enumerable: true }, getReader: { enumerable: true }, pipeThrough: { enumerable: true }, pipeTo: { enumerable: true }, tee: { enumerable: true }, values: { enumerable: true }, locked: { enumerable: true } }), h2(L.from, "from"), h2(L.prototype.cancel, "cancel"), h2(L.prototype.getReader, "getReader"), h2(L.prototype.pipeThrough, "pipeThrough"), h2(L.prototype.pipeTo, "pipeTo"), h2(L.prototype.tee, "tee"), h2(L.prototype.values, "values"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(L.prototype, Symbol.toStringTag, { value: "ReadableStream", configurable: true }), Object.defineProperty(L.prototype, Ur, { value: L.prototype.values, writable: true, configurable: true });
10460      function Et(e, t3, r2, s = 1, u = () => 1) {
10461        const c2 = Object.create(L.prototype);
10462        cn(c2);
10463        const d = Object.create(ne.prototype);
10464        return Qo(c2, d, e, t3, r2, s, u), c2;
10465      }
10466      n2(Et, "CreateReadableStream");
10467      function Go(e, t3, r2) {
10468        const s = Object.create(L.prototype);
10469        cn(s);
10470        const u = Object.create(te.prototype);
10471        return To(s, u, e, t3, r2, 0, void 0), s;
10472      }
10473      n2(Go, "CreateReadableByteStream");
10474      function cn(e) {
10475        e._state = "readable", e._reader = void 0, e._storedError = void 0, e._disturbed = false;
10476      }
10477      n2(cn, "InitializeReadableStream");
10478      function We(e) {
10479        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_readableStreamController") ? false : e instanceof L;
10480      }
10481      n2(We, "IsReadableStream");
10482      function qe(e) {
10483        return e._reader !== void 0;
10484      }
10485      n2(qe, "IsReadableStreamLocked");
10486      function ie(e, t3) {
10487        if (e._disturbed = true, e._state === "closed") return T2(void 0);
10488        if (e._state === "errored") return b(e._storedError);
10489        At(e);
10490        const r2 = e._reader;
10491        if (r2 !== void 0 && je(r2)) {
10492          const u = r2._readIntoRequests;
10493          r2._readIntoRequests = new D2(), u.forEach((c2) => {
10494            c2._closeSteps(void 0);
10495          });
10496        }
10497        const s = e._readableStreamController[Ar](t3);
10498        return F4(s, f2);
10499      }
10500      n2(ie, "ReadableStreamCancel");
10501      function At(e) {
10502        e._state = "closed";
10503        const t3 = e._reader;
10504        if (t3 !== void 0 && (Zn(t3), Ee(t3))) {
10505          const r2 = t3._readRequests;
10506          t3._readRequests = new D2(), r2.forEach((s) => {
10507            s._closeSteps();
10508          });
10509        }
10510      }
10511      n2(At, "ReadableStreamClose");
10512      function Zo(e, t3) {
10513        e._state = "errored", e._storedError = t3;
10514        const r2 = e._reader;
10515        r2 !== void 0 && (Or(r2, t3), Ee(r2) ? ro(r2, t3) : Ao(r2, t3));
10516      }
10517      n2(Zo, "ReadableStreamError");
10518      function Me(e) {
10519        return new TypeError(`ReadableStream.prototype.${e} can only be used on a ReadableStream`);
10520      }
10521      n2(Me, "streamBrandCheckException$1");
10522      function Ko(e, t3) {
10523        ue(e, t3);
10524        const r2 = e == null ? void 0 : e.highWaterMark;
10525        return zr(r2, "highWaterMark", "QueuingStrategyInit"), { highWaterMark: Ir(r2) };
10526      }
10527      n2(Ko, "convertQueuingStrategyInit");
10528      const Jo = n2((e) => e.byteLength, "byteLengthSizeFunction");
10529      h2(Jo, "size");
10530      const vn = class vn {
10531        constructor(t3) {
10532          Se(t3, 1, "ByteLengthQueuingStrategy"), t3 = Ko(t3, "First parameter"), this._byteLengthQueuingStrategyHighWaterMark = t3.highWaterMark;
10533        }
10534        get highWaterMark() {
10535          if (!ei(this)) throw Xo("highWaterMark");
10536          return this._byteLengthQueuingStrategyHighWaterMark;
10537        }
10538        get size() {
10539          if (!ei(this)) throw Xo("size");
10540          return Jo;
10541        }
10542      };
10543      n2(vn, "ByteLengthQueuingStrategy");
10544      let Xe = vn;
10545      Object.defineProperties(Xe.prototype, { highWaterMark: { enumerable: true }, size: { enumerable: true } }), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(Xe.prototype, Symbol.toStringTag, { value: "ByteLengthQueuingStrategy", configurable: true });
10546      function Xo(e) {
10547        return new TypeError(`ByteLengthQueuingStrategy.prototype.${e} can only be used on a ByteLengthQueuingStrategy`);
10548      }
10549      n2(Xo, "byteLengthBrandCheckException");
10550      function ei(e) {
10551        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_byteLengthQueuingStrategyHighWaterMark") ? false : e instanceof Xe;
10552      }
10553      n2(ei, "IsByteLengthQueuingStrategy");
10554      const ti = n2(() => 1, "countSizeFunction");
10555      h2(ti, "size");
10556      const En = class En {
10557        constructor(t3) {
10558          Se(t3, 1, "CountQueuingStrategy"), t3 = Ko(t3, "First parameter"), this._countQueuingStrategyHighWaterMark = t3.highWaterMark;
10559        }
10560        get highWaterMark() {
10561          if (!ni(this)) throw ri("highWaterMark");
10562          return this._countQueuingStrategyHighWaterMark;
10563        }
10564        get size() {
10565          if (!ni(this)) throw ri("size");
10566          return ti;
10567        }
10568      };
10569      n2(En, "CountQueuingStrategy");
10570      let et = En;
10571      Object.defineProperties(et.prototype, { highWaterMark: { enumerable: true }, size: { enumerable: true } }), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(et.prototype, Symbol.toStringTag, { value: "CountQueuingStrategy", configurable: true });
10572      function ri(e) {
10573        return new TypeError(`CountQueuingStrategy.prototype.${e} can only be used on a CountQueuingStrategy`);
10574      }
10575      n2(ri, "countBrandCheckException");
10576      function ni(e) {
10577        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_countQueuingStrategyHighWaterMark") ? false : e instanceof et;
10578      }
10579      n2(ni, "IsCountQueuingStrategy");
10580      function gs(e, t3) {
10581        ue(e, t3);
10582        const r2 = e == null ? void 0 : e.cancel, s = e == null ? void 0 : e.flush, u = e == null ? void 0 : e.readableType, c2 = e == null ? void 0 : e.start, d = e == null ? void 0 : e.transform, m2 = e == null ? void 0 : e.writableType;
10583        return { cancel: r2 === void 0 ? void 0 : Rs(r2, e, `${t3} has member 'cancel' that`), flush: s === void 0 ? void 0 : _s(s, e, `${t3} has member 'flush' that`), readableType: u, start: c2 === void 0 ? void 0 : Ss(c2, e, `${t3} has member 'start' that`), transform: d === void 0 ? void 0 : ws(d, e, `${t3} has member 'transform' that`), writableType: m2 };
10584      }
10585      n2(gs, "convertTransformer");
10586      function _s(e, t3, r2) {
10587        return Z2(e, r2), (s) => j(e, t3, [s]);
10588      }
10589      n2(_s, "convertTransformerFlushCallback");
10590      function Ss(e, t3, r2) {
10591        return Z2(e, r2), (s) => z(e, t3, [s]);
10592      }
10593      n2(Ss, "convertTransformerStartCallback");
10594      function ws(e, t3, r2) {
10595        return Z2(e, r2), (s, u) => j(e, t3, [s, u]);
10596      }
10597      n2(ws, "convertTransformerTransformCallback");
10598      function Rs(e, t3, r2) {
10599        return Z2(e, r2), (s) => j(e, t3, [s]);
10600      }
10601      n2(Rs, "convertTransformerCancelCallback");
10602      const An = class An {
10603        constructor(t3 = {}, r2 = {}, s = {}) {
10604          t3 === void 0 && (t3 = null);
10605          const u = Zt(r2, "Second parameter"), c2 = Zt(s, "Third parameter"), d = gs(t3, "First parameter");
10606          if (d.readableType !== void 0) throw new RangeError("Invalid readableType specified");
10607          if (d.writableType !== void 0) throw new RangeError("Invalid writableType specified");
10608          const m2 = Tt(c2, 0), R3 = Gt(c2), y = Tt(u, 1), C2 = Gt(u);
10609          let P2;
10610          const B2 = A((ae) => {
10611            P2 = ae;
10612          });
10613          Ts(this, B2, y, C2, m2, R3), Ps(this, d), d.start !== void 0 ? P2(d.start(this._transformStreamController)) : P2(void 0);
10614        }
10615        get readable() {
10616          if (!oi(this)) throw li("readable");
10617          return this._readable;
10618        }
10619        get writable() {
10620          if (!oi(this)) throw li("writable");
10621          return this._writable;
10622        }
10623      };
10624      n2(An, "TransformStream");
10625      let tt = An;
10626      Object.defineProperties(tt.prototype, { readable: { enumerable: true }, writable: { enumerable: true } }), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(tt.prototype, Symbol.toStringTag, { value: "TransformStream", configurable: true });
10627      function Ts(e, t3, r2, s, u, c2) {
10628        function d() {
10629          return t3;
10630        }
10631        n2(d, "startAlgorithm");
10632        function m2(B2) {
10633          return As(e, B2);
10634        }
10635        n2(m2, "writeAlgorithm");
10636        function R3(B2) {
10637          return Bs(e, B2);
10638        }
10639        n2(R3, "abortAlgorithm");
10640        function y() {
10641          return ks(e);
10642        }
10643        n2(y, "closeAlgorithm"), e._writable = Ea(d, m2, y, R3, r2, s);
10644        function C2() {
10645          return Ws(e);
10646        }
10647        n2(C2, "pullAlgorithm");
10648        function P2(B2) {
10649          return qs(e, B2);
10650        }
10651        n2(P2, "cancelAlgorithm"), e._readable = Et(d, C2, P2, u, c2), e._backpressure = void 0, e._backpressureChangePromise = void 0, e._backpressureChangePromise_resolve = void 0, sr(e, true), e._transformStreamController = void 0;
10652      }
10653      n2(Ts, "InitializeTransformStream");
10654      function oi(e) {
10655        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_transformStreamController") ? false : e instanceof tt;
10656      }
10657      n2(oi, "IsTransformStream");
10658      function ii(e, t3) {
10659        oe(e._readable._readableStreamController, t3), dn(e, t3);
10660      }
10661      n2(ii, "TransformStreamError");
10662      function dn(e, t3) {
10663        ur(e._transformStreamController), Ct(e._writable._writableStreamController, t3), hn(e);
10664      }
10665      n2(dn, "TransformStreamErrorWritableAndUnblockWrite");
10666      function hn(e) {
10667        e._backpressure && sr(e, false);
10668      }
10669      n2(hn, "TransformStreamUnblockWrite");
10670      function sr(e, t3) {
10671        e._backpressureChangePromise !== void 0 && e._backpressureChangePromise_resolve(), e._backpressureChangePromise = A((r2) => {
10672          e._backpressureChangePromise_resolve = r2;
10673        }), e._backpressure = t3;
10674      }
10675      n2(sr, "TransformStreamSetBackpressure");
10676      const Bn = class Bn {
10677        constructor() {
10678          throw new TypeError("Illegal constructor");
10679        }
10680        get desiredSize() {
10681          if (!lr(this)) throw fr("desiredSize");
10682          const t3 = this._controlledTransformStream._readable._readableStreamController;
10683          return fn(t3);
10684        }
10685        enqueue(t3 = void 0) {
10686          if (!lr(this)) throw fr("enqueue");
10687          ai(this, t3);
10688        }
10689        error(t3 = void 0) {
10690          if (!lr(this)) throw fr("error");
10691          vs(this, t3);
10692        }
10693        terminate() {
10694          if (!lr(this)) throw fr("terminate");
10695          Es(this);
10696        }
10697      };
10698      n2(Bn, "TransformStreamDefaultController");
10699      let pe = Bn;
10700      Object.defineProperties(pe.prototype, { enqueue: { enumerable: true }, error: { enumerable: true }, terminate: { enumerable: true }, desiredSize: { enumerable: true } }), h2(pe.prototype.enqueue, "enqueue"), h2(pe.prototype.error, "error"), h2(pe.prototype.terminate, "terminate"), typeof Symbol.toStringTag == "symbol" && Object.defineProperty(pe.prototype, Symbol.toStringTag, { value: "TransformStreamDefaultController", configurable: true });
10701      function lr(e) {
10702        return !l(e) || !Object.prototype.hasOwnProperty.call(e, "_controlledTransformStream") ? false : e instanceof pe;
10703      }
10704      n2(lr, "IsTransformStreamDefaultController");
10705      function Cs(e, t3, r2, s, u) {
10706        t3._controlledTransformStream = e, e._transformStreamController = t3, t3._transformAlgorithm = r2, t3._flushAlgorithm = s, t3._cancelAlgorithm = u, t3._finishPromise = void 0, t3._finishPromise_resolve = void 0, t3._finishPromise_reject = void 0;
10707      }
10708      n2(Cs, "SetUpTransformStreamDefaultController");
10709      function Ps(e, t3) {
10710        const r2 = Object.create(pe.prototype);
10711        let s, u, c2;
10712        t3.transform !== void 0 ? s = n2((d) => t3.transform(d, r2), "transformAlgorithm") : s = n2((d) => {
10713          try {
10714            return ai(r2, d), T2(void 0);
10715          } catch (m2) {
10716            return b(m2);
10717          }
10718        }, "transformAlgorithm"), t3.flush !== void 0 ? u = n2(() => t3.flush(r2), "flushAlgorithm") : u = n2(() => T2(void 0), "flushAlgorithm"), t3.cancel !== void 0 ? c2 = n2((d) => t3.cancel(d), "cancelAlgorithm") : c2 = n2(() => T2(void 0), "cancelAlgorithm"), Cs(e, r2, s, u, c2);
10719      }
10720      n2(Ps, "SetUpTransformStreamDefaultControllerFromTransformer");
10721      function ur(e) {
10722        e._transformAlgorithm = void 0, e._flushAlgorithm = void 0, e._cancelAlgorithm = void 0;
10723      }
10724      n2(ur, "TransformStreamDefaultControllerClearAlgorithms");
10725      function ai(e, t3) {
10726        const r2 = e._controlledTransformStream, s = r2._readable._readableStreamController;
10727        if (!Je(s)) throw new TypeError("Readable side is not in a state that permits enqueue");
10728        try {
10729          Ke(s, t3);
10730        } catch (c2) {
10731          throw dn(r2, c2), r2._readable._storedError;
10732        }
10733        ts(s) !== r2._backpressure && sr(r2, true);
10734      }
10735      n2(ai, "TransformStreamDefaultControllerEnqueue");
10736      function vs(e, t3) {
10737        ii(e._controlledTransformStream, t3);
10738      }
10739      n2(vs, "TransformStreamDefaultControllerError");
10740      function si(e, t3) {
10741        const r2 = e._transformAlgorithm(t3);
10742        return F4(r2, void 0, (s) => {
10743          throw ii(e._controlledTransformStream, s), s;
10744        });
10745      }
10746      n2(si, "TransformStreamDefaultControllerPerformTransform");
10747      function Es(e) {
10748        const t3 = e._controlledTransformStream, r2 = t3._readable._readableStreamController;
10749        De(r2);
10750        const s = new TypeError("TransformStream terminated");
10751        dn(t3, s);
10752      }
10753      n2(Es, "TransformStreamDefaultControllerTerminate");
10754      function As(e, t3) {
10755        const r2 = e._transformStreamController;
10756        if (e._backpressure) {
10757          const s = e._backpressureChangePromise;
10758          return F4(s, () => {
10759            const u = e._writable;
10760            if (u._state === "erroring") throw u._storedError;
10761            return si(r2, t3);
10762          });
10763        }
10764        return si(r2, t3);
10765      }
10766      n2(As, "TransformStreamDefaultSinkWriteAlgorithm");
10767      function Bs(e, t3) {
10768        const r2 = e._transformStreamController;
10769        if (r2._finishPromise !== void 0) return r2._finishPromise;
10770        const s = e._readable;
10771        r2._finishPromise = A((c2, d) => {
10772          r2._finishPromise_resolve = c2, r2._finishPromise_reject = d;
10773        });
10774        const u = r2._cancelAlgorithm(t3);
10775        return ur(r2), g2(u, () => (s._state === "errored" ? rt(r2, s._storedError) : (oe(s._readableStreamController, t3), pn(r2)), null), (c2) => (oe(s._readableStreamController, c2), rt(r2, c2), null)), r2._finishPromise;
10776      }
10777      n2(Bs, "TransformStreamDefaultSinkAbortAlgorithm");
10778      function ks(e) {
10779        const t3 = e._transformStreamController;
10780        if (t3._finishPromise !== void 0) return t3._finishPromise;
10781        const r2 = e._readable;
10782        t3._finishPromise = A((u, c2) => {
10783          t3._finishPromise_resolve = u, t3._finishPromise_reject = c2;
10784        });
10785        const s = t3._flushAlgorithm();
10786        return ur(t3), g2(s, () => (r2._state === "errored" ? rt(t3, r2._storedError) : (De(r2._readableStreamController), pn(t3)), null), (u) => (oe(r2._readableStreamController, u), rt(t3, u), null)), t3._finishPromise;
10787      }
10788      n2(ks, "TransformStreamDefaultSinkCloseAlgorithm");
10789      function Ws(e) {
10790        return sr(e, false), e._backpressureChangePromise;
10791      }
10792      n2(Ws, "TransformStreamDefaultSourcePullAlgorithm");
10793      function qs(e, t3) {
10794        const r2 = e._transformStreamController;
10795        if (r2._finishPromise !== void 0) return r2._finishPromise;
10796        const s = e._writable;
10797        r2._finishPromise = A((c2, d) => {
10798          r2._finishPromise_resolve = c2, r2._finishPromise_reject = d;
10799        });
10800        const u = r2._cancelAlgorithm(t3);
10801        return ur(r2), g2(u, () => (s._state === "errored" ? rt(r2, s._storedError) : (Ct(s._writableStreamController, t3), hn(e), pn(r2)), null), (c2) => (Ct(s._writableStreamController, c2), hn(e), rt(r2, c2), null)), r2._finishPromise;
10802      }
10803      n2(qs, "TransformStreamDefaultSourceCancelAlgorithm");
10804      function fr(e) {
10805        return new TypeError(`TransformStreamDefaultController.prototype.${e} can only be used on a TransformStreamDefaultController`);
10806      }
10807      n2(fr, "defaultControllerBrandCheckException");
10808      function pn(e) {
10809        e._finishPromise_resolve !== void 0 && (e._finishPromise_resolve(), e._finishPromise_resolve = void 0, e._finishPromise_reject = void 0);
10810      }
10811      n2(pn, "defaultControllerFinishPromiseResolve");
10812      function rt(e, t3) {
10813        e._finishPromise_reject !== void 0 && (Q(e._finishPromise), e._finishPromise_reject(t3), e._finishPromise_resolve = void 0, e._finishPromise_reject = void 0);
10814      }
10815      n2(rt, "defaultControllerFinishPromiseReject");
10816      function li(e) {
10817        return new TypeError(`TransformStream.prototype.${e} can only be used on a TransformStream`);
10818      }
10819      n2(li, "streamBrandCheckException"), a.ByteLengthQueuingStrategy = Xe, a.CountQueuingStrategy = et, a.ReadableByteStreamController = te, a.ReadableStream = L, a.ReadableStreamBYOBReader = ce, a.ReadableStreamBYOBRequest = Re, a.ReadableStreamDefaultController = ne, a.ReadableStreamDefaultReader = fe, a.TransformStream = tt, a.TransformStreamDefaultController = pe, a.WritableStream = de, a.WritableStreamDefaultController = ke, a.WritableStreamDefaultWriter = re;
10820    });
10821  })(kt, kt.exports)), kt.exports;
10822}
10823function Hs() {
10824  if (mi) return pi;
10825  mi = 1;
10826  const i = 65536;
10827  if (!globalThis.ReadableStream) try {
10828    const o3 = require("process"), { emitWarning: a } = o3;
10829    try {
10830      o3.emitWarning = () => {
10831      }, Object.assign(globalThis, require("stream/web")), o3.emitWarning = a;
10832    } catch (f2) {
10833      throw o3.emitWarning = a, f2;
10834    }
10835  } catch (e) {
10836    Object.assign(globalThis, Ns());
10837  }
10838  try {
10839    const { Blob: o3 } = require("buffer");
10840    o3 && !o3.prototype.stream && (o3.prototype.stream = n2(function(f2) {
10841      let l = 0;
10842      const p2 = this;
10843      return new ReadableStream({ type: "bytes", pull(h2) {
10844        return __async(this, null, function* () {
10845          const v2 = yield p2.slice(l, Math.min(p2.size, l + i)).arrayBuffer();
10846          l += v2.byteLength, h2.enqueue(new Uint8Array(v2)), l === p2.size && h2.close();
10847        });
10848      } });
10849    }, "name"));
10850  } catch (e) {
10851  }
10852  return pi;
10853}
10854function Wn(i, o3 = true) {
10855  return __asyncGenerator(this, null, function* () {
10856    for (const a of i) if ("stream" in a) yield* __yieldStar(a.stream());
10857    else if (ArrayBuffer.isView(a)) if (o3) {
10858      let f2 = a.byteOffset;
10859      const l = a.byteOffset + a.byteLength;
10860      for (; f2 !== l; ) {
10861        const p2 = Math.min(l - f2, yi), h2 = a.buffer.slice(f2, f2 + p2);
10862        f2 += h2.byteLength, yield new Uint8Array(h2);
10863      }
10864    } else yield a;
10865    else {
10866      let f2 = 0, l = a;
10867      for (; f2 !== l.size; ) {
10868        const h2 = yield new __await(l.slice(f2, Math.min(l.size, f2 + yi)).arrayBuffer());
10869        f2 += h2.byteLength, yield new Uint8Array(h2);
10870      }
10871    }
10872  });
10873}
10874function Zs(i, o3 = ut) {
10875  var a = `${_i()}${_i()}`.replace(/\./g, "").slice(-28).padStart(32, "-"), f2 = [], l = `--${a}\r
10876Content-Disposition: form-data; name="`;
10877  return i.forEach((p2, h2) => typeof p2 == "string" ? f2.push(l + On(h2) + `"\r
10878\r
10879${p2.replace(new RegExp("\\r(?!\\n)|(?<!\\r)\\n", "g"), `\r
10880`)}\r
10881`) : f2.push(l + On(h2) + `"; filename="${On(p2.name, 1)}"\r
10882Content-Type: ${p2.type || "application/octet-stream"}\r
10883\r
10884`, p2, `\r
10885`)), f2.push(`--${a}--`), new o3(f2, { type: "multipart/form-data; boundary=" + a });
10886}
10887function zn(i) {
10888  return __async(this, null, function* () {
10889    if (i[H].disturbed) throw new TypeError(`body used already for: ${i.url}`);
10890    if (i[H].disturbed = true, i[H].error) throw i[H].error;
10891    const { body: o3 } = i;
10892    if (o3 === null) return import_node_buffer.Buffer.alloc(0);
10893    if (!(o3 instanceof import_node_stream3.default)) return import_node_buffer.Buffer.alloc(0);
10894    const a = [];
10895    let f2 = 0;
10896    try {
10897      try {
10898        for (var iter = __forAwait(o3), more, temp, error; more = !(temp = yield iter.next()).done; more = false) {
10899          const l = temp.value;
10900          if (i.size > 0 && f2 + l.length > i.size) {
10901            const p2 = new G(`content size at ${i.url} over limit: ${i.size}`, "max-size");
10902            throw o3.destroy(p2), p2;
10903          }
10904          f2 += l.length, a.push(l);
10905        }
10906      } catch (temp) {
10907        error = [temp];
10908      } finally {
10909        try {
10910          more && (temp = iter.return) && (yield temp.call(iter));
10911        } finally {
10912          if (error)
10913            throw error[0];
10914        }
10915      }
10916    } catch (l) {
10917      throw l instanceof ft ? l : new G(`Invalid response body while trying to fetch ${i.url}: ${l.message}`, "system", l);
10918    }
10919    if (o3.readableEnded === true || o3._readableState.ended === true) try {
10920      return a.every((l) => typeof l == "string") ? import_node_buffer.Buffer.from(a.join("")) : import_node_buffer.Buffer.concat(a, f2);
10921    } catch (l) {
10922      throw new G(`Could not create Buffer from response body for ${i.url}: ${l.message}`, "system", l);
10923    }
10924    else throw new G(`Premature close of server response while trying to fetch ${i.url}`);
10925  });
10926}
10927function ol(i = []) {
10928  return new ye(i.reduce((o3, a, f2, l) => (f2 % 2 === 0 && o3.push(l.slice(f2, f2 + 2)), o3), []).filter(([o3, a]) => {
10929    try {
10930      return gr(o3), Fn(o3, String(a)), true;
10931    } catch (e) {
10932      return false;
10933    }
10934  }));
10935}
10936function Ti(i, o3 = false) {
10937  return i == null || (i = new URL(i), /^(about|blob|data):$/.test(i.protocol)) ? "no-referrer" : (i.username = "", i.password = "", i.hash = "", o3 && (i.pathname = "", i.search = ""), i);
10938}
10939function ll(i) {
10940  if (!Ci.has(i)) throw new TypeError(`Invalid referrerPolicy: ${i}`);
10941  return i;
10942}
10943function ul(i) {
10944  if (/^(http|ws)s:$/.test(i.protocol)) return true;
10945  const o3 = i.host.replace(/(^\[)|(]$)/g, ""), a = (0, import_node_net.isIP)(o3);
10946  return a === 4 && /^127\./.test(o3) || a === 6 && /^(((0+:){7})|(::(0+:){0,6}))0*1$/.test(o3) ? true : i.host === "localhost" || i.host.endsWith(".localhost") ? false : i.protocol === "file:";
10947}
10948function ct(i) {
10949  return /^about:(blank|srcdoc)$/.test(i) || i.protocol === "data:" || /^(blob|filesystem):$/.test(i.protocol) ? true : ul(i);
10950}
10951function fl(i, { referrerURLCallback: o3, referrerOriginCallback: a } = {}) {
10952  if (i.referrer === "no-referrer" || i.referrerPolicy === "") return null;
10953  const f2 = i.referrerPolicy;
10954  if (i.referrer === "about:client") return "no-referrer";
10955  const l = i.referrer;
10956  let p2 = Ti(l), h2 = Ti(l, true);
10957  p2.toString().length > 4096 && (p2 = h2), o3 && (p2 = o3(p2)), a && (h2 = a(h2));
10958  const S = new URL(i.url);
10959  switch (f2) {
10960    case "no-referrer":
10961      return "no-referrer";
10962    case "origin":
10963      return h2;
10964    case "unsafe-url":
10965      return p2;
10966    case "strict-origin":
10967      return ct(p2) && !ct(S) ? "no-referrer" : h2.toString();
10968    case "strict-origin-when-cross-origin":
10969      return p2.origin === S.origin ? p2 : ct(p2) && !ct(S) ? "no-referrer" : h2;
10970    case "same-origin":
10971      return p2.origin === S.origin ? p2 : "no-referrer";
10972    case "origin-when-cross-origin":
10973      return p2.origin === S.origin ? p2 : h2;
10974    case "no-referrer-when-downgrade":
10975      return ct(p2) && !ct(S) ? "no-referrer" : p2;
10976    default:
10977      throw new TypeError(`Invalid referrerPolicy: ${f2}`);
10978  }
10979}
10980function cl(i) {
10981  const o3 = (i.get("referrer-policy") || "").split(/[,\s]+/);
10982  let a = "";
10983  for (const f2 of o3) f2 && Ci.has(f2) && (a = f2);
10984  return a;
10985}
10986function pl() {
10987  if (Pi) return Ln;
10988  if (Pi = 1, !globalThis.DOMException) try {
10989    const { MessageChannel: i } = require("worker_threads"), o3 = new i().port1, a = new ArrayBuffer();
10990    o3.postMessage(a, [a, a]);
10991  } catch (i) {
10992    i.constructor.name === "DOMException" && (globalThis.DOMException = i.constructor);
10993  }
10994  return Ln = globalThis.DOMException, Ln;
10995}
10996function Ai(i, o3) {
10997  return __async(this, null, function* () {
10998    return new Promise((a, f2) => {
10999      const l = new dt(i, o3), { parsedURL: p2, options: h2 } = hl(l);
11000      if (!wl.has(p2.protocol)) throw new TypeError(`node-fetch cannot load ${i}. URL scheme "${p2.protocol.replace(/:$/, "")}" is not supported.`);
11001      if (p2.protocol === "data:") {
11002        const g2 = Us(l.url), V = new le(g2, { headers: { "Content-Type": g2.typeFull } });
11003        a(V);
11004        return;
11005      }
11006      const S = (p2.protocol === "https:" ? import_node_https.default : import_node_http.default).request, { signal: v2 } = l;
11007      let w2 = null;
11008      const A = n2(() => {
11009        const g2 = new _r("The operation was aborted.");
11010        f2(g2), l.body && l.body instanceof import_node_stream3.default.Readable && l.body.destroy(g2), !(!w2 || !w2.body) && w2.body.emit("error", g2);
11011      }, "abort");
11012      if (v2 && v2.aborted) {
11013        A();
11014        return;
11015      }
11016      const T2 = n2(() => {
11017        A(), q();
11018      }, "abortAndFinalize"), b = S(p2.toString(), h2);
11019      v2 && v2.addEventListener("abort", T2);
11020      const q = n2(() => {
11021        b.abort(), v2 && v2.removeEventListener("abort", T2);
11022      }, "finalize");
11023      b.on("error", (g2) => {
11024        f2(new G(`request to ${l.url} failed, reason: ${g2.message}`, "system", g2)), q();
11025      }), Rl(b, (g2) => {
11026        w2 && w2.body && w2.body.destroy(g2);
11027      }), process.version < "v14" && b.on("socket", (g2) => {
11028        let V;
11029        g2.prependListener("end", () => {
11030          V = g2._eventsCount;
11031        }), g2.prependListener("close", (I2) => {
11032          if (w2 && V < g2._eventsCount && !I2) {
11033            const F4 = new Error("Premature close");
11034            F4.code = "ERR_STREAM_PREMATURE_CLOSE", w2.body.emit("error", F4);
11035          }
11036        });
11037      }), b.on("response", (g2) => {
11038        b.setTimeout(0);
11039        const V = ol(g2.rawHeaders);
11040        if (jn(g2.statusCode)) {
11041          const z = V.get("Location");
11042          let j = null;
11043          try {
11044            j = z === null ? null : new URL(z, l.url);
11045          } catch (e) {
11046            if (l.redirect !== "manual") {
11047              f2(new G(`uri requested responds with an invalid redirect URL: ${z}`, "invalid-redirect")), q();
11048              return;
11049            }
11050          }
11051          switch (l.redirect) {
11052            case "error":
11053              f2(new G(`uri requested responds with a redirect, redirect mode is set to error: ${l.url}`, "no-redirect")), q();
11054              return;
11055            case "manual":
11056              break;
11057            case "follow": {
11058              if (j === null) break;
11059              if (l.counter >= l.follow) {
11060                f2(new G(`maximum redirect reached at: ${l.url}`, "max-redirect")), q();
11061                return;
11062              }
11063              const U = { headers: new ye(l.headers), follow: l.follow, counter: l.counter + 1, agent: l.agent, compress: l.compress, method: l.method, body: In(l), signal: l.signal, size: l.size, referrer: l.referrer, referrerPolicy: l.referrerPolicy };
11064              if (!Js(l.url, j) || !Xs(l.url, j)) for (const jt of ["authorization", "www-authenticate", "cookie", "cookie2"]) U.headers.delete(jt);
11065              if (g2.statusCode !== 303 && l.body && o3.body instanceof import_node_stream3.default.Readable) {
11066                f2(new G("Cannot follow redirect with body being a readable stream", "unsupported-redirect")), q();
11067                return;
11068              }
11069              (g2.statusCode === 303 || (g2.statusCode === 301 || g2.statusCode === 302) && l.method === "POST") && (U.method = "GET", U.body = void 0, U.headers.delete("content-length"));
11070              const D2 = cl(V);
11071              D2 && (U.referrerPolicy = D2), a(Ai(new dt(j, U))), q();
11072              return;
11073            }
11074            default:
11075              return f2(new TypeError(`Redirect option '${l.redirect}' is not a valid value of RequestRedirect`));
11076          }
11077        }
11078        v2 && g2.once("end", () => {
11079          v2.removeEventListener("abort", T2);
11080        });
11081        let I2 = (0, import_node_stream3.pipeline)(g2, new import_node_stream3.PassThrough(), (z) => {
11082          z && f2(z);
11083        });
11084        process.version < "v12.10" && g2.on("aborted", T2);
11085        const F4 = { url: l.url, status: g2.statusCode, statusText: g2.statusMessage, headers: V, size: l.size, counter: l.counter, highWaterMark: l.highWaterMark }, Q = V.get("Content-Encoding");
11086        if (!l.compress || l.method === "HEAD" || Q === null || g2.statusCode === 204 || g2.statusCode === 304) {
11087          w2 = new le(I2, F4), a(w2);
11088          return;
11089        }
11090        const ge = { flush: import_node_zlib.default.Z_SYNC_FLUSH, finishFlush: import_node_zlib.default.Z_SYNC_FLUSH };
11091        if (Q === "gzip" || Q === "x-gzip") {
11092          I2 = (0, import_node_stream3.pipeline)(I2, import_node_zlib.default.createGunzip(ge), (z) => {
11093            z && f2(z);
11094          }), w2 = new le(I2, F4), a(w2);
11095          return;
11096        }
11097        if (Q === "deflate" || Q === "x-deflate") {
11098          const z = (0, import_node_stream3.pipeline)(g2, new import_node_stream3.PassThrough(), (j) => {
11099            j && f2(j);
11100          });
11101          z.once("data", (j) => {
11102            (j[0] & 15) === 8 ? I2 = (0, import_node_stream3.pipeline)(I2, import_node_zlib.default.createInflate(), (U) => {
11103              U && f2(U);
11104            }) : I2 = (0, import_node_stream3.pipeline)(I2, import_node_zlib.default.createInflateRaw(), (U) => {
11105              U && f2(U);
11106            }), w2 = new le(I2, F4), a(w2);
11107          }), z.once("end", () => {
11108            w2 || (w2 = new le(I2, F4), a(w2));
11109          });
11110          return;
11111        }
11112        if (Q === "br") {
11113          I2 = (0, import_node_stream3.pipeline)(I2, import_node_zlib.default.createBrotliDecompress(), (z) => {
11114            z && f2(z);
11115          }), w2 = new le(I2, F4), a(w2);
11116          return;
11117        }
11118        w2 = new le(I2, F4), a(w2);
11119      }), nl(b, l).catch(f2);
11120    });
11121  });
11122}
11123function Rl(i, o3) {
11124  const a = import_node_buffer.Buffer.from(`0\r
11125\r
11126`);
11127  let f2 = false, l = false, p2;
11128  i.on("response", (h2) => {
11129    const { headers: S } = h2;
11130    f2 = S["transfer-encoding"] === "chunked" && !S["content-length"];
11131  }), i.on("socket", (h2) => {
11132    const S = n2(() => {
11133      if (f2 && !l) {
11134        const w2 = new Error("Premature close");
11135        w2.code = "ERR_STREAM_PREMATURE_CLOSE", o3(w2);
11136      }
11137    }, "onSocketClose"), v2 = n2((w2) => {
11138      l = import_node_buffer.Buffer.compare(w2.slice(-5), a) === 0, !l && p2 && (l = import_node_buffer.Buffer.compare(p2.slice(-3), a.slice(0, 3)) === 0 && import_node_buffer.Buffer.compare(w2.slice(-2), a.slice(3)) === 0), p2 = w2;
11139    }, "onData");
11140    h2.prependListener("close", S), h2.on("data", v2), i.on("close", () => {
11141      h2.removeListener("close", S), h2.removeListener("data", v2);
11142    });
11143  });
11144}
11145function W(i) {
11146  const o3 = Bi.get(i);
11147  return console.assert(o3 != null, "'this' is expected an Event object, but got", i), o3;
11148}
11149function ki(i) {
11150  if (i.passiveListener != null) {
11151    typeof console < "u" && typeof console.error == "function" && console.error("Unable to preventDefault inside passive event listener invocation.", i.passiveListener);
11152    return;
11153  }
11154  i.event.cancelable && (i.canceled = true, typeof i.event.preventDefault == "function" && i.event.preventDefault());
11155}
11156function ht(i, o3) {
11157  Bi.set(this, { eventTarget: i, event: o3, eventPhase: 2, currentTarget: i, canceled: false, stopped: false, immediateStopped: false, passiveListener: null, timeStamp: o3.timeStamp || Date.now() }), Object.defineProperty(this, "isTrusted", { value: false, enumerable: true });
11158  const a = Object.keys(o3);
11159  for (let f2 = 0; f2 < a.length; ++f2) {
11160    const l = a[f2];
11161    l in this || Object.defineProperty(this, l, Wi(l));
11162  }
11163}
11164function Wi(i) {
11165  return { get() {
11166    return W(this).event[i];
11167  }, set(o3) {
11168    W(this).event[i] = o3;
11169  }, configurable: true, enumerable: true };
11170}
11171function Tl(i) {
11172  return { value() {
11173    const o3 = W(this).event;
11174    return o3[i].apply(o3, arguments);
11175  }, configurable: true, enumerable: true };
11176}
11177function Cl(i, o3) {
11178  const a = Object.keys(o3);
11179  if (a.length === 0) return i;
11180  function f2(l, p2) {
11181    i.call(this, l, p2);
11182  }
11183  n2(f2, "CustomEvent"), f2.prototype = Object.create(i.prototype, { constructor: { value: f2, configurable: true, writable: true } });
11184  for (let l = 0; l < a.length; ++l) {
11185    const p2 = a[l];
11186    if (!(p2 in i.prototype)) {
11187      const S = typeof Object.getOwnPropertyDescriptor(o3, p2).value == "function";
11188      Object.defineProperty(f2.prototype, p2, S ? Tl(p2) : Wi(p2));
11189    }
11190  }
11191  return f2;
11192}
11193function qi(i) {
11194  if (i == null || i === Object.prototype) return ht;
11195  let o3 = Dn.get(i);
11196  return o3 == null && (o3 = Cl(qi(Object.getPrototypeOf(i)), i), Dn.set(i, o3)), o3;
11197}
11198function Pl(i, o3) {
11199  const a = qi(Object.getPrototypeOf(o3));
11200  return new a(i, o3);
11201}
11202function vl(i) {
11203  return W(i).immediateStopped;
11204}
11205function El(i, o3) {
11206  W(i).eventPhase = o3;
11207}
11208function Al(i, o3) {
11209  W(i).currentTarget = o3;
11210}
11211function Oi(i, o3) {
11212  W(i).passiveListener = o3;
11213}
11214function Rr(i) {
11215  return i !== null && typeof i == "object";
11216}
11217function Ot(i) {
11218  const o3 = zi.get(i);
11219  if (o3 == null) throw new TypeError("'this' is expected an EventTarget object, but got another value.");
11220  return o3;
11221}
11222function Bl(i) {
11223  return { get() {
11224    let a = Ot(this).get(i);
11225    for (; a != null; ) {
11226      if (a.listenerType === wr) return a.listener;
11227      a = a.next;
11228    }
11229    return null;
11230  }, set(o3) {
11231    typeof o3 != "function" && !Rr(o3) && (o3 = null);
11232    const a = Ot(this);
11233    let f2 = null, l = a.get(i);
11234    for (; l != null; ) l.listenerType === wr ? f2 !== null ? f2.next = l.next : l.next !== null ? a.set(i, l.next) : a.delete(i) : f2 = l, l = l.next;
11235    if (o3 !== null) {
11236      const p2 = { listener: o3, listenerType: wr, passive: false, once: false, next: null };
11237      f2 === null ? a.set(i, p2) : f2.next = p2;
11238    }
11239  }, configurable: true, enumerable: true };
11240}
11241function ji(i, o3) {
11242  Object.defineProperty(i, `on${o3}`, Bl(o3));
11243}
11244function Li(i) {
11245  function o3() {
11246    Pe.call(this);
11247  }
11248  n2(o3, "CustomEventTarget"), o3.prototype = Object.create(Pe.prototype, { constructor: { value: o3, configurable: true, writable: true } });
11249  for (let a = 0; a < i.length; ++a) ji(o3.prototype, i[a]);
11250  return o3;
11251}
11252function Pe() {
11253  if (this instanceof Pe) {
11254    zi.set(this, /* @__PURE__ */ new Map());
11255    return;
11256  }
11257  if (arguments.length === 1 && Array.isArray(arguments[0])) return Li(arguments[0]);
11258  if (arguments.length > 0) {
11259    const i = new Array(arguments.length);
11260    for (let o3 = 0; o3 < arguments.length; ++o3) i[o3] = arguments[o3];
11261    return Li(i);
11262  }
11263  throw new TypeError("Cannot call a class as a function");
11264}
11265function kl() {
11266  const i = Object.create(pt.prototype);
11267  return Pe.call(i), Tr.set(i, false), i;
11268}
11269function Wl(i) {
11270  Tr.get(i) === false && (Tr.set(i, true), i.dispatchEvent({ type: "abort" }));
11271}
11272function Di(i) {
11273  const o3 = $i.get(i);
11274  if (o3 == null) throw new TypeError(`Expected 'this' to be an 'AbortController' object, but got ${i === null ? "null" : typeof i}`);
11275  return o3;
11276}
11277function Ui() {
11278  var _a2, _b2, _c, _d;
11279  !((_b2 = (_a2 = globalThis.process) == null ? void 0 : _a2.versions) == null ? void 0 : _b2.node) && !((_d = (_c = globalThis.process) == null ? void 0 : _c.env) == null ? void 0 : _d.DISABLE_NODE_FETCH_NATIVE_WARN || true) && console.warn("[node-fetch-native] Node.js compatible build of `node-fetch-native` is being used in a non-Node.js environment. Please make sure you are using proper export conditions or report this issue to https://github.com/unjs/node-fetch-native. You can set `process.env.DISABLE_NODE_FETCH_NATIVE_WARN` to disable this warning.");
11280}
11281var import_node_http, import_node_https, import_node_zlib, import_node_stream3, import_node_buffer, import_node_util3, import_node_url2, import_node_net, import_node_fs4, import_node_path5, Os, fi, n2, ci, O, be, X, ve, zt, bt, Cr, ze, It, Ft, mt, ee, yt, He, Ve, gt, pi, kt, xs, bi, mi, yi, gi, ut, Vs, qn, Wt, Qs, Ys, _i, Gs, Si, On, Ue, br, Un, ft, xn, G, mr, wi, yr, Ks, Js, Xs, el, H, Nn, xe, In, tl, Ri, rl, nl, gr, Fn, Pr, ye, il, jn, se, Ne, le, al, Ci, sl, $2, qt, dl, vr, dt, hl, Hn, _r, Ln, Pi, bl, ml, $n, yl, gl, _l, Sl, vi, Ei, Er, Sr, wl, Bi, Dn, zi, Ii, Fi, wr, Vn, pt, Tr, Mn, $i, ql, Ol, Mi;
11282var init_node = __esm({
11283  "node_modules/node-fetch-native/dist/node.mjs"() {
11284    "use strict";
11285    import_node_http = __toESM(require("http"), 1);
11286    import_node_https = __toESM(require("https"), 1);
11287    import_node_zlib = __toESM(require("zlib"), 1);
11288    import_node_stream3 = __toESM(require("stream"), 1);
11289    import_node_buffer = require("buffer");
11290    import_node_util3 = require("util");
11291    init_node_fetch_native_DfbY2q_x();
11292    import_node_url2 = require("url");
11293    import_node_net = require("net");
11294    import_node_fs4 = require("fs");
11295    import_node_path5 = require("path");
11296    Os = Object.defineProperty;
11297    fi = (i) => {
11298      throw TypeError(i);
11299    };
11300    n2 = (i, o3) => Os(i, "name", { value: o3, configurable: true });
11301    ci = (i, o3, a) => o3.has(i) || fi("Cannot " + a);
11302    O = (i, o3, a) => (ci(i, o3, "read from private field"), a ? a.call(i) : o3.get(i));
11303    be = (i, o3, a) => o3.has(i) ? fi("Cannot add the same private member more than once") : o3 instanceof WeakSet ? o3.add(i) : o3.set(i, a);
11304    X = (i, o3, a, f2) => (ci(i, o3, "write to private field"), f2 ? f2.call(i, a) : o3.set(i, a), a);
11305    n2(Us, "dataUriToBuffer");
11306    pi = {};
11307    kt = { exports: {} };
11308    xs = kt.exports;
11309    n2(Ns, "requirePonyfill_es2018");
11310    n2(Hs, "requireStreams"), Hs();
11311    yi = 65536;
11312    n2(Wn, "toIterator");
11313    gi = (ze = class {
11314      constructor(o3 = [], a = {}) {
11315        be(this, ve, []);
11316        be(this, zt, "");
11317        be(this, bt, 0);
11318        be(this, Cr, "transparent");
11319        if (typeof o3 != "object" || o3 === null) throw new TypeError("Failed to construct 'Blob': The provided value cannot be converted to a sequence.");
11320        if (typeof o3[Symbol.iterator] != "function") throw new TypeError("Failed to construct 'Blob': The object must have a callable @@iterator property.");
11321        if (typeof a != "object" && typeof a != "function") throw new TypeError("Failed to construct 'Blob': parameter 2 cannot convert to dictionary.");
11322        a === null && (a = {});
11323        const f2 = new TextEncoder();
11324        for (const p2 of o3) {
11325          let h2;
11326          ArrayBuffer.isView(p2) ? h2 = new Uint8Array(p2.buffer.slice(p2.byteOffset, p2.byteOffset + p2.byteLength)) : p2 instanceof ArrayBuffer ? h2 = new Uint8Array(p2.slice(0)) : p2 instanceof ze ? h2 = p2 : h2 = f2.encode(`${p2}`), X(this, bt, O(this, bt) + (ArrayBuffer.isView(h2) ? h2.byteLength : h2.size)), O(this, ve).push(h2);
11327        }
11328        X(this, Cr, `${a.endings === void 0 ? "transparent" : a.endings}`);
11329        const l = a.type === void 0 ? "" : String(a.type);
11330        X(this, zt, /^[\x20-\x7E]*$/.test(l) ? l : "");
11331      }
11332      get size() {
11333        return O(this, bt);
11334      }
11335      get type() {
11336        return O(this, zt);
11337      }
11338      text() {
11339        return __async(this, null, function* () {
11340          const o3 = new TextDecoder();
11341          let a = "";
11342          try {
11343            for (var iter = __forAwait(Wn(O(this, ve), false)), more, temp, error; more = !(temp = yield iter.next()).done; more = false) {
11344              const f2 = temp.value;
11345              a += o3.decode(f2, { stream: true });
11346            }
11347          } catch (temp) {
11348            error = [temp];
11349          } finally {
11350            try {
11351              more && (temp = iter.return) && (yield temp.call(iter));
11352            } finally {
11353              if (error)
11354                throw error[0];
11355            }
11356          }
11357          return a += o3.decode(), a;
11358        });
11359      }
11360      arrayBuffer() {
11361        return __async(this, null, function* () {
11362          const o3 = new Uint8Array(this.size);
11363          let a = 0;
11364          try {
11365            for (var iter = __forAwait(Wn(O(this, ve), false)), more, temp, error; more = !(temp = yield iter.next()).done; more = false) {
11366              const f2 = temp.value;
11367              o3.set(f2, a), a += f2.length;
11368            }
11369          } catch (temp) {
11370            error = [temp];
11371          } finally {
11372            try {
11373              more && (temp = iter.return) && (yield temp.call(iter));
11374            } finally {
11375              if (error)
11376                throw error[0];
11377            }
11378          }
11379          return o3.buffer;
11380        });
11381      }
11382      stream() {
11383        const o3 = Wn(O(this, ve), true);
11384        return new globalThis.ReadableStream({ type: "bytes", pull(a) {
11385          return __async(this, null, function* () {
11386            const f2 = yield o3.next();
11387            f2.done ? a.close() : a.enqueue(f2.value);
11388          });
11389        }, cancel() {
11390          return __async(this, null, function* () {
11391            yield o3.return();
11392          });
11393        } });
11394      }
11395      slice(o3 = 0, a = this.size, f2 = "") {
11396        const { size: l } = this;
11397        let p2 = o3 < 0 ? Math.max(l + o3, 0) : Math.min(o3, l), h2 = a < 0 ? Math.max(l + a, 0) : Math.min(a, l);
11398        const S = Math.max(h2 - p2, 0), v2 = O(this, ve), w2 = [];
11399        let A = 0;
11400        for (const b of v2) {
11401          if (A >= S) break;
11402          const q = ArrayBuffer.isView(b) ? b.byteLength : b.size;
11403          if (p2 && q <= p2) p2 -= q, h2 -= q;
11404          else {
11405            let g2;
11406            ArrayBuffer.isView(b) ? (g2 = b.subarray(p2, Math.min(q, h2)), A += g2.byteLength) : (g2 = b.slice(p2, Math.min(q, h2)), A += g2.size), h2 -= q, w2.push(g2), p2 = 0;
11407          }
11408        }
11409        const T2 = new ze([], { type: String(f2).toLowerCase() });
11410        return X(T2, bt, S), X(T2, ve, w2), T2;
11411      }
11412      get [Symbol.toStringTag]() {
11413        return "Blob";
11414      }
11415      static [Symbol.hasInstance](o3) {
11416        return o3 && typeof o3 == "object" && typeof o3.constructor == "function" && (typeof o3.stream == "function" || typeof o3.arrayBuffer == "function") && /^(Blob|File)$/.test(o3[Symbol.toStringTag]);
11417      }
11418    }, ve = /* @__PURE__ */ new WeakMap(), zt = /* @__PURE__ */ new WeakMap(), bt = /* @__PURE__ */ new WeakMap(), Cr = /* @__PURE__ */ new WeakMap(), n2(ze, "Blob"), ze);
11419    Object.defineProperties(gi.prototype, { size: { enumerable: true }, type: { enumerable: true }, slice: { enumerable: true } });
11420    ut = gi;
11421    Vs = (mt = class extends ut {
11422      constructor(a, f2, l = {}) {
11423        if (arguments.length < 2) throw new TypeError(`Failed to construct 'File': 2 arguments required, but only ${arguments.length} present.`);
11424        super(a, l);
11425        be(this, It, 0);
11426        be(this, Ft, "");
11427        l === null && (l = {});
11428        const p2 = l.lastModified === void 0 ? Date.now() : Number(l.lastModified);
11429        Number.isNaN(p2) || X(this, It, p2), X(this, Ft, String(f2));
11430      }
11431      get name() {
11432        return O(this, Ft);
11433      }
11434      get lastModified() {
11435        return O(this, It);
11436      }
11437      get [Symbol.toStringTag]() {
11438        return "File";
11439      }
11440      static [Symbol.hasInstance](a) {
11441        return !!a && a instanceof ut && /^(File)$/.test(a[Symbol.toStringTag]);
11442      }
11443    }, It = /* @__PURE__ */ new WeakMap(), Ft = /* @__PURE__ */ new WeakMap(), n2(mt, "File"), mt);
11444    qn = Vs;
11445    ({ toStringTag: Wt, iterator: Qs, hasInstance: Ys } = Symbol);
11446    _i = Math.random;
11447    Gs = "append,set,get,getAll,delete,keys,values,entries,forEach,constructor".split(",");
11448    Si = n2((i, o3, a) => (i += "", /^(Blob|File)$/.test(o3 && o3[Wt]) ? [(a = a !== void 0 ? a + "" : o3[Wt] == "File" ? o3.name : "blob", i), o3.name !== a || o3[Wt] == "blob" ? new qn([o3], a, o3) : o3] : [i, o3 + ""]), "f");
11449    On = n2((i, o3) => (o3 ? i : i.replace(/\r?\n|\r/g, `\r
11450`)).replace(/\n/g, "%0A").replace(/\r/g, "%0D").replace(/"/g, "%22"), "e$1");
11451    Ue = n2((i, o3, a) => {
11452      if (o3.length < a) throw new TypeError(`Failed to execute '${i}' on 'FormData': ${a} arguments required, but only ${o3.length} present.`);
11453    }, "x");
11454    br = (yt = class {
11455      constructor(...o3) {
11456        be(this, ee, []);
11457        if (o3.length) throw new TypeError("Failed to construct 'FormData': parameter 1 is not of type 'HTMLFormElement'.");
11458      }
11459      get [Wt]() {
11460        return "FormData";
11461      }
11462      [Qs]() {
11463        return this.entries();
11464      }
11465      static [Ys](o3) {
11466        return o3 && typeof o3 == "object" && o3[Wt] === "FormData" && !Gs.some((a) => typeof o3[a] != "function");
11467      }
11468      append(...o3) {
11469        Ue("append", arguments, 2), O(this, ee).push(Si(...o3));
11470      }
11471      delete(o3) {
11472        Ue("delete", arguments, 1), o3 += "", X(this, ee, O(this, ee).filter(([a]) => a !== o3));
11473      }
11474      get(o3) {
11475        Ue("get", arguments, 1), o3 += "";
11476        for (var a = O(this, ee), f2 = a.length, l = 0; l < f2; l++) if (a[l][0] === o3) return a[l][1];
11477        return null;
11478      }
11479      getAll(o3, a) {
11480        return Ue("getAll", arguments, 1), a = [], o3 += "", O(this, ee).forEach((f2) => f2[0] === o3 && a.push(f2[1])), a;
11481      }
11482      has(o3) {
11483        return Ue("has", arguments, 1), o3 += "", O(this, ee).some((a) => a[0] === o3);
11484      }
11485      forEach(o3, a) {
11486        Ue("forEach", arguments, 1);
11487        for (var [f2, l] of this) o3.call(a, l, f2, this);
11488      }
11489      set(...o3) {
11490        Ue("set", arguments, 2);
11491        var a = [], f2 = true;
11492        o3 = Si(...o3), O(this, ee).forEach((l) => {
11493          l[0] === o3[0] ? f2 && (f2 = !a.push(o3)) : a.push(l);
11494        }), f2 && a.push(o3), X(this, ee, a);
11495      }
11496      *entries() {
11497        yield* __yieldStar(O(this, ee));
11498      }
11499      *keys() {
11500        for (var [o3] of this) yield o3;
11501      }
11502      *values() {
11503        for (var [, o3] of this) yield o3;
11504      }
11505    }, ee = /* @__PURE__ */ new WeakMap(), n2(yt, "FormData"), yt);
11506    n2(Zs, "formDataToBlob");
11507    Un = class Un2 extends Error {
11508      constructor(o3, a) {
11509        super(o3), Error.captureStackTrace(this, this.constructor), this.type = a;
11510      }
11511      get name() {
11512        return this.constructor.name;
11513      }
11514      get [Symbol.toStringTag]() {
11515        return this.constructor.name;
11516      }
11517    };
11518    n2(Un, "FetchBaseError");
11519    ft = Un;
11520    xn = class xn2 extends ft {
11521      constructor(o3, a, f2) {
11522        super(o3, a), f2 && (this.code = this.errno = f2.code, this.erroredSysCall = f2.syscall);
11523      }
11524    };
11525    n2(xn, "FetchError");
11526    G = xn;
11527    mr = Symbol.toStringTag;
11528    wi = n2((i) => typeof i == "object" && typeof i.append == "function" && typeof i.delete == "function" && typeof i.get == "function" && typeof i.getAll == "function" && typeof i.has == "function" && typeof i.set == "function" && typeof i.sort == "function" && i[mr] === "URLSearchParams", "isURLSearchParameters");
11529    yr = n2((i) => i && typeof i == "object" && typeof i.arrayBuffer == "function" && typeof i.type == "string" && typeof i.stream == "function" && typeof i.constructor == "function" && /^(Blob|File)$/.test(i[mr]), "isBlob");
11530    Ks = n2((i) => typeof i == "object" && (i[mr] === "AbortSignal" || i[mr] === "EventTarget"), "isAbortSignal");
11531    Js = n2((i, o3) => {
11532      const a = new URL(o3).hostname, f2 = new URL(i).hostname;
11533      return a === f2 || a.endsWith(`.${f2}`);
11534    }, "isDomainOrSubdomain");
11535    Xs = n2((i, o3) => {
11536      const a = new URL(o3).protocol, f2 = new URL(i).protocol;
11537      return a === f2;
11538    }, "isSameProtocol");
11539    el = (0, import_node_util3.promisify)(import_node_stream3.default.pipeline);
11540    H = Symbol("Body internals");
11541    Nn = class Nn2 {
11542      constructor(o3, { size: a = 0 } = {}) {
11543        let f2 = null;
11544        o3 === null ? o3 = null : wi(o3) ? o3 = import_node_buffer.Buffer.from(o3.toString()) : yr(o3) || import_node_buffer.Buffer.isBuffer(o3) || (import_node_util3.types.isAnyArrayBuffer(o3) ? o3 = import_node_buffer.Buffer.from(o3) : ArrayBuffer.isView(o3) ? o3 = import_node_buffer.Buffer.from(o3.buffer, o3.byteOffset, o3.byteLength) : o3 instanceof import_node_stream3.default || (o3 instanceof br ? (o3 = Zs(o3), f2 = o3.type.split("=")[1]) : o3 = import_node_buffer.Buffer.from(String(o3))));
11545        let l = o3;
11546        import_node_buffer.Buffer.isBuffer(o3) ? l = import_node_stream3.default.Readable.from(o3) : yr(o3) && (l = import_node_stream3.default.Readable.from(o3.stream())), this[H] = { body: o3, stream: l, boundary: f2, disturbed: false, error: null }, this.size = a, o3 instanceof import_node_stream3.default && o3.on("error", (p2) => {
11547          const h2 = p2 instanceof ft ? p2 : new G(`Invalid response body while trying to fetch ${this.url}: ${p2.message}`, "system", p2);
11548          this[H].error = h2;
11549        });
11550      }
11551      get body() {
11552        return this[H].stream;
11553      }
11554      get bodyUsed() {
11555        return this[H].disturbed;
11556      }
11557      arrayBuffer() {
11558        return __async(this, null, function* () {
11559          const { buffer: o3, byteOffset: a, byteLength: f2 } = yield zn(this);
11560          return o3.slice(a, a + f2);
11561        });
11562      }
11563      formData() {
11564        return __async(this, null, function* () {
11565          const o3 = this.headers.get("content-type");
11566          if (o3.startsWith("application/x-www-form-urlencoded")) {
11567            const f2 = new br(), l = new URLSearchParams(yield this.text());
11568            for (const [p2, h2] of l) f2.append(p2, h2);
11569            return f2;
11570          }
11571          const { toFormData: a } = yield Promise.resolve().then(() => (init_multipart_parser(), multipart_parser_exports));
11572          return a(this.body, o3);
11573        });
11574      }
11575      blob() {
11576        return __async(this, null, function* () {
11577          const o3 = this.headers && this.headers.get("content-type") || this[H].body && this[H].body.type || "", a = yield this.arrayBuffer();
11578          return new ut([a], { type: o3 });
11579        });
11580      }
11581      json() {
11582        return __async(this, null, function* () {
11583          const o3 = yield this.text();
11584          return JSON.parse(o3);
11585        });
11586      }
11587      text() {
11588        return __async(this, null, function* () {
11589          const o3 = yield zn(this);
11590          return new TextDecoder().decode(o3);
11591        });
11592      }
11593      buffer() {
11594        return zn(this);
11595      }
11596    };
11597    n2(Nn, "Body");
11598    xe = Nn;
11599    xe.prototype.buffer = (0, import_node_util3.deprecate)(xe.prototype.buffer, "Please use 'response.arrayBuffer()' instead of 'response.buffer()'", "node-fetch#buffer"), Object.defineProperties(xe.prototype, { body: { enumerable: true }, bodyUsed: { enumerable: true }, arrayBuffer: { enumerable: true }, blob: { enumerable: true }, json: { enumerable: true }, text: { enumerable: true }, data: { get: (0, import_node_util3.deprecate)(() => {
11600    }, "data doesn't exist, use json(), text(), arrayBuffer(), or body instead", "https://github.com/node-fetch/node-fetch/issues/1000 (response)") } });
11601    n2(zn, "consumeBody");
11602    In = n2((i, o3) => {
11603      let a, f2, { body: l } = i[H];
11604      if (i.bodyUsed) throw new Error("cannot clone body after it is used");
11605      return l instanceof import_node_stream3.default && typeof l.getBoundary != "function" && (a = new import_node_stream3.PassThrough({ highWaterMark: o3 }), f2 = new import_node_stream3.PassThrough({ highWaterMark: o3 }), l.pipe(a), l.pipe(f2), i[H].stream = a, l = f2), l;
11606    }, "clone");
11607    tl = (0, import_node_util3.deprecate)((i) => i.getBoundary(), "form-data doesn't follow the spec and requires special treatment. Use alternative package", "https://github.com/node-fetch/node-fetch/issues/1167");
11608    Ri = n2((i, o3) => i === null ? null : typeof i == "string" ? "text/plain;charset=UTF-8" : wi(i) ? "application/x-www-form-urlencoded;charset=UTF-8" : yr(i) ? i.type || null : import_node_buffer.Buffer.isBuffer(i) || import_node_util3.types.isAnyArrayBuffer(i) || ArrayBuffer.isView(i) ? null : i instanceof br ? `multipart/form-data; boundary=${o3[H].boundary}` : i && typeof i.getBoundary == "function" ? `multipart/form-data;boundary=${tl(i)}` : i instanceof import_node_stream3.default ? null : "text/plain;charset=UTF-8", "extractContentType");
11609    rl = n2((i) => {
11610      const { body: o3 } = i[H];
11611      return o3 === null ? 0 : yr(o3) ? o3.size : import_node_buffer.Buffer.isBuffer(o3) ? o3.length : o3 && typeof o3.getLengthSync == "function" && o3.hasKnownLength && o3.hasKnownLength() ? o3.getLengthSync() : null;
11612    }, "getTotalBytes");
11613    nl = n2((_0, _1) => __async(null, [_0, _1], function* (i, { body: o3 }) {
11614      o3 === null ? i.end() : yield el(o3, i);
11615    }), "writeToStream");
11616    gr = typeof import_node_http.default.validateHeaderName == "function" ? import_node_http.default.validateHeaderName : (i) => {
11617      if (!/^[\^`\-\w!#$%&'*+.|~]+$/.test(i)) {
11618        const o3 = new TypeError(`Header name must be a valid HTTP token [${i}]`);
11619        throw Object.defineProperty(o3, "code", { value: "ERR_INVALID_HTTP_TOKEN" }), o3;
11620      }
11621    };
11622    Fn = typeof import_node_http.default.validateHeaderValue == "function" ? import_node_http.default.validateHeaderValue : (i, o3) => {
11623      if (/[^\t\u0020-\u007E\u0080-\u00FF]/.test(o3)) {
11624        const a = new TypeError(`Invalid character in header content ["${i}"]`);
11625        throw Object.defineProperty(a, "code", { value: "ERR_INVALID_CHAR" }), a;
11626      }
11627    };
11628    Pr = class Pr2 extends URLSearchParams {
11629      constructor(o3) {
11630        let a = [];
11631        if (o3 instanceof Pr2) {
11632          const f2 = o3.raw();
11633          for (const [l, p2] of Object.entries(f2)) a.push(...p2.map((h2) => [l, h2]));
11634        } else if (o3 != null) if (typeof o3 == "object" && !import_node_util3.types.isBoxedPrimitive(o3)) {
11635          const f2 = o3[Symbol.iterator];
11636          if (f2 == null) a.push(...Object.entries(o3));
11637          else {
11638            if (typeof f2 != "function") throw new TypeError("Header pairs must be iterable");
11639            a = [...o3].map((l) => {
11640              if (typeof l != "object" || import_node_util3.types.isBoxedPrimitive(l)) throw new TypeError("Each header pair must be an iterable object");
11641              return [...l];
11642            }).map((l) => {
11643              if (l.length !== 2) throw new TypeError("Each header pair must be a name/value tuple");
11644              return [...l];
11645            });
11646          }
11647        } else throw new TypeError("Failed to construct 'Headers': The provided value is not of type '(sequence<sequence<ByteString>> or record<ByteString, ByteString>)");
11648        return a = a.length > 0 ? a.map(([f2, l]) => (gr(f2), Fn(f2, String(l)), [String(f2).toLowerCase(), String(l)])) : void 0, super(a), new Proxy(this, { get(f2, l, p2) {
11649          switch (l) {
11650            case "append":
11651            case "set":
11652              return (h2, S) => (gr(h2), Fn(h2, String(S)), URLSearchParams.prototype[l].call(f2, String(h2).toLowerCase(), String(S)));
11653            case "delete":
11654            case "has":
11655            case "getAll":
11656              return (h2) => (gr(h2), URLSearchParams.prototype[l].call(f2, String(h2).toLowerCase()));
11657            case "keys":
11658              return () => (f2.sort(), new Set(URLSearchParams.prototype.keys.call(f2)).keys());
11659            default:
11660              return Reflect.get(f2, l, p2);
11661          }
11662        } });
11663      }
11664      get [Symbol.toStringTag]() {
11665        return this.constructor.name;
11666      }
11667      toString() {
11668        return Object.prototype.toString.call(this);
11669      }
11670      get(o3) {
11671        const a = this.getAll(o3);
11672        if (a.length === 0) return null;
11673        let f2 = a.join(", ");
11674        return /^content-encoding$/i.test(o3) && (f2 = f2.toLowerCase()), f2;
11675      }
11676      forEach(o3, a = void 0) {
11677        for (const f2 of this.keys()) Reflect.apply(o3, a, [this.get(f2), f2, this]);
11678      }
11679      *values() {
11680        for (const o3 of this.keys()) yield this.get(o3);
11681      }
11682      *entries() {
11683        for (const o3 of this.keys()) yield [o3, this.get(o3)];
11684      }
11685      [Symbol.iterator]() {
11686        return this.entries();
11687      }
11688      raw() {
11689        return [...this.keys()].reduce((o3, a) => (o3[a] = this.getAll(a), o3), {});
11690      }
11691      [Symbol.for("nodejs.util.inspect.custom")]() {
11692        return [...this.keys()].reduce((o3, a) => {
11693          const f2 = this.getAll(a);
11694          return a === "host" ? o3[a] = f2[0] : o3[a] = f2.length > 1 ? f2 : f2[0], o3;
11695        }, {});
11696      }
11697    };
11698    n2(Pr, "Headers");
11699    ye = Pr;
11700    Object.defineProperties(ye.prototype, ["get", "entries", "forEach", "values"].reduce((i, o3) => (i[o3] = { enumerable: true }, i), {}));
11701    n2(ol, "fromRawHeaders");
11702    il = /* @__PURE__ */ new Set([301, 302, 303, 307, 308]);
11703    jn = n2((i) => il.has(i), "isRedirect");
11704    se = Symbol("Response internals");
11705    Ne = class Ne2 extends xe {
11706      constructor(o3 = null, a = {}) {
11707        super(o3, a);
11708        const f2 = a.status != null ? a.status : 200, l = new ye(a.headers);
11709        if (o3 !== null && !l.has("Content-Type")) {
11710          const p2 = Ri(o3, this);
11711          p2 && l.append("Content-Type", p2);
11712        }
11713        this[se] = { type: "default", url: a.url, status: f2, statusText: a.statusText || "", headers: l, counter: a.counter, highWaterMark: a.highWaterMark };
11714      }
11715      get type() {
11716        return this[se].type;
11717      }
11718      get url() {
11719        return this[se].url || "";
11720      }
11721      get status() {
11722        return this[se].status;
11723      }
11724      get ok() {
11725        return this[se].status >= 200 && this[se].status < 300;
11726      }
11727      get redirected() {
11728        return this[se].counter > 0;
11729      }
11730      get statusText() {
11731        return this[se].statusText;
11732      }
11733      get headers() {
11734        return this[se].headers;
11735      }
11736      get highWaterMark() {
11737        return this[se].highWaterMark;
11738      }
11739      clone() {
11740        return new Ne2(In(this, this.highWaterMark), { type: this.type, url: this.url, status: this.status, statusText: this.statusText, headers: this.headers, ok: this.ok, redirected: this.redirected, size: this.size, highWaterMark: this.highWaterMark });
11741      }
11742      static redirect(o3, a = 302) {
11743        if (!jn(a)) throw new RangeError('Failed to execute "redirect" on "response": Invalid status code');
11744        return new Ne2(null, { headers: { location: new URL(o3).toString() }, status: a });
11745      }
11746      static error() {
11747        const o3 = new Ne2(null, { status: 0, statusText: "" });
11748        return o3[se].type = "error", o3;
11749      }
11750      static json(o3 = void 0, a = {}) {
11751        const f2 = JSON.stringify(o3);
11752        if (f2 === void 0) throw new TypeError("data is not JSON serializable");
11753        const l = new ye(a && a.headers);
11754        return l.has("content-type") || l.set("content-type", "application/json"), new Ne2(f2, __spreadProps(__spreadValues({}, a), { headers: l }));
11755      }
11756      get [Symbol.toStringTag]() {
11757        return "Response";
11758      }
11759    };
11760    n2(Ne, "Response");
11761    le = Ne;
11762    Object.defineProperties(le.prototype, { type: { enumerable: true }, url: { enumerable: true }, status: { enumerable: true }, ok: { enumerable: true }, redirected: { enumerable: true }, statusText: { enumerable: true }, headers: { enumerable: true }, clone: { enumerable: true } });
11763    al = n2((i) => {
11764      if (i.search) return i.search;
11765      const o3 = i.href.length - 1, a = i.hash || (i.href[o3] === "#" ? "#" : "");
11766      return i.href[o3 - a.length] === "?" ? "?" : "";
11767    }, "getSearch");
11768    n2(Ti, "stripURLForUseAsAReferrer");
11769    Ci = /* @__PURE__ */ new Set(["", "no-referrer", "no-referrer-when-downgrade", "same-origin", "origin", "strict-origin", "origin-when-cross-origin", "strict-origin-when-cross-origin", "unsafe-url"]);
11770    sl = "strict-origin-when-cross-origin";
11771    n2(ll, "validateReferrerPolicy");
11772    n2(ul, "isOriginPotentiallyTrustworthy");
11773    n2(ct, "isUrlPotentiallyTrustworthy");
11774    n2(fl, "determineRequestsReferrer");
11775    n2(cl, "parseReferrerPolicyFromHeader");
11776    $2 = Symbol("Request internals");
11777    qt = n2((i) => typeof i == "object" && typeof i[$2] == "object", "isRequest");
11778    dl = (0, import_node_util3.deprecate)(() => {
11779    }, ".data is not a valid RequestInit property, use .body instead", "https://github.com/node-fetch/node-fetch/issues/1000 (request)");
11780    vr = class vr2 extends xe {
11781      constructor(o3, a = {}) {
11782        let f2;
11783        if (qt(o3) ? f2 = new URL(o3.url) : (f2 = new URL(o3), o3 = {}), f2.username !== "" || f2.password !== "") throw new TypeError(`${f2} is an url with embedded credentials.`);
11784        let l = a.method || o3.method || "GET";
11785        if (/^(delete|get|head|options|post|put)$/i.test(l) && (l = l.toUpperCase()), !qt(a) && "data" in a && dl(), (a.body != null || qt(o3) && o3.body !== null) && (l === "GET" || l === "HEAD")) throw new TypeError("Request with GET/HEAD method cannot have body");
11786        const p2 = a.body ? a.body : qt(o3) && o3.body !== null ? In(o3) : null;
11787        super(p2, { size: a.size || o3.size || 0 });
11788        const h2 = new ye(a.headers || o3.headers || {});
11789        if (p2 !== null && !h2.has("Content-Type")) {
11790          const w2 = Ri(p2, this);
11791          w2 && h2.set("Content-Type", w2);
11792        }
11793        let S = qt(o3) ? o3.signal : null;
11794        if ("signal" in a && (S = a.signal), S != null && !Ks(S)) throw new TypeError("Expected signal to be an instanceof AbortSignal or EventTarget");
11795        let v2 = a.referrer == null ? o3.referrer : a.referrer;
11796        if (v2 === "") v2 = "no-referrer";
11797        else if (v2) {
11798          const w2 = new URL(v2);
11799          v2 = /^about:(\/\/)?client$/.test(w2) ? "client" : w2;
11800        } else v2 = void 0;
11801        this[$2] = { method: l, redirect: a.redirect || o3.redirect || "follow", headers: h2, parsedURL: f2, signal: S, referrer: v2 }, this.follow = a.follow === void 0 ? o3.follow === void 0 ? 20 : o3.follow : a.follow, this.compress = a.compress === void 0 ? o3.compress === void 0 ? true : o3.compress : a.compress, this.counter = a.counter || o3.counter || 0, this.agent = a.agent || o3.agent, this.highWaterMark = a.highWaterMark || o3.highWaterMark || 16384, this.insecureHTTPParser = a.insecureHTTPParser || o3.insecureHTTPParser || false, this.referrerPolicy = a.referrerPolicy || o3.referrerPolicy || "";
11802      }
11803      get method() {
11804        return this[$2].method;
11805      }
11806      get url() {
11807        return (0, import_node_url2.format)(this[$2].parsedURL);
11808      }
11809      get headers() {
11810        return this[$2].headers;
11811      }
11812      get redirect() {
11813        return this[$2].redirect;
11814      }
11815      get signal() {
11816        return this[$2].signal;
11817      }
11818      get referrer() {
11819        if (this[$2].referrer === "no-referrer") return "";
11820        if (this[$2].referrer === "client") return "about:client";
11821        if (this[$2].referrer) return this[$2].referrer.toString();
11822      }
11823      get referrerPolicy() {
11824        return this[$2].referrerPolicy;
11825      }
11826      set referrerPolicy(o3) {
11827        this[$2].referrerPolicy = ll(o3);
11828      }
11829      clone() {
11830        return new vr2(this);
11831      }
11832      get [Symbol.toStringTag]() {
11833        return "Request";
11834      }
11835    };
11836    n2(vr, "Request");
11837    dt = vr;
11838    Object.defineProperties(dt.prototype, { method: { enumerable: true }, url: { enumerable: true }, headers: { enumerable: true }, redirect: { enumerable: true }, clone: { enumerable: true }, signal: { enumerable: true }, referrer: { enumerable: true }, referrerPolicy: { enumerable: true } });
11839    hl = n2((i) => {
11840      const { parsedURL: o3 } = i[$2], a = new ye(i[$2].headers);
11841      a.has("Accept") || a.set("Accept", "*/*");
11842      let f2 = null;
11843      if (i.body === null && /^(post|put)$/i.test(i.method) && (f2 = "0"), i.body !== null) {
11844        const S = rl(i);
11845        typeof S == "number" && !Number.isNaN(S) && (f2 = String(S));
11846      }
11847      f2 && a.set("Content-Length", f2), i.referrerPolicy === "" && (i.referrerPolicy = sl), i.referrer && i.referrer !== "no-referrer" ? i[$2].referrer = fl(i) : i[$2].referrer = "no-referrer", i[$2].referrer instanceof URL && a.set("Referer", i.referrer), a.has("User-Agent") || a.set("User-Agent", "node-fetch"), i.compress && !a.has("Accept-Encoding") && a.set("Accept-Encoding", "gzip, deflate, br");
11848      let { agent: l } = i;
11849      typeof l == "function" && (l = l(o3));
11850      const p2 = al(o3), h2 = { path: o3.pathname + p2, method: i.method, headers: a[Symbol.for("nodejs.util.inspect.custom")](), insecureHTTPParser: i.insecureHTTPParser, agent: l };
11851      return { parsedURL: o3, options: h2 };
11852    }, "getNodeRequestOptions");
11853    Hn = class Hn2 extends ft {
11854      constructor(o3, a = "aborted") {
11855        super(o3, a);
11856      }
11857    };
11858    n2(Hn, "AbortError");
11859    _r = Hn;
11860    n2(pl, "requireNodeDomexception");
11861    bl = pl();
11862    ml = f(bl);
11863    ({ stat: $n } = import_node_fs4.promises);
11864    yl = n2((i, o3) => vi((0, import_node_fs4.statSync)(i), i, o3), "blobFromSync");
11865    gl = n2((i, o3) => $n(i).then((a) => vi(a, i, o3)), "blobFrom");
11866    _l = n2((i, o3) => $n(i).then((a) => Ei(a, i, o3)), "fileFrom");
11867    Sl = n2((i, o3) => Ei((0, import_node_fs4.statSync)(i), i, o3), "fileFromSync");
11868    vi = n2((i, o3, a = "") => new ut([new Sr({ path: o3, size: i.size, lastModified: i.mtimeMs, start: 0 })], { type: a }), "fromBlob");
11869    Ei = n2((i, o3, a = "") => new qn([new Sr({ path: o3, size: i.size, lastModified: i.mtimeMs, start: 0 })], (0, import_node_path5.basename)(o3), { type: a, lastModified: i.mtimeMs }), "fromFile");
11870    Er = class Er2 {
11871      constructor(o3) {
11872        be(this, He);
11873        be(this, Ve);
11874        X(this, He, o3.path), X(this, Ve, o3.start), this.size = o3.size, this.lastModified = o3.lastModified;
11875      }
11876      slice(o3, a) {
11877        return new Er2({ path: O(this, He), lastModified: this.lastModified, size: a - o3, start: O(this, Ve) + o3 });
11878      }
11879      stream() {
11880        return __asyncGenerator(this, null, function* () {
11881          const { mtimeMs: o3 } = yield new __await($n(O(this, He)));
11882          if (o3 > this.lastModified) throw new ml("The requested file could not be read, typically due to permission problems that have occurred after a reference to a file was acquired.", "NotReadableError");
11883          yield* __yieldStar((0, import_node_fs4.createReadStream)(O(this, He), { start: O(this, Ve), end: O(this, Ve) + this.size - 1 }));
11884        });
11885      }
11886      get [Symbol.toStringTag]() {
11887        return "Blob";
11888      }
11889    };
11890    He = /* @__PURE__ */ new WeakMap(), Ve = /* @__PURE__ */ new WeakMap(), n2(Er, "BlobDataItem");
11891    Sr = Er;
11892    wl = /* @__PURE__ */ new Set(["data:", "http:", "https:"]);
11893    n2(Ai, "fetch$1");
11894    n2(Rl, "fixResponseChunkedTransferBadEnding");
11895    Bi = /* @__PURE__ */ new WeakMap();
11896    Dn = /* @__PURE__ */ new WeakMap();
11897    n2(W, "pd");
11898    n2(ki, "setCancelFlag");
11899    n2(ht, "Event"), ht.prototype = { get type() {
11900      return W(this).event.type;
11901    }, get target() {
11902      return W(this).eventTarget;
11903    }, get currentTarget() {
11904      return W(this).currentTarget;
11905    }, composedPath() {
11906      const i = W(this).currentTarget;
11907      return i == null ? [] : [i];
11908    }, get NONE() {
11909      return 0;
11910    }, get CAPTURING_PHASE() {
11911      return 1;
11912    }, get AT_TARGET() {
11913      return 2;
11914    }, get BUBBLING_PHASE() {
11915      return 3;
11916    }, get eventPhase() {
11917      return W(this).eventPhase;
11918    }, stopPropagation() {
11919      const i = W(this);
11920      i.stopped = true, typeof i.event.stopPropagation == "function" && i.event.stopPropagation();
11921    }, stopImmediatePropagation() {
11922      const i = W(this);
11923      i.stopped = true, i.immediateStopped = true, typeof i.event.stopImmediatePropagation == "function" && i.event.stopImmediatePropagation();
11924    }, get bubbles() {
11925      return !!W(this).event.bubbles;
11926    }, get cancelable() {
11927      return !!W(this).event.cancelable;
11928    }, preventDefault() {
11929      ki(W(this));
11930    }, get defaultPrevented() {
11931      return W(this).canceled;
11932    }, get composed() {
11933      return !!W(this).event.composed;
11934    }, get timeStamp() {
11935      return W(this).timeStamp;
11936    }, get srcElement() {
11937      return W(this).eventTarget;
11938    }, get cancelBubble() {
11939      return W(this).stopped;
11940    }, set cancelBubble(i) {
11941      if (!i) return;
11942      const o3 = W(this);
11943      o3.stopped = true, typeof o3.event.cancelBubble == "boolean" && (o3.event.cancelBubble = true);
11944    }, get returnValue() {
11945      return !W(this).canceled;
11946    }, set returnValue(i) {
11947      i || ki(W(this));
11948    }, initEvent() {
11949    } }, Object.defineProperty(ht.prototype, "constructor", { value: ht, configurable: true, writable: true }), typeof window < "u" && typeof window.Event < "u" && (Object.setPrototypeOf(ht.prototype, window.Event.prototype), Dn.set(window.Event.prototype, ht));
11950    n2(Wi, "defineRedirectDescriptor");
11951    n2(Tl, "defineCallDescriptor");
11952    n2(Cl, "defineWrapper");
11953    n2(qi, "getWrapper");
11954    n2(Pl, "wrapEvent");
11955    n2(vl, "isStopped");
11956    n2(El, "setEventPhase");
11957    n2(Al, "setCurrentTarget");
11958    n2(Oi, "setPassiveListener");
11959    zi = /* @__PURE__ */ new WeakMap();
11960    Ii = 1;
11961    Fi = 2;
11962    wr = 3;
11963    n2(Rr, "isObject");
11964    n2(Ot, "getListeners");
11965    n2(Bl, "defineEventAttributeDescriptor");
11966    n2(ji, "defineEventAttribute");
11967    n2(Li, "defineCustomEventTarget");
11968    n2(Pe, "EventTarget"), Pe.prototype = { addEventListener(i, o3, a) {
11969      if (o3 == null) return;
11970      if (typeof o3 != "function" && !Rr(o3)) throw new TypeError("'listener' should be a function or an object.");
11971      const f2 = Ot(this), l = Rr(a), h2 = (l ? !!a.capture : !!a) ? Ii : Fi, S = { listener: o3, listenerType: h2, passive: l && !!a.passive, once: l && !!a.once, next: null };
11972      let v2 = f2.get(i);
11973      if (v2 === void 0) {
11974        f2.set(i, S);
11975        return;
11976      }
11977      let w2 = null;
11978      for (; v2 != null; ) {
11979        if (v2.listener === o3 && v2.listenerType === h2) return;
11980        w2 = v2, v2 = v2.next;
11981      }
11982      w2.next = S;
11983    }, removeEventListener(i, o3, a) {
11984      if (o3 == null) return;
11985      const f2 = Ot(this), p2 = (Rr(a) ? !!a.capture : !!a) ? Ii : Fi;
11986      let h2 = null, S = f2.get(i);
11987      for (; S != null; ) {
11988        if (S.listener === o3 && S.listenerType === p2) {
11989          h2 !== null ? h2.next = S.next : S.next !== null ? f2.set(i, S.next) : f2.delete(i);
11990          return;
11991        }
11992        h2 = S, S = S.next;
11993      }
11994    }, dispatchEvent(i) {
11995      if (i == null || typeof i.type != "string") throw new TypeError('"event.type" should be a string.');
11996      const o3 = Ot(this), a = i.type;
11997      let f2 = o3.get(a);
11998      if (f2 == null) return true;
11999      const l = Pl(this, i);
12000      let p2 = null;
12001      for (; f2 != null; ) {
12002        if (f2.once ? p2 !== null ? p2.next = f2.next : f2.next !== null ? o3.set(a, f2.next) : o3.delete(a) : p2 = f2, Oi(l, f2.passive ? f2.listener : null), typeof f2.listener == "function") try {
12003          f2.listener.call(this, l);
12004        } catch (h2) {
12005          typeof console < "u" && typeof console.error == "function" && console.error(h2);
12006        }
12007        else f2.listenerType !== wr && typeof f2.listener.handleEvent == "function" && f2.listener.handleEvent(l);
12008        if (vl(l)) break;
12009        f2 = f2.next;
12010      }
12011      return Oi(l, null), El(l, 0), Al(l, null), !l.defaultPrevented;
12012    } }, Object.defineProperty(Pe.prototype, "constructor", { value: Pe, configurable: true, writable: true }), typeof window < "u" && typeof window.EventTarget < "u" && Object.setPrototypeOf(Pe.prototype, window.EventTarget.prototype);
12013    Vn = class Vn2 extends Pe {
12014      constructor() {
12015        throw super(), new TypeError("AbortSignal cannot be constructed directly");
12016      }
12017      get aborted() {
12018        const o3 = Tr.get(this);
12019        if (typeof o3 != "boolean") throw new TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this === null ? "null" : typeof this}`);
12020        return o3;
12021      }
12022    };
12023    n2(Vn, "AbortSignal");
12024    pt = Vn;
12025    ji(pt.prototype, "abort");
12026    n2(kl, "createAbortSignal");
12027    n2(Wl, "abortSignal");
12028    Tr = /* @__PURE__ */ new WeakMap();
12029    Object.defineProperties(pt.prototype, { aborted: { enumerable: true } }), typeof Symbol == "function" && typeof Symbol.toStringTag == "symbol" && Object.defineProperty(pt.prototype, Symbol.toStringTag, { configurable: true, value: "AbortSignal" });
12030    Mn = (gt = class {
12031      constructor() {
12032        $i.set(this, kl());
12033      }
12034      get signal() {
12035        return Di(this);
12036      }
12037      abort() {
12038        Wl(Di(this));
12039      }
12040    }, n2(gt, "AbortController"), gt);
12041    $i = /* @__PURE__ */ new WeakMap();
12042    n2(Di, "getSignal"), Object.defineProperties(Mn.prototype, { signal: { enumerable: true }, abort: { enumerable: true } }), typeof Symbol == "function" && typeof Symbol.toStringTag == "symbol" && Object.defineProperty(Mn.prototype, Symbol.toStringTag, { configurable: true, value: "AbortController" });
12043    ql = Object.defineProperty;
12044    Ol = n2((i, o3) => ql(i, "name", { value: o3, configurable: true }), "e");
12045    Mi = Ai;
12046    Ui();
12047    n2(Ui, "s"), Ol(Ui, "checkNodeEnvironment");
12048  }
12049});
12050
12051// node_modules/minimist/index.js
12052var require_minimist = __commonJS({
12053  "node_modules/minimist/index.js"(exports2, module2) {
12054    "use strict";
12055    function hasKey(obj, keys) {
12056      var o3 = obj;
12057      keys.slice(0, -1).forEach(function(key2) {
12058        o3 = o3[key2] || {};
12059      });
12060      var key = keys[keys.length - 1];
12061      return key in o3;
12062    }
12063    function isNumber(x2) {
12064      if (typeof x2 === "number") {
12065        return true;
12066      }
12067      if (/^0x[0-9a-f]+$/i.test(x2)) {
12068        return true;
12069      }
12070      return /^[-+]?(?:\d+(?:\.\d*)?|\.\d+)(e[-+]?\d+)?$/.test(x2);
12071    }
12072    function isConstructorOrProto(obj, key) {
12073      return key === "constructor" && typeof obj[key] === "function" || key === "__proto__";
12074    }
12075    module2.exports = function(args, opts) {
12076      if (!opts) {
12077        opts = {};
12078      }
12079      var flags = {
12080        bools: {},
12081        strings: {},
12082        unknownFn: null
12083      };
12084      if (typeof opts.unknown === "function") {
12085        flags.unknownFn = opts.unknown;
12086      }
12087      if (typeof opts.boolean === "boolean" && opts.boolean) {
12088        flags.allBools = true;
12089      } else {
12090        [].concat(opts.boolean).filter(Boolean).forEach(function(key2) {
12091          flags.bools[key2] = true;
12092        });
12093      }
12094      var aliases = {};
12095      function aliasIsBoolean(key2) {
12096        return aliases[key2].some(function(x2) {
12097          return flags.bools[x2];
12098        });
12099      }
12100      Object.keys(opts.alias || {}).forEach(function(key2) {
12101        aliases[key2] = [].concat(opts.alias[key2]);
12102        aliases[key2].forEach(function(x2) {
12103          aliases[x2] = [key2].concat(aliases[key2].filter(function(y) {
12104            return x2 !== y;
12105          }));
12106        });
12107      });
12108      [].concat(opts.string).filter(Boolean).forEach(function(key2) {
12109        flags.strings[key2] = true;
12110        if (aliases[key2]) {
12111          [].concat(aliases[key2]).forEach(function(k2) {
12112            flags.strings[k2] = true;
12113          });
12114        }
12115      });
12116      var defaults = opts.default || {};
12117      var argv = { _: [] };
12118      function argDefined(key2, arg2) {
12119        return flags.allBools && /^--[^=]+$/.test(arg2) || flags.strings[key2] || flags.bools[key2] || aliases[key2];
12120      }
12121      function setKey(obj, keys, value2) {
12122        var o3 = obj;
12123        for (var i2 = 0; i2 < keys.length - 1; i2++) {
12124          var key2 = keys[i2];
12125          if (isConstructorOrProto(o3, key2)) {
12126            return;
12127          }
12128          if (o3[key2] === void 0) {
12129            o3[key2] = {};
12130          }
12131          if (o3[key2] === Object.prototype || o3[key2] === Number.prototype || o3[key2] === String.prototype) {
12132            o3[key2] = {};
12133          }
12134          if (o3[key2] === Array.prototype) {
12135            o3[key2] = [];
12136          }
12137          o3 = o3[key2];
12138        }
12139        var lastKey = keys[keys.length - 1];
12140        if (isConstructorOrProto(o3, lastKey)) {
12141          return;
12142        }
12143        if (o3 === Object.prototype || o3 === Number.prototype || o3 === String.prototype) {
12144          o3 = {};
12145        }
12146        if (o3 === Array.prototype) {
12147          o3 = [];
12148        }
12149        if (o3[lastKey] === void 0 || flags.bools[lastKey] || typeof o3[lastKey] === "boolean") {
12150          o3[lastKey] = value2;
12151        } else if (Array.isArray(o3[lastKey])) {
12152          o3[lastKey].push(value2);
12153        } else {
12154          o3[lastKey] = [o3[lastKey], value2];
12155        }
12156      }
12157      function setArg(key2, val, arg2) {
12158        if (arg2 && flags.unknownFn && !argDefined(key2, arg2)) {
12159          if (flags.unknownFn(arg2) === false) {
12160            return;
12161          }
12162        }
12163        var value2 = !flags.strings[key2] && isNumber(val) ? Number(val) : val;
12164        setKey(argv, key2.split("."), value2);
12165        (aliases[key2] || []).forEach(function(x2) {
12166          setKey(argv, x2.split("."), value2);
12167        });
12168      }
12169      Object.keys(flags.bools).forEach(function(key2) {
12170        setArg(key2, defaults[key2] === void 0 ? false : defaults[key2]);
12171      });
12172      var notFlags = [];
12173      if (args.indexOf("--") !== -1) {
12174        notFlags = args.slice(args.indexOf("--") + 1);
12175        args = args.slice(0, args.indexOf("--"));
12176      }
12177      for (var i = 0; i < args.length; i++) {
12178        var arg = args[i];
12179        var key;
12180        var next;
12181        if (/^--.+=/.test(arg)) {
12182          var m2 = arg.match(/^--([^=]+)=([\s\S]*)$/);
12183          key = m2[1];
12184          var value = m2[2];
12185          if (flags.bools[key]) {
12186            value = value !== "false";
12187          }
12188          setArg(key, value, arg);
12189        } else if (/^--no-.+/.test(arg)) {
12190          key = arg.match(/^--no-(.+)/)[1];
12191          setArg(key, false, arg);
12192        } else if (/^--.+/.test(arg)) {
12193          key = arg.match(/^--(.+)/)[1];
12194          next = args[i + 1];
12195          if (next !== void 0 && !/^(-|--)[^-]/.test(next) && !flags.bools[key] && !flags.allBools && (aliases[key] ? !aliasIsBoolean(key) : true)) {
12196            setArg(key, next, arg);
12197            i += 1;
12198          } else if (/^(true|false)$/.test(next)) {
12199            setArg(key, next === "true", arg);
12200            i += 1;
12201          } else {
12202            setArg(key, flags.strings[key] ? "" : true, arg);
12203          }
12204        } else if (/^-[^-]+/.test(arg)) {
12205          var letters = arg.slice(1, -1).split("");
12206          var broken = false;
12207          for (var j = 0; j < letters.length; j++) {
12208            next = arg.slice(j + 2);
12209            if (next === "-") {
12210              setArg(letters[j], next, arg);
12211              continue;
12212            }
12213            if (/[A-Za-z]/.test(letters[j]) && next[0] === "=") {
12214              setArg(letters[j], next.slice(1), arg);
12215              broken = true;
12216              break;
12217            }
12218            if (/[A-Za-z]/.test(letters[j]) && /-?\d+(\.\d*)?(e-?\d+)?$/.test(next)) {
12219              setArg(letters[j], next, arg);
12220              broken = true;
12221              break;
12222            }
12223            if (letters[j + 1] && letters[j + 1].match(/\W/)) {
12224              setArg(letters[j], arg.slice(j + 2), arg);
12225              broken = true;
12226              break;
12227            } else {
12228              setArg(letters[j], flags.strings[letters[j]] ? "" : true, arg);
12229            }
12230          }
12231          key = arg.slice(-1)[0];
12232          if (!broken && key !== "-") {
12233            if (args[i + 1] && !/^(-|--)[^-]/.test(args[i + 1]) && !flags.bools[key] && (aliases[key] ? !aliasIsBoolean(key) : true)) {
12234              setArg(key, args[i + 1], arg);
12235              i += 1;
12236            } else if (args[i + 1] && /^(true|false)$/.test(args[i + 1])) {
12237              setArg(key, args[i + 1] === "true", arg);
12238              i += 1;
12239            } else {
12240              setArg(key, flags.strings[key] ? "" : true, arg);
12241            }
12242          }
12243        } else {
12244          if (!flags.unknownFn || flags.unknownFn(arg) !== false) {
12245            argv._.push(flags.strings._ || !isNumber(arg) ? arg : Number(arg));
12246          }
12247          if (opts.stopEarly) {
12248            argv._.push.apply(argv._, args.slice(i + 1));
12249            break;
12250          }
12251        }
12252      }
12253      Object.keys(defaults).forEach(function(k2) {
12254        if (!hasKey(argv, k2.split("."))) {
12255          setKey(argv, k2.split("."), defaults[k2]);
12256          (aliases[k2] || []).forEach(function(x2) {
12257            setKey(argv, x2.split("."), defaults[k2]);
12258          });
12259        }
12260      });
12261      if (opts["--"]) {
12262        argv["--"] = notFlags.slice();
12263      } else {
12264        notFlags.forEach(function(k2) {
12265          argv._.push(k2);
12266        });
12267      }
12268      return argv;
12269    };
12270  }
12271});
12272
12273// src/vendor-extra.ts
12274var vendor_extra_exports = {};
12275__export(vendor_extra_exports, {
12276  MAML: () => MAML,
12277  YAML: () => YAML,
12278  createRequire: () => createRequire,
12279  depseek: () => depseek,
12280  dotenv: () => dotenv,
12281  fs: () => fs5,
12282  glob: () => glob,
12283  minimist: () => minimist,
12284  nodeFetch: () => nodeFetch
12285});
12286module.exports = __toCommonJS(vendor_extra_exports);
12287
12288// node_modules/globby/index.js
12289var import_node_process2 = __toESM(require("process"), 1);
12290var import_node_fs3 = __toESM(require("fs"), 1);
12291var import_node_path4 = __toESM(require("path"), 1);
12292var import_node_stream2 = require("stream");
12293
12294// node_modules/@sindresorhus/merge-streams/index.js
12295var import_node_events = require("events");
12296var import_node_stream = require("stream");
12297var import_promises = require("stream").promises;
12298function mergeStreams(streams) {
12299  if (!Array.isArray(streams)) {
12300    throw new TypeError(`Expected an array, got \`${typeof streams}\`.`);
12301  }
12302  for (const stream of streams) {
12303    validateStream(stream);
12304  }
12305  const objectMode = streams.some(({ readableObjectMode }) => readableObjectMode);
12306  const highWaterMark = getHighWaterMark(streams, objectMode);
12307  const passThroughStream = new MergedStream({
12308    objectMode,
12309    writableHighWaterMark: highWaterMark,
12310    readableHighWaterMark: highWaterMark
12311  });
12312  for (const stream of streams) {
12313    passThroughStream.add(stream);
12314  }
12315  return passThroughStream;
12316}
12317var getHighWaterMark = (streams, objectMode) => {
12318  if (streams.length === 0) {
12319    return (0, import_node_stream.getDefaultHighWaterMark)(objectMode);
12320  }
12321  const highWaterMarks = streams.filter(({ readableObjectMode }) => readableObjectMode === objectMode).map(({ readableHighWaterMark }) => readableHighWaterMark);
12322  return Math.max(...highWaterMarks);
12323};
12324var _streams, _ended, _aborted, _onFinished, _unpipeEvent, _streamPromises;
12325var MergedStream = class extends import_node_stream.PassThrough {
12326  constructor() {
12327    super(...arguments);
12328    __privateAdd(this, _streams, /* @__PURE__ */ new Set([]));
12329    __privateAdd(this, _ended, /* @__PURE__ */ new Set([]));
12330    __privateAdd(this, _aborted, /* @__PURE__ */ new Set([]));
12331    __privateAdd(this, _onFinished);
12332    __privateAdd(this, _unpipeEvent, Symbol("unpipe"));
12333    __privateAdd(this, _streamPromises, /* @__PURE__ */ new WeakMap());
12334  }
12335  add(stream) {
12336    var _a2;
12337    validateStream(stream);
12338    if (__privateGet(this, _streams).has(stream)) {
12339      return;
12340    }
12341    __privateGet(this, _streams).add(stream);
12342    (_a2 = __privateGet(this, _onFinished)) != null ? _a2 : __privateSet(this, _onFinished, onMergedStreamFinished(this, __privateGet(this, _streams), __privateGet(this, _unpipeEvent)));
12343    const streamPromise = endWhenStreamsDone({
12344      passThroughStream: this,
12345      stream,
12346      streams: __privateGet(this, _streams),
12347      ended: __privateGet(this, _ended),
12348      aborted: __privateGet(this, _aborted),
12349      onFinished: __privateGet(this, _onFinished),
12350      unpipeEvent: __privateGet(this, _unpipeEvent)
12351    });
12352    __privateGet(this, _streamPromises).set(stream, streamPromise);
12353    stream.pipe(this, { end: false });
12354  }
12355  remove(stream) {
12356    return __async(this, null, function* () {
12357      validateStream(stream);
12358      if (!__privateGet(this, _streams).has(stream)) {
12359        return false;
12360      }
12361      const streamPromise = __privateGet(this, _streamPromises).get(stream);
12362      if (streamPromise === void 0) {
12363        return false;
12364      }
12365      __privateGet(this, _streamPromises).delete(stream);
12366      stream.unpipe(this);
12367      yield streamPromise;
12368      return true;
12369    });
12370  }
12371};
12372_streams = new WeakMap();
12373_ended = new WeakMap();
12374_aborted = new WeakMap();
12375_onFinished = new WeakMap();
12376_unpipeEvent = new WeakMap();
12377_streamPromises = new WeakMap();
12378var onMergedStreamFinished = (passThroughStream, streams, unpipeEvent) => __async(null, null, function* () {
12379  updateMaxListeners(passThroughStream, PASSTHROUGH_LISTENERS_COUNT);
12380  const controller = new AbortController();
12381  try {
12382    yield Promise.race([
12383      onMergedStreamEnd(passThroughStream, controller),
12384      onInputStreamsUnpipe(passThroughStream, streams, unpipeEvent, controller)
12385    ]);
12386  } finally {
12387    controller.abort();
12388    updateMaxListeners(passThroughStream, -PASSTHROUGH_LISTENERS_COUNT);
12389  }
12390});
12391var onMergedStreamEnd = (_0, _1) => __async(null, [_0, _1], function* (passThroughStream, { signal }) {
12392  try {
12393    yield (0, import_promises.finished)(passThroughStream, { signal, cleanup: true });
12394  } catch (error) {
12395    errorOrAbortStream(passThroughStream, error);
12396    throw error;
12397  }
12398});
12399var onInputStreamsUnpipe = (_0, _1, _2, _3) => __async(null, [_0, _1, _2, _3], function* (passThroughStream, streams, unpipeEvent, { signal }) {
12400  try {
12401    for (var iter = __forAwait((0, import_node_events.on)(passThroughStream, "unpipe", { signal })), more, temp, error; more = !(temp = yield iter.next()).done; more = false) {
12402      const [unpipedStream] = temp.value;
12403      if (streams.has(unpipedStream)) {
12404        unpipedStream.emit(unpipeEvent);
12405      }
12406    }
12407  } catch (temp) {
12408    error = [temp];
12409  } finally {
12410    try {
12411      more && (temp = iter.return) && (yield temp.call(iter));
12412    } finally {
12413      if (error)
12414        throw error[0];
12415    }
12416  }
12417});
12418var validateStream = (stream) => {
12419  if (typeof (stream == null ? void 0 : stream.pipe) !== "function") {
12420    throw new TypeError(`Expected a readable stream, got: \`${typeof stream}\`.`);
12421  }
12422};
12423var endWhenStreamsDone = (_0) => __async(null, [_0], function* ({ passThroughStream, stream, streams, ended, aborted, onFinished, unpipeEvent }) {
12424  updateMaxListeners(passThroughStream, PASSTHROUGH_LISTENERS_PER_STREAM);
12425  const controller = new AbortController();
12426  try {
12427    yield Promise.race([
12428      afterMergedStreamFinished(onFinished, stream, controller),
12429      onInputStreamEnd({
12430        passThroughStream,
12431        stream,
12432        streams,
12433        ended,
12434        aborted,
12435        controller
12436      }),
12437      onInputStreamUnpipe({
12438        stream,
12439        streams,
12440        ended,
12441        aborted,
12442        unpipeEvent,
12443        controller
12444      })
12445    ]);
12446  } finally {
12447    controller.abort();
12448    updateMaxListeners(passThroughStream, -PASSTHROUGH_LISTENERS_PER_STREAM);
12449  }
12450  if (streams.size > 0 && streams.size === ended.size + aborted.size) {
12451    if (ended.size === 0 && aborted.size > 0) {
12452      abortStream(passThroughStream);
12453    } else {
12454      endStream(passThroughStream);
12455    }
12456  }
12457});
12458var afterMergedStreamFinished = (_0, _1, _2) => __async(null, [_0, _1, _2], function* (onFinished, stream, { signal }) {
12459  try {
12460    yield onFinished;
12461    if (!signal.aborted) {
12462      abortStream(stream);
12463    }
12464  } catch (error) {
12465    if (!signal.aborted) {
12466      errorOrAbortStream(stream, error);
12467    }
12468  }
12469});
12470var onInputStreamEnd = (_0) => __async(null, [_0], function* ({ passThroughStream, stream, streams, ended, aborted, controller: { signal } }) {
12471  try {
12472    yield (0, import_promises.finished)(stream, {
12473      signal,
12474      cleanup: true,
12475      readable: true,
12476      writable: false
12477    });
12478    if (streams.has(stream)) {
12479      ended.add(stream);
12480    }
12481  } catch (error) {
12482    if (signal.aborted || !streams.has(stream)) {
12483      return;
12484    }
12485    if (isAbortError(error)) {
12486      aborted.add(stream);
12487    } else {
12488      errorStream(passThroughStream, error);
12489    }
12490  }
12491});
12492var onInputStreamUnpipe = (_0) => __async(null, [_0], function* ({ stream, streams, ended, aborted, unpipeEvent, controller: { signal } }) {
12493  yield (0, import_node_events.once)(stream, unpipeEvent, { signal });
12494  if (!stream.readable) {
12495    return (0, import_node_events.once)(signal, "abort", { signal });
12496  }
12497  streams.delete(stream);
12498  ended.delete(stream);
12499  aborted.delete(stream);
12500});
12501var endStream = (stream) => {
12502  if (stream.writable) {
12503    stream.end();
12504  }
12505};
12506var errorOrAbortStream = (stream, error) => {
12507  if (isAbortError(error)) {
12508    abortStream(stream);
12509  } else {
12510    errorStream(stream, error);
12511  }
12512};
12513var isAbortError = (error) => (error == null ? void 0 : error.code) === "ERR_STREAM_PREMATURE_CLOSE";
12514var abortStream = (stream) => {
12515  if (stream.readable || stream.writable) {
12516    stream.destroy();
12517  }
12518};
12519var errorStream = (stream, error) => {
12520  if (!stream.destroyed) {
12521    stream.once("error", noop);
12522    stream.destroy(error);
12523  }
12524};
12525var noop = () => {
12526};
12527var updateMaxListeners = (passThroughStream, increment) => {
12528  const maxListeners = passThroughStream.getMaxListeners();
12529  if (maxListeners !== 0 && maxListeners !== Number.POSITIVE_INFINITY) {
12530    passThroughStream.setMaxListeners(maxListeners + increment);
12531  }
12532};
12533var PASSTHROUGH_LISTENERS_COUNT = 2;
12534var PASSTHROUGH_LISTENERS_PER_STREAM = 1;
12535
12536// node_modules/globby/index.js
12537var import_fast_glob2 = __toESM(require_out4(), 1);
12538
12539// node_modules/unicorn-magic/node.js
12540var import_node_util = require("util");
12541var import_node_child_process = require("child_process");
12542var import_node_url = require("url");
12543var execFileOriginal = (0, import_node_util.promisify)(import_node_child_process.execFile);
12544function toPath(urlOrPath) {
12545  return urlOrPath instanceof URL ? (0, import_node_url.fileURLToPath)(urlOrPath) : urlOrPath;
12546}
12547var TEN_MEGABYTES_IN_BYTES = 10 * 1024 * 1024;
12548
12549// node_modules/globby/ignore.js
12550var import_node_process = __toESM(require("process"), 1);
12551var import_node_fs2 = __toESM(require("fs"), 1);
12552var import_promises2 = __toESM(require("fs").promises, 1);
12553var import_node_path3 = __toESM(require("path"), 1);
12554var import_fast_glob = __toESM(require_out4(), 1);
12555var import_ignore = __toESM(require_ignore(), 1);
12556
12557// node_modules/is-path-inside/index.js
12558var import_node_path = __toESM(require("path"), 1);
12559function isPathInside(childPath, parentPath) {
12560  const relation = import_node_path.default.relative(parentPath, childPath);
12561  return Boolean(
12562    relation && relation !== ".." && !relation.startsWith(`..${import_node_path.default.sep}`) && relation !== import_node_path.default.resolve(childPath)
12563  );
12564}
12565
12566// node_modules/slash/index.js
12567function slash(path5) {
12568  const isExtendedLengthPath = path5.startsWith("\\\\?\\");
12569  if (isExtendedLengthPath) {
12570    return path5;
12571  }
12572  return path5.replace(/\\/g, "/");
12573}
12574
12575// node_modules/globby/utilities.js
12576var import_node_fs = __toESM(require("fs"), 1);
12577var import_node_path2 = __toESM(require("path"), 1);
12578var import_node_util2 = require("util");
12579var isNegativePattern = (pattern) => pattern[0] === "!";
12580var bindFsMethod = (object, methodName) => {
12581  const method = object == null ? void 0 : object[methodName];
12582  return typeof method === "function" ? method.bind(object) : void 0;
12583};
12584var promisifyFsMethod = (object, methodName) => {
12585  const method = object == null ? void 0 : object[methodName];
12586  if (typeof method !== "function") {
12587    return void 0;
12588  }
12589  return (0, import_node_util2.promisify)(method.bind(object));
12590};
12591var normalizeDirectoryPatternForFastGlob = (pattern) => {
12592  if (!pattern.endsWith("/")) {
12593    return pattern;
12594  }
12595  const trimmedPattern = pattern.replace(/\/+$/u, "");
12596  if (!trimmedPattern) {
12597    return "/**";
12598  }
12599  if (trimmedPattern === "**") {
12600    return "**/**";
12601  }
12602  const hasLeadingSlash = trimmedPattern.startsWith("/");
12603  const patternBody = hasLeadingSlash ? trimmedPattern.slice(1) : trimmedPattern;
12604  const hasInnerSlash = patternBody.includes("/");
12605  const needsRecursivePrefix = !hasLeadingSlash && !hasInnerSlash && !trimmedPattern.startsWith("**/");
12606  const recursivePrefix = needsRecursivePrefix ? "**/" : "";
12607  return `${recursivePrefix}${trimmedPattern}/**`;
12608};
12609var getParentDirectoryPrefix = (pattern) => {
12610  const normalizedPattern = isNegativePattern(pattern) ? pattern.slice(1) : pattern;
12611  const match = normalizedPattern.match(/^(\.\.\/)+/);
12612  return match ? match[0] : "";
12613};
12614var adjustIgnorePatternsForParentDirectories = (patterns, ignorePatterns) => {
12615  if (patterns.length === 0 || ignorePatterns.length === 0) {
12616    return ignorePatterns;
12617  }
12618  const parentPrefixes = patterns.map((pattern) => getParentDirectoryPrefix(pattern));
12619  const firstPrefix = parentPrefixes[0];
12620  if (!firstPrefix) {
12621    return ignorePatterns;
12622  }
12623  const allSamePrefix = parentPrefixes.every((prefix) => prefix === firstPrefix);
12624  if (!allSamePrefix) {
12625    return ignorePatterns;
12626  }
12627  return ignorePatterns.map((pattern) => {
12628    if (pattern.startsWith("**/") && !pattern.startsWith("../")) {
12629      return firstPrefix + pattern;
12630    }
12631    return pattern;
12632  });
12633};
12634var getAsyncStatMethod = (fsImplementation) => {
12635  var _a2;
12636  return (_a2 = bindFsMethod(fsImplementation == null ? void 0 : fsImplementation.promises, "stat")) != null ? _a2 : bindFsMethod(import_node_fs.default.promises, "stat");
12637};
12638var getStatSyncMethod = (fsImplementation) => {
12639  if (fsImplementation) {
12640    return bindFsMethod(fsImplementation, "statSync");
12641  }
12642  return bindFsMethod(import_node_fs.default, "statSync");
12643};
12644var pathHasGitDirectory = (stats) => {
12645  var _a2, _b2;
12646  return Boolean(((_a2 = stats == null ? void 0 : stats.isDirectory) == null ? void 0 : _a2.call(stats)) || ((_b2 = stats == null ? void 0 : stats.isFile) == null ? void 0 : _b2.call(stats)));
12647};
12648var buildPathChain = (startPath, rootPath) => {
12649  const chain = [];
12650  let currentPath = startPath;
12651  chain.push(currentPath);
12652  while (currentPath !== rootPath) {
12653    const parentPath = import_node_path2.default.dirname(currentPath);
12654    if (parentPath === currentPath) {
12655      break;
12656    }
12657    currentPath = parentPath;
12658    chain.push(currentPath);
12659  }
12660  return chain;
12661};
12662var findGitRootInChain = (paths, statMethod) => __async(null, null, function* () {
12663  for (const directory of paths) {
12664    const gitPath = import_node_path2.default.join(directory, ".git");
12665    try {
12666      const stats = yield statMethod(gitPath);
12667      if (pathHasGitDirectory(stats)) {
12668        return directory;
12669      }
12670    } catch (e) {
12671    }
12672  }
12673  return void 0;
12674});
12675var findGitRootSyncUncached = (cwd, fsImplementation) => {
12676  const statSyncMethod = getStatSyncMethod(fsImplementation);
12677  if (!statSyncMethod) {
12678    return void 0;
12679  }
12680  const currentPath = import_node_path2.default.resolve(cwd);
12681  const { root } = import_node_path2.default.parse(currentPath);
12682  const chain = buildPathChain(currentPath, root);
12683  for (const directory of chain) {
12684    const gitPath = import_node_path2.default.join(directory, ".git");
12685    try {
12686      const stats = statSyncMethod(gitPath);
12687      if (pathHasGitDirectory(stats)) {
12688        return directory;
12689      }
12690    } catch (e) {
12691    }
12692  }
12693  return void 0;
12694};
12695var findGitRootSync = (cwd, fsImplementation) => {
12696  if (typeof cwd !== "string") {
12697    throw new TypeError("cwd must be a string");
12698  }
12699  return findGitRootSyncUncached(cwd, fsImplementation);
12700};
12701var findGitRootAsyncUncached = (cwd, fsImplementation) => __async(null, null, function* () {
12702  const statMethod = getAsyncStatMethod(fsImplementation);
12703  if (!statMethod) {
12704    return findGitRootSync(cwd, fsImplementation);
12705  }
12706  const currentPath = import_node_path2.default.resolve(cwd);
12707  const { root } = import_node_path2.default.parse(currentPath);
12708  const chain = buildPathChain(currentPath, root);
12709  return findGitRootInChain(chain, statMethod);
12710});
12711var findGitRoot = (cwd, fsImplementation) => __async(null, null, function* () {
12712  if (typeof cwd !== "string") {
12713    throw new TypeError("cwd must be a string");
12714  }
12715  return findGitRootAsyncUncached(cwd, fsImplementation);
12716});
12717var isWithinGitRoot = (gitRoot, cwd) => {
12718  const resolvedGitRoot = import_node_path2.default.resolve(gitRoot);
12719  const resolvedCwd = import_node_path2.default.resolve(cwd);
12720  return resolvedCwd === resolvedGitRoot || isPathInside(resolvedCwd, resolvedGitRoot);
12721};
12722var getParentGitignorePaths = (gitRoot, cwd) => {
12723  if (gitRoot && typeof gitRoot !== "string") {
12724    throw new TypeError("gitRoot must be a string or undefined");
12725  }
12726  if (typeof cwd !== "string") {
12727    throw new TypeError("cwd must be a string");
12728  }
12729  if (!gitRoot) {
12730    return [];
12731  }
12732  if (!isWithinGitRoot(gitRoot, cwd)) {
12733    return [];
12734  }
12735  const chain = buildPathChain(import_node_path2.default.resolve(cwd), import_node_path2.default.resolve(gitRoot));
12736  return [...chain].reverse().map((directory) => import_node_path2.default.join(directory, ".gitignore"));
12737};
12738var convertPatternsForFastGlob = (patterns, usingGitRoot, normalizeDirectoryPatternForFastGlob2) => {
12739  if (usingGitRoot) {
12740    return [];
12741  }
12742  const result = [];
12743  let hasNegations = false;
12744  for (const pattern of patterns) {
12745    if (isNegativePattern(pattern)) {
12746      hasNegations = true;
12747      break;
12748    }
12749    result.push(normalizeDirectoryPatternForFastGlob2(pattern));
12750  }
12751  return hasNegations ? [] : result;
12752};
12753
12754// node_modules/globby/ignore.js
12755var defaultIgnoredDirectories = [
12756  "**/node_modules",
12757  "**/flow-typed",
12758  "**/coverage",
12759  "**/.git"
12760];
12761var ignoreFilesGlobOptions = {
12762  absolute: true,
12763  dot: true
12764};
12765var GITIGNORE_FILES_PATTERN = "**/.gitignore";
12766var getReadFileMethod = (fsImplementation) => {
12767  var _a2, _b2;
12768  return (_b2 = (_a2 = bindFsMethod(fsImplementation == null ? void 0 : fsImplementation.promises, "readFile")) != null ? _a2 : bindFsMethod(import_promises2.default, "readFile")) != null ? _b2 : promisifyFsMethod(fsImplementation, "readFile");
12769};
12770var getReadFileSyncMethod = (fsImplementation) => {
12771  var _a2;
12772  return (_a2 = bindFsMethod(fsImplementation, "readFileSync")) != null ? _a2 : bindFsMethod(import_node_fs2.default, "readFileSync");
12773};
12774var shouldSkipIgnoreFileError = (error, suppressErrors) => {
12775  if (!error) {
12776    return Boolean(suppressErrors);
12777  }
12778  if (error.code === "ENOENT" || error.code === "ENOTDIR") {
12779    return true;
12780  }
12781  return Boolean(suppressErrors);
12782};
12783var createIgnoreFileReadError = (filePath, error) => {
12784  if (error instanceof Error) {
12785    error.message = `Failed to read ignore file at ${filePath}: ${error.message}`;
12786    return error;
12787  }
12788  return new Error(`Failed to read ignore file at ${filePath}: ${String(error)}`);
12789};
12790var processIgnoreFileCore = (filePath, readMethod, suppressErrors) => {
12791  try {
12792    const content = readMethod(filePath, "utf8");
12793    return { filePath, content };
12794  } catch (error) {
12795    if (shouldSkipIgnoreFileError(error, suppressErrors)) {
12796      return void 0;
12797    }
12798    throw createIgnoreFileReadError(filePath, error);
12799  }
12800};
12801var readIgnoreFilesSafely = (paths, readFileMethod, suppressErrors) => __async(null, null, function* () {
12802  const fileResults = yield Promise.all(paths.map((filePath) => __async(null, null, function* () {
12803    try {
12804      const content = yield readFileMethod(filePath, "utf8");
12805      return { filePath, content };
12806    } catch (error) {
12807      if (shouldSkipIgnoreFileError(error, suppressErrors)) {
12808        return void 0;
12809      }
12810      throw createIgnoreFileReadError(filePath, error);
12811    }
12812  })));
12813  return fileResults.filter(Boolean);
12814});
12815var readIgnoreFilesSafelySync = (paths, readFileSyncMethod, suppressErrors) => paths.map((filePath) => processIgnoreFileCore(filePath, readFileSyncMethod, suppressErrors)).filter(Boolean);
12816var dedupePaths = (paths) => {
12817  const seen = /* @__PURE__ */ new Set();
12818  return paths.filter((filePath) => {
12819    if (seen.has(filePath)) {
12820      return false;
12821    }
12822    seen.add(filePath);
12823    return true;
12824  });
12825};
12826var globIgnoreFiles = (globFunction, patterns, normalizedOptions) => globFunction(patterns, __spreadValues(__spreadValues({}, normalizedOptions), ignoreFilesGlobOptions));
12827var getParentIgnorePaths = (gitRoot, normalizedOptions) => gitRoot ? getParentGitignorePaths(gitRoot, normalizedOptions.cwd) : [];
12828var combineIgnoreFilePaths = (gitRoot, normalizedOptions, childPaths) => dedupePaths([
12829  ...getParentIgnorePaths(gitRoot, normalizedOptions),
12830  ...childPaths
12831]);
12832var buildIgnoreResult = (files, normalizedOptions, gitRoot) => {
12833  const baseDir = gitRoot || normalizedOptions.cwd;
12834  const patterns = getPatternsFromIgnoreFiles(files, baseDir);
12835  return {
12836    patterns,
12837    predicate: createIgnorePredicate(patterns, normalizedOptions.cwd, baseDir),
12838    usingGitRoot: Boolean(gitRoot && gitRoot !== normalizedOptions.cwd)
12839  };
12840};
12841var applyBaseToPattern = (pattern, base) => {
12842  if (!base) {
12843    return pattern;
12844  }
12845  const isNegative = isNegativePattern(pattern);
12846  const cleanPattern = isNegative ? pattern.slice(1) : pattern;
12847  const slashIndex = cleanPattern.indexOf("/");
12848  const hasNonTrailingSlash = slashIndex !== -1 && slashIndex !== cleanPattern.length - 1;
12849  let result;
12850  if (!hasNonTrailingSlash) {
12851    result = import_node_path3.default.posix.join(base, "**", cleanPattern);
12852  } else if (cleanPattern.startsWith("/")) {
12853    result = import_node_path3.default.posix.join(base, cleanPattern.slice(1));
12854  } else {
12855    result = import_node_path3.default.posix.join(base, cleanPattern);
12856  }
12857  return isNegative ? "!" + result : result;
12858};
12859var parseIgnoreFile = (file, cwd) => {
12860  const base = slash(import_node_path3.default.relative(cwd, import_node_path3.default.dirname(file.filePath)));
12861  return file.content.split(/\r?\n/).filter((line) => line && !line.startsWith("#")).map((pattern) => applyBaseToPattern(pattern, base));
12862};
12863var toRelativePath = (fileOrDirectory, cwd) => {
12864  if (import_node_path3.default.isAbsolute(fileOrDirectory)) {
12865    const relativePath = import_node_path3.default.relative(cwd, fileOrDirectory);
12866    if (relativePath && !isPathInside(fileOrDirectory, cwd)) {
12867      return void 0;
12868    }
12869    return relativePath;
12870  }
12871  if (fileOrDirectory.startsWith("./")) {
12872    return fileOrDirectory.slice(2);
12873  }
12874  if (fileOrDirectory.startsWith("../")) {
12875    return void 0;
12876  }
12877  return fileOrDirectory;
12878};
12879var createIgnorePredicate = (patterns, cwd, baseDir) => {
12880  const ignores = (0, import_ignore.default)().add(patterns);
12881  const resolvedCwd = import_node_path3.default.normalize(import_node_path3.default.resolve(cwd));
12882  const resolvedBaseDir = import_node_path3.default.normalize(import_node_path3.default.resolve(baseDir));
12883  return (fileOrDirectory) => {
12884    fileOrDirectory = toPath(fileOrDirectory);
12885    const normalizedPath = import_node_path3.default.normalize(import_node_path3.default.resolve(fileOrDirectory));
12886    if (normalizedPath === resolvedCwd) {
12887      return false;
12888    }
12889    const relativePath = toRelativePath(fileOrDirectory, resolvedBaseDir);
12890    if (relativePath === void 0) {
12891      return false;
12892    }
12893    return relativePath ? ignores.ignores(slash(relativePath)) : false;
12894  };
12895};
12896var normalizeOptions = (options = {}) => {
12897  var _a2, _b2, _c, _d;
12898  const ignoreOption = options.ignore ? Array.isArray(options.ignore) ? options.ignore : [options.ignore] : [];
12899  const cwd = (_a2 = toPath(options.cwd)) != null ? _a2 : import_node_process.default.cwd();
12900  const deep = typeof options.deep === "number" ? Math.max(0, options.deep) + 1 : Number.POSITIVE_INFINITY;
12901  return {
12902    cwd,
12903    suppressErrors: (_b2 = options.suppressErrors) != null ? _b2 : false,
12904    deep,
12905    ignore: [...ignoreOption, ...defaultIgnoredDirectories],
12906    followSymbolicLinks: (_c = options.followSymbolicLinks) != null ? _c : true,
12907    concurrency: options.concurrency,
12908    throwErrorOnBrokenSymbolicLink: (_d = options.throwErrorOnBrokenSymbolicLink) != null ? _d : false,
12909    fs: options.fs
12910  };
12911};
12912var collectIgnoreFileArtifactsAsync = (patterns, options, includeParentIgnoreFiles) => __async(null, null, function* () {
12913  const normalizedOptions = normalizeOptions(options);
12914  const childPaths = yield globIgnoreFiles(import_fast_glob.default, patterns, normalizedOptions);
12915  const gitRoot = includeParentIgnoreFiles ? yield findGitRoot(normalizedOptions.cwd, normalizedOptions.fs) : void 0;
12916  const allPaths = combineIgnoreFilePaths(gitRoot, normalizedOptions, childPaths);
12917  const readFileMethod = getReadFileMethod(normalizedOptions.fs);
12918  const files = yield readIgnoreFilesSafely(allPaths, readFileMethod, normalizedOptions.suppressErrors);
12919  return { files, normalizedOptions, gitRoot };
12920});
12921var collectIgnoreFileArtifactsSync = (patterns, options, includeParentIgnoreFiles) => {
12922  const normalizedOptions = normalizeOptions(options);
12923  const childPaths = globIgnoreFiles(import_fast_glob.default.sync, patterns, normalizedOptions);
12924  const gitRoot = includeParentIgnoreFiles ? findGitRootSync(normalizedOptions.cwd, normalizedOptions.fs) : void 0;
12925  const allPaths = combineIgnoreFilePaths(gitRoot, normalizedOptions, childPaths);
12926  const readFileSyncMethod = getReadFileSyncMethod(normalizedOptions.fs);
12927  const files = readIgnoreFilesSafelySync(allPaths, readFileSyncMethod, normalizedOptions.suppressErrors);
12928  return { files, normalizedOptions, gitRoot };
12929};
12930var isIgnoredByIgnoreFiles = (patterns, options) => __async(null, null, function* () {
12931  const { files, normalizedOptions, gitRoot } = yield collectIgnoreFileArtifactsAsync(patterns, options, false);
12932  return buildIgnoreResult(files, normalizedOptions, gitRoot).predicate;
12933});
12934var isIgnoredByIgnoreFilesSync = (patterns, options) => {
12935  const { files, normalizedOptions, gitRoot } = collectIgnoreFileArtifactsSync(patterns, options, false);
12936  return buildIgnoreResult(files, normalizedOptions, gitRoot).predicate;
12937};
12938var getPatternsFromIgnoreFiles = (files, baseDir) => files.flatMap((file) => parseIgnoreFile(file, baseDir));
12939var getIgnorePatternsAndPredicate = (patterns, options, includeParentIgnoreFiles = false) => __async(null, null, function* () {
12940  const { files, normalizedOptions, gitRoot } = yield collectIgnoreFileArtifactsAsync(
12941    patterns,
12942    options,
12943    includeParentIgnoreFiles
12944  );
12945  return buildIgnoreResult(files, normalizedOptions, gitRoot);
12946});
12947var getIgnorePatternsAndPredicateSync = (patterns, options, includeParentIgnoreFiles = false) => {
12948  const { files, normalizedOptions, gitRoot } = collectIgnoreFileArtifactsSync(
12949    patterns,
12950    options,
12951    includeParentIgnoreFiles
12952  );
12953  return buildIgnoreResult(files, normalizedOptions, gitRoot);
12954};
12955var isGitIgnored = (options) => isIgnoredByIgnoreFiles(GITIGNORE_FILES_PATTERN, options);
12956var isGitIgnoredSync = (options) => isIgnoredByIgnoreFilesSync(GITIGNORE_FILES_PATTERN, options);
12957
12958// node_modules/globby/index.js
12959var assertPatternsInput = (patterns) => {
12960  if (patterns.some((pattern) => typeof pattern !== "string")) {
12961    throw new TypeError("Patterns must be a string or an array of strings");
12962  }
12963};
12964var getStatMethod = (fsImplementation) => {
12965  var _a2, _b2;
12966  return (_b2 = (_a2 = bindFsMethod(fsImplementation == null ? void 0 : fsImplementation.promises, "stat")) != null ? _a2 : bindFsMethod(import_node_fs3.default.promises, "stat")) != null ? _b2 : promisifyFsMethod(fsImplementation, "stat");
12967};
12968var getStatSyncMethod2 = (fsImplementation) => {
12969  var _a2;
12970  return (_a2 = bindFsMethod(fsImplementation, "statSync")) != null ? _a2 : bindFsMethod(import_node_fs3.default, "statSync");
12971};
12972var isDirectory = (path5, fsImplementation) => __async(null, null, function* () {
12973  try {
12974    const stats = yield getStatMethod(fsImplementation)(path5);
12975    return stats.isDirectory();
12976  } catch (e) {
12977    return false;
12978  }
12979});
12980var isDirectorySync = (path5, fsImplementation) => {
12981  try {
12982    const stats = getStatSyncMethod2(fsImplementation)(path5);
12983    return stats.isDirectory();
12984  } catch (e) {
12985    return false;
12986  }
12987};
12988var normalizePathForDirectoryGlob = (filePath, cwd) => {
12989  const path5 = isNegativePattern(filePath) ? filePath.slice(1) : filePath;
12990  return import_node_path4.default.isAbsolute(path5) ? path5 : import_node_path4.default.join(cwd, path5);
12991};
12992var shouldExpandGlobstarDirectory = (pattern) => {
12993  const match = pattern == null ? void 0 : pattern.match(/\*\*\/([^/]+)$/);
12994  if (!match) {
12995    return false;
12996  }
12997  const dirname = match[1];
12998  const hasWildcards = /[*?[\]{}]/.test(dirname);
12999  const hasExtension = import_node_path4.default.extname(dirname) && !dirname.startsWith(".");
13000  return !hasWildcards && !hasExtension;
13001};
13002var getDirectoryGlob = ({ directoryPath, files, extensions }) => {
13003  const extensionGlob = (extensions == null ? void 0 : extensions.length) > 0 ? `.${extensions.length > 1 ? `{${extensions.join(",")}}` : extensions[0]}` : "";
13004  return files ? files.map((file) => import_node_path4.default.posix.join(directoryPath, `**/${import_node_path4.default.extname(file) ? file : `${file}${extensionGlob}`}`)) : [import_node_path4.default.posix.join(directoryPath, `**${extensionGlob ? `/*${extensionGlob}` : ""}`)];
13005};
13006var directoryToGlob = (_0, ..._1) => __async(null, [_0, ..._1], function* (directoryPaths, {
13007  cwd = import_node_process2.default.cwd(),
13008  files,
13009  extensions,
13010  fs: fsImplementation
13011} = {}) {
13012  const globs = yield Promise.all(directoryPaths.map((directoryPath) => __async(null, null, function* () {
13013    const checkPattern = isNegativePattern(directoryPath) ? directoryPath.slice(1) : directoryPath;
13014    if (shouldExpandGlobstarDirectory(checkPattern)) {
13015      return getDirectoryGlob({ directoryPath, files, extensions });
13016    }
13017    const pathToCheck = normalizePathForDirectoryGlob(directoryPath, cwd);
13018    return (yield isDirectory(pathToCheck, fsImplementation)) ? getDirectoryGlob({ directoryPath, files, extensions }) : directoryPath;
13019  })));
13020  return globs.flat();
13021});
13022var directoryToGlobSync = (directoryPaths, {
13023  cwd = import_node_process2.default.cwd(),
13024  files,
13025  extensions,
13026  fs: fsImplementation
13027} = {}) => directoryPaths.flatMap((directoryPath) => {
13028  const checkPattern = isNegativePattern(directoryPath) ? directoryPath.slice(1) : directoryPath;
13029  if (shouldExpandGlobstarDirectory(checkPattern)) {
13030    return getDirectoryGlob({ directoryPath, files, extensions });
13031  }
13032  const pathToCheck = normalizePathForDirectoryGlob(directoryPath, cwd);
13033  return isDirectorySync(pathToCheck, fsImplementation) ? getDirectoryGlob({ directoryPath, files, extensions }) : directoryPath;
13034});
13035var toPatternsArray = (patterns) => {
13036  patterns = [...new Set([patterns].flat())];
13037  assertPatternsInput(patterns);
13038  return patterns;
13039};
13040var checkCwdOption = (cwd, fsImplementation = import_node_fs3.default) => {
13041  if (!cwd || !fsImplementation.statSync) {
13042    return;
13043  }
13044  let stats;
13045  try {
13046    stats = fsImplementation.statSync(cwd);
13047  } catch (e) {
13048    return;
13049  }
13050  if (!stats.isDirectory()) {
13051    throw new Error(`The \`cwd\` option must be a path to a directory, got: ${cwd}`);
13052  }
13053};
13054var normalizeOptions2 = (options = {}) => {
13055  var _a2;
13056  const ignore = options.ignore ? Array.isArray(options.ignore) ? options.ignore : [options.ignore] : [];
13057  options = __spreadProps(__spreadValues({}, options), {
13058    ignore,
13059    expandDirectories: (_a2 = options.expandDirectories) != null ? _a2 : true,
13060    cwd: toPath(options.cwd)
13061  });
13062  checkCwdOption(options.cwd, options.fs);
13063  return options;
13064};
13065var normalizeArguments = (function_) => (patterns, options) => __async(null, null, function* () {
13066  return function_(toPatternsArray(patterns), normalizeOptions2(options));
13067});
13068var normalizeArgumentsSync = (function_) => (patterns, options) => function_(toPatternsArray(patterns), normalizeOptions2(options));
13069var getIgnoreFilesPatterns = (options) => {
13070  const { ignoreFiles, gitignore } = options;
13071  const patterns = ignoreFiles ? toPatternsArray(ignoreFiles) : [];
13072  if (gitignore) {
13073    patterns.push(GITIGNORE_FILES_PATTERN);
13074  }
13075  return patterns;
13076};
13077var applyIgnoreFilesAndGetFilter = (options) => __async(null, null, function* () {
13078  const ignoreFilesPatterns = getIgnoreFilesPatterns(options);
13079  if (ignoreFilesPatterns.length === 0) {
13080    return {
13081      options,
13082      filter: createFilterFunction(false, options.cwd)
13083    };
13084  }
13085  const includeParentIgnoreFiles = options.gitignore === true;
13086  const { patterns, predicate, usingGitRoot } = yield getIgnorePatternsAndPredicate(ignoreFilesPatterns, options, includeParentIgnoreFiles);
13087  const patternsForFastGlob = convertPatternsForFastGlob(patterns, usingGitRoot, normalizeDirectoryPatternForFastGlob);
13088  const modifiedOptions = __spreadProps(__spreadValues({}, options), {
13089    ignore: [...options.ignore, ...patternsForFastGlob]
13090  });
13091  return {
13092    options: modifiedOptions,
13093    filter: createFilterFunction(predicate, options.cwd)
13094  };
13095});
13096var applyIgnoreFilesAndGetFilterSync = (options) => {
13097  const ignoreFilesPatterns = getIgnoreFilesPatterns(options);
13098  if (ignoreFilesPatterns.length === 0) {
13099    return {
13100      options,
13101      filter: createFilterFunction(false, options.cwd)
13102    };
13103  }
13104  const includeParentIgnoreFiles = options.gitignore === true;
13105  const { patterns, predicate, usingGitRoot } = getIgnorePatternsAndPredicateSync(ignoreFilesPatterns, options, includeParentIgnoreFiles);
13106  const patternsForFastGlob = convertPatternsForFastGlob(patterns, usingGitRoot, normalizeDirectoryPatternForFastGlob);
13107  const modifiedOptions = __spreadProps(__spreadValues({}, options), {
13108    ignore: [...options.ignore, ...patternsForFastGlob]
13109  });
13110  return {
13111    options: modifiedOptions,
13112    filter: createFilterFunction(predicate, options.cwd)
13113  };
13114};
13115var createFilterFunction = (isIgnored, cwd) => {
13116  const seen = /* @__PURE__ */ new Set();
13117  const basePath = cwd || import_node_process2.default.cwd();
13118  const pathCache = /* @__PURE__ */ new Map();
13119  return (fastGlobResult) => {
13120    var _a2;
13121    const pathKey = import_node_path4.default.normalize((_a2 = fastGlobResult.path) != null ? _a2 : fastGlobResult);
13122    if (seen.has(pathKey)) {
13123      return false;
13124    }
13125    if (isIgnored) {
13126      let absolutePath = pathCache.get(pathKey);
13127      if (absolutePath === void 0) {
13128        absolutePath = import_node_path4.default.isAbsolute(pathKey) ? pathKey : import_node_path4.default.resolve(basePath, pathKey);
13129        pathCache.set(pathKey, absolutePath);
13130        if (pathCache.size > 1e4) {
13131          pathCache.clear();
13132        }
13133      }
13134      if (isIgnored(absolutePath)) {
13135        return false;
13136      }
13137    }
13138    seen.add(pathKey);
13139    return true;
13140  };
13141};
13142var unionFastGlobResults = (results, filter) => results.flat().filter((fastGlobResult) => filter(fastGlobResult));
13143var convertNegativePatterns = (patterns, options) => {
13144  if (patterns.length > 0 && patterns.every((pattern) => isNegativePattern(pattern))) {
13145    patterns = ["**/*", ...patterns];
13146  }
13147  const tasks = [];
13148  while (patterns.length > 0) {
13149    const index = patterns.findIndex((pattern) => isNegativePattern(pattern));
13150    if (index === -1) {
13151      tasks.push({ patterns, options });
13152      break;
13153    }
13154    const ignorePattern = patterns[index].slice(1);
13155    for (const task of tasks) {
13156      task.options.ignore.push(ignorePattern);
13157    }
13158    if (index !== 0) {
13159      tasks.push({
13160        patterns: patterns.slice(0, index),
13161        options: __spreadProps(__spreadValues({}, options), {
13162          ignore: [
13163            ...options.ignore,
13164            ignorePattern
13165          ]
13166        })
13167      });
13168    }
13169    patterns = patterns.slice(index + 1);
13170  }
13171  return tasks;
13172};
13173var applyParentDirectoryIgnoreAdjustments = (tasks) => tasks.map((task) => ({
13174  patterns: task.patterns,
13175  options: __spreadProps(__spreadValues({}, task.options), {
13176    ignore: adjustIgnorePatternsForParentDirectories(task.patterns, task.options.ignore)
13177  })
13178}));
13179var normalizeExpandDirectoriesOption = (options, cwd) => __spreadValues(__spreadValues({}, cwd ? { cwd } : {}), Array.isArray(options) ? { files: options } : options);
13180var generateTasks = (patterns, options) => __async(null, null, function* () {
13181  const globTasks = convertNegativePatterns(patterns, options);
13182  const { cwd, expandDirectories, fs: fsImplementation } = options;
13183  if (!expandDirectories) {
13184    return applyParentDirectoryIgnoreAdjustments(globTasks);
13185  }
13186  const directoryToGlobOptions = __spreadProps(__spreadValues({}, normalizeExpandDirectoriesOption(expandDirectories, cwd)), {
13187    fs: fsImplementation
13188  });
13189  return Promise.all(globTasks.map((task) => __async(null, null, function* () {
13190    let { patterns: patterns2, options: options2 } = task;
13191    [
13192      patterns2,
13193      options2.ignore
13194    ] = yield Promise.all([
13195      directoryToGlob(patterns2, directoryToGlobOptions),
13196      directoryToGlob(options2.ignore, { cwd, fs: fsImplementation })
13197    ]);
13198    options2.ignore = adjustIgnorePatternsForParentDirectories(patterns2, options2.ignore);
13199    return { patterns: patterns2, options: options2 };
13200  })));
13201});
13202var generateTasksSync = (patterns, options) => {
13203  const globTasks = convertNegativePatterns(patterns, options);
13204  const { cwd, expandDirectories, fs: fsImplementation } = options;
13205  if (!expandDirectories) {
13206    return applyParentDirectoryIgnoreAdjustments(globTasks);
13207  }
13208  const directoryToGlobSyncOptions = __spreadProps(__spreadValues({}, normalizeExpandDirectoriesOption(expandDirectories, cwd)), {
13209    fs: fsImplementation
13210  });
13211  return globTasks.map((task) => {
13212    let { patterns: patterns2, options: options2 } = task;
13213    patterns2 = directoryToGlobSync(patterns2, directoryToGlobSyncOptions);
13214    options2.ignore = directoryToGlobSync(options2.ignore, { cwd, fs: fsImplementation });
13215    options2.ignore = adjustIgnorePatternsForParentDirectories(patterns2, options2.ignore);
13216    return { patterns: patterns2, options: options2 };
13217  });
13218};
13219var globby = normalizeArguments((patterns, options) => __async(null, null, function* () {
13220  const { options: modifiedOptions, filter } = yield applyIgnoreFilesAndGetFilter(options);
13221  const tasks = yield generateTasks(patterns, modifiedOptions);
13222  const results = yield Promise.all(tasks.map((task) => (0, import_fast_glob2.default)(task.patterns, task.options)));
13223  return unionFastGlobResults(results, filter);
13224}));
13225var globbySync = normalizeArgumentsSync((patterns, options) => {
13226  const { options: modifiedOptions, filter } = applyIgnoreFilesAndGetFilterSync(options);
13227  const tasks = generateTasksSync(patterns, modifiedOptions);
13228  const results = tasks.map((task) => import_fast_glob2.default.sync(task.patterns, task.options));
13229  return unionFastGlobResults(results, filter);
13230});
13231var globbyStream = normalizeArgumentsSync((patterns, options) => {
13232  const { options: modifiedOptions, filter } = applyIgnoreFilesAndGetFilterSync(options);
13233  const tasks = generateTasksSync(patterns, modifiedOptions);
13234  const streams = tasks.map((task) => import_fast_glob2.default.stream(task.patterns, task.options));
13235  if (streams.length === 0) {
13236    return import_node_stream2.Readable.from([]);
13237  }
13238  const stream = mergeStreams(streams).filter((fastGlobResult) => filter(fastGlobResult));
13239  return stream;
13240});
13241var isDynamicPattern = normalizeArgumentsSync((patterns, options) => patterns.some((pattern) => import_fast_glob2.default.isDynamicPattern(pattern, options)));
13242var generateGlobTasks = normalizeArguments(generateTasks);
13243var generateGlobTasksSync = normalizeArgumentsSync(generateTasksSync);
13244var { convertPathToPattern } = import_fast_glob2.default;
13245
13246// node_modules/yaml/browser/index.js
13247var browser_exports = {};
13248__export(browser_exports, {
13249  Alias: () => Alias,
13250  CST: () => cst_exports,
13251  Composer: () => Composer,
13252  Document: () => Document,
13253  Lexer: () => Lexer,
13254  LineCounter: () => LineCounter,
13255  Pair: () => Pair,
13256  Parser: () => Parser,
13257  Scalar: () => Scalar,
13258  Schema: () => Schema,
13259  YAMLError: () => YAMLError,
13260  YAMLMap: () => YAMLMap,
13261  YAMLParseError: () => YAMLParseError,
13262  YAMLSeq: () => YAMLSeq,
13263  YAMLWarning: () => YAMLWarning,
13264  default: () => browser_default,
13265  isAlias: () => isAlias,
13266  isCollection: () => isCollection,
13267  isDocument: () => isDocument,
13268  isMap: () => isMap,
13269  isNode: () => isNode,
13270  isPair: () => isPair,
13271  isScalar: () => isScalar,
13272  isSeq: () => isSeq,
13273  parse: () => parse,
13274  parseAllDocuments: () => parseAllDocuments,
13275  parseDocument: () => parseDocument,
13276  stringify: () => stringify3,
13277  visit: () => visit,
13278  visitAsync: () => visitAsync
13279});
13280
13281// node_modules/yaml/browser/dist/index.js
13282var dist_exports = {};
13283__export(dist_exports, {
13284  Alias: () => Alias,
13285  CST: () => cst_exports,
13286  Composer: () => Composer,
13287  Document: () => Document,
13288  Lexer: () => Lexer,
13289  LineCounter: () => LineCounter,
13290  Pair: () => Pair,
13291  Parser: () => Parser,
13292  Scalar: () => Scalar,
13293  Schema: () => Schema,
13294  YAMLError: () => YAMLError,
13295  YAMLMap: () => YAMLMap,
13296  YAMLParseError: () => YAMLParseError,
13297  YAMLSeq: () => YAMLSeq,
13298  YAMLWarning: () => YAMLWarning,
13299  isAlias: () => isAlias,
13300  isCollection: () => isCollection,
13301  isDocument: () => isDocument,
13302  isMap: () => isMap,
13303  isNode: () => isNode,
13304  isPair: () => isPair,
13305  isScalar: () => isScalar,
13306  isSeq: () => isSeq,
13307  parse: () => parse,
13308  parseAllDocuments: () => parseAllDocuments,
13309  parseDocument: () => parseDocument,
13310  stringify: () => stringify3,
13311  visit: () => visit,
13312  visitAsync: () => visitAsync
13313});
13314
13315// node_modules/yaml/browser/dist/nodes/identity.js
13316var ALIAS = Symbol.for("yaml.alias");
13317var DOC = Symbol.for("yaml.document");
13318var MAP = Symbol.for("yaml.map");
13319var PAIR = Symbol.for("yaml.pair");
13320var SCALAR = Symbol.for("yaml.scalar");
13321var SEQ = Symbol.for("yaml.seq");
13322var NODE_TYPE = Symbol.for("yaml.node.type");
13323var isAlias = (node) => !!node && typeof node === "object" && node[NODE_TYPE] === ALIAS;
13324var isDocument = (node) => !!node && typeof node === "object" && node[NODE_TYPE] === DOC;
13325var isMap = (node) => !!node && typeof node === "object" && node[NODE_TYPE] === MAP;
13326var isPair = (node) => !!node && typeof node === "object" && node[NODE_TYPE] === PAIR;
13327var isScalar = (node) => !!node && typeof node === "object" && node[NODE_TYPE] === SCALAR;
13328var isSeq = (node) => !!node && typeof node === "object" && node[NODE_TYPE] === SEQ;
13329function isCollection(node) {
13330  if (node && typeof node === "object")
13331    switch (node[NODE_TYPE]) {
13332      case MAP:
13333      case SEQ:
13334        return true;
13335    }
13336  return false;
13337}
13338function isNode(node) {
13339  if (node && typeof node === "object")
13340    switch (node[NODE_TYPE]) {
13341      case ALIAS:
13342      case MAP:
13343      case SCALAR:
13344      case SEQ:
13345        return true;
13346    }
13347  return false;
13348}
13349var hasAnchor = (node) => (isScalar(node) || isCollection(node)) && !!node.anchor;
13350
13351// node_modules/yaml/browser/dist/visit.js
13352var BREAK = Symbol("break visit");
13353var SKIP = Symbol("skip children");
13354var REMOVE = Symbol("remove node");
13355function visit(node, visitor) {
13356  const visitor_ = initVisitor(visitor);
13357  if (isDocument(node)) {
13358    const cd = visit_(null, node.contents, visitor_, Object.freeze([node]));
13359    if (cd === REMOVE)
13360      node.contents = null;
13361  } else
13362    visit_(null, node, visitor_, Object.freeze([]));
13363}
13364visit.BREAK = BREAK;
13365visit.SKIP = SKIP;
13366visit.REMOVE = REMOVE;
13367function visit_(key, node, visitor, path5) {
13368  const ctrl = callVisitor(key, node, visitor, path5);
13369  if (isNode(ctrl) || isPair(ctrl)) {
13370    replaceNode(key, path5, ctrl);
13371    return visit_(key, ctrl, visitor, path5);
13372  }
13373  if (typeof ctrl !== "symbol") {
13374    if (isCollection(node)) {
13375      path5 = Object.freeze(path5.concat(node));
13376      for (let i = 0; i < node.items.length; ++i) {
13377        const ci2 = visit_(i, node.items[i], visitor, path5);
13378        if (typeof ci2 === "number")
13379          i = ci2 - 1;
13380        else if (ci2 === BREAK)
13381          return BREAK;
13382        else if (ci2 === REMOVE) {
13383          node.items.splice(i, 1);
13384          i -= 1;
13385        }
13386      }
13387    } else if (isPair(node)) {
13388      path5 = Object.freeze(path5.concat(node));
13389      const ck = visit_("key", node.key, visitor, path5);
13390      if (ck === BREAK)
13391        return BREAK;
13392      else if (ck === REMOVE)
13393        node.key = null;
13394      const cv = visit_("value", node.value, visitor, path5);
13395      if (cv === BREAK)
13396        return BREAK;
13397      else if (cv === REMOVE)
13398        node.value = null;
13399    }
13400  }
13401  return ctrl;
13402}
13403function visitAsync(node, visitor) {
13404  return __async(this, null, function* () {
13405    const visitor_ = initVisitor(visitor);
13406    if (isDocument(node)) {
13407      const cd = yield visitAsync_(null, node.contents, visitor_, Object.freeze([node]));
13408      if (cd === REMOVE)
13409        node.contents = null;
13410    } else
13411      yield visitAsync_(null, node, visitor_, Object.freeze([]));
13412  });
13413}
13414visitAsync.BREAK = BREAK;
13415visitAsync.SKIP = SKIP;
13416visitAsync.REMOVE = REMOVE;
13417function visitAsync_(key, node, visitor, path5) {
13418  return __async(this, null, function* () {
13419    const ctrl = yield callVisitor(key, node, visitor, path5);
13420    if (isNode(ctrl) || isPair(ctrl)) {
13421      replaceNode(key, path5, ctrl);
13422      return visitAsync_(key, ctrl, visitor, path5);
13423    }
13424    if (typeof ctrl !== "symbol") {
13425      if (isCollection(node)) {
13426        path5 = Object.freeze(path5.concat(node));
13427        for (let i = 0; i < node.items.length; ++i) {
13428          const ci2 = yield visitAsync_(i, node.items[i], visitor, path5);
13429          if (typeof ci2 === "number")
13430            i = ci2 - 1;
13431          else if (ci2 === BREAK)
13432            return BREAK;
13433          else if (ci2 === REMOVE) {
13434            node.items.splice(i, 1);
13435            i -= 1;
13436          }
13437        }
13438      } else if (isPair(node)) {
13439        path5 = Object.freeze(path5.concat(node));
13440        const ck = yield visitAsync_("key", node.key, visitor, path5);
13441        if (ck === BREAK)
13442          return BREAK;
13443        else if (ck === REMOVE)
13444          node.key = null;
13445        const cv = yield visitAsync_("value", node.value, visitor, path5);
13446        if (cv === BREAK)
13447          return BREAK;
13448        else if (cv === REMOVE)
13449          node.value = null;
13450      }
13451    }
13452    return ctrl;
13453  });
13454}
13455function initVisitor(visitor) {
13456  if (typeof visitor === "object" && (visitor.Collection || visitor.Node || visitor.Value)) {
13457    return Object.assign({
13458      Alias: visitor.Node,
13459      Map: visitor.Node,
13460      Scalar: visitor.Node,
13461      Seq: visitor.Node
13462    }, visitor.Value && {
13463      Map: visitor.Value,
13464      Scalar: visitor.Value,
13465      Seq: visitor.Value
13466    }, visitor.Collection && {
13467      Map: visitor.Collection,
13468      Seq: visitor.Collection
13469    }, visitor);
13470  }
13471  return visitor;
13472}
13473function callVisitor(key, node, visitor, path5) {
13474  var _a2, _b2, _c, _d, _e;
13475  if (typeof visitor === "function")
13476    return visitor(key, node, path5);
13477  if (isMap(node))
13478    return (_a2 = visitor.Map) == null ? void 0 : _a2.call(visitor, key, node, path5);
13479  if (isSeq(node))
13480    return (_b2 = visitor.Seq) == null ? void 0 : _b2.call(visitor, key, node, path5);
13481  if (isPair(node))
13482    return (_c = visitor.Pair) == null ? void 0 : _c.call(visitor, key, node, path5);
13483  if (isScalar(node))
13484    return (_d = visitor.Scalar) == null ? void 0 : _d.call(visitor, key, node, path5);
13485  if (isAlias(node))
13486    return (_e = visitor.Alias) == null ? void 0 : _e.call(visitor, key, node, path5);
13487  return void 0;
13488}
13489function replaceNode(key, path5, node) {
13490  const parent = path5[path5.length - 1];
13491  if (isCollection(parent)) {
13492    parent.items[key] = node;
13493  } else if (isPair(parent)) {
13494    if (key === "key")
13495      parent.key = node;
13496    else
13497      parent.value = node;
13498  } else if (isDocument(parent)) {
13499    parent.contents = node;
13500  } else {
13501    const pt2 = isAlias(parent) ? "alias" : "scalar";
13502    throw new Error(`Cannot replace node with ${pt2} parent`);
13503  }
13504}
13505
13506// node_modules/yaml/browser/dist/doc/directives.js
13507var escapeChars = {
13508  "!": "%21",
13509  ",": "%2C",
13510  "[": "%5B",
13511  "]": "%5D",
13512  "{": "%7B",
13513  "}": "%7D"
13514};
13515var escapeTagName = (tn) => tn.replace(/[!,[\]{}]/g, (ch) => escapeChars[ch]);
13516var Directives = class _Directives {
13517  constructor(yaml, tags) {
13518    this.docStart = null;
13519    this.docEnd = false;
13520    this.yaml = Object.assign({}, _Directives.defaultYaml, yaml);
13521    this.tags = Object.assign({}, _Directives.defaultTags, tags);
13522  }
13523  clone() {
13524    const copy = new _Directives(this.yaml, this.tags);
13525    copy.docStart = this.docStart;
13526    return copy;
13527  }
13528  /**
13529   * During parsing, get a Directives instance for the current document and
13530   * update the stream state according to the current version's spec.
13531   */
13532  atDocument() {
13533    const res = new _Directives(this.yaml, this.tags);
13534    switch (this.yaml.version) {
13535      case "1.1":
13536        this.atNextDocument = true;
13537        break;
13538      case "1.2":
13539        this.atNextDocument = false;
13540        this.yaml = {
13541          explicit: _Directives.defaultYaml.explicit,
13542          version: "1.2"
13543        };
13544        this.tags = Object.assign({}, _Directives.defaultTags);
13545        break;
13546    }
13547    return res;
13548  }
13549  /**
13550   * @param onError - May be called even if the action was successful
13551   * @returns `true` on success
13552   */
13553  add(line, onError) {
13554    if (this.atNextDocument) {
13555      this.yaml = { explicit: _Directives.defaultYaml.explicit, version: "1.1" };
13556      this.tags = Object.assign({}, _Directives.defaultTags);
13557      this.atNextDocument = false;
13558    }
13559    const parts = line.trim().split(/[ \t]+/);
13560    const name = parts.shift();
13561    switch (name) {
13562      case "%TAG": {
13563        if (parts.length !== 2) {
13564          onError(0, "%TAG directive should contain exactly two parts");
13565          if (parts.length < 2)
13566            return false;
13567        }
13568        const [handle, prefix] = parts;
13569        this.tags[handle] = prefix;
13570        return true;
13571      }
13572      case "%YAML": {
13573        this.yaml.explicit = true;
13574        if (parts.length !== 1) {
13575          onError(0, "%YAML directive should contain exactly one part");
13576          return false;
13577        }
13578        const [version] = parts;
13579        if (version === "1.1" || version === "1.2") {
13580          this.yaml.version = version;
13581          return true;
13582        } else {
13583          const isValid = /^\d+\.\d+$/.test(version);
13584          onError(6, `Unsupported YAML version ${version}`, isValid);
13585          return false;
13586        }
13587      }
13588      default:
13589        onError(0, `Unknown directive ${name}`, true);
13590        return false;
13591    }
13592  }
13593  /**
13594   * Resolves a tag, matching handles to those defined in %TAG directives.
13595   *
13596   * @returns Resolved tag, which may also be the non-specific tag `'!'` or a
13597   *   `'!local'` tag, or `null` if unresolvable.
13598   */
13599  tagName(source, onError) {
13600    if (source === "!")
13601      return "!";
13602    if (source[0] !== "!") {
13603      onError(`Not a valid tag: ${source}`);
13604      return null;
13605    }
13606    if (source[1] === "<") {
13607      const verbatim = source.slice(2, -1);
13608      if (verbatim === "!" || verbatim === "!!") {
13609        onError(`Verbatim tags aren't resolved, so ${source} is invalid.`);
13610        return null;
13611      }
13612      if (source[source.length - 1] !== ">")
13613        onError("Verbatim tags must end with a >");
13614      return verbatim;
13615    }
13616    const [, handle, suffix] = source.match(new RegExp("^(.*!)([^!]*)$", "s"));
13617    if (!suffix)
13618      onError(`The ${source} tag has no suffix`);
13619    const prefix = this.tags[handle];
13620    if (prefix) {
13621      try {
13622        return prefix + decodeURIComponent(suffix);
13623      } catch (error) {
13624        onError(String(error));
13625        return null;
13626      }
13627    }
13628    if (handle === "!")
13629      return source;
13630    onError(`Could not resolve tag: ${source}`);
13631    return null;
13632  }
13633  /**
13634   * Given a fully resolved tag, returns its printable string form,
13635   * taking into account current tag prefixes and defaults.
13636   */
13637  tagString(tag) {
13638    for (const [handle, prefix] of Object.entries(this.tags)) {
13639      if (tag.startsWith(prefix))
13640        return handle + escapeTagName(tag.substring(prefix.length));
13641    }
13642    return tag[0] === "!" ? tag : `!<${tag}>`;
13643  }
13644  toString(doc) {
13645    const lines = this.yaml.explicit ? [`%YAML ${this.yaml.version || "1.2"}`] : [];
13646    const tagEntries = Object.entries(this.tags);
13647    let tagNames;
13648    if (doc && tagEntries.length > 0 && isNode(doc.contents)) {
13649      const tags = {};
13650      visit(doc.contents, (_key, node) => {
13651        if (isNode(node) && node.tag)
13652          tags[node.tag] = true;
13653      });
13654      tagNames = Object.keys(tags);
13655    } else
13656      tagNames = [];
13657    for (const [handle, prefix] of tagEntries) {
13658      if (handle === "!!" && prefix === "tag:yaml.org,2002:")
13659        continue;
13660      if (!doc || tagNames.some((tn) => tn.startsWith(prefix)))
13661        lines.push(`%TAG ${handle} ${prefix}`);
13662    }
13663    return lines.join("\n");
13664  }
13665};
13666Directives.defaultYaml = { explicit: false, version: "1.2" };
13667Directives.defaultTags = { "!!": "tag:yaml.org,2002:" };
13668
13669// node_modules/yaml/browser/dist/doc/anchors.js
13670function anchorIsValid(anchor) {
13671  if (/[\x00-\x19\s,[\]{}]/.test(anchor)) {
13672    const sa = JSON.stringify(anchor);
13673    const msg = `Anchor must not contain whitespace or control characters: ${sa}`;
13674    throw new Error(msg);
13675  }
13676  return true;
13677}
13678function anchorNames(root) {
13679  const anchors = /* @__PURE__ */ new Set();
13680  visit(root, {
13681    Value(_key, node) {
13682      if (node.anchor)
13683        anchors.add(node.anchor);
13684    }
13685  });
13686  return anchors;
13687}
13688function findNewAnchor(prefix, exclude) {
13689  for (let i = 1; true; ++i) {
13690    const name = `${prefix}${i}`;
13691    if (!exclude.has(name))
13692      return name;
13693  }
13694}
13695function createNodeAnchors(doc, prefix) {
13696  const aliasObjects = [];
13697  const sourceObjects = /* @__PURE__ */ new Map();
13698  let prevAnchors = null;
13699  return {
13700    onAnchor: (source) => {
13701      aliasObjects.push(source);
13702      prevAnchors != null ? prevAnchors : prevAnchors = anchorNames(doc);
13703      const anchor = findNewAnchor(prefix, prevAnchors);
13704      prevAnchors.add(anchor);
13705      return anchor;
13706    },
13707    /**
13708     * With circular references, the source node is only resolved after all
13709     * of its child nodes are. This is why anchors are set only after all of
13710     * the nodes have been created.
13711     */
13712    setAnchors: () => {
13713      for (const source of aliasObjects) {
13714        const ref = sourceObjects.get(source);
13715        if (typeof ref === "object" && ref.anchor && (isScalar(ref.node) || isCollection(ref.node))) {
13716          ref.node.anchor = ref.anchor;
13717        } else {
13718          const error = new Error("Failed to resolve repeated object (this should not happen)");
13719          error.source = source;
13720          throw error;
13721        }
13722      }
13723    },
13724    sourceObjects
13725  };
13726}
13727
13728// node_modules/yaml/browser/dist/doc/applyReviver.js
13729function applyReviver(reviver, obj, key, val) {
13730  if (val && typeof val === "object") {
13731    if (Array.isArray(val)) {
13732      for (let i = 0, len = val.length; i < len; ++i) {
13733        const v0 = val[i];
13734        const v1 = applyReviver(reviver, val, String(i), v0);
13735        if (v1 === void 0)
13736          delete val[i];
13737        else if (v1 !== v0)
13738          val[i] = v1;
13739      }
13740    } else if (val instanceof Map) {
13741      for (const k2 of Array.from(val.keys())) {
13742        const v0 = val.get(k2);
13743        const v1 = applyReviver(reviver, val, k2, v0);
13744        if (v1 === void 0)
13745          val.delete(k2);
13746        else if (v1 !== v0)
13747          val.set(k2, v1);
13748      }
13749    } else if (val instanceof Set) {
13750      for (const v0 of Array.from(val)) {
13751        const v1 = applyReviver(reviver, val, v0, v0);
13752        if (v1 === void 0)
13753          val.delete(v0);
13754        else if (v1 !== v0) {
13755          val.delete(v0);
13756          val.add(v1);
13757        }
13758      }
13759    } else {
13760      for (const [k2, v0] of Object.entries(val)) {
13761        const v1 = applyReviver(reviver, val, k2, v0);
13762        if (v1 === void 0)
13763          delete val[k2];
13764        else if (v1 !== v0)
13765          val[k2] = v1;
13766      }
13767    }
13768  }
13769  return reviver.call(obj, key, val);
13770}
13771
13772// node_modules/yaml/browser/dist/nodes/toJS.js
13773function toJS(value, arg, ctx) {
13774  if (Array.isArray(value))
13775    return value.map((v2, i) => toJS(v2, String(i), ctx));
13776  if (value && typeof value.toJSON === "function") {
13777    if (!ctx || !hasAnchor(value))
13778      return value.toJSON(arg, ctx);
13779    const data = { aliasCount: 0, count: 1, res: void 0 };
13780    ctx.anchors.set(value, data);
13781    ctx.onCreate = (res2) => {
13782      data.res = res2;
13783      delete ctx.onCreate;
13784    };
13785    const res = value.toJSON(arg, ctx);
13786    if (ctx.onCreate)
13787      ctx.onCreate(res);
13788    return res;
13789  }
13790  if (typeof value === "bigint" && !(ctx == null ? void 0 : ctx.keep))
13791    return Number(value);
13792  return value;
13793}
13794
13795// node_modules/yaml/browser/dist/nodes/Node.js
13796var NodeBase = class {
13797  constructor(type) {
13798    Object.defineProperty(this, NODE_TYPE, { value: type });
13799  }
13800  /** Create a copy of this node.  */
13801  clone() {
13802    const copy = Object.create(Object.getPrototypeOf(this), Object.getOwnPropertyDescriptors(this));
13803    if (this.range)
13804      copy.range = this.range.slice();
13805    return copy;
13806  }
13807  /** A plain JavaScript representation of this node. */
13808  toJS(doc, { mapAsMap, maxAliasCount, onAnchor, reviver } = {}) {
13809    if (!isDocument(doc))
13810      throw new TypeError("A document argument is required");
13811    const ctx = {
13812      anchors: /* @__PURE__ */ new Map(),
13813      doc,
13814      keep: true,
13815      mapAsMap: mapAsMap === true,
13816      mapKeyWarned: false,
13817      maxAliasCount: typeof maxAliasCount === "number" ? maxAliasCount : 100
13818    };
13819    const res = toJS(this, "", ctx);
13820    if (typeof onAnchor === "function")
13821      for (const { count, res: res2 } of ctx.anchors.values())
13822        onAnchor(res2, count);
13823    return typeof reviver === "function" ? applyReviver(reviver, { "": res }, "", res) : res;
13824  }
13825};
13826
13827// node_modules/yaml/browser/dist/nodes/Alias.js
13828var Alias = class extends NodeBase {
13829  constructor(source) {
13830    super(ALIAS);
13831    this.source = source;
13832    Object.defineProperty(this, "tag", {
13833      set() {
13834        throw new Error("Alias nodes cannot have tags");
13835      }
13836    });
13837  }
13838  /**
13839   * Resolve the value of this alias within `doc`, finding the last
13840   * instance of the `source` anchor before this node.
13841   */
13842  resolve(doc, ctx) {
13843    let nodes;
13844    if (ctx == null ? void 0 : ctx.aliasResolveCache) {
13845      nodes = ctx.aliasResolveCache;
13846    } else {
13847      nodes = [];
13848      visit(doc, {
13849        Node: (_key, node) => {
13850          if (isAlias(node) || hasAnchor(node))
13851            nodes.push(node);
13852        }
13853      });
13854      if (ctx)
13855        ctx.aliasResolveCache = nodes;
13856    }
13857    let found = void 0;
13858    for (const node of nodes) {
13859      if (node === this)
13860        break;
13861      if (node.anchor === this.source)
13862        found = node;
13863    }
13864    return found;
13865  }
13866  toJSON(_arg, ctx) {
13867    if (!ctx)
13868      return { source: this.source };
13869    const { anchors, doc, maxAliasCount } = ctx;
13870    const source = this.resolve(doc, ctx);
13871    if (!source) {
13872      const msg = `Unresolved alias (the anchor must be set before the alias): ${this.source}`;
13873      throw new ReferenceError(msg);
13874    }
13875    let data = anchors.get(source);
13876    if (!data) {
13877      toJS(source, null, ctx);
13878      data = anchors.get(source);
13879    }
13880    if (!data || data.res === void 0) {
13881      const msg = "This should not happen: Alias anchor was not resolved?";
13882      throw new ReferenceError(msg);
13883    }
13884    if (maxAliasCount >= 0) {
13885      data.count += 1;
13886      if (data.aliasCount === 0)
13887        data.aliasCount = getAliasCount(doc, source, anchors);
13888      if (data.count * data.aliasCount > maxAliasCount) {
13889        const msg = "Excessive alias count indicates a resource exhaustion attack";
13890        throw new ReferenceError(msg);
13891      }
13892    }
13893    return data.res;
13894  }
13895  toString(ctx, _onComment, _onChompKeep) {
13896    const src = `*${this.source}`;
13897    if (ctx) {
13898      anchorIsValid(this.source);
13899      if (ctx.options.verifyAliasOrder && !ctx.anchors.has(this.source)) {
13900        const msg = `Unresolved alias (the anchor must be set before the alias): ${this.source}`;
13901        throw new Error(msg);
13902      }
13903      if (ctx.implicitKey)
13904        return `${src} `;
13905    }
13906    return src;
13907  }
13908};
13909function getAliasCount(doc, node, anchors) {
13910  if (isAlias(node)) {
13911    const source = node.resolve(doc);
13912    const anchor = anchors && source && anchors.get(source);
13913    return anchor ? anchor.count * anchor.aliasCount : 0;
13914  } else if (isCollection(node)) {
13915    let count = 0;
13916    for (const item of node.items) {
13917      const c2 = getAliasCount(doc, item, anchors);
13918      if (c2 > count)
13919        count = c2;
13920    }
13921    return count;
13922  } else if (isPair(node)) {
13923    const kc = getAliasCount(doc, node.key, anchors);
13924    const vc = getAliasCount(doc, node.value, anchors);
13925    return Math.max(kc, vc);
13926  }
13927  return 1;
13928}
13929
13930// node_modules/yaml/browser/dist/nodes/Scalar.js
13931var isScalarValue = (value) => !value || typeof value !== "function" && typeof value !== "object";
13932var Scalar = class extends NodeBase {
13933  constructor(value) {
13934    super(SCALAR);
13935    this.value = value;
13936  }
13937  toJSON(arg, ctx) {
13938    return (ctx == null ? void 0 : ctx.keep) ? this.value : toJS(this.value, arg, ctx);
13939  }
13940  toString() {
13941    return String(this.value);
13942  }
13943};
13944Scalar.BLOCK_FOLDED = "BLOCK_FOLDED";
13945Scalar.BLOCK_LITERAL = "BLOCK_LITERAL";
13946Scalar.PLAIN = "PLAIN";
13947Scalar.QUOTE_DOUBLE = "QUOTE_DOUBLE";
13948Scalar.QUOTE_SINGLE = "QUOTE_SINGLE";
13949
13950// node_modules/yaml/browser/dist/doc/createNode.js
13951var defaultTagPrefix = "tag:yaml.org,2002:";
13952function findTagObject(value, tagName, tags) {
13953  var _a2;
13954  if (tagName) {
13955    const match = tags.filter((t3) => t3.tag === tagName);
13956    const tagObj = (_a2 = match.find((t3) => !t3.format)) != null ? _a2 : match[0];
13957    if (!tagObj)
13958      throw new Error(`Tag ${tagName} not found`);
13959    return tagObj;
13960  }
13961  return tags.find((t3) => {
13962    var _a3;
13963    return ((_a3 = t3.identify) == null ? void 0 : _a3.call(t3, value)) && !t3.format;
13964  });
13965}
13966function createNode(value, tagName, ctx) {
13967  var _a2, _b2, _c, _d;
13968  if (isDocument(value))
13969    value = value.contents;
13970  if (isNode(value))
13971    return value;
13972  if (isPair(value)) {
13973    const map2 = (_b2 = (_a2 = ctx.schema[MAP]).createNode) == null ? void 0 : _b2.call(_a2, ctx.schema, null, ctx);
13974    map2.items.push(value);
13975    return map2;
13976  }
13977  if (value instanceof String || value instanceof Number || value instanceof Boolean || typeof BigInt !== "undefined" && value instanceof BigInt) {
13978    value = value.valueOf();
13979  }
13980  const { aliasDuplicateObjects, onAnchor, onTagObj, schema: schema4, sourceObjects } = ctx;
13981  let ref = void 0;
13982  if (aliasDuplicateObjects && value && typeof value === "object") {
13983    ref = sourceObjects.get(value);
13984    if (ref) {
13985      (_c = ref.anchor) != null ? _c : ref.anchor = onAnchor(value);
13986      return new Alias(ref.anchor);
13987    } else {
13988      ref = { anchor: null, node: null };
13989      sourceObjects.set(value, ref);
13990    }
13991  }
13992  if (tagName == null ? void 0 : tagName.startsWith("!!"))
13993    tagName = defaultTagPrefix + tagName.slice(2);
13994  let tagObj = findTagObject(value, tagName, schema4.tags);
13995  if (!tagObj) {
13996    if (value && typeof value.toJSON === "function") {
13997      value = value.toJSON();
13998    }
13999    if (!value || typeof value !== "object") {
14000      const node2 = new Scalar(value);
14001      if (ref)
14002        ref.node = node2;
14003      return node2;
14004    }
14005    tagObj = value instanceof Map ? schema4[MAP] : Symbol.iterator in Object(value) ? schema4[SEQ] : schema4[MAP];
14006  }
14007  if (onTagObj) {
14008    onTagObj(tagObj);
14009    delete ctx.onTagObj;
14010  }
14011  const node = (tagObj == null ? void 0 : tagObj.createNode) ? tagObj.createNode(ctx.schema, value, ctx) : typeof ((_d = tagObj == null ? void 0 : tagObj.nodeClass) == null ? void 0 : _d.from) === "function" ? tagObj.nodeClass.from(ctx.schema, value, ctx) : new Scalar(value);
14012  if (tagName)
14013    node.tag = tagName;
14014  else if (!tagObj.default)
14015    node.tag = tagObj.tag;
14016  if (ref)
14017    ref.node = node;
14018  return node;
14019}
14020
14021// node_modules/yaml/browser/dist/nodes/Collection.js
14022function collectionFromPath(schema4, path5, value) {
14023  let v2 = value;
14024  for (let i = path5.length - 1; i >= 0; --i) {
14025    const k2 = path5[i];
14026    if (typeof k2 === "number" && Number.isInteger(k2) && k2 >= 0) {
14027      const a = [];
14028      a[k2] = v2;
14029      v2 = a;
14030    } else {
14031      v2 = /* @__PURE__ */ new Map([[k2, v2]]);
14032    }
14033  }
14034  return createNode(v2, void 0, {
14035    aliasDuplicateObjects: false,
14036    keepUndefined: false,
14037    onAnchor: () => {
14038      throw new Error("This should not happen, please report a bug.");
14039    },
14040    schema: schema4,
14041    sourceObjects: /* @__PURE__ */ new Map()
14042  });
14043}
14044var isEmptyPath = (path5) => path5 == null || typeof path5 === "object" && !!path5[Symbol.iterator]().next().done;
14045var Collection = class extends NodeBase {
14046  constructor(type, schema4) {
14047    super(type);
14048    Object.defineProperty(this, "schema", {
14049      value: schema4,
14050      configurable: true,
14051      enumerable: false,
14052      writable: true
14053    });
14054  }
14055  /**
14056   * Create a copy of this collection.
14057   *
14058   * @param schema - If defined, overwrites the original's schema
14059   */
14060  clone(schema4) {
14061    const copy = Object.create(Object.getPrototypeOf(this), Object.getOwnPropertyDescriptors(this));
14062    if (schema4)
14063      copy.schema = schema4;
14064    copy.items = copy.items.map((it) => isNode(it) || isPair(it) ? it.clone(schema4) : it);
14065    if (this.range)
14066      copy.range = this.range.slice();
14067    return copy;
14068  }
14069  /**
14070   * Adds a value to the collection. For `!!map` and `!!omap` the value must
14071   * be a Pair instance or a `{ key, value }` object, which may not have a key
14072   * that already exists in the map.
14073   */
14074  addIn(path5, value) {
14075    if (isEmptyPath(path5))
14076      this.add(value);
14077    else {
14078      const [key, ...rest] = path5;
14079      const node = this.get(key, true);
14080      if (isCollection(node))
14081        node.addIn(rest, value);
14082      else if (node === void 0 && this.schema)
14083        this.set(key, collectionFromPath(this.schema, rest, value));
14084      else
14085        throw new Error(`Expected YAML collection at ${key}. Remaining path: ${rest}`);
14086    }
14087  }
14088  /**
14089   * Removes a value from the collection.
14090   * @returns `true` if the item was found and removed.
14091   */
14092  deleteIn(path5) {
14093    const [key, ...rest] = path5;
14094    if (rest.length === 0)
14095      return this.delete(key);
14096    const node = this.get(key, true);
14097    if (isCollection(node))
14098      return node.deleteIn(rest);
14099    else
14100      throw new Error(`Expected YAML collection at ${key}. Remaining path: ${rest}`);
14101  }
14102  /**
14103   * Returns item at `key`, or `undefined` if not found. By default unwraps
14104   * scalar values from their surrounding node; to disable set `keepScalar` to
14105   * `true` (collections are always returned intact).
14106   */
14107  getIn(path5, keepScalar) {
14108    const [key, ...rest] = path5;
14109    const node = this.get(key, true);
14110    if (rest.length === 0)
14111      return !keepScalar && isScalar(node) ? node.value : node;
14112    else
14113      return isCollection(node) ? node.getIn(rest, keepScalar) : void 0;
14114  }
14115  hasAllNullValues(allowScalar) {
14116    return this.items.every((node) => {
14117      if (!isPair(node))
14118        return false;
14119      const n4 = node.value;
14120      return n4 == null || allowScalar && isScalar(n4) && n4.value == null && !n4.commentBefore && !n4.comment && !n4.tag;
14121    });
14122  }
14123  /**
14124   * Checks if the collection includes a value with the key `key`.
14125   */
14126  hasIn(path5) {
14127    const [key, ...rest] = path5;
14128    if (rest.length === 0)
14129      return this.has(key);
14130    const node = this.get(key, true);
14131    return isCollection(node) ? node.hasIn(rest) : false;
14132  }
14133  /**
14134   * Sets a value in this collection. For `!!set`, `value` needs to be a
14135   * boolean to add/remove the item from the set.
14136   */
14137  setIn(path5, value) {
14138    const [key, ...rest] = path5;
14139    if (rest.length === 0) {
14140      this.set(key, value);
14141    } else {
14142      const node = this.get(key, true);
14143      if (isCollection(node))
14144        node.setIn(rest, value);
14145      else if (node === void 0 && this.schema)
14146        this.set(key, collectionFromPath(this.schema, rest, value));
14147      else
14148        throw new Error(`Expected YAML collection at ${key}. Remaining path: ${rest}`);
14149    }
14150  }
14151};
14152
14153// node_modules/yaml/browser/dist/stringify/stringifyComment.js
14154var stringifyComment = (str) => str.replace(/^(?!$)(?: $)?/gm, "#");
14155function indentComment(comment, indent) {
14156  if (/^\n+$/.test(comment))
14157    return comment.substring(1);
14158  return indent ? comment.replace(/^(?! *$)/gm, indent) : comment;
14159}
14160var lineComment = (str, indent, comment) => str.endsWith("\n") ? indentComment(comment, indent) : comment.includes("\n") ? "\n" + indentComment(comment, indent) : (str.endsWith(" ") ? "" : " ") + comment;
14161
14162// node_modules/yaml/browser/dist/stringify/foldFlowLines.js
14163var FOLD_FLOW = "flow";
14164var FOLD_BLOCK = "block";
14165var FOLD_QUOTED = "quoted";
14166function foldFlowLines(text, indent, mode = "flow", { indentAtStart, lineWidth = 80, minContentWidth = 20, onFold, onOverflow } = {}) {
14167  if (!lineWidth || lineWidth < 0)
14168    return text;
14169  if (lineWidth < minContentWidth)
14170    minContentWidth = 0;
14171  const endStep = Math.max(1 + minContentWidth, 1 + lineWidth - indent.length);
14172  if (text.length <= endStep)
14173    return text;
14174  const folds = [];
14175  const escapedFolds = {};
14176  let end = lineWidth - indent.length;
14177  if (typeof indentAtStart === "number") {
14178    if (indentAtStart > lineWidth - Math.max(2, minContentWidth))
14179      folds.push(0);
14180    else
14181      end = lineWidth - indentAtStart;
14182  }
14183  let split = void 0;
14184  let prev = void 0;
14185  let overflow = false;
14186  let i = -1;
14187  let escStart = -1;
14188  let escEnd = -1;
14189  if (mode === FOLD_BLOCK) {
14190    i = consumeMoreIndentedLines(text, i, indent.length);
14191    if (i !== -1)
14192      end = i + endStep;
14193  }
14194  for (let ch; ch = text[i += 1]; ) {
14195    if (mode === FOLD_QUOTED && ch === "\\") {
14196      escStart = i;
14197      switch (text[i + 1]) {
14198        case "x":
14199          i += 3;
14200          break;
14201        case "u":
14202          i += 5;
14203          break;
14204        case "U":
14205          i += 9;
14206          break;
14207        default:
14208          i += 1;
14209      }
14210      escEnd = i;
14211    }
14212    if (ch === "\n") {
14213      if (mode === FOLD_BLOCK)
14214        i = consumeMoreIndentedLines(text, i, indent.length);
14215      end = i + indent.length + endStep;
14216      split = void 0;
14217    } else {
14218      if (ch === " " && prev && prev !== " " && prev !== "\n" && prev !== "	") {
14219        const next = text[i + 1];
14220        if (next && next !== " " && next !== "\n" && next !== "	")
14221          split = i;
14222      }
14223      if (i >= end) {
14224        if (split) {
14225          folds.push(split);
14226          end = split + endStep;
14227          split = void 0;
14228        } else if (mode === FOLD_QUOTED) {
14229          while (prev === " " || prev === "	") {
14230            prev = ch;
14231            ch = text[i += 1];
14232            overflow = true;
14233          }
14234          const j = i > escEnd + 1 ? i - 2 : escStart - 1;
14235          if (escapedFolds[j])
14236            return text;
14237          folds.push(j);
14238          escapedFolds[j] = true;
14239          end = j + endStep;
14240          split = void 0;
14241        } else {
14242          overflow = true;
14243        }
14244      }
14245    }
14246    prev = ch;
14247  }
14248  if (overflow && onOverflow)
14249    onOverflow();
14250  if (folds.length === 0)
14251    return text;
14252  if (onFold)
14253    onFold();
14254  let res = text.slice(0, folds[0]);
14255  for (let i2 = 0; i2 < folds.length; ++i2) {
14256    const fold = folds[i2];
14257    const end2 = folds[i2 + 1] || text.length;
14258    if (fold === 0)
14259      res = `
14260${indent}${text.slice(0, end2)}`;
14261    else {
14262      if (mode === FOLD_QUOTED && escapedFolds[fold])
14263        res += `${text[fold]}\\`;
14264      res += `
14265${indent}${text.slice(fold + 1, end2)}`;
14266    }
14267  }
14268  return res;
14269}
14270function consumeMoreIndentedLines(text, i, indent) {
14271  let end = i;
14272  let start = i + 1;
14273  let ch = text[start];
14274  while (ch === " " || ch === "	") {
14275    if (i < start + indent) {
14276      ch = text[++i];
14277    } else {
14278      do {
14279        ch = text[++i];
14280      } while (ch && ch !== "\n");
14281      end = i;
14282      start = i + 1;
14283      ch = text[start];
14284    }
14285  }
14286  return end;
14287}
14288
14289// node_modules/yaml/browser/dist/stringify/stringifyString.js
14290var getFoldOptions = (ctx, isBlock2) => ({
14291  indentAtStart: isBlock2 ? ctx.indent.length : ctx.indentAtStart,
14292  lineWidth: ctx.options.lineWidth,
14293  minContentWidth: ctx.options.minContentWidth
14294});
14295var containsDocumentMarker = (str) => /^(%|---|\.\.\.)/m.test(str);
14296function lineLengthOverLimit(str, lineWidth, indentLength) {
14297  if (!lineWidth || lineWidth < 0)
14298    return false;
14299  const limit = lineWidth - indentLength;
14300  const strLen = str.length;
14301  if (strLen <= limit)
14302    return false;
14303  for (let i = 0, start = 0; i < strLen; ++i) {
14304    if (str[i] === "\n") {
14305      if (i - start > limit)
14306        return true;
14307      start = i + 1;
14308      if (strLen - start <= limit)
14309        return false;
14310    }
14311  }
14312  return true;
14313}
14314function doubleQuotedString(value, ctx) {
14315  const json = JSON.stringify(value);
14316  if (ctx.options.doubleQuotedAsJSON)
14317    return json;
14318  const { implicitKey } = ctx;
14319  const minMultiLineLength = ctx.options.doubleQuotedMinMultiLineLength;
14320  const indent = ctx.indent || (containsDocumentMarker(value) ? "  " : "");
14321  let str = "";
14322  let start = 0;
14323  for (let i = 0, ch = json[i]; ch; ch = json[++i]) {
14324    if (ch === " " && json[i + 1] === "\\" && json[i + 2] === "n") {
14325      str += json.slice(start, i) + "\\ ";
14326      i += 1;
14327      start = i;
14328      ch = "\\";
14329    }
14330    if (ch === "\\")
14331      switch (json[i + 1]) {
14332        case "u":
14333          {
14334            str += json.slice(start, i);
14335            const code = json.substr(i + 2, 4);
14336            switch (code) {
14337              case "0000":
14338                str += "\\0";
14339                break;
14340              case "0007":
14341                str += "\\a";
14342                break;
14343              case "000b":
14344                str += "\\v";
14345                break;
14346              case "001b":
14347                str += "\\e";
14348                break;
14349              case "0085":
14350                str += "\\N";
14351                break;
14352              case "00a0":
14353                str += "\\_";
14354                break;
14355              case "2028":
14356                str += "\\L";
14357                break;
14358              case "2029":
14359                str += "\\P";
14360                break;
14361              default:
14362                if (code.substr(0, 2) === "00")
14363                  str += "\\x" + code.substr(2);
14364                else
14365                  str += json.substr(i, 6);
14366            }
14367            i += 5;
14368            start = i + 1;
14369          }
14370          break;
14371        case "n":
14372          if (implicitKey || json[i + 2] === '"' || json.length < minMultiLineLength) {
14373            i += 1;
14374          } else {
14375            str += json.slice(start, i) + "\n\n";
14376            while (json[i + 2] === "\\" && json[i + 3] === "n" && json[i + 4] !== '"') {
14377              str += "\n";
14378              i += 2;
14379            }
14380            str += indent;
14381            if (json[i + 2] === " ")
14382              str += "\\";
14383            i += 1;
14384            start = i + 1;
14385          }
14386          break;
14387        default:
14388          i += 1;
14389      }
14390  }
14391  str = start ? str + json.slice(start) : json;
14392  return implicitKey ? str : foldFlowLines(str, indent, FOLD_QUOTED, getFoldOptions(ctx, false));
14393}
14394function singleQuotedString(value, ctx) {
14395  if (ctx.options.singleQuote === false || ctx.implicitKey && value.includes("\n") || /[ \t]\n|\n[ \t]/.test(value))
14396    return doubleQuotedString(value, ctx);
14397  const indent = ctx.indent || (containsDocumentMarker(value) ? "  " : "");
14398  const res = "'" + value.replace(/'/g, "''").replace(/\n+/g, `$&
14399${indent}`) + "'";
14400  return ctx.implicitKey ? res : foldFlowLines(res, indent, FOLD_FLOW, getFoldOptions(ctx, false));
14401}
14402function quotedString(value, ctx) {
14403  const { singleQuote } = ctx.options;
14404  let qs;
14405  if (singleQuote === false)
14406    qs = doubleQuotedString;
14407  else {
14408    const hasDouble = value.includes('"');
14409    const hasSingle = value.includes("'");
14410    if (hasDouble && !hasSingle)
14411      qs = singleQuotedString;
14412    else if (hasSingle && !hasDouble)
14413      qs = doubleQuotedString;
14414    else
14415      qs = singleQuote ? singleQuotedString : doubleQuotedString;
14416  }
14417  return qs(value, ctx);
14418}
14419var blockEndNewlines;
14420try {
14421  blockEndNewlines = new RegExp("(^|(?<!\n))\n+(?!\n|$)", "g");
14422} catch (e) {
14423  blockEndNewlines = /\n+(?!\n|$)/g;
14424}
14425function blockString({ comment, type, value }, ctx, onComment, onChompKeep) {
14426  const { blockQuote, commentString, lineWidth } = ctx.options;
14427  if (!blockQuote || /\n[\t ]+$/.test(value)) {
14428    return quotedString(value, ctx);
14429  }
14430  const indent = ctx.indent || (ctx.forceBlockIndent || containsDocumentMarker(value) ? "  " : "");
14431  const literal = blockQuote === "literal" ? true : blockQuote === "folded" || type === Scalar.BLOCK_FOLDED ? false : type === Scalar.BLOCK_LITERAL ? true : !lineLengthOverLimit(value, lineWidth, indent.length);
14432  if (!value)
14433    return literal ? "|\n" : ">\n";
14434  let chomp;
14435  let endStart;
14436  for (endStart = value.length; endStart > 0; --endStart) {
14437    const ch = value[endStart - 1];
14438    if (ch !== "\n" && ch !== "	" && ch !== " ")
14439      break;
14440  }
14441  let end = value.substring(endStart);
14442  const endNlPos = end.indexOf("\n");
14443  if (endNlPos === -1) {
14444    chomp = "-";
14445  } else if (value === end || endNlPos !== end.length - 1) {
14446    chomp = "+";
14447    if (onChompKeep)
14448      onChompKeep();
14449  } else {
14450    chomp = "";
14451  }
14452  if (end) {
14453    value = value.slice(0, -end.length);
14454    if (end[end.length - 1] === "\n")
14455      end = end.slice(0, -1);
14456    end = end.replace(blockEndNewlines, `$&${indent}`);
14457  }
14458  let startWithSpace = false;
14459  let startEnd;
14460  let startNlPos = -1;
14461  for (startEnd = 0; startEnd < value.length; ++startEnd) {
14462    const ch = value[startEnd];
14463    if (ch === " ")
14464      startWithSpace = true;
14465    else if (ch === "\n")
14466      startNlPos = startEnd;
14467    else
14468      break;
14469  }
14470  let start = value.substring(0, startNlPos < startEnd ? startNlPos + 1 : startEnd);
14471  if (start) {
14472    value = value.substring(start.length);
14473    start = start.replace(/\n+/g, `$&${indent}`);
14474  }
14475  const indentSize = indent ? "2" : "1";
14476  let header = (startWithSpace ? indentSize : "") + chomp;
14477  if (comment) {
14478    header += " " + commentString(comment.replace(/ ?[\r\n]+/g, " "));
14479    if (onComment)
14480      onComment();
14481  }
14482  if (!literal) {
14483    const foldedValue = value.replace(/\n+/g, "\n$&").replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g, "$1$2").replace(/\n+/g, `$&${indent}`);
14484    let literalFallback = false;
14485    const foldOptions = getFoldOptions(ctx, true);
14486    if (blockQuote !== "folded" && type !== Scalar.BLOCK_FOLDED) {
14487      foldOptions.onOverflow = () => {
14488        literalFallback = true;
14489      };
14490    }
14491    const body = foldFlowLines(`${start}${foldedValue}${end}`, indent, FOLD_BLOCK, foldOptions);
14492    if (!literalFallback)
14493      return `>${header}
14494${indent}${body}`;
14495  }
14496  value = value.replace(/\n+/g, `$&${indent}`);
14497  return `|${header}
14498${indent}${start}${value}${end}`;
14499}
14500function plainString(item, ctx, onComment, onChompKeep) {
14501  const { type, value } = item;
14502  const { actualString, implicitKey, indent, indentStep, inFlow } = ctx;
14503  if (implicitKey && value.includes("\n") || inFlow && /[[\]{},]/.test(value)) {
14504    return quotedString(value, ctx);
14505  }
14506  if (/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(value)) {
14507    return implicitKey || inFlow || !value.includes("\n") ? quotedString(value, ctx) : blockString(item, ctx, onComment, onChompKeep);
14508  }
14509  if (!implicitKey && !inFlow && type !== Scalar.PLAIN && value.includes("\n")) {
14510    return blockString(item, ctx, onComment, onChompKeep);
14511  }
14512  if (containsDocumentMarker(value)) {
14513    if (indent === "") {
14514      ctx.forceBlockIndent = true;
14515      return blockString(item, ctx, onComment, onChompKeep);
14516    } else if (implicitKey && indent === indentStep) {
14517      return quotedString(value, ctx);
14518    }
14519  }
14520  const str = value.replace(/\n+/g, `$&
14521${indent}`);
14522  if (actualString) {
14523    const test = (tag) => {
14524      var _a2;
14525      return tag.default && tag.tag !== "tag:yaml.org,2002:str" && ((_a2 = tag.test) == null ? void 0 : _a2.test(str));
14526    };
14527    const { compat, tags } = ctx.doc.schema;
14528    if (tags.some(test) || (compat == null ? void 0 : compat.some(test)))
14529      return quotedString(value, ctx);
14530  }
14531  return implicitKey ? str : foldFlowLines(str, indent, FOLD_FLOW, getFoldOptions(ctx, false));
14532}
14533function stringifyString(item, ctx, onComment, onChompKeep) {
14534  const { implicitKey, inFlow } = ctx;
14535  const ss = typeof item.value === "string" ? item : Object.assign({}, item, { value: String(item.value) });
14536  let { type } = item;
14537  if (type !== Scalar.QUOTE_DOUBLE) {
14538    if (/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(ss.value))
14539      type = Scalar.QUOTE_DOUBLE;
14540  }
14541  const _stringify = (_type) => {
14542    switch (_type) {
14543      case Scalar.BLOCK_FOLDED:
14544      case Scalar.BLOCK_LITERAL:
14545        return implicitKey || inFlow ? quotedString(ss.value, ctx) : blockString(ss, ctx, onComment, onChompKeep);
14546      case Scalar.QUOTE_DOUBLE:
14547        return doubleQuotedString(ss.value, ctx);
14548      case Scalar.QUOTE_SINGLE:
14549        return singleQuotedString(ss.value, ctx);
14550      case Scalar.PLAIN:
14551        return plainString(ss, ctx, onComment, onChompKeep);
14552      default:
14553        return null;
14554    }
14555  };
14556  let res = _stringify(type);
14557  if (res === null) {
14558    const { defaultKeyType, defaultStringType } = ctx.options;
14559    const t3 = implicitKey && defaultKeyType || defaultStringType;
14560    res = _stringify(t3);
14561    if (res === null)
14562      throw new Error(`Unsupported default string type ${t3}`);
14563  }
14564  return res;
14565}
14566
14567// node_modules/yaml/browser/dist/stringify/stringify.js
14568function createStringifyContext(doc, options) {
14569  const opt = Object.assign({
14570    blockQuote: true,
14571    commentString: stringifyComment,
14572    defaultKeyType: null,
14573    defaultStringType: "PLAIN",
14574    directives: null,
14575    doubleQuotedAsJSON: false,
14576    doubleQuotedMinMultiLineLength: 40,
14577    falseStr: "false",
14578    flowCollectionPadding: true,
14579    indentSeq: true,
14580    lineWidth: 80,
14581    minContentWidth: 20,
14582    nullStr: "null",
14583    simpleKeys: false,
14584    singleQuote: null,
14585    trueStr: "true",
14586    verifyAliasOrder: true
14587  }, doc.schema.toStringOptions, options);
14588  let inFlow;
14589  switch (opt.collectionStyle) {
14590    case "block":
14591      inFlow = false;
14592      break;
14593    case "flow":
14594      inFlow = true;
14595      break;
14596    default:
14597      inFlow = null;
14598  }
14599  return {
14600    anchors: /* @__PURE__ */ new Set(),
14601    doc,
14602    flowCollectionPadding: opt.flowCollectionPadding ? " " : "",
14603    indent: "",
14604    indentStep: typeof opt.indent === "number" ? " ".repeat(opt.indent) : "  ",
14605    inFlow,
14606    options: opt
14607  };
14608}
14609function getTagObject(tags, item) {
14610  var _a2, _b2, _c, _d;
14611  if (item.tag) {
14612    const match = tags.filter((t3) => t3.tag === item.tag);
14613    if (match.length > 0)
14614      return (_a2 = match.find((t3) => t3.format === item.format)) != null ? _a2 : match[0];
14615  }
14616  let tagObj = void 0;
14617  let obj;
14618  if (isScalar(item)) {
14619    obj = item.value;
14620    let match = tags.filter((t3) => {
14621      var _a3;
14622      return (_a3 = t3.identify) == null ? void 0 : _a3.call(t3, obj);
14623    });
14624    if (match.length > 1) {
14625      const testMatch = match.filter((t3) => t3.test);
14626      if (testMatch.length > 0)
14627        match = testMatch;
14628    }
14629    tagObj = (_b2 = match.find((t3) => t3.format === item.format)) != null ? _b2 : match.find((t3) => !t3.format);
14630  } else {
14631    obj = item;
14632    tagObj = tags.find((t3) => t3.nodeClass && obj instanceof t3.nodeClass);
14633  }
14634  if (!tagObj) {
14635    const name = (_d = (_c = obj == null ? void 0 : obj.constructor) == null ? void 0 : _c.name) != null ? _d : obj === null ? "null" : typeof obj;
14636    throw new Error(`Tag not resolved for ${name} value`);
14637  }
14638  return tagObj;
14639}
14640function stringifyProps(node, tagObj, { anchors, doc }) {
14641  var _a2;
14642  if (!doc.directives)
14643    return "";
14644  const props = [];
14645  const anchor = (isScalar(node) || isCollection(node)) && node.anchor;
14646  if (anchor && anchorIsValid(anchor)) {
14647    anchors.add(anchor);
14648    props.push(`&${anchor}`);
14649  }
14650  const tag = (_a2 = node.tag) != null ? _a2 : tagObj.default ? null : tagObj.tag;
14651  if (tag)
14652    props.push(doc.directives.tagString(tag));
14653  return props.join(" ");
14654}
14655function stringify(item, ctx, onComment, onChompKeep) {
14656  var _a2, _b2;
14657  if (isPair(item))
14658    return item.toString(ctx, onComment, onChompKeep);
14659  if (isAlias(item)) {
14660    if (ctx.doc.directives)
14661      return item.toString(ctx);
14662    if ((_a2 = ctx.resolvedAliases) == null ? void 0 : _a2.has(item)) {
14663      throw new TypeError(`Cannot stringify circular structure without alias nodes`);
14664    } else {
14665      if (ctx.resolvedAliases)
14666        ctx.resolvedAliases.add(item);
14667      else
14668        ctx.resolvedAliases = /* @__PURE__ */ new Set([item]);
14669      item = item.resolve(ctx.doc);
14670    }
14671  }
14672  let tagObj = void 0;
14673  const node = isNode(item) ? item : ctx.doc.createNode(item, { onTagObj: (o3) => tagObj = o3 });
14674  tagObj != null ? tagObj : tagObj = getTagObject(ctx.doc.schema.tags, node);
14675  const props = stringifyProps(node, tagObj, ctx);
14676  if (props.length > 0)
14677    ctx.indentAtStart = ((_b2 = ctx.indentAtStart) != null ? _b2 : 0) + props.length + 1;
14678  const str = typeof tagObj.stringify === "function" ? tagObj.stringify(node, ctx, onComment, onChompKeep) : isScalar(node) ? stringifyString(node, ctx, onComment, onChompKeep) : node.toString(ctx, onComment, onChompKeep);
14679  if (!props)
14680    return str;
14681  return isScalar(node) || str[0] === "{" || str[0] === "[" ? `${props} ${str}` : `${props}
14682${ctx.indent}${str}`;
14683}
14684
14685// node_modules/yaml/browser/dist/stringify/stringifyPair.js
14686function stringifyPair({ key, value }, ctx, onComment, onChompKeep) {
14687  var _a2, _b2;
14688  const { allNullValues, doc, indent, indentStep, options: { commentString, indentSeq, simpleKeys } } = ctx;
14689  let keyComment = isNode(key) && key.comment || null;
14690  if (simpleKeys) {
14691    if (keyComment) {
14692      throw new Error("With simple keys, key nodes cannot have comments");
14693    }
14694    if (isCollection(key) || !isNode(key) && typeof key === "object") {
14695      const msg = "With simple keys, collection cannot be used as a key value";
14696      throw new Error(msg);
14697    }
14698  }
14699  let explicitKey = !simpleKeys && (!key || keyComment && value == null && !ctx.inFlow || isCollection(key) || (isScalar(key) ? key.type === Scalar.BLOCK_FOLDED || key.type === Scalar.BLOCK_LITERAL : typeof key === "object"));
14700  ctx = Object.assign({}, ctx, {
14701    allNullValues: false,
14702    implicitKey: !explicitKey && (simpleKeys || !allNullValues),
14703    indent: indent + indentStep
14704  });
14705  let keyCommentDone = false;
14706  let chompKeep = false;
14707  let str = stringify(key, ctx, () => keyCommentDone = true, () => chompKeep = true);
14708  if (!explicitKey && !ctx.inFlow && str.length > 1024) {
14709    if (simpleKeys)
14710      throw new Error("With simple keys, single line scalar must not span more than 1024 characters");
14711    explicitKey = true;
14712  }
14713  if (ctx.inFlow) {
14714    if (allNullValues || value == null) {
14715      if (keyCommentDone && onComment)
14716        onComment();
14717      return str === "" ? "?" : explicitKey ? `? ${str}` : str;
14718    }
14719  } else if (allNullValues && !simpleKeys || value == null && explicitKey) {
14720    str = `? ${str}`;
14721    if (keyComment && !keyCommentDone) {
14722      str += lineComment(str, ctx.indent, commentString(keyComment));
14723    } else if (chompKeep && onChompKeep)
14724      onChompKeep();
14725    return str;
14726  }
14727  if (keyCommentDone)
14728    keyComment = null;
14729  if (explicitKey) {
14730    if (keyComment)
14731      str += lineComment(str, ctx.indent, commentString(keyComment));
14732    str = `? ${str}
14733${indent}:`;
14734  } else {
14735    str = `${str}:`;
14736    if (keyComment)
14737      str += lineComment(str, ctx.indent, commentString(keyComment));
14738  }
14739  let vsb, vcb, valueComment;
14740  if (isNode(value)) {
14741    vsb = !!value.spaceBefore;
14742    vcb = value.commentBefore;
14743    valueComment = value.comment;
14744  } else {
14745    vsb = false;
14746    vcb = null;
14747    valueComment = null;
14748    if (value && typeof value === "object")
14749      value = doc.createNode(value);
14750  }
14751  ctx.implicitKey = false;
14752  if (!explicitKey && !keyComment && isScalar(value))
14753    ctx.indentAtStart = str.length + 1;
14754  chompKeep = false;
14755  if (!indentSeq && indentStep.length >= 2 && !ctx.inFlow && !explicitKey && isSeq(value) && !value.flow && !value.tag && !value.anchor) {
14756    ctx.indent = ctx.indent.substring(2);
14757  }
14758  let valueCommentDone = false;
14759  const valueStr = stringify(value, ctx, () => valueCommentDone = true, () => chompKeep = true);
14760  let ws = " ";
14761  if (keyComment || vsb || vcb) {
14762    ws = vsb ? "\n" : "";
14763    if (vcb) {
14764      const cs = commentString(vcb);
14765      ws += `
14766${indentComment(cs, ctx.indent)}`;
14767    }
14768    if (valueStr === "" && !ctx.inFlow) {
14769      if (ws === "\n")
14770        ws = "\n\n";
14771    } else {
14772      ws += `
14773${ctx.indent}`;
14774    }
14775  } else if (!explicitKey && isCollection(value)) {
14776    const vs0 = valueStr[0];
14777    const nl0 = valueStr.indexOf("\n");
14778    const hasNewline = nl0 !== -1;
14779    const flow = (_b2 = (_a2 = ctx.inFlow) != null ? _a2 : value.flow) != null ? _b2 : value.items.length === 0;
14780    if (hasNewline || !flow) {
14781      let hasPropsLine = false;
14782      if (hasNewline && (vs0 === "&" || vs0 === "!")) {
14783        let sp0 = valueStr.indexOf(" ");
14784        if (vs0 === "&" && sp0 !== -1 && sp0 < nl0 && valueStr[sp0 + 1] === "!") {
14785          sp0 = valueStr.indexOf(" ", sp0 + 1);
14786        }
14787        if (sp0 === -1 || nl0 < sp0)
14788          hasPropsLine = true;
14789      }
14790      if (!hasPropsLine)
14791        ws = `
14792${ctx.indent}`;
14793    }
14794  } else if (valueStr === "" || valueStr[0] === "\n") {
14795    ws = "";
14796  }
14797  str += ws + valueStr;
14798  if (ctx.inFlow) {
14799    if (valueCommentDone && onComment)
14800      onComment();
14801  } else if (valueComment && !valueCommentDone) {
14802    str += lineComment(str, ctx.indent, commentString(valueComment));
14803  } else if (chompKeep && onChompKeep) {
14804    onChompKeep();
14805  }
14806  return str;
14807}
14808
14809// node_modules/yaml/browser/dist/log.js
14810function warn(logLevel, warning) {
14811  if (logLevel === "debug" || logLevel === "warn") {
14812    console.warn(warning);
14813  }
14814}
14815
14816// node_modules/yaml/browser/dist/schema/yaml-1.1/merge.js
14817var MERGE_KEY = "<<";
14818var merge = {
14819  identify: (value) => value === MERGE_KEY || typeof value === "symbol" && value.description === MERGE_KEY,
14820  default: "key",
14821  tag: "tag:yaml.org,2002:merge",
14822  test: /^<<$/,
14823  resolve: () => Object.assign(new Scalar(Symbol(MERGE_KEY)), {
14824    addToJSMap: addMergeToJSMap
14825  }),
14826  stringify: () => MERGE_KEY
14827};
14828var isMergeKey = (ctx, key) => (merge.identify(key) || isScalar(key) && (!key.type || key.type === Scalar.PLAIN) && merge.identify(key.value)) && (ctx == null ? void 0 : ctx.doc.schema.tags.some((tag) => tag.tag === merge.tag && tag.default));
14829function addMergeToJSMap(ctx, map2, value) {
14830  value = ctx && isAlias(value) ? value.resolve(ctx.doc) : value;
14831  if (isSeq(value))
14832    for (const it of value.items)
14833      mergeValue(ctx, map2, it);
14834  else if (Array.isArray(value))
14835    for (const it of value)
14836      mergeValue(ctx, map2, it);
14837  else
14838    mergeValue(ctx, map2, value);
14839}
14840function mergeValue(ctx, map2, value) {
14841  const source = ctx && isAlias(value) ? value.resolve(ctx.doc) : value;
14842  if (!isMap(source))
14843    throw new Error("Merge sources must be maps or map aliases");
14844  const srcMap = source.toJSON(null, ctx, Map);
14845  for (const [key, value2] of srcMap) {
14846    if (map2 instanceof Map) {
14847      if (!map2.has(key))
14848        map2.set(key, value2);
14849    } else if (map2 instanceof Set) {
14850      map2.add(key);
14851    } else if (!Object.prototype.hasOwnProperty.call(map2, key)) {
14852      Object.defineProperty(map2, key, {
14853        value: value2,
14854        writable: true,
14855        enumerable: true,
14856        configurable: true
14857      });
14858    }
14859  }
14860  return map2;
14861}
14862
14863// node_modules/yaml/browser/dist/nodes/addPairToJSMap.js
14864function addPairToJSMap(ctx, map2, { key, value }) {
14865  if (isNode(key) && key.addToJSMap)
14866    key.addToJSMap(ctx, map2, value);
14867  else if (isMergeKey(ctx, key))
14868    addMergeToJSMap(ctx, map2, value);
14869  else {
14870    const jsKey = toJS(key, "", ctx);
14871    if (map2 instanceof Map) {
14872      map2.set(jsKey, toJS(value, jsKey, ctx));
14873    } else if (map2 instanceof Set) {
14874      map2.add(jsKey);
14875    } else {
14876      const stringKey = stringifyKey(key, jsKey, ctx);
14877      const jsValue = toJS(value, stringKey, ctx);
14878      if (stringKey in map2)
14879        Object.defineProperty(map2, stringKey, {
14880          value: jsValue,
14881          writable: true,
14882          enumerable: true,
14883          configurable: true
14884        });
14885      else
14886        map2[stringKey] = jsValue;
14887    }
14888  }
14889  return map2;
14890}
14891function stringifyKey(key, jsKey, ctx) {
14892  if (jsKey === null)
14893    return "";
14894  if (typeof jsKey !== "object")
14895    return String(jsKey);
14896  if (isNode(key) && (ctx == null ? void 0 : ctx.doc)) {
14897    const strCtx = createStringifyContext(ctx.doc, {});
14898    strCtx.anchors = /* @__PURE__ */ new Set();
14899    for (const node of ctx.anchors.keys())
14900      strCtx.anchors.add(node.anchor);
14901    strCtx.inFlow = true;
14902    strCtx.inStringifyKey = true;
14903    const strKey = key.toString(strCtx);
14904    if (!ctx.mapKeyWarned) {
14905      let jsonStr = JSON.stringify(strKey);
14906      if (jsonStr.length > 40)
14907        jsonStr = jsonStr.substring(0, 36) + '..."';
14908      warn(ctx.doc.options.logLevel, `Keys with collection values will be stringified due to JS Object restrictions: ${jsonStr}. Set mapAsMap: true to use object keys.`);
14909      ctx.mapKeyWarned = true;
14910    }
14911    return strKey;
14912  }
14913  return JSON.stringify(jsKey);
14914}
14915
14916// node_modules/yaml/browser/dist/nodes/Pair.js
14917function createPair(key, value, ctx) {
14918  const k2 = createNode(key, void 0, ctx);
14919  const v2 = createNode(value, void 0, ctx);
14920  return new Pair(k2, v2);
14921}
14922var Pair = class _Pair {
14923  constructor(key, value = null) {
14924    Object.defineProperty(this, NODE_TYPE, { value: PAIR });
14925    this.key = key;
14926    this.value = value;
14927  }
14928  clone(schema4) {
14929    let { key, value } = this;
14930    if (isNode(key))
14931      key = key.clone(schema4);
14932    if (isNode(value))
14933      value = value.clone(schema4);
14934    return new _Pair(key, value);
14935  }
14936  toJSON(_, ctx) {
14937    const pair = (ctx == null ? void 0 : ctx.mapAsMap) ? /* @__PURE__ */ new Map() : {};
14938    return addPairToJSMap(ctx, pair, this);
14939  }
14940  toString(ctx, onComment, onChompKeep) {
14941    return (ctx == null ? void 0 : ctx.doc) ? stringifyPair(this, ctx, onComment, onChompKeep) : JSON.stringify(this);
14942  }
14943};
14944
14945// node_modules/yaml/browser/dist/stringify/stringifyCollection.js
14946function stringifyCollection(collection, ctx, options) {
14947  var _a2;
14948  const flow = (_a2 = ctx.inFlow) != null ? _a2 : collection.flow;
14949  const stringify6 = flow ? stringifyFlowCollection : stringifyBlockCollection;
14950  return stringify6(collection, ctx, options);
14951}
14952function stringifyBlockCollection({ comment, items }, ctx, { blockItemPrefix, flowChars, itemIndent, onChompKeep, onComment }) {
14953  const { indent, options: { commentString } } = ctx;
14954  const itemCtx = Object.assign({}, ctx, { indent: itemIndent, type: null });
14955  let chompKeep = false;
14956  const lines = [];
14957  for (let i = 0; i < items.length; ++i) {
14958    const item = items[i];
14959    let comment2 = null;
14960    if (isNode(item)) {
14961      if (!chompKeep && item.spaceBefore)
14962        lines.push("");
14963      addCommentBefore(ctx, lines, item.commentBefore, chompKeep);
14964      if (item.comment)
14965        comment2 = item.comment;
14966    } else if (isPair(item)) {
14967      const ik = isNode(item.key) ? item.key : null;
14968      if (ik) {
14969        if (!chompKeep && ik.spaceBefore)
14970          lines.push("");
14971        addCommentBefore(ctx, lines, ik.commentBefore, chompKeep);
14972      }
14973    }
14974    chompKeep = false;
14975    let str2 = stringify(item, itemCtx, () => comment2 = null, () => chompKeep = true);
14976    if (comment2)
14977      str2 += lineComment(str2, itemIndent, commentString(comment2));
14978    if (chompKeep && comment2)
14979      chompKeep = false;
14980    lines.push(blockItemPrefix + str2);
14981  }
14982  let str;
14983  if (lines.length === 0) {
14984    str = flowChars.start + flowChars.end;
14985  } else {
14986    str = lines[0];
14987    for (let i = 1; i < lines.length; ++i) {
14988      const line = lines[i];
14989      str += line ? `
14990${indent}${line}` : "\n";
14991    }
14992  }
14993  if (comment) {
14994    str += "\n" + indentComment(commentString(comment), indent);
14995    if (onComment)
14996      onComment();
14997  } else if (chompKeep && onChompKeep)
14998    onChompKeep();
14999  return str;
15000}
15001function stringifyFlowCollection({ items }, ctx, { flowChars, itemIndent }) {
15002  const { indent, indentStep, flowCollectionPadding: fcPadding, options: { commentString } } = ctx;
15003  itemIndent += indentStep;
15004  const itemCtx = Object.assign({}, ctx, {
15005    indent: itemIndent,
15006    inFlow: true,
15007    type: null
15008  });
15009  let reqNewline = false;
15010  let linesAtValue = 0;
15011  const lines = [];
15012  for (let i = 0; i < items.length; ++i) {
15013    const item = items[i];
15014    let comment = null;
15015    if (isNode(item)) {
15016      if (item.spaceBefore)
15017        lines.push("");
15018      addCommentBefore(ctx, lines, item.commentBefore, false);
15019      if (item.comment)
15020        comment = item.comment;
15021    } else if (isPair(item)) {
15022      const ik = isNode(item.key) ? item.key : null;
15023      if (ik) {
15024        if (ik.spaceBefore)
15025          lines.push("");
15026        addCommentBefore(ctx, lines, ik.commentBefore, false);
15027        if (ik.comment)
15028          reqNewline = true;
15029      }
15030      const iv = isNode(item.value) ? item.value : null;
15031      if (iv) {
15032        if (iv.comment)
15033          comment = iv.comment;
15034        if (iv.commentBefore)
15035          reqNewline = true;
15036      } else if (item.value == null && (ik == null ? void 0 : ik.comment)) {
15037        comment = ik.comment;
15038      }
15039    }
15040    if (comment)
15041      reqNewline = true;
15042    let str = stringify(item, itemCtx, () => comment = null);
15043    if (i < items.length - 1)
15044      str += ",";
15045    if (comment)
15046      str += lineComment(str, itemIndent, commentString(comment));
15047    if (!reqNewline && (lines.length > linesAtValue || str.includes("\n")))
15048      reqNewline = true;
15049    lines.push(str);
15050    linesAtValue = lines.length;
15051  }
15052  const { start, end } = flowChars;
15053  if (lines.length === 0) {
15054    return start + end;
15055  } else {
15056    if (!reqNewline) {
15057      const len = lines.reduce((sum, line) => sum + line.length + 2, 2);
15058      reqNewline = ctx.options.lineWidth > 0 && len > ctx.options.lineWidth;
15059    }
15060    if (reqNewline) {
15061      let str = start;
15062      for (const line of lines)
15063        str += line ? `
15064${indentStep}${indent}${line}` : "\n";
15065      return `${str}
15066${indent}${end}`;
15067    } else {
15068      return `${start}${fcPadding}${lines.join(" ")}${fcPadding}${end}`;
15069    }
15070  }
15071}
15072function addCommentBefore({ indent, options: { commentString } }, lines, comment, chompKeep) {
15073  if (comment && chompKeep)
15074    comment = comment.replace(/^\n+/, "");
15075  if (comment) {
15076    const ic = indentComment(commentString(comment), indent);
15077    lines.push(ic.trimStart());
15078  }
15079}
15080
15081// node_modules/yaml/browser/dist/nodes/YAMLMap.js
15082function findPair(items, key) {
15083  const k2 = isScalar(key) ? key.value : key;
15084  for (const it of items) {
15085    if (isPair(it)) {
15086      if (it.key === key || it.key === k2)
15087        return it;
15088      if (isScalar(it.key) && it.key.value === k2)
15089        return it;
15090    }
15091  }
15092  return void 0;
15093}
15094var YAMLMap = class extends Collection {
15095  static get tagName() {
15096    return "tag:yaml.org,2002:map";
15097  }
15098  constructor(schema4) {
15099    super(MAP, schema4);
15100    this.items = [];
15101  }
15102  /**
15103   * A generic collection parsing method that can be extended
15104   * to other node classes that inherit from YAMLMap
15105   */
15106  static from(schema4, obj, ctx) {
15107    const { keepUndefined, replacer } = ctx;
15108    const map2 = new this(schema4);
15109    const add = (key, value) => {
15110      if (typeof replacer === "function")
15111        value = replacer.call(obj, key, value);
15112      else if (Array.isArray(replacer) && !replacer.includes(key))
15113        return;
15114      if (value !== void 0 || keepUndefined)
15115        map2.items.push(createPair(key, value, ctx));
15116    };
15117    if (obj instanceof Map) {
15118      for (const [key, value] of obj)
15119        add(key, value);
15120    } else if (obj && typeof obj === "object") {
15121      for (const key of Object.keys(obj))
15122        add(key, obj[key]);
15123    }
15124    if (typeof schema4.sortMapEntries === "function") {
15125      map2.items.sort(schema4.sortMapEntries);
15126    }
15127    return map2;
15128  }
15129  /**
15130   * Adds a value to the collection.
15131   *
15132   * @param overwrite - If not set `true`, using a key that is already in the
15133   *   collection will throw. Otherwise, overwrites the previous value.
15134   */
15135  add(pair, overwrite) {
15136    var _a2;
15137    let _pair;
15138    if (isPair(pair))
15139      _pair = pair;
15140    else if (!pair || typeof pair !== "object" || !("key" in pair)) {
15141      _pair = new Pair(pair, pair == null ? void 0 : pair.value);
15142    } else
15143      _pair = new Pair(pair.key, pair.value);
15144    const prev = findPair(this.items, _pair.key);
15145    const sortEntries = (_a2 = this.schema) == null ? void 0 : _a2.sortMapEntries;
15146    if (prev) {
15147      if (!overwrite)
15148        throw new Error(`Key ${_pair.key} already set`);
15149      if (isScalar(prev.value) && isScalarValue(_pair.value))
15150        prev.value.value = _pair.value;
15151      else
15152        prev.value = _pair.value;
15153    } else if (sortEntries) {
15154      const i = this.items.findIndex((item) => sortEntries(_pair, item) < 0);
15155      if (i === -1)
15156        this.items.push(_pair);
15157      else
15158        this.items.splice(i, 0, _pair);
15159    } else {
15160      this.items.push(_pair);
15161    }
15162  }
15163  delete(key) {
15164    const it = findPair(this.items, key);
15165    if (!it)
15166      return false;
15167    const del = this.items.splice(this.items.indexOf(it), 1);
15168    return del.length > 0;
15169  }
15170  get(key, keepScalar) {
15171    var _a2;
15172    const it = findPair(this.items, key);
15173    const node = it == null ? void 0 : it.value;
15174    return (_a2 = !keepScalar && isScalar(node) ? node.value : node) != null ? _a2 : void 0;
15175  }
15176  has(key) {
15177    return !!findPair(this.items, key);
15178  }
15179  set(key, value) {
15180    this.add(new Pair(key, value), true);
15181  }
15182  /**
15183   * @param ctx - Conversion context, originally set in Document#toJS()
15184   * @param {Class} Type - If set, forces the returned collection type
15185   * @returns Instance of Type, Map, or Object
15186   */
15187  toJSON(_, ctx, Type) {
15188    const map2 = Type ? new Type() : (ctx == null ? void 0 : ctx.mapAsMap) ? /* @__PURE__ */ new Map() : {};
15189    if (ctx == null ? void 0 : ctx.onCreate)
15190      ctx.onCreate(map2);
15191    for (const item of this.items)
15192      addPairToJSMap(ctx, map2, item);
15193    return map2;
15194  }
15195  toString(ctx, onComment, onChompKeep) {
15196    if (!ctx)
15197      return JSON.stringify(this);
15198    for (const item of this.items) {
15199      if (!isPair(item))
15200        throw new Error(`Map items must all be pairs; found ${JSON.stringify(item)} instead`);
15201    }
15202    if (!ctx.allNullValues && this.hasAllNullValues(false))
15203      ctx = Object.assign({}, ctx, { allNullValues: true });
15204    return stringifyCollection(this, ctx, {
15205      blockItemPrefix: "",
15206      flowChars: { start: "{", end: "}" },
15207      itemIndent: ctx.indent || "",
15208      onChompKeep,
15209      onComment
15210    });
15211  }
15212};
15213
15214// node_modules/yaml/browser/dist/schema/common/map.js
15215var map = {
15216  collection: "map",
15217  default: true,
15218  nodeClass: YAMLMap,
15219  tag: "tag:yaml.org,2002:map",
15220  resolve(map2, onError) {
15221    if (!isMap(map2))
15222      onError("Expected a mapping for this tag");
15223    return map2;
15224  },
15225  createNode: (schema4, obj, ctx) => YAMLMap.from(schema4, obj, ctx)
15226};
15227
15228// node_modules/yaml/browser/dist/nodes/YAMLSeq.js
15229var YAMLSeq = class extends Collection {
15230  static get tagName() {
15231    return "tag:yaml.org,2002:seq";
15232  }
15233  constructor(schema4) {
15234    super(SEQ, schema4);
15235    this.items = [];
15236  }
15237  add(value) {
15238    this.items.push(value);
15239  }
15240  /**
15241   * Removes a value from the collection.
15242   *
15243   * `key` must contain a representation of an integer for this to succeed.
15244   * It may be wrapped in a `Scalar`.
15245   *
15246   * @returns `true` if the item was found and removed.
15247   */
15248  delete(key) {
15249    const idx = asItemIndex(key);
15250    if (typeof idx !== "number")
15251      return false;
15252    const del = this.items.splice(idx, 1);
15253    return del.length > 0;
15254  }
15255  get(key, keepScalar) {
15256    const idx = asItemIndex(key);
15257    if (typeof idx !== "number")
15258      return void 0;
15259    const it = this.items[idx];
15260    return !keepScalar && isScalar(it) ? it.value : it;
15261  }
15262  /**
15263   * Checks if the collection includes a value with the key `key`.
15264   *
15265   * `key` must contain a representation of an integer for this to succeed.
15266   * It may be wrapped in a `Scalar`.
15267   */
15268  has(key) {
15269    const idx = asItemIndex(key);
15270    return typeof idx === "number" && idx < this.items.length;
15271  }
15272  /**
15273   * Sets a value in this collection. For `!!set`, `value` needs to be a
15274   * boolean to add/remove the item from the set.
15275   *
15276   * If `key` does not contain a representation of an integer, this will throw.
15277   * It may be wrapped in a `Scalar`.
15278   */
15279  set(key, value) {
15280    const idx = asItemIndex(key);
15281    if (typeof idx !== "number")
15282      throw new Error(`Expected a valid index, not ${key}.`);
15283    const prev = this.items[idx];
15284    if (isScalar(prev) && isScalarValue(value))
15285      prev.value = value;
15286    else
15287      this.items[idx] = value;
15288  }
15289  toJSON(_, ctx) {
15290    const seq2 = [];
15291    if (ctx == null ? void 0 : ctx.onCreate)
15292      ctx.onCreate(seq2);
15293    let i = 0;
15294    for (const item of this.items)
15295      seq2.push(toJS(item, String(i++), ctx));
15296    return seq2;
15297  }
15298  toString(ctx, onComment, onChompKeep) {
15299    if (!ctx)
15300      return JSON.stringify(this);
15301    return stringifyCollection(this, ctx, {
15302      blockItemPrefix: "- ",
15303      flowChars: { start: "[", end: "]" },
15304      itemIndent: (ctx.indent || "") + "  ",
15305      onChompKeep,
15306      onComment
15307    });
15308  }
15309  static from(schema4, obj, ctx) {
15310    const { replacer } = ctx;
15311    const seq2 = new this(schema4);
15312    if (obj && Symbol.iterator in Object(obj)) {
15313      let i = 0;
15314      for (let it of obj) {
15315        if (typeof replacer === "function") {
15316          const key = obj instanceof Set ? it : String(i++);
15317          it = replacer.call(obj, key, it);
15318        }
15319        seq2.items.push(createNode(it, void 0, ctx));
15320      }
15321    }
15322    return seq2;
15323  }
15324};
15325function asItemIndex(key) {
15326  let idx = isScalar(key) ? key.value : key;
15327  if (idx && typeof idx === "string")
15328    idx = Number(idx);
15329  return typeof idx === "number" && Number.isInteger(idx) && idx >= 0 ? idx : null;
15330}
15331
15332// node_modules/yaml/browser/dist/schema/common/seq.js
15333var seq = {
15334  collection: "seq",
15335  default: true,
15336  nodeClass: YAMLSeq,
15337  tag: "tag:yaml.org,2002:seq",
15338  resolve(seq2, onError) {
15339    if (!isSeq(seq2))
15340      onError("Expected a sequence for this tag");
15341    return seq2;
15342  },
15343  createNode: (schema4, obj, ctx) => YAMLSeq.from(schema4, obj, ctx)
15344};
15345
15346// node_modules/yaml/browser/dist/schema/common/string.js
15347var string = {
15348  identify: (value) => typeof value === "string",
15349  default: true,
15350  tag: "tag:yaml.org,2002:str",
15351  resolve: (str) => str,
15352  stringify(item, ctx, onComment, onChompKeep) {
15353    ctx = Object.assign({ actualString: true }, ctx);
15354    return stringifyString(item, ctx, onComment, onChompKeep);
15355  }
15356};
15357
15358// node_modules/yaml/browser/dist/schema/common/null.js
15359var nullTag = {
15360  identify: (value) => value == null,
15361  createNode: () => new Scalar(null),
15362  default: true,
15363  tag: "tag:yaml.org,2002:null",
15364  test: /^(?:~|[Nn]ull|NULL)?$/,
15365  resolve: () => new Scalar(null),
15366  stringify: ({ source }, ctx) => typeof source === "string" && nullTag.test.test(source) ? source : ctx.options.nullStr
15367};
15368
15369// node_modules/yaml/browser/dist/schema/core/bool.js
15370var boolTag = {
15371  identify: (value) => typeof value === "boolean",
15372  default: true,
15373  tag: "tag:yaml.org,2002:bool",
15374  test: /^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,
15375  resolve: (str) => new Scalar(str[0] === "t" || str[0] === "T"),
15376  stringify({ source, value }, ctx) {
15377    if (source && boolTag.test.test(source)) {
15378      const sv = source[0] === "t" || source[0] === "T";
15379      if (value === sv)
15380        return source;
15381    }
15382    return value ? ctx.options.trueStr : ctx.options.falseStr;
15383  }
15384};
15385
15386// node_modules/yaml/browser/dist/stringify/stringifyNumber.js
15387function stringifyNumber({ format, minFractionDigits, tag, value }) {
15388  if (typeof value === "bigint")
15389    return String(value);
15390  const num = typeof value === "number" ? value : Number(value);
15391  if (!isFinite(num))
15392    return isNaN(num) ? ".nan" : num < 0 ? "-.inf" : ".inf";
15393  let n4 = JSON.stringify(value);
15394  if (!format && minFractionDigits && (!tag || tag === "tag:yaml.org,2002:float") && /^\d/.test(n4)) {
15395    let i = n4.indexOf(".");
15396    if (i < 0) {
15397      i = n4.length;
15398      n4 += ".";
15399    }
15400    let d = minFractionDigits - (n4.length - i - 1);
15401    while (d-- > 0)
15402      n4 += "0";
15403  }
15404  return n4;
15405}
15406
15407// node_modules/yaml/browser/dist/schema/core/float.js
15408var floatNaN = {
15409  identify: (value) => typeof value === "number",
15410  default: true,
15411  tag: "tag:yaml.org,2002:float",
15412  test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,
15413  resolve: (str) => str.slice(-3).toLowerCase() === "nan" ? NaN : str[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY,
15414  stringify: stringifyNumber
15415};
15416var floatExp = {
15417  identify: (value) => typeof value === "number",
15418  default: true,
15419  tag: "tag:yaml.org,2002:float",
15420  format: "EXP",
15421  test: /^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,
15422  resolve: (str) => parseFloat(str),
15423  stringify(node) {
15424    const num = Number(node.value);
15425    return isFinite(num) ? num.toExponential() : stringifyNumber(node);
15426  }
15427};
15428var float = {
15429  identify: (value) => typeof value === "number",
15430  default: true,
15431  tag: "tag:yaml.org,2002:float",
15432  test: /^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,
15433  resolve(str) {
15434    const node = new Scalar(parseFloat(str));
15435    const dot = str.indexOf(".");
15436    if (dot !== -1 && str[str.length - 1] === "0")
15437      node.minFractionDigits = str.length - dot - 1;
15438    return node;
15439  },
15440  stringify: stringifyNumber
15441};
15442
15443// node_modules/yaml/browser/dist/schema/core/int.js
15444var intIdentify = (value) => typeof value === "bigint" || Number.isInteger(value);
15445var intResolve = (str, offset, radix, { intAsBigInt }) => intAsBigInt ? BigInt(str) : parseInt(str.substring(offset), radix);
15446function intStringify(node, radix, prefix) {
15447  const { value } = node;
15448  if (intIdentify(value) && value >= 0)
15449    return prefix + value.toString(radix);
15450  return stringifyNumber(node);
15451}
15452var intOct = {
15453  identify: (value) => intIdentify(value) && value >= 0,
15454  default: true,
15455  tag: "tag:yaml.org,2002:int",
15456  format: "OCT",
15457  test: /^0o[0-7]+$/,
15458  resolve: (str, _onError, opt) => intResolve(str, 2, 8, opt),
15459  stringify: (node) => intStringify(node, 8, "0o")
15460};
15461var int = {
15462  identify: intIdentify,
15463  default: true,
15464  tag: "tag:yaml.org,2002:int",
15465  test: /^[-+]?[0-9]+$/,
15466  resolve: (str, _onError, opt) => intResolve(str, 0, 10, opt),
15467  stringify: stringifyNumber
15468};
15469var intHex = {
15470  identify: (value) => intIdentify(value) && value >= 0,
15471  default: true,
15472  tag: "tag:yaml.org,2002:int",
15473  format: "HEX",
15474  test: /^0x[0-9a-fA-F]+$/,
15475  resolve: (str, _onError, opt) => intResolve(str, 2, 16, opt),
15476  stringify: (node) => intStringify(node, 16, "0x")
15477};
15478
15479// node_modules/yaml/browser/dist/schema/core/schema.js
15480var schema = [
15481  map,
15482  seq,
15483  string,
15484  nullTag,
15485  boolTag,
15486  intOct,
15487  int,
15488  intHex,
15489  floatNaN,
15490  floatExp,
15491  float
15492];
15493
15494// node_modules/yaml/browser/dist/schema/json/schema.js
15495function intIdentify2(value) {
15496  return typeof value === "bigint" || Number.isInteger(value);
15497}
15498var stringifyJSON = ({ value }) => JSON.stringify(value);
15499var jsonScalars = [
15500  {
15501    identify: (value) => typeof value === "string",
15502    default: true,
15503    tag: "tag:yaml.org,2002:str",
15504    resolve: (str) => str,
15505    stringify: stringifyJSON
15506  },
15507  {
15508    identify: (value) => value == null,
15509    createNode: () => new Scalar(null),
15510    default: true,
15511    tag: "tag:yaml.org,2002:null",
15512    test: /^null$/,
15513    resolve: () => null,
15514    stringify: stringifyJSON
15515  },
15516  {
15517    identify: (value) => typeof value === "boolean",
15518    default: true,
15519    tag: "tag:yaml.org,2002:bool",
15520    test: /^true$|^false$/,
15521    resolve: (str) => str === "true",
15522    stringify: stringifyJSON
15523  },
15524  {
15525    identify: intIdentify2,
15526    default: true,
15527    tag: "tag:yaml.org,2002:int",
15528    test: /^-?(?:0|[1-9][0-9]*)$/,
15529    resolve: (str, _onError, { intAsBigInt }) => intAsBigInt ? BigInt(str) : parseInt(str, 10),
15530    stringify: ({ value }) => intIdentify2(value) ? value.toString() : JSON.stringify(value)
15531  },
15532  {
15533    identify: (value) => typeof value === "number",
15534    default: true,
15535    tag: "tag:yaml.org,2002:float",
15536    test: /^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,
15537    resolve: (str) => parseFloat(str),
15538    stringify: stringifyJSON
15539  }
15540];
15541var jsonError = {
15542  default: true,
15543  tag: "",
15544  test: /^/,
15545  resolve(str, onError) {
15546    onError(`Unresolved plain scalar ${JSON.stringify(str)}`);
15547    return str;
15548  }
15549};
15550var schema2 = [map, seq].concat(jsonScalars, jsonError);
15551
15552// node_modules/yaml/browser/dist/schema/yaml-1.1/binary.js
15553var binary = {
15554  identify: (value) => value instanceof Uint8Array,
15555  // Buffer inherits from Uint8Array
15556  default: false,
15557  tag: "tag:yaml.org,2002:binary",
15558  /**
15559   * Returns a Buffer in node and an Uint8Array in browsers
15560   *
15561   * To use the resulting buffer as an image, you'll want to do something like:
15562   *
15563   *   const blob = new Blob([buffer], { type: 'image/jpeg' })
15564   *   document.querySelector('#photo').src = URL.createObjectURL(blob)
15565   */
15566  resolve(src, onError) {
15567    if (typeof atob === "function") {
15568      const str = atob(src.replace(/[\n\r]/g, ""));
15569      const buffer = new Uint8Array(str.length);
15570      for (let i = 0; i < str.length; ++i)
15571        buffer[i] = str.charCodeAt(i);
15572      return buffer;
15573    } else {
15574      onError("This environment does not support reading binary tags; either Buffer or atob is required");
15575      return src;
15576    }
15577  },
15578  stringify({ comment, type, value }, ctx, onComment, onChompKeep) {
15579    if (!value)
15580      return "";
15581    const buf = value;
15582    let str;
15583    if (typeof btoa === "function") {
15584      let s = "";
15585      for (let i = 0; i < buf.length; ++i)
15586        s += String.fromCharCode(buf[i]);
15587      str = btoa(s);
15588    } else {
15589      throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");
15590    }
15591    type != null ? type : type = Scalar.BLOCK_LITERAL;
15592    if (type !== Scalar.QUOTE_DOUBLE) {
15593      const lineWidth = Math.max(ctx.options.lineWidth - ctx.indent.length, ctx.options.minContentWidth);
15594      const n4 = Math.ceil(str.length / lineWidth);
15595      const lines = new Array(n4);
15596      for (let i = 0, o3 = 0; i < n4; ++i, o3 += lineWidth) {
15597        lines[i] = str.substr(o3, lineWidth);
15598      }
15599      str = lines.join(type === Scalar.BLOCK_LITERAL ? "\n" : " ");
15600    }
15601    return stringifyString({ comment, type, value: str }, ctx, onComment, onChompKeep);
15602  }
15603};
15604
15605// node_modules/yaml/browser/dist/schema/yaml-1.1/pairs.js
15606function resolvePairs(seq2, onError) {
15607  var _a2;
15608  if (isSeq(seq2)) {
15609    for (let i = 0; i < seq2.items.length; ++i) {
15610      let item = seq2.items[i];
15611      if (isPair(item))
15612        continue;
15613      else if (isMap(item)) {
15614        if (item.items.length > 1)
15615          onError("Each pair must have its own sequence indicator");
15616        const pair = item.items[0] || new Pair(new Scalar(null));
15617        if (item.commentBefore)
15618          pair.key.commentBefore = pair.key.commentBefore ? `${item.commentBefore}
15619${pair.key.commentBefore}` : item.commentBefore;
15620        if (item.comment) {
15621          const cn = (_a2 = pair.value) != null ? _a2 : pair.key;
15622          cn.comment = cn.comment ? `${item.comment}
15623${cn.comment}` : item.comment;
15624        }
15625        item = pair;
15626      }
15627      seq2.items[i] = isPair(item) ? item : new Pair(item);
15628    }
15629  } else
15630    onError("Expected a sequence for this tag");
15631  return seq2;
15632}
15633function createPairs(schema4, iterable, ctx) {
15634  const { replacer } = ctx;
15635  const pairs2 = new YAMLSeq(schema4);
15636  pairs2.tag = "tag:yaml.org,2002:pairs";
15637  let i = 0;
15638  if (iterable && Symbol.iterator in Object(iterable))
15639    for (let it of iterable) {
15640      if (typeof replacer === "function")
15641        it = replacer.call(iterable, String(i++), it);
15642      let key, value;
15643      if (Array.isArray(it)) {
15644        if (it.length === 2) {
15645          key = it[0];
15646          value = it[1];
15647        } else
15648          throw new TypeError(`Expected [key, value] tuple: ${it}`);
15649      } else if (it && it instanceof Object) {
15650        const keys = Object.keys(it);
15651        if (keys.length === 1) {
15652          key = keys[0];
15653          value = it[key];
15654        } else {
15655          throw new TypeError(`Expected tuple with one key, not ${keys.length} keys`);
15656        }
15657      } else {
15658        key = it;
15659      }
15660      pairs2.items.push(createPair(key, value, ctx));
15661    }
15662  return pairs2;
15663}
15664var pairs = {
15665  collection: "seq",
15666  default: false,
15667  tag: "tag:yaml.org,2002:pairs",
15668  resolve: resolvePairs,
15669  createNode: createPairs
15670};
15671
15672// node_modules/yaml/browser/dist/schema/yaml-1.1/omap.js
15673var YAMLOMap = class _YAMLOMap extends YAMLSeq {
15674  constructor() {
15675    super();
15676    this.add = YAMLMap.prototype.add.bind(this);
15677    this.delete = YAMLMap.prototype.delete.bind(this);
15678    this.get = YAMLMap.prototype.get.bind(this);
15679    this.has = YAMLMap.prototype.has.bind(this);
15680    this.set = YAMLMap.prototype.set.bind(this);
15681    this.tag = _YAMLOMap.tag;
15682  }
15683  /**
15684   * If `ctx` is given, the return type is actually `Map<unknown, unknown>`,
15685   * but TypeScript won't allow widening the signature of a child method.
15686   */
15687  toJSON(_, ctx) {
15688    if (!ctx)
15689      return super.toJSON(_);
15690    const map2 = /* @__PURE__ */ new Map();
15691    if (ctx == null ? void 0 : ctx.onCreate)
15692      ctx.onCreate(map2);
15693    for (const pair of this.items) {
15694      let key, value;
15695      if (isPair(pair)) {
15696        key = toJS(pair.key, "", ctx);
15697        value = toJS(pair.value, key, ctx);
15698      } else {
15699        key = toJS(pair, "", ctx);
15700      }
15701      if (map2.has(key))
15702        throw new Error("Ordered maps must not include duplicate keys");
15703      map2.set(key, value);
15704    }
15705    return map2;
15706  }
15707  static from(schema4, iterable, ctx) {
15708    const pairs2 = createPairs(schema4, iterable, ctx);
15709    const omap2 = new this();
15710    omap2.items = pairs2.items;
15711    return omap2;
15712  }
15713};
15714YAMLOMap.tag = "tag:yaml.org,2002:omap";
15715var omap = {
15716  collection: "seq",
15717  identify: (value) => value instanceof Map,
15718  nodeClass: YAMLOMap,
15719  default: false,
15720  tag: "tag:yaml.org,2002:omap",
15721  resolve(seq2, onError) {
15722    const pairs2 = resolvePairs(seq2, onError);
15723    const seenKeys = [];
15724    for (const { key } of pairs2.items) {
15725      if (isScalar(key)) {
15726        if (seenKeys.includes(key.value)) {
15727          onError(`Ordered maps must not include duplicate keys: ${key.value}`);
15728        } else {
15729          seenKeys.push(key.value);
15730        }
15731      }
15732    }
15733    return Object.assign(new YAMLOMap(), pairs2);
15734  },
15735  createNode: (schema4, iterable, ctx) => YAMLOMap.from(schema4, iterable, ctx)
15736};
15737
15738// node_modules/yaml/browser/dist/schema/yaml-1.1/bool.js
15739function boolStringify({ value, source }, ctx) {
15740  const boolObj = value ? trueTag : falseTag;
15741  if (source && boolObj.test.test(source))
15742    return source;
15743  return value ? ctx.options.trueStr : ctx.options.falseStr;
15744}
15745var trueTag = {
15746  identify: (value) => value === true,
15747  default: true,
15748  tag: "tag:yaml.org,2002:bool",
15749  test: /^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,
15750  resolve: () => new Scalar(true),
15751  stringify: boolStringify
15752};
15753var falseTag = {
15754  identify: (value) => value === false,
15755  default: true,
15756  tag: "tag:yaml.org,2002:bool",
15757  test: /^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,
15758  resolve: () => new Scalar(false),
15759  stringify: boolStringify
15760};
15761
15762// node_modules/yaml/browser/dist/schema/yaml-1.1/float.js
15763var floatNaN2 = {
15764  identify: (value) => typeof value === "number",
15765  default: true,
15766  tag: "tag:yaml.org,2002:float",
15767  test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,
15768  resolve: (str) => str.slice(-3).toLowerCase() === "nan" ? NaN : str[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY,
15769  stringify: stringifyNumber
15770};
15771var floatExp2 = {
15772  identify: (value) => typeof value === "number",
15773  default: true,
15774  tag: "tag:yaml.org,2002:float",
15775  format: "EXP",
15776  test: /^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,
15777  resolve: (str) => parseFloat(str.replace(/_/g, "")),
15778  stringify(node) {
15779    const num = Number(node.value);
15780    return isFinite(num) ? num.toExponential() : stringifyNumber(node);
15781  }
15782};
15783var float2 = {
15784  identify: (value) => typeof value === "number",
15785  default: true,
15786  tag: "tag:yaml.org,2002:float",
15787  test: /^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,
15788  resolve(str) {
15789    const node = new Scalar(parseFloat(str.replace(/_/g, "")));
15790    const dot = str.indexOf(".");
15791    if (dot !== -1) {
15792      const f2 = str.substring(dot + 1).replace(/_/g, "");
15793      if (f2[f2.length - 1] === "0")
15794        node.minFractionDigits = f2.length;
15795    }
15796    return node;
15797  },
15798  stringify: stringifyNumber
15799};
15800
15801// node_modules/yaml/browser/dist/schema/yaml-1.1/int.js
15802var intIdentify3 = (value) => typeof value === "bigint" || Number.isInteger(value);
15803function intResolve2(str, offset, radix, { intAsBigInt }) {
15804  const sign = str[0];
15805  if (sign === "-" || sign === "+")
15806    offset += 1;
15807  str = str.substring(offset).replace(/_/g, "");
15808  if (intAsBigInt) {
15809    switch (radix) {
15810      case 2:
15811        str = `0b${str}`;
15812        break;
15813      case 8:
15814        str = `0o${str}`;
15815        break;
15816      case 16:
15817        str = `0x${str}`;
15818        break;
15819    }
15820    const n5 = BigInt(str);
15821    return sign === "-" ? BigInt(-1) * n5 : n5;
15822  }
15823  const n4 = parseInt(str, radix);
15824  return sign === "-" ? -1 * n4 : n4;
15825}
15826function intStringify2(node, radix, prefix) {
15827  const { value } = node;
15828  if (intIdentify3(value)) {
15829    const str = value.toString(radix);
15830    return value < 0 ? "-" + prefix + str.substr(1) : prefix + str;
15831  }
15832  return stringifyNumber(node);
15833}
15834var intBin = {
15835  identify: intIdentify3,
15836  default: true,
15837  tag: "tag:yaml.org,2002:int",
15838  format: "BIN",
15839  test: /^[-+]?0b[0-1_]+$/,
15840  resolve: (str, _onError, opt) => intResolve2(str, 2, 2, opt),
15841  stringify: (node) => intStringify2(node, 2, "0b")
15842};
15843var intOct2 = {
15844  identify: intIdentify3,
15845  default: true,
15846  tag: "tag:yaml.org,2002:int",
15847  format: "OCT",
15848  test: /^[-+]?0[0-7_]+$/,
15849  resolve: (str, _onError, opt) => intResolve2(str, 1, 8, opt),
15850  stringify: (node) => intStringify2(node, 8, "0")
15851};
15852var int2 = {
15853  identify: intIdentify3,
15854  default: true,
15855  tag: "tag:yaml.org,2002:int",
15856  test: /^[-+]?[0-9][0-9_]*$/,
15857  resolve: (str, _onError, opt) => intResolve2(str, 0, 10, opt),
15858  stringify: stringifyNumber
15859};
15860var intHex2 = {
15861  identify: intIdentify3,
15862  default: true,
15863  tag: "tag:yaml.org,2002:int",
15864  format: "HEX",
15865  test: /^[-+]?0x[0-9a-fA-F_]+$/,
15866  resolve: (str, _onError, opt) => intResolve2(str, 2, 16, opt),
15867  stringify: (node) => intStringify2(node, 16, "0x")
15868};
15869
15870// node_modules/yaml/browser/dist/schema/yaml-1.1/set.js
15871var YAMLSet = class _YAMLSet extends YAMLMap {
15872  constructor(schema4) {
15873    super(schema4);
15874    this.tag = _YAMLSet.tag;
15875  }
15876  add(key) {
15877    let pair;
15878    if (isPair(key))
15879      pair = key;
15880    else if (key && typeof key === "object" && "key" in key && "value" in key && key.value === null)
15881      pair = new Pair(key.key, null);
15882    else
15883      pair = new Pair(key, null);
15884    const prev = findPair(this.items, pair.key);
15885    if (!prev)
15886      this.items.push(pair);
15887  }
15888  /**
15889   * If `keepPair` is `true`, returns the Pair matching `key`.
15890   * Otherwise, returns the value of that Pair's key.
15891   */
15892  get(key, keepPair) {
15893    const pair = findPair(this.items, key);
15894    return !keepPair && isPair(pair) ? isScalar(pair.key) ? pair.key.value : pair.key : pair;
15895  }
15896  set(key, value) {
15897    if (typeof value !== "boolean")
15898      throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof value}`);
15899    const prev = findPair(this.items, key);
15900    if (prev && !value) {
15901      this.items.splice(this.items.indexOf(prev), 1);
15902    } else if (!prev && value) {
15903      this.items.push(new Pair(key));
15904    }
15905  }
15906  toJSON(_, ctx) {
15907    return super.toJSON(_, ctx, Set);
15908  }
15909  toString(ctx, onComment, onChompKeep) {
15910    if (!ctx)
15911      return JSON.stringify(this);
15912    if (this.hasAllNullValues(true))
15913      return super.toString(Object.assign({}, ctx, { allNullValues: true }), onComment, onChompKeep);
15914    else
15915      throw new Error("Set items must all have null values");
15916  }
15917  static from(schema4, iterable, ctx) {
15918    const { replacer } = ctx;
15919    const set2 = new this(schema4);
15920    if (iterable && Symbol.iterator in Object(iterable))
15921      for (let value of iterable) {
15922        if (typeof replacer === "function")
15923          value = replacer.call(iterable, value, value);
15924        set2.items.push(createPair(value, null, ctx));
15925      }
15926    return set2;
15927  }
15928};
15929YAMLSet.tag = "tag:yaml.org,2002:set";
15930var set = {
15931  collection: "map",
15932  identify: (value) => value instanceof Set,
15933  nodeClass: YAMLSet,
15934  default: false,
15935  tag: "tag:yaml.org,2002:set",
15936  createNode: (schema4, iterable, ctx) => YAMLSet.from(schema4, iterable, ctx),
15937  resolve(map2, onError) {
15938    if (isMap(map2)) {
15939      if (map2.hasAllNullValues(true))
15940        return Object.assign(new YAMLSet(), map2);
15941      else
15942        onError("Set items must all have null values");
15943    } else
15944      onError("Expected a mapping for this tag");
15945    return map2;
15946  }
15947};
15948
15949// node_modules/yaml/browser/dist/schema/yaml-1.1/timestamp.js
15950function parseSexagesimal(str, asBigInt) {
15951  const sign = str[0];
15952  const parts = sign === "-" || sign === "+" ? str.substring(1) : str;
15953  const num = (n4) => asBigInt ? BigInt(n4) : Number(n4);
15954  const res = parts.replace(/_/g, "").split(":").reduce((res2, p2) => res2 * num(60) + num(p2), num(0));
15955  return sign === "-" ? num(-1) * res : res;
15956}
15957function stringifySexagesimal(node) {
15958  let { value } = node;
15959  let num = (n4) => n4;
15960  if (typeof value === "bigint")
15961    num = (n4) => BigInt(n4);
15962  else if (isNaN(value) || !isFinite(value))
15963    return stringifyNumber(node);
15964  let sign = "";
15965  if (value < 0) {
15966    sign = "-";
15967    value *= num(-1);
15968  }
15969  const _60 = num(60);
15970  const parts = [value % _60];
15971  if (value < 60) {
15972    parts.unshift(0);
15973  } else {
15974    value = (value - parts[0]) / _60;
15975    parts.unshift(value % _60);
15976    if (value >= 60) {
15977      value = (value - parts[0]) / _60;
15978      parts.unshift(value);
15979    }
15980  }
15981  return sign + parts.map((n4) => String(n4).padStart(2, "0")).join(":").replace(/000000\d*$/, "");
15982}
15983var intTime = {
15984  identify: (value) => typeof value === "bigint" || Number.isInteger(value),
15985  default: true,
15986  tag: "tag:yaml.org,2002:int",
15987  format: "TIME",
15988  test: /^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,
15989  resolve: (str, _onError, { intAsBigInt }) => parseSexagesimal(str, intAsBigInt),
15990  stringify: stringifySexagesimal
15991};
15992var floatTime = {
15993  identify: (value) => typeof value === "number",
15994  default: true,
15995  tag: "tag:yaml.org,2002:float",
15996  format: "TIME",
15997  test: /^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,
15998  resolve: (str) => parseSexagesimal(str, false),
15999  stringify: stringifySexagesimal
16000};
16001var timestamp = {
16002  identify: (value) => value instanceof Date,
16003  default: true,
16004  tag: "tag:yaml.org,2002:timestamp",
16005  // If the time zone is omitted, the timestamp is assumed to be specified in UTC. The time part
16006  // may be omitted altogether, resulting in a date format. In such a case, the time part is
16007  // assumed to be 00:00:00Z (start of day, UTC).
16008  test: RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),
16009  resolve(str) {
16010    const match = str.match(timestamp.test);
16011    if (!match)
16012      throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd");
16013    const [, year, month, day, hour, minute, second] = match.map(Number);
16014    const millisec = match[7] ? Number((match[7] + "00").substr(1, 3)) : 0;
16015    let date = Date.UTC(year, month - 1, day, hour || 0, minute || 0, second || 0, millisec);
16016    const tz = match[8];
16017    if (tz && tz !== "Z") {
16018      let d = parseSexagesimal(tz, false);
16019      if (Math.abs(d) < 30)
16020        d *= 60;
16021      date -= 6e4 * d;
16022    }
16023    return new Date(date);
16024  },
16025  stringify: ({ value }) => {
16026    var _a2;
16027    return (_a2 = value == null ? void 0 : value.toISOString().replace(/(T00:00:00)?\.000Z$/, "")) != null ? _a2 : "";
16028  }
16029};
16030
16031// node_modules/yaml/browser/dist/schema/yaml-1.1/schema.js
16032var schema3 = [
16033  map,
16034  seq,
16035  string,
16036  nullTag,
16037  trueTag,
16038  falseTag,
16039  intBin,
16040  intOct2,
16041  int2,
16042  intHex2,
16043  floatNaN2,
16044  floatExp2,
16045  float2,
16046  binary,
16047  merge,
16048  omap,
16049  pairs,
16050  set,
16051  intTime,
16052  floatTime,
16053  timestamp
16054];
16055
16056// node_modules/yaml/browser/dist/schema/tags.js
16057var schemas = /* @__PURE__ */ new Map([
16058  ["core", schema],
16059  ["failsafe", [map, seq, string]],
16060  ["json", schema2],
16061  ["yaml11", schema3],
16062  ["yaml-1.1", schema3]
16063]);
16064var tagsByName = {
16065  binary,
16066  bool: boolTag,
16067  float,
16068  floatExp,
16069  floatNaN,
16070  floatTime,
16071  int,
16072  intHex,
16073  intOct,
16074  intTime,
16075  map,
16076  merge,
16077  null: nullTag,
16078  omap,
16079  pairs,
16080  seq,
16081  set,
16082  timestamp
16083};
16084var coreKnownTags = {
16085  "tag:yaml.org,2002:binary": binary,
16086  "tag:yaml.org,2002:merge": merge,
16087  "tag:yaml.org,2002:omap": omap,
16088  "tag:yaml.org,2002:pairs": pairs,
16089  "tag:yaml.org,2002:set": set,
16090  "tag:yaml.org,2002:timestamp": timestamp
16091};
16092function getTags(customTags, schemaName, addMergeTag) {
16093  const schemaTags = schemas.get(schemaName);
16094  if (schemaTags && !customTags) {
16095    return addMergeTag && !schemaTags.includes(merge) ? schemaTags.concat(merge) : schemaTags.slice();
16096  }
16097  let tags = schemaTags;
16098  if (!tags) {
16099    if (Array.isArray(customTags))
16100      tags = [];
16101    else {
16102      const keys = Array.from(schemas.keys()).filter((key) => key !== "yaml11").map((key) => JSON.stringify(key)).join(", ");
16103      throw new Error(`Unknown schema "${schemaName}"; use one of ${keys} or define customTags array`);
16104    }
16105  }
16106  if (Array.isArray(customTags)) {
16107    for (const tag of customTags)
16108      tags = tags.concat(tag);
16109  } else if (typeof customTags === "function") {
16110    tags = customTags(tags.slice());
16111  }
16112  if (addMergeTag)
16113    tags = tags.concat(merge);
16114  return tags.reduce((tags2, tag) => {
16115    const tagObj = typeof tag === "string" ? tagsByName[tag] : tag;
16116    if (!tagObj) {
16117      const tagName = JSON.stringify(tag);
16118      const keys = Object.keys(tagsByName).map((key) => JSON.stringify(key)).join(", ");
16119      throw new Error(`Unknown custom tag ${tagName}; use one of ${keys}`);
16120    }
16121    if (!tags2.includes(tagObj))
16122      tags2.push(tagObj);
16123    return tags2;
16124  }, []);
16125}
16126
16127// node_modules/yaml/browser/dist/schema/Schema.js
16128var sortMapEntriesByKey = (a, b) => a.key < b.key ? -1 : a.key > b.key ? 1 : 0;
16129var Schema = class _Schema {
16130  constructor({ compat, customTags, merge: merge2, resolveKnownTags, schema: schema4, sortMapEntries, toStringDefaults }) {
16131    this.compat = Array.isArray(compat) ? getTags(compat, "compat") : compat ? getTags(null, compat) : null;
16132    this.name = typeof schema4 === "string" && schema4 || "core";
16133    this.knownTags = resolveKnownTags ? coreKnownTags : {};
16134    this.tags = getTags(customTags, this.name, merge2);
16135    this.toStringOptions = toStringDefaults != null ? toStringDefaults : null;
16136    Object.defineProperty(this, MAP, { value: map });
16137    Object.defineProperty(this, SCALAR, { value: string });
16138    Object.defineProperty(this, SEQ, { value: seq });
16139    this.sortMapEntries = typeof sortMapEntries === "function" ? sortMapEntries : sortMapEntries === true ? sortMapEntriesByKey : null;
16140  }
16141  clone() {
16142    const copy = Object.create(_Schema.prototype, Object.getOwnPropertyDescriptors(this));
16143    copy.tags = this.tags.slice();
16144    return copy;
16145  }
16146};
16147
16148// node_modules/yaml/browser/dist/stringify/stringifyDocument.js
16149function stringifyDocument(doc, options) {
16150  var _a2;
16151  const lines = [];
16152  let hasDirectives = options.directives === true;
16153  if (options.directives !== false && doc.directives) {
16154    const dir = doc.directives.toString(doc);
16155    if (dir) {
16156      lines.push(dir);
16157      hasDirectives = true;
16158    } else if (doc.directives.docStart)
16159      hasDirectives = true;
16160  }
16161  if (hasDirectives)
16162    lines.push("---");
16163  const ctx = createStringifyContext(doc, options);
16164  const { commentString } = ctx.options;
16165  if (doc.commentBefore) {
16166    if (lines.length !== 1)
16167      lines.unshift("");
16168    const cs = commentString(doc.commentBefore);
16169    lines.unshift(indentComment(cs, ""));
16170  }
16171  let chompKeep = false;
16172  let contentComment = null;
16173  if (doc.contents) {
16174    if (isNode(doc.contents)) {
16175      if (doc.contents.spaceBefore && hasDirectives)
16176        lines.push("");
16177      if (doc.contents.commentBefore) {
16178        const cs = commentString(doc.contents.commentBefore);
16179        lines.push(indentComment(cs, ""));
16180      }
16181      ctx.forceBlockIndent = !!doc.comment;
16182      contentComment = doc.contents.comment;
16183    }
16184    const onChompKeep = contentComment ? void 0 : () => chompKeep = true;
16185    let body = stringify(doc.contents, ctx, () => contentComment = null, onChompKeep);
16186    if (contentComment)
16187      body += lineComment(body, "", commentString(contentComment));
16188    if ((body[0] === "|" || body[0] === ">") && lines[lines.length - 1] === "---") {
16189      lines[lines.length - 1] = `--- ${body}`;
16190    } else
16191      lines.push(body);
16192  } else {
16193    lines.push(stringify(doc.contents, ctx));
16194  }
16195  if ((_a2 = doc.directives) == null ? void 0 : _a2.docEnd) {
16196    if (doc.comment) {
16197      const cs = commentString(doc.comment);
16198      if (cs.includes("\n")) {
16199        lines.push("...");
16200        lines.push(indentComment(cs, ""));
16201      } else {
16202        lines.push(`... ${cs}`);
16203      }
16204    } else {
16205      lines.push("...");
16206    }
16207  } else {
16208    let dc = doc.comment;
16209    if (dc && chompKeep)
16210      dc = dc.replace(/^\n+/, "");
16211    if (dc) {
16212      if ((!chompKeep || contentComment) && lines[lines.length - 1] !== "")
16213        lines.push("");
16214      lines.push(indentComment(commentString(dc), ""));
16215    }
16216  }
16217  return lines.join("\n") + "\n";
16218}
16219
16220// node_modules/yaml/browser/dist/doc/Document.js
16221var Document = class _Document {
16222  constructor(value, replacer, options) {
16223    this.commentBefore = null;
16224    this.comment = null;
16225    this.errors = [];
16226    this.warnings = [];
16227    Object.defineProperty(this, NODE_TYPE, { value: DOC });
16228    let _replacer = null;
16229    if (typeof replacer === "function" || Array.isArray(replacer)) {
16230      _replacer = replacer;
16231    } else if (options === void 0 && replacer) {
16232      options = replacer;
16233      replacer = void 0;
16234    }
16235    const opt = Object.assign({
16236      intAsBigInt: false,
16237      keepSourceTokens: false,
16238      logLevel: "warn",
16239      prettyErrors: true,
16240      strict: true,
16241      stringKeys: false,
16242      uniqueKeys: true,
16243      version: "1.2"
16244    }, options);
16245    this.options = opt;
16246    let { version } = opt;
16247    if (options == null ? void 0 : options._directives) {
16248      this.directives = options._directives.atDocument();
16249      if (this.directives.yaml.explicit)
16250        version = this.directives.yaml.version;
16251    } else
16252      this.directives = new Directives({ version });
16253    this.setSchema(version, options);
16254    this.contents = value === void 0 ? null : this.createNode(value, _replacer, options);
16255  }
16256  /**
16257   * Create a deep copy of this Document and its contents.
16258   *
16259   * Custom Node values that inherit from `Object` still refer to their original instances.
16260   */
16261  clone() {
16262    const copy = Object.create(_Document.prototype, {
16263      [NODE_TYPE]: { value: DOC }
16264    });
16265    copy.commentBefore = this.commentBefore;
16266    copy.comment = this.comment;
16267    copy.errors = this.errors.slice();
16268    copy.warnings = this.warnings.slice();
16269    copy.options = Object.assign({}, this.options);
16270    if (this.directives)
16271      copy.directives = this.directives.clone();
16272    copy.schema = this.schema.clone();
16273    copy.contents = isNode(this.contents) ? this.contents.clone(copy.schema) : this.contents;
16274    if (this.range)
16275      copy.range = this.range.slice();
16276    return copy;
16277  }
16278  /** Adds a value to the document. */
16279  add(value) {
16280    if (assertCollection(this.contents))
16281      this.contents.add(value);
16282  }
16283  /** Adds a value to the document. */
16284  addIn(path5, value) {
16285    if (assertCollection(this.contents))
16286      this.contents.addIn(path5, value);
16287  }
16288  /**
16289   * Create a new `Alias` node, ensuring that the target `node` has the required anchor.
16290   *
16291   * If `node` already has an anchor, `name` is ignored.
16292   * Otherwise, the `node.anchor` value will be set to `name`,
16293   * or if an anchor with that name is already present in the document,
16294   * `name` will be used as a prefix for a new unique anchor.
16295   * If `name` is undefined, the generated anchor will use 'a' as a prefix.
16296   */
16297  createAlias(node, name) {
16298    if (!node.anchor) {
16299      const prev = anchorNames(this);
16300      node.anchor = // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
16301      !name || prev.has(name) ? findNewAnchor(name || "a", prev) : name;
16302    }
16303    return new Alias(node.anchor);
16304  }
16305  createNode(value, replacer, options) {
16306    let _replacer = void 0;
16307    if (typeof replacer === "function") {
16308      value = replacer.call({ "": value }, "", value);
16309      _replacer = replacer;
16310    } else if (Array.isArray(replacer)) {
16311      const keyToStr = (v2) => typeof v2 === "number" || v2 instanceof String || v2 instanceof Number;
16312      const asStr = replacer.filter(keyToStr).map(String);
16313      if (asStr.length > 0)
16314        replacer = replacer.concat(asStr);
16315      _replacer = replacer;
16316    } else if (options === void 0 && replacer) {
16317      options = replacer;
16318      replacer = void 0;
16319    }
16320    const { aliasDuplicateObjects, anchorPrefix, flow, keepUndefined, onTagObj, tag } = options != null ? options : {};
16321    const { onAnchor, setAnchors, sourceObjects } = createNodeAnchors(
16322      this,
16323      // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
16324      anchorPrefix || "a"
16325    );
16326    const ctx = {
16327      aliasDuplicateObjects: aliasDuplicateObjects != null ? aliasDuplicateObjects : true,
16328      keepUndefined: keepUndefined != null ? keepUndefined : false,
16329      onAnchor,
16330      onTagObj,
16331      replacer: _replacer,
16332      schema: this.schema,
16333      sourceObjects
16334    };
16335    const node = createNode(value, tag, ctx);
16336    if (flow && isCollection(node))
16337      node.flow = true;
16338    setAnchors();
16339    return node;
16340  }
16341  /**
16342   * Convert a key and a value into a `Pair` using the current schema,
16343   * recursively wrapping all values as `Scalar` or `Collection` nodes.
16344   */
16345  createPair(key, value, options = {}) {
16346    const k2 = this.createNode(key, null, options);
16347    const v2 = this.createNode(value, null, options);
16348    return new Pair(k2, v2);
16349  }
16350  /**
16351   * Removes a value from the document.
16352   * @returns `true` if the item was found and removed.
16353   */
16354  delete(key) {
16355    return assertCollection(this.contents) ? this.contents.delete(key) : false;
16356  }
16357  /**
16358   * Removes a value from the document.
16359   * @returns `true` if the item was found and removed.
16360   */
16361  deleteIn(path5) {
16362    if (isEmptyPath(path5)) {
16363      if (this.contents == null)
16364        return false;
16365      this.contents = null;
16366      return true;
16367    }
16368    return assertCollection(this.contents) ? this.contents.deleteIn(path5) : false;
16369  }
16370  /**
16371   * Returns item at `key`, or `undefined` if not found. By default unwraps
16372   * scalar values from their surrounding node; to disable set `keepScalar` to
16373   * `true` (collections are always returned intact).
16374   */
16375  get(key, keepScalar) {
16376    return isCollection(this.contents) ? this.contents.get(key, keepScalar) : void 0;
16377  }
16378  /**
16379   * Returns item at `path`, or `undefined` if not found. By default unwraps
16380   * scalar values from their surrounding node; to disable set `keepScalar` to
16381   * `true` (collections are always returned intact).
16382   */
16383  getIn(path5, keepScalar) {
16384    if (isEmptyPath(path5))
16385      return !keepScalar && isScalar(this.contents) ? this.contents.value : this.contents;
16386    return isCollection(this.contents) ? this.contents.getIn(path5, keepScalar) : void 0;
16387  }
16388  /**
16389   * Checks if the document includes a value with the key `key`.
16390   */
16391  has(key) {
16392    return isCollection(this.contents) ? this.contents.has(key) : false;
16393  }
16394  /**
16395   * Checks if the document includes a value at `path`.
16396   */
16397  hasIn(path5) {
16398    if (isEmptyPath(path5))
16399      return this.contents !== void 0;
16400    return isCollection(this.contents) ? this.contents.hasIn(path5) : false;
16401  }
16402  /**
16403   * Sets a value in this document. For `!!set`, `value` needs to be a
16404   * boolean to add/remove the item from the set.
16405   */
16406  set(key, value) {
16407    if (this.contents == null) {
16408      this.contents = collectionFromPath(this.schema, [key], value);
16409    } else if (assertCollection(this.contents)) {
16410      this.contents.set(key, value);
16411    }
16412  }
16413  /**
16414   * Sets a value in this document. For `!!set`, `value` needs to be a
16415   * boolean to add/remove the item from the set.
16416   */
16417  setIn(path5, value) {
16418    if (isEmptyPath(path5)) {
16419      this.contents = value;
16420    } else if (this.contents == null) {
16421      this.contents = collectionFromPath(this.schema, Array.from(path5), value);
16422    } else if (assertCollection(this.contents)) {
16423      this.contents.setIn(path5, value);
16424    }
16425  }
16426  /**
16427   * Change the YAML version and schema used by the document.
16428   * A `null` version disables support for directives, explicit tags, anchors, and aliases.
16429   * It also requires the `schema` option to be given as a `Schema` instance value.
16430   *
16431   * Overrides all previously set schema options.
16432   */
16433  setSchema(version, options = {}) {
16434    if (typeof version === "number")
16435      version = String(version);
16436    let opt;
16437    switch (version) {
16438      case "1.1":
16439        if (this.directives)
16440          this.directives.yaml.version = "1.1";
16441        else
16442          this.directives = new Directives({ version: "1.1" });
16443        opt = { resolveKnownTags: false, schema: "yaml-1.1" };
16444        break;
16445      case "1.2":
16446      case "next":
16447        if (this.directives)
16448          this.directives.yaml.version = version;
16449        else
16450          this.directives = new Directives({ version });
16451        opt = { resolveKnownTags: true, schema: "core" };
16452        break;
16453      case null:
16454        if (this.directives)
16455          delete this.directives;
16456        opt = null;
16457        break;
16458      default: {
16459        const sv = JSON.stringify(version);
16460        throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${sv}`);
16461      }
16462    }
16463    if (options.schema instanceof Object)
16464      this.schema = options.schema;
16465    else if (opt)
16466      this.schema = new Schema(Object.assign(opt, options));
16467    else
16468      throw new Error(`With a null YAML version, the { schema: Schema } option is required`);
16469  }
16470  // json & jsonArg are only used from toJSON()
16471  toJS({ json, jsonArg, mapAsMap, maxAliasCount, onAnchor, reviver } = {}) {
16472    const ctx = {
16473      anchors: /* @__PURE__ */ new Map(),
16474      doc: this,
16475      keep: !json,
16476      mapAsMap: mapAsMap === true,
16477      mapKeyWarned: false,
16478      maxAliasCount: typeof maxAliasCount === "number" ? maxAliasCount : 100
16479    };
16480    const res = toJS(this.contents, jsonArg != null ? jsonArg : "", ctx);
16481    if (typeof onAnchor === "function")
16482      for (const { count, res: res2 } of ctx.anchors.values())
16483        onAnchor(res2, count);
16484    return typeof reviver === "function" ? applyReviver(reviver, { "": res }, "", res) : res;
16485  }
16486  /**
16487   * A JSON representation of the document `contents`.
16488   *
16489   * @param jsonArg Used by `JSON.stringify` to indicate the array index or
16490   *   property name.
16491   */
16492  toJSON(jsonArg, onAnchor) {
16493    return this.toJS({ json: true, jsonArg, mapAsMap: false, onAnchor });
16494  }
16495  /** A YAML representation of the document. */
16496  toString(options = {}) {
16497    if (this.errors.length > 0)
16498      throw new Error("Document with errors cannot be stringified");
16499    if ("indent" in options && (!Number.isInteger(options.indent) || Number(options.indent) <= 0)) {
16500      const s = JSON.stringify(options.indent);
16501      throw new Error(`"indent" option must be a positive integer, not ${s}`);
16502    }
16503    return stringifyDocument(this, options);
16504  }
16505};
16506function assertCollection(contents) {
16507  if (isCollection(contents))
16508    return true;
16509  throw new Error("Expected a YAML collection as document contents");
16510}
16511
16512// node_modules/yaml/browser/dist/errors.js
16513var YAMLError = class extends Error {
16514  constructor(name, pos, code, message) {
16515    super();
16516    this.name = name;
16517    this.code = code;
16518    this.message = message;
16519    this.pos = pos;
16520  }
16521};
16522var YAMLParseError = class extends YAMLError {
16523  constructor(pos, code, message) {
16524    super("YAMLParseError", pos, code, message);
16525  }
16526};
16527var YAMLWarning = class extends YAMLError {
16528  constructor(pos, code, message) {
16529    super("YAMLWarning", pos, code, message);
16530  }
16531};
16532var prettifyError = (src, lc) => (error) => {
16533  if (error.pos[0] === -1)
16534    return;
16535  error.linePos = error.pos.map((pos) => lc.linePos(pos));
16536  const { line, col } = error.linePos[0];
16537  error.message += ` at line ${line}, column ${col}`;
16538  let ci2 = col - 1;
16539  let lineStr = src.substring(lc.lineStarts[line - 1], lc.lineStarts[line]).replace(/[\n\r]+$/, "");
16540  if (ci2 >= 60 && lineStr.length > 80) {
16541    const trimStart = Math.min(ci2 - 39, lineStr.length - 79);
16542    lineStr = "\u2026" + lineStr.substring(trimStart);
16543    ci2 -= trimStart - 1;
16544  }
16545  if (lineStr.length > 80)
16546    lineStr = lineStr.substring(0, 79) + "\u2026";
16547  if (line > 1 && /^ *$/.test(lineStr.substring(0, ci2))) {
16548    let prev = src.substring(lc.lineStarts[line - 2], lc.lineStarts[line - 1]);
16549    if (prev.length > 80)
16550      prev = prev.substring(0, 79) + "\u2026\n";
16551    lineStr = prev + lineStr;
16552  }
16553  if (/[^ ]/.test(lineStr)) {
16554    let count = 1;
16555    const end = error.linePos[1];
16556    if (end && end.line === line && end.col > col) {
16557      count = Math.max(1, Math.min(end.col - col, 80 - ci2));
16558    }
16559    const pointer = " ".repeat(ci2) + "^".repeat(count);
16560    error.message += `:
16561
16562${lineStr}
16563${pointer}
16564`;
16565  }
16566};
16567
16568// node_modules/yaml/browser/dist/compose/resolve-props.js
16569function resolveProps(tokens, { flow, indicator, next, offset, onError, parentIndent, startOnNewline }) {
16570  let spaceBefore = false;
16571  let atNewline = startOnNewline;
16572  let hasSpace = startOnNewline;
16573  let comment = "";
16574  let commentSep = "";
16575  let hasNewline = false;
16576  let reqSpace = false;
16577  let tab = null;
16578  let anchor = null;
16579  let tag = null;
16580  let newlineAfterProp = null;
16581  let comma = null;
16582  let found = null;
16583  let start = null;
16584  for (const token of tokens) {
16585    if (reqSpace) {
16586      if (token.type !== "space" && token.type !== "newline" && token.type !== "comma")
16587        onError(token.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space");
16588      reqSpace = false;
16589    }
16590    if (tab) {
16591      if (atNewline && token.type !== "comment" && token.type !== "newline") {
16592        onError(tab, "TAB_AS_INDENT", "Tabs are not allowed as indentation");
16593      }
16594      tab = null;
16595    }
16596    switch (token.type) {
16597      case "space":
16598        if (!flow && (indicator !== "doc-start" || (next == null ? void 0 : next.type) !== "flow-collection") && token.source.includes("	")) {
16599          tab = token;
16600        }
16601        hasSpace = true;
16602        break;
16603      case "comment": {
16604        if (!hasSpace)
16605          onError(token, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters");
16606        const cb = token.source.substring(1) || " ";
16607        if (!comment)
16608          comment = cb;
16609        else
16610          comment += commentSep + cb;
16611        commentSep = "";
16612        atNewline = false;
16613        break;
16614      }
16615      case "newline":
16616        if (atNewline) {
16617          if (comment)
16618            comment += token.source;
16619          else if (!found || indicator !== "seq-item-ind")
16620            spaceBefore = true;
16621        } else
16622          commentSep += token.source;
16623        atNewline = true;
16624        hasNewline = true;
16625        if (anchor || tag)
16626          newlineAfterProp = token;
16627        hasSpace = true;
16628        break;
16629      case "anchor":
16630        if (anchor)
16631          onError(token, "MULTIPLE_ANCHORS", "A node can have at most one anchor");
16632        if (token.source.endsWith(":"))
16633          onError(token.offset + token.source.length - 1, "BAD_ALIAS", "Anchor ending in : is ambiguous", true);
16634        anchor = token;
16635        start != null ? start : start = token.offset;
16636        atNewline = false;
16637        hasSpace = false;
16638        reqSpace = true;
16639        break;
16640      case "tag": {
16641        if (tag)
16642          onError(token, "MULTIPLE_TAGS", "A node can have at most one tag");
16643        tag = token;
16644        start != null ? start : start = token.offset;
16645        atNewline = false;
16646        hasSpace = false;
16647        reqSpace = true;
16648        break;
16649      }
16650      case indicator:
16651        if (anchor || tag)
16652          onError(token, "BAD_PROP_ORDER", `Anchors and tags must be after the ${token.source} indicator`);
16653        if (found)
16654          onError(token, "UNEXPECTED_TOKEN", `Unexpected ${token.source} in ${flow != null ? flow : "collection"}`);
16655        found = token;
16656        atNewline = indicator === "seq-item-ind" || indicator === "explicit-key-ind";
16657        hasSpace = false;
16658        break;
16659      case "comma":
16660        if (flow) {
16661          if (comma)
16662            onError(token, "UNEXPECTED_TOKEN", `Unexpected , in ${flow}`);
16663          comma = token;
16664          atNewline = false;
16665          hasSpace = false;
16666          break;
16667        }
16668      // else fallthrough
16669      default:
16670        onError(token, "UNEXPECTED_TOKEN", `Unexpected ${token.type} token`);
16671        atNewline = false;
16672        hasSpace = false;
16673    }
16674  }
16675  const last = tokens[tokens.length - 1];
16676  const end = last ? last.offset + last.source.length : offset;
16677  if (reqSpace && next && next.type !== "space" && next.type !== "newline" && next.type !== "comma" && (next.type !== "scalar" || next.source !== "")) {
16678    onError(next.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space");
16679  }
16680  if (tab && (atNewline && tab.indent <= parentIndent || (next == null ? void 0 : next.type) === "block-map" || (next == null ? void 0 : next.type) === "block-seq"))
16681    onError(tab, "TAB_AS_INDENT", "Tabs are not allowed as indentation");
16682  return {
16683    comma,
16684    found,
16685    spaceBefore,
16686    comment,
16687    hasNewline,
16688    anchor,
16689    tag,
16690    newlineAfterProp,
16691    end,
16692    start: start != null ? start : end
16693  };
16694}
16695
16696// node_modules/yaml/browser/dist/compose/util-contains-newline.js
16697function containsNewline(key) {
16698  if (!key)
16699    return null;
16700  switch (key.type) {
16701    case "alias":
16702    case "scalar":
16703    case "double-quoted-scalar":
16704    case "single-quoted-scalar":
16705      if (key.source.includes("\n"))
16706        return true;
16707      if (key.end) {
16708        for (const st2 of key.end)
16709          if (st2.type === "newline")
16710            return true;
16711      }
16712      return false;
16713    case "flow-collection":
16714      for (const it of key.items) {
16715        for (const st2 of it.start)
16716          if (st2.type === "newline")
16717            return true;
16718        if (it.sep) {
16719          for (const st2 of it.sep)
16720            if (st2.type === "newline")
16721              return true;
16722        }
16723        if (containsNewline(it.key) || containsNewline(it.value))
16724          return true;
16725      }
16726      return false;
16727    default:
16728      return true;
16729  }
16730}
16731
16732// node_modules/yaml/browser/dist/compose/util-flow-indent-check.js
16733function flowIndentCheck(indent, fc, onError) {
16734  if ((fc == null ? void 0 : fc.type) === "flow-collection") {
16735    const end = fc.end[0];
16736    if (end.indent === indent && (end.source === "]" || end.source === "}") && containsNewline(fc)) {
16737      const msg = "Flow end indicator should be more indented than parent";
16738      onError(end, "BAD_INDENT", msg, true);
16739    }
16740  }
16741}
16742
16743// node_modules/yaml/browser/dist/compose/util-map-includes.js
16744function mapIncludes(ctx, items, search) {
16745  const { uniqueKeys } = ctx.options;
16746  if (uniqueKeys === false)
16747    return false;
16748  const isEqual = typeof uniqueKeys === "function" ? uniqueKeys : (a, b) => a === b || isScalar(a) && isScalar(b) && a.value === b.value;
16749  return items.some((pair) => isEqual(pair.key, search));
16750}
16751
16752// node_modules/yaml/browser/dist/compose/resolve-block-map.js
16753var startColMsg = "All mapping items must start at the same column";
16754function resolveBlockMap({ composeNode: composeNode2, composeEmptyNode: composeEmptyNode2 }, ctx, bm, onError, tag) {
16755  var _a2, _b2;
16756  const NodeClass = (_a2 = tag == null ? void 0 : tag.nodeClass) != null ? _a2 : YAMLMap;
16757  const map2 = new NodeClass(ctx.schema);
16758  if (ctx.atRoot)
16759    ctx.atRoot = false;
16760  let offset = bm.offset;
16761  let commentEnd = null;
16762  for (const collItem of bm.items) {
16763    const { start, key, sep, value } = collItem;
16764    const keyProps = resolveProps(start, {
16765      indicator: "explicit-key-ind",
16766      next: key != null ? key : sep == null ? void 0 : sep[0],
16767      offset,
16768      onError,
16769      parentIndent: bm.indent,
16770      startOnNewline: true
16771    });
16772    const implicitKey = !keyProps.found;
16773    if (implicitKey) {
16774      if (key) {
16775        if (key.type === "block-seq")
16776          onError(offset, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key");
16777        else if ("indent" in key && key.indent !== bm.indent)
16778          onError(offset, "BAD_INDENT", startColMsg);
16779      }
16780      if (!keyProps.anchor && !keyProps.tag && !sep) {
16781        commentEnd = keyProps.end;
16782        if (keyProps.comment) {
16783          if (map2.comment)
16784            map2.comment += "\n" + keyProps.comment;
16785          else
16786            map2.comment = keyProps.comment;
16787        }
16788        continue;
16789      }
16790      if (keyProps.newlineAfterProp || containsNewline(key)) {
16791        onError(key != null ? key : start[start.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line");
16792      }
16793    } else if (((_b2 = keyProps.found) == null ? void 0 : _b2.indent) !== bm.indent) {
16794      onError(offset, "BAD_INDENT", startColMsg);
16795    }
16796    ctx.atKey = true;
16797    const keyStart = keyProps.end;
16798    const keyNode = key ? composeNode2(ctx, key, keyProps, onError) : composeEmptyNode2(ctx, keyStart, start, null, keyProps, onError);
16799    if (ctx.schema.compat)
16800      flowIndentCheck(bm.indent, key, onError);
16801    ctx.atKey = false;
16802    if (mapIncludes(ctx, map2.items, keyNode))
16803      onError(keyStart, "DUPLICATE_KEY", "Map keys must be unique");
16804    const valueProps = resolveProps(sep != null ? sep : [], {
16805      indicator: "map-value-ind",
16806      next: value,
16807      offset: keyNode.range[2],
16808      onError,
16809      parentIndent: bm.indent,
16810      startOnNewline: !key || key.type === "block-scalar"
16811    });
16812    offset = valueProps.end;
16813    if (valueProps.found) {
16814      if (implicitKey) {
16815        if ((value == null ? void 0 : value.type) === "block-map" && !valueProps.hasNewline)
16816          onError(offset, "BLOCK_AS_IMPLICIT_KEY", "Nested mappings are not allowed in compact mappings");
16817        if (ctx.options.strict && keyProps.start < valueProps.found.offset - 1024)
16818          onError(keyNode.range, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit block mapping key");
16819      }
16820      const valueNode = value ? composeNode2(ctx, value, valueProps, onError) : composeEmptyNode2(ctx, offset, sep, null, valueProps, onError);
16821      if (ctx.schema.compat)
16822        flowIndentCheck(bm.indent, value, onError);
16823      offset = valueNode.range[2];
16824      const pair = new Pair(keyNode, valueNode);
16825      if (ctx.options.keepSourceTokens)
16826        pair.srcToken = collItem;
16827      map2.items.push(pair);
16828    } else {
16829      if (implicitKey)
16830        onError(keyNode.range, "MISSING_CHAR", "Implicit map keys need to be followed by map values");
16831      if (valueProps.comment) {
16832        if (keyNode.comment)
16833          keyNode.comment += "\n" + valueProps.comment;
16834        else
16835          keyNode.comment = valueProps.comment;
16836      }
16837      const pair = new Pair(keyNode);
16838      if (ctx.options.keepSourceTokens)
16839        pair.srcToken = collItem;
16840      map2.items.push(pair);
16841    }
16842  }
16843  if (commentEnd && commentEnd < offset)
16844    onError(commentEnd, "IMPOSSIBLE", "Map comment with trailing content");
16845  map2.range = [bm.offset, offset, commentEnd != null ? commentEnd : offset];
16846  return map2;
16847}
16848
16849// node_modules/yaml/browser/dist/compose/resolve-block-seq.js
16850function resolveBlockSeq({ composeNode: composeNode2, composeEmptyNode: composeEmptyNode2 }, ctx, bs, onError, tag) {
16851  var _a2;
16852  const NodeClass = (_a2 = tag == null ? void 0 : tag.nodeClass) != null ? _a2 : YAMLSeq;
16853  const seq2 = new NodeClass(ctx.schema);
16854  if (ctx.atRoot)
16855    ctx.atRoot = false;
16856  if (ctx.atKey)
16857    ctx.atKey = false;
16858  let offset = bs.offset;
16859  let commentEnd = null;
16860  for (const { start, value } of bs.items) {
16861    const props = resolveProps(start, {
16862      indicator: "seq-item-ind",
16863      next: value,
16864      offset,
16865      onError,
16866      parentIndent: bs.indent,
16867      startOnNewline: true
16868    });
16869    if (!props.found) {
16870      if (props.anchor || props.tag || value) {
16871        if (value && value.type === "block-seq")
16872          onError(props.end, "BAD_INDENT", "All sequence items must start at the same column");
16873        else
16874          onError(offset, "MISSING_CHAR", "Sequence item without - indicator");
16875      } else {
16876        commentEnd = props.end;
16877        if (props.comment)
16878          seq2.comment = props.comment;
16879        continue;
16880      }
16881    }
16882    const node = value ? composeNode2(ctx, value, props, onError) : composeEmptyNode2(ctx, props.end, start, null, props, onError);
16883    if (ctx.schema.compat)
16884      flowIndentCheck(bs.indent, value, onError);
16885    offset = node.range[2];
16886    seq2.items.push(node);
16887  }
16888  seq2.range = [bs.offset, offset, commentEnd != null ? commentEnd : offset];
16889  return seq2;
16890}
16891
16892// node_modules/yaml/browser/dist/compose/resolve-end.js
16893function resolveEnd(end, offset, reqSpace, onError) {
16894  let comment = "";
16895  if (end) {
16896    let hasSpace = false;
16897    let sep = "";
16898    for (const token of end) {
16899      const { source, type } = token;
16900      switch (type) {
16901        case "space":
16902          hasSpace = true;
16903          break;
16904        case "comment": {
16905          if (reqSpace && !hasSpace)
16906            onError(token, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters");
16907          const cb = source.substring(1) || " ";
16908          if (!comment)
16909            comment = cb;
16910          else
16911            comment += sep + cb;
16912          sep = "";
16913          break;
16914        }
16915        case "newline":
16916          if (comment)
16917            sep += source;
16918          hasSpace = true;
16919          break;
16920        default:
16921          onError(token, "UNEXPECTED_TOKEN", `Unexpected ${type} at node end`);
16922      }
16923      offset += source.length;
16924    }
16925  }
16926  return { comment, offset };
16927}
16928
16929// node_modules/yaml/browser/dist/compose/resolve-flow-collection.js
16930var blockMsg = "Block collections are not allowed within flow collections";
16931var isBlock = (token) => token && (token.type === "block-map" || token.type === "block-seq");
16932function resolveFlowCollection({ composeNode: composeNode2, composeEmptyNode: composeEmptyNode2 }, ctx, fc, onError, tag) {
16933  var _a2, _b2;
16934  const isMap2 = fc.start.source === "{";
16935  const fcName = isMap2 ? "flow map" : "flow sequence";
16936  const NodeClass = (_a2 = tag == null ? void 0 : tag.nodeClass) != null ? _a2 : isMap2 ? YAMLMap : YAMLSeq;
16937  const coll = new NodeClass(ctx.schema);
16938  coll.flow = true;
16939  const atRoot = ctx.atRoot;
16940  if (atRoot)
16941    ctx.atRoot = false;
16942  if (ctx.atKey)
16943    ctx.atKey = false;
16944  let offset = fc.offset + fc.start.source.length;
16945  for (let i = 0; i < fc.items.length; ++i) {
16946    const collItem = fc.items[i];
16947    const { start, key, sep, value } = collItem;
16948    const props = resolveProps(start, {
16949      flow: fcName,
16950      indicator: "explicit-key-ind",
16951      next: key != null ? key : sep == null ? void 0 : sep[0],
16952      offset,
16953      onError,
16954      parentIndent: fc.indent,
16955      startOnNewline: false
16956    });
16957    if (!props.found) {
16958      if (!props.anchor && !props.tag && !sep && !value) {
16959        if (i === 0 && props.comma)
16960          onError(props.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${fcName}`);
16961        else if (i < fc.items.length - 1)
16962          onError(props.start, "UNEXPECTED_TOKEN", `Unexpected empty item in ${fcName}`);
16963        if (props.comment) {
16964          if (coll.comment)
16965            coll.comment += "\n" + props.comment;
16966          else
16967            coll.comment = props.comment;
16968        }
16969        offset = props.end;
16970        continue;
16971      }
16972      if (!isMap2 && ctx.options.strict && containsNewline(key))
16973        onError(
16974          key,
16975          // checked by containsNewline()
16976          "MULTILINE_IMPLICIT_KEY",
16977          "Implicit keys of flow sequence pairs need to be on a single line"
16978        );
16979    }
16980    if (i === 0) {
16981      if (props.comma)
16982        onError(props.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${fcName}`);
16983    } else {
16984      if (!props.comma)
16985        onError(props.start, "MISSING_CHAR", `Missing , between ${fcName} items`);
16986      if (props.comment) {
16987        let prevItemComment = "";
16988        loop: for (const st2 of start) {
16989          switch (st2.type) {
16990            case "comma":
16991            case "space":
16992              break;
16993            case "comment":
16994              prevItemComment = st2.source.substring(1);
16995              break loop;
16996            default:
16997              break loop;
16998          }
16999        }
17000        if (prevItemComment) {
17001          let prev = coll.items[coll.items.length - 1];
17002          if (isPair(prev))
17003            prev = (_b2 = prev.value) != null ? _b2 : prev.key;
17004          if (prev.comment)
17005            prev.comment += "\n" + prevItemComment;
17006          else
17007            prev.comment = prevItemComment;
17008          props.comment = props.comment.substring(prevItemComment.length + 1);
17009        }
17010      }
17011    }
17012    if (!isMap2 && !sep && !props.found) {
17013      const valueNode = value ? composeNode2(ctx, value, props, onError) : composeEmptyNode2(ctx, props.end, sep, null, props, onError);
17014      coll.items.push(valueNode);
17015      offset = valueNode.range[2];
17016      if (isBlock(value))
17017        onError(valueNode.range, "BLOCK_IN_FLOW", blockMsg);
17018    } else {
17019      ctx.atKey = true;
17020      const keyStart = props.end;
17021      const keyNode = key ? composeNode2(ctx, key, props, onError) : composeEmptyNode2(ctx, keyStart, start, null, props, onError);
17022      if (isBlock(key))
17023        onError(keyNode.range, "BLOCK_IN_FLOW", blockMsg);
17024      ctx.atKey = false;
17025      const valueProps = resolveProps(sep != null ? sep : [], {
17026        flow: fcName,
17027        indicator: "map-value-ind",
17028        next: value,
17029        offset: keyNode.range[2],
17030        onError,
17031        parentIndent: fc.indent,
17032        startOnNewline: false
17033      });
17034      if (valueProps.found) {
17035        if (!isMap2 && !props.found && ctx.options.strict) {
17036          if (sep)
17037            for (const st2 of sep) {
17038              if (st2 === valueProps.found)
17039                break;
17040              if (st2.type === "newline") {
17041                onError(st2, "MULTILINE_IMPLICIT_KEY", "Implicit keys of flow sequence pairs need to be on a single line");
17042                break;
17043              }
17044            }
17045          if (props.start < valueProps.found.offset - 1024)
17046            onError(valueProps.found, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit flow sequence key");
17047        }
17048      } else if (value) {
17049        if ("source" in value && value.source && value.source[0] === ":")
17050          onError(value, "MISSING_CHAR", `Missing space after : in ${fcName}`);
17051        else
17052          onError(valueProps.start, "MISSING_CHAR", `Missing , or : between ${fcName} items`);
17053      }
17054      const valueNode = value ? composeNode2(ctx, value, valueProps, onError) : valueProps.found ? composeEmptyNode2(ctx, valueProps.end, sep, null, valueProps, onError) : null;
17055      if (valueNode) {
17056        if (isBlock(value))
17057          onError(valueNode.range, "BLOCK_IN_FLOW", blockMsg);
17058      } else if (valueProps.comment) {
17059        if (keyNode.comment)
17060          keyNode.comment += "\n" + valueProps.comment;
17061        else
17062          keyNode.comment = valueProps.comment;
17063      }
17064      const pair = new Pair(keyNode, valueNode);
17065      if (ctx.options.keepSourceTokens)
17066        pair.srcToken = collItem;
17067      if (isMap2) {
17068        const map2 = coll;
17069        if (mapIncludes(ctx, map2.items, keyNode))
17070          onError(keyStart, "DUPLICATE_KEY", "Map keys must be unique");
17071        map2.items.push(pair);
17072      } else {
17073        const map2 = new YAMLMap(ctx.schema);
17074        map2.flow = true;
17075        map2.items.push(pair);
17076        const endRange = (valueNode != null ? valueNode : keyNode).range;
17077        map2.range = [keyNode.range[0], endRange[1], endRange[2]];
17078        coll.items.push(map2);
17079      }
17080      offset = valueNode ? valueNode.range[2] : valueProps.end;
17081    }
17082  }
17083  const expectedEnd = isMap2 ? "}" : "]";
17084  const [ce, ...ee2] = fc.end;
17085  let cePos = offset;
17086  if (ce && ce.source === expectedEnd)
17087    cePos = ce.offset + ce.source.length;
17088  else {
17089    const name = fcName[0].toUpperCase() + fcName.substring(1);
17090    const msg = atRoot ? `${name} must end with a ${expectedEnd}` : `${name} in block collection must be sufficiently indented and end with a ${expectedEnd}`;
17091    onError(offset, atRoot ? "MISSING_CHAR" : "BAD_INDENT", msg);
17092    if (ce && ce.source.length !== 1)
17093      ee2.unshift(ce);
17094  }
17095  if (ee2.length > 0) {
17096    const end = resolveEnd(ee2, cePos, ctx.options.strict, onError);
17097    if (end.comment) {
17098      if (coll.comment)
17099        coll.comment += "\n" + end.comment;
17100      else
17101        coll.comment = end.comment;
17102    }
17103    coll.range = [fc.offset, cePos, end.offset];
17104  } else {
17105    coll.range = [fc.offset, cePos, cePos];
17106  }
17107  return coll;
17108}
17109
17110// node_modules/yaml/browser/dist/compose/compose-collection.js
17111function resolveCollection(CN2, ctx, token, onError, tagName, tag) {
17112  const coll = token.type === "block-map" ? resolveBlockMap(CN2, ctx, token, onError, tag) : token.type === "block-seq" ? resolveBlockSeq(CN2, ctx, token, onError, tag) : resolveFlowCollection(CN2, ctx, token, onError, tag);
17113  const Coll = coll.constructor;
17114  if (tagName === "!" || tagName === Coll.tagName) {
17115    coll.tag = Coll.tagName;
17116    return coll;
17117  }
17118  if (tagName)
17119    coll.tag = tagName;
17120  return coll;
17121}
17122function composeCollection(CN2, ctx, token, props, onError) {
17123  var _a2, _b2, _c;
17124  const tagToken = props.tag;
17125  const tagName = !tagToken ? null : ctx.directives.tagName(tagToken.source, (msg) => onError(tagToken, "TAG_RESOLVE_FAILED", msg));
17126  if (token.type === "block-seq") {
17127    const { anchor, newlineAfterProp: nl2 } = props;
17128    const lastProp = anchor && tagToken ? anchor.offset > tagToken.offset ? anchor : tagToken : anchor != null ? anchor : tagToken;
17129    if (lastProp && (!nl2 || nl2.offset < lastProp.offset)) {
17130      const message = "Missing newline after block sequence props";
17131      onError(lastProp, "MISSING_CHAR", message);
17132    }
17133  }
17134  const expType = token.type === "block-map" ? "map" : token.type === "block-seq" ? "seq" : token.start.source === "{" ? "map" : "seq";
17135  if (!tagToken || !tagName || tagName === "!" || tagName === YAMLMap.tagName && expType === "map" || tagName === YAMLSeq.tagName && expType === "seq") {
17136    return resolveCollection(CN2, ctx, token, onError, tagName);
17137  }
17138  let tag = ctx.schema.tags.find((t3) => t3.tag === tagName && t3.collection === expType);
17139  if (!tag) {
17140    const kt2 = ctx.schema.knownTags[tagName];
17141    if (kt2 && kt2.collection === expType) {
17142      ctx.schema.tags.push(Object.assign({}, kt2, { default: false }));
17143      tag = kt2;
17144    } else {
17145      if (kt2) {
17146        onError(tagToken, "BAD_COLLECTION_TYPE", `${kt2.tag} used for ${expType} collection, but expects ${(_a2 = kt2.collection) != null ? _a2 : "scalar"}`, true);
17147      } else {
17148        onError(tagToken, "TAG_RESOLVE_FAILED", `Unresolved tag: ${tagName}`, true);
17149      }
17150      return resolveCollection(CN2, ctx, token, onError, tagName);
17151    }
17152  }
17153  const coll = resolveCollection(CN2, ctx, token, onError, tagName, tag);
17154  const res = (_c = (_b2 = tag.resolve) == null ? void 0 : _b2.call(tag, coll, (msg) => onError(tagToken, "TAG_RESOLVE_FAILED", msg), ctx.options)) != null ? _c : coll;
17155  const node = isNode(res) ? res : new Scalar(res);
17156  node.range = coll.range;
17157  node.tag = tagName;
17158  if (tag == null ? void 0 : tag.format)
17159    node.format = tag.format;
17160  return node;
17161}
17162
17163// node_modules/yaml/browser/dist/compose/resolve-block-scalar.js
17164function resolveBlockScalar(ctx, scalar, onError) {
17165  const start = scalar.offset;
17166  const header = parseBlockScalarHeader(scalar, ctx.options.strict, onError);
17167  if (!header)
17168    return { value: "", type: null, comment: "", range: [start, start, start] };
17169  const type = header.mode === ">" ? Scalar.BLOCK_FOLDED : Scalar.BLOCK_LITERAL;
17170  const lines = scalar.source ? splitLines(scalar.source) : [];
17171  let chompStart = lines.length;
17172  for (let i = lines.length - 1; i >= 0; --i) {
17173    const content = lines[i][1];
17174    if (content === "" || content === "\r")
17175      chompStart = i;
17176    else
17177      break;
17178  }
17179  if (chompStart === 0) {
17180    const value2 = header.chomp === "+" && lines.length > 0 ? "\n".repeat(Math.max(1, lines.length - 1)) : "";
17181    let end2 = start + header.length;
17182    if (scalar.source)
17183      end2 += scalar.source.length;
17184    return { value: value2, type, comment: header.comment, range: [start, end2, end2] };
17185  }
17186  let trimIndent = scalar.indent + header.indent;
17187  let offset = scalar.offset + header.length;
17188  let contentStart = 0;
17189  for (let i = 0; i < chompStart; ++i) {
17190    const [indent, content] = lines[i];
17191    if (content === "" || content === "\r") {
17192      if (header.indent === 0 && indent.length > trimIndent)
17193        trimIndent = indent.length;
17194    } else {
17195      if (indent.length < trimIndent) {
17196        const message = "Block scalars with more-indented leading empty lines must use an explicit indentation indicator";
17197        onError(offset + indent.length, "MISSING_CHAR", message);
17198      }
17199      if (header.indent === 0)
17200        trimIndent = indent.length;
17201      contentStart = i;
17202      if (trimIndent === 0 && !ctx.atRoot) {
17203        const message = "Block scalar values in collections must be indented";
17204        onError(offset, "BAD_INDENT", message);
17205      }
17206      break;
17207    }
17208    offset += indent.length + content.length + 1;
17209  }
17210  for (let i = lines.length - 1; i >= chompStart; --i) {
17211    if (lines[i][0].length > trimIndent)
17212      chompStart = i + 1;
17213  }
17214  let value = "";
17215  let sep = "";
17216  let prevMoreIndented = false;
17217  for (let i = 0; i < contentStart; ++i)
17218    value += lines[i][0].slice(trimIndent) + "\n";
17219  for (let i = contentStart; i < chompStart; ++i) {
17220    let [indent, content] = lines[i];
17221    offset += indent.length + content.length + 1;
17222    const crlf = content[content.length - 1] === "\r";
17223    if (crlf)
17224      content = content.slice(0, -1);
17225    if (content && indent.length < trimIndent) {
17226      const src = header.indent ? "explicit indentation indicator" : "first line";
17227      const message = `Block scalar lines must not be less indented than their ${src}`;
17228      onError(offset - content.length - (crlf ? 2 : 1), "BAD_INDENT", message);
17229      indent = "";
17230    }
17231    if (type === Scalar.BLOCK_LITERAL) {
17232      value += sep + indent.slice(trimIndent) + content;
17233      sep = "\n";
17234    } else if (indent.length > trimIndent || content[0] === "	") {
17235      if (sep === " ")
17236        sep = "\n";
17237      else if (!prevMoreIndented && sep === "\n")
17238        sep = "\n\n";
17239      value += sep + indent.slice(trimIndent) + content;
17240      sep = "\n";
17241      prevMoreIndented = true;
17242    } else if (content === "") {
17243      if (sep === "\n")
17244        value += "\n";
17245      else
17246        sep = "\n";
17247    } else {
17248      value += sep + content;
17249      sep = " ";
17250      prevMoreIndented = false;
17251    }
17252  }
17253  switch (header.chomp) {
17254    case "-":
17255      break;
17256    case "+":
17257      for (let i = chompStart; i < lines.length; ++i)
17258        value += "\n" + lines[i][0].slice(trimIndent);
17259      if (value[value.length - 1] !== "\n")
17260        value += "\n";
17261      break;
17262    default:
17263      value += "\n";
17264  }
17265  const end = start + header.length + scalar.source.length;
17266  return { value, type, comment: header.comment, range: [start, end, end] };
17267}
17268function parseBlockScalarHeader({ offset, props }, strict, onError) {
17269  if (props[0].type !== "block-scalar-header") {
17270    onError(props[0], "IMPOSSIBLE", "Block scalar header not found");
17271    return null;
17272  }
17273  const { source } = props[0];
17274  const mode = source[0];
17275  let indent = 0;
17276  let chomp = "";
17277  let error = -1;
17278  for (let i = 1; i < source.length; ++i) {
17279    const ch = source[i];
17280    if (!chomp && (ch === "-" || ch === "+"))
17281      chomp = ch;
17282    else {
17283      const n4 = Number(ch);
17284      if (!indent && n4)
17285        indent = n4;
17286      else if (error === -1)
17287        error = offset + i;
17288    }
17289  }
17290  if (error !== -1)
17291    onError(error, "UNEXPECTED_TOKEN", `Block scalar header includes extra characters: ${source}`);
17292  let hasSpace = false;
17293  let comment = "";
17294  let length = source.length;
17295  for (let i = 1; i < props.length; ++i) {
17296    const token = props[i];
17297    switch (token.type) {
17298      case "space":
17299        hasSpace = true;
17300      // fallthrough
17301      case "newline":
17302        length += token.source.length;
17303        break;
17304      case "comment":
17305        if (strict && !hasSpace) {
17306          const message = "Comments must be separated from other tokens by white space characters";
17307          onError(token, "MISSING_CHAR", message);
17308        }
17309        length += token.source.length;
17310        comment = token.source.substring(1);
17311        break;
17312      case "error":
17313        onError(token, "UNEXPECTED_TOKEN", token.message);
17314        length += token.source.length;
17315        break;
17316      /* istanbul ignore next should not happen */
17317      default: {
17318        const message = `Unexpected token in block scalar header: ${token.type}`;
17319        onError(token, "UNEXPECTED_TOKEN", message);
17320        const ts = token.source;
17321        if (ts && typeof ts === "string")
17322          length += ts.length;
17323      }
17324    }
17325  }
17326  return { mode, indent, chomp, comment, length };
17327}
17328function splitLines(source) {
17329  const split = source.split(/\n( *)/);
17330  const first = split[0];
17331  const m2 = first.match(/^( *)/);
17332  const line0 = (m2 == null ? void 0 : m2[1]) ? [m2[1], first.slice(m2[1].length)] : ["", first];
17333  const lines = [line0];
17334  for (let i = 1; i < split.length; i += 2)
17335    lines.push([split[i], split[i + 1]]);
17336  return lines;
17337}
17338
17339// node_modules/yaml/browser/dist/compose/resolve-flow-scalar.js
17340function resolveFlowScalar(scalar, strict, onError) {
17341  const { offset, type, source, end } = scalar;
17342  let _type;
17343  let value;
17344  const _onError = (rel, code, msg) => onError(offset + rel, code, msg);
17345  switch (type) {
17346    case "scalar":
17347      _type = Scalar.PLAIN;
17348      value = plainValue(source, _onError);
17349      break;
17350    case "single-quoted-scalar":
17351      _type = Scalar.QUOTE_SINGLE;
17352      value = singleQuotedValue(source, _onError);
17353      break;
17354    case "double-quoted-scalar":
17355      _type = Scalar.QUOTE_DOUBLE;
17356      value = doubleQuotedValue(source, _onError);
17357      break;
17358    /* istanbul ignore next should not happen */
17359    default:
17360      onError(scalar, "UNEXPECTED_TOKEN", `Expected a flow scalar value, but found: ${type}`);
17361      return {
17362        value: "",
17363        type: null,
17364        comment: "",
17365        range: [offset, offset + source.length, offset + source.length]
17366      };
17367  }
17368  const valueEnd = offset + source.length;
17369  const re = resolveEnd(end, valueEnd, strict, onError);
17370  return {
17371    value,
17372    type: _type,
17373    comment: re.comment,
17374    range: [offset, valueEnd, re.offset]
17375  };
17376}
17377function plainValue(source, onError) {
17378  let badChar = "";
17379  switch (source[0]) {
17380    /* istanbul ignore next should not happen */
17381    case "	":
17382      badChar = "a tab character";
17383      break;
17384    case ",":
17385      badChar = "flow indicator character ,";
17386      break;
17387    case "%":
17388      badChar = "directive indicator character %";
17389      break;
17390    case "|":
17391    case ">": {
17392      badChar = `block scalar indicator ${source[0]}`;
17393      break;
17394    }
17395    case "@":
17396    case "`": {
17397      badChar = `reserved character ${source[0]}`;
17398      break;
17399    }
17400  }
17401  if (badChar)
17402    onError(0, "BAD_SCALAR_START", `Plain value cannot start with ${badChar}`);
17403  return foldLines(source);
17404}
17405function singleQuotedValue(source, onError) {
17406  if (source[source.length - 1] !== "'" || source.length === 1)
17407    onError(source.length, "MISSING_CHAR", "Missing closing 'quote");
17408  return foldLines(source.slice(1, -1)).replace(/''/g, "'");
17409}
17410function foldLines(source) {
17411  var _a2;
17412  let first, line;
17413  try {
17414    first = new RegExp("(.*?)(?<![ 	])[ 	]*\r?\n", "sy");
17415    line = new RegExp("[ 	]*(.*?)(?:(?<![ 	])[ 	]*)?\r?\n", "sy");
17416  } catch (e) {
17417    first = new RegExp("(.*?)[ \\t]*\\r?\\n", "sy");
17418    line = new RegExp("[ \\t]*(.*?)[ \\t]*\\r?\\n", "sy");
17419  }
17420  let match = first.exec(source);
17421  if (!match)
17422    return source;
17423  let res = match[1];
17424  let sep = " ";
17425  let pos = first.lastIndex;
17426  line.lastIndex = pos;
17427  while (match = line.exec(source)) {
17428    if (match[1] === "") {
17429      if (sep === "\n")
17430        res += sep;
17431      else
17432        sep = "\n";
17433    } else {
17434      res += sep + match[1];
17435      sep = " ";
17436    }
17437    pos = line.lastIndex;
17438  }
17439  const last = new RegExp("[ \\t]*(.*)", "sy");
17440  last.lastIndex = pos;
17441  match = last.exec(source);
17442  return res + sep + ((_a2 = match == null ? void 0 : match[1]) != null ? _a2 : "");
17443}
17444function doubleQuotedValue(source, onError) {
17445  let res = "";
17446  for (let i = 1; i < source.length - 1; ++i) {
17447    const ch = source[i];
17448    if (ch === "\r" && source[i + 1] === "\n")
17449      continue;
17450    if (ch === "\n") {
17451      const { fold, offset } = foldNewline(source, i);
17452      res += fold;
17453      i = offset;
17454    } else if (ch === "\\") {
17455      let next = source[++i];
17456      const cc = escapeCodes[next];
17457      if (cc)
17458        res += cc;
17459      else if (next === "\n") {
17460        next = source[i + 1];
17461        while (next === " " || next === "	")
17462          next = source[++i + 1];
17463      } else if (next === "\r" && source[i + 1] === "\n") {
17464        next = source[++i + 1];
17465        while (next === " " || next === "	")
17466          next = source[++i + 1];
17467      } else if (next === "x" || next === "u" || next === "U") {
17468        const length = { x: 2, u: 4, U: 8 }[next];
17469        res += parseCharCode(source, i + 1, length, onError);
17470        i += length;
17471      } else {
17472        const raw = source.substr(i - 1, 2);
17473        onError(i - 1, "BAD_DQ_ESCAPE", `Invalid escape sequence ${raw}`);
17474        res += raw;
17475      }
17476    } else if (ch === " " || ch === "	") {
17477      const wsStart = i;
17478      let next = source[i + 1];
17479      while (next === " " || next === "	")
17480        next = source[++i + 1];
17481      if (next !== "\n" && !(next === "\r" && source[i + 2] === "\n"))
17482        res += i > wsStart ? source.slice(wsStart, i + 1) : ch;
17483    } else {
17484      res += ch;
17485    }
17486  }
17487  if (source[source.length - 1] !== '"' || source.length === 1)
17488    onError(source.length, "MISSING_CHAR", 'Missing closing "quote');
17489  return res;
17490}
17491function foldNewline(source, offset) {
17492  let fold = "";
17493  let ch = source[offset + 1];
17494  while (ch === " " || ch === "	" || ch === "\n" || ch === "\r") {
17495    if (ch === "\r" && source[offset + 2] !== "\n")
17496      break;
17497    if (ch === "\n")
17498      fold += "\n";
17499    offset += 1;
17500    ch = source[offset + 1];
17501  }
17502  if (!fold)
17503    fold = " ";
17504  return { fold, offset };
17505}
17506var escapeCodes = {
17507  "0": "\0",
17508  // null character
17509  a: "\x07",
17510  // bell character
17511  b: "\b",
17512  // backspace
17513  e: "\x1B",
17514  // escape character
17515  f: "\f",
17516  // form feed
17517  n: "\n",
17518  // line feed
17519  r: "\r",
17520  // carriage return
17521  t: "	",
17522  // horizontal tab
17523  v: "\v",
17524  // vertical tab
17525  N: "\x85",
17526  // Unicode next line
17527  _: "\xA0",
17528  // Unicode non-breaking space
17529  L: "\u2028",
17530  // Unicode line separator
17531  P: "\u2029",
17532  // Unicode paragraph separator
17533  " ": " ",
17534  '"': '"',
17535  "/": "/",
17536  "\\": "\\",
17537  "	": "	"
17538};
17539function parseCharCode(source, offset, length, onError) {
17540  const cc = source.substr(offset, length);
17541  const ok = cc.length === length && /^[0-9a-fA-F]+$/.test(cc);
17542  const code = ok ? parseInt(cc, 16) : NaN;
17543  if (isNaN(code)) {
17544    const raw = source.substr(offset - 2, length + 2);
17545    onError(offset - 2, "BAD_DQ_ESCAPE", `Invalid escape sequence ${raw}`);
17546    return raw;
17547  }
17548  return String.fromCodePoint(code);
17549}
17550
17551// node_modules/yaml/browser/dist/compose/compose-scalar.js
17552function composeScalar(ctx, token, tagToken, onError) {
17553  const { value, type, comment, range } = token.type === "block-scalar" ? resolveBlockScalar(ctx, token, onError) : resolveFlowScalar(token, ctx.options.strict, onError);
17554  const tagName = tagToken ? ctx.directives.tagName(tagToken.source, (msg) => onError(tagToken, "TAG_RESOLVE_FAILED", msg)) : null;
17555  let tag;
17556  if (ctx.options.stringKeys && ctx.atKey) {
17557    tag = ctx.schema[SCALAR];
17558  } else if (tagName)
17559    tag = findScalarTagByName(ctx.schema, value, tagName, tagToken, onError);
17560  else if (token.type === "scalar")
17561    tag = findScalarTagByTest(ctx, value, token, onError);
17562  else
17563    tag = ctx.schema[SCALAR];
17564  let scalar;
17565  try {
17566    const res = tag.resolve(value, (msg) => onError(tagToken != null ? tagToken : token, "TAG_RESOLVE_FAILED", msg), ctx.options);
17567    scalar = isScalar(res) ? res : new Scalar(res);
17568  } catch (error) {
17569    const msg = error instanceof Error ? error.message : String(error);
17570    onError(tagToken != null ? tagToken : token, "TAG_RESOLVE_FAILED", msg);
17571    scalar = new Scalar(value);
17572  }
17573  scalar.range = range;
17574  scalar.source = value;
17575  if (type)
17576    scalar.type = type;
17577  if (tagName)
17578    scalar.tag = tagName;
17579  if (tag.format)
17580    scalar.format = tag.format;
17581  if (comment)
17582    scalar.comment = comment;
17583  return scalar;
17584}
17585function findScalarTagByName(schema4, value, tagName, tagToken, onError) {
17586  var _a2;
17587  if (tagName === "!")
17588    return schema4[SCALAR];
17589  const matchWithTest = [];
17590  for (const tag of schema4.tags) {
17591    if (!tag.collection && tag.tag === tagName) {
17592      if (tag.default && tag.test)
17593        matchWithTest.push(tag);
17594      else
17595        return tag;
17596    }
17597  }
17598  for (const tag of matchWithTest)
17599    if ((_a2 = tag.test) == null ? void 0 : _a2.test(value))
17600      return tag;
17601  const kt2 = schema4.knownTags[tagName];
17602  if (kt2 && !kt2.collection) {
17603    schema4.tags.push(Object.assign({}, kt2, { default: false, test: void 0 }));
17604    return kt2;
17605  }
17606  onError(tagToken, "TAG_RESOLVE_FAILED", `Unresolved tag: ${tagName}`, tagName !== "tag:yaml.org,2002:str");
17607  return schema4[SCALAR];
17608}
17609function findScalarTagByTest({ atKey, directives, schema: schema4 }, value, token, onError) {
17610  var _a2;
17611  const tag = schema4.tags.find((tag2) => {
17612    var _a3;
17613    return (tag2.default === true || atKey && tag2.default === "key") && ((_a3 = tag2.test) == null ? void 0 : _a3.test(value));
17614  }) || schema4[SCALAR];
17615  if (schema4.compat) {
17616    const compat = (_a2 = schema4.compat.find((tag2) => {
17617      var _a3;
17618      return tag2.default && ((_a3 = tag2.test) == null ? void 0 : _a3.test(value));
17619    })) != null ? _a2 : schema4[SCALAR];
17620    if (tag.tag !== compat.tag) {
17621      const ts = directives.tagString(tag.tag);
17622      const cs = directives.tagString(compat.tag);
17623      const msg = `Value may be parsed as either ${ts} or ${cs}`;
17624      onError(token, "TAG_RESOLVE_FAILED", msg, true);
17625    }
17626  }
17627  return tag;
17628}
17629
17630// node_modules/yaml/browser/dist/compose/util-empty-scalar-position.js
17631function emptyScalarPosition(offset, before, pos) {
17632  if (before) {
17633    pos != null ? pos : pos = before.length;
17634    for (let i = pos - 1; i >= 0; --i) {
17635      let st2 = before[i];
17636      switch (st2.type) {
17637        case "space":
17638        case "comment":
17639        case "newline":
17640          offset -= st2.source.length;
17641          continue;
17642      }
17643      st2 = before[++i];
17644      while ((st2 == null ? void 0 : st2.type) === "space") {
17645        offset += st2.source.length;
17646        st2 = before[++i];
17647      }
17648      break;
17649    }
17650  }
17651  return offset;
17652}
17653
17654// node_modules/yaml/browser/dist/compose/compose-node.js
17655var CN = { composeNode, composeEmptyNode };
17656function composeNode(ctx, token, props, onError) {
17657  const atKey = ctx.atKey;
17658  const { spaceBefore, comment, anchor, tag } = props;
17659  let node;
17660  let isSrcToken = true;
17661  switch (token.type) {
17662    case "alias":
17663      node = composeAlias(ctx, token, onError);
17664      if (anchor || tag)
17665        onError(token, "ALIAS_PROPS", "An alias node must not specify any properties");
17666      break;
17667    case "scalar":
17668    case "single-quoted-scalar":
17669    case "double-quoted-scalar":
17670    case "block-scalar":
17671      node = composeScalar(ctx, token, tag, onError);
17672      if (anchor)
17673        node.anchor = anchor.source.substring(1);
17674      break;
17675    case "block-map":
17676    case "block-seq":
17677    case "flow-collection":
17678      node = composeCollection(CN, ctx, token, props, onError);
17679      if (anchor)
17680        node.anchor = anchor.source.substring(1);
17681      break;
17682    default: {
17683      const message = token.type === "error" ? token.message : `Unsupported token (type: ${token.type})`;
17684      onError(token, "UNEXPECTED_TOKEN", message);
17685      node = composeEmptyNode(ctx, token.offset, void 0, null, props, onError);
17686      isSrcToken = false;
17687    }
17688  }
17689  if (anchor && node.anchor === "")
17690    onError(anchor, "BAD_ALIAS", "Anchor cannot be an empty string");
17691  if (atKey && ctx.options.stringKeys && (!isScalar(node) || typeof node.value !== "string" || node.tag && node.tag !== "tag:yaml.org,2002:str")) {
17692    const msg = "With stringKeys, all keys must be strings";
17693    onError(tag != null ? tag : token, "NON_STRING_KEY", msg);
17694  }
17695  if (spaceBefore)
17696    node.spaceBefore = true;
17697  if (comment) {
17698    if (token.type === "scalar" && token.source === "")
17699      node.comment = comment;
17700    else
17701      node.commentBefore = comment;
17702  }
17703  if (ctx.options.keepSourceTokens && isSrcToken)
17704    node.srcToken = token;
17705  return node;
17706}
17707function composeEmptyNode(ctx, offset, before, pos, { spaceBefore, comment, anchor, tag, end }, onError) {
17708  const token = {
17709    type: "scalar",
17710    offset: emptyScalarPosition(offset, before, pos),
17711    indent: -1,
17712    source: ""
17713  };
17714  const node = composeScalar(ctx, token, tag, onError);
17715  if (anchor) {
17716    node.anchor = anchor.source.substring(1);
17717    if (node.anchor === "")
17718      onError(anchor, "BAD_ALIAS", "Anchor cannot be an empty string");
17719  }
17720  if (spaceBefore)
17721    node.spaceBefore = true;
17722  if (comment) {
17723    node.comment = comment;
17724    node.range[2] = end;
17725  }
17726  return node;
17727}
17728function composeAlias({ options }, { offset, source, end }, onError) {
17729  const alias = new Alias(source.substring(1));
17730  if (alias.source === "")
17731    onError(offset, "BAD_ALIAS", "Alias cannot be an empty string");
17732  if (alias.source.endsWith(":"))
17733    onError(offset + source.length - 1, "BAD_ALIAS", "Alias ending in : is ambiguous", true);
17734  const valueEnd = offset + source.length;
17735  const re = resolveEnd(end, valueEnd, options.strict, onError);
17736  alias.range = [offset, valueEnd, re.offset];
17737  if (re.comment)
17738    alias.comment = re.comment;
17739  return alias;
17740}
17741
17742// node_modules/yaml/browser/dist/compose/compose-doc.js
17743function composeDoc(options, directives, { offset, start, value, end }, onError) {
17744  const opts = Object.assign({ _directives: directives }, options);
17745  const doc = new Document(void 0, opts);
17746  const ctx = {
17747    atKey: false,
17748    atRoot: true,
17749    directives: doc.directives,
17750    options: doc.options,
17751    schema: doc.schema
17752  };
17753  const props = resolveProps(start, {
17754    indicator: "doc-start",
17755    next: value != null ? value : end == null ? void 0 : end[0],
17756    offset,
17757    onError,
17758    parentIndent: 0,
17759    startOnNewline: true
17760  });
17761  if (props.found) {
17762    doc.directives.docStart = true;
17763    if (value && (value.type === "block-map" || value.type === "block-seq") && !props.hasNewline)
17764      onError(props.end, "MISSING_CHAR", "Block collection cannot start on same line with directives-end marker");
17765  }
17766  doc.contents = value ? composeNode(ctx, value, props, onError) : composeEmptyNode(ctx, props.end, start, null, props, onError);
17767  const contentEnd = doc.contents.range[2];
17768  const re = resolveEnd(end, contentEnd, false, onError);
17769  if (re.comment)
17770    doc.comment = re.comment;
17771  doc.range = [offset, contentEnd, re.offset];
17772  return doc;
17773}
17774
17775// node_modules/yaml/browser/dist/compose/composer.js
17776function getErrorPos(src) {
17777  if (typeof src === "number")
17778    return [src, src + 1];
17779  if (Array.isArray(src))
17780    return src.length === 2 ? src : [src[0], src[1]];
17781  const { offset, source } = src;
17782  return [offset, offset + (typeof source === "string" ? source.length : 1)];
17783}
17784function parsePrelude(prelude) {
17785  var _a2;
17786  let comment = "";
17787  let atComment = false;
17788  let afterEmptyLine = false;
17789  for (let i = 0; i < prelude.length; ++i) {
17790    const source = prelude[i];
17791    switch (source[0]) {
17792      case "#":
17793        comment += (comment === "" ? "" : afterEmptyLine ? "\n\n" : "\n") + (source.substring(1) || " ");
17794        atComment = true;
17795        afterEmptyLine = false;
17796        break;
17797      case "%":
17798        if (((_a2 = prelude[i + 1]) == null ? void 0 : _a2[0]) !== "#")
17799          i += 1;
17800        atComment = false;
17801        break;
17802      default:
17803        if (!atComment)
17804          afterEmptyLine = true;
17805        atComment = false;
17806    }
17807  }
17808  return { comment, afterEmptyLine };
17809}
17810var Composer = class {
17811  constructor(options = {}) {
17812    this.doc = null;
17813    this.atDirectives = false;
17814    this.prelude = [];
17815    this.errors = [];
17816    this.warnings = [];
17817    this.onError = (source, code, message, warning) => {
17818      const pos = getErrorPos(source);
17819      if (warning)
17820        this.warnings.push(new YAMLWarning(pos, code, message));
17821      else
17822        this.errors.push(new YAMLParseError(pos, code, message));
17823    };
17824    this.directives = new Directives({ version: options.version || "1.2" });
17825    this.options = options;
17826  }
17827  decorate(doc, afterDoc) {
17828    const { comment, afterEmptyLine } = parsePrelude(this.prelude);
17829    if (comment) {
17830      const dc = doc.contents;
17831      if (afterDoc) {
17832        doc.comment = doc.comment ? `${doc.comment}
17833${comment}` : comment;
17834      } else if (afterEmptyLine || doc.directives.docStart || !dc) {
17835        doc.commentBefore = comment;
17836      } else if (isCollection(dc) && !dc.flow && dc.items.length > 0) {
17837        let it = dc.items[0];
17838        if (isPair(it))
17839          it = it.key;
17840        const cb = it.commentBefore;
17841        it.commentBefore = cb ? `${comment}
17842${cb}` : comment;
17843      } else {
17844        const cb = dc.commentBefore;
17845        dc.commentBefore = cb ? `${comment}
17846${cb}` : comment;
17847      }
17848    }
17849    if (afterDoc) {
17850      Array.prototype.push.apply(doc.errors, this.errors);
17851      Array.prototype.push.apply(doc.warnings, this.warnings);
17852    } else {
17853      doc.errors = this.errors;
17854      doc.warnings = this.warnings;
17855    }
17856    this.prelude = [];
17857    this.errors = [];
17858    this.warnings = [];
17859  }
17860  /**
17861   * Current stream status information.
17862   *
17863   * Mostly useful at the end of input for an empty stream.
17864   */
17865  streamInfo() {
17866    return {
17867      comment: parsePrelude(this.prelude).comment,
17868      directives: this.directives,
17869      errors: this.errors,
17870      warnings: this.warnings
17871    };
17872  }
17873  /**
17874   * Compose tokens into documents.
17875   *
17876   * @param forceDoc - If the stream contains no document, still emit a final document including any comments and directives that would be applied to a subsequent document.
17877   * @param endOffset - Should be set if `forceDoc` is also set, to set the document range end and to indicate errors correctly.
17878   */
17879  *compose(tokens, forceDoc = false, endOffset = -1) {
17880    for (const token of tokens)
17881      yield* __yieldStar(this.next(token));
17882    yield* __yieldStar(this.end(forceDoc, endOffset));
17883  }
17884  /** Advance the composer by one CST token. */
17885  *next(token) {
17886    switch (token.type) {
17887      case "directive":
17888        this.directives.add(token.source, (offset, message, warning) => {
17889          const pos = getErrorPos(token);
17890          pos[0] += offset;
17891          this.onError(pos, "BAD_DIRECTIVE", message, warning);
17892        });
17893        this.prelude.push(token.source);
17894        this.atDirectives = true;
17895        break;
17896      case "document": {
17897        const doc = composeDoc(this.options, this.directives, token, this.onError);
17898        if (this.atDirectives && !doc.directives.docStart)
17899          this.onError(token, "MISSING_CHAR", "Missing directives-end/doc-start indicator line");
17900        this.decorate(doc, false);
17901        if (this.doc)
17902          yield this.doc;
17903        this.doc = doc;
17904        this.atDirectives = false;
17905        break;
17906      }
17907      case "byte-order-mark":
17908      case "space":
17909        break;
17910      case "comment":
17911      case "newline":
17912        this.prelude.push(token.source);
17913        break;
17914      case "error": {
17915        const msg = token.source ? `${token.message}: ${JSON.stringify(token.source)}` : token.message;
17916        const error = new YAMLParseError(getErrorPos(token), "UNEXPECTED_TOKEN", msg);
17917        if (this.atDirectives || !this.doc)
17918          this.errors.push(error);
17919        else
17920          this.doc.errors.push(error);
17921        break;
17922      }
17923      case "doc-end": {
17924        if (!this.doc) {
17925          const msg = "Unexpected doc-end without preceding document";
17926          this.errors.push(new YAMLParseError(getErrorPos(token), "UNEXPECTED_TOKEN", msg));
17927          break;
17928        }
17929        this.doc.directives.docEnd = true;
17930        const end = resolveEnd(token.end, token.offset + token.source.length, this.doc.options.strict, this.onError);
17931        this.decorate(this.doc, true);
17932        if (end.comment) {
17933          const dc = this.doc.comment;
17934          this.doc.comment = dc ? `${dc}
17935${end.comment}` : end.comment;
17936        }
17937        this.doc.range[2] = end.offset;
17938        break;
17939      }
17940      default:
17941        this.errors.push(new YAMLParseError(getErrorPos(token), "UNEXPECTED_TOKEN", `Unsupported token ${token.type}`));
17942    }
17943  }
17944  /**
17945   * Call at end of input to yield any remaining document.
17946   *
17947   * @param forceDoc - If the stream contains no document, still emit a final document including any comments and directives that would be applied to a subsequent document.
17948   * @param endOffset - Should be set if `forceDoc` is also set, to set the document range end and to indicate errors correctly.
17949   */
17950  *end(forceDoc = false, endOffset = -1) {
17951    if (this.doc) {
17952      this.decorate(this.doc, true);
17953      yield this.doc;
17954      this.doc = null;
17955    } else if (forceDoc) {
17956      const opts = Object.assign({ _directives: this.directives }, this.options);
17957      const doc = new Document(void 0, opts);
17958      if (this.atDirectives)
17959        this.onError(endOffset, "MISSING_CHAR", "Missing directives-end indicator line");
17960      doc.range = [0, endOffset, endOffset];
17961      this.decorate(doc, false);
17962      yield doc;
17963    }
17964  }
17965};
17966
17967// node_modules/yaml/browser/dist/parse/cst.js
17968var cst_exports = {};
17969__export(cst_exports, {
17970  BOM: () => BOM,
17971  DOCUMENT: () => DOCUMENT,
17972  FLOW_END: () => FLOW_END,
17973  SCALAR: () => SCALAR2,
17974  createScalarToken: () => createScalarToken,
17975  isCollection: () => isCollection2,
17976  isScalar: () => isScalar2,
17977  prettyToken: () => prettyToken,
17978  resolveAsScalar: () => resolveAsScalar,
17979  setScalarValue: () => setScalarValue,
17980  stringify: () => stringify2,
17981  tokenType: () => tokenType,
17982  visit: () => visit2
17983});
17984
17985// node_modules/yaml/browser/dist/parse/cst-scalar.js
17986function resolveAsScalar(token, strict = true, onError) {
17987  if (token) {
17988    const _onError = (pos, code, message) => {
17989      const offset = typeof pos === "number" ? pos : Array.isArray(pos) ? pos[0] : pos.offset;
17990      if (onError)
17991        onError(offset, code, message);
17992      else
17993        throw new YAMLParseError([offset, offset + 1], code, message);
17994    };
17995    switch (token.type) {
17996      case "scalar":
17997      case "single-quoted-scalar":
17998      case "double-quoted-scalar":
17999        return resolveFlowScalar(token, strict, _onError);
18000      case "block-scalar":
18001        return resolveBlockScalar({ options: { strict } }, token, _onError);
18002    }
18003  }
18004  return null;
18005}
18006function createScalarToken(value, context) {
18007  var _a2;
18008  const { implicitKey = false, indent, inFlow = false, offset = -1, type = "PLAIN" } = context;
18009  const source = stringifyString({ type, value }, {
18010    implicitKey,
18011    indent: indent > 0 ? " ".repeat(indent) : "",
18012    inFlow,
18013    options: { blockQuote: true, lineWidth: -1 }
18014  });
18015  const end = (_a2 = context.end) != null ? _a2 : [
18016    { type: "newline", offset: -1, indent, source: "\n" }
18017  ];
18018  switch (source[0]) {
18019    case "|":
18020    case ">": {
18021      const he = source.indexOf("\n");
18022      const head = source.substring(0, he);
18023      const body = source.substring(he + 1) + "\n";
18024      const props = [
18025        { type: "block-scalar-header", offset, indent, source: head }
18026      ];
18027      if (!addEndtoBlockProps(props, end))
18028        props.push({ type: "newline", offset: -1, indent, source: "\n" });
18029      return { type: "block-scalar", offset, indent, props, source: body };
18030    }
18031    case '"':
18032      return { type: "double-quoted-scalar", offset, indent, source, end };
18033    case "'":
18034      return { type: "single-quoted-scalar", offset, indent, source, end };
18035    default:
18036      return { type: "scalar", offset, indent, source, end };
18037  }
18038}
18039function setScalarValue(token, value, context = {}) {
18040  let { afterKey = false, implicitKey = false, inFlow = false, type } = context;
18041  let indent = "indent" in token ? token.indent : null;
18042  if (afterKey && typeof indent === "number")
18043    indent += 2;
18044  if (!type)
18045    switch (token.type) {
18046      case "single-quoted-scalar":
18047        type = "QUOTE_SINGLE";
18048        break;
18049      case "double-quoted-scalar":
18050        type = "QUOTE_DOUBLE";
18051        break;
18052      case "block-scalar": {
18053        const header = token.props[0];
18054        if (header.type !== "block-scalar-header")
18055          throw new Error("Invalid block scalar header");
18056        type = header.source[0] === ">" ? "BLOCK_FOLDED" : "BLOCK_LITERAL";
18057        break;
18058      }
18059      default:
18060        type = "PLAIN";
18061    }
18062  const source = stringifyString({ type, value }, {
18063    implicitKey: implicitKey || indent === null,
18064    indent: indent !== null && indent > 0 ? " ".repeat(indent) : "",
18065    inFlow,
18066    options: { blockQuote: true, lineWidth: -1 }
18067  });
18068  switch (source[0]) {
18069    case "|":
18070    case ">":
18071      setBlockScalarValue(token, source);
18072      break;
18073    case '"':
18074      setFlowScalarValue(token, source, "double-quoted-scalar");
18075      break;
18076    case "'":
18077      setFlowScalarValue(token, source, "single-quoted-scalar");
18078      break;
18079    default:
18080      setFlowScalarValue(token, source, "scalar");
18081  }
18082}
18083function setBlockScalarValue(token, source) {
18084  const he = source.indexOf("\n");
18085  const head = source.substring(0, he);
18086  const body = source.substring(he + 1) + "\n";
18087  if (token.type === "block-scalar") {
18088    const header = token.props[0];
18089    if (header.type !== "block-scalar-header")
18090      throw new Error("Invalid block scalar header");
18091    header.source = head;
18092    token.source = body;
18093  } else {
18094    const { offset } = token;
18095    const indent = "indent" in token ? token.indent : -1;
18096    const props = [
18097      { type: "block-scalar-header", offset, indent, source: head }
18098    ];
18099    if (!addEndtoBlockProps(props, "end" in token ? token.end : void 0))
18100      props.push({ type: "newline", offset: -1, indent, source: "\n" });
18101    for (const key of Object.keys(token))
18102      if (key !== "type" && key !== "offset")
18103        delete token[key];
18104    Object.assign(token, { type: "block-scalar", indent, props, source: body });
18105  }
18106}
18107function addEndtoBlockProps(props, end) {
18108  if (end)
18109    for (const st2 of end)
18110      switch (st2.type) {
18111        case "space":
18112        case "comment":
18113          props.push(st2);
18114          break;
18115        case "newline":
18116          props.push(st2);
18117          return true;
18118      }
18119  return false;
18120}
18121function setFlowScalarValue(token, source, type) {
18122  switch (token.type) {
18123    case "scalar":
18124    case "double-quoted-scalar":
18125    case "single-quoted-scalar":
18126      token.type = type;
18127      token.source = source;
18128      break;
18129    case "block-scalar": {
18130      const end = token.props.slice(1);
18131      let oa = source.length;
18132      if (token.props[0].type === "block-scalar-header")
18133        oa -= token.props[0].source.length;
18134      for (const tok of end)
18135        tok.offset += oa;
18136      delete token.props;
18137      Object.assign(token, { type, source, end });
18138      break;
18139    }
18140    case "block-map":
18141    case "block-seq": {
18142      const offset = token.offset + source.length;
18143      const nl2 = { type: "newline", offset, indent: token.indent, source: "\n" };
18144      delete token.items;
18145      Object.assign(token, { type, source, end: [nl2] });
18146      break;
18147    }
18148    default: {
18149      const indent = "indent" in token ? token.indent : -1;
18150      const end = "end" in token && Array.isArray(token.end) ? token.end.filter((st2) => st2.type === "space" || st2.type === "comment" || st2.type === "newline") : [];
18151      for (const key of Object.keys(token))
18152        if (key !== "type" && key !== "offset")
18153          delete token[key];
18154      Object.assign(token, { type, indent, source, end });
18155    }
18156  }
18157}
18158
18159// node_modules/yaml/browser/dist/parse/cst-stringify.js
18160var stringify2 = (cst) => "type" in cst ? stringifyToken(cst) : stringifyItem(cst);
18161function stringifyToken(token) {
18162  switch (token.type) {
18163    case "block-scalar": {
18164      let res = "";
18165      for (const tok of token.props)
18166        res += stringifyToken(tok);
18167      return res + token.source;
18168    }
18169    case "block-map":
18170    case "block-seq": {
18171      let res = "";
18172      for (const item of token.items)
18173        res += stringifyItem(item);
18174      return res;
18175    }
18176    case "flow-collection": {
18177      let res = token.start.source;
18178      for (const item of token.items)
18179        res += stringifyItem(item);
18180      for (const st2 of token.end)
18181        res += st2.source;
18182      return res;
18183    }
18184    case "document": {
18185      let res = stringifyItem(token);
18186      if (token.end)
18187        for (const st2 of token.end)
18188          res += st2.source;
18189      return res;
18190    }
18191    default: {
18192      let res = token.source;
18193      if ("end" in token && token.end)
18194        for (const st2 of token.end)
18195          res += st2.source;
18196      return res;
18197    }
18198  }
18199}
18200function stringifyItem({ start, key, sep, value }) {
18201  let res = "";
18202  for (const st2 of start)
18203    res += st2.source;
18204  if (key)
18205    res += stringifyToken(key);
18206  if (sep)
18207    for (const st2 of sep)
18208      res += st2.source;
18209  if (value)
18210    res += stringifyToken(value);
18211  return res;
18212}
18213
18214// node_modules/yaml/browser/dist/parse/cst-visit.js
18215var BREAK2 = Symbol("break visit");
18216var SKIP2 = Symbol("skip children");
18217var REMOVE2 = Symbol("remove item");
18218function visit2(cst, visitor) {
18219  if ("type" in cst && cst.type === "document")
18220    cst = { start: cst.start, value: cst.value };
18221  _visit(Object.freeze([]), cst, visitor);
18222}
18223visit2.BREAK = BREAK2;
18224visit2.SKIP = SKIP2;
18225visit2.REMOVE = REMOVE2;
18226visit2.itemAtPath = (cst, path5) => {
18227  let item = cst;
18228  for (const [field, index] of path5) {
18229    const tok = item == null ? void 0 : item[field];
18230    if (tok && "items" in tok) {
18231      item = tok.items[index];
18232    } else
18233      return void 0;
18234  }
18235  return item;
18236};
18237visit2.parentCollection = (cst, path5) => {
18238  const parent = visit2.itemAtPath(cst, path5.slice(0, -1));
18239  const field = path5[path5.length - 1][0];
18240  const coll = parent == null ? void 0 : parent[field];
18241  if (coll && "items" in coll)
18242    return coll;
18243  throw new Error("Parent collection not found");
18244};
18245function _visit(path5, item, visitor) {
18246  let ctrl = visitor(item, path5);
18247  if (typeof ctrl === "symbol")
18248    return ctrl;
18249  for (const field of ["key", "value"]) {
18250    const token = item[field];
18251    if (token && "items" in token) {
18252      for (let i = 0; i < token.items.length; ++i) {
18253        const ci2 = _visit(Object.freeze(path5.concat([[field, i]])), token.items[i], visitor);
18254        if (typeof ci2 === "number")
18255          i = ci2 - 1;
18256        else if (ci2 === BREAK2)
18257          return BREAK2;
18258        else if (ci2 === REMOVE2) {
18259          token.items.splice(i, 1);
18260          i -= 1;
18261        }
18262      }
18263      if (typeof ctrl === "function" && field === "key")
18264        ctrl = ctrl(item, path5);
18265    }
18266  }
18267  return typeof ctrl === "function" ? ctrl(item, path5) : ctrl;
18268}
18269
18270// node_modules/yaml/browser/dist/parse/cst.js
18271var BOM = "\uFEFF";
18272var DOCUMENT = "";
18273var FLOW_END = "";
18274var SCALAR2 = "";
18275var isCollection2 = (token) => !!token && "items" in token;
18276var isScalar2 = (token) => !!token && (token.type === "scalar" || token.type === "single-quoted-scalar" || token.type === "double-quoted-scalar" || token.type === "block-scalar");
18277function prettyToken(token) {
18278  switch (token) {
18279    case BOM:
18280      return "<BOM>";
18281    case DOCUMENT:
18282      return "<DOC>";
18283    case FLOW_END:
18284      return "<FLOW_END>";
18285    case SCALAR2:
18286      return "<SCALAR>";
18287    default:
18288      return JSON.stringify(token);
18289  }
18290}
18291function tokenType(source) {
18292  switch (source) {
18293    case BOM:
18294      return "byte-order-mark";
18295    case DOCUMENT:
18296      return "doc-mode";
18297    case FLOW_END:
18298      return "flow-error-end";
18299    case SCALAR2:
18300      return "scalar";
18301    case "---":
18302      return "doc-start";
18303    case "...":
18304      return "doc-end";
18305    case "":
18306    case "\n":
18307    case "\r\n":
18308      return "newline";
18309    case "-":
18310      return "seq-item-ind";
18311    case "?":
18312      return "explicit-key-ind";
18313    case ":":
18314      return "map-value-ind";
18315    case "{":
18316      return "flow-map-start";
18317    case "}":
18318      return "flow-map-end";
18319    case "[":
18320      return "flow-seq-start";
18321    case "]":
18322      return "flow-seq-end";
18323    case ",":
18324      return "comma";
18325  }
18326  switch (source[0]) {
18327    case " ":
18328    case "	":
18329      return "space";
18330    case "#":
18331      return "comment";
18332    case "%":
18333      return "directive-line";
18334    case "*":
18335      return "alias";
18336    case "&":
18337      return "anchor";
18338    case "!":
18339      return "tag";
18340    case "'":
18341      return "single-quoted-scalar";
18342    case '"':
18343      return "double-quoted-scalar";
18344    case "|":
18345    case ">":
18346      return "block-scalar-header";
18347  }
18348  return null;
18349}
18350
18351// node_modules/yaml/browser/dist/parse/lexer.js
18352function isEmpty(ch) {
18353  switch (ch) {
18354    case void 0:
18355    case " ":
18356    case "\n":
18357    case "\r":
18358    case "	":
18359      return true;
18360    default:
18361      return false;
18362  }
18363}
18364var hexDigits = new Set("0123456789ABCDEFabcdef");
18365var tagChars = new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()");
18366var flowIndicatorChars = new Set(",[]{}");
18367var invalidAnchorChars = new Set(" ,[]{}\n\r	");
18368var isNotAnchorChar = (ch) => !ch || invalidAnchorChars.has(ch);
18369var Lexer = class {
18370  constructor() {
18371    this.atEnd = false;
18372    this.blockScalarIndent = -1;
18373    this.blockScalarKeep = false;
18374    this.buffer = "";
18375    this.flowKey = false;
18376    this.flowLevel = 0;
18377    this.indentNext = 0;
18378    this.indentValue = 0;
18379    this.lineEndPos = null;
18380    this.next = null;
18381    this.pos = 0;
18382  }
18383  /**
18384   * Generate YAML tokens from the `source` string. If `incomplete`,
18385   * a part of the last line may be left as a buffer for the next call.
18386   *
18387   * @returns A generator of lexical tokens
18388   */
18389  *lex(source, incomplete = false) {
18390    var _a2;
18391    if (source) {
18392      if (typeof source !== "string")
18393        throw TypeError("source is not a string");
18394      this.buffer = this.buffer ? this.buffer + source : source;
18395      this.lineEndPos = null;
18396    }
18397    this.atEnd = !incomplete;
18398    let next = (_a2 = this.next) != null ? _a2 : "stream";
18399    while (next && (incomplete || this.hasChars(1)))
18400      next = yield* __yieldStar(this.parseNext(next));
18401  }
18402  atLineEnd() {
18403    let i = this.pos;
18404    let ch = this.buffer[i];
18405    while (ch === " " || ch === "	")
18406      ch = this.buffer[++i];
18407    if (!ch || ch === "#" || ch === "\n")
18408      return true;
18409    if (ch === "\r")
18410      return this.buffer[i + 1] === "\n";
18411    return false;
18412  }
18413  charAt(n4) {
18414    return this.buffer[this.pos + n4];
18415  }
18416  continueScalar(offset) {
18417    let ch = this.buffer[offset];
18418    if (this.indentNext > 0) {
18419      let indent = 0;
18420      while (ch === " ")
18421        ch = this.buffer[++indent + offset];
18422      if (ch === "\r") {
18423        const next = this.buffer[indent + offset + 1];
18424        if (next === "\n" || !next && !this.atEnd)
18425          return offset + indent + 1;
18426      }
18427      return ch === "\n" || indent >= this.indentNext || !ch && !this.atEnd ? offset + indent : -1;
18428    }
18429    if (ch === "-" || ch === ".") {
18430      const dt2 = this.buffer.substr(offset, 3);
18431      if ((dt2 === "---" || dt2 === "...") && isEmpty(this.buffer[offset + 3]))
18432        return -1;
18433    }
18434    return offset;
18435  }
18436  getLine() {
18437    let end = this.lineEndPos;
18438    if (typeof end !== "number" || end !== -1 && end < this.pos) {
18439      end = this.buffer.indexOf("\n", this.pos);
18440      this.lineEndPos = end;
18441    }
18442    if (end === -1)
18443      return this.atEnd ? this.buffer.substring(this.pos) : null;
18444    if (this.buffer[end - 1] === "\r")
18445      end -= 1;
18446    return this.buffer.substring(this.pos, end);
18447  }
18448  hasChars(n4) {
18449    return this.pos + n4 <= this.buffer.length;
18450  }
18451  setNext(state) {
18452    this.buffer = this.buffer.substring(this.pos);
18453    this.pos = 0;
18454    this.lineEndPos = null;
18455    this.next = state;
18456    return null;
18457  }
18458  peek(n4) {
18459    return this.buffer.substr(this.pos, n4);
18460  }
18461  *parseNext(next) {
18462    switch (next) {
18463      case "stream":
18464        return yield* __yieldStar(this.parseStream());
18465      case "line-start":
18466        return yield* __yieldStar(this.parseLineStart());
18467      case "block-start":
18468        return yield* __yieldStar(this.parseBlockStart());
18469      case "doc":
18470        return yield* __yieldStar(this.parseDocument());
18471      case "flow":
18472        return yield* __yieldStar(this.parseFlowCollection());
18473      case "quoted-scalar":
18474        return yield* __yieldStar(this.parseQuotedScalar());
18475      case "block-scalar":
18476        return yield* __yieldStar(this.parseBlockScalar());
18477      case "plain-scalar":
18478        return yield* __yieldStar(this.parsePlainScalar());
18479    }
18480  }
18481  *parseStream() {
18482    let line = this.getLine();
18483    if (line === null)
18484      return this.setNext("stream");
18485    if (line[0] === BOM) {
18486      yield* __yieldStar(this.pushCount(1));
18487      line = line.substring(1);
18488    }
18489    if (line[0] === "%") {
18490      let dirEnd = line.length;
18491      let cs = line.indexOf("#");
18492      while (cs !== -1) {
18493        const ch = line[cs - 1];
18494        if (ch === " " || ch === "	") {
18495          dirEnd = cs - 1;
18496          break;
18497        } else {
18498          cs = line.indexOf("#", cs + 1);
18499        }
18500      }
18501      while (true) {
18502        const ch = line[dirEnd - 1];
18503        if (ch === " " || ch === "	")
18504          dirEnd -= 1;
18505        else
18506          break;
18507      }
18508      const n4 = (yield* __yieldStar(this.pushCount(dirEnd))) + (yield* __yieldStar(this.pushSpaces(true)));
18509      yield* __yieldStar(this.pushCount(line.length - n4));
18510      this.pushNewline();
18511      return "stream";
18512    }
18513    if (this.atLineEnd()) {
18514      const sp = yield* __yieldStar(this.pushSpaces(true));
18515      yield* __yieldStar(this.pushCount(line.length - sp));
18516      yield* __yieldStar(this.pushNewline());
18517      return "stream";
18518    }
18519    yield DOCUMENT;
18520    return yield* __yieldStar(this.parseLineStart());
18521  }
18522  *parseLineStart() {
18523    const ch = this.charAt(0);
18524    if (!ch && !this.atEnd)
18525      return this.setNext("line-start");
18526    if (ch === "-" || ch === ".") {
18527      if (!this.atEnd && !this.hasChars(4))
18528        return this.setNext("line-start");
18529      const s = this.peek(3);
18530      if ((s === "---" || s === "...") && isEmpty(this.charAt(3))) {
18531        yield* __yieldStar(this.pushCount(3));
18532        this.indentValue = 0;
18533        this.indentNext = 0;
18534        return s === "---" ? "doc" : "stream";
18535      }
18536    }
18537    this.indentValue = yield* __yieldStar(this.pushSpaces(false));
18538    if (this.indentNext > this.indentValue && !isEmpty(this.charAt(1)))
18539      this.indentNext = this.indentValue;
18540    return yield* __yieldStar(this.parseBlockStart());
18541  }
18542  *parseBlockStart() {
18543    const [ch0, ch1] = this.peek(2);
18544    if (!ch1 && !this.atEnd)
18545      return this.setNext("block-start");
18546    if ((ch0 === "-" || ch0 === "?" || ch0 === ":") && isEmpty(ch1)) {
18547      const n4 = (yield* __yieldStar(this.pushCount(1))) + (yield* __yieldStar(this.pushSpaces(true)));
18548      this.indentNext = this.indentValue + 1;
18549      this.indentValue += n4;
18550      return yield* __yieldStar(this.parseBlockStart());
18551    }
18552    return "doc";
18553  }
18554  *parseDocument() {
18555    yield* __yieldStar(this.pushSpaces(true));
18556    const line = this.getLine();
18557    if (line === null)
18558      return this.setNext("doc");
18559    let n4 = yield* __yieldStar(this.pushIndicators());
18560    switch (line[n4]) {
18561      case "#":
18562        yield* __yieldStar(this.pushCount(line.length - n4));
18563      // fallthrough
18564      case void 0:
18565        yield* __yieldStar(this.pushNewline());
18566        return yield* __yieldStar(this.parseLineStart());
18567      case "{":
18568      case "[":
18569        yield* __yieldStar(this.pushCount(1));
18570        this.flowKey = false;
18571        this.flowLevel = 1;
18572        return "flow";
18573      case "}":
18574      case "]":
18575        yield* __yieldStar(this.pushCount(1));
18576        return "doc";
18577      case "*":
18578        yield* __yieldStar(this.pushUntil(isNotAnchorChar));
18579        return "doc";
18580      case '"':
18581      case "'":
18582        return yield* __yieldStar(this.parseQuotedScalar());
18583      case "|":
18584      case ">":
18585        n4 += yield* __yieldStar(this.parseBlockScalarHeader());
18586        n4 += yield* __yieldStar(this.pushSpaces(true));
18587        yield* __yieldStar(this.pushCount(line.length - n4));
18588        yield* __yieldStar(this.pushNewline());
18589        return yield* __yieldStar(this.parseBlockScalar());
18590      default:
18591        return yield* __yieldStar(this.parsePlainScalar());
18592    }
18593  }
18594  *parseFlowCollection() {
18595    let nl2, sp;
18596    let indent = -1;
18597    do {
18598      nl2 = yield* __yieldStar(this.pushNewline());
18599      if (nl2 > 0) {
18600        sp = yield* __yieldStar(this.pushSpaces(false));
18601        this.indentValue = indent = sp;
18602      } else {
18603        sp = 0;
18604      }
18605      sp += yield* __yieldStar(this.pushSpaces(true));
18606    } while (nl2 + sp > 0);
18607    const line = this.getLine();
18608    if (line === null)
18609      return this.setNext("flow");
18610    if (indent !== -1 && indent < this.indentNext && line[0] !== "#" || indent === 0 && (line.startsWith("---") || line.startsWith("...")) && isEmpty(line[3])) {
18611      const atFlowEndMarker = indent === this.indentNext - 1 && this.flowLevel === 1 && (line[0] === "]" || line[0] === "}");
18612      if (!atFlowEndMarker) {
18613        this.flowLevel = 0;
18614        yield FLOW_END;
18615        return yield* __yieldStar(this.parseLineStart());
18616      }
18617    }
18618    let n4 = 0;
18619    while (line[n4] === ",") {
18620      n4 += yield* __yieldStar(this.pushCount(1));
18621      n4 += yield* __yieldStar(this.pushSpaces(true));
18622      this.flowKey = false;
18623    }
18624    n4 += yield* __yieldStar(this.pushIndicators());
18625    switch (line[n4]) {
18626      case void 0:
18627        return "flow";
18628      case "#":
18629        yield* __yieldStar(this.pushCount(line.length - n4));
18630        return "flow";
18631      case "{":
18632      case "[":
18633        yield* __yieldStar(this.pushCount(1));
18634        this.flowKey = false;
18635        this.flowLevel += 1;
18636        return "flow";
18637      case "}":
18638      case "]":
18639        yield* __yieldStar(this.pushCount(1));
18640        this.flowKey = true;
18641        this.flowLevel -= 1;
18642        return this.flowLevel ? "flow" : "doc";
18643      case "*":
18644        yield* __yieldStar(this.pushUntil(isNotAnchorChar));
18645        return "flow";
18646      case '"':
18647      case "'":
18648        this.flowKey = true;
18649        return yield* __yieldStar(this.parseQuotedScalar());
18650      case ":": {
18651        const next = this.charAt(1);
18652        if (this.flowKey || isEmpty(next) || next === ",") {
18653          this.flowKey = false;
18654          yield* __yieldStar(this.pushCount(1));
18655          yield* __yieldStar(this.pushSpaces(true));
18656          return "flow";
18657        }
18658      }
18659      // fallthrough
18660      default:
18661        this.flowKey = false;
18662        return yield* __yieldStar(this.parsePlainScalar());
18663    }
18664  }
18665  *parseQuotedScalar() {
18666    const quote = this.charAt(0);
18667    let end = this.buffer.indexOf(quote, this.pos + 1);
18668    if (quote === "'") {
18669      while (end !== -1 && this.buffer[end + 1] === "'")
18670        end = this.buffer.indexOf("'", end + 2);
18671    } else {
18672      while (end !== -1) {
18673        let n4 = 0;
18674        while (this.buffer[end - 1 - n4] === "\\")
18675          n4 += 1;
18676        if (n4 % 2 === 0)
18677          break;
18678        end = this.buffer.indexOf('"', end + 1);
18679      }
18680    }
18681    const qb = this.buffer.substring(0, end);
18682    let nl2 = qb.indexOf("\n", this.pos);
18683    if (nl2 !== -1) {
18684      while (nl2 !== -1) {
18685        const cs = this.continueScalar(nl2 + 1);
18686        if (cs === -1)
18687          break;
18688        nl2 = qb.indexOf("\n", cs);
18689      }
18690      if (nl2 !== -1) {
18691        end = nl2 - (qb[nl2 - 1] === "\r" ? 2 : 1);
18692      }
18693    }
18694    if (end === -1) {
18695      if (!this.atEnd)
18696        return this.setNext("quoted-scalar");
18697      end = this.buffer.length;
18698    }
18699    yield* __yieldStar(this.pushToIndex(end + 1, false));
18700    return this.flowLevel ? "flow" : "doc";
18701  }
18702  *parseBlockScalarHeader() {
18703    this.blockScalarIndent = -1;
18704    this.blockScalarKeep = false;
18705    let i = this.pos;
18706    while (true) {
18707      const ch = this.buffer[++i];
18708      if (ch === "+")
18709        this.blockScalarKeep = true;
18710      else if (ch > "0" && ch <= "9")
18711        this.blockScalarIndent = Number(ch) - 1;
18712      else if (ch !== "-")
18713        break;
18714    }
18715    return yield* __yieldStar(this.pushUntil((ch) => isEmpty(ch) || ch === "#"));
18716  }
18717  *parseBlockScalar() {
18718    let nl2 = this.pos - 1;
18719    let indent = 0;
18720    let ch;
18721    loop: for (let i2 = this.pos; ch = this.buffer[i2]; ++i2) {
18722      switch (ch) {
18723        case " ":
18724          indent += 1;
18725          break;
18726        case "\n":
18727          nl2 = i2;
18728          indent = 0;
18729          break;
18730        case "\r": {
18731          const next = this.buffer[i2 + 1];
18732          if (!next && !this.atEnd)
18733            return this.setNext("block-scalar");
18734          if (next === "\n")
18735            break;
18736        }
18737        // fallthrough
18738        default:
18739          break loop;
18740      }
18741    }
18742    if (!ch && !this.atEnd)
18743      return this.setNext("block-scalar");
18744    if (indent >= this.indentNext) {
18745      if (this.blockScalarIndent === -1)
18746        this.indentNext = indent;
18747      else {
18748        this.indentNext = this.blockScalarIndent + (this.indentNext === 0 ? 1 : this.indentNext);
18749      }
18750      do {
18751        const cs = this.continueScalar(nl2 + 1);
18752        if (cs === -1)
18753          break;
18754        nl2 = this.buffer.indexOf("\n", cs);
18755      } while (nl2 !== -1);
18756      if (nl2 === -1) {
18757        if (!this.atEnd)
18758          return this.setNext("block-scalar");
18759        nl2 = this.buffer.length;
18760      }
18761    }
18762    let i = nl2 + 1;
18763    ch = this.buffer[i];
18764    while (ch === " ")
18765      ch = this.buffer[++i];
18766    if (ch === "	") {
18767      while (ch === "	" || ch === " " || ch === "\r" || ch === "\n")
18768        ch = this.buffer[++i];
18769      nl2 = i - 1;
18770    } else if (!this.blockScalarKeep) {
18771      do {
18772        let i2 = nl2 - 1;
18773        let ch2 = this.buffer[i2];
18774        if (ch2 === "\r")
18775          ch2 = this.buffer[--i2];
18776        const lastChar = i2;
18777        while (ch2 === " ")
18778          ch2 = this.buffer[--i2];
18779        if (ch2 === "\n" && i2 >= this.pos && i2 + 1 + indent > lastChar)
18780          nl2 = i2;
18781        else
18782          break;
18783      } while (true);
18784    }
18785    yield SCALAR2;
18786    yield* __yieldStar(this.pushToIndex(nl2 + 1, true));
18787    return yield* __yieldStar(this.parseLineStart());
18788  }
18789  *parsePlainScalar() {
18790    const inFlow = this.flowLevel > 0;
18791    let end = this.pos - 1;
18792    let i = this.pos - 1;
18793    let ch;
18794    while (ch = this.buffer[++i]) {
18795      if (ch === ":") {
18796        const next = this.buffer[i + 1];
18797        if (isEmpty(next) || inFlow && flowIndicatorChars.has(next))
18798          break;
18799        end = i;
18800      } else if (isEmpty(ch)) {
18801        let next = this.buffer[i + 1];
18802        if (ch === "\r") {
18803          if (next === "\n") {
18804            i += 1;
18805            ch = "\n";
18806            next = this.buffer[i + 1];
18807          } else
18808            end = i;
18809        }
18810        if (next === "#" || inFlow && flowIndicatorChars.has(next))
18811          break;
18812        if (ch === "\n") {
18813          const cs = this.continueScalar(i + 1);
18814          if (cs === -1)
18815            break;
18816          i = Math.max(i, cs - 2);
18817        }
18818      } else {
18819        if (inFlow && flowIndicatorChars.has(ch))
18820          break;
18821        end = i;
18822      }
18823    }
18824    if (!ch && !this.atEnd)
18825      return this.setNext("plain-scalar");
18826    yield SCALAR2;
18827    yield* __yieldStar(this.pushToIndex(end + 1, true));
18828    return inFlow ? "flow" : "doc";
18829  }
18830  *pushCount(n4) {
18831    if (n4 > 0) {
18832      yield this.buffer.substr(this.pos, n4);
18833      this.pos += n4;
18834      return n4;
18835    }
18836    return 0;
18837  }
18838  *pushToIndex(i, allowEmpty) {
18839    const s = this.buffer.slice(this.pos, i);
18840    if (s) {
18841      yield s;
18842      this.pos += s.length;
18843      return s.length;
18844    } else if (allowEmpty)
18845      yield "";
18846    return 0;
18847  }
18848  *pushIndicators() {
18849    switch (this.charAt(0)) {
18850      case "!":
18851        return (yield* __yieldStar(this.pushTag())) + (yield* __yieldStar(this.pushSpaces(true))) + (yield* __yieldStar(this.pushIndicators()));
18852      case "&":
18853        return (yield* __yieldStar(this.pushUntil(isNotAnchorChar))) + (yield* __yieldStar(this.pushSpaces(true))) + (yield* __yieldStar(this.pushIndicators()));
18854      case "-":
18855      // this is an error
18856      case "?":
18857      // this is an error outside flow collections
18858      case ":": {
18859        const inFlow = this.flowLevel > 0;
18860        const ch1 = this.charAt(1);
18861        if (isEmpty(ch1) || inFlow && flowIndicatorChars.has(ch1)) {
18862          if (!inFlow)
18863            this.indentNext = this.indentValue + 1;
18864          else if (this.flowKey)
18865            this.flowKey = false;
18866          return (yield* __yieldStar(this.pushCount(1))) + (yield* __yieldStar(this.pushSpaces(true))) + (yield* __yieldStar(this.pushIndicators()));
18867        }
18868      }
18869    }
18870    return 0;
18871  }
18872  *pushTag() {
18873    if (this.charAt(1) === "<") {
18874      let i = this.pos + 2;
18875      let ch = this.buffer[i];
18876      while (!isEmpty(ch) && ch !== ">")
18877        ch = this.buffer[++i];
18878      return yield* __yieldStar(this.pushToIndex(ch === ">" ? i + 1 : i, false));
18879    } else {
18880      let i = this.pos + 1;
18881      let ch = this.buffer[i];
18882      while (ch) {
18883        if (tagChars.has(ch))
18884          ch = this.buffer[++i];
18885        else if (ch === "%" && hexDigits.has(this.buffer[i + 1]) && hexDigits.has(this.buffer[i + 2])) {
18886          ch = this.buffer[i += 3];
18887        } else
18888          break;
18889      }
18890      return yield* __yieldStar(this.pushToIndex(i, false));
18891    }
18892  }
18893  *pushNewline() {
18894    const ch = this.buffer[this.pos];
18895    if (ch === "\n")
18896      return yield* __yieldStar(this.pushCount(1));
18897    else if (ch === "\r" && this.charAt(1) === "\n")
18898      return yield* __yieldStar(this.pushCount(2));
18899    else
18900      return 0;
18901  }
18902  *pushSpaces(allowTabs) {
18903    let i = this.pos - 1;
18904    let ch;
18905    do {
18906      ch = this.buffer[++i];
18907    } while (ch === " " || allowTabs && ch === "	");
18908    const n4 = i - this.pos;
18909    if (n4 > 0) {
18910      yield this.buffer.substr(this.pos, n4);
18911      this.pos = i;
18912    }
18913    return n4;
18914  }
18915  *pushUntil(test) {
18916    let i = this.pos;
18917    let ch = this.buffer[i];
18918    while (!test(ch))
18919      ch = this.buffer[++i];
18920    return yield* __yieldStar(this.pushToIndex(i, false));
18921  }
18922};
18923
18924// node_modules/yaml/browser/dist/parse/line-counter.js
18925var LineCounter = class {
18926  constructor() {
18927    this.lineStarts = [];
18928    this.addNewLine = (offset) => this.lineStarts.push(offset);
18929    this.linePos = (offset) => {
18930      let low = 0;
18931      let high = this.lineStarts.length;
18932      while (low < high) {
18933        const mid = low + high >> 1;
18934        if (this.lineStarts[mid] < offset)
18935          low = mid + 1;
18936        else
18937          high = mid;
18938      }
18939      if (this.lineStarts[low] === offset)
18940        return { line: low + 1, col: 1 };
18941      if (low === 0)
18942        return { line: 0, col: offset };
18943      const start = this.lineStarts[low - 1];
18944      return { line: low, col: offset - start + 1 };
18945    };
18946  }
18947};
18948
18949// node_modules/yaml/browser/dist/parse/parser.js
18950function includesToken(list, type) {
18951  for (let i = 0; i < list.length; ++i)
18952    if (list[i].type === type)
18953      return true;
18954  return false;
18955}
18956function findNonEmptyIndex(list) {
18957  for (let i = 0; i < list.length; ++i) {
18958    switch (list[i].type) {
18959      case "space":
18960      case "comment":
18961      case "newline":
18962        break;
18963      default:
18964        return i;
18965    }
18966  }
18967  return -1;
18968}
18969function isFlowToken(token) {
18970  switch (token == null ? void 0 : token.type) {
18971    case "alias":
18972    case "scalar":
18973    case "single-quoted-scalar":
18974    case "double-quoted-scalar":
18975    case "flow-collection":
18976      return true;
18977    default:
18978      return false;
18979  }
18980}
18981function getPrevProps(parent) {
18982  var _a2;
18983  switch (parent.type) {
18984    case "document":
18985      return parent.start;
18986    case "block-map": {
18987      const it = parent.items[parent.items.length - 1];
18988      return (_a2 = it.sep) != null ? _a2 : it.start;
18989    }
18990    case "block-seq":
18991      return parent.items[parent.items.length - 1].start;
18992    /* istanbul ignore next should not happen */
18993    default:
18994      return [];
18995  }
18996}
18997function getFirstKeyStartProps(prev) {
18998  var _a2;
18999  if (prev.length === 0)
19000    return [];
19001  let i = prev.length;
19002  loop: while (--i >= 0) {
19003    switch (prev[i].type) {
19004      case "doc-start":
19005      case "explicit-key-ind":
19006      case "map-value-ind":
19007      case "seq-item-ind":
19008      case "newline":
19009        break loop;
19010    }
19011  }
19012  while (((_a2 = prev[++i]) == null ? void 0 : _a2.type) === "space") {
19013  }
19014  return prev.splice(i, prev.length);
19015}
19016function fixFlowSeqItems(fc) {
19017  if (fc.start.type === "flow-seq-start") {
19018    for (const it of fc.items) {
19019      if (it.sep && !it.value && !includesToken(it.start, "explicit-key-ind") && !includesToken(it.sep, "map-value-ind")) {
19020        if (it.key)
19021          it.value = it.key;
19022        delete it.key;
19023        if (isFlowToken(it.value)) {
19024          if (it.value.end)
19025            Array.prototype.push.apply(it.value.end, it.sep);
19026          else
19027            it.value.end = it.sep;
19028        } else
19029          Array.prototype.push.apply(it.start, it.sep);
19030        delete it.sep;
19031      }
19032    }
19033  }
19034}
19035var Parser = class {
19036  /**
19037   * @param onNewLine - If defined, called separately with the start position of
19038   *   each new line (in `parse()`, including the start of input).
19039   */
19040  constructor(onNewLine) {
19041    this.atNewLine = true;
19042    this.atScalar = false;
19043    this.indent = 0;
19044    this.offset = 0;
19045    this.onKeyLine = false;
19046    this.stack = [];
19047    this.source = "";
19048    this.type = "";
19049    this.lexer = new Lexer();
19050    this.onNewLine = onNewLine;
19051  }
19052  /**
19053   * Parse `source` as a YAML stream.
19054   * If `incomplete`, a part of the last line may be left as a buffer for the next call.
19055   *
19056   * Errors are not thrown, but yielded as `{ type: 'error', message }` tokens.
19057   *
19058   * @returns A generator of tokens representing each directive, document, and other structure.
19059   */
19060  *parse(source, incomplete = false) {
19061    if (this.onNewLine && this.offset === 0)
19062      this.onNewLine(0);
19063    for (const lexeme of this.lexer.lex(source, incomplete))
19064      yield* __yieldStar(this.next(lexeme));
19065    if (!incomplete)
19066      yield* __yieldStar(this.end());
19067  }
19068  /**
19069   * Advance the parser by the `source` of one lexical token.
19070   */
19071  *next(source) {
19072    this.source = source;
19073    if (this.atScalar) {
19074      this.atScalar = false;
19075      yield* __yieldStar(this.step());
19076      this.offset += source.length;
19077      return;
19078    }
19079    const type = tokenType(source);
19080    if (!type) {
19081      const message = `Not a YAML token: ${source}`;
19082      yield* __yieldStar(this.pop({ type: "error", offset: this.offset, message, source }));
19083      this.offset += source.length;
19084    } else if (type === "scalar") {
19085      this.atNewLine = false;
19086      this.atScalar = true;
19087      this.type = "scalar";
19088    } else {
19089      this.type = type;
19090      yield* __yieldStar(this.step());
19091      switch (type) {
19092        case "newline":
19093          this.atNewLine = true;
19094          this.indent = 0;
19095          if (this.onNewLine)
19096            this.onNewLine(this.offset + source.length);
19097          break;
19098        case "space":
19099          if (this.atNewLine && source[0] === " ")
19100            this.indent += source.length;
19101          break;
19102        case "explicit-key-ind":
19103        case "map-value-ind":
19104        case "seq-item-ind":
19105          if (this.atNewLine)
19106            this.indent += source.length;
19107          break;
19108        case "doc-mode":
19109        case "flow-error-end":
19110          return;
19111        default:
19112          this.atNewLine = false;
19113      }
19114      this.offset += source.length;
19115    }
19116  }
19117  /** Call at end of input to push out any remaining constructions */
19118  *end() {
19119    while (this.stack.length > 0)
19120      yield* __yieldStar(this.pop());
19121  }
19122  get sourceToken() {
19123    const st2 = {
19124      type: this.type,
19125      offset: this.offset,
19126      indent: this.indent,
19127      source: this.source
19128    };
19129    return st2;
19130  }
19131  *step() {
19132    const top = this.peek(1);
19133    if (this.type === "doc-end" && (!top || top.type !== "doc-end")) {
19134      while (this.stack.length > 0)
19135        yield* __yieldStar(this.pop());
19136      this.stack.push({
19137        type: "doc-end",
19138        offset: this.offset,
19139        source: this.source
19140      });
19141      return;
19142    }
19143    if (!top)
19144      return yield* __yieldStar(this.stream());
19145    switch (top.type) {
19146      case "document":
19147        return yield* __yieldStar(this.document(top));
19148      case "alias":
19149      case "scalar":
19150      case "single-quoted-scalar":
19151      case "double-quoted-scalar":
19152        return yield* __yieldStar(this.scalar(top));
19153      case "block-scalar":
19154        return yield* __yieldStar(this.blockScalar(top));
19155      case "block-map":
19156        return yield* __yieldStar(this.blockMap(top));
19157      case "block-seq":
19158        return yield* __yieldStar(this.blockSequence(top));
19159      case "flow-collection":
19160        return yield* __yieldStar(this.flowCollection(top));
19161      case "doc-end":
19162        return yield* __yieldStar(this.documentEnd(top));
19163    }
19164    yield* __yieldStar(this.pop());
19165  }
19166  peek(n4) {
19167    return this.stack[this.stack.length - n4];
19168  }
19169  *pop(error) {
19170    const token = error != null ? error : this.stack.pop();
19171    if (!token) {
19172      const message = "Tried to pop an empty stack";
19173      yield { type: "error", offset: this.offset, source: "", message };
19174    } else if (this.stack.length === 0) {
19175      yield token;
19176    } else {
19177      const top = this.peek(1);
19178      if (token.type === "block-scalar") {
19179        token.indent = "indent" in top ? top.indent : 0;
19180      } else if (token.type === "flow-collection" && top.type === "document") {
19181        token.indent = 0;
19182      }
19183      if (token.type === "flow-collection")
19184        fixFlowSeqItems(token);
19185      switch (top.type) {
19186        case "document":
19187          top.value = token;
19188          break;
19189        case "block-scalar":
19190          top.props.push(token);
19191          break;
19192        case "block-map": {
19193          const it = top.items[top.items.length - 1];
19194          if (it.value) {
19195            top.items.push({ start: [], key: token, sep: [] });
19196            this.onKeyLine = true;
19197            return;
19198          } else if (it.sep) {
19199            it.value = token;
19200          } else {
19201            Object.assign(it, { key: token, sep: [] });
19202            this.onKeyLine = !it.explicitKey;
19203            return;
19204          }
19205          break;
19206        }
19207        case "block-seq": {
19208          const it = top.items[top.items.length - 1];
19209          if (it.value)
19210            top.items.push({ start: [], value: token });
19211          else
19212            it.value = token;
19213          break;
19214        }
19215        case "flow-collection": {
19216          const it = top.items[top.items.length - 1];
19217          if (!it || it.value)
19218            top.items.push({ start: [], key: token, sep: [] });
19219          else if (it.sep)
19220            it.value = token;
19221          else
19222            Object.assign(it, { key: token, sep: [] });
19223          return;
19224        }
19225        /* istanbul ignore next should not happen */
19226        default:
19227          yield* __yieldStar(this.pop());
19228          yield* __yieldStar(this.pop(token));
19229      }
19230      if ((top.type === "document" || top.type === "block-map" || top.type === "block-seq") && (token.type === "block-map" || token.type === "block-seq")) {
19231        const last = token.items[token.items.length - 1];
19232        if (last && !last.sep && !last.value && last.start.length > 0 && findNonEmptyIndex(last.start) === -1 && (token.indent === 0 || last.start.every((st2) => st2.type !== "comment" || st2.indent < token.indent))) {
19233          if (top.type === "document")
19234            top.end = last.start;
19235          else
19236            top.items.push({ start: last.start });
19237          token.items.splice(-1, 1);
19238        }
19239      }
19240    }
19241  }
19242  *stream() {
19243    switch (this.type) {
19244      case "directive-line":
19245        yield { type: "directive", offset: this.offset, source: this.source };
19246        return;
19247      case "byte-order-mark":
19248      case "space":
19249      case "comment":
19250      case "newline":
19251        yield this.sourceToken;
19252        return;
19253      case "doc-mode":
19254      case "doc-start": {
19255        const doc = {
19256          type: "document",
19257          offset: this.offset,
19258          start: []
19259        };
19260        if (this.type === "doc-start")
19261          doc.start.push(this.sourceToken);
19262        this.stack.push(doc);
19263        return;
19264      }
19265    }
19266    yield {
19267      type: "error",
19268      offset: this.offset,
19269      message: `Unexpected ${this.type} token in YAML stream`,
19270      source: this.source
19271    };
19272  }
19273  *document(doc) {
19274    if (doc.value)
19275      return yield* __yieldStar(this.lineEnd(doc));
19276    switch (this.type) {
19277      case "doc-start": {
19278        if (findNonEmptyIndex(doc.start) !== -1) {
19279          yield* __yieldStar(this.pop());
19280          yield* __yieldStar(this.step());
19281        } else
19282          doc.start.push(this.sourceToken);
19283        return;
19284      }
19285      case "anchor":
19286      case "tag":
19287      case "space":
19288      case "comment":
19289      case "newline":
19290        doc.start.push(this.sourceToken);
19291        return;
19292    }
19293    const bv = this.startBlockValue(doc);
19294    if (bv)
19295      this.stack.push(bv);
19296    else {
19297      yield {
19298        type: "error",
19299        offset: this.offset,
19300        message: `Unexpected ${this.type} token in YAML document`,
19301        source: this.source
19302      };
19303    }
19304  }
19305  *scalar(scalar) {
19306    if (this.type === "map-value-ind") {
19307      const prev = getPrevProps(this.peek(2));
19308      const start = getFirstKeyStartProps(prev);
19309      let sep;
19310      if (scalar.end) {
19311        sep = scalar.end;
19312        sep.push(this.sourceToken);
19313        delete scalar.end;
19314      } else
19315        sep = [this.sourceToken];
19316      const map2 = {
19317        type: "block-map",
19318        offset: scalar.offset,
19319        indent: scalar.indent,
19320        items: [{ start, key: scalar, sep }]
19321      };
19322      this.onKeyLine = true;
19323      this.stack[this.stack.length - 1] = map2;
19324    } else
19325      yield* __yieldStar(this.lineEnd(scalar));
19326  }
19327  *blockScalar(scalar) {
19328    switch (this.type) {
19329      case "space":
19330      case "comment":
19331      case "newline":
19332        scalar.props.push(this.sourceToken);
19333        return;
19334      case "scalar":
19335        scalar.source = this.source;
19336        this.atNewLine = true;
19337        this.indent = 0;
19338        if (this.onNewLine) {
19339          let nl2 = this.source.indexOf("\n") + 1;
19340          while (nl2 !== 0) {
19341            this.onNewLine(this.offset + nl2);
19342            nl2 = this.source.indexOf("\n", nl2) + 1;
19343          }
19344        }
19345        yield* __yieldStar(this.pop());
19346        break;
19347      /* istanbul ignore next should not happen */
19348      default:
19349        yield* __yieldStar(this.pop());
19350        yield* __yieldStar(this.step());
19351    }
19352  }
19353  *blockMap(map2) {
19354    var _a2;
19355    const it = map2.items[map2.items.length - 1];
19356    switch (this.type) {
19357      case "newline":
19358        this.onKeyLine = false;
19359        if (it.value) {
19360          const end = "end" in it.value ? it.value.end : void 0;
19361          const last = Array.isArray(end) ? end[end.length - 1] : void 0;
19362          if ((last == null ? void 0 : last.type) === "comment")
19363            end == null ? void 0 : end.push(this.sourceToken);
19364          else
19365            map2.items.push({ start: [this.sourceToken] });
19366        } else if (it.sep) {
19367          it.sep.push(this.sourceToken);
19368        } else {
19369          it.start.push(this.sourceToken);
19370        }
19371        return;
19372      case "space":
19373      case "comment":
19374        if (it.value) {
19375          map2.items.push({ start: [this.sourceToken] });
19376        } else if (it.sep) {
19377          it.sep.push(this.sourceToken);
19378        } else {
19379          if (this.atIndentedComment(it.start, map2.indent)) {
19380            const prev = map2.items[map2.items.length - 2];
19381            const end = (_a2 = prev == null ? void 0 : prev.value) == null ? void 0 : _a2.end;
19382            if (Array.isArray(end)) {
19383              Array.prototype.push.apply(end, it.start);
19384              end.push(this.sourceToken);
19385              map2.items.pop();
19386              return;
19387            }
19388          }
19389          it.start.push(this.sourceToken);
19390        }
19391        return;
19392    }
19393    if (this.indent >= map2.indent) {
19394      const atMapIndent = !this.onKeyLine && this.indent === map2.indent;
19395      const atNextItem = atMapIndent && (it.sep || it.explicitKey) && this.type !== "seq-item-ind";
19396      let start = [];
19397      if (atNextItem && it.sep && !it.value) {
19398        const nl2 = [];
19399        for (let i = 0; i < it.sep.length; ++i) {
19400          const st2 = it.sep[i];
19401          switch (st2.type) {
19402            case "newline":
19403              nl2.push(i);
19404              break;
19405            case "space":
19406              break;
19407            case "comment":
19408              if (st2.indent > map2.indent)
19409                nl2.length = 0;
19410              break;
19411            default:
19412              nl2.length = 0;
19413          }
19414        }
19415        if (nl2.length >= 2)
19416          start = it.sep.splice(nl2[1]);
19417      }
19418      switch (this.type) {
19419        case "anchor":
19420        case "tag":
19421          if (atNextItem || it.value) {
19422            start.push(this.sourceToken);
19423            map2.items.push({ start });
19424            this.onKeyLine = true;
19425          } else if (it.sep) {
19426            it.sep.push(this.sourceToken);
19427          } else {
19428            it.start.push(this.sourceToken);
19429          }
19430          return;
19431        case "explicit-key-ind":
19432          if (!it.sep && !it.explicitKey) {
19433            it.start.push(this.sourceToken);
19434            it.explicitKey = true;
19435          } else if (atNextItem || it.value) {
19436            start.push(this.sourceToken);
19437            map2.items.push({ start, explicitKey: true });
19438          } else {
19439            this.stack.push({
19440              type: "block-map",
19441              offset: this.offset,
19442              indent: this.indent,
19443              items: [{ start: [this.sourceToken], explicitKey: true }]
19444            });
19445          }
19446          this.onKeyLine = true;
19447          return;
19448        case "map-value-ind":
19449          if (it.explicitKey) {
19450            if (!it.sep) {
19451              if (includesToken(it.start, "newline")) {
19452                Object.assign(it, { key: null, sep: [this.sourceToken] });
19453              } else {
19454                const start2 = getFirstKeyStartProps(it.start);
19455                this.stack.push({
19456                  type: "block-map",
19457                  offset: this.offset,
19458                  indent: this.indent,
19459                  items: [{ start: start2, key: null, sep: [this.sourceToken] }]
19460                });
19461              }
19462            } else if (it.value) {
19463              map2.items.push({ start: [], key: null, sep: [this.sourceToken] });
19464            } else if (includesToken(it.sep, "map-value-ind")) {
19465              this.stack.push({
19466                type: "block-map",
19467                offset: this.offset,
19468                indent: this.indent,
19469                items: [{ start, key: null, sep: [this.sourceToken] }]
19470              });
19471            } else if (isFlowToken(it.key) && !includesToken(it.sep, "newline")) {
19472              const start2 = getFirstKeyStartProps(it.start);
19473              const key = it.key;
19474              const sep = it.sep;
19475              sep.push(this.sourceToken);
19476              delete it.key;
19477              delete it.sep;
19478              this.stack.push({
19479                type: "block-map",
19480                offset: this.offset,
19481                indent: this.indent,
19482                items: [{ start: start2, key, sep }]
19483              });
19484            } else if (start.length > 0) {
19485              it.sep = it.sep.concat(start, this.sourceToken);
19486            } else {
19487              it.sep.push(this.sourceToken);
19488            }
19489          } else {
19490            if (!it.sep) {
19491              Object.assign(it, { key: null, sep: [this.sourceToken] });
19492            } else if (it.value || atNextItem) {
19493              map2.items.push({ start, key: null, sep: [this.sourceToken] });
19494            } else if (includesToken(it.sep, "map-value-ind")) {
19495              this.stack.push({
19496                type: "block-map",
19497                offset: this.offset,
19498                indent: this.indent,
19499                items: [{ start: [], key: null, sep: [this.sourceToken] }]
19500              });
19501            } else {
19502              it.sep.push(this.sourceToken);
19503            }
19504          }
19505          this.onKeyLine = true;
19506          return;
19507        case "alias":
19508        case "scalar":
19509        case "single-quoted-scalar":
19510        case "double-quoted-scalar": {
19511          const fs6 = this.flowScalar(this.type);
19512          if (atNextItem || it.value) {
19513            map2.items.push({ start, key: fs6, sep: [] });
19514            this.onKeyLine = true;
19515          } else if (it.sep) {
19516            this.stack.push(fs6);
19517          } else {
19518            Object.assign(it, { key: fs6, sep: [] });
19519            this.onKeyLine = true;
19520          }
19521          return;
19522        }
19523        default: {
19524          const bv = this.startBlockValue(map2);
19525          if (bv) {
19526            if (bv.type === "block-seq") {
19527              if (!it.explicitKey && it.sep && !includesToken(it.sep, "newline")) {
19528                yield* __yieldStar(this.pop({
19529                  type: "error",
19530                  offset: this.offset,
19531                  message: "Unexpected block-seq-ind on same line with key",
19532                  source: this.source
19533                }));
19534                return;
19535              }
19536            } else if (atMapIndent) {
19537              map2.items.push({ start });
19538            }
19539            this.stack.push(bv);
19540            return;
19541          }
19542        }
19543      }
19544    }
19545    yield* __yieldStar(this.pop());
19546    yield* __yieldStar(this.step());
19547  }
19548  *blockSequence(seq2) {
19549    var _a2;
19550    const it = seq2.items[seq2.items.length - 1];
19551    switch (this.type) {
19552      case "newline":
19553        if (it.value) {
19554          const end = "end" in it.value ? it.value.end : void 0;
19555          const last = Array.isArray(end) ? end[end.length - 1] : void 0;
19556          if ((last == null ? void 0 : last.type) === "comment")
19557            end == null ? void 0 : end.push(this.sourceToken);
19558          else
19559            seq2.items.push({ start: [this.sourceToken] });
19560        } else
19561          it.start.push(this.sourceToken);
19562        return;
19563      case "space":
19564      case "comment":
19565        if (it.value)
19566          seq2.items.push({ start: [this.sourceToken] });
19567        else {
19568          if (this.atIndentedComment(it.start, seq2.indent)) {
19569            const prev = seq2.items[seq2.items.length - 2];
19570            const end = (_a2 = prev == null ? void 0 : prev.value) == null ? void 0 : _a2.end;
19571            if (Array.isArray(end)) {
19572              Array.prototype.push.apply(end, it.start);
19573              end.push(this.sourceToken);
19574              seq2.items.pop();
19575              return;
19576            }
19577          }
19578          it.start.push(this.sourceToken);
19579        }
19580        return;
19581      case "anchor":
19582      case "tag":
19583        if (it.value || this.indent <= seq2.indent)
19584          break;
19585        it.start.push(this.sourceToken);
19586        return;
19587      case "seq-item-ind":
19588        if (this.indent !== seq2.indent)
19589          break;
19590        if (it.value || includesToken(it.start, "seq-item-ind"))
19591          seq2.items.push({ start: [this.sourceToken] });
19592        else
19593          it.start.push(this.sourceToken);
19594        return;
19595    }
19596    if (this.indent > seq2.indent) {
19597      const bv = this.startBlockValue(seq2);
19598      if (bv) {
19599        this.stack.push(bv);
19600        return;
19601      }
19602    }
19603    yield* __yieldStar(this.pop());
19604    yield* __yieldStar(this.step());
19605  }
19606  *flowCollection(fc) {
19607    const it = fc.items[fc.items.length - 1];
19608    if (this.type === "flow-error-end") {
19609      let top;
19610      do {
19611        yield* __yieldStar(this.pop());
19612        top = this.peek(1);
19613      } while (top && top.type === "flow-collection");
19614    } else if (fc.end.length === 0) {
19615      switch (this.type) {
19616        case "comma":
19617        case "explicit-key-ind":
19618          if (!it || it.sep)
19619            fc.items.push({ start: [this.sourceToken] });
19620          else
19621            it.start.push(this.sourceToken);
19622          return;
19623        case "map-value-ind":
19624          if (!it || it.value)
19625            fc.items.push({ start: [], key: null, sep: [this.sourceToken] });
19626          else if (it.sep)
19627            it.sep.push(this.sourceToken);
19628          else
19629            Object.assign(it, { key: null, sep: [this.sourceToken] });
19630          return;
19631        case "space":
19632        case "comment":
19633        case "newline":
19634        case "anchor":
19635        case "tag":
19636          if (!it || it.value)
19637            fc.items.push({ start: [this.sourceToken] });
19638          else if (it.sep)
19639            it.sep.push(this.sourceToken);
19640          else
19641            it.start.push(this.sourceToken);
19642          return;
19643        case "alias":
19644        case "scalar":
19645        case "single-quoted-scalar":
19646        case "double-quoted-scalar": {
19647          const fs6 = this.flowScalar(this.type);
19648          if (!it || it.value)
19649            fc.items.push({ start: [], key: fs6, sep: [] });
19650          else if (it.sep)
19651            this.stack.push(fs6);
19652          else
19653            Object.assign(it, { key: fs6, sep: [] });
19654          return;
19655        }
19656        case "flow-map-end":
19657        case "flow-seq-end":
19658          fc.end.push(this.sourceToken);
19659          return;
19660      }
19661      const bv = this.startBlockValue(fc);
19662      if (bv)
19663        this.stack.push(bv);
19664      else {
19665        yield* __yieldStar(this.pop());
19666        yield* __yieldStar(this.step());
19667      }
19668    } else {
19669      const parent = this.peek(2);
19670      if (parent.type === "block-map" && (this.type === "map-value-ind" && parent.indent === fc.indent || this.type === "newline" && !parent.items[parent.items.length - 1].sep)) {
19671        yield* __yieldStar(this.pop());
19672        yield* __yieldStar(this.step());
19673      } else if (this.type === "map-value-ind" && parent.type !== "flow-collection") {
19674        const prev = getPrevProps(parent);
19675        const start = getFirstKeyStartProps(prev);
19676        fixFlowSeqItems(fc);
19677        const sep = fc.end.splice(1, fc.end.length);
19678        sep.push(this.sourceToken);
19679        const map2 = {
19680          type: "block-map",
19681          offset: fc.offset,
19682          indent: fc.indent,
19683          items: [{ start, key: fc, sep }]
19684        };
19685        this.onKeyLine = true;
19686        this.stack[this.stack.length - 1] = map2;
19687      } else {
19688        yield* __yieldStar(this.lineEnd(fc));
19689      }
19690    }
19691  }
19692  flowScalar(type) {
19693    if (this.onNewLine) {
19694      let nl2 = this.source.indexOf("\n") + 1;
19695      while (nl2 !== 0) {
19696        this.onNewLine(this.offset + nl2);
19697        nl2 = this.source.indexOf("\n", nl2) + 1;
19698      }
19699    }
19700    return {
19701      type,
19702      offset: this.offset,
19703      indent: this.indent,
19704      source: this.source
19705    };
19706  }
19707  startBlockValue(parent) {
19708    switch (this.type) {
19709      case "alias":
19710      case "scalar":
19711      case "single-quoted-scalar":
19712      case "double-quoted-scalar":
19713        return this.flowScalar(this.type);
19714      case "block-scalar-header":
19715        return {
19716          type: "block-scalar",
19717          offset: this.offset,
19718          indent: this.indent,
19719          props: [this.sourceToken],
19720          source: ""
19721        };
19722      case "flow-map-start":
19723      case "flow-seq-start":
19724        return {
19725          type: "flow-collection",
19726          offset: this.offset,
19727          indent: this.indent,
19728          start: this.sourceToken,
19729          items: [],
19730          end: []
19731        };
19732      case "seq-item-ind":
19733        return {
19734          type: "block-seq",
19735          offset: this.offset,
19736          indent: this.indent,
19737          items: [{ start: [this.sourceToken] }]
19738        };
19739      case "explicit-key-ind": {
19740        this.onKeyLine = true;
19741        const prev = getPrevProps(parent);
19742        const start = getFirstKeyStartProps(prev);
19743        start.push(this.sourceToken);
19744        return {
19745          type: "block-map",
19746          offset: this.offset,
19747          indent: this.indent,
19748          items: [{ start, explicitKey: true }]
19749        };
19750      }
19751      case "map-value-ind": {
19752        this.onKeyLine = true;
19753        const prev = getPrevProps(parent);
19754        const start = getFirstKeyStartProps(prev);
19755        return {
19756          type: "block-map",
19757          offset: this.offset,
19758          indent: this.indent,
19759          items: [{ start, key: null, sep: [this.sourceToken] }]
19760        };
19761      }
19762    }
19763    return null;
19764  }
19765  atIndentedComment(start, indent) {
19766    if (this.type !== "comment")
19767      return false;
19768    if (this.indent <= indent)
19769      return false;
19770    return start.every((st2) => st2.type === "newline" || st2.type === "space");
19771  }
19772  *documentEnd(docEnd) {
19773    if (this.type !== "doc-mode") {
19774      if (docEnd.end)
19775        docEnd.end.push(this.sourceToken);
19776      else
19777        docEnd.end = [this.sourceToken];
19778      if (this.type === "newline")
19779        yield* __yieldStar(this.pop());
19780    }
19781  }
19782  *lineEnd(token) {
19783    switch (this.type) {
19784      case "comma":
19785      case "doc-start":
19786      case "doc-end":
19787      case "flow-seq-end":
19788      case "flow-map-end":
19789      case "map-value-ind":
19790        yield* __yieldStar(this.pop());
19791        yield* __yieldStar(this.step());
19792        break;
19793      case "newline":
19794        this.onKeyLine = false;
19795      // fallthrough
19796      case "space":
19797      case "comment":
19798      default:
19799        if (token.end)
19800          token.end.push(this.sourceToken);
19801        else
19802          token.end = [this.sourceToken];
19803        if (this.type === "newline")
19804          yield* __yieldStar(this.pop());
19805    }
19806  }
19807};
19808
19809// node_modules/yaml/browser/dist/public-api.js
19810function parseOptions(options) {
19811  const prettyErrors = options.prettyErrors !== false;
19812  const lineCounter = options.lineCounter || prettyErrors && new LineCounter() || null;
19813  return { lineCounter, prettyErrors };
19814}
19815function parseAllDocuments(source, options = {}) {
19816  const { lineCounter, prettyErrors } = parseOptions(options);
19817  const parser = new Parser(lineCounter == null ? void 0 : lineCounter.addNewLine);
19818  const composer = new Composer(options);
19819  const docs = Array.from(composer.compose(parser.parse(source)));
19820  if (prettyErrors && lineCounter)
19821    for (const doc of docs) {
19822      doc.errors.forEach(prettifyError(source, lineCounter));
19823      doc.warnings.forEach(prettifyError(source, lineCounter));
19824    }
19825  if (docs.length > 0)
19826    return docs;
19827  return Object.assign([], { empty: true }, composer.streamInfo());
19828}
19829function parseDocument(source, options = {}) {
19830  const { lineCounter, prettyErrors } = parseOptions(options);
19831  const parser = new Parser(lineCounter == null ? void 0 : lineCounter.addNewLine);
19832  const composer = new Composer(options);
19833  let doc = null;
19834  for (const _doc of composer.compose(parser.parse(source), true, source.length)) {
19835    if (!doc)
19836      doc = _doc;
19837    else if (doc.options.logLevel !== "silent") {
19838      doc.errors.push(new YAMLParseError(_doc.range.slice(0, 2), "MULTIPLE_DOCS", "Source contains multiple documents; please use YAML.parseAllDocuments()"));
19839      break;
19840    }
19841  }
19842  if (prettyErrors && lineCounter) {
19843    doc.errors.forEach(prettifyError(source, lineCounter));
19844    doc.warnings.forEach(prettifyError(source, lineCounter));
19845  }
19846  return doc;
19847}
19848function parse(src, reviver, options) {
19849  let _reviver = void 0;
19850  if (typeof reviver === "function") {
19851    _reviver = reviver;
19852  } else if (options === void 0 && reviver && typeof reviver === "object") {
19853    options = reviver;
19854  }
19855  const doc = parseDocument(src, options);
19856  if (!doc)
19857    return null;
19858  doc.warnings.forEach((warning) => warn(doc.options.logLevel, warning));
19859  if (doc.errors.length > 0) {
19860    if (doc.options.logLevel !== "silent")
19861      throw doc.errors[0];
19862    else
19863      doc.errors = [];
19864  }
19865  return doc.toJS(Object.assign({ reviver: _reviver }, options));
19866}
19867function stringify3(value, replacer, options) {
19868  var _a2;
19869  let _replacer = null;
19870  if (typeof replacer === "function" || Array.isArray(replacer)) {
19871    _replacer = replacer;
19872  } else if (options === void 0 && replacer) {
19873    options = replacer;
19874  }
19875  if (typeof options === "string")
19876    options = options.length;
19877  if (typeof options === "number") {
19878    const indent = Math.round(options);
19879    options = indent < 1 ? void 0 : indent > 8 ? { indent: 8 } : { indent };
19880  }
19881  if (value === void 0) {
19882    const { keepUndefined } = (_a2 = options != null ? options : replacer) != null ? _a2 : {};
19883    if (!keepUndefined)
19884      return void 0;
19885  }
19886  if (isDocument(value) && !_replacer)
19887    return value.toString(options);
19888  return new Document(value, _replacer, options).toString(options);
19889}
19890
19891// node_modules/yaml/browser/index.js
19892var browser_default = dist_exports;
19893
19894// node_modules/maml.js/build/index.js
19895var build_exports = {};
19896__export(build_exports, {
19897  parse: () => parse2,
19898  stringify: () => stringify4
19899});
19900
19901// node_modules/maml.js/build/parse.js
19902function parse2(source) {
19903  if (typeof source !== "string")
19904    throw TypeError("Source must be a string");
19905  let pos = 0, lineNumber = 1, ch, done = false;
19906  next();
19907  const value = parseValue();
19908  skipWhitespace();
19909  if (!done) {
19910    throw new SyntaxError(errorSnippet());
19911  }
19912  expectValue(value);
19913  return value;
19914  function next() {
19915    if (pos < source.length) {
19916      ch = source[pos];
19917      pos++;
19918    } else {
19919      ch = "";
19920      done = true;
19921    }
19922    if (ch === "\n") {
19923      lineNumber++;
19924    }
19925  }
19926  function lookahead2() {
19927    return source.substring(pos, pos + 2);
19928  }
19929  function parseValue() {
19930    var _a2, _b2, _c, _d, _e, _f, _g;
19931    skipWhitespace();
19932    return (_g = (_f = (_e = (_d = (_c = (_b2 = (_a2 = parseMultilineString()) != null ? _a2 : parseString()) != null ? _b2 : parseNumber()) != null ? _c : parseObject()) != null ? _d : parseArray()) != null ? _e : parseKeyword("true", true)) != null ? _f : parseKeyword("false", false)) != null ? _g : parseKeyword("null", null);
19933  }
19934  function parseString() {
19935    if (ch !== '"')
19936      return;
19937    let str = "";
19938    let escaped = false;
19939    while (true) {
19940      next();
19941      if (escaped) {
19942        if (ch === "u") {
19943          next();
19944          if (ch !== "{") {
19945            throw new SyntaxError(errorSnippet(errorMap.u + " " + JSON.stringify(ch) + ' (expected "{")'));
19946          }
19947          let hex = "";
19948          while (true) {
19949            next();
19950            if (ch === "}")
19951              break;
19952            if (!isHexDigit(ch)) {
19953              throw new SyntaxError(errorSnippet(errorMap.u + " " + JSON.stringify(ch)));
19954            }
19955            hex += ch;
19956            if (hex.length > 6) {
19957              throw new SyntaxError(errorSnippet(errorMap.u + " (too many hex digits)"));
19958            }
19959          }
19960          if (hex.length === 0) {
19961            throw new SyntaxError(errorSnippet(errorMap.u));
19962          }
19963          const codePoint = parseInt(hex, 16);
19964          if (codePoint > 1114111) {
19965            throw new SyntaxError(errorSnippet(errorMap.u + " (out of range)"));
19966          }
19967          str += String.fromCodePoint(codePoint);
19968        } else {
19969          const escapedChar = escapeMap[ch];
19970          if (!escapedChar) {
19971            throw new SyntaxError(errorSnippet(errorMap.u + " " + JSON.stringify(ch)));
19972          }
19973          str += escapedChar;
19974        }
19975        escaped = false;
19976      } else if (ch === "\\") {
19977        escaped = true;
19978      } else if (ch === '"') {
19979        break;
19980      } else if (ch === "\n") {
19981        throw new SyntaxError(errorSnippet(`Use """ for multiline strings or escape newlines with "\\n"`));
19982      } else if (ch < "") {
19983        throw new SyntaxError(errorSnippet(`Unescaped control character ${JSON.stringify(ch)}`));
19984      } else {
19985        str += ch;
19986      }
19987    }
19988    next();
19989    return str;
19990  }
19991  function parseMultilineString() {
19992    if (ch !== '"' || lookahead2() !== '""')
19993      return;
19994    next();
19995    next();
19996    next();
19997    let hasLeadingNewline = false;
19998    if (ch === "\n") {
19999      hasLeadingNewline = true;
20000      next();
20001    }
20002    let str = "";
20003    while (!done) {
20004      if (ch === '"' && lookahead2() === '""') {
20005        next();
20006        next();
20007        next();
20008        if (str === "" && !hasLeadingNewline) {
20009          throw new SyntaxError(errorSnippet("Multiline strings cannot be empty"));
20010        }
20011        return str;
20012      }
20013      str += ch;
20014      next();
20015    }
20016    throw new SyntaxError(errorSnippet());
20017  }
20018  function parseNumber() {
20019    if (!isDigit(ch) && ch !== "-")
20020      return;
20021    let numStr = "";
20022    let float3 = false;
20023    if (ch === "-") {
20024      numStr += ch;
20025      next();
20026      if (!isDigit(ch)) {
20027        throw new SyntaxError(errorSnippet());
20028      }
20029    }
20030    if (ch === "0") {
20031      numStr += ch;
20032      next();
20033    } else {
20034      while (isDigit(ch)) {
20035        numStr += ch;
20036        next();
20037      }
20038    }
20039    if (ch === ".") {
20040      float3 = true;
20041      numStr += ch;
20042      next();
20043      if (!isDigit(ch)) {
20044        throw new SyntaxError(errorSnippet());
20045      }
20046      while (isDigit(ch)) {
20047        numStr += ch;
20048        next();
20049      }
20050    }
20051    if (ch === "e" || ch === "E") {
20052      float3 = true;
20053      numStr += ch;
20054      next();
20055      if (ch === "+" || ch === "-") {
20056        numStr += ch;
20057        next();
20058      }
20059      if (!isDigit(ch)) {
20060        throw new SyntaxError(errorSnippet());
20061      }
20062      while (isDigit(ch)) {
20063        numStr += ch;
20064        next();
20065      }
20066    }
20067    return float3 ? parseFloat(numStr) : toSafeNumber(numStr);
20068  }
20069  function parseObject() {
20070    if (ch !== "{")
20071      return;
20072    next();
20073    skipWhitespace();
20074    const obj = {};
20075    if (ch === "}") {
20076      next();
20077      return obj;
20078    }
20079    while (true) {
20080      const keyPos = pos;
20081      let key;
20082      if (ch === '"') {
20083        key = parseString();
20084      } else {
20085        key = parseKey();
20086      }
20087      if (Object.prototype.hasOwnProperty.call(obj, key)) {
20088        pos = keyPos;
20089        throw new SyntaxError(errorSnippet(`Duplicate key ${JSON.stringify(key)}`));
20090      }
20091      skipWhitespace();
20092      if (ch !== ":") {
20093        throw new SyntaxError(errorSnippet());
20094      }
20095      next();
20096      const value2 = parseValue();
20097      expectValue(value2);
20098      obj[key] = value2;
20099      const newlineAfterValue = skipWhitespace();
20100      if (ch === "}") {
20101        next();
20102        return obj;
20103      } else if (ch === ",") {
20104        next();
20105        skipWhitespace();
20106        if (ch === "}") {
20107          next();
20108          return obj;
20109        }
20110      } else if (newlineAfterValue) {
20111        continue;
20112      } else {
20113        throw new SyntaxError(errorSnippet("Expected comma or newline between key-value pairs"));
20114      }
20115    }
20116  }
20117  function parseKey() {
20118    let identifier = "";
20119    while (isKeyChar(ch)) {
20120      identifier += ch;
20121      next();
20122    }
20123    if (identifier === "") {
20124      throw new SyntaxError(errorSnippet());
20125    }
20126    return identifier;
20127  }
20128  function parseArray() {
20129    if (ch !== "[")
20130      return;
20131    next();
20132    skipWhitespace();
20133    const array = [];
20134    if (ch === "]") {
20135      next();
20136      return array;
20137    }
20138    while (true) {
20139      const value2 = parseValue();
20140      expectValue(value2);
20141      array.push(value2);
20142      const newLineAfterValue = skipWhitespace();
20143      if (ch === "]") {
20144        next();
20145        return array;
20146      } else if (ch === ",") {
20147        next();
20148        skipWhitespace();
20149        if (ch === "]") {
20150          next();
20151          return array;
20152        }
20153      } else if (newLineAfterValue) {
20154        continue;
20155      } else {
20156        throw new SyntaxError(errorSnippet("Expected comma or newline between values"));
20157      }
20158    }
20159  }
20160  function parseKeyword(name, value2) {
20161    if (ch !== name[0])
20162      return;
20163    for (let i = 1; i < name.length; i++) {
20164      next();
20165      if (ch !== name[i]) {
20166        throw new SyntaxError(errorSnippet());
20167      }
20168    }
20169    next();
20170    if (isWhitespace(ch) || ch === "," || ch === "}" || ch === "]" || ch === void 0) {
20171      return value2;
20172    }
20173    throw new SyntaxError(errorSnippet());
20174  }
20175  function skipWhitespace() {
20176    let hasNewline = false;
20177    while (isWhitespace(ch)) {
20178      hasNewline || (hasNewline = ch === "\n");
20179      next();
20180    }
20181    const hasNewlineAfterComment = skipComment();
20182    return hasNewline || hasNewlineAfterComment;
20183  }
20184  function skipComment() {
20185    if (ch === "#") {
20186      while (!done && ch !== "\n") {
20187        next();
20188      }
20189      return skipWhitespace();
20190    }
20191    return false;
20192  }
20193  function isWhitespace(ch2) {
20194    return ch2 === " " || ch2 === "\n" || ch2 === "	" || ch2 === "\r";
20195  }
20196  function isHexDigit(ch2) {
20197    return ch2 >= "0" && ch2 <= "9" || ch2 >= "A" && ch2 <= "F";
20198  }
20199  function isDigit(ch2) {
20200    return ch2 >= "0" && ch2 <= "9";
20201  }
20202  function isKeyChar(ch2) {
20203    return ch2 >= "A" && ch2 <= "Z" || ch2 >= "a" && ch2 <= "z" || ch2 >= "0" && ch2 <= "9" || ch2 === "_" || ch2 === "-";
20204  }
20205  function toSafeNumber(str) {
20206    if (str == "-0")
20207      return -0;
20208    const num = Number(str);
20209    return num >= Number.MIN_SAFE_INTEGER && num <= Number.MAX_SAFE_INTEGER ? num : BigInt(str);
20210  }
20211  function expectValue(value2) {
20212    if (value2 === void 0) {
20213      throw new SyntaxError(errorSnippet());
20214    }
20215  }
20216  function errorSnippet(message = `Unexpected character ${JSON.stringify(ch)}`) {
20217    if (!ch)
20218      message = "Unexpected end of input";
20219    const lines = source.substring(pos - 40, pos).split("\n");
20220    let lastLine = lines.at(-1) || "";
20221    let postfix = source.substring(pos, pos + 40).split("\n", 1).at(0) || "";
20222    if (lastLine === "") {
20223      lastLine = lines.at(-2) || "";
20224      lastLine += " ";
20225      lineNumber--;
20226      postfix = "";
20227    }
20228    const snippet = `    ${lastLine}${postfix}
20229`;
20230    const pointer = `    ${".".repeat(Math.max(0, lastLine.length - 1))}^
20231`;
20232    return `${message} on line ${lineNumber}.
20233
20234${snippet}${pointer}`;
20235  }
20236}
20237var escapeMap = {
20238  '"': '"',
20239  "\\": "\\",
20240  n: "\n",
20241  r: "\r",
20242  t: "	"
20243};
20244var errorMap = {
20245  u: "Invalid escape sequence"
20246};
20247
20248// node_modules/maml.js/build/stringify.js
20249function stringify4(value) {
20250  return doStringify(value, 0);
20251}
20252function doStringify(value, level) {
20253  const kind = value === null ? "null" : Array.isArray(value) ? "array" : typeof value;
20254  switch (kind) {
20255    case "string":
20256      return JSON.stringify(value);
20257    case "boolean":
20258    case "bigint":
20259    case "number":
20260      return `${value}`;
20261    case "null":
20262    case "undefined":
20263      return "null";
20264    case "array": {
20265      const len = value.length;
20266      if (len === 0)
20267        return "[]";
20268      const childIndent = getIndent(level + 1);
20269      const parentIndent = getIndent(level);
20270      let out = "[\n";
20271      for (let i = 0; i < len; i++) {
20272        if (i > 0)
20273          out += "\n";
20274        out += childIndent + doStringify(value[i], level + 1);
20275      }
20276      return out + "\n" + parentIndent + "]";
20277    }
20278    case "object": {
20279      const keys = Object.keys(value);
20280      const len = keys.length;
20281      if (len === 0)
20282        return "{}";
20283      const childIndent = getIndent(level + 1);
20284      const parentIndent = getIndent(level);
20285      let out = "{\n";
20286      for (let i = 0; i < len; i++) {
20287        if (i > 0)
20288          out += "\n";
20289        const key = keys[i];
20290        out += childIndent + doKeyStringify(key) + ": " + doStringify(value[key], level + 1);
20291      }
20292      return out + "\n" + parentIndent + "}";
20293    }
20294    default:
20295      throw new Error(`Unsupported value type: ${kind}`);
20296  }
20297}
20298var KEY_RE = /^[A-Za-z0-9_-]+$/;
20299function doKeyStringify(key) {
20300  return KEY_RE.test(key) ? key : JSON.stringify(key);
20301}
20302function getIndent(level) {
20303  return " ".repeat(2 * level);
20304}
20305
20306// src/vendor-extra.ts
20307var _fs = __toESM(require_lib(), 1);
20308var import_create_require = __toESM(require_create_require(), 1);
20309
20310// node_modules/node-fetch-native/dist/index.mjs
20311init_node();
20312init_node();
20313init_node_fetch_native_DfbY2q_x();
20314var _a, _b;
20315var o2 = !!((_b = (_a = globalThis.process) == null ? void 0 : _a.env) == null ? void 0 : _b.FORCE_NODE_FETCH);
20316var r = !o2 && globalThis.fetch || Mi;
20317var p = !o2 && globalThis.Blob || ut;
20318var F3 = !o2 && globalThis.File || qn;
20319var h = !o2 && globalThis.FormData || br;
20320var n3 = !o2 && globalThis.Headers || ye;
20321var c = !o2 && globalThis.Request || dt;
20322var R2 = !o2 && globalThis.Response || le;
20323var T = !o2 && globalThis.AbortController || Mn;
20324
20325// node_modules/depseek/target/esm/index.mjs
20326var importRequireRe = /((\.{3}|\s|[!%&(*+,/:;<=>?[^{|}~-]|^)(require\s?\(\s?|import\s?\(?\s?)|\sfrom)\s?$/;
20327var isDep = (v2, re) => !!v2 && re.test(v2);
20328var isSpace = (v2) => v2 === " " || v2 === "\n" || v2 === "	";
20329var isQ = (v2) => `"'\``.includes(v2);
20330var normalizeOpts = (opts) => __spreadValues({
20331  bufferSize: 1e3,
20332  comments: false,
20333  re: importRequireRe,
20334  offset: 19
20335}, opts);
20336var depseekSync = (input, opts) => extract(readify(input.toString()), opts);
20337var readify = (input) => {
20338  const chunks = [null, input];
20339  return { read: () => chunks.pop() };
20340};
20341var extract = (readable, _opts) => {
20342  const { re, comments, bufferSize, offset } = normalizeOpts(_opts);
20343  const refs = [];
20344  const pushRef = (type, value, index) => refs.push({ type, value, index });
20345  let i = 0;
20346  let prev = "";
20347  let chunk;
20348  let c2 = null;
20349  let q = null;
20350  let token = "";
20351  let strLiteral = "";
20352  let commentBlock = "";
20353  let commentValue = "";
20354  while (null !== (chunk = readable.read(bufferSize))) {
20355    const len = chunk.length;
20356    let j = 0;
20357    while (j < len) {
20358      const char = chunk[j];
20359      if (c2 === q) {
20360        if (isSpace(char)) {
20361          if (!isSpace(prev)) token += char;
20362        } else if (prev === "/" && (char === "/" || char === "*")) c2 = char;
20363        else if (isQ(char)) q = char;
20364        else token += char;
20365      } else if (c2 === null) {
20366        if (isSpace(char) || isQ(char)) {
20367          if (strLiteral && isDep(token.slice(-offset), re)) pushRef("dep", strLiteral, i - strLiteral.length);
20368          strLiteral = "";
20369          token = "";
20370          q = null;
20371        } else strLiteral += char;
20372      } else if (q === null) {
20373        if (c2 === "/" && char === "\n" || c2 === "*" && prev === "*" && char === "/") {
20374          commentValue = c2 === "*" ? commentBlock.slice(0, -1) : commentBlock;
20375          if (commentValue && comments) pushRef("comment", commentValue, i - commentValue.length);
20376          commentBlock = "";
20377          token = token.slice(0, -1);
20378          c2 = null;
20379        } else if (comments) commentBlock += char;
20380      }
20381      prev = char;
20382      i++;
20383      j++;
20384    }
20385  }
20386  return refs;
20387};
20388
20389// src/vendor-extra.ts
20390var import_minimist = __toESM(require_minimist(), 1);
20391
20392// node_modules/envapi/target/esm/index.mjs
20393var import_node_fs5 = __toESM(require("fs"), 1);
20394var import_node_path6 = __toESM(require("path"), 1);
20395var import_node_util4 = require("util");
20396var DOTENV = ".env";
20397var Q1 = '"';
20398var Q2 = "'";
20399var Q3 = "`";
20400var KR = /^[a-zA-Z_]\w*$/;
20401var SR = /\s/;
20402var decoder = new import_node_util4.TextDecoder();
20403var parse3 = (content) => {
20404  const e = {};
20405  let k2 = "";
20406  let b = "";
20407  let q = "";
20408  let i = 0;
20409  const cap = () => {
20410    k2 = k2.trim();
20411    if (k2) {
20412      if (!KR.test(k2)) throw new Error(`Invalid identifier: ${k2}`);
20413      e[k2] = b.trim();
20414      b = k2 = "";
20415    }
20416  };
20417  for (const c2 of typeof content === "string" ? content : decoder.decode(content)) {
20418    if (i) {
20419      if (c2 === "\n") i = 0;
20420      continue;
20421    }
20422    if (!q) {
20423      if (c2 === "#") {
20424        i = 1;
20425        continue;
20426      }
20427      if (c2 === "\n") {
20428        cap();
20429        continue;
20430      }
20431      if (SR.test(c2)) {
20432        if (!k2 && b === "export") b = "";
20433        if (!b) continue;
20434      }
20435      if (c2 === "=") {
20436        if (!k2) {
20437          k2 = b;
20438          b = "";
20439          continue;
20440        }
20441      }
20442    }
20443    if (c2 === Q1 || c2 === Q2 || c2 === Q3) {
20444      if (!q && !b) {
20445        q = c2;
20446        continue;
20447      }
20448      if (q === c2) {
20449        q = "";
20450        b && cap();
20451        continue;
20452      }
20453    }
20454    b += c2;
20455  }
20456  cap();
20457  return e;
20458};
20459var formatValue = (v2) => {
20460  const q1 = v2.includes(Q1);
20461  const q2 = v2.includes(Q2);
20462  const q3 = v2.includes(Q3);
20463  const s = SR.test(v2);
20464  if (!q1 && !q2 && !q3 && !s) return v2;
20465  if (!q1) return `${Q1}${v2}${Q1}`;
20466  if (!q2) return `${Q2}${v2}${Q2}`;
20467  if (parse3(`V=${Q3}${v2}${Q3}`).V !== v2) throw new Error(`Invalid value: ${v2}`);
20468  return `${Q3}${v2}${Q3}`;
20469};
20470var stringify5 = (env) => Object.entries(env).map(([k2, v2]) => `${k2}=${formatValue(v2 || "")}`).join("\n");
20471var _load = (read, ...files) => files.reverse().reduce((m2, f2) => Object.assign(m2, parse3(read(import_node_path6.default.resolve(f2)))), {});
20472var load = (...files) => _load((file) => import_node_fs5.default.readFileSync(file, "utf8"), ...files);
20473var loadSafe = (...files) => _load(
20474  (file) => import_node_fs5.default.existsSync(file) ? import_node_fs5.default.readFileSync(file, "utf8") : "",
20475  ...files
20476);
20477var populate = (env, extra) => Object.assign(env, extra);
20478var config = (def = DOTENV, ...files) => populate(process.env, loadSafe(def, ...files));
20479var index_default = { parse: parse3, stringify: stringify5, load, loadSafe, config };
20480
20481// src/vendor-extra.ts
20482var import_internals = require("./internals.cjs");
20483var { wrap } = import_internals.bus;
20484var globalVar = "Deno" in globalThis ? globalThis : global;
20485globalVar.AbortController = globalVar.AbortController || T;
20486var createRequire = import_create_require.default;
20487var globbyModule = {
20488  convertPathToPattern,
20489  globby,
20490  sync: globbySync,
20491  globbySync,
20492  globbyStream,
20493  generateGlobTasksSync,
20494  generateGlobTasks,
20495  isGitIgnoredSync,
20496  isGitIgnored,
20497  isDynamicPattern
20498};
20499var _glob = Object.assign(function globby2(patterns, options) {
20500  return globbyModule.globby(patterns, options);
20501}, globbyModule);
20502var _YAML = browser_exports;
20503var depseek = wrap("depseek", depseekSync);
20504var dotenv = wrap("dotenv", index_default);
20505var fs5 = wrap("fs", _fs);
20506var YAML = wrap("YAML", _YAML);
20507var MAML = wrap("MAML", build_exports);
20508var glob = wrap("glob", _glob);
20509var nodeFetch = wrap("nodeFetch", r);
20510var minimist = wrap("minimist", import_minimist.default);
20511/* c8 ignore next 100 */
20512// Annotate the CommonJS export names for ESM import in node:
205130 && (module.exports = {
20514  MAML,
20515  YAML,
20516  createRequire,
20517  depseek,
20518  dotenv,
20519  fs,
20520  glob,
20521  minimist,
20522  nodeFetch
20523});