'use strict';

var chunkFW7TXF3C_cjs = require('./chunk-FW7TXF3C.cjs');

// ../../node_modules/.pnpm/is-obj@2.0.0/node_modules/is-obj/index.js
var require_is_obj = chunkFW7TXF3C_cjs.__commonJS({
  "../../node_modules/.pnpm/is-obj@2.0.0/node_modules/is-obj/index.js"(exports$1, module) {
    chunkFW7TXF3C_cjs.init_cjs_shims();
    module.exports = (value) => {
      const type = typeof value;
      return value !== null && (type === "object" || type === "function");
    };
  }
});

// ../../node_modules/.pnpm/dot-prop@5.3.0/node_modules/dot-prop/index.js
var require_dot_prop = chunkFW7TXF3C_cjs.__commonJS({
  "../../node_modules/.pnpm/dot-prop@5.3.0/node_modules/dot-prop/index.js"(exports$1, module) {
    chunkFW7TXF3C_cjs.init_cjs_shims();
    var isObj = require_is_obj();
    var disallowedKeys = [
      "__proto__",
      "prototype",
      "constructor"
    ];
    var isValidPath = /* @__PURE__ */ chunkFW7TXF3C_cjs.__name((pathSegments) => !pathSegments.some((segment) => disallowedKeys.includes(segment)), "isValidPath");
    function getPathSegments(path) {
      const pathArray = path.split(".");
      const parts = [];
      for (let i = 0; i < pathArray.length; i++) {
        let p = pathArray[i];
        while (p[p.length - 1] === "\\" && pathArray[i + 1] !== void 0) {
          p = p.slice(0, -1) + ".";
          p += pathArray[++i];
        }
        parts.push(p);
      }
      if (!isValidPath(parts)) {
        return [];
      }
      return parts;
    }
    chunkFW7TXF3C_cjs.__name(getPathSegments, "getPathSegments");
    module.exports = {
      get(object, path, value) {
        if (!isObj(object) || typeof path !== "string") {
          return value === void 0 ? object : value;
        }
        const pathArray = getPathSegments(path);
        if (pathArray.length === 0) {
          return;
        }
        for (let i = 0; i < pathArray.length; i++) {
          if (!Object.prototype.propertyIsEnumerable.call(object, pathArray[i])) {
            return value;
          }
          object = object[pathArray[i]];
          if (object === void 0 || object === null) {
            if (i !== pathArray.length - 1) {
              return value;
            }
            break;
          }
        }
        return object;
      },
      set(object, path, value) {
        if (!isObj(object) || typeof path !== "string") {
          return object;
        }
        const root = object;
        const pathArray = getPathSegments(path);
        for (let i = 0; i < pathArray.length; i++) {
          const p = pathArray[i];
          if (!isObj(object[p])) {
            object[p] = {};
          }
          if (i === pathArray.length - 1) {
            object[p] = value;
          }
          object = object[p];
        }
        return root;
      },
      delete(object, path) {
        if (!isObj(object) || typeof path !== "string") {
          return false;
        }
        const pathArray = getPathSegments(path);
        for (let i = 0; i < pathArray.length; i++) {
          const p = pathArray[i];
          if (i === pathArray.length - 1) {
            delete object[p];
            return true;
          }
          object = object[p];
          if (!isObj(object)) {
            return false;
          }
        }
      },
      has(object, path) {
        if (!isObj(object) || typeof path !== "string") {
          return false;
        }
        const pathArray = getPathSegments(path);
        if (pathArray.length === 0) {
          return false;
        }
        for (let i = 0; i < pathArray.length; i++) {
          if (isObj(object)) {
            if (!(pathArray[i] in object)) {
              return false;
            }
            object = object[pathArray[i]];
          } else {
            return false;
          }
        }
        return true;
      }
    };
  }
});

// ../../node_modules/.pnpm/to-fast-properties@3.0.1/node_modules/to-fast-properties/index.js
var require_to_fast_properties = chunkFW7TXF3C_cjs.__commonJS({
  "../../node_modules/.pnpm/to-fast-properties@3.0.1/node_modules/to-fast-properties/index.js"(exports$1, module) {
    chunkFW7TXF3C_cjs.init_cjs_shims();
    var fastProto = null;
    function FastObject(o) {
      if (fastProto !== null && typeof fastProto.property) {
        const result = fastProto;
        fastProto = FastObject.prototype = null;
        return result;
      }
      fastProto = FastObject.prototype = o == null ? /* @__PURE__ */ Object.create(null) : o;
      return new FastObject();
    }
    chunkFW7TXF3C_cjs.__name(FastObject, "FastObject");
    var inlineCacheCutoff = 10;
    for (let i = 0; i <= inlineCacheCutoff; i++) {
      FastObject();
    }
    module.exports = /* @__PURE__ */ chunkFW7TXF3C_cjs.__name(function toFastproperties(o) {
      return FastObject(o);
    }, "toFastproperties");
  }
});

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/iterators.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var __\u03A9ArrayLike = [
  "T",
  "length",
  "ArrayLike",
  `b!P'4"9'e"!LMw#y`
];
var __\u03A9IterableIterator = [
  "T",
  "TReturn",
  "TNext",
  () => __\u03A9Iterator,
  0,
  () => Symbol.iterator,
  "IterableIterator",
  `b!"c""c#Pe"!e""e"#o$$Pe#!e#"e##o%$1&Mw'y`
];
var __\u03A9Iterator = [
  "T",
  "TReturn",
  "TNext",
  "param0",
  () => __\u03A9IteratorResult,
  "next",
  "value",
  () => __\u03A9IteratorResult,
  "return",
  "e",
  () => __\u03A9IteratorResult,
  "throw",
  "Iterator",
  `b!"c""c#PPPPGPe%#GJ@2$e#!e#"o%#1&Pe#"2'8e#!e#"o(#1)P"2*8e#!e#"o+#1,Mw-y`
];
var __\u03A9IteratorResult = [
  "T",
  "TReturn",
  () => __\u03A9IteratorYieldResult,
  () => __\u03A9IteratorReturnResult,
  "IteratorResult",
  'b!"c"Pe"!o#"e""o$"Jw%y'
];
var __\u03A9IteratorYieldResult = [
  "TYield",
  false,
  "done",
  "value",
  "IteratorYieldResult",
  'b!P."4#8e"!4$Mw%y'
];
var __\u03A9IteratorReturnResult = [
  "TReturn",
  true,
  "done",
  "value",
  "IteratorReturnResult",
  'b!P."4#e"!4$Mw%y'
];
eachKey.__type = [
  () => __\u03A9ArrayLike,
  "object",
  () => __\u03A9IterableIterator,
  "eachKey",
  `P"o!"2"'o#"/$`
];
eachKey.__type = [
  "object",
  () => __\u03A9IterableIterator,
  "eachKey",
  'P"2!&o""/#'
];
function* eachKey(object) {
  if (Array.isArray(object)) {
    for (let i = 0; i < object.length; i++) {
      yield i;
    }
  } else {
    for (const i in object) {
      if (object.hasOwnProperty(i)) {
        yield i;
      }
    }
  }
}
chunkFW7TXF3C_cjs.__name(eachKey, "eachKey");
eachKey.__type = [
  () => __\u03A9ArrayLike,
  "object",
  () => __\u03A9IterableIterator,
  "eachKey",
  `PP""o!"J2"P&'Jo#"/$`
];
function* each(object) {
  if (Array.isArray(object)) {
    for (let i = 0; i < object.length; i++) {
      yield object[i];
    }
  } else {
    for (const i in object) {
      if (object.hasOwnProperty(i)) {
        yield object[i];
      }
    }
  }
}
chunkFW7TXF3C_cjs.__name(each, "each");
each.__type = [
  () => __\u03A9ArrayLike,
  "object",
  () => __\u03A9IterableIterator,
  "each",
  'PPP&"LM"o!"J2""o#"/$'
];
eachPair.__type = [
  () => __\u03A9ArrayLike,
  "object",
  () => __\u03A9IterableIterator,
  "eachPair",
  `P"o!"2"P'"Go#"/$`
];
eachPair.__type = [
  "object",
  () => __\u03A9IterableIterator,
  "eachPair",
  'PP&"LM2!P&"Go""/#'
];
function* eachPair(object) {
  if (Array.isArray(object)) {
    for (let i = 0; i < object.length; i++) {
      yield [
        i,
        object[i]
      ];
    }
  } else {
    for (const i in object) {
      if (object.hasOwnProperty(i)) {
        yield [
          i,
          object[i]
        ];
      }
    }
  }
}
chunkFW7TXF3C_cjs.__name(eachPair, "eachPair");
eachPair.__type = [
  () => __\u03A9ArrayLike,
  "object",
  () => __\u03A9IterableIterator,
  "eachPair",
  `PPP&"LM"o!"J2"PP&"GP'"GJo#"/$`
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/core.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var import_dot_prop = chunkFW7TXF3C_cjs.__toESM(require_dot_prop(), 1);
var __\u03A9Object = [
  () => Function,
  "constructor",
  "toString",
  "toLocaleString",
  0,
  "valueOf",
  () => __\u03A9PropertyKey,
  "v",
  "hasOwnProperty",
  0,
  "isPrototypeOf",
  () => __\u03A9PropertyKey,
  "propertyIsEnumerable",
  "Object",
  `PPu!4"P&1#P&1$Pn%1&Pn'2()1)Pn*2()1+Pn,2()1-Mw.y`
];
var __\u03A9Error = [
  "name",
  "message",
  "stack",
  "Error",
  'P&4!&4"&4#8Mw$y'
];
var __\u03A9IterableIterator2 = [
  "T",
  "TReturn",
  "TNext",
  () => __\u03A9Iterator2,
  0,
  () => Symbol.iterator,
  "IterableIterator",
  `b!"c""c#Pe"!e""e"#o$$Pe#!e#"e##o%$1&Mw'y`
];
var __\u03A9PropertyKey = [
  "PropertyKey",
  "P&'+Jw!y"
];
var __\u03A9Iterator2 = [
  "T",
  "TReturn",
  "TNext",
  "param0",
  () => __\u03A9IteratorResult2,
  "next",
  "value",
  () => __\u03A9IteratorResult2,
  "return",
  "e",
  () => __\u03A9IteratorResult2,
  "throw",
  "Iterator",
  `b!"c""c#PPPPGPe%#GJ@2$e#!e#"o%#1&Pe#"2'8e#!e#"o(#1)P"2*8e#!e#"o+#1,Mw-y`
];
var __\u03A9IteratorResult2 = [
  "T",
  "TReturn",
  () => __\u03A9IteratorYieldResult2,
  () => __\u03A9IteratorReturnResult2,
  "IteratorResult",
  'b!"c"Pe"!o#"e""o$"Jw%y'
];
var __\u03A9IteratorYieldResult2 = [
  "TYield",
  false,
  "done",
  "value",
  "IteratorYieldResult",
  'b!P."4#8e"!4$Mw%y'
];
var __\u03A9IteratorReturnResult2 = [
  "TReturn",
  true,
  "done",
  "value",
  "IteratorReturnResult",
  'b!P."4#e"!4$Mw%y'
];
function __assignType(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType, "__assignType");
var CustomError = class extends Error {
  static {
    chunkFW7TXF3C_cjs.__name(this, "CustomError");
  }
  constructor(...args) {
    super(...args);
    this.name = this.constructor.name;
  }
};
CustomError.__type = [
  () => Error,
  "name",
  "args",
  "constructor",
  "CustomError",
  'P7!&3"P"@2#"0$5w%'
];
var __\u03A9CustomError = [
  "cause",
  "CustomError",
  'P#4!8Mw"y'
];
var __\u03A9ClassType = [
  "T",
  "args",
  "new",
  "ClassType",
  '"c!PP"@2"e#!1#Mw$y'
];
var __\u03A9AbstractClassType = [
  "T",
  "args",
  "new",
  "AbstractClassType",
  '"c!P"@2"e"!/#w$y'
];
var __\u03A9ExtractClassType = [
  "T",
  () => __\u03A9AbstractClassType,
  "ExtractClassType",
  `l:e"!R!RPde#!h!!o""qk#'QRb!Pde"!p)w#y`
];
function getClassName(classTypeOrInstance) {
  if (!classTypeOrInstance) return "undefined";
  const proto = classTypeOrInstance["prototype"] ? classTypeOrInstance["prototype"] : classTypeOrInstance;
  return proto.constructor.name || "anonymous class";
}
chunkFW7TXF3C_cjs.__name(getClassName, "getClassName");
getClassName.__type = [
  () => __\u03A9ClassType,
  () => __\u03A9Object,
  "classTypeOrInstance",
  "getClassName",
  'PP"o!"n"J2#&/$'
];
function getClassPropertyName(classType, propertyName) {
  const name = getClassName(classType);
  return `${name}.${propertyName}`;
}
chunkFW7TXF3C_cjs.__name(getClassPropertyName, "getClassPropertyName");
getClassPropertyName.__type = [
  () => __\u03A9ClassType,
  () => __\u03A9Object,
  "classType",
  "propertyName",
  "getClassPropertyName",
  'PP"o!"n"J2#&2$&/%'
];
function applyDefaults(classType, target) {
  const classInstance = new classType();
  for (const [i, v] of eachPair(target)) {
    classInstance[i] = v;
  }
  return classInstance;
}
chunkFW7TXF3C_cjs.__name(applyDefaults, "applyDefaults");
applyDefaults.__type = [
  () => __\u03A9ClassType,
  "classType",
  "target",
  "applyDefaults",
  'P"o!"2"P&"LM2#"/$'
];
function identifyType(obj) {
  return (({}.toString.call(obj).match(/\s([a-zA-Z]+)/) || [])[1] || "").toLowerCase();
}
chunkFW7TXF3C_cjs.__name(identifyType, "identifyType");
identifyType.__type = [
  "obj",
  "identifyType",
  'P"2!"/"'
];
function isPlainObject(obj) {
  return Boolean(obj && typeof obj === "object" && obj.constructor instanceof obj.constructor);
}
chunkFW7TXF3C_cjs.__name(isPlainObject, "isPlainObject");
isPlainObject.__type = [
  "obj",
  "isPlainObject",
  'P"2!!/"'
];
function getClassTypeFromInstance(target) {
  if (!isClassInstance(target)) {
    throw new Error(`Value is not a class instance. Got ${stringifyValueWithType(target)}`);
  }
  return target["constructor"];
}
chunkFW7TXF3C_cjs.__name(getClassTypeFromInstance, "getClassTypeFromInstance");
getClassTypeFromInstance.__type = [
  "target",
  () => __\u03A9ClassType,
  "getClassTypeFromInstance",
  'P"2!"o""/#'
];
function isClassInstance(target) {
  return target !== void 0 && target !== null && target["constructor"] && Object.getPrototypeOf(target) === target["constructor"].prototype && !isPlainObject(target) && isObject(target);
}
chunkFW7TXF3C_cjs.__name(isClassInstance, "isClassInstance");
isClassInstance.__type = [
  "target",
  "isClassInstance",
  'P"2!)/"'
];
function stringifyValueWithType(value, depth = 0) {
  if ("string" === typeof value) return `string(${value})`;
  if ("number" === typeof value) return `number(${value})`;
  if ("boolean" === typeof value) return `boolean(${value})`;
  if ("bigint" === typeof value) return `bigint(${value})`;
  if (isPlainObject(value)) return `object ${depth < 2 ? prettyPrintObject(value, depth) : ""}`;
  if (isArray(value)) return `Array`;
  if (isClass(value)) return `${getClassName(value)}`;
  if (isObject(value)) return `${getClassName(getClassTypeFromInstance(value))} ${depth < 2 ? prettyPrintObject(value, depth) : ""}`;
  if ("function" === typeof value) return `function ${value.name}`;
  if (null === value) return `null`;
  return "undefined";
}
chunkFW7TXF3C_cjs.__name(stringifyValueWithType, "stringifyValueWithType");
stringifyValueWithType.__type = [
  "value",
  "depth",
  () => 0,
  "stringifyValueWithType",
  `P"2!'2">#&/$`
];
function changeClass(value, newClass) {
  return Object.assign(Object.create(newClass.prototype), value);
}
chunkFW7TXF3C_cjs.__name(changeClass, "changeClass");
changeClass.__type = [
  "value",
  () => __\u03A9ClassType,
  "newClass",
  "changeClass",
  'P%2!"o""2#"/$'
];
function prettyPrintObject(object, depth = 0) {
  const res = [];
  for (const i in object) {
    res.push(i + ": " + stringifyValueWithType(object[i], depth + 1));
  }
  return "{" + res.join(",") + "}";
}
chunkFW7TXF3C_cjs.__name(prettyPrintObject, "prettyPrintObject");
prettyPrintObject.__type = [
  "object",
  "depth",
  () => 0,
  "prettyPrintObject",
  `P%2!'2">#&/$`
];
function isFunction(obj) {
  if ("function" === typeof obj) {
    return !obj.toString().startsWith("class ") && !obj.toString().startsWith("class{");
  }
  return false;
}
chunkFW7TXF3C_cjs.__name(isFunction, "isFunction");
isFunction.__type = [
  "obj",
  "isFunction",
  'P"2!!/"'
];
var AsyncFunction = (async () => {
}).constructor;
function isAsyncFunction(obj) {
  return obj instanceof AsyncFunction;
}
chunkFW7TXF3C_cjs.__name(isAsyncFunction, "isAsyncFunction");
isAsyncFunction.__type = [
  "obj",
  "isAsyncFunction",
  'P"2!!/"'
];
function isPromise(obj) {
  return obj !== null && typeof obj === "object" && typeof obj.then === "function" && typeof obj.catch === "function" && typeof obj.finally === "function";
}
chunkFW7TXF3C_cjs.__name(isPromise, "isPromise");
isPromise.__type = [
  "obj",
  "isPromise",
  'PP""`J2!!/"'
];
function isClass(obj) {
  if ("function" === typeof obj) {
    return obj.toString().startsWith("class ") || obj.toString().startsWith("class{");
  }
  return false;
}
chunkFW7TXF3C_cjs.__name(isClass, "isClass");
isClass.__type = [
  "obj",
  "isClass",
  'P"2!!/"'
];
function isGlobalClass(obj) {
  if ("function" !== typeof obj) return false;
  if ("undefined" !== typeof window) {
    return window[getClassName(obj)] === obj;
  }
  if ("undefined" !== typeof global) {
    return global[getClassName(obj)] === obj;
  }
  return false;
}
chunkFW7TXF3C_cjs.__name(isGlobalClass, "isGlobalClass");
isGlobalClass.__type = [
  "obj",
  "isGlobalClass",
  'P"2!!/"'
];
function isObject(obj) {
  if (obj === null) {
    return false;
  }
  return typeof obj === "object" && !isArray(obj);
}
chunkFW7TXF3C_cjs.__name(isObject, "isObject");
isObject.__type = [
  "obj",
  "isObject",
  'P"2!!/"'
];
function isObjectLiteral(obj) {
  return isObject(obj) && !(obj instanceof Date) && !(obj instanceof Map) && !(obj instanceof Set);
}
chunkFW7TXF3C_cjs.__name(isObjectLiteral, "isObjectLiteral");
isObjectLiteral.__type = [
  "obj",
  "isObjectLiteral",
  'P"2!!/"'
];
var isArray = Array.isArray;
function isNull(obj) {
  return null === obj;
}
chunkFW7TXF3C_cjs.__name(isNull, "isNull");
isNull.__type = [
  "obj",
  "isNull",
  'P"2!!/"'
];
function isUndefined(obj) {
  return void 0 === obj;
}
chunkFW7TXF3C_cjs.__name(isUndefined, "isUndefined");
isUndefined.__type = [
  "obj",
  "isUndefined",
  'P"2!!/"'
];
function isSet(obj) {
  return !isNull(obj) && !isUndefined(obj);
}
chunkFW7TXF3C_cjs.__name(isSet, "isSet");
isSet.__type = [
  "obj",
  "isSet",
  'P"2!)/"'
];
function isNumber(obj) {
  return "number" === identifyType(obj);
}
chunkFW7TXF3C_cjs.__name(isNumber, "isNumber");
isNumber.__type = [
  "obj",
  "isNumber",
  'P"2!!/"'
];
function isNumeric(s) {
  if ("number" === typeof s) return true;
  let points = 0;
  for (let i = s.length - 1; i >= 0; i--) {
    const d = s.charCodeAt(i);
    if (d === 46) {
      if (points++ > 0) return false;
      continue;
    }
    if (d < 48 || d > 57) return false;
  }
  return true;
}
chunkFW7TXF3C_cjs.__name(isNumeric, "isNumeric");
isNumeric.__type = [
  "s",
  "isNumeric",
  `PP&'J2!)/"`
];
var isInteger = Number.isInteger || __assignType(function(obj) {
  return obj % 1 === 0;
}, [
  "obj",
  "",
  'P"2!"/"'
]);
function isString(obj) {
  return "string" === identifyType(obj);
}
chunkFW7TXF3C_cjs.__name(isString, "isString");
isString.__type = [
  "obj",
  "isString",
  'P"2!!/"'
];
function indexOf(array, item) {
  if (!array) {
    return -1;
  }
  return array.indexOf(item);
}
chunkFW7TXF3C_cjs.__name(indexOf, "indexOf");
indexOf.__type = [
  "array",
  "item",
  "indexOf",
  `P"F2!"2"'/#`
];
async function sleep(seconds) {
  return Promise.\u03A9 = [
    [
      "$"
    ]
  ], new Promise(__assignType((resolve) => setTimeout(resolve, seconds * 1e3), [
    "resolve",
    "",
    'P"2!"/"'
  ]));
}
chunkFW7TXF3C_cjs.__name(sleep, "sleep");
sleep.__type = [
  "seconds",
  "sleep",
  "P'2!$`/\""
];
function copy(v) {
  if (isArray(v)) {
    return v.slice(0);
  }
  return v;
}
chunkFW7TXF3C_cjs.__name(copy, "copy");
copy.__type = [
  "v",
  "copy",
  'P"F2!"F/"'
];
function empty(value) {
  if (!value) return true;
  if (isArray(value)) {
    return value.length === 0;
  } else {
    for (const i in value) if (value.hasOwnProperty(i)) return false;
    return true;
  }
}
chunkFW7TXF3C_cjs.__name(empty, "empty");
empty.__type = [
  "value",
  "empty",
  'PP"F%PMJ2!8)/"'
];
function size(array) {
  if (!array) {
    return 0;
  }
  if (isArray(array)) {
    return array.length;
  } else {
    return getObjectKeysSize(array);
  }
}
chunkFW7TXF3C_cjs.__name(size, "size");
size.__type = [
  "array",
  "size",
  `PP"FP&"LMJ2!'/"`
];
function firstKey(v) {
  return Object.keys(v)[0];
}
chunkFW7TXF3C_cjs.__name(firstKey, "firstKey");
firstKey.__type = [
  "v",
  "firstKey",
  'PPP&"LM%J2!P&-J/"'
];
function lastKey(v) {
  const keys = Object.keys(v);
  if (keys.length) {
    return;
  }
  return keys[keys.length - 1];
}
chunkFW7TXF3C_cjs.__name(lastKey, "lastKey");
lastKey.__type = [
  "v",
  "lastKey",
  'PPP&"LM%J2!P&-J/"'
];
function first(v) {
  if (isArray(v)) {
    return v[0];
  }
  const key = firstKey(v);
  if (key) {
    return v[key];
  }
  return;
}
chunkFW7TXF3C_cjs.__name(first, "first");
first.__type = [
  "v",
  "first",
  'PPP&"LM"FJ2!P"-J/"'
];
function last(v) {
  if (isArray(v)) {
    if (v.length > 0) {
      return v[v.length - 1];
    }
    return;
  }
  const key = firstKey(v);
  if (key) {
    return v[key];
  }
  return;
}
chunkFW7TXF3C_cjs.__name(last, "last");
last.__type = [
  "v",
  "last",
  'PPP&"LM"FJ2!P"-J/"'
];
function average(array) {
  let sum = 0;
  for (const n of array) {
    sum += n;
  }
  return sum / array.length;
}
chunkFW7TXF3C_cjs.__name(average, "average");
average.__type = [
  "array",
  "average",
  `P'F2!'/"`
];
function prependObjectKeys(o, prependText) {
  const converted = {};
  for (const i in o) {
    if (!o.hasOwnProperty(i)) continue;
    converted[prependText + i] = o[i];
  }
  return converted;
}
chunkFW7TXF3C_cjs.__name(prependObjectKeys, "prependObjectKeys");
prependObjectKeys.__type = [
  "o",
  "prependText",
  "prependObjectKeys",
  'PP&"LM2!&2"P&"LM/#'
];
function appendObject(origin, extend, prependKeyName = "") {
  const no = prependObjectKeys(extend, prependKeyName);
  for (const [i, v] of eachPair(no)) {
    origin[i] = v;
  }
}
chunkFW7TXF3C_cjs.__name(appendObject, "appendObject");
appendObject.__type = [
  "origin",
  "extend",
  "prependKeyName",
  () => "",
  "appendObject",
  'PP&"LM2!P&"LM2"&2#>$"/%'
];
async function asyncOperation(executor) {
  try {
    return await (Promise.\u03A9 = [
      void 0
    ], new Promise(async (resolve, reject) => {
      try {
        await executor(resolve, reject);
      } catch (e) {
        reject(e);
      }
    }));
  } catch (error) {
    mergeStack(error, createStack());
    throw error;
  }
}
chunkFW7TXF3C_cjs.__name(asyncOperation, "asyncOperation");
function fixAsyncOperation(promise) {
  return asyncOperation(__assignType(async (resolve, reject) => {
    resolve(await promise);
  }, [
    "resolve",
    "reject",
    "",
    'P"2!"2""/#'
  ]));
}
chunkFW7TXF3C_cjs.__name(fixAsyncOperation, "fixAsyncOperation");
fixAsyncOperation.__type = [
  "promise",
  "fixAsyncOperation",
  'P"`2!"`/"'
];
function mergePromiseStack(promise, stack2) {
  stack2 = stack2 || createStack();
  promise.then(() => {
  }, __assignType((error) => {
    mergeStack(error, stack2 || "");
  }, [
    "error",
    "",
    'P"2!"/"'
  ]));
  return promise;
}
chunkFW7TXF3C_cjs.__name(mergePromiseStack, "mergePromiseStack");
mergePromiseStack.__type = [
  "promise",
  "stack",
  "mergePromiseStack",
  'P"`2!&2"8"`/#'
];
function createStack(removeCallee = true) {
  if (Error.stackTraceLimit === 10) Error.stackTraceLimit = 100;
  let stack2 = new Error().stack || "";
  stack2 = stack2.slice(stack2.indexOf("   at ") + 6);
  stack2 = stack2.slice(stack2.indexOf("   at ") - 1);
  if (removeCallee) {
    stack2 = stack2.slice(stack2.indexOf("   at ") + 6);
    stack2 = stack2.slice(stack2.indexOf("   at ") - 1);
  }
  return stack2;
}
chunkFW7TXF3C_cjs.__name(createStack, "createStack");
createStack.__type = [
  "removeCallee",
  () => true,
  "createStack",
  'P)2!>"&/#'
];
function mergeStack(error, stack2) {
  if (error instanceof Error && error.stack) {
    error.stack += "\n" + stack2;
  }
}
chunkFW7TXF3C_cjs.__name(mergeStack, "mergeStack");
mergeStack.__type = [
  () => __\u03A9Error,
  "error",
  "stack",
  "mergeStack",
  'Pn!2"&2#"/$'
];
function ensureError(error, classType = Error) {
  return error instanceof Error || error instanceof AggregateError ? error : new classType(error);
}
chunkFW7TXF3C_cjs.__name(ensureError, "ensureError");
ensureError.__type = [
  "error",
  () => __\u03A9ClassType,
  "classType",
  () => Error,
  () => __\u03A9Error,
  "ensureError",
  'P"2!8n"2#>$n%/&'
];
function collectForMicrotask(callback) {
  let items = [];
  let taskScheduled = false;
  return __assignType((arg) => {
    items.push(arg);
    if (!taskScheduled) {
      taskScheduled = true;
      queueMicrotask(() => {
        taskScheduled = false;
        callback(items);
        items.length = 0;
      });
    }
  }, [
    () => callback,
    "args",
    "",
    "arg",
    'PPdi!Ph"!F2"$/#qe!!!j2$"/#'
  ]);
}
chunkFW7TXF3C_cjs.__name(collectForMicrotask, "collectForMicrotask");
collectForMicrotask.__type = [
  "args",
  "",
  "callback",
  "arg",
  "collectForMicrotask",
  'PP"F2!$/"2#P"2$$/"/%'
];
function time() {
  return Date.now() / 1e3;
}
chunkFW7TXF3C_cjs.__name(time, "time");
time.__type = [
  "time",
  "P'/!"
];
function getPathValue(bag, parameterPath, defaultValue) {
  if (parameterPath === "" || parameterPath === void 0) return bag;
  if (isSet(bag[parameterPath])) {
    return bag[parameterPath];
  }
  const result = import_dot_prop.default.get(bag, parameterPath);
  return isSet(result) ? result : defaultValue;
}
chunkFW7TXF3C_cjs.__name(getPathValue, "getPathValue");
getPathValue.__type = [
  "bag",
  "parameterPath",
  "defaultValue",
  "getPathValue",
  'PP&"LM2!&2""2#8"/$'
];
function setPathValue(bag, parameterPath, value) {
  import_dot_prop.default.set(bag, parameterPath, value);
}
chunkFW7TXF3C_cjs.__name(setPathValue, "setPathValue");
setPathValue.__type = [
  "bag",
  "parameterPath",
  "value",
  "setPathValue",
  'P%2!&2""2#"/$'
];
function deletePathValue(bag, parameterPath) {
  import_dot_prop.default.delete(bag, parameterPath);
}
chunkFW7TXF3C_cjs.__name(deletePathValue, "deletePathValue");
deletePathValue.__type = [
  "bag",
  "parameterPath",
  "deletePathValue",
  'P%2!&2""/#'
];
function humanBytes(bytes, si = false) {
  const thresh = si ? 1e3 : 1024;
  if (Math.abs(bytes) < thresh) {
    return bytes + " B";
  }
  const units = si ? [
    "kB",
    "MB",
    "GB",
    "TB",
    "PB",
    "EB",
    "ZB",
    "YB"
  ] : [
    "KiB",
    "MiB",
    "GiB",
    "TiB",
    "PiB",
    "EiB",
    "ZiB",
    "YiB"
  ];
  let u = -1;
  do {
    bytes /= thresh;
    ++u;
  } while (Math.abs(bytes) >= thresh && u < units.length - 1);
  return bytes.toFixed(2) + " " + units[u];
}
chunkFW7TXF3C_cjs.__name(humanBytes, "humanBytes");
humanBytes.__type = [
  "bytes",
  "si",
  () => false,
  "humanBytes",
  `P'2!)2">#&/$`
];
function getObjectKeysSize(obj) {
  let size2 = 0;
  for (let i in obj) if (obj.hasOwnProperty(i)) size2++;
  return size2;
}
chunkFW7TXF3C_cjs.__name(getObjectKeysSize, "getObjectKeysSize");
getObjectKeysSize.__type = [
  "obj",
  "getObjectKeysSize",
  `P%2!'/"`
];
function isConstructable(fn) {
  try {
    new new Proxy(fn, {
      construct: /* @__PURE__ */ chunkFW7TXF3C_cjs.__name(() => ({}), "construct")
    })();
    return true;
  } catch (err) {
    return false;
  }
}
chunkFW7TXF3C_cjs.__name(isConstructable, "isConstructable");
isConstructable.__type = [
  "fn",
  "isConstructable",
  'P"2!)/"'
];
function isPrototypeOfBase(prototype, base) {
  if (!prototype) return false;
  if (prototype === base) return true;
  let currentProto = Object.getPrototypeOf(prototype);
  while (currentProto && currentProto !== Object.prototype) {
    if (currentProto === base) return true;
    currentProto = Object.getPrototypeOf(currentProto);
  }
  return false;
}
chunkFW7TXF3C_cjs.__name(isPrototypeOfBase, "isPrototypeOfBase");
isPrototypeOfBase.__type = [
  () => __\u03A9AbstractClassType,
  "prototype",
  () => __\u03A9ClassType,
  "base",
  "isPrototypeOfBase",
  'PPn!-J2"n#2$)/%'
];
function getParentClass(classType) {
  const parent = Object.getPrototypeOf(classType);
  if (parent === Object.prototype || Object.getPrototypeOf(parent) === Object.prototype) return;
  return parent;
}
chunkFW7TXF3C_cjs.__name(getParentClass, "getParentClass");
getParentClass.__type = [
  () => __\u03A9ClassType,
  "classType",
  () => __\u03A9ClassType,
  "getParentClass",
  'Pn!2"Pn#-J/$'
];
function getInheritanceChain(classType) {
  const chain = [
    classType
  ];
  let current = classType;
  while (current = getParentClass(current)) {
    chain.push(current);
  }
  return chain;
}
chunkFW7TXF3C_cjs.__name(getInheritanceChain, "getInheritanceChain");
getInheritanceChain.__type = [
  () => __\u03A9ClassType,
  "classType",
  () => __\u03A9ClassType,
  "getInheritanceChain",
  'Pn!2"n#F/$'
];
function inDebugMode() {
  return typeof v8debug === "object" || typeof process !== "undefined" && /--debug|--inspect/.test(process.execArgv.join(" "));
}
chunkFW7TXF3C_cjs.__name(inDebugMode, "inDebugMode");
inDebugMode.__type = [
  "inDebugMode",
  'P"/!'
];
function createDynamicClass(name, base) {
  if (base) {
    let baseName = getClassName(base);
    if (baseName === name) baseName += "Base";
    return new Function(baseName, `return class ${name} extends ${baseName} {}`)(base);
  }
  return new Function(`return class ${name} {}`)();
}
chunkFW7TXF3C_cjs.__name(createDynamicClass, "createDynamicClass");
createDynamicClass.__type = [
  "name",
  () => __\u03A9ClassType,
  "base",
  () => __\u03A9ClassType,
  "createDynamicClass",
  'P&2!n"2#8n$/%'
];
function isIterable(value) {
  return isArray(value) || value instanceof Set || value instanceof Map;
}
chunkFW7TXF3C_cjs.__name(isIterable, "isIterable");
isIterable.__type = [
  "value",
  "isIterable",
  'P"2!)/"'
];
function iterableSize(value) {
  return isArray(value) ? value.length : value.size || 0;
}
chunkFW7TXF3C_cjs.__name(iterableSize, "iterableSize");
iterableSize.__type = [
  "value",
  "iterableSize",
  `PP#F#D##EJ2!'/"`
];
function getCurrentFileName() {
  const e = new Error();
  const initiator = e.stack.split("\n").slice(2, 3)[0];
  let path = /(?<path>[^(\s]+):[0-9]+:[0-9]+/.exec(initiator).groups.path;
  if (path.indexOf("file") >= 0) {
    path = new URL(path).pathname;
  }
  if (path[0] === "/" && process.platform === "win32") {
    path = path.slice(1);
  }
  return path;
}
chunkFW7TXF3C_cjs.__name(getCurrentFileName, "getCurrentFileName");
getCurrentFileName.__type = [
  "getCurrentFileName",
  "P&/!"
];
function escapeRegExp(string) {
  return string.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
}
chunkFW7TXF3C_cjs.__name(escapeRegExp, "escapeRegExp");
escapeRegExp.__type = [
  "string",
  "escapeRegExp",
  'P&2!&/"'
];
function hasProperty(object, property) {
  return Object.prototype.hasOwnProperty.call(object, property);
}
chunkFW7TXF3C_cjs.__name(hasProperty, "hasProperty");
hasProperty.__type = [
  "object",
  "property",
  "hasProperty",
  'P"2!"2")/#'
];
function* range(startOrLength, stop = 0, step = 1) {
  let i = startOrLength;
  let end = stop;
  if (stop === 0) {
    i = 0;
    end = startOrLength;
  }
  for (; i < end; i += step) {
    yield i;
  }
}
chunkFW7TXF3C_cjs.__name(range, "range");
range.__type = [
  "startOrLength",
  "stop",
  () => 0,
  "step",
  () => 1,
  () => __\u03A9IterableIterator2,
  "range",
  `P'2!'2">#'2$>%'o&"/'`
];
function rangeArray(startOrLength, stop = 0, step = 1) {
  return [
    ...range(startOrLength, stop, step)
  ];
}
chunkFW7TXF3C_cjs.__name(rangeArray, "rangeArray");
rangeArray.__type = [
  "startOrLength",
  "stop",
  () => 0,
  "step",
  () => 1,
  "rangeArray",
  `P'2!'2">#'2$>%'F/&`
];
function zip(...args) {
  const minLength = Math.min(...args.map(__assignType((arr) => arr.length, [
    "arr",
    "",
    'P"2!"/"'
  ])));
  return Array.from({
    length: minLength
  }).map(__assignType((_, i) => args.map(__assignType((arr) => arr[i], [
    "arr",
    "",
    'P"2!"/"'
  ])), [
    "_",
    "i",
    "",
    'P"2!"2""/#'
  ]));
}
chunkFW7TXF3C_cjs.__name(zip, "zip");
zip.__type = [
  "args",
  "zip",
  `l:e"!R!RPd"e#!fh!!Fqk#'QRP"@2!Pd"gN)!F/"`
];
function forwardTypeArguments(x, y) {
  y.\u03A9 = x.\u03A9;
  x.\u03A9 = void 0;
}
chunkFW7TXF3C_cjs.__name(forwardTypeArguments, "forwardTypeArguments");
forwardTypeArguments.__type = [
  "x",
  "y",
  "forwardTypeArguments",
  'P"2!"2"$/#'
];
function formatError(error, withStack = false) {
  if (error && error.name === "AggregateError" && "errors" in error) {
    return `${withStack && error.stack || `AggregateError: ${error.message}`}
Errors:
${error.errors.map(__assignType((v) => formatError(v), [
      "v",
      "",
      'P"2!"/"'
    ])).join("\n")}`;
  }
  if (error instanceof Error) {
    let current = error.cause;
    let errors = [
      withStack && error.stack || error.message || "Error"
    ];
    while (current) {
      errors.push(`cause by ${formatError(current)}`);
      current = current.cause;
    }
    return errors.join("\n");
  }
  if (withStack && error.stack) return error.stack;
  return String(error);
}
chunkFW7TXF3C_cjs.__name(formatError, "formatError");
formatError.__type = [
  "error",
  "withStack",
  () => false,
  "formatError",
  'P"2!)2">#&/$'
];
function assertInstanceOf(object, constructor) {
  if (!(object instanceof constructor)) {
    throw new Error(`Object ${getClassName(object)} is not an instance of the expected class ${getClassName(constructor)}`);
  }
}
chunkFW7TXF3C_cjs.__name(assertInstanceOf, "assertInstanceOf");
assertInstanceOf.__type = [
  "object",
  "args",
  "new",
  "constructor",
  "assertInstanceOf",
  'P"2!PP"@2""1#M2$!/%'
];
function assertDefined(value) {
  if (value === null || value === void 0) {
    throw new Error(`Value is not defined`);
  }
}
chunkFW7TXF3C_cjs.__name(assertDefined, "assertDefined");
assertDefined.__type = [
  "value",
  "assertDefined",
  'P"2!!/"'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/perf.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var import_to_fast_properties = chunkFW7TXF3C_cjs.__toESM(require_to_fast_properties(), 1);
function toFastProperties(obj) {
  (0, import_to_fast_properties.default)(obj);
}
chunkFW7TXF3C_cjs.__name(toFastProperties, "toFastProperties");
toFastProperties.__type = [
  "obj",
  "toFastProperties",
  'P"2!"/"'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/decorators.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var __\u03A9PropertyDescriptor = [
  "configurable",
  "enumerable",
  "value",
  "writable",
  "get",
  "v",
  "set",
  "PropertyDescriptor",
  `P)4!8)4"8"4#8)4$8P"1%P"2&$1'Mw(y`
];
var __\u03A9TypedPropertyDescriptor = [
  "T",
  "enumerable",
  "configurable",
  "writable",
  "value",
  "",
  "get",
  "set",
  "TypedPropertyDescriptor",
  `b!P)4"8)4#8)4$8e"!4%8Pe#!/&4'8Pe#!2%$/&4(8Mw)y`
];
function __assignType2(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType2, "__assignType");
function log() {
  return __assignType2(function(target, propertyKey, descriptor) {
    const orig = descriptor.value;
    descriptor.value = __assignType2(function(...args) {
      const a = args.map(__assignType2((v) => typeof v, [
        "v",
        "",
        'P"2!"/"'
      ])).join(",");
      console.info(getClassName(target) + "::" + String(propertyKey) + "(" + a + ")");
      return orig.apply(this, args);
    }, [
      "args",
      "",
      'P"@2!"/"'
    ]);
    return descriptor;
  }, [
    "target",
    "propertyKey",
    () => __\u03A9PropertyDescriptor,
    "descriptor",
    "",
    'P%2!P&+J2"n#2$"/%'
  ]);
}
chunkFW7TXF3C_cjs.__name(log, "log");
log.__type = [
  "log",
  'P"/!'
];
function stack() {
  return __assignType2(function(target, propertyKey, descriptor) {
    const orig = descriptor.value;
    descriptor.value = __assignType2(async function(...args) {
      const name = "__c_" + propertyKey;
      if (this[name] === void 0) {
        this[name] = null;
        toFastProperties(this);
      }
      while (this[name]) {
        await this[name];
      }
      this[name] = orig.apply(this, args);
      try {
        return await this[name];
      } finally {
        this[name] = null;
      }
    }, [
      "args",
      "",
      'P"@2!"/"'
    ]);
  }, [
    "target",
    "propertyKey",
    () => __\u03A9TypedPropertyDescriptor,
    "args",
    "",
    "descriptor",
    'P%2!&2"P"@2$"`/%o#"2&"/%'
  ]);
}
chunkFW7TXF3C_cjs.__name(stack, "stack");
stack.__type = [
  "stack",
  'P"/!'
];
function singleStack() {
  return __assignType2(function(target, propertyKey, descriptor) {
    const orig = descriptor.value;
    descriptor.value = __assignType2(async function(...args) {
      const name = "__sc_" + propertyKey;
      if (this[name] === void 0) {
        this[name] = null;
        toFastProperties(this);
      }
      if (this[name]) {
        return await this[name];
      }
      this[name] = orig.apply(this, args);
      try {
        return await this[name];
      } finally {
        this[name] = null;
      }
    }, [
      "args",
      "",
      'P"@2!"/"'
    ]);
  }, [
    "target",
    "propertyKey",
    () => __\u03A9TypedPropertyDescriptor,
    "args",
    "",
    "descriptor",
    'P%2!&2"P"@2$"`/%o#"2&"/%'
  ]);
}
chunkFW7TXF3C_cjs.__name(singleStack, "singleStack");
singleStack.__type = [
  "singleStack",
  'P"/!'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/enum.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var __\u03A9Object2 = [
  () => Function,
  "constructor",
  "toString",
  "toLocaleString",
  0,
  "valueOf",
  () => __\u03A9PropertyKey2,
  "v",
  "hasOwnProperty",
  0,
  "isPrototypeOf",
  () => __\u03A9PropertyKey2,
  "propertyIsEnumerable",
  "Object",
  `PPu!4"P&1#P&1$Pn%1&Pn'2()1)Pn*2()1+Pn,2()1-Mw.y`
];
var __\u03A9PropertyKey2 = [
  "PropertyKey",
  "P&'+Jw!y"
];
function __assignType3(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType3, "__assignType");
var cacheEnumLabels = (Map.\u03A9 = [
  [
    () => __\u03A9Object2,
    "n!"
  ],
  [
    "&F"
  ]
], /* @__PURE__ */ new Map());
function getEnumLabel(enumType, id) {
  for (const i of eachKey(enumType)) {
    if (id === enumType[i]) {
      return i;
    }
  }
}
chunkFW7TXF3C_cjs.__name(getEnumLabel, "getEnumLabel");
getEnumLabel.__type = [
  "enumType",
  "id",
  "getEnumLabel",
  'PP&"LM2!"2""/#'
];
function getEnumLabels(enumDefinition) {
  let value = cacheEnumLabels.get(enumDefinition);
  if (!value) {
    value = Object.keys(enumDefinition).filter(__assignType3((v) => !Number.isFinite(parseInt(v, 10)), [
      "v",
      "",
      'P"2!"/"'
    ]));
    cacheEnumLabels.set(enumDefinition, value);
  }
  return value;
}
chunkFW7TXF3C_cjs.__name(getEnumLabels, "getEnumLabels");
getEnumLabels.__type = [
  "enumDefinition",
  "getEnumLabels",
  'P"2!"/"'
];
var cacheEnumKeys = (Map.\u03A9 = [
  [
    () => __\u03A9Object2,
    "n!"
  ],
  [
    "&F"
  ]
], /* @__PURE__ */ new Map());
function getEnumValues(enumDefinition) {
  let value = cacheEnumKeys.get(enumDefinition);
  if (!value) {
    value = Object.values(enumDefinition).filter(__assignType3((v) => {
      return "number" !== typeof enumDefinition[v];
    }, [
      "v",
      "",
      'P"2!"/"'
    ]));
    cacheEnumKeys.set(enumDefinition, value);
  }
  return value;
}
chunkFW7TXF3C_cjs.__name(getEnumValues, "getEnumValues");
getEnumValues.__type = [
  "enumDefinition",
  "getEnumValues",
  'P"2!"F/"'
];
function getEnumKeyLabelMap(enumDefinition) {
  const map = (Map.\u03A9 = [
    [
      '"'
    ],
    [
      "&"
    ]
  ], /* @__PURE__ */ new Map());
  const keys = getEnumValues(enumDefinition);
  const labels = getEnumLabels(enumDefinition);
  for (let i = 0; i < keys.length; i++) {
    map.set(keys[i], labels[i]);
  }
  return map;
}
chunkFW7TXF3C_cjs.__name(getEnumKeyLabelMap, "getEnumKeyLabelMap");
getEnumKeyLabelMap.__type = [
  "enumDefinition",
  "getEnumKeyLabelMap",
  'P"2!"&E/"'
];
function isValidEnumValue(enumDefinition, value, allowLabelsAsValue = false) {
  if (allowLabelsAsValue) {
    const labels = getEnumLabels(enumDefinition);
    if (-1 !== labels.indexOf(String(value))) {
      return true;
    }
  }
  const values = getEnumValues(enumDefinition);
  return -1 !== values.indexOf(+value) || -1 !== values.indexOf(value) || -1 !== values.indexOf(String(value));
}
chunkFW7TXF3C_cjs.__name(isValidEnumValue, "isValidEnumValue");
isValidEnumValue.__type = [
  "enumDefinition",
  "value",
  "allowLabelsAsValue",
  "isValidEnumValue",
  'P"2!"2""2#"/$'
];
function getValidEnumValue(enumDefinition, value, allowLabelsAsValue = false) {
  if (allowLabelsAsValue) {
    const labels = getEnumLabels(enumDefinition);
    if (-1 !== labels.indexOf(String(value))) {
      return enumDefinition[String(value)];
    }
  }
  const values = getEnumValues(enumDefinition);
  if (-1 !== values.indexOf(value)) {
    return value;
  }
  if (-1 !== values.indexOf(+value)) {
    return +value;
  }
  if (-1 !== values.indexOf(String(value))) {
    return String(value);
  }
}
chunkFW7TXF3C_cjs.__name(getValidEnumValue, "getValidEnumValue");
getValidEnumValue.__type = [
  "enumDefinition",
  "value",
  "allowLabelsAsValue",
  "getValidEnumValue",
  'P"2!"2""2#"/$'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/timer.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var Timer = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "Timer");
  }
  constructor() {
    this.timeoutTimers = [];
  }
  setTimeout(cb, timeout) {
    const timer = setTimeout(cb, timeout);
    this.timeoutTimers.push(timer);
    return timer;
  }
  /**
   * Clears all timers at once.
   */
  clear() {
    for (const timeout of this.timeoutTimers) {
      clearTimeout(timeout);
    }
  }
};
Timer.__type = [
  "timeoutTimers",
  function() {
    return [];
  },
  "",
  "cb",
  "timeout",
  "setTimeout",
  "clear",
  "Timer",
  `"F3!<>"PP$/#2$'2%"0&P"0'5w(`
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/array.js
chunkFW7TXF3C_cjs.init_cjs_shims();
function arrayHasItem(array, item) {
  return -1 !== array.indexOf(item);
}
chunkFW7TXF3C_cjs.__name(arrayHasItem, "arrayHasItem");
arrayHasItem.__type = [
  "array",
  "item",
  "arrayHasItem",
  'P"F2!"2")/#'
];
function arrayClear(array) {
  const found = array.length;
  array.length = 0;
  return found;
}
chunkFW7TXF3C_cjs.__name(arrayClear, "arrayClear");
arrayClear.__type = [
  "array",
  "arrayClear",
  `P"F2!'/"`
];
function arrayRemoveItem(array, item) {
  const index = array.indexOf(item);
  if (-1 !== index) {
    array.splice(index, 1);
    return true;
  }
  return false;
}
chunkFW7TXF3C_cjs.__name(arrayRemoveItem, "arrayRemoveItem");
arrayRemoveItem.__type = [
  "array",
  "item",
  "arrayRemoveItem",
  'P"F2!"2")/#'
];
function arrayMoveItem(array, item, move) {
  if (move === 0) return array;
  const index = array.indexOf(item);
  if (-1 !== index) {
    const newIndex = index + move;
    array.splice(index, 1);
    if (newIndex <= 0) {
      array.unshift(item);
    } else if (newIndex >= array.length) {
      array.push(item);
    } else {
      array.splice(newIndex, 0, item);
    }
  }
  return array;
}
chunkFW7TXF3C_cjs.__name(arrayMoveItem, "arrayMoveItem");
arrayMoveItem.__type = [
  "array",
  "item",
  "move",
  "arrayMoveItem",
  `P"2!"2"'2#"/$`
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/process-locker.js
chunkFW7TXF3C_cjs.init_cjs_shims();
function __assignType4(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType4, "__assignType");
var LOCKS = {};
var ProcessLock = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "ProcessLock");
  }
  constructor(id) {
    this.id = id;
    this.holding = false;
  }
  async acquire(ttl = 0, timeout = 0) {
    if (this.holding) {
      throw new Error("Lock already acquired");
    }
    return Promise.\u03A9 = [
      [
        "$"
      ]
    ], new Promise(__assignType4((resolve, reject) => {
      if (LOCKS[this.id]) {
        let timeoutId;
        const ourTake = /* @__PURE__ */ chunkFW7TXF3C_cjs.__name(() => {
          LOCKS[this.id].time = Date.now() / 1e3;
          clearTimeout(timeoutId);
          this.holding = true;
          resolve();
          if (ttl) {
            this.ttlTimeout = setTimeout(() => {
              this.unlock();
            }, ttl * 1e3);
          }
        }, "ourTake");
        if (timeout > 0) {
          timeoutId = setTimeout(() => {
            if (LOCKS[this.id]) arrayRemoveItem(LOCKS[this.id].queue, ourTake);
            reject("Lock timed out " + this.id);
          }, timeout * 1e3);
        }
        LOCKS[this.id].queue.push(ourTake);
      } else {
        LOCKS[this.id] = {
          time: Date.now() / 1e3,
          queue: []
        };
        this.holding = true;
        resolve();
        if (ttl) {
          this.ttlTimeout = setTimeout(() => {
            this.unlock();
          }, ttl * 1e3);
        }
      }
    }, [
      "resolve",
      "reject",
      "",
      'P"2!"2""/#'
    ]));
  }
  isLocked() {
    return this.holding;
  }
  tryLock(ttl = 0) {
    this.holding = false;
    if (!LOCKS[this.id]) {
      LOCKS[this.id] = {
        time: Date.now() / 1e3,
        queue: []
      };
      this.holding = true;
      if (ttl) {
        this.ttlTimeout = setTimeout(() => {
          this.unlock();
        }, ttl * 1e3);
      }
    }
    return this.holding;
  }
  unlock() {
    clearTimeout(this.ttlTimeout);
    if (!this.holding) {
      return;
    }
    this.holding = false;
    if (LOCKS[this.id].queue.length) {
      const next = LOCKS[this.id].queue.shift();
      next();
    } else {
      delete LOCKS[this.id];
    }
  }
};
ProcessLock.__type = [
  "holding",
  function() {
    return false;
  },
  "ttlTimeout",
  "id",
  "constructor",
  "ttl",
  () => 0,
  "timeout",
  () => 0,
  "acquire",
  "isLocked",
  () => 0,
  "tryLock",
  "unlock",
  "ProcessLock",
  `)3!;>""3#<P&2$:9"0%P'2&>''2(>)"0*P"0+P'2&>,"0-P"0.5w/`
];
var ProcessLocker = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "ProcessLocker");
  }
  /**
   *
   * @param id
   * @param ttl optional defines when the times automatically unlocks.
   * @param timeout if after `timeout` seconds the lock isn't acquired, it throws an error.
   */
  async acquireLock(id, ttl = 0, timeout = 0) {
    const lock = new ProcessLock(id);
    await lock.acquire(ttl, timeout);
    return lock;
  }
  async tryLock(id, ttl = 0) {
    const lock = new ProcessLock(id);
    if (lock.tryLock(ttl)) {
      return lock;
    }
    return;
  }
  isLocked(id) {
    return !!LOCKS[id];
  }
};
ProcessLocker.__type = [
  "id",
  "ttl",
  () => 0,
  "timeout",
  () => 0,
  () => ProcessLock,
  "acquireLock",
  () => 0,
  () => ProcessLock,
  "tryLock",
  "isLocked",
  "ProcessLocker",
  "P&2!'2\">#'2$>%P7&`0'P&2!'2\">(PP7)-J`0*P&2!)0+5w,"
];
var Mutex = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "Mutex");
  }
  unlock() {
    if (this.resolver) this.resolver();
    this.promise = void 0;
  }
  async lock() {
    while (this.promise) {
      await this.promise;
    }
    this.promise = new Promise(__assignType4((resolver) => {
      this.resolver = resolver;
    }, [
      "resolver",
      "",
      'P"2!"/"'
    ]));
  }
};
Mutex.__type = [
  "promise",
  () => Function,
  "resolver",
  "unlock",
  "lock",
  "Mutex",
  '$`3!8<Pu"3#8<P$0$P$`0%5w&'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/network.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var ParsedHost = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "ParsedHost");
  }
  constructor() {
    this.host = "127.0.0.1";
    this.port = 0;
    this.unixSocket = "";
  }
  get isUnixSocket() {
    return this.unixSocket !== "";
  }
  get isHostname() {
    return this.unixSocket === "";
  }
  get hostWithIp() {
    return this.host + (this.port ? (this.host && ":") + this.port : "");
  }
  toString() {
    return this.isUnixSocket ? this.unixSocket : this.hostWithIp;
  }
  getWebSocketUrl(secure = false) {
    const protocol = secure ? "wss" : "ws";
    if (this.isUnixSocket) {
      return `${protocol}+unix://${this.unixSocket}`;
    }
    return `${protocol}://${this.hostWithIp}`;
  }
  getHttpUrl(secure = false) {
    if (this.isUnixSocket) {
      return `file://${this.unixSocket}`;
    }
    const protocol = secure ? "https" : "http";
    return `${protocol}://${this.hostWithIp}`;
  }
};
ParsedHost.__type = [
  "host",
  function() {
    return "127.0.0.1";
  },
  "port",
  function() {
    return 0;
  },
  "unixSocket",
  function() {
    return "";
  },
  "toString",
  "secure",
  () => false,
  "getWebSocketUrl",
  () => false,
  "getHttpUrl",
  "ParsedHost",
  `&3!>"'3#>$&3%>&!!!P&0'P)2(>)"0*P)2(>+"0,5w-`
];
function parseHost(hostWithIpOrUnixPath) {
  const parsedHost = new ParsedHost();
  if (hostWithIpOrUnixPath.includes("/") || hostWithIpOrUnixPath.includes("\\") || hostWithIpOrUnixPath.endsWith(".sock")) {
    parsedHost.unixSocket = hostWithIpOrUnixPath;
  } else {
    if (hostWithIpOrUnixPath.includes(":")) {
      const [host, port] = hostWithIpOrUnixPath.split(":");
      if (host) parsedHost.host = host;
      if (port) parsedHost.port = parseInt(port, 10);
    } else {
      if (hostWithIpOrUnixPath) parsedHost.host = hostWithIpOrUnixPath;
    }
  }
  return parsedHost;
}
chunkFW7TXF3C_cjs.__name(parseHost, "parseHost");
parseHost.__type = [
  "hostWithIpOrUnixPath",
  () => ParsedHost,
  "parseHost",
  'P&2!P7"/#'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/compiler.js
chunkFW7TXF3C_cjs.init_cjs_shims();

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/indent.js
chunkFW7TXF3C_cjs.init_cjs_shims();
function __assignType5(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType5, "__assignType");
var indent = __assignType5(function(n) {
  function t(n2, t2) {
    var e2, r2 = [];
    for (e2 = 0; e2 < n2.length; e2++) r2.push(t2(n2[e2], e2, n2));
    return r2;
  }
  chunkFW7TXF3C_cjs.__name(t, "t");
  t.__type = [
    "n",
    "t",
    'P"2!"2""/"'
  ];
  function e(n2, t2) {
    var e2, r2;
    for (e2 = 0; e2 < n2.length; e2++) if (r2 = t2(n2[e2], e2, n2)) return r2;
    return false;
  }
  chunkFW7TXF3C_cjs.__name(e, "e");
  e.__type = [
    "n",
    "t",
    "e",
    'P"2!"2""/#'
  ];
  function r(n2, t2, e2) {
    if (d[n2]) return d[n2];
    var r2 = [];
    d[n2] = r2, e2 = e2 || "";
    for (var a2 = 0; a2 < t2.length; a2++) t2[a2].a.indexOf(n2.toLowerCase()) !== -1 && e2.indexOf(t2[a2].b) === -1 && r2.push(t2[a2]);
    return r2;
  }
  chunkFW7TXF3C_cjs.__name(r, "r");
  r.__type = [
    "n",
    "t",
    "e",
    "r",
    'P"2!"2""2#"/$'
  ];
  function a(n2, a2, o2) {
    function h2(n3) {
      P = n3.cursor;
      var t2 = n3.rule, e2 = E + 1 + (t2.c || 0);
      n3.line = e2, Z.push(n3), t2.d && z[e2]++, t2.e && (S = r(t2.e, g)), t2.f && F.push(null), t2.callback && t2.callback(n3, z, O);
    }
    chunkFW7TXF3C_cjs.__name(h2, "h");
    h2.__type = [
      "n",
      "h",
      'P"2!"/"'
    ];
    function d2() {
      var n3 = Z.pop(), t2 = n3.line, e2 = n3.rule;
      if (e2.d) {
        var r2 = "function" == typeof e2.g ? e2.g(b) : e2.g, a3 = r2 || 0 !== b.matchIndex ? 1 : 0;
        O[E + a3] && O[E + a3].push(t2);
      }
      e2.e && (S = null), e2.f && F.pop(), F[F.length - 1] = n3;
    }
    chunkFW7TXF3C_cjs.__name(d2, "d");
    d2.__type = [
      "d",
      'P"/!'
    ];
    function m2(n3, r2, a3) {
      n3 = n3.substring(a3, n3.length);
      for (var l2, s2, i2, c2 = null, u2 = n3.length, o3 = F[F.length - 1], h3 = o3 ? o3.rule.b : "", d3 = t(Z, __assignType5(function(n4) {
        return n4.rule.b;
      }, [
        "n",
        "",
        'P"2!"/"'
      ])).join("\n"), m3 = 0; m3 < r2.length; m3++) i2 = r2[m3], i2.h && e(i2.h, __assignType5(function(n4) {
        return d3.indexOf(n4) != -1;
      }, [
        "n",
        "",
        'P"2!"/"'
      ])) || (!i2.i || h3 && i2.i.indexOf(h3) !== -1) && (s2 = f(n3, i2.j, i2), s2.matchIndex != -1 && s2.matchIndex < u2 && (!i2.k || 0 === a3) && (u2 = s2.matchIndex, l2 = s2, c2 = i2));
      return {
        rule: c2,
        relativeIndex: c2 ? u2 : -1,
        matchIndex: c2 ? u2 + a3 : -1,
        cursor: c2 ? a3 + l2.cursor : -1,
        state: l2 ? l2.state : {},
        lastMatch: o3
      };
    }
    chunkFW7TXF3C_cjs.__name(m2, "m");
    m2.__type = [
      "n",
      "r",
      "a",
      "m",
      'P"2!"2""2#"/$'
    ];
    function j2(n3, t2, e2, r2) {
      n3 = n3.substr(e2, n3.length);
      var a3 = t2.rule, l2 = f(n3, a3.l, a3, t2.state, r2), s2 = a3.m ? l2.cursor : l2.matchIndex;
      return {
        endPatternIndex: l2.endPatternIndex,
        matchIndex: l2.matchIndex === -1 ? -1 : l2.matchIndex + e2,
        cursor: s2 === -1 ? -1 : s2 + e2,
        state: l2.state
      };
    }
    chunkFW7TXF3C_cjs.__name(j2, "j");
    j2.__type = [
      "n",
      "t",
      "e",
      "r",
      "j",
      'P"2!"2""2#"2$"/%'
    ];
    n2 = n2 || "";
    var b, x, v, p, I, y = o2 && null != o2.tabString ? o2.tabString : "	", k = n2.split(/[\r]?\n/gi), w = k.length, A = s(w), z = s(w), O = l(w), Z = [], F = [
      null
    ], E = 0, P = 0, S = null;
    for (o2 && (o2.debug = {
      buffers: {
        ignore: A,
        indent: z,
        dedent: O,
        active: Z
      }
    }); E < w; ) {
      if (v = k[E].trim(), p = u(v) + "\r\n", I = Z[Z.length - 1], x = m2(p, S || a2, P), Z.length) {
        if (b = j2(p, I, P, x), b.matchIndex === -1) {
          if (I.rule.n) {
            A[E] = 1, E++, P = 0;
            continue;
          }
        } else if (I.rule.n || x.matchIndex === -1 || b.matchIndex <= x.matchIndex) {
          d2(), P = b.cursor;
          continue;
        }
      }
      x.matchIndex !== -1 ? h2(x) : (E++, P = 0);
    }
    var $, q, R, T, M, C, H = 0, L = i(z), _ = s(w), B = [];
    for (M = 0; M < w; M++) {
      for (q = O[M], T = 0, C = 0; C < q.length; C++) R = q[C], R < 0 ? -R !== M && (_[-R]++, T += 1) : L[R] > 0 && (L[R]--, T += R !== M);
      $ = L[M], _[M] = $ > T ? 1 : $ < T ? $ - T : 0, L[M] = $ > 0 ? 1 : 0;
    }
    for (M = 0; M < w; M++) 1 === A[M - 1] && 1 === A[M] ? B.push(k[M]) : (H += _[M] || 0, B.push((H > 0 ? c(y, H) : "") + k[M].trim()));
    return B.join("\r\n");
  }
  chunkFW7TXF3C_cjs.__name(a, "a");
  a.__type = [
    "n",
    "a",
    "o",
    'P"2!"2""2#"/"'
  ];
  function l(n2) {
    for (var t2 = new Array(n2), e2 = 0; e2 < n2; e2++) t2[e2] = [];
    return t2;
  }
  chunkFW7TXF3C_cjs.__name(l, "l");
  l.__type = [
    "n",
    "l",
    'P"2!"/"'
  ];
  function s(t2) {
    if (n.Int16Array) return new Int16Array(t2);
    for (var e2 = new Array(t2), r2 = 0; r2 < t2; r2++) e2[r2] = 0;
    return e2;
  }
  chunkFW7TXF3C_cjs.__name(s, "s");
  s.__type = [
    "t",
    "s",
    'P"2!"/"'
  ];
  function i(n2) {
    for (var t2 = s(n2.length), e2 = 0; e2 < n2.length; e2++) t2[e2] = n2[e2];
    return t2;
  }
  chunkFW7TXF3C_cjs.__name(i, "i");
  i.__type = [
    "n",
    "i",
    'P"2!"/"'
  ];
  function c(n2, t2) {
    return new Array(t2 + 1).join(n2);
  }
  chunkFW7TXF3C_cjs.__name(c, "c");
  c.__type = [
    "n",
    "t",
    "c",
    'P"2!"2""/#'
  ];
  function u(n2) {
    return n2.replace(/\\(u[0-9A-Za-z]{4}|u\{[0-9A-Za-z]{1,6}]\}|x[0-9A-Za-z]{2}|.)/g, "0");
  }
  chunkFW7TXF3C_cjs.__name(u, "u");
  u.__type = [
    "n",
    "u",
    'P"2!"/"'
  ];
  function o(n2, t2, e2) {
    var r2 = n2.lastMatch;
    r2 && "=" === r2.rule.b && e2[n2.line].push(-r2.line);
  }
  chunkFW7TXF3C_cjs.__name(o, "o");
  o.__type = [
    "n",
    "t",
    "e",
    "o",
    'P"2!"2""2#"/$'
  ];
  function h(n2, t2, e2, r2) {
    var a2;
    if (e2.newline) {
      if (a2 = n2.search(/[;,=]?\r*\n/), a2 !== -1) return {
        matchIndex: a2,
        length: 1
      };
    } else a2 = n2.search(/[^\s\r\n\{\(\[]/), e2.newline = a2 !== -1 && (a2 <= r2.relativeIndex || r2.relativeIndex === -1);
    return null;
  }
  chunkFW7TXF3C_cjs.__name(h, "h");
  h.__type = [
    "n",
    "t",
    "e",
    "r",
    "h",
    'P"2!"2""2#"2$"/%'
  ];
  function f(n2, t2, e2, r2, a2) {
    r2 = r2 || {};
    for (var l2, s2, i2 = -1, c2 = 0, u2 = 0; u2 < t2.length; u2++) if (s2 = t2[u2], "function" == typeof s2) {
      if (l2 = s2(n2, e2, r2, a2)) {
        i2 = l2.matchIndex, c2 = l2.length;
        break;
      }
    } else if (l2 = n2.match(s2)) {
      i2 = n2.search(s2), c2 = l2[0].length;
      break;
    }
    return {
      endPatternIndex: u2,
      matchIndex: i2,
      cursor: i2 + c2,
      state: r2
    };
  }
  chunkFW7TXF3C_cjs.__name(f, "f");
  f.__type = [
    "n",
    "t",
    "e",
    "r",
    "a",
    "f",
    'P"2!"2""2#"2$"2%"/&'
  ];
  var d = {};
  String.prototype.trim || (String.prototype.trim = function() {
    return this.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
  });
  var m = /\r*\n/, j = [
    "tag",
    "void-tags",
    "html-tag"
  ], g = [
    {
      a: "js html",
      b: "comment",
      j: [
        /\<\!\-\-/
      ],
      l: [
        /\-\-\>/
      ],
      n: true,
      m: true
    },
    {
      a: "html",
      b: "doctype",
      j: [
        /\<\!doctype html>/i
      ],
      l: [
        m
      ],
      n: true,
      m: true
    },
    {
      a: "js html",
      b: "void-tags",
      j: [
        /\<(area|base|br|col|command|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)/i
      ],
      l: [
        />/
      ],
      d: true,
      m: true
    },
    {
      a: "html",
      b: "mode switch js",
      j: [
        __assignType5(function(n2) {
          var t2 = /<script[\s>].*/i, e2 = /<\/script>/i, r2 = t2.exec(n2), a2 = e2.exec(n2);
          return r2 && (!a2 || a2.index < r2.index) ? {
            matchIndex: r2.index,
            length: r2[0].length
          } : null;
        }, [
          "n",
          "",
          'P"2!"/"'
        ])
      ],
      l: [
        /<\/script>/i
      ],
      e: "js",
      m: true,
      d: true,
      f: true
    },
    {
      a: "html",
      b: "mode switch css",
      j: [
        __assignType5(function(n2) {
          var t2 = /<style[\s>].*/i, e2 = /<\/style>/i, r2 = t2.exec(n2), a2 = e2.exec(n2);
          return r2 && (!a2 || a2.index < r2.index) ? {
            matchIndex: r2.index,
            length: r2[0].length
          } : null;
        }, [
          "n",
          "",
          'P"2!"/"'
        ])
      ],
      l: [
        /<\/style>/i
      ],
      e: "css",
      m: true,
      d: true,
      f: true
    },
    {
      a: "html",
      b: "html-tag",
      j: [
        /<html[^A-Za-z0-9]/i
      ],
      l: [
        /<\/html>/i
      ],
      m: true
    },
    {
      a: "js html",
      b: "tag",
      j: [
        __assignType5(function(n2, t2, e2) {
          var r2 = /<([A-Za-z][A-Za-z0-9\-\.]*)/, a2 = n2.match(r2);
          return a2 ? (e2.openingTag = a2[1], {
            matchIndex: a2.index,
            length: a2[0].length
          }) : null;
        }, [
          "n",
          "t",
          "e",
          "",
          'P"2!"2""2#"/$'
        ])
      ],
      l: [
        __assignType5(function(n2, t2, e2) {
          var r2 = new RegExp("</" + e2.openingTag + ">|\\s/>", "i"), a2 = n2.match(r2);
          return a2 ? {
            matchIndex: a2.index,
            length: a2[0].length
          } : null;
        }, [
          "n",
          "t",
          "e",
          "",
          'P"2!"2""2#"/$'
        ])
      ],
      d: true,
      m: true
    },
    {
      a: "js",
      b: "line-comment",
      j: [
        /\/\//
      ],
      l: [
        m
      ],
      n: true
    },
    {
      a: "js css",
      b: "block-comment",
      j: [
        /\/\*/
      ],
      l: [
        /\*\//
      ],
      n: true,
      m: true
    },
    {
      a: "js",
      b: "regex",
      j: [
        __assignType5(function(n2, t2) {
          var e2 = /[(,=:[!&|?{};][\s]*\/[^\/]|^[\s]*\/[^\/]/, r2 = n2.search(e2);
          if (r2 != -1) {
            r2 = n2.indexOf("/", r2);
            var a2 = n2.substring(r2 + 1), l2 = f(a2, t2.l, t2);
            if (l2.matchIndex != -1) {
              a2 = a2.substring(0, l2.matchIndex);
              try {
                return new RegExp(a2), {
                  matchIndex: r2,
                  length: 1
                };
              } catch (s2) {
                return null;
              }
            }
          }
          return null;
        }, [
          "n",
          "t",
          "",
          'P"2!"2""/#'
        ])
      ],
      l: [
        __assignType5(function(n2) {
          for (var t2 = 0, e2 = n2.indexOf("/"); e2 != -1; ) try {
            new RegExp(n2.substring(0, e2));
            break;
          } catch (r2) {
            e2 = n2.indexOf("/", t2), t2 = e2 + 1;
          }
          return e2 === -1 ? null : {
            matchIndex: e2,
            length: 1
          };
        }, [
          "n",
          "",
          'P"2!"/"'
        ])
      ],
      n: true,
      m: true
    },
    {
      a: "js html",
      b: "quotes",
      h: j,
      j: [
        /"/
      ],
      l: [
        /"/,
        m
      ],
      n: true,
      m: true
    },
    {
      a: "js html",
      b: "quotes",
      h: j,
      j: [
        /'/
      ],
      l: [
        /'/,
        m
      ],
      n: true,
      m: true
    },
    {
      a: "js css",
      b: "string",
      j: [
        /(''|""|``)/
      ],
      l: [
        /./,
        m
      ]
    },
    {
      a: "js css",
      b: "string",
      j: [
        /\"(?=[^"])/
      ],
      l: [
        /[^\\]\"/,
        m
      ],
      n: true,
      m: true
    },
    {
      a: "js css",
      b: "string",
      j: [
        /\'(?=[^'])/
      ],
      l: [
        /[^\\]\'/,
        m
      ],
      n: true,
      m: true
    },
    {
      a: "js css",
      b: "string",
      j: [
        /\`(?=[^`])/
      ],
      l: [
        /[^\\]\`/
      ],
      n: true,
      m: true
    },
    {
      a: "js",
      b: "if",
      j: [
        /^if\s*(?=\()/,
        /[\s]+if\s*(?=\()/
      ],
      l: [
        /else[\s]+/,
        h,
        /[{;]/
      ],
      d: true
    },
    {
      a: "js",
      b: "for|while",
      j: [
        /^(for|while)\s*(?=\()/
      ],
      l: [
        h,
        /[{;]/
      ],
      d: true
    },
    {
      a: "js",
      b: "else",
      j: [
        /else[\s]+/
      ],
      l: [
        /if[^\w$]/,
        h,
        /[{;]/
      ],
      d: true
    },
    {
      a: "js css",
      b: "bracket",
      j: [
        /\(\s*(var|let|const)?\s*/
      ],
      l: [
        /\)/
      ],
      d: true,
      m: true,
      f: true
    },
    {
      a: "js",
      b: "dot-chain",
      j: [
        /^\.[A-Za-z$_]/
      ],
      l: [
        /[\.;]/,
        m
      ],
      d: true,
      k: true,
      c: -1
    },
    {
      a: "js",
      b: "dot-chain",
      j: [
        /\.\s*\r*\n/
      ],
      l: [
        /[\.;})\]]/,
        /[^\s]\s*\r*\n/
      ],
      d: true
    },
    {
      a: "js css",
      b: "array",
      j: [
        /\[/
      ],
      l: [
        /\]/
      ],
      d: true,
      m: true,
      f: true
    },
    {
      a: "js css",
      b: "block",
      j: [
        /\{/
      ],
      l: [
        /\}/
      ],
      d: true,
      m: true,
      f: true
    },
    {
      a: "js",
      b: "var/let/const",
      j: [
        /(var|let|const)[\s]*\r*\n/
      ],
      l: [
        h
      ],
      d: true,
      g: true
    },
    {
      a: "js",
      b: "var/let/const",
      j: [
        /(var|let|const)\s+(?=[\w$])/
      ],
      l: [
        /[,;=]/,
        h
      ],
      d: true
    },
    {
      a: "js",
      b: "var/let/const",
      i: [
        "var/let/const",
        "="
      ],
      j: [
        /,[\s]*\r*\n/
      ],
      l: [
        /[,;]/,
        h
      ],
      d: true,
      callback: o
    },
    {
      a: "js",
      b: "var/let/const",
      i: [
        "var/let/const",
        "="
      ],
      j: [
        /^,/
      ],
      l: [
        /[,;]/,
        h
      ],
      k: true,
      d: true,
      c: -1,
      callback: o
    },
    {
      a: "js",
      b: "equality",
      j: [
        /[=<>!]=(=)?/
      ],
      l: [
        /./
      ]
    },
    {
      a: "js",
      b: "=",
      h: j,
      j: [
        /=/
      ],
      l: [
        /[,;\)\]}]/,
        m
      ]
    },
    {
      a: "js",
      b: "?:",
      j: [
        /\?/
      ],
      l: [
        /[:;]/
      ],
      g: true,
      d: true
    },
    {
      a: "js",
      b: "case",
      j: [
        /^(case|default)[\s:]/
      ],
      l: [
        /break[\s;\r\n]/,
        /^return[\s;\r\n]/,
        /^case[\s]+/,
        /^default[\s:]/,
        /}/
      ],
      g: __assignType5(function(n2) {
        return n2.endPatternIndex <= 1;
      }, [
        "n",
        "",
        'P"2!"/"'
      ]),
      d: true,
      f: true
    },
    {
      a: "js",
      b: "semicolon",
      j: [
        /;/
      ],
      l: [
        /./
      ]
    }
  ];
  return {
    css: __assignType5(function(n2, t2) {
      return a(n2, r("css", g), t2);
    }, [
      "n",
      "t",
      "",
      'P"2!"2""/#'
    ]),
    js: __assignType5(function(n2, t2) {
      return a(n2, r("js", g), t2);
    }, [
      "n",
      "t",
      "",
      'P"2!"2""/#'
    ]),
    ts: __assignType5(function(n2, t2) {
      return a(n2, r("js", g), t2);
    }, [
      "n",
      "t",
      "",
      'P"2!"2""/#'
    ]),
    html: __assignType5(function(n2, t2) {
      var e2 = t2 && t2.indentHtmlTag ? r("html", g, "html-tag") : r("html", g);
      return a(n2, e2, t2);
    }, [
      "n",
      "t",
      "",
      'P"2!"2""/#'
    ])
  };
}, [
  "n",
  "",
  'P"2!"/"'
])(globalThis);

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/compiler.js
var __\u03A9Partial = [
  "T",
  "Partial",
  'l+e#!e"!fRb!Pde"!gN#"w"y'
];
var indentCode = ("undefined" !== typeof process && process.env?.DEBUG || "").includes("deepkit");
var CompilerContext = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "CompilerContext");
  }
  constructor(config = {}) {
    this.context = (Map.\u03A9 = [
      [
        "&"
      ],
      [
        '"'
      ]
    ], /* @__PURE__ */ new Map());
    this.constVariables = (Map.\u03A9 = [
      [
        '"'
      ],
      [
        "&"
      ]
    ], /* @__PURE__ */ new Map());
    this.maxReservedVariable = 1e4;
    this.reservedNames = (Set.\u03A9 = [
      [
        "&"
      ]
    ], /* @__PURE__ */ new Set());
    this.variableContext = {};
    this.preCode = "";
    this.initialiseVariables = [];
    this.config = {
      indent: false
    };
    Object.assign(this.config, config);
    this.context.set("_context", this.variableContext);
  }
  reserveName(name) {
    for (let i = 0; i < this.maxReservedVariable; i++) {
      const candidate = name + "_" + i;
      if (!this.reservedNames.has(candidate)) {
        this.reservedNames.add(candidate);
        return candidate;
      }
    }
    throw new Error(`Too many context variables (max ${this.maxReservedVariable})`);
  }
  set(values) {
    for (const i in values) {
      if (!hasProperty(values, i)) {
        continue;
      }
      this.context.set(i, values[i]);
    }
  }
  /**
   * Returns always the same variable name for the same value.
   * The variable name should not be set afterwards.
   */
  reserveConst(value, name = "constVar") {
    if (value === void 0) throw new Error("Can not reserve const for undefined value");
    let constName = this.constVariables.get(value);
    if (!constName) {
      constName = this.reserveName(name);
      this.constVariables.set(value, constName);
      this.context.set(constName, value);
    }
    return constName;
  }
  reserveVariable(name = "var", value) {
    const freeName = this.reserveName(name);
    if (value === void 0) {
      return "_context." + freeName;
    } else {
      this.context.set(freeName, value);
      return freeName;
    }
  }
  raw(functionCode) {
    try {
      return new Function(...this.context.keys(), `'use strict';
` + functionCode)(...this.context.values());
    } catch (error) {
      throw new Error("Could not build function: " + error + functionCode);
    }
  }
  format(code) {
    if (indentCode || this.config.indent) return indent.js(code, {
      tabString: "    "
    });
    return code;
  }
  build(functionCode, ...args) {
    functionCode = this.format(`
            'use strict';
            ${this.preCode}
            return function self(${args.join(", ")}){
                'use strict';
                ${functionCode}
            };
        `);
    try {
      return new Function(...this.context.keys(), functionCode)(...this.context.values());
    } catch (error) {
      throw new Error(`Could not build function(${[
        ...this.context.keys()
      ].join(",")}): ` + error + functionCode);
    }
  }
  buildAsync(functionCode, ...args) {
    functionCode = `
            'use strict';
            ${this.preCode}
            return async function self(${args.join(", ")}){
                'use strict';
                ${functionCode}
            };
        `;
    try {
      return new Function(...this.context.keys(), this.format(functionCode))(...this.context.values());
    } catch (error) {
      throw new Error("Could not build function: " + error + functionCode);
    }
  }
};
CompilerContext.__type = [
  "context",
  function() {
    return Map.\u03A9 = [
      [
        "&"
      ],
      [
        '"'
      ]
    ], /* @__PURE__ */ new Map();
  },
  "constVariables",
  function() {
    return Map.\u03A9 = [
      [
        '"'
      ],
      [
        "&"
      ]
    ], /* @__PURE__ */ new Map();
  },
  "maxReservedVariable",
  function() {
    return 1e4;
  },
  "reservedNames",
  function() {
    return Set.\u03A9 = [
      [
        "&"
      ]
    ], /* @__PURE__ */ new Set();
  },
  "variableContext",
  function() {
    return {};
  },
  "preCode",
  function() {
    return "";
  },
  "initialiseVariables",
  function() {
    return [];
  },
  "indent",
  "config",
  function() {
    return {
      indent: false
    };
  },
  () => __\u03A9Partial,
  () => CompilerContext,
  "config",
  () => ({}),
  "constructor",
  "name",
  "reserveName",
  "values",
  "set",
  "value",
  () => "constVar",
  "reserveConst",
  () => "var",
  "reserveVariable",
  "functionCode",
  () => Function,
  "raw",
  "code",
  "format",
  "args",
  "build",
  () => Function,
  "buildAsync",
  "CompilerContext",
  `!3!9>"!3#<>$'3%>&!3'<>(P&"LM3)<>*&3+>,&F3->.P)4/M30>1PP73.4fo2"20>5"06P&27&08PP&"LM29"0:P"2;&27><&0=P&27>>"2;8&0?P&2@PuA0BP&2C&0D<P&2@&@2E"0FP&2@&@2EPuG0H5wI`
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/string.js
chunkFW7TXF3C_cjs.init_cjs_shims();
function __assignType6(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType6, "__assignType");
function indent2(indentation, prefix = "") {
  return __assignType6((str = "") => {
    return " ".repeat(indentation) + str.replace(/\n/g, "\n" + " ".repeat(indentation) + prefix);
  }, [
    "str",
    () => "",
    "",
    'P&2!>""/#'
  ]);
}
chunkFW7TXF3C_cjs.__name(indent2, "indent");
indent2.__type = [
  "indentation",
  "prefix",
  () => "",
  "indent",
  `P'2!&2">#"/$`
];
function capitalize(string) {
  return string.charAt(0).toUpperCase() + string.slice(1);
}
chunkFW7TXF3C_cjs.__name(capitalize, "capitalize");
capitalize.__type = [
  "string",
  "capitalize",
  'P&2!&/"'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/emitter.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var __\u03A9AsyncSubscriber = [
  "T",
  "event",
  "",
  "AsyncSubscriber",
  'b!Pe"!2"P$`$J/#w$y'
];
var __\u03A9Subscriber = [
  "T",
  "event",
  "",
  "Subscriber",
  'b!Pe"!2"P$`$J/#w$y'
];
var __\u03A9AsyncEventSubscription = [
  "",
  "unsubscribe",
  "AsyncEventSubscription",
  'PP$/!4"Mw#y'
];
var __\u03A9EventSubscription = [
  "",
  "unsubscribe",
  "EventSubscription",
  'PP$/!4"Mw#y'
];
var asyncId = 0;
var EmitterEvent = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "EmitterEvent");
  }
  constructor() {
    this.id = asyncId++;
    this.stopped = false;
    this.propagationStopped = false;
  }
  /**
   * Stop propagating the event to subsequent event listeners.
   */
  stopPropagation() {
    this.propagationStopped = true;
  }
  /**
   * Signal the emitter that you want to abort.
   * Subsequent event listeners will still be called.
   */
  stop() {
    this.stopped = true;
  }
};
EmitterEvent.__type = [
  "id",
  function() {
    return asyncId++;
  },
  "stopped",
  function() {
    return false;
  },
  "propagationStopped",
  function() {
    return false;
  },
  "stopPropagation",
  "stop",
  "EmitterEvent",
  `!3!9>")3#>$)3%>&P"0'P"0(5w)`
];
var EventEmitter = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "EventEmitter");
  }
  constructor(parent) {
    this.parent = parent;
    this.subscribers = [];
  }
  subscribe(callback) {
    this.subscribers.push(callback);
    return {
      unsubscribe: /* @__PURE__ */ chunkFW7TXF3C_cjs.__name(() => {
        arrayRemoveItem(this.subscribers, callback);
      }, "unsubscribe")
    };
  }
  emit(event) {
    if (this.parent) this.parent.emit(event);
    if (event.propagationStopped) return;
    for (const subscriber of this.subscribers) {
      subscriber(event);
      if (event.propagationStopped) return;
    }
  }
  hasSubscriptions() {
    return this.subscribers.length > 0;
  }
};
EventEmitter.__type = [
  "T",
  () => __\u03A9Subscriber,
  "subscribers",
  function() {
    return [];
  },
  () => EventEmitter,
  "parent",
  "constructor",
  () => __\u03A9Subscriber,
  "callback",
  () => __\u03A9EventSubscription,
  "subscribe",
  "event",
  "emit",
  "hasSubscriptions",
  "EventEmitter",
  `b!e!!o""F3#<>$PP"7%2&8<"0'Pe"!o("2)n*0+Pe"!2,$0-P)0.5w/`
];
var AsyncEventEmitter = class {
  static {
    chunkFW7TXF3C_cjs.__name(this, "AsyncEventEmitter");
  }
  constructor(parent) {
    this.parent = parent;
    this.subscribers = [];
  }
  subscribe(callback) {
    this.subscribers.push(callback);
    return {
      unsubscribe: /* @__PURE__ */ chunkFW7TXF3C_cjs.__name(() => {
        arrayRemoveItem(this.subscribers, callback);
      }, "unsubscribe")
    };
  }
  async emit(event) {
    if (this.parent) await this.parent.emit(event);
    if (event.propagationStopped) return;
    for (const subscriber of this.subscribers) {
      await subscriber(event);
      if (event.propagationStopped) return;
    }
  }
  hasSubscriptions() {
    return this.subscribers.length > 0;
  }
};
AsyncEventEmitter.__type = [
  "T",
  () => __\u03A9AsyncSubscriber,
  "subscribers",
  function() {
    return [];
  },
  () => AsyncEventEmitter,
  "parent",
  "constructor",
  () => __\u03A9AsyncSubscriber,
  "callback",
  () => __\u03A9AsyncEventSubscription,
  "subscribe",
  "event",
  "emit",
  "hasSubscriptions",
  "AsyncEventEmitter",
  'b!e!!o""F3#<>$PP"7%2&8<"0\'Pe"!o("2)n*0+Pe"!2,$`0-P)0.5w/'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/reactive.js
chunkFW7TXF3C_cjs.init_cjs_shims();
function __assignType7(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType7, "__assignType");
var nextTick = typeof requestAnimationFrame !== "undefined" ? __assignType7((cb) => requestAnimationFrame(cb), [
  "",
  "cb",
  'PP$/!2""/!'
]) : __assignType7((cb) => setTimeout(cb), [
  "",
  "cb",
  'PP$/!2""/!'
]);
var clearTick = typeof requestAnimationFrame !== "undefined" ? __assignType7((id) => cancelAnimationFrame(id), [
  "id",
  "",
  'P"2!"/"'
]) : __assignType7((id) => clearTick(id), [
  "id",
  "",
  'P"2!"/"'
]);
function throttleTime(call, cps = 5) {
  let last2 = Date.now();
  let dirty = false;
  let lastArgs = [];
  let execution = false;
  function tick() {
    const now = Date.now();
    if (!execution && now - last2 > 1e3 / cps) {
      execution = true;
      call(...lastArgs);
      dirty = false;
      last2 = Date.now();
      execution = false;
    }
    if (dirty) {
      nextTick(tick);
    }
  }
  chunkFW7TXF3C_cjs.__name(tick, "tick");
  tick.__type = [
    "tick",
    'P"/!'
  ];
  return __assignType7((...args) => {
    dirty = true;
    lastArgs = args;
    tick();
  }, [
    "args",
    "",
    'P"@2!"/"'
  ]);
}
chunkFW7TXF3C_cjs.__name(throttleTime, "throttleTime");
throttleTime.__type = [
  () => Function,
  "call",
  "cps",
  "args",
  "",
  "throttleTime",
  'PPu!2""2#P"@2$$/%/&'
];
function bufferedGate(callback) {
  const q = [];
  let activated = false;
  const throttled = throttleTime(async () => {
    if (q.length === 0) return;
    for (const t of q) {
      const result = callback(t);
      if (result instanceof Promise) {
        await result;
      }
    }
    q.splice(0, q.length);
  });
  return {
    activate: /* @__PURE__ */ chunkFW7TXF3C_cjs.__name(() => {
      activated = true;
      throttled();
    }, "activate"),
    call: __assignType7((i) => {
      q.push(i);
      if (activated) {
        throttled();
      }
    }, [
      () => callback,
      "arg",
      "",
      "i",
      'PPdi!Ph"!2""/#qe!!!j2$"/#'
    ])
  };
}
chunkFW7TXF3C_cjs.__name(bufferedGate, "bufferedGate");
bufferedGate.__type = [
  "arg",
  "",
  "callback",
  "bufferedGate",
  'PP"2!"/"2#"/$'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/reflection.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var COMMENTS = /((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg;
var DEFAULT_PARAMS = /=[^,]+/mg;
var FAT_ARROWS = /=>.*$/mg;
function extractParameters(fn) {
  fn = typeof fn === "string" ? fn : fn.toString();
  fn = removeStrings(fn);
  if (fn.startsWith("class")) {
    const start = fn.match(new RegExp("[	 \n{]constructor\\("));
    if (!start) return [];
    fn = fn.substr((start.index || 0) + start[0].length);
    fn = fn.replace(COMMENTS, "").replace(FAT_ARROWS, "").replace(DEFAULT_PARAMS, "");
    return fn.slice(0, fn.indexOf("{")).match(/([^\(\){\s,]+)/g) || [];
  } else {
    fn = fn.replace(COMMENTS, "").replace(FAT_ARROWS, "").replace(DEFAULT_PARAMS, "");
    return fn.slice(fn.indexOf("(") + 1, fn.indexOf("{")).match(/([^\(\)\{\}\s,]+)/g) || [];
  }
}
chunkFW7TXF3C_cjs.__name(extractParameters, "extractParameters");
extractParameters.__type = [
  () => Function,
  () => __\u03A9ClassType,
  "fn",
  "extractParameters",
  'PP&Pu!n"J2#&F/$'
];
function extractMethodBody(classCode, name) {
  let methodCode = "";
  classCode = removeStrings(classCode);
  const start = classCode.match(new RegExp("[	 \n]" + name + "\\("));
  if (!start) return "";
  classCode = classCode.substr((start.index || 0) + start[0].length);
  let blockDepth = 1;
  classCode = classCode.substr(classCode.indexOf("{") + 1);
  for (let i = 0; i < classCode.length; i++) {
    const char = classCode[i];
    if (char === "{") blockDepth++;
    if (char === "}") blockDepth--;
    if (blockDepth === 0) {
      return methodCode;
    }
    if (char === "\n" || char === "	" || char === " ") continue;
    methodCode += char;
  }
  return methodCode;
}
chunkFW7TXF3C_cjs.__name(extractMethodBody, "extractMethodBody");
extractMethodBody.__type = [
  "classCode",
  "name",
  "extractMethodBody",
  'P&2!&2"&/#'
];
function removeStrings(code) {
  let result = "";
  let inString = false;
  for (let i = 0; i < code.length; i++) {
    const char = code[i];
    if (inString && char === "\\") {
      i++;
      continue;
    }
    if (char === '"') {
      if (inString === '"') {
        inString = false;
        continue;
      }
      if (!inString) {
        inString = '"';
        continue;
      }
    }
    if (char === "'") {
      if (inString === "'") {
        inString = false;
        continue;
      }
      if (!inString) {
        inString = "'";
        continue;
      }
    }
    if (!inString) {
      result += char;
    }
  }
  return result;
}
chunkFW7TXF3C_cjs.__name(removeStrings, "removeStrings");
removeStrings.__type = [
  "code",
  "removeStrings",
  'P&2!"/"'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/url.js
chunkFW7TXF3C_cjs.init_cjs_shims();
function __assignType8(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType8, "__assignType");
function removeSlash(v) {
  return v.replace(/(^\/+)|(\/+$)/g, "");
}
chunkFW7TXF3C_cjs.__name(removeSlash, "removeSlash");
removeSlash.__type = [
  "v",
  "removeSlash",
  'P&2!&/"'
];
function urlJoin(...path) {
  const leadingSlash = path[0] && path[0] !== "/" && path[0][0] === "/";
  const last2 = path[path.length - 1];
  const trailingSlash = last2 && last2 !== "/" && last2[last2.length - 1] === "/";
  return (leadingSlash ? "/" : "") + path.filter(__assignType8((v) => !!v, [
    "v",
    "",
    'P"2!"/"'
  ])).map(__assignType8((v) => v === "/" ? "" : removeSlash(v.trim()), [
    "v",
    "",
    'P"2!"/"'
  ])).join("/") + (trailingSlash ? "/" : "");
}
chunkFW7TXF3C_cjs.__name(urlJoin, "urlJoin");
urlJoin.__type = [
  "path",
  "urlJoin",
  'P&@2!&/"'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/types.js
chunkFW7TXF3C_cjs.init_cjs_shims();
var __\u03A9TypeAnnotation = [
  "T",
  "Options",
  "TypeAnnotation",
  'b!!c"#w#y'
];
var __\u03A9InjectMeta = [
  "T",
  () => __\u03A9TypeAnnotation,
  "inject",
  "InjectMeta",
  '!c!.#e!!o"#w$y'
];
var __\u03A9Inject = [
  "Type",
  "Token",
  () => __\u03A9InjectMeta,
  "Inject",
  'b!!c"Pe"!e""o#"Kw$y'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/buffer.js
chunkFW7TXF3C_cjs.init_cjs_shims();
function __assignType9(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType9, "__assignType");
var createBuffer = "undefined" !== typeof Buffer && "function" === typeof Buffer.allocUnsafe ? Buffer.allocUnsafe : __assignType9((size2) => new Uint8Array(size2), [
  "size",
  "",
  'P"2!"/"'
]);
function bufferConcat(chunks, length) {
  if (void 0 === length) {
    length = 0;
    for (const chunk of chunks) length += chunk.length;
  }
  const result = createBuffer(length);
  let offset = 0;
  for (const chunk of chunks) {
    result.set(chunk, offset);
    offset += chunk.length;
  }
  return result;
}
chunkFW7TXF3C_cjs.__name(bufferConcat, "bufferConcat");
bufferConcat.__type = [
  "chunks",
  "length",
  "bufferConcat",
  `PWF2!'2"8W/#`
];
var textEncoder = new TextDecoder();
var uint8ArrayToUtf8 = "undefined" !== typeof Buffer ? __assignType9((buffer) => Buffer.from(buffer).toString("utf8"), [
  "buffer",
  "",
  'PW2!"/"'
]) : __assignType9((buffer) => textEncoder.decode(buffer), [
  "buffer",
  "",
  'PW2!"/"'
]);
function bufferToString(buffer) {
  if ("string" === typeof buffer) return buffer;
  return uint8ArrayToUtf8(buffer);
}
chunkFW7TXF3C_cjs.__name(bufferToString, "bufferToString");
bufferToString.__type = [
  "buffer",
  "bufferToString",
  'PP&WJ2!&/"'
];
function nativeBase64ToUint8Array(base64) {
  const raw = atob(base64);
  const rawLength = raw.length;
  const array = createBuffer(rawLength);
  for (let i = 0; i < rawLength; i++) {
    array[i] = raw.charCodeAt(i);
  }
  return array;
}
chunkFW7TXF3C_cjs.__name(nativeBase64ToUint8Array, "nativeBase64ToUint8Array");
nativeBase64ToUint8Array.__type = [
  "base64",
  "nativeBase64ToUint8Array",
  'P&2!W/"'
];
var base64ToUint8Array = "undefined" === typeof Buffer ? nativeBase64ToUint8Array : __assignType9((base64) => Buffer.from(base64, "base64"), [
  "base64",
  "",
  'P&2!"/"'
]);

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/src/path.js
chunkFW7TXF3C_cjs.init_cjs_shims();
function __assignType10(fn, args) {
  fn.__type = args;
  return fn;
}
chunkFW7TXF3C_cjs.__name(__assignType10, "__assignType");
function pathNormalize(path) {
  path = path[0] !== "/" ? "/" + path : path;
  path = path.length > 1 && path[path.length - 1] === "/" ? path.slice(0, -1) : path;
  return path.replace(/\/+/g, "/");
}
chunkFW7TXF3C_cjs.__name(pathNormalize, "pathNormalize");
pathNormalize.__type = [
  "path",
  "pathNormalize",
  'P&2!&/"'
];
function pathDirectory(path) {
  if (path === "/") return "/";
  const lastSlash = path.lastIndexOf("/");
  return lastSlash <= 0 ? "/" : path.slice(0, lastSlash);
}
chunkFW7TXF3C_cjs.__name(pathDirectory, "pathDirectory");
pathDirectory.__type = [
  "path",
  "pathDirectory",
  'P&2!&/"'
];
function pathBasename(path) {
  const lastSlash = path.lastIndexOf("/");
  return lastSlash === -1 ? path : path.slice(lastSlash + 1);
}
chunkFW7TXF3C_cjs.__name(pathBasename, "pathBasename");
pathBasename.__type = [
  "path",
  "pathBasename",
  'P&2!&/"'
];
function pathExtension(path) {
  const basename = pathBasename(path);
  const lastDot = basename.lastIndexOf(".");
  return lastDot === -1 ? "" : basename.slice(lastDot + 1);
}
chunkFW7TXF3C_cjs.__name(pathExtension, "pathExtension");
pathExtension.__type = [
  "path",
  "pathExtension",
  'P&2!&/"'
];
function pathJoin(...paths) {
  return "/" + paths.map(__assignType10((v) => pathNormalize(v).slice(1), [
    "v",
    "",
    'P"2!"/"'
  ])).filter(__assignType10((v) => !!v, [
    "v",
    "",
    'P"2!"/"'
  ])).join("/");
}
chunkFW7TXF3C_cjs.__name(pathJoin, "pathJoin");
pathJoin.__type = [
  "paths",
  "pathJoin",
  'P&@2!&/"'
];

// ../../node_modules/.pnpm/@deepkit+core@1.0.5_patch_hash=8c3beca4372c6a8941162780ddd0f977ef3d461c2018f0809f86f416260ba440/node_modules/@deepkit/core/dist/esm/index.js
chunkFW7TXF3C_cjs.init_cjs_shims();

exports.AsyncEventEmitter = AsyncEventEmitter;
exports.AsyncFunction = AsyncFunction;
exports.CompilerContext = CompilerContext;
exports.CustomError = CustomError;
exports.EmitterEvent = EmitterEvent;
exports.EventEmitter = EventEmitter;
exports.Mutex = Mutex;
exports.ParsedHost = ParsedHost;
exports.ProcessLock = ProcessLock;
exports.ProcessLocker = ProcessLocker;
exports.Timer = Timer;
exports.__ΩAbstractClassType = __ΩAbstractClassType;
exports.__ΩAsyncEventSubscription = __ΩAsyncEventSubscription;
exports.__ΩClassType = __ΩClassType;
exports.__ΩCustomError = __ΩCustomError;
exports.__ΩEventSubscription = __ΩEventSubscription;
exports.__ΩExtractClassType = __ΩExtractClassType;
exports.__ΩInject = __ΩInject;
exports.__ΩInjectMeta = __ΩInjectMeta;
exports.__ΩTypeAnnotation = __ΩTypeAnnotation;
exports.appendObject = appendObject;
exports.applyDefaults = applyDefaults;
exports.arrayClear = arrayClear;
exports.arrayHasItem = arrayHasItem;
exports.arrayMoveItem = arrayMoveItem;
exports.arrayRemoveItem = arrayRemoveItem;
exports.assertDefined = assertDefined;
exports.assertInstanceOf = assertInstanceOf;
exports.asyncOperation = asyncOperation;
exports.average = average;
exports.base64ToUint8Array = base64ToUint8Array;
exports.bufferConcat = bufferConcat;
exports.bufferToString = bufferToString;
exports.bufferedGate = bufferedGate;
exports.capitalize = capitalize;
exports.changeClass = changeClass;
exports.clearTick = clearTick;
exports.collectForMicrotask = collectForMicrotask;
exports.copy = copy;
exports.createBuffer = createBuffer;
exports.createDynamicClass = createDynamicClass;
exports.createStack = createStack;
exports.deletePathValue = deletePathValue;
exports.each = each;
exports.eachKey = eachKey;
exports.eachPair = eachPair;
exports.empty = empty;
exports.ensureError = ensureError;
exports.escapeRegExp = escapeRegExp;
exports.extractMethodBody = extractMethodBody;
exports.extractParameters = extractParameters;
exports.first = first;
exports.firstKey = firstKey;
exports.fixAsyncOperation = fixAsyncOperation;
exports.formatError = formatError;
exports.forwardTypeArguments = forwardTypeArguments;
exports.getClassName = getClassName;
exports.getClassPropertyName = getClassPropertyName;
exports.getClassTypeFromInstance = getClassTypeFromInstance;
exports.getCurrentFileName = getCurrentFileName;
exports.getEnumKeyLabelMap = getEnumKeyLabelMap;
exports.getEnumLabel = getEnumLabel;
exports.getEnumLabels = getEnumLabels;
exports.getEnumValues = getEnumValues;
exports.getInheritanceChain = getInheritanceChain;
exports.getObjectKeysSize = getObjectKeysSize;
exports.getParentClass = getParentClass;
exports.getPathValue = getPathValue;
exports.getValidEnumValue = getValidEnumValue;
exports.hasProperty = hasProperty;
exports.humanBytes = humanBytes;
exports.identifyType = identifyType;
exports.inDebugMode = inDebugMode;
exports.indent = indent2;
exports.indexOf = indexOf;
exports.isArray = isArray;
exports.isAsyncFunction = isAsyncFunction;
exports.isClass = isClass;
exports.isClassInstance = isClassInstance;
exports.isConstructable = isConstructable;
exports.isFunction = isFunction;
exports.isGlobalClass = isGlobalClass;
exports.isInteger = isInteger;
exports.isIterable = isIterable;
exports.isNull = isNull;
exports.isNumber = isNumber;
exports.isNumeric = isNumeric;
exports.isObject = isObject;
exports.isObjectLiteral = isObjectLiteral;
exports.isPlainObject = isPlainObject;
exports.isPromise = isPromise;
exports.isPrototypeOfBase = isPrototypeOfBase;
exports.isSet = isSet;
exports.isString = isString;
exports.isUndefined = isUndefined;
exports.isValidEnumValue = isValidEnumValue;
exports.iterableSize = iterableSize;
exports.last = last;
exports.lastKey = lastKey;
exports.log = log;
exports.mergePromiseStack = mergePromiseStack;
exports.mergeStack = mergeStack;
exports.nativeBase64ToUint8Array = nativeBase64ToUint8Array;
exports.nextTick = nextTick;
exports.parseHost = parseHost;
exports.pathBasename = pathBasename;
exports.pathDirectory = pathDirectory;
exports.pathExtension = pathExtension;
exports.pathJoin = pathJoin;
exports.pathNormalize = pathNormalize;
exports.prependObjectKeys = prependObjectKeys;
exports.prettyPrintObject = prettyPrintObject;
exports.range = range;
exports.rangeArray = rangeArray;
exports.removeStrings = removeStrings;
exports.setPathValue = setPathValue;
exports.singleStack = singleStack;
exports.size = size;
exports.sleep = sleep;
exports.stack = stack;
exports.stringifyValueWithType = stringifyValueWithType;
exports.throttleTime = throttleTime;
exports.time = time;
exports.toFastProperties = toFastProperties;
exports.uint8ArrayToUtf8 = uint8ArrayToUtf8;
exports.urlJoin = urlJoin;
exports.zip = zip;
//# sourceMappingURL=chunk-PGQ2Z24T.cjs.map
//# sourceMappingURL=chunk-PGQ2Z24T.cjs.map