@nhtio/lucid-resourceful 1.20250718.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (68) hide show
  1. package/LICENSE.md +9 -0
  2. package/README.md +5 -0
  3. package/decorator_utils-1yWqd_Gg.cjs +6792 -0
  4. package/decorator_utils-1yWqd_Gg.cjs.map +1 -0
  5. package/decorator_utils-BUuBwQYK.js +6793 -0
  6. package/decorator_utils-BUuBwQYK.js.map +1 -0
  7. package/definitions-B66EPk0H.js +381 -0
  8. package/definitions-B66EPk0H.js.map +1 -0
  9. package/definitions-BrN-oCRI.cjs +380 -0
  10. package/definitions-BrN-oCRI.cjs.map +1 -0
  11. package/definitions.cjs +15 -0
  12. package/definitions.cjs.map +1 -0
  13. package/definitions.d.ts +5 -0
  14. package/definitions.mjs +15 -0
  15. package/definitions.mjs.map +1 -0
  16. package/errors-B1rr67uM.js +3004 -0
  17. package/errors-B1rr67uM.js.map +1 -0
  18. package/errors-D8jb9VxY.cjs +3000 -0
  19. package/errors-D8jb9VxY.cjs.map +1 -0
  20. package/errors.cjs +22 -0
  21. package/errors.cjs.map +1 -0
  22. package/errors.d.ts +94 -0
  23. package/errors.mjs +22 -0
  24. package/errors.mjs.map +1 -0
  25. package/index-Cv6KC1rC.cjs +670 -0
  26. package/index-Cv6KC1rC.cjs.map +1 -0
  27. package/index-DDaZ2qr2.js +671 -0
  28. package/index-DDaZ2qr2.js.map +1 -0
  29. package/index.cjs +12706 -0
  30. package/index.cjs.map +1 -0
  31. package/index.d.ts +14 -0
  32. package/index.mjs +12708 -0
  33. package/index.mjs.map +1 -0
  34. package/joi.cjs +5 -0
  35. package/joi.cjs.map +1 -0
  36. package/joi.d.ts +5 -0
  37. package/joi.mjs +5 -0
  38. package/joi.mjs.map +1 -0
  39. package/package.json +65 -0
  40. package/private/constants.d.ts +11 -0
  41. package/private/controller_factory.d.ts +1 -0
  42. package/private/data_type_schemas.d.ts +12 -0
  43. package/private/data_types.d.ts +437 -0
  44. package/private/decorator_schemas.d.ts +34 -0
  45. package/private/decorator_utils.d.ts +305 -0
  46. package/private/decorators.d.ts +209 -0
  47. package/private/helpers.d.ts +34 -0
  48. package/private/joi/bigint.d.ts +85 -0
  49. package/private/joi/index.d.ts +65 -0
  50. package/private/lucene_to_lucid_translator.d.ts +201 -0
  51. package/private/mixin.d.ts +563 -0
  52. package/private/schema_types.d.ts +157 -0
  53. package/private/type_guards.d.ts +42 -0
  54. package/private/types.d.ts +102 -0
  55. package/private/utils.d.ts +10 -0
  56. package/types.cjs +2 -0
  57. package/types.cjs.map +1 -0
  58. package/types.d.ts +28 -0
  59. package/types.mjs +2 -0
  60. package/types.mjs.map +1 -0
  61. package/utils/casters.d.ts +1 -0
  62. package/utils/consumers.d.ts +1 -0
  63. package/utils/preparers.d.ts +1 -0
  64. package/utils.cjs +50 -0
  65. package/utils.cjs.map +1 -0
  66. package/utils.d.ts +20 -0
  67. package/utils.mjs +51 -0
  68. package/utils.mjs.map +1 -0
@@ -0,0 +1,3000 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __typeError = (msg) => {
4
+ throw TypeError(msg);
5
+ };
6
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
7
+ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
8
+ var __accessCheck = (obj, member, msg) => member.has(obj) || __typeError("Cannot " + msg);
9
+ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read from private field"), getter ? getter.call(obj) : member.get(obj));
10
+ var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
11
+ var __privateSet = (obj, member, value, setter) => (__accessCheck(obj, member, "write to private field"), setter ? setter.call(obj, value) : member.set(obj, value), value);
12
+ var _ignoreNull, _a;
13
+ const node_util = require("node:util");
14
+ require("url");
15
+ require("path");
16
+ require("fs/promises");
17
+ const crypto = require("crypto");
18
+ require("buffer");
19
+ exports.Exception = class Exception extends Error {
20
+ constructor(message, options) {
21
+ super(message, options);
22
+ /**
23
+ * Name of the class that raised the exception.
24
+ */
25
+ __publicField(this, "name");
26
+ /**
27
+ * A status code for the error. Usually helpful when converting errors
28
+ * to HTTP responses.
29
+ */
30
+ __publicField(this, "status");
31
+ const ErrorConstructor = this.constructor;
32
+ this.name = ErrorConstructor.name;
33
+ this.message = message || ErrorConstructor.message || "";
34
+ this.status = (options == null ? void 0 : options.status) || ErrorConstructor.status || 500;
35
+ const code = (options == null ? void 0 : options.code) || ErrorConstructor.code;
36
+ if (code !== void 0) {
37
+ this.code = code;
38
+ }
39
+ const help = ErrorConstructor.help;
40
+ if (help !== void 0) {
41
+ this.help = help;
42
+ }
43
+ Error.captureStackTrace(this, ErrorConstructor);
44
+ }
45
+ get [Symbol.toStringTag]() {
46
+ return this.constructor.name;
47
+ }
48
+ toString() {
49
+ if (this.code) {
50
+ return `${this.name} [${this.code}]: ${this.message}`;
51
+ }
52
+ return `${this.name}: ${this.message}`;
53
+ }
54
+ };
55
+ function createError(message, code, status) {
56
+ var _a2;
57
+ return _a2 = class extends exports.Exception {
58
+ constructor(args, options) {
59
+ super(node_util.format(message, ...args || []), options);
60
+ this.name = "Exception";
61
+ }
62
+ }, __publicField(_a2, "message", message), __publicField(_a2, "code", code), __publicField(_a2, "status", status), _a2;
63
+ }
64
+ exports.commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
65
+ function getDefaultExportFromCjs(x) {
66
+ return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
67
+ }
68
+ var secureJsonParse = { exports: {} };
69
+ secureJsonParse.exports;
70
+ const hasBuffer = typeof Buffer !== "undefined";
71
+ const suspectProtoRx = /"(?:_|\\u005[Ff])(?:_|\\u005[Ff])(?:p|\\u0070)(?:r|\\u0072)(?:o|\\u006[Ff])(?:t|\\u0074)(?:o|\\u006[Ff])(?:_|\\u005[Ff])(?:_|\\u005[Ff])"\s*:/;
72
+ const suspectConstructorRx = /"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/;
73
+ function _parse(text, reviver, options) {
74
+ if (options == null) {
75
+ if (reviver !== null && typeof reviver === "object") {
76
+ options = reviver;
77
+ reviver = void 0;
78
+ }
79
+ }
80
+ if (hasBuffer && Buffer.isBuffer(text)) {
81
+ text = text.toString();
82
+ }
83
+ if (text && text.charCodeAt(0) === 65279) {
84
+ text = text.slice(1);
85
+ }
86
+ const obj = JSON.parse(text, reviver);
87
+ if (obj === null || typeof obj !== "object") {
88
+ return obj;
89
+ }
90
+ const protoAction = options && options.protoAction || "error";
91
+ const constructorAction = options && options.constructorAction || "error";
92
+ if (protoAction === "ignore" && constructorAction === "ignore") {
93
+ return obj;
94
+ }
95
+ if (protoAction !== "ignore" && constructorAction !== "ignore") {
96
+ if (suspectProtoRx.test(text) === false && suspectConstructorRx.test(text) === false) {
97
+ return obj;
98
+ }
99
+ } else if (protoAction !== "ignore" && constructorAction === "ignore") {
100
+ if (suspectProtoRx.test(text) === false) {
101
+ return obj;
102
+ }
103
+ } else {
104
+ if (suspectConstructorRx.test(text) === false) {
105
+ return obj;
106
+ }
107
+ }
108
+ return filter(obj, { protoAction, constructorAction, safe: options && options.safe });
109
+ }
110
+ function filter(obj, { protoAction = "error", constructorAction = "error", safe } = {}) {
111
+ let next = [obj];
112
+ while (next.length) {
113
+ const nodes = next;
114
+ next = [];
115
+ for (const node of nodes) {
116
+ if (protoAction !== "ignore" && Object.prototype.hasOwnProperty.call(node, "__proto__")) {
117
+ if (safe === true) {
118
+ return null;
119
+ } else if (protoAction === "error") {
120
+ throw new SyntaxError("Object contains forbidden prototype property");
121
+ }
122
+ delete node.__proto__;
123
+ }
124
+ if (constructorAction !== "ignore" && Object.prototype.hasOwnProperty.call(node, "constructor") && Object.prototype.hasOwnProperty.call(node.constructor, "prototype")) {
125
+ if (safe === true) {
126
+ return null;
127
+ } else if (constructorAction === "error") {
128
+ throw new SyntaxError("Object contains forbidden prototype property");
129
+ }
130
+ delete node.constructor;
131
+ }
132
+ for (const key in node) {
133
+ const value = node[key];
134
+ if (value && typeof value === "object") {
135
+ next.push(value);
136
+ }
137
+ }
138
+ }
139
+ }
140
+ return obj;
141
+ }
142
+ function parse$2(text, reviver, options) {
143
+ const { stackTraceLimit } = Error;
144
+ Error.stackTraceLimit = 0;
145
+ try {
146
+ return _parse(text, reviver, options);
147
+ } finally {
148
+ Error.stackTraceLimit = stackTraceLimit;
149
+ }
150
+ }
151
+ function safeParse(text, reviver) {
152
+ const { stackTraceLimit } = Error;
153
+ Error.stackTraceLimit = 0;
154
+ try {
155
+ return _parse(text, reviver, { safe: true });
156
+ } catch {
157
+ return void 0;
158
+ } finally {
159
+ Error.stackTraceLimit = stackTraceLimit;
160
+ }
161
+ }
162
+ secureJsonParse.exports = parse$2;
163
+ secureJsonParse.exports.default = parse$2;
164
+ secureJsonParse.exports.parse = parse$2;
165
+ secureJsonParse.exports.safeParse = safeParse;
166
+ secureJsonParse.exports.scan = filter;
167
+ secureJsonParse.exports;
168
+ var safeStableStringify = { exports: {} };
169
+ safeStableStringify.exports;
170
+ (function(module2, exports2) {
171
+ const { hasOwnProperty } = Object.prototype;
172
+ const stringify = configure2();
173
+ stringify.configure = configure2;
174
+ stringify.stringify = stringify;
175
+ stringify.default = stringify;
176
+ exports2.stringify = stringify;
177
+ exports2.configure = configure2;
178
+ module2.exports = stringify;
179
+ const strEscapeSequencesRegExp = /[\u0000-\u001f\u0022\u005c\ud800-\udfff]/;
180
+ function strEscape(str) {
181
+ if (str.length < 5e3 && !strEscapeSequencesRegExp.test(str)) {
182
+ return `"${str}"`;
183
+ }
184
+ return JSON.stringify(str);
185
+ }
186
+ function sort(array, comparator) {
187
+ if (array.length > 200 || comparator) {
188
+ return array.sort(comparator);
189
+ }
190
+ for (let i = 1; i < array.length; i++) {
191
+ const currentValue = array[i];
192
+ let position = i;
193
+ while (position !== 0 && array[position - 1] > currentValue) {
194
+ array[position] = array[position - 1];
195
+ position--;
196
+ }
197
+ array[position] = currentValue;
198
+ }
199
+ return array;
200
+ }
201
+ const typedArrayPrototypeGetSymbolToStringTag = Object.getOwnPropertyDescriptor(
202
+ Object.getPrototypeOf(
203
+ Object.getPrototypeOf(
204
+ new Int8Array()
205
+ )
206
+ ),
207
+ Symbol.toStringTag
208
+ ).get;
209
+ function isTypedArrayWithEntries(value) {
210
+ return typedArrayPrototypeGetSymbolToStringTag.call(value) !== void 0 && value.length !== 0;
211
+ }
212
+ function stringifyTypedArray(array, separator, maximumBreadth) {
213
+ if (array.length < maximumBreadth) {
214
+ maximumBreadth = array.length;
215
+ }
216
+ const whitespace = separator === "," ? "" : " ";
217
+ let res = `"0":${whitespace}${array[0]}`;
218
+ for (let i = 1; i < maximumBreadth; i++) {
219
+ res += `${separator}"${i}":${whitespace}${array[i]}`;
220
+ }
221
+ return res;
222
+ }
223
+ function getCircularValueOption(options) {
224
+ if (hasOwnProperty.call(options, "circularValue")) {
225
+ const circularValue = options.circularValue;
226
+ if (typeof circularValue === "string") {
227
+ return `"${circularValue}"`;
228
+ }
229
+ if (circularValue == null) {
230
+ return circularValue;
231
+ }
232
+ if (circularValue === Error || circularValue === TypeError) {
233
+ return {
234
+ toString() {
235
+ throw new TypeError("Converting circular structure to JSON");
236
+ }
237
+ };
238
+ }
239
+ throw new TypeError('The "circularValue" argument must be of type string or the value null or undefined');
240
+ }
241
+ return '"[Circular]"';
242
+ }
243
+ function getDeterministicOption(options) {
244
+ let value;
245
+ if (hasOwnProperty.call(options, "deterministic")) {
246
+ value = options.deterministic;
247
+ if (typeof value !== "boolean" && typeof value !== "function") {
248
+ throw new TypeError('The "deterministic" argument must be of type boolean or comparator function');
249
+ }
250
+ }
251
+ return value === void 0 ? true : value;
252
+ }
253
+ function getBooleanOption(options, key) {
254
+ let value;
255
+ if (hasOwnProperty.call(options, key)) {
256
+ value = options[key];
257
+ if (typeof value !== "boolean") {
258
+ throw new TypeError(`The "${key}" argument must be of type boolean`);
259
+ }
260
+ }
261
+ return value === void 0 ? true : value;
262
+ }
263
+ function getPositiveIntegerOption(options, key) {
264
+ let value;
265
+ if (hasOwnProperty.call(options, key)) {
266
+ value = options[key];
267
+ if (typeof value !== "number") {
268
+ throw new TypeError(`The "${key}" argument must be of type number`);
269
+ }
270
+ if (!Number.isInteger(value)) {
271
+ throw new TypeError(`The "${key}" argument must be an integer`);
272
+ }
273
+ if (value < 1) {
274
+ throw new RangeError(`The "${key}" argument must be >= 1`);
275
+ }
276
+ }
277
+ return value === void 0 ? Infinity : value;
278
+ }
279
+ function getItemCount(number) {
280
+ if (number === 1) {
281
+ return "1 item";
282
+ }
283
+ return `${number} items`;
284
+ }
285
+ function getUniqueReplacerSet(replacerArray) {
286
+ const replacerSet = /* @__PURE__ */ new Set();
287
+ for (const value of replacerArray) {
288
+ if (typeof value === "string" || typeof value === "number") {
289
+ replacerSet.add(String(value));
290
+ }
291
+ }
292
+ return replacerSet;
293
+ }
294
+ function getStrictOption(options) {
295
+ if (hasOwnProperty.call(options, "strict")) {
296
+ const value = options.strict;
297
+ if (typeof value !== "boolean") {
298
+ throw new TypeError('The "strict" argument must be of type boolean');
299
+ }
300
+ if (value) {
301
+ return (value2) => {
302
+ let message = `Object can not safely be stringified. Received type ${typeof value2}`;
303
+ if (typeof value2 !== "function") message += ` (${value2.toString()})`;
304
+ throw new Error(message);
305
+ };
306
+ }
307
+ }
308
+ }
309
+ function configure2(options) {
310
+ options = { ...options };
311
+ const fail = getStrictOption(options);
312
+ if (fail) {
313
+ if (options.bigint === void 0) {
314
+ options.bigint = false;
315
+ }
316
+ if (!("circularValue" in options)) {
317
+ options.circularValue = Error;
318
+ }
319
+ }
320
+ const circularValue = getCircularValueOption(options);
321
+ const bigint = getBooleanOption(options, "bigint");
322
+ const deterministic = getDeterministicOption(options);
323
+ const comparator = typeof deterministic === "function" ? deterministic : void 0;
324
+ const maximumDepth = getPositiveIntegerOption(options, "maximumDepth");
325
+ const maximumBreadth = getPositiveIntegerOption(options, "maximumBreadth");
326
+ function stringifyFnReplacer(key, parent, stack, replacer, spacer, indentation) {
327
+ let value = parent[key];
328
+ if (typeof value === "object" && value !== null && typeof value.toJSON === "function") {
329
+ value = value.toJSON(key);
330
+ }
331
+ value = replacer.call(parent, key, value);
332
+ switch (typeof value) {
333
+ case "string":
334
+ return strEscape(value);
335
+ case "object": {
336
+ if (value === null) {
337
+ return "null";
338
+ }
339
+ if (stack.indexOf(value) !== -1) {
340
+ return circularValue;
341
+ }
342
+ let res = "";
343
+ let join = ",";
344
+ const originalIndentation = indentation;
345
+ if (Array.isArray(value)) {
346
+ if (value.length === 0) {
347
+ return "[]";
348
+ }
349
+ if (maximumDepth < stack.length + 1) {
350
+ return '"[Array]"';
351
+ }
352
+ stack.push(value);
353
+ if (spacer !== "") {
354
+ indentation += spacer;
355
+ res += `
356
+ ${indentation}`;
357
+ join = `,
358
+ ${indentation}`;
359
+ }
360
+ const maximumValuesToStringify = Math.min(value.length, maximumBreadth);
361
+ let i = 0;
362
+ for (; i < maximumValuesToStringify - 1; i++) {
363
+ const tmp2 = stringifyFnReplacer(String(i), value, stack, replacer, spacer, indentation);
364
+ res += tmp2 !== void 0 ? tmp2 : "null";
365
+ res += join;
366
+ }
367
+ const tmp = stringifyFnReplacer(String(i), value, stack, replacer, spacer, indentation);
368
+ res += tmp !== void 0 ? tmp : "null";
369
+ if (value.length - 1 > maximumBreadth) {
370
+ const removedKeys = value.length - maximumBreadth - 1;
371
+ res += `${join}"... ${getItemCount(removedKeys)} not stringified"`;
372
+ }
373
+ if (spacer !== "") {
374
+ res += `
375
+ ${originalIndentation}`;
376
+ }
377
+ stack.pop();
378
+ return `[${res}]`;
379
+ }
380
+ let keys = Object.keys(value);
381
+ const keyLength = keys.length;
382
+ if (keyLength === 0) {
383
+ return "{}";
384
+ }
385
+ if (maximumDepth < stack.length + 1) {
386
+ return '"[Object]"';
387
+ }
388
+ let whitespace = "";
389
+ let separator = "";
390
+ if (spacer !== "") {
391
+ indentation += spacer;
392
+ join = `,
393
+ ${indentation}`;
394
+ whitespace = " ";
395
+ }
396
+ const maximumPropertiesToStringify = Math.min(keyLength, maximumBreadth);
397
+ if (deterministic && !isTypedArrayWithEntries(value)) {
398
+ keys = sort(keys, comparator);
399
+ }
400
+ stack.push(value);
401
+ for (let i = 0; i < maximumPropertiesToStringify; i++) {
402
+ const key2 = keys[i];
403
+ const tmp = stringifyFnReplacer(key2, value, stack, replacer, spacer, indentation);
404
+ if (tmp !== void 0) {
405
+ res += `${separator}${strEscape(key2)}:${whitespace}${tmp}`;
406
+ separator = join;
407
+ }
408
+ }
409
+ if (keyLength > maximumBreadth) {
410
+ const removedKeys = keyLength - maximumBreadth;
411
+ res += `${separator}"...":${whitespace}"${getItemCount(removedKeys)} not stringified"`;
412
+ separator = join;
413
+ }
414
+ if (spacer !== "" && separator.length > 1) {
415
+ res = `
416
+ ${indentation}${res}
417
+ ${originalIndentation}`;
418
+ }
419
+ stack.pop();
420
+ return `{${res}}`;
421
+ }
422
+ case "number":
423
+ return isFinite(value) ? String(value) : fail ? fail(value) : "null";
424
+ case "boolean":
425
+ return value === true ? "true" : "false";
426
+ case "undefined":
427
+ return void 0;
428
+ case "bigint":
429
+ if (bigint) {
430
+ return String(value);
431
+ }
432
+ default:
433
+ return fail ? fail(value) : void 0;
434
+ }
435
+ }
436
+ function stringifyArrayReplacer(key, value, stack, replacer, spacer, indentation) {
437
+ if (typeof value === "object" && value !== null && typeof value.toJSON === "function") {
438
+ value = value.toJSON(key);
439
+ }
440
+ switch (typeof value) {
441
+ case "string":
442
+ return strEscape(value);
443
+ case "object": {
444
+ if (value === null) {
445
+ return "null";
446
+ }
447
+ if (stack.indexOf(value) !== -1) {
448
+ return circularValue;
449
+ }
450
+ const originalIndentation = indentation;
451
+ let res = "";
452
+ let join = ",";
453
+ if (Array.isArray(value)) {
454
+ if (value.length === 0) {
455
+ return "[]";
456
+ }
457
+ if (maximumDepth < stack.length + 1) {
458
+ return '"[Array]"';
459
+ }
460
+ stack.push(value);
461
+ if (spacer !== "") {
462
+ indentation += spacer;
463
+ res += `
464
+ ${indentation}`;
465
+ join = `,
466
+ ${indentation}`;
467
+ }
468
+ const maximumValuesToStringify = Math.min(value.length, maximumBreadth);
469
+ let i = 0;
470
+ for (; i < maximumValuesToStringify - 1; i++) {
471
+ const tmp2 = stringifyArrayReplacer(String(i), value[i], stack, replacer, spacer, indentation);
472
+ res += tmp2 !== void 0 ? tmp2 : "null";
473
+ res += join;
474
+ }
475
+ const tmp = stringifyArrayReplacer(String(i), value[i], stack, replacer, spacer, indentation);
476
+ res += tmp !== void 0 ? tmp : "null";
477
+ if (value.length - 1 > maximumBreadth) {
478
+ const removedKeys = value.length - maximumBreadth - 1;
479
+ res += `${join}"... ${getItemCount(removedKeys)} not stringified"`;
480
+ }
481
+ if (spacer !== "") {
482
+ res += `
483
+ ${originalIndentation}`;
484
+ }
485
+ stack.pop();
486
+ return `[${res}]`;
487
+ }
488
+ stack.push(value);
489
+ let whitespace = "";
490
+ if (spacer !== "") {
491
+ indentation += spacer;
492
+ join = `,
493
+ ${indentation}`;
494
+ whitespace = " ";
495
+ }
496
+ let separator = "";
497
+ for (const key2 of replacer) {
498
+ const tmp = stringifyArrayReplacer(key2, value[key2], stack, replacer, spacer, indentation);
499
+ if (tmp !== void 0) {
500
+ res += `${separator}${strEscape(key2)}:${whitespace}${tmp}`;
501
+ separator = join;
502
+ }
503
+ }
504
+ if (spacer !== "" && separator.length > 1) {
505
+ res = `
506
+ ${indentation}${res}
507
+ ${originalIndentation}`;
508
+ }
509
+ stack.pop();
510
+ return `{${res}}`;
511
+ }
512
+ case "number":
513
+ return isFinite(value) ? String(value) : fail ? fail(value) : "null";
514
+ case "boolean":
515
+ return value === true ? "true" : "false";
516
+ case "undefined":
517
+ return void 0;
518
+ case "bigint":
519
+ if (bigint) {
520
+ return String(value);
521
+ }
522
+ default:
523
+ return fail ? fail(value) : void 0;
524
+ }
525
+ }
526
+ function stringifyIndent(key, value, stack, spacer, indentation) {
527
+ switch (typeof value) {
528
+ case "string":
529
+ return strEscape(value);
530
+ case "object": {
531
+ if (value === null) {
532
+ return "null";
533
+ }
534
+ if (typeof value.toJSON === "function") {
535
+ value = value.toJSON(key);
536
+ if (typeof value !== "object") {
537
+ return stringifyIndent(key, value, stack, spacer, indentation);
538
+ }
539
+ if (value === null) {
540
+ return "null";
541
+ }
542
+ }
543
+ if (stack.indexOf(value) !== -1) {
544
+ return circularValue;
545
+ }
546
+ const originalIndentation = indentation;
547
+ if (Array.isArray(value)) {
548
+ if (value.length === 0) {
549
+ return "[]";
550
+ }
551
+ if (maximumDepth < stack.length + 1) {
552
+ return '"[Array]"';
553
+ }
554
+ stack.push(value);
555
+ indentation += spacer;
556
+ let res2 = `
557
+ ${indentation}`;
558
+ const join2 = `,
559
+ ${indentation}`;
560
+ const maximumValuesToStringify = Math.min(value.length, maximumBreadth);
561
+ let i = 0;
562
+ for (; i < maximumValuesToStringify - 1; i++) {
563
+ const tmp2 = stringifyIndent(String(i), value[i], stack, spacer, indentation);
564
+ res2 += tmp2 !== void 0 ? tmp2 : "null";
565
+ res2 += join2;
566
+ }
567
+ const tmp = stringifyIndent(String(i), value[i], stack, spacer, indentation);
568
+ res2 += tmp !== void 0 ? tmp : "null";
569
+ if (value.length - 1 > maximumBreadth) {
570
+ const removedKeys = value.length - maximumBreadth - 1;
571
+ res2 += `${join2}"... ${getItemCount(removedKeys)} not stringified"`;
572
+ }
573
+ res2 += `
574
+ ${originalIndentation}`;
575
+ stack.pop();
576
+ return `[${res2}]`;
577
+ }
578
+ let keys = Object.keys(value);
579
+ const keyLength = keys.length;
580
+ if (keyLength === 0) {
581
+ return "{}";
582
+ }
583
+ if (maximumDepth < stack.length + 1) {
584
+ return '"[Object]"';
585
+ }
586
+ indentation += spacer;
587
+ const join = `,
588
+ ${indentation}`;
589
+ let res = "";
590
+ let separator = "";
591
+ let maximumPropertiesToStringify = Math.min(keyLength, maximumBreadth);
592
+ if (isTypedArrayWithEntries(value)) {
593
+ res += stringifyTypedArray(value, join, maximumBreadth);
594
+ keys = keys.slice(value.length);
595
+ maximumPropertiesToStringify -= value.length;
596
+ separator = join;
597
+ }
598
+ if (deterministic) {
599
+ keys = sort(keys, comparator);
600
+ }
601
+ stack.push(value);
602
+ for (let i = 0; i < maximumPropertiesToStringify; i++) {
603
+ const key2 = keys[i];
604
+ const tmp = stringifyIndent(key2, value[key2], stack, spacer, indentation);
605
+ if (tmp !== void 0) {
606
+ res += `${separator}${strEscape(key2)}: ${tmp}`;
607
+ separator = join;
608
+ }
609
+ }
610
+ if (keyLength > maximumBreadth) {
611
+ const removedKeys = keyLength - maximumBreadth;
612
+ res += `${separator}"...": "${getItemCount(removedKeys)} not stringified"`;
613
+ separator = join;
614
+ }
615
+ if (separator !== "") {
616
+ res = `
617
+ ${indentation}${res}
618
+ ${originalIndentation}`;
619
+ }
620
+ stack.pop();
621
+ return `{${res}}`;
622
+ }
623
+ case "number":
624
+ return isFinite(value) ? String(value) : fail ? fail(value) : "null";
625
+ case "boolean":
626
+ return value === true ? "true" : "false";
627
+ case "undefined":
628
+ return void 0;
629
+ case "bigint":
630
+ if (bigint) {
631
+ return String(value);
632
+ }
633
+ default:
634
+ return fail ? fail(value) : void 0;
635
+ }
636
+ }
637
+ function stringifySimple(key, value, stack) {
638
+ switch (typeof value) {
639
+ case "string":
640
+ return strEscape(value);
641
+ case "object": {
642
+ if (value === null) {
643
+ return "null";
644
+ }
645
+ if (typeof value.toJSON === "function") {
646
+ value = value.toJSON(key);
647
+ if (typeof value !== "object") {
648
+ return stringifySimple(key, value, stack);
649
+ }
650
+ if (value === null) {
651
+ return "null";
652
+ }
653
+ }
654
+ if (stack.indexOf(value) !== -1) {
655
+ return circularValue;
656
+ }
657
+ let res = "";
658
+ const hasLength = value.length !== void 0;
659
+ if (hasLength && Array.isArray(value)) {
660
+ if (value.length === 0) {
661
+ return "[]";
662
+ }
663
+ if (maximumDepth < stack.length + 1) {
664
+ return '"[Array]"';
665
+ }
666
+ stack.push(value);
667
+ const maximumValuesToStringify = Math.min(value.length, maximumBreadth);
668
+ let i = 0;
669
+ for (; i < maximumValuesToStringify - 1; i++) {
670
+ const tmp2 = stringifySimple(String(i), value[i], stack);
671
+ res += tmp2 !== void 0 ? tmp2 : "null";
672
+ res += ",";
673
+ }
674
+ const tmp = stringifySimple(String(i), value[i], stack);
675
+ res += tmp !== void 0 ? tmp : "null";
676
+ if (value.length - 1 > maximumBreadth) {
677
+ const removedKeys = value.length - maximumBreadth - 1;
678
+ res += `,"... ${getItemCount(removedKeys)} not stringified"`;
679
+ }
680
+ stack.pop();
681
+ return `[${res}]`;
682
+ }
683
+ let keys = Object.keys(value);
684
+ const keyLength = keys.length;
685
+ if (keyLength === 0) {
686
+ return "{}";
687
+ }
688
+ if (maximumDepth < stack.length + 1) {
689
+ return '"[Object]"';
690
+ }
691
+ let separator = "";
692
+ let maximumPropertiesToStringify = Math.min(keyLength, maximumBreadth);
693
+ if (hasLength && isTypedArrayWithEntries(value)) {
694
+ res += stringifyTypedArray(value, ",", maximumBreadth);
695
+ keys = keys.slice(value.length);
696
+ maximumPropertiesToStringify -= value.length;
697
+ separator = ",";
698
+ }
699
+ if (deterministic) {
700
+ keys = sort(keys, comparator);
701
+ }
702
+ stack.push(value);
703
+ for (let i = 0; i < maximumPropertiesToStringify; i++) {
704
+ const key2 = keys[i];
705
+ const tmp = stringifySimple(key2, value[key2], stack);
706
+ if (tmp !== void 0) {
707
+ res += `${separator}${strEscape(key2)}:${tmp}`;
708
+ separator = ",";
709
+ }
710
+ }
711
+ if (keyLength > maximumBreadth) {
712
+ const removedKeys = keyLength - maximumBreadth;
713
+ res += `${separator}"...":"${getItemCount(removedKeys)} not stringified"`;
714
+ }
715
+ stack.pop();
716
+ return `{${res}}`;
717
+ }
718
+ case "number":
719
+ return isFinite(value) ? String(value) : fail ? fail(value) : "null";
720
+ case "boolean":
721
+ return value === true ? "true" : "false";
722
+ case "undefined":
723
+ return void 0;
724
+ case "bigint":
725
+ if (bigint) {
726
+ return String(value);
727
+ }
728
+ default:
729
+ return fail ? fail(value) : void 0;
730
+ }
731
+ }
732
+ function stringify2(value, replacer, space) {
733
+ if (arguments.length > 1) {
734
+ let spacer = "";
735
+ if (typeof space === "number") {
736
+ spacer = " ".repeat(Math.min(space, 10));
737
+ } else if (typeof space === "string") {
738
+ spacer = space.slice(0, 10);
739
+ }
740
+ if (replacer != null) {
741
+ if (typeof replacer === "function") {
742
+ return stringifyFnReplacer("", { "": value }, [], replacer, spacer, "");
743
+ }
744
+ if (Array.isArray(replacer)) {
745
+ return stringifyArrayReplacer("", value, [], getUniqueReplacerSet(replacer), spacer, "");
746
+ }
747
+ }
748
+ if (spacer.length !== 0) {
749
+ return stringifyIndent("", value, [], spacer, "");
750
+ }
751
+ }
752
+ return stringifySimple("", value, []);
753
+ }
754
+ return stringify2;
755
+ }
756
+ })(safeStableStringify, safeStableStringify.exports);
757
+ var safeStableStringifyExports = safeStableStringify.exports;
758
+ const cjsModule = /* @__PURE__ */ getDefaultExportFromCjs(safeStableStringifyExports);
759
+ const configure = cjsModule.configure;
760
+ configure({
761
+ bigint: false,
762
+ circularValue: void 0,
763
+ deterministic: false
764
+ });
765
+ var __defProp2 = Object.defineProperty;
766
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
767
+ var __getOwnPropNames = Object.getOwnPropertyNames;
768
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
769
+ var __copyProps = (to, from, except, desc) => {
770
+ if (from && typeof from === "object" || typeof from === "function") {
771
+ for (let key of __getOwnPropNames(from))
772
+ if (!__hasOwnProp.call(to, key) && key !== except)
773
+ __defProp2(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
774
+ }
775
+ return to;
776
+ };
777
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
778
+ var main = { exports: {} };
779
+ /**
780
+ * @license
781
+ * Lodash (Custom Build) lodash.com/license | Underscore.js 1.8.3 underscorejs.org/LICENSE
782
+ * Build: `lodash include="pick,omit,has,get,set,unset,mergeWith,merge,size,clone,cloneWith,cloneDeep,cloneDeepWith,toPath" --production`
783
+ */
784
+ main.exports;
785
+ (function(module2, exports$1) {
786
+ (function() {
787
+ function t(t2, e2, n2) {
788
+ switch (n2.length) {
789
+ case 0:
790
+ return t2.call(e2);
791
+ case 1:
792
+ return t2.call(e2, n2[0]);
793
+ case 2:
794
+ return t2.call(e2, n2[0], n2[1]);
795
+ case 3:
796
+ return t2.call(e2, n2[0], n2[1], n2[2]);
797
+ }
798
+ return t2.apply(e2, n2);
799
+ }
800
+ function e(t2, e2) {
801
+ for (var n2 = -1, r2 = null == t2 ? 0 : t2.length; ++n2 < r2 && false !== e2(t2[n2], n2, t2); ) ;
802
+ }
803
+ function n(t2, e2) {
804
+ for (var n2 = -1, r2 = null == t2 ? 0 : t2.length, u2 = 0, o2 = []; ++n2 < r2; ) {
805
+ var c2 = t2[n2];
806
+ e2(c2, n2, t2) && (o2[u2++] = c2);
807
+ }
808
+ return o2;
809
+ }
810
+ function r(t2, e2) {
811
+ for (var n2 = -1, r2 = null == t2 ? 0 : t2.length, u2 = Array(r2); ++n2 < r2; ) u2[n2] = e2(t2[n2], n2, t2);
812
+ return u2;
813
+ }
814
+ function u(t2, e2) {
815
+ for (var n2 = -1, r2 = e2.length, u2 = t2.length; ++n2 < r2; ) t2[u2 + n2] = e2[n2];
816
+ return t2;
817
+ }
818
+ function o(t2) {
819
+ return function(e2) {
820
+ return t2(e2);
821
+ };
822
+ }
823
+ function c(t2) {
824
+ var e2 = Object;
825
+ return function(n2) {
826
+ return t2(e2(n2));
827
+ };
828
+ }
829
+ function i() {
830
+ }
831
+ function f(t2) {
832
+ var e2 = -1, n2 = null == t2 ? 0 : t2.length;
833
+ for (this.clear(); ++e2 < n2; ) {
834
+ var r2 = t2[e2];
835
+ this.set(r2[0], r2[1]);
836
+ }
837
+ }
838
+ function a(t2) {
839
+ var e2 = -1, n2 = null == t2 ? 0 : t2.length;
840
+ for (this.clear(); ++e2 < n2; ) {
841
+ var r2 = t2[e2];
842
+ this.set(r2[0], r2[1]);
843
+ }
844
+ }
845
+ function l(t2) {
846
+ var e2 = -1, n2 = null == t2 ? 0 : t2.length;
847
+ for (this.clear(); ++e2 < n2; ) {
848
+ var r2 = t2[e2];
849
+ this.set(r2[0], r2[1]);
850
+ }
851
+ }
852
+ function s(t2) {
853
+ this.size = (this.__data__ = new a(t2)).size;
854
+ }
855
+ function b(t2, e2) {
856
+ var n2 = Ye(t2), r2 = !n2 && Xe(t2), u2 = !n2 && !r2 && Ze(t2), o2 = !n2 && !r2 && !u2 && nn(t2);
857
+ if (n2 = n2 || r2 || u2 || o2) {
858
+ for (var r2 = t2.length, c2 = String, i2 = -1, f2 = Array(r2); ++i2 < r2; ) f2[i2] = c2(i2);
859
+ r2 = f2;
860
+ } else r2 = [];
861
+ var a2, c2 = r2.length;
862
+ for (a2 in t2) !e2 && !fe.call(t2, a2) || n2 && ("length" == a2 || u2 && ("offset" == a2 || "parent" == a2) || o2 && ("buffer" == a2 || "byteLength" == a2 || "byteOffset" == a2) || ut(a2, c2)) || r2.push(a2);
863
+ return r2;
864
+ }
865
+ function p(t2, e2, n2) {
866
+ (n2 === Mt || bt(t2[e2], n2)) && (n2 !== Mt || e2 in t2) || d(t2, e2, n2);
867
+ }
868
+ function h(t2, e2, n2) {
869
+ var r2 = t2[e2];
870
+ fe.call(t2, e2) && bt(r2, n2) && (n2 !== Mt || e2 in t2) || d(t2, e2, n2);
871
+ }
872
+ function y(t2, e2) {
873
+ for (var n2 = t2.length; n2--; ) if (bt(t2[n2][0], e2)) return n2;
874
+ return -1;
875
+ }
876
+ function j(t2, e2) {
877
+ return t2 && V(e2, St(e2), t2);
878
+ }
879
+ function _(t2, e2) {
880
+ return t2 && V(e2, zt(e2), t2);
881
+ }
882
+ function d(t2, e2, n2) {
883
+ "__proto__" == e2 && we ? we(t2, e2, { configurable: true, enumerable: true, value: n2, writable: true }) : t2[e2] = n2;
884
+ }
885
+ function g(t2, n2, r2, u2, o2, c2) {
886
+ var i2, f2 = 1 & n2, a2 = 2 & n2, l2 = 4 & n2;
887
+ if (r2 && (i2 = o2 ? r2(t2, u2, o2, c2) : r2(t2)), i2 !== Mt) return i2;
888
+ if (!_t(t2)) return t2;
889
+ if (u2 = Ye(t2)) {
890
+ if (i2 = tt(t2), !f2) return T(t2, i2);
891
+ } else {
892
+ var b2 = Je(t2), p2 = "[object Function]" == b2 || "[object GeneratorFunction]" == b2;
893
+ if (Ze(t2)) return R(t2, f2);
894
+ if ("[object Object]" == b2 || "[object Arguments]" == b2 || p2 && !o2) {
895
+ if (i2 = a2 || p2 ? {} : et(t2), !f2) return a2 ? G(t2, _(i2, t2)) : N(t2, j(i2, t2));
896
+ } else {
897
+ if (!Gt[b2]) return o2 ? t2 : {};
898
+ i2 = nt(t2, b2, f2);
899
+ }
900
+ }
901
+ if (c2 || (c2 = new s()), o2 = c2.get(t2)) return o2;
902
+ if (c2.set(t2, i2), en(t2)) return t2.forEach(function(e2) {
903
+ i2.add(g(e2, n2, r2, e2, t2, c2));
904
+ }), i2;
905
+ if (tn(t2)) return t2.forEach(function(e2, u3) {
906
+ i2.set(u3, g(e2, n2, r2, u3, t2, c2));
907
+ }), i2;
908
+ var a2 = l2 ? a2 ? Q : K : a2 ? zt : St, y2 = u2 ? Mt : a2(t2);
909
+ return e(y2 || t2, function(e2, u3) {
910
+ y2 && (u3 = e2, e2 = t2[u3]), h(i2, u3, g(e2, n2, r2, u3, t2, c2));
911
+ }), i2;
912
+ }
913
+ function v(t2, e2, n2, r2, o2) {
914
+ var c2 = -1, i2 = t2.length;
915
+ for (n2 || (n2 = rt), o2 || (o2 = []); ++c2 < i2; ) {
916
+ var f2 = t2[c2];
917
+ n2(f2) ? u(o2, f2) : o2[o2.length] = f2;
918
+ }
919
+ return o2;
920
+ }
921
+ function A(t2, e2) {
922
+ e2 = C(e2, t2);
923
+ for (var n2 = 0, r2 = e2.length; null != t2 && n2 < r2; ) t2 = t2[it(e2[n2++])];
924
+ return n2 && n2 == r2 ? t2 : Mt;
925
+ }
926
+ function m(t2, e2, n2) {
927
+ return e2 = e2(t2), Ye(t2) ? e2 : u(e2, n2(t2));
928
+ }
929
+ function w(t2) {
930
+ if (null == t2) t2 = t2 === Mt ? "[object Undefined]" : "[object Null]";
931
+ else if (me && me in Object(t2)) {
932
+ var e2 = fe.call(t2, me), n2 = t2[me];
933
+ try {
934
+ t2[me] = Mt;
935
+ var r2 = true;
936
+ } catch (t3) {
937
+ }
938
+ var u2 = le.call(t2);
939
+ r2 && (e2 ? t2[me] = n2 : delete t2[me]), t2 = u2;
940
+ } else t2 = le.call(t2);
941
+ return t2;
942
+ }
943
+ function O(t2, e2) {
944
+ return null != t2 && fe.call(t2, e2);
945
+ }
946
+ function S(t2, e2) {
947
+ return null != t2 && e2 in Object(t2);
948
+ }
949
+ function z(t2) {
950
+ return dt(t2) && "[object Arguments]" == w(t2);
951
+ }
952
+ function x(t2) {
953
+ return dt(t2) && "[object Map]" == Je(t2);
954
+ }
955
+ function k(t2) {
956
+ return dt(t2) && "[object Set]" == Je(t2);
957
+ }
958
+ function F(t2) {
959
+ return dt(t2) && jt(t2.length) && !!Nt[w(t2)];
960
+ }
961
+ function I(t2) {
962
+ if (!ot(t2)) return ze(t2);
963
+ var e2, n2 = [];
964
+ for (e2 in Object(t2)) fe.call(t2, e2) && "constructor" != e2 && n2.push(e2);
965
+ return n2;
966
+ }
967
+ function M(t2, e2, n2, r2, u2) {
968
+ t2 !== e2 && Ne(e2, function(o2, c2) {
969
+ if (_t(o2)) {
970
+ u2 || (u2 = new s());
971
+ var i2 = u2, f2 = "__proto__" == c2 ? Mt : t2[c2], a2 = "__proto__" == c2 ? Mt : e2[c2], l2 = i2.get(a2);
972
+ if (l2) p(t2, c2, l2);
973
+ else {
974
+ var l2 = r2 ? r2(f2, a2, c2 + "", t2, e2, i2) : Mt, b2 = l2 === Mt;
975
+ if (b2) {
976
+ var h2 = Ye(a2), y2 = !h2 && Ze(a2), j2 = !h2 && !y2 && nn(a2), l2 = a2;
977
+ h2 || y2 || j2 ? Ye(f2) ? l2 = f2 : ht(f2) ? l2 = T(f2) : y2 ? (b2 = false, l2 = R(a2, true)) : j2 ? (b2 = false, l2 = L(a2, true)) : l2 = [] : gt(a2) || Xe(a2) ? (l2 = f2, Xe(f2) ? l2 = mt(f2) : (!_t(f2) || n2 && yt(f2)) && (l2 = et(a2))) : b2 = false;
978
+ }
979
+ b2 && (i2.set(a2, l2), M(l2, a2, n2, r2, i2), i2.delete(a2)), p(t2, c2, l2);
980
+ }
981
+ } else i2 = r2 ? r2("__proto__" == c2 ? Mt : t2[c2], o2, c2 + "", t2, e2, u2) : Mt, i2 === Mt && (i2 = o2), p(t2, c2, i2);
982
+ }, zt);
983
+ }
984
+ function E(t2, e2) {
985
+ return U(t2, e2, function(e3, n2) {
986
+ return Ot(t2, n2);
987
+ });
988
+ }
989
+ function U(t2, e2, n2) {
990
+ for (var r2 = -1, u2 = e2.length, o2 = {}; ++r2 < u2; ) {
991
+ var c2 = e2[r2], i2 = A(t2, c2);
992
+ n2(i2, c2) && D(o2, C(c2, t2), i2);
993
+ }
994
+ return o2;
995
+ }
996
+ function P(t2) {
997
+ return Ke(ct(t2, void 0, kt), t2 + "");
998
+ }
999
+ function D(t2, e2, n2) {
1000
+ if (!_t(t2)) return t2;
1001
+ e2 = C(e2, t2);
1002
+ for (var r2 = -1, u2 = e2.length, o2 = u2 - 1, c2 = t2; null != c2 && ++r2 < u2; ) {
1003
+ var i2 = it(e2[r2]), f2 = n2;
1004
+ if (r2 != o2) {
1005
+ var a2 = c2[i2], f2 = Mt;
1006
+ f2 === Mt && (f2 = _t(a2) ? a2 : ut(e2[r2 + 1]) ? [] : {});
1007
+ }
1008
+ h(c2, i2, f2), c2 = c2[i2];
1009
+ }
1010
+ return t2;
1011
+ }
1012
+ function $(t2) {
1013
+ if (typeof t2 == "string") return t2;
1014
+ if (Ye(t2)) return r(t2, $) + "";
1015
+ if (At(t2)) return Te ? Te.call(t2) : "";
1016
+ var e2 = t2 + "";
1017
+ return "0" == e2 && 1 / t2 == -Et ? "-0" : e2;
1018
+ }
1019
+ function B(t2, e2) {
1020
+ e2 = C(e2, t2);
1021
+ var n2;
1022
+ if (2 > e2.length) n2 = t2;
1023
+ else {
1024
+ n2 = e2;
1025
+ var r2 = 0, u2 = -1, o2 = -1, c2 = n2.length;
1026
+ for (0 > r2 && (r2 = -r2 > c2 ? 0 : c2 + r2), u2 = u2 > c2 ? c2 : u2, 0 > u2 && (u2 += c2), c2 = r2 > u2 ? 0 : u2 - r2 >>> 0, r2 >>>= 0, u2 = Array(c2); ++o2 < c2; ) u2[o2] = n2[o2 + r2];
1027
+ n2 = A(t2, u2);
1028
+ }
1029
+ return t2 = n2, null == t2 || delete t2[it(lt(e2))];
1030
+ }
1031
+ function C(t2, e2) {
1032
+ var n2;
1033
+ return Ye(t2) ? n2 = t2 : (Ye(t2) ? n2 = false : (n2 = typeof t2, n2 = !("number" != n2 && "symbol" != n2 && "boolean" != n2 && null != t2 && !At(t2)) || (Pt.test(t2) || !Ut.test(t2) || null != e2 && t2 in Object(e2))), n2 = n2 ? [t2] : Qe(wt(t2))), n2;
1034
+ }
1035
+ function R(t2, e2) {
1036
+ if (e2) return t2.slice();
1037
+ var n2 = t2.length, n2 = je ? je(n2) : new t2.constructor(n2);
1038
+ return t2.copy(n2), n2;
1039
+ }
1040
+ function W(t2) {
1041
+ var e2 = new t2.constructor(t2.byteLength);
1042
+ return new ye(e2).set(new ye(t2)), e2;
1043
+ }
1044
+ function L(t2, e2) {
1045
+ return new t2.constructor(e2 ? W(t2.buffer) : t2.buffer, t2.byteOffset, t2.length);
1046
+ }
1047
+ function T(t2, e2) {
1048
+ var n2 = -1, r2 = t2.length;
1049
+ for (e2 || (e2 = Array(r2)); ++n2 < r2; ) e2[n2] = t2[n2];
1050
+ return e2;
1051
+ }
1052
+ function V(t2, e2, n2) {
1053
+ var r2 = !n2;
1054
+ n2 || (n2 = {});
1055
+ for (var u2 = -1, o2 = e2.length; ++u2 < o2; ) {
1056
+ var c2 = e2[u2], i2 = Mt;
1057
+ i2 === Mt && (i2 = t2[c2]), r2 ? d(n2, c2, i2) : h(n2, c2, i2);
1058
+ }
1059
+ return n2;
1060
+ }
1061
+ function N(t2, e2) {
1062
+ return V(t2, qe(t2), e2);
1063
+ }
1064
+ function G(t2, e2) {
1065
+ return V(t2, He(t2), e2);
1066
+ }
1067
+ function q(t2) {
1068
+ return P(function(e2, n2) {
1069
+ var r2, u2 = -1, o2 = n2.length, c2 = 1 < o2 ? n2[o2 - 1] : Mt, i2 = 2 < o2 ? n2[2] : Mt, c2 = 3 < t2.length && typeof c2 == "function" ? (o2--, c2) : Mt;
1070
+ if (r2 = i2) {
1071
+ r2 = n2[0];
1072
+ var f2 = n2[1];
1073
+ if (_t(i2)) {
1074
+ var a2 = typeof f2;
1075
+ r2 = !!("number" == a2 ? pt(i2) && ut(f2, i2.length) : "string" == a2 && f2 in i2) && bt(i2[f2], r2);
1076
+ } else r2 = false;
1077
+ }
1078
+ for (r2 && (c2 = 3 > o2 ? Mt : c2, o2 = 1), e2 = Object(e2); ++u2 < o2; ) (i2 = n2[u2]) && t2(e2, i2, u2, c2);
1079
+ return e2;
1080
+ });
1081
+ }
1082
+ function H(t2) {
1083
+ return gt(t2) ? Mt : t2;
1084
+ }
1085
+ function J(t2) {
1086
+ return Ke(ct(t2, Mt, at), t2 + "");
1087
+ }
1088
+ function K(t2) {
1089
+ return m(t2, St, qe);
1090
+ }
1091
+ function Q(t2) {
1092
+ return m(t2, zt, He);
1093
+ }
1094
+ function X(t2, e2) {
1095
+ var n2 = t2.__data__, r2 = typeof e2;
1096
+ return ("string" == r2 || "number" == r2 || "symbol" == r2 || "boolean" == r2 ? "__proto__" !== e2 : null === e2) ? n2[typeof e2 == "string" ? "string" : "hash"] : n2.map;
1097
+ }
1098
+ function Y(t2, e2) {
1099
+ var n2 = null == t2 ? Mt : t2[e2];
1100
+ return (!_t(n2) || ae && ae in n2 ? 0 : (yt(n2) ? be : Ct).test(ft(n2))) ? n2 : Mt;
1101
+ }
1102
+ function Z(t2, e2, n2) {
1103
+ e2 = C(e2, t2);
1104
+ for (var r2 = -1, u2 = e2.length, o2 = false; ++r2 < u2; ) {
1105
+ var c2 = it(e2[r2]);
1106
+ if (!(o2 = null != t2 && n2(t2, c2))) break;
1107
+ t2 = t2[c2];
1108
+ }
1109
+ return o2 || ++r2 != u2 ? o2 : (u2 = null == t2 ? 0 : t2.length, !!u2 && jt(u2) && ut(c2, u2) && (Ye(t2) || Xe(t2)));
1110
+ }
1111
+ function tt(t2) {
1112
+ var e2 = t2.length, n2 = new t2.constructor(e2);
1113
+ return e2 && "string" == typeof t2[0] && fe.call(t2, "index") && (n2.index = t2.index, n2.input = t2.input), n2;
1114
+ }
1115
+ function et(t2) {
1116
+ return typeof t2.constructor != "function" || ot(t2) ? {} : Ve(_e(t2));
1117
+ }
1118
+ function nt(t2, e2, n2) {
1119
+ var r2 = t2.constructor;
1120
+ switch (e2) {
1121
+ case "[object ArrayBuffer]":
1122
+ return W(t2);
1123
+ case "[object Boolean]":
1124
+ case "[object Date]":
1125
+ return new r2(+t2);
1126
+ case "[object DataView]":
1127
+ return e2 = n2 ? W(t2.buffer) : t2.buffer, new t2.constructor(e2, t2.byteOffset, t2.byteLength);
1128
+ case "[object Float32Array]":
1129
+ case "[object Float64Array]":
1130
+ case "[object Int8Array]":
1131
+ case "[object Int16Array]":
1132
+ case "[object Int32Array]":
1133
+ case "[object Uint8Array]":
1134
+ case "[object Uint8ClampedArray]":
1135
+ case "[object Uint16Array]":
1136
+ case "[object Uint32Array]":
1137
+ return L(t2, n2);
1138
+ case "[object Map]":
1139
+ return new r2();
1140
+ case "[object Number]":
1141
+ case "[object String]":
1142
+ return new r2(t2);
1143
+ case "[object RegExp]":
1144
+ return e2 = new t2.constructor(t2.source, Bt.exec(t2)), e2.lastIndex = t2.lastIndex, e2;
1145
+ case "[object Set]":
1146
+ return new r2();
1147
+ case "[object Symbol]":
1148
+ return Le ? Object(Le.call(t2)) : {};
1149
+ }
1150
+ }
1151
+ function rt(t2) {
1152
+ return Ye(t2) || Xe(t2) || !!(Ae && t2 && t2[Ae]);
1153
+ }
1154
+ function ut(t2, e2) {
1155
+ var n2 = typeof t2;
1156
+ return e2 = null == e2 ? 9007199254740991 : e2, !!e2 && ("number" == n2 || "symbol" != n2 && Rt.test(t2)) && -1 < t2 && 0 == t2 % 1 && t2 < e2;
1157
+ }
1158
+ function ot(t2) {
1159
+ var e2 = t2 && t2.constructor;
1160
+ return t2 === (typeof e2 == "function" && e2.prototype || oe);
1161
+ }
1162
+ function ct(e2, n2, r2) {
1163
+ return n2 = xe(n2 === Mt ? e2.length - 1 : n2, 0), function() {
1164
+ for (var u2 = arguments, o2 = -1, c2 = xe(u2.length - n2, 0), i2 = Array(c2); ++o2 < c2; ) i2[o2] = u2[n2 + o2];
1165
+ for (o2 = -1, c2 = Array(n2 + 1); ++o2 < n2; ) c2[o2] = u2[o2];
1166
+ return c2[n2] = r2(i2), t(e2, this, c2);
1167
+ };
1168
+ }
1169
+ function it(t2) {
1170
+ if (typeof t2 == "string" || At(t2)) return t2;
1171
+ var e2 = t2 + "";
1172
+ return "0" == e2 && 1 / t2 == -Et ? "-0" : e2;
1173
+ }
1174
+ function ft(t2) {
1175
+ if (null != t2) {
1176
+ try {
1177
+ return ie.call(t2);
1178
+ } catch (t3) {
1179
+ }
1180
+ return t2 + "";
1181
+ }
1182
+ return "";
1183
+ }
1184
+ function at(t2) {
1185
+ return (null == t2 ? 0 : t2.length) ? v(t2) : [];
1186
+ }
1187
+ function lt(t2) {
1188
+ var e2 = null == t2 ? 0 : t2.length;
1189
+ return e2 ? t2[e2 - 1] : Mt;
1190
+ }
1191
+ function st(t2, e2) {
1192
+ function n2() {
1193
+ var r2 = arguments, u2 = e2 ? e2.apply(this, r2) : r2[0], o2 = n2.cache;
1194
+ return o2.has(u2) ? o2.get(u2) : (r2 = t2.apply(this, r2), n2.cache = o2.set(u2, r2) || o2, r2);
1195
+ }
1196
+ if (typeof t2 != "function" || null != e2 && typeof e2 != "function") throw new TypeError("Expected a function");
1197
+ return n2.cache = new (st.Cache || l)(), n2;
1198
+ }
1199
+ function bt(t2, e2) {
1200
+ return t2 === e2 || t2 !== t2 && e2 !== e2;
1201
+ }
1202
+ function pt(t2) {
1203
+ return null != t2 && jt(t2.length) && !yt(t2);
1204
+ }
1205
+ function ht(t2) {
1206
+ return dt(t2) && pt(t2);
1207
+ }
1208
+ function yt(t2) {
1209
+ return !!_t(t2) && (t2 = w(t2), "[object Function]" == t2 || "[object GeneratorFunction]" == t2 || "[object AsyncFunction]" == t2 || "[object Proxy]" == t2);
1210
+ }
1211
+ function jt(t2) {
1212
+ return typeof t2 == "number" && -1 < t2 && 0 == t2 % 1 && 9007199254740991 >= t2;
1213
+ }
1214
+ function _t(t2) {
1215
+ var e2 = typeof t2;
1216
+ return null != t2 && ("object" == e2 || "function" == e2);
1217
+ }
1218
+ function dt(t2) {
1219
+ return null != t2 && typeof t2 == "object";
1220
+ }
1221
+ function gt(t2) {
1222
+ return !(!dt(t2) || "[object Object]" != w(t2)) && (t2 = _e(t2), null === t2 || (t2 = fe.call(t2, "constructor") && t2.constructor, typeof t2 == "function" && t2 instanceof t2 && ie.call(t2) == se));
1223
+ }
1224
+ function vt(t2) {
1225
+ return typeof t2 == "string" || !Ye(t2) && dt(t2) && "[object String]" == w(t2);
1226
+ }
1227
+ function At(t2) {
1228
+ return typeof t2 == "symbol" || dt(t2) && "[object Symbol]" == w(t2);
1229
+ }
1230
+ function mt(t2) {
1231
+ return V(t2, zt(t2));
1232
+ }
1233
+ function wt(t2) {
1234
+ return null == t2 ? "" : $(t2);
1235
+ }
1236
+ function Ot(t2, e2) {
1237
+ return null != t2 && Z(t2, e2, S);
1238
+ }
1239
+ function St(t2) {
1240
+ return pt(t2) ? b(t2) : I(t2);
1241
+ }
1242
+ function zt(t2) {
1243
+ if (pt(t2)) t2 = b(t2, true);
1244
+ else if (_t(t2)) {
1245
+ var e2, n2 = ot(t2), r2 = [];
1246
+ for (e2 in t2) ("constructor" != e2 || !n2 && fe.call(t2, e2)) && r2.push(e2);
1247
+ t2 = r2;
1248
+ } else {
1249
+ if (e2 = [], null != t2) for (n2 in Object(t2)) e2.push(n2);
1250
+ t2 = e2;
1251
+ }
1252
+ return t2;
1253
+ }
1254
+ function xt(t2) {
1255
+ return function() {
1256
+ return t2;
1257
+ };
1258
+ }
1259
+ function kt(t2) {
1260
+ return t2;
1261
+ }
1262
+ function Ft() {
1263
+ return [];
1264
+ }
1265
+ function It() {
1266
+ return false;
1267
+ }
1268
+ var Mt, Et = 1 / 0, Ut = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, Pt = /^\w*$/, Dt = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, $t = /\\(\\)?/g, Bt = /\w*$/, Ct = /^\[object .+?Constructor\]$/, Rt = /^(?:0|[1-9]\d*)$/, Wt = "[\\ufe0e\\ufe0f]?(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?(?:\\u200d(?:[^\\ud800-\\udfff]|(?:\\ud83c[\\udde6-\\uddff]){2}|[\\ud800-\\udbff][\\udc00-\\udfff])[\\ufe0e\\ufe0f]?(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?)*", Lt = "(?:[^\\ud800-\\udfff][\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]?|[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|(?:\\ud83c[\\udde6-\\uddff]){2}|[\\ud800-\\udbff][\\udc00-\\udfff]|[\\ud800-\\udfff])", Tt = RegExp("\\ud83c[\\udffb-\\udfff](?=\\ud83c[\\udffb-\\udfff])|" + Lt + Wt, "g"), Vt = RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]"), Nt = {};
1269
+ Nt["[object Float32Array]"] = Nt["[object Float64Array]"] = Nt["[object Int8Array]"] = Nt["[object Int16Array]"] = Nt["[object Int32Array]"] = Nt["[object Uint8Array]"] = Nt["[object Uint8ClampedArray]"] = Nt["[object Uint16Array]"] = Nt["[object Uint32Array]"] = true, Nt["[object Arguments]"] = Nt["[object Array]"] = Nt["[object ArrayBuffer]"] = Nt["[object Boolean]"] = Nt["[object DataView]"] = Nt["[object Date]"] = Nt["[object Error]"] = Nt["[object Function]"] = Nt["[object Map]"] = Nt["[object Number]"] = Nt["[object Object]"] = Nt["[object RegExp]"] = Nt["[object Set]"] = Nt["[object String]"] = Nt["[object WeakMap]"] = false;
1270
+ var Gt = {};
1271
+ Gt["[object Arguments]"] = Gt["[object Array]"] = Gt["[object ArrayBuffer]"] = Gt["[object DataView]"] = Gt["[object Boolean]"] = Gt["[object Date]"] = Gt["[object Float32Array]"] = Gt["[object Float64Array]"] = Gt["[object Int8Array]"] = Gt["[object Int16Array]"] = Gt["[object Int32Array]"] = Gt["[object Map]"] = Gt["[object Number]"] = Gt["[object Object]"] = Gt["[object RegExp]"] = Gt["[object Set]"] = Gt["[object String]"] = Gt["[object Symbol]"] = Gt["[object Uint8Array]"] = Gt["[object Uint8ClampedArray]"] = Gt["[object Uint16Array]"] = Gt["[object Uint32Array]"] = true, Gt["[object Error]"] = Gt["[object Function]"] = Gt["[object WeakMap]"] = false;
1272
+ var qt, Ht = typeof exports.commonjsGlobal == "object" && exports.commonjsGlobal && exports.commonjsGlobal.Object === Object && exports.commonjsGlobal, Jt = typeof self == "object" && self && self.Object === Object && self, Kt = Ht || Jt || Function("return this")(), Qt = exports$1 && !exports$1.nodeType && exports$1, Xt = Qt && true && module2 && !module2.nodeType && module2, Yt = Xt && Xt.exports === Qt, Zt = Yt && Ht.process;
1273
+ t: {
1274
+ try {
1275
+ qt = Zt && Zt.binding && Zt.binding("util");
1276
+ break t;
1277
+ } catch (t2) {
1278
+ }
1279
+ qt = void 0;
1280
+ }
1281
+ var te = qt && qt.isMap, ee = qt && qt.isSet, ne = qt && qt.isTypedArray, re = /* @__PURE__ */ function(t2) {
1282
+ return function(e2) {
1283
+ return null == e2 ? Mt : e2[t2];
1284
+ };
1285
+ }("length"), ue = Array.prototype, oe = Object.prototype, ce = Kt["__core-js_shared__"], ie = Function.prototype.toString, fe = oe.hasOwnProperty, ae = function() {
1286
+ var t2 = /[^.]+$/.exec(ce && ce.keys && ce.keys.IE_PROTO || "");
1287
+ return t2 ? "Symbol(src)_1." + t2 : "";
1288
+ }(), le = oe.toString, se = ie.call(Object), be = RegExp("^" + ie.call(fe).replace(/[\\^$.*+?()[\]{}|]/g, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"), pe = Yt ? Kt.Buffer : Mt, he = Kt.Symbol, ye = Kt.Uint8Array, je = pe ? pe.a : Mt, _e = c(Object.getPrototypeOf), de = Object.create, ge = oe.propertyIsEnumerable, ve = ue.splice, Ae = he ? he.isConcatSpreadable : Mt, me = he ? he.toStringTag : Mt, we = function() {
1289
+ try {
1290
+ var t2 = Y(Object, "defineProperty");
1291
+ return t2({}, "", {}), t2;
1292
+ } catch (t3) {
1293
+ }
1294
+ }(), Oe = Object.getOwnPropertySymbols, Se = pe ? pe.isBuffer : Mt, ze = c(Object.keys), xe = Math.max, ke = Date.now, Fe = Y(Kt, "DataView"), Ie = Y(Kt, "Map"), Me = Y(Kt, "Promise"), Ee = Y(Kt, "Set"), Ue = Y(Kt, "WeakMap"), Pe = Y(Object, "create"), De = ft(Fe), $e = ft(Ie), Be = ft(Me), Ce = ft(Ee), Re = ft(Ue), We = he ? he.prototype : Mt, Le = We ? We.valueOf : Mt, Te = We ? We.toString : Mt, Ve = /* @__PURE__ */ function() {
1295
+ function t2() {
1296
+ }
1297
+ return function(e2) {
1298
+ return _t(e2) ? de ? de(e2) : (t2.prototype = e2, e2 = new t2(), t2.prototype = Mt, e2) : {};
1299
+ };
1300
+ }();
1301
+ f.prototype.clear = function() {
1302
+ this.__data__ = Pe ? Pe(null) : {}, this.size = 0;
1303
+ }, f.prototype.delete = function(t2) {
1304
+ return t2 = this.has(t2) && delete this.__data__[t2], this.size -= t2 ? 1 : 0, t2;
1305
+ }, f.prototype.get = function(t2) {
1306
+ var e2 = this.__data__;
1307
+ return Pe ? (t2 = e2[t2], "__lodash_hash_undefined__" === t2 ? Mt : t2) : fe.call(e2, t2) ? e2[t2] : Mt;
1308
+ }, f.prototype.has = function(t2) {
1309
+ var e2 = this.__data__;
1310
+ return Pe ? e2[t2] !== Mt : fe.call(e2, t2);
1311
+ }, f.prototype.set = function(t2, e2) {
1312
+ var n2 = this.__data__;
1313
+ return this.size += this.has(t2) ? 0 : 1, n2[t2] = Pe && e2 === Mt ? "__lodash_hash_undefined__" : e2, this;
1314
+ }, a.prototype.clear = function() {
1315
+ this.__data__ = [], this.size = 0;
1316
+ }, a.prototype.delete = function(t2) {
1317
+ var e2 = this.__data__;
1318
+ return t2 = y(e2, t2), !(0 > t2) && (t2 == e2.length - 1 ? e2.pop() : ve.call(e2, t2, 1), --this.size, true);
1319
+ }, a.prototype.get = function(t2) {
1320
+ var e2 = this.__data__;
1321
+ return t2 = y(e2, t2), 0 > t2 ? Mt : e2[t2][1];
1322
+ }, a.prototype.has = function(t2) {
1323
+ return -1 < y(this.__data__, t2);
1324
+ }, a.prototype.set = function(t2, e2) {
1325
+ var n2 = this.__data__, r2 = y(n2, t2);
1326
+ return 0 > r2 ? (++this.size, n2.push([t2, e2])) : n2[r2][1] = e2, this;
1327
+ }, l.prototype.clear = function() {
1328
+ this.size = 0, this.__data__ = {
1329
+ hash: new f(),
1330
+ map: new (Ie || a)(),
1331
+ string: new f()
1332
+ };
1333
+ }, l.prototype.delete = function(t2) {
1334
+ return t2 = X(this, t2).delete(t2), this.size -= t2 ? 1 : 0, t2;
1335
+ }, l.prototype.get = function(t2) {
1336
+ return X(this, t2).get(t2);
1337
+ }, l.prototype.has = function(t2) {
1338
+ return X(this, t2).has(t2);
1339
+ }, l.prototype.set = function(t2, e2) {
1340
+ var n2 = X(this, t2), r2 = n2.size;
1341
+ return n2.set(t2, e2), this.size += n2.size == r2 ? 0 : 1, this;
1342
+ }, s.prototype.clear = function() {
1343
+ this.__data__ = new a(), this.size = 0;
1344
+ }, s.prototype.delete = function(t2) {
1345
+ var e2 = this.__data__;
1346
+ return t2 = e2.delete(t2), this.size = e2.size, t2;
1347
+ }, s.prototype.get = function(t2) {
1348
+ return this.__data__.get(t2);
1349
+ }, s.prototype.has = function(t2) {
1350
+ return this.__data__.has(t2);
1351
+ }, s.prototype.set = function(t2, e2) {
1352
+ var n2 = this.__data__;
1353
+ if (n2 instanceof a) {
1354
+ var r2 = n2.__data__;
1355
+ if (!Ie || 199 > r2.length) return r2.push([t2, e2]), this.size = ++n2.size, this;
1356
+ n2 = this.__data__ = new l(r2);
1357
+ }
1358
+ return n2.set(t2, e2), this.size = n2.size, this;
1359
+ };
1360
+ var Ne = /* @__PURE__ */ function(t2) {
1361
+ return function(e2, n2, r2) {
1362
+ var u2 = -1, o2 = Object(e2);
1363
+ r2 = r2(e2);
1364
+ for (var c2 = r2.length; c2--; ) {
1365
+ var i2 = r2[++u2];
1366
+ if (false === n2(o2[i2], i2, o2)) break;
1367
+ }
1368
+ return e2;
1369
+ };
1370
+ }(), Ge = we ? function(t2, e2) {
1371
+ return we(t2, "toString", {
1372
+ configurable: true,
1373
+ enumerable: false,
1374
+ value: xt(e2),
1375
+ writable: true
1376
+ });
1377
+ } : kt, qe = Oe ? function(t2) {
1378
+ return null == t2 ? [] : (t2 = Object(t2), n(Oe(t2), function(e2) {
1379
+ return ge.call(t2, e2);
1380
+ }));
1381
+ } : Ft, He = Oe ? function(t2) {
1382
+ for (var e2 = []; t2; ) u(e2, qe(t2)), t2 = _e(t2);
1383
+ return e2;
1384
+ } : Ft, Je = w;
1385
+ (Fe && "[object DataView]" != Je(new Fe(new ArrayBuffer(1))) || Ie && "[object Map]" != Je(new Ie()) || Me && "[object Promise]" != Je(Me.resolve()) || Ee && "[object Set]" != Je(new Ee()) || Ue && "[object WeakMap]" != Je(new Ue())) && (Je = function(t2) {
1386
+ var e2 = w(t2);
1387
+ if (t2 = (t2 = "[object Object]" == e2 ? t2.constructor : Mt) ? ft(t2) : "") switch (t2) {
1388
+ case De:
1389
+ return "[object DataView]";
1390
+ case $e:
1391
+ return "[object Map]";
1392
+ case Be:
1393
+ return "[object Promise]";
1394
+ case Ce:
1395
+ return "[object Set]";
1396
+ case Re:
1397
+ return "[object WeakMap]";
1398
+ }
1399
+ return e2;
1400
+ });
1401
+ var Ke = /* @__PURE__ */ function(t2) {
1402
+ var e2 = 0, n2 = 0;
1403
+ return function() {
1404
+ var r2 = ke(), u2 = 16 - (r2 - n2);
1405
+ if (n2 = r2, 0 < u2) {
1406
+ if (800 <= ++e2) return arguments[0];
1407
+ } else e2 = 0;
1408
+ return t2.apply(Mt, arguments);
1409
+ };
1410
+ }(Ge), Qe = function(t2) {
1411
+ t2 = st(t2, function(t3) {
1412
+ return 500 === e2.size && e2.clear(), t3;
1413
+ });
1414
+ var e2 = t2.cache;
1415
+ return t2;
1416
+ }(function(t2) {
1417
+ var e2 = [];
1418
+ return 46 === t2.charCodeAt(0) && e2.push(""), t2.replace(Dt, function(t3, n2, r2, u2) {
1419
+ e2.push(r2 ? u2.replace($t, "$1") : n2 || t3);
1420
+ }), e2;
1421
+ });
1422
+ st.Cache = l;
1423
+ var Xe = z(/* @__PURE__ */ function() {
1424
+ return arguments;
1425
+ }()) ? z : function(t2) {
1426
+ return dt(t2) && fe.call(t2, "callee") && !ge.call(t2, "callee");
1427
+ }, Ye = Array.isArray, Ze = Se || It, tn = te ? o(te) : x, en = ee ? o(ee) : k, nn = ne ? o(ne) : F, rn = q(function(t2, e2, n2) {
1428
+ M(t2, e2, n2);
1429
+ }), un = q(function(t2, e2, n2, r2) {
1430
+ M(t2, e2, n2, r2);
1431
+ }), on = J(function(t2, e2) {
1432
+ var n2 = {};
1433
+ if (null == t2) return n2;
1434
+ var u2 = false;
1435
+ e2 = r(e2, function(e3) {
1436
+ return e3 = C(e3, t2), u2 || (u2 = 1 < e3.length), e3;
1437
+ }), V(t2, Q(t2), n2), u2 && (n2 = g(n2, 7, H));
1438
+ for (var o2 = e2.length; o2--; ) B(n2, e2[o2]);
1439
+ return n2;
1440
+ }), cn = J(function(t2, e2) {
1441
+ return null == t2 ? {} : E(t2, e2);
1442
+ });
1443
+ i.constant = xt, i.flatten = at, i.keys = St, i.keysIn = zt, i.memoize = st, i.merge = rn, i.mergeWith = un, i.omit = on, i.pick = cn, i.set = function(t2, e2, n2) {
1444
+ return null == t2 ? t2 : D(t2, e2, n2);
1445
+ }, i.toPath = function(t2) {
1446
+ return Ye(t2) ? r(t2, it) : At(t2) ? [t2] : T(Qe(wt(t2)));
1447
+ }, i.toPlainObject = mt, i.unset = function(t2, e2) {
1448
+ return null == t2 || B(t2, e2);
1449
+ }, i.clone = function(t2) {
1450
+ return g(t2, 4);
1451
+ }, i.cloneDeep = function(t2) {
1452
+ return g(t2, 5);
1453
+ }, i.cloneDeepWith = function(t2, e2) {
1454
+ return e2 = typeof e2 == "function" ? e2 : Mt, g(t2, 5, e2);
1455
+ }, i.cloneWith = function(t2, e2) {
1456
+ return e2 = typeof e2 == "function" ? e2 : Mt, g(t2, 4, e2);
1457
+ }, i.eq = bt, i.get = function(t2, e2, n2) {
1458
+ return t2 = null == t2 ? Mt : A(t2, e2), t2 === Mt ? n2 : t2;
1459
+ }, i.has = function(t2, e2) {
1460
+ return null != t2 && Z(t2, e2, O);
1461
+ }, i.hasIn = Ot, i.identity = kt, i.isArguments = Xe, i.isArray = Ye, i.isArrayLike = pt, i.isArrayLikeObject = ht, i.isBuffer = Ze, i.isFunction = yt, i.isLength = jt, i.isMap = tn, i.isObject = _t, i.isObjectLike = dt, i.isPlainObject = gt, i.isSet = en, i.isString = vt, i.isSymbol = At, i.isTypedArray = nn, i.last = lt, i.stubArray = Ft, i.stubFalse = It, i.size = function(t2) {
1462
+ if (null == t2) return 0;
1463
+ if (pt(t2)) {
1464
+ if (vt(t2)) if (Vt.test(t2)) {
1465
+ for (var e2 = Tt.lastIndex = 0; Tt.test(t2); ) ++e2;
1466
+ t2 = e2;
1467
+ } else t2 = re(t2);
1468
+ else t2 = t2.length;
1469
+ return t2;
1470
+ }
1471
+ return e2 = Je(t2), "[object Map]" == e2 || "[object Set]" == e2 ? t2.size : I(t2).length;
1472
+ }, i.toString = wt, i.VERSION = "4.17.5", Xt ? ((Xt.exports = i)._ = i, Qt._ = i) : Kt._ = i;
1473
+ }).call(exports.commonjsGlobal);
1474
+ })(main, main.exports);
1475
+ var mainExports = main.exports;
1476
+ const lodash = /* @__PURE__ */ getDefaultExportFromCjs(mainExports);
1477
+ var bytes$2 = { exports: {} };
1478
+ /*!
1479
+ * bytes
1480
+ * Copyright(c) 2012-2014 TJ Holowaychuk
1481
+ * Copyright(c) 2015 Jed Watson
1482
+ * MIT Licensed
1483
+ */
1484
+ bytes$2.exports;
1485
+ bytes$2.exports = bytes;
1486
+ bytes$2.exports.format = format$1;
1487
+ bytes$2.exports.parse = parse$1;
1488
+ var formatThousandsRegExp = /\B(?=(\d{3})+(?!\d))/g;
1489
+ var formatDecimalsRegExp = /(?:\.0*|(\.[^0]+)0+)$/;
1490
+ var map = {
1491
+ b: 1,
1492
+ kb: 1 << 10,
1493
+ mb: 1 << 20,
1494
+ gb: 1 << 30,
1495
+ tb: Math.pow(1024, 4),
1496
+ pb: Math.pow(1024, 5)
1497
+ };
1498
+ var parseRegExp = /^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb|pb)$/i;
1499
+ function bytes(value, options) {
1500
+ if (typeof value === "string") {
1501
+ return parse$1(value);
1502
+ }
1503
+ if (typeof value === "number") {
1504
+ return format$1(value, options);
1505
+ }
1506
+ return null;
1507
+ }
1508
+ function format$1(value, options) {
1509
+ if (!Number.isFinite(value)) {
1510
+ return null;
1511
+ }
1512
+ var mag = Math.abs(value);
1513
+ var thousandsSeparator = options && options.thousandsSeparator || "";
1514
+ var unitSeparator = options && options.unitSeparator || "";
1515
+ var decimalPlaces = options && options.decimalPlaces !== void 0 ? options.decimalPlaces : 2;
1516
+ var fixedDecimals = Boolean(options && options.fixedDecimals);
1517
+ var unit = options && options.unit || "";
1518
+ if (!unit || !map[unit.toLowerCase()]) {
1519
+ if (mag >= map.pb) {
1520
+ unit = "PB";
1521
+ } else if (mag >= map.tb) {
1522
+ unit = "TB";
1523
+ } else if (mag >= map.gb) {
1524
+ unit = "GB";
1525
+ } else if (mag >= map.mb) {
1526
+ unit = "MB";
1527
+ } else if (mag >= map.kb) {
1528
+ unit = "KB";
1529
+ } else {
1530
+ unit = "B";
1531
+ }
1532
+ }
1533
+ var val = value / map[unit.toLowerCase()];
1534
+ var str = val.toFixed(decimalPlaces);
1535
+ if (!fixedDecimals) {
1536
+ str = str.replace(formatDecimalsRegExp, "$1");
1537
+ }
1538
+ if (thousandsSeparator) {
1539
+ str = str.split(".").map(function(s, i) {
1540
+ return i === 0 ? s.replace(formatThousandsRegExp, thousandsSeparator) : s;
1541
+ }).join(".");
1542
+ }
1543
+ return str + unitSeparator + unit;
1544
+ }
1545
+ function parse$1(val) {
1546
+ if (typeof val === "number" && !isNaN(val)) {
1547
+ return val;
1548
+ }
1549
+ if (typeof val !== "string") {
1550
+ return null;
1551
+ }
1552
+ var results = parseRegExp.exec(val);
1553
+ var floatValue;
1554
+ var unit = "b";
1555
+ if (!results) {
1556
+ floatValue = parseInt(val, 10);
1557
+ unit = "b";
1558
+ } else {
1559
+ floatValue = parseFloat(results[1]);
1560
+ unit = results[4].toLowerCase();
1561
+ }
1562
+ if (isNaN(floatValue)) {
1563
+ return null;
1564
+ }
1565
+ return Math.floor(map[unit] * floatValue);
1566
+ }
1567
+ var bytesExports = bytes$2.exports;
1568
+ const bytes$1 = /* @__PURE__ */ getDefaultExportFromCjs(bytesExports);
1569
+ var RGX = /^(-?(?:\d+)?\.?\d+) *(m(?:illiseconds?|s(?:ecs?)?))?(s(?:ec(?:onds?|s)?)?)?(m(?:in(?:utes?|s)?)?)?(h(?:ours?|rs?)?)?(d(?:ays?)?)?(w(?:eeks?|ks?)?)?(y(?:ears?|rs?)?)?$/, SEC = 1e3, MIN = SEC * 60, HOUR = MIN * 60, DAY = HOUR * 24, YEAR = DAY * 365.25;
1570
+ function parse(val) {
1571
+ var num, arr = val.toLowerCase().match(RGX);
1572
+ if (arr != null && (num = parseFloat(arr[1]))) {
1573
+ if (arr[3] != null) return num * SEC;
1574
+ if (arr[4] != null) return num * MIN;
1575
+ if (arr[5] != null) return num * HOUR;
1576
+ if (arr[6] != null) return num * DAY;
1577
+ if (arr[7] != null) return num * DAY * 7;
1578
+ if (arr[8] != null) return num * YEAR;
1579
+ return num;
1580
+ }
1581
+ }
1582
+ function fmt(val, pfx, str, long) {
1583
+ var num = (val | 0) === val ? val : ~~(val + 0.5);
1584
+ return pfx + num + (long ? " " + str + (num != 1 ? "s" : "") : str[0]);
1585
+ }
1586
+ function format(num, long) {
1587
+ var pfx = num < 0 ? "-" : "", abs = num < 0 ? -num : num;
1588
+ if (abs < SEC) return num + (long ? " ms" : "ms");
1589
+ if (abs < MIN) return fmt(abs / SEC, pfx, "second", long);
1590
+ if (abs < HOUR) return fmt(abs / MIN, pfx, "minute", long);
1591
+ if (abs < DAY) return fmt(abs / HOUR, pfx, "hour", long);
1592
+ if (abs < YEAR) return fmt(abs / DAY, pfx, "day", long);
1593
+ return fmt(abs / YEAR, pfx, "year", long);
1594
+ }
1595
+ var slugify = { exports: {} };
1596
+ slugify.exports;
1597
+ (function(module2, exports$1) {
1598
+ (function(name, root, factory) {
1599
+ {
1600
+ module2.exports = factory();
1601
+ module2.exports["default"] = factory();
1602
+ }
1603
+ })("slugify", exports.commonjsGlobal, function() {
1604
+ var charMap = JSON.parse(`{"$":"dollar","%":"percent","&":"and","<":"less",">":"greater","|":"or","¢":"cent","£":"pound","¤":"currency","¥":"yen","©":"(c)","ª":"a","®":"(r)","º":"o","À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","Æ":"AE","Ç":"C","È":"E","É":"E","Ê":"E","Ë":"E","Ì":"I","Í":"I","Î":"I","Ï":"I","Ð":"D","Ñ":"N","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","Ù":"U","Ú":"U","Û":"U","Ü":"U","Ý":"Y","Þ":"TH","ß":"ss","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","æ":"ae","ç":"c","è":"e","é":"e","ê":"e","ë":"e","ì":"i","í":"i","î":"i","ï":"i","ð":"d","ñ":"n","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","ù":"u","ú":"u","û":"u","ü":"u","ý":"y","þ":"th","ÿ":"y","Ā":"A","ā":"a","Ă":"A","ă":"a","Ą":"A","ą":"a","Ć":"C","ć":"c","Č":"C","č":"c","Ď":"D","ď":"d","Đ":"DJ","đ":"dj","Ē":"E","ē":"e","Ė":"E","ė":"e","Ę":"e","ę":"e","Ě":"E","ě":"e","Ğ":"G","ğ":"g","Ģ":"G","ģ":"g","Ĩ":"I","ĩ":"i","Ī":"i","ī":"i","Į":"I","į":"i","İ":"I","ı":"i","Ķ":"k","ķ":"k","Ļ":"L","ļ":"l","Ľ":"L","ľ":"l","Ł":"L","ł":"l","Ń":"N","ń":"n","Ņ":"N","ņ":"n","Ň":"N","ň":"n","Ō":"O","ō":"o","Ő":"O","ő":"o","Œ":"OE","œ":"oe","Ŕ":"R","ŕ":"r","Ř":"R","ř":"r","Ś":"S","ś":"s","Ş":"S","ş":"s","Š":"S","š":"s","Ţ":"T","ţ":"t","Ť":"T","ť":"t","Ũ":"U","ũ":"u","Ū":"u","ū":"u","Ů":"U","ů":"u","Ű":"U","ű":"u","Ų":"U","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","ź":"z","Ż":"Z","ż":"z","Ž":"Z","ž":"z","Ə":"E","ƒ":"f","Ơ":"O","ơ":"o","Ư":"U","ư":"u","Lj":"LJ","lj":"lj","Nj":"NJ","nj":"nj","Ș":"S","ș":"s","Ț":"T","ț":"t","ə":"e","˚":"o","Ά":"A","Έ":"E","Ή":"H","Ί":"I","Ό":"O","Ύ":"Y","Ώ":"W","ΐ":"i","Α":"A","Β":"B","Γ":"G","Δ":"D","Ε":"E","Ζ":"Z","Η":"H","Θ":"8","Ι":"I","Κ":"K","Λ":"L","Μ":"M","Ν":"N","Ξ":"3","Ο":"O","Π":"P","Ρ":"R","Σ":"S","Τ":"T","Υ":"Y","Φ":"F","Χ":"X","Ψ":"PS","Ω":"W","Ϊ":"I","Ϋ":"Y","ά":"a","έ":"e","ή":"h","ί":"i","ΰ":"y","α":"a","β":"b","γ":"g","δ":"d","ε":"e","ζ":"z","η":"h","θ":"8","ι":"i","κ":"k","λ":"l","μ":"m","ν":"n","ξ":"3","ο":"o","π":"p","ρ":"r","ς":"s","σ":"s","τ":"t","υ":"y","φ":"f","χ":"x","ψ":"ps","ω":"w","ϊ":"i","ϋ":"y","ό":"o","ύ":"y","ώ":"w","Ё":"Yo","Ђ":"DJ","Є":"Ye","І":"I","Ї":"Yi","Ј":"J","Љ":"LJ","Њ":"NJ","Ћ":"C","Џ":"DZ","А":"A","Б":"B","В":"V","Г":"G","Д":"D","Е":"E","Ж":"Zh","З":"Z","И":"I","Й":"J","К":"K","Л":"L","М":"M","Н":"N","О":"O","П":"P","Р":"R","С":"S","Т":"T","У":"U","Ф":"F","Х":"H","Ц":"C","Ч":"Ch","Ш":"Sh","Щ":"Sh","Ъ":"U","Ы":"Y","Ь":"","Э":"E","Ю":"Yu","Я":"Ya","а":"a","б":"b","в":"v","г":"g","д":"d","е":"e","ж":"zh","з":"z","и":"i","й":"j","к":"k","л":"l","м":"m","н":"n","о":"o","п":"p","р":"r","с":"s","т":"t","у":"u","ф":"f","х":"h","ц":"c","ч":"ch","ш":"sh","щ":"sh","ъ":"u","ы":"y","ь":"","э":"e","ю":"yu","я":"ya","ё":"yo","ђ":"dj","є":"ye","і":"i","ї":"yi","ј":"j","љ":"lj","њ":"nj","ћ":"c","ѝ":"u","џ":"dz","Ґ":"G","ґ":"g","Ғ":"GH","ғ":"gh","Қ":"KH","қ":"kh","Ң":"NG","ң":"ng","Ү":"UE","ү":"ue","Ұ":"U","ұ":"u","Һ":"H","һ":"h","Ә":"AE","ә":"ae","Ө":"OE","ө":"oe","Ա":"A","Բ":"B","Գ":"G","Դ":"D","Ե":"E","Զ":"Z","Է":"E'","Ը":"Y'","Թ":"T'","Ժ":"JH","Ի":"I","Լ":"L","Խ":"X","Ծ":"C'","Կ":"K","Հ":"H","Ձ":"D'","Ղ":"GH","Ճ":"TW","Մ":"M","Յ":"Y","Ն":"N","Շ":"SH","Չ":"CH","Պ":"P","Ջ":"J","Ռ":"R'","Ս":"S","Վ":"V","Տ":"T","Ր":"R","Ց":"C","Փ":"P'","Ք":"Q'","Օ":"O''","Ֆ":"F","և":"EV","ء":"a","آ":"aa","أ":"a","ؤ":"u","إ":"i","ئ":"e","ا":"a","ب":"b","ة":"h","ت":"t","ث":"th","ج":"j","ح":"h","خ":"kh","د":"d","ذ":"th","ر":"r","ز":"z","س":"s","ش":"sh","ص":"s","ض":"dh","ط":"t","ظ":"z","ع":"a","غ":"gh","ف":"f","ق":"q","ك":"k","ل":"l","م":"m","ن":"n","ه":"h","و":"w","ى":"a","ي":"y","ً":"an","ٌ":"on","ٍ":"en","َ":"a","ُ":"u","ِ":"e","ْ":"","٠":"0","١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","پ":"p","چ":"ch","ژ":"zh","ک":"k","گ":"g","ی":"y","۰":"0","۱":"1","۲":"2","۳":"3","۴":"4","۵":"5","۶":"6","۷":"7","۸":"8","۹":"9","฿":"baht","ა":"a","ბ":"b","გ":"g","დ":"d","ე":"e","ვ":"v","ზ":"z","თ":"t","ი":"i","კ":"k","ლ":"l","მ":"m","ნ":"n","ო":"o","პ":"p","ჟ":"zh","რ":"r","ს":"s","ტ":"t","უ":"u","ფ":"f","ქ":"k","ღ":"gh","ყ":"q","შ":"sh","ჩ":"ch","ც":"ts","ძ":"dz","წ":"ts","ჭ":"ch","ხ":"kh","ჯ":"j","ჰ":"h","Ṣ":"S","ṣ":"s","Ẁ":"W","ẁ":"w","Ẃ":"W","ẃ":"w","Ẅ":"W","ẅ":"w","ẞ":"SS","Ạ":"A","ạ":"a","Ả":"A","ả":"a","Ấ":"A","ấ":"a","Ầ":"A","ầ":"a","Ẩ":"A","ẩ":"a","Ẫ":"A","ẫ":"a","Ậ":"A","ậ":"a","Ắ":"A","ắ":"a","Ằ":"A","ằ":"a","Ẳ":"A","ẳ":"a","Ẵ":"A","ẵ":"a","Ặ":"A","ặ":"a","Ẹ":"E","ẹ":"e","Ẻ":"E","ẻ":"e","Ẽ":"E","ẽ":"e","Ế":"E","ế":"e","Ề":"E","ề":"e","Ể":"E","ể":"e","Ễ":"E","ễ":"e","Ệ":"E","ệ":"e","Ỉ":"I","ỉ":"i","Ị":"I","ị":"i","Ọ":"O","ọ":"o","Ỏ":"O","ỏ":"o","Ố":"O","ố":"o","Ồ":"O","ồ":"o","Ổ":"O","ổ":"o","Ỗ":"O","ỗ":"o","Ộ":"O","ộ":"o","Ớ":"O","ớ":"o","Ờ":"O","ờ":"o","Ở":"O","ở":"o","Ỡ":"O","ỡ":"o","Ợ":"O","ợ":"o","Ụ":"U","ụ":"u","Ủ":"U","ủ":"u","Ứ":"U","ứ":"u","Ừ":"U","ừ":"u","Ử":"U","ử":"u","Ữ":"U","ữ":"u","Ự":"U","ự":"u","Ỳ":"Y","ỳ":"y","Ỵ":"Y","ỵ":"y","Ỷ":"Y","ỷ":"y","Ỹ":"Y","ỹ":"y","–":"-","‘":"'","’":"'","“":"\\"","”":"\\"","„":"\\"","†":"+","•":"*","…":"...","₠":"ecu","₢":"cruzeiro","₣":"french franc","₤":"lira","₥":"mill","₦":"naira","₧":"peseta","₨":"rupee","₩":"won","₪":"new shequel","₫":"dong","€":"euro","₭":"kip","₮":"tugrik","₯":"drachma","₰":"penny","₱":"peso","₲":"guarani","₳":"austral","₴":"hryvnia","₵":"cedi","₸":"kazakhstani tenge","₹":"indian rupee","₺":"turkish lira","₽":"russian ruble","₿":"bitcoin","℠":"sm","™":"tm","∂":"d","∆":"delta","∑":"sum","∞":"infinity","♥":"love","元":"yuan","円":"yen","﷼":"rial","ﻵ":"laa","ﻷ":"laa","ﻹ":"lai","ﻻ":"la"}`);
1605
+ var locales = JSON.parse('{"bg":{"Й":"Y","Ц":"Ts","Щ":"Sht","Ъ":"A","Ь":"Y","й":"y","ц":"ts","щ":"sht","ъ":"a","ь":"y"},"de":{"Ä":"AE","ä":"ae","Ö":"OE","ö":"oe","Ü":"UE","ü":"ue","ß":"ss","%":"prozent","&":"und","|":"oder","∑":"summe","∞":"unendlich","♥":"liebe"},"es":{"%":"por ciento","&":"y","<":"menor que",">":"mayor que","|":"o","¢":"centavos","£":"libras","¤":"moneda","₣":"francos","∑":"suma","∞":"infinito","♥":"amor"},"fr":{"%":"pourcent","&":"et","<":"plus petit",">":"plus grand","|":"ou","¢":"centime","£":"livre","¤":"devise","₣":"franc","∑":"somme","∞":"infini","♥":"amour"},"pt":{"%":"porcento","&":"e","<":"menor",">":"maior","|":"ou","¢":"centavo","∑":"soma","£":"libra","∞":"infinito","♥":"amor"},"uk":{"И":"Y","и":"y","Й":"Y","й":"y","Ц":"Ts","ц":"ts","Х":"Kh","х":"kh","Щ":"Shch","щ":"shch","Г":"H","г":"h"},"vi":{"Đ":"D","đ":"d"},"da":{"Ø":"OE","ø":"oe","Å":"AA","å":"aa","%":"procent","&":"og","|":"eller","$":"dollar","<":"mindre end",">":"større end"},"nb":{"&":"og","Å":"AA","Æ":"AE","Ø":"OE","å":"aa","æ":"ae","ø":"oe"},"it":{"&":"e"},"nl":{"&":"en"},"sv":{"&":"och","Å":"AA","Ä":"AE","Ö":"OE","å":"aa","ä":"ae","ö":"oe"}}');
1606
+ function replace(string2, options) {
1607
+ if (typeof string2 !== "string") {
1608
+ throw new Error("slugify: string argument expected");
1609
+ }
1610
+ options = typeof options === "string" ? { replacement: options } : options || {};
1611
+ var locale = locales[options.locale] || {};
1612
+ var replacement = options.replacement === void 0 ? "-" : options.replacement;
1613
+ var trim = options.trim === void 0 ? true : options.trim;
1614
+ var slug2 = string2.normalize().split("").reduce(function(result, ch) {
1615
+ var appendChar = locale[ch];
1616
+ if (appendChar === void 0) appendChar = charMap[ch];
1617
+ if (appendChar === void 0) appendChar = ch;
1618
+ if (appendChar === replacement) appendChar = " ";
1619
+ return result + appendChar.replace(options.remove || /[^\w\s$*_+~.()'"!\-:@]+/g, "");
1620
+ }, "");
1621
+ if (options.strict) {
1622
+ slug2 = slug2.replace(/[^A-Za-z0-9\s]/g, "");
1623
+ }
1624
+ if (trim) {
1625
+ slug2 = slug2.trim();
1626
+ }
1627
+ slug2 = slug2.replace(/\s+/g, replacement);
1628
+ if (options.lower) {
1629
+ slug2 = slug2.toLowerCase();
1630
+ }
1631
+ return slug2;
1632
+ }
1633
+ replace.extend = function(customMap) {
1634
+ Object.assign(charMap, customMap);
1635
+ };
1636
+ return replace;
1637
+ });
1638
+ })(slugify, slugify.exports);
1639
+ var slugifyExports = slugify.exports;
1640
+ const slugifyPkg = /* @__PURE__ */ getDefaultExportFromCjs(slugifyExports);
1641
+ var truncatise = { exports: {} };
1642
+ truncatise.exports;
1643
+ (function(module2) {
1644
+ (function(exportTo) {
1645
+ var selfClosingTags = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "menuitem", "meta", "param", "source", "track", "wbr"];
1646
+ var truncatise3 = function(text, options) {
1647
+ var options = options || {}, text = (text || "").trim(), truncatedText = "", currentState = 0, isEndOfWord = false, currentTag = "", tagStack = [], nextChar = "";
1648
+ var charCounter = 0, wordCounter = 0, paragraphCounter = 0;
1649
+ var NOT_TAG = 0, TAG_START = 1, TAG_ATTRIBUTES = 2;
1650
+ options.TruncateBy = options.TruncateBy === void 0 || typeof options.TruncateBy !== "string" || !options.TruncateBy.match(/(word(s)?|character(s)?|paragraph(s)?)/) ? "words" : options.TruncateBy.toLowerCase();
1651
+ options.TruncateLength = options.TruncateLength === void 0 || typeof options.TruncateLength !== "number" ? 50 : options.TruncateLength;
1652
+ options.StripHTML = options.StripHTML === void 0 || typeof options.StripHTML !== "boolean" ? false : options.StripHTML;
1653
+ options.Strict = options.Strict === void 0 || typeof options.Strict !== "boolean" ? true : options.Strict;
1654
+ options.Suffix = options.Suffix === void 0 || typeof options.Suffix !== "string" ? "..." : options.Suffix;
1655
+ if (text === "" || text.length <= options.TruncateLength && options.StripHTML === false) {
1656
+ return text;
1657
+ }
1658
+ if (options.StripHTML) {
1659
+ text = String(text).replace(/<br( \/)?>/gi, " ");
1660
+ }
1661
+ if (options.StripHTML && !options.TruncateBy.match(/(paragraph(s)?)/)) {
1662
+ text = String(text).replace(/<!--(.*?)-->/gm, "").replace(/<\/?[^>]+>/gi, "");
1663
+ }
1664
+ text = String(text).replace(/<\/p>(\r?\n)+<p>/gm, "</p><p>");
1665
+ if (options.StripHTML && String(text).match(/\r?\n\r?\n/)) {
1666
+ text = String(text).replace(/((.+)(\r?\n\r?\n|$))/gi, "<p>$2</p>");
1667
+ }
1668
+ for (var pointer = 0; pointer < text.length; pointer++) {
1669
+ var currentChar = text[pointer];
1670
+ switch (currentChar) {
1671
+ case "<":
1672
+ if (currentState === NOT_TAG) {
1673
+ currentState = TAG_START;
1674
+ currentTag = "";
1675
+ }
1676
+ if (!options.StripHTML) {
1677
+ truncatedText += currentChar;
1678
+ }
1679
+ break;
1680
+ case ">":
1681
+ if (currentState === TAG_START || currentState === TAG_ATTRIBUTES) {
1682
+ currentState = NOT_TAG;
1683
+ currentTag = currentTag.toLowerCase();
1684
+ if (currentTag === "/p") {
1685
+ paragraphCounter++;
1686
+ if (options.StripHTML) {
1687
+ truncatedText += " ";
1688
+ }
1689
+ }
1690
+ if (selfClosingTags.indexOf(currentTag) === -1 && selfClosingTags.indexOf(currentTag + "/") === -1) {
1691
+ if (currentTag.indexOf("/") >= 0) {
1692
+ tagStack.pop();
1693
+ } else {
1694
+ tagStack.push(currentTag);
1695
+ }
1696
+ }
1697
+ }
1698
+ if (!options.StripHTML) {
1699
+ truncatedText += currentChar;
1700
+ }
1701
+ break;
1702
+ case " ":
1703
+ if (currentState === TAG_START) {
1704
+ currentState = TAG_ATTRIBUTES;
1705
+ }
1706
+ if (currentState === NOT_TAG) {
1707
+ wordCounter++;
1708
+ charCounter++;
1709
+ }
1710
+ if (currentState === NOT_TAG || !options.StripHTML) {
1711
+ truncatedText += currentChar;
1712
+ }
1713
+ break;
1714
+ default:
1715
+ if (currentState === NOT_TAG) {
1716
+ charCounter++;
1717
+ }
1718
+ if (currentState === TAG_START) {
1719
+ currentTag += currentChar;
1720
+ }
1721
+ if (currentState === NOT_TAG || !options.StripHTML) {
1722
+ truncatedText += currentChar;
1723
+ }
1724
+ break;
1725
+ }
1726
+ nextChar = text[pointer + 1] || "";
1727
+ isEndOfWord = options.Strict ? true : !currentChar.match(/[a-zA-ZÇ-Ü']/i) || !nextChar.match(/[a-zA-ZÇ-Ü']/i);
1728
+ if (options.TruncateBy.match(/word(s)?/i) && options.TruncateLength <= wordCounter) {
1729
+ truncatedText = truncatedText.replace(/\s+$/, "");
1730
+ break;
1731
+ }
1732
+ if (options.TruncateBy.match(/character(s)?/i) && options.TruncateLength <= charCounter && isEndOfWord) {
1733
+ break;
1734
+ }
1735
+ if (options.TruncateBy.match(/paragraph(s)?/i) && options.TruncateLength === paragraphCounter) {
1736
+ break;
1737
+ }
1738
+ }
1739
+ if (!options.StripHTML && tagStack.length > 0) {
1740
+ while (tagStack.length > 0) {
1741
+ var tag = tagStack.pop();
1742
+ if (tag !== "!--") {
1743
+ truncatedText += "</" + tag + ">";
1744
+ }
1745
+ }
1746
+ }
1747
+ if (pointer < text.length - 1) {
1748
+ if (truncatedText.match(/<\/p>$/gi)) {
1749
+ truncatedText = truncatedText.replace(/(<\/p>)$/gi, options.Suffix + "$1");
1750
+ } else {
1751
+ truncatedText = truncatedText + options.Suffix;
1752
+ }
1753
+ }
1754
+ return truncatedText.trim();
1755
+ };
1756
+ if (module2.exports) {
1757
+ return module2.exports = truncatise3;
1758
+ }
1759
+ exportTo.truncatise = truncatise3;
1760
+ })(exports.commonjsGlobal);
1761
+ })(truncatise);
1762
+ var truncatiseExports = truncatise.exports;
1763
+ const truncatise2 = /* @__PURE__ */ getDefaultExportFromCjs(truncatiseExports);
1764
+ function commonjsRequire(path) {
1765
+ throw new Error('Could not dynamically require "' + path + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
1766
+ }
1767
+ var pluralize$1 = { exports: {} };
1768
+ pluralize$1.exports;
1769
+ (function(module2, exports$1) {
1770
+ (function(root, pluralize2) {
1771
+ if (typeof commonjsRequire === "function" && true && true) {
1772
+ module2.exports = pluralize2();
1773
+ } else {
1774
+ root.pluralize = pluralize2();
1775
+ }
1776
+ })(exports.commonjsGlobal, function() {
1777
+ var pluralRules = [];
1778
+ var singularRules = [];
1779
+ var uncountables = {};
1780
+ var irregularPlurals = {};
1781
+ var irregularSingles = {};
1782
+ function sanitizeRule(rule) {
1783
+ if (typeof rule === "string") {
1784
+ return new RegExp("^" + rule + "$", "i");
1785
+ }
1786
+ return rule;
1787
+ }
1788
+ function restoreCase(word, token) {
1789
+ if (word === token) return token;
1790
+ if (word === word.toLowerCase()) return token.toLowerCase();
1791
+ if (word === word.toUpperCase()) return token.toUpperCase();
1792
+ if (word[0] === word[0].toUpperCase()) {
1793
+ return token.charAt(0).toUpperCase() + token.substr(1).toLowerCase();
1794
+ }
1795
+ return token.toLowerCase();
1796
+ }
1797
+ function interpolate2(str, args) {
1798
+ return str.replace(/\$(\d{1,2})/g, function(match, index) {
1799
+ return args[index] || "";
1800
+ });
1801
+ }
1802
+ function replace(word, rule) {
1803
+ return word.replace(rule[0], function(match, index) {
1804
+ var result = interpolate2(rule[1], arguments);
1805
+ if (match === "") {
1806
+ return restoreCase(word[index - 1], result);
1807
+ }
1808
+ return restoreCase(match, result);
1809
+ });
1810
+ }
1811
+ function sanitizeWord(token, word, rules) {
1812
+ if (!token.length || uncountables.hasOwnProperty(token)) {
1813
+ return word;
1814
+ }
1815
+ var len = rules.length;
1816
+ while (len--) {
1817
+ var rule = rules[len];
1818
+ if (rule[0].test(word)) return replace(word, rule);
1819
+ }
1820
+ return word;
1821
+ }
1822
+ function replaceWord(replaceMap, keepMap, rules) {
1823
+ return function(word) {
1824
+ var token = word.toLowerCase();
1825
+ if (keepMap.hasOwnProperty(token)) {
1826
+ return restoreCase(word, token);
1827
+ }
1828
+ if (replaceMap.hasOwnProperty(token)) {
1829
+ return restoreCase(word, replaceMap[token]);
1830
+ }
1831
+ return sanitizeWord(token, word, rules);
1832
+ };
1833
+ }
1834
+ function checkWord(replaceMap, keepMap, rules, bool) {
1835
+ return function(word) {
1836
+ var token = word.toLowerCase();
1837
+ if (keepMap.hasOwnProperty(token)) return true;
1838
+ if (replaceMap.hasOwnProperty(token)) return false;
1839
+ return sanitizeWord(token, token, rules) === token;
1840
+ };
1841
+ }
1842
+ function pluralize2(word, count, inclusive) {
1843
+ var pluralized = count === 1 ? pluralize2.singular(word) : pluralize2.plural(word);
1844
+ return (inclusive ? count + " " : "") + pluralized;
1845
+ }
1846
+ pluralize2.plural = replaceWord(
1847
+ irregularSingles,
1848
+ irregularPlurals,
1849
+ pluralRules
1850
+ );
1851
+ pluralize2.isPlural = checkWord(
1852
+ irregularSingles,
1853
+ irregularPlurals,
1854
+ pluralRules
1855
+ );
1856
+ pluralize2.singular = replaceWord(
1857
+ irregularPlurals,
1858
+ irregularSingles,
1859
+ singularRules
1860
+ );
1861
+ pluralize2.isSingular = checkWord(
1862
+ irregularPlurals,
1863
+ irregularSingles,
1864
+ singularRules
1865
+ );
1866
+ pluralize2.addPluralRule = function(rule, replacement) {
1867
+ pluralRules.push([sanitizeRule(rule), replacement]);
1868
+ };
1869
+ pluralize2.addSingularRule = function(rule, replacement) {
1870
+ singularRules.push([sanitizeRule(rule), replacement]);
1871
+ };
1872
+ pluralize2.addUncountableRule = function(word) {
1873
+ if (typeof word === "string") {
1874
+ uncountables[word.toLowerCase()] = true;
1875
+ return;
1876
+ }
1877
+ pluralize2.addPluralRule(word, "$0");
1878
+ pluralize2.addSingularRule(word, "$0");
1879
+ };
1880
+ pluralize2.addIrregularRule = function(single, plural2) {
1881
+ plural2 = plural2.toLowerCase();
1882
+ single = single.toLowerCase();
1883
+ irregularSingles[single] = plural2;
1884
+ irregularPlurals[plural2] = single;
1885
+ };
1886
+ [
1887
+ // Pronouns.
1888
+ ["I", "we"],
1889
+ ["me", "us"],
1890
+ ["he", "they"],
1891
+ ["she", "they"],
1892
+ ["them", "them"],
1893
+ ["myself", "ourselves"],
1894
+ ["yourself", "yourselves"],
1895
+ ["itself", "themselves"],
1896
+ ["herself", "themselves"],
1897
+ ["himself", "themselves"],
1898
+ ["themself", "themselves"],
1899
+ ["is", "are"],
1900
+ ["was", "were"],
1901
+ ["has", "have"],
1902
+ ["this", "these"],
1903
+ ["that", "those"],
1904
+ // Words ending in with a consonant and `o`.
1905
+ ["echo", "echoes"],
1906
+ ["dingo", "dingoes"],
1907
+ ["volcano", "volcanoes"],
1908
+ ["tornado", "tornadoes"],
1909
+ ["torpedo", "torpedoes"],
1910
+ // Ends with `us`.
1911
+ ["genus", "genera"],
1912
+ ["viscus", "viscera"],
1913
+ // Ends with `ma`.
1914
+ ["stigma", "stigmata"],
1915
+ ["stoma", "stomata"],
1916
+ ["dogma", "dogmata"],
1917
+ ["lemma", "lemmata"],
1918
+ ["schema", "schemata"],
1919
+ ["anathema", "anathemata"],
1920
+ // Other irregular rules.
1921
+ ["ox", "oxen"],
1922
+ ["axe", "axes"],
1923
+ ["die", "dice"],
1924
+ ["yes", "yeses"],
1925
+ ["foot", "feet"],
1926
+ ["eave", "eaves"],
1927
+ ["goose", "geese"],
1928
+ ["tooth", "teeth"],
1929
+ ["quiz", "quizzes"],
1930
+ ["human", "humans"],
1931
+ ["proof", "proofs"],
1932
+ ["carve", "carves"],
1933
+ ["valve", "valves"],
1934
+ ["looey", "looies"],
1935
+ ["thief", "thieves"],
1936
+ ["groove", "grooves"],
1937
+ ["pickaxe", "pickaxes"],
1938
+ ["passerby", "passersby"]
1939
+ ].forEach(function(rule) {
1940
+ return pluralize2.addIrregularRule(rule[0], rule[1]);
1941
+ });
1942
+ [
1943
+ [/s?$/i, "s"],
1944
+ [/[^\u0000-\u007F]$/i, "$0"],
1945
+ [/([^aeiou]ese)$/i, "$1"],
1946
+ [/(ax|test)is$/i, "$1es"],
1947
+ [/(alias|[^aou]us|t[lm]as|gas|ris)$/i, "$1es"],
1948
+ [/(e[mn]u)s?$/i, "$1s"],
1949
+ [/([^l]ias|[aeiou]las|[ejzr]as|[iu]am)$/i, "$1"],
1950
+ [/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i, "$1i"],
1951
+ [/(alumn|alg|vertebr)(?:a|ae)$/i, "$1ae"],
1952
+ [/(seraph|cherub)(?:im)?$/i, "$1im"],
1953
+ [/(her|at|gr)o$/i, "$1oes"],
1954
+ [/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|automat|quor)(?:a|um)$/i, "$1a"],
1955
+ [/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)(?:a|on)$/i, "$1a"],
1956
+ [/sis$/i, "ses"],
1957
+ [/(?:(kni|wi|li)fe|(ar|l|ea|eo|oa|hoo)f)$/i, "$1$2ves"],
1958
+ [/([^aeiouy]|qu)y$/i, "$1ies"],
1959
+ [/([^ch][ieo][ln])ey$/i, "$1ies"],
1960
+ [/(x|ch|ss|sh|zz)$/i, "$1es"],
1961
+ [/(matr|cod|mur|sil|vert|ind|append)(?:ix|ex)$/i, "$1ices"],
1962
+ [/\b((?:tit)?m|l)(?:ice|ouse)$/i, "$1ice"],
1963
+ [/(pe)(?:rson|ople)$/i, "$1ople"],
1964
+ [/(child)(?:ren)?$/i, "$1ren"],
1965
+ [/eaux$/i, "$0"],
1966
+ [/m[ae]n$/i, "men"],
1967
+ ["thou", "you"]
1968
+ ].forEach(function(rule) {
1969
+ return pluralize2.addPluralRule(rule[0], rule[1]);
1970
+ });
1971
+ [
1972
+ [/s$/i, ""],
1973
+ [/(ss)$/i, "$1"],
1974
+ [/(wi|kni|(?:after|half|high|low|mid|non|night|[^\w]|^)li)ves$/i, "$1fe"],
1975
+ [/(ar|(?:wo|[ae])l|[eo][ao])ves$/i, "$1f"],
1976
+ [/ies$/i, "y"],
1977
+ [/\b([pl]|zomb|(?:neck|cross)?t|coll|faer|food|gen|goon|group|lass|talk|goal|cut)ies$/i, "$1ie"],
1978
+ [/\b(mon|smil)ies$/i, "$1ey"],
1979
+ [/\b((?:tit)?m|l)ice$/i, "$1ouse"],
1980
+ [/(seraph|cherub)im$/i, "$1"],
1981
+ [/(x|ch|ss|sh|zz|tto|go|cho|alias|[^aou]us|t[lm]as|gas|(?:her|at|gr)o|[aeiou]ris)(?:es)?$/i, "$1"],
1982
+ [/(analy|diagno|parenthe|progno|synop|the|empha|cri|ne)(?:sis|ses)$/i, "$1sis"],
1983
+ [/(movie|twelve|abuse|e[mn]u)s$/i, "$1"],
1984
+ [/(test)(?:is|es)$/i, "$1is"],
1985
+ [/(alumn|syllab|vir|radi|nucle|fung|cact|stimul|termin|bacill|foc|uter|loc|strat)(?:us|i)$/i, "$1us"],
1986
+ [/(agend|addend|millenni|dat|extrem|bacteri|desiderat|strat|candelabr|errat|ov|symposi|curricul|quor)a$/i, "$1um"],
1987
+ [/(apheli|hyperbat|periheli|asyndet|noumen|phenomen|criteri|organ|prolegomen|hedr|automat)a$/i, "$1on"],
1988
+ [/(alumn|alg|vertebr)ae$/i, "$1a"],
1989
+ [/(cod|mur|sil|vert|ind)ices$/i, "$1ex"],
1990
+ [/(matr|append)ices$/i, "$1ix"],
1991
+ [/(pe)(rson|ople)$/i, "$1rson"],
1992
+ [/(child)ren$/i, "$1"],
1993
+ [/(eau)x?$/i, "$1"],
1994
+ [/men$/i, "man"]
1995
+ ].forEach(function(rule) {
1996
+ return pluralize2.addSingularRule(rule[0], rule[1]);
1997
+ });
1998
+ [
1999
+ // Singular words with no plurals.
2000
+ "adulthood",
2001
+ "advice",
2002
+ "agenda",
2003
+ "aid",
2004
+ "aircraft",
2005
+ "alcohol",
2006
+ "ammo",
2007
+ "analytics",
2008
+ "anime",
2009
+ "athletics",
2010
+ "audio",
2011
+ "bison",
2012
+ "blood",
2013
+ "bream",
2014
+ "buffalo",
2015
+ "butter",
2016
+ "carp",
2017
+ "cash",
2018
+ "chassis",
2019
+ "chess",
2020
+ "clothing",
2021
+ "cod",
2022
+ "commerce",
2023
+ "cooperation",
2024
+ "corps",
2025
+ "debris",
2026
+ "diabetes",
2027
+ "digestion",
2028
+ "elk",
2029
+ "energy",
2030
+ "equipment",
2031
+ "excretion",
2032
+ "expertise",
2033
+ "firmware",
2034
+ "flounder",
2035
+ "fun",
2036
+ "gallows",
2037
+ "garbage",
2038
+ "graffiti",
2039
+ "hardware",
2040
+ "headquarters",
2041
+ "health",
2042
+ "herpes",
2043
+ "highjinks",
2044
+ "homework",
2045
+ "housework",
2046
+ "information",
2047
+ "jeans",
2048
+ "justice",
2049
+ "kudos",
2050
+ "labour",
2051
+ "literature",
2052
+ "machinery",
2053
+ "mackerel",
2054
+ "mail",
2055
+ "media",
2056
+ "mews",
2057
+ "moose",
2058
+ "music",
2059
+ "mud",
2060
+ "manga",
2061
+ "news",
2062
+ "only",
2063
+ "personnel",
2064
+ "pike",
2065
+ "plankton",
2066
+ "pliers",
2067
+ "police",
2068
+ "pollution",
2069
+ "premises",
2070
+ "rain",
2071
+ "research",
2072
+ "rice",
2073
+ "salmon",
2074
+ "scissors",
2075
+ "series",
2076
+ "sewage",
2077
+ "shambles",
2078
+ "shrimp",
2079
+ "software",
2080
+ "species",
2081
+ "staff",
2082
+ "swine",
2083
+ "tennis",
2084
+ "traffic",
2085
+ "transportation",
2086
+ "trout",
2087
+ "tuna",
2088
+ "wealth",
2089
+ "welfare",
2090
+ "whiting",
2091
+ "wildebeest",
2092
+ "wildlife",
2093
+ "you",
2094
+ /pok[eé]mon$/i,
2095
+ // Regexes.
2096
+ /[^aeiou]ese$/i,
2097
+ // "chinese", "japanese"
2098
+ /deer$/i,
2099
+ // "deer", "reindeer"
2100
+ /fish$/i,
2101
+ // "fish", "blowfish", "angelfish"
2102
+ /measles$/i,
2103
+ /o[iu]s$/i,
2104
+ // "carnivorous"
2105
+ /pox$/i,
2106
+ // "chickpox", "smallpox"
2107
+ /sheep$/i
2108
+ ].forEach(pluralize2.addUncountableRule);
2109
+ return pluralize2;
2110
+ });
2111
+ })(pluralize$1, pluralize$1.exports);
2112
+ var pluralizeExports = pluralize$1.exports;
2113
+ const pluralizePkg = /* @__PURE__ */ getDefaultExportFromCjs(pluralizeExports);
2114
+ const magicSplit = /^[a-zà-öø-ÿа-я]+|[A-ZÀ-ÖØ-ßА-Я][a-zà-öø-ÿа-я]+|[a-zà-öø-ÿа-я]+|[0-9]+|[A-ZÀ-ÖØ-ßА-Я]+(?![a-zà-öø-ÿа-я])/g;
2115
+ const spaceSplit = /\S+/g;
2116
+ function getPartsAndIndexes(string2, splitRegex) {
2117
+ const result = { parts: [], prefixes: [] };
2118
+ const matches = string2.matchAll(splitRegex);
2119
+ let lastWordEndIndex = 0;
2120
+ for (const match of matches) {
2121
+ if (typeof match.index !== "number")
2122
+ continue;
2123
+ const word = match[0];
2124
+ result.parts.push(word);
2125
+ const prefix = string2.slice(lastWordEndIndex, match.index).trim();
2126
+ result.prefixes.push(prefix);
2127
+ lastWordEndIndex = match.index + word.length;
2128
+ }
2129
+ const tail = string2.slice(lastWordEndIndex).trim();
2130
+ if (tail) {
2131
+ result.parts.push("");
2132
+ result.prefixes.push(tail);
2133
+ }
2134
+ return result;
2135
+ }
2136
+ function splitAndPrefix(string2, options) {
2137
+ const { keepSpecialCharacters = false, keep, prefix = "" } = options || {};
2138
+ const normalString = string2.trim().normalize("NFC");
2139
+ const hasSpaces = normalString.includes(" ");
2140
+ const split = hasSpaces ? spaceSplit : magicSplit;
2141
+ const partsAndIndexes = getPartsAndIndexes(normalString, split);
2142
+ return partsAndIndexes.parts.map((_part, i) => {
2143
+ let foundPrefix = partsAndIndexes.prefixes[i] || "";
2144
+ let part = _part;
2145
+ if (keepSpecialCharacters === false) {
2146
+ if (keep) {
2147
+ part = part.normalize("NFD").replace(new RegExp(`[^a-zA-ZØßø0-9${keep.join("")}]`, "g"), "");
2148
+ }
2149
+ if (!keep) {
2150
+ part = part.normalize("NFD").replace(/[^a-zA-ZØßø0-9]/g, "");
2151
+ foundPrefix = "";
2152
+ }
2153
+ }
2154
+ if (keep && foundPrefix) {
2155
+ foundPrefix = foundPrefix.replace(new RegExp(`[^${keep.join("")}]`, "g"), "");
2156
+ }
2157
+ if (i === 0) {
2158
+ return foundPrefix + part;
2159
+ }
2160
+ if (!foundPrefix && !part)
2161
+ return "";
2162
+ if (!hasSpaces) {
2163
+ return (foundPrefix || prefix) + part;
2164
+ }
2165
+ if (!foundPrefix && prefix.match(/\s/)) {
2166
+ return " " + part;
2167
+ }
2168
+ return (foundPrefix || prefix) + part;
2169
+ }).filter(Boolean);
2170
+ }
2171
+ function capitaliseWord(string2) {
2172
+ const match = string2.matchAll(magicSplit).next().value;
2173
+ const firstLetterIndex = match ? match.index : 0;
2174
+ return string2.slice(0, firstLetterIndex + 1).toUpperCase() + string2.slice(firstLetterIndex + 1).toLowerCase();
2175
+ }
2176
+ function camelCase(string2, options) {
2177
+ return splitAndPrefix(string2, options).reduce((result, word, index) => {
2178
+ return index === 0 || !(word[0] || "").match(magicSplit) ? result + word.toLowerCase() : result + capitaliseWord(word);
2179
+ }, "");
2180
+ }
2181
+ function pascalCase(string2, options) {
2182
+ return splitAndPrefix(string2, options).reduce((result, word) => {
2183
+ return result + capitaliseWord(word);
2184
+ }, "");
2185
+ }
2186
+ function kebabCase(string2, options) {
2187
+ return splitAndPrefix(string2, { ...options, prefix: "-" }).join("").toLowerCase();
2188
+ }
2189
+ function snakeCase(string2, options) {
2190
+ return splitAndPrefix(string2, { ...options, prefix: "_" }).join("").toLowerCase();
2191
+ }
2192
+ function trainCase(string2, options) {
2193
+ return splitAndPrefix(string2, { ...options, prefix: "-" }).map((word) => capitaliseWord(word)).join("");
2194
+ }
2195
+ function dotNotation(string2, options) {
2196
+ return splitAndPrefix(string2, { ...options, prefix: "." }).join("");
2197
+ }
2198
+ function capitalCase(string2, options = { keepSpecialCharacters: true }) {
2199
+ return splitAndPrefix(string2, { ...options, prefix: " " }).reduce((result, word) => {
2200
+ return result + capitaliseWord(word);
2201
+ }, "");
2202
+ }
2203
+ var bytes_default = {
2204
+ /**
2205
+ * Formats bytes to a human-readable string value. When input cannot be formatted, the `null` value is returned. The accepted options are as follows.
2206
+ *
2207
+ - `decimalPlaces`: Maximum number of decimal places to include in output. `default=2`.
2208
+ - `fixedDecimals`: Whether to always display the maximum number of decimal places. `default=false`.
2209
+ - `thousandsSeparator`: Specify the separator for thousands. `default=''`.
2210
+ - `unit`: The unit in which the result will be returned. It could be `B/KB/MB/GB/TB`. The default behavior is to auto-detect based on the input.
2211
+ - `unitSeparator`: The separator between the value and the `unit`. `default=''`.
2212
+ */
2213
+ format(valueInBytes, options) {
2214
+ return bytes$1.format(valueInBytes, options);
2215
+ },
2216
+ /**
2217
+ * Parse a human-readable string expression to bytes. If the unit value is a number, it will be
2218
+ * returned as it is. Otherwise, the string expression will be converted to a number representing
2219
+ * bytes.
2220
+ *
2221
+ * The `null` value is returned when the input cannot be parsed.
2222
+ *
2223
+ * Supported units and abbreviations are as follows and are case-insensitive:
2224
+ - `b` for bytes
2225
+ - `kb` for kilobytes
2226
+ - `mb` for megabytes
2227
+ - `gb` for gigabytes
2228
+ - `tb` for terabytes
2229
+ - `pb` for petabytes
2230
+ */
2231
+ parse(unit) {
2232
+ if (typeof unit === "number") {
2233
+ return unit;
2234
+ }
2235
+ return bytes$1.parse(unit);
2236
+ }
2237
+ };
2238
+ var uuidGenerator = crypto.randomUUID;
2239
+ function uuid(options) {
2240
+ return uuidGenerator(options);
2241
+ }
2242
+ uuid.use = function uuidUse(generator) {
2243
+ uuidGenerator = generator;
2244
+ };
2245
+ uuid.restore = function uuidRestore() {
2246
+ uuidGenerator = crypto.randomUUID;
2247
+ };
2248
+ var seconds_default = {
2249
+ /**
2250
+ * Formats seconds to pretty string output
2251
+ */
2252
+ format(seconds, long) {
2253
+ return format(seconds * 1e3, long);
2254
+ },
2255
+ /**
2256
+ * Parse the time expression to seconds. If the unit value is a number, then
2257
+ * it will be returned as it is. Otherwise the string expression will be
2258
+ * converted to a number representing seconds.
2259
+ */
2260
+ parse(duration) {
2261
+ if (typeof duration === "number") {
2262
+ return duration;
2263
+ }
2264
+ const milliseconds = parse(duration);
2265
+ if (milliseconds === void 0) {
2266
+ throw new Error(`Invalid duration expression "${duration}"`);
2267
+ }
2268
+ return Math.floor(milliseconds / 1e3);
2269
+ }
2270
+ };
2271
+ var slug = slugifyPkg;
2272
+ var defaultGenerator = (size) => {
2273
+ const bits = (size + 1) * 6;
2274
+ const buffer = crypto.randomBytes(Math.ceil(bits / 8));
2275
+ return Buffer.from(buffer).toString("base64").replace(/\+/g, "-").replace(/\//g, "_").replace(/\=/g, "").slice(0, size);
2276
+ };
2277
+ var randomGenerator = defaultGenerator;
2278
+ function random(size) {
2279
+ return randomGenerator(size);
2280
+ }
2281
+ random.use = function randomUse(generator) {
2282
+ randomGenerator = generator;
2283
+ };
2284
+ random.restore = function randomRestore() {
2285
+ randomGenerator = defaultGenerator;
2286
+ };
2287
+ function excerpt(sentence2, charactersLimit, options) {
2288
+ return truncatise2(sentence2, {
2289
+ TruncateLength: charactersLimit,
2290
+ /**
2291
+ * Do not complete words when "completeWords" is not explicitly set
2292
+ * to true
2293
+ */
2294
+ Strict: options && options.completeWords === true ? false : true,
2295
+ StripHTML: true,
2296
+ TruncateBy: "characters",
2297
+ Suffix: options && options.suffix
2298
+ });
2299
+ }
2300
+ function applyPadding(value, options) {
2301
+ if (options.paddingLeft) {
2302
+ value = `${options.paddingChar.repeat(options.paddingLeft)}${value}`;
2303
+ }
2304
+ if (options.paddingRight) {
2305
+ value = `${value}${options.paddingChar.repeat(options.paddingRight)}`;
2306
+ }
2307
+ return value;
2308
+ }
2309
+ function justify(columns, options) {
2310
+ const normalizedOptions = {
2311
+ align: "left",
2312
+ indent: " ",
2313
+ ...options
2314
+ };
2315
+ return columns.map((column) => {
2316
+ var _a2;
2317
+ const columnWidth = ((_a2 = options.getLength) == null ? void 0 : _a2.call(options, column)) ?? column.length;
2318
+ if (columnWidth >= normalizedOptions.width) {
2319
+ return column;
2320
+ }
2321
+ if (normalizedOptions.align === "left") {
2322
+ return applyPadding(column, {
2323
+ paddingChar: normalizedOptions.indent,
2324
+ paddingRight: normalizedOptions.width - columnWidth
2325
+ });
2326
+ }
2327
+ return applyPadding(column, {
2328
+ paddingChar: normalizedOptions.indent,
2329
+ paddingLeft: normalizedOptions.width - columnWidth
2330
+ });
2331
+ });
2332
+ }
2333
+ function ordinal(value) {
2334
+ const transformedValue = Math.abs(typeof value === "string" ? Number.parseInt(value) : value);
2335
+ if (!Number.isFinite(transformedValue) || Number.isNaN(transformedValue)) {
2336
+ throw new Error("Cannot ordinalize invalid or infinite numbers");
2337
+ }
2338
+ const percent = transformedValue % 100;
2339
+ if (percent >= 10 && percent <= 20) {
2340
+ return `${value}th`;
2341
+ }
2342
+ const decimal = transformedValue % 10;
2343
+ switch (decimal) {
2344
+ case 1:
2345
+ return `${value}st`;
2346
+ case 2:
2347
+ return `${value}nd`;
2348
+ case 3:
2349
+ return `${value}rd`;
2350
+ default:
2351
+ return `${value}th`;
2352
+ }
2353
+ }
2354
+ function truncate(sentence2, charactersLimit, options) {
2355
+ return truncatise2(sentence2, {
2356
+ TruncateLength: charactersLimit,
2357
+ /**
2358
+ * Do not complete words when "completeWords" is not explicitly set
2359
+ * to true
2360
+ */
2361
+ Strict: options && options.completeWords === true ? false : true,
2362
+ StripHTML: false,
2363
+ TruncateBy: "characters",
2364
+ Suffix: options && options.suffix
2365
+ });
2366
+ }
2367
+ function sentence(values, options) {
2368
+ if (values.length === 0) {
2369
+ return "";
2370
+ }
2371
+ if (values.length === 1) {
2372
+ return values[0];
2373
+ }
2374
+ if (values.length === 2) {
2375
+ return `${values[0]}${(options == null ? void 0 : options.pairSeparator) || " and "}${values[1]}`;
2376
+ }
2377
+ const normalized = Object.assign({ separator: ", ", lastSeparator: ", and " }, options);
2378
+ return `${values.slice(0, -1).join(normalized.separator)}${normalized.lastSeparator}${values[values.length - 1]}`;
2379
+ }
2380
+ function wordWrap(value, options) {
2381
+ const width = options.width;
2382
+ const indent = options.indent ?? "";
2383
+ const newLine = `${options.newLine ?? "\n"}${indent}`;
2384
+ let regexString = ".{1," + width + "}";
2385
+ regexString += "([\\s​]+|$)|[^\\s​]+?([\\s​]+|$)";
2386
+ const re = new RegExp(regexString, "g");
2387
+ const lines = value.match(re) || [];
2388
+ const result = lines.map(function(line) {
2389
+ if (line.slice(-1) === "\n") {
2390
+ line = line.slice(0, line.length - 1);
2391
+ }
2392
+ return options.escape ? options.escape(line) : line;
2393
+ }).join(newLine);
2394
+ return result;
2395
+ }
2396
+ var milliseconds_default = {
2397
+ /**
2398
+ * Formats milliseconds to pretty string output
2399
+ */
2400
+ format(milliseconds, long) {
2401
+ return format(milliseconds, long);
2402
+ },
2403
+ /**
2404
+ * Parse the time expression to milliseconds. If the unit value is a number,
2405
+ * then it will be returned as it is. Otherwise the string expression will
2406
+ * be converted to a number representing seconds.
2407
+ */
2408
+ parse(duration) {
2409
+ if (typeof duration === "number") {
2410
+ return duration;
2411
+ }
2412
+ const milliseconds = parse(duration);
2413
+ if (milliseconds === void 0) {
2414
+ throw new Error(`Invalid duration expression "${duration}"`);
2415
+ }
2416
+ return milliseconds;
2417
+ }
2418
+ };
2419
+ function htmlEscape(value) {
2420
+ return value.replace(/&/g, "&amp;").replace(/"/g, "&quot;").replace(/'/g, "&#39;").replace(/</g, "&lt;").replace(/>/g, "&gt;");
2421
+ }
2422
+ function parseProp(data, key) {
2423
+ const tokens = key.split(".");
2424
+ while (tokens.length) {
2425
+ if (data === null || typeof data !== "object") {
2426
+ return;
2427
+ }
2428
+ const token = tokens.shift();
2429
+ data = Object.hasOwn(data, token) ? data[token] : void 0;
2430
+ }
2431
+ return data;
2432
+ }
2433
+ function interpolate(input, data) {
2434
+ return input.replace(/(\\)?{{(.*?)}}/g, (_, escapeChar, key) => {
2435
+ if (escapeChar) {
2436
+ return `{{${key}}}`;
2437
+ }
2438
+ return parseProp(data, key.trim());
2439
+ });
2440
+ }
2441
+ function toUnixSlash(path) {
2442
+ const isExtendedLengthPath = path.startsWith("\\\\?\\");
2443
+ if (isExtendedLengthPath) {
2444
+ return path;
2445
+ }
2446
+ return path.replace(/\\/g, "/");
2447
+ }
2448
+ function pluralize(word, count, inclusive) {
2449
+ return pluralizePkg(word, count, inclusive);
2450
+ }
2451
+ pluralize.addPluralRule = pluralizePkg.addPluralRule;
2452
+ pluralize.addSingularRule = pluralizePkg.addSingularRule;
2453
+ pluralize.addIrregularRule = pluralizePkg.addIrregularRule;
2454
+ pluralize.addUncountableRule = pluralizePkg.addUncountableRule;
2455
+ var plural = pluralizePkg.plural;
2456
+ var singular = pluralizePkg.singular;
2457
+ var isPlural = pluralizePkg.isPlural;
2458
+ var isSingular = pluralizePkg.isSingular;
2459
+ var NO_CASE_SPLIT_REGEXP = [/([a-z0-9])([A-Z])/g, /([A-Z])([A-Z][a-z])/g];
2460
+ var NO_CASE_STRIP_REGEXP = /[^A-Z0-9]+/gi;
2461
+ var SMALL_WORDS = /\b(?:an?d?|a[st]|because|but|by|en|for|i[fn]|neither|nor|o[fnr]|only|over|per|so|some|tha[tn]|the|to|up|upon|vs?\.?|versus|via|when|with|without|yet)\b/i;
2462
+ var TOKENS = /[^\s:–—-]+|./g;
2463
+ var WHITESPACE = /\s/;
2464
+ var IS_MANUAL_CASE = /.(?=[A-Z]|\..)/;
2465
+ var ALPHANUMERIC_PATTERN = /[A-Za-z0-9\u00C0-\u00FF]/;
2466
+ function titleCase(input) {
2467
+ let output = "";
2468
+ let result;
2469
+ while ((result = TOKENS.exec(input)) !== null) {
2470
+ const { 0: token, index } = result;
2471
+ if (!IS_MANUAL_CASE.test(token) && (!SMALL_WORDS.test(token) || index === 0 || index + token.length === input.length) && (input.charAt(index + token.length) !== ":" || WHITESPACE.test(input.charAt(index + token.length + 1)))) {
2472
+ output += token.replace(ALPHANUMERIC_PATTERN, (char) => char.toUpperCase());
2473
+ continue;
2474
+ }
2475
+ output += token;
2476
+ }
2477
+ return output;
2478
+ }
2479
+ function camelCase2(value) {
2480
+ return camelCase(value);
2481
+ }
2482
+ function snakeCase2(value) {
2483
+ return snakeCase(value);
2484
+ }
2485
+ function dashCase(value, options) {
2486
+ if (options && options.capitalize) {
2487
+ return trainCase(value);
2488
+ }
2489
+ return kebabCase(value);
2490
+ }
2491
+ function pascalCase2(value) {
2492
+ return pascalCase(value);
2493
+ }
2494
+ function capitalCase2(value) {
2495
+ return capitalCase(value);
2496
+ }
2497
+ function sentenceCase(value) {
2498
+ return noCase(value, (input, index) => {
2499
+ const result = input.toLowerCase();
2500
+ if (index === 0) {
2501
+ return input.charAt(0).toUpperCase() + input.substring(1);
2502
+ }
2503
+ return result;
2504
+ });
2505
+ }
2506
+ function dotCase(value, options) {
2507
+ const transformedValue = dotNotation(value);
2508
+ if (options && options.lowerCase) {
2509
+ return transformedValue.toLowerCase();
2510
+ }
2511
+ return transformedValue;
2512
+ }
2513
+ function noCase(value, transform) {
2514
+ let result = NO_CASE_SPLIT_REGEXP.reduce((input, regex) => input.replace(regex, "$1\0$2"), value);
2515
+ result = result.replace(NO_CASE_STRIP_REGEXP, "\0");
2516
+ let start = 0;
2517
+ let end = result.length;
2518
+ while (result.charAt(start) === "\0") {
2519
+ start++;
2520
+ }
2521
+ while (result.charAt(end - 1) === "\0") {
2522
+ end--;
2523
+ }
2524
+ return result.slice(start, end).split("\0").map(transform || ((input) => input.toLowerCase())).join(" ");
2525
+ }
2526
+ function condenseWhitespace(value) {
2527
+ return value.trim().replace(/\s{2,}/g, " ");
2528
+ }
2529
+ var string = {
2530
+ excerpt,
2531
+ truncate,
2532
+ slug,
2533
+ interpolate,
2534
+ plural,
2535
+ pluralize,
2536
+ singular,
2537
+ isPlural,
2538
+ isSingular,
2539
+ camelCase: camelCase2,
2540
+ capitalCase: capitalCase2,
2541
+ dashCase,
2542
+ dotCase,
2543
+ noCase,
2544
+ pascalCase: pascalCase2,
2545
+ sentenceCase,
2546
+ snakeCase: snakeCase2,
2547
+ titleCase,
2548
+ random,
2549
+ sentence,
2550
+ condenseWhitespace,
2551
+ wordWrap,
2552
+ seconds: seconds_default,
2553
+ milliseconds: milliseconds_default,
2554
+ bytes: bytes_default,
2555
+ ordinal,
2556
+ htmlEscape,
2557
+ justify,
2558
+ uuid,
2559
+ toUnixSlash
2560
+ };
2561
+ exports.index_default = string;
2562
+ var ObjectBuilder = (_a = class {
2563
+ constructor(initialValue, ignoreNull) {
2564
+ __privateAdd(this, _ignoreNull);
2565
+ __publicField(this, "values");
2566
+ this.values = initialValue;
2567
+ __privateSet(this, _ignoreNull, ignoreNull === true ? true : false);
2568
+ }
2569
+ add(key, value) {
2570
+ if (value === void 0) {
2571
+ return this;
2572
+ }
2573
+ if (__privateGet(this, _ignoreNull) === true && value === null) {
2574
+ return this;
2575
+ }
2576
+ this.values[key] = value;
2577
+ return this;
2578
+ }
2579
+ /**
2580
+ * Remove key from the object
2581
+ */
2582
+ remove(key) {
2583
+ delete this.values[key];
2584
+ return this;
2585
+ }
2586
+ /**
2587
+ * Find if a value exists
2588
+ */
2589
+ has(key) {
2590
+ return this.get(key) !== void 0;
2591
+ }
2592
+ /**
2593
+ * Get the existing value for a given key
2594
+ */
2595
+ get(key) {
2596
+ return this.values[key];
2597
+ }
2598
+ /**
2599
+ * Get the underlying constructed object
2600
+ */
2601
+ toObject() {
2602
+ return this.values;
2603
+ }
2604
+ }, _ignoreNull = new WeakMap(), _a);
2605
+ const object_builder_star = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2606
+ __proto__: null,
2607
+ get ObjectBuilder() {
2608
+ return ObjectBuilder;
2609
+ }
2610
+ }, Symbol.toStringTag, { value: "Module" }));
2611
+ var Base64 = class {
2612
+ encode(data, encoding) {
2613
+ if (typeof data === "string") {
2614
+ return Buffer.from(data, encoding).toString("base64");
2615
+ }
2616
+ if (Buffer.isBuffer(data)) {
2617
+ return data.toString("base64");
2618
+ }
2619
+ return Buffer.from(data).toString("base64");
2620
+ }
2621
+ decode(encoded, encoding = "utf-8", strict = false) {
2622
+ if (Buffer.isBuffer(encoded)) {
2623
+ return encoded.toString(encoding);
2624
+ }
2625
+ const decoded = Buffer.from(encoded, "base64").toString(encoding);
2626
+ const isInvalid = this.encode(decoded, encoding) !== encoded;
2627
+ if (strict && isInvalid) {
2628
+ throw new Error("Cannot decode malformed value");
2629
+ }
2630
+ return isInvalid ? null : decoded;
2631
+ }
2632
+ urlEncode(data, encoding) {
2633
+ const encoded = typeof data === "string" ? this.encode(data, encoding) : this.encode(data);
2634
+ return encoded.replace(/\+/g, "-").replace(/\//g, "_").replace(/\=/g, "");
2635
+ }
2636
+ urlDecode(encoded, encoding = "utf-8", strict = false) {
2637
+ if (Buffer.isBuffer(encoded)) {
2638
+ return encoded.toString(encoding);
2639
+ }
2640
+ const decoded = Buffer.from(encoded, "base64").toString(encoding);
2641
+ const isInvalid = this.urlEncode(decoded, encoding) !== encoded;
2642
+ if (strict && isInvalid) {
2643
+ throw new Error("Cannot urlDecode malformed value");
2644
+ }
2645
+ return isInvalid ? null : decoded;
2646
+ }
2647
+ };
2648
+ new Base64();
2649
+ function defineStaticProperty(self2, propertyName, {
2650
+ initialValue,
2651
+ strategy
2652
+ }) {
2653
+ if (!self2.hasOwnProperty(propertyName)) {
2654
+ const value = self2[propertyName];
2655
+ if (strategy === "define" || value === void 0) {
2656
+ Object.defineProperty(self2, propertyName, {
2657
+ value: initialValue,
2658
+ configurable: true,
2659
+ enumerable: true,
2660
+ writable: true
2661
+ });
2662
+ return;
2663
+ }
2664
+ Object.defineProperty(self2, propertyName, {
2665
+ value: typeof strategy === "function" ? strategy(value) : lodash.cloneDeep(value),
2666
+ configurable: true,
2667
+ enumerable: true,
2668
+ writable: true
2669
+ });
2670
+ }
2671
+ }
2672
+ var object_builder_exports = {};
2673
+ __reExport(object_builder_exports, object_builder_star);
2674
+ object_builder_exports.ObjectBuilder;
2675
+ const messageFromJoiValidationError = (reason, fallback) => {
2676
+ return reason ? reason.details.map((d) => d.message).join(" and ") : fallback;
2677
+ };
2678
+ class E_INVALID_RESOURCEFUL_DATA_TYPE_OPTIONS extends exports.Exception {
2679
+ constructor(name, reason) {
2680
+ const msg = `Invalid Options for "${name}": ` + messageFromJoiValidationError(
2681
+ reason,
2682
+ "The options provided are not compatible with the data type"
2683
+ );
2684
+ super(msg, {
2685
+ code: "E_INVALID_RESOURCEFUL_DATA_TYPE_OPTIONS",
2686
+ status: 500,
2687
+ cause: reason
2688
+ });
2689
+ Object.defineProperty(this, "details", {
2690
+ value: reason == null ? void 0 : reason.details,
2691
+ enumerable: true,
2692
+ writable: false,
2693
+ configurable: false
2694
+ });
2695
+ }
2696
+ }
2697
+ __publicField(E_INVALID_RESOURCEFUL_DATA_TYPE_OPTIONS, "status", 500);
2698
+ __publicField(E_INVALID_RESOURCEFUL_DATA_TYPE_OPTIONS, "code", "E_INVALID_RESOURCEFUL_DATA_TYPE_OPTIONS");
2699
+ class E_INVALID_RESOURCEFUL_MIXIN_OPTIONS extends exports.Exception {
2700
+ constructor(name, reason) {
2701
+ const msg = `Invalid 'withResourceful' options for "${name}": ` + messageFromJoiValidationError(
2702
+ reason,
2703
+ "The options provided are not compatible with the withResourceful mixin"
2704
+ );
2705
+ super(msg, {
2706
+ code: "E_INVALID_RESOURCEFUL_MIXIN_OPTIONS",
2707
+ status: 500,
2708
+ cause: reason
2709
+ });
2710
+ Object.defineProperty(this, "details", {
2711
+ value: reason == null ? void 0 : reason.details,
2712
+ enumerable: true,
2713
+ writable: false,
2714
+ configurable: false
2715
+ });
2716
+ }
2717
+ }
2718
+ __publicField(E_INVALID_RESOURCEFUL_MIXIN_OPTIONS, "status", 500);
2719
+ __publicField(E_INVALID_RESOURCEFUL_MIXIN_OPTIONS, "code", "E_INVALID_RESOURCEFUL_MIXIN_OPTIONS");
2720
+ const E_INVALID_PREPARED_VALUE = createError(
2721
+ "E_INVALID_PREPARED_VALUE",
2722
+ 'The value for "%s" is not a valid %s',
2723
+ 422
2724
+ );
2725
+ const E_INVALID_CONSUMED_VALUE = createError(
2726
+ "E_INVALID_CONSUMED_VALUE",
2727
+ 'The value for "%s" could not be consumed as a valid %s',
2728
+ 500
2729
+ );
2730
+ const E_UNCASTABLE = createError(
2731
+ "E_UNCASTABLE",
2732
+ "The value could not be cast to a valid %s",
2733
+ 500
2734
+ );
2735
+ class E_INVALID_RESOURCEFUL_DECORATOR_OPTIONS extends exports.Exception {
2736
+ constructor(decoratorName, fieldName, reason) {
2737
+ const msg = `Invalid "@${decoratorName}" Options for "${fieldName}": ` + messageFromJoiValidationError(
2738
+ reason,
2739
+ "The options provided are not compatible with the decorator's requirements"
2740
+ );
2741
+ super(msg, {
2742
+ code: "E_INVALID_RESOURCEFUL_DECORATOR_OPTIONS",
2743
+ status: 500,
2744
+ cause: reason
2745
+ });
2746
+ Object.defineProperty(this, "details", {
2747
+ value: reason == null ? void 0 : reason.details,
2748
+ enumerable: true,
2749
+ writable: false,
2750
+ configurable: false
2751
+ });
2752
+ }
2753
+ }
2754
+ __publicField(E_INVALID_RESOURCEFUL_DECORATOR_OPTIONS, "status", 500);
2755
+ __publicField(E_INVALID_RESOURCEFUL_DECORATOR_OPTIONS, "code", "E_INVALID_RESOURCEFUL_DECORATOR_OPTIONS");
2756
+ class E_FORBIDDEN extends exports.Exception {
2757
+ constructor(message) {
2758
+ const msg = message;
2759
+ super(msg, {
2760
+ code: "E_FORBIDDEN",
2761
+ status: 403
2762
+ });
2763
+ Object.defineProperty(this, "details", {
2764
+ value: msg,
2765
+ enumerable: true,
2766
+ writable: false,
2767
+ configurable: false
2768
+ });
2769
+ }
2770
+ }
2771
+ __publicField(E_FORBIDDEN, "status", 403);
2772
+ __publicField(E_FORBIDDEN, "code", "E_FORBIDDEN");
2773
+ class E_INVALID_LUCENE_QUERY extends exports.Exception {
2774
+ constructor(message) {
2775
+ const msg = `Invalid Lucene query: ${message}`;
2776
+ super(msg, {
2777
+ code: "E_INVALID_LUCENE_QUERY",
2778
+ status: 400
2779
+ });
2780
+ Object.defineProperty(this, "details", {
2781
+ value: msg,
2782
+ enumerable: true,
2783
+ writable: false,
2784
+ configurable: false
2785
+ });
2786
+ }
2787
+ }
2788
+ __publicField(E_INVALID_LUCENE_QUERY, "status", 400);
2789
+ __publicField(E_INVALID_LUCENE_QUERY, "code", "E_INVALID_LUCENE_QUERY");
2790
+ class E_INVALID_COLUMN_ACCESS extends exports.Exception {
2791
+ constructor(columnName) {
2792
+ const msg = `You don't have access to column "${columnName}" or the column does not exist.`;
2793
+ super(msg, {
2794
+ code: "E_INVALID_COLUMN_ACCESS",
2795
+ status: 403
2796
+ });
2797
+ Object.defineProperty(this, "details", {
2798
+ value: msg,
2799
+ enumerable: true,
2800
+ writable: false,
2801
+ configurable: false
2802
+ });
2803
+ }
2804
+ }
2805
+ __publicField(E_INVALID_COLUMN_ACCESS, "status", 403);
2806
+ __publicField(E_INVALID_COLUMN_ACCESS, "code", "E_INVALID_COLUMN_ACCESS");
2807
+ class E_UNEXPECTED_COLUMN_IN_QUERY extends exports.Exception {
2808
+ constructor(columnName) {
2809
+ const msg = `Unexpected column in query: "${columnName}"`;
2810
+ super(msg, {
2811
+ code: "E_UNEXPECTED_COLUMN_IN_QUERY",
2812
+ status: 400
2813
+ });
2814
+ Object.defineProperty(this, "details", {
2815
+ value: msg,
2816
+ enumerable: true,
2817
+ writable: false,
2818
+ configurable: false
2819
+ });
2820
+ }
2821
+ }
2822
+ __publicField(E_UNEXPECTED_COLUMN_IN_QUERY, "status", 400);
2823
+ __publicField(E_UNEXPECTED_COLUMN_IN_QUERY, "code", "E_UNEXPECTED_COLUMN_IN_QUERY");
2824
+ class E_LUCENE_SYNTAX_EXCEPTION extends exports.Exception {
2825
+ constructor(original) {
2826
+ const msg = `${original.message} at line ${original.line}, column ${original.column}, offset ${original.offset}`;
2827
+ super(msg, {
2828
+ code: "E_LUCENE_SYNTAX_EXCEPTION",
2829
+ status: 422,
2830
+ cause: original
2831
+ });
2832
+ Object.defineProperty(this, "offset", {
2833
+ value: original.offset,
2834
+ enumerable: true,
2835
+ writable: false,
2836
+ configurable: false
2837
+ });
2838
+ Object.defineProperty(this, "line", {
2839
+ value: original.line,
2840
+ enumerable: true,
2841
+ writable: false,
2842
+ configurable: false
2843
+ });
2844
+ Object.defineProperty(this, "column", {
2845
+ value: original.column,
2846
+ enumerable: true,
2847
+ writable: false,
2848
+ configurable: false
2849
+ });
2850
+ }
2851
+ }
2852
+ __publicField(E_LUCENE_SYNTAX_EXCEPTION, "status", 422);
2853
+ __publicField(E_LUCENE_SYNTAX_EXCEPTION, "code", "E_LUCENE_SYNTAX_EXCEPTION");
2854
+ class E_LUCENE_UNEXPECTED_EXCEPTION extends exports.Exception {
2855
+ constructor(original) {
2856
+ const msg = `Unexpected error while processing Lucene query: ${original instanceof Error ? original.message : String(original)}`;
2857
+ super(msg, {
2858
+ code: "E_LUCENE_UNEXPECTED_EXCEPTION",
2859
+ status: 503,
2860
+ cause: original
2861
+ });
2862
+ }
2863
+ }
2864
+ __publicField(E_LUCENE_UNEXPECTED_EXCEPTION, "status", 503);
2865
+ __publicField(E_LUCENE_UNEXPECTED_EXCEPTION, "code", "E_LUCENE_UNEXPECTED_EXCEPTION");
2866
+ class E_LUCENE_INVALID_TYPE extends exports.Exception {
2867
+ constructor(type) {
2868
+ const msg = `"${type}" is not a valid Lucene AST type.`;
2869
+ super(msg, {
2870
+ code: "E_LUCENE_INVALID_TYPE",
2871
+ status: 503
2872
+ });
2873
+ }
2874
+ }
2875
+ __publicField(E_LUCENE_INVALID_TYPE, "status", 503);
2876
+ __publicField(E_LUCENE_INVALID_TYPE, "code", "E_LUCENE_INVALID_TYPE");
2877
+ class E_INVALID_RESOUREFUL_INDEX_REQUEST_EXCEPTION extends exports.Exception {
2878
+ constructor(reason) {
2879
+ super(messageFromJoiValidationError(reason, "Your request could not be fulfilled"), {
2880
+ code: "E_INVALID_RESOUREFUL_INDEX_REQUEST_EXCEPTION",
2881
+ status: 422,
2882
+ cause: reason
2883
+ });
2884
+ Object.defineProperty(this, "details", {
2885
+ value: reason == null ? void 0 : reason.details,
2886
+ enumerable: true,
2887
+ writable: false,
2888
+ configurable: false
2889
+ });
2890
+ }
2891
+ }
2892
+ __publicField(E_INVALID_RESOUREFUL_INDEX_REQUEST_EXCEPTION, "status", 422);
2893
+ __publicField(E_INVALID_RESOUREFUL_INDEX_REQUEST_EXCEPTION, "code", "E_INVALID_RESOUREFUL_INDEX_REQUEST_EXCEPTION");
2894
+ class E_MISSING_PRIMARY_KEY_EXCEPTION extends exports.Exception {
2895
+ constructor(type) {
2896
+ const msg = `"${type}" does not have a primary key defined`;
2897
+ super(msg, {
2898
+ code: "E_MISSING_PRIMARY_KEY_EXCEPTION",
2899
+ status: 503
2900
+ });
2901
+ }
2902
+ }
2903
+ __publicField(E_MISSING_PRIMARY_KEY_EXCEPTION, "status", 503);
2904
+ __publicField(E_MISSING_PRIMARY_KEY_EXCEPTION, "code", "E_MISSING_PRIMARY_KEY_EXCEPTION");
2905
+ class E_RECORD_NOT_FOUND_EXCEPTION extends exports.Exception {
2906
+ constructor() {
2907
+ const msg = `The record is not present or User doesn't have access to it.`;
2908
+ super(msg, {
2909
+ code: "E_RECORD_NOT_FOUND_EXCEPTION",
2910
+ status: 404
2911
+ });
2912
+ }
2913
+ }
2914
+ __publicField(E_RECORD_NOT_FOUND_EXCEPTION, "status", 404);
2915
+ __publicField(E_RECORD_NOT_FOUND_EXCEPTION, "code", "E_RECORD_NOT_FOUND_EXCEPTION");
2916
+ class E_INVALID_PAYLOAD_EXCEPTION extends exports.Exception {
2917
+ constructor(reason) {
2918
+ super(
2919
+ messageFromJoiValidationError(reason, "Your submission does not pass validation criteria"),
2920
+ {
2921
+ code: "E_INVALID_PAYLOAD_EXCEPTION",
2922
+ status: 422,
2923
+ cause: reason
2924
+ }
2925
+ );
2926
+ Object.defineProperty(this, "details", {
2927
+ value: reason == null ? void 0 : reason.details,
2928
+ enumerable: true,
2929
+ writable: false,
2930
+ configurable: false
2931
+ });
2932
+ }
2933
+ }
2934
+ __publicField(E_INVALID_PAYLOAD_EXCEPTION, "status", 422);
2935
+ __publicField(E_INVALID_PAYLOAD_EXCEPTION, "code", "E_INVALID_PAYLOAD_EXCEPTION");
2936
+ class E_FORBIDDEN_PAYLOAD_EXCEPTION extends exports.Exception {
2937
+ constructor(reason) {
2938
+ super(
2939
+ messageFromJoiValidationError(reason, "Your submission does not pass authorization criteria"),
2940
+ {
2941
+ code: "E_FORBIDDEN_PAYLOAD_EXCEPTION",
2942
+ status: 403,
2943
+ cause: reason
2944
+ }
2945
+ );
2946
+ Object.defineProperty(this, "details", {
2947
+ value: reason == null ? void 0 : reason.details,
2948
+ enumerable: true,
2949
+ writable: false,
2950
+ configurable: false
2951
+ });
2952
+ }
2953
+ }
2954
+ __publicField(E_FORBIDDEN_PAYLOAD_EXCEPTION, "status", 403);
2955
+ __publicField(E_FORBIDDEN_PAYLOAD_EXCEPTION, "code", "E_FORBIDDEN_PAYLOAD_EXCEPTION");
2956
+ const errors = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2957
+ __proto__: null,
2958
+ E_FORBIDDEN,
2959
+ E_FORBIDDEN_PAYLOAD_EXCEPTION,
2960
+ E_INVALID_COLUMN_ACCESS,
2961
+ E_INVALID_CONSUMED_VALUE,
2962
+ E_INVALID_LUCENE_QUERY,
2963
+ E_INVALID_PAYLOAD_EXCEPTION,
2964
+ E_INVALID_PREPARED_VALUE,
2965
+ E_INVALID_RESOURCEFUL_DATA_TYPE_OPTIONS,
2966
+ E_INVALID_RESOURCEFUL_DECORATOR_OPTIONS,
2967
+ E_INVALID_RESOURCEFUL_MIXIN_OPTIONS,
2968
+ E_INVALID_RESOUREFUL_INDEX_REQUEST_EXCEPTION,
2969
+ E_LUCENE_INVALID_TYPE,
2970
+ E_LUCENE_SYNTAX_EXCEPTION,
2971
+ E_LUCENE_UNEXPECTED_EXCEPTION,
2972
+ E_MISSING_PRIMARY_KEY_EXCEPTION,
2973
+ E_RECORD_NOT_FOUND_EXCEPTION,
2974
+ E_UNCASTABLE,
2975
+ E_UNEXPECTED_COLUMN_IN_QUERY
2976
+ }, Symbol.toStringTag, { value: "Module" }));
2977
+ exports.E_FORBIDDEN = E_FORBIDDEN;
2978
+ exports.E_FORBIDDEN_PAYLOAD_EXCEPTION = E_FORBIDDEN_PAYLOAD_EXCEPTION;
2979
+ exports.E_INVALID_COLUMN_ACCESS = E_INVALID_COLUMN_ACCESS;
2980
+ exports.E_INVALID_CONSUMED_VALUE = E_INVALID_CONSUMED_VALUE;
2981
+ exports.E_INVALID_LUCENE_QUERY = E_INVALID_LUCENE_QUERY;
2982
+ exports.E_INVALID_PAYLOAD_EXCEPTION = E_INVALID_PAYLOAD_EXCEPTION;
2983
+ exports.E_INVALID_PREPARED_VALUE = E_INVALID_PREPARED_VALUE;
2984
+ exports.E_INVALID_RESOURCEFUL_DATA_TYPE_OPTIONS = E_INVALID_RESOURCEFUL_DATA_TYPE_OPTIONS;
2985
+ exports.E_INVALID_RESOURCEFUL_DECORATOR_OPTIONS = E_INVALID_RESOURCEFUL_DECORATOR_OPTIONS;
2986
+ exports.E_INVALID_RESOURCEFUL_MIXIN_OPTIONS = E_INVALID_RESOURCEFUL_MIXIN_OPTIONS;
2987
+ exports.E_INVALID_RESOUREFUL_INDEX_REQUEST_EXCEPTION = E_INVALID_RESOUREFUL_INDEX_REQUEST_EXCEPTION;
2988
+ exports.E_LUCENE_INVALID_TYPE = E_LUCENE_INVALID_TYPE;
2989
+ exports.E_LUCENE_SYNTAX_EXCEPTION = E_LUCENE_SYNTAX_EXCEPTION;
2990
+ exports.E_LUCENE_UNEXPECTED_EXCEPTION = E_LUCENE_UNEXPECTED_EXCEPTION;
2991
+ exports.E_MISSING_PRIMARY_KEY_EXCEPTION = E_MISSING_PRIMARY_KEY_EXCEPTION;
2992
+ exports.E_RECORD_NOT_FOUND_EXCEPTION = E_RECORD_NOT_FOUND_EXCEPTION;
2993
+ exports.E_UNCASTABLE = E_UNCASTABLE;
2994
+ exports.E_UNEXPECTED_COLUMN_IN_QUERY = E_UNEXPECTED_COLUMN_IN_QUERY;
2995
+ exports.createError = createError;
2996
+ exports.defineStaticProperty = defineStaticProperty;
2997
+ exports.errors = errors;
2998
+ exports.getDefaultExportFromCjs = getDefaultExportFromCjs;
2999
+ exports.lodash = lodash;
3000
+ //# sourceMappingURL=errors-D8jb9VxY.cjs.map