@wirecat/mail-cli 0.8.0 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (151) hide show
  1. package/CHANGELOG.md +51 -0
  2. package/dist/bin/mail.js +2 -2
  3. package/dist/bundle/{all-profiles-MXGDUBAM.js → all-profiles-OJPRIFKU.js} +9 -9
  4. package/dist/bundle/{anthropic-A2QA4W7L.js → anthropic-3AXHD4WH.js} +6 -6
  5. package/dist/bundle/{app-server-PMIMK6FK.js → app-server-V4KHCUGE.js} +45 -46
  6. package/dist/bundle/{bun-3UW3LFNL.js → bun-ISYNUTQJ.js} +2 -2
  7. package/dist/bundle/{bun-sqlite-TGFZFKAX.js → bun-sqlite-FH3D4AXL.js} +5 -5
  8. package/dist/bundle/{chunk-W7H3PZ67.js → chunk-2TTCKOQ7.js} +2 -2
  9. package/dist/bundle/{chunk-U4IF2MOB.js → chunk-35Y3INBK.js} +2 -2
  10. package/dist/bundle/{chunk-Q5DOXSBM.js → chunk-44LVUMS2.js} +1 -1
  11. package/dist/bundle/{chunk-ZKAT6I2I.js → chunk-4D52FA34.js} +1 -1
  12. package/dist/bundle/{chunk-L3KMVMRJ.js → chunk-4DPICEPQ.js} +2 -2
  13. package/dist/bundle/{chunk-PXCIM6D5.js → chunk-4GPPRLIG.js} +7 -42
  14. package/dist/bundle/{chunk-BEUQ2X7U.js → chunk-5TACUBRJ.js} +8 -8
  15. package/dist/bundle/{chunk-EN3UZPGB.js → chunk-6LNRNQHJ.js} +4 -4
  16. package/dist/bundle/{chunk-6U6Z3GXR.js → chunk-6QNPJSRM.js} +6 -6
  17. package/dist/bundle/{chunk-5W74YMCK.js → chunk-6UT3MXOB.js} +3 -3
  18. package/dist/bundle/{chunk-TCWJYOZV.js → chunk-AJ4JS2ZR.js} +36 -11
  19. package/dist/bundle/{chunk-NEBO3NZU.js → chunk-BYQ3Z6UL.js} +3 -3
  20. package/dist/bundle/{chunk-Z5GDZ3QF.js → chunk-DN54W657.js} +2 -2
  21. package/dist/bundle/{chunk-RFWTPSJX.js → chunk-F3QDSQ7V.js} +34 -28
  22. package/dist/bundle/{chunk-YS2WUWY7.js → chunk-FYMQPAE5.js} +4 -4
  23. package/dist/bundle/{chunk-NI6WX55Z.js → chunk-G2WDY5XB.js} +2 -2
  24. package/dist/bundle/{chunk-EU35YQXE.js → chunk-GAIVTJ3E.js} +121 -32
  25. package/dist/bundle/{chunk-J5RKMQ6A.js → chunk-GFCNSU3B.js} +48 -48
  26. package/dist/bundle/{chunk-L2ZHPIFC.js → chunk-GUFWLTOW.js} +2 -2
  27. package/dist/bundle/{chunk-CMNFLAUG.js → chunk-GYNHU56E.js} +4 -4
  28. package/dist/bundle/{chunk-BCDPLG7T.js → chunk-HVVLSCFB.js} +1 -1
  29. package/dist/bundle/{chunk-EVO77D3Y.js → chunk-IG2WXKIT.js} +8 -8
  30. package/dist/bundle/{chunk-QBBKSCQD.js → chunk-IWHXM2S7.js} +1620 -671
  31. package/dist/bundle/{chunk-KBKEZV4L.js → chunk-IXYKM7OJ.js} +13 -13
  32. package/dist/bundle/{chunk-ZISFMUYB.js → chunk-JAWJZTFL.js} +18 -18
  33. package/dist/bundle/{chunk-PEF637VV.js → chunk-JIIEJLAX.js} +4 -4
  34. package/dist/bundle/{chunk-DLB2JPLU.js → chunk-JNUKTAMZ.js} +1 -1
  35. package/dist/bundle/{chunk-DM4ULDS3.js → chunk-K2F7YMMM.js} +6 -6
  36. package/dist/bundle/{chunk-NWKLBZN5.js → chunk-KJP2B65C.js} +30 -30
  37. package/dist/bundle/{chunk-CRS63C3T.js → chunk-KQXLRAHT.js} +2 -5
  38. package/dist/bundle/{chunk-4QDBMYK4.js → chunk-KVN4RY7E.js} +52 -53
  39. package/dist/bundle/{chunk-DYCPBLUC.js → chunk-L3PVAY3M.js} +2 -2
  40. package/dist/bundle/{chunk-W5J6I5GW.js → chunk-LIQ5LICB.js} +3 -3
  41. package/dist/bundle/{chunk-SZ5PKNDF.js → chunk-LXHLQ6RK.js} +7 -7
  42. package/dist/bundle/{chunk-XWNCXFR5.js → chunk-MDIRW3AT.js} +2 -2
  43. package/dist/bundle/{chunk-LN7TNZIS.js → chunk-N6P55LDU.js} +84 -8
  44. package/dist/bundle/{chunk-7JUTNCQX.js → chunk-NBQQ2ZTF.js} +19 -14
  45. package/dist/bundle/{chunk-NAIJNJZZ.js → chunk-NSDOYHIS.js} +10 -8
  46. package/dist/bundle/{chunk-UR6WHUJF.js → chunk-OHC4GVWV.js} +2 -2
  47. package/dist/bundle/{chunk-6JK46V5X.js → chunk-PLPSFJO6.js} +6 -6
  48. package/dist/bundle/{chunk-RVZ4JIRR.js → chunk-PSXAC6OO.js} +1 -1
  49. package/dist/bundle/{chunk-WS4L47DG.js → chunk-QB54TE52.js} +1 -1
  50. package/dist/bundle/{chunk-KF4YULWC.js → chunk-QPQSMJBW.js} +10 -10
  51. package/dist/bundle/{chunk-WWNAQ75T.js → chunk-S64N24ON.js} +3 -3
  52. package/dist/bundle/{chunk-J6ACLZKV.js → chunk-SW5NVASW.js} +9 -9
  53. package/dist/bundle/{chunk-FSBKLJXM.js → chunk-SYBMOE6F.js} +865 -838
  54. package/dist/bundle/{chunk-VSDVH2M2.js → chunk-T3AGR4TI.js} +4840 -894
  55. package/dist/bundle/{chunk-KEZHPPMI.js → chunk-TTKNBUMT.js} +45 -5
  56. package/dist/bundle/{chunk-ROZBXOES.js → chunk-TZGQPTZ2.js} +1 -1
  57. package/dist/bundle/{chunk-AO3XYONW.js → chunk-UDJIC6YL.js} +67 -30
  58. package/dist/bundle/{chunk-2MQXXPPK.js → chunk-V6K2GX2Y.js} +17 -17
  59. package/dist/bundle/{chunk-2KZJWBXB.js → chunk-VEXXVLBM.js} +3 -3
  60. package/dist/bundle/{chunk-TMQA4KR7.js → chunk-WL7CYT7O.js} +1 -1
  61. package/dist/bundle/{chunk-6J3DKKOV.js → chunk-X37KLD23.js} +14 -14
  62. package/dist/bundle/{chunk-5PWKPRTD.js → chunk-XTIQFMZH.js} +4 -4
  63. package/dist/bundle/{chunk-OAQ4UB6V.js → chunk-YDUES6ET.js} +4 -4
  64. package/dist/bundle/{chunk-VGR3AGAC.js → chunk-YRZ23RCS.js} +164 -59
  65. package/dist/bundle/command-contract-TW44FY47.js +33 -0
  66. package/dist/bundle/{decode-NF4TGOR3.js → decode-FM4C2WWG.js} +5 -5
  67. package/dist/bundle/{dispatch-5C6XNGEE.js → dispatch-K3HG4RYT.js} +8 -8
  68. package/dist/bundle/{dist-DVYY3YFG.js → dist-7LNVI7VB.js} +17 -13
  69. package/dist/bundle/{echarts-F3USGP5B.js → echarts-5C2A72XM.js} +2 -2
  70. package/dist/bundle/{embed-2RXV3BEC.js → embed-N56P6YVY.js} +6 -6
  71. package/dist/bundle/{embedder-I2SJMC6N.js → embedder-QLYKFLOL.js} +9 -9
  72. package/dist/bundle/{failure-YRGRZBTX.js → failure-5ZLVZTRU.js} +2 -2
  73. package/dist/bundle/{first-run-3GA7YCKZ.js → first-run-VMF4PJ7Q.js} +11 -11
  74. package/dist/bundle/first-screen-ZN7ODW5K.js +31 -0
  75. package/dist/bundle/{instructions-VHI5CWH5.js → instructions-QA5FHDOJ.js} +1 -1
  76. package/dist/bundle/mail.js +12 -12
  77. package/dist/bundle/{mcp-B25MZCS7.js → mcp-LO2XDBBC.js} +2 -2
  78. package/dist/bundle/{node-4RBB3RDY.js → node-OXJZWUYZ.js} +2 -2
  79. package/dist/bundle/{node-sqlite-FWYX3P2D.js → node-sqlite-7GCEI67B.js} +5 -5
  80. package/dist/bundle/{oauth-6JKKRGLX.js → oauth-VTPIYBTP.js} +7 -7
  81. package/dist/bundle/{open-7JSNC3MR.js → open-7XX3YF2X.js} +4 -4
  82. package/dist/bundle/{openai-ASLWL3D6.js → openai-D3KRCXSY.js} +14 -14
  83. package/dist/bundle/{process-AB2D2G2Q.js → process-KFI7SXQD.js} +1 -1
  84. package/dist/bundle/{program-ZJPQ3IDU.js → program-OJUWUHHC.js} +1355 -864
  85. package/dist/bundle/{prompt-JDFVQR3L.js → prompt-TBZT3APW.js} +5 -5
  86. package/dist/bundle/{recognize-PKYA4HRC.js → recognize-WQSE5ZPL.js} +4 -4
  87. package/dist/bundle/{remote-USBVVO4O.js → remote-J5HHRNVQ.js} +7 -7
  88. package/dist/bundle/{rerank-UBMV6KO6.js → rerank-DP2Y3WDT.js} +7 -7
  89. package/dist/bundle/{serve-SVS3YOYS.js → serve-VXPOQDQO.js} +9 -9
  90. package/dist/bundle/{server-7PZMYXY6.js → server-OSBNGA2F.js} +37 -38
  91. package/dist/bundle/server-XHWSCXVX.js +62 -0
  92. package/dist/bundle/{sqlite-runtime-IDPTXAM7.js → sqlite-runtime-XY32WOIT.js} +5 -5
  93. package/dist/bundle/{state-6G2TSVP7.js → state-KPOPMR6O.js} +6 -6
  94. package/dist/bundle/{store-7A464D4X.js → store-FWRGNGP3.js} +25 -17
  95. package/dist/bundle/{store-L56GFI4P.js → store-UBI2YCRC.js} +13 -13
  96. package/dist/bundle/store-maintenance-command-3ZXPEIGF.js +52 -0
  97. package/dist/commands/login.d.ts.map +1 -1
  98. package/dist/commands/login.js +2 -1
  99. package/dist/commands/login.js.map +1 -1
  100. package/dist/commands/session-start.d.ts.map +1 -1
  101. package/dist/commands/session-start.js +3 -3
  102. package/dist/commands/session-start.js.map +1 -1
  103. package/dist/commands/sync.d.ts.map +1 -1
  104. package/dist/commands/sync.js +22 -7
  105. package/dist/commands/sync.js.map +1 -1
  106. package/dist/config.d.ts +6 -0
  107. package/dist/config.d.ts.map +1 -1
  108. package/dist/mail/imap/connection.d.ts.map +1 -1
  109. package/dist/mail/imap/connection.js +6 -4
  110. package/dist/mail/imap/connection.js.map +1 -1
  111. package/dist/mail/imap/errors.d.ts +7 -0
  112. package/dist/mail/imap/errors.d.ts.map +1 -1
  113. package/dist/mail/imap/errors.js +8 -4
  114. package/dist/mail/imap/errors.js.map +1 -1
  115. package/dist/mail/imap/read.d.ts.map +1 -1
  116. package/dist/mail/imap/read.js +36 -20
  117. package/dist/mail/imap/read.js.map +1 -1
  118. package/dist/mail/imap/search.d.ts +7 -2
  119. package/dist/mail/imap/search.d.ts.map +1 -1
  120. package/dist/mail/imap/search.js +13 -7
  121. package/dist/mail/imap/search.js.map +1 -1
  122. package/dist/mail/imap/write.d.ts.map +1 -1
  123. package/dist/mail/imap/write.js +2 -1
  124. package/dist/mail/imap/write.js.map +1 -1
  125. package/dist/mail/organise.d.ts.map +1 -1
  126. package/dist/mail/organise.js +92 -87
  127. package/dist/mail/organise.js.map +1 -1
  128. package/dist/mail/send.d.ts.map +1 -1
  129. package/dist/mail/send.js +26 -5
  130. package/dist/mail/send.js.map +1 -1
  131. package/dist/oauth.d.ts +2 -8
  132. package/dist/oauth.d.ts.map +1 -1
  133. package/dist/oauth.js +6 -40
  134. package/dist/oauth.js.map +1 -1
  135. package/dist/providers.d.ts.map +1 -1
  136. package/dist/providers.js +2 -1
  137. package/dist/providers.js.map +1 -1
  138. package/dist/reasons.d.ts.map +1 -1
  139. package/dist/reasons.js +0 -3
  140. package/dist/reasons.js.map +1 -1
  141. package/dist/version.d.ts +1 -1
  142. package/dist/version.d.ts.map +1 -1
  143. package/dist/version.js +1 -1
  144. package/dist/version.js.map +1 -1
  145. package/package.json +3 -3
  146. package/dist/bundle/chunk-NSODLSEL.js +0 -3604
  147. package/dist/bundle/command-contract-Q32SL5KX.js +0 -34
  148. package/dist/bundle/first-screen-JFIXKYAK.js +0 -32
  149. package/dist/bundle/server-KA7Q5XCL.js +0 -63
  150. package/dist/bundle/store-maintenance-command-2LM4GOI3.js +0 -52
  151. /package/dist/bundle/{chunk-EKRM2QJB.js → chunk-MRLSUCHT.js} +0 -0
@@ -3,26 +3,26 @@ const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  executableEnvironment,
5
5
  executableOnPath
6
- } from "./chunk-ROZBXOES.js";
6
+ } from "./chunk-TZGQPTZ2.js";
7
7
  import {
8
8
  require_cross_spawn
9
9
  } from "./chunk-D72URWJE.js";
10
10
  import {
11
11
  loadConfigFile,
12
12
  saveConfigFile
13
- } from "./chunk-ZISFMUYB.js";
13
+ } from "./chunk-JAWJZTFL.js";
14
14
  import {
15
15
  number,
16
16
  object,
17
17
  optional,
18
18
  string
19
- } from "./chunk-NAIJNJZZ.js";
19
+ } from "./chunk-NSDOYHIS.js";
20
20
  import {
21
21
  __name,
22
22
  __toESM
23
23
  } from "./chunk-ZVVMGPBJ.js";
24
24
 
25
- // node_modules/.pnpm/@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/update/index.js
25
+ // node_modules/.pnpm/@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/update/index.js
26
26
  var import_cross_spawn = __toESM(require_cross_spawn(), 1);
27
27
  import { existsSync } from "node:fs";
28
28
  var updateCommand = /* @__PURE__ */ __name((installer, packageName) => {
@@ -18,9 +18,9 @@ import {
18
18
  strictObject,
19
19
  string,
20
20
  unknown
21
- } from "./chunk-NAIJNJZZ.js";
21
+ } from "./chunk-NSDOYHIS.js";
22
22
 
23
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/entities/fields.js
23
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/entities/fields.js
24
24
  var text = string();
25
25
  var id = pipe(string(), minLength(1));
26
26
  var time = isoTime;
@@ -44,7 +44,7 @@ var author = strictObject({
44
44
  name: nullable(text)
45
45
  });
46
46
 
47
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/entities/knowledge-lists.js
47
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/entities/knowledge-lists.js
48
48
  var organization = strictObject({
49
49
  id,
50
50
  ref: reference,
@@ -74,7 +74,7 @@ var reminder = strictObject({
74
74
  receipt: nullable(text)
75
75
  });
76
76
 
77
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/entities/note.js
77
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/entities/note.js
78
78
  var link = {
79
79
  target_text: nullable(text),
80
80
  kind: text,
@@ -1,14 +1,18 @@
1
1
  import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
+ import {
4
+ formatMeetingReference,
5
+ parseMeetingReference
6
+ } from "./chunk-KVN4RY7E.js";
3
7
  import {
4
8
  CliError,
5
9
  singleLine
6
- } from "./chunk-L3KMVMRJ.js";
10
+ } from "./chunk-4DPICEPQ.js";
7
11
  import {
8
12
  __name
9
13
  } from "./chunk-ZVVMGPBJ.js";
10
14
 
11
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/domain/locator.js
15
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/domain/locator.js
12
16
  var SCHEME = "msg:";
13
17
  var formatLocator = /* @__PURE__ */ __name(({ provider, account, chat, message }) => SCHEME + [provider, account, chat, message].map(encodeURIComponent).join("/"), "formatLocator");
14
18
  var isLocator = /* @__PURE__ */ __name((reference) => reference.trim().startsWith(SCHEME), "isLocator");
@@ -22,7 +26,7 @@ var parseLocator = /* @__PURE__ */ __name((reference) => {
22
26
  return { provider, account, chat, message };
23
27
  }, "parseLocator");
24
28
 
25
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/domain/references.js
29
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/domain/references.js
26
30
  var SIMPLE_REFERENCES = [
27
31
  "note",
28
32
  "document",
@@ -33,75 +37,149 @@ var SIMPLE_REFERENCES = [
33
37
  "memory",
34
38
  "fact",
35
39
  "bot",
40
+ "event",
36
41
  "entity"
37
42
  ];
38
- var parts = /* @__PURE__ */ __name((rest, count, reference, shape) => {
43
+ var malformed = /* @__PURE__ */ __name((text, shape) => new CliError("validation_error", `"${singleLine(text)}" is not a reference \u2014 expected ${shape}`, {
44
+ reason: "ref.malformed"
45
+ }), "malformed");
46
+ var parts = /* @__PURE__ */ __name((rest, count, text, shape) => {
39
47
  const split = rest.split("/");
40
48
  if (split.length !== count || split.some((part) => part === ""))
41
- throw new CliError("validation_error", `"${singleLine(reference)}" is not a reference \u2014 expected ${shape}`);
49
+ throw malformed(text, shape);
42
50
  return split.map(decodeURIComponent);
43
51
  }, "parts");
44
- var formatReference = /* @__PURE__ */ __name((reference) => {
45
- switch (reference.type) {
46
- case "message":
47
- return formatLocator(reference);
48
- case "chat":
49
- return `chat:${[reference.provider, reference.account, reference.chat].map(encodeURIComponent).join("/")}`;
50
- case "contact":
51
- return `contact:${[reference.provider, reference.id].map(encodeURIComponent).join("/")}`;
52
- case "folder":
53
- return reference.path === null ? `folder:${encodeURIComponent(reference.id)}` : `folder:${encodeURIComponent(reference.id)}/${encodeURIComponent(reference.path)}`;
54
- default:
55
- return `${reference.type}:${reference.id}`;
56
- }
57
- }, "formatReference");
58
- var parseReference = /* @__PURE__ */ __name((text) => {
59
- const reference = text.trim();
60
- const colon = reference.indexOf(":");
61
- const prefix = colon < 0 ? "" : reference.slice(0, colon);
62
- const rest = reference.slice(colon + 1);
63
- switch (prefix) {
64
- case "msg":
65
- return { type: "message", ...parseLocator(reference) };
66
- case "chat": {
67
- const [provider, account, chat] = parts(rest, 3, reference, "chat:<provider>/<account>/<chat>");
52
+ var encoded = /* @__PURE__ */ __name((...values) => values.map(encodeURIComponent).join("/"), "encoded");
53
+ var folderPath = /* @__PURE__ */ __name((path) => {
54
+ const clean = path.split("/").filter((part) => part !== "" && part !== ".").join("/");
55
+ return clean === "" ? path.trim() === "" ? "" : null : clean;
56
+ }, "folderPath");
57
+ var MEETING_SHAPE = "meeting:<account>/<meeting>[/<transcript>[/<cue>]] with safe integer ids";
58
+ var kind = /* @__PURE__ */ __name((spec) => spec, "kind");
59
+ var simple = /* @__PURE__ */ __name((prefix) => kind({
60
+ prefix,
61
+ type: prefix,
62
+ shape: `${prefix}:<id>`,
63
+ parse: /* @__PURE__ */ __name((rest, text) => {
64
+ if (!rest.trim())
65
+ throw new CliError("validation_error", `"${singleLine(text)}" names no ${prefix}`, {
66
+ reason: "ref.malformed"
67
+ });
68
+ return { type: prefix, id: rest };
69
+ }, "parse"),
70
+ format: /* @__PURE__ */ __name((reference) => `${reference.type}:${reference.id}`, "format")
71
+ }), "simple");
72
+ var REF_KINDS = [
73
+ kind({
74
+ prefix: "msg",
75
+ type: "message",
76
+ shape: "msg:<provider>/<account>/<chat>/<message>",
77
+ parse: /* @__PURE__ */ __name((_, text) => {
78
+ try {
79
+ return { type: "message", ...parseLocator(text) };
80
+ } catch {
81
+ throw malformed(text, "msg:<provider>/<account>/<chat>/<message>");
82
+ }
83
+ }, "parse"),
84
+ format: formatLocator
85
+ }),
86
+ kind({
87
+ prefix: "chat",
88
+ type: "chat",
89
+ shape: "chat:<provider>/<account>/<chat>",
90
+ parse: /* @__PURE__ */ __name((rest, text) => {
91
+ const [provider, account, chat] = parts(rest, 3, text, "chat:<provider>/<account>/<chat>");
68
92
  return { type: "chat", provider, account, chat };
69
- }
70
- case "contact": {
71
- const [provider, id] = parts(rest, 2, reference, "contact:<provider>/<id>");
93
+ }, "parse"),
94
+ format: /* @__PURE__ */ __name(({ provider, account, chat }) => `chat:${encoded(provider, account, chat)}`, "format")
95
+ }),
96
+ kind({
97
+ prefix: "contact",
98
+ type: "contact",
99
+ shape: "contact:<provider>/<id>",
100
+ parse: /* @__PURE__ */ __name((rest, text) => {
101
+ const [provider, id] = parts(rest, 2, text, "contact:<provider>/<id>");
72
102
  return { type: "contact", provider, id };
73
- }
74
- case "folder": {
103
+ }, "parse"),
104
+ format: /* @__PURE__ */ __name(({ provider, id }) => `contact:${encoded(provider, id)}`, "format")
105
+ }),
106
+ kind({
107
+ prefix: "folder",
108
+ type: "folder",
109
+ shape: "folder:<id>[/<path>]",
110
+ parse: /* @__PURE__ */ __name((rest, text) => {
75
111
  const slash = rest.indexOf("/");
76
112
  const id = decodeURIComponent(slash < 0 ? rest : rest.slice(0, slash));
77
113
  const path = slash < 0 ? null : folderPath(decodeURIComponent(rest.slice(slash + 1)));
78
114
  if (!id.trim() || path === "")
79
- throw new CliError("validation_error", `"${singleLine(reference)}" is not a reference \u2014 expected folder:<id>[/<path>]`);
115
+ throw malformed(text, "folder:<id>[/<path>]");
80
116
  return { type: "folder", id, path };
81
- }
82
- default:
83
- if (SIMPLE_REFERENCES.includes(prefix)) {
84
- if (!rest.trim())
85
- throw new CliError("validation_error", `"${singleLine(reference)}" names no ${prefix}`);
86
- return { type: prefix, id: rest };
117
+ }, "parse"),
118
+ format: /* @__PURE__ */ __name(({ id, path }) => path === null ? `folder:${encodeURIComponent(id)}` : `folder:${encoded(id, path)}`, "format")
119
+ }),
120
+ kind({
121
+ prefix: "meeting",
122
+ type: "meeting",
123
+ shape: MEETING_SHAPE,
124
+ parse: /* @__PURE__ */ __name((_, text) => {
125
+ try {
126
+ return parseMeetingReference(text);
127
+ } catch {
128
+ throw malformed(text, MEETING_SHAPE);
87
129
  }
88
- throw new CliError("validation_error", `"${singleLine(reference)}" is not a reference \u2014 expected msg:, chat:, contact:, folder:, ${SIMPLE_REFERENCES.filter((one) => one !== "entity").join(":, ")}:`);
130
+ }, "parse"),
131
+ format: formatMeetingReference
132
+ }),
133
+ ...SIMPLE_REFERENCES.map(simple)
134
+ ];
135
+ var byPrefix = new Map(REF_KINDS.map((spec) => [spec.prefix, spec]));
136
+ var byType = new Map(REF_KINDS.map((spec) => [spec.type, spec]));
137
+ var offered = REF_KINDS.map(({ prefix }) => prefix).filter((prefix) => prefix !== "entity");
138
+ var distance = /* @__PURE__ */ __name((a, b) => {
139
+ let row = Array.from({ length: b.length + 1 }, (_, at) => at);
140
+ for (const [i, x] of [...a].entries()) {
141
+ const next = [i + 1];
142
+ for (const [j, y] of [...b].entries())
143
+ next.push(Math.min(row[j + 1] + 1, next[j] + 1, row[j] + (x === y ? 0 : 1)));
144
+ row = next;
89
145
  }
146
+ return row[b.length];
147
+ }, "distance");
148
+ var nearest = /* @__PURE__ */ __name((typed) => offered.find((prefix) => typed.length >= 2 && prefix.startsWith(typed)) ?? offered.map((prefix) => ({ prefix, far: distance(typed, prefix) })).filter(({ far }) => far <= 2).sort((a, b) => a.far - b.far)[0]?.prefix, "nearest");
149
+ var unknownKind = /* @__PURE__ */ __name((text, prefix, rest) => {
150
+ const near = prefix === "" ? void 0 : nearest(prefix);
151
+ const kinds = offered.map((one) => `${one}:`).join(", ");
152
+ const hint = near === void 0 ? `; kinds: ${kinds}` : `; did you mean ${near}:${singleLine(rest)}? Kinds: ${kinds}`;
153
+ return new CliError("validation_error", `"${singleLine(text)}" is no kind of reference${hint}`, {
154
+ reason: "ref.unknown-kind"
155
+ });
156
+ }, "unknownKind");
157
+ var formatReference = /* @__PURE__ */ __name((reference) => byType.get(reference.type).format(reference), "formatReference");
158
+ var parseReference = /* @__PURE__ */ __name((text) => {
159
+ const reference = text.trim();
160
+ const colon = reference.indexOf(":");
161
+ const prefix = colon < 0 ? "" : reference.slice(0, colon);
162
+ const rest = reference.slice(colon + 1);
163
+ const spec = byPrefix.get(prefix);
164
+ if (!spec)
165
+ throw unknownKind(reference, prefix, rest);
166
+ return spec.parse(rest, reference);
90
167
  }, "parseReference");
91
- var folderPath = /* @__PURE__ */ __name((path) => {
92
- const clean = path.split("/").filter((part) => part !== "" && part !== ".").join("/");
93
- return clean === "" ? path.trim() === "" ? "" : null : clean;
94
- }, "folderPath");
95
168
  var canonicalReference = /* @__PURE__ */ __name((text) => formatReference(parseReference(text)), "canonicalReference");
169
+ var looksLikeReference = /* @__PURE__ */ __name((text) => {
170
+ const match = /^([a-z]+):\S+$/.exec(text.trim());
171
+ return match !== null && byPrefix.has(match[1]);
172
+ }, "looksLikeReference");
96
173
 
97
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/domain/providers.js
174
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/domain/providers.js
98
175
  var KINDS = ["messages", "mail", "notes", "documents", "meetings", "events"];
176
+ var MESSENGER_OPENS = { chat: "messages list", message: "messages show", contact: "contacts show" };
99
177
  var PROVIDERS = [
100
- { name: "telegram", kind: "messages", aliases: ["tg"] },
178
+ { name: "telegram", kind: "messages", aliases: ["tg"], command: "tg", opens: MESSENGER_OPENS },
101
179
  { name: "telegram-bot", kind: "messages", aliases: ["tg-bot"] },
102
- { name: "max", kind: "messages", aliases: [] },
180
+ { name: "max", kind: "messages", aliases: [], command: "max", opens: MESSENGER_OPENS },
103
181
  { name: "max-bot", kind: "messages", aliases: [] },
104
- { name: "whatsapp", kind: "messages", aliases: ["wa"] },
182
+ { name: "whatsapp", kind: "messages", aliases: ["wa"], command: "wa", opens: MESSENGER_OPENS },
105
183
  { name: "whatsapp-bot", kind: "messages", aliases: ["wa-bot"] },
106
184
  { name: "email", kind: "mail", aliases: [] },
107
185
  { name: "notes", kind: "notes", aliases: [] },
@@ -109,6 +187,17 @@ var PROVIDERS = [
109
187
  { name: "obsidian", kind: "notes", aliases: [] },
110
188
  { name: "zoom", kind: "meetings", aliases: [] }
111
189
  ];
190
+ var LABELS = {
191
+ telegram: "Telegram",
192
+ "telegram-bot": "Telegram bot",
193
+ max: "MAX",
194
+ "max-bot": "MAX bot",
195
+ whatsapp: "WhatsApp",
196
+ "whatsapp-bot": "WhatsApp bot",
197
+ "google-drive": "Google Drive",
198
+ email: "mail"
199
+ };
200
+ var providerLabel = /* @__PURE__ */ __name((provider) => LABELS[provider] ?? provider, "providerLabel");
112
201
  var FOLDER_PROVIDERS = ["local", "obsidian", "folder"];
113
202
  var isFolderProvider = /* @__PURE__ */ __name((provider) => FOLDER_PROVIDERS.includes(provider), "isFolderProvider");
114
203
  var folderProviderSql = /* @__PURE__ */ __name((column = "provider") => `${column} IN (${FOLDER_PROVIDERS.map((name) => `'${name}'`).join(", ")})`, "folderProviderSql");
@@ -123,23 +212,35 @@ var invalid = /* @__PURE__ */ __name((message) => {
123
212
  throw new CliError("validation_error", message);
124
213
  }, "invalid");
125
214
  var wordOf = /* @__PURE__ */ __name((value, what) => typeof value === "string" && WORD.test(value) ? value : invalid(`${what} is lowercase letters, digits, - and _ \u2014 not ${JSON.stringify(value)}`), "wordOf");
215
+ var OPEN_KINDS = new Set(REF_KINDS.map(({ type }) => type).filter((type) => type !== "entity"));
216
+ var COMMAND_WORDS = /^[a-z0-9][a-z0-9_-]*( [a-z0-9][a-z0-9_-]*)*$/;
217
+ var opensOf = /* @__PURE__ */ __name((value, named) => {
218
+ if (typeof value !== "object" || value === null || Array.isArray(value))
219
+ return invalid(`provider ${named}'s opens maps a kind of reference to a command`);
220
+ const known = Object.entries(value).filter(([kind2]) => OPEN_KINDS.has(kind2));
221
+ for (const [kind2, command] of known)
222
+ if (typeof command !== "string" || !COMMAND_WORDS.test(command))
223
+ invalid(`provider ${named} opens a ${kind2} with command words, not ${JSON.stringify(command)}`);
224
+ return Object.fromEntries(known);
225
+ }, "opensOf");
126
226
  var providerEntryOf = /* @__PURE__ */ __name((value) => {
127
227
  if (typeof value !== "object" || value === null || Array.isArray(value))
128
228
  return invalid("a provider entry is an object");
129
- const { name, kind, aliases = [], command } = value;
229
+ const { name, kind: kind2, aliases = [], command, opens } = value;
130
230
  const named = wordOf(name, "a provider's name");
131
- if (typeof kind !== "string" || !KINDS.includes(kind))
132
- invalid(`provider ${named}'s kind is one of ${KINDS.join(", ")} \u2014 not ${JSON.stringify(kind)}`);
231
+ if (typeof kind2 !== "string" || !KINDS.includes(kind2))
232
+ invalid(`provider ${named}'s kind is one of ${KINDS.join(", ")} \u2014 not ${JSON.stringify(kind2)}`);
133
233
  if (!Array.isArray(aliases))
134
234
  invalid(`provider ${named}'s aliases are a list`);
135
235
  return {
136
236
  name: named,
137
- kind,
237
+ kind: kind2,
138
238
  aliases: [...new Set(aliases.map((alias) => wordOf(alias, `an alias of ${named}`)))],
139
- ...command === void 0 ? {} : { command: wordOf(command, `the command of ${named}`) }
239
+ ...command === void 0 ? {} : { command: wordOf(command, `the command of ${named}`) },
240
+ ...opens === void 0 ? {} : { opens: opensOf(opens, named) }
140
241
  };
141
242
  }, "providerEntryOf");
142
- var describe = /* @__PURE__ */ __name(({ name, kind, command }) => `${name} (${kind}${command ? `, from ${command}` : ""})`, "describe");
243
+ var describe = /* @__PURE__ */ __name(({ name, kind: kind2, command }) => `${name} (${kind2}${command ? `, from ${command}` : ""})`, "describe");
143
244
  var wordsOf = /* @__PURE__ */ __name(({ name, aliases }) => [name, ...aliases], "wordsOf");
144
245
  var joined = /* @__PURE__ */ __name((known, entry) => {
145
246
  const same = known.find(({ name }) => name === entry.name);
@@ -148,7 +249,8 @@ var joined = /* @__PURE__ */ __name((known, entry) => {
148
249
  const merged = same ? {
149
250
  ...same,
150
251
  aliases: [.../* @__PURE__ */ new Set([...same.aliases, ...entry.aliases])],
151
- ...entry.command ? { command: entry.command } : {}
252
+ ...entry.command ? { command: entry.command } : {},
253
+ ...entry.opens ? { opens: { ...same.opens, ...entry.opens } } : {}
152
254
  } : entry;
153
255
  const others = known.filter((one) => one !== same);
154
256
  for (const word of wordsOf(merged)) {
@@ -188,7 +290,7 @@ var providerNamed = /* @__PURE__ */ __name((word) => {
188
290
  var kindIn = /* @__PURE__ */ __name((provider) => isFolderProvider(provider) ? "notes" : registry.find(({ name }) => name === provider)?.kind, "kindIn");
189
291
  var kindOf = /* @__PURE__ */ __name((provider) => kindIn(provider) ?? "messages", "kindOf");
190
292
 
191
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/domain/counters.js
293
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/domain/counters.js
192
294
  var COUNTER_FIELDS = ["views", "reactions", "comments"];
193
295
  var validCounter = /* @__PURE__ */ __name((value) => typeof value === "number" && Number.isFinite(value) && value >= 0, "validCounter");
194
296
  var counterValue = /* @__PURE__ */ __name((message, field) => {
@@ -225,7 +327,7 @@ var counterFreshness = /* @__PURE__ */ __name((states) => {
225
327
  return states.some((one) => one.freshness === "stale") ? "stale" : "fresh";
226
328
  }, "counterFreshness");
227
329
 
228
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/domain/rankings-options.js
330
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/domain/rankings-options.js
229
331
  var MESSAGE_MEASURES = ["views", "reactions", "forwards", "comments", "replies", "thread-size"];
230
332
  var AUTHOR_MEASURES = [
231
333
  "messages",
@@ -369,11 +471,14 @@ export {
369
471
  formatLocator,
370
472
  isLocator,
371
473
  parseLocator,
474
+ REF_KINDS,
372
475
  formatReference,
373
476
  parseReference,
374
477
  canonicalReference,
478
+ looksLikeReference,
375
479
  KINDS,
376
480
  PROVIDERS,
481
+ providerLabel,
377
482
  FOLDER_PROVIDERS,
378
483
  isFolderProvider,
379
484
  folderProviderSql,
@@ -0,0 +1,33 @@
1
+ import { createRequire as __bundleRequire } from "node:module";
2
+ const require = __bundleRequire(import.meta.url);
3
+ import {
4
+ SCHEMA_DIALECT,
5
+ commandContract,
6
+ commandPathOf,
7
+ findCommand,
8
+ outputOf
9
+ } from "./chunk-4GPPRLIG.js";
10
+ import "./chunk-T3AGR4TI.js";
11
+ import "./chunk-AJ4JS2ZR.js";
12
+ import "./chunk-SW5NVASW.js";
13
+ import "./chunk-VEXXVLBM.js";
14
+ import "./chunk-44LVUMS2.js";
15
+ import "./chunk-6LNRNQHJ.js";
16
+ import "./chunk-YDUES6ET.js";
17
+ import "./chunk-LXHLQ6RK.js";
18
+ import "./chunk-KVN4RY7E.js";
19
+ import "./chunk-PLPSFJO6.js";
20
+ import "./chunk-MDIRW3AT.js";
21
+ import "./chunk-MRLSUCHT.js";
22
+ import "./chunk-JAWJZTFL.js";
23
+ import "./chunk-NSDOYHIS.js";
24
+ import "./chunk-Y5E2WNWB.js";
25
+ import "./chunk-4DPICEPQ.js";
26
+ import "./chunk-ZVVMGPBJ.js";
27
+ export {
28
+ SCHEMA_DIALECT,
29
+ commandContract,
30
+ commandPathOf,
31
+ findCommand,
32
+ outputOf
33
+ };
@@ -3,20 +3,20 @@ const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  SAMPLE_RATE,
5
5
  decodeOgg
6
- } from "./chunk-YS2WUWY7.js";
7
- import "./chunk-ZISFMUYB.js";
8
- import "./chunk-NAIJNJZZ.js";
6
+ } from "./chunk-FYMQPAE5.js";
7
+ import "./chunk-JAWJZTFL.js";
8
+ import "./chunk-NSDOYHIS.js";
9
9
  import {
10
10
  importFrom
11
11
  } from "./chunk-Y5E2WNWB.js";
12
12
  import {
13
13
  CliError
14
- } from "./chunk-L3KMVMRJ.js";
14
+ } from "./chunk-4DPICEPQ.js";
15
15
  import {
16
16
  __name
17
17
  } from "./chunk-ZVVMGPBJ.js";
18
18
 
19
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/speech/decode.js
19
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/speech/decode.js
20
20
  import { spawn } from "node:child_process";
21
21
  import { mkdtemp, rm, writeFile } from "node:fs/promises";
22
22
  import { createRequire } from "node:module";
@@ -13,22 +13,22 @@ import {
13
13
  parseDescribe,
14
14
  shimFiles,
15
15
  writeShim
16
- } from "./chunk-PEF637VV.js";
16
+ } from "./chunk-JIIEJLAX.js";
17
17
  import "./chunk-Y5E2WNWB.js";
18
18
  import {
19
19
  CliError
20
- } from "./chunk-L3KMVMRJ.js";
20
+ } from "./chunk-4DPICEPQ.js";
21
21
  import {
22
22
  __name,
23
23
  __toESM
24
24
  } from "./chunk-ZVVMGPBJ.js";
25
25
 
26
- // node_modules/.pnpm/@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/dispatch.js
26
+ // node_modules/.pnpm/@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/dispatch.js
27
27
  var import_cross_spawn2 = __toESM(require_cross_spawn(), 1);
28
28
  import { randomUUID } from "node:crypto";
29
29
  import { constants } from "node:os";
30
30
 
31
- // node_modules/.pnpm/@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/path.js
31
+ // node_modules/.pnpm/@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/path.js
32
32
  import { readdirSync, statSync } from "node:fs";
33
33
  import { join } from "node:path";
34
34
  var variable = /* @__PURE__ */ __name((env, name, platform) => platform === "win32" ? Object.entries(env).find(([key]) => key.toUpperCase() === name)?.[1] : env[name], "variable");
@@ -100,7 +100,7 @@ var findTools = /* @__PURE__ */ __name((search) => {
100
100
  }, "findTools");
101
101
  var isBuiltIn = /* @__PURE__ */ __name((name) => name === "wcat" || BUILT_IN_COMMANDS.includes(name), "isBuiltIn");
102
102
 
103
- // node_modules/.pnpm/@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/probe.js
103
+ // node_modules/.pnpm/@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/probe.js
104
104
  var import_cross_spawn = __toESM(require_cross_spawn(), 1);
105
105
  import { readFileSync } from "node:fs";
106
106
  var MAX_ANSWER_BYTES = 64 * 1024;
@@ -149,7 +149,7 @@ var baseVersion = /* @__PURE__ */ __name(() => {
149
149
  }
150
150
  }, "baseVersion");
151
151
 
152
- // node_modules/.pnpm/@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/shortcuts.js
152
+ // node_modules/.pnpm/@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/shortcuts.js
153
153
  import { closeSync, openSync, readSync, realpathSync, rmSync } from "node:fs";
154
154
  import { basename, dirname } from "node:path";
155
155
  var WIRECAT_PACKAGE = /node_modules[\\/]+@wirecat[\\/]/;
@@ -241,7 +241,7 @@ var removeShortcuts = /* @__PURE__ */ __name((search, names) => listShortcuts(se
241
241
  return { ...statusOf(shortcut.name, shortcut.program, search), changed: true };
242
242
  }), "removeShortcuts");
243
243
 
244
- // node_modules/.pnpm/@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/dispatch.js
244
+ // node_modules/.pnpm/@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/wcat/dispatch.js
245
245
  var DEFAULT_DESCRIBE_TIMEOUT_MS = 2e3;
246
246
  var listTools = /* @__PURE__ */ __name(async (context) => {
247
247
  const installed = installedPrograms(context);
@@ -338,7 +338,7 @@ var runTool = /* @__PURE__ */ __name((path, args, context) => new Promise((resol
338
338
  });
339
339
  }), "runTool");
340
340
  var fail = /* @__PURE__ */ __name(async (error, json, context) => {
341
- const { errorObjectOf, exitCodeOfError, renderError } = await import("./failure-YRGRZBTX.js");
341
+ const { errorObjectOf, exitCodeOfError, renderError } = await import("./failure-5ZLVZTRU.js");
342
342
  const object = errorObjectOf(error);
343
343
  context.stderr.write(`${renderError(object, { cli: "wcat", interactive: !json })}
344
344
  `);
@@ -11,17 +11,17 @@ import {
11
11
  parseMarkdownSpans,
12
12
  plainQr,
13
13
  terminalQr
14
- } from "./chunk-KF4YULWC.js";
14
+ } from "./chunk-QPQSMJBW.js";
15
15
  import {
16
16
  DETAILS,
17
17
  REASONS,
18
18
  failureContext
19
- } from "./chunk-KEZHPPMI.js";
19
+ } from "./chunk-TTKNBUMT.js";
20
20
  import {
21
21
  pollLines,
22
22
  renderMessage,
23
23
  renderMessages
24
- } from "./chunk-L2ZHPIFC.js";
24
+ } from "./chunk-GUFWLTOW.js";
25
25
  import {
26
26
  ModerationRules,
27
27
  act,
@@ -32,20 +32,21 @@ import {
32
32
  pickChat,
33
33
  pickPerson,
34
34
  validateFormattedText
35
- } from "./chunk-LN7TNZIS.js";
35
+ } from "./chunk-N6P55LDU.js";
36
36
  import {
37
37
  readSecret
38
- } from "./chunk-W5J6I5GW.js";
39
- import "./chunk-DYCPBLUC.js";
38
+ } from "./chunk-LIQ5LICB.js";
39
+ import "./chunk-L3PVAY3M.js";
40
40
  import "./chunk-HTQTIKWP.js";
41
41
  import {
42
42
  resolveOutput
43
- } from "./chunk-TCWJYOZV.js";
43
+ } from "./chunk-AJ4JS2ZR.js";
44
44
  import {
45
45
  COUNTER_FIELDS,
46
46
  FOLDER_PROVIDERS,
47
47
  KINDS,
48
48
  PROVIDERS,
49
+ REF_KINDS,
49
50
  UNKNOWN_PROVIDER,
50
51
  canonicalReference,
51
52
  counterValue,
@@ -56,6 +57,7 @@ import {
56
57
  isLocator,
57
58
  kindIn,
58
59
  kindOf,
60
+ looksLikeReference,
59
61
  observedCounters,
60
62
  parseLocator,
61
63
  parseReference,
@@ -63,19 +65,19 @@ import {
63
65
  providers,
64
66
  rankingOptions,
65
67
  useProviders
66
- } from "./chunk-VGR3AGAC.js";
68
+ } from "./chunk-YRZ23RCS.js";
67
69
  import {
68
70
  TAG_TYPES,
69
71
  canonicalMeetingReference,
70
72
  formatMeetingReference,
71
73
  normalizeTag,
72
74
  parseMeetingReference
73
- } from "./chunk-4QDBMYK4.js";
74
- import "./chunk-EKRM2QJB.js";
75
- import "./chunk-ZISFMUYB.js";
76
- import "./chunk-NAIJNJZZ.js";
75
+ } from "./chunk-KVN4RY7E.js";
76
+ import "./chunk-MRLSUCHT.js";
77
+ import "./chunk-JAWJZTFL.js";
78
+ import "./chunk-NSDOYHIS.js";
77
79
  import "./chunk-Y5E2WNWB.js";
78
- import "./chunk-L3KMVMRJ.js";
80
+ import "./chunk-4DPICEPQ.js";
79
81
  import "./chunk-ZVVMGPBJ.js";
80
82
  export {
81
83
  DETAILS as CORE_DETAILS,
@@ -86,6 +88,7 @@ export {
86
88
  ModerationRules,
87
89
  PASTE_QR,
88
90
  PROVIDERS,
91
+ REF_KINDS,
89
92
  TAG_TYPES,
90
93
  UNKNOWN_PROVIDER,
91
94
  act,
@@ -109,6 +112,7 @@ export {
109
112
  kindIn,
110
113
  kindOf,
111
114
  loginQr,
115
+ looksLikeReference,
112
116
  moderationPathFor,
113
117
  normalizeTag,
114
118
  observedCounters,
@@ -42399,7 +42399,7 @@ function install11(registers) {
42399
42399
  }
42400
42400
  __name(install11, "install");
42401
42401
 
42402
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/charts/echarts-option.js
42402
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/charts/echarts-option.js
42403
42403
  var echartsOption = /* @__PURE__ */ __name((chart) => ({
42404
42404
  animation: false,
42405
42405
  backgroundColor: "#111827",
@@ -42447,7 +42447,7 @@ var echartsOption = /* @__PURE__ */ __name((chart) => ({
42447
42447
  } : {}
42448
42448
  }), "echartsOption");
42449
42449
 
42450
- // node_modules/.pnpm/@wirecat+cli-core@0.541.0_@wirecat+cli-base@0.72.0_commander@15.0.0_esbuild@0.28.2_type_5e2b4e61bcb779e86c364517878b6f21/node_modules/@wirecat/cli-core/dist/charts/echarts.js
42450
+ // node_modules/.pnpm/@wirecat+cli-core@0.550.0_@wirecat+cli-base@0.74.0_commander@15.0.0_esbuild@0.28.2_type_14b809de162f39c654f85ad24a8cdf95/node_modules/@wirecat/cli-core/dist/charts/echarts.js
42451
42451
  use([install2, install, install6, install5, install10, install7, install11]);
42452
42452
  var echartsRenderer = {
42453
42453
  render: /* @__PURE__ */ __name(async (chart, size) => {