@cortexkit/pi-magic-context 0.29.1 → 0.30.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1087 -852
- package/dist/subagent-entry.js +1132 -896
- package/package.json +9 -9
package/dist/index.js
CHANGED
|
@@ -13887,7 +13887,7 @@ var require_src = __commonJS((exports, module) => {
|
|
|
13887
13887
|
};
|
|
13888
13888
|
});
|
|
13889
13889
|
|
|
13890
|
-
// ../../node_modules/.bun/comment-json@
|
|
13890
|
+
// ../../node_modules/.bun/comment-json@5.0.0/node_modules/comment-json/src/common.js
|
|
13891
13891
|
var require_common = __commonJS((exports, module) => {
|
|
13892
13892
|
var PREFIX_BEFORE = "before";
|
|
13893
13893
|
var PREFIX_AFTER_PROP = "after-prop";
|
|
@@ -13919,8 +13919,6 @@ var require_common = __commonJS((exports, module) => {
|
|
|
13919
13919
|
var NON_PROP_SYMBOL_KEYS = NON_PROP_SYMBOL_PREFIXES.map(Symbol.for);
|
|
13920
13920
|
var COLON = ":";
|
|
13921
13921
|
var UNDEFINED = undefined;
|
|
13922
|
-
var LINE_BREAKS_BEFORE = new WeakMap;
|
|
13923
|
-
var LINE_BREAKS_AFTER = new WeakMap;
|
|
13924
13922
|
var RAW_STRING_LITERALS = new WeakMap;
|
|
13925
13923
|
var is_string = (subject) => typeof subject === "string";
|
|
13926
13924
|
var is_number = (subject) => typeof subject === "number";
|
|
@@ -14023,17 +14021,49 @@ var require_common = __commonJS((exports, module) => {
|
|
|
14023
14021
|
});
|
|
14024
14022
|
return target;
|
|
14025
14023
|
};
|
|
14026
|
-
var
|
|
14027
|
-
|
|
14028
|
-
|
|
14029
|
-
|
|
14024
|
+
var is_comment_symbol = (subject) => {
|
|
14025
|
+
const key = Symbol.keyFor(subject);
|
|
14026
|
+
return is_string(key) && (NON_PROP_SYMBOL_PREFIXES.includes(key) || PROP_SYMBOL_PREFIXES.some((prefix) => key.indexOf(prefix + COLON) === 0));
|
|
14027
|
+
};
|
|
14028
|
+
var remove_blank_line_tokens = (comments) => {
|
|
14029
|
+
let write = 0;
|
|
14030
|
+
let removed = false;
|
|
14031
|
+
comments.forEach((comment) => {
|
|
14032
|
+
if (comment && comment.type === "BlankLine") {
|
|
14033
|
+
removed = true;
|
|
14034
|
+
return;
|
|
14035
|
+
}
|
|
14036
|
+
comments[write++] = comment;
|
|
14037
|
+
});
|
|
14038
|
+
comments.length = write;
|
|
14039
|
+
return removed;
|
|
14040
|
+
};
|
|
14041
|
+
var remove_blank_lines_from_prop = (target, prop) => {
|
|
14042
|
+
if (!Object.hasOwn(target, prop)) {
|
|
14043
|
+
return;
|
|
14030
14044
|
}
|
|
14031
|
-
|
|
14032
|
-
|
|
14045
|
+
const comments = target[prop];
|
|
14046
|
+
if (!Array.isArray(comments) || !remove_blank_line_tokens(comments)) {
|
|
14047
|
+
return;
|
|
14048
|
+
}
|
|
14049
|
+
if (!comments.length) {
|
|
14050
|
+
delete target[prop];
|
|
14033
14051
|
}
|
|
14034
14052
|
};
|
|
14035
|
-
var
|
|
14036
|
-
|
|
14053
|
+
var remove_blank_lines_deep = (target) => {
|
|
14054
|
+
Object.getOwnPropertySymbols(target).forEach((prop) => {
|
|
14055
|
+
if (is_comment_symbol(prop)) {
|
|
14056
|
+
remove_blank_lines_from_prop(target, prop);
|
|
14057
|
+
}
|
|
14058
|
+
});
|
|
14059
|
+
Object.keys(target).forEach((key) => {
|
|
14060
|
+
const value = target[key];
|
|
14061
|
+
if (is_object(value)) {
|
|
14062
|
+
remove_blank_lines_deep(value);
|
|
14063
|
+
}
|
|
14064
|
+
});
|
|
14065
|
+
};
|
|
14066
|
+
var is_raw_json = typeof JSON.isRawJSON === "function" ? JSON.isRawJSON : () => false;
|
|
14037
14067
|
module.exports = {
|
|
14038
14068
|
PROP_SYMBOL_PREFIXES,
|
|
14039
14069
|
PREFIX_BEFORE,
|
|
@@ -14063,9 +14093,6 @@ var require_common = __commonJS((exports, module) => {
|
|
|
14063
14093
|
is_raw_json,
|
|
14064
14094
|
set_raw_string_literal,
|
|
14065
14095
|
get_raw_string_literal,
|
|
14066
|
-
set_comment_line_breaks,
|
|
14067
|
-
get_comment_line_breaks_before,
|
|
14068
|
-
get_comment_line_breaks_after,
|
|
14069
14096
|
assign(target, source, keys) {
|
|
14070
14097
|
if (!is_object(target)) {
|
|
14071
14098
|
throw new TypeError("Cannot convert undefined or null to object");
|
|
@@ -14127,11 +14154,26 @@ var require_common = __commonJS((exports, module) => {
|
|
|
14127
14154
|
return;
|
|
14128
14155
|
}
|
|
14129
14156
|
delete target[prop];
|
|
14157
|
+
},
|
|
14158
|
+
removeBlankLines(target, location) {
|
|
14159
|
+
if (!is_object(target)) {
|
|
14160
|
+
throw new TypeError("target must be an object");
|
|
14161
|
+
}
|
|
14162
|
+
if (location === UNDEFINED) {
|
|
14163
|
+
remove_blank_lines_deep(target);
|
|
14164
|
+
return;
|
|
14165
|
+
}
|
|
14166
|
+
const {
|
|
14167
|
+
where,
|
|
14168
|
+
key
|
|
14169
|
+
} = location;
|
|
14170
|
+
const prop = symbol_checked(where, key);
|
|
14171
|
+
remove_blank_lines_from_prop(target, prop);
|
|
14130
14172
|
}
|
|
14131
14173
|
};
|
|
14132
14174
|
});
|
|
14133
14175
|
|
|
14134
|
-
// ../../node_modules/.bun/comment-json@
|
|
14176
|
+
// ../../node_modules/.bun/comment-json@5.0.0/node_modules/comment-json/src/array.js
|
|
14135
14177
|
var require_array = __commonJS((exports, module) => {
|
|
14136
14178
|
var { sort } = require_src();
|
|
14137
14179
|
var {
|
|
@@ -14289,7 +14331,7 @@ var require_array = __commonJS((exports, module) => {
|
|
|
14289
14331
|
};
|
|
14290
14332
|
});
|
|
14291
14333
|
|
|
14292
|
-
// ../../node_modules/.bun/comment-json@
|
|
14334
|
+
// ../../node_modules/.bun/comment-json@5.0.0/node_modules/comment-json/src/parse.js
|
|
14293
14335
|
var require_parse = __commonJS((exports, module) => {
|
|
14294
14336
|
var esprima = require_esprima();
|
|
14295
14337
|
var {
|
|
@@ -14315,7 +14357,6 @@ var require_parse = __commonJS((exports, module) => {
|
|
|
14315
14357
|
is_object,
|
|
14316
14358
|
define: define2,
|
|
14317
14359
|
set_raw_string_literal,
|
|
14318
|
-
set_comment_line_breaks,
|
|
14319
14360
|
assign_non_prop_comments
|
|
14320
14361
|
} = require_common();
|
|
14321
14362
|
var tokenize = (code) => esprima.tokenize(code, {
|
|
@@ -14329,23 +14370,27 @@ var require_parse = __commonJS((exports, module) => {
|
|
|
14329
14370
|
var previous_props = [];
|
|
14330
14371
|
var last_prop;
|
|
14331
14372
|
var remove_comments = false;
|
|
14373
|
+
var remove_blank_lines = false;
|
|
14332
14374
|
var inline = false;
|
|
14333
14375
|
var tokens = null;
|
|
14334
14376
|
var last = null;
|
|
14335
14377
|
var current = null;
|
|
14336
14378
|
var index;
|
|
14337
14379
|
var reviver = null;
|
|
14380
|
+
var source_line_count = 0;
|
|
14338
14381
|
var clean = () => {
|
|
14339
14382
|
current_code = UNDEFINED;
|
|
14340
14383
|
previous_props.length = previous_hosts.length = 0;
|
|
14341
14384
|
last = null;
|
|
14342
14385
|
last_prop = UNDEFINED;
|
|
14386
|
+
remove_blank_lines = false;
|
|
14343
14387
|
};
|
|
14344
14388
|
var free = () => {
|
|
14345
14389
|
clean();
|
|
14346
14390
|
tokens.length = 0;
|
|
14347
14391
|
unassigned_comments = comments_host = tokens = last = current = reviver = null;
|
|
14348
14392
|
current_code = UNDEFINED;
|
|
14393
|
+
source_line_count = 0;
|
|
14349
14394
|
};
|
|
14350
14395
|
var symbolFor = (prefix) => Symbol.for(last_prop !== UNDEFINED ? prefix + COLON + last_prop : prefix);
|
|
14351
14396
|
var transform2 = (k, { value, context = {} }) => reviver ? reviver(k, value, context) : value;
|
|
@@ -14389,6 +14434,37 @@ var require_parse = __commonJS((exports, module) => {
|
|
|
14389
14434
|
var restore_comments_host = () => {
|
|
14390
14435
|
comments_host = previous_hosts.pop();
|
|
14391
14436
|
};
|
|
14437
|
+
var create_blank_line = () => ({
|
|
14438
|
+
type: "BlankLine",
|
|
14439
|
+
inline: false
|
|
14440
|
+
});
|
|
14441
|
+
var append_blank_lines = (comments, from_line, to_line) => {
|
|
14442
|
+
if (remove_blank_lines) {
|
|
14443
|
+
return;
|
|
14444
|
+
}
|
|
14445
|
+
let blank_lines = Math.max(0, to_line - from_line - 1);
|
|
14446
|
+
while (blank_lines-- > 0) {
|
|
14447
|
+
comments.push(create_blank_line());
|
|
14448
|
+
}
|
|
14449
|
+
};
|
|
14450
|
+
var normalize_parse_options = (options) => {
|
|
14451
|
+
if (typeof options === "boolean") {
|
|
14452
|
+
return {
|
|
14453
|
+
no_comments: options,
|
|
14454
|
+
no_blank_lines: false
|
|
14455
|
+
};
|
|
14456
|
+
}
|
|
14457
|
+
if (!is_object(options)) {
|
|
14458
|
+
return {
|
|
14459
|
+
no_comments: false,
|
|
14460
|
+
no_blank_lines: false
|
|
14461
|
+
};
|
|
14462
|
+
}
|
|
14463
|
+
return {
|
|
14464
|
+
no_comments: !!options.no_comments,
|
|
14465
|
+
no_blank_lines: !!options.no_blank_lines
|
|
14466
|
+
};
|
|
14467
|
+
};
|
|
14392
14468
|
var assign_after_comments = () => {
|
|
14393
14469
|
if (!unassigned_comments) {
|
|
14394
14470
|
return;
|
|
@@ -14421,26 +14497,26 @@ var require_parse = __commonJS((exports, module) => {
|
|
|
14421
14497
|
};
|
|
14422
14498
|
var parse_comments = (prefix) => {
|
|
14423
14499
|
const comments = [];
|
|
14500
|
+
let previous_line = last ? last.loc.end.line : 0;
|
|
14424
14501
|
while (current && (is("LineComment") || is("BlockComment"))) {
|
|
14502
|
+
append_blank_lines(comments, previous_line, current.loc.start.line);
|
|
14425
14503
|
const comment = {
|
|
14426
14504
|
...current,
|
|
14427
14505
|
inline
|
|
14428
14506
|
};
|
|
14429
|
-
const previous_line = last ? last.loc.end.line : 1;
|
|
14430
|
-
set_comment_line_breaks(comment, Math.max(0, comment.loc.start.line - previous_line));
|
|
14431
14507
|
comments.push(comment);
|
|
14508
|
+
previous_line = comment.loc.end.line;
|
|
14432
14509
|
next();
|
|
14433
14510
|
}
|
|
14434
|
-
|
|
14435
|
-
if (length) {
|
|
14436
|
-
const comment = comments[length - 1];
|
|
14437
|
-
const current_line = current ? current.loc.start.line : comment.loc.end.line;
|
|
14438
|
-
set_comment_line_breaks(comment, undefined, Math.max(0, current_line - comment.loc.end.line));
|
|
14439
|
-
}
|
|
14511
|
+
append_blank_lines(comments, previous_line, current ? current.loc.start.line : source_line_count);
|
|
14440
14512
|
if (remove_comments) {
|
|
14441
|
-
|
|
14513
|
+
for (let i = comments.length - 1;i >= 0; i--) {
|
|
14514
|
+
if (comments[i].type !== "BlankLine") {
|
|
14515
|
+
comments.splice(i, 1);
|
|
14516
|
+
}
|
|
14517
|
+
}
|
|
14442
14518
|
}
|
|
14443
|
-
if (!length) {
|
|
14519
|
+
if (!comments.length) {
|
|
14444
14520
|
return;
|
|
14445
14521
|
}
|
|
14446
14522
|
if (prefix) {
|
|
@@ -14579,12 +14655,19 @@ var require_parse = __commonJS((exports, module) => {
|
|
|
14579
14655
|
return {};
|
|
14580
14656
|
}
|
|
14581
14657
|
}
|
|
14582
|
-
var parse5 = (code, rev,
|
|
14658
|
+
var parse5 = (code, rev, options) => {
|
|
14583
14659
|
clean();
|
|
14660
|
+
const {
|
|
14661
|
+
no_comments,
|
|
14662
|
+
no_blank_lines
|
|
14663
|
+
} = normalize_parse_options(options);
|
|
14584
14664
|
current_code = code;
|
|
14665
|
+
source_line_count = code.split(`
|
|
14666
|
+
`).length;
|
|
14585
14667
|
tokens = tokenize(code);
|
|
14586
14668
|
reviver = rev;
|
|
14587
14669
|
remove_comments = no_comments;
|
|
14670
|
+
remove_blank_lines = no_blank_lines;
|
|
14588
14671
|
if (!tokens.length) {
|
|
14589
14672
|
unexpected_end();
|
|
14590
14673
|
}
|
|
@@ -14614,7 +14697,7 @@ var require_parse = __commonJS((exports, module) => {
|
|
|
14614
14697
|
};
|
|
14615
14698
|
});
|
|
14616
14699
|
|
|
14617
|
-
// ../../node_modules/.bun/comment-json@
|
|
14700
|
+
// ../../node_modules/.bun/comment-json@5.0.0/node_modules/comment-json/src/stringify.js
|
|
14618
14701
|
var require_stringify = __commonJS((exports, module) => {
|
|
14619
14702
|
var {
|
|
14620
14703
|
PREFIX_BEFORE_ALL,
|
|
@@ -14636,8 +14719,6 @@ var require_stringify = __commonJS((exports, module) => {
|
|
|
14636
14719
|
is_number,
|
|
14637
14720
|
is_object,
|
|
14638
14721
|
get_raw_string_literal,
|
|
14639
|
-
get_comment_line_breaks_before,
|
|
14640
|
-
get_comment_line_breaks_after,
|
|
14641
14722
|
is_raw_json
|
|
14642
14723
|
} = require_common();
|
|
14643
14724
|
var SPACE = " ";
|
|
@@ -14652,26 +14733,18 @@ var require_stringify = __commonJS((exports, module) => {
|
|
|
14652
14733
|
var quote = JSON.stringify;
|
|
14653
14734
|
var comment_stringify = (value, line) => line ? `//${value}` : `/*${value}*/`;
|
|
14654
14735
|
var repeat_line_breaks = (line_breaks, gap) => (LF + gap).repeat(line_breaks);
|
|
14655
|
-
var
|
|
14656
|
-
var
|
|
14657
|
-
if (!previous_comment || !previous_comment.loc || !comment.loc) {
|
|
14658
|
-
return null;
|
|
14659
|
-
}
|
|
14660
|
-
const { end } = previous_comment.loc;
|
|
14661
|
-
const { start } = comment.loc;
|
|
14662
|
-
if (!end || !start || !is_number(end.line) || !is_number(start.line)) {
|
|
14663
|
-
return null;
|
|
14664
|
-
}
|
|
14665
|
-
const line_breaks = start.line - end.line;
|
|
14666
|
-
return line_breaks >= 0 ? line_breaks : null;
|
|
14667
|
-
};
|
|
14668
|
-
var count_trailing_line_breaks = (str, gap) => {
|
|
14669
|
-
const unit = LF + gap;
|
|
14670
|
-
const { length } = unit;
|
|
14736
|
+
var is_inline_whitespace = (char) => char === SPACE || char === "\t";
|
|
14737
|
+
var count_trailing_line_breaks = (str) => {
|
|
14671
14738
|
let i = str.length;
|
|
14672
14739
|
let count = 0;
|
|
14673
|
-
while (i
|
|
14674
|
-
i
|
|
14740
|
+
while (i > 0) {
|
|
14741
|
+
while (i > 0 && is_inline_whitespace(str[i - 1])) {
|
|
14742
|
+
i--;
|
|
14743
|
+
}
|
|
14744
|
+
if (i === 0 || str[i - 1] !== LF) {
|
|
14745
|
+
return count;
|
|
14746
|
+
}
|
|
14747
|
+
i--;
|
|
14675
14748
|
count++;
|
|
14676
14749
|
}
|
|
14677
14750
|
return count;
|
|
@@ -14682,27 +14755,30 @@ var require_stringify = __commonJS((exports, module) => {
|
|
|
14682
14755
|
return EMPTY;
|
|
14683
14756
|
}
|
|
14684
14757
|
let str = EMPTY;
|
|
14758
|
+
let blank_lines = 0;
|
|
14685
14759
|
let last_comment = null;
|
|
14686
14760
|
comments.forEach((comment, i) => {
|
|
14761
|
+
if (comment.type === "BlankLine") {
|
|
14762
|
+
blank_lines++;
|
|
14763
|
+
return;
|
|
14764
|
+
}
|
|
14687
14765
|
const {
|
|
14688
14766
|
inline,
|
|
14689
14767
|
type,
|
|
14690
14768
|
value
|
|
14691
14769
|
} = comment;
|
|
14692
|
-
|
|
14693
|
-
|
|
14694
|
-
line_breaks_before = read_line_breaks_from_loc(last_comment, comment);
|
|
14695
|
-
}
|
|
14696
|
-
if (line_breaks_before === null) {
|
|
14697
|
-
line_breaks_before = inline ? 0 : 1;
|
|
14698
|
-
}
|
|
14699
|
-
const delimiter = line_breaks_before > 0 ? repeat_line_breaks(line_breaks_before, deeper_gap) : inline ? SPACE : i === 0 ? EMPTY : LF + deeper_gap;
|
|
14770
|
+
const line_breaks_before = blank_lines > 0 ? blank_lines + (inline ? 0 : 1) : null;
|
|
14771
|
+
const delimiter = line_breaks_before > 0 ? repeat_line_breaks(line_breaks_before, deeper_gap) : inline ? SPACE : i === 0 && symbol_tag === PREFIX_BEFORE_ALL && deeper_gap === EMPTY ? EMPTY : LF + deeper_gap;
|
|
14700
14772
|
const is_line_comment = type === "LineComment";
|
|
14701
14773
|
str += delimiter + comment_stringify(value, is_line_comment);
|
|
14774
|
+
blank_lines = 0;
|
|
14702
14775
|
last_comment = comment;
|
|
14703
14776
|
});
|
|
14777
|
+
if (!last_comment) {
|
|
14778
|
+
return blank_lines ? repeat_line_breaks(blank_lines + 1, deeper_gap) : EMPTY;
|
|
14779
|
+
}
|
|
14704
14780
|
const default_line_breaks_after = display_block || last_comment.type === "LineComment" ? 1 : 0;
|
|
14705
|
-
const line_breaks_after =
|
|
14781
|
+
const line_breaks_after = blank_lines > 0 ? blank_lines + 1 : default_line_breaks_after;
|
|
14706
14782
|
return str + repeat_line_breaks(line_breaks_after, deeper_gap);
|
|
14707
14783
|
};
|
|
14708
14784
|
var replacer = null;
|
|
@@ -14711,7 +14787,7 @@ var require_stringify = __commonJS((exports, module) => {
|
|
|
14711
14787
|
replacer = null;
|
|
14712
14788
|
indent = EMPTY;
|
|
14713
14789
|
};
|
|
14714
|
-
var join12 = (one, two, gap) => one ? two ? one + two.trim() + LF + gap : one.trimRight() + repeat_line_breaks(Math.max(1, count_trailing_line_breaks(one
|
|
14790
|
+
var join12 = (one, two, gap) => one ? two ? one + two.trim() + LF + gap : one.trimRight() + repeat_line_breaks(Math.max(1, count_trailing_line_breaks(one)), gap) : two ? two.trimRight() + repeat_line_breaks(Math.max(1, count_trailing_line_breaks(two)), gap) : EMPTY;
|
|
14715
14791
|
var join_content = (inside, value, gap) => {
|
|
14716
14792
|
const comment = process_comments(value, PREFIX_BEFORE, gap + indent, true);
|
|
14717
14793
|
return join12(comment, inside, gap);
|
|
@@ -14810,6 +14886,8 @@ var require_stringify = __commonJS((exports, module) => {
|
|
|
14810
14886
|
const str = toString.call(subject);
|
|
14811
14887
|
return PRIMITIVE_OBJECT_TYPES.includes(str);
|
|
14812
14888
|
};
|
|
14889
|
+
var normalize_blank_lines = (str) => typeof str === "string" ? str.replace(/\n[ \t]+(?=\n)/g, `
|
|
14890
|
+
`) : str;
|
|
14813
14891
|
module.exports = (value, replacer_, space) => {
|
|
14814
14892
|
const indent_ = get_indent(space);
|
|
14815
14893
|
if (!indent_) {
|
|
@@ -14822,11 +14900,12 @@ var require_stringify = __commonJS((exports, module) => {
|
|
|
14822
14900
|
indent = indent_;
|
|
14823
14901
|
const str = is_primitive_object(value) ? JSON.stringify(value) : stringify("", { "": value }, EMPTY);
|
|
14824
14902
|
clean();
|
|
14825
|
-
|
|
14903
|
+
const output = is_object(value) ? process_comments(value, PREFIX_BEFORE_ALL, EMPTY, true).trimLeft() + str + process_comments(value, PREFIX_AFTER_ALL, EMPTY).trimRight() : str;
|
|
14904
|
+
return normalize_blank_lines(output);
|
|
14826
14905
|
};
|
|
14827
14906
|
});
|
|
14828
14907
|
|
|
14829
|
-
// ../../node_modules/.bun/comment-json@
|
|
14908
|
+
// ../../node_modules/.bun/comment-json@5.0.0/node_modules/comment-json/src/index.js
|
|
14830
14909
|
var require_src2 = __commonJS((exports, module) => {
|
|
14831
14910
|
var { parse: parse5, tokenize } = require_parse();
|
|
14832
14911
|
var stringify = require_stringify();
|
|
@@ -14841,7 +14920,8 @@ var require_src2 = __commonJS((exports, module) => {
|
|
|
14841
14920
|
PREFIX_AFTER_ALL,
|
|
14842
14921
|
assign,
|
|
14843
14922
|
moveComments,
|
|
14844
|
-
removeComments
|
|
14923
|
+
removeComments,
|
|
14924
|
+
removeBlankLines
|
|
14845
14925
|
} = require_common();
|
|
14846
14926
|
module.exports = {
|
|
14847
14927
|
PREFIX_BEFORE,
|
|
@@ -14857,7 +14937,8 @@ var require_src2 = __commonJS((exports, module) => {
|
|
|
14857
14937
|
CommentArray,
|
|
14858
14938
|
assign,
|
|
14859
14939
|
moveComments,
|
|
14860
|
-
removeComments
|
|
14940
|
+
removeComments,
|
|
14941
|
+
removeBlankLines
|
|
14861
14942
|
};
|
|
14862
14943
|
});
|
|
14863
14944
|
|
|
@@ -156386,10 +156467,9 @@ function compareSemverCore(a, b) {
|
|
|
156386
156467
|
|
|
156387
156468
|
// ../plugin/src/shared/announcement.ts
|
|
156388
156469
|
init_data_path();
|
|
156389
|
-
var ANNOUNCEMENT_VERSION = "0.
|
|
156470
|
+
var ANNOUNCEMENT_VERSION = "0.30.1";
|
|
156390
156471
|
var ANNOUNCEMENT_FEATURES = [
|
|
156391
|
-
|
|
156392
|
-
"When memory is disabled, the ctx_memory tool and its guidance are no longer shown (they had nothing to write to). ctx_search stays, searching conversation history and git commits."
|
|
156472
|
+
"Local embeddings work on OpenCode Desktop again (#195): /ctx-embed no longer fails with 'Unsupported device: cpu' on the Desktop app."
|
|
156393
156473
|
];
|
|
156394
156474
|
var ANNOUNCEMENT_FOOTER = "Join us on Discord: https://discord.gg/F2uWxjGnU";
|
|
156395
156475
|
var STATE_FILENAME = "last_announced_version";
|
|
@@ -173138,8 +173218,8 @@ async function injectWasmOrtForElectron() {
|
|
|
173138
173218
|
try {
|
|
173139
173219
|
const { createRequire: createRequireFn } = await import("node:module");
|
|
173140
173220
|
const requireFn = createRequireFn(import.meta.url);
|
|
173141
|
-
const
|
|
173142
|
-
const distDir =
|
|
173221
|
+
const mainEntry = requireFn.resolve("onnxruntime-web");
|
|
173222
|
+
const distDir = dirname5(mainEntry);
|
|
173143
173223
|
const wasmPathsPrefix = `${pathToFileURL(distDir).href}/`;
|
|
173144
173224
|
if (ortWeb.env?.wasm) {
|
|
173145
173225
|
ortWeb.env.wasm.wasmPaths = wasmPathsPrefix;
|
|
@@ -173260,7 +173340,7 @@ class LocalEmbeddingProvider {
|
|
|
173260
173340
|
if (this.disposing) {
|
|
173261
173341
|
return;
|
|
173262
173342
|
}
|
|
173263
|
-
await injectWasmOrtForElectron();
|
|
173343
|
+
const injectedWasmOrt = await injectWasmOrtForElectron();
|
|
173264
173344
|
const transformersSpec = "@huggingface/transformers";
|
|
173265
173345
|
const transformersModule = await import(transformersSpec);
|
|
173266
173346
|
const env = transformersModule.env;
|
|
@@ -173290,7 +173370,8 @@ class LocalEmbeddingProvider {
|
|
|
173290
173370
|
for (let attempt = 1;attempt <= MAX_ATTEMPTS; attempt++) {
|
|
173291
173371
|
try {
|
|
173292
173372
|
const pipeline = await withQuietConsole(() => createPipeline("feature-extraction", this.model, {
|
|
173293
|
-
dtype: "fp32"
|
|
173373
|
+
dtype: "fp32",
|
|
173374
|
+
...injectedWasmOrt ? { device: "auto" } : {}
|
|
173294
173375
|
}));
|
|
173295
173376
|
if (this.disposing) {
|
|
173296
173377
|
await pipeline.dispose?.();
|
|
@@ -199718,7 +199799,7 @@ function formatThresholdPercent(value) {
|
|
|
199718
199799
|
// package.json
|
|
199719
199800
|
var package_default = {
|
|
199720
199801
|
name: "@cortexkit/pi-magic-context",
|
|
199721
|
-
version: "0.
|
|
199802
|
+
version: "0.30.1",
|
|
199722
199803
|
type: "module",
|
|
199723
199804
|
description: "Pi coding agent extension for Magic Context — cross-session memory and context management",
|
|
199724
199805
|
main: "dist/index.js",
|
|
@@ -199758,23 +199839,23 @@ var package_default = {
|
|
|
199758
199839
|
"@huggingface/transformers": "^4.1.0",
|
|
199759
199840
|
"@jitl/quickjs-singlefile-cjs-release-asyncify": "0.32.0",
|
|
199760
199841
|
"ai-tokenizer": "^1.0.6",
|
|
199761
|
-
"comment-json": "^
|
|
199842
|
+
"comment-json": "^5.0.0",
|
|
199762
199843
|
"quickjs-emscripten": "^0.32.0",
|
|
199763
|
-
typebox: "^1.1
|
|
199844
|
+
typebox: "^1.3.1",
|
|
199764
199845
|
zod: "^4.1.8"
|
|
199765
199846
|
},
|
|
199766
199847
|
devDependencies: {
|
|
199767
|
-
"@biomejs/biome": "^2.
|
|
199768
|
-
"@earendil-works/pi-coding-agent": "^0.
|
|
199769
|
-
"@earendil-works/pi-tui": "^0.
|
|
199848
|
+
"@biomejs/biome": "^2.5.1",
|
|
199849
|
+
"@earendil-works/pi-coding-agent": "^0.80.2",
|
|
199850
|
+
"@earendil-works/pi-tui": "^0.80.2",
|
|
199770
199851
|
"@types/better-sqlite3": "^7.6.13",
|
|
199771
199852
|
"@types/bun": "^1.3.10",
|
|
199772
|
-
"@types/node": "^22.
|
|
199853
|
+
"@types/node": "^22.20.0",
|
|
199773
199854
|
typescript: "^5.8.0"
|
|
199774
199855
|
},
|
|
199775
199856
|
peerDependencies: {
|
|
199776
|
-
"@earendil-works/pi-coding-agent": "^0.
|
|
199777
|
-
"@earendil-works/pi-tui": "^0.
|
|
199857
|
+
"@earendil-works/pi-coding-agent": "^0.80.2",
|
|
199858
|
+
"@earendil-works/pi-tui": "^0.80.2"
|
|
199778
199859
|
},
|
|
199779
199860
|
exports: {
|
|
199780
199861
|
".": {
|
|
@@ -200504,7 +200585,7 @@ ${partLines.join(`
|
|
|
200504
200585
|
`), lastOrdinal, truncated };
|
|
200505
200586
|
}
|
|
200506
200587
|
|
|
200507
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200588
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/memory/memory.mjs
|
|
200508
200589
|
var exports_memory = {};
|
|
200509
200590
|
__export(exports_memory, {
|
|
200510
200591
|
Update: () => Update,
|
|
@@ -200515,7 +200596,7 @@ __export(exports_memory, {
|
|
|
200515
200596
|
Assign: () => Assign
|
|
200516
200597
|
});
|
|
200517
200598
|
|
|
200518
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200599
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/memory/metrics.mjs
|
|
200519
200600
|
var Metrics = {
|
|
200520
200601
|
assign: 0,
|
|
200521
200602
|
create: 0,
|
|
@@ -200524,17 +200605,17 @@ var Metrics = {
|
|
|
200524
200605
|
update: 0
|
|
200525
200606
|
};
|
|
200526
200607
|
|
|
200527
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200608
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/memory/assign.mjs
|
|
200528
200609
|
function Assign(left, right) {
|
|
200529
200610
|
Metrics.assign += 1;
|
|
200530
200611
|
return { ...left, ...right };
|
|
200531
200612
|
}
|
|
200532
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200613
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/guard/guard.mjs
|
|
200533
200614
|
var exports_guard = {};
|
|
200534
200615
|
__export(exports_guard, {
|
|
200535
200616
|
Values: () => Values,
|
|
200536
|
-
TakeLeft: () => TakeLeft,
|
|
200537
200617
|
Symbols: () => Symbols,
|
|
200618
|
+
ShiftLeft: () => ShiftLeft,
|
|
200538
200619
|
Keys: () => Keys,
|
|
200539
200620
|
IsValueLike: () => IsValueLike,
|
|
200540
200621
|
IsUnsafePropertyKey: () => IsUnsafePropertyKey,
|
|
@@ -200550,7 +200631,6 @@ __export(exports_guard, {
|
|
|
200550
200631
|
IsMaxLength: () => IsMaxLength2,
|
|
200551
200632
|
IsLessThan: () => IsLessThan,
|
|
200552
200633
|
IsLessEqualThan: () => IsLessEqualThan,
|
|
200553
|
-
IsIterator: () => IsIterator,
|
|
200554
200634
|
IsInteger: () => IsInteger,
|
|
200555
200635
|
IsGreaterThan: () => IsGreaterThan,
|
|
200556
200636
|
IsGreaterEqualThan: () => IsGreaterEqualThan,
|
|
@@ -200561,7 +200641,6 @@ __export(exports_guard, {
|
|
|
200561
200641
|
IsClassInstance: () => IsClassInstance,
|
|
200562
200642
|
IsBoolean: () => IsBoolean,
|
|
200563
200643
|
IsBigInt: () => IsBigInt,
|
|
200564
|
-
IsAsyncIterator: () => IsAsyncIterator,
|
|
200565
200644
|
IsArray: () => IsArray,
|
|
200566
200645
|
HasPropertyKey: () => HasPropertyKey,
|
|
200567
200646
|
GraphemeCount: () => GraphemeCount2,
|
|
@@ -200571,7 +200650,7 @@ __export(exports_guard, {
|
|
|
200571
200650
|
Entries: () => Entries
|
|
200572
200651
|
});
|
|
200573
200652
|
|
|
200574
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200653
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/guard/string.mjs
|
|
200575
200654
|
function IsBetween(value, min, max) {
|
|
200576
200655
|
return value >= min && value <= max;
|
|
200577
200656
|
}
|
|
@@ -200675,13 +200754,10 @@ function IsMaxLengthFast(value, maxLength) {
|
|
|
200675
200754
|
return true;
|
|
200676
200755
|
}
|
|
200677
200756
|
|
|
200678
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200757
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/guard/guard.mjs
|
|
200679
200758
|
function IsArray(value) {
|
|
200680
200759
|
return Array.isArray(value);
|
|
200681
200760
|
}
|
|
200682
|
-
function IsAsyncIterator(value) {
|
|
200683
|
-
return IsObject(value) && Symbol.asyncIterator in value;
|
|
200684
|
-
}
|
|
200685
200761
|
function IsBigInt(value) {
|
|
200686
200762
|
return IsEqual(typeof value, "bigint");
|
|
200687
200763
|
}
|
|
@@ -200704,9 +200780,6 @@ function IsFunction(value) {
|
|
|
200704
200780
|
function IsInteger(value) {
|
|
200705
200781
|
return Number.isInteger(value);
|
|
200706
200782
|
}
|
|
200707
|
-
function IsIterator(value) {
|
|
200708
|
-
return IsObject(value) && Symbol.iterator in value;
|
|
200709
|
-
}
|
|
200710
200783
|
function IsNull(value) {
|
|
200711
200784
|
return IsEqual(value, null);
|
|
200712
200785
|
}
|
|
@@ -200790,7 +200863,7 @@ function EveryAll(value, offset, callback) {
|
|
|
200790
200863
|
}
|
|
200791
200864
|
return result;
|
|
200792
200865
|
}
|
|
200793
|
-
function
|
|
200866
|
+
function ShiftLeft(array2, true_, false_) {
|
|
200794
200867
|
return IsEqual(array2.length, 0) ? false_() : true_(array2[0], array2.slice(1));
|
|
200795
200868
|
}
|
|
200796
200869
|
function IsUnsafePropertyKey(key) {
|
|
@@ -200826,20 +200899,99 @@ function DeepEqualArray(left, right) {
|
|
|
200826
200899
|
function IsDeepEqual(left, right) {
|
|
200827
200900
|
return IsArray(left) ? DeepEqualArray(left, right) : IsObject(left) ? DeepEqualObject(left, right) : IsEqual(left, right);
|
|
200828
200901
|
}
|
|
200829
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200830
|
-
|
|
200831
|
-
|
|
200902
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/guard/globals.mjs
|
|
200903
|
+
var exports_globals = {};
|
|
200904
|
+
__export(exports_globals, {
|
|
200905
|
+
IsUint8ClampedArray: () => IsUint8ClampedArray,
|
|
200906
|
+
IsUint8Array: () => IsUint8Array,
|
|
200907
|
+
IsUint32Array: () => IsUint32Array,
|
|
200908
|
+
IsUint16Array: () => IsUint16Array,
|
|
200909
|
+
IsTypeArray: () => IsTypeArray,
|
|
200910
|
+
IsString: () => IsString2,
|
|
200911
|
+
IsSet: () => IsSet,
|
|
200912
|
+
IsRegExp: () => IsRegExp,
|
|
200913
|
+
IsNumber: () => IsNumber2,
|
|
200914
|
+
IsMap: () => IsMap,
|
|
200915
|
+
IsInt8Array: () => IsInt8Array,
|
|
200916
|
+
IsInt32Array: () => IsInt32Array,
|
|
200917
|
+
IsInt16Array: () => IsInt16Array,
|
|
200918
|
+
IsFloat64Array: () => IsFloat64Array,
|
|
200919
|
+
IsFloat32Array: () => IsFloat32Array,
|
|
200920
|
+
IsDate: () => IsDate,
|
|
200921
|
+
IsBoolean: () => IsBoolean2,
|
|
200922
|
+
IsBigUint64Array: () => IsBigUint64Array,
|
|
200923
|
+
IsBigInt64Array: () => IsBigInt64Array
|
|
200924
|
+
});
|
|
200925
|
+
function IsBoolean2(value) {
|
|
200926
|
+
return value instanceof Boolean;
|
|
200927
|
+
}
|
|
200928
|
+
function IsNumber2(value) {
|
|
200929
|
+
return value instanceof Number;
|
|
200930
|
+
}
|
|
200931
|
+
function IsString2(value) {
|
|
200932
|
+
return value instanceof String;
|
|
200933
|
+
}
|
|
200934
|
+
function IsTypeArray(value) {
|
|
200935
|
+
return globalThis.ArrayBuffer.isView(value);
|
|
200936
|
+
}
|
|
200937
|
+
function IsInt8Array(value) {
|
|
200938
|
+
return value instanceof globalThis.Int8Array;
|
|
200939
|
+
}
|
|
200940
|
+
function IsUint8Array(value) {
|
|
200941
|
+
return value instanceof globalThis.Uint8Array;
|
|
200942
|
+
}
|
|
200943
|
+
function IsUint8ClampedArray(value) {
|
|
200944
|
+
return value instanceof globalThis.Uint8ClampedArray;
|
|
200945
|
+
}
|
|
200946
|
+
function IsInt16Array(value) {
|
|
200947
|
+
return value instanceof globalThis.Int16Array;
|
|
200948
|
+
}
|
|
200949
|
+
function IsUint16Array(value) {
|
|
200950
|
+
return value instanceof globalThis.Uint16Array;
|
|
200951
|
+
}
|
|
200952
|
+
function IsInt32Array(value) {
|
|
200953
|
+
return value instanceof globalThis.Int32Array;
|
|
200954
|
+
}
|
|
200955
|
+
function IsUint32Array(value) {
|
|
200956
|
+
return value instanceof globalThis.Uint32Array;
|
|
200957
|
+
}
|
|
200958
|
+
function IsFloat32Array(value) {
|
|
200959
|
+
return value instanceof globalThis.Float32Array;
|
|
200960
|
+
}
|
|
200961
|
+
function IsFloat64Array(value) {
|
|
200962
|
+
return value instanceof globalThis.Float64Array;
|
|
200963
|
+
}
|
|
200964
|
+
function IsBigInt64Array(value) {
|
|
200965
|
+
return value instanceof globalThis.BigInt64Array;
|
|
200966
|
+
}
|
|
200967
|
+
function IsBigUint64Array(value) {
|
|
200968
|
+
return value instanceof globalThis.BigUint64Array;
|
|
200969
|
+
}
|
|
200970
|
+
function IsRegExp(value) {
|
|
200971
|
+
return value instanceof globalThis.RegExp;
|
|
200972
|
+
}
|
|
200973
|
+
function IsDate(value) {
|
|
200974
|
+
return value instanceof globalThis.Date;
|
|
200832
200975
|
}
|
|
200833
|
-
function
|
|
200976
|
+
function IsSet(value) {
|
|
200977
|
+
return value instanceof globalThis.Set;
|
|
200978
|
+
}
|
|
200979
|
+
function IsMap(value) {
|
|
200980
|
+
return value instanceof globalThis.Map;
|
|
200981
|
+
}
|
|
200982
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/memory/clone.mjs
|
|
200983
|
+
function FromClassInstance(value) {
|
|
200834
200984
|
return value;
|
|
200835
200985
|
}
|
|
200836
|
-
function
|
|
200837
|
-
return
|
|
200986
|
+
function IsTypeObject(value) {
|
|
200987
|
+
return exports_guard.HasPropertyKey(value, "~kind") || exports_guard.HasPropertyKey(value, "~unsafe");
|
|
200838
200988
|
}
|
|
200839
|
-
function
|
|
200989
|
+
function FromTypeObject(value) {
|
|
200840
200990
|
const result = {};
|
|
200841
200991
|
const descriptors = Object.getOwnPropertyDescriptors(value);
|
|
200842
200992
|
for (const key of Object.keys(descriptors)) {
|
|
200993
|
+
if (exports_guard.IsUnsafePropertyKey(key))
|
|
200994
|
+
continue;
|
|
200843
200995
|
const descriptor = descriptors[key];
|
|
200844
200996
|
if (exports_guard.HasPropertyKey(descriptor, "value")) {
|
|
200845
200997
|
Object.defineProperty(result, key, { ...descriptor, value: FromValue(descriptor.value) });
|
|
@@ -200847,20 +200999,44 @@ function FromObject(value) {
|
|
|
200847
200999
|
}
|
|
200848
201000
|
return result;
|
|
200849
201001
|
}
|
|
201002
|
+
function FromPlainObject(value) {
|
|
201003
|
+
const result = {};
|
|
201004
|
+
for (const key of exports_guard.Keys(value)) {
|
|
201005
|
+
if (exports_guard.IsUnsafePropertyKey(key))
|
|
201006
|
+
continue;
|
|
201007
|
+
result[key] = FromValue(value[key]);
|
|
201008
|
+
}
|
|
201009
|
+
for (const key of exports_guard.Symbols(value)) {
|
|
201010
|
+
result[key] = FromValue(value[key]);
|
|
201011
|
+
}
|
|
201012
|
+
return result;
|
|
201013
|
+
}
|
|
201014
|
+
function FromObject(value) {
|
|
201015
|
+
return exports_guard.IsClassInstance(value) ? FromClassInstance(value) : IsTypeObject(value) ? FromTypeObject(value) : FromPlainObject(value);
|
|
201016
|
+
}
|
|
201017
|
+
function FromArray(value) {
|
|
201018
|
+
return value.map((element) => FromValue(element));
|
|
201019
|
+
}
|
|
201020
|
+
function FromTypedArray(value) {
|
|
201021
|
+
return value.slice();
|
|
201022
|
+
}
|
|
200850
201023
|
function FromRegExp(value) {
|
|
200851
201024
|
return new RegExp(value.source, value.flags);
|
|
200852
201025
|
}
|
|
200853
|
-
function
|
|
200854
|
-
return value;
|
|
201026
|
+
function FromMap(value) {
|
|
201027
|
+
return new Map(FromValue([...value.entries()]));
|
|
201028
|
+
}
|
|
201029
|
+
function FromSet(value) {
|
|
201030
|
+
return new Set(FromValue([...value.values()]));
|
|
200855
201031
|
}
|
|
200856
201032
|
function FromValue(value) {
|
|
200857
|
-
return value
|
|
201033
|
+
return exports_globals.IsTypeArray(value) ? FromTypedArray(value) : exports_globals.IsRegExp(value) ? FromRegExp(value) : exports_globals.IsMap(value) ? FromMap(value) : exports_globals.IsSet(value) ? FromSet(value) : exports_guard.IsArray(value) ? FromArray(value) : exports_guard.IsObject(value) ? FromObject(value) : value;
|
|
200858
201034
|
}
|
|
200859
201035
|
function Clone(value) {
|
|
200860
201036
|
Metrics.clone += 1;
|
|
200861
201037
|
return FromValue(value);
|
|
200862
201038
|
}
|
|
200863
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201039
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/settings/settings.mjs
|
|
200864
201040
|
var exports_settings = {};
|
|
200865
201041
|
__export(exports_settings, {
|
|
200866
201042
|
Set: () => Set2,
|
|
@@ -200873,7 +201049,8 @@ var settings = {
|
|
|
200873
201049
|
useAcceleration: true,
|
|
200874
201050
|
exactOptionalPropertyTypes: false,
|
|
200875
201051
|
enumerableKind: false,
|
|
200876
|
-
correctiveParse: false
|
|
201052
|
+
correctiveParse: false,
|
|
201053
|
+
unionPrioritySort: true
|
|
200877
201054
|
};
|
|
200878
201055
|
function Reset() {
|
|
200879
201056
|
settings.immutableTypes = false;
|
|
@@ -200882,6 +201059,7 @@ function Reset() {
|
|
|
200882
201059
|
settings.exactOptionalPropertyTypes = false;
|
|
200883
201060
|
settings.enumerableKind = false;
|
|
200884
201061
|
settings.correctiveParse = false;
|
|
201062
|
+
settings.unionPrioritySort = true;
|
|
200885
201063
|
}
|
|
200886
201064
|
function Set2(options) {
|
|
200887
201065
|
for (const key of exports_guard.Keys(options)) {
|
|
@@ -200894,7 +201072,7 @@ function Set2(options) {
|
|
|
200894
201072
|
function Get() {
|
|
200895
201073
|
return settings;
|
|
200896
201074
|
}
|
|
200897
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201075
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/memory/create.mjs
|
|
200898
201076
|
function MergeHidden(left, right) {
|
|
200899
201077
|
for (const key of Object.keys(right)) {
|
|
200900
201078
|
Object.defineProperty(left, key, {
|
|
@@ -200916,7 +201094,7 @@ function Create(hidden, enumerable, options = {}) {
|
|
|
200916
201094
|
const withHidden = settings2.enumerableKind ? Merge(withOptions, hidden) : MergeHidden(withOptions, hidden);
|
|
200917
201095
|
return settings2.immutableTypes ? Object.freeze(withHidden) : withHidden;
|
|
200918
201096
|
}
|
|
200919
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201097
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/memory/discard.mjs
|
|
200920
201098
|
function Discard(value, propertyKeys) {
|
|
200921
201099
|
Metrics.discard += 1;
|
|
200922
201100
|
const result = {};
|
|
@@ -200929,7 +201107,7 @@ function Discard(value, propertyKeys) {
|
|
|
200929
201107
|
}
|
|
200930
201108
|
return result;
|
|
200931
201109
|
}
|
|
200932
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201110
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/memory/update.mjs
|
|
200933
201111
|
function Update(current, hidden, enumerable) {
|
|
200934
201112
|
Metrics.update += 1;
|
|
200935
201113
|
const settings2 = exports_settings.Get();
|
|
@@ -200952,7 +201130,7 @@ function Update(current, hidden, enumerable) {
|
|
|
200952
201130
|
}
|
|
200953
201131
|
return result;
|
|
200954
201132
|
}
|
|
200955
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201133
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/schema.mjs
|
|
200956
201134
|
function IsKind(value, kind) {
|
|
200957
201135
|
return exports_guard.IsObject(value) && exports_guard.HasPropertyKey(value, "~kind") && exports_guard.IsEqual(value["~kind"], kind);
|
|
200958
201136
|
}
|
|
@@ -200960,136 +201138,41 @@ function IsSchema(value) {
|
|
|
200960
201138
|
return exports_guard.IsObject(value);
|
|
200961
201139
|
}
|
|
200962
201140
|
|
|
200963
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200964
|
-
function OptionalAddAction(type) {
|
|
200965
|
-
return exports_memory.Create({ ["~kind"]: "OptionalAddAction" }, { type }, {});
|
|
200966
|
-
}
|
|
200967
|
-
function IsOptionalAddAction(value) {
|
|
200968
|
-
return exports_guard.IsObject(value) && exports_guard.HasPropertyKey(value, "~kind") && exports_guard.HasPropertyKey(value, "type") && exports_guard.IsEqual(value["~kind"], "OptionalAddAction") && IsSchema(value.type);
|
|
200969
|
-
}
|
|
200970
|
-
function OptionalRemoveAction(type) {
|
|
200971
|
-
return exports_memory.Create({ ["~kind"]: "OptionalRemoveAction" }, { type }, {});
|
|
200972
|
-
}
|
|
200973
|
-
function IsOptionalRemoveAction(value) {
|
|
200974
|
-
return exports_guard.IsObject(value) && exports_guard.HasPropertyKey(value, "~kind") && exports_guard.HasPropertyKey(value, "type") && exports_guard.IsEqual(value["~kind"], "OptionalRemoveAction") && IsSchema(value.type);
|
|
200975
|
-
}
|
|
200976
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/action/_readonly.mjs
|
|
200977
|
-
function ReadonlyAddAction(type) {
|
|
200978
|
-
return exports_memory.Create({ ["~kind"]: "ReadonlyAddAction" }, { type }, {});
|
|
200979
|
-
}
|
|
200980
|
-
function IsReadonlyAddAction(value) {
|
|
200981
|
-
return exports_guard.IsObject(value) && exports_guard.HasPropertyKey(value, "~kind") && exports_guard.HasPropertyKey(value, "type") && exports_guard.IsEqual(value["~kind"], "ReadonlyAddAction") && IsSchema(value.type);
|
|
200982
|
-
}
|
|
200983
|
-
function ReadonlyRemoveAction(type) {
|
|
200984
|
-
return exports_memory.Create({ ["~kind"]: "ReadonlyRemoveAction" }, { type }, {});
|
|
200985
|
-
}
|
|
200986
|
-
function IsReadonlyRemoveAction(value) {
|
|
200987
|
-
return exports_guard.IsObject(value) && exports_guard.HasPropertyKey(value, "~kind") && exports_guard.HasPropertyKey(value, "type") && exports_guard.IsEqual(value["~kind"], "ReadonlyRemoveAction") && IsSchema(value.type);
|
|
200988
|
-
}
|
|
200989
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/types/deferred.mjs
|
|
201141
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/deferred.mjs
|
|
200990
201142
|
function Deferred(action, parameters, options) {
|
|
200991
|
-
return exports_memory.Create({ "~kind": "Deferred" }, { action, parameters, options }, {});
|
|
201143
|
+
return exports_memory.Create({ "~kind": "Deferred" }, { type: "deferred", action, parameters, options }, {});
|
|
200992
201144
|
}
|
|
200993
201145
|
function IsDeferred(value) {
|
|
200994
201146
|
return IsKind(value, "Deferred");
|
|
200995
201147
|
}
|
|
200996
201148
|
|
|
200997
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
200998
|
-
function
|
|
200999
|
-
return exports_memory.Create({ ["~kind"]: "Promise" }, { type: "promise", item }, options);
|
|
201000
|
-
}
|
|
201001
|
-
function IsPromise(value) {
|
|
201002
|
-
return IsKind(value, "Promise");
|
|
201003
|
-
}
|
|
201004
|
-
function PromiseOptions(type) {
|
|
201005
|
-
return exports_memory.Discard(type, ["~kind", "type", "item"]);
|
|
201006
|
-
}
|
|
201007
|
-
|
|
201008
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/types/_immutable.mjs
|
|
201009
|
-
function ImmutableAdd(type) {
|
|
201010
|
-
return exports_memory.Update(type, { "~immutable": true }, {});
|
|
201011
|
-
}
|
|
201012
|
-
function Immutable(type) {
|
|
201013
|
-
return ImmutableAdd(type);
|
|
201014
|
-
}
|
|
201015
|
-
function IsImmutable(value) {
|
|
201016
|
-
return IsSchema(value) && exports_guard.HasPropertyKey(value, "~immutable");
|
|
201017
|
-
}
|
|
201018
|
-
|
|
201019
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/types/_optional.mjs
|
|
201020
|
-
function OptionalRemove(type) {
|
|
201021
|
-
const result = exports_memory.Discard(type, ["~optional"]);
|
|
201022
|
-
return result;
|
|
201023
|
-
}
|
|
201024
|
-
function OptionalAdd(type) {
|
|
201025
|
-
return exports_memory.Update(type, { "~optional": true }, {});
|
|
201026
|
-
}
|
|
201027
|
-
function Optional(type) {
|
|
201028
|
-
return OptionalAdd(type);
|
|
201029
|
-
}
|
|
201030
|
-
function IsOptional(value) {
|
|
201031
|
-
return IsSchema(value) && exports_guard.HasPropertyKey(value, "~optional");
|
|
201032
|
-
}
|
|
201033
|
-
|
|
201034
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/types/_readonly.mjs
|
|
201035
|
-
function ReadonlyRemove(type) {
|
|
201036
|
-
return exports_memory.Discard(type, ["~readonly"]);
|
|
201037
|
-
}
|
|
201038
|
-
function ReadonlyAdd(type) {
|
|
201149
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly/instantiate_add.mjs
|
|
201150
|
+
function AddReadonlyOperation(type) {
|
|
201039
201151
|
return exports_memory.Update(type, { "~readonly": true }, {});
|
|
201040
201152
|
}
|
|
201041
|
-
function
|
|
201042
|
-
|
|
201153
|
+
function AddReadonlyAction(type, options) {
|
|
201154
|
+
const result = exports_memory.Update(AddReadonlyOperation(type), {}, options);
|
|
201155
|
+
return result;
|
|
201043
201156
|
}
|
|
201044
|
-
function
|
|
201045
|
-
|
|
201157
|
+
function AddReadonlyInstantiate(context, state, type, options) {
|
|
201158
|
+
const instantiatedType = InstantiateType(context, state, type);
|
|
201159
|
+
return AddReadonlyAction(instantiatedType, options);
|
|
201046
201160
|
}
|
|
201047
201161
|
|
|
201048
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201049
|
-
function
|
|
201050
|
-
return {
|
|
201051
|
-
enumerable: exports_settings.Get().enumerableKind,
|
|
201052
|
-
writable: false,
|
|
201053
|
-
configurable: false,
|
|
201054
|
-
value
|
|
201055
|
-
};
|
|
201162
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/optional/instantiate_add.mjs
|
|
201163
|
+
function AddOptionalOperation(type) {
|
|
201164
|
+
return exports_memory.Update(type, { "~optional": true }, {});
|
|
201056
201165
|
}
|
|
201057
|
-
|
|
201058
|
-
|
|
201059
|
-
|
|
201060
|
-
globalThis.Object.defineProperty(this, "~kind", BaseProperty("Base"));
|
|
201061
|
-
globalThis.Object.defineProperty(this, "~guard", BaseProperty({
|
|
201062
|
-
check: (value) => this.Check(value),
|
|
201063
|
-
errors: (value) => this.Errors(value)
|
|
201064
|
-
}));
|
|
201065
|
-
}
|
|
201066
|
-
Check(_value) {
|
|
201067
|
-
return true;
|
|
201068
|
-
}
|
|
201069
|
-
Errors(_value) {
|
|
201070
|
-
return [];
|
|
201071
|
-
}
|
|
201072
|
-
Convert(value) {
|
|
201073
|
-
return value;
|
|
201074
|
-
}
|
|
201075
|
-
Clean(value) {
|
|
201076
|
-
return value;
|
|
201077
|
-
}
|
|
201078
|
-
Default(value) {
|
|
201079
|
-
return value;
|
|
201080
|
-
}
|
|
201081
|
-
Create() {
|
|
201082
|
-
throw new Error("Create not implemented");
|
|
201083
|
-
}
|
|
201084
|
-
Clone() {
|
|
201085
|
-
throw Error("Clone not implemented");
|
|
201086
|
-
}
|
|
201166
|
+
function AddOptionalAction(type, options) {
|
|
201167
|
+
const result = exports_memory.Update(AddOptionalOperation(type), {}, options);
|
|
201168
|
+
return result;
|
|
201087
201169
|
}
|
|
201088
|
-
function
|
|
201089
|
-
|
|
201170
|
+
function AddOptionalInstantiate(context, state, type, options) {
|
|
201171
|
+
const instantiatedType = InstantiateType(context, state, type);
|
|
201172
|
+
return AddOptionalAction(instantiatedType, options);
|
|
201090
201173
|
}
|
|
201091
201174
|
|
|
201092
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201175
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/array.mjs
|
|
201093
201176
|
function _Array_(items, options) {
|
|
201094
201177
|
return exports_memory.Create({ "~kind": "Array" }, { type: "array", items }, options);
|
|
201095
201178
|
}
|
|
@@ -201100,18 +201183,7 @@ function ArrayOptions(type) {
|
|
|
201100
201183
|
return exports_memory.Discard(type, ["~kind", "type", "items"]);
|
|
201101
201184
|
}
|
|
201102
201185
|
|
|
201103
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201104
|
-
function AsyncIterator(iteratorItems, options) {
|
|
201105
|
-
return exports_memory.Create({ "~kind": "AsyncIterator" }, { type: "asyncIterator", iteratorItems }, options);
|
|
201106
|
-
}
|
|
201107
|
-
function IsAsyncIterator2(value) {
|
|
201108
|
-
return IsKind(value, "AsyncIterator");
|
|
201109
|
-
}
|
|
201110
|
-
function AsyncIteratorOptions(type) {
|
|
201111
|
-
return exports_memory.Discard(type, ["~kind", "type", "iteratorItems"]);
|
|
201112
|
-
}
|
|
201113
|
-
|
|
201114
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/types/constructor.mjs
|
|
201186
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/constructor.mjs
|
|
201115
201187
|
function Constructor(parameters, instanceType, options = {}) {
|
|
201116
201188
|
return exports_memory.Create({ "~kind": "Constructor" }, { type: "constructor", parameters, instanceType }, options);
|
|
201117
201189
|
}
|
|
@@ -201122,7 +201194,7 @@ function ConstructorOptions(type) {
|
|
|
201122
201194
|
return exports_memory.Discard(type, ["~kind", "type", "parameters", "instanceType"]);
|
|
201123
201195
|
}
|
|
201124
201196
|
|
|
201125
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201197
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/function.mjs
|
|
201126
201198
|
function _Function_(parameters, returnType, options = {}) {
|
|
201127
201199
|
return exports_memory.Create({ ["~kind"]: "Function" }, { type: "function", parameters, returnType }, options);
|
|
201128
201200
|
}
|
|
@@ -201133,7 +201205,7 @@ function FunctionOptions(type) {
|
|
|
201133
201205
|
return exports_memory.Discard(type, ["~kind", "type", "parameters", "returnType"]);
|
|
201134
201206
|
}
|
|
201135
201207
|
|
|
201136
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201208
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/ref.mjs
|
|
201137
201209
|
function Ref(ref, options) {
|
|
201138
201210
|
return exports_memory.Create({ ["~kind"]: "Ref" }, { $ref: ref }, options);
|
|
201139
201211
|
}
|
|
@@ -201141,7 +201213,7 @@ function IsRef(value) {
|
|
|
201141
201213
|
return IsKind(value, "Ref");
|
|
201142
201214
|
}
|
|
201143
201215
|
|
|
201144
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201216
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/generic.mjs
|
|
201145
201217
|
function Generic(parameters, expression) {
|
|
201146
201218
|
return exports_memory.Create({ "~kind": "Generic" }, { type: "generic", parameters, expression });
|
|
201147
201219
|
}
|
|
@@ -201149,7 +201221,7 @@ function IsGeneric(value) {
|
|
|
201149
201221
|
return IsKind(value, "Generic");
|
|
201150
201222
|
}
|
|
201151
201223
|
|
|
201152
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201224
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/any.mjs
|
|
201153
201225
|
function Any(options) {
|
|
201154
201226
|
return exports_memory.Create({ ["~kind"]: "Any" }, {}, options);
|
|
201155
201227
|
}
|
|
@@ -201157,7 +201229,7 @@ function IsAny(value) {
|
|
|
201157
201229
|
return IsKind(value, "Any");
|
|
201158
201230
|
}
|
|
201159
201231
|
|
|
201160
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201232
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/never.mjs
|
|
201161
201233
|
var NeverPattern = "(?!)";
|
|
201162
201234
|
function Never(options) {
|
|
201163
201235
|
return exports_memory.Create({ "~kind": "Never" }, { not: {} }, options);
|
|
@@ -201166,7 +201238,23 @@ function IsNever(value) {
|
|
|
201166
201238
|
return IsKind(value, "Never");
|
|
201167
201239
|
}
|
|
201168
201240
|
|
|
201169
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201241
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/_add_optional.mjs
|
|
201242
|
+
function AddOptionalDeferred(type, options = {}) {
|
|
201243
|
+
return Deferred("AddOptional", [type], options);
|
|
201244
|
+
}
|
|
201245
|
+
function AddOptional(type, options = {}) {
|
|
201246
|
+
return AddOptionalAction(type, options);
|
|
201247
|
+
}
|
|
201248
|
+
|
|
201249
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/_optional.mjs
|
|
201250
|
+
function Optional(type) {
|
|
201251
|
+
return AddOptional(type);
|
|
201252
|
+
}
|
|
201253
|
+
function IsOptional(value) {
|
|
201254
|
+
return IsSchema(value) && exports_guard.HasPropertyKey(value, "~optional");
|
|
201255
|
+
}
|
|
201256
|
+
|
|
201257
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/properties.mjs
|
|
201170
201258
|
function RequiredArray(properties) {
|
|
201171
201259
|
return exports_guard.Keys(properties).filter((key) => !IsOptional(properties[key]));
|
|
201172
201260
|
}
|
|
@@ -201177,7 +201265,7 @@ function PropertyValues(properties) {
|
|
|
201177
201265
|
return exports_guard.Values(properties);
|
|
201178
201266
|
}
|
|
201179
201267
|
|
|
201180
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201268
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/object.mjs
|
|
201181
201269
|
function _Object_(properties, options = {}) {
|
|
201182
201270
|
const requiredKeys = RequiredArray(properties);
|
|
201183
201271
|
const required2 = requiredKeys.length > 0 ? { required: requiredKeys } : {};
|
|
@@ -201190,18 +201278,7 @@ function ObjectOptions(type) {
|
|
|
201190
201278
|
return exports_memory.Discard(type, ["~kind", "type", "properties", "required"]);
|
|
201191
201279
|
}
|
|
201192
201280
|
|
|
201193
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201194
|
-
function Union(anyOf, options = {}) {
|
|
201195
|
-
return exports_memory.Create({ "~kind": "Union" }, { anyOf }, options);
|
|
201196
|
-
}
|
|
201197
|
-
function IsUnion(value) {
|
|
201198
|
-
return IsKind(value, "Union");
|
|
201199
|
-
}
|
|
201200
|
-
function UnionOptions(type) {
|
|
201201
|
-
return exports_memory.Discard(type, ["~kind", "anyOf"]);
|
|
201202
|
-
}
|
|
201203
|
-
|
|
201204
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/types/unknown.mjs
|
|
201281
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/unknown.mjs
|
|
201205
201282
|
function Unknown(options) {
|
|
201206
201283
|
return exports_memory.Create({ ["~kind"]: "Unknown" }, {}, options);
|
|
201207
201284
|
}
|
|
@@ -201209,7 +201286,7 @@ function IsUnknown(value) {
|
|
|
201209
201286
|
return IsKind(value, "Unknown");
|
|
201210
201287
|
}
|
|
201211
201288
|
|
|
201212
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201289
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/cyclic.mjs
|
|
201213
201290
|
function Cyclic($defs, $ref, options) {
|
|
201214
201291
|
const defs = exports_guard.Keys($defs).reduce((result, key) => {
|
|
201215
201292
|
return { ...result, [key]: exports_memory.Update($defs[key], {}, { $id: key }) };
|
|
@@ -201220,7 +201297,7 @@ function IsCyclic(value) {
|
|
|
201220
201297
|
return IsKind(value, "Cyclic");
|
|
201221
201298
|
}
|
|
201222
201299
|
|
|
201223
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201300
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/unsafe.mjs
|
|
201224
201301
|
function Unsafe(schema) {
|
|
201225
201302
|
return exports_memory.Update(schema, { ["~unsafe"]: null }, {});
|
|
201226
201303
|
}
|
|
@@ -201228,7 +201305,7 @@ function IsUnsafe(value) {
|
|
|
201228
201305
|
return exports_guard.IsObjectNotArray(value) && exports_guard.HasPropertyKey(value, "~unsafe") && exports_guard.IsNull(value["~unsafe"]);
|
|
201229
201306
|
}
|
|
201230
201307
|
|
|
201231
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201308
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/arguments/arguments.mjs
|
|
201232
201309
|
var exports_arguments = {};
|
|
201233
201310
|
__export(exports_arguments, {
|
|
201234
201311
|
Match: () => Match
|
|
@@ -201238,7 +201315,7 @@ function Match(args, match) {
|
|
|
201238
201315
|
throw Error("Invalid Arguments");
|
|
201239
201316
|
})();
|
|
201240
201317
|
}
|
|
201241
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201318
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/infer.mjs
|
|
201242
201319
|
function Infer(...args) {
|
|
201243
201320
|
const [name2, extends_] = exports_arguments.Match(args, {
|
|
201244
201321
|
2: (name3, extends_2) => [name3, extends_2, extends_2],
|
|
@@ -201250,7 +201327,18 @@ function IsInfer(value) {
|
|
|
201250
201327
|
return IsKind(value, "Infer");
|
|
201251
201328
|
}
|
|
201252
201329
|
|
|
201253
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201330
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/dependent.mjs
|
|
201331
|
+
function Dependent(if_, then_, else_, options = {}) {
|
|
201332
|
+
return exports_memory.Create({ "~kind": "Dependent" }, { if: if_, then: then_, else: else_ }, options);
|
|
201333
|
+
}
|
|
201334
|
+
function IsDependent(value) {
|
|
201335
|
+
return IsKind(value, "Dependent");
|
|
201336
|
+
}
|
|
201337
|
+
function DependentOptions(type) {
|
|
201338
|
+
return exports_memory.Discard(type, ["~kind", "if", "then", "else"]);
|
|
201339
|
+
}
|
|
201340
|
+
|
|
201341
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/enum/typescript_enum_to_enum_values.mjs
|
|
201254
201342
|
function IsTypeScriptEnumLike(value) {
|
|
201255
201343
|
return exports_guard.IsObjectNotArray(value);
|
|
201256
201344
|
}
|
|
@@ -201259,7 +201347,7 @@ function TypeScriptEnumToEnumValues(type) {
|
|
|
201259
201347
|
return keys.reduce((result, key) => [...result, type[key]], []);
|
|
201260
201348
|
}
|
|
201261
201349
|
|
|
201262
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201350
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/enum.mjs
|
|
201263
201351
|
function Enum(value, options) {
|
|
201264
201352
|
const values = IsTypeScriptEnumLike(value) ? TypeScriptEnumToEnumValues(value) : value;
|
|
201265
201353
|
return exports_memory.Create({ "~kind": "Enum" }, { enum: values }, options);
|
|
@@ -201268,7 +201356,7 @@ function IsEnum(value) {
|
|
|
201268
201356
|
return IsKind(value, "Enum");
|
|
201269
201357
|
}
|
|
201270
201358
|
|
|
201271
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201359
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/intersect.mjs
|
|
201272
201360
|
function Intersect(types2, options = {}) {
|
|
201273
201361
|
return exports_memory.Create({ "~kind": "Intersect" }, { allOf: types2 }, options);
|
|
201274
201362
|
}
|
|
@@ -201278,11 +201366,11 @@ function IsIntersect(value) {
|
|
|
201278
201366
|
function IntersectOptions(type) {
|
|
201279
201367
|
return exports_memory.Discard(type, ["~kind", "allOf"]);
|
|
201280
201368
|
}
|
|
201281
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201369
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/unreachable/unreachable.mjs
|
|
201282
201370
|
function Unreachable() {
|
|
201283
201371
|
throw new Error("Unreachable");
|
|
201284
201372
|
}
|
|
201285
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201373
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/system/hashing/hash.mjs
|
|
201286
201374
|
var ByteMarker;
|
|
201287
201375
|
(function(ByteMarker2) {
|
|
201288
201376
|
ByteMarker2[ByteMarker2["Array"] = 0] = "Array";
|
|
@@ -201307,7 +201395,7 @@ var F64 = new Float64Array(1);
|
|
|
201307
201395
|
var F64In = new DataView(F64.buffer);
|
|
201308
201396
|
var F64Out = new Uint8Array(F64.buffer);
|
|
201309
201397
|
var encoder2 = new TextEncoder;
|
|
201310
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201398
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/_codec.mjs
|
|
201311
201399
|
class EncodeBuilder {
|
|
201312
201400
|
constructor(type, decode3) {
|
|
201313
201401
|
this.type = type;
|
|
@@ -201346,17 +201434,38 @@ function Encode(type, callback) {
|
|
|
201346
201434
|
function IsCodec(value) {
|
|
201347
201435
|
return IsSchema(value) && exports_guard.HasPropertyKey(value, "~codec") && exports_guard.IsObject(value["~codec"]) && exports_guard.HasPropertyKey(value["~codec"], "encode") && exports_guard.HasPropertyKey(value["~codec"], "decode");
|
|
201348
201436
|
}
|
|
201349
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201437
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/_immutable.mjs
|
|
201438
|
+
function Immutable(type) {
|
|
201439
|
+
return AddImmutable(type);
|
|
201440
|
+
}
|
|
201441
|
+
function IsImmutable(value) {
|
|
201442
|
+
return IsSchema(value) && exports_guard.HasPropertyKey(value, "~immutable");
|
|
201443
|
+
}
|
|
201444
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/_add_readonly.mjs
|
|
201445
|
+
function AddReadonlyDeferred(type, options = {}) {
|
|
201446
|
+
return Deferred("AddReadonly", [type], options);
|
|
201447
|
+
}
|
|
201448
|
+
function AddReadonly(type, options = {}) {
|
|
201449
|
+
return AddReadonlyAction(type, options);
|
|
201450
|
+
}
|
|
201451
|
+
|
|
201452
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/_readonly.mjs
|
|
201453
|
+
function Readonly(type) {
|
|
201454
|
+
return AddReadonly(type);
|
|
201455
|
+
}
|
|
201456
|
+
function IsReadonly(value) {
|
|
201457
|
+
return IsSchema(value) && exports_guard.HasPropertyKey(value, "~readonly");
|
|
201458
|
+
}
|
|
201459
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/_refine.mjs
|
|
201350
201460
|
function RefineAdd(type, refinement) {
|
|
201351
201461
|
const refinements = IsRefine(type) ? [...type["~refine"], refinement] : [refinement];
|
|
201352
201462
|
return exports_memory.Update(type, { "~refine": refinements }, {});
|
|
201353
201463
|
}
|
|
201354
201464
|
function Refine(...args) {
|
|
201355
|
-
const [type, check2,
|
|
201465
|
+
const [type, check2, error51] = exports_arguments.Match(args, {
|
|
201356
201466
|
3: (type2, check3, error52) => [type2, check3, error52],
|
|
201357
201467
|
2: (type2, check3) => [type2, check3, () => "Refine Error"]
|
|
201358
201468
|
});
|
|
201359
|
-
const error51 = exports_guard.IsString(error_or_message) ? () => error_or_message : error_or_message;
|
|
201360
201469
|
return RefineAdd(type, { check: check2, error: error51 });
|
|
201361
201470
|
}
|
|
201362
201471
|
function IsRefinement(value) {
|
|
@@ -201365,7 +201474,7 @@ function IsRefinement(value) {
|
|
|
201365
201474
|
function IsRefine(value) {
|
|
201366
201475
|
return IsSchema(value) && exports_guard.HasPropertyKey(value, "~refine") && exports_guard.IsArray(value["~refine"]) && exports_guard.Every(value["~refine"], 0, (value2) => IsRefinement(value2));
|
|
201367
201476
|
}
|
|
201368
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201477
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/bigint.mjs
|
|
201369
201478
|
var BigIntPattern = "-?(?:0|[1-9][0-9]*)n";
|
|
201370
201479
|
function BigInt2(options) {
|
|
201371
201480
|
return exports_memory.Create({ "~kind": "BigInt" }, { type: "bigint" }, options);
|
|
@@ -201373,21 +201482,21 @@ function BigInt2(options) {
|
|
|
201373
201482
|
function IsBigInt2(value) {
|
|
201374
201483
|
return IsKind(value, "BigInt");
|
|
201375
201484
|
}
|
|
201376
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201485
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/boolean.mjs
|
|
201377
201486
|
function Boolean2(options) {
|
|
201378
201487
|
return exports_memory.Create({ "~kind": "Boolean" }, { type: "boolean" }, options);
|
|
201379
201488
|
}
|
|
201380
|
-
function
|
|
201489
|
+
function IsBoolean3(value) {
|
|
201381
201490
|
return IsKind(value, "Boolean");
|
|
201382
201491
|
}
|
|
201383
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201492
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/identifier.mjs
|
|
201384
201493
|
function Identifier(name2) {
|
|
201385
201494
|
return exports_memory.Create({ "~kind": "Identifier" }, { name: name2 });
|
|
201386
201495
|
}
|
|
201387
201496
|
function IsIdentifier(value) {
|
|
201388
201497
|
return IsKind(value, "Identifier");
|
|
201389
201498
|
}
|
|
201390
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201499
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/integer.mjs
|
|
201391
201500
|
var IntegerPattern = "-?(?:0|[1-9][0-9]*)";
|
|
201392
201501
|
function Integer(options) {
|
|
201393
201502
|
return exports_memory.Create({ "~kind": "Integer" }, { type: "integer" }, options);
|
|
@@ -201395,17 +201504,7 @@ function Integer(options) {
|
|
|
201395
201504
|
function IsInteger2(value) {
|
|
201396
201505
|
return IsKind(value, "Integer");
|
|
201397
201506
|
}
|
|
201398
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201399
|
-
function Iterator(iteratorItems, options) {
|
|
201400
|
-
return exports_memory.Create({ "~kind": "Iterator" }, { type: "iterator", iteratorItems }, options);
|
|
201401
|
-
}
|
|
201402
|
-
function IsIterator2(value) {
|
|
201403
|
-
return IsKind(value, "Iterator");
|
|
201404
|
-
}
|
|
201405
|
-
function IteratorOptions(type) {
|
|
201406
|
-
return exports_memory.Discard(type, ["~kind", "type", "iteratorItems"]);
|
|
201407
|
-
}
|
|
201408
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/types/literal.mjs
|
|
201507
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/literal.mjs
|
|
201409
201508
|
class InvalidLiteralValue extends Error {
|
|
201410
201509
|
constructor(value) {
|
|
201411
201510
|
super(`Invalid Literal value`);
|
|
@@ -201437,29 +201536,29 @@ function IsLiteralString(value) {
|
|
|
201437
201536
|
function IsLiteral(value) {
|
|
201438
201537
|
return IsKind(value, "Literal");
|
|
201439
201538
|
}
|
|
201440
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201539
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/null.mjs
|
|
201441
201540
|
function Null(options) {
|
|
201442
201541
|
return exports_memory.Create({ "~kind": "Null" }, { type: "null" }, options);
|
|
201443
201542
|
}
|
|
201444
201543
|
function IsNull2(value) {
|
|
201445
201544
|
return IsKind(value, "Null");
|
|
201446
201545
|
}
|
|
201447
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201448
|
-
var NumberPattern = "-?(?:0|[1-9][0-9]*)(
|
|
201546
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/number.mjs
|
|
201547
|
+
var NumberPattern = "-?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?";
|
|
201449
201548
|
function Number2(options) {
|
|
201450
201549
|
return exports_memory.Create({ "~kind": "Number" }, { type: "number" }, options);
|
|
201451
201550
|
}
|
|
201452
|
-
function
|
|
201551
|
+
function IsNumber3(value) {
|
|
201453
201552
|
return IsKind(value, "Number");
|
|
201454
201553
|
}
|
|
201455
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201554
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/symbol.mjs
|
|
201456
201555
|
function Symbol2(options) {
|
|
201457
201556
|
return exports_memory.Create({ "~kind": "Symbol" }, { type: "symbol" }, options);
|
|
201458
201557
|
}
|
|
201459
201558
|
function IsSymbol2(value) {
|
|
201460
201559
|
return IsKind(value, "Symbol");
|
|
201461
201560
|
}
|
|
201462
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201561
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/parameter.mjs
|
|
201463
201562
|
function Parameter(...args) {
|
|
201464
201563
|
const [name2, extends_, equals] = exports_arguments.Match(args, {
|
|
201465
201564
|
3: (name3, extends_2, equals2) => [name3, extends_2, equals2],
|
|
@@ -201471,28 +201570,39 @@ function Parameter(...args) {
|
|
|
201471
201570
|
function IsParameter(value) {
|
|
201472
201571
|
return IsKind(value, "Parameter");
|
|
201473
201572
|
}
|
|
201474
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201573
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/string.mjs
|
|
201475
201574
|
var StringPattern = ".*";
|
|
201476
201575
|
function String2(options) {
|
|
201477
201576
|
return exports_memory.Create({ "~kind": "String" }, { type: "string" }, options);
|
|
201478
201577
|
}
|
|
201479
|
-
function
|
|
201578
|
+
function IsString3(value) {
|
|
201480
201579
|
return IsKind(value, "String");
|
|
201481
201580
|
}
|
|
201482
201581
|
|
|
201483
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201582
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/union.mjs
|
|
201583
|
+
function Union(anyOf, options = {}) {
|
|
201584
|
+
return exports_memory.Create({ "~kind": "Union" }, { anyOf }, options);
|
|
201585
|
+
}
|
|
201586
|
+
function IsUnion(value) {
|
|
201587
|
+
return IsKind(value, "Union");
|
|
201588
|
+
}
|
|
201589
|
+
function UnionOptions(type) {
|
|
201590
|
+
return exports_memory.Discard(type, ["~kind", "anyOf"]);
|
|
201591
|
+
}
|
|
201592
|
+
|
|
201593
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/patterns/pattern.mjs
|
|
201484
201594
|
function ParsePatternIntoTypes(pattern) {
|
|
201485
201595
|
const parsed = Pattern(pattern);
|
|
201486
201596
|
const result = exports_guard.IsEqual(parsed.length, 2) ? parsed[0] : [];
|
|
201487
201597
|
return result;
|
|
201488
201598
|
}
|
|
201489
201599
|
|
|
201490
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201600
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/template_literal/is_finite.mjs
|
|
201491
201601
|
function FromLiteral(_value) {
|
|
201492
201602
|
return true;
|
|
201493
201603
|
}
|
|
201494
201604
|
function FromTypesReduce(types2) {
|
|
201495
|
-
return exports_guard.
|
|
201605
|
+
return exports_guard.ShiftLeft(types2, (left, right) => FromType(left) ? FromTypesReduce(right) : false, () => true);
|
|
201496
201606
|
}
|
|
201497
201607
|
function FromTypes(types2) {
|
|
201498
201608
|
const result = exports_guard.IsEqual(types2.length, 0) ? false : FromTypesReduce(types2);
|
|
@@ -201506,27 +201616,27 @@ function IsTemplateLiteralFinite(types2) {
|
|
|
201506
201616
|
return result;
|
|
201507
201617
|
}
|
|
201508
201618
|
|
|
201509
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201619
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/template_literal/create.mjs
|
|
201510
201620
|
function TemplateLiteralCreate(pattern) {
|
|
201511
201621
|
return exports_memory.Create({ ["~kind"]: "TemplateLiteral" }, { type: "string", pattern }, {});
|
|
201512
201622
|
}
|
|
201513
201623
|
|
|
201514
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201624
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/template_literal/decode.mjs
|
|
201515
201625
|
function FromLiteralPush(variants, value, result = []) {
|
|
201516
|
-
return exports_guard.
|
|
201626
|
+
return exports_guard.ShiftLeft(variants, (left, right) => FromLiteralPush(right, value, [...result, `${left}${value}`]), () => result);
|
|
201517
201627
|
}
|
|
201518
201628
|
function FromLiteral2(variants, value) {
|
|
201519
201629
|
return exports_guard.IsEqual(variants.length, 0) ? [`${value}`] : FromLiteralPush(variants, value);
|
|
201520
201630
|
}
|
|
201521
201631
|
function FromUnion(variants, types2, result = []) {
|
|
201522
|
-
return exports_guard.
|
|
201632
|
+
return exports_guard.ShiftLeft(types2, (left, right) => FromUnion(variants, right, [...result, ...FromType2(variants, left)]), () => result);
|
|
201523
201633
|
}
|
|
201524
201634
|
function FromType2(variants, type) {
|
|
201525
201635
|
const result = IsUnion(type) ? FromUnion(variants, type.anyOf) : IsLiteral(type) ? FromLiteral2(variants, type.const) : Unreachable();
|
|
201526
201636
|
return result;
|
|
201527
201637
|
}
|
|
201528
201638
|
function DecodeFromSpan(variants, types2) {
|
|
201529
|
-
return exports_guard.
|
|
201639
|
+
return exports_guard.ShiftLeft(types2, (left, right) => DecodeFromSpan(FromType2(variants, left), right), () => variants);
|
|
201530
201640
|
}
|
|
201531
201641
|
function VariantsToLiterals(variants) {
|
|
201532
201642
|
return variants.map((variant) => Literal(variant));
|
|
@@ -201551,67 +201661,78 @@ function TemplateLiteralDecode(pattern) {
|
|
|
201551
201661
|
return result;
|
|
201552
201662
|
}
|
|
201553
201663
|
|
|
201554
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201664
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/record_create.mjs
|
|
201555
201665
|
function CreateRecord(key, value) {
|
|
201556
201666
|
const type = "object";
|
|
201557
201667
|
const patternProperties = { [key]: value };
|
|
201558
201668
|
return exports_memory.Create({ ["~kind"]: "Record" }, { type, patternProperties });
|
|
201559
201669
|
}
|
|
201560
201670
|
|
|
201561
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201671
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_any.mjs
|
|
201562
201672
|
function FromAnyKey(value) {
|
|
201563
201673
|
return CreateRecord(StringKey, value);
|
|
201564
201674
|
}
|
|
201565
201675
|
|
|
201566
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201676
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_boolean.mjs
|
|
201567
201677
|
function FromBooleanKey(value) {
|
|
201568
201678
|
return _Object_({ true: value, false: value });
|
|
201569
201679
|
}
|
|
201570
201680
|
|
|
201571
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201572
|
-
function
|
|
201573
|
-
|
|
201681
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/tuple.mjs
|
|
201682
|
+
function Tuple(types2, options = {}) {
|
|
201683
|
+
const [items, minItems, additionalItems] = [types2, types2.length, false];
|
|
201684
|
+
return exports_memory.Create({ ["~kind"]: "Tuple" }, { type: "array", additionalItems, items, minItems }, options);
|
|
201574
201685
|
}
|
|
201575
|
-
function
|
|
201576
|
-
|
|
201577
|
-
return result;
|
|
201686
|
+
function IsTuple(value) {
|
|
201687
|
+
return IsKind(value, "Tuple");
|
|
201578
201688
|
}
|
|
201579
|
-
function
|
|
201580
|
-
|
|
201581
|
-
|
|
201582
|
-
|
|
201689
|
+
function TupleOptions(type) {
|
|
201690
|
+
return exports_memory.Discard(type, ["~kind", "type", "items", "minItems", "additionalItems"]);
|
|
201691
|
+
}
|
|
201692
|
+
|
|
201693
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly/instantiate_remove.mjs
|
|
201694
|
+
function RemoveReadonlyOperation(type) {
|
|
201695
|
+
return exports_memory.Discard(type, ["~readonly"]);
|
|
201583
201696
|
}
|
|
201584
|
-
function
|
|
201585
|
-
const result =
|
|
201697
|
+
function RemoveReadonlyAction(type, options) {
|
|
201698
|
+
const result = exports_memory.Update(RemoveReadonlyOperation(type), {}, options);
|
|
201586
201699
|
return result;
|
|
201587
201700
|
}
|
|
201701
|
+
function RemoveReadonlyInstantiate(context, state, type, options) {
|
|
201702
|
+
const instantiatedType = InstantiateType(context, state, type);
|
|
201703
|
+
return RemoveReadonlyAction(instantiatedType, options);
|
|
201704
|
+
}
|
|
201588
201705
|
|
|
201589
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201590
|
-
function
|
|
201591
|
-
|
|
201592
|
-
|
|
201593
|
-
|
|
201706
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/_remove_readonly.mjs
|
|
201707
|
+
function RemoveReadonlyDeferred(type, options = {}) {
|
|
201708
|
+
return Deferred("RemoveReadonly", [type], options);
|
|
201709
|
+
}
|
|
201710
|
+
function RemoveReadonly(type, options = {}) {
|
|
201711
|
+
return RemoveReadonlyAction(type, options);
|
|
201594
201712
|
}
|
|
201595
201713
|
|
|
201596
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201597
|
-
function
|
|
201598
|
-
|
|
201714
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/optional/instantiate_remove.mjs
|
|
201715
|
+
function RemoveOptionalOperation(type) {
|
|
201716
|
+
return exports_memory.Discard(type, ["~optional"]);
|
|
201717
|
+
}
|
|
201718
|
+
function RemoveOptionalAction(type, options) {
|
|
201719
|
+
const result = exports_memory.Update(RemoveOptionalOperation(type), {}, options);
|
|
201599
201720
|
return result;
|
|
201600
201721
|
}
|
|
201601
|
-
|
|
201602
|
-
|
|
201603
|
-
|
|
201604
|
-
const [items, minItems, additionalItems] = [types2, types2.length, false];
|
|
201605
|
-
return exports_memory.Create({ ["~kind"]: "Tuple" }, { type: "array", additionalItems, items, minItems }, options);
|
|
201722
|
+
function RemoveOptionalInstantiate(context, state, type, options) {
|
|
201723
|
+
const instantiatedType = InstantiateType(context, state, type);
|
|
201724
|
+
return RemoveOptionalAction(instantiatedType, options);
|
|
201606
201725
|
}
|
|
201607
|
-
|
|
201608
|
-
|
|
201726
|
+
|
|
201727
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/_remove_optional.mjs
|
|
201728
|
+
function RemoveOptionalDeferred(type, options = {}) {
|
|
201729
|
+
return Deferred("RemoveOptional", [type], options);
|
|
201609
201730
|
}
|
|
201610
|
-
function
|
|
201611
|
-
return
|
|
201731
|
+
function RemoveOptional(type, options = {}) {
|
|
201732
|
+
return RemoveOptionalAction(type, options);
|
|
201612
201733
|
}
|
|
201613
201734
|
|
|
201614
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201735
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/tuple/to_object.mjs
|
|
201615
201736
|
function TupleElementsToProperties(types2) {
|
|
201616
201737
|
const result = types2.reduceRight((result2, right, index) => {
|
|
201617
201738
|
return { [index]: right, ...result2 };
|
|
@@ -201624,7 +201745,7 @@ function TupleToObject(type) {
|
|
|
201624
201745
|
return result;
|
|
201625
201746
|
}
|
|
201626
201747
|
|
|
201627
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201748
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/evaluate/composite.mjs
|
|
201628
201749
|
function IsReadonlyProperty(left, right) {
|
|
201629
201750
|
return IsReadonly(left) ? IsReadonly(right) ? true : false : false;
|
|
201630
201751
|
}
|
|
@@ -201635,8 +201756,8 @@ function CompositeProperty(left, right) {
|
|
|
201635
201756
|
const isReadonly = IsReadonlyProperty(left, right);
|
|
201636
201757
|
const isOptional = IsOptionalProperty(left, right);
|
|
201637
201758
|
const evaluated = EvaluateIntersect([left, right]);
|
|
201638
|
-
const property =
|
|
201639
|
-
return isReadonly && isOptional ?
|
|
201759
|
+
const property = RemoveReadonly(RemoveOptional(evaluated));
|
|
201760
|
+
return isReadonly && isOptional ? AddReadonly(AddOptional(property)) : isReadonly && !isOptional ? AddReadonly(property) : !isReadonly && isOptional ? AddOptional(property) : property;
|
|
201640
201761
|
}
|
|
201641
201762
|
function CompositePropertyKey(left, right, key) {
|
|
201642
201763
|
return key in left ? key in right ? CompositeProperty(left[key], right[key]) : left[key] : (key in right) ? right[key] : Never();
|
|
@@ -201658,13 +201779,13 @@ function Composite(left, right) {
|
|
|
201658
201779
|
return _Object_(properties);
|
|
201659
201780
|
}
|
|
201660
201781
|
|
|
201661
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201782
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/evaluate/narrow.mjs
|
|
201662
201783
|
function Narrow(left, right) {
|
|
201663
201784
|
const result = Compare(left, right);
|
|
201664
201785
|
return exports_guard.IsEqual(result, ResultLeftInside) ? left : exports_guard.IsEqual(result, ResultRightInside) ? right : exports_guard.IsEqual(result, ResultEqual) ? right : Never();
|
|
201665
201786
|
}
|
|
201666
201787
|
|
|
201667
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201788
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/evaluate/distribute.mjs
|
|
201668
201789
|
function IsObjectLike(type) {
|
|
201669
201790
|
return IsObject2(type) || IsTuple(type);
|
|
201670
201791
|
}
|
|
@@ -201684,65 +201805,114 @@ function DistributeOperation(left, right) {
|
|
|
201684
201805
|
return result;
|
|
201685
201806
|
}
|
|
201686
201807
|
function DistributeType(type, types2, result = []) {
|
|
201687
|
-
return exports_guard.
|
|
201808
|
+
return exports_guard.ShiftLeft(types2, (left, right) => DistributeType(type, right, [...result, DistributeOperation(type, left)]), () => exports_guard.IsEqual(result.length, 0) ? [type] : result);
|
|
201688
201809
|
}
|
|
201689
201810
|
function DistributeUnion(types2, distribution, result = []) {
|
|
201690
|
-
return exports_guard.
|
|
201811
|
+
return exports_guard.ShiftLeft(types2, (left, right) => DistributeUnion(right, distribution, [...result, ...Distribute([left], distribution)]), () => result);
|
|
201691
201812
|
}
|
|
201692
201813
|
function Distribute(types2, result = []) {
|
|
201693
|
-
return exports_guard.
|
|
201814
|
+
return exports_guard.ShiftLeft(types2, (left, right) => IsUnion(left) ? Distribute(right, DistributeUnion(left.anyOf, result)) : Distribute(right, DistributeType(left, result)), () => result);
|
|
201815
|
+
}
|
|
201816
|
+
|
|
201817
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/exclude/operation.mjs
|
|
201818
|
+
function ExcludeType(left, right) {
|
|
201819
|
+
const check2 = Extends({}, left, right);
|
|
201820
|
+
const result = exports_result.IsExtendsTrueLike(check2) ? [] : [left];
|
|
201821
|
+
return result;
|
|
201822
|
+
}
|
|
201823
|
+
function ExcludeUnion(types2, right) {
|
|
201824
|
+
return types2.reduce((result, head) => {
|
|
201825
|
+
return [...result, ...ExcludeType(head, right)];
|
|
201826
|
+
}, []);
|
|
201827
|
+
}
|
|
201828
|
+
function ExcludeOperation(left, right) {
|
|
201829
|
+
const evaluated = EvaluateType(left);
|
|
201830
|
+
const canonical = IsUnion(evaluated) ? evaluated.anyOf : [evaluated];
|
|
201831
|
+
const remaining = ExcludeUnion(canonical, right);
|
|
201832
|
+
const result = EvaluateUnion(remaining);
|
|
201833
|
+
return result;
|
|
201694
201834
|
}
|
|
201695
201835
|
|
|
201696
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201836
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/evaluate/evaluate.mjs
|
|
201837
|
+
function EvaluateDependent(if_, then_, else_) {
|
|
201838
|
+
const intersect = Intersect([if_, then_]);
|
|
201839
|
+
const excluded = ExcludeOperation(else_, if_);
|
|
201840
|
+
const result = EvaluateUnion([intersect, excluded]);
|
|
201841
|
+
return result;
|
|
201842
|
+
}
|
|
201843
|
+
function EvaluateEnum(values) {
|
|
201844
|
+
const result = values.map((value) => Literal(value));
|
|
201845
|
+
return EvaluateUnion(result);
|
|
201846
|
+
}
|
|
201697
201847
|
function EvaluateIntersect(types2) {
|
|
201698
201848
|
const distribution = Distribute(types2);
|
|
201699
|
-
const
|
|
201849
|
+
const broadend = Broaden(distribution);
|
|
201850
|
+
const result = EvaluateUnionFast(broadend);
|
|
201851
|
+
return result;
|
|
201852
|
+
}
|
|
201853
|
+
function EvaluateTemplateLiteral(pattern) {
|
|
201854
|
+
const evaluated = TemplateLiteralDecode(pattern);
|
|
201855
|
+
const result = EvaluateType(evaluated);
|
|
201700
201856
|
return result;
|
|
201701
201857
|
}
|
|
201702
201858
|
function EvaluateUnion(types2) {
|
|
201703
|
-
const
|
|
201859
|
+
const broadend = Broaden(types2);
|
|
201860
|
+
const result = EvaluateUnionFast(broadend);
|
|
201704
201861
|
return result;
|
|
201705
201862
|
}
|
|
201706
201863
|
function EvaluateType(type) {
|
|
201707
|
-
return IsIntersect(type) ? EvaluateIntersect(type.allOf) : IsUnion(type) ? EvaluateUnion(type.anyOf) : type;
|
|
201864
|
+
return IsDependent(type) ? EvaluateDependent(type.if, type.then, type.else) : IsEnum(type) ? EvaluateEnum(type.enum) : IsIntersect(type) ? EvaluateIntersect(type.allOf) : IsTemplateLiteral(type) ? EvaluateTemplateLiteral(type.pattern) : IsUnion(type) ? EvaluateUnion(type.anyOf) : type;
|
|
201708
201865
|
}
|
|
201709
201866
|
function EvaluateUnionFast(types2) {
|
|
201710
201867
|
const result = exports_guard.IsEqual(types2.length, 1) ? types2[0] : exports_guard.IsEqual(types2.length, 0) ? Never() : Union(types2);
|
|
201711
201868
|
return result;
|
|
201712
201869
|
}
|
|
201713
201870
|
|
|
201714
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201871
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_enum.mjs
|
|
201872
|
+
function FromEnumKey(values, value) {
|
|
201873
|
+
const unionKey = EvaluateEnum(values);
|
|
201874
|
+
const result = FromKey(unionKey, value);
|
|
201875
|
+
return result;
|
|
201876
|
+
}
|
|
201877
|
+
|
|
201878
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_integer.mjs
|
|
201879
|
+
function FromIntegerKey(_key, value) {
|
|
201880
|
+
const result = CreateRecord(IntegerKey, value);
|
|
201881
|
+
return result;
|
|
201882
|
+
}
|
|
201883
|
+
|
|
201884
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_intersect.mjs
|
|
201715
201885
|
function FromIntersectKey(types2, value) {
|
|
201716
201886
|
const evaluatedKey = EvaluateIntersect(types2);
|
|
201717
201887
|
const result = FromKey(evaluatedKey, value);
|
|
201718
201888
|
return result;
|
|
201719
201889
|
}
|
|
201720
201890
|
|
|
201721
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201891
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_literal.mjs
|
|
201722
201892
|
function FromLiteralKey(key, value) {
|
|
201723
201893
|
return exports_guard.IsString(key) || exports_guard.IsNumber(key) ? _Object_({ [key]: value }) : exports_guard.IsEqual(key, false) ? _Object_({ false: value }) : exports_guard.IsEqual(key, true) ? _Object_({ true: value }) : _Object_({});
|
|
201724
201894
|
}
|
|
201725
201895
|
|
|
201726
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201896
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_number.mjs
|
|
201727
201897
|
function FromNumberKey(_key, value) {
|
|
201728
201898
|
const result = CreateRecord(NumberKey, value);
|
|
201729
201899
|
return result;
|
|
201730
201900
|
}
|
|
201731
201901
|
|
|
201732
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201902
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_string.mjs
|
|
201733
201903
|
function FromStringKey(key, value) {
|
|
201734
201904
|
return exports_guard.HasPropertyKey(key, "pattern") && (exports_guard.IsString(key.pattern) || key.pattern instanceof RegExp) ? CreateRecord(key.pattern.toString(), value) : CreateRecord(StringKey, value);
|
|
201735
201905
|
}
|
|
201736
201906
|
|
|
201737
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201907
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_template_literal.mjs
|
|
201738
201908
|
function FromTemplateKey(pattern, value) {
|
|
201739
201909
|
const types2 = ParsePatternIntoTypes(pattern);
|
|
201740
201910
|
const finite = IsTemplateLiteralFinite(types2);
|
|
201741
|
-
const result = finite ? FromKey(
|
|
201911
|
+
const result = finite ? FromKey(EvaluateTemplateLiteral(pattern), value) : CreateRecord(pattern, value);
|
|
201742
201912
|
return result;
|
|
201743
201913
|
}
|
|
201744
201914
|
|
|
201745
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201915
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/evaluate/flatten.mjs
|
|
201746
201916
|
function FlattenType(type) {
|
|
201747
201917
|
const result = IsUnion(type) ? Flatten(type.anyOf) : [type];
|
|
201748
201918
|
return result;
|
|
@@ -201753,9 +201923,9 @@ function Flatten(types2) {
|
|
|
201753
201923
|
}, []);
|
|
201754
201924
|
}
|
|
201755
201925
|
|
|
201756
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201926
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key_union.mjs
|
|
201757
201927
|
function StringOrNumberCheck(types2) {
|
|
201758
|
-
return types2.some((type) =>
|
|
201928
|
+
return types2.some((type) => IsString3(type) || IsNumber3(type) || IsInteger2(type));
|
|
201759
201929
|
}
|
|
201760
201930
|
function TryBuildRecord(types2, value) {
|
|
201761
201931
|
return exports_guard.IsEqual(StringOrNumberCheck(types2), true) ? CreateRecord(StringKey, value) : undefined;
|
|
@@ -201776,13 +201946,13 @@ function FromUnionKey(types2, value) {
|
|
|
201776
201946
|
return IsSchema(record2) ? record2 : CreateObject(flattened, value);
|
|
201777
201947
|
}
|
|
201778
201948
|
|
|
201779
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201949
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/from_key.mjs
|
|
201780
201950
|
function FromKey(key, value) {
|
|
201781
|
-
const result = IsAny(key) ? FromAnyKey(value) :
|
|
201951
|
+
const result = IsAny(key) ? FromAnyKey(value) : IsBoolean3(key) ? FromBooleanKey(value) : IsEnum(key) ? FromEnumKey(key.enum, value) : IsInteger2(key) ? FromIntegerKey(key, value) : IsIntersect(key) ? FromIntersectKey(key.allOf, value) : IsLiteral(key) ? FromLiteralKey(key.const, value) : IsNumber3(key) ? FromNumberKey(key, value) : IsUnion(key) ? FromUnionKey(key.anyOf, value) : IsString3(key) ? FromStringKey(key, value) : IsTemplateLiteral(key) ? FromTemplateKey(key.pattern, value) : _Object_({});
|
|
201782
201952
|
return result;
|
|
201783
201953
|
}
|
|
201784
201954
|
|
|
201785
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201955
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/record/instantiate.mjs
|
|
201786
201956
|
function RecordAction(key, value, options) {
|
|
201787
201957
|
const result = CanInstantiate([key]) ? exports_memory.Update(FromKey(key, value), {}, options) : RecordDeferred(key, value, options);
|
|
201788
201958
|
return result;
|
|
@@ -201793,7 +201963,7 @@ function RecordInstantiate(context, state, key, value, options) {
|
|
|
201793
201963
|
return RecordAction(instantiatedKey, instantiatedValue, options);
|
|
201794
201964
|
}
|
|
201795
201965
|
|
|
201796
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201966
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/record.mjs
|
|
201797
201967
|
var IntegerKey = `^${IntegerPattern}$`;
|
|
201798
201968
|
var NumberKey = `^${NumberPattern}$`;
|
|
201799
201969
|
var StringKey = `^${StringPattern}$`;
|
|
@@ -201803,15 +201973,19 @@ function RecordDeferred(key, value, options = {}) {
|
|
|
201803
201973
|
function Record(key, value, options = {}) {
|
|
201804
201974
|
return RecordAction(key, value, options);
|
|
201805
201975
|
}
|
|
201806
|
-
function RecordFromPattern(
|
|
201807
|
-
return CreateRecord(
|
|
201976
|
+
function RecordFromPattern(pattern, value) {
|
|
201977
|
+
return CreateRecord(pattern, value);
|
|
201978
|
+
}
|
|
201979
|
+
function RecordPatternToType(pattern) {
|
|
201980
|
+
const result = exports_guard.IsEqual(pattern, StringKey) ? String2() : exports_guard.IsEqual(pattern, IntegerKey) ? Integer() : exports_guard.IsEqual(pattern, NumberKey) ? Number2() : TemplateLiteralDecodeUnsafe(pattern);
|
|
201981
|
+
return result;
|
|
201808
201982
|
}
|
|
201809
201983
|
function RecordPattern(type) {
|
|
201810
201984
|
return exports_guard.Keys(type.patternProperties)[0];
|
|
201811
201985
|
}
|
|
201812
201986
|
function RecordKey(type) {
|
|
201813
201987
|
const pattern = RecordPattern(type);
|
|
201814
|
-
const result =
|
|
201988
|
+
const result = RecordPatternToType(pattern);
|
|
201815
201989
|
return result;
|
|
201816
201990
|
}
|
|
201817
201991
|
function RecordValue(type) {
|
|
@@ -201820,37 +201994,37 @@ function RecordValue(type) {
|
|
|
201820
201994
|
function IsRecord(value) {
|
|
201821
201995
|
return IsKind(value, "Record");
|
|
201822
201996
|
}
|
|
201823
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
201997
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/rest.mjs
|
|
201824
201998
|
function Rest(type) {
|
|
201825
201999
|
return exports_memory.Create({ "~kind": "Rest" }, { type: "rest", items: type }, {});
|
|
201826
202000
|
}
|
|
201827
202001
|
function IsRest(value) {
|
|
201828
202002
|
return IsKind(value, "Rest");
|
|
201829
202003
|
}
|
|
201830
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202004
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/this.mjs
|
|
201831
202005
|
function This(options) {
|
|
201832
202006
|
return exports_memory.Create({ ["~kind"]: "This" }, { $ref: "#" }, options);
|
|
201833
202007
|
}
|
|
201834
202008
|
function IsThis(value) {
|
|
201835
202009
|
return IsKind(value, "This");
|
|
201836
202010
|
}
|
|
201837
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202011
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/undefined.mjs
|
|
201838
202012
|
function Undefined(options) {
|
|
201839
202013
|
return exports_memory.Create({ "~kind": "Undefined" }, { type: "undefined" }, options);
|
|
201840
202014
|
}
|
|
201841
202015
|
function IsUndefined2(value) {
|
|
201842
202016
|
return IsKind(value, "Undefined");
|
|
201843
202017
|
}
|
|
201844
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202018
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/void.mjs
|
|
201845
202019
|
function Void(options) {
|
|
201846
202020
|
return exports_memory.Create({ "~kind": "Void" }, { type: "void" }, options);
|
|
201847
202021
|
}
|
|
201848
202022
|
function IsVoid(value) {
|
|
201849
202023
|
return IsKind(value, "Void");
|
|
201850
202024
|
}
|
|
201851
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202025
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/mapping.mjs
|
|
201852
202026
|
function IntrinsicOrCall(ref2, parameters) {
|
|
201853
|
-
return exports_guard.IsEqual(ref2, "Array") ? _Array_(parameters[0]) : exports_guard.IsEqual(ref2, "
|
|
202027
|
+
return exports_guard.IsEqual(ref2, "Array") ? _Array_(parameters[0]) : exports_guard.IsEqual(ref2, "Capitalize") ? CapitalizeDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "ConstructorParameters") ? ConstructorParametersDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Evaluate") ? EvaluateDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Exclude") ? ExcludeDeferred(parameters[0], parameters[1]) : exports_guard.IsEqual(ref2, "Extract") ? ExtractDeferred(parameters[0], parameters[1]) : exports_guard.IsEqual(ref2, "Index") ? IndexDeferred(parameters[0], parameters[1]) : exports_guard.IsEqual(ref2, "InstanceType") ? InstanceTypeDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Lowercase") ? LowercaseDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "NonNullable") ? NonNullableDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Omit") ? OmitDeferred(parameters[0], parameters[1]) : exports_guard.IsEqual(ref2, "Parameters") ? ParametersDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Partial") ? PartialDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Pick") ? PickDeferred(parameters[0], parameters[1]) : exports_guard.IsEqual(ref2, "Readonly") ? ReadonlyObjectDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "KeyOf") ? KeyOfDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Record") ? RecordDeferred(parameters[0], parameters[1]) : exports_guard.IsEqual(ref2, "Required") ? RequiredDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "ReturnType") ? ReturnTypeDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Uncapitalize") ? UncapitalizeDeferred(parameters[0]) : exports_guard.IsEqual(ref2, "Uppercase") ? UppercaseDeferred(parameters[0]) : CallConstruct(Ref(ref2), parameters);
|
|
201854
202028
|
}
|
|
201855
202029
|
function Unreachable2() {
|
|
201856
202030
|
throw Error("Unreachable");
|
|
@@ -201939,8 +202113,17 @@ function KeywordVoidMapping(input) {
|
|
|
201939
202113
|
function KeywordThisMapping(input) {
|
|
201940
202114
|
return This();
|
|
201941
202115
|
}
|
|
201942
|
-
function
|
|
201943
|
-
return input;
|
|
202116
|
+
function LiteralBigIntMapping(input) {
|
|
202117
|
+
return Literal(BigInt(input));
|
|
202118
|
+
}
|
|
202119
|
+
function LiteralBooleanMapping(input) {
|
|
202120
|
+
return Literal(exports_guard.IsEqual(input, "true"));
|
|
202121
|
+
}
|
|
202122
|
+
function LiteralNumberMapping(input) {
|
|
202123
|
+
return Literal(parseFloat(input));
|
|
202124
|
+
}
|
|
202125
|
+
function LiteralStringMapping(input) {
|
|
202126
|
+
return Literal(input);
|
|
201944
202127
|
}
|
|
201945
202128
|
function TemplateInterpolateMapping(input) {
|
|
201946
202129
|
return input[1];
|
|
@@ -201957,20 +202140,8 @@ function TemplateLiteralTypesMapping(input) {
|
|
|
201957
202140
|
function TemplateLiteralMapping(input) {
|
|
201958
202141
|
return TemplateLiteralDeferred(input);
|
|
201959
202142
|
}
|
|
201960
|
-
function
|
|
201961
|
-
return
|
|
201962
|
-
}
|
|
201963
|
-
function LiteralBooleanMapping(input) {
|
|
201964
|
-
return Literal(exports_guard.IsEqual(input, "true"));
|
|
201965
|
-
}
|
|
201966
|
-
function LiteralNumberMapping(input) {
|
|
201967
|
-
return Literal(parseFloat(input));
|
|
201968
|
-
}
|
|
201969
|
-
function LiteralStringMapping(input) {
|
|
201970
|
-
return Literal(input);
|
|
201971
|
-
}
|
|
201972
|
-
function LiteralMapping(input) {
|
|
201973
|
-
return input;
|
|
202143
|
+
function DependentMapping(input) {
|
|
202144
|
+
return exports_guard.IsEqual(input.length, 6) ? Dependent(input[1], input[3], input[5]) : Dependent(input[1], input[3], Unknown());
|
|
201974
202145
|
}
|
|
201975
202146
|
function KeyOfMapping(input) {
|
|
201976
202147
|
return input.length > 0;
|
|
@@ -201986,18 +202157,24 @@ function ExtendsMapping(input) {
|
|
|
201986
202157
|
function BaseMapping(input) {
|
|
201987
202158
|
return exports_guard.IsArray(input) && exports_guard.IsEqual(input.length, 3) ? input[1] : input;
|
|
201988
202159
|
}
|
|
201989
|
-
|
|
202160
|
+
function WithMapping(input) {
|
|
202161
|
+
return exports_guard.IsEqual(input.length, 2) ? input[1] : [];
|
|
202162
|
+
}
|
|
202163
|
+
function FactorIndexArray(Type, indexArray) {
|
|
201990
202164
|
return indexArray.reduce((result, left) => {
|
|
201991
202165
|
const _left = left;
|
|
201992
202166
|
return exports_guard.IsEqual(_left.length, 1) ? IndexDeferred(result, _left[0]) : exports_guard.IsEqual(_left.length, 0) ? _Array_(result) : Unreachable2();
|
|
201993
202167
|
}, Type);
|
|
201994
|
-
}
|
|
201995
|
-
|
|
202168
|
+
}
|
|
202169
|
+
function FactorExtends(type, extend2) {
|
|
201996
202170
|
return exports_guard.IsEqual(extend2.length, 3) ? ConditionalDeferred(type, extend2[0], extend2[1], extend2[2]) : type;
|
|
201997
|
-
}
|
|
202171
|
+
}
|
|
202172
|
+
function FactorWith(type, withClause) {
|
|
202173
|
+
return exports_guard.IsArray(withClause) && exports_guard.IsEqual(withClause.length, 0) ? type : WithDeferred(type, withClause);
|
|
202174
|
+
}
|
|
201998
202175
|
function FactorMapping(input) {
|
|
201999
|
-
const [keyOf, type, indexArray, extend2] = input;
|
|
202000
|
-
return keyOf ? FactorExtends(KeyOfDeferred(FactorIndexArray(type, indexArray)), extend2) : FactorExtends(FactorIndexArray(type, indexArray), extend2);
|
|
202176
|
+
const [keyOf, type, indexArray, extend2, withClause] = input;
|
|
202177
|
+
return FactorWith(keyOf ? FactorExtends(KeyOfDeferred(FactorIndexArray(type, indexArray)), extend2) : FactorExtends(FactorIndexArray(type, indexArray), extend2), withClause);
|
|
202001
202178
|
}
|
|
202002
202179
|
function ExprBinaryMapping(left, rest2) {
|
|
202003
202180
|
return exports_guard.IsEqual(rest2.length, 3) ? (() => {
|
|
@@ -202027,7 +202204,7 @@ function ExprMapping(input) {
|
|
|
202027
202204
|
return ExprBinaryMapping(left, rest2);
|
|
202028
202205
|
}
|
|
202029
202206
|
function ExprReadonlyMapping(input) {
|
|
202030
|
-
return
|
|
202207
|
+
return AddImmutableDeferred(input[1]);
|
|
202031
202208
|
}
|
|
202032
202209
|
function ExprPipeMapping(input) {
|
|
202033
202210
|
return input[1];
|
|
@@ -202051,7 +202228,7 @@ function PropertyKeyQuotedMapping(input) {
|
|
|
202051
202228
|
return input;
|
|
202052
202229
|
}
|
|
202053
202230
|
function PropertyKeyIndexMapping(input) {
|
|
202054
|
-
return IsInteger2(input[3]) ? IntegerKey :
|
|
202231
|
+
return IsInteger2(input[3]) ? IntegerKey : IsNumber3(input[3]) ? NumberKey : IsSymbol2(input[3]) ? StringKey : IsString3(input[3]) ? StringKey : Unreachable2();
|
|
202055
202232
|
}
|
|
202056
202233
|
function PropertyKeyMapping(input) {
|
|
202057
202234
|
return input;
|
|
@@ -202065,7 +202242,7 @@ function OptionalMapping(input) {
|
|
|
202065
202242
|
function PropertyMapping(input) {
|
|
202066
202243
|
const [isReadonly, key, isOptional, _colon, type] = input;
|
|
202067
202244
|
return {
|
|
202068
|
-
[key]: isReadonly && isOptional ?
|
|
202245
|
+
[key]: isReadonly && isOptional ? AddReadonlyDeferred(AddOptionalDeferred(type)) : isReadonly && !isOptional ? AddReadonlyDeferred(type) : !isReadonly && isOptional ? AddOptionalDeferred(type) : type
|
|
202069
202246
|
};
|
|
202070
202247
|
}
|
|
202071
202248
|
function PropertyDelimiterMapping(input) {
|
|
@@ -202089,16 +202266,16 @@ function _Object_Mapping(input) {
|
|
|
202089
202266
|
return _Object_(properties2, options);
|
|
202090
202267
|
}
|
|
202091
202268
|
function ElementNamedMapping(input) {
|
|
202092
|
-
return exports_guard.IsEqual(input.length, 5) ?
|
|
202269
|
+
return exports_guard.IsEqual(input.length, 5) ? AddReadonlyDeferred(AddOptionalDeferred(input[4])) : exports_guard.IsEqual(input.length, 3) ? input[2] : exports_guard.IsEqual(input.length, 4) ? exports_guard.IsEqual(input[2], "readonly") ? AddReadonlyDeferred(input[3]) : AddOptionalDeferred(input[3]) : Unreachable2();
|
|
202093
202270
|
}
|
|
202094
202271
|
function ElementReadonlyOptionalMapping(input) {
|
|
202095
|
-
return
|
|
202272
|
+
return AddReadonlyDeferred(AddOptionalDeferred(input[1]));
|
|
202096
202273
|
}
|
|
202097
202274
|
function ElementReadonlyMapping(input) {
|
|
202098
|
-
return
|
|
202275
|
+
return AddReadonlyDeferred(input[1]);
|
|
202099
202276
|
}
|
|
202100
202277
|
function ElementOptionalMapping(input) {
|
|
202101
|
-
return
|
|
202278
|
+
return AddOptionalDeferred(input[0]);
|
|
202102
202279
|
}
|
|
202103
202280
|
function ElementBaseMapping(input) {
|
|
202104
202281
|
return input;
|
|
@@ -202109,17 +202286,17 @@ function ElementMapping(input) {
|
|
|
202109
202286
|
function ElementListMapping(input) {
|
|
202110
202287
|
return Delimited(input);
|
|
202111
202288
|
}
|
|
202112
|
-
function
|
|
202289
|
+
function _Tuple_Mapping(input) {
|
|
202113
202290
|
return Tuple(input[1]);
|
|
202114
202291
|
}
|
|
202115
202292
|
function ParameterReadonlyOptionalMapping(input) {
|
|
202116
|
-
return
|
|
202293
|
+
return AddReadonlyDeferred(AddOptionalDeferred(input[4]));
|
|
202117
202294
|
}
|
|
202118
202295
|
function ParameterReadonlyMapping(input) {
|
|
202119
|
-
return
|
|
202296
|
+
return AddReadonlyDeferred(input[3]);
|
|
202120
202297
|
}
|
|
202121
202298
|
function ParameterOptionalMapping(input) {
|
|
202122
|
-
return
|
|
202299
|
+
return AddOptionalDeferred(input[3]);
|
|
202123
202300
|
}
|
|
202124
202301
|
function ParameterTypeMapping(input) {
|
|
202125
202302
|
return input[2];
|
|
@@ -202136,17 +202313,17 @@ function ParameterListMapping(input) {
|
|
|
202136
202313
|
function _Function_Mapping(input) {
|
|
202137
202314
|
return _Function_(input[1], input[4]);
|
|
202138
202315
|
}
|
|
202139
|
-
function
|
|
202316
|
+
function _Constructor_Mapping(input) {
|
|
202140
202317
|
return Constructor(input[2], input[5]);
|
|
202141
202318
|
}
|
|
202142
202319
|
function ApplyReadonly(state, type) {
|
|
202143
|
-
return exports_guard.IsEqual(state, "remove") ?
|
|
202320
|
+
return exports_guard.IsEqual(state, "remove") ? RemoveReadonlyDeferred(type) : exports_guard.IsEqual(state, "add") ? AddReadonlyDeferred(type) : type;
|
|
202144
202321
|
}
|
|
202145
202322
|
function MappedReadonlyMapping(input) {
|
|
202146
202323
|
return exports_guard.IsEqual(input.length, 2) && exports_guard.IsEqual(input[0], "-") ? "remove" : exports_guard.IsEqual(input.length, 2) && exports_guard.IsEqual(input[0], "+") ? "add" : exports_guard.IsEqual(input.length, 1) ? "add" : "none";
|
|
202147
202324
|
}
|
|
202148
202325
|
function ApplyOptional(state, type) {
|
|
202149
|
-
return exports_guard.IsEqual(state, "remove") ?
|
|
202326
|
+
return exports_guard.IsEqual(state, "remove") ? RemoveOptionalDeferred(type) : exports_guard.IsEqual(state, "add") ? AddOptionalDeferred(type) : type;
|
|
202150
202327
|
}
|
|
202151
202328
|
function MappedOptionalMapping(input) {
|
|
202152
202329
|
return exports_guard.IsEqual(input.length, 2) && exports_guard.IsEqual(input[0], "-") ? "remove" : exports_guard.IsEqual(input.length, 2) && exports_guard.IsEqual(input[0], "+") ? "add" : exports_guard.IsEqual(input.length, 1) ? "add" : "none";
|
|
@@ -202154,48 +202331,51 @@ function MappedOptionalMapping(input) {
|
|
|
202154
202331
|
function MappedAsMapping(input) {
|
|
202155
202332
|
return exports_guard.IsEqual(input.length, 2) ? [input[1]] : [];
|
|
202156
202333
|
}
|
|
202157
|
-
function
|
|
202334
|
+
function _Mapped_Mapping(input) {
|
|
202158
202335
|
return exports_guard.IsArray(input[6]) && exports_guard.IsEqual(input[6].length, 1) ? MappedDeferred(Identifier(input[3]), input[5], input[6][0], ApplyReadonly(input[1], ApplyOptional(input[8], input[10]))) : MappedDeferred(Identifier(input[3]), input[5], Ref(input[3]), ApplyReadonly(input[1], ApplyOptional(input[8], input[10])));
|
|
202159
202336
|
}
|
|
202160
202337
|
function ReferenceMapping(input) {
|
|
202161
202338
|
return Ref(input);
|
|
202162
202339
|
}
|
|
202163
|
-
function
|
|
202164
|
-
return
|
|
202340
|
+
function WithBigIntMapping(input) {
|
|
202341
|
+
return BigInt(input);
|
|
202165
202342
|
}
|
|
202166
|
-
function
|
|
202343
|
+
function WithNumberMapping(input) {
|
|
202167
202344
|
return parseFloat(input);
|
|
202168
202345
|
}
|
|
202169
|
-
function
|
|
202346
|
+
function WithBooleanMapping(input) {
|
|
202170
202347
|
return exports_guard.IsEqual(input, "true");
|
|
202171
202348
|
}
|
|
202172
|
-
function
|
|
202349
|
+
function WithStringMapping(input) {
|
|
202173
202350
|
return input;
|
|
202174
202351
|
}
|
|
202175
|
-
function
|
|
202352
|
+
function WithNullMapping(input) {
|
|
202176
202353
|
return null;
|
|
202177
202354
|
}
|
|
202178
|
-
function
|
|
202355
|
+
function WithUndefinedMapping(input) {
|
|
202356
|
+
return;
|
|
202357
|
+
}
|
|
202358
|
+
function WithPropertyMapping(input) {
|
|
202179
202359
|
return { [input[0]]: input[2] };
|
|
202180
202360
|
}
|
|
202181
|
-
function
|
|
202361
|
+
function WithPropertyListMapping(input) {
|
|
202182
202362
|
return Delimited(input);
|
|
202183
202363
|
}
|
|
202184
|
-
function
|
|
202364
|
+
function WithObjectMappingReduce(propertyList) {
|
|
202185
202365
|
return propertyList.reduce((result, left) => {
|
|
202186
202366
|
return exports_memory.Assign(result, left);
|
|
202187
202367
|
}, {});
|
|
202188
202368
|
}
|
|
202189
|
-
function
|
|
202190
|
-
return
|
|
202369
|
+
function WithObjectMapping(input) {
|
|
202370
|
+
return WithObjectMappingReduce(input[1]);
|
|
202191
202371
|
}
|
|
202192
|
-
function
|
|
202372
|
+
function WithElementListMapping(input) {
|
|
202193
202373
|
return Delimited(input);
|
|
202194
202374
|
}
|
|
202195
|
-
function
|
|
202375
|
+
function WithArrayMapping(input) {
|
|
202196
202376
|
return input[1];
|
|
202197
202377
|
}
|
|
202198
|
-
function
|
|
202378
|
+
function WithValueMapping(input) {
|
|
202199
202379
|
return input;
|
|
202200
202380
|
}
|
|
202201
202381
|
function PatternBigIntMapping(input) {
|
|
@@ -202279,7 +202459,7 @@ function ModuleMapping(input) {
|
|
|
202279
202459
|
function ScriptMapping(input) {
|
|
202280
202460
|
return input;
|
|
202281
202461
|
}
|
|
202282
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202462
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/internal/match.mjs
|
|
202283
202463
|
function IsMatch(value) {
|
|
202284
202464
|
return IsEqual(value.length, 2);
|
|
202285
202465
|
}
|
|
@@ -202287,7 +202467,7 @@ function Match2(input, ok, fail) {
|
|
|
202287
202467
|
return IsMatch(input) ? ok(input[0], input[1]) : fail();
|
|
202288
202468
|
}
|
|
202289
202469
|
|
|
202290
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202470
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/internal/take.mjs
|
|
202291
202471
|
function TakeVariant(variant, input) {
|
|
202292
202472
|
return IsEqual(input.indexOf(variant), 0) ? [variant, input.slice(variant.length)] : [];
|
|
202293
202473
|
}
|
|
@@ -202300,7 +202480,7 @@ function Take(variants, input) {
|
|
|
202300
202480
|
return [];
|
|
202301
202481
|
}
|
|
202302
202482
|
|
|
202303
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202483
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/internal/char.mjs
|
|
202304
202484
|
function Range(start, end) {
|
|
202305
202485
|
return Array.from({ length: end - start + 1 }, (_, i) => String.fromCharCode(start + i));
|
|
202306
202486
|
}
|
|
@@ -202319,7 +202499,7 @@ var Dot = ".";
|
|
|
202319
202499
|
var DollarSign = "$";
|
|
202320
202500
|
var Hyphen = "-";
|
|
202321
202501
|
|
|
202322
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202502
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/internal/trim.mjs
|
|
202323
202503
|
var LineComment = "//";
|
|
202324
202504
|
var OpenComment = "/*";
|
|
202325
202505
|
var CloseComment = "*/";
|
|
@@ -202345,12 +202525,12 @@ function Trim(input) {
|
|
|
202345
202525
|
return trimmed.startsWith(OpenComment) ? Trim(DiscardMultilineComment(trimmed.slice(2))) : trimmed.startsWith(LineComment) ? Trim(DiscardLineComment(trimmed.slice(2))) : trimmed;
|
|
202346
202526
|
}
|
|
202347
202527
|
|
|
202348
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202528
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/internal/optional.mjs
|
|
202349
202529
|
function Optional2(value, input) {
|
|
202350
202530
|
return Match2(Take([value], input), (Optional3, Rest2) => [Optional3, Rest2], () => ["", input]);
|
|
202351
202531
|
}
|
|
202352
202532
|
|
|
202353
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202533
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/internal/many.mjs
|
|
202354
202534
|
function IsDiscard(discard2, input) {
|
|
202355
202535
|
return discard2.includes(input);
|
|
202356
202536
|
}
|
|
@@ -202358,7 +202538,7 @@ function Many(allowed, discard2, input, result = "") {
|
|
|
202358
202538
|
return Match2(Take(allowed, input), (Char, Rest2) => IsDiscard(discard2, Char) ? Many(allowed, discard2, Rest2, result) : Many(allowed, discard2, Rest2, `${result}${Char}`), () => [result, input]);
|
|
202359
202539
|
}
|
|
202360
202540
|
|
|
202361
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202541
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/unsigned_integer.mjs
|
|
202362
202542
|
function TakeNonZero(input) {
|
|
202363
202543
|
return Take(NonZero, input);
|
|
202364
202544
|
}
|
|
@@ -202373,7 +202553,7 @@ function UnsignedInteger(input) {
|
|
|
202373
202553
|
return TakeUnsignedInteger(Trim(input));
|
|
202374
202554
|
}
|
|
202375
202555
|
|
|
202376
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202556
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/integer.mjs
|
|
202377
202557
|
function TakeSign(input) {
|
|
202378
202558
|
return Optional2(Hyphen, input);
|
|
202379
202559
|
}
|
|
@@ -202384,21 +202564,21 @@ function Integer2(input) {
|
|
|
202384
202564
|
return TakeSignedInteger(Trim(input));
|
|
202385
202565
|
}
|
|
202386
202566
|
|
|
202387
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202567
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/bigint.mjs
|
|
202388
202568
|
function TakeBigInt(input) {
|
|
202389
202569
|
return Match2(Integer2(input), (Integer3, IntegerRest) => Match2(Take(["n"], IntegerRest), (_N, NRest) => [`${Integer3}`, NRest], () => []), () => []);
|
|
202390
202570
|
}
|
|
202391
202571
|
function BigInt3(input) {
|
|
202392
202572
|
return TakeBigInt(input);
|
|
202393
202573
|
}
|
|
202394
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202574
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/const.mjs
|
|
202395
202575
|
function TakeConst(const_, input) {
|
|
202396
202576
|
return Take([const_], input);
|
|
202397
202577
|
}
|
|
202398
202578
|
function Const(const_, input) {
|
|
202399
202579
|
return IsEqual(const_, "") ? ["", input] : const_.startsWith(NewLine) ? TakeConst(const_, TrimWhitespace(input)) : const_.startsWith(WhiteSpace) ? TakeConst(const_, input) : TakeConst(const_, Trim(input));
|
|
202400
202580
|
}
|
|
202401
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202581
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/ident.mjs
|
|
202402
202582
|
var Initial = [...Alpha, UnderScore, DollarSign];
|
|
202403
202583
|
function TakeInitial(input) {
|
|
202404
202584
|
return Take(Initial, input);
|
|
@@ -202413,7 +202593,7 @@ function TakeIdent(input) {
|
|
|
202413
202593
|
function Ident(input) {
|
|
202414
202594
|
return TakeIdent(Trim(input));
|
|
202415
202595
|
}
|
|
202416
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202596
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/unsigned_number.mjs
|
|
202417
202597
|
var AllowedDigits2 = [...Digit, UnderScore];
|
|
202418
202598
|
function IsLeadingDot(input) {
|
|
202419
202599
|
return IsMatch(Take([Dot], input));
|
|
@@ -202434,7 +202614,7 @@ function UnsignedNumber(input) {
|
|
|
202434
202614
|
return TakeUnsignedNumber(Trim(input));
|
|
202435
202615
|
}
|
|
202436
202616
|
|
|
202437
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202617
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/number.mjs
|
|
202438
202618
|
function TakeSign2(input) {
|
|
202439
202619
|
return Optional2(Hyphen, input);
|
|
202440
202620
|
}
|
|
@@ -202444,19 +202624,19 @@ function TakeSignedNumber(input) {
|
|
|
202444
202624
|
function Number3(input) {
|
|
202445
202625
|
return TakeSignedNumber(Trim(input));
|
|
202446
202626
|
}
|
|
202447
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202627
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/until.mjs
|
|
202448
202628
|
function TakeOne(input) {
|
|
202449
202629
|
const result = IsEqual(input, "") ? [] : [input.slice(0, 1), input.slice(1)];
|
|
202450
202630
|
return result;
|
|
202451
202631
|
}
|
|
202452
202632
|
function IsInputMatchSentinal(end, input) {
|
|
202453
|
-
return
|
|
202633
|
+
return ShiftLeft(end, (left, right) => input.startsWith(left) ? true : IsInputMatchSentinal(right, input), () => false);
|
|
202454
202634
|
}
|
|
202455
202635
|
function Until(end, input, result = "") {
|
|
202456
202636
|
return Match2(TakeOne(input), (One, Rest2) => IsInputMatchSentinal(end, input) ? [result, input] : Until(end, Rest2, `${result}${One}`), () => []);
|
|
202457
202637
|
}
|
|
202458
202638
|
|
|
202459
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202639
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/span.mjs
|
|
202460
202640
|
function MultiLine(start, end, input) {
|
|
202461
202641
|
return Match2(Take([start], input), (_, Rest2) => Match2(Until([end], Rest2), (Until2, UntilRest) => Match2(Take([end], UntilRest), (_2, Rest3) => [`${Until2}`, Rest3], () => []), () => []), () => []);
|
|
202462
202642
|
}
|
|
@@ -202466,7 +202646,7 @@ function SingleLine(start, end, input) {
|
|
|
202466
202646
|
function Span(start, end, multiLine, input) {
|
|
202467
202647
|
return multiLine ? MultiLine(start, end, Trim(input)) : SingleLine(start, end, Trim(input));
|
|
202468
202648
|
}
|
|
202469
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202649
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/string.mjs
|
|
202470
202650
|
function TakeInitial2(quotes, input) {
|
|
202471
202651
|
return Take(quotes, input);
|
|
202472
202652
|
}
|
|
@@ -202479,11 +202659,11 @@ function TakeString(quotes, input) {
|
|
|
202479
202659
|
function String3(quotes, input) {
|
|
202480
202660
|
return TakeString(quotes, Trim(input));
|
|
202481
202661
|
}
|
|
202482
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202662
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/token/until_1.mjs
|
|
202483
202663
|
function Until_1(end, input) {
|
|
202484
202664
|
return Match2(Until(end, input), (Until2, UntilRest) => IsEqual(Until2, "") ? [] : [Until2, UntilRest], () => []);
|
|
202485
202665
|
}
|
|
202486
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202666
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/parser.mjs
|
|
202487
202667
|
var If = (result, left, right = () => []) => result.length === 2 ? left(result) : right();
|
|
202488
202668
|
var GenericParameterExtendsEquals = (input) => If(If(Ident(input), ([_0, input2]) => If(Const("extends", input2), ([_1, input3]) => If(Type(input3), ([_2, input4]) => If(Const("=", input4), ([_3, input5]) => If(Type(input5), ([_4, input6]) => [[_0, _1, _2, _3, _4], input6]))))), ([_0, input2]) => [GenericParameterExtendsEqualsMapping(_0), input2]);
|
|
202489
202669
|
var GenericParameterExtends = (input) => If(If(Ident(input), ([_0, input2]) => If(Const("extends", input2), ([_1, input3]) => If(Type(input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [GenericParameterExtendsMapping(_0), input2]);
|
|
@@ -202512,23 +202692,23 @@ var KeywordNever = (input) => If(Const("never", input), ([_0, input2]) => [Keywo
|
|
|
202512
202692
|
var KeywordSymbol = (input) => If(Const("symbol", input), ([_0, input2]) => [KeywordSymbolMapping(_0), input2]);
|
|
202513
202693
|
var KeywordVoid = (input) => If(Const("void", input), ([_0, input2]) => [KeywordVoidMapping(_0), input2]);
|
|
202514
202694
|
var KeywordThis = (input) => If(Const("this", input), ([_0, input2]) => [KeywordThisMapping(_0), input2]);
|
|
202515
|
-
var Keyword = (input) => If(If(KeywordString(input), ([_0, input2]) => [_0, input2], () => If(KeywordNumber(input), ([_0, input2]) => [_0, input2], () => If(KeywordBoolean(input), ([_0, input2]) => [_0, input2], () => If(KeywordUndefined(input), ([_0, input2]) => [_0, input2], () => If(KeywordNull(input), ([_0, input2]) => [_0, input2], () => If(KeywordInteger(input), ([_0, input2]) => [_0, input2], () => If(KeywordBigInt(input), ([_0, input2]) => [_0, input2], () => If(KeywordUnknown(input), ([_0, input2]) => [_0, input2], () => If(KeywordAny(input), ([_0, input2]) => [_0, input2], () => If(KeywordObject(input), ([_0, input2]) => [_0, input2], () => If(KeywordNever(input), ([_0, input2]) => [_0, input2], () => If(KeywordSymbol(input), ([_0, input2]) => [_0, input2], () => If(KeywordVoid(input), ([_0, input2]) => [_0, input2], () => If(KeywordThis(input), ([_0, input2]) => [_0, input2], () => [])))))))))))))), ([_0, input2]) => [KeywordMapping(_0), input2]);
|
|
202516
202695
|
var TemplateInterpolate = (input) => If(If(Const("${", input), ([_0, input2]) => If(Type(input2), ([_1, input3]) => If(Const("}", input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [TemplateInterpolateMapping(_0), input2]);
|
|
202517
202696
|
var TemplateSpan = (input) => If(Until(["${", "`"], input), ([_0, input2]) => [TemplateSpanMapping(_0), input2]);
|
|
202518
202697
|
var TemplateBody = (input) => If(If(If(TemplateSpan(input), ([_0, input2]) => If(TemplateInterpolate(input2), ([_1, input3]) => If(TemplateBody(input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [_0, input2], () => If(If(TemplateSpan(input), ([_0, input2]) => [[_0], input2]), ([_0, input2]) => [_0, input2], () => If(If(TemplateSpan(input), ([_0, input2]) => [[_0], input2]), ([_0, input2]) => [_0, input2], () => []))), ([_0, input2]) => [TemplateBodyMapping(_0), input2]);
|
|
202519
202698
|
var TemplateLiteralTypes = (input) => If(If(Const("`", input), ([_0, input2]) => If(TemplateBody(input2), ([_1, input3]) => If(Const("`", input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [TemplateLiteralTypesMapping(_0), input2]);
|
|
202520
202699
|
var TemplateLiteral = (input) => If(TemplateLiteralTypes(input), ([_0, input2]) => [TemplateLiteralMapping(_0), input2]);
|
|
202700
|
+
var Dependent2 = (input) => If(If(If(Const("if", input), ([_0, input2]) => If(Type(input2), ([_1, input3]) => If(Const("then", input3), ([_2, input4]) => If(Type(input4), ([_3, input5]) => If(Const("else", input5), ([_4, input6]) => If(Type(input6), ([_5, input7]) => [[_0, _1, _2, _3, _4, _5], input7])))))), ([_0, input2]) => [_0, input2], () => If(If(Const("if", input), ([_0, input2]) => If(Type(input2), ([_1, input3]) => If(Const("then", input3), ([_2, input4]) => If(Type(input4), ([_3, input5]) => [[_0, _1, _2, _3], input5])))), ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [DependentMapping(_0), input2]);
|
|
202521
202701
|
var LiteralBigInt = (input) => If(BigInt3(input), ([_0, input2]) => [LiteralBigIntMapping(_0), input2]);
|
|
202522
202702
|
var LiteralBoolean = (input) => If(If(Const("true", input), ([_0, input2]) => [_0, input2], () => If(Const("false", input), ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [LiteralBooleanMapping(_0), input2]);
|
|
202523
202703
|
var LiteralNumber = (input) => If(Number3(input), ([_0, input2]) => [LiteralNumberMapping(_0), input2]);
|
|
202524
202704
|
var LiteralString = (input) => If(String3(["'", '"'], input), ([_0, input2]) => [LiteralStringMapping(_0), input2]);
|
|
202525
|
-
var Literal2 = (input) => If(If(LiteralBigInt(input), ([_0, input2]) => [_0, input2], () => If(LiteralBoolean(input), ([_0, input2]) => [_0, input2], () => If(LiteralNumber(input), ([_0, input2]) => [_0, input2], () => If(LiteralString(input), ([_0, input2]) => [_0, input2], () => [])))), ([_0, input2]) => [LiteralMapping(_0), input2]);
|
|
202526
202705
|
var KeyOf = (input) => If(If(If(Const("keyof", input), ([_0, input2]) => [[_0], input2]), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [KeyOfMapping(_0), input2]);
|
|
202527
202706
|
var IndexArray_0 = (input, result = []) => If(If(If(Const("[", input), ([_0, input2]) => If(Type(input2), ([_1, input3]) => If(Const("]", input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [_0, input2], () => If(If(Const("[", input), ([_0, input2]) => If(Const("]", input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => IndexArray_0(input2, [...result, _0]), () => [result, input]);
|
|
202528
202707
|
var IndexArray = (input) => If(IndexArray_0(input), ([_0, input2]) => [IndexArrayMapping(_0), input2]);
|
|
202529
|
-
var
|
|
202530
|
-
var
|
|
202531
|
-
var
|
|
202708
|
+
var Extends2 = (input) => If(If(If(Const("extends", input), ([_0, input2]) => If(Type(input2), ([_1, input3]) => If(Const("?", input3), ([_2, input4]) => If(Type(input4), ([_3, input5]) => If(Const(":", input5), ([_4, input6]) => If(Type(input6), ([_5, input7]) => [[_0, _1, _2, _3, _4, _5], input7])))))), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [ExtendsMapping(_0), input2]);
|
|
202709
|
+
var Base = (input) => If(If(If(Const("(", input), ([_0, input2]) => If(Type(input2), ([_1, input3]) => If(Const(")", input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [_0, input2], () => If(KeywordString(input), ([_0, input2]) => [_0, input2], () => If(KeywordNumber(input), ([_0, input2]) => [_0, input2], () => If(KeywordBoolean(input), ([_0, input2]) => [_0, input2], () => If(KeywordUndefined(input), ([_0, input2]) => [_0, input2], () => If(KeywordNull(input), ([_0, input2]) => [_0, input2], () => If(KeywordInteger(input), ([_0, input2]) => [_0, input2], () => If(KeywordBigInt(input), ([_0, input2]) => [_0, input2], () => If(KeywordUnknown(input), ([_0, input2]) => [_0, input2], () => If(KeywordAny(input), ([_0, input2]) => [_0, input2], () => If(KeywordObject(input), ([_0, input2]) => [_0, input2], () => If(KeywordNever(input), ([_0, input2]) => [_0, input2], () => If(KeywordSymbol(input), ([_0, input2]) => [_0, input2], () => If(KeywordVoid(input), ([_0, input2]) => [_0, input2], () => If(KeywordThis(input), ([_0, input2]) => [_0, input2], () => If(LiteralBigInt(input), ([_0, input2]) => [_0, input2], () => If(LiteralBoolean(input), ([_0, input2]) => [_0, input2], () => If(LiteralNumber(input), ([_0, input2]) => [_0, input2], () => If(LiteralString(input), ([_0, input2]) => [_0, input2], () => If(TemplateLiteral(input), ([_0, input2]) => [_0, input2], () => If(Dependent2(input), ([_0, input2]) => [_0, input2], () => If(_Object_2(input), ([_0, input2]) => [_0, input2], () => If(_Tuple_(input), ([_0, input2]) => [_0, input2], () => If(_Constructor_(input), ([_0, input2]) => [_0, input2], () => If(_Function_2(input), ([_0, input2]) => [_0, input2], () => If(_Mapped_(input), ([_0, input2]) => [_0, input2], () => If(GenericCall(input), ([_0, input2]) => [_0, input2], () => If(Reference(input), ([_0, input2]) => [_0, input2], () => [])))))))))))))))))))))))))))), ([_0, input2]) => [BaseMapping(_0), input2]);
|
|
202710
|
+
var With = (input) => If(If(If(Const("with", input), ([_0, input2]) => If(WithObject(input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [WithMapping(_0), input2]);
|
|
202711
|
+
var Factor = (input) => If(If(KeyOf(input), ([_0, input2]) => If(Base(input2), ([_1, input3]) => If(IndexArray(input3), ([_2, input4]) => If(Extends2(input4), ([_3, input5]) => If(With(input5), ([_4, input6]) => [[_0, _1, _2, _3, _4], input6]))))), ([_0, input2]) => [FactorMapping(_0), input2]);
|
|
202532
202712
|
var ExprTermTail = (input) => If(If(If(Const("&", input), ([_0, input2]) => If(Factor(input2), ([_1, input3]) => If(ExprTermTail(input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [ExprTermTailMapping(_0), input2]);
|
|
202533
202713
|
var ExprTerm = (input) => If(If(Factor(input), ([_0, input2]) => If(ExprTermTail(input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [ExprTermMapping(_0), input2]);
|
|
202534
202714
|
var ExprTail = (input) => If(If(If(Const("|", input), ([_0, input2]) => If(ExprTerm(input2), ([_1, input3]) => If(ExprTail(input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [ExprTailMapping(_0), input2]);
|
|
@@ -202562,7 +202742,7 @@ var ElementBase = (input) => If(If(ElementNamed(input), ([_0, input2]) => [_0, i
|
|
|
202562
202742
|
var Element = (input) => If(If(If(Const("...", input), ([_0, input2]) => If(ElementBase(input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [_0, input2], () => If(If(ElementBase(input), ([_0, input2]) => [[_0], input2]), ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [ElementMapping(_0), input2]);
|
|
202563
202743
|
var ElementList_0 = (input, result = []) => If(If(Element(input), ([_0, input2]) => If(Const(",", input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => ElementList_0(input2, [...result, _0]), () => [result, input]);
|
|
202564
202744
|
var ElementList = (input) => If(If(ElementList_0(input), ([_0, input2]) => If(If(If(Element(input2), ([_02, input3]) => [[_02], input3]), ([_02, input3]) => [_02, input3], () => If([[], input2], ([_02, input3]) => [_02, input3], () => [])), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [ElementListMapping(_0), input2]);
|
|
202565
|
-
var
|
|
202745
|
+
var _Tuple_ = (input) => If(If(Const("[", input), ([_0, input2]) => If(ElementList(input2), ([_1, input3]) => If(Const("]", input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [_Tuple_Mapping(_0), input2]);
|
|
202566
202746
|
var ParameterReadonlyOptional = (input) => If(If(Ident(input), ([_0, input2]) => If(Const("?", input2), ([_1, input3]) => If(Const(":", input3), ([_2, input4]) => If(Const("readonly", input4), ([_3, input5]) => If(Type(input5), ([_4, input6]) => [[_0, _1, _2, _3, _4], input6]))))), ([_0, input2]) => [ParameterReadonlyOptionalMapping(_0), input2]);
|
|
202567
202747
|
var ParameterReadonly = (input) => If(If(Ident(input), ([_0, input2]) => If(Const(":", input2), ([_1, input3]) => If(Const("readonly", input3), ([_2, input4]) => If(Type(input4), ([_3, input5]) => [[_0, _1, _2, _3], input5])))), ([_0, input2]) => [ParameterReadonlyMapping(_0), input2]);
|
|
202568
202748
|
var ParameterOptional = (input) => If(If(Ident(input), ([_0, input2]) => If(Const("?", input2), ([_1, input3]) => If(Const(":", input3), ([_2, input4]) => If(Type(input4), ([_3, input5]) => [[_0, _1, _2, _3], input5])))), ([_0, input2]) => [ParameterOptionalMapping(_0), input2]);
|
|
@@ -202572,31 +202752,32 @@ var Parameter2 = (input) => If(If(If(Const("...", input), ([_0, input2]) => If(P
|
|
|
202572
202752
|
var ParameterList_0 = (input, result = []) => If(If(Parameter2(input), ([_0, input2]) => If(Const(",", input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => ParameterList_0(input2, [...result, _0]), () => [result, input]);
|
|
202573
202753
|
var ParameterList = (input) => If(If(ParameterList_0(input), ([_0, input2]) => If(If(If(Parameter2(input2), ([_02, input3]) => [[_02], input3]), ([_02, input3]) => [_02, input3], () => If([[], input2], ([_02, input3]) => [_02, input3], () => [])), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [ParameterListMapping(_0), input2]);
|
|
202574
202754
|
var _Function_2 = (input) => If(If(Const("(", input), ([_0, input2]) => If(ParameterList(input2), ([_1, input3]) => If(Const(")", input3), ([_2, input4]) => If(Const("=>", input4), ([_3, input5]) => If(Type(input5), ([_4, input6]) => [[_0, _1, _2, _3, _4], input6]))))), ([_0, input2]) => [_Function_Mapping(_0), input2]);
|
|
202575
|
-
var
|
|
202755
|
+
var _Constructor_ = (input) => If(If(Const("new", input), ([_0, input2]) => If(Const("(", input2), ([_1, input3]) => If(ParameterList(input3), ([_2, input4]) => If(Const(")", input4), ([_3, input5]) => If(Const("=>", input5), ([_4, input6]) => If(Type(input6), ([_5, input7]) => [[_0, _1, _2, _3, _4, _5], input7])))))), ([_0, input2]) => [_Constructor_Mapping(_0), input2]);
|
|
202576
202756
|
var MappedReadonly = (input) => If(If(If(Const("+", input), ([_0, input2]) => If(Const("readonly", input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [_0, input2], () => If(If(Const("-", input), ([_0, input2]) => If(Const("readonly", input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [_0, input2], () => If(If(Const("readonly", input), ([_0, input2]) => [[_0], input2]), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => [])))), ([_0, input2]) => [MappedReadonlyMapping(_0), input2]);
|
|
202577
202757
|
var MappedOptional = (input) => If(If(If(Const("+", input), ([_0, input2]) => If(Const("?", input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [_0, input2], () => If(If(Const("-", input), ([_0, input2]) => If(Const("?", input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [_0, input2], () => If(If(Const("?", input), ([_0, input2]) => [[_0], input2]), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => [])))), ([_0, input2]) => [MappedOptionalMapping(_0), input2]);
|
|
202578
202758
|
var MappedAs = (input) => If(If(If(Const("as", input), ([_0, input2]) => If(Type(input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [MappedAsMapping(_0), input2]);
|
|
202579
|
-
var
|
|
202759
|
+
var _Mapped_ = (input) => If(If(Const("{", input), ([_0, input2]) => If(MappedReadonly(input2), ([_1, input3]) => If(Const("[", input3), ([_2, input4]) => If(Ident(input4), ([_3, input5]) => If(Const("in", input5), ([_4, input6]) => If(Type(input6), ([_5, input7]) => If(MappedAs(input7), ([_6, input8]) => If(Const("]", input8), ([_7, input9]) => If(MappedOptional(input9), ([_8, input10]) => If(Const(":", input10), ([_9, input11]) => If(Type(input11), ([_10, input12]) => If(OptionalSemiColon(input12), ([_11, input13]) => If(Const("}", input13), ([_12, input14]) => [[_0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12], input14]))))))))))))), ([_0, input2]) => [_Mapped_Mapping(_0), input2]);
|
|
202580
202760
|
var Reference = (input) => If(Ident(input), ([_0, input2]) => [ReferenceMapping(_0), input2]);
|
|
202581
|
-
var
|
|
202582
|
-
var
|
|
202583
|
-
var
|
|
202584
|
-
var
|
|
202585
|
-
var
|
|
202586
|
-
var
|
|
202587
|
-
var
|
|
202588
|
-
var
|
|
202589
|
-
var
|
|
202590
|
-
var
|
|
202591
|
-
var
|
|
202592
|
-
var
|
|
202593
|
-
var
|
|
202761
|
+
var WithBigInt = (input) => If(BigInt3(input), ([_0, input2]) => [WithBigIntMapping(_0), input2]);
|
|
202762
|
+
var WithNumber = (input) => If(Number3(input), ([_0, input2]) => [WithNumberMapping(_0), input2]);
|
|
202763
|
+
var WithBoolean = (input) => If(If(Const("true", input), ([_0, input2]) => [_0, input2], () => If(Const("false", input), ([_0, input2]) => [_0, input2], () => [])), ([_0, input2]) => [WithBooleanMapping(_0), input2]);
|
|
202764
|
+
var WithString = (input) => If(String3(['"', "'"], input), ([_0, input2]) => [WithStringMapping(_0), input2]);
|
|
202765
|
+
var WithNull = (input) => If(Const("null", input), ([_0, input2]) => [WithNullMapping(_0), input2]);
|
|
202766
|
+
var WithUndefined = (input) => If(Const("undefined", input), ([_0, input2]) => [WithUndefinedMapping(_0), input2]);
|
|
202767
|
+
var WithProperty = (input) => If(If(PropertyKey(input), ([_0, input2]) => If(Const(":", input2), ([_1, input3]) => If(WithValue(input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [WithPropertyMapping(_0), input2]);
|
|
202768
|
+
var WithPropertyList_0 = (input, result = []) => If(If(WithProperty(input), ([_0, input2]) => If(PropertyDelimiter(input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => WithPropertyList_0(input2, [...result, _0]), () => [result, input]);
|
|
202769
|
+
var WithPropertyList = (input) => If(If(WithPropertyList_0(input), ([_0, input2]) => If(If(If(WithProperty(input2), ([_02, input3]) => [[_02], input3]), ([_02, input3]) => [_02, input3], () => If([[], input2], ([_02, input3]) => [_02, input3], () => [])), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [WithPropertyListMapping(_0), input2]);
|
|
202770
|
+
var WithObject = (input) => If(If(Const("{", input), ([_0, input2]) => If(WithPropertyList(input2), ([_1, input3]) => If(Const("}", input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [WithObjectMapping(_0), input2]);
|
|
202771
|
+
var WithElementList_0 = (input, result = []) => If(If(WithValue(input), ([_0, input2]) => If(Const(",", input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => WithElementList_0(input2, [...result, _0]), () => [result, input]);
|
|
202772
|
+
var WithElementList = (input) => If(If(WithElementList_0(input), ([_0, input2]) => If(If(If(WithValue(input2), ([_02, input3]) => [[_02], input3]), ([_02, input3]) => [_02, input3], () => If([[], input2], ([_02, input3]) => [_02, input3], () => [])), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [WithElementListMapping(_0), input2]);
|
|
202773
|
+
var WithArray = (input) => If(If(Const("[", input), ([_0, input2]) => If(WithElementList(input2), ([_1, input3]) => If(Const("]", input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [WithArrayMapping(_0), input2]);
|
|
202774
|
+
var WithValue = (input) => If(If(WithBigInt(input), ([_0, input2]) => [_0, input2], () => If(WithNumber(input), ([_0, input2]) => [_0, input2], () => If(WithBoolean(input), ([_0, input2]) => [_0, input2], () => If(WithString(input), ([_0, input2]) => [_0, input2], () => If(WithNull(input), ([_0, input2]) => [_0, input2], () => If(WithUndefined(input), ([_0, input2]) => [_0, input2], () => If(WithObject(input), ([_0, input2]) => [_0, input2], () => If(WithArray(input), ([_0, input2]) => [_0, input2], () => [])))))))), ([_0, input2]) => [WithValueMapping(_0), input2]);
|
|
202594
202775
|
var PatternBigInt = (input) => If(Const("-?(?:0|[1-9][0-9]*)n", input), ([_0, input2]) => [PatternBigIntMapping(_0), input2]);
|
|
202595
202776
|
var PatternString = (input) => If(Const(".*", input), ([_0, input2]) => [PatternStringMapping(_0), input2]);
|
|
202596
|
-
var PatternNumber = (input) => If(Const("-?(?:0|[1-9][0-9]*)(
|
|
202777
|
+
var PatternNumber = (input) => If(Const("-?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?", input), ([_0, input2]) => [PatternNumberMapping(_0), input2]);
|
|
202597
202778
|
var PatternInteger = (input) => If(Const("-?(?:0|[1-9][0-9]*)", input), ([_0, input2]) => [PatternIntegerMapping(_0), input2]);
|
|
202598
202779
|
var PatternNever = (input) => If(Const("(?!)", input), ([_0, input2]) => [PatternNeverMapping(_0), input2]);
|
|
202599
|
-
var PatternText = (input) => If(Until_1(["-?(?:0|[1-9][0-9]*)n", ".*", "-?(?:0|[1-9][0-9]*)(
|
|
202780
|
+
var PatternText = (input) => If(Until_1(["-?(?:0|[1-9][0-9]*)n", ".*", "-?(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?", "-?(?:0|[1-9][0-9]*)", "(?!)", "(", ")", "$", "|"], input), ([_0, input2]) => [PatternTextMapping(_0), input2]);
|
|
202600
202781
|
var PatternBase = (input) => If(If(PatternBigInt(input), ([_0, input2]) => [_0, input2], () => If(PatternString(input), ([_0, input2]) => [_0, input2], () => If(PatternNumber(input), ([_0, input2]) => [_0, input2], () => If(PatternInteger(input), ([_0, input2]) => [_0, input2], () => If(PatternNever(input), ([_0, input2]) => [_0, input2], () => If(PatternGroup(input), ([_0, input2]) => [_0, input2], () => If(PatternText(input), ([_0, input2]) => [_0, input2], () => []))))))), ([_0, input2]) => [PatternBaseMapping(_0), input2]);
|
|
202601
202782
|
var PatternGroup = (input) => If(If(Const("(", input), ([_0, input2]) => If(PatternBody(input2), ([_1, input3]) => If(Const(")", input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [PatternGroupMapping(_0), input2]);
|
|
202602
202783
|
var PatternUnion = (input) => If(If(If(PatternTerm(input), ([_0, input2]) => If(Const("|", input2), ([_1, input3]) => If(PatternUnion(input3), ([_2, input4]) => [[_0, _1, _2], input4]))), ([_0, input2]) => [_0, input2], () => If(If(PatternTerm(input), ([_0, input2]) => [[_0], input2]), ([_0, input2]) => [_0, input2], () => If([[], input], ([_0, input2]) => [_0, input2], () => []))), ([_0, input2]) => [PatternUnionMapping(_0), input2]);
|
|
@@ -202620,14 +202801,14 @@ var ModuleDeclaration = (input) => If(If(ExportKeyword(input), ([_0, input2]) =>
|
|
|
202620
202801
|
var Module = (input) => If(If(ModuleDeclaration(input), ([_0, input2]) => If(ModuleDeclarationList(input2), ([_1, input3]) => [[_0, _1], input3])), ([_0, input2]) => [ModuleMapping(_0), input2]);
|
|
202621
202802
|
var Script = (input) => If(If(Module(input), ([_0, input2]) => [_0, input2], () => If(GenericType(input), ([_0, input2]) => [_0, input2], () => If(Type(input), ([_0, input2]) => [_0, input2], () => []))), ([_0, input2]) => [ScriptMapping(_0), input2]);
|
|
202622
202803
|
|
|
202623
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202804
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/patterns/template.mjs
|
|
202624
202805
|
function ParseTemplateIntoTypes(template) {
|
|
202625
202806
|
const parsed = TemplateLiteralTypes(`\`${template}\``);
|
|
202626
202807
|
const result = exports_guard.IsEqual(parsed.length, 2) ? parsed[0] : Unreachable();
|
|
202627
202808
|
return result;
|
|
202628
202809
|
}
|
|
202629
202810
|
|
|
202630
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202811
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/template_literal/encode.mjs
|
|
202631
202812
|
function JoinString(input) {
|
|
202632
202813
|
return input.join("|");
|
|
202633
202814
|
}
|
|
@@ -202660,18 +202841,18 @@ function EncodeTemplateLiteralDeferred(types2, right, pattern) {
|
|
|
202660
202841
|
const result = EncodeType(templateLiteral2, right, pattern);
|
|
202661
202842
|
return result;
|
|
202662
202843
|
}
|
|
202663
|
-
function EncodeEnum(
|
|
202664
|
-
const
|
|
202665
|
-
return
|
|
202844
|
+
function EncodeEnum(values, right, pattern) {
|
|
202845
|
+
const evaluated = EvaluateEnum(values);
|
|
202846
|
+
return EncodeType(evaluated, right, pattern);
|
|
202666
202847
|
}
|
|
202667
202848
|
function EncodeUnion(types2, right, pattern, result = []) {
|
|
202668
|
-
return exports_guard.
|
|
202849
|
+
return exports_guard.ShiftLeft(types2, (head, tail) => EncodeUnion(tail, right, pattern, [...result, EncodeType(head, [], "")]), () => EncodeTypes(right, `${pattern}(${JoinString(result)})`));
|
|
202669
202850
|
}
|
|
202670
202851
|
function EncodeType(type, right, pattern) {
|
|
202671
|
-
return IsEnum(type) ? EncodeEnum(type.enum, right, pattern) : IsInteger2(type) ? EncodeInteger(right, pattern) : IsLiteral(type) ? EncodeLiteral(type.const, right, pattern) : IsBigInt2(type) ? EncodeBigInt(right, pattern) :
|
|
202852
|
+
return IsEnum(type) ? EncodeEnum(type.enum, right, pattern) : IsInteger2(type) ? EncodeInteger(right, pattern) : IsLiteral(type) ? EncodeLiteral(type.const, right, pattern) : IsBigInt2(type) ? EncodeBigInt(right, pattern) : IsBoolean3(type) ? EncodeBoolean(right, pattern) : IsNumber3(type) ? EncodeNumber(right, pattern) : IsString3(type) ? EncodeString(right, pattern) : IsTemplateLiteral(type) ? EncodeTemplateLiteral(type.pattern, right, pattern) : IsTemplateLiteralDeferred(type) ? EncodeTemplateLiteralDeferred(type.parameters[0], right, pattern) : IsUnion(type) ? EncodeUnion(type.anyOf, right, pattern) : NeverPattern;
|
|
202672
202853
|
}
|
|
202673
202854
|
function EncodeTypes(types2, pattern) {
|
|
202674
|
-
return exports_guard.
|
|
202855
|
+
return exports_guard.ShiftLeft(types2, (left, right) => EncodeType(left, right, pattern), () => pattern);
|
|
202675
202856
|
}
|
|
202676
202857
|
function EncodePattern(types2) {
|
|
202677
202858
|
const encoded = EncodeTypes(types2, "");
|
|
@@ -202684,7 +202865,7 @@ function TemplateLiteralEncode(types2) {
|
|
|
202684
202865
|
return result;
|
|
202685
202866
|
}
|
|
202686
202867
|
|
|
202687
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202868
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/template_literal/instantiate.mjs
|
|
202688
202869
|
function TemplateLiteralAction(types2, options) {
|
|
202689
202870
|
const result = CanInstantiate(types2) ? exports_memory.Update(TemplateLiteralEncode(types2), {}, options) : TemplateLiteralDeferred(types2, options);
|
|
202690
202871
|
return result;
|
|
@@ -202694,7 +202875,7 @@ function TemplateLiteralInstantiate(context, state, types2, options) {
|
|
|
202694
202875
|
return TemplateLiteralAction(instantiatedTypes, options);
|
|
202695
202876
|
}
|
|
202696
202877
|
|
|
202697
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202878
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/template_literal.mjs
|
|
202698
202879
|
function TemplateLiteralDeferred(types2, options = {}) {
|
|
202699
202880
|
return Deferred("TemplateLiteral", [types2], options);
|
|
202700
202881
|
}
|
|
@@ -202716,7 +202897,7 @@ function IsTemplateLiteral(value) {
|
|
|
202716
202897
|
return IsKind(value, "TemplateLiteral");
|
|
202717
202898
|
}
|
|
202718
202899
|
|
|
202719
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202900
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/result.mjs
|
|
202720
202901
|
var exports_result = {};
|
|
202721
202902
|
__export(exports_result, {
|
|
202722
202903
|
Match: () => Match3,
|
|
@@ -202752,37 +202933,41 @@ function IsExtendsTrueLike(value) {
|
|
|
202752
202933
|
function Match3(result, true_, false_) {
|
|
202753
202934
|
return IsExtendsTrueLike(result) ? true_(result.inferred) : false_();
|
|
202754
202935
|
}
|
|
202755
|
-
|
|
202936
|
+
|
|
202937
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/extends_right.mjs
|
|
202756
202938
|
function ExtendsRightInfer(inferred, name2, left, right) {
|
|
202757
202939
|
return Match3(ExtendsLeft(inferred, left, right), (checkInferred) => ExtendsTrue(exports_memory.Assign(exports_memory.Assign(inferred, checkInferred), { [name2]: left })), () => ExtendsFalse());
|
|
202758
202940
|
}
|
|
202759
202941
|
function ExtendsRightAny(inferred, _left) {
|
|
202760
202942
|
return ExtendsTrue(inferred);
|
|
202761
202943
|
}
|
|
202944
|
+
function ExtendsRightDependent(inferred, left, if_, then_, else_) {
|
|
202945
|
+
return Match3(ExtendsLeft(inferred, left, if_), (inferred2) => Match3(ExtendsLeft(inferred2, left, then_), (inferred3) => ExtendsTrue(inferred3), () => ExtendsFalse()), () => Match3(ExtendsLeft(inferred, left, else_), (inferred2) => ExtendsTrue(inferred2), () => ExtendsFalse()));
|
|
202946
|
+
}
|
|
202762
202947
|
function ExtendsRightEnum(inferred, left, right) {
|
|
202763
|
-
const
|
|
202764
|
-
return ExtendsLeft(inferred, left,
|
|
202948
|
+
const evaluated = EvaluateEnum(right);
|
|
202949
|
+
return ExtendsLeft(inferred, left, evaluated);
|
|
202765
202950
|
}
|
|
202766
202951
|
function ExtendsRightIntersect(inferred, left, right) {
|
|
202767
|
-
return exports_guard.
|
|
202952
|
+
return exports_guard.ShiftLeft(right, (head, tail) => Match3(ExtendsLeft(inferred, left, head), (inferred2) => ExtendsRightIntersect(inferred2, left, tail), () => ExtendsFalse()), () => ExtendsTrue(inferred));
|
|
202768
202953
|
}
|
|
202769
202954
|
function ExtendsRightTemplateLiteral(inferred, left, right) {
|
|
202770
|
-
const
|
|
202771
|
-
return ExtendsLeft(inferred, left,
|
|
202955
|
+
const evaluated = EvaluateTemplateLiteral(right);
|
|
202956
|
+
return ExtendsLeft(inferred, left, evaluated);
|
|
202772
202957
|
}
|
|
202773
202958
|
function ExtendsRightUnion(inferred, left, right) {
|
|
202774
|
-
return exports_guard.
|
|
202959
|
+
return exports_guard.ShiftLeft(right, (head, tail) => Match3(ExtendsLeft(inferred, left, head), (inferred2) => ExtendsTrue(inferred2), () => ExtendsRightUnion(inferred, left, tail)), () => ExtendsFalse());
|
|
202775
202960
|
}
|
|
202776
202961
|
function ExtendsRight(inferred, left, right) {
|
|
202777
|
-
return IsAny(right) ? ExtendsRightAny(inferred, left) : IsEnum(right) ? ExtendsRightEnum(inferred, left, right.enum) : IsInfer(right) ? ExtendsRightInfer(inferred, right.name, left, right.extends) : IsIntersect(right) ? ExtendsRightIntersect(inferred, left, right.allOf) : IsTemplateLiteral(right) ? ExtendsRightTemplateLiteral(inferred, left, right.pattern) : IsUnion(right) ? ExtendsRightUnion(inferred, left, right.anyOf) : IsUnknown(right) ? ExtendsTrue(inferred) : ExtendsFalse();
|
|
202962
|
+
return IsAny(right) ? ExtendsRightAny(inferred, left) : IsDependent(right) ? ExtendsRightDependent(inferred, left, right.if, right.then, right.else) : IsEnum(right) ? ExtendsRightEnum(inferred, left, right.enum) : IsInfer(right) ? ExtendsRightInfer(inferred, right.name, left, right.extends) : IsIntersect(right) ? ExtendsRightIntersect(inferred, left, right.allOf) : IsTemplateLiteral(right) ? ExtendsRightTemplateLiteral(inferred, left, right.pattern) : IsUnion(right) ? ExtendsRightUnion(inferred, left, right.anyOf) : IsUnknown(right) ? ExtendsTrue(inferred) : ExtendsFalse();
|
|
202778
202963
|
}
|
|
202779
202964
|
|
|
202780
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202965
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/any.mjs
|
|
202781
202966
|
function ExtendsAny(inferred, left, right) {
|
|
202782
202967
|
return IsInfer(right) ? ExtendsRight(inferred, left, right) : IsAny(right) ? ExtendsTrue(inferred) : IsUnknown(right) ? ExtendsTrue(inferred) : ExtendsUnion(inferred);
|
|
202783
202968
|
}
|
|
202784
202969
|
|
|
202785
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202970
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/array.mjs
|
|
202786
202971
|
function ExtendsImmutable(left, right) {
|
|
202787
202972
|
const isImmutableLeft = IsImmutable(left);
|
|
202788
202973
|
const isImmutableRight = IsImmutable(right);
|
|
@@ -202792,22 +202977,17 @@ function ExtendsArray(inferred, arrayLeft, left, right) {
|
|
|
202792
202977
|
return IsArray2(right) ? ExtendsImmutable(arrayLeft, right) ? ExtendsLeft(inferred, left, right.items) : ExtendsFalse() : ExtendsRight(inferred, arrayLeft, right);
|
|
202793
202978
|
}
|
|
202794
202979
|
|
|
202795
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202796
|
-
function ExtendsAsyncIterator(inferred, left, right) {
|
|
202797
|
-
return IsAsyncIterator2(right) ? ExtendsLeft(inferred, left, right.iteratorItems) : ExtendsRight(inferred, AsyncIterator(left), right);
|
|
202798
|
-
}
|
|
202799
|
-
|
|
202800
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/extends/bigint.mjs
|
|
202980
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/bigint.mjs
|
|
202801
202981
|
function ExtendsBigInt(inferred, left, right) {
|
|
202802
202982
|
return IsBigInt2(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
202803
202983
|
}
|
|
202804
202984
|
|
|
202805
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202985
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/boolean.mjs
|
|
202806
202986
|
function ExtendsBoolean(inferred, left, right) {
|
|
202807
|
-
return
|
|
202987
|
+
return IsBoolean3(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
202808
202988
|
}
|
|
202809
202989
|
|
|
202810
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202990
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/parameters.mjs
|
|
202811
202991
|
function ParameterCompare(inferred, left, leftRest, right, rightRest) {
|
|
202812
202992
|
const checkLeft = IsInfer(right) ? left : right;
|
|
202813
202993
|
const checkRight = IsInfer(right) ? right : left;
|
|
@@ -202816,52 +202996,53 @@ function ParameterCompare(inferred, left, leftRest, right, rightRest) {
|
|
|
202816
202996
|
return !isLeftOptional && isRightOptional ? ExtendsFalse() : Match3(ExtendsLeft(inferred, checkLeft, checkRight), (inferred2) => ExtendsParameters(inferred2, leftRest, rightRest), () => ExtendsFalse());
|
|
202817
202997
|
}
|
|
202818
202998
|
function ParameterRight(inferred, left, leftRest, rightRest) {
|
|
202819
|
-
return exports_guard.
|
|
202999
|
+
return exports_guard.ShiftLeft(rightRest, (head, tail) => ParameterCompare(inferred, left, leftRest, head, tail), () => IsOptional(left) ? ExtendsTrue(inferred) : ExtendsFalse());
|
|
202820
203000
|
}
|
|
202821
203001
|
function ParametersLeft(inferred, left, rightRest) {
|
|
202822
|
-
return exports_guard.
|
|
203002
|
+
return exports_guard.ShiftLeft(left, (head, tail) => ParameterRight(inferred, head, tail, rightRest), () => ExtendsTrue(inferred));
|
|
202823
203003
|
}
|
|
202824
203004
|
function ExtendsParameters(inferred, left, right) {
|
|
202825
203005
|
return ParametersLeft(inferred, left, right);
|
|
202826
203006
|
}
|
|
202827
203007
|
|
|
202828
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203008
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/return_type.mjs
|
|
202829
203009
|
function ExtendsReturnType(inferred, left, right) {
|
|
202830
203010
|
return IsVoid(right) ? ExtendsTrue(inferred) : ExtendsLeft(inferred, left, right);
|
|
202831
203011
|
}
|
|
202832
203012
|
|
|
202833
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203013
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/constructor.mjs
|
|
202834
203014
|
function ExtendsConstructor(inferred, parameters, returnType, right) {
|
|
202835
203015
|
return IsAny(right) ? ExtendsTrue(inferred) : IsUnknown(right) ? ExtendsTrue(inferred) : IsConstructor2(right) ? Match3(ExtendsParameters(inferred, parameters, right["parameters"]), (inferred2) => ExtendsReturnType(inferred2, returnType, right["instanceType"]), () => ExtendsFalse()) : ExtendsFalse();
|
|
202836
203016
|
}
|
|
202837
203017
|
|
|
202838
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203018
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/dependent.mjs
|
|
203019
|
+
function ExtendsDependent(inferred, if_, then_, else_, right) {
|
|
203020
|
+
return Match3(ExtendsLeft(inferred, if_, right), () => ExtendsLeft(inferred, then_, right), () => ExtendsLeft(inferred, else_, right));
|
|
203021
|
+
}
|
|
203022
|
+
|
|
203023
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/enum.mjs
|
|
202839
203024
|
function ExtendsEnum(inferred, left, right) {
|
|
202840
|
-
|
|
203025
|
+
const evaluated = EvaluateEnum(left);
|
|
203026
|
+
return ExtendsLeft(inferred, evaluated, right);
|
|
202841
203027
|
}
|
|
202842
203028
|
|
|
202843
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203029
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/function.mjs
|
|
202844
203030
|
function ExtendsFunction(inferred, parameters, returnType, right) {
|
|
202845
203031
|
return IsAny(right) ? ExtendsTrue(inferred) : IsUnknown(right) ? ExtendsTrue(inferred) : IsFunction2(right) ? Match3(ExtendsParameters(inferred, parameters, right["parameters"]), (inferred2) => ExtendsReturnType(inferred2, returnType, right["returnType"]), () => ExtendsFalse()) : ExtendsFalse();
|
|
202846
203032
|
}
|
|
202847
203033
|
|
|
202848
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203034
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/integer.mjs
|
|
202849
203035
|
function ExtendsInteger(inferred, left, right) {
|
|
202850
|
-
return IsInteger2(right) ? ExtendsTrue(inferred) :
|
|
203036
|
+
return IsInteger2(right) ? ExtendsTrue(inferred) : IsNumber3(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
202851
203037
|
}
|
|
202852
203038
|
|
|
202853
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203039
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/intersect.mjs
|
|
202854
203040
|
function ExtendsIntersect(inferred, left, right) {
|
|
202855
203041
|
const evaluated = EvaluateIntersect(left);
|
|
202856
203042
|
return ExtendsLeft(inferred, evaluated, right);
|
|
202857
203043
|
}
|
|
202858
203044
|
|
|
202859
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202860
|
-
function ExtendsIterator(inferred, left, right) {
|
|
202861
|
-
return IsIterator2(right) ? ExtendsLeft(inferred, left, right.iteratorItems) : ExtendsRight(inferred, Iterator(left), right);
|
|
202862
|
-
}
|
|
202863
|
-
|
|
202864
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/extends/literal.mjs
|
|
203045
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/literal.mjs
|
|
202865
203046
|
function ExtendsLiteralValue(inferred, left, right) {
|
|
202866
203047
|
return left === right ? ExtendsTrue(inferred) : ExtendsFalse();
|
|
202867
203048
|
}
|
|
@@ -202869,34 +203050,34 @@ function ExtendsLiteralBigInt(inferred, left, right) {
|
|
|
202869
203050
|
return IsLiteral(right) ? ExtendsLiteralValue(inferred, left, right.const) : IsBigInt2(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, Literal(left), right);
|
|
202870
203051
|
}
|
|
202871
203052
|
function ExtendsLiteralBoolean(inferred, left, right) {
|
|
202872
|
-
return IsLiteral(right) ? ExtendsLiteralValue(inferred, left, right.const) :
|
|
203053
|
+
return IsLiteral(right) ? ExtendsLiteralValue(inferred, left, right.const) : IsBoolean3(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, Literal(left), right);
|
|
202873
203054
|
}
|
|
202874
203055
|
function ExtendsLiteralNumber(inferred, left, right) {
|
|
202875
|
-
return IsLiteral(right) ? ExtendsLiteralValue(inferred, left, right.const) :
|
|
203056
|
+
return IsLiteral(right) ? ExtendsLiteralValue(inferred, left, right.const) : IsNumber3(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, Literal(left), right);
|
|
202876
203057
|
}
|
|
202877
203058
|
function ExtendsLiteralString(inferred, left, right) {
|
|
202878
|
-
return IsLiteral(right) ? ExtendsLiteralValue(inferred, left, right.const) :
|
|
203059
|
+
return IsLiteral(right) ? ExtendsLiteralValue(inferred, left, right.const) : IsString3(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, Literal(left), right);
|
|
202879
203060
|
}
|
|
202880
203061
|
function ExtendsLiteral(inferred, left, right) {
|
|
202881
203062
|
return exports_guard.IsBigInt(left.const) ? ExtendsLiteralBigInt(inferred, left.const, right) : exports_guard.IsBoolean(left.const) ? ExtendsLiteralBoolean(inferred, left.const, right) : exports_guard.IsNumber(left.const) ? ExtendsLiteralNumber(inferred, left.const, right) : exports_guard.IsString(left.const) ? ExtendsLiteralString(inferred, left.const, right) : Unreachable();
|
|
202882
203063
|
}
|
|
202883
203064
|
|
|
202884
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203065
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/never.mjs
|
|
202885
203066
|
function ExtendsNever(inferred, left, right) {
|
|
202886
203067
|
return IsInfer(right) ? ExtendsRight(inferred, left, right) : ExtendsTrue(inferred);
|
|
202887
203068
|
}
|
|
202888
203069
|
|
|
202889
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203070
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/null.mjs
|
|
202890
203071
|
function ExtendsNull(inferred, left, right) {
|
|
202891
203072
|
return IsNull2(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
202892
203073
|
}
|
|
202893
203074
|
|
|
202894
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203075
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/number.mjs
|
|
202895
203076
|
function ExtendsNumber(inferred, left, right) {
|
|
202896
|
-
return
|
|
203077
|
+
return IsNumber3(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
202897
203078
|
}
|
|
202898
203079
|
|
|
202899
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203080
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/object.mjs
|
|
202900
203081
|
function ExtendsPropertyOptional(inferred, left, right) {
|
|
202901
203082
|
return IsOptional(left) ? IsOptional(right) ? ExtendsTrue(inferred) : ExtendsFalse() : ExtendsTrue(inferred);
|
|
202902
203083
|
}
|
|
@@ -202924,32 +203105,54 @@ function ExtendsProperties(inferred, left, right) {
|
|
|
202924
203105
|
function ExtendsObjectToObject(inferred, left, right) {
|
|
202925
203106
|
return ExtendsProperties(inferred, left, right);
|
|
202926
203107
|
}
|
|
203108
|
+
function RecordMergeInferred(left, right) {
|
|
203109
|
+
return exports_guard.Keys(right).reduce((result, key) => {
|
|
203110
|
+
return {
|
|
203111
|
+
...result,
|
|
203112
|
+
[key]: exports_guard.HasPropertyKey(left, key) ? IsUnion(result[key]) ? Union([...result[key].anyOf, right[key]]) : Union([left[key], right[key]]) : right[key]
|
|
203113
|
+
};
|
|
203114
|
+
}, left);
|
|
203115
|
+
}
|
|
203116
|
+
function ExtendsRecordComparer(properties2, keys, type, result) {
|
|
203117
|
+
return exports_guard.ShiftLeft(keys, (left, right) => Match3(ExtendsLeft({}, properties2[left], type), (inferred) => ExtendsRecordComparer(properties2, right, type, RecordMergeInferred(result, inferred)), () => ExtendsFalse()), () => ExtendsTrue(result));
|
|
203118
|
+
}
|
|
203119
|
+
function ExtendsObjectToRecord(inferred, properties2, _pattern, value) {
|
|
203120
|
+
const keys = exports_guard.Keys(properties2);
|
|
203121
|
+
const result = ExtendsRecordComparer(properties2, keys, value, inferred);
|
|
203122
|
+
return result;
|
|
203123
|
+
}
|
|
202927
203124
|
function ExtendsObject(inferred, left, right) {
|
|
202928
|
-
return IsObject2(right) ? ExtendsObjectToObject(inferred, left, right.properties) : ExtendsRight(inferred, _Object_(left), right);
|
|
203125
|
+
return IsRecord(right) ? ExtendsObjectToRecord(inferred, left, RecordPattern(right), RecordValue(right)) : IsObject2(right) ? ExtendsObjectToObject(inferred, left, right.properties) : ExtendsRight(inferred, _Object_(left), right);
|
|
202929
203126
|
}
|
|
202930
203127
|
|
|
202931
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
202932
|
-
function
|
|
202933
|
-
return
|
|
203128
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/record.mjs
|
|
203129
|
+
function FromObject2(inferred, properties2) {
|
|
203130
|
+
return exports_guard.IsEqual(exports_guard.Keys(properties2).length, 0) ? ExtendsTrue(inferred) : ExtendsFalse();
|
|
203131
|
+
}
|
|
203132
|
+
function FromRecord(inferred, _leftKey, leftValue, _rightKey, rightValue) {
|
|
203133
|
+
return ExtendsLeft(inferred, leftValue, rightValue);
|
|
203134
|
+
}
|
|
203135
|
+
function ExtendsRecord(inferred, leftPattern, leftValue, right) {
|
|
203136
|
+
return IsRecord(right) ? FromRecord(inferred, RecordPatternToType(leftPattern), leftValue, RecordPatternToType(RecordPattern(right)), RecordValue(right)) : IsObject2(right) ? FromObject2(inferred, right.properties) : IsAny(right) ? ExtendsTrue(inferred) : IsUnknown(right) ? ExtendsTrue(inferred) : ExtendsFalse();
|
|
202934
203137
|
}
|
|
202935
203138
|
|
|
202936
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203139
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/string.mjs
|
|
202937
203140
|
function ExtendsString(inferred, left, right) {
|
|
202938
|
-
return
|
|
203141
|
+
return IsString3(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
202939
203142
|
}
|
|
202940
203143
|
|
|
202941
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203144
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/symbol.mjs
|
|
202942
203145
|
function ExtendsSymbol(inferred, left, right) {
|
|
202943
203146
|
return IsSymbol2(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
202944
203147
|
}
|
|
202945
203148
|
|
|
202946
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203149
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/template_literal.mjs
|
|
202947
203150
|
function ExtendsTemplateLiteral(inferred, left, right) {
|
|
202948
|
-
const
|
|
202949
|
-
return ExtendsLeft(inferred,
|
|
203151
|
+
const evaluated = EvaluateTemplateLiteral(left);
|
|
203152
|
+
return ExtendsLeft(inferred, evaluated, right);
|
|
202950
203153
|
}
|
|
202951
203154
|
|
|
202952
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203155
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/inference.mjs
|
|
202953
203156
|
function Inferrable(name2, type) {
|
|
202954
203157
|
return exports_memory.Create({ "~kind": "Inferrable" }, { name: name2, type }, {});
|
|
202955
203158
|
}
|
|
@@ -202963,7 +203166,7 @@ function TryInferable(type) {
|
|
|
202963
203166
|
return IsInfer(type) ? Inferrable(type.name, type.extends) : undefined;
|
|
202964
203167
|
}
|
|
202965
203168
|
function TryInferResults(rest3, right, result = []) {
|
|
202966
|
-
return exports_guard.
|
|
203169
|
+
return exports_guard.ShiftLeft(rest3, (head, tail) => Match3(ExtendsLeft({}, head, right), () => TryInferResults(tail, right, [...result, head]), () => {
|
|
202967
203170
|
return;
|
|
202968
203171
|
}), () => result);
|
|
202969
203172
|
}
|
|
@@ -202976,7 +203179,7 @@ function InferUnionResult(inferred, name2, left, right) {
|
|
|
202976
203179
|
return exports_guard.IsArray(results) ? ExtendsTrue(exports_memory.Assign(inferred, { [name2]: Union(results) })) : ExtendsFalse();
|
|
202977
203180
|
}
|
|
202978
203181
|
|
|
202979
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203182
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/tuple.mjs
|
|
202980
203183
|
function Reverse(types2) {
|
|
202981
203184
|
return [...types2].reverse();
|
|
202982
203185
|
}
|
|
@@ -202993,61 +203196,61 @@ function ElementsCompare(inferred, reversed, left, leftRest, right, rightRest) {
|
|
|
202993
203196
|
}
|
|
202994
203197
|
function ElementsLeft(inferred, reversed, leftRest, right, rightRest) {
|
|
202995
203198
|
const inferable = TryRestInferable(right);
|
|
202996
|
-
return IsInferable(inferable) ? InferTupleResult(inferred, inferable["name"], ApplyReverse(leftRest, reversed), inferable["type"]) : exports_guard.
|
|
203199
|
+
return IsInferable(inferable) ? InferTupleResult(inferred, inferable["name"], ApplyReverse(leftRest, reversed), inferable["type"]) : exports_guard.ShiftLeft(leftRest, (head, tail) => ElementsCompare(inferred, reversed, head, tail, right, rightRest), () => ExtendsFalse());
|
|
202997
203200
|
}
|
|
202998
203201
|
function ElementsRight(inferred, reversed, leftRest, rightRest) {
|
|
202999
|
-
return exports_guard.
|
|
203202
|
+
return exports_guard.ShiftLeft(rightRest, (head, tail) => ElementsLeft(inferred, reversed, leftRest, head, tail), () => exports_guard.IsEqual(leftRest.length, 0) ? ExtendsTrue(inferred) : ExtendsFalse());
|
|
203000
203203
|
}
|
|
203001
203204
|
function Elements(inferred, reversed, leftRest, rightRest) {
|
|
203002
203205
|
return ElementsRight(inferred, reversed, leftRest, rightRest);
|
|
203003
203206
|
}
|
|
203004
203207
|
function ExtendsTupleToTuple(inferred, left, right) {
|
|
203005
|
-
const instantiatedRight = InstantiateElements(inferred,
|
|
203208
|
+
const instantiatedRight = InstantiateElements(inferred, State([], []), right);
|
|
203006
203209
|
const reversed = Reversed(instantiatedRight);
|
|
203007
203210
|
return Elements(inferred, reversed, ApplyReverse(left, reversed), ApplyReverse(instantiatedRight, reversed));
|
|
203008
203211
|
}
|
|
203009
203212
|
function ExtendsTupleToArray(inferred, left, right) {
|
|
203010
203213
|
const inferrable = TryInferable(right);
|
|
203011
|
-
return IsInferable(inferrable) ? InferUnionResult(inferred, inferrable["name"], left, inferrable["type"]) : exports_guard.
|
|
203214
|
+
return IsInferable(inferrable) ? InferUnionResult(inferred, inferrable["name"], left, inferrable["type"]) : exports_guard.ShiftLeft(left, (head, tail) => Match3(ExtendsLeft(inferred, head, right), (inferred2) => ExtendsTupleToArray(inferred2, tail, right), () => ExtendsFalse()), () => ExtendsTrue(inferred));
|
|
203012
203215
|
}
|
|
203013
203216
|
function ExtendsTuple(inferred, left, right) {
|
|
203014
|
-
const instantiatedLeft = InstantiateElements(inferred,
|
|
203217
|
+
const instantiatedLeft = InstantiateElements(inferred, State([], []), left);
|
|
203015
203218
|
return IsTuple(right) ? ExtendsTupleToTuple(inferred, instantiatedLeft, right.items) : IsArray2(right) ? ExtendsTupleToArray(inferred, instantiatedLeft, right.items) : ExtendsRight(inferred, Tuple(instantiatedLeft), right);
|
|
203016
203219
|
}
|
|
203017
203220
|
|
|
203018
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203221
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/undefined.mjs
|
|
203019
203222
|
function ExtendsUndefined(inferred, left, right) {
|
|
203020
203223
|
return IsVoid(right) ? ExtendsTrue(inferred) : IsUndefined2(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
203021
203224
|
}
|
|
203022
203225
|
|
|
203023
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203226
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/union.mjs
|
|
203024
203227
|
function ExtendsUnionSome(inferred, type, unionTypes) {
|
|
203025
|
-
return exports_guard.
|
|
203228
|
+
return exports_guard.ShiftLeft(unionTypes, (head, tail) => Match3(ExtendsLeft(inferred, type, head), (inferred2) => ExtendsTrue(inferred2), () => ExtendsUnionSome(inferred, type, tail)), () => ExtendsFalse());
|
|
203026
203229
|
}
|
|
203027
203230
|
function ExtendsUnionLeft(inferred, left, right) {
|
|
203028
|
-
return exports_guard.
|
|
203231
|
+
return exports_guard.ShiftLeft(left, (head, tail) => Match3(ExtendsUnionSome(inferred, head, right), (inferred2) => ExtendsUnionLeft(inferred2, tail, right), () => ExtendsFalse()), () => ExtendsTrue(inferred));
|
|
203029
203232
|
}
|
|
203030
203233
|
function ExtendsUnion2(inferred, left, right) {
|
|
203031
203234
|
const inferrable = TryInferable(right);
|
|
203032
203235
|
return IsInferable(inferrable) ? InferUnionResult(inferred, inferrable.name, left, inferrable.type) : IsUnion(right) ? ExtendsUnionLeft(inferred, left, right.anyOf) : ExtendsUnionLeft(inferred, left, [right]);
|
|
203033
203236
|
}
|
|
203034
203237
|
|
|
203035
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203238
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/unknown.mjs
|
|
203036
203239
|
function ExtendsUnknown(inferred, left, right) {
|
|
203037
203240
|
return IsInfer(right) ? ExtendsRight(inferred, left, right) : IsAny(right) ? ExtendsTrue(inferred) : IsUnknown(right) ? ExtendsTrue(inferred) : ExtendsFalse();
|
|
203038
203241
|
}
|
|
203039
203242
|
|
|
203040
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203243
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/void.mjs
|
|
203041
203244
|
function ExtendsVoid(inferred, left, right) {
|
|
203042
203245
|
return IsVoid(right) ? ExtendsTrue(inferred) : ExtendsRight(inferred, left, right);
|
|
203043
203246
|
}
|
|
203044
203247
|
|
|
203045
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203248
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/extends_left.mjs
|
|
203046
203249
|
function ExtendsLeft(inferred, left, right) {
|
|
203047
|
-
return IsAny(left) ? ExtendsAny(inferred, left, right) : IsArray2(left) ? ExtendsArray(inferred, left, left.items, right) :
|
|
203250
|
+
return IsAny(left) ? ExtendsAny(inferred, left, right) : IsArray2(left) ? ExtendsArray(inferred, left, left.items, right) : IsBigInt2(left) ? ExtendsBigInt(inferred, left, right) : IsBoolean3(left) ? ExtendsBoolean(inferred, left, right) : IsConstructor2(left) ? ExtendsConstructor(inferred, left.parameters, left.instanceType, right) : IsDependent(left) ? ExtendsDependent(inferred, left.if, left.then, left.else, right) : IsEnum(left) ? ExtendsEnum(inferred, left.enum, right) : IsFunction2(left) ? ExtendsFunction(inferred, left.parameters, left.returnType, right) : IsInteger2(left) ? ExtendsInteger(inferred, left, right) : IsIntersect(left) ? ExtendsIntersect(inferred, left.allOf, right) : IsLiteral(left) ? ExtendsLiteral(inferred, left, right) : IsNever(left) ? ExtendsNever(inferred, left, right) : IsNull2(left) ? ExtendsNull(inferred, left, right) : IsNumber3(left) ? ExtendsNumber(inferred, left, right) : IsObject2(left) ? ExtendsObject(inferred, left.properties, right) : IsRecord(left) ? ExtendsRecord(inferred, RecordPattern(left), RecordValue(left), right) : IsString3(left) ? ExtendsString(inferred, left, right) : IsSymbol2(left) ? ExtendsSymbol(inferred, left, right) : IsTemplateLiteral(left) ? ExtendsTemplateLiteral(inferred, left.pattern, right) : IsTuple(left) ? ExtendsTuple(inferred, left.items, right) : IsUndefined2(left) ? ExtendsUndefined(inferred, left, right) : IsUnion(left) ? ExtendsUnion2(inferred, left.anyOf, right) : IsUnknown(left) ? ExtendsUnknown(inferred, left, right) : IsVoid(left) ? ExtendsVoid(inferred, left, right) : ExtendsFalse();
|
|
203048
203251
|
}
|
|
203049
203252
|
|
|
203050
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203253
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/interface/instantiate.mjs
|
|
203051
203254
|
function InterfaceOperation(heritage, properties2) {
|
|
203052
203255
|
const result = EvaluateIntersect([...heritage, _Object_(properties2)]);
|
|
203053
203256
|
return result;
|
|
@@ -203062,7 +203265,7 @@ function InterfaceInstantiate(context, state, heritage, properties2, options) {
|
|
|
203062
203265
|
return InterfaceAction(instantiatedHeritage, instantiatedProperties, options);
|
|
203063
203266
|
}
|
|
203064
203267
|
|
|
203065
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203268
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/interface.mjs
|
|
203066
203269
|
function InterfaceDeferred(heritage, properties2, options = {}) {
|
|
203067
203270
|
return Deferred("Interface", [heritage, properties2], options);
|
|
203068
203271
|
}
|
|
@@ -203073,7 +203276,7 @@ function Interface(heritage, properties2, options = {}) {
|
|
|
203073
203276
|
return InterfaceAction(heritage, properties2, options);
|
|
203074
203277
|
}
|
|
203075
203278
|
|
|
203076
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203279
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/cyclic/check.mjs
|
|
203077
203280
|
function FromRef(stack, context, ref2) {
|
|
203078
203281
|
return stack.includes(ref2) ? true : FromType3([...stack, ref2], context, context[ref2]);
|
|
203079
203282
|
}
|
|
@@ -203082,20 +203285,20 @@ function FromProperties(stack, context, properties2) {
|
|
|
203082
203285
|
return FromTypes2(stack, context, types2);
|
|
203083
203286
|
}
|
|
203084
203287
|
function FromTypes2(stack, context, types2) {
|
|
203085
|
-
return exports_guard.
|
|
203288
|
+
return exports_guard.ShiftLeft(types2, (left, right) => FromType3(stack, context, left) ? true : FromTypes2(stack, context, right), () => false);
|
|
203086
203289
|
}
|
|
203087
203290
|
function FromType3(stack, context, type) {
|
|
203088
|
-
return IsRef(type) ? FromRef(stack, context, type.$ref) : IsArray2(type) ? FromType3(stack, context, type.items) :
|
|
203291
|
+
return IsRef(type) ? FromRef(stack, context, type.$ref) : IsArray2(type) ? FromType3(stack, context, type.items) : IsConstructor2(type) ? FromTypes2(stack, context, [...type.parameters, type.instanceType]) : IsFunction2(type) ? FromTypes2(stack, context, [...type.parameters, type.returnType]) : IsInterfaceDeferred(type) ? FromProperties(stack, context, type.parameters[1]) : IsIntersect(type) ? FromTypes2(stack, context, type.allOf) : IsObject2(type) ? FromProperties(stack, context, type.properties) : IsUnion(type) ? FromTypes2(stack, context, type.anyOf) : IsTuple(type) ? FromTypes2(stack, context, type.items) : IsRecord(type) ? FromType3(stack, context, RecordValue(type)) : false;
|
|
203089
203292
|
}
|
|
203090
203293
|
function CyclicCheck(stack, context, type) {
|
|
203091
203294
|
const result = FromType3(stack, context, type);
|
|
203092
203295
|
return result;
|
|
203093
203296
|
}
|
|
203094
203297
|
|
|
203095
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203298
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/cyclic/candidates.mjs
|
|
203096
203299
|
function ResolveCandidateKeys(context, keys) {
|
|
203097
203300
|
return keys.reduce((result, left) => {
|
|
203098
|
-
return
|
|
203301
|
+
return CyclicCheck([left], context, context[left]) ? [...result, left] : result;
|
|
203099
203302
|
}, []);
|
|
203100
203303
|
}
|
|
203101
203304
|
function CyclicCandidates(context) {
|
|
@@ -203103,7 +203306,7 @@ function CyclicCandidates(context) {
|
|
|
203103
203306
|
const result = ResolveCandidateKeys(context, keys);
|
|
203104
203307
|
return result;
|
|
203105
203308
|
}
|
|
203106
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203309
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/cyclic/dependencies.mjs
|
|
203107
203310
|
function FromRef2(context, ref2, result) {
|
|
203108
203311
|
return result.includes(ref2) ? result : (ref2 in context) ? FromType4(context, context[ref2], [...result, ref2]) : Unreachable();
|
|
203109
203312
|
}
|
|
@@ -203117,13 +203320,13 @@ function FromTypes3(context, types2, result) {
|
|
|
203117
203320
|
}, result);
|
|
203118
203321
|
}
|
|
203119
203322
|
function FromType4(context, type, result) {
|
|
203120
|
-
return IsRef(type) ? FromRef2(context, type.$ref, result) : IsArray2(type) ? FromType4(context, type.items, result) :
|
|
203323
|
+
return IsRef(type) ? FromRef2(context, type.$ref, result) : IsArray2(type) ? FromType4(context, type.items, result) : IsConstructor2(type) ? FromTypes3(context, [...type.parameters, type.instanceType], result) : IsFunction2(type) ? FromTypes3(context, [...type.parameters, type.returnType], result) : IsInterfaceDeferred(type) ? FromProperties2(context, type.parameters[1], result) : IsIntersect(type) ? FromTypes3(context, type.allOf, result) : IsObject2(type) ? FromProperties2(context, type.properties, result) : IsUnion(type) ? FromTypes3(context, type.anyOf, result) : IsTuple(type) ? FromTypes3(context, type.items, result) : IsRecord(type) ? FromType4(context, RecordValue(type), result) : result;
|
|
203121
203324
|
}
|
|
203122
203325
|
function CyclicDependencies(context, key, type) {
|
|
203123
203326
|
const result = FromType4(context, type, [key]);
|
|
203124
203327
|
return result;
|
|
203125
203328
|
}
|
|
203126
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203329
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/cyclic/extends.mjs
|
|
203127
203330
|
function FromRef3(_ref) {
|
|
203128
203331
|
return Any();
|
|
203129
203332
|
}
|
|
@@ -203138,7 +203341,7 @@ function FromTypes4(types2) {
|
|
|
203138
203341
|
}, []);
|
|
203139
203342
|
}
|
|
203140
203343
|
function FromType5(type) {
|
|
203141
|
-
return IsRef(type) ? FromRef3(type.$ref) : IsArray2(type) ? _Array_(FromType5(type.items), ArrayOptions(type)) :
|
|
203344
|
+
return IsRef(type) ? FromRef3(type.$ref) : IsArray2(type) ? _Array_(FromType5(type.items), ArrayOptions(type)) : IsConstructor2(type) ? Constructor(FromTypes4(type.parameters), FromType5(type.instanceType)) : IsFunction2(type) ? _Function_(FromTypes4(type.parameters), FromType5(type.returnType)) : IsIntersect(type) ? Intersect(FromTypes4(type.allOf)) : IsObject2(type) ? _Object_(FromProperties3(type.properties)) : IsRecord(type) ? Record(RecordKey(type), FromType5(RecordValue(type))) : IsUnion(type) ? Union(FromTypes4(type.anyOf)) : IsTuple(type) ? Tuple(FromTypes4(type.items)) : type;
|
|
203142
203345
|
}
|
|
203143
203346
|
function CyclicAnyFromParameters(defs, ref2) {
|
|
203144
203347
|
return ref2 in defs ? FromType5(defs[ref2]) : Unknown();
|
|
@@ -203146,10 +203349,10 @@ function CyclicAnyFromParameters(defs, ref2) {
|
|
|
203146
203349
|
function CyclicExtends(type) {
|
|
203147
203350
|
return CyclicAnyFromParameters(type.$defs, type.$ref);
|
|
203148
203351
|
}
|
|
203149
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203352
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/cyclic/instantiate.mjs
|
|
203150
203353
|
function CyclicInterface(context, heritage, properties2) {
|
|
203151
|
-
const instantiatedHeritage = InstantiateTypes(context,
|
|
203152
|
-
const instantiatedProperties = InstantiateProperties({},
|
|
203354
|
+
const instantiatedHeritage = InstantiateTypes(context, State([], []), heritage);
|
|
203355
|
+
const instantiatedProperties = InstantiateProperties({}, State([], []), properties2);
|
|
203153
203356
|
const evaluatedInterface = EvaluateIntersect([...instantiatedHeritage, _Object_(instantiatedProperties)]);
|
|
203154
203357
|
return evaluatedInterface;
|
|
203155
203358
|
}
|
|
@@ -203167,7 +203370,7 @@ function InstantiateCyclic(context, ref2, type) {
|
|
|
203167
203370
|
const result = Cyclic(definitions, ref2);
|
|
203168
203371
|
return result;
|
|
203169
203372
|
}
|
|
203170
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203373
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/cyclic/target.mjs
|
|
203171
203374
|
function Resolve(defs, ref2) {
|
|
203172
203375
|
return ref2 in defs ? IsRef(defs[ref2]) ? Resolve(defs, defs[ref2].$ref) : defs[ref2] : Never();
|
|
203173
203376
|
}
|
|
@@ -203175,29 +203378,29 @@ function CyclicTarget(defs, ref2) {
|
|
|
203175
203378
|
const result = Resolve(defs, ref2);
|
|
203176
203379
|
return result;
|
|
203177
203380
|
}
|
|
203178
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203381
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/extends/extends.mjs
|
|
203179
203382
|
function Canonical(type) {
|
|
203180
203383
|
return IsCyclic(type) ? CyclicExtends(type) : IsUnsafe(type) ? Unknown() : type;
|
|
203181
203384
|
}
|
|
203182
|
-
function
|
|
203385
|
+
function Extends(inferred, left, right) {
|
|
203183
203386
|
const canonicalLeft = Canonical(left);
|
|
203184
203387
|
const canonicalRight = Canonical(right);
|
|
203185
203388
|
return ExtendsLeft(inferred, canonicalLeft, canonicalRight);
|
|
203186
203389
|
}
|
|
203187
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203390
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/evaluate/compare.mjs
|
|
203188
203391
|
var ResultEqual = "equal";
|
|
203189
203392
|
var ResultDisjoint = "disjoint";
|
|
203190
203393
|
var ResultLeftInside = "left-inside";
|
|
203191
203394
|
var ResultRightInside = "right-inside";
|
|
203192
203395
|
function Compare(left, right) {
|
|
203193
203396
|
const extendsCheck = [
|
|
203194
|
-
IsUnknown(left) ? exports_result.ExtendsFalse() :
|
|
203195
|
-
IsUnknown(left) ? exports_result.ExtendsTrue({}) :
|
|
203397
|
+
IsUnknown(left) ? exports_result.ExtendsFalse() : Extends({}, left, right),
|
|
203398
|
+
IsUnknown(left) ? exports_result.ExtendsTrue({}) : Extends({}, right, left)
|
|
203196
203399
|
];
|
|
203197
203400
|
return exports_result.IsExtendsTrueLike(extendsCheck[0]) && exports_result.IsExtendsTrueLike(extendsCheck[1]) ? ResultEqual : exports_result.IsExtendsTrueLike(extendsCheck[0]) && exports_result.IsExtendsFalse(extendsCheck[1]) ? ResultLeftInside : exports_result.IsExtendsFalse(extendsCheck[0]) && exports_result.IsExtendsTrueLike(extendsCheck[1]) ? ResultRightInside : ResultDisjoint;
|
|
203198
203401
|
}
|
|
203199
203402
|
|
|
203200
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203403
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/evaluate/broaden.mjs
|
|
203201
203404
|
function BroadFilter(type, types2) {
|
|
203202
203405
|
return types2.filter((left) => {
|
|
203203
203406
|
return Compare(type, left) === ResultRightInside ? false : true;
|
|
@@ -203222,10 +203425,9 @@ function BroadenTypes(types2) {
|
|
|
203222
203425
|
function Broaden(types2) {
|
|
203223
203426
|
const broadened = BroadenTypes(types2);
|
|
203224
203427
|
const flattened = Flatten(broadened);
|
|
203225
|
-
|
|
203226
|
-
return result;
|
|
203428
|
+
return flattened;
|
|
203227
203429
|
}
|
|
203228
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203430
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/evaluate/instantiate.mjs
|
|
203229
203431
|
function EvaluateAction(type, options) {
|
|
203230
203432
|
const result = exports_memory.Update(EvaluateType(type), {}, options);
|
|
203231
203433
|
return result;
|
|
@@ -203234,7 +203436,7 @@ function EvaluateInstantiate(context, state, type, options) {
|
|
|
203234
203436
|
const instantiatedType = InstantiateType(context, state, type);
|
|
203235
203437
|
return EvaluateAction(instantiatedType, options);
|
|
203236
203438
|
}
|
|
203237
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203439
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/call/distribute_arguments.mjs
|
|
203238
203440
|
function CollectDistributionNames(expression, result = []) {
|
|
203239
203441
|
return IsDeferred(expression) && exports_guard.IsEqual(expression.action, "Conditional") ? IsRef(expression.parameters[0]) ? CollectDistributionNames(expression.parameters[2], CollectDistributionNames(expression.parameters[3], [...result, expression.parameters[0]["$ref"]])) : CollectDistributionNames(expression.parameters[2], CollectDistributionNames(expression.parameters[3], result)) : IsDeferred(expression) && exports_guard.IsEqual(expression.action, "Mapped") ? IsDeferred(expression.parameters[1]) && exports_guard.IsEqual(expression.parameters[1].action, "KeyOf") && IsRef(expression.parameters[1].parameters[0]) ? [...result, expression.parameters[1].parameters[0]["$ref"]] : result : result;
|
|
203240
203442
|
}
|
|
@@ -203242,7 +203444,7 @@ function BuildDistributionArray(parameters, names) {
|
|
|
203242
203444
|
return parameters.reduce((result, left) => [...result, names.includes(left.name)], []);
|
|
203243
203445
|
}
|
|
203244
203446
|
function ZipDistributionArray(arguments_, distributionArray, result = []) {
|
|
203245
|
-
return exports_guard.
|
|
203447
|
+
return exports_guard.ShiftLeft(arguments_, (argumentLeft, argumentRight) => exports_guard.ShiftLeft(distributionArray, (booleanLeft, booleanRight) => ZipDistributionArray(argumentRight, booleanRight, [...result, [booleanLeft, argumentLeft]]), () => result), () => result);
|
|
203246
203448
|
}
|
|
203247
203449
|
function Expand(type) {
|
|
203248
203450
|
return IsUnion(type) ? [...type.anyOf] : [type];
|
|
@@ -203267,7 +203469,7 @@ function DistributeArguments(parameters, arguments_, expression) {
|
|
|
203267
203469
|
return IsDeferred(expression) && exports_guard.IsEqual(expression.action, "Conditional") ? Distribute2(zippedArguments) : IsDeferred(expression) && exports_guard.IsEqual(expression.action, "Mapped") ? Distribute2(zippedArguments) : [arguments_];
|
|
203268
203470
|
}
|
|
203269
203471
|
|
|
203270
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203472
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/call/resolve_target.mjs
|
|
203271
203473
|
function FromNotResolvable() {
|
|
203272
203474
|
return ["(not-resolvable)", Never()];
|
|
203273
203475
|
}
|
|
@@ -203287,9 +203489,9 @@ function ResolveTarget(context, target2, arguments_) {
|
|
|
203287
203489
|
return FromType6(context, "(anonymous)", target2, arguments_);
|
|
203288
203490
|
}
|
|
203289
203491
|
|
|
203290
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203492
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/call/resolve_arguments.mjs
|
|
203291
203493
|
function AssertArgumentExtends(name2, type, extends_) {
|
|
203292
|
-
if (IsInfer(type) || IsCall(type) || exports_result.IsExtendsTrueLike(
|
|
203494
|
+
if (IsInfer(type) || IsCall(type) || exports_result.IsExtendsTrueLike(Extends({}, type, extends_)))
|
|
203293
203495
|
return;
|
|
203294
203496
|
const cause = { parameter: name2, expect: extends_, actual: type };
|
|
203295
203497
|
throw new Error(`Argument for parameter ${name2} does not satisfy constraint`, { cause });
|
|
@@ -203302,16 +203504,16 @@ function BindArgument(context, state, name2, extends_, type) {
|
|
|
203302
203504
|
function BindArguments(context, state, parameterLeft, parameterRight, arguments_) {
|
|
203303
203505
|
const instantiatedExtends = InstantiateType(context, state, parameterLeft.extends);
|
|
203304
203506
|
const instantiatedEquals = InstantiateType(context, state, parameterLeft.equals);
|
|
203305
|
-
return exports_guard.
|
|
203507
|
+
return exports_guard.ShiftLeft(arguments_, (left, right) => BindParameters(BindArgument(context, state, parameterLeft["name"], instantiatedExtends, left), state, parameterRight, right), () => BindParameters(BindArgument(context, state, parameterLeft["name"], instantiatedExtends, instantiatedEquals), state, parameterRight, []));
|
|
203306
203508
|
}
|
|
203307
203509
|
function BindParameters(context, state, parameters, arguments_) {
|
|
203308
|
-
return exports_guard.
|
|
203510
|
+
return exports_guard.ShiftLeft(parameters, (left, right) => BindArguments(context, state, left, right, arguments_), () => context);
|
|
203309
203511
|
}
|
|
203310
203512
|
function ResolveArgumentsContext(context, state, parameters, arguments_) {
|
|
203311
203513
|
return BindParameters(context, state, parameters, arguments_);
|
|
203312
203514
|
}
|
|
203313
203515
|
|
|
203314
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203516
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/call/instantiate.mjs
|
|
203315
203517
|
function Peek(state) {
|
|
203316
203518
|
const result = exports_guard.IsGreaterThan(state.callstack.length, 0) ? state.callstack[state.callstack.length - 1] : "";
|
|
203317
203519
|
return result;
|
|
@@ -203322,8 +203524,8 @@ function IsTailCall(state, name2) {
|
|
|
203322
203524
|
}
|
|
203323
203525
|
function CallDispatch(context, state, target2, parameters, expression, arguments_) {
|
|
203324
203526
|
const argumentsContext = ResolveArgumentsContext(context, state, parameters, arguments_);
|
|
203325
|
-
const returnType = InstantiateType(argumentsContext,
|
|
203326
|
-
return InstantiateType(
|
|
203527
|
+
const returnType = InstantiateType(argumentsContext, State([...state["callstack"], target2["$ref"]], state["visited"]), expression);
|
|
203528
|
+
return InstantiateType(argumentsContext, State([], []), returnType);
|
|
203327
203529
|
}
|
|
203328
203530
|
function CallDistributed(context, state, target2, parameters, expression, distributedArguments) {
|
|
203329
203531
|
return distributedArguments.reduce((result, arguments_) => [...result, CallDispatch(context, state, target2, parameters, expression, arguments_)], []);
|
|
@@ -203343,46 +203545,59 @@ function CallInstantiate(context, state, target2, arguments_) {
|
|
|
203343
203545
|
return result;
|
|
203344
203546
|
}
|
|
203345
203547
|
|
|
203346
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203548
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/types/call.mjs
|
|
203347
203549
|
function CallConstruct(target2, arguments_) {
|
|
203348
|
-
return exports_memory.Create({ ["~kind"]: "Call" }, { target: target2, arguments: arguments_ }, {});
|
|
203550
|
+
return exports_memory.Create({ ["~kind"]: "Call" }, { type: "call", target: target2, arguments: arguments_ }, {});
|
|
203349
203551
|
}
|
|
203350
203552
|
function Call(target2, arguments_) {
|
|
203351
|
-
return CallInstantiate({},
|
|
203553
|
+
return CallInstantiate({}, State([], []), target2, arguments_);
|
|
203352
203554
|
}
|
|
203353
203555
|
function IsCall(value) {
|
|
203354
203556
|
return IsKind(value, "Call");
|
|
203355
203557
|
}
|
|
203356
203558
|
|
|
203357
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203559
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/immutable/instantiate_remove.mjs
|
|
203560
|
+
function RemoveImmutableOperation(type) {
|
|
203561
|
+
return exports_memory.Discard(type, ["~immutable"]);
|
|
203562
|
+
}
|
|
203563
|
+
function RemoveImmutableAction(type, options) {
|
|
203564
|
+
const result = exports_memory.Update(RemoveImmutableOperation(type), {}, options);
|
|
203565
|
+
return result;
|
|
203566
|
+
}
|
|
203567
|
+
function RemoveImmutableInstantiate(context, state, type, options) {
|
|
203568
|
+
const instantiatedType = InstantiateType(context, state, type);
|
|
203569
|
+
return RemoveImmutableAction(instantiatedType, options);
|
|
203570
|
+
}
|
|
203571
|
+
|
|
203572
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/intrinsics/mapping.mjs
|
|
203358
203573
|
function ApplyMapping(mapping, value) {
|
|
203359
203574
|
return mapping(value);
|
|
203360
203575
|
}
|
|
203361
203576
|
|
|
203362
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203577
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/intrinsics/from_literal.mjs
|
|
203363
203578
|
function FromLiteral3(mapping, value) {
|
|
203364
203579
|
return exports_guard.IsString(value) ? Literal(ApplyMapping(mapping, value)) : Literal(value);
|
|
203365
203580
|
}
|
|
203366
203581
|
|
|
203367
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203582
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/intrinsics/from_template_literal.mjs
|
|
203368
203583
|
function FromTemplateLiteral(mapping, pattern) {
|
|
203369
|
-
const
|
|
203370
|
-
const result = FromType7(mapping,
|
|
203584
|
+
const evaluated = EvaluateTemplateLiteral(pattern);
|
|
203585
|
+
const result = FromType7(mapping, evaluated);
|
|
203371
203586
|
return result;
|
|
203372
203587
|
}
|
|
203373
203588
|
|
|
203374
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203589
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/intrinsics/from_union.mjs
|
|
203375
203590
|
function FromUnion2(mapping, types2) {
|
|
203376
203591
|
const result = types2.map((type) => FromType7(mapping, type));
|
|
203377
203592
|
return Union(result);
|
|
203378
203593
|
}
|
|
203379
203594
|
|
|
203380
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203595
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/intrinsics/from_type.mjs
|
|
203381
203596
|
function FromType7(mapping, type) {
|
|
203382
203597
|
return IsLiteral(type) ? FromLiteral3(mapping, type.const) : IsTemplateLiteral(type) ? FromTemplateLiteral(mapping, type.pattern) : IsUnion(type) ? FromUnion2(mapping, type.anyOf) : type;
|
|
203383
203598
|
}
|
|
203384
203599
|
|
|
203385
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203600
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/capitalize.mjs
|
|
203386
203601
|
function CapitalizeDeferred(type, options = {}) {
|
|
203387
203602
|
return Deferred("Capitalize", [type], options);
|
|
203388
203603
|
}
|
|
@@ -203390,7 +203605,7 @@ function Capitalize(type, options = {}) {
|
|
|
203390
203605
|
return CapitalizeAction(type, options);
|
|
203391
203606
|
}
|
|
203392
203607
|
|
|
203393
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203608
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/lowercase.mjs
|
|
203394
203609
|
function LowercaseDeferred(type, options = {}) {
|
|
203395
203610
|
return Deferred("Lowercase", [type], options);
|
|
203396
203611
|
}
|
|
@@ -203398,7 +203613,7 @@ function Lowercase(type, options = {}) {
|
|
|
203398
203613
|
return LowercaseAction(type, options);
|
|
203399
203614
|
}
|
|
203400
203615
|
|
|
203401
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203616
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/uncapitalize.mjs
|
|
203402
203617
|
function UncapitalizeDeferred(type, options = {}) {
|
|
203403
203618
|
return Deferred("Uncapitalize", [type], options);
|
|
203404
203619
|
}
|
|
@@ -203406,7 +203621,7 @@ function Uncapitalize(type, options = {}) {
|
|
|
203406
203621
|
return UncapitalizeAction(type, options);
|
|
203407
203622
|
}
|
|
203408
203623
|
|
|
203409
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203624
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/uppercase.mjs
|
|
203410
203625
|
function UppercaseDeferred(type, options = {}) {
|
|
203411
203626
|
return Deferred("Uppercase", [type], options);
|
|
203412
203627
|
}
|
|
@@ -203414,7 +203629,7 @@ function Uppercase(type, options = {}) {
|
|
|
203414
203629
|
return UppercaseAction(type, options);
|
|
203415
203630
|
}
|
|
203416
203631
|
|
|
203417
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203632
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/intrinsics/instantiate.mjs
|
|
203418
203633
|
var CapitalizeMapping = (input) => input[0].toUpperCase() + input.slice(1);
|
|
203419
203634
|
var LowercaseMapping = (input) => input.toLowerCase();
|
|
203420
203635
|
var UncapitalizeMapping = (input) => input[0].toLowerCase() + input.slice(1);
|
|
@@ -203452,17 +203667,17 @@ function UppercaseInstantiate(context, state, type, options) {
|
|
|
203452
203667
|
return UppercaseAction(instantiatedType, options);
|
|
203453
203668
|
}
|
|
203454
203669
|
|
|
203455
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203670
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/conditional.mjs
|
|
203456
203671
|
function ConditionalDeferred(left, right, true_, false_, options = {}) {
|
|
203457
203672
|
return Deferred("Conditional", [left, right, true_, false_], options);
|
|
203458
203673
|
}
|
|
203459
203674
|
function Conditional(left, right, true_, false_, options = {}) {
|
|
203460
|
-
return ConditionalAction({},
|
|
203675
|
+
return ConditionalAction({}, State([], []), left, right, true_, false_, options);
|
|
203461
203676
|
}
|
|
203462
203677
|
|
|
203463
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203678
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/conditional/instantiate.mjs
|
|
203464
203679
|
function ConditionalOperation(context, state, left, right, true_, false_) {
|
|
203465
|
-
const extendsResult =
|
|
203680
|
+
const extendsResult = Extends(context, left, right);
|
|
203466
203681
|
return exports_result.IsExtendsUnion(extendsResult) ? Union([InstantiateType(extendsResult.inferred, state, true_), InstantiateType(context, state, false_)]) : exports_result.IsExtendsTrue(extendsResult) ? InstantiateType(extendsResult.inferred, state, true_) : InstantiateType(context, state, false_);
|
|
203467
203682
|
}
|
|
203468
203683
|
function ConditionalAction(context, state, left, right, true_, false_, options) {
|
|
@@ -203474,7 +203689,7 @@ function ConditionalInstantiate(context, state, left, right, true_, false_, opti
|
|
|
203474
203689
|
const instantiatedRight = InstantiateType(context, state, right);
|
|
203475
203690
|
return ConditionalAction(context, state, instantiatedLeft, instantiatedRight, true_, false_, options);
|
|
203476
203691
|
}
|
|
203477
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203692
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/constructor_parameters.mjs
|
|
203478
203693
|
function ConstructorParametersDeferred(type, options = {}) {
|
|
203479
203694
|
return Deferred("ConstructorParameters", [type], options);
|
|
203480
203695
|
}
|
|
@@ -203482,10 +203697,10 @@ function ConstructorParameters(type, options = {}) {
|
|
|
203482
203697
|
return ConstructorParametersAction(type, options);
|
|
203483
203698
|
}
|
|
203484
203699
|
|
|
203485
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203700
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/constructor_parameters/instantiate.mjs
|
|
203486
203701
|
function ConstructorParametersOperation(type) {
|
|
203487
203702
|
const parameters = IsConstructor2(type) ? type["parameters"] : [];
|
|
203488
|
-
const instantiatedParameters = InstantiateElements({},
|
|
203703
|
+
const instantiatedParameters = InstantiateElements({}, State([], []), parameters);
|
|
203489
203704
|
const result = Tuple(instantiatedParameters);
|
|
203490
203705
|
return result;
|
|
203491
203706
|
}
|
|
@@ -203498,7 +203713,7 @@ function ConstructorParametersInstantiate(context, state, type, options) {
|
|
|
203498
203713
|
return ConstructorParametersAction(instantiatedType, options);
|
|
203499
203714
|
}
|
|
203500
203715
|
|
|
203501
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203716
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/exclude.mjs
|
|
203502
203717
|
function ExcludeDeferred(left, right, options = {}) {
|
|
203503
203718
|
return Deferred("Exclude", [left, right], options);
|
|
203504
203719
|
}
|
|
@@ -203506,24 +203721,7 @@ function Exclude(left, right, options = {}) {
|
|
|
203506
203721
|
return ExcludeAction(left, right, options);
|
|
203507
203722
|
}
|
|
203508
203723
|
|
|
203509
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203510
|
-
function ExcludeUnionLeft(types2, right) {
|
|
203511
|
-
return types2.reduce((result, head) => {
|
|
203512
|
-
return [...result, ...ExcludeTypeLeft(head, right)];
|
|
203513
|
-
}, []);
|
|
203514
|
-
}
|
|
203515
|
-
function ExcludeTypeLeft(left, right) {
|
|
203516
|
-
const check3 = Extends2({}, left, right);
|
|
203517
|
-
const result = exports_result.IsExtendsTrueLike(check3) ? [] : [left];
|
|
203518
|
-
return result;
|
|
203519
|
-
}
|
|
203520
|
-
function ExcludeOperation(left, right) {
|
|
203521
|
-
const remaining = IsEnum(left) ? ExcludeUnionLeft(EnumValuesToVariants(left.enum), right) : IsUnion(left) ? ExcludeUnionLeft(Flatten(left.anyOf), right) : ExcludeTypeLeft(left, right);
|
|
203522
|
-
const result = EvaluateUnion(remaining);
|
|
203523
|
-
return result;
|
|
203524
|
-
}
|
|
203525
|
-
|
|
203526
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/engine/exclude/instantiate.mjs
|
|
203724
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/exclude/instantiate.mjs
|
|
203527
203725
|
function ExcludeAction(left, right, options) {
|
|
203528
203726
|
const result = CanInstantiate([left, right]) ? exports_memory.Update(ExcludeOperation(left, right), {}, options) : ExcludeDeferred(left, right, options);
|
|
203529
203727
|
return result;
|
|
@@ -203534,7 +203732,7 @@ function ExcludeInstantiate(context, state, left, right, options) {
|
|
|
203534
203732
|
return ExcludeAction(instantiatedLeft, instantiatedRight, options);
|
|
203535
203733
|
}
|
|
203536
203734
|
|
|
203537
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203735
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/extract.mjs
|
|
203538
203736
|
function ExtractDeferred(left, right, options = {}) {
|
|
203539
203737
|
return Deferred("Extract", [left, right], options);
|
|
203540
203738
|
}
|
|
@@ -203542,24 +203740,26 @@ function Extract(left, right, options = {}) {
|
|
|
203542
203740
|
return ExtractAction(left, right, options);
|
|
203543
203741
|
}
|
|
203544
203742
|
|
|
203545
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203546
|
-
function
|
|
203547
|
-
|
|
203548
|
-
return [...result, ...ExtractTypeLeft(head, right)];
|
|
203549
|
-
}, []);
|
|
203550
|
-
}
|
|
203551
|
-
function ExtractTypeLeft(left, right) {
|
|
203552
|
-
const check3 = Extends2({}, left, right);
|
|
203743
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/extract/operation.mjs
|
|
203744
|
+
function ExtractType(left, right) {
|
|
203745
|
+
const check3 = Extends({}, left, right);
|
|
203553
203746
|
const result = exports_result.IsExtendsTrueLike(check3) ? [left] : [];
|
|
203554
203747
|
return result;
|
|
203555
203748
|
}
|
|
203749
|
+
function ExtractUnion(types2, right) {
|
|
203750
|
+
return types2.reduce((result, head) => {
|
|
203751
|
+
return [...result, ...ExtractType(head, right)];
|
|
203752
|
+
}, []);
|
|
203753
|
+
}
|
|
203556
203754
|
function ExtractOperation(left, right) {
|
|
203557
|
-
const
|
|
203755
|
+
const evaluated = EvaluateType(left);
|
|
203756
|
+
const canonical = IsUnion(evaluated) ? evaluated.anyOf : [evaluated];
|
|
203757
|
+
const remaining = ExtractUnion(canonical, right);
|
|
203558
203758
|
const result = EvaluateUnion(remaining);
|
|
203559
203759
|
return result;
|
|
203560
203760
|
}
|
|
203561
203761
|
|
|
203562
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203762
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/extract/instantiate.mjs
|
|
203563
203763
|
function ExtractAction(left, right, options) {
|
|
203564
203764
|
const result = CanInstantiate([left, right]) ? exports_memory.Update(ExtractOperation(left, right), {}, options) : ExtractDeferred(left, right, options);
|
|
203565
203765
|
return result;
|
|
@@ -203570,7 +203770,7 @@ function ExtractInstantiate(context, state, left, right, options) {
|
|
|
203570
203770
|
return ExtractAction(instantiatedLeft, instantiatedRight, options);
|
|
203571
203771
|
}
|
|
203572
203772
|
|
|
203573
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203773
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/helpers/keys_to_indexer.mjs
|
|
203574
203774
|
function KeysToLiterals(keys) {
|
|
203575
203775
|
return keys.reduce((result, left) => {
|
|
203576
203776
|
return IsLiteralValue(left) ? [...result, Literal(left)] : result;
|
|
@@ -203582,7 +203782,7 @@ function KeysToIndexer(keys) {
|
|
|
203582
203782
|
return result;
|
|
203583
203783
|
}
|
|
203584
203784
|
|
|
203585
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203785
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/indexed.mjs
|
|
203586
203786
|
function IndexDeferred(type, indexer, options = {}) {
|
|
203587
203787
|
return Deferred("Index", [type, indexer], options);
|
|
203588
203788
|
}
|
|
@@ -203591,14 +203791,21 @@ function Index(type, indexer_or_keys, options = {}) {
|
|
|
203591
203791
|
return IndexAction(type, indexer, options);
|
|
203592
203792
|
}
|
|
203593
203793
|
|
|
203594
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203794
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/object/from_cyclic.mjs
|
|
203595
203795
|
function FromCyclic(defs, ref2) {
|
|
203596
203796
|
const target2 = CyclicTarget(defs, ref2);
|
|
203597
203797
|
const result = FromType8(target2);
|
|
203598
203798
|
return result;
|
|
203599
203799
|
}
|
|
203600
203800
|
|
|
203601
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203801
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/object/from_dependent.mjs
|
|
203802
|
+
function FromDependent(if_, then_, else_) {
|
|
203803
|
+
const evaluated = EvaluateDependent(if_, then_, else_);
|
|
203804
|
+
const result = FromType8(evaluated);
|
|
203805
|
+
return result;
|
|
203806
|
+
}
|
|
203807
|
+
|
|
203808
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/object/from_intersect.mjs
|
|
203602
203809
|
function CollapseIntersectProperties(left, right) {
|
|
203603
203810
|
const leftKeys = exports_guard.Keys(left).filter((key) => !exports_guard.HasPropertyKey(right, key));
|
|
203604
203811
|
const rightKeys = exports_guard.Keys(right).filter((key) => !exports_guard.HasPropertyKey(left, key));
|
|
@@ -203616,19 +203823,19 @@ function FromIntersect(types2) {
|
|
|
203616
203823
|
}, {});
|
|
203617
203824
|
}
|
|
203618
203825
|
|
|
203619
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203620
|
-
function
|
|
203826
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/object/from_object.mjs
|
|
203827
|
+
function FromObject3(properties2) {
|
|
203621
203828
|
return properties2;
|
|
203622
203829
|
}
|
|
203623
203830
|
|
|
203624
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203831
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/object/from_tuple.mjs
|
|
203625
203832
|
function FromTuple(types2) {
|
|
203626
203833
|
const object3 = TupleToObject(Tuple(types2));
|
|
203627
203834
|
const result = FromType8(object3);
|
|
203628
203835
|
return result;
|
|
203629
203836
|
}
|
|
203630
203837
|
|
|
203631
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203838
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/object/from_union.mjs
|
|
203632
203839
|
function CollapseUnionProperties(left, right) {
|
|
203633
203840
|
const sharedKeys = exports_guard.Keys(left).filter((key) => (key in right));
|
|
203634
203841
|
const result = sharedKeys.reduce((result2, key) => {
|
|
@@ -203637,31 +203844,31 @@ function CollapseUnionProperties(left, right) {
|
|
|
203637
203844
|
return result;
|
|
203638
203845
|
}
|
|
203639
203846
|
function ReduceVariants(types2, result) {
|
|
203640
|
-
return exports_guard.
|
|
203847
|
+
return exports_guard.ShiftLeft(types2, (left, right) => ReduceVariants(right, CollapseUnionProperties(result, FromType8(left))), () => result);
|
|
203641
203848
|
}
|
|
203642
203849
|
function FromUnion3(types2) {
|
|
203643
|
-
return exports_guard.
|
|
203850
|
+
return exports_guard.ShiftLeft(types2, (left, right) => ReduceVariants(right, FromType8(left)), () => Unreachable());
|
|
203644
203851
|
}
|
|
203645
203852
|
|
|
203646
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203853
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/object/from_type.mjs
|
|
203647
203854
|
function FromType8(type) {
|
|
203648
|
-
return IsCyclic(type) ? FromCyclic(type.$defs, type.$ref) : IsIntersect(type) ? FromIntersect(type.allOf) : IsUnion(type) ? FromUnion3(type.anyOf) : IsTuple(type) ? FromTuple(type.items) : IsObject2(type) ?
|
|
203855
|
+
return IsCyclic(type) ? FromCyclic(type.$defs, type.$ref) : IsDependent(type) ? FromDependent(type.if, type.then, type.else) : IsIntersect(type) ? FromIntersect(type.allOf) : IsUnion(type) ? FromUnion3(type.anyOf) : IsTuple(type) ? FromTuple(type.items) : IsObject2(type) ? FromObject3(type.properties) : {};
|
|
203649
203856
|
}
|
|
203650
203857
|
|
|
203651
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203858
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/object/collapse.mjs
|
|
203652
203859
|
function CollapseToObject(type) {
|
|
203653
203860
|
const properties2 = FromType8(type);
|
|
203654
203861
|
const result = _Object_(properties2);
|
|
203655
203862
|
return result;
|
|
203656
203863
|
}
|
|
203657
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203864
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/helpers/keys.mjs
|
|
203658
203865
|
var integerKeyPattern = new RegExp("^(?:0|[1-9][0-9]*)$");
|
|
203659
203866
|
function ConvertToIntegerKey(value) {
|
|
203660
203867
|
const normal = `${value}`;
|
|
203661
203868
|
return integerKeyPattern.test(normal) ? parseInt(normal) : value;
|
|
203662
203869
|
}
|
|
203663
203870
|
|
|
203664
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203871
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexed/from_array.mjs
|
|
203665
203872
|
function NormalizeLiteral(value) {
|
|
203666
203873
|
return Literal(ConvertToIntegerKey(value));
|
|
203667
203874
|
}
|
|
@@ -203673,76 +203880,83 @@ function NormalizeIndexer(type) {
|
|
|
203673
203880
|
}
|
|
203674
203881
|
function FromArray2(type, indexer) {
|
|
203675
203882
|
const normalizedIndexer = NormalizeIndexer(indexer);
|
|
203676
|
-
const check3 =
|
|
203883
|
+
const check3 = Extends({}, normalizedIndexer, Number2());
|
|
203677
203884
|
const result = exports_result.IsExtendsTrueLike(check3) ? type : IsLiteral(indexer) && exports_guard.IsEqual(indexer.const, "length") ? Number2() : Never();
|
|
203678
203885
|
return result;
|
|
203679
203886
|
}
|
|
203680
203887
|
|
|
203681
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203888
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/from_cyclic.mjs
|
|
203682
203889
|
function FromCyclic2(defs, ref2) {
|
|
203683
203890
|
const target2 = CyclicTarget(defs, ref2);
|
|
203684
203891
|
const result = FromType9(target2);
|
|
203685
203892
|
return result;
|
|
203686
203893
|
}
|
|
203687
203894
|
|
|
203688
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203689
|
-
function
|
|
203690
|
-
|
|
203691
|
-
|
|
203692
|
-
|
|
203895
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/from_dependent.mjs
|
|
203896
|
+
function FromDependent2(if_, then_, else_) {
|
|
203897
|
+
const evaluated = EvaluateDependent(if_, then_, else_);
|
|
203898
|
+
const result = FromType9(evaluated);
|
|
203899
|
+
return result;
|
|
203693
203900
|
}
|
|
203694
203901
|
|
|
203695
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203902
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/from_enum.mjs
|
|
203696
203903
|
function FromEnum(values) {
|
|
203697
|
-
const
|
|
203698
|
-
const result =
|
|
203904
|
+
const evaluated = EvaluateEnum(values);
|
|
203905
|
+
const result = FromType9(evaluated);
|
|
203699
203906
|
return result;
|
|
203700
203907
|
}
|
|
203701
203908
|
|
|
203702
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203909
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/from_intersect.mjs
|
|
203703
203910
|
function FromIntersect2(types2) {
|
|
203704
203911
|
const evaluated = EvaluateIntersect(types2);
|
|
203705
203912
|
const result = FromType9(evaluated);
|
|
203706
203913
|
return result;
|
|
203707
203914
|
}
|
|
203708
203915
|
|
|
203709
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203916
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/from_literal.mjs
|
|
203710
203917
|
function FromLiteral4(value) {
|
|
203711
203918
|
const result = [`${value}`];
|
|
203712
203919
|
return result;
|
|
203713
203920
|
}
|
|
203714
203921
|
|
|
203715
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203922
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/from_template_literal.mjs
|
|
203716
203923
|
function FromTemplateLiteral2(pattern) {
|
|
203717
|
-
const
|
|
203718
|
-
const result = FromType9(
|
|
203924
|
+
const evaluated = EvaluateTemplateLiteral(pattern);
|
|
203925
|
+
const result = FromType9(evaluated);
|
|
203719
203926
|
return result;
|
|
203720
203927
|
}
|
|
203721
203928
|
|
|
203722
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203929
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/from_union.mjs
|
|
203930
|
+
function FromUnion4(types2) {
|
|
203931
|
+
return types2.reduce((result, left) => {
|
|
203932
|
+
return [...result, ...FromType9(left)];
|
|
203933
|
+
}, []);
|
|
203934
|
+
}
|
|
203935
|
+
|
|
203936
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/from_type.mjs
|
|
203723
203937
|
function FromType9(type) {
|
|
203724
|
-
return IsCyclic(type) ? FromCyclic2(type.$defs, type.$ref) : IsEnum(type) ? FromEnum(type.enum) : IsIntersect(type) ? FromIntersect2(type.allOf) : IsLiteral(type) ? FromLiteral4(type.const) : IsTemplateLiteral(type) ? FromTemplateLiteral2(type.pattern) : IsUnion(type) ? FromUnion4(type.anyOf) : [];
|
|
203938
|
+
return IsCyclic(type) ? FromCyclic2(type.$defs, type.$ref) : IsDependent(type) ? FromDependent2(type.if, type.then, type.else) : IsEnum(type) ? FromEnum(type.enum) : IsIntersect(type) ? FromIntersect2(type.allOf) : IsLiteral(type) ? FromLiteral4(type.const) : IsTemplateLiteral(type) ? FromTemplateLiteral2(type.pattern) : IsUnion(type) ? FromUnion4(type.anyOf) : [];
|
|
203725
203939
|
}
|
|
203726
203940
|
|
|
203727
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203941
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/to_indexable_keys.mjs
|
|
203728
203942
|
function ToIndexableKeys(type) {
|
|
203729
203943
|
const result = FromType9(type);
|
|
203730
203944
|
return result;
|
|
203731
203945
|
}
|
|
203732
203946
|
|
|
203733
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203947
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/this/expand_this.mjs
|
|
203734
203948
|
function FromTypes5(properties2, types2) {
|
|
203735
203949
|
return types2.map((type) => FromType10(properties2, type));
|
|
203736
203950
|
}
|
|
203737
203951
|
function FromType10(properties2, type) {
|
|
203738
|
-
return IsArray2(type) ? _Array_(FromType10(properties2, type.items)) :
|
|
203952
|
+
return IsArray2(type) ? _Array_(FromType10(properties2, type.items)) : IsConstructor2(type) ? Constructor(FromTypes5(properties2, type.parameters), FromType10(properties2, type.instanceType)) : IsFunction2(type) ? _Function_(FromTypes5(properties2, type.parameters), FromType10(properties2, type.returnType)) : IsTuple(type) ? Tuple(FromTypes5(properties2, type.items)) : IsUnion(type) ? Union(FromTypes5(properties2, type.anyOf)) : IsIntersect(type) ? Intersect(FromTypes5(properties2, type.allOf)) : IsThis(type) ? _Object_(properties2) : type;
|
|
203739
203953
|
}
|
|
203740
203954
|
function ExpandThis(properties2, type) {
|
|
203741
203955
|
const result = FromType10(properties2, type);
|
|
203742
203956
|
return result;
|
|
203743
203957
|
}
|
|
203744
203958
|
|
|
203745
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203959
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexed/from_object.mjs
|
|
203746
203960
|
function IndexProperty(properties2, key) {
|
|
203747
203961
|
const selectedType = key in properties2 ? properties2[key] : Never();
|
|
203748
203962
|
const result = ExpandThis(properties2, selectedType);
|
|
@@ -203771,12 +203985,12 @@ function FromIndexerNumber(properties2) {
|
|
|
203771
203985
|
const result = EvaluateUnion(variants);
|
|
203772
203986
|
return result;
|
|
203773
203987
|
}
|
|
203774
|
-
function
|
|
203775
|
-
const result =
|
|
203988
|
+
function FromObject4(properties2, indexer) {
|
|
203989
|
+
const result = IsNumber3(indexer) ? FromIndexerNumber(properties2) : FromIndexer(properties2, indexer);
|
|
203776
203990
|
return result;
|
|
203777
203991
|
}
|
|
203778
203992
|
|
|
203779
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203993
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexed/array_indexer.mjs
|
|
203780
203994
|
function ConvertLiteral(value) {
|
|
203781
203995
|
return Literal(ConvertToIntegerKey(value));
|
|
203782
203996
|
}
|
|
@@ -203787,10 +204001,10 @@ function FormatArrayIndexer(type) {
|
|
|
203787
204001
|
return IsIntersect(type) ? Intersect(ArrayIndexerTypes(type.allOf)) : IsUnion(type) ? Union(ArrayIndexerTypes(type.anyOf)) : IsLiteral(type) ? ConvertLiteral(type.const) : type;
|
|
203788
204002
|
}
|
|
203789
204003
|
|
|
203790
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204004
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexed/from_tuple.mjs
|
|
203791
204005
|
function IndexElementsWithIndexer(types2, indexer) {
|
|
203792
204006
|
return types2.reduceRight((result, right, index) => {
|
|
203793
|
-
const check3 =
|
|
204007
|
+
const check3 = Extends({}, Literal(index), indexer);
|
|
203794
204008
|
return exports_result.IsExtendsTrueLike(check3) ? [right, ...result] : result;
|
|
203795
204009
|
}, []);
|
|
203796
204010
|
}
|
|
@@ -203803,17 +204017,17 @@ function FromTupleWithoutIndexer(types2) {
|
|
|
203803
204017
|
return EvaluateUnionFast(types2);
|
|
203804
204018
|
}
|
|
203805
204019
|
function FromTuple2(types2, indexer) {
|
|
203806
|
-
return IsLiteral(indexer) && exports_guard.IsEqual(indexer.const, "length") ? Literal(types2.length) :
|
|
204020
|
+
return IsLiteral(indexer) && exports_guard.IsEqual(indexer.const, "length") ? Literal(types2.length) : IsNumber3(indexer) || IsInteger2(indexer) ? FromTupleWithoutIndexer(types2) : FromTupleWithIndexer(types2, indexer);
|
|
203807
204021
|
}
|
|
203808
204022
|
|
|
203809
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204023
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexed/from_type.mjs
|
|
203810
204024
|
function FromType11(type, indexer) {
|
|
203811
|
-
return IsArray2(type) ? FromArray2(type.items, indexer) : IsObject2(type) ?
|
|
204025
|
+
return IsArray2(type) ? FromArray2(type.items, indexer) : IsObject2(type) ? FromObject4(type.properties, indexer) : IsTuple(type) ? FromTuple2(type.items, indexer) : Never();
|
|
203812
204026
|
}
|
|
203813
204027
|
|
|
203814
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204028
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexed/instantiate.mjs
|
|
203815
204029
|
function NormalizeType(type) {
|
|
203816
|
-
const result = IsCyclic(type) || IsIntersect(type) || IsUnion(type) ? CollapseToObject(type) : type;
|
|
204030
|
+
const result = IsCyclic(type) || IsDependent(type) || IsIntersect(type) || IsUnion(type) ? CollapseToObject(type) : type;
|
|
203817
204031
|
return result;
|
|
203818
204032
|
}
|
|
203819
204033
|
function IndexAction(type, indexer, options) {
|
|
@@ -203826,7 +204040,7 @@ function IndexInstantiate(context, state, type, indexer, options) {
|
|
|
203826
204040
|
return IndexAction(instantiatedType, instantiatedIndexer, options);
|
|
203827
204041
|
}
|
|
203828
204042
|
|
|
203829
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204043
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/instance_type.mjs
|
|
203830
204044
|
function InstanceTypeDeferred(type, options = {}) {
|
|
203831
204045
|
return Deferred("InstanceType", [type], options);
|
|
203832
204046
|
}
|
|
@@ -203834,7 +204048,7 @@ function InstanceType(type, options = {}) {
|
|
|
203834
204048
|
return InstanceTypeAction(type, options);
|
|
203835
204049
|
}
|
|
203836
204050
|
|
|
203837
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204051
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/instance_type/instantiate.mjs
|
|
203838
204052
|
function InstanceTypeOperation(type) {
|
|
203839
204053
|
return IsConstructor2(type) ? type["instanceType"] : Never();
|
|
203840
204054
|
}
|
|
@@ -203847,7 +204061,7 @@ function InstanceTypeInstantiate(context, state, type, options = {}) {
|
|
|
203847
204061
|
return InstanceTypeAction(instantiatedType, options);
|
|
203848
204062
|
}
|
|
203849
204063
|
|
|
203850
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204064
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/keyof.mjs
|
|
203851
204065
|
function KeyOfDeferred(type, options = {}) {
|
|
203852
204066
|
return Deferred("KeyOf", [type], options);
|
|
203853
204067
|
}
|
|
@@ -203855,49 +204069,49 @@ function KeyOf2(type, options = {}) {
|
|
|
203855
204069
|
return KeyOfAction(type, options);
|
|
203856
204070
|
}
|
|
203857
204071
|
|
|
203858
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204072
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/keyof/from_any.mjs
|
|
203859
204073
|
function FromAny() {
|
|
203860
204074
|
return Union([Number2(), String2(), Symbol2()]);
|
|
203861
204075
|
}
|
|
203862
204076
|
|
|
203863
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204077
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/keyof/from_array.mjs
|
|
203864
204078
|
function FromArray3(_type) {
|
|
203865
204079
|
return Number2();
|
|
203866
204080
|
}
|
|
203867
204081
|
|
|
203868
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204082
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/keyof/from_object.mjs
|
|
203869
204083
|
function FromPropertyKeys(keys) {
|
|
203870
204084
|
const result = keys.reduce((result2, left) => {
|
|
203871
204085
|
return IsLiteralValue(left) ? [...result2, Literal(ConvertToIntegerKey(left))] : Unreachable();
|
|
203872
204086
|
}, []);
|
|
203873
204087
|
return result;
|
|
203874
204088
|
}
|
|
203875
|
-
function
|
|
204089
|
+
function FromObject5(properties2) {
|
|
203876
204090
|
const propertyKeys = exports_guard.Keys(properties2);
|
|
203877
204091
|
const variants = FromPropertyKeys(propertyKeys);
|
|
203878
204092
|
const result = EvaluateUnionFast(variants);
|
|
203879
204093
|
return result;
|
|
203880
204094
|
}
|
|
203881
204095
|
|
|
203882
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203883
|
-
function
|
|
204096
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/keyof/from_record.mjs
|
|
204097
|
+
function FromRecord2(type) {
|
|
203884
204098
|
return RecordKey(type);
|
|
203885
204099
|
}
|
|
203886
204100
|
|
|
203887
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204101
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/keyof/from_tuple.mjs
|
|
203888
204102
|
function FromTuple3(types2) {
|
|
203889
204103
|
const result = types2.map((_, index) => Literal(index));
|
|
203890
204104
|
return EvaluateUnionFast(result);
|
|
203891
204105
|
}
|
|
203892
204106
|
|
|
203893
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204107
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/keyof/from_type.mjs
|
|
203894
204108
|
function FromType12(type) {
|
|
203895
|
-
return IsAny(type) ? FromAny() : IsArray2(type) ? FromArray3(type.items) : IsObject2(type) ?
|
|
204109
|
+
return IsAny(type) ? FromAny() : IsArray2(type) ? FromArray3(type.items) : IsObject2(type) ? FromObject5(type.properties) : IsRecord(type) ? FromRecord2(type) : IsTuple(type) ? FromTuple3(type.items) : Never();
|
|
203896
204110
|
}
|
|
203897
204111
|
|
|
203898
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204112
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/keyof/instantiate.mjs
|
|
203899
204113
|
function NormalizeType2(type) {
|
|
203900
|
-
const result = IsCyclic(type) || IsIntersect(type) || IsUnion(type) ? CollapseToObject(type) : type;
|
|
204114
|
+
const result = IsCyclic(type) || IsDependent(type) || IsIntersect(type) || IsUnion(type) ? CollapseToObject(type) : type;
|
|
203901
204115
|
return result;
|
|
203902
204116
|
}
|
|
203903
204117
|
function KeyOfAction(type, options) {
|
|
@@ -203908,18 +204122,18 @@ function KeyOfInstantiate(context, state, type, options) {
|
|
|
203908
204122
|
return KeyOfAction(instantiatedType, options);
|
|
203909
204123
|
}
|
|
203910
204124
|
|
|
203911
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204125
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/mapped.mjs
|
|
203912
204126
|
function MappedDeferred(identifier2, type, as, property, options = {}) {
|
|
203913
204127
|
return Deferred("Mapped", [identifier2, type, as, property], options);
|
|
203914
204128
|
}
|
|
203915
|
-
function
|
|
203916
|
-
return MappedAction({},
|
|
204129
|
+
function Mapped(identifier2, type, as, property, options = {}) {
|
|
204130
|
+
return MappedAction({}, State([], []), identifier2, type, as, property, options);
|
|
203917
204131
|
}
|
|
203918
204132
|
|
|
203919
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204133
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/mapped/mapped_variants.mjs
|
|
203920
204134
|
function FromTemplateLiteral3(pattern) {
|
|
203921
|
-
const
|
|
203922
|
-
const result = FromType13(
|
|
204135
|
+
const evaluated = EvaluateTemplateLiteral(pattern);
|
|
204136
|
+
const result = FromType13(evaluated);
|
|
203923
204137
|
return result;
|
|
203924
204138
|
}
|
|
203925
204139
|
function FromUnion5(types2) {
|
|
@@ -203927,12 +204141,17 @@ function FromUnion5(types2) {
|
|
|
203927
204141
|
return [...result, ...FromType13(left)];
|
|
203928
204142
|
}, []);
|
|
203929
204143
|
}
|
|
204144
|
+
function FromEnum2(values) {
|
|
204145
|
+
const evaluated = EvaluateEnum(values);
|
|
204146
|
+
const result = FromType13(evaluated);
|
|
204147
|
+
return result;
|
|
204148
|
+
}
|
|
203930
204149
|
function FromLiteral5(value) {
|
|
203931
204150
|
const result = exports_guard.IsNumber(value) ? [Literal(`${value}`)] : [Literal(value)];
|
|
203932
204151
|
return result;
|
|
203933
204152
|
}
|
|
203934
204153
|
function FromType13(type) {
|
|
203935
|
-
const result = IsEnum(type) ?
|
|
204154
|
+
const result = IsEnum(type) ? FromEnum2(type.enum) : IsLiteral(type) ? FromLiteral5(type.const) : IsTemplateLiteral(type) ? FromTemplateLiteral3(type.pattern) : IsUnion(type) ? FromUnion5(type.anyOf) : [type];
|
|
203936
204155
|
return result;
|
|
203937
204156
|
}
|
|
203938
204157
|
function MappedVariants(type) {
|
|
@@ -203940,9 +204159,9 @@ function MappedVariants(type) {
|
|
|
203940
204159
|
return result;
|
|
203941
204160
|
}
|
|
203942
204161
|
|
|
203943
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204162
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/mapped/mapped_operation.mjs
|
|
203944
204163
|
function CanonicalAs(instantiatedAs) {
|
|
203945
|
-
const result = IsTemplateLiteral(instantiatedAs) ?
|
|
204164
|
+
const result = IsTemplateLiteral(instantiatedAs) ? EvaluateTemplateLiteral(instantiatedAs.pattern) : instantiatedAs;
|
|
203946
204165
|
return result;
|
|
203947
204166
|
}
|
|
203948
204167
|
function MappedVariant(context, state, identifier2, variant, as, property) {
|
|
@@ -203970,7 +204189,7 @@ function MappedOperation(context, state, identifier2, type, as, property) {
|
|
|
203970
204189
|
return result;
|
|
203971
204190
|
}
|
|
203972
204191
|
|
|
203973
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204192
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/mapped/instantiate.mjs
|
|
203974
204193
|
function MappedAction(context, state, identifier2, type, as, property, options) {
|
|
203975
204194
|
const result = CanInstantiate([type]) ? exports_memory.Update(MappedOperation(context, state, identifier2, type, as, property), {}, options) : MappedDeferred(identifier2, type, as, property, options);
|
|
203976
204195
|
return result;
|
|
@@ -203980,33 +204199,34 @@ function MappedInstantiate(context, state, identifier2, type, as, property, opti
|
|
|
203980
204199
|
return MappedAction(context, state, identifier2, instantiatedType, as, property, options);
|
|
203981
204200
|
}
|
|
203982
204201
|
|
|
203983
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
203984
|
-
function InstantiateCyclics(context, cyclicKeys) {
|
|
203985
|
-
const
|
|
203986
|
-
|
|
203987
|
-
|
|
204202
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/module/instantiate.mjs
|
|
204203
|
+
function InstantiateCyclics(context, declarations, cyclicKeys) {
|
|
204204
|
+
const declarationContext = exports_memory.Assign(context, declarations);
|
|
204205
|
+
const declarationKeys = exports_guard.Keys(declarations).filter((key) => cyclicKeys.includes(key));
|
|
204206
|
+
return declarationKeys.reduce((result, key) => {
|
|
204207
|
+
return { ...result, [key]: InstantiateCyclic(declarationContext, key, declarations[key]) };
|
|
203988
204208
|
}, {});
|
|
203989
204209
|
}
|
|
203990
|
-
function InstantiateNonCyclics(context, cyclicKeys) {
|
|
203991
|
-
const
|
|
203992
|
-
|
|
203993
|
-
|
|
204210
|
+
function InstantiateNonCyclics(context, declarations, cyclicKeys) {
|
|
204211
|
+
const declarationContext = exports_memory.Assign(context, declarations);
|
|
204212
|
+
const declarationKeys = exports_guard.Keys(declarations).filter((key) => !cyclicKeys.includes(key));
|
|
204213
|
+
return declarationKeys.reduce((result, key) => {
|
|
204214
|
+
return { ...result, [key]: InstantiateType(declarationContext, State([], []), declarations[key]) };
|
|
203994
204215
|
}, {});
|
|
203995
204216
|
}
|
|
203996
|
-
function InstantiateModule(context, options) {
|
|
203997
|
-
const cyclicCandidates = CyclicCandidates(
|
|
203998
|
-
const instantiatedCyclics = InstantiateCyclics(context, cyclicCandidates);
|
|
203999
|
-
const instantiatedNonCyclics = InstantiateNonCyclics(context, cyclicCandidates);
|
|
204217
|
+
function InstantiateModule(context, declarations, options) {
|
|
204218
|
+
const cyclicCandidates = CyclicCandidates(declarations);
|
|
204219
|
+
const instantiatedCyclics = InstantiateCyclics(context, declarations, cyclicCandidates);
|
|
204220
|
+
const instantiatedNonCyclics = InstantiateNonCyclics(context, declarations, cyclicCandidates);
|
|
204000
204221
|
const instantiatedModule = { ...instantiatedCyclics, ...instantiatedNonCyclics };
|
|
204001
204222
|
return exports_memory.Update(instantiatedModule, {}, options);
|
|
204002
204223
|
}
|
|
204003
|
-
function ModuleInstantiate(context, _state,
|
|
204004
|
-
const
|
|
204005
|
-
const instantiatedModule = InstantiateModule(moduleContext, options);
|
|
204224
|
+
function ModuleInstantiate(context, _state, declarations, options) {
|
|
204225
|
+
const instantiatedModule = InstantiateModule(context, declarations, options);
|
|
204006
204226
|
return instantiatedModule;
|
|
204007
204227
|
}
|
|
204008
204228
|
|
|
204009
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204229
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/non_nullable.mjs
|
|
204010
204230
|
function NonNullableDeferred(type, options = {}) {
|
|
204011
204231
|
return Deferred("NonNullable", [type], options);
|
|
204012
204232
|
}
|
|
@@ -204014,7 +204234,7 @@ function NonNullable(type, options = {}) {
|
|
|
204014
204234
|
return NonNullableAction(type, options);
|
|
204015
204235
|
}
|
|
204016
204236
|
|
|
204017
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204237
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/non_nullable/instantiate.mjs
|
|
204018
204238
|
function NonNullableOperation(type) {
|
|
204019
204239
|
const excluded = Union([Null(), Undefined()]);
|
|
204020
204240
|
return ExcludeAction(type, excluded, {});
|
|
@@ -204028,7 +204248,7 @@ function NonNullableInstantiate(context, state, type, options) {
|
|
|
204028
204248
|
return NonNullableAction(instantiatedType, options);
|
|
204029
204249
|
}
|
|
204030
204250
|
|
|
204031
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204251
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/omit.mjs
|
|
204032
204252
|
function OmitDeferred(type, indexer, options = {}) {
|
|
204033
204253
|
return Deferred("Omit", [type, indexer], options);
|
|
204034
204254
|
}
|
|
@@ -204037,14 +204257,14 @@ function Omit(type, indexer_or_keys, options = {}) {
|
|
|
204037
204257
|
return OmitAction(type, indexer, options);
|
|
204038
204258
|
}
|
|
204039
204259
|
|
|
204040
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204260
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/indexable/to_indexable.mjs
|
|
204041
204261
|
function ToIndexable(type) {
|
|
204042
204262
|
const collapsed = CollapseToObject(type);
|
|
204043
204263
|
const result = IsObject2(collapsed) ? collapsed.properties : Unreachable();
|
|
204044
204264
|
return result;
|
|
204045
204265
|
}
|
|
204046
204266
|
|
|
204047
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204267
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/omit/from_type.mjs
|
|
204048
204268
|
function FromKeys(properties2, keys) {
|
|
204049
204269
|
const result = exports_guard.Keys(properties2).reduce((result2, key) => {
|
|
204050
204270
|
return keys.includes(key) ? result2 : { ...result2, [key]: properties2[key] };
|
|
@@ -204059,7 +204279,7 @@ function FromType14(type, indexer) {
|
|
|
204059
204279
|
return result;
|
|
204060
204280
|
}
|
|
204061
204281
|
|
|
204062
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204282
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/omit/instantiate.mjs
|
|
204063
204283
|
function OmitAction(type, indexer, options) {
|
|
204064
204284
|
const result = CanInstantiate([type, indexer]) ? exports_memory.Update(FromType14(type, indexer), {}, options) : OmitDeferred(type, indexer, options);
|
|
204065
204285
|
return result;
|
|
@@ -204070,25 +204290,7 @@ function OmitInstantiate(context, state, type, indexer, options) {
|
|
|
204070
204290
|
return OmitAction(instantiatedType, instantiatedIndexer, options);
|
|
204071
204291
|
}
|
|
204072
204292
|
|
|
204073
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204074
|
-
function OptionsDeferred(type, options) {
|
|
204075
|
-
return Deferred("Options", [type, options], {});
|
|
204076
|
-
}
|
|
204077
|
-
function Options2(type, options) {
|
|
204078
|
-
return OptionsAction(type, options);
|
|
204079
|
-
}
|
|
204080
|
-
|
|
204081
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/engine/options/instantiate.mjs
|
|
204082
|
-
function OptionsAction(type, options) {
|
|
204083
|
-
const result = CanInstantiate([type]) ? exports_memory.Update(type, {}, options) : OptionsDeferred(type, options);
|
|
204084
|
-
return result;
|
|
204085
|
-
}
|
|
204086
|
-
function OptionsInstantiate(context, state, type, options) {
|
|
204087
|
-
const instaniatedType = InstantiateType(context, state, type);
|
|
204088
|
-
return OptionsAction(instaniatedType, options);
|
|
204089
|
-
}
|
|
204090
|
-
|
|
204091
|
-
// ../../node_modules/.bun/typebox@1.1.38/node_modules/typebox/build/type/action/parameters.mjs
|
|
204293
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/parameters.mjs
|
|
204092
204294
|
function ParametersDeferred(type, options = {}) {
|
|
204093
204295
|
return Deferred("Parameters", [type], options);
|
|
204094
204296
|
}
|
|
@@ -204096,10 +204298,10 @@ function Parameters(type, options = {}) {
|
|
|
204096
204298
|
return ParametersAction(type, options);
|
|
204097
204299
|
}
|
|
204098
204300
|
|
|
204099
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204301
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/parameters/instantiate.mjs
|
|
204100
204302
|
function ParametersOperation(type) {
|
|
204101
204303
|
const parameters = IsFunction2(type) ? type["parameters"] : [];
|
|
204102
|
-
const instantiatedParameters = InstantiateElements({},
|
|
204304
|
+
const instantiatedParameters = InstantiateElements({}, State([], []), parameters);
|
|
204103
204305
|
const result = Tuple(instantiatedParameters);
|
|
204104
204306
|
return result;
|
|
204105
204307
|
}
|
|
@@ -204112,7 +204314,7 @@ function ParametersInstantiate(context, state, type, options) {
|
|
|
204112
204314
|
return ParametersAction(instantiatedType, options);
|
|
204113
204315
|
}
|
|
204114
204316
|
|
|
204115
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204317
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/partial.mjs
|
|
204116
204318
|
function PartialDeferred(type, options = {}) {
|
|
204117
204319
|
return Deferred("Partial", [type], options);
|
|
204118
204320
|
}
|
|
@@ -204120,7 +204322,7 @@ function Partial(type, options = {}) {
|
|
|
204120
204322
|
return PartialAction(type, options);
|
|
204121
204323
|
}
|
|
204122
204324
|
|
|
204123
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204325
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/partial/from_cyclic.mjs
|
|
204124
204326
|
function FromCyclic3(defs, ref2) {
|
|
204125
204327
|
const target2 = CyclicTarget(defs, ref2);
|
|
204126
204328
|
const partial2 = FromType15(target2);
|
|
@@ -204128,33 +204330,41 @@ function FromCyclic3(defs, ref2) {
|
|
|
204128
204330
|
return result;
|
|
204129
204331
|
}
|
|
204130
204332
|
|
|
204131
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204333
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/partial/from_dependent.mjs
|
|
204334
|
+
function FromDependent3(if_, then_, else_) {
|
|
204335
|
+
const evaluated = EvaluateDependent(if_, then_, else_);
|
|
204336
|
+
const result = FromType15(evaluated);
|
|
204337
|
+
return result;
|
|
204338
|
+
}
|
|
204339
|
+
|
|
204340
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/partial/from_intersect.mjs
|
|
204132
204341
|
function FromIntersect3(types2) {
|
|
204133
|
-
const
|
|
204134
|
-
|
|
204342
|
+
const evaluated = EvaluateIntersect(types2);
|
|
204343
|
+
const result = FromType15(evaluated);
|
|
204344
|
+
return result;
|
|
204135
204345
|
}
|
|
204136
204346
|
|
|
204137
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204347
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/partial/from_union.mjs
|
|
204138
204348
|
function FromUnion6(types2) {
|
|
204139
204349
|
const result = types2.map((type) => FromType15(type));
|
|
204140
204350
|
return Union(result);
|
|
204141
204351
|
}
|
|
204142
204352
|
|
|
204143
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204144
|
-
function
|
|
204353
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/partial/from_object.mjs
|
|
204354
|
+
function FromObject6(properties2) {
|
|
204145
204355
|
const mapped = exports_guard.Keys(properties2).reduce((result2, left) => {
|
|
204146
|
-
return { ...result2, [left]:
|
|
204356
|
+
return { ...result2, [left]: AddOptional(properties2[left]) };
|
|
204147
204357
|
}, {});
|
|
204148
204358
|
const result = _Object_(mapped);
|
|
204149
204359
|
return result;
|
|
204150
204360
|
}
|
|
204151
204361
|
|
|
204152
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204362
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/partial/from_type.mjs
|
|
204153
204363
|
function FromType15(type) {
|
|
204154
|
-
return IsCyclic(type) ? FromCyclic3(type.$defs, type.$ref) : IsIntersect(type) ? FromIntersect3(type.allOf) : IsUnion(type) ? FromUnion6(type.anyOf) : IsObject2(type) ?
|
|
204364
|
+
return IsCyclic(type) ? FromCyclic3(type.$defs, type.$ref) : IsDependent(type) ? FromDependent3(type.if, type.then, type.else) : IsIntersect(type) ? FromIntersect3(type.allOf) : IsUnion(type) ? FromUnion6(type.anyOf) : IsObject2(type) ? FromObject6(type.properties) : _Object_({});
|
|
204155
204365
|
}
|
|
204156
204366
|
|
|
204157
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204367
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/partial/instantiate.mjs
|
|
204158
204368
|
function PartialAction(type, options) {
|
|
204159
204369
|
const result = CanInstantiate([type]) ? exports_memory.Update(FromType15(type), {}, options) : PartialDeferred(type, options);
|
|
204160
204370
|
return result;
|
|
@@ -204164,7 +204374,7 @@ function PartialInstantiate(context, state, type, options) {
|
|
|
204164
204374
|
return PartialAction(instantiatedType, options);
|
|
204165
204375
|
}
|
|
204166
204376
|
|
|
204167
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204377
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/pick.mjs
|
|
204168
204378
|
function PickDeferred(type, indexer, options = {}) {
|
|
204169
204379
|
return Deferred("Pick", [type, indexer], options);
|
|
204170
204380
|
}
|
|
@@ -204173,7 +204383,7 @@ function Pick(type, indexer_or_keys, options = {}) {
|
|
|
204173
204383
|
return PickAction(type, indexer, options);
|
|
204174
204384
|
}
|
|
204175
204385
|
|
|
204176
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204386
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/pick/from_type.mjs
|
|
204177
204387
|
function FromKeys2(properties2, keys) {
|
|
204178
204388
|
const result = exports_guard.Keys(properties2).reduce((result2, key) => {
|
|
204179
204389
|
return keys.includes(key) ? exports_memory.Assign(result2, { [key]: properties2[key] }) : result2;
|
|
@@ -204188,7 +204398,7 @@ function FromType16(type, indexer) {
|
|
|
204188
204398
|
return result;
|
|
204189
204399
|
}
|
|
204190
204400
|
|
|
204191
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204401
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/pick/instantiate.mjs
|
|
204192
204402
|
function PickAction(type, indexer, options) {
|
|
204193
204403
|
const result = CanInstantiate([type, indexer]) ? exports_memory.Update(FromType16(type, indexer), {}, options) : PickDeferred(type, indexer, options);
|
|
204194
204404
|
return result;
|
|
@@ -204199,22 +204409,21 @@ function PickInstantiate(context, state, type, indexer, options) {
|
|
|
204199
204409
|
return PickAction(instantiatedType, instantiatedIndexer, options);
|
|
204200
204410
|
}
|
|
204201
204411
|
|
|
204202
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204412
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/readonly_object.mjs
|
|
204203
204413
|
function ReadonlyObjectDeferred(type, options = {}) {
|
|
204204
204414
|
return Deferred("ReadonlyObject", [type], options);
|
|
204205
204415
|
}
|
|
204206
204416
|
function ReadonlyObject(type, options = {}) {
|
|
204207
204417
|
return ReadonlyObjectAction(type, options);
|
|
204208
204418
|
}
|
|
204209
|
-
var ReadonlyType = ReadonlyObject;
|
|
204210
204419
|
|
|
204211
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204420
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/from_array.mjs
|
|
204212
204421
|
function FromArray4(type) {
|
|
204213
|
-
const result =
|
|
204422
|
+
const result = AddImmutable(_Array_(type));
|
|
204214
204423
|
return result;
|
|
204215
204424
|
}
|
|
204216
204425
|
|
|
204217
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204426
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/from_cyclic.mjs
|
|
204218
204427
|
function FromCyclic4(defs, ref2) {
|
|
204219
204428
|
const target2 = CyclicTarget(defs, ref2);
|
|
204220
204429
|
const partial2 = FromType17(target2);
|
|
@@ -204222,39 +204431,47 @@ function FromCyclic4(defs, ref2) {
|
|
|
204222
204431
|
return result;
|
|
204223
204432
|
}
|
|
204224
204433
|
|
|
204225
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204434
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/from_dependent.mjs
|
|
204435
|
+
function FromDependent4(if_, then_, else_) {
|
|
204436
|
+
const evaluated = EvaluateDependent(if_, then_, else_);
|
|
204437
|
+
const result = FromType17(evaluated);
|
|
204438
|
+
return result;
|
|
204439
|
+
}
|
|
204440
|
+
|
|
204441
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/from_intersect.mjs
|
|
204226
204442
|
function FromIntersect4(types2) {
|
|
204227
|
-
const
|
|
204228
|
-
|
|
204443
|
+
const evaluated = EvaluateIntersect(types2);
|
|
204444
|
+
const result = FromType17(evaluated);
|
|
204445
|
+
return result;
|
|
204229
204446
|
}
|
|
204230
204447
|
|
|
204231
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204232
|
-
function
|
|
204448
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/from_object.mjs
|
|
204449
|
+
function FromObject7(properties2) {
|
|
204233
204450
|
const mapped = exports_guard.Keys(properties2).reduce((result2, left) => {
|
|
204234
|
-
return { ...result2, [left]:
|
|
204451
|
+
return { ...result2, [left]: AddReadonly(properties2[left]) };
|
|
204235
204452
|
}, {});
|
|
204236
204453
|
const result = _Object_(mapped);
|
|
204237
204454
|
return result;
|
|
204238
204455
|
}
|
|
204239
204456
|
|
|
204240
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204457
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/from_tuple.mjs
|
|
204241
204458
|
function FromTuple4(types2) {
|
|
204242
|
-
const result =
|
|
204459
|
+
const result = AddImmutable(Tuple(types2));
|
|
204243
204460
|
return result;
|
|
204244
204461
|
}
|
|
204245
204462
|
|
|
204246
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204463
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/from_union.mjs
|
|
204247
204464
|
function FromUnion7(types2) {
|
|
204248
204465
|
const result = types2.map((type) => FromType17(type));
|
|
204249
204466
|
return Union(result);
|
|
204250
204467
|
}
|
|
204251
204468
|
|
|
204252
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204469
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/from_type.mjs
|
|
204253
204470
|
function FromType17(type) {
|
|
204254
|
-
return IsArray2(type) ? FromArray4(type.items) : IsCyclic(type) ? FromCyclic4(type.$defs, type.$ref) : IsIntersect(type) ? FromIntersect4(type.allOf) : IsObject2(type) ?
|
|
204471
|
+
return IsArray2(type) ? FromArray4(type.items) : IsCyclic(type) ? FromCyclic4(type.$defs, type.$ref) : IsDependent(type) ? FromDependent4(type.if, type.then, type.else) : IsIntersect(type) ? FromIntersect4(type.allOf) : IsObject2(type) ? FromObject7(type.properties) : IsTuple(type) ? FromTuple4(type.items) : IsUnion(type) ? FromUnion7(type.anyOf) : type;
|
|
204255
204472
|
}
|
|
204256
204473
|
|
|
204257
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204474
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/readonly_object/instantiate.mjs
|
|
204258
204475
|
function ReadonlyObjectAction(type, options) {
|
|
204259
204476
|
const result = CanInstantiate([type]) ? exports_memory.Update(FromType17(type), {}, options) : ReadonlyObjectDeferred(type);
|
|
204260
204477
|
return result;
|
|
@@ -204264,12 +204481,12 @@ function ReadonlyObjectInstantiate(context, state, type, options) {
|
|
|
204264
204481
|
return ReadonlyObjectAction(instantiatedType, options);
|
|
204265
204482
|
}
|
|
204266
204483
|
|
|
204267
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204484
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/ref/instantiate.mjs
|
|
204268
204485
|
function RefInstantiate(context, state, type, ref2) {
|
|
204269
|
-
return ref2
|
|
204486
|
+
return state.visited.includes(ref2) ? type : (ref2 in context) ? InstantiateType(context, State(state["callstack"], [...state["visited"], ref2]), context[ref2]) : type;
|
|
204270
204487
|
}
|
|
204271
204488
|
|
|
204272
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204489
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/required/from_cyclic.mjs
|
|
204273
204490
|
function FromCyclic5(defs, ref2) {
|
|
204274
204491
|
const target2 = CyclicTarget(defs, ref2);
|
|
204275
204492
|
const partial2 = FromType18(target2);
|
|
@@ -204277,33 +204494,41 @@ function FromCyclic5(defs, ref2) {
|
|
|
204277
204494
|
return result;
|
|
204278
204495
|
}
|
|
204279
204496
|
|
|
204280
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204497
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/required/from_dependent.mjs
|
|
204498
|
+
function FromDependent5(if_, then_, else_) {
|
|
204499
|
+
const evaluated = EvaluateDependent(if_, then_, else_);
|
|
204500
|
+
const result = FromType18(evaluated);
|
|
204501
|
+
return result;
|
|
204502
|
+
}
|
|
204503
|
+
|
|
204504
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/required/from_intersect.mjs
|
|
204281
204505
|
function FromIntersect5(types2) {
|
|
204282
|
-
const
|
|
204283
|
-
|
|
204506
|
+
const evaluated = EvaluateIntersect(types2);
|
|
204507
|
+
const result = FromType18(evaluated);
|
|
204508
|
+
return result;
|
|
204284
204509
|
}
|
|
204285
204510
|
|
|
204286
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204511
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/required/from_union.mjs
|
|
204287
204512
|
function FromUnion8(types2) {
|
|
204288
204513
|
const result = types2.map((type) => FromType18(type));
|
|
204289
204514
|
return Union(result);
|
|
204290
204515
|
}
|
|
204291
204516
|
|
|
204292
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204293
|
-
function
|
|
204517
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/required/from_object.mjs
|
|
204518
|
+
function FromObject8(properties2) {
|
|
204294
204519
|
const mapped = exports_guard.Keys(properties2).reduce((result2, left) => {
|
|
204295
|
-
return { ...result2, [left]:
|
|
204520
|
+
return { ...result2, [left]: RemoveOptional(properties2[left]) };
|
|
204296
204521
|
}, {});
|
|
204297
204522
|
const result = _Object_(mapped);
|
|
204298
204523
|
return result;
|
|
204299
204524
|
}
|
|
204300
204525
|
|
|
204301
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204526
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/required/from_type.mjs
|
|
204302
204527
|
function FromType18(type) {
|
|
204303
|
-
return IsCyclic(type) ? FromCyclic5(type.$defs, type.$ref) : IsIntersect(type) ? FromIntersect5(type.allOf) : IsUnion(type) ? FromUnion8(type.anyOf) : IsObject2(type) ?
|
|
204528
|
+
return IsCyclic(type) ? FromCyclic5(type.$defs, type.$ref) : IsDependent(type) ? FromDependent5(type.if, type.then, type.else) : IsIntersect(type) ? FromIntersect5(type.allOf) : IsUnion(type) ? FromUnion8(type.anyOf) : IsObject2(type) ? FromObject8(type.properties) : _Object_({});
|
|
204304
204529
|
}
|
|
204305
204530
|
|
|
204306
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204531
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/required.mjs
|
|
204307
204532
|
function RequiredDeferred(type, options = {}) {
|
|
204308
204533
|
return Deferred("Required", [type], options);
|
|
204309
204534
|
}
|
|
@@ -204311,7 +204536,7 @@ function Required(type, options = {}) {
|
|
|
204311
204536
|
return RequiredAction(type, options);
|
|
204312
204537
|
}
|
|
204313
204538
|
|
|
204314
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204539
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/required/instantiate.mjs
|
|
204315
204540
|
function RequiredAction(type, options) {
|
|
204316
204541
|
const result = CanInstantiate([type]) ? exports_memory.Update(FromType18(type), {}, options) : RequiredDeferred(type, options);
|
|
204317
204542
|
return result;
|
|
@@ -204321,7 +204546,7 @@ function RequiredInstantiate(context, state, type, options) {
|
|
|
204321
204546
|
return RequiredAction(instaniatedType, options);
|
|
204322
204547
|
}
|
|
204323
204548
|
|
|
204324
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204549
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/return_type.mjs
|
|
204325
204550
|
function ReturnTypeDeferred(type, options = {}) {
|
|
204326
204551
|
return Deferred("ReturnType", [type], options);
|
|
204327
204552
|
}
|
|
@@ -204329,7 +204554,7 @@ function ReturnType(type, options = {}) {
|
|
|
204329
204554
|
return ReturnTypeAction(type, options);
|
|
204330
204555
|
}
|
|
204331
204556
|
|
|
204332
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204557
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/return_type/instantiate.mjs
|
|
204333
204558
|
function ReturnTypeOperation(type) {
|
|
204334
204559
|
return IsFunction2(type) ? type["returnType"] : Never();
|
|
204335
204560
|
}
|
|
@@ -204342,7 +204567,25 @@ function ReturnTypeInstantiate(context, state, type, options = {}) {
|
|
|
204342
204567
|
return ReturnTypeAction(instantiatedType, options);
|
|
204343
204568
|
}
|
|
204344
204569
|
|
|
204345
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204570
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/with.mjs
|
|
204571
|
+
function WithDeferred(type, options) {
|
|
204572
|
+
return Deferred("With", [type, options], {});
|
|
204573
|
+
}
|
|
204574
|
+
function With2(type, options) {
|
|
204575
|
+
return WithAction(type, options);
|
|
204576
|
+
}
|
|
204577
|
+
|
|
204578
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/with/instantiate.mjs
|
|
204579
|
+
function WithAction(type, options) {
|
|
204580
|
+
const result = CanInstantiate([type]) ? exports_memory.Update(type, {}, options) : WithDeferred(type, options);
|
|
204581
|
+
return result;
|
|
204582
|
+
}
|
|
204583
|
+
function WithInstantiate(context, state, type, options) {
|
|
204584
|
+
const instaniatedType = InstantiateType(context, state, type);
|
|
204585
|
+
return WithAction(instaniatedType, options);
|
|
204586
|
+
}
|
|
204587
|
+
|
|
204588
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/rest/spread.mjs
|
|
204346
204589
|
function SpreadElement(type) {
|
|
204347
204590
|
const result = IsRest(type) ? IsTuple(type.items) ? RestSpread(type.items.items) : IsInfer(type.items) ? [type] : IsRef(type.items) ? [type] : [Never()] : [type];
|
|
204348
204591
|
return result;
|
|
@@ -204353,18 +204596,12 @@ function RestSpread(types2) {
|
|
|
204353
204596
|
}, []);
|
|
204354
204597
|
return result;
|
|
204355
204598
|
}
|
|
204356
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204357
|
-
function
|
|
204358
|
-
return
|
|
204359
|
-
}
|
|
204360
|
-
function ModifierActions(type, readonly2, optional2) {
|
|
204361
|
-
return IsReadonlyRemoveAction(type) ? ModifierActions(type.type, "remove", optional2) : IsOptionalRemoveAction(type) ? ModifierActions(type.type, readonly2, "remove") : IsReadonlyAddAction(type) ? ModifierActions(type.type, "add", optional2) : IsOptionalAddAction(type) ? ModifierActions(type.type, readonly2, "add") : [type, readonly2, optional2];
|
|
204362
|
-
}
|
|
204363
|
-
function ApplyReadonly2(action, type) {
|
|
204364
|
-
return exports_guard.IsEqual(action, "remove") ? ReadonlyRemove(type) : exports_guard.IsEqual(action, "add") ? ReadonlyAdd(type) : type;
|
|
204599
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/instantiate.mjs
|
|
204600
|
+
function State(callstack, visited) {
|
|
204601
|
+
return { callstack, visited };
|
|
204365
204602
|
}
|
|
204366
|
-
function
|
|
204367
|
-
return exports_guard.
|
|
204603
|
+
function CanInstantiate(types2) {
|
|
204604
|
+
return exports_guard.ShiftLeft(types2, (left, right) => IsRef(left) ? false : CanInstantiate(right), () => true);
|
|
204368
204605
|
}
|
|
204369
204606
|
function InstantiateProperties(context, state, properties2) {
|
|
204370
204607
|
return exports_guard.Keys(properties2).reduce((result, key) => {
|
|
@@ -204379,70 +204616,77 @@ function InstantiateElements(context, state, types2) {
|
|
|
204379
204616
|
function InstantiateTypes(context, state, types2) {
|
|
204380
204617
|
return types2.map((type) => InstantiateType(context, state, type));
|
|
204381
204618
|
}
|
|
204619
|
+
function WithModifiers(type, instantiatedType) {
|
|
204620
|
+
const withOptional = IsOptional(type) ? AddOptionalAction(instantiatedType, {}) : instantiatedType;
|
|
204621
|
+
const withReadonly = IsReadonly(type) ? AddReadonlyAction(withOptional, {}) : withOptional;
|
|
204622
|
+
const withImmutable = IsImmutable(type) ? AddImmutableAction(withReadonly, {}) : withReadonly;
|
|
204623
|
+
return withImmutable;
|
|
204624
|
+
}
|
|
204382
204625
|
function InstantiateDeferred(context, state, action, parameters, options) {
|
|
204383
|
-
return exports_guard.IsEqual(action, "
|
|
204384
|
-
}
|
|
204385
|
-
function
|
|
204386
|
-
const
|
|
204387
|
-
const
|
|
204388
|
-
const type = IsBase(modifiers[0]) ? modifiers[0].Clone() : modifiers[0];
|
|
204389
|
-
const instantiated = IsRef(type) ? RefInstantiate(context, state, type, type.$ref) : IsArray2(type) ? _Array_(InstantiateType(context, state, type.items), ArrayOptions(type)) : IsAsyncIterator2(type) ? AsyncIterator(InstantiateType(context, state, type.iteratorItems), AsyncIteratorOptions(type)) : IsCall(type) ? CallInstantiate(context, state, type.target, type.arguments) : IsConstructor2(type) ? Constructor(InstantiateTypes(context, state, type.parameters), InstantiateType(context, state, type.instanceType), ConstructorOptions(type)) : IsDeferred(type) ? InstantiateDeferred(context, state, type.action, type.parameters, type.options) : IsFunction2(type) ? _Function_(InstantiateTypes(context, state, type.parameters), InstantiateType(context, state, type.returnType), FunctionOptions(type)) : IsIntersect(type) ? Intersect(InstantiateTypes(context, state, type.allOf), IntersectOptions(type)) : IsIterator2(type) ? Iterator(InstantiateType(context, state, type.iteratorItems), IteratorOptions(type)) : IsObject2(type) ? _Object_(InstantiateProperties(context, state, type.properties), ObjectOptions(type)) : IsPromise(type) ? _Promise_(InstantiateType(context, state, type.item), PromiseOptions(type)) : IsRecord(type) ? RecordFromPattern(RecordPattern(type), InstantiateType(context, state, RecordValue(type))) : IsRest(type) ? Rest(InstantiateType(context, state, type.items)) : IsTuple(type) ? Tuple(InstantiateElements(context, state, type.items), TupleOptions(type)) : IsUnion(type) ? Union(InstantiateTypes(context, state, type.anyOf), UnionOptions(type)) : type;
|
|
204390
|
-
const withImmutable = immutable ? Immutable(instantiated) : instantiated;
|
|
204391
|
-
const withModifiers = ApplyReadonly2(modifiers[1], ApplyOptional2(modifiers[2], withImmutable));
|
|
204626
|
+
return exports_guard.IsEqual(action, "AddImmutable") ? AddImmutableInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "RemoveImmutable") ? RemoveImmutableInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "AddReadonly") ? AddReadonlyInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "RemoveReadonly") ? RemoveReadonlyInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "AddOptional") ? AddOptionalInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "RemoveOptional") ? RemoveOptionalInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Capitalize") ? CapitalizeInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Conditional") ? ConditionalInstantiate(context, state, parameters[0], parameters[1], parameters[2], parameters[3], options) : exports_guard.IsEqual(action, "ConstructorParameters") ? ConstructorParametersInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Evaluate") ? EvaluateInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Exclude") ? ExcludeInstantiate(context, state, parameters[0], parameters[1], options) : exports_guard.IsEqual(action, "Extract") ? ExtractInstantiate(context, state, parameters[0], parameters[1], options) : exports_guard.IsEqual(action, "Index") ? IndexInstantiate(context, state, parameters[0], parameters[1], options) : exports_guard.IsEqual(action, "InstanceType") ? InstanceTypeInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Interface") ? InterfaceInstantiate(context, state, parameters[0], parameters[1], options) : exports_guard.IsEqual(action, "KeyOf") ? KeyOfInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Lowercase") ? LowercaseInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Mapped") ? MappedInstantiate(context, state, parameters[0], parameters[1], parameters[2], parameters[3], options) : exports_guard.IsEqual(action, "Module") ? ModuleInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "NonNullable") ? NonNullableInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Pick") ? PickInstantiate(context, state, parameters[0], parameters[1], options) : exports_guard.IsEqual(action, "Parameters") ? ParametersInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Partial") ? PartialInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Omit") ? OmitInstantiate(context, state, parameters[0], parameters[1], options) : exports_guard.IsEqual(action, "ReadonlyObject") ? ReadonlyObjectInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Record") ? RecordInstantiate(context, state, parameters[0], parameters[1], options) : exports_guard.IsEqual(action, "Required") ? RequiredInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "ReturnType") ? ReturnTypeInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "TemplateLiteral") ? TemplateLiteralInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Uncapitalize") ? UncapitalizeInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "Uppercase") ? UppercaseInstantiate(context, state, parameters[0], options) : exports_guard.IsEqual(action, "With") ? WithInstantiate(context, state, parameters[0], parameters[1]) : Deferred(action, parameters, options);
|
|
204627
|
+
}
|
|
204628
|
+
function InstantiateImmediate(context, state, type) {
|
|
204629
|
+
const instantiatedType = IsRef(type) ? RefInstantiate(context, state, type, type.$ref) : IsArray2(type) ? _Array_(InstantiateType(context, state, type.items), ArrayOptions(type)) : IsCall(type) ? CallInstantiate(context, state, type.target, type.arguments) : IsConstructor2(type) ? Constructor(InstantiateTypes(context, state, type.parameters), InstantiateType(context, state, type.instanceType), ConstructorOptions(type)) : IsFunction2(type) ? _Function_(InstantiateTypes(context, state, type.parameters), InstantiateType(context, state, type.returnType), FunctionOptions(type)) : IsDependent(type) ? Dependent(InstantiateType(context, state, type.if), InstantiateType(context, state, type.then), InstantiateType(context, state, type.else), DependentOptions(type)) : IsIntersect(type) ? Intersect(InstantiateTypes(context, state, type.allOf), IntersectOptions(type)) : IsObject2(type) ? _Object_(InstantiateProperties(context, state, type.properties), ObjectOptions(type)) : IsRecord(type) ? RecordFromPattern(RecordPattern(type), InstantiateType(context, state, RecordValue(type))) : IsRest(type) ? Rest(InstantiateType(context, state, type.items)) : IsTuple(type) ? Tuple(InstantiateElements(context, state, type.items), TupleOptions(type)) : IsUnion(type) ? Union(InstantiateTypes(context, state, type.anyOf), UnionOptions(type)) : type;
|
|
204630
|
+
const withModifiers = WithModifiers(type, instantiatedType);
|
|
204392
204631
|
return withModifiers;
|
|
204393
204632
|
}
|
|
204633
|
+
function InstantiateType(context, state, type) {
|
|
204634
|
+
const result = IsDeferred(type) ? InstantiateDeferred(context, state, type.action, type.parameters, type.options) : InstantiateImmediate(context, state, type);
|
|
204635
|
+
return result;
|
|
204636
|
+
}
|
|
204394
204637
|
function Instantiate(context, type) {
|
|
204395
|
-
return InstantiateType(context,
|
|
204638
|
+
return InstantiateType(context, State([], []), type);
|
|
204396
204639
|
}
|
|
204397
204640
|
|
|
204398
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204399
|
-
function
|
|
204400
|
-
return
|
|
204641
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/engine/immutable/instantiate_add.mjs
|
|
204642
|
+
function AddImmutableOperation(type) {
|
|
204643
|
+
return exports_memory.Update(type, { "~immutable": true }, {});
|
|
204401
204644
|
}
|
|
204402
|
-
function
|
|
204403
|
-
const result =
|
|
204645
|
+
function AddImmutableAction(type, options) {
|
|
204646
|
+
const result = exports_memory.Update(AddImmutableOperation(type), {}, options);
|
|
204404
204647
|
return result;
|
|
204405
204648
|
}
|
|
204406
|
-
function
|
|
204649
|
+
function AddImmutableInstantiate(context, state, type, options) {
|
|
204407
204650
|
const instantiatedType = InstantiateType(context, state, type);
|
|
204408
|
-
return
|
|
204651
|
+
return AddImmutableAction(instantiatedType, options);
|
|
204409
204652
|
}
|
|
204410
204653
|
|
|
204411
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204412
|
-
function
|
|
204413
|
-
return Deferred("
|
|
204654
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/_add_immutable.mjs
|
|
204655
|
+
function AddImmutableDeferred(type, options = {}) {
|
|
204656
|
+
return Deferred("AddImmutable", [type], options);
|
|
204414
204657
|
}
|
|
204415
|
-
function
|
|
204416
|
-
return
|
|
204658
|
+
function AddImmutable(type, options = {}) {
|
|
204659
|
+
return AddImmutableAction(type, options);
|
|
204417
204660
|
}
|
|
204418
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204661
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/evaluate.mjs
|
|
204419
204662
|
function EvaluateDeferred(type, options = {}) {
|
|
204420
204663
|
return Deferred("Evaluate", [type], options);
|
|
204421
204664
|
}
|
|
204422
204665
|
function Evaluate(type, options = {}) {
|
|
204423
204666
|
return EvaluateAction(type, options);
|
|
204424
204667
|
}
|
|
204425
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204426
|
-
function ModuleDeferred(
|
|
204427
|
-
return Deferred("Module", [
|
|
204668
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/action/module.mjs
|
|
204669
|
+
function ModuleDeferred(declarations, options = {}) {
|
|
204670
|
+
return Deferred("Module", [declarations], options);
|
|
204428
204671
|
}
|
|
204429
|
-
function Module2(
|
|
204430
|
-
return
|
|
204672
|
+
function Module2(declarations, options = {}) {
|
|
204673
|
+
return ModuleInstantiate({}, State([], []), declarations, options);
|
|
204431
204674
|
}
|
|
204432
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204675
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/type/script/script.mjs
|
|
204433
204676
|
function Script2(...args) {
|
|
204434
|
-
const [context, input,
|
|
204435
|
-
2: (script,
|
|
204436
|
-
3: (context2, script,
|
|
204677
|
+
const [context, input, options] = exports_arguments.Match(args, {
|
|
204678
|
+
2: (script, options2) => exports_guard.IsString(script) ? [{}, script, options2] : [script, options2, {}],
|
|
204679
|
+
3: (context2, script, options2) => [context2, script, options2],
|
|
204437
204680
|
1: (script) => [{}, script, {}]
|
|
204438
204681
|
});
|
|
204439
204682
|
const result = Script(input);
|
|
204440
|
-
const parsed = exports_guard.IsArray(result) && exports_guard.IsEqual(result.length, 2) ? InstantiateType(context,
|
|
204441
|
-
return exports_memory.Update(parsed, {},
|
|
204683
|
+
const parsed = exports_guard.IsArray(result) && exports_guard.IsEqual(result.length, 2) ? InstantiateType(context, State([], []), result[0]) : Never();
|
|
204684
|
+
return exports_memory.Update(parsed, {}, options);
|
|
204442
204685
|
}
|
|
204443
|
-
// ../../node_modules/.bun/typebox@1.1
|
|
204686
|
+
// ../../node_modules/.bun/typebox@1.3.1/node_modules/typebox/build/typebox.mjs
|
|
204444
204687
|
var exports_typebox = {};
|
|
204445
204688
|
__export(exports_typebox, {
|
|
204689
|
+
With: () => With2,
|
|
204446
204690
|
Void: () => Void,
|
|
204447
204691
|
Uppercase: () => Uppercase,
|
|
204448
204692
|
Unsafe: () => Unsafe,
|
|
@@ -204465,15 +204709,12 @@ __export(exports_typebox, {
|
|
|
204465
204709
|
RecordPattern: () => RecordPattern,
|
|
204466
204710
|
RecordKey: () => RecordKey,
|
|
204467
204711
|
Record: () => Record,
|
|
204468
|
-
ReadonlyType: () => ReadonlyType,
|
|
204469
204712
|
ReadonlyObject: () => ReadonlyObject,
|
|
204470
204713
|
Readonly: () => Readonly,
|
|
204471
|
-
Promise: () => _Promise_,
|
|
204472
204714
|
Pick: () => Pick,
|
|
204473
204715
|
Partial: () => Partial,
|
|
204474
204716
|
Parameters: () => Parameters,
|
|
204475
204717
|
Parameter: () => Parameter,
|
|
204476
|
-
Options: () => Options2,
|
|
204477
204718
|
Optional: () => Optional,
|
|
204478
204719
|
Omit: () => Omit,
|
|
204479
204720
|
Object: () => _Object_,
|
|
@@ -204482,11 +204723,10 @@ __export(exports_typebox, {
|
|
|
204482
204723
|
NonNullable: () => NonNullable,
|
|
204483
204724
|
Never: () => Never,
|
|
204484
204725
|
Module: () => Module2,
|
|
204485
|
-
Mapped: () =>
|
|
204726
|
+
Mapped: () => Mapped,
|
|
204486
204727
|
Lowercase: () => Lowercase,
|
|
204487
204728
|
Literal: () => Literal,
|
|
204488
204729
|
KeyOf: () => KeyOf2,
|
|
204489
|
-
Iterator: () => Iterator,
|
|
204490
204730
|
IsVoid: () => IsVoid,
|
|
204491
204731
|
IsUnsafe: () => IsUnsafe,
|
|
204492
204732
|
IsUnknown: () => IsUnknown,
|
|
@@ -204496,23 +204736,21 @@ __export(exports_typebox, {
|
|
|
204496
204736
|
IsThis: () => IsThis,
|
|
204497
204737
|
IsTemplateLiteral: () => IsTemplateLiteral,
|
|
204498
204738
|
IsSymbol: () => IsSymbol2,
|
|
204499
|
-
IsString: () =>
|
|
204739
|
+
IsString: () => IsString3,
|
|
204500
204740
|
IsSchema: () => IsSchema,
|
|
204501
204741
|
IsRest: () => IsRest,
|
|
204502
204742
|
IsRefine: () => IsRefine,
|
|
204503
204743
|
IsRef: () => IsRef,
|
|
204504
204744
|
IsRecord: () => IsRecord,
|
|
204505
204745
|
IsReadonly: () => IsReadonly,
|
|
204506
|
-
IsPromise: () => IsPromise,
|
|
204507
204746
|
IsParameter: () => IsParameter,
|
|
204508
204747
|
IsOptional: () => IsOptional,
|
|
204509
204748
|
IsObject: () => IsObject2,
|
|
204510
|
-
IsNumber: () =>
|
|
204749
|
+
IsNumber: () => IsNumber3,
|
|
204511
204750
|
IsNull: () => IsNull2,
|
|
204512
204751
|
IsNever: () => IsNever,
|
|
204513
204752
|
IsLiteral: () => IsLiteral,
|
|
204514
204753
|
IsKind: () => IsKind,
|
|
204515
|
-
IsIterator: () => IsIterator2,
|
|
204516
204754
|
IsIntersect: () => IsIntersect,
|
|
204517
204755
|
IsInteger: () => IsInteger2,
|
|
204518
204756
|
IsInfer: () => IsInfer,
|
|
@@ -204521,14 +204759,13 @@ __export(exports_typebox, {
|
|
|
204521
204759
|
IsGeneric: () => IsGeneric,
|
|
204522
204760
|
IsFunction: () => IsFunction2,
|
|
204523
204761
|
IsEnum: () => IsEnum,
|
|
204762
|
+
IsDependent: () => IsDependent,
|
|
204524
204763
|
IsCyclic: () => IsCyclic,
|
|
204525
204764
|
IsConstructor: () => IsConstructor2,
|
|
204526
204765
|
IsCodec: () => IsCodec,
|
|
204527
204766
|
IsCall: () => IsCall,
|
|
204528
|
-
IsBoolean: () =>
|
|
204767
|
+
IsBoolean: () => IsBoolean3,
|
|
204529
204768
|
IsBigInt: () => IsBigInt2,
|
|
204530
|
-
IsBase: () => IsBase,
|
|
204531
|
-
IsAsyncIterator: () => IsAsyncIterator2,
|
|
204532
204769
|
IsArray: () => IsArray2,
|
|
204533
204770
|
IsAny: () => IsAny,
|
|
204534
204771
|
Intersect: () => Intersect,
|
|
@@ -204544,12 +204781,13 @@ __export(exports_typebox, {
|
|
|
204544
204781
|
Function: () => _Function_,
|
|
204545
204782
|
Extract: () => Extract,
|
|
204546
204783
|
ExtendsResult: () => exports_result,
|
|
204547
|
-
Extends: () =>
|
|
204784
|
+
Extends: () => Extends,
|
|
204548
204785
|
Exclude: () => Exclude,
|
|
204549
204786
|
Evaluate: () => Evaluate,
|
|
204550
204787
|
Enum: () => Enum,
|
|
204551
204788
|
EncodeBuilder: () => EncodeBuilder,
|
|
204552
204789
|
Encode: () => Encode,
|
|
204790
|
+
Dependent: () => Dependent,
|
|
204553
204791
|
DecodeBuilder: () => DecodeBuilder,
|
|
204554
204792
|
Decode: () => Decode,
|
|
204555
204793
|
Cyclic: () => Cyclic,
|
|
@@ -204561,9 +204799,6 @@ __export(exports_typebox, {
|
|
|
204561
204799
|
Call: () => Call,
|
|
204562
204800
|
Boolean: () => Boolean2,
|
|
204563
204801
|
BigInt: () => BigInt2,
|
|
204564
|
-
Base: () => Base,
|
|
204565
|
-
Awaited: () => Awaited,
|
|
204566
|
-
AsyncIterator: () => AsyncIterator,
|
|
204567
204802
|
Array: () => _Array_,
|
|
204568
204803
|
Any: () => Any
|
|
204569
204804
|
});
|