@cortexkit/aft-pi 0.41.0 → 0.42.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -13020,6 +13020,7 @@ class BinaryBridge {
13020
13020
  }
13021
13021
  // ../aft-bridge/dist/callgraph-format.js
13022
13022
  import { homedir as homedir3 } from "node:os";
13023
+ var UNRESOLVED_SUMMARY_NAME_LIMIT = 10;
13023
13024
  var PLAIN_CALLGRAPH_THEME = {
13024
13025
  fg: (_role, text) => text
13025
13026
  };
@@ -13055,7 +13056,26 @@ function treeLine(depth, text) {
13055
13056
  function nameMatchEdgeMarker(record, theme) {
13056
13057
  return asString(record.resolved_by) === "name_match" ? ` ${theme.fg("warning", "~")}` : "";
13057
13058
  }
13058
- function renderCallTreeNode(node, depth, lines, theme) {
13059
+ function isUnresolvedLeaf(node) {
13060
+ return node.resolved === false && asRecords(node.children).length === 0;
13061
+ }
13062
+ function unresolvedSummaryText(nodes) {
13063
+ const distinctNames = [];
13064
+ const seen = new Set;
13065
+ for (const node of nodes) {
13066
+ const name = asString(node.name) ?? "(unknown)";
13067
+ if (seen.has(name))
13068
+ continue;
13069
+ seen.add(name);
13070
+ distinctNames.push(name);
13071
+ }
13072
+ const displayed = distinctNames.slice(0, UNRESOLVED_SUMMARY_NAME_LIMIT);
13073
+ const hidden = distinctNames.length - displayed.length;
13074
+ const names = hidden > 0 ? `${displayed.join(", ")}, … (+${hidden} more)` : displayed.join(", ");
13075
+ const noun = nodes.length === 1 ? "call" : "calls";
13076
+ return `+ ${nodes.length} unresolved external ${noun}: ${names}`;
13077
+ }
13078
+ function renderCallTreeNode(node, depth, lines, theme, options) {
13059
13079
  const name = asString(node.name) ?? "(unknown)";
13060
13080
  const file = shortenPath(asString(node.file) ?? "(unknown file)");
13061
13081
  const line = asNumber(node.line);
@@ -13063,8 +13083,31 @@ function renderCallTreeNode(node, depth, lines, theme) {
13063
13083
  const nameMatch = nameMatchEdgeMarker(node, theme);
13064
13084
  const location = line !== undefined ? `[${file}:${line}]` : `[${file}]`;
13065
13085
  lines.push(treeLine(depth, `${name} ${location}${unresolved}${nameMatch}`));
13066
- asRecords(node.children).forEach((child) => {
13067
- renderCallTreeNode(child, depth + 1, lines, theme);
13086
+ const children = asRecords(node.children);
13087
+ if (options.includeUnresolved) {
13088
+ children.forEach((child) => {
13089
+ renderCallTreeNode(child, depth + 1, lines, theme, options);
13090
+ });
13091
+ return;
13092
+ }
13093
+ const unresolvedLeaves = children.filter(isUnresolvedLeaf);
13094
+ if (unresolvedLeaves.length === 0) {
13095
+ children.forEach((child) => {
13096
+ renderCallTreeNode(child, depth + 1, lines, theme, options);
13097
+ });
13098
+ return;
13099
+ }
13100
+ const unresolvedLeafSet = new Set(unresolvedLeaves);
13101
+ let summaryInserted = false;
13102
+ children.forEach((child) => {
13103
+ if (unresolvedLeafSet.has(child)) {
13104
+ if (!summaryInserted) {
13105
+ lines.push(treeLine(depth + 1, theme.fg("warning", unresolvedSummaryText(unresolvedLeaves))));
13106
+ summaryInserted = true;
13107
+ }
13108
+ return;
13109
+ }
13110
+ renderCallTreeNode(child, depth + 1, lines, theme, options);
13068
13111
  });
13069
13112
  }
13070
13113
  function depthWarning(response, theme, depthField = "depth_limited", truncatedField = "truncated") {
@@ -13075,6 +13118,11 @@ function depthWarning(response, theme, depthField = "depth_limited", truncatedFi
13075
13118
  const detail = truncated > 0 ? `, ${truncated} truncated` : "";
13076
13119
  return theme.fg("warning", `(depth limited${detail})`);
13077
13120
  }
13121
+ function hubSummaryLine(response, theme) {
13122
+ const summary = asRecord(response.hub_summary);
13123
+ const message = summary ? asString(summary.message) : undefined;
13124
+ return message ? theme.fg("warning", message) : undefined;
13125
+ }
13078
13126
  function renderTracePath(path2, index, lines, theme) {
13079
13127
  lines.push(`Path ${index + 1}`);
13080
13128
  asRecords(path2.hops).forEach((hop, hopIndex) => {
@@ -13111,13 +13159,13 @@ function renderCallersGroupLines(group, theme) {
13111
13159
  }
13112
13160
  return lines;
13113
13161
  }
13114
- function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME) {
13162
+ function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME, options = {}) {
13115
13163
  const record = asRecord(response);
13116
13164
  if (!record)
13117
13165
  return [theme.fg("muted", "No navigation result.")];
13118
13166
  if (op === "call_tree") {
13119
13167
  const lines = [];
13120
- renderCallTreeNode(record, 0, lines, theme);
13168
+ renderCallTreeNode(record, 0, lines, theme, options);
13121
13169
  const warning = depthWarning(record, theme);
13122
13170
  if (warning)
13123
13171
  lines.push(warning);
@@ -13126,6 +13174,7 @@ function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME) {
13126
13174
  if (op === "callers") {
13127
13175
  const groups = asRecords(record.callers);
13128
13176
  const warning = depthWarning(record, theme);
13177
+ const hubSummary = hubSummaryLine(record, theme);
13129
13178
  const total = asNumber(record.total_callers) ?? 0;
13130
13179
  const sections2 = [
13131
13180
  joinNonEmpty([
@@ -13134,6 +13183,8 @@ function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME) {
13134
13183
  warning
13135
13184
  ])
13136
13185
  ];
13186
+ if (hubSummary)
13187
+ sections2.push(hubSummary);
13137
13188
  groups.forEach((group) => {
13138
13189
  sections2.push(renderCallersGroupLines(group, theme).join(`
13139
13190
  `));
@@ -13161,6 +13212,7 @@ function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME) {
13161
13212
  if (op === "trace_to") {
13162
13213
  const paths = asRecords(record.paths);
13163
13214
  const warning = depthWarning(record, theme, "max_depth_reached", "truncated_paths");
13215
+ const hubSummary = hubSummaryLine(record, theme);
13164
13216
  const totalPaths = asNumber(record.total_paths) ?? paths.length;
13165
13217
  const entryPoints = asNumber(record.entry_points_found) ?? 0;
13166
13218
  const sections2 = [
@@ -13170,6 +13222,8 @@ function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME) {
13170
13222
  warning
13171
13223
  ])
13172
13224
  ];
13225
+ if (hubSummary)
13226
+ sections2.push(hubSummary);
13173
13227
  if (paths.length === 0)
13174
13228
  sections2.push(theme.fg("muted", "No entry paths found."));
13175
13229
  paths.forEach((path2, index) => {
@@ -13183,6 +13237,7 @@ function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME) {
13183
13237
  if (op === "impact") {
13184
13238
  const callers = asRecords(record.callers);
13185
13239
  const warning = depthWarning(record, theme);
13240
+ const hubSummary = hubSummaryLine(record, theme);
13186
13241
  const totalAffected = asNumber(record.total_affected) ?? callers.length;
13187
13242
  const affectedFiles = asNumber(record.affected_files) ?? 0;
13188
13243
  const sections2 = [
@@ -13192,6 +13247,8 @@ function formatCallgraphSections(op, response, theme = PLAIN_CALLGRAPH_THEME) {
13192
13247
  warning
13193
13248
  ])
13194
13249
  ];
13250
+ if (hubSummary)
13251
+ sections2.push(hubSummary);
13195
13252
  if (callers.length === 0)
13196
13253
  sections2.push(theme.fg("muted", "No impacted callers found."));
13197
13254
  callers.forEach((caller) => {
@@ -15560,6 +15617,9 @@ function formatReadFooter(agentSpecifiedRange, data, options) {
15560
15617
  (Showing lines ${startLine}-${endLine} of ${totalLines}. Use ${options.rangeHint} to read other sections.)`;
15561
15618
  }
15562
15619
  // ../aft-bridge/dist/zoom-format.js
15620
+ function formatExtraCallSites(ref) {
15621
+ return Number.isInteger(ref.extra_count) && (ref.extra_count ?? 0) > 0 ? ` +${ref.extra_count}` : "";
15622
+ }
15563
15623
  function formatZoomText(targetLabel, response) {
15564
15624
  const range = response.range;
15565
15625
  const startLine = range?.start_line ?? 1;
@@ -15597,13 +15657,13 @@ function formatZoomText(targetLabel, response) {
15597
15657
  if (callsOut.length > 0) {
15598
15658
  out.push("", "──── calls_out");
15599
15659
  for (const ref of callsOut) {
15600
- out.push(` ${ref.name} (line ${ref.line})`);
15660
+ out.push(` ${ref.name} (line ${ref.line})${formatExtraCallSites(ref)}`);
15601
15661
  }
15602
15662
  }
15603
15663
  if (calledBy.length > 0) {
15604
15664
  out.push("", "──── called_by");
15605
15665
  for (const ref of calledBy) {
15606
- out.push(` ${ref.name} (line ${ref.line})`);
15666
+ out.push(` ${ref.name} (line ${ref.line})${formatExtraCallSites(ref)}`);
15607
15667
  }
15608
15668
  }
15609
15669
  return out.join(`
@@ -16304,7 +16364,7 @@ import {
16304
16364
  // package.json
16305
16365
  var package_default = {
16306
16366
  name: "@cortexkit/aft-pi",
16307
- version: "0.41.0",
16367
+ version: "0.42.0",
16308
16368
  type: "module",
16309
16369
  description: "Pi coding agent extension for Agent File Tools (AFT) — tree-sitter and LSP-powered code analysis",
16310
16370
  main: "dist/index.js",
@@ -16327,25 +16387,25 @@ var package_default = {
16327
16387
  "test:unit": "bun test src/__tests__ --path-ignore-patterns 'src/__tests__/e2e/**'"
16328
16388
  },
16329
16389
  dependencies: {
16330
- "@cortexkit/aft-bridge": "0.41.0",
16390
+ "@cortexkit/aft-bridge": "0.42.0",
16331
16391
  "@xterm/headless": "^5.5.0",
16332
16392
  "comment-json": "^5.0.0",
16333
16393
  diff: "^8.0.4",
16334
- typebox: "^1.1.24",
16335
- zod: "^4.1.8"
16394
+ typebox: "1.1.38",
16395
+ zod: "^4.4.3"
16336
16396
  },
16337
16397
  optionalDependencies: {
16338
- "@cortexkit/aft-darwin-arm64": "0.41.0",
16339
- "@cortexkit/aft-darwin-x64": "0.41.0",
16340
- "@cortexkit/aft-linux-arm64": "0.41.0",
16341
- "@cortexkit/aft-linux-x64": "0.41.0",
16342
- "@cortexkit/aft-win32-arm64": "0.41.0",
16343
- "@cortexkit/aft-win32-x64": "0.41.0"
16398
+ "@cortexkit/aft-darwin-arm64": "0.42.0",
16399
+ "@cortexkit/aft-darwin-x64": "0.42.0",
16400
+ "@cortexkit/aft-linux-arm64": "0.42.0",
16401
+ "@cortexkit/aft-linux-x64": "0.42.0",
16402
+ "@cortexkit/aft-win32-arm64": "0.42.0",
16403
+ "@cortexkit/aft-win32-x64": "0.42.0"
16344
16404
  },
16345
16405
  devDependencies: {
16346
- "@earendil-works/pi-coding-agent": "*",
16347
- "@earendil-works/pi-ai": "*",
16348
- "@earendil-works/pi-tui": "*",
16406
+ "@earendil-works/pi-coding-agent": "^0.80.2",
16407
+ "@earendil-works/pi-ai": "^0.80.2",
16408
+ "@earendil-works/pi-tui": "^0.80.2",
16349
16409
  "@types/node": "^22.0.0",
16350
16410
  typescript: "^5.8.0"
16351
16411
  },
@@ -16920,7 +16980,7 @@ function registerStatusCommand(pi, ctx) {
16920
16980
  import { existsSync as existsSync7, readFileSync as readFileSync6, renameSync as renameSync5, unlinkSync as unlinkSync5, writeFileSync as writeFileSync4 } from "node:fs";
16921
16981
  var import_comment_json = __toESM(require_src2(), 1);
16922
16982
 
16923
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/external.js
16983
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/external.js
16924
16984
  var exports_external = {};
16925
16985
  __export(exports_external, {
16926
16986
  xor: () => xor,
@@ -17022,6 +17082,7 @@ __export(exports_external, {
17022
17082
  iso: () => exports_iso,
17023
17083
  ipv6: () => ipv62,
17024
17084
  ipv4: () => ipv42,
17085
+ invertCodec: () => invertCodec,
17025
17086
  intersection: () => intersection,
17026
17087
  int64: () => int64,
17027
17088
  int32: () => int32,
@@ -17100,6 +17161,7 @@ __export(exports_external, {
17100
17161
  ZodRealError: () => ZodRealError,
17101
17162
  ZodReadonly: () => ZodReadonly,
17102
17163
  ZodPromise: () => ZodPromise,
17164
+ ZodPreprocess: () => ZodPreprocess,
17103
17165
  ZodPrefault: () => ZodPrefault,
17104
17166
  ZodPipe: () => ZodPipe,
17105
17167
  ZodOptional: () => ZodOptional,
@@ -17161,7 +17223,7 @@ __export(exports_external, {
17161
17223
  $brand: () => $brand
17162
17224
  });
17163
17225
 
17164
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/index.js
17226
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/index.js
17165
17227
  var exports_core2 = {};
17166
17228
  __export(exports_core2, {
17167
17229
  version: () => version,
@@ -17360,6 +17422,7 @@ __export(exports_core2, {
17360
17422
  $ZodRealError: () => $ZodRealError,
17361
17423
  $ZodReadonly: () => $ZodReadonly,
17362
17424
  $ZodPromise: () => $ZodPromise,
17425
+ $ZodPreprocess: () => $ZodPreprocess,
17363
17426
  $ZodPrefault: () => $ZodPrefault,
17364
17427
  $ZodPipe: () => $ZodPipe,
17365
17428
  $ZodOptional: () => $ZodOptional,
@@ -17439,8 +17502,9 @@ __export(exports_core2, {
17439
17502
  $ZodAny: () => $ZodAny
17440
17503
  });
17441
17504
 
17442
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/core.js
17443
- var NEVER = Object.freeze({
17505
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/core.js
17506
+ var _a;
17507
+ var NEVER = /* @__PURE__ */ Object.freeze({
17444
17508
  status: "aborted"
17445
17509
  });
17446
17510
  function $constructor(name, initializer, params) {
@@ -17475,10 +17539,10 @@ function $constructor(name, initializer, params) {
17475
17539
  }
17476
17540
  Object.defineProperty(Definition, "name", { value: name });
17477
17541
  function _(def) {
17478
- var _a;
17542
+ var _a2;
17479
17543
  const inst = params?.Parent ? new Definition : this;
17480
17544
  init(inst, def);
17481
- (_a = inst._zod).deferred ?? (_a.deferred = []);
17545
+ (_a2 = inst._zod).deferred ?? (_a2.deferred = []);
17482
17546
  for (const fn of inst._zod.deferred) {
17483
17547
  fn();
17484
17548
  }
@@ -17509,13 +17573,14 @@ class $ZodEncodeError extends Error {
17509
17573
  this.name = "ZodEncodeError";
17510
17574
  }
17511
17575
  }
17512
- var globalConfig = {};
17576
+ (_a = globalThis).__zod_globalConfig ?? (_a.__zod_globalConfig = {});
17577
+ var globalConfig = globalThis.__zod_globalConfig;
17513
17578
  function config(newConfig) {
17514
17579
  if (newConfig)
17515
17580
  Object.assign(globalConfig, newConfig);
17516
17581
  return globalConfig;
17517
17582
  }
17518
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/util.js
17583
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/util.js
17519
17584
  var exports_util = {};
17520
17585
  __export(exports_util, {
17521
17586
  unwrapMessage: () => unwrapMessage,
@@ -17557,6 +17622,7 @@ __export(exports_util, {
17557
17622
  floatSafeRemainder: () => floatSafeRemainder,
17558
17623
  finalizeIssue: () => finalizeIssue,
17559
17624
  extend: () => extend,
17625
+ explicitlyAborted: () => explicitlyAborted,
17560
17626
  escapeRegex: () => escapeRegex,
17561
17627
  esc: () => esc,
17562
17628
  defineLazy: () => defineLazy,
@@ -17627,21 +17693,14 @@ function cleanRegex(source) {
17627
17693
  return source.slice(start, end);
17628
17694
  }
17629
17695
  function floatSafeRemainder(val, step) {
17630
- const valDecCount = (val.toString().split(".")[1] || "").length;
17631
- const stepString = step.toString();
17632
- let stepDecCount = (stepString.split(".")[1] || "").length;
17633
- if (stepDecCount === 0 && /\d?e-\d?/.test(stepString)) {
17634
- const match = stepString.match(/\d?e-(\d?)/);
17635
- if (match?.[1]) {
17636
- stepDecCount = Number.parseInt(match[1]);
17637
- }
17638
- }
17639
- const decCount = valDecCount > stepDecCount ? valDecCount : stepDecCount;
17640
- const valInt = Number.parseInt(val.toFixed(decCount).replace(".", ""));
17641
- const stepInt = Number.parseInt(step.toFixed(decCount).replace(".", ""));
17642
- return valInt % stepInt / 10 ** decCount;
17696
+ const ratio = val / step;
17697
+ const roundedRatio = Math.round(ratio);
17698
+ const tolerance = Number.EPSILON * Math.max(Math.abs(ratio), 1);
17699
+ if (Math.abs(ratio - roundedRatio) < tolerance)
17700
+ return 0;
17701
+ return ratio - roundedRatio;
17643
17702
  }
17644
- var EVALUATING = Symbol("evaluating");
17703
+ var EVALUATING = /* @__PURE__ */ Symbol("evaluating");
17645
17704
  function defineLazy(object, key, getter) {
17646
17705
  let value = undefined;
17647
17706
  Object.defineProperty(object, key, {
@@ -17719,7 +17778,10 @@ var captureStackTrace = "captureStackTrace" in Error ? Error.captureStackTrace :
17719
17778
  function isObject(data) {
17720
17779
  return typeof data === "object" && data !== null && !Array.isArray(data);
17721
17780
  }
17722
- var allowsEval = cached(() => {
17781
+ var allowsEval = /* @__PURE__ */ cached(() => {
17782
+ if (globalConfig.jitless) {
17783
+ return false;
17784
+ }
17723
17785
  if (typeof navigator !== "undefined" && navigator?.userAgent?.includes("Cloudflare")) {
17724
17786
  return false;
17725
17787
  }
@@ -17752,6 +17814,10 @@ function shallowClone(o) {
17752
17814
  return { ...o };
17753
17815
  if (Array.isArray(o))
17754
17816
  return [...o];
17817
+ if (o instanceof Map)
17818
+ return new Map(o);
17819
+ if (o instanceof Set)
17820
+ return new Set(o);
17755
17821
  return o;
17756
17822
  }
17757
17823
  function numKeys(data) {
@@ -17807,8 +17873,15 @@ var getParsedType = (data) => {
17807
17873
  throw new Error(`Unknown data type: ${t}`);
17808
17874
  }
17809
17875
  };
17810
- var propertyKeyTypes = new Set(["string", "number", "symbol"]);
17811
- var primitiveTypes = new Set(["string", "number", "bigint", "boolean", "symbol", "undefined"]);
17876
+ var propertyKeyTypes = /* @__PURE__ */ new Set(["string", "number", "symbol"]);
17877
+ var primitiveTypes = /* @__PURE__ */ new Set([
17878
+ "string",
17879
+ "number",
17880
+ "bigint",
17881
+ "boolean",
17882
+ "symbol",
17883
+ "undefined"
17884
+ ]);
17812
17885
  function escapeRegex(str) {
17813
17886
  return str.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
17814
17887
  }
@@ -17977,6 +18050,9 @@ function safeExtend(schema, shape) {
17977
18050
  return clone(schema, def);
17978
18051
  }
17979
18052
  function merge(a, b) {
18053
+ if (a._zod.def.checks?.length) {
18054
+ throw new Error(".merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.");
18055
+ }
17980
18056
  const def = mergeDefs(a._zod.def, {
17981
18057
  get shape() {
17982
18058
  const _shape = { ...a._zod.def.shape, ...b._zod.def.shape };
@@ -17986,7 +18062,7 @@ function merge(a, b) {
17986
18062
  get catchall() {
17987
18063
  return b._zod.def.catchall;
17988
18064
  },
17989
- checks: []
18065
+ checks: b._zod.def.checks ?? []
17990
18066
  });
17991
18067
  return clone(a, def);
17992
18068
  }
@@ -18069,10 +18145,20 @@ function aborted(x, startIndex = 0) {
18069
18145
  }
18070
18146
  return false;
18071
18147
  }
18148
+ function explicitlyAborted(x, startIndex = 0) {
18149
+ if (x.aborted === true)
18150
+ return true;
18151
+ for (let i = startIndex;i < x.issues.length; i++) {
18152
+ if (x.issues[i]?.continue === false) {
18153
+ return true;
18154
+ }
18155
+ }
18156
+ return false;
18157
+ }
18072
18158
  function prefixIssues(path3, issues) {
18073
18159
  return issues.map((iss) => {
18074
- var _a;
18075
- (_a = iss).path ?? (_a.path = []);
18160
+ var _a2;
18161
+ (_a2 = iss).path ?? (_a2.path = []);
18076
18162
  iss.path.unshift(path3);
18077
18163
  return iss;
18078
18164
  });
@@ -18081,17 +18167,14 @@ function unwrapMessage(message) {
18081
18167
  return typeof message === "string" ? message : message?.message;
18082
18168
  }
18083
18169
  function finalizeIssue(iss, ctx, config2) {
18084
- const full = { ...iss, path: iss.path ?? [] };
18085
- if (!iss.message) {
18086
- const message = unwrapMessage(iss.inst?._zod.def?.error?.(iss)) ?? unwrapMessage(ctx?.error?.(iss)) ?? unwrapMessage(config2.customError?.(iss)) ?? unwrapMessage(config2.localeError?.(iss)) ?? "Invalid input";
18087
- full.message = message;
18088
- }
18089
- delete full.inst;
18090
- delete full.continue;
18091
- if (!ctx?.reportInput) {
18092
- delete full.input;
18170
+ const message = iss.message ? iss.message : unwrapMessage(iss.inst?._zod.def?.error?.(iss)) ?? unwrapMessage(ctx?.error?.(iss)) ?? unwrapMessage(config2.customError?.(iss)) ?? unwrapMessage(config2.localeError?.(iss)) ?? "Invalid input";
18171
+ const { inst: _inst, continue: _continue, input: _input, ...rest } = iss;
18172
+ rest.path ?? (rest.path = []);
18173
+ rest.message = message;
18174
+ if (ctx?.reportInput) {
18175
+ rest.input = _input;
18093
18176
  }
18094
- return full;
18177
+ return rest;
18095
18178
  }
18096
18179
  function getSizableOrigin(input) {
18097
18180
  if (input instanceof Set)
@@ -18189,7 +18272,7 @@ class Class {
18189
18272
  constructor(..._args) {}
18190
18273
  }
18191
18274
 
18192
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/errors.js
18275
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/errors.js
18193
18276
  var initializer = (inst, def) => {
18194
18277
  inst.name = "$ZodError";
18195
18278
  Object.defineProperty(inst, "_zod", {
@@ -18223,30 +18306,33 @@ function flattenError(error3, mapper = (issue2) => issue2.message) {
18223
18306
  }
18224
18307
  function formatError(error3, mapper = (issue2) => issue2.message) {
18225
18308
  const fieldErrors = { _errors: [] };
18226
- const processError = (error4) => {
18309
+ const processError = (error4, path3 = []) => {
18227
18310
  for (const issue2 of error4.issues) {
18228
18311
  if (issue2.code === "invalid_union" && issue2.errors.length) {
18229
- issue2.errors.map((issues) => processError({ issues }));
18312
+ issue2.errors.map((issues) => processError({ issues }, [...path3, ...issue2.path]));
18230
18313
  } else if (issue2.code === "invalid_key") {
18231
- processError({ issues: issue2.issues });
18314
+ processError({ issues: issue2.issues }, [...path3, ...issue2.path]);
18232
18315
  } else if (issue2.code === "invalid_element") {
18233
- processError({ issues: issue2.issues });
18234
- } else if (issue2.path.length === 0) {
18235
- fieldErrors._errors.push(mapper(issue2));
18316
+ processError({ issues: issue2.issues }, [...path3, ...issue2.path]);
18236
18317
  } else {
18237
- let curr = fieldErrors;
18238
- let i = 0;
18239
- while (i < issue2.path.length) {
18240
- const el = issue2.path[i];
18241
- const terminal = i === issue2.path.length - 1;
18242
- if (!terminal) {
18243
- curr[el] = curr[el] || { _errors: [] };
18244
- } else {
18245
- curr[el] = curr[el] || { _errors: [] };
18246
- curr[el]._errors.push(mapper(issue2));
18318
+ const fullpath = [...path3, ...issue2.path];
18319
+ if (fullpath.length === 0) {
18320
+ fieldErrors._errors.push(mapper(issue2));
18321
+ } else {
18322
+ let curr = fieldErrors;
18323
+ let i = 0;
18324
+ while (i < fullpath.length) {
18325
+ const el = fullpath[i];
18326
+ const terminal = i === fullpath.length - 1;
18327
+ if (!terminal) {
18328
+ curr[el] = curr[el] || { _errors: [] };
18329
+ } else {
18330
+ curr[el] = curr[el] || { _errors: [] };
18331
+ curr[el]._errors.push(mapper(issue2));
18332
+ }
18333
+ curr = curr[el];
18334
+ i++;
18247
18335
  }
18248
- curr = curr[el];
18249
- i++;
18250
18336
  }
18251
18337
  }
18252
18338
  }
@@ -18257,14 +18343,14 @@ function formatError(error3, mapper = (issue2) => issue2.message) {
18257
18343
  function treeifyError(error3, mapper = (issue2) => issue2.message) {
18258
18344
  const result = { errors: [] };
18259
18345
  const processError = (error4, path3 = []) => {
18260
- var _a, _b;
18346
+ var _a2, _b;
18261
18347
  for (const issue2 of error4.issues) {
18262
18348
  if (issue2.code === "invalid_union" && issue2.errors.length) {
18263
- issue2.errors.map((issues) => processError({ issues }, issue2.path));
18349
+ issue2.errors.map((issues) => processError({ issues }, [...path3, ...issue2.path]));
18264
18350
  } else if (issue2.code === "invalid_key") {
18265
- processError({ issues: issue2.issues }, issue2.path);
18351
+ processError({ issues: issue2.issues }, [...path3, ...issue2.path]);
18266
18352
  } else if (issue2.code === "invalid_element") {
18267
- processError({ issues: issue2.issues }, issue2.path);
18353
+ processError({ issues: issue2.issues }, [...path3, ...issue2.path]);
18268
18354
  } else {
18269
18355
  const fullpath = [...path3, ...issue2.path];
18270
18356
  if (fullpath.length === 0) {
@@ -18278,7 +18364,7 @@ function treeifyError(error3, mapper = (issue2) => issue2.message) {
18278
18364
  const terminal = i === fullpath.length - 1;
18279
18365
  if (typeof el === "string") {
18280
18366
  curr.properties ?? (curr.properties = {});
18281
- (_a = curr.properties)[el] ?? (_a[el] = { errors: [] });
18367
+ (_a2 = curr.properties)[el] ?? (_a2[el] = { errors: [] });
18282
18368
  curr = curr.properties[el];
18283
18369
  } else {
18284
18370
  curr.items ?? (curr.items = []);
@@ -18326,9 +18412,9 @@ function prettifyError(error3) {
18326
18412
  `);
18327
18413
  }
18328
18414
 
18329
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/parse.js
18415
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/parse.js
18330
18416
  var _parse = (_Err) => (schema, value, _ctx, _params) => {
18331
- const ctx = _ctx ? Object.assign(_ctx, { async: false }) : { async: false };
18417
+ const ctx = _ctx ? { ..._ctx, async: false } : { async: false };
18332
18418
  const result = schema._zod.run({ value, issues: [] }, ctx);
18333
18419
  if (result instanceof Promise) {
18334
18420
  throw new $ZodAsyncError;
@@ -18342,7 +18428,7 @@ var _parse = (_Err) => (schema, value, _ctx, _params) => {
18342
18428
  };
18343
18429
  var parse = /* @__PURE__ */ _parse($ZodRealError);
18344
18430
  var _parseAsync = (_Err) => async (schema, value, _ctx, params) => {
18345
- const ctx = _ctx ? Object.assign(_ctx, { async: true }) : { async: true };
18431
+ const ctx = _ctx ? { ..._ctx, async: true } : { async: true };
18346
18432
  let result = schema._zod.run({ value, issues: [] }, ctx);
18347
18433
  if (result instanceof Promise)
18348
18434
  result = await result;
@@ -18367,7 +18453,7 @@ var _safeParse = (_Err) => (schema, value, _ctx) => {
18367
18453
  };
18368
18454
  var safeParse = /* @__PURE__ */ _safeParse($ZodRealError);
18369
18455
  var _safeParseAsync = (_Err) => async (schema, value, _ctx) => {
18370
- const ctx = _ctx ? Object.assign(_ctx, { async: true }) : { async: true };
18456
+ const ctx = _ctx ? { ..._ctx, async: true } : { async: true };
18371
18457
  let result = schema._zod.run({ value, issues: [] }, ctx);
18372
18458
  if (result instanceof Promise)
18373
18459
  result = await result;
@@ -18378,7 +18464,7 @@ var _safeParseAsync = (_Err) => async (schema, value, _ctx) => {
18378
18464
  };
18379
18465
  var safeParseAsync = /* @__PURE__ */ _safeParseAsync($ZodRealError);
18380
18466
  var _encode = (_Err) => (schema, value, _ctx) => {
18381
- const ctx = _ctx ? Object.assign(_ctx, { direction: "backward" }) : { direction: "backward" };
18467
+ const ctx = _ctx ? { ..._ctx, direction: "backward" } : { direction: "backward" };
18382
18468
  return _parse(_Err)(schema, value, ctx);
18383
18469
  };
18384
18470
  var encode = /* @__PURE__ */ _encode($ZodRealError);
@@ -18387,7 +18473,7 @@ var _decode = (_Err) => (schema, value, _ctx) => {
18387
18473
  };
18388
18474
  var decode = /* @__PURE__ */ _decode($ZodRealError);
18389
18475
  var _encodeAsync = (_Err) => async (schema, value, _ctx) => {
18390
- const ctx = _ctx ? Object.assign(_ctx, { direction: "backward" }) : { direction: "backward" };
18476
+ const ctx = _ctx ? { ..._ctx, direction: "backward" } : { direction: "backward" };
18391
18477
  return _parseAsync(_Err)(schema, value, ctx);
18392
18478
  };
18393
18479
  var encodeAsync = /* @__PURE__ */ _encodeAsync($ZodRealError);
@@ -18396,7 +18482,7 @@ var _decodeAsync = (_Err) => async (schema, value, _ctx) => {
18396
18482
  };
18397
18483
  var decodeAsync = /* @__PURE__ */ _decodeAsync($ZodRealError);
18398
18484
  var _safeEncode = (_Err) => (schema, value, _ctx) => {
18399
- const ctx = _ctx ? Object.assign(_ctx, { direction: "backward" }) : { direction: "backward" };
18485
+ const ctx = _ctx ? { ..._ctx, direction: "backward" } : { direction: "backward" };
18400
18486
  return _safeParse(_Err)(schema, value, ctx);
18401
18487
  };
18402
18488
  var safeEncode = /* @__PURE__ */ _safeEncode($ZodRealError);
@@ -18405,7 +18491,7 @@ var _safeDecode = (_Err) => (schema, value, _ctx) => {
18405
18491
  };
18406
18492
  var safeDecode = /* @__PURE__ */ _safeDecode($ZodRealError);
18407
18493
  var _safeEncodeAsync = (_Err) => async (schema, value, _ctx) => {
18408
- const ctx = _ctx ? Object.assign(_ctx, { direction: "backward" }) : { direction: "backward" };
18494
+ const ctx = _ctx ? { ..._ctx, direction: "backward" } : { direction: "backward" };
18409
18495
  return _safeParseAsync(_Err)(schema, value, ctx);
18410
18496
  };
18411
18497
  var safeEncodeAsync = /* @__PURE__ */ _safeEncodeAsync($ZodRealError);
@@ -18413,7 +18499,7 @@ var _safeDecodeAsync = (_Err) => async (schema, value, _ctx) => {
18413
18499
  return _safeParseAsync(_Err)(schema, value, _ctx);
18414
18500
  };
18415
18501
  var safeDecodeAsync = /* @__PURE__ */ _safeDecodeAsync($ZodRealError);
18416
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/regexes.js
18502
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/regexes.js
18417
18503
  var exports_regexes = {};
18418
18504
  __export(exports_regexes, {
18419
18505
  xid: () => xid,
@@ -18453,6 +18539,7 @@ __export(exports_regexes, {
18453
18539
  ipv4: () => ipv4,
18454
18540
  integer: () => integer,
18455
18541
  idnEmail: () => idnEmail,
18542
+ httpProtocol: () => httpProtocol,
18456
18543
  html5Email: () => html5Email,
18457
18544
  hostname: () => hostname,
18458
18545
  hex: () => hex,
@@ -18475,7 +18562,7 @@ __export(exports_regexes, {
18475
18562
  base64url: () => base64url,
18476
18563
  base64: () => base64
18477
18564
  });
18478
- var cuid = /^[cC][^\s-]{8,}$/;
18565
+ var cuid = /^[cC][0-9a-z]{6,}$/;
18479
18566
  var cuid2 = /^[0-9a-z]+$/;
18480
18567
  var ulid = /^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/;
18481
18568
  var xid = /^[0-9a-vA-V]{20}$/;
@@ -18514,6 +18601,7 @@ var base64 = /^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/
18514
18601
  var base64url = /^[A-Za-z0-9_-]*$/;
18515
18602
  var hostname = /^(?=.{1,253}\.?$)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[-0-9a-zA-Z]{0,61}[0-9a-zA-Z])?)*\.?$/;
18516
18603
  var domain = /^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/;
18604
+ var httpProtocol = /^https?$/;
18517
18605
  var e164 = /^\+[1-9]\d{6,14}$/;
18518
18606
  var dateSource = `(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))`;
18519
18607
  var date = /* @__PURE__ */ new RegExp(`^${dateSource}$`);
@@ -18570,12 +18658,12 @@ var sha512_hex = /^[0-9a-fA-F]{128}$/;
18570
18658
  var sha512_base64 = /* @__PURE__ */ fixedBase64(86, "==");
18571
18659
  var sha512_base64url = /* @__PURE__ */ fixedBase64url(86);
18572
18660
 
18573
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/checks.js
18661
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/checks.js
18574
18662
  var $ZodCheck = /* @__PURE__ */ $constructor("$ZodCheck", (inst, def) => {
18575
- var _a;
18663
+ var _a2;
18576
18664
  inst._zod ?? (inst._zod = {});
18577
18665
  inst._zod.def = def;
18578
- (_a = inst._zod).onattach ?? (_a.onattach = []);
18666
+ (_a2 = inst._zod).onattach ?? (_a2.onattach = []);
18579
18667
  });
18580
18668
  var numericOriginMap = {
18581
18669
  number: "number",
@@ -18641,8 +18729,8 @@ var $ZodCheckGreaterThan = /* @__PURE__ */ $constructor("$ZodCheckGreaterThan",
18641
18729
  var $ZodCheckMultipleOf = /* @__PURE__ */ $constructor("$ZodCheckMultipleOf", (inst, def) => {
18642
18730
  $ZodCheck.init(inst, def);
18643
18731
  inst._zod.onattach.push((inst2) => {
18644
- var _a;
18645
- (_a = inst2._zod.bag).multipleOf ?? (_a.multipleOf = def.value);
18732
+ var _a2;
18733
+ (_a2 = inst2._zod.bag).multipleOf ?? (_a2.multipleOf = def.value);
18646
18734
  });
18647
18735
  inst._zod.check = (payload) => {
18648
18736
  if (typeof payload.value !== typeof def.value)
@@ -18775,9 +18863,9 @@ var $ZodCheckBigIntFormat = /* @__PURE__ */ $constructor("$ZodCheckBigIntFormat"
18775
18863
  };
18776
18864
  });
18777
18865
  var $ZodCheckMaxSize = /* @__PURE__ */ $constructor("$ZodCheckMaxSize", (inst, def) => {
18778
- var _a;
18866
+ var _a2;
18779
18867
  $ZodCheck.init(inst, def);
18780
- (_a = inst._zod.def).when ?? (_a.when = (payload) => {
18868
+ (_a2 = inst._zod.def).when ?? (_a2.when = (payload) => {
18781
18869
  const val = payload.value;
18782
18870
  return !nullish(val) && val.size !== undefined;
18783
18871
  });
@@ -18803,9 +18891,9 @@ var $ZodCheckMaxSize = /* @__PURE__ */ $constructor("$ZodCheckMaxSize", (inst, d
18803
18891
  };
18804
18892
  });
18805
18893
  var $ZodCheckMinSize = /* @__PURE__ */ $constructor("$ZodCheckMinSize", (inst, def) => {
18806
- var _a;
18894
+ var _a2;
18807
18895
  $ZodCheck.init(inst, def);
18808
- (_a = inst._zod.def).when ?? (_a.when = (payload) => {
18896
+ (_a2 = inst._zod.def).when ?? (_a2.when = (payload) => {
18809
18897
  const val = payload.value;
18810
18898
  return !nullish(val) && val.size !== undefined;
18811
18899
  });
@@ -18831,9 +18919,9 @@ var $ZodCheckMinSize = /* @__PURE__ */ $constructor("$ZodCheckMinSize", (inst, d
18831
18919
  };
18832
18920
  });
18833
18921
  var $ZodCheckSizeEquals = /* @__PURE__ */ $constructor("$ZodCheckSizeEquals", (inst, def) => {
18834
- var _a;
18922
+ var _a2;
18835
18923
  $ZodCheck.init(inst, def);
18836
- (_a = inst._zod.def).when ?? (_a.when = (payload) => {
18924
+ (_a2 = inst._zod.def).when ?? (_a2.when = (payload) => {
18837
18925
  const val = payload.value;
18838
18926
  return !nullish(val) && val.size !== undefined;
18839
18927
  });
@@ -18861,9 +18949,9 @@ var $ZodCheckSizeEquals = /* @__PURE__ */ $constructor("$ZodCheckSizeEquals", (i
18861
18949
  };
18862
18950
  });
18863
18951
  var $ZodCheckMaxLength = /* @__PURE__ */ $constructor("$ZodCheckMaxLength", (inst, def) => {
18864
- var _a;
18952
+ var _a2;
18865
18953
  $ZodCheck.init(inst, def);
18866
- (_a = inst._zod.def).when ?? (_a.when = (payload) => {
18954
+ (_a2 = inst._zod.def).when ?? (_a2.when = (payload) => {
18867
18955
  const val = payload.value;
18868
18956
  return !nullish(val) && val.length !== undefined;
18869
18957
  });
@@ -18890,9 +18978,9 @@ var $ZodCheckMaxLength = /* @__PURE__ */ $constructor("$ZodCheckMaxLength", (ins
18890
18978
  };
18891
18979
  });
18892
18980
  var $ZodCheckMinLength = /* @__PURE__ */ $constructor("$ZodCheckMinLength", (inst, def) => {
18893
- var _a;
18981
+ var _a2;
18894
18982
  $ZodCheck.init(inst, def);
18895
- (_a = inst._zod.def).when ?? (_a.when = (payload) => {
18983
+ (_a2 = inst._zod.def).when ?? (_a2.when = (payload) => {
18896
18984
  const val = payload.value;
18897
18985
  return !nullish(val) && val.length !== undefined;
18898
18986
  });
@@ -18919,9 +19007,9 @@ var $ZodCheckMinLength = /* @__PURE__ */ $constructor("$ZodCheckMinLength", (ins
18919
19007
  };
18920
19008
  });
18921
19009
  var $ZodCheckLengthEquals = /* @__PURE__ */ $constructor("$ZodCheckLengthEquals", (inst, def) => {
18922
- var _a;
19010
+ var _a2;
18923
19011
  $ZodCheck.init(inst, def);
18924
- (_a = inst._zod.def).when ?? (_a.when = (payload) => {
19012
+ (_a2 = inst._zod.def).when ?? (_a2.when = (payload) => {
18925
19013
  const val = payload.value;
18926
19014
  return !nullish(val) && val.length !== undefined;
18927
19015
  });
@@ -18950,7 +19038,7 @@ var $ZodCheckLengthEquals = /* @__PURE__ */ $constructor("$ZodCheckLengthEquals"
18950
19038
  };
18951
19039
  });
18952
19040
  var $ZodCheckStringFormat = /* @__PURE__ */ $constructor("$ZodCheckStringFormat", (inst, def) => {
18953
- var _a, _b;
19041
+ var _a2, _b;
18954
19042
  $ZodCheck.init(inst, def);
18955
19043
  inst._zod.onattach.push((inst2) => {
18956
19044
  const bag = inst2._zod.bag;
@@ -18961,7 +19049,7 @@ var $ZodCheckStringFormat = /* @__PURE__ */ $constructor("$ZodCheckStringFormat"
18961
19049
  }
18962
19050
  });
18963
19051
  if (def.pattern)
18964
- (_a = inst._zod).check ?? (_a.check = (payload) => {
19052
+ (_a2 = inst._zod).check ?? (_a2.check = (payload) => {
18965
19053
  def.pattern.lastIndex = 0;
18966
19054
  if (def.pattern.test(payload.value))
18967
19055
  return;
@@ -19117,7 +19205,7 @@ var $ZodCheckOverwrite = /* @__PURE__ */ $constructor("$ZodCheckOverwrite", (ins
19117
19205
  };
19118
19206
  });
19119
19207
 
19120
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/doc.js
19208
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/doc.js
19121
19209
  class Doc {
19122
19210
  constructor(args = []) {
19123
19211
  this.content = [];
@@ -19155,16 +19243,16 @@ class Doc {
19155
19243
  }
19156
19244
  }
19157
19245
 
19158
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/versions.js
19246
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/versions.js
19159
19247
  var version = {
19160
19248
  major: 4,
19161
- minor: 3,
19162
- patch: 6
19249
+ minor: 4,
19250
+ patch: 3
19163
19251
  };
19164
19252
 
19165
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/schemas.js
19253
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/schemas.js
19166
19254
  var $ZodType = /* @__PURE__ */ $constructor("$ZodType", (inst, def) => {
19167
- var _a;
19255
+ var _a2;
19168
19256
  inst ?? (inst = {});
19169
19257
  inst._zod.def = def;
19170
19258
  inst._zod.bag = inst._zod.bag || {};
@@ -19179,7 +19267,7 @@ var $ZodType = /* @__PURE__ */ $constructor("$ZodType", (inst, def) => {
19179
19267
  }
19180
19268
  }
19181
19269
  if (checks.length === 0) {
19182
- (_a = inst._zod).deferred ?? (_a.deferred = []);
19270
+ (_a2 = inst._zod).deferred ?? (_a2.deferred = []);
19183
19271
  inst._zod.deferred?.push(() => {
19184
19272
  inst._zod.run = inst._zod.parse;
19185
19273
  });
@@ -19189,6 +19277,8 @@ var $ZodType = /* @__PURE__ */ $constructor("$ZodType", (inst, def) => {
19189
19277
  let asyncResult;
19190
19278
  for (const ch of checks2) {
19191
19279
  if (ch._zod.def.when) {
19280
+ if (explicitlyAborted(payload))
19281
+ continue;
19192
19282
  const shouldRun = ch._zod.def.when(payload);
19193
19283
  if (!shouldRun)
19194
19284
  continue;
@@ -19328,6 +19418,19 @@ var $ZodURL = /* @__PURE__ */ $constructor("$ZodURL", (inst, def) => {
19328
19418
  inst._zod.check = (payload) => {
19329
19419
  try {
19330
19420
  const trimmed = payload.value.trim();
19421
+ if (!def.normalize && def.protocol?.source === httpProtocol.source) {
19422
+ if (!/^https?:\/\//i.test(trimmed)) {
19423
+ payload.issues.push({
19424
+ code: "invalid_format",
19425
+ format: "url",
19426
+ note: "Invalid URL format",
19427
+ input: payload.value,
19428
+ inst,
19429
+ continue: !def.abort
19430
+ });
19431
+ return;
19432
+ }
19433
+ }
19331
19434
  const url = new URL(trimmed);
19332
19435
  if (def.hostname) {
19333
19436
  def.hostname.lastIndex = 0;
@@ -19481,6 +19584,8 @@ var $ZodCIDRv6 = /* @__PURE__ */ $constructor("$ZodCIDRv6", (inst, def) => {
19481
19584
  function isValidBase64(data) {
19482
19585
  if (data === "")
19483
19586
  return true;
19587
+ if (/\s/.test(data))
19588
+ return false;
19484
19589
  if (data.length % 4 !== 0)
19485
19590
  return false;
19486
19591
  try {
@@ -19670,8 +19775,6 @@ var $ZodUndefined = /* @__PURE__ */ $constructor("$ZodUndefined", (inst, def) =>
19670
19775
  $ZodType.init(inst, def);
19671
19776
  inst._zod.pattern = _undefined;
19672
19777
  inst._zod.values = new Set([undefined]);
19673
- inst._zod.optin = "optional";
19674
- inst._zod.optout = "optional";
19675
19778
  inst._zod.parse = (payload, _ctx) => {
19676
19779
  const input = payload.value;
19677
19780
  if (typeof input === "undefined")
@@ -19799,15 +19902,27 @@ var $ZodArray = /* @__PURE__ */ $constructor("$ZodArray", (inst, def) => {
19799
19902
  return payload;
19800
19903
  };
19801
19904
  });
19802
- function handlePropertyResult(result, final, key, input, isOptionalOut) {
19905
+ function handlePropertyResult(result, final, key, input, isOptionalIn, isOptionalOut) {
19906
+ const isPresent = key in input;
19803
19907
  if (result.issues.length) {
19804
- if (isOptionalOut && !(key in input)) {
19908
+ if (isOptionalIn && isOptionalOut && !isPresent) {
19805
19909
  return;
19806
19910
  }
19807
19911
  final.issues.push(...prefixIssues(key, result.issues));
19808
19912
  }
19913
+ if (!isPresent && !isOptionalIn) {
19914
+ if (!result.issues.length) {
19915
+ final.issues.push({
19916
+ code: "invalid_type",
19917
+ expected: "nonoptional",
19918
+ input: undefined,
19919
+ path: [key]
19920
+ });
19921
+ }
19922
+ return;
19923
+ }
19809
19924
  if (result.value === undefined) {
19810
- if (key in input) {
19925
+ if (isPresent) {
19811
19926
  final.value[key] = undefined;
19812
19927
  }
19813
19928
  } else {
@@ -19835,8 +19950,11 @@ function handleCatchall(proms, input, payload, ctx, def, inst) {
19835
19950
  const keySet = def.keySet;
19836
19951
  const _catchall = def.catchall._zod;
19837
19952
  const t = _catchall.def.type;
19953
+ const isOptionalIn = _catchall.optin === "optional";
19838
19954
  const isOptionalOut = _catchall.optout === "optional";
19839
19955
  for (const key in input) {
19956
+ if (key === "__proto__")
19957
+ continue;
19840
19958
  if (keySet.has(key))
19841
19959
  continue;
19842
19960
  if (t === "never") {
@@ -19845,9 +19963,9 @@ function handleCatchall(proms, input, payload, ctx, def, inst) {
19845
19963
  }
19846
19964
  const r = _catchall.run({ value: input[key], issues: [] }, ctx);
19847
19965
  if (r instanceof Promise) {
19848
- proms.push(r.then((r2) => handlePropertyResult(r2, payload, key, input, isOptionalOut)));
19966
+ proms.push(r.then((r2) => handlePropertyResult(r2, payload, key, input, isOptionalIn, isOptionalOut)));
19849
19967
  } else {
19850
- handlePropertyResult(r, payload, key, input, isOptionalOut);
19968
+ handlePropertyResult(r, payload, key, input, isOptionalIn, isOptionalOut);
19851
19969
  }
19852
19970
  }
19853
19971
  if (unrecognized.length) {
@@ -19913,12 +20031,13 @@ var $ZodObject = /* @__PURE__ */ $constructor("$ZodObject", (inst, def) => {
19913
20031
  const shape = value.shape;
19914
20032
  for (const key of value.keys) {
19915
20033
  const el = shape[key];
20034
+ const isOptionalIn = el._zod.optin === "optional";
19916
20035
  const isOptionalOut = el._zod.optout === "optional";
19917
20036
  const r = el._zod.run({ value: input[key], issues: [] }, ctx);
19918
20037
  if (r instanceof Promise) {
19919
- proms.push(r.then((r2) => handlePropertyResult(r2, payload, key, input, isOptionalOut)));
20038
+ proms.push(r.then((r2) => handlePropertyResult(r2, payload, key, input, isOptionalIn, isOptionalOut)));
19920
20039
  } else {
19921
- handlePropertyResult(r, payload, key, input, isOptionalOut);
20040
+ handlePropertyResult(r, payload, key, input, isOptionalIn, isOptionalOut);
19922
20041
  }
19923
20042
  }
19924
20043
  if (!catchall) {
@@ -19949,9 +20068,10 @@ var $ZodObjectJIT = /* @__PURE__ */ $constructor("$ZodObjectJIT", (inst, def) =>
19949
20068
  const id = ids[key];
19950
20069
  const k = esc(key);
19951
20070
  const schema = shape[key];
20071
+ const isOptionalIn = schema?._zod?.optin === "optional";
19952
20072
  const isOptionalOut = schema?._zod?.optout === "optional";
19953
20073
  doc.write(`const ${id} = ${parseStr(key)};`);
19954
- if (isOptionalOut) {
20074
+ if (isOptionalIn && isOptionalOut) {
19955
20075
  doc.write(`
19956
20076
  if (${id}.issues.length) {
19957
20077
  if (${k} in input) {
@@ -19970,6 +20090,33 @@ var $ZodObjectJIT = /* @__PURE__ */ $constructor("$ZodObjectJIT", (inst, def) =>
19970
20090
  newResult[${k}] = ${id}.value;
19971
20091
  }
19972
20092
 
20093
+ `);
20094
+ } else if (!isOptionalIn) {
20095
+ doc.write(`
20096
+ const ${id}_present = ${k} in input;
20097
+ if (${id}.issues.length) {
20098
+ payload.issues = payload.issues.concat(${id}.issues.map(iss => ({
20099
+ ...iss,
20100
+ path: iss.path ? [${k}, ...iss.path] : [${k}]
20101
+ })));
20102
+ }
20103
+ if (!${id}_present && !${id}.issues.length) {
20104
+ payload.issues.push({
20105
+ code: "invalid_type",
20106
+ expected: "nonoptional",
20107
+ input: undefined,
20108
+ path: [${k}]
20109
+ });
20110
+ }
20111
+
20112
+ if (${id}_present) {
20113
+ if (${id}.value === undefined) {
20114
+ newResult[${k}] = undefined;
20115
+ } else {
20116
+ newResult[${k}] = ${id}.value;
20117
+ }
20118
+ }
20119
+
19973
20120
  `);
19974
20121
  } else {
19975
20122
  doc.write(`
@@ -20063,10 +20210,9 @@ var $ZodUnion = /* @__PURE__ */ $constructor("$ZodUnion", (inst, def) => {
20063
20210
  }
20064
20211
  return;
20065
20212
  });
20066
- const single = def.options.length === 1;
20067
- const first = def.options[0]._zod.run;
20213
+ const first = def.options.length === 1 ? def.options[0]._zod.run : null;
20068
20214
  inst._zod.parse = (payload, ctx) => {
20069
- if (single) {
20215
+ if (first) {
20070
20216
  return first(payload, ctx);
20071
20217
  }
20072
20218
  let async = false;
@@ -20119,10 +20265,9 @@ function handleExclusiveUnionResults(results, final, inst, ctx) {
20119
20265
  var $ZodXor = /* @__PURE__ */ $constructor("$ZodXor", (inst, def) => {
20120
20266
  $ZodUnion.init(inst, def);
20121
20267
  def.inclusive = false;
20122
- const single = def.options.length === 1;
20123
- const first = def.options[0]._zod.run;
20268
+ const first = def.options.length === 1 ? def.options[0]._zod.run : null;
20124
20269
  inst._zod.parse = (payload, ctx) => {
20125
- if (single) {
20270
+ if (first) {
20126
20271
  return first(payload, ctx);
20127
20272
  }
20128
20273
  let async = false;
@@ -20197,7 +20342,7 @@ var $ZodDiscriminatedUnion = /* @__PURE__ */ $constructor("$ZodDiscriminatedUnio
20197
20342
  if (opt) {
20198
20343
  return opt._zod.run(payload, ctx);
20199
20344
  }
20200
- if (def.unionFallback) {
20345
+ if (def.unionFallback || ctx.direction === "backward") {
20201
20346
  return _super(payload, ctx);
20202
20347
  }
20203
20348
  payload.issues.push({
@@ -20205,6 +20350,7 @@ var $ZodDiscriminatedUnion = /* @__PURE__ */ $constructor("$ZodDiscriminatedUnio
20205
20350
  errors: [],
20206
20351
  note: "No matching discriminator",
20207
20352
  discriminator: def.discriminator,
20353
+ options: Array.from(disc.value.keys()),
20208
20354
  input,
20209
20355
  path: [def.discriminator],
20210
20356
  inst
@@ -20326,64 +20472,96 @@ var $ZodTuple = /* @__PURE__ */ $constructor("$ZodTuple", (inst, def) => {
20326
20472
  }
20327
20473
  payload.value = [];
20328
20474
  const proms = [];
20329
- const reversedIndex = [...items].reverse().findIndex((item) => item._zod.optin !== "optional");
20330
- const optStart = reversedIndex === -1 ? 0 : items.length - reversedIndex;
20475
+ const optinStart = getTupleOptStart(items, "optin");
20476
+ const optoutStart = getTupleOptStart(items, "optout");
20331
20477
  if (!def.rest) {
20332
- const tooBig = input.length > items.length;
20333
- const tooSmall = input.length < optStart - 1;
20334
- if (tooBig || tooSmall) {
20478
+ if (input.length < optinStart) {
20335
20479
  payload.issues.push({
20336
- ...tooBig ? { code: "too_big", maximum: items.length, inclusive: true } : { code: "too_small", minimum: items.length },
20480
+ code: "too_small",
20481
+ minimum: optinStart,
20482
+ inclusive: true,
20337
20483
  input,
20338
20484
  inst,
20339
20485
  origin: "array"
20340
20486
  });
20341
20487
  return payload;
20342
20488
  }
20343
- }
20344
- let i = -1;
20345
- for (const item of items) {
20346
- i++;
20347
- if (i >= input.length) {
20348
- if (i >= optStart)
20349
- continue;
20489
+ if (input.length > items.length) {
20490
+ payload.issues.push({
20491
+ code: "too_big",
20492
+ maximum: items.length,
20493
+ inclusive: true,
20494
+ input,
20495
+ inst,
20496
+ origin: "array"
20497
+ });
20350
20498
  }
20351
- const result = item._zod.run({
20352
- value: input[i],
20353
- issues: []
20354
- }, ctx);
20355
- if (result instanceof Promise) {
20356
- proms.push(result.then((result2) => handleTupleResult(result2, payload, i)));
20499
+ }
20500
+ const itemResults = new Array(items.length);
20501
+ for (let i = 0;i < items.length; i++) {
20502
+ const r = items[i]._zod.run({ value: input[i], issues: [] }, ctx);
20503
+ if (r instanceof Promise) {
20504
+ proms.push(r.then((rr) => {
20505
+ itemResults[i] = rr;
20506
+ }));
20357
20507
  } else {
20358
- handleTupleResult(result, payload, i);
20508
+ itemResults[i] = r;
20359
20509
  }
20360
20510
  }
20361
20511
  if (def.rest) {
20512
+ let i = items.length - 1;
20362
20513
  const rest = input.slice(items.length);
20363
20514
  for (const el of rest) {
20364
20515
  i++;
20365
- const result = def.rest._zod.run({
20366
- value: el,
20367
- issues: []
20368
- }, ctx);
20516
+ const result = def.rest._zod.run({ value: el, issues: [] }, ctx);
20369
20517
  if (result instanceof Promise) {
20370
- proms.push(result.then((result2) => handleTupleResult(result2, payload, i)));
20518
+ proms.push(result.then((r) => handleTupleResult(r, payload, i)));
20371
20519
  } else {
20372
20520
  handleTupleResult(result, payload, i);
20373
20521
  }
20374
20522
  }
20375
20523
  }
20376
- if (proms.length)
20377
- return Promise.all(proms).then(() => payload);
20378
- return payload;
20524
+ if (proms.length) {
20525
+ return Promise.all(proms).then(() => handleTupleResults(itemResults, payload, items, input, optoutStart));
20526
+ }
20527
+ return handleTupleResults(itemResults, payload, items, input, optoutStart);
20379
20528
  };
20380
20529
  });
20530
+ function getTupleOptStart(items, key) {
20531
+ for (let i = items.length - 1;i >= 0; i--) {
20532
+ if (items[i]._zod[key] !== "optional")
20533
+ return i + 1;
20534
+ }
20535
+ return 0;
20536
+ }
20381
20537
  function handleTupleResult(result, final, index) {
20382
20538
  if (result.issues.length) {
20383
20539
  final.issues.push(...prefixIssues(index, result.issues));
20384
20540
  }
20385
20541
  final.value[index] = result.value;
20386
20542
  }
20543
+ function handleTupleResults(itemResults, final, items, input, optoutStart) {
20544
+ for (let i = 0;i < items.length; i++) {
20545
+ const r = itemResults[i];
20546
+ const isPresent = i < input.length;
20547
+ if (r.issues.length) {
20548
+ if (!isPresent && i >= optoutStart) {
20549
+ final.value.length = i;
20550
+ break;
20551
+ }
20552
+ final.issues.push(...prefixIssues(i, r.issues));
20553
+ }
20554
+ final.value[i] = r.value;
20555
+ }
20556
+ for (let i = final.value.length - 1;i >= input.length; i--) {
20557
+ if (items[i]._zod.optout === "optional" && final.value[i] === undefined) {
20558
+ final.value.length = i;
20559
+ } else {
20560
+ break;
20561
+ }
20562
+ }
20563
+ return final;
20564
+ }
20387
20565
  var $ZodRecord = /* @__PURE__ */ $constructor("$ZodRecord", (inst, def) => {
20388
20566
  $ZodType.init(inst, def);
20389
20567
  inst._zod.parse = (payload, ctx) => {
@@ -20405,19 +20583,35 @@ var $ZodRecord = /* @__PURE__ */ $constructor("$ZodRecord", (inst, def) => {
20405
20583
  for (const key of values) {
20406
20584
  if (typeof key === "string" || typeof key === "number" || typeof key === "symbol") {
20407
20585
  recordKeys.add(typeof key === "number" ? key.toString() : key);
20586
+ const keyResult = def.keyType._zod.run({ value: key, issues: [] }, ctx);
20587
+ if (keyResult instanceof Promise) {
20588
+ throw new Error("Async schemas not supported in object keys currently");
20589
+ }
20590
+ if (keyResult.issues.length) {
20591
+ payload.issues.push({
20592
+ code: "invalid_key",
20593
+ origin: "record",
20594
+ issues: keyResult.issues.map((iss) => finalizeIssue(iss, ctx, config())),
20595
+ input: key,
20596
+ path: [key],
20597
+ inst
20598
+ });
20599
+ continue;
20600
+ }
20601
+ const outKey = keyResult.value;
20408
20602
  const result = def.valueType._zod.run({ value: input[key], issues: [] }, ctx);
20409
20603
  if (result instanceof Promise) {
20410
20604
  proms.push(result.then((result2) => {
20411
20605
  if (result2.issues.length) {
20412
20606
  payload.issues.push(...prefixIssues(key, result2.issues));
20413
20607
  }
20414
- payload.value[key] = result2.value;
20608
+ payload.value[outKey] = result2.value;
20415
20609
  }));
20416
20610
  } else {
20417
20611
  if (result.issues.length) {
20418
20612
  payload.issues.push(...prefixIssues(key, result.issues));
20419
20613
  }
20420
- payload.value[key] = result.value;
20614
+ payload.value[outKey] = result.value;
20421
20615
  }
20422
20616
  }
20423
20617
  }
@@ -20441,6 +20635,8 @@ var $ZodRecord = /* @__PURE__ */ $constructor("$ZodRecord", (inst, def) => {
20441
20635
  for (const key of Reflect.ownKeys(input)) {
20442
20636
  if (key === "__proto__")
20443
20637
  continue;
20638
+ if (!Object.prototype.propertyIsEnumerable.call(input, key))
20639
+ continue;
20444
20640
  let keyResult = def.keyType._zod.run({ value: key, issues: [] }, ctx);
20445
20641
  if (keyResult instanceof Promise) {
20446
20642
  throw new Error("Async schemas not supported in object keys currently");
@@ -20645,6 +20841,7 @@ var $ZodFile = /* @__PURE__ */ $constructor("$ZodFile", (inst, def) => {
20645
20841
  });
20646
20842
  var $ZodTransform = /* @__PURE__ */ $constructor("$ZodTransform", (inst, def) => {
20647
20843
  $ZodType.init(inst, def);
20844
+ inst._zod.optin = "optional";
20648
20845
  inst._zod.parse = (payload, ctx) => {
20649
20846
  if (ctx.direction === "backward") {
20650
20847
  throw new $ZodEncodeError(inst.constructor.name);
@@ -20654,6 +20851,7 @@ var $ZodTransform = /* @__PURE__ */ $constructor("$ZodTransform", (inst, def) =>
20654
20851
  const output = _out instanceof Promise ? _out : Promise.resolve(_out);
20655
20852
  return output.then((output2) => {
20656
20853
  payload.value = output2;
20854
+ payload.fallback = true;
20657
20855
  return payload;
20658
20856
  });
20659
20857
  }
@@ -20661,11 +20859,12 @@ var $ZodTransform = /* @__PURE__ */ $constructor("$ZodTransform", (inst, def) =>
20661
20859
  throw new $ZodAsyncError;
20662
20860
  }
20663
20861
  payload.value = _out;
20862
+ payload.fallback = true;
20664
20863
  return payload;
20665
20864
  };
20666
20865
  });
20667
20866
  function handleOptionalResult(result, input) {
20668
- if (result.issues.length && input === undefined) {
20867
+ if (input === undefined && (result.issues.length || result.fallback)) {
20669
20868
  return { issues: [], value: undefined };
20670
20869
  }
20671
20870
  return result;
@@ -20683,10 +20882,11 @@ var $ZodOptional = /* @__PURE__ */ $constructor("$ZodOptional", (inst, def) => {
20683
20882
  });
20684
20883
  inst._zod.parse = (payload, ctx) => {
20685
20884
  if (def.innerType._zod.optin === "optional") {
20885
+ const input = payload.value;
20686
20886
  const result = def.innerType._zod.run(payload, ctx);
20687
20887
  if (result instanceof Promise)
20688
- return result.then((r) => handleOptionalResult(r, payload.value));
20689
- return handleOptionalResult(result, payload.value);
20888
+ return result.then((r) => handleOptionalResult(r, input));
20889
+ return handleOptionalResult(result, input);
20690
20890
  }
20691
20891
  if (payload.value === undefined) {
20692
20892
  return payload;
@@ -20802,7 +21002,7 @@ var $ZodSuccess = /* @__PURE__ */ $constructor("$ZodSuccess", (inst, def) => {
20802
21002
  });
20803
21003
  var $ZodCatch = /* @__PURE__ */ $constructor("$ZodCatch", (inst, def) => {
20804
21004
  $ZodType.init(inst, def);
20805
- defineLazy(inst._zod, "optin", () => def.innerType._zod.optin);
21005
+ inst._zod.optin = "optional";
20806
21006
  defineLazy(inst._zod, "optout", () => def.innerType._zod.optout);
20807
21007
  defineLazy(inst._zod, "values", () => def.innerType._zod.values);
20808
21008
  inst._zod.parse = (payload, ctx) => {
@@ -20822,6 +21022,7 @@ var $ZodCatch = /* @__PURE__ */ $constructor("$ZodCatch", (inst, def) => {
20822
21022
  input: payload.value
20823
21023
  });
20824
21024
  payload.issues = [];
21025
+ payload.fallback = true;
20825
21026
  }
20826
21027
  return payload;
20827
21028
  });
@@ -20836,6 +21037,7 @@ var $ZodCatch = /* @__PURE__ */ $constructor("$ZodCatch", (inst, def) => {
20836
21037
  input: payload.value
20837
21038
  });
20838
21039
  payload.issues = [];
21040
+ payload.fallback = true;
20839
21041
  }
20840
21042
  return payload;
20841
21043
  };
@@ -20881,7 +21083,7 @@ function handlePipeResult(left, next, ctx) {
20881
21083
  left.aborted = true;
20882
21084
  return left;
20883
21085
  }
20884
- return next._zod.run({ value: left.value, issues: left.issues }, ctx);
21086
+ return next._zod.run({ value: left.value, issues: left.issues, fallback: left.fallback }, ctx);
20885
21087
  }
20886
21088
  var $ZodCodec = /* @__PURE__ */ $constructor("$ZodCodec", (inst, def) => {
20887
21089
  $ZodType.init(inst, def);
@@ -20933,6 +21135,9 @@ function handleCodecTxResult(left, value, nextSchema, ctx) {
20933
21135
  }
20934
21136
  return nextSchema._zod.run({ value, issues: left.issues }, ctx);
20935
21137
  }
21138
+ var $ZodPreprocess = /* @__PURE__ */ $constructor("$ZodPreprocess", (inst, def) => {
21139
+ $ZodPipe.init(inst, def);
21140
+ });
20936
21141
  var $ZodReadonly = /* @__PURE__ */ $constructor("$ZodReadonly", (inst, def) => {
20937
21142
  $ZodType.init(inst, def);
20938
21143
  defineLazy(inst._zod, "propValues", () => def.innerType._zod.propValues);
@@ -21084,7 +21289,12 @@ var $ZodPromise = /* @__PURE__ */ $constructor("$ZodPromise", (inst, def) => {
21084
21289
  });
21085
21290
  var $ZodLazy = /* @__PURE__ */ $constructor("$ZodLazy", (inst, def) => {
21086
21291
  $ZodType.init(inst, def);
21087
- defineLazy(inst._zod, "innerType", () => def.getter());
21292
+ defineLazy(inst._zod, "innerType", () => {
21293
+ const d = def;
21294
+ if (!d._cachedInner)
21295
+ d._cachedInner = def.getter();
21296
+ return d._cachedInner;
21297
+ });
21088
21298
  defineLazy(inst._zod, "pattern", () => inst._zod.innerType?._zod?.pattern);
21089
21299
  defineLazy(inst._zod, "propValues", () => inst._zod.innerType?._zod?.propValues);
21090
21300
  defineLazy(inst._zod, "optin", () => inst._zod.innerType?._zod?.optin ?? undefined);
@@ -21124,7 +21334,7 @@ function handleRefineResult(result, payload, input, inst) {
21124
21334
  payload.issues.push(issue(_iss));
21125
21335
  }
21126
21336
  }
21127
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/index.js
21337
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/index.js
21128
21338
  var exports_locales = {};
21129
21339
  __export(exports_locales, {
21130
21340
  zhTW: () => zh_TW_default,
@@ -21141,6 +21351,7 @@ __export(exports_locales, {
21141
21351
  sv: () => sv_default,
21142
21352
  sl: () => sl_default,
21143
21353
  ru: () => ru_default,
21354
+ ro: () => ro_default,
21144
21355
  pt: () => pt_default,
21145
21356
  ps: () => ps_default,
21146
21357
  pl: () => pl_default,
@@ -21160,6 +21371,7 @@ __export(exports_locales, {
21160
21371
  id: () => id_default,
21161
21372
  hy: () => hy_default,
21162
21373
  hu: () => hu_default,
21374
+ hr: () => hr_default,
21163
21375
  he: () => he_default,
21164
21376
  frCA: () => fr_CA_default,
21165
21377
  fr: () => fr_default,
@@ -21168,6 +21380,7 @@ __export(exports_locales, {
21168
21380
  es: () => es_default,
21169
21381
  eo: () => eo_default,
21170
21382
  en: () => en_default,
21383
+ el: () => el_default,
21171
21384
  de: () => de_default,
21172
21385
  da: () => da_default,
21173
21386
  cs: () => cs_default,
@@ -21178,7 +21391,7 @@ __export(exports_locales, {
21178
21391
  ar: () => ar_default
21179
21392
  });
21180
21393
 
21181
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ar.js
21394
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ar.js
21182
21395
  var error3 = () => {
21183
21396
  const Sizable = {
21184
21397
  string: { unit: "حرف", verb: "أن يحوي" },
@@ -21284,7 +21497,7 @@ function ar_default() {
21284
21497
  localeError: error3()
21285
21498
  };
21286
21499
  }
21287
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/az.js
21500
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/az.js
21288
21501
  var error4 = () => {
21289
21502
  const Sizable = {
21290
21503
  string: { unit: "simvol", verb: "olmalıdır" },
@@ -21389,7 +21602,7 @@ function az_default() {
21389
21602
  localeError: error4()
21390
21603
  };
21391
21604
  }
21392
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/be.js
21605
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/be.js
21393
21606
  function getBelarusianPlural(count, one, few, many) {
21394
21607
  const absCount = Math.abs(count);
21395
21608
  const lastDigit = absCount % 10;
@@ -21545,7 +21758,7 @@ function be_default() {
21545
21758
  localeError: error5()
21546
21759
  };
21547
21760
  }
21548
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/bg.js
21761
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/bg.js
21549
21762
  var error6 = () => {
21550
21763
  const Sizable = {
21551
21764
  string: { unit: "символа", verb: "да съдържа" },
@@ -21665,7 +21878,7 @@ function bg_default() {
21665
21878
  localeError: error6()
21666
21879
  };
21667
21880
  }
21668
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ca.js
21881
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ca.js
21669
21882
  var error7 = () => {
21670
21883
  const Sizable = {
21671
21884
  string: { unit: "caràcters", verb: "contenir" },
@@ -21772,7 +21985,7 @@ function ca_default() {
21772
21985
  localeError: error7()
21773
21986
  };
21774
21987
  }
21775
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/cs.js
21988
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/cs.js
21776
21989
  var error8 = () => {
21777
21990
  const Sizable = {
21778
21991
  string: { unit: "znaků", verb: "mít" },
@@ -21883,7 +22096,7 @@ function cs_default() {
21883
22096
  localeError: error8()
21884
22097
  };
21885
22098
  }
21886
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/da.js
22099
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/da.js
21887
22100
  var error9 = () => {
21888
22101
  const Sizable = {
21889
22102
  string: { unit: "tegn", verb: "havde" },
@@ -21998,7 +22211,7 @@ function da_default() {
21998
22211
  localeError: error9()
21999
22212
  };
22000
22213
  }
22001
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/de.js
22214
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/de.js
22002
22215
  var error10 = () => {
22003
22216
  const Sizable = {
22004
22217
  string: { unit: "Zeichen", verb: "zu haben" },
@@ -22106,8 +22319,117 @@ function de_default() {
22106
22319
  localeError: error10()
22107
22320
  };
22108
22321
  }
22109
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/en.js
22322
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/el.js
22110
22323
  var error11 = () => {
22324
+ const Sizable = {
22325
+ string: { unit: "χαρακτήρες", verb: "να έχει" },
22326
+ file: { unit: "bytes", verb: "να έχει" },
22327
+ array: { unit: "στοιχεία", verb: "να έχει" },
22328
+ set: { unit: "στοιχεία", verb: "να έχει" },
22329
+ map: { unit: "καταχωρήσεις", verb: "να έχει" }
22330
+ };
22331
+ function getSizing(origin) {
22332
+ return Sizable[origin] ?? null;
22333
+ }
22334
+ const FormatDictionary = {
22335
+ regex: "είσοδος",
22336
+ email: "διεύθυνση email",
22337
+ url: "URL",
22338
+ emoji: "emoji",
22339
+ uuid: "UUID",
22340
+ uuidv4: "UUIDv4",
22341
+ uuidv6: "UUIDv6",
22342
+ nanoid: "nanoid",
22343
+ guid: "GUID",
22344
+ cuid: "cuid",
22345
+ cuid2: "cuid2",
22346
+ ulid: "ULID",
22347
+ xid: "XID",
22348
+ ksuid: "KSUID",
22349
+ datetime: "ISO ημερομηνία και ώρα",
22350
+ date: "ISO ημερομηνία",
22351
+ time: "ISO ώρα",
22352
+ duration: "ISO διάρκεια",
22353
+ ipv4: "διεύθυνση IPv4",
22354
+ ipv6: "διεύθυνση IPv6",
22355
+ mac: "διεύθυνση MAC",
22356
+ cidrv4: "εύρος IPv4",
22357
+ cidrv6: "εύρος IPv6",
22358
+ base64: "συμβολοσειρά κωδικοποιημένη σε base64",
22359
+ base64url: "συμβολοσειρά κωδικοποιημένη σε base64url",
22360
+ json_string: "συμβολοσειρά JSON",
22361
+ e164: "αριθμός E.164",
22362
+ jwt: "JWT",
22363
+ template_literal: "είσοδος"
22364
+ };
22365
+ const TypeDictionary = {
22366
+ nan: "NaN"
22367
+ };
22368
+ return (issue2) => {
22369
+ switch (issue2.code) {
22370
+ case "invalid_type": {
22371
+ const expected = TypeDictionary[issue2.expected] ?? issue2.expected;
22372
+ const receivedType = parsedType(issue2.input);
22373
+ const received = TypeDictionary[receivedType] ?? receivedType;
22374
+ if (typeof issue2.expected === "string" && /^[A-Z]/.test(issue2.expected)) {
22375
+ return `Μη έγκυρη είσοδος: αναμενόταν instanceof ${issue2.expected}, λήφθηκε ${received}`;
22376
+ }
22377
+ return `Μη έγκυρη είσοδος: αναμενόταν ${expected}, λήφθηκε ${received}`;
22378
+ }
22379
+ case "invalid_value":
22380
+ if (issue2.values.length === 1)
22381
+ return `Μη έγκυρη είσοδος: αναμενόταν ${stringifyPrimitive(issue2.values[0])}`;
22382
+ return `Μη έγκυρη επιλογή: αναμενόταν ένα από ${joinValues(issue2.values, "|")}`;
22383
+ case "too_big": {
22384
+ const adj = issue2.inclusive ? "<=" : "<";
22385
+ const sizing = getSizing(issue2.origin);
22386
+ if (sizing)
22387
+ return `Πολύ μεγάλο: αναμενόταν ${issue2.origin ?? "τιμή"} να έχει ${adj}${issue2.maximum.toString()} ${sizing.unit ?? "στοιχεία"}`;
22388
+ return `Πολύ μεγάλο: αναμενόταν ${issue2.origin ?? "τιμή"} να είναι ${adj}${issue2.maximum.toString()}`;
22389
+ }
22390
+ case "too_small": {
22391
+ const adj = issue2.inclusive ? ">=" : ">";
22392
+ const sizing = getSizing(issue2.origin);
22393
+ if (sizing) {
22394
+ return `Πολύ μικρό: αναμενόταν ${issue2.origin} να έχει ${adj}${issue2.minimum.toString()} ${sizing.unit}`;
22395
+ }
22396
+ return `Πολύ μικρό: αναμενόταν ${issue2.origin} να είναι ${adj}${issue2.minimum.toString()}`;
22397
+ }
22398
+ case "invalid_format": {
22399
+ const _issue = issue2;
22400
+ if (_issue.format === "starts_with") {
22401
+ return `Μη έγκυρη συμβολοσειρά: πρέπει να ξεκινά με "${_issue.prefix}"`;
22402
+ }
22403
+ if (_issue.format === "ends_with")
22404
+ return `Μη έγκυρη συμβολοσειρά: πρέπει να τελειώνει με "${_issue.suffix}"`;
22405
+ if (_issue.format === "includes")
22406
+ return `Μη έγκυρη συμβολοσειρά: πρέπει να περιέχει "${_issue.includes}"`;
22407
+ if (_issue.format === "regex")
22408
+ return `Μη έγκυρη συμβολοσειρά: πρέπει να ταιριάζει με το μοτίβο ${_issue.pattern}`;
22409
+ return `Μη έγκυρο: ${FormatDictionary[_issue.format] ?? issue2.format}`;
22410
+ }
22411
+ case "not_multiple_of":
22412
+ return `Μη έγκυρος αριθμός: πρέπει να είναι πολλαπλάσιο του ${issue2.divisor}`;
22413
+ case "unrecognized_keys":
22414
+ return `Άγνωστ${issue2.keys.length > 1 ? "α" : "ο"} κλειδ${issue2.keys.length > 1 ? "ιά" : "ί"}: ${joinValues(issue2.keys, ", ")}`;
22415
+ case "invalid_key":
22416
+ return `Μη έγκυρο κλειδί στο ${issue2.origin}`;
22417
+ case "invalid_union":
22418
+ return "Μη έγκυρη είσοδος";
22419
+ case "invalid_element":
22420
+ return `Μη έγκυρη τιμή στο ${issue2.origin}`;
22421
+ default:
22422
+ return `Μη έγκυρη είσοδος`;
22423
+ }
22424
+ };
22425
+ };
22426
+ function el_default() {
22427
+ return {
22428
+ localeError: error11()
22429
+ };
22430
+ }
22431
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/en.js
22432
+ var error12 = () => {
22111
22433
  const Sizable = {
22112
22434
  string: { unit: "characters", verb: "to have" },
22113
22435
  file: { unit: "bytes", verb: "to have" },
@@ -22199,6 +22521,10 @@ var error11 = () => {
22199
22521
  case "invalid_key":
22200
22522
  return `Invalid key in ${issue2.origin}`;
22201
22523
  case "invalid_union":
22524
+ if (issue2.options && Array.isArray(issue2.options) && issue2.options.length > 0) {
22525
+ const opts = issue2.options.map((o) => `'${o}'`).join(" | ");
22526
+ return `Invalid discriminator value. Expected ${opts}`;
22527
+ }
22202
22528
  return "Invalid input";
22203
22529
  case "invalid_element":
22204
22530
  return `Invalid value in ${issue2.origin}`;
@@ -22209,11 +22535,11 @@ var error11 = () => {
22209
22535
  };
22210
22536
  function en_default() {
22211
22537
  return {
22212
- localeError: error11()
22538
+ localeError: error12()
22213
22539
  };
22214
22540
  }
22215
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/eo.js
22216
- var error12 = () => {
22541
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/eo.js
22542
+ var error13 = () => {
22217
22543
  const Sizable = {
22218
22544
  string: { unit: "karaktrojn", verb: "havi" },
22219
22545
  file: { unit: "bajtojn", verb: "havi" },
@@ -22318,11 +22644,11 @@ var error12 = () => {
22318
22644
  };
22319
22645
  function eo_default() {
22320
22646
  return {
22321
- localeError: error12()
22647
+ localeError: error13()
22322
22648
  };
22323
22649
  }
22324
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/es.js
22325
- var error13 = () => {
22650
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/es.js
22651
+ var error14 = () => {
22326
22652
  const Sizable = {
22327
22653
  string: { unit: "caracteres", verb: "tener" },
22328
22654
  file: { unit: "bytes", verb: "tener" },
@@ -22450,11 +22776,11 @@ var error13 = () => {
22450
22776
  };
22451
22777
  function es_default() {
22452
22778
  return {
22453
- localeError: error13()
22779
+ localeError: error14()
22454
22780
  };
22455
22781
  }
22456
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/fa.js
22457
- var error14 = () => {
22782
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/fa.js
22783
+ var error15 = () => {
22458
22784
  const Sizable = {
22459
22785
  string: { unit: "کاراکتر", verb: "داشته باشد" },
22460
22786
  file: { unit: "بایت", verb: "داشته باشد" },
@@ -22564,11 +22890,11 @@ var error14 = () => {
22564
22890
  };
22565
22891
  function fa_default() {
22566
22892
  return {
22567
- localeError: error14()
22893
+ localeError: error15()
22568
22894
  };
22569
22895
  }
22570
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/fi.js
22571
- var error15 = () => {
22896
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/fi.js
22897
+ var error16 = () => {
22572
22898
  const Sizable = {
22573
22899
  string: { unit: "merkkiä", subject: "merkkijonon" },
22574
22900
  file: { unit: "tavua", subject: "tiedoston" },
@@ -22676,11 +23002,11 @@ var error15 = () => {
22676
23002
  };
22677
23003
  function fi_default() {
22678
23004
  return {
22679
- localeError: error15()
23005
+ localeError: error16()
22680
23006
  };
22681
23007
  }
22682
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/fr.js
22683
- var error16 = () => {
23008
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/fr.js
23009
+ var error17 = () => {
22684
23010
  const Sizable = {
22685
23011
  string: { unit: "caractères", verb: "avoir" },
22686
23012
  file: { unit: "octets", verb: "avoir" },
@@ -22721,9 +23047,27 @@ var error16 = () => {
22721
23047
  template_literal: "entrée"
22722
23048
  };
22723
23049
  const TypeDictionary = {
22724
- nan: "NaN",
23050
+ string: "chaîne",
22725
23051
  number: "nombre",
22726
- array: "tableau"
23052
+ int: "entier",
23053
+ boolean: "booléen",
23054
+ bigint: "grand entier",
23055
+ symbol: "symbole",
23056
+ undefined: "indéfini",
23057
+ null: "null",
23058
+ never: "jamais",
23059
+ void: "vide",
23060
+ date: "date",
23061
+ array: "tableau",
23062
+ object: "objet",
23063
+ tuple: "tuple",
23064
+ record: "enregistrement",
23065
+ map: "carte",
23066
+ set: "ensemble",
23067
+ file: "fichier",
23068
+ nonoptional: "non-optionnel",
23069
+ nan: "NaN",
23070
+ function: "fonction"
22727
23071
  };
22728
23072
  return (issue2) => {
22729
23073
  switch (issue2.code) {
@@ -22744,16 +23088,15 @@ var error16 = () => {
22744
23088
  const adj = issue2.inclusive ? "<=" : "<";
22745
23089
  const sizing = getSizing(issue2.origin);
22746
23090
  if (sizing)
22747
- return `Trop grand : ${issue2.origin ?? "valeur"} doit ${sizing.verb} ${adj}${issue2.maximum.toString()} ${sizing.unit ?? "élément(s)"}`;
22748
- return `Trop grand : ${issue2.origin ?? "valeur"} doit être ${adj}${issue2.maximum.toString()}`;
23091
+ return `Trop grand : ${TypeDictionary[issue2.origin] ?? "valeur"} doit ${sizing.verb} ${adj}${issue2.maximum.toString()} ${sizing.unit ?? "élément(s)"}`;
23092
+ return `Trop grand : ${TypeDictionary[issue2.origin] ?? "valeur"} doit être ${adj}${issue2.maximum.toString()}`;
22749
23093
  }
22750
23094
  case "too_small": {
22751
23095
  const adj = issue2.inclusive ? ">=" : ">";
22752
23096
  const sizing = getSizing(issue2.origin);
22753
- if (sizing) {
22754
- return `Trop petit : ${issue2.origin} doit ${sizing.verb} ${adj}${issue2.minimum.toString()} ${sizing.unit}`;
22755
- }
22756
- return `Trop petit : ${issue2.origin} doit être ${adj}${issue2.minimum.toString()}`;
23097
+ if (sizing)
23098
+ return `Trop petit : ${TypeDictionary[issue2.origin] ?? "valeur"} doit ${sizing.verb} ${adj}${issue2.minimum.toString()} ${sizing.unit}`;
23099
+ return `Trop petit : ${TypeDictionary[issue2.origin] ?? "valeur"} doit être ${adj}${issue2.minimum.toString()}`;
22757
23100
  }
22758
23101
  case "invalid_format": {
22759
23102
  const _issue = issue2;
@@ -22784,11 +23127,11 @@ var error16 = () => {
22784
23127
  };
22785
23128
  function fr_default() {
22786
23129
  return {
22787
- localeError: error16()
23130
+ localeError: error17()
22788
23131
  };
22789
23132
  }
22790
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/fr-CA.js
22791
- var error17 = () => {
23133
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/fr-CA.js
23134
+ var error18 = () => {
22792
23135
  const Sizable = {
22793
23136
  string: { unit: "caractères", verb: "avoir" },
22794
23137
  file: { unit: "octets", verb: "avoir" },
@@ -22891,11 +23234,11 @@ var error17 = () => {
22891
23234
  };
22892
23235
  function fr_CA_default() {
22893
23236
  return {
22894
- localeError: error17()
23237
+ localeError: error18()
22895
23238
  };
22896
23239
  }
22897
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/he.js
22898
- var error18 = () => {
23240
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/he.js
23241
+ var error19 = () => {
22899
23242
  const TypeNames = {
22900
23243
  string: { label: "מחרוזת", gender: "f" },
22901
23244
  number: { label: "מספר", gender: "m" },
@@ -23084,11 +23427,133 @@ var error18 = () => {
23084
23427
  };
23085
23428
  function he_default() {
23086
23429
  return {
23087
- localeError: error18()
23430
+ localeError: error19()
23088
23431
  };
23089
23432
  }
23090
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/hu.js
23091
- var error19 = () => {
23433
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/hr.js
23434
+ var error20 = () => {
23435
+ const Sizable = {
23436
+ string: { unit: "znakova", verb: "imati" },
23437
+ file: { unit: "bajtova", verb: "imati" },
23438
+ array: { unit: "stavki", verb: "imati" },
23439
+ set: { unit: "stavki", verb: "imati" }
23440
+ };
23441
+ function getSizing(origin) {
23442
+ return Sizable[origin] ?? null;
23443
+ }
23444
+ const FormatDictionary = {
23445
+ regex: "unos",
23446
+ email: "email adresa",
23447
+ url: "URL",
23448
+ emoji: "emoji",
23449
+ uuid: "UUID",
23450
+ uuidv4: "UUIDv4",
23451
+ uuidv6: "UUIDv6",
23452
+ nanoid: "nanoid",
23453
+ guid: "GUID",
23454
+ cuid: "cuid",
23455
+ cuid2: "cuid2",
23456
+ ulid: "ULID",
23457
+ xid: "XID",
23458
+ ksuid: "KSUID",
23459
+ datetime: "ISO datum i vrijeme",
23460
+ date: "ISO datum",
23461
+ time: "ISO vrijeme",
23462
+ duration: "ISO trajanje",
23463
+ ipv4: "IPv4 adresa",
23464
+ ipv6: "IPv6 adresa",
23465
+ cidrv4: "IPv4 raspon",
23466
+ cidrv6: "IPv6 raspon",
23467
+ base64: "base64 kodirani tekst",
23468
+ base64url: "base64url kodirani tekst",
23469
+ json_string: "JSON tekst",
23470
+ e164: "E.164 broj",
23471
+ jwt: "JWT",
23472
+ template_literal: "unos"
23473
+ };
23474
+ const TypeDictionary = {
23475
+ nan: "NaN",
23476
+ string: "tekst",
23477
+ number: "broj",
23478
+ boolean: "boolean",
23479
+ array: "niz",
23480
+ object: "objekt",
23481
+ set: "skup",
23482
+ file: "datoteka",
23483
+ date: "datum",
23484
+ bigint: "bigint",
23485
+ symbol: "simbol",
23486
+ undefined: "undefined",
23487
+ null: "null",
23488
+ function: "funkcija",
23489
+ map: "mapa"
23490
+ };
23491
+ return (issue2) => {
23492
+ switch (issue2.code) {
23493
+ case "invalid_type": {
23494
+ const expected = TypeDictionary[issue2.expected] ?? issue2.expected;
23495
+ const receivedType = parsedType(issue2.input);
23496
+ const received = TypeDictionary[receivedType] ?? receivedType;
23497
+ if (/^[A-Z]/.test(issue2.expected)) {
23498
+ return `Neispravan unos: očekuje se instanceof ${issue2.expected}, a primljeno je ${received}`;
23499
+ }
23500
+ return `Neispravan unos: očekuje se ${expected}, a primljeno je ${received}`;
23501
+ }
23502
+ case "invalid_value":
23503
+ if (issue2.values.length === 1)
23504
+ return `Neispravna vrijednost: očekivano ${stringifyPrimitive(issue2.values[0])}`;
23505
+ return `Neispravna opcija: očekivano jedno od ${joinValues(issue2.values, "|")}`;
23506
+ case "too_big": {
23507
+ const adj = issue2.inclusive ? "<=" : "<";
23508
+ const sizing = getSizing(issue2.origin);
23509
+ const origin = TypeDictionary[issue2.origin] ?? issue2.origin;
23510
+ if (sizing)
23511
+ return `Preveliko: očekivano da ${origin ?? "vrijednost"} ima ${adj}${issue2.maximum.toString()} ${sizing.unit ?? "elemenata"}`;
23512
+ return `Preveliko: očekivano da ${origin ?? "vrijednost"} bude ${adj}${issue2.maximum.toString()}`;
23513
+ }
23514
+ case "too_small": {
23515
+ const adj = issue2.inclusive ? ">=" : ">";
23516
+ const sizing = getSizing(issue2.origin);
23517
+ const origin = TypeDictionary[issue2.origin] ?? issue2.origin;
23518
+ if (sizing) {
23519
+ return `Premalo: očekivano da ${origin} ima ${adj}${issue2.minimum.toString()} ${sizing.unit}`;
23520
+ }
23521
+ return `Premalo: očekivano da ${origin} bude ${adj}${issue2.minimum.toString()}`;
23522
+ }
23523
+ case "invalid_format": {
23524
+ const _issue = issue2;
23525
+ if (_issue.format === "starts_with")
23526
+ return `Neispravan tekst: mora započinjati s "${_issue.prefix}"`;
23527
+ if (_issue.format === "ends_with")
23528
+ return `Neispravan tekst: mora završavati s "${_issue.suffix}"`;
23529
+ if (_issue.format === "includes")
23530
+ return `Neispravan tekst: mora sadržavati "${_issue.includes}"`;
23531
+ if (_issue.format === "regex")
23532
+ return `Neispravan tekst: mora odgovarati uzorku ${_issue.pattern}`;
23533
+ return `Neispravna ${FormatDictionary[_issue.format] ?? issue2.format}`;
23534
+ }
23535
+ case "not_multiple_of":
23536
+ return `Neispravan broj: mora biti višekratnik od ${issue2.divisor}`;
23537
+ case "unrecognized_keys":
23538
+ return `Neprepoznat${issue2.keys.length > 1 ? "i ključevi" : " ključ"}: ${joinValues(issue2.keys, ", ")}`;
23539
+ case "invalid_key":
23540
+ return `Neispravan ključ u ${TypeDictionary[issue2.origin] ?? issue2.origin}`;
23541
+ case "invalid_union":
23542
+ return "Neispravan unos";
23543
+ case "invalid_element":
23544
+ return `Neispravna vrijednost u ${TypeDictionary[issue2.origin] ?? issue2.origin}`;
23545
+ default:
23546
+ return `Neispravan unos`;
23547
+ }
23548
+ };
23549
+ };
23550
+ function hr_default() {
23551
+ return {
23552
+ localeError: error20()
23553
+ };
23554
+ }
23555
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/hu.js
23556
+ var error21 = () => {
23092
23557
  const Sizable = {
23093
23558
  string: { unit: "karakter", verb: "legyen" },
23094
23559
  file: { unit: "byte", verb: "legyen" },
@@ -23192,10 +23657,10 @@ var error19 = () => {
23192
23657
  };
23193
23658
  function hu_default() {
23194
23659
  return {
23195
- localeError: error19()
23660
+ localeError: error21()
23196
23661
  };
23197
23662
  }
23198
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/hy.js
23663
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/hy.js
23199
23664
  function getArmenianPlural(count, one, many) {
23200
23665
  return Math.abs(count) === 1 ? one : many;
23201
23666
  }
@@ -23206,7 +23671,7 @@ function withDefiniteArticle(word) {
23206
23671
  const lastChar = word[word.length - 1];
23207
23672
  return word + (vowels.includes(lastChar) ? "ն" : "ը");
23208
23673
  }
23209
- var error20 = () => {
23674
+ var error22 = () => {
23210
23675
  const Sizable = {
23211
23676
  string: {
23212
23677
  unit: {
@@ -23339,11 +23804,11 @@ var error20 = () => {
23339
23804
  };
23340
23805
  function hy_default() {
23341
23806
  return {
23342
- localeError: error20()
23807
+ localeError: error22()
23343
23808
  };
23344
23809
  }
23345
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/id.js
23346
- var error21 = () => {
23810
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/id.js
23811
+ var error23 = () => {
23347
23812
  const Sizable = {
23348
23813
  string: { unit: "karakter", verb: "memiliki" },
23349
23814
  file: { unit: "byte", verb: "memiliki" },
@@ -23445,11 +23910,11 @@ var error21 = () => {
23445
23910
  };
23446
23911
  function id_default() {
23447
23912
  return {
23448
- localeError: error21()
23913
+ localeError: error23()
23449
23914
  };
23450
23915
  }
23451
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/is.js
23452
- var error22 = () => {
23916
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/is.js
23917
+ var error24 = () => {
23453
23918
  const Sizable = {
23454
23919
  string: { unit: "stafi", verb: "að hafa" },
23455
23920
  file: { unit: "bæti", verb: "að hafa" },
@@ -23554,11 +24019,11 @@ var error22 = () => {
23554
24019
  };
23555
24020
  function is_default() {
23556
24021
  return {
23557
- localeError: error22()
24022
+ localeError: error24()
23558
24023
  };
23559
24024
  }
23560
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/it.js
23561
- var error23 = () => {
24025
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/it.js
24026
+ var error25 = () => {
23562
24027
  const Sizable = {
23563
24028
  string: { unit: "caratteri", verb: "avere" },
23564
24029
  file: { unit: "byte", verb: "avere" },
@@ -23643,7 +24108,7 @@ var error23 = () => {
23643
24108
  return `Stringa non valida: deve includere "${_issue.includes}"`;
23644
24109
  if (_issue.format === "regex")
23645
24110
  return `Stringa non valida: deve corrispondere al pattern ${_issue.pattern}`;
23646
- return `Invalid ${FormatDictionary[_issue.format] ?? issue2.format}`;
24111
+ return `Input non valido: ${FormatDictionary[_issue.format] ?? issue2.format}`;
23647
24112
  }
23648
24113
  case "not_multiple_of":
23649
24114
  return `Numero non valido: deve essere un multiplo di ${issue2.divisor}`;
@@ -23662,11 +24127,11 @@ var error23 = () => {
23662
24127
  };
23663
24128
  function it_default() {
23664
24129
  return {
23665
- localeError: error23()
24130
+ localeError: error25()
23666
24131
  };
23667
24132
  }
23668
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ja.js
23669
- var error24 = () => {
24133
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ja.js
24134
+ var error26 = () => {
23670
24135
  const Sizable = {
23671
24136
  string: { unit: "文字", verb: "である" },
23672
24137
  file: { unit: "バイト", verb: "である" },
@@ -23769,11 +24234,11 @@ var error24 = () => {
23769
24234
  };
23770
24235
  function ja_default() {
23771
24236
  return {
23772
- localeError: error24()
24237
+ localeError: error26()
23773
24238
  };
23774
24239
  }
23775
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ka.js
23776
- var error25 = () => {
24240
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ka.js
24241
+ var error27 = () => {
23777
24242
  const Sizable = {
23778
24243
  string: { unit: "სიმბოლო", verb: "უნდა შეიცავდეს" },
23779
24244
  file: { unit: "ბაიტი", verb: "უნდა შეიცავდეს" },
@@ -23806,9 +24271,9 @@ var error25 = () => {
23806
24271
  ipv6: "IPv6 მისამართი",
23807
24272
  cidrv4: "IPv4 დიაპაზონი",
23808
24273
  cidrv6: "IPv6 დიაპაზონი",
23809
- base64: "base64-კოდირებული სტრინგი",
23810
- base64url: "base64url-კოდირებული სტრინგი",
23811
- json_string: "JSON სტრინგი",
24274
+ base64: "base64-კოდირებული ველი",
24275
+ base64url: "base64url-კოდირებული ველი",
24276
+ json_string: "JSON ველი",
23812
24277
  e164: "E.164 ნომერი",
23813
24278
  jwt: "JWT",
23814
24279
  template_literal: "შეყვანა"
@@ -23816,7 +24281,7 @@ var error25 = () => {
23816
24281
  const TypeDictionary = {
23817
24282
  nan: "NaN",
23818
24283
  number: "რიცხვი",
23819
- string: "სტრინგი",
24284
+ string: "ველი",
23820
24285
  boolean: "ბულეანი",
23821
24286
  function: "ფუნქცია",
23822
24287
  array: "მასივი"
@@ -23854,14 +24319,14 @@ var error25 = () => {
23854
24319
  case "invalid_format": {
23855
24320
  const _issue = issue2;
23856
24321
  if (_issue.format === "starts_with") {
23857
- return `არასწორი სტრინგი: უნდა იწყებოდეს "${_issue.prefix}"-ით`;
24322
+ return `არასწორი ველი: უნდა იწყებოდეს "${_issue.prefix}"-ით`;
23858
24323
  }
23859
24324
  if (_issue.format === "ends_with")
23860
- return `არასწორი სტრინგი: უნდა მთავრდებოდეს "${_issue.suffix}"-ით`;
24325
+ return `არასწორი ველი: უნდა მთავრდებოდეს "${_issue.suffix}"-ით`;
23861
24326
  if (_issue.format === "includes")
23862
- return `არასწორი სტრინგი: უნდა შეიცავდეს "${_issue.includes}"-ს`;
24327
+ return `არასწორი ველი: უნდა შეიცავდეს "${_issue.includes}"-ს`;
23863
24328
  if (_issue.format === "regex")
23864
- return `არასწორი სტრინგი: უნდა შეესაბამებოდეს შაბლონს ${_issue.pattern}`;
24329
+ return `არასწორი ველი: უნდა შეესაბამებოდეს შაბლონს ${_issue.pattern}`;
23865
24330
  return `არასწორი ${FormatDictionary[_issue.format] ?? issue2.format}`;
23866
24331
  }
23867
24332
  case "not_multiple_of":
@@ -23881,11 +24346,11 @@ var error25 = () => {
23881
24346
  };
23882
24347
  function ka_default() {
23883
24348
  return {
23884
- localeError: error25()
24349
+ localeError: error27()
23885
24350
  };
23886
24351
  }
23887
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/km.js
23888
- var error26 = () => {
24352
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/km.js
24353
+ var error28 = () => {
23889
24354
  const Sizable = {
23890
24355
  string: { unit: "តួអក្សរ", verb: "គួរមាន" },
23891
24356
  file: { unit: "បៃ", verb: "គួរមាន" },
@@ -23991,16 +24456,16 @@ var error26 = () => {
23991
24456
  };
23992
24457
  function km_default() {
23993
24458
  return {
23994
- localeError: error26()
24459
+ localeError: error28()
23995
24460
  };
23996
24461
  }
23997
24462
 
23998
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/kh.js
24463
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/kh.js
23999
24464
  function kh_default() {
24000
24465
  return km_default();
24001
24466
  }
24002
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ko.js
24003
- var error27 = () => {
24467
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ko.js
24468
+ var error29 = () => {
24004
24469
  const Sizable = {
24005
24470
  string: { unit: "문자", verb: "to have" },
24006
24471
  file: { unit: "바이트", verb: "to have" },
@@ -24107,10 +24572,10 @@ var error27 = () => {
24107
24572
  };
24108
24573
  function ko_default() {
24109
24574
  return {
24110
- localeError: error27()
24575
+ localeError: error29()
24111
24576
  };
24112
24577
  }
24113
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/lt.js
24578
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/lt.js
24114
24579
  var capitalizeFirstCharacter = (text) => {
24115
24580
  return text.charAt(0).toUpperCase() + text.slice(1);
24116
24581
  };
@@ -24124,7 +24589,7 @@ function getUnitTypeFromNumber(number2) {
24124
24589
  return "one";
24125
24590
  return "few";
24126
24591
  }
24127
- var error28 = () => {
24592
+ var error30 = () => {
24128
24593
  const Sizable = {
24129
24594
  string: {
24130
24595
  unit: {
@@ -24310,11 +24775,11 @@ var error28 = () => {
24310
24775
  };
24311
24776
  function lt_default() {
24312
24777
  return {
24313
- localeError: error28()
24778
+ localeError: error30()
24314
24779
  };
24315
24780
  }
24316
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/mk.js
24317
- var error29 = () => {
24781
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/mk.js
24782
+ var error31 = () => {
24318
24783
  const Sizable = {
24319
24784
  string: { unit: "знаци", verb: "да имаат" },
24320
24785
  file: { unit: "бајти", verb: "да имаат" },
@@ -24419,11 +24884,11 @@ var error29 = () => {
24419
24884
  };
24420
24885
  function mk_default() {
24421
24886
  return {
24422
- localeError: error29()
24887
+ localeError: error31()
24423
24888
  };
24424
24889
  }
24425
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ms.js
24426
- var error30 = () => {
24890
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ms.js
24891
+ var error32 = () => {
24427
24892
  const Sizable = {
24428
24893
  string: { unit: "aksara", verb: "mempunyai" },
24429
24894
  file: { unit: "bait", verb: "mempunyai" },
@@ -24526,11 +24991,11 @@ var error30 = () => {
24526
24991
  };
24527
24992
  function ms_default() {
24528
24993
  return {
24529
- localeError: error30()
24994
+ localeError: error32()
24530
24995
  };
24531
24996
  }
24532
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/nl.js
24533
- var error31 = () => {
24997
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/nl.js
24998
+ var error33 = () => {
24534
24999
  const Sizable = {
24535
25000
  string: { unit: "tekens", verb: "heeft" },
24536
25001
  file: { unit: "bytes", verb: "heeft" },
@@ -24636,11 +25101,11 @@ var error31 = () => {
24636
25101
  };
24637
25102
  function nl_default() {
24638
25103
  return {
24639
- localeError: error31()
25104
+ localeError: error33()
24640
25105
  };
24641
25106
  }
24642
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/no.js
24643
- var error32 = () => {
25107
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/no.js
25108
+ var error34 = () => {
24644
25109
  const Sizable = {
24645
25110
  string: { unit: "tegn", verb: "å ha" },
24646
25111
  file: { unit: "bytes", verb: "å ha" },
@@ -24744,11 +25209,11 @@ var error32 = () => {
24744
25209
  };
24745
25210
  function no_default() {
24746
25211
  return {
24747
- localeError: error32()
25212
+ localeError: error34()
24748
25213
  };
24749
25214
  }
24750
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ota.js
24751
- var error33 = () => {
25215
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ota.js
25216
+ var error35 = () => {
24752
25217
  const Sizable = {
24753
25218
  string: { unit: "harf", verb: "olmalıdır" },
24754
25219
  file: { unit: "bayt", verb: "olmalıdır" },
@@ -24853,11 +25318,11 @@ var error33 = () => {
24853
25318
  };
24854
25319
  function ota_default() {
24855
25320
  return {
24856
- localeError: error33()
25321
+ localeError: error35()
24857
25322
  };
24858
25323
  }
24859
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ps.js
24860
- var error34 = () => {
25324
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ps.js
25325
+ var error36 = () => {
24861
25326
  const Sizable = {
24862
25327
  string: { unit: "توکي", verb: "ولري" },
24863
25328
  file: { unit: "بایټس", verb: "ولري" },
@@ -24967,11 +25432,11 @@ var error34 = () => {
24967
25432
  };
24968
25433
  function ps_default() {
24969
25434
  return {
24970
- localeError: error34()
25435
+ localeError: error36()
24971
25436
  };
24972
25437
  }
24973
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/pl.js
24974
- var error35 = () => {
25438
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/pl.js
25439
+ var error37 = () => {
24975
25440
  const Sizable = {
24976
25441
  string: { unit: "znaków", verb: "mieć" },
24977
25442
  file: { unit: "bajtów", verb: "mieć" },
@@ -25070,29 +25535,138 @@ var error35 = () => {
25070
25535
  case "invalid_element":
25071
25536
  return `Nieprawidłowa wartość w ${issue2.origin}`;
25072
25537
  default:
25073
- return `Nieprawidłowe dane wejściowe`;
25538
+ return `Nieprawidłowe dane wejściowe`;
25539
+ }
25540
+ };
25541
+ };
25542
+ function pl_default() {
25543
+ return {
25544
+ localeError: error37()
25545
+ };
25546
+ }
25547
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/pt.js
25548
+ var error38 = () => {
25549
+ const Sizable = {
25550
+ string: { unit: "caracteres", verb: "ter" },
25551
+ file: { unit: "bytes", verb: "ter" },
25552
+ array: { unit: "itens", verb: "ter" },
25553
+ set: { unit: "itens", verb: "ter" }
25554
+ };
25555
+ function getSizing(origin) {
25556
+ return Sizable[origin] ?? null;
25557
+ }
25558
+ const FormatDictionary = {
25559
+ regex: "padrão",
25560
+ email: "endereço de e-mail",
25561
+ url: "URL",
25562
+ emoji: "emoji",
25563
+ uuid: "UUID",
25564
+ uuidv4: "UUIDv4",
25565
+ uuidv6: "UUIDv6",
25566
+ nanoid: "nanoid",
25567
+ guid: "GUID",
25568
+ cuid: "cuid",
25569
+ cuid2: "cuid2",
25570
+ ulid: "ULID",
25571
+ xid: "XID",
25572
+ ksuid: "KSUID",
25573
+ datetime: "data e hora ISO",
25574
+ date: "data ISO",
25575
+ time: "hora ISO",
25576
+ duration: "duração ISO",
25577
+ ipv4: "endereço IPv4",
25578
+ ipv6: "endereço IPv6",
25579
+ cidrv4: "faixa de IPv4",
25580
+ cidrv6: "faixa de IPv6",
25581
+ base64: "texto codificado em base64",
25582
+ base64url: "URL codificada em base64",
25583
+ json_string: "texto JSON",
25584
+ e164: "número E.164",
25585
+ jwt: "JWT",
25586
+ template_literal: "entrada"
25587
+ };
25588
+ const TypeDictionary = {
25589
+ nan: "NaN",
25590
+ number: "número",
25591
+ null: "nulo"
25592
+ };
25593
+ return (issue2) => {
25594
+ switch (issue2.code) {
25595
+ case "invalid_type": {
25596
+ const expected = TypeDictionary[issue2.expected] ?? issue2.expected;
25597
+ const receivedType = parsedType(issue2.input);
25598
+ const received = TypeDictionary[receivedType] ?? receivedType;
25599
+ if (/^[A-Z]/.test(issue2.expected)) {
25600
+ return `Tipo inválido: esperado instanceof ${issue2.expected}, recebido ${received}`;
25601
+ }
25602
+ return `Tipo inválido: esperado ${expected}, recebido ${received}`;
25603
+ }
25604
+ case "invalid_value":
25605
+ if (issue2.values.length === 1)
25606
+ return `Entrada inválida: esperado ${stringifyPrimitive(issue2.values[0])}`;
25607
+ return `Opção inválida: esperada uma das ${joinValues(issue2.values, "|")}`;
25608
+ case "too_big": {
25609
+ const adj = issue2.inclusive ? "<=" : "<";
25610
+ const sizing = getSizing(issue2.origin);
25611
+ if (sizing)
25612
+ return `Muito grande: esperado que ${issue2.origin ?? "valor"} tivesse ${adj}${issue2.maximum.toString()} ${sizing.unit ?? "elementos"}`;
25613
+ return `Muito grande: esperado que ${issue2.origin ?? "valor"} fosse ${adj}${issue2.maximum.toString()}`;
25614
+ }
25615
+ case "too_small": {
25616
+ const adj = issue2.inclusive ? ">=" : ">";
25617
+ const sizing = getSizing(issue2.origin);
25618
+ if (sizing) {
25619
+ return `Muito pequeno: esperado que ${issue2.origin} tivesse ${adj}${issue2.minimum.toString()} ${sizing.unit}`;
25620
+ }
25621
+ return `Muito pequeno: esperado que ${issue2.origin} fosse ${adj}${issue2.minimum.toString()}`;
25622
+ }
25623
+ case "invalid_format": {
25624
+ const _issue = issue2;
25625
+ if (_issue.format === "starts_with")
25626
+ return `Texto inválido: deve começar com "${_issue.prefix}"`;
25627
+ if (_issue.format === "ends_with")
25628
+ return `Texto inválido: deve terminar com "${_issue.suffix}"`;
25629
+ if (_issue.format === "includes")
25630
+ return `Texto inválido: deve incluir "${_issue.includes}"`;
25631
+ if (_issue.format === "regex")
25632
+ return `Texto inválido: deve corresponder ao padrão ${_issue.pattern}`;
25633
+ return `${FormatDictionary[_issue.format] ?? issue2.format} inválido`;
25634
+ }
25635
+ case "not_multiple_of":
25636
+ return `Número inválido: deve ser múltiplo de ${issue2.divisor}`;
25637
+ case "unrecognized_keys":
25638
+ return `Chave${issue2.keys.length > 1 ? "s" : ""} desconhecida${issue2.keys.length > 1 ? "s" : ""}: ${joinValues(issue2.keys, ", ")}`;
25639
+ case "invalid_key":
25640
+ return `Chave inválida em ${issue2.origin}`;
25641
+ case "invalid_union":
25642
+ return "Entrada inválida";
25643
+ case "invalid_element":
25644
+ return `Valor inválido em ${issue2.origin}`;
25645
+ default:
25646
+ return `Campo inválido`;
25074
25647
  }
25075
25648
  };
25076
25649
  };
25077
- function pl_default() {
25650
+ function pt_default() {
25078
25651
  return {
25079
- localeError: error35()
25652
+ localeError: error38()
25080
25653
  };
25081
25654
  }
25082
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/pt.js
25083
- var error36 = () => {
25655
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ro.js
25656
+ var error39 = () => {
25084
25657
  const Sizable = {
25085
- string: { unit: "caracteres", verb: "ter" },
25086
- file: { unit: "bytes", verb: "ter" },
25087
- array: { unit: "itens", verb: "ter" },
25088
- set: { unit: "itens", verb: "ter" }
25658
+ string: { unit: "caractere", verb: "să aibă" },
25659
+ file: { unit: "octeți", verb: "să aibă" },
25660
+ array: { unit: "elemente", verb: "să aibă" },
25661
+ set: { unit: "elemente", verb: "să aibă" },
25662
+ map: { unit: "intrări", verb: "să aibă" }
25089
25663
  };
25090
25664
  function getSizing(origin) {
25091
25665
  return Sizable[origin] ?? null;
25092
25666
  }
25093
25667
  const FormatDictionary = {
25094
- regex: "padrão",
25095
- email: "endereço de e-mail",
25668
+ regex: "intrare",
25669
+ email: "adresă de email",
25096
25670
  url: "URL",
25097
25671
  emoji: "emoji",
25098
25672
  uuid: "UUID",
@@ -25105,25 +25679,37 @@ var error36 = () => {
25105
25679
  ulid: "ULID",
25106
25680
  xid: "XID",
25107
25681
  ksuid: "KSUID",
25108
- datetime: "data e hora ISO",
25109
- date: "data ISO",
25110
- time: "hora ISO",
25111
- duration: "duração ISO",
25112
- ipv4: "endereço IPv4",
25113
- ipv6: "endereço IPv6",
25114
- cidrv4: "faixa de IPv4",
25115
- cidrv6: "faixa de IPv6",
25116
- base64: "texto codificado em base64",
25117
- base64url: "URL codificada em base64",
25118
- json_string: "texto JSON",
25119
- e164: "número E.164",
25682
+ datetime: "dată și oră ISO",
25683
+ date: "dată ISO",
25684
+ time: "oră ISO",
25685
+ duration: "durată ISO",
25686
+ ipv4: "adresă IPv4",
25687
+ ipv6: "adresă IPv6",
25688
+ mac: "adresă MAC",
25689
+ cidrv4: "interval IPv4",
25690
+ cidrv6: "interval IPv6",
25691
+ base64: "șir codat base64",
25692
+ base64url: "șir codat base64url",
25693
+ json_string: "șir JSON",
25694
+ e164: "număr E.164",
25120
25695
  jwt: "JWT",
25121
- template_literal: "entrada"
25696
+ template_literal: "intrare"
25122
25697
  };
25123
25698
  const TypeDictionary = {
25124
25699
  nan: "NaN",
25125
- number: "número",
25126
- null: "nulo"
25700
+ string: "șir",
25701
+ number: "număr",
25702
+ boolean: "boolean",
25703
+ function: "funcție",
25704
+ array: "matrice",
25705
+ object: "obiect",
25706
+ undefined: "nedefinit",
25707
+ symbol: "simbol",
25708
+ bigint: "număr mare",
25709
+ void: "void",
25710
+ never: "never",
25711
+ map: "hartă",
25712
+ set: "set"
25127
25713
  };
25128
25714
  return (issue2) => {
25129
25715
  switch (issue2.code) {
@@ -25131,63 +25717,61 @@ var error36 = () => {
25131
25717
  const expected = TypeDictionary[issue2.expected] ?? issue2.expected;
25132
25718
  const receivedType = parsedType(issue2.input);
25133
25719
  const received = TypeDictionary[receivedType] ?? receivedType;
25134
- if (/^[A-Z]/.test(issue2.expected)) {
25135
- return `Tipo inválido: esperado instanceof ${issue2.expected}, recebido ${received}`;
25136
- }
25137
- return `Tipo inválido: esperado ${expected}, recebido ${received}`;
25720
+ return `Intrare invalidă: așteptat ${expected}, primit ${received}`;
25138
25721
  }
25139
25722
  case "invalid_value":
25140
25723
  if (issue2.values.length === 1)
25141
- return `Entrada inválida: esperado ${stringifyPrimitive(issue2.values[0])}`;
25142
- return `Opção inválida: esperada uma das ${joinValues(issue2.values, "|")}`;
25724
+ return `Intrare invalidă: așteptat ${stringifyPrimitive(issue2.values[0])}`;
25725
+ return `Opțiune invalidă: așteptat una dintre ${joinValues(issue2.values, "|")}`;
25143
25726
  case "too_big": {
25144
25727
  const adj = issue2.inclusive ? "<=" : "<";
25145
25728
  const sizing = getSizing(issue2.origin);
25146
25729
  if (sizing)
25147
- return `Muito grande: esperado que ${issue2.origin ?? "valor"} tivesse ${adj}${issue2.maximum.toString()} ${sizing.unit ?? "elementos"}`;
25148
- return `Muito grande: esperado que ${issue2.origin ?? "valor"} fosse ${adj}${issue2.maximum.toString()}`;
25730
+ return `Prea mare: așteptat ca ${issue2.origin ?? "valoarea"} ${sizing.verb} ${adj}${issue2.maximum.toString()} ${sizing.unit ?? "elemente"}`;
25731
+ return `Prea mare: așteptat ca ${issue2.origin ?? "valoarea"} fie ${adj}${issue2.maximum.toString()}`;
25149
25732
  }
25150
25733
  case "too_small": {
25151
25734
  const adj = issue2.inclusive ? ">=" : ">";
25152
25735
  const sizing = getSizing(issue2.origin);
25153
25736
  if (sizing) {
25154
- return `Muito pequeno: esperado que ${issue2.origin} tivesse ${adj}${issue2.minimum.toString()} ${sizing.unit}`;
25737
+ return `Prea mic: așteptat ca ${issue2.origin} ${sizing.verb} ${adj}${issue2.minimum.toString()} ${sizing.unit}`;
25155
25738
  }
25156
- return `Muito pequeno: esperado que ${issue2.origin} fosse ${adj}${issue2.minimum.toString()}`;
25739
+ return `Prea mic: așteptat ca ${issue2.origin} fie ${adj}${issue2.minimum.toString()}`;
25157
25740
  }
25158
25741
  case "invalid_format": {
25159
25742
  const _issue = issue2;
25160
- if (_issue.format === "starts_with")
25161
- return `Texto inválido: deve começar com "${_issue.prefix}"`;
25743
+ if (_issue.format === "starts_with") {
25744
+ return `Șir invalid: trebuie înceapă cu "${_issue.prefix}"`;
25745
+ }
25162
25746
  if (_issue.format === "ends_with")
25163
- return `Texto inválido: deve terminar com "${_issue.suffix}"`;
25747
+ return `Șir invalid: trebuie se termine cu "${_issue.suffix}"`;
25164
25748
  if (_issue.format === "includes")
25165
- return `Texto inválido: deve incluir "${_issue.includes}"`;
25749
+ return `Șir invalid: trebuie includă "${_issue.includes}"`;
25166
25750
  if (_issue.format === "regex")
25167
- return `Texto inválido: deve corresponder ao padrão ${_issue.pattern}`;
25168
- return `${FormatDictionary[_issue.format] ?? issue2.format} inválido`;
25751
+ return `Șir invalid: trebuie se potrivească cu modelul ${_issue.pattern}`;
25752
+ return `Format invalid: ${FormatDictionary[_issue.format] ?? issue2.format}`;
25169
25753
  }
25170
25754
  case "not_multiple_of":
25171
- return `Número inválido: deve ser múltiplo de ${issue2.divisor}`;
25755
+ return `Număr invalid: trebuie fie multiplu de ${issue2.divisor}`;
25172
25756
  case "unrecognized_keys":
25173
- return `Chave${issue2.keys.length > 1 ? "s" : ""} desconhecida${issue2.keys.length > 1 ? "s" : ""}: ${joinValues(issue2.keys, ", ")}`;
25757
+ return `Chei nerecunoscute: ${joinValues(issue2.keys, ", ")}`;
25174
25758
  case "invalid_key":
25175
- return `Chave inválida em ${issue2.origin}`;
25759
+ return `Cheie invalidă în ${issue2.origin}`;
25176
25760
  case "invalid_union":
25177
- return "Entrada inválida";
25761
+ return "Intrare invalidă";
25178
25762
  case "invalid_element":
25179
- return `Valor inválido em ${issue2.origin}`;
25763
+ return `Valoare invalidă în ${issue2.origin}`;
25180
25764
  default:
25181
- return `Campo inválido`;
25765
+ return `Intrare invalidă`;
25182
25766
  }
25183
25767
  };
25184
25768
  };
25185
- function pt_default() {
25769
+ function ro_default() {
25186
25770
  return {
25187
- localeError: error36()
25771
+ localeError: error39()
25188
25772
  };
25189
25773
  }
25190
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ru.js
25774
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ru.js
25191
25775
  function getRussianPlural(count, one, few, many) {
25192
25776
  const absCount = Math.abs(count);
25193
25777
  const lastDigit = absCount % 10;
@@ -25203,7 +25787,7 @@ function getRussianPlural(count, one, few, many) {
25203
25787
  }
25204
25788
  return many;
25205
25789
  }
25206
- var error37 = () => {
25790
+ var error40 = () => {
25207
25791
  const Sizable = {
25208
25792
  string: {
25209
25793
  unit: {
@@ -25340,11 +25924,11 @@ var error37 = () => {
25340
25924
  };
25341
25925
  function ru_default() {
25342
25926
  return {
25343
- localeError: error37()
25927
+ localeError: error40()
25344
25928
  };
25345
25929
  }
25346
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/sl.js
25347
- var error38 = () => {
25930
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/sl.js
25931
+ var error41 = () => {
25348
25932
  const Sizable = {
25349
25933
  string: { unit: "znakov", verb: "imeti" },
25350
25934
  file: { unit: "bajtov", verb: "imeti" },
@@ -25449,11 +26033,11 @@ var error38 = () => {
25449
26033
  };
25450
26034
  function sl_default() {
25451
26035
  return {
25452
- localeError: error38()
26036
+ localeError: error41()
25453
26037
  };
25454
26038
  }
25455
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/sv.js
25456
- var error39 = () => {
26039
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/sv.js
26040
+ var error42 = () => {
25457
26041
  const Sizable = {
25458
26042
  string: { unit: "tecken", verb: "att ha" },
25459
26043
  file: { unit: "bytes", verb: "att ha" },
@@ -25559,11 +26143,11 @@ var error39 = () => {
25559
26143
  };
25560
26144
  function sv_default() {
25561
26145
  return {
25562
- localeError: error39()
26146
+ localeError: error42()
25563
26147
  };
25564
26148
  }
25565
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ta.js
25566
- var error40 = () => {
26149
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ta.js
26150
+ var error43 = () => {
25567
26151
  const Sizable = {
25568
26152
  string: { unit: "எழுத்துக்கள்", verb: "கொண்டிருக்க வேண்டும்" },
25569
26153
  file: { unit: "பைட்டுகள்", verb: "கொண்டிருக்க வேண்டும்" },
@@ -25669,11 +26253,11 @@ var error40 = () => {
25669
26253
  };
25670
26254
  function ta_default() {
25671
26255
  return {
25672
- localeError: error40()
26256
+ localeError: error43()
25673
26257
  };
25674
26258
  }
25675
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/th.js
25676
- var error41 = () => {
26259
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/th.js
26260
+ var error44 = () => {
25677
26261
  const Sizable = {
25678
26262
  string: { unit: "ตัวอักษร", verb: "ควรมี" },
25679
26263
  file: { unit: "ไบต์", verb: "ควรมี" },
@@ -25779,11 +26363,11 @@ var error41 = () => {
25779
26363
  };
25780
26364
  function th_default() {
25781
26365
  return {
25782
- localeError: error41()
26366
+ localeError: error44()
25783
26367
  };
25784
26368
  }
25785
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/tr.js
25786
- var error42 = () => {
26369
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/tr.js
26370
+ var error45 = () => {
25787
26371
  const Sizable = {
25788
26372
  string: { unit: "karakter", verb: "olmalı" },
25789
26373
  file: { unit: "bayt", verb: "olmalı" },
@@ -25884,11 +26468,11 @@ var error42 = () => {
25884
26468
  };
25885
26469
  function tr_default() {
25886
26470
  return {
25887
- localeError: error42()
26471
+ localeError: error45()
25888
26472
  };
25889
26473
  }
25890
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/uk.js
25891
- var error43 = () => {
26474
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/uk.js
26475
+ var error46 = () => {
25892
26476
  const Sizable = {
25893
26477
  string: { unit: "символів", verb: "матиме" },
25894
26478
  file: { unit: "байтів", verb: "матиме" },
@@ -25992,16 +26576,16 @@ var error43 = () => {
25992
26576
  };
25993
26577
  function uk_default() {
25994
26578
  return {
25995
- localeError: error43()
26579
+ localeError: error46()
25996
26580
  };
25997
26581
  }
25998
26582
 
25999
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ua.js
26583
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ua.js
26000
26584
  function ua_default() {
26001
26585
  return uk_default();
26002
26586
  }
26003
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/ur.js
26004
- var error44 = () => {
26587
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/ur.js
26588
+ var error47 = () => {
26005
26589
  const Sizable = {
26006
26590
  string: { unit: "حروف", verb: "ہونا" },
26007
26591
  file: { unit: "بائٹس", verb: "ہونا" },
@@ -26107,16 +26691,17 @@ var error44 = () => {
26107
26691
  };
26108
26692
  function ur_default() {
26109
26693
  return {
26110
- localeError: error44()
26694
+ localeError: error47()
26111
26695
  };
26112
26696
  }
26113
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/uz.js
26114
- var error45 = () => {
26697
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/uz.js
26698
+ var error48 = () => {
26115
26699
  const Sizable = {
26116
26700
  string: { unit: "belgi", verb: "bo‘lishi kerak" },
26117
26701
  file: { unit: "bayt", verb: "bo‘lishi kerak" },
26118
26702
  array: { unit: "element", verb: "bo‘lishi kerak" },
26119
- set: { unit: "element", verb: "bo‘lishi kerak" }
26703
+ set: { unit: "element", verb: "bo‘lishi kerak" },
26704
+ map: { unit: "yozuv", verb: "bo‘lishi kerak" }
26120
26705
  };
26121
26706
  function getSizing(origin) {
26122
26707
  return Sizable[origin] ?? null;
@@ -26216,11 +26801,11 @@ var error45 = () => {
26216
26801
  };
26217
26802
  function uz_default() {
26218
26803
  return {
26219
- localeError: error45()
26804
+ localeError: error48()
26220
26805
  };
26221
26806
  }
26222
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/vi.js
26223
- var error46 = () => {
26807
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/vi.js
26808
+ var error49 = () => {
26224
26809
  const Sizable = {
26225
26810
  string: { unit: "ký tự", verb: "có" },
26226
26811
  file: { unit: "byte", verb: "có" },
@@ -26324,11 +26909,11 @@ var error46 = () => {
26324
26909
  };
26325
26910
  function vi_default() {
26326
26911
  return {
26327
- localeError: error46()
26912
+ localeError: error49()
26328
26913
  };
26329
26914
  }
26330
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/zh-CN.js
26331
- var error47 = () => {
26915
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/zh-CN.js
26916
+ var error50 = () => {
26332
26917
  const Sizable = {
26333
26918
  string: { unit: "字符", verb: "包含" },
26334
26919
  file: { unit: "字节", verb: "包含" },
@@ -26433,11 +27018,11 @@ var error47 = () => {
26433
27018
  };
26434
27019
  function zh_CN_default() {
26435
27020
  return {
26436
- localeError: error47()
27021
+ localeError: error50()
26437
27022
  };
26438
27023
  }
26439
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/zh-TW.js
26440
- var error48 = () => {
27024
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/zh-TW.js
27025
+ var error51 = () => {
26441
27026
  const Sizable = {
26442
27027
  string: { unit: "字元", verb: "擁有" },
26443
27028
  file: { unit: "位元組", verb: "擁有" },
@@ -26540,11 +27125,11 @@ var error48 = () => {
26540
27125
  };
26541
27126
  function zh_TW_default() {
26542
27127
  return {
26543
- localeError: error48()
27128
+ localeError: error51()
26544
27129
  };
26545
27130
  }
26546
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/locales/yo.js
26547
- var error49 = () => {
27131
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/locales/yo.js
27132
+ var error52 = () => {
26548
27133
  const Sizable = {
26549
27134
  string: { unit: "àmi", verb: "ní" },
26550
27135
  file: { unit: "bytes", verb: "ní" },
@@ -26647,11 +27232,11 @@ var error49 = () => {
26647
27232
  };
26648
27233
  function yo_default() {
26649
27234
  return {
26650
- localeError: error49()
27235
+ localeError: error52()
26651
27236
  };
26652
27237
  }
26653
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/registries.js
26654
- var _a;
27238
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/registries.js
27239
+ var _a2;
26655
27240
  var $output = Symbol("ZodOutput");
26656
27241
  var $input = Symbol("ZodInput");
26657
27242
 
@@ -26698,9 +27283,9 @@ class $ZodRegistry {
26698
27283
  function registry() {
26699
27284
  return new $ZodRegistry;
26700
27285
  }
26701
- (_a = globalThis).__zod_globalRegistry ?? (_a.__zod_globalRegistry = registry());
27286
+ (_a2 = globalThis).__zod_globalRegistry ?? (_a2.__zod_globalRegistry = registry());
26702
27287
  var globalRegistry = globalThis.__zod_globalRegistry;
26703
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/api.js
27288
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/api.js
26704
27289
  function _string(Class2, params) {
26705
27290
  return new Class2({
26706
27291
  type: "string",
@@ -27504,7 +28089,7 @@ function _refine(Class2, fn, _params) {
27504
28089
  });
27505
28090
  return schema;
27506
28091
  }
27507
- function _superRefine(fn) {
28092
+ function _superRefine(fn, params) {
27508
28093
  const ch = _check((payload) => {
27509
28094
  payload.addIssue = (issue2) => {
27510
28095
  if (typeof issue2 === "string") {
@@ -27521,7 +28106,7 @@ function _superRefine(fn) {
27521
28106
  }
27522
28107
  };
27523
28108
  return fn(payload.value, payload);
27524
- });
28109
+ }, params);
27525
28110
  return ch;
27526
28111
  }
27527
28112
  function _check(fn, params) {
@@ -27620,7 +28205,7 @@ function _stringFormat(Class2, format, fnOrRegex, _params = {}) {
27620
28205
  const inst = new Class2(def);
27621
28206
  return inst;
27622
28207
  }
27623
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/to-json-schema.js
28208
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/to-json-schema.js
27624
28209
  function initializeContext(params) {
27625
28210
  let target = params?.target ?? "draft-2020-12";
27626
28211
  if (target === "draft-4")
@@ -27642,7 +28227,7 @@ function initializeContext(params) {
27642
28227
  };
27643
28228
  }
27644
28229
  function process2(schema, ctx, _params = { path: [], schemaPath: [] }) {
27645
- var _a2;
28230
+ var _a3;
27646
28231
  const def = schema._zod.def;
27647
28232
  const seen = ctx.seen.get(schema);
27648
28233
  if (seen) {
@@ -27689,8 +28274,8 @@ function process2(schema, ctx, _params = { path: [], schemaPath: [] }) {
27689
28274
  delete result.schema.examples;
27690
28275
  delete result.schema.default;
27691
28276
  }
27692
- if (ctx.io === "input" && result.schema._prefault)
27693
- (_a2 = result.schema).default ?? (_a2.default = result.schema._prefault);
28277
+ if (ctx.io === "input" && "_prefault" in result.schema)
28278
+ (_a3 = result.schema).default ?? (_a3.default = result.schema._prefault);
27694
28279
  delete result.schema._prefault;
27695
28280
  const _result = ctx.seen.get(schema);
27696
28281
  return _result.schema;
@@ -27867,10 +28452,15 @@ function finalize(ctx, schema) {
27867
28452
  result.$id = ctx.external.uri(id);
27868
28453
  }
27869
28454
  Object.assign(result, root.def ?? root.schema);
28455
+ const rootMetaId = ctx.metadataRegistry.get(schema)?.id;
28456
+ if (rootMetaId !== undefined && result.id === rootMetaId)
28457
+ delete result.id;
27870
28458
  const defs = ctx.external?.defs ?? {};
27871
28459
  for (const entry of ctx.seen.entries()) {
27872
28460
  const seen = entry[1];
27873
28461
  if (seen.def && seen.defId) {
28462
+ if (seen.def.id === seen.defId)
28463
+ delete seen.def.id;
27874
28464
  defs[seen.defId] = seen.def;
27875
28465
  }
27876
28466
  }
@@ -27925,6 +28515,8 @@ function isTransforming(_schema, _ctx) {
27925
28515
  return isTransforming(def.keyType, ctx) || isTransforming(def.valueType, ctx);
27926
28516
  }
27927
28517
  if (def.type === "pipe") {
28518
+ if (_schema._zod.traits.has("$ZodCodec"))
28519
+ return true;
27928
28520
  return isTransforming(def.in, ctx) || isTransforming(def.out, ctx);
27929
28521
  }
27930
28522
  if (def.type === "object") {
@@ -27965,7 +28557,7 @@ var createStandardJSONSchemaMethod = (schema, io, processors = {}) => (params) =
27965
28557
  extractDefs(ctx, schema);
27966
28558
  return finalize(ctx, schema);
27967
28559
  };
27968
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/json-schema-processors.js
28560
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/json-schema-processors.js
27969
28561
  var formatMap = {
27970
28562
  guid: "uuid",
27971
28563
  url: "uri",
@@ -28012,39 +28604,28 @@ var numberProcessor = (schema, ctx, _json, _params) => {
28012
28604
  json.type = "integer";
28013
28605
  else
28014
28606
  json.type = "number";
28015
- if (typeof exclusiveMinimum === "number") {
28016
- if (ctx.target === "draft-04" || ctx.target === "openapi-3.0") {
28607
+ const exMin = typeof exclusiveMinimum === "number" && exclusiveMinimum >= (minimum ?? Number.NEGATIVE_INFINITY);
28608
+ const exMax = typeof exclusiveMaximum === "number" && exclusiveMaximum <= (maximum ?? Number.POSITIVE_INFINITY);
28609
+ const legacy = ctx.target === "draft-04" || ctx.target === "openapi-3.0";
28610
+ if (exMin) {
28611
+ if (legacy) {
28017
28612
  json.minimum = exclusiveMinimum;
28018
28613
  json.exclusiveMinimum = true;
28019
28614
  } else {
28020
28615
  json.exclusiveMinimum = exclusiveMinimum;
28021
28616
  }
28022
- }
28023
- if (typeof minimum === "number") {
28617
+ } else if (typeof minimum === "number") {
28024
28618
  json.minimum = minimum;
28025
- if (typeof exclusiveMinimum === "number" && ctx.target !== "draft-04") {
28026
- if (exclusiveMinimum >= minimum)
28027
- delete json.minimum;
28028
- else
28029
- delete json.exclusiveMinimum;
28030
- }
28031
28619
  }
28032
- if (typeof exclusiveMaximum === "number") {
28033
- if (ctx.target === "draft-04" || ctx.target === "openapi-3.0") {
28620
+ if (exMax) {
28621
+ if (legacy) {
28034
28622
  json.maximum = exclusiveMaximum;
28035
28623
  json.exclusiveMaximum = true;
28036
28624
  } else {
28037
28625
  json.exclusiveMaximum = exclusiveMaximum;
28038
28626
  }
28039
- }
28040
- if (typeof maximum === "number") {
28627
+ } else if (typeof maximum === "number") {
28041
28628
  json.maximum = maximum;
28042
- if (typeof exclusiveMaximum === "number" && ctx.target !== "draft-04") {
28043
- if (exclusiveMaximum <= maximum)
28044
- delete json.maximum;
28045
- else
28046
- delete json.exclusiveMaximum;
28047
- }
28048
28629
  }
28049
28630
  if (typeof multipleOf === "number")
28050
28631
  json.multipleOf = multipleOf;
@@ -28212,7 +28793,10 @@ var arrayProcessor = (schema, ctx, _json, params) => {
28212
28793
  if (typeof maximum === "number")
28213
28794
  json.maxItems = maximum;
28214
28795
  json.type = "array";
28215
- json.items = process2(def.element, ctx, { ...params, path: [...params.path, "items"] });
28796
+ json.items = process2(def.element, ctx, {
28797
+ ...params,
28798
+ path: [...params.path, "items"]
28799
+ });
28216
28800
  };
28217
28801
  var objectProcessor = (schema, ctx, _json, params) => {
28218
28802
  const json = _json;
@@ -28405,7 +28989,8 @@ var catchProcessor = (schema, ctx, json, params) => {
28405
28989
  };
28406
28990
  var pipeProcessor = (schema, ctx, _json, params) => {
28407
28991
  const def = schema._zod.def;
28408
- const innerType = ctx.io === "input" ? def.in._zod.def.type === "transform" ? def.out : def.in : def.out;
28992
+ const inIsTransform = def.in._zod.traits.has("$ZodTransform");
28993
+ const innerType = ctx.io === "input" ? inIsTransform ? def.out : def.in : def.out;
28409
28994
  process2(innerType, ctx, params);
28410
28995
  const seen = ctx.seen.get(schema);
28411
28996
  seen.ref = innerType;
@@ -28510,7 +29095,7 @@ function toJSONSchema(input, params) {
28510
29095
  extractDefs(ctx, input);
28511
29096
  return finalize(ctx, input);
28512
29097
  }
28513
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/json-schema-generator.js
29098
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/json-schema-generator.js
28514
29099
  class JSONSchemaGenerator {
28515
29100
  get metadataRegistry() {
28516
29101
  return this.ctx.metadataRegistry;
@@ -28569,9 +29154,9 @@ class JSONSchemaGenerator {
28569
29154
  return plainResult;
28570
29155
  }
28571
29156
  }
28572
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/json-schema.js
29157
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/core/json-schema.js
28573
29158
  var exports_json_schema = {};
28574
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/schemas.js
29159
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/schemas.js
28575
29160
  var exports_schemas2 = {};
28576
29161
  __export(exports_schemas2, {
28577
29162
  xor: () => xor,
@@ -28631,6 +29216,7 @@ __export(exports_schemas2, {
28631
29216
  json: () => json,
28632
29217
  ipv6: () => ipv62,
28633
29218
  ipv4: () => ipv42,
29219
+ invertCodec: () => invertCodec,
28634
29220
  intersection: () => intersection,
28635
29221
  int64: () => int64,
28636
29222
  int32: () => int32,
@@ -28691,6 +29277,7 @@ __export(exports_schemas2, {
28691
29277
  ZodRecord: () => ZodRecord,
28692
29278
  ZodReadonly: () => ZodReadonly,
28693
29279
  ZodPromise: () => ZodPromise,
29280
+ ZodPreprocess: () => ZodPreprocess,
28694
29281
  ZodPrefault: () => ZodPrefault,
28695
29282
  ZodPipe: () => ZodPipe,
28696
29283
  ZodOptional: () => ZodOptional,
@@ -28740,7 +29327,7 @@ __export(exports_schemas2, {
28740
29327
  ZodAny: () => ZodAny
28741
29328
  });
28742
29329
 
28743
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/checks.js
29330
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/checks.js
28744
29331
  var exports_checks2 = {};
28745
29332
  __export(exports_checks2, {
28746
29333
  uppercase: () => _uppercase,
@@ -28774,7 +29361,7 @@ __export(exports_checks2, {
28774
29361
  endsWith: () => _endsWith
28775
29362
  });
28776
29363
 
28777
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/iso.js
29364
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/iso.js
28778
29365
  var exports_iso = {};
28779
29366
  __export(exports_iso, {
28780
29367
  time: () => time2,
@@ -28815,7 +29402,7 @@ function duration2(params) {
28815
29402
  return _isoDuration(ZodISODuration, params);
28816
29403
  }
28817
29404
 
28818
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/errors.js
29405
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/errors.js
28819
29406
  var initializer2 = (inst, issues) => {
28820
29407
  $ZodError.init(inst, issues);
28821
29408
  inst.name = "ZodError";
@@ -28845,12 +29432,12 @@ var initializer2 = (inst, issues) => {
28845
29432
  }
28846
29433
  });
28847
29434
  };
28848
- var ZodError = $constructor("ZodError", initializer2);
28849
- var ZodRealError = $constructor("ZodError", initializer2, {
29435
+ var ZodError = /* @__PURE__ */ $constructor("ZodError", initializer2);
29436
+ var ZodRealError = /* @__PURE__ */ $constructor("ZodError", initializer2, {
28850
29437
  Parent: Error
28851
29438
  });
28852
29439
 
28853
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/parse.js
29440
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/parse.js
28854
29441
  var parse3 = /* @__PURE__ */ _parse(ZodRealError);
28855
29442
  var parseAsync2 = /* @__PURE__ */ _parseAsync(ZodRealError);
28856
29443
  var safeParse2 = /* @__PURE__ */ _safeParse(ZodRealError);
@@ -28864,7 +29451,44 @@ var safeDecode2 = /* @__PURE__ */ _safeDecode(ZodRealError);
28864
29451
  var safeEncodeAsync2 = /* @__PURE__ */ _safeEncodeAsync(ZodRealError);
28865
29452
  var safeDecodeAsync2 = /* @__PURE__ */ _safeDecodeAsync(ZodRealError);
28866
29453
 
28867
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/schemas.js
29454
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/schemas.js
29455
+ var _installedGroups = /* @__PURE__ */ new WeakMap;
29456
+ function _installLazyMethods(inst, group, methods) {
29457
+ const proto = Object.getPrototypeOf(inst);
29458
+ let installed = _installedGroups.get(proto);
29459
+ if (!installed) {
29460
+ installed = new Set;
29461
+ _installedGroups.set(proto, installed);
29462
+ }
29463
+ if (installed.has(group))
29464
+ return;
29465
+ installed.add(group);
29466
+ for (const key in methods) {
29467
+ const fn = methods[key];
29468
+ Object.defineProperty(proto, key, {
29469
+ configurable: true,
29470
+ enumerable: false,
29471
+ get() {
29472
+ const bound = fn.bind(this);
29473
+ Object.defineProperty(this, key, {
29474
+ configurable: true,
29475
+ writable: true,
29476
+ enumerable: true,
29477
+ value: bound
29478
+ });
29479
+ return bound;
29480
+ },
29481
+ set(v) {
29482
+ Object.defineProperty(this, key, {
29483
+ configurable: true,
29484
+ writable: true,
29485
+ enumerable: true,
29486
+ value: v
29487
+ });
29488
+ }
29489
+ });
29490
+ }
29491
+ }
28868
29492
  var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
28869
29493
  $ZodType.init(inst, def);
28870
29494
  Object.assign(inst["~standard"], {
@@ -28877,23 +29501,6 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
28877
29501
  inst.def = def;
28878
29502
  inst.type = def.type;
28879
29503
  Object.defineProperty(inst, "_def", { value: def });
28880
- inst.check = (...checks2) => {
28881
- return inst.clone(exports_util.mergeDefs(def, {
28882
- checks: [
28883
- ...def.checks ?? [],
28884
- ...checks2.map((ch) => typeof ch === "function" ? { _zod: { check: ch, def: { check: "custom" }, onattach: [] } } : ch)
28885
- ]
28886
- }), {
28887
- parent: true
28888
- });
28889
- };
28890
- inst.with = inst.check;
28891
- inst.clone = (def2, params) => clone(inst, def2, params);
28892
- inst.brand = () => inst;
28893
- inst.register = (reg, meta2) => {
28894
- reg.add(inst, meta2);
28895
- return inst;
28896
- };
28897
29504
  inst.parse = (data, params) => parse3(inst, data, params, { callee: inst.parse });
28898
29505
  inst.safeParse = (data, params) => safeParse2(inst, data, params);
28899
29506
  inst.parseAsync = async (data, params) => parseAsync2(inst, data, params, { callee: inst.parseAsync });
@@ -28907,45 +29514,108 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
28907
29514
  inst.safeDecode = (data, params) => safeDecode2(inst, data, params);
28908
29515
  inst.safeEncodeAsync = async (data, params) => safeEncodeAsync2(inst, data, params);
28909
29516
  inst.safeDecodeAsync = async (data, params) => safeDecodeAsync2(inst, data, params);
28910
- inst.refine = (check, params) => inst.check(refine(check, params));
28911
- inst.superRefine = (refinement) => inst.check(superRefine(refinement));
28912
- inst.overwrite = (fn) => inst.check(_overwrite(fn));
28913
- inst.optional = () => optional(inst);
28914
- inst.exactOptional = () => exactOptional(inst);
28915
- inst.nullable = () => nullable(inst);
28916
- inst.nullish = () => optional(nullable(inst));
28917
- inst.nonoptional = (params) => nonoptional(inst, params);
28918
- inst.array = () => array(inst);
28919
- inst.or = (arg) => union([inst, arg]);
28920
- inst.and = (arg) => intersection(inst, arg);
28921
- inst.transform = (tx) => pipe(inst, transform(tx));
28922
- inst.default = (def2) => _default2(inst, def2);
28923
- inst.prefault = (def2) => prefault(inst, def2);
28924
- inst.catch = (params) => _catch2(inst, params);
28925
- inst.pipe = (target) => pipe(inst, target);
28926
- inst.readonly = () => readonly(inst);
28927
- inst.describe = (description) => {
28928
- const cl = inst.clone();
28929
- globalRegistry.add(cl, { description });
28930
- return cl;
28931
- };
29517
+ _installLazyMethods(inst, "ZodType", {
29518
+ check(...chks) {
29519
+ const def2 = this.def;
29520
+ return this.clone(exports_util.mergeDefs(def2, {
29521
+ checks: [
29522
+ ...def2.checks ?? [],
29523
+ ...chks.map((ch) => typeof ch === "function" ? { _zod: { check: ch, def: { check: "custom" }, onattach: [] } } : ch)
29524
+ ]
29525
+ }), { parent: true });
29526
+ },
29527
+ with(...chks) {
29528
+ return this.check(...chks);
29529
+ },
29530
+ clone(def2, params) {
29531
+ return clone(this, def2, params);
29532
+ },
29533
+ brand() {
29534
+ return this;
29535
+ },
29536
+ register(reg, meta2) {
29537
+ reg.add(this, meta2);
29538
+ return this;
29539
+ },
29540
+ refine(check, params) {
29541
+ return this.check(refine(check, params));
29542
+ },
29543
+ superRefine(refinement, params) {
29544
+ return this.check(superRefine(refinement, params));
29545
+ },
29546
+ overwrite(fn) {
29547
+ return this.check(_overwrite(fn));
29548
+ },
29549
+ optional() {
29550
+ return optional(this);
29551
+ },
29552
+ exactOptional() {
29553
+ return exactOptional(this);
29554
+ },
29555
+ nullable() {
29556
+ return nullable(this);
29557
+ },
29558
+ nullish() {
29559
+ return optional(nullable(this));
29560
+ },
29561
+ nonoptional(params) {
29562
+ return nonoptional(this, params);
29563
+ },
29564
+ array() {
29565
+ return array(this);
29566
+ },
29567
+ or(arg) {
29568
+ return union([this, arg]);
29569
+ },
29570
+ and(arg) {
29571
+ return intersection(this, arg);
29572
+ },
29573
+ transform(tx) {
29574
+ return pipe(this, transform(tx));
29575
+ },
29576
+ default(d) {
29577
+ return _default2(this, d);
29578
+ },
29579
+ prefault(d) {
29580
+ return prefault(this, d);
29581
+ },
29582
+ catch(params) {
29583
+ return _catch2(this, params);
29584
+ },
29585
+ pipe(target) {
29586
+ return pipe(this, target);
29587
+ },
29588
+ readonly() {
29589
+ return readonly(this);
29590
+ },
29591
+ describe(description) {
29592
+ const cl = this.clone();
29593
+ globalRegistry.add(cl, { description });
29594
+ return cl;
29595
+ },
29596
+ meta(...args) {
29597
+ if (args.length === 0)
29598
+ return globalRegistry.get(this);
29599
+ const cl = this.clone();
29600
+ globalRegistry.add(cl, args[0]);
29601
+ return cl;
29602
+ },
29603
+ isOptional() {
29604
+ return this.safeParse(undefined).success;
29605
+ },
29606
+ isNullable() {
29607
+ return this.safeParse(null).success;
29608
+ },
29609
+ apply(fn) {
29610
+ return fn(this);
29611
+ }
29612
+ });
28932
29613
  Object.defineProperty(inst, "description", {
28933
29614
  get() {
28934
29615
  return globalRegistry.get(inst)?.description;
28935
29616
  },
28936
29617
  configurable: true
28937
29618
  });
28938
- inst.meta = (...args) => {
28939
- if (args.length === 0) {
28940
- return globalRegistry.get(inst);
28941
- }
28942
- const cl = inst.clone();
28943
- globalRegistry.add(cl, args[0]);
28944
- return cl;
28945
- };
28946
- inst.isOptional = () => inst.safeParse(undefined).success;
28947
- inst.isNullable = () => inst.safeParse(null).success;
28948
- inst.apply = (fn) => fn(inst);
28949
29619
  return inst;
28950
29620
  });
28951
29621
  var _ZodString = /* @__PURE__ */ $constructor("_ZodString", (inst, def) => {
@@ -28956,21 +29626,53 @@ var _ZodString = /* @__PURE__ */ $constructor("_ZodString", (inst, def) => {
28956
29626
  inst.format = bag.format ?? null;
28957
29627
  inst.minLength = bag.minimum ?? null;
28958
29628
  inst.maxLength = bag.maximum ?? null;
28959
- inst.regex = (...args) => inst.check(_regex(...args));
28960
- inst.includes = (...args) => inst.check(_includes(...args));
28961
- inst.startsWith = (...args) => inst.check(_startsWith(...args));
28962
- inst.endsWith = (...args) => inst.check(_endsWith(...args));
28963
- inst.min = (...args) => inst.check(_minLength(...args));
28964
- inst.max = (...args) => inst.check(_maxLength(...args));
28965
- inst.length = (...args) => inst.check(_length(...args));
28966
- inst.nonempty = (...args) => inst.check(_minLength(1, ...args));
28967
- inst.lowercase = (params) => inst.check(_lowercase(params));
28968
- inst.uppercase = (params) => inst.check(_uppercase(params));
28969
- inst.trim = () => inst.check(_trim());
28970
- inst.normalize = (...args) => inst.check(_normalize(...args));
28971
- inst.toLowerCase = () => inst.check(_toLowerCase());
28972
- inst.toUpperCase = () => inst.check(_toUpperCase());
28973
- inst.slugify = () => inst.check(_slugify());
29629
+ _installLazyMethods(inst, "_ZodString", {
29630
+ regex(...args) {
29631
+ return this.check(_regex(...args));
29632
+ },
29633
+ includes(...args) {
29634
+ return this.check(_includes(...args));
29635
+ },
29636
+ startsWith(...args) {
29637
+ return this.check(_startsWith(...args));
29638
+ },
29639
+ endsWith(...args) {
29640
+ return this.check(_endsWith(...args));
29641
+ },
29642
+ min(...args) {
29643
+ return this.check(_minLength(...args));
29644
+ },
29645
+ max(...args) {
29646
+ return this.check(_maxLength(...args));
29647
+ },
29648
+ length(...args) {
29649
+ return this.check(_length(...args));
29650
+ },
29651
+ nonempty(...args) {
29652
+ return this.check(_minLength(1, ...args));
29653
+ },
29654
+ lowercase(params) {
29655
+ return this.check(_lowercase(params));
29656
+ },
29657
+ uppercase(params) {
29658
+ return this.check(_uppercase(params));
29659
+ },
29660
+ trim() {
29661
+ return this.check(_trim());
29662
+ },
29663
+ normalize(...args) {
29664
+ return this.check(_normalize(...args));
29665
+ },
29666
+ toLowerCase() {
29667
+ return this.check(_toLowerCase());
29668
+ },
29669
+ toUpperCase() {
29670
+ return this.check(_toUpperCase());
29671
+ },
29672
+ slugify() {
29673
+ return this.check(_slugify());
29674
+ }
29675
+ });
28974
29676
  });
28975
29677
  var ZodString = /* @__PURE__ */ $constructor("ZodString", (inst, def) => {
28976
29678
  $ZodString.init(inst, def);
@@ -29049,7 +29751,7 @@ function url(params) {
29049
29751
  }
29050
29752
  function httpUrl(params) {
29051
29753
  return _url(ZodURL, {
29052
- protocol: /^https?$/,
29754
+ protocol: exports_regexes.httpProtocol,
29053
29755
  hostname: exports_regexes.domain,
29054
29756
  ...exports_util.normalizeParams(params)
29055
29757
  });
@@ -29191,21 +29893,53 @@ var ZodNumber = /* @__PURE__ */ $constructor("ZodNumber", (inst, def) => {
29191
29893
  $ZodNumber.init(inst, def);
29192
29894
  ZodType.init(inst, def);
29193
29895
  inst._zod.processJSONSchema = (ctx, json, params) => numberProcessor(inst, ctx, json, params);
29194
- inst.gt = (value, params) => inst.check(_gt(value, params));
29195
- inst.gte = (value, params) => inst.check(_gte(value, params));
29196
- inst.min = (value, params) => inst.check(_gte(value, params));
29197
- inst.lt = (value, params) => inst.check(_lt(value, params));
29198
- inst.lte = (value, params) => inst.check(_lte(value, params));
29199
- inst.max = (value, params) => inst.check(_lte(value, params));
29200
- inst.int = (params) => inst.check(int(params));
29201
- inst.safe = (params) => inst.check(int(params));
29202
- inst.positive = (params) => inst.check(_gt(0, params));
29203
- inst.nonnegative = (params) => inst.check(_gte(0, params));
29204
- inst.negative = (params) => inst.check(_lt(0, params));
29205
- inst.nonpositive = (params) => inst.check(_lte(0, params));
29206
- inst.multipleOf = (value, params) => inst.check(_multipleOf(value, params));
29207
- inst.step = (value, params) => inst.check(_multipleOf(value, params));
29208
- inst.finite = () => inst;
29896
+ _installLazyMethods(inst, "ZodNumber", {
29897
+ gt(value, params) {
29898
+ return this.check(_gt(value, params));
29899
+ },
29900
+ gte(value, params) {
29901
+ return this.check(_gte(value, params));
29902
+ },
29903
+ min(value, params) {
29904
+ return this.check(_gte(value, params));
29905
+ },
29906
+ lt(value, params) {
29907
+ return this.check(_lt(value, params));
29908
+ },
29909
+ lte(value, params) {
29910
+ return this.check(_lte(value, params));
29911
+ },
29912
+ max(value, params) {
29913
+ return this.check(_lte(value, params));
29914
+ },
29915
+ int(params) {
29916
+ return this.check(int(params));
29917
+ },
29918
+ safe(params) {
29919
+ return this.check(int(params));
29920
+ },
29921
+ positive(params) {
29922
+ return this.check(_gt(0, params));
29923
+ },
29924
+ nonnegative(params) {
29925
+ return this.check(_gte(0, params));
29926
+ },
29927
+ negative(params) {
29928
+ return this.check(_lt(0, params));
29929
+ },
29930
+ nonpositive(params) {
29931
+ return this.check(_lte(0, params));
29932
+ },
29933
+ multipleOf(value, params) {
29934
+ return this.check(_multipleOf(value, params));
29935
+ },
29936
+ step(value, params) {
29937
+ return this.check(_multipleOf(value, params));
29938
+ },
29939
+ finite() {
29940
+ return this;
29941
+ }
29942
+ });
29209
29943
  const bag = inst._zod.bag;
29210
29944
  inst.minValue = Math.max(bag.minimum ?? Number.NEGATIVE_INFINITY, bag.exclusiveMinimum ?? Number.NEGATIVE_INFINITY) ?? null;
29211
29945
  inst.maxValue = Math.min(bag.maximum ?? Number.POSITIVE_INFINITY, bag.exclusiveMaximum ?? Number.POSITIVE_INFINITY) ?? null;
@@ -29352,11 +30086,23 @@ var ZodArray = /* @__PURE__ */ $constructor("ZodArray", (inst, def) => {
29352
30086
  ZodType.init(inst, def);
29353
30087
  inst._zod.processJSONSchema = (ctx, json, params) => arrayProcessor(inst, ctx, json, params);
29354
30088
  inst.element = def.element;
29355
- inst.min = (minLength, params) => inst.check(_minLength(minLength, params));
29356
- inst.nonempty = (params) => inst.check(_minLength(1, params));
29357
- inst.max = (maxLength, params) => inst.check(_maxLength(maxLength, params));
29358
- inst.length = (len, params) => inst.check(_length(len, params));
29359
- inst.unwrap = () => inst.element;
30089
+ _installLazyMethods(inst, "ZodArray", {
30090
+ min(n, params) {
30091
+ return this.check(_minLength(n, params));
30092
+ },
30093
+ nonempty(params) {
30094
+ return this.check(_minLength(1, params));
30095
+ },
30096
+ max(n, params) {
30097
+ return this.check(_maxLength(n, params));
30098
+ },
30099
+ length(n, params) {
30100
+ return this.check(_length(n, params));
30101
+ },
30102
+ unwrap() {
30103
+ return this.element;
30104
+ }
30105
+ });
29360
30106
  });
29361
30107
  function array(element, params) {
29362
30108
  return _array(ZodArray, element, params);
@@ -29372,23 +30118,47 @@ var ZodObject = /* @__PURE__ */ $constructor("ZodObject", (inst, def) => {
29372
30118
  exports_util.defineLazy(inst, "shape", () => {
29373
30119
  return def.shape;
29374
30120
  });
29375
- inst.keyof = () => _enum2(Object.keys(inst._zod.def.shape));
29376
- inst.catchall = (catchall) => inst.clone({ ...inst._zod.def, catchall });
29377
- inst.passthrough = () => inst.clone({ ...inst._zod.def, catchall: unknown() });
29378
- inst.loose = () => inst.clone({ ...inst._zod.def, catchall: unknown() });
29379
- inst.strict = () => inst.clone({ ...inst._zod.def, catchall: never() });
29380
- inst.strip = () => inst.clone({ ...inst._zod.def, catchall: undefined });
29381
- inst.extend = (incoming) => {
29382
- return exports_util.extend(inst, incoming);
29383
- };
29384
- inst.safeExtend = (incoming) => {
29385
- return exports_util.safeExtend(inst, incoming);
29386
- };
29387
- inst.merge = (other) => exports_util.merge(inst, other);
29388
- inst.pick = (mask) => exports_util.pick(inst, mask);
29389
- inst.omit = (mask) => exports_util.omit(inst, mask);
29390
- inst.partial = (...args) => exports_util.partial(ZodOptional, inst, args[0]);
29391
- inst.required = (...args) => exports_util.required(ZodNonOptional, inst, args[0]);
30121
+ _installLazyMethods(inst, "ZodObject", {
30122
+ keyof() {
30123
+ return _enum2(Object.keys(this._zod.def.shape));
30124
+ },
30125
+ catchall(catchall) {
30126
+ return this.clone({ ...this._zod.def, catchall });
30127
+ },
30128
+ passthrough() {
30129
+ return this.clone({ ...this._zod.def, catchall: unknown() });
30130
+ },
30131
+ loose() {
30132
+ return this.clone({ ...this._zod.def, catchall: unknown() });
30133
+ },
30134
+ strict() {
30135
+ return this.clone({ ...this._zod.def, catchall: never() });
30136
+ },
30137
+ strip() {
30138
+ return this.clone({ ...this._zod.def, catchall: undefined });
30139
+ },
30140
+ extend(incoming) {
30141
+ return exports_util.extend(this, incoming);
30142
+ },
30143
+ safeExtend(incoming) {
30144
+ return exports_util.safeExtend(this, incoming);
30145
+ },
30146
+ merge(other) {
30147
+ return exports_util.merge(this, other);
30148
+ },
30149
+ pick(mask) {
30150
+ return exports_util.pick(this, mask);
30151
+ },
30152
+ omit(mask) {
30153
+ return exports_util.omit(this, mask);
30154
+ },
30155
+ partial(...args) {
30156
+ return exports_util.partial(ZodOptional, this, args[0]);
30157
+ },
30158
+ required(...args) {
30159
+ return exports_util.required(ZodNonOptional, this, args[0]);
30160
+ }
30161
+ });
29392
30162
  });
29393
30163
  function object(shape, params) {
29394
30164
  const def = {
@@ -29493,6 +30263,14 @@ var ZodRecord = /* @__PURE__ */ $constructor("ZodRecord", (inst, def) => {
29493
30263
  inst.valueType = def.valueType;
29494
30264
  });
29495
30265
  function record(keyType, valueType, params) {
30266
+ if (!valueType || !valueType._zod) {
30267
+ return new ZodRecord({
30268
+ type: "record",
30269
+ keyType: string2(),
30270
+ valueType: keyType,
30271
+ ...exports_util.normalizeParams(valueType)
30272
+ });
30273
+ }
29496
30274
  return new ZodRecord({
29497
30275
  type: "record",
29498
30276
  keyType,
@@ -29664,10 +30442,12 @@ var ZodTransform = /* @__PURE__ */ $constructor("ZodTransform", (inst, def) => {
29664
30442
  if (output instanceof Promise) {
29665
30443
  return output.then((output2) => {
29666
30444
  payload.value = output2;
30445
+ payload.fallback = true;
29667
30446
  return payload;
29668
30447
  });
29669
30448
  }
29670
30449
  payload.value = output;
30450
+ payload.fallback = true;
29671
30451
  return payload;
29672
30452
  };
29673
30453
  });
@@ -29821,6 +30601,20 @@ function codec(in_, out, params) {
29821
30601
  reverseTransform: params.encode
29822
30602
  });
29823
30603
  }
30604
+ function invertCodec(codec2) {
30605
+ const def = codec2._zod.def;
30606
+ return new ZodCodec({
30607
+ type: "pipe",
30608
+ in: def.out,
30609
+ out: def.in,
30610
+ transform: def.reverseTransform,
30611
+ reverseTransform: def.transform
30612
+ });
30613
+ }
30614
+ var ZodPreprocess = /* @__PURE__ */ $constructor("ZodPreprocess", (inst, def) => {
30615
+ ZodPipe.init(inst, def);
30616
+ $ZodPreprocess.init(inst, def);
30617
+ });
29824
30618
  var ZodReadonly = /* @__PURE__ */ $constructor("ZodReadonly", (inst, def) => {
29825
30619
  $ZodReadonly.init(inst, def);
29826
30620
  ZodType.init(inst, def);
@@ -29899,8 +30693,8 @@ function custom(fn, _params) {
29899
30693
  function refine(fn, _params = {}) {
29900
30694
  return _refine(ZodCustom, fn, _params);
29901
30695
  }
29902
- function superRefine(fn) {
29903
- return _superRefine(fn);
30696
+ function superRefine(fn, params) {
30697
+ return _superRefine(fn, params);
29904
30698
  }
29905
30699
  var describe2 = describe;
29906
30700
  var meta2 = meta;
@@ -29938,9 +30732,13 @@ function json(params) {
29938
30732
  return jsonSchema;
29939
30733
  }
29940
30734
  function preprocess(fn, schema) {
29941
- return pipe(transform(fn), schema);
30735
+ return new ZodPreprocess({
30736
+ type: "pipe",
30737
+ in: transform(fn),
30738
+ out: schema
30739
+ });
29942
30740
  }
29943
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/compat.js
30741
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/compat.js
29944
30742
  var ZodIssueCode = {
29945
30743
  invalid_type: "invalid_type",
29946
30744
  too_big: "too_big",
@@ -29964,13 +30762,13 @@ function getErrorMap() {
29964
30762
  }
29965
30763
  var ZodFirstPartyTypeKind;
29966
30764
  (function(ZodFirstPartyTypeKind2) {})(ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {}));
29967
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/from-json-schema.js
30765
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/from-json-schema.js
29968
30766
  var z = {
29969
30767
  ...exports_schemas2,
29970
30768
  ...exports_checks2,
29971
30769
  iso: exports_iso
29972
30770
  };
29973
- var RECOGNIZED_KEYS = new Set([
30771
+ var RECOGNIZED_KEYS = /* @__PURE__ */ new Set([
29974
30772
  "$schema",
29975
30773
  "$ref",
29976
30774
  "$defs",
@@ -30344,12 +31142,6 @@ function convertBaseSchema(schema, ctx) {
30344
31142
  default:
30345
31143
  throw new Error(`Unsupported type: ${type}`);
30346
31144
  }
30347
- if (schema.description) {
30348
- zodSchema = zodSchema.describe(schema.description);
30349
- }
30350
- if (schema.default !== undefined) {
30351
- zodSchema = zodSchema.default(schema.default);
30352
- }
30353
31145
  return zodSchema;
30354
31146
  }
30355
31147
  function convertSchema(schema, ctx) {
@@ -30386,6 +31178,9 @@ function convertSchema(schema, ctx) {
30386
31178
  if (schema.readOnly === true) {
30387
31179
  baseSchema = z.readonly(baseSchema);
30388
31180
  }
31181
+ if (schema.default !== undefined) {
31182
+ baseSchema = baseSchema.default(schema.default);
31183
+ }
30389
31184
  const extraMeta = {};
30390
31185
  const coreMetadataKeys = ["$id", "id", "$comment", "$anchor", "$vocabulary", "$dynamicRef", "$dynamicAnchor"];
30391
31186
  for (const key of coreMetadataKeys) {
@@ -30407,25 +31202,34 @@ function convertSchema(schema, ctx) {
30407
31202
  if (Object.keys(extraMeta).length > 0) {
30408
31203
  ctx.registry.add(baseSchema, extraMeta);
30409
31204
  }
31205
+ if (schema.description) {
31206
+ baseSchema = baseSchema.describe(schema.description);
31207
+ }
30410
31208
  return baseSchema;
30411
31209
  }
30412
31210
  function fromJSONSchema(schema, params) {
30413
31211
  if (typeof schema === "boolean") {
30414
31212
  return schema ? z.any() : z.never();
30415
31213
  }
30416
- const version2 = detectVersion(schema, params?.defaultTarget);
30417
- const defs = schema.$defs || schema.definitions || {};
31214
+ let normalized;
31215
+ try {
31216
+ normalized = JSON.parse(JSON.stringify(schema));
31217
+ } catch {
31218
+ throw new Error("fromJSONSchema input is not valid JSON (possibly cyclic); use $defs/$ref for recursive schemas");
31219
+ }
31220
+ const version2 = detectVersion(normalized, params?.defaultTarget);
31221
+ const defs = normalized.$defs || normalized.definitions || {};
30418
31222
  const ctx = {
30419
31223
  version: version2,
30420
31224
  defs,
30421
31225
  refs: new Map,
30422
31226
  processing: new Set,
30423
- rootSchema: schema,
31227
+ rootSchema: normalized,
30424
31228
  registry: params?.registry ?? globalRegistry
30425
31229
  };
30426
- return convertSchema(schema, ctx);
31230
+ return convertSchema(normalized, ctx);
30427
31231
  }
30428
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/coerce.js
31232
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/coerce.js
30429
31233
  var exports_coerce = {};
30430
31234
  __export(exports_coerce, {
30431
31235
  string: () => string3,
@@ -30450,7 +31254,7 @@ function date4(params) {
30450
31254
  return _coercedDate(ZodDate, params);
30451
31255
  }
30452
31256
 
30453
- // ../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/classic/external.js
31257
+ // ../../node_modules/.bun/zod@4.4.3/node_modules/zod/v4/classic/external.js
30454
31258
  config(en_default());
30455
31259
  // src/config.ts
30456
31260
  var FOREGROUND_WAIT_WINDOW_DEFAULT_MS = 15000;
@@ -30600,6 +31404,11 @@ var InspectConfigSchema = exports_external.object({
30600
31404
  }).optional()
30601
31405
  }).optional()
30602
31406
  });
31407
+ var BackupConfigSchema = exports_external.object({
31408
+ enabled: exports_external.boolean().optional(),
31409
+ max_depth: exports_external.number().int().positive().optional(),
31410
+ max_file_size: exports_external.number().int().positive().optional()
31411
+ });
30603
31412
  var AftConfigSchema = exports_external.object({
30604
31413
  $schema: exports_external.string().optional(),
30605
31414
  format_on_edit: exports_external.boolean().optional(),
@@ -30616,6 +31425,7 @@ var AftConfigSchema = exports_external.object({
30616
31425
  callgraph_store: exports_external.boolean().optional(),
30617
31426
  callgraph_chunk_size: exports_external.number().optional(),
30618
31427
  inspect: InspectConfigSchema.optional(),
31428
+ backup: BackupConfigSchema.optional(),
30619
31429
  bash: BashConfigSchema.optional(),
30620
31430
  experimental: ExperimentalConfigSchema.optional(),
30621
31431
  lsp: LspConfigSchema.optional(),
@@ -30966,10 +31776,17 @@ function getStrippedTopLevelKeys(override) {
30966
31776
  stripped.push("url_fetch_allow_private");
30967
31777
  if (override.bridge !== undefined)
30968
31778
  stripped.push("bridge");
31779
+ if (override.backup !== undefined)
31780
+ stripped.push("backup");
31781
+ if (override.disabled_tools?.includes("aft_safety"))
31782
+ stripped.push("disabled_tools.aft_safety");
30969
31783
  return stripped;
30970
31784
  }
30971
31785
  function mergeConfigs(base, override) {
30972
- const disabledTools = [...base.disabled_tools ?? [], ...override.disabled_tools ?? []];
31786
+ const disabledTools = [
31787
+ ...base.disabled_tools ?? [],
31788
+ ...(override.disabled_tools ?? []).filter((tool) => tool !== "aft_safety")
31789
+ ];
30973
31790
  const formatter = { ...base.formatter, ...override.formatter };
30974
31791
  const checker = { ...base.checker, ...override.checker };
30975
31792
  const semantic = mergeSemanticConfig(base.semantic, override.semantic);
@@ -33378,10 +34195,11 @@ PDFs aren't supported on the Pi harness yet.`, response);
33378
34195
  });
33379
34196
  }
33380
34197
  if (surface.hoistWrite) {
34198
+ const writeBackupText = ctx.config.backup?.enabled === false ? "Backup capture is disabled by user config." : "Existing files are backed up before overwriting (undo via aft_safety).";
33381
34199
  pi.registerTool({
33382
34200
  name: "write",
33383
34201
  label: "write",
33384
- description: "Write content to a file, creating it and parent directories automatically. Existing files are backed up before overwriting (undo via aft_safety) and auto-formatted when the project has a formatter configured. Uses `filePath` (not `path`). For partial edits, use the `edit` tool.",
34202
+ description: `Write content to a file, creating it and parent directories automatically. ${writeBackupText} Auto-formats when the project has a formatter configured. Uses \`filePath\` (not \`path\`). For partial edits, use the \`edit\` tool.`,
33385
34203
  promptSnippet: "Create or overwrite files (uses filePath; auto-formats)",
33386
34204
  promptGuidelines: ["Use write only for new files or complete rewrites."],
33387
34205
  parameters: WriteParams,
@@ -33977,13 +34795,13 @@ function buildAstReplaceSections(payload, theme) {
33977
34795
  files.forEach((fileResult) => {
33978
34796
  const file2 = shortenPath3(asString2(fileResult.file) ?? "(unknown file)");
33979
34797
  const replacements = asNumber2(fileResult.replacements) ?? 0;
33980
- const error50 = asString2(fileResult.error);
34798
+ const error53 = asString2(fileResult.error);
33981
34799
  const diff = asString2(fileResult.diff);
33982
34800
  const lines = [
33983
34801
  `${theme.fg("accent", file2)} ${theme.fg("muted", `(${replacements} replacement${replacements === 1 ? "" : "s"})`)}`
33984
34802
  ];
33985
- if (error50) {
33986
- lines.push(theme.fg("error", error50));
34803
+ if (error53) {
34804
+ lines.push(theme.fg("error", error53));
33987
34805
  } else if (diff) {
33988
34806
  const rendered = renderUnifiedDiff(diff);
33989
34807
  lines.push(rendered || theme.fg("muted", "No diff available."));
@@ -34993,11 +35811,12 @@ function renderFsResult(toolName, args, result, theme, context) {
34993
35811
  ], context);
34994
35812
  }
34995
35813
  function registerFsTools(pi, ctx, surface) {
35814
+ const backupsDisabled = ctx.config.backup?.enabled === false;
34996
35815
  if (surface.delete) {
34997
35816
  pi.registerTool({
34998
35817
  name: "aft_delete",
34999
35818
  label: "delete",
35000
- description: "Delete one or more files (or directories) with backup. Each file is backed up before deletion — use `aft_safety undo` to recover any of them. " + "For directories, every file inside is individually backed up before removal. Directory deletion requires recursive: true. " + "Returns { success, complete, deleted, skipped_files }: partial success is allowed; files that fail are reported in skipped_files.",
35819
+ description: "Delete one or more files (or directories). " + (backupsDisabled ? "Backup capture is disabled by user config, so this tool does not create undo snapshots. " : "Each file is backed up before deletion — use `aft_safety undo` to recover any of them. For directories, every file inside is individually backed up before removal. ") + "Directory deletion requires recursive: true. " + "Returns { success, complete, deleted, skipped_files }: partial success is allowed; files that fail are reported in skipped_files.",
35001
35820
  parameters: DeleteParams,
35002
35821
  async execute(_toolCallId, params, _signal, _onUpdate, extCtx) {
35003
35822
  const inputs = coerceStringArray(params.files);
@@ -35047,7 +35866,7 @@ function registerFsTools(pi, ctx, surface) {
35047
35866
  pi.registerTool({
35048
35867
  name: "aft_move",
35049
35868
  label: "move",
35050
- description: "Move or rename a file with backup. Creates parent directories for the destination automatically. This operates on files at the OS level — to relocate a code symbol between files, use `aft_refactor` with op='move' instead.",
35869
+ description: "Move or rename a file. " + (backupsDisabled ? "Backup capture is disabled by user config. " : "Creates an undo backup before moving. ") + "Creates parent directories for the destination automatically. This operates on files at the OS level — to relocate a code symbol between files, use `aft_refactor` with op='move' instead.",
35051
35870
  parameters: MoveParams,
35052
35871
  async execute(_toolCallId, params, _signal, _onUpdate, extCtx) {
35053
35872
  const filePath = await resolvePathArg(extCtx.cwd, params.filePath);
@@ -35148,10 +35967,11 @@ function renderImportResult(result, args, theme, context) {
35148
35967
  return renderSections(buildImportSections(args, payload, theme), context);
35149
35968
  }
35150
35969
  function registerImportTools(pi, ctx) {
35970
+ const organizeRecovery = ctx.config.backup?.enabled === false ? "Backup capture is disabled by user config; review broad cleanup changes before proceeding." : "Use aft_safety checkpoint/undo before broad cleanup.";
35151
35971
  pi.registerTool({
35152
35972
  name: "aft_import",
35153
35973
  label: "import",
35154
- description: "Language-aware import management. Supports TS, JS, TSX, Python, Rust, Go, Solidity, Java, C#, PHP, Kotlin, Scala, Swift, Ruby, Lua, C, C++, Perl, Vue. Ops: `add`, `remove`, `organize`. Use aft_safety checkpoint/undo before broad cleanup.",
35974
+ description: `Language-aware import management. Supports TS, JS, TSX, Python, Rust, Go, Solidity, Java, C#, PHP, Kotlin, Scala, Swift, Ruby, Lua, C, C++, Perl, Vue. Ops: \`add\`, \`remove\`, \`organize\`. ${organizeRecovery}`,
35155
35975
  parameters: ImportParams,
35156
35976
  async execute(_toolCallId, params, _signal, _onUpdate, extCtx) {
35157
35977
  if ((params.op === "add" || params.op === "remove") && isEmptyParam(params.module)) {
@@ -35513,6 +36333,12 @@ function navigateParamsSchema() {
35513
36333
  })),
35514
36334
  toFile: Type9.Optional(Type9.String({
35515
36335
  description: "Optional target file for trace_to_symbol; required when toSymbol exists in multiple files"
36336
+ })),
36337
+ includeTests: Type9.Optional(Type9.Boolean({
36338
+ description: "Include test files in callers/paths. Defaults to false; tests are hidden."
36339
+ })),
36340
+ includeUnresolved: Type9.Optional(Type9.Boolean({
36341
+ description: "Show every unresolved external/stdlib call individually. Defaults to false; unresolved leaf calls are collapsed into one summary per parent."
35516
36342
  }))
35517
36343
  });
35518
36344
  }
@@ -35520,7 +36346,9 @@ function buildNavigateSections(args, payload, theme) {
35520
36346
  const themeAdapter = {
35521
36347
  fg: (role, s) => theme.fg(role, s)
35522
36348
  };
35523
- return formatCallgraphSections(args.op, payload, themeAdapter);
36349
+ return formatCallgraphSections(args.op, payload, themeAdapter, {
36350
+ includeUnresolved: coerceBoolean(args.includeUnresolved)
36351
+ });
35524
36352
  }
35525
36353
  function renderNavigateCall(args, theme, context) {
35526
36354
  const summary = [
@@ -35540,7 +36368,7 @@ function registerNavigateTool(pi, ctx) {
35540
36368
  pi.registerTool({
35541
36369
  name: "aft_callgraph",
35542
36370
  label: "callgraph",
35543
- description: "Answer code-relationship questions from a real call graph — instead of grep + read chains. Reach for this whenever the question is about how symbols connect. All ops require both `filePath` and `symbol`. Use `callers` for call sites (before renaming/signature changes), `impact` for blast radius (what breaks if a symbol changes), `call_tree` for what a function calls, `trace_to` for how execution reaches a symbol from entry points, `trace_to_symbol` for the shortest path from one symbol to another (requires `toSymbol`; if ambiguous, the error returns candidate files — retry with `toFile`), `trace_data` to follow a value across assignments/params. Markers: ~ = edge resolved by name only (may point at the wrong same-named symbol); [unresolved] = callee not resolved to a definition, so the location shown is the call site. Unmarked edges are resolved exactly.",
36371
+ description: "Answer code-relationship questions from a real call graph — instead of grep + read chains. Reach for this whenever the question is about how symbols connect. Use aft_zoom with `callgraph:true` for one-level forward calls-out while reading source; use aft_callgraph only for reverse callers or multi-level traces so you do not double-fetch the same relationships. All ops require both `filePath` and `symbol`. Use `callers` for call sites (before renaming/signature changes), `impact` for blast radius (what breaks if a symbol changes), `call_tree` for what a function calls, `trace_to` for how execution reaches a symbol from entry points, `trace_to_symbol` for the shortest path from one symbol to another (requires `toSymbol`; if ambiguous, the error returns candidate files — retry with `toFile`), `trace_data` to follow a value across assignments/params. Markers: ~ = edge resolved by name only (may point at the wrong same-named symbol); [unresolved] = callee not resolved to a definition, so the location shown is the call site. Unmarked edges are resolved exactly. By default, unresolved external/stdlib leaf calls in call_tree are collapsed into one summary per parent; pass includeUnresolved=true to show every unresolved edge individually.",
35544
36372
  parameters: navigateParamsSchema(),
35545
36373
  async execute(_toolCallId, params, _signal, _onUpdate, extCtx) {
35546
36374
  if (isEmptyParam(params.filePath)) {
@@ -35581,15 +36409,19 @@ function registerNavigateTool(pi, ctx) {
35581
36409
  req.toSymbol = params.toSymbol;
35582
36410
  if (toFile !== undefined)
35583
36411
  req.toFile = toFile;
36412
+ if (!isEmptyParam(params.includeTests))
36413
+ req.include_tests = coerceBoolean(params.includeTests);
35584
36414
  try {
35585
36415
  const response = await callBridge(bridge, params.op, req, extCtx);
35586
- return textResult(formatCallgraphSections(params.op, response, PLAIN_CALLGRAPH_THEME).join(`
36416
+ return textResult(formatCallgraphSections(params.op, response, PLAIN_CALLGRAPH_THEME, {
36417
+ includeUnresolved: coerceBoolean(params.includeUnresolved)
36418
+ }).join(`
35587
36419
  `), response);
35588
- } catch (error50) {
35589
- if (error50 instanceof BridgeError && CALLGRAPH_SOFT_CODES.has(error50.code)) {
35590
- return textResult(error50.message);
36420
+ } catch (error53) {
36421
+ if (error53 instanceof BridgeError && CALLGRAPH_SOFT_CODES.has(error53.code)) {
36422
+ return textResult(error53.message);
35591
36423
  }
35592
- throw error50;
36424
+ throw error53;
35593
36425
  }
35594
36426
  },
35595
36427
  renderCall(args, theme, context) {
@@ -35610,6 +36442,9 @@ var OutlineParams = Type10.Object({
35610
36442
  }),
35611
36443
  files: Type10.Optional(Type10.Boolean({
35612
36444
  description: "Directory-only mode: when true, target must be a directory or array of directories and the result is a flat file tree with path, language, symbol count, and byte size instead of a symbol outline."
36445
+ })),
36446
+ includeTests: Type10.Optional(Type10.Boolean({
36447
+ description: "Directory outline only: include test files. Defaults to false; tests are hidden."
35613
36448
  }))
35614
36449
  });
35615
36450
  var ZoomTarget = Type10.Object({
@@ -35650,6 +36485,10 @@ async function assertReadPathPermissions(extCtx, ctx, paths) {
35650
36485
  function zoomTargetLabel(args) {
35651
36486
  return args.filePath ?? args.url ?? "(no target)";
35652
36487
  }
36488
+ function zoomExtraCallSites(call) {
36489
+ const extraCount = call.extra_count;
36490
+ return typeof extraCount === "number" && Number.isInteger(extraCount) && extraCount > 0 ? ` +${extraCount}` : "";
36491
+ }
35653
36492
  function buildOutlineSections(text, theme) {
35654
36493
  const trimmed = text.trim();
35655
36494
  if (!trimmed)
@@ -35712,11 +36551,11 @@ function buildZoomSections(args, payload, theme) {
35712
36551
  const callsOut = annotations ? asRecords2(annotations.calls_out) : [];
35713
36552
  const calledBy = annotations ? asRecords2(annotations.called_by) : [];
35714
36553
  if (callsOut.length > 0) {
35715
- lines.push(`${theme.fg("muted", "calls out")}`, callsOut.map((call) => ` ↳ ${asString2(call.name) ?? "(unknown)"}${typeof call.line === "number" ? `:${call.line}` : ""}`).join(`
36554
+ lines.push(`${theme.fg("muted", "calls out")}`, callsOut.map((call) => ` ↳ ${asString2(call.name) ?? "(unknown)"}${typeof call.line === "number" ? `:${call.line}` : ""}${zoomExtraCallSites(call)}`).join(`
35716
36555
  `));
35717
36556
  }
35718
36557
  if (calledBy.length > 0) {
35719
- lines.push(`${theme.fg("muted", "called by")}`, calledBy.map((call) => ` ↳ ${asString2(call.name) ?? "(unknown)"}${typeof call.line === "number" ? `:${call.line}` : ""}`).join(`
36558
+ lines.push(`${theme.fg("muted", "called by")}`, calledBy.map((call) => ` ↳ ${asString2(call.name) ?? "(unknown)"}${typeof call.line === "number" ? `:${call.line}` : ""}${zoomExtraCallSites(call)}`).join(`
35720
36559
  `));
35721
36560
  }
35722
36561
  return lines.join(`
@@ -35761,6 +36600,8 @@ function registerReadingTools(pi, ctx, surface) {
35761
36600
  label: "outline",
35762
36601
  description: `Structural outline of source code, documentation files, or remote URLs. For code, returns symbols (functions, classes, types) with line ranges. For Markdown and HTML, returns heading hierarchy. Use this to explore structure before reading specific sections with aft_zoom. Set \`files: true\` with a directory target for a flat indexed file tree with language, symbol count, and byte metadata.
35763
36602
 
36603
+ For understanding a specific feature, prefer aft_search + aft_zoom on named symbols; use aft_outline on a whole directory only for high-level structure mapping. aft_zoom with \`callgraph:true\` gives one-level forward calls-out; use aft_callgraph only for reverse callers or multi-level traces.
36604
+
35764
36605
  Pass a single \`target\`:
35765
36606
  • file path → outline that file (with signatures)
35766
36607
  • directory path → outline source files under it (recursively, up to 200 files)
@@ -35771,6 +36612,8 @@ Pass a single \`target\`:
35771
36612
  const bridge = bridgeFor(ctx, extCtx.cwd);
35772
36613
  const target = coerceTargetParam(params.target);
35773
36614
  const filesMode = coerceBoolean(params.files);
36615
+ const hasIncludeTests = !isEmptyParam(params.includeTests);
36616
+ const includeTests = coerceBoolean(params.includeTests);
35774
36617
  const isArray = Array.isArray(target) && target.length > 0;
35775
36618
  if (filesMode) {
35776
36619
  if (Array.isArray(target)) {
@@ -35826,7 +36669,7 @@ Pass a single \`target\`:
35826
36669
  } catch {}
35827
36670
  await assertReadPathPermissions(extCtx, ctx, resolvedTarget);
35828
36671
  if (isDirectory) {
35829
- const response2 = await callBridge(bridge, "outline", { directory: resolvedTarget }, extCtx);
36672
+ const response2 = await callBridge(bridge, "outline", { directory: resolvedTarget, ...hasIncludeTests ? { includeTests } : {} }, extCtx);
35830
36673
  return textResult(JSON.stringify(response2, null, 2), response2);
35831
36674
  }
35832
36675
  const response = await callBridge(bridge, "outline", { file: resolvedTarget }, extCtx);
@@ -36483,7 +37326,7 @@ function registerSemanticTool(pi, ctx) {
36483
37326
  name: "aft_search",
36484
37327
  label: "search",
36485
37328
  description: [
36486
- "Search code with one tool: concepts, identifiers, error strings, regex, literals, and filenames are auto-routed to the right engine and returned ranked. Use it for any code search including when you only know what the code does, not what it's named ('where is rate limiting handled', 'retry logic', '^export', 'Cargo.lock').",
37329
+ "Search code with one tool: concepts, identifiers, error strings, regex, literals, and filenames are auto-routed to the right engine and returned ranked. For conceptual 'how does X work' queries, phrase a full natural-language sentence the semantic lane is NL-aware and matches intent against docstrings and comments ('how does the ORM build and execute a query', 'where is rate limiting handled'), not just keywords. Exact names, strings, and regex stay terse ('^export', 'Cargo.lock').",
36487
37330
  "",
36488
37331
  "Set hint to 'regex', 'literal', or 'semantic' to force a lane."
36489
37332
  ].join(`
@@ -36677,11 +37520,11 @@ var PLUGIN_VERSION = (() => {
36677
37520
  return "0.0.0";
36678
37521
  }
36679
37522
  })();
36680
- var ANNOUNCEMENT_VERSION = "0.41.0";
37523
+ var ANNOUNCEMENT_VERSION = "0.42.0";
36681
37524
  var ANNOUNCEMENT_FEATURES = [
36682
- "Search now works on repositories of any size: the trigram index behind grep and aft_search is disk-backed, so it uses a fixed, small amount of memory (Chromium dropped from ~14 GB to under 800 MB) and the old 20,000-file limit that disabled it on large repos is gone.",
36683
- "Call-graph navigation (aft_callgraph, symbol move) no longer has a 5,000-file limit it works on repositories of any size.",
36684
- "Semantic search (aft_search) now covers Java, Kotlin, Ruby, Swift, Scala, Lua, Perl, and R, in addition to the languages already supported."
37525
+ "Navigation and search tools now return leaner output: aft_zoom on a large class/struct returns a member menu instead of the whole body, aft_callgraph collapses standard-library noise, and aft_search expands only the top match within a budget substantially less context per call, same answers.",
37526
+ "Backups behind aft_safety undo are now configurable (backup.enabled, max_depth, max_file_size), and edits are faster (one appended snapshot instead of rewriting the whole stack).",
37527
+ "Editing Rust code with &raw and files whose paths contain [brackets] or {braces} (e.g. Next.js dynamic routes) no longer fails."
36685
37528
  ];
36686
37529
  var ANNOUNCEMENT_FOOTER = "Join us on Discord: https://discord.gg/DSa65w8wuf";
36687
37530
  var ALL_ONLY_TOOLS = new Set(["aft_callgraph", "aft_delete", "aft_move", "aft_refactor"]);
@@ -37045,7 +37888,7 @@ ${lines}
37045
37888
  if (surface.importTool) {
37046
37889
  registerImportTools(pi, ctx);
37047
37890
  }
37048
- if (surface.safety) {
37891
+ if (surface.safety && config2.backup?.enabled !== false) {
37049
37892
  registerSafetyTool(pi, ctx);
37050
37893
  }
37051
37894
  if (surface.astSearch || surface.astReplace) {